From c8592a86f3a1ffee7f0a48aebd39e1f1c63901a3 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Wed, 26 Jul 2023 11:11:37 -0400 Subject: [PATCH 001/270] Check data check log (#9928) * add checkData to checkLog * update wrappers --- .../automation/2_1/KeeperRegistryBase2_1.sol | 14 ++++++++++++++ .../automation/2_1/KeeperRegistryLogicA2_1.sol | 14 +++++--------- .../2_1/interfaces/IKeeperRegistryMaster.sol | 4 ++-- .../2_1/interfaces/ILogAutomation.sol | 6 +++++- .../tests/LogTriggeredFeedLookup.sol | 5 ++++- .../dev/automation/tests/LogUpkeepCounter.sol | 2 +- .../v0.8/automation/KeeperRegistry2_1.test.ts | 2 +- .../i_keeper_registry_master_wrapper_2_1.go | 16 ++++++++-------- .../i_log_automation/i_log_automation.go | 16 ++++++++-------- .../keeper_registry_logic_a_wrapper_2_1.go | 18 +++++++++--------- .../log_triggered_feed_lookup_wrapper.go | 18 +++++++++--------- .../log_upkeep_counter_wrapper.go | 18 +++++++++--------- ...wrapper-dependency-versions-do-not-edit.txt | 10 +++++----- 13 files changed, 80 insertions(+), 63 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index 12b05e3bfce..3b0010f23e4 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -691,6 +691,20 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { return Trigger(uint8(rawID[15])); } + function _checkPayload( + uint256 upkeepId, + Trigger triggerType, + bytes memory triggerData + ) internal view returns (bytes memory) { + if (triggerType == Trigger.CONDITION) { + return abi.encodeWithSelector(CHECK_SELECTOR, s_checkData[upkeepId]); + } else if (triggerType == Trigger.LOG) { + Log memory log = abi.decode(triggerData, (Log)); + return abi.encodeWithSelector(CHECK_LOG_SELECTOR, log, s_checkData[upkeepId]); + } + revert InvalidTriggerType(); + } + /** * @dev _decodeReport decodes a serialized report into a Report struct */ diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol index bba3580c546..bca218137f8 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol @@ -34,7 +34,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { /** * @notice called by the automation DON to check if work is needed * @param id the upkeep ID to check for work needed - * @param checkData the data passed to the upkeep contract's checkUpkeep function + * @param triggerData extra contextual data about the trigger (not used in all code paths) * @dev this one of the core functions called in the hot path * @dev there is a 2nd checkUpkeep function (below) that is being maintained for backwards compatibility * @dev there is an incongruency on what gets returned during failure modes @@ -42,7 +42,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { */ function checkUpkeep( uint256 id, - bytes memory checkData + bytes memory triggerData ) public cannotExecute @@ -79,12 +79,8 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { return (false, bytes(""), UpkeepFailureReason.INSUFFICIENT_BALANCE, 0, upkeep.performGas, 0, 0); } - bytes memory callData; - if (triggerType == Trigger.CONDITION) { - callData = abi.encodeWithSelector(CHECK_SELECTOR, checkData); - } else { - callData = bytes.concat(CHECK_LOG_SELECTOR, checkData); - } + bytes memory callData = _checkPayload(id, triggerType, triggerData); + gasUsed = gasleft(); (bool success, bytes memory result) = upkeep.target.call{gas: s_storage.checkGasLimit}(callData); gasUsed = gasUsed - gasleft(); @@ -157,7 +153,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { uint256 linkNative ) { - return checkUpkeep(id, s_checkData[id]); + return checkUpkeep(id, bytes("")); } /** diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol index c7f5482c6ae..09fc6488d3d 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol @@ -162,7 +162,7 @@ interface IKeeperRegistryMaster { function checkUpkeep( uint256 id, - bytes memory checkData + bytes memory triggerData ) external returns ( @@ -372,5 +372,5 @@ interface KeeperRegistryBase2_1 { // THIS FILE WAS AUTOGENERATED FROM THE FOLLOWING ABI JSON: /* -[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"checkData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getCheckGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract AutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTransmitGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getCheckGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract AutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTransmitGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] */ diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/ILogAutomation.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/ILogAutomation.sol index ce405fdef0e..ebb098ee31c 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/ILogAutomation.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/ILogAutomation.sol @@ -22,13 +22,17 @@ interface ILogAutomation { * method. * @param log the raw log data matching the filter that this contract has * registered as a trigger + * @param checkData user-specified extra data to provide context to this upkeep * @return upkeepNeeded boolean to indicate whether the keeper should call * performUpkeep or not. * @return performData bytes that the keeper should call performUpkeep with, if * upkeep is needed. If you would like to encode data to decode later, try * `abi.encode`. */ - function checkLog(Log calldata log) external returns (bool upkeepNeeded, bytes memory performData); + function checkLog( + Log calldata log, + bytes memory checkData + ) external returns (bool upkeepNeeded, bytes memory performData); /** * @notice method that is actually executed by the keepers, via the registry. diff --git a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol index 3aa2b187b86..e631eea317e 100644 --- a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol +++ b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol @@ -56,7 +56,10 @@ contract LogTriggeredFeedLookup is ILogAutomation, FeedLookupCompatibleInterface feedsHex = newFeeds; } - function checkLog(Log calldata log) external override returns (bool upkeepNeeded, bytes memory performData) { + function checkLog( + Log calldata log, + bytes memory + ) external override returns (bool upkeepNeeded, bytes memory performData) { uint256 blockNum = getBlockNumber(); // filter by event signature diff --git a/contracts/src/v0.8/dev/automation/tests/LogUpkeepCounter.sol b/contracts/src/v0.8/dev/automation/tests/LogUpkeepCounter.sol index 73795b3b1b1..84e53b65493 100644 --- a/contracts/src/v0.8/dev/automation/tests/LogUpkeepCounter.sol +++ b/contracts/src/v0.8/dev/automation/tests/LogUpkeepCounter.sol @@ -48,7 +48,7 @@ contract LogUpkeepCounter is ILogAutomation { emit Trigger(1, 2, 3); } - function checkLog(Log calldata log) external view override returns (bool, bytes memory) { + function checkLog(Log calldata log, bytes memory) external view override returns (bool, bytes memory) { require(eligible(), "not eligible"); if (log.topics[0] == sig1 || log.topics[0] == sig2 || log.topics[0] == sig3 || log.topics[0] == sig4) { return (true, abi.encode(log)); diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index d7f9a60ebd1..f6ef0eaae86 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -3193,7 +3193,7 @@ describe('KeeperRegistry2_1', () => { data: ethers.utils.randomBytes(1000), } - await ltUpkeep.mock.checkLog.withArgs(log).returns(true, '0x1234') + await ltUpkeep.mock.checkLog.withArgs(log, '0x').returns(true, '0x1234') const checkData = encodeLog(log) diff --git a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go index 2eb8dfa9aaa..42181724edd 100644 --- a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go +++ b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var IKeeperRegistryMasterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var IKeeperRegistryMasterABI = IKeeperRegistryMasterMetaData.ABI @@ -1042,16 +1042,16 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) CheckCallb return _IKeeperRegistryMaster.Contract.CheckCallback(&_IKeeperRegistryMaster.TransactOpts, id, values, extraData) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) CheckUpkeep(opts *bind.TransactOpts, id *big.Int, checkData []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.contract.Transact(opts, "checkUpkeep", id, checkData) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) CheckUpkeep(opts *bind.TransactOpts, id *big.Int, triggerData []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.contract.Transact(opts, "checkUpkeep", id, triggerData) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) CheckUpkeep(id *big.Int, checkData []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.Contract.CheckUpkeep(&_IKeeperRegistryMaster.TransactOpts, id, checkData) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) CheckUpkeep(id *big.Int, triggerData []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.Contract.CheckUpkeep(&_IKeeperRegistryMaster.TransactOpts, id, triggerData) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) CheckUpkeep(id *big.Int, checkData []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.Contract.CheckUpkeep(&_IKeeperRegistryMaster.TransactOpts, id, checkData) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) CheckUpkeep(id *big.Int, triggerData []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.Contract.CheckUpkeep(&_IKeeperRegistryMaster.TransactOpts, id, triggerData) } func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) CheckUpkeep0(opts *bind.TransactOpts, id *big.Int) (*types.Transaction, error) { @@ -5921,7 +5921,7 @@ type IKeeperRegistryMasterInterface interface { CheckCallback(opts *bind.TransactOpts, id *big.Int, values [][]byte, extraData []byte) (*types.Transaction, error) - CheckUpkeep(opts *bind.TransactOpts, id *big.Int, checkData []byte) (*types.Transaction, error) + CheckUpkeep(opts *bind.TransactOpts, id *big.Int, triggerData []byte) (*types.Transaction, error) CheckUpkeep0(opts *bind.TransactOpts, id *big.Int) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/i_log_automation/i_log_automation.go b/core/gethwrappers/generated/i_log_automation/i_log_automation.go index fda92f01c40..122c7f2ce7d 100644 --- a/core/gethwrappers/generated/i_log_automation/i_log_automation.go +++ b/core/gethwrappers/generated/i_log_automation/i_log_automation.go @@ -40,7 +40,7 @@ type Log struct { } var ILogAutomationMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var ILogAutomationABI = ILogAutomationMetaData.ABI @@ -161,16 +161,16 @@ func (_ILogAutomation *ILogAutomationTransactorRaw) Transact(opts *bind.Transact return _ILogAutomation.Contract.contract.Transact(opts, method, params...) } -func (_ILogAutomation *ILogAutomationTransactor) CheckLog(opts *bind.TransactOpts, log Log) (*types.Transaction, error) { - return _ILogAutomation.contract.Transact(opts, "checkLog", log) +func (_ILogAutomation *ILogAutomationTransactor) CheckLog(opts *bind.TransactOpts, log Log, checkData []byte) (*types.Transaction, error) { + return _ILogAutomation.contract.Transact(opts, "checkLog", log, checkData) } -func (_ILogAutomation *ILogAutomationSession) CheckLog(log Log) (*types.Transaction, error) { - return _ILogAutomation.Contract.CheckLog(&_ILogAutomation.TransactOpts, log) +func (_ILogAutomation *ILogAutomationSession) CheckLog(log Log, checkData []byte) (*types.Transaction, error) { + return _ILogAutomation.Contract.CheckLog(&_ILogAutomation.TransactOpts, log, checkData) } -func (_ILogAutomation *ILogAutomationTransactorSession) CheckLog(log Log) (*types.Transaction, error) { - return _ILogAutomation.Contract.CheckLog(&_ILogAutomation.TransactOpts, log) +func (_ILogAutomation *ILogAutomationTransactorSession) CheckLog(log Log, checkData []byte) (*types.Transaction, error) { + return _ILogAutomation.Contract.CheckLog(&_ILogAutomation.TransactOpts, log, checkData) } func (_ILogAutomation *ILogAutomationTransactor) PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) { @@ -190,7 +190,7 @@ func (_ILogAutomation *ILogAutomation) Address() common.Address { } type ILogAutomationInterface interface { - CheckLog(opts *bind.TransactOpts, log Log) (*types.Transaction, error) + CheckLog(opts *bind.TransactOpts, log Log, checkData []byte) (*types.Transaction, error) PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go index 5c283a0181f..710ac46d9cc 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go @@ -31,8 +31,8 @@ var ( ) var KeeperRegistryLogicAMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101206040523480156200001257600080fd5b5060405162005fa238038062005fa2833981016040819052620000359162000374565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b91906200039b565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000100919062000374565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000165919062000374565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca919062000374565b3380600081620002215760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000254576200025481620002b0565b5050508360028111156200026c576200026c620003be565b60e0816002811115620002835762000283620003be565b9052506001600160a01b0392831660805290821660a052811660c052919091166101005250620003d49050565b336001600160a01b038216036200030a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000218565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200037157600080fd5b50565b6000602082840312156200038757600080fd5b815162000394816200035b565b9392505050565b600060208284031215620003ae57600080fd5b8151600381106200039457600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051615b666200043c6000396000818161010e01526101a901526000818161345c01528181613692015281816139180152613ac0015260006132280152600061330c015260008181611e2201526123f50152615b666000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806385c1b0ba11620000a5578063c8048022116200006f578063c804802214620002b7578063ce7dc5b414620002ce578063f2fde38b14620002e5578063f7d334ba14620002fc576200010c565b806385c1b0ba14620002535780638da5cb5b146200026a5780638e86139b1462000289578063948108f714620002a0576200010c565b80634ee88d3511620000e75780634ee88d3514620001ef5780636ded9eae146200020657806371791aa0146200021d57806379ba50971462000249576200010c565b806328f32f38146200015457806329c5efad146200017e578063349e8cca14620001a7575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e8080156200014d573d6000f35b3d6000fd5b005b6200016b6200016536600462004134565b62000313565b6040519081526020015b60405180910390f35b620001956200018f3660046200421a565b62000636565b60405162000175949392919062004342565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000175565b62000152620002003660046200437f565b62000878565b6200016b62000217366004620043cf565b620008e0565b620002346200022e3660046200421a565b62000946565b60405162000175979695949392919062004482565b620001526200112f565b6200015262000264366004620044d4565b62001232565b60005473ffffffffffffffffffffffffffffffffffffffff16620001c9565b620001526200029a36600462004561565b62001ea3565b62000152620002b1366004620045c4565b62002223565b62000152620002c8366004620045f3565b620024c5565b62000195620002df366004620046c9565b6200289b565b62000152620002f636600462004740565b6200296b565b620002346200030d366004620045f3565b62002983565b6000805473ffffffffffffffffffffffffffffffffffffffff1633148015906200034757506200034560093362002a55565b155b156200037f576040517fd48b678b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200038a8662002a89565b90506000818a306040516200039f9062003ede565b92835273ffffffffffffffffffffffffffffffffffffffff9182166020840152166040820152606001604051809103906000f080158015620003e5573d6000803e3d6000fd5b509050620004c9826040518061010001604052806000151581526020018c63ffffffff16815260200163ffffffff801681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff168152602001600063ffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff168152508a89898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915062002c2d9050565b6014805474010000000000000000000000000000000000000000900463ffffffff169080620004f8836200478f565b91906101000a81548163ffffffff021916908363ffffffff16021790555050817fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d0128a8a6040516200057192919063ffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2817fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8787604051620005ad929190620047fe565b60405180910390a2817f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d566485604051620005e7919062004814565b60405180910390a2817f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508460405162000621919062004814565b60405180910390a25098975050505050505050565b600060606000806200064762003066565b60008681526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff91810482169483019490945265010000000000840481169482019490945273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009093048316606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490931660c0840152600201541660e08201525a60e0820151601454604051929450600092839273ffffffffffffffffffffffffffffffffffffffff16916c01000000000000000000000000900463ffffffff169062000767908b9062004829565b60006040518083038160008787f1925050503d8060008114620007a7576040519150601f19603f3d011682016040523d82523d6000602084013e620007ac565b606091505b50915091505a620007be908562004847565b935081620007e95760006040518060200160405280600081525060079650965096505050506200086f565b80806020019051810190620007ff9190620048b8565b9097509550866200082d5760006040518060200160405280600081525060049650965096505050506200086f565b601554865164010000000090910463ffffffff1610156200086b5760006040518060200160405280600081525060059650965096505050506200086f565b5050505b92959194509250565b6200088383620030a1565b6000838152601a602052604090206200089e828483620049ad565b50827f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d56648383604051620008d3929190620047fe565b60405180910390a2505050565b60006200093a88888860008989604051806020016040528060008152508a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506200031392505050565b98975050505050505050565b6000606060008060008060006200095c62003066565b6000620009698a62003157565b905060006012604051806101200160405290816000820160009054906101000a900460ff1660ff1660ff1681526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900462ffffff1662ffffff1662ffffff16815260200160008201600c9054906101000a900461ffff1661ffff1661ffff16815260200160008201600e9054906101000a900460ff1615151515815260200160008201600f9054906101000a900460ff161515151581526020016000820160109054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090506000600460008d8152602001908152602001600020604051806101000160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160018201600c9054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020016001820160189054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152505090508160a001511562000ce4576000604051806020016040528060008152506009600084602001516000808263ffffffff169250995099509950995099509950995050505062001123565b604081015163ffffffff9081161462000d35576000604051806020016040528060008152506001600084602001516000808263ffffffff169250995099509950995099509950995050505062001123565b80511562000d7b576000604051806020016040528060008152506002600084602001516000808263ffffffff169250995099509950995099509950995050505062001123565b62000d868262003205565b602083015160155492975090955060009162000db8918591879190640100000000900463ffffffff168a8a87620033f7565b9050806bffffffffffffffffffffffff168260a001516bffffffffffffffffffffffff16101562000e22576000604051806020016040528060008152506006600085602001516000808263ffffffff1692509a509a509a509a509a509a509a505050505062001123565b6060600085600181111562000e3b5762000e3b620042d7565b0362000efb576040517f6e04ff0d000000000000000000000000000000000000000000000000000000009062000e76908f9060240162004814565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152905062000f42565b60405162000f30907fbe61b77500000000000000000000000000000000000000000000000000000000908f9060200162004ad5565b60405160208183030381529060405290505b5a60e0840151601454604051929b50600092839273ffffffffffffffffffffffffffffffffffffffff16916c01000000000000000000000000900463ffffffff169062000f9190869062004829565b60006040518083038160008787f1925050503d806000811462000fd1576040519150601f19603f3d011682016040523d82523d6000602084013e62000fd6565b606091505b50915091505a62000fe8908c62004847565b9a5081620010685760155481516801000000000000000090910463ffffffff1610156200104557505060408051602080820190925260008082529490910151939c509a50600899505063ffffffff90911695506200112392505050565b602090940151939b5060039a505063ffffffff9092169650620011239350505050565b808060200190518101906200107e9190620048b8565b909e509c508d620010bf57505060408051602080820190925260008082529490910151939c509a50600499505063ffffffff90911695506200112392505050565b6015548d5164010000000090910463ffffffff1610156200111057505060408051602080820190925260008082529490910151939c509a50600599505063ffffffff90911695506200112392505050565b505050506020015163ffffffff16945050505b92959891949750929550565b60015473ffffffffffffffffffffffffffffffffffffffff163314620011b6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600173ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff166003811115620012715762001271620042d7565b14158015620012bd5750600373ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff166003811115620012ba57620012ba620042d7565b14155b15620012f5576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1662001355576040517fd12d7d8d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082900362001391576040517f2c2fc94100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805161010081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526000808567ffffffffffffffff811115620013f057620013f062003fe1565b6040519080825280602002602001820160405280156200141a578160200160208202803683370190505b50905060008667ffffffffffffffff8111156200143b576200143b62003fe1565b604051908082528060200260200182016040528015620014ca57816020015b604080516101008101825260008082526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816200145a5790505b50905060008767ffffffffffffffff811115620014eb57620014eb62003fe1565b6040519080825280602002602001820160405280156200152057816020015b60608152602001906001900390816200150a5790505b50905060008867ffffffffffffffff81111562001541576200154162003fe1565b6040519080825280602002602001820160405280156200157657816020015b6060815260200190600190039081620015605790505b50905060008967ffffffffffffffff81111562001597576200159762003fe1565b604051908082528060200260200182016040528015620015cc57816020015b6060815260200190600190039081620015b65790505b50905060005b8a81101562001be7578b8b82818110620015f057620015f062004b1f565b6020908102929092013560008181526004845260409081902081516101008082018452825460ff81161515835263ffffffff91810482169783019790975265010000000000870481169382019390935273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009096048616606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490921660c08301526002015490931660e08401529a50909850620016dc905089620030a1565b60608801516040517f1a5da6c800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c8116600483015290911690631a5da6c890602401600060405180830381600087803b1580156200174c57600080fd5b505af115801562001761573d6000803e3d6000fd5b50505050878582815181106200177b576200177b62004b1f565b6020026020010181905250600560008a815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868281518110620017cf57620017cf62004b1f565b73ffffffffffffffffffffffffffffffffffffffff90921660209283029190910182015260008a815260079091526040902080546200180e9062004905565b80601f01602080910402602001604051908101604052809291908181526020018280546200183c9062004905565b80156200188d5780601f1062001861576101008083540402835291602001916200188d565b820191906000526020600020905b8154815290600101906020018083116200186f57829003601f168201915b5050505050848281518110620018a757620018a762004b1f565b6020026020010181905250601a60008a81526020019081526020016000208054620018d29062004905565b80601f0160208091040260200160405190810160405280929190818152602001828054620019009062004905565b8015620019515780601f10620019255761010080835404028352916020019162001951565b820191906000526020600020905b8154815290600101906020018083116200193357829003601f168201915b50505050508382815181106200196b576200196b62004b1f565b6020026020010181905250601b60008a81526020019081526020016000208054620019969062004905565b80601f0160208091040260200160405190810160405280929190818152602001828054620019c49062004905565b801562001a155780601f10620019e95761010080835404028352916020019162001a15565b820191906000526020600020905b815481529060010190602001808311620019f757829003601f168201915b505050505082828151811062001a2f5762001a2f62004b1f565b60200260200101819052508760a001516bffffffffffffffffffffffff168762001a5a919062004b4e565b60008a815260046020908152604080832080547fffffff00000000000000000000000000000000000000000000000000000000001681556001810180547fffffffff0000000000000000000000000000000000000000000000000000000016905560020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556007909152812091985062001afa919062003eec565b6000898152601a6020526040812062001b139162003eec565b6000898152601b6020526040812062001b2c9162003eec565b600089815260066020526040902080547fffffffffffffffffffffffff000000000000000000000000000000000000000016905562001b6d60028a62003448565b5060a0880151604080516bffffffffffffffffffffffff909216825273ffffffffffffffffffffffffffffffffffffffff8c1660208301528a917fb38647142fbb1ea4c000fc4569b37a4e9a9f6313317b84ee3e5326c1a6cd06ff910160405180910390a28062001bde8162004b64565b915050620015d2565b508560185462001bf8919062004847565b60185560405160009062001c1d908d908d9088908a9089908990899060200162004c4b565b60405160208183030381529060405290508973ffffffffffffffffffffffffffffffffffffffff16638e86139b6013600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c71249ab60038e73ffffffffffffffffffffffffffffffffffffffff1663aab9edd66040518163ffffffff1660e01b8152600401602060405180830381865afa15801562001cd9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001cff919062004dc5565b866040518463ffffffff1660e01b815260040162001d209392919062004dea565b600060405180830381865afa15801562001d3e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405262001d86919081019062004e11565b6040518263ffffffff1660e01b815260040162001da4919062004814565b600060405180830381600087803b15801562001dbf57600080fd5b505af115801562001dd4573d6000803e3d6000fd5b50506040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d81166004830152602482018b90527f000000000000000000000000000000000000000000000000000000000000000016925063a9059cbb91506044016020604051808303816000875af115801562001e6e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001e94919062004e4a565b50505050505050505050505050565b60023360009081526019602052604090205460ff16600381111562001ecc5762001ecc620042d7565b1415801562001f02575060033360009081526019602052604090205460ff16600381111562001eff5762001eff620042d7565b14155b1562001f3a576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808080808062001f4f878901896200504a565b95509550955095509550955060005b86518110156200221857600073ffffffffffffffffffffffffffffffffffffffff1686828151811062001f955762001f9562004b1f565b60200260200101516060015173ffffffffffffffffffffffffffffffffffffffff1603620020a55786818151811062001fd25762001fd262004b1f565b602002602001015186828151811062001fef5762001fef62004b1f565b602002602001015160e00151306040516200200a9062003ede565b92835273ffffffffffffffffffffffffffffffffffffffff9182166020840152166040820152606001604051809103906000f08015801562002050573d6000803e3d6000fd5b5086828151811062002066576200206662004b1f565b60200260200101516060019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505b6200215d878281518110620020be57620020be62004b1f565b6020026020010151878381518110620020db57620020db62004b1f565b6020026020010151878481518110620020f857620020f862004b1f565b602002602001015187858151811062002115576200211562004b1f565b602002602001015187868151811062002132576200213262004b1f565b60200260200101518787815181106200214f576200214f62004b1f565b602002602001015162002c2d565b86818151811062002172576200217262004b1f565b60200260200101517f74931a144e43a50694897f241d973aecb5024c0e910f9bb80a163ea3c1cf5a71878381518110620021b057620021b062004b1f565b602002602001015160a0015133604051620021fb9291906bffffffffffffffffffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2806200220f8162004b64565b91505062001f5e565b505050505050505050565b60008281526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff918104821694830194909452650100000000008404811694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009094048416606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490921660e083015290911462002330576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160a0015162002342919062005152565b600084815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601854620023aa9184169062004b4e565b6018556040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526bffffffffffffffffffffffff831660448201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906323b872dd906064016020604051808303816000875af115801562002454573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200247a919062004e4a565b506040516bffffffffffffffffffffffff83168152339084907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a3505050565b600081815260046020908152604080832081516101008082018452825460ff81161515835263ffffffff918104821695830195909552650100000000008504811693820184905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009095048516606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490931660e0840152919291141590620025bd60005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161490508180156200261857508080156200261657506200260962003456565b836040015163ffffffff16115b155b1562002650576040517ffbc0357800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8015801562002683575060008481526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314155b15620026bb576040517ffbdb8e5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000620026c762003456565b905081620026df57620026dc60328262004b4e565b90505b6000858152600460205260409020805463ffffffff80841665010000000000027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff909216919091179091556200273b9060029087906200344816565b5060135460808501516bffffffffffffffffffffffff9182169160009116821115620027a45760808601516200277290836200517a565b90508560a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115620027a4575060a08501515b808660a00151620027b691906200517a565b600088815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff938416021790556014546200281e9183911662005152565b601480547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9290921691909117905560405167ffffffffffffffff84169088907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a350505050505050565b60006060600080620028ac62003066565b6000634b56a42e60e01b888888604051602401620028cd93929190620051a2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152905062002958898262000636565b929c919b50995090975095505050505050565b6200297562003512565b620029808162003595565b50565b60006060600080600080600062002a3e88600760008b81526020019081526020016000208054620029b49062004905565b80601f0160208091040260200160405190810160405280929190818152602001828054620029e29062004905565b801562002a335780601f1062002a075761010080835404028352916020019162002a33565b820191906000526020600020905b81548152906001019060200180831162002a1557829003601f168201915b505050505062000946565b959e949d50929b5090995097509550909350915050565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b90505b92915050565b600080600062002ab0600162002a9e62003456565b62002aaa919062004847565b6200368c565b601454604080516020810193909352309083015274010000000000000000000000000000000000000000900463ffffffff166060820152608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201209083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060045b600f81101562002bbc578282828151811062002b785762002b7862004b1f565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508062002bb38162004b64565b91505062002b58565b5083600181111562002bd25762002bd2620042d7565b60f81b81600f8151811062002beb5762002beb62004b1f565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535062002c2581620051d6565b949350505050565b6012546e010000000000000000000000000000900460ff161562002c7d576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e085015173ffffffffffffffffffffffffffffffffffffffff163b62002cd0576040517f09ee12d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601554835163ffffffff909116101562002d16576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108fc856020015163ffffffff16108062002d545750601454602086015163ffffffff70010000000000000000000000000000000090920482169116115b1562002d8c576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008681526004602052604090206002015473ffffffffffffffffffffffffffffffffffffffff161562002dec576040517f6e3b930b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600086815260046020908152604080832088518154848b0151848c015160608d015173ffffffffffffffffffffffffffffffffffffffff9081166901000000000000000000027fffffff0000000000000000000000000000000000000000ffffffffffffffffff63ffffffff9384166501000000000002167fffffff000000000000000000000000000000000000000000000000ffffffffff948416610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff971515979097167fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009096169590951795909517929092169290921792909217835560808b015160018401805460a08e015160c08f01519094167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff6bffffffffffffffffffffffff9586166c01000000000000000000000000027fffffffffffffffff0000000000000000000000000000000000000000000000009093169590941694909417179190911691909117905560e08a0151600290920180549282167fffffffffffffffffffffffff0000000000000000000000000000000000000000938416179055600584528285208054918a16919092161790556007909152902062002ff4848262005219565b508460a001516bffffffffffffffffffffffff1660185462003017919062004b4e565b6018556000868152601a6020526040902062003034838262005219565b506000868152601b602052604090206200304f828262005219565b506200305d600287620037fb565b50505050505050565b32156200309f576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314620030ff576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff9081161462002980576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f811015620031ec577fff000000000000000000000000000000000000000000000000000000000000008216838260208110620031a057620031a062004b1f565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614620031d757506000949350505050565b80620031e38162004b64565b9150506200315e565b5081600f1a600181111562002c255762002c25620042d7565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa15801562003292573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620032b891906200535b565b5094509092505050600081131580620032d057508142105b80620032f55750828015620032f55750620032ec824262004847565b8463ffffffff16105b15620033065760165495506200330a565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa15801562003376573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200339c91906200535b565b5094509092505050600081131580620033b457508142105b80620033d95750828015620033d95750620033d0824262004847565b8463ffffffff16105b15620033ea576017549450620033ee565b8094505b50505050915091565b6000806200340b88878b6000015162003809565b9050600080620034288b8a63ffffffff16858a8a60018b620038df565b909250905062003439818362005152565b9b9a5050505050505050505050565b600062002a80838362003d81565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156200348f576200348f620042d7565b036200350d57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620034e2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620035089190620053b0565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff1633146200309f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401620011ad565b3373ffffffffffffffffffffffffffffffffffffffff82160362003616576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620011ad565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115620036c557620036c5620042d7565b03620037f1576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200371a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620037409190620053b0565b905080831015806200375e57506101006200375c848362004847565b115b156200376d5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015620037c4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620037ea9190620053b0565b9392505050565b504090565b919050565b600062002a80838362003e8c565b60008080856001811115620038225762003822620042d7565b0362003833575062015f906200388d565b60018560018111156200384a576200384a620042d7565b036200385b57506201adb06200388d565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b620038a063ffffffff85166014620053ca565b620038ad8460016200540a565b620038be9060ff16611d4c620053ca565b620038ca908362004b4e565b620038d6919062004b4e565b95945050505050565b6000806000896080015161ffff1687620038fa9190620053ca565b9050838015620039095750803a105b156200391257503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156200394b576200394b620042d7565b0362003abc576040805160008152602081019091528515620039af5760003660405180608001604052806048815260200162005b1260489139604051602001620039989392919062005426565b604051602081830303815290604052905062003a1d565b601554620039cd90640100000000900463ffffffff1660046200544f565b63ffffffff1667ffffffffffffffff811115620039ee57620039ee62003fe1565b6040519080825280601f01601f19166020018201604052801562003a19576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9062003a6f90849060040162004814565b602060405180830381865afa15801562003a8d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003ab39190620053b0565b91505062003c26565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111562003af35762003af3620042d7565b0362003c2657841562003b7b57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003b4d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003b739190620053b0565b905062003c26565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801562003bca573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003bf091906200547e565b505060155492945062003c1593505050640100000000900463ffffffff1682620053ca565b62003c22906010620053ca565b9150505b8462003c4557808b6080015161ffff1662003c429190620053ca565b90505b62003c5561ffff871682620054c9565b90506000878262003c678c8e62004b4e565b62003c739086620053ca565b62003c7f919062004b4e565b62003c9390670de0b6b3a7640000620053ca565b62003c9f9190620054c9565b905060008c6040015163ffffffff1664e8d4a5100062003cc09190620053ca565b898e6020015163ffffffff16858f8862003cdb9190620053ca565b62003ce7919062004b4e565b62003cf790633b9aca00620053ca565b62003d039190620053ca565b62003d0f9190620054c9565b62003d1b919062004b4e565b90506b033b2e3c9fd0803ce800000062003d36828462004b4e565b111562003d6f576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000818152600183016020526040812054801562003e7a57600062003da860018362004847565b855490915060009062003dbe9060019062004847565b905081811462003e2a57600086600001828154811062003de25762003de262004b1f565b906000526020600020015490508087600001848154811062003e085762003e0862004b1f565b6000918252602080832090910192909255918252600188019052604090208390555b855486908062003e3e5762003e3e62005505565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505062002a83565b600091505062002a83565b5092915050565b600081815260018301602052604081205462003ed55750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915562002a83565b50600062002a83565b6105dd806200553583390190565b50805462003efa9062004905565b6000825580601f1062003f0b575050565b601f0160209004906000526020600020908101906200298091905b8082111562003f3c576000815560010162003f26565b5090565b73ffffffffffffffffffffffffffffffffffffffff811681146200298057600080fd5b8035620037f68162003f40565b803563ffffffff81168114620037f657600080fd5b803560028110620037f657600080fd5b60008083601f84011262003fa857600080fd5b50813567ffffffffffffffff81111562003fc157600080fd5b60208301915083602082850101111562003fda57600080fd5b9250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610100810167ffffffffffffffff8111828210171562004037576200403762003fe1565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171562004087576200408762003fe1565b604052919050565b600067ffffffffffffffff821115620040ac57620040ac62003fe1565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f830112620040ea57600080fd5b813562004101620040fb826200408f565b6200403d565b8181528460208386010111156200411757600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060e0898b0312156200415157600080fd5b88356200415e8162003f40565b97506200416e60208a0162003f70565b96506040890135620041808162003f40565b95506200419060608a0162003f85565b9450608089013567ffffffffffffffff80821115620041ae57600080fd5b620041bc8c838d0162003f95565b909650945060a08b0135915080821115620041d657600080fd5b620041e48c838d01620040d8565b935060c08b0135915080821115620041fb57600080fd5b506200420a8b828c01620040d8565b9150509295985092959890939650565b600080604083850312156200422e57600080fd5b82359150602083013567ffffffffffffffff8111156200424d57600080fd5b6200425b85828601620040d8565b9150509250929050565b60005b838110156200428257818101518382015260200162004268565b50506000910152565b60008151808452620042a581602086016020860162004265565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600a81106200433e577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b84151581526080602082015260006200435f60808301866200428b565b905062004370604083018562004306565b82606083015295945050505050565b6000806000604084860312156200439557600080fd5b83359250602084013567ffffffffffffffff811115620043b457600080fd5b620043c28682870162003f95565b9497909650939450505050565b600080600080600080600060a0888a031215620043eb57600080fd5b8735620043f88162003f40565b9650620044086020890162003f70565b955060408801356200441a8162003f40565b9450606088013567ffffffffffffffff808211156200443857600080fd5b620044468b838c0162003f95565b909650945060808a01359150808211156200446057600080fd5b506200446f8a828b0162003f95565b989b979a50959850939692959293505050565b871515815260e0602082015260006200449f60e08301896200428b565b9050620044b0604083018862004306565b8560608301528460808301528360a08301528260c083015298975050505050505050565b600080600060408486031215620044ea57600080fd5b833567ffffffffffffffff808211156200450357600080fd5b818601915086601f8301126200451857600080fd5b8135818111156200452857600080fd5b8760208260051b85010111156200453e57600080fd5b60209283019550935050840135620045568162003f40565b809150509250925092565b600080602083850312156200457557600080fd5b823567ffffffffffffffff8111156200458d57600080fd5b6200459b8582860162003f95565b90969095509350505050565b80356bffffffffffffffffffffffff81168114620037f657600080fd5b60008060408385031215620045d857600080fd5b82359150620045ea60208401620045a7565b90509250929050565b6000602082840312156200460657600080fd5b5035919050565b600067ffffffffffffffff8211156200462a576200462a62003fe1565b5060051b60200190565b600082601f8301126200464657600080fd5b8135602062004659620040fb836200460d565b82815260059290921b840181019181810190868411156200467957600080fd5b8286015b84811015620046be57803567ffffffffffffffff8111156200469f5760008081fd5b620046af8986838b0101620040d8565b8452509183019183016200467d565b509695505050505050565b60008060008060608587031215620046e057600080fd5b84359350602085013567ffffffffffffffff808211156200470057600080fd5b6200470e8883890162004634565b945060408701359150808211156200472557600080fd5b50620047348782880162003f95565b95989497509550505050565b6000602082840312156200475357600080fd5b8135620037ea8162003f40565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff808316818103620047ab57620047ab62004760565b6001019392505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60208152600062002c25602083018486620047b5565b60208152600062002a8060208301846200428b565b600082516200483d81846020870162004265565b9190910192915050565b8181038181111562002a835762002a8362004760565b80151581146200298057600080fd5b600082601f8301126200487e57600080fd5b81516200488f620040fb826200408f565b818152846020838601011115620048a557600080fd5b62002c2582602083016020870162004265565b60008060408385031215620048cc57600080fd5b8251620048d9816200485d565b602084015190925067ffffffffffffffff811115620048f757600080fd5b6200425b858286016200486c565b600181811c908216806200491a57607f821691505b60208210810362004954577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115620049a857600081815260208120601f850160051c81016020861015620049835750805b601f850160051c820191505b81811015620049a4578281556001016200498f565b5050505b505050565b67ffffffffffffffff831115620049c857620049c862003fe1565b620049e083620049d9835462004905565b836200495a565b6000601f84116001811462004a355760008515620049fe5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835562004ace565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101562004a86578685013582556020948501946001909201910162004a64565b508682101562004ac2577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7fffffffff00000000000000000000000000000000000000000000000000000000831681526000825162004b1181600485016020870162004265565b919091016004019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b8082018082111562002a835762002a8362004760565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362004b985762004b9862004760565b5060010190565b600081518084526020808501945080840160005b8381101562004be757815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010162004bb3565b509495945050505050565b600081518084526020808501808196508360051b8101915082860160005b8581101562004c3e57828403895262004c2b8483516200428b565b9885019893509084019060010162004c10565b5091979650505050505050565b600060c0808352888184015260e07f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8a111562004c8757600080fd5b8960051b808c83870137840184810382016020808701919091528a518383018190528b82019261010092919083019060005b8181101562004d5a5785518051151584528481015163ffffffff9081168686015260408083015182169086015260608083015173ffffffffffffffffffffffffffffffffffffffff908116918701919091526080808401516bffffffffffffffffffffffff9081169188019190915260a080850151909116908701528a8301519091168a860152908801511687840152948301949184019160010162004cb9565b5050878103604089015262004d70818d62004b9f565b95505050505050828103606084015262004d8b818762004bf2565b9050828103608084015262004da1818662004bf2565b905082810360a084015262004db7818562004bf2565b9a9950505050505050505050565b60006020828403121562004dd857600080fd5b815160ff81168114620037ea57600080fd5b60ff8416815260ff83166020820152606060408201526000620038d660608301846200428b565b60006020828403121562004e2457600080fd5b815167ffffffffffffffff81111562004e3c57600080fd5b62002c25848285016200486c565b60006020828403121562004e5d57600080fd5b8151620037ea816200485d565b600082601f83011262004e7c57600080fd5b8135602062004e8f620040fb836200460d565b82815260059290921b8401810191818101908684111562004eaf57600080fd5b8286015b84811015620046be578035835291830191830162004eb3565b600082601f83011262004ede57600080fd5b8135602062004ef1620040fb836200460d565b82815260089290921b8401810191818101908684111562004f1157600080fd5b8286015b84811015620046be57610100818903121562004f315760008081fd5b62004f3b62004010565b813562004f48816200485d565b815262004f5782860162003f70565b85820152604062004f6a81840162003f70565b90820152606062004f7d83820162003f63565b90820152608062004f90838201620045a7565b9082015260a062004fa3838201620045a7565b9082015260c062004fb683820162003f70565b9082015260e062004fc983820162003f63565b908201528352918301916101000162004f15565b600082601f83011262004fef57600080fd5b8135602062005002620040fb836200460d565b82815260059290921b840181019181810190868411156200502257600080fd5b8286015b84811015620046be5780356200503c8162003f40565b835291830191830162005026565b60008060008060008060c087890312156200506457600080fd5b863567ffffffffffffffff808211156200507d57600080fd5b6200508b8a838b0162004e6a565b97506020890135915080821115620050a257600080fd5b620050b08a838b0162004ecc565b96506040890135915080821115620050c757600080fd5b620050d58a838b0162004fdd565b95506060890135915080821115620050ec57600080fd5b620050fa8a838b0162004634565b945060808901359150808211156200511157600080fd5b6200511f8a838b0162004634565b935060a08901359150808211156200513657600080fd5b506200514589828a0162004634565b9150509295509295509295565b6bffffffffffffffffffffffff81811683821601908082111562003e855762003e8562004760565b6bffffffffffffffffffffffff82811682821603908082111562003e855762003e8562004760565b604081526000620051b7604083018662004bf2565b8281036020840152620051cc818587620047b5565b9695505050505050565b8051602080830151919081101562004954577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60209190910360031b1b16919050565b815167ffffffffffffffff81111562005236576200523662003fe1565b6200524e8162005247845462004905565b846200495a565b602080601f831160018114620052a457600084156200526d5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555620049a4565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015620052f357888601518255948401946001909101908401620052d2565b50858210156200533057878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b805169ffffffffffffffffffff81168114620037f657600080fd5b600080600080600060a086880312156200537457600080fd5b6200537f8662005340565b9450602086015193506040860151925060608601519150620053a46080870162005340565b90509295509295909350565b600060208284031215620053c357600080fd5b5051919050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161562005405576200540562004760565b500290565b60ff818116838216019081111562002a835762002a8362004760565b8284823760008382016000815283516200544581836020880162004265565b0195945050505050565b600063ffffffff8083168185168183048111821515161562005475576200547562004760565b02949350505050565b60008060008060008060c087890312156200549857600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b60008262005500577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe60c060405234801561001057600080fd5b506040516105dd3803806105dd83398101604081905261002f91610073565b600080546001600160a01b0319166001600160a01b039283161790551660805260a0526100af565b80516001600160a01b038116811461006e57600080fd5b919050565b60008060006060848603121561008857600080fd5b8351925061009860208501610057565b91506100a660408501610057565b90509250925092565b60805160a0516105026100db600039600061014c015260008181610177015261028901526105026000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c806379188d161161005057806379188d161461011d5780638ee489b214610147578063f00e6a2a1461017557600080fd5b8063181f5a77146100775780631a5da6c8146100c95780635ab1bd53146100de575b600080fd5b6100b36040518060400160405280601981526020017f4175746f6d6174696f6e466f7277617264657220312e302e300000000000000081525081565b6040516100c09190610304565b60405180910390f35b6100dc6100d7366004610370565b61019b565b005b60005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100c0565b61013061012b3660046103dc565b610233565b6040805192151583526020830191909152016100c0565b6040517f000000000000000000000000000000000000000000000000000000000000000081526020016100c0565b7f00000000000000000000000000000000000000000000000000000000000000006100f8565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ec576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60008054819073ffffffffffffffffffffffffffffffffffffffff163314610287576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f00000000000000000000000000000000000000000000000000000000000000005a91505a6113888110156102bb57600080fd5b6113888103905085604082048203116102d357600080fd5b50803b6102df57600080fd5b6000808551602087016000858af192505a6102fa90836104b5565b9150509250929050565b600060208083528351808285015260005b8181101561033157858101830151858201604001528201610315565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60006020828403121561038257600080fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146103a657600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080604083850312156103ef57600080fd5b82359150602083013567ffffffffffffffff8082111561040e57600080fd5b818501915085601f83011261042257600080fd5b813581811115610434576104346103ad565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561047a5761047a6103ad565b8160405282815288602084870101111561049357600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b818103818111156104ef577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea164736f6c6343000810000a307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101206040523480156200001257600080fd5b506040516200629c3803806200629c833981016040819052620000359162000374565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b91906200039b565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000100919062000374565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000165919062000374565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca919062000374565b3380600081620002215760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000254576200025481620002b0565b5050508360028111156200026c576200026c620003be565b60e0816002811115620002835762000283620003be565b9052506001600160a01b0392831660805290821660a052811660c052919091166101005250620003d49050565b336001600160a01b038216036200030a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000218565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200037157600080fd5b50565b6000602082840312156200038757600080fd5b815162000394816200035b565b9392505050565b600060208284031215620003ae57600080fd5b8151600381106200039457600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051615e606200043c6000396000818161010e01526101a90152600081816134db01528181613711015281816139590152613b010152600061308501526000613169015260008181611d1301526122e60152615e606000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806385c1b0ba11620000a5578063c8048022116200006f578063c804802214620002b7578063ce7dc5b414620002ce578063f2fde38b14620002e5578063f7d334ba14620002fc576200010c565b806385c1b0ba14620002535780638da5cb5b146200026a5780638e86139b1462000289578063948108f714620002a0576200010c565b80634ee88d3511620000e75780634ee88d3514620001ef5780636ded9eae146200020657806371791aa0146200021d57806379ba50971462000249576200010c565b806328f32f38146200015457806329c5efad146200017e578063349e8cca14620001a7575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e8080156200014d573d6000f35b3d6000fd5b005b6200016b6200016536600462004175565b62000313565b6040519081526020015b60405180910390f35b620001956200018f3660046200425b565b62000636565b60405162000175949392919062004383565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000175565b6200015262000200366004620043c0565b62000878565b6200016b6200021736600462004410565b620008e0565b620002346200022e3660046200425b565b62000946565b604051620001759796959493929190620044c3565b6200015262001020565b620001526200026436600462004515565b62001123565b60005473ffffffffffffffffffffffffffffffffffffffff16620001c9565b620001526200029a366004620045a2565b62001d94565b62000152620002b136600462004605565b62002114565b62000152620002c836600462004634565b620023b6565b62000195620002df3660046200470a565b6200278c565b62000152620002f636600462004781565b6200285c565b620002346200030d36600462004634565b62002874565b6000805473ffffffffffffffffffffffffffffffffffffffff16331480159062000347575062000345600933620028b2565b155b156200037f576040517fd48b678b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200038a86620028e6565b90506000818a306040516200039f9062003f1f565b92835273ffffffffffffffffffffffffffffffffffffffff9182166020840152166040820152606001604051809103906000f080158015620003e5573d6000803e3d6000fd5b509050620004c9826040518061010001604052806000151581526020018c63ffffffff16815260200163ffffffff801681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff168152602001600063ffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff168152508a89898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915062002a8a9050565b6014805474010000000000000000000000000000000000000000900463ffffffff169080620004f883620047d0565b91906101000a81548163ffffffff021916908363ffffffff16021790555050817fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d0128a8a6040516200057192919063ffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2817fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8787604051620005ad9291906200483f565b60405180910390a2817f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d566485604051620005e7919062004855565b60405180910390a2817f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508460405162000621919062004855565b60405180910390a25098975050505050505050565b600060606000806200064762002ec3565b60008681526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff91810482169483019490945265010000000000840481169482019490945273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009093048316606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490931660c0840152600201541660e08201525a60e0820151601454604051929450600092839273ffffffffffffffffffffffffffffffffffffffff16916c01000000000000000000000000900463ffffffff169062000767908b906200486a565b60006040518083038160008787f1925050503d8060008114620007a7576040519150601f19603f3d011682016040523d82523d6000602084013e620007ac565b606091505b50915091505a620007be908562004888565b935081620007e95760006040518060200160405280600081525060079650965096505050506200086f565b80806020019051810190620007ff9190620048f9565b9097509550866200082d5760006040518060200160405280600081525060049650965096505050506200086f565b601554865164010000000090910463ffffffff1610156200086b5760006040518060200160405280600081525060059650965096505050506200086f565b5050505b92959194509250565b620008838362002efe565b6000838152601a602052604090206200089e828483620049ee565b50827f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d56648383604051620008d39291906200483f565b60405180910390a2505050565b60006200093a88888860008989604051806020016040528060008152508a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506200031392505050565b98975050505050505050565b6000606060008060008060006200095c62002ec3565b6000620009698a62002fb4565b905060006012604051806101200160405290816000820160009054906101000a900460ff1660ff1660ff1681526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900462ffffff1662ffffff1662ffffff16815260200160008201600c9054906101000a900461ffff1661ffff1661ffff16815260200160008201600e9054906101000a900460ff1615151515815260200160008201600f9054906101000a900460ff161515151581526020016000820160109054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090506000600460008d8152602001908152602001600020604051806101000160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160018201600c9054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020016001820160189054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152505090508160a001511562000ce4576000604051806020016040528060008152506009600084602001516000808263ffffffff169250995099509950995099509950995050505062001014565b604081015163ffffffff9081161462000d35576000604051806020016040528060008152506001600084602001516000808263ffffffff169250995099509950995099509950995050505062001014565b80511562000d7b576000604051806020016040528060008152506002600084602001516000808263ffffffff169250995099509950995099509950995050505062001014565b62000d868262003062565b602083015160155492975090955060009162000db8918591879190640100000000900463ffffffff168a8a8762003254565b9050806bffffffffffffffffffffffff168260a001516bffffffffffffffffffffffff16101562000e22576000604051806020016040528060008152506006600085602001516000808263ffffffff1692509a509a509a509a509a509a509a505050505062001014565b600062000e318e868f620032a5565b90505a60e0840151601454604051929b50600092839273ffffffffffffffffffffffffffffffffffffffff16916c01000000000000000000000000900463ffffffff169062000e829086906200486a565b60006040518083038160008787f1925050503d806000811462000ec2576040519150601f19603f3d011682016040523d82523d6000602084013e62000ec7565b606091505b50915091505a62000ed9908c62004888565b9a508162000f595760155481516801000000000000000090910463ffffffff16101562000f3657505060408051602080820190925260008082529490910151939c509a50600899505063ffffffff90911695506200101492505050565b602090940151939b5060039a505063ffffffff9092169650620010149350505050565b8080602001905181019062000f6f9190620048f9565b909e509c508d62000fb057505060408051602080820190925260008082529490910151939c509a50600499505063ffffffff90911695506200101492505050565b6015548d5164010000000090910463ffffffff1610156200100157505060408051602080820190925260008082529490910151939c509a50600599505063ffffffff90911695506200101492505050565b505050506020015163ffffffff16945050505b92959891949750929550565b60015473ffffffffffffffffffffffffffffffffffffffff163314620010a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600173ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff16600381111562001162576200116262004318565b14158015620011ae5750600373ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff166003811115620011ab57620011ab62004318565b14155b15620011e6576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1662001246576040517fd12d7d8d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082900362001282576040517f2c2fc94100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805161010081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526000808567ffffffffffffffff811115620012e157620012e162004022565b6040519080825280602002602001820160405280156200130b578160200160208202803683370190505b50905060008667ffffffffffffffff8111156200132c576200132c62004022565b604051908082528060200260200182016040528015620013bb57816020015b604080516101008101825260008082526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816200134b5790505b50905060008767ffffffffffffffff811115620013dc57620013dc62004022565b6040519080825280602002602001820160405280156200141157816020015b6060815260200190600190039081620013fb5790505b50905060008867ffffffffffffffff81111562001432576200143262004022565b6040519080825280602002602001820160405280156200146757816020015b6060815260200190600190039081620014515790505b50905060008967ffffffffffffffff81111562001488576200148862004022565b604051908082528060200260200182016040528015620014bd57816020015b6060815260200190600190039081620014a75790505b50905060005b8a81101562001ad8578b8b82818110620014e157620014e162004b16565b6020908102929092013560008181526004845260409081902081516101008082018452825460ff81161515835263ffffffff91810482169783019790975265010000000000870481169382019390935273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009096048616606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490921660c08301526002015490931660e08401529a50909850620015cd90508962002efe565b60608801516040517f1a5da6c800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c8116600483015290911690631a5da6c890602401600060405180830381600087803b1580156200163d57600080fd5b505af115801562001652573d6000803e3d6000fd5b50505050878582815181106200166c576200166c62004b16565b6020026020010181905250600560008a815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868281518110620016c057620016c062004b16565b73ffffffffffffffffffffffffffffffffffffffff90921660209283029190910182015260008a81526007909152604090208054620016ff9062004946565b80601f01602080910402602001604051908101604052809291908181526020018280546200172d9062004946565b80156200177e5780601f1062001752576101008083540402835291602001916200177e565b820191906000526020600020905b8154815290600101906020018083116200176057829003601f168201915b505050505084828151811062001798576200179862004b16565b6020026020010181905250601a60008a81526020019081526020016000208054620017c39062004946565b80601f0160208091040260200160405190810160405280929190818152602001828054620017f19062004946565b8015620018425780601f10620018165761010080835404028352916020019162001842565b820191906000526020600020905b8154815290600101906020018083116200182457829003601f168201915b50505050508382815181106200185c576200185c62004b16565b6020026020010181905250601b60008a81526020019081526020016000208054620018879062004946565b80601f0160208091040260200160405190810160405280929190818152602001828054620018b59062004946565b8015620019065780601f10620018da5761010080835404028352916020019162001906565b820191906000526020600020905b815481529060010190602001808311620018e857829003601f168201915b505050505082828151811062001920576200192062004b16565b60200260200101819052508760a001516bffffffffffffffffffffffff16876200194b919062004b45565b60008a815260046020908152604080832080547fffffff00000000000000000000000000000000000000000000000000000000001681556001810180547fffffffff0000000000000000000000000000000000000000000000000000000016905560020180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560079091528120919850620019eb919062003f2d565b6000898152601a6020526040812062001a049162003f2d565b6000898152601b6020526040812062001a1d9162003f2d565b600089815260066020526040902080547fffffffffffffffffffffffff000000000000000000000000000000000000000016905562001a5e60028a620034c7565b5060a0880151604080516bffffffffffffffffffffffff909216825273ffffffffffffffffffffffffffffffffffffffff8c1660208301528a917fb38647142fbb1ea4c000fc4569b37a4e9a9f6313317b84ee3e5326c1a6cd06ff910160405180910390a28062001acf8162004b5b565b915050620014c3565b508560185462001ae9919062004888565b60185560405160009062001b0e908d908d9088908a9089908990899060200162004c42565b60405160208183030381529060405290508973ffffffffffffffffffffffffffffffffffffffff16638e86139b6013600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c71249ab60038e73ffffffffffffffffffffffffffffffffffffffff1663aab9edd66040518163ffffffff1660e01b8152600401602060405180830381865afa15801562001bca573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001bf0919062004dbc565b866040518463ffffffff1660e01b815260040162001c119392919062004de1565b600060405180830381865afa15801562001c2f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405262001c77919081019062004e08565b6040518263ffffffff1660e01b815260040162001c95919062004855565b600060405180830381600087803b15801562001cb057600080fd5b505af115801562001cc5573d6000803e3d6000fd5b50506040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d81166004830152602482018b90527f000000000000000000000000000000000000000000000000000000000000000016925063a9059cbb91506044016020604051808303816000875af115801562001d5f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001d85919062004e41565b50505050505050505050505050565b60023360009081526019602052604090205460ff16600381111562001dbd5762001dbd62004318565b1415801562001df3575060033360009081526019602052604090205460ff16600381111562001df05762001df062004318565b14155b1562001e2b576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808080808062001e408789018962005041565b95509550955095509550955060005b86518110156200210957600073ffffffffffffffffffffffffffffffffffffffff1686828151811062001e865762001e8662004b16565b60200260200101516060015173ffffffffffffffffffffffffffffffffffffffff160362001f965786818151811062001ec35762001ec362004b16565b602002602001015186828151811062001ee05762001ee062004b16565b602002602001015160e001513060405162001efb9062003f1f565b92835273ffffffffffffffffffffffffffffffffffffffff9182166020840152166040820152606001604051809103906000f08015801562001f41573d6000803e3d6000fd5b5086828151811062001f575762001f5762004b16565b60200260200101516060019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505b6200204e87828151811062001faf5762001faf62004b16565b602002602001015187838151811062001fcc5762001fcc62004b16565b602002602001015187848151811062001fe95762001fe962004b16565b602002602001015187858151811062002006576200200662004b16565b602002602001015187868151811062002023576200202362004b16565b602002602001015187878151811062002040576200204062004b16565b602002602001015162002a8a565b86818151811062002063576200206362004b16565b60200260200101517f74931a144e43a50694897f241d973aecb5024c0e910f9bb80a163ea3c1cf5a71878381518110620020a157620020a162004b16565b602002602001015160a0015133604051620020ec9291906bffffffffffffffffffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a280620021008162004b5b565b91505062001e4f565b505050505050505050565b60008281526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff918104821694830194909452650100000000008404811694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009094048416606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490921660e083015290911462002221576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160a0015162002233919062005149565b600084815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff938416021790556018546200229b9184169062004b45565b6018556040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526bffffffffffffffffffffffff831660448201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906323b872dd906064016020604051808303816000875af115801562002345573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200236b919062004e41565b506040516bffffffffffffffffffffffff83168152339084907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a3505050565b600081815260046020908152604080832081516101008082018452825460ff81161515835263ffffffff918104821695830195909552650100000000008504811693820184905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009095048516606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490931660e0840152919291141590620024ae60005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16149050818015620025095750808015620025075750620024fa620034d5565b836040015163ffffffff16115b155b1562002541576040517ffbc0357800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8015801562002574575060008481526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314155b15620025ac576040517ffbdb8e5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000620025b8620034d5565b905081620025d057620025cd60328262004b45565b90505b6000858152600460205260409020805463ffffffff80841665010000000000027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff909216919091179091556200262c906002908790620034c716565b5060135460808501516bffffffffffffffffffffffff91821691600091168211156200269557608086015162002663908362005171565b90508560a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111562002695575060a08501515b808660a00151620026a7919062005171565b600088815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff938416021790556014546200270f9183911662005149565b601480547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9290921691909117905560405167ffffffffffffffff84169088907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a350505050505050565b600060606000806200279d62002ec3565b6000634b56a42e60e01b888888604051602401620027be9392919062005199565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152905062002849898262000636565b929c919b50995090975095505050505050565b6200286662003591565b620028718162003614565b50565b6000606060008060008060006200289b886040518060200160405280600081525062000946565b959e949d50929b5090995097509550909350915050565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b90505b92915050565b60008060006200290d6001620028fb620034d5565b62002907919062004888565b6200370b565b601454604080516020810193909352309083015274010000000000000000000000000000000000000000900463ffffffff166060820152608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201209083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060045b600f81101562002a195782828281518110620029d557620029d562004b16565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508062002a108162004b5b565b915050620029b5565b5083600181111562002a2f5762002a2f62004318565b60f81b81600f8151811062002a485762002a4862004b16565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535062002a8281620051cd565b949350505050565b6012546e010000000000000000000000000000900460ff161562002ada576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e085015173ffffffffffffffffffffffffffffffffffffffff163b62002b2d576040517f09ee12d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601554835163ffffffff909116101562002b73576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108fc856020015163ffffffff16108062002bb15750601454602086015163ffffffff70010000000000000000000000000000000090920482169116115b1562002be9576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008681526004602052604090206002015473ffffffffffffffffffffffffffffffffffffffff161562002c49576040517f6e3b930b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600086815260046020908152604080832088518154848b0151848c015160608d015173ffffffffffffffffffffffffffffffffffffffff9081166901000000000000000000027fffffff0000000000000000000000000000000000000000ffffffffffffffffff63ffffffff9384166501000000000002167fffffff000000000000000000000000000000000000000000000000ffffffffff948416610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff971515979097167fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009096169590951795909517929092169290921792909217835560808b015160018401805460a08e015160c08f01519094167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff6bffffffffffffffffffffffff9586166c01000000000000000000000000027fffffffffffffffff0000000000000000000000000000000000000000000000009093169590941694909417179190911691909117905560e08a0151600290920180549282167fffffffffffffffffffffffff0000000000000000000000000000000000000000938416179055600584528285208054918a16919092161790556007909152902062002e51848262005210565b508460a001516bffffffffffffffffffffffff1660185462002e74919062004b45565b6018556000868152601a6020526040902062002e91838262005210565b506000868152601b6020526040902062002eac828262005210565b5062002eba60028762003873565b50505050505050565b321562002efc576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff16331462002f5c576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff9081161462002871576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f81101562003049577fff00000000000000000000000000000000000000000000000000000000000000821683826020811062002ffd5762002ffd62004b16565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146200303457506000949350505050565b80620030408162004b5b565b91505062002fbb565b5081600f1a600181111562002a825762002a8262004318565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015620030ef573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003115919062005352565b50945090925050506000811315806200312d57508142105b8062003152575082801562003152575062003149824262004888565b8463ffffffff16105b156200316357601654955062003167565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015620031d3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620031f9919062005352565b50945090925050506000811315806200321157508142105b806200323657508280156200323657506200322d824262004888565b8463ffffffff16105b15620032475760175494506200324b565b8094505b50505050915091565b6000806200326888878b6000015162003881565b9050600080620032858b8a63ffffffff16858a8a60018b62003920565b909250905062003296818362005149565b9b9a5050505050505050505050565b60606000836001811115620032be57620032be62004318565b036200338b576000848152600760205260409081902090517f6e04ff0d000000000000000000000000000000000000000000000000000000009162003306916024016200544a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091529050620034c0565b6001836001811115620033a257620033a262004318565b036200348e57600082806020019051810190620033c09190620054ce565b6000868152600760205260409081902090519192507f40691db4000000000000000000000000000000000000000000000000000000009162003407918491602401620055e2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091529150620034c09050565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b6000620028dd838362003dc2565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156200350e576200350e62004318565b036200358c57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003561573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620035879190620056aa565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331462002efc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016200109e565b3373ffffffffffffffffffffffffffffffffffffffff82160362003695576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200109e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111562003744576200374462004318565b0362003869576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003799573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620037bf9190620056aa565b90508083101580620037dd5750610100620037db848362004888565b115b15620037ec5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa15801562003843573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620034c09190620056aa565b504090565b919050565b6000620028dd838362003ecd565b600080808560018111156200389a576200389a62004318565b03620038ab575062015f90620038ce565b6001856001811115620038c257620038c262004318565b036200348e57506201adb05b620038e163ffffffff85166014620056c4565b620038ee84600162005704565b620038ff9060ff16611d4c620056c4565b6200390b908362004b45565b62003917919062004b45565b95945050505050565b6000806000896080015161ffff16876200393b9190620056c4565b90508380156200394a5750803a105b156200395357503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156200398c576200398c62004318565b0362003afd576040805160008152602081019091528515620039f05760003660405180608001604052806048815260200162005e0c60489139604051602001620039d99392919062005720565b604051602081830303815290604052905062003a5e565b60155462003a0e90640100000000900463ffffffff16600462005749565b63ffffffff1667ffffffffffffffff81111562003a2f5762003a2f62004022565b6040519080825280601f01601f19166020018201604052801562003a5a576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9062003ab090849060040162004855565b602060405180830381865afa15801562003ace573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003af49190620056aa565b91505062003c67565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111562003b345762003b3462004318565b0362003c6757841562003bbc57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003b8e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003bb49190620056aa565b905062003c67565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801562003c0b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c31919062005778565b505060155492945062003c5693505050640100000000900463ffffffff1682620056c4565b62003c63906010620056c4565b9150505b8462003c8657808b6080015161ffff1662003c839190620056c4565b90505b62003c9661ffff871682620057c3565b90506000878262003ca88c8e62004b45565b62003cb49086620056c4565b62003cc0919062004b45565b62003cd490670de0b6b3a7640000620056c4565b62003ce09190620057c3565b905060008c6040015163ffffffff1664e8d4a5100062003d019190620056c4565b898e6020015163ffffffff16858f8862003d1c9190620056c4565b62003d28919062004b45565b62003d3890633b9aca00620056c4565b62003d449190620056c4565b62003d509190620057c3565b62003d5c919062004b45565b90506b033b2e3c9fd0803ce800000062003d77828462004b45565b111562003db0576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000818152600183016020526040812054801562003ebb57600062003de960018362004888565b855490915060009062003dff9060019062004888565b905081811462003e6b57600086600001828154811062003e235762003e2362004b16565b906000526020600020015490508087600001848154811062003e495762003e4962004b16565b6000918252602080832090910192909255918252600188019052604090208390555b855486908062003e7f5762003e7f620057ff565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050620028e0565b6000915050620028e0565b5092915050565b600081815260018301602052604081205462003f1657508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155620028e0565b506000620028e0565b6105dd806200582f83390190565b50805462003f3b9062004946565b6000825580601f1062003f4c575050565b601f0160209004906000526020600020908101906200287191905b8082111562003f7d576000815560010162003f67565b5090565b73ffffffffffffffffffffffffffffffffffffffff811681146200287157600080fd5b80356200386e8162003f81565b803563ffffffff811681146200386e57600080fd5b8035600281106200386e57600080fd5b60008083601f84011262003fe957600080fd5b50813567ffffffffffffffff8111156200400257600080fd5b6020830191508360208285010111156200401b57600080fd5b9250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610100810167ffffffffffffffff8111828210171562004078576200407862004022565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715620040c857620040c862004022565b604052919050565b600067ffffffffffffffff821115620040ed57620040ed62004022565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f8301126200412b57600080fd5b8135620041426200413c82620040d0565b6200407e565b8181528460208386010111156200415857600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060e0898b0312156200419257600080fd5b88356200419f8162003f81565b9750620041af60208a0162003fb1565b96506040890135620041c18162003f81565b9550620041d160608a0162003fc6565b9450608089013567ffffffffffffffff80821115620041ef57600080fd5b620041fd8c838d0162003fd6565b909650945060a08b01359150808211156200421757600080fd5b620042258c838d0162004119565b935060c08b01359150808211156200423c57600080fd5b506200424b8b828c0162004119565b9150509295985092959890939650565b600080604083850312156200426f57600080fd5b82359150602083013567ffffffffffffffff8111156200428e57600080fd5b6200429c8582860162004119565b9150509250929050565b60005b83811015620042c3578181015183820152602001620042a9565b50506000910152565b60008151808452620042e6816020860160208601620042a6565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600a81106200437f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b8415158152608060208201526000620043a06080830186620042cc565b9050620043b1604083018562004347565b82606083015295945050505050565b600080600060408486031215620043d657600080fd5b83359250602084013567ffffffffffffffff811115620043f557600080fd5b620044038682870162003fd6565b9497909650939450505050565b600080600080600080600060a0888a0312156200442c57600080fd5b8735620044398162003f81565b9650620044496020890162003fb1565b955060408801356200445b8162003f81565b9450606088013567ffffffffffffffff808211156200447957600080fd5b620044878b838c0162003fd6565b909650945060808a0135915080821115620044a157600080fd5b50620044b08a828b0162003fd6565b989b979a50959850939692959293505050565b871515815260e060208201526000620044e060e0830189620042cc565b9050620044f1604083018862004347565b8560608301528460808301528360a08301528260c083015298975050505050505050565b6000806000604084860312156200452b57600080fd5b833567ffffffffffffffff808211156200454457600080fd5b818601915086601f8301126200455957600080fd5b8135818111156200456957600080fd5b8760208260051b85010111156200457f57600080fd5b60209283019550935050840135620045978162003f81565b809150509250925092565b60008060208385031215620045b657600080fd5b823567ffffffffffffffff811115620045ce57600080fd5b620045dc8582860162003fd6565b90969095509350505050565b80356bffffffffffffffffffffffff811681146200386e57600080fd5b600080604083850312156200461957600080fd5b823591506200462b60208401620045e8565b90509250929050565b6000602082840312156200464757600080fd5b5035919050565b600067ffffffffffffffff8211156200466b576200466b62004022565b5060051b60200190565b600082601f8301126200468757600080fd5b813560206200469a6200413c836200464e565b82815260059290921b84018101918181019086841115620046ba57600080fd5b8286015b84811015620046ff57803567ffffffffffffffff811115620046e05760008081fd5b620046f08986838b010162004119565b845250918301918301620046be565b509695505050505050565b600080600080606085870312156200472157600080fd5b84359350602085013567ffffffffffffffff808211156200474157600080fd5b6200474f8883890162004675565b945060408701359150808211156200476657600080fd5b50620047758782880162003fd6565b95989497509550505050565b6000602082840312156200479457600080fd5b8135620034c08162003f81565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff808316818103620047ec57620047ec620047a1565b6001019392505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60208152600062002a82602083018486620047f6565b602081526000620028dd6020830184620042cc565b600082516200487e818460208701620042a6565b9190910192915050565b81810381811115620028e057620028e0620047a1565b80151581146200287157600080fd5b600082601f830112620048bf57600080fd5b8151620048d06200413c82620040d0565b818152846020838601011115620048e657600080fd5b62002a82826020830160208701620042a6565b600080604083850312156200490d57600080fd5b82516200491a816200489e565b602084015190925067ffffffffffffffff8111156200493857600080fd5b6200429c85828601620048ad565b600181811c908216806200495b57607f821691505b60208210810362004995577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115620049e957600081815260208120601f850160051c81016020861015620049c45750805b601f850160051c820191505b81811015620049e557828155600101620049d0565b5050505b505050565b67ffffffffffffffff83111562004a095762004a0962004022565b62004a218362004a1a835462004946565b836200499b565b6000601f84116001811462004a76576000851562004a3f5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835562004b0f565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101562004ac7578685013582556020948501946001909201910162004aa5565b508682101562004b03577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b80820180821115620028e057620028e0620047a1565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362004b8f5762004b8f620047a1565b5060010190565b600081518084526020808501945080840160005b8381101562004bde57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010162004baa565b509495945050505050565b600081518084526020808501808196508360051b8101915082860160005b8581101562004c3557828403895262004c22848351620042cc565b9885019893509084019060010162004c07565b5091979650505050505050565b600060c0808352888184015260e07f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8a111562004c7e57600080fd5b8960051b808c83870137840184810382016020808701919091528a518383018190528b82019261010092919083019060005b8181101562004d515785518051151584528481015163ffffffff9081168686015260408083015182169086015260608083015173ffffffffffffffffffffffffffffffffffffffff908116918701919091526080808401516bffffffffffffffffffffffff9081169188019190915260a080850151909116908701528a8301519091168a860152908801511687840152948301949184019160010162004cb0565b5050878103604089015262004d67818d62004b96565b95505050505050828103606084015262004d82818762004be9565b9050828103608084015262004d98818662004be9565b905082810360a084015262004dae818562004be9565b9a9950505050505050505050565b60006020828403121562004dcf57600080fd5b815160ff81168114620034c057600080fd5b60ff8416815260ff83166020820152606060408201526000620039176060830184620042cc565b60006020828403121562004e1b57600080fd5b815167ffffffffffffffff81111562004e3357600080fd5b62002a8284828501620048ad565b60006020828403121562004e5457600080fd5b8151620034c0816200489e565b600082601f83011262004e7357600080fd5b8135602062004e866200413c836200464e565b82815260059290921b8401810191818101908684111562004ea657600080fd5b8286015b84811015620046ff578035835291830191830162004eaa565b600082601f83011262004ed557600080fd5b8135602062004ee86200413c836200464e565b82815260089290921b8401810191818101908684111562004f0857600080fd5b8286015b84811015620046ff57610100818903121562004f285760008081fd5b62004f3262004051565b813562004f3f816200489e565b815262004f4e82860162003fb1565b85820152604062004f6181840162003fb1565b90820152606062004f7483820162003fa4565b90820152608062004f87838201620045e8565b9082015260a062004f9a838201620045e8565b9082015260c062004fad83820162003fb1565b9082015260e062004fc083820162003fa4565b908201528352918301916101000162004f0c565b600082601f83011262004fe657600080fd5b8135602062004ff96200413c836200464e565b82815260059290921b840181019181810190868411156200501957600080fd5b8286015b84811015620046ff578035620050338162003f81565b83529183019183016200501d565b60008060008060008060c087890312156200505b57600080fd5b863567ffffffffffffffff808211156200507457600080fd5b620050828a838b0162004e61565b975060208901359150808211156200509957600080fd5b620050a78a838b0162004ec3565b96506040890135915080821115620050be57600080fd5b620050cc8a838b0162004fd4565b95506060890135915080821115620050e357600080fd5b620050f18a838b0162004675565b945060808901359150808211156200510857600080fd5b620051168a838b0162004675565b935060a08901359150808211156200512d57600080fd5b506200513c89828a0162004675565b9150509295509295509295565b6bffffffffffffffffffffffff81811683821601908082111562003ec65762003ec6620047a1565b6bffffffffffffffffffffffff82811682821603908082111562003ec65762003ec6620047a1565b604081526000620051ae604083018662004be9565b8281036020840152620051c3818587620047f6565b9695505050505050565b8051602080830151919081101562004995577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60209190910360031b1b16919050565b815167ffffffffffffffff8111156200522d576200522d62004022565b62005245816200523e845462004946565b846200499b565b602080601f8311600181146200529b5760008415620052645750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555620049e5565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015620052ea57888601518255948401946001909101908401620052c9565b50858210156200532757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b805169ffffffffffffffffffff811681146200386e57600080fd5b600080600080600060a086880312156200536b57600080fd5b620053768662005337565b94506020860151935060408601519250606086015191506200539b6080870162005337565b90509295509295909350565b60008154620053b68162004946565b808552602060018381168015620053d657600181146200540f576200543f565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b89010195506200543f565b866000528260002060005b85811015620054375781548a82018601529083019084016200541a565b890184019650505b505050505092915050565b602081526000620028dd6020830184620053a7565b80516200386e8162003f81565b600082601f8301126200547e57600080fd5b81516020620054916200413c836200464e565b82815260059290921b84018101918181019086841115620054b157600080fd5b8286015b84811015620046ff5780518352918301918301620054b5565b600060208284031215620054e157600080fd5b815167ffffffffffffffff80821115620054fa57600080fd5b9083019061010082860312156200551057600080fd5b6200551a62004051565b82518152602083015160208201526040830151604082015260608301516060820152608083015160808201526200555460a084016200545f565b60a082015260c0830151828111156200556c57600080fd5b6200557a878286016200546c565b60c08301525060e0830151828111156200559357600080fd5b620055a187828601620048ad565b60e08301525095945050505050565b600081518084526020808501945080840160005b8381101562004bde57815187529582019590820190600101620055c4565b60408152825160408201526020830151606082015260408301516080820152606083015160a0820152608083015160c082015273ffffffffffffffffffffffffffffffffffffffff60a08401511660e0820152600060c084015161010080818501525062005655610140840182620055b0565b905060e08501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc084830301610120850152620056938282620042cc565b9150508281036020840152620039178185620053a7565b600060208284031215620056bd57600080fd5b5051919050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615620056ff57620056ff620047a1565b500290565b60ff8181168382160190811115620028e057620028e0620047a1565b8284823760008382016000815283516200573f818360208801620042a6565b0195945050505050565b600063ffffffff808316818516818304811182151516156200576f576200576f620047a1565b02949350505050565b60008060008060008060c087890312156200579257600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082620057fa577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe60c060405234801561001057600080fd5b506040516105dd3803806105dd83398101604081905261002f91610073565b600080546001600160a01b0319166001600160a01b039283161790551660805260a0526100af565b80516001600160a01b038116811461006e57600080fd5b919050565b60008060006060848603121561008857600080fd5b8351925061009860208501610057565b91506100a660408501610057565b90509250925092565b60805160a0516105026100db600039600061014c015260008181610177015261028901526105026000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c806379188d161161005057806379188d161461011d5780638ee489b214610147578063f00e6a2a1461017557600080fd5b8063181f5a77146100775780631a5da6c8146100c95780635ab1bd53146100de575b600080fd5b6100b36040518060400160405280601981526020017f4175746f6d6174696f6e466f7277617264657220312e302e300000000000000081525081565b6040516100c09190610304565b60405180910390f35b6100dc6100d7366004610370565b61019b565b005b60005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100c0565b61013061012b3660046103dc565b610233565b6040805192151583526020830191909152016100c0565b6040517f000000000000000000000000000000000000000000000000000000000000000081526020016100c0565b7f00000000000000000000000000000000000000000000000000000000000000006100f8565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ec576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60008054819073ffffffffffffffffffffffffffffffffffffffff163314610287576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f00000000000000000000000000000000000000000000000000000000000000005a91505a6113888110156102bb57600080fd5b6113888103905085604082048203116102d357600080fd5b50803b6102df57600080fd5b6000808551602087016000858af192505a6102fa90836104b5565b9150509250929050565b600060208083528351808285015260005b8181101561033157858101830151858201604001528201610315565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60006020828403121561038257600080fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146103a657600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080604083850312156103ef57600080fd5b82359150602083013567ffffffffffffffff8082111561040e57600080fd5b818501915085601f83011261042257600080fd5b813581811115610434576104346103ad565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561047a5761047a6103ad565b8160405282815288602084870101111561049357600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b818103818111156104ef577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea164736f6c6343000810000a307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryLogicAABI = KeeperRegistryLogicAMetaData.ABI @@ -263,16 +263,16 @@ func (_KeeperRegistryLogicA *KeeperRegistryLogicATransactorSession) CheckCallbac return _KeeperRegistryLogicA.Contract.CheckCallback(&_KeeperRegistryLogicA.TransactOpts, id, values, extraData) } -func (_KeeperRegistryLogicA *KeeperRegistryLogicATransactor) CheckUpkeep(opts *bind.TransactOpts, id *big.Int, checkData []byte) (*types.Transaction, error) { - return _KeeperRegistryLogicA.contract.Transact(opts, "checkUpkeep", id, checkData) +func (_KeeperRegistryLogicA *KeeperRegistryLogicATransactor) CheckUpkeep(opts *bind.TransactOpts, id *big.Int, triggerData []byte) (*types.Transaction, error) { + return _KeeperRegistryLogicA.contract.Transact(opts, "checkUpkeep", id, triggerData) } -func (_KeeperRegistryLogicA *KeeperRegistryLogicASession) CheckUpkeep(id *big.Int, checkData []byte) (*types.Transaction, error) { - return _KeeperRegistryLogicA.Contract.CheckUpkeep(&_KeeperRegistryLogicA.TransactOpts, id, checkData) +func (_KeeperRegistryLogicA *KeeperRegistryLogicASession) CheckUpkeep(id *big.Int, triggerData []byte) (*types.Transaction, error) { + return _KeeperRegistryLogicA.Contract.CheckUpkeep(&_KeeperRegistryLogicA.TransactOpts, id, triggerData) } -func (_KeeperRegistryLogicA *KeeperRegistryLogicATransactorSession) CheckUpkeep(id *big.Int, checkData []byte) (*types.Transaction, error) { - return _KeeperRegistryLogicA.Contract.CheckUpkeep(&_KeeperRegistryLogicA.TransactOpts, id, checkData) +func (_KeeperRegistryLogicA *KeeperRegistryLogicATransactorSession) CheckUpkeep(id *big.Int, triggerData []byte) (*types.Transaction, error) { + return _KeeperRegistryLogicA.Contract.CheckUpkeep(&_KeeperRegistryLogicA.TransactOpts, id, triggerData) } func (_KeeperRegistryLogicA *KeeperRegistryLogicATransactor) CheckUpkeep0(opts *bind.TransactOpts, id *big.Int) (*types.Transaction, error) { @@ -4518,7 +4518,7 @@ type KeeperRegistryLogicAInterface interface { CheckCallback(opts *bind.TransactOpts, id *big.Int, values [][]byte, extraData []byte) (*types.Transaction, error) - CheckUpkeep(opts *bind.TransactOpts, id *big.Int, checkData []byte) (*types.Transaction, error) + CheckUpkeep(opts *bind.TransactOpts, id *big.Int, triggerData []byte) (*types.Transaction, error) CheckUpkeep0(opts *bind.TransactOpts, id *big.Int) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go b/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go index 4f9ae538bb9..dee841e4a29 100644 --- a/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go +++ b/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go @@ -42,8 +42,8 @@ type Log struct { } var LogTriggeredFeedLookupMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useArbitrumBlockNum\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"verified\",\"type\":\"bytes\"}],\"name\":\"PerformingLogTriggerUpkeep\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParam\",\"type\":\"string\"}],\"name\":\"setFeedParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"timeParam\",\"type\":\"string\"}],\"name\":\"setTimeParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x610120604052604260a08181526080918291906200147560c03990526200002a9060019081620000d4565b506040805180820190915260098152680cccacac892c890caf60bb1b60208201526002906200005a908262000250565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b60208201526003906200008c908262000250565b503480156200009a57600080fd5b50604051620014b7380380620014b7833981016040819052620000bd916200031c565b6000805460ff191691151591909117905562000347565b8280548282559060005260206000209081019282156200011f579160200282015b828111156200011f57825182906200010e908262000250565b5091602001919060010190620000f5565b506200012d92915062000131565b5090565b808211156200012d57600062000148828262000152565b5060010162000131565b5080546200016090620001c1565b6000825580601f1062000171575050565b601f01602090049060005260206000209081019062000191919062000194565b50565b5b808211156200012d576000815560010162000195565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001d657607f821691505b602082108103620001f757634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200024b57600081815260208120601f850160051c81016020861015620002265750805b601f850160051c820191505b81811015620002475782815560010162000232565b5050505b505050565b81516001600160401b038111156200026c576200026c620001ab565b62000284816200027d8454620001c1565b84620001fd565b602080601f831160018114620002bc5760008415620002a35750858301515b600019600386901b1c1916600185901b17855562000247565b600085815260208120601f198616915b82811015620002ed57888601518255948401946001909101908401620002cc565b50858210156200030c5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156200032f57600080fd5b815180151581146200034057600080fd5b9392505050565b61111e80620003576000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80639525d57411610076578063afb28d1f1161005b578063afb28d1f14610178578063be61b77514610180578063c98f10b01461019357600080fd5b80639525d574146101455780639d6f1cc71461015857600080fd5b80634b56a42e116100a75780634b56a42e146100eb578063601d5a7114610115578063642f6cef1461012857600080fd5b806305e25131146100c35780634585e33b146100d8575b600080fd5b6100d66100d13660046108b3565b61019b565b005b6100d66100e6366004610969565b6101b2565b6100fe6100f93660046109db565b610254565b60405161010c929190610b13565b60405180910390f35b6100d6610123366004610b36565b6102aa565b6000546101359060ff1681565b604051901515815260200161010c565b6100d6610153366004610b36565b6102b6565b61016b610166366004610b6b565b6102c2565b60405161010c9190610b84565b61016b61036e565b6100fe61018e366004610b9e565b61037b565b61016b61062b565b80516101ae9060019060208401906106be565b5050565b6000806101c1838501856109db565b915091506000806000838060200190518101906101de9190610c03565b919450925090506060327f299a03817e683a32b21e29e3ae3c31f1c9c773f7d532836d116b62a9281fbc9d858585610214610638565b8b60008151811061022757610227610c38565b60200260200101518760405161024296959493929190610c67565b60405180910390a25050505050505050565b600060606000848460405160200161026d929190610cc7565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052600193509150505b9250929050565b60036101ae8282610dfd565b60026101ae8282610dfd565b600181815481106102d257600080fd5b9060005260206000200160009150905080546102ed90610d5b565b80601f016020809104026020016040519081016040528092919081815260200182805461031990610d5b565b80156103665780601f1061033b57610100808354040283529160200191610366565b820191906000526020600020905b81548152906001019060200180831161034957829003601f168201915b505050505081565b600280546102ed90610d5b565b600060606000610389610638565b90507fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd6103b960c0860186610f17565b60008181106103ca576103ca610c38565b90506020020135036105a35760006103e560c0860186610f17565b60018181106103f6576103f6610c38565b9050602002013560405160200161040f91815260200190565b60405160208183030381529060405290506000818060200190518101906104369190610f7f565b9050600061044760c0880188610f17565b600281811061045857610458610c38565b9050602002013560405160200161047191815260200190565b60405160208183030381529060405290506000818060200190518101906104989190610f7f565b905060006104a960c08a018a610f17565b60038181106104ba576104ba610c38565b905060200201356040516020016104d391815260200190565b60405160208183030381529060405290506000818060200190518101906104fa9190610f98565b604080516020810188905290810185905273ffffffffffffffffffffffffffffffffffffffff821660608201529091506002906001906003908a90608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e00000000000000000000000000000000000000000000000000000000825261059a959493929160040161104e565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f6700000000000000000000000000000000000000000000000000000000000000606482015260840161059a565b600380546102ed90610d5b565b6000805460ff16156106b957606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610690573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b49190610f7f565b905090565b504390565b828054828255906000526020600020908101928215610704579160200282015b8281111561070457825182906106f49082610dfd565b50916020019190600101906106de565b50610710929150610714565b5090565b808211156107105760006107288282610731565b50600101610714565b50805461073d90610d5b565b6000825580601f1061074d575050565b601f01602090049060005260206000209081019061076b919061076e565b50565b5b80821115610710576000815560010161076f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156107f9576107f9610783565b604052919050565b600067ffffffffffffffff82111561081b5761081b610783565b5060051b60200190565b600082601f83011261083657600080fd5b813567ffffffffffffffff81111561085057610850610783565b61088160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016107b2565b81815284602083860101111561089657600080fd5b816020850160208301376000918101602001919091529392505050565b600060208083850312156108c657600080fd5b823567ffffffffffffffff808211156108de57600080fd5b818501915085601f8301126108f257600080fd5b813561090561090082610801565b6107b2565b81815260059190911b8301840190848101908883111561092457600080fd5b8585015b8381101561095c578035858111156109405760008081fd5b61094e8b89838a0101610825565b845250918601918601610928565b5098975050505050505050565b6000806020838503121561097c57600080fd5b823567ffffffffffffffff8082111561099457600080fd5b818501915085601f8301126109a857600080fd5b8135818111156109b757600080fd5b8660208285010111156109c957600080fd5b60209290920196919550909350505050565b600080604083850312156109ee57600080fd5b823567ffffffffffffffff80821115610a0657600080fd5b818501915085601f830112610a1a57600080fd5b81356020610a2a61090083610801565b82815260059290921b84018101918181019089841115610a4957600080fd5b8286015b84811015610a8157803586811115610a655760008081fd5b610a738c86838b0101610825565b845250918301918301610a4d565b5096505086013592505080821115610a9857600080fd5b50610aa585828601610825565b9150509250929050565b6000815180845260005b81811015610ad557602081850181015186830182015201610ab9565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b8215158152604060208201526000610b2e6040830184610aaf565b949350505050565b600060208284031215610b4857600080fd5b813567ffffffffffffffff811115610b5f57600080fd5b610b2e84828501610825565b600060208284031215610b7d57600080fd5b5035919050565b602081526000610b976020830184610aaf565b9392505050565b600060208284031215610bb057600080fd5b813567ffffffffffffffff811115610bc757600080fd5b82016101008185031215610b9757600080fd5b805173ffffffffffffffffffffffffffffffffffffffff81168114610bfe57600080fd5b919050565b600080600060608486031215610c1857600080fd5b8351925060208401519150610c2f60408501610bda565b90509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b86815285602082015273ffffffffffffffffffffffffffffffffffffffff8516604082015283606082015260c060808201526000610ca860c0830185610aaf565b82810360a0840152610cba8185610aaf565b9998505050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610d3c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610d2a868351610aaf565b95509382019390820190600101610cf0565b505085840381870152505050610d528185610aaf565b95945050505050565b600181811c90821680610d6f57607f821691505b602082108103610da8577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115610df857600081815260208120601f850160051c81016020861015610dd55750805b601f850160051c820191505b81811015610df457828155600101610de1565b5050505b505050565b815167ffffffffffffffff811115610e1757610e17610783565b610e2b81610e258454610d5b565b84610dae565b602080601f831160018114610e7e5760008415610e485750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555610df4565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015610ecb57888601518255948401946001909101908401610eac565b5085821015610f0757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610f4c57600080fd5b83018035915067ffffffffffffffff821115610f6757600080fd5b6020019150600581901b36038213156102a357600080fd5b600060208284031215610f9157600080fd5b5051919050565b600060208284031215610faa57600080fd5b610b9782610bda565b60008154610fc081610d5b565b808552602060018381168015610fdd576001811461101557611043565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b8901019550611043565b866000528260002060005b8581101561103b5781548a8201860152908301908401611020565b890184019650505b505050505092915050565b60a08152600061106160a0830188610fb3565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b838110156110d3577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526110c18383610fb3565b94860194925060019182019101611088565b505086810360408801526110e7818b610fb3565b94505050505084606084015282810360808401526111058185610aaf565b9897505050505050505056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useArbitrumBlockNum\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"verified\",\"type\":\"bytes\"}],\"name\":\"PerformingLogTriggerUpkeep\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParam\",\"type\":\"string\"}],\"name\":\"setFeedParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"timeParam\",\"type\":\"string\"}],\"name\":\"setTimeParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x610120604052604260a08181526080918291906200148f60c03990526200002a9060019081620000d4565b506040805180820190915260098152680cccacac892c890caf60bb1b60208201526002906200005a908262000250565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b60208201526003906200008c908262000250565b503480156200009a57600080fd5b50604051620014d1380380620014d1833981016040819052620000bd916200031c565b6000805460ff191691151591909117905562000347565b8280548282559060005260206000209081019282156200011f579160200282015b828111156200011f57825182906200010e908262000250565b5091602001919060010190620000f5565b506200012d92915062000131565b5090565b808211156200012d57600062000148828262000152565b5060010162000131565b5080546200016090620001c1565b6000825580601f1062000171575050565b601f01602090049060005260206000209081019062000191919062000194565b50565b5b808211156200012d576000815560010162000195565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001d657607f821691505b602082108103620001f757634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200024b57600081815260208120601f850160051c81016020861015620002265750805b601f850160051c820191505b81811015620002475782815560010162000232565b5050505b505050565b81516001600160401b038111156200026c576200026c620001ab565b62000284816200027d8454620001c1565b84620001fd565b602080601f831160018114620002bc5760008415620002a35750858301515b600019600386901b1c1916600185901b17855562000247565b600085815260208120601f198616915b82811015620002ed57888601518255948401946001909101908401620002cc565b50858210156200030c5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156200032f57600080fd5b815180151581146200034057600080fd5b9392505050565b61113880620003576000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c8063642f6cef116100765780639d6f1cc71161005b5780639d6f1cc71461016b578063afb28d1f1461018b578063c98f10b01461019357600080fd5b8063642f6cef1461013b5780639525d5741461015857600080fd5b80634585e33b116100a75780634585e33b146101025780634b56a42e14610115578063601d5a711461012857600080fd5b806305e25131146100c357806340691db4146100d8575b600080fd5b6100d66100d13660046108b3565b61019b565b005b6100eb6100e6366004610969565b6101b2565b6040516100f9929190610a3a565b60405180910390f35b6100d6610110366004610a5d565b610462565b6100eb610123366004610acf565b610504565b6100d6610136366004610b8c565b61055a565b6000546101489060ff1681565b60405190151581526020016100f9565b6100d6610166366004610b8c565b610566565b61017e610179366004610bc1565b610572565b6040516100f99190610bda565b61017e61061e565b61017e61062b565b80516101ae9060019060208401906106be565b5050565b6000606060006101c0610638565b90507fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd6101f060c0870187610bf4565b600081811061020157610201610c5c565b90506020020135036103da57600061021c60c0870187610bf4565b600181811061022d5761022d610c5c565b9050602002013560405160200161024691815260200190565b604051602081830303815290604052905060008180602001905181019061026d9190610c8b565b9050600061027e60c0890189610bf4565b600281811061028f5761028f610c5c565b905060200201356040516020016102a891815260200190565b60405160208183030381529060405290506000818060200190518101906102cf9190610c8b565b905060006102e060c08b018b610bf4565b60038181106102f1576102f1610c5c565b9050602002013560405160200161030a91815260200190565b60405160208183030381529060405290506000818060200190518101906103319190610ccd565b604080516020810188905290810185905273ffffffffffffffffffffffffffffffffffffffff821660608201529091506002906001906003908a90608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526103d19594939291600401610dd6565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f670000000000000000000000000000000000000000000000000000000000000060648201526084016103d1565b60008061047183850185610acf565b9150915060008060008380602001905181019061048e9190610e99565b919450925090506060327f299a03817e683a32b21e29e3ae3c31f1c9c773f7d532836d116b62a9281fbc9d8585856104c4610638565b8b6000815181106104d7576104d7610c5c565b6020026020010151876040516104f296959493929190610ece565b60405180910390a25050505050505050565b600060606000848460405160200161051d929190610f2e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052600193509150505b9250929050565b60036101ae8282611011565b60026101ae8282611011565b6001818154811061058257600080fd5b90600052602060002001600091509050805461059d90610ce8565b80601f01602080910402602001604051908101604052809291908181526020018280546105c990610ce8565b80156106165780601f106105eb57610100808354040283529160200191610616565b820191906000526020600020905b8154815290600101906020018083116105f957829003601f168201915b505050505081565b6002805461059d90610ce8565b6003805461059d90610ce8565b6000805460ff16156106b957606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610690573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b49190610c8b565b905090565b504390565b828054828255906000526020600020908101928215610704579160200282015b8281111561070457825182906106f49082611011565b50916020019190600101906106de565b50610710929150610714565b5090565b808211156107105760006107288282610731565b50600101610714565b50805461073d90610ce8565b6000825580601f1061074d575050565b601f01602090049060005260206000209081019061076b919061076e565b50565b5b80821115610710576000815560010161076f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156107f9576107f9610783565b604052919050565b600067ffffffffffffffff82111561081b5761081b610783565b5060051b60200190565b600082601f83011261083657600080fd5b813567ffffffffffffffff81111561085057610850610783565b61088160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016107b2565b81815284602083860101111561089657600080fd5b816020850160208301376000918101602001919091529392505050565b600060208083850312156108c657600080fd5b823567ffffffffffffffff808211156108de57600080fd5b818501915085601f8301126108f257600080fd5b813561090561090082610801565b6107b2565b81815260059190911b8301840190848101908883111561092457600080fd5b8585015b8381101561095c578035858111156109405760008081fd5b61094e8b89838a0101610825565b845250918601918601610928565b5098975050505050505050565b6000806040838503121561097c57600080fd5b823567ffffffffffffffff8082111561099457600080fd5b9084019061010082870312156109a957600080fd5b909250602084013590808211156109bf57600080fd5b506109cc85828601610825565b9150509250929050565b6000815180845260005b818110156109fc576020818501810151868301820152016109e0565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b8215158152604060208201526000610a5560408301846109d6565b949350505050565b60008060208385031215610a7057600080fd5b823567ffffffffffffffff80821115610a8857600080fd5b818501915085601f830112610a9c57600080fd5b813581811115610aab57600080fd5b866020828501011115610abd57600080fd5b60209290920196919550909350505050565b60008060408385031215610ae257600080fd5b823567ffffffffffffffff80821115610afa57600080fd5b818501915085601f830112610b0e57600080fd5b81356020610b1e61090083610801565b82815260059290921b84018101918181019089841115610b3d57600080fd5b8286015b84811015610b7557803586811115610b595760008081fd5b610b678c86838b0101610825565b845250918301918301610b41565b50965050860135925050808211156109bf57600080fd5b600060208284031215610b9e57600080fd5b813567ffffffffffffffff811115610bb557600080fd5b610a5584828501610825565b600060208284031215610bd357600080fd5b5035919050565b602081526000610bed60208301846109d6565b9392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610c2957600080fd5b83018035915067ffffffffffffffff821115610c4457600080fd5b6020019150600581901b360382131561055357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215610c9d57600080fd5b5051919050565b805173ffffffffffffffffffffffffffffffffffffffff81168114610cc857600080fd5b919050565b600060208284031215610cdf57600080fd5b610bed82610ca4565b600181811c90821680610cfc57607f821691505b602082108103610d35577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008154610d4881610ce8565b808552602060018381168015610d655760018114610d9d57610dcb565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b8901019550610dcb565b866000528260002060005b85811015610dc35781548a8201860152908301908401610da8565b890184019650505b505050505092915050565b60a081526000610de960a0830188610d3b565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610e5b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610e498383610d3b565b94860194925060019182019101610e10565b50508681036040880152610e6f818b610d3b565b9450505050508460608401528281036080840152610e8d81856109d6565b98975050505050505050565b600080600060608486031215610eae57600080fd5b8351925060208401519150610ec560408501610ca4565b90509250925092565b86815285602082015273ffffffffffffffffffffffffffffffffffffffff8516604082015283606082015260c060808201526000610f0f60c08301856109d6565b82810360a0840152610f2181856109d6565b9998505050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610fa3577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610f918683516109d6565b95509382019390820190600101610f57565b505085840381870152505050610fb981856109d6565b95945050505050565b601f82111561100c57600081815260208120601f850160051c81016020861015610fe95750805b601f850160051c820191505b8181101561100857828155600101610ff5565b5050505b505050565b815167ffffffffffffffff81111561102b5761102b610783565b61103f816110398454610ce8565b84610fc2565b602080601f831160018114611092576000841561105c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555611008565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156110df578886015182559484019460019091019084016110c0565b508582101561111b57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var LogTriggeredFeedLookupABI = LogTriggeredFeedLookupMetaData.ABI @@ -300,16 +300,16 @@ func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCallerSession) UseArbitrumB return _LogTriggeredFeedLookup.Contract.UseArbitrumBlockNum(&_LogTriggeredFeedLookup.CallOpts) } -func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactor) CheckLog(opts *bind.TransactOpts, log Log) (*types.Transaction, error) { - return _LogTriggeredFeedLookup.contract.Transact(opts, "checkLog", log) +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactor) CheckLog(opts *bind.TransactOpts, log Log, arg1 []byte) (*types.Transaction, error) { + return _LogTriggeredFeedLookup.contract.Transact(opts, "checkLog", log, arg1) } -func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupSession) CheckLog(log Log) (*types.Transaction, error) { - return _LogTriggeredFeedLookup.Contract.CheckLog(&_LogTriggeredFeedLookup.TransactOpts, log) +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupSession) CheckLog(log Log, arg1 []byte) (*types.Transaction, error) { + return _LogTriggeredFeedLookup.Contract.CheckLog(&_LogTriggeredFeedLookup.TransactOpts, log, arg1) } -func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactorSession) CheckLog(log Log) (*types.Transaction, error) { - return _LogTriggeredFeedLookup.Contract.CheckLog(&_LogTriggeredFeedLookup.TransactOpts, log) +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactorSession) CheckLog(log Log, arg1 []byte) (*types.Transaction, error) { + return _LogTriggeredFeedLookup.Contract.CheckLog(&_LogTriggeredFeedLookup.TransactOpts, log, arg1) } func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactor) PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) { @@ -529,7 +529,7 @@ type LogTriggeredFeedLookupInterface interface { UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) - CheckLog(opts *bind.TransactOpts, log Log) (*types.Transaction, error) + CheckLog(opts *bind.TransactOpts, log Log, arg1 []byte) (*types.Transaction, error) PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/log_upkeep_counter_wrapper/log_upkeep_counter_wrapper.go b/core/gethwrappers/generated/log_upkeep_counter_wrapper/log_upkeep_counter_wrapper.go index 46f1dc7bf64..1a6f58fe6b1 100644 --- a/core/gethwrappers/generated/log_upkeep_counter_wrapper/log_upkeep_counter_wrapper.go +++ b/core/gethwrappers/generated/log_upkeep_counter_wrapper/log_upkeep_counter_wrapper.go @@ -42,8 +42,8 @@ type Log struct { } var LogUpkeepCounterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_testRange\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"initialBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"lastBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"counter\",\"type\":\"uint256\"}],\"name\":\"PerformingUpkeep\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"Trigger\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"a\",\"type\":\"uint256\"}],\"name\":\"Trigger\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"a\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"b\",\"type\":\"uint256\"}],\"name\":\"Trigger\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"a\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"b\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"}],\"name\":\"Trigger\",\"type\":\"event\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"counter\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"previousPerformBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_testRange\",\"type\":\"uint256\"}],\"name\":\"setSpread\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"start\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"testRange\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040527f3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d6000557f57b1de35764b0939dde00771c7069cdf8d6a65d6a175623f19aa18784fd4c6da6001557f1da9f70fe932e73fba9374396c5c0b02dbd170f951874b7b4afabe4dd029a9c86002557f5121119bad45ca7e58e0bdadf39045f5111e93ba4304a0f6457a3e7bc9791e716003553480156100a057600080fd5b50604051610f17380380610f178339810160408190526100bf916100da565b600455600060068190554360055560078190556008556100f3565b6000602082840312156100ec57600080fd5b5051919050565b610e15806101026000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c8063917d895f11610076578063be61b7751161005b578063be61b77514610135578063be9a655514610156578063d832d92f1461015e57600080fd5b8063917d895f1461010f578063b66a261c1461011857600080fd5b806361bc221a116100a757806361bc221a146100f45780636250a13a146100fd578063806b984f1461010657600080fd5b80632cb15864146100c35780634585e33b146100df575b600080fd5b6100cc60075481565b6040519081526020015b60405180910390f35b6100f26100ed366004610810565b610176565b005b6100cc60085481565b6100cc60045481565b6100cc60055481565b6100cc60065481565b6100f261012636600461099a565b60045560006007819055600855565b610148610143366004610882565b6103ed565b6040516100d6929190610a4b565b6100f26105d0565b6101666106aa565b60405190151581526020016100d6565b60075461018257436007555b43600555600854610194906001610d4c565b60085560055460065560006101ab828401846108c5565b90506000548160c001516000815181106101c7576101c7610daa565b60200260200101511415610203576040517f3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d90600090a1610395565b6001548160c0015160008151811061021d5761021d610daa565b6020026020010151141561026557604051600181527f57b1de35764b0939dde00771c7069cdf8d6a65d6a175623f19aa18784fd4c6da906020015b60405180910390a1610395565b6002548160c0015160008151811061027f5761027f610daa565b602002602001015114156102c4576040805160018152600260208201527f1da9f70fe932e73fba9374396c5c0b02dbd170f951874b7b4afabe4dd029a9c89101610258565b6003548160c001516000815181106102de576102de610daa565b6020026020010151141561032e576040805160018152600260208201526003918101919091527f5121119bad45ca7e58e0bdadf39045f5111e93ba4304a0f6457a3e7bc9791e7190606001610258565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f636f756c64206e6f742066696e64206d61746368696e6720736967000000000060448201526064015b60405180910390fd5b60075460055460065460085460408051948552602085019390935291830152606082015232907f8e8112f20a2134e18e591d2cdd68cd86a95d06e6328ede501fc6314f4a5075fa9060800160405180910390a2505050565b600060606103f96106aa565b61045f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f6e6f7420656c696769626c650000000000000000000000000000000000000000604482015260640161038c565b60005461046f60c0850185610b99565b600081811061048057610480610daa565b9050602002013514806104b8575060015461049e60c0850185610b99565b60008181106104af576104af610daa565b90506020020135145b806104e857506002546104ce60c0850185610b99565b60008181106104df576104df610daa565b90506020020135145b8061051857506003546104fe60c0850185610b99565b600081811061050f5761050f610daa565b90506020020135145b15610548576001836040516020016105309190610ac8565b60405160208183030381529060405291509150915091565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f6700000000000000000000000000000000000000000000000000000000000000606482015260840161038c565b6040517f3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d90600090a1604051600181527f57b1de35764b0939dde00771c7069cdf8d6a65d6a175623f19aa18784fd4c6da9060200160405180910390a16040805160018152600260208201527f1da9f70fe932e73fba9374396c5c0b02dbd170f951874b7b4afabe4dd029a9c8910160405180910390a160408051600181526002602082015260038183015290517f5121119bad45ca7e58e0bdadf39045f5111e93ba4304a0f6457a3e7bc9791e719181900360600190a1565b6000600754600014156106bd5750600190565b6004546007546106cd9043610d64565b10905090565b803573ffffffffffffffffffffffffffffffffffffffff811681146106f757600080fd5b919050565b600082601f83011261070d57600080fd5b8135602067ffffffffffffffff82111561072957610729610dd9565b8160051b610738828201610c32565b83815282810190868401838801850189101561075357600080fd5b600093505b85841015610776578035835260019390930192918401918401610758565b50979650505050505050565b600082601f83011261079357600080fd5b813567ffffffffffffffff8111156107ad576107ad610dd9565b6107de60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610c32565b8181528460208386010111156107f357600080fd5b816020850160208301376000918101602001919091529392505050565b6000806020838503121561082357600080fd5b823567ffffffffffffffff8082111561083b57600080fd5b818501915085601f83011261084f57600080fd5b81358181111561085e57600080fd5b86602082850101111561087057600080fd5b60209290920196919550909350505050565b60006020828403121561089457600080fd5b813567ffffffffffffffff8111156108ab57600080fd5b820161010081850312156108be57600080fd5b9392505050565b6000602082840312156108d757600080fd5b813567ffffffffffffffff808211156108ef57600080fd5b90830190610100828603121561090457600080fd5b61090c610c08565b823581526020830135602082015260408301356040820152606083013560608201526080830135608082015261094460a084016106d3565b60a082015260c08301358281111561095b57600080fd5b610967878286016106fc565b60c08301525060e08301358281111561097f57600080fd5b61098b87828601610782565b60e08301525095945050505050565b6000602082840312156109ac57600080fd5b5035919050565b81835260007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8311156109e557600080fd5b8260051b8083602087013760009401602001938452509192915050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b821515815260006020604081840152835180604085015260005b81811015610a8157858101830151858201606001528201610a65565b81811115610a93576000606083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01692909201606001949350505050565b6020815281356020820152602082013560408201526040820135606082015260608201356080820152608082013560a082015273ffffffffffffffffffffffffffffffffffffffff610b1c60a084016106d3565b1660c08201526000610b3160c0840184610c81565b6101008060e0860152610b49610120860183856109b3565b9250610b5860e0870187610ce8565b92507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08685030182870152610b8e848483610a02565b979650505050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610bce57600080fd5b83018035915067ffffffffffffffff821115610be957600080fd5b6020019150600581901b3603821315610c0157600080fd5b9250929050565b604051610100810167ffffffffffffffff81118282101715610c2c57610c2c610dd9565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610c7957610c79610dd9565b604052919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610cb657600080fd5b830160208101925035905067ffffffffffffffff811115610cd657600080fd5b8060051b3603831315610c0157600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610d1d57600080fd5b830160208101925035905067ffffffffffffffff811115610d3d57600080fd5b803603831315610c0157600080fd5b60008219821115610d5f57610d5f610d7b565b500190565b600082821015610d7657610d76610d7b565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_testRange\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"initialBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"lastBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"counter\",\"type\":\"uint256\"}],\"name\":\"PerformingUpkeep\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"Trigger\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"a\",\"type\":\"uint256\"}],\"name\":\"Trigger\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"a\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"b\",\"type\":\"uint256\"}],\"name\":\"Trigger\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"a\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"b\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"}],\"name\":\"Trigger\",\"type\":\"event\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"counter\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"previousPerformBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_testRange\",\"type\":\"uint256\"}],\"name\":\"setSpread\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"start\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"testRange\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60806040527f3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d6000557f57b1de35764b0939dde00771c7069cdf8d6a65d6a175623f19aa18784fd4c6da6001557f1da9f70fe932e73fba9374396c5c0b02dbd170f951874b7b4afabe4dd029a9c86002557f5121119bad45ca7e58e0bdadf39045f5111e93ba4304a0f6457a3e7bc9791e716003553480156100a057600080fd5b50604051610f41380380610f418339810160408190526100bf916100da565b600455600060068190554360055560078190556008556100f3565b6000602082840312156100ec57600080fd5b5051919050565b610e3f806101026000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c8063806b984f11610076578063b66a261c1161005b578063b66a261c14610139578063be9a655514610156578063d832d92f1461015e57600080fd5b8063806b984f14610127578063917d895f1461013057600080fd5b80634585e33b116100a75780634585e33b1461010057806361bc221a146101155780636250a13a1461011e57600080fd5b80632cb15864146100c357806340691db4146100df575b600080fd5b6100cc60075481565b6040519081526020015b60405180910390f35b6100f26100ed366004610889565b610176565b6040516100d6929190610a7c565b61011361010e366004610817565b610365565b005b6100cc60085481565b6100cc60045481565b6100cc60055481565b6100cc60065481565b6101136101473660046109cb565b60045560006007819055600855565b6101136105d7565b6101666106b1565b60405190151581526020016100d6565b600060606101826106b1565b6101ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600c60248201527f6e6f7420656c696769626c65000000000000000000000000000000000000000060448201526064015b60405180910390fd5b6000546101fd60c0860186610bca565b600081811061020e5761020e610dd4565b905060200201351480610246575060015461022c60c0860186610bca565b600081811061023d5761023d610dd4565b90506020020135145b80610276575060025461025c60c0860186610bca565b600081811061026d5761026d610dd4565b90506020020135145b806102a6575060035461028c60c0860186610bca565b600081811061029d5761029d610dd4565b90506020020135145b156102d6576001846040516020016102be9190610af9565b6040516020818303038152906040529150915061035e565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f670000000000000000000000000000000000000000000000000000000000000060648201526084016101e4565b9250929050565b60075461037157436007555b43600555600854610383906001610d76565b600855600554600655600061039a828401846108f6565b90506000548160c001516000815181106103b6576103b6610dd4565b602002602001015114156103f2576040517f3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d90600090a161057f565b6001548160c0015160008151811061040c5761040c610dd4565b6020026020010151141561045457604051600181527f57b1de35764b0939dde00771c7069cdf8d6a65d6a175623f19aa18784fd4c6da906020015b60405180910390a161057f565b6002548160c0015160008151811061046e5761046e610dd4565b602002602001015114156104b3576040805160018152600260208201527f1da9f70fe932e73fba9374396c5c0b02dbd170f951874b7b4afabe4dd029a9c89101610447565b6003548160c001516000815181106104cd576104cd610dd4565b6020026020010151141561051d576040805160018152600260208201526003918101919091527f5121119bad45ca7e58e0bdadf39045f5111e93ba4304a0f6457a3e7bc9791e7190606001610447565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f636f756c64206e6f742066696e64206d61746368696e6720736967000000000060448201526064016101e4565b60075460055460065460085460408051948552602085019390935291830152606082015232907f8e8112f20a2134e18e591d2cdd68cd86a95d06e6328ede501fc6314f4a5075fa9060800160405180910390a2505050565b6040517f3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d90600090a1604051600181527f57b1de35764b0939dde00771c7069cdf8d6a65d6a175623f19aa18784fd4c6da9060200160405180910390a16040805160018152600260208201527f1da9f70fe932e73fba9374396c5c0b02dbd170f951874b7b4afabe4dd029a9c8910160405180910390a160408051600181526002602082015260038183015290517f5121119bad45ca7e58e0bdadf39045f5111e93ba4304a0f6457a3e7bc9791e719181900360600190a1565b6000600754600014156106c45750600190565b6004546007546106d49043610d8e565b10905090565b803573ffffffffffffffffffffffffffffffffffffffff811681146106fe57600080fd5b919050565b600082601f83011261071457600080fd5b8135602067ffffffffffffffff82111561073057610730610e03565b8160051b61073f828201610c5c565b83815282810190868401838801850189101561075a57600080fd5b600093505b8584101561077d57803583526001939093019291840191840161075f565b50979650505050505050565b600082601f83011261079a57600080fd5b813567ffffffffffffffff8111156107b4576107b4610e03565b6107e560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610c5c565b8181528460208386010111156107fa57600080fd5b816020850160208301376000918101602001919091529392505050565b6000806020838503121561082a57600080fd5b823567ffffffffffffffff8082111561084257600080fd5b818501915085601f83011261085657600080fd5b81358181111561086557600080fd5b86602082850101111561087757600080fd5b60209290920196919550909350505050565b6000806040838503121561089c57600080fd5b823567ffffffffffffffff808211156108b457600080fd5b9084019061010082870312156108c957600080fd5b909250602084013590808211156108df57600080fd5b506108ec85828601610789565b9150509250929050565b60006020828403121561090857600080fd5b813567ffffffffffffffff8082111561092057600080fd5b90830190610100828603121561093557600080fd5b61093d610c32565b823581526020830135602082015260408301356040820152606083013560608201526080830135608082015261097560a084016106da565b60a082015260c08301358281111561098c57600080fd5b61099887828601610703565b60c08301525060e0830135828111156109b057600080fd5b6109bc87828601610789565b60e08301525095945050505050565b6000602082840312156109dd57600080fd5b5035919050565b81835260007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff831115610a1657600080fd5b8260051b8083602087013760009401602001938452509192915050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b821515815260006020604081840152835180604085015260005b81811015610ab257858101830151858201606001528201610a96565b81811115610ac4576000606083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01692909201606001949350505050565b6020815281356020820152602082013560408201526040820135606082015260608201356080820152608082013560a082015273ffffffffffffffffffffffffffffffffffffffff610b4d60a084016106da565b1660c08201526000610b6260c0840184610cab565b6101008060e0860152610b7a610120860183856109e4565b9250610b8960e0870187610d12565b92507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08685030182870152610bbf848483610a33565b979650505050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610bff57600080fd5b83018035915067ffffffffffffffff821115610c1a57600080fd5b6020019150600581901b360382131561035e57600080fd5b604051610100810167ffffffffffffffff81118282101715610c5657610c56610e03565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610ca357610ca3610e03565b604052919050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610ce057600080fd5b830160208101925035905067ffffffffffffffff811115610d0057600080fd5b8060051b360383131561035e57600080fd5b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610d4757600080fd5b830160208101925035905067ffffffffffffffff811115610d6757600080fd5b80360383131561035e57600080fd5b60008219821115610d8957610d89610da5565b500190565b600082821015610da057610da0610da5565b500390565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", } var LogUpkeepCounterABI = LogUpkeepCounterMetaData.ABI @@ -182,9 +182,9 @@ func (_LogUpkeepCounter *LogUpkeepCounterTransactorRaw) Transact(opts *bind.Tran return _LogUpkeepCounter.Contract.contract.Transact(opts, method, params...) } -func (_LogUpkeepCounter *LogUpkeepCounterCaller) CheckLog(opts *bind.CallOpts, log Log) (bool, []byte, error) { +func (_LogUpkeepCounter *LogUpkeepCounterCaller) CheckLog(opts *bind.CallOpts, log Log, arg1 []byte) (bool, []byte, error) { var out []interface{} - err := _LogUpkeepCounter.contract.Call(opts, &out, "checkLog", log) + err := _LogUpkeepCounter.contract.Call(opts, &out, "checkLog", log, arg1) if err != nil { return *new(bool), *new([]byte), err @@ -197,12 +197,12 @@ func (_LogUpkeepCounter *LogUpkeepCounterCaller) CheckLog(opts *bind.CallOpts, l } -func (_LogUpkeepCounter *LogUpkeepCounterSession) CheckLog(log Log) (bool, []byte, error) { - return _LogUpkeepCounter.Contract.CheckLog(&_LogUpkeepCounter.CallOpts, log) +func (_LogUpkeepCounter *LogUpkeepCounterSession) CheckLog(log Log, arg1 []byte) (bool, []byte, error) { + return _LogUpkeepCounter.Contract.CheckLog(&_LogUpkeepCounter.CallOpts, log, arg1) } -func (_LogUpkeepCounter *LogUpkeepCounterCallerSession) CheckLog(log Log) (bool, []byte, error) { - return _LogUpkeepCounter.Contract.CheckLog(&_LogUpkeepCounter.CallOpts, log) +func (_LogUpkeepCounter *LogUpkeepCounterCallerSession) CheckLog(log Log, arg1 []byte) (bool, []byte, error) { + return _LogUpkeepCounter.Contract.CheckLog(&_LogUpkeepCounter.CallOpts, log, arg1) } func (_LogUpkeepCounter *LogUpkeepCounterCaller) Counter(opts *bind.CallOpts) (*big.Int, error) { @@ -1017,7 +1017,7 @@ func (_LogUpkeepCounter *LogUpkeepCounter) Address() common.Address { } type LogUpkeepCounterInterface interface { - CheckLog(opts *bind.CallOpts, log Log) (bool, []byte, error) + CheckLog(opts *bind.CallOpts, log Log, arg1 []byte) (bool, []byte, error) Counter(opts *bind.CallOpts) (*big.Int, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e39794e3283..d7e7d74ffc2 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -19,13 +19,13 @@ flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../cont functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 -i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin bae4953d5927956ad355decba4f90b40fe3364b29656ad3eeccbc15b34bdb45e -i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin 8cc5fbd18810dd2a3dc12871eabdb3bf79634544614e00ee967382767b9dfde3 +i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 35e8ad434d27f8b23c8e759c1ca2d05aff99ccb2589edac8f87ea3c1312a7255 +i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 keeper_registry_logic1_3: ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin 0176d7abdb01b370c5bf4f670d9abf85ca10aff53b1f7bdad41f85fabe666020 keeper_registry_logic2_0: ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin d69d2bc8e4844293dbc2d45abcddc50b84c88554ecccfa4fa77c0ca45ec80871 -keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 41a73c159373257b335e72196b57f0ca4aa2cf83e484943af7b0c8fce3c863de +keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 41119855ff05ac7f0b7c0c4ed8d0c7968411b597bddb5c36246a7ccf28631f13 keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 3a1a5efbcd1cf65e6e591b7b8c897f7bf8bde5a43376edfe78dd9e7a7415f40e keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin 6ce079f2738f015f7374673a2816e8e9787143d00b780ea7652c8aa9ad9e1e20 keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 @@ -36,8 +36,8 @@ keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../c llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 log_emitter: ../../contracts/solc/v0.8.6/LogEmitter.abi ../../contracts/solc/v0.8.6/LogEmitter.bin 375488d19b6ee1c180d42048be10abea9146e2a58347fd180358850d435cb854 -log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin 0c64df455593bbd4768b28d9794b916fcb4af629c00e4dcd69dc107d41968bd4 -log_upkeep_counter_wrapper: ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin f53538fb7ec780a8d5e18f3a7c11b917ce9eba0020a60f5b113b6bf8b16ddf2f +log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin 3b64fe225de164203b760a0e5088d1b5034fcbe8483ce295439e8e52f0c71859 +log_upkeep_counter_wrapper: ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin 13d6543329f89d06cbf3901d7f9ecdc42acc1a84d8c61db291fcbfdbe1138eb1 mercury_exposed_verifier: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 mercury_upkeep_wrapper: ../../contracts/solc/v0.8.15/MercuryUpkeep.abi ../../contracts/solc/v0.8.15/MercuryUpkeep.bin c4627433ed9ebe7f8cf6594f577b4a1826ce6f2209271895a885fd4b3017320e mercury_verifier: ../../contracts/solc/v0.8.16/Verifier.abi ../../contracts/solc/v0.8.16/Verifier.bin 24b2db0d5db8e0198bb7eae2ecde65f2596df4bcc7b17d604d25300546c1694e From f3e9fce234df0230e3d76e6514660ad55b25be38 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Wed, 26 Jul 2023 10:20:23 -0500 Subject: [PATCH 002/270] CODEOWNERS: /plugins and /common (#9834) --- CODEOWNERS | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CODEOWNERS b/CODEOWNERS index 10d1284e0ba..819f3fd7340 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -9,6 +9,7 @@ /core/internal @samsondav @jmank88 # Chains +/common @smartcontractkit/integrations /core/chains/evm @samsondav @prashantkumar1982 /core/chains/evm/headtracker @pinebit @samsondav @prashantkumar1982 /core/chains/evm/client @samsondav @prashantkumar1982 @@ -95,3 +96,6 @@ flake.lock @smartcontractkit/prodsec-public ./core/config @samsondav @jmank88 ./docs/CONFIG.md @samsondav @jmank88 @dwightjl ./internal/config/docs.toml @samsondav @jmank88 @dwightjl + +# LOOP Plugins +/plugins @jmank88 @krehermann From daf7696c7c9d8a060736a58d0f61e1915907cf80 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 26 Jul 2023 17:27:16 +0000 Subject: [PATCH 003/270] Update Operator UI from v0.8.0-e0e85f9 to v0.8.0-91e5ba4 (#9861) * Update Operator UI from v0.8.0-e0e85f9 to v0.8.0-91e5ba4 * Trigger build --------- Co-authored-by: jmank88 Co-authored-by: george-dorin --- operator_ui/TAG | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/operator_ui/TAG b/operator_ui/TAG index c607f17b656..e75a8c12a57 100644 --- a/operator_ui/TAG +++ b/operator_ui/TAG @@ -1 +1 @@ -v0.8.0-e0e85f9 +v0.8.0-91e5ba4 From 0c767a3d8fea9a7ecd21b18e3c8e60b2d498c6d3 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Wed, 26 Jul 2023 14:43:54 -0400 Subject: [PATCH 004/270] [Functions] (feat): Add configurability for over estimating fulfillment gas price (#9845) * (feat): Add configurability for over estimating cost for gas price increases * Regen geth wrappers * (test): Add fulfillmentGasPriceOverEstimationBP unit test --- .../functions/dev/1_0_0/FunctionsBilling.sol | 27 +++++++--- .../1_0_0/interfaces/IFunctionsBilling.sol | 4 +- .../functions/v1/FunctionsCoordinator.test.ts | 54 +++++++++++++++++++ .../v0.8/functions/v1/FunctionsRouter.test.ts | 10 +--- .../test/v0.8/functions/v1/RouterBase.test.ts | 5 ++ contracts/test/v0.8/functions/v1/utils.ts | 3 ++ .../functions_coordinator.go | 39 +++++++------- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 8 files changed, 107 insertions(+), 37 deletions(-) create mode 100644 contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 6fbd4b6109c..6cfca2ff8c0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -59,6 +59,9 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // The highest support request data version supported by the node // All lower versions should also be supported uint16 maxSupportedRequestDataVersion; + // Percentage of gas price overestimation to account for changes in gas price between request and response + // Held as basis points (one hundredth of 1 percentage point) + uint256 fulfillmentGasPriceOverEstimationBP; } Config private s_config; event ConfigSet( @@ -68,7 +71,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint32 gasOverheadAfterCallback, int256 fallbackNativePerUnitLink, uint96 donFee, - uint16 maxSupportedRequestDataVersion + uint16 maxSupportedRequestDataVersion, + uint256 fulfillmentGasPriceOverEstimationBP ); error UnsupportedRequestDataVersion(); @@ -126,8 +130,9 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { int256 fallbackNativePerUnitLink, uint32 requestTimeoutSeconds, uint96 donFee, - uint16 maxSupportedRequestDataVersion - ) = abi.decode(config, (uint32, uint32, uint32, uint32, int256, uint32, uint96, uint16)); + uint16 maxSupportedRequestDataVersion, + uint256 fulfillmentGasPriceOverEstimationBP + ) = abi.decode(config, (uint32, uint32, uint32, uint32, int256, uint32, uint96, uint16, uint256)); if (fallbackNativePerUnitLink <= 0) { revert InvalidLinkWeiPrice(fallbackNativePerUnitLink); @@ -140,7 +145,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { requestTimeoutSeconds: requestTimeoutSeconds, donFee: donFee, fallbackNativePerUnitLink: fallbackNativePerUnitLink, - maxSupportedRequestDataVersion: maxSupportedRequestDataVersion + maxSupportedRequestDataVersion: maxSupportedRequestDataVersion, + fulfillmentGasPriceOverEstimationBP: fulfillmentGasPriceOverEstimationBP }); emit ConfigSet( maxCallbackGasLimit, @@ -149,7 +155,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { gasOverheadAfterCallback, fallbackNativePerUnitLink, donFee, - maxSupportedRequestDataVersion + maxSupportedRequestDataVersion, + fulfillmentGasPriceOverEstimationBP ); } @@ -167,7 +174,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { int256 fallbackNativePerUnitLink, uint32 gasOverheadBeforeCallback, address linkPriceFeed, - uint16 maxSupportedRequestDataVersion + uint16 maxSupportedRequestDataVersion, + uint256 fulfillmentGasPriceOverEstimationBP ) { return ( @@ -177,7 +185,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { s_config.fallbackNativePerUnitLink, s_config.gasOverheadBeforeCallback, address(LINK_TO_NATIVE_FEED), - s_config.maxSupportedRequestDataVersion + s_config.maxSupportedRequestDataVersion, + s_config.fulfillmentGasPriceOverEstimationBP ); } @@ -257,8 +266,10 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { revert InvalidLinkWeiPrice(weiPerUnitLink); } uint256 executionGas = s_config.gasOverheadBeforeCallback + s_config.gasOverheadAfterCallback + callbackGasLimit; + uint256 gasPriceWithOverestimation = gasPrice + + ((gasPrice * s_config.fulfillmentGasPriceOverEstimationBP) / 10_000); // (1e18 juels/link) (wei/gas * gas) / (wei/link) = juels - uint256 paymentNoFee = (1e18 * gasPrice * executionGas) / uint256(weiPerUnitLink); + uint256 paymentNoFee = (1e18 * gasPriceWithOverestimation * executionGas) / uint256(weiPerUnitLink); uint256 fee = uint256(donFee) + uint256(adminFee); if (paymentNoFee > (1e27 - fee)) { revert PaymentTooLarge(); // Payment + fee cannot be more than all of the link in existence. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index f16ef26bfb1..615e3bb9adb 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -26,6 +26,7 @@ interface IFunctionsBilling { * @return gasOverhead average gas execution cost used in estimating total cost * @return linkPriceFeed address of contract for a conversion price between LINK token and native token * @return maxSupportedRequestDataVersion The highest support request data version supported by the node + * @return fulfillmentGasPriceOverEstimationBP Percentage of gas price overestimation to account for changes in gas price between request and response. Held as basis points (one hundredth of 1 percentage point) */ function getConfig() external @@ -37,7 +38,8 @@ interface IFunctionsBilling { int256 fallbackWeiPerUnitLink, uint32 gasOverhead, address linkPriceFeed, - uint16 maxSupportedRequestDataVersion + uint16 maxSupportedRequestDataVersion, + uint256 fulfillmentGasPriceOverEstimationBP ); /** diff --git a/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts b/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts new file mode 100644 index 00000000000..29ef0b5b640 --- /dev/null +++ b/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts @@ -0,0 +1,54 @@ +import { ethers } from 'hardhat' +import { expect } from 'chai' +import { + getSetupFactory, + FunctionsContracts, + coordinatorConfig, + ids, +} from './utils' + +const setup = getSetupFactory() +let contracts: FunctionsContracts + +beforeEach(async () => { + ;({ contracts } = setup()) +}) + +describe('Functions Coordinator', () => { + describe('Config', () => { + it('#fulfillmentGasPriceOverEstimationBP overestimates gas cost', async () => { + const estimateWithNoOverestimaton = + await contracts.coordinator.estimateCost(1, 0x0, 100_000, 20) + + await contracts.router.proposeConfigUpdate( + ids.donId, + ethers.utils.defaultAbiCoder.encode( + [ + 'uint32', + 'uint32', + 'uint32', + 'uint32', + 'int256', + 'uint32', + 'uint96', + 'uint16', + 'uint256', + ], + [ + ...Object.values({ + ...coordinatorConfig, + fulfillmentGasPriceOverEstimationBP: 10_000, + }), + ], + ), + ) + await contracts.router.updateConfig(ids.donId) + + // Halve the gas price, which should be the same estimate because of fulfillmentGasPriceOverEstimationBP doubling the gas price + const estimateWithOverestimaton = + await contracts.coordinator.estimateCost(1, 0x0, 100_000, 10) + + expect(estimateWithNoOverestimaton).to.equal(estimateWithOverestimaton) + }) + }) +}) diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index a36c794d48f..9425376b6b4 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -1,23 +1,15 @@ -import { ethers } from 'hardhat' import { expect } from 'chai' import { getSetupFactory, FunctionsContracts, - FunctionsRoles, functionsRouterConfig, - stringToHex, - anyValue, - createSubscription, } from './utils' const setup = getSetupFactory() let contracts: FunctionsContracts -let roles: FunctionsRoles - -const donLabel = ethers.utils.formatBytes32String('1') beforeEach(async () => { - ;({ contracts, roles } = setup()) + ;({ contracts } = setup()) }) describe('Functions Router - Request lifecycle', () => { diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 4a4553ebd75..7abba95d478 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -112,6 +112,7 @@ describe('FunctionsRouter - Base', () => { 'uint32', 'uint96', 'uint16', + 'uint256', ], [ ...Object.values({ @@ -168,6 +169,7 @@ describe('FunctionsRouter - Base', () => { 'uint32', 'uint96', 'uint16', + 'uint256', ], [...Object.values(coordinatorConfig)], ), @@ -187,6 +189,7 @@ describe('FunctionsRouter - Base', () => { 'uint32', 'uint96', 'uint16', + 'uint256', ], [...Object.values(coordinatorConfig)], ), @@ -206,6 +209,7 @@ describe('FunctionsRouter - Base', () => { 'uint32', 'uint96', 'uint16', + 'uint256', ], [...Object.values(coordinatorConfig)], ), @@ -337,6 +341,7 @@ describe('FunctionsRouter - Base', () => { 'uint32', 'uint96', 'uint16', + 'uint256', ], [...Object.values(coordinatorConfig)], ), diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index b38f97d6bfd..f481130b313 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -72,6 +72,7 @@ export type CoordinatorConfig = { donFee: number fallbackNativePerUnitLink: BigNumber maxSupportedRequestDataVersion: number + fulfillmentGasPriceOverEstimationBP: number } const fallbackNativePerUnitLink = 5000000000000000 export const coordinatorConfig: CoordinatorConfig = { @@ -83,6 +84,7 @@ export const coordinatorConfig: CoordinatorConfig = { donFee: 0, fallbackNativePerUnitLink: BigNumber.from(fallbackNativePerUnitLink), maxSupportedRequestDataVersion: 1, + fulfillmentGasPriceOverEstimationBP: 0, } export const accessControlMockPublicKey = '0x32237412cC0321f56422d206e505dB4B3871AF5c' @@ -241,6 +243,7 @@ export function getSetupFactory(): () => { 'uint32', 'uint96', 'uint16', + 'uint256', ], [...Object.values(coordinatorConfig)], ) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 9f4ce45fb6b..8b642d3f16a 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -60,8 +60,8 @@ type IFunctionsCoordinatorRequest struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"OCRConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"caller\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620058c7380380620058c783398101604081905262000034916200042a565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620005f29350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080600080600080600080888060200190518101906200022091906200053a565b975097509750975097509750975097506000841362000256576040516321ea67b360e11b81526004810185905260240162000089565b604080516101008101825263ffffffff808b168083528a8216602084018190528983168486018190528b841660608601819052938916608086018190526001600160601b03891660a0870181905260c087018c905261ffff891660e0909701879052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d869055600e805461ffff19169091179055517fd09395baf4d99e44ce1b8e96a4396a3f896d0fd5e4517993f28ce0a6fb42e22790620003e4908a908a9089908b908a908990899063ffffffff97881681529587166020870152938616604086015291909416606084015260808301939093526001600160601b039290921660a082015261ffff9190911660c082015260e00190565b60405180910390a1505050505050505050565b80516001600160a01b03811681146200040f57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200044057600080fd5b6200044b84620003f7565b602085810151919450906001600160401b03808211156200046b57600080fd5b818701915087601f8301126200048057600080fd5b81518181111562000495576200049562000414565b604051601f8201601f19908116603f01168101908382118183101715620004c057620004c062000414565b816040528281528a86848701011115620004d957600080fd5b600093505b82841015620004fd5784840186015181850187015292850192620004de565b60008684830101528097505050505050506200051c60408501620003f7565b90509250925092565b805163ffffffff811681146200040f57600080fd5b600080600080600080600080610100898b0312156200055857600080fd5b620005638962000525565b97506200057360208a0162000525565b96506200058360408a0162000525565b95506200059360608a0162000525565b945060808901519350620005aa60a08a0162000525565b60c08a01519093506001600160601b0381168114620005c857600080fd5b60e08a015190925061ffff81168114620005e157600080fd5b809150509295985092959890939650565b6080516152b96200060e600039600061142c01526152b96000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610481578063de9dfa4614610489578063e3d0e7121461049c578063f2fde38b146104af57600080fd5b8063b1dc65a4146103ce578063c3f909d4146103e1578063d227d2451461046e57600080fd5b80639883c10d116100c85780639883c10d14610394578063af1296d3146103a6578063afcb95d7146103ae57600080fd5b806381ff70481461031957806385b214cf146103495780638da5cb5b1461036c57600080fd5b8063533989871161015b5780637f15e166116101355780637f15e166146102d657806380756031146102e957806381411834146102fc57806381f1b9381461031157600080fd5b806353398987146102a557806366316d8d146102bb57806379ba5097146102ce57600080fd5b806326ceabac1161018c57806326ceabac1461024f578063354497aa14610262578063466557181461027557600080fd5b8063083a5466146101b35780630a33e0a5146101c8578063181f5a771461020d575b600080fd5b6101c66101c1366004613d55565b6104c2565b005b6101db6101d6366004613d97565b610517565b604080519485526bffffffffffffffffffffffff90931660208501529183015260608201526080015b60405180910390f35b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b6040516102049190613e36565b6101c661025d366004613e6b565b61073d565b6101c6610270366004613f94565b6107df565b610288610283366004614004565b610846565b6040516bffffffffffffffffffffffff9091168152602001610204565b6102ad610876565b60405161020492919061412b565b6101c66102c93660046141d5565b610b25565b6101c6610ca3565b6101c66102e4366004613d55565b610da5565b6101c66102f736600461420e565b610df5565b610304610eac565b6040516102049190614263565b610242610f1b565b6004546002546040805163ffffffff80851682526401000000009094049093166020840152820152606001610204565b61035c610357366004614276565b610fec565b6040519015158152602001610204565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610204565b6008545b604051908152602001610204565b6103986111d6565b604080516001815260006020820181905291810191909152606001610204565b6101c66103dc3660046142d4565b6112b9565b600c54600d54600a54600e546040805163ffffffff80871682526401000000008704811660208301526c010000000000000000000000008704811692820192909252606081019490945268010000000000000000909404909316608083015273ffffffffffffffffffffffffffffffffffffffff1660a082015261ffff90911660c082015260e001610204565b61028861047c36600461438b565b6119ea565b610242611b6f565b610288610497366004614004565b611bc6565b6101c66104aa3660046144ad565b611c61565b6101c66104bd366004613e6b565b612645565b6104ca612656565b6000819003610505576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601361051282848361461b565b505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff163314610571576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61057e6020860186614736565b90506000036105b8576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160808101909152600090806105d4602089018961479b565b67ffffffffffffffff1681526020016105f360a0890160808a01613e6b565b73ffffffffffffffffffffffffffffffffffffffff16815260200161061e6080890160608a016147b8565b63ffffffff1681523a60209182015290915061068b9061064090880188614736565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250610685925050506060890160408a016147e5565b836126d9565b929750909550935091506106a560a0870160808801613e6b565b73ffffffffffffffffffffffffffffffffffffffff16857fb108b073fa485003d66284614f1c3b4feb3f47ffc88f7873bf3b2ec4bb8939bc326106eb60208b018b61479b565b6106fb60c08c0160a08d01613e6b565b61070860208d018d614736565b8d604001602081019061071b91906147e5565b60405161072d96959493929190614802565b60405180910390a3509193509193565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061077857503373ffffffffffffffffffffffffffffffffffffffff8216145b6107ae576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660009081526012602052604081206107dc91613c9a565b50565b60095473ffffffffffffffffffffffffffffffffffffffff163314610830576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61083981612d03565b8051602090910120600855565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa1580156108c6573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261090c91908101906148fa565b90506000815167ffffffffffffffff81111561092a5761092a613e88565b60405190808252806020026020018201604052801561095d57816020015b60608152602001906001900390816109485790505b50905060005b8251811015610b1b57601260008483815181106109825761098261492f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546109cf9061457a565b9050600003610a0a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60126000848381518110610a2057610a2061492f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610a6d9061457a565b80601f0160208091040260200160405190810160405280929190818152602001828054610a999061457a565b8015610ae65780601f10610abb57610100808354040283529160200191610ae6565b820191906000526020600020905b815481529060010190602001808311610ac957829003601f168201915b5050505050828281518110610afd57610afd61492f565b60200260200101819052508080610b139061498d565b915050610963565b5090939092509050565b610b2d612fb0565b806bffffffffffffffffffffffff16600003610b635750336000908152600f60205260409020546bffffffffffffffffffffffff165b336000908152600f60205260409020546bffffffffffffffffffffffff80831691161015610bbd576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600f602052604081208054839290610bea9084906bffffffffffffffffffffffff166149c5565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610c8657600080fd5b505af1158015610c9a573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610d29576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610dad612656565b6000819003610de8576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601161051282848361461b565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610e405750610e1f33613149565b8015610e4057503373ffffffffffffffffffffffffffffffffffffffff8416145b610e76576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601260205260409020610ea682848361461b565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610f1157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610ee6575b5050505050905090565b606060138054610f2a9061457a565b9050600003610f65576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60138054610f729061457a565b80601f0160208091040260200160405190810160405280929190818152602001828054610f9e9061457a565b8015610f115780601f10610fc057610100808354040283529160200191610f11565b820191906000526020600020905b815481529060010190602001808311610fce57509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314611040576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e084015260048101546101008401526005015461012083015261114e5750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611260573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112849190614a0b565b509350509250508280156112a6575061129d8142614a5b565b8463ffffffff16105b156112b157600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161130f91849163ffffffff851691908e908e908190840183828082843760009201919091525061325d92505050565b611345576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461141a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610d20565b6114288b8b8b8b8b8b613266565b60007f000000000000000000000000000000000000000000000000000000000000000015611485576002826020015183604001516114669190614a6e565b6114709190614ab6565b61147b906001614a6e565b60ff16905061149b565b6020820151611495906001614a6e565b60ff1690505b888114611504576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610d20565b88871461156d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610d20565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156115b0576115b0614ad8565b60028111156115c1576115c1614ad8565b90525090506002816020015160028111156115de576115de614ad8565b14801561162557506007816000015160ff16815481106116005761160061492f565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b61168b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610d20565b5050505050611698613cd4565b6000808a8a6040516116ab929190614b07565b6040519081900381206116c2918e90602001614b17565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156119cc57600060018489846020811061172b5761172b61492f565b61173891901a601b614a6e565b8e8e8681811061174a5761174a61492f565b905060200201358d8d878181106117635761176361492f565b90506020020135604051600081526020016040526040516117a0949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156117c2573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561184257611842614ad8565b600281111561185357611853614ad8565b905250925060018360200151600281111561187057611870614ad8565b146118d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610d20565b8251600090879060ff16601f81106118f1576118f161492f565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611973576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610d20565b8086846000015160ff16601f811061198d5761198d61492f565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526119b8600186614a6e565b945050806119c59061498d565b905061170c565b5050506119dd833383858e8e613314565b5050505050505050505050565b60006301c9c3808363ffffffff161115611a4457600c546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff80861660048301529091166024820152604401610d20565b620f4240821115611a81576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808867ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018563ffffffff1681526020018481525090506000611b0f87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610846915050565b90506000611b5488888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611bc6915050565b9050611b62868684846135b9565b9998505050505050505050565b606060118054611b7e9061457a565b9050600003611bb9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60118054610f729061457a565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611c36573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c5a9190614b2b565b9392505050565b855185518560ff16601f831115611cd4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610d20565b60008111611d3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610d20565b818314611dcc576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610d20565b611dd7816003614b48565b8311611e3f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610d20565b611e47612656565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611e8e90886136ef565b6006541561204357600654600090611ea890600190614a5b565b9050600060068281548110611ebf57611ebf61492f565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611ef957611ef961492f565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090811690915592909116808452922080549091169055600680549192509080611f7957611f79614b5f565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190556007805480611fe257611fe2614b5f565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611e8e915050565b60005b8151518110156124a8576000600560008460000151848151811061206c5761206c61492f565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156120b6576120b6614ad8565b1461211d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610d20565b6040805180820190915260ff8216815260016020820152825180516005916000918590811061214e5761214e61492f565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156121ef576121ef614ad8565b0217905550600091506121ff9050565b60056000846020015184815181106122195761221961492f565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561226357612263614ad8565b146122ca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610d20565b6040805180820190915260ff8216815260208101600281525060056000846020015184815181106122fd576122fd61492f565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561239e5761239e614ad8565b0217905550508251805160069250839081106123bc576123bc61492f565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160079190839081106124385761243861492f565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556124a18161498d565b9050612046565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff43811682029283178555908304811693600193909260009261253a928692908216911617614b8e565b92506101000a81548163ffffffff021916908363ffffffff1602179055506125994630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a0015161370c565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a0998612638988b98919763ffffffff909216969095919491939192614bab565b60405180910390a16119dd565b61264d612656565b6107dc816137b7565b60005473ffffffffffffffffffffffffffffffffffffffff1633146126d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d20565b565b600e5460009081908190819061ffff9081169087161115612726576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c54604086015163ffffffff9182169116111561278857604085810151600c5491517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff918216600482015291166024820152604401610d20565b60006127948887610846565b905060006127a28988611bc6565b905060006127ba8860400151896060015185856135b9565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa15801561283d573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526128839190810190614c31565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015612914573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129389190614cbd565b509150506bffffffffffffffffffffffff851661295583856149c5565b6bffffffffffffffffffffffff16101561299b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612a1a308e602001518f600001518560016129b89190614d0f565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff16612b069190614b8e565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee542290612cb3908490614d30565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60008060008060008060008088806020019051810190612d239190614e32565b9750975097509750975097509750975060008413612d70576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101859052602401610d20565b604080516101008101825263ffffffff808b168083528a8216602084018190528983168486018190528b841660608601819052938916608086018190526bffffffffffffffffffffffff891660a0870181905260c087018c905261ffff891660e0909701879052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d869055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055517fd09395baf4d99e44ce1b8e96a4396a3f896d0fd5e4517993f28ce0a6fb42e22790612f9d908a908a9089908b908a908990899063ffffffff97881681529587166020870152938616604086015291909416606084015260808301939093526bffffffffffffffffffffffff9290921660a082015261ffff9190911660c082015260e00190565b60405180910390a1505050505050505050565b6000612fba610eac565b90508051600003612ff7576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051601054600091613016916bffffffffffffffffffffffff16614ed8565b905060005b82518160ff1610156130ea5781600f6000858460ff16815181106130415761304161492f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166130a99190614f03565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080806130e290614f28565b91505061301b565b5081516130f79082614f47565b601080546000906131179084906bffffffffffffffffffffffff166149c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015613197573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526131dd91908101906148fa565b905060005b8151811015613253578373ffffffffffffffffffffffffffffffffffffffff168282815181106132145761321461492f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603613241575060019392505050565b8061324b8161498d565b9150506131e2565b5060009392505050565b60019392505050565b6000613273826020614b48565b61327e856020614b48565b61328a88610144614f77565b6132949190614f77565b61329e9190614f77565b6132a9906000614f77565b9050368114610c9a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610d20565b606080806133248486018661500a565b82519295509093509150158061333c57508151835114155b8061334957508051835114155b15613380576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156135ad5760006133e48583815181106133a3576133a361492f565b60200260200101518584815181106133bd576133bd61492f565b60200260200101518585815181106133d7576133d761492f565b60200260200101516138ac565b905060008160068111156133fa576133fa614ad8565b14806134175750600181600681111561341557613415614ad8565b145b156134725784828151811061342e5761342e61492f565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a261359a565b600281600681111561348657613486614ad8565b036134d65784828151811061349d5761349d61492f565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a261359a565b60038160068111156134ea576134ea614ad8565b0361353a578482815181106135015761350161492f565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a261359a565b600581600681111561354e5761354e614ad8565b0361359a578482815181106135655761356561492f565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a25b50806135a58161498d565b915050613383565b50505050505050505050565b6000806135c46111d6565b905060008113613603576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d20565b600c5460009087906136399063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614b8e565b6136439190614b8e565b63ffffffff1690506000828261366189670de0b6b3a7640000614b48565b61366b9190614b48565b61367591906150e7565b905060006136946bffffffffffffffffffffffff808816908916614f77565b90506136ac816b033b2e3c9fd0803ce8000000614a5b565b8211156136e5576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611b628183614f77565b60006136f9610eac565b51111561370857613708612fb0565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613730999897969594939291906150fb565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613836576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d20565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e0830152600481015461010083015260050154610120820152906139bb576002915050611c5a565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613a196111d6565b905060008113613a58576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d20565b600081613a6d3a670de0b6b3a7640000614b48565b613a7791906150e7565b9050600083610100015182613a8c9190614b48565b905060008460a0015182613aa09190614f03565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613b08908f908f908f908c908b903390600401615190565b60408051808303816000875af1158015613b26573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b4a9190615201565b9092509050613b598186614f03565b336000908152600f6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601080549193909291613bb991859116614f03565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613c1f9190614f03565b60c08d015160a08e0151613c33888d614f03565b613c3d9190614f03565b613c479190614f03565b8760ff166006811115613c5c57613c5c614ad8565b604051613c6d959493929190615230565b60405180910390a28160ff166006811115613c8a57613c8a614ad8565b9c9b505050505050505050505050565b508054613ca69061457a565b6000825580601f10613cb6575050565b601f0160209004906000526020600020908101906107dc9190613cf3565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613d085760008155600101613cf4565b5090565b60008083601f840112613d1e57600080fd5b50813567ffffffffffffffff811115613d3657600080fd5b602083019150836020828501011115613d4e57600080fd5b9250929050565b60008060208385031215613d6857600080fd5b823567ffffffffffffffff811115613d7f57600080fd5b613d8b85828601613d0c565b90969095509350505050565b600060208284031215613da957600080fd5b813567ffffffffffffffff811115613dc057600080fd5b820160c08185031215611c5a57600080fd5b6000815180845260005b81811015613df857602081850181015186830182015201613ddc565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611c5a6020830184613dd2565b73ffffffffffffffffffffffffffffffffffffffff811681146107dc57600080fd5b600060208284031215613e7d57600080fd5b8135611c5a81613e49565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613efe57613efe613e88565b604052919050565b600082601f830112613f1757600080fd5b813567ffffffffffffffff811115613f3157613f31613e88565b613f6260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613eb7565b818152846020838601011115613f7757600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613fa657600080fd5b813567ffffffffffffffff811115613fbd57600080fd5b613fc984828501613f06565b949350505050565b67ffffffffffffffff811681146107dc57600080fd5b80356111d181613fd1565b63ffffffff811681146107dc57600080fd5b60008082840360a081121561401857600080fd5b833567ffffffffffffffff8082111561403057600080fd5b61403c87838801613f06565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561406e57600080fd5b6040519250608083019150828210818311171561408d5761408d613e88565b50604052602084013561409f81613fd1565b815260408401356140af81613e49565b602082015260608401356140c281613ff2565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561412057815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140ee565b509495945050505050565b60408152600061413e60408301856140da565b6020838203818501528185518084528284019150828160051b85010183880160005b838110156141ac577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261419a838351613dd2565b94860194925090850190600101614160565b50909998505050505050505050565b6bffffffffffffffffffffffff811681146107dc57600080fd5b600080604083850312156141e857600080fd5b82356141f381613e49565b91506020830135614203816141bb565b809150509250929050565b60008060006040848603121561422357600080fd5b833561422e81613e49565b9250602084013567ffffffffffffffff81111561424a57600080fd5b61425686828701613d0c565b9497909650939450505050565b602081526000611c5a60208301846140da565b60006020828403121561428857600080fd5b5035919050565b60008083601f8401126142a157600080fd5b50813567ffffffffffffffff8111156142b957600080fd5b6020830191508360208260051b8501011115613d4e57600080fd5b60008060008060008060008060e0898b0312156142f057600080fd5b606089018a81111561430157600080fd5b8998503567ffffffffffffffff8082111561431b57600080fd5b6143278c838d01613d0c565b909950975060808b013591508082111561434057600080fd5b61434c8c838d0161428f565b909750955060a08b013591508082111561436557600080fd5b506143728b828c0161428f565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156143a357600080fd5b85356143ae81613fd1565b9450602086013567ffffffffffffffff8111156143ca57600080fd5b6143d688828901613d0c565b90955093505060408601356143ea81613ff2565b949793965091946060013592915050565b600067ffffffffffffffff82111561441557614415613e88565b5060051b60200190565b600082601f83011261443057600080fd5b81356020614445614440836143fb565b613eb7565b82815260059290921b8401810191818101908684111561446457600080fd5b8286015b8481101561448857803561447b81613e49565b8352918301918301614468565b509695505050505050565b60ff811681146107dc57600080fd5b80356111d181614493565b60008060008060008060c087890312156144c657600080fd5b863567ffffffffffffffff808211156144de57600080fd5b6144ea8a838b0161441f565b9750602089013591508082111561450057600080fd5b61450c8a838b0161441f565b965061451a60408a016144a2565b9550606089013591508082111561453057600080fd5b61453c8a838b01613f06565b945061454a60808a01613fe7565b935060a089013591508082111561456057600080fd5b5061456d89828a01613f06565b9150509295509295509295565b600181811c9082168061458e57607f821691505b6020821081036145c7577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561051257600081815260208120601f850160051c810160208610156145f45750805b601f850160051c820191505b8181101561461357828155600101614600565b505050505050565b67ffffffffffffffff83111561463357614633613e88565b61464783614641835461457a565b836145cd565b6000601f84116001811461469957600085156146635750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561472f565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156146e857868501358255602094850194600190920191016146c8565b5086821015614723577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261476b57600080fd5b83018035915067ffffffffffffffff82111561478657600080fd5b602001915036819003821315613d4e57600080fd5b6000602082840312156147ad57600080fd5b8135611c5a81613fd1565b6000602082840312156147ca57600080fd5b8135611c5a81613ff2565b61ffff811681146107dc57600080fd5b6000602082840312156147f757600080fd5b8135611c5a816147d5565b600073ffffffffffffffffffffffffffffffffffffffff808916835267ffffffffffffffff8816602084015280871660408401525060a060608301528360a0830152838560c0840137600060c0858401015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116830101905061ffff83166080830152979650505050505050565b600082601f8301126148a757600080fd5b815160206148b7614440836143fb565b82815260059290921b840181019181810190868411156148d657600080fd5b8286015b848110156144885780516148ed81613e49565b83529183019183016148da565b60006020828403121561490c57600080fd5b815167ffffffffffffffff81111561492357600080fd5b613fc984828501614896565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036149be576149be61495e565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156149ea576149ea61495e565b5092915050565b805169ffffffffffffffffffff811681146111d157600080fd5b600080600080600060a08688031215614a2357600080fd5b614a2c866149f1565b9450602086015193506040860151925060608601519150614a4f608087016149f1565b90509295509295909350565b818103818111156108705761087061495e565b60ff81811683821601908111156108705761087061495e565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614ac957614ac9614a87565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614b3d57600080fd5b8151611c5a816141bb565b80820281158282048414176108705761087061495e565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156149ea576149ea61495e565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614bdb8184018a6140da565b90508281036080840152614bef81896140da565b905060ff871660a084015282810360c0840152614c0c8187613dd2565b905067ffffffffffffffff851660e0840152828103610100840152613c8a8185613dd2565b600080600080600060a08688031215614c4957600080fd5b8551614c54816141bb565b6020870151909550614c65816141bb565b6040870151909450614c7681613e49565b6060870151909350614c8781613e49565b608087015190925067ffffffffffffffff811115614ca457600080fd5b614cb088828901614896565b9150509295509295909350565b600080600060608486031215614cd257600080fd5b83518015158114614ce257600080fd5b6020850151909350614cf381613fd1565b6040850151909250614d0481613fd1565b809150509250925092565b67ffffffffffffffff8181168382160190808211156149ea576149ea61495e565b815167ffffffffffffffff16815261014081016020830151614d6a602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151614d82604084018263ffffffff169052565b50606083015160608301526080830151614db4608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a0830151614dd460a08401826bffffffffffffffffffffffff169052565b5060c0830151614df460c08401826bffffffffffffffffffffffff169052565b5060e0830151614e1460e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b600080600080600080600080610100898b031215614e4f57600080fd5b8851614e5a81613ff2565b60208a0151909850614e6b81613ff2565b60408a0151909750614e7c81613ff2565b60608a0151909650614e8d81613ff2565b60808a015160a08b01519196509450614ea581613ff2565b60c08a0151909350614eb6816141bb565b60e08a0151909250614ec7816147d5565b809150509295985092959890939650565b60006bffffffffffffffffffffffff80841680614ef757614ef7614a87565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156149ea576149ea61495e565b600060ff821660ff8103614f3e57614f3e61495e565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614f6f57614f6f61495e565b505092915050565b808201808211156108705761087061495e565b600082601f830112614f9b57600080fd5b81356020614fab614440836143fb565b82815260059290921b84018101918181019086841115614fca57600080fd5b8286015b8481101561448857803567ffffffffffffffff811115614fee5760008081fd5b614ffc8986838b0101613f06565b845250918301918301614fce565b60008060006060848603121561501f57600080fd5b833567ffffffffffffffff8082111561503757600080fd5b818601915086601f83011261504b57600080fd5b8135602061505b614440836143fb565b82815260059290921b8401810191818101908a84111561507a57600080fd5b948201945b838610156150985785358252948201949082019061507f565b975050870135925050808211156150ae57600080fd5b6150ba87838801614f8a565b935060408601359150808211156150d057600080fd5b506150dd86828701614f8a565b9150509250925092565b6000826150f6576150f6614a87565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151428285018b6140da565b91508382036080850152615156828a6140da565b915060ff881660a085015283820360c08501526151738288613dd2565b90861660e08501528381036101008501529050613c8a8185613dd2565b86815260c0602082015260006151a960c0830188613dd2565b82810360408401526151bb8188613dd2565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b6000806040838503121561521457600080fd5b825161521f81614493565b6020840151909250614203816141bb565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a081016007831061529c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"OCRConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"caller\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200598e3803806200598e833981016040819052620000349162000444565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006169350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000222919062000554565b985098509850985098509850985098509850600085136200025a576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160601b038a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e805461ffff19169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590620003fd908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160601b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200042957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200045a57600080fd5b620004658462000411565b602085810151919450906001600160401b03808211156200048557600080fd5b818701915087601f8301126200049a57600080fd5b815181811115620004af57620004af6200042e565b604051601f8201601f19908116603f01168101908382118183101715620004da57620004da6200042e565b816040528281528a86848701011115620004f357600080fd5b600093505b82841015620005175784840186015181850187015292850192620004f8565b6000868483010152809750505050505050620005366040850162000411565b90509250925092565b805163ffffffff811681146200042957600080fd5b60008060008060008060008060006101208a8c0312156200057457600080fd5b6200057f8a6200053f565b98506200058f60208b016200053f565b97506200059f60408b016200053f565b9650620005af60608b016200053f565b955060808a01519450620005c660a08b016200053f565b60c08b01519094506001600160601b0381168114620005e457600080fd5b60e08b015190935061ffff81168114620005fd57600080fd5b809250506101008a015190509295985092959850929598565b60805161535c620006326000396000611471015261535c6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146104c6578063de9dfa46146104ce578063e3d0e712146104e1578063f2fde38b146104f457600080fd5b8063b1dc65a4146103ce578063c3f909d4146103e1578063d227d245146104b357600080fd5b80639883c10d116100c85780639883c10d14610394578063af1296d3146103a6578063afcb95d7146103ae57600080fd5b806381ff70481461031957806385b214cf146103495780638da5cb5b1461036c57600080fd5b8063533989871161015b5780637f15e166116101355780637f15e166146102d657806380756031146102e957806381411834146102fc57806381f1b9381461031157600080fd5b806353398987146102a557806366316d8d146102bb57806379ba5097146102ce57600080fd5b806326ceabac1161018c57806326ceabac1461024f578063354497aa14610262578063466557181461027557600080fd5b8063083a5466146101b35780630a33e0a5146101c8578063181f5a771461020d575b600080fd5b6101c66101c1366004613dee565b610507565b005b6101db6101d6366004613e30565b61055c565b604080519485526bffffffffffffffffffffffff90931660208501529183015260608201526080015b60405180910390f35b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b6040516102049190613ecf565b6101c661025d366004613f04565b610782565b6101c661027036600461402d565b610824565b61028861028336600461409d565b61088b565b6040516bffffffffffffffffffffffff9091168152602001610204565b6102ad6108bb565b6040516102049291906141c4565b6101c66102c936600461426e565b610b6a565b6101c6610ce8565b6101c66102e4366004613dee565b610dea565b6101c66102f73660046142a7565b610e3a565b610304610ef1565b60405161020491906142fc565b610242610f60565b6004546002546040805163ffffffff80851682526401000000009094049093166020840152820152606001610204565b61035c61035736600461430f565b611031565b6040519015158152602001610204565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610204565b6008545b604051908152602001610204565b61039861121b565b604080516001815260006020820181905291810191909152606001610204565b6101c66103dc36600461436d565b6112fe565b61044f600c54600d54600a54600e54600f5463ffffffff8086169664010000000087048216966c01000000000000000000000000810483169695680100000000000000009091049092169373ffffffffffffffffffffffffffffffffffffffff9092169261ffff9092169190565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e081019190915261010001610204565b6102886104c1366004614424565b611a2f565b610242611bb4565b6102886104dc36600461409d565b611c0b565b6101c66104ef366004614546565b611ca6565b6101c6610502366004613f04565b61268a565b61050f61269b565b600081900361054a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60146105578284836146b4565b505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff1633146105b6576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6105c360208601866147cf565b90506000036105fd576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160808101909152600090806106196020890189614834565b67ffffffffffffffff16815260200161063860a0890160808a01613f04565b73ffffffffffffffffffffffffffffffffffffffff1681526020016106636080890160608a01614851565b63ffffffff1681523a6020918201529091506106d090610685908801886147cf565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506106ca925050506060890160408a0161487e565b8361271e565b929750909550935091506106ea60a0870160808801613f04565b73ffffffffffffffffffffffffffffffffffffffff16857fb108b073fa485003d66284614f1c3b4feb3f47ffc88f7873bf3b2ec4bb8939bc3261073060208b018b614834565b61074060c08c0160a08d01613f04565b61074d60208d018d6147cf565b8d6040016020810190610760919061487e565b6040516107729695949392919061489b565b60405180910390a3509193509193565b60005473ffffffffffffffffffffffffffffffffffffffff163314806107bd57503373ffffffffffffffffffffffffffffffffffffffff8216145b6107f3576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260136020526040812061082191613d33565b50565b60095473ffffffffffffffffffffffffffffffffffffffff163314610875576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61087e81612d48565b8051602090910120600855565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa15801561090b573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526109519190810190614993565b90506000815167ffffffffffffffff81111561096f5761096f613f21565b6040519080825280602002602001820160405280156109a257816020015b606081526020019060019003908161098d5790505b50905060005b8251811015610b6057601360008483815181106109c7576109c76149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610a1490614613565b9050600003610a4f576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60136000848381518110610a6557610a656149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610ab290614613565b80601f0160208091040260200160405190810160405280929190818152602001828054610ade90614613565b8015610b2b5780601f10610b0057610100808354040283529160200191610b2b565b820191906000526020600020905b815481529060010190602001808311610b0e57829003601f168201915b5050505050828281518110610b4257610b426149c8565b60200260200101819052508080610b5890614a26565b9150506109a8565b5090939092509050565b610b7261300f565b806bffffffffffffffffffffffff16600003610ba85750336000908152601060205260409020546bffffffffffffffffffffffff165b336000908152601060205260409020546bffffffffffffffffffffffff80831691161015610c02576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526010602052604081208054839290610c2f9084906bffffffffffffffffffffffff16614a5e565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610ccb57600080fd5b505af1158015610cdf573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610d6e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610df261269b565b6000819003610e2d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60126105578284836146b4565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610e855750610e64336131a8565b8015610e8557503373ffffffffffffffffffffffffffffffffffffffff8416145b610ebb576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601360205260409020610eeb8284836146b4565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610f5657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610f2b575b5050505050905090565b606060148054610f6f90614613565b9050600003610faa576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60148054610fb790614613565b80601f0160208091040260200160405190810160405280929190818152602001828054610fe390614613565b8015610f565780601f1061100557610100808354040283529160200191610f56565b820191906000526020600020905b81548152906001019060200180831161101357509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314611085576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e08401526004810154610100840152600501546101208301526111935750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156112a5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112c99190614aa4565b509350509250508280156112eb57506112e28142614af4565b8463ffffffff16105b156112f657600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161135491849163ffffffff851691908e908e90819084018382808284376000920191909152506132bc92505050565b61138a576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461145f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610d65565b61146d8b8b8b8b8b8b6132c5565b60007f0000000000000000000000000000000000000000000000000000000000000000156114ca576002826020015183604001516114ab9190614b07565b6114b59190614b4f565b6114c0906001614b07565b60ff1690506114e0565b60208201516114da906001614b07565b60ff1690505b888114611549576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610d65565b8887146115b2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610d65565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156115f5576115f5614b71565b600281111561160657611606614b71565b905250905060028160200151600281111561162357611623614b71565b14801561166a57506007816000015160ff1681548110611645576116456149c8565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6116d0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610d65565b50505050506116dd613d6d565b6000808a8a6040516116f0929190614ba0565b604051908190038120611707918e90602001614bb0565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611a11576000600184898460208110611770576117706149c8565b61177d91901a601b614b07565b8e8e8681811061178f5761178f6149c8565b905060200201358d8d878181106117a8576117a86149c8565b90506020020135604051600081526020016040526040516117e5949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611807573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561188757611887614b71565b600281111561189857611898614b71565b90525092506001836020015160028111156118b5576118b5614b71565b1461191c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610d65565b8251600090879060ff16601f8110611936576119366149c8565b602002015173ffffffffffffffffffffffffffffffffffffffff16146119b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610d65565b8086846000015160ff16601f81106119d2576119d26149c8565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526119fd600186614b07565b94505080611a0a90614a26565b9050611751565b505050611a22833383858e8e613373565b5050505050505050505050565b60006301c9c3808363ffffffff161115611a8957600c546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff80861660048301529091166024820152604401610d65565b620f4240821115611ac6576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808867ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018563ffffffff1681526020018481525090506000611b5487878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061088b915050565b90506000611b9988888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611c0b915050565b9050611ba786868484613618565b9998505050505050505050565b606060128054611bc390614613565b9050600003611bfe576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60128054610fb790614613565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611c7b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c9f9190614bc4565b9392505050565b855185518560ff16601f831115611d19576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610d65565b60008111611d83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610d65565b818314611e11576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610d65565b611e1c816003614be1565b8311611e84576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610d65565b611e8c61269b565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611ed39088613788565b6006541561208857600654600090611eed90600190614af4565b9050600060068281548110611f0457611f046149c8565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f3e57611f3e6149c8565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090811690915592909116808452922080549091169055600680549192509080611fbe57611fbe614bf8565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061202757612027614bf8565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611ed3915050565b60005b8151518110156124ed57600060056000846000015184815181106120b1576120b16149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156120fb576120fb614b71565b14612162576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610d65565b6040805180820190915260ff82168152600160208201528251805160059160009185908110612193576121936149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561223457612234614b71565b0217905550600091506122449050565b600560008460200151848151811061225e5761225e6149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122a8576122a8614b71565b1461230f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610d65565b6040805180820190915260ff821681526020810160028152506005600084602001518481518110612342576123426149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156123e3576123e3614b71565b021790555050825180516006925083908110612401576124016149c8565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600791908390811061247d5761247d6149c8565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556124e681614a26565b905061208b565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff43811682029283178555908304811693600193909260009261257f928692908216911617614c27565b92506101000a81548163ffffffff021916908363ffffffff1602179055506125de4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516137a5565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a099861267d988b98919763ffffffff909216969095919491939192614c44565b60405180910390a1611a22565b61269261269b565b61082181613850565b60005473ffffffffffffffffffffffffffffffffffffffff16331461271c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d65565b565b600e5460009081908190819061ffff908116908716111561276b576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c54604086015163ffffffff918216911611156127cd57604085810151600c5491517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff918216600482015291166024820152604401610d65565b60006127d9888761088b565b905060006127e78988611c0b565b905060006127ff886040015189606001518585613618565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa158015612882573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526128c89190810190614cca565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015612959573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061297d9190614d56565b509150506bffffffffffffffffffffffff851661299a8385614a5e565b6bffffffffffffffffffffffff1610156129e0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612a5f308e602001518f600001518560016129fd9190614da8565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff16612b4b9190614c27565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee542290612cf8908490614dc9565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b600080600080600080600080600089806020019051810190612d6a9190614ecb565b98509850985098509850985098509850985060008513612db9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610d65565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526bffffffffffffffffffffffff8a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590612ffb908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526bffffffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b6000613019610ef1565b90508051600003613056576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051601154600091613075916bffffffffffffffffffffffff16614f7b565b905060005b82518160ff161015613149578160106000858460ff16815181106130a0576130a06149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166131089190614fa6565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550808061314190614fcb565b91505061307a565b5081516131569082614fea565b601180546000906131769084906bffffffffffffffffffffffff16614a5e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa1580156131f6573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261323c9190810190614993565b905060005b81518110156132b2578373ffffffffffffffffffffffffffffffffffffffff16828281518110613273576132736149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036132a0575060019392505050565b806132aa81614a26565b915050613241565b5060009392505050565b60019392505050565b60006132d2826020614be1565b6132dd856020614be1565b6132e98861014461501a565b6132f3919061501a565b6132fd919061501a565b61330890600061501a565b9050368114610cdf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610d65565b60608080613383848601866150ad565b82519295509093509150158061339b57508151835114155b806133a857508051835114155b156133df576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b835181101561360c576000613443858381518110613402576134026149c8565b602002602001015185848151811061341c5761341c6149c8565b6020026020010151858581518110613436576134366149c8565b6020026020010151613945565b9050600081600681111561345957613459614b71565b14806134765750600181600681111561347457613474614b71565b145b156134d15784828151811061348d5761348d6149c8565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a26135f9565b60028160068111156134e5576134e5614b71565b03613535578482815181106134fc576134fc6149c8565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a26135f9565b600381600681111561354957613549614b71565b0361359957848281518110613560576135606149c8565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a26135f9565b60058160068111156135ad576135ad614b71565b036135f9578482815181106135c4576135c46149c8565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a25b508061360481614a26565b9150506133e2565b50505050505050505050565b60008061362361121b565b905060008113613662576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d65565b600c5460009087906136989063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c27565b6136a29190614c27565b63ffffffff1690506000612710600c60030154886136c09190614be1565b6136ca919061518a565b6136d4908861501a565b9050600083836136ec84670de0b6b3a7640000614be1565b6136f69190614be1565b613700919061518a565b9050600061371f6bffffffffffffffffffffffff808916908a1661501a565b9050613737816b033b2e3c9fd0803ce8000000614af4565b821115613770576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61377a818361501a565b9a9950505050505050505050565b6000613792610ef1565b5111156137a1576137a161300f565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016137c99998979695949392919061519e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036138cf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d65565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613a54576002915050611c9f565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613ab261121b565b905060008113613af1576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d65565b600081613b063a670de0b6b3a7640000614be1565b613b10919061518a565b9050600083610100015182613b259190614be1565b905060008460a0015182613b399190614fa6565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613ba1908f908f908f908c908b903390600401615233565b60408051808303816000875af1158015613bbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613be391906152a4565b9092509050613bf28186614fa6565b33600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601180549193909291613c5291859116614fa6565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613cb89190614fa6565b60c08d015160a08e0151613ccc888d614fa6565b613cd69190614fa6565b613ce09190614fa6565b8760ff166006811115613cf557613cf5614b71565b604051613d069594939291906152d3565b60405180910390a28160ff166006811115613d2357613d23614b71565b9c9b505050505050505050505050565b508054613d3f90614613565b6000825580601f10613d4f575050565b601f0160209004906000526020600020908101906108219190613d8c565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613da15760008155600101613d8d565b5090565b60008083601f840112613db757600080fd5b50813567ffffffffffffffff811115613dcf57600080fd5b602083019150836020828501011115613de757600080fd5b9250929050565b60008060208385031215613e0157600080fd5b823567ffffffffffffffff811115613e1857600080fd5b613e2485828601613da5565b90969095509350505050565b600060208284031215613e4257600080fd5b813567ffffffffffffffff811115613e5957600080fd5b820160c08185031215611c9f57600080fd5b6000815180845260005b81811015613e9157602081850181015186830182015201613e75565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611c9f6020830184613e6b565b73ffffffffffffffffffffffffffffffffffffffff8116811461082157600080fd5b600060208284031215613f1657600080fd5b8135611c9f81613ee2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613f9757613f97613f21565b604052919050565b600082601f830112613fb057600080fd5b813567ffffffffffffffff811115613fca57613fca613f21565b613ffb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f50565b81815284602083860101111561401057600080fd5b816020850160208301376000918101602001919091529392505050565b60006020828403121561403f57600080fd5b813567ffffffffffffffff81111561405657600080fd5b61406284828501613f9f565b949350505050565b67ffffffffffffffff8116811461082157600080fd5b80356112168161406a565b63ffffffff8116811461082157600080fd5b60008082840360a08112156140b157600080fd5b833567ffffffffffffffff808211156140c957600080fd5b6140d587838801613f9f565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561410757600080fd5b6040519250608083019150828210818311171561412657614126613f21565b5060405260208401356141388161406a565b8152604084013561414881613ee2565b6020820152606084013561415b8161408b565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156141b957815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614187565b509495945050505050565b6040815260006141d76040830185614173565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614245577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614233838351613e6b565b948601949250908501906001016141f9565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461082157600080fd5b6000806040838503121561428157600080fd5b823561428c81613ee2565b9150602083013561429c81614254565b809150509250929050565b6000806000604084860312156142bc57600080fd5b83356142c781613ee2565b9250602084013567ffffffffffffffff8111156142e357600080fd5b6142ef86828701613da5565b9497909650939450505050565b602081526000611c9f6020830184614173565b60006020828403121561432157600080fd5b5035919050565b60008083601f84011261433a57600080fd5b50813567ffffffffffffffff81111561435257600080fd5b6020830191508360208260051b8501011115613de757600080fd5b60008060008060008060008060e0898b03121561438957600080fd5b606089018a81111561439a57600080fd5b8998503567ffffffffffffffff808211156143b457600080fd5b6143c08c838d01613da5565b909950975060808b01359150808211156143d957600080fd5b6143e58c838d01614328565b909750955060a08b01359150808211156143fe57600080fd5b5061440b8b828c01614328565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561443c57600080fd5b85356144478161406a565b9450602086013567ffffffffffffffff81111561446357600080fd5b61446f88828901613da5565b90955093505060408601356144838161408b565b949793965091946060013592915050565b600067ffffffffffffffff8211156144ae576144ae613f21565b5060051b60200190565b600082601f8301126144c957600080fd5b813560206144de6144d983614494565b613f50565b82815260059290921b840181019181810190868411156144fd57600080fd5b8286015b8481101561452157803561451481613ee2565b8352918301918301614501565b509695505050505050565b60ff8116811461082157600080fd5b80356112168161452c565b60008060008060008060c0878903121561455f57600080fd5b863567ffffffffffffffff8082111561457757600080fd5b6145838a838b016144b8565b9750602089013591508082111561459957600080fd5b6145a58a838b016144b8565b96506145b360408a0161453b565b955060608901359150808211156145c957600080fd5b6145d58a838b01613f9f565b94506145e360808a01614080565b935060a08901359150808211156145f957600080fd5b5061460689828a01613f9f565b9150509295509295509295565b600181811c9082168061462757607f821691505b602082108103614660577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561055757600081815260208120601f850160051c8101602086101561468d5750805b601f850160051c820191505b818110156146ac57828155600101614699565b505050505050565b67ffffffffffffffff8311156146cc576146cc613f21565b6146e0836146da8354614613565b83614666565b6000601f84116001811461473257600085156146fc5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147c8565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147815786850135825560209485019460019092019101614761565b50868210156147bc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261480457600080fd5b83018035915067ffffffffffffffff82111561481f57600080fd5b602001915036819003821315613de757600080fd5b60006020828403121561484657600080fd5b8135611c9f8161406a565b60006020828403121561486357600080fd5b8135611c9f8161408b565b61ffff8116811461082157600080fd5b60006020828403121561489057600080fd5b8135611c9f8161486e565b600073ffffffffffffffffffffffffffffffffffffffff808916835267ffffffffffffffff8816602084015280871660408401525060a060608301528360a0830152838560c0840137600060c0858401015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116830101905061ffff83166080830152979650505050505050565b600082601f83011261494057600080fd5b815160206149506144d983614494565b82815260059290921b8401810191818101908684111561496f57600080fd5b8286015b8481101561452157805161498681613ee2565b8352918301918301614973565b6000602082840312156149a557600080fd5b815167ffffffffffffffff8111156149bc57600080fd5b6140628482850161492f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614a5757614a576149f7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614a8357614a836149f7565b5092915050565b805169ffffffffffffffffffff8116811461121657600080fd5b600080600080600060a08688031215614abc57600080fd5b614ac586614a8a565b9450602086015193506040860151925060608601519150614ae860808701614a8a565b90509295509295909350565b818103818111156108b5576108b56149f7565b60ff81811683821601908111156108b5576108b56149f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614b6257614b62614b20565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614bd657600080fd5b8151611c9f81614254565b80820281158282048414176108b5576108b56149f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614a8357614a836149f7565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614c748184018a614173565b90508281036080840152614c888189614173565b905060ff871660a084015282810360c0840152614ca58187613e6b565b905067ffffffffffffffff851660e0840152828103610100840152613d238185613e6b565b600080600080600060a08688031215614ce257600080fd5b8551614ced81614254565b6020870151909550614cfe81614254565b6040870151909450614d0f81613ee2565b6060870151909350614d2081613ee2565b608087015190925067ffffffffffffffff811115614d3d57600080fd5b614d498882890161492f565b9150509295509295909350565b600080600060608486031215614d6b57600080fd5b83518015158114614d7b57600080fd5b6020850151909350614d8c8161406a565b6040850151909250614d9d8161406a565b809150509250925092565b67ffffffffffffffff818116838216019080821115614a8357614a836149f7565b815167ffffffffffffffff16815261014081016020830151614e03602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151614e1b604084018263ffffffff169052565b50606083015160608301526080830151614e4d608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a0830151614e6d60a08401826bffffffffffffffffffffffff169052565b5060c0830151614e8d60c08401826bffffffffffffffffffffffff169052565b5060e0830151614ead60e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60008060008060008060008060006101208a8c031215614eea57600080fd5b8951614ef58161408b565b60208b0151909950614f068161408b565b60408b0151909850614f178161408b565b60608b0151909750614f288161408b565b60808b015160a08c01519197509550614f408161408b565b60c08b0151909450614f5181614254565b60e08b0151909350614f628161486e565b809250506101008a015190509295985092959850929598565b60006bffffffffffffffffffffffff80841680614f9a57614f9a614b20565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614a8357614a836149f7565b600060ff821660ff8103614fe157614fe16149f7565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114615012576150126149f7565b505092915050565b808201808211156108b5576108b56149f7565b600082601f83011261503e57600080fd5b8135602061504e6144d983614494565b82815260059290921b8401810191818101908684111561506d57600080fd5b8286015b8481101561452157803567ffffffffffffffff8111156150915760008081fd5b61509f8986838b0101613f9f565b845250918301918301615071565b6000806000606084860312156150c257600080fd5b833567ffffffffffffffff808211156150da57600080fd5b818601915086601f8301126150ee57600080fd5b813560206150fe6144d983614494565b82815260059290921b8401810191818101908a84111561511d57600080fd5b948201945b8386101561513b57853582529482019490820190615122565b9750508701359250508082111561515157600080fd5b61515d8783880161502d565b9350604086013591508082111561517357600080fd5b506151808682870161502d565b9150509250925092565b60008261519957615199614b20565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151e58285018b614173565b915083820360808501526151f9828a614173565b915060ff881660a085015283820360c08501526152168288613e6b565b90861660e08501528381036101008501529050613d238185613e6b565b86815260c06020820152600061524c60c0830188613e6b565b828103604084015261525e8188613e6b565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156152b757600080fd5b82516152c28161452c565b602084015190925061429c81614254565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a081016007831061533f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -285,6 +285,7 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.Ca outstruct.GasOverheadBeforeCallback = *abi.ConvertType(out[4], new(uint32)).(*uint32) outstruct.LinkPriceFeed = *abi.ConvertType(out[5], new(common.Address)).(*common.Address) outstruct.MaxSupportedRequestDataVersion = *abi.ConvertType(out[6], new(uint16)).(*uint16) + outstruct.FulfillmentGasPriceOverEstimationBP = *abi.ConvertType(out[7], new(*big.Int)).(**big.Int) return *outstruct, err @@ -1005,14 +1006,15 @@ func (it *FunctionsCoordinatorConfigSetIterator) Close() error { } type FunctionsCoordinatorConfigSet struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadBeforeCallback uint32 - GasOverheadAfterCallback uint32 - FallbackNativePerUnitLink *big.Int - DonFee *big.Int - MaxSupportedRequestDataVersion uint16 - Raw types.Log + MaxCallbackGasLimit uint32 + FeedStalenessSeconds uint32 + GasOverheadBeforeCallback uint32 + GasOverheadAfterCallback uint32 + FallbackNativePerUnitLink *big.Int + DonFee *big.Int + MaxSupportedRequestDataVersion uint16 + FulfillmentGasPriceOverEstimationBP *big.Int + Raw types.Log } func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) { @@ -2360,13 +2362,14 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseTransmitted(log } type GetConfig struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadAfterCallback *big.Int - FallbackNativePerUnitLink *big.Int - GasOverheadBeforeCallback uint32 - LinkPriceFeed common.Address - MaxSupportedRequestDataVersion uint16 + MaxCallbackGasLimit uint32 + FeedStalenessSeconds uint32 + GasOverheadAfterCallback *big.Int + FallbackNativePerUnitLink *big.Int + GasOverheadBeforeCallback uint32 + LinkPriceFeed common.Address + MaxSupportedRequestDataVersion uint16 + FulfillmentGasPriceOverEstimationBP *big.Int } type LatestConfigDetails struct { ConfigCount uint32 @@ -2422,7 +2425,7 @@ func (FunctionsCoordinatorBillingStart) Topic() common.Hash { } func (FunctionsCoordinatorConfigSet) Topic() common.Hash { - return common.HexToHash("0xd09395baf4d99e44ce1b8e96a4396a3f896d0fd5e4517993f28ce0a6fb42e227") + return common.HexToHash("0xd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c5") } func (FunctionsCoordinatorCostExceedsCommitment) Topic() common.Hash { diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index f32c24902fb..68964a591be 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../. functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a03725d15d3405d68bec96237a2155435a752c659c2b13b0746003f45e621ded functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin ea01c8210316c767b4925731a55ee03bfe5cf04f1c4663aa3115bbc36b94d01f -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin bb2992f4dccff3e9c763c7379991f9dbcfd158ac8f47c9987985f57a56cdd05f +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin e2b8bf83f35eed9162a94c6e13ac3568e044cc38f89f117612ee8d92e59467e4 functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 158fb9e0f9caea329a037f17f0b73f291906c6d9e7e44a774fb17566232785e7 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 From c3fb4aa4f6cda829f6fa1085ac59b9c8b152affa Mon Sep 17 00:00:00 2001 From: Anindita Ghosh <88458927+AnieeG@users.noreply.github.com> Date: Wed, 26 Jul 2023 12:19:47 -0700 Subject: [PATCH 005/270] TT-477 - fix chaos tests (#9940) * fix chaos labels * bump version --- integration-tests/chaos/automation_chaos_test.go | 6 +++--- integration-tests/chaos/ocr2vrf_chaos_test.go | 4 ++-- integration-tests/chaos/ocr_chaos_test.go | 6 +++--- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- 5 files changed, 11 insertions(+), 11 deletions(-) diff --git a/integration-tests/chaos/automation_chaos_test.go b/integration-tests/chaos/automation_chaos_test.go index 985cb11bcb2..a693c4568fc 100644 --- a/integration-tests/chaos/automation_chaos_test.go +++ b/integration-tests/chaos/automation_chaos_test.go @@ -193,11 +193,11 @@ func TestAutomationChaos(t *testing.T) { return } - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 1, 2, ChaosGroupMinority) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 1, 2, ChaosGroupMinority) require.NoError(t, err) - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 3, 5, ChaosGroupMajority) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 3, 5, ChaosGroupMajority) require.NoError(t, err) - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 2, 5, ChaosGroupMajorityPlus) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 2, 5, ChaosGroupMajorityPlus) require.NoError(t, err) chainClient, err := blockchain.NewEVMClient(network, testEnvironment) diff --git a/integration-tests/chaos/ocr2vrf_chaos_test.go b/integration-tests/chaos/ocr2vrf_chaos_test.go index 00723a468b2..7d10107ba56 100644 --- a/integration-tests/chaos/ocr2vrf_chaos_test.go +++ b/integration-tests/chaos/ocr2vrf_chaos_test.go @@ -134,9 +134,9 @@ func TestOCR2VRFChaos(t *testing.T) { return } - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 1, 2, ChaosGroupMinority) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 1, 2, ChaosGroupMinority) require.NoError(t, err) - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 3, 5, ChaosGroupMajority) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 3, 5, ChaosGroupMajority) require.NoError(t, err) chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) diff --git a/integration-tests/chaos/ocr_chaos_test.go b/integration-tests/chaos/ocr_chaos_test.go index 13c0db64ed1..58b4d5bea65 100644 --- a/integration-tests/chaos/ocr_chaos_test.go +++ b/integration-tests/chaos/ocr_chaos_test.go @@ -145,11 +145,11 @@ func TestOCRChaos(t *testing.T) { return } - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 1, 2, ChaosGroupMinority) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 1, 2, ChaosGroupMinority) require.NoError(t, err) - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 3, 5, ChaosGroupMajority) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 3, 5, ChaosGroupMajority) require.NoError(t, err) - err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, 2, 5, ChaosGroupMajorityPlus) + err = testEnvironment.Client.LabelChaosGroup(testEnvironment.Cfg.Namespace, "instance=", 2, 5, ChaosGroupMajorityPlus) require.NoError(t, err) chainClient, err := blockchain.NewEVMClient(blockchain.SimulatedEVMNetwork, testEnvironment) diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 106b5386532..01f69df4fe6 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -17,7 +17,7 @@ require ( github.com/pkg/errors v0.9.1 github.com/rs/zerolog v1.29.1 github.com/slack-go/slack v0.12.2 - github.com/smartcontractkit/chainlink-env v0.35.0 + github.com/smartcontractkit/chainlink-env v0.35.2 github.com/smartcontractkit/chainlink-testing-framework v1.14.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 9bbc38d3ec1..5f74da6e9d1 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1363,8 +1363,8 @@ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b h1:vh4N/K+TMG8oV7L2i4U8q5aMjlVgf5M8TAZJCsXUh4U= -github.com/smartcontractkit/chainlink-env v0.35.0 h1:bjF+OOqWJUEIGmoiOZ6k1D4q6J6S/MqD269m37u0Ub8= -github.com/smartcontractkit/chainlink-env v0.35.0/go.mod h1:hMOkTDW5k0C5B5lup1+xpPiZQPkq84YGLuFDVdTKU7A= +github.com/smartcontractkit/chainlink-env v0.35.2 h1:KhlY2LgEq5e6Or5qlkCGIv0MJjJUA0mMVTgLdWptRAM= +github.com/smartcontractkit/chainlink-env v0.35.2/go.mod h1:hMOkTDW5k0C5B5lup1+xpPiZQPkq84YGLuFDVdTKU7A= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= From 3c70cd1523d121a8f703a0f0d6cd3ea24caec4cf Mon Sep 17 00:00:00 2001 From: Awbrey Hughlett Date: Wed, 26 Jul 2023 14:46:50 -0500 Subject: [PATCH 006/270] set ocr2keepers tag to stable version (#9937) * set ocr2keepers tag to stable version * go tidy --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 06e52154e53..7a5b2b4bbd8 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0 + github.com/smartcontractkit/ocr2keepers v0.7.1 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 98f0b7f5025..d074e851ccc 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1439,8 +1439,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202306 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d/go.mod h1:AW1rNDx4YN0VJzM1OrZtsOV9ORdcqcSFtsOQO3GeOQo= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0 h1:zkXsh4MAARNXqUlsMPBzVtFVV7SN93SxQ3KfCicnans= -github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= +github.com/smartcontractkit/ocr2keepers v0.7.1 h1:10+i/DKhrSjvyrZ/+MVUiLOunWJbr3ehKYP+jXfCRuk= +github.com/smartcontractkit/ocr2keepers v0.7.1/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/go.mod b/go.mod index 3b7b8eb010b..f52cb58347f 100644 --- a/go.mod +++ b/go.mod @@ -71,7 +71,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0 + github.com/smartcontractkit/ocr2keepers v0.7.1 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c diff --git a/go.sum b/go.sum index 69c185326cb..c92089d9c77 100644 --- a/go.sum +++ b/go.sum @@ -1444,8 +1444,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202306 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d/go.mod h1:AW1rNDx4YN0VJzM1OrZtsOV9ORdcqcSFtsOQO3GeOQo= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0 h1:zkXsh4MAARNXqUlsMPBzVtFVV7SN93SxQ3KfCicnans= -github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= +github.com/smartcontractkit/ocr2keepers v0.7.1 h1:10+i/DKhrSjvyrZ/+MVUiLOunWJbr3ehKYP+jXfCRuk= +github.com/smartcontractkit/ocr2keepers v0.7.1/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 01f69df4fe6..8cc6f13cd7a 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -21,7 +21,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.14.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0 + github.com/smartcontractkit/ocr2keepers v0.7.1 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c github.com/stretchr/testify v1.8.4 github.com/umbracle/ethgo v0.1.3 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 5f74da6e9d1..6b55ea7e9d2 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1373,8 +1373,8 @@ github.com/smartcontractkit/chainlink-testing-framework v1.14.0 h1:XJSE2xnXCij1P github.com/smartcontractkit/chainlink-testing-framework v1.14.0/go.mod h1:Wio/JS9GuEAWOI0k46sUs4+/wLMZnZKz9IwCpdV/miY= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0 h1:zkXsh4MAARNXqUlsMPBzVtFVV7SN93SxQ3KfCicnans= -github.com/smartcontractkit/ocr2keepers v1.0.0-alpha.0/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= +github.com/smartcontractkit/ocr2keepers v0.7.1 h1:10+i/DKhrSjvyrZ/+MVUiLOunWJbr3ehKYP+jXfCRuk= +github.com/smartcontractkit/ocr2keepers v0.7.1/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From cdc6ae5ef873669964a0438f792f53ee7fa26622 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Wed, 26 Jul 2023 12:56:58 -0700 Subject: [PATCH 007/270] [Functions] Support subscription flags in contracts (#9903) 1. Support setting per-sub flags. 2. Extend OracleEvent with flags and gas limit fields. 3. Add gas limit list to router config and enforce it based on that list. 4. Some unrelated changes to reduce contact size. --- .../functions/dev/1_0_0/FunctionsBilling.sol | 12 +- .../dev/1_0_0/FunctionsCoordinator.sol | 12 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 59 +++++++-- .../dev/1_0_0/FunctionsSubscriptions.sol | 115 +++++++++++------- .../interfaces/IFunctionsCoordinator.sol | 5 +- .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 7 ++ .../interfaces/IFunctionsSubscriptions.sol | 15 +++ .../testhelpers/FunctionsClientTestHelper.sol | 4 +- .../v0.8/functions/v1/FunctionsClient.test.ts | 44 +++++++ .../v1/FunctionsSubscriptions.test.ts | 28 ++++- .../test/v0.8/functions/v1/GasGolf.test.ts | 1 + .../test/v0.8/functions/v1/RouterBase.test.ts | 5 +- contracts/test/v0.8/functions/v1/utils.ts | 6 +- .../functions_coordinator.go | 21 ++-- .../functions_router/functions_router.go | 67 +++++++++- ...rapper-dependency-versions-do-not-edit.txt | 4 +- 16 files changed, 305 insertions(+), 100 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 6cfca2ff8c0..3711a628ed4 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -80,7 +80,6 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { error InvalidSubscription(); error UnauthorizedSender(); error MustBeSubOwner(address owner); - error GasLimitTooBig(uint32 have, uint32 want); error InvalidLinkWeiPrice(int256 linkWei); error PaymentTooLarge(); error NoTransmittersSet(); @@ -239,9 +238,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint256 gasPrice ) external view override returns (uint96) { // Reasonable ceilings to prevent integer overflows - if (callbackGasLimit > 30_000_000 /* London upgrade's 30M block max */) { - revert GasLimitTooBig(callbackGasLimit, s_config.maxCallbackGasLimit); - } + IFunctionsRouter router = IFunctionsRouter(address(s_router)); + router.isValidCallbackGasLimit(subscriptionId, callbackGasLimit); if (gasPrice > 1_000_000) { revert InvalidCalldata(); } @@ -301,12 +299,6 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { revert UnsupportedRequestDataVersion(); } - // No lower bound on the requested gas limit. A user could request 0 - // and they would simply be billed for the gas and computation. - if (billing.callbackGasLimit > s_config.maxCallbackGasLimit) { - revert GasLimitTooBig(billing.callbackGasLimit, s_config.maxCallbackGasLimit); - } - // Check that subscription can afford the estimated cost uint96 donFee = getDONFee(data, billing); uint96 adminFee = getAdminFee(data, billing); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 5c875fd7698..96c8cad5c57 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -20,7 +20,9 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli uint64 subscriptionId, address subscriptionOwner, bytes data, - uint16 dataVersion + uint16 dataVersion, + bytes32 flags, + uint64 callbackGasLimit ); event OracleResponse(bytes32 indexed requestId, address transmitter); event InvalidRequestID(bytes32 indexed requestId); @@ -156,7 +158,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli RequestBilling memory billing = IFunctionsBilling.RequestBilling( request.subscriptionId, - request.caller, + request.requestingContract, request.callbackGasLimit, tx.gasprice ); @@ -169,12 +171,14 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli emit OracleRequest( requestId, - request.caller, + request.requestingContract, tx.origin, request.subscriptionId, request.subscriptionOwner, request.data, - request.dataVersion + request.dataVersion, + request.flags, + request.callbackGasLimit ); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 80a2f0037e8..cafd6d96551 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -32,6 +32,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions error OnlyCallableFromCoordinator(); error SenderMustAcceptTermsOfService(address sender); + error InvalidGasFlagValue(uint8 value); + error GasLimitTooBig(uint32 limit); struct CallbackResult { bool success; @@ -40,6 +42,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Identifier for the route to the Terms of Service Allow List bytes32 private constant ALLOW_LIST_ID = keccak256("Functions Terms of Service Allow List"); + uint8 private constant GAS_FLAG_INDEX = 0; // ================================================================ // | Configuration state | @@ -49,9 +52,12 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 adminFee; // The function selector that is used when calling back to the Client contract bytes4 handleOracleFulfillmentSelector; + // List of max callback gas limits used by flag with GAS_FLAG_INDEX + uint32[] maxCallbackGasLimits; } Config private s_config; - event ConfigSet(uint96 adminFee, bytes4 handleOracleFulfillmentSelector); + + event ConfigSet(uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] maxCallbackGasLimits); error OnlyCallableByRoute(); @@ -98,9 +104,16 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions * - adminFee: fee that will be paid to the Router owner for operating the network */ function _setConfig(bytes memory config) internal override { - (uint96 adminFee, bytes4 handleOracleFulfillmentSelector) = abi.decode(config, (uint96, bytes4)); - s_config = Config({adminFee: adminFee, handleOracleFulfillmentSelector: handleOracleFulfillmentSelector}); - emit ConfigSet(adminFee, handleOracleFulfillmentSelector); + (uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] memory maxCallbackGasLimits) = abi.decode( + config, + (uint96, bytes4, uint32[]) + ); + s_config = Config({ + adminFee: adminFee, + handleOracleFulfillmentSelector: handleOracleFulfillmentSelector, + maxCallbackGasLimits: maxCallbackGasLimits + }); + emit ConfigSet(adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits); } // ================================================================ @@ -117,6 +130,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions ) private returns (bytes32 requestId) { _isValidSubscription(subscriptionId); _isValidConsumer(msg.sender, subscriptionId); + _isValidCallbackGasLimit(subscriptionId, callbackGasLimit); address coordinatorAddress = _getContractById(donId, useProposed); @@ -131,12 +145,13 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions requestTimeoutSeconds ) = IFunctionsCoordinator(coordinatorAddress).sendRequest( IFunctionsCoordinator.Request( + msg.sender, subscriptionId, + s_subscriptions[subscriptionId].owner, data, dataVersion, - callbackGasLimit, - msg.sender, - s_subscriptions[subscriptionId].owner + _getFlags(subscriptionId), + callbackGasLimit ) ); @@ -194,7 +209,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint16 dataVersion, uint32 callbackGasLimit, bytes32 donId - ) external override nonReentrant whenNotPaused returns (bytes32) { + ) external override whenNotPaused returns (bytes32) { + _nonReentrant(); return _sendRequest(donId, false, subscriptionId, data, dataVersion, callbackGasLimit); } @@ -208,7 +224,9 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 juelsPerGas, uint96 costWithoutFulfillment, address transmitter - ) external override nonReentrant returns (uint8 resultCode, uint96 callbackGasCostJuels) { + ) external override returns (uint8 resultCode, uint96 callbackGasCostJuels) { + _nonReentrant(); + Commitment memory commitment = s_requestCommitments[requestId]; if (msg.sender != commitment.coordinator) { @@ -325,19 +343,34 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions result = CallbackResult(success, gasUsed); } + /** + * @inheritdoc IFunctionsRouter + */ + function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) external view { + _isValidCallbackGasLimit(subscriptionId, callbackGasLimit); + } + + function _isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) internal view { + uint8 index = uint8(_getFlags(subscriptionId)[GAS_FLAG_INDEX]); + if (index >= s_config.maxCallbackGasLimits.length) { + revert InvalidGasFlagValue(index); + } + if (callbackGasLimit > s_config.maxCallbackGasLimits[index]) { + revert GasLimitTooBig(s_config.maxCallbackGasLimits[index]); + } + } + // ================================================================ // | Modifiers | // ================================================================ - modifier onlyRouterOwner() override { + function _onlyRouterOwner() internal view override { _validateOwnership(); - _; } - modifier onlySenderThatAcceptedToS() override { + function _onlySenderThatAcceptedToS() internal override { if (ITermsOfServiceAllowList(_getContractById(ALLOW_LIST_ID, false)).isAllowedSender(msg.sender) == false) { revert SenderMustAcceptTermsOfService(msg.sender); } - _; } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 5e1d321230e..74f0c83c52a 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -50,7 +50,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei error InvalidSubscription(); error OnlyCallableFromLink(); error InvalidCalldata(); - error MustBeSubOwner(address owner); + error MustBeSubOwner(); error PendingRequestExists(); error MustBeRequestedOwner(address proposedOwner); error BalanceInvariantViolated(uint256 internalBalance, uint256 externalBalance); // Should never happen @@ -233,7 +233,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function ownerCancelSubscription(uint64 subscriptionId) external override onlyRouterOwner { + function ownerCancelSubscription(uint64 subscriptionId) external override { + _onlyRouterOwner(); address owner = s_subscriptions[subscriptionId].owner; if (owner == address(0)) { revert InvalidSubscription(); @@ -244,7 +245,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function recoverFunds(address to) external override onlyRouterOwner { + function recoverFunds(address to) external override { + _onlyRouterOwner(); uint256 externalBalance = LINK.balanceOf(address(this)); uint256 internalBalance = uint256(s_totalBalance); if (internalBalance > externalBalance) { @@ -264,7 +266,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @param recipient where to send the funds * @param amount amount to withdraw */ - function ownerWithdraw(address recipient, uint96 amount) internal nonReentrant onlyRouterOwner { + function ownerWithdraw(address recipient, uint96 amount) internal { + _nonReentrant(); + _onlyRouterOwner(); if (amount == 0) { amount = s_withdrawableTokens[address(this)]; } @@ -286,7 +290,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function oracleWithdraw(address recipient, uint96 amount) external override nonReentrant { + function oracleWithdraw(address recipient, uint96 amount) external override { + _nonReentrant(); if (amount == 0) { revert InvalidCalldata(); } @@ -303,7 +308,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ // | Deposit helper method | // ================================================================ - function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override nonReentrant { + function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override { + _nonReentrant(); if (msg.sender != address(LINK)) { revert OnlyCallableFromLink(); } @@ -328,13 +334,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function createSubscription() - external - override - nonReentrant - onlySenderThatAcceptedToS - returns (uint64 subscriptionId) - { + function createSubscription() external override returns (uint64 subscriptionId) { + _nonReentrant(); + _onlySenderThatAcceptedToS(); + s_currentsubscriptionId++; subscriptionId = s_currentsubscriptionId; s_subscriptions[subscriptionId] = Subscription({ @@ -342,7 +345,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei blockedBalance: 0, owner: msg.sender, requestedOwner: address(0), - consumers: new address[](0) + consumers: new address[](0), + flags: bytes32(0) }); emit SubscriptionCreated(subscriptionId, msg.sender); @@ -351,10 +355,11 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function requestSubscriptionOwnerTransfer( - uint64 subscriptionId, - address newOwner - ) external override onlySubscriptionOwner(subscriptionId) nonReentrant onlySenderThatAcceptedToS { + function requestSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { + _onlySubscriptionOwner(subscriptionId); + _nonReentrant(); + _onlySenderThatAcceptedToS(); + // Proposing to address(0) would never be claimable, so don't need to check. if (s_subscriptions[subscriptionId].requestedOwner != newOwner) { @@ -366,9 +371,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function acceptSubscriptionOwnerTransfer( - uint64 subscriptionId - ) external override nonReentrant onlySenderThatAcceptedToS { + function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external override { + _nonReentrant(); + _onlySenderThatAcceptedToS(); address previousOwner = s_subscriptions[subscriptionId].owner; address nextOwner = s_subscriptions[subscriptionId].requestedOwner; if (nextOwner != msg.sender) { @@ -382,10 +387,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function removeConsumer( - uint64 subscriptionId, - address consumer - ) external override onlySubscriptionOwner(subscriptionId) nonReentrant onlySenderThatAcceptedToS { + function removeConsumer(uint64 subscriptionId, address consumer) external override { + _onlySubscriptionOwner(subscriptionId); + _nonReentrant(); + _onlySenderThatAcceptedToS(); Consumer memory consumerData = s_consumers[consumer][subscriptionId]; if (!consumerData.allowed) { revert InvalidConsumer(subscriptionId, consumer); @@ -413,10 +418,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function addConsumer( - uint64 subscriptionId, - address consumer - ) external override onlySubscriptionOwner(subscriptionId) nonReentrant onlySenderThatAcceptedToS { + function addConsumer(uint64 subscriptionId, address consumer) external override { + _onlySubscriptionOwner(subscriptionId); + _nonReentrant(); + _onlySenderThatAcceptedToS(); // Already maxed, cannot add any more consumers. if (s_subscriptions[subscriptionId].consumers.length == MAX_CONSUMERS) { revert TooManyConsumers(); @@ -435,17 +440,18 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function cancelSubscription( - uint64 subscriptionId, - address to - ) external override onlySubscriptionOwner(subscriptionId) nonReentrant onlySenderThatAcceptedToS { + function cancelSubscription(uint64 subscriptionId, address to) external override { + _onlySubscriptionOwner(subscriptionId); + _nonReentrant(); + _onlySenderThatAcceptedToS(); if (_pendingRequestExists(subscriptionId)) { revert PendingRequestExists(); } _cancelSubscriptionHelper(subscriptionId, to); } - function _cancelSubscriptionHelper(uint64 subscriptionId, address to) private nonReentrant { + function _cancelSubscriptionHelper(uint64 subscriptionId, address to) private { + _nonReentrant(); Subscription memory sub = s_subscriptions[subscriptionId]; uint96 balance = sub.balance; // Note bounded by MAX_CONSUMERS; @@ -479,13 +485,34 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei return false; } + /** + * @inheritdoc IFunctionsSubscriptions + */ + function setFlags(uint64 subscriptionId, bytes32 flags) external override { + _onlyRouterOwner(); + _isValidSubscription(subscriptionId); + s_subscriptions[subscriptionId].flags = flags; + } + + function _getFlags(uint64 subscriptionId) internal view returns (bytes32) { + return s_subscriptions[subscriptionId].flags; + } + + /** + * @inheritdoc IFunctionsSubscriptions + */ + function getFlags(uint64 subscriptionId) external view returns (bytes32) { + return _getFlags(subscriptionId); + } + // ================================================================ // | Request Timeout Methods | // ================================================================ /** * @inheritdoc IFunctionsSubscriptions */ - function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external override nonReentrant { + function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external override { + _nonReentrant(); for (uint256 i = 0; i < requestIdsToTimeout.length; i++) { bytes32 requestId = requestIdsToTimeout[i]; Commitment memory request = s_requestCommitments[requestId]; @@ -495,7 +522,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _isValidSubscription(subscriptionId); address owner = s_subscriptions[subscriptionId].owner; if (msg.sender != owner) { - revert MustBeSubOwner(owner); + revert MustBeSubOwner(); } // Check that request has exceeded allowed request time @@ -518,29 +545,23 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ // | Modifiers | // ================================================================ - modifier onlySubscriptionOwner(uint64 subscriptionId) { + function _onlySubscriptionOwner(uint64 subscriptionId) internal view { address owner = s_subscriptions[subscriptionId].owner; if (owner == address(0)) { revert InvalidSubscription(); } if (msg.sender != owner) { - revert MustBeSubOwner(owner); + revert MustBeSubOwner(); } - _; } - modifier nonReentrant() { + function _nonReentrant() internal view { if (s_reentrancyLock) { revert Reentrant(); } - _; } - modifier onlySenderThatAcceptedToS() virtual { - _; - } + function _onlySenderThatAcceptedToS() internal virtual; - modifier onlyRouterOwner() virtual { - _; - } + function _onlyRouterOwner() internal virtual; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 309a2d5de04..62f5ad8af3f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -6,12 +6,13 @@ pragma solidity ^0.8.19; */ interface IFunctionsCoordinator { struct Request { + address requestingContract; // The client contract that is sending the request uint64 subscriptionId; // Identifier of the subscription that will be charged for the request + address subscriptionOwner; // The owner of the subscription bytes data; // Encoded Chainlink Functions request data, use FunctionsClient API to encode a request uint16 dataVersion; // The version of the structure of the encoded data + bytes32 flags; // Per-subscription flags uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract can utilize - address caller; // The client contract that is sending the request - address subscriptionOwner; // The owner of the subscription } /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index 932f34d0c6b..4936261330f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -60,4 +60,11 @@ interface IFunctionsRouter is IRouterBase { uint96 costWithoutFulfillment, address transmitter ) external returns (uint8, uint96); + + /** + * @notice Validate requested gas limit is below the subscription max. + * @param subscriptionId subscription ID + * @param callbackGasLimit desired callback gas limit + */ + function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) external view; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 7582764a3e1..bc792cf020d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -18,6 +18,7 @@ interface IFunctionsSubscriptions { // Note that we need the s_consumers map to be able to directly check if a // consumer is valid without reading all the consumers from storage. address[] consumers; + bytes32 flags; // Per-subscription flags. } struct Consumer { @@ -166,4 +167,18 @@ interface IFunctionsSubscriptions { * @dev Used to disable subscription canceling while outstanding request are present. */ function pendingRequestExists(uint64 subscriptionId) external view returns (bool); + + /** + * @notice Set flags for a given subscription. + * @param subscriptionId - ID of the subscription + * @param flags - desired flag values + */ + function setFlags(uint64 subscriptionId, bytes32 flags) external; + + /** + * @notice Get flags for a given subscription. + * @param subscriptionId - ID of the subscription + * @return flags - current flag values + */ + function getFlags(uint64 subscriptionId) external view returns (bytes32); } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index ceaff7b4c19..b8b5b5a88a9 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -18,10 +18,10 @@ contract FunctionsClientTestHelper is FunctionsClient { function sendSimpleRequestWithJavaScript( string memory sourceCode, uint64 subscriptionId, - bytes32 donId + bytes32 donId, + uint32 callbackGasLimit ) public returns (bytes32 requestId) { Functions.Request memory request; - uint32 callbackGasLimit = 20_000; request.initializeRequestForInlineJavaScript(sourceCode); requestId = _sendRequest(request, subscriptionId, callbackGasLimit, donId); emit SendRequestInvoked(requestId, sourceCode, subscriptionId); diff --git a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts index c7ee07fd92a..744d8a851d4 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts @@ -30,6 +30,10 @@ describe('Functions Client', () => { contracts.accessControl, contracts.linkToken, ) + const flags = + '0x0101010101010101010101010101010101010101010101010101010101010101' + const callbackGas = 100_000 + await contracts.router.setFlags(subscriptionId, flags) const defaultAccountAddress = await roles.defaultAccount.getAddress() await expect( contracts.client @@ -38,6 +42,7 @@ describe('Functions Client', () => { 'return `hello world`', subscriptionId, ids.donId, + callbackGas, ), ) .to.emit(contracts.client, 'RequestSent') @@ -51,9 +56,46 @@ describe('Functions Client', () => { roles.subOwnerAddress, anyValue, anyValue, + flags, + callbackGas, ) }) + it('respects gas flag setting', async () => { + const subscriptionId = await createSubscription( + roles.subOwner, + [contracts.client.address], + contracts.router, + contracts.accessControl, + contracts.linkToken, + ) + const flags = + '0x0101010101010101010101010101010101010101010101010101010101010101' + await contracts.router.setFlags(subscriptionId, flags) + await expect( + contracts.client + .connect(roles.defaultAccount) + .sendSimpleRequestWithJavaScript( + 'return `hello world`', + subscriptionId, + ids.donId, + 400_000, + ), + ) + .to.emit(contracts.client, 'RequestSent') + .to.emit(contracts.coordinator, 'OracleRequest') + await expect( + contracts.client + .connect(roles.defaultAccount) + .sendSimpleRequestWithJavaScript( + 'return `hello world`', + subscriptionId, + ids.donId, + 600_000, // limit set by gas flag == 1 is 500_000 + ), + ).to.be.revertedWith('GasLimitTooBig(500000)') + }) + it('encodes user request to CBOR', async () => { const subscriptionId = await createSubscription( roles.subOwner, @@ -67,6 +109,7 @@ describe('Functions Client', () => { js, subscriptionId, ids.donId, + 20_000, ) const args = await parseOracleRequestEventArgs(tx) assert.equal(args.length, 5) @@ -99,6 +142,7 @@ describe('Functions Client', () => { 'function run(){return response}', subscriptionId, ids.donId, + 20_000, ) const { events } = await tx.wait() const requestId = getEventArg(events, 'RequestSent', 0) diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index f93748002dd..b4180b62371 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -90,7 +90,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.stranger) .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ).to.be.revertedWith(`MustBeSubOwner("${roles.subOwnerAddress}")`) + ).to.be.revertedWith(`MustBeSubOwner()`) }) it('owner can request transfer', async function () { await expect( @@ -184,7 +184,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.stranger) .addConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`MustBeSubOwner("${roles.subOwnerAddress}")`) + ).to.be.revertedWith(`MustBeSubOwner()`) }) it('add is idempotent', async function () { await contracts.router @@ -260,7 +260,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.stranger) .removeConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`MustBeSubOwner("${roles.subOwnerAddress}")`) + ).to.be.revertedWith(`MustBeSubOwner()`) }) it('owner can update', async function () { const subBefore = await contracts.router.getSubscription(subId) @@ -330,6 +330,7 @@ describe('Functions Router - Subscriptions', () => { `return 'hello world'`, subId, donLabel, + 20_000, ) expect( await contracts.router @@ -361,7 +362,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.stranger) .cancelSubscription(subId, roles.subOwnerAddress), - ).to.be.revertedWith(`MustBeSubOwner("${roles.subOwnerAddress}")`) + ).to.be.revertedWith(`MustBeSubOwner()`) }) it('can cancel', async function () { await contracts.linkToken @@ -430,6 +431,7 @@ describe('Functions Router - Subscriptions', () => { `return 'hello world'`, subId, donLabel, + 20_000, ) // Should revert with outstanding requests await expect( @@ -550,4 +552,22 @@ describe('Functions Router - Subscriptions', () => { ).to.be.revertedWith(`InsufficientBalance`) }) }) + + describe('#flagsSet', async function () { + it('get flags that were previously set', async function () { + const flags = ethers.utils.formatBytes32String('arbitrary_byte_values') + await acceptTermsOfService( + contracts.accessControl, + roles.subOwner, + roles.subOwnerAddress, + ) + await expect( + contracts.router.connect(roles.subOwner).createSubscription(), + ) + .to.emit(contracts.router, 'SubscriptionCreated') + .withArgs(1, roles.subOwnerAddress) + await contracts.router.setFlags(1, flags) + expect(await contracts.router.getFlags(1)).to.equal(flags) + }) + }) }) diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index f0c1bb96f7d..d9c263261fe 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -74,6 +74,7 @@ describe('Gas Golf', () => { 'function myFancyFunction(){return "woah, thats fancy"}', subscriptionId, ids.donId, + 20_000, ) const { gasUsed: requestTxGasUsed, events } = await requestTx.wait() const requestId = getEventArg(events, 'RequestSent', 0) diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 7abba95d478..2d4d0a897f5 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -70,8 +70,8 @@ describe('FunctionsRouter - Base', () => { contracts.router.proposeConfigUpdate( ids.routerId, ethers.utils.defaultAbiCoder.encode( - ['uint96', 'bytes4'], - [1, 0x0ca76175], + ['uint96', 'bytes4', 'uint32[]'], + [1, 0x0ca76175, [300_000, 500_000]], ), ), ).to.emit(contracts.router, 'ConfigProposed') @@ -380,6 +380,7 @@ describe('FunctionsRouter - Base', () => { `return 'hello world'`, subscriptionId, ids.donId, + 20_000, ), ).to.be.revertedWith('Pausable: paused') }) diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index f481130b313..6f535dddb92 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -58,10 +58,12 @@ export const encodeReport = ( export type FunctionsRouterConfig = { adminFee: number handleOracleFulfillmentSelector: string + maxCallbackGasLimits: number[] } export const functionsRouterConfig: FunctionsRouterConfig = { adminFee: 0, handleOracleFulfillmentSelector: '0x0ca76175', + maxCallbackGasLimits: [300_000, 500_000, 1_000_000], } export type CoordinatorConfig = { maxCallbackGasLimit: number @@ -186,7 +188,7 @@ export async function createSubscription( .connect(owner) .transferAndCall( router.address, - BigNumber.from('54666805176129187'), + BigNumber.from('1000000000000000000'), ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), ) } @@ -220,7 +222,7 @@ export function getSetupFactory(): () => { linkEthRate, ) const routerConfigBytes = ethers.utils.defaultAbiCoder.encode( - ['uint96', 'bytes4'], + ['uint96', 'bytes4', 'uint32[]'], [...Object.values(functionsRouterConfig)], ) const startingTimelockBlocks = 0 diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 8b642d3f16a..36df6713c6c 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -51,17 +51,18 @@ type IFunctionsBillingRequestBilling struct { } type IFunctionsCoordinatorRequest struct { - SubscriptionId uint64 - Data []byte - DataVersion uint16 - CallbackGasLimit uint32 - Caller common.Address - SubscriptionOwner common.Address + RequestingContract common.Address + SubscriptionId uint64 + SubscriptionOwner common.Address + Data []byte + DataVersion uint16 + Flags [32]byte + CallbackGasLimit uint32 } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"OCRConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"caller\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200598e3803806200598e833981016040819052620000349162000444565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006169350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000222919062000554565b985098509850985098509850985098509850600085136200025a576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160601b038a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e805461ffff19169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590620003fd908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160601b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200042957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200045a57600080fd5b620004658462000411565b602085810151919450906001600160401b03808211156200048557600080fd5b818701915087601f8301126200049a57600080fd5b815181811115620004af57620004af6200042e565b604051601f8201601f19908116603f01168101908382118183101715620004da57620004da6200042e565b816040528281528a86848701011115620004f357600080fd5b600093505b82841015620005175784840186015181850187015292850192620004f8565b6000868483010152809750505050505050620005366040850162000411565b90509250925092565b805163ffffffff811681146200042957600080fd5b60008060008060008060008060006101208a8c0312156200057457600080fd5b6200057f8a6200053f565b98506200058f60208b016200053f565b97506200059f60408b016200053f565b9650620005af60608b016200053f565b955060808a01519450620005c660a08b016200053f565b60c08b01519094506001600160601b0381168114620005e457600080fd5b60e08b015190935061ffff81168114620005fd57600080fd5b809250506101008a015190509295985092959850929598565b60805161535c620006326000396000611471015261535c6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146104c6578063de9dfa46146104ce578063e3d0e712146104e1578063f2fde38b146104f457600080fd5b8063b1dc65a4146103ce578063c3f909d4146103e1578063d227d245146104b357600080fd5b80639883c10d116100c85780639883c10d14610394578063af1296d3146103a6578063afcb95d7146103ae57600080fd5b806381ff70481461031957806385b214cf146103495780638da5cb5b1461036c57600080fd5b8063533989871161015b5780637f15e166116101355780637f15e166146102d657806380756031146102e957806381411834146102fc57806381f1b9381461031157600080fd5b806353398987146102a557806366316d8d146102bb57806379ba5097146102ce57600080fd5b806326ceabac1161018c57806326ceabac1461024f578063354497aa14610262578063466557181461027557600080fd5b8063083a5466146101b35780630a33e0a5146101c8578063181f5a771461020d575b600080fd5b6101c66101c1366004613dee565b610507565b005b6101db6101d6366004613e30565b61055c565b604080519485526bffffffffffffffffffffffff90931660208501529183015260608201526080015b60405180910390f35b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b6040516102049190613ecf565b6101c661025d366004613f04565b610782565b6101c661027036600461402d565b610824565b61028861028336600461409d565b61088b565b6040516bffffffffffffffffffffffff9091168152602001610204565b6102ad6108bb565b6040516102049291906141c4565b6101c66102c936600461426e565b610b6a565b6101c6610ce8565b6101c66102e4366004613dee565b610dea565b6101c66102f73660046142a7565b610e3a565b610304610ef1565b60405161020491906142fc565b610242610f60565b6004546002546040805163ffffffff80851682526401000000009094049093166020840152820152606001610204565b61035c61035736600461430f565b611031565b6040519015158152602001610204565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610204565b6008545b604051908152602001610204565b61039861121b565b604080516001815260006020820181905291810191909152606001610204565b6101c66103dc36600461436d565b6112fe565b61044f600c54600d54600a54600e54600f5463ffffffff8086169664010000000087048216966c01000000000000000000000000810483169695680100000000000000009091049092169373ffffffffffffffffffffffffffffffffffffffff9092169261ffff9092169190565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e081019190915261010001610204565b6102886104c1366004614424565b611a2f565b610242611bb4565b6102886104dc36600461409d565b611c0b565b6101c66104ef366004614546565b611ca6565b6101c6610502366004613f04565b61268a565b61050f61269b565b600081900361054a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60146105578284836146b4565b505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff1633146105b6576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6105c360208601866147cf565b90506000036105fd576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160808101909152600090806106196020890189614834565b67ffffffffffffffff16815260200161063860a0890160808a01613f04565b73ffffffffffffffffffffffffffffffffffffffff1681526020016106636080890160608a01614851565b63ffffffff1681523a6020918201529091506106d090610685908801886147cf565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506106ca925050506060890160408a0161487e565b8361271e565b929750909550935091506106ea60a0870160808801613f04565b73ffffffffffffffffffffffffffffffffffffffff16857fb108b073fa485003d66284614f1c3b4feb3f47ffc88f7873bf3b2ec4bb8939bc3261073060208b018b614834565b61074060c08c0160a08d01613f04565b61074d60208d018d6147cf565b8d6040016020810190610760919061487e565b6040516107729695949392919061489b565b60405180910390a3509193509193565b60005473ffffffffffffffffffffffffffffffffffffffff163314806107bd57503373ffffffffffffffffffffffffffffffffffffffff8216145b6107f3576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260136020526040812061082191613d33565b50565b60095473ffffffffffffffffffffffffffffffffffffffff163314610875576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61087e81612d48565b8051602090910120600855565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa15801561090b573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526109519190810190614993565b90506000815167ffffffffffffffff81111561096f5761096f613f21565b6040519080825280602002602001820160405280156109a257816020015b606081526020019060019003908161098d5790505b50905060005b8251811015610b6057601360008483815181106109c7576109c76149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610a1490614613565b9050600003610a4f576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60136000848381518110610a6557610a656149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610ab290614613565b80601f0160208091040260200160405190810160405280929190818152602001828054610ade90614613565b8015610b2b5780601f10610b0057610100808354040283529160200191610b2b565b820191906000526020600020905b815481529060010190602001808311610b0e57829003601f168201915b5050505050828281518110610b4257610b426149c8565b60200260200101819052508080610b5890614a26565b9150506109a8565b5090939092509050565b610b7261300f565b806bffffffffffffffffffffffff16600003610ba85750336000908152601060205260409020546bffffffffffffffffffffffff165b336000908152601060205260409020546bffffffffffffffffffffffff80831691161015610c02576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526010602052604081208054839290610c2f9084906bffffffffffffffffffffffff16614a5e565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610ccb57600080fd5b505af1158015610cdf573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610d6e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610df261269b565b6000819003610e2d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60126105578284836146b4565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610e855750610e64336131a8565b8015610e8557503373ffffffffffffffffffffffffffffffffffffffff8416145b610ebb576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601360205260409020610eeb8284836146b4565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610f5657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610f2b575b5050505050905090565b606060148054610f6f90614613565b9050600003610faa576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60148054610fb790614613565b80601f0160208091040260200160405190810160405280929190818152602001828054610fe390614613565b8015610f565780601f1061100557610100808354040283529160200191610f56565b820191906000526020600020905b81548152906001019060200180831161101357509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314611085576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e08401526004810154610100840152600501546101208301526111935750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156112a5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112c99190614aa4565b509350509250508280156112eb57506112e28142614af4565b8463ffffffff16105b156112f657600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161135491849163ffffffff851691908e908e90819084018382808284376000920191909152506132bc92505050565b61138a576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461145f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610d65565b61146d8b8b8b8b8b8b6132c5565b60007f0000000000000000000000000000000000000000000000000000000000000000156114ca576002826020015183604001516114ab9190614b07565b6114b59190614b4f565b6114c0906001614b07565b60ff1690506114e0565b60208201516114da906001614b07565b60ff1690505b888114611549576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610d65565b8887146115b2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610d65565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156115f5576115f5614b71565b600281111561160657611606614b71565b905250905060028160200151600281111561162357611623614b71565b14801561166a57506007816000015160ff1681548110611645576116456149c8565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6116d0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610d65565b50505050506116dd613d6d565b6000808a8a6040516116f0929190614ba0565b604051908190038120611707918e90602001614bb0565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611a11576000600184898460208110611770576117706149c8565b61177d91901a601b614b07565b8e8e8681811061178f5761178f6149c8565b905060200201358d8d878181106117a8576117a86149c8565b90506020020135604051600081526020016040526040516117e5949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611807573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561188757611887614b71565b600281111561189857611898614b71565b90525092506001836020015160028111156118b5576118b5614b71565b1461191c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610d65565b8251600090879060ff16601f8110611936576119366149c8565b602002015173ffffffffffffffffffffffffffffffffffffffff16146119b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610d65565b8086846000015160ff16601f81106119d2576119d26149c8565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526119fd600186614b07565b94505080611a0a90614a26565b9050611751565b505050611a22833383858e8e613373565b5050505050505050505050565b60006301c9c3808363ffffffff161115611a8957600c546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff80861660048301529091166024820152604401610d65565b620f4240821115611ac6576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808867ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018563ffffffff1681526020018481525090506000611b5487878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061088b915050565b90506000611b9988888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611c0b915050565b9050611ba786868484613618565b9998505050505050505050565b606060128054611bc390614613565b9050600003611bfe576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60128054610fb790614613565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611c7b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c9f9190614bc4565b9392505050565b855185518560ff16601f831115611d19576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610d65565b60008111611d83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610d65565b818314611e11576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610d65565b611e1c816003614be1565b8311611e84576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610d65565b611e8c61269b565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611ed39088613788565b6006541561208857600654600090611eed90600190614af4565b9050600060068281548110611f0457611f046149c8565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f3e57611f3e6149c8565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090811690915592909116808452922080549091169055600680549192509080611fbe57611fbe614bf8565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061202757612027614bf8565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611ed3915050565b60005b8151518110156124ed57600060056000846000015184815181106120b1576120b16149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156120fb576120fb614b71565b14612162576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610d65565b6040805180820190915260ff82168152600160208201528251805160059160009185908110612193576121936149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561223457612234614b71565b0217905550600091506122449050565b600560008460200151848151811061225e5761225e6149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122a8576122a8614b71565b1461230f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610d65565b6040805180820190915260ff821681526020810160028152506005600084602001518481518110612342576123426149c8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156123e3576123e3614b71565b021790555050825180516006925083908110612401576124016149c8565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600791908390811061247d5761247d6149c8565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556124e681614a26565b905061208b565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff43811682029283178555908304811693600193909260009261257f928692908216911617614c27565b92506101000a81548163ffffffff021916908363ffffffff1602179055506125de4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516137a5565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a099861267d988b98919763ffffffff909216969095919491939192614c44565b60405180910390a1611a22565b61269261269b565b61082181613850565b60005473ffffffffffffffffffffffffffffffffffffffff16331461271c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d65565b565b600e5460009081908190819061ffff908116908716111561276b576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c54604086015163ffffffff918216911611156127cd57604085810151600c5491517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff918216600482015291166024820152604401610d65565b60006127d9888761088b565b905060006127e78988611c0b565b905060006127ff886040015189606001518585613618565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa158015612882573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526128c89190810190614cca565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015612959573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061297d9190614d56565b509150506bffffffffffffffffffffffff851661299a8385614a5e565b6bffffffffffffffffffffffff1610156129e0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612a5f308e602001518f600001518560016129fd9190614da8565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff16612b4b9190614c27565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee542290612cf8908490614dc9565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b600080600080600080600080600089806020019051810190612d6a9190614ecb565b98509850985098509850985098509850985060008513612db9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610d65565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526bffffffffffffffffffffffff8a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590612ffb908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526bffffffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b6000613019610ef1565b90508051600003613056576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051601154600091613075916bffffffffffffffffffffffff16614f7b565b905060005b82518160ff161015613149578160106000858460ff16815181106130a0576130a06149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166131089190614fa6565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550808061314190614fcb565b91505061307a565b5081516131569082614fea565b601180546000906131769084906bffffffffffffffffffffffff16614a5e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa1580156131f6573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261323c9190810190614993565b905060005b81518110156132b2578373ffffffffffffffffffffffffffffffffffffffff16828281518110613273576132736149c8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036132a0575060019392505050565b806132aa81614a26565b915050613241565b5060009392505050565b60019392505050565b60006132d2826020614be1565b6132dd856020614be1565b6132e98861014461501a565b6132f3919061501a565b6132fd919061501a565b61330890600061501a565b9050368114610cdf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610d65565b60608080613383848601866150ad565b82519295509093509150158061339b57508151835114155b806133a857508051835114155b156133df576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b835181101561360c576000613443858381518110613402576134026149c8565b602002602001015185848151811061341c5761341c6149c8565b6020026020010151858581518110613436576134366149c8565b6020026020010151613945565b9050600081600681111561345957613459614b71565b14806134765750600181600681111561347457613474614b71565b145b156134d15784828151811061348d5761348d6149c8565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a26135f9565b60028160068111156134e5576134e5614b71565b03613535578482815181106134fc576134fc6149c8565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a26135f9565b600381600681111561354957613549614b71565b0361359957848281518110613560576135606149c8565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a26135f9565b60058160068111156135ad576135ad614b71565b036135f9578482815181106135c4576135c46149c8565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a25b508061360481614a26565b9150506133e2565b50505050505050505050565b60008061362361121b565b905060008113613662576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d65565b600c5460009087906136989063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c27565b6136a29190614c27565b63ffffffff1690506000612710600c60030154886136c09190614be1565b6136ca919061518a565b6136d4908861501a565b9050600083836136ec84670de0b6b3a7640000614be1565b6136f69190614be1565b613700919061518a565b9050600061371f6bffffffffffffffffffffffff808916908a1661501a565b9050613737816b033b2e3c9fd0803ce8000000614af4565b821115613770576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61377a818361501a565b9a9950505050505050505050565b6000613792610ef1565b5111156137a1576137a161300f565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016137c99998979695949392919061519e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036138cf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d65565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613a54576002915050611c9f565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613ab261121b565b905060008113613af1576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d65565b600081613b063a670de0b6b3a7640000614be1565b613b10919061518a565b9050600083610100015182613b259190614be1565b905060008460a0015182613b399190614fa6565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613ba1908f908f908f908c908b903390600401615233565b60408051808303816000875af1158015613bbf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613be391906152a4565b9092509050613bf28186614fa6565b33600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601180549193909291613c5291859116614fa6565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613cb89190614fa6565b60c08d015160a08e0151613ccc888d614fa6565b613cd69190614fa6565b613ce09190614fa6565b8760ff166006811115613cf557613cf5614b71565b604051613d069594939291906152d3565b60405180910390a28160ff166006811115613d2357613d23614b71565b9c9b505050505050505050505050565b508054613d3f90614613565b6000825580601f10613d4f575050565b601f0160209004906000526020600020908101906108219190613d8c565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613da15760008155600101613d8d565b5090565b60008083601f840112613db757600080fd5b50813567ffffffffffffffff811115613dcf57600080fd5b602083019150836020828501011115613de757600080fd5b9250929050565b60008060208385031215613e0157600080fd5b823567ffffffffffffffff811115613e1857600080fd5b613e2485828601613da5565b90969095509350505050565b600060208284031215613e4257600080fd5b813567ffffffffffffffff811115613e5957600080fd5b820160c08185031215611c9f57600080fd5b6000815180845260005b81811015613e9157602081850181015186830182015201613e75565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611c9f6020830184613e6b565b73ffffffffffffffffffffffffffffffffffffffff8116811461082157600080fd5b600060208284031215613f1657600080fd5b8135611c9f81613ee2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613f9757613f97613f21565b604052919050565b600082601f830112613fb057600080fd5b813567ffffffffffffffff811115613fca57613fca613f21565b613ffb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f50565b81815284602083860101111561401057600080fd5b816020850160208301376000918101602001919091529392505050565b60006020828403121561403f57600080fd5b813567ffffffffffffffff81111561405657600080fd5b61406284828501613f9f565b949350505050565b67ffffffffffffffff8116811461082157600080fd5b80356112168161406a565b63ffffffff8116811461082157600080fd5b60008082840360a08112156140b157600080fd5b833567ffffffffffffffff808211156140c957600080fd5b6140d587838801613f9f565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561410757600080fd5b6040519250608083019150828210818311171561412657614126613f21565b5060405260208401356141388161406a565b8152604084013561414881613ee2565b6020820152606084013561415b8161408b565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156141b957815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614187565b509495945050505050565b6040815260006141d76040830185614173565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614245577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614233838351613e6b565b948601949250908501906001016141f9565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461082157600080fd5b6000806040838503121561428157600080fd5b823561428c81613ee2565b9150602083013561429c81614254565b809150509250929050565b6000806000604084860312156142bc57600080fd5b83356142c781613ee2565b9250602084013567ffffffffffffffff8111156142e357600080fd5b6142ef86828701613da5565b9497909650939450505050565b602081526000611c9f6020830184614173565b60006020828403121561432157600080fd5b5035919050565b60008083601f84011261433a57600080fd5b50813567ffffffffffffffff81111561435257600080fd5b6020830191508360208260051b8501011115613de757600080fd5b60008060008060008060008060e0898b03121561438957600080fd5b606089018a81111561439a57600080fd5b8998503567ffffffffffffffff808211156143b457600080fd5b6143c08c838d01613da5565b909950975060808b01359150808211156143d957600080fd5b6143e58c838d01614328565b909750955060a08b01359150808211156143fe57600080fd5b5061440b8b828c01614328565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561443c57600080fd5b85356144478161406a565b9450602086013567ffffffffffffffff81111561446357600080fd5b61446f88828901613da5565b90955093505060408601356144838161408b565b949793965091946060013592915050565b600067ffffffffffffffff8211156144ae576144ae613f21565b5060051b60200190565b600082601f8301126144c957600080fd5b813560206144de6144d983614494565b613f50565b82815260059290921b840181019181810190868411156144fd57600080fd5b8286015b8481101561452157803561451481613ee2565b8352918301918301614501565b509695505050505050565b60ff8116811461082157600080fd5b80356112168161452c565b60008060008060008060c0878903121561455f57600080fd5b863567ffffffffffffffff8082111561457757600080fd5b6145838a838b016144b8565b9750602089013591508082111561459957600080fd5b6145a58a838b016144b8565b96506145b360408a0161453b565b955060608901359150808211156145c957600080fd5b6145d58a838b01613f9f565b94506145e360808a01614080565b935060a08901359150808211156145f957600080fd5b5061460689828a01613f9f565b9150509295509295509295565b600181811c9082168061462757607f821691505b602082108103614660577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561055757600081815260208120601f850160051c8101602086101561468d5750805b601f850160051c820191505b818110156146ac57828155600101614699565b505050505050565b67ffffffffffffffff8311156146cc576146cc613f21565b6146e0836146da8354614613565b83614666565b6000601f84116001811461473257600085156146fc5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147c8565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147815786850135825560209485019460019092019101614761565b50868210156147bc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261480457600080fd5b83018035915067ffffffffffffffff82111561481f57600080fd5b602001915036819003821315613de757600080fd5b60006020828403121561484657600080fd5b8135611c9f8161406a565b60006020828403121561486357600080fd5b8135611c9f8161408b565b61ffff8116811461082157600080fd5b60006020828403121561489057600080fd5b8135611c9f8161486e565b600073ffffffffffffffffffffffffffffffffffffffff808916835267ffffffffffffffff8816602084015280871660408401525060a060608301528360a0830152838560c0840137600060c0858401015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116830101905061ffff83166080830152979650505050505050565b600082601f83011261494057600080fd5b815160206149506144d983614494565b82815260059290921b8401810191818101908684111561496f57600080fd5b8286015b8481101561452157805161498681613ee2565b8352918301918301614973565b6000602082840312156149a557600080fd5b815167ffffffffffffffff8111156149bc57600080fd5b6140628482850161492f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614a5757614a576149f7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614a8357614a836149f7565b5092915050565b805169ffffffffffffffffffff8116811461121657600080fd5b600080600080600060a08688031215614abc57600080fd5b614ac586614a8a565b9450602086015193506040860151925060608601519150614ae860808701614a8a565b90509295509295909350565b818103818111156108b5576108b56149f7565b60ff81811683821601908111156108b5576108b56149f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614b6257614b62614b20565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614bd657600080fd5b8151611c9f81614254565b80820281158282048414176108b5576108b56149f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614a8357614a836149f7565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614c748184018a614173565b90508281036080840152614c888189614173565b905060ff871660a084015282810360c0840152614ca58187613e6b565b905067ffffffffffffffff851660e0840152828103610100840152613d238185613e6b565b600080600080600060a08688031215614ce257600080fd5b8551614ced81614254565b6020870151909550614cfe81614254565b6040870151909450614d0f81613ee2565b6060870151909350614d2081613ee2565b608087015190925067ffffffffffffffff811115614d3d57600080fd5b614d498882890161492f565b9150509295509295909350565b600080600060608486031215614d6b57600080fd5b83518015158114614d7b57600080fd5b6020850151909350614d8c8161406a565b6040850151909250614d9d8161406a565b809150509250925092565b67ffffffffffffffff818116838216019080821115614a8357614a836149f7565b815167ffffffffffffffff16815261014081016020830151614e03602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151614e1b604084018263ffffffff169052565b50606083015160608301526080830151614e4d608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a0830151614e6d60a08401826bffffffffffffffffffffffff169052565b5060c0830151614e8d60c08401826bffffffffffffffffffffffff169052565b5060e0830151614ead60e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60008060008060008060008060006101208a8c031215614eea57600080fd5b8951614ef58161408b565b60208b0151909950614f068161408b565b60408b0151909850614f178161408b565b60608b0151909750614f288161408b565b60808b015160a08c01519197509550614f408161408b565b60c08b0151909450614f5181614254565b60e08b0151909350614f628161486e565b809250506101008a015190509295985092959850929598565b60006bffffffffffffffffffffffff80841680614f9a57614f9a614b20565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614a8357614a836149f7565b600060ff821660ff8103614fe157614fe16149f7565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114615012576150126149f7565b505092915050565b808201808211156108b5576108b56149f7565b600082601f83011261503e57600080fd5b8135602061504e6144d983614494565b82815260059290921b8401810191818101908684111561506d57600080fd5b8286015b8481101561452157803567ffffffffffffffff8111156150915760008081fd5b61509f8986838b0101613f9f565b845250918301918301615071565b6000806000606084860312156150c257600080fd5b833567ffffffffffffffff808211156150da57600080fd5b818601915086601f8301126150ee57600080fd5b813560206150fe6144d983614494565b82815260059290921b8401810191818101908a84111561511d57600080fd5b948201945b8386101561513b57853582529482019490820190615122565b9750508701359250508082111561515157600080fd5b61515d8783880161502d565b9350604086013591508082111561517357600080fd5b506151808682870161502d565b9150509250925092565b60008261519957615199614b20565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151e58285018b614173565b915083820360808501526151f9828a614173565b915060ff881660a085015283820360c08501526152168288613e6b565b90861660e08501528381036101008501529050613d238185613e6b565b86815260c06020820152600061524c60c0830188613e6b565b828103604084015261525e8188613e6b565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156152b757600080fd5b82516152c28161452c565b602084015190925061429c81614254565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a081016007831061533f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"OCRConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200599138038062005991833981016040819052620000349162000444565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006169350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000222919062000554565b985098509850985098509850985098509850600085136200025a576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160601b038a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e805461ffff19169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590620003fd908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160601b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200042957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200045a57600080fd5b620004658462000411565b602085810151919450906001600160401b03808211156200048557600080fd5b818701915087601f8301126200049a57600080fd5b815181811115620004af57620004af6200042e565b604051601f8201601f19908116603f01168101908382118183101715620004da57620004da6200042e565b816040528281528a86848701011115620004f357600080fd5b600093505b82841015620005175784840186015181850187015292850192620004f8565b6000868483010152809750505050505050620005366040850162000411565b90509250925092565b805163ffffffff811681146200042957600080fd5b60008060008060008060008060006101208a8c0312156200057457600080fd5b6200057f8a6200053f565b98506200058f60208b016200053f565b97506200059f60408b016200053f565b9650620005af60608b016200053f565b955060808a01519450620005c660a08b016200053f565b60c08b01519094506001600160601b0381168114620005e457600080fd5b60e08b015190935061ffff81168114620005fd57600080fd5b809250506101008a015190509295985092959850929598565b60805161535f62000632600039600061124f015261535f6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806385b214cf116100ee578063c3f909d411610097578063de9dfa4611610071578063de9dfa4614610492578063e1a82d6f146104a5578063e3d0e712146104e5578063f2fde38b146104f857600080fd5b8063c3f909d4146103a5578063d227d24514610477578063d328a91e1461048a57600080fd5b8063af1296d3116100c8578063af1296d31461036a578063afcb95d714610372578063b1dc65a41461039257600080fd5b806385b214cf1461030d5780638da5cb5b146103305780639883c10d1461035857600080fd5b806366316d8d1161015b578063807560311161013557806380756031146102ad57806381411834146102c057806381f1b938146102d557806381ff7048146102dd57600080fd5b806366316d8d1461027f57806379ba5097146102925780637f15e1661461029a57600080fd5b8063354497aa1161018c578063354497aa146102265780634665571814610239578063533989871461026957600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004613ddf565b61050b565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a9190613e85565b60405180910390f35b6101c6610221366004613eba565b610560565b6101c6610234366004613fe3565b610602565b61024c610247366004614053565b610669565b6040516bffffffffffffffffffffffff909116815260200161020a565b610271610699565b60405161020a92919061417a565b6101c661028d366004614224565b610948565b6101c6610ac6565b6101c66102a8366004613ddf565b610bc8565b6101c66102bb36600461425d565b610c18565b6102c8610ccf565b60405161020a91906142b2565b6101fd610d3e565b6004546002546040805163ffffffff8085168252640100000000909404909316602084015282015260600161020a565b61032061031b3660046142c5565b610e0f565b604051901515815260200161020a565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6008545b60405190815260200161020a565b61035c610ff9565b60408051600181526000602082018190529181019190915260600161020a565b6101c66103a0366004614323565b6110dc565b610413600c54600d54600a54600e54600f5463ffffffff8086169664010000000087048216966c01000000000000000000000000810483169695680100000000000000009091049092169373ffffffffffffffffffffffffffffffffffffffff9092169261ffff9092169190565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61024c6104853660046143da565b61180d565b6101fd6119d3565b61024c6104a0366004614053565b611a2a565b6104b86104b336600461444a565b611ac5565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b6101c66104f3366004614537565b611d07565b6101c6610506366004613eba565b6126eb565b6105136126fc565b600081900361054e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601461055b8284836146a5565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061059b57503373ffffffffffffffffffffffffffffffffffffffff8216145b6105d1576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660009081526013602052604081206105ff91613d24565b50565b60095473ffffffffffffffffffffffffffffffffffffffff163314610653576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61065c8161277f565b8051602090910120600855565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106e9573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261072f9190810190614824565b90506000815167ffffffffffffffff81111561074d5761074d613ed7565b60405190808252806020026020018201604052801561078057816020015b606081526020019060019003908161076b5790505b50905060005b825181101561093e57601360008483815181106107a5576107a5614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107f290614604565b905060000361082d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013600084838151811061084357610843614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461089090614604565b80601f01602080910402602001604051908101604052809291908181526020018280546108bc90614604565b80156109095780601f106108de57610100808354040283529160200191610909565b820191906000526020600020905b8154815290600101906020018083116108ec57829003601f168201915b505050505082828151811061092057610920614859565b60200260200101819052508080610936906148b7565b915050610786565b5090939092509050565b610950612a46565b806bffffffffffffffffffffffff166000036109865750336000908152601060205260409020546bffffffffffffffffffffffff165b336000908152601060205260409020546bffffffffffffffffffffffff808316911610156109e0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526010602052604081208054839290610a0d9084906bffffffffffffffffffffffff166148ef565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610aa957600080fd5b505af1158015610abd573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b4c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bd06126fc565b6000819003610c0b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601261055b8284836146a5565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c635750610c4233612bdf565b8015610c6357503373ffffffffffffffffffffffffffffffffffffffff8416145b610c99576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601360205260409020610cc98284836146a5565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610d3457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d09575b5050505050905090565b606060148054610d4d90614604565b9050600003610d88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60148054610d9590614604565b80601f0160208091040260200160405190810160405280929190818152602001828054610dc190614604565b8015610d345780601f10610de357610100808354040283529160200191610d34565b820191906000526020600020905b815481529060010190602001808311610df157509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314610e63576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e0840152600481015461010084015260050154610120830152610f715750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611083573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110a79190614935565b509350509250508280156110c957506110c08142614985565b8463ffffffff16105b156110d457600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161113291849163ffffffff851691908e908e9081908401838280828437600092019190915250612cf392505050565b611168576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461123d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b43565b61124b8b8b8b8b8b8b612cfc565b60007f0000000000000000000000000000000000000000000000000000000000000000156112a8576002826020015183604001516112899190614998565b61129391906149e0565b61129e906001614998565b60ff1690506112be565b60208201516112b8906001614998565b60ff1690505b888114611327576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b43565b888714611390576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b43565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156113d3576113d3614a02565b60028111156113e4576113e4614a02565b905250905060028160200151600281111561140157611401614a02565b14801561144857506007816000015160ff168154811061142357611423614859565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b43565b50505050506114bb613d5e565b6000808a8a6040516114ce929190614a31565b6040519081900381206114e5918e90602001614a41565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117ef57600060018489846020811061154e5761154e614859565b61155b91901a601b614998565b8e8e8681811061156d5761156d614859565b905060200201358d8d8781811061158657611586614859565b90506020020135604051600081526020016040526040516115c3949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115e5573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561166557611665614a02565b600281111561167657611676614a02565b905250925060018360200151600281111561169357611693614a02565b146116fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b43565b8251600090879060ff16601f811061171457611714614859565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611796576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b43565b8086846000015160ff16601f81106117b0576117b0614859565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526117db600186614998565b945050806117e8906148b7565b905061152f565b505050611800833383858e8e612daa565b5050505050505050505050565b6009546040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8716600482015263ffffffff8416602482015260009173ffffffffffffffffffffffffffffffffffffffff169081906310fc49c19060440160006040518083038186803b15801561188f57600080fd5b505afa1580156118a3573d6000803e3d6000fd5b50505050620f42408311156118e4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152509050600061197288888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610669915050565b905060006119b789898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611a2a915050565b90506119c58787848461304f565b9a9950505050505050505050565b6060601280546119e290614604565b9050600003611a1d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60128054610d9590614604565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611a9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611abe9190614a55565b9392505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff163314611b1f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611b2c6060860186614a72565b9050600003611b66576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060800160405280876020016020810190611b869190614ad7565b67ffffffffffffffff168152602090810190611ba490890189613eba565b73ffffffffffffffffffffffffffffffffffffffff168152602001611bcf60e0890160c08a01614af4565b63ffffffff1681523a6020909101529050611c3b611bf06060880188614a72565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611c359250505060a0890160808a01614b21565b836131b1565b92975090955093509150611c526020870187613eba565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c32611c9b60408b0160208c01614ad7565b611cab60608c0160408d01613eba565b611cb860608d018d614a72565b8d6080016020810190611ccb9190614b21565b8e60a001358f60c0016020810190611ce39190614af4565b604051611cf7989796959493929190614b3e565b60405180910390a3509193509193565b855185518560ff16601f831115611d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b43565b60008111611de4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b43565b818314611e72576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b43565b611e7d816003614be4565b8311611ee5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b43565b611eed6126fc565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f349088613779565b600654156120e957600654600090611f4e90600190614985565b9050600060068281548110611f6557611f65614859565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f9f57611f9f614859565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560068054919250908061201f5761201f614bfb565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061208857612088614bfb565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f34915050565b60005b81515181101561254e576000600560008460000151848151811061211257612112614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215c5761215c614a02565b146121c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b43565b6040805180820190915260ff821681526001602082015282518051600591600091859081106121f4576121f4614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561229557612295614a02565b0217905550600091506122a59050565b60056000846020015184815181106122bf576122bf614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230957612309614a02565b14612370576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b43565b6040805180820190915260ff8216815260208101600281525060056000846020015184815181106123a3576123a3614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561244457612444614a02565b02179055505082518051600692508390811061246257612462614859565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160079190839081106124de576124de614859565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612547816148b7565b90506120ec565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff4381168202928317855590830481169360019390926000926125e0928692908216911617614c2a565b92506101000a81548163ffffffff021916908363ffffffff16021790555061263f4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613796565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a09986126de988b98919763ffffffff909216969095919491939192614c47565b60405180910390a1611800565b6126f36126fc565b6105ff81613841565b60005473ffffffffffffffffffffffffffffffffffffffff16331461277d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b43565b565b6000806000806000806000806000898060200190518101906127a19190614ccd565b985098509850985098509850985098509850600085136127f0576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610b43565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526bffffffffffffffffffffffff8a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590612a32908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526bffffffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b6000612a50610ccf565b90508051600003612a8d576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051601154600091612aac916bffffffffffffffffffffffff16614d7d565b905060005b82518160ff161015612b80578160106000858460ff1681518110612ad757612ad7614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612b3f9190614da8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508080612b7890614dcd565b915050612ab1565b508151612b8d9082614dec565b60118054600090612bad9084906bffffffffffffffffffffffff166148ef565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015612c2d573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612c739190810190614824565b905060005b8151811015612ce9578373ffffffffffffffffffffffffffffffffffffffff16828281518110612caa57612caa614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612cd7575060019392505050565b80612ce1816148b7565b915050612c78565b5060009392505050565b60019392505050565b6000612d09826020614be4565b612d14856020614be4565b612d2088610144614e1c565b612d2a9190614e1c565b612d349190614e1c565b612d3f906000614e1c565b9050368114610abd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b43565b60608080612dba84860186614eaf565b825192955090935091501580612dd257508151835114155b80612ddf57508051835114155b15612e16576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8351811015613043576000612e7a858381518110612e3957612e39614859565b6020026020010151858481518110612e5357612e53614859565b6020026020010151858581518110612e6d57612e6d614859565b6020026020010151613936565b90506000816006811115612e9057612e90614a02565b1480612ead57506001816006811115612eab57612eab614a02565b145b15612f0857848281518110612ec457612ec4614859565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613030565b6002816006811115612f1c57612f1c614a02565b03612f6c57848281518110612f3357612f33614859565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613030565b6003816006811115612f8057612f80614a02565b03612fd057848281518110612f9757612f97614859565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613030565b6005816006811115612fe457612fe4614a02565b0361303057848281518110612ffb57612ffb614859565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a25b508061303b816148b7565b915050612e19565b50505050505050505050565b60008061305a610ff9565b905060008113613099576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b43565b600c5460009087906130cf9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c2a565b6130d99190614c2a565b63ffffffff1690506000612710600c60030154886130f79190614be4565b6131019190614f8c565b61310b9088614e1c565b90506000838361312384670de0b6b3a7640000614be4565b61312d9190614be4565b6131379190614f8c565b905060006131566bffffffffffffffffffffffff808916908a16614e1c565b905061316e816b033b2e3c9fd0803ce8000000614985565b8211156131a7576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119c58183614e1c565b600e5460009081908190819061ffff90811690871611156131fe576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061320a8887610669565b905060006132188988611a2a565b9050600061323088604001518960600151858561304f565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa1580156132b3573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526132f99190810190614fa0565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa15801561338a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133ae919061502c565b509150506bffffffffffffffffffffffff85166133cb83856148ef565b6bffffffffffffffffffffffff161015613411576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613490308e602001518f6000015185600161342e919061507e565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff1661357c9190614c2a565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee54229061372990849061509f565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b6000613783610ccf565b51111561379257613792612a46565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016137ba999897969594939291906151a1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036138c0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b43565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613a45576002915050611abe565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613aa3610ff9565b905060008113613ae2576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b43565b600081613af73a670de0b6b3a7640000614be4565b613b019190614f8c565b9050600083610100015182613b169190614be4565b905060008460a0015182613b2a9190614da8565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613b92908f908f908f908c908b903390600401615236565b60408051808303816000875af1158015613bb0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bd491906152a7565b9092509050613be38186614da8565b33600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601180549193909291613c4391859116614da8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613ca99190614da8565b60c08d015160a08e0151613cbd888d614da8565b613cc79190614da8565b613cd19190614da8565b8760ff166006811115613ce657613ce6614a02565b604051613cf79594939291906152d6565b60405180910390a28160ff166006811115613d1457613d14614a02565b9c9b505050505050505050505050565b508054613d3090614604565b6000825580601f10613d40575050565b601f0160209004906000526020600020908101906105ff9190613d7d565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613d925760008155600101613d7e565b5090565b60008083601f840112613da857600080fd5b50813567ffffffffffffffff811115613dc057600080fd5b602083019150836020828501011115613dd857600080fd5b9250929050565b60008060208385031215613df257600080fd5b823567ffffffffffffffff811115613e0957600080fd5b613e1585828601613d96565b90969095509350505050565b6000815180845260005b81811015613e4757602081850181015186830182015201613e2b565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611abe6020830184613e21565b73ffffffffffffffffffffffffffffffffffffffff811681146105ff57600080fd5b600060208284031215613ecc57600080fd5b8135611abe81613e98565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613f4d57613f4d613ed7565b604052919050565b600082601f830112613f6657600080fd5b813567ffffffffffffffff811115613f8057613f80613ed7565b613fb160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f06565b818152846020838601011115613fc657600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613ff557600080fd5b813567ffffffffffffffff81111561400c57600080fd5b61401884828501613f55565b949350505050565b67ffffffffffffffff811681146105ff57600080fd5b8035610ff481614020565b63ffffffff811681146105ff57600080fd5b60008082840360a081121561406757600080fd5b833567ffffffffffffffff8082111561407f57600080fd5b61408b87838801613f55565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156140bd57600080fd5b604051925060808301915082821081831117156140dc576140dc613ed7565b5060405260208401356140ee81614020565b815260408401356140fe81613e98565b6020820152606084013561411181614041565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561416f57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161413d565b509495945050505050565b60408152600061418d6040830185614129565b6020838203818501528185518084528284019150828160051b85010183880160005b838110156141fb577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526141e9838351613e21565b948601949250908501906001016141af565b50909998505050505050505050565b6bffffffffffffffffffffffff811681146105ff57600080fd5b6000806040838503121561423757600080fd5b823561424281613e98565b915060208301356142528161420a565b809150509250929050565b60008060006040848603121561427257600080fd5b833561427d81613e98565b9250602084013567ffffffffffffffff81111561429957600080fd5b6142a586828701613d96565b9497909650939450505050565b602081526000611abe6020830184614129565b6000602082840312156142d757600080fd5b5035919050565b60008083601f8401126142f057600080fd5b50813567ffffffffffffffff81111561430857600080fd5b6020830191508360208260051b8501011115613dd857600080fd5b60008060008060008060008060e0898b03121561433f57600080fd5b606089018a81111561435057600080fd5b8998503567ffffffffffffffff8082111561436a57600080fd5b6143768c838d01613d96565b909950975060808b013591508082111561438f57600080fd5b61439b8c838d016142de565b909750955060a08b01359150808211156143b457600080fd5b506143c18b828c016142de565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156143f257600080fd5b85356143fd81614020565b9450602086013567ffffffffffffffff81111561441957600080fd5b61442588828901613d96565b909550935050604086013561443981614041565b949793965091946060013592915050565b60006020828403121561445c57600080fd5b813567ffffffffffffffff81111561447357600080fd5b820160e08185031215611abe57600080fd5b600067ffffffffffffffff82111561449f5761449f613ed7565b5060051b60200190565b600082601f8301126144ba57600080fd5b813560206144cf6144ca83614485565b613f06565b82815260059290921b840181019181810190868411156144ee57600080fd5b8286015b8481101561451257803561450581613e98565b83529183019183016144f2565b509695505050505050565b60ff811681146105ff57600080fd5b8035610ff48161451d565b60008060008060008060c0878903121561455057600080fd5b863567ffffffffffffffff8082111561456857600080fd5b6145748a838b016144a9565b9750602089013591508082111561458a57600080fd5b6145968a838b016144a9565b96506145a460408a0161452c565b955060608901359150808211156145ba57600080fd5b6145c68a838b01613f55565b94506145d460808a01614036565b935060a08901359150808211156145ea57600080fd5b506145f789828a01613f55565b9150509295509295509295565b600181811c9082168061461857607f821691505b602082108103614651577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561055b57600081815260208120601f850160051c8101602086101561467e5750805b601f850160051c820191505b8181101561469d5782815560010161468a565b505050505050565b67ffffffffffffffff8311156146bd576146bd613ed7565b6146d1836146cb8354614604565b83614657565b6000601f84116001811461472357600085156146ed5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147b9565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147725786850135825560209485019460019092019101614752565b50868210156147ad577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b600082601f8301126147d157600080fd5b815160206147e16144ca83614485565b82815260059290921b8401810191818101908684111561480057600080fd5b8286015b8481101561451257805161481781613e98565b8352918301918301614804565b60006020828403121561483657600080fd5b815167ffffffffffffffff81111561484d57600080fd5b614018848285016147c0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036148e8576148e8614888565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561491457614914614888565b5092915050565b805169ffffffffffffffffffff81168114610ff457600080fd5b600080600080600060a0868803121561494d57600080fd5b6149568661491b565b94506020860151935060408601519250606086015191506149796080870161491b565b90509295509295909350565b8181038181111561069357610693614888565b60ff818116838216019081111561069357610693614888565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff8316806149f3576149f36149b1565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614a6757600080fd5b8151611abe8161420a565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614aa757600080fd5b83018035915067ffffffffffffffff821115614ac257600080fd5b602001915036819003821315613dd857600080fd5b600060208284031215614ae957600080fd5b8135611abe81614020565b600060208284031215614b0657600080fd5b8135611abe81614041565b61ffff811681146105ff57600080fd5b600060208284031215614b3357600080fd5b8135611abe81614b11565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b808202811582820484141761069357610693614888565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561491457614914614888565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614c778184018a614129565b90508281036080840152614c8b8189614129565b905060ff871660a084015282810360c0840152614ca88187613e21565b905067ffffffffffffffff851660e0840152828103610100840152613d148185613e21565b60008060008060008060008060006101208a8c031215614cec57600080fd5b8951614cf781614041565b60208b0151909950614d0881614041565b60408b0151909850614d1981614041565b60608b0151909750614d2a81614041565b60808b015160a08c01519197509550614d4281614041565b60c08b0151909450614d538161420a565b60e08b0151909350614d6481614b11565b809250506101008a015190509295985092959850929598565b60006bffffffffffffffffffffffff80841680614d9c57614d9c6149b1565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561491457614914614888565b600060ff821660ff8103614de357614de3614888565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614e1457614e14614888565b505092915050565b8082018082111561069357610693614888565b600082601f830112614e4057600080fd5b81356020614e506144ca83614485565b82815260059290921b84018101918181019086841115614e6f57600080fd5b8286015b8481101561451257803567ffffffffffffffff811115614e935760008081fd5b614ea18986838b0101613f55565b845250918301918301614e73565b600080600060608486031215614ec457600080fd5b833567ffffffffffffffff80821115614edc57600080fd5b818601915086601f830112614ef057600080fd5b81356020614f006144ca83614485565b82815260059290921b8401810191818101908a841115614f1f57600080fd5b948201945b83861015614f3d57853582529482019490820190614f24565b97505087013592505080821115614f5357600080fd5b614f5f87838801614e2f565b93506040860135915080821115614f7557600080fd5b50614f8286828701614e2f565b9150509250925092565b600082614f9b57614f9b6149b1565b500490565b600080600080600060a08688031215614fb857600080fd5b8551614fc38161420a565b6020870151909550614fd48161420a565b6040870151909450614fe581613e98565b6060870151909350614ff681613e98565b608087015190925067ffffffffffffffff81111561501357600080fd5b61501f888289016147c0565b9150509295509295909350565b60008060006060848603121561504157600080fd5b8351801515811461505157600080fd5b602085015190935061506281614020565b604085015190925061507381614020565b809150509250925092565b67ffffffffffffffff81811683821601908082111561491457614914614888565b815167ffffffffffffffff168152610140810160208301516150d9602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516150f1604084018263ffffffff169052565b50606083015160608301526080830151615123608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a083015161514360a08401826bffffffffffffffffffffffff169052565b5060c083015161516360c08401826bffffffffffffffffffffffff169052565b5060e083015161518360e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151e88285018b614129565b915083820360808501526151fc828a614129565b915060ff881660a085015283820360c08501526152198288613e21565b90861660e08501528381036101008501529050613d148185613e21565b86815260c06020820152600061524f60c0830188613e21565b82810360408401526152618188613e21565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156152ba57600080fd5b82516152c58161451d565b60208401519092506142528161420a565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a0810160078310615342577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -1643,6 +1644,8 @@ type FunctionsCoordinatorOracleRequest struct { SubscriptionOwner common.Address Data []byte DataVersion uint16 + Flags [32]byte + CallbackGasLimit uint64 Raw types.Log } @@ -2445,7 +2448,7 @@ func (FunctionsCoordinatorOCRConfigSet) Topic() common.Hash { } func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { - return common.HexToHash("0xb108b073fa485003d66284614f1c3b4feb3f47ffc88f7873bf3b2ec4bb8939bc") + return common.HexToHash("0xd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c") } func (FunctionsCoordinatorOracleResponse) Topic() common.Hash { diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 27b57d922bc..d258c7b8eb7 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -31,8 +31,8 @@ var ( ) var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b506040516200640a3803806200640a833981016040819052620000449162000322565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620004939350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080828060200190518101906200026291906200043d565b6040805180820182526001600160601b0384168082526001600160e01b031984166020928301819052601180546001600160801b03191683176c0100000000000000000000000060e088901c021790558351918252918101919091529294509092507fb2b9bfb736b0bfef266985352cfca2a114226362209f5a6e5a2a2ed14383ba57910160405180910390a1505050565b805161ffff811681146200030757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b600080600080608085870312156200033957600080fd5b6200034485620002f4565b9350602062000355818701620002f4565b60408701519094506001600160a01b03811681146200037357600080fd5b60608701519093506001600160401b03808211156200039157600080fd5b818801915088601f830112620003a657600080fd5b815181811115620003bb57620003bb6200030c565b604051601f8201601f19908116603f01168101908382118183101715620003e657620003e66200030c565b816040528281528b86848701011115620003ff57600080fd5b600093505b8284101562000423578484018601518185018701529285019262000404565b600086848301015280965050505050505092959194509250565b600080604083850312156200045157600080fd5b82516001600160601b03811681146200046957600080fd5b60208401519092506001600160e01b0319811681146200048857600080fd5b809150509250929050565b615f6780620004a36000396000f3fe608060405234801561001057600080fd5b50600436106102c85760003560e01c8063823597401161017b578063b187bd26116100d8578063d7ae1d301161008c578063e82ad7d411610071578063e82ad7d41461070e578063eb523d6c14610721578063f2fde38b1461073457600080fd5b8063d7ae1d30146106e8578063e72f6e30146106fb57600080fd5b8063b734c0f4116100bd578063b734c0f4146106b6578063badc3eb6146106be578063c4614d61146106d557600080fd5b8063b187bd2614610698578063b5643858146106a357600080fd5b8063a21a23e41161012f578063a4c0ed3611610114578063a4c0ed361461064c578063a9c9a9181461065f578063aab396bd1461067257600080fd5b8063a21a23e414610620578063a47c76961461062857600080fd5b80638fde5317116101605780638fde5317146105fd5780639883c10d146106055780639f87fad71461060d57600080fd5b806382359740146105c75780638da5cb5b146105da57600080fd5b806354fd4d5011610229578063674603d0116101dd57806371ec28ac116101c257806371ec28ac1461059d5780637341c10c146105ac57806379ba5097146105bf57600080fd5b8063674603d0146104d05780636a6df79b1461056557600080fd5b806366316d8d1161020e57806366316d8d146104835780636641997014610496578063665871ec146104bd57600080fd5b806354fd4d50146104155780635c975abb1461046c57600080fd5b806336566f06116102805780633e871e4d116102655780633e871e4d146103a85780633fd67e05146103bb578063461d2762146103f457600080fd5b806336566f061461038d578063385de9ae1461039557600080fd5b806312b58349116102b157806312b58349146102f5578063181f5a77146103355780632a905ccc1461037757600080fd5b806302bcc5b6146102cd57806304c357cb146102e2575b600080fd5b6102e06102db366004615086565b610747565b005b6102e06102f03660046150c5565b6107c7565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b60405161032c919061515c565b6011546bffffffffffffffffffffffff16610313565b6102e0610aaf565b6102e06103a33660046151b8565b610ad4565b6102e06103b6366004615318565b610cb8565b6103ce6103c9366004615479565b610fcd565b6040805160ff90931683526bffffffffffffffffffffffff90911660208301520161032c565b610407610402366004615541565b611328565b60405190815260200161032c565b600180546040805192835261ffff740100000000000000000000000000000000000000008304811660208501527601000000000000000000000000000000000000000000009092049091169082015260600161032c565b60005460ff165b604051901515815260200161032c565b6102e06104913660046155bf565b6113c2565b600b5467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161032c565b6102e06104cb3660046155f6565b611623565b61053d6104de36600461566b565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff928316602085015291169082015260600161032c565b6105786105733660046156a3565b611a59565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161032c565b6040516064815260200161032c565b6102e06105ba3660046150c5565b611a6c565b6102e0611e05565b6102e06105d5366004615086565b611f27565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610578565b6102e0612196565b600a54610407565b6102e061061b3660046150c5565b61221a565b6104a4612817565b61063b610636366004615086565b612ae5565b60405161032c959493929190615719565b6102e061065a36600461576e565b612bd3565b61057861066d3660046157c8565b612e2f565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610407565b60005460ff16610473565b6102e06106b13660046157e1565b612e42565b6102e0612f5b565b6106c66131d1565b60405161032c939291906157fc565b61036a6106e33660046151b8565b6132ac565b6102e06106f63660046150c5565b6132c1565b6102e061070936600461585d565b613515565b61047361071c366004615086565b613729565b6102e061072f3660046157c8565b613734565b6102e061074236600461585d565b6139bd565b61074f6139ce565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16806107b9576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107c38282613a54565b5050565b67ffffffffffffffff82166000908152600c6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff1680610833576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461089f576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024015b60405180910390fd5b60105460ff16156108dc576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109077fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613e40565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af1158015610975573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906109999190615878565b15156000036109d6576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610896565b67ffffffffffffffff84166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff848116911614610aa95767ffffffffffffffff84166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff88169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b50505050565b610ab76139ce565b60005460ff1615610acc57610aca613f42565b565b610aca613fbf565b610adc6139ce565b6000610ae9846000613e40565b905060003073ffffffffffffffffffffffffffffffffffffffff831603610b135750600a54610b87565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610b60573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b849190615895565b90505b8383604051610b979291906158ae565b60405180910390208103610bd7576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610c3e9062010000900461ffff16436158ed565b9052600086815260066020908152604090912082518155908201516001820190610c6890826159a1565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610ca9908790849088908890615abb565b60405180910390a15050505050565b610cc06139ce565b8151815181141580610cd25750600881115b15610d09576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610e40576000848260ff1681518110610d2e57610d2e615b16565b602002602001015190506000848360ff1681518110610d4f57610d4f615b16565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610dba575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610df1576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610e2b576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610896565b50508080610e3890615b45565b915050610d0c565b50600754600090610e5b9062010000900461ffff16436158ed565b604080516060810182528681526020808201879052918101839052865192935091600391610e8d918391890190614f79565b506020828101518051610ea69260018501920190614fc0565b506040820151816002015590505060005b84518160ff161015610fc6577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610ef957610ef9615b16565b602002602001015160026000888560ff1681518110610f1a57610f1a615b16565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610f6657610f66615b16565b602002602001015185604051610fac949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610fbe81615b45565b915050610eb7565b5050505050565b601054600090819060ff161561100f576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e0830152331461111d576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff1661114657600292505061131d565b8060c00151816060015163ffffffff1661116091906158ed565b5a101561117157600392505061131d565b80608001516bffffffffffffffffffffffff16611197826060015163ffffffff1661401a565b6111a19088615b64565b868360e001516111b19190615b94565b6111bb9190615b94565b6bffffffffffffffffffffffff1611156111d957600492505061131d565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000009081169091556003820184905560048201849055600590910180549091169055606083015190830151919450849161127a918c918c918c916140bc565b805190915061128a57600161128d565b60005b935060006112b48360400151846080015185602001518660e001518c87602001518d61423a565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516112fd578e6112ff565b8f5b60405161130f9493929190615bc0565b60405180910390a351925050505b965096945050505050565b60105460009060ff1615611368576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6113706144b7565b6113b78260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a91506145249050565b979650505050505050565b60105460ff16156113ff576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806bffffffffffffffffffffffff16600003611447576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff808316911610156114a1576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906114ce9084906bffffffffffffffffffffffff16615c16565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff166115259190615c16565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af11580156115c9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115ed9190615878565b6107c3576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff1615611660576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015611a5457600083838381811061167f5761167f615b16565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e0850152909350905061176881614924565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff163381146117ec576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610896565b8260a0015142101561182a576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611899573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906118bd9190615878565b15611a3c57608084015167ffffffffffffffff84166000908152600c6020819052604090912080549091906119119084906c0100000000000000000000000090046bffffffffffffffffffffffff16615c16565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff80881684529352902080546001926009916119969185916901000000000000000000900416615c3b565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b50505050508080611a4c90615c5c565b915050611663565b505050565b6000611a658383613e40565b9392505050565b67ffffffffffffffff82166000908152600c6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff1680611ad8576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611b3f576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610896565b60105460ff1615611b7c576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611ba77fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613e40565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af1158015611c15573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c399190615878565b1515600003611c76576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610896565b67ffffffffffffffff84166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611ceb576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d6020908152604080832067ffffffffffffffff8816845290915290205460ff16610aa95773ffffffffffffffffffffffffffffffffffffffff83166000818152600d6020908152604080832067ffffffffffffffff891680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610aa0565b60015473ffffffffffffffffffffffffffffffffffffffff163314611e86576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610896565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60105460ff1615611f64576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611f8f7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613e40565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af1158015611ffd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906120219190615878565b151560000361205e576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610896565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff91821691163381146120ed576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610896565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b61219e6139ce565b6009544310156121da576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b67ffffffffffffffff82166000908152600c6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff1680612286576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff8216146122ed576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610896565b60105460ff161561232a576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6123557fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613e40565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af11580156123c3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123e79190615878565b1515600003612424576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610896565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d6020908152604080832067ffffffffffffffff8089168552908352928190208151606081018352905460ff81161515808352610100820486169483019490945269010000000000000000009004909316908301526124f4576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8616600482015273ffffffffffffffffffffffffffffffffffffffff85166024820152604401610896565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614612549576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff85166000908152600c60209081526040808320600301805482518185028101850190935280835291929091908301828280156125c457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612599575b505050505090506000600182516125db9190615c94565b905060005b8251811015612779578673ffffffffffffffffffffffffffffffffffffffff1683828151811061261257612612615b16565b602002602001015173ffffffffffffffffffffffffffffffffffffffff160361276757600083838151811061264957612649615b16565b6020026020010151905080600c60008b67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600301838154811061268f5761268f615b16565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff8b168152600c9091526040902060030180548061270957612709615ca7565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550612779565b8061277181615c5c565b9150506125e0565b5073ffffffffffffffffffffffffffffffffffffffff86166000818152600d6020908152604080832067ffffffffffffffff8c168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a250505050505050565b60105460009060ff1615612857576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6128827fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613e40565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af11580156128f0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129149190615878565b1515600003612951576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610896565b600b805467ffffffffffffffff1690600061296b83615cd6565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160a081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000091821617909155965160028401805491909216971696909617909555925180519296509094509192612aa0926003850192910190614fc0565b505060405133815267ffffffffffffffff831691507f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6000806000806060612af686614924565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff9182169850921695509091830182828015612bc357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612b98575b5050505050905091939590929450565b60105460ff1615612c10576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601054610100900473ffffffffffffffffffffffffffffffffffffffff163314612c66576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612ca0576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612cae82840184615086565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff16612d1a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff1691869190612d518385615b94565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff16612da89190615b94565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8828784612e0f91906158ed565b6040805192835260208301919091520160405180910390a2505050505050565b6000612e3c826000613e40565b92915050565b612e4a6139ce565b60075461ffff808316620100009092041603612e92576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff9081169082161115612ed6576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff62010000909104811680835290841660208301529091820190612f0990436158ed565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b612f636139ce565b600554431015612f9f576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff166001612fbc9190615cfd565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff9384160217908190557601000000000000000000000000000000000000000000009004161561304d57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff821610156131ce57600060036000018260ff168154811061307857613078615b16565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff86169081106130c7576130c7615b16565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a150505080806131c690615b45565b915050613050565b50565b6000606080600360020154600360000160036001018180548060200260200160405190810160405280929190818152602001828054801561323157602002820191906000526020600020905b81548152602001906001019080831161321d575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561329a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161326f575b50505050509050925092509250909192565b60606132b984848461498d565b949350505050565b67ffffffffffffffff82166000908152600c6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff168061332d576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614613394576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610896565b60105460ff16156133d1576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6133fc7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613e40565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561346a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061348e9190615878565b15156000036134cb576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610896565b6134d484614a5c565b1561350b576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610aa98484613a54565b61351d6139ce565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015613591573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135b59190615895565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115613619576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610896565b81811015611a5457600061362d8284615c94565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af11580156136af573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906136d39190615878565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6000612e3c82614a5c565b61373c6139ce565b6000600660008381526020019081526020016000206040518060600160405290816000820154815260200160018201805461377690615900565b80601f01602080910402602001604051908101604052809291908181526020018280546137a290615900565b80156137ef5780601f106137c4576101008083540402835291602001916137ef565b820191906000526020600020905b8154815290600101906020018083116137d257829003601f168201915b5050505050815260200160028201548152505090508060400151431015613842576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613867576138548160200151614bad565b6020808201518051910120600a5561390f565b613872826000613e40565b73ffffffffffffffffffffffffffffffffffffffff1663354497aa82602001516040518263ffffffff1660e01b81526004016138ae919061515c565b600060405180830381600087803b1580156138c857600080fd5b505af19250505080156138d9575060015b61390f576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff16600161392c9190615cfd565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926139b1928692615d18565b60405180910390a15050565b6139c56139ce565b6131ce81614c8b565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610aca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610896565b60105460ff1615613a91576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600c60209081526040808320815160a08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff908116828501526002830154166060820152600382018054845181870281018701909552808552919492936080860193909290830182828015613b7257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613b47575b5050509190925250508151919250600090505b826080015151811015613c2b57600d600084608001518381518110613bac57613bac615b16565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905580613c2381615c5c565b915050613b85565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000908116909155600282018054909116905590613cb1600383018261503a565b505080600b60088282829054906101000a90046bffffffffffffffffffffffff16613cdc9190615c16565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af1158015613d81573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613da59190615878565b613ddb576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101610aa0565b600081613e7f5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613e79579050612e3c565b50613f0d565b60005b60035460ff82161015613f0b576003805460ff8316908110613ea657613ea6615b16565b90600052602060002001548403613ef9576004805460ff8316908110613ece57613ece615b16565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150612e3c9050565b80613f0381615b45565b915050613e82565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610896565b613f4a614d86565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613fc76144b7565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613f953390565b60006bffffffffffffffffffffffff8211156140b8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610896565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b906140ff90899089908990602401615d40565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a6113888110156141bc57600080fd5b6113888103905086604082048203116141d457600080fd5b853b6141df57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b604080518082019091526000808252602082015260006142598461401a565b6142639086615b64565b90506000816142728886615b94565b61427c9190615b94565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c9091529283208054929750939450849392916142d391859116615c16565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550818461430d9190615b94565b336000908152600e60205260408120805490919061433a9084906bffffffffffffffffffffffff16615b94565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b9450909261438191859116615b94565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff166144009190615c16565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f168552925290912080546001926009916144849185916901000000000000000000900416615c3b565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60005460ff1615610aca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610896565b600061452f85614924565b6145393386614df2565b60006145458888613e40565b6040805160c08101825267ffffffffffffffff891680825260208083018a905261ffff89168385015263ffffffff881660608401523360808401526000918252600c90528281206001015473ffffffffffffffffffffffffffffffffffffffff90811660a084015292517f0a33e0a5000000000000000000000000000000000000000000000000000000008152939450928392839290861691630a33e0a5916145f091600401615d6b565b6080604051808303816000875af115801561460f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906146339190615df5565b92975090945092509050614648338a85614e8e565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff16815260200182426146c891906158ed565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161490e96959493929190615e33565b60405180910390a4505050509695505050505050565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff166131ce576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606060008080806149a086880188615e97565b935093509350935060006149b989600187878787614524565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614a4f578181602081106149f8576149f8615b16565b1a60f81b878281518110614a0e57614a0e615b16565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080614a4781615c5c565b9150506149dd565b5050505050509392505050565b67ffffffffffffffff81166000908152600c6020908152604080832060030180548251818502810185019093528083528493830182828015614ad457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614aa9575b5050505050905060005b8151811015614ba3576000600d6000848481518110614aff57614aff615b16565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014614b9057506001949350505050565b5080614b9b81615c5c565b915050614ade565b5060009392505050565b60008082806020019051810190614bc49190615f06565b6040805180820182526bffffffffffffffffffffffff84168082527fffffffff0000000000000000000000000000000000000000000000000000000084166020928301819052601180547fffffffffffffffffffffffffffffffff000000000000000000000000000000001683176c0100000000000000000000000060e088901c021790558351918252918101919091529294509092507fb2b9bfb736b0bfef266985352cfca2a114226362209f5a6e5a2a2ed14383ba57910160405180910390a1505050565b3373ffffffffffffffffffffffffffffffffffffffff821603614d0a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610896565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610aca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610896565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff166107c3576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610896565b67ffffffffffffffff82166000908152600c602081905260409091208054839290614ed89084906c0100000000000000000000000090046bffffffffffffffffffffffff16615b94565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614f4e928492900416615c3b565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614fb4579160200282015b82811115614fb4578251825591602001919060010190614f99565b506140b8929150615054565b828054828255906000526020600020908101928215614fb4579160200282015b82811115614fb457825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614fe0565b50805460008255906000526020600020908101906131ce91905b5b808211156140b85760008155600101615055565b803567ffffffffffffffff8116811461508157600080fd5b919050565b60006020828403121561509857600080fd5b611a6582615069565b803573ffffffffffffffffffffffffffffffffffffffff8116811461508157600080fd5b600080604083850312156150d857600080fd5b6150e183615069565b91506150ef602084016150a1565b90509250929050565b6000815180845260005b8181101561511e57602081850181015186830182015201615102565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611a6560208301846150f8565b60008083601f84011261518157600080fd5b50813567ffffffffffffffff81111561519957600080fd5b6020830191508360208285010111156151b157600080fd5b9250929050565b6000806000604084860312156151cd57600080fd5b83359250602084013567ffffffffffffffff8111156151eb57600080fd5b6151f78682870161516f565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561527a5761527a615204565b604052919050565b600067ffffffffffffffff82111561529c5761529c615204565b5060051b60200190565b600082601f8301126152b757600080fd5b813560206152cc6152c783615282565b615233565b82815260059290921b840181019181810190868411156152eb57600080fd5b8286015b8481101561530d57615300816150a1565b83529183019183016152ef565b509695505050505050565b6000806040838503121561532b57600080fd5b823567ffffffffffffffff8082111561534357600080fd5b818501915085601f83011261535757600080fd5b813560206153676152c783615282565b82815260059290921b8401810191818101908984111561538657600080fd5b948201945b838610156153a45785358252948201949082019061538b565b965050860135925050808211156153ba57600080fd5b506153c7858286016152a6565b9150509250929050565b600082601f8301126153e257600080fd5b813567ffffffffffffffff8111156153fc576153fc615204565b61542d60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601615233565b81815284602083860101111561544257600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146131ce57600080fd5b60008060008060008060c0878903121561549257600080fd5b86359550602087013567ffffffffffffffff808211156154b157600080fd5b6154bd8a838b016153d1565b965060408901359150808211156154d357600080fd5b506154e089828a016153d1565b94505060608701356154f18161545f565b925060808701356155018161545f565b915061550f60a088016150a1565b90509295509295509295565b803561ffff8116811461508157600080fd5b803563ffffffff8116811461508157600080fd5b60008060008060008060a0878903121561555a57600080fd5b61556387615069565b9550602087013567ffffffffffffffff81111561557f57600080fd5b61558b89828a0161516f565b909650945061559e90506040880161551b565b92506155ac6060880161552d565b9150608087013590509295509295509295565b600080604083850312156155d257600080fd5b6155db836150a1565b915060208301356155eb8161545f565b809150509250929050565b6000806020838503121561560957600080fd5b823567ffffffffffffffff8082111561562157600080fd5b818501915085601f83011261563557600080fd5b81358181111561564457600080fd5b8660208260051b850101111561565957600080fd5b60209290920196919550909350505050565b6000806040838503121561567e57600080fd5b615687836150a1565b91506150ef60208401615069565b80151581146131ce57600080fd5b600080604083850312156156b657600080fd5b8235915060208301356155eb81615695565b600081518084526020808501945080840160005b8381101561570e57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016156dc565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a0608082018190526000906113b7908301846156c8565b6000806000806060858703121561578457600080fd5b61578d856150a1565b935060208501359250604085013567ffffffffffffffff8111156157b057600080fd5b6157bc8782880161516f565b95989497509550505050565b6000602082840312156157da57600080fd5b5035919050565b6000602082840312156157f357600080fd5b611a658261551b565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561583d57845183529383019391830191600101615821565b5050848103604086015261585181876156c8565b98975050505050505050565b60006020828403121561586f57600080fd5b611a65826150a1565b60006020828403121561588a57600080fd5b8151611a6581615695565b6000602082840312156158a757600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115612e3c57612e3c6158be565b600181811c9082168061591457607f821691505b60208210810361594d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611a5457600081815260208120601f850160051c8101602086101561597a5750805b601f850160051c820191505b8181101561599957828155600101615986565b505050505050565b815167ffffffffffffffff8111156159bb576159bb615204565b6159cf816159c98454615900565b84615953565b602080601f831160018114615a2257600084156159ec5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615999565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015615a6f57888601518255948401946001909101908401615a50565b5085821015615aab57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103615b5b57615b5b6158be565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114615b8c57615b8c6158be565b505092915050565b6bffffffffffffffffffffffff818116838216019080821115615bb957615bb96158be565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff83166040820152608060608201526000615c0c60808301846150f8565b9695505050505050565b6bffffffffffffffffffffffff828116828216039080821115615bb957615bb96158be565b67ffffffffffffffff818116838216019080821115615bb957615bb96158be565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203615c8d57615c8d6158be565b5060010190565b81810381811115612e3c57612e3c6158be565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff808316818103615cf357615cf36158be565b6001019392505050565b61ffff818116838216019080821115615bb957615bb96158be565b838152826020820152606060408201526000615d3760608301846150f8565b95945050505050565b838152606060208201526000615d5960608301856150f8565b8281036040840152615c0c81856150f8565b6020815267ffffffffffffffff82511660208201526000602083015160c06040840152615d9b60e08401826150f8565b905061ffff604085015116606084015263ffffffff6060850151166080840152608084015173ffffffffffffffffffffffffffffffffffffffff80821660a08601528060a08701511660c086015250508091505092915050565b60008060008060808587031215615e0b57600080fd5b845193506020850151615e1d8161545f565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615e7460c08301866150f8565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b60008060008060808587031215615ead57600080fd5b615eb685615069565b9350602085013567ffffffffffffffff811115615ed257600080fd5b615ede878288016153d1565b935050615eed6040860161551b565b9150615efb6060860161552d565b905092959194509250565b60008060408385031215615f1957600080fd5b8251615f248161545f565b60208401519092507fffffffff00000000000000000000000000000000000000000000000000000000811681146155eb57600080fdfea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b506040516200612b3803806200612b833981016040819052620000449162000451565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620006cb9350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026491906200054e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052601180546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002dc916012919086019062000323565b509050507f02c673f957dfd44004b8ef12f6c1858031d7bd50b3918b09fb6f39bffede86a483838360405162000315939291906200065a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003c75791602002820160005b838211156200039357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200034d565b8015620003c55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000393565b505b50620003d5929150620003d9565b5090565b5b80821115620003d55760008155600101620003da565b805161ffff811681146200040357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000449576200044962000408565b604052919050565b600080600080608085870312156200046857600080fd5b6200047385620003f0565b9350602062000484818701620003f0565b60408701519094506001600160a01b0381168114620004a257600080fd5b60608701519093506001600160401b0380821115620004c057600080fd5b818801915088601f830112620004d557600080fd5b815181811115620004ea57620004ea62000408565b620004fe601f8201601f191685016200041e565b915080825289848285010111156200051557600080fd5b60005b818110156200053557838101850151838201860152840162000518565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056457600080fd5b83516001600160601b03811681146200057c57600080fd5b602085810151919450906001600160e01b0319811681146200059d57600080fd5b60408601519093506001600160401b0380821115620005bb57600080fd5b818701915087601f830112620005d057600080fd5b815181811115620005e557620005e562000408565b8060051b9150620005f88483016200041e565b818152918301840191848101908a8411156200061357600080fd5b938501935b838510156200064a578451925063ffffffff83168314620006395760008081fd5b828252938501939085019062000618565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bd57845163ffffffff168352938301939183019160010162000699565b509098975050505050505050565b615a5080620006db6000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610768578063eb523d6c1461077b578063f2fde38b1461078e57600080fd5b8063c4614d611461072f578063d7ae1d3014610742578063e72f6e301461075557600080fd5b8063b5643858116100c8578063b5643858146106fd578063b734c0f414610710578063badc3eb61461071857600080fd5b8063aab396bd146106cc578063b187bd26146106f257600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c769614610682578063a4c0ed36146106a6578063a9c9a918146106b957600080fd5b80639883c10d1461065f5780639f87fad714610667578063a21a23e41461067a57600080fd5b8063823597401161017657806382359740146106215780638da5cb5b146106345780638fde53171461065757600080fd5b80637341c10c1461060657806379ba50971461061957600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461052a5780636a6df79b146105bf57806371ec28ac146105f757600080fd5b806366316d8d146104dd57806366419970146104f0578063665871ec1461051757600080fd5b806354fd4d501161022f57806354fd4d501461045c57806355fedefa146104b35780635c975abb146104c657600080fd5b80633fd67e0514610402578063461d27621461043b57600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103d4578063385de9ae146103dc5780633e871e4d146103ef57600080fd5b80631ded3b36146103ab5780632a905ccc146103be57600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461036957600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc3660046149ec565b6107a1565b005b610301610311366004614a2b565b610821565b610301610324366004614a70565b610910565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103609190614b0b565b6103016103b9366004614b1e565b61091a565b6011546bffffffffffffffffffffffff16610347565b61030161094b565b6103016103ea366004614b91565b610970565b6103016103fd366004614cf1565b610b54565b610415610410366004614e52565b610e6e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610360565b61044e610449366004614f06565b611192565b604051908152602001610360565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610360565b61044e6104c13660046149ec565b6111f6565b60005460ff165b6040519015158152602001610360565b6103016104eb366004614f88565b61121a565b600b5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610360565b610301610525366004614fb4565b611446565b610597610538366004615029565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610360565b6105d26105cd366004615061565b61182f565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610360565b60405160648152602001610360565b610301610614366004614a2b565b611842565b6103016119ef565b61030161062f3660046149ec565b611b11565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d2565b610301611c59565b600a5461044e565b610301610675366004614a2b565b611cdd565b6104fe6120e7565b6106956106903660046149ec565b61229f565b6040516103609594939291906150d7565b6103016106b436600461512c565b61238d565b6105d26106c7366004615186565b6125b4565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761044e565b60005460ff166104cd565b61030161070b36600461519f565b6125c1565b6103016126da565b610720612950565b604051610360939291906151ba565b61039e61073d366004614b91565b612a2b565b610301610750366004614a2b565b612a40565b61030161076336600461521b565b612a99565b6104cd6107763660046149ec565b612cae565b610301610789366004615186565b612cb9565b61030161079c36600461521b565b612f42565b6107a9612f53565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610813576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61081d8282612f5b565b5050565b61082a8261332d565b6108326133e6565b61083a613423565b67ffffffffffffffff82166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff82811691161461081d5767ffffffffffffffff82166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61081d828261351d565b610922612f53565b61092b8261363d565b67ffffffffffffffff9091166000908152600c6020526040902060040155565b6109536136a6565b60005460ff16156109685761096661372c565b565b6109666137a9565b6109786136a6565b6000610985846000613804565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109af5750600a54610a23565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156109fc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a209190615236565b90505b8383604051610a3392919061524f565b60405180910390208103610a73576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610ada9062010000900461ffff164361528e565b9052600086815260066020908152604090912082518155908201516001820190610b049082615342565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b4590879084908890889061545c565b60405180910390a15050505050565b610b5c6136a6565b8151815181141580610b6e5750600881115b15610ba5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610ce1576000848260ff1681518110610bca57610bca6154b7565b602002602001015190506000848360ff1681518110610beb57610beb6154b7565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c56575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c8d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccc576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b50508080610cd9906154e6565b915050610ba8565b50600754600090610cfc9062010000900461ffff164361528e565b604080516060810182528681526020808201879052918101839052865192935091600391610d2e918391890190614835565b506020828101518051610d47926001850192019061487c565b506040820151816002015590505060005b84518160ff161015610e67577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610d9a57610d9a6154b7565b602002602001015160026000888560ff1681518110610dbb57610dbb6154b7565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e0757610e076154b7565b602002602001015185604051610e4d949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610e5f816154e6565b915050610d58565b5050505050565b600080610e796133e6565b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e08301523314610f87576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff16610fb0576002925050611187565b8060c00151816060015163ffffffff16610fca919061528e565b5a1015610fdb576003925050611187565b80608001516bffffffffffffffffffffffff16611001826060015163ffffffff16613906565b61100b9088615505565b868360e0015161101b9190615535565b6110259190615535565b6bffffffffffffffffffffffff161115611043576004925050611187565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018490556004820184905560059091018054909116905560608301519083015191945084916110e4918c918c918c916139a8565b80519091506110f45760016110f7565b60005b9350600061111e8360400151846080015185602001518660e001518c87602001518d613b26565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b0520836020015189898760000151611167578e611169565b8f5b6040516111799493929190615561565b60405180910390a351925050505b965096945050505050565b600061119c613da3565b6111a46133e6565b6111eb8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e109050565b979650505050505050565b67ffffffffffffffff81166000908152600c60205260408120600401545b92915050565b6112226133e6565b806bffffffffffffffffffffffff1660000361126a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff808316911610156112c4576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906112f19084906bffffffffffffffffffffffff166155b7565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff1661134891906155b7565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af11580156113ec573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061141091906155dc565b61081d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61144e6133e6565b60005b8181101561182a57600083838381811061146d5761146d6154b7565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e085015290935090506115568161363d565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff163381146115c2576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260a00151421015611600576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561166f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061169391906155dc565b1561181257608084015167ffffffffffffffff84166000908152600c6020819052604090912080549091906116e79084906c0100000000000000000000000090046bffffffffffffffffffffffff166155b7565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff808816845293529020805460019260099161176c91859169010000000000000000009004166155f9565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b505050505080806118229061561a565b915050611451565b505050565b600061183b8383613804565b9392505050565b61184b8261332d565b6118536133e6565b61185b613423565b67ffffffffffffffff82166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c016118d0576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611917575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600d6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610904565b60015473ffffffffffffffffffffffffffffffffffffffff163314611a70576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cc3565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b196133e6565b611b21613423565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff9182169116338114611bb0576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cc3565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611c616136a6565b600954431015611c9d576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b611ce68261332d565b611cee6133e6565b611cf6613423565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611dc6576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e1b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600c6020908152604080832060030180548251818502810185019093528083529192909190830182828015611e9657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e6b575b50505050509050600060018251611ead9190615652565b905060005b825181101561204b578473ffffffffffffffffffffffffffffffffffffffff16838281518110611ee457611ee46154b7565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612039576000838381518110611f1b57611f1b6154b7565b6020026020010151905080600c60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206003018381548110611f6157611f616154b7565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600c90915260409020600301805480611fdb57611fdb615665565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061204b565b806120438161561a565b915050611eb2565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600d6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60006120f16133e6565b6120f9613423565b600b805467ffffffffffffffff1690600061211383615694565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160c081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815260a0870186905297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915596516002840180549190921697169690961790955592518051929650909450919261224f92600385019291019061487c565b5060a0919091015160049091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b60008060008060606122b08661363d565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff918216985092169550909183018282801561237d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612352575b5050505050905091939590929450565b6123956133e6565b601054610100900473ffffffffffffffffffffffffffffffffffffffff1633146123eb576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612425576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612433828401846149ec565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff1661249f576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff16918691906124d68385615535565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff1661252d9190615535565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8828784612594919061528e565b6040805192835260208301919091520160405180910390a2505050505050565b6000611214826000613804565b6125c96136a6565b60075461ffff808316620100009092041603612611576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff9081169082161115612655576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff62010000909104811680835290841660208301529091820190612688904361528e565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b6126e26136a6565b60055443101561271e576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff16600161273b91906156bb565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff938416021790819055760100000000000000000000000000000000000000000000900416156127cc57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff8216101561294d57600060036000018260ff16815481106127f7576127f76154b7565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff8616908110612846576128466154b7565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a15050508080612945906154e6565b9150506127cf565b50565b600060608060036002015460036000016003600101818054806020026020016040519081016040528092919081815260200182805480156129b057602002820191906000526020600020905b81548152602001906001019080831161299c575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612a1957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129ee575b50505050509050925092509250909192565b6060612a3884848461422c565b949350505050565b612a498261332d565b612a516133e6565b612a59613423565b612a62826142fb565b15610813576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612aa1612f53565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612b15573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b399190615236565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115612b9d576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cc3565b8181101561182a576000612bb18284615652565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af1158015612c33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c5791906155dc565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b6000611214826142fb565b612cc16136a6565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612cfb906152a1565b80601f0160208091040260200160405190810160405280929190818152602001828054612d27906152a1565b8015612d745780601f10612d4957610100808354040283529160200191612d74565b820191906000526020600020905b815481529060010190602001808311612d5757829003601f168201915b5050505050815260200160028201548152505090508060400151431015612dc7576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612dec57612dd9816020015161444c565b6020808201518051910120600a55612e94565b612df7826000613804565b73ffffffffffffffffffffffffffffffffffffffff1663354497aa82602001516040518263ffffffff1660e01b8152600401612e339190614b0b565b600060405180830381600087803b158015612e4d57600080fd5b505af1925050508015612e5e575060015b612e94576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff166001612eb191906156bb565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612f369286926156d6565b60405180910390a15050565b612f4a6136a6565b61294d81614547565b6109666136a6565b612f636133e6565b67ffffffffffffffff82166000908152600c60209081526040808320815160c08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff90811682850152600283015416606082015260038201805484518187028101870190955280855291949293608086019390929083018282801561304457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613019575b505050918352505060049190910154602090910152805190915060005b82608001515181101561310757600d600084608001518381518110613088576130886154b7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055806130ff8161561a565b915050613061565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff000000000000000000000000000000000000000090811690915560028201805490911690559061318d60038301826148f6565b6004820160009055505080600b60088282829054906101000a90046bffffffffffffffffffffffff166131c091906155b7565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af1158015613265573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061328991906155dc565b6132bf576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680613397576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461081d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff1615610966576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61344e7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613804565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af11580156134bc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134e091906155dc565b1515600003610966576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cc3565b67ffffffffffffffff82166000908152600c6020526040812060040154601254911a90811061357d576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cc3565b6012805460ff8316908110613594576135946154b7565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561182a576012805460ff83169081106135e4576135e46154b7565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cc3565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1661294d576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cc3565b613734614642565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6137b1613da3565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861377f3390565b6000816138435760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16801561383d579050611214565b506138d1565b60005b60035460ff821610156138cf576003805460ff831690811061386a5761386a6154b7565b906000526020600020015484036138bd576004805460ff8316908110613892576138926154b7565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112149050565b806138c7816154e6565b915050613846565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cc3565b60006bffffffffffffffffffffffff8211156139a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cc3565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b906139eb908990899089906024016156fe565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a611388811015613aa857600080fd5b611388810390508660408204820311613ac057600080fd5b853b613acb57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613b4584613906565b613b4f9086615505565b9050600081613b5e8886615535565b613b689190615535565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c909152928320805492975093945084939291613bbf918591166155b7565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613bf99190615535565b336000908152600e602052604081208054909190613c269084906bffffffffffffffffffffffff16615535565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b94509092613c6d91859116615535565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff16613cec91906155b7565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613d7091859169010000000000000000009004166155f9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60005460ff1615610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cc3565b6000613e1b8561363d565b613e2533866146ae565b613e2f858361351d565b6000613e3b8888613804565b6040805160e08101825233815267ffffffffffffffff891660208083018290526000828152600c808352858220600181015473ffffffffffffffffffffffffffffffffffffffff90811687890152606087018e905261ffff8d166080880152948352925260049182015460a085015263ffffffff891660c085015293517fe1a82d6f0000000000000000000000000000000000000000000000000000000081529495509293849384939287169263e1a82d6f92613ef89201615729565b6080604051808303816000875af1158015613f17573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f3b91906157bc565b92975090945092509050613f50338a8561474a565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff1681526020018242613fd0919061528e565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e604051614216969594939291906157fa565b60405180910390a4505050509695505050505050565b6060600080808061423f8688018861585e565b9350935093509350600061425889600187878787613e10565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156142ee57818160208110614297576142976154b7565b1a60f81b8782815181106142ad576142ad6154b7565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806142e68161561a565b91505061427c565b5050505050509392505050565b67ffffffffffffffff81166000908152600c602090815260408083206003018054825181850281018501909352808352849383018282801561437357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614348575b5050505050905060005b8151811015614442576000600d600084848151811061439e5761439e6154b7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461442f57506001949350505050565b508061443a8161561a565b91505061437d565b5060009392505050565b60008060008380602001905181019061446591906158cf565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052601180547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145109160129190860190614914565b509050507f02c673f957dfd44004b8ef12f6c1858031d7bd50b3918b09fb6f39bffede86a4838383604051612ca0939291906159b8565b3373ffffffffffffffffffffffffffffffffffffffff8216036145c6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cc3565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cc3565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff1661081d576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b67ffffffffffffffff82166000908152600c6020819052604090912080548392906147949084906c0100000000000000000000000090046bffffffffffffffffffffffff16615535565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261480a9284929004166155f9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614870579160200282015b82811115614870578251825591602001919060010190614855565b506139a49291506149ba565b828054828255906000526020600020908101928215614870579160200282015b8281111561487057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061489c565b508054600082559060005260206000209081019061294d91906149ba565b828054828255906000526020600020906007016008900481019282156148705791602002820160005b8382111561498157835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261493d565b80156149b15782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614981565b50506139a49291505b5b808211156139a457600081556001016149bb565b803567ffffffffffffffff811681146149e757600080fd5b919050565b6000602082840312156149fe57600080fd5b61183b826149cf565b803573ffffffffffffffffffffffffffffffffffffffff811681146149e757600080fd5b60008060408385031215614a3e57600080fd5b614a47836149cf565b9150614a5560208401614a07565b90509250929050565b63ffffffff8116811461294d57600080fd5b60008060408385031215614a8357600080fd5b614a8c836149cf565b91506020830135614a9c81614a5e565b809150509250929050565b6000815180845260005b81811015614acd57602081850181015186830182015201614ab1565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b60208152600061183b6020830184614aa7565b60008060408385031215614b3157600080fd5b614b3a836149cf565b946020939093013593505050565b60008083601f840112614b5a57600080fd5b50813567ffffffffffffffff811115614b7257600080fd5b602083019150836020828501011115614b8a57600080fd5b9250929050565b600080600060408486031215614ba657600080fd5b83359250602084013567ffffffffffffffff811115614bc457600080fd5b614bd086828701614b48565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614c5357614c53614bdd565b604052919050565b600067ffffffffffffffff821115614c7557614c75614bdd565b5060051b60200190565b600082601f830112614c9057600080fd5b81356020614ca5614ca083614c5b565b614c0c565b82815260059290921b84018101918181019086841115614cc457600080fd5b8286015b84811015614ce657614cd981614a07565b8352918301918301614cc8565b509695505050505050565b60008060408385031215614d0457600080fd5b823567ffffffffffffffff80821115614d1c57600080fd5b818501915085601f830112614d3057600080fd5b81356020614d40614ca083614c5b565b82815260059290921b84018101918181019089841115614d5f57600080fd5b948201945b83861015614d7d57853582529482019490820190614d64565b96505086013592505080821115614d9357600080fd5b50614da085828601614c7f565b9150509250929050565b600082601f830112614dbb57600080fd5b813567ffffffffffffffff811115614dd557614dd5614bdd565b614e0660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614c0c565b818152846020838601011115614e1b57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461294d57600080fd5b60008060008060008060c08789031215614e6b57600080fd5b86359550602087013567ffffffffffffffff80821115614e8a57600080fd5b614e968a838b01614daa565b96506040890135915080821115614eac57600080fd5b50614eb989828a01614daa565b9450506060870135614eca81614e38565b92506080870135614eda81614e38565b9150614ee860a08801614a07565b90509295509295509295565b803561ffff811681146149e757600080fd5b60008060008060008060a08789031215614f1f57600080fd5b614f28876149cf565b9550602087013567ffffffffffffffff811115614f4457600080fd5b614f5089828a01614b48565b9096509450614f63905060408801614ef4565b92506060870135614f7381614a5e565b80925050608087013590509295509295509295565b60008060408385031215614f9b57600080fd5b614fa483614a07565b91506020830135614a9c81614e38565b60008060208385031215614fc757600080fd5b823567ffffffffffffffff80821115614fdf57600080fd5b818501915085601f830112614ff357600080fd5b81358181111561500257600080fd5b8660208260051b850101111561501757600080fd5b60209290920196919550909350505050565b6000806040838503121561503c57600080fd5b61504583614a07565b9150614a55602084016149cf565b801515811461294d57600080fd5b6000806040838503121561507457600080fd5b823591506020830135614a9c81615053565b600081518084526020808501945080840160005b838110156150cc57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161509a565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a0608082018190526000906111eb90830184615086565b6000806000806060858703121561514257600080fd5b61514b85614a07565b935060208501359250604085013567ffffffffffffffff81111561516e57600080fd5b61517a87828801614b48565b95989497509550505050565b60006020828403121561519857600080fd5b5035919050565b6000602082840312156151b157600080fd5b61183b82614ef4565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156151fb578451835293830193918301916001016151df565b5050848103604086015261520f8187615086565b98975050505050505050565b60006020828403121561522d57600080fd5b61183b82614a07565b60006020828403121561524857600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112145761121461525f565b600181811c908216806152b557607f821691505b6020821081036152ee577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561182a57600081815260208120601f850160051c8101602086101561531b5750805b601f850160051c820191505b8181101561533a57828155600101615327565b505050505050565b815167ffffffffffffffff81111561535c5761535c614bdd565b6153708161536a84546152a1565b846152f4565b602080601f8311600181146153c3576000841561538d5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561533a565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015615410578886015182559484019460019091019084016153f1565b508582101561544c57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036154fc576154fc61525f565b60010192915050565b6bffffffffffffffffffffffff81811683821602808216919082811461552d5761552d61525f565b505092915050565b6bffffffffffffffffffffffff81811683821601908082111561555a5761555a61525f565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006155ad6080830184614aa7565b9695505050505050565b6bffffffffffffffffffffffff82811682821603908082111561555a5761555a61525f565b6000602082840312156155ee57600080fd5b815161183b81615053565b67ffffffffffffffff81811683821601908082111561555a5761555a61525f565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361564b5761564b61525f565b5060010190565b818103818111156112145761121461525f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036156b1576156b161525f565b6001019392505050565b61ffff81811683821601908082111561555a5761555a61525f565b8381528260208201526060604082015260006156f56060830184614aa7565b95945050505050565b8381526060602082015260006157176060830185614aa7565b82810360408401526155ad8185614aa7565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015267ffffffffffffffff602085015116604084015280604085015116606084015250606083015160e06080840152615788610100840182614aa7565b905061ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b600080600080608085870312156157d257600080fd5b8451935060208501516157e481614e38565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261583b60c0830186614aa7565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b6000806000806080858703121561587457600080fd5b61587d856149cf565b9350602085013567ffffffffffffffff81111561589957600080fd5b6158a587828801614daa565b9350506158b460408601614ef4565b915060608501356158c481614a5e565b939692955090935050565b6000806000606084860312156158e457600080fd5b83516158ef81614e38565b809350506020808501517fffffffff000000000000000000000000000000000000000000000000000000008116811461592757600080fd5b604086015190935067ffffffffffffffff81111561594457600080fd5b8501601f8101871361595557600080fd5b8051615963614ca082614c5b565b81815260059190911b8201830190838101908983111561598257600080fd5b928401925b828410156159a957835161599a81614a5e565b82529284019290840190615987565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615a3557845163ffffffff1683529383019391830191600101615a13565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -312,6 +312,28 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetContractById0(id [32]by return _FunctionsRouter.Contract.GetContractById0(&_FunctionsRouter.CallOpts, id) } +func (_FunctionsRouter *FunctionsRouterCaller) GetFlags(opts *bind.CallOpts, subscriptionId uint64) ([32]byte, error) { + var out []interface{} + err := _FunctionsRouter.contract.Call(opts, &out, "getFlags", subscriptionId) + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_FunctionsRouter *FunctionsRouterSession) GetFlags(subscriptionId uint64) ([32]byte, error) { + return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) +} + +func (_FunctionsRouter *FunctionsRouterCallerSession) GetFlags(subscriptionId uint64) ([32]byte, error) { + return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) +} + func (_FunctionsRouter *FunctionsRouterCaller) GetMaxConsumers(opts *bind.CallOpts) (uint16, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getMaxConsumers") @@ -457,6 +479,26 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) IsPaused() (bool, error) { return _FunctionsRouter.Contract.IsPaused(&_FunctionsRouter.CallOpts) } +func (_FunctionsRouter *FunctionsRouterCaller) IsValidCallbackGasLimit(opts *bind.CallOpts, subscriptionId uint64, callbackGasLimit uint32) error { + var out []interface{} + err := _FunctionsRouter.contract.Call(opts, &out, "isValidCallbackGasLimit", subscriptionId, callbackGasLimit) + + if err != nil { + return err + } + + return err + +} + +func (_FunctionsRouter *FunctionsRouterSession) IsValidCallbackGasLimit(subscriptionId uint64, callbackGasLimit uint32) error { + return _FunctionsRouter.Contract.IsValidCallbackGasLimit(&_FunctionsRouter.CallOpts, subscriptionId, callbackGasLimit) +} + +func (_FunctionsRouter *FunctionsRouterCallerSession) IsValidCallbackGasLimit(subscriptionId uint64, callbackGasLimit uint32) error { + return _FunctionsRouter.Contract.IsValidCallbackGasLimit(&_FunctionsRouter.CallOpts, subscriptionId, callbackGasLimit) +} + func (_FunctionsRouter *FunctionsRouterCaller) Owner(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "owner") @@ -761,6 +803,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) SendRequest(subscripti return _FunctionsRouter.Contract.SendRequest(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) } +func (_FunctionsRouter *FunctionsRouterTransactor) SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "setFlags", subscriptionId, flags) +} + +func (_FunctionsRouter *FunctionsRouterSession) SetFlags(subscriptionId uint64, flags [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.SetFlags(&_FunctionsRouter.TransactOpts, subscriptionId, flags) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) SetFlags(subscriptionId uint64, flags [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.SetFlags(&_FunctionsRouter.TransactOpts, subscriptionId, flags) +} + func (_FunctionsRouter *FunctionsRouterTransactor) TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "timeoutRequests", requestIdsToTimeout) } @@ -1027,6 +1081,7 @@ func (it *FunctionsRouterConfigSetIterator) Close() error { type FunctionsRouterConfigSet struct { AdminFee *big.Int HandleOracleFulfillmentSelector [4]byte + MaxCallbackGasLimits []uint32 Raw types.Log } @@ -3562,7 +3617,7 @@ func (FunctionsRouterConfigProposed) Topic() common.Hash { } func (FunctionsRouterConfigSet) Topic() common.Hash { - return common.HexToHash("0xb2b9bfb736b0bfef266985352cfca2a114226362209f5a6e5a2a2ed14383ba57") + return common.HexToHash("0x02c673f957dfd44004b8ef12f6c1858031d7bd50b3918b09fb6f39bffede86a4") } func (FunctionsRouterConfigUpdated) Topic() common.Hash { @@ -3660,6 +3715,8 @@ type FunctionsRouterInterface interface { GetContractById0(opts *bind.CallOpts, id [32]byte) (common.Address, error) + GetFlags(opts *bind.CallOpts, subscriptionId uint64) ([32]byte, error) + GetMaxConsumers(opts *bind.CallOpts) (uint16, error) GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) @@ -3674,6 +3731,8 @@ type FunctionsRouterInterface interface { IsPaused(opts *bind.CallOpts) (bool, error) + IsValidCallbackGasLimit(opts *bind.CallOpts, subscriptionId uint64, callbackGasLimit uint32) error + Owner(opts *bind.CallOpts) (common.Address, error) Paused(opts *bind.CallOpts) (bool, error) @@ -3716,6 +3775,8 @@ type FunctionsRouterInterface interface { SendRequest(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) + SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) + TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) TogglePaused(opts *bind.TransactOpts) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 68964a591be..f567e9b464b 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,8 +3,8 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../. functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a03725d15d3405d68bec96237a2155435a752c659c2b13b0746003f45e621ded functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin ea01c8210316c767b4925731a55ee03bfe5cf04f1c4663aa3115bbc36b94d01f -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin e2b8bf83f35eed9162a94c6e13ac3568e044cc38f89f117612ee8d92e59467e4 -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 158fb9e0f9caea329a037f17f0b73f291906c6d9e7e44a774fb17566232785e7 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin e6187f1a9f935fa78351bb39bbb1f1717594cdbeb0b82fe17755dea9a8992896 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 0297b5b61baf49527475de73422943b31adc470398cc670c053b6d037a63b727 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From 89b0e14948b502ccbee0aacca8251b314a4b2508 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Wed, 26 Jul 2023 17:30:08 -0400 Subject: [PATCH 008/270] add gas analysis test; gas golf registerUpkeep() (#9938) * add gas analysis test; gas golf registerUpkeep() * remove hacky address extraction from bytecode * cleanup --- .../automation/2_1/AutomationForwarder.sol | 64 +++-- .../2_1/AutomationForwarderLogic.sol | 24 ++ .../dev/automation/2_1/KeeperRegistry2_1.sol | 3 +- .../automation/2_1/KeeperRegistryBase2_1.sol | 22 +- .../2_1/KeeperRegistryLogicA2_1.sol | 30 +- .../2_1/KeeperRegistryLogicB2_1.sol | 14 +- .../automation/2_1/UpkeepTranscoder4_0.sol | 19 +- .../2_1/interfaces/IAutomationForwarder.sol | 15 + .../2_1/interfaces/IKeeperRegistryMaster.sol | 6 +- .../2_1/test/AutomationForwarder.t.sol | 14 +- .../src/v0.8/interfaces/ITypeAndVersion.sol | 6 + contracts/test/test-helpers/helpers.ts | 4 + .../automation/AutomationForwarder.test.ts | 30 +- .../automation/AutomationGasAnalysis.test.ts | 258 ++++++++++++++++++ .../automation/AutomationRegistrar2_1.test.ts | 6 +- .../v0.8/automation/KeeperRegistry2_1.test.ts | 20 +- .../automation/UpkeepTranscoder4_0.test.ts | 82 ++---- contracts/test/v0.8/automation/helpers.ts | 19 +- .../i_keeper_registry_master_wrapper_2_1.go | 26 +- .../keeper_registry_logic_a_wrapper_2_1.go | 2 +- .../keeper_registry_logic_b_wrapper_2_1.go | 32 ++- .../keeper_registry_wrapper_2_1.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 8 +- 23 files changed, 531 insertions(+), 175 deletions(-) create mode 100644 contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol create mode 100644 contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol create mode 100644 contracts/src/v0.8/interfaces/ITypeAndVersion.sol create mode 100644 contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts diff --git a/contracts/src/v0.8/dev/automation/2_1/AutomationForwarder.sol b/contracts/src/v0.8/dev/automation/2_1/AutomationForwarder.sol index dd365ca5ad6..1391a2babe7 100644 --- a/contracts/src/v0.8/dev/automation/2_1/AutomationForwarder.sol +++ b/contracts/src/v0.8/dev/automation/2_1/AutomationForwarder.sol @@ -12,18 +12,15 @@ uint256 constant PERFORM_GAS_CUSHION = 5_000; * which stays consistent between migrations. The Forwarder also exposes the registry address, so that users who * want to programatically interact with the registry (ie top up funds) can do so. */ -contract AutomationForwarder is TypeAndVersionInterface { - IAutomationRegistryConsumer private s_registry; +contract AutomationForwarder { address private immutable i_target; - uint256 private immutable i_upkeepID; - string public constant override typeAndVersion = "AutomationForwarder 1.0.0"; - - error NotAuthorized(); + address private immutable i_logic; + IAutomationRegistryConsumer private s_registry; - constructor(uint256 upkeepID, address target, address registry) { + constructor(address target, address registry, address logic) { s_registry = IAutomationRegistryConsumer(registry); i_target = target; - i_upkeepID = upkeepID; + i_logic = logic; } /** @@ -33,7 +30,7 @@ contract AutomationForwarder is TypeAndVersionInterface { * @return success indicating whether the target call succeeded or failed */ function forward(uint256 gasAmount, bytes memory data) external returns (bool success, uint256 gasUsed) { - if (msg.sender != address(s_registry)) revert NotAuthorized(); + if (msg.sender != address(s_registry)) revert(); address target = i_target; gasUsed = gasleft(); assembly { @@ -59,33 +56,34 @@ contract AutomationForwarder is TypeAndVersionInterface { return (success, gasUsed); } - /** - * @notice updateRegistry is called by the registry during migrations - * @param newRegistry is the registry that this forwarder is being migrated to - */ - function updateRegistry(address newRegistry) external { - if (msg.sender != address(s_registry)) revert NotAuthorized(); - s_registry = IAutomationRegistryConsumer(newRegistry); - } - - /** - * @notice gets the registry address - */ - function getRegistry() external view returns (IAutomationRegistryConsumer) { - return s_registry; - } - - /** - * @notice gets the target contract address - */ function getTarget() external view returns (address) { return i_target; } - /** - * @notice gets the upkeepID that this forwarder belongs to - */ - function getUpkeepID() external view returns (uint256) { - return i_upkeepID; + fallback() external { + // copy to memory for assembly access + address logic = i_logic; + // copied directly from OZ's Proxy contract + assembly { + // Copy msg.data. We take full control of memory in this inline assembly + // block because it will not return to Solidity code. We overwrite the + // Solidity scratch pad at memory position 0. + calldatacopy(0, 0, calldatasize()) + + // out and outsize are 0 because we don't know the size yet. + let result := delegatecall(gas(), logic, 0, calldatasize(), 0, 0) + + // Copy the returned data. + returndatacopy(0, 0, returndatasize()) + + switch result + // delegatecall returns 0 on error. + case 0 { + revert(0, returndatasize()) + } + default { + return(0, returndatasize()) + } + } } } diff --git a/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol b/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol new file mode 100644 index 00000000000..655c6131fd3 --- /dev/null +++ b/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import {IAutomationRegistryConsumer} from "./interfaces/IAutomationRegistryConsumer.sol"; +import "../../../interfaces/ITypeAndVersion.sol"; + +contract AutomationForwarderLogic is ITypeAndVersion { + IAutomationRegistryConsumer private s_registry; + + string public constant typeAndVersion = "AutomationForwarder 1.0.0"; + + /** + * @notice updateRegistry is called by the registry during migrations + * @param newRegistry is the registry that this forwarder is being migrated to + */ + function updateRegistry(address newRegistry) external { + if (msg.sender != address(s_registry)) revert(); + s_registry = IAutomationRegistryConsumer(newRegistry); + } + + function getRegistry() external view returns (IAutomationRegistryConsumer) { + return s_registry; + } +} diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol index a2b86007d28..422f3ae3b45 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol @@ -49,7 +49,8 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, ER logicA.getMode(), logicA.getLinkAddress(), logicA.getLinkNativeFeedAddress(), - logicA.getFastGasFeedAddress() + logicA.getFastGasFeedAddress(), + logicA.getAutomationForwarderLogic() ) Chainable(address(logicA)) {} diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index 3b0010f23e4..dc2f66fada7 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -9,7 +9,7 @@ import "../../../automation/ExecutionPrevention.sol"; import {ArbSys} from "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; import "./interfaces/FeedLookupCompatibleInterface.sol"; import "./interfaces/ILogAutomation.sol"; -import {AutomationForwarder} from "./AutomationForwarder.sol"; +import {IAutomationForwarder} from "./interfaces/IAutomationForwarder.sol"; import "../../../ConfirmedOwner.sol"; import "../../../interfaces/AggregatorV3Interface.sol"; import "../../../interfaces/LinkTokenInterface.sol"; @@ -70,6 +70,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { AggregatorV3Interface internal immutable i_linkNativeFeed; AggregatorV3Interface internal immutable i_fastGasFeed; Mode internal immutable i_mode; + address internal immutable i_automationForwarderLogic; /** * @dev - The storage is gas optimised for one and only one function - transmit. All the storage accessed in transmit @@ -263,20 +264,17 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { * @member amountSpent the amount this upkeep has spent * @member balance the balance of this upkeep * @member lastPerformedBlockNumber the last block number when this upkeep was performed - * @member target the contract which needs to be serviced */ struct Upkeep { bool paused; uint32 performGas; uint32 maxValidBlocknumber; - AutomationForwarder forwarder; + IAutomationForwarder forwarder; // 0 bytes left in 1st EVM word - not written to in transmit uint96 amountSpent; uint96 balance; uint32 lastPerformedBlockNumber; // 2 bytes left in 2nd EVM word - written in transmit path - address target; - // 12 bytes left in 3rd EVM word - neither written to nor read in transmit } /** @@ -450,11 +448,18 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { * @param linkNativeFeed address of the LINK/Native price feed * @param fastGasFeed address of the Fast Gas price feed */ - constructor(Mode mode, address link, address linkNativeFeed, address fastGasFeed) ConfirmedOwner(msg.sender) { + constructor( + Mode mode, + address link, + address linkNativeFeed, + address fastGasFeed, + address automationForwarderLogic + ) ConfirmedOwner(msg.sender) { i_mode = mode; i_link = LinkTokenInterface(link); i_linkNativeFeed = AggregatorV3Interface(linkNativeFeed); i_fastGasFeed = AggregatorV3Interface(fastGasFeed); + i_automationForwarderLogic = automationForwarderLogic; } /////////////////////////////////////////////////////////////////////////////////////// @@ -479,11 +484,10 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { bytes memory offchainConfig ) internal { if (s_hotVars.paused) revert RegistryPaused(); - if (!upkeep.target.isContract()) revert NotAContract(); if (checkData.length > s_storage.maxCheckDataSize) revert CheckDataExceedsLimit(); if (upkeep.performGas < PERFORM_GAS_MIN || upkeep.performGas > s_storage.maxPerformGas) revert GasLimitOutsideRange(); - if (s_upkeep[id].target != ZERO_ADDRESS) revert UpkeepAlreadyExists(); + if (address(s_upkeep[id].forwarder) != address(0)) revert UpkeepAlreadyExists(); s_upkeep[id] = upkeep; s_upkeepAdmin[id] = admin; s_checkData[id] = checkData; @@ -854,7 +858,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { * transmitter and the exact gas required by the Upkeep */ function _performUpkeep( - AutomationForwarder forwarder, + IAutomationForwarder forwarder, uint256 performGas, bytes memory performData ) internal nonReentrant returns (bool success, uint256 gasUsed) { diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol index bca218137f8..e4c38fa951c 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol @@ -26,7 +26,8 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { logicB.getMode(), logicB.getLinkAddress(), logicB.getLinkNativeFeedAddress(), - logicB.getFastGasFeedAddress() + logicB.getFastGasFeedAddress(), + logicB.getAutomationForwarderLogic() ) Chainable(address(logicB)) {} @@ -82,7 +83,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { bytes memory callData = _checkPayload(id, triggerType, triggerData); gasUsed = gasleft(); - (bool success, bytes memory result) = upkeep.target.call{gas: s_storage.checkGasLimit}(callData); + (bool success, bytes memory result) = upkeep.forwarder.getTarget().call{gas: s_storage.checkGasLimit}(callData); gasUsed = gasUsed - gasleft(); if (!success) { @@ -191,7 +192,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { { Upkeep memory upkeep = s_upkeep[id]; gasUsed = gasleft(); - (bool success, bytes memory result) = upkeep.target.call{gas: s_storage.checkGasLimit}(payload); + (bool success, bytes memory result) = upkeep.forwarder.getTarget().call{gas: s_storage.checkGasLimit}(payload); gasUsed = gasUsed - gasleft(); if (!success) { return (false, bytes(""), UpkeepFailureReason.CALLBACK_REVERTED, gasUsed); @@ -227,12 +228,14 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { bytes memory offchainConfig ) public returns (uint256 id) { if (msg.sender != owner() && !s_registrars.contains(msg.sender)) revert OnlyCallableByOwnerOrRegistrar(); + if (!target.isContract()) revert NotAContract(); id = _createID(triggerType); - AutomationForwarder forwarder = new AutomationForwarder(id, target, address(this)); + IAutomationForwarder forwarder = IAutomationForwarder( + address(new AutomationForwarder(target, address(this), i_automationForwarderLogic)) + ); _createUpkeep( id, Upkeep({ - target: target, performGas: gasLimit, balance: 0, maxValidBlocknumber: UINT32_MAX, @@ -363,7 +366,15 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { emit UpkeepMigrated(id, upkeep.balance, destination); } s_expectedLinkBalance = s_expectedLinkBalance - totalBalanceRemaining; - bytes memory encodedUpkeeps = abi.encode(ids, upkeeps, admins, checkDatas, triggerConfigs, offchainConfigs); + bytes memory encodedUpkeeps = abi.encode( + ids, + upkeeps, + new address[](ids.length), + admins, + checkDatas, + triggerConfigs, + offchainConfigs + ); MigratableKeeperRegistryInterfaceV2(destination).receiveUpkeeps( UpkeepTranscoderInterfaceV2(s_storage.transcoder).transcodeUpkeeps( UPKEEP_VERSION_BASE, @@ -387,14 +398,17 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { ( uint256[] memory ids, Upkeep[] memory upkeeps, + address[] memory targets, address[] memory upkeepAdmins, bytes[] memory checkDatas, bytes[] memory triggerConfigs, bytes[] memory offchainConfigs - ) = abi.decode(encodedUpkeeps, (uint256[], Upkeep[], address[], bytes[], bytes[], bytes[])); + ) = abi.decode(encodedUpkeeps, (uint256[], Upkeep[], address[], address[], bytes[], bytes[], bytes[])); for (uint256 idx = 0; idx < ids.length; idx++) { if (address(upkeeps[idx].forwarder) == ZERO_ADDRESS) { - upkeeps[idx].forwarder = new AutomationForwarder(ids[idx], upkeeps[idx].target, address(this)); + upkeeps[idx].forwarder = IAutomationForwarder( + address(new AutomationForwarder(targets[idx], address(this), i_automationForwarderLogic)) + ); } _createUpkeep( ids[idx], diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol index 8cc0c137453..5acc3cb6725 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol @@ -15,8 +15,9 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { Mode mode, address link, address linkNativeFeed, - address fastGasFeed - ) KeeperRegistryBase2_1(mode, link, linkNativeFeed, fastGasFeed) {} + address fastGasFeed, + address automationForwarderLogic + ) KeeperRegistryBase2_1(mode, link, linkNativeFeed, fastGasFeed, automationForwarderLogic) {} /////////////////////// // UPKEEP MANAGEMENT // @@ -299,6 +300,10 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { return address(i_fastGasFeed); } + function getAutomationForwarderLogic() external view returns (address) { + return i_automationForwarderLogic; + } + function upkeepTranscoderVersion() public pure returns (UpkeepFormat) { return UPKEEP_TRANSCODER_VERSION_BASE; } @@ -314,8 +319,9 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { */ function getUpkeep(uint256 id) external view returns (UpkeepInfo memory upkeepInfo) { Upkeep memory reg = s_upkeep[id]; + address target = address(reg.forwarder) == address(0) ? address(0) : reg.forwarder.getTarget(); upkeepInfo = UpkeepInfo({ - target: reg.target, + target: target, performGas: reg.performGas, checkData: s_checkData[id], balance: reg.balance, @@ -501,7 +507,7 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { /** * @notice returns the upkeep's forwarder contract */ - function getForwarder(uint256 upkeepID) external view returns (AutomationForwarder) { + function getForwarder(uint256 upkeepID) external view returns (IAutomationForwarder) { return s_upkeep[upkeepID].forwarder; } } diff --git a/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol b/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol index b4b3b1a97f3..3547fe703e5 100644 --- a/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol +++ b/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol @@ -5,7 +5,7 @@ pragma solidity 0.8.16; import "../../../interfaces/automation/UpkeepTranscoderInterfaceV2.sol"; import "../../../interfaces/TypeAndVersionInterface.sol"; import {KeeperRegistryBase2_1 as R21} from "./KeeperRegistryBase2_1.sol"; -import {AutomationForwarder} from "./AutomationForwarder.sol"; +import {IAutomationForwarder} from "./interfaces/IAutomationForwarder.sol"; import {AutomationRegistryBaseInterface, UpkeepInfo} from "../../../interfaces/automation/2_0/AutomationRegistryInterface2_0.sol"; enum RegistryVersion { @@ -63,7 +63,7 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter */ string public constant override typeAndVersion = "UpkeepTranscoder 4.0.0"; uint32 internal constant UINT32_MAX = type(uint32).max; - AutomationForwarder internal constant ZERO_FORWARDER = AutomationForwarder(address(0)); + IAutomationForwarder internal constant ZERO_FORWARDER = IAutomationForwarder(address(0)); /** * @notice transcodeUpkeeps transforms upkeep data from the format expected by @@ -91,6 +91,7 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter if (ids.length != upkeepsV12.length || ids.length != checkDatas.length) { revert InvalidTranscoding(); } + address[] memory targets = new address[](ids.length); address[] memory admins = new address[](ids.length); R21.Upkeep[] memory newUpkeeps = new R21.Upkeep[](ids.length); UpkeepV12 memory upkeepV12; @@ -100,15 +101,15 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter performGas: upkeepV12.executeGas, maxValidBlocknumber: UINT32_MAX, // maxValidBlocknumber is uint64 in V1, hence a new default value is provided paused: false, // migrated upkeeps are not paused by default - target: upkeepV12.target, forwarder: ZERO_FORWARDER, amountSpent: upkeepV12.amountSpent, balance: upkeepV12.balance, lastPerformedBlockNumber: 0 }); + targets[idx] = upkeepV12.target; admins[idx] = upkeepV12.admin; } - return abi.encode(ids, newUpkeeps, admins, checkDatas, new bytes[](ids.length), new bytes[](ids.length)); + return abi.encode(ids, newUpkeeps, targets, admins, checkDatas, new bytes[](ids.length), new bytes[](ids.length)); } // v1.3 => v2.1 if (fromVersion == uint8(RegistryVersion.V13)) { @@ -119,6 +120,7 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter if (ids.length != upkeepsV13.length || ids.length != checkDatas.length) { revert InvalidTranscoding(); } + address[] memory targets = new address[](ids.length); address[] memory admins = new address[](ids.length); R21.Upkeep[] memory newUpkeeps = new R21.Upkeep[](ids.length); UpkeepV13 memory upkeepV13; @@ -128,15 +130,15 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter performGas: upkeepV13.executeGas, maxValidBlocknumber: upkeepV13.maxValidBlocknumber, paused: upkeepV13.paused, - target: upkeepV13.target, forwarder: ZERO_FORWARDER, amountSpent: upkeepV13.amountSpent, balance: upkeepV13.balance, lastPerformedBlockNumber: 0 }); + targets[idx] = upkeepV13.target; admins[idx] = upkeepV13.admin; } - return abi.encode(ids, newUpkeeps, admins, checkDatas, new bytes[](ids.length), new bytes[](ids.length)); + return abi.encode(ids, newUpkeeps, targets, admins, checkDatas, new bytes[](ids.length), new bytes[](ids.length)); } // v2.0 => v2.1 if (fromVersion == uint8(RegistryVersion.V20)) { @@ -149,6 +151,7 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter AutomationRegistryBaseInterface registry20 = AutomationRegistryBaseInterface(msg.sender); R21.Upkeep[] memory newUpkeeps = new R21.Upkeep[](ids.length); bytes[] memory offchainConfigs = new bytes[](ids.length); + address[] memory targets = new address[](ids.length); UpkeepV20 memory upkeepV20; for (uint256 idx = 0; idx < ids.length; idx++) { upkeepV20 = upkeepsV20[idx]; @@ -156,15 +159,15 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter performGas: upkeepV20.executeGas, maxValidBlocknumber: upkeepV20.maxValidBlocknumber, paused: upkeepV20.paused, - target: upkeepV20.target, forwarder: ZERO_FORWARDER, amountSpent: upkeepV20.amountSpent, balance: upkeepV20.balance, lastPerformedBlockNumber: 0 }); + targets[idx] = upkeepV20.target; offchainConfigs[idx] = registry20.getUpkeep(ids[idx]).offchainConfig; } - return abi.encode(ids, newUpkeeps, admins, checkDatas, new bytes[](ids.length), offchainConfigs); + return abi.encode(ids, newUpkeeps, targets, admins, checkDatas, new bytes[](ids.length), offchainConfigs); } // v2.1 => v2.1 if (fromVersion == uint8(RegistryVersion.V21)) { diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol new file mode 100644 index 00000000000..d7ae7f573a0 --- /dev/null +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import "../../../../interfaces/ITypeAndVersion.sol"; +import {IAutomationRegistryConsumer} from "./IAutomationRegistryConsumer.sol"; + +interface IAutomationForwarder is ITypeAndVersion { + function forward(uint256 gasAmount, bytes memory data) external returns (bool success, uint256 gasUsed); + + function updateRegistry(address newRegistry) external; + + function getRegistry() external view returns (IAutomationRegistryConsumer); + + function getTarget() external view returns (address); +} diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol index 09fc6488d3d..6a31ed9317c 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol @@ -1,4 +1,4 @@ -// abi-checksum: 0x6565db16782f234c7deba02db44ac01288fa7e6e063f5b02a4a6825a5826c481 +// abi-checksum: 0xd6afaa401e56004015d2d8e11158ae6f810ee421a634423a6e9533f09fa544c6 // SPDX-License-Identifier: MIT // !! THIS FILE WAS AUTOGENERATED BY abi-to-sol v0.6.6. SEE SOURCE BELOW. !! pragma solidity ^0.8.4; @@ -226,6 +226,8 @@ interface IKeeperRegistryMaster { function getAdminPrivilegeConfig(address admin) external view returns (bytes memory); + function getAutomationForwarderLogic() external view returns (address); + function getBalance(uint256 id) external view returns (uint96 balance); function getCancellationDelay() external pure returns (uint256); @@ -372,5 +374,5 @@ interface KeeperRegistryBase2_1 { // THIS FILE WAS AUTOGENERATED FROM THE FOLLOWING ABI JSON: /* -[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getCheckGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract AutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTransmitGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getCheckGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTransmitGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] */ diff --git a/contracts/src/v0.8/dev/automation/2_1/test/AutomationForwarder.t.sol b/contracts/src/v0.8/dev/automation/2_1/test/AutomationForwarder.t.sol index 2b5d76e98d1..d876def8bf0 100644 --- a/contracts/src/v0.8/dev/automation/2_1/test/AutomationForwarder.t.sol +++ b/contracts/src/v0.8/dev/automation/2_1/test/AutomationForwarder.t.sol @@ -2,7 +2,9 @@ pragma solidity 0.8.16; import {IAutomationRegistryConsumer} from "../interfaces/IAutomationRegistryConsumer.sol"; +import {IAutomationForwarder} from "../interfaces/IAutomationForwarder.sol"; import {AutomationForwarder} from "../AutomationForwarder.sol"; +import {AutomationForwarderLogic} from "../AutomationForwarderLogic.sol"; import {MockKeeperRegistry2_1} from "../mocks/MockKeeperRegistry2_1.sol"; import {UpkeepCounter} from "../mocks/UpkeepCounter.sol"; import {BaseTest} from "./BaseTest.t.sol"; @@ -11,7 +13,8 @@ import {BaseTest} from "./BaseTest.t.sol"; // forge test --match-path src/v0.8/dev/automation/2_1/test/AutomationForwarder.t.sol contract AutomationForwarderSetUp is BaseTest { - AutomationForwarder internal forwarder; + IAutomationForwarder internal forwarder; + AutomationForwarderLogic internal logicContract; IAutomationRegistryConsumer internal default_registry; UpkeepCounter internal default_target; uint256 constant GAS = 1e18; @@ -21,7 +24,10 @@ contract AutomationForwarderSetUp is BaseTest { default_registry = IAutomationRegistryConsumer(new MockKeeperRegistry2_1()); default_target = new UpkeepCounter(10000, 1); vm.startPrank(address(default_registry)); - forwarder = new AutomationForwarder(1, address(default_target), address(default_registry)); + logicContract = new AutomationForwarderLogic(); + forwarder = IAutomationForwarder( + address(new AutomationForwarder(address(default_target), address(default_registry), address(logicContract))) + ); // OWNER not necessary? OWNER = address(default_registry); } @@ -57,7 +63,7 @@ contract AutomationForwarder_forward is AutomationForwarderSetUp { uint256 prevCount = default_target.counter(); bytes memory selector = getSelector("performUpkeep(bytes)", ""); changePrank(STRANGER); - vm.expectRevert(AutomationForwarder.NotAuthorized.selector); + vm.expectRevert(); (bool val, uint256 gasUsed) = forwarder.forward(GAS, selector); assertFalse(val); assertEq(gasUsed, 0); @@ -77,7 +83,7 @@ contract AutomationForwarder_updateRegistry is AutomationForwarderSetUp { function testNotFromRegistryNotAuthorizedReverts() public { address newRegistry = address(1); changePrank(STRANGER); - vm.expectRevert(AutomationForwarder.NotAuthorized.selector); + vm.expectRevert(); forwarder.updateRegistry(address(newRegistry)); } } diff --git a/contracts/src/v0.8/interfaces/ITypeAndVersion.sol b/contracts/src/v0.8/interfaces/ITypeAndVersion.sol new file mode 100644 index 00000000000..135f6d0aebf --- /dev/null +++ b/contracts/src/v0.8/interfaces/ITypeAndVersion.sol @@ -0,0 +1,6 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +interface ITypeAndVersion { + function typeAndVersion() external pure returns (string memory); +} diff --git a/contracts/test/test-helpers/helpers.ts b/contracts/test/test-helpers/helpers.ts index 94fe91ce4f4..e65cd57e8d9 100644 --- a/contracts/test/test-helpers/helpers.ts +++ b/contracts/test/test-helpers/helpers.ts @@ -336,3 +336,7 @@ export async function reset() { params: [], }) } + +export function randomAddress() { + return ethers.Wallet.createRandom().address +} diff --git a/contracts/test/v0.8/automation/AutomationForwarder.test.ts b/contracts/test/v0.8/automation/AutomationForwarder.test.ts index 6fb91f5f77c..634bfb61ea9 100644 --- a/contracts/test/v0.8/automation/AutomationForwarder.test.ts +++ b/contracts/test/v0.8/automation/AutomationForwarder.test.ts @@ -1,7 +1,8 @@ import { expect } from 'chai' import { ethers } from 'hardhat' import { getUsers, Roles } from '../../test-helpers/setup' -import { AutomationForwarder } from '../../../typechain/AutomationForwarder' +import { IAutomationForwarder } from '../../../typechain/IAutomationForwarder' +import { IAutomationForwarder__factory as IAutomationForwarderFactory } from '../../../typechain/factories/IAutomationForwarder__factory' import { loadFixture } from '@nomicfoundation/hardhat-network-helpers' import { deployMockContract, @@ -15,12 +16,11 @@ import { * the contract factory, which deploys forwarder instances :) */ -const NOT_AUTHORIZED_ERR = 'NotAuthorized()' const CUSTOM_REVERT = 'this is a custom revert message' let roles: Roles let defaultAddress: string -let forwarder: AutomationForwarder +let forwarder: IAutomationForwarder let target: MockContract const targetABI = [ @@ -45,11 +45,24 @@ const setup = async () => { await target.mock.handler.returns() await target.mock.handlerUint.returns(100) await target.mock.iRevert.revertsWithReason(CUSTOM_REVERT) + const logicFactory = await ethers.getContractFactory( + 'AutomationForwarderLogic', + ) + const logicContract = await logicFactory + .connect(roles.defaultAccount) + .deploy() const factory = await ethers.getContractFactory('AutomationForwarder') - forwarder = await factory + const forwarderContract = await factory .connect(roles.defaultAccount) - .deploy(100, target.address, await roles.defaultAccount.getAddress()) - await forwarder.deployed() + .deploy( + target.address, + await roles.defaultAccount.getAddress(), + logicContract.address, + ) + forwarder = IAutomationForwarderFactory.connect( + forwarderContract.address, + roles.defaultAccount, + ) } describe('AutomationForwarder', () => { @@ -61,7 +74,6 @@ describe('AutomationForwarder', () => { it('sets the initial values', async () => { expect(await forwarder.getRegistry()).to.equal(defaultAddress) expect(await forwarder.getTarget()).to.equal(target.address) - expect(await forwarder.getUpkeepID()).to.equal(100) }) }) @@ -78,7 +90,7 @@ describe('AutomationForwarder', () => { it('is only callable by the registry', async () => { await expect( forwarder.connect(roles.stranger).forward(gas, HANDLER), - ).to.be.revertedWith(NOT_AUTHORIZED_ERR) + ).to.be.revertedWith('') await forwarder.connect(roles.defaultAccount).forward(gas, HANDLER) }) @@ -121,7 +133,7 @@ describe('AutomationForwarder', () => { it('is only callable by the existing registry', async () => { await expect( forwarder.connect(roles.stranger).updateRegistry(newRegistry), - ).to.be.revertedWith(NOT_AUTHORIZED_ERR) + ).to.be.revertedWith('') await forwarder.connect(roles.defaultAccount).updateRegistry(newRegistry) }) diff --git a/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts b/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts new file mode 100644 index 00000000000..ae49d30348c --- /dev/null +++ b/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts @@ -0,0 +1,258 @@ +import { ethers } from 'hardhat' +import { BigNumber } from 'ethers' +import { expect, assert } from 'chai' +import { getUsers } from '../../test-helpers/setup' +import { randomAddress, toWei } from '../../test-helpers/helpers' +import { deployRegistry21, setConfigExplicit } from './helpers' + +// don't run these tests in CI +const describeMaybe = process.env.CI ? describe.skip : describe + +// registry settings +const f = 1 +const linkEth = BigNumber.from(300000000) +const gasWei = BigNumber.from(100) +const minUpkeepSpend = BigNumber.from('1000000000000000000') +const paymentPremiumPPB = BigNumber.from(250000000) +const flatFeeMicroLink = BigNumber.from(0) +const blockCountPerTurn = 20 +const checkGasLimit = BigNumber.from(20000000) +const fallbackGasPrice = BigNumber.from(200) +const fallbackLinkPrice = BigNumber.from(200000000) +const maxCheckDataSize = BigNumber.from(10000) +const maxPerformDataSize = BigNumber.from(10000) +const maxRevertDataSize = BigNumber.from(1000) +const maxPerformGas = BigNumber.from(5000000) +const stalenessSeconds = BigNumber.from(43820) +const gasCeilingMultiplier = BigNumber.from(1) +const signers = [ + randomAddress(), + randomAddress(), + randomAddress(), + randomAddress(), +] +const transmitters = [ + randomAddress(), + randomAddress(), + randomAddress(), + randomAddress(), +] +const transcoder = ethers.constants.AddressZero + +// registrar settings +const triggerType = 0 // conditional +const autoApproveType = 2 // auto-approve enabled +const autoApproveMaxAllowed = 100 // auto-approve enabled + +// upkeep settings +const name = 'test upkeep' +const encryptedEmail = '0xabcd1234' +const gasLimit = 100_000 +const checkData = '0xdeadbeef' +const amount = toWei('5') +const source = 5 +const triggerConfig = '0x' +const offchainConfig = '0x' + +describeMaybe('Automation Gas Analysis', () => { + it('Compares gas usage amongst registries / registrars', async () => { + assert( + Boolean(process.env.REPORT_GAS), + 'this test must be run with REPORT_GAS=true', + ) + + const personas = (await getUsers()).personas + const owner = personas.Default + const ownerAddress = await owner.getAddress() + + // factories + const getFact = ethers.getContractFactory + const linkTokenFactory = await getFact('LinkToken') + const mockV3AggregatorFactory = await getFact( + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', + ) + const upkeepMockFactory = await getFact('UpkeepMock') + const registry12Factory = await getFact('KeeperRegistry1_2') + const registrar12Factory = await getFact('KeeperRegistrar') + const registry20Factory = await getFact('KeeperRegistry2_0') + const registryLogic20Factory = await getFact('KeeperRegistryLogic2_0') + const registrar20Factory = await getFact('KeeperRegistrar2_0') + const registrar21Factory = await getFact('AutomationRegistrar2_1') + const forwarderLogicFactory = await getFact('AutomationForwarderLogic') + + // deploy dependancy contracts + const linkToken = await linkTokenFactory.connect(owner).deploy() + const gasPriceFeed = await mockV3AggregatorFactory + .connect(owner) + .deploy(0, gasWei) + const linkEthFeed = await mockV3AggregatorFactory + .connect(owner) + .deploy(9, linkEth) + const upkeep = await upkeepMockFactory.connect(owner).deploy() + + // deploy v1.2 + const registrar12 = await registrar12Factory.connect(owner).deploy( + linkToken.address, + autoApproveType, + autoApproveMaxAllowed, + ethers.constants.AddressZero, // set later + minUpkeepSpend, + ) + const registry12 = await registry12Factory + .connect(owner) + .deploy(linkToken.address, linkEthFeed.address, gasPriceFeed.address, { + paymentPremiumPPB, + flatFeeMicroLink, + blockCountPerTurn, + checkGasLimit, + stalenessSeconds, + gasCeilingMultiplier, + minUpkeepSpend, + maxPerformGas, + fallbackGasPrice, + fallbackLinkPrice, + transcoder, + registrar: registrar12.address, + }) + await registrar12.setRegistrationConfig( + autoApproveType, + autoApproveMaxAllowed, + registry12.address, + minUpkeepSpend, + ) + + // deploy v2.0 + const registryLogic20 = await registryLogic20Factory + .connect(owner) + .deploy(0, linkToken.address, linkEthFeed.address, gasPriceFeed.address) + const registry20 = await registry20Factory + .connect(owner) + .deploy(registryLogic20.address) + const registrar20 = await registrar20Factory + .connect(owner) + .deploy( + linkToken.address, + autoApproveType, + autoApproveMaxAllowed, + registry20.address, + minUpkeepSpend, + ) + const config20 = { + paymentPremiumPPB, + flatFeeMicroLink, + checkGasLimit, + stalenessSeconds, + gasCeilingMultiplier, + minUpkeepSpend, + maxCheckDataSize, + maxPerformDataSize, + maxPerformGas, + fallbackGasPrice, + fallbackLinkPrice, + transcoder, + registrar: registrar20.address, + } + const onchainConfig20 = ethers.utils.defaultAbiCoder.encode( + [ + 'tuple(uint32 paymentPremiumPPB,uint32 flatFeeMicroLink,uint32 checkGasLimit,uint24 stalenessSeconds\ + ,uint16 gasCeilingMultiplier,uint96 minUpkeepSpend,uint32 maxPerformGas,uint32 maxCheckDataSize,\ + uint32 maxPerformDataSize,uint256 fallbackGasPrice,uint256 fallbackLinkPrice,address transcoder,\ + address registrar)', + ], + [config20], + ) + await registry20 + .connect(owner) + .setConfig(signers, transmitters, f, onchainConfig20, 1, '0x') + + // deploy v2.1 + const forwarderLogic = await forwarderLogicFactory.connect(owner).deploy() + const registry21 = await deployRegistry21( + owner, + 0, + linkToken.address, + linkEthFeed.address, + gasPriceFeed.address, + forwarderLogic.address, + ) + const registrar21 = await registrar21Factory + .connect(owner) + .deploy(linkToken.address, registry21.address, minUpkeepSpend, [ + { + triggerType, + autoApproveType, + autoApproveMaxAllowed, + }, + ]) + const onchainConfig21 = { + paymentPremiumPPB, + flatFeeMicroLink, + checkGasLimit, + stalenessSeconds, + gasCeilingMultiplier, + minUpkeepSpend, + maxCheckDataSize, + maxPerformDataSize, + maxRevertDataSize, + maxPerformGas, + fallbackGasPrice, + fallbackLinkPrice, + transcoder, + registrars: [registrar21.address], + upkeepPrivilegeManager: randomAddress(), + } + await registry21 + .connect(owner) + [setConfigExplicit](signers, transmitters, f, onchainConfig21, 1, '0x') + + // approve LINK + await linkToken.connect(owner).approve(registrar20.address, amount) + await linkToken.connect(owner).approve(registrar21.address, amount) + + const abiEncodedBytes = registrar12.interface.encodeFunctionData( + 'register', + [ + name, + encryptedEmail, + upkeep.address, + gasLimit, + ownerAddress, + checkData, + amount, + source, + ownerAddress, + ], + ) + + let tx = await linkToken + .connect(owner) + .transferAndCall(registrar12.address, amount, abiEncodedBytes) + await expect(tx).to.emit(registry12, 'UpkeepRegistered') + + tx = await registrar20.connect(owner).registerUpkeep({ + name, + encryptedEmail, + upkeepContract: upkeep.address, + gasLimit, + adminAddress: ownerAddress, + checkData, + amount, + offchainConfig, + }) + await expect(tx).to.emit(registry20, 'UpkeepRegistered') + + tx = await registrar21.connect(owner).registerUpkeep({ + name, + encryptedEmail, + upkeepContract: upkeep.address, + gasLimit, + adminAddress: ownerAddress, + triggerType, + checkData, + amount, + triggerConfig, + offchainConfig, + }) + await expect(tx).to.emit(registry21, 'UpkeepRegistered') + }) +}) diff --git a/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts b/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts index 5912373e9a7..bb427122dd2 100644 --- a/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts +++ b/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts @@ -12,7 +12,7 @@ import { UpkeepMock } from '../../../typechain/UpkeepMock' import { toWei } from '../../test-helpers/helpers' import { IKeeperRegistryMaster as IKeeperRegistry } from '../../../typechain/IKeeperRegistryMaster' import { AutomationRegistrar2_1 as Registrar } from '../../../typechain/AutomationRegistrar2_1' -import { deployRegistry21 } from './helpers' +import { deployRegistry21, setConfigExplicit } from './helpers' // copied from KeeperRegistryBase2_1.sol enum Trigger { @@ -163,9 +163,7 @@ describe('AutomationRegistrar2_1', () => { } await registry .connect(owner) - [ - 'setConfig(address[],address[],uint8,(uint32,uint32,uint32,uint24,uint16,uint96,uint32,uint32,uint32,uint32,uint256,uint256,address,address[],address),uint64,bytes)' - ](keepers, keepers, 1, onchainConfig, 1, '0x') + [setConfigExplicit](keepers, keepers, 1, onchainConfig, 1, '0x') }) describe('#typeAndVersion', () => { diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index f6ef0eaae86..cbd60c8d12f 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -12,7 +12,7 @@ import { } from 'ethers' import { evmRevert } from '../../test-helpers/matchers' import { getUsers, Personas } from '../../test-helpers/setup' -import { toWei } from '../../test-helpers/helpers' +import { toWei, randomAddress } from '../../test-helpers/helpers' import { LinkToken__factory as LinkTokenFactory } from '../../../typechain/factories/LinkToken__factory' import { MercuryUpkeep__factory as MercuryUpkeepFactory } from '../../../typechain/factories/MercuryUpkeep__factory' import { MockV3Aggregator__factory as MockV3AggregatorFactory } from '../../../typechain/factories/MockV3Aggregator__factory' @@ -21,6 +21,7 @@ import { UpkeepAutoFunder__factory as UpkeepAutoFunderFactory } from '../../../t import { MockArbGasInfo__factory as MockArbGasInfoFactory } from '../../../typechain/factories/MockArbGasInfo__factory' import { MockOVMGasPriceOracle__factory as MockOVMGasPriceOracleFactory } from '../../../typechain/factories/MockOVMGasPriceOracle__factory' import { ILogAutomation__factory as ILogAutomationactory } from '../../../typechain/factories/ILogAutomation__factory' +import { IAutomationForwarder__factory as IAutomationForwarderFactory } from '../../../typechain/factories/IAutomationForwarder__factory' import { MockArbSys__factory as MockArbSysFactory } from '../../../typechain/factories/MockArbSys__factory' import { AutomationUtils2_1 as AutomationUtils } from '../../../typechain/AutomationUtils2_1' import { MercuryUpkeep } from '../../../typechain/MercuryUpkeep' @@ -43,7 +44,7 @@ import { deployMockContract, MockContract, } from '@ethereum-waffle/mock-contract' -import { deployRegistry21 } from './helpers' +import { deployRegistry21, setConfigRaw, setConfigExplicit } from './helpers' const describeMaybe = process.env.SKIP_SLOW ? describe.skip : describe const itMaybe = process.env.SKIP_SLOW ? it.skip : it @@ -82,11 +83,6 @@ type LogTrigger = Parameters[0] type ConditionalTrigger = Parameters[0] type Log = Parameters[0] -// function signatures for the two setConfig methods -const setConfigRaw = 'setConfig(address[],address[],uint8,bytes,uint64,bytes)' -const setConfigExplicit = - 'setConfig(address[],address[],uint8,(uint32,uint32,uint32,uint24,uint16,uint96,uint32,uint32,uint32,uint32,uint256,uint256,address,address[],address),uint64,bytes)' - // ----------------------------------------------------------------------------------------------- // These values should match the constants declared in registry @@ -166,10 +162,6 @@ let mockOVMGasPriceOracle: MockOVMGasPriceOracle let mercuryUpkeep: MercuryUpkeep let automationUtils: AutomationUtils -function randomAddress() { - return ethers.Wallet.createRandom().address -} - function now() { return Math.floor(Date.now() / 1000) } @@ -4735,10 +4727,10 @@ describe('KeeperRegistry2_1', () => { expect((await registry.getState()).state.numUpkeeps).to.equal( numUpkeeps, ) - const forwarderFactory = await ethers.getContractFactory( - 'AutomationForwarder', + const forwarder = await IAutomationForwarderFactory.connect( + forwarderAddress, + owner, ) - const forwarder = await forwarderFactory.attach(forwarderAddress) expect(await forwarder.getRegistry()).to.equal(registry.address) // Set an upkeep admin transfer in progress too await registry diff --git a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts index f7759f935ba..9f58a7f47f6 100644 --- a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts +++ b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts @@ -96,7 +96,7 @@ async function getUpkeepID(tx: any): Promise { return receipt.events[0].args.id } -const encodeConfig = (config: any) => { +const encodeConfig20 = (config: any) => { return ethers.utils.defaultAbiCoder.encode( [ 'tuple(uint32 paymentPremiumPPB,uint32 flatFeeMicroLink,uint32 checkGasLimit,uint24 stalenessSeconds\ @@ -119,38 +119,6 @@ const encodeUpkeepV12 = (ids: number[], upkeeps: any[], checkDatas: any[]) => { ) } -const encodeUpkeepV13 = (ids: number[], upkeeps: any[], checkDatas: any[]) => { - return ethers.utils.defaultAbiCoder.encode( - [ - 'uint256[]', - 'tuple(uint96,address,uint96,address,uint32,uint32,address,bool)[]', - 'bytes[]', - ], - [ids, upkeeps, checkDatas], - ) -} - -const encodeUpkeepV21 = ( - ids: number[], - upkeeps: any[], - admins: string[], - checkDatas: string[], - triggerConfigs: string[], - offchainConfigs: string[], -) => { - return ethers.utils.defaultAbiCoder.encode( - [ - 'uint256[]', - 'tuple(bool,uint32,uint32,address,uint96,uint96,uint32,address)[]', - 'address[]', - 'bytes[]', - 'bytes[]', - 'bytes[]', - ], - [ids, upkeeps, admins, checkDatas, triggerConfigs, offchainConfigs], - ) -} - async function deployRegistry1_2(): Promise<[BigNumber, KeeperRegistry1_2]> { const keeperRegistryFactory = await ethers.getContractFactory( 'KeeperRegistry1_2', @@ -266,7 +234,7 @@ async function deployRegistry2_0(): Promise<[BigNumber, KeeperRegistry2_0]> { signerAddresses, keeperAddresses, f, - encodeConfig(config), + encodeConfig20(config), offchainVersion, offchainBytes, ) @@ -500,47 +468,29 @@ describe('UpkeepTranscoder4_0', () => { ) }) - context('when from and to versions are correct', () => { - it('transcodes v1.2 upkeeps to v2.1 properly, regardless of toVersion value', async () => { - const data = await transcoder.transcodeUpkeeps( + context('when from version is correct', () => { + // note this is a bugfix - the "to" version should be accounted for in + // future versions of the transcoder + it('transcodes to v2.1, regardless of toVersion value', async () => { + const data1 = await transcoder.transcodeUpkeeps( UpkeepFormat.V12, UpkeepFormat.V12, encodeUpkeepV12(idx, upkeepsV12, ['0xabcd', '0xffff']), ) - assert.equal( - encodeUpkeepV21( - idx, - upkeepsV21, - admins, - ['0xabcd', '0xffff'], - ['0x', '0x'], - ['0x', '0x'], - ), - data, - ) - }) - - it('transcodes v1.3 upkeeps to v2.1 properly, regardless of toVersion value', async () => { - const data = await transcoder.transcodeUpkeeps( - UpkeepFormat.V13, + const data2 = await transcoder.transcodeUpkeeps( + UpkeepFormat.V12, UpkeepFormat.V13, - encodeUpkeepV13(idx, upkeepsV13, ['0xabcd', '0xffff']), + encodeUpkeepV12(idx, upkeepsV12, ['0xabcd', '0xffff']), ) - assert.equal( - encodeUpkeepV21( - idx, - upkeepsV21, - admins, - ['0xabcd', '0xffff'], - ['0x', '0x'], - ['0x', '0x'], - ), - data, + const data3 = await transcoder.transcodeUpkeeps( + UpkeepFormat.V12, + 100, + encodeUpkeepV12(idx, upkeepsV12, ['0xabcd', '0xffff']), ) + assert.equal(data1, data2) + assert.equal(data1, data3) }) - // DEV cannot test raw transcoding 2.0 => 2.1 because transcodeUpkeeps is not pure - it('migrates upkeeps from 1.2 registry to 2.1', async () => { await linkToken .connect(owner) diff --git a/contracts/test/v0.8/automation/helpers.ts b/contracts/test/v0.8/automation/helpers.ts index 7abca064978..888987c0bc7 100644 --- a/contracts/test/v0.8/automation/helpers.ts +++ b/contracts/test/v0.8/automation/helpers.ts @@ -4,9 +4,18 @@ import { KeeperRegistryLogicB2_1__factory as KeeperRegistryLogicBFactory } from import { IKeeperRegistryMaster as IKeeperRegistry } from '../../../typechain/IKeeperRegistryMaster' import { IKeeperRegistryMaster__factory as IKeeperRegistryMasterFactory } from '../../../typechain/factories/IKeeperRegistryMaster__factory' +export const setConfigRaw = + 'setConfig(address[],address[],uint8,bytes,uint64,bytes)' + +export const setConfigExplicit = + 'setConfig(address[],address[],uint8,(uint32,uint32,uint32,uint24,uint16,uint96,uint32,uint32,uint32,uint32,uint256,uint256,address,address[],address),uint64,bytes)' + export const deployRegistry21 = async ( from: Signer, - ...params: Parameters + mode: Parameters[0], + link: Parameters[1], + linkNative: Parameters[2], + fastgas: Parameters[3], ): Promise => { const logicBFactory = await ethers.getContractFactory( 'KeeperRegistryLogicB2_1', @@ -15,7 +24,13 @@ export const deployRegistry21 = async ( 'KeeperRegistryLogicA2_1', ) const registryFactory = await ethers.getContractFactory('KeeperRegistry2_1') - const logicB = await logicBFactory.connect(from).deploy(...params) + const forwarderLogicFactory = await ethers.getContractFactory( + 'AutomationForwarderLogic', + ) + const forwarderLogic = await forwarderLogicFactory.connect(from).deploy() + const logicB = await logicBFactory + .connect(from) + .deploy(mode, link, linkNative, fastgas, forwarderLogic.address) const logicA = await logicAFactory.connect(from).deploy(logicB.address) const master = await registryFactory.connect(from).deploy(logicA.address) return IKeeperRegistryMasterFactory.connect(master.address, from) diff --git a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go index 42181724edd..527e193569b 100644 --- a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go +++ b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var IKeeperRegistryMasterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var IKeeperRegistryMasterABI = IKeeperRegistryMasterMetaData.ABI @@ -262,6 +262,28 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetAdminPrivil return _IKeeperRegistryMaster.Contract.GetAdminPrivilegeConfig(&_IKeeperRegistryMaster.CallOpts, admin) } +func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) GetAutomationForwarderLogic(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _IKeeperRegistryMaster.contract.Call(opts, &out, "getAutomationForwarderLogic") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) GetAutomationForwarderLogic() (common.Address, error) { + return _IKeeperRegistryMaster.Contract.GetAutomationForwarderLogic(&_IKeeperRegistryMaster.CallOpts) +} + +func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetAutomationForwarderLogic() (common.Address, error) { + return _IKeeperRegistryMaster.Contract.GetAutomationForwarderLogic(&_IKeeperRegistryMaster.CallOpts) +} + func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) GetBalance(opts *bind.CallOpts, id *big.Int) (*big.Int, error) { var out []interface{} err := _IKeeperRegistryMaster.contract.Call(opts, &out, "getBalance", id) @@ -5839,6 +5861,8 @@ type IKeeperRegistryMasterInterface interface { GetAdminPrivilegeConfig(opts *bind.CallOpts, admin common.Address) ([]byte, error) + GetAutomationForwarderLogic(opts *bind.CallOpts) (common.Address, error) + GetBalance(opts *bind.CallOpts, id *big.Int) (*big.Int, error) GetCancellationDelay(opts *bind.CallOpts) (*big.Int, error) diff --git a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go index 710ac46d9cc..edd51a155ff 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go @@ -32,7 +32,7 @@ var ( var KeeperRegistryLogicAMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101206040523480156200001257600080fd5b506040516200629c3803806200629c833981016040819052620000359162000374565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b91906200039b565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000100919062000374565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000165919062000374565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca919062000374565b3380600081620002215760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000254576200025481620002b0565b5050508360028111156200026c576200026c620003be565b60e0816002811115620002835762000283620003be565b9052506001600160a01b0392831660805290821660a052811660c052919091166101005250620003d49050565b336001600160a01b038216036200030a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000218565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200037157600080fd5b50565b6000602082840312156200038757600080fd5b815162000394816200035b565b9392505050565b600060208284031215620003ae57600080fd5b8151600381106200039457600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051615e606200043c6000396000818161010e01526101a90152600081816134db01528181613711015281816139590152613b010152600061308501526000613169015260008181611d1301526122e60152615e606000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806385c1b0ba11620000a5578063c8048022116200006f578063c804802214620002b7578063ce7dc5b414620002ce578063f2fde38b14620002e5578063f7d334ba14620002fc576200010c565b806385c1b0ba14620002535780638da5cb5b146200026a5780638e86139b1462000289578063948108f714620002a0576200010c565b80634ee88d3511620000e75780634ee88d3514620001ef5780636ded9eae146200020657806371791aa0146200021d57806379ba50971462000249576200010c565b806328f32f38146200015457806329c5efad146200017e578063349e8cca14620001a7575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e8080156200014d573d6000f35b3d6000fd5b005b6200016b6200016536600462004175565b62000313565b6040519081526020015b60405180910390f35b620001956200018f3660046200425b565b62000636565b60405162000175949392919062004383565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000175565b6200015262000200366004620043c0565b62000878565b6200016b6200021736600462004410565b620008e0565b620002346200022e3660046200425b565b62000946565b604051620001759796959493929190620044c3565b6200015262001020565b620001526200026436600462004515565b62001123565b60005473ffffffffffffffffffffffffffffffffffffffff16620001c9565b620001526200029a366004620045a2565b62001d94565b62000152620002b136600462004605565b62002114565b62000152620002c836600462004634565b620023b6565b62000195620002df3660046200470a565b6200278c565b62000152620002f636600462004781565b6200285c565b620002346200030d36600462004634565b62002874565b6000805473ffffffffffffffffffffffffffffffffffffffff16331480159062000347575062000345600933620028b2565b155b156200037f576040517fd48b678b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6200038a86620028e6565b90506000818a306040516200039f9062003f1f565b92835273ffffffffffffffffffffffffffffffffffffffff9182166020840152166040820152606001604051809103906000f080158015620003e5573d6000803e3d6000fd5b509050620004c9826040518061010001604052806000151581526020018c63ffffffff16815260200163ffffffff801681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff168152602001600063ffffffff1681526020018d73ffffffffffffffffffffffffffffffffffffffff168152508a89898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915062002a8a9050565b6014805474010000000000000000000000000000000000000000900463ffffffff169080620004f883620047d0565b91906101000a81548163ffffffff021916908363ffffffff16021790555050817fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d0128a8a6040516200057192919063ffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2817fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8787604051620005ad9291906200483f565b60405180910390a2817f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d566485604051620005e7919062004855565b60405180910390a2817f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508460405162000621919062004855565b60405180910390a25098975050505050505050565b600060606000806200064762002ec3565b60008681526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff91810482169483019490945265010000000000840481169482019490945273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009093048316606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490931660c0840152600201541660e08201525a60e0820151601454604051929450600092839273ffffffffffffffffffffffffffffffffffffffff16916c01000000000000000000000000900463ffffffff169062000767908b906200486a565b60006040518083038160008787f1925050503d8060008114620007a7576040519150601f19603f3d011682016040523d82523d6000602084013e620007ac565b606091505b50915091505a620007be908562004888565b935081620007e95760006040518060200160405280600081525060079650965096505050506200086f565b80806020019051810190620007ff9190620048f9565b9097509550866200082d5760006040518060200160405280600081525060049650965096505050506200086f565b601554865164010000000090910463ffffffff1610156200086b5760006040518060200160405280600081525060059650965096505050506200086f565b5050505b92959194509250565b620008838362002efe565b6000838152601a602052604090206200089e828483620049ee565b50827f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d56648383604051620008d39291906200483f565b60405180910390a2505050565b60006200093a88888860008989604051806020016040528060008152508a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506200031392505050565b98975050505050505050565b6000606060008060008060006200095c62002ec3565b6000620009698a62002fb4565b905060006012604051806101200160405290816000820160009054906101000a900460ff1660ff1660ff1681526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900462ffffff1662ffffff1662ffffff16815260200160008201600c9054906101000a900461ffff1661ffff1661ffff16815260200160008201600e9054906101000a900460ff1615151515815260200160008201600f9054906101000a900460ff161515151581526020016000820160109054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090506000600460008d8152602001908152602001600020604051806101000160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160018201600c9054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020016001820160189054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016002820160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152505090508160a001511562000ce4576000604051806020016040528060008152506009600084602001516000808263ffffffff169250995099509950995099509950995050505062001014565b604081015163ffffffff9081161462000d35576000604051806020016040528060008152506001600084602001516000808263ffffffff169250995099509950995099509950995050505062001014565b80511562000d7b576000604051806020016040528060008152506002600084602001516000808263ffffffff169250995099509950995099509950995050505062001014565b62000d868262003062565b602083015160155492975090955060009162000db8918591879190640100000000900463ffffffff168a8a8762003254565b9050806bffffffffffffffffffffffff168260a001516bffffffffffffffffffffffff16101562000e22576000604051806020016040528060008152506006600085602001516000808263ffffffff1692509a509a509a509a509a509a509a505050505062001014565b600062000e318e868f620032a5565b90505a60e0840151601454604051929b50600092839273ffffffffffffffffffffffffffffffffffffffff16916c01000000000000000000000000900463ffffffff169062000e829086906200486a565b60006040518083038160008787f1925050503d806000811462000ec2576040519150601f19603f3d011682016040523d82523d6000602084013e62000ec7565b606091505b50915091505a62000ed9908c62004888565b9a508162000f595760155481516801000000000000000090910463ffffffff16101562000f3657505060408051602080820190925260008082529490910151939c509a50600899505063ffffffff90911695506200101492505050565b602090940151939b5060039a505063ffffffff9092169650620010149350505050565b8080602001905181019062000f6f9190620048f9565b909e509c508d62000fb057505060408051602080820190925260008082529490910151939c509a50600499505063ffffffff90911695506200101492505050565b6015548d5164010000000090910463ffffffff1610156200100157505060408051602080820190925260008082529490910151939c509a50600599505063ffffffff90911695506200101492505050565b505050506020015163ffffffff16945050505b92959891949750929550565b60015473ffffffffffffffffffffffffffffffffffffffff163314620010a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600173ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff16600381111562001162576200116262004318565b14158015620011ae5750600373ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff166003811115620011ab57620011ab62004318565b14155b15620011e6576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1662001246576040517fd12d7d8d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082900362001282576040517f2c2fc94100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805161010081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526000808567ffffffffffffffff811115620012e157620012e162004022565b6040519080825280602002602001820160405280156200130b578160200160208202803683370190505b50905060008667ffffffffffffffff8111156200132c576200132c62004022565b604051908082528060200260200182016040528015620013bb57816020015b604080516101008101825260008082526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816200134b5790505b50905060008767ffffffffffffffff811115620013dc57620013dc62004022565b6040519080825280602002602001820160405280156200141157816020015b6060815260200190600190039081620013fb5790505b50905060008867ffffffffffffffff81111562001432576200143262004022565b6040519080825280602002602001820160405280156200146757816020015b6060815260200190600190039081620014515790505b50905060008967ffffffffffffffff81111562001488576200148862004022565b604051908082528060200260200182016040528015620014bd57816020015b6060815260200190600190039081620014a75790505b50905060005b8a81101562001ad8578b8b82818110620014e157620014e162004b16565b6020908102929092013560008181526004845260409081902081516101008082018452825460ff81161515835263ffffffff91810482169783019790975265010000000000870481169382019390935273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009096048616606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490921660c08301526002015490931660e08401529a50909850620015cd90508962002efe565b60608801516040517f1a5da6c800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c8116600483015290911690631a5da6c890602401600060405180830381600087803b1580156200163d57600080fd5b505af115801562001652573d6000803e3d6000fd5b50505050878582815181106200166c576200166c62004b16565b6020026020010181905250600560008a815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868281518110620016c057620016c062004b16565b73ffffffffffffffffffffffffffffffffffffffff90921660209283029190910182015260008a81526007909152604090208054620016ff9062004946565b80601f01602080910402602001604051908101604052809291908181526020018280546200172d9062004946565b80156200177e5780601f1062001752576101008083540402835291602001916200177e565b820191906000526020600020905b8154815290600101906020018083116200176057829003601f168201915b505050505084828151811062001798576200179862004b16565b6020026020010181905250601a60008a81526020019081526020016000208054620017c39062004946565b80601f0160208091040260200160405190810160405280929190818152602001828054620017f19062004946565b8015620018425780601f10620018165761010080835404028352916020019162001842565b820191906000526020600020905b8154815290600101906020018083116200182457829003601f168201915b50505050508382815181106200185c576200185c62004b16565b6020026020010181905250601b60008a81526020019081526020016000208054620018879062004946565b80601f0160208091040260200160405190810160405280929190818152602001828054620018b59062004946565b8015620019065780601f10620018da5761010080835404028352916020019162001906565b820191906000526020600020905b815481529060010190602001808311620018e857829003601f168201915b505050505082828151811062001920576200192062004b16565b60200260200101819052508760a001516bffffffffffffffffffffffff16876200194b919062004b45565b60008a815260046020908152604080832080547fffffff00000000000000000000000000000000000000000000000000000000001681556001810180547fffffffff0000000000000000000000000000000000000000000000000000000016905560020180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560079091528120919850620019eb919062003f2d565b6000898152601a6020526040812062001a049162003f2d565b6000898152601b6020526040812062001a1d9162003f2d565b600089815260066020526040902080547fffffffffffffffffffffffff000000000000000000000000000000000000000016905562001a5e60028a620034c7565b5060a0880151604080516bffffffffffffffffffffffff909216825273ffffffffffffffffffffffffffffffffffffffff8c1660208301528a917fb38647142fbb1ea4c000fc4569b37a4e9a9f6313317b84ee3e5326c1a6cd06ff910160405180910390a28062001acf8162004b5b565b915050620014c3565b508560185462001ae9919062004888565b60185560405160009062001b0e908d908d9088908a9089908990899060200162004c42565b60405160208183030381529060405290508973ffffffffffffffffffffffffffffffffffffffff16638e86139b6013600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c71249ab60038e73ffffffffffffffffffffffffffffffffffffffff1663aab9edd66040518163ffffffff1660e01b8152600401602060405180830381865afa15801562001bca573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001bf0919062004dbc565b866040518463ffffffff1660e01b815260040162001c119392919062004de1565b600060405180830381865afa15801562001c2f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405262001c77919081019062004e08565b6040518263ffffffff1660e01b815260040162001c95919062004855565b600060405180830381600087803b15801562001cb057600080fd5b505af115801562001cc5573d6000803e3d6000fd5b50506040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d81166004830152602482018b90527f000000000000000000000000000000000000000000000000000000000000000016925063a9059cbb91506044016020604051808303816000875af115801562001d5f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001d85919062004e41565b50505050505050505050505050565b60023360009081526019602052604090205460ff16600381111562001dbd5762001dbd62004318565b1415801562001df3575060033360009081526019602052604090205460ff16600381111562001df05762001df062004318565b14155b1562001e2b576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808080808062001e408789018962005041565b95509550955095509550955060005b86518110156200210957600073ffffffffffffffffffffffffffffffffffffffff1686828151811062001e865762001e8662004b16565b60200260200101516060015173ffffffffffffffffffffffffffffffffffffffff160362001f965786818151811062001ec35762001ec362004b16565b602002602001015186828151811062001ee05762001ee062004b16565b602002602001015160e001513060405162001efb9062003f1f565b92835273ffffffffffffffffffffffffffffffffffffffff9182166020840152166040820152606001604051809103906000f08015801562001f41573d6000803e3d6000fd5b5086828151811062001f575762001f5762004b16565b60200260200101516060019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505b6200204e87828151811062001faf5762001faf62004b16565b602002602001015187838151811062001fcc5762001fcc62004b16565b602002602001015187848151811062001fe95762001fe962004b16565b602002602001015187858151811062002006576200200662004b16565b602002602001015187868151811062002023576200202362004b16565b602002602001015187878151811062002040576200204062004b16565b602002602001015162002a8a565b86818151811062002063576200206362004b16565b60200260200101517f74931a144e43a50694897f241d973aecb5024c0e910f9bb80a163ea3c1cf5a71878381518110620020a157620020a162004b16565b602002602001015160a0015133604051620020ec9291906bffffffffffffffffffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a280620021008162004b5b565b91505062001e4f565b505050505050505050565b60008281526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff918104821694830194909452650100000000008404811694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009094048416606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490921660e083015290911462002221576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160a0015162002233919062005149565b600084815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff938416021790556018546200229b9184169062004b45565b6018556040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526bffffffffffffffffffffffff831660448201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906323b872dd906064016020604051808303816000875af115801562002345573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200236b919062004e41565b506040516bffffffffffffffffffffffff83168152339084907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a3505050565b600081815260046020908152604080832081516101008082018452825460ff81161515835263ffffffff918104821695830195909552650100000000008504811693820184905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009095048516606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490931660e0840152919291141590620024ae60005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16149050818015620025095750808015620025075750620024fa620034d5565b836040015163ffffffff16115b155b1562002541576040517ffbc0357800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8015801562002574575060008481526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314155b15620025ac576040517ffbdb8e5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000620025b8620034d5565b905081620025d057620025cd60328262004b45565b90505b6000858152600460205260409020805463ffffffff80841665010000000000027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff909216919091179091556200262c906002908790620034c716565b5060135460808501516bffffffffffffffffffffffff91821691600091168211156200269557608086015162002663908362005171565b90508560a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111562002695575060a08501515b808660a00151620026a7919062005171565b600088815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff938416021790556014546200270f9183911662005149565b601480547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9290921691909117905560405167ffffffffffffffff84169088907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a350505050505050565b600060606000806200279d62002ec3565b6000634b56a42e60e01b888888604051602401620027be9392919062005199565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152905062002849898262000636565b929c919b50995090975095505050505050565b6200286662003591565b620028718162003614565b50565b6000606060008060008060006200289b886040518060200160405280600081525062000946565b959e949d50929b5090995097509550909350915050565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b90505b92915050565b60008060006200290d6001620028fb620034d5565b62002907919062004888565b6200370b565b601454604080516020810193909352309083015274010000000000000000000000000000000000000000900463ffffffff166060820152608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201209083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060045b600f81101562002a195782828281518110620029d557620029d562004b16565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508062002a108162004b5b565b915050620029b5565b5083600181111562002a2f5762002a2f62004318565b60f81b81600f8151811062002a485762002a4862004b16565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535062002a8281620051cd565b949350505050565b6012546e010000000000000000000000000000900460ff161562002ada576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e085015173ffffffffffffffffffffffffffffffffffffffff163b62002b2d576040517f09ee12d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601554835163ffffffff909116101562002b73576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108fc856020015163ffffffff16108062002bb15750601454602086015163ffffffff70010000000000000000000000000000000090920482169116115b1562002be9576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008681526004602052604090206002015473ffffffffffffffffffffffffffffffffffffffff161562002c49576040517f6e3b930b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600086815260046020908152604080832088518154848b0151848c015160608d015173ffffffffffffffffffffffffffffffffffffffff9081166901000000000000000000027fffffff0000000000000000000000000000000000000000ffffffffffffffffff63ffffffff9384166501000000000002167fffffff000000000000000000000000000000000000000000000000ffffffffff948416610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff971515979097167fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009096169590951795909517929092169290921792909217835560808b015160018401805460a08e015160c08f01519094167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff6bffffffffffffffffffffffff9586166c01000000000000000000000000027fffffffffffffffff0000000000000000000000000000000000000000000000009093169590941694909417179190911691909117905560e08a0151600290920180549282167fffffffffffffffffffffffff0000000000000000000000000000000000000000938416179055600584528285208054918a16919092161790556007909152902062002e51848262005210565b508460a001516bffffffffffffffffffffffff1660185462002e74919062004b45565b6018556000868152601a6020526040902062002e91838262005210565b506000868152601b6020526040902062002eac828262005210565b5062002eba60028762003873565b50505050505050565b321562002efc576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff16331462002f5c576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff9081161462002871576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f81101562003049577fff00000000000000000000000000000000000000000000000000000000000000821683826020811062002ffd5762002ffd62004b16565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146200303457506000949350505050565b80620030408162004b5b565b91505062002fbb565b5081600f1a600181111562002a825762002a8262004318565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015620030ef573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003115919062005352565b50945090925050506000811315806200312d57508142105b8062003152575082801562003152575062003149824262004888565b8463ffffffff16105b156200316357601654955062003167565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015620031d3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620031f9919062005352565b50945090925050506000811315806200321157508142105b806200323657508280156200323657506200322d824262004888565b8463ffffffff16105b15620032475760175494506200324b565b8094505b50505050915091565b6000806200326888878b6000015162003881565b9050600080620032858b8a63ffffffff16858a8a60018b62003920565b909250905062003296818362005149565b9b9a5050505050505050505050565b60606000836001811115620032be57620032be62004318565b036200338b576000848152600760205260409081902090517f6e04ff0d000000000000000000000000000000000000000000000000000000009162003306916024016200544a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091529050620034c0565b6001836001811115620033a257620033a262004318565b036200348e57600082806020019051810190620033c09190620054ce565b6000868152600760205260409081902090519192507f40691db4000000000000000000000000000000000000000000000000000000009162003407918491602401620055e2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091529150620034c09050565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b6000620028dd838362003dc2565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156200350e576200350e62004318565b036200358c57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003561573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620035879190620056aa565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331462002efc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016200109e565b3373ffffffffffffffffffffffffffffffffffffffff82160362003695576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200109e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111562003744576200374462004318565b0362003869576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003799573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620037bf9190620056aa565b90508083101580620037dd5750610100620037db848362004888565b115b15620037ec5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa15801562003843573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620034c09190620056aa565b504090565b919050565b6000620028dd838362003ecd565b600080808560018111156200389a576200389a62004318565b03620038ab575062015f90620038ce565b6001856001811115620038c257620038c262004318565b036200348e57506201adb05b620038e163ffffffff85166014620056c4565b620038ee84600162005704565b620038ff9060ff16611d4c620056c4565b6200390b908362004b45565b62003917919062004b45565b95945050505050565b6000806000896080015161ffff16876200393b9190620056c4565b90508380156200394a5750803a105b156200395357503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156200398c576200398c62004318565b0362003afd576040805160008152602081019091528515620039f05760003660405180608001604052806048815260200162005e0c60489139604051602001620039d99392919062005720565b604051602081830303815290604052905062003a5e565b60155462003a0e90640100000000900463ffffffff16600462005749565b63ffffffff1667ffffffffffffffff81111562003a2f5762003a2f62004022565b6040519080825280601f01601f19166020018201604052801562003a5a576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9062003ab090849060040162004855565b602060405180830381865afa15801562003ace573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003af49190620056aa565b91505062003c67565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111562003b345762003b3462004318565b0362003c6757841562003bbc57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003b8e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003bb49190620056aa565b905062003c67565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801562003c0b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c31919062005778565b505060155492945062003c5693505050640100000000900463ffffffff1682620056c4565b62003c63906010620056c4565b9150505b8462003c8657808b6080015161ffff1662003c839190620056c4565b90505b62003c9661ffff871682620057c3565b90506000878262003ca88c8e62004b45565b62003cb49086620056c4565b62003cc0919062004b45565b62003cd490670de0b6b3a7640000620056c4565b62003ce09190620057c3565b905060008c6040015163ffffffff1664e8d4a5100062003d019190620056c4565b898e6020015163ffffffff16858f8862003d1c9190620056c4565b62003d28919062004b45565b62003d3890633b9aca00620056c4565b62003d449190620056c4565b62003d509190620057c3565b62003d5c919062004b45565b90506b033b2e3c9fd0803ce800000062003d77828462004b45565b111562003db0576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000818152600183016020526040812054801562003ebb57600062003de960018362004888565b855490915060009062003dff9060019062004888565b905081811462003e6b57600086600001828154811062003e235762003e2362004b16565b906000526020600020015490508087600001848154811062003e495762003e4962004b16565b6000918252602080832090910192909255918252600188019052604090208390555b855486908062003e7f5762003e7f620057ff565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050620028e0565b6000915050620028e0565b5092915050565b600081815260018301602052604081205462003f1657508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155620028e0565b506000620028e0565b6105dd806200582f83390190565b50805462003f3b9062004946565b6000825580601f1062003f4c575050565b601f0160209004906000526020600020908101906200287191905b8082111562003f7d576000815560010162003f67565b5090565b73ffffffffffffffffffffffffffffffffffffffff811681146200287157600080fd5b80356200386e8162003f81565b803563ffffffff811681146200386e57600080fd5b8035600281106200386e57600080fd5b60008083601f84011262003fe957600080fd5b50813567ffffffffffffffff8111156200400257600080fd5b6020830191508360208285010111156200401b57600080fd5b9250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610100810167ffffffffffffffff8111828210171562004078576200407862004022565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715620040c857620040c862004022565b604052919050565b600067ffffffffffffffff821115620040ed57620040ed62004022565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f8301126200412b57600080fd5b8135620041426200413c82620040d0565b6200407e565b8181528460208386010111156200415857600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060e0898b0312156200419257600080fd5b88356200419f8162003f81565b9750620041af60208a0162003fb1565b96506040890135620041c18162003f81565b9550620041d160608a0162003fc6565b9450608089013567ffffffffffffffff80821115620041ef57600080fd5b620041fd8c838d0162003fd6565b909650945060a08b01359150808211156200421757600080fd5b620042258c838d0162004119565b935060c08b01359150808211156200423c57600080fd5b506200424b8b828c0162004119565b9150509295985092959890939650565b600080604083850312156200426f57600080fd5b82359150602083013567ffffffffffffffff8111156200428e57600080fd5b6200429c8582860162004119565b9150509250929050565b60005b83811015620042c3578181015183820152602001620042a9565b50506000910152565b60008151808452620042e6816020860160208601620042a6565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600a81106200437f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b8415158152608060208201526000620043a06080830186620042cc565b9050620043b1604083018562004347565b82606083015295945050505050565b600080600060408486031215620043d657600080fd5b83359250602084013567ffffffffffffffff811115620043f557600080fd5b620044038682870162003fd6565b9497909650939450505050565b600080600080600080600060a0888a0312156200442c57600080fd5b8735620044398162003f81565b9650620044496020890162003fb1565b955060408801356200445b8162003f81565b9450606088013567ffffffffffffffff808211156200447957600080fd5b620044878b838c0162003fd6565b909650945060808a0135915080821115620044a157600080fd5b50620044b08a828b0162003fd6565b989b979a50959850939692959293505050565b871515815260e060208201526000620044e060e0830189620042cc565b9050620044f1604083018862004347565b8560608301528460808301528360a08301528260c083015298975050505050505050565b6000806000604084860312156200452b57600080fd5b833567ffffffffffffffff808211156200454457600080fd5b818601915086601f8301126200455957600080fd5b8135818111156200456957600080fd5b8760208260051b85010111156200457f57600080fd5b60209283019550935050840135620045978162003f81565b809150509250925092565b60008060208385031215620045b657600080fd5b823567ffffffffffffffff811115620045ce57600080fd5b620045dc8582860162003fd6565b90969095509350505050565b80356bffffffffffffffffffffffff811681146200386e57600080fd5b600080604083850312156200461957600080fd5b823591506200462b60208401620045e8565b90509250929050565b6000602082840312156200464757600080fd5b5035919050565b600067ffffffffffffffff8211156200466b576200466b62004022565b5060051b60200190565b600082601f8301126200468757600080fd5b813560206200469a6200413c836200464e565b82815260059290921b84018101918181019086841115620046ba57600080fd5b8286015b84811015620046ff57803567ffffffffffffffff811115620046e05760008081fd5b620046f08986838b010162004119565b845250918301918301620046be565b509695505050505050565b600080600080606085870312156200472157600080fd5b84359350602085013567ffffffffffffffff808211156200474157600080fd5b6200474f8883890162004675565b945060408701359150808211156200476657600080fd5b50620047758782880162003fd6565b95989497509550505050565b6000602082840312156200479457600080fd5b8135620034c08162003f81565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff808316818103620047ec57620047ec620047a1565b6001019392505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60208152600062002a82602083018486620047f6565b602081526000620028dd6020830184620042cc565b600082516200487e818460208701620042a6565b9190910192915050565b81810381811115620028e057620028e0620047a1565b80151581146200287157600080fd5b600082601f830112620048bf57600080fd5b8151620048d06200413c82620040d0565b818152846020838601011115620048e657600080fd5b62002a82826020830160208701620042a6565b600080604083850312156200490d57600080fd5b82516200491a816200489e565b602084015190925067ffffffffffffffff8111156200493857600080fd5b6200429c85828601620048ad565b600181811c908216806200495b57607f821691505b60208210810362004995577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115620049e957600081815260208120601f850160051c81016020861015620049c45750805b601f850160051c820191505b81811015620049e557828155600101620049d0565b5050505b505050565b67ffffffffffffffff83111562004a095762004a0962004022565b62004a218362004a1a835462004946565b836200499b565b6000601f84116001811462004a76576000851562004a3f5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835562004b0f565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101562004ac7578685013582556020948501946001909201910162004aa5565b508682101562004b03577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b80820180821115620028e057620028e0620047a1565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362004b8f5762004b8f620047a1565b5060010190565b600081518084526020808501945080840160005b8381101562004bde57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010162004baa565b509495945050505050565b600081518084526020808501808196508360051b8101915082860160005b8581101562004c3557828403895262004c22848351620042cc565b9885019893509084019060010162004c07565b5091979650505050505050565b600060c0808352888184015260e07f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8a111562004c7e57600080fd5b8960051b808c83870137840184810382016020808701919091528a518383018190528b82019261010092919083019060005b8181101562004d515785518051151584528481015163ffffffff9081168686015260408083015182169086015260608083015173ffffffffffffffffffffffffffffffffffffffff908116918701919091526080808401516bffffffffffffffffffffffff9081169188019190915260a080850151909116908701528a8301519091168a860152908801511687840152948301949184019160010162004cb0565b5050878103604089015262004d67818d62004b96565b95505050505050828103606084015262004d82818762004be9565b9050828103608084015262004d98818662004be9565b905082810360a084015262004dae818562004be9565b9a9950505050505050505050565b60006020828403121562004dcf57600080fd5b815160ff81168114620034c057600080fd5b60ff8416815260ff83166020820152606060408201526000620039176060830184620042cc565b60006020828403121562004e1b57600080fd5b815167ffffffffffffffff81111562004e3357600080fd5b62002a8284828501620048ad565b60006020828403121562004e5457600080fd5b8151620034c0816200489e565b600082601f83011262004e7357600080fd5b8135602062004e866200413c836200464e565b82815260059290921b8401810191818101908684111562004ea657600080fd5b8286015b84811015620046ff578035835291830191830162004eaa565b600082601f83011262004ed557600080fd5b8135602062004ee86200413c836200464e565b82815260089290921b8401810191818101908684111562004f0857600080fd5b8286015b84811015620046ff57610100818903121562004f285760008081fd5b62004f3262004051565b813562004f3f816200489e565b815262004f4e82860162003fb1565b85820152604062004f6181840162003fb1565b90820152606062004f7483820162003fa4565b90820152608062004f87838201620045e8565b9082015260a062004f9a838201620045e8565b9082015260c062004fad83820162003fb1565b9082015260e062004fc083820162003fa4565b908201528352918301916101000162004f0c565b600082601f83011262004fe657600080fd5b8135602062004ff96200413c836200464e565b82815260059290921b840181019181810190868411156200501957600080fd5b8286015b84811015620046ff578035620050338162003f81565b83529183019183016200501d565b60008060008060008060c087890312156200505b57600080fd5b863567ffffffffffffffff808211156200507457600080fd5b620050828a838b0162004e61565b975060208901359150808211156200509957600080fd5b620050a78a838b0162004ec3565b96506040890135915080821115620050be57600080fd5b620050cc8a838b0162004fd4565b95506060890135915080821115620050e357600080fd5b620050f18a838b0162004675565b945060808901359150808211156200510857600080fd5b620051168a838b0162004675565b935060a08901359150808211156200512d57600080fd5b506200513c89828a0162004675565b9150509295509295509295565b6bffffffffffffffffffffffff81811683821601908082111562003ec65762003ec6620047a1565b6bffffffffffffffffffffffff82811682821603908082111562003ec65762003ec6620047a1565b604081526000620051ae604083018662004be9565b8281036020840152620051c3818587620047f6565b9695505050505050565b8051602080830151919081101562004995577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60209190910360031b1b16919050565b815167ffffffffffffffff8111156200522d576200522d62004022565b62005245816200523e845462004946565b846200499b565b602080601f8311600181146200529b5760008415620052645750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555620049e5565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015620052ea57888601518255948401946001909101908401620052c9565b50858210156200532757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b805169ffffffffffffffffffff811681146200386e57600080fd5b600080600080600060a086880312156200536b57600080fd5b620053768662005337565b94506020860151935060408601519250606086015191506200539b6080870162005337565b90509295509295909350565b60008154620053b68162004946565b808552602060018381168015620053d657600181146200540f576200543f565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b89010195506200543f565b866000528260002060005b85811015620054375781548a82018601529083019084016200541a565b890184019650505b505050505092915050565b602081526000620028dd6020830184620053a7565b80516200386e8162003f81565b600082601f8301126200547e57600080fd5b81516020620054916200413c836200464e565b82815260059290921b84018101918181019086841115620054b157600080fd5b8286015b84811015620046ff5780518352918301918301620054b5565b600060208284031215620054e157600080fd5b815167ffffffffffffffff80821115620054fa57600080fd5b9083019061010082860312156200551057600080fd5b6200551a62004051565b82518152602083015160208201526040830151604082015260608301516060820152608083015160808201526200555460a084016200545f565b60a082015260c0830151828111156200556c57600080fd5b6200557a878286016200546c565b60c08301525060e0830151828111156200559357600080fd5b620055a187828601620048ad565b60e08301525095945050505050565b600081518084526020808501945080840160005b8381101562004bde57815187529582019590820190600101620055c4565b60408152825160408201526020830151606082015260408301516080820152606083015160a0820152608083015160c082015273ffffffffffffffffffffffffffffffffffffffff60a08401511660e0820152600060c084015161010080818501525062005655610140840182620055b0565b905060e08501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc084830301610120850152620056938282620042cc565b9150508281036020840152620039178185620053a7565b600060208284031215620056bd57600080fd5b5051919050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615620056ff57620056ff620047a1565b500290565b60ff8181168382160190811115620028e057620028e0620047a1565b8284823760008382016000815283516200573f818360208801620042a6565b0195945050505050565b600063ffffffff808316818516818304811182151516156200576f576200576f620047a1565b02949350505050565b60008060008060008060c087890312156200579257600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082620057fa577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe60c060405234801561001057600080fd5b506040516105dd3803806105dd83398101604081905261002f91610073565b600080546001600160a01b0319166001600160a01b039283161790551660805260a0526100af565b80516001600160a01b038116811461006e57600080fd5b919050565b60008060006060848603121561008857600080fd5b8351925061009860208501610057565b91506100a660408501610057565b90509250925092565b60805160a0516105026100db600039600061014c015260008181610177015261028901526105026000f3fe608060405234801561001057600080fd5b50600436106100725760003560e01c806379188d161161005057806379188d161461011d5780638ee489b214610147578063f00e6a2a1461017557600080fd5b8063181f5a77146100775780631a5da6c8146100c95780635ab1bd53146100de575b600080fd5b6100b36040518060400160405280601981526020017f4175746f6d6174696f6e466f7277617264657220312e302e300000000000000081525081565b6040516100c09190610304565b60405180910390f35b6100dc6100d7366004610370565b61019b565b005b60005473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100c0565b61013061012b3660046103dc565b610233565b6040805192151583526020830191909152016100c0565b6040517f000000000000000000000000000000000000000000000000000000000000000081526020016100c0565b7f00000000000000000000000000000000000000000000000000000000000000006100f8565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ec576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60008054819073ffffffffffffffffffffffffffffffffffffffff163314610287576040517fea8e4eb500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f00000000000000000000000000000000000000000000000000000000000000005a91505a6113888110156102bb57600080fd5b6113888103905085604082048203116102d357600080fd5b50803b6102df57600080fd5b6000808551602087016000858af192505a6102fa90836104b5565b9150509250929050565b600060208083528351808285015260005b8181101561033157858101830151858201604001528201610315565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60006020828403121561038257600080fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146103a657600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080604083850312156103ef57600080fd5b82359150602083013567ffffffffffffffff8082111561040e57600080fd5b818501915085601f83011261042257600080fd5b813581811115610434576104346103ad565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561047a5761047a6103ad565b8160405282815288602084870101111561049357600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b818103818111156104ef577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea164736f6c6343000810000a307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + Bin: "0x6101406040523480156200001257600080fd5b50604051620061d1380380620061d18339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051615d18620004b96000396000818161010e01526101a90152600081816103e10152611fa10152600081816135370152818161376d015281816139b50152613b5d015260006130e1015260006131c5015260008181611de301526123af0152615d186000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806385c1b0ba11620000a5578063c8048022116200006f578063c804802214620002b7578063ce7dc5b414620002ce578063f2fde38b14620002e5578063f7d334ba14620002fc576200010c565b806385c1b0ba14620002535780638da5cb5b146200026a5780638e86139b1462000289578063948108f714620002a0576200010c565b80634ee88d3511620000e75780634ee88d3514620001ef5780636ded9eae146200020657806371791aa0146200021d57806379ba50971462000249576200010c565b806328f32f38146200015457806329c5efad146200017e578063349e8cca14620001a7575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e8080156200014d573d6000f35b3d6000fd5b005b6200016b62000165366004620041ea565b62000313565b6040519081526020015b60405180910390f35b620001956200018f366004620042d0565b6200068c565b604051620001759493929190620043f8565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000175565b620001526200020036600462004435565b62000930565b6200016b6200021736600462004485565b62000998565b620002346200022e366004620042d0565b620009fe565b60405162000175979695949392919062004538565b62000152620010f0565b62000152620002643660046200458a565b620011f3565b60005473ffffffffffffffffffffffffffffffffffffffff16620001c9565b620001526200029a36600462004617565b62001e64565b62000152620002b13660046200467a565b620021ec565b62000152620002c8366004620046a9565b6200247f565b62000195620002df3660046200477f565b62002846565b62000152620002f6366004620047f6565b62002916565b620002346200030d366004620046a9565b6200292e565b6000805473ffffffffffffffffffffffffffffffffffffffff163314801590620003475750620003456009336200296c565b155b156200037f576040517fd48b678b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff89163b620003ce576040517f09ee12d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b620003d986620029a0565b9050600089307f00000000000000000000000000000000000000000000000000000000000000006040516200040e9062003f7b565b73ffffffffffffffffffffffffffffffffffffffff938416815291831660208301529091166040820152606001604051809103906000f08015801562000458573d6000803e3d6000fd5b5090506200051f826040518060e001604052806000151581526020018c63ffffffff16815260200163ffffffff801681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff168152602001600063ffffffff168152508a89898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915062002b449050565b6014805474010000000000000000000000000000000000000000900463ffffffff1690806200054e8362004845565b91906101000a81548163ffffffff021916908363ffffffff16021790555050817fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d0128a8a604051620005c792919063ffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2817fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d878760405162000603929190620048b4565b60405180910390a2817f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d5664856040516200063d9190620048ca565b60405180910390a2817f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf485084604051620006779190620048ca565b60405180910390a25098975050505050505050565b600060606000806200069d62002f1f565b600086815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff90811694830194909452650100000000008104841694820194909452690100000000000000000090930473ffffffffffffffffffffffffffffffffffffffff166060840152600101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a0840152780100000000000000000000000000000000000000000000000090041660c08201525a9150600080826060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620007b7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620007dd9190620048ec565b73ffffffffffffffffffffffffffffffffffffffff166013600101600c9054906101000a900463ffffffff1663ffffffff16896040516200081f91906200490c565b60006040518083038160008787f1925050503d80600081146200085f576040519150601f19603f3d011682016040523d82523d6000602084013e62000864565b606091505b50915091505a6200087690856200492a565b935081620008a157600060405180602001604052806000815250600796509650965050505062000927565b80806020019051810190620008b791906200499b565b909750955086620008e557600060405180602001604052806000815250600496509650965050505062000927565b601554865164010000000090910463ffffffff1610156200092357600060405180602001604052806000815250600596509650965050505062000927565b5050505b92959194509250565b6200093b8362002f5a565b6000838152601a602052604090206200095682848362004a90565b50827f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d566483836040516200098b929190620048b4565b60405180910390a2505050565b6000620009f288888860008989604051806020016040528060008152508a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506200031392505050565b98975050505050505050565b60006060600080600080600062000a1462002f1f565b600062000a218a62003010565b905060006012604051806101200160405290816000820160009054906101000a900460ff1660ff1660ff1681526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900462ffffff1662ffffff1662ffffff16815260200160008201600c9054906101000a900461ffff1661ffff1661ffff16815260200160008201600e9054906101000a900460ff1615151515815260200160008201600f9054906101000a900460ff161515151581526020016000820160109054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090506000600460008d81526020019081526020016000206040518060e00160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160018201600c9054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020016001820160189054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090508160a001511562000d45576000604051806020016040528060008152506009600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b604081015163ffffffff9081161462000d96576000604051806020016040528060008152506001600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b80511562000ddc576000604051806020016040528060008152506002600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b62000de782620030be565b602083015160155492975090955060009162000e19918591879190640100000000900463ffffffff168a8a87620032b0565b9050806bffffffffffffffffffffffff168260a001516bffffffffffffffffffffffff16101562000e83576000604051806020016040528060008152506006600085602001516000808263ffffffff1692509a509a509a509a509a509a509a5050505050620010e4565b600062000e928e868f62003301565b90505a9850600080846060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000eea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000f109190620048ec565b73ffffffffffffffffffffffffffffffffffffffff166013600101600c9054906101000a900463ffffffff1663ffffffff168460405162000f5291906200490c565b60006040518083038160008787f1925050503d806000811462000f92576040519150601f19603f3d011682016040523d82523d6000602084013e62000f97565b606091505b50915091505a62000fa9908c6200492a565b9a5081620010295760155481516801000000000000000090910463ffffffff1610156200100657505060408051602080820190925260008082529490910151939c509a50600899505063ffffffff9091169550620010e492505050565b602090940151939b5060039a505063ffffffff9092169650620010e49350505050565b808060200190518101906200103f91906200499b565b909e509c508d6200108057505060408051602080820190925260008082529490910151939c509a50600499505063ffffffff9091169550620010e492505050565b6015548d5164010000000090910463ffffffff161015620010d157505060408051602080820190925260008082529490910151939c509a50600599505063ffffffff9091169550620010e492505050565b505050506020015163ffffffff16945050505b92959891949750929550565b60015473ffffffffffffffffffffffffffffffffffffffff16331462001177576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600173ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff1660038111156200123257620012326200438d565b141580156200127e5750600373ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff1660038111156200127b576200127b6200438d565b14155b15620012b6576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1662001316576040517fd12d7d8d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082900362001352576040517f2c2fc94100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c081018290526000808567ffffffffffffffff811115620013a957620013a962004071565b604051908082528060200260200182016040528015620013d3578160200160208202803683370190505b50905060008667ffffffffffffffff811115620013f457620013f462004071565b6040519080825280602002602001820160405280156200147b57816020015b6040805160e08101825260008082526020808301829052928201819052606082018190526080820181905260a0820181905260c082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181620014135790505b50905060008767ffffffffffffffff8111156200149c576200149c62004071565b604051908082528060200260200182016040528015620014d157816020015b6060815260200190600190039081620014bb5790505b50905060008867ffffffffffffffff811115620014f257620014f262004071565b6040519080825280602002602001820160405280156200152757816020015b6060815260200190600190039081620015115790505b50905060008967ffffffffffffffff81111562001548576200154862004071565b6040519080825280602002602001820160405280156200157d57816020015b6060815260200190600190039081620015675790505b50905060005b8a81101562001b61578b8b82818110620015a157620015a162004bb8565b60209081029290920135600081815260048452604090819020815160e081018352815460ff811615158252610100810463ffffffff90811697830197909752650100000000008104871693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490931660c08401529a509098506200168090508962002f5a565b60608801516040517f1a5da6c800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c8116600483015290911690631a5da6c890602401600060405180830381600087803b158015620016f057600080fd5b505af115801562001705573d6000803e3d6000fd5b50505050878582815181106200171f576200171f62004bb8565b6020026020010181905250600560008a815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1686828151811062001773576200177362004bb8565b73ffffffffffffffffffffffffffffffffffffffff90921660209283029190910182015260008a81526007909152604090208054620017b290620049e8565b80601f0160208091040260200160405190810160405280929190818152602001828054620017e090620049e8565b8015620018315780601f10620018055761010080835404028352916020019162001831565b820191906000526020600020905b8154815290600101906020018083116200181357829003601f168201915b50505050508482815181106200184b576200184b62004bb8565b6020026020010181905250601a60008a815260200190815260200160002080546200187690620049e8565b80601f0160208091040260200160405190810160405280929190818152602001828054620018a490620049e8565b8015620018f55780601f10620018c957610100808354040283529160200191620018f5565b820191906000526020600020905b815481529060010190602001808311620018d757829003601f168201915b50505050508382815181106200190f576200190f62004bb8565b6020026020010181905250601b60008a815260200190815260200160002080546200193a90620049e8565b80601f01602080910402602001604051908101604052809291908181526020018280546200196890620049e8565b8015620019b95780601f106200198d57610100808354040283529160200191620019b9565b820191906000526020600020905b8154815290600101906020018083116200199b57829003601f168201915b5050505050828281518110620019d357620019d362004bb8565b60200260200101819052508760a001516bffffffffffffffffffffffff1687620019fe919062004be7565b60008a815260046020908152604080832080547fffffff000000000000000000000000000000000000000000000000000000000016815560010180547fffffffff000000000000000000000000000000000000000000000000000000001690556007909152812091985062001a74919062003f89565b6000898152601a6020526040812062001a8d9162003f89565b6000898152601b6020526040812062001aa69162003f89565b600089815260066020526040902080547fffffffffffffffffffffffff000000000000000000000000000000000000000016905562001ae760028a62003523565b5060a0880151604080516bffffffffffffffffffffffff909216825273ffffffffffffffffffffffffffffffffffffffff8c1660208301528a917fb38647142fbb1ea4c000fc4569b37a4e9a9f6313317b84ee3e5326c1a6cd06ff910160405180910390a28062001b588162004bfd565b91505062001583565b508560185462001b7291906200492a565b60185560008b8b868167ffffffffffffffff81111562001b965762001b9662004071565b60405190808252806020026020018201604052801562001bc0578160200160208202803683370190505b508988888860405160200162001bde98979695949392919062004da3565b60405160208183030381529060405290508973ffffffffffffffffffffffffffffffffffffffff16638e86139b6013600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c71249ab60038e73ffffffffffffffffffffffffffffffffffffffff1663aab9edd66040518163ffffffff1660e01b8152600401602060405180830381865afa15801562001c9a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001cc0919062004e73565b866040518463ffffffff1660e01b815260040162001ce19392919062004e98565b600060405180830381865afa15801562001cff573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405262001d47919081019062004ebf565b6040518263ffffffff1660e01b815260040162001d659190620048ca565b600060405180830381600087803b15801562001d8057600080fd5b505af115801562001d95573d6000803e3d6000fd5b50506040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d81166004830152602482018b90527f000000000000000000000000000000000000000000000000000000000000000016925063a9059cbb91506044016020604051808303816000875af115801562001e2f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001e55919062004ef8565b50505050505050505050505050565b60023360009081526019602052604090205460ff16600381111562001e8d5762001e8d6200438d565b1415801562001ec3575060033360009081526019602052604090205460ff16600381111562001ec05762001ec06200438d565b14155b1562001efb576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080808062001f11888a018a620050f0565b965096509650965096509650965060005b8751811015620021e057600073ffffffffffffffffffffffffffffffffffffffff1687828151811062001f595762001f5962004bb8565b60200260200101516060015173ffffffffffffffffffffffffffffffffffffffff16036200206d5785818151811062001f965762001f9662004bb8565b6020026020010151307f000000000000000000000000000000000000000000000000000000000000000060405162001fce9062003f7b565b73ffffffffffffffffffffffffffffffffffffffff938416815291831660208301529091166040820152606001604051809103906000f08015801562002018573d6000803e3d6000fd5b508782815181106200202e576200202e62004bb8565b60200260200101516060019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505b6200212588828151811062002086576200208662004bb8565b6020026020010151888381518110620020a357620020a362004bb8565b6020026020010151878481518110620020c057620020c062004bb8565b6020026020010151878581518110620020dd57620020dd62004bb8565b6020026020010151878681518110620020fa57620020fa62004bb8565b602002602001015187878151811062002117576200211762004bb8565b602002602001015162002b44565b8781815181106200213a576200213a62004bb8565b60200260200101517f74931a144e43a50694897f241d973aecb5024c0e910f9bb80a163ea3c1cf5a7188838151811062002178576200217862004bb8565b602002602001015160a0015133604051620021c39291906bffffffffffffffffffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a280620021d78162004bfd565b91505062001f22565b50505050505050505050565b600082815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c08201529114620022ea576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160a00151620022fc919062005221565b600084815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601854620023649184169062004be7565b6018556040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526bffffffffffffffffffffffff831660448201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906323b872dd906064016020604051808303816000875af11580156200240e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062002434919062004ef8565b506040516bffffffffffffffffffffffff83168152339084907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a3505050565b6000818152600460209081526040808320815160e081018352815460ff81161515825263ffffffff6101008204811695830195909552650100000000008104851693820184905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004831660c082015292911415906200256860005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16149050818015620025c35750808015620025c15750620025b462003531565b836040015163ffffffff16115b155b15620025fb576040517ffbc0357800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b801580156200262e575060008481526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314155b1562002666576040517ffbdb8e5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006200267262003531565b9050816200268a576200268760328262004be7565b90505b6000858152600460205260409020805463ffffffff80841665010000000000027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff90921691909117909155620026e69060029087906200352316565b5060135460808501516bffffffffffffffffffffffff91821691600091168211156200274f5760808601516200271d908362005249565b90508560a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff1611156200274f575060a08501515b808660a0015162002761919062005249565b600088815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601454620027c99183911662005221565b601480547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9290921691909117905560405167ffffffffffffffff84169088907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a350505050505050565b600060606000806200285762002f1f565b6000634b56a42e60e01b888888604051602401620028789392919062005271565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290506200290389826200068c565b929c919b50995090975095505050505050565b62002920620035ed565b6200292b8162003670565b50565b600060606000806000806000620029558860405180602001604052806000815250620009fe565b959e949d50929b5090995097509550909350915050565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b90505b92915050565b6000806000620029c76001620029b562003531565b620029c191906200492a565b62003767565b601454604080516020810193909352309083015274010000000000000000000000000000000000000000900463ffffffff166060820152608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201209083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060045b600f81101562002ad3578282828151811062002a8f5762002a8f62004bb8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508062002aca8162004bfd565b91505062002a6f565b5083600181111562002ae95762002ae96200438d565b60f81b81600f8151811062002b025762002b0262004bb8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535062002b3c81620052a5565b949350505050565b6012546e010000000000000000000000000000900460ff161562002b94576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601554835163ffffffff909116101562002bda576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108fc856020015163ffffffff16108062002c185750601454602086015163ffffffff70010000000000000000000000000000000090920482169116115b1562002c50576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000868152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff161562002cba576040517f6e3b930b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000868152600460209081526040808320885181548a8501518b85015160608d01517fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009093169315157fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff169390931761010063ffffffff92831602177fffffff000000000000000000000000000000000000000000000000ffffffffff1665010000000000938216939093027fffffff0000000000000000000000000000000000000000ffffffffffffffffff1692909217690100000000000000000073ffffffffffffffffffffffffffffffffffffffff9283160217835560808b01516001909301805460a08d015160c08e01516bffffffffffffffffffffffff9687167fffffffffffffffff000000000000000000000000000000000000000000000000909316929092176c010000000000000000000000009690911695909502949094177fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff1678010000000000000000000000000000000000000000000000009490931693909302919091179091556005835281842080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169189169190911790556007909152902062002ead8482620052e8565b508460a001516bffffffffffffffffffffffff1660185462002ed0919062004be7565b6018556000868152601a6020526040902062002eed8382620052e8565b506000868152601b6020526040902062002f088282620052e8565b5062002f16600287620038cf565b50505050505050565b321562002f58576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff16331462002fb8576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff908116146200292b576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f811015620030a5577fff00000000000000000000000000000000000000000000000000000000000000821683826020811062003059576200305962004bb8565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146200309057506000949350505050565b806200309c8162004bfd565b91505062003017565b5081600f1a600181111562002b3c5762002b3c6200438d565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156200314b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200317191906200542a565b50945090925050506000811315806200318957508142105b80620031ae5750828015620031ae5750620031a582426200492a565b8463ffffffff16105b15620031bf576016549550620031c3565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156200322f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200325591906200542a565b50945090925050506000811315806200326d57508142105b806200329257508280156200329257506200328982426200492a565b8463ffffffff16105b15620032a3576017549450620032a7565b8094505b50505050915091565b600080620032c488878b60000151620038dd565b9050600080620032e18b8a63ffffffff16858a8a60018b6200397c565b9092509050620032f2818362005221565b9b9a5050505050505050505050565b606060008360018111156200331a576200331a6200438d565b03620033e7576000848152600760205260409081902090517f6e04ff0d0000000000000000000000000000000000000000000000000000000091620033629160240162005522565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290506200351c565b6001836001811115620033fe57620033fe6200438d565b03620034ea576000828060200190518101906200341c919062005599565b6000868152600760205260409081902090519192507f40691db4000000000000000000000000000000000000000000000000000000009162003463918491602401620056ad565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915291506200351c9050565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b600062002997838362003e1e565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156200356a576200356a6200438d565b03620035e857606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620035bd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620035e3919062005775565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331462002f58576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016200116e565b3373ffffffffffffffffffffffffffffffffffffffff821603620036f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200116e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115620037a057620037a06200438d565b03620038c5576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620037f5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200381b919062005775565b905080831015806200383957506101006200383784836200492a565b115b15620038485750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa1580156200389f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200351c919062005775565b504090565b919050565b600062002997838362003f29565b60008080856001811115620038f657620038f66200438d565b0362003907575062015f906200392a565b60018560018111156200391e576200391e6200438d565b03620034ea57506201adb05b6200393d63ffffffff851660146200578f565b6200394a846001620057cf565b6200395b9060ff16611d4c6200578f565b62003967908362004be7565b62003973919062004be7565b95945050505050565b6000806000896080015161ffff16876200399791906200578f565b9050838015620039a65750803a105b15620039af57503a5b600060027f00000000000000000000000000000000000000000000000000000000000000006002811115620039e857620039e86200438d565b0362003b5957604080516000815260208101909152851562003a4c5760003660405180608001604052806048815260200162005cc46048913960405160200162003a3593929190620057eb565b604051602081830303815290604052905062003aba565b60155462003a6a90640100000000900463ffffffff16600462005814565b63ffffffff1667ffffffffffffffff81111562003a8b5762003a8b62004071565b6040519080825280601f01601f19166020018201604052801562003ab6576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9062003b0c908490600401620048ca565b602060405180830381865afa15801562003b2a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003b50919062005775565b91505062003cc3565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111562003b905762003b906200438d565b0362003cc357841562003c1857606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003bea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c10919062005775565b905062003cc3565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801562003c67573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c8d919062005843565b505060155492945062003cb293505050640100000000900463ffffffff16826200578f565b62003cbf9060106200578f565b9150505b8462003ce257808b6080015161ffff1662003cdf91906200578f565b90505b62003cf261ffff8716826200588e565b90506000878262003d048c8e62004be7565b62003d1090866200578f565b62003d1c919062004be7565b62003d3090670de0b6b3a76400006200578f565b62003d3c91906200588e565b905060008c6040015163ffffffff1664e8d4a5100062003d5d91906200578f565b898e6020015163ffffffff16858f8862003d7891906200578f565b62003d84919062004be7565b62003d9490633b9aca006200578f565b62003da091906200578f565b62003dac91906200588e565b62003db8919062004be7565b90506b033b2e3c9fd0803ce800000062003dd3828462004be7565b111562003e0c576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000818152600183016020526040812054801562003f1757600062003e456001836200492a565b855490915060009062003e5b906001906200492a565b905081811462003ec757600086600001828154811062003e7f5762003e7f62004bb8565b906000526020600020015490508087600001848154811062003ea55762003ea562004bb8565b6000918252602080832090910192909255918252600188019052604090208390555b855486908062003edb5762003edb620058ca565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506200299a565b60009150506200299a565b5092915050565b600081815260018301602052604081205462003f72575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556200299a565b5060006200299a565b6103ca80620058fa83390190565b50805462003f9790620049e8565b6000825580601f1062003fa8575050565b601f0160209004906000526020600020908101906200292b91905b8082111562003fd9576000815560010162003fc3565b5090565b73ffffffffffffffffffffffffffffffffffffffff811681146200292b57600080fd5b803563ffffffff81168114620038ca57600080fd5b803560028110620038ca57600080fd5b60008083601f8401126200403857600080fd5b50813567ffffffffffffffff8111156200405157600080fd5b6020830191508360208285010111156200406a57600080fd5b9250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160e0810167ffffffffffffffff81118282101715620040c657620040c662004071565b60405290565b604051610100810167ffffffffffffffff81118282101715620040c657620040c662004071565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156200413d576200413d62004071565b604052919050565b600067ffffffffffffffff82111562004162576200416262004071565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f830112620041a057600080fd5b8135620041b7620041b18262004145565b620040f3565b818152846020838601011115620041cd57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060e0898b0312156200420757600080fd5b8835620042148162003fdd565b97506200422460208a0162004000565b96506040890135620042368162003fdd565b95506200424660608a0162004015565b9450608089013567ffffffffffffffff808211156200426457600080fd5b620042728c838d0162004025565b909650945060a08b01359150808211156200428c57600080fd5b6200429a8c838d016200418e565b935060c08b0135915080821115620042b157600080fd5b50620042c08b828c016200418e565b9150509295985092959890939650565b60008060408385031215620042e457600080fd5b82359150602083013567ffffffffffffffff8111156200430357600080fd5b62004311858286016200418e565b9150509250929050565b60005b83811015620043385781810151838201526020016200431e565b50506000910152565b600081518084526200435b8160208601602086016200431b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600a8110620043f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b841515815260806020820152600062004415608083018662004341565b9050620044266040830185620043bc565b82606083015295945050505050565b6000806000604084860312156200444b57600080fd5b83359250602084013567ffffffffffffffff8111156200446a57600080fd5b620044788682870162004025565b9497909650939450505050565b600080600080600080600060a0888a031215620044a157600080fd5b8735620044ae8162003fdd565b9650620044be6020890162004000565b95506040880135620044d08162003fdd565b9450606088013567ffffffffffffffff80821115620044ee57600080fd5b620044fc8b838c0162004025565b909650945060808a01359150808211156200451657600080fd5b50620045258a828b0162004025565b989b979a50959850939692959293505050565b871515815260e0602082015260006200455560e083018962004341565b9050620045666040830188620043bc565b8560608301528460808301528360a08301528260c083015298975050505050505050565b600080600060408486031215620045a057600080fd5b833567ffffffffffffffff80821115620045b957600080fd5b818601915086601f830112620045ce57600080fd5b813581811115620045de57600080fd5b8760208260051b8501011115620045f457600080fd5b602092830195509350508401356200460c8162003fdd565b809150509250925092565b600080602083850312156200462b57600080fd5b823567ffffffffffffffff8111156200464357600080fd5b620046518582860162004025565b90969095509350505050565b80356bffffffffffffffffffffffff81168114620038ca57600080fd5b600080604083850312156200468e57600080fd5b82359150620046a0602084016200465d565b90509250929050565b600060208284031215620046bc57600080fd5b5035919050565b600067ffffffffffffffff821115620046e057620046e062004071565b5060051b60200190565b600082601f830112620046fc57600080fd5b813560206200470f620041b183620046c3565b82815260059290921b840181019181810190868411156200472f57600080fd5b8286015b848110156200477457803567ffffffffffffffff811115620047555760008081fd5b620047658986838b01016200418e565b84525091830191830162004733565b509695505050505050565b600080600080606085870312156200479657600080fd5b84359350602085013567ffffffffffffffff80821115620047b657600080fd5b620047c488838901620046ea565b94506040870135915080821115620047db57600080fd5b50620047ea8782880162004025565b95989497509550505050565b6000602082840312156200480957600080fd5b81356200351c8162003fdd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff80831681810362004861576200486162004816565b6001019392505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60208152600062002b3c6020830184866200486b565b60208152600062002997602083018462004341565b8051620038ca8162003fdd565b600060208284031215620048ff57600080fd5b81516200351c8162003fdd565b60008251620049208184602087016200431b565b9190910192915050565b818103818111156200299a576200299a62004816565b80151581146200292b57600080fd5b600082601f8301126200496157600080fd5b815162004972620041b18262004145565b8181528460208386010111156200498857600080fd5b62002b3c8260208301602087016200431b565b60008060408385031215620049af57600080fd5b8251620049bc8162004940565b602084015190925067ffffffffffffffff811115620049da57600080fd5b62004311858286016200494f565b600181811c90821680620049fd57607f821691505b60208210810362004a37577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111562004a8b57600081815260208120601f850160051c8101602086101562004a665750805b601f850160051c820191505b8181101562004a875782815560010162004a72565b5050505b505050565b67ffffffffffffffff83111562004aab5762004aab62004071565b62004ac38362004abc8354620049e8565b8362004a3d565b6000601f84116001811462004b18576000851562004ae15750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835562004bb1565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101562004b69578685013582556020948501946001909201910162004b47565b508682101562004ba5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b808201808211156200299a576200299a62004816565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362004c315762004c3162004816565b5060010190565b600081518084526020808501945080840160005b8381101562004cf75781518051151588528381015163ffffffff908116858a01526040808301519091169089015260608082015173ffffffffffffffffffffffffffffffffffffffff16908901526080808201516bffffffffffffffffffffffff169089015260a08082015162004cd2828b01826bffffffffffffffffffffffff169052565b505060c09081015163ffffffff169088015260e0909601959082019060010162004c4c565b509495945050505050565b600081518084526020808501945080840160005b8381101562004cf757815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010162004d16565b600081518084526020808501808196508360051b8101915082860160005b8581101562004d9657828403895262004d8384835162004341565b9885019893509084019060010162004d68565b5091979650505050505050565b60e081528760e082015260006101007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8a111562004de057600080fd5b8960051b808c8386013783018381038201602085015262004e048282018b62004c38565b915050828103604084015262004e1b818962004d02565b9050828103606084015262004e31818862004d02565b9050828103608084015262004e47818762004d4a565b905082810360a084015262004e5d818662004d4a565b905082810360c0840152620032f2818562004d4a565b60006020828403121562004e8657600080fd5b815160ff811681146200351c57600080fd5b60ff8416815260ff8316602082015260606040820152600062003973606083018462004341565b60006020828403121562004ed257600080fd5b815167ffffffffffffffff81111562004eea57600080fd5b62002b3c848285016200494f565b60006020828403121562004f0b57600080fd5b81516200351c8162004940565b600082601f83011262004f2a57600080fd5b8135602062004f3d620041b183620046c3565b82815260059290921b8401810191818101908684111562004f5d57600080fd5b8286015b8481101562004774578035835291830191830162004f61565b600082601f83011262004f8c57600080fd5b8135602062004f9f620041b183620046c3565b82815260e0928302850182019282820191908785111562004fbf57600080fd5b8387015b85811015620050765781818a03121562004fdd5760008081fd5b62004fe7620040a0565b813562004ff48162004940565b81526200500382870162004000565b8682015260406200501681840162004000565b908201526060828101356200502b8162003fdd565b9082015260806200503e8382016200465d565b9082015260a0620050518382016200465d565b9082015260c06200506483820162004000565b90820152845292840192810162004fc3565b5090979650505050505050565b600082601f8301126200509557600080fd5b81356020620050a8620041b183620046c3565b82815260059290921b84018101918181019086841115620050c857600080fd5b8286015b8481101562004774578035620050e28162003fdd565b8352918301918301620050cc565b600080600080600080600060e0888a0312156200510c57600080fd5b873567ffffffffffffffff808211156200512557600080fd5b620051338b838c0162004f18565b985060208a01359150808211156200514a57600080fd5b620051588b838c0162004f7a565b975060408a01359150808211156200516f57600080fd5b6200517d8b838c0162005083565b965060608a01359150808211156200519457600080fd5b620051a28b838c0162005083565b955060808a0135915080821115620051b957600080fd5b620051c78b838c01620046ea565b945060a08a0135915080821115620051de57600080fd5b620051ec8b838c01620046ea565b935060c08a01359150808211156200520357600080fd5b50620052128a828b01620046ea565b91505092959891949750929550565b6bffffffffffffffffffffffff81811683821601908082111562003f225762003f2262004816565b6bffffffffffffffffffffffff82811682821603908082111562003f225762003f2262004816565b60408152600062005286604083018662004d4a565b82810360208401526200529b8185876200486b565b9695505050505050565b8051602080830151919081101562004a37577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60209190910360031b1b16919050565b815167ffffffffffffffff81111562005305576200530562004071565b6200531d81620053168454620049e8565b8462004a3d565b602080601f8311600181146200537357600084156200533c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855562004a87565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015620053c257888601518255948401946001909101908401620053a1565b5085821015620053ff57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b805169ffffffffffffffffffff81168114620038ca57600080fd5b600080600080600060a086880312156200544357600080fd5b6200544e866200540f565b945060208601519350604086015192506060860151915062005473608087016200540f565b90509295509295909350565b600081546200548e81620049e8565b808552602060018381168015620054ae5760018114620054e75762005517565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b890101955062005517565b866000528260002060005b858110156200550f5781548a8201860152908301908401620054f2565b890184019650505b505050505092915050565b6020815260006200299760208301846200547f565b600082601f8301126200554957600080fd5b815160206200555c620041b183620046c3565b82815260059290921b840181019181810190868411156200557c57600080fd5b8286015b8481101562004774578051835291830191830162005580565b600060208284031215620055ac57600080fd5b815167ffffffffffffffff80821115620055c557600080fd5b908301906101008286031215620055db57600080fd5b620055e5620040cc565b82518152602083015160208201526040830151604082015260608301516060820152608083015160808201526200561f60a08401620048df565b60a082015260c0830151828111156200563757600080fd5b620056458782860162005537565b60c08301525060e0830151828111156200565e57600080fd5b6200566c878286016200494f565b60e08301525095945050505050565b600081518084526020808501945080840160005b8381101562004cf7578151875295820195908201906001016200568f565b60408152825160408201526020830151606082015260408301516080820152606083015160a0820152608083015160c082015273ffffffffffffffffffffffffffffffffffffffff60a08401511660e0820152600060c0840151610100808185015250620057206101408401826200567b565b905060e08501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0848303016101208501526200575e828262004341565b91505082810360208401526200397381856200547f565b6000602082840312156200578857600080fd5b5051919050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615620057ca57620057ca62004816565b500290565b60ff81811683821601908111156200299a576200299a62004816565b8284823760008382016000815283516200580a8183602088016200431b565b0195945050505050565b600063ffffffff808316818516818304811182151516156200583a576200583a62004816565b02949350505050565b60008060008060008060c087890312156200585d57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082620058c5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe60c060405234801561001057600080fd5b506040516103ca3803806103ca83398101604081905261002f91610076565b600080546001600160a01b0319166001600160a01b039384161790559181166080521660a0526100b9565b80516001600160a01b038116811461007157600080fd5b919050565b60008060006060848603121561008b57600080fd5b6100948461005a565b92506100a26020850161005a565b91506100b06040850161005a565b90509250925092565b60805160a0516102e76100e36000396000603801526000818160c4015261011701526102e76000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c806379188d161461007b578063f00e6a2a146100aa575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610076573d6000f35b3d6000fd5b61008e6100893660046101c1565b6100ee565b6040805192151583526020830191909152015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001681526020016100a1565b60008054819073ffffffffffffffffffffffffffffffffffffffff16331461011557600080fd5b7f00000000000000000000000000000000000000000000000000000000000000005a91505a61138881101561014957600080fd5b61138881039050856040820482031161016157600080fd5b50803b61016d57600080fd5b6000808551602087016000858af192505a610188908361029a565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080604083850312156101d457600080fd5b82359150602083013567ffffffffffffffff808211156101f357600080fd5b818501915085601f83011261020757600080fd5b81358181111561021957610219610192565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561025f5761025f610192565b8160405282815288602084870101111561027857600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b818103818111156102d4577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea164736f6c6343000810000a307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryLogicAABI = KeeperRegistryLogicAMetaData.ABI diff --git a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go index 9494d6d6aae..6f9c65b90bc 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go @@ -75,15 +75,15 @@ type KeeperRegistryBase21UpkeepInfo struct { } var KeeperRegistryLogicBMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101006040523480156200001257600080fd5b5060405162004eb838038062004eb88339810160408190526200003591620001e1565b838383833380600081620000905760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c357620000c38162000119565b505050836002811115620000db57620000db62000243565b60e0816002811115620000f257620000f262000243565b9052506001600160a01b0392831660805290821660a0521660c05250620002599350505050565b336001600160a01b03821603620001735760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000087565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001dc57600080fd5b919050565b60008060008060808587031215620001f857600080fd5b8451600381106200020857600080fd5b93506200021860208601620001c4565b92506200022860408601620001c4565b91506200023860608601620001c4565b905092959194509250565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e051614bdf620002d9600039600081816104fb0152818161329d0152818161382001526139b301526000818161058301526130910152600081816106cc015261316b01526000818161075a01528181611b7b01528181611e51015281816122c9015281816127eb015261286f0152614bdf6000f3fe608060405234801561001057600080fd5b50600436106103365760003560e01c806379ea9943116101b2578063b148ab6b116100f9578063cd7f71b5116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107ad578063ed56b3e1146107c0578063f2fde38b14610833578063faa3e9961461084657600080fd5b8063cd7f71b51461077e578063d2b441ab14610791578063d76326481461079a57600080fd5b8063b79550be116100d3578063b79550be14610730578063c7c3a19a14610738578063ca30e6031461075857600080fd5b8063b148ab6b14610703578063b6511a2a14610716578063b657bc9c1461071d57600080fd5b8063a710b2211161015b578063abc76ae011610135578063abc76ae0146106c2578063b10b673c146106ca578063b121e147146106f057600080fd5b8063a710b2211461068d578063a72aa27e146106a0578063aab9edd6146106b357600080fd5b80638765ecbe1161018c5780638765ecbe146106495780638da5cb5b1461065c5780638dcf0fe71461067a57600080fd5b806379ea9943146105f65780637d9b97e0146106395780638456cb591461064157600080fd5b80633f4ba83a116102815780635165f2f51161022a5780636709d0e5116102045780636709d0e514610581578063671d36ed146105c8578063744bfe61146105db57806379ba5097146105ee57600080fd5b80635165f2f5146105485780635b6aa71c1461055b5780636209e1e91461056e57600080fd5b80634b4fd03b1161025b5780634b4fd03b146104f95780634ca16c521461051f5780635147cd591461052857600080fd5b80633f4ba83a1461047b578063421d183b1461048357806348013d7b146104e957600080fd5b80631a2af011116102e3578063232c1cc5116102bd578063232c1cc5146104585780632d9c718f1461045f5780633b9cce591461046857600080fd5b80631a2af011146103d45780631e010439146103e7578063207b65161461044557600080fd5b80631865c57d116103145780631865c57d14610388578063187256e8146103a157806319d97a94146103b457600080fd5b8063050ee65d1461033b57806306e3b632146103535780630b7d33e614610373575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b610366610361366004613d3e565b61088c565b60405161034a9190613d60565b610386610381366004613ded565b6109a9565b005b610390610a63565b60405161034a959493929190613ff0565b6103866103af36600461412e565b610e7c565b6103c76103c2366004614169565b610eed565b60405161034a91906141f0565b6103866103e2366004614203565b610f8f565b6104286103f5366004614169565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff909116815260200161034a565b6103c7610453366004614169565b611095565b6014610340565b62061a80610340565b61038661047636600461422f565b6110b2565b610386611308565b6104966104913660046142a4565b61136e565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a00161034a565b60005b60405161034a91906142fe565b7f00000000000000000000000000000000000000000000000000000000000000006104ec565b62015f90610340565b61053b610536366004614169565b6114a1565b60405161034a9190614311565b610386610556366004614169565b6114ac565b610428610569366004614339565b61162e565b6103c761057c3660046142a4565b611760565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161034a565b6103866105d6366004614369565b611794565b6103866105e9366004614203565b61186e565b610386611c77565b6105a3610604366004614169565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b610386611d79565b610386611ed4565b610386610657366004614169565b611f45565b60005473ffffffffffffffffffffffffffffffffffffffff166105a3565b610386610688366004613ded565b6120ca565b61038661069b3660046143a3565b61211f565b6103866106ae3660046143cd565b61239b565b6040516003815260200161034a565b611d4c610340565b7f00000000000000000000000000000000000000000000000000000000000000006105a3565b6103866106fe3660046142a4565b612490565b610386610711366004614169565b612588565b6032610340565b61042861072b366004614169565b612785565b6103866127b2565b61074b610746366004614169565b61290e565b60405161034a91906143f0565b7f00000000000000000000000000000000000000000000000000000000000000006105a3565b61038661078c366004613ded565b612c42565b620f4240610340565b6104286107a8366004614169565b612cd9565b6103866107bb3660046143a3565b612ce4565b61081a6107ce3660046142a4565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff90911660208301520161034a565b6103866108413660046142a4565b612e42565b61087f6108543660046142a4565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161034a9190614527565b6060600061089a6002612e56565b90508084106108d5576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006108e1848661456a565b9050818111806108ef575083155b6108f957806108fb565b815b90506000610909868361457d565b67ffffffffffffffff81111561092157610921614590565b60405190808252806020026020018201604052801561094a578160200160208202803683370190505b50905060005b815181101561099d5761096e610966888361456a565b600290612e60565b828281518110610980576109806145bf565b602090810291909101015280610995816145ee565b915050610950565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a0a576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a238284836146c8565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a569291906147e3565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610bb06002612e56565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d586009612e73565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610dfb57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dd0575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610e6457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e39575b50505050509150945094509450945094509091929394565b610e84612e80565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610ee457610ee46142bf565b02179055505050565b6000818152601c60205260409020805460609190610f0a90614626565b80601f0160208091040260200160405190810160405280929190818152602001828054610f3690614626565b8015610f835780601f10610f5857610100808354040283529160200191610f83565b820191906000526020600020905b815481529060010190602001808311610f6657829003601f168201915b50505050509050919050565b610f9882612f03565b3373ffffffffffffffffffffffffffffffffffffffff821603610fe7576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116146110915760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f0a90614626565b6110ba612e80565b600e5481146110f5576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e548110156112c7576000600e8281548110611117576111176145bf565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f90925260408320549193501690858585818110611161576111616145bf565b905060200201602081019061117691906142a4565b905073ffffffffffffffffffffffffffffffffffffffff81161580611209575073ffffffffffffffffffffffffffffffffffffffff8216158015906111e757508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b8015611209575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611240576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112b15773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b50505080806112bf906145ee565b9150506110f8565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e83836040516112fc93929190614830565b60405180910390a15050565b611310612e80565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015282918291829182919082906114485760608201516012546000916114349170010000000000000000000000000000000090046bffffffffffffffffffffffff166148e0565b600e549091506114449082614934565b9150505b81516020830151604084015161145f90849061495f565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109a382612fb7565b6114b581612f03565b60008181526004602090815260409182902082516101008082018552825460ff8116151580845263ffffffff92820483169584019590955265010000000000810482169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009095048516606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a0840152780100000000000000000000000000000000000000000000000090041660c082015260029091015490921660e08301526115bf576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556115fe600283613062565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c01000000000000000000000000000000000000000000000000000000009091041691810191909152600090818061172d8361306e565b91509150611756838787601360020160049054906101000a900463ffffffff168686600061324c565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f0a90614626565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633146117f5576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d602052604090206118258284836146c8565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a569291906147e3565b6012546f01000000000000000000000000000000900460ff16156118be576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff8116611945576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020908152604080832081516101008082018452825460ff81161515835263ffffffff91810482168387015265010000000000810482168386015273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091048116606084015260018401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a08501527801000000000000000000000000000000000000000000000000900490911660c0830152600290920154821660e082015286855260059093529220549091163314611a58576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a60613297565b816040015163ffffffff161115611aa3576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611ae390829061457d565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611bc6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bea9190614984565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611cfd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611d81612e80565b6014546018546bffffffffffffffffffffffff90911690611da390829061457d565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611eb0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110919190614984565b611edc612e80565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25890602001611364565b611f4e81612f03565b60008181526004602090815260409182902082516101008082018552825460ff8116158015845263ffffffff92820483169584019590955265010000000000810482169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009095048516606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a0840152780100000000000000000000000000000000000000000000000090041660c082015260029091015490921660e0830152612058576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905561209a60028361334c565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120d383612f03565b6000838152601b602052604090206120ec8284836146c8565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a569291906147e3565b73ffffffffffffffffffffffffffffffffffffffff811661216c576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121cc576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e5460009161220391859170010000000000000000000000000000000090046bffffffffffffffffffffffff1690613358565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff16905560185490915061226d906bffffffffffffffffffffffff83169061457d565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015612312573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123369190614984565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123d0575060145463ffffffff7001000000000000000000000000000000009091048116908216115b15612407576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61241082612f03565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff8181166000908152601060205260409020541633146124f0576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b60008181526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff918104821694830194909452650100000000008404811694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009094048416606083015260018301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a084015278010000000000000000000000000000000000000000000000009004811660c083015260029092015490921660e0830152909114612694576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff1633146126f1576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109a361279383612fb7565b600084815260046020526040902054610100900463ffffffff1661162e565b6127ba612e80565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612847573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061286b91906149a6565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33601854846128b8919061457d565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611e91565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e08201819052610100820152610120810191909152600082815260046020908152604080832081516101008082018452825460ff81161515835263ffffffff918104821683870190815265010000000000820483168487015273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009092048216606085015260018501546bffffffffffffffffffffffff80821660808701526c0100000000000000000000000082041660a086015278010000000000000000000000000000000000000000000000009004831660c0850152600290940154811660e084019081528551610140810187529051909116815292511682850152868552600790935292819020805492939291830191612a6390614626565b80601f0160208091040260200160405190810160405280929190818152602001828054612a8f90614626565b8015612adc5780601f10612ab157610100808354040283529160200191612adc565b820191906000526020600020905b815481529060010190602001808311612abf57829003601f168201915b505050505081526020018260a001516bffffffffffffffffffffffff1681526020016005600086815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001826040015163ffffffff1667ffffffffffffffff1681526020018260c0015163ffffffff16815260200182608001516bffffffffffffffffffffffff168152602001826000015115158152602001601b60008681526020019081526020016000208054612bb990614626565b80601f0160208091040260200160405190810160405280929190818152602001828054612be590614626565b8015612c325780601f10612c0757610100808354040283529160200191612c32565b820191906000526020600020905b815481529060010190602001808311612c1557829003601f168201915b5050505050815250915050919050565b612c4b83612f03565b60155463ffffffff16811115612c8d576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612ca68284836146c8565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a569291906147e3565b60006109a382612785565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612d44576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612d93576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152601060205260409020548116908216146110915773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612e4a612e80565b612e5381613560565b50565b60006109a3825490565b6000612e6c8383613655565b9392505050565b60606000612e6c8361367f565b60005473ffffffffffffffffffffffffffffffffffffffff163314612f01576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611cf4565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612f60576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612e53576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f811015613044577fff000000000000000000000000000000000000000000000000000000000000008216838260208110612ffc57612ffc6145bf565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161461303257506000949350505050565b8061303c816145ee565b915050612fbe565b5081600f1a600181111561305a5761305a6142bf565b949350505050565b6000612e6c83836136da565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156130fa573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061311e91906149d9565b509450909250505060008113158061313557508142105b806131565750828015613156575061314d824261457d565b8463ffffffff16105b15613165576016549550613169565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156131d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131f891906149d9565b509450909250505060008113158061320f57508142105b8061323057508280156132305750613227824261457d565b8463ffffffff16105b1561323f576017549450613243565b8094505b50505050915091565b60008061325e88878b60000151613729565b90506000806132798b8a63ffffffff16858a8a60018b6137eb565b9092509050613288818361495f565b9b9a5050505050505050505050565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156132cd576132cd6142bf565b0361334757606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561331e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061334291906149a6565b905090565b504390565b6000612e6c8383613c44565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906135545760008160600151856133f091906148e0565b905060006133fe8583614934565b90508083604001818151613412919061495f565b6bffffffffffffffffffffffff1690525061342d8582614a29565b8360600181815161343e919061495f565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036135df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611cf4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600082600001828154811061366c5761366c6145bf565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610f8357602002820191906000526020600020905b8154815260200190600101908083116136bb5750505050509050919050565b6000818152600183016020526040812054613721575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109a3565b5060006109a3565b6000808085600181111561373f5761373f6142bf565b0361374e575062015f906137a3565b6001856001811115613762576137626142bf565b0361377157506201adb06137a3565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6137b463ffffffff85166014614a5d565b6137bf846001614a9a565b6137ce9060ff16611d4c614a5d565b6137d8908361456a565b6137e2919061456a565b95945050505050565b6000806000896080015161ffff16876138049190614a5d565b90508380156138125750803a105b1561381a57503a5b600060027f00000000000000000000000000000000000000000000000000000000000000006002811115613850576138506142bf565b036139af5760408051600081526020810190915285156138ae57600036604051806080016040528060488152602001614b8b6048913960405160200161389893929190614ab3565b6040516020818303038152906040529050613916565b6015546138ca90640100000000900463ffffffff166004614ada565b63ffffffff1667ffffffffffffffff8111156138e8576138e8614590565b6040519080825280601f01601f191660200182016040528015613912576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e906139669084906004016141f0565b602060405180830381865afa158015613983573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139a791906149a6565b915050613b09565b60017f000000000000000000000000000000000000000000000000000000000000000060028111156139e3576139e36142bf565b03613b09578415613a6557606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a5e91906149a6565b9050613b09565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613ab3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ad79190614afd565b5050601554929450613afa93505050640100000000900463ffffffff1682614a5d565b613b05906010614a5d565b9150505b84613b2557808b6080015161ffff16613b229190614a5d565b90505b613b3361ffff871682614b47565b905060008782613b438c8e61456a565b613b4d9086614a5d565b613b57919061456a565b613b6990670de0b6b3a7640000614a5d565b613b739190614b47565b905060008c6040015163ffffffff1664e8d4a51000613b929190614a5d565b898e6020015163ffffffff16858f88613bab9190614a5d565b613bb5919061456a565b613bc390633b9aca00614a5d565b613bcd9190614a5d565b613bd79190614b47565b613be1919061456a565b90506b033b2e3c9fd0803ce8000000613bfa828461456a565b1115613c32576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613d2d576000613c6860018361457d565b8554909150600090613c7c9060019061457d565b9050818114613ce1576000866000018281548110613c9c57613c9c6145bf565b9060005260206000200154905080876000018481548110613cbf57613cbf6145bf565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613cf257613cf2614b5b565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109a3565b60009150506109a3565b5092915050565b60008060408385031215613d5157600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613d9857835183529284019291840191600101613d7c565b50909695505050505050565b60008083601f840112613db657600080fd5b50813567ffffffffffffffff811115613dce57600080fd5b602083019150836020828501011115613de657600080fd5b9250929050565b600080600060408486031215613e0257600080fd5b83359250602084013567ffffffffffffffff811115613e2057600080fd5b613e2c86828701613da4565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613e7f57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613e4d565b509495945050505050565b805163ffffffff16825260006101e06020830151613eb0602086018263ffffffff169052565b506040830151613ec8604086018263ffffffff169052565b506060830151613edf606086018262ffffff169052565b506080830151613ef5608086018261ffff169052565b5060a0830151613f1560a08601826bffffffffffffffffffffffff169052565b5060c0830151613f2d60c086018263ffffffff169052565b5060e0830151613f4560e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a080840151818601839052613fba83870182613e39565b925050506101c080840151613fe68287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c0602088015161401e60208501826bffffffffffffffffffffffff169052565b5060408801516040840152606088015161404860608501826bffffffffffffffffffffffff169052565b506080880151608084015260a088015161406a60a085018263ffffffff169052565b5060c088015161408260c085018263ffffffff169052565b5060e088015160e0840152610100808901516140a58286018263ffffffff169052565b50506101208881015115159084015261014083018190526140c881840188613e8a565b90508281036101608401526140dd8187613e39565b90508281036101808401526140f28186613e39565b9150506117566101a083018460ff169052565b803573ffffffffffffffffffffffffffffffffffffffff8116811461412957600080fd5b919050565b6000806040838503121561414157600080fd5b61414a83614105565b915060208301356004811061415e57600080fd5b809150509250929050565b60006020828403121561417b57600080fd5b5035919050565b60005b8381101561419d578181015183820152602001614185565b50506000910152565b600081518084526141be816020860160208601614182565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612e6c60208301846141a6565b6000806040838503121561421657600080fd5b8235915061422660208401614105565b90509250929050565b6000806020838503121561424257600080fd5b823567ffffffffffffffff8082111561425a57600080fd5b818501915085601f83011261426e57600080fd5b81358181111561427d57600080fd5b8660208260051b850101111561429257600080fd5b60209290920196919550909350505050565b6000602082840312156142b657600080fd5b612e6c82614105565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612e5357612e536142bf565b6020810161430b836142ee565b91905290565b602081016002831061430b5761430b6142bf565b803563ffffffff8116811461412957600080fd5b6000806040838503121561434c57600080fd5b82356002811061435b57600080fd5b915061422660208401614325565b60008060006040848603121561437e57600080fd5b61438784614105565b9250602084013567ffffffffffffffff811115613e2057600080fd5b600080604083850312156143b657600080fd5b6143bf83614105565b915061422660208401614105565b600080604083850312156143e057600080fd5b8235915061422660208401614325565b6020815261441760208201835173ffffffffffffffffffffffffffffffffffffffff169052565b60006020830151614430604084018263ffffffff169052565b50604083015161014080606085015261444d6101608501836141a6565b9150606085015161446e60808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e08501516101006144da818701836bffffffffffffffffffffffff169052565b86015190506101206144ef8682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00183870152905061175683826141a6565b602081016004831061430b5761430b6142bf565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109a3576109a361453b565b818103818111156109a3576109a361453b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361461f5761461f61453b565b5060010190565b600181811c9082168061463a57607f821691505b602082108103614673577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156146c357600081815260208120601f850160051c810160208610156146a05750805b601f850160051c820191505b818110156146bf578281556001016146ac565b5050505b505050565b67ffffffffffffffff8311156146e0576146e0614590565b6146f4836146ee8354614626565b83614679565b6000601f84116001811461474657600085156147105750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147dc565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147955786850135825560209485019460019092019101614775565b50868210156147d0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561488757815473ffffffffffffffffffffffffffffffffffffffff1684529284019260019182019101614855565b505050838103828501528481528590820160005b868110156148d45773ffffffffffffffffffffffffffffffffffffffff6148c184614105565b168252918301919083019060010161489b565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613d3757613d3761453b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff8084168061495357614953614905565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613d3757613d3761453b565b60006020828403121561499657600080fd5b81518015158114612e6c57600080fd5b6000602082840312156149b857600080fd5b5051919050565b805169ffffffffffffffffffff8116811461412957600080fd5b600080600080600060a086880312156149f157600080fd5b6149fa866149bf565b9450602086015193506040860151925060608601519150614a1d608087016149bf565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614a5457614a5461453b565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614a9557614a9561453b565b500290565b60ff81811683821601908111156109a3576109a361453b565b828482376000838201600081528351614ad0818360208801614182565b0195945050505050565b600063ffffffff80831681851681830481118215151615614a5457614a5461453b565b60008060008060008060c08789031215614b1657600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614b5657614b56614905565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101206040523480156200001257600080fd5b5060405162004fa638038062004fa68339810160408190526200003591620001e9565b84848484843380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000121565b505050846002811115620000dc57620000dc6200025e565b60e0816002811115620000f357620000f36200025e565b9052506001600160a01b0393841660805291831660a052821660c05216610100525062000274945050505050565b336001600160a01b038216036200017b5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001e457600080fd5b919050565b600080600080600060a086880312156200020257600080fd5b8551600381106200021257600080fd5b94506200022260208701620001cc565b93506200023260408701620001cc565b92506200024260608701620001cc565b91506200025260808701620001cc565b90509295509295909350565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051614ca7620002ff60003960006105680152600081816105060152818161333c015281816138bf0152613a520152600081816105d501526131300152600081816106fd015261320a01526000818161078b01528181611b9501528181611e6b015281816122d8015281816127eb015261286f0152614ca76000f3fe608060405234801561001057600080fd5b50600436106103415760003560e01c806379ba5097116101bd578063b148ab6b116100f9578063cd7f71b5116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107de578063ed56b3e1146107f1578063f2fde38b14610864578063faa3e9961461087757600080fd5b8063cd7f71b5146107af578063d2b441ab146107c2578063d7632648146107cb57600080fd5b8063b79550be116100d3578063b79550be14610761578063c7c3a19a14610769578063ca30e6031461078957600080fd5b8063b148ab6b14610734578063b6511a2a14610747578063b657bc9c1461074e57600080fd5b80638dcf0fe711610166578063aab9edd611610140578063aab9edd6146106e4578063abc76ae0146106f3578063b10b673c146106fb578063b121e1471461072157600080fd5b80638dcf0fe7146106ab578063a710b221146106be578063a72aa27e146106d157600080fd5b80638456cb59116101975780638456cb59146106725780638765ecbe1461067a5780638da5cb5b1461068d57600080fd5b806379ba50971461061f57806379ea9943146106275780637d9b97e01461066a57600080fd5b80633f4ba83a1161028c5780635165f2f5116102355780636209e1e91161020f5780636209e1e9146105c05780636709d0e5146105d3578063671d36ed146105f9578063744bfe611461060c57600080fd5b80635165f2f5146105535780635425d8ac146105665780635b6aa71c146105ad57600080fd5b80634b4fd03b116102665780634b4fd03b146105045780634ca16c521461052a5780635147cd591461053357600080fd5b80633f4ba83a14610486578063421d183b1461048e57806348013d7b146104f457600080fd5b80631a2af011116102ee578063232c1cc5116102c8578063232c1cc5146104635780632d9c718f1461046a5780633b9cce591461047357600080fd5b80631a2af011146103df5780631e010439146103f2578063207b65161461045057600080fd5b80631865c57d1161031f5780631865c57d14610393578063187256e8146103ac57806319d97a94146103bf57600080fd5b8063050ee65d1461034657806306e3b6321461035e5780630b7d33e61461037e575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b61037161036c366004613ddd565b6108bd565b6040516103559190613dff565b61039161038c366004613e8c565b6109da565b005b61039b610a94565b60405161035595949392919061408f565b6103916103ba3660046141c6565b610ead565b6103d26103cd366004614203565b610f1e565b604051610355919061428a565b6103916103ed36600461429d565b610fc0565b610433610400366004614203565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff9091168152602001610355565b6103d261045e366004614203565b6110c6565b601461034b565b62061a8061034b565b6103916104813660046142c2565b6110e3565b610391611339565b6104a161049c366004614337565b61139f565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a001610355565b60005b6040516103559190614393565b7f00000000000000000000000000000000000000000000000000000000000000006104f7565b62015f9061034b565b610546610541366004614203565b6114d2565b60405161035591906143a6565b610391610561366004614203565b6114dd565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610355565b6104336105bb3660046143d3565b611654565b6103d26105ce366004614337565b611786565b7f0000000000000000000000000000000000000000000000000000000000000000610588565b61039161060736600461440c565b6117ba565b61039161061a36600461429d565b611894565b610391611c91565b610588610635366004614203565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b610391611d93565b610391611eee565b610391610688366004614203565b611f5f565b60005473ffffffffffffffffffffffffffffffffffffffff16610588565b6103916106b9366004613e8c565b6120d9565b6103916106cc366004614448565b61212e565b6103916106df366004614476565b6123aa565b60405160038152602001610355565b611d4c61034b565b7f0000000000000000000000000000000000000000000000000000000000000000610588565b61039161072f366004614337565b61249f565b610391610742366004614203565b612597565b603261034b565b61043361075c366004614203565b612785565b6103916127b2565b61077c610777366004614203565b61290e565b6040516103559190614499565b7f0000000000000000000000000000000000000000000000000000000000000000610588565b6103916107bd366004613e8c565b612ce1565b620f424061034b565b6104336107d9366004614203565b612d78565b6103916107ec366004614448565b612d83565b61084b6107ff366004614337565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff909116602083015201610355565b610391610872366004614337565b612ee1565b6108b0610885366004614337565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161035591906145d0565b606060006108cb6002612ef5565b9050808410610906576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006109128486614613565b905081811180610920575083155b61092a578061092c565b815b9050600061093a8683614626565b67ffffffffffffffff81111561095257610952614639565b60405190808252806020026020018201604052801561097b578160200160208202803683370190505b50905060005b81518110156109ce5761099f6109978883614613565b600290612eff565b8282815181106109b1576109b1614668565b6020908102919091010152806109c681614697565b915050610981565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a3b576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a54828483614771565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a8792919061488c565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610be16002612ef5565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d896009612f12565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610e2c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e01575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610e9557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e6a575b50505050509150945094509450945094509091929394565b610eb5612f1f565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610f1557610f15614354565b02179055505050565b6000818152601c60205260409020805460609190610f3b906146cf565b80601f0160208091040260200160405190810160405280929190818152602001828054610f67906146cf565b8015610fb45780601f10610f8957610100808354040283529160200191610fb4565b820191906000526020600020905b815481529060010190602001808311610f9757829003601f168201915b50505050509050919050565b610fc982612fa2565b3373ffffffffffffffffffffffffffffffffffffffff821603611018576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116146110c25760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f3b906146cf565b6110eb612f1f565b600e548114611126576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e548110156112f8576000600e828154811061114857611148614668565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f9092526040832054919350169085858581811061119257611192614668565b90506020020160208101906111a79190614337565b905073ffffffffffffffffffffffffffffffffffffffff8116158061123a575073ffffffffffffffffffffffffffffffffffffffff82161580159061121857508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b801561123a575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611271576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112e25773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b50505080806112f090614697565b915050611129565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e838360405161132d939291906148d9565b60405180910390a15050565b611341612f1f565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015282918291829182919082906114795760608201516012546000916114659170010000000000000000000000000000000090046bffffffffffffffffffffffff1661498b565b600e5490915061147590826149df565b9150505b815160208301516040840151611490908490614a0a565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109d482613056565b6114e681612fa2565b600081815260046020908152604091829020825160e081018452815460ff8116151580835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c0820152906115e5576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055611624600283613101565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c0100000000000000000000000000000000000000000000000000000000909104169181019190915260009081806117538361310d565b9150915061177c838787601360020160049054906101000a900463ffffffff16868660006132eb565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f3b906146cf565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16331461181b576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d6020526040902061184b828483614771565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a8792919061488c565b6012546f01000000000000000000000000000000900460ff16156118e4576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff811661196b576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600460209081526040808320815160e081018352815460ff81161515825263ffffffff610100820481168387015265010000000000820481168386015273ffffffffffffffffffffffffffffffffffffffff6901000000000000000000909204821660608401526001909301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c082015286855260059093529220549091163314611a72576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a7a613336565b816040015163ffffffff161115611abd576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611afd908290614626565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c049190614a2f565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611d17576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611d9b612f1f565b6014546018546bffffffffffffffffffffffff90911690611dbd908290614626565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611eca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110c29190614a2f565b611ef6612f1f565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25890602001611395565b611f6881612fa2565b600081815260046020908152604091829020825160e081018452815460ff8116158015835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c082015290612067576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556120a96002836133eb565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120e283612fa2565b6000838152601b602052604090206120fb828483614771565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a8792919061488c565b73ffffffffffffffffffffffffffffffffffffffff811661217b576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121db576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e5460009161221291859170010000000000000000000000000000000090046bffffffffffffffffffffffff16906133f7565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff16905560185490915061227c906bffffffffffffffffffffffff831690614626565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015612321573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123459190614a2f565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123df575060145463ffffffff7001000000000000000000000000000000009091048116908216115b15612416576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61241f82612fa2565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff8181166000908152601060205260409020541633146124ff576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b600081815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c08201529114612694576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff1633146126f1576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109d461279383613056565b600084815260046020526040902054610100900463ffffffff16611654565b6127ba612f1f565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612847573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061286b9190614a51565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33601854846128b89190614626565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611eab565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e082018190526101008201526101208101919091526000828152600460209081526040808320815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606083018190526001909101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c0820152919015612aa657816060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612a7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612aa19190614a6a565b612aa9565b60005b90506040518061014001604052808273ffffffffffffffffffffffffffffffffffffffff168152602001836020015163ffffffff168152602001600760008781526020019081526020016000208054612b01906146cf565b80601f0160208091040260200160405190810160405280929190818152602001828054612b2d906146cf565b8015612b7a5780601f10612b4f57610100808354040283529160200191612b7a565b820191906000526020600020905b815481529060010190602001808311612b5d57829003601f168201915b505050505081526020018360a001516bffffffffffffffffffffffff1681526020016005600087815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001836040015163ffffffff1667ffffffffffffffff1681526020018360c0015163ffffffff16815260200183608001516bffffffffffffffffffffffff168152602001836000015115158152602001601b60008781526020019081526020016000208054612c57906146cf565b80601f0160208091040260200160405190810160405280929190818152602001828054612c83906146cf565b8015612cd05780601f10612ca557610100808354040283529160200191612cd0565b820191906000526020600020905b815481529060010190602001808311612cb357829003601f168201915b505050505081525092505050919050565b612cea83612fa2565b60155463ffffffff16811115612d2c576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612d45828483614771565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a8792919061488c565b60006109d482612785565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612de3576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612e32576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152601060205260409020548116908216146110c25773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612ee9612f1f565b612ef2816135ff565b50565b60006109d4825490565b6000612f0b83836136f4565b9392505050565b60606000612f0b8361371e565b60005473ffffffffffffffffffffffffffffffffffffffff163314612fa0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611d0e565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612fff576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612ef2576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f8110156130e3577fff00000000000000000000000000000000000000000000000000000000000000821683826020811061309b5761309b614668565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146130d157506000949350505050565b806130db81614697565b91505061305d565b5081600f1a60018111156130f9576130f9614354565b949350505050565b6000612f0b8383613779565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613199573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131bd9190614aa1565b50945090925050506000811315806131d457508142105b806131f557508280156131f557506131ec8242614626565b8463ffffffff16105b15613204576016549550613208565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613273573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132979190614aa1565b50945090925050506000811315806132ae57508142105b806132cf57508280156132cf57506132c68242614626565b8463ffffffff16105b156132de5760175494506132e2565b8094505b50505050915091565b6000806132fd88878b600001516137c8565b90506000806133188b8a63ffffffff16858a8a60018b61388a565b90925090506133278183614a0a565b9b9a5050505050505050505050565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111561336c5761336c614354565b036133e657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156133bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133e19190614a51565b905090565b504390565b6000612f0b8383613ce3565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906135f357600081606001518561348f919061498b565b9050600061349d85836149df565b905080836040018181516134b19190614a0a565b6bffffffffffffffffffffffff169052506134cc8582614af1565b836060018181516134dd9190614a0a565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361367e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611d0e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600082600001828154811061370b5761370b614668565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610fb457602002820191906000526020600020905b81548152602001906001019080831161375a5750505050509050919050565b60008181526001830160205260408120546137c0575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109d4565b5060006109d4565b600080808560018111156137de576137de614354565b036137ed575062015f90613842565b600185600181111561380157613801614354565b0361381057506201adb0613842565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61385363ffffffff85166014614b25565b61385e846001614b62565b61386d9060ff16611d4c614b25565b6138779083614613565b6138819190614613565b95945050505050565b6000806000896080015161ffff16876138a39190614b25565b90508380156138b15750803a105b156138b957503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156138ef576138ef614354565b03613a4e57604080516000815260208101909152851561394d57600036604051806080016040528060488152602001614c536048913960405160200161393793929190614b7b565b60405160208183030381529060405290506139b5565b60155461396990640100000000900463ffffffff166004614ba2565b63ffffffff1667ffffffffffffffff81111561398757613987614639565b6040519080825280601f01601f1916602001820160405280156139b1576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613a0590849060040161428a565b602060405180830381865afa158015613a22573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a469190614a51565b915050613ba8565b60017f00000000000000000000000000000000000000000000000000000000000000006002811115613a8257613a82614354565b03613ba8578415613b0457606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613ad9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613afd9190614a51565b9050613ba8565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613b52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b769190614bc5565b5050601554929450613b9993505050640100000000900463ffffffff1682614b25565b613ba4906010614b25565b9150505b84613bc457808b6080015161ffff16613bc19190614b25565b90505b613bd261ffff871682614c0f565b905060008782613be28c8e614613565b613bec9086614b25565b613bf69190614613565b613c0890670de0b6b3a7640000614b25565b613c129190614c0f565b905060008c6040015163ffffffff1664e8d4a51000613c319190614b25565b898e6020015163ffffffff16858f88613c4a9190614b25565b613c549190614613565b613c6290633b9aca00614b25565b613c6c9190614b25565b613c769190614c0f565b613c809190614613565b90506b033b2e3c9fd0803ce8000000613c998284614613565b1115613cd1576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613dcc576000613d07600183614626565b8554909150600090613d1b90600190614626565b9050818114613d80576000866000018281548110613d3b57613d3b614668565b9060005260206000200154905080876000018481548110613d5e57613d5e614668565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613d9157613d91614c23565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109d4565b60009150506109d4565b5092915050565b60008060408385031215613df057600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613e3757835183529284019291840191600101613e1b565b50909695505050505050565b60008083601f840112613e5557600080fd5b50813567ffffffffffffffff811115613e6d57600080fd5b602083019150836020828501011115613e8557600080fd5b9250929050565b600080600060408486031215613ea157600080fd5b83359250602084013567ffffffffffffffff811115613ebf57600080fd5b613ecb86828701613e43565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613f1e57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613eec565b509495945050505050565b805163ffffffff16825260006101e06020830151613f4f602086018263ffffffff169052565b506040830151613f67604086018263ffffffff169052565b506060830151613f7e606086018262ffffff169052565b506080830151613f94608086018261ffff169052565b5060a0830151613fb460a08601826bffffffffffffffffffffffff169052565b5060c0830151613fcc60c086018263ffffffff169052565b5060e0830151613fe460e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a08084015181860183905261405983870182613ed8565b925050506101c0808401516140858287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c060208801516140bd60208501826bffffffffffffffffffffffff169052565b506040880151604084015260608801516140e760608501826bffffffffffffffffffffffff169052565b506080880151608084015260a088015161410960a085018263ffffffff169052565b5060c088015161412160c085018263ffffffff169052565b5060e088015160e0840152610100808901516141448286018263ffffffff169052565b505061012088810151151590840152610140830181905261416781840188613f29565b905082810361016084015261417c8187613ed8565b90508281036101808401526141918186613ed8565b91505061177c6101a083018460ff169052565b73ffffffffffffffffffffffffffffffffffffffff81168114612ef257600080fd5b600080604083850312156141d957600080fd5b82356141e4816141a4565b91506020830135600481106141f857600080fd5b809150509250929050565b60006020828403121561421557600080fd5b5035919050565b60005b8381101561423757818101518382015260200161421f565b50506000910152565b6000815180845261425881602086016020860161421c565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612f0b6020830184614240565b600080604083850312156142b057600080fd5b8235915060208301356141f8816141a4565b600080602083850312156142d557600080fd5b823567ffffffffffffffff808211156142ed57600080fd5b818501915085601f83011261430157600080fd5b81358181111561431057600080fd5b8660208260051b850101111561432557600080fd5b60209290920196919550909350505050565b60006020828403121561434957600080fd5b8135612f0b816141a4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612ef257612ef2614354565b602081016143a083614383565b91905290565b60208101600283106143a0576143a0614354565b803563ffffffff811681146143ce57600080fd5b919050565b600080604083850312156143e657600080fd5b8235600281106143f557600080fd5b9150614403602084016143ba565b90509250929050565b60008060006040848603121561442157600080fd5b833561442c816141a4565b9250602084013567ffffffffffffffff811115613ebf57600080fd5b6000806040838503121561445b57600080fd5b8235614466816141a4565b915060208301356141f8816141a4565b6000806040838503121561448957600080fd5b82359150614403602084016143ba565b602081526144c060208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516144d9604084018263ffffffff169052565b5060408301516101408060608501526144f6610160850183614240565b9150606085015161451760808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e0850151610100614583818701836bffffffffffffffffffffffff169052565b86015190506101206145988682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00183870152905061177c8382614240565b60208101600483106143a0576143a0614354565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109d4576109d46145e4565b818103818111156109d4576109d46145e4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036146c8576146c86145e4565b5060010190565b600181811c908216806146e357607f821691505b60208210810361471c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561476c57600081815260208120601f850160051c810160208610156147495750805b601f850160051c820191505b8181101561476857828155600101614755565b5050505b505050565b67ffffffffffffffff83111561478957614789614639565b61479d8361479783546146cf565b83614722565b6000601f8411600181146147ef57600085156147b95750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614885565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561483e578685013582556020948501946001909201910161481e565b5086821015614879577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561493057815473ffffffffffffffffffffffffffffffffffffffff16845292840192600191820191016148fe565b505050838103828501528481528590820160005b8681101561497f578235614957816141a4565b73ffffffffffffffffffffffffffffffffffffffff1682529183019190830190600101614944565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613dd657613dd66145e4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff808416806149fe576149fe6149b0565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613dd657613dd66145e4565b600060208284031215614a4157600080fd5b81518015158114612f0b57600080fd5b600060208284031215614a6357600080fd5b5051919050565b600060208284031215614a7c57600080fd5b8151612f0b816141a4565b805169ffffffffffffffffffff811681146143ce57600080fd5b600080600080600060a08688031215614ab957600080fd5b614ac286614a87565b9450602086015193506040860151925060608601519150614ae560808701614a87565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614b1c57614b1c6145e4565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b5d57614b5d6145e4565b500290565b60ff81811683821601908111156109d4576109d46145e4565b828482376000838201600081528351614b9881836020880161421c565b0195945050505050565b600063ffffffff80831681851681830481118215151615614b1c57614b1c6145e4565b60008060008060008060c08789031215614bde57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614c1e57614c1e6149b0565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryLogicBABI = KeeperRegistryLogicBMetaData.ABI var KeeperRegistryLogicBBin = KeeperRegistryLogicBMetaData.Bin -func DeployKeeperRegistryLogicB(auth *bind.TransactOpts, backend bind.ContractBackend, mode uint8, link common.Address, linkNativeFeed common.Address, fastGasFeed common.Address) (common.Address, *types.Transaction, *KeeperRegistryLogicB, error) { +func DeployKeeperRegistryLogicB(auth *bind.TransactOpts, backend bind.ContractBackend, mode uint8, link common.Address, linkNativeFeed common.Address, fastGasFeed common.Address, automationForwarderLogic common.Address) (common.Address, *types.Transaction, *KeeperRegistryLogicB, error) { parsed, err := KeeperRegistryLogicBMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -92,7 +92,7 @@ func DeployKeeperRegistryLogicB(auth *bind.TransactOpts, backend bind.ContractBa return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(KeeperRegistryLogicBBin), backend, mode, link, linkNativeFeed, fastGasFeed) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(KeeperRegistryLogicBBin), backend, mode, link, linkNativeFeed, fastGasFeed, automationForwarderLogic) if err != nil { return common.Address{}, nil, nil, err } @@ -259,6 +259,28 @@ func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetAdminPrivileg return _KeeperRegistryLogicB.Contract.GetAdminPrivilegeConfig(&_KeeperRegistryLogicB.CallOpts, admin) } +func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) GetAutomationForwarderLogic(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _KeeperRegistryLogicB.contract.Call(opts, &out, "getAutomationForwarderLogic") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_KeeperRegistryLogicB *KeeperRegistryLogicBSession) GetAutomationForwarderLogic() (common.Address, error) { + return _KeeperRegistryLogicB.Contract.GetAutomationForwarderLogic(&_KeeperRegistryLogicB.CallOpts) +} + +func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetAutomationForwarderLogic() (common.Address, error) { + return _KeeperRegistryLogicB.Contract.GetAutomationForwarderLogic(&_KeeperRegistryLogicB.CallOpts) +} + func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) GetBalance(opts *bind.CallOpts, id *big.Int) (*big.Int, error) { var out []interface{} err := _KeeperRegistryLogicB.contract.Call(opts, &out, "getBalance", id) @@ -5281,6 +5303,8 @@ type KeeperRegistryLogicBInterface interface { GetAdminPrivilegeConfig(opts *bind.CallOpts, admin common.Address) ([]byte, error) + GetAutomationForwarderLogic(opts *bind.CallOpts) (common.Address, error) + GetBalance(opts *bind.CallOpts, id *big.Int) (*big.Int, error) GetCancellationDelay(opts *bind.CallOpts) (*big.Int, error) diff --git a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go index 7314e295e31..8215d4c3310 100644 --- a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go @@ -50,7 +50,7 @@ type KeeperRegistryBase21OnchainConfig struct { var KeeperRegistryMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101206040523480156200001257600080fd5b506040516200543038038062005430833981016040819052620000359162000374565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b91906200039b565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000100919062000374565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000165919062000374565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca919062000374565b3380600081620002215760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000254576200025481620002b0565b5050508360028111156200026c576200026c620003be565b60e0816002811115620002835762000283620003be565b9052506001600160a01b0392831660805290821660a052811660c052919091166101005250620003d49050565b336001600160a01b038216036200030a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000218565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200037157600080fd5b50565b6000602082840312156200038757600080fd5b815162000394816200035b565b9392505050565b600060208284031215620003ae57600080fd5b8151600381106200039457600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e051610100516150026200042e6000396000818160d6015261016f0152600081816124850152818161337c0152818161350f0152613a3f01526000505060005050600061043b01526150026000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063a931358d11610081578063b1dc65a41161005b578063b1dc65a4146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063a931358d14610262578063aed2e92914610275578063afcb95d71461029f576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613cbe565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d47565b610423565b610119610270366004614167565b61063f565b610288610283366004614234565b611456565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102f63660046142c5565b6115ce565b61011961030936600461437c565b6121b5565b61011961031c36600461440b565b6121de565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da82840184614428565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff16614470565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da908590614495565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b6106476121f2565b601f86511115610683576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036106c0576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b845186511415806106df57506106d78460036144a8565b60ff16865111155b15610716576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156107ab57610798600e828154811061076f5761076f6144d1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612275565b50806107a381614500565b915050610743565b5060008060005b836bffffffffffffffffffffffff168110156108b457600d81815481106107db576107db6144d1565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff90921694509082908110610816576108166144d1565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806108ac81614500565b9150506107b2565b506108c1600d6000613b93565b6108cd600e6000613b93565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c51811015610c5157600c60008e8381518110610912576109126144d1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff161561097d576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106109ae576109ae6144d1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110610a5657610a566144d1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250610b1b576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941717919091169290921791909117905580610c4981614500565b9150506108f3565b50508a51610c679150600d9060208d0190613bb1565b508851610c7b90600e9060208c0190613bb1565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff16905061123d61247f565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff93841602178082556001926018916112b89185917801000000000000000000000000000000000000000000000000900416614538565b92506101000a81548163ffffffff021916908363ffffffff1602179055506000886040516020016112e991906145a6565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061135290469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f612534565b60115560005b61136260096125de565b8110156113925761137f6113776009836125ee565b6009906125fa565b508061138a81614500565b915050611358565b5060005b896101a00151518110156113e9576113d68a6101a0015182815181106113be576113be6144d1565b6020026020010151600961261c90919063ffffffff16565b50806113e181614500565b915050611396565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f6040516114409998979695949392919061470a565b60405180910390a1505050505050505050505050565b60008061146161263e565b6012546e010000000000000000000000000000900460ff16156114b0576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008581526004602090815260409182902082516101008082018552825460ff81161515835263ffffffff918104821683860181905265010000000000820483168488015273ffffffffffffffffffffffffffffffffffffffff690100000000000000000090920482166060850181905260018601546bffffffffffffffffffffffff80821660808801526c0100000000000000000000000082041660a08701527801000000000000000000000000000000000000000000000000900490931660c08501526002909401541660e08301528451601f890185900485028101850190955287855290936115bf93919291899089908190840183828082843760009201919091525061267692505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506116fc576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff16611745576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a3514611781576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805161178e9060016147a0565b60ff168614158061179f5750858414155b156117d6576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117e68a8a8a8a8a8a8a8a612881565b60006117f28a8a612aea565b9050600081604001515167ffffffffffffffff81111561181457611814613da3565b6040519080825280602002602001820160405280156118e857816020015b6040805161022081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e08301829052610200830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816118325790505b5090506000805b836040015151811015611da9576004600085604001518381518110611916576119166144d1565b602090810291909101810151825281810192909252604090810160002081516101008082018452825460ff81161515835263ffffffff91810482169583019590955265010000000000850481169382019390935273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009094048416606082015260018201546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490921660c08301526002015490911660e08201528351849083908110611a0857611a086144d1565b602002602001015160000181905250611a3d84604001518281518110611a3057611a306144d1565b6020026020010151612ba3565b838281518110611a4f57611a4f6144d1565b6020026020010151608001906001811115611a6c57611a6c6147b9565b90816001811115611a7f57611a7f6147b9565b81525050611af785848381518110611a9957611a996144d1565b602002602001015160800151858481518110611ab757611ab76144d1565b602002602001015160000151602001518760a001518581518110611add57611add6144d1565b602002602001015151886000015189602001516001612c4e565b838281518110611b0957611b096144d1565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050611b7b84604001518281518110611b5057611b506144d1565b602002602001015185608001518381518110611b6e57611b6e6144d1565b6020026020010151612c99565b838281518110611b8d57611b8d6144d1565b602002602001015160e0018181525050611bfb84604001518281518110611bb657611bb66144d1565b602002602001015185608001518381518110611bd457611bd46144d1565b6020026020010151858481518110611bee57611bee6144d1565b6020026020010151612ccc565b848381518110611c0d57611c0d6144d1565b6020026020010151602001858481518110611c2a57611c2a6144d1565b6020026020010151610100018281525082151515158152505050828181518110611c5657611c566144d1565b60200260200101516020015115611c7957611c726001836147e8565b9150611c7e565b611d97565b611ce4838281518110611c9357611c936144d1565b6020026020010151600001516060015185606001518381518110611cb957611cb96144d1565b60200260200101518660a001518481518110611cd757611cd76144d1565b6020026020010151612676565b848381518110611cf657611cf66144d1565b6020026020010151606001858481518110611d1357611d136144d1565b602002602001015160a0018281525082151515158152505050828181518110611d3e57611d3e6144d1565b602002602001015160a0015186611d559190614803565b9550611d9784604001518281518110611d7057611d706144d1565b6020026020010151848381518110611d8a57611d8a6144d1565b6020026020010151612e57565b80611da181614500565b9150506118ef565b508061ffff16600003611dc05750505050506121ab565b8351611dcd9060016147a0565b611ddc9060ff1661044c614816565b616b6c611dea8d6010614816565b5a611df59089614803565b611dff9190614495565b611e099190614495565b611e139190614495565b9450611b58611e2661ffff831687614882565b611e309190614495565b945060008060008060005b87604001515181101561204d57868181518110611e5a57611e5a6144d1565b6020026020010151602001511561203b57611eb68a888381518110611e8157611e816144d1565b6020026020010151608001518a60a001518481518110611ea357611ea36144d1565b6020026020010151518c60000151612f40565b878281518110611ec857611ec86144d1565b602002602001015160c0018181525050611f248989604001518381518110611ef257611ef26144d1565b6020026020010151898481518110611f0c57611f0c6144d1565b60200260200101518b600001518c602001518b612f60565b9093509150611f338285614470565b9350611f3f8386614470565b9450868181518110611f5357611f536144d1565b602002602001015160600151151588604001518281518110611f7757611f776144d1565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c68486611fac9190614470565b8a8581518110611fbe57611fbe6144d1565b602002602001015160a001518b8681518110611fdc57611fdc6144d1565b602002602001015160c001518c8781518110611ffa57611ffa6144d1565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b8061204581614500565b915050611e3b565b5050336000908152600b6020526040902080548492506002906120859084906201000090046bffffffffffffffffffffffff16614470565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff166120df9190614470565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f600160038110612122576121226144d1565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff1611156121a157601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6121d6868686868060200190518101906121cf9190614931565b868661063f565b505050505050565b6121e66121f2565b6121ef81613053565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314612273576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e010000000000000000000000000000900490911660608201529061247157600081606001518561230d9190614a8b565b9050600061231b8583614ab0565b9050808360400181815161232f9190614470565b6bffffffffffffffffffffffff1690525061234a8582614adb565b8360600181815161235b9190614470565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156124b5576124b56147b9565b0361252f57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612506573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061252a9190614b0f565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a60405160200161255899989796959493929190614b28565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006125e8825490565b92915050565b60006124788383613148565b60006124788373ffffffffffffffffffffffffffffffffffffffff8416613172565b60006124788373ffffffffffffffffffffffffffffffffffffffff841661326c565b3215612273576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60125460009081906f01000000000000000000000000000000900460ff16156126cb576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b0000000000000000000000000000000000000000000000000000000090612738908590602401613cbe565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d169061280b9087908790600401614bbd565b60408051808303816000875af1158015612829573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061284d9190614bd6565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b60008787604051612893929190614c09565b6040519081900381206128aa918b90602001614c19565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b88811015612a8157600185878360208110612916576129166144d1565b61292391901a601b6147a0565b8c8c85818110612935576129356144d1565b905060200201358b8b8681811061294e5761294e6144d1565b905060200201356040516000815260200160405260405161298b949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156129ad573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff8082161515808552610100909204169383019390935290955093509050612a5b576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b840193508080612a7990614500565b9150506128f9565b50827e01010101010101010101010101010101010101010101010101010101010101841614612adc576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b612b236040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6000612b3183850185614d0a565b6040810151516060820151519192509081141580612b5457508082608001515114155b80612b645750808260a001515114155b15612b9b576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b509392505050565b6000818160045b600f811015612c30577fff000000000000000000000000000000000000000000000000000000000000008216838260208110612be857612be86144d1565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612c1e57506000949350505050565b80612c2881614500565b915050612baa565b5081600f1a6001811115612c4657612c466147b9565b949350505050565b600080612c6088878b600001516132bb565b9050600080612c7b8b8a63ffffffff16858a8a60018b613347565b9092509050612c8a8183614470565b9b9a5050505050505050505050565b60008282604051602001612cae929190614df7565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612ce757612ce76147b9565b03612d0b57612cf78686866137a0565b612d06576000925090506115c6565b612d82565b600184608001516001811115612d2357612d236147b9565b03612d50576000612d358787876138a0565b9250905080612d4a57506000925090506115c6565b50612d82565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d8a61247f565b84516040015163ffffffff1611612de457857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e00151604051612dd191815260200190565b60405180910390a26000925090506115c6565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff161015612e4a57857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e00151604051612dd191815260200190565b6001969095509350505050565b600081608001516001811115612e6f57612e6f6147b9565b03612ee157612e7c61247f565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612ef957612ef96147b9565b03612f3c57610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612f4d8484846132bb565b905080851015612c465750929392505050565b600080612f7b888760a001518860c001518888886001613347565b90925090506000612f8c8284614470565b600089815260046020526040902060010180549192508291600c90612fd09084906c0100000000000000000000000090046bffffffffffffffffffffffff16614a8b565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a81526004602052604081206001018054859450909261301991859116614470565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036130d2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600082600001828154811061315f5761315f6144d1565b9060005260206000200154905092915050565b6000818152600183016020526040812054801561325b576000613196600183614803565b85549091506000906131aa90600190614803565b905081811461320f5760008660000182815481106131ca576131ca6144d1565b90600052602060002001549050808760000184815481106131ed576131ed6144d1565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061322057613220614e1d565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506125e8565b60009150506125e8565b5092915050565b60008181526001830160205260408120546132b3575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556125e8565b5060006125e8565b600080808560018111156132d1576132d16147b9565b036132e0575062015f906132ff565b60018560018111156132f4576132f46147b9565b03612d5057506201adb05b61331063ffffffff85166014614816565b61331b8460016147a0565b61332a9060ff16611d4c614816565b6133349083614495565b61333e9190614495565b95945050505050565b6000806000896080015161ffff16876133609190614816565b905083801561336e5750803a105b1561337657503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156133ac576133ac6147b9565b0361350b57604080516000815260208101909152851561340a57600036604051806080016040528060488152602001614fae604891396040516020016133f493929190614e4c565b6040516020818303038152906040529050613472565b60155461342690640100000000900463ffffffff166004614e73565b63ffffffff1667ffffffffffffffff81111561344457613444613da3565b6040519080825280601f01601f19166020018201604052801561346e576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e906134c2908490600401613cbe565b602060405180830381865afa1580156134df573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135039190614b0f565b915050613665565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561353f5761353f6147b9565b036136655784156135c157606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613596573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135ba9190614b0f565b9050613665565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801561360f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906136339190614e96565b505060155492945061365693505050640100000000900463ffffffff1682614816565b613661906010614816565b9150505b8461368157808b6080015161ffff1661367e9190614816565b90505b61368f61ffff871682614882565b90506000878261369f8c8e614495565b6136a99086614816565b6136b39190614495565b6136c590670de0b6b3a7640000614816565b6136cf9190614882565b905060008c6040015163ffffffff1664e8d4a510006136ee9190614816565b898e6020015163ffffffff16858f886137079190614816565b6137119190614495565b61371f90633b9aca00614816565b6137299190614816565b6137339190614882565b61373d9190614495565b90506b033b2e3c9fd0803ce80000006137568284614495565b111561378e576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906137b79190614ee0565b835160c00151815191925063ffffffff9081169116101561381a57847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e0015160405161380891815260200190565b60405180910390a26000915050612478565b60208101511580159061384157506020810151815161383e9063ffffffff16613a39565b14155b8061385a575061384f61247f565b815163ffffffff1610155b1561389557847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e0015160405161380891815260200190565b506001949350505050565b6000806000848060200190518101906138b99190614f38565b90506000868260000151836020015160405160200161391093929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101206060830151909150158015906139725750816060015161396f836040015163ffffffff16613a39565b14155b8061398e575061398061247f565b826040015163ffffffff1610155b156139de57867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e001516040516139c991815260200190565b60405180910390a26000935091506115c69050565b60008181526008602052604090205460ff1615613a2b57867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e001516040516139c991815260200190565b600197909650945050505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a6f57613a6f6147b9565b03613b89576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613ac2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ae69190614b0f565b90508083101580613b015750610100613aff8483614803565b115b15613b0f5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b65573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124789190614b0f565b504090565b919050565b50805460008255906000526020600020908101906121ef9190613c3b565b828054828255906000526020600020908101928215613c2b579160200282015b82811115613c2b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613bd1565b50613c37929150613c3b565b5090565b5b80821115613c375760008155600101613c3c565b60005b83811015613c6b578181015183820152602001613c53565b50506000910152565b60008151808452613c8c816020860160208601613c50565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006124786020830184613c74565b73ffffffffffffffffffffffffffffffffffffffff811681146121ef57600080fd5b8035613b8e81613cd1565b60008083601f840112613d1057600080fd5b50813567ffffffffffffffff811115613d2857600080fd5b602083019150836020828501011115613d4057600080fd5b9250929050565b60008060008060608587031215613d5d57600080fd5b8435613d6881613cd1565b935060208501359250604085013567ffffffffffffffff811115613d8b57600080fd5b613d9787828801613cfe565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613df657613df6613da3565b60405290565b60405160c0810167ffffffffffffffff81118282101715613df657613df6613da3565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e6657613e66613da3565b604052919050565b600067ffffffffffffffff821115613e8857613e88613da3565b5060051b60200190565b600082601f830112613ea357600080fd5b81356020613eb8613eb383613e6e565b613e1f565b82815260059290921b84018101918181019086841115613ed757600080fd5b8286015b84811015613efb578035613eee81613cd1565b8352918301918301613edb565b509695505050505050565b803560ff81168114613b8e57600080fd5b63ffffffff811681146121ef57600080fd5b8035613b8e81613f17565b62ffffff811681146121ef57600080fd5b8035613b8e81613f34565b61ffff811681146121ef57600080fd5b8035613b8e81613f50565b6bffffffffffffffffffffffff811681146121ef57600080fd5b8035613b8e81613f6b565b60006101e08284031215613fa357600080fd5b613fab613dd2565b9050613fb682613f29565b8152613fc460208301613f29565b6020820152613fd560408301613f29565b6040820152613fe660608301613f45565b6060820152613ff760808301613f60565b608082015261400860a08301613f85565b60a082015261401960c08301613f29565b60c082015261402a60e08301613f29565b60e082015261010061403d818401613f29565b9082015261012061404f838201613f29565b9082015261014082810135908201526101608083013590820152610180614077818401613cf3565b908201526101a08281013567ffffffffffffffff81111561409757600080fd5b6140a385828601613e92565b8284015250506101c06140b7818401613cf3565b9082015292915050565b803567ffffffffffffffff81168114613b8e57600080fd5b600082601f8301126140ea57600080fd5b813567ffffffffffffffff81111561410457614104613da3565b61413560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613e1f565b81815284602083860101111561414a57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561418057600080fd5b863567ffffffffffffffff8082111561419857600080fd5b6141a48a838b01613e92565b975060208901359150808211156141ba57600080fd5b6141c68a838b01613e92565b96506141d460408a01613f06565b955060608901359150808211156141ea57600080fd5b6141f68a838b01613f90565b945061420460808a016140c1565b935060a089013591508082111561421a57600080fd5b5061422789828a016140d9565b9150509295509295509295565b60008060006040848603121561424957600080fd5b83359250602084013567ffffffffffffffff81111561426757600080fd5b61427386828701613cfe565b9497909650939450505050565b60008083601f84011261429257600080fd5b50813567ffffffffffffffff8111156142aa57600080fd5b6020830191508360208260051b8501011115613d4057600080fd5b60008060008060008060008060e0898b0312156142e157600080fd5b606089018a8111156142f257600080fd5b8998503567ffffffffffffffff8082111561430c57600080fd5b6143188c838d01613cfe565b909950975060808b013591508082111561433157600080fd5b61433d8c838d01614280565b909750955060a08b013591508082111561435657600080fd5b506143638b828c01614280565b999c989b50969995989497949560c00135949350505050565b60008060008060008060c0878903121561439557600080fd5b863567ffffffffffffffff808211156143ad57600080fd5b6143b98a838b01613e92565b975060208901359150808211156143cf57600080fd5b6143db8a838b01613e92565b96506143e960408a01613f06565b955060608901359150808211156143ff57600080fd5b6141f68a838b016140d9565b60006020828403121561441d57600080fd5b813561247881613cd1565b60006020828403121561443a57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff81811683821601908082111561326557613265614441565b808201808211156125e8576125e8614441565b600060ff821660ff84168160ff04811182151516156144c9576144c9614441565b029392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361453157614531614441565b5060010190565b63ffffffff81811683821601908082111561326557613265614441565b600081518084526020808501945080840160005b8381101561459b57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614569565b509495945050505050565b602081526145bd60208201835163ffffffff169052565b600060208301516145d6604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e083015161010061464f8185018363ffffffff169052565b84015190506101206146688482018363ffffffff169052565b84015190506101406146818482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a06146c48185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526146e4610200860184614555565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b1660408501525080606084015261473a8184018a614555565b9050828103608084015261474e8189614555565b905060ff871660a084015282810360c084015261476b8187613c74565b905067ffffffffffffffff851660e08401528281036101008401526147908185613c74565b9c9b505050505050505050505050565b60ff81811683821601908111156125e8576125e8614441565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff81811683821601908082111561326557613265614441565b818103818111156125e8576125e8614441565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561484e5761484e614441565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261489157614891614853565b500490565b8051613b8e81613f17565b8051613b8e81613f34565b8051613b8e81613f50565b8051613b8e81613f6b565b8051613b8e81613cd1565b600082601f8301126148de57600080fd5b815160206148ee613eb383613e6e565b82815260059290921b8401810191818101908684111561490d57600080fd5b8286015b84811015613efb57805161492481613cd1565b8352918301918301614911565b60006020828403121561494357600080fd5b815167ffffffffffffffff8082111561495b57600080fd5b908301906101e0828603121561497057600080fd5b614978613dd2565b61498183614896565b815261498f60208401614896565b60208201526149a060408401614896565b60408201526149b1606084016148a1565b60608201526149c2608084016148ac565b60808201526149d360a084016148b7565b60a08201526149e460c08401614896565b60c08201526149f560e08401614896565b60e0820152610100614a08818501614896565b90820152610120614a1a848201614896565b9082015261014083810151908201526101608084015190820152610180614a428185016148c2565b908201526101a08381015183811115614a5a57600080fd5b614a66888287016148cd565b8284015250506101c09150614a7c8284016148c2565b91810191909152949350505050565b6bffffffffffffffffffffffff82811682821603908082111561326557613265614441565b60006bffffffffffffffffffffffff80841680614acf57614acf614853565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614b0657614b06614441565b02949350505050565b600060208284031215614b2157600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614b6f8285018b614555565b91508382036080850152614b83828a614555565b915060ff881660a085015283820360c0850152614ba08288613c74565b90861660e085015283810361010085015290506147908185613c74565b828152604060208201526000612c466040830184613c74565b60008060408385031215614be957600080fd5b82518015158114614bf957600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614c4057600080fd5b81356020614c50613eb383613e6e565b82815260059290921b84018101918181019086841115614c6f57600080fd5b8286015b84811015613efb5780358352918301918301614c73565b600082601f830112614c9b57600080fd5b81356020614cab613eb383613e6e565b82815260059290921b84018101918181019086841115614cca57600080fd5b8286015b84811015613efb57803567ffffffffffffffff811115614cee5760008081fd5b614cfc8986838b01016140d9565b845250918301918301614cce565b600060208284031215614d1c57600080fd5b813567ffffffffffffffff80821115614d3457600080fd5b9083019060c08286031215614d4857600080fd5b614d50613dfc565b8235815260208301356020820152604083013582811115614d7057600080fd5b614d7c87828601614c2f565b604083015250606083013582811115614d9457600080fd5b614da087828601614c2f565b606083015250608083013582811115614db857600080fd5b614dc487828601614c8a565b60808301525060a083013582811115614ddc57600080fd5b614de887828601614c8a565b60a08301525095945050505050565b82815260008251614e0f816020850160208701613c50565b919091016020019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b828482376000838201600081528351614e69818360208801613c50565b0195945050505050565b600063ffffffff80831681851681830481118215151615614b0657614b06614441565b60008060008060008060c08789031215614eaf57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614ef257600080fd5b6040516040810181811067ffffffffffffffff82111715614f1557614f15613da3565b6040528251614f2381613f17565b81526020928301519281019290925250919050565b600060808284031215614f4a57600080fd5b6040516080810181811067ffffffffffffffff82111715614f6d57614f6d613da3565b604052825181526020830151614f8281613f17565b60208201526040830151614f9581613f17565b6040820152606092830151928101929092525091905056fe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + Bin: "0x6101406040523480156200001257600080fd5b506040516200547e3803806200547e8339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614fdd620004a16000396000818160d6015261016f0152600050506000818161246001528181613357015281816134ea0152613a1a01526000505060005050600061043b0152614fdd6000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063a931358d11610081578063b1dc65a41161005b578063b1dc65a4146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063a931358d14610262578063aed2e92914610275578063afcb95d71461029f576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613c99565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d22565b610423565b610119610270366004614142565b61063f565b61028861028336600461420f565b611456565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102f63660046142a0565b6115be565b610119610309366004614357565b612190565b61011961031c3660046143e6565b6121b9565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da82840184614403565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff1661444b565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da908590614470565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b6106476121cd565b601f86511115610683576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036106c0576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b845186511415806106df57506106d7846003614483565b60ff16865111155b15610716576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156107ab57610798600e828154811061076f5761076f6144ac565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612250565b50806107a3816144db565b915050610743565b5060008060005b836bffffffffffffffffffffffff168110156108b457600d81815481106107db576107db6144ac565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff90921694509082908110610816576108166144ac565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806108ac816144db565b9150506107b2565b506108c1600d6000613b6e565b6108cd600e6000613b6e565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c51811015610c5157600c60008e8381518110610912576109126144ac565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff161561097d576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106109ae576109ae6144ac565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110610a5657610a566144ac565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250610b1b576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941717919091169290921791909117905580610c49816144db565b9150506108f3565b50508a51610c679150600d9060208d0190613b8c565b508851610c7b90600e9060208c0190613b8c565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff16905061123d61245a565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff93841602178082556001926018916112b89185917801000000000000000000000000000000000000000000000000900416614513565b92506101000a81548163ffffffff021916908363ffffffff1602179055506000886040516020016112e99190614581565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061135290469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f61250f565b60115560005b61136260096125b9565b8110156113925761137f6113776009836125c9565b6009906125d5565b508061138a816144db565b915050611358565b5060005b896101a00151518110156113e9576113d68a6101a0015182815181106113be576113be6144ac565b602002602001015160096125f790919063ffffffff16565b50806113e1816144db565b915050611396565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f604051611440999897969594939291906146e5565b60405180910390a1505050505050505050505050565b600080611461612619565b6012546e010000000000000000000000000000900460ff16156114b0576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f890185900485028101850190955287855290936115af93899089908190840183828082843760009201919091525061265192505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506116ec576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff16611735576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a3514611771576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805161177e90600161477b565b60ff168614158061178f5750858414155b156117c6576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117d68a8a8a8a8a8a8a8a61285c565b60006117e28a8a612ac5565b9050600081604001515167ffffffffffffffff81111561180457611804613d7e565b6040519080825280602002602001820160405280156118d057816020015b6040805161020081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816118225790505b5090506000805b836040015151811015611d845760046000856040015183815181106118fe576118fe6144ac565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c082015283518490839081106119e3576119e36144ac565b602002602001015160000181905250611a1884604001518281518110611a0b57611a0b6144ac565b6020026020010151612b7e565b838281518110611a2a57611a2a6144ac565b6020026020010151608001906001811115611a4757611a47614794565b90816001811115611a5a57611a5a614794565b81525050611ad285848381518110611a7457611a746144ac565b602002602001015160800151858481518110611a9257611a926144ac565b602002602001015160000151602001518760a001518581518110611ab857611ab86144ac565b602002602001015151886000015189602001516001612c29565b838281518110611ae457611ae46144ac565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050611b5684604001518281518110611b2b57611b2b6144ac565b602002602001015185608001518381518110611b4957611b496144ac565b6020026020010151612c74565b838281518110611b6857611b686144ac565b602002602001015160e0018181525050611bd684604001518281518110611b9157611b916144ac565b602002602001015185608001518381518110611baf57611baf6144ac565b6020026020010151858481518110611bc957611bc96144ac565b6020026020010151612ca7565b848381518110611be857611be86144ac565b6020026020010151602001858481518110611c0557611c056144ac565b6020026020010151610100018281525082151515158152505050828181518110611c3157611c316144ac565b60200260200101516020015115611c5457611c4d6001836147c3565b9150611c59565b611d72565b611cbf838281518110611c6e57611c6e6144ac565b6020026020010151600001516060015185606001518381518110611c9457611c946144ac565b60200260200101518660a001518481518110611cb257611cb26144ac565b6020026020010151612651565b848381518110611cd157611cd16144ac565b6020026020010151606001858481518110611cee57611cee6144ac565b602002602001015160a0018281525082151515158152505050828181518110611d1957611d196144ac565b602002602001015160a0015186611d3091906147de565b9550611d7284604001518281518110611d4b57611d4b6144ac565b6020026020010151848381518110611d6557611d656144ac565b6020026020010151612e32565b80611d7c816144db565b9150506118d7565b508061ffff16600003611d9b575050505050612186565b8351611da890600161477b565b611db79060ff1661044c6147f1565b616b6c611dc58d60106147f1565b5a611dd090896147de565b611dda9190614470565b611de49190614470565b611dee9190614470565b9450611b58611e0161ffff83168761485d565b611e0b9190614470565b945060008060008060005b87604001515181101561202857868181518110611e3557611e356144ac565b6020026020010151602001511561201657611e918a888381518110611e5c57611e5c6144ac565b6020026020010151608001518a60a001518481518110611e7e57611e7e6144ac565b6020026020010151518c60000151612f1b565b878281518110611ea357611ea36144ac565b602002602001015160c0018181525050611eff8989604001518381518110611ecd57611ecd6144ac565b6020026020010151898481518110611ee757611ee76144ac565b60200260200101518b600001518c602001518b612f3b565b9093509150611f0e828561444b565b9350611f1a838661444b565b9450868181518110611f2e57611f2e6144ac565b602002602001015160600151151588604001518281518110611f5257611f526144ac565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c68486611f87919061444b565b8a8581518110611f9957611f996144ac565b602002602001015160a001518b8681518110611fb757611fb76144ac565b602002602001015160c001518c8781518110611fd557611fd56144ac565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b80612020816144db565b915050611e16565b5050336000908152600b6020526040902080548492506002906120609084906201000090046bffffffffffffffffffffffff1661444b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff166120ba919061444b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f6001600381106120fd576120fd6144ac565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff16111561217c57601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6121b1868686868060200190518101906121aa919061490c565b868661063f565b505050505050565b6121c16121cd565b6121ca8161302e565b50565b60005473ffffffffffffffffffffffffffffffffffffffff16331461224e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e010000000000000000000000000000900490911660608201529061244c5760008160600151856122e89190614a66565b905060006122f68583614a8b565b9050808360400181815161230a919061444b565b6bffffffffffffffffffffffff169052506123258582614ab6565b83606001818151612336919061444b565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111561249057612490614794565b0361250a57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156124e1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125059190614aea565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a60405160200161253399989796959493929190614b03565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006125c3825490565b92915050565b60006124538383613123565b60006124538373ffffffffffffffffffffffffffffffffffffffff841661314d565b60006124538373ffffffffffffffffffffffffffffffffffffffff8416613247565b321561224e576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60125460009081906f01000000000000000000000000000000900460ff16156126a6576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b0000000000000000000000000000000000000000000000000000000090612713908590602401613c99565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906127e69087908790600401614b98565b60408051808303816000875af1158015612804573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128289190614bb1565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b6000878760405161286e929190614be4565b604051908190038120612885918b90602001614bf4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b88811015612a5c576001858783602081106128f1576128f16144ac565b6128fe91901a601b61477b565b8c8c85818110612910576129106144ac565b905060200201358b8b86818110612929576129296144ac565b9050602002013560405160008152602001604052604051612966949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015612988573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff8082161515808552610100909204169383019390935290955093509050612a36576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b840193508080612a54906144db565b9150506128d4565b50827e01010101010101010101010101010101010101010101010101010101010101841614612ab7576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b612afe6040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6000612b0c83850185614ce5565b6040810151516060820151519192509081141580612b2f57508082608001515114155b80612b3f5750808260a001515114155b15612b76576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b509392505050565b6000818160045b600f811015612c0b577fff000000000000000000000000000000000000000000000000000000000000008216838260208110612bc357612bc36144ac565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612bf957506000949350505050565b80612c03816144db565b915050612b85565b5081600f1a6001811115612c2157612c21614794565b949350505050565b600080612c3b88878b60000151613296565b9050600080612c568b8a63ffffffff16858a8a60018b613322565b9092509050612c65818361444b565b9b9a5050505050505050505050565b60008282604051602001612c89929190614dd2565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612cc257612cc2614794565b03612ce657612cd286868661377b565b612ce1576000925090506115b6565b612d5d565b600184608001516001811115612cfe57612cfe614794565b03612d2b576000612d1087878761387b565b9250905080612d2557506000925090506115b6565b50612d5d565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d6561245a565b84516040015163ffffffff1611612dbf57857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e00151604051612dac91815260200190565b60405180910390a26000925090506115b6565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff161015612e2557857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e00151604051612dac91815260200190565b6001969095509350505050565b600081608001516001811115612e4a57612e4a614794565b03612ebc57612e5761245a565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612ed457612ed4614794565b03612f1757610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612f28848484613296565b905080851015612c215750929392505050565b600080612f56888760a001518860c001518888886001613322565b90925090506000612f67828461444b565b600089815260046020526040902060010180549192508291600c90612fab9084906c0100000000000000000000000090046bffffffffffffffffffffffff16614a66565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612ff49185911661444b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036130ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600082600001828154811061313a5761313a6144ac565b9060005260206000200154905092915050565b600081815260018301602052604081205480156132365760006131716001836147de565b8554909150600090613185906001906147de565b90508181146131ea5760008660000182815481106131a5576131a56144ac565b90600052602060002001549050808760000184815481106131c8576131c86144ac565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806131fb576131fb614df8565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506125c3565b60009150506125c3565b5092915050565b600081815260018301602052604081205461328e575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556125c3565b5060006125c3565b600080808560018111156132ac576132ac614794565b036132bb575062015f906132da565b60018560018111156132cf576132cf614794565b03612d2b57506201adb05b6132eb63ffffffff851660146147f1565b6132f684600161477b565b6133059060ff16611d4c6147f1565b61330f9083614470565b6133199190614470565b95945050505050565b6000806000896080015161ffff168761333b91906147f1565b90508380156133495750803a105b1561335157503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561338757613387614794565b036134e65760408051600081526020810190915285156133e557600036604051806080016040528060488152602001614f89604891396040516020016133cf93929190614e27565b604051602081830303815290604052905061344d565b60155461340190640100000000900463ffffffff166004614e4e565b63ffffffff1667ffffffffffffffff81111561341f5761341f613d7e565b6040519080825280601f01601f191660200182016040528015613449576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9061349d908490600401613c99565b602060405180830381865afa1580156134ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134de9190614aea565b915050613640565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561351a5761351a614794565b0361364057841561359c57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613571573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135959190614aea565b9050613640565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156135ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061360e9190614e71565b505060155492945061363193505050640100000000900463ffffffff16826147f1565b61363c9060106147f1565b9150505b8461365c57808b6080015161ffff1661365991906147f1565b90505b61366a61ffff87168261485d565b90506000878261367a8c8e614470565b61368490866147f1565b61368e9190614470565b6136a090670de0b6b3a76400006147f1565b6136aa919061485d565b905060008c6040015163ffffffff1664e8d4a510006136c991906147f1565b898e6020015163ffffffff16858f886136e291906147f1565b6136ec9190614470565b6136fa90633b9aca006147f1565b61370491906147f1565b61370e919061485d565b6137189190614470565b90506b033b2e3c9fd0803ce80000006137318284614470565b1115613769576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906137929190614ebb565b835160c00151815191925063ffffffff908116911610156137f557847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e001516040516137e391815260200190565b60405180910390a26000915050612453565b60208101511580159061381c5750602081015181516138199063ffffffff16613a14565b14155b80613835575061382a61245a565b815163ffffffff1610155b1561387057847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e001516040516137e391815260200190565b506001949350505050565b6000806000848060200190518101906138949190614f13565b9050600086826000015183602001516040516020016138eb93929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061394d5750816060015161394a836040015163ffffffff16613a14565b14155b80613969575061395b61245a565b826040015163ffffffff1610155b156139b957867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e001516040516139a491815260200190565b60405180910390a26000935091506115b69050565b60008181526008602052604090205460ff1615613a0657867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e001516040516139a491815260200190565b600197909650945050505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a4a57613a4a614794565b03613b64576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a9d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ac19190614aea565b90508083101580613adc5750610100613ada84836147de565b115b15613aea5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b40573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124539190614aea565b504090565b919050565b50805460008255906000526020600020908101906121ca9190613c16565b828054828255906000526020600020908101928215613c06579160200282015b82811115613c0657825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613bac565b50613c12929150613c16565b5090565b5b80821115613c125760008155600101613c17565b60005b83811015613c46578181015183820152602001613c2e565b50506000910152565b60008151808452613c67816020860160208601613c2b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006124536020830184613c4f565b73ffffffffffffffffffffffffffffffffffffffff811681146121ca57600080fd5b8035613b6981613cac565b60008083601f840112613ceb57600080fd5b50813567ffffffffffffffff811115613d0357600080fd5b602083019150836020828501011115613d1b57600080fd5b9250929050565b60008060008060608587031215613d3857600080fd5b8435613d4381613cac565b935060208501359250604085013567ffffffffffffffff811115613d6657600080fd5b613d7287828801613cd9565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613dd157613dd1613d7e565b60405290565b60405160c0810167ffffffffffffffff81118282101715613dd157613dd1613d7e565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e4157613e41613d7e565b604052919050565b600067ffffffffffffffff821115613e6357613e63613d7e565b5060051b60200190565b600082601f830112613e7e57600080fd5b81356020613e93613e8e83613e49565b613dfa565b82815260059290921b84018101918181019086841115613eb257600080fd5b8286015b84811015613ed6578035613ec981613cac565b8352918301918301613eb6565b509695505050505050565b803560ff81168114613b6957600080fd5b63ffffffff811681146121ca57600080fd5b8035613b6981613ef2565b62ffffff811681146121ca57600080fd5b8035613b6981613f0f565b61ffff811681146121ca57600080fd5b8035613b6981613f2b565b6bffffffffffffffffffffffff811681146121ca57600080fd5b8035613b6981613f46565b60006101e08284031215613f7e57600080fd5b613f86613dad565b9050613f9182613f04565b8152613f9f60208301613f04565b6020820152613fb060408301613f04565b6040820152613fc160608301613f20565b6060820152613fd260808301613f3b565b6080820152613fe360a08301613f60565b60a0820152613ff460c08301613f04565b60c082015261400560e08301613f04565b60e0820152610100614018818401613f04565b9082015261012061402a838201613f04565b9082015261014082810135908201526101608083013590820152610180614052818401613cce565b908201526101a08281013567ffffffffffffffff81111561407257600080fd5b61407e85828601613e6d565b8284015250506101c0614092818401613cce565b9082015292915050565b803567ffffffffffffffff81168114613b6957600080fd5b600082601f8301126140c557600080fd5b813567ffffffffffffffff8111156140df576140df613d7e565b61411060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613dfa565b81815284602083860101111561412557600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561415b57600080fd5b863567ffffffffffffffff8082111561417357600080fd5b61417f8a838b01613e6d565b9750602089013591508082111561419557600080fd5b6141a18a838b01613e6d565b96506141af60408a01613ee1565b955060608901359150808211156141c557600080fd5b6141d18a838b01613f6b565b94506141df60808a0161409c565b935060a08901359150808211156141f557600080fd5b5061420289828a016140b4565b9150509295509295509295565b60008060006040848603121561422457600080fd5b83359250602084013567ffffffffffffffff81111561424257600080fd5b61424e86828701613cd9565b9497909650939450505050565b60008083601f84011261426d57600080fd5b50813567ffffffffffffffff81111561428557600080fd5b6020830191508360208260051b8501011115613d1b57600080fd5b60008060008060008060008060e0898b0312156142bc57600080fd5b606089018a8111156142cd57600080fd5b8998503567ffffffffffffffff808211156142e757600080fd5b6142f38c838d01613cd9565b909950975060808b013591508082111561430c57600080fd5b6143188c838d0161425b565b909750955060a08b013591508082111561433157600080fd5b5061433e8b828c0161425b565b999c989b50969995989497949560c00135949350505050565b60008060008060008060c0878903121561437057600080fd5b863567ffffffffffffffff8082111561438857600080fd5b6143948a838b01613e6d565b975060208901359150808211156143aa57600080fd5b6143b68a838b01613e6d565b96506143c460408a01613ee1565b955060608901359150808211156143da57600080fd5b6141d18a838b016140b4565b6000602082840312156143f857600080fd5b813561245381613cac565b60006020828403121561441557600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156132405761324061441c565b808201808211156125c3576125c361441c565b600060ff821660ff84168160ff04811182151516156144a4576144a461441c565b029392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361450c5761450c61441c565b5060010190565b63ffffffff8181168382160190808211156132405761324061441c565b600081518084526020808501945080840160005b8381101561457657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614544565b509495945050505050565b6020815261459860208201835163ffffffff169052565b600060208301516145b1604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e083015161010061462a8185018363ffffffff169052565b84015190506101206146438482018363ffffffff169052565b840151905061014061465c8482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a061469f8185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526146bf610200860184614530565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526147158184018a614530565b905082810360808401526147298189614530565b905060ff871660a084015282810360c08401526147468187613c4f565b905067ffffffffffffffff851660e084015282810361010084015261476b8185613c4f565b9c9b505050505050505050505050565b60ff81811683821601908111156125c3576125c361441c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156132405761324061441c565b818103818111156125c3576125c361441c565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156148295761482961441c565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261486c5761486c61482e565b500490565b8051613b6981613ef2565b8051613b6981613f0f565b8051613b6981613f2b565b8051613b6981613f46565b8051613b6981613cac565b600082601f8301126148b957600080fd5b815160206148c9613e8e83613e49565b82815260059290921b840181019181810190868411156148e857600080fd5b8286015b84811015613ed65780516148ff81613cac565b83529183019183016148ec565b60006020828403121561491e57600080fd5b815167ffffffffffffffff8082111561493657600080fd5b908301906101e0828603121561494b57600080fd5b614953613dad565b61495c83614871565b815261496a60208401614871565b602082015261497b60408401614871565b604082015261498c6060840161487c565b606082015261499d60808401614887565b60808201526149ae60a08401614892565b60a08201526149bf60c08401614871565b60c08201526149d060e08401614871565b60e08201526101006149e3818501614871565b908201526101206149f5848201614871565b9082015261014083810151908201526101608084015190820152610180614a1d81850161489d565b908201526101a08381015183811115614a3557600080fd5b614a41888287016148a8565b8284015250506101c09150614a5782840161489d565b91810191909152949350505050565b6bffffffffffffffffffffffff8281168282160390808211156132405761324061441c565b60006bffffffffffffffffffffffff80841680614aaa57614aaa61482e565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614ae157614ae161441c565b02949350505050565b600060208284031215614afc57600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614b4a8285018b614530565b91508382036080850152614b5e828a614530565b915060ff881660a085015283820360c0850152614b7b8288613c4f565b90861660e0850152838103610100850152905061476b8185613c4f565b828152604060208201526000612c216040830184613c4f565b60008060408385031215614bc457600080fd5b82518015158114614bd457600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614c1b57600080fd5b81356020614c2b613e8e83613e49565b82815260059290921b84018101918181019086841115614c4a57600080fd5b8286015b84811015613ed65780358352918301918301614c4e565b600082601f830112614c7657600080fd5b81356020614c86613e8e83613e49565b82815260059290921b84018101918181019086841115614ca557600080fd5b8286015b84811015613ed657803567ffffffffffffffff811115614cc95760008081fd5b614cd78986838b01016140b4565b845250918301918301614ca9565b600060208284031215614cf757600080fd5b813567ffffffffffffffff80821115614d0f57600080fd5b9083019060c08286031215614d2357600080fd5b614d2b613dd7565b8235815260208301356020820152604083013582811115614d4b57600080fd5b614d5787828601614c0a565b604083015250606083013582811115614d6f57600080fd5b614d7b87828601614c0a565b606083015250608083013582811115614d9357600080fd5b614d9f87828601614c65565b60808301525060a083013582811115614db757600080fd5b614dc387828601614c65565b60a08301525095945050505050565b82815260008251614dea816020850160208701613c2b565b919091016020019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b828482376000838201600081528351614e44818360208801613c2b565b0195945050505050565b600063ffffffff80831681851681830481118215151615614ae157614ae161441c565b60008060008060008060c08789031215614e8a57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614ecd57600080fd5b6040516040810181811067ffffffffffffffff82111715614ef057614ef0613d7e565b6040528251614efe81613ef2565b81526020928301519281019290925250919050565b600060808284031215614f2557600080fd5b6040516080810181811067ffffffffffffffff82111715614f4857614f48613d7e565b604052825181526020830151614f5d81613ef2565b60208201526040830151614f7081613ef2565b6040820152606092830151928101929092525091905056fe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryABI = KeeperRegistryMetaData.ABI diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index d7e7d74ffc2..5501c937962 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -19,19 +19,19 @@ flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../cont functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 -i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 35e8ad434d27f8b23c8e759c1ca2d05aff99ccb2589edac8f87ea3c1312a7255 +i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 5a25a405fb683c2d4eab19c0ac15490b324034a08dee2dc7622e949176cca03c i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 keeper_registry_logic1_3: ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin 0176d7abdb01b370c5bf4f670d9abf85ca10aff53b1f7bdad41f85fabe666020 keeper_registry_logic2_0: ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin d69d2bc8e4844293dbc2d45abcddc50b84c88554ecccfa4fa77c0ca45ec80871 -keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 41119855ff05ac7f0b7c0c4ed8d0c7968411b597bddb5c36246a7ccf28631f13 -keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 3a1a5efbcd1cf65e6e591b7b8c897f7bf8bde5a43376edfe78dd9e7a7415f40e +keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 56b35d4ec381125da58ce6ab7166553df18c0367e4b92402e3436212b8e732c1 +keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 4c83988955df4e91a5ee154d741982edf4796fd0836a05172ce289d20b6d4b97 keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin 6ce079f2738f015f7374673a2816e8e9787143d00b780ea7652c8aa9ad9e1e20 keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 -keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 7c0ef55da830b137a89a6e3d58ffb38385fb1c6ed84d0168eebedef598fd2a0f +keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin a36bdb08793747e81fe936a855276d0b61e20531b900aea86bed997a43a37d24 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 From 695d82c4f3aa4ae1c459d9c22ec8c141212fc93d Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Wed, 26 Jul 2023 19:34:47 -0400 Subject: [PATCH 009/270] 2.1 cleanup p2 (#9945) --- .../automation/2_1/KeeperRegistryBase2_1.sol | 54 +++++++++---------- .../2_1/KeeperRegistryLogicB2_1.sol | 8 --- .../automation/2_1/UpkeepTranscoder4_0.sol | 6 +-- .../2_1/interfaces/IKeeperRegistryMaster.sol | 8 +-- .../v0.8/automation/KeeperRegistry2_1.test.ts | 7 ++- .../automation/UpkeepTranscoder4_0.test.ts | 6 --- .../i_keeper_registry_master_wrapper_2_1.go | 50 +---------------- .../keeper_registry_logic_b_wrapper_2_1.go | 52 +----------------- ...rapper-dependency-versions-do-not-edit.txt | 4 +- 9 files changed, 38 insertions(+), 157 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index dc2f66fada7..db6d1acd26d 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -51,8 +51,6 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { bytes internal constant L1_FEE_DATA_PADDING = "0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff"; - uint256 internal constant TRANSMIT_GAS_OVERHEAD = 1_000_000; // Used only by offchain caller - uint256 internal constant CHECK_GAS_OVERHEAD = 400_000; // Used only by offchain caller uint256 internal constant REGISTRY_CONDITIONAL_OVERHEAD = 90_000; // Used in maxPayment estimation, and in capping overheads during actual payment uint256 internal constant REGISTRY_LOG_OVERHEAD = 110_000; // Used only in maxPayment estimation, and in capping overheads during actual payment. uint256 internal constant REGISTRY_PER_PERFORM_BYTE_GAS_OVERHEAD = 20; // Used only in maxPayment estimation, and in capping overheads during actual payment. Value scales with performData length. @@ -106,18 +104,28 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { error ArrayHasNoEntries(); error CannotCancel(); + error CheckDataExceedsLimit(); + error ConfigDigestMismatch(); error DuplicateEntry(); + error DuplicateSigners(); error GasLimitCanOnlyIncrease(); error GasLimitOutsideRange(); + error IncorrectNumberOfFaultyOracles(); + error IncorrectNumberOfSignatures(); + error IncorrectNumberOfSigners(); error IndexOutOfRange(); error InsufficientFunds(); error InvalidDataLength(); error InvalidTrigger(); error InvalidPayee(); error InvalidRecipient(); + error InvalidReport(); error InvalidTriggerType(); + error MaxCheckDataSizeCanOnlyIncrease(); + error MaxPerformDataSizeCanOnlyIncrease(); error MigrationNotPermitted(); error NotAContract(); + error OnlyActiveSigners(); error OnlyActiveTransmitters(); error OnlyCallableByAdmin(); error OnlyCallableByLINKToken(); @@ -131,28 +139,18 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { error OnlyUnpausedUpkeep(); error ParameterLengthError(); error PaymentGreaterThanAllLINK(); + error ReentrantCall(); + error RegistryPaused(); + error RepeatedSigner(); + error RepeatedTransmitter(); error TargetCheckReverted(bytes reason); + error TooManyOracles(); error TranscoderNotSet(); + error UpkeepAlreadyExists(); error UpkeepCancelled(); error UpkeepNotCanceled(); error UpkeepNotNeeded(); error ValueNotChanged(); - error ConfigDigestMismatch(); - error IncorrectNumberOfSignatures(); - error OnlyActiveSigners(); - error DuplicateSigners(); - error TooManyOracles(); - error IncorrectNumberOfSigners(); - error IncorrectNumberOfFaultyOracles(); - error RepeatedSigner(); - error RepeatedTransmitter(); - error CheckDataExceedsLimit(); - error MaxCheckDataSizeCanOnlyIncrease(); - error MaxPerformDataSizeCanOnlyIncrease(); - error InvalidReport(); - error RegistryPaused(); - error ReentrantCall(); - error UpkeepAlreadyExists(); enum MigrationPermission { NONE, @@ -407,22 +405,25 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { } event AdminPrivilegeConfigSet(address indexed admin, bytes privilegeConfig); + event CancelledUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); event FundsAdded(uint256 indexed id, address indexed from, uint96 amount); event FundsWithdrawn(uint256 indexed id, uint256 amount, address to); + event InsufficientFundsUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); event OwnerFundsWithdrawn(uint96 amount); + event Paused(address account); event PayeesUpdated(address[] transmitters, address[] payees); event PayeeshipTransferRequested(address indexed transmitter, address indexed from, address indexed to); event PayeeshipTransferred(address indexed transmitter, address indexed from, address indexed to); event PaymentWithdrawn(address indexed transmitter, uint256 indexed amount, address indexed to, address payee); - event UpkeepPrivilegeConfigSet(uint256 indexed id, bytes privilegeConfig); - event UpkeepAdminTransferRequested(uint256 indexed id, address indexed from, address indexed to); + event ReorgedUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event StaleUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); event UpkeepAdminTransferred(uint256 indexed id, address indexed from, address indexed to); + event UpkeepAdminTransferRequested(uint256 indexed id, address indexed from, address indexed to); event UpkeepCanceled(uint256 indexed id, uint64 indexed atBlockHeight); event UpkeepCheckDataSet(uint256 indexed id, bytes newCheckData); event UpkeepGasLimitSet(uint256 indexed id, uint96 gasLimit); - event UpkeepOffchainConfigSet(uint256 indexed id, bytes offchainConfig); - event UpkeepTriggerConfigSet(uint256 indexed id, bytes triggerConfig); event UpkeepMigrated(uint256 indexed id, uint256 remainingBalance, address destination); + event UpkeepOffchainConfigSet(uint256 indexed id, bytes offchainConfig); event UpkeepPaused(uint256 indexed id); event UpkeepPerformed( uint256 indexed id, @@ -432,14 +433,11 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { uint256 gasOverhead, bytes32 upkeepTriggerID ); + event UpkeepPrivilegeConfigSet(uint256 indexed id, bytes privilegeConfig); event UpkeepReceived(uint256 indexed id, uint256 startingBalance, address importedFrom); - event UpkeepUnpaused(uint256 indexed id); event UpkeepRegistered(uint256 indexed id, uint32 performGas, address admin); - event StaleUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); - event ReorgedUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); - event InsufficientFundsUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); - event CancelledUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); - event Paused(address account); + event UpkeepTriggerConfigSet(uint256 indexed id, bytes triggerConfig); + event UpkeepUnpaused(uint256 indexed id); event Unpaused(address account); /** diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol index 5acc3cb6725..18ec3264dba 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol @@ -256,14 +256,6 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { // GETTERS // ///////////// - function getTransmitGasOverhead() external pure returns (uint256) { - return TRANSMIT_GAS_OVERHEAD; - } - - function getCheckGasOverhead() external pure returns (uint256) { - return CHECK_GAS_OVERHEAD; - } - function getConditionalGasOverhead() external pure returns (uint256) { return REGISTRY_CONDITIONAL_OVERHEAD; } diff --git a/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol b/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol index 3547fe703e5..e8bd6c3e1c2 100644 --- a/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol +++ b/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol @@ -148,9 +148,8 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter revert InvalidTranscoding(); } // bit of a hack - transcodeUpkeeps should be a pure function - AutomationRegistryBaseInterface registry20 = AutomationRegistryBaseInterface(msg.sender); R21.Upkeep[] memory newUpkeeps = new R21.Upkeep[](ids.length); - bytes[] memory offchainConfigs = new bytes[](ids.length); + bytes[] memory emptyBytes = new bytes[](ids.length); address[] memory targets = new address[](ids.length); UpkeepV20 memory upkeepV20; for (uint256 idx = 0; idx < ids.length; idx++) { @@ -165,9 +164,8 @@ contract UpkeepTranscoder4_0 is UpkeepTranscoderInterfaceV2, TypeAndVersionInter lastPerformedBlockNumber: 0 }); targets[idx] = upkeepV20.target; - offchainConfigs[idx] = registry20.getUpkeep(ids[idx]).offchainConfig; } - return abi.encode(ids, newUpkeeps, targets, admins, checkDatas, new bytes[](ids.length), offchainConfigs); + return abi.encode(ids, newUpkeeps, targets, admins, checkDatas, emptyBytes, emptyBytes); } // v2.1 => v2.1 if (fromVersion == uint8(RegistryVersion.V21)) { diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol index 6a31ed9317c..4bb311c17f0 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol @@ -1,4 +1,4 @@ -// abi-checksum: 0xd6afaa401e56004015d2d8e11158ae6f810ee421a634423a6e9533f09fa544c6 +// abi-checksum: 0xd9f033314bb5bd344295bf9d6a633daaf42f2768b27d4595db0918489938fa58 // SPDX-License-Identifier: MIT // !! THIS FILE WAS AUTOGENERATED BY abi-to-sol v0.6.6. SEE SOURCE BELOW. !! pragma solidity ^0.8.4; @@ -232,8 +232,6 @@ interface IKeeperRegistryMaster { function getCancellationDelay() external pure returns (uint256); - function getCheckGasOverhead() external pure returns (uint256); - function getConditionalGasOverhead() external pure returns (uint256); function getFastGasFeedAddress() external view returns (address); @@ -273,8 +271,6 @@ interface IKeeperRegistryMaster { uint8 f ); - function getTransmitGasOverhead() external pure returns (uint256); - function getTransmitterInfo( address query ) external view returns (bool active, uint8 index, uint96 balance, uint96 lastCollected, address payee); @@ -374,5 +370,5 @@ interface KeeperRegistryBase2_1 { // THIS FILE WAS AUTOGENERATED FROM THE FOLLOWING ABI JSON: /* -[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getCheckGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getTransmitGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] */ diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index cbd60c8d12f..044a6fad25d 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -86,8 +86,6 @@ type Log = Parameters[0] // ----------------------------------------------------------------------------------------------- // These values should match the constants declared in registry -let transmitGasOverhead: BigNumber -let checkGasOverhead: BigNumber let registryConditionalOverhead: BigNumber let registryLogOverhead: BigNumber let registryPerSignerGasOverhead: BigNumber @@ -113,6 +111,9 @@ const emptyBytes = '0x' const emptyBytes32 = '0x0000000000000000000000000000000000000000000000000000000000000000' +const transmitGasOverhead = 1_000_000 +const checkGasOverhead = 400_000 + const stalenessSeconds = BigNumber.from(43820) const gasCeilingMultiplier = BigNumber.from(2) const checkGasLimit = BigNumber.from(10000000) @@ -924,8 +925,6 @@ describe('KeeperRegistry2_1', () => { gasPriceFeed.address, ) - transmitGasOverhead = await registry.getTransmitGasOverhead() - checkGasOverhead = await registry.getCheckGasOverhead() registryConditionalOverhead = await registry.getConditionalGasOverhead() registryLogOverhead = await registry.getLogGasOverhead() registryPerSignerGasOverhead = await registry.getPerSignerGasOverhead() diff --git a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts index 9f58a7f47f6..5eac53f05c9 100644 --- a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts +++ b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts @@ -606,9 +606,6 @@ describe('UpkeepTranscoder4_0', () => { expect((await registry20.getUpkeep(id20)).checkData).to.equal( randomBytes, ) - expect((await registry20.getUpkeep(id20)).offchainConfig).to.equal( - randomBytes, - ) expect((await registry20.getState()).state.numUpkeeps).to.equal(1) await registry20 @@ -631,9 +628,6 @@ describe('UpkeepTranscoder4_0', () => { expect((await registry21.getUpkeep(id20)).checkData).to.equal( randomBytes, ) - expect((await registry21.getUpkeep(id20)).offchainConfig).to.equal( - randomBytes, - ) expect(await registry21.getUpkeepTriggerConfig(id20)).to.equal('0x') }) }) diff --git a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go index 527e193569b..99936b95fe2 100644 --- a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go +++ b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var IKeeperRegistryMasterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var IKeeperRegistryMasterABI = IKeeperRegistryMasterMetaData.ABI @@ -328,28 +328,6 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetCancellatio return _IKeeperRegistryMaster.Contract.GetCancellationDelay(&_IKeeperRegistryMaster.CallOpts) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) GetCheckGasOverhead(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _IKeeperRegistryMaster.contract.Call(opts, &out, "getCheckGasOverhead") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) GetCheckGasOverhead() (*big.Int, error) { - return _IKeeperRegistryMaster.Contract.GetCheckGasOverhead(&_IKeeperRegistryMaster.CallOpts) -} - -func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetCheckGasOverhead() (*big.Int, error) { - return _IKeeperRegistryMaster.Contract.GetCheckGasOverhead(&_IKeeperRegistryMaster.CallOpts) -} - func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) GetConditionalGasOverhead(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} err := _IKeeperRegistryMaster.contract.Call(opts, &out, "getConditionalGasOverhead") @@ -699,28 +677,6 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetState() (Ge return _IKeeperRegistryMaster.Contract.GetState(&_IKeeperRegistryMaster.CallOpts) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) GetTransmitGasOverhead(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _IKeeperRegistryMaster.contract.Call(opts, &out, "getTransmitGasOverhead") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) GetTransmitGasOverhead() (*big.Int, error) { - return _IKeeperRegistryMaster.Contract.GetTransmitGasOverhead(&_IKeeperRegistryMaster.CallOpts) -} - -func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetTransmitGasOverhead() (*big.Int, error) { - return _IKeeperRegistryMaster.Contract.GetTransmitGasOverhead(&_IKeeperRegistryMaster.CallOpts) -} - func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) GetTransmitterInfo(opts *bind.CallOpts, query common.Address) (GetTransmitterInfo, error) { @@ -5867,8 +5823,6 @@ type IKeeperRegistryMasterInterface interface { GetCancellationDelay(opts *bind.CallOpts) (*big.Int, error) - GetCheckGasOverhead(opts *bind.CallOpts) (*big.Int, error) - GetConditionalGasOverhead(opts *bind.CallOpts) (*big.Int, error) GetFastGasFeedAddress(opts *bind.CallOpts) (common.Address, error) @@ -5903,8 +5857,6 @@ type IKeeperRegistryMasterInterface interface { error) - GetTransmitGasOverhead(opts *bind.CallOpts) (*big.Int, error) - GetTransmitterInfo(opts *bind.CallOpts, query common.Address) (GetTransmitterInfo, error) diff --git a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go index 6f9c65b90bc..7428bd2424e 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go @@ -75,8 +75,8 @@ type KeeperRegistryBase21UpkeepInfo struct { } var KeeperRegistryLogicBMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCheckGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTransmitGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101206040523480156200001257600080fd5b5060405162004fa638038062004fa68339810160408190526200003591620001e9565b84848484843380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000121565b505050846002811115620000dc57620000dc6200025e565b60e0816002811115620000f357620000f36200025e565b9052506001600160a01b0393841660805291831660a052821660c05216610100525062000274945050505050565b336001600160a01b038216036200017b5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001e457600080fd5b919050565b600080600080600060a086880312156200020257600080fd5b8551600381106200021257600080fd5b94506200022260208701620001cc565b93506200023260408701620001cc565b92506200024260608701620001cc565b91506200025260808701620001cc565b90509295509295909350565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051614ca7620002ff60003960006105680152600081816105060152818161333c015281816138bf0152613a520152600081816105d501526131300152600081816106fd015261320a01526000818161078b01528181611b9501528181611e6b015281816122d8015281816127eb015261286f0152614ca76000f3fe608060405234801561001057600080fd5b50600436106103415760003560e01c806379ba5097116101bd578063b148ab6b116100f9578063cd7f71b5116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107de578063ed56b3e1146107f1578063f2fde38b14610864578063faa3e9961461087757600080fd5b8063cd7f71b5146107af578063d2b441ab146107c2578063d7632648146107cb57600080fd5b8063b79550be116100d3578063b79550be14610761578063c7c3a19a14610769578063ca30e6031461078957600080fd5b8063b148ab6b14610734578063b6511a2a14610747578063b657bc9c1461074e57600080fd5b80638dcf0fe711610166578063aab9edd611610140578063aab9edd6146106e4578063abc76ae0146106f3578063b10b673c146106fb578063b121e1471461072157600080fd5b80638dcf0fe7146106ab578063a710b221146106be578063a72aa27e146106d157600080fd5b80638456cb59116101975780638456cb59146106725780638765ecbe1461067a5780638da5cb5b1461068d57600080fd5b806379ba50971461061f57806379ea9943146106275780637d9b97e01461066a57600080fd5b80633f4ba83a1161028c5780635165f2f5116102355780636209e1e91161020f5780636209e1e9146105c05780636709d0e5146105d3578063671d36ed146105f9578063744bfe611461060c57600080fd5b80635165f2f5146105535780635425d8ac146105665780635b6aa71c146105ad57600080fd5b80634b4fd03b116102665780634b4fd03b146105045780634ca16c521461052a5780635147cd591461053357600080fd5b80633f4ba83a14610486578063421d183b1461048e57806348013d7b146104f457600080fd5b80631a2af011116102ee578063232c1cc5116102c8578063232c1cc5146104635780632d9c718f1461046a5780633b9cce591461047357600080fd5b80631a2af011146103df5780631e010439146103f2578063207b65161461045057600080fd5b80631865c57d1161031f5780631865c57d14610393578063187256e8146103ac57806319d97a94146103bf57600080fd5b8063050ee65d1461034657806306e3b6321461035e5780630b7d33e61461037e575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b61037161036c366004613ddd565b6108bd565b6040516103559190613dff565b61039161038c366004613e8c565b6109da565b005b61039b610a94565b60405161035595949392919061408f565b6103916103ba3660046141c6565b610ead565b6103d26103cd366004614203565b610f1e565b604051610355919061428a565b6103916103ed36600461429d565b610fc0565b610433610400366004614203565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff9091168152602001610355565b6103d261045e366004614203565b6110c6565b601461034b565b62061a8061034b565b6103916104813660046142c2565b6110e3565b610391611339565b6104a161049c366004614337565b61139f565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a001610355565b60005b6040516103559190614393565b7f00000000000000000000000000000000000000000000000000000000000000006104f7565b62015f9061034b565b610546610541366004614203565b6114d2565b60405161035591906143a6565b610391610561366004614203565b6114dd565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610355565b6104336105bb3660046143d3565b611654565b6103d26105ce366004614337565b611786565b7f0000000000000000000000000000000000000000000000000000000000000000610588565b61039161060736600461440c565b6117ba565b61039161061a36600461429d565b611894565b610391611c91565b610588610635366004614203565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b610391611d93565b610391611eee565b610391610688366004614203565b611f5f565b60005473ffffffffffffffffffffffffffffffffffffffff16610588565b6103916106b9366004613e8c565b6120d9565b6103916106cc366004614448565b61212e565b6103916106df366004614476565b6123aa565b60405160038152602001610355565b611d4c61034b565b7f0000000000000000000000000000000000000000000000000000000000000000610588565b61039161072f366004614337565b61249f565b610391610742366004614203565b612597565b603261034b565b61043361075c366004614203565b612785565b6103916127b2565b61077c610777366004614203565b61290e565b6040516103559190614499565b7f0000000000000000000000000000000000000000000000000000000000000000610588565b6103916107bd366004613e8c565b612ce1565b620f424061034b565b6104336107d9366004614203565b612d78565b6103916107ec366004614448565b612d83565b61084b6107ff366004614337565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff909116602083015201610355565b610391610872366004614337565b612ee1565b6108b0610885366004614337565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161035591906145d0565b606060006108cb6002612ef5565b9050808410610906576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006109128486614613565b905081811180610920575083155b61092a578061092c565b815b9050600061093a8683614626565b67ffffffffffffffff81111561095257610952614639565b60405190808252806020026020018201604052801561097b578160200160208202803683370190505b50905060005b81518110156109ce5761099f6109978883614613565b600290612eff565b8282815181106109b1576109b1614668565b6020908102919091010152806109c681614697565b915050610981565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a3b576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a54828483614771565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a8792919061488c565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610be16002612ef5565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d896009612f12565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610e2c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e01575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610e9557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e6a575b50505050509150945094509450945094509091929394565b610eb5612f1f565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610f1557610f15614354565b02179055505050565b6000818152601c60205260409020805460609190610f3b906146cf565b80601f0160208091040260200160405190810160405280929190818152602001828054610f67906146cf565b8015610fb45780601f10610f8957610100808354040283529160200191610fb4565b820191906000526020600020905b815481529060010190602001808311610f9757829003601f168201915b50505050509050919050565b610fc982612fa2565b3373ffffffffffffffffffffffffffffffffffffffff821603611018576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116146110c25760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f3b906146cf565b6110eb612f1f565b600e548114611126576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e548110156112f8576000600e828154811061114857611148614668565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f9092526040832054919350169085858581811061119257611192614668565b90506020020160208101906111a79190614337565b905073ffffffffffffffffffffffffffffffffffffffff8116158061123a575073ffffffffffffffffffffffffffffffffffffffff82161580159061121857508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b801561123a575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611271576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112e25773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b50505080806112f090614697565b915050611129565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e838360405161132d939291906148d9565b60405180910390a15050565b611341612f1f565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015282918291829182919082906114795760608201516012546000916114659170010000000000000000000000000000000090046bffffffffffffffffffffffff1661498b565b600e5490915061147590826149df565b9150505b815160208301516040840151611490908490614a0a565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109d482613056565b6114e681612fa2565b600081815260046020908152604091829020825160e081018452815460ff8116151580835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c0820152906115e5576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055611624600283613101565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c0100000000000000000000000000000000000000000000000000000000909104169181019190915260009081806117538361310d565b9150915061177c838787601360020160049054906101000a900463ffffffff16868660006132eb565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f3b906146cf565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16331461181b576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d6020526040902061184b828483614771565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a8792919061488c565b6012546f01000000000000000000000000000000900460ff16156118e4576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff811661196b576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600460209081526040808320815160e081018352815460ff81161515825263ffffffff610100820481168387015265010000000000820481168386015273ffffffffffffffffffffffffffffffffffffffff6901000000000000000000909204821660608401526001909301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c082015286855260059093529220549091163314611a72576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a7a613336565b816040015163ffffffff161115611abd576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611afd908290614626565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c049190614a2f565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611d17576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611d9b612f1f565b6014546018546bffffffffffffffffffffffff90911690611dbd908290614626565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611eca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110c29190614a2f565b611ef6612f1f565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25890602001611395565b611f6881612fa2565b600081815260046020908152604091829020825160e081018452815460ff8116158015835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c082015290612067576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556120a96002836133eb565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120e283612fa2565b6000838152601b602052604090206120fb828483614771565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a8792919061488c565b73ffffffffffffffffffffffffffffffffffffffff811661217b576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121db576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e5460009161221291859170010000000000000000000000000000000090046bffffffffffffffffffffffff16906133f7565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff16905560185490915061227c906bffffffffffffffffffffffff831690614626565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015612321573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123459190614a2f565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123df575060145463ffffffff7001000000000000000000000000000000009091048116908216115b15612416576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61241f82612fa2565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff8181166000908152601060205260409020541633146124ff576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b600081815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c08201529114612694576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff1633146126f1576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109d461279383613056565b600084815260046020526040902054610100900463ffffffff16611654565b6127ba612f1f565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612847573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061286b9190614a51565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33601854846128b89190614626565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611eab565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e082018190526101008201526101208101919091526000828152600460209081526040808320815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606083018190526001909101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c0820152919015612aa657816060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612a7d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612aa19190614a6a565b612aa9565b60005b90506040518061014001604052808273ffffffffffffffffffffffffffffffffffffffff168152602001836020015163ffffffff168152602001600760008781526020019081526020016000208054612b01906146cf565b80601f0160208091040260200160405190810160405280929190818152602001828054612b2d906146cf565b8015612b7a5780601f10612b4f57610100808354040283529160200191612b7a565b820191906000526020600020905b815481529060010190602001808311612b5d57829003601f168201915b505050505081526020018360a001516bffffffffffffffffffffffff1681526020016005600087815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001836040015163ffffffff1667ffffffffffffffff1681526020018360c0015163ffffffff16815260200183608001516bffffffffffffffffffffffff168152602001836000015115158152602001601b60008781526020019081526020016000208054612c57906146cf565b80601f0160208091040260200160405190810160405280929190818152602001828054612c83906146cf565b8015612cd05780601f10612ca557610100808354040283529160200191612cd0565b820191906000526020600020905b815481529060010190602001808311612cb357829003601f168201915b505050505081525092505050919050565b612cea83612fa2565b60155463ffffffff16811115612d2c576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612d45828483614771565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a8792919061488c565b60006109d482612785565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612de3576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612e32576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152601060205260409020548116908216146110c25773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612ee9612f1f565b612ef2816135ff565b50565b60006109d4825490565b6000612f0b83836136f4565b9392505050565b60606000612f0b8361371e565b60005473ffffffffffffffffffffffffffffffffffffffff163314612fa0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611d0e565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612fff576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612ef2576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f8110156130e3577fff00000000000000000000000000000000000000000000000000000000000000821683826020811061309b5761309b614668565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146130d157506000949350505050565b806130db81614697565b91505061305d565b5081600f1a60018111156130f9576130f9614354565b949350505050565b6000612f0b8383613779565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613199573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131bd9190614aa1565b50945090925050506000811315806131d457508142105b806131f557508280156131f557506131ec8242614626565b8463ffffffff16105b15613204576016549550613208565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613273573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132979190614aa1565b50945090925050506000811315806132ae57508142105b806132cf57508280156132cf57506132c68242614626565b8463ffffffff16105b156132de5760175494506132e2565b8094505b50505050915091565b6000806132fd88878b600001516137c8565b90506000806133188b8a63ffffffff16858a8a60018b61388a565b90925090506133278183614a0a565b9b9a5050505050505050505050565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111561336c5761336c614354565b036133e657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156133bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133e19190614a51565b905090565b504390565b6000612f0b8383613ce3565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906135f357600081606001518561348f919061498b565b9050600061349d85836149df565b905080836040018181516134b19190614a0a565b6bffffffffffffffffffffffff169052506134cc8582614af1565b836060018181516134dd9190614a0a565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361367e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611d0e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600082600001828154811061370b5761370b614668565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610fb457602002820191906000526020600020905b81548152602001906001019080831161375a5750505050509050919050565b60008181526001830160205260408120546137c0575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109d4565b5060006109d4565b600080808560018111156137de576137de614354565b036137ed575062015f90613842565b600185600181111561380157613801614354565b0361381057506201adb0613842565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61385363ffffffff85166014614b25565b61385e846001614b62565b61386d9060ff16611d4c614b25565b6138779083614613565b6138819190614613565b95945050505050565b6000806000896080015161ffff16876138a39190614b25565b90508380156138b15750803a105b156138b957503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156138ef576138ef614354565b03613a4e57604080516000815260208101909152851561394d57600036604051806080016040528060488152602001614c536048913960405160200161393793929190614b7b565b60405160208183030381529060405290506139b5565b60155461396990640100000000900463ffffffff166004614ba2565b63ffffffff1667ffffffffffffffff81111561398757613987614639565b6040519080825280601f01601f1916602001820160405280156139b1576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613a0590849060040161428a565b602060405180830381865afa158015613a22573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a469190614a51565b915050613ba8565b60017f00000000000000000000000000000000000000000000000000000000000000006002811115613a8257613a82614354565b03613ba8578415613b0457606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613ad9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613afd9190614a51565b9050613ba8565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613b52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b769190614bc5565b5050601554929450613b9993505050640100000000900463ffffffff1682614b25565b613ba4906010614b25565b9150505b84613bc457808b6080015161ffff16613bc19190614b25565b90505b613bd261ffff871682614c0f565b905060008782613be28c8e614613565b613bec9086614b25565b613bf69190614613565b613c0890670de0b6b3a7640000614b25565b613c129190614c0f565b905060008c6040015163ffffffff1664e8d4a51000613c319190614b25565b898e6020015163ffffffff16858f88613c4a9190614b25565b613c549190614613565b613c6290633b9aca00614b25565b613c6c9190614b25565b613c769190614c0f565b613c809190614613565b90506b033b2e3c9fd0803ce8000000613c998284614613565b1115613cd1576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613dcc576000613d07600183614626565b8554909150600090613d1b90600190614626565b9050818114613d80576000866000018281548110613d3b57613d3b614668565b9060005260206000200154905080876000018481548110613d5e57613d5e614668565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613d9157613d91614c23565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109d4565b60009150506109d4565b5092915050565b60008060408385031215613df057600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613e3757835183529284019291840191600101613e1b565b50909695505050505050565b60008083601f840112613e5557600080fd5b50813567ffffffffffffffff811115613e6d57600080fd5b602083019150836020828501011115613e8557600080fd5b9250929050565b600080600060408486031215613ea157600080fd5b83359250602084013567ffffffffffffffff811115613ebf57600080fd5b613ecb86828701613e43565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613f1e57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613eec565b509495945050505050565b805163ffffffff16825260006101e06020830151613f4f602086018263ffffffff169052565b506040830151613f67604086018263ffffffff169052565b506060830151613f7e606086018262ffffff169052565b506080830151613f94608086018261ffff169052565b5060a0830151613fb460a08601826bffffffffffffffffffffffff169052565b5060c0830151613fcc60c086018263ffffffff169052565b5060e0830151613fe460e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a08084015181860183905261405983870182613ed8565b925050506101c0808401516140858287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c060208801516140bd60208501826bffffffffffffffffffffffff169052565b506040880151604084015260608801516140e760608501826bffffffffffffffffffffffff169052565b506080880151608084015260a088015161410960a085018263ffffffff169052565b5060c088015161412160c085018263ffffffff169052565b5060e088015160e0840152610100808901516141448286018263ffffffff169052565b505061012088810151151590840152610140830181905261416781840188613f29565b905082810361016084015261417c8187613ed8565b90508281036101808401526141918186613ed8565b91505061177c6101a083018460ff169052565b73ffffffffffffffffffffffffffffffffffffffff81168114612ef257600080fd5b600080604083850312156141d957600080fd5b82356141e4816141a4565b91506020830135600481106141f857600080fd5b809150509250929050565b60006020828403121561421557600080fd5b5035919050565b60005b8381101561423757818101518382015260200161421f565b50506000910152565b6000815180845261425881602086016020860161421c565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612f0b6020830184614240565b600080604083850312156142b057600080fd5b8235915060208301356141f8816141a4565b600080602083850312156142d557600080fd5b823567ffffffffffffffff808211156142ed57600080fd5b818501915085601f83011261430157600080fd5b81358181111561431057600080fd5b8660208260051b850101111561432557600080fd5b60209290920196919550909350505050565b60006020828403121561434957600080fd5b8135612f0b816141a4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612ef257612ef2614354565b602081016143a083614383565b91905290565b60208101600283106143a0576143a0614354565b803563ffffffff811681146143ce57600080fd5b919050565b600080604083850312156143e657600080fd5b8235600281106143f557600080fd5b9150614403602084016143ba565b90509250929050565b60008060006040848603121561442157600080fd5b833561442c816141a4565b9250602084013567ffffffffffffffff811115613ebf57600080fd5b6000806040838503121561445b57600080fd5b8235614466816141a4565b915060208301356141f8816141a4565b6000806040838503121561448957600080fd5b82359150614403602084016143ba565b602081526144c060208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516144d9604084018263ffffffff169052565b5060408301516101408060608501526144f6610160850183614240565b9150606085015161451760808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e0850151610100614583818701836bffffffffffffffffffffffff169052565b86015190506101206145988682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00183870152905061177c8382614240565b60208101600483106143a0576143a0614354565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109d4576109d46145e4565b818103818111156109d4576109d46145e4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036146c8576146c86145e4565b5060010190565b600181811c908216806146e357607f821691505b60208210810361471c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561476c57600081815260208120601f850160051c810160208610156147495750805b601f850160051c820191505b8181101561476857828155600101614755565b5050505b505050565b67ffffffffffffffff83111561478957614789614639565b61479d8361479783546146cf565b83614722565b6000601f8411600181146147ef57600085156147b95750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614885565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561483e578685013582556020948501946001909201910161481e565b5086821015614879577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561493057815473ffffffffffffffffffffffffffffffffffffffff16845292840192600191820191016148fe565b505050838103828501528481528590820160005b8681101561497f578235614957816141a4565b73ffffffffffffffffffffffffffffffffffffffff1682529183019190830190600101614944565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613dd657613dd66145e4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff808416806149fe576149fe6149b0565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613dd657613dd66145e4565b600060208284031215614a4157600080fd5b81518015158114612f0b57600080fd5b600060208284031215614a6357600080fd5b5051919050565b600060208284031215614a7c57600080fd5b8151612f0b816141a4565b805169ffffffffffffffffffff811681146143ce57600080fd5b600080600080600060a08688031215614ab957600080fd5b614ac286614a87565b9450602086015193506040860151925060608601519150614ae560808701614a87565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614b1c57614b1c6145e4565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b5d57614b5d6145e4565b500290565b60ff81811683821601908111156109d4576109d46145e4565b828482376000838201600081528351614b9881836020880161421c565b0195945050505050565b600063ffffffff80831681851681830481118215151615614b1c57614b1c6145e4565b60008060008060008060c08789031215614bde57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614c1e57614c1e6149b0565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101206040523480156200001257600080fd5b5060405162004f7e38038062004f7e8339810160408190526200003591620001e9565b84848484843380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000121565b505050846002811115620000dc57620000dc6200025e565b60e0816002811115620000f357620000f36200025e565b9052506001600160a01b0393841660805291831660a052821660c05216610100525062000274945050505050565b336001600160a01b038216036200017b5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001e457600080fd5b919050565b600080600080600060a086880312156200020257600080fd5b8551600381106200021257600080fd5b94506200022260208701620001cc565b93506200023260408701620001cc565b92506200024260608701620001cc565b91506200025260808701620001cc565b90509295509295909350565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051614c7f620002ff60003960006105490152600081816104e701528181613314015281816138970152613a2a0152600081816105b601526131080152600081816106de01526131e201526000818161076c01528181611b6d01528181611e43015281816122b0015281816127c301526128470152614c7f6000f3fe608060405234801561001057600080fd5b506004361061032b5760003560e01c806379ba5097116101b2578063b121e147116100f9578063ca30e603116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107b6578063ed56b3e1146107c9578063f2fde38b1461083c578063faa3e9961461084f57600080fd5b8063ca30e6031461076a578063cd7f71b514610790578063d7632648146107a357600080fd5b8063b657bc9c116100d3578063b657bc9c1461072f578063b79550be14610742578063c7c3a19a1461074a57600080fd5b8063b121e14714610702578063b148ab6b14610715578063b6511a2a1461072857600080fd5b80638dcf0fe71161015b578063aab9edd611610135578063aab9edd6146106c5578063abc76ae0146106d4578063b10b673c146106dc57600080fd5b80638dcf0fe71461068c578063a710b2211461069f578063a72aa27e146106b257600080fd5b80638456cb591161018c5780638456cb59146106535780638765ecbe1461065b5780638da5cb5b1461066e57600080fd5b806379ba50971461060057806379ea9943146106085780637d9b97e01461064b57600080fd5b8063421d183b116102765780635425d8ac1161021f5780636709d0e5116101f95780636709d0e5146105b4578063671d36ed146105da578063744bfe61146105ed57600080fd5b80635425d8ac146105475780635b6aa71c1461058e5780636209e1e9146105a157600080fd5b80634ca16c52116102505780634ca16c521461050b5780635147cd59146105145780635165f2f51461053457600080fd5b8063421d183b1461046f57806348013d7b146104d55780634b4fd03b146104e557600080fd5b80631a2af011116102d8578063232c1cc5116102b2578063232c1cc51461044d5780633b9cce59146104545780633f4ba83a1461046757600080fd5b80631a2af011146103c95780631e010439146103dc578063207b65161461043a57600080fd5b80631865c57d116103095780631865c57d1461037d578063187256e81461039657806319d97a94146103a957600080fd5b8063050ee65d1461033057806306e3b632146103485780630b7d33e614610368575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b61035b610356366004613db5565b610895565b60405161033f9190613dd7565b61037b610376366004613e64565b6109b2565b005b610385610a6c565b60405161033f959493929190614067565b61037b6103a436600461419e565b610e85565b6103bc6103b73660046141db565b610ef6565b60405161033f9190614262565b61037b6103d7366004614275565b610f98565b61041d6103ea3660046141db565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff909116815260200161033f565b6103bc6104483660046141db565b61109e565b6014610335565b61037b61046236600461429a565b6110bb565b61037b611311565b61048261047d36600461430f565b611377565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a00161033f565b60005b60405161033f919061436b565b7f00000000000000000000000000000000000000000000000000000000000000006104d8565b62015f90610335565b6105276105223660046141db565b6114aa565b60405161033f919061437e565b61037b6105423660046141db565b6114b5565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161033f565b61041d61059c3660046143ab565b61162c565b6103bc6105af36600461430f565b61175e565b7f0000000000000000000000000000000000000000000000000000000000000000610569565b61037b6105e83660046143e4565b611792565b61037b6105fb366004614275565b61186c565b61037b611c69565b6105696106163660046141db565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b61037b611d6b565b61037b611ec6565b61037b6106693660046141db565b611f37565b60005473ffffffffffffffffffffffffffffffffffffffff16610569565b61037b61069a366004613e64565b6120b1565b61037b6106ad366004614420565b612106565b61037b6106c036600461444e565b612382565b6040516003815260200161033f565b611d4c610335565b7f0000000000000000000000000000000000000000000000000000000000000000610569565b61037b61071036600461430f565b612477565b61037b6107233660046141db565b61256f565b6032610335565b61041d61073d3660046141db565b61275d565b61037b61278a565b61075d6107583660046141db565b6128e6565b60405161033f9190614471565b7f0000000000000000000000000000000000000000000000000000000000000000610569565b61037b61079e366004613e64565b612cb9565b61041d6107b13660046141db565b612d50565b61037b6107c4366004614420565b612d5b565b6108236107d736600461430f565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff90911660208301520161033f565b61037b61084a36600461430f565b612eb9565b61088861085d36600461430f565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161033f91906145a8565b606060006108a36002612ecd565b90508084106108de576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006108ea84866145eb565b9050818111806108f8575083155b6109025780610904565b815b9050600061091286836145fe565b67ffffffffffffffff81111561092a5761092a614611565b604051908082528060200260200182016040528015610953578160200160208202803683370190505b50905060005b81518110156109a65761097761096f88836145eb565b600290612ed7565b82828151811061098957610989614640565b60209081029190910101528061099e8161466f565b915050610959565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a13576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a2c828483614749565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a5f929190614864565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610bb96002612ecd565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d616009612eea565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610e0457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dd9575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610e6d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e42575b50505050509150945094509450945094509091929394565b610e8d612ef7565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610eed57610eed61432c565b02179055505050565b6000818152601c60205260409020805460609190610f13906146a7565b80601f0160208091040260200160405190810160405280929190818152602001828054610f3f906146a7565b8015610f8c5780601f10610f6157610100808354040283529160200191610f8c565b820191906000526020600020905b815481529060010190602001808311610f6f57829003601f168201915b50505050509050919050565b610fa182612f7a565b3373ffffffffffffffffffffffffffffffffffffffff821603610ff0576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff82811691161461109a5760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f13906146a7565b6110c3612ef7565b600e5481146110fe576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e548110156112d0576000600e828154811061112057611120614640565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f9092526040832054919350169085858581811061116a5761116a614640565b905060200201602081019061117f919061430f565b905073ffffffffffffffffffffffffffffffffffffffff81161580611212575073ffffffffffffffffffffffffffffffffffffffff8216158015906111f057508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b8015611212575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611249576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112ba5773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b50505080806112c89061466f565b915050611101565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e8383604051611305939291906148b1565b60405180910390a15050565b611319612ef7565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152829182918291829190829061145157606082015160125460009161143d9170010000000000000000000000000000000090046bffffffffffffffffffffffff16614963565b600e5490915061144d90826149b7565b9150505b8151602083015160408401516114689084906149e2565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109ac8261302e565b6114be81612f7a565b600081815260046020908152604091829020825160e081018452815460ff8116151580835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c0820152906115bd576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556115fc6002836130d9565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c01000000000000000000000000000000000000000000000000000000009091041691810191909152600090818061172b836130e5565b91509150611754838787601360020160049054906101000a900463ffffffff16868660006132c3565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f13906146a7565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633146117f3576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d60205260409020611823828483614749565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a5f929190614864565b6012546f01000000000000000000000000000000900460ff16156118bc576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff8116611943576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600460209081526040808320815160e081018352815460ff81161515825263ffffffff610100820481168387015265010000000000820481168386015273ffffffffffffffffffffffffffffffffffffffff6901000000000000000000909204821660608401526001909301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c082015286855260059093529220549091163314611a4a576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a5261330e565b816040015163ffffffff161115611a95576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611ad59082906145fe565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611bb8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bdc9190614a07565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611cef576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611d73612ef7565b6014546018546bffffffffffffffffffffffff90911690611d959082906145fe565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611ea2573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061109a9190614a07565b611ece612ef7565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589060200161136d565b611f4081612f7a565b600081815260046020908152604091829020825160e081018452815460ff8116158015835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201529061203f576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556120816002836133c3565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120ba83612f7a565b6000838152601b602052604090206120d3828483614749565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a5f929190614864565b73ffffffffffffffffffffffffffffffffffffffff8116612153576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121b3576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e546000916121ea91859170010000000000000000000000000000000090046bffffffffffffffffffffffff16906133cf565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff169055601854909150612254906bffffffffffffffffffffffff8316906145fe565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af11580156122f9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061231d9190614a07565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123b7575060145463ffffffff7001000000000000000000000000000000009091048116908216115b156123ee576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6123f782612f7a565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff8181166000908152601060205260409020541633146124d7576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b600081815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c0820152911461266c576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff1633146126c9576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109ac61276b8361302e565b600084815260046020526040902054610100900463ffffffff1661162c565b612792612ef7565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561281f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128439190614a29565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb336018548461289091906145fe565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611e83565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e082018190526101008201526101208101919091526000828152600460209081526040808320815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606083018190526001909101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c0820152919015612a7e57816060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612a55573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a799190614a42565b612a81565b60005b90506040518061014001604052808273ffffffffffffffffffffffffffffffffffffffff168152602001836020015163ffffffff168152602001600760008781526020019081526020016000208054612ad9906146a7565b80601f0160208091040260200160405190810160405280929190818152602001828054612b05906146a7565b8015612b525780601f10612b2757610100808354040283529160200191612b52565b820191906000526020600020905b815481529060010190602001808311612b3557829003601f168201915b505050505081526020018360a001516bffffffffffffffffffffffff1681526020016005600087815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001836040015163ffffffff1667ffffffffffffffff1681526020018360c0015163ffffffff16815260200183608001516bffffffffffffffffffffffff168152602001836000015115158152602001601b60008781526020019081526020016000208054612c2f906146a7565b80601f0160208091040260200160405190810160405280929190818152602001828054612c5b906146a7565b8015612ca85780601f10612c7d57610100808354040283529160200191612ca8565b820191906000526020600020905b815481529060010190602001808311612c8b57829003601f168201915b505050505081525092505050919050565b612cc283612f7a565b60155463ffffffff16811115612d04576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612d1d828483614749565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a5f929190614864565b60006109ac8261275d565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612dbb576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612e0a576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff82811660009081526010602052604090205481169082161461109a5773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612ec1612ef7565b612eca816135d7565b50565b60006109ac825490565b6000612ee383836136cc565b9392505050565b60606000612ee3836136f6565b60005473ffffffffffffffffffffffffffffffffffffffff163314612f78576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611ce6565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612fd7576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612eca576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f8110156130bb577fff00000000000000000000000000000000000000000000000000000000000000821683826020811061307357613073614640565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146130a957506000949350505050565b806130b38161466f565b915050613035565b5081600f1a60018111156130d1576130d161432c565b949350505050565b6000612ee38383613751565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613171573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131959190614a79565b50945090925050506000811315806131ac57508142105b806131cd57508280156131cd57506131c482426145fe565b8463ffffffff16105b156131dc5760165495506131e0565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa15801561324b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061326f9190614a79565b509450909250505060008113158061328657508142105b806132a757508280156132a7575061329e82426145fe565b8463ffffffff16105b156132b65760175494506132ba565b8094505b50505050915091565b6000806132d588878b600001516137a0565b90506000806132f08b8a63ffffffff16858a8a60018b613862565b90925090506132ff81836149e2565b9b9a5050505050505050505050565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156133445761334461432c565b036133be57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613395573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133b99190614a29565b905090565b504390565b6000612ee38383613cbb565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906135cb5760008160600151856134679190614963565b9050600061347585836149b7565b9050808360400181815161348991906149e2565b6bffffffffffffffffffffffff169052506134a48582614ac9565b836060018181516134b591906149e2565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613656576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611ce6565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008260000182815481106136e3576136e3614640565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610f8c57602002820191906000526020600020905b8154815260200190600101908083116137325750505050509050919050565b6000818152600183016020526040812054613798575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109ac565b5060006109ac565b600080808560018111156137b6576137b661432c565b036137c5575062015f9061381a565b60018560018111156137d9576137d961432c565b036137e857506201adb061381a565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61382b63ffffffff85166014614afd565b613836846001614b3a565b6138459060ff16611d4c614afd565b61384f90836145eb565b61385991906145eb565b95945050505050565b6000806000896080015161ffff168761387b9190614afd565b90508380156138895750803a105b1561389157503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156138c7576138c761432c565b03613a2657604080516000815260208101909152851561392557600036604051806080016040528060488152602001614c2b6048913960405160200161390f93929190614b53565b604051602081830303815290604052905061398d565b60155461394190640100000000900463ffffffff166004614b7a565b63ffffffff1667ffffffffffffffff81111561395f5761395f614611565b6040519080825280601f01601f191660200182016040528015613989576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e906139dd908490600401614262565b602060405180830381865afa1580156139fa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a1e9190614a29565b915050613b80565b60017f00000000000000000000000000000000000000000000000000000000000000006002811115613a5a57613a5a61432c565b03613b80578415613adc57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613ab1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ad59190614a29565b9050613b80565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613b2a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b4e9190614b9d565b5050601554929450613b7193505050640100000000900463ffffffff1682614afd565b613b7c906010614afd565b9150505b84613b9c57808b6080015161ffff16613b999190614afd565b90505b613baa61ffff871682614be7565b905060008782613bba8c8e6145eb565b613bc49086614afd565b613bce91906145eb565b613be090670de0b6b3a7640000614afd565b613bea9190614be7565b905060008c6040015163ffffffff1664e8d4a51000613c099190614afd565b898e6020015163ffffffff16858f88613c229190614afd565b613c2c91906145eb565b613c3a90633b9aca00614afd565b613c449190614afd565b613c4e9190614be7565b613c5891906145eb565b90506b033b2e3c9fd0803ce8000000613c7182846145eb565b1115613ca9576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613da4576000613cdf6001836145fe565b8554909150600090613cf3906001906145fe565b9050818114613d58576000866000018281548110613d1357613d13614640565b9060005260206000200154905080876000018481548110613d3657613d36614640565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613d6957613d69614bfb565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109ac565b60009150506109ac565b5092915050565b60008060408385031215613dc857600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613e0f57835183529284019291840191600101613df3565b50909695505050505050565b60008083601f840112613e2d57600080fd5b50813567ffffffffffffffff811115613e4557600080fd5b602083019150836020828501011115613e5d57600080fd5b9250929050565b600080600060408486031215613e7957600080fd5b83359250602084013567ffffffffffffffff811115613e9757600080fd5b613ea386828701613e1b565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613ef657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613ec4565b509495945050505050565b805163ffffffff16825260006101e06020830151613f27602086018263ffffffff169052565b506040830151613f3f604086018263ffffffff169052565b506060830151613f56606086018262ffffff169052565b506080830151613f6c608086018261ffff169052565b5060a0830151613f8c60a08601826bffffffffffffffffffffffff169052565b5060c0830151613fa460c086018263ffffffff169052565b5060e0830151613fbc60e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a08084015181860183905261403183870182613eb0565b925050506101c08084015161405d8287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c0602088015161409560208501826bffffffffffffffffffffffff169052565b506040880151604084015260608801516140bf60608501826bffffffffffffffffffffffff169052565b506080880151608084015260a08801516140e160a085018263ffffffff169052565b5060c08801516140f960c085018263ffffffff169052565b5060e088015160e08401526101008089015161411c8286018263ffffffff169052565b505061012088810151151590840152610140830181905261413f81840188613f01565b90508281036101608401526141548187613eb0565b90508281036101808401526141698186613eb0565b9150506117546101a083018460ff169052565b73ffffffffffffffffffffffffffffffffffffffff81168114612eca57600080fd5b600080604083850312156141b157600080fd5b82356141bc8161417c565b91506020830135600481106141d057600080fd5b809150509250929050565b6000602082840312156141ed57600080fd5b5035919050565b60005b8381101561420f5781810151838201526020016141f7565b50506000910152565b600081518084526142308160208601602086016141f4565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612ee36020830184614218565b6000806040838503121561428857600080fd5b8235915060208301356141d08161417c565b600080602083850312156142ad57600080fd5b823567ffffffffffffffff808211156142c557600080fd5b818501915085601f8301126142d957600080fd5b8135818111156142e857600080fd5b8660208260051b85010111156142fd57600080fd5b60209290920196919550909350505050565b60006020828403121561432157600080fd5b8135612ee38161417c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612eca57612eca61432c565b602081016143788361435b565b91905290565b60208101600283106143785761437861432c565b803563ffffffff811681146143a657600080fd5b919050565b600080604083850312156143be57600080fd5b8235600281106143cd57600080fd5b91506143db60208401614392565b90509250929050565b6000806000604084860312156143f957600080fd5b83356144048161417c565b9250602084013567ffffffffffffffff811115613e9757600080fd5b6000806040838503121561443357600080fd5b823561443e8161417c565b915060208301356141d08161417c565b6000806040838503121561446157600080fd5b823591506143db60208401614392565b6020815261449860208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516144b1604084018263ffffffff169052565b5060408301516101408060608501526144ce610160850183614218565b915060608501516144ef60808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e085015161010061455b818701836bffffffffffffffffffffffff169052565b86015190506101206145708682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018387015290506117548382614218565b60208101600483106143785761437861432c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109ac576109ac6145bc565b818103818111156109ac576109ac6145bc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036146a0576146a06145bc565b5060010190565b600181811c908216806146bb57607f821691505b6020821081036146f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561474457600081815260208120601f850160051c810160208610156147215750805b601f850160051c820191505b818110156147405782815560010161472d565b5050505b505050565b67ffffffffffffffff83111561476157614761614611565b6147758361476f83546146a7565b836146fa565b6000601f8411600181146147c757600085156147915750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561485d565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561481657868501358255602094850194600190920191016147f6565b5086821015614851577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561490857815473ffffffffffffffffffffffffffffffffffffffff16845292840192600191820191016148d6565b505050838103828501528481528590820160005b8681101561495757823561492f8161417c565b73ffffffffffffffffffffffffffffffffffffffff168252918301919083019060010161491c565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613dae57613dae6145bc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff808416806149d6576149d6614988565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613dae57613dae6145bc565b600060208284031215614a1957600080fd5b81518015158114612ee357600080fd5b600060208284031215614a3b57600080fd5b5051919050565b600060208284031215614a5457600080fd5b8151612ee38161417c565b805169ffffffffffffffffffff811681146143a657600080fd5b600080600080600060a08688031215614a9157600080fd5b614a9a86614a5f565b9450602086015193506040860151925060608601519150614abd60808701614a5f565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614af457614af46145bc565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b3557614b356145bc565b500290565b60ff81811683821601908111156109ac576109ac6145bc565b828482376000838201600081528351614b708183602088016141f4565b0195945050505050565b600063ffffffff80831681851681830481118215151615614af457614af46145bc565b60008060008060008060c08789031215614bb657600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614bf657614bf6614988565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryLogicBABI = KeeperRegistryLogicBMetaData.ABI @@ -325,28 +325,6 @@ func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetCancellationD return _KeeperRegistryLogicB.Contract.GetCancellationDelay(&_KeeperRegistryLogicB.CallOpts) } -func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) GetCheckGasOverhead(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _KeeperRegistryLogicB.contract.Call(opts, &out, "getCheckGasOverhead") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_KeeperRegistryLogicB *KeeperRegistryLogicBSession) GetCheckGasOverhead() (*big.Int, error) { - return _KeeperRegistryLogicB.Contract.GetCheckGasOverhead(&_KeeperRegistryLogicB.CallOpts) -} - -func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetCheckGasOverhead() (*big.Int, error) { - return _KeeperRegistryLogicB.Contract.GetCheckGasOverhead(&_KeeperRegistryLogicB.CallOpts) -} - func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) GetConditionalGasOverhead(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} err := _KeeperRegistryLogicB.contract.Call(opts, &out, "getConditionalGasOverhead") @@ -696,28 +674,6 @@ func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetState() (GetS return _KeeperRegistryLogicB.Contract.GetState(&_KeeperRegistryLogicB.CallOpts) } -func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) GetTransmitGasOverhead(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _KeeperRegistryLogicB.contract.Call(opts, &out, "getTransmitGasOverhead") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_KeeperRegistryLogicB *KeeperRegistryLogicBSession) GetTransmitGasOverhead() (*big.Int, error) { - return _KeeperRegistryLogicB.Contract.GetTransmitGasOverhead(&_KeeperRegistryLogicB.CallOpts) -} - -func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetTransmitGasOverhead() (*big.Int, error) { - return _KeeperRegistryLogicB.Contract.GetTransmitGasOverhead(&_KeeperRegistryLogicB.CallOpts) -} - func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) GetTransmitterInfo(opts *bind.CallOpts, query common.Address) (GetTransmitterInfo, error) { @@ -5309,8 +5265,6 @@ type KeeperRegistryLogicBInterface interface { GetCancellationDelay(opts *bind.CallOpts) (*big.Int, error) - GetCheckGasOverhead(opts *bind.CallOpts) (*big.Int, error) - GetConditionalGasOverhead(opts *bind.CallOpts) (*big.Int, error) GetFastGasFeedAddress(opts *bind.CallOpts) (common.Address, error) @@ -5345,8 +5299,6 @@ type KeeperRegistryLogicBInterface interface { error) - GetTransmitGasOverhead(opts *bind.CallOpts) (*big.Int, error) - GetTransmitterInfo(opts *bind.CallOpts, query common.Address) (GetTransmitterInfo, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 5501c937962..6baa4bcd7c7 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -19,14 +19,14 @@ flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../cont functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 -i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 5a25a405fb683c2d4eab19c0ac15490b324034a08dee2dc7622e949176cca03c +i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin f572f28c8f8ff8e07ef1331d70489926d314bd4ba72f6af5df4ee21d2e73e81a i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 keeper_registry_logic1_3: ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin 0176d7abdb01b370c5bf4f670d9abf85ca10aff53b1f7bdad41f85fabe666020 keeper_registry_logic2_0: ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin d69d2bc8e4844293dbc2d45abcddc50b84c88554ecccfa4fa77c0ca45ec80871 keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 56b35d4ec381125da58ce6ab7166553df18c0367e4b92402e3436212b8e732c1 -keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 4c83988955df4e91a5ee154d741982edf4796fd0836a05172ce289d20b6d4b97 +keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 14ba22d33b0a9047d28abdcb128edb909ff09b593ef86bfb44863341226ce7e7 keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin 6ce079f2738f015f7374673a2816e8e9787143d00b780ea7652c8aa9ad9e1e20 keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 From 831d6b758d62e519823925a4d35a4c30685ffb9f Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Wed, 26 Jul 2023 21:14:47 -0400 Subject: [PATCH 010/270] (test): Update gas golf baseline (#9946) --- contracts/test/v0.8/functions/v1/GasGolf.test.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index d9c263261fe..3b7958390aa 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -1,6 +1,5 @@ import { ethers } from 'hardhat' import { BigNumber } from 'ethers' -import { expect } from 'chai' import { getSetupFactory, FunctionsContracts, @@ -15,7 +14,7 @@ const setup = getSetupFactory() let contracts: FunctionsContracts let roles: FunctionsRoles -const baselineGasUsed = 933_007 // TODO: Baseline will be updated at the start of 7/27 +const baselineGasUsed = 944_073 let currentGasUsed = 0 beforeEach(async () => { From c7d508298e3a692dcc93ace99f574a0700c4f4b7 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Thu, 27 Jul 2023 02:39:26 +0100 Subject: [PATCH 011/270] Update max payment calcualtion during transmit (#9939) * Update max payment calcualtion during transmit * fix --------- Co-authored-by: Ryan Hall --- contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol | 2 +- .../keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go | 2 +- .../generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol index 422f3ae3b45..24cbc4150e4 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol @@ -90,7 +90,7 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, ER upkeepTransmitInfo[i].maxLinkPayment = _getMaxLinkPayment( hotVars, upkeepTransmitInfo[i].triggerType, - upkeepTransmitInfo[i].upkeep.performGas, + uint32(report.gasLimits[i]), uint32(report.performDatas[i].length), report.fastGasWei, report.linkNative, diff --git a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go index 8215d4c3310..8471089a0c2 100644 --- a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go @@ -50,7 +50,7 @@ type KeeperRegistryBase21OnchainConfig struct { var KeeperRegistryMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101406040523480156200001257600080fd5b506040516200547e3803806200547e8339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614fdd620004a16000396000818160d6015261016f0152600050506000818161246001528181613357015281816134ea0152613a1a01526000505060005050600061043b0152614fdd6000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063a931358d11610081578063b1dc65a41161005b578063b1dc65a4146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063a931358d14610262578063aed2e92914610275578063afcb95d71461029f576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613c99565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d22565b610423565b610119610270366004614142565b61063f565b61028861028336600461420f565b611456565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102f63660046142a0565b6115be565b610119610309366004614357565b612190565b61011961031c3660046143e6565b6121b9565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da82840184614403565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff1661444b565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da908590614470565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b6106476121cd565b601f86511115610683576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036106c0576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b845186511415806106df57506106d7846003614483565b60ff16865111155b15610716576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156107ab57610798600e828154811061076f5761076f6144ac565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612250565b50806107a3816144db565b915050610743565b5060008060005b836bffffffffffffffffffffffff168110156108b457600d81815481106107db576107db6144ac565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff90921694509082908110610816576108166144ac565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806108ac816144db565b9150506107b2565b506108c1600d6000613b6e565b6108cd600e6000613b6e565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c51811015610c5157600c60008e8381518110610912576109126144ac565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff161561097d576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106109ae576109ae6144ac565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110610a5657610a566144ac565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250610b1b576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941717919091169290921791909117905580610c49816144db565b9150506108f3565b50508a51610c679150600d9060208d0190613b8c565b508851610c7b90600e9060208c0190613b8c565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff16905061123d61245a565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff93841602178082556001926018916112b89185917801000000000000000000000000000000000000000000000000900416614513565b92506101000a81548163ffffffff021916908363ffffffff1602179055506000886040516020016112e99190614581565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061135290469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f61250f565b60115560005b61136260096125b9565b8110156113925761137f6113776009836125c9565b6009906125d5565b508061138a816144db565b915050611358565b5060005b896101a00151518110156113e9576113d68a6101a0015182815181106113be576113be6144ac565b602002602001015160096125f790919063ffffffff16565b50806113e1816144db565b915050611396565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f604051611440999897969594939291906146e5565b60405180910390a1505050505050505050505050565b600080611461612619565b6012546e010000000000000000000000000000900460ff16156114b0576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f890185900485028101850190955287855290936115af93899089908190840183828082843760009201919091525061265192505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506116ec576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff16611735576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a3514611771576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805161177e90600161477b565b60ff168614158061178f5750858414155b156117c6576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117d68a8a8a8a8a8a8a8a61285c565b60006117e28a8a612ac5565b9050600081604001515167ffffffffffffffff81111561180457611804613d7e565b6040519080825280602002602001820160405280156118d057816020015b6040805161020081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816118225790505b5090506000805b836040015151811015611d845760046000856040015183815181106118fe576118fe6144ac565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c082015283518490839081106119e3576119e36144ac565b602002602001015160000181905250611a1884604001518281518110611a0b57611a0b6144ac565b6020026020010151612b7e565b838281518110611a2a57611a2a6144ac565b6020026020010151608001906001811115611a4757611a47614794565b90816001811115611a5a57611a5a614794565b81525050611ad285848381518110611a7457611a746144ac565b602002602001015160800151858481518110611a9257611a926144ac565b602002602001015160000151602001518760a001518581518110611ab857611ab86144ac565b602002602001015151886000015189602001516001612c29565b838281518110611ae457611ae46144ac565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050611b5684604001518281518110611b2b57611b2b6144ac565b602002602001015185608001518381518110611b4957611b496144ac565b6020026020010151612c74565b838281518110611b6857611b686144ac565b602002602001015160e0018181525050611bd684604001518281518110611b9157611b916144ac565b602002602001015185608001518381518110611baf57611baf6144ac565b6020026020010151858481518110611bc957611bc96144ac565b6020026020010151612ca7565b848381518110611be857611be86144ac565b6020026020010151602001858481518110611c0557611c056144ac565b6020026020010151610100018281525082151515158152505050828181518110611c3157611c316144ac565b60200260200101516020015115611c5457611c4d6001836147c3565b9150611c59565b611d72565b611cbf838281518110611c6e57611c6e6144ac565b6020026020010151600001516060015185606001518381518110611c9457611c946144ac565b60200260200101518660a001518481518110611cb257611cb26144ac565b6020026020010151612651565b848381518110611cd157611cd16144ac565b6020026020010151606001858481518110611cee57611cee6144ac565b602002602001015160a0018281525082151515158152505050828181518110611d1957611d196144ac565b602002602001015160a0015186611d3091906147de565b9550611d7284604001518281518110611d4b57611d4b6144ac565b6020026020010151848381518110611d6557611d656144ac565b6020026020010151612e32565b80611d7c816144db565b9150506118d7565b508061ffff16600003611d9b575050505050612186565b8351611da890600161477b565b611db79060ff1661044c6147f1565b616b6c611dc58d60106147f1565b5a611dd090896147de565b611dda9190614470565b611de49190614470565b611dee9190614470565b9450611b58611e0161ffff83168761485d565b611e0b9190614470565b945060008060008060005b87604001515181101561202857868181518110611e3557611e356144ac565b6020026020010151602001511561201657611e918a888381518110611e5c57611e5c6144ac565b6020026020010151608001518a60a001518481518110611e7e57611e7e6144ac565b6020026020010151518c60000151612f1b565b878281518110611ea357611ea36144ac565b602002602001015160c0018181525050611eff8989604001518381518110611ecd57611ecd6144ac565b6020026020010151898481518110611ee757611ee76144ac565b60200260200101518b600001518c602001518b612f3b565b9093509150611f0e828561444b565b9350611f1a838661444b565b9450868181518110611f2e57611f2e6144ac565b602002602001015160600151151588604001518281518110611f5257611f526144ac565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c68486611f87919061444b565b8a8581518110611f9957611f996144ac565b602002602001015160a001518b8681518110611fb757611fb76144ac565b602002602001015160c001518c8781518110611fd557611fd56144ac565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b80612020816144db565b915050611e16565b5050336000908152600b6020526040902080548492506002906120609084906201000090046bffffffffffffffffffffffff1661444b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff166120ba919061444b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f6001600381106120fd576120fd6144ac565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff16111561217c57601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6121b1868686868060200190518101906121aa919061490c565b868661063f565b505050505050565b6121c16121cd565b6121ca8161302e565b50565b60005473ffffffffffffffffffffffffffffffffffffffff16331461224e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e010000000000000000000000000000900490911660608201529061244c5760008160600151856122e89190614a66565b905060006122f68583614a8b565b9050808360400181815161230a919061444b565b6bffffffffffffffffffffffff169052506123258582614ab6565b83606001818151612336919061444b565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111561249057612490614794565b0361250a57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156124e1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125059190614aea565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a60405160200161253399989796959493929190614b03565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006125c3825490565b92915050565b60006124538383613123565b60006124538373ffffffffffffffffffffffffffffffffffffffff841661314d565b60006124538373ffffffffffffffffffffffffffffffffffffffff8416613247565b321561224e576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60125460009081906f01000000000000000000000000000000900460ff16156126a6576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b0000000000000000000000000000000000000000000000000000000090612713908590602401613c99565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906127e69087908790600401614b98565b60408051808303816000875af1158015612804573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128289190614bb1565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b6000878760405161286e929190614be4565b604051908190038120612885918b90602001614bf4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b88811015612a5c576001858783602081106128f1576128f16144ac565b6128fe91901a601b61477b565b8c8c85818110612910576129106144ac565b905060200201358b8b86818110612929576129296144ac565b9050602002013560405160008152602001604052604051612966949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015612988573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff8082161515808552610100909204169383019390935290955093509050612a36576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b840193508080612a54906144db565b9150506128d4565b50827e01010101010101010101010101010101010101010101010101010101010101841614612ab7576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b612afe6040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6000612b0c83850185614ce5565b6040810151516060820151519192509081141580612b2f57508082608001515114155b80612b3f5750808260a001515114155b15612b76576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b509392505050565b6000818160045b600f811015612c0b577fff000000000000000000000000000000000000000000000000000000000000008216838260208110612bc357612bc36144ac565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612bf957506000949350505050565b80612c03816144db565b915050612b85565b5081600f1a6001811115612c2157612c21614794565b949350505050565b600080612c3b88878b60000151613296565b9050600080612c568b8a63ffffffff16858a8a60018b613322565b9092509050612c65818361444b565b9b9a5050505050505050505050565b60008282604051602001612c89929190614dd2565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612cc257612cc2614794565b03612ce657612cd286868661377b565b612ce1576000925090506115b6565b612d5d565b600184608001516001811115612cfe57612cfe614794565b03612d2b576000612d1087878761387b565b9250905080612d2557506000925090506115b6565b50612d5d565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d6561245a565b84516040015163ffffffff1611612dbf57857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e00151604051612dac91815260200190565b60405180910390a26000925090506115b6565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff161015612e2557857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e00151604051612dac91815260200190565b6001969095509350505050565b600081608001516001811115612e4a57612e4a614794565b03612ebc57612e5761245a565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612ed457612ed4614794565b03612f1757610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612f28848484613296565b905080851015612c215750929392505050565b600080612f56888760a001518860c001518888886001613322565b90925090506000612f67828461444b565b600089815260046020526040902060010180549192508291600c90612fab9084906c0100000000000000000000000090046bffffffffffffffffffffffff16614a66565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612ff49185911661444b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036130ad576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600082600001828154811061313a5761313a6144ac565b9060005260206000200154905092915050565b600081815260018301602052604081205480156132365760006131716001836147de565b8554909150600090613185906001906147de565b90508181146131ea5760008660000182815481106131a5576131a56144ac565b90600052602060002001549050808760000184815481106131c8576131c86144ac565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806131fb576131fb614df8565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506125c3565b60009150506125c3565b5092915050565b600081815260018301602052604081205461328e575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556125c3565b5060006125c3565b600080808560018111156132ac576132ac614794565b036132bb575062015f906132da565b60018560018111156132cf576132cf614794565b03612d2b57506201adb05b6132eb63ffffffff851660146147f1565b6132f684600161477b565b6133059060ff16611d4c6147f1565b61330f9083614470565b6133199190614470565b95945050505050565b6000806000896080015161ffff168761333b91906147f1565b90508380156133495750803a105b1561335157503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561338757613387614794565b036134e65760408051600081526020810190915285156133e557600036604051806080016040528060488152602001614f89604891396040516020016133cf93929190614e27565b604051602081830303815290604052905061344d565b60155461340190640100000000900463ffffffff166004614e4e565b63ffffffff1667ffffffffffffffff81111561341f5761341f613d7e565b6040519080825280601f01601f191660200182016040528015613449576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9061349d908490600401613c99565b602060405180830381865afa1580156134ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134de9190614aea565b915050613640565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561351a5761351a614794565b0361364057841561359c57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613571573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135959190614aea565b9050613640565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156135ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061360e9190614e71565b505060155492945061363193505050640100000000900463ffffffff16826147f1565b61363c9060106147f1565b9150505b8461365c57808b6080015161ffff1661365991906147f1565b90505b61366a61ffff87168261485d565b90506000878261367a8c8e614470565b61368490866147f1565b61368e9190614470565b6136a090670de0b6b3a76400006147f1565b6136aa919061485d565b905060008c6040015163ffffffff1664e8d4a510006136c991906147f1565b898e6020015163ffffffff16858f886136e291906147f1565b6136ec9190614470565b6136fa90633b9aca006147f1565b61370491906147f1565b61370e919061485d565b6137189190614470565b90506b033b2e3c9fd0803ce80000006137318284614470565b1115613769576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906137929190614ebb565b835160c00151815191925063ffffffff908116911610156137f557847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e001516040516137e391815260200190565b60405180910390a26000915050612453565b60208101511580159061381c5750602081015181516138199063ffffffff16613a14565b14155b80613835575061382a61245a565b815163ffffffff1610155b1561387057847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e001516040516137e391815260200190565b506001949350505050565b6000806000848060200190518101906138949190614f13565b9050600086826000015183602001516040516020016138eb93929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061394d5750816060015161394a836040015163ffffffff16613a14565b14155b80613969575061395b61245a565b826040015163ffffffff1610155b156139b957867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e001516040516139a491815260200190565b60405180910390a26000935091506115b69050565b60008181526008602052604090205460ff1615613a0657867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e001516040516139a491815260200190565b600197909650945050505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a4a57613a4a614794565b03613b64576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a9d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ac19190614aea565b90508083101580613adc5750610100613ada84836147de565b115b15613aea5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b40573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124539190614aea565b504090565b919050565b50805460008255906000526020600020908101906121ca9190613c16565b828054828255906000526020600020908101928215613c06579160200282015b82811115613c0657825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613bac565b50613c12929150613c16565b5090565b5b80821115613c125760008155600101613c17565b60005b83811015613c46578181015183820152602001613c2e565b50506000910152565b60008151808452613c67816020860160208601613c2b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006124536020830184613c4f565b73ffffffffffffffffffffffffffffffffffffffff811681146121ca57600080fd5b8035613b6981613cac565b60008083601f840112613ceb57600080fd5b50813567ffffffffffffffff811115613d0357600080fd5b602083019150836020828501011115613d1b57600080fd5b9250929050565b60008060008060608587031215613d3857600080fd5b8435613d4381613cac565b935060208501359250604085013567ffffffffffffffff811115613d6657600080fd5b613d7287828801613cd9565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613dd157613dd1613d7e565b60405290565b60405160c0810167ffffffffffffffff81118282101715613dd157613dd1613d7e565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e4157613e41613d7e565b604052919050565b600067ffffffffffffffff821115613e6357613e63613d7e565b5060051b60200190565b600082601f830112613e7e57600080fd5b81356020613e93613e8e83613e49565b613dfa565b82815260059290921b84018101918181019086841115613eb257600080fd5b8286015b84811015613ed6578035613ec981613cac565b8352918301918301613eb6565b509695505050505050565b803560ff81168114613b6957600080fd5b63ffffffff811681146121ca57600080fd5b8035613b6981613ef2565b62ffffff811681146121ca57600080fd5b8035613b6981613f0f565b61ffff811681146121ca57600080fd5b8035613b6981613f2b565b6bffffffffffffffffffffffff811681146121ca57600080fd5b8035613b6981613f46565b60006101e08284031215613f7e57600080fd5b613f86613dad565b9050613f9182613f04565b8152613f9f60208301613f04565b6020820152613fb060408301613f04565b6040820152613fc160608301613f20565b6060820152613fd260808301613f3b565b6080820152613fe360a08301613f60565b60a0820152613ff460c08301613f04565b60c082015261400560e08301613f04565b60e0820152610100614018818401613f04565b9082015261012061402a838201613f04565b9082015261014082810135908201526101608083013590820152610180614052818401613cce565b908201526101a08281013567ffffffffffffffff81111561407257600080fd5b61407e85828601613e6d565b8284015250506101c0614092818401613cce565b9082015292915050565b803567ffffffffffffffff81168114613b6957600080fd5b600082601f8301126140c557600080fd5b813567ffffffffffffffff8111156140df576140df613d7e565b61411060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613dfa565b81815284602083860101111561412557600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561415b57600080fd5b863567ffffffffffffffff8082111561417357600080fd5b61417f8a838b01613e6d565b9750602089013591508082111561419557600080fd5b6141a18a838b01613e6d565b96506141af60408a01613ee1565b955060608901359150808211156141c557600080fd5b6141d18a838b01613f6b565b94506141df60808a0161409c565b935060a08901359150808211156141f557600080fd5b5061420289828a016140b4565b9150509295509295509295565b60008060006040848603121561422457600080fd5b83359250602084013567ffffffffffffffff81111561424257600080fd5b61424e86828701613cd9565b9497909650939450505050565b60008083601f84011261426d57600080fd5b50813567ffffffffffffffff81111561428557600080fd5b6020830191508360208260051b8501011115613d1b57600080fd5b60008060008060008060008060e0898b0312156142bc57600080fd5b606089018a8111156142cd57600080fd5b8998503567ffffffffffffffff808211156142e757600080fd5b6142f38c838d01613cd9565b909950975060808b013591508082111561430c57600080fd5b6143188c838d0161425b565b909750955060a08b013591508082111561433157600080fd5b5061433e8b828c0161425b565b999c989b50969995989497949560c00135949350505050565b60008060008060008060c0878903121561437057600080fd5b863567ffffffffffffffff8082111561438857600080fd5b6143948a838b01613e6d565b975060208901359150808211156143aa57600080fd5b6143b68a838b01613e6d565b96506143c460408a01613ee1565b955060608901359150808211156143da57600080fd5b6141d18a838b016140b4565b6000602082840312156143f857600080fd5b813561245381613cac565b60006020828403121561441557600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156132405761324061441c565b808201808211156125c3576125c361441c565b600060ff821660ff84168160ff04811182151516156144a4576144a461441c565b029392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361450c5761450c61441c565b5060010190565b63ffffffff8181168382160190808211156132405761324061441c565b600081518084526020808501945080840160005b8381101561457657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614544565b509495945050505050565b6020815261459860208201835163ffffffff169052565b600060208301516145b1604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e083015161010061462a8185018363ffffffff169052565b84015190506101206146438482018363ffffffff169052565b840151905061014061465c8482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a061469f8185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526146bf610200860184614530565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526147158184018a614530565b905082810360808401526147298189614530565b905060ff871660a084015282810360c08401526147468187613c4f565b905067ffffffffffffffff851660e084015282810361010084015261476b8185613c4f565b9c9b505050505050505050505050565b60ff81811683821601908111156125c3576125c361441c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156132405761324061441c565b818103818111156125c3576125c361441c565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156148295761482961441c565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261486c5761486c61482e565b500490565b8051613b6981613ef2565b8051613b6981613f0f565b8051613b6981613f2b565b8051613b6981613f46565b8051613b6981613cac565b600082601f8301126148b957600080fd5b815160206148c9613e8e83613e49565b82815260059290921b840181019181810190868411156148e857600080fd5b8286015b84811015613ed65780516148ff81613cac565b83529183019183016148ec565b60006020828403121561491e57600080fd5b815167ffffffffffffffff8082111561493657600080fd5b908301906101e0828603121561494b57600080fd5b614953613dad565b61495c83614871565b815261496a60208401614871565b602082015261497b60408401614871565b604082015261498c6060840161487c565b606082015261499d60808401614887565b60808201526149ae60a08401614892565b60a08201526149bf60c08401614871565b60c08201526149d060e08401614871565b60e08201526101006149e3818501614871565b908201526101206149f5848201614871565b9082015261014083810151908201526101608084015190820152610180614a1d81850161489d565b908201526101a08381015183811115614a3557600080fd5b614a41888287016148a8565b8284015250506101c09150614a5782840161489d565b91810191909152949350505050565b6bffffffffffffffffffffffff8281168282160390808211156132405761324061441c565b60006bffffffffffffffffffffffff80841680614aaa57614aaa61482e565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614ae157614ae161441c565b02949350505050565b600060208284031215614afc57600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614b4a8285018b614530565b91508382036080850152614b5e828a614530565b915060ff881660a085015283820360c0850152614b7b8288613c4f565b90861660e0850152838103610100850152905061476b8185613c4f565b828152604060208201526000612c216040830184613c4f565b60008060408385031215614bc457600080fd5b82518015158114614bd457600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614c1b57600080fd5b81356020614c2b613e8e83613e49565b82815260059290921b84018101918181019086841115614c4a57600080fd5b8286015b84811015613ed65780358352918301918301614c4e565b600082601f830112614c7657600080fd5b81356020614c86613e8e83613e49565b82815260059290921b84018101918181019086841115614ca557600080fd5b8286015b84811015613ed657803567ffffffffffffffff811115614cc95760008081fd5b614cd78986838b01016140b4565b845250918301918301614ca9565b600060208284031215614cf757600080fd5b813567ffffffffffffffff80821115614d0f57600080fd5b9083019060c08286031215614d2357600080fd5b614d2b613dd7565b8235815260208301356020820152604083013582811115614d4b57600080fd5b614d5787828601614c0a565b604083015250606083013582811115614d6f57600080fd5b614d7b87828601614c0a565b606083015250608083013582811115614d9357600080fd5b614d9f87828601614c65565b60808301525060a083013582811115614db757600080fd5b614dc387828601614c65565b60a08301525095945050505050565b82815260008251614dea816020850160208701613c2b565b919091016020019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b828482376000838201600081528351614e44818360208801613c2b565b0195945050505050565b600063ffffffff80831681851681830481118215151615614ae157614ae161441c565b60008060008060008060c08789031215614e8a57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614ecd57600080fd5b6040516040810181811067ffffffffffffffff82111715614ef057614ef0613d7e565b6040528251614efe81613ef2565b81526020928301519281019290925250919050565b600060808284031215614f2557600080fd5b6040516080810181811067ffffffffffffffff82111715614f4857614f48613d7e565b604052825181526020830151614f5d81613ef2565b60208201526040830151614f7081613ef2565b6040820152606092830151928101929092525091905056fe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + Bin: "0x6101406040523480156200001257600080fd5b506040516200547a3803806200547a8339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614fd9620004a16000396000818160d6015261016f0152600050506000818161245c01528181613353015281816134e60152613a1601526000505060005050600061043b0152614fd96000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063a931358d11610081578063b1dc65a41161005b578063b1dc65a4146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063a931358d14610262578063aed2e92914610275578063afcb95d71461029f576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613c95565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d1e565b610423565b61011961027036600461413e565b61063f565b61028861028336600461420b565b611456565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102f636600461429c565b6115be565b610119610309366004614353565b61218c565b61011961031c3660046143e2565b6121b5565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da828401846143ff565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff16614447565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da90859061446c565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b6106476121c9565b601f86511115610683576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036106c0576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b845186511415806106df57506106d784600361447f565b60ff16865111155b15610716576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156107ab57610798600e828154811061076f5761076f6144a8565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16848461224c565b50806107a3816144d7565b915050610743565b5060008060005b836bffffffffffffffffffffffff168110156108b457600d81815481106107db576107db6144a8565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff90921694509082908110610816576108166144a8565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806108ac816144d7565b9150506107b2565b506108c1600d6000613b6a565b6108cd600e6000613b6a565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c51811015610c5157600c60008e8381518110610912576109126144a8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff161561097d576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106109ae576109ae6144a8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110610a5657610a566144a8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250610b1b576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941717919091169290921791909117905580610c49816144d7565b9150506108f3565b50508a51610c679150600d9060208d0190613b88565b508851610c7b90600e9060208c0190613b88565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff16905061123d612456565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff93841602178082556001926018916112b8918591780100000000000000000000000000000000000000000000000090041661450f565b92506101000a81548163ffffffff021916908363ffffffff1602179055506000886040516020016112e9919061457d565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061135290469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f61250b565b60115560005b61136260096125b5565b8110156113925761137f6113776009836125c5565b6009906125d1565b508061138a816144d7565b915050611358565b5060005b896101a00151518110156113e9576113d68a6101a0015182815181106113be576113be6144a8565b602002602001015160096125f390919063ffffffff16565b50806113e1816144d7565b915050611396565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f604051611440999897969594939291906146e1565b60405180910390a1505050505050505050505050565b600080611461612615565b6012546e010000000000000000000000000000900460ff16156114b0576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f890185900485028101850190955287855290936115af93899089908190840183828082843760009201919091525061264d92505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506116ec576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff16611735576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a3514611771576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805161177e906001614777565b60ff168614158061178f5750858414155b156117c6576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117d68a8a8a8a8a8a8a8a612858565b60006117e28a8a612ac1565b9050600081604001515167ffffffffffffffff81111561180457611804613d7a565b6040519080825280602002602001820160405280156118d057816020015b6040805161020081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816118225790505b5090506000805b836040015151811015611d805760046000856040015183815181106118fe576118fe6144a8565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c082015283518490839081106119e3576119e36144a8565b602002602001015160000181905250611a1884604001518281518110611a0b57611a0b6144a8565b6020026020010151612b7a565b838281518110611a2a57611a2a6144a8565b6020026020010151608001906001811115611a4757611a47614790565b90816001811115611a5a57611a5a614790565b81525050611ace85848381518110611a7457611a746144a8565b60200260200101516080015186606001518481518110611a9657611a966144a8565b60200260200101518760a001518581518110611ab457611ab46144a8565b602002602001015151886000015189602001516001612c25565b838281518110611ae057611ae06144a8565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050611b5284604001518281518110611b2757611b276144a8565b602002602001015185608001518381518110611b4557611b456144a8565b6020026020010151612c70565b838281518110611b6457611b646144a8565b602002602001015160e0018181525050611bd284604001518281518110611b8d57611b8d6144a8565b602002602001015185608001518381518110611bab57611bab6144a8565b6020026020010151858481518110611bc557611bc56144a8565b6020026020010151612ca3565b848381518110611be457611be46144a8565b6020026020010151602001858481518110611c0157611c016144a8565b6020026020010151610100018281525082151515158152505050828181518110611c2d57611c2d6144a8565b60200260200101516020015115611c5057611c496001836147bf565b9150611c55565b611d6e565b611cbb838281518110611c6a57611c6a6144a8565b6020026020010151600001516060015185606001518381518110611c9057611c906144a8565b60200260200101518660a001518481518110611cae57611cae6144a8565b602002602001015161264d565b848381518110611ccd57611ccd6144a8565b6020026020010151606001858481518110611cea57611cea6144a8565b602002602001015160a0018281525082151515158152505050828181518110611d1557611d156144a8565b602002602001015160a0015186611d2c91906147da565b9550611d6e84604001518281518110611d4757611d476144a8565b6020026020010151848381518110611d6157611d616144a8565b6020026020010151612e2e565b80611d78816144d7565b9150506118d7565b508061ffff16600003611d97575050505050612182565b8351611da4906001614777565b611db39060ff1661044c6147ed565b616b6c611dc18d60106147ed565b5a611dcc90896147da565b611dd6919061446c565b611de0919061446c565b611dea919061446c565b9450611b58611dfd61ffff831687614859565b611e07919061446c565b945060008060008060005b87604001515181101561202457868181518110611e3157611e316144a8565b6020026020010151602001511561201257611e8d8a888381518110611e5857611e586144a8565b6020026020010151608001518a60a001518481518110611e7a57611e7a6144a8565b6020026020010151518c60000151612f17565b878281518110611e9f57611e9f6144a8565b602002602001015160c0018181525050611efb8989604001518381518110611ec957611ec96144a8565b6020026020010151898481518110611ee357611ee36144a8565b60200260200101518b600001518c602001518b612f37565b9093509150611f0a8285614447565b9350611f168386614447565b9450868181518110611f2a57611f2a6144a8565b602002602001015160600151151588604001518281518110611f4e57611f4e6144a8565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c68486611f839190614447565b8a8581518110611f9557611f956144a8565b602002602001015160a001518b8681518110611fb357611fb36144a8565b602002602001015160c001518c8781518110611fd157611fd16144a8565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b8061201c816144d7565b915050611e12565b5050336000908152600b60205260409020805484925060029061205c9084906201000090046bffffffffffffffffffffffff16614447565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff166120b69190614447565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f6001600381106120f9576120f96144a8565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff16111561217857601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6121ad868686868060200190518101906121a69190614908565b868661063f565b505050505050565b6121bd6121c9565b6121c68161302a565b50565b60005473ffffffffffffffffffffffffffffffffffffffff16331461224a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906124485760008160600151856122e49190614a62565b905060006122f28583614a87565b905080836040018181516123069190614447565b6bffffffffffffffffffffffff169052506123218582614ab2565b836060018181516123329190614447565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111561248c5761248c614790565b0361250657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156124dd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125019190614ae6565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a60405160200161252f99989796959493929190614aff565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006125bf825490565b92915050565b600061244f838361311f565b600061244f8373ffffffffffffffffffffffffffffffffffffffff8416613149565b600061244f8373ffffffffffffffffffffffffffffffffffffffff8416613243565b321561224a576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60125460009081906f01000000000000000000000000000000900460ff16156126a2576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b000000000000000000000000000000000000000000000000000000009061270f908590602401613c95565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906127e29087908790600401614b94565b60408051808303816000875af1158015612800573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128249190614bad565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b6000878760405161286a929190614be0565b604051908190038120612881918b90602001614bf0565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b88811015612a58576001858783602081106128ed576128ed6144a8565b6128fa91901a601b614777565b8c8c8581811061290c5761290c6144a8565b905060200201358b8b86818110612925576129256144a8565b9050602002013560405160008152602001604052604051612962949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015612984573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff8082161515808552610100909204169383019390935290955093509050612a32576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b840193508080612a50906144d7565b9150506128d0565b50827e01010101010101010101010101010101010101010101010101010101010101841614612ab3576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b612afa6040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6000612b0883850185614ce1565b6040810151516060820151519192509081141580612b2b57508082608001515114155b80612b3b5750808260a001515114155b15612b72576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b509392505050565b6000818160045b600f811015612c07577fff000000000000000000000000000000000000000000000000000000000000008216838260208110612bbf57612bbf6144a8565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612bf557506000949350505050565b80612bff816144d7565b915050612b81565b5081600f1a6001811115612c1d57612c1d614790565b949350505050565b600080612c3788878b60000151613292565b9050600080612c528b8a63ffffffff16858a8a60018b61331e565b9092509050612c618183614447565b9b9a5050505050505050505050565b60008282604051602001612c85929190614dce565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612cbe57612cbe614790565b03612ce257612cce868686613777565b612cdd576000925090506115b6565b612d59565b600184608001516001811115612cfa57612cfa614790565b03612d27576000612d0c878787613877565b9250905080612d2157506000925090506115b6565b50612d59565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d61612456565b84516040015163ffffffff1611612dbb57857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e00151604051612da891815260200190565b60405180910390a26000925090506115b6565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff161015612e2157857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e00151604051612da891815260200190565b6001969095509350505050565b600081608001516001811115612e4657612e46614790565b03612eb857612e53612456565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612ed057612ed0614790565b03612f1357610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612f24848484613292565b905080851015612c1d5750929392505050565b600080612f52888760a001518860c00151888888600161331e565b90925090506000612f638284614447565b600089815260046020526040902060010180549192508291600c90612fa79084906c0100000000000000000000000090046bffffffffffffffffffffffff16614a62565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612ff091859116614447565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036130a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000826000018281548110613136576131366144a8565b9060005260206000200154905092915050565b6000818152600183016020526040812054801561323257600061316d6001836147da565b8554909150600090613181906001906147da565b90508181146131e65760008660000182815481106131a1576131a16144a8565b90600052602060002001549050808760000184815481106131c4576131c46144a8565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806131f7576131f7614df4565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506125bf565b60009150506125bf565b5092915050565b600081815260018301602052604081205461328a575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556125bf565b5060006125bf565b600080808560018111156132a8576132a8614790565b036132b7575062015f906132d6565b60018560018111156132cb576132cb614790565b03612d2757506201adb05b6132e763ffffffff851660146147ed565b6132f2846001614777565b6133019060ff16611d4c6147ed565b61330b908361446c565b613315919061446c565b95945050505050565b6000806000896080015161ffff168761333791906147ed565b90508380156133455750803a105b1561334d57503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561338357613383614790565b036134e25760408051600081526020810190915285156133e157600036604051806080016040528060488152602001614f85604891396040516020016133cb93929190614e23565b6040516020818303038152906040529050613449565b6015546133fd90640100000000900463ffffffff166004614e4a565b63ffffffff1667ffffffffffffffff81111561341b5761341b613d7a565b6040519080825280601f01601f191660200182016040528015613445576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613499908490600401613c95565b602060405180830381865afa1580156134b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134da9190614ae6565b91505061363c565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561351657613516614790565b0361363c57841561359857606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561356d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135919190614ae6565b905061363c565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156135e6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061360a9190614e6d565b505060155492945061362d93505050640100000000900463ffffffff16826147ed565b6136389060106147ed565b9150505b8461365857808b6080015161ffff1661365591906147ed565b90505b61366661ffff871682614859565b9050600087826136768c8e61446c565b61368090866147ed565b61368a919061446c565b61369c90670de0b6b3a76400006147ed565b6136a69190614859565b905060008c6040015163ffffffff1664e8d4a510006136c591906147ed565b898e6020015163ffffffff16858f886136de91906147ed565b6136e8919061446c565b6136f690633b9aca006147ed565b61370091906147ed565b61370a9190614859565b613714919061446c565b90506b033b2e3c9fd0803ce800000061372d828461446c565b1115613765576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000808380602001905181019061378e9190614eb7565b835160c00151815191925063ffffffff908116911610156137f157847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e001516040516137df91815260200190565b60405180910390a2600091505061244f565b6020810151158015906138185750602081015181516138159063ffffffff16613a10565b14155b806138315750613826612456565b815163ffffffff1610155b1561386c57847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e001516040516137df91815260200190565b506001949350505050565b6000806000848060200190518101906138909190614f0f565b9050600086826000015183602001516040516020016138e793929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061394957508160600151613946836040015163ffffffff16613a10565b14155b806139655750613957612456565b826040015163ffffffff1610155b156139b557867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e001516040516139a091815260200190565b60405180910390a26000935091506115b69050565b60008181526008602052604090205460ff1615613a0257867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e001516040516139a091815260200190565b600197909650945050505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a4657613a46614790565b03613b60576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a99573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613abd9190614ae6565b90508083101580613ad85750610100613ad684836147da565b115b15613ae65750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b3c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061244f9190614ae6565b504090565b919050565b50805460008255906000526020600020908101906121c69190613c12565b828054828255906000526020600020908101928215613c02579160200282015b82811115613c0257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613ba8565b50613c0e929150613c12565b5090565b5b80821115613c0e5760008155600101613c13565b60005b83811015613c42578181015183820152602001613c2a565b50506000910152565b60008151808452613c63816020860160208601613c27565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061244f6020830184613c4b565b73ffffffffffffffffffffffffffffffffffffffff811681146121c657600080fd5b8035613b6581613ca8565b60008083601f840112613ce757600080fd5b50813567ffffffffffffffff811115613cff57600080fd5b602083019150836020828501011115613d1757600080fd5b9250929050565b60008060008060608587031215613d3457600080fd5b8435613d3f81613ca8565b935060208501359250604085013567ffffffffffffffff811115613d6257600080fd5b613d6e87828801613cd5565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613dcd57613dcd613d7a565b60405290565b60405160c0810167ffffffffffffffff81118282101715613dcd57613dcd613d7a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e3d57613e3d613d7a565b604052919050565b600067ffffffffffffffff821115613e5f57613e5f613d7a565b5060051b60200190565b600082601f830112613e7a57600080fd5b81356020613e8f613e8a83613e45565b613df6565b82815260059290921b84018101918181019086841115613eae57600080fd5b8286015b84811015613ed2578035613ec581613ca8565b8352918301918301613eb2565b509695505050505050565b803560ff81168114613b6557600080fd5b63ffffffff811681146121c657600080fd5b8035613b6581613eee565b62ffffff811681146121c657600080fd5b8035613b6581613f0b565b61ffff811681146121c657600080fd5b8035613b6581613f27565b6bffffffffffffffffffffffff811681146121c657600080fd5b8035613b6581613f42565b60006101e08284031215613f7a57600080fd5b613f82613da9565b9050613f8d82613f00565b8152613f9b60208301613f00565b6020820152613fac60408301613f00565b6040820152613fbd60608301613f1c565b6060820152613fce60808301613f37565b6080820152613fdf60a08301613f5c565b60a0820152613ff060c08301613f00565b60c082015261400160e08301613f00565b60e0820152610100614014818401613f00565b90820152610120614026838201613f00565b908201526101408281013590820152610160808301359082015261018061404e818401613cca565b908201526101a08281013567ffffffffffffffff81111561406e57600080fd5b61407a85828601613e69565b8284015250506101c061408e818401613cca565b9082015292915050565b803567ffffffffffffffff81168114613b6557600080fd5b600082601f8301126140c157600080fd5b813567ffffffffffffffff8111156140db576140db613d7a565b61410c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613df6565b81815284602083860101111561412157600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561415757600080fd5b863567ffffffffffffffff8082111561416f57600080fd5b61417b8a838b01613e69565b9750602089013591508082111561419157600080fd5b61419d8a838b01613e69565b96506141ab60408a01613edd565b955060608901359150808211156141c157600080fd5b6141cd8a838b01613f67565b94506141db60808a01614098565b935060a08901359150808211156141f157600080fd5b506141fe89828a016140b0565b9150509295509295509295565b60008060006040848603121561422057600080fd5b83359250602084013567ffffffffffffffff81111561423e57600080fd5b61424a86828701613cd5565b9497909650939450505050565b60008083601f84011261426957600080fd5b50813567ffffffffffffffff81111561428157600080fd5b6020830191508360208260051b8501011115613d1757600080fd5b60008060008060008060008060e0898b0312156142b857600080fd5b606089018a8111156142c957600080fd5b8998503567ffffffffffffffff808211156142e357600080fd5b6142ef8c838d01613cd5565b909950975060808b013591508082111561430857600080fd5b6143148c838d01614257565b909750955060a08b013591508082111561432d57600080fd5b5061433a8b828c01614257565b999c989b50969995989497949560c00135949350505050565b60008060008060008060c0878903121561436c57600080fd5b863567ffffffffffffffff8082111561438457600080fd5b6143908a838b01613e69565b975060208901359150808211156143a657600080fd5b6143b28a838b01613e69565b96506143c060408a01613edd565b955060608901359150808211156143d657600080fd5b6141cd8a838b016140b0565b6000602082840312156143f457600080fd5b813561244f81613ca8565b60006020828403121561441157600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff81811683821601908082111561323c5761323c614418565b808201808211156125bf576125bf614418565b600060ff821660ff84168160ff04811182151516156144a0576144a0614418565b029392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361450857614508614418565b5060010190565b63ffffffff81811683821601908082111561323c5761323c614418565b600081518084526020808501945080840160005b8381101561457257815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614540565b509495945050505050565b6020815261459460208201835163ffffffff169052565b600060208301516145ad604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e08301516101006146268185018363ffffffff169052565b840151905061012061463f8482018363ffffffff169052565b84015190506101406146588482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a061469b8185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526146bb61020086018461452c565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526147118184018a61452c565b90508281036080840152614725818961452c565b905060ff871660a084015282810360c08401526147428187613c4b565b905067ffffffffffffffff851660e08401528281036101008401526147678185613c4b565b9c9b505050505050505050505050565b60ff81811683821601908111156125bf576125bf614418565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff81811683821601908082111561323c5761323c614418565b818103818111156125bf576125bf614418565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561482557614825614418565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826148685761486861482a565b500490565b8051613b6581613eee565b8051613b6581613f0b565b8051613b6581613f27565b8051613b6581613f42565b8051613b6581613ca8565b600082601f8301126148b557600080fd5b815160206148c5613e8a83613e45565b82815260059290921b840181019181810190868411156148e457600080fd5b8286015b84811015613ed25780516148fb81613ca8565b83529183019183016148e8565b60006020828403121561491a57600080fd5b815167ffffffffffffffff8082111561493257600080fd5b908301906101e0828603121561494757600080fd5b61494f613da9565b6149588361486d565b81526149666020840161486d565b60208201526149776040840161486d565b604082015261498860608401614878565b606082015261499960808401614883565b60808201526149aa60a0840161488e565b60a08201526149bb60c0840161486d565b60c08201526149cc60e0840161486d565b60e08201526101006149df81850161486d565b908201526101206149f184820161486d565b9082015261014083810151908201526101608084015190820152610180614a19818501614899565b908201526101a08381015183811115614a3157600080fd5b614a3d888287016148a4565b8284015250506101c09150614a53828401614899565b91810191909152949350505050565b6bffffffffffffffffffffffff82811682821603908082111561323c5761323c614418565b60006bffffffffffffffffffffffff80841680614aa657614aa661482a565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614add57614add614418565b02949350505050565b600060208284031215614af857600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614b468285018b61452c565b91508382036080850152614b5a828a61452c565b915060ff881660a085015283820360c0850152614b778288613c4b565b90861660e085015283810361010085015290506147678185613c4b565b828152604060208201526000612c1d6040830184613c4b565b60008060408385031215614bc057600080fd5b82518015158114614bd057600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614c1757600080fd5b81356020614c27613e8a83613e45565b82815260059290921b84018101918181019086841115614c4657600080fd5b8286015b84811015613ed25780358352918301918301614c4a565b600082601f830112614c7257600080fd5b81356020614c82613e8a83613e45565b82815260059290921b84018101918181019086841115614ca157600080fd5b8286015b84811015613ed257803567ffffffffffffffff811115614cc55760008081fd5b614cd38986838b01016140b0565b845250918301918301614ca5565b600060208284031215614cf357600080fd5b813567ffffffffffffffff80821115614d0b57600080fd5b9083019060c08286031215614d1f57600080fd5b614d27613dd3565b8235815260208301356020820152604083013582811115614d4757600080fd5b614d5387828601614c06565b604083015250606083013582811115614d6b57600080fd5b614d7787828601614c06565b606083015250608083013582811115614d8f57600080fd5b614d9b87828601614c61565b60808301525060a083013582811115614db357600080fd5b614dbf87828601614c61565b60a08301525095945050505050565b82815260008251614de6816020850160208701613c27565b919091016020019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b828482376000838201600081528351614e40818360208801613c27565b0195945050505050565b600063ffffffff80831681851681830481118215151615614add57614add614418565b60008060008060008060c08789031215614e8657600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614ec957600080fd5b6040516040810181811067ffffffffffffffff82111715614eec57614eec613d7a565b6040528251614efa81613eee565b81526020928301519281019290925250919050565b600060808284031215614f2157600080fd5b6040516080810181811067ffffffffffffffff82111715614f4457614f44613d7a565b604052825181526020830151614f5981613eee565b60208201526040830151614f6c81613eee565b6040820152606092830151928101929092525091905056fe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryABI = KeeperRegistryMetaData.ABI diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 6baa4bcd7c7..50e31b6cfa4 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -31,7 +31,7 @@ keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../. keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 -keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin a36bdb08793747e81fe936a855276d0b61e20531b900aea86bed997a43a37d24 +keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 0cb301ae98d7d3f5c53da3534724896b2bd423a136ec9fb292a766ba9c64c765 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 From 0fbb553efa2a1ce963c37c0199dae9026dfb6ecf Mon Sep 17 00:00:00 2001 From: Cedric Date: Thu, 27 Jul 2023 10:05:36 +0100 Subject: [PATCH 012/270] [chore] Bump push-gha-metrics-action to latest (#9915) --- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 +++--- .github/workflows/build-publish-develop.yml | 2 +- .github/workflows/build-publish.yml | 2 +- .github/workflows/build.yml | 2 +- .github/workflows/changelog.yml | 2 +- .github/workflows/ci-core.yml | 12 +++++------ .github/workflows/codeql-analysis.yml | 2 +- .github/workflows/dependency-check.yml | 2 +- .../goreleaser-build-publish-develop.yml | 2 +- .github/workflows/integration-chaos-tests.yml | 6 +++--- .../workflows/integration-tests-publish.yml | 2 +- .github/workflows/integration-tests.yml | 20 +++++++++---------- .github/workflows/lint-gh-workflows.yml | 2 +- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/operator-ui.yml | 2 +- .github/workflows/performance-tests.yml | 4 ++-- .github/workflows/readme.yml | 2 +- .github/workflows/sigscanner.yml | 2 +- .github/workflows/solidity-foundry.yml | 2 +- .github/workflows/solidity.yml | 16 +++++++-------- ...evelop-from-smartcontractkit-chainlink.yml | 2 +- 22 files changed, 48 insertions(+), 48 deletions(-) diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index daf1c74ee90..ca0cc67f19d 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -128,7 +128,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index 7b02462d895..07243d93e3b 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -36,7 +36,7 @@ jobs: - name: Collect Metrics if: inputs.chainlinkImage == '' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -81,7 +81,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -192,7 +192,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish-develop.yml b/.github/workflows/build-publish-develop.yml index f7ade04b5b5..e8def971629 100644 --- a/.github/workflows/build-publish-develop.yml +++ b/.github/workflows/build-publish-develop.yml @@ -40,7 +40,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish.yml b/.github/workflows/build-publish.yml index 0b76b96d466..ddc2bb55449 100644 --- a/.github/workflows/build-publish.yml +++ b/.github/workflows/build-publish.yml @@ -50,7 +50,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d2de350a96c..29c474c764f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,7 +22,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index f9072837379..f3b0c507340 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 93db23ab46f..29aafcda453 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -100,7 +100,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -129,7 +129,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -193,7 +193,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -219,7 +219,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -312,7 +312,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -344,7 +344,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 365c9b518e7..09a9b3235cb 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -48,7 +48,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/dependency-check.yml b/.github/workflows/dependency-check.yml index 5a2acbac496..4a88007fa6a 100644 --- a/.github/workflows/dependency-check.yml +++ b/.github/workflows/dependency-check.yml @@ -47,7 +47,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/goreleaser-build-publish-develop.yml b/.github/workflows/goreleaser-build-publish-develop.yml index 0ba17533610..80f360afd5b 100644 --- a/.github/workflows/goreleaser-build-publish-develop.yml +++ b/.github/workflows/goreleaser-build-publish-develop.yml @@ -39,7 +39,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index ecc4a1e9216..5b84bbd28f0 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -53,7 +53,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -99,7 +99,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests-publish.yml b/.github/workflows/integration-tests-publish.yml index 9f9f6ca092a..d38ffa6f5fa 100644 --- a/.github/workflows/integration-tests-publish.yml +++ b/.github/workflows/integration-tests-publish.yml @@ -20,7 +20,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 4214c936b50..e5955400505 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -72,7 +72,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -119,7 +119,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -248,7 +248,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -269,7 +269,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -337,7 +337,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -443,7 +443,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -482,7 +482,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -536,7 +536,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -681,7 +681,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/lint-gh-workflows.yml b/.github/workflows/lint-gh-workflows.yml index 60c1648d3ed..02530227eb2 100644 --- a/.github/workflows/lint-gh-workflows.yml +++ b/.github/workflows/lint-gh-workflows.yml @@ -13,7 +13,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index bc41757b8ff..30810faca04 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -77,7 +77,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/operator-ui.yml b/.github/workflows/operator-ui.yml index 68039f27686..0ba6dc3cb79 100644 --- a/.github/workflows/operator-ui.yml +++ b/.github/workflows/operator-ui.yml @@ -33,7 +33,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index b277b9f1b3b..0cd5f7cfc08 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/readme.yml b/.github/workflows/readme.yml index 194938eede3..06877afd308 100644 --- a/.github/workflows/readme.yml +++ b/.github/workflows/readme.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sigscanner.yml b/.github/workflows/sigscanner.yml index 6d376e28af0..9e07d71acd1 100644 --- a/.github/workflows/sigscanner.yml +++ b/.github/workflows/sigscanner.yml @@ -26,7 +26,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index f81aa1d12e8..5f9022a7f94 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -70,7 +70,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity.yml b/.github/workflows/solidity.yml index 614679c284a..4f93b933401 100644 --- a/.github/workflows/solidity.yml +++ b/.github/workflows/solidity.yml @@ -43,7 +43,7 @@ jobs: config: ./contracts/ci.json - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -91,7 +91,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -153,7 +153,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -178,7 +178,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@8163dcea2f01a0a8fec84b284406ff7af1d2e1c0 + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -202,7 +202,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -249,7 +249,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -275,7 +275,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -301,7 +301,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml index d4d6fa3f79e..37b2b4c6986 100644 --- a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml +++ b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml @@ -30,7 +30,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@90fcbaac8ebf86da9c4d55dba24f6fe3029f0e0b + uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} From c0f6d0767c123bc8cbf9206f12799e97fdffe445 Mon Sep 17 00:00:00 2001 From: Sri Kidambi <1702865+kidambisrinivas@users.noreply.github.com> Date: Thu, 27 Jul 2023 10:28:47 +0100 Subject: [PATCH 013/270] Add subscription ID to RandomWordsFulfilled logs (#9936) * Add subscription ID to RandomWordsFulfilled logs * Indexed subID param in RandomWordsFulfilled log event * Generate the test results instead of hardcoding * Fix FilterRandomWordsFulfilled * Fix FilterRandomWordsFulfilled in coordinator_v2x_interface.go * Fix prettier --------- Co-authored-by: Sri Kidambi --- .../src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 5 ++-- .../ExposedVRFCoordinatorV2Plus.sol | 8 +++++ .../test/v0.8/foundry/vrf/VRFV2Plus.t.sol | 16 +++++++++- .../vrf_coordinator_v2plus.go | 29 +++++++++++++------ ...rapper-dependency-versions-do-not-edit.txt | 2 +- .../vrf/v2/coordinator_v2x_interface.go | 17 ++++++++--- .../vrf/v2/integration_helpers_test.go | 14 +++++---- .../vrf/v2/integration_v2_plus_test.go | 17 ++++++++++- core/services/vrf/v2/integration_v2_test.go | 9 ++++-- 9 files changed, 91 insertions(+), 26 deletions(-) diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index b29e2b0042e..216f29c72a2 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -64,6 +64,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { event RandomWordsFulfilled( uint256 indexed requestId, uint256 outputSeed, + uint256 indexed subID, uint96 payment, bytes extraArgs, bool success @@ -377,7 +378,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { function getRandomnessFromProof( Proof calldata proof, RequestCommitment calldata rc - ) private view returns (Output memory) { + ) internal view returns (Output memory) { bytes32 keyHash = hashOfKey(proof.pk); // Only registered proving keys are permitted. address oracle = s_provingKeys[keyHash]; @@ -471,7 +472,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { ); // Include payment in the event for tracking costs. // event RandomWordsFulfilled(uint256 indexed requestId, uint256 outputSeed, uint96 payment, bytes extraArgs, bool success); - emit RandomWordsFulfilled(output.requestId, output.randomness, payment, extraArgs, success); + emit RandomWordsFulfilled(output.requestId, output.randomness, rc.subId, payment, extraArgs, success); return payment; } diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol index c4ab099a777..819225bd7ed 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol @@ -1,6 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.4; +import "../../../vrf/VRF.sol"; import {VRFCoordinatorV2Plus} from "../VRFCoordinatorV2Plus.sol"; contract ExposedVRFCoordinatorV2Plus is VRFCoordinatorV2Plus { @@ -18,4 +19,11 @@ contract ExposedVRFCoordinatorV2Plus is VRFCoordinatorV2Plus { function isTargetRegisteredExternal(address target) external view returns (bool) { return isTargetRegistered(target); } + + function getRandomnessFromProofExternal( + Proof calldata proof, + RequestCommitment calldata rc + ) external view returns (Output memory) { + return getRandomnessFromProof(proof, rc); + } } diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol index 3be839d6ca3..9ca8477fa90 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol @@ -152,6 +152,14 @@ contract VRFV2Plus is BaseTest { bytes extraArgs, address indexed sender ); + event RandomWordsFulfilled( + uint256 indexed requestId, + uint256 outputSeed, + uint256 indexed subID, + uint96 payment, + bytes extraArgs, + bool success + ); function testRequestAndFulfillRandomWordsNative() public { uint32 requestBlock = 10; @@ -241,6 +249,9 @@ contract VRFV2Plus is BaseTest { extraArgs: VRFV2PlusClient._argsToBytes(VRFV2PlusClient.ExtraArgsV1({nativePayment: true})) }); (, uint96 ethBalanceBefore, , ) = s_testCoordinator.getSubscription(subId); + vm.expectEmit(true, true, false, true); + uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; + emit RandomWordsFulfilled(requestId, outputSeed, subId, 122500, rc.extraArgs, true); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); @@ -272,7 +283,7 @@ contract VRFV2Plus is BaseTest { registerProvingKey(); // Request random words. - vm.expectEmit(true, true, true, true); + vm.expectEmit(true, true, false, true); (uint256 requestId, uint256 preSeed) = s_testCoordinator.computeRequestIdExternal( vrfKeyHash, address(s_testConsumer), @@ -347,6 +358,9 @@ contract VRFV2Plus is BaseTest { extraArgs: VRFV2PlusClient._argsToBytes(VRFV2PlusClient.ExtraArgsV1({nativePayment: false})) }); (uint96 linkBalanceBefore, , , ) = s_testCoordinator.getSubscription(subId); + vm.expectEmit(true, true, false, true); + uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; + emit RandomWordsFulfilled(requestId, outputSeed, subId, 290972, rc.extraArgs, true); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index 33b05e4c4a9..ee345bc327a 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -66,8 +66,8 @@ type VRFV2PlusClientRandomWordsRequest struct { } var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"}],\"name\":\"setLINK\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLinkEthFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620060b0380380620060b0833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615ed0620001e0600039600081816105e30152613b350152615ed06000f3fe6080604052600436106102fc5760003560e01c8063981837d51161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610972578063ee9d2d3814610999578063f2fde38b146109c657600080fd5b8063dc311dd31461090f578063e72f6e301461093f578063e8509bff1461095f57600080fd5b8063d98e620e116100bb578063d98e620e14610899578063da2f2610146108b9578063dac83d29146108ef57600080fd5b8063bec4c08c14610839578063caf70c4a14610859578063cb6317971461087957600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107d9578063b08c8795146107f9578063b2a7cac51461081957600080fd5b8063a4c0ed3614610779578063a8cb447b14610799578063aa433aff146107b957600080fd5b80639d40a6fd116101745780639d40a6fd1461070a578063a02e061614610744578063a21a23e41461076457600080fd5b8063981837d5146106ca5780639b1c385e146106ea57600080fd5b806340d6bb8211610253578063689c4517116101fc57806379ba5097116101d657806379ba50971461066b57806386fe91c7146106805780638da5cb5b146106ac57600080fd5b8063689c4517146105d15780636b6feccc146106055780636f64f03f1461064b57600080fd5b80635d06b4ab1161022d5780635d06b4ab1461057c57806364d51a2a1461059c57806366316d8d146105b157600080fd5b806340d6bb821461050157806341af6c871461052c57806346d8d4861461055c57600080fd5b80630ae09540116102b5578063294daa491161028f578063294daa491461048d578063330987b3146104a9578063405b84fa146104e157600080fd5b80630ae095401461040d57806315c48b841461042d5780631b6b6d231461045557600080fd5b8063043bd6ae116102e6578063043bd6ae14610350578063088070f51461037457806308821d58146103ed57600080fd5b80620122911461030157806304104edb1461032e575b600080fd5b34801561030d57600080fd5b506103166109e6565b604051610325939291906159ab565b60405180910390f35b34801561033a57600080fd5b5061034e61034936600461533f565b610a62565b005b34801561035c57600080fd5b50610366600e5481565b604051908152602001610325565b34801561038057600080fd5b50600f546103bc9061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff938416602086015291831691840191909152166060820152608001610325565b3480156103f957600080fd5b5061034e610408366004615447565b610c24565b34801561041957600080fd5b5061034e610428366004615704565b610db8565b34801561043957600080fd5b5061044260c881565b60405161ffff9091168152602001610325565b34801561046157600080fd5b50600354610475906001600160a01b031681565b6040516001600160a01b039091168152602001610325565b34801561049957600080fd5b5060405160018152602001610325565b3480156104b557600080fd5b506104c96104c436600461551a565b610ea4565b6040516001600160601b039091168152602001610325565b3480156104ed57600080fd5b5061034e6104fc366004615704565b61135e565b34801561050d57600080fd5b506105176101f481565b60405163ffffffff9091168152602001610325565b34801561053857600080fd5b5061054c61054736600461549c565b61173d565b6040519015158152602001610325565b34801561056857600080fd5b5061034e61057736600461535c565b61193f565b34801561058857600080fd5b5061034e61059736600461533f565b611ada565b3480156105a857600080fd5b50610442606481565b3480156105bd57600080fd5b5061034e6105cc36600461535c565b611bb1565b3480156105dd57600080fd5b506104757f000000000000000000000000000000000000000000000000000000000000000081565b34801561061157600080fd5b5060105461062e9063ffffffff8082169164010000000090041682565b6040805163ffffffff938416815292909116602083015201610325565b34801561065757600080fd5b5061034e610666366004615391565b611d6e565b34801561067757600080fd5b5061034e611e86565b34801561068c57600080fd5b506007546104c9906801000000000000000090046001600160601b031681565b3480156106b857600080fd5b506000546001600160a01b0316610475565b3480156106d657600080fd5b5061034e6106e536600461533f565b611f37565b3480156106f657600080fd5b50610366610705366004615616565b611f61565b34801561071657600080fd5b5060075461072b9067ffffffffffffffff1681565b60405167ffffffffffffffff9091168152602001610325565b34801561075057600080fd5b5061034e61075f36600461533f565b6123a2565b34801561077057600080fd5b5061036661240f565b34801561078557600080fd5b5061034e6107943660046153be565b61266f565b3480156107a557600080fd5b5061034e6107b436600461533f565b61285f565b3480156107c557600080fd5b5061034e6107d436600461549c565b61297b565b3480156107e557600080fd5b50600a54610475906001600160a01b031681565b34801561080557600080fd5b5061034e610814366004615666565b6129db565b34801561082557600080fd5b5061034e61083436600461549c565b612b65565b34801561084557600080fd5b5061034e610854366004615704565b612cd2565b34801561086557600080fd5b50610366610874366004615463565b612ea5565b34801561088557600080fd5b5061034e610894366004615704565b612ed5565b3480156108a557600080fd5b506103666108b436600461549c565b6131f2565b3480156108c557600080fd5b506104756108d436600461549c565b600b602052600090815260409020546001600160a01b031681565b3480156108fb57600080fd5b5061034e61090a366004615704565b613213565b34801561091b57600080fd5b5061092f61092a36600461549c565b61334b565b6040516103259493929190615ba9565b34801561094b57600080fd5b5061034e61095a36600461533f565b61342e565b61034e61096d36600461549c565b6135f6565b34801561097e57600080fd5b506007546104c990600160a01b90046001600160601b031681565b3480156109a557600080fd5b506103666109b436600461549c565b600d6020526000908152604090205481565b3480156109d257600080fd5b5061034e6109e136600461533f565b61374e565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a5057602002820191906000526020600020905b815481526020019060010190808311610a3c575b50505050509050925092509250909192565b610a6a61375f565b60115460005b81811015610bf757826001600160a01b031660118281548110610a9557610a95615e54565b6000918252602090912001546001600160a01b03161415610be5576011610abd600184615d4c565b81548110610acd57610acd615e54565b600091825260209091200154601180546001600160a01b039092169183908110610af957610af9615e54565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b30600185615d4c565b81548110610b4057610b40615e54565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b7f57610b7f615e3e565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bef81615dbb565b915050610a70565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c2c61375f565b604080518082018252600091610c5b919084906002908390839080828437600092019190915250612ea5915050565b6000818152600b60205260409020549091506001600160a01b031680610c9757604051631dfd6e1360e21b815260048101839052602401610c18565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d6f5782600c8281548110610cd257610cd2615e54565b90600052602060002001541415610d5d57600c805460009190610cf790600190615d4c565b81548110610d0757610d07615e54565b9060005260206000200154905080600c8381548110610d2857610d28615e54565b600091825260209091200155600c805480610d4557610d45615e3e565b60019003818190600052602060002001600090559055505b80610d6781615dbb565b915050610cb4565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610dab91815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610df057604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e2457604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415610e645760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b60028055610e718461173d565b15610e8f57604051631685ecdd60e31b815260040160405180910390fd5b610e9984846137bb565b505060016002555050565b6000600280541415610ee65760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b6002805560005a90506000610efb8585613952565b90506000610f0f6080860160608701615734565b63ffffffff1667ffffffffffffffff811115610f2d57610f2d615e6a565b604051908082528060200260200182016040528015610f56578160200160208202803683370190505b50905060005b610f6c6080870160608801615734565b63ffffffff16811015610fe157826040015181604051602001610f99929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610fc457610fc4615e54565b602090810291909101015280610fd981615dbb565b915050610f5c565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161103291908690602401615a1e565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199094169390931790925291506000906110ae906110929060608b01908b01615734565b63ffffffff166110a860a08b0160808c0161533f565b84613ca7565b905060006110c76110c260a08b018b615bee565b613cf5565b51600f549091506000906110f29089906a0100000000000000000000900463ffffffff163a85613da4565b905081156111fb576020808b01356000908152600690915260409020546001600160601b03808316600160601b90920416101561114257604051631e9acf1760e31b815260040160405180910390fd5b60208a81013560009081526006909152604090208054829190600c90611179908490600160601b90046001600160601b0316615d63565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b0316835260099091528120805485945090926111d291859116615cf7565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506112e7565b6020808b01356000908152600690915260409020546001600160601b038083169116101561123c57604051631e9acf1760e31b815260040160405180910390fd5b6020808b0135600090815260069091526040812080548392906112699084906001600160601b0316615d63565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b0316835260089091528120805485945090926112c291859116615cf7565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113026040518060200160405280851515815250613df4565b905087602001517f2c7b705f67f9ae2cbd3edc06b5b99afb00441ee4aea7bb77f109273bc1f3b5eb89604001518484886040516113429493929190615b6e565b60405180910390a25060016002559a9950505050505050505050565b61136781613e7a565b61138f57604051635428d44960e01b81526001600160a01b0382166004820152602401610c18565b60008060008061139e8661334b565b9350935093509350336001600160a01b0316826001600160a01b0316146114075760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c18565b6114108661173d565b1561145d5760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c18565b60006040518060c00160405280611472600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016114c69190615936565b60405160208183030381529060405290506114e088613ee4565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b03881690611532908590600401615923565b6000604051808303818588803b15801561154b57600080fd5b505af115801561155f573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b1580156115bb57600080fd5b505af11580156115cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f3919061547f565b61163f5760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c18565b60005b83518110156116f05783818151811061165d5761165d615e54565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b1580156116c557600080fd5b505af11580156116d9573d6000803e3d6000fd5b5050505080806116e890615dbb565b915050611642565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287969395860193909291908301828280156117c757602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117a9575b505050505081525050905060005b8160400151518110156119355760005b600c548110156119225760006118eb600c838154811061180757611807615e54565b90600052602060002001548560400151858151811061182857611828615e54565b602002602001015188600460008960400151898151811061184b5761184b615e54565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d60205260409020549091501561190f5750600195945050505050565b508061191a81615dbb565b9150506117e5565b508061192d81615dbb565b9150506117d5565b5060009392505050565b60028054141561197f5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b60028055336000908152600960205260409020546001600160601b03808316911610156119bf57604051631e9acf1760e31b815260040160405180910390fd5b33600090815260096020526040812080548392906119e79084906001600160601b0316615d63565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a2f9190615d63565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611aa9576040519150601f19603f3d011682016040523d82523d6000602084013e611aae565b606091505b5050905080611ad057604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611ae261375f565b611aeb81613e7a565b15611b2d576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c18565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611bf15760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b60028055336000908152600860205260409020546001600160601b0380831691161015611c3157604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611c599084906001600160601b0316615d63565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611ca19190615d63565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d1057600080fd5b505af1158015611d24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d48919061547f565b611d6557604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611d7661375f565b604080518082018252600091611da5919084906002908390839080828437600092019190915250612ea5915050565b6000818152600b60205260409020549091506001600160a01b031615611dfa576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c18565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610dab565b6001546001600160a01b03163314611ee05760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c18565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611f3f61375f565b600a80546001600160a01b0319166001600160a01b0392909216919091179055565b6000600280541415611fa35760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b600280556020808301356000908152600590915260409020546001600160a01b0316611fe257604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612034576040516379bfd40160e01b815260208401356004820152336024820152604401610c18565b600f5461ffff1661204b606085016040860161564b565b61ffff16108061206e575060c8612068606085016040860161564b565b61ffff16115b156120b457612083606084016040850161564b565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c18565b600f5462010000900463ffffffff166120d36080850160608601615734565b63ffffffff16111561213c576120ef6080840160608501615734565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c18565b6101f461214f60a0850160808601615734565b63ffffffff1611156121ae5761216b60a0840160808501615734565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c18565b60006121bb826001615ccb565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e080850184905285518086039091018152610100909401909452825192019190912092935090600090612247906110c290890189615bee565b9050600061225482613df4565b90508361225f614136565b60208a013561227460808c0160608d01615734565b61228460a08d0160808e01615734565b338660405160200161229c9796959493929190615aab565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d6040016020810190612313919061564b565b8e60600160208101906123269190615734565b8f60800160208101906123399190615734565b8960405161234c96959493929190615a6c565b60405180910390a4505033600090815260046020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b6123aa61375f565b6003546001600160a01b0316156123ed576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b0319166001600160a01b0392909216919091179055565b60006002805414156124515760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b60028055600033612463600143615d4c565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b77ffffffffffffffffffffffffffffffffffffffffffffffff1916606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124f483615dd6565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561253657612536615e6a565b60405190808252806020026020018201604052801561255f578160200160208202803683370190505b5060408051808201825260008082526020808301828152878352600682528483209351845491516001600160601b03908116600160601b0277ffffffffffffffffffffffffffffffffffffffffffffffff199093169116171790925582516060810184523381528083018281528185018681528884526005855294909220815181546001600160a01b039182166001600160a01b0319918216178355935160018301805491909216941693909317909255925180519495509293909261262c92600285019291019061516a565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b6002805414156126af5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b600280556003546001600160a01b031633146126f7576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612731576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061273f8284018461549c565b6000818152600560205260409020549091506001600160a01b031661277757604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b03169186919061279e8385615cf7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127e69190615cf7565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846128399190615cb3565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b61286761375f565b6007544790600160a01b90046001600160601b0316818111156128a7576040516354ced18160e11b81526004810182905260248101839052604401610c18565b818110156129765760006128bb8284615d4c565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d806000811461290a576040519150601f19603f3d011682016040523d82523d6000602084013e61290f565b606091505b505090508061293157604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b61298361375f565b6000818152600560205260409020546001600160a01b03166129b857604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c219082906001600160a01b03166137bb565b6129e361375f565b60c861ffff87161115612a1d5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c18565b60008213612a41576040516321ea67b360e11b815260048101839052602401610c18565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612ba55760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b600280556000818152600560205260409020546001600160a01b0316612bde57604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c5057600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c18565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526005602052604090205482906001600160a01b031680612d0a57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d3e57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415612d7e5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b60028080556000858152600560205260409020015460641415612dcd576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612e0557610e99565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612eb89190615915565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612f0d57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612f4157604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415612f815760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b60028055612f8e8461173d565b15612fac57604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16613009576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c18565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561306c57602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161304e575b505050505090506000600182516130839190615d4c565b905060005b825181101561318f57856001600160a01b03168382815181106130ad576130ad615e54565b60200260200101516001600160a01b0316141561317d5760008383815181106130d8576130d8615e54565b6020026020010151905080600560008a8152602001908152602001600020600201838154811061310a5761310a615e54565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260059091526040902060020180548061315557613155615e3e565b600082815260209020810160001990810180546001600160a01b03191690550190555061318f565b8061318781615dbb565b915050613088565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161284a565b600c818154811061320257600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b03168061324b57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461327f57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b6002805414156132bf5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b600280556000848152600560205260409020600101546001600160a01b03848116911614610e995760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e92565b600081815260056020526040812054819081906060906001600160a01b031661338757604051630fb532db60e11b815260040160405180910390fd5b60008581526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b900416946001600160a01b0390931693919283919083018282801561341857602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133fa575b5050505050905093509350935093509193509193565b61343661375f565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561349357600080fd5b505afa1580156134a7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134cb91906154b5565b6007549091506801000000000000000090046001600160601b031681811115613511576040516354ced18160e11b81526004810182905260248101839052604401610c18565b818110156129765760006135258284615d4c565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561357557600080fd5b505af1158015613589573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135ad919061547f565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6002805414156136365760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea48339815191526044820152606401610c18565b600280556000818152600560205260409020546001600160a01b031661366f57604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c61369e8385615cf7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136e69190615cf7565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846137399190615cb3565b60408051928352602083019190915201612cc1565b61375661375f565b610c21816141cf565b6000546001600160a01b031633146137b95760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c18565b565b6000806137c784613ee4565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b15801561382457600080fd5b505af1158015613838573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061385c919061547f565b61387957604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d80600081146138cf576040519150601f19603f3d011682016040523d82523d6000602084013e6138d4565b606091505b50509050806138f657604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b60408051606081018252600080825260208201819052818301819052825180840184529192909161399b9186906002908390839080828437600092019190915250612ea5915050565b6000818152600b60205260409020549091506001600160a01b0316806139d757604051631dfd6e1360e21b815260048101839052602401610c18565b6000828660c001356040516020016139f9929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613a58576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613a66602088018861574f565b6020880135613a7b60608a0160408b01615734565b613a8b60808b0160608c01615734565b613a9b60a08c0160808d0161533f565b613aa860a08d018d615bee565b604051602001613abf989796959493929190615af5565b604051602081830303815290604052805190602001208114613b0d576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613b24613b1f602089018961574f565b614279565b905080613c32576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613b6760208a018a61574f565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613ba757600080fd5b505afa158015613bbb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bdf91906154b5565b905080613c3257613bf3602088018861574f565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c18565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c7a613c74368c90038c018c615572565b83614380565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613cb957600080fd5b611388810390508460408204820311613cd157600080fd5b50823b613cdd57600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613d1e5750604080516020810190915260008152613ca1565b7f92fd133800000000000000000000000000000000000000000000000000000000613d498385615d8b565b6001600160e01b03191614613d8a576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d978260048186615c89565b810190613cee91906154ce565b60008115613dd257601054613dcb9086908690640100000000900463ffffffff16866143eb565b9050613dec565b601054613de9908690869063ffffffff1686614455565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613e2d91511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613edb57826001600160a01b031660118281548110613ea557613ea5615e54565b6000918252602090912001546001600160a01b03161415613ec95750600192915050565b80613ed381615dbb565b915050613e7e565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613f7057602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613f52575b5050509190925250505060008581526006602090815260408083208151808301909252546001600160601b03808216808452600160601b9092041692820183905296509094509192505b826040015151811015614032576004600084604001518381518110613fe157613fe1615e54565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff191690558061402a81615dbb565b915050613fba565b50600085815260056020526040812080546001600160a01b0319908116825560018201805490911690559061406a60028301826151cf565b50506000858152600660205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff19169055600780548591906008906140c39084906801000000000000000090046001600160601b0316615d63565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b031661410b9190615d63565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b181148061414b575062066eed81145b156141c85760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561418a57600080fd5b505afa15801561419e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906141c291906154b5565b91505090565b4391505090565b6001600160a01b0381163314156142285760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c18565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b181148061428e575062066eed81145b15614370576101008367ffffffffffffffff166142a9614136565b6142b39190615d4c565b11806142d057506142c2614136565b8367ffffffffffffffff1610155b156142de5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561433857600080fd5b505afa15801561434c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613cee91906154b5565b505067ffffffffffffffff164090565b60006143b48360000151846020015185604001518660600151868860a001518960c001518a60e001518b610100015161455c565b600383602001516040516020016143cc929190615a0a565b60408051601f1981840301815291905280516020909101209392505050565b6000806143f6614797565b905060005a6144058888615cb3565b61440f9190615d4c565b6144199085615d2d565b9050600061443263ffffffff871664e8d4a51000615d2d565b90508261443f8284615cb3565b6144499190615cb3565b98975050505050505050565b6000806144606147f3565b905060008113614486576040516321ea67b360e11b815260048101829052602401610c18565b6000614490614797565b9050600082825a6144a18b8b615cb3565b6144ab9190615d4c565b6144b59088615d2d565b6144bf9190615cb3565b6144d190670de0b6b3a7640000615d2d565b6144db9190615d19565b905060006144f463ffffffff881664e8d4a51000615d2d565b905061450c816b033b2e3c9fd0803ce8000000615d4c565b821115614545576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61454f8183615cb3565b9998505050505050505050565b614565896148da565b6145b15760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c18565b6145ba886148da565b6146065760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c18565b61460f836148da565b61465b5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c18565b614664826148da565b6146b05760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c18565b6146bc878a88876149b3565b6147085760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c18565b60006147148a87614ae8565b90506000614727898b878b868989614b4c565b90506000614738838d8d8a86614c6c565b9050808a146147895760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c18565b505050505050505050505050565b60004661a4b18114806147ac575062066eed81145b156147eb57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561418a57600080fd5b600091505090565b600f54600a54604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000936601000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b15801561486d57600080fd5b505afa158015614881573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906148a59190615779565b5094509092508491505080156148c957506148c08242615d4c565b8463ffffffff16105b15613dec5750600e54949350505050565b80516000906401000003d019116149335760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c18565b60208201516401000003d0191161498c5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c18565b60208201516401000003d0199080096149ac8360005b6020020151614cac565b1492915050565b60006001600160a01b038216614a0b5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c18565b602084015160009060011615614a2257601c614a25565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614ac0573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614af06151ed565b614b1d60018484604051602001614b09939291906158f4565b604051602081830303815290604052614cd0565b90505b614b29816148da565b613ca1578051604080516020810192909252614b459101614b09565b9050614b20565b614b546151ed565b825186516401000003d0199081900691061415614bb35760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c18565b614bbe878988614d1f565b614c0a5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c18565b614c15848685614d1f565b614c615760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c18565b614449868484614e59565b600060028686868587604051602001614c8a96959493929190615895565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614cd86151ed565b614ce182614f20565b8152614cf6614cf18260006149a2565b614f5b565b602082018190526002900660011415614d1a576020810180516401000003d0190390525b919050565b600082614d6e5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c18565b83516020850151600090614d8490600290615dfe565b15614d9057601c614d93565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614e05573d6000803e3d6000fd5b505050602060405103519050600086604051602001614e249190615883565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614e616151ed565b835160208086015185519186015160009384938493614e8293909190614f7b565b919450925090506401000003d019858209600114614ee25760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c18565b60405180604001604052806401000003d01980614f0157614f01615e28565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614d1a57604080516020808201939093528151808203840181529082019091528051910120614f28565b6000613ca1826002614f746401000003d0196001615cb3565b901c61505b565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614fbb838385856150fd565b9098509050614fcc88828e88615121565b9098509050614fdd88828c87615121565b90985090506000614ff08d878b85615121565b9098509050615001888286866150fd565b909850905061501288828e89615121565b9098509050818114615047576401000003d019818a0998506401000003d01982890997506401000003d019818309965061504b565b8196505b5050505050509450945094915050565b60008061506661520b565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a0820152615098615229565b60208160c0846005600019fa9250826150f35760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c18565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156151bf579160200282015b828111156151bf57825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019061518a565b506151cb929150615247565b5090565b5080546000825590600052602060002090810190610c219190615247565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156151cb5760008155600101615248565b8035614d1a81615e80565b8060408101831015613ca157600080fd5b600082601f83011261528957600080fd5b615291615c3c565b8083856040860111156152a357600080fd5b60005b60028110156152c55781358452602093840193909101906001016152a6565b509095945050505050565b600060c082840312156152e257600080fd5b50919050565b803561ffff81168114614d1a57600080fd5b803563ffffffff81168114614d1a57600080fd5b805169ffffffffffffffffffff81168114614d1a57600080fd5b80356001600160601b0381168114614d1a57600080fd5b60006020828403121561535157600080fd5b8135613cee81615e80565b6000806040838503121561536f57600080fd5b823561537a81615e80565b915061538860208401615328565b90509250929050565b600080606083850312156153a457600080fd5b82356153af81615e80565b91506153888460208501615267565b600080600080606085870312156153d457600080fd5b84356153df81615e80565b935060208501359250604085013567ffffffffffffffff8082111561540357600080fd5b818701915087601f83011261541757600080fd5b81358181111561542657600080fd5b88602082850101111561543857600080fd5b95989497505060200194505050565b60006040828403121561545957600080fd5b613cee8383615267565b60006040828403121561547557600080fd5b613cee8383615278565b60006020828403121561549157600080fd5b8151613cee81615e95565b6000602082840312156154ae57600080fd5b5035919050565b6000602082840312156154c757600080fd5b5051919050565b6000602082840312156154e057600080fd5b6040516020810181811067ffffffffffffffff8211171561550357615503615e6a565b604052823561551181615e95565b81529392505050565b6000808284036101c081121561552f57600080fd5b6101a08082121561553f57600080fd5b849350830135905067ffffffffffffffff81111561555c57600080fd5b615568858286016152d0565b9150509250929050565b60006101a0828403121561558557600080fd5b61558d615c65565b6155978484615278565b81526155a68460408501615278565b60208201526080830135604082015260a0830135606082015260c083013560808201526155d560e0840161525c565b60a08201526101006155e985828601615278565b60c08301526155fc856101408601615278565b60e083015261018084013581830152508091505092915050565b60006020828403121561562857600080fd5b813567ffffffffffffffff81111561563f57600080fd5b613dec848285016152d0565b60006020828403121561565d57600080fd5b613cee826152e8565b60008060008060008086880360e081121561568057600080fd5b615689886152e8565b9650615697602089016152fa565b95506156a5604089016152fa565b94506156b3606089016152fa565b9350608088013592506040609f19820112156156ce57600080fd5b506156d7615c3c565b6156e360a089016152fa565b81526156f160c089016152fa565b6020820152809150509295509295509295565b6000806040838503121561571757600080fd5b82359150602083013561572981615e80565b809150509250929050565b60006020828403121561574657600080fd5b613cee826152fa565b60006020828403121561576157600080fd5b813567ffffffffffffffff81168114613cee57600080fd5b600080600080600060a0868803121561579157600080fd5b61579a8661530e565b94506020860151935060408601519250606086015191506157bd6080870161530e565b90509295509295909350565b600081518084526020808501945080840160005b838110156158025781516001600160a01b0316875295820195908201906001016157dd565b509495945050505050565b8060005b6002811015615830578151845260209384019390910190600101615811565b50505050565b6000815180845260005b8181101561585c57602081850181015186830182015201615840565b8181111561586e576000602083870101525b50601f01601f19169290920160200192915050565b61588d818361580d565b604001919050565b8681526158a5602082018761580d565b6158b2606082018661580d565b6158bf60a082018561580d565b6158cc60e082018461580d565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b838152615904602082018461580d565b606081019190915260800192915050565b60408101613ca1828461580d565b602081526000613cee6020830184615836565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261597c60e08401826157c9565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159fc578451835293830193918301916001016159e0565b509098975050505050505050565b82815260608101613cee602083018461580d565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a5f57845183529383019391830191600101615a43565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261444960c0830184615836565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261454f60e0830184615836565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b966080830185615836565b9050821515606083015295945050505050565b60006001600160601b0380871683528086166020840152506001600160a01b038416604083015260806060830152615be460808301846157c9565b9695505050505050565b6000808335601e19843603018112615c0557600080fd5b83018035915067ffffffffffffffff821115615c2057600080fd5b602001915036819003821315615c3557600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c5f57615c5f615e6a565b60405290565b604051610120810167ffffffffffffffff81118282101715615c5f57615c5f615e6a565b60008085851115615c9957600080fd5b83861115615ca657600080fd5b5050820193919092039150565b60008219821115615cc657615cc6615e12565b500190565b600067ffffffffffffffff808316818516808303821115615cee57615cee615e12565b01949350505050565b60006001600160601b03808316818516808303821115615cee57615cee615e12565b600082615d2857615d28615e28565b500490565b6000816000190483118215151615615d4757615d47615e12565b500290565b600082821015615d5e57615d5e615e12565b500390565b60006001600160601b0383811690831681811015615d8357615d83615e12565b039392505050565b6001600160e01b03198135818116916004851015615db35780818660040360031b1b83161692505b505092915050565b6000600019821415615dcf57615dcf615e12565b5060010190565b600067ffffffffffffffff80831681811415615df457615df4615e12565b6001019392505050565b600082615e0d57615e0d615e28565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c2157600080fd5b8015158114610c2157600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"}],\"name\":\"setLINK\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLinkEthFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620060b5380380620060b5833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615ed5620001e0600039600081816105e30152613b3a0152615ed56000f3fe6080604052600436106102fc5760003560e01c8063981837d51161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610972578063ee9d2d3814610999578063f2fde38b146109c657600080fd5b8063dc311dd31461090f578063e72f6e301461093f578063e8509bff1461095f57600080fd5b8063d98e620e116100bb578063d98e620e14610899578063da2f2610146108b9578063dac83d29146108ef57600080fd5b8063bec4c08c14610839578063caf70c4a14610859578063cb6317971461087957600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107d9578063b08c8795146107f9578063b2a7cac51461081957600080fd5b8063a4c0ed3614610779578063a8cb447b14610799578063aa433aff146107b957600080fd5b80639d40a6fd116101745780639d40a6fd1461070a578063a02e061614610744578063a21a23e41461076457600080fd5b8063981837d5146106ca5780639b1c385e146106ea57600080fd5b806340d6bb8211610253578063689c4517116101fc57806379ba5097116101d657806379ba50971461066b57806386fe91c7146106805780638da5cb5b146106ac57600080fd5b8063689c4517146105d15780636b6feccc146106055780636f64f03f1461064b57600080fd5b80635d06b4ab1161022d5780635d06b4ab1461057c57806364d51a2a1461059c57806366316d8d146105b157600080fd5b806340d6bb821461050157806341af6c871461052c57806346d8d4861461055c57600080fd5b80630ae09540116102b5578063294daa491161028f578063294daa491461048d578063330987b3146104a9578063405b84fa146104e157600080fd5b80630ae095401461040d57806315c48b841461042d5780631b6b6d231461045557600080fd5b8063043bd6ae116102e6578063043bd6ae14610350578063088070f51461037457806308821d58146103ed57600080fd5b80620122911461030157806304104edb1461032e575b600080fd5b34801561030d57600080fd5b506103166109e6565b604051610325939291906159b0565b60405180910390f35b34801561033a57600080fd5b5061034e610349366004615344565b610a62565b005b34801561035c57600080fd5b50610366600e5481565b604051908152602001610325565b34801561038057600080fd5b50600f546103bc9061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff938416602086015291831691840191909152166060820152608001610325565b3480156103f957600080fd5b5061034e61040836600461544c565b610c24565b34801561041957600080fd5b5061034e610428366004615709565b610db8565b34801561043957600080fd5b5061044260c881565b60405161ffff9091168152602001610325565b34801561046157600080fd5b50600354610475906001600160a01b031681565b6040516001600160a01b039091168152602001610325565b34801561049957600080fd5b5060405160018152602001610325565b3480156104b557600080fd5b506104c96104c436600461551f565b610ea4565b6040516001600160601b039091168152602001610325565b3480156104ed57600080fd5b5061034e6104fc366004615709565b611363565b34801561050d57600080fd5b506105176101f481565b60405163ffffffff9091168152602001610325565b34801561053857600080fd5b5061054c6105473660046154a1565b611742565b6040519015158152602001610325565b34801561056857600080fd5b5061034e610577366004615361565b611944565b34801561058857600080fd5b5061034e610597366004615344565b611adf565b3480156105a857600080fd5b50610442606481565b3480156105bd57600080fd5b5061034e6105cc366004615361565b611bb6565b3480156105dd57600080fd5b506104757f000000000000000000000000000000000000000000000000000000000000000081565b34801561061157600080fd5b5060105461062e9063ffffffff8082169164010000000090041682565b6040805163ffffffff938416815292909116602083015201610325565b34801561065757600080fd5b5061034e610666366004615396565b611d73565b34801561067757600080fd5b5061034e611e8b565b34801561068c57600080fd5b506007546104c9906801000000000000000090046001600160601b031681565b3480156106b857600080fd5b506000546001600160a01b0316610475565b3480156106d657600080fd5b5061034e6106e5366004615344565b611f3c565b3480156106f657600080fd5b5061036661070536600461561b565b611f66565b34801561071657600080fd5b5060075461072b9067ffffffffffffffff1681565b60405167ffffffffffffffff9091168152602001610325565b34801561075057600080fd5b5061034e61075f366004615344565b6123a7565b34801561077057600080fd5b50610366612414565b34801561078557600080fd5b5061034e6107943660046153c3565b612674565b3480156107a557600080fd5b5061034e6107b4366004615344565b612864565b3480156107c557600080fd5b5061034e6107d43660046154a1565b612980565b3480156107e557600080fd5b50600a54610475906001600160a01b031681565b34801561080557600080fd5b5061034e61081436600461566b565b6129e0565b34801561082557600080fd5b5061034e6108343660046154a1565b612b6a565b34801561084557600080fd5b5061034e610854366004615709565b612cd7565b34801561086557600080fd5b50610366610874366004615468565b612eaa565b34801561088557600080fd5b5061034e610894366004615709565b612eda565b3480156108a557600080fd5b506103666108b43660046154a1565b6131f7565b3480156108c557600080fd5b506104756108d43660046154a1565b600b602052600090815260409020546001600160a01b031681565b3480156108fb57600080fd5b5061034e61090a366004615709565b613218565b34801561091b57600080fd5b5061092f61092a3660046154a1565b613350565b6040516103259493929190615bae565b34801561094b57600080fd5b5061034e61095a366004615344565b613433565b61034e61096d3660046154a1565b6135fb565b34801561097e57600080fd5b506007546104c990600160a01b90046001600160601b031681565b3480156109a557600080fd5b506103666109b43660046154a1565b600d6020526000908152604090205481565b3480156109d257600080fd5b5061034e6109e1366004615344565b613753565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a5057602002820191906000526020600020905b815481526020019060010190808311610a3c575b50505050509050925092509250909192565b610a6a613764565b60115460005b81811015610bf757826001600160a01b031660118281548110610a9557610a95615e59565b6000918252602090912001546001600160a01b03161415610be5576011610abd600184615d51565b81548110610acd57610acd615e59565b600091825260209091200154601180546001600160a01b039092169183908110610af957610af9615e59565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b30600185615d51565b81548110610b4057610b40615e59565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b7f57610b7f615e43565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bef81615dc0565b915050610a70565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c2c613764565b604080518082018252600091610c5b919084906002908390839080828437600092019190915250612eaa915050565b6000818152600b60205260409020549091506001600160a01b031680610c9757604051631dfd6e1360e21b815260048101839052602401610c18565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d6f5782600c8281548110610cd257610cd2615e59565b90600052602060002001541415610d5d57600c805460009190610cf790600190615d51565b81548110610d0757610d07615e59565b9060005260206000200154905080600c8381548110610d2857610d28615e59565b600091825260209091200155600c805480610d4557610d45615e43565b60019003818190600052602060002001600090559055505b80610d6781615dc0565b915050610cb4565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610dab91815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610df057604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e2457604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415610e645760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055610e7184611742565b15610e8f57604051631685ecdd60e31b815260040160405180910390fd5b610e9984846137c0565b505060016002555050565b6000600280541415610ee65760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b6002805560005a90506000610efb8585613957565b90506000610f0f6080860160608701615739565b63ffffffff1667ffffffffffffffff811115610f2d57610f2d615e6f565b604051908082528060200260200182016040528015610f56578160200160208202803683370190505b50905060005b610f6c6080870160608801615739565b63ffffffff16811015610fe157826040015181604051602001610f99929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610fc457610fc4615e59565b602090810291909101015280610fd981615dc0565b915050610f5c565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161103291908690602401615a23565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199094169390931790925291506000906110ae906110929060608b01908b01615739565b63ffffffff166110a860a08b0160808c01615344565b84613cac565b905060006110c76110c260a08b018b615bf3565b613cfa565b51600f549091506000906110f29089906a0100000000000000000000900463ffffffff163a85613da9565b905081156111fb576020808b01356000908152600690915260409020546001600160601b03808316600160601b90920416101561114257604051631e9acf1760e31b815260040160405180910390fd5b60208a81013560009081526006909152604090208054829190600c90611179908490600160601b90046001600160601b0316615d68565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b0316835260099091528120805485945090926111d291859116615cfc565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506112e7565b6020808b01356000908152600690915260409020546001600160601b038083169116101561123c57604051631e9acf1760e31b815260040160405180910390fd5b6020808b0135600090815260069091526040812080548392906112699084906001600160601b0316615d68565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b0316835260089091528120805485945090926112c291859116615cfc565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113026040518060200160405280851515815250613df9565b90508a6020013588602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8a604001518585896040516113479493929190615b73565b60405180910390a35060016002559a9950505050505050505050565b61136c81613e7f565b61139457604051635428d44960e01b81526001600160a01b0382166004820152602401610c18565b6000806000806113a386613350565b9350935093509350336001600160a01b0316826001600160a01b03161461140c5760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c18565b61141586611742565b156114625760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c18565b60006040518060c00160405280611477600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016114cb919061593b565b60405160208183030381529060405290506114e588613ee9565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b03881690611537908590600401615928565b6000604051808303818588803b15801561155057600080fd5b505af1158015611564573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b1580156115c057600080fd5b505af11580156115d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f89190615484565b6116445760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c18565b60005b83518110156116f55783818151811061166257611662615e59565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b1580156116ca57600080fd5b505af11580156116de573d6000803e3d6000fd5b5050505080806116ed90615dc0565b915050611647565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287969395860193909291908301828280156117cc57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117ae575b505050505081525050905060005b81604001515181101561193a5760005b600c548110156119275760006118f0600c838154811061180c5761180c615e59565b90600052602060002001548560400151858151811061182d5761182d615e59565b602002602001015188600460008960400151898151811061185057611850615e59565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119145750600195945050505050565b508061191f81615dc0565b9150506117ea565b508061193281615dc0565b9150506117da565b5060009392505050565b6002805414156119845760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055336000908152600960205260409020546001600160601b03808316911610156119c457604051631e9acf1760e31b815260040160405180910390fd5b33600090815260096020526040812080548392906119ec9084906001600160601b0316615d68565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a349190615d68565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611aae576040519150601f19603f3d011682016040523d82523d6000602084013e611ab3565b606091505b5050905080611ad557604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611ae7613764565b611af081613e7f565b15611b32576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c18565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611bf65760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055336000908152600860205260409020546001600160601b0380831691161015611c3657604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611c5e9084906001600160601b0316615d68565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611ca69190615d68565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d1557600080fd5b505af1158015611d29573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d4d9190615484565b611d6a57604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611d7b613764565b604080518082018252600091611daa919084906002908390839080828437600092019190915250612eaa915050565b6000818152600b60205260409020549091506001600160a01b031615611dff576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c18565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610dab565b6001546001600160a01b03163314611ee55760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c18565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611f44613764565b600a80546001600160a01b0319166001600160a01b0392909216919091179055565b6000600280541415611fa85760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556020808301356000908152600590915260409020546001600160a01b0316611fe757604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612039576040516379bfd40160e01b815260208401356004820152336024820152604401610c18565b600f5461ffff166120506060850160408601615650565b61ffff161080612073575060c861206d6060850160408601615650565b61ffff16115b156120b9576120886060840160408501615650565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c18565b600f5462010000900463ffffffff166120d86080850160608601615739565b63ffffffff161115612141576120f46080840160608501615739565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c18565b6101f461215460a0850160808601615739565b63ffffffff1611156121b35761217060a0840160808501615739565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c18565b60006121c0826001615cd0565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061224c906110c290890189615bf3565b9050600061225982613df9565b90508361226461413b565b60208a013561227960808c0160608d01615739565b61228960a08d0160808e01615739565b33866040516020016122a19796959493929190615ab0565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d60400160208101906123189190615650565b8e606001602081019061232b9190615739565b8f608001602081019061233e9190615739565b8960405161235196959493929190615a71565b60405180910390a4505033600090815260046020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b6123af613764565b6003546001600160a01b0316156123f2576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b0319166001600160a01b0392909216919091179055565b60006002805414156124565760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055600033612468600143615d51565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b77ffffffffffffffffffffffffffffffffffffffffffffffff1916606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124f983615ddb565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561253b5761253b615e6f565b604051908082528060200260200182016040528015612564578160200160208202803683370190505b5060408051808201825260008082526020808301828152878352600682528483209351845491516001600160601b03908116600160601b0277ffffffffffffffffffffffffffffffffffffffffffffffff199093169116171790925582516060810184523381528083018281528185018681528884526005855294909220815181546001600160a01b039182166001600160a01b0319918216178355935160018301805491909216941693909317909255925180519495509293909261263192600285019291019061516f565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b6002805414156126b45760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556003546001600160a01b031633146126fc576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612736576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612744828401846154a1565b6000818152600560205260409020549091506001600160a01b031661277c57604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127a38385615cfc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127eb9190615cfc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a82878461283e9190615cb8565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b61286c613764565b6007544790600160a01b90046001600160601b0316818111156128ac576040516354ced18160e11b81526004810182905260248101839052604401610c18565b8181101561297b5760006128c08284615d51565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d806000811461290f576040519150601f19603f3d011682016040523d82523d6000602084013e612914565b606091505b505090508061293657604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b612988613764565b6000818152600560205260409020546001600160a01b03166129bd57604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c219082906001600160a01b03166137c0565b6129e8613764565b60c861ffff87161115612a225760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c18565b60008213612a46576040516321ea67b360e11b815260048101839052602401610c18565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612baa5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556000818152600560205260409020546001600160a01b0316612be357604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c5557600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c18565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526005602052604090205482906001600160a01b031680612d0f57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d4357604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415612d835760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028080556000858152600560205260409020015460641415612dd2576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612e0a57610e99565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612ebd919061591a565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612f1257604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612f4657604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415612f865760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055612f9384611742565b15612fb157604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1661300e576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c18565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561307157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613053575b505050505090506000600182516130889190615d51565b905060005b825181101561319457856001600160a01b03168382815181106130b2576130b2615e59565b60200260200101516001600160a01b031614156131825760008383815181106130dd576130dd615e59565b6020026020010151905080600560008a8152602001908152602001600020600201838154811061310f5761310f615e59565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260059091526040902060020180548061315a5761315a615e43565b600082815260209020810160001990810180546001600160a01b031916905501905550613194565b8061318c81615dc0565b91505061308d565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161284f565b600c818154811061320757600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b03168061325057604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461328457604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b6002805414156132c45760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556000848152600560205260409020600101546001600160a01b03848116911614610e995760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e97565b600081815260056020526040812054819081906060906001600160a01b031661338c57604051630fb532db60e11b815260040160405180910390fd5b60008581526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b900416946001600160a01b0390931693919283919083018282801561341d57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133ff575b5050505050905093509350935093509193509193565b61343b613764565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561349857600080fd5b505afa1580156134ac573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134d091906154ba565b6007549091506801000000000000000090046001600160601b031681811115613516576040516354ced18160e11b81526004810182905260248101839052604401610c18565b8181101561297b57600061352a8284615d51565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561357a57600080fd5b505af115801561358e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135b29190615484565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b60028054141561363b5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556000818152600560205260409020546001600160a01b031661367457604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136a38385615cfc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136eb9190615cfc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde82348461373e9190615cb8565b60408051928352602083019190915201612cc6565b61375b613764565b610c21816141d4565b6000546001600160a01b031633146137be5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c18565b565b6000806137cc84613ee9565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b15801561382957600080fd5b505af115801561383d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138619190615484565b61387e57604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d80600081146138d4576040519150601f19603f3d011682016040523d82523d6000602084013e6138d9565b606091505b50509050806138fb57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905281830181905282518084018452919290916139a09186906002908390839080828437600092019190915250612eaa915050565b6000818152600b60205260409020549091506001600160a01b0316806139dc57604051631dfd6e1360e21b815260048101839052602401610c18565b6000828660c001356040516020016139fe929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613a5d576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613a6b6020880188615754565b6020880135613a8060608a0160408b01615739565b613a9060808b0160608c01615739565b613aa060a08c0160808d01615344565b613aad60a08d018d615bf3565b604051602001613ac4989796959493929190615afa565b604051602081830303815290604052805190602001208114613b12576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613b29613b246020890189615754565b61427e565b905080613c37576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613b6c60208a018a615754565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613bac57600080fd5b505afa158015613bc0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613be491906154ba565b905080613c3757613bf86020880188615754565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c18565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c7f613c79368c90038c018c615577565b83614385565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613cbe57600080fd5b611388810390508460408204820311613cd657600080fd5b50823b613ce257600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613d235750604080516020810190915260008152613ca6565b7f92fd133800000000000000000000000000000000000000000000000000000000613d4e8385615d90565b6001600160e01b03191614613d8f576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d9c8260048186615c8e565b810190613cf391906154d3565b60008115613dd757601054613dd09086908690640100000000900463ffffffff16866143f0565b9050613df1565b601054613dee908690869063ffffffff168661445a565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613e3291511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613ee057826001600160a01b031660118281548110613eaa57613eaa615e59565b6000918252602090912001546001600160a01b03161415613ece5750600192915050565b80613ed881615dc0565b915050613e83565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613f7557602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613f57575b5050509190925250505060008581526006602090815260408083208151808301909252546001600160601b03808216808452600160601b9092041692820183905296509094509192505b826040015151811015614037576004600084604001518381518110613fe657613fe6615e59565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff191690558061402f81615dc0565b915050613fbf565b50600085815260056020526040812080546001600160a01b0319908116825560018201805490911690559061406f60028301826151d4565b50506000858152600660205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff19169055600780548591906008906140c89084906801000000000000000090046001600160601b0316615d68565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b03166141109190615d68565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b1811480614150575062066eed81145b156141cd5760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561418f57600080fd5b505afa1580156141a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906141c791906154ba565b91505090565b4391505090565b6001600160a01b03811633141561422d5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c18565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b1811480614293575062066eed81145b15614375576101008367ffffffffffffffff166142ae61413b565b6142b89190615d51565b11806142d557506142c761413b565b8367ffffffffffffffff1610155b156142e35750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561433d57600080fd5b505afa158015614351573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613cf391906154ba565b505067ffffffffffffffff164090565b60006143b98360000151846020015185604001518660600151868860a001518960c001518a60e001518b6101000151614561565b600383602001516040516020016143d1929190615a0f565b60408051601f1981840301815291905280516020909101209392505050565b6000806143fb61479c565b905060005a61440a8888615cb8565b6144149190615d51565b61441e9085615d32565b9050600061443763ffffffff871664e8d4a51000615d32565b9050826144448284615cb8565b61444e9190615cb8565b98975050505050505050565b6000806144656147f8565b90506000811361448b576040516321ea67b360e11b815260048101829052602401610c18565b600061449561479c565b9050600082825a6144a68b8b615cb8565b6144b09190615d51565b6144ba9088615d32565b6144c49190615cb8565b6144d690670de0b6b3a7640000615d32565b6144e09190615d1e565b905060006144f963ffffffff881664e8d4a51000615d32565b9050614511816b033b2e3c9fd0803ce8000000615d51565b82111561454a576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6145548183615cb8565b9998505050505050505050565b61456a896148df565b6145b65760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c18565b6145bf886148df565b61460b5760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c18565b614614836148df565b6146605760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c18565b614669826148df565b6146b55760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c18565b6146c1878a88876149b8565b61470d5760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c18565b60006147198a87614aed565b9050600061472c898b878b868989614b51565b9050600061473d838d8d8a86614c71565b9050808a1461478e5760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c18565b505050505050505050505050565b60004661a4b18114806147b1575062066eed81145b156147f057606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561418f57600080fd5b600091505090565b600f54600a54604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000936601000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b15801561487257600080fd5b505afa158015614886573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906148aa919061577e565b5094509092508491505080156148ce57506148c58242615d51565b8463ffffffff16105b15613df15750600e54949350505050565b80516000906401000003d019116149385760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c18565b60208201516401000003d019116149915760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c18565b60208201516401000003d0199080096149b18360005b6020020151614cb1565b1492915050565b60006001600160a01b038216614a105760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c18565b602084015160009060011615614a2757601c614a2a565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614ac5573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614af56151f2565b614b2260018484604051602001614b0e939291906158f9565b604051602081830303815290604052614cd5565b90505b614b2e816148df565b613ca6578051604080516020810192909252614b4a9101614b0e565b9050614b25565b614b596151f2565b825186516401000003d0199081900691061415614bb85760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c18565b614bc3878988614d24565b614c0f5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c18565b614c1a848685614d24565b614c665760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c18565b61444e868484614e5e565b600060028686868587604051602001614c8f9695949392919061589a565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614cdd6151f2565b614ce682614f25565b8152614cfb614cf68260006149a7565b614f60565b602082018190526002900660011415614d1f576020810180516401000003d0190390525b919050565b600082614d735760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c18565b83516020850151600090614d8990600290615e03565b15614d9557601c614d98565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614e0a573d6000803e3d6000fd5b505050602060405103519050600086604051602001614e299190615888565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614e666151f2565b835160208086015185519186015160009384938493614e8793909190614f80565b919450925090506401000003d019858209600114614ee75760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c18565b60405180604001604052806401000003d01980614f0657614f06615e2d565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614d1f57604080516020808201939093528151808203840181529082019091528051910120614f2d565b6000613ca6826002614f796401000003d0196001615cb8565b901c615060565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614fc083838585615102565b9098509050614fd188828e88615126565b9098509050614fe288828c87615126565b90985090506000614ff58d878b85615126565b909850905061500688828686615102565b909850905061501788828e89615126565b909850905081811461504c576401000003d019818a0998506401000003d01982890997506401000003d0198183099650615050565b8196505b5050505050509450945094915050565b60008061506b615210565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a082015261509d61522e565b60208160c0846005600019fa9250826150f85760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c18565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156151c4579160200282015b828111156151c457825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019061518f565b506151d092915061524c565b5090565b5080546000825590600052602060002090810190610c21919061524c565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156151d0576000815560010161524d565b8035614d1f81615e85565b8060408101831015613ca657600080fd5b600082601f83011261528e57600080fd5b615296615c41565b8083856040860111156152a857600080fd5b60005b60028110156152ca5781358452602093840193909101906001016152ab565b509095945050505050565b600060c082840312156152e757600080fd5b50919050565b803561ffff81168114614d1f57600080fd5b803563ffffffff81168114614d1f57600080fd5b805169ffffffffffffffffffff81168114614d1f57600080fd5b80356001600160601b0381168114614d1f57600080fd5b60006020828403121561535657600080fd5b8135613cf381615e85565b6000806040838503121561537457600080fd5b823561537f81615e85565b915061538d6020840161532d565b90509250929050565b600080606083850312156153a957600080fd5b82356153b481615e85565b915061538d846020850161526c565b600080600080606085870312156153d957600080fd5b84356153e481615e85565b935060208501359250604085013567ffffffffffffffff8082111561540857600080fd5b818701915087601f83011261541c57600080fd5b81358181111561542b57600080fd5b88602082850101111561543d57600080fd5b95989497505060200194505050565b60006040828403121561545e57600080fd5b613cf3838361526c565b60006040828403121561547a57600080fd5b613cf3838361527d565b60006020828403121561549657600080fd5b8151613cf381615e9a565b6000602082840312156154b357600080fd5b5035919050565b6000602082840312156154cc57600080fd5b5051919050565b6000602082840312156154e557600080fd5b6040516020810181811067ffffffffffffffff8211171561550857615508615e6f565b604052823561551681615e9a565b81529392505050565b6000808284036101c081121561553457600080fd5b6101a08082121561554457600080fd5b849350830135905067ffffffffffffffff81111561556157600080fd5b61556d858286016152d5565b9150509250929050565b60006101a0828403121561558a57600080fd5b615592615c6a565b61559c848461527d565b81526155ab846040850161527d565b60208201526080830135604082015260a0830135606082015260c083013560808201526155da60e08401615261565b60a08201526101006155ee8582860161527d565b60c083015261560185610140860161527d565b60e083015261018084013581830152508091505092915050565b60006020828403121561562d57600080fd5b813567ffffffffffffffff81111561564457600080fd5b613df1848285016152d5565b60006020828403121561566257600080fd5b613cf3826152ed565b60008060008060008086880360e081121561568557600080fd5b61568e886152ed565b965061569c602089016152ff565b95506156aa604089016152ff565b94506156b8606089016152ff565b9350608088013592506040609f19820112156156d357600080fd5b506156dc615c41565b6156e860a089016152ff565b81526156f660c089016152ff565b6020820152809150509295509295509295565b6000806040838503121561571c57600080fd5b82359150602083013561572e81615e85565b809150509250929050565b60006020828403121561574b57600080fd5b613cf3826152ff565b60006020828403121561576657600080fd5b813567ffffffffffffffff81168114613cf357600080fd5b600080600080600060a0868803121561579657600080fd5b61579f86615313565b94506020860151935060408601519250606086015191506157c260808701615313565b90509295509295909350565b600081518084526020808501945080840160005b838110156158075781516001600160a01b0316875295820195908201906001016157e2565b509495945050505050565b8060005b6002811015615835578151845260209384019390910190600101615816565b50505050565b6000815180845260005b8181101561586157602081850181015186830182015201615845565b81811115615873576000602083870101525b50601f01601f19169290920160200192915050565b6158928183615812565b604001919050565b8681526158aa6020820187615812565b6158b76060820186615812565b6158c460a0820185615812565b6158d160e0820184615812565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526159096020820184615812565b606081019190915260800192915050565b60408101613ca68284615812565b602081526000613cf3602083018461583b565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261598160e08401826157ce565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615a01578451835293830193918301916001016159e5565b509098975050505050505050565b82815260608101613cf36020830184615812565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a6457845183529383019391830191600101615a48565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261444e60c083018461583b565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261455460e083018461583b565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b9b608083018561583b565b9050821515606083015295945050505050565b60006001600160601b0380871683528086166020840152506001600160a01b038416604083015260806060830152615be960808301846157ce565b9695505050505050565b6000808335601e19843603018112615c0a57600080fd5b83018035915067ffffffffffffffff821115615c2557600080fd5b602001915036819003821315615c3a57600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c6457615c64615e6f565b60405290565b604051610120810167ffffffffffffffff81118282101715615c6457615c64615e6f565b60008085851115615c9e57600080fd5b83861115615cab57600080fd5b5050820193919092039150565b60008219821115615ccb57615ccb615e17565b500190565b600067ffffffffffffffff808316818516808303821115615cf357615cf3615e17565b01949350505050565b60006001600160601b03808316818516808303821115615cf357615cf3615e17565b600082615d2d57615d2d615e2d565b500490565b6000816000190483118215151615615d4c57615d4c615e17565b500290565b600082821015615d6357615d63615e17565b500390565b60006001600160601b0383811690831681811015615d8857615d88615e17565b039392505050565b6001600160e01b03198135818116916004851015615db85780818660040360031b1b83161692505b505092915050565b6000600019821415615dd457615dd4615e17565b5060010190565b600067ffffffffffffffff80831681811415615df957615df9615e17565b6001019392505050565b600082615e1257615e12615e2d565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c2157600080fd5b8015158114610c2157600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI @@ -2299,34 +2299,45 @@ func (it *VRFCoordinatorV2PlusRandomWordsFulfilledIterator) Close() error { type VRFCoordinatorV2PlusRandomWordsFulfilled struct { RequestId *big.Int OutputSeed *big.Int + SubID *big.Int Payment *big.Int ExtraArgs []byte Success bool Raw types.Log } -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusFilterer) FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestId []*big.Int) (*VRFCoordinatorV2PlusRandomWordsFulfilledIterator, error) { +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusFilterer) FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestId []*big.Int, subID []*big.Int) (*VRFCoordinatorV2PlusRandomWordsFulfilledIterator, error) { var requestIdRule []interface{} for _, requestIdItem := range requestId { requestIdRule = append(requestIdRule, requestIdItem) } - logs, sub, err := _VRFCoordinatorV2Plus.contract.FilterLogs(opts, "RandomWordsFulfilled", requestIdRule) + var subIDRule []interface{} + for _, subIDItem := range subID { + subIDRule = append(subIDRule, subIDItem) + } + + logs, sub, err := _VRFCoordinatorV2Plus.contract.FilterLogs(opts, "RandomWordsFulfilled", requestIdRule, subIDRule) if err != nil { return nil, err } return &VRFCoordinatorV2PlusRandomWordsFulfilledIterator{contract: _VRFCoordinatorV2Plus.contract, event: "RandomWordsFulfilled", logs: logs, sub: sub}, nil } -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusFilterer) WatchRandomWordsFulfilled(opts *bind.WatchOpts, sink chan<- *VRFCoordinatorV2PlusRandomWordsFulfilled, requestId []*big.Int) (event.Subscription, error) { +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusFilterer) WatchRandomWordsFulfilled(opts *bind.WatchOpts, sink chan<- *VRFCoordinatorV2PlusRandomWordsFulfilled, requestId []*big.Int, subID []*big.Int) (event.Subscription, error) { var requestIdRule []interface{} for _, requestIdItem := range requestId { requestIdRule = append(requestIdRule, requestIdItem) } - logs, sub, err := _VRFCoordinatorV2Plus.contract.WatchLogs(opts, "RandomWordsFulfilled", requestIdRule) + var subIDRule []interface{} + for _, subIDItem := range subID { + subIDRule = append(subIDRule, subIDItem) + } + + logs, sub, err := _VRFCoordinatorV2Plus.contract.WatchLogs(opts, "RandomWordsFulfilled", requestIdRule, subIDRule) if err != nil { return nil, err } @@ -3658,7 +3669,7 @@ func (VRFCoordinatorV2PlusProvingKeyRegistered) Topic() common.Hash { } func (VRFCoordinatorV2PlusRandomWordsFulfilled) Topic() common.Hash { - return common.HexToHash("0x2c7b705f67f9ae2cbd3edc06b5b99afb00441ee4aea7bb77f109273bc1f3b5eb") + return common.HexToHash("0x7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e") } func (VRFCoordinatorV2PlusRandomWordsRequested) Topic() common.Hash { @@ -3860,9 +3871,9 @@ type VRFCoordinatorV2PlusInterface interface { ParseProvingKeyRegistered(log types.Log) (*VRFCoordinatorV2PlusProvingKeyRegistered, error) - FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestId []*big.Int) (*VRFCoordinatorV2PlusRandomWordsFulfilledIterator, error) + FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestId []*big.Int, subID []*big.Int) (*VRFCoordinatorV2PlusRandomWordsFulfilledIterator, error) - WatchRandomWordsFulfilled(opts *bind.WatchOpts, sink chan<- *VRFCoordinatorV2PlusRandomWordsFulfilled, requestId []*big.Int) (event.Subscription, error) + WatchRandomWordsFulfilled(opts *bind.WatchOpts, sink chan<- *VRFCoordinatorV2PlusRandomWordsFulfilled, requestId []*big.Int, subID []*big.Int) (event.Subscription, error) ParseRandomWordsFulfilled(log types.Log) (*VRFCoordinatorV2PlusRandomWordsFulfilled, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 50e31b6cfa4..e059fc5f92f 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -70,7 +70,7 @@ vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsume vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 8b9603ed36f8ec1cf33c1ee87f51631d06122781d822563cd327ca6fbb42cb7a +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 61b058b2fcd891bc86198d13c5f2bbcc053cab338ea7c1acd6b0eea5a122d9a1 vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c diff --git a/core/services/vrf/v2/coordinator_v2x_interface.go b/core/services/vrf/v2/coordinator_v2x_interface.go index 9535c501260..98b543c33c2 100644 --- a/core/services/vrf/v2/coordinator_v2x_interface.go +++ b/core/services/vrf/v2/coordinator_v2x_interface.go @@ -43,7 +43,7 @@ type CoordinatorV2_X interface { RegisterProvingKey(opts *bind.TransactOpts, oracle common.Address, publicProvingKey [2]*big.Int) (*types.Transaction, error) FilterSubscriptionCreated(opts *bind.FilterOpts, subID []*big.Int) (SubscriptionCreatedIterator, error) FilterRandomWordsRequested(opts *bind.FilterOpts, keyHash [][32]byte, subID []*big.Int, sender []common.Address) (RandomWordsRequestedIterator, error) - FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestID []*big.Int) (RandomWordsFulfilledIterator, error) + FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestID []*big.Int, subID []*big.Int) (RandomWordsFulfilledIterator, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) RemoveConsumer(opts *bind.TransactOpts, subID *big.Int, consumer common.Address) (*types.Transaction, error) CancelSubscription(opts *bind.TransactOpts, subID *big.Int, to common.Address) (*types.Transaction, error) @@ -144,7 +144,7 @@ func (c *coordinatorV2) FilterRandomWordsRequested(opts *bind.FilterOpts, keyHas return NewV2RandomWordsRequestedIterator(it), nil } -func (c *coordinatorV2) FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestID []*big.Int) (RandomWordsFulfilledIterator, error) { +func (c *coordinatorV2) FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestID []*big.Int, subID []*big.Int) (RandomWordsFulfilledIterator, error) { it, err := c.coordinator.FilterRandomWordsFulfilled(opts, requestID) if err != nil { return nil, err @@ -274,8 +274,8 @@ func (c *coordinatorV2Plus) FilterRandomWordsRequested(opts *bind.FilterOpts, ke return NewV2PlusRandomWordsRequestedIterator(it), nil } -func (c *coordinatorV2Plus) FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestID []*big.Int) (RandomWordsFulfilledIterator, error) { - it, err := c.coordinator.FilterRandomWordsFulfilled(opts, requestID) +func (c *coordinatorV2Plus) FilterRandomWordsFulfilled(opts *bind.FilterOpts, requestID []*big.Int, subID []*big.Int) (RandomWordsFulfilledIterator, error) { + it, err := c.coordinator.FilterRandomWordsFulfilled(opts, requestID, subID) if err != nil { return nil, err } @@ -569,6 +569,7 @@ type RandomWordsFulfilled interface { RequestID() *big.Int Success() bool NativePayment() bool + SubID() *big.Int Payment() *big.Int Raw() types.Log } @@ -597,6 +598,10 @@ func (rwf *v2RandomWordsFulfilled) NativePayment() bool { return false } +func (rwf *v2RandomWordsFulfilled) SubID() *big.Int { + panic("VRF V2 RandomWordsFulfilled does not implement SubID") +} + func (rwf *v2RandomWordsFulfilled) Payment() *big.Int { return rwf.event.Payment } @@ -633,6 +638,10 @@ func (rwf *v2PlusRandomWordsFulfilled) NativePayment() bool { return nativePayment } +func (rwf *v2PlusRandomWordsFulfilled) SubID() *big.Int { + return rwf.event.SubID +} + func (rwf *v2PlusRandomWordsFulfilled) Payment() *big.Int { return rwf.event.Payment } diff --git a/core/services/vrf/v2/integration_helpers_test.go b/core/services/vrf/v2/integration_helpers_test.go index 4f99b00cd16..9a085af576c 100644 --- a/core/services/vrf/v2/integration_helpers_test.go +++ b/core/services/vrf/v2/integration_helpers_test.go @@ -54,7 +54,8 @@ func testSingleConsumerHappyPath( assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, - rwfe v22.RandomWordsFulfilled), + rwfe v22.RandomWordsFulfilled, + subID *big.Int), ) { key1 := cltest.MustGenerateRandomKey(t) key2 := cltest.MustGenerateRandomKey(t) @@ -118,7 +119,7 @@ func testSingleConsumerHappyPath( // * payment should be exactly the amount specified as the premium in the coordinator fee config rwfe := assertRandomWordsFulfilled(t, requestID1, true, coordinator) if len(assertions) > 0 { - assertions[0](t, coordinator, rwfe) + assertions[0](t, coordinator, rwfe, subID) } // Make the second randomness request and assert fulfillment is successful @@ -138,7 +139,7 @@ func testSingleConsumerHappyPath( // * payment should be exactly the amount specified as the premium in the coordinator fee config rwfe = assertRandomWordsFulfilled(t, requestID2, true, coordinator) if len(assertions) > 0 { - assertions[0](t, coordinator, rwfe) + assertions[0](t, coordinator, rwfe, subID) } // Assert correct number of random words sent by coordinator. @@ -345,7 +346,8 @@ func testSingleConsumerHappyPathBatchFulfillment( assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, - rwfe v22.RandomWordsFulfilled), + rwfe v22.RandomWordsFulfilled, + subID *big.Int), ) { key1 := cltest.MustGenerateRandomKey(t) gasLanePriceWei := assets.GWei(10) @@ -422,7 +424,7 @@ func testSingleConsumerHappyPathBatchFulfillment( rwfe = assertRandomWordsFulfilled(t, requestID, false, coordinator) } if len(assertions) > 0 { - assertions[0](t, coordinator, rwfe) + assertions[0](t, coordinator, rwfe, subID) } } @@ -1495,7 +1497,7 @@ func testMaliciousConsumer( require.Equal(t, uint64(1), r.Status) // The user callback should have errored - it, err := uni.rootContract.FilterRandomWordsFulfilled(nil, nil) + it, err := uni.rootContract.FilterRandomWordsFulfilled(nil, nil, nil) require.NoError(t, err) var fulfillments []v22.RandomWordsFulfilled for it.Next() { diff --git a/core/services/vrf/v2/integration_v2_plus_test.go b/core/services/vrf/v2/integration_v2_plus_test.go index 96873be43d1..1db674f25fc 100644 --- a/core/services/vrf/v2/integration_v2_plus_test.go +++ b/core/services/vrf/v2/integration_v2_plus_test.go @@ -292,6 +292,11 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment(t *testi 5, // number of requests to send false, // don't send big callback vrfcommon.V2Plus, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }, ) } @@ -313,6 +318,11 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment_BigGasCa 5, // number of requests to send true, // send big callback vrfcommon.V2Plus, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }, ) } @@ -331,7 +341,12 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath(t *testing.T) { uni.rootContractAddress, uni.batchCoordinatorContractAddress, nil, - vrfcommon.V2Plus) + vrfcommon.V2Plus, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }) } func TestVRFV2PlusIntegration_SingleConsumer_EOA_Request(t *testing.T) { diff --git a/core/services/vrf/v2/integration_v2_test.go b/core/services/vrf/v2/integration_v2_test.go index ce5e5999c34..c2cbac95ec6 100644 --- a/core/services/vrf/v2/integration_v2_test.go +++ b/core/services/vrf/v2/integration_v2_test.go @@ -714,7 +714,7 @@ func assertRandomWordsFulfilled( numChecks := 3 found := false for i := 0; i < numChecks; i++ { - filter, err := coordinator.FilterRandomWordsFulfilled(nil, []*big.Int{requestID}) + filter, err := coordinator.FilterRandomWordsFulfilled(nil, []*big.Int{requestID}, nil) require.NoError(t, err) for filter.Next() { require.Equal(t, expectedSuccess, filter.Event().Success(), "fulfillment event success not correct, expected: %+v, actual: %+v", expectedSuccess, filter.Event().Success()) @@ -893,6 +893,11 @@ func TestVRFV2Integration_SingleConsumer_HappyPath(t *testing.T) { uni.batchCoordinatorContractAddress, ptr(uni.vrfOwnerAddress), vrfcommon.V2, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + require.PanicsWithValue(t, "VRF V2 RandomWordsFulfilled does not implement SubID", func() { + rwfe.SubID() + }) + }, ) } @@ -1603,7 +1608,7 @@ func TestIntegrationVRFV2(t *testing.T) { // Wait for the request to be fulfilled on-chain. var rf []v22.RandomWordsFulfilled gomega.NewWithT(t).Eventually(func() bool { - rfIterator, err2 := uni.rootContract.FilterRandomWordsFulfilled(nil, nil) + rfIterator, err2 := uni.rootContract.FilterRandomWordsFulfilled(nil, nil, nil) require.NoError(t, err2, "failed to logs") uni.backend.Commit() for rfIterator.Next() { From 506b5c9dfd8cbacaf6538af421f19c172ec5e878 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Thu, 27 Jul 2023 06:27:13 -0700 Subject: [PATCH 014/270] [Functions] Support flags in Listener (#9947) 1. Implement handleOracleRequestV1 to handle new OracleRequest type. 2. Parse flags and enforce relevant limits. 3. Pass flags to the EA. --- .../functions/external_adapter_client.go | 4 + .../functions/external_adapter_client_test.go | 10 +- core/services/functions/listener.go | 97 ++++++++++++++++--- core/services/functions/listener_test.go | 85 ++++++++++++++-- .../mocks/external_adapter_client.go | 26 ++--- core/services/functions/request.go | 2 + .../ocr2/plugins/functions/config/config.go | 2 + 7 files changed, 184 insertions(+), 42 deletions(-) diff --git a/core/services/functions/external_adapter_client.go b/core/services/functions/external_adapter_client.go index 3bd8ff74046..fc12406e442 100644 --- a/core/services/functions/external_adapter_client.go +++ b/core/services/functions/external_adapter_client.go @@ -33,6 +33,7 @@ type ExternalAdapterClient interface { jobName string, subscriptionOwner string, subscriptionId uint64, + flags RequestFlags, nodeProvidedSecrets string, requestData *RequestData, ) (userResult, userError []byte, domains []string, err error) @@ -66,6 +67,7 @@ type requestPayload struct { JobName string `json:"jobName"` SubscriptionOwner string `json:"subscriptionOwner"` SubscriptionId uint64 `json:"subscriptionId"` + Flags RequestFlags `json:"flags"` // marshalled as an array of numbers NodeProvidedSecrets string `json:"nodeProvidedSecrets"` Data *RequestData `json:"data"` } @@ -123,6 +125,7 @@ func (ea *externalAdapterClient) RunComputation( jobName string, subscriptionOwner string, subscriptionId uint64, + flags RequestFlags, nodeProvidedSecrets string, requestData *RequestData, ) (userResult, userError []byte, domains []string, err error) { @@ -133,6 +136,7 @@ func (ea *externalAdapterClient) RunComputation( JobName: jobName, SubscriptionOwner: subscriptionOwner, SubscriptionId: subscriptionId, + Flags: flags, NodeProvidedSecrets: nodeProvidedSecrets, Data: requestData, } diff --git a/core/services/functions/external_adapter_client_test.go b/core/services/functions/external_adapter_client_test.go index 9feb3c689c0..a0d6d461099 100644 --- a/core/services/functions/external_adapter_client_test.go +++ b/core/services/functions/external_adapter_client_test.go @@ -51,7 +51,7 @@ func runRequestTest(t *testing.T, adapterJSONResponse, expectedUserResult, expec assert.NoError(t, err, "Unexpected error") ea := functions.NewExternalAdapterClient(*adapterUrl, 100_000) - userResult, userError, domains, err := ea.RunComputation(testutils.Context(t), "requestID1234", "TestJob", "SubOwner", 1, "", &functions.RequestData{}) + userResult, userError, domains, err := ea.RunComputation(testutils.Context(t), "requestID1234", "TestJob", "SubOwner", 1, functions.RequestFlags{}, "", &functions.RequestData{}) if expectedError != nil { assert.Equal(t, expectedError.Error(), err.Error(), "Unexpected error") @@ -167,7 +167,7 @@ func TestRunComputation_CorrectAdapterRequest(t *testing.T) { body, err := io.ReadAll(r.Body) assert.NoError(t, err) expectedData := `{"source":"abcd","language":7,"codeLocation":42,"secrets":"qrvM","secretsLocation":88,"args":["arg1","arg2"]}` - expectedBody := fmt.Sprintf(`{"endpoint":"lambda","requestId":"requestID1234","jobName":"TestJob","subscriptionOwner":"SubOwner","subscriptionId":1,"nodeProvidedSecrets":"secRETS","data":%s}`, expectedData) + expectedBody := fmt.Sprintf(`{"endpoint":"lambda","requestId":"requestID1234","jobName":"TestJob","subscriptionOwner":"SubOwner","subscriptionId":1,"flags":[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],"nodeProvidedSecrets":"secRETS","data":%s}`, expectedData) assert.Equal(t, expectedBody, string(body)) fmt.Fprintln(w, "}}invalidJSON") @@ -186,7 +186,7 @@ func TestRunComputation_CorrectAdapterRequest(t *testing.T) { SecretsLocation: 88, Args: []string{"arg1", "arg2"}, } - _, _, _, err = ea.RunComputation(testutils.Context(t), "requestID1234", "TestJob", "SubOwner", 1, "secRETS", reqData) + _, _, _, err = ea.RunComputation(testutils.Context(t), "requestID1234", "TestJob", "SubOwner", 1, functions.RequestFlags{}, "secRETS", reqData) assert.Error(t, err) } @@ -200,7 +200,7 @@ func TestRunComputation_HTTP500(t *testing.T) { assert.NoError(t, err) ea := functions.NewExternalAdapterClient(*adapterUrl, 100_000) - _, _, _, err = ea.RunComputation(testutils.Context(t), "requestID1234", "TestJob", "SubOwner", 1, "secRETS", &functions.RequestData{}) + _, _, _, err = ea.RunComputation(testutils.Context(t), "requestID1234", "TestJob", "SubOwner", 1, functions.RequestFlags{}, "secRETS", &functions.RequestData{}) assert.Error(t, err) } @@ -217,7 +217,7 @@ func TestRunComputation_ContextRespected(t *testing.T) { ea := functions.NewExternalAdapterClient(*adapterUrl, 100_000) ctx, cancel := context.WithTimeout(testutils.Context(t), 10*time.Millisecond) defer cancel() - _, _, _, err = ea.RunComputation(ctx, "requestID1234", "TestJob", "SubOwner", 1, "secRETS", &functions.RequestData{}) + _, _, _, err = ea.RunComputation(ctx, "requestID1234", "TestJob", "SubOwner", 1, functions.RequestFlags{}, "secRETS", &functions.RequestData{}) assert.Error(t, err) close(done) } diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index c5ecb5f2c2a..98f1a2799d8 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -3,6 +3,7 @@ package functions import ( "context" "fmt" + "math" "reflect" "sync" "time" @@ -15,6 +16,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/cbor" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" @@ -111,6 +113,9 @@ const ( DefaultPruneMaxStoredRequests uint32 = 20_000 DefaultPruneCheckFrequencySec uint32 = 60 * 10 DefaultPruneBatchSize uint32 = 500 + + FlagCBORMaxSize uint32 = 1 + FlagSecretsMaxSize uint32 = 2 ) type FunctionsListener struct { @@ -274,7 +279,7 @@ func (l *FunctionsListener) processOracleEvents() { case *ocr2dr_oracle.OCR2DROracleOracleRequest: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleRequest").Inc() l.shutdownWaitGroup.Add(1) - go l.handleOracleRequest(log, lb) + go l.handleOracleRequestV0(log, lb) case *ocr2dr_oracle.OCR2DROracleOracleResponse: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleResponse").Inc() l.shutdownWaitGroup.Add(1) @@ -317,13 +322,64 @@ func (l *FunctionsListener) setError(ctx context.Context, requestId RequestID, e } } -func (l *FunctionsListener) handleOracleRequest(request *ocr2dr_oracle.OCR2DROracleOracleRequest, lb log.Broadcast) { +func (l *FunctionsListener) getMaxCBORsize(flags RequestFlags) uint32 { + idx := flags[FlagCBORMaxSize] + if int(idx) >= len(l.pluginConfig.MaxRequestSizesList) { + return l.pluginConfig.MaxRequestSizeBytes // deprecated + } + return l.pluginConfig.MaxRequestSizesList[idx] +} + +func (l *FunctionsListener) getMaxSecretsSize(flags RequestFlags) uint32 { + idx := flags[FlagSecretsMaxSize] + if int(idx) >= len(l.pluginConfig.MaxSecretsSizesList) { + return math.MaxUint32 // not enforced if not configured + } + return l.pluginConfig.MaxSecretsSizesList[idx] +} + +// TODO (FUN-662): call from LogPoller in a separate goroutine +func (l *FunctionsListener) HandleOracleRequestV1(request *functions_coordinator.FunctionsCoordinatorOracleRequest, coordinatorContractAddress *common.Address, lb log.Broadcast) { + l.logger.Infow("oracle request v1 received", "requestID", formatRequestId(request.RequestId)) + ctx, cancel := l.getNewHandlerContext() + defer cancel() + + callbackGasLimit := uint32(request.CallbackGasLimit) + newReq := &Request{ + RequestID: request.RequestId, + RequestTxHash: &request.Raw.TxHash, + ReceivedAt: time.Now(), + Flags: request.Flags[:], + CallbackGasLimit: &callbackGasLimit, + CoordinatorContractAddress: coordinatorContractAddress, + } + if err := l.pluginORM.CreateRequest(newReq, pg.WithParentCtx(ctx)); err != nil { + if errors.Is(err, ErrDuplicateRequestID) { + l.logger.Warnw("received a log with duplicate request ID", "requestID", formatRequestId(request.RequestId), "err", err) + l.markLogConsumed(lb, pg.WithParentCtx(ctx)) + } else { + l.logger.Errorw("failed to create a DB entry for new request", "requestID", formatRequestId(request.RequestId), "err", err) + } + return + } + l.markLogConsumed(lb, pg.WithParentCtx(ctx)) + + promRequestDataSize.WithLabelValues(l.oracleHexAddr).Observe(float64(len(request.Data))) + requestData, err := l.parseCBOR(request.RequestId, request.Data, l.getMaxCBORsize(request.Flags)) + if err != nil { + l.setError(ctx, request.RequestId, USER_ERROR, []byte(err.Error())) + return + } + l.handleRequest(ctx, request.RequestId, request.SubscriptionId, request.SubscriptionOwner, request.Flags, requestData) +} + +// deprecated +func (l *FunctionsListener) handleOracleRequestV0(request *ocr2dr_oracle.OCR2DROracleOracleRequest, lb log.Broadcast) { defer l.shutdownWaitGroup.Done() ctx, cancel := l.getNewHandlerContext() defer cancel() l.logger.Infow("oracle request received", "requestID", formatRequestId(request.RequestId)) - // TODO(FUN-617) extract and set new fields (Flags, AggregationMethod, CallbackGasLimit, CoordinatorContractAddress, OnchainMetadata) newReq := &Request{RequestID: request.RequestId, RequestTxHash: &request.Raw.TxHash, ReceivedAt: time.Now()} if err := l.pluginORM.CreateRequest(newReq, pg.WithParentCtx(ctx)); err != nil { if errors.Is(err, ErrDuplicateRequestID) { @@ -337,24 +393,30 @@ func (l *FunctionsListener) handleOracleRequest(request *ocr2dr_oracle.OCR2DROra l.markLogConsumed(lb, pg.WithParentCtx(ctx)) promRequestDataSize.WithLabelValues(l.oracleHexAddr).Observe(float64(len(request.Data))) - - if l.pluginConfig.MaxRequestSizeBytes > 0 && uint32(len(request.Data)) > l.pluginConfig.MaxRequestSizeBytes { - l.logger.Errorw("request too big", "requestID", formatRequestId(request.RequestId), "requestSize", len(request.Data), "maxRequestSize", l.pluginConfig.MaxRequestSizeBytes) - l.setError(ctx, request.RequestId, USER_ERROR, []byte(fmt.Sprintf("request too big (max %d bytes)", l.pluginConfig.MaxRequestSizeBytes))) + requestData, err := l.parseCBOR(request.RequestId, request.Data, l.pluginConfig.MaxRequestSizeBytes) + if err != nil { + l.setError(ctx, request.RequestId, USER_ERROR, []byte(err.Error())) return } + l.handleRequest(ctx, request.RequestId, request.SubscriptionId, request.SubscriptionOwner, [32]byte{}, requestData) +} + +func (l *FunctionsListener) parseCBOR(requestId RequestID, cborData []byte, maxSizeBytes uint32) (*RequestData, error) { + if maxSizeBytes > 0 && uint32(len(cborData)) > maxSizeBytes { + l.logger.Errorw("request too big", "requestID", formatRequestId(requestId), "requestSize", len(cborData), "maxRequestSize", maxSizeBytes) + return nil, fmt.Errorf("request too big (max %d bytes)", maxSizeBytes) + } var requestData RequestData - if err := cbor.ParseDietCBORToStruct(request.Data, &requestData); err != nil { - l.logger.Errorw("failed to parse CBOR", "requestID", formatRequestId(request.RequestId), "err", err) - l.setError(ctx, request.RequestId, USER_ERROR, []byte("CBOR parsing error")) - return + if err := cbor.ParseDietCBORToStruct(cborData, &requestData); err != nil { + l.logger.Errorw("failed to parse CBOR", "requestID", formatRequestId(requestId), "err", err) + return nil, errors.New("CBOR parsing error") } - l.handleRequest(ctx, request.RequestId, request.SubscriptionId, request.SubscriptionOwner, &requestData) + return &requestData, nil } -func (l *FunctionsListener) handleRequest(ctx context.Context, requestID [32]byte, subscriptionId uint64, subscriptionOwner common.Address, requestData *RequestData) { +func (l *FunctionsListener) handleRequest(ctx context.Context, requestID RequestID, subscriptionId uint64, subscriptionOwner common.Address, flags RequestFlags, requestData *RequestData) { startTime := time.Now() defer func() { duration := time.Since(startTime) @@ -383,7 +445,14 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID [32]byt return } - computationResult, computationError, domains, err := eaClient.RunComputation(ctx, requestIDStr, l.job.Name.ValueOrZero(), subscriptionOwner.Hex(), subscriptionId, nodeProvidedSecrets, requestData) + maxSecretsSize := l.getMaxSecretsSize(flags) + if uint32(len(nodeProvidedSecrets)) > maxSecretsSize { + l.logger.Errorw("secrets size too big", "requestID", requestIDStr, "secretsSize", len(nodeProvidedSecrets), "maxSecretsSize", maxSecretsSize) + l.setError(ctx, requestID, USER_ERROR, []byte("secrets size too big")) + return + } + + computationResult, computationError, domains, err := eaClient.RunComputation(ctx, requestIDStr, l.job.Name.ValueOrZero(), subscriptionOwner.Hex(), subscriptionId, flags, nodeProvidedSecrets, requestData) if err != nil { l.logger.Errorw("internal adapter error", "requestID", requestIDStr, "err", err) diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index b33684d71d9..26f0f918b21 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -17,6 +17,7 @@ import ( "google.golang.org/protobuf/proto" log_mocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log/mocks" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" @@ -66,7 +67,7 @@ var ( DecryptedSecrets []byte = []byte(`{"0x0":"lhcK"}`) ) -func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySec int) *FunctionsListenerUniverse { +func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySec int, setTiers bool) *FunctionsListenerUniverse { cfg := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { c.EVM[0].MinIncomingConfirmations = ptr[uint32](1) }) @@ -92,6 +93,10 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe "decryptRequestTimeoutSec": 100, }, } + if setTiers { + jsonConfig["maxRequestSizesList"] = []uint32{10, 100, 1_000} + jsonConfig["maxSecretsSizesList"] = []uint32{10, 100, 200} + } jb := job.Job{ Type: job.OffchainReporting2, SchemaVersion: 1, @@ -131,7 +136,7 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe } func PrepareAndStartFunctionsListener(t *testing.T, cbor []byte) (*FunctionsListenerUniverse, *log_mocks.Broadcast, chan struct{}) { - uni := NewFunctionsListenerUniverse(t, 0, 1_000_000) + uni := NewFunctionsListenerUniverse(t, 0, 1_000_000, false) uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) err := uni.service.Start(testutils.Context(t)) @@ -161,7 +166,7 @@ func TestFunctionsListener_HandleOracleRequestSuccess(t *testing.T) { uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) - uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) }).Return(nil) @@ -194,7 +199,7 @@ func TestFunctionsListener_ThresholdDecryptedSecrets(t *testing.T) { uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) uni.eaClient.On("FetchEncryptedSecrets", mock.Anything, mock.Anything, RequestIDStr, mock.Anything, mock.Anything).Return(EncryptedSecrets, nil, nil) uni.decryptor.On("Decrypt", mock.Anything, []byte(RequestIDStr), EncryptedSecrets).Return(DecryptedSecrets, nil) - uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, string(DecryptedSecrets), mock.Anything).Return(ResultBytes, nil, nil, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, string(DecryptedSecrets), mock.Anything).Return(ResultBytes, nil, nil, nil) uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) }).Return(nil) @@ -261,7 +266,7 @@ func TestFunctionsListener_ReportSourceCodeDomains(t *testing.T) { uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) - uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything).Return(ResultBytes, nil, Domains, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, Domains, nil) uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) }).Return(nil) @@ -293,7 +298,7 @@ func TestFunctionsListener_HandleOracleRequestComputationError(t *testing.T) { uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) - uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything).Return(nil, ErrorBytes, nil, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(nil, ErrorBytes, nil, nil) uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, ErrorBytes, mock.Anything, true, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) }).Return(nil) @@ -376,8 +381,8 @@ func TestFunctionsListener_HandleOracleRequestCBORParsingCorrect(t *testing.T) { uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) - uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { - reqData := args.Get(6).(*functions_service.RequestData) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { + reqData := args.Get(7).(*functions_service.RequestData) assert.Equal(t, incomingData.Source, reqData.Source) assert.Equal(t, incomingData.Language, reqData.Language) assert.Equal(t, incomingData.Secrets, reqData.Secrets) @@ -398,7 +403,7 @@ func TestFunctionsListener_RequestTimeout(t *testing.T) { reqId := newRequestID() doneCh := make(chan bool) - uni := NewFunctionsListenerUniverse(t, 1, 1_000_000) + uni := NewFunctionsListenerUniverse(t, 1, 1_000_000, false) uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) uni.pluginORM.On("TimeoutExpiredResults", mock.Anything, uint32(1), mock.Anything).Return([]functions_service.RequestID{reqId}, nil).Run(func(args mock.Arguments) { doneCh <- true @@ -435,7 +440,7 @@ func TestFunctionsListener_PruneRequests(t *testing.T) { t.Parallel() doneCh := make(chan bool) - uni := NewFunctionsListenerUniverse(t, 0, 1) + uni := NewFunctionsListenerUniverse(t, 0, 1, false) uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) uni.pluginORM.On("PruneOldestRequests", functions_service.DefaultPruneMaxStoredRequests, functions_service.DefaultPruneBatchSize, mock.Anything).Return(uint32(0), uint32(0), nil).Run(func(args mock.Arguments) { doneCh <- true @@ -446,3 +451,63 @@ func TestFunctionsListener_PruneRequests(t *testing.T) { <-doneCh uni.service.Close() } + +func TestFunctionsListener_HandleOracleRequestV1_Success(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) + + flags := [32]byte{} + flags[1] = 1 // tier no 1 of request size + request := functions_coordinator.FunctionsCoordinatorOracleRequest{ + RequestId: RequestID, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Flags: flags, + Data: make([]byte, 12), // tier 1 should allow for up to 100 bytes + } + + uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) + uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) + log := log_mocks.NewBroadcast(t) + uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) + log.On("String").Return("") + uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) + uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Return(nil) + err := uni.service.Start(testutils.Context(t)) + require.NoError(t, err) + + uni.service.HandleOracleRequestV1(&request, &request.RequestingContract, log) + uni.service.Close() +} + +func TestFunctionsListener_HandleOracleRequestV1_CBORTooBig(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) + + flags := [32]byte{} + flags[1] = 1 // tier no 1 of request size + request := functions_coordinator.FunctionsCoordinatorOracleRequest{ + RequestId: RequestID, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Flags: flags, + Data: make([]byte, 120), // tier 1 only allows for up to 100 bytes + } + + uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) + uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) + log := log_mocks.NewBroadcast(t) + uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) + log.On("String").Return("") + uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, []byte("request too big (max 100 bytes)"), mock.Anything, mock.Anything, mock.Anything).Return(nil) + err := uni.service.Start(testutils.Context(t)) + require.NoError(t, err) + + uni.service.HandleOracleRequestV1(&request, &request.RequestingContract, log) + uni.service.Close() +} diff --git a/core/services/functions/mocks/external_adapter_client.go b/core/services/functions/mocks/external_adapter_client.go index 91d0a1a24e1..2815819251b 100644 --- a/core/services/functions/mocks/external_adapter_client.go +++ b/core/services/functions/mocks/external_adapter_client.go @@ -49,43 +49,43 @@ func (_m *ExternalAdapterClient) FetchEncryptedSecrets(ctx context.Context, encr return r0, r1, r2 } -// RunComputation provides a mock function with given fields: ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData -func (_m *ExternalAdapterClient) RunComputation(ctx context.Context, requestId string, jobName string, subscriptionOwner string, subscriptionId uint64, nodeProvidedSecrets string, requestData *functions.RequestData) ([]byte, []byte, []string, error) { - ret := _m.Called(ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData) +// RunComputation provides a mock function with given fields: ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData +func (_m *ExternalAdapterClient) RunComputation(ctx context.Context, requestId string, jobName string, subscriptionOwner string, subscriptionId uint64, flags functions.RequestFlags, nodeProvidedSecrets string, requestData *functions.RequestData) ([]byte, []byte, []string, error) { + ret := _m.Called(ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData) var r0 []byte var r1 []byte var r2 []string var r3 error - if rf, ok := ret.Get(0).(func(context.Context, string, string, string, uint64, string, *functions.RequestData) ([]byte, []byte, []string, error)); ok { - return rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData) + if rf, ok := ret.Get(0).(func(context.Context, string, string, string, uint64, functions.RequestFlags, string, *functions.RequestData) ([]byte, []byte, []string, error)); ok { + return rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData) } - if rf, ok := ret.Get(0).(func(context.Context, string, string, string, uint64, string, *functions.RequestData) []byte); ok { - r0 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData) + if rf, ok := ret.Get(0).(func(context.Context, string, string, string, uint64, functions.RequestFlags, string, *functions.RequestData) []byte); ok { + r0 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData) } else { if ret.Get(0) != nil { r0 = ret.Get(0).([]byte) } } - if rf, ok := ret.Get(1).(func(context.Context, string, string, string, uint64, string, *functions.RequestData) []byte); ok { - r1 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData) + if rf, ok := ret.Get(1).(func(context.Context, string, string, string, uint64, functions.RequestFlags, string, *functions.RequestData) []byte); ok { + r1 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData) } else { if ret.Get(1) != nil { r1 = ret.Get(1).([]byte) } } - if rf, ok := ret.Get(2).(func(context.Context, string, string, string, uint64, string, *functions.RequestData) []string); ok { - r2 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData) + if rf, ok := ret.Get(2).(func(context.Context, string, string, string, uint64, functions.RequestFlags, string, *functions.RequestData) []string); ok { + r2 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData) } else { if ret.Get(2) != nil { r2 = ret.Get(2).([]string) } } - if rf, ok := ret.Get(3).(func(context.Context, string, string, string, uint64, string, *functions.RequestData) error); ok { - r3 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, nodeProvidedSecrets, requestData) + if rf, ok := ret.Get(3).(func(context.Context, string, string, string, uint64, functions.RequestFlags, string, *functions.RequestData) error); ok { + r3 = rf(ctx, requestId, jobName, subscriptionOwner, subscriptionId, flags, nodeProvidedSecrets, requestData) } else { r3 = ret.Error(3) } diff --git a/core/services/functions/request.go b/core/services/functions/request.go index 1dbc226b05e..53ed91a3991 100644 --- a/core/services/functions/request.go +++ b/core/services/functions/request.go @@ -7,6 +7,8 @@ const ( LanguageJavaScript = 0 ) +type RequestFlags [32]byte + type RequestData struct { Source string `json:"source" cbor:"source"` Language int `json:"language" cbor:"language"` diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index 160c99e3514..16eaf4e6312 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -28,6 +28,8 @@ type PluginConfig struct { PruneBatchSize uint32 `json:"pruneBatchSize"` ListenerEventHandlerTimeoutSec uint32 `json:"listenerEventHandlerTimeoutSec"` MaxRequestSizeBytes uint32 `json:"maxRequestSizeBytes"` + MaxRequestSizesList []uint32 `json:"maxRequestSizesList"` + MaxSecretsSizesList []uint32 `json:"maxSecretsSizesList"` GatewayConnectorConfig *connector.ConnectorConfig `json:"gatewayConnectorConfig"` OnchainAllowlist *functions.OnchainAllowlistConfig `json:"onchainAllowlist"` RateLimiter *common.RateLimiterConfig `json:"rateLimiter"` From c8b7bc897940e69f10fbe5e1531fb8be5fa8c5a3 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Thu, 27 Jul 2023 11:41:33 -0400 Subject: [PATCH 015/270] add setConfigTypeSafe (#9950) --- .../dev/automation/2_1/KeeperRegistry2_1.sol | 4 +- .../2_1/interfaces/IKeeperRegistryMaster.sol | 8 +-- .../automation/AutomationGasAnalysis.test.ts | 4 +- .../automation/AutomationRegistrar2_1.test.ts | 4 +- .../v0.8/automation/KeeperRegistry2_1.test.ts | 62 +++++++++---------- .../automation/UpkeepTranscoder4_0.test.ts | 4 +- contracts/test/v0.8/automation/helpers.ts | 6 -- .../i_keeper_registry_master_wrapper_2_1.go | 30 ++++----- .../keeper_registry_wrapper_2_1.go | 32 +++++----- ...rapper-dependency-versions-do-not-edit.txt | 4 +- .../chaincli/handler/keeper_deployer.go | 2 +- 11 files changed, 75 insertions(+), 85 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol index 24cbc4150e4..1f18dc3914d 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol @@ -232,7 +232,7 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, ER uint64 offchainConfigVersion, bytes memory offchainConfig ) external override { - setConfig( + setConfigTypeSafe( signers, transmitters, f, @@ -242,7 +242,7 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, ER ); } - function setConfig( + function setConfigTypeSafe( address[] memory signers, address[] memory transmitters, uint8 f, diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol index 4bb311c17f0..9d545b116b8 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol @@ -122,16 +122,16 @@ interface IKeeperRegistryMaster { address[] memory signers, address[] memory transmitters, uint8 f, - KeeperRegistryBase2_1.OnchainConfig memory onchainConfig, + bytes memory onchainConfigBytes, uint64 offchainConfigVersion, bytes memory offchainConfig ) external; - function setConfig( + function setConfigTypeSafe( address[] memory signers, address[] memory transmitters, uint8 f, - bytes memory onchainConfigBytes, + KeeperRegistryBase2_1.OnchainConfig memory onchainConfig, uint64 offchainConfigVersion, bytes memory offchainConfig ) external; @@ -370,5 +370,5 @@ interface KeeperRegistryBase2_1 { // THIS FILE WAS AUTOGENERATED FROM THE FOLLOWING ABI JSON: /* -[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfigTypeSafe","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] */ diff --git a/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts b/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts index ae49d30348c..c2e08f4cd81 100644 --- a/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts +++ b/contracts/test/v0.8/automation/AutomationGasAnalysis.test.ts @@ -3,7 +3,7 @@ import { BigNumber } from 'ethers' import { expect, assert } from 'chai' import { getUsers } from '../../test-helpers/setup' import { randomAddress, toWei } from '../../test-helpers/helpers' -import { deployRegistry21, setConfigExplicit } from './helpers' +import { deployRegistry21 } from './helpers' // don't run these tests in CI const describeMaybe = process.env.CI ? describe.skip : describe @@ -203,7 +203,7 @@ describeMaybe('Automation Gas Analysis', () => { } await registry21 .connect(owner) - [setConfigExplicit](signers, transmitters, f, onchainConfig21, 1, '0x') + .setConfigTypeSafe(signers, transmitters, f, onchainConfig21, 1, '0x') // approve LINK await linkToken.connect(owner).approve(registrar20.address, amount) diff --git a/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts b/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts index bb427122dd2..cb74ee61b52 100644 --- a/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts +++ b/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts @@ -12,7 +12,7 @@ import { UpkeepMock } from '../../../typechain/UpkeepMock' import { toWei } from '../../test-helpers/helpers' import { IKeeperRegistryMaster as IKeeperRegistry } from '../../../typechain/IKeeperRegistryMaster' import { AutomationRegistrar2_1 as Registrar } from '../../../typechain/AutomationRegistrar2_1' -import { deployRegistry21, setConfigExplicit } from './helpers' +import { deployRegistry21 } from './helpers' // copied from KeeperRegistryBase2_1.sol enum Trigger { @@ -163,7 +163,7 @@ describe('AutomationRegistrar2_1', () => { } await registry .connect(owner) - [setConfigExplicit](keepers, keepers, 1, onchainConfig, 1, '0x') + .setConfigTypeSafe(keepers, keepers, 1, onchainConfig, 1, '0x') }) describe('#typeAndVersion', () => { diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index 044a6fad25d..f200c042817 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -44,7 +44,7 @@ import { deployMockContract, MockContract, } from '@ethereum-waffle/mock-contract' -import { deployRegistry21, setConfigRaw, setConfigExplicit } from './helpers' +import { deployRegistry21 } from './helpers' const describeMaybe = process.env.SKIP_SLOW ? describe.skip : describe const itMaybe = process.env.SKIP_SLOW ? it.skip : it @@ -418,9 +418,7 @@ describe('KeeperRegistry2_1', () => { let signers: Wallet[] let signerAddresses: string[] let config: any - let baseConfig: Parameters< - IKeeperRegistry['setConfig(address[],address[],uint8,bytes,uint64,bytes)'] - > + let baseConfig: Parameters let upkeepManager: string before(async () => { @@ -607,7 +605,7 @@ describe('KeeperRegistry2_1', () => { .add(registryPerPerformByteGasOverhead.mul(maxPerformDataSize)) for (const test of tests) { - await registry.connect(owner)[setConfigRaw]( + await registry.connect(owner).setConfig( signerAddresses, keeperAddresses, f, @@ -933,7 +931,7 @@ describe('KeeperRegistry2_1', () => { cancellationDelay = (await registry.getCancellationDelay()).toNumber() for (const reg of [registry, arbRegistry, opRegistry, mgRegistry]) { - await reg.connect(owner)[setConfigRaw](...baseConfig) + await reg.connect(owner).setConfig(...baseConfig) await reg.connect(owner).setPayees(payees) await linkToken.connect(admin).approve(reg.address, toWei('1000')) await linkToken.connect(owner).approve(reg.address, toWei('1000')) @@ -1706,7 +1704,7 @@ describe('KeeperRegistry2_1', () => { itMaybe( 'has a large enough gas overhead to cover upkeep that use all its gas [ @skip-coverage ]', async () => { - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses, keeperAddresses, 10, // maximise f to maximise overhead @@ -1751,7 +1749,7 @@ describe('KeeperRegistry2_1', () => { const newF = fArray[i] await registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, newF, @@ -1898,7 +1896,7 @@ describe('KeeperRegistry2_1', () => { await mock.setPerformGasToBurn(performGas) await registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, newF, @@ -2006,7 +2004,7 @@ describe('KeeperRegistry2_1', () => { const performData = '0x' await mock.setCanPerform(true) await mock.setPerformGasToBurn(performGas) - await registry[setConfigExplicit]( + await registry.setConfigTypeSafe( signerAddresses, keeperAddresses, newF, @@ -3526,7 +3524,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(payee1) - [setConfigExplicit]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -3549,7 +3547,7 @@ describe('KeeperRegistry2_1', () => { await registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -3612,7 +3610,7 @@ describe('KeeperRegistry2_1', () => { await registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -3628,7 +3626,7 @@ describe('KeeperRegistry2_1', () => { it('emits an event', async () => { const tx = await registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -3656,7 +3654,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(payee1) - [setConfigExplicit]( + .setConfigTypeSafe( newKeepers, newKeepers, f, @@ -3675,7 +3673,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( newKeepers, newKeepers, f, @@ -3691,7 +3689,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( newKeepers, newKeepers, 0, @@ -3708,7 +3706,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signers, newKeepers, f, @@ -3725,7 +3723,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( newKeepers, newKeepers, f, @@ -3747,7 +3745,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( newSigners, newKeepers, f, @@ -3769,7 +3767,7 @@ describe('KeeperRegistry2_1', () => { await evmRevert( registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( newKeepers, newTransmitters, f, @@ -3797,7 +3795,7 @@ describe('KeeperRegistry2_1', () => { const newSigners = newKeepers tx = await registry .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( newSigners, newKeepers, f, @@ -4481,7 +4479,7 @@ describe('KeeperRegistry2_1', () => { await registry.connect(admin).addFunds(upkeepId, toWei('100')) // Very high min spend, whole balance as cancellation fees const minUpkeepSpend = toWei('1000') - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -4885,7 +4883,7 @@ describe('KeeperRegistry2_1', () => { }) it('reverts if the payee is the zero address', async () => { - await blankRegistry.connect(owner)[setConfigRaw](...baseConfig) // used to test initial config + await blankRegistry.connect(owner).setConfig(...baseConfig) // used to test initial config await evmRevert( blankRegistry // used to test initial config @@ -4899,7 +4897,7 @@ describe('KeeperRegistry2_1', () => { 'sets the payees when exisitng payees are zero address', async () => { //Initial payees should be zero address - await blankRegistry.connect(owner)[setConfigRaw](...baseConfig) // used to test initial config + await blankRegistry.connect(owner).setConfig(...baseConfig) // used to test initial config for (let i = 0; i < keeperAddresses.length; i++) { const payee = ( @@ -4931,7 +4929,7 @@ describe('KeeperRegistry2_1', () => { // configure registry with 5 keepers // optimism registry await blankRegistry // used to test initial configurations .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( signers, keepers, f, @@ -4946,7 +4944,7 @@ describe('KeeperRegistry2_1', () => { // add another keeper // optimism registry await blankRegistry // used to test initial configurations .connect(owner) - [setConfigExplicit]( + .setConfigTypeSafe( [...signers, randomAddress()], [...keepers, newTransmitter], f, @@ -5125,7 +5123,7 @@ describe('KeeperRegistry2_1', () => { it('deducts a cancellation fee from the upkeep and gives to owner', async () => { const minUpkeepSpend = toWei('10') - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -5178,7 +5176,7 @@ describe('KeeperRegistry2_1', () => { it('deducts up to balance as cancellation fee', async () => { // Very high min spend, should deduct whole balance as cancellation fees const minUpkeepSpend = toWei('1000') - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -5226,7 +5224,7 @@ describe('KeeperRegistry2_1', () => { it('does not deduct cancellation fee if more than minUpkeepSpend is spent', async () => { // Very low min spend, already spent in one perform upkeep const minUpkeepSpend = BigNumber.from(420) - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses, keeperAddresses, f, @@ -5625,7 +5623,7 @@ describe('KeeperRegistry2_1', () => { maxAllowedSpareChange = maxAllowedSpareChange.add(BigNumber.from('31')) await verifyConsistentAccounting(maxAllowedSpareChange) - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses.slice(2, 15), // only use 2-14th index keepers keeperAddresses.slice(2, 15), f, @@ -5657,7 +5655,7 @@ describe('KeeperRegistry2_1', () => { ) await verifyConsistentAccounting(maxAllowedSpareChange) - await registry.connect(owner)[setConfigExplicit]( + await registry.connect(owner).setConfigTypeSafe( signerAddresses.slice(0, 4), // only use 0-3rd index keepers keeperAddresses.slice(0, 4), f, diff --git a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts index 5eac53f05c9..e2903ee447a 100644 --- a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts +++ b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts @@ -283,9 +283,7 @@ async function deployRegistry2_1() { await registry .connect(owner) - [ - 'setConfig(address[],address[],uint8,(uint32,uint32,uint32,uint24,uint16,uint96,uint32,uint32,uint32,uint32,uint256,uint256,address,address[],address),uint64,bytes)' - ]( + .setConfigTypeSafe( signerAddresses, keeperAddresses, f, diff --git a/contracts/test/v0.8/automation/helpers.ts b/contracts/test/v0.8/automation/helpers.ts index 888987c0bc7..e2aa762577a 100644 --- a/contracts/test/v0.8/automation/helpers.ts +++ b/contracts/test/v0.8/automation/helpers.ts @@ -4,12 +4,6 @@ import { KeeperRegistryLogicB2_1__factory as KeeperRegistryLogicBFactory } from import { IKeeperRegistryMaster as IKeeperRegistry } from '../../../typechain/IKeeperRegistryMaster' import { IKeeperRegistryMaster__factory as IKeeperRegistryMasterFactory } from '../../../typechain/factories/IKeeperRegistryMaster__factory' -export const setConfigRaw = - 'setConfig(address[],address[],uint8,bytes,uint64,bytes)' - -export const setConfigExplicit = - 'setConfig(address[],address[],uint8,(uint32,uint32,uint32,uint24,uint16,uint96,uint32,uint32,uint32,uint32,uint256,uint256,address,address[],address),uint64,bytes)' - export const deployRegistry21 = async ( from: Signer, mode: Parameters[0], diff --git a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go index 99936b95fe2..b4d37a53708 100644 --- a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go +++ b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var IKeeperRegistryMasterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var IKeeperRegistryMasterABI = IKeeperRegistryMasterMetaData.ABI @@ -1164,28 +1164,28 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) SetAdminPr return _IKeeperRegistryMaster.Contract.SetAdminPrivilegeConfig(&_IKeeperRegistryMaster.TransactOpts, admin, newPrivilegeConfig) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.contract.Transact(opts, "setConfig", signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.contract.Transact(opts, "setConfig", signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.Contract.SetConfig(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.Contract.SetConfig(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.Contract.SetConfig(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.Contract.SetConfig(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) SetConfig0(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.contract.Transact(opts, "setConfig0", signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) SetConfigTypeSafe(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.contract.Transact(opts, "setConfigTypeSafe", signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) SetConfig0(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.Contract.SetConfig0(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) SetConfigTypeSafe(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.Contract.SetConfigTypeSafe(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } -func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) SetConfig0(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _IKeeperRegistryMaster.Contract.SetConfig0(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) +func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactorSession) SetConfigTypeSafe(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _IKeeperRegistryMaster.Contract.SetConfigTypeSafe(&_IKeeperRegistryMaster.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } func (_IKeeperRegistryMaster *IKeeperRegistryMasterTransactor) SetPayees(opts *bind.TransactOpts, payees []common.Address) (*types.Transaction, error) { @@ -5921,9 +5921,9 @@ type IKeeperRegistryMasterInterface interface { SetAdminPrivilegeConfig(opts *bind.TransactOpts, admin common.Address, newPrivilegeConfig []byte) (*types.Transaction, error) - SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) + SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) - SetConfig0(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) + SetConfigTypeSafe(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) SetPayees(opts *bind.TransactOpts, payees []common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go index 8471089a0c2..6d6bdbede9e 100644 --- a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go @@ -49,8 +49,8 @@ type KeeperRegistryBase21OnchainConfig struct { } var KeeperRegistryMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101406040523480156200001257600080fd5b506040516200547a3803806200547a8339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614fd9620004a16000396000818160d6015261016f0152600050506000818161245c01528181613353015281816134e60152613a1601526000505060005050600061043b0152614fd96000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063a931358d11610081578063b1dc65a41161005b578063b1dc65a4146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063a931358d14610262578063aed2e92914610275578063afcb95d71461029f576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613c95565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d1e565b610423565b61011961027036600461413e565b61063f565b61028861028336600461420b565b611456565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102f636600461429c565b6115be565b610119610309366004614353565b61218c565b61011961031c3660046143e2565b6121b5565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da828401846143ff565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff16614447565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da90859061446c565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b6106476121c9565b601f86511115610683576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036106c0576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b845186511415806106df57506106d784600361447f565b60ff16865111155b15610716576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156107ab57610798600e828154811061076f5761076f6144a8565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16848461224c565b50806107a3816144d7565b915050610743565b5060008060005b836bffffffffffffffffffffffff168110156108b457600d81815481106107db576107db6144a8565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff90921694509082908110610816576108166144a8565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806108ac816144d7565b9150506107b2565b506108c1600d6000613b6a565b6108cd600e6000613b6a565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c51811015610c5157600c60008e8381518110610912576109126144a8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff161561097d576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106109ae576109ae6144a8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110610a5657610a566144a8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250610b1b576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009095169490941717919091169290921791909117905580610c49816144d7565b9150506108f3565b50508a51610c679150600d9060208d0190613b88565b508851610c7b90600e9060208c0190613b88565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff16905061123d612456565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff93841602178082556001926018916112b8918591780100000000000000000000000000000000000000000000000090041661450f565b92506101000a81548163ffffffff021916908363ffffffff1602179055506000886040516020016112e9919061457d565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061135290469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f61250b565b60115560005b61136260096125b5565b8110156113925761137f6113776009836125c5565b6009906125d1565b508061138a816144d7565b915050611358565b5060005b896101a00151518110156113e9576113d68a6101a0015182815181106113be576113be6144a8565b602002602001015160096125f390919063ffffffff16565b50806113e1816144d7565b915050611396565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f604051611440999897969594939291906146e1565b60405180910390a1505050505050505050505050565b600080611461612615565b6012546e010000000000000000000000000000900460ff16156114b0576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f890185900485028101850190955287855290936115af93899089908190840183828082843760009201919091525061264d92505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506116ec576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff16611735576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a3514611771576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805161177e906001614777565b60ff168614158061178f5750858414155b156117c6576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117d68a8a8a8a8a8a8a8a612858565b60006117e28a8a612ac1565b9050600081604001515167ffffffffffffffff81111561180457611804613d7a565b6040519080825280602002602001820160405280156118d057816020015b6040805161020081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9092019101816118225790505b5090506000805b836040015151811015611d805760046000856040015183815181106118fe576118fe6144a8565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c082015283518490839081106119e3576119e36144a8565b602002602001015160000181905250611a1884604001518281518110611a0b57611a0b6144a8565b6020026020010151612b7a565b838281518110611a2a57611a2a6144a8565b6020026020010151608001906001811115611a4757611a47614790565b90816001811115611a5a57611a5a614790565b81525050611ace85848381518110611a7457611a746144a8565b60200260200101516080015186606001518481518110611a9657611a966144a8565b60200260200101518760a001518581518110611ab457611ab46144a8565b602002602001015151886000015189602001516001612c25565b838281518110611ae057611ae06144a8565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050611b5284604001518281518110611b2757611b276144a8565b602002602001015185608001518381518110611b4557611b456144a8565b6020026020010151612c70565b838281518110611b6457611b646144a8565b602002602001015160e0018181525050611bd284604001518281518110611b8d57611b8d6144a8565b602002602001015185608001518381518110611bab57611bab6144a8565b6020026020010151858481518110611bc557611bc56144a8565b6020026020010151612ca3565b848381518110611be457611be46144a8565b6020026020010151602001858481518110611c0157611c016144a8565b6020026020010151610100018281525082151515158152505050828181518110611c2d57611c2d6144a8565b60200260200101516020015115611c5057611c496001836147bf565b9150611c55565b611d6e565b611cbb838281518110611c6a57611c6a6144a8565b6020026020010151600001516060015185606001518381518110611c9057611c906144a8565b60200260200101518660a001518481518110611cae57611cae6144a8565b602002602001015161264d565b848381518110611ccd57611ccd6144a8565b6020026020010151606001858481518110611cea57611cea6144a8565b602002602001015160a0018281525082151515158152505050828181518110611d1557611d156144a8565b602002602001015160a0015186611d2c91906147da565b9550611d6e84604001518281518110611d4757611d476144a8565b6020026020010151848381518110611d6157611d616144a8565b6020026020010151612e2e565b80611d78816144d7565b9150506118d7565b508061ffff16600003611d97575050505050612182565b8351611da4906001614777565b611db39060ff1661044c6147ed565b616b6c611dc18d60106147ed565b5a611dcc90896147da565b611dd6919061446c565b611de0919061446c565b611dea919061446c565b9450611b58611dfd61ffff831687614859565b611e07919061446c565b945060008060008060005b87604001515181101561202457868181518110611e3157611e316144a8565b6020026020010151602001511561201257611e8d8a888381518110611e5857611e586144a8565b6020026020010151608001518a60a001518481518110611e7a57611e7a6144a8565b6020026020010151518c60000151612f17565b878281518110611e9f57611e9f6144a8565b602002602001015160c0018181525050611efb8989604001518381518110611ec957611ec96144a8565b6020026020010151898481518110611ee357611ee36144a8565b60200260200101518b600001518c602001518b612f37565b9093509150611f0a8285614447565b9350611f168386614447565b9450868181518110611f2a57611f2a6144a8565b602002602001015160600151151588604001518281518110611f4e57611f4e6144a8565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c68486611f839190614447565b8a8581518110611f9557611f956144a8565b602002602001015160a001518b8681518110611fb357611fb36144a8565b602002602001015160c001518c8781518110611fd157611fd16144a8565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b8061201c816144d7565b915050611e12565b5050336000908152600b60205260409020805484925060029061205c9084906201000090046bffffffffffffffffffffffff16614447565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff166120b69190614447565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f6001600381106120f9576120f96144a8565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff16111561217857601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6121ad868686868060200190518101906121a69190614908565b868661063f565b505050505050565b6121bd6121c9565b6121c68161302a565b50565b60005473ffffffffffffffffffffffffffffffffffffffff16331461224a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906124485760008160600151856122e49190614a62565b905060006122f28583614a87565b905080836040018181516123069190614447565b6bffffffffffffffffffffffff169052506123218582614ab2565b836060018181516123329190614447565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f0000000000000000000000000000000000000000000000000000000000000000600281111561248c5761248c614790565b0361250657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156124dd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125019190614ae6565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a60405160200161252f99989796959493929190614aff565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006125bf825490565b92915050565b600061244f838361311f565b600061244f8373ffffffffffffffffffffffffffffffffffffffff8416613149565b600061244f8373ffffffffffffffffffffffffffffffffffffffff8416613243565b321561224a576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60125460009081906f01000000000000000000000000000000900460ff16156126a2576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b000000000000000000000000000000000000000000000000000000009061270f908590602401613c95565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906127e29087908790600401614b94565b60408051808303816000875af1158015612800573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128249190614bad565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b6000878760405161286a929190614be0565b604051908190038120612881918b90602001614bf0565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b88811015612a58576001858783602081106128ed576128ed6144a8565b6128fa91901a601b614777565b8c8c8581811061290c5761290c6144a8565b905060200201358b8b86818110612925576129256144a8565b9050602002013560405160008152602001604052604051612962949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015612984573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff8082161515808552610100909204169383019390935290955093509050612a32576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b840193508080612a50906144d7565b9150506128d0565b50827e01010101010101010101010101010101010101010101010101010101010101841614612ab3576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b612afa6040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6000612b0883850185614ce1565b6040810151516060820151519192509081141580612b2b57508082608001515114155b80612b3b5750808260a001515114155b15612b72576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b509392505050565b6000818160045b600f811015612c07577fff000000000000000000000000000000000000000000000000000000000000008216838260208110612bbf57612bbf6144a8565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff191614612bf557506000949350505050565b80612bff816144d7565b915050612b81565b5081600f1a6001811115612c1d57612c1d614790565b949350505050565b600080612c3788878b60000151613292565b9050600080612c528b8a63ffffffff16858a8a60018b61331e565b9092509050612c618183614447565b9b9a5050505050505050505050565b60008282604051602001612c85929190614dce565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612cbe57612cbe614790565b03612ce257612cce868686613777565b612cdd576000925090506115b6565b612d59565b600184608001516001811115612cfa57612cfa614790565b03612d27576000612d0c878787613877565b9250905080612d2157506000925090506115b6565b50612d59565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d61612456565b84516040015163ffffffff1611612dbb57857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e00151604051612da891815260200190565b60405180910390a26000925090506115b6565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff161015612e2157857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e00151604051612da891815260200190565b6001969095509350505050565b600081608001516001811115612e4657612e46614790565b03612eb857612e53612456565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612ed057612ed0614790565b03612f1357610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612f24848484613292565b905080851015612c1d5750929392505050565b600080612f52888760a001518860c00151888888600161331e565b90925090506000612f638284614447565b600089815260046020526040902060010180549192508291600c90612fa79084906c0100000000000000000000000090046bffffffffffffffffffffffff16614a62565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612ff091859116614447565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036130a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000826000018281548110613136576131366144a8565b9060005260206000200154905092915050565b6000818152600183016020526040812054801561323257600061316d6001836147da565b8554909150600090613181906001906147da565b90508181146131e65760008660000182815481106131a1576131a16144a8565b90600052602060002001549050808760000184815481106131c4576131c46144a8565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806131f7576131f7614df4565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506125bf565b60009150506125bf565b5092915050565b600081815260018301602052604081205461328a575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556125bf565b5060006125bf565b600080808560018111156132a8576132a8614790565b036132b7575062015f906132d6565b60018560018111156132cb576132cb614790565b03612d2757506201adb05b6132e763ffffffff851660146147ed565b6132f2846001614777565b6133019060ff16611d4c6147ed565b61330b908361446c565b613315919061446c565b95945050505050565b6000806000896080015161ffff168761333791906147ed565b90508380156133455750803a105b1561334d57503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561338357613383614790565b036134e25760408051600081526020810190915285156133e157600036604051806080016040528060488152602001614f85604891396040516020016133cb93929190614e23565b6040516020818303038152906040529050613449565b6015546133fd90640100000000900463ffffffff166004614e4a565b63ffffffff1667ffffffffffffffff81111561341b5761341b613d7a565b6040519080825280601f01601f191660200182016040528015613445576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613499908490600401613c95565b602060405180830381865afa1580156134b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134da9190614ae6565b91505061363c565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561351657613516614790565b0361363c57841561359857606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561356d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135919190614ae6565b905061363c565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156135e6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061360a9190614e6d565b505060155492945061362d93505050640100000000900463ffffffff16826147ed565b6136389060106147ed565b9150505b8461365857808b6080015161ffff1661365591906147ed565b90505b61366661ffff871682614859565b9050600087826136768c8e61446c565b61368090866147ed565b61368a919061446c565b61369c90670de0b6b3a76400006147ed565b6136a69190614859565b905060008c6040015163ffffffff1664e8d4a510006136c591906147ed565b898e6020015163ffffffff16858f886136de91906147ed565b6136e8919061446c565b6136f690633b9aca006147ed565b61370091906147ed565b61370a9190614859565b613714919061446c565b90506b033b2e3c9fd0803ce800000061372d828461446c565b1115613765576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000808380602001905181019061378e9190614eb7565b835160c00151815191925063ffffffff908116911610156137f157847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e001516040516137df91815260200190565b60405180910390a2600091505061244f565b6020810151158015906138185750602081015181516138159063ffffffff16613a10565b14155b806138315750613826612456565b815163ffffffff1610155b1561386c57847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e001516040516137df91815260200190565b506001949350505050565b6000806000848060200190518101906138909190614f0f565b9050600086826000015183602001516040516020016138e793929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061394957508160600151613946836040015163ffffffff16613a10565b14155b806139655750613957612456565b826040015163ffffffff1610155b156139b557867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e001516040516139a091815260200190565b60405180910390a26000935091506115b69050565b60008181526008602052604090205460ff1615613a0257867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e001516040516139a091815260200190565b600197909650945050505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a4657613a46614790565b03613b60576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a99573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613abd9190614ae6565b90508083101580613ad85750610100613ad684836147da565b115b15613ae65750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b3c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061244f9190614ae6565b504090565b919050565b50805460008255906000526020600020908101906121c69190613c12565b828054828255906000526020600020908101928215613c02579160200282015b82811115613c0257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613ba8565b50613c0e929150613c12565b5090565b5b80821115613c0e5760008155600101613c13565b60005b83811015613c42578181015183820152602001613c2a565b50506000910152565b60008151808452613c63816020860160208601613c27565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061244f6020830184613c4b565b73ffffffffffffffffffffffffffffffffffffffff811681146121c657600080fd5b8035613b6581613ca8565b60008083601f840112613ce757600080fd5b50813567ffffffffffffffff811115613cff57600080fd5b602083019150836020828501011115613d1757600080fd5b9250929050565b60008060008060608587031215613d3457600080fd5b8435613d3f81613ca8565b935060208501359250604085013567ffffffffffffffff811115613d6257600080fd5b613d6e87828801613cd5565b95989497509550505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613dcd57613dcd613d7a565b60405290565b60405160c0810167ffffffffffffffff81118282101715613dcd57613dcd613d7a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e3d57613e3d613d7a565b604052919050565b600067ffffffffffffffff821115613e5f57613e5f613d7a565b5060051b60200190565b600082601f830112613e7a57600080fd5b81356020613e8f613e8a83613e45565b613df6565b82815260059290921b84018101918181019086841115613eae57600080fd5b8286015b84811015613ed2578035613ec581613ca8565b8352918301918301613eb2565b509695505050505050565b803560ff81168114613b6557600080fd5b63ffffffff811681146121c657600080fd5b8035613b6581613eee565b62ffffff811681146121c657600080fd5b8035613b6581613f0b565b61ffff811681146121c657600080fd5b8035613b6581613f27565b6bffffffffffffffffffffffff811681146121c657600080fd5b8035613b6581613f42565b60006101e08284031215613f7a57600080fd5b613f82613da9565b9050613f8d82613f00565b8152613f9b60208301613f00565b6020820152613fac60408301613f00565b6040820152613fbd60608301613f1c565b6060820152613fce60808301613f37565b6080820152613fdf60a08301613f5c565b60a0820152613ff060c08301613f00565b60c082015261400160e08301613f00565b60e0820152610100614014818401613f00565b90820152610120614026838201613f00565b908201526101408281013590820152610160808301359082015261018061404e818401613cca565b908201526101a08281013567ffffffffffffffff81111561406e57600080fd5b61407a85828601613e69565b8284015250506101c061408e818401613cca565b9082015292915050565b803567ffffffffffffffff81168114613b6557600080fd5b600082601f8301126140c157600080fd5b813567ffffffffffffffff8111156140db576140db613d7a565b61410c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613df6565b81815284602083860101111561412157600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561415757600080fd5b863567ffffffffffffffff8082111561416f57600080fd5b61417b8a838b01613e69565b9750602089013591508082111561419157600080fd5b61419d8a838b01613e69565b96506141ab60408a01613edd565b955060608901359150808211156141c157600080fd5b6141cd8a838b01613f67565b94506141db60808a01614098565b935060a08901359150808211156141f157600080fd5b506141fe89828a016140b0565b9150509295509295509295565b60008060006040848603121561422057600080fd5b83359250602084013567ffffffffffffffff81111561423e57600080fd5b61424a86828701613cd5565b9497909650939450505050565b60008083601f84011261426957600080fd5b50813567ffffffffffffffff81111561428157600080fd5b6020830191508360208260051b8501011115613d1757600080fd5b60008060008060008060008060e0898b0312156142b857600080fd5b606089018a8111156142c957600080fd5b8998503567ffffffffffffffff808211156142e357600080fd5b6142ef8c838d01613cd5565b909950975060808b013591508082111561430857600080fd5b6143148c838d01614257565b909750955060a08b013591508082111561432d57600080fd5b5061433a8b828c01614257565b999c989b50969995989497949560c00135949350505050565b60008060008060008060c0878903121561436c57600080fd5b863567ffffffffffffffff8082111561438457600080fd5b6143908a838b01613e69565b975060208901359150808211156143a657600080fd5b6143b28a838b01613e69565b96506143c060408a01613edd565b955060608901359150808211156143d657600080fd5b6141cd8a838b016140b0565b6000602082840312156143f457600080fd5b813561244f81613ca8565b60006020828403121561441157600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff81811683821601908082111561323c5761323c614418565b808201808211156125bf576125bf614418565b600060ff821660ff84168160ff04811182151516156144a0576144a0614418565b029392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361450857614508614418565b5060010190565b63ffffffff81811683821601908082111561323c5761323c614418565b600081518084526020808501945080840160005b8381101561457257815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614540565b509495945050505050565b6020815261459460208201835163ffffffff169052565b600060208301516145ad604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e08301516101006146268185018363ffffffff169052565b840151905061012061463f8482018363ffffffff169052565b84015190506101406146588482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a061469b8185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526146bb61020086018461452c565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526147118184018a61452c565b90508281036080840152614725818961452c565b905060ff871660a084015282810360c08401526147428187613c4b565b905067ffffffffffffffff851660e08401528281036101008401526147678185613c4b565b9c9b505050505050505050505050565b60ff81811683821601908111156125bf576125bf614418565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff81811683821601908082111561323c5761323c614418565b818103818111156125bf576125bf614418565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561482557614825614418565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826148685761486861482a565b500490565b8051613b6581613eee565b8051613b6581613f0b565b8051613b6581613f27565b8051613b6581613f42565b8051613b6581613ca8565b600082601f8301126148b557600080fd5b815160206148c5613e8a83613e45565b82815260059290921b840181019181810190868411156148e457600080fd5b8286015b84811015613ed25780516148fb81613ca8565b83529183019183016148e8565b60006020828403121561491a57600080fd5b815167ffffffffffffffff8082111561493257600080fd5b908301906101e0828603121561494757600080fd5b61494f613da9565b6149588361486d565b81526149666020840161486d565b60208201526149776040840161486d565b604082015261498860608401614878565b606082015261499960808401614883565b60808201526149aa60a0840161488e565b60a08201526149bb60c0840161486d565b60c08201526149cc60e0840161486d565b60e08201526101006149df81850161486d565b908201526101206149f184820161486d565b9082015261014083810151908201526101608084015190820152610180614a19818501614899565b908201526101a08381015183811115614a3157600080fd5b614a3d888287016148a4565b8284015250506101c09150614a53828401614899565b91810191909152949350505050565b6bffffffffffffffffffffffff82811682821603908082111561323c5761323c614418565b60006bffffffffffffffffffffffff80841680614aa657614aa661482a565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614add57614add614418565b02949350505050565b600060208284031215614af857600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614b468285018b61452c565b91508382036080850152614b5a828a61452c565b915060ff881660a085015283820360c0850152614b778288613c4b565b90861660e085015283810361010085015290506147678185613c4b565b828152604060208201526000612c1d6040830184613c4b565b60008060408385031215614bc057600080fd5b82518015158114614bd057600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614c1757600080fd5b81356020614c27613e8a83613e45565b82815260059290921b84018101918181019086841115614c4657600080fd5b8286015b84811015613ed25780358352918301918301614c4a565b600082601f830112614c7257600080fd5b81356020614c82613e8a83613e45565b82815260059290921b84018101918181019086841115614ca157600080fd5b8286015b84811015613ed257803567ffffffffffffffff811115614cc55760008081fd5b614cd38986838b01016140b0565b845250918301918301614ca5565b600060208284031215614cf357600080fd5b813567ffffffffffffffff80821115614d0b57600080fd5b9083019060c08286031215614d1f57600080fd5b614d27613dd3565b8235815260208301356020820152604083013582811115614d4757600080fd5b614d5387828601614c06565b604083015250606083013582811115614d6b57600080fd5b614d7787828601614c06565b606083015250608083013582811115614d8f57600080fd5b614d9b87828601614c61565b60808301525060a083013582811115614db357600080fd5b614dbf87828601614c61565b60a08301525095945050505050565b82815260008251614de6816020850160208701613c27565b919091016020019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b828482376000838201600081528351614e40818360208801613c27565b0195945050505050565b600063ffffffff80831681851681830481118215151615614add57614add614418565b60008060008060008060c08789031215614e8657600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614ec957600080fd5b6040516040810181811067ffffffffffffffff82111715614eec57614eec613d7a565b6040528251614efa81613eee565b81526020928301519281019290925250919050565b600060808284031215614f2157600080fd5b6040516080810181811067ffffffffffffffff82111715614f4457614f44613d7a565b604052825181526020830151614f5981613eee565b60208201526040830151614f6c81613eee565b6040820152606092830151928101929092525091905056fe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x6101406040523480156200001257600080fd5b5060405162005476380380620054768339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614fd5620004a16000396000818160d6015261016f01526000505060008181612e73015281816131dc0152818161336f0152613a1201526000505060005050600061043b0152614fd56000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063aed2e92911610081578063e29b753c1161005b578063e29b753c146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063aed2e92914610262578063afcb95d71461028c578063b1dc65a4146102d5576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613c91565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d1a565b610423565b610275610270366004613d76565b61063f565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102e3366004613e07565b6107a7565b6101196102f6366004614282565b611375565b61011961030936600461434f565b61218c565b61011961031c3660046143de565b6121b5565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da828401846143fb565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff16614443565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da908590614468565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b60008061064a6121c9565b6012546e010000000000000000000000000000900460ff1615610699576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f8901859004850281018501909552878552909361079893899089908190840183828082843760009201919091525061220392505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506108d5576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff1661091e576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a351461095a576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516109679060016144aa565b60ff16861415806109785750858414155b156109af576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109bf8a8a8a8a8a8a8a8a61240e565b60006109cb8a8a612677565b9050600081604001515167ffffffffffffffff8111156109ed576109ed613ebe565b604051908082528060200260200182016040528015610ab957816020015b6040805161020081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181610a0b5790505b5090506000805b836040015151811015610f69576004600085604001518381518110610ae757610ae761447b565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201528351849083908110610bcc57610bcc61447b565b602002602001015160000181905250610c0184604001518281518110610bf457610bf461447b565b6020026020010151612732565b838281518110610c1357610c1361447b565b6020026020010151608001906001811115610c3057610c306144c3565b90816001811115610c4357610c436144c3565b81525050610cb785848381518110610c5d57610c5d61447b565b60200260200101516080015186606001518481518110610c7f57610c7f61447b565b60200260200101518760a001518581518110610c9d57610c9d61447b565b6020026020010151518860000151896020015160016127dd565b838281518110610cc957610cc961447b565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050610d3b84604001518281518110610d1057610d1061447b565b602002602001015185608001518381518110610d2e57610d2e61447b565b6020026020010151612828565b838281518110610d4d57610d4d61447b565b602002602001015160e0018181525050610dbb84604001518281518110610d7657610d7661447b565b602002602001015185608001518381518110610d9457610d9461447b565b6020026020010151858481518110610dae57610dae61447b565b602002602001015161285b565b848381518110610dcd57610dcd61447b565b6020026020010151602001858481518110610dea57610dea61447b565b6020026020010151610100018281525082151515158152505050828181518110610e1657610e1661447b565b60200260200101516020015115610e3957610e326001836144f2565b9150610e3e565b610f57565b610ea4838281518110610e5357610e5361447b565b6020026020010151600001516060015185606001518381518110610e7957610e7961447b565b60200260200101518660a001518481518110610e9757610e9761447b565b6020026020010151612203565b848381518110610eb657610eb661447b565b6020026020010151606001858481518110610ed357610ed361447b565b602002602001015160a0018281525082151515158152505050828181518110610efe57610efe61447b565b602002602001015160a0015186610f15919061450d565b9550610f5784604001518281518110610f3057610f3061447b565b6020026020010151848381518110610f4a57610f4a61447b565b60200260200101516129e6565b80610f6181614520565b915050610ac0565b508061ffff16600003610f8057505050505061136b565b8351610f8d9060016144aa565b610f9c9060ff1661044c614558565b616b6c610faa8d6010614558565b5a610fb5908961450d565b610fbf9190614468565b610fc99190614468565b610fd39190614468565b9450611b58610fe661ffff8316876145c4565b610ff09190614468565b945060008060008060005b87604001515181101561120d5786818151811061101a5761101a61447b565b602002602001015160200151156111fb576110768a8883815181106110415761104161447b565b6020026020010151608001518a60a0015184815181106110635761106361447b565b6020026020010151518c60000151612acf565b8782815181106110885761108861447b565b602002602001015160c00181815250506110e489896040015183815181106110b2576110b261447b565b60200260200101518984815181106110cc576110cc61447b565b60200260200101518b600001518c602001518b612aef565b90935091506110f38285614443565b93506110ff8386614443565b94508681815181106111135761111361447b565b6020026020010151606001511515886040015182815181106111375761113761447b565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c6848661116c9190614443565b8a858151811061117e5761117e61447b565b602002602001015160a001518b868151811061119c5761119c61447b565b602002602001015160c001518c87815181106111ba576111ba61447b565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b8061120581614520565b915050610ffb565b5050336000908152600b6020526040902080548492506002906112459084906201000090046bffffffffffffffffffffffff16614443565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff1661129f9190614443565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f6001600381106112e2576112e261447b565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff16111561136157601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b61137d612be2565b601f865111156113b9576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036113f6576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84518651141580611415575061140d8460036145d8565b60ff16865111155b1561144c576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156114e1576114ce600e82815481106114a5576114a561447b565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612c63565b50806114d981614520565b915050611479565b5060008060005b836bffffffffffffffffffffffff168110156115ea57600d81815481106115115761151161447b565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff9092169450908290811061154c5761154c61447b565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806115e281614520565b9150506114e8565b506115f7600d6000613b66565b611603600e6000613b66565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c5181101561198757600c60008e83815181106116485761164861447b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff16156116b3576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106116e4576116e461447b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c908290811061178c5761178c61447b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250611851576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909516949094171791909116929092179190911790558061197f81614520565b915050611629565b50508a5161199d9150600d9060208d0190613b84565b5088516119b190600e9060208c0190613b84565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff169050611f73612e6d565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff9384160217808255600192601891611fee9185917801000000000000000000000000000000000000000000000000900416614601565b92506101000a81548163ffffffff021916908363ffffffff16021790555060008860405160200161201f919061466f565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061208890469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f612f22565b60115560005b6120986009612fcc565b8110156120c8576120b56120ad600983612fd6565b600990612fe2565b50806120c081614520565b91505061208e565b5060005b896101a001515181101561211f5761210c8a6101a0015182815181106120f4576120f461447b565b6020026020010151600961300490919063ffffffff16565b508061211781614520565b9150506120cc565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f604051612176999897969594939291906147d3565b60405180910390a1505050505050505050505050565b6121ad868686868060200190518101906121a69190614904565b8686611375565b505050505050565b6121bd612be2565b6121c681613026565b50565b3215612201576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60125460009081906f01000000000000000000000000000000900460ff1615612258576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b00000000000000000000000000000000000000000000000000000000906122c5908590602401613c91565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906123989087908790600401614a5e565b60408051808303816000875af11580156123b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123da9190614a77565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b60008787604051612420929190614aaa565b604051908190038120612437918b90602001614aba565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b8881101561260e576001858783602081106124a3576124a361447b565b6124b091901a601b6144aa565b8c8c858181106124c2576124c261447b565b905060200201358b8b868181106124db576124db61447b565b9050602002013560405160008152602001604052604051612518949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561253a573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff80821615158085526101009092041693830193909352909550935090506125e8576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b84019350808061260690614520565b915050612486565b50827e01010101010101010101010101010101010101010101010101010101010101841614612669576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b6126b06040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b60006126be83850185614bab565b60408101515160608201515191925090811415806126e157508082608001515114155b806126f15750808260a001515114155b15612728576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5090505b92915050565b6000818160045b600f8110156127bf577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106127775761277761447b565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146127ad57506000949350505050565b806127b781614520565b915050612739565b5081600f1a60018111156127d5576127d56144c3565b949350505050565b6000806127ef88878b6000015161311b565b905060008061280a8b8a63ffffffff16858a8a60018b6131a7565b90925090506128198183614443565b9b9a5050505050505050505050565b6000828260405160200161283d929190614c98565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612876576128766144c3565b0361289a57612886868686613600565b6128955760009250905061079f565b612911565b6001846080015160018111156128b2576128b26144c3565b036128df5760006128c4878787613700565b92509050806128d9575060009250905061079f565b50612911565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612919612e6d565b84516040015163ffffffff161161297357857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e0015160405161296091815260200190565b60405180910390a260009250905061079f565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff1610156129d957857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e0015160405161296091815260200190565b6001969095509350505050565b6000816080015160018111156129fe576129fe6144c3565b03612a7057612a0b612e6d565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612a8857612a886144c3565b03612acb57610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612adc84848461311b565b9050808510156127d55750929392505050565b600080612b0a888760a001518860c0015188888860016131a7565b90925090506000612b1b8284614443565b600089815260046020526040902060010180549192508291600c90612b5f9084906c0100000000000000000000000090046bffffffffffffffffffffffff16614cbe565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612ba891859116614443565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314612201576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015290612e5f576000816060015185612cfb9190614cbe565b90506000612d098583614ce3565b90508083604001818151612d1d9190614443565b6bffffffffffffffffffffffff16905250612d388582614d0e565b83606001818151612d499190614443565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115612ea357612ea36144c3565b03612f1d57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612ef4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f189190614d42565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a604051602001612f4699989796959493929190614d5b565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b600061272c825490565b6000612e668383613899565b6000612e668373ffffffffffffffffffffffffffffffffffffffff84166138c3565b6000612e668373ffffffffffffffffffffffffffffffffffffffff84166139bd565b3373ffffffffffffffffffffffffffffffffffffffff8216036130a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008080856001811115613131576131316144c3565b03613140575062015f9061315f565b6001856001811115613154576131546144c3565b036128df57506201adb05b61317063ffffffff85166014614558565b61317b8460016144aa565b61318a9060ff16611d4c614558565b6131949083614468565b61319e9190614468565b95945050505050565b6000806000896080015161ffff16876131c09190614558565b90508380156131ce5750803a105b156131d657503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561320c5761320c6144c3565b0361336b57604080516000815260208101909152851561326a57600036604051806080016040528060488152602001614f816048913960405160200161325493929190614df0565b60405160208183030381529060405290506132d2565b60155461328690640100000000900463ffffffff166004614e17565b63ffffffff1667ffffffffffffffff8111156132a4576132a4613ebe565b6040519080825280601f01601f1916602001820160405280156132ce576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613322908490600401613c91565b602060405180830381865afa15801561333f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133639190614d42565b9150506134c5565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561339f5761339f6144c3565b036134c557841561342157606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156133f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061341a9190614d42565b90506134c5565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801561346f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134939190614e3a565b50506015549294506134b693505050640100000000900463ffffffff1682614558565b6134c1906010614558565b9150505b846134e157808b6080015161ffff166134de9190614558565b90505b6134ef61ffff8716826145c4565b9050600087826134ff8c8e614468565b6135099086614558565b6135139190614468565b61352590670de0b6b3a7640000614558565b61352f91906145c4565b905060008c6040015163ffffffff1664e8d4a5100061354e9190614558565b898e6020015163ffffffff16858f886135679190614558565b6135719190614468565b61357f90633b9aca00614558565b6135899190614558565b61359391906145c4565b61359d9190614468565b90506b033b2e3c9fd0803ce80000006135b68284614468565b11156135ee576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906136179190614e84565b835160c00151815191925063ffffffff9081169116101561367a57847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e0015160405161366891815260200190565b60405180910390a26000915050612e66565b6020810151158015906136a157506020810151815161369e9063ffffffff16613a0c565b14155b806136ba57506136af612e6d565b815163ffffffff1610155b156136f557847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e0015160405161366891815260200190565b506001949350505050565b6000806000848060200190518101906137199190614edc565b90506000868260000151836020015160405160200161377093929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101206060830151909150158015906137d2575081606001516137cf836040015163ffffffff16613a0c565b14155b806137ee57506137e0612e6d565b826040015163ffffffff1610155b1561383e57867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e0015160405161382991815260200190565b60405180910390a260009350915061079f9050565b60008181526008602052604090205460ff161561388b57867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e0015160405161382991815260200190565b600197909650945050505050565b60008260000182815481106138b0576138b061447b565b9060005260206000200154905092915050565b600081815260018301602052604081205480156139ac5760006138e760018361450d565b85549091506000906138fb9060019061450d565b905081811461396057600086600001828154811061391b5761391b61447b565b906000526020600020015490508087600001848154811061393e5761393e61447b565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061397157613971614f51565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061272c565b600091505061272c565b5092915050565b6000818152600183016020526040812054613a045750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561272c565b50600061272c565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a4257613a426144c3565b03613b5c576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a95573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ab99190614d42565b90508083101580613ad45750610100613ad2848361450d565b115b15613ae25750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b38573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e669190614d42565b504090565b919050565b50805460008255906000526020600020908101906121c69190613c0e565b828054828255906000526020600020908101928215613bfe579160200282015b82811115613bfe57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613ba4565b50613c0a929150613c0e565b5090565b5b80821115613c0a5760008155600101613c0f565b60005b83811015613c3e578181015183820152602001613c26565b50506000910152565b60008151808452613c5f816020860160208601613c23565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612e666020830184613c47565b73ffffffffffffffffffffffffffffffffffffffff811681146121c657600080fd5b8035613b6181613ca4565b60008083601f840112613ce357600080fd5b50813567ffffffffffffffff811115613cfb57600080fd5b602083019150836020828501011115613d1357600080fd5b9250929050565b60008060008060608587031215613d3057600080fd5b8435613d3b81613ca4565b935060208501359250604085013567ffffffffffffffff811115613d5e57600080fd5b613d6a87828801613cd1565b95989497509550505050565b600080600060408486031215613d8b57600080fd5b83359250602084013567ffffffffffffffff811115613da957600080fd5b613db586828701613cd1565b9497909650939450505050565b60008083601f840112613dd457600080fd5b50813567ffffffffffffffff811115613dec57600080fd5b6020830191508360208260051b8501011115613d1357600080fd5b60008060008060008060008060e0898b031215613e2357600080fd5b606089018a811115613e3457600080fd5b8998503567ffffffffffffffff80821115613e4e57600080fd5b613e5a8c838d01613cd1565b909950975060808b0135915080821115613e7357600080fd5b613e7f8c838d01613dc2565b909750955060a08b0135915080821115613e9857600080fd5b50613ea58b828c01613dc2565b999c989b50969995989497949560c00135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613f1157613f11613ebe565b60405290565b60405160c0810167ffffffffffffffff81118282101715613f1157613f11613ebe565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613f8157613f81613ebe565b604052919050565b600067ffffffffffffffff821115613fa357613fa3613ebe565b5060051b60200190565b600082601f830112613fbe57600080fd5b81356020613fd3613fce83613f89565b613f3a565b82815260059290921b84018101918181019086841115613ff257600080fd5b8286015b8481101561401657803561400981613ca4565b8352918301918301613ff6565b509695505050505050565b803560ff81168114613b6157600080fd5b63ffffffff811681146121c657600080fd5b8035613b6181614032565b62ffffff811681146121c657600080fd5b8035613b618161404f565b61ffff811681146121c657600080fd5b8035613b618161406b565b6bffffffffffffffffffffffff811681146121c657600080fd5b8035613b6181614086565b60006101e082840312156140be57600080fd5b6140c6613eed565b90506140d182614044565b81526140df60208301614044565b60208201526140f060408301614044565b604082015261410160608301614060565b60608201526141126080830161407b565b608082015261412360a083016140a0565b60a082015261413460c08301614044565b60c082015261414560e08301614044565b60e0820152610100614158818401614044565b9082015261012061416a838201614044565b9082015261014082810135908201526101608083013590820152610180614192818401613cc6565b908201526101a08281013567ffffffffffffffff8111156141b257600080fd5b6141be85828601613fad565b8284015250506101c06141d2818401613cc6565b9082015292915050565b803567ffffffffffffffff81168114613b6157600080fd5b600082601f83011261420557600080fd5b813567ffffffffffffffff81111561421f5761421f613ebe565b61425060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f3a565b81815284602083860101111561426557600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561429b57600080fd5b863567ffffffffffffffff808211156142b357600080fd5b6142bf8a838b01613fad565b975060208901359150808211156142d557600080fd5b6142e18a838b01613fad565b96506142ef60408a01614021565b9550606089013591508082111561430557600080fd5b6143118a838b016140ab565b945061431f60808a016141dc565b935060a089013591508082111561433557600080fd5b5061434289828a016141f4565b9150509295509295509295565b60008060008060008060c0878903121561436857600080fd5b863567ffffffffffffffff8082111561438057600080fd5b61438c8a838b01613fad565b975060208901359150808211156143a257600080fd5b6143ae8a838b01613fad565b96506143bc60408a01614021565b955060608901359150808211156143d257600080fd5b6143118a838b016141f4565b6000602082840312156143f057600080fd5b8135612e6681613ca4565b60006020828403121561440d57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156139b6576139b6614414565b8082018082111561272c5761272c614414565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60ff818116838216019081111561272c5761272c614414565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156139b6576139b6614414565b8181038181111561272c5761272c614414565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361455157614551614414565b5060010190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561459057614590614414565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826145d3576145d3614595565b500490565b600060ff821660ff84168160ff04811182151516156145f9576145f9614414565b029392505050565b63ffffffff8181168382160190808211156139b6576139b6614414565b600081518084526020808501945080840160005b8381101561466457815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614632565b509495945050505050565b6020815261468660208201835163ffffffff169052565b6000602083015161469f604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e08301516101006147188185018363ffffffff169052565b84015190506101206147318482018363ffffffff169052565b840151905061014061474a8482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a061478d8185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526147ad61020086018461461e565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526148038184018a61461e565b90508281036080840152614817818961461e565b905060ff871660a084015282810360c08401526148348187613c47565b905067ffffffffffffffff851660e08401528281036101008401526148598185613c47565b9c9b505050505050505050505050565b8051613b6181614032565b8051613b618161404f565b8051613b618161406b565b8051613b6181614086565b8051613b6181613ca4565b600082601f8301126148b157600080fd5b815160206148c1613fce83613f89565b82815260059290921b840181019181810190868411156148e057600080fd5b8286015b848110156140165780516148f781613ca4565b83529183019183016148e4565b60006020828403121561491657600080fd5b815167ffffffffffffffff8082111561492e57600080fd5b908301906101e0828603121561494357600080fd5b61494b613eed565b61495483614869565b815261496260208401614869565b602082015261497360408401614869565b604082015261498460608401614874565b60608201526149956080840161487f565b60808201526149a660a0840161488a565b60a08201526149b760c08401614869565b60c08201526149c860e08401614869565b60e08201526101006149db818501614869565b908201526101206149ed848201614869565b9082015261014083810151908201526101608084015190820152610180614a15818501614895565b908201526101a08381015183811115614a2d57600080fd5b614a39888287016148a0565b8284015250506101c09150614a4f828401614895565b91810191909152949350505050565b8281526040602082015260006127d56040830184613c47565b60008060408385031215614a8a57600080fd5b82518015158114614a9a57600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614ae157600080fd5b81356020614af1613fce83613f89565b82815260059290921b84018101918181019086841115614b1057600080fd5b8286015b848110156140165780358352918301918301614b14565b600082601f830112614b3c57600080fd5b81356020614b4c613fce83613f89565b82815260059290921b84018101918181019086841115614b6b57600080fd5b8286015b8481101561401657803567ffffffffffffffff811115614b8f5760008081fd5b614b9d8986838b01016141f4565b845250918301918301614b6f565b600060208284031215614bbd57600080fd5b813567ffffffffffffffff80821115614bd557600080fd5b9083019060c08286031215614be957600080fd5b614bf1613f17565b8235815260208301356020820152604083013582811115614c1157600080fd5b614c1d87828601614ad0565b604083015250606083013582811115614c3557600080fd5b614c4187828601614ad0565b606083015250608083013582811115614c5957600080fd5b614c6587828601614b2b565b60808301525060a083013582811115614c7d57600080fd5b614c8987828601614b2b565b60a08301525095945050505050565b82815260008251614cb0816020850160208701613c23565b919091016020019392505050565b6bffffffffffffffffffffffff8281168282160390808211156139b6576139b6614414565b60006bffffffffffffffffffffffff80841680614d0257614d02614595565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614d3957614d39614414565b02949350505050565b600060208284031215614d5457600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614da28285018b61461e565b91508382036080850152614db6828a61461e565b915060ff881660a085015283820360c0850152614dd38288613c47565b90861660e085015283810361010085015290506148598185613c47565b828482376000838201600081528351614e0d818360208801613c23565b0195945050505050565b600063ffffffff80831681851681830481118215151615614d3957614d39614414565b60008060008060008060c08789031215614e5357600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614e9657600080fd5b6040516040810181811067ffffffffffffffff82111715614eb957614eb9613ebe565b6040528251614ec781614032565b81526020928301519281019290925250919050565b600060808284031215614eee57600080fd5b6040516080810181811067ffffffffffffffff82111715614f1157614f11613ebe565b604052825181526020830151614f2681614032565b60208201526040830151614f3981614032565b60408201526060928301519281019290925250919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryABI = KeeperRegistryMetaData.ABI @@ -341,28 +341,28 @@ func (_KeeperRegistry *KeeperRegistryTransactorSession) OnTokenTransfer(sender c return _KeeperRegistry.Contract.OnTokenTransfer(&_KeeperRegistry.TransactOpts, sender, amount, data) } -func (_KeeperRegistry *KeeperRegistryTransactor) SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _KeeperRegistry.contract.Transact(opts, "setConfig", signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_KeeperRegistry *KeeperRegistryTransactor) SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _KeeperRegistry.contract.Transact(opts, "setConfig", signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) } -func (_KeeperRegistry *KeeperRegistrySession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _KeeperRegistry.Contract.SetConfig(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_KeeperRegistry *KeeperRegistrySession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _KeeperRegistry.Contract.SetConfig(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) } -func (_KeeperRegistry *KeeperRegistryTransactorSession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _KeeperRegistry.Contract.SetConfig(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_KeeperRegistry *KeeperRegistryTransactorSession) SetConfig(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _KeeperRegistry.Contract.SetConfig(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) } -func (_KeeperRegistry *KeeperRegistryTransactor) SetConfig0(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _KeeperRegistry.contract.Transact(opts, "setConfig0", signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) +func (_KeeperRegistry *KeeperRegistryTransactor) SetConfigTypeSafe(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _KeeperRegistry.contract.Transact(opts, "setConfigTypeSafe", signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } -func (_KeeperRegistry *KeeperRegistrySession) SetConfig0(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _KeeperRegistry.Contract.SetConfig0(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) +func (_KeeperRegistry *KeeperRegistrySession) SetConfigTypeSafe(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _KeeperRegistry.Contract.SetConfigTypeSafe(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } -func (_KeeperRegistry *KeeperRegistryTransactorSession) SetConfig0(signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _KeeperRegistry.Contract.SetConfig0(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfigBytes, offchainConfigVersion, offchainConfig) +func (_KeeperRegistry *KeeperRegistryTransactorSession) SetConfigTypeSafe(signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { + return _KeeperRegistry.Contract.SetConfigTypeSafe(&_KeeperRegistry.TransactOpts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } func (_KeeperRegistry *KeeperRegistryTransactor) SimulatePerformUpkeep(opts *bind.TransactOpts, id *big.Int, performData []byte) (*types.Transaction, error) { @@ -4820,9 +4820,9 @@ type KeeperRegistryInterface interface { OnTokenTransfer(opts *bind.TransactOpts, sender common.Address, amount *big.Int, data []byte) (*types.Transaction, error) - SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) + SetConfig(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) - SetConfig0(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfigBytes []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) + SetConfigTypeSafe(opts *bind.TransactOpts, signers []common.Address, transmitters []common.Address, f uint8, onchainConfig KeeperRegistryBase21OnchainConfig, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) SimulatePerformUpkeep(opts *bind.TransactOpts, id *big.Int, performData []byte) (*types.Transaction, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e059fc5f92f..0ff1ae31d3c 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -19,7 +19,7 @@ flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../cont functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 -i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin f572f28c8f8ff8e07ef1331d70489926d314bd4ba72f6af5df4ee21d2e73e81a +i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin fb976990e21d6c454245bcd3247d71b2f045a7c5636adaebfe64b7449cb6042e i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 @@ -31,7 +31,7 @@ keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../. keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 -keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 0cb301ae98d7d3f5c53da3534724896b2bd423a136ec9fb292a766ba9c64c765 +keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 307482ad11b5025b59b3373bf2032280d215334addd158d3f876d439ad834398 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 diff --git a/core/scripts/chaincli/handler/keeper_deployer.go b/core/scripts/chaincli/handler/keeper_deployer.go index f353a602911..a53f236453a 100644 --- a/core/scripts/chaincli/handler/keeper_deployer.go +++ b/core/scripts/chaincli/handler/keeper_deployer.go @@ -353,7 +353,7 @@ func (d *v21KeeperDeployer) SetKeepers(opts *bind.TransactOpts, cls []cmd.HTTPCl UpkeepPrivilegeManager: common.HexToAddress(d.cfg.UpkeepPrivilegeManager), } - return d.IKeeperRegistryMasterInterface.SetConfig(opts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) + return d.IKeeperRegistryMasterInterface.SetConfigTypeSafe(opts, signers, transmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) } // legacy support function From f53d37247ecfd0826e934b0ca109dd7d95c43543 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Thu, 27 Jul 2023 12:25:11 -0400 Subject: [PATCH 016/270] Add AutomationForwarderLogic contract to chaincli (#9951) * deploy AutomationForwarderLogic in chaincli * add forwarder logic contract wrapper * update chainCLI to deploy AutomationForwarderLogic --- contracts/scripts/native_solc_compile_all | 1 + .../dev/automation/2_1/AutomationUtils2_1.sol | 1 - .../automation_forwarder_logic.go | 240 ++++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + core/gethwrappers/go_generate.go | 1 + core/scripts/chaincli/handler/keeper.go | 13 +- 6 files changed, 254 insertions(+), 3 deletions(-) create mode 100644 core/gethwrappers/generated/automation_forwarder_logic/automation_forwarder_logic.go diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index d85b4b32150..2ac3de0fa04 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -57,6 +57,7 @@ $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistryLogicB2_1.s $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/interfaces/ILogAutomation.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationUtils2_1.sol +$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationForwarderLogic.sol $SCRIPTPATH/native_solc8_6_compile dev/automation/tests/LogUpkeepCounter.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/tests/LogTriggeredFeedLookup.sol $SCRIPTPATH/native_solc8_6_compile automation/UpkeepTranscoder.sol diff --git a/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol b/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol index 738a0f42deb..cf2dd34fdfa 100644 --- a/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol @@ -15,7 +15,6 @@ import "./interfaces/ILogAutomation.sol"; */ struct LogTriggerConfig { address contractAddress; - // TODO - bytes1? uint8 filterSelector; // denotes which topics apply to filter ex 000, 101, 111...only last 3 bits apply bytes32 topic0; bytes32 topic1; diff --git a/core/gethwrappers/generated/automation_forwarder_logic/automation_forwarder_logic.go b/core/gethwrappers/generated/automation_forwarder_logic/automation_forwarder_logic.go new file mode 100644 index 00000000000..b26f5e5692c --- /dev/null +++ b/core/gethwrappers/generated/automation_forwarder_logic/automation_forwarder_logic.go @@ -0,0 +1,240 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package automation_forwarder_logic + +import ( + "errors" + "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" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var AutomationForwarderLogicMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[],\"name\":\"getRegistry\",\"outputs\":[{\"internalType\":\"contractIAutomationRegistryConsumer\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newRegistry\",\"type\":\"address\"}],\"name\":\"updateRegistry\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b506101f6806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063181f5a77146100465780631a5da6c8146100985780635ab1bd53146100ad575b600080fd5b6100826040518060400160405280601981526020017f4175746f6d6174696f6e466f7277617264657220312e302e300000000000000081525081565b60405161008f9190610140565b60405180910390f35b6100ab6100a63660046101ac565b6100d5565b005b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161008f565b60005473ffffffffffffffffffffffffffffffffffffffff1633146100f957600080fd5b600080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b600060208083528351808285015260005b8181101561016d57858101830151858201604001528201610151565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b6000602082840312156101be57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff811681146101e257600080fd5b939250505056fea164736f6c6343000810000a", +} + +var AutomationForwarderLogicABI = AutomationForwarderLogicMetaData.ABI + +var AutomationForwarderLogicBin = AutomationForwarderLogicMetaData.Bin + +func DeployAutomationForwarderLogic(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *AutomationForwarderLogic, error) { + parsed, err := AutomationForwarderLogicMetaData.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(AutomationForwarderLogicBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &AutomationForwarderLogic{AutomationForwarderLogicCaller: AutomationForwarderLogicCaller{contract: contract}, AutomationForwarderLogicTransactor: AutomationForwarderLogicTransactor{contract: contract}, AutomationForwarderLogicFilterer: AutomationForwarderLogicFilterer{contract: contract}}, nil +} + +type AutomationForwarderLogic struct { + address common.Address + abi abi.ABI + AutomationForwarderLogicCaller + AutomationForwarderLogicTransactor + AutomationForwarderLogicFilterer +} + +type AutomationForwarderLogicCaller struct { + contract *bind.BoundContract +} + +type AutomationForwarderLogicTransactor struct { + contract *bind.BoundContract +} + +type AutomationForwarderLogicFilterer struct { + contract *bind.BoundContract +} + +type AutomationForwarderLogicSession struct { + Contract *AutomationForwarderLogic + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type AutomationForwarderLogicCallerSession struct { + Contract *AutomationForwarderLogicCaller + CallOpts bind.CallOpts +} + +type AutomationForwarderLogicTransactorSession struct { + Contract *AutomationForwarderLogicTransactor + TransactOpts bind.TransactOpts +} + +type AutomationForwarderLogicRaw struct { + Contract *AutomationForwarderLogic +} + +type AutomationForwarderLogicCallerRaw struct { + Contract *AutomationForwarderLogicCaller +} + +type AutomationForwarderLogicTransactorRaw struct { + Contract *AutomationForwarderLogicTransactor +} + +func NewAutomationForwarderLogic(address common.Address, backend bind.ContractBackend) (*AutomationForwarderLogic, error) { + abi, err := abi.JSON(strings.NewReader(AutomationForwarderLogicABI)) + if err != nil { + return nil, err + } + contract, err := bindAutomationForwarderLogic(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &AutomationForwarderLogic{address: address, abi: abi, AutomationForwarderLogicCaller: AutomationForwarderLogicCaller{contract: contract}, AutomationForwarderLogicTransactor: AutomationForwarderLogicTransactor{contract: contract}, AutomationForwarderLogicFilterer: AutomationForwarderLogicFilterer{contract: contract}}, nil +} + +func NewAutomationForwarderLogicCaller(address common.Address, caller bind.ContractCaller) (*AutomationForwarderLogicCaller, error) { + contract, err := bindAutomationForwarderLogic(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &AutomationForwarderLogicCaller{contract: contract}, nil +} + +func NewAutomationForwarderLogicTransactor(address common.Address, transactor bind.ContractTransactor) (*AutomationForwarderLogicTransactor, error) { + contract, err := bindAutomationForwarderLogic(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &AutomationForwarderLogicTransactor{contract: contract}, nil +} + +func NewAutomationForwarderLogicFilterer(address common.Address, filterer bind.ContractFilterer) (*AutomationForwarderLogicFilterer, error) { + contract, err := bindAutomationForwarderLogic(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &AutomationForwarderLogicFilterer{contract: contract}, nil +} + +func bindAutomationForwarderLogic(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := AutomationForwarderLogicMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _AutomationForwarderLogic.Contract.AutomationForwarderLogicCaller.contract.Call(opts, result, method, params...) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationForwarderLogic.Contract.AutomationForwarderLogicTransactor.contract.Transfer(opts) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _AutomationForwarderLogic.Contract.AutomationForwarderLogicTransactor.contract.Transact(opts, method, params...) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _AutomationForwarderLogic.Contract.contract.Call(opts, result, method, params...) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationForwarderLogic.Contract.contract.Transfer(opts) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _AutomationForwarderLogic.Contract.contract.Transact(opts, method, params...) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicCaller) GetRegistry(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _AutomationForwarderLogic.contract.Call(opts, &out, "getRegistry") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicSession) GetRegistry() (common.Address, error) { + return _AutomationForwarderLogic.Contract.GetRegistry(&_AutomationForwarderLogic.CallOpts) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicCallerSession) GetRegistry() (common.Address, error) { + return _AutomationForwarderLogic.Contract.GetRegistry(&_AutomationForwarderLogic.CallOpts) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _AutomationForwarderLogic.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicSession) TypeAndVersion() (string, error) { + return _AutomationForwarderLogic.Contract.TypeAndVersion(&_AutomationForwarderLogic.CallOpts) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicCallerSession) TypeAndVersion() (string, error) { + return _AutomationForwarderLogic.Contract.TypeAndVersion(&_AutomationForwarderLogic.CallOpts) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicTransactor) UpdateRegistry(opts *bind.TransactOpts, newRegistry common.Address) (*types.Transaction, error) { + return _AutomationForwarderLogic.contract.Transact(opts, "updateRegistry", newRegistry) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicSession) UpdateRegistry(newRegistry common.Address) (*types.Transaction, error) { + return _AutomationForwarderLogic.Contract.UpdateRegistry(&_AutomationForwarderLogic.TransactOpts, newRegistry) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogicTransactorSession) UpdateRegistry(newRegistry common.Address) (*types.Transaction, error) { + return _AutomationForwarderLogic.Contract.UpdateRegistry(&_AutomationForwarderLogic.TransactOpts, newRegistry) +} + +func (_AutomationForwarderLogic *AutomationForwarderLogic) Address() common.Address { + return _AutomationForwarderLogic.address +} + +type AutomationForwarderLogicInterface interface { + GetRegistry(opts *bind.CallOpts) (common.Address, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + UpdateRegistry(opts *bind.TransactOpts, newRegistry common.Address) (*types.Transaction, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 0ff1ae31d3c..09a68174bee 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -4,6 +4,7 @@ aggregator_v3_interface: ../../contracts/solc/v0.8.6/AggregatorV3Interface.abi . authorized_forwarder: ../../contracts/solc/v0.7/AuthorizedForwarder.abi ../../contracts/solc/v0.7/AuthorizedForwarder.bin 426d0866a294c77b27a526265f98c688326eb3dec3b7a698180c5f1921ebdf56 authorized_receiver: ../../contracts/solc/v0.7/AuthorizedReceiver.abi ../../contracts/solc/v0.7/AuthorizedReceiver.bin 18e8969ba3234b027e1b16c11a783aca58d0ea5c2361010ec597f134b7bf1c4f automation_consumer_benchmark: ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.abi ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.bin f52c76f1aaed4be541d82d97189d70f5aa027fc9838037dd7a7d21910c8c488e +automation_forwarder_logic: ../../contracts/solc/v0.8.16/AutomationForwarderLogic.abi ../../contracts/solc/v0.8.16/AutomationForwarderLogic.bin 15ae0c367297955fdab4b552dbb10e1f2be80a8fde0efec4a4d398693e9d72b5 automation_utils_2_1: ../../contracts/solc/v0.8.16/AutomationUtils2_1.abi ../../contracts/solc/v0.8.16/AutomationUtils2_1.bin 0b3006a2a1588916d22bf1ae5429bd3bce24a58904588d5ed3fe1026d64616cf batch_blockhash_store: ../../contracts/solc/v0.8.6/BatchBlockhashStore.abi ../../contracts/solc/v0.8.6/BatchBlockhashStore.bin c5ab26709a01050402615659403f32d5cd1b85f3ad6bb6bfe021692f4233cf19 batch_vrf_coordinator_v2: ../../contracts/solc/v0.8.6/BatchVRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/BatchVRFCoordinatorV2.bin d0a54963260d8c1f1bbd984b758285e6027cfb5a7e42701bcb562ab123219332 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 270ab016e61..5700c939a78 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -55,6 +55,7 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin IKeeperRegistryMaster i_keeper_registry_master_wrapper_2_1 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin ILogAutomation i_log_automation //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationUtils2_1.abi ../../contracts/solc/v0.8.16/AutomationUtils2_1.bin AutomationUtils automation_utils_2_1 +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationForwarderLogic.abi ../../contracts/solc/v0.8.16/AutomationForwarderLogic.bin AutomationForwarderLogic automation_forwarder_logic //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin LogUpkeepCounter log_upkeep_counter_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin LogTriggeredFeedLookup log_triggered_feed_lookup_wrapper diff --git a/core/scripts/chaincli/handler/keeper.go b/core/scripts/chaincli/handler/keeper.go index 9a5457f8cc0..4db80829e2b 100644 --- a/core/scripts/chaincli/handler/keeper.go +++ b/core/scripts/chaincli/handler/keeper.go @@ -17,6 +17,7 @@ import ( "github.com/smartcontractkit/chainlink/core/scripts/chaincli/config" helpers "github.com/smartcontractkit/chainlink/core/scripts/common" "github.com/smartcontractkit/chainlink/v2/core/cmd" + automationForwarderLogic "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_forwarder_logic" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" registrylogic20 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic2_0" registrylogica21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1" @@ -250,6 +251,13 @@ func (k *Keeper) VerifyContract(params ...string) { // deployRegistry21 deploys a version 2.1 keeper registry func (k *Keeper) deployRegistry21(ctx context.Context, verify bool) (common.Address, *iregistry21.IKeeperRegistryMaster) { + automationForwarderLogicAddr, tx, _, err := automationForwarderLogic.DeployAutomationForwarderLogic(k.buildTxOpts(ctx), k.client) + if err != nil { + log.Fatal("Deploy AutomationForwarderLogic failed: ", err) + } + k.waitDeployment(ctx, tx) + log.Println("AutomationForwarderLogic deployed:", automationForwarderLogicAddr.Hex(), "-", helpers.ExplorerLink(k.cfg.ChainID, tx.Hash())) + registryLogicBAddr, tx, _, err := registrylogicb21.DeployKeeperRegistryLogicB( k.buildTxOpts(ctx), k.client, @@ -257,12 +265,13 @@ func (k *Keeper) deployRegistry21(ctx context.Context, verify bool) (common.Addr common.HexToAddress(k.cfg.LinkTokenAddr), common.HexToAddress(k.cfg.LinkETHFeedAddr), common.HexToAddress(k.cfg.FastGasFeedAddr), + automationForwarderLogicAddr, ) if err != nil { log.Fatal("DeployAbi failed: ", err) } k.waitDeployment(ctx, tx) - log.Println("KeeperRegistryLogicB 2.1 Logic deployed:", registryLogicBAddr.Hex(), "-", helpers.ExplorerLink(k.cfg.ChainID, tx.Hash())) + log.Println("KeeperRegistry LogicB 2.1 deployed:", registryLogicBAddr.Hex(), "-", helpers.ExplorerLink(k.cfg.ChainID, tx.Hash())) // verify KeeperRegistryLogicB if verify { @@ -279,7 +288,7 @@ func (k *Keeper) deployRegistry21(ctx context.Context, verify bool) (common.Addr log.Fatal("DeployAbi failed: ", err) } k.waitDeployment(ctx, tx) - log.Println("KeeperRegistryLogicA 2.1 Logic deployed:", registryLogicAAddr.Hex(), "-", helpers.ExplorerLink(k.cfg.ChainID, tx.Hash())) + log.Println("KeeperRegistry LogicA 2.1 deployed:", registryLogicAAddr.Hex(), "-", helpers.ExplorerLink(k.cfg.ChainID, tx.Hash())) // verify KeeperRegistryLogicA if verify { From 0922ee153cef13f539ba6813e4cc90969cb2e536 Mon Sep 17 00:00:00 2001 From: ilija42 <57732589+ilija42@users.noreply.github.com> Date: Thu, 27 Jul 2023 19:37:10 +0200 Subject: [PATCH 017/270] Fix TestIntegration_VRF_WithBHS race condition (#9953) * Fix TestIntegration_VRF_WithBHS race condition * Fix potential raciness in TestIntegration_VRF_JPV2 --- core/services/vrf/v1/integration_test.go | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/core/services/vrf/v1/integration_test.go b/core/services/vrf/v1/integration_test.go index d0c87c9cc99..d9154a4873f 100644 --- a/core/services/vrf/v1/integration_test.go +++ b/core/services/vrf/v1/integration_test.go @@ -89,6 +89,10 @@ func TestIntegration_VRF_JPV2(t *testing.T) { assert.NotNil(t, 0, runs[0].Outputs.Val) assert.NotNil(t, 0, runs[1].Outputs.Val) + // stop jobs as to not cause a race condition in geth simulated backend + // between job creating new tx and fulfillment logs polling below + require.NoError(t, app.JobSpawner().DeleteJob(jb.ID)) + // Ensure the eth transaction gets confirmed on chain. gomega.NewWithT(t).Eventually(func() bool { orm := txmgr.NewTxStore(app.GetSqlxDB(), app.GetLogger(), app.GetConfig().Database()) @@ -142,7 +146,7 @@ func TestIntegration_VRF_WithBHS(t *testing.T) { sendingKeys := []string{key.Address.String()} // Create BHS Job and start it - _ = vrftesthelpers.CreateAndStartBHSJob(t, sendingKeys, app, cu.BHSContractAddress.String(), + bhsJob := vrftesthelpers.CreateAndStartBHSJob(t, sendingKeys, app, cu.BHSContractAddress.String(), cu.RootContractAddress.String(), "", "") // Ensure log poller is ready and has all logs. @@ -200,6 +204,11 @@ func TestIntegration_VRF_WithBHS(t *testing.T) { assert.Equal(t, 4, len(runs[0].PipelineTaskRuns)) assert.NotNil(t, 0, runs[0].Outputs.Val) + // stop jobs as to not cause a race condition in geth simulated backend + // between job creating new tx and fulfillment logs polling below + require.NoError(t, app.JobSpawner().DeleteJob(jb.ID)) + require.NoError(t, app.JobSpawner().DeleteJob(bhsJob.ID)) + // Ensure the eth transaction gets confirmed on chain. gomega.NewWithT(t).Eventually(func() bool { orm := txmgr.NewTxStore(app.GetSqlxDB(), app.GetLogger(), app.GetConfig().Database()) From 0bebc35a14388fa1f4dd9bc9d94fb5cb45c8e332 Mon Sep 17 00:00:00 2001 From: Oliver Townsend <133903322+ogtownsend@users.noreply.github.com> Date: Thu, 27 Jul 2023 10:59:36 -0700 Subject: [PATCH 018/270] generating registrar v2.1 (#9911) --- contracts/scripts/native_solc_compile_all | 1 + .../automation_registrar_wrapper2_1.go | 1685 +++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + core/gethwrappers/go_generate.go | 1 + 4 files changed, 1688 insertions(+) create mode 100644 core/gethwrappers/generated/automation_registrar_wrapper2_1/automation_registrar_wrapper2_1.go diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 2ac3de0fa04..5c295290fe2 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -51,6 +51,7 @@ $SCRIPTPATH/native_solc8_6_compile automation/1_3/KeeperRegistryLogic1_3.sol $SCRIPTPATH/native_solc8_6_compile automation/2_0/KeeperRegistrar2_0.sol $SCRIPTPATH/native_solc8_6_compile automation/2_0/KeeperRegistry2_0.sol $SCRIPTPATH/native_solc8_6_compile automation/2_0/KeeperRegistryLogic2_0.sol +$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationRegistrar2_1.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistry2_1.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistryLogicA2_1.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistryLogicB2_1.sol diff --git a/core/gethwrappers/generated/automation_registrar_wrapper2_1/automation_registrar_wrapper2_1.go b/core/gethwrappers/generated/automation_registrar_wrapper2_1/automation_registrar_wrapper2_1.go new file mode 100644 index 00000000000..d2b8054436a --- /dev/null +++ b/core/gethwrappers/generated/automation_registrar_wrapper2_1/automation_registrar_wrapper2_1.go @@ -0,0 +1,1685 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package automation_registrar_wrapper2_1 + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type AutomationRegistrar21InitialTriggerConfig struct { + TriggerType uint8 + AutoApproveType uint8 + AutoApproveMaxAllowed uint32 +} + +type AutomationRegistrar21RegistrationParams struct { + Name string + EncryptedEmail []byte + UpkeepContract common.Address + GasLimit uint32 + AdminAddress common.Address + TriggerType uint8 + CheckData []byte + TriggerConfig []byte + OffchainConfig []byte + Amount *big.Int +} + +type AutomationRegistrar21TriggerRegistrationStorage struct { + AutoApproveType uint8 + AutoApproveMaxAllowed uint32 + ApprovedCount uint32 +} + +var AutomationRegistrarMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"LINKAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"minLINKJuels\",\"type\":\"uint96\"},{\"components\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"enumAutomationRegistrar2_1.AutoApproveType\",\"name\":\"autoApproveType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"}],\"internalType\":\"structAutomationRegistrar2_1.InitialTriggerConfig[]\",\"name\":\"triggerConfigs\",\"type\":\"tuple[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AmountMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FunctionNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"HashMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientPayment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAdminAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"LinkTransferFailed\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyAdminOrOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistrationRequestFailed\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RequestNotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"SenderMismatch\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"AutoApproveAllowedSenderSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"minLINKJuels\",\"type\":\"uint96\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"displayName\",\"type\":\"string\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"RegistrationApproved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"}],\"name\":\"RegistrationRejected\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"encryptedEmail\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"upkeepContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"RegistrationRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"enumAutomationRegistrar2_1.AutoApproveType\",\"name\":\"autoApproveType\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"}],\"name\":\"TriggerConfigSet\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"address\",\"name\":\"upkeepContract\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"}],\"name\":\"approve\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"}],\"name\":\"cancel\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"}],\"name\":\"getAutoApproveAllowedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"minLINKJuels\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"}],\"name\":\"getPendingRequest\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"}],\"name\":\"getTriggerRegistrationDetails\",\"outputs\":[{\"components\":[{\"internalType\":\"enumAutomationRegistrar2_1.AutoApproveType\",\"name\":\"autoApproveType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"approvedCount\",\"type\":\"uint32\"}],\"internalType\":\"structAutomationRegistrar2_1.TriggerRegistrationStorage\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedEmail\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"upkeepContract\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"register\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedEmail\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"upkeepContract\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"internalType\":\"structAutomationRegistrar2_1.RegistrationParams\",\"name\":\"requestParams\",\"type\":\"tuple\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"setAutoApproveAllowedSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"minLINKJuels\",\"type\":\"uint96\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"enumAutomationRegistrar2_1.AutoApproveType\",\"name\":\"autoApproveType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"}],\"name\":\"setTriggerConfig\",\"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\":\"view\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162002d8238038062002d8283398101604081905262000034916200043b565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be816200017a565b5050506001600160a01b038416608052620000da838362000225565b60005b81518110156200016f576200015a82828151811062000100576200010062000598565b60200260200101516000015183838151811062000121576200012162000598565b60200260200101516020015184848151811062000142576200014262000598565b6020026020010151604001516200029e60201b60201c565b806200016681620005ae565b915050620000dd565b50505050506200062f565b336001600160a01b03821603620001d45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6200022f6200034c565b6040805180820182526001600160a01b0384168082526001600160601b0384166020928301819052600160a01b810282176004558351918252918101919091527f39ce5d867555f0b0183e358fce5b158e7ca4fecd7c01cb7e0e19f1e23285838a910160405180910390a15050565b620002a86200034c565b60ff83166000908152600360205260409020805483919060ff19166001836002811115620002da57620002da620005d6565b021790555060ff831660009081526003602052604090819020805464ffffffff00191661010063ffffffff851602179055517f830a6d06a4e2caac67eba04323de22bdb04f032dd8b3d6a0c52b503d9a7036a3906200033f90859085908590620005ec565b60405180910390a1505050565b6000546001600160a01b03163314620003a85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000082565b565b80516001600160a01b0381168114620003c257600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051606081016001600160401b0381118282101715620004025762000402620003c7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004335762000433620003c7565b604052919050565b600080600080608085870312156200045257600080fd5b6200045d85620003aa565b935060206200046e818701620003aa565b604087810151919550906001600160601b03811681146200048e57600080fd5b606088810151919550906001600160401b0380821115620004ae57600080fd5b818a0191508a601f830112620004c357600080fd5b815181811115620004d857620004d8620003c7565b620004e8868260051b0162000408565b818152868101925090840283018601908c8211156200050657600080fd5b928601925b81841015620005875784848e031215620005255760008081fd5b6200052f620003dd565b845160ff81168114620005425760008081fd5b81528488015160038110620005575760008081fd5b818901528487015163ffffffff81168114620005735760008081fd5b81880152835292840192918601916200050b565b999c989b5096995050505050505050565b634e487b7160e01b600052603260045260246000fd5b600060018201620005cf57634e487b7160e01b600052601160045260246000fd5b5060010190565b634e487b7160e01b600052602160045260246000fd5b60ff8416815260608101600384106200061557634e487b7160e01b600052602160045260246000fd5b83602083015263ffffffff83166040830152949350505050565b6080516127146200066e60003960008181610177015281816105d601528181610887015281816109bd01528181610f0e015261171b01526127146000f3fe608060405234801561001057600080fd5b506004361061011b5760003560e01c8063856853e6116100b2578063b5ff5b4111610081578063c4d252f511610066578063c4d252f5146103e3578063e8d4070d146103f6578063f2fde38b1461040957600080fd5b8063b5ff5b4114610369578063c3f909d41461037c57600080fd5b8063856853e61461027857806388b12d551461028b5780638da5cb5b14610338578063a4c0ed361461035657600080fd5b80633f678e11116100ee5780633f678e11146101f35780636c4cdfc31461021457806379ba5097146102275780637e776f7f1461022f57600080fd5b8063181f5a77146101205780631b6b6d2314610172578063212d0884146101be578063367b9b4f146101de575b600080fd5b61015c6040518060400160405280601981526020017f4175746f6d6174696f6e52656769737472617220322e312e300000000000000081525081565b6040516101699190611a74565b60405180910390f35b6101997f000000000000000000000000000000000000000000000000000000000000000081565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610169565b6101d16101cc366004611aa4565b61041c565b6040516101699190611b29565b6101f16101ec366004611b9d565b6104a9565b005b610206610201366004611bd6565b61053b565b604051908152602001610169565b6101f1610222366004611c2e565b6106d3565b6101f161076d565b61026861023d366004611c63565b73ffffffffffffffffffffffffffffffffffffffff1660009081526005602052604090205460ff1690565b6040519015158152602001610169565b6101f1610286366004611de1565b61086f565b6102ff610299366004611f40565b60009081526002602090815260409182902082518084019093525473ffffffffffffffffffffffffffffffffffffffff8116808452740100000000000000000000000000000000000000009091046bffffffffffffffffffffffff169290910182905291565b6040805173ffffffffffffffffffffffffffffffffffffffff90931683526bffffffffffffffffffffffff909116602083015201610169565b60005473ffffffffffffffffffffffffffffffffffffffff16610199565b6101f1610364366004611f59565b6109a5565b6101f1610377366004611fb5565b610ce3565b60408051808201825260045473ffffffffffffffffffffffffffffffffffffffff8116808352740100000000000000000000000000000000000000009091046bffffffffffffffffffffffff16602092830181905283519182529181019190915201610169565b6101f16103f1366004611f40565b610dc2565b6101f1610404366004611ffe565b61104c565b6101f1610417366004611c63565b6112d9565b60408051606080820183526000808352602080840182905283850182905260ff86811683526003909152908490208451928301909452835492939192839116600281111561046c5761046c611abf565b600281111561047d5761047d611abf565b8152905463ffffffff610100820481166020840152650100000000009091041660409091015292915050565b6104b16112ed565b73ffffffffffffffffffffffffffffffffffffffff821660008181526005602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001685151590811790915591519182527f20c6237dac83526a849285a9f79d08a483291bdd3a056a0ef9ae94ecee1ad356910160405180910390a25050565b6004546000907401000000000000000000000000000000000000000090046bffffffffffffffffffffffff1661057961014084016101208501612109565b6bffffffffffffffffffffffff1610156105bf576040517fcd1c886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000166323b872dd333061060f61014087016101208801612109565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e086901b16815273ffffffffffffffffffffffffffffffffffffffff93841660048201529290911660248301526bffffffffffffffffffffffff1660448201526064016020604051808303816000875af1158015610696573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106ba9190612124565b506106cd6106c783612141565b33611370565b92915050565b6106db6112ed565b60408051808201825273ffffffffffffffffffffffffffffffffffffffff84168082526bffffffffffffffffffffffff8416602092830181905274010000000000000000000000000000000000000000810282176004558351918252918101919091527f39ce5d867555f0b0183e358fce5b158e7ca4fecd7c01cb7e0e19f1e23285838a910160405180910390a15050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146107f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146108de576040517f018d10be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109966040518061014001604052808e81526020018d8d8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050509082525073ffffffffffffffffffffffffffffffffffffffff808d16602083015263ffffffff8c1660408301528a16606082015260ff8916608082015260a0810188905260c0810187905260e081018690526bffffffffffffffffffffffff85166101009091015282611370565b50505050505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610a14576040517f018d10be00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81818080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050505060208101517fffffffff0000000000000000000000000000000000000000000000000000000081167f856853e60000000000000000000000000000000000000000000000000000000014610aca576040517fe3d6792100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8484846000610adc8260048186612276565b810190610ae991906122a0565b509950505050505050505050806bffffffffffffffffffffffff168414610b3c576040517f55e97b0d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8988886000610b4e8260048186612276565b810190610b5b91906122a0565b9a50505050505050505050508073ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff1614610bcc576040517ff8c5638e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6004547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff168d1015610c2e576040517fcd1c886700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60003073ffffffffffffffffffffffffffffffffffffffff168d8d604051610c579291906123dd565b600060405180830381855af49150503d8060008114610c92576040519150601f19603f3d011682016040523d82523d6000602084013e610c97565b606091505b5050905080610cd2576040517f649bf81000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050505050565b610ceb6112ed565b60ff8316600090815260036020526040902080548391907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836002811115610d3857610d38611abf565b021790555060ff83166000908152600360205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff851602179055517f830a6d06a4e2caac67eba04323de22bdb04f032dd8b3d6a0c52b503d9a7036a390610db5908590859085906123ed565b60405180910390a1505050565b60008181526002602090815260409182902082518084019093525473ffffffffffffffffffffffffffffffffffffffff8116808452740100000000000000000000000000000000000000009091046bffffffffffffffffffffffff1691830191909152331480610e49575060005473ffffffffffffffffffffffffffffffffffffffff1633145b610e7f576040517f61685c2b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805173ffffffffffffffffffffffffffffffffffffffff16610ecd576040517f4b13b31e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260026020908152604080832083905583519184015190517fa9059cbb0000000000000000000000000000000000000000000000000000000081527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169263a9059cbb92610f859260040173ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b6020604051808303816000875af1158015610fa4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fc89190612124565b90508061101c5781516040517fc2e4dce800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff90911660048201526024016107ea565b60405183907f3663fb28ebc87645eb972c9dad8521bf665c623f287e79f1c56f1eb374b82a2290600090a2505050565b6110546112ed565b60008181526002602090815260409182902082518084019093525473ffffffffffffffffffffffffffffffffffffffff8116808452740100000000000000000000000000000000000000009091046bffffffffffffffffffffffff16918301919091526110ed576040517f4b13b31e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008b8b8b8b8b8b8b8b8b60405160200161111099989796959493929190612461565b604051602081830303815290604052805190602001209050808314611161576040517f3f4d605300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60026000848152602001908152602001600020600080820160006101000a81549073ffffffffffffffffffffffffffffffffffffffff02191690556000820160146101000a8154906bffffffffffffffffffffffff021916905550506112c96040518061014001604052808f81526020016040518060200160405280600081525081526020018e73ffffffffffffffffffffffffffffffffffffffff1681526020018d63ffffffff1681526020018c73ffffffffffffffffffffffffffffffffffffffff1681526020018b60ff1681526020018a8a8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525050509082525060208082018a905260408051601f8a0183900483028101830182528981529201919089908990819084018382808284376000920191909152505050908252506020858101516bffffffffffffffffffffffff1691015282611647565b5050505050505050505050505050565b6112e16112ed565b6112ea81611876565b50565b60005473ffffffffffffffffffffffffffffffffffffffff16331461136e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107ea565b565b608082015160009073ffffffffffffffffffffffffffffffffffffffff166113c4576040517f05bb467c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008360400151846060015185608001518660a001518760c001518860e0015189610100015160405160200161140097969594939291906124e7565b604051602081830303815290604052805190602001209050836040015173ffffffffffffffffffffffffffffffffffffffff16817f7684390ebb103102f7f48c71439c2408713f8d437782a6fab2756acc0e42c1b786600001518760200151886060015189608001518a60a001518b60e001518c61010001518d60c001518e610120015160405161149999989796959493929190612569565b60405180910390a360a084015160ff9081166000908152600360205260408082208151606081019092528054929361151c9383911660028111156114df576114df611abf565b60028111156114f0576114f0611abf565b8152905463ffffffff61010082048116602084015265010000000000909104166040909101528561196b565b156115845760a085015160ff166000908152600360205260409020805465010000000000900463ffffffff1690600561155483612653565b91906101000a81548163ffffffff021916908363ffffffff1602179055505061157d8583611647565b905061163f565b61012085015160008381526002602052604081205490916115ca917401000000000000000000000000000000000000000090046bffffffffffffffffffffffff16612676565b604080518082018252608089015173ffffffffffffffffffffffffffffffffffffffff90811682526bffffffffffffffffffffffff9384166020808401918252600089815260029091529390932091519251909316740100000000000000000000000000000000000000000291909216179055505b949350505050565b600480546040808501516060860151608087015160a088015160c089015160e08a01516101008b015196517f28f32f3800000000000000000000000000000000000000000000000000000000815260009973ffffffffffffffffffffffffffffffffffffffff909916988a988a986328f32f38986116d29891979096919590949193909291016124e7565b6020604051808303816000875af11580156116f1573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061171591906126a2565b905060007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16634000aea0848861012001518560405160200161176f91815260200190565b6040516020818303038152906040526040518463ffffffff1660e01b815260040161179c939291906126bb565b6020604051808303816000875af11580156117bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117df9190612124565b905080611830576040517fc2e4dce800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201526024016107ea565b81857fb9a292fb7e3edd920cd2d2829a3615a640c43fd7de0a0820aa0668feb4c37d4b88600001516040516118659190611a74565b60405180910390a350949350505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036118f5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107ea565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808351600281111561198157611981611abf565b0361198e575060006106cd565b6001835160028111156119a3576119a3611abf565b1480156119d6575073ffffffffffffffffffffffffffffffffffffffff821660009081526005602052604090205460ff16155b156119e3575060006106cd565b826020015163ffffffff16836040015163ffffffff161015611a07575060016106cd565b50600092915050565b6000815180845260005b81811015611a3657602081850181015186830182015201611a1a565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611a876020830184611a10565b9392505050565b803560ff81168114611a9f57600080fd5b919050565b600060208284031215611ab657600080fd5b611a8782611a8e565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110611b25577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6000606082019050611b3c828451611aee565b602083015163ffffffff8082166020850152806040860151166040850152505092915050565b73ffffffffffffffffffffffffffffffffffffffff811681146112ea57600080fd5b8035611a9f81611b62565b80151581146112ea57600080fd5b60008060408385031215611bb057600080fd5b8235611bbb81611b62565b91506020830135611bcb81611b8f565b809150509250929050565b600060208284031215611be857600080fd5b813567ffffffffffffffff811115611bff57600080fd5b82016101408185031215611a8757600080fd5b80356bffffffffffffffffffffffff81168114611a9f57600080fd5b60008060408385031215611c4157600080fd5b8235611c4c81611b62565b9150611c5a60208401611c12565b90509250929050565b600060208284031215611c7557600080fd5b8135611a8781611b62565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715611cd357611cd3611c80565b60405290565b600082601f830112611cea57600080fd5b813567ffffffffffffffff80821115611d0557611d05611c80565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908282118183101715611d4b57611d4b611c80565b81604052838152866020858801011115611d6457600080fd5b836020870160208301376000602085830101528094505050505092915050565b60008083601f840112611d9657600080fd5b50813567ffffffffffffffff811115611dae57600080fd5b602083019150836020828501011115611dc657600080fd5b9250929050565b803563ffffffff81168114611a9f57600080fd5b6000806000806000806000806000806000806101608d8f031215611e0457600080fd5b67ffffffffffffffff8d351115611e1a57600080fd5b611e278e8e358f01611cd9565b9b5067ffffffffffffffff60208e01351115611e4257600080fd5b611e528e60208f01358f01611d84565b909b509950611e6360408e01611b84565b9850611e7160608e01611dcd565b9750611e7f60808e01611b84565b9650611e8d60a08e01611a8e565b955067ffffffffffffffff60c08e01351115611ea857600080fd5b611eb88e60c08f01358f01611cd9565b945067ffffffffffffffff60e08e01351115611ed357600080fd5b611ee38e60e08f01358f01611cd9565b935067ffffffffffffffff6101008e01351115611eff57600080fd5b611f108e6101008f01358f01611cd9565b9250611f1f6101208e01611c12565b9150611f2e6101408e01611b84565b90509295989b509295989b509295989b565b600060208284031215611f5257600080fd5b5035919050565b60008060008060608587031215611f6f57600080fd5b8435611f7a81611b62565b935060208501359250604085013567ffffffffffffffff811115611f9d57600080fd5b611fa987828801611d84565b95989497509550505050565b600080600060608486031215611fca57600080fd5b611fd384611a8e565b9250602084013560038110611fe757600080fd5b9150611ff560408501611dcd565b90509250925092565b60008060008060008060008060008060006101208c8e03121561202057600080fd5b67ffffffffffffffff808d35111561203757600080fd5b6120448e8e358f01611cd9565b9b5061205260208e01611b84565b9a5061206060408e01611dcd565b995061206e60608e01611b84565b985061207c60808e01611a8e565b97508060a08e0135111561208f57600080fd5b61209f8e60a08f01358f01611d84565b909750955060c08d01358110156120b557600080fd5b6120c58e60c08f01358f01611cd9565b94508060e08e013511156120d857600080fd5b506120e98d60e08e01358e01611d84565b81945080935050506101008c013590509295989b509295989b9093969950565b60006020828403121561211b57600080fd5b611a8782611c12565b60006020828403121561213657600080fd5b8151611a8781611b8f565b6000610140823603121561215457600080fd5b61215c611caf565b823567ffffffffffffffff8082111561217457600080fd5b61218036838701611cd9565b8352602085013591508082111561219657600080fd5b6121a236838701611cd9565b60208401526121b360408601611b84565b60408401526121c460608601611dcd565b60608401526121d560808601611b84565b60808401526121e660a08601611a8e565b60a084015260c08501359150808211156121ff57600080fd5b61220b36838701611cd9565b60c084015260e085013591508082111561222457600080fd5b61223036838701611cd9565b60e08401526101009150818501358181111561224b57600080fd5b61225736828801611cd9565b8385015250505061012061226c818501611c12565b9082015292915050565b6000808585111561228657600080fd5b8386111561229357600080fd5b5050820193919092039150565b60008060008060008060008060008060006101608c8e0312156122c257600080fd5b67ffffffffffffffff808d3511156122d957600080fd5b6122e68e8e358f01611cd9565b9b508060208e013511156122f957600080fd5b6123098e60208f01358f01611cd9565b9a5061231760408e01611b84565b995061232560608e01611dcd565b985061233360808e01611b84565b975061234160a08e01611a8e565b96508060c08e0135111561235457600080fd5b6123648e60c08f01358f01611cd9565b95508060e08e0135111561237757600080fd5b6123878e60e08f01358f01611cd9565b9450806101008e0135111561239b57600080fd5b506123ad8d6101008e01358e01611cd9565b92506123bc6101208d01611c12565b91506123cb6101408d01611b84565b90509295989b509295989b9093969950565b8183823760009101908152919050565b60ff84168152606081016124046020830185611aee565b63ffffffff83166040830152949350505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b600073ffffffffffffffffffffffffffffffffffffffff808c16835263ffffffff8b166020840152808a1660408401525060ff8816606083015260e060808301526124b060e083018789612418565b82810360a08401526124c28187611a10565b905082810360c08401526124d7818587612418565b9c9b505050505050505050505050565b600073ffffffffffffffffffffffffffffffffffffffff808a16835263ffffffff8916602084015280881660408401525060ff8616606083015260e0608083015261253560e0830186611a10565b82810360a08401526125478186611a10565b905082810360c084015261255b8185611a10565b9a9950505050505050505050565b600061012080835261257d8184018d611a10565b90508281036020840152612591818c611a10565b905063ffffffff8a16604084015273ffffffffffffffffffffffffffffffffffffffff8916606084015260ff8816608084015282810360a08401526125d68188611a10565b905082810360c08401526125ea8187611a10565b905082810360e08401526125fe8186611a10565b9150506bffffffffffffffffffffffff83166101008301529a9950505050505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff80831681810361266c5761266c612624565b6001019392505050565b6bffffffffffffffffffffffff81811683821601908082111561269b5761269b612624565b5092915050565b6000602082840312156126b457600080fd5b5051919050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff831660208201526060604082015260006126fe6060830184611a10565b9594505050505056fea164736f6c6343000810000a", +} + +var AutomationRegistrarABI = AutomationRegistrarMetaData.ABI + +var AutomationRegistrarBin = AutomationRegistrarMetaData.Bin + +func DeployAutomationRegistrar(auth *bind.TransactOpts, backend bind.ContractBackend, LINKAddress common.Address, keeperRegistry common.Address, minLINKJuels *big.Int, triggerConfigs []AutomationRegistrar21InitialTriggerConfig) (common.Address, *types.Transaction, *AutomationRegistrar, error) { + parsed, err := AutomationRegistrarMetaData.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(AutomationRegistrarBin), backend, LINKAddress, keeperRegistry, minLINKJuels, triggerConfigs) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &AutomationRegistrar{AutomationRegistrarCaller: AutomationRegistrarCaller{contract: contract}, AutomationRegistrarTransactor: AutomationRegistrarTransactor{contract: contract}, AutomationRegistrarFilterer: AutomationRegistrarFilterer{contract: contract}}, nil +} + +type AutomationRegistrar struct { + address common.Address + abi abi.ABI + AutomationRegistrarCaller + AutomationRegistrarTransactor + AutomationRegistrarFilterer +} + +type AutomationRegistrarCaller struct { + contract *bind.BoundContract +} + +type AutomationRegistrarTransactor struct { + contract *bind.BoundContract +} + +type AutomationRegistrarFilterer struct { + contract *bind.BoundContract +} + +type AutomationRegistrarSession struct { + Contract *AutomationRegistrar + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type AutomationRegistrarCallerSession struct { + Contract *AutomationRegistrarCaller + CallOpts bind.CallOpts +} + +type AutomationRegistrarTransactorSession struct { + Contract *AutomationRegistrarTransactor + TransactOpts bind.TransactOpts +} + +type AutomationRegistrarRaw struct { + Contract *AutomationRegistrar +} + +type AutomationRegistrarCallerRaw struct { + Contract *AutomationRegistrarCaller +} + +type AutomationRegistrarTransactorRaw struct { + Contract *AutomationRegistrarTransactor +} + +func NewAutomationRegistrar(address common.Address, backend bind.ContractBackend) (*AutomationRegistrar, error) { + abi, err := abi.JSON(strings.NewReader(AutomationRegistrarABI)) + if err != nil { + return nil, err + } + contract, err := bindAutomationRegistrar(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &AutomationRegistrar{address: address, abi: abi, AutomationRegistrarCaller: AutomationRegistrarCaller{contract: contract}, AutomationRegistrarTransactor: AutomationRegistrarTransactor{contract: contract}, AutomationRegistrarFilterer: AutomationRegistrarFilterer{contract: contract}}, nil +} + +func NewAutomationRegistrarCaller(address common.Address, caller bind.ContractCaller) (*AutomationRegistrarCaller, error) { + contract, err := bindAutomationRegistrar(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &AutomationRegistrarCaller{contract: contract}, nil +} + +func NewAutomationRegistrarTransactor(address common.Address, transactor bind.ContractTransactor) (*AutomationRegistrarTransactor, error) { + contract, err := bindAutomationRegistrar(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &AutomationRegistrarTransactor{contract: contract}, nil +} + +func NewAutomationRegistrarFilterer(address common.Address, filterer bind.ContractFilterer) (*AutomationRegistrarFilterer, error) { + contract, err := bindAutomationRegistrar(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &AutomationRegistrarFilterer{contract: contract}, nil +} + +func bindAutomationRegistrar(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := AutomationRegistrarMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_AutomationRegistrar *AutomationRegistrarRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _AutomationRegistrar.Contract.AutomationRegistrarCaller.contract.Call(opts, result, method, params...) +} + +func (_AutomationRegistrar *AutomationRegistrarRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.AutomationRegistrarTransactor.contract.Transfer(opts) +} + +func (_AutomationRegistrar *AutomationRegistrarRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.AutomationRegistrarTransactor.contract.Transact(opts, method, params...) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _AutomationRegistrar.Contract.contract.Call(opts, result, method, params...) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.contract.Transfer(opts) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.contract.Transact(opts, method, params...) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) LINK(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _AutomationRegistrar.contract.Call(opts, &out, "LINK") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_AutomationRegistrar *AutomationRegistrarSession) LINK() (common.Address, error) { + return _AutomationRegistrar.Contract.LINK(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) LINK() (common.Address, error) { + return _AutomationRegistrar.Contract.LINK(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) GetAutoApproveAllowedSender(opts *bind.CallOpts, senderAddress common.Address) (bool, error) { + var out []interface{} + err := _AutomationRegistrar.contract.Call(opts, &out, "getAutoApproveAllowedSender", senderAddress) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_AutomationRegistrar *AutomationRegistrarSession) GetAutoApproveAllowedSender(senderAddress common.Address) (bool, error) { + return _AutomationRegistrar.Contract.GetAutoApproveAllowedSender(&_AutomationRegistrar.CallOpts, senderAddress) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) GetAutoApproveAllowedSender(senderAddress common.Address) (bool, error) { + return _AutomationRegistrar.Contract.GetAutoApproveAllowedSender(&_AutomationRegistrar.CallOpts, senderAddress) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) GetConfig(opts *bind.CallOpts) (GetConfig, + + error) { + var out []interface{} + err := _AutomationRegistrar.contract.Call(opts, &out, "getConfig") + + outstruct := new(GetConfig) + if err != nil { + return *outstruct, err + } + + outstruct.KeeperRegistry = *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + outstruct.MinLINKJuels = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_AutomationRegistrar *AutomationRegistrarSession) GetConfig() (GetConfig, + + error) { + return _AutomationRegistrar.Contract.GetConfig(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) GetConfig() (GetConfig, + + error) { + return _AutomationRegistrar.Contract.GetConfig(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) GetPendingRequest(opts *bind.CallOpts, hash [32]byte) (common.Address, *big.Int, error) { + var out []interface{} + err := _AutomationRegistrar.contract.Call(opts, &out, "getPendingRequest", hash) + + if err != nil { + return *new(common.Address), *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + + return out0, out1, err + +} + +func (_AutomationRegistrar *AutomationRegistrarSession) GetPendingRequest(hash [32]byte) (common.Address, *big.Int, error) { + return _AutomationRegistrar.Contract.GetPendingRequest(&_AutomationRegistrar.CallOpts, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) GetPendingRequest(hash [32]byte) (common.Address, *big.Int, error) { + return _AutomationRegistrar.Contract.GetPendingRequest(&_AutomationRegistrar.CallOpts, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) GetTriggerRegistrationDetails(opts *bind.CallOpts, triggerType uint8) (AutomationRegistrar21TriggerRegistrationStorage, error) { + var out []interface{} + err := _AutomationRegistrar.contract.Call(opts, &out, "getTriggerRegistrationDetails", triggerType) + + if err != nil { + return *new(AutomationRegistrar21TriggerRegistrationStorage), err + } + + out0 := *abi.ConvertType(out[0], new(AutomationRegistrar21TriggerRegistrationStorage)).(*AutomationRegistrar21TriggerRegistrationStorage) + + return out0, err + +} + +func (_AutomationRegistrar *AutomationRegistrarSession) GetTriggerRegistrationDetails(triggerType uint8) (AutomationRegistrar21TriggerRegistrationStorage, error) { + return _AutomationRegistrar.Contract.GetTriggerRegistrationDetails(&_AutomationRegistrar.CallOpts, triggerType) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) GetTriggerRegistrationDetails(triggerType uint8) (AutomationRegistrar21TriggerRegistrationStorage, error) { + return _AutomationRegistrar.Contract.GetTriggerRegistrationDetails(&_AutomationRegistrar.CallOpts, triggerType) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _AutomationRegistrar.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 (_AutomationRegistrar *AutomationRegistrarSession) Owner() (common.Address, error) { + return _AutomationRegistrar.Contract.Owner(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) Owner() (common.Address, error) { + return _AutomationRegistrar.Contract.Owner(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _AutomationRegistrar.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_AutomationRegistrar *AutomationRegistrarSession) TypeAndVersion() (string, error) { + return _AutomationRegistrar.Contract.TypeAndVersion(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarCallerSession) TypeAndVersion() (string, error) { + return _AutomationRegistrar.Contract.TypeAndVersion(&_AutomationRegistrar.CallOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "acceptOwnership") +} + +func (_AutomationRegistrar *AutomationRegistrarSession) AcceptOwnership() (*types.Transaction, error) { + return _AutomationRegistrar.Contract.AcceptOwnership(&_AutomationRegistrar.TransactOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _AutomationRegistrar.Contract.AcceptOwnership(&_AutomationRegistrar.TransactOpts) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) Approve(opts *bind.TransactOpts, name string, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, hash [32]byte) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "approve", name, upkeepContract, gasLimit, adminAddress, triggerType, checkData, triggerConfig, offchainConfig, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) Approve(name string, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, hash [32]byte) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.Approve(&_AutomationRegistrar.TransactOpts, name, upkeepContract, gasLimit, adminAddress, triggerType, checkData, triggerConfig, offchainConfig, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) Approve(name string, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, hash [32]byte) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.Approve(&_AutomationRegistrar.TransactOpts, name, upkeepContract, gasLimit, adminAddress, triggerType, checkData, triggerConfig, offchainConfig, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) Cancel(opts *bind.TransactOpts, hash [32]byte) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "cancel", hash) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) Cancel(hash [32]byte) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.Cancel(&_AutomationRegistrar.TransactOpts, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) Cancel(hash [32]byte) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.Cancel(&_AutomationRegistrar.TransactOpts, hash) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) OnTokenTransfer(opts *bind.TransactOpts, sender common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "onTokenTransfer", sender, amount, data) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) OnTokenTransfer(sender common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.OnTokenTransfer(&_AutomationRegistrar.TransactOpts, sender, amount, data) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) OnTokenTransfer(sender common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.OnTokenTransfer(&_AutomationRegistrar.TransactOpts, sender, amount, data) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) Register(opts *bind.TransactOpts, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, amount *big.Int, sender common.Address) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "register", name, encryptedEmail, upkeepContract, gasLimit, adminAddress, triggerType, checkData, triggerConfig, offchainConfig, amount, sender) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) Register(name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, amount *big.Int, sender common.Address) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.Register(&_AutomationRegistrar.TransactOpts, name, encryptedEmail, upkeepContract, gasLimit, adminAddress, triggerType, checkData, triggerConfig, offchainConfig, amount, sender) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) Register(name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, amount *big.Int, sender common.Address) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.Register(&_AutomationRegistrar.TransactOpts, name, encryptedEmail, upkeepContract, gasLimit, adminAddress, triggerType, checkData, triggerConfig, offchainConfig, amount, sender) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) RegisterUpkeep(opts *bind.TransactOpts, requestParams AutomationRegistrar21RegistrationParams) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "registerUpkeep", requestParams) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) RegisterUpkeep(requestParams AutomationRegistrar21RegistrationParams) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.RegisterUpkeep(&_AutomationRegistrar.TransactOpts, requestParams) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) RegisterUpkeep(requestParams AutomationRegistrar21RegistrationParams) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.RegisterUpkeep(&_AutomationRegistrar.TransactOpts, requestParams) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) SetAutoApproveAllowedSender(opts *bind.TransactOpts, senderAddress common.Address, allowed bool) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "setAutoApproveAllowedSender", senderAddress, allowed) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) SetAutoApproveAllowedSender(senderAddress common.Address, allowed bool) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.SetAutoApproveAllowedSender(&_AutomationRegistrar.TransactOpts, senderAddress, allowed) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) SetAutoApproveAllowedSender(senderAddress common.Address, allowed bool) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.SetAutoApproveAllowedSender(&_AutomationRegistrar.TransactOpts, senderAddress, allowed) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) SetConfig(opts *bind.TransactOpts, keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "setConfig", keeperRegistry, minLINKJuels) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) SetConfig(keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.SetConfig(&_AutomationRegistrar.TransactOpts, keeperRegistry, minLINKJuels) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) SetConfig(keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.SetConfig(&_AutomationRegistrar.TransactOpts, keeperRegistry, minLINKJuels) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) SetTriggerConfig(opts *bind.TransactOpts, triggerType uint8, autoApproveType uint8, autoApproveMaxAllowed uint32) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "setTriggerConfig", triggerType, autoApproveType, autoApproveMaxAllowed) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) SetTriggerConfig(triggerType uint8, autoApproveType uint8, autoApproveMaxAllowed uint32) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.SetTriggerConfig(&_AutomationRegistrar.TransactOpts, triggerType, autoApproveType, autoApproveMaxAllowed) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) SetTriggerConfig(triggerType uint8, autoApproveType uint8, autoApproveMaxAllowed uint32) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.SetTriggerConfig(&_AutomationRegistrar.TransactOpts, triggerType, autoApproveType, autoApproveMaxAllowed) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _AutomationRegistrar.contract.Transact(opts, "transferOwnership", to) +} + +func (_AutomationRegistrar *AutomationRegistrarSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.TransferOwnership(&_AutomationRegistrar.TransactOpts, to) +} + +func (_AutomationRegistrar *AutomationRegistrarTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _AutomationRegistrar.Contract.TransferOwnership(&_AutomationRegistrar.TransactOpts, to) +} + +type AutomationRegistrarAutoApproveAllowedSenderSetIterator struct { + Event *AutomationRegistrarAutoApproveAllowedSenderSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarAutoApproveAllowedSenderSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarAutoApproveAllowedSenderSet) + 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(AutomationRegistrarAutoApproveAllowedSenderSet) + 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 *AutomationRegistrarAutoApproveAllowedSenderSetIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarAutoApproveAllowedSenderSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarAutoApproveAllowedSenderSet struct { + SenderAddress common.Address + Allowed bool + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterAutoApproveAllowedSenderSet(opts *bind.FilterOpts, senderAddress []common.Address) (*AutomationRegistrarAutoApproveAllowedSenderSetIterator, error) { + + var senderAddressRule []interface{} + for _, senderAddressItem := range senderAddress { + senderAddressRule = append(senderAddressRule, senderAddressItem) + } + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "AutoApproveAllowedSenderSet", senderAddressRule) + if err != nil { + return nil, err + } + return &AutomationRegistrarAutoApproveAllowedSenderSetIterator{contract: _AutomationRegistrar.contract, event: "AutoApproveAllowedSenderSet", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchAutoApproveAllowedSenderSet(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarAutoApproveAllowedSenderSet, senderAddress []common.Address) (event.Subscription, error) { + + var senderAddressRule []interface{} + for _, senderAddressItem := range senderAddress { + senderAddressRule = append(senderAddressRule, senderAddressItem) + } + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "AutoApproveAllowedSenderSet", senderAddressRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarAutoApproveAllowedSenderSet) + if err := _AutomationRegistrar.contract.UnpackLog(event, "AutoApproveAllowedSenderSet", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseAutoApproveAllowedSenderSet(log types.Log) (*AutomationRegistrarAutoApproveAllowedSenderSet, error) { + event := new(AutomationRegistrarAutoApproveAllowedSenderSet) + if err := _AutomationRegistrar.contract.UnpackLog(event, "AutoApproveAllowedSenderSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarConfigChangedIterator struct { + Event *AutomationRegistrarConfigChanged + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarConfigChangedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarConfigChanged) + 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(AutomationRegistrarConfigChanged) + 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 *AutomationRegistrarConfigChangedIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarConfigChangedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarConfigChanged struct { + KeeperRegistry common.Address + MinLINKJuels *big.Int + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*AutomationRegistrarConfigChangedIterator, error) { + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "ConfigChanged") + if err != nil { + return nil, err + } + return &AutomationRegistrarConfigChangedIterator{contract: _AutomationRegistrar.contract, event: "ConfigChanged", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarConfigChanged) (event.Subscription, error) { + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "ConfigChanged") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarConfigChanged) + if err := _AutomationRegistrar.contract.UnpackLog(event, "ConfigChanged", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseConfigChanged(log types.Log) (*AutomationRegistrarConfigChanged, error) { + event := new(AutomationRegistrarConfigChanged) + if err := _AutomationRegistrar.contract.UnpackLog(event, "ConfigChanged", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarOwnershipTransferRequestedIterator struct { + Event *AutomationRegistrarOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarOwnershipTransferRequested) + 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(AutomationRegistrarOwnershipTransferRequested) + 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 *AutomationRegistrarOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*AutomationRegistrarOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &AutomationRegistrarOwnershipTransferRequestedIterator{contract: _AutomationRegistrar.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarOwnershipTransferRequested) + if err := _AutomationRegistrar.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseOwnershipTransferRequested(log types.Log) (*AutomationRegistrarOwnershipTransferRequested, error) { + event := new(AutomationRegistrarOwnershipTransferRequested) + if err := _AutomationRegistrar.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarOwnershipTransferredIterator struct { + Event *AutomationRegistrarOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarOwnershipTransferred) + 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(AutomationRegistrarOwnershipTransferred) + 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 *AutomationRegistrarOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*AutomationRegistrarOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &AutomationRegistrarOwnershipTransferredIterator{contract: _AutomationRegistrar.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarOwnershipTransferred) + if err := _AutomationRegistrar.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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseOwnershipTransferred(log types.Log) (*AutomationRegistrarOwnershipTransferred, error) { + event := new(AutomationRegistrarOwnershipTransferred) + if err := _AutomationRegistrar.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarRegistrationApprovedIterator struct { + Event *AutomationRegistrarRegistrationApproved + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarRegistrationApprovedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarRegistrationApproved) + 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(AutomationRegistrarRegistrationApproved) + 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 *AutomationRegistrarRegistrationApprovedIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarRegistrationApprovedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarRegistrationApproved struct { + Hash [32]byte + DisplayName string + UpkeepId *big.Int + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterRegistrationApproved(opts *bind.FilterOpts, hash [][32]byte, upkeepId []*big.Int) (*AutomationRegistrarRegistrationApprovedIterator, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "RegistrationApproved", hashRule, upkeepIdRule) + if err != nil { + return nil, err + } + return &AutomationRegistrarRegistrationApprovedIterator{contract: _AutomationRegistrar.contract, event: "RegistrationApproved", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchRegistrationApproved(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarRegistrationApproved, hash [][32]byte, upkeepId []*big.Int) (event.Subscription, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "RegistrationApproved", hashRule, upkeepIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarRegistrationApproved) + if err := _AutomationRegistrar.contract.UnpackLog(event, "RegistrationApproved", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseRegistrationApproved(log types.Log) (*AutomationRegistrarRegistrationApproved, error) { + event := new(AutomationRegistrarRegistrationApproved) + if err := _AutomationRegistrar.contract.UnpackLog(event, "RegistrationApproved", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarRegistrationRejectedIterator struct { + Event *AutomationRegistrarRegistrationRejected + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarRegistrationRejectedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarRegistrationRejected) + 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(AutomationRegistrarRegistrationRejected) + 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 *AutomationRegistrarRegistrationRejectedIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarRegistrationRejectedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarRegistrationRejected struct { + Hash [32]byte + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterRegistrationRejected(opts *bind.FilterOpts, hash [][32]byte) (*AutomationRegistrarRegistrationRejectedIterator, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "RegistrationRejected", hashRule) + if err != nil { + return nil, err + } + return &AutomationRegistrarRegistrationRejectedIterator{contract: _AutomationRegistrar.contract, event: "RegistrationRejected", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchRegistrationRejected(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarRegistrationRejected, hash [][32]byte) (event.Subscription, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "RegistrationRejected", hashRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarRegistrationRejected) + if err := _AutomationRegistrar.contract.UnpackLog(event, "RegistrationRejected", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseRegistrationRejected(log types.Log) (*AutomationRegistrarRegistrationRejected, error) { + event := new(AutomationRegistrarRegistrationRejected) + if err := _AutomationRegistrar.contract.UnpackLog(event, "RegistrationRejected", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarRegistrationRequestedIterator struct { + Event *AutomationRegistrarRegistrationRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarRegistrationRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarRegistrationRequested) + 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(AutomationRegistrarRegistrationRequested) + 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 *AutomationRegistrarRegistrationRequestedIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarRegistrationRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarRegistrationRequested struct { + Hash [32]byte + Name string + EncryptedEmail []byte + UpkeepContract common.Address + GasLimit uint32 + AdminAddress common.Address + TriggerType uint8 + TriggerConfig []byte + OffchainConfig []byte + CheckData []byte + Amount *big.Int + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterRegistrationRequested(opts *bind.FilterOpts, hash [][32]byte, upkeepContract []common.Address) (*AutomationRegistrarRegistrationRequestedIterator, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepContractRule []interface{} + for _, upkeepContractItem := range upkeepContract { + upkeepContractRule = append(upkeepContractRule, upkeepContractItem) + } + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "RegistrationRequested", hashRule, upkeepContractRule) + if err != nil { + return nil, err + } + return &AutomationRegistrarRegistrationRequestedIterator{contract: _AutomationRegistrar.contract, event: "RegistrationRequested", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchRegistrationRequested(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarRegistrationRequested, hash [][32]byte, upkeepContract []common.Address) (event.Subscription, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepContractRule []interface{} + for _, upkeepContractItem := range upkeepContract { + upkeepContractRule = append(upkeepContractRule, upkeepContractItem) + } + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "RegistrationRequested", hashRule, upkeepContractRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarRegistrationRequested) + if err := _AutomationRegistrar.contract.UnpackLog(event, "RegistrationRequested", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseRegistrationRequested(log types.Log) (*AutomationRegistrarRegistrationRequested, error) { + event := new(AutomationRegistrarRegistrationRequested) + if err := _AutomationRegistrar.contract.UnpackLog(event, "RegistrationRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type AutomationRegistrarTriggerConfigSetIterator struct { + Event *AutomationRegistrarTriggerConfigSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *AutomationRegistrarTriggerConfigSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(AutomationRegistrarTriggerConfigSet) + 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(AutomationRegistrarTriggerConfigSet) + 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 *AutomationRegistrarTriggerConfigSetIterator) Error() error { + return it.fail +} + +func (it *AutomationRegistrarTriggerConfigSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type AutomationRegistrarTriggerConfigSet struct { + TriggerType uint8 + AutoApproveType uint8 + AutoApproveMaxAllowed uint32 + Raw types.Log +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) FilterTriggerConfigSet(opts *bind.FilterOpts) (*AutomationRegistrarTriggerConfigSetIterator, error) { + + logs, sub, err := _AutomationRegistrar.contract.FilterLogs(opts, "TriggerConfigSet") + if err != nil { + return nil, err + } + return &AutomationRegistrarTriggerConfigSetIterator{contract: _AutomationRegistrar.contract, event: "TriggerConfigSet", logs: logs, sub: sub}, nil +} + +func (_AutomationRegistrar *AutomationRegistrarFilterer) WatchTriggerConfigSet(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarTriggerConfigSet) (event.Subscription, error) { + + logs, sub, err := _AutomationRegistrar.contract.WatchLogs(opts, "TriggerConfigSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(AutomationRegistrarTriggerConfigSet) + if err := _AutomationRegistrar.contract.UnpackLog(event, "TriggerConfigSet", 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 (_AutomationRegistrar *AutomationRegistrarFilterer) ParseTriggerConfigSet(log types.Log) (*AutomationRegistrarTriggerConfigSet, error) { + event := new(AutomationRegistrarTriggerConfigSet) + if err := _AutomationRegistrar.contract.UnpackLog(event, "TriggerConfigSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type GetConfig struct { + KeeperRegistry common.Address + MinLINKJuels *big.Int +} + +func (_AutomationRegistrar *AutomationRegistrar) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _AutomationRegistrar.abi.Events["AutoApproveAllowedSenderSet"].ID: + return _AutomationRegistrar.ParseAutoApproveAllowedSenderSet(log) + case _AutomationRegistrar.abi.Events["ConfigChanged"].ID: + return _AutomationRegistrar.ParseConfigChanged(log) + case _AutomationRegistrar.abi.Events["OwnershipTransferRequested"].ID: + return _AutomationRegistrar.ParseOwnershipTransferRequested(log) + case _AutomationRegistrar.abi.Events["OwnershipTransferred"].ID: + return _AutomationRegistrar.ParseOwnershipTransferred(log) + case _AutomationRegistrar.abi.Events["RegistrationApproved"].ID: + return _AutomationRegistrar.ParseRegistrationApproved(log) + case _AutomationRegistrar.abi.Events["RegistrationRejected"].ID: + return _AutomationRegistrar.ParseRegistrationRejected(log) + case _AutomationRegistrar.abi.Events["RegistrationRequested"].ID: + return _AutomationRegistrar.ParseRegistrationRequested(log) + case _AutomationRegistrar.abi.Events["TriggerConfigSet"].ID: + return _AutomationRegistrar.ParseTriggerConfigSet(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (AutomationRegistrarAutoApproveAllowedSenderSet) Topic() common.Hash { + return common.HexToHash("0x20c6237dac83526a849285a9f79d08a483291bdd3a056a0ef9ae94ecee1ad356") +} + +func (AutomationRegistrarConfigChanged) Topic() common.Hash { + return common.HexToHash("0x39ce5d867555f0b0183e358fce5b158e7ca4fecd7c01cb7e0e19f1e23285838a") +} + +func (AutomationRegistrarOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (AutomationRegistrarOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (AutomationRegistrarRegistrationApproved) Topic() common.Hash { + return common.HexToHash("0xb9a292fb7e3edd920cd2d2829a3615a640c43fd7de0a0820aa0668feb4c37d4b") +} + +func (AutomationRegistrarRegistrationRejected) Topic() common.Hash { + return common.HexToHash("0x3663fb28ebc87645eb972c9dad8521bf665c623f287e79f1c56f1eb374b82a22") +} + +func (AutomationRegistrarRegistrationRequested) Topic() common.Hash { + return common.HexToHash("0x7684390ebb103102f7f48c71439c2408713f8d437782a6fab2756acc0e42c1b7") +} + +func (AutomationRegistrarTriggerConfigSet) Topic() common.Hash { + return common.HexToHash("0x830a6d06a4e2caac67eba04323de22bdb04f032dd8b3d6a0c52b503d9a7036a3") +} + +func (_AutomationRegistrar *AutomationRegistrar) Address() common.Address { + return _AutomationRegistrar.address +} + +type AutomationRegistrarInterface interface { + LINK(opts *bind.CallOpts) (common.Address, error) + + GetAutoApproveAllowedSender(opts *bind.CallOpts, senderAddress common.Address) (bool, error) + + GetConfig(opts *bind.CallOpts) (GetConfig, + + error) + + GetPendingRequest(opts *bind.CallOpts, hash [32]byte) (common.Address, *big.Int, error) + + GetTriggerRegistrationDetails(opts *bind.CallOpts, triggerType uint8) (AutomationRegistrar21TriggerRegistrationStorage, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + Approve(opts *bind.TransactOpts, name string, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, hash [32]byte) (*types.Transaction, error) + + Cancel(opts *bind.TransactOpts, hash [32]byte) (*types.Transaction, error) + + OnTokenTransfer(opts *bind.TransactOpts, sender common.Address, amount *big.Int, data []byte) (*types.Transaction, error) + + Register(opts *bind.TransactOpts, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, triggerType uint8, checkData []byte, triggerConfig []byte, offchainConfig []byte, amount *big.Int, sender common.Address) (*types.Transaction, error) + + RegisterUpkeep(opts *bind.TransactOpts, requestParams AutomationRegistrar21RegistrationParams) (*types.Transaction, error) + + SetAutoApproveAllowedSender(opts *bind.TransactOpts, senderAddress common.Address, allowed bool) (*types.Transaction, error) + + SetConfig(opts *bind.TransactOpts, keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) + + SetTriggerConfig(opts *bind.TransactOpts, triggerType uint8, autoApproveType uint8, autoApproveMaxAllowed uint32) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + FilterAutoApproveAllowedSenderSet(opts *bind.FilterOpts, senderAddress []common.Address) (*AutomationRegistrarAutoApproveAllowedSenderSetIterator, error) + + WatchAutoApproveAllowedSenderSet(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarAutoApproveAllowedSenderSet, senderAddress []common.Address) (event.Subscription, error) + + ParseAutoApproveAllowedSenderSet(log types.Log) (*AutomationRegistrarAutoApproveAllowedSenderSet, error) + + FilterConfigChanged(opts *bind.FilterOpts) (*AutomationRegistrarConfigChangedIterator, error) + + WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarConfigChanged) (event.Subscription, error) + + ParseConfigChanged(log types.Log) (*AutomationRegistrarConfigChanged, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*AutomationRegistrarOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*AutomationRegistrarOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*AutomationRegistrarOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*AutomationRegistrarOwnershipTransferred, error) + + FilterRegistrationApproved(opts *bind.FilterOpts, hash [][32]byte, upkeepId []*big.Int) (*AutomationRegistrarRegistrationApprovedIterator, error) + + WatchRegistrationApproved(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarRegistrationApproved, hash [][32]byte, upkeepId []*big.Int) (event.Subscription, error) + + ParseRegistrationApproved(log types.Log) (*AutomationRegistrarRegistrationApproved, error) + + FilterRegistrationRejected(opts *bind.FilterOpts, hash [][32]byte) (*AutomationRegistrarRegistrationRejectedIterator, error) + + WatchRegistrationRejected(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarRegistrationRejected, hash [][32]byte) (event.Subscription, error) + + ParseRegistrationRejected(log types.Log) (*AutomationRegistrarRegistrationRejected, error) + + FilterRegistrationRequested(opts *bind.FilterOpts, hash [][32]byte, upkeepContract []common.Address) (*AutomationRegistrarRegistrationRequestedIterator, error) + + WatchRegistrationRequested(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarRegistrationRequested, hash [][32]byte, upkeepContract []common.Address) (event.Subscription, error) + + ParseRegistrationRequested(log types.Log) (*AutomationRegistrarRegistrationRequested, error) + + FilterTriggerConfigSet(opts *bind.FilterOpts) (*AutomationRegistrarTriggerConfigSetIterator, error) + + WatchTriggerConfigSet(opts *bind.WatchOpts, sink chan<- *AutomationRegistrarTriggerConfigSet) (event.Subscription, error) + + ParseTriggerConfigSet(log types.Log) (*AutomationRegistrarTriggerConfigSet, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 09a68174bee..677f48e66a0 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -5,6 +5,7 @@ authorized_forwarder: ../../contracts/solc/v0.7/AuthorizedForwarder.abi ../../co authorized_receiver: ../../contracts/solc/v0.7/AuthorizedReceiver.abi ../../contracts/solc/v0.7/AuthorizedReceiver.bin 18e8969ba3234b027e1b16c11a783aca58d0ea5c2361010ec597f134b7bf1c4f automation_consumer_benchmark: ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.abi ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.bin f52c76f1aaed4be541d82d97189d70f5aa027fc9838037dd7a7d21910c8c488e automation_forwarder_logic: ../../contracts/solc/v0.8.16/AutomationForwarderLogic.abi ../../contracts/solc/v0.8.16/AutomationForwarderLogic.bin 15ae0c367297955fdab4b552dbb10e1f2be80a8fde0efec4a4d398693e9d72b5 +automation_registrar_wrapper2_1: ../../contracts/solc/v0.8.16/AutomationRegistrar2_1.abi ../../contracts/solc/v0.8.16/AutomationRegistrar2_1.bin eb06d853aab39d3196c593b03e555851cbe8386e0fe54a74c2479f62d14b3c42 automation_utils_2_1: ../../contracts/solc/v0.8.16/AutomationUtils2_1.abi ../../contracts/solc/v0.8.16/AutomationUtils2_1.bin 0b3006a2a1588916d22bf1ae5429bd3bce24a58904588d5ed3fe1026d64616cf batch_blockhash_store: ../../contracts/solc/v0.8.6/BatchBlockhashStore.abi ../../contracts/solc/v0.8.6/BatchBlockhashStore.bin c5ab26709a01050402615659403f32d5cd1b85f3ad6bb6bfe021692f4233cf19 batch_vrf_coordinator_v2: ../../contracts/solc/v0.8.6/BatchVRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/BatchVRFCoordinatorV2.bin d0a54963260d8c1f1bbd984b758285e6027cfb5a7e42701bcb562ab123219332 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 5700c939a78..7bc31195e14 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -49,6 +49,7 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.15/MercuryUpkeep.abi ../../contracts/solc/v0.8.15/MercuryUpkeep.bin MercuryUpkeep mercury_upkeep_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.bin FeedLookupCompatibleInterface feed_lookup_compatible_interface //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.abi ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.bin AutomationConsumerBenchmark automation_consumer_benchmark +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationRegistrar2_1.abi ../../contracts/solc/v0.8.16/AutomationRegistrar2_1.bin AutomationRegistrar automation_registrar_wrapper2_1 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin KeeperRegistry keeper_registry_wrapper_2_1 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin KeeperRegistryLogicA keeper_registry_logic_a_wrapper_2_1 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin KeeperRegistryLogicB keeper_registry_logic_b_wrapper_2_1 From 65005b81add2e43713135387b0c933e5ab3903c0 Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Thu, 27 Jul 2023 23:11:06 +0300 Subject: [PATCH 019/270] Integrate ocr2keepers 0.7.2 (#9949) * update ocr2keepers@v0.7.2 * upkeep state: use state from ocr2keepers * added empty interfaces for ocr2keepers * added upkeepTriggerID in encoder * go mod tidy * remove redundant struct * lint * upkeep provider * fix nil pointer and add test --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- .../ocr2/plugins/ocr2keeper/evm21/abi_test.go | 2 +- .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 3 + .../ocr2keeper/evm21/logprovider/provider.go | 9 ++ .../ocr2keeper/evm21/logprovider/recoverer.go | 102 ++++++++++++++++++ .../evm21/logprovider/recoverer_test.go | 55 ++++++++++ .../ocr2/plugins/ocr2keeper/evm21/registry.go | 8 ++ .../ocr2keeper/evm21/upkeep_provider.go | 49 +++++++++ .../ocr2keeper/evm21/upkeep_provider_test.go | 88 +++++++++++++++ .../ocr2keeper/evm21/upkeep_state_store.go | 20 ++-- .../evm21/upkeep_state_store_test.go | 12 +-- go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 16 files changed, 336 insertions(+), 30 deletions(-) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 7a5b2b4bbd8..ce41a83f334 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v0.7.1 + github.com/smartcontractkit/ocr2keepers v0.7.2 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index d074e851ccc..1b2acc16078 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1439,8 +1439,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202306 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d/go.mod h1:AW1rNDx4YN0VJzM1OrZtsOV9ORdcqcSFtsOQO3GeOQo= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.1 h1:10+i/DKhrSjvyrZ/+MVUiLOunWJbr3ehKYP+jXfCRuk= -github.com/smartcontractkit/ocr2keepers v0.7.1/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= +github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= +github.com/smartcontractkit/ocr2keepers v0.7.2/go.mod h1:2cQpoTO4SL0JYKabW2bSzbN5i86ZH9G1O/75EsXlj3o= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go index f2a3fa32b72..aa9d8247f5d 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go @@ -9,11 +9,11 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" "github.com/stretchr/testify/assert" automation21Utils "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" ) func TestUnpackCheckResults(t *testing.T) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index cc60bbd4d07..559b51c3f7c 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -133,12 +133,15 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk common.BytesToHash(triggerW.BlockHash[:]).Hex(), logExt, ) + triggerID, _ := UpkeepTriggerID(upkeepId, report.Triggers[i]) reportedUpkeeps[i] = ocr2keepers.ReportedUpkeep{ + ID: triggerID, UpkeepID: ocr2keepers.UpkeepIdentifier(upkeepId.String()), Trigger: trigger, PerformData: report.PerformDatas[i], } } + return reportedUpkeeps, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 38725fc767f..c924a666f14 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -11,6 +11,7 @@ import ( "time" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" "go.uber.org/multierr" "golang.org/x/time/rate" @@ -61,6 +62,9 @@ type LogEventProviderTest interface { ReadLogs(ctx context.Context, force bool, ids ...*big.Int) error } +var _ keepersflows.PayloadBuilder = &logEventProvider{} +var _ keepersflows.LogEventProvider = &logEventProvider{} + // logEventProvider manages log filters for upkeeps and enables to read the log events. type logEventProvider struct { lggr logger.Logger @@ -130,6 +134,11 @@ func (p *logEventProvider) Close() error { return nil } +func (p *logEventProvider) BuildPayload(ctx context.Context, proposal ocr2keepers.CoordinatedProposal) (ocr2keepers.UpkeepPayload, error) { + // TODO: implement + return ocr2keepers.UpkeepPayload{}, nil +} + func (p *logEventProvider) GetLogs(context.Context) ([]ocr2keepers.UpkeepPayload, error) { latest := p.buffer.latestBlockSeen() diff := latest - p.opts.LogBlocksLookback diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go new file mode 100644 index 00000000000..41f394af63f --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go @@ -0,0 +1,102 @@ +package logprovider + +import ( + "context" + "errors" + "sync" + "time" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/logger" +) + +var ( + ErrNotFound = errors.New("not found") +) + +type logRecoverer struct { + lggr logger.Logger + + cancel context.CancelFunc + + interval time.Duration + lock *sync.RWMutex + + pending []ocr2keepers.UpkeepPayload + visited map[string]bool + + poller logpoller.LogPoller +} + +var _ keepersflows.RecoverableProvider = &logRecoverer{} + +func NewLogRecoverer(lggr logger.Logger, poller logpoller.LogPoller, interval time.Duration) *logRecoverer { + if interval == 0 { + interval = 30 * time.Second + } + return &logRecoverer{ + lggr: lggr.Named("LogRecoverer"), + interval: interval, + lock: &sync.RWMutex{}, + pending: make([]ocr2keepers.UpkeepPayload, 0), + visited: make(map[string]bool), + poller: poller, + } +} + +func (r *logRecoverer) Start(pctx context.Context) error { + ctx, cancel := context.WithCancel(pctx) + r.lock.Lock() + r.cancel = cancel + interval := r.interval + r.lock.Unlock() + + ticker := time.NewTicker(interval) + defer ticker.Stop() + + r.lggr.Debug("Starting log recoverer") + + for { + select { + case <-ticker.C: + r.recover(ctx) + case <-ctx.Done(): + return nil + } + } +} + +func (r *logRecoverer) Close() error { + r.lock.Lock() + defer r.lock.Unlock() + + if r.cancel != nil { + r.cancel() + } + return nil +} + +func (r *logRecoverer) GetRecoverables() ([]ocr2keepers.UpkeepPayload, error) { + r.lock.Lock() + defer r.lock.Unlock() + + if len(r.pending) == 0 { + return nil, nil + } + + pending := r.pending + r.pending = make([]ocr2keepers.UpkeepPayload, 0) + + for _, p := range pending { + r.visited[p.ID] = true + } + + return pending, nil +} + +func (r *logRecoverer) recover(ctx context.Context) { + // TODO: implement +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go new file mode 100644 index 00000000000..5b1a1ac29f0 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go @@ -0,0 +1,55 @@ +package logprovider + +import ( + "testing" + "time" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/chainlink/v2/core/logger" +) + +func TestLogRecoverer_GetRecoverables(t *testing.T) { + r := NewLogRecoverer(logger.TestLogger(t), nil, time.Millisecond*10) + + tests := []struct { + name string + pending []ocr2keepers.UpkeepPayload + want []ocr2keepers.UpkeepPayload + wantErr bool + }{ + { + "empty", + []ocr2keepers.UpkeepPayload{}, + []ocr2keepers.UpkeepPayload{}, + false, + }, + { + "happy flow", + []ocr2keepers.UpkeepPayload{ + {ID: "1"}, {ID: "2"}, + }, + []ocr2keepers.UpkeepPayload{ + {ID: "1"}, {ID: "2"}, + }, + false, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + r.lock.Lock() + r.pending = tc.pending + r.lock.Unlock() + + got, err := r.GetRecoverables() + if tc.wantErr { + require.Error(t, err) + } else { + require.NoError(t, err) + } + require.Len(t, got, len(tc.want)) + }) + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 7c096cbbaa7..f910507612c 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -906,3 +906,11 @@ func (r *EvmRegistry) fetchTriggerConfig(id *big.Int) ([]byte, error) { } return cfg, nil } + +func (r *EvmRegistry) getBlockHash(blockNumber *big.Int) (common.Hash, error) { + block, err := r.client.BlockByNumber(r.ctx, blockNumber) + if err != nil { + return [32]byte{}, fmt.Errorf("%w: failed to get latest block", ErrHeadNotAvailable) + } + return block.Hash(), nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go new file mode 100644 index 00000000000..fb1917b0989 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go @@ -0,0 +1,49 @@ +package evm + +import ( + "context" + "math/big" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" +) + +var _ keepersflows.UpkeepProvider = &upkeepProvider{} + +type upkeepProvider struct { + reg *EvmRegistry +} + +func NewUpkeepProvider(reg *EvmRegistry) *upkeepProvider { + return &upkeepProvider{ + reg: reg, + } +} + +func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context, blockKey ocr2keepers.BlockKey) ([]ocr2keepers.UpkeepPayload, error) { + ids, err := p.reg.GetActiveUpkeepIDsByType(ctx, uint8(conditionTrigger)) + if err != nil { + return nil, err + } + block, ok := big.NewInt(0).SetString(string(blockKey), 10) + if !ok { + return nil, ocr2keepers.ErrInvalidBlockKey + } + blockHash, err := p.reg.getBlockHash(block) + if err != nil { + return nil, err + } + + var payloads []ocr2keepers.UpkeepPayload + for _, uid := range ids { + payloads = append(payloads, ocr2keepers.NewUpkeepPayload( + big.NewInt(0).SetBytes(uid), + int(conditionTrigger), + blockKey, + ocr2keepers.NewTrigger(block.Int64(), blockHash.Hex(), struct{}{}), + nil, + )) + } + + return payloads, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go new file mode 100644 index 00000000000..fd7df12cb64 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go @@ -0,0 +1,88 @@ +package evm + +import ( + "math/big" + "sync" + "testing" + + coreTypes "github.com/ethereum/go-ethereum/core/types" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" + + clientmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" +) + +func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { + ctx := testutils.Context(t) + c := new(clientmocks.Client) + + r := &EvmRegistry{ + mu: sync.RWMutex{}, + active: map[string]activeUpkeep{}, + client: c, + } + + p := NewUpkeepProvider(r) + + tests := []struct { + name string + active map[string]activeUpkeep + blockHeader coreTypes.Header + want []ocr2keepers.UpkeepPayload + wantErr bool + }{ + { + "empty", + map[string]activeUpkeep{}, + coreTypes.Header{Number: big.NewInt(0)}, + nil, + false, + }, + { + "happy flow", + map[string]activeUpkeep{ + "1": { + ID: big.NewInt(1), + }, + "2": { + ID: big.NewInt(2), + }, + }, + coreTypes.Header{Number: big.NewInt(1)}, + []ocr2keepers.UpkeepPayload{ + { + ID: "edc5ec5f1d41b338a9ba6902caa8620a992fd086dcb978a6baa11a08e2e2795f", + Trigger: ocr2keepers.Trigger{BlockNumber: 1, BlockHash: "0xc3bd2d00745c03048a5616146a96f5ff78e54efb9e5b04af208cdaff6f3830ee"}, + }, { + ID: "351362d44977dba636dd8b7429255db2e7b90a93ebddcb5f0f93cd81995ea887", + Trigger: ocr2keepers.Trigger{BlockNumber: 1, BlockHash: "0xc3bd2d00745c03048a5616146a96f5ff78e54efb9e5b04af208cdaff6f3830ee"}, + }, + }, + false, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + b := coreTypes.NewBlockWithHeader(&tc.blockHeader) + c.On("BlockByNumber", mock.Anything, mock.Anything).Return(b, nil) + + r.mu.Lock() + r.active = tc.active + r.mu.Unlock() + + got, err := p.GetActiveUpkeeps(ctx, BlockKeyHelper[int64]{}.MakeBlockKey(b.Number().Int64())) + require.NoError(t, err) + require.Len(t, got, len(tc.want)) + + for i, payload := range got { + expected := tc.want[i] + require.Equal(t, expected.ID, payload.ID) + require.Equal(t, expected.Trigger.BlockNumber, payload.Trigger.BlockNumber) + require.Equal(t, expected.Trigger.BlockHash, payload.Trigger.BlockHash) + } + }) + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go index f67a91759d7..009cb26c5fd 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go @@ -18,26 +18,18 @@ const BlockKeySeparator = "|" type upkeepState struct { payload *ocr2keepers.UpkeepPayload - state *UpkeepState + state *ocr2keepers.UpkeepState block int64 upkeepId string } -// TODO: use the same type defined in keeper plugin after a new release is cut -type UpkeepState uint8 - -const ( - Performed UpkeepState = iota - Eligible -) - type UpkeepStateReader interface { // SelectByUpkeepIDsAndBlockRange retrieves upkeep states for provided upkeep ids and block range, the result is currently not in particular order - SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, start, end int64) ([]*ocr2keepers.UpkeepPayload, []*UpkeepState, error) + SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, start, end int64) ([]*ocr2keepers.UpkeepPayload, []*ocr2keepers.UpkeepState, error) } type UpkeepStateUpdater interface { - SetUpkeepState(ocr2keepers.UpkeepPayload, UpkeepState) error + SetUpkeepState(ocr2keepers.UpkeepPayload, ocr2keepers.UpkeepState) error } type UpkeepStateStore struct { @@ -56,11 +48,11 @@ func NewUpkeepStateStore(lggr logger.Logger) *UpkeepStateStore { } } -func (u *UpkeepStateStore) SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, start, end int64) ([]*ocr2keepers.UpkeepPayload, []*UpkeepState, error) { +func (u *UpkeepStateStore) SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, start, end int64) ([]*ocr2keepers.UpkeepPayload, []*ocr2keepers.UpkeepState, error) { u.mu.RLock() defer u.mu.RUnlock() var pl []*ocr2keepers.UpkeepPayload - var us []*UpkeepState + var us []*ocr2keepers.UpkeepState uids := mapset.NewSet[string]() for _, uid := range upkeepIds { @@ -77,7 +69,7 @@ func (u *UpkeepStateStore) SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, return pl, us, nil } -func (u *UpkeepStateStore) SetUpkeepState(pl ocr2keepers.UpkeepPayload, us UpkeepState) error { +func (u *UpkeepStateStore) SetUpkeepState(pl ocr2keepers.UpkeepPayload, us ocr2keepers.UpkeepState) error { u.mu.Lock() defer u.mu.Unlock() diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go index 5da7bf7d7e6..1c04dc35db5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go @@ -43,7 +43,7 @@ func TestUpkeepStateStore_InvalidBlockKey(t *testing.T) { tests := []struct { name string payloads []ocr2keepers.UpkeepPayload - states []UpkeepState + states []ocr2keepers.UpkeepState expectedError error }{ { @@ -51,7 +51,7 @@ func TestUpkeepStateStore_InvalidBlockKey(t *testing.T) { payloads: []ocr2keepers.UpkeepPayload{ ocr2keepers.NewUpkeepPayload(upkeepId2, logTriggerType, invalidBlockKey, trigger1, []byte{}), }, - states: []UpkeepState{Performed}, + states: []ocr2keepers.UpkeepState{ocr2keepers.Performed}, expectedError: fmt.Errorf("check block %s is invalid for upkeep %s", invalidBlockKey, upkeepId2), }, } @@ -68,13 +68,13 @@ func TestUpkeepStateStore_InvalidBlockKey(t *testing.T) { } func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { - p := Performed - e := Eligible + p := ocr2keepers.Performed + e := ocr2keepers.Eligible tests := []struct { name string payloads []ocr2keepers.UpkeepPayload - states []UpkeepState + states []ocr2keepers.UpkeepState expectedError error oldIds []string oldIdResult []upkeepState @@ -93,7 +93,7 @@ func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { payload4, payload5, // this overrides payload 2 bc they have the same payload ID }, - states: []UpkeepState{Performed, Performed, Performed, Eligible}, + states: []ocr2keepers.UpkeepState{ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Eligible}, oldIds: []string{payload2.ID, payload3.ID, payload4.ID}, oldIdResult: []upkeepState{ { diff --git a/go.mod b/go.mod index f52cb58347f..333a2b2005b 100644 --- a/go.mod +++ b/go.mod @@ -71,7 +71,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v0.7.1 + github.com/smartcontractkit/ocr2keepers v0.7.2 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c diff --git a/go.sum b/go.sum index c92089d9c77..ee241534c5b 100644 --- a/go.sum +++ b/go.sum @@ -1444,8 +1444,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202306 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d/go.mod h1:AW1rNDx4YN0VJzM1OrZtsOV9ORdcqcSFtsOQO3GeOQo= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.1 h1:10+i/DKhrSjvyrZ/+MVUiLOunWJbr3ehKYP+jXfCRuk= -github.com/smartcontractkit/ocr2keepers v0.7.1/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= +github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= +github.com/smartcontractkit/ocr2keepers v0.7.2/go.mod h1:2cQpoTO4SL0JYKabW2bSzbN5i86ZH9G1O/75EsXlj3o= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 8cc6f13cd7a..5ac50f3dc8d 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -21,7 +21,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.14.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v0.7.1 + github.com/smartcontractkit/ocr2keepers v0.7.2 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c github.com/stretchr/testify v1.8.4 github.com/umbracle/ethgo v0.1.3 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 6b55ea7e9d2..10f017cd519 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1373,8 +1373,8 @@ github.com/smartcontractkit/chainlink-testing-framework v1.14.0 h1:XJSE2xnXCij1P github.com/smartcontractkit/chainlink-testing-framework v1.14.0/go.mod h1:Wio/JS9GuEAWOI0k46sUs4+/wLMZnZKz9IwCpdV/miY= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.1 h1:10+i/DKhrSjvyrZ/+MVUiLOunWJbr3ehKYP+jXfCRuk= -github.com/smartcontractkit/ocr2keepers v0.7.1/go.mod h1:13Q6zuYWLByKXzzcSoi7L01bT8OzxM//XgMZQeCZVP0= +github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= +github.com/smartcontractkit/ocr2keepers v0.7.2/go.mod h1:2cQpoTO4SL0JYKabW2bSzbN5i86ZH9G1O/75EsXlj3o= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From 7536173b3417e564c6181b4f8e845808f39f75ea Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Thu, 27 Jul 2023 16:37:21 -0400 Subject: [PATCH 020/270] update VL contracts for 2.1 (#9747) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add an example contract for mercury and log trigger * refactor * refactor * refactor * add a VL contract for log triggered feed lookup upkeep * Change update transmitter balance behaviour (#9624) * Change update transmitter balance behaviour * add test * regen go wrappers and address comments * fix tests * skip coverage for flaky test * remove todo * cleanup merge * regen wrapper * revert ine removal * skip coverage --------- Co-authored-by: FelixFan1992 * Upkeep manager refactor (#9637) * refactor upkeep administrative manager * remove only * fix * fix go build * regen interface * remove only * fix tests * addressed comments * refactor * fix tests * fix error string * fix tests * fix chaincli * Fixes When to Run Live Tests (#9666) * Update AWS action (#9672) * update VL contracts to work with 2.1 (#9673) * update VL contracts to work with 2.1 * fix * Move EVM node pool config (#9656) * Move EVM node pool config * Update after merge * Add test * Update after merge * Cleanup pipeline data references and change back to checkData (#9650) * Cleanup pipeline data references and change back to checkData * fix tests * regen wrappers * regen wrappers * Mercury feeds starts at the first block number not at zero (#9664) * Mercury feeds starts at the first block number not at zero * Update integration test * chainlink-relay => bbcb3a99b7d3a18fe638660c8cfa847b49511dd1 * Update core/services/relay/evm/mercury/data_source.go Co-authored-by: Sergei Drugalev * Fix lint * Fix test --------- Co-authored-by: Sergei Drugalev * [Functions] Allowlist support (#9635) * Update mercury telemetry version (#9676) * [Functions] Mark duplicate request ID log as consumed (#9647) Do it to avoid a flood of repetitive error when LogBroadcaster re-submits the same log in a loop. * Refactoring S4 plugin (#9643) * Functions/S4 integration * Fixed whitespace * Removed integration code * Reduce MAX_PERFORM and MAX_CHECK (#9657) * Properly scope logpoller to feedID for mercury (#9680) * [Functions] Use byte array for secrets in RequestData structure (#9677) Co-authored-by: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> * bump chainlink-env for pod ready improvemeents (#9640) * bump chainlink-env for pod ready improvemeents * bump one more time * function update fix * cleanup checkupkeep and callback (#9651) * cleanup checkupkeep and callback * cleanup * further cleanup * update comment * cleanup * add max revert data size struct * compile * regen wrappers and fix test * fix tests * add test for revert size limit * fix bug * add callback tests * more callback tests * more tests * regen wrappers * fix test * add clarifying comment * fix test * fix chaincli * regen wrappers --------- Co-authored-by: FelixFan1992 * Cleanup TODOs (#9682) * [BCI-1435] Improve EVM Client Readability (#9662) * added type assertion to client * moved chain and client interfaces to common * updated mocks * Added concrete interface of methods in evm client * renamed commontypes to types for headbroadcaster * removed redundent declaration of function in evm client * refactored commontypes to types for txmgr --------- Co-authored-by: Prashant Yadav <34992934+prashantkumar1982@users.noreply.github.com> * Custom configPoller to support multiple Functions plugins (#9648) * custom configPoller to support multiple Functions plugins * removed log * Fixed tests * fixed lint errors * rolled back unneeded lint changes * addressed feedback * fixed error * use imported ConfigPoller interface --------- Co-authored-by: Bolek <1416262+bolekk@users.noreply.github.com> * Use make (#9687) * fix flat fee micro link (#9690) * update url example for mercury (#9691) * Modles.go evm prefix cleanup (#9654) * Modles.go evm prefix cleanup * removed evm prefix for transmitchecker --------- Co-authored-by: Prashant Yadav <34992934+prashantkumar1982@users.noreply.github.com> * [BCF-2299] ocr2 testing (#9684) * Add integration testing OCRV2 helper functions for forwarders * Add forwarders enabled flag to ocr2 smoke test setup func * Add ocr2 with fwds smoke test * Fix forwarders models definitions to match returned json * Fix OCR2TaskJobSpec String method to include ForwardingAllowed field * Change ocr2 fwds smoke test to run for 100 rounds * Improve ocr2_helpers by removing DeployOCRv2Contracts code duplicates * Improve ocr2_helpers by removing CreateOCRv2Jobs code duplicates * Fix fwdrs ocr2 smoke test round val assertion to be of same type * add iLogAutomation geth wrapper (#9665) * Cleanup setConfig on registry (#9692) * Cleanup setConfig * regen wrappers * Allow zero address to be used as proposed admin address (#9695) * Allow zero address to be used as proposed admin address * regen wrappers * fix test * fix reorg upkeep protection to allow bypass by empty blockhash (#9699) * Fix reorg protection to allow bypass via empty blockhash * regen wrappers --------- Co-authored-by: Ryan Hall * Pause checkUpkeep when registry is paused (#9704) * Pause checkUpkeep when registry is paused * regen wrappers * fix test * regen wrappers * cleanup block - conditional trigger naming to be consistent (#9705) * Cleanup block and conditional trigger to be consistent * regen wrappers * regen wrappers * Bump chainlink-starknet (includes latest caigo) (#9137) * bump caigo * Use caigo to encode the point in a canonical way * Update chainlink-starknet * clean up some logging (#9675) * Automation Registrar 2.1 (#9701) * add deployRegistry21 helper * write automation registrar v2.1 * wip * set verify to false for contract verification (#9716) * Remove excess bytes in logging (not necessary to log payload) (#9711) * Functions: connection handler (#9693) * Functions: connection handler prep work * S4 methods * FunctionsConnector tests * Fixed broken test * Addressed PR feedback * Allowlist refactor * Addressed PR feedback * Preparation for Threshold plugin integration with Functions (#9670) * squashing all commits * integrated changes from #9677 * fixed lint error * fixed lint error * fixed proto name conflict * ran protoc * addressed feedback * Addressed feedback * Added decryptionQueueConfig to integration test jobspec * Fix bugs from merge conflict resolution * Initializing S4 plugin (#9725) * Initializing S4 plugin * Addressed PR feedback * Make all error keys in logs consistent (#9718) * clean up evm 20 (#9741) * add a verifiable load contract for log trigger upkeeps * fix encoding issues in registry 2.1 (#9740) * Log event provider (#9583) * log event provider (wip) * fixes 2.1 integration * log event provider + buffer * log event provider: integration test * adding a temp copy from ocr2keepers * increase timeout to stablize test TODO: figure this out w/o timeouts at all * use log struct for check data * move log event provider int test into evm21 * extract 2.1 int tests * aligned default config should fix backfill test instability * fixes and tests * lint * extract logprovider package * extract log packer * stablize test * apply lookback buffer after rate limiting * stablize tests * log struct packing * Registry 2 1 utils contract (#9727) * build AutomationUtils contract and update tests * use report struct as rawReport bytes * update wrappers * add Log struct --------- Co-authored-by: FelixFan1992 * add verifiable load contract for log trigger upkeeps * generate go wrappers * clean up * updates * format * refactor * update * remove build info * format * update * update go script to read results --------- Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Co-authored-by: Adam Hamrick Co-authored-by: george-dorin <120329946+george-dorin@users.noreply.github.com> Co-authored-by: Sam Co-authored-by: Sergei Drugalev Co-authored-by: Bolek <1416262+bolekk@users.noreply.github.com> Co-authored-by: Andrei Smirnov Co-authored-by: kylesmartin <54827727+kylesmartin@users.noreply.github.com> Co-authored-by: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Co-authored-by: Tate Co-authored-by: Chia Yong Kang Co-authored-by: Prashant Yadav <34992934+prashantkumar1982@users.noreply.github.com> Co-authored-by: Simson Co-authored-by: ilija42 <57732589+ilija42@users.noreply.github.com> Co-authored-by: Ryan Hall Co-authored-by: Blaž Hrastnik Co-authored-by: Lei Co-authored-by: Amir Y <83904651+amirylm@users.noreply.github.com> --- contracts/scripts/native_solc_compile_all | 5 +- .../tests/LogTriggeredFeedLookup.sol | 4 +- .../src/v0.8/tests/VerifiableLoadBase.sol | 237 +- .../tests/VerifiableLoadLogTriggerUpkeep.sol | 86 + .../tests/VerifiableLoadMercuryUpkeep.sol | 49 +- .../src/v0.8/tests/VerifiableLoadUpkeep.sol | 40 +- .../log_triggered_feed_lookup_wrapper.go | 34 +- ...ifiable_load_log_trigger_upkeep_wrapper.go | 2319 +++++++++++++++++ .../verifiable_load_mercury_upkeep_wrapper.go | 1547 +++-------- .../verifiable_load_upkeep_wrapper.go | 1400 +++------- ...rapper-dependency-versions-do-not-edit.txt | 7 +- core/gethwrappers/go_generate.go | 5 +- .../handler/keeper_verifiable_load.go | 128 +- 13 files changed, 3156 insertions(+), 2705 deletions(-) create mode 100644 contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol create mode 100644 core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 5c295290fe2..82e8724774c 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -62,8 +62,9 @@ $SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationForwarderLogic. $SCRIPTPATH/native_solc8_6_compile dev/automation/tests/LogUpkeepCounter.sol $SCRIPTPATH/native_solc8_16_compile dev/automation/tests/LogTriggeredFeedLookup.sol $SCRIPTPATH/native_solc8_6_compile automation/UpkeepTranscoder.sol -$SCRIPTPATH/native_solc8_6_compile tests/VerifiableLoadUpkeep.sol -$SCRIPTPATH/native_solc8_6_compile tests/VerifiableLoadMercuryUpkeep.sol +$SCRIPTPATH/native_solc8_16_compile tests/VerifiableLoadUpkeep.sol +$SCRIPTPATH/native_solc8_16_compile tests/VerifiableLoadMercuryUpkeep.sol +$SCRIPTPATH/native_solc8_16_compile tests/VerifiableLoadLogTriggerUpkeep.sol $SCRIPTPATH/native_solc8_15_compile tests/MercuryUpkeep.sol $SCRIPTPATH/native_solc8_15_compile dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol $SCRIPTPATH/native_solc8_16_compile tests/AutomationConsumerBenchmark.sol diff --git a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol index e631eea317e..e40a719e73d 100644 --- a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol +++ b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol @@ -81,7 +81,7 @@ contract LogTriggeredFeedLookup is ILogAutomation, FeedLookupCompatibleInterface (bytes[] memory values, bytes memory extraData) = abi.decode(performData, (bytes[], bytes)); (uint256 orderId, uint256 amount, address exchange) = abi.decode(extraData, (uint256, uint256, address)); - bytes memory verifiedResponse; // = VERIFIER.verify(values[0]); + bytes memory verifiedResponse = VERIFIER.verify(values[0]); emit PerformingLogTriggerUpkeep( tx.origin, @@ -97,7 +97,7 @@ contract LogTriggeredFeedLookup is ILogAutomation, FeedLookupCompatibleInterface function checkCallback( bytes[] memory values, bytes memory extraData - ) external view override returns (bool upkeepNeeded, bytes memory performData) { + ) external view override returns (bool, bytes memory) { // do sth about the chainlinkBlob data in values and extraData bytes memory performData = abi.encode(values, extraData); return (true, performData); diff --git a/contracts/src/v0.8/tests/VerifiableLoadBase.sol b/contracts/src/v0.8/tests/VerifiableLoadBase.sol index 66c0df85d2b..78c345b87a5 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadBase.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadBase.sol @@ -1,25 +1,31 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.6; +pragma solidity ^0.8.16; import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; -import "../automation/2_0/KeeperRegistrar2_0.sol"; import "../dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol"; import {ArbSys} from "../dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import "../dev/automation/2_1/AutomationRegistrar2_1.sol"; + +struct LogTriggerConfig { + address contractAddress; + uint8 filterSelector; // denotes which topics apply to filter ex 000, 101, 111...only last 3 bits apply + bytes32 topic0; + bytes32 topic1; + bytes32 topic2; + bytes32 topic3; +} abstract contract VerifiableLoadBase is ConfirmedOwner { error IndexOutOfRange(); + event LogEmitted(uint256 indexed upkeepId, uint256 indexed blockNum, address addr); event UpkeepsRegistered(uint256[] upkeepIds); - event UpkeepsCancelled(uint256[] upkeepIds); - event RegistrarSet(address newRegistrar); - event FundsAdded(uint256 upkeepId, uint96 amount); event UpkeepTopUp(uint256 upkeepId, uint96 amount, uint256 blockNum); - event InsufficientFunds(uint256 balance, uint256 blockNum); event Received(address sender, uint256 value); - event PerformingUpkeep(uint256 firstPerformBlock, uint256 lastBlock, uint256 previousBlock, uint256 counter); using EnumerableSet for EnumerableSet.UintSet; ArbSys internal constant ARB_SYS = ArbSys(0x0000000000000000000000000000000000000064); + bytes32 public constant emittedSig = 0x97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf08; //keccak256(LogEmitted(uint256,uint256,address)) mapping(uint256 => uint256) public lastTopUpBlocks; mapping(uint256 => uint256) public intervals; @@ -30,17 +36,13 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { mapping(uint256 => uint256) public checkGasToBurns; mapping(uint256 => uint256) public performDataSizes; mapping(uint256 => uint256) public gasLimits; - mapping(uint256 => bytes) public checkDatas; mapping(bytes32 => bool) public dummyMap; // used to force storage lookup mapping(uint256 => uint256[]) public delays; // how to query for delays for a certain past period: calendar day and/or past 24 hours mapping(uint256 => mapping(uint16 => uint256[])) public bucketedDelays; - mapping(uint256 => mapping(uint16 => uint256[])) public timestampDelays; - mapping(uint256 => uint256[]) public timestamps; - mapping(uint256 => uint16) public timestampBuckets; mapping(uint256 => uint16) public buckets; EnumerableSet.UintSet internal s_upkeepIDs; - KeeperRegistrar2_0 public registrar; + AutomationRegistrar2_1 public registrar; LinkTokenInterface public linkToken; IKeeperRegistryMaster public registry; // check if an upkeep is eligible for adding funds at this interval @@ -55,15 +57,14 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { // the following fields are immutable bc if they are adjusted, the existing upkeeps' delays will be stored in // different sizes of buckets. it's better to redeploy this contract with new values. uint16 public immutable BUCKET_SIZE = 100; - uint16 public immutable TIMESTAMP_INTERVAL = 3600; /** * @param registrarAddress a registrar address * @param useArb if this contract will use arbitrum block number */ constructor(address registrarAddress, bool useArb) ConfirmedOwner(msg.sender) { - registrar = KeeperRegistrar2_0(registrarAddress); - (, , , address registryAddress, ) = registrar.getRegistrationConfig(); + registrar = AutomationRegistrar2_1(registrarAddress); + (address registryAddress, ) = registrar.getConfig(); registry = IKeeperRegistryMaster(payable(address(registryAddress))); linkToken = registrar.LINK(); useArbitrumBlockNum = useArb; @@ -93,13 +94,11 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { * @notice sets registrar, registry, and link token address. * @param newRegistrar the new registrar address */ - function setConfig(KeeperRegistrar2_0 newRegistrar) external { + function setConfig(AutomationRegistrar2_1 newRegistrar) external { registrar = newRegistrar; - (, , , address registryAddress, ) = registrar.getRegistrationConfig(); + (address registryAddress, ) = registrar.getConfig(); registry = IKeeperRegistryMaster(payable(address(registryAddress))); linkToken = registrar.LINK(); - - emit RegistrarSet(address(registrar)); } /** @@ -126,18 +125,31 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { * @param params a registration params struct * @return an upkeep ID */ - function _registerUpkeep(KeeperRegistrar2_0.RegistrationParams memory params) private returns (uint256) { + function _registerUpkeep(AutomationRegistrar2_1.RegistrationParams memory params) private returns (uint256) { uint256 upkeepId = registrar.registerUpkeep(params); s_upkeepIDs.add(upkeepId); gasLimits[upkeepId] = params.gasLimit; - checkDatas[upkeepId] = params.checkData; return upkeepId; } + function getLogTriggerConfig(uint256 upkeepId) external view returns (bytes memory logTrigger) { + LogTriggerConfig memory cfg = LogTriggerConfig({ + contractAddress: address(this), + filterSelector: 1, // only filter by topic1 + topic0: emittedSig, + topic1: bytes32(abi.encode(upkeepId)), + topic2: 0x000000000000000000000000000000000000000000000000000000000000000, + topic3: 0x000000000000000000000000000000000000000000000000000000000000000 + }); + return abi.encode(cfg); + } + /** * @notice batch registering upkeeps. * @param number the number of upkeeps to be registered * @param gasLimit the gas limit of each upkeep + * @param triggerType the trigger type of this upkeep, 0 for conditional, 1 for log trigger + * @param triggerConfig the trigger config of this upkeep * @param amount the amount of LINK to fund each upkeep * @param checkGasToBurn the amount of check gas to burn * @param performGasToBurn the amount of perform gas to burn @@ -145,17 +157,21 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { function batchRegisterUpkeeps( uint8 number, uint32 gasLimit, + uint8 triggerType, + bytes memory triggerConfig, uint96 amount, uint256 checkGasToBurn, uint256 performGasToBurn ) external { - KeeperRegistrar2_0.RegistrationParams memory params = KeeperRegistrar2_0.RegistrationParams({ + AutomationRegistrar2_1.RegistrationParams memory params = AutomationRegistrar2_1.RegistrationParams({ name: "test", encryptedEmail: bytes(""), upkeepContract: address(this), gasLimit: gasLimit, adminAddress: address(this), // use address of this contract as the admin + triggerType: triggerType, checkData: bytes(""), // update pipeline data later bc upkeep id is not available now + triggerConfig: triggerConfig, offchainConfig: bytes(""), amount: amount }); @@ -165,6 +181,10 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { uint256[] memory upkeepIds = new uint256[](number); for (uint8 i = 0; i < number; i++) { uint256 upkeepId = _registerUpkeep(params); + if (triggerType == 1) { + bytes memory triggerCfg = this.getLogTriggerConfig(upkeepId); + registry.setUpkeepTriggerConfig(upkeepId, triggerCfg); + } upkeepIds[i] = upkeepId; checkGasToBurns[upkeepId] = checkGasToBurn; performGasToBurns[upkeepId] = performGasToBurn; @@ -172,15 +192,33 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { emit UpkeepsRegistered(upkeepIds); } + function topUpFund(uint256 upkeepId, uint256 blockNum) public { + if (blockNum - lastTopUpBlocks[upkeepId] > upkeepTopUpCheckInterval) { + KeeperRegistryBase2_1.UpkeepInfo memory info = registry.getUpkeep(upkeepId); + uint96 minBalance = registry.getMinBalanceForUpkeep(upkeepId); + if (info.balance < minBalanceThresholdMultiplier * minBalance) { + addFunds(upkeepId, addLinkAmount); + lastTopUpBlocks[upkeepId] = blockNum; + emit UpkeepTopUp(upkeepId, addLinkAmount, blockNum); + } + } + } + + function burnPerformGas(uint256 upkeepId, uint256 startGas, uint256 blockNum) public { + uint256 performGasToBurn = performGasToBurns[upkeepId]; + while (startGas - gasleft() + 10000 < performGasToBurn) { + dummyMap[blockhash(blockNum)] = false; + } + } + /** * @notice adds fund for an upkeep. * @param upkeepId the upkeep ID * @param amount the amount of LINK to be funded for the upkeep */ - function addFunds(uint256 upkeepId, uint96 amount) external { + function addFunds(uint256 upkeepId, uint96 amount) public { linkToken.approve(address(registry), amount); registry.addFunds(upkeepId, amount); - emit FundsAdded(upkeepId, amount); } /** @@ -190,7 +228,6 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { */ function updateUpkeepPipelineData(uint256 upkeepId, bytes calldata pipelineData) external { registry.setUpkeepCheckData(upkeepId, pipelineData); - checkDatas[upkeepId] = pipelineData; } function withdrawLinks(uint256 upkeepId) external { @@ -222,7 +259,6 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { for (uint8 i = 0; i < len; i++) { this.cancelUpkeep(upkeepIds[i]); } - emit UpkeepsCancelled(upkeepIds); } function eligible(uint256 upkeepId) public view returns (bool) { @@ -276,13 +312,6 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { delete bucketedDelays[upkeepId][i]; } delete buckets[upkeepId]; - - currentBucket = timestampBuckets[upkeepId]; - for (uint16 i = 0; i <= currentBucket; i++) { - delete timestampDelays[upkeepId][i]; - } - delete timestamps[upkeepId]; - delete timestampBuckets[upkeepId]; } /** @@ -309,16 +338,24 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { } } - function getDelaysLength(uint256 upkeepId) public view returns (uint256) { - return delays[upkeepId].length; - } - - function getDelaysLengthAtBucket(uint256 upkeepId, uint16 bucket) public view returns (uint256) { - return bucketedDelays[upkeepId][bucket].length; + /** + * @notice finds all log trigger upkeeps and emits logs to serve as the initial trigger for upkeeps + */ + function batchSendLogs() external { + uint256[] memory upkeepIds = registry.getActiveUpkeepIDs(0, 0); + uint256 len = upkeepIds.length; + uint256 blockNum = getBlockNumber(); + for (uint256 i = 0; i < len; i++) { + uint256 upkeepId = upkeepIds[i]; + uint8 triggerType = registry.getTriggerType(upkeepId); + if (triggerType == 1) { + emit LogEmitted(upkeepId, blockNum, address(this)); + } + } } - function getDelaysLengthAtTimestampBucket(uint256 upkeepId, uint16 timestampBucket) public view returns (uint256) { - return timestampDelays[upkeepId][timestampBucket].length; + function getDelaysLength(uint256 upkeepId) public view returns (uint256) { + return delays[upkeepId].length; } function getBucketedDelaysLength(uint256 upkeepId) public view returns (uint256) { @@ -330,23 +367,10 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { return len; } - function getTimestampBucketedDelaysLength(uint256 upkeepId) public view returns (uint256) { - uint16 timestampBucket = timestampBuckets[upkeepId]; - uint256 len = 0; - for (uint16 i = 0; i <= timestampBucket; i++) { - len += timestampDelays[upkeepId][i].length; - } - return len; - } - function getDelays(uint256 upkeepId) public view returns (uint256[] memory) { return delays[upkeepId]; } - function getTimestampDelays(uint256 upkeepId, uint16 timestampBucket) public view returns (uint256[] memory) { - return timestampDelays[upkeepId][timestampBucket]; - } - function getBucketedDelays(uint256 upkeepId, uint16 bucket) public view returns (uint256[] memory) { return bucketedDelays[upkeepId][bucket]; } @@ -356,62 +380,11 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { return getSumDelayLastNPerforms(delays, n); } - function getSumBucketedDelayLastNPerforms(uint256 upkeepId, uint256 n) public view returns (uint256, uint256) { - uint256 len = this.getBucketedDelaysLength(upkeepId); - if (n == 0 || n >= len) { - n = len; - } - uint256 nn = n; - uint256 sum = 0; - uint16 currentBucket = buckets[upkeepId]; - for (uint16 i = currentBucket; i >= 0; i--) { - uint256[] memory delays = bucketedDelays[upkeepId][i]; - (uint256 s, uint256 m) = getSumDelayLastNPerforms(delays, nn); - sum += s; - nn -= m; - if (nn <= 0) { - break; - } - } - return (sum, n); - } - - function getSumTimestampBucketedDelayLastNPerforms( - uint256 upkeepId, - uint256 n - ) public view returns (uint256, uint256) { - uint256 len = this.getTimestampBucketedDelaysLength(upkeepId); - if (n == 0 || n >= len) { - n = len; - } - uint256 nn = n; - uint256 sum = 0; - uint16 timestampBucket = timestampBuckets[upkeepId]; - for (uint16 i = timestampBucket; i >= 0; i--) { - uint256[] memory delays = timestampDelays[upkeepId][i]; - (uint256 s, uint256 m) = getSumDelayLastNPerforms(delays, nn); - sum += s; - nn -= m; - if (nn <= 0) { - break; - } - } - return (sum, n); - } - function getSumDelayInBucket(uint256 upkeepId, uint16 bucket) public view returns (uint256, uint256) { uint256[] memory delays = bucketedDelays[upkeepId][bucket]; return getSumDelayLastNPerforms(delays, delays.length); } - function getSumDelayInTimestampBucket( - uint256 upkeepId, - uint16 timestampBucket - ) public view returns (uint256, uint256) { - uint256[] memory delays = timestampDelays[upkeepId][timestampBucket]; - return getSumDelayLastNPerforms(delays, delays.length); - } - function getSumDelayLastNPerforms(uint256[] memory delays, uint256 n) internal view returns (uint256, uint256) { uint256 i; uint256 len = delays.length; @@ -424,60 +397,6 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { return (sum, n); } - function getPxDelayForAllUpkeeps(uint256 p) public view returns (uint256[] memory, uint256[] memory) { - uint256 len = s_upkeepIDs.length(); - uint256[] memory upkeepIds = new uint256[](len); - uint256[] memory pxDelays = new uint256[](len); - - for (uint256 idx = 0; idx < len; idx++) { - uint256 upkeepId = s_upkeepIDs.at(idx); - uint256[] memory delays = delays[upkeepId]; - upkeepIds[idx] = upkeepId; - pxDelays[idx] = getPxDelayLastNPerforms(delays, p, delays.length); - } - - return (upkeepIds, pxDelays); - } - - function getPxBucketedDelaysForAllUpkeeps(uint256 p) public view returns (uint256[] memory, uint256[] memory) { - uint256 len = s_upkeepIDs.length(); - uint256[] memory upkeepIds = new uint256[](len); - uint256[] memory pxDelays = new uint256[](len); - - for (uint256 idx = 0; idx < len; idx++) { - uint256 upkeepId = s_upkeepIDs.at(idx); - upkeepIds[idx] = upkeepId; - uint16 currentBucket = buckets[upkeepId]; - uint256 delayLen = this.getBucketedDelaysLength(upkeepId); - uint256[] memory delays = new uint256[](delayLen); - uint256 i = 0; - mapping(uint16 => uint256[]) storage bucketedDelays = bucketedDelays[upkeepId]; - for (uint16 j = 0; j <= currentBucket; j++) { - uint256[] memory d = bucketedDelays[j]; - for (uint256 k = 0; k < d.length; k++) { - delays[i++] = d[k]; - } - } - pxDelays[idx] = getPxDelayLastNPerforms(delays, p, delayLen); - } - - return (upkeepIds, pxDelays); - } - - function getPxDelayInTimestampBucket( - uint256 upkeepId, - uint256 p, - uint16 timestampBucket - ) public view returns (uint256) { - uint256[] memory delays = timestampDelays[upkeepId][timestampBucket]; - return getPxDelayLastNPerforms(delays, p, delays.length); - } - - function getPxDelayInBucket(uint256 upkeepId, uint256 p, uint16 bucket) public view returns (uint256) { - uint256[] memory delays = bucketedDelays[upkeepId][bucket]; - return getPxDelayLastNPerforms(delays, p, delays.length); - } - function getPxDelayLastNPerforms(uint256 upkeepId, uint256 p, uint256 n) public view returns (uint256) { return getPxDelayLastNPerforms(delays[upkeepId], p, n); } diff --git a/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol new file mode 100644 index 00000000000..49f9158075f --- /dev/null +++ b/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol @@ -0,0 +1,86 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import "./VerifiableLoadBase.sol"; +import "../dev/automation/2_1/interfaces/ILogAutomation.sol"; +import "../dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol"; + +contract VerifiableLoadLogTriggerUpkeep is VerifiableLoadBase, FeedLookupCompatibleInterface, ILogAutomation { + string[] public feedsHex = [ + "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000" + ]; + string public feedParamKey = "feedIdHex"; + string public timeParamKey = "blockNumber"; + + constructor(address _registrar, bool _useArb) VerifiableLoadBase(_registrar, _useArb) {} + + function setFeedsHex(string[] memory newFeeds) external { + feedsHex = newFeeds; + } + + function checkLog(Log calldata log, bytes memory checkData) external returns (bool, bytes memory) { + uint256 startGas = gasleft(); + uint256 blockNum = getBlockNumber(); + + // filter by event signature + if (log.topics[0] == emittedSig) { + bytes memory t1 = abi.encodePacked(log.topics[1]); // bytes32 to bytes + uint256 upkeepId = abi.decode(t1, (uint256)); + bytes memory t2 = abi.encodePacked(log.topics[2]); + uint256 blockNum = abi.decode(t2, (uint256)); + + uint256 checkGasToBurn = checkGasToBurns[upkeepId]; + while (startGas - gasleft() + 15000 < checkGasToBurn) { + dummyMap[blockhash(blockNum)] = false; + blockNum--; + } + + revert FeedLookup(feedParamKey, feedsHex, timeParamKey, blockNum, abi.encode(upkeepId, blockNum)); + } + revert("could not find matching event sig"); + } + + function performUpkeep(bytes calldata performData) external { + uint256 startGas = gasleft(); + (bytes[] memory values, bytes memory extraData) = abi.decode(performData, (bytes[], bytes)); + (uint256 upkeepId, uint256 logBlockNumber) = abi.decode(extraData, (uint256, uint256)); + + uint256 firstPerformBlock = firstPerformBlocks[upkeepId]; + uint256 previousPerformBlock = previousPerformBlocks[upkeepId]; + uint256 currentBlockNum = getBlockNumber(); + + if (firstPerformBlock == 0) { + firstPerformBlocks[upkeepId] = currentBlockNum; + } else { + uint256 delay = currentBlockNum - logBlockNumber; + uint16 bucket = buckets[upkeepId]; + uint256[] memory bucketDelays = bucketedDelays[upkeepId][bucket]; + if (bucketDelays.length == BUCKET_SIZE) { + bucket++; + buckets[upkeepId] = bucket; + } + bucketedDelays[upkeepId][bucket].push(delay); + delays[upkeepId].push(delay); + } + + uint256 counter = counters[upkeepId] + 1; + counters[upkeepId] = counter; + previousPerformBlocks[upkeepId] = currentBlockNum; + + // for every upkeepTopUpCheckInterval (5), check if the upkeep balance is at least + // minBalanceThresholdMultiplier (20) * min balance. If not, add addLinkAmount (0.2) to the upkeep + // upkeepTopUpCheckInterval, minBalanceThresholdMultiplier, and addLinkAmount are configurable + topUpFund(upkeepId, currentBlockNum); + emit LogEmitted(upkeepId, currentBlockNum, address(this)); + burnPerformGas(upkeepId, startGas, currentBlockNum); + } + + function checkCallback( + bytes[] memory values, + bytes memory extraData + ) external pure override returns (bool, bytes memory) { + bytes memory performData = abi.encode(values, extraData); + return (true, performData); + } +} diff --git a/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol index 67eb8301891..3cb834033f0 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.6; +pragma solidity 0.8.16; import "./VerifiableLoadBase.sol"; import "../dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol"; @@ -10,17 +10,9 @@ contract VerifiableLoadMercuryUpkeep is VerifiableLoadBase, FeedLookupCompatible "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", "0x555344432d5553442d415242495452554d2d544553544e455400000000000000" ]; - string public constant feedParamKey = "feedIDHex"; + string public constant feedParamKey = "feedIdHex"; string public constant timeParamKey = "blockNumber"; - event MercuryPerformEvent( - address indexed origin, - uint256 indexed upkeepId, - uint256 indexed blockNumber, - bytes v0, - bytes ed - ); - constructor(address registrarAddress, bool useArb) VerifiableLoadBase(registrarAddress, useArb) {} function setFeedsHex(string[] memory newFeeds) external { @@ -67,19 +59,8 @@ contract VerifiableLoadMercuryUpkeep is VerifiableLoadBase, FeedLookupCompatible if (firstPerformBlock == 0) { firstPerformBlocks[upkeepId] = blockNum; - firstPerformBlock = blockNum; - timestamps[upkeepId].push(block.timestamp); } else { - // Calculate and append delay uint256 delay = blockNum - previousPerformBlock - intervals[upkeepId]; - - uint16 timestampBucket = timestampBuckets[upkeepId]; - if (block.timestamp - TIMESTAMP_INTERVAL > timestamps[upkeepId][timestampBucket]) { - timestamps[upkeepId].push(block.timestamp); - timestampBucket++; - timestampBuckets[upkeepId] = timestampBucket; - } - uint16 bucket = buckets[upkeepId]; uint256[] memory bucketDelays = bucketedDelays[upkeepId][bucket]; if (bucketDelays.length == BUCKET_SIZE) { @@ -87,36 +68,14 @@ contract VerifiableLoadMercuryUpkeep is VerifiableLoadBase, FeedLookupCompatible buckets[upkeepId] = bucket; } bucketedDelays[upkeepId][bucket].push(delay); - timestampDelays[upkeepId][timestampBucket].push(delay); delays[upkeepId].push(delay); } uint256 counter = counters[upkeepId] + 1; counters[upkeepId] = counter; - emit PerformingUpkeep(firstPerformBlock, blockNum, previousPerformBlock, counter); previousPerformBlocks[upkeepId] = blockNum; - // for every upkeepTopUpCheckInterval (5), check if the upkeep balance is at least - // minBalanceThresholdMultiplier (20) * min balance. If not, add addLinkAmount (0.2) to the upkeep - // upkeepTopUpCheckInterval, minBalanceThresholdMultiplier, and addLinkAmount are configurable - if (blockNum - lastTopUpBlocks[upkeepId] > upkeepTopUpCheckInterval) { - KeeperRegistryBase2_1.UpkeepInfo memory info = registry.getUpkeep(upkeepId); - uint96 minBalance = registry.getMinBalanceForUpkeep(upkeepId); - if (info.balance < minBalanceThresholdMultiplier * minBalance) { - this.addFunds(upkeepId, addLinkAmount); - lastTopUpBlocks[upkeepId] = blockNum; - emit UpkeepTopUp(upkeepId, addLinkAmount, blockNum); - } - } - - uint256 performGasToBurn = performGasToBurns[upkeepId]; - while (startGas - gasleft() + 10000 < performGasToBurn) { - // 10K margin over gas to burn - dummyMap[blockhash(blockNum)] = false; // arbitrary storage writes - } - - // bytes memory v0 = VERIFIER.verify(values[0]); - // bytes memory v1 = VERIFIER.verify(values[1]); - emit MercuryPerformEvent(tx.origin, upkeepId, blockNum, values[0], extraData); + topUpFund(upkeepId, blockNum); + burnPerformGas(upkeepId, startGas, blockNum); } } diff --git a/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol index 595c49fdd7a..e3c2e300db9 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.6; +pragma solidity 0.8.16; import "./VerifiableLoadBase.sol"; @@ -16,9 +16,7 @@ contract VerifiableLoadUpkeep is VerifiableLoadBase { uint256 blockNum = getBlockNumber(); bool needed = eligible(upkeepId); while (startGas - gasleft() + 10000 < checkGasToBurn) { - // 10K margin over gas to burn - // Hard coded check gas to burn - dummyMap[blockhash(blockNum)] = false; // arbitrary storage writes + dummyMap[blockhash(blockNum)] = false; blockNum--; } return (needed, pData); @@ -32,19 +30,8 @@ contract VerifiableLoadUpkeep is VerifiableLoadBase { uint256 blockNum = getBlockNumber(); if (firstPerformBlock == 0) { firstPerformBlocks[upkeepId] = blockNum; - firstPerformBlock = blockNum; - timestamps[upkeepId].push(block.timestamp); } else { - // Calculate and append delay uint256 delay = blockNum - previousPerformBlock - intervals[upkeepId]; - - uint16 timestampBucket = timestampBuckets[upkeepId]; - if (block.timestamp - TIMESTAMP_INTERVAL > timestamps[upkeepId][timestampBucket]) { - timestamps[upkeepId].push(block.timestamp); - timestampBucket++; - timestampBuckets[upkeepId] = timestampBucket; - } - uint16 bucket = buckets[upkeepId]; uint256[] memory bucketDelays = bucketedDelays[upkeepId][bucket]; if (bucketDelays.length == BUCKET_SIZE) { @@ -52,33 +39,14 @@ contract VerifiableLoadUpkeep is VerifiableLoadBase { buckets[upkeepId] = bucket; } bucketedDelays[upkeepId][bucket].push(delay); - timestampDelays[upkeepId][timestampBucket].push(delay); delays[upkeepId].push(delay); } uint256 counter = counters[upkeepId] + 1; counters[upkeepId] = counter; - emit PerformingUpkeep(firstPerformBlock, blockNum, previousPerformBlock, counter); previousPerformBlocks[upkeepId] = blockNum; - // for every upkeepTopUpCheckInterval (5), check if the upkeep balance is at least - // minBalanceThresholdMultiplier (20) * min balance. If not, add addLinkAmount (0.2) to the upkeep - // upkeepTopUpCheckInterval, minBalanceThresholdMultiplier, and addLinkAmount are configurable - if (blockNum - lastTopUpBlocks[upkeepId] > upkeepTopUpCheckInterval) { - KeeperRegistryBase2_1.UpkeepInfo memory info = registry.getUpkeep(upkeepId); - uint96 minBalance = registry.getMinBalanceForUpkeep(upkeepId); - if (info.balance < minBalanceThresholdMultiplier * minBalance) { - this.addFunds(upkeepId, addLinkAmount); - lastTopUpBlocks[upkeepId] = blockNum; - emit UpkeepTopUp(upkeepId, addLinkAmount, blockNum); - } - } - - uint256 performGasToBurn = performGasToBurns[upkeepId]; - while (startGas - gasleft() + 10000 < performGasToBurn) { - // 10K margin over gas to burn - dummyMap[blockhash(blockNum)] = false; // arbitrary storage writes - blockNum--; - } + topUpFund(upkeepId, blockNum); + burnPerformGas(upkeepId, startGas, blockNum); } } diff --git a/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go b/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go index dee841e4a29..f09dd42d2ab 100644 --- a/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go +++ b/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go @@ -42,8 +42,8 @@ type Log struct { } var LogTriggeredFeedLookupMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useArbitrumBlockNum\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"verified\",\"type\":\"bytes\"}],\"name\":\"PerformingLogTriggerUpkeep\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParam\",\"type\":\"string\"}],\"name\":\"setFeedParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"timeParam\",\"type\":\"string\"}],\"name\":\"setTimeParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x610120604052604260a08181526080918291906200148f60c03990526200002a9060019081620000d4565b506040805180820190915260098152680cccacac892c890caf60bb1b60208201526002906200005a908262000250565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b60208201526003906200008c908262000250565b503480156200009a57600080fd5b50604051620014d1380380620014d1833981016040819052620000bd916200031c565b6000805460ff191691151591909117905562000347565b8280548282559060005260206000209081019282156200011f579160200282015b828111156200011f57825182906200010e908262000250565b5091602001919060010190620000f5565b506200012d92915062000131565b5090565b808211156200012d57600062000148828262000152565b5060010162000131565b5080546200016090620001c1565b6000825580601f1062000171575050565b601f01602090049060005260206000209081019062000191919062000194565b50565b5b808211156200012d576000815560010162000195565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001d657607f821691505b602082108103620001f757634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200024b57600081815260208120601f850160051c81016020861015620002265750805b601f850160051c820191505b81811015620002475782815560010162000232565b5050505b505050565b81516001600160401b038111156200026c576200026c620001ab565b62000284816200027d8454620001c1565b84620001fd565b602080601f831160018114620002bc5760008415620002a35750858301515b600019600386901b1c1916600185901b17855562000247565b600085815260208120601f198616915b82811015620002ed57888601518255948401946001909101908401620002cc565b50858210156200030c5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156200032f57600080fd5b815180151581146200034057600080fd5b9392505050565b61113880620003576000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c8063642f6cef116100765780639d6f1cc71161005b5780639d6f1cc71461016b578063afb28d1f1461018b578063c98f10b01461019357600080fd5b8063642f6cef1461013b5780639525d5741461015857600080fd5b80634585e33b116100a75780634585e33b146101025780634b56a42e14610115578063601d5a711461012857600080fd5b806305e25131146100c357806340691db4146100d8575b600080fd5b6100d66100d13660046108b3565b61019b565b005b6100eb6100e6366004610969565b6101b2565b6040516100f9929190610a3a565b60405180910390f35b6100d6610110366004610a5d565b610462565b6100eb610123366004610acf565b610504565b6100d6610136366004610b8c565b61055a565b6000546101489060ff1681565b60405190151581526020016100f9565b6100d6610166366004610b8c565b610566565b61017e610179366004610bc1565b610572565b6040516100f99190610bda565b61017e61061e565b61017e61062b565b80516101ae9060019060208401906106be565b5050565b6000606060006101c0610638565b90507fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd6101f060c0870187610bf4565b600081811061020157610201610c5c565b90506020020135036103da57600061021c60c0870187610bf4565b600181811061022d5761022d610c5c565b9050602002013560405160200161024691815260200190565b604051602081830303815290604052905060008180602001905181019061026d9190610c8b565b9050600061027e60c0890189610bf4565b600281811061028f5761028f610c5c565b905060200201356040516020016102a891815260200190565b60405160208183030381529060405290506000818060200190518101906102cf9190610c8b565b905060006102e060c08b018b610bf4565b60038181106102f1576102f1610c5c565b9050602002013560405160200161030a91815260200190565b60405160208183030381529060405290506000818060200190518101906103319190610ccd565b604080516020810188905290810185905273ffffffffffffffffffffffffffffffffffffffff821660608201529091506002906001906003908a90608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526103d19594939291600401610dd6565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f670000000000000000000000000000000000000000000000000000000000000060648201526084016103d1565b60008061047183850185610acf565b9150915060008060008380602001905181019061048e9190610e99565b919450925090506060327f299a03817e683a32b21e29e3ae3c31f1c9c773f7d532836d116b62a9281fbc9d8585856104c4610638565b8b6000815181106104d7576104d7610c5c565b6020026020010151876040516104f296959493929190610ece565b60405180910390a25050505050505050565b600060606000848460405160200161051d929190610f2e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052600193509150505b9250929050565b60036101ae8282611011565b60026101ae8282611011565b6001818154811061058257600080fd5b90600052602060002001600091509050805461059d90610ce8565b80601f01602080910402602001604051908101604052809291908181526020018280546105c990610ce8565b80156106165780601f106105eb57610100808354040283529160200191610616565b820191906000526020600020905b8154815290600101906020018083116105f957829003601f168201915b505050505081565b6002805461059d90610ce8565b6003805461059d90610ce8565b6000805460ff16156106b957606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610690573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106b49190610c8b565b905090565b504390565b828054828255906000526020600020908101928215610704579160200282015b8281111561070457825182906106f49082611011565b50916020019190600101906106de565b50610710929150610714565b5090565b808211156107105760006107288282610731565b50600101610714565b50805461073d90610ce8565b6000825580601f1061074d575050565b601f01602090049060005260206000209081019061076b919061076e565b50565b5b80821115610710576000815560010161076f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156107f9576107f9610783565b604052919050565b600067ffffffffffffffff82111561081b5761081b610783565b5060051b60200190565b600082601f83011261083657600080fd5b813567ffffffffffffffff81111561085057610850610783565b61088160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016107b2565b81815284602083860101111561089657600080fd5b816020850160208301376000918101602001919091529392505050565b600060208083850312156108c657600080fd5b823567ffffffffffffffff808211156108de57600080fd5b818501915085601f8301126108f257600080fd5b813561090561090082610801565b6107b2565b81815260059190911b8301840190848101908883111561092457600080fd5b8585015b8381101561095c578035858111156109405760008081fd5b61094e8b89838a0101610825565b845250918601918601610928565b5098975050505050505050565b6000806040838503121561097c57600080fd5b823567ffffffffffffffff8082111561099457600080fd5b9084019061010082870312156109a957600080fd5b909250602084013590808211156109bf57600080fd5b506109cc85828601610825565b9150509250929050565b6000815180845260005b818110156109fc576020818501810151868301820152016109e0565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b8215158152604060208201526000610a5560408301846109d6565b949350505050565b60008060208385031215610a7057600080fd5b823567ffffffffffffffff80821115610a8857600080fd5b818501915085601f830112610a9c57600080fd5b813581811115610aab57600080fd5b866020828501011115610abd57600080fd5b60209290920196919550909350505050565b60008060408385031215610ae257600080fd5b823567ffffffffffffffff80821115610afa57600080fd5b818501915085601f830112610b0e57600080fd5b81356020610b1e61090083610801565b82815260059290921b84018101918181019089841115610b3d57600080fd5b8286015b84811015610b7557803586811115610b595760008081fd5b610b678c86838b0101610825565b845250918301918301610b41565b50965050860135925050808211156109bf57600080fd5b600060208284031215610b9e57600080fd5b813567ffffffffffffffff811115610bb557600080fd5b610a5584828501610825565b600060208284031215610bd357600080fd5b5035919050565b602081526000610bed60208301846109d6565b9392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610c2957600080fd5b83018035915067ffffffffffffffff821115610c4457600080fd5b6020019150600581901b360382131561055357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215610c9d57600080fd5b5051919050565b805173ffffffffffffffffffffffffffffffffffffffff81168114610cc857600080fd5b919050565b600060208284031215610cdf57600080fd5b610bed82610ca4565b600181811c90821680610cfc57607f821691505b602082108103610d35577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008154610d4881610ce8565b808552602060018381168015610d655760018114610d9d57610dcb565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b8901019550610dcb565b866000528260002060005b85811015610dc35781548a8201860152908301908401610da8565b890184019650505b505050505092915050565b60a081526000610de960a0830188610d3b565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610e5b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610e498383610d3b565b94860194925060019182019101610e10565b50508681036040880152610e6f818b610d3b565b9450505050508460608401528281036080840152610e8d81856109d6565b98975050505050505050565b600080600060608486031215610eae57600080fd5b8351925060208401519150610ec560408501610ca4565b90509250925092565b86815285602082015273ffffffffffffffffffffffffffffffffffffffff8516604082015283606082015260c060808201526000610f0f60c08301856109d6565b82810360a0840152610f2181856109d6565b9998505050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610fa3577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610f918683516109d6565b95509382019390820190600101610f57565b505085840381870152505050610fb981856109d6565b95945050505050565b601f82111561100c57600081815260208120601f850160051c81016020861015610fe95750805b601f850160051c820191505b8181101561100857828155600101610ff5565b5050505b505050565b815167ffffffffffffffff81111561102b5761102b610783565b61103f816110398454610ce8565b84610fc2565b602080601f831160018114611092576000841561105c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555611008565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156110df578886015182559484019460019091019084016110c0565b508582101561111b57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useArbitrumBlockNum\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"verified\",\"type\":\"bytes\"}],\"name\":\"PerformingLogTriggerUpkeep\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParam\",\"type\":\"string\"}],\"name\":\"setFeedParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"timeParam\",\"type\":\"string\"}],\"name\":\"setTimeParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x610120604052604260a0818152608091829190620015dd60c03990526200002a9060019081620000d4565b506040805180820190915260098152680cccacac892c890caf60bb1b60208201526002906200005a908262000250565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b60208201526003906200008c908262000250565b503480156200009a57600080fd5b506040516200161f3803806200161f833981016040819052620000bd916200031c565b6000805460ff191691151591909117905562000347565b8280548282559060005260206000209081019282156200011f579160200282015b828111156200011f57825182906200010e908262000250565b5091602001919060010190620000f5565b506200012d92915062000131565b5090565b808211156200012d57600062000148828262000152565b5060010162000131565b5080546200016090620001c1565b6000825580601f1062000171575050565b601f01602090049060005260206000209081019062000191919062000194565b50565b5b808211156200012d576000815560010162000195565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001d657607f821691505b602082108103620001f757634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200024b57600081815260208120601f850160051c81016020861015620002265750805b601f850160051c820191505b81811015620002475782815560010162000232565b5050505b505050565b81516001600160401b038111156200026c576200026c620001ab565b62000284816200027d8454620001c1565b84620001fd565b602080601f831160018114620002bc5760008415620002a35750858301515b600019600386901b1c1916600185901b17855562000247565b600085815260208120601f198616915b82811015620002ed57888601518255948401946001909101908401620002cc565b50858210156200030c5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156200032f57600080fd5b815180151581146200034057600080fd5b9392505050565b61128680620003576000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c8063642f6cef116100765780639d6f1cc71161005b5780639d6f1cc71461016b578063afb28d1f1461018b578063c98f10b01461019357600080fd5b8063642f6cef1461013b5780639525d5741461015857600080fd5b80634585e33b116100a75780634585e33b146101025780634b56a42e14610115578063601d5a711461012857600080fd5b806305e25131146100c357806340691db4146100d8575b600080fd5b6100d66100d136600461098e565b61019b565b005b6100eb6100e6366004610a3f565b6101b2565b6040516100f9929190610b1a565b60405180910390f35b6100d6610110366004610b3d565b610462565b6100eb610123366004610baf565b6105d1565b6100d6610136366004610c6c565b610627565b6000546101489060ff1681565b60405190151581526020016100f9565b6100d6610166366004610c6c565b610633565b61017e610179366004610ca1565b61063f565b6040516100f99190610cba565b61017e6106eb565b61017e6106f8565b80516101ae90600190602084019061078b565b5050565b6000606060006101c0610705565b90507fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd6101f060c0870187610cd4565b600081811061020157610201610d3c565b90506020020135036103da57600061021c60c0870187610cd4565b600181811061022d5761022d610d3c565b9050602002013560405160200161024691815260200190565b604051602081830303815290604052905060008180602001905181019061026d9190610d6b565b9050600061027e60c0890189610cd4565b600281811061028f5761028f610d3c565b905060200201356040516020016102a891815260200190565b60405160208183030381529060405290506000818060200190518101906102cf9190610d6b565b905060006102e060c08b018b610cd4565b60038181106102f1576102f1610d3c565b9050602002013560405160200161030a91815260200190565b60405160208183030381529060405290506000818060200190518101906103319190610dad565b604080516020810188905290810185905273ffffffffffffffffffffffffffffffffffffffff821660608201529091506002906001906003908a90608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526103d19594939291600401610eb6565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f670000000000000000000000000000000000000000000000000000000000000060648201526084016103d1565b60008061047183850185610baf565b9150915060008060008380602001905181019061048e9190610f79565b92509250925060007309dff56a4ff44e0f4436260a04f5cfa65636a48173ffffffffffffffffffffffffffffffffffffffff16638e760afe876000815181106104d9576104d9610d3c565b60200260200101516040518263ffffffff1660e01b81526004016104fd9190610cba565b6000604051808303816000875af115801561051c573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526105629190810190610fae565b9050327f299a03817e683a32b21e29e3ae3c31f1c9c773f7d532836d116b62a9281fbc9d858585610591610705565b8b6000815181106105a4576105a4610d3c565b6020026020010151876040516105bf96959493929190611025565b60405180910390a25050505050505050565b60006060600084846040516020016105ea929190611085565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052600193509150505b9250929050565b60036101ae828261115f565b60026101ae828261115f565b6001818154811061064f57600080fd5b90600052602060002001600091509050805461066a90610dc8565b80601f016020809104026020016040519081016040528092919081815260200182805461069690610dc8565b80156106e35780601f106106b8576101008083540402835291602001916106e3565b820191906000526020600020905b8154815290600101906020018083116106c657829003601f168201915b505050505081565b6002805461066a90610dc8565b6003805461066a90610dc8565b6000805460ff161561078657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561075d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107819190610d6b565b905090565b504390565b8280548282559060005260206000209081019282156107d1579160200282015b828111156107d157825182906107c1908261115f565b50916020019190600101906107ab565b506107dd9291506107e1565b5090565b808211156107dd5760006107f582826107fe565b506001016107e1565b50805461080a90610dc8565b6000825580601f1061081a575050565b601f016020900490600052602060002090810190610838919061083b565b50565b5b808211156107dd576000815560010161083c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156108c6576108c6610850565b604052919050565b600067ffffffffffffffff8211156108e8576108e8610850565b5060051b60200190565b600067ffffffffffffffff82111561090c5761090c610850565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f83011261094957600080fd5b813561095c610957826108f2565b61087f565b81815284602083860101111561097157600080fd5b816020850160208301376000918101602001919091529392505050565b600060208083850312156109a157600080fd5b823567ffffffffffffffff808211156109b957600080fd5b818501915085601f8301126109cd57600080fd5b81356109db610957826108ce565b81815260059190911b830184019084810190888311156109fa57600080fd5b8585015b83811015610a3257803585811115610a165760008081fd5b610a248b89838a0101610938565b8452509186019186016109fe565b5098975050505050505050565b60008060408385031215610a5257600080fd5b823567ffffffffffffffff80821115610a6a57600080fd5b908401906101008287031215610a7f57600080fd5b90925060208401359080821115610a9557600080fd5b50610aa285828601610938565b9150509250929050565b60005b83811015610ac7578181015183820152602001610aaf565b50506000910152565b60008151808452610ae8816020860160208601610aac565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b8215158152604060208201526000610b356040830184610ad0565b949350505050565b60008060208385031215610b5057600080fd5b823567ffffffffffffffff80821115610b6857600080fd5b818501915085601f830112610b7c57600080fd5b813581811115610b8b57600080fd5b866020828501011115610b9d57600080fd5b60209290920196919550909350505050565b60008060408385031215610bc257600080fd5b823567ffffffffffffffff80821115610bda57600080fd5b818501915085601f830112610bee57600080fd5b81356020610bfe610957836108ce565b82815260059290921b84018101918181019089841115610c1d57600080fd5b8286015b84811015610c5557803586811115610c395760008081fd5b610c478c86838b0101610938565b845250918301918301610c21565b5096505086013592505080821115610a9557600080fd5b600060208284031215610c7e57600080fd5b813567ffffffffffffffff811115610c9557600080fd5b610b3584828501610938565b600060208284031215610cb357600080fd5b5035919050565b602081526000610ccd6020830184610ad0565b9392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610d0957600080fd5b83018035915067ffffffffffffffff821115610d2457600080fd5b6020019150600581901b360382131561062057600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215610d7d57600080fd5b5051919050565b805173ffffffffffffffffffffffffffffffffffffffff81168114610da857600080fd5b919050565b600060208284031215610dbf57600080fd5b610ccd82610d84565b600181811c90821680610ddc57607f821691505b602082108103610e15577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008154610e2881610dc8565b808552602060018381168015610e455760018114610e7d57610eab565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b8901019550610eab565b866000528260002060005b85811015610ea35781548a8201860152908301908401610e88565b890184019650505b505050505092915050565b60a081526000610ec960a0830188610e1b565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610f3b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610f298383610e1b565b94860194925060019182019101610ef0565b50508681036040880152610f4f818b610e1b565b9450505050508460608401528281036080840152610f6d8185610ad0565b98975050505050505050565b600080600060608486031215610f8e57600080fd5b8351925060208401519150610fa560408501610d84565b90509250925092565b600060208284031215610fc057600080fd5b815167ffffffffffffffff811115610fd757600080fd5b8201601f81018413610fe857600080fd5b8051610ff6610957826108f2565b81815285602083850101111561100b57600080fd5b61101c826020830160208601610aac565b95945050505050565b86815285602082015273ffffffffffffffffffffffffffffffffffffffff8516604082015283606082015260c06080820152600061106660c0830185610ad0565b82810360a08401526110788185610ad0565b9998505050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156110fa577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030185526110e8868351610ad0565b955093820193908201906001016110ae565b50508584038187015250505061101c8185610ad0565b601f82111561115a57600081815260208120601f850160051c810160208610156111375750805b601f850160051c820191505b8181101561115657828155600101611143565b5050505b505050565b815167ffffffffffffffff81111561117957611179610850565b61118d816111878454610dc8565b84611110565b602080601f8311600181146111e057600084156111aa5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555611156565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561122d5788860151825594840194600190910190840161120e565b508582101561126957878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var LogTriggeredFeedLookupABI = LogTriggeredFeedLookupMetaData.ABI @@ -182,33 +182,26 @@ func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactorRaw) Transact(opt return _LogTriggeredFeedLookup.Contract.contract.Transact(opts, method, params...) } -func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCaller) CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (CheckCallback, - - error) { +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCaller) CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (bool, []byte, error) { var out []interface{} err := _LogTriggeredFeedLookup.contract.Call(opts, &out, "checkCallback", values, extraData) - outstruct := new(CheckCallback) if err != nil { - return *outstruct, err + return *new(bool), *new([]byte), err } - outstruct.UpkeepNeeded = *abi.ConvertType(out[0], new(bool)).(*bool) - outstruct.PerformData = *abi.ConvertType(out[1], new([]byte)).(*[]byte) + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + out1 := *abi.ConvertType(out[1], new([]byte)).(*[]byte) - return *outstruct, err + return out0, out1, err } -func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupSession) CheckCallback(values [][]byte, extraData []byte) (CheckCallback, - - error) { +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupSession) CheckCallback(values [][]byte, extraData []byte) (bool, []byte, error) { return _LogTriggeredFeedLookup.Contract.CheckCallback(&_LogTriggeredFeedLookup.CallOpts, values, extraData) } -func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCallerSession) CheckCallback(values [][]byte, extraData []byte) (CheckCallback, - - error) { +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCallerSession) CheckCallback(values [][]byte, extraData []byte) (bool, []byte, error) { return _LogTriggeredFeedLookup.Contract.CheckCallback(&_LogTriggeredFeedLookup.CallOpts, values, extraData) } @@ -493,11 +486,6 @@ func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupFilterer) ParsePerformingLo return event, nil } -type CheckCallback struct { - UpkeepNeeded bool - PerformData []byte -} - func (_LogTriggeredFeedLookup *LogTriggeredFeedLookup) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { case _LogTriggeredFeedLookup.abi.Events["PerformingLogTriggerUpkeep"].ID: @@ -517,9 +505,7 @@ func (_LogTriggeredFeedLookup *LogTriggeredFeedLookup) Address() common.Address } type LogTriggeredFeedLookupInterface interface { - CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (CheckCallback, - - error) + CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (bool, []byte, error) FeedParamKey(opts *bind.CallOpts) (string, error) diff --git a/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go new file mode 100644 index 00000000000..e031ecc6b1a --- /dev/null +++ b/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go @@ -0,0 +1,2319 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package verifiable_load_log_trigger_upkeep_wrapper + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type Log struct { + Index *big.Int + TxIndex *big.Int + TxHash [32]byte + BlockNumber *big.Int + BlockHash [32]byte + Source common.Address + Topics [][32]byte + Data []byte +} + +var VerifiableLoadLogTriggerUpkeepMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x6005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460a052610180604052604261010081815260c091829190620051ff61012039815260200160405180608001604052806042815260200162005241604291399052620000759060169060026200037e565b506040805180820190915260098152680cccacac892c890caf60bb1b6020820152601790620000a59082620004fa565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152601890620000d79082620004fa565b50348015620000e557600080fd5b5060405162005283380380620052838339810160408190526200010891620005dc565b81813380600081620001615760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000194576200019481620002d3565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200021791906200061f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200027d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002a3919062000650565b601280546001600160a01b0319166001600160a01b03929092169190911790555015156080525062000677915050565b336001600160a01b038216036200032d5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000158565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003c9579160200282015b82811115620003c95782518290620003b89082620004fa565b50916020019190600101906200039f565b50620003d7929150620003db565b5090565b80821115620003d7576000620003f28282620003fc565b50600101620003db565b5080546200040a906200046b565b6000825580601f106200041b575050565b601f0160209004906000526020600020908101906200043b91906200043e565b50565b5b80821115620003d757600081556001016200043f565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200048057607f821691505b602082108103620004a157634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620004f557600081815260208120601f850160051c81016020861015620004d05750805b601f850160051c820191505b81811015620004f157828155600101620004dc565b5050505b505050565b81516001600160401b0381111562000516576200051662000455565b6200052e816200052784546200046b565b84620004a7565b602080601f8311600181146200056657600084156200054d5750858301515b600019600386901b1c1916600185901b178555620004f1565b600085815260208120601f198616915b82811015620005975788860151825594840194600190910190840162000576565b5085821015620005b65787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b03811681146200043b57600080fd5b60008060408385031215620005f057600080fd5b8251620005fd81620005c6565b602084015190925080151581146200061457600080fd5b809150509250929050565b600080604083850312156200063357600080fd5b82516200064081620005c6565b6020939093015192949293505050565b6000602082840312156200066357600080fd5b81516200067081620005c6565b9392505050565b60805160a051614b54620006ab600039600081816104f00152611bf401526000818161082c01526130410152614b546000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610dc7578063f2fde38b14610ddd578063fba7ffa314610dfd578063fcdc1f6314610e2a57600080fd5b8063d6051a7214610d3a578063daee1aeb14610d5a578063dbef701e14610d7a578063e0114adb14610d9a57600080fd5b8063c357f1f3116100dc578063c357f1f314610c4c578063c804802214610ca6578063c98f10b014610cc6578063d355852814610cdb57600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c2c57600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b806346e7a63e116102e2578063636092e8116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063636092e8146107d8578063642f6cef1461081a57806369cdbadb1461085e57806369e9b7731461088b57600080fd5b806359710992116102b157806359710992146107615780635d4ee7f3146107765780635f17e6161461078b57806360457ff5146107ab57600080fd5b806346e7a63e146106c75780634b56a42e146106f457806351c98be31461071457806357970e931461073457600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c1461063957806340691db4146106595780634585e33b1461068757806345d2ec17146106a757600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b61042636600461378a565b610e57565b005b34801561043957600080fd5b5061042b6104483660046138ab565b610e6e565b34801561045957600080fd5b5061046d610468366004613947565b61122a565b60405161047a9190613969565b60405180910390f35b34801561048f57600080fd5b506104a361049e3660046139c4565b611329565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc3660046139f9565b611367565b60405161047a9190613a80565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a93565b611487565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613ae1565b61150a565b34801561058657600080fd5b506104a3610595366004613afe565b6116d4565b3480156105a657600080fd5b5061042b6105b5366004613b6f565b61173f565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a36106273660046139f9565b60036020526000908152604090205481565b34801561064557600080fd5b506104a36106543660046139f9565b6117d9565b34801561066557600080fd5b50610679610674366004613bb1565b611842565b60405161047a929190613c1e565b34801561069357600080fd5b5061042b6106a2366004613c7b565b611af3565b3480156106b357600080fd5b5061046d6106c2366004613a93565b611d44565b3480156106d357600080fd5b506104a36106e23660046139f9565b600a6020526000908152604090205481565b34801561070057600080fd5b5061067961070f366004613cb1565b611db3565b34801561072057600080fd5b5061042b61072f366004613d6e565b611e07565b34801561074057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561076d57600080fd5b5061042b611eab565b34801561078257600080fd5b5061042b612096565b34801561079757600080fd5b5061042b6107a6366004613947565b6121cd565b3480156107b757600080fd5b506104a36107c63660046139f9565b60076020526000908152604090205481565b3480156107e457600080fd5b506015546107fd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561082657600080fd5b5061084e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561086a57600080fd5b506104a36108793660046139f9565b60086020526000908152604090205481565b34801561089757600080fd5b5061042b6108a6366004613947565b60009182526008602052604090912055565b3480156108c457600080fd5b5061084e6108d33660046139f9565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a36109033660046139f9565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a36109303660046139f9565b60046020526000908152604090205481565b34801561094e57600080fd5b5061084e61095d3660046139f9565b61229a565b34801561096e57600080fd5b5061042b6122ec565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613dc5565b6123e9565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a3660046139f9565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a37366004613947565b61247a565b348015610a4857600080fd5b5061042b610a57366004613e11565b6126bf565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab3366004613947565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae03660046139f9565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b113660046139f9565b612808565b348015610b2257600080fd5b506104d1610b313660046139f9565b61286a565b348015610b4257600080fd5b506104a37f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0881565b348015610b7657600080fd5b5061042b610b85366004613afe565b612916565b348015610b9657600080fd5b5061042b610ba53660046139f9565b601455565b348015610bb657600080fd5b5061042b610bc5366004613e41565b61297f565b348015610bd657600080fd5b5061042b610be5366004613947565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c123660046139f9565b612a2a565b348015610c2357600080fd5b506104d1612ab0565b348015610c3857600080fd5b5061042b610c47366004613b6f565b612abd565b348015610c5857600080fd5b5061042b610c67366004613e66565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610cb257600080fd5b5061042b610cc13660046139f9565b612b57565b348015610cd257600080fd5b506104d1612bef565b348015610ce757600080fd5b5061042b610cf6366004613e83565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610d4657600080fd5b50610545610d55366004613947565b612bfc565b348015610d6657600080fd5b5061042b610d75366004613b6f565b612c65565b348015610d8657600080fd5b506104a3610d95366004613947565b612d30565b348015610da657600080fd5b506104a3610db53660046139f9565b60096020526000908152604090205481565b348015610dd357600080fd5b506104a360145481565b348015610de957600080fd5b5061042b610df8366004613ae1565b612d61565b348015610e0957600080fd5b506104a3610e183660046139f9565b60066020526000908152604090205481565b348015610e3657600080fd5b506104a3610e453660046139f9565b60026020526000908152604090205481565b8051610e6a90601690602084019061355a565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610f54908c1688613ecf565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610fd2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ff69190613f13565b5060008860ff1667ffffffffffffffff8111156110155761101561363a565b60405190808252806020026020018201604052801561103e578160200160208202803683370190505b50905060005b8960ff168160ff1610156111e757600061105d84612d75565b90508860ff16600103611195576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111089190810190613f7b565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111619085908590600401613fb0565b600060405180830381600087803b15801561117b57600080fd5b505af115801561118f573d6000803e3d6000fd5b50505050505b80838360ff16815181106111ab576111ab613fc9565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111df81613ff8565b915050611044565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516112179190613969565b60405180910390a1505050505050505050565b60606000611238600f612e43565b9050808410611273576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82600003611288576112858482614017565b92505b60008367ffffffffffffffff8111156112a3576112a361363a565b6040519080825280602002602001820160405280156112cc578160200160208202803683370190505b50905060005b8481101561131e576112ef6112e7828861402a565b600f90612e4d565b82828151811061130157611301613fc9565b6020908102919091010152806113168161403d565b9150506112d2565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061135157600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0860001b8152602001846040516020016113d891815260200190565b6040516020818303038152906040526113f090614075565b81526020016000801b81526020016000801b8152509050806040516020016114709190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156114eb57602002820191906000526020600020905b8154815260200190600101908083116114d7575b505050505090506114fd818251612e59565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa1580156115a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c491906140c5565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015611667573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168b91906140f3565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c6020908152604080832080548251818502810185019093528083526117359383018282801561172957602002820191906000526020600020905b815481526020019060010190808311611715575b50505050508484612ede565b90505b9392505050565b8060005b818160ff1610156117d3573063c8048022858560ff851681811061176957611769613fc9565b905060200201356040518263ffffffff1660e01b815260040161178e91815260200190565b600060405180830381600087803b1580156117a857600080fd5b505af11580156117bc573d6000803e3d6000fd5b5050505080806117cb90613ff8565b915050611743565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff161161183a576000858152600d6020908152604080832061ffff85168452909152902054611826908361402a565b91508061183281614110565b9150506117ef565b509392505050565b6000606060005a9050600061185561303d565b90507f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0861188560c0880188614131565b600081811061189657611896613fc9565b9050602002013503611a6b5760006118b160c0880188614131565b60018181106118c2576118c2613fc9565b905060200201356040516020016118db91815260200190565b60405160208183030381529060405290506000818060200190518101906119029190614199565b9050600061191360c08a018a614131565b600281811061192457611924613fc9565b9050602002013560405160200161193d91815260200190565b60405160208183030381529060405290506000818060200190518101906119649190614199565b6000848152600860205260409020549091505b805a6119839089614017565b61198f90613a9861402a565b10156119dd5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055816119d5816141b2565b925050611977565b601760166018848786604051602001611a00929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252611a6295949392916004016142cf565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f67000000000000000000000000000000000000000000000000000000000000006064820152608401611a62565b60005a9050600080611b0784860186613cb1565b9150915060008082806020019051810190611b229190614392565b6000828152600560209081526040808320546004909252822054939550919350909190611b4d61303d565b905082600003611b6d576000858152600560205260409020819055611cb1565b6000611b798583614017565b6000878152600e6020908152604080832054600d835281842061ffff909116808552908352818420805483518186028101860190945280845295965090949192909190830182828015611beb57602002820191906000526020600020905b815481526020019060010190808311611bd7575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611c665781611c2881614110565b60008a8152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055898352600c8252928220805493840181558252902001555b600085815260066020526040812054611ccb90600161402a565b6000878152600660209081526040808320849055600490915290208390559050611cf5868361247a565b604051308152829087907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a3611d37868a84612916565b5050505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611da657602002820191906000526020600020905b815481526020019060010190808311611d92575b5050505050905092915050565b6000606060008484604051602001611dcc9291906143b6565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611ea45730635f17e616868684818110611e2b57611e2b613fc9565b90506020020135856040518363ffffffff1660e01b8152600401611e5f92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611e7957600080fd5b505af1158015611e8d573d6000803e3d6000fd5b505050508080611e9c9061403d565b915050611e0b565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611f22573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f68919081019061444a565b80519091506000611f7761303d565b905060005b828110156117d3576000848281518110611f9857611f98613fc9565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015612018573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061203c91906144db565b90508060ff1660010361208157604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b5050808061208e9061403d565b915050611f7c565b61209e6130df565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561210d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121319190614199565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af11580156121a9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6a9190613f13565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120612205916135b0565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611612261576000848152600d6020908152604080832061ffff85168452909152812061224f916135b0565b8061225981614110565b91505061221a565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b60008181526005602052604081205481036122b757506001919050565b6000828152600360209081526040808320546004909252909120546122da61303d565b6122e49190614017565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461236d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401611a62565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b590612443908690869086906004016144f8565b600060405180830381600087803b15801561245d57600080fd5b505af1158015612471573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124969083614017565b1115610e6a576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa15801561250c573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612552919081019061457a565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156125c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125eb9190614699565b60155490915061260f9082906c01000000000000000000000000900460ff16613ecf565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156117d3576015546126529085906bffffffffffffffffffffffff166126bf565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af1158015612747573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061276b9190613f13565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b1580156127ec57600080fd5b505af1158015612800573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561285e57602002820191906000526020600020905b81548152602001906001019080831161284a575b50505050509050919050565b6016818154811061287a57600080fd5b906000526020600020016000915090508054612895906141e7565b80601f01602080910402602001604051908101604052809291908181526020018280546128c1906141e7565b801561290e5780601f106128e35761010080835404028352916020019161290e565b820191906000526020600020905b8154815290600101906020018083116128f157829003601f168201915b505050505081565b6000838152600760205260409020545b805a6129329085614017565b61293e9061271061402a565b10156117d35781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612926565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b1580156129f757600080fd5b505af1158015612a0b573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a9c57600080fd5b505af1158015611ea4573d6000803e3d6000fd5b60178054612895906141e7565b8060005b818163ffffffff1610156117d3573063af953a4a858563ffffffff8516818110612aed57612aed613fc9565b905060200201356040518263ffffffff1660e01b8152600401612b1291815260200190565b600060405180830381600087803b158015612b2c57600080fd5b505af1158015612b40573d6000803e3d6000fd5b505050508080612b4f906146b6565b915050612ac1565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612bc357600080fd5b505af1158015612bd7573d6000803e3d6000fd5b50505050610e6a81600f61316290919063ffffffff16565b60188054612895906141e7565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612c5457602002820191906000526020600020905b815481526020019060010190808311612c40575b505050505090506114fd8185612e59565b8060005b818110156117d3576000848483818110612c8557612c85613fc9565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612cbe91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612cea929190613fb0565b600060405180830381600087803b158015612d0457600080fd5b505af1158015612d18573d6000803e3d6000fd5b50505050508080612d289061403d565b915050612c69565b600c6020528160005260406000208181548110612d4c57600080fd5b90600052602060002001600091509150505481565b612d696130df565b612d728161316e565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612dd09086906004016146cf565b6020604051808303816000875af1158015612def573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e139190614199565b9050612e20600f82613263565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b6000611323825490565b6000611738838361326f565b815160009081908190841580612e6f5750808510155b15612e78578094505b60008092505b85831015612ed457866001612e938585614017565b612e9d9190614017565b81518110612ead57612ead613fc9565b602002602001015181612ec0919061402a565b905082612ecc8161403d565b935050612e7e565b9694955050505050565b82516000908190831580612ef25750808410155b15612efb578093505b60008467ffffffffffffffff811115612f1657612f1661363a565b604051908082528060200260200182016040528015612f3f578160200160208202803683370190505b509050600092505b84831015612fad57866001612f5c8585614017565b612f669190614017565b81518110612f7657612f76613fc9565b6020026020010151818481518110612f9057612f90613fc9565b602090810291909101015282612fa58161403d565b935050612f47565b612fc681600060018451612fc19190614017565b613299565b85606403612fff578060018251612fdd9190614017565b81518110612fed57612fed613fc9565b60200260200101519350505050611738565b80606482518861300f9190614821565b613019919061488d565b8151811061302957613029613fc9565b602002602001015193505050509392505050565b60007f0000000000000000000000000000000000000000000000000000000000000000156130da57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156130b1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130d59190614199565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314613160576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611a62565b565b60006117388383613411565b3373ffffffffffffffffffffffffffffffffffffffff8216036131ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611a62565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000611738838361350b565b600082600001828154811061328657613286613fc9565b9060005260206000200154905092915050565b81818082036132a9575050505050565b60008560026132b887876148a1565b6132c291906148c1565b6132cc9087614929565b815181106132dc576132dc613fc9565b602002602001015190505b8183136133eb575b8086848151811061330257613302613fc9565b60200260200101511015613322578261331a81614951565b9350506132ef565b85828151811061333457613334613fc9565b6020026020010151811015613355578161334d81614982565b925050613322565b8183136133e65785828151811061336e5761336e613fc9565b602002602001015186848151811061338857613388613fc9565b60200260200101518785815181106133a2576133a2613fc9565b602002602001018885815181106133bb576133bb613fc9565b602090810291909101019190915252826133d481614951565b93505081806133e290614982565b9250505b6132e7565b818512156133fe576133fe868684613299565b8383121561280057612800868486613299565b600081815260018301602052604081205480156134fa576000613435600183614017565b855490915060009061344990600190614017565b90508181146134ae57600086600001828154811061346957613469613fc9565b906000526020600020015490508087600001848154811061348c5761348c613fc9565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134bf576134bf6149b3565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050611323565b6000915050611323565b5092915050565b600081815260018301602052604081205461355257508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155611323565b506000611323565b8280548282559060005260206000209081019282156135a0579160200282015b828111156135a057825182906135909082614a2d565b509160200191906001019061357a565b506135ac9291506135ce565b5090565b5080546000825590600052602060002090810190612d7291906135eb565b808211156135ac5760006135e28282613600565b506001016135ce565b5b808211156135ac57600081556001016135ec565b50805461360c906141e7565b6000825580601f1061361c575050565b601f016020900490600052602060002090810190612d7291906135eb565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561368d5761368d61363a565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156136da576136da61363a565b604052919050565b600067ffffffffffffffff8211156136fc576136fc61363a565b5060051b60200190565b600067ffffffffffffffff8211156137205761372061363a565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600061375f61375a84613706565b613693565b905082815283838301111561377357600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561379d57600080fd5b823567ffffffffffffffff808211156137b557600080fd5b818501915085601f8301126137c957600080fd5b81356137d761375a826136e2565b81815260059190911b830184019084810190888311156137f657600080fd5b8585015b83811015613843578035858111156138125760008081fd5b8601603f81018b136138245760008081fd5b6138358b898301356040840161374c565b8452509186019186016137fa565b5098975050505050505050565b60ff81168114612d7257600080fd5b63ffffffff81168114612d7257600080fd5b600082601f83011261388257600080fd5b6117388383356020850161374c565b6bffffffffffffffffffffffff81168114612d7257600080fd5b600080600080600080600060e0888a0312156138c657600080fd5b87356138d181613850565b965060208801356138e18161385f565b955060408801356138f181613850565b9450606088013567ffffffffffffffff81111561390d57600080fd5b6139198a828b01613871565b945050608088013561392a81613891565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561395a57600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b818110156139a157835183529284019291840191600101613985565b50909695505050505050565b803561ffff811681146139bf57600080fd5b919050565b6000806000606084860312156139d957600080fd5b833592506139e9602085016139ad565b9150604084013590509250925092565b600060208284031215613a0b57600080fd5b5035919050565b60005b83811015613a2d578181015183820152602001613a15565b50506000910152565b60008151808452613a4e816020860160208601613a12565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117386020830184613a36565b60008060408385031215613aa657600080fd5b82359150613ab6602084016139ad565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612d7257600080fd5b600060208284031215613af357600080fd5b813561173881613abf565b600080600060608486031215613b1357600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613b3c57600080fd5b50813567ffffffffffffffff811115613b5457600080fd5b6020830191508360208260051b850101111561150357600080fd5b60008060208385031215613b8257600080fd5b823567ffffffffffffffff811115613b9957600080fd5b613ba585828601613b2a565b90969095509350505050565b60008060408385031215613bc457600080fd5b823567ffffffffffffffff80821115613bdc57600080fd5b908401906101008287031215613bf157600080fd5b90925060208401359080821115613c0757600080fd5b50613c1485828601613871565b9150509250929050565b82151581526040602082015260006117356040830184613a36565b60008083601f840112613c4b57600080fd5b50813567ffffffffffffffff811115613c6357600080fd5b60208301915083602082850101111561150357600080fd5b60008060208385031215613c8e57600080fd5b823567ffffffffffffffff811115613ca557600080fd5b613ba585828601613c39565b60008060408385031215613cc457600080fd5b823567ffffffffffffffff80821115613cdc57600080fd5b818501915085601f830112613cf057600080fd5b81356020613d0061375a836136e2565b82815260059290921b84018101918181019089841115613d1f57600080fd5b8286015b84811015613d5757803586811115613d3b5760008081fd5b613d498c86838b0101613871565b845250918301918301613d23565b5096505086013592505080821115613c0757600080fd5b600080600060408486031215613d8357600080fd5b833567ffffffffffffffff811115613d9a57600080fd5b613da686828701613b2a565b9094509250506020840135613dba8161385f565b809150509250925092565b600080600060408486031215613dda57600080fd5b83359250602084013567ffffffffffffffff811115613df857600080fd5b613e0486828701613c39565b9497909650939450505050565b60008060408385031215613e2457600080fd5b823591506020830135613e3681613891565b809150509250929050565b60008060408385031215613e5457600080fd5b823591506020830135613e368161385f565b600060208284031215613e7857600080fd5b813561173881613891565b600060208284031215613e9557600080fd5b813561173881613850565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613efa57613efa613ea0565b02949350505050565b805180151581146139bf57600080fd5b600060208284031215613f2557600080fd5b61173882613f03565b600082601f830112613f3f57600080fd5b8151613f4d61375a82613706565b818152846020838601011115613f6257600080fd5b613f73826020830160208701613a12565b949350505050565b600060208284031215613f8d57600080fd5b815167ffffffffffffffff811115613fa457600080fd5b613f7384828501613f2e565b8281526040602082015260006117356040830184613a36565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361400e5761400e613ea0565b60010192915050565b8181038181111561132357611323613ea0565b8082018082111561132357611323613ea0565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406e5761406e613ea0565b5060010190565b805160208083015191908110156140b4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b80516139bf81613abf565b600080604083850312156140d857600080fd5b82516140e381613abf565b6020939093015192949293505050565b60006020828403121561410557600080fd5b815161173881613abf565b600061ffff80831681810361412757614127613ea0565b6001019392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261416657600080fd5b83018035915067ffffffffffffffff82111561418157600080fd5b6020019150600581901b360382131561150357600080fd5b6000602082840312156141ab57600080fd5b5051919050565b6000816141c1576141c1613ea0565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600181811c908216806141fb57607f821691505b6020821081036140b4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60008154614241816141e7565b80855260206001838116801561425e5760018114614296576142c4565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b89010195506142c4565b866000528260002060005b858110156142bc5781548a82018601529083019084016142a1565b890184019650505b505050505092915050565b60a0815260006142e260a0830188614234565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015614354577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526143428383614234565b94860194925060019182019101614309565b50508681036040880152614368818b614234565b94505050505084606084015282810360808401526143868185613a36565b98975050505050505050565b600080604083850312156143a557600080fd5b505080516020909101519092909150565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561442b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614419868351613a36565b955093820193908201906001016143df565b5050858403818701525050506144418185613a36565b95945050505050565b6000602080838503121561445d57600080fd5b825167ffffffffffffffff81111561447457600080fd5b8301601f8101851361448557600080fd5b805161449361375a826136e2565b81815260059190911b820183019083810190878311156144b257600080fd5b928401925b828410156144d0578351825292840192908401906144b7565b979650505050505050565b6000602082840312156144ed57600080fd5b815161173881613850565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b80516139bf8161385f565b80516139bf81613891565b805167ffffffffffffffff811681146139bf57600080fd5b60006020828403121561458c57600080fd5b815167ffffffffffffffff808211156145a457600080fd5b9083019061014082860312156145b957600080fd5b6145c1613669565b6145ca836140ba565b81526145d86020840161454c565b60208201526040830151828111156145ef57600080fd5b6145fb87828601613f2e565b60408301525061460d60608401614557565b606082015261461e608084016140ba565b608082015261462f60a08401614562565b60a082015261464060c0840161454c565b60c082015261465160e08401614557565b60e0820152610100614664818501613f03565b90820152610120838101518381111561467c57600080fd5b61468888828701613f2e565b918301919091525095945050505050565b6000602082840312156146ab57600080fd5b815161173881613891565b600063ffffffff80831681810361412757614127613ea0565b60208152600082516101408060208501526146ee610160850183613a36565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261472a8483613a36565b935060408701519150614755606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e08701526147b68483613a36565b935060e087015191506101008187860301818801526147d58584613a36565b9450808801519250506101208187860301818801526147f48584613a36565b94508088015192505050614817828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561485957614859613ea0565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261489c5761489c61485e565b500490565b818103600083128015838313168383128216171561350457613504613ea0565b6000826148d0576148d061485e565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561492457614924613ea0565b500590565b808201828112600083128015821682158216171561494957614949613ea0565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406e5761406e613ea0565b60007f800000000000000000000000000000000000000000000000000000000000000082036141c1576141c1613ea0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f821115614a2857600081815260208120601f850160051c81016020861015614a095750805b601f850160051c820191505b8181101561280057828155600101614a15565b505050565b815167ffffffffffffffff811115614a4757614a4761363a565b614a5b81614a5584546141e7565b846149e2565b602080601f831160018114614aae5760008415614a785750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555612800565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015614afb57888601518255948401946001909101908401614adc565b5085821015614b3757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", +} + +var VerifiableLoadLogTriggerUpkeepABI = VerifiableLoadLogTriggerUpkeepMetaData.ABI + +var VerifiableLoadLogTriggerUpkeepBin = VerifiableLoadLogTriggerUpkeepMetaData.Bin + +func DeployVerifiableLoadLogTriggerUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, _useArb bool) (common.Address, *types.Transaction, *VerifiableLoadLogTriggerUpkeep, error) { + parsed, err := VerifiableLoadLogTriggerUpkeepMetaData.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(VerifiableLoadLogTriggerUpkeepBin), backend, _registrar, _useArb) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &VerifiableLoadLogTriggerUpkeep{VerifiableLoadLogTriggerUpkeepCaller: VerifiableLoadLogTriggerUpkeepCaller{contract: contract}, VerifiableLoadLogTriggerUpkeepTransactor: VerifiableLoadLogTriggerUpkeepTransactor{contract: contract}, VerifiableLoadLogTriggerUpkeepFilterer: VerifiableLoadLogTriggerUpkeepFilterer{contract: contract}}, nil +} + +type VerifiableLoadLogTriggerUpkeep struct { + address common.Address + abi abi.ABI + VerifiableLoadLogTriggerUpkeepCaller + VerifiableLoadLogTriggerUpkeepTransactor + VerifiableLoadLogTriggerUpkeepFilterer +} + +type VerifiableLoadLogTriggerUpkeepCaller struct { + contract *bind.BoundContract +} + +type VerifiableLoadLogTriggerUpkeepTransactor struct { + contract *bind.BoundContract +} + +type VerifiableLoadLogTriggerUpkeepFilterer struct { + contract *bind.BoundContract +} + +type VerifiableLoadLogTriggerUpkeepSession struct { + Contract *VerifiableLoadLogTriggerUpkeep + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type VerifiableLoadLogTriggerUpkeepCallerSession struct { + Contract *VerifiableLoadLogTriggerUpkeepCaller + CallOpts bind.CallOpts +} + +type VerifiableLoadLogTriggerUpkeepTransactorSession struct { + Contract *VerifiableLoadLogTriggerUpkeepTransactor + TransactOpts bind.TransactOpts +} + +type VerifiableLoadLogTriggerUpkeepRaw struct { + Contract *VerifiableLoadLogTriggerUpkeep +} + +type VerifiableLoadLogTriggerUpkeepCallerRaw struct { + Contract *VerifiableLoadLogTriggerUpkeepCaller +} + +type VerifiableLoadLogTriggerUpkeepTransactorRaw struct { + Contract *VerifiableLoadLogTriggerUpkeepTransactor +} + +func NewVerifiableLoadLogTriggerUpkeep(address common.Address, backend bind.ContractBackend) (*VerifiableLoadLogTriggerUpkeep, error) { + abi, err := abi.JSON(strings.NewReader(VerifiableLoadLogTriggerUpkeepABI)) + if err != nil { + return nil, err + } + contract, err := bindVerifiableLoadLogTriggerUpkeep(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeep{address: address, abi: abi, VerifiableLoadLogTriggerUpkeepCaller: VerifiableLoadLogTriggerUpkeepCaller{contract: contract}, VerifiableLoadLogTriggerUpkeepTransactor: VerifiableLoadLogTriggerUpkeepTransactor{contract: contract}, VerifiableLoadLogTriggerUpkeepFilterer: VerifiableLoadLogTriggerUpkeepFilterer{contract: contract}}, nil +} + +func NewVerifiableLoadLogTriggerUpkeepCaller(address common.Address, caller bind.ContractCaller) (*VerifiableLoadLogTriggerUpkeepCaller, error) { + contract, err := bindVerifiableLoadLogTriggerUpkeep(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepCaller{contract: contract}, nil +} + +func NewVerifiableLoadLogTriggerUpkeepTransactor(address common.Address, transactor bind.ContractTransactor) (*VerifiableLoadLogTriggerUpkeepTransactor, error) { + contract, err := bindVerifiableLoadLogTriggerUpkeep(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepTransactor{contract: contract}, nil +} + +func NewVerifiableLoadLogTriggerUpkeepFilterer(address common.Address, filterer bind.ContractFilterer) (*VerifiableLoadLogTriggerUpkeepFilterer, error) { + contract, err := bindVerifiableLoadLogTriggerUpkeep(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepFilterer{contract: contract}, nil +} + +func bindVerifiableLoadLogTriggerUpkeep(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := VerifiableLoadLogTriggerUpkeepMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VerifiableLoadLogTriggerUpkeep.Contract.VerifiableLoadLogTriggerUpkeepCaller.contract.Call(opts, result, method, params...) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.VerifiableLoadLogTriggerUpkeepTransactor.contract.Transfer(opts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.VerifiableLoadLogTriggerUpkeepTransactor.contract.Transact(opts, method, params...) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VerifiableLoadLogTriggerUpkeep.Contract.contract.Call(opts, result, method, params...) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.contract.Transfer(opts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.contract.Transact(opts, method, params...) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) BUCKETSIZE(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "BUCKET_SIZE") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BUCKETSIZE() (uint16, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BUCKETSIZE(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) BUCKETSIZE() (uint16, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BUCKETSIZE(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "addLinkAmount") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) AddLinkAmount() (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AddLinkAmount(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) AddLinkAmount() (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AddLinkAmount(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) BucketedDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "bucketedDelays", arg0, arg1, arg2) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BucketedDelays(arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BucketedDelays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0, arg1, arg2) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) BucketedDelays(arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BucketedDelays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0, arg1, arg2) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Buckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "buckets", arg0) + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Buckets(arg0 *big.Int) (uint16, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Buckets(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Buckets(arg0 *big.Int) (uint16, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Buckets(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (bool, []byte, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "checkCallback", values, extraData) + + if err != nil { + return *new(bool), *new([]byte), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + out1 := *abi.ConvertType(out[1], new([]byte)).(*[]byte) + + return out0, out1, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) CheckCallback(values [][]byte, extraData []byte) (bool, []byte, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CheckCallback(&_VerifiableLoadLogTriggerUpkeep.CallOpts, values, extraData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) CheckCallback(values [][]byte, extraData []byte) (bool, []byte, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CheckCallback(&_VerifiableLoadLogTriggerUpkeep.CallOpts, values, extraData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) CheckGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "checkGasToBurns", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) CheckGasToBurns(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CheckGasToBurns(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) CheckGasToBurns(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CheckGasToBurns(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Counters(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "counters", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Counters(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Counters(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Counters(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Counters(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Delays(opts *bind.CallOpts, arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "delays", arg0, arg1) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Delays(arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Delays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0, arg1) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Delays(arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Delays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0, arg1) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) DummyMap(opts *bind.CallOpts, arg0 [32]byte) (bool, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "dummyMap", arg0) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) DummyMap(arg0 [32]byte) (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.DummyMap(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) DummyMap(arg0 [32]byte) (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.DummyMap(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Eligible(opts *bind.CallOpts, upkeepId *big.Int) (bool, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "eligible", upkeepId) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Eligible(upkeepId *big.Int) (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Eligible(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Eligible(upkeepId *big.Int) (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Eligible(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) EmittedSig(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "emittedSig") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) EmittedSig() ([32]byte, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.EmittedSig(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) EmittedSig() ([32]byte, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.EmittedSig(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) FeedParamKey(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "feedParamKey") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) FeedParamKey() (string, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.FeedParamKey(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) FeedParamKey() (string, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.FeedParamKey(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) FeedsHex(opts *bind.CallOpts, arg0 *big.Int) (string, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "feedsHex", arg0) + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) FeedsHex(arg0 *big.Int) (string, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.FeedsHex(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) FeedsHex(arg0 *big.Int) (string, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.FeedsHex(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) FirstPerformBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "firstPerformBlocks", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) FirstPerformBlocks(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.FirstPerformBlocks(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) FirstPerformBlocks(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.FirstPerformBlocks(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GasLimits(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "gasLimits", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GasLimits(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GasLimits(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GasLimits(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GasLimits(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetActiveUpkeepIDs(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getActiveUpkeepIDs", startIndex, maxCount) + + if err != nil { + return *new([]*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetActiveUpkeepIDs(startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetActiveUpkeepIDs(&_VerifiableLoadLogTriggerUpkeep.CallOpts, startIndex, maxCount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetActiveUpkeepIDs(startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetActiveUpkeepIDs(&_VerifiableLoadLogTriggerUpkeep.CallOpts, startIndex, maxCount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetBucketedDelays(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) ([]*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getBucketedDelays", upkeepId, bucket) + + if err != nil { + return *new([]*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetBucketedDelays(upkeepId *big.Int, bucket uint16) ([]*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetBucketedDelays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, bucket) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetBucketedDelays(upkeepId *big.Int, bucket uint16) ([]*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetBucketedDelays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, bucket) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetBucketedDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getBucketedDelaysLength", upkeepId) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetBucketedDelaysLength(upkeepId *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetBucketedDelaysLength(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetBucketedDelaysLength(upkeepId *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetBucketedDelaysLength(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetDelays(opts *bind.CallOpts, upkeepId *big.Int) ([]*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getDelays", upkeepId) + + if err != nil { + return *new([]*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetDelays(upkeepId *big.Int) ([]*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetDelays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetDelays(upkeepId *big.Int) ([]*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetDelays(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getDelaysLength", upkeepId) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetDelaysLength(upkeepId *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetDelaysLength(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetDelaysLength(upkeepId *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetDelaysLength(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetLogTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getLogTriggerConfig", upkeepId) + + if err != nil { + return *new([]byte), err + } + + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetLogTriggerConfig(upkeepId *big.Int) ([]byte, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetLogTriggerConfig(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetLogTriggerConfig(upkeepId *big.Int) ([]byte, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetLogTriggerConfig(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetPxDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getPxDelayLastNPerforms", upkeepId, p, n) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetPxDelayLastNPerforms(upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetPxDelayLastNPerforms(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, p, n) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetPxDelayLastNPerforms(upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetPxDelayLastNPerforms(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, p, n) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetSumDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getSumDelayInBucket", upkeepId, bucket) + + if err != nil { + return *new(*big.Int), *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + + return out0, out1, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetSumDelayInBucket(upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetSumDelayInBucket(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, bucket) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetSumDelayInBucket(upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetSumDelayInBucket(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, bucket) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) GetSumDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "getSumDelayLastNPerforms", upkeepId, n) + + if err != nil { + return *new(*big.Int), *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + + return out0, out1, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) GetSumDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetSumDelayLastNPerforms(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, n) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) GetSumDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.GetSumDelayLastNPerforms(&_VerifiableLoadLogTriggerUpkeep.CallOpts, upkeepId, n) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Intervals(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "intervals", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Intervals(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Intervals(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Intervals(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Intervals(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) LastTopUpBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "lastTopUpBlocks", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) LastTopUpBlocks(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.LastTopUpBlocks(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) LastTopUpBlocks(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.LastTopUpBlocks(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) LinkToken(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "linkToken") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) LinkToken() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.LinkToken(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) LinkToken() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.LinkToken(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) MinBalanceThresholdMultiplier(opts *bind.CallOpts) (uint8, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "minBalanceThresholdMultiplier") + + if err != nil { + return *new(uint8), err + } + + out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) MinBalanceThresholdMultiplier() (uint8, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.MinBalanceThresholdMultiplier(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) MinBalanceThresholdMultiplier() (uint8, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.MinBalanceThresholdMultiplier(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Owner() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Owner(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Owner() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Owner(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) PerformDataSizes(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "performDataSizes", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) PerformDataSizes(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PerformDataSizes(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) PerformDataSizes(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PerformDataSizes(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) PerformGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "performGasToBurns", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) PerformGasToBurns(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PerformGasToBurns(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) PerformGasToBurns(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PerformGasToBurns(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) PreviousPerformBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "previousPerformBlocks", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) PreviousPerformBlocks(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PreviousPerformBlocks(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) PreviousPerformBlocks(arg0 *big.Int) (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PreviousPerformBlocks(&_VerifiableLoadLogTriggerUpkeep.CallOpts, arg0) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Registrar(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "registrar") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Registrar() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Registrar(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Registrar() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Registrar(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) Registry(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "registry") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Registry() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Registry(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) Registry() (common.Address, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Registry(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) TimeParamKey(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "timeParamKey") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) TimeParamKey() (string, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.TimeParamKey(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) TimeParamKey() (string, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.TimeParamKey(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "upkeepTopUpCheckInterval") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) UpkeepTopUpCheckInterval() (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) UpkeepTopUpCheckInterval() (*big.Int, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "useArbitrumBlockNum") + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) UseArbitrumBlockNum() (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) UseArbitrumBlockNum() (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "acceptOwnership") +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AcceptOwnership(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AcceptOwnership(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "addFunds", upkeepId, amount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AddFunds(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, amount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AddFunds(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, amount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "batchCancelUpkeeps", upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "batchRegisterUpkeeps", number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BatchSendLogs(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "batchSendLogs") +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BatchSendLogs() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchSendLogs(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BatchSendLogs() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchSendLogs(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BatchSetIntervals(opts *bind.TransactOpts, upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "batchSetIntervals", upkeepIds, interval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BatchSetIntervals(upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchSetIntervals(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds, interval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BatchSetIntervals(upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchSetIntervals(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds, interval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BatchUpdatePipelineData(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "batchUpdatePipelineData", upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BatchUpdatePipelineData(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchUpdatePipelineData(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BatchUpdatePipelineData(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchUpdatePipelineData(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BatchWithdrawLinks(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "batchWithdrawLinks", upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BatchWithdrawLinks(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchWithdrawLinks(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BatchWithdrawLinks(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BatchWithdrawLinks(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepIds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) BurnPerformGas(opts *bind.TransactOpts, upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "burnPerformGas", upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) BurnPerformGas(upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BurnPerformGas(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) BurnPerformGas(upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.BurnPerformGas(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) CancelUpkeep(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "cancelUpkeep", upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) CancelUpkeep(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CancelUpkeep(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) CancelUpkeep(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CancelUpkeep(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) CheckLog(opts *bind.TransactOpts, log Log, checkData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "checkLog", log, checkData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) CheckLog(log Log, checkData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CheckLog(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, log, checkData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) CheckLog(log Log, checkData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.CheckLog(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, log, checkData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "performUpkeep", performData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) PerformUpkeep(performData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PerformUpkeep(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, performData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) PerformUpkeep(performData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.PerformUpkeep(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, performData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setAddLinkAmount", amount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetAddLinkAmount(amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetAddLinkAmount(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, amount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetAddLinkAmount(amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetAddLinkAmount(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, amount) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetCheckGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setCheckGasToBurn", upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetCheckGasToBurn(upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetCheckGasToBurn(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetCheckGasToBurn(upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetCheckGasToBurn(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetConfig(opts *bind.TransactOpts, newRegistrar common.Address) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setConfig", newRegistrar) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetConfig(newRegistrar common.Address) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetConfig(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newRegistrar) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetConfig(newRegistrar common.Address) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetConfig(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newRegistrar) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetFeedsHex(opts *bind.TransactOpts, newFeeds []string) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setFeedsHex", newFeeds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetFeedsHex(newFeeds []string) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetFeedsHex(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newFeeds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetFeedsHex(newFeeds []string) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetFeedsHex(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newFeeds) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetInterval(opts *bind.TransactOpts, upkeepId *big.Int, _interval *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setInterval", upkeepId, _interval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetInterval(upkeepId *big.Int, _interval *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetInterval(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, _interval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetInterval(upkeepId *big.Int, _interval *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetInterval(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, _interval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetMinBalanceThresholdMultiplier(opts *bind.TransactOpts, newMinBalanceThresholdMultiplier uint8) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setMinBalanceThresholdMultiplier", newMinBalanceThresholdMultiplier) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetMinBalanceThresholdMultiplier(newMinBalanceThresholdMultiplier uint8) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetMinBalanceThresholdMultiplier(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newMinBalanceThresholdMultiplier) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetMinBalanceThresholdMultiplier(newMinBalanceThresholdMultiplier uint8) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetMinBalanceThresholdMultiplier(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newMinBalanceThresholdMultiplier) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetPerformDataSize(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setPerformDataSize", upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetPerformDataSize(upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetPerformDataSize(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetPerformDataSize(upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetPerformDataSize(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetPerformGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setPerformGasToBurn", upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetPerformGasToBurn(upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetPerformGasToBurn(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetPerformGasToBurn(upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetPerformGasToBurn(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, value) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetUpkeepGasLimit(opts *bind.TransactOpts, upkeepId *big.Int, gasLimit uint32) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setUpkeepGasLimit", upkeepId, gasLimit) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetUpkeepGasLimit(upkeepId *big.Int, gasLimit uint32) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetUpkeepGasLimit(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, gasLimit) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetUpkeepGasLimit(upkeepId *big.Int, gasLimit uint32) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetUpkeepGasLimit(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, gasLimit) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetUpkeepTopUpCheckInterval(opts *bind.TransactOpts, newInterval *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setUpkeepTopUpCheckInterval", newInterval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetUpkeepTopUpCheckInterval(newInterval *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetUpkeepTopUpCheckInterval(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newInterval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetUpkeepTopUpCheckInterval(newInterval *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetUpkeepTopUpCheckInterval(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newInterval) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "topUpFund", upkeepId, blockNum) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) TopUpFund(upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.TopUpFund(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, blockNum) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) TopUpFund(upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.TopUpFund(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, blockNum) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "transferOwnership", to) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.TransferOwnership(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, to) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.TransferOwnership(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, to) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) UpdateUpkeepPipelineData(opts *bind.TransactOpts, upkeepId *big.Int, pipelineData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "updateUpkeepPipelineData", upkeepId, pipelineData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) UpdateUpkeepPipelineData(upkeepId *big.Int, pipelineData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UpdateUpkeepPipelineData(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, pipelineData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) UpdateUpkeepPipelineData(upkeepId *big.Int, pipelineData []byte) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UpdateUpkeepPipelineData(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId, pipelineData) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) WithdrawLinks(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "withdrawLinks") +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) WithdrawLinks() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.WithdrawLinks(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) WithdrawLinks() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.WithdrawLinks(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) WithdrawLinks0(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "withdrawLinks0", upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.RawTransact(opts, nil) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) Receive() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Receive(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) Receive() (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.Receive(&_VerifiableLoadLogTriggerUpkeep.TransactOpts) +} + +type VerifiableLoadLogTriggerUpkeepLogEmittedIterator struct { + Event *VerifiableLoadLogTriggerUpkeepLogEmitted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifiableLoadLogTriggerUpkeepLogEmittedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifiableLoadLogTriggerUpkeepLogEmitted) + 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(VerifiableLoadLogTriggerUpkeepLogEmitted) + 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 *VerifiableLoadLogTriggerUpkeepLogEmittedIterator) Error() error { + return it.fail +} + +func (it *VerifiableLoadLogTriggerUpkeepLogEmittedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifiableLoadLogTriggerUpkeepLogEmitted struct { + UpkeepId *big.Int + BlockNum *big.Int + Addr common.Address + Raw types.Log +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) FilterLogEmitted(opts *bind.FilterOpts, upkeepId []*big.Int, blockNum []*big.Int) (*VerifiableLoadLogTriggerUpkeepLogEmittedIterator, error) { + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + var blockNumRule []interface{} + for _, blockNumItem := range blockNum { + blockNumRule = append(blockNumRule, blockNumItem) + } + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.FilterLogs(opts, "LogEmitted", upkeepIdRule, blockNumRule) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepLogEmittedIterator{contract: _VerifiableLoadLogTriggerUpkeep.contract, event: "LogEmitted", logs: logs, sub: sub}, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) WatchLogEmitted(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepLogEmitted, upkeepId []*big.Int, blockNum []*big.Int) (event.Subscription, error) { + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + var blockNumRule []interface{} + for _, blockNumItem := range blockNum { + blockNumRule = append(blockNumRule, blockNumItem) + } + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.WatchLogs(opts, "LogEmitted", upkeepIdRule, blockNumRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifiableLoadLogTriggerUpkeepLogEmitted) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "LogEmitted", 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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) ParseLogEmitted(log types.Log) (*VerifiableLoadLogTriggerUpkeepLogEmitted, error) { + event := new(VerifiableLoadLogTriggerUpkeepLogEmitted) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "LogEmitted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator struct { + Event *VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested) + 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(VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested) + 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 *VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator{contract: _VerifiableLoadLogTriggerUpkeep.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested, error) { + event := new(VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator struct { + Event *VerifiableLoadLogTriggerUpkeepOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifiableLoadLogTriggerUpkeepOwnershipTransferred) + 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(VerifiableLoadLogTriggerUpkeepOwnershipTransferred) + 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 *VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifiableLoadLogTriggerUpkeepOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator{contract: _VerifiableLoadLogTriggerUpkeep.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifiableLoadLogTriggerUpkeepOwnershipTransferred) + if err := _VerifiableLoadLogTriggerUpkeep.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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) ParseOwnershipTransferred(log types.Log) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferred, error) { + event := new(VerifiableLoadLogTriggerUpkeepOwnershipTransferred) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifiableLoadLogTriggerUpkeepReceivedIterator struct { + Event *VerifiableLoadLogTriggerUpkeepReceived + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifiableLoadLogTriggerUpkeepReceivedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifiableLoadLogTriggerUpkeepReceived) + 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(VerifiableLoadLogTriggerUpkeepReceived) + 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 *VerifiableLoadLogTriggerUpkeepReceivedIterator) Error() error { + return it.fail +} + +func (it *VerifiableLoadLogTriggerUpkeepReceivedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifiableLoadLogTriggerUpkeepReceived struct { + Sender common.Address + Value *big.Int + Raw types.Log +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadLogTriggerUpkeepReceivedIterator, error) { + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.FilterLogs(opts, "Received") + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepReceivedIterator{contract: _VerifiableLoadLogTriggerUpkeep.contract, event: "Received", logs: logs, sub: sub}, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepReceived) (event.Subscription, error) { + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.WatchLogs(opts, "Received") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifiableLoadLogTriggerUpkeepReceived) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "Received", 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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) ParseReceived(log types.Log) (*VerifiableLoadLogTriggerUpkeepReceived, error) { + event := new(VerifiableLoadLogTriggerUpkeepReceived) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "Received", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator struct { + Event *VerifiableLoadLogTriggerUpkeepUpkeepTopUp + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifiableLoadLogTriggerUpkeepUpkeepTopUp) + 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(VerifiableLoadLogTriggerUpkeepUpkeepTopUp) + 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 *VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator) Error() error { + return it.fail +} + +func (it *VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifiableLoadLogTriggerUpkeepUpkeepTopUp struct { + UpkeepId *big.Int + Amount *big.Int + BlockNum *big.Int + Raw types.Log +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator, error) { + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.FilterLogs(opts, "UpkeepTopUp") + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator{contract: _VerifiableLoadLogTriggerUpkeep.contract, event: "UpkeepTopUp", logs: logs, sub: sub}, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepUpkeepTopUp) (event.Subscription, error) { + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.WatchLogs(opts, "UpkeepTopUp") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifiableLoadLogTriggerUpkeepUpkeepTopUp) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "UpkeepTopUp", 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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadLogTriggerUpkeepUpkeepTopUp, error) { + event := new(VerifiableLoadLogTriggerUpkeepUpkeepTopUp) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator struct { + Event *VerifiableLoadLogTriggerUpkeepUpkeepsRegistered + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) + 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(VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) + 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 *VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator) Error() error { + return it.fail +} + +func (it *VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifiableLoadLogTriggerUpkeepUpkeepsRegistered struct { + UpkeepIds []*big.Int + Raw types.Log +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) FilterUpkeepsRegistered(opts *bind.FilterOpts) (*VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator, error) { + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.FilterLogs(opts, "UpkeepsRegistered") + if err != nil { + return nil, err + } + return &VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator{contract: _VerifiableLoadLogTriggerUpkeep.contract, event: "UpkeepsRegistered", logs: logs, sub: sub}, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) WatchUpkeepsRegistered(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) (event.Subscription, error) { + + logs, sub, err := _VerifiableLoadLogTriggerUpkeep.contract.WatchLogs(opts, "UpkeepsRegistered") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "UpkeepsRegistered", 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 (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepFilterer) ParseUpkeepsRegistered(log types.Log) (*VerifiableLoadLogTriggerUpkeepUpkeepsRegistered, error) { + event := new(VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) + if err := _VerifiableLoadLogTriggerUpkeep.contract.UnpackLog(event, "UpkeepsRegistered", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeep) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _VerifiableLoadLogTriggerUpkeep.abi.Events["LogEmitted"].ID: + return _VerifiableLoadLogTriggerUpkeep.ParseLogEmitted(log) + case _VerifiableLoadLogTriggerUpkeep.abi.Events["OwnershipTransferRequested"].ID: + return _VerifiableLoadLogTriggerUpkeep.ParseOwnershipTransferRequested(log) + case _VerifiableLoadLogTriggerUpkeep.abi.Events["OwnershipTransferred"].ID: + return _VerifiableLoadLogTriggerUpkeep.ParseOwnershipTransferred(log) + case _VerifiableLoadLogTriggerUpkeep.abi.Events["Received"].ID: + return _VerifiableLoadLogTriggerUpkeep.ParseReceived(log) + case _VerifiableLoadLogTriggerUpkeep.abi.Events["UpkeepTopUp"].ID: + return _VerifiableLoadLogTriggerUpkeep.ParseUpkeepTopUp(log) + case _VerifiableLoadLogTriggerUpkeep.abi.Events["UpkeepsRegistered"].ID: + return _VerifiableLoadLogTriggerUpkeep.ParseUpkeepsRegistered(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (VerifiableLoadLogTriggerUpkeepLogEmitted) Topic() common.Hash { + return common.HexToHash("0x97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf08") +} + +func (VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (VerifiableLoadLogTriggerUpkeepOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (VerifiableLoadLogTriggerUpkeepReceived) Topic() common.Hash { + return common.HexToHash("0x88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874") +} + +func (VerifiableLoadLogTriggerUpkeepUpkeepTopUp) Topic() common.Hash { + return common.HexToHash("0x49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c0") +} + +func (VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) Topic() common.Hash { + return common.HexToHash("0x2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711") +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeep) Address() common.Address { + return _VerifiableLoadLogTriggerUpkeep.address +} + +type VerifiableLoadLogTriggerUpkeepInterface interface { + BUCKETSIZE(opts *bind.CallOpts) (uint16, error) + + AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) + + BucketedDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) + + Buckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) + + CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (bool, []byte, error) + + CheckGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + Counters(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + Delays(opts *bind.CallOpts, arg0 *big.Int, arg1 *big.Int) (*big.Int, error) + + DummyMap(opts *bind.CallOpts, arg0 [32]byte) (bool, error) + + Eligible(opts *bind.CallOpts, upkeepId *big.Int) (bool, error) + + EmittedSig(opts *bind.CallOpts) ([32]byte, error) + + FeedParamKey(opts *bind.CallOpts) (string, error) + + FeedsHex(opts *bind.CallOpts, arg0 *big.Int) (string, error) + + FirstPerformBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + GasLimits(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + GetActiveUpkeepIDs(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) + + GetBucketedDelays(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) ([]*big.Int, error) + + GetBucketedDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) + + GetDelays(opts *bind.CallOpts, upkeepId *big.Int) ([]*big.Int, error) + + GetDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) + + GetLogTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) + + GetPxDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) + + GetSumDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) + + GetSumDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) + + Intervals(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + LastTopUpBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + LinkToken(opts *bind.CallOpts) (common.Address, error) + + MinBalanceThresholdMultiplier(opts *bind.CallOpts) (uint8, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + PerformDataSizes(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + PerformGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + PreviousPerformBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) + + Registrar(opts *bind.CallOpts) (common.Address, error) + + Registry(opts *bind.CallOpts) (common.Address, error) + + TimeParamKey(opts *bind.CallOpts) (string, error) + + UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) + + UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) + + BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) + + BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) + + BatchSendLogs(opts *bind.TransactOpts) (*types.Transaction, error) + + BatchSetIntervals(opts *bind.TransactOpts, upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) + + BatchUpdatePipelineData(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) + + BatchWithdrawLinks(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) + + BurnPerformGas(opts *bind.TransactOpts, upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) + + CancelUpkeep(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) + + CheckLog(opts *bind.TransactOpts, log Log, checkData []byte) (*types.Transaction, error) + + PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) + + SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + + SetCheckGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) + + SetConfig(opts *bind.TransactOpts, newRegistrar common.Address) (*types.Transaction, error) + + SetFeedsHex(opts *bind.TransactOpts, newFeeds []string) (*types.Transaction, error) + + SetInterval(opts *bind.TransactOpts, upkeepId *big.Int, _interval *big.Int) (*types.Transaction, error) + + SetMinBalanceThresholdMultiplier(opts *bind.TransactOpts, newMinBalanceThresholdMultiplier uint8) (*types.Transaction, error) + + SetPerformDataSize(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) + + SetPerformGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) + + SetUpkeepGasLimit(opts *bind.TransactOpts, upkeepId *big.Int, gasLimit uint32) (*types.Transaction, error) + + SetUpkeepTopUpCheckInterval(opts *bind.TransactOpts, newInterval *big.Int) (*types.Transaction, error) + + TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + UpdateUpkeepPipelineData(opts *bind.TransactOpts, upkeepId *big.Int, pipelineData []byte) (*types.Transaction, error) + + WithdrawLinks(opts *bind.TransactOpts) (*types.Transaction, error) + + WithdrawLinks0(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) + + Receive(opts *bind.TransactOpts) (*types.Transaction, error) + + FilterLogEmitted(opts *bind.FilterOpts, upkeepId []*big.Int, blockNum []*big.Int) (*VerifiableLoadLogTriggerUpkeepLogEmittedIterator, error) + + WatchLogEmitted(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepLogEmitted, upkeepId []*big.Int, blockNum []*big.Int) (event.Subscription, error) + + ParseLogEmitted(log types.Log) (*VerifiableLoadLogTriggerUpkeepLogEmitted, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*VerifiableLoadLogTriggerUpkeepOwnershipTransferred, error) + + FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadLogTriggerUpkeepReceivedIterator, error) + + WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepReceived) (event.Subscription, error) + + ParseReceived(log types.Log) (*VerifiableLoadLogTriggerUpkeepReceived, error) + + FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadLogTriggerUpkeepUpkeepTopUpIterator, error) + + WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepUpkeepTopUp) (event.Subscription, error) + + ParseUpkeepTopUp(log types.Log) (*VerifiableLoadLogTriggerUpkeepUpkeepTopUp, error) + + FilterUpkeepsRegistered(opts *bind.FilterOpts) (*VerifiableLoadLogTriggerUpkeepUpkeepsRegisteredIterator, error) + + WatchUpkeepsRegistered(opts *bind.WatchOpts, sink chan<- *VerifiableLoadLogTriggerUpkeepUpkeepsRegistered) (event.Subscription, error) + + ParseUpkeepsRegistered(log types.Log) (*VerifiableLoadLogTriggerUpkeepUpkeepsRegistered, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go index dcaf739c1bb..e517a0d92ce 100644 --- a/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go @@ -31,8 +31,8 @@ var ( ) var VerifiableLoadMercuryUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registrarAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"InsufficientFunds\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"origin\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"v0\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"ed\",\"type\":\"bytes\"}],\"name\":\"MercuryPerformEvent\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"uint256\",\"name\":\"firstPerformBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"lastBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"counter\",\"type\":\"uint256\"}],\"name\":\"PerformingUpkeep\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"RegistrarSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsCancelled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"TIMESTAMP_INTERVAL\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkDatas\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getDelaysLengthAtBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getDelaysLengthAtTimestampBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"}],\"name\":\"getPxBucketedDelaysForAllUpkeeps\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"}],\"name\":\"getPxDelayForAllUpkeeps\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getPxDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getPxDelayInTimestampBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumBucketedDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInTimestampBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumTimestampBucketedDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTimestampBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getTimestampDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractKeeperRegistrar2_0\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractKeeperRegistrar2_0\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"timestampBuckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"timestampDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"timestamps\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x6005601855601980546001600160681b0319166c140000000002c68af0bb140000179055601960f21b60a05260e160f41b60c0526101c0604052604261014081815260e09182919062005da261016039815260200160405180608001604052806042815260200162005de460429139815260200160405180608001604052806042815260200162005e266042913990526200009f90601a9060036200036e565b50348015620000ad57600080fd5b5060405162005e6838038062005e68833981016040819052620000d091620004f1565b81813380600081620001295760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156200015c576200015c81620002c2565b5050601580546001600160a01b0319166001600160a01b0385169081179091556040805163850af0cb60e01b815290516000935063850af0cb9160048082019260a092909190829003018186803b158015620001b757600080fd5b505afa158015620001cc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001f291906200055b565b50601780546001600160a01b0319166001600160a01b038381169190911790915560155460408051631b6b6d2360e01b8152905193975091169450631b6b6d2393506004808201935060209291829003018186803b1580156200025457600080fd5b505afa15801562000269573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200028f919062000534565b601680546001600160a01b0319166001600160a01b039290921691909117905550151560f81b608052506200061e915050565b6001600160a01b0381163314156200031d5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000120565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003c0579160200282015b82811115620003c05782518051620003af918491602090910190620003d2565b50916020019190600101906200038f565b50620003ce9291506200045d565b5090565b828054620003e090620005cb565b90600052602060002090601f0160209004810192826200040457600085556200044f565b82601f106200041f57805160ff19168380011785556200044f565b828001600101855582156200044f579182015b828111156200044f57825182559160200191906001019062000432565b50620003ce9291506200047e565b80821115620003ce57600062000474828262000495565b506001016200045d565b5b80821115620003ce57600081556001016200047f565b508054620004a390620005cb565b6000825580601f10620004b4575050565b601f016020900490600052602060002090810190620004d491906200047e565b50565b805163ffffffff81168114620004ec57600080fd5b919050565b600080604083850312156200050557600080fd5b8251620005128162000608565b602084015190925080151581146200052957600080fd5b809150509250929050565b6000602082840312156200054757600080fd5b8151620005548162000608565b9392505050565b600080600080600060a086880312156200057457600080fd5b8551600381106200058457600080fd5b94506200059460208701620004d7565b9350620005a460408701620004d7565b92506060860151620005b68162000608565b80925050608086015190509295509295909350565b600181811c90821680620005e057607f821691505b602082108114156200060257634e487b7160e01b600052602260045260246000fd5b50919050565b6001600160a01b0381168114620004d457600080fd5b60805160f81c60a05160f01c60c05160f01c6157366200066c600039600081816106f40152611b480152600081816105cc0152611c5c0152600081816109d10152613ba801526157366000f3fe6080604052600436106104f05760003560e01c80637b10399911610294578063a79c40431161015e578063d6051a72116100d6578063f2fde38b1161008a578063fba7ffa31161006f578063fba7ffa314611134578063fbfb4f7614611161578063fcdc1f631461118157600080fd5b8063f2fde38b146110f4578063fb0ceb041461111457600080fd5b8063dbef701e116100bb578063dbef701e14611091578063e0114adb146110b1578063e4553083146110de57600080fd5b8063d6051a7214611051578063daee1aeb1461107157600080fd5b8063becde0e11161012d578063c804802211610112578063c804802214610f89578063c98f10b014610fa9578063d355852814610ff257600080fd5b8063becde0e114610f0f578063c357f1f314610f2f57600080fd5b8063a79c404314610e3b578063af953a4a14610e68578063afb28d1f14610e88578063b0971e1a14610ed157600080fd5b8063948108f71161020c5780639d385eaa116101c0578063a5f58934116101a5578063a5f5893414610ddb578063a6c60d8914610dfb578063a72aa27e14610e1b57600080fd5b80639d385eaa14610d9b5780639d6f1cc714610dbb57600080fd5b80639ac542eb116101f15780639ac542eb14610d015780639b42935414610d3d5780639b51fb0d14610d6a57600080fd5b8063948108f714610cc157806399cc6b0b14610ce157600080fd5b806387dfa900116102635780638da5cb5b116102485780638da5cb5b14610c495780638fcb3fba14610c745780639095aa3514610ca157600080fd5b806387dfa90014610c095780638bc7b77214610c2957600080fd5b80637b10399914610b7c5780637e4087b814610ba95780637e7a46dc14610bc95780638237831714610be957600080fd5b80634b56a42e116103d5578063643b34e91161034d5780637145f11b1161030157806376721303116102e65780637672130314610b1a578063776898c814610b4757806379ba509714610b6757600080fd5b80637145f11b14610abd57806373644cce14610aed57600080fd5b806369e9b7731161033257806369e9b77314610a505780636e04ff0d14610a7d5780637137a70214610a9d57600080fd5b8063643b34e914610a0357806369cdbadb14610a2357600080fd5b80635d4ee7f3116103a457806360457ff51161038957806360457ff514610950578063636092e81461097d578063642f6cef146109bf57600080fd5b80635d4ee7f31461091b5780635f17e6161461093057600080fd5b80634b56a42e1461087357806351c98be3146108a157806357970e93146108c157806358c52c04146108ee57600080fd5b806329f0e4961161046857806333774d1c116104375780634585e33b1161041c5780634585e33b1461080657806345d2ec171461082657806346e7a63e1461084657600080fd5b806333774d1c146107b55780633ebe8d6c146107e657600080fd5b806329f0e496146106e25780632a9032d3146107165780632b20e39714610736578063328ffd111461078857600080fd5b8063177b0eb9116104bf578063206c32e8116104a4578063206c32e81461066d57806320e3dbd4146106a257806328c4b57b146106c257600080fd5b8063177b0eb9146106015780631bee00801461063f57600080fd5b806305e251311461053457806306e3b63214610556578063077ac6211461058c57806312c55027146105ba57600080fd5b3661052f57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561054057600080fd5b5061055461054f366004614668565b6111ae565b005b34801561056257600080fd5b50610576610571366004614aa7565b6111c5565b6040516105839190614d92565b60405180910390f35b34801561059857600080fd5b506105ac6105a7366004614a72565b6112c1565b604051908152602001610583565b3480156105c657600080fd5b506105ee7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610583565b34801561060d57600080fd5b506105ac61061c366004614a46565b6000918252600f6020908152604080842061ffff93909316845291905290205490565b34801561064b57600080fd5b5061065f61065a3660046147e7565b6112ff565b604051610583929190614da5565b34801561067957600080fd5b5061068d610688366004614a46565b611608565b60408051928352602083019190915201610583565b3480156106ae57600080fd5b506105546106bd366004614571565b61168b565b3480156106ce57600080fd5b506105ac6106dd366004614afe565b6118ac565b3480156106ee57600080fd5b506105ee7f000000000000000000000000000000000000000000000000000000000000000081565b34801561072257600080fd5b50610554610731366004614733565b611917565b34801561074257600080fd5b506015546107639073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610583565b34801561079457600080fd5b506105ac6107a33660046147e7565b60036020526000908152604090205481565b3480156107c157600080fd5b506105ee6107d03660046147e7565b60116020526000908152604090205461ffff1681565b3480156107f257600080fd5b506105ac6108013660046147e7565b6119ea565b34801561081257600080fd5b50610554610821366004614800565b611a53565b34801561083257600080fd5b50610576610841366004614a46565b612170565b34801561085257600080fd5b506105ac6108613660046147e7565b600a6020526000908152604090205481565b34801561087f57600080fd5b5061089361088e36600461458e565b6121df565b604051610583929190614dca565b3480156108ad57600080fd5b506105546108bc366004614775565b612233565b3480156108cd57600080fd5b506016546107639073ffffffffffffffffffffffffffffffffffffffff1681565b3480156108fa57600080fd5b5061090e6109093660046147e7565b6122d7565b6040516105839190614de5565b34801561092757600080fd5b50610554612371565b34801561093c57600080fd5b5061055461094b366004614aa7565b6124c6565b34801561095c57600080fd5b506105ac61096b3660046147e7565b60076020526000908152604090205481565b34801561098957600080fd5b506019546109a2906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610583565b3480156109cb57600080fd5b506109f37f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610583565b348015610a0f57600080fd5b5061068d610a1e366004614aa7565b612638565b348015610a2f57600080fd5b506105ac610a3e3660046147e7565b60086020526000908152604090205481565b348015610a5c57600080fd5b50610554610a6b366004614aa7565b60009182526008602052604090912055565b348015610a8957600080fd5b50610893610a98366004614800565b6127bd565b348015610aa957600080fd5b506105ac610ab8366004614a72565b6129d2565b348015610ac957600080fd5b506109f3610ad83660046147e7565b600c6020526000908152604090205460ff1681565b348015610af957600080fd5b506105ac610b083660046147e7565b6000908152600d602052604090205490565b348015610b2657600080fd5b506105ac610b353660046147e7565b60046020526000908152604090205481565b348015610b5357600080fd5b506109f3610b623660046147e7565b6129fa565b348015610b7357600080fd5b50610554612a4a565b348015610b8857600080fd5b506017546107639073ffffffffffffffffffffffffffffffffffffffff1681565b348015610bb557600080fd5b5061068d610bc4366004614aa7565b612b47565b348015610bd557600080fd5b50610554610be43660046149fa565b612cbf565b348015610bf557600080fd5b506105ac610c04366004614ac9565b612d6a565b348015610c1557600080fd5b506105ac610c24366004614ac9565b612de5565b348015610c3557600080fd5b5061065f610c443660046147e7565b612e55565b348015610c5557600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610763565b348015610c8057600080fd5b506105ac610c8f3660046147e7565b60056020526000908152604090205481565b348015610cad57600080fd5b50610554610cbc366004614b9a565b612fca565b348015610ccd57600080fd5b50610554610cdc366004614b5a565b61324a565b348015610ced57600080fd5b50610576610cfc366004614a46565b6133e2565b348015610d0d57600080fd5b50601954610d2b906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610583565b348015610d4957600080fd5b50610554610d58366004614aa7565b60009182526009602052604090912055565b348015610d7657600080fd5b506105ee610d853660046147e7565b60126020526000908152604090205461ffff1681565b348015610da757600080fd5b50610576610db63660046147e7565b61344f565b348015610dc757600080fd5b5061090e610dd63660046147e7565b6134b1565b348015610de757600080fd5b506105ac610df63660046147e7565b6134dc565b348015610e0757600080fd5b50610554610e163660046147e7565b601855565b348015610e2757600080fd5b50610554610e36366004614b2a565b61353d565b348015610e4757600080fd5b50610554610e56366004614aa7565b60009182526007602052604090912055565b348015610e7457600080fd5b50610554610e833660046147e7565b6135e8565b348015610e9457600080fd5b5061090e6040518060400160405280600981526020017f666565644944486578000000000000000000000000000000000000000000000081525081565b348015610edd57600080fd5b506105ac610eec366004614a46565b6000918252600e6020908152604080842061ffff93909316845291905290205490565b348015610f1b57600080fd5b50610554610f2a366004614733565b61366e565b348015610f3b57600080fd5b50610554610f4a366004614bf3565b601980547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610f9557600080fd5b50610554610fa43660046147e7565b613708565b348015610fb557600080fd5b5061090e6040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525081565b348015610ffe57600080fd5b5061055461100d366004614b7f565b6019805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b34801561105d57600080fd5b5061068d61106c366004614aa7565b6137a0565b34801561107d57600080fd5b5061055461108c366004614733565b613809565b34801561109d57600080fd5b506105ac6110ac366004614aa7565b6138d4565b3480156110bd57600080fd5b506105ac6110cc3660046147e7565b60096020526000908152604090205481565b3480156110ea57600080fd5b506105ac60185481565b34801561110057600080fd5b5061055461110f366004614571565b613905565b34801561112057600080fd5b506105ac61112f366004614aa7565b613919565b34801561114057600080fd5b506105ac61114f3660046147e7565b60066020526000908152604090205481565b34801561116d57600080fd5b5061068d61117c366004614a46565b613935565b34801561118d57600080fd5b506105ac61119c3660046147e7565b60026020526000908152604090205481565b80516111c190601a9060208401906141d5565b5050565b606060006111d360136139a9565b905080841061120e576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826112205761121d84826153fe565b92505b60008367ffffffffffffffff81111561123b5761123b6156ac565b604051908082528060200260200182016040528015611264578160200160208202803683370190505b50905060005b848110156112b65761128761127f8288615285565b6013906139b3565b8282815181106112995761129961567d565b6020908102919091010152806112ae81615584565b91505061126a565b509150505b92915050565b600e60205282600052604060002060205281600052604060002081815481106112e957600080fd5b9060005260206000200160009250925050505481565b606080600061130e60136139a9565b905060008167ffffffffffffffff81111561132b5761132b6156ac565b604051908082528060200260200182016040528015611354578160200160208202803683370190505b50905060008267ffffffffffffffff811115611372576113726156ac565b60405190808252806020026020018201604052801561139b578160200160208202803683370190505b50905060005b838110156115fc5760006113b66013836139b3565b9050808483815181106113cb576113cb61567d565b6020908102919091018101919091526000828152601290915260408082205490517f3ebe8d6c0000000000000000000000000000000000000000000000000000000081526004810184905261ffff90911691903090633ebe8d6c9060240160206040518083038186803b15801561144157600080fd5b505afa158015611455573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061147991906149e1565b905060008167ffffffffffffffff811115611496576114966156ac565b6040519080825280602002602001820160405280156114bf578160200160208202803683370190505b506000858152600e6020526040812091925090815b8561ffff168161ffff16116115b95761ffff81166000908152602083815260408083208054825181850281018501909352808352919290919083018282801561153c57602002820191906000526020600020905b815481526020019060010190808311611528575b5050505050905060005b81518110156115a4578181815181106115615761156161567d565b602002602001015186868061157590615584565b9750815181106115875761158761567d565b60209081029190910101528061159c81615584565b915050611546565b505080806115b190615562565b9150506114d4565b506115c5838e866139bf565b8888815181106115d7576115d761567d565b60200260200101818152505050505050505080806115f490615584565b9150506113a1565b50909590945092505050565b6000828152600e6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561166c57602002820191906000526020600020905b815481526020019060010190808311611658575b5050505050905061167e818251613b1f565b92509250505b9250929050565b601580547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517f850af0cb00000000000000000000000000000000000000000000000000000000815290516000929163850af0cb9160048083019260a0929190829003018186803b15801561172057600080fd5b505afa158015611734573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117589190614853565b50601780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601554604080517f1b6b6d23000000000000000000000000000000000000000000000000000000008152905193975091169450631b6b6d2393506004808201935060209291829003018186803b1580156117f757600080fd5b505afa15801561180b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061182f9190614836565b601680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff928316179055601554604051911681527f6263309d5d4d1cfececd45a387cda7f14dccde21cf7a1bee1be6561075e61014906020015b60405180910390a15050565b6000838152600d60209081526040808320805482518185028101850190935280835261190d9383018282801561190157602002820191906000526020600020905b8154815260200190600101908083116118ed575b505050505084846139bf565b90505b9392505050565b8060005b818160ff1610156119ab573063c8048022858560ff85168181106119415761194161567d565b905060200201356040518263ffffffff1660e01b815260040161196691815260200190565b600060405180830381600087803b15801561198057600080fd5b505af1158015611994573d6000803e3d6000fd5b5050505080806119a3906155d0565b91505061191b565b507fbeac20a03a6674e40498fac4356bc86e356c0d761a8d35d436712dc93bc7c74b83836040516119dd929190614d3d565b60405180910390a1505050565b60008181526012602052604081205461ffff1681805b8261ffff168161ffff1611611a4b576000858152600e6020908152604080832061ffff85168452909152902054611a379083615285565b915080611a4381615562565b915050611a00565b509392505050565b60005a9050600080611a678486018661458e565b91509150600081806020019051810190611a8191906149e1565b60008181526005602090815260408083205460049092528220549293509190611aa8613ba4565b905082611ae25760008481526005602090815260408083208490556010825282208054600181018255908352912042910155915081611d42565b600084815260036020526040812054611afb84846153fe565b611b0591906153fe565b6000868152601160209081526040808320546010909252909120805492935061ffff9091169182908110611b3b57611b3b61567d565b90600052602060002001547f000000000000000000000000000000000000000000000000000000000000000061ffff1642611b7691906153fe565b1115611be55760008681526010602090815260408220805460018101825590835291204291015580611ba781615562565b600088815260116020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559150505b600086815260126020908152604080832054600e835281842061ffff9091168085529083528184208054835181860281018601909452808452919493909190830182828015611c5357602002820191906000526020600020905b815481526020019060010190808311611c3f575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff1681511415611ccf5781611c9181615562565b60008a815260126020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600e6020908152604080832061ffff94851684528252808320805460018181018355918552838520018790558a8452600f83528184209590941683529381528382208054808501825590835281832001859055888252600d81529281208054928301815581529190912001555b600084815260066020526040812054611d5c906001615285565b6000868152600660209081526040918290208390558151878152908101859052908101859052606081018290529091507f6b6b3eeaaf107627513e76a81662118e7b1d8c78866f70760262115ddcfeede39060800160405180910390a16000858152600460209081526040808320859055601854600290925290912054611de390846153fe565b111561208e576017546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810187905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a9060240160006040518083038186803b158015611e5457600080fd5b505afa158015611e68573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611eae91908101906148c2565b6017546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810189905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c9060240160206040518083038186803b158015611f1e57600080fd5b505afa158015611f32573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f569190614c10565b601954909150611f7a9082906c01000000000000000000000000900460ff16615356565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff16101561208b576019546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018990526bffffffffffffffffffffffff9091166024820152309063948108f790604401600060405180830381600087803b15801561200b57600080fd5b505af115801561201f573d6000803e3d6000fd5b50505060008881526002602090815260409182902087905560195482518b81526bffffffffffffffffffffffff909116918101919091529081018690527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c0915060600160405180910390a15b50505b6000858152600760205260409020545b805a6120aa908b6153fe565b6120b690612710615285565b10156120f75782406000908152600c6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905561209e565b82863273ffffffffffffffffffffffffffffffffffffffff167fcad583be2d908a590c81c7e332cf11c7a4ea41ecf1e059efac3ea7e83e34f1a58b6000815181106121445761214461567d565b60200260200101518b60405161215b929190614df8565b60405180910390a45050505050505050505050565b6000828152600e6020908152604080832061ffff851684528252918290208054835181840281018401909452808452606093928301828280156121d257602002820191906000526020600020905b8154815260200190600101908083116121be575b5050505050905092915050565b60006060600084846040516020016121f8929190614cb2565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b818110156122d05730635f17e6168686848181106122575761225761567d565b90506020020135856040518363ffffffff1660e01b815260040161228b92919091825263ffffffff16602082015260400190565b600060405180830381600087803b1580156122a557600080fd5b505af11580156122b9573d6000803e3d6000fd5b5050505080806122c890615584565b915050612237565b5050505050565b600b60205260009081526040902080546122f0906154d5565b80601f016020809104026020016040519081016040528092919081815260200182805461231c906154d5565b80156123695780601f1061233e57610100808354040283529160200191612369565b820191906000526020600020905b81548152906001019060200180831161234c57829003601f168201915b505050505081565b612379613c55565b6016546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a082319060240160206040518083038186803b1580156123e357600080fd5b505afa1580156123f7573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061241b91906149e1565b6016546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb90604401602060405180830381600087803b15801561248e57600080fd5b505af11580156124a2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c191906147cc565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600d90915281206124fe91614232565b60008281526012602052604081205461ffff16905b8161ffff168161ffff161161255a576000848152600e6020908152604080832061ffff85168452909152812061254891614232565b8061255281615562565b915050612513565b5050600082815260126020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055601190915281205461ffff16905b8161ffff168161ffff16116125e8576000848152600f6020908152604080832061ffff8516845290915281206125d691614232565b806125e081615562565b9150506125a1565b50600083815260106020526040812061260091614232565b5050600090815260116020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6040517f3ebe8d6c00000000000000000000000000000000000000000000000000000000815260048101839052600090819081903090633ebe8d6c9060240160206040518083038186803b15801561268f57600080fd5b505afa1580156126a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906126c791906149e1565b90508315806126d65750808410155b156126df578093505b60008581526012602052604081205485919061ffff16805b6000898152600e6020908152604080832061ffff8516845282528083208054825181850281018501909352808352919290919083018282801561275957602002820191906000526020600020905b815481526020019060010190808311612745575b5050505050905060008061276d8388613b1f565b909250905061277c8287615285565b955061278881886153fe565b96506000871161279a575050506127b0565b50505080806127a890615499565b9150506126f7565b5090979596505050505050565b6000606060005a905060006127d4858701876147e7565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff81111561280d5761280d6156ac565b6040519080825280601f01601f191660200182016040528015612837576020820181803683370190505b50604051602001612849929190615115565b60405160208183030381529060405290506000612864613ba4565b90506000612871866129fa565b90505b835a61288090896153fe565b61288c90612710615285565b10156128cd5781406000908152600c6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612874565b806128e5576000839850985050505050505050611684565b6040518060400160405280600981526020017f6665656449444865780000000000000000000000000000000000000000000000815250601a6040518060400160405280600b81526020017f626c6f636b4e756d626572000000000000000000000000000000000000000000815250848960405160200161296791815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526129c99594939291600401614e1d565b60405180910390fd5b600f60205282600052604060002060205281600052604060002081815481106112e957600080fd5b600081815260056020526040812054612a1557506001919050565b600082815260036020908152604080832054600490925290912054612a38613ba4565b612a4291906153fe565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612acb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016129c9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6040517fa5f589340000000000000000000000000000000000000000000000000000000081526004810183905260009081908190309063a5f589349060240160206040518083038186803b158015612b9e57600080fd5b505afa158015612bb2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bd691906149e1565b9050831580612be55750808410155b15612bee578093505b60008581526011602052604081205485919061ffff16805b6000898152600f6020908152604080832061ffff85168452825280832080548251818502810185019093528083529192909190830182828015612c6857602002820191906000526020600020905b815481526020019060010190808311612c54575b50505050509050600080612c7c8388613b1f565b9092509050612c8b8287615285565b9550612c9781886153fe565b965060008711612ca9575050506127b0565b5050508080612cb790615499565b915050612c06565b6017546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b590612d19908690869086906004016150c1565b600060405180830381600087803b158015612d3357600080fd5b505af1158015612d47573d6000803e3d6000fd5b5050506000848152600b60205260409020612d6491508383614250565b50505050565b6000838152600e6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493830182828015612dc957602002820191906000526020600020905b815481526020019060010190808311612db5575b50505050509050612ddc818583516139bf565b95945050505050565b6000838152600f6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493830182828015612dc95760200282019190600052602060002090815481526020019060010190808311612db55750505050509050612ddc818583516139bf565b6060806000612e6460136139a9565b905060008167ffffffffffffffff811115612e8157612e816156ac565b604051908082528060200260200182016040528015612eaa578160200160208202803683370190505b50905060008267ffffffffffffffff811115612ec857612ec86156ac565b604051908082528060200260200182016040528015612ef1578160200160208202803683370190505b50905060005b838110156115fc576000612f0c6013836139b3565b6000818152600d6020908152604080832080548251818502810185019093528083529495509293909291830182828015612f6557602002820191906000526020600020905b815481526020019060010190808311612f51575b5050505050905081858481518110612f7f57612f7f61567d565b602002602001018181525050612f97818a83516139bf565b848481518110612fa957612fa961567d565b60200260200101818152505050508080612fc290615584565b915050612ef7565b6040805161014081018252600461010082019081527f746573740000000000000000000000000000000000000000000000000000000061012083015281528151602081810184526000808352818401929092523083850181905263ffffffff8916606085015260808401528351808201855282815260a08401528351908101909352825260c08101919091526bffffffffffffffffffffffff841660e082015260165460155473ffffffffffffffffffffffffffffffffffffffff9182169163095ea7b3911661309d60ff8a1688615356565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff166024820152604401602060405180830381600087803b15801561311657600080fd5b505af115801561312a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061314e91906147cc565b5060008660ff1667ffffffffffffffff81111561316d5761316d6156ac565b604051908082528060200260200182016040528015613196578160200160208202803683370190505b50905060005b8760ff168160ff1610156132095760006131b584613cd8565b905080838360ff16815181106131cd576131cd61567d565b60209081029190910181019190915260009182526008815260408083208890556007909152902084905580613201816155d0565b91505061319c565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516132399190614d92565b60405180910390a150505050505050565b6016546017546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b390604401602060405180830381600087803b1580156132cd57600080fd5b505af11580156132e1573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061330591906147cc565b506017546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561338657600080fd5b505af115801561339a573d6000803e3d6000fd5b5050604080518581526bffffffffffffffffffffffff851660208201527f8137dc366612bf502338bd8951f835ad8ceba421c4eb3d79c7f9b3ce0ac4762e93500190506118a0565b6000828152600f6020908152604080832061ffff851684528252918290208054835181840281018401909452808452606093928301828280156121d257602002820191906000526020600020908154815260200190600101908083116121be575050505050905092915050565b6000818152600d60209081526040918290208054835181840281018401909452808452606093928301828280156134a557602002820191906000526020600020905b815481526020019060010190808311613491575b50505050509050919050565b601a81815481106134c157600080fd5b9060005260206000200160009150905080546122f0906154d5565b60008181526011602052604081205461ffff1681805b8261ffff168161ffff1611611a4b576000858152600f6020908152604080832061ffff851684529091529020546135299083615285565b91508061353581615562565b9150506134f2565b6017546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b1580156135b557600080fd5b505af11580156135c9573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6017546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b15801561365a57600080fd5b505af11580156122d0573d6000803e3d6000fd5b8060005b818163ffffffff161015612d64573063af953a4a858563ffffffff851681811061369e5761369e61567d565b905060200201356040518263ffffffff1660e01b81526004016136c391815260200190565b600060405180830381600087803b1580156136dd57600080fd5b505af11580156136f1573d6000803e3d6000fd5b505050508080613700906155b6565b915050613672565b6017546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561377457600080fd5b505af1158015613788573d6000803e3d6000fd5b505050506111c1816013613dda90919063ffffffff16565b6000828152600d602090815260408083208054825181850281018501909352808352849384939291908301828280156137f857602002820191906000526020600020905b8154815260200190600101908083116137e4575b5050505050905061167e8185613b1f565b8060005b81811015612d645760008484838181106138295761382961567d565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc828360405160200161386291815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161388e929190615115565b600060405180830381600087803b1580156138a857600080fd5b505af11580156138bc573d6000803e3d6000fd5b505050505080806138cc90615584565b91505061380d565b600d60205281600052604060002081815481106138f057600080fd5b90600052602060002001600091509150505481565b61390d613c55565b61391681613de6565b50565b601060205281600052604060002081815481106138f057600080fd5b6000828152600f6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561166c5760200282019190600052602060002090815481526020019060010190808311611658575050505050905061167e818251613b1f565b60006112bb825490565b60006119108383613edc565b825160009081908315806139d35750808410155b156139dc578093505b60008467ffffffffffffffff8111156139f7576139f76156ac565b604051908082528060200260200182016040528015613a20578160200160208202803683370190505b509050600092505b84831015613a8e57866001613a3d85856153fe565b613a4791906153fe565b81518110613a5757613a5761567d565b6020026020010151818481518110613a7157613a7161567d565b602090810291909101015282613a8681615584565b935050613a28565b613aa781600060018451613aa291906153fe565b613f06565b8560641415613ae1578060018251613abf91906153fe565b81518110613acf57613acf61567d565b60200260200101519350505050611910565b806064825188613af19190615319565b613afb9190615305565b81518110613b0b57613b0b61567d565b602002602001015193505050509392505050565b815160009081908190841580613b355750808510155b15613b3e578094505b60008092505b85831015613b9a57866001613b5985856153fe565b613b6391906153fe565b81518110613b7357613b7361567d565b602002602001015181613b869190615285565b905082613b9281615584565b935050613b44565b9694955050505050565b60007f000000000000000000000000000000000000000000000000000000000000000015613c5057606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b158015613c1357600080fd5b505afa158015613c27573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c4b91906149e1565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314613cd6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016129c9565b565b6015546040517f08b79da4000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff909116906308b79da490613d33908690600401614fa1565b602060405180830381600087803b158015613d4d57600080fd5b505af1158015613d61573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d8591906149e1565b9050613d92601382614087565b5060608301516000828152600a6020908152604080832063ffffffff90941690935560a0860151600b8252929091208251613dd393919291909101906142ee565b5092915050565b60006119108383614093565b73ffffffffffffffffffffffffffffffffffffffff8116331415613e66576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016129c9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000826000018281548110613ef357613ef361567d565b9060005260206000200154905092915050565b818180821415613f17575050505050565b6000856002613f26878761538a565b613f30919061529d565b613f3a9087615211565b81518110613f4a57613f4a61567d565b602002602001015190505b818313614059575b80868481518110613f7057613f7061567d565b60200260200101511015613f905782613f8881615529565b935050613f5d565b858281518110613fa257613fa261567d565b6020026020010151811015613fc35781613fbb81615441565b925050613f90565b81831361405457858281518110613fdc57613fdc61567d565b6020026020010151868481518110613ff657613ff661567d565b60200260200101518785815181106140105761401061567d565b602002602001018885815181106140295761402961567d565b6020908102919091010191909152528261404281615529565b935050818061405090615441565b9250505b613f55565b8185121561406c5761406c868684613f06565b8383121561407f5761407f868486613f06565b505050505050565b60006119108383614186565b6000818152600183016020526040812054801561417c5760006140b76001836153fe565b85549091506000906140cb906001906153fe565b90508181146141305760008660000182815481106140eb576140eb61567d565b906000526020600020015490508087600001848154811061410e5761410e61567d565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806141415761414161564e565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506112bb565b60009150506112bb565b60008181526001830160205260408120546141cd575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556112bb565b5060006112bb565b828054828255906000526020600020908101928215614222579160200282015b8281111561422257825180516142129184916020909101906142ee565b50916020019190600101906141f5565b5061422e929150614362565b5090565b5080546000825590600052602060002090810190613916919061437f565b82805461425c906154d5565b90600052602060002090601f01602090048101928261427e57600085556142e2565b82601f106142b5578280017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008235161785556142e2565b828001600101855582156142e2579182015b828111156142e25782358255916020019190600101906142c7565b5061422e92915061437f565b8280546142fa906154d5565b90600052602060002090601f01602090048101928261431c57600085556142e2565b82601f1061433557805160ff19168380011785556142e2565b828001600101855582156142e2579182015b828111156142e2578251825591602001919060010190614347565b8082111561422e5760006143768282614394565b50600101614362565b5b8082111561422e5760008155600101614380565b5080546143a0906154d5565b6000825580601f106143b0575050565b601f016020900490600052602060002090810190613916919061437f565b60006143e16143dc846151cb565b615158565b90508281528383830111156143f557600080fd5b828260208301376000602084830101529392505050565b8051614417816156db565b919050565b60008083601f84011261442e57600080fd5b50813567ffffffffffffffff81111561444657600080fd5b6020830191508360208260051b850101111561168457600080fd5b8051801515811461441757600080fd5b60008083601f84011261448357600080fd5b50813567ffffffffffffffff81111561449b57600080fd5b60208301915083602082850101111561168457600080fd5b600082601f8301126144c457600080fd5b611910838335602085016143ce565b600082601f8301126144e457600080fd5b81516144f26143dc826151cb565b81815284602083860101111561450757600080fd5b614518826020830160208701615415565b949350505050565b803561ffff8116811461441757600080fd5b8051614417816156fd565b805167ffffffffffffffff8116811461441757600080fd5b803560ff8116811461441757600080fd5b80516144178161570f565b60006020828403121561458357600080fd5b8135611910816156db565b600080604083850312156145a157600080fd5b823567ffffffffffffffff808211156145b957600080fd5b818501915085601f8301126145cd57600080fd5b813560206145dd6143dc836151a7565b8083825282820191508286018a848660051b89010111156145fd57600080fd5b60005b858110156146385781358781111561461757600080fd5b6146258d87838c01016144b3565b8552509284019290840190600101614600565b5090975050508601359250508082111561465157600080fd5b5061465e858286016144b3565b9150509250929050565b6000602080838503121561467b57600080fd5b823567ffffffffffffffff8082111561469357600080fd5b818501915085601f8301126146a757600080fd5b81356146b56143dc826151a7565b80828252858201915085850189878560051b88010111156146d557600080fd5b60005b84811015614724578135868111156146ef57600080fd5b8701603f81018c1361470057600080fd5b6147118c8a830135604084016143ce565b85525092870192908701906001016146d8565b50909998505050505050505050565b6000806020838503121561474657600080fd5b823567ffffffffffffffff81111561475d57600080fd5b6147698582860161441c565b90969095509350505050565b60008060006040848603121561478a57600080fd5b833567ffffffffffffffff8111156147a157600080fd5b6147ad8682870161441c565b90945092505060208401356147c1816156fd565b809150509250925092565b6000602082840312156147de57600080fd5b61191082614461565b6000602082840312156147f957600080fd5b5035919050565b6000806020838503121561481357600080fd5b823567ffffffffffffffff81111561482a57600080fd5b61476985828601614471565b60006020828403121561484857600080fd5b8151611910816156db565b600080600080600060a0868803121561486b57600080fd5b85516003811061487a57600080fd5b602087015190955061488b816156fd565b604087015190945061489c816156fd565b60608701519093506148ad816156db565b80925050608086015190509295509295909350565b6000602082840312156148d457600080fd5b815167ffffffffffffffff808211156148ec57600080fd5b90830190610140828603121561490157600080fd5b61490961512e565b6149128361440c565b815261492060208401614532565b602082015260408301518281111561493757600080fd5b614943878286016144d3565b60408301525061495560608401614566565b60608201526149666080840161440c565b608082015261497760a0840161453d565b60a082015261498860c08401614532565b60c082015261499960e08401614566565b60e08201526101006149ac818501614461565b9082015261012083810151838111156149c457600080fd5b6149d0888287016144d3565b918301919091525095945050505050565b6000602082840312156149f357600080fd5b5051919050565b600080600060408486031215614a0f57600080fd5b83359250602084013567ffffffffffffffff811115614a2d57600080fd5b614a3986828701614471565b9497909650939450505050565b60008060408385031215614a5957600080fd5b82359150614a6960208401614520565b90509250929050565b600080600060608486031215614a8757600080fd5b83359250614a9760208501614520565b9150604084013590509250925092565b60008060408385031215614aba57600080fd5b50508035926020909101359150565b600080600060608486031215614ade57600080fd5b8335925060208401359150614af560408501614520565b90509250925092565b600080600060608486031215614b1357600080fd5b505081359360208301359350604090920135919050565b60008060408385031215614b3d57600080fd5b823591506020830135614b4f816156fd565b809150509250929050565b60008060408385031215614b6d57600080fd5b823591506020830135614b4f8161570f565b600060208284031215614b9157600080fd5b61191082614555565b600080600080600060a08688031215614bb257600080fd5b614bbb86614555565b94506020860135614bcb816156fd565b93506040860135614bdb8161570f565b94979396509394606081013594506080013592915050565b600060208284031215614c0557600080fd5b81356119108161570f565b600060208284031215614c2257600080fd5b81516119108161570f565b600081518084526020808501945080840160005b83811015614c5d57815187529582019590820190600101614c41565b509495945050505050565b60008151808452614c80816020860160208601615415565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015614d27577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614d15868351614c68565b95509382019390820190600101614cdb565b505085840381870152505050612ddc8185614c68565b6020815281602082015260007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff831115614d7657600080fd5b8260051b80856040850137600092016040019182525092915050565b6020815260006119106020830184614c2d565b604081526000614db86040830185614c2d565b8281036020840152612ddc8185614c2d565b821515815260406020820152600061190d6040830184614c68565b6020815260006119106020830184614c68565b604081526000614e0b6040830185614c68565b8281036020840152612ddc8185614c68565b60a081526000614e3060a0830188614c68565b6020838203818501528188548084528284019150828160051b85010160008b8152848120815b84811015614f62578784037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001865281548390600181811c9080831680614e9e57607f831692505b8b8310811415614ed5577f4e487b710000000000000000000000000000000000000000000000000000000088526022600452602488fd5b82895260208901818015614ef05760018114614f1f57614f49565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00861682528d82019650614f49565b6000898152602090208a5b86811015614f4357815484820152908501908f01614f2a565b83019750505b505050988a019892965050509190910190600101614e56565b5050508681036040880152614f77818b614c68565b9450505050508460608401528281036080840152614f958185614c68565b98975050505050505050565b6020815260008251610100806020850152614fc0610120850183614c68565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe080868503016040870152614ffc8483614c68565b935060408701519150615027606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a08701519150808685030160c08701526150788483614c68565b935060c08701519150808685030160e0870152506150968382614c68565b92505060e08501516150b7828601826bffffffffffffffffffffffff169052565b5090949350505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b82815260406020820152600061190d6040830184614c68565b604051610140810167ffffffffffffffff81118282101715615152576151526156ac565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561519f5761519f6156ac565b604052919050565b600067ffffffffffffffff8211156151c1576151c16156ac565b5060051b60200190565b600067ffffffffffffffff8211156151e5576151e56156ac565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b6000808212827f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0384138115161561524b5761524b6155f0565b827f800000000000000000000000000000000000000000000000000000000000000003841281161561527f5761527f6155f0565b50500190565b60008219821115615298576152986155f0565b500190565b6000826152ac576152ac61561f565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f800000000000000000000000000000000000000000000000000000000000000083141615615300576153006155f0565b500590565b6000826153145761531461561f565b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615615351576153516155f0565b500290565b60006bffffffffffffffffffffffff80831681851681830481118215151615615381576153816155f0565b02949350505050565b6000808312837f8000000000000000000000000000000000000000000000000000000000000000018312811516156153c4576153c46155f0565b837f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0183138116156153f8576153f86155f0565b50500390565b600082821015615410576154106155f0565b500390565b60005b83811015615430578181015183820152602001615418565b83811115612d645750506000910152565b60007f8000000000000000000000000000000000000000000000000000000000000000821415615473576154736155f0565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600061ffff8216806154ad576154ad6155f0565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0192915050565b600181811c908216806154e957607f821691505b60208210811415615523577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561555b5761555b6155f0565b5060010190565b600061ffff8083168181141561557a5761557a6155f0565b6001019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561555b5761555b6155f0565b600063ffffffff8083168181141561557a5761557a6155f0565b600060ff821660ff8114156155e7576155e76155f0565b60010192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8116811461391657600080fd5b63ffffffff8116811461391657600080fd5b6bffffffffffffffffffffffff8116811461391657600080fdfea164736f6c6343000806000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307835353533343434333264353535333434326434313532343234393534353235353464326435343435353335343465343535343030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registrarAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x6005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460a0526101a0604052604261012081815260c0918291906200504661014039815260200160405180608001604052806042815260200162005088604291398152602001604051806080016040528060428152602001620050ca604291399052620000949060169060036200033b565b50348015620000a257600080fd5b506040516200510c3803806200510c833981016040819052620000c59162000428565b818133806000816200011e5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156200015157620001518162000290565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001ae573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001d491906200046b565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200023a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200026091906200049c565b601280546001600160a01b0319166001600160a01b03929092169190911790555015156080525062000634915050565b336001600160a01b03821603620002ea5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000115565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b82805482825590600052602060002090810192821562000386579160200282015b8281111562000386578251829062000375908262000568565b50916020019190600101906200035c565b506200039492915062000398565b5090565b8082111562000394576000620003af8282620003b9565b5060010162000398565b508054620003c790620004d9565b6000825580601f10620003d8575050565b601f016020900490600052602060002090810190620003f89190620003fb565b50565b5b80821115620003945760008155600101620003fc565b6001600160a01b0381168114620003f857600080fd5b600080604083850312156200043c57600080fd5b8251620004498162000412565b602084015190925080151581146200046057600080fd5b809150509250929050565b600080604083850312156200047f57600080fd5b82516200048c8162000412565b6020939093015192949293505050565b600060208284031215620004af57600080fd5b8151620004bc8162000412565b9392505050565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620004ee57607f821691505b6020821081036200050f57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200056357600081815260208120601f850160051c810160208610156200053e5750805b601f850160051c820191505b818110156200055f578281556001016200054a565b5050505b505050565b81516001600160401b03811115620005845762000584620004c3565b6200059c81620005958454620004d9565b8462000515565b602080601f831160018114620005d45760008415620005bb5750858301515b600019600386901b1c1916600185901b1785556200055f565b600085815260208120601f198616915b828110156200060557888601518255948401946001909101908401620005e4565b5085821015620006245787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a0516149de62000668600039600081816104f001526119bd01526000818161080c0152612fcd01526149de6000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610e2f578063f2fde38b14610e45578063fba7ffa314610e65578063fcdc1f6314610e9257600080fd5b8063d6051a7214610da2578063daee1aeb14610dc2578063dbef701e14610de2578063e0114adb14610e0257600080fd5b8063c357f1f3116100dc578063c357f1f314610c80578063c804802214610cda578063c98f10b014610cfa578063d355852814610d4357600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c6057600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b80634b56a42e116102e2578063642f6cef116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063642f6cef146107fa57806369cdbadb1461083e57806369e9b7731461086b5780636e04ff0d1461089857600080fd5b80635d4ee7f3116102b15780635d4ee7f3146107565780635f17e6161461076b57806360457ff51461078b578063636092e8146107b857600080fd5b80634b56a42e146106c657806351c98be3146106f457806357970e9314610714578063597109921461074157600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c146106395780634585e33b1461065957806345d2ec171461067957806346e7a63e1461069957600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b610426366004613716565b610ebf565b005b34801561043957600080fd5b5061042b610448366004613837565b610ed6565b34801561045957600080fd5b5061046d6104683660046138d3565b611292565b60405161047a91906138f5565b60405180910390f35b34801561048f57600080fd5b506104a361049e366004613950565b611391565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc366004613985565b6113cf565b60405161047a9190613a0c565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a1f565b6114ef565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613a6d565b611572565b34801561058657600080fd5b506104a3610595366004613a8a565b61173c565b3480156105a657600080fd5b5061042b6105b5366004613afb565b6117a7565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a3610627366004613985565b60036020526000908152604090205481565b34801561064557600080fd5b506104a3610654366004613985565b611841565b34801561066557600080fd5b5061042b610674366004613b7f565b6118aa565b34801561068557600080fd5b5061046d610694366004613a1f565b611ad5565b3480156106a557600080fd5b506104a36106b4366004613985565b600a6020526000908152604090205481565b3480156106d257600080fd5b506106e66106e1366004613bb5565b611b44565b60405161047a929190613c89565b34801561070057600080fd5b5061042b61070f366004613ca4565b611b98565b34801561072057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561074d57600080fd5b5061042b611c3c565b34801561076257600080fd5b5061042b611e27565b34801561077757600080fd5b5061042b6107863660046138d3565b611f5e565b34801561079757600080fd5b506104a36107a6366004613985565b60076020526000908152604090205481565b3480156107c457600080fd5b506015546107dd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561080657600080fd5b5061082e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561084a57600080fd5b506104a3610859366004613985565b60086020526000908152604090205481565b34801561087757600080fd5b5061042b6108863660046138d3565b60009182526008602052604090912055565b3480156108a457600080fd5b506106e66108b3366004613b7f565b61202b565b3480156108c457600080fd5b5061082e6108d3366004613985565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a3610903366004613985565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a3610930366004613985565b60046020526000908152604090205481565b34801561094e57600080fd5b5061082e61095d366004613985565b612240565b34801561096e57600080fd5b5061042b612292565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613cfb565b61238f565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a366004613985565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a373660046138d3565b612420565b348015610a4857600080fd5b5061042b610a57366004613d47565b612665565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab33660046138d3565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae0366004613985565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b11366004613985565b6127ae565b348015610b2257600080fd5b506104d1610b31366004613985565b612810565b348015610b4257600080fd5b506104a37f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0881565b348015610b7657600080fd5b5061042b610b85366004613a8a565b6128bc565b348015610b9657600080fd5b5061042b610ba5366004613985565b601455565b348015610bb657600080fd5b5061042b610bc5366004613d77565b612925565b348015610bd657600080fd5b5061042b610be53660046138d3565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c12366004613985565b6129d0565b348015610c2357600080fd5b506104d16040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525081565b348015610c6c57600080fd5b5061042b610c7b366004613afb565b612a56565b348015610c8c57600080fd5b5061042b610c9b366004613d9c565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610ce657600080fd5b5061042b610cf5366004613985565b612af0565b348015610d0657600080fd5b506104d16040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525081565b348015610d4f57600080fd5b5061042b610d5e366004613db9565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610dae57600080fd5b50610545610dbd3660046138d3565b612b88565b348015610dce57600080fd5b5061042b610ddd366004613afb565b612bf1565b348015610dee57600080fd5b506104a3610dfd3660046138d3565b612cbc565b348015610e0e57600080fd5b506104a3610e1d366004613985565b60096020526000908152604090205481565b348015610e3b57600080fd5b506104a360145481565b348015610e5157600080fd5b5061042b610e60366004613a6d565b612ced565b348015610e7157600080fd5b506104a3610e80366004613985565b60066020526000908152604090205481565b348015610e9e57600080fd5b506104a3610ead366004613985565b60026020526000908152604090205481565b8051610ed29060169060208401906134e6565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610fbc908c1688613e05565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af115801561103a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061105e9190613e49565b5060008860ff1667ffffffffffffffff81111561107d5761107d6135c6565b6040519080825280602002602001820160405280156110a6578160200160208202803683370190505b50905060005b8960ff168160ff16101561124f5760006110c584612d01565b90508860ff166001036111fd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa15801561112a573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111709190810190613eb1565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111c99085908590600401613ee6565b600060405180830381600087803b1580156111e357600080fd5b505af11580156111f7573d6000803e3d6000fd5b50505050505b80838360ff168151811061121357611213613eff565b6020908102919091018101919091526000918252600881526040808320889055600790915290208490558061124781613f2e565b9150506110ac565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161127f91906138f5565b60405180910390a1505050505050505050565b606060006112a0600f612dcf565b90508084106112db576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036112f0576112ed8482613f4d565b92505b60008367ffffffffffffffff81111561130b5761130b6135c6565b604051908082528060200260200182016040528015611334578160200160208202803683370190505b50905060005b848110156113865761135761134f8288613f60565b600f90612dd9565b82828151811061136957611369613eff565b60209081029190910101528061137e81613f73565b91505061133a565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106113b957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0860001b81526020018460405160200161144091815260200190565b60405160208183030381529060405261145890613fab565b81526020016000801b81526020016000801b8152509050806040516020016114d89190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561155357602002820191906000526020600020905b81548152602001906001019080831161153f575b50505050509050611565818251612de5565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611608573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061162c9190613ffb565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156116cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116f39190614029565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261179d9383018282801561179157602002820191906000526020600020905b81548152602001906001019080831161177d575b50505050508484612e6a565b90505b9392505050565b8060005b818160ff16101561183b573063c8048022858560ff85168181106117d1576117d1613eff565b905060200201356040518263ffffffff1660e01b81526004016117f691815260200190565b600060405180830381600087803b15801561181057600080fd5b505af1158015611824573d6000803e3d6000fd5b50505050808061183390613f2e565b9150506117ab565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff16116118a2576000858152600d6020908152604080832061ffff8516845290915290205461188e9083613f60565b91508061189a81614046565b915050611857565b509392505050565b60005a90506000806118be84860186613bb5565b915091506000818060200190518101906118d89190614067565b600081815260056020908152604080832054600490925282205492935091906118ff612fc9565b90508260000361191f576000848152600560205260409020819055611a7a565b6000848152600360205260408120546119388484613f4d565b6119429190613f4d565b6000868152600e6020908152604080832054600d835281842061ffff9091168085529083528184208054835181860281018601909452808452959650909491929091908301828280156119b457602002820191906000526020600020905b8154815260200190600101908083116119a0575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611a2f57816119f181614046565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b600084815260066020526040812054611a94906001613f60565b6000868152600660209081526040808320849055600490915290208390559050611abe8583612420565b611ac98589846128bc565b50505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611b3757602002820191906000526020600020905b815481526020019060010190808311611b23575b5050505050905092915050565b6000606060008484604051602001611b5d929190614080565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611c355730635f17e616868684818110611bbc57611bbc613eff565b90506020020135856040518363ffffffff1660e01b8152600401611bf092919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611c0a57600080fd5b505af1158015611c1e573d6000803e3d6000fd5b505050508080611c2d90613f73565b915050611b9c565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611cb3573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611cf99190810190614114565b80519091506000611d08612fc9565b905060005b8281101561183b576000848281518110611d2957611d29613eff565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611da9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dcd91906141a5565b90508060ff16600103611e1257604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611e1f90613f73565b915050611d0d565b611e2f61306b565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611e9e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ec29190614067565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611f3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed29190613e49565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611f969161353c565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611ff2576000848152600d6020908152604080832061ffff851684529091528120611fe09161353c565b80611fea81614046565b915050611fab565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a9050600061204285870187613985565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff81111561207b5761207b6135c6565b6040519080825280601f01601f1916602001820160405280156120a5576020820181803683370190505b506040516020016120b7929190613ee6565b604051602081830303815290604052905060006120d2612fc9565b905060006120df86612240565b90505b835a6120ee9089613f4d565b6120fa90612710613f60565b101561213b5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556120e2565b8061215357600083985098505050505050505061156b565b6040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525060166040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525084896040516020016121d591815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252612237959493929160040161420f565b60405180910390fd5b600081815260056020526040812054810361225d57506001919050565b600082815260036020908152604080832054600490925290912054612280612fc9565b61228a9190613f4d565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612313576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401612237565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b5906123e99086908690869060040161435c565b600060405180830381600087803b15801561240357600080fd5b505af1158015612417573d6000803e3d6000fd5b50505050505050565b60145460008381526002602052604090205461243c9083613f4d565b1115610ed2576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa1580156124b2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526124f891908101906143de565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa15801561256d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061259191906144fd565b6015549091506125b59082906c01000000000000000000000000900460ff16613e05565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff16101561183b576015546125f89085906bffffffffffffffffffffffff16612665565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af11580156126ed573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127119190613e49565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561279257600080fd5b505af11580156127a6573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561280457602002820191906000526020600020905b8154815260200190600101908083116127f0575b50505050509050919050565b6016818154811061282057600080fd5b90600052602060002001600091509050805461283b906141c2565b80601f0160208091040260200160405190810160405280929190818152602001828054612867906141c2565b80156128b45780601f10612889576101008083540402835291602001916128b4565b820191906000526020600020905b81548152906001019060200180831161289757829003601f168201915b505050505081565b6000838152600760205260409020545b805a6128d89085613f4d565b6128e490612710613f60565b101561183b5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556128cc565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561299d57600080fd5b505af11580156129b1573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a4257600080fd5b505af1158015611c35573d6000803e3d6000fd5b8060005b818163ffffffff16101561183b573063af953a4a858563ffffffff8516818110612a8657612a86613eff565b905060200201356040518263ffffffff1660e01b8152600401612aab91815260200190565b600060405180830381600087803b158015612ac557600080fd5b505af1158015612ad9573d6000803e3d6000fd5b505050508080612ae89061451a565b915050612a5a565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612b5c57600080fd5b505af1158015612b70573d6000803e3d6000fd5b50505050610ed281600f6130ee90919063ffffffff16565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612be057602002820191906000526020600020905b815481526020019060010190808311612bcc575b505050505090506115658185612de5565b8060005b8181101561183b576000848483818110612c1157612c11613eff565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612c4a91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612c76929190613ee6565b600060405180830381600087803b158015612c9057600080fd5b505af1158015612ca4573d6000803e3d6000fd5b50505050508080612cb490613f73565b915050612bf5565b600c6020528160005260406000208181548110612cd857600080fd5b90600052602060002001600091509150505481565b612cf561306b565b612cfe816130fa565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612d5c908690600401614533565b6020604051808303816000875af1158015612d7b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d9f9190614067565b9050612dac600f826131ef565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061138b825490565b60006117a083836131fb565b815160009081908190841580612dfb5750808510155b15612e04578094505b60008092505b85831015612e6057866001612e1f8585613f4d565b612e299190613f4d565b81518110612e3957612e39613eff565b602002602001015181612e4c9190613f60565b905082612e5881613f73565b935050612e0a565b9694955050505050565b82516000908190831580612e7e5750808410155b15612e87578093505b60008467ffffffffffffffff811115612ea257612ea26135c6565b604051908082528060200260200182016040528015612ecb578160200160208202803683370190505b509050600092505b84831015612f3957866001612ee88585613f4d565b612ef29190613f4d565b81518110612f0257612f02613eff565b6020026020010151818481518110612f1c57612f1c613eff565b602090810291909101015282612f3181613f73565b935050612ed3565b612f5281600060018451612f4d9190613f4d565b613225565b85606403612f8b578060018251612f699190613f4d565b81518110612f7957612f79613eff565b602002602001015193505050506117a0565b806064825188612f9b9190614685565b612fa591906146f1565b81518110612fb557612fb5613eff565b602002602001015193505050509392505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561306657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561303d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130619190614067565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff1633146130ec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612237565b565b60006117a0838361339d565b3373ffffffffffffffffffffffffffffffffffffffff821603613179576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612237565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006117a08383613497565b600082600001828154811061321257613212613eff565b9060005260206000200154905092915050565b8181808203613235575050505050565b60008560026132448787614705565b61324e9190614725565b613258908761478d565b8151811061326857613268613eff565b602002602001015190505b818313613377575b8086848151811061328e5761328e613eff565b602002602001015110156132ae57826132a6816147b5565b93505061327b565b8582815181106132c0576132c0613eff565b60200260200101518110156132e157816132d9816147e6565b9250506132ae565b818313613372578582815181106132fa576132fa613eff565b602002602001015186848151811061331457613314613eff565b602002602001015187858151811061332e5761332e613eff565b6020026020010188858151811061334757613347613eff565b60209081029190910101919091525282613360816147b5565b935050818061336e906147e6565b9250505b613273565b8185121561338a5761338a868684613225565b838312156127a6576127a6868486613225565b600081815260018301602052604081205480156134865760006133c1600183613f4d565b85549091506000906133d590600190613f4d565b905081811461343a5760008660000182815481106133f5576133f5613eff565b906000526020600020015490508087600001848154811061341857613418613eff565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061344b5761344b61483d565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061138b565b600091505061138b565b5092915050565b60008181526001830160205260408120546134de5750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561138b565b50600061138b565b82805482825590600052602060002090810192821561352c579160200282015b8281111561352c578251829061351c90826148b7565b5091602001919060010190613506565b5061353892915061355a565b5090565b5080546000825590600052602060002090810190612cfe9190613577565b8082111561353857600061356e828261358c565b5060010161355a565b5b808211156135385760008155600101613578565b508054613598906141c2565b6000825580601f106135a8575050565b601f016020900490600052602060002090810190612cfe9190613577565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715613619576136196135c6565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613666576136666135c6565b604052919050565b600067ffffffffffffffff821115613688576136886135c6565b5060051b60200190565b600067ffffffffffffffff8211156136ac576136ac6135c6565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b60006136eb6136e684613692565b61361f565b90508281528383830111156136ff57600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561372957600080fd5b823567ffffffffffffffff8082111561374157600080fd5b818501915085601f83011261375557600080fd5b81356137636136e68261366e565b81815260059190911b8301840190848101908883111561378257600080fd5b8585015b838110156137cf5780358581111561379e5760008081fd5b8601603f81018b136137b05760008081fd5b6137c18b89830135604084016136d8565b845250918601918601613786565b5098975050505050505050565b60ff81168114612cfe57600080fd5b63ffffffff81168114612cfe57600080fd5b600082601f83011261380e57600080fd5b6117a0838335602085016136d8565b6bffffffffffffffffffffffff81168114612cfe57600080fd5b600080600080600080600060e0888a03121561385257600080fd5b873561385d816137dc565b9650602088013561386d816137eb565b9550604088013561387d816137dc565b9450606088013567ffffffffffffffff81111561389957600080fd5b6138a58a828b016137fd565b94505060808801356138b68161381d565b9699959850939692959460a0840135945060c09093013592915050565b600080604083850312156138e657600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561392d57835183529284019291840191600101613911565b50909695505050505050565b803561ffff8116811461394b57600080fd5b919050565b60008060006060848603121561396557600080fd5b8335925061397560208501613939565b9150604084013590509250925092565b60006020828403121561399757600080fd5b5035919050565b60005b838110156139b95781810151838201526020016139a1565b50506000910152565b600081518084526139da81602086016020860161399e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117a060208301846139c2565b60008060408385031215613a3257600080fd5b82359150613a4260208401613939565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612cfe57600080fd5b600060208284031215613a7f57600080fd5b81356117a081613a4b565b600080600060608486031215613a9f57600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613ac857600080fd5b50813567ffffffffffffffff811115613ae057600080fd5b6020830191508360208260051b850101111561156b57600080fd5b60008060208385031215613b0e57600080fd5b823567ffffffffffffffff811115613b2557600080fd5b613b3185828601613ab6565b90969095509350505050565b60008083601f840112613b4f57600080fd5b50813567ffffffffffffffff811115613b6757600080fd5b60208301915083602082850101111561156b57600080fd5b60008060208385031215613b9257600080fd5b823567ffffffffffffffff811115613ba957600080fd5b613b3185828601613b3d565b60008060408385031215613bc857600080fd5b823567ffffffffffffffff80821115613be057600080fd5b818501915085601f830112613bf457600080fd5b81356020613c046136e68361366e565b82815260059290921b84018101918181019089841115613c2357600080fd5b8286015b84811015613c5b57803586811115613c3f5760008081fd5b613c4d8c86838b01016137fd565b845250918301918301613c27565b5096505086013592505080821115613c7257600080fd5b50613c7f858286016137fd565b9150509250929050565b821515815260406020820152600061179d60408301846139c2565b600080600060408486031215613cb957600080fd5b833567ffffffffffffffff811115613cd057600080fd5b613cdc86828701613ab6565b9094509250506020840135613cf0816137eb565b809150509250925092565b600080600060408486031215613d1057600080fd5b83359250602084013567ffffffffffffffff811115613d2e57600080fd5b613d3a86828701613b3d565b9497909650939450505050565b60008060408385031215613d5a57600080fd5b823591506020830135613d6c8161381d565b809150509250929050565b60008060408385031215613d8a57600080fd5b823591506020830135613d6c816137eb565b600060208284031215613dae57600080fd5b81356117a08161381d565b600060208284031215613dcb57600080fd5b81356117a0816137dc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613e3057613e30613dd6565b02949350505050565b8051801515811461394b57600080fd5b600060208284031215613e5b57600080fd5b6117a082613e39565b600082601f830112613e7557600080fd5b8151613e836136e682613692565b818152846020838601011115613e9857600080fd5b613ea982602083016020870161399e565b949350505050565b600060208284031215613ec357600080fd5b815167ffffffffffffffff811115613eda57600080fd5b613ea984828501613e64565b82815260406020820152600061179d60408301846139c2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103613f4457613f44613dd6565b60010192915050565b8181038181111561138b5761138b613dd6565b8082018082111561138b5761138b613dd6565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa457613fa4613dd6565b5060010190565b80516020808301519190811015613fea577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161394b81613a4b565b6000806040838503121561400e57600080fd5b825161401981613a4b565b6020939093015192949293505050565b60006020828403121561403b57600080fd5b81516117a081613a4b565b600061ffff80831681810361405d5761405d613dd6565b6001019392505050565b60006020828403121561407957600080fd5b5051919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156140f5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030185526140e38683516139c2565b955093820193908201906001016140a9565b50508584038187015250505061410b81856139c2565b95945050505050565b6000602080838503121561412757600080fd5b825167ffffffffffffffff81111561413e57600080fd5b8301601f8101851361414f57600080fd5b805161415d6136e68261366e565b81815260059190911b8201830190838101908783111561417c57600080fd5b928401925b8284101561419a57835182529284019290840190614181565b979650505050505050565b6000602082840312156141b757600080fd5b81516117a0816137dc565b600181811c908216806141d657607f821691505b602082108103613fea577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60a08152600061422260a08301886139c2565b602083820381850152818854808452828401915060058382821b86010160008c8152858120815b8581101561431c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0898503018752828254614284816141c2565b8087526001828116801561429f57600181146142d657614305565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0084168d8a01528c8315158b1b8a01019450614305565b8688528c8820885b848110156142fd5781548f828d01015283820191508e810190506142de565b8a018e019550505b50998b019992965050509190910190600101614249565b5050508781036040890152614331818c6139c2565b95505050505050846060840152828103608084015261435081856139c2565b98975050505050505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b805161394b816137eb565b805161394b8161381d565b805167ffffffffffffffff8116811461394b57600080fd5b6000602082840312156143f057600080fd5b815167ffffffffffffffff8082111561440857600080fd5b90830190610140828603121561441d57600080fd5b6144256135f5565b61442e83613ff0565b815261443c602084016143b0565b602082015260408301518281111561445357600080fd5b61445f87828601613e64565b604083015250614471606084016143bb565b606082015261448260808401613ff0565b608082015261449360a084016143c6565b60a08201526144a460c084016143b0565b60c08201526144b560e084016143bb565b60e08201526101006144c8818501613e39565b9082015261012083810151838111156144e057600080fd5b6144ec88828701613e64565b918301919091525095945050505050565b60006020828403121561450f57600080fd5b81516117a08161381d565b600063ffffffff80831681810361405d5761405d613dd6565b60208152600082516101408060208501526145526101608501836139c2565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261458e84836139c2565b9350604087015191506145b9606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e087015261461a84836139c2565b935060e0870151915061010081878603018188015261463985846139c2565b94508088015192505061012081878603018188015261465885846139c2565b9450808801519250505061467b828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156146bd576146bd613dd6565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082614700576147006146c2565b500490565b818103600083128015838313168383128216171561349057613490613dd6565b600082614734576147346146c2565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561478857614788613dd6565b500590565b80820182811260008312801582168215821617156147ad576147ad613dd6565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa457613fa4613dd6565b60007f8000000000000000000000000000000000000000000000000000000000000000820361481757614817613dd6565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f8211156148b257600081815260208120601f850160051c810160208610156148935750805b601f850160051c820191505b818110156127a65782815560010161489f565b505050565b815167ffffffffffffffff8111156148d1576148d16135c6565b6148e5816148df84546141c2565b8461486c565b602080601f83116001811461493857600084156149025750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556127a6565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561498557888601518255948401946001909101908401614966565b50858210156149c157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307835353533343434333264353535333434326434313532343234393534353235353464326435343435353335343465343535343030303030303030303030303030", } var VerifiableLoadMercuryUpkeepABI = VerifiableLoadMercuryUpkeepMetaData.ABI @@ -193,28 +193,6 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) BU return _VerifiableLoadMercuryUpkeep.Contract.BUCKETSIZE(&_VerifiableLoadMercuryUpkeep.CallOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) TIMESTAMPINTERVAL(opts *bind.CallOpts) (uint16, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "TIMESTAMP_INTERVAL") - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) TIMESTAMPINTERVAL() (uint16, error) { - return _VerifiableLoadMercuryUpkeep.Contract.TIMESTAMPINTERVAL(&_VerifiableLoadMercuryUpkeep.CallOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) TIMESTAMPINTERVAL() (uint16, error) { - return _VerifiableLoadMercuryUpkeep.Contract.TIMESTAMPINTERVAL(&_VerifiableLoadMercuryUpkeep.CallOpts) -} - func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "addLinkAmount") @@ -304,28 +282,6 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Ch return _VerifiableLoadMercuryUpkeep.Contract.CheckCallback(&_VerifiableLoadMercuryUpkeep.CallOpts, values, extraData) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) CheckDatas(opts *bind.CallOpts, arg0 *big.Int) ([]byte, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "checkDatas", arg0) - - if err != nil { - return *new([]byte), err - } - - out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) CheckDatas(arg0 *big.Int) ([]byte, error) { - return _VerifiableLoadMercuryUpkeep.Contract.CheckDatas(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) CheckDatas(arg0 *big.Int) ([]byte, error) { - return _VerifiableLoadMercuryUpkeep.Contract.CheckDatas(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0) -} - func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) CheckGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { var out []interface{} err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "checkGasToBurns", arg0) @@ -436,6 +392,28 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) El return _VerifiableLoadMercuryUpkeep.Contract.Eligible(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId) } +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) EmittedSig(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "emittedSig") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) EmittedSig() ([32]byte, error) { + return _VerifiableLoadMercuryUpkeep.Contract.EmittedSig(&_VerifiableLoadMercuryUpkeep.CallOpts) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) EmittedSig() ([32]byte, error) { + return _VerifiableLoadMercuryUpkeep.Contract.EmittedSig(&_VerifiableLoadMercuryUpkeep.CallOpts) +} + func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) FeedParamKey(opts *bind.CallOpts) (string, error) { var out []interface{} err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "feedParamKey") @@ -634,138 +612,26 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Ge return _VerifiableLoadMercuryUpkeep.Contract.GetDelaysLength(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetDelaysLengthAtBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getDelaysLengthAtBucket", upkeepId, bucket) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetDelaysLengthAtBucket(upkeepId *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetDelaysLengthAtBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, bucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetDelaysLengthAtBucket(upkeepId *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetDelaysLengthAtBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, bucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetDelaysLengthAtTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getDelaysLengthAtTimestampBucket", upkeepId, timestampBucket) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetDelaysLengthAtTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetDelaysLengthAtTimestampBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetDelaysLengthAtTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetDelaysLengthAtTimestampBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetPxBucketedDelaysForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getPxBucketedDelaysForAllUpkeeps", p) - - if err != nil { - return *new([]*big.Int), *new([]*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) - out1 := *abi.ConvertType(out[1], new([]*big.Int)).(*[]*big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetPxBucketedDelaysForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxBucketedDelaysForAllUpkeeps(&_VerifiableLoadMercuryUpkeep.CallOpts, p) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetPxBucketedDelaysForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxBucketedDelaysForAllUpkeeps(&_VerifiableLoadMercuryUpkeep.CallOpts, p) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetPxDelayForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getPxDelayForAllUpkeeps", p) - - if err != nil { - return *new([]*big.Int), *new([]*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) - out1 := *abi.ConvertType(out[1], new([]*big.Int)).(*[]*big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetPxDelayForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayForAllUpkeeps(&_VerifiableLoadMercuryUpkeep.CallOpts, p) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetPxDelayForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayForAllUpkeeps(&_VerifiableLoadMercuryUpkeep.CallOpts, p) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetPxDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getPxDelayInBucket", upkeepId, p, bucket) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetPxDelayInBucket(upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayInBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, p, bucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetPxDelayInBucket(upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayInBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, p, bucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetPxDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetLogTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) { var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getPxDelayInTimestampBucket", upkeepId, p, timestampBucket) + err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getLogTriggerConfig", upkeepId) if err != nil { - return *new(*big.Int), err + return *new([]byte), err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) return out0, err } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetPxDelayInTimestampBucket(upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayInTimestampBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, p, timestampBucket) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetLogTriggerConfig(upkeepId *big.Int) ([]byte, error) { + return _VerifiableLoadMercuryUpkeep.Contract.GetLogTriggerConfig(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetPxDelayInTimestampBucket(upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayInTimestampBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, p, timestampBucket) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetLogTriggerConfig(upkeepId *big.Int) ([]byte, error) { + return _VerifiableLoadMercuryUpkeep.Contract.GetLogTriggerConfig(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId) } func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetPxDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) { @@ -790,29 +656,6 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Ge return _VerifiableLoadMercuryUpkeep.Contract.GetPxDelayLastNPerforms(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, p, n) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetSumBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getSumBucketedDelayLastNPerforms", upkeepId, n) - - if err != nil { - return *new(*big.Int), *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetSumBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetSumBucketedDelayLastNPerforms(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, n) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetSumBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetSumBucketedDelayLastNPerforms(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, n) -} - func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetSumDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) { var out []interface{} err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getSumDelayInBucket", upkeepId, bucket) @@ -836,29 +679,6 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Ge return _VerifiableLoadMercuryUpkeep.Contract.GetSumDelayInBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, bucket) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetSumDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getSumDelayInTimestampBucket", upkeepId, timestampBucket) - - if err != nil { - return *new(*big.Int), *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetSumDelayInTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetSumDelayInTimestampBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetSumDelayInTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetSumDelayInTimestampBucket(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, timestampBucket) -} - func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetSumDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { var out []interface{} err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getSumDelayLastNPerforms", upkeepId, n) @@ -882,73 +702,6 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Ge return _VerifiableLoadMercuryUpkeep.Contract.GetSumDelayLastNPerforms(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, n) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetSumTimestampBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getSumTimestampBucketedDelayLastNPerforms", upkeepId, n) - - if err != nil { - return *new(*big.Int), *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetSumTimestampBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetSumTimestampBucketedDelayLastNPerforms(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, n) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetSumTimestampBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetSumTimestampBucketedDelayLastNPerforms(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, n) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetTimestampBucketedDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getTimestampBucketedDelaysLength", upkeepId) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetTimestampBucketedDelaysLength(upkeepId *big.Int) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetTimestampBucketedDelaysLength(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetTimestampBucketedDelaysLength(upkeepId *big.Int) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetTimestampBucketedDelaysLength(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) GetTimestampDelays(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "getTimestampDelays", upkeepId, timestampBucket) - - if err != nil { - return *new([]*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) GetTimestampDelays(upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetTimestampDelays(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) GetTimestampDelays(upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.GetTimestampDelays(&_VerifiableLoadMercuryUpkeep.CallOpts, upkeepId, timestampBucket) -} - func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) Intervals(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { var out []interface{} err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "intervals", arg0) @@ -1191,162 +944,108 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Ti return _VerifiableLoadMercuryUpkeep.Contract.TimeParamKey(&_VerifiableLoadMercuryUpkeep.CallOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) TimestampBuckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "timestampBuckets", arg0) + err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "upkeepTopUpCheckInterval") if err != nil { - return *new(uint16), err + return *new(*big.Int), err } - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) return out0, err } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) TimestampBuckets(arg0 *big.Int) (uint16, error) { - return _VerifiableLoadMercuryUpkeep.Contract.TimestampBuckets(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) UpkeepTopUpCheckInterval() (*big.Int, error) { + return _VerifiableLoadMercuryUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadMercuryUpkeep.CallOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) TimestampBuckets(arg0 *big.Int) (uint16, error) { - return _VerifiableLoadMercuryUpkeep.Contract.TimestampBuckets(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) UpkeepTopUpCheckInterval() (*big.Int, error) { + return _VerifiableLoadMercuryUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadMercuryUpkeep.CallOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) TimestampDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) { var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "timestampDelays", arg0, arg1, arg2) + err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "useArbitrumBlockNum") if err != nil { - return *new(*big.Int), err + return *new(bool), err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) return out0, err } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) TimestampDelays(arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.TimestampDelays(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0, arg1, arg2) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) UseArbitrumBlockNum() (bool, error) { + return _VerifiableLoadMercuryUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadMercuryUpkeep.CallOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) TimestampDelays(arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.TimestampDelays(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0, arg1, arg2) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) UseArbitrumBlockNum() (bool, error) { + return _VerifiableLoadMercuryUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadMercuryUpkeep.CallOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) Timestamps(opts *bind.CallOpts, arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "timestamps", arg0, arg1) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "acceptOwnership") +} - if err != nil { - return *new(*big.Int), err - } +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.AcceptOwnership(&_VerifiableLoadMercuryUpkeep.TransactOpts) +} - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.AcceptOwnership(&_VerifiableLoadMercuryUpkeep.TransactOpts) +} - return out0, err +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "addFunds", upkeepId, amount) +} +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.AddFunds(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, amount) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) Timestamps(arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.Timestamps(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0, arg1) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.AddFunds(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, amount) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) Timestamps(arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.Timestamps(&_VerifiableLoadMercuryUpkeep.CallOpts, arg0, arg1) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "batchCancelUpkeeps", upkeepIds) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "upkeepTopUpCheckInterval") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) UpkeepTopUpCheckInterval() (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadMercuryUpkeep.CallOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) UpkeepTopUpCheckInterval() (*big.Int, error) { - return _VerifiableLoadMercuryUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadMercuryUpkeep.CallOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCaller) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) { - var out []interface{} - err := _VerifiableLoadMercuryUpkeep.contract.Call(opts, &out, "useArbitrumBlockNum") - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) UseArbitrumBlockNum() (bool, error) { - return _VerifiableLoadMercuryUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadMercuryUpkeep.CallOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepCallerSession) UseArbitrumBlockNum() (bool, error) { - return _VerifiableLoadMercuryUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadMercuryUpkeep.CallOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "acceptOwnership") -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) AcceptOwnership() (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.AcceptOwnership(&_VerifiableLoadMercuryUpkeep.TransactOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.AcceptOwnership(&_VerifiableLoadMercuryUpkeep.TransactOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "addFunds", upkeepId, amount) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.AddFunds(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, amount) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepIds) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.AddFunds(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, amount) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepIds) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "batchCancelUpkeeps", upkeepIds) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "batchRegisterUpkeeps", number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepIds) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepIds) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "batchRegisterUpkeeps", number, gasLimit, amount, checkGasToBurn, performGasToBurn) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BatchSendLogs(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "batchSendLogs") } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, number, gasLimit, amount, checkGasToBurn, performGasToBurn) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) BatchSendLogs() (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BatchSendLogs(&_VerifiableLoadMercuryUpkeep.TransactOpts) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadMercuryUpkeep.TransactOpts, number, gasLimit, amount, checkGasToBurn, performGasToBurn) +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) BatchSendLogs() (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BatchSendLogs(&_VerifiableLoadMercuryUpkeep.TransactOpts) } func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BatchSetIntervals(opts *bind.TransactOpts, upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) { @@ -1385,6 +1084,18 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession return _VerifiableLoadMercuryUpkeep.Contract.BatchWithdrawLinks(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepIds) } +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) BurnPerformGas(opts *bind.TransactOpts, upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "burnPerformGas", upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) BurnPerformGas(upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BurnPerformGas(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) BurnPerformGas(upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.BurnPerformGas(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, startGas, blockNum) +} + func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) CancelUpkeep(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "cancelUpkeep", upkeepId) } @@ -1541,6 +1252,18 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession return _VerifiableLoadMercuryUpkeep.Contract.SetUpkeepTopUpCheckInterval(&_VerifiableLoadMercuryUpkeep.TransactOpts, newInterval) } +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "topUpFund", upkeepId, blockNum) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) TopUpFund(upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.TopUpFund(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, blockNum) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) TopUpFund(upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.TopUpFund(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId, blockNum) +} + func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "transferOwnership", to) } @@ -1586,678 +1309,23 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) Withdraw } func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.contract.RawTransact(opts, nil) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) Receive() (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.Receive(&_VerifiableLoadMercuryUpkeep.TransactOpts) -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) Receive() (*types.Transaction, error) { - return _VerifiableLoadMercuryUpkeep.Contract.Receive(&_VerifiableLoadMercuryUpkeep.TransactOpts) -} - -type VerifiableLoadMercuryUpkeepFundsAddedIterator struct { - Event *VerifiableLoadMercuryUpkeepFundsAdded - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadMercuryUpkeepFundsAddedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepFundsAdded) - 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(VerifiableLoadMercuryUpkeepFundsAdded) - 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 *VerifiableLoadMercuryUpkeepFundsAddedIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadMercuryUpkeepFundsAddedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadMercuryUpkeepFundsAdded struct { - UpkeepId *big.Int - Amount *big.Int - Raw types.Log -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterFundsAdded(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepFundsAddedIterator, error) { - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "FundsAdded") - if err != nil { - return nil, err - } - return &VerifiableLoadMercuryUpkeepFundsAddedIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "FundsAdded", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepFundsAdded) (event.Subscription, error) { - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "FundsAdded") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadMercuryUpkeepFundsAdded) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "FundsAdded", 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 (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseFundsAdded(log types.Log) (*VerifiableLoadMercuryUpkeepFundsAdded, error) { - event := new(VerifiableLoadMercuryUpkeepFundsAdded) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "FundsAdded", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadMercuryUpkeepInsufficientFundsIterator struct { - Event *VerifiableLoadMercuryUpkeepInsufficientFunds - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadMercuryUpkeepInsufficientFundsIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepInsufficientFunds) - 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(VerifiableLoadMercuryUpkeepInsufficientFunds) - 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 *VerifiableLoadMercuryUpkeepInsufficientFundsIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadMercuryUpkeepInsufficientFundsIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadMercuryUpkeepInsufficientFunds struct { - Balance *big.Int - BlockNum *big.Int - Raw types.Log -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterInsufficientFunds(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepInsufficientFundsIterator, error) { - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "InsufficientFunds") - if err != nil { - return nil, err - } - return &VerifiableLoadMercuryUpkeepInsufficientFundsIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "InsufficientFunds", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchInsufficientFunds(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepInsufficientFunds) (event.Subscription, error) { - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "InsufficientFunds") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadMercuryUpkeepInsufficientFunds) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "InsufficientFunds", 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 (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseInsufficientFunds(log types.Log) (*VerifiableLoadMercuryUpkeepInsufficientFunds, error) { - event := new(VerifiableLoadMercuryUpkeepInsufficientFunds) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "InsufficientFunds", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadMercuryUpkeepMercuryPerformEventIterator struct { - Event *VerifiableLoadMercuryUpkeepMercuryPerformEvent - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadMercuryUpkeepMercuryPerformEventIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepMercuryPerformEvent) - 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(VerifiableLoadMercuryUpkeepMercuryPerformEvent) - 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 *VerifiableLoadMercuryUpkeepMercuryPerformEventIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadMercuryUpkeepMercuryPerformEventIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadMercuryUpkeepMercuryPerformEvent struct { - Origin common.Address - UpkeepId *big.Int - BlockNumber *big.Int - V0 []byte - Ed []byte - Raw types.Log -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterMercuryPerformEvent(opts *bind.FilterOpts, origin []common.Address, upkeepId []*big.Int, blockNumber []*big.Int) (*VerifiableLoadMercuryUpkeepMercuryPerformEventIterator, error) { - - var originRule []interface{} - for _, originItem := range origin { - originRule = append(originRule, originItem) - } - var upkeepIdRule []interface{} - for _, upkeepIdItem := range upkeepId { - upkeepIdRule = append(upkeepIdRule, upkeepIdItem) - } - var blockNumberRule []interface{} - for _, blockNumberItem := range blockNumber { - blockNumberRule = append(blockNumberRule, blockNumberItem) - } - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "MercuryPerformEvent", originRule, upkeepIdRule, blockNumberRule) - if err != nil { - return nil, err - } - return &VerifiableLoadMercuryUpkeepMercuryPerformEventIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "MercuryPerformEvent", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchMercuryPerformEvent(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepMercuryPerformEvent, origin []common.Address, upkeepId []*big.Int, blockNumber []*big.Int) (event.Subscription, error) { - - var originRule []interface{} - for _, originItem := range origin { - originRule = append(originRule, originItem) - } - var upkeepIdRule []interface{} - for _, upkeepIdItem := range upkeepId { - upkeepIdRule = append(upkeepIdRule, upkeepIdItem) - } - var blockNumberRule []interface{} - for _, blockNumberItem := range blockNumber { - blockNumberRule = append(blockNumberRule, blockNumberItem) - } - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "MercuryPerformEvent", originRule, upkeepIdRule, blockNumberRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadMercuryUpkeepMercuryPerformEvent) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "MercuryPerformEvent", 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 (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseMercuryPerformEvent(log types.Log) (*VerifiableLoadMercuryUpkeepMercuryPerformEvent, error) { - event := new(VerifiableLoadMercuryUpkeepMercuryPerformEvent) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "MercuryPerformEvent", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator struct { - Event *VerifiableLoadMercuryUpkeepOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) - 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(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) - 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 *VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadMercuryUpkeepOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifiableLoadMercuryUpkeepOwnershipTransferRequested, error) { - event := new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadMercuryUpkeepOwnershipTransferredIterator struct { - Event *VerifiableLoadMercuryUpkeepOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadMercuryUpkeepOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepOwnershipTransferred) - 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(VerifiableLoadMercuryUpkeepOwnershipTransferred) - 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 *VerifiableLoadMercuryUpkeepOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadMercuryUpkeepOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadMercuryUpkeepOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadMercuryUpkeepOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &VerifiableLoadMercuryUpkeepOwnershipTransferredIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadMercuryUpkeepOwnershipTransferred) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return err - } - event.Raw = log + return _VerifiableLoadMercuryUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId) +} - 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 (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.RawTransact(opts, nil) } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseOwnershipTransferred(log types.Log) (*VerifiableLoadMercuryUpkeepOwnershipTransferred, error) { - event := new(VerifiableLoadMercuryUpkeepOwnershipTransferred) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) Receive() (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.Receive(&_VerifiableLoadMercuryUpkeep.TransactOpts) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) Receive() (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.Receive(&_VerifiableLoadMercuryUpkeep.TransactOpts) } -type VerifiableLoadMercuryUpkeepPerformingUpkeepIterator struct { - Event *VerifiableLoadMercuryUpkeepPerformingUpkeep +type VerifiableLoadMercuryUpkeepLogEmittedIterator struct { + Event *VerifiableLoadMercuryUpkeepLogEmitted contract *bind.BoundContract event string @@ -2268,7 +1336,7 @@ type VerifiableLoadMercuryUpkeepPerformingUpkeepIterator struct { fail error } -func (it *VerifiableLoadMercuryUpkeepPerformingUpkeepIterator) Next() bool { +func (it *VerifiableLoadMercuryUpkeepLogEmittedIterator) Next() bool { if it.fail != nil { return false @@ -2277,7 +1345,7 @@ func (it *VerifiableLoadMercuryUpkeepPerformingUpkeepIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepPerformingUpkeep) + it.Event = new(VerifiableLoadMercuryUpkeepLogEmitted) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2292,7 +1360,7 @@ func (it *VerifiableLoadMercuryUpkeepPerformingUpkeepIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepPerformingUpkeep) + it.Event = new(VerifiableLoadMercuryUpkeepLogEmitted) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2307,35 +1375,52 @@ func (it *VerifiableLoadMercuryUpkeepPerformingUpkeepIterator) Next() bool { } } -func (it *VerifiableLoadMercuryUpkeepPerformingUpkeepIterator) Error() error { +func (it *VerifiableLoadMercuryUpkeepLogEmittedIterator) Error() error { return it.fail } -func (it *VerifiableLoadMercuryUpkeepPerformingUpkeepIterator) Close() error { +func (it *VerifiableLoadMercuryUpkeepLogEmittedIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadMercuryUpkeepPerformingUpkeep struct { - FirstPerformBlock *big.Int - LastBlock *big.Int - PreviousBlock *big.Int - Counter *big.Int - Raw types.Log +type VerifiableLoadMercuryUpkeepLogEmitted struct { + UpkeepId *big.Int + BlockNum *big.Int + Addr common.Address + Raw types.Log } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterPerformingUpkeep(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepPerformingUpkeepIterator, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterLogEmitted(opts *bind.FilterOpts, upkeepId []*big.Int, blockNum []*big.Int) (*VerifiableLoadMercuryUpkeepLogEmittedIterator, error) { + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + var blockNumRule []interface{} + for _, blockNumItem := range blockNum { + blockNumRule = append(blockNumRule, blockNumItem) + } - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "PerformingUpkeep") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "LogEmitted", upkeepIdRule, blockNumRule) if err != nil { return nil, err } - return &VerifiableLoadMercuryUpkeepPerformingUpkeepIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "PerformingUpkeep", logs: logs, sub: sub}, nil + return &VerifiableLoadMercuryUpkeepLogEmittedIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "LogEmitted", logs: logs, sub: sub}, nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchPerformingUpkeep(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepPerformingUpkeep) (event.Subscription, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchLogEmitted(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepLogEmitted, upkeepId []*big.Int, blockNum []*big.Int) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "PerformingUpkeep") + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + var blockNumRule []interface{} + for _, blockNumItem := range blockNum { + blockNumRule = append(blockNumRule, blockNumItem) + } + + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "LogEmitted", upkeepIdRule, blockNumRule) if err != nil { return nil, err } @@ -2345,8 +1430,8 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchPe select { case log := <-logs: - event := new(VerifiableLoadMercuryUpkeepPerformingUpkeep) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "PerformingUpkeep", log); err != nil { + event := new(VerifiableLoadMercuryUpkeepLogEmitted) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "LogEmitted", log); err != nil { return err } event.Raw = log @@ -2367,17 +1452,17 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchPe }), nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParsePerformingUpkeep(log types.Log) (*VerifiableLoadMercuryUpkeepPerformingUpkeep, error) { - event := new(VerifiableLoadMercuryUpkeepPerformingUpkeep) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "PerformingUpkeep", log); err != nil { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseLogEmitted(log types.Log) (*VerifiableLoadMercuryUpkeepLogEmitted, error) { + event := new(VerifiableLoadMercuryUpkeepLogEmitted) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "LogEmitted", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadMercuryUpkeepReceivedIterator struct { - Event *VerifiableLoadMercuryUpkeepReceived +type VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator struct { + Event *VerifiableLoadMercuryUpkeepOwnershipTransferRequested contract *bind.BoundContract event string @@ -2388,7 +1473,7 @@ type VerifiableLoadMercuryUpkeepReceivedIterator struct { fail error } -func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Next() bool { +func (it *VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator) Next() bool { if it.fail != nil { return false @@ -2397,7 +1482,7 @@ func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepReceived) + it.Event = new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2412,7 +1497,7 @@ func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepReceived) + it.Event = new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2427,33 +1512,51 @@ func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Next() bool { } } -func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Error() error { +func (it *VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator) Error() error { return it.fail } -func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Close() error { +func (it *VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadMercuryUpkeepReceived struct { - Sender common.Address - Value *big.Int - Raw types.Log +type VerifiableLoadMercuryUpkeepOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepReceivedIterator, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "Received") + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) if err != nil { return nil, err } - return &VerifiableLoadMercuryUpkeepReceivedIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "Received", logs: logs, sub: sub}, nil + return &VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepReceived) (event.Subscription, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "Received") + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) if err != nil { return nil, err } @@ -2463,8 +1566,8 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchRe select { case log := <-logs: - event := new(VerifiableLoadMercuryUpkeepReceived) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "Received", log); err != nil { + event := new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { return err } event.Raw = log @@ -2485,17 +1588,17 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchRe }), nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseReceived(log types.Log) (*VerifiableLoadMercuryUpkeepReceived, error) { - event := new(VerifiableLoadMercuryUpkeepReceived) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "Received", log); err != nil { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifiableLoadMercuryUpkeepOwnershipTransferRequested, error) { + event := new(VerifiableLoadMercuryUpkeepOwnershipTransferRequested) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadMercuryUpkeepRegistrarSetIterator struct { - Event *VerifiableLoadMercuryUpkeepRegistrarSet +type VerifiableLoadMercuryUpkeepOwnershipTransferredIterator struct { + Event *VerifiableLoadMercuryUpkeepOwnershipTransferred contract *bind.BoundContract event string @@ -2506,7 +1609,7 @@ type VerifiableLoadMercuryUpkeepRegistrarSetIterator struct { fail error } -func (it *VerifiableLoadMercuryUpkeepRegistrarSetIterator) Next() bool { +func (it *VerifiableLoadMercuryUpkeepOwnershipTransferredIterator) Next() bool { if it.fail != nil { return false @@ -2515,7 +1618,7 @@ func (it *VerifiableLoadMercuryUpkeepRegistrarSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepRegistrarSet) + it.Event = new(VerifiableLoadMercuryUpkeepOwnershipTransferred) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2530,7 +1633,7 @@ func (it *VerifiableLoadMercuryUpkeepRegistrarSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepRegistrarSet) + it.Event = new(VerifiableLoadMercuryUpkeepOwnershipTransferred) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2545,32 +1648,51 @@ func (it *VerifiableLoadMercuryUpkeepRegistrarSetIterator) Next() bool { } } -func (it *VerifiableLoadMercuryUpkeepRegistrarSetIterator) Error() error { +func (it *VerifiableLoadMercuryUpkeepOwnershipTransferredIterator) Error() error { return it.fail } -func (it *VerifiableLoadMercuryUpkeepRegistrarSetIterator) Close() error { +func (it *VerifiableLoadMercuryUpkeepOwnershipTransferredIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadMercuryUpkeepRegistrarSet struct { - NewRegistrar common.Address - Raw types.Log +type VerifiableLoadMercuryUpkeepOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterRegistrarSet(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepRegistrarSetIterator, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadMercuryUpkeepOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "RegistrarSet") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) if err != nil { return nil, err } - return &VerifiableLoadMercuryUpkeepRegistrarSetIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "RegistrarSet", logs: logs, sub: sub}, nil + return &VerifiableLoadMercuryUpkeepOwnershipTransferredIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchRegistrarSet(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepRegistrarSet) (event.Subscription, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "RegistrarSet") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) if err != nil { return nil, err } @@ -2580,8 +1702,8 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchRe select { case log := <-logs: - event := new(VerifiableLoadMercuryUpkeepRegistrarSet) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "RegistrarSet", log); err != nil { + event := new(VerifiableLoadMercuryUpkeepOwnershipTransferred) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return err } event.Raw = log @@ -2602,17 +1724,17 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchRe }), nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseRegistrarSet(log types.Log) (*VerifiableLoadMercuryUpkeepRegistrarSet, error) { - event := new(VerifiableLoadMercuryUpkeepRegistrarSet) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "RegistrarSet", log); err != nil { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseOwnershipTransferred(log types.Log) (*VerifiableLoadMercuryUpkeepOwnershipTransferred, error) { + event := new(VerifiableLoadMercuryUpkeepOwnershipTransferred) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadMercuryUpkeepUpkeepTopUpIterator struct { - Event *VerifiableLoadMercuryUpkeepUpkeepTopUp +type VerifiableLoadMercuryUpkeepReceivedIterator struct { + Event *VerifiableLoadMercuryUpkeepReceived contract *bind.BoundContract event string @@ -2623,7 +1745,7 @@ type VerifiableLoadMercuryUpkeepUpkeepTopUpIterator struct { fail error } -func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Next() bool { +func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Next() bool { if it.fail != nil { return false @@ -2632,7 +1754,7 @@ func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepUpkeepTopUp) + it.Event = new(VerifiableLoadMercuryUpkeepReceived) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2647,7 +1769,7 @@ func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepUpkeepTopUp) + it.Event = new(VerifiableLoadMercuryUpkeepReceived) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2662,34 +1784,33 @@ func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Next() bool { } } -func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Error() error { +func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Error() error { return it.fail } -func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Close() error { +func (it *VerifiableLoadMercuryUpkeepReceivedIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadMercuryUpkeepUpkeepTopUp struct { - UpkeepId *big.Int - Amount *big.Int - BlockNum *big.Int - Raw types.Log +type VerifiableLoadMercuryUpkeepReceived struct { + Sender common.Address + Value *big.Int + Raw types.Log } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepUpkeepTopUpIterator, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepReceivedIterator, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "UpkeepTopUp") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "Received") if err != nil { return nil, err } - return &VerifiableLoadMercuryUpkeepUpkeepTopUpIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "UpkeepTopUp", logs: logs, sub: sub}, nil + return &VerifiableLoadMercuryUpkeepReceivedIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "Received", logs: logs, sub: sub}, nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepUpkeepTopUp) (event.Subscription, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepReceived) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "UpkeepTopUp") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "Received") if err != nil { return nil, err } @@ -2699,8 +1820,8 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUp select { case log := <-logs: - event := new(VerifiableLoadMercuryUpkeepUpkeepTopUp) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { + event := new(VerifiableLoadMercuryUpkeepReceived) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "Received", log); err != nil { return err } event.Raw = log @@ -2721,17 +1842,17 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUp }), nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadMercuryUpkeepUpkeepTopUp, error) { - event := new(VerifiableLoadMercuryUpkeepUpkeepTopUp) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseReceived(log types.Log) (*VerifiableLoadMercuryUpkeepReceived, error) { + event := new(VerifiableLoadMercuryUpkeepReceived) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "Received", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator struct { - Event *VerifiableLoadMercuryUpkeepUpkeepsCancelled +type VerifiableLoadMercuryUpkeepUpkeepTopUpIterator struct { + Event *VerifiableLoadMercuryUpkeepUpkeepTopUp contract *bind.BoundContract event string @@ -2742,7 +1863,7 @@ type VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator struct { fail error } -func (it *VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator) Next() bool { +func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Next() bool { if it.fail != nil { return false @@ -2751,7 +1872,7 @@ func (it *VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepUpkeepsCancelled) + it.Event = new(VerifiableLoadMercuryUpkeepUpkeepTopUp) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2766,7 +1887,7 @@ func (it *VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadMercuryUpkeepUpkeepsCancelled) + it.Event = new(VerifiableLoadMercuryUpkeepUpkeepTopUp) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2781,32 +1902,34 @@ func (it *VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator) Next() bool { } } -func (it *VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator) Error() error { +func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Error() error { return it.fail } -func (it *VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator) Close() error { +func (it *VerifiableLoadMercuryUpkeepUpkeepTopUpIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadMercuryUpkeepUpkeepsCancelled struct { - UpkeepIds []*big.Int - Raw types.Log +type VerifiableLoadMercuryUpkeepUpkeepTopUp struct { + UpkeepId *big.Int + Amount *big.Int + BlockNum *big.Int + Raw types.Log } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterUpkeepsCancelled(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepUpkeepTopUpIterator, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "UpkeepsCancelled") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.FilterLogs(opts, "UpkeepTopUp") if err != nil { return nil, err } - return &VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "UpkeepsCancelled", logs: logs, sub: sub}, nil + return &VerifiableLoadMercuryUpkeepUpkeepTopUpIterator{contract: _VerifiableLoadMercuryUpkeep.contract, event: "UpkeepTopUp", logs: logs, sub: sub}, nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUpkeepsCancelled(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepUpkeepsCancelled) (event.Subscription, error) { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepUpkeepTopUp) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "UpkeepsCancelled") + logs, sub, err := _VerifiableLoadMercuryUpkeep.contract.WatchLogs(opts, "UpkeepTopUp") if err != nil { return nil, err } @@ -2816,8 +1939,8 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUp select { case log := <-logs: - event := new(VerifiableLoadMercuryUpkeepUpkeepsCancelled) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "UpkeepsCancelled", log); err != nil { + event := new(VerifiableLoadMercuryUpkeepUpkeepTopUp) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { return err } event.Raw = log @@ -2838,9 +1961,9 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) WatchUp }), nil } -func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseUpkeepsCancelled(log types.Log) (*VerifiableLoadMercuryUpkeepUpkeepsCancelled, error) { - event := new(VerifiableLoadMercuryUpkeepUpkeepsCancelled) - if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "UpkeepsCancelled", log); err != nil { +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadMercuryUpkeepUpkeepTopUp, error) { + event := new(VerifiableLoadMercuryUpkeepUpkeepTopUp) + if err := _VerifiableLoadMercuryUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { return nil, err } event.Raw = log @@ -2966,26 +2089,16 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepFilterer) ParseUp func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeep) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { - case _VerifiableLoadMercuryUpkeep.abi.Events["FundsAdded"].ID: - return _VerifiableLoadMercuryUpkeep.ParseFundsAdded(log) - case _VerifiableLoadMercuryUpkeep.abi.Events["InsufficientFunds"].ID: - return _VerifiableLoadMercuryUpkeep.ParseInsufficientFunds(log) - case _VerifiableLoadMercuryUpkeep.abi.Events["MercuryPerformEvent"].ID: - return _VerifiableLoadMercuryUpkeep.ParseMercuryPerformEvent(log) + case _VerifiableLoadMercuryUpkeep.abi.Events["LogEmitted"].ID: + return _VerifiableLoadMercuryUpkeep.ParseLogEmitted(log) case _VerifiableLoadMercuryUpkeep.abi.Events["OwnershipTransferRequested"].ID: return _VerifiableLoadMercuryUpkeep.ParseOwnershipTransferRequested(log) case _VerifiableLoadMercuryUpkeep.abi.Events["OwnershipTransferred"].ID: return _VerifiableLoadMercuryUpkeep.ParseOwnershipTransferred(log) - case _VerifiableLoadMercuryUpkeep.abi.Events["PerformingUpkeep"].ID: - return _VerifiableLoadMercuryUpkeep.ParsePerformingUpkeep(log) case _VerifiableLoadMercuryUpkeep.abi.Events["Received"].ID: return _VerifiableLoadMercuryUpkeep.ParseReceived(log) - case _VerifiableLoadMercuryUpkeep.abi.Events["RegistrarSet"].ID: - return _VerifiableLoadMercuryUpkeep.ParseRegistrarSet(log) case _VerifiableLoadMercuryUpkeep.abi.Events["UpkeepTopUp"].ID: return _VerifiableLoadMercuryUpkeep.ParseUpkeepTopUp(log) - case _VerifiableLoadMercuryUpkeep.abi.Events["UpkeepsCancelled"].ID: - return _VerifiableLoadMercuryUpkeep.ParseUpkeepsCancelled(log) case _VerifiableLoadMercuryUpkeep.abi.Events["UpkeepsRegistered"].ID: return _VerifiableLoadMercuryUpkeep.ParseUpkeepsRegistered(log) @@ -2994,16 +2107,8 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeep) ParseLog(log ty } } -func (VerifiableLoadMercuryUpkeepFundsAdded) Topic() common.Hash { - return common.HexToHash("0x8137dc366612bf502338bd8951f835ad8ceba421c4eb3d79c7f9b3ce0ac4762e") -} - -func (VerifiableLoadMercuryUpkeepInsufficientFunds) Topic() common.Hash { - return common.HexToHash("0x03eb8b54a949acec2cd08fdb6d6bd4647a1f2c907d75d6900648effa92eb147f") -} - -func (VerifiableLoadMercuryUpkeepMercuryPerformEvent) Topic() common.Hash { - return common.HexToHash("0xcad583be2d908a590c81c7e332cf11c7a4ea41ecf1e059efac3ea7e83e34f1a5") +func (VerifiableLoadMercuryUpkeepLogEmitted) Topic() common.Hash { + return common.HexToHash("0x97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf08") } func (VerifiableLoadMercuryUpkeepOwnershipTransferRequested) Topic() common.Hash { @@ -3014,26 +2119,14 @@ func (VerifiableLoadMercuryUpkeepOwnershipTransferred) Topic() common.Hash { return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") } -func (VerifiableLoadMercuryUpkeepPerformingUpkeep) Topic() common.Hash { - return common.HexToHash("0x6b6b3eeaaf107627513e76a81662118e7b1d8c78866f70760262115ddcfeede3") -} - func (VerifiableLoadMercuryUpkeepReceived) Topic() common.Hash { return common.HexToHash("0x88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874") } -func (VerifiableLoadMercuryUpkeepRegistrarSet) Topic() common.Hash { - return common.HexToHash("0x6263309d5d4d1cfececd45a387cda7f14dccde21cf7a1bee1be6561075e61014") -} - func (VerifiableLoadMercuryUpkeepUpkeepTopUp) Topic() common.Hash { return common.HexToHash("0x49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c0") } -func (VerifiableLoadMercuryUpkeepUpkeepsCancelled) Topic() common.Hash { - return common.HexToHash("0xbeac20a03a6674e40498fac4356bc86e356c0d761a8d35d436712dc93bc7c74b") -} - func (VerifiableLoadMercuryUpkeepUpkeepsRegistered) Topic() common.Hash { return common.HexToHash("0x2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711") } @@ -3045,8 +2138,6 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeep) Address() commo type VerifiableLoadMercuryUpkeepInterface interface { BUCKETSIZE(opts *bind.CallOpts) (uint16, error) - TIMESTAMPINTERVAL(opts *bind.CallOpts) (uint16, error) - AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) BucketedDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) @@ -3055,8 +2146,6 @@ type VerifiableLoadMercuryUpkeepInterface interface { CheckCallback(opts *bind.CallOpts, values [][]byte, extraData []byte) (bool, []byte, error) - CheckDatas(opts *bind.CallOpts, arg0 *big.Int) ([]byte, error) - CheckGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) Counters(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) @@ -3067,6 +2156,8 @@ type VerifiableLoadMercuryUpkeepInterface interface { Eligible(opts *bind.CallOpts, upkeepId *big.Int) (bool, error) + EmittedSig(opts *bind.CallOpts) ([32]byte, error) + FeedParamKey(opts *bind.CallOpts) (string, error) FeedsHex(opts *bind.CallOpts, arg0 *big.Int) (string, error) @@ -3085,34 +2176,14 @@ type VerifiableLoadMercuryUpkeepInterface interface { GetDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) - GetDelaysLengthAtBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, error) - - GetDelaysLengthAtTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) - - GetPxBucketedDelaysForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) - - GetPxDelayForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) - - GetPxDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) - - GetPxDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) + GetLogTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) GetPxDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) - GetSumBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) - GetSumDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) - GetSumDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) - GetSumDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) - GetSumTimestampBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) - - GetTimestampBucketedDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) - - GetTimestampDelays(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) - Intervals(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) LastTopUpBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) @@ -3135,12 +2206,6 @@ type VerifiableLoadMercuryUpkeepInterface interface { TimeParamKey(opts *bind.CallOpts) (string, error) - TimestampBuckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) - - TimestampDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) - - Timestamps(opts *bind.CallOpts, arg0 *big.Int, arg1 *big.Int) (*big.Int, error) - UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) @@ -3151,7 +2216,9 @@ type VerifiableLoadMercuryUpkeepInterface interface { BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) - BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) + BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) + + BatchSendLogs(opts *bind.TransactOpts) (*types.Transaction, error) BatchSetIntervals(opts *bind.TransactOpts, upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) @@ -3159,6 +2226,8 @@ type VerifiableLoadMercuryUpkeepInterface interface { BatchWithdrawLinks(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) + BurnPerformGas(opts *bind.TransactOpts, upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) + CancelUpkeep(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) CheckUpkeep(opts *bind.TransactOpts, checkData []byte) (*types.Transaction, error) @@ -3185,6 +2254,8 @@ type VerifiableLoadMercuryUpkeepInterface interface { SetUpkeepTopUpCheckInterval(opts *bind.TransactOpts, newInterval *big.Int) (*types.Transaction, error) + TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) UpdateUpkeepPipelineData(opts *bind.TransactOpts, upkeepId *big.Int, pipelineData []byte) (*types.Transaction, error) @@ -3195,23 +2266,11 @@ type VerifiableLoadMercuryUpkeepInterface interface { Receive(opts *bind.TransactOpts) (*types.Transaction, error) - FilterFundsAdded(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepFundsAddedIterator, error) - - WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepFundsAdded) (event.Subscription, error) - - ParseFundsAdded(log types.Log) (*VerifiableLoadMercuryUpkeepFundsAdded, error) - - FilterInsufficientFunds(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepInsufficientFundsIterator, error) + FilterLogEmitted(opts *bind.FilterOpts, upkeepId []*big.Int, blockNum []*big.Int) (*VerifiableLoadMercuryUpkeepLogEmittedIterator, error) - WatchInsufficientFunds(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepInsufficientFunds) (event.Subscription, error) + WatchLogEmitted(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepLogEmitted, upkeepId []*big.Int, blockNum []*big.Int) (event.Subscription, error) - ParseInsufficientFunds(log types.Log) (*VerifiableLoadMercuryUpkeepInsufficientFunds, error) - - FilterMercuryPerformEvent(opts *bind.FilterOpts, origin []common.Address, upkeepId []*big.Int, blockNumber []*big.Int) (*VerifiableLoadMercuryUpkeepMercuryPerformEventIterator, error) - - WatchMercuryPerformEvent(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepMercuryPerformEvent, origin []common.Address, upkeepId []*big.Int, blockNumber []*big.Int) (event.Subscription, error) - - ParseMercuryPerformEvent(log types.Log) (*VerifiableLoadMercuryUpkeepMercuryPerformEvent, error) + ParseLogEmitted(log types.Log) (*VerifiableLoadMercuryUpkeepLogEmitted, error) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadMercuryUpkeepOwnershipTransferRequestedIterator, error) @@ -3225,36 +2284,18 @@ type VerifiableLoadMercuryUpkeepInterface interface { ParseOwnershipTransferred(log types.Log) (*VerifiableLoadMercuryUpkeepOwnershipTransferred, error) - FilterPerformingUpkeep(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepPerformingUpkeepIterator, error) - - WatchPerformingUpkeep(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepPerformingUpkeep) (event.Subscription, error) - - ParsePerformingUpkeep(log types.Log) (*VerifiableLoadMercuryUpkeepPerformingUpkeep, error) - FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepReceivedIterator, error) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepReceived) (event.Subscription, error) ParseReceived(log types.Log) (*VerifiableLoadMercuryUpkeepReceived, error) - FilterRegistrarSet(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepRegistrarSetIterator, error) - - WatchRegistrarSet(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepRegistrarSet) (event.Subscription, error) - - ParseRegistrarSet(log types.Log) (*VerifiableLoadMercuryUpkeepRegistrarSet, error) - FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepUpkeepTopUpIterator, error) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepUpkeepTopUp) (event.Subscription, error) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadMercuryUpkeepUpkeepTopUp, error) - FilterUpkeepsCancelled(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepUpkeepsCancelledIterator, error) - - WatchUpkeepsCancelled(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepUpkeepsCancelled) (event.Subscription, error) - - ParseUpkeepsCancelled(log types.Log) (*VerifiableLoadMercuryUpkeepUpkeepsCancelled, error) - FilterUpkeepsRegistered(opts *bind.FilterOpts) (*VerifiableLoadMercuryUpkeepUpkeepsRegisteredIterator, error) WatchUpkeepsRegistered(opts *bind.WatchOpts, sink chan<- *VerifiableLoadMercuryUpkeepUpkeepsRegistered) (event.Subscription, error) diff --git a/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go index 5d0105bba68..dae8eaf30bf 100644 --- a/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go @@ -31,8 +31,8 @@ var ( ) var VerifiableLoadUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registrarAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"balance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"InsufficientFunds\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"uint256\",\"name\":\"firstPerformBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"lastBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"previousBlock\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"counter\",\"type\":\"uint256\"}],\"name\":\"PerformingUpkeep\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"RegistrarSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsCancelled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"TIMESTAMP_INTERVAL\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkDatas\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getDelaysLengthAtBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getDelaysLengthAtTimestampBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"}],\"name\":\"getPxBucketedDelaysForAllUpkeeps\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"}],\"name\":\"getPxDelayForAllUpkeeps\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getPxDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getPxDelayInTimestampBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumBucketedDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInTimestampBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumTimestampBucketedDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTimestampBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"timestampBucket\",\"type\":\"uint16\"}],\"name\":\"getTimestampDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractKeeperRegistrar2_0\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractKeeperRegistrar2_0\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"timestampBuckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"timestampDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"timestamps\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60e06040526005601855601980546001600160681b0319166c140000000002c68af0bb140000179055601960f21b60a05260e160f41b60c0523480156200004557600080fd5b50604051620053bc380380620053bc833981016040819052620000689162000320565b81813380600081620000c15760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000f457620000f4816200025a565b5050601580546001600160a01b0319166001600160a01b0385169081179091556040805163850af0cb60e01b815290516000935063850af0cb9160048082019260a092909190829003018186803b1580156200014f57600080fd5b505afa15801562000164573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200018a91906200038a565b50601780546001600160a01b0319166001600160a01b038381169190911790915560155460408051631b6b6d2360e01b8152905193975091169450631b6b6d2393506004808201935060209291829003018186803b158015620001ec57600080fd5b505afa15801562000201573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000227919062000363565b601680546001600160a01b0319166001600160a01b039290921691909117905550151560f81b6080525062000413915050565b6001600160a01b038116331415620002b55760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000b8565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b805163ffffffff811681146200031b57600080fd5b919050565b600080604083850312156200033457600080fd5b82516200034181620003fa565b602084015190925080151581146200035857600080fd5b809150509250929050565b6000602082840312156200037657600080fd5b81516200038381620003fa565b9392505050565b600080600080600060a08688031215620003a357600080fd5b855160038110620003b357600080fd5b9450620003c36020870162000306565b9350620003d36040870162000306565b92506060860151620003e581620003fa565b80925050608086015190509295509295909350565b6001600160a01b03811681146200041057600080fd5b50565b60805160f81c60a05160f01c60c05160f01c614f5b620004616000396000818161064d015261199e0152600081816105230152611ab20152600081816108fc015261383f0152614f5b6000f3fe6080604052600436106104695760003560e01c80637b10399911610243578063a72aa27e11610143578063daee1aeb116100bb578063f2fde38b1161008a578063fba7ffa31161006f578063fba7ffa314610fbb578063fbfb4f7614610fe8578063fcdc1f631461100857600080fd5b8063f2fde38b14610f7b578063fb0ceb0414610f9b57600080fd5b8063daee1aeb14610ef8578063dbef701e14610f18578063e0114adb14610f38578063e455308314610f6557600080fd5b8063becde0e111610112578063c8048022116100f7578063c804802214610e59578063d355852814610e79578063d6051a7214610ed857600080fd5b8063becde0e114610ddf578063c357f1f314610dff57600080fd5b8063a72aa27e14610d34578063a79c404314610d54578063af953a4a14610d81578063b0971e1a14610da157600080fd5b80639095aa35116101d65780639b429354116101a55780639d385eaa1161018a5780639d385eaa14610cd4578063a5f5893414610cf4578063a6c60d8914610d1457600080fd5b80639b42935414610c765780639b51fb0d14610ca357600080fd5b80639095aa3514610bda578063948108f714610bfa57806399cc6b0b14610c1a5780639ac542eb14610c3a57600080fd5b806387dfa9001161021257806387dfa90014610b425780638bc7b77214610b625780638da5cb5b14610b825780638fcb3fba14610bad57600080fd5b80637b10399914610ab55780637e4087b814610ae25780637e7a46dc14610b025780638237831714610b2257600080fd5b806351c98be31161036957806369cdbadb116102e15780637145f11b116102b057806376721303116102955780637672130314610a53578063776898c814610a8057806379ba509714610aa057600080fd5b80637145f11b146109f657806373644cce14610a2657600080fd5b806369cdbadb1461094e57806369e9b7731461097b5780636e04ff0d146109a85780637137a702146109d657600080fd5b80635f17e61611610338578063636092e81161031d578063636092e8146108a8578063642f6cef146108ea578063643b34e91461092e57600080fd5b80635f17e6161461085b57806360457ff51461087b57600080fd5b806351c98be3146107cc57806357970e93146107ec57806358c52c04146108195780635d4ee7f31461084657600080fd5b806329f0e496116103fc57806333774d1c116103cb5780634585e33b116103b05780634585e33b1461075f57806345d2ec171461077f57806346e7a63e1461079f57600080fd5b806333774d1c1461070e5780633ebe8d6c1461073f57600080fd5b806329f0e4961461063b5780632a9032d31461066f5780632b20e3971461068f578063328ffd11146106e157600080fd5b80631bee0080116104385780631bee008014610596578063206c32e8146105c457806320e3dbd4146105f957806328c4b57b1461061b57600080fd5b806306e3b632146104ad578063077ac621146104e357806312c5502714610511578063177b0eb91461055857600080fd5b366104a857604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b3480156104b957600080fd5b506104cd6104c8366004614515565b611035565b6040516104da9190614775565b60405180910390f35b3480156104ef57600080fd5b506105036104fe3660046144e0565b611131565b6040519081526020016104da565b34801561051d57600080fd5b506105457f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff90911681526020016104da565b34801561056457600080fd5b506105036105733660046144b4565b6000918252600f6020908152604080842061ffff93909316845291905290205490565b3480156105a257600080fd5b506105b66105b13660046141d0565b61116f565b6040516104da929190614788565b3480156105d057600080fd5b506105e46105df3660046144b4565b611478565b604080519283526020830191909152016104da565b34801561060557600080fd5b506106196106143660046140ff565b6114fb565b005b34801561062757600080fd5b5061050361063636600461456c565b61171c565b34801561064757600080fd5b506105457f000000000000000000000000000000000000000000000000000000000000000081565b34801561067b57600080fd5b5061061961068a36600461411c565b611787565b34801561069b57600080fd5b506015546106bc9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016104da565b3480156106ed57600080fd5b506105036106fc3660046141d0565b60036020526000908152604090205481565b34801561071a57600080fd5b506105456107293660046141d0565b60116020526000908152604090205461ffff1681565b34801561074b57600080fd5b5061050361075a3660046141d0565b61185a565b34801561076b57600080fd5b5061061961077a3660046141e9565b6118c3565b34801561078b57600080fd5b506104cd61079a3660046144b4565b611f65565b3480156107ab57600080fd5b506105036107ba3660046141d0565b600a6020526000908152604090205481565b3480156107d857600080fd5b506106196107e736600461415e565b611fd4565b3480156107f857600080fd5b506016546106bc9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561082557600080fd5b506108396108343660046141d0565b612078565b6040516104da91906147c8565b34801561085257600080fd5b50610619612112565b34801561086757600080fd5b50610619610876366004614515565b61226b565b34801561088757600080fd5b506105036108963660046141d0565b60076020526000908152604090205481565b3480156108b457600080fd5b506019546108cd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff90911681526020016104da565b3480156108f657600080fd5b5061091e7f000000000000000000000000000000000000000000000000000000000000000081565b60405190151581526020016104da565b34801561093a57600080fd5b506105e4610949366004614515565b6123dd565b34801561095a57600080fd5b506105036109693660046141d0565b60086020526000908152604090205481565b34801561098757600080fd5b50610619610996366004614515565b60009182526008602052604090912055565b3480156109b457600080fd5b506109c86109c33660046141e9565b612562565b6040516104da9291906147ad565b3480156109e257600080fd5b506105036109f13660046144e0565b61268f565b348015610a0257600080fd5b5061091e610a113660046141d0565b600c6020526000908152604090205460ff1681565b348015610a3257600080fd5b50610503610a413660046141d0565b6000908152600d602052604090205490565b348015610a5f57600080fd5b50610503610a6e3660046141d0565b60046020526000908152604090205481565b348015610a8c57600080fd5b5061091e610a9b3660046141d0565b6126b7565b348015610aac57600080fd5b50610619612707565b348015610ac157600080fd5b506017546106bc9073ffffffffffffffffffffffffffffffffffffffff1681565b348015610aee57600080fd5b506105e4610afd366004614515565b612809565b348015610b0e57600080fd5b50610619610b1d3660046143e3565b612981565b348015610b2e57600080fd5b50610503610b3d366004614537565b612a2c565b348015610b4e57600080fd5b50610503610b5d366004614537565b612aa7565b348015610b6e57600080fd5b506105b6610b7d3660046141d0565b612b17565b348015610b8e57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166106bc565b348015610bb957600080fd5b50610503610bc83660046141d0565b60056020526000908152604090205481565b348015610be657600080fd5b50610619610bf5366004614608565b612c8c565b348015610c0657600080fd5b50610619610c153660046145c8565b612f0c565b348015610c2657600080fd5b506104cd610c353660046144b4565b6130a4565b348015610c4657600080fd5b50601954610c64906c01000000000000000000000000900460ff1681565b60405160ff90911681526020016104da565b348015610c8257600080fd5b50610619610c91366004614515565b60009182526009602052604090912055565b348015610caf57600080fd5b50610545610cbe3660046141d0565b60126020526000908152604090205461ffff1681565b348015610ce057600080fd5b506104cd610cef3660046141d0565b613111565b348015610d0057600080fd5b50610503610d0f3660046141d0565b613173565b348015610d2057600080fd5b50610619610d2f3660046141d0565b601855565b348015610d4057600080fd5b50610619610d4f366004614598565b6131d4565b348015610d6057600080fd5b50610619610d6f366004614515565b60009182526007602052604090912055565b348015610d8d57600080fd5b50610619610d9c3660046141d0565b61327f565b348015610dad57600080fd5b50610503610dbc3660046144b4565b6000918252600e6020908152604080842061ffff93909316845291905290205490565b348015610deb57600080fd5b50610619610dfa36600461411c565b613305565b348015610e0b57600080fd5b50610619610e1a366004614661565b601980547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610e6557600080fd5b50610619610e743660046141d0565b61339f565b348015610e8557600080fd5b50610619610e943660046145ed565b6019805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610ee457600080fd5b506105e4610ef3366004614515565b613437565b348015610f0457600080fd5b50610619610f1336600461411c565b6134a0565b348015610f2457600080fd5b50610503610f33366004614515565b61356b565b348015610f4457600080fd5b50610503610f533660046141d0565b60096020526000908152604090205481565b348015610f7157600080fd5b5061050360185481565b348015610f8757600080fd5b50610619610f963660046140ff565b61359c565b348015610fa757600080fd5b50610503610fb6366004614515565b6135b0565b348015610fc757600080fd5b50610503610fd63660046141d0565b60066020526000908152604090205481565b348015610ff457600080fd5b506105e46110033660046144b4565b6135cc565b34801561101457600080fd5b506105036110233660046141d0565b60026020526000908152604090205481565b606060006110436013613640565b905080841061107e576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826110905761108d8482614c14565b92505b60008367ffffffffffffffff8111156110ab576110ab614ed1565b6040519080825280602002602001820160405280156110d4578160200160208202803683370190505b50905060005b84811015611126576110f76110ef8288614a9b565b60139061364a565b82828151811061110957611109614ea2565b60209081029190910101528061111e81614da9565b9150506110da565b509150505b92915050565b600e602052826000526040600020602052816000526040600020818154811061115957600080fd5b9060005260206000200160009250925050505481565b606080600061117e6013613640565b905060008167ffffffffffffffff81111561119b5761119b614ed1565b6040519080825280602002602001820160405280156111c4578160200160208202803683370190505b50905060008267ffffffffffffffff8111156111e2576111e2614ed1565b60405190808252806020026020018201604052801561120b578160200160208202803683370190505b50905060005b8381101561146c57600061122660138361364a565b90508084838151811061123b5761123b614ea2565b6020908102919091018101919091526000828152601290915260408082205490517f3ebe8d6c0000000000000000000000000000000000000000000000000000000081526004810184905261ffff90911691903090633ebe8d6c9060240160206040518083038186803b1580156112b157600080fd5b505afa1580156112c5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112e991906143ca565b905060008167ffffffffffffffff81111561130657611306614ed1565b60405190808252806020026020018201604052801561132f578160200160208202803683370190505b506000858152600e6020526040812091925090815b8561ffff168161ffff16116114295761ffff8116600090815260208381526040808320805482518185028101850190935280835291929091908301828280156113ac57602002820191906000526020600020905b815481526020019060010190808311611398575b5050505050905060005b8151811015611414578181815181106113d1576113d1614ea2565b60200260200101518686806113e590614da9565b9750815181106113f7576113f7614ea2565b60209081029190910101528061140c81614da9565b9150506113b6565b5050808061142190614d87565b915050611344565b50611435838e86613656565b88888151811061144757611447614ea2565b602002602001018181525050505050505050808061146490614da9565b915050611211565b50909590945092505050565b6000828152600e6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156114dc57602002820191906000526020600020905b8154815260200190600101908083116114c8575b505050505090506114ee8182516137b6565b92509250505b9250929050565b601580547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517f850af0cb00000000000000000000000000000000000000000000000000000000815290516000929163850af0cb9160048083019260a0929190829003018186803b15801561159057600080fd5b505afa1580156115a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c8919061423c565b50601780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601554604080517f1b6b6d23000000000000000000000000000000000000000000000000000000008152905193975091169450631b6b6d2393506004808201935060209291829003018186803b15801561166757600080fd5b505afa15801561167b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061169f919061421f565b601680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff928316179055601554604051911681527f6263309d5d4d1cfececd45a387cda7f14dccde21cf7a1bee1be6561075e61014906020015b60405180910390a15050565b6000838152600d60209081526040808320805482518185028101850190935280835261177d9383018282801561177157602002820191906000526020600020905b81548152602001906001019080831161175d575b50505050508484613656565b90505b9392505050565b8060005b818160ff16101561181b573063c8048022858560ff85168181106117b1576117b1614ea2565b905060200201356040518263ffffffff1660e01b81526004016117d691815260200190565b600060405180830381600087803b1580156117f057600080fd5b505af1158015611804573d6000803e3d6000fd5b50505050808061181390614df5565b91505061178b565b507fbeac20a03a6674e40498fac4356bc86e356c0d761a8d35d436712dc93bc7c74b838360405161184d929190614720565b60405180910390a1505050565b60008181526012602052604081205461ffff1681805b8261ffff168161ffff16116118bb576000858152600e6020908152604080832061ffff851684529091529020546118a79083614a9b565b9150806118b381614d87565b915050611870565b509392505050565b60005a905060006118d68385018561442f565b50600081815260056020908152604080832054600490925282205492935091906118fe61383b565b9050826119385760008481526005602090815260408083208490556010825282208054600181018255908352912042910155915081611b98565b6000848152600360205260408120546119518484614c14565b61195b9190614c14565b6000868152601160209081526040808320546010909252909120805492935061ffff909116918290811061199157611991614ea2565b90600052602060002001547f000000000000000000000000000000000000000000000000000000000000000061ffff16426119cc9190614c14565b1115611a3b57600086815260106020908152604082208054600181018255908352912042910155806119fd81614d87565b600088815260116020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559150505b600086815260126020908152604080832054600e835281842061ffff9091168085529083528184208054835181860281018601909452808452919493909190830182828015611aa957602002820191906000526020600020905b815481526020019060010190808311611a95575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff1681511415611b255781611ae781614d87565b60008a815260126020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600e6020908152604080832061ffff94851684528252808320805460018181018355918552838520018790558a8452600f83528184209590941683529381528382208054808501825590835281832001859055888252600d81529281208054928301815581529190912001555b600084815260066020526040812054611bb2906001614a9b565b6000868152600660209081526040918290208390558151878152908101859052908101859052606081018290529091507f6b6b3eeaaf107627513e76a81662118e7b1d8c78866f70760262115ddcfeede39060800160405180910390a16000858152600460209081526040808320859055601854600290925290912054611c399084614c14565b1115611ee4576017546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810187905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a9060240160006040518083038186803b158015611caa57600080fd5b505afa158015611cbe573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611d0491908101906142ab565b6017546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810189905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c9060240160206040518083038186803b158015611d7457600080fd5b505afa158015611d88573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dac919061467e565b601954909150611dd09082906c01000000000000000000000000900460ff16614b6c565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff161015611ee1576019546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018990526bffffffffffffffffffffffff9091166024820152309063948108f790604401600060405180830381600087803b158015611e6157600080fd5b505af1158015611e75573d6000803e3d6000fd5b50505060008881526002602090815260409182902087905560195482518b81526bffffffffffffffffffffffff909116918101919091529081018690527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c0915060600160405180910390a15b50505b6000858152600760205260409020545b805a611f009089614c14565b611f0c90612710614a9b565b1015611f5a5782406000908152600c6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905582611f5281614ceb565b935050611ef4565b505050505050505050565b6000828152600e6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611fc757602002820191906000526020600020905b815481526020019060010190808311611fb3575b5050505050905092915050565b8160005b818110156120715730635f17e616868684818110611ff857611ff8614ea2565b90506020020135856040518363ffffffff1660e01b815260040161202c92919091825263ffffffff16602082015260400190565b600060405180830381600087803b15801561204657600080fd5b505af115801561205a573d6000803e3d6000fd5b50505050808061206990614da9565b915050611fd8565b5050505050565b600b602052600090815260409020805461209190614cfa565b80601f01602080910402602001604051908101604052809291908181526020018280546120bd90614cfa565b801561210a5780601f106120df5761010080835404028352916020019161210a565b820191906000526020600020905b8154815290600101906020018083116120ed57829003601f168201915b505050505081565b61211a6138ec565b6016546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a082319060240160206040518083038186803b15801561218457600080fd5b505afa158015612198573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121bc91906143ca565b6016546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb90604401602060405180830381600087803b15801561222f57600080fd5b505af1158015612243573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061226791906141b5565b5050565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600d90915281206122a391613e6c565b60008281526012602052604081205461ffff16905b8161ffff168161ffff16116122ff576000848152600e6020908152604080832061ffff8516845290915281206122ed91613e6c565b806122f781614d87565b9150506122b8565b5050600082815260126020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055601190915281205461ffff16905b8161ffff168161ffff161161238d576000848152600f6020908152604080832061ffff85168452909152812061237b91613e6c565b8061238581614d87565b915050612346565b5060008381526010602052604081206123a591613e6c565b5050600090815260116020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6040517f3ebe8d6c00000000000000000000000000000000000000000000000000000000815260048101839052600090819081903090633ebe8d6c9060240160206040518083038186803b15801561243457600080fd5b505afa158015612448573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061246c91906143ca565b905083158061247b5750808410155b15612484578093505b60008581526012602052604081205485919061ffff16805b6000898152600e6020908152604080832061ffff851684528252808320805482518185028101850190935280835291929091908301828280156124fe57602002820191906000526020600020905b8154815260200190600101908083116124ea575b5050505050905060008061251283886137b6565b90925090506125218287614a9b565b955061252d8188614c14565b96506000871161253f57505050612555565b505050808061254d90614caf565b91505061249c565b5090979596505050505050565b6000606060005a90506000612579858701876141d0565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff8111156125b2576125b2614ed1565b6040519080825280601f01601f1916602001820160405280156125dc576020820181803683370190505b506040516020016125ee92919061494f565b6040516020818303038152906040529050600061260961383b565b90506000612616866126b7565b90505b835a6126259089614c14565b61263190612710614a9b565b101561267f5781406000908152600c6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690558161267781614ceb565b925050612619565b9a91995090975050505050505050565b600f602052826000526040600020602052816000526040600020818154811061115957600080fd5b6000818152600560205260408120546126d257506001919050565b6000828152600360209081526040808320546004909252909120546126f561383b565b6126ff9190614c14565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461278d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6040517fa5f589340000000000000000000000000000000000000000000000000000000081526004810183905260009081908190309063a5f589349060240160206040518083038186803b15801561286057600080fd5b505afa158015612874573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061289891906143ca565b90508315806128a75750808410155b156128b0578093505b60008581526011602052604081205485919061ffff16805b6000898152600f6020908152604080832061ffff8516845282528083208054825181850281018501909352808352919290919083018282801561292a57602002820191906000526020600020905b815481526020019060010190808311612916575b5050505050905060008061293e83886137b6565b909250905061294d8287614a9b565b95506129598188614c14565b96506000871161296b57505050612555565b505050808061297990614caf565b9150506128c8565b6017546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b5906129db908690869086906004016148fb565b600060405180830381600087803b1580156129f557600080fd5b505af1158015612a09573d6000803e3d6000fd5b5050506000848152600b60205260409020612a2691508383613e8a565b50505050565b6000838152600e6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493830182828015612a8b57602002820191906000526020600020905b815481526020019060010190808311612a77575b50505050509050612a9e81858351613656565b95945050505050565b6000838152600f6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493830182828015612a8b5760200282019190600052602060002090815481526020019060010190808311612a775750505050509050612a9e81858351613656565b6060806000612b266013613640565b905060008167ffffffffffffffff811115612b4357612b43614ed1565b604051908082528060200260200182016040528015612b6c578160200160208202803683370190505b50905060008267ffffffffffffffff811115612b8a57612b8a614ed1565b604051908082528060200260200182016040528015612bb3578160200160208202803683370190505b50905060005b8381101561146c576000612bce60138361364a565b6000818152600d6020908152604080832080548251818502810185019093528083529495509293909291830182828015612c2757602002820191906000526020600020905b815481526020019060010190808311612c13575b5050505050905081858481518110612c4157612c41614ea2565b602002602001018181525050612c59818a8351613656565b848481518110612c6b57612c6b614ea2565b60200260200101818152505050508080612c8490614da9565b915050612bb9565b6040805161014081018252600461010082019081527f746573740000000000000000000000000000000000000000000000000000000061012083015281528151602081810184526000808352818401929092523083850181905263ffffffff8916606085015260808401528351808201855282815260a08401528351908101909352825260c08101919091526bffffffffffffffffffffffff841660e082015260165460155473ffffffffffffffffffffffffffffffffffffffff9182169163095ea7b39116612d5f60ff8a1688614b6c565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff166024820152604401602060405180830381600087803b158015612dd857600080fd5b505af1158015612dec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e1091906141b5565b5060008660ff1667ffffffffffffffff811115612e2f57612e2f614ed1565b604051908082528060200260200182016040528015612e58578160200160208202803683370190505b50905060005b8760ff168160ff161015612ecb576000612e778461396f565b905080838360ff1681518110612e8f57612e8f614ea2565b60209081029190910181019190915260009182526008815260408083208890556007909152902084905580612ec381614df5565b915050612e5e565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c71181604051612efb9190614775565b60405180910390a150505050505050565b6016546017546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b390604401602060405180830381600087803b158015612f8f57600080fd5b505af1158015612fa3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612fc791906141b5565b506017546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561304857600080fd5b505af115801561305c573d6000803e3d6000fd5b5050604080518581526bffffffffffffffffffffffff851660208201527f8137dc366612bf502338bd8951f835ad8ceba421c4eb3d79c7f9b3ce0ac4762e9350019050611710565b6000828152600f6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611fc75760200282019190600052602060002090815481526020019060010190808311611fb3575050505050905092915050565b6000818152600d602090815260409182902080548351818402810184019094528084526060939283018282801561316757602002820191906000526020600020905b815481526020019060010190808311613153575b50505050509050919050565b60008181526011602052604081205461ffff1681805b8261ffff168161ffff16116118bb576000858152600f6020908152604080832061ffff851684529091529020546131c09083614a9b565b9150806131cc81614d87565b915050613189565b6017546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561324c57600080fd5b505af1158015613260573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6017546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b1580156132f157600080fd5b505af1158015612071573d6000803e3d6000fd5b8060005b818163ffffffff161015612a26573063af953a4a858563ffffffff851681811061333557613335614ea2565b905060200201356040518263ffffffff1660e01b815260040161335a91815260200190565b600060405180830381600087803b15801561337457600080fd5b505af1158015613388573d6000803e3d6000fd5b50505050808061339790614ddb565b915050613309565b6017546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561340b57600080fd5b505af115801561341f573d6000803e3d6000fd5b50505050612267816013613a7190919063ffffffff16565b6000828152600d6020908152604080832080548251818502810185019093528083528493849392919083018282801561348f57602002820191906000526020600020905b81548152602001906001019080831161347b575b505050505090506114ee81856137b6565b8060005b81811015612a265760008484838181106134c0576134c0614ea2565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc82836040516020016134f991815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161352592919061494f565b600060405180830381600087803b15801561353f57600080fd5b505af1158015613553573d6000803e3d6000fd5b5050505050808061356390614da9565b9150506134a4565b600d602052816000526040600020818154811061358757600080fd5b90600052602060002001600091509150505481565b6135a46138ec565b6135ad81613a7d565b50565b6010602052816000526040600020818154811061358757600080fd5b6000828152600f6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156114dc57602002820191906000526020600020908154815260200190600101908083116114c857505050505090506114ee8182516137b6565b600061112b825490565b60006117808383613b73565b8251600090819083158061366a5750808410155b15613673578093505b60008467ffffffffffffffff81111561368e5761368e614ed1565b6040519080825280602002602001820160405280156136b7578160200160208202803683370190505b509050600092505b84831015613725578660016136d48585614c14565b6136de9190614c14565b815181106136ee576136ee614ea2565b602002602001015181848151811061370857613708614ea2565b60209081029190910101528261371d81614da9565b9350506136bf565b61373e816000600184516137399190614c14565b613b9d565b85606414156137785780600182516137569190614c14565b8151811061376657613766614ea2565b60200260200101519350505050611780565b8060648251886137889190614b2f565b6137929190614b1b565b815181106137a2576137a2614ea2565b602002602001015193505050509392505050565b8151600090819081908415806137cc5750808510155b156137d5578094505b60008092505b85831015613831578660016137f08585614c14565b6137fa9190614c14565b8151811061380a5761380a614ea2565b60200260200101518161381d9190614a9b565b90508261382981614da9565b9350506137db565b9694955050505050565b60007f0000000000000000000000000000000000000000000000000000000000000000156138e757606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b1580156138aa57600080fd5b505afa1580156138be573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138e291906143ca565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331461396d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612784565b565b6015546040517f08b79da4000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff909116906308b79da4906139ca9086906004016147db565b602060405180830381600087803b1580156139e457600080fd5b505af11580156139f8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a1c91906143ca565b9050613a29601382613d1e565b5060608301516000828152600a6020908152604080832063ffffffff90941690935560a0860151600b8252929091208251613a6a9391929190910190613f2c565b5092915050565b60006117808383613d2a565b73ffffffffffffffffffffffffffffffffffffffff8116331415613afd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612784565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000826000018281548110613b8a57613b8a614ea2565b9060005260206000200154905092915050565b818180821415613bae575050505050565b6000856002613bbd8787614ba0565b613bc79190614ab3565b613bd19087614a27565b81518110613be157613be1614ea2565b602002602001015190505b818313613cf0575b80868481518110613c0757613c07614ea2565b60200260200101511015613c275782613c1f81614d4e565b935050613bf4565b858281518110613c3957613c39614ea2565b6020026020010151811015613c5a5781613c5281614c57565b925050613c27565b818313613ceb57858281518110613c7357613c73614ea2565b6020026020010151868481518110613c8d57613c8d614ea2565b6020026020010151878581518110613ca757613ca7614ea2565b60200260200101888581518110613cc057613cc0614ea2565b60209081029190910101919091525282613cd981614d4e565b9350508180613ce790614c57565b9250505b613bec565b81851215613d0357613d03868684613b9d565b83831215613d1657613d16868486613b9d565b505050505050565b60006117808383613e1d565b60008181526001830160205260408120548015613e13576000613d4e600183614c14565b8554909150600090613d6290600190614c14565b9050818114613dc7576000866000018281548110613d8257613d82614ea2565b9060005260206000200154905080876000018481548110613da557613da5614ea2565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613dd857613dd8614e73565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061112b565b600091505061112b565b6000818152600183016020526040812054613e645750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561112b565b50600061112b565b50805460008255906000526020600020908101906135ad9190613fa0565b828054613e9690614cfa565b90600052602060002090601f016020900481019282613eb85760008555613f1c565b82601f10613eef578280017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00823516178555613f1c565b82800160010185558215613f1c579182015b82811115613f1c578235825591602001919060010190613f01565b50613f28929150613fa0565b5090565b828054613f3890614cfa565b90600052602060002090601f016020900481019282613f5a5760008555613f1c565b82601f10613f7357805160ff1916838001178555613f1c565b82800160010185558215613f1c579182015b82811115613f1c578251825591602001919060010190613f85565b5b80821115613f285760008155600101613fa1565b8051613fc081614f00565b919050565b60008083601f840112613fd757600080fd5b50813567ffffffffffffffff811115613fef57600080fd5b6020830191508360208260051b85010111156114f457600080fd5b80518015158114613fc057600080fd5b60008083601f84011261402c57600080fd5b50813567ffffffffffffffff81111561404457600080fd5b6020830191508360208285010111156114f457600080fd5b600082601f83011261406d57600080fd5b815161408061407b826149e1565b614992565b81815284602083860101111561409557600080fd5b6140a6826020830160208701614c2b565b949350505050565b803561ffff81168114613fc057600080fd5b8051613fc081614f22565b805167ffffffffffffffff81168114613fc057600080fd5b803560ff81168114613fc057600080fd5b8051613fc081614f34565b60006020828403121561411157600080fd5b813561178081614f00565b6000806020838503121561412f57600080fd5b823567ffffffffffffffff81111561414657600080fd5b61415285828601613fc5565b90969095509350505050565b60008060006040848603121561417357600080fd5b833567ffffffffffffffff81111561418a57600080fd5b61419686828701613fc5565b90945092505060208401356141aa81614f22565b809150509250925092565b6000602082840312156141c757600080fd5b6117808261400a565b6000602082840312156141e257600080fd5b5035919050565b600080602083850312156141fc57600080fd5b823567ffffffffffffffff81111561421357600080fd5b6141528582860161401a565b60006020828403121561423157600080fd5b815161178081614f00565b600080600080600060a0868803121561425457600080fd5b85516003811061426357600080fd5b602087015190955061427481614f22565b604087015190945061428581614f22565b606087015190935061429681614f00565b80925050608086015190509295509295909350565b6000602082840312156142bd57600080fd5b815167ffffffffffffffff808211156142d557600080fd5b9083019061014082860312156142ea57600080fd5b6142f2614968565b6142fb83613fb5565b8152614309602084016140c0565b602082015260408301518281111561432057600080fd5b61432c8782860161405c565b60408301525061433e606084016140f4565b606082015261434f60808401613fb5565b608082015261436060a084016140cb565b60a082015261437160c084016140c0565b60c082015261438260e084016140f4565b60e082015261010061439581850161400a565b9082015261012083810151838111156143ad57600080fd5b6143b98882870161405c565b918301919091525095945050505050565b6000602082840312156143dc57600080fd5b5051919050565b6000806000604084860312156143f857600080fd5b83359250602084013567ffffffffffffffff81111561441657600080fd5b6144228682870161401a565b9497909650939450505050565b6000806040838503121561444257600080fd5b82359150602083013567ffffffffffffffff81111561446057600080fd5b8301601f8101851361447157600080fd5b803561447f61407b826149e1565b81815286602083850101111561449457600080fd5b816020840160208301376000602083830101528093505050509250929050565b600080604083850312156144c757600080fd5b823591506144d7602084016140ae565b90509250929050565b6000806000606084860312156144f557600080fd5b83359250614505602085016140ae565b9150604084013590509250925092565b6000806040838503121561452857600080fd5b50508035926020909101359150565b60008060006060848603121561454c57600080fd5b8335925060208401359150614563604085016140ae565b90509250925092565b60008060006060848603121561458157600080fd5b505081359360208301359350604090920135919050565b600080604083850312156145ab57600080fd5b8235915060208301356145bd81614f22565b809150509250929050565b600080604083850312156145db57600080fd5b8235915060208301356145bd81614f34565b6000602082840312156145ff57600080fd5b611780826140e3565b600080600080600060a0868803121561462057600080fd5b614629866140e3565b9450602086013561463981614f22565b9350604086013561464981614f34565b94979396509394606081013594506080013592915050565b60006020828403121561467357600080fd5b813561178081614f34565b60006020828403121561469057600080fd5b815161178081614f34565b600081518084526020808501945080840160005b838110156146cb578151875295820195908201906001016146af565b509495945050505050565b600081518084526146ee816020860160208601614c2b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815281602082015260007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83111561475957600080fd5b8260051b80856040850137600092016040019182525092915050565b602081526000611780602083018461469b565b60408152600061479b604083018561469b565b8281036020840152612a9e818561469b565b821515815260406020820152600061177d60408301846146d6565b60208152600061178060208301846146d6565b60208152600082516101008060208501526147fa6101208501836146d6565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261483684836146d6565b935060408701519150614861606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a08701519150808685030160c08701526148b284836146d6565b935060c08701519150808685030160e0870152506148d083826146d6565b92505060e08501516148f1828601826bffffffffffffffffffffffff169052565b5090949350505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b82815260406020820152600061177d60408301846146d6565b604051610140810167ffffffffffffffff8111828210171561498c5761498c614ed1565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156149d9576149d9614ed1565b604052919050565b600067ffffffffffffffff8211156149fb576149fb614ed1565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b6000808212827f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff03841381151615614a6157614a61614e15565b827f8000000000000000000000000000000000000000000000000000000000000000038412811615614a9557614a95614e15565b50500190565b60008219821115614aae57614aae614e15565b500190565b600082614ac257614ac2614e44565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f800000000000000000000000000000000000000000000000000000000000000083141615614b1657614b16614e15565b500590565b600082614b2a57614b2a614e44565b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b6757614b67614e15565b500290565b60006bffffffffffffffffffffffff80831681851681830481118215151615614b9757614b97614e15565b02949350505050565b6000808312837f800000000000000000000000000000000000000000000000000000000000000001831281151615614bda57614bda614e15565b837f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff018313811615614c0e57614c0e614e15565b50500390565b600082821015614c2657614c26614e15565b500390565b60005b83811015614c46578181015183820152602001614c2e565b83811115612a265750506000910152565b60007f8000000000000000000000000000000000000000000000000000000000000000821415614c8957614c89614e15565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600061ffff821680614cc357614cc3614e15565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0192915050565b600081614c8957614c89614e15565b600181811c90821680614d0e57607f821691505b60208210811415614d48577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415614d8057614d80614e15565b5060010190565b600061ffff80831681811415614d9f57614d9f614e15565b6001019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415614d8057614d80614e15565b600063ffffffff80831681811415614d9f57614d9f614e15565b600060ff821660ff811415614e0c57614e0c614e15565b60010192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff811681146135ad57600080fd5b63ffffffff811681146135ad57600080fd5b6bffffffffffffffffffffffff811681146135ad57600080fdfea164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registrarAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x60c06040526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460a0523480156200003a57600080fd5b50604051620044c2380380620044c28339810160408190526200005d91620002ec565b81813380600081620000b65760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000e957620000e98162000228565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa15801562000146573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200016c91906200032f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620001d2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001f8919062000360565b601280546001600160a01b0319166001600160a01b03929092169190911790555015156080525062000387915050565b336001600160a01b03821603620002825760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000ad565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620002e957600080fd5b50565b600080604083850312156200030057600080fd5b82516200030d81620002d3565b602084015190925080151581146200032457600080fd5b809150509250929050565b600080604083850312156200034357600080fd5b82516200035081620002d3565b6020939093015192949293505050565b6000602082840312156200037357600080fd5b81516200038081620002d3565b9392505050565b60805160a051614107620003bb6000396000818161049901526118630152600081816107870152612c9201526141076000f3fe6080604052600436106103905760003560e01c8063776898c8116101dc578063a72aa27e11610102578063d6051a72116100a0578063e45530831161006f578063e455308314610d06578063f2fde38b14610d1c578063fba7ffa314610d3c578063fcdc1f6314610d6957600080fd5b8063d6051a7214610c79578063daee1aeb14610c99578063dbef701e14610cb9578063e0114adb14610cd957600080fd5b8063becde0e1116100dc578063becde0e114610b80578063c357f1f314610ba0578063c804802214610bfa578063d355852814610c1a57600080fd5b8063a72aa27e14610b13578063a79c404314610b33578063af953a4a14610b6057600080fd5b8063948108f71161017a5780639d385eaa116101495780639d385eaa14610a7f578063a654824814610a9f578063a6b5947514610ad3578063a6c60d8914610af357600080fd5b8063948108f7146109c55780639ac542eb146109e55780639b42935414610a215780639b51fb0d14610a4e57600080fd5b80637e7a46dc116101b65780637e7a46dc1461092d5780638da5cb5b1461094d5780638fcb3fba14610978578063924ca578146109a557600080fd5b8063776898c8146108cb57806379ba5097146108eb5780637b1039991461090057600080fd5b806346e7a63e116102c1578063636092e81161025f5780636e04ff0d1161022e5780636e04ff0d146108135780637145f11b1461084157806373644cce14610871578063767213031461089e57600080fd5b8063636092e814610733578063642f6cef1461077557806369cdbadb146107b957806369e9b773146107e657600080fd5b8063597109921161029b57806359710992146106bc5780635d4ee7f3146106d15780635f17e616146106e657806360457ff51461070657600080fd5b806346e7a63e1461064257806351c98be31461066f57806357970e931461068f57600080fd5b806328c4b57b1161032e578063328ffd1111610308578063328ffd11146105b55780633ebe8d6c146105e25780634585e33b1461060257806345d2ec171461062257600080fd5b806328c4b57b146105235780632a9032d3146105435780632b20e3971461056357600080fd5b80630d4a4fb11161036a5780630d4a4fb11461045a57806312c5502714610487578063206c32e8146104ce57806320e3dbd41461050357600080fd5b806306c1cc00146103d457806306e3b632146103f6578063077ac6211461042c57600080fd5b366103cf57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b3480156103e057600080fd5b506103f46103ef36600461335c565b610d96565b005b34801561040257600080fd5b506104166104113660046133f8565b611152565b604051610423919061341a565b60405180910390f35b34801561043857600080fd5b5061044c610447366004613475565b611251565b604051908152602001610423565b34801561046657600080fd5b5061047a6104753660046134aa565b61128f565b6040516104239190613531565b34801561049357600080fd5b506104bb7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610423565b3480156104da57600080fd5b506104ee6104e9366004613544565b6113af565b60408051928352602083019190915201610423565b34801561050f57600080fd5b506103f461051e366004613592565b611432565b34801561052f57600080fd5b5061044c61053e3660046135af565b6115fc565b34801561054f57600080fd5b506103f461055e366004613620565b611667565b34801561056f57600080fd5b506011546105909073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610423565b3480156105c157600080fd5b5061044c6105d03660046134aa565b60036020526000908152604090205481565b3480156105ee57600080fd5b5061044c6105fd3660046134aa565b611701565b34801561060e57600080fd5b506103f461061d3660046136a4565b61176a565b34801561062e57600080fd5b5061041661063d366004613544565b611979565b34801561064e57600080fd5b5061044c61065d3660046134aa565b600a6020526000908152604090205481565b34801561067b57600080fd5b506103f461068a3660046136da565b6119e8565b34801561069b57600080fd5b506012546105909073ffffffffffffffffffffffffffffffffffffffff1681565b3480156106c857600080fd5b506103f4611a8c565b3480156106dd57600080fd5b506103f4611c77565b3480156106f257600080fd5b506103f46107013660046133f8565b611db2565b34801561071257600080fd5b5061044c6107213660046134aa565b60076020526000908152604090205481565b34801561073f57600080fd5b50601554610758906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610423565b34801561078157600080fd5b506107a97f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610423565b3480156107c557600080fd5b5061044c6107d43660046134aa565b60086020526000908152604090205481565b3480156107f257600080fd5b506103f46108013660046133f8565b60009182526008602052604090912055565b34801561081f57600080fd5b5061083361082e3660046136a4565b611e7f565b604051610423929190613731565b34801561084d57600080fd5b506107a961085c3660046134aa565b600b6020526000908152604090205460ff1681565b34801561087d57600080fd5b5061044c61088c3660046134aa565b6000908152600c602052604090205490565b3480156108aa57600080fd5b5061044c6108b93660046134aa565b60046020526000908152604090205481565b3480156108d757600080fd5b506107a96108e63660046134aa565b611fac565b3480156108f757600080fd5b506103f4611ffe565b34801561090c57600080fd5b506013546105909073ffffffffffffffffffffffffffffffffffffffff1681565b34801561093957600080fd5b506103f461094836600461374c565b612100565b34801561095957600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610590565b34801561098457600080fd5b5061044c6109933660046134aa565b60056020526000908152604090205481565b3480156109b157600080fd5b506103f46109c03660046133f8565b612191565b3480156109d157600080fd5b506103f46109e0366004613798565b6123d6565b3480156109f157600080fd5b50601554610a0f906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610423565b348015610a2d57600080fd5b506103f4610a3c3660046133f8565b60009182526009602052604090912055565b348015610a5a57600080fd5b506104bb610a693660046134aa565b600e6020526000908152604090205461ffff1681565b348015610a8b57600080fd5b50610416610a9a3660046134aa565b61251f565b348015610aab57600080fd5b5061044c7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0881565b348015610adf57600080fd5b506103f4610aee3660046135af565b612581565b348015610aff57600080fd5b506103f4610b0e3660046134aa565b601455565b348015610b1f57600080fd5b506103f4610b2e3660046137c8565b6125ea565b348015610b3f57600080fd5b506103f4610b4e3660046133f8565b60009182526007602052604090912055565b348015610b6c57600080fd5b506103f4610b7b3660046134aa565b612695565b348015610b8c57600080fd5b506103f4610b9b366004613620565b61271b565b348015610bac57600080fd5b506103f4610bbb3660046137ed565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610c0657600080fd5b506103f4610c153660046134aa565b6127b5565b348015610c2657600080fd5b506103f4610c3536600461380a565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610c8557600080fd5b506104ee610c943660046133f8565b61284d565b348015610ca557600080fd5b506103f4610cb4366004613620565b6128b6565b348015610cc557600080fd5b5061044c610cd43660046133f8565b612981565b348015610ce557600080fd5b5061044c610cf43660046134aa565b60096020526000908152604090205481565b348015610d1257600080fd5b5061044c60145481565b348015610d2857600080fd5b506103f4610d37366004613592565b6129b2565b348015610d4857600080fd5b5061044c610d573660046134aa565b60066020526000908152604090205481565b348015610d7557600080fd5b5061044c610d843660046134aa565b60026020526000908152604090205481565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610e7c908c1688613856565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610efa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1e919061389a565b5060008860ff1667ffffffffffffffff811115610f3d57610f3d6131fe565b604051908082528060200260200182016040528015610f66578160200160208202803683370190505b50905060005b8960ff168160ff16101561110f576000610f85846129c6565b90508860ff166001036110bd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015610fea573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526110309190810190613902565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906110899085908590600401613937565b600060405180830381600087803b1580156110a357600080fd5b505af11580156110b7573d6000803e3d6000fd5b50505050505b80838360ff16815181106110d3576110d3613950565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111078161397f565b915050610f6c565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161113f919061341a565b60405180910390a1505050505050505050565b60606000611160600f612a94565b905080841061119b576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036111b0576111ad848261399e565b92505b60008367ffffffffffffffff8111156111cb576111cb6131fe565b6040519080825280602002602001820160405280156111f4578160200160208202803683370190505b50905060005b848110156112465761121761120f82886139b1565b600f90612a9e565b82828151811061122957611229613950565b60209081029190910101528061123e816139c4565b9150506111fa565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061127957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0860001b81526020018460405160200161130091815260200190565b604051602081830303815290604052611318906139fc565b81526020016000801b81526020016000801b8152509050806040516020016113989190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561141357602002820191906000526020600020905b8154815260200190600101908083116113ff575b50505050509050611425818251612aaa565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa1580156114c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114ec9190613a4c565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa15801561158f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115b39190613a7a565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261165d9383018282801561165157602002820191906000526020600020905b81548152602001906001019080831161163d575b50505050508484612b2f565b90505b9392505050565b8060005b818160ff1610156116fb573063c8048022858560ff851681811061169157611691613950565b905060200201356040518263ffffffff1660e01b81526004016116b691815260200190565b600060405180830381600087803b1580156116d057600080fd5b505af11580156116e4573d6000803e3d6000fd5b5050505080806116f39061397f565b91505061166b565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff1611611762576000858152600d6020908152604080832061ffff8516845290915290205461174e90836139b1565b91508061175a81613a97565b915050611717565b509392505050565b60005a9050600061177d83850185613ab8565b50600081815260056020908152604080832054600490925282205492935091906117a5612c8e565b9050826000036117c5576000848152600560205260409020819055611920565b6000848152600360205260408120546117de848461399e565b6117e8919061399e565b6000868152600e6020908152604080832054600d835281842061ffff90911680855290835281842080548351818602810186019094528084529596509094919290919083018282801561185a57602002820191906000526020600020905b815481526020019060010190808311611846575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff168151036118d5578161189781613a97565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b60008481526006602052604081205461193a9060016139b1565b60008681526006602090815260408083208490556004909152902083905590506119648583612191565b61196f858784612581565b5050505050505050565b6000828152600d6020908152604080832061ffff851684528252918290208054835181840281018401909452808452606093928301828280156119db57602002820191906000526020600020905b8154815260200190600101908083116119c7575b5050505050905092915050565b8160005b81811015611a855730635f17e616868684818110611a0c57611a0c613950565b90506020020135856040518363ffffffff1660e01b8152600401611a4092919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611a5a57600080fd5b505af1158015611a6e573d6000803e3d6000fd5b505050508080611a7d906139c4565b9150506119ec565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611b03573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611b499190810190613aff565b80519091506000611b58612c8e565b905060005b828110156116fb576000848281518110611b7957611b79613950565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611bf9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c1d9190613ba5565b90508060ff16600103611c6257604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611c6f906139c4565b915050611b5d565b611c7f612d30565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611cee573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d129190613bc2565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611d8a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dae919061389a565b5050565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611dea916131ab565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611e46576000848152600d6020908152604080832061ffff851684529091528120611e34916131ab565b80611e3e81613a97565b915050611dff565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a90506000611e96858701876134aa565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115611ecf57611ecf6131fe565b6040519080825280601f01601f191660200182016040528015611ef9576020820181803683370190505b50604051602001611f0b929190613937565b60405160208183030381529060405290506000611f26612c8e565b90506000611f3386611fac565b90505b835a611f42908961399e565b611f4e906127106139b1565b1015611f9c5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905581611f9481613bdb565b925050611f36565b9a91995090975050505050505050565b6000818152600560205260408120548103611fc957506001919050565b600082815260036020908152604080832054600490925290912054611fec612c8e565b611ff6919061399e565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612084576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b59061215a90869086908690600401613c10565b600060405180830381600087803b15801561217457600080fd5b505af1158015612188573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546121ad908361399e565b1115611dae576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612223573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526122699190810190613c92565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156122de573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123029190613db1565b6015549091506123269082906c01000000000000000000000000900460ff16613856565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156116fb576015546123699085906bffffffffffffffffffffffff166123d6565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af115801561245e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612482919061389a565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561250357600080fd5b505af1158015612517573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561257557602002820191906000526020600020905b815481526020019060010190808311612561575b50505050509050919050565b6000838152600760205260409020545b805a61259d908561399e565b6125a9906127106139b1565b10156116fb5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612591565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561266257600080fd5b505af1158015612676573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b15801561270757600080fd5b505af1158015611a85573d6000803e3d6000fd5b8060005b818163ffffffff1610156116fb573063af953a4a858563ffffffff851681811061274b5761274b613950565b905060200201356040518263ffffffff1660e01b815260040161277091815260200190565b600060405180830381600087803b15801561278a57600080fd5b505af115801561279e573d6000803e3d6000fd5b5050505080806127ad90613dce565b91505061271f565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561282157600080fd5b505af1158015612835573d6000803e3d6000fd5b50505050611dae81600f612db390919063ffffffff16565b6000828152600c602090815260408083208054825181850281018501909352808352849384939291908301828280156128a557602002820191906000526020600020905b815481526020019060010190808311612891575b505050505090506114258185612aaa565b8060005b818110156116fb5760008484838181106128d6576128d6613950565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc828360405160200161290f91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161293b929190613937565b600060405180830381600087803b15801561295557600080fd5b505af1158015612969573d6000803e3d6000fd5b50505050508080612979906139c4565b9150506128ba565b600c602052816000526040600020818154811061299d57600080fd5b90600052602060002001600091509150505481565b6129ba612d30565b6129c381612dbf565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612a21908690600401613de7565b6020604051808303816000875af1158015612a40573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a649190613bc2565b9050612a71600f82612eb4565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061124b825490565b60006116608383612ec0565b815160009081908190841580612ac05750808510155b15612ac9578094505b60008092505b85831015612b2557866001612ae4858561399e565b612aee919061399e565b81518110612afe57612afe613950565b602002602001015181612b1191906139b1565b905082612b1d816139c4565b935050612acf565b9694955050505050565b82516000908190831580612b435750808410155b15612b4c578093505b60008467ffffffffffffffff811115612b6757612b676131fe565b604051908082528060200260200182016040528015612b90578160200160208202803683370190505b509050600092505b84831015612bfe57866001612bad858561399e565b612bb7919061399e565b81518110612bc757612bc7613950565b6020026020010151818481518110612be157612be1613950565b602090810291909101015282612bf6816139c4565b935050612b98565b612c1781600060018451612c12919061399e565b612eea565b85606403612c50578060018251612c2e919061399e565b81518110612c3e57612c3e613950565b60200260200101519350505050611660565b806064825188612c609190613f39565b612c6a9190613fa5565b81518110612c7a57612c7a613950565b602002602001015193505050509392505050565b60007f000000000000000000000000000000000000000000000000000000000000000015612d2b57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612d02573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d269190613bc2565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314612db1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161207b565b565b60006116608383613062565b3373ffffffffffffffffffffffffffffffffffffffff821603612e3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161207b565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000611660838361315c565b6000826000018281548110612ed757612ed7613950565b9060005260206000200154905092915050565b8181808203612efa575050505050565b6000856002612f098787613fb9565b612f139190613fd9565b612f1d9087614041565b81518110612f2d57612f2d613950565b602002602001015190505b81831361303c575b80868481518110612f5357612f53613950565b60200260200101511015612f735782612f6b81614069565b935050612f40565b858281518110612f8557612f85613950565b6020026020010151811015612fa65781612f9e8161409a565b925050612f73565b81831361303757858281518110612fbf57612fbf613950565b6020026020010151868481518110612fd957612fd9613950565b6020026020010151878581518110612ff357612ff3613950565b6020026020010188858151811061300c5761300c613950565b6020908102919091010191909152528261302581614069565b93505081806130339061409a565b9250505b612f38565b8185121561304f5761304f868684612eea565b8383121561251757612517868486612eea565b6000818152600183016020526040812054801561314b57600061308660018361399e565b855490915060009061309a9060019061399e565b90508181146130ff5760008660000182815481106130ba576130ba613950565b90600052602060002001549050808760000184815481106130dd576130dd613950565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613110576131106140cb565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061124b565b600091505061124b565b5092915050565b60008181526001830160205260408120546131a35750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561124b565b50600061124b565b50805460008255906000526020600020908101906129c391905b808211156131d957600081556001016131c5565b5090565b60ff811681146129c357600080fd5b63ffffffff811681146129c357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715613251576132516131fe565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561329e5761329e6131fe565b604052919050565b600067ffffffffffffffff8211156132c0576132c06131fe565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f8301126132fd57600080fd5b813561331061330b826132a6565b613257565b81815284602083860101111561332557600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129c357600080fd5b600080600080600080600060e0888a03121561337757600080fd5b8735613382816131dd565b96506020880135613392816131ec565b955060408801356133a2816131dd565b9450606088013567ffffffffffffffff8111156133be57600080fd5b6133ca8a828b016132ec565b94505060808801356133db81613342565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561340b57600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561345257835183529284019291840191600101613436565b50909695505050505050565b803561ffff8116811461347057600080fd5b919050565b60008060006060848603121561348a57600080fd5b8335925061349a6020850161345e565b9150604084013590509250925092565b6000602082840312156134bc57600080fd5b5035919050565b60005b838110156134de5781810151838201526020016134c6565b50506000910152565b600081518084526134ff8160208601602086016134c3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061166060208301846134e7565b6000806040838503121561355757600080fd5b823591506135676020840161345e565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff811681146129c357600080fd5b6000602082840312156135a457600080fd5b813561166081613570565b6000806000606084860312156135c457600080fd5b505081359360208301359350604090920135919050565b60008083601f8401126135ed57600080fd5b50813567ffffffffffffffff81111561360557600080fd5b6020830191508360208260051b850101111561142b57600080fd5b6000806020838503121561363357600080fd5b823567ffffffffffffffff81111561364a57600080fd5b613656858286016135db565b90969095509350505050565b60008083601f84011261367457600080fd5b50813567ffffffffffffffff81111561368c57600080fd5b60208301915083602082850101111561142b57600080fd5b600080602083850312156136b757600080fd5b823567ffffffffffffffff8111156136ce57600080fd5b61365685828601613662565b6000806000604084860312156136ef57600080fd5b833567ffffffffffffffff81111561370657600080fd5b613712868287016135db565b9094509250506020840135613726816131ec565b809150509250925092565b821515815260406020820152600061165d60408301846134e7565b60008060006040848603121561376157600080fd5b83359250602084013567ffffffffffffffff81111561377f57600080fd5b61378b86828701613662565b9497909650939450505050565b600080604083850312156137ab57600080fd5b8235915060208301356137bd81613342565b809150509250929050565b600080604083850312156137db57600080fd5b8235915060208301356137bd816131ec565b6000602082840312156137ff57600080fd5b813561166081613342565b60006020828403121561381c57600080fd5b8135611660816131dd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff8083168185168183048111821515161561388157613881613827565b02949350505050565b8051801515811461347057600080fd5b6000602082840312156138ac57600080fd5b6116608261388a565b600082601f8301126138c657600080fd5b81516138d461330b826132a6565b8181528460208386010111156138e957600080fd5b6138fa8260208301602087016134c3565b949350505050565b60006020828403121561391457600080fd5b815167ffffffffffffffff81111561392b57600080fd5b6138fa848285016138b5565b82815260406020820152600061165d60408301846134e7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361399557613995613827565b60010192915050565b8181038181111561124b5761124b613827565b8082018082111561124b5761124b613827565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f5576139f5613827565b5060010190565b80516020808301519190811015613a3b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161347081613570565b60008060408385031215613a5f57600080fd5b8251613a6a81613570565b6020939093015192949293505050565b600060208284031215613a8c57600080fd5b815161166081613570565b600061ffff808316818103613aae57613aae613827565b6001019392505050565b60008060408385031215613acb57600080fd5b82359150602083013567ffffffffffffffff811115613ae957600080fd5b613af5858286016132ec565b9150509250929050565b60006020808385031215613b1257600080fd5b825167ffffffffffffffff80821115613b2a57600080fd5b818501915085601f830112613b3e57600080fd5b815181811115613b5057613b506131fe565b8060051b9150613b61848301613257565b8181529183018401918481019088841115613b7b57600080fd5b938501935b83851015613b9957845182529385019390850190613b80565b98975050505050505050565b600060208284031215613bb757600080fd5b8151611660816131dd565b600060208284031215613bd457600080fd5b5051919050565b600081613bea57613bea613827565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b8051613470816131ec565b805161347081613342565b805167ffffffffffffffff8116811461347057600080fd5b600060208284031215613ca457600080fd5b815167ffffffffffffffff80821115613cbc57600080fd5b908301906101408286031215613cd157600080fd5b613cd961322d565b613ce283613a41565b8152613cf060208401613c64565b6020820152604083015182811115613d0757600080fd5b613d13878286016138b5565b604083015250613d2560608401613c6f565b6060820152613d3660808401613a41565b6080820152613d4760a08401613c7a565b60a0820152613d5860c08401613c64565b60c0820152613d6960e08401613c6f565b60e0820152610100613d7c81850161388a565b908201526101208381015183811115613d9457600080fd5b613da0888287016138b5565b918301919091525095945050505050565b600060208284031215613dc357600080fd5b815161166081613342565b600063ffffffff808316818103613aae57613aae613827565b6020815260008251610140806020850152613e066101608501836134e7565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe080868503016040870152613e4284836134e7565b935060408701519150613e6d606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e0870152613ece84836134e7565b935060e08701519150610100818786030181880152613eed85846134e7565b945080880151925050610120818786030181880152613f0c85846134e7565b94508088015192505050613f2f828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613f7157613f71613827565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082613fb457613fb4613f76565b500490565b818103600083128015838313168383128216171561315557613155613827565b600082613fe857613fe8613f76565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561403c5761403c613827565b500590565b808201828112600083128015821682158216171561406157614061613827565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f5576139f5613827565b60007f80000000000000000000000000000000000000000000000000000000000000008203613bea57613bea613827565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000810000a", } var VerifiableLoadUpkeepABI = VerifiableLoadUpkeepMetaData.ABI @@ -193,28 +193,6 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) BUCKETSIZE() (ui return _VerifiableLoadUpkeep.Contract.BUCKETSIZE(&_VerifiableLoadUpkeep.CallOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) TIMESTAMPINTERVAL(opts *bind.CallOpts) (uint16, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "TIMESTAMP_INTERVAL") - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) TIMESTAMPINTERVAL() (uint16, error) { - return _VerifiableLoadUpkeep.Contract.TIMESTAMPINTERVAL(&_VerifiableLoadUpkeep.CallOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) TIMESTAMPINTERVAL() (uint16, error) { - return _VerifiableLoadUpkeep.Contract.TIMESTAMPINTERVAL(&_VerifiableLoadUpkeep.CallOpts) -} - func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "addLinkAmount") @@ -281,28 +259,6 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) Buckets(arg0 *bi return _VerifiableLoadUpkeep.Contract.Buckets(&_VerifiableLoadUpkeep.CallOpts, arg0) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) CheckDatas(opts *bind.CallOpts, arg0 *big.Int) ([]byte, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "checkDatas", arg0) - - if err != nil { - return *new([]byte), err - } - - out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) CheckDatas(arg0 *big.Int) ([]byte, error) { - return _VerifiableLoadUpkeep.Contract.CheckDatas(&_VerifiableLoadUpkeep.CallOpts, arg0) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) CheckDatas(arg0 *big.Int) ([]byte, error) { - return _VerifiableLoadUpkeep.Contract.CheckDatas(&_VerifiableLoadUpkeep.CallOpts, arg0) -} - func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) CheckGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { var out []interface{} err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "checkGasToBurns", arg0) @@ -413,6 +369,28 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) Eligible(upkeepI return _VerifiableLoadUpkeep.Contract.Eligible(&_VerifiableLoadUpkeep.CallOpts, upkeepId) } +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) EmittedSig(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "emittedSig") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) EmittedSig() ([32]byte, error) { + return _VerifiableLoadUpkeep.Contract.EmittedSig(&_VerifiableLoadUpkeep.CallOpts) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) EmittedSig() ([32]byte, error) { + return _VerifiableLoadUpkeep.Contract.EmittedSig(&_VerifiableLoadUpkeep.CallOpts) +} + func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) FirstPerformBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { var out []interface{} err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "firstPerformBlocks", arg0) @@ -567,138 +545,26 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetDelaysLength( return _VerifiableLoadUpkeep.Contract.GetDelaysLength(&_VerifiableLoadUpkeep.CallOpts, upkeepId) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetDelaysLengthAtBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getDelaysLengthAtBucket", upkeepId, bucket) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetDelaysLengthAtBucket(upkeepId *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetDelaysLengthAtBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, bucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetDelaysLengthAtBucket(upkeepId *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetDelaysLengthAtBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, bucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetDelaysLengthAtTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getDelaysLengthAtTimestampBucket", upkeepId, timestampBucket) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetDelaysLengthAtTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetDelaysLengthAtTimestampBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetDelaysLengthAtTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetDelaysLengthAtTimestampBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetPxBucketedDelaysForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getPxBucketedDelaysForAllUpkeeps", p) - - if err != nil { - return *new([]*big.Int), *new([]*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) - out1 := *abi.ConvertType(out[1], new([]*big.Int)).(*[]*big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetPxBucketedDelaysForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxBucketedDelaysForAllUpkeeps(&_VerifiableLoadUpkeep.CallOpts, p) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetPxBucketedDelaysForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxBucketedDelaysForAllUpkeeps(&_VerifiableLoadUpkeep.CallOpts, p) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetPxDelayForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getPxDelayForAllUpkeeps", p) - - if err != nil { - return *new([]*big.Int), *new([]*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) - out1 := *abi.ConvertType(out[1], new([]*big.Int)).(*[]*big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetPxDelayForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxDelayForAllUpkeeps(&_VerifiableLoadUpkeep.CallOpts, p) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetPxDelayForAllUpkeeps(p *big.Int) ([]*big.Int, []*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxDelayForAllUpkeeps(&_VerifiableLoadUpkeep.CallOpts, p) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetPxDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getPxDelayInBucket", upkeepId, p, bucket) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetPxDelayInBucket(upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxDelayInBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, p, bucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetPxDelayInBucket(upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxDelayInBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, p, bucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetPxDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetLogTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) { var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getPxDelayInTimestampBucket", upkeepId, p, timestampBucket) + err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getLogTriggerConfig", upkeepId) if err != nil { - return *new(*big.Int), err + return *new([]byte), err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) return out0, err } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetPxDelayInTimestampBucket(upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxDelayInTimestampBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, p, timestampBucket) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetLogTriggerConfig(upkeepId *big.Int) ([]byte, error) { + return _VerifiableLoadUpkeep.Contract.GetLogTriggerConfig(&_VerifiableLoadUpkeep.CallOpts, upkeepId) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetPxDelayInTimestampBucket(upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetPxDelayInTimestampBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, p, timestampBucket) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetLogTriggerConfig(upkeepId *big.Int) ([]byte, error) { + return _VerifiableLoadUpkeep.Contract.GetLogTriggerConfig(&_VerifiableLoadUpkeep.CallOpts, upkeepId) } func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetPxDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) { @@ -723,29 +589,6 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetPxDelayLastNP return _VerifiableLoadUpkeep.Contract.GetPxDelayLastNPerforms(&_VerifiableLoadUpkeep.CallOpts, upkeepId, p, n) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetSumBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getSumBucketedDelayLastNPerforms", upkeepId, n) - - if err != nil { - return *new(*big.Int), *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetSumBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetSumBucketedDelayLastNPerforms(&_VerifiableLoadUpkeep.CallOpts, upkeepId, n) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetSumBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetSumBucketedDelayLastNPerforms(&_VerifiableLoadUpkeep.CallOpts, upkeepId, n) -} - func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetSumDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) { var out []interface{} err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getSumDelayInBucket", upkeepId, bucket) @@ -769,29 +612,6 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetSumDelayInBuc return _VerifiableLoadUpkeep.Contract.GetSumDelayInBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, bucket) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetSumDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getSumDelayInTimestampBucket", upkeepId, timestampBucket) - - if err != nil { - return *new(*big.Int), *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetSumDelayInTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetSumDelayInTimestampBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetSumDelayInTimestampBucket(upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetSumDelayInTimestampBucket(&_VerifiableLoadUpkeep.CallOpts, upkeepId, timestampBucket) -} - func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetSumDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { var out []interface{} err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getSumDelayLastNPerforms", upkeepId, n) @@ -815,73 +635,6 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetSumDelayLastN return _VerifiableLoadUpkeep.Contract.GetSumDelayLastNPerforms(&_VerifiableLoadUpkeep.CallOpts, upkeepId, n) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetSumTimestampBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getSumTimestampBucketedDelayLastNPerforms", upkeepId, n) - - if err != nil { - return *new(*big.Int), *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - - return out0, out1, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetSumTimestampBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetSumTimestampBucketedDelayLastNPerforms(&_VerifiableLoadUpkeep.CallOpts, upkeepId, n) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetSumTimestampBucketedDelayLastNPerforms(upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetSumTimestampBucketedDelayLastNPerforms(&_VerifiableLoadUpkeep.CallOpts, upkeepId, n) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetTimestampBucketedDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getTimestampBucketedDelaysLength", upkeepId) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetTimestampBucketedDelaysLength(upkeepId *big.Int) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetTimestampBucketedDelaysLength(&_VerifiableLoadUpkeep.CallOpts, upkeepId) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetTimestampBucketedDelaysLength(upkeepId *big.Int) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetTimestampBucketedDelaysLength(&_VerifiableLoadUpkeep.CallOpts, upkeepId) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) GetTimestampDelays(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "getTimestampDelays", upkeepId, timestampBucket) - - if err != nil { - return *new([]*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) GetTimestampDelays(upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetTimestampDelays(&_VerifiableLoadUpkeep.CallOpts, upkeepId, timestampBucket) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) GetTimestampDelays(upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.GetTimestampDelays(&_VerifiableLoadUpkeep.CallOpts, upkeepId, timestampBucket) -} - func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) Intervals(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) { var out []interface{} err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "intervals", arg0) @@ -1102,162 +855,108 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) Registry() (comm return _VerifiableLoadUpkeep.Contract.Registry(&_VerifiableLoadUpkeep.CallOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) TimestampBuckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "timestampBuckets", arg0) + err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "upkeepTopUpCheckInterval") if err != nil { - return *new(uint16), err + return *new(*big.Int), err } - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) return out0, err } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) TimestampBuckets(arg0 *big.Int) (uint16, error) { - return _VerifiableLoadUpkeep.Contract.TimestampBuckets(&_VerifiableLoadUpkeep.CallOpts, arg0) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) UpkeepTopUpCheckInterval() (*big.Int, error) { + return _VerifiableLoadUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadUpkeep.CallOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) TimestampBuckets(arg0 *big.Int) (uint16, error) { - return _VerifiableLoadUpkeep.Contract.TimestampBuckets(&_VerifiableLoadUpkeep.CallOpts, arg0) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) UpkeepTopUpCheckInterval() (*big.Int, error) { + return _VerifiableLoadUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadUpkeep.CallOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) TimestampDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) { var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "timestampDelays", arg0, arg1, arg2) + err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "useArbitrumBlockNum") if err != nil { - return *new(*big.Int), err + return *new(bool), err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) return out0, err } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) TimestampDelays(arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.TimestampDelays(&_VerifiableLoadUpkeep.CallOpts, arg0, arg1, arg2) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) UseArbitrumBlockNum() (bool, error) { + return _VerifiableLoadUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadUpkeep.CallOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) TimestampDelays(arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.TimestampDelays(&_VerifiableLoadUpkeep.CallOpts, arg0, arg1, arg2) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) UseArbitrumBlockNum() (bool, error) { + return _VerifiableLoadUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadUpkeep.CallOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) Timestamps(opts *bind.CallOpts, arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "timestamps", arg0, arg1) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "acceptOwnership") +} - if err != nil { - return *new(*big.Int), err - } +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.AcceptOwnership(&_VerifiableLoadUpkeep.TransactOpts) +} - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.AcceptOwnership(&_VerifiableLoadUpkeep.TransactOpts) +} - return out0, err +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "addFunds", upkeepId, amount) +} +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.AddFunds(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, amount) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) Timestamps(arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.Timestamps(&_VerifiableLoadUpkeep.CallOpts, arg0, arg1) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.AddFunds(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, amount) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) Timestamps(arg0 *big.Int, arg1 *big.Int) (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.Timestamps(&_VerifiableLoadUpkeep.CallOpts, arg0, arg1) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "batchCancelUpkeeps", upkeepIds) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "upkeepTopUpCheckInterval") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) UpkeepTopUpCheckInterval() (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadUpkeep.CallOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) UpkeepTopUpCheckInterval() (*big.Int, error) { - return _VerifiableLoadUpkeep.Contract.UpkeepTopUpCheckInterval(&_VerifiableLoadUpkeep.CallOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCaller) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) { - var out []interface{} - err := _VerifiableLoadUpkeep.contract.Call(opts, &out, "useArbitrumBlockNum") - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) UseArbitrumBlockNum() (bool, error) { - return _VerifiableLoadUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadUpkeep.CallOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepCallerSession) UseArbitrumBlockNum() (bool, error) { - return _VerifiableLoadUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadUpkeep.CallOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.contract.Transact(opts, "acceptOwnership") -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) AcceptOwnership() (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.AcceptOwnership(&_VerifiableLoadUpkeep.TransactOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.AcceptOwnership(&_VerifiableLoadUpkeep.TransactOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.contract.Transact(opts, "addFunds", upkeepId, amount) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.AddFunds(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, amount) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, upkeepIds) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) AddFunds(upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.AddFunds(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, amount) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, upkeepIds) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.contract.Transact(opts, "batchCancelUpkeeps", upkeepIds) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "batchRegisterUpkeeps", number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, upkeepIds) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BatchCancelUpkeeps(upkeepIds []*big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.BatchCancelUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, upkeepIds) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, number, gasLimit, triggerType, triggerConfig, amount, checkGasToBurn, performGasToBurn) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.contract.Transact(opts, "batchRegisterUpkeeps", number, gasLimit, amount, checkGasToBurn, performGasToBurn) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BatchSendLogs(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "batchSendLogs") } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, number, gasLimit, amount, checkGasToBurn, performGasToBurn) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) BatchSendLogs() (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BatchSendLogs(&_VerifiableLoadUpkeep.TransactOpts) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BatchRegisterUpkeeps(number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.BatchRegisterUpkeeps(&_VerifiableLoadUpkeep.TransactOpts, number, gasLimit, amount, checkGasToBurn, performGasToBurn) +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BatchSendLogs() (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BatchSendLogs(&_VerifiableLoadUpkeep.TransactOpts) } func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BatchSetIntervals(opts *bind.TransactOpts, upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) { @@ -1296,6 +995,18 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BatchWithdra return _VerifiableLoadUpkeep.Contract.BatchWithdrawLinks(&_VerifiableLoadUpkeep.TransactOpts, upkeepIds) } +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) BurnPerformGas(opts *bind.TransactOpts, upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "burnPerformGas", upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) BurnPerformGas(upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BurnPerformGas(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, startGas, blockNum) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) BurnPerformGas(upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.BurnPerformGas(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, startGas, blockNum) +} + func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) CancelUpkeep(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { return _VerifiableLoadUpkeep.contract.Transact(opts, "cancelUpkeep", upkeepId) } @@ -1440,6 +1151,18 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) SetUpkeepTop return _VerifiableLoadUpkeep.Contract.SetUpkeepTopUpCheckInterval(&_VerifiableLoadUpkeep.TransactOpts, newInterval) } +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "topUpFund", upkeepId, blockNum) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) TopUpFund(upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.TopUpFund(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, blockNum) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) TopUpFund(upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.TopUpFund(&_VerifiableLoadUpkeep.TransactOpts, upkeepId, blockNum) +} + func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _VerifiableLoadUpkeep.contract.Transact(opts, "transferOwnership", to) } @@ -1478,538 +1201,30 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) WithdrawLink func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) WithdrawLinks0(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { return _VerifiableLoadUpkeep.contract.Transact(opts, "withdrawLinks0", upkeepId) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadUpkeep.TransactOpts, upkeepId) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadUpkeep.TransactOpts, upkeepId) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error) { - return _VerifiableLoadUpkeep.contract.RawTransact(opts, nil) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) Receive() (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.Receive(&_VerifiableLoadUpkeep.TransactOpts) -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) Receive() (*types.Transaction, error) { - return _VerifiableLoadUpkeep.Contract.Receive(&_VerifiableLoadUpkeep.TransactOpts) -} - -type VerifiableLoadUpkeepFundsAddedIterator struct { - Event *VerifiableLoadUpkeepFundsAdded - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadUpkeepFundsAddedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepFundsAdded) - 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(VerifiableLoadUpkeepFundsAdded) - 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 *VerifiableLoadUpkeepFundsAddedIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadUpkeepFundsAddedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadUpkeepFundsAdded struct { - UpkeepId *big.Int - Amount *big.Int - Raw types.Log -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterFundsAdded(opts *bind.FilterOpts) (*VerifiableLoadUpkeepFundsAddedIterator, error) { - - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "FundsAdded") - if err != nil { - return nil, err - } - return &VerifiableLoadUpkeepFundsAddedIterator{contract: _VerifiableLoadUpkeep.contract, event: "FundsAdded", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepFundsAdded) (event.Subscription, error) { - - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "FundsAdded") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadUpkeepFundsAdded) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "FundsAdded", 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 (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseFundsAdded(log types.Log) (*VerifiableLoadUpkeepFundsAdded, error) { - event := new(VerifiableLoadUpkeepFundsAdded) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "FundsAdded", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadUpkeepInsufficientFundsIterator struct { - Event *VerifiableLoadUpkeepInsufficientFunds - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadUpkeepInsufficientFundsIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepInsufficientFunds) - 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(VerifiableLoadUpkeepInsufficientFunds) - 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 *VerifiableLoadUpkeepInsufficientFundsIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadUpkeepInsufficientFundsIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadUpkeepInsufficientFunds struct { - Balance *big.Int - BlockNum *big.Int - Raw types.Log -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterInsufficientFunds(opts *bind.FilterOpts) (*VerifiableLoadUpkeepInsufficientFundsIterator, error) { - - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "InsufficientFunds") - if err != nil { - return nil, err - } - return &VerifiableLoadUpkeepInsufficientFundsIterator{contract: _VerifiableLoadUpkeep.contract, event: "InsufficientFunds", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchInsufficientFunds(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepInsufficientFunds) (event.Subscription, error) { - - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "InsufficientFunds") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadUpkeepInsufficientFunds) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "InsufficientFunds", 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 (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseInsufficientFunds(log types.Log) (*VerifiableLoadUpkeepInsufficientFunds, error) { - event := new(VerifiableLoadUpkeepInsufficientFunds) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "InsufficientFunds", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadUpkeepOwnershipTransferRequestedIterator struct { - Event *VerifiableLoadUpkeepOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadUpkeepOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepOwnershipTransferRequested) - 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(VerifiableLoadUpkeepOwnershipTransferRequested) - 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 *VerifiableLoadUpkeepOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadUpkeepOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadUpkeepOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadUpkeepOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &VerifiableLoadUpkeepOwnershipTransferRequestedIterator{contract: _VerifiableLoadUpkeep.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(VerifiableLoadUpkeepOwnershipTransferRequested) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifiableLoadUpkeepOwnershipTransferRequested, error) { - event := new(VerifiableLoadUpkeepOwnershipTransferRequested) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type VerifiableLoadUpkeepOwnershipTransferredIterator struct { - Event *VerifiableLoadUpkeepOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *VerifiableLoadUpkeepOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepOwnershipTransferred) - 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(VerifiableLoadUpkeepOwnershipTransferred) - 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 *VerifiableLoadUpkeepOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *VerifiableLoadUpkeepOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type VerifiableLoadUpkeepOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadUpkeepOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &VerifiableLoadUpkeepOwnershipTransferredIterator{contract: _VerifiableLoadUpkeep.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: +} - event := new(VerifiableLoadUpkeepOwnershipTransferred) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return err - } - event.Raw = log +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadUpkeep.TransactOpts, upkeepId) +} - 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 (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) WithdrawLinks0(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.WithdrawLinks0(&_VerifiableLoadUpkeep.TransactOpts, upkeepId) } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseOwnershipTransferred(log types.Log) (*VerifiableLoadUpkeepOwnershipTransferred, error) { - event := new(VerifiableLoadUpkeepOwnershipTransferred) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.RawTransact(opts, nil) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) Receive() (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.Receive(&_VerifiableLoadUpkeep.TransactOpts) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) Receive() (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.Receive(&_VerifiableLoadUpkeep.TransactOpts) } -type VerifiableLoadUpkeepPerformingUpkeepIterator struct { - Event *VerifiableLoadUpkeepPerformingUpkeep +type VerifiableLoadUpkeepLogEmittedIterator struct { + Event *VerifiableLoadUpkeepLogEmitted contract *bind.BoundContract event string @@ -2020,7 +1235,7 @@ type VerifiableLoadUpkeepPerformingUpkeepIterator struct { fail error } -func (it *VerifiableLoadUpkeepPerformingUpkeepIterator) Next() bool { +func (it *VerifiableLoadUpkeepLogEmittedIterator) Next() bool { if it.fail != nil { return false @@ -2029,7 +1244,7 @@ func (it *VerifiableLoadUpkeepPerformingUpkeepIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepPerformingUpkeep) + it.Event = new(VerifiableLoadUpkeepLogEmitted) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2044,7 +1259,7 @@ func (it *VerifiableLoadUpkeepPerformingUpkeepIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepPerformingUpkeep) + it.Event = new(VerifiableLoadUpkeepLogEmitted) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2059,35 +1274,52 @@ func (it *VerifiableLoadUpkeepPerformingUpkeepIterator) Next() bool { } } -func (it *VerifiableLoadUpkeepPerformingUpkeepIterator) Error() error { +func (it *VerifiableLoadUpkeepLogEmittedIterator) Error() error { return it.fail } -func (it *VerifiableLoadUpkeepPerformingUpkeepIterator) Close() error { +func (it *VerifiableLoadUpkeepLogEmittedIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadUpkeepPerformingUpkeep struct { - FirstPerformBlock *big.Int - LastBlock *big.Int - PreviousBlock *big.Int - Counter *big.Int - Raw types.Log +type VerifiableLoadUpkeepLogEmitted struct { + UpkeepId *big.Int + BlockNum *big.Int + Addr common.Address + Raw types.Log } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterPerformingUpkeep(opts *bind.FilterOpts) (*VerifiableLoadUpkeepPerformingUpkeepIterator, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterLogEmitted(opts *bind.FilterOpts, upkeepId []*big.Int, blockNum []*big.Int) (*VerifiableLoadUpkeepLogEmittedIterator, error) { + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + var blockNumRule []interface{} + for _, blockNumItem := range blockNum { + blockNumRule = append(blockNumRule, blockNumItem) + } - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "PerformingUpkeep") + logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "LogEmitted", upkeepIdRule, blockNumRule) if err != nil { return nil, err } - return &VerifiableLoadUpkeepPerformingUpkeepIterator{contract: _VerifiableLoadUpkeep.contract, event: "PerformingUpkeep", logs: logs, sub: sub}, nil + return &VerifiableLoadUpkeepLogEmittedIterator{contract: _VerifiableLoadUpkeep.contract, event: "LogEmitted", logs: logs, sub: sub}, nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchPerformingUpkeep(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepPerformingUpkeep) (event.Subscription, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchLogEmitted(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepLogEmitted, upkeepId []*big.Int, blockNum []*big.Int) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "PerformingUpkeep") + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + var blockNumRule []interface{} + for _, blockNumItem := range blockNum { + blockNumRule = append(blockNumRule, blockNumItem) + } + + logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "LogEmitted", upkeepIdRule, blockNumRule) if err != nil { return nil, err } @@ -2097,8 +1329,8 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchPerformingUpkeep select { case log := <-logs: - event := new(VerifiableLoadUpkeepPerformingUpkeep) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "PerformingUpkeep", log); err != nil { + event := new(VerifiableLoadUpkeepLogEmitted) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "LogEmitted", log); err != nil { return err } event.Raw = log @@ -2119,17 +1351,17 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchPerformingUpkeep }), nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParsePerformingUpkeep(log types.Log) (*VerifiableLoadUpkeepPerformingUpkeep, error) { - event := new(VerifiableLoadUpkeepPerformingUpkeep) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "PerformingUpkeep", log); err != nil { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseLogEmitted(log types.Log) (*VerifiableLoadUpkeepLogEmitted, error) { + event := new(VerifiableLoadUpkeepLogEmitted) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "LogEmitted", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadUpkeepReceivedIterator struct { - Event *VerifiableLoadUpkeepReceived +type VerifiableLoadUpkeepOwnershipTransferRequestedIterator struct { + Event *VerifiableLoadUpkeepOwnershipTransferRequested contract *bind.BoundContract event string @@ -2140,7 +1372,7 @@ type VerifiableLoadUpkeepReceivedIterator struct { fail error } -func (it *VerifiableLoadUpkeepReceivedIterator) Next() bool { +func (it *VerifiableLoadUpkeepOwnershipTransferRequestedIterator) Next() bool { if it.fail != nil { return false @@ -2149,7 +1381,7 @@ func (it *VerifiableLoadUpkeepReceivedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepReceived) + it.Event = new(VerifiableLoadUpkeepOwnershipTransferRequested) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2164,7 +1396,7 @@ func (it *VerifiableLoadUpkeepReceivedIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepReceived) + it.Event = new(VerifiableLoadUpkeepOwnershipTransferRequested) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2179,33 +1411,51 @@ func (it *VerifiableLoadUpkeepReceivedIterator) Next() bool { } } -func (it *VerifiableLoadUpkeepReceivedIterator) Error() error { +func (it *VerifiableLoadUpkeepOwnershipTransferRequestedIterator) Error() error { return it.fail } -func (it *VerifiableLoadUpkeepReceivedIterator) Close() error { +func (it *VerifiableLoadUpkeepOwnershipTransferRequestedIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadUpkeepReceived struct { - Sender common.Address - Value *big.Int - Raw types.Log +type VerifiableLoadUpkeepOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadUpkeepReceivedIterator, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadUpkeepOwnershipTransferRequestedIterator, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "Received") + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) if err != nil { return nil, err } - return &VerifiableLoadUpkeepReceivedIterator{contract: _VerifiableLoadUpkeep.contract, event: "Received", logs: logs, sub: sub}, nil + return &VerifiableLoadUpkeepOwnershipTransferRequestedIterator{contract: _VerifiableLoadUpkeep.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepReceived) (event.Subscription, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "Received") + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) if err != nil { return nil, err } @@ -2215,8 +1465,8 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchReceived(opts *b select { case log := <-logs: - event := new(VerifiableLoadUpkeepReceived) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "Received", log); err != nil { + event := new(VerifiableLoadUpkeepOwnershipTransferRequested) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { return err } event.Raw = log @@ -2237,17 +1487,17 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchReceived(opts *b }), nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseReceived(log types.Log) (*VerifiableLoadUpkeepReceived, error) { - event := new(VerifiableLoadUpkeepReceived) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "Received", log); err != nil { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifiableLoadUpkeepOwnershipTransferRequested, error) { + event := new(VerifiableLoadUpkeepOwnershipTransferRequested) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadUpkeepRegistrarSetIterator struct { - Event *VerifiableLoadUpkeepRegistrarSet +type VerifiableLoadUpkeepOwnershipTransferredIterator struct { + Event *VerifiableLoadUpkeepOwnershipTransferred contract *bind.BoundContract event string @@ -2258,7 +1508,7 @@ type VerifiableLoadUpkeepRegistrarSetIterator struct { fail error } -func (it *VerifiableLoadUpkeepRegistrarSetIterator) Next() bool { +func (it *VerifiableLoadUpkeepOwnershipTransferredIterator) Next() bool { if it.fail != nil { return false @@ -2267,7 +1517,7 @@ func (it *VerifiableLoadUpkeepRegistrarSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepRegistrarSet) + it.Event = new(VerifiableLoadUpkeepOwnershipTransferred) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2282,7 +1532,7 @@ func (it *VerifiableLoadUpkeepRegistrarSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepRegistrarSet) + it.Event = new(VerifiableLoadUpkeepOwnershipTransferred) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2297,32 +1547,51 @@ func (it *VerifiableLoadUpkeepRegistrarSetIterator) Next() bool { } } -func (it *VerifiableLoadUpkeepRegistrarSetIterator) Error() error { +func (it *VerifiableLoadUpkeepOwnershipTransferredIterator) Error() error { return it.fail } -func (it *VerifiableLoadUpkeepRegistrarSetIterator) Close() error { +func (it *VerifiableLoadUpkeepOwnershipTransferredIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadUpkeepRegistrarSet struct { - NewRegistrar common.Address - Raw types.Log +type VerifiableLoadUpkeepOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterRegistrarSet(opts *bind.FilterOpts) (*VerifiableLoadUpkeepRegistrarSetIterator, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadUpkeepOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "RegistrarSet") + logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) if err != nil { return nil, err } - return &VerifiableLoadUpkeepRegistrarSetIterator{contract: _VerifiableLoadUpkeep.contract, event: "RegistrarSet", logs: logs, sub: sub}, nil + return &VerifiableLoadUpkeepOwnershipTransferredIterator{contract: _VerifiableLoadUpkeep.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchRegistrarSet(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepRegistrarSet) (event.Subscription, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "RegistrarSet") + logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) if err != nil { return nil, err } @@ -2332,8 +1601,8 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchRegistrarSet(opt select { case log := <-logs: - event := new(VerifiableLoadUpkeepRegistrarSet) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "RegistrarSet", log); err != nil { + event := new(VerifiableLoadUpkeepOwnershipTransferred) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return err } event.Raw = log @@ -2354,17 +1623,17 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchRegistrarSet(opt }), nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseRegistrarSet(log types.Log) (*VerifiableLoadUpkeepRegistrarSet, error) { - event := new(VerifiableLoadUpkeepRegistrarSet) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "RegistrarSet", log); err != nil { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseOwnershipTransferred(log types.Log) (*VerifiableLoadUpkeepOwnershipTransferred, error) { + event := new(VerifiableLoadUpkeepOwnershipTransferred) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadUpkeepUpkeepTopUpIterator struct { - Event *VerifiableLoadUpkeepUpkeepTopUp +type VerifiableLoadUpkeepReceivedIterator struct { + Event *VerifiableLoadUpkeepReceived contract *bind.BoundContract event string @@ -2375,7 +1644,7 @@ type VerifiableLoadUpkeepUpkeepTopUpIterator struct { fail error } -func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Next() bool { +func (it *VerifiableLoadUpkeepReceivedIterator) Next() bool { if it.fail != nil { return false @@ -2384,7 +1653,7 @@ func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepUpkeepTopUp) + it.Event = new(VerifiableLoadUpkeepReceived) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2399,7 +1668,7 @@ func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepUpkeepTopUp) + it.Event = new(VerifiableLoadUpkeepReceived) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2414,34 +1683,33 @@ func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Next() bool { } } -func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Error() error { +func (it *VerifiableLoadUpkeepReceivedIterator) Error() error { return it.fail } -func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Close() error { +func (it *VerifiableLoadUpkeepReceivedIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadUpkeepUpkeepTopUp struct { - UpkeepId *big.Int - Amount *big.Int - BlockNum *big.Int - Raw types.Log +type VerifiableLoadUpkeepReceived struct { + Sender common.Address + Value *big.Int + Raw types.Log } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadUpkeepUpkeepTopUpIterator, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadUpkeepReceivedIterator, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "UpkeepTopUp") + logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "Received") if err != nil { return nil, err } - return &VerifiableLoadUpkeepUpkeepTopUpIterator{contract: _VerifiableLoadUpkeep.contract, event: "UpkeepTopUp", logs: logs, sub: sub}, nil + return &VerifiableLoadUpkeepReceivedIterator{contract: _VerifiableLoadUpkeep.contract, event: "Received", logs: logs, sub: sub}, nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepUpkeepTopUp) (event.Subscription, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepReceived) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "UpkeepTopUp") + logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "Received") if err != nil { return nil, err } @@ -2451,8 +1719,8 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepTopUp(opts select { case log := <-logs: - event := new(VerifiableLoadUpkeepUpkeepTopUp) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { + event := new(VerifiableLoadUpkeepReceived) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "Received", log); err != nil { return err } event.Raw = log @@ -2473,17 +1741,17 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepTopUp(opts }), nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadUpkeepUpkeepTopUp, error) { - event := new(VerifiableLoadUpkeepUpkeepTopUp) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseReceived(log types.Log) (*VerifiableLoadUpkeepReceived, error) { + event := new(VerifiableLoadUpkeepReceived) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "Received", log); err != nil { return nil, err } event.Raw = log return event, nil } -type VerifiableLoadUpkeepUpkeepsCancelledIterator struct { - Event *VerifiableLoadUpkeepUpkeepsCancelled +type VerifiableLoadUpkeepUpkeepTopUpIterator struct { + Event *VerifiableLoadUpkeepUpkeepTopUp contract *bind.BoundContract event string @@ -2494,7 +1762,7 @@ type VerifiableLoadUpkeepUpkeepsCancelledIterator struct { fail error } -func (it *VerifiableLoadUpkeepUpkeepsCancelledIterator) Next() bool { +func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Next() bool { if it.fail != nil { return false @@ -2503,7 +1771,7 @@ func (it *VerifiableLoadUpkeepUpkeepsCancelledIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepUpkeepsCancelled) + it.Event = new(VerifiableLoadUpkeepUpkeepTopUp) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2518,7 +1786,7 @@ func (it *VerifiableLoadUpkeepUpkeepsCancelledIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(VerifiableLoadUpkeepUpkeepsCancelled) + it.Event = new(VerifiableLoadUpkeepUpkeepTopUp) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2533,32 +1801,34 @@ func (it *VerifiableLoadUpkeepUpkeepsCancelledIterator) Next() bool { } } -func (it *VerifiableLoadUpkeepUpkeepsCancelledIterator) Error() error { +func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Error() error { return it.fail } -func (it *VerifiableLoadUpkeepUpkeepsCancelledIterator) Close() error { +func (it *VerifiableLoadUpkeepUpkeepTopUpIterator) Close() error { it.sub.Unsubscribe() return nil } -type VerifiableLoadUpkeepUpkeepsCancelled struct { - UpkeepIds []*big.Int - Raw types.Log +type VerifiableLoadUpkeepUpkeepTopUp struct { + UpkeepId *big.Int + Amount *big.Int + BlockNum *big.Int + Raw types.Log } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterUpkeepsCancelled(opts *bind.FilterOpts) (*VerifiableLoadUpkeepUpkeepsCancelledIterator, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadUpkeepUpkeepTopUpIterator, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "UpkeepsCancelled") + logs, sub, err := _VerifiableLoadUpkeep.contract.FilterLogs(opts, "UpkeepTopUp") if err != nil { return nil, err } - return &VerifiableLoadUpkeepUpkeepsCancelledIterator{contract: _VerifiableLoadUpkeep.contract, event: "UpkeepsCancelled", logs: logs, sub: sub}, nil + return &VerifiableLoadUpkeepUpkeepTopUpIterator{contract: _VerifiableLoadUpkeep.contract, event: "UpkeepTopUp", logs: logs, sub: sub}, nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepsCancelled(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepUpkeepsCancelled) (event.Subscription, error) { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepUpkeepTopUp) (event.Subscription, error) { - logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "UpkeepsCancelled") + logs, sub, err := _VerifiableLoadUpkeep.contract.WatchLogs(opts, "UpkeepTopUp") if err != nil { return nil, err } @@ -2568,8 +1838,8 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepsCancelled select { case log := <-logs: - event := new(VerifiableLoadUpkeepUpkeepsCancelled) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "UpkeepsCancelled", log); err != nil { + event := new(VerifiableLoadUpkeepUpkeepTopUp) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { return err } event.Raw = log @@ -2590,9 +1860,9 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) WatchUpkeepsCancelled }), nil } -func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseUpkeepsCancelled(log types.Log) (*VerifiableLoadUpkeepUpkeepsCancelled, error) { - event := new(VerifiableLoadUpkeepUpkeepsCancelled) - if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "UpkeepsCancelled", log); err != nil { +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadUpkeepUpkeepTopUp, error) { + event := new(VerifiableLoadUpkeepUpkeepTopUp) + if err := _VerifiableLoadUpkeep.contract.UnpackLog(event, "UpkeepTopUp", log); err != nil { return nil, err } event.Raw = log @@ -2718,24 +1988,16 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepFilterer) ParseUpkeepsRegistere func (_VerifiableLoadUpkeep *VerifiableLoadUpkeep) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { - case _VerifiableLoadUpkeep.abi.Events["FundsAdded"].ID: - return _VerifiableLoadUpkeep.ParseFundsAdded(log) - case _VerifiableLoadUpkeep.abi.Events["InsufficientFunds"].ID: - return _VerifiableLoadUpkeep.ParseInsufficientFunds(log) + case _VerifiableLoadUpkeep.abi.Events["LogEmitted"].ID: + return _VerifiableLoadUpkeep.ParseLogEmitted(log) case _VerifiableLoadUpkeep.abi.Events["OwnershipTransferRequested"].ID: return _VerifiableLoadUpkeep.ParseOwnershipTransferRequested(log) case _VerifiableLoadUpkeep.abi.Events["OwnershipTransferred"].ID: return _VerifiableLoadUpkeep.ParseOwnershipTransferred(log) - case _VerifiableLoadUpkeep.abi.Events["PerformingUpkeep"].ID: - return _VerifiableLoadUpkeep.ParsePerformingUpkeep(log) case _VerifiableLoadUpkeep.abi.Events["Received"].ID: return _VerifiableLoadUpkeep.ParseReceived(log) - case _VerifiableLoadUpkeep.abi.Events["RegistrarSet"].ID: - return _VerifiableLoadUpkeep.ParseRegistrarSet(log) case _VerifiableLoadUpkeep.abi.Events["UpkeepTopUp"].ID: return _VerifiableLoadUpkeep.ParseUpkeepTopUp(log) - case _VerifiableLoadUpkeep.abi.Events["UpkeepsCancelled"].ID: - return _VerifiableLoadUpkeep.ParseUpkeepsCancelled(log) case _VerifiableLoadUpkeep.abi.Events["UpkeepsRegistered"].ID: return _VerifiableLoadUpkeep.ParseUpkeepsRegistered(log) @@ -2744,12 +2006,8 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeep) ParseLog(log types.Log) (gene } } -func (VerifiableLoadUpkeepFundsAdded) Topic() common.Hash { - return common.HexToHash("0x8137dc366612bf502338bd8951f835ad8ceba421c4eb3d79c7f9b3ce0ac4762e") -} - -func (VerifiableLoadUpkeepInsufficientFunds) Topic() common.Hash { - return common.HexToHash("0x03eb8b54a949acec2cd08fdb6d6bd4647a1f2c907d75d6900648effa92eb147f") +func (VerifiableLoadUpkeepLogEmitted) Topic() common.Hash { + return common.HexToHash("0x97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf08") } func (VerifiableLoadUpkeepOwnershipTransferRequested) Topic() common.Hash { @@ -2760,26 +2018,14 @@ func (VerifiableLoadUpkeepOwnershipTransferred) Topic() common.Hash { return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") } -func (VerifiableLoadUpkeepPerformingUpkeep) Topic() common.Hash { - return common.HexToHash("0x6b6b3eeaaf107627513e76a81662118e7b1d8c78866f70760262115ddcfeede3") -} - func (VerifiableLoadUpkeepReceived) Topic() common.Hash { return common.HexToHash("0x88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874") } -func (VerifiableLoadUpkeepRegistrarSet) Topic() common.Hash { - return common.HexToHash("0x6263309d5d4d1cfececd45a387cda7f14dccde21cf7a1bee1be6561075e61014") -} - func (VerifiableLoadUpkeepUpkeepTopUp) Topic() common.Hash { return common.HexToHash("0x49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c0") } -func (VerifiableLoadUpkeepUpkeepsCancelled) Topic() common.Hash { - return common.HexToHash("0xbeac20a03a6674e40498fac4356bc86e356c0d761a8d35d436712dc93bc7c74b") -} - func (VerifiableLoadUpkeepUpkeepsRegistered) Topic() common.Hash { return common.HexToHash("0x2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711") } @@ -2791,16 +2037,12 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeep) Address() common.Address { type VerifiableLoadUpkeepInterface interface { BUCKETSIZE(opts *bind.CallOpts) (uint16, error) - TIMESTAMPINTERVAL(opts *bind.CallOpts) (uint16, error) - AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) BucketedDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) Buckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) - CheckDatas(opts *bind.CallOpts, arg0 *big.Int) ([]byte, error) - CheckGasToBurns(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) Counters(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) @@ -2811,6 +2053,8 @@ type VerifiableLoadUpkeepInterface interface { Eligible(opts *bind.CallOpts, upkeepId *big.Int) (bool, error) + EmittedSig(opts *bind.CallOpts) ([32]byte, error) + FirstPerformBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) GasLimits(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) @@ -2825,34 +2069,14 @@ type VerifiableLoadUpkeepInterface interface { GetDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) - GetDelaysLengthAtBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, error) - - GetDelaysLengthAtTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, error) - - GetPxBucketedDelaysForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) - - GetPxDelayForAllUpkeeps(opts *bind.CallOpts, p *big.Int) ([]*big.Int, []*big.Int, error) - - GetPxDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, bucket uint16) (*big.Int, error) - - GetPxDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, timestampBucket uint16) (*big.Int, error) + GetLogTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) GetPxDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, p *big.Int, n *big.Int) (*big.Int, error) - GetSumBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) - GetSumDelayInBucket(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) (*big.Int, *big.Int, error) - GetSumDelayInTimestampBucket(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) (*big.Int, *big.Int, error) - GetSumDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) - GetSumTimestampBucketedDelayLastNPerforms(opts *bind.CallOpts, upkeepId *big.Int, n *big.Int) (*big.Int, *big.Int, error) - - GetTimestampBucketedDelaysLength(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) - - GetTimestampDelays(opts *bind.CallOpts, upkeepId *big.Int, timestampBucket uint16) ([]*big.Int, error) - Intervals(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) LastTopUpBlocks(opts *bind.CallOpts, arg0 *big.Int) (*big.Int, error) @@ -2873,12 +2097,6 @@ type VerifiableLoadUpkeepInterface interface { Registry(opts *bind.CallOpts) (common.Address, error) - TimestampBuckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) - - TimestampDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) - - Timestamps(opts *bind.CallOpts, arg0 *big.Int, arg1 *big.Int) (*big.Int, error) - UpkeepTopUpCheckInterval(opts *bind.CallOpts) (*big.Int, error) UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) @@ -2889,7 +2107,9 @@ type VerifiableLoadUpkeepInterface interface { BatchCancelUpkeeps(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) - BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) + BatchRegisterUpkeeps(opts *bind.TransactOpts, number uint8, gasLimit uint32, triggerType uint8, triggerConfig []byte, amount *big.Int, checkGasToBurn *big.Int, performGasToBurn *big.Int) (*types.Transaction, error) + + BatchSendLogs(opts *bind.TransactOpts) (*types.Transaction, error) BatchSetIntervals(opts *bind.TransactOpts, upkeepIds []*big.Int, interval uint32) (*types.Transaction, error) @@ -2897,6 +2117,8 @@ type VerifiableLoadUpkeepInterface interface { BatchWithdrawLinks(opts *bind.TransactOpts, upkeepIds []*big.Int) (*types.Transaction, error) + BurnPerformGas(opts *bind.TransactOpts, upkeepId *big.Int, startGas *big.Int, blockNum *big.Int) (*types.Transaction, error) + CancelUpkeep(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) CheckUpkeep(opts *bind.TransactOpts, checkData []byte) (*types.Transaction, error) @@ -2921,6 +2143,8 @@ type VerifiableLoadUpkeepInterface interface { SetUpkeepTopUpCheckInterval(opts *bind.TransactOpts, newInterval *big.Int) (*types.Transaction, error) + TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) UpdateUpkeepPipelineData(opts *bind.TransactOpts, upkeepId *big.Int, pipelineData []byte) (*types.Transaction, error) @@ -2931,17 +2155,11 @@ type VerifiableLoadUpkeepInterface interface { Receive(opts *bind.TransactOpts) (*types.Transaction, error) - FilterFundsAdded(opts *bind.FilterOpts) (*VerifiableLoadUpkeepFundsAddedIterator, error) + FilterLogEmitted(opts *bind.FilterOpts, upkeepId []*big.Int, blockNum []*big.Int) (*VerifiableLoadUpkeepLogEmittedIterator, error) - WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepFundsAdded) (event.Subscription, error) + WatchLogEmitted(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepLogEmitted, upkeepId []*big.Int, blockNum []*big.Int) (event.Subscription, error) - ParseFundsAdded(log types.Log) (*VerifiableLoadUpkeepFundsAdded, error) - - FilterInsufficientFunds(opts *bind.FilterOpts) (*VerifiableLoadUpkeepInsufficientFundsIterator, error) - - WatchInsufficientFunds(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepInsufficientFunds) (event.Subscription, error) - - ParseInsufficientFunds(log types.Log) (*VerifiableLoadUpkeepInsufficientFunds, error) + ParseLogEmitted(log types.Log) (*VerifiableLoadUpkeepLogEmitted, error) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifiableLoadUpkeepOwnershipTransferRequestedIterator, error) @@ -2955,36 +2173,18 @@ type VerifiableLoadUpkeepInterface interface { ParseOwnershipTransferred(log types.Log) (*VerifiableLoadUpkeepOwnershipTransferred, error) - FilterPerformingUpkeep(opts *bind.FilterOpts) (*VerifiableLoadUpkeepPerformingUpkeepIterator, error) - - WatchPerformingUpkeep(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepPerformingUpkeep) (event.Subscription, error) - - ParsePerformingUpkeep(log types.Log) (*VerifiableLoadUpkeepPerformingUpkeep, error) - FilterReceived(opts *bind.FilterOpts) (*VerifiableLoadUpkeepReceivedIterator, error) WatchReceived(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepReceived) (event.Subscription, error) ParseReceived(log types.Log) (*VerifiableLoadUpkeepReceived, error) - FilterRegistrarSet(opts *bind.FilterOpts) (*VerifiableLoadUpkeepRegistrarSetIterator, error) - - WatchRegistrarSet(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepRegistrarSet) (event.Subscription, error) - - ParseRegistrarSet(log types.Log) (*VerifiableLoadUpkeepRegistrarSet, error) - FilterUpkeepTopUp(opts *bind.FilterOpts) (*VerifiableLoadUpkeepUpkeepTopUpIterator, error) WatchUpkeepTopUp(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepUpkeepTopUp) (event.Subscription, error) ParseUpkeepTopUp(log types.Log) (*VerifiableLoadUpkeepUpkeepTopUp, error) - FilterUpkeepsCancelled(opts *bind.FilterOpts) (*VerifiableLoadUpkeepUpkeepsCancelledIterator, error) - - WatchUpkeepsCancelled(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepUpkeepsCancelled) (event.Subscription, error) - - ParseUpkeepsCancelled(log types.Log) (*VerifiableLoadUpkeepUpkeepsCancelled, error) - FilterUpkeepsRegistered(opts *bind.FilterOpts) (*VerifiableLoadUpkeepUpkeepsRegisteredIterator, error) WatchUpkeepsRegistered(opts *bind.WatchOpts, sink chan<- *VerifiableLoadUpkeepUpkeepsRegistered) (event.Subscription, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 677f48e66a0..b450f62acda 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -38,7 +38,7 @@ keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../c llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 log_emitter: ../../contracts/solc/v0.8.6/LogEmitter.abi ../../contracts/solc/v0.8.6/LogEmitter.bin 375488d19b6ee1c180d42048be10abea9146e2a58347fd180358850d435cb854 -log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin 3b64fe225de164203b760a0e5088d1b5034fcbe8483ce295439e8e52f0c71859 +log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin b16d9cafc51d85c4cd0b32fe0f53e37243b769585c5473c6f0e2c5db7dafc817 log_upkeep_counter_wrapper: ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin 13d6543329f89d06cbf3901d7f9ecdc42acc1a84d8c61db291fcbfdbe1138eb1 mercury_exposed_verifier: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 mercury_upkeep_wrapper: ../../contracts/solc/v0.8.15/MercuryUpkeep.abi ../../contracts/solc/v0.8.15/MercuryUpkeep.bin c4627433ed9ebe7f8cf6594f577b4a1826ce6f2209271895a885fd4b3017320e @@ -65,8 +65,9 @@ type_and_version_interface_wrapper: ../../contracts/solc/v0.8.6/TypeAndVersionIn upkeep_counter_wrapper: ../../contracts/solc/v0.7/UpkeepCounter.abi ../../contracts/solc/v0.7/UpkeepCounter.bin 901961ebf18906febc1c350f02da85c7ea1c2a68da70cfd94efa27c837a48663 upkeep_perform_counter_restrictive_wrapper: ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.abi ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.bin 8975a058fba528e16d8414dc6f13946d17a145fcbc66cf25a32449b6fe1ce878 upkeep_transcoder: ../../contracts/solc/v0.8.6/UpkeepTranscoder.abi ../../contracts/solc/v0.8.6/UpkeepTranscoder.bin 336c92a981597be26508455f81a908a0784a817b129a59686c5b2c4afcba730a -verifiable_load_mercury_upkeep_wrapper: ../../contracts/solc/v0.8.6/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.6/VerifiableLoadMercuryUpkeep.bin b922ba0dfc984484d0b3655d1b4a67d27a4b7035f75e73130f4f6e29ff0b53ec -verifiable_load_upkeep_wrapper: ../../contracts/solc/v0.8.6/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.6/VerifiableLoadUpkeep.bin dd0b055496b5e4ef14a9925b98abf6759009282dfac21e4f2b083f64a0c41cef +verifiable_load_log_trigger_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin 7e03338febcd40b1b90eca22be9a3715662b33b40ce18a5d4d50ad29eda6f5e2 +verifiable_load_mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin 47babc359db1b1f2d1d9401eef3f3b86349fd7053b43ccf31ed3872c20979878 +verifiable_load_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin 42f190693bb49f1e76e0e396e0560c3e9152b7a01c6a9e62ed35d99b03f97a1e vrf_consumer_v2: ../../contracts/solc/v0.8.6/VRFConsumerV2.abi ../../contracts/solc/v0.8.6/VRFConsumerV2.bin 9ef258bf8e9f8d880fd229ceb145593d91e24fc89366baa0bf19169c5787d15f vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.bin 3155c611e4d6882e9324b6e975033b31356776ea8b031ca63d63da37589d583b vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 7bc31195e14..82b304f26bb 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -44,8 +44,9 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin KeeperRegistry keeper_registry_wrapper2_0 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin KeeperRegistryLogic keeper_registry_logic2_0 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/UpkeepTranscoder.abi ../../contracts/solc/v0.8.6/UpkeepTranscoder.bin UpkeepTranscoder upkeep_transcoder -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.6/VerifiableLoadUpkeep.bin VerifiableLoadUpkeep verifiable_load_upkeep_wrapper -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.6/VerifiableLoadMercuryUpkeep.bin VerifiableLoadMercuryUpkeep verifiable_load_mercury_upkeep_wrapper +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin VerifiableLoadUpkeep verifiable_load_upkeep_wrapper +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin VerifiableLoadMercuryUpkeep verifiable_load_mercury_upkeep_wrapper +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin VerifiableLoadLogTriggerUpkeep verifiable_load_log_trigger_upkeep_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.15/MercuryUpkeep.abi ../../contracts/solc/v0.8.15/MercuryUpkeep.bin MercuryUpkeep mercury_upkeep_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.bin FeedLookupCompatibleInterface feed_lookup_compatible_interface //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.abi ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.bin AutomationConsumerBenchmark automation_consumer_benchmark diff --git a/core/scripts/chaincli/handler/keeper_verifiable_load.go b/core/scripts/chaincli/handler/keeper_verifiable_load.go index d954ad4d180..ad704393877 100644 --- a/core/scripts/chaincli/handler/keeper_verifiable_load.go +++ b/core/scripts/chaincli/handler/keeper_verifiable_load.go @@ -26,41 +26,42 @@ const ( maxUpkeepNum = 100 ) -type UpkeepInfo struct { - mu sync.Mutex - ID *big.Int - Bucket uint16 - TimestampBucket uint16 - DelayBuckets map[uint16][]float64 - DelayTimestampBuckets map[uint16][]float64 - SortedAllDelays []float64 - TotalDelayBlock float64 - TotalPerforms uint64 +type upkeepInfo struct { + mu sync.Mutex + ID *big.Int + Bucket uint16 + DelayBuckets map[uint16][]float64 + SortedAllDelays []float64 + TotalDelayBlock float64 + TotalPerforms uint64 } -func (ui *UpkeepInfo) AddBucket(bucketNum uint16, bucketDelays []float64) { - ui.mu.Lock() - defer ui.mu.Unlock() - ui.DelayBuckets[bucketNum] = bucketDelays +type verifiableLoad interface { + GetActiveUpkeepIDs(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) + Counters(opts *bind.CallOpts, upkeepId *big.Int) (*big.Int, error) + GetBucketedDelays(opts *bind.CallOpts, upkeepId *big.Int, bucket uint16) ([]*big.Int, error) + Buckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) } -func (ui *UpkeepInfo) AddTimestampBucket(bucketNum uint16, bucketDelays []float64) { +func (ui *upkeepInfo) AddBucket(bucketNum uint16, bucketDelays []float64) { ui.mu.Lock() defer ui.mu.Unlock() - ui.DelayTimestampBuckets[bucketNum] = bucketDelays + ui.DelayBuckets[bucketNum] = bucketDelays } -type UpkeepStats struct { +type upkeepStats struct { BlockNumber uint64 - AllInfos []*UpkeepInfo + AllInfos []*upkeepInfo TotalDelayBlock float64 TotalPerforms uint64 SortedAllDelays []float64 } func (k *Keeper) GetVerifiableLoadStats(ctx context.Context) { + var v verifiableLoad + var err error addr := common.HexToAddress(k.cfg.VerifiableLoadContractAddress) - v, err := verifiable_load_upkeep_wrapper.NewVerifiableLoadUpkeep(addr, k.client) + v, err = verifiable_load_upkeep_wrapper.NewVerifiableLoadUpkeep(addr, k.client) if err != nil { log.Fatalf("failed to create a new verifiable load upkeep from address %s: %v", k.cfg.VerifiableLoadContractAddress, err) } @@ -83,9 +84,9 @@ func (k *Keeper) GetVerifiableLoadStats(ctx context.Context) { log.Fatalf("failed to get active upkeep IDs from %s: %v", k.cfg.VerifiableLoadContractAddress, err) } - upkeepStats := &UpkeepStats{BlockNumber: blockNum} + us := &upkeepStats{BlockNumber: blockNum} - resultsChan := make(chan *UpkeepInfo, maxUpkeepNum) + resultsChan := make(chan *upkeepInfo, maxUpkeepNum) idChan := make(chan *big.Int, maxUpkeepNum) var wg sync.WaitGroup @@ -106,25 +107,25 @@ func (k *Keeper) GetVerifiableLoadStats(ctx context.Context) { close(resultsChan) for info := range resultsChan { - upkeepStats.AllInfos = append(upkeepStats.AllInfos, info) - upkeepStats.TotalPerforms += info.TotalPerforms - upkeepStats.TotalDelayBlock += info.TotalDelayBlock - upkeepStats.SortedAllDelays = append(upkeepStats.SortedAllDelays, info.SortedAllDelays...) + us.AllInfos = append(us.AllInfos, info) + us.TotalPerforms += info.TotalPerforms + us.TotalDelayBlock += info.TotalDelayBlock + us.SortedAllDelays = append(us.SortedAllDelays, info.SortedAllDelays...) } - sort.Float64s(upkeepStats.SortedAllDelays) + sort.Float64s(us.SortedAllDelays) log.Println("\n\n================================== ALL UPKEEPS SUMMARY =======================================================") - p50, _ := stats.Percentile(upkeepStats.SortedAllDelays, 50) - p90, _ := stats.Percentile(upkeepStats.SortedAllDelays, 90) - p95, _ := stats.Percentile(upkeepStats.SortedAllDelays, 95) - p99, _ := stats.Percentile(upkeepStats.SortedAllDelays, 99) - maxDelay := upkeepStats.SortedAllDelays[len(upkeepStats.SortedAllDelays)-1] - log.Printf("For total %d upkeeps: total performs: %d, p50: %f, p90: %f, p95: %f, p99: %f, max delay: %f, total delay blocks: %f, average perform delay: %f\n", len(upkeepIds), upkeepStats.TotalPerforms, p50, p90, p95, p99, maxDelay, upkeepStats.TotalDelayBlock, upkeepStats.TotalDelayBlock/float64(upkeepStats.TotalPerforms)) + p50, _ := stats.Percentile(us.SortedAllDelays, 50) + p90, _ := stats.Percentile(us.SortedAllDelays, 90) + p95, _ := stats.Percentile(us.SortedAllDelays, 95) + p99, _ := stats.Percentile(us.SortedAllDelays, 99) + maxDelay := us.SortedAllDelays[len(us.SortedAllDelays)-1] + log.Printf("For total %d upkeeps: total performs: %d, p50: %f, p90: %f, p95: %f, p99: %f, max delay: %f, total delay blocks: %f, average perform delay: %f\n", len(upkeepIds), us.TotalPerforms, p50, p90, p95, p99, maxDelay, us.TotalDelayBlock, us.TotalDelayBlock/float64(us.TotalPerforms)) log.Printf("All STATS ABOVE ARE CALCULATED AT BLOCK %d", blockNum) } -func (k *Keeper) getUpkeepInfo(idChan chan *big.Int, resultsChan chan *UpkeepInfo, v *verifiable_load_upkeep_wrapper.VerifiableLoadUpkeep, opts *bind.CallOpts, wg *sync.WaitGroup) { +func (k *Keeper) getUpkeepInfo(idChan chan *big.Int, resultsChan chan *upkeepInfo, v verifiableLoad, opts *bind.CallOpts, wg *sync.WaitGroup) { defer wg.Done() for id := range idChan { @@ -140,31 +141,18 @@ func (k *Keeper) getUpkeepInfo(idChan chan *big.Int, resultsChan chan *UpkeepInf log.Fatalf("failed to get current bucket count for %s: %v", id.String(), err) } - info := &UpkeepInfo{ - ID: id, - Bucket: b, - TotalPerforms: c.Uint64(), - DelayBuckets: map[uint16][]float64{}, - DelayTimestampBuckets: map[uint16][]float64{}, + info := &upkeepInfo{ + ID: id, + Bucket: b, + TotalPerforms: c.Uint64(), + DelayBuckets: map[uint16][]float64{}, } var delays []float64 var wg1 sync.WaitGroup for i := uint16(0); i <= b; i++ { wg1.Add(1) - go k.getBucketData(v, opts, false, id, i, &wg1, info) - } - wg1.Wait() - - // get all the timestamp buckets of an upkeep. performs which happen every 1 hour after the first perform fall into the same bucket. - t, err := v.TimestampBuckets(opts, id) - if err != nil { - log.Fatalf("failed to get timestamp bucket for %s: %v", id.String(), err) - } - info.TimestampBucket = t - for i := uint16(0); i <= t; i++ { - wg1.Add(1) - go k.getBucketData(v, opts, true, id, i, &wg1, info) + go k.getBucketData(v, opts, id, i, &wg1, info) } wg1.Wait() @@ -183,7 +171,6 @@ func (k *Keeper) getUpkeepInfo(idChan chan *big.Int, resultsChan chan *UpkeepInf p90, _ := stats.Percentile(info.SortedAllDelays, 90) p95, _ := stats.Percentile(info.SortedAllDelays, 95) p99, _ := stats.Percentile(info.SortedAllDelays, 99) - // TODO sometimes SortedAllDelays is empty maxDelay := info.SortedAllDelays[len(info.SortedAllDelays)-1] log.Printf("upkeep ID %s has %d performs in total. p50: %f, p90: %f, p95: %f, p99: %f, max delay: %f, total delay blocks: %d, average perform delay: %f\n", id, info.TotalPerforms, p50, p90, p95, p99, maxDelay, uint64(info.TotalDelayBlock), info.TotalDelayBlock/float64(info.TotalPerforms)) @@ -191,30 +178,18 @@ func (k *Keeper) getUpkeepInfo(idChan chan *big.Int, resultsChan chan *UpkeepInf } } -func (k *Keeper) getBucketData(v *verifiable_load_upkeep_wrapper.VerifiableLoadUpkeep, opts *bind.CallOpts, getTimestampBucket bool, id *big.Int, bucketNum uint16, wg *sync.WaitGroup, info *UpkeepInfo) { +func (k *Keeper) getBucketData(v verifiableLoad, opts *bind.CallOpts, id *big.Int, bucketNum uint16, wg *sync.WaitGroup, info *upkeepInfo) { defer wg.Done() var bucketDelays []*big.Int var err error - if getTimestampBucket { - for i := 0; i < retryNum; i++ { - bucketDelays, err = v.GetTimestampDelays(opts, id, bucketNum) - if err != nil { - log.Printf("failed to get timestamp bucketed delays for upkeep id %s timestamp bucket %d: %v, retrying...", id.String(), bucketNum, err) - time.Sleep(retryDelay) - } else { - break - } - } - } else { - for i := 0; i < retryNum; i++ { - bucketDelays, err = v.GetBucketedDelays(opts, id, bucketNum) - if err != nil { - log.Printf("failed to get bucketed delays for upkeep id %s bucket %d: %v, retrying...", id.String(), bucketNum, err) - time.Sleep(retryDelay) - } else { - break - } + for i := 0; i < retryNum; i++ { + bucketDelays, err = v.GetBucketedDelays(opts, id, bucketNum) + if err != nil { + log.Printf("failed to get bucketed delays for upkeep id %s bucket %d: %v, retrying...", id.String(), bucketNum, err) + time.Sleep(retryDelay) + } else { + break } } @@ -223,10 +198,5 @@ func (k *Keeper) getBucketData(v *verifiable_load_upkeep_wrapper.VerifiableLoadU floatBucketDelays = append(floatBucketDelays, float64(d.Uint64())) } sort.Float64s(floatBucketDelays) - - if getTimestampBucket { - info.AddTimestampBucket(bucketNum, floatBucketDelays) - } else { - info.AddBucket(bucketNum, floatBucketDelays) - } + info.AddBucket(bucketNum, floatBucketDelays) } From 919b64dc092461d4ef70f5b48a41db85558a70de Mon Sep 17 00:00:00 2001 From: Sri Kidambi <1702865+kidambisrinivas@users.noreply.github.com> Date: Thu, 27 Jul 2023 21:56:38 +0100 Subject: [PATCH 021/270] Set LINK and LINK/ETH at the same time in the VRFCoordinatorV2Plus (#9954) * Set LINK and LINK/ETH at the same time in the VRFCoordinatorV2Plus * Format sol files * Minor changes --------- Co-authored-by: Sri Kidambi --- .../src/v0.8/dev/vrf/SubscriptionAPI.sol | 12 ++++++- .../src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 11 ------- .../vrf/VRFCoordinatorV2Plus_Migration.t.sol | 3 +- .../test/v0.8/foundry/vrf/VRFV2Plus.t.sol | 5 ++- .../test/v0.8/foundry/vrf/VRFV2Wrapper.t.sol | 3 +- .../vrf_coordinator_v2plus.go | 32 ++++++------------- ...rapper-dependency-versions-do-not-edit.txt | 2 +- core/scripts/vrfv2plus/testnet/util.go | 7 ++-- .../vrf/v2/integration_v2_plus_test.go | 22 +++++++++---- 9 files changed, 42 insertions(+), 55 deletions(-) diff --git a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol index 69f96b5683f..a26149ea728 100644 --- a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol +++ b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol @@ -3,6 +3,7 @@ pragma solidity ^0.8.0; import "../../interfaces/LinkTokenInterface.sol"; import "../../ConfirmedOwner.sol"; +import "../../interfaces/AggregatorV3Interface.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "../../interfaces/ERC677ReceiverInterface.sol"; import "../interfaces/IVRFSubscriptionV2Plus.sol"; @@ -10,6 +11,8 @@ import "../interfaces/IVRFSubscriptionV2Plus.sol"; abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, ERC677ReceiverInterface, IVRFSubscriptionV2Plus { /// @dev may not be provided upon construction on some chains due to lack of availability LinkTokenInterface public LINK; + /// @dev may not be provided upon construction on some chains due to lack of availability + AggregatorV3Interface public LINK_ETH_FEED; // We need to maintain a list of consuming addresses. // This bound ensures we are able to loop over them as needed. @@ -83,12 +86,19 @@ abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, ERC677Rece constructor() ConfirmedOwner(msg.sender) {} - function setLINK(address link) external onlyOwner { + /** + * @notice set the LINK token contract and link eth feed to be + * used by this coordinator + * @param link - address of link token + * @param linkEthFeed address of the link eth feed + */ + function setLINKAndLINKETHFeed(address link, address linkEthFeed) external onlyOwner { // Disallow re-setting link token because the logic wouldn't really make sense if (address(LINK) != address(0)) { revert LinkAlreadySet(); } LINK = LinkTokenInterface(link); + LINK_ETH_FEED = AggregatorV3Interface(linkEthFeed); } /** diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 216f29c72a2..783f6cccc4c 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -3,7 +3,6 @@ pragma solidity ^0.8.4; import "../../interfaces/LinkTokenInterface.sol"; import "../../interfaces/BlockhashStoreInterface.sol"; -import "../../interfaces/AggregatorV3Interface.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; import "../../vrf/VRF.sol"; import "./VRFConsumerBaseV2Plus.sol"; @@ -13,8 +12,6 @@ import "./libraries/VRFV2PlusClient.sol"; import "../interfaces/IVRFCoordinatorV2PlusMigration.sol"; contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { - /// @dev may not be provided upon construction on some chains due to lack of availability - AggregatorV3Interface public LINK_ETH_FEED; /// @dev should always be available BlockhashStoreInterface public immutable BLOCKHASH_STORE; @@ -113,14 +110,6 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { BLOCKHASH_STORE = BlockhashStoreInterface(blockhashStore); } - /** - * @notice set the link eth feed to be used by this coordinator - * @param linkEthFeed address of the link eth feed - */ - function setLinkEthFeed(address linkEthFeed) external onlyOwner { - LINK_ETH_FEED = AggregatorV3Interface(linkEthFeed); - } - /** * @notice Registers a proving key to an oracle. * @param oracle address of the oracle diff --git a/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol b/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol index e35425dfd48..2ab9b5979d8 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol @@ -45,8 +45,7 @@ contract VRFCoordinatorV2Plus_Migration is BaseTest { subId = v1Coordinator.createSubscription(); linkToken = new MockLinkToken(); linkEthFeed = new MockV3Aggregator(18, 500000000000000000); // .5 ETH (good for testing) - v1Coordinator.setLINK(address(linkToken)); - v1Coordinator.setLinkEthFeed(address(linkEthFeed)); + v1Coordinator.setLINKAndLINKETHFeed(address(linkToken), address(linkEthFeed)); linkTokenAddr = address(linkToken); v2Coordinator = new VRFCoordinatorV2Plus_V2Example(address(linkToken), address(v1Coordinator)); v1CoordinatorAddr = address(v1Coordinator); diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol index 9ca8477fa90..b9bfd7e2887 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol @@ -80,8 +80,7 @@ contract VRFV2Plus is BaseTest { s_testConsumer = VRFV2PlusConsumerExample(consumerCreate2Address); // Configure the coordinator. - s_testCoordinator.setLINK(address(s_linkToken)); - s_testCoordinator.setLinkEthFeed(address(s_linkEthFeed)); + s_testCoordinator.setLINKAndLINKETHFeed(address(s_linkToken), address(s_linkEthFeed)); } function setConfig(VRFCoordinatorV2Plus.FeeConfig memory feeConfig) internal { @@ -360,7 +359,7 @@ contract VRFV2Plus is BaseTest { (uint96 linkBalanceBefore, , , ) = s_testCoordinator.getSubscription(subId); vm.expectEmit(true, true, false, true); uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; - emit RandomWordsFulfilled(requestId, outputSeed, subId, 290972, rc.extraArgs, true); + emit RandomWordsFulfilled(requestId, outputSeed, subId, 290978, rc.extraArgs, true); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Wrapper.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Wrapper.t.sol index 18e2eb3b987..4b506bb8c50 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Wrapper.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Wrapper.t.sol @@ -44,8 +44,7 @@ contract VRFV2PlusWrapperTest is BaseTest { s_consumer = new VRFV2PlusWrapperConsumerExample(address(s_linkToken), address(s_wrapper)); // Configure the coordinator. - s_testCoordinator.setLINK(address(s_linkToken)); - s_testCoordinator.setLinkEthFeed(address(s_linkEthFeed)); + s_testCoordinator.setLINKAndLINKETHFeed(address(s_linkToken), address(s_linkEthFeed)); setConfigCoordinator(basicFeeConfig); setConfigWrapper(); diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index ee345bc327a..4a44fc4162e 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -66,8 +66,8 @@ type VRFV2PlusClientRandomWordsRequest struct { } var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"}],\"name\":\"setLINK\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLinkEthFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620060b5380380620060b5833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615ed5620001e0600039600081816105e30152613b3a0152615ed56000f3fe6080604052600436106102fc5760003560e01c8063981837d51161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610972578063ee9d2d3814610999578063f2fde38b146109c657600080fd5b8063dc311dd31461090f578063e72f6e301461093f578063e8509bff1461095f57600080fd5b8063d98e620e116100bb578063d98e620e14610899578063da2f2610146108b9578063dac83d29146108ef57600080fd5b8063bec4c08c14610839578063caf70c4a14610859578063cb6317971461087957600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107d9578063b08c8795146107f9578063b2a7cac51461081957600080fd5b8063a4c0ed3614610779578063a8cb447b14610799578063aa433aff146107b957600080fd5b80639d40a6fd116101745780639d40a6fd1461070a578063a02e061614610744578063a21a23e41461076457600080fd5b8063981837d5146106ca5780639b1c385e146106ea57600080fd5b806340d6bb8211610253578063689c4517116101fc57806379ba5097116101d657806379ba50971461066b57806386fe91c7146106805780638da5cb5b146106ac57600080fd5b8063689c4517146105d15780636b6feccc146106055780636f64f03f1461064b57600080fd5b80635d06b4ab1161022d5780635d06b4ab1461057c57806364d51a2a1461059c57806366316d8d146105b157600080fd5b806340d6bb821461050157806341af6c871461052c57806346d8d4861461055c57600080fd5b80630ae09540116102b5578063294daa491161028f578063294daa491461048d578063330987b3146104a9578063405b84fa146104e157600080fd5b80630ae095401461040d57806315c48b841461042d5780631b6b6d231461045557600080fd5b8063043bd6ae116102e6578063043bd6ae14610350578063088070f51461037457806308821d58146103ed57600080fd5b80620122911461030157806304104edb1461032e575b600080fd5b34801561030d57600080fd5b506103166109e6565b604051610325939291906159b0565b60405180910390f35b34801561033a57600080fd5b5061034e610349366004615344565b610a62565b005b34801561035c57600080fd5b50610366600e5481565b604051908152602001610325565b34801561038057600080fd5b50600f546103bc9061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff938416602086015291831691840191909152166060820152608001610325565b3480156103f957600080fd5b5061034e61040836600461544c565b610c24565b34801561041957600080fd5b5061034e610428366004615709565b610db8565b34801561043957600080fd5b5061044260c881565b60405161ffff9091168152602001610325565b34801561046157600080fd5b50600354610475906001600160a01b031681565b6040516001600160a01b039091168152602001610325565b34801561049957600080fd5b5060405160018152602001610325565b3480156104b557600080fd5b506104c96104c436600461551f565b610ea4565b6040516001600160601b039091168152602001610325565b3480156104ed57600080fd5b5061034e6104fc366004615709565b611363565b34801561050d57600080fd5b506105176101f481565b60405163ffffffff9091168152602001610325565b34801561053857600080fd5b5061054c6105473660046154a1565b611742565b6040519015158152602001610325565b34801561056857600080fd5b5061034e610577366004615361565b611944565b34801561058857600080fd5b5061034e610597366004615344565b611adf565b3480156105a857600080fd5b50610442606481565b3480156105bd57600080fd5b5061034e6105cc366004615361565b611bb6565b3480156105dd57600080fd5b506104757f000000000000000000000000000000000000000000000000000000000000000081565b34801561061157600080fd5b5060105461062e9063ffffffff8082169164010000000090041682565b6040805163ffffffff938416815292909116602083015201610325565b34801561065757600080fd5b5061034e610666366004615396565b611d73565b34801561067757600080fd5b5061034e611e8b565b34801561068c57600080fd5b506007546104c9906801000000000000000090046001600160601b031681565b3480156106b857600080fd5b506000546001600160a01b0316610475565b3480156106d657600080fd5b5061034e6106e5366004615344565b611f3c565b3480156106f657600080fd5b5061036661070536600461561b565b611f66565b34801561071657600080fd5b5060075461072b9067ffffffffffffffff1681565b60405167ffffffffffffffff9091168152602001610325565b34801561075057600080fd5b5061034e61075f366004615344565b6123a7565b34801561077057600080fd5b50610366612414565b34801561078557600080fd5b5061034e6107943660046153c3565b612674565b3480156107a557600080fd5b5061034e6107b4366004615344565b612864565b3480156107c557600080fd5b5061034e6107d43660046154a1565b612980565b3480156107e557600080fd5b50600a54610475906001600160a01b031681565b34801561080557600080fd5b5061034e61081436600461566b565b6129e0565b34801561082557600080fd5b5061034e6108343660046154a1565b612b6a565b34801561084557600080fd5b5061034e610854366004615709565b612cd7565b34801561086557600080fd5b50610366610874366004615468565b612eaa565b34801561088557600080fd5b5061034e610894366004615709565b612eda565b3480156108a557600080fd5b506103666108b43660046154a1565b6131f7565b3480156108c557600080fd5b506104756108d43660046154a1565b600b602052600090815260409020546001600160a01b031681565b3480156108fb57600080fd5b5061034e61090a366004615709565b613218565b34801561091b57600080fd5b5061092f61092a3660046154a1565b613350565b6040516103259493929190615bae565b34801561094b57600080fd5b5061034e61095a366004615344565b613433565b61034e61096d3660046154a1565b6135fb565b34801561097e57600080fd5b506007546104c990600160a01b90046001600160601b031681565b3480156109a557600080fd5b506103666109b43660046154a1565b600d6020526000908152604090205481565b3480156109d257600080fd5b5061034e6109e1366004615344565b613753565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a5057602002820191906000526020600020905b815481526020019060010190808311610a3c575b50505050509050925092509250909192565b610a6a613764565b60115460005b81811015610bf757826001600160a01b031660118281548110610a9557610a95615e59565b6000918252602090912001546001600160a01b03161415610be5576011610abd600184615d51565b81548110610acd57610acd615e59565b600091825260209091200154601180546001600160a01b039092169183908110610af957610af9615e59565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b30600185615d51565b81548110610b4057610b40615e59565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b7f57610b7f615e43565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bef81615dc0565b915050610a70565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c2c613764565b604080518082018252600091610c5b919084906002908390839080828437600092019190915250612eaa915050565b6000818152600b60205260409020549091506001600160a01b031680610c9757604051631dfd6e1360e21b815260048101839052602401610c18565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d6f5782600c8281548110610cd257610cd2615e59565b90600052602060002001541415610d5d57600c805460009190610cf790600190615d51565b81548110610d0757610d07615e59565b9060005260206000200154905080600c8381548110610d2857610d28615e59565b600091825260209091200155600c805480610d4557610d45615e43565b60019003818190600052602060002001600090559055505b80610d6781615dc0565b915050610cb4565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610dab91815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610df057604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e2457604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415610e645760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055610e7184611742565b15610e8f57604051631685ecdd60e31b815260040160405180910390fd5b610e9984846137c0565b505060016002555050565b6000600280541415610ee65760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b6002805560005a90506000610efb8585613957565b90506000610f0f6080860160608701615739565b63ffffffff1667ffffffffffffffff811115610f2d57610f2d615e6f565b604051908082528060200260200182016040528015610f56578160200160208202803683370190505b50905060005b610f6c6080870160608801615739565b63ffffffff16811015610fe157826040015181604051602001610f99929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610fc457610fc4615e59565b602090810291909101015280610fd981615dc0565b915050610f5c565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161103291908690602401615a23565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199094169390931790925291506000906110ae906110929060608b01908b01615739565b63ffffffff166110a860a08b0160808c01615344565b84613cac565b905060006110c76110c260a08b018b615bf3565b613cfa565b51600f549091506000906110f29089906a0100000000000000000000900463ffffffff163a85613da9565b905081156111fb576020808b01356000908152600690915260409020546001600160601b03808316600160601b90920416101561114257604051631e9acf1760e31b815260040160405180910390fd5b60208a81013560009081526006909152604090208054829190600c90611179908490600160601b90046001600160601b0316615d68565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b0316835260099091528120805485945090926111d291859116615cfc565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506112e7565b6020808b01356000908152600690915260409020546001600160601b038083169116101561123c57604051631e9acf1760e31b815260040160405180910390fd5b6020808b0135600090815260069091526040812080548392906112699084906001600160601b0316615d68565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b0316835260089091528120805485945090926112c291859116615cfc565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113026040518060200160405280851515815250613df9565b90508a6020013588602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8a604001518585896040516113479493929190615b73565b60405180910390a35060016002559a9950505050505050505050565b61136c81613e7f565b61139457604051635428d44960e01b81526001600160a01b0382166004820152602401610c18565b6000806000806113a386613350565b9350935093509350336001600160a01b0316826001600160a01b03161461140c5760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c18565b61141586611742565b156114625760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c18565b60006040518060c00160405280611477600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016114cb919061593b565b60405160208183030381529060405290506114e588613ee9565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b03881690611537908590600401615928565b6000604051808303818588803b15801561155057600080fd5b505af1158015611564573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b1580156115c057600080fd5b505af11580156115d4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115f89190615484565b6116445760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c18565b60005b83518110156116f55783818151811061166257611662615e59565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b1580156116ca57600080fd5b505af11580156116de573d6000803e3d6000fd5b5050505080806116ed90615dc0565b915050611647565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287969395860193909291908301828280156117cc57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117ae575b505050505081525050905060005b81604001515181101561193a5760005b600c548110156119275760006118f0600c838154811061180c5761180c615e59565b90600052602060002001548560400151858151811061182d5761182d615e59565b602002602001015188600460008960400151898151811061185057611850615e59565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119145750600195945050505050565b508061191f81615dc0565b9150506117ea565b508061193281615dc0565b9150506117da565b5060009392505050565b6002805414156119845760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055336000908152600960205260409020546001600160601b03808316911610156119c457604051631e9acf1760e31b815260040160405180910390fd5b33600090815260096020526040812080548392906119ec9084906001600160601b0316615d68565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a349190615d68565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611aae576040519150601f19603f3d011682016040523d82523d6000602084013e611ab3565b606091505b5050905080611ad557604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611ae7613764565b611af081613e7f565b15611b32576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c18565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611bf65760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055336000908152600860205260409020546001600160601b0380831691161015611c3657604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611c5e9084906001600160601b0316615d68565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611ca69190615d68565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d1557600080fd5b505af1158015611d29573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d4d9190615484565b611d6a57604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611d7b613764565b604080518082018252600091611daa919084906002908390839080828437600092019190915250612eaa915050565b6000818152600b60205260409020549091506001600160a01b031615611dff576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c18565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610dab565b6001546001600160a01b03163314611ee55760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c18565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611f44613764565b600a80546001600160a01b0319166001600160a01b0392909216919091179055565b6000600280541415611fa85760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556020808301356000908152600590915260409020546001600160a01b0316611fe757604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612039576040516379bfd40160e01b815260208401356004820152336024820152604401610c18565b600f5461ffff166120506060850160408601615650565b61ffff161080612073575060c861206d6060850160408601615650565b61ffff16115b156120b9576120886060840160408501615650565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c18565b600f5462010000900463ffffffff166120d86080850160608601615739565b63ffffffff161115612141576120f46080840160608501615739565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c18565b6101f461215460a0850160808601615739565b63ffffffff1611156121b35761217060a0840160808501615739565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c18565b60006121c0826001615cd0565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061224c906110c290890189615bf3565b9050600061225982613df9565b90508361226461413b565b60208a013561227960808c0160608d01615739565b61228960a08d0160808e01615739565b33866040516020016122a19796959493929190615ab0565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d60400160208101906123189190615650565b8e606001602081019061232b9190615739565b8f608001602081019061233e9190615739565b8960405161235196959493929190615a71565b60405180910390a4505033600090815260046020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b6123af613764565b6003546001600160a01b0316156123f2576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b0319166001600160a01b0392909216919091179055565b60006002805414156124565760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055600033612468600143615d51565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b77ffffffffffffffffffffffffffffffffffffffffffffffff1916606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124f983615ddb565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561253b5761253b615e6f565b604051908082528060200260200182016040528015612564578160200160208202803683370190505b5060408051808201825260008082526020808301828152878352600682528483209351845491516001600160601b03908116600160601b0277ffffffffffffffffffffffffffffffffffffffffffffffff199093169116171790925582516060810184523381528083018281528185018681528884526005855294909220815181546001600160a01b039182166001600160a01b0319918216178355935160018301805491909216941693909317909255925180519495509293909261263192600285019291019061516f565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b6002805414156126b45760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556003546001600160a01b031633146126fc576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612736576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612744828401846154a1565b6000818152600560205260409020549091506001600160a01b031661277c57604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127a38385615cfc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127eb9190615cfc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a82878461283e9190615cb8565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b61286c613764565b6007544790600160a01b90046001600160601b0316818111156128ac576040516354ced18160e11b81526004810182905260248101839052604401610c18565b8181101561297b5760006128c08284615d51565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d806000811461290f576040519150601f19603f3d011682016040523d82523d6000602084013e612914565b606091505b505090508061293657604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b612988613764565b6000818152600560205260409020546001600160a01b03166129bd57604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c219082906001600160a01b03166137c0565b6129e8613764565b60c861ffff87161115612a225760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c18565b60008213612a46576040516321ea67b360e11b815260048101839052602401610c18565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612baa5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556000818152600560205260409020546001600160a01b0316612be357604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c5557600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c18565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526005602052604090205482906001600160a01b031680612d0f57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d4357604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415612d835760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028080556000858152600560205260409020015460641415612dd2576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612e0a57610e99565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612ebd919061591a565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612f1257604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612f4657604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b600280541415612f865760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b60028055612f9384611742565b15612fb157604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1661300e576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c18565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561307157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613053575b505050505090506000600182516130889190615d51565b905060005b825181101561319457856001600160a01b03168382815181106130b2576130b2615e59565b60200260200101516001600160a01b031614156131825760008383815181106130dd576130dd615e59565b6020026020010151905080600560008a8152602001908152602001600020600201838154811061310f5761310f615e59565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260059091526040902060020180548061315a5761315a615e43565b600082815260209020810160001990810180546001600160a01b031916905501905550613194565b8061318c81615dc0565b91505061308d565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161284f565b600c818154811061320757600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b03168061325057604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461328457604051636c51fda960e11b81526001600160a01b0382166004820152602401610c18565b6002805414156132c45760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556000848152600560205260409020600101546001600160a01b03848116911614610e995760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e97565b600081815260056020526040812054819081906060906001600160a01b031661338c57604051630fb532db60e11b815260040160405180910390fd5b60008581526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b900416946001600160a01b0390931693919283919083018282801561341d57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133ff575b5050505050905093509350935093509193509193565b61343b613764565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561349857600080fd5b505afa1580156134ac573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134d091906154ba565b6007549091506801000000000000000090046001600160601b031681811115613516576040516354ced18160e11b81526004810182905260248101839052604401610c18565b8181101561297b57600061352a8284615d51565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561357a57600080fd5b505af115801561358e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135b29190615484565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b60028054141561363b5760405162461bcd60e51b815260206004820152601f6024820152600080516020615ea98339815191526044820152606401610c18565b600280556000818152600560205260409020546001600160a01b031661367457604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136a38385615cfc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136eb9190615cfc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde82348461373e9190615cb8565b60408051928352602083019190915201612cc6565b61375b613764565b610c21816141d4565b6000546001600160a01b031633146137be5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c18565b565b6000806137cc84613ee9565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b15801561382957600080fd5b505af115801561383d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138619190615484565b61387e57604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d80600081146138d4576040519150601f19603f3d011682016040523d82523d6000602084013e6138d9565b606091505b50509050806138fb57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905281830181905282518084018452919290916139a09186906002908390839080828437600092019190915250612eaa915050565b6000818152600b60205260409020549091506001600160a01b0316806139dc57604051631dfd6e1360e21b815260048101839052602401610c18565b6000828660c001356040516020016139fe929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613a5d576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613a6b6020880188615754565b6020880135613a8060608a0160408b01615739565b613a9060808b0160608c01615739565b613aa060a08c0160808d01615344565b613aad60a08d018d615bf3565b604051602001613ac4989796959493929190615afa565b604051602081830303815290604052805190602001208114613b12576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613b29613b246020890189615754565b61427e565b905080613c37576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613b6c60208a018a615754565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613bac57600080fd5b505afa158015613bc0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613be491906154ba565b905080613c3757613bf86020880188615754565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c18565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c7f613c79368c90038c018c615577565b83614385565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613cbe57600080fd5b611388810390508460408204820311613cd657600080fd5b50823b613ce257600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613d235750604080516020810190915260008152613ca6565b7f92fd133800000000000000000000000000000000000000000000000000000000613d4e8385615d90565b6001600160e01b03191614613d8f576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d9c8260048186615c8e565b810190613cf391906154d3565b60008115613dd757601054613dd09086908690640100000000900463ffffffff16866143f0565b9050613df1565b601054613dee908690869063ffffffff168661445a565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613e3291511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613ee057826001600160a01b031660118281548110613eaa57613eaa615e59565b6000918252602090912001546001600160a01b03161415613ece5750600192915050565b80613ed881615dc0565b915050613e83565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613f7557602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613f57575b5050509190925250505060008581526006602090815260408083208151808301909252546001600160601b03808216808452600160601b9092041692820183905296509094509192505b826040015151811015614037576004600084604001518381518110613fe657613fe6615e59565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff191690558061402f81615dc0565b915050613fbf565b50600085815260056020526040812080546001600160a01b0319908116825560018201805490911690559061406f60028301826151d4565b50506000858152600660205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff19169055600780548591906008906140c89084906801000000000000000090046001600160601b0316615d68565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b03166141109190615d68565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b1811480614150575062066eed81145b156141cd5760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561418f57600080fd5b505afa1580156141a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906141c791906154ba565b91505090565b4391505090565b6001600160a01b03811633141561422d5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c18565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b1811480614293575062066eed81145b15614375576101008367ffffffffffffffff166142ae61413b565b6142b89190615d51565b11806142d557506142c761413b565b8367ffffffffffffffff1610155b156142e35750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561433d57600080fd5b505afa158015614351573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613cf391906154ba565b505067ffffffffffffffff164090565b60006143b98360000151846020015185604001518660600151868860a001518960c001518a60e001518b6101000151614561565b600383602001516040516020016143d1929190615a0f565b60408051601f1981840301815291905280516020909101209392505050565b6000806143fb61479c565b905060005a61440a8888615cb8565b6144149190615d51565b61441e9085615d32565b9050600061443763ffffffff871664e8d4a51000615d32565b9050826144448284615cb8565b61444e9190615cb8565b98975050505050505050565b6000806144656147f8565b90506000811361448b576040516321ea67b360e11b815260048101829052602401610c18565b600061449561479c565b9050600082825a6144a68b8b615cb8565b6144b09190615d51565b6144ba9088615d32565b6144c49190615cb8565b6144d690670de0b6b3a7640000615d32565b6144e09190615d1e565b905060006144f963ffffffff881664e8d4a51000615d32565b9050614511816b033b2e3c9fd0803ce8000000615d51565b82111561454a576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6145548183615cb8565b9998505050505050505050565b61456a896148df565b6145b65760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c18565b6145bf886148df565b61460b5760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c18565b614614836148df565b6146605760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c18565b614669826148df565b6146b55760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c18565b6146c1878a88876149b8565b61470d5760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c18565b60006147198a87614aed565b9050600061472c898b878b868989614b51565b9050600061473d838d8d8a86614c71565b9050808a1461478e5760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c18565b505050505050505050505050565b60004661a4b18114806147b1575062066eed81145b156147f057606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561418f57600080fd5b600091505090565b600f54600a54604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000936601000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b15801561487257600080fd5b505afa158015614886573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906148aa919061577e565b5094509092508491505080156148ce57506148c58242615d51565b8463ffffffff16105b15613df15750600e54949350505050565b80516000906401000003d019116149385760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c18565b60208201516401000003d019116149915760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c18565b60208201516401000003d0199080096149b18360005b6020020151614cb1565b1492915050565b60006001600160a01b038216614a105760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c18565b602084015160009060011615614a2757601c614a2a565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614ac5573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614af56151f2565b614b2260018484604051602001614b0e939291906158f9565b604051602081830303815290604052614cd5565b90505b614b2e816148df565b613ca6578051604080516020810192909252614b4a9101614b0e565b9050614b25565b614b596151f2565b825186516401000003d0199081900691061415614bb85760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c18565b614bc3878988614d24565b614c0f5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c18565b614c1a848685614d24565b614c665760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c18565b61444e868484614e5e565b600060028686868587604051602001614c8f9695949392919061589a565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614cdd6151f2565b614ce682614f25565b8152614cfb614cf68260006149a7565b614f60565b602082018190526002900660011415614d1f576020810180516401000003d0190390525b919050565b600082614d735760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c18565b83516020850151600090614d8990600290615e03565b15614d9557601c614d98565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614e0a573d6000803e3d6000fd5b505050602060405103519050600086604051602001614e299190615888565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614e666151f2565b835160208086015185519186015160009384938493614e8793909190614f80565b919450925090506401000003d019858209600114614ee75760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c18565b60405180604001604052806401000003d01980614f0657614f06615e2d565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614d1f57604080516020808201939093528151808203840181529082019091528051910120614f2d565b6000613ca6826002614f796401000003d0196001615cb8565b901c615060565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614fc083838585615102565b9098509050614fd188828e88615126565b9098509050614fe288828c87615126565b90985090506000614ff58d878b85615126565b909850905061500688828686615102565b909850905061501788828e89615126565b909850905081811461504c576401000003d019818a0998506401000003d01982890997506401000003d0198183099650615050565b8196505b5050505050509450945094915050565b60008061506b615210565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a082015261509d61522e565b60208160c0846005600019fa9250826150f85760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c18565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156151c4579160200282015b828111156151c457825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019061518f565b506151d092915061524c565b5090565b5080546000825590600052602060002090810190610c21919061524c565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156151d0576000815560010161524d565b8035614d1f81615e85565b8060408101831015613ca657600080fd5b600082601f83011261528e57600080fd5b615296615c41565b8083856040860111156152a857600080fd5b60005b60028110156152ca5781358452602093840193909101906001016152ab565b509095945050505050565b600060c082840312156152e757600080fd5b50919050565b803561ffff81168114614d1f57600080fd5b803563ffffffff81168114614d1f57600080fd5b805169ffffffffffffffffffff81168114614d1f57600080fd5b80356001600160601b0381168114614d1f57600080fd5b60006020828403121561535657600080fd5b8135613cf381615e85565b6000806040838503121561537457600080fd5b823561537f81615e85565b915061538d6020840161532d565b90509250929050565b600080606083850312156153a957600080fd5b82356153b481615e85565b915061538d846020850161526c565b600080600080606085870312156153d957600080fd5b84356153e481615e85565b935060208501359250604085013567ffffffffffffffff8082111561540857600080fd5b818701915087601f83011261541c57600080fd5b81358181111561542b57600080fd5b88602082850101111561543d57600080fd5b95989497505060200194505050565b60006040828403121561545e57600080fd5b613cf3838361526c565b60006040828403121561547a57600080fd5b613cf3838361527d565b60006020828403121561549657600080fd5b8151613cf381615e9a565b6000602082840312156154b357600080fd5b5035919050565b6000602082840312156154cc57600080fd5b5051919050565b6000602082840312156154e557600080fd5b6040516020810181811067ffffffffffffffff8211171561550857615508615e6f565b604052823561551681615e9a565b81529392505050565b6000808284036101c081121561553457600080fd5b6101a08082121561554457600080fd5b849350830135905067ffffffffffffffff81111561556157600080fd5b61556d858286016152d5565b9150509250929050565b60006101a0828403121561558a57600080fd5b615592615c6a565b61559c848461527d565b81526155ab846040850161527d565b60208201526080830135604082015260a0830135606082015260c083013560808201526155da60e08401615261565b60a08201526101006155ee8582860161527d565b60c083015261560185610140860161527d565b60e083015261018084013581830152508091505092915050565b60006020828403121561562d57600080fd5b813567ffffffffffffffff81111561564457600080fd5b613df1848285016152d5565b60006020828403121561566257600080fd5b613cf3826152ed565b60008060008060008086880360e081121561568557600080fd5b61568e886152ed565b965061569c602089016152ff565b95506156aa604089016152ff565b94506156b8606089016152ff565b9350608088013592506040609f19820112156156d357600080fd5b506156dc615c41565b6156e860a089016152ff565b81526156f660c089016152ff565b6020820152809150509295509295509295565b6000806040838503121561571c57600080fd5b82359150602083013561572e81615e85565b809150509250929050565b60006020828403121561574b57600080fd5b613cf3826152ff565b60006020828403121561576657600080fd5b813567ffffffffffffffff81168114613cf357600080fd5b600080600080600060a0868803121561579657600080fd5b61579f86615313565b94506020860151935060408601519250606086015191506157c260808701615313565b90509295509295909350565b600081518084526020808501945080840160005b838110156158075781516001600160a01b0316875295820195908201906001016157e2565b509495945050505050565b8060005b6002811015615835578151845260209384019390910190600101615816565b50505050565b6000815180845260005b8181101561586157602081850181015186830182015201615845565b81811115615873576000602083870101525b50601f01601f19169290920160200192915050565b6158928183615812565b604001919050565b8681526158aa6020820187615812565b6158b76060820186615812565b6158c460a0820185615812565b6158d160e0820184615812565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526159096020820184615812565b606081019190915260800192915050565b60408101613ca68284615812565b602081526000613cf3602083018461583b565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261598160e08401826157ce565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615a01578451835293830193918301916001016159e5565b509098975050505050505050565b82815260608101613cf36020830184615812565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a6457845183529383019391830191600101615a48565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261444e60c083018461583b565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261455460e083018461583b565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b9b608083018561583b565b9050821515606083015295945050505050565b60006001600160601b0380871683528086166020840152506001600160a01b038416604083015260806060830152615be960808301846157ce565b9695505050505050565b6000808335601e19843603018112615c0a57600080fd5b83018035915067ffffffffffffffff821115615c2557600080fd5b602001915036819003821315615c3a57600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c6457615c64615e6f565b60405290565b604051610120810167ffffffffffffffff81118282101715615c6457615c64615e6f565b60008085851115615c9e57600080fd5b83861115615cab57600080fd5b5050820193919092039150565b60008219821115615ccb57615ccb615e17565b500190565b600067ffffffffffffffff808316818516808303821115615cf357615cf3615e17565b01949350505050565b60006001600160601b03808316818516808303821115615cf357615cf3615e17565b600082615d2d57615d2d615e2d565b500490565b6000816000190483118215151615615d4c57615d4c615e17565b500290565b600082821015615d6357615d63615e17565b500390565b60006001600160601b0383811690831681811015615d8857615d88615e17565b039392505050565b6001600160e01b03198135818116916004851015615db85780818660040360031b1b83161692505b505092915050565b6000600019821415615dd457615dd4615e17565b5060010190565b600067ffffffffffffffff80831681811415615df957615df9615e17565b6001019392505050565b600082615e1257615e12615e2d565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c2157600080fd5b8015158114610c2157600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200609738038062006097833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615eb7620001e0600039600081816105f80152613aef0152615eb76000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610947578063ee9d2d381461096e578063f2fde38b1461099b57600080fd5b8063dc311dd3146108e4578063e72f6e3014610914578063e8509bff1461093457600080fd5b8063d98e620e116100bb578063d98e620e1461086e578063da2f26101461088e578063dac83d29146108c457600080fd5b8063bec4c08c1461080e578063caf70c4a1461082e578063cb6317971461084e57600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107ae578063b08c8795146107ce578063b2a7cac5146107ee57600080fd5b8063a4c0ed361461074e578063a8cb447b1461076e578063aa433aff1461078e57600080fd5b80639b1c385e116101745780639b1c385e146106df5780639d40a6fd146106ff578063a21a23e41461073957600080fd5b806386fe91c7146106955780638da5cb5b146106c157600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461061a5780636f64f03f1461066057806379ba50971461068057600080fd5b806364d51a2a146105b157806366316d8d146105c6578063689c4517146105e657600080fd5b806346d8d4861161022d57806346d8d4861461055157806357133e64146105715780635d06b4ab1461059157600080fd5b806340d6bb82146104f657806341af6c871461052157600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610482578063330987b31461049e578063405b84fa146104d657600080fd5b80630ae095401461040257806315c48b84146104225780631b6b6d231461044a57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103e257600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109bb565b60405161031a93929190615992565b60405180910390f35b34801561032f57600080fd5b5061034361033e3660046152f8565b610a37565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600f546103b19061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff93841660208601529183169184019190915216606082015260800161031a565b3480156103ee57600080fd5b506103436103fd366004615439565b610bf9565b34801561040e57600080fd5b5061034361041d3660046156f6565b610d8d565b34801561042e57600080fd5b5061043760c881565b60405161ffff909116815260200161031a565b34801561045657600080fd5b5060035461046a906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b34801561048e57600080fd5b506040516001815260200161031a565b3480156104aa57600080fd5b506104be6104b936600461550c565b610e79565b6040516001600160601b03909116815260200161031a565b3480156104e257600080fd5b506103436104f13660046156f6565b611338565b34801561050257600080fd5b5061050c6101f481565b60405163ffffffff909116815260200161031a565b34801561052d57600080fd5b5061054161053c36600461548e565b611717565b604051901515815260200161031a565b34801561055d57600080fd5b5061034361056c366004615315565b611919565b34801561057d57600080fd5b5061034361058c36600461534a565b611ab4565b34801561059d57600080fd5b506103436105ac3660046152f8565b611b2d565b3480156105bd57600080fd5b50610437606481565b3480156105d257600080fd5b506103436105e1366004615315565b611c04565b3480156105f257600080fd5b5061046a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561062657600080fd5b506010546106439063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561066c57600080fd5b5061034361067b366004615383565b611dc0565b34801561068c57600080fd5b50610343611ed8565b3480156106a157600080fd5b506008546104be906801000000000000000090046001600160601b031681565b3480156106cd57600080fd5b506000546001600160a01b031661046a565b3480156106eb57600080fd5b5061035b6106fa366004615608565b611f89565b34801561070b57600080fd5b506008546107209067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561074557600080fd5b5061035b6123ca565b34801561075a57600080fd5b506103436107693660046153b0565b61262a565b34801561077a57600080fd5b506103436107893660046152f8565b612819565b34801561079a57600080fd5b506103436107a936600461548e565b612935565b3480156107ba57600080fd5b5060045461046a906001600160a01b031681565b3480156107da57600080fd5b506103436107e9366004615658565b612995565b3480156107fa57600080fd5b5061034361080936600461548e565b612b1f565b34801561081a57600080fd5b506103436108293660046156f6565b612c8c565b34801561083a57600080fd5b5061035b610849366004615455565b612e5f565b34801561085a57600080fd5b506103436108693660046156f6565b612e8f565b34801561087a57600080fd5b5061035b61088936600461548e565b6131ac565b34801561089a57600080fd5b5061046a6108a936600461548e565b600b602052600090815260409020546001600160a01b031681565b3480156108d057600080fd5b506103436108df3660046156f6565b6131cd565b3480156108f057600080fd5b506109046108ff36600461548e565b613305565b60405161031a9493929190615b90565b34801561092057600080fd5b5061034361092f3660046152f8565b6133e8565b61034361094236600461548e565b6135b0565b34801561095357600080fd5b506008546104be90600160a01b90046001600160601b031681565b34801561097a57600080fd5b5061035b61098936600461548e565b600d6020526000908152604090205481565b3480156109a757600080fd5b506103436109b63660046152f8565b613708565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a2557602002820191906000526020600020905b815481526020019060010190808311610a11575b50505050509050925092509250909192565b610a3f613719565b60115460005b81811015610bcc57826001600160a01b031660118281548110610a6a57610a6a615e3b565b6000918252602090912001546001600160a01b03161415610bba576011610a92600184615d33565b81548110610aa257610aa2615e3b565b600091825260209091200154601180546001600160a01b039092169183908110610ace57610ace615e3b565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b05600185615d33565b81548110610b1557610b15615e3b565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b5457610b54615e25565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bc481615da2565b915050610a45565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c01613719565b604080518082018252600091610c30919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031680610c6c57604051631dfd6e1360e21b815260048101839052602401610bed565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d445782600c8281548110610ca757610ca7615e3b565b90600052602060002001541415610d3257600c805460009190610ccc90600190615d33565b81548110610cdc57610cdc615e3b565b9060005260206000200154905080600c8381548110610cfd57610cfd615e3b565b600091825260209091200155600c805480610d1a57610d1a615e25565b60019003818190600052602060002001600090559055505b80610d3c81615da2565b915050610c89565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d8091815260200190565b60405180910390a2505050565b60008281526006602052604090205482906001600160a01b031680610dc557604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610df957604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b600280541415610e395760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055610e4684611717565b15610e6457604051631685ecdd60e31b815260040160405180910390fd5b610e6e8484613775565b505060016002555050565b6000600280541415610ebb5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b6002805560005a90506000610ed0858561390c565b90506000610ee4608086016060870161571b565b63ffffffff1667ffffffffffffffff811115610f0257610f02615e51565b604051908082528060200260200182016040528015610f2b578160200160208202803683370190505b50905060005b610f41608087016060880161571b565b63ffffffff16811015610fb657826040015181604051602001610f6e929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f9957610f99615e3b565b602090810291909101015280610fae81615da2565b915050610f31565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161100791908690602401615a05565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b0319909416939093179092529150600090611083906110679060608b01908b0161571b565b63ffffffff1661107d60a08b0160808c016152f8565b84613c61565b9050600061109c61109760a08b018b615bd5565b613caf565b51600f549091506000906110c79089906a0100000000000000000000900463ffffffff163a85613d5e565b905081156111d0576020808b01356000908152600790915260409020546001600160601b03808316600160601b90920416101561111757604051631e9acf1760e31b815260040160405180910390fd5b60208a81013560009081526007909152604090208054829190600c9061114e908490600160601b90046001600160601b0316615d4a565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b03168352600a9091528120805485945090926111a791859116615cde565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506112bc565b6020808b01356000908152600790915260409020546001600160601b038083169116101561121157604051631e9acf1760e31b815260040160405180910390fd5b6020808b01356000908152600790915260408120805483929061123e9084906001600160601b0316615d4a565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261129791859116615cde565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006112d76040518060200160405280851515815250613dae565b90508a6020013588602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8a6040015185858960405161131c9493929190615b55565b60405180910390a35060016002559a9950505050505050505050565b61134181613e34565b61136957604051635428d44960e01b81526001600160a01b0382166004820152602401610bed565b60008060008061137886613305565b9350935093509350336001600160a01b0316826001600160a01b0316146113e15760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610bed565b6113ea86611717565b156114375760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610bed565b60006040518060c0016040528061144c600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016114a0919061591d565b60405160208183030381529060405290506114ba88613e9e565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061150c90859060040161590a565b6000604051808303818588803b15801561152557600080fd5b505af1158015611539573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561159557600080fd5b505af11580156115a9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115cd9190615471565b6116195760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610bed565b60005b83518110156116ca5783818151811061163757611637615e3b565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561169f57600080fd5b505af11580156116b3573d6000803e3d6000fd5b5050505080806116c290615da2565b91505061161c565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600660209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287969395860193909291908301828280156117a157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611783575b505050505081525050905060005b81604001515181101561190f5760005b600c548110156118fc5760006118c5600c83815481106117e1576117e1615e3b565b90600052602060002001548560400151858151811061180257611802615e3b565b602002602001015188600560008960400151898151811061182557611825615e3b565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156118e95750600195945050505050565b50806118f481615da2565b9150506117bf565b508061190781615da2565b9150506117af565b5060009392505050565b6002805414156119595760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055336000908152600a60205260409020546001600160601b038083169116101561199957604051631e9acf1760e31b815260040160405180910390fd5b336000908152600a6020526040812080548392906119c19084906001600160601b0316615d4a565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600860148282829054906101000a90046001600160601b0316611a099190615d4a565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611a83576040519150601f19603f3d011682016040523d82523d6000602084013e611a88565b606091505b5050905080611aaa57604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611abc613719565b6003546001600160a01b031615611aff576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b039384166001600160a01b03199182161790915560048054929093169116179055565b611b35613719565b611b3e81613e34565b15611b80576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610bed565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611c445760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055336000908152600960205260409020546001600160601b0380831691161015611c8457604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611cac9084906001600160601b0316615d4a565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550806008808282829054906101000a90046001600160601b0316611cf39190615d4a565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d6257600080fd5b505af1158015611d76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d9a9190615471565b611db757604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611dc8613719565b604080518082018252600091611df7919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031615611e4c576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610bed565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d80565b6001546001600160a01b03163314611f325760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610bed565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6000600280541415611fcb5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556020808301356000908152600690915260409020546001600160a01b031661200a57604051630fb532db60e11b815260040160405180910390fd5b33600090815260056020908152604080832085830135845290915290205467ffffffffffffffff168061205c576040516379bfd40160e01b815260208401356004820152336024820152604401610bed565b600f5461ffff16612073606085016040860161563d565b61ffff161080612096575060c8612090606085016040860161563d565b61ffff16115b156120dc576120ab606084016040850161563d565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610bed565b600f5462010000900463ffffffff166120fb608085016060860161571b565b63ffffffff16111561216457612117608084016060850161571b565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610bed565b6101f461217760a085016080860161571b565b63ffffffff1611156121d65761219360a084016080850161571b565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610bed565b60006121e3826001615cb2565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061226f9061109790890189615bd5565b9050600061227c82613dae565b9050836122876140ef565b60208a013561229c60808c0160608d0161571b565b6122ac60a08d0160808e0161571b565b33866040516020016122c49796959493929190615a92565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061233b919061563d565b8e606001602081019061234e919061571b565b8f6080016020810190612361919061571b565b8960405161237496959493929190615a53565b60405180910390a4505033600090815260056020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b600060028054141561240c5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b6002805560003361241e600143615d33565b600854604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b77ffffffffffffffffffffffffffffffffffffffffffffffff1916606882015260700160408051601f1981840301815291905280516020909101206008805491925067ffffffffffffffff9091169060006124af83615dbd565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff8111156124f1576124f1615e51565b60405190808252806020026020018201604052801561251a578160200160208202803683370190505b5060408051808201825260008082526020808301828152878352600782528483209351845491516001600160601b03908116600160601b0277ffffffffffffffffffffffffffffffffffffffffffffffff199093169116171790925582516060810184523381528083018281528185018681528884526006855294909220815181546001600160a01b039182166001600160a01b031991821617835593516001830180549190921694169390931790925592518051949550929390926125e7926002850192910190615123565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b60028054141561266a5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556003546001600160a01b031633146126b2576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146126ec576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006126fa8284018461548e565b6000818152600660205260409020549091506001600160a01b031661273257604051630fb532db60e11b815260040160405180910390fd5b600081815260076020526040812080546001600160601b0316918691906127598385615cde565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550846008808282829054906101000a90046001600160601b03166127a09190615cde565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846127f39190615c9a565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b612821613719565b6008544790600160a01b90046001600160601b031681811115612861576040516354ced18160e11b81526004810182905260248101839052604401610bed565b818110156129305760006128758284615d33565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128c4576040519150601f19603f3d011682016040523d82523d6000602084013e6128c9565b606091505b50509050806128eb57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b61293d613719565b6000818152600660205260409020546001600160a01b031661297257604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040902054610bf69082906001600160a01b0316613775565b61299d613719565b60c861ffff871611156129d75760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610bed565b600082136129fb576040516321ea67b360e11b815260048101839052602401610bed565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612b5f5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556000818152600660205260409020546001600160a01b0316612b9857604051630fb532db60e11b815260040160405180910390fd5b6000818152600660205260409020600101546001600160a01b03163314612c0a57600081815260066020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610bed565b6000818152600660209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526006602052604090205482906001600160a01b031680612cc457604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612cf857604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b600280541415612d385760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028080556000858152600660205260409020015460641415612d87576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff1615612dbf57610e6e565b6001600160a01b03831660008181526005602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600683528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612e7291906158fc565b604051602081830303815290604052805190602001209050919050565b60008281526006602052604090205482906001600160a01b031680612ec757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612efb57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b600280541415612f3b5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055612f4884611717565b15612f6657604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff16612fc3576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610bed565b60008481526006602090815260408083206002018054825181850281018501909352808352919290919083018282801561302657602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613008575b5050505050905060006001825161303d9190615d33565b905060005b825181101561314957856001600160a01b031683828151811061306757613067615e3b565b60200260200101516001600160a01b0316141561313757600083838151811061309257613092615e3b565b6020026020010151905080600660008a815260200190815260200160002060020183815481106130c4576130c4615e3b565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260069091526040902060020180548061310f5761310f615e25565b600082815260209020810160001990810180546001600160a01b031916905501905550613149565b8061314181615da2565b915050613042565b506001600160a01b03851660008181526005602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a79101612804565b600c81815481106131bc57600080fd5b600091825260209091200154905081565b60008281526006602052604090205482906001600160a01b03168061320557604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461323957604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b6002805414156132795760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556000848152600660205260409020600101546001600160a01b03848116911614610e6e5760008481526006602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e4c565b600081815260066020526040812054819081906060906001600160a01b031661334157604051630fb532db60e11b815260040160405180910390fd5b60008581526007602090815260408083205460068352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b900416946001600160a01b039093169391928391908301828280156133d257602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133b4575b5050505050905093509350935093509193509193565b6133f0613719565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561344d57600080fd5b505afa158015613461573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061348591906154a7565b6008549091506801000000000000000090046001600160601b0316818111156134cb576040516354ced18160e11b81526004810182905260248101839052604401610bed565b818110156129305760006134df8284615d33565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561352f57600080fd5b505af1158015613543573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135679190615471565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6002805414156135f05760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556000818152600660205260409020546001600160a01b031661362957604051630fb532db60e11b815260040160405180910390fd5b60008181526007602052604090208054600160601b90046001600160601b0316903490600c6136588385615cde565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600860148282829054906101000a90046001600160601b03166136a09190615cde565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136f39190615c9a565b60408051928352602083019190915201612c7b565b613710613719565b610bf681614188565b6000546001600160a01b031633146137735760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bed565b565b60008061378184613e9e565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137de57600080fd5b505af11580156137f2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138169190615471565b61383357604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613889576040519150601f19603f3d011682016040523d82523d6000602084013e61388e565b606091505b50509050806138b057604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905281830181905282518084018452919290916139559186906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b03168061399157604051631dfd6e1360e21b815260048101839052602401610bed565b6000828660c001356040516020016139b3929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613a12576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613a206020880188615736565b6020880135613a3560608a0160408b0161571b565b613a4560808b0160608c0161571b565b613a5560a08c0160808d016152f8565b613a6260a08d018d615bd5565b604051602001613a79989796959493929190615adc565b604051602081830303815290604052805190602001208114613ac7576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613ade613ad96020890189615736565b614232565b905080613bec576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613b2160208a018a615736565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613b6157600080fd5b505afa158015613b75573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b9991906154a7565b905080613bec57613bad6020880188615736565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610bed565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c34613c2e368c90038c018c615564565b83614339565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613c7357600080fd5b611388810390508460408204820311613c8b57600080fd5b50823b613c9757600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613cd85750604080516020810190915260008152613c5b565b7f92fd133800000000000000000000000000000000000000000000000000000000613d038385615d72565b6001600160e01b03191614613d44576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d518260048186615c70565b810190613ca891906154c0565b60008115613d8c57601054613d859086908690640100000000900463ffffffff16866143a4565b9050613da6565b601054613da3908690869063ffffffff168661440e565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613de791511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613e9557826001600160a01b031660118281548110613e5f57613e5f615e3b565b6000918252602090912001546001600160a01b03161415613e835750600192915050565b80613e8d81615da2565b915050613e38565b50600092915050565b6000818152600660209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613f2a57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613f0c575b5050509190925250505060008581526007602090815260408083208151808301909252546001600160601b03808216808452600160601b9092041692820183905296509094509192505b826040015151811015613fec576005600084604001518381518110613f9b57613f9b615e3b565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613fe481615da2565b915050613f74565b50600085815260066020526040812080546001600160a01b031990811682556001820180549091169055906140246002830182615188565b50506000858152600760205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff1916905560088054859190819061407c9084906801000000000000000090046001600160601b0316615d4a565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600860148282829054906101000a90046001600160601b03166140c49190615d4a565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b1811480614104575062066eed81145b156141815760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561414357600080fd5b505afa158015614157573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061417b91906154a7565b91505090565b4391505090565b6001600160a01b0381163314156141e15760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bed565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b1811480614247575062066eed81145b15614329576101008367ffffffffffffffff166142626140ef565b61426c9190615d33565b1180614289575061427b6140ef565b8367ffffffffffffffff1610155b156142975750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156142f157600080fd5b505afa158015614305573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ca891906154a7565b505067ffffffffffffffff164090565b600061436d8360000151846020015185604001518660600151868860a001518960c001518a60e001518b6101000151614515565b600383602001516040516020016143859291906159f1565b60408051601f1981840301815291905280516020909101209392505050565b6000806143af614750565b905060005a6143be8888615c9a565b6143c89190615d33565b6143d29085615d14565b905060006143eb63ffffffff871664e8d4a51000615d14565b9050826143f88284615c9a565b6144029190615c9a565b98975050505050505050565b6000806144196147ac565b90506000811361443f576040516321ea67b360e11b815260048101829052602401610bed565b6000614449614750565b9050600082825a61445a8b8b615c9a565b6144649190615d33565b61446e9088615d14565b6144789190615c9a565b61448a90670de0b6b3a7640000615d14565b6144949190615d00565b905060006144ad63ffffffff881664e8d4a51000615d14565b90506144c5816b033b2e3c9fd0803ce8000000615d33565b8211156144fe576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6145088183615c9a565b9998505050505050505050565b61451e89614893565b61456a5760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610bed565b61457388614893565b6145bf5760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610bed565b6145c883614893565b6146145760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610bed565b61461d82614893565b6146695760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610bed565b614675878a888761496c565b6146c15760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610bed565b60006146cd8a87614aa1565b905060006146e0898b878b868989614b05565b905060006146f1838d8d8a86614c25565b9050808a146147425760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610bed565b505050505050505050505050565b60004661a4b1811480614765575062066eed81145b156147a457606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561414357600080fd5b600091505090565b600f5460048054604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000946601000000000000900463ffffffff169384151593869384936001600160a01b039092169263feaf968c928282019260a09290829003018186803b15801561482657600080fd5b505afa15801561483a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061485e9190615760565b50945090925084915050801561488257506148798242615d33565b8463ffffffff16105b15613da65750600e54949350505050565b80516000906401000003d019116148ec5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610bed565b60208201516401000003d019116149455760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610bed565b60208201516401000003d0199080096149658360005b6020020151614c65565b1492915050565b60006001600160a01b0382166149c45760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610bed565b6020840151600090600116156149db57601c6149de565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614a79573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614aa96151a6565b614ad660018484604051602001614ac2939291906158db565b604051602081830303815290604052614c89565b90505b614ae281614893565b613c5b578051604080516020810192909252614afe9101614ac2565b9050614ad9565b614b0d6151a6565b825186516401000003d0199081900691061415614b6c5760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610bed565b614b77878988614cd8565b614bc35760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610bed565b614bce848685614cd8565b614c1a5760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610bed565b614402868484614e12565b600060028686868587604051602001614c439695949392919061587c565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614c916151a6565b614c9a82614ed9565b8152614caf614caa82600061495b565b614f14565b602082018190526002900660011415614cd3576020810180516401000003d0190390525b919050565b600082614d275760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610bed565b83516020850151600090614d3d90600290615de5565b15614d4957601c614d4c565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614dbe573d6000803e3d6000fd5b505050602060405103519050600086604051602001614ddd919061586a565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614e1a6151a6565b835160208086015185519186015160009384938493614e3b93909190614f34565b919450925090506401000003d019858209600114614e9b5760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610bed565b60405180604001604052806401000003d01980614eba57614eba615e0f565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614cd357604080516020808201939093528151808203840181529082019091528051910120614ee1565b6000613c5b826002614f2d6401000003d0196001615c9a565b901c615014565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614f74838385856150b6565b9098509050614f8588828e886150da565b9098509050614f9688828c876150da565b90985090506000614fa98d878b856150da565b9098509050614fba888286866150b6565b9098509050614fcb88828e896150da565b9098509050818114615000576401000003d019818a0998506401000003d01982890997506401000003d0198183099650615004565b8196505b5050505050509450945094915050565b60008061501f6151c4565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a08201526150516151e2565b60208160c0846005600019fa9250826150ac5760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610bed565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b828054828255906000526020600020908101928215615178579160200282015b8281111561517857825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190615143565b50615184929150615200565b5090565b5080546000825590600052602060002090810190610bf69190615200565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156151845760008155600101615201565b8035614cd381615e67565b8060408101831015613c5b57600080fd5b600082601f83011261524257600080fd5b61524a615c23565b80838560408601111561525c57600080fd5b60005b600281101561527e57813584526020938401939091019060010161525f565b509095945050505050565b600060c0828403121561529b57600080fd5b50919050565b803561ffff81168114614cd357600080fd5b803563ffffffff81168114614cd357600080fd5b805169ffffffffffffffffffff81168114614cd357600080fd5b80356001600160601b0381168114614cd357600080fd5b60006020828403121561530a57600080fd5b8135613ca881615e67565b6000806040838503121561532857600080fd5b823561533381615e67565b9150615341602084016152e1565b90509250929050565b6000806040838503121561535d57600080fd5b823561536881615e67565b9150602083013561537881615e67565b809150509250929050565b6000806060838503121561539657600080fd5b82356153a181615e67565b91506153418460208501615220565b600080600080606085870312156153c657600080fd5b84356153d181615e67565b935060208501359250604085013567ffffffffffffffff808211156153f557600080fd5b818701915087601f83011261540957600080fd5b81358181111561541857600080fd5b88602082850101111561542a57600080fd5b95989497505060200194505050565b60006040828403121561544b57600080fd5b613ca88383615220565b60006040828403121561546757600080fd5b613ca88383615231565b60006020828403121561548357600080fd5b8151613ca881615e7c565b6000602082840312156154a057600080fd5b5035919050565b6000602082840312156154b957600080fd5b5051919050565b6000602082840312156154d257600080fd5b6040516020810181811067ffffffffffffffff821117156154f5576154f5615e51565b604052823561550381615e7c565b81529392505050565b6000808284036101c081121561552157600080fd5b6101a08082121561553157600080fd5b849350830135905067ffffffffffffffff81111561554e57600080fd5b61555a85828601615289565b9150509250929050565b60006101a0828403121561557757600080fd5b61557f615c4c565b6155898484615231565b81526155988460408501615231565b60208201526080830135604082015260a0830135606082015260c083013560808201526155c760e08401615215565b60a08201526101006155db85828601615231565b60c08301526155ee856101408601615231565b60e083015261018084013581830152508091505092915050565b60006020828403121561561a57600080fd5b813567ffffffffffffffff81111561563157600080fd5b613da684828501615289565b60006020828403121561564f57600080fd5b613ca8826152a1565b60008060008060008086880360e081121561567257600080fd5b61567b886152a1565b9650615689602089016152b3565b9550615697604089016152b3565b94506156a5606089016152b3565b9350608088013592506040609f19820112156156c057600080fd5b506156c9615c23565b6156d560a089016152b3565b81526156e360c089016152b3565b6020820152809150509295509295509295565b6000806040838503121561570957600080fd5b82359150602083013561537881615e67565b60006020828403121561572d57600080fd5b613ca8826152b3565b60006020828403121561574857600080fd5b813567ffffffffffffffff81168114613ca857600080fd5b600080600080600060a0868803121561577857600080fd5b615781866152c7565b94506020860151935060408601519250606086015191506157a4608087016152c7565b90509295509295909350565b600081518084526020808501945080840160005b838110156157e95781516001600160a01b0316875295820195908201906001016157c4565b509495945050505050565b8060005b60028110156158175781518452602093840193909101906001016157f8565b50505050565b6000815180845260005b8181101561584357602081850181015186830182015201615827565b81811115615855576000602083870101525b50601f01601f19169290920160200192915050565b61587481836157f4565b604001919050565b86815261588c60208201876157f4565b61589960608201866157f4565b6158a660a08201856157f4565b6158b360e08201846157f4565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526158eb60208201846157f4565b606081019190915260800192915050565b60408101613c5b82846157f4565b602081526000613ca8602083018461581d565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261596360e08401826157b0565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159e3578451835293830193918301916001016159c7565b509098975050505050505050565b82815260608101613ca860208301846157f4565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a4657845183529383019391830191600101615a2a565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261440260c083018461581d565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261450860e083018461581d565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b7d608083018561581d565b9050821515606083015295945050505050565b60006001600160601b0380871683528086166020840152506001600160a01b038416604083015260806060830152615bcb60808301846157b0565b9695505050505050565b6000808335601e19843603018112615bec57600080fd5b83018035915067ffffffffffffffff821115615c0757600080fd5b602001915036819003821315615c1c57600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c4657615c46615e51565b60405290565b604051610120810167ffffffffffffffff81118282101715615c4657615c46615e51565b60008085851115615c8057600080fd5b83861115615c8d57600080fd5b5050820193919092039150565b60008219821115615cad57615cad615df9565b500190565b600067ffffffffffffffff808316818516808303821115615cd557615cd5615df9565b01949350505050565b60006001600160601b03808316818516808303821115615cd557615cd5615df9565b600082615d0f57615d0f615e0f565b500490565b6000816000190483118215151615615d2e57615d2e615df9565b500290565b600082821015615d4557615d45615df9565b500390565b60006001600160601b0383811690831681811015615d6a57615d6a615df9565b039392505050565b6001600160e01b03198135818116916004851015615d9a5780818660040360031b1b83161692505b505092915050565b6000600019821415615db657615db6615df9565b5060010190565b600067ffffffffffffffff80831681811415615ddb57615ddb615df9565b6001019392505050565b600082615df457615df4615e0f565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610bf657600080fd5b8015158114610bf657600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI @@ -962,28 +962,16 @@ func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactorSession) SetConfig(mi return _VRFCoordinatorV2Plus.Contract.SetConfig(&_VRFCoordinatorV2Plus.TransactOpts, minimumRequestConfirmations, maxGasLimit, stalenessSeconds, gasAfterPaymentCalculation, fallbackWeiPerUnitLink, feeConfig) } -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactor) SetLINK(opts *bind.TransactOpts, link common.Address) (*types.Transaction, error) { - return _VRFCoordinatorV2Plus.contract.Transact(opts, "setLINK", link) +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactor) SetLINKAndLINKETHFeed(opts *bind.TransactOpts, link common.Address, linkEthFeed common.Address) (*types.Transaction, error) { + return _VRFCoordinatorV2Plus.contract.Transact(opts, "setLINKAndLINKETHFeed", link, linkEthFeed) } -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusSession) SetLINK(link common.Address) (*types.Transaction, error) { - return _VRFCoordinatorV2Plus.Contract.SetLINK(&_VRFCoordinatorV2Plus.TransactOpts, link) +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusSession) SetLINKAndLINKETHFeed(link common.Address, linkEthFeed common.Address) (*types.Transaction, error) { + return _VRFCoordinatorV2Plus.Contract.SetLINKAndLINKETHFeed(&_VRFCoordinatorV2Plus.TransactOpts, link, linkEthFeed) } -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactorSession) SetLINK(link common.Address) (*types.Transaction, error) { - return _VRFCoordinatorV2Plus.Contract.SetLINK(&_VRFCoordinatorV2Plus.TransactOpts, link) -} - -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactor) SetLinkEthFeed(opts *bind.TransactOpts, linkEthFeed common.Address) (*types.Transaction, error) { - return _VRFCoordinatorV2Plus.contract.Transact(opts, "setLinkEthFeed", linkEthFeed) -} - -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusSession) SetLinkEthFeed(linkEthFeed common.Address) (*types.Transaction, error) { - return _VRFCoordinatorV2Plus.Contract.SetLinkEthFeed(&_VRFCoordinatorV2Plus.TransactOpts, linkEthFeed) -} - -func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactorSession) SetLinkEthFeed(linkEthFeed common.Address) (*types.Transaction, error) { - return _VRFCoordinatorV2Plus.Contract.SetLinkEthFeed(&_VRFCoordinatorV2Plus.TransactOpts, linkEthFeed) +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactorSession) SetLINKAndLINKETHFeed(link common.Address, linkEthFeed common.Address) (*types.Transaction, error) { + return _VRFCoordinatorV2Plus.Contract.SetLINKAndLINKETHFeed(&_VRFCoordinatorV2Plus.TransactOpts, link, linkEthFeed) } func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { @@ -3805,9 +3793,7 @@ type VRFCoordinatorV2PlusInterface interface { SetConfig(opts *bind.TransactOpts, minimumRequestConfirmations uint16, maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation uint32, fallbackWeiPerUnitLink *big.Int, feeConfig VRFCoordinatorV2PlusFeeConfig) (*types.Transaction, error) - SetLINK(opts *bind.TransactOpts, link common.Address) (*types.Transaction, error) - - SetLinkEthFeed(opts *bind.TransactOpts, linkEthFeed common.Address) (*types.Transaction, error) + SetLINKAndLINKETHFeed(opts *bind.TransactOpts, link common.Address, linkEthFeed common.Address) (*types.Transaction, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index b450f62acda..fdf455f7518 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -73,7 +73,7 @@ vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsume vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 61b058b2fcd891bc86198d13c5f2bbcc053cab338ea7c1acd6b0eea5a122d9a1 +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 6216568e976884b3a5b6664c8877f71f11fd50419f08bd43e08eaf4f6e920cf4 vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c diff --git a/core/scripts/vrfv2plus/testnet/util.go b/core/scripts/vrfv2plus/testnet/util.go index da8f9d6824c..d002b8c03b4 100644 --- a/core/scripts/vrfv2plus/testnet/util.go +++ b/core/scripts/vrfv2plus/testnet/util.go @@ -51,13 +51,10 @@ func deployCoordinator( coordinator, err := vrf_coordinator_v2plus.NewVRFCoordinatorV2Plus(coordinatorAddress, e.Ec) helpers.PanicErr(err) - linkTx, err := coordinator.SetLINK(e.Owner, common.HexToAddress(linkAddress)) + linkTx, err := coordinator.SetLINKAndLINKETHFeed(e.Owner, + common.HexToAddress(linkAddress), common.HexToAddress(linkEthAddress)) helpers.PanicErr(err) helpers.ConfirmTXMined(context.Background(), e.Ec, linkTx, e.ChainID) - - linkETHTx, err := coordinator.SetLinkEthFeed(e.Owner, common.HexToAddress(linkEthAddress)) - helpers.PanicErr(err) - helpers.ConfirmTXMined(context.Background(), e.Ec, linkETHTx, e.ChainID) return coordinatorAddress } diff --git a/core/services/vrf/v2/integration_v2_plus_test.go b/core/services/vrf/v2/integration_v2_plus_test.go index 1db674f25fc..02b5fab6b68 100644 --- a/core/services/vrf/v2/integration_v2_plus_test.go +++ b/core/services/vrf/v2/integration_v2_plus_test.go @@ -121,11 +121,7 @@ func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumer require.NoError(t, err, "failed to deploy VRFCoordinatorV2 contract to simulated ethereum blockchain") backend.Commit() - _, err = coordinatorContract.SetLINK(neil, linkAddress) - require.NoError(t, err) - backend.Commit() - - _, err = coordinatorContract.SetLinkEthFeed(neil, linkEthFeed) + _, err = coordinatorContract.SetLINKAndLINKETHFeed(neil, linkAddress, linkEthFeed) require.NoError(t, err) backend.Commit() @@ -534,6 +530,12 @@ func TestVRFV2PlusIntegration_ExternalOwnerConsumerExample(t *testing.T) { owner, backend) require.NoError(t, err) backend.Commit() + // Deploy feed + linkEthFeed, _, _, err := + mock_v3_aggregator_contract.DeployMockV3AggregatorContract( + owner, backend, 18, vrftesthelpers.WeiPerUnitLink.BigInt()) // 0.01 eth per link + require.NoError(t, err) + backend.Commit() coordinatorAddress, _, coordinator, err := vrf_coordinator_v2plus.DeployVRFCoordinatorV2Plus( owner, backend, common.Address{}) //bhs not needed for this test @@ -544,7 +546,7 @@ func TestVRFV2PlusIntegration_ExternalOwnerConsumerExample(t *testing.T) { }) require.NoError(t, err) backend.Commit() - _, err = coordinator.SetLINK(owner, linkAddress) + _, err = coordinator.SetLINKAndLINKETHFeed(owner, linkAddress, linkEthFeed) require.NoError(t, err) backend.Commit() consumerAddress, _, consumer, err := vrf_v2plus_sub_owner.DeployVRFV2PlusExternalSubOwnerExample(owner, backend, coordinatorAddress, linkAddress) @@ -598,12 +600,18 @@ func TestVRFV2PlusIntegration_SimpleConsumerExample(t *testing.T) { owner, backend) require.NoError(t, err) backend.Commit() + // Deploy feed + linkEthFeed, _, _, err := + mock_v3_aggregator_contract.DeployMockV3AggregatorContract( + owner, backend, 18, vrftesthelpers.WeiPerUnitLink.BigInt()) // 0.01 eth per link + require.NoError(t, err) + backend.Commit() coordinatorAddress, _, coordinator, err := vrf_coordinator_v2plus.DeployVRFCoordinatorV2Plus( owner, backend, common.Address{}) // bhs not needed for this test require.NoError(t, err) backend.Commit() - _, err = coordinator.SetLINK(owner, linkAddress) + _, err = coordinator.SetLINKAndLINKETHFeed(owner, linkAddress, linkEthFeed) require.NoError(t, err) backend.Commit() consumerAddress, _, consumer, err := vrf_v2plus_single_consumer.DeployVRFV2PlusSingleConsumerExample(owner, backend, coordinatorAddress, linkAddress, 1, 1, 1, [32]byte{}, false) From 7d895d7c0a55b85b82c4b543e711f19bcb8bda23 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Thu, 27 Jul 2023 17:16:05 -0400 Subject: [PATCH 022/270] revert to upkeep id permission for mercury (#9959) --- .../plugins/ocr2keeper/evm21/feed_lookup.go | 12 ++--- .../ocr2keeper/evm21/feed_lookup_test.go | 18 ++----- .../ocr2keeper/evm21/mocks/registry.go | 53 +++++++++---------- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 4 +- 4 files changed, 34 insertions(+), 53 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 49ea387c058..30cb008b566 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -182,18 +182,12 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * // allowedToUseMercury retrieves upkeep's administrative offchain config and decode a mercuryEnabled bool to indicate if // this upkeep is allowed to use Mercury service. func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (bool, error) { - var au activeUpkeep - var ok bool - if au, ok = r.active[upkeepId.String()]; !ok { - return false, fmt.Errorf("upkeep %s is not active", upkeepId) - } - - allowed, ok := r.mercury.allowListCache.Get(au.Admin.Hex()) + allowed, ok := r.mercury.allowListCache.Get(upkeepId.String()) if ok { return allowed.(bool), nil } - cfg, err := r.registry.GetAdminPrivilegeConfig(opts, au.Admin) + cfg, err := r.registry.GetUpkeepPrivilegeConfig(opts, upkeepId) if err != nil { return false, fmt.Errorf("failed to get upkeep privilege config for upkeep ID %s: %v", upkeepId, err) } @@ -203,7 +197,7 @@ func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int if err != nil { return false, fmt.Errorf("failed to unmarshal privilege config for upkeep ID %s: %v", upkeepId, err) } - r.mercury.allowListCache.Set(au.Admin.Hex(), a.MercuryEnabled, cache.DefaultExpiration) + r.mercury.allowListCache.Set(upkeepId.String(), a.MercuryEnabled, cache.DefaultExpiration) return a.MercuryEnabled, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index 6cb9381db69..da671e57836 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -77,7 +77,6 @@ func setupEVMRegistry(t *testing.T) *EvmRegistry { func TestEvmRegistry_FeedLookup(t *testing.T) { upkeepId, ok := new(big.Int).SetString("71022726777042968814359024671382968091267501884371696415772139504780367423725", 10) assert.True(t, ok, t.Name()) - admin := common.HexToAddress("0x6cA639822c6C241Fa9A7A6b5032F6F7F1C513CAD") tests := []struct { name string input []ocr2keepers.CheckResult @@ -228,17 +227,13 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { r := setupEVMRegistry(t) - r.active[upkeepId.String()] = activeUpkeep{ - ID: upkeepId, - Admin: admin, - } if !tt.cachedAdminCfg && !tt.hasError { mockRegistry := mocks.NewRegistry(t) cfg := AdminOffchainConfig{MercuryEnabled: tt.hasPermission} b, err := json.Marshal(cfg) assert.Nil(t, err) - mockRegistry.On("GetAdminPrivilegeConfig", mock.Anything, admin).Return(b, nil) + mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return(b, nil) r.registry = mockRegistry } @@ -322,7 +317,6 @@ func TestEvmRegistry_DecodeFeedLookup(t *testing.T) { func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { upkeepId, ok := new(big.Int).SetString("71022726777042968814359024671382968091267501884371696415772139504780367423725", 10) assert.True(t, ok, t.Name()) - admin := common.HexToAddress("0x6cA639822c6C241Fa9A7A6b5032F6F7F1C513CAD") tests := []struct { name string cached bool @@ -359,24 +353,20 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { r := setupEVMRegistry(t) - r.active[upkeepId.String()] = activeUpkeep{ - ID: upkeepId, - Admin: admin, - } if tt.errorMessage != "" { mockRegistry := mocks.NewRegistry(t) - mockRegistry.On("GetAdminPrivilegeConfig", mock.Anything, admin).Return([]byte{0, 1}, nil) + mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return([]byte{0, 1}, nil) r.registry = mockRegistry } else { if tt.cached { - r.mercury.allowListCache.Set(admin.Hex(), tt.allowed, cache.DefaultExpiration) + r.mercury.allowListCache.Set(upkeepId.String(), tt.allowed, cache.DefaultExpiration) } else { mockRegistry := mocks.NewRegistry(t) cfg := AdminOffchainConfig{MercuryEnabled: tt.allowed} b, err := json.Marshal(cfg) assert.Nil(t, err) - mockRegistry.On("GetAdminPrivilegeConfig", mock.Anything, admin).Return(b, nil) + mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return(b, nil) r.registry = mockRegistry } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/mocks/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/mocks/registry.go index 7e6f9fb5827..1827d4cb57f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/mocks/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/mocks/registry.go @@ -6,7 +6,6 @@ import ( big "math/big" bind "github.com/ethereum/go-ethereum/accounts/abi/bind" - common "github.com/ethereum/go-ethereum/common" generated "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated" @@ -74,32 +73,6 @@ func (_m *Registry) GetActiveUpkeepIDs(opts *bind.CallOpts, startIndex *big.Int, return r0, r1 } -// GetAdminPrivilegeConfig provides a mock function with given fields: opts, admin -func (_m *Registry) GetAdminPrivilegeConfig(opts *bind.CallOpts, admin common.Address) ([]byte, error) { - ret := _m.Called(opts, admin) - - var r0 []byte - var r1 error - if rf, ok := ret.Get(0).(func(*bind.CallOpts, common.Address) ([]byte, error)); ok { - return rf(opts, admin) - } - if rf, ok := ret.Get(0).(func(*bind.CallOpts, common.Address) []byte); ok { - r0 = rf(opts, admin) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]byte) - } - } - - if rf, ok := ret.Get(1).(func(*bind.CallOpts, common.Address) error); ok { - r1 = rf(opts, admin) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - // GetState provides a mock function with given fields: opts func (_m *Registry) GetState(opts *bind.CallOpts) (i_keeper_registry_master_wrapper_2_1.GetState, error) { ret := _m.Called(opts) @@ -148,6 +121,32 @@ func (_m *Registry) GetUpkeep(opts *bind.CallOpts, id *big.Int) (i_keeper_regist return r0, r1 } +// GetUpkeepPrivilegeConfig provides a mock function with given fields: opts, upkeepId +func (_m *Registry) GetUpkeepPrivilegeConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) { + ret := _m.Called(opts, upkeepId) + + var r0 []byte + var r1 error + if rf, ok := ret.Get(0).(func(*bind.CallOpts, *big.Int) ([]byte, error)); ok { + return rf(opts, upkeepId) + } + if rf, ok := ret.Get(0).(func(*bind.CallOpts, *big.Int) []byte); ok { + r0 = rf(opts, upkeepId) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]byte) + } + } + + if rf, ok := ret.Get(1).(func(*bind.CallOpts, *big.Int) error); ok { + r1 = rf(opts, upkeepId) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // GetUpkeepTriggerConfig provides a mock function with given fields: opts, upkeepId func (_m *Registry) GetUpkeepTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) { ret := _m.Called(opts, upkeepId) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index f910507612c..5082a1793dd 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -64,7 +64,7 @@ type Registry interface { GetUpkeep(opts *bind.CallOpts, id *big.Int) (UpkeepInfo, error) GetState(opts *bind.CallOpts) (iregistry21.GetState, error) GetActiveUpkeepIDs(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) - GetAdminPrivilegeConfig(opts *bind.CallOpts, admin common.Address) ([]byte, error) + GetUpkeepPrivilegeConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) GetUpkeepTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) CheckCallback(opts *bind.TransactOpts, id *big.Int, values [][]byte, extraData []byte) (*coreTypes.Transaction, error) ParseLog(log coreTypes.Log) (generated.AbigenLog, error) @@ -156,7 +156,6 @@ type activeUpkeep struct { ID *big.Int PerformGasLimit uint32 CheckData []byte - Admin common.Address } type MercuryConfig struct { @@ -860,7 +859,6 @@ func (r *EvmRegistry) getUpkeepConfigs(ctx context.Context, ids []*big.Int) ([]a ID: ids[i], PerformGasLimit: info.PerformGas, CheckData: info.CheckData, - Admin: info.Admin, } } } From ea5e408a56d1a18f9e993e2518df796df0e4ef8d Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Thu, 27 Jul 2023 17:20:46 -0700 Subject: [PATCH 023/270] [Function] Custom Transmitter (#9912) 1. Add a custom Transmitter that extracts coordinator contract address from report before each transmission. 2. Extend ABI codec and OCR protos to include coordinator contract addresses. 3. Aggregate metadata correctly during OCR processing. --- .../ocr2/plugins/functions/aggregation.go | 23 +- .../plugins/functions/aggregation_test.go | 42 ++-- .../ocr2/plugins/functions/config/config.go | 2 + .../plugins/functions/encoding/abi_codec.go | 153 ++++++++++-- .../functions/encoding/abi_codec_test.go | 41 +++- .../functions/encoding/ocr_types.pb.go | 41 +++- .../functions/encoding/ocr_types.proto | 2 + .../services/ocr2/plugins/functions/plugin.go | 7 +- .../ocr2/plugins/functions/reporting.go | 63 +++-- .../ocr2/plugins/functions/reporting_test.go | 130 ++++++++-- .../relay/evm/contract_transmitter_test.go | 2 +- core/services/relay/evm/functions.go | 80 +++++- .../evm/functions/contract_transmitter.go | 232 ++++++++++++++++++ .../functions/contract_transmitter_test.go | 118 +++++++++ 14 files changed, 824 insertions(+), 112 deletions(-) create mode 100644 core/services/relay/evm/functions/contract_transmitter.go create mode 100644 core/services/relay/evm/functions/contract_transmitter_test.go diff --git a/core/services/ocr2/plugins/functions/aggregation.go b/core/services/ocr2/plugins/functions/aggregation.go index 6989e68b62d..32a2509e70e 100644 --- a/core/services/ocr2/plugins/functions/aggregation.go +++ b/core/services/ocr2/plugins/functions/aggregation.go @@ -50,8 +50,8 @@ func Aggregate(aggMethod config.AggregationMethod, observations []*encoding.Proc rawData = append(rawData, item.Result) } } - // Metadata (currently only callbackGas) is aggregated using MODE method - finalResult.CallbackGasLimit = aggregateMetadata(toAggregate) + // Metadata (CallbackGasLimit, CoordinatorContract and OnchainMetadata) is aggregated using MODE method + finalResult.CallbackGasLimit, finalResult.CoordinatorContract, finalResult.OnchainMetadata = aggregateMetadata(toAggregate) if resultIsError { // Errors are always aggregated using MODE method finalResult.Error = aggregateMode(rawData) @@ -68,14 +68,27 @@ func Aggregate(aggMethod config.AggregationMethod, observations []*encoding.Proc return &finalResult, nil } -func aggregateMetadata(items []*encoding.ProcessedRequest) (callbackGasLimit uint32) { +func aggregateMetadata(items []*encoding.ProcessedRequest) (uint32, []byte, []byte) { gasLimitBytes := make([][]byte, len(items)) + coordinatorContracts := make([][]byte, len(items)) + onchainMetadata := make([][]byte, len(items)) for i, item := range items { gasLimitBytes[i] = make([]byte, 4) binary.BigEndian.PutUint32(gasLimitBytes[i], item.CallbackGasLimit) + coordinatorContracts[i] = item.CoordinatorContract + if coordinatorContracts[i] == nil { + coordinatorContracts[i] = []byte{} + } + onchainMetadata[i] = item.OnchainMetadata + if onchainMetadata[i] == nil { + onchainMetadata[i] = []byte{} + } } - aggregated := aggregateMode(gasLimitBytes) - return binary.BigEndian.Uint32(aggregated) + aggGasLimitBytes := aggregateMode(gasLimitBytes) + aggGasLimitUint32 := binary.BigEndian.Uint32(aggGasLimitBytes) + aggCoordinatorContract := aggregateMode(coordinatorContracts) + aggOnchainMetadata := aggregateMode(onchainMetadata) + return aggGasLimitUint32, aggCoordinatorContract, aggOnchainMetadata } func aggregateMode(items [][]byte) []byte { diff --git a/core/services/ocr2/plugins/functions/aggregation_test.go b/core/services/ocr2/plugins/functions/aggregation_test.go index c6ce2ecc8e1..8a39a9b6561 100644 --- a/core/services/ocr2/plugins/functions/aggregation_test.go +++ b/core/services/ocr2/plugins/functions/aggregation_test.go @@ -13,10 +13,12 @@ import ( func req(id int, result []byte, err []byte) *encoding.ProcessedRequest { return &encoding.ProcessedRequest{ - RequestID: []byte(strconv.Itoa(id)), - Result: result, - Error: err, - CallbackGasLimit: 0, + RequestID: []byte(strconv.Itoa(id)), + Result: result, + Error: err, + CallbackGasLimit: 0, + CoordinatorContract: []byte{}, + OnchainMetadata: []byte{}, } } @@ -24,12 +26,14 @@ func reqS(id int, result string, err string) *encoding.ProcessedRequest { return req(id, []byte(result), []byte(err)) } -func reqMeta(id int, result []byte, err []byte, callbackGas uint32) *encoding.ProcessedRequest { +func reqMeta(id int, result []byte, err []byte, callbackGas uint32, coordinatorContract []byte, onchainMeta []byte) *encoding.ProcessedRequest { return &encoding.ProcessedRequest{ - RequestID: []byte(strconv.Itoa(id)), - Result: result, - Error: err, - CallbackGasLimit: callbackGas, + RequestID: []byte(strconv.Itoa(id)), + Result: result, + Error: err, + CallbackGasLimit: callbackGas, + CoordinatorContract: coordinatorContract, + OnchainMetadata: onchainMeta, } } @@ -117,23 +121,23 @@ func TestAggregate_Successful(t *testing.T) { "Metadata With Results", config.AggregationMethod_AGGREGATION_MEDIAN, []*encoding.ProcessedRequest{ - reqMeta(21, []byte{1}, []byte{}, 100), - reqMeta(21, []byte{1}, []byte{}, 90), - reqMeta(21, []byte{1}, []byte{}, 100), - reqMeta(21, []byte{1}, []byte{}, 100), + reqMeta(21, []byte{1}, []byte{}, 100, []byte{2}, []byte{4}), + reqMeta(21, []byte{1}, []byte{}, 90, []byte{2}, []byte{4}), + reqMeta(21, []byte{1}, []byte{}, 100, []byte{0}, []byte{4}), + reqMeta(21, []byte{1}, []byte{}, 100, []byte{2}, []byte{1}), }, - reqMeta(21, []byte{1}, []byte{}, 100), + reqMeta(21, []byte{1}, []byte{}, 100, []byte{2}, []byte{4}), }, { "Metadata With Errors", config.AggregationMethod_AGGREGATION_MEDIAN, []*encoding.ProcessedRequest{ - reqMeta(21, []byte{}, []byte{2}, 90), - reqMeta(21, []byte{}, []byte{2}, 100), - reqMeta(21, []byte{}, []byte{2}, 100), - reqMeta(21, []byte{}, []byte{2}, 100), + reqMeta(21, []byte{}, []byte{2}, 90, []byte{0}, []byte{4}), + reqMeta(21, []byte{}, []byte{2}, 100, []byte{2}, []byte{4}), + reqMeta(21, []byte{}, []byte{2}, 100, []byte{2}, []byte{1}), + reqMeta(21, []byte{}, []byte{2}, 100, []byte{2}, []byte{4}), }, - reqMeta(21, []byte{}, []byte{2}, 100), + reqMeta(21, []byte{}, []byte{2}, 100, []byte{2}, []byte{4}), }, } diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index 16eaf4e6312..ae59ffc574e 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -19,6 +19,8 @@ import ( // This config is part of the job spec and is loaded only once on node boot/job creation. type PluginConfig struct { + DONId string `json:"donId"` + ContractVersion uint32 `json:"contractVersion"` MinIncomingConfirmations uint32 `json:"minIncomingConfirmations"` RequestTimeoutSec uint32 `json:"requestTimeoutSec"` RequestTimeoutCheckFrequencySec uint32 `json:"requestTimeoutCheckFrequencySec"` diff --git a/core/services/ocr2/plugins/functions/encoding/abi_codec.go b/core/services/ocr2/plugins/functions/encoding/abi_codec.go index 1668eefa6ce..e7f62605db9 100644 --- a/core/services/ocr2/plugins/functions/encoding/abi_codec.go +++ b/core/services/ocr2/plugins/functions/encoding/abi_codec.go @@ -7,11 +7,48 @@ import ( "github.com/pkg/errors" ) -type ReportCodec struct { +type ReportCodec interface { + EncodeReport(requests []*ProcessedRequest) ([]byte, error) + DecodeReport(raw []byte) ([]*ProcessedRequest, error) +} + +type reportCodecV0 struct { reportTypes abi.Arguments } -func getReportTypes() (abi.Arguments, error) { +type reportCodecV1 struct { + reportTypes abi.Arguments +} + +func NewReportCodec(contractVersion uint32) (ReportCodec, error) { + switch contractVersion { + case 0: // deprecated + reportTypes, err := getReportTypesV0() + if err != nil { + return nil, err + } + return &reportCodecV0{reportTypes: reportTypes}, nil + case 1: + reportTypes, err := getReportTypesV1() + if err != nil { + return nil, err + } + return &reportCodecV1{reportTypes: reportTypes}, nil + default: + return nil, fmt.Errorf("unknown contract version: %d", contractVersion) + } +} + +func SliceToByte32(slice []byte) ([32]byte, error) { + if len(slice) != 32 { + return [32]byte{}, fmt.Errorf("input length is not 32 bytes: %d", len(slice)) + } + var res [32]byte + copy(res[:], slice[:32]) + return res, nil +} + +func getReportTypesV0() (abi.Arguments, error) { bytes32ArrType, err := abi.NewType("bytes32[]", "", []abi.ArgumentMarshaling{}) if err != nil { return nil, fmt.Errorf("unable to create an ABI type object for bytes32[]") @@ -27,26 +64,7 @@ func getReportTypes() (abi.Arguments, error) { }), nil } -func NewReportCodec() (*ReportCodec, error) { - reportTypes, err := getReportTypes() - if err != nil { - return nil, err - } - return &ReportCodec{ - reportTypes: reportTypes, - }, nil -} - -func SliceToByte32(slice []byte) ([32]byte, error) { - if len(slice) != 32 { - return [32]byte{}, fmt.Errorf("input length is not 32 bytes: %d", len(slice)) - } - var res [32]byte - copy(res[:], slice[:32]) - return res, nil -} - -func (c *ReportCodec) EncodeReport(requests []*ProcessedRequest) ([]byte, error) { +func (c *reportCodecV0) EncodeReport(requests []*ProcessedRequest) ([]byte, error) { size := len(requests) if size == 0 { return []byte{}, nil @@ -66,7 +84,7 @@ func (c *ReportCodec) EncodeReport(requests []*ProcessedRequest) ([]byte, error) return c.reportTypes.Pack(ids, results, errors) } -func (c *ReportCodec) DecodeReport(raw []byte) ([]*ProcessedRequest, error) { +func (c *reportCodecV0) DecodeReport(raw []byte) ([]*ProcessedRequest, error) { reportElems := map[string]interface{}{} if err := c.reportTypes.UnpackIntoMap(reportElems, raw); err != nil { return nil, errors.WithMessage(err, "unable to unpack elements from raw report") @@ -104,3 +122,92 @@ func (c *ReportCodec) DecodeReport(raw []byte) ([]*ProcessedRequest, error) { } return decoded, nil } + +func getReportTypesV1() (abi.Arguments, error) { + bytes32ArrType, err := abi.NewType("bytes32[]", "", []abi.ArgumentMarshaling{}) + if err != nil { + return nil, fmt.Errorf("unable to create an ABI type object for bytes32[]") + } + bytesArrType, err := abi.NewType("bytes[]", "", []abi.ArgumentMarshaling{}) + if err != nil { + return nil, fmt.Errorf("unable to create an ABI type object for bytes[]") + } + return abi.Arguments([]abi.Argument{ + {Name: "ids", Type: bytes32ArrType}, + {Name: "results", Type: bytesArrType}, + {Name: "errors", Type: bytesArrType}, + {Name: "onchain_metadata", Type: bytesArrType}, + {Name: "processing_metadata", Type: bytesArrType}, + }), nil +} + +func (c *reportCodecV1) EncodeReport(requests []*ProcessedRequest) ([]byte, error) { + size := len(requests) + if size == 0 { + return []byte{}, nil + } + ids := make([][32]byte, size) + results := make([][]byte, size) + errors := make([][]byte, size) + onchainMetadata := make([][]byte, size) + processingMetadata := make([][]byte, size) + for i := 0; i < size; i++ { + var err error + ids[i], err = SliceToByte32(requests[i].RequestID) + if err != nil { + return nil, err + } + results[i] = requests[i].Result + errors[i] = requests[i].Error + onchainMetadata[i] = requests[i].OnchainMetadata + processingMetadata[i] = requests[i].CoordinatorContract + // CallbackGasLimit is not ABI-encoded + } + return c.reportTypes.Pack(ids, results, errors, onchainMetadata, processingMetadata) +} + +func (c *reportCodecV1) DecodeReport(raw []byte) ([]*ProcessedRequest, error) { + reportElems := map[string]interface{}{} + if err := c.reportTypes.UnpackIntoMap(reportElems, raw); err != nil { + return nil, errors.WithMessage(err, "unable to unpack elements from raw report") + } + + idsIface, idsOK := reportElems["ids"] + resultsIface, resultsOK := reportElems["results"] + errorsIface, errorsOK := reportElems["errors"] + onchainMetaIface, onchainMetaOK := reportElems["onchain_metadata"] + processingMetaIface, processingMetaOK := reportElems["processing_metadata"] + if !idsOK || !resultsOK || !errorsOK || !onchainMetaOK || !processingMetaOK { + return nil, fmt.Errorf("missing arrays in raw report, ids: %v, results: %v, errors: %v", idsOK, resultsOK, errorsOK) + } + + ids, idsOK := idsIface.([][32]byte) + results, resultsOK := resultsIface.([][]byte) + errors, errorsOK := errorsIface.([][]byte) + onchainMeta, onchainMetaOK := onchainMetaIface.([][]byte) + processingMeta, processingMetaOK := processingMetaIface.([][]byte) + if !idsOK || !resultsOK || !errorsOK || !onchainMetaOK || !processingMetaOK { + return nil, fmt.Errorf("unable to cast part of raw report into array type, ids: %v, results: %v, errors: %v", idsOK, resultsOK, errorsOK) + } + + size := len(ids) + if len(results) != size || len(errors) != size || len(onchainMeta) != size || len(processingMeta) != size { + return nil, fmt.Errorf("unequal sizes of arrays parsed from raw report, ids: %v, results: %v, errors: %v", len(ids), len(results), len(errors)) + } + if size == 0 { + return []*ProcessedRequest{}, nil + } + + decoded := make([]*ProcessedRequest, size) + for i := 0; i < size; i++ { + decoded[i] = &ProcessedRequest{ + RequestID: ids[i][:], + Result: results[i], + Error: errors[i], + OnchainMetadata: onchainMeta[i], + CoordinatorContract: processingMeta[i], + // CallbackGasLimit is not ABI-encoded + } + } + return decoded, nil +} diff --git a/core/services/ocr2/plugins/functions/encoding/abi_codec_test.go b/core/services/ocr2/plugins/functions/encoding/abi_codec_test.go index f15dfe9a814..03c8b87af16 100644 --- a/core/services/ocr2/plugins/functions/encoding/abi_codec_test.go +++ b/core/services/ocr2/plugins/functions/encoding/abi_codec_test.go @@ -9,9 +9,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/encoding" ) -func TestABICodec_EncodeDecodeSuccess(t *testing.T) { +func TestABICodec_EncodeDecodeV0Success(t *testing.T) { t.Parallel() - codec, err := encoding.NewReportCodec() + codec, err := encoding.NewReportCodec(0) require.NoError(t, err) var report = []*encoding.ProcessedRequest{ @@ -40,6 +40,43 @@ func TestABICodec_EncodeDecodeSuccess(t *testing.T) { } } +func TestABICodec_EncodeDecodeV1Success(t *testing.T) { + t.Parallel() + codec, err := encoding.NewReportCodec(1) + require.NoError(t, err) + + var report = []*encoding.ProcessedRequest{ + { + RequestID: []byte(fmt.Sprintf("%032d", 123)), + Result: []byte("abcd"), + Error: []byte("err string"), + CoordinatorContract: []byte("contract_1"), + OnchainMetadata: []byte("commitment_1"), + }, + { + RequestID: []byte(fmt.Sprintf("%032d", 4321)), + Result: []byte("0xababababab"), + Error: []byte(""), + CoordinatorContract: []byte("contract_2"), + OnchainMetadata: []byte("commitment_2"), + }, + } + + encoded, err := codec.EncodeReport(report) + require.NoError(t, err) + decoded, err := codec.DecodeReport(encoded) + require.NoError(t, err) + + require.Equal(t, len(report), len(decoded)) + for i := 0; i < len(report); i++ { + require.Equal(t, report[i].RequestID, decoded[i].RequestID, "RequestIDs not equal at index %d", i) + require.Equal(t, report[i].Result, decoded[i].Result, "Results not equal at index %d", i) + require.Equal(t, report[i].Error, decoded[i].Error, "Errors not equal at index %d", i) + require.Equal(t, report[i].CoordinatorContract, decoded[i].CoordinatorContract, "Contracts not equal at index %d", i) + require.Equal(t, report[i].OnchainMetadata, decoded[i].OnchainMetadata, "Metadata not equal at index %d", i) + } +} + func TestABICodec_SliceToByte32(t *testing.T) { t.Parallel() diff --git a/core/services/ocr2/plugins/functions/encoding/ocr_types.pb.go b/core/services/ocr2/plugins/functions/encoding/ocr_types.pb.go index 58808bd5756..4022076334b 100644 --- a/core/services/ocr2/plugins/functions/encoding/ocr_types.pb.go +++ b/core/services/ocr2/plugins/functions/encoding/ocr_types.pb.go @@ -121,10 +121,12 @@ type ProcessedRequest struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - RequestID []byte `protobuf:"bytes,1,opt,name=requestID,proto3" json:"requestID,omitempty"` - Result []byte `protobuf:"bytes,2,opt,name=result,proto3" json:"result,omitempty"` - Error []byte `protobuf:"bytes,3,opt,name=error,proto3" json:"error,omitempty"` - CallbackGasLimit uint32 `protobuf:"varint,4,opt,name=callbackGasLimit,proto3" json:"callbackGasLimit,omitempty"` + RequestID []byte `protobuf:"bytes,1,opt,name=requestID,proto3" json:"requestID,omitempty"` + Result []byte `protobuf:"bytes,2,opt,name=result,proto3" json:"result,omitempty"` + Error []byte `protobuf:"bytes,3,opt,name=error,proto3" json:"error,omitempty"` + CallbackGasLimit uint32 `protobuf:"varint,4,opt,name=callbackGasLimit,proto3" json:"callbackGasLimit,omitempty"` + CoordinatorContract []byte `protobuf:"bytes,5,opt,name=coordinatorContract,proto3" json:"coordinatorContract,omitempty"` + OnchainMetadata []byte `protobuf:"bytes,6,opt,name=onchainMetadata,proto3" json:"onchainMetadata,omitempty"` } func (x *ProcessedRequest) Reset() { @@ -187,6 +189,20 @@ func (x *ProcessedRequest) GetCallbackGasLimit() uint32 { return 0 } +func (x *ProcessedRequest) GetCoordinatorContract() []byte { + if x != nil { + return x.CoordinatorContract + } + return nil +} + +func (x *ProcessedRequest) GetOnchainMetadata() []byte { + if x != nil { + return x.OnchainMetadata + } + return nil +} + var File_core_services_ocr2_plugins_functions_encoding_ocr_types_proto protoreflect.FileDescriptor var file_core_services_ocr2_plugins_functions_encoding_ocr_types_proto_rawDesc = []byte{ @@ -202,7 +218,7 @@ var file_core_services_ocr2_plugins_functions_encoding_ocr_types_proto_rawDesc = 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x2e, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x52, 0x11, 0x70, 0x72, 0x6f, 0x63, 0x65, 0x73, - 0x73, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x22, 0x8a, 0x01, 0x0a, 0x10, + 0x73, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x22, 0xe6, 0x01, 0x0a, 0x10, 0x50, 0x72, 0x6f, 0x63, 0x65, 0x73, 0x73, 0x65, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x1c, 0x0a, 0x09, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x49, 0x44, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x49, 0x44, 0x12, 0x16, @@ -211,11 +227,16 @@ var file_core_services_ocr2_plugins_functions_encoding_ocr_types_proto_rawDesc = 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x65, 0x72, 0x72, 0x6f, 0x72, 0x12, 0x2a, 0x0a, 0x10, 0x63, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x10, 0x63, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, - 0x47, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x42, 0x2f, 0x5a, 0x2d, 0x63, 0x6f, 0x72, 0x65, - 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2f, 0x6f, 0x63, 0x72, 0x32, 0x2f, 0x70, - 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x2f, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, - 0x2f, 0x65, 0x6e, 0x63, 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x47, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x30, 0x0a, 0x13, 0x63, 0x6f, 0x6f, 0x72, + 0x64, 0x69, 0x6e, 0x61, 0x74, 0x6f, 0x72, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x18, + 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x13, 0x63, 0x6f, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x74, + 0x6f, 0x72, 0x43, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, 0x12, 0x28, 0x0a, 0x0f, 0x6f, 0x6e, + 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4d, 0x65, 0x74, 0x61, 0x64, 0x61, 0x74, 0x61, 0x18, 0x06, 0x20, + 0x01, 0x28, 0x0c, 0x52, 0x0f, 0x6f, 0x6e, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x4d, 0x65, 0x74, 0x61, + 0x64, 0x61, 0x74, 0x61, 0x42, 0x2f, 0x5a, 0x2d, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, + 0x76, 0x69, 0x63, 0x65, 0x73, 0x2f, 0x6f, 0x63, 0x72, 0x32, 0x2f, 0x70, 0x6c, 0x75, 0x67, 0x69, + 0x6e, 0x73, 0x2f, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, 0x65, 0x6e, 0x63, + 0x6f, 0x64, 0x69, 0x6e, 0x67, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/core/services/ocr2/plugins/functions/encoding/ocr_types.proto b/core/services/ocr2/plugins/functions/encoding/ocr_types.proto index 4495366c526..a546f0f1b00 100644 --- a/core/services/ocr2/plugins/functions/encoding/ocr_types.proto +++ b/core/services/ocr2/plugins/functions/encoding/ocr_types.proto @@ -19,4 +19,6 @@ message ProcessedRequest { bytes result = 2; bytes error = 3; uint32 callbackGasLimit = 4; + bytes coordinatorContract = 5; + bytes onchainMetadata = 6; } diff --git a/core/services/ocr2/plugins/functions/plugin.go b/core/services/ocr2/plugins/functions/plugin.go index cdb0f0111c9..3fedd7a1687 100644 --- a/core/services/ocr2/plugins/functions/plugin.go +++ b/core/services/ocr2/plugins/functions/plugin.go @@ -121,9 +121,10 @@ func NewFunctionsServices(functionsOracleArgs, thresholdOracleArgs, s4OracleArgs allServices = append(allServices, functionsListener) functionsOracleArgs.ReportingPluginFactory = FunctionsReportingPluginFactory{ - Logger: functionsOracleArgs.Logger, - PluginORM: pluginORM, - JobID: conf.Job.ExternalJobID, + Logger: functionsOracleArgs.Logger, + PluginORM: pluginORM, + JobID: conf.Job.ExternalJobID, + ContractVersion: pluginConfig.ContractVersion, } functionsReportingPluginOracle, err := libocr2.NewOracle(*functionsOracleArgs) if err != nil { diff --git a/core/services/ocr2/plugins/functions/reporting.go b/core/services/ocr2/plugins/functions/reporting.go index 2246cff4ba0..7f532439c6a 100644 --- a/core/services/ocr2/plugins/functions/reporting.go +++ b/core/services/ocr2/plugins/functions/reporting.go @@ -19,20 +19,22 @@ import ( ) type FunctionsReportingPluginFactory struct { - Logger commontypes.Logger - PluginORM functions.ORM - JobID uuid.UUID + Logger commontypes.Logger + PluginORM functions.ORM + JobID uuid.UUID + ContractVersion uint32 } var _ types.ReportingPluginFactory = (*FunctionsReportingPluginFactory)(nil) type functionsReporting struct { - logger commontypes.Logger - pluginORM functions.ORM - jobID uuid.UUID - reportCodec *encoding.ReportCodec - genericConfig *types.ReportingPluginConfig - specificConfig *config.ReportingPluginConfigWrapper + logger commontypes.Logger + pluginORM functions.ORM + jobID uuid.UUID + reportCodec encoding.ReportCodec + genericConfig *types.ReportingPluginConfig + specificConfig *config.ReportingPluginConfigWrapper + contractVersion uint32 } var _ types.ReportingPlugin = &functionsReporting{} @@ -88,7 +90,7 @@ func (f FunctionsReportingPluginFactory) NewReportingPlugin(rpConfig types.Repor }) return nil, types.ReportingPluginInfo{}, err } - codec, err := encoding.NewReportCodec() + codec, err := encoding.NewReportCodec(f.ContractVersion) if err != nil { f.Logger.Error("unable to create a report codec object", commontypes.LogFields{}) return nil, types.ReportingPluginInfo{}, err @@ -103,12 +105,13 @@ func (f FunctionsReportingPluginFactory) NewReportingPlugin(rpConfig types.Repor }, } plugin := functionsReporting{ - logger: f.Logger, - pluginORM: f.PluginORM, - jobID: f.JobID, - reportCodec: codec, - genericConfig: &rpConfig, - specificConfig: pluginConfig, + logger: f.Logger, + pluginORM: f.PluginORM, + jobID: f.JobID, + reportCodec: codec, + genericConfig: &rpConfig, + specificConfig: pluginConfig, + contractVersion: f.ContractVersion, } promReportingPlugins.WithLabelValues(f.JobID.String()).Inc() return &plugin, info, nil @@ -193,12 +196,20 @@ func (r *functionsReporting) Observation(ctx context.Context, ts types.ReportTim // NOTE: ignoring TIMED_OUT requests, which potentially had ready results if localResult.State == functions.RESULT_READY { resultProto := encoding.ProcessedRequest{ - RequestID: localResult.RequestID[:], - Result: localResult.Result, - Error: localResult.Error, + RequestID: localResult.RequestID[:], + Result: localResult.Result, + Error: localResult.Error, + OnchainMetadata: localResult.OnchainMetadata, } - if localResult.CallbackGasLimit != nil { + if r.contractVersion == 1 { + if localResult.CallbackGasLimit == nil || localResult.CoordinatorContractAddress == nil { + r.logger.Error("FunctionsReporting Observation missing required v1 fields", commontypes.LogFields{ + "requestID": formatRequestId(id[:]), + }) + continue + } resultProto.CallbackGasLimit = *localResult.CallbackGasLimit + resultProto.CoordinatorContract = localResult.CoordinatorContractAddress[:] } observationProto.ProcessedRequests = append(observationProto.ProcessedRequests, &resultProto) idStrs = append(idStrs, formatRequestId(localResult.RequestID[:])) @@ -428,12 +439,12 @@ func (r *functionsReporting) ShouldTransmitAcceptedReport(ctx context.Context, t needTransmissionIds = append(needTransmissionIds, reqIdStr) continue } - if request.State == functions.TIMED_OUT || request.State == functions.CONFIRMED { - r.logger.Debug("FunctionsReporting ShouldTransmitAcceptedReport: request is not FINALIZED any more. Not transmitting.", - commontypes.LogFields{ - "requestID": reqIdStr, - "state": request.State.String(), - }) + if request.State == functions.CONFIRMED { + r.logger.Debug("FunctionsReporting ShouldTransmitAcceptedReport: request already CONFIRMED. Not transmitting.", commontypes.LogFields{"requestID": reqIdStr}) + continue + } + if request.State == functions.TIMED_OUT { + r.logger.Debug("FunctionsReporting ShouldTransmitAcceptedReport: request already TIMED_OUT. Not transmitting.", commontypes.LogFields{"requestID": reqIdStr}) continue } if request.State == functions.IN_PROGRESS || request.State == functions.RESULT_READY { diff --git a/core/services/ocr2/plugins/functions/reporting_test.go b/core/services/ocr2/plugins/functions/reporting_test.go index bb0a5239375..e08a0aca7a0 100644 --- a/core/services/ocr2/plugins/functions/reporting_test.go +++ b/core/services/ocr2/plugins/functions/reporting_test.go @@ -4,6 +4,7 @@ import ( "errors" "testing" + "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" "google.golang.org/protobuf/proto" @@ -21,18 +22,20 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/encoding" ) -func preparePlugin(t *testing.T, batchSize uint32) (types.ReportingPlugin, *functions_mocks.ORM, *encoding.ReportCodec) { +func preparePlugin(t *testing.T, batchSize uint32, contractVersion uint32, maxTotalGasLimit uint32) (types.ReportingPlugin, *functions_mocks.ORM, encoding.ReportCodec) { lggr := logger.TestLogger(t) ocrLogger := relaylogger.NewOCRWrapper(lggr, true, func(msg string) {}) orm := functions_mocks.NewORM(t) factory := functions.FunctionsReportingPluginFactory{ - Logger: ocrLogger, - PluginORM: orm, + Logger: ocrLogger, + PluginORM: orm, + ContractVersion: contractVersion, } pluginConfig := config.ReportingPluginConfigWrapper{ Config: &config.ReportingPluginConfig{ - MaxRequestBatchSize: batchSize, + MaxRequestBatchSize: batchSize, + MaxReportTotalCallbackGas: maxTotalGasLimit, }, } pluginConfigBytes, err := config.EncodeReportingPluginConfig(&pluginConfig) @@ -43,7 +46,7 @@ func preparePlugin(t *testing.T, batchSize uint32) (types.ReportingPlugin, *func OffchainConfig: pluginConfigBytes, }) require.NoError(t, err) - codec, err := encoding.NewReportCodec() + codec, err := encoding.NewReportCodec(contractVersion) require.NoError(t, err) return plugin, orm, codec } @@ -92,6 +95,17 @@ func newProcessedRequest(requestId functions_srv.RequestID, compResult []byte, c } } +func newProcessedRequestWithMeta(requestId functions_srv.RequestID, compResult []byte, compError []byte, callbackGasLimit uint32, coordinatorContract []byte, onchainMetadata []byte) *encoding.ProcessedRequest { + return &encoding.ProcessedRequest{ + RequestID: requestId[:], + Result: compResult, + Error: compError, + CallbackGasLimit: callbackGasLimit, + CoordinatorContract: coordinatorContract, + OnchainMetadata: onchainMetadata, + } +} + func newObservation(t *testing.T, observerId uint8, requests ...*encoding.ProcessedRequest) types.AttributedObservation { observationProto := encoding.Observation{ProcessedRequests: requests} raw, err := proto.Marshal(&observationProto) @@ -102,10 +116,10 @@ func newObservation(t *testing.T, observerId uint8, requests ...*encoding.Proces } } -func TestDRReporting_Query(t *testing.T) { +func TestFunctionsReporting_Query(t *testing.T) { t.Parallel() const batchSize = 10 - plugin, orm, _ := preparePlugin(t, batchSize) + plugin, orm, _ := preparePlugin(t, batchSize, 0, 0) reqs := []functions_srv.Request{newRequest(), newRequest()} orm.On("FindOldestEntriesByState", functions_srv.RESULT_READY, uint32(batchSize), mock.Anything).Return(reqs, nil) @@ -120,9 +134,9 @@ func TestDRReporting_Query(t *testing.T) { require.Equal(t, reqs[1].RequestID[:], queryProto.RequestIDs[1]) } -func TestDRReporting_Observation(t *testing.T) { +func TestFunctionsReporting_Observation(t *testing.T) { t.Parallel() - plugin, orm, _ := preparePlugin(t, 10) + plugin, orm, _ := preparePlugin(t, 10, 0, 0) req1 := newRequestWithResult([]byte("abc")) req2 := newRequest() @@ -155,9 +169,9 @@ func TestDRReporting_Observation(t *testing.T) { require.Equal(t, observationProto.ProcessedRequests[1].Result, []byte("def")) } -func TestDRReporting_Observation_IncorrectQuery(t *testing.T) { +func TestFunctionsReporting_Observation_IncorrectQuery(t *testing.T) { t.Parallel() - plugin, orm, _ := preparePlugin(t, 10) + plugin, orm, _ := preparePlugin(t, 10, 0, 0) req1 := newRequestWithResult([]byte("abc")) invalidId := []byte("invalid") @@ -182,9 +196,9 @@ func TestDRReporting_Observation_IncorrectQuery(t *testing.T) { require.Equal(t, observationProto.ProcessedRequests[0].Result, []byte("abc")) } -func TestDRReporting_Report(t *testing.T) { +func TestFunctionsReporting_Report(t *testing.T) { t.Parallel() - plugin, _, codec := preparePlugin(t, 10) + plugin, _, codec := preparePlugin(t, 10, 0, 0) reqId1, reqId2, reqId3 := newRequestID(), newRequestID(), newRequestID() compResult := []byte("aaa") procReq1 := newProcessedRequest(reqId1, compResult, []byte{}) @@ -219,9 +233,81 @@ func TestDRReporting_Report(t *testing.T) { require.Equal(t, []byte{}, decoded[1].Error) } -func TestDRReporting_Report_DeterministicOrderOfRequests(t *testing.T) { +func TestFunctionsReporting_Report_WithGasLimitAndMetadata(t *testing.T) { + t.Parallel() + plugin, _, codec := preparePlugin(t, 10, 1, 300000) + reqId1, reqId2, reqId3 := newRequestID(), newRequestID(), newRequestID() + compResult := []byte("aaa") + gasLimit1, gasLimit2 := uint32(100_000), uint32(200_000) + coordinatorContract1, coordinatorContract2 := common.Address{1}, common.Address{2} + meta1, meta2 := []byte("meta1"), []byte("meta2") + procReq1 := newProcessedRequestWithMeta(reqId1, compResult, []byte{}, gasLimit1, coordinatorContract1[:], meta1) + procReq2 := newProcessedRequestWithMeta(reqId2, compResult, []byte{}, gasLimit2, coordinatorContract2[:], meta2) + + query := newMarshalledQuery(t, reqId1, reqId2, reqId3, reqId1, reqId2) // duplicates should be ignored + obs := []types.AttributedObservation{ + newObservation(t, 1, procReq2, procReq1), + newObservation(t, 2, procReq1, procReq2), + newObservation(t, 3, procReq1, procReq2), + } + + produced, reportBytes, err := plugin.Report(testutils.Context(t), types.ReportTimestamp{}, query, obs) + require.True(t, produced) + require.NoError(t, err) + + decoded, err := codec.DecodeReport(reportBytes) + require.NoError(t, err) + require.Equal(t, 2, len(decoded)) + + require.Equal(t, reqId1[:], decoded[0].RequestID) + require.Equal(t, compResult, decoded[0].Result) + require.Equal(t, []byte{}, decoded[0].Error) + require.Equal(t, coordinatorContract1[:], decoded[0].CoordinatorContract) + require.Equal(t, meta1, decoded[0].OnchainMetadata) + // CallbackGasLimit is not ABI-encoded + + require.Equal(t, reqId2[:], decoded[1].RequestID) + require.Equal(t, compResult, decoded[1].Result) + require.Equal(t, []byte{}, decoded[1].Error) + require.Equal(t, coordinatorContract2[:], decoded[1].CoordinatorContract) + require.Equal(t, meta2, decoded[1].OnchainMetadata) + // CallbackGasLimit is not ABI-encoded +} + +func TestFunctionsReporting_Report_CallbackGasLimitExceeded(t *testing.T) { + t.Parallel() + plugin, _, codec := preparePlugin(t, 10, 1, 200000) + reqId1, reqId2 := newRequestID(), newRequestID() + compResult := []byte("aaa") + gasLimit1, gasLimit2 := uint32(100_000), uint32(200_000) + coordinatorContract1, coordinatorContract2 := common.Address{1}, common.Address{2} + procReq1 := newProcessedRequestWithMeta(reqId1, compResult, []byte{}, gasLimit1, coordinatorContract1[:], []byte{}) + procReq2 := newProcessedRequestWithMeta(reqId2, compResult, []byte{}, gasLimit2, coordinatorContract2[:], []byte{}) + + query := newMarshalledQuery(t, reqId1, reqId2) + obs := []types.AttributedObservation{ + newObservation(t, 1, procReq2, procReq1), + newObservation(t, 2, procReq1, procReq2), + newObservation(t, 3, procReq1, procReq2), + } + + produced, reportBytes, err := plugin.Report(testutils.Context(t), types.ReportTimestamp{}, query, obs) + require.True(t, produced) + require.NoError(t, err) + + decoded, err := codec.DecodeReport(reportBytes) + require.NoError(t, err) + // Gas limit is set to 200k per report so we can only fit the first request + require.Equal(t, 1, len(decoded)) + require.Equal(t, reqId1[:], decoded[0].RequestID) + require.Equal(t, compResult, decoded[0].Result) + require.Equal(t, []byte{}, decoded[0].Error) + require.Equal(t, coordinatorContract1[:], decoded[0].CoordinatorContract) +} + +func TestFunctionsReporting_Report_DeterministicOrderOfRequests(t *testing.T) { t.Parallel() - plugin, _, codec := preparePlugin(t, 10) + plugin, _, codec := preparePlugin(t, 10, 0, 0) reqId1, reqId2, reqId3 := newRequestID(), newRequestID(), newRequestID() compResult := []byte("aaa") @@ -248,9 +334,9 @@ func TestDRReporting_Report_DeterministicOrderOfRequests(t *testing.T) { require.Equal(t, 3, len(decoded)) } -func TestDRReporting_Report_IncorrectObservation(t *testing.T) { +func TestFunctionsReporting_Report_IncorrectObservation(t *testing.T) { t.Parallel() - plugin, _, _ := preparePlugin(t, 10) + plugin, _, _ := preparePlugin(t, 10, 0, 0) reqId1 := newRequestID() compResult := []byte("aaa") @@ -265,7 +351,7 @@ func TestDRReporting_Report_IncorrectObservation(t *testing.T) { require.NoError(t, err) } -func getReportBytes(t *testing.T, codec *encoding.ReportCodec, reqs ...functions_srv.Request) []byte { +func getReportBytes(t *testing.T, codec encoding.ReportCodec, reqs ...functions_srv.Request) []byte { var report []*encoding.ProcessedRequest for _, req := range reqs { req := req @@ -276,9 +362,9 @@ func getReportBytes(t *testing.T, codec *encoding.ReportCodec, reqs ...functions return reportBytes } -func TestDRReporting_ShouldAcceptFinalizedReport(t *testing.T) { +func TestFunctionsReporting_ShouldAcceptFinalizedReport(t *testing.T) { t.Parallel() - plugin, orm, codec := preparePlugin(t, 10) + plugin, orm, codec := preparePlugin(t, 10, 0, 0) req1 := newRequestWithResult([]byte("xxx")) // nonexistent req2 := newRequestWithResult([]byte("abc")) @@ -315,9 +401,9 @@ func TestDRReporting_ShouldAcceptFinalizedReport(t *testing.T) { require.True(t, should) } -func TestDRReporting_ShouldTransmitAcceptedReport(t *testing.T) { +func TestFunctionsReporting_ShouldTransmitAcceptedReport(t *testing.T) { t.Parallel() - plugin, orm, codec := preparePlugin(t, 10) + plugin, orm, codec := preparePlugin(t, 10, 0, 0) req1 := newRequestWithResult([]byte("xxx")) // nonexistent req2 := newRequestWithResult([]byte("abc")) diff --git a/core/services/relay/evm/contract_transmitter_test.go b/core/services/relay/evm/contract_transmitter_test.go index 73c9234a13e..e03c5508247 100644 --- a/core/services/relay/evm/contract_transmitter_test.go +++ b/core/services/relay/evm/contract_transmitter_test.go @@ -55,7 +55,7 @@ func TestContractTransmitter(t *testing.T) { // scanLogs = true digestAndEpochScanLogs, _ := hex.DecodeString( - "0000000000000000000000000000000000000000000000000000000000000001" + // false + "0000000000000000000000000000000000000000000000000000000000000001" + // true "000130da6b9315bd59af6b0a3f5463c0d0a39e92eaa34cbcbdbace7b3bfcc776" + // config digest "0000000000000000000000000000000000000000000000000000000000000002") // epoch c.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(digestAndEpochScanLogs, nil).Once() diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index c5bf13c0854..169b42f1864 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -12,9 +12,13 @@ import ( "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" + txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + txm "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" + "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" functionsRelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" ) @@ -37,7 +41,11 @@ func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, par if err != nil { return nil, err } - contractTransmitter, err := newContractTransmitter(lggr, rargs, pargs.TransmitterID, configWatcher, ethKeystore) + var pluginConfig config.PluginConfig + if err2 := json.Unmarshal(pargs.PluginConfig, &pluginConfig); err2 != nil { + return nil, err2 + } + contractTransmitter, err := newFunctionsContractTransmitter(pluginConfig.ContractVersion, rargs, pargs.TransmitterID, configWatcher, ethKeystore, lggr) if err != nil { return nil, err } @@ -82,3 +90,73 @@ func newFunctionsConfigProvider(pluginType functionsRelay.FunctionsPluginType, c return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, relayConfig.FromBlock, args.New), nil } + +func newFunctionsContractTransmitter(contractVersion uint32, rargs relaytypes.RelayArgs, transmitterID string, configWatcher *configWatcher, ethKeystore keystore.Eth, lggr logger.Logger) (ContractTransmitter, error) { + var relayConfig evmRelayTypes.RelayConfig + if err := json.Unmarshal(rargs.RelayConfig, &relayConfig); err != nil { + return nil, err + } + var fromAddresses []common.Address + sendingKeys := relayConfig.SendingKeys + if !relayConfig.EffectiveTransmitterID.Valid { + return nil, errors.New("EffectiveTransmitterID must be specified") + } + effectiveTransmitterAddress := common.HexToAddress(relayConfig.EffectiveTransmitterID.String) + + sendingKeysLength := len(sendingKeys) + if sendingKeysLength == 0 { + return nil, errors.New("no sending keys provided") + } + + // If we are using multiple sending keys, then a forwarder is needed to rotate transmissions. + // Ensure that this forwarder is not set to a local sending key, and ensure our sending keys are enabled. + for _, s := range sendingKeys { + if sendingKeysLength > 1 && s == effectiveTransmitterAddress.String() { + return nil, errors.New("the transmitter is a local sending key with transaction forwarding enabled") + } + if err := ethKeystore.CheckEnabled(common.HexToAddress(s), configWatcher.chain.Config().EVM().ChainID()); err != nil { + return nil, errors.Wrap(err, "one of the sending keys given is not enabled") + } + fromAddresses = append(fromAddresses, common.HexToAddress(s)) + } + + scoped := configWatcher.chain.Config() + strategy := txmgrcommon.NewQueueingTxStrategy(rargs.ExternalJobID, scoped.OCR2().DefaultTransactionQueueDepth(), scoped.Database().DefaultQueryTimeout()) + + var checker txm.TransmitCheckerSpec + if configWatcher.chain.Config().OCR2().SimulateTransactions() { + checker.CheckerType = txm.TransmitCheckerTypeSimulate + } + + gasLimit := configWatcher.chain.Config().EVM().GasEstimator().LimitDefault() + ocr2Limit := configWatcher.chain.Config().EVM().GasEstimator().LimitJobType().OCR2() + if ocr2Limit != nil { + gasLimit = *ocr2Limit + } + + transmitter, err := ocrcommon.NewTransmitter( + configWatcher.chain.TxManager(), + fromAddresses, + gasLimit, + effectiveTransmitterAddress, + strategy, + checker, + configWatcher.chain.ID(), + ethKeystore, + ) + + if err != nil { + return nil, errors.Wrap(err, "failed to create transmitter") + } + + return functionsRelay.NewFunctionsContractTransmitter( + configWatcher.contractAddress, + configWatcher.chain.Client(), + configWatcher.contractABI, + transmitter, + configWatcher.chain.LogPoller(), + lggr, + nil, + contractVersion, + ) +} diff --git a/core/services/relay/evm/functions/contract_transmitter.go b/core/services/relay/evm/functions/contract_transmitter.go new file mode 100644 index 00000000000..eda0ae1b78a --- /dev/null +++ b/core/services/relay/evm/functions/contract_transmitter.go @@ -0,0 +1,232 @@ +package functions + +import ( + "context" + "database/sql" + "encoding/hex" + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + gethcommon "github.com/ethereum/go-ethereum/common" + "github.com/pkg/errors" + "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/encoding" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +type FunctionsContractTransmitter interface { + services.ServiceCtx + ocrtypes.ContractTransmitter +} + +var _ FunctionsContractTransmitter = &contractTransmitter{} + +type Transmitter interface { + CreateEthTransaction(ctx context.Context, toAddress gethcommon.Address, payload []byte, txMeta *txmgr.TxMeta) error + FromAddress() gethcommon.Address +} + +type ReportToEthMetadata func([]byte) (*txmgr.TxMeta, error) + +func reportToEvmTxMetaNoop([]byte) (*txmgr.TxMeta, error) { + return nil, nil +} + +type contractTransmitter struct { + contractAddress gethcommon.Address + contractABI abi.ABI + transmitter Transmitter + transmittedEventSig common.Hash + contractReader contractReader + lp logpoller.LogPoller + lggr logger.Logger + reportToEvmTxMeta ReportToEthMetadata + contractVersion uint32 + reportCodec encoding.ReportCodec +} + +func transmitterFilterName(addr common.Address) string { + return logpoller.FilterName("OCR ContractTransmitter", addr.String()) +} + +func NewFunctionsContractTransmitter( + destAddressV0 gethcommon.Address, + caller contractReader, + contractABI abi.ABI, + transmitter Transmitter, + lp logpoller.LogPoller, + lggr logger.Logger, + reportToEvmTxMeta ReportToEthMetadata, + contractVersion uint32, +) (*contractTransmitter, error) { + transmitted, ok := contractABI.Events["Transmitted"] + if !ok { + return nil, errors.New("invalid ABI, missing transmitted") + } + + // TODO(FUN-674): Read updates from correct contract. + err := lp.RegisterFilter(logpoller.Filter{Name: transmitterFilterName(destAddressV0), EventSigs: []common.Hash{transmitted.ID}, Addresses: []common.Address{destAddressV0}}) + if err != nil { + return nil, err + } + if reportToEvmTxMeta == nil { + reportToEvmTxMeta = reportToEvmTxMetaNoop + } + codec, err := encoding.NewReportCodec(contractVersion) + if err != nil { + return nil, err + } + return &contractTransmitter{ + contractAddress: destAddressV0, + contractABI: contractABI, + transmitter: transmitter, + transmittedEventSig: transmitted.ID, + lp: lp, + contractReader: caller, + lggr: lggr.Named("OCRContractTransmitter"), + reportToEvmTxMeta: reportToEvmTxMeta, + contractVersion: contractVersion, + reportCodec: codec, + }, nil +} + +// Transmit sends the report to the on-chain smart contract's Transmit method. +func (oc *contractTransmitter) Transmit(ctx context.Context, reportCtx ocrtypes.ReportContext, report ocrtypes.Report, signatures []ocrtypes.AttributedOnchainSignature) error { + var rs [][32]byte + var ss [][32]byte + var vs [32]byte + for i, as := range signatures { + r, s, v, err := evmutil.SplitSignature(as.Signature) + if err != nil { + panic("eventTransmit(ev): error in SplitSignature") + } + rs = append(rs, r) + ss = append(ss, s) + vs[i] = v + } + rawReportCtx := evmutil.RawReportContext(reportCtx) + + txMeta, err := oc.reportToEvmTxMeta(report) + if err != nil { + oc.lggr.Warnw("failed to generate tx metadata for report", "err", err) + } + + destinationContract := oc.contractAddress + if oc.contractVersion == 1 { + requests, err2 := oc.reportCodec.DecodeReport(report) + if err2 != nil { + return errors.Wrap(err2, "DecodeReport failed") + } + if len(requests) == 0 { + return errors.New("no requests in report") + } + if len(requests[0].CoordinatorContract) != common.AddressLength { + return fmt.Errorf("incorrect length of CoordinatorContract field: %d", len(requests[0].CoordinatorContract)) + } + // NOTE: this is incorrect if batch contains requests destined for different contracts + // and there is currently no way areound it until we get rid of batching + destinationContract.SetBytes(requests[0].CoordinatorContract) + } + + oc.lggr.Debugw("Transmitting report", "report", hex.EncodeToString(report), "rawReportCtx", rawReportCtx, "contractAddress", destinationContract, "txMeta", txMeta) + + payload, err := oc.contractABI.Pack("transmit", rawReportCtx, []byte(report), rs, ss, vs) + if err != nil { + return errors.Wrap(err, "abi.Pack failed") + } + + return errors.Wrap(oc.transmitter.CreateEthTransaction(ctx, destinationContract, payload, txMeta), "failed to send Eth transaction") +} + +type contractReader interface { + CallContract(ctx context.Context, call ethereum.CallMsg, blockNumber *big.Int) ([]byte, error) +} + +func parseTransmitted(log []byte) ([32]byte, uint32, error) { + var args abi.Arguments = []abi.Argument{ + { + Name: "configDigest", + Type: utils.MustAbiType("bytes32", nil), + }, + { + Name: "epoch", + Type: utils.MustAbiType("uint32", nil), + }, + } + transmitted, err := args.Unpack(log) + if err != nil { + return [32]byte{}, 0, err + } + configDigest := *abi.ConvertType(transmitted[0], new([32]byte)).(*[32]byte) + epoch := *abi.ConvertType(transmitted[1], new(uint32)).(*uint32) + return configDigest, epoch, err +} + +func callContract(ctx context.Context, addr common.Address, contractABI abi.ABI, method string, args []interface{}, caller contractReader) ([]interface{}, error) { + input, err := contractABI.Pack(method, args...) + if err != nil { + return nil, err + } + output, err := caller.CallContract(ctx, ethereum.CallMsg{To: &addr, Data: input}, nil) + if err != nil { + return nil, err + } + return contractABI.Unpack(method, output) +} + +// LatestConfigDigestAndEpoch retrieves the latest config digest and epoch from the OCR2 contract. +// It is plugin independent, in particular avoids use of the plugin specific generated evm wrappers +// by using the evm client Call directly for functions/events that are part of OCR2Abstract. +func (oc *contractTransmitter) LatestConfigDigestAndEpoch(ctx context.Context) (ocrtypes.ConfigDigest, uint32, error) { + latestConfigDigestAndEpoch, err := callContract(ctx, oc.contractAddress, oc.contractABI, "latestConfigDigestAndEpoch", nil, oc.contractReader) + if err != nil { + return ocrtypes.ConfigDigest{}, 0, err + } + // Panic on these conversions erroring, would mean a broken contract. + scanLogs := *abi.ConvertType(latestConfigDigestAndEpoch[0], new(bool)).(*bool) + configDigest := *abi.ConvertType(latestConfigDigestAndEpoch[1], new([32]byte)).(*[32]byte) + epoch := *abi.ConvertType(latestConfigDigestAndEpoch[2], new(uint32)).(*uint32) + if !scanLogs { + return configDigest, epoch, nil + } + + // Otherwise, we have to scan for the logs. + if err != nil { + return ocrtypes.ConfigDigest{}, 0, err + } + latest, err := oc.lp.LatestLogByEventSigWithConfs( + oc.transmittedEventSig, oc.contractAddress, 1, pg.WithParentCtx(ctx)) + if err != nil { + if errors.Is(err, sql.ErrNoRows) { + // No transmissions yet + return configDigest, 0, nil + } + return ocrtypes.ConfigDigest{}, 0, err + } + return parseTransmitted(latest.Data) +} + +// FromAccount returns the account from which the transmitter invokes the contract +func (oc *contractTransmitter) FromAccount() (ocrtypes.Account, error) { + return ocrtypes.Account(oc.transmitter.FromAddress().String()), nil +} + +func (oc *contractTransmitter) Start(ctx context.Context) error { return nil } +func (oc *contractTransmitter) Close() error { return nil } + +// Has no state/lifecycle so it's always healthy and ready +func (oc *contractTransmitter) Ready() error { return nil } +func (oc *contractTransmitter) HealthReport() map[string]error { + return map[string]error{oc.Name(): nil} +} +func (oc *contractTransmitter) Name() string { return oc.lggr.Name() } diff --git a/core/services/relay/evm/functions/contract_transmitter_test.go b/core/services/relay/evm/functions/contract_transmitter_test.go new file mode 100644 index 00000000000..b8bd98473da --- /dev/null +++ b/core/services/relay/evm/functions/contract_transmitter_test.go @@ -0,0 +1,118 @@ +package functions_test + +import ( + "context" + "encoding/hex" + "strings" + "testing" + + "github.com/ethereum/go-ethereum/accounts/abi" + gethcommon "github.com/ethereum/go-ethereum/common" + "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" + + evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" + lpmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/encoding" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" +) + +type mockTransmitter struct { + toAddress gethcommon.Address +} + +func (m *mockTransmitter) CreateEthTransaction(ctx context.Context, toAddress gethcommon.Address, payload []byte, _ *txmgr.TxMeta) error { + m.toAddress = toAddress + return nil +} +func (mockTransmitter) FromAddress() gethcommon.Address { return testutils.NewAddress() } + +func TestContractTransmitter_LatestConfigDigestAndEpoch(t *testing.T) { + t.Parallel() + + digestStr := "000130da6b9315bd59af6b0a3f5463c0d0a39e92eaa34cbcbdbace7b3bfcc776" + lggr := logger.TestLogger(t) + c := evmclimocks.NewClient(t) + lp := lpmocks.NewLogPoller(t) + digestAndEpochDontScanLogs, err := hex.DecodeString( + "0000000000000000000000000000000000000000000000000000000000000000" + // scan logs = false + digestStr + + "0000000000000000000000000000000000000000000000000000000000000002") // epoch + require.NoError(t, err) + c.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(digestAndEpochDontScanLogs, nil).Once() + contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorABI)) + require.NoError(t, err) + lp.On("RegisterFilter", mock.Anything).Return(nil) + + functionsTransmitter, err := functions.NewFunctionsContractTransmitter(gethcommon.Address{}, c, contractABI, &mockTransmitter{}, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { + return &txmgr.TxMeta{}, nil + }, 0) + require.NoError(t, err) + + digest, epoch, err := functionsTransmitter.LatestConfigDigestAndEpoch(testutils.Context(t)) + require.NoError(t, err) + assert.Equal(t, digestStr, hex.EncodeToString(digest[:])) + assert.Equal(t, uint32(2), epoch) +} + +func TestContractTransmitter_Transmit_V0(t *testing.T) { + t.Parallel() + + contractVersion := uint32(0) + destAddress := testutils.NewAddress() + lggr := logger.TestLogger(t) + c := evmclimocks.NewClient(t) + lp := lpmocks.NewLogPoller(t) + contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorABI)) + require.NoError(t, err) + lp.On("RegisterFilter", mock.Anything).Return(nil) + + ocrTransmitter := mockTransmitter{} + ot, err := functions.NewFunctionsContractTransmitter(destAddress, c, contractABI, &ocrTransmitter, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { + return &txmgr.TxMeta{}, nil + }, contractVersion) + require.NoError(t, err) + + require.NoError(t, ot.Transmit(testutils.Context(t), ocrtypes.ReportContext{}, []byte("bar"), []ocrtypes.AttributedOnchainSignature{})) + require.Equal(t, destAddress, ocrTransmitter.toAddress) +} + +func TestContractTransmitter_Transmit_V1(t *testing.T) { + t.Parallel() + + contractVersion := uint32(1) + configuredDestAddress, coordinatorAddress := testutils.NewAddress(), testutils.NewAddress() + lggr := logger.TestLogger(t) + c := evmclimocks.NewClient(t) + lp := lpmocks.NewLogPoller(t) + contractABI, _ := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorABI)) + lp.On("RegisterFilter", mock.Anything).Return(nil) + + ocrTransmitter := mockTransmitter{} + ot, err := functions.NewFunctionsContractTransmitter(configuredDestAddress, c, contractABI, &ocrTransmitter, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { + return &txmgr.TxMeta{}, nil + }, contractVersion) + require.NoError(t, err) + + reqId, err := hex.DecodeString("000102030405060708090a0b0c0d0e0f000102030405060708090a0b0c0d0e0f") + require.NoError(t, err) + processedRequests := []*encoding.ProcessedRequest{ + { + RequestID: reqId, + CoordinatorContract: coordinatorAddress.Bytes(), + }, + } + codec, err := encoding.NewReportCodec(contractVersion) + require.NoError(t, err) + reportBytes, err := codec.EncodeReport(processedRequests) + require.NoError(t, err) + + require.NoError(t, ot.Transmit(testutils.Context(t), ocrtypes.ReportContext{}, reportBytes, []ocrtypes.AttributedOnchainSignature{})) + require.Equal(t, coordinatorAddress, ocrTransmitter.toAddress) +} From 59ac7ce2cdd27a47863fd5c45a98314b1a955377 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Thu, 27 Jul 2023 23:49:54 -0400 Subject: [PATCH 024/270] Rename contract setConfig methods to maintain OCR plugin's expectation (#9965) --- .../functions/dev/1_0_0/FunctionsBilling.sol | 8 +- .../dev/1_0_0/FunctionsCoordinator.sol | 3 + .../functions/dev/1_0_0/FunctionsRouter.sol | 18 +- .../src/v0.8/functions/dev/1_0_0/Routable.sol | 8 +- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 8 +- .../accessControl/TermsOfServiceAllowList.sol | 2 +- .../dev/1_0_0/interfaces/IConfigurable.sol | 2 +- .../functions/dev/1_0_0/ocr/OCR2Abstract.sol | 2 +- .../v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol | 2 +- .../functions_allow_list.go | 32 +- .../functions_coordinator.go | 319 +++++++++++++----- .../functions_router/functions_router.go | 116 +++---- ...rapper-dependency-versions-do-not-edit.txt | 6 +- 13 files changed, 338 insertions(+), 188 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 3711a628ed4..9dfd98e4424 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -64,7 +64,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint256 fulfillmentGasPriceOverEstimationBP; } Config private s_config; - event ConfigSet( + event ConfigChanged( uint32 maxCallbackGasLimit, uint32 feedStalenessSeconds, uint32 gasOverheadBeforeCallback, @@ -120,7 +120,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { * @param config bytes of abi.encoded config data to set the following: * See the content of the Config struct above */ - function _setConfig(bytes memory config) internal override { + function _updateConfig(bytes memory config) internal override { ( uint32 maxCallbackGasLimit, uint32 feedStalenessSeconds, @@ -147,7 +147,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { maxSupportedRequestDataVersion: maxSupportedRequestDataVersion, fulfillmentGasPriceOverEstimationBP: fulfillmentGasPriceOverEstimationBP }); - emit ConfigSet( + emit ConfigChanged( maxCallbackGasLimit, feedStalenessSeconds, gasOverheadBeforeCallback, @@ -375,7 +375,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { if (weiPerUnitLink <= 0) { revert InvalidLinkWeiPrice(weiPerUnitLink); } - // (1e18 juels/link) * (gas/wei) / (wei/link) = juels per wei + // (1e18 juels/link) * (wei/gas) / (wei/link) = juels per gas uint256 juelsPerGas = (1e18 * tx.gasprice) / uint256(weiPerUnitLink); // Gas overhead without callback uint96 gasOverheadJuels = uint96(juelsPerGas * commitment.gasOverhead); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 96c8cad5c57..0098d4a1dbc 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -28,6 +28,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli event InvalidRequestID(bytes32 indexed requestId); event InsufficientGasProvided(bytes32 indexed requestId); event CostExceedsCommitment(bytes32 indexed requestId); + event InsufficientSubscriptionBalance(bytes32 indexed requestId); error EmptyRequestData(); error InconsistentReportData(); @@ -241,6 +242,8 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli emit InsufficientGasProvided(requestIds[i]); } else if (result == FulfillResult.COST_EXCEEDS_COMMITMENT) { emit CostExceedsCommitment(requestIds[i]); + } else if (result == FulfillResult.INSUFFICIENT_SUBSCRIPTION_BALANCE) { + emit InsufficientSubscriptionBalance(requestIds[i]); } } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index cafd6d96551..ee4df59b20e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -56,8 +56,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint32[] maxCallbackGasLimits; } Config private s_config; - - event ConfigSet(uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] maxCallbackGasLimits); + event ConfigChanged(uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] maxCallbackGasLimits); error OnlyCallableByRoute(); @@ -103,7 +102,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions * @param config bytes of config data to set the following: * - adminFee: fee that will be paid to the Router owner for operating the network */ - function _setConfig(bytes memory config) internal override { + function _updateConfig(bytes memory config) internal override { (uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] memory maxCallbackGasLimits) = abi.decode( config, (uint96, bytes4, uint32[]) @@ -113,7 +112,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions handleOracleFulfillmentSelector: handleOracleFulfillmentSelector, maxCallbackGasLimits: maxCallbackGasLimits }); - emit ConfigSet(adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits); + emit ConfigChanged(adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits); } // ================================================================ @@ -244,12 +243,21 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions return (resultCode, callbackGasCostJuels); } + // Check that the subscription can still afford + if ( + commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > + s_subscriptions[commitment.subscriptionId].balance + ) { + resultCode = 4; // IFunctionsRouter.FulfillResult.INSUFFICIENT_SUBSCRIPTION_BALANCE + return (resultCode, callbackGasCostJuels); + } + // Check that the cost has not exceeded the quoted cost if ( commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > commitment.estimatedCost ) { - resultCode = 4; // IFunctionsRouter.FulfillResult.COST_EXCEEDS_COMMITMENT + resultCode = 5; // IFunctionsRouter.FulfillResult.COST_EXCEEDS_COMMITMENT return (resultCode, callbackGasCostJuels); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index f5a9ac1a477..876bbcc4fd7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -24,7 +24,7 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { revert RouterMustBeSet(); } s_router = IRouterBase(router); - _setConfig(config); + _updateConfig(config); s_config_hash = keccak256(config); } @@ -39,13 +39,13 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { * @dev Must be implemented by inheriting contract * Use to set configuration state */ - function _setConfig(bytes memory config) internal virtual; + function _updateConfig(bytes memory config) internal virtual; /** * @inheritdoc IConfigurable */ - function setConfig(bytes memory config) external override onlyRouter { - _setConfig(config); + function updateConfig(bytes memory config) external override onlyRouter { + _updateConfig(config); s_config_hash = keccak256(config); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index 6e6176aaa30..5610f26f264 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -100,7 +100,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme MAXIMUM_TIMELOCK_BLOCKS = maximumTimelockBlocks; // Set the initial configuration for the Router s_route[routerId] = address(this); - _setConfig(selfConfig); + _updateConfig(selfConfig); s_config_hash = keccak256(selfConfig); } @@ -249,7 +249,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme * @dev Must be implemented by inheriting contract * Use to set configuration state of the Router */ - function _setConfig(bytes memory config) internal virtual; + function _updateConfig(bytes memory config) internal virtual; /** * @inheritdoc IRouterBase @@ -278,10 +278,10 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme revert TimelockInEffect(); } if (id == routerId) { - _setConfig(proposal.to); + _updateConfig(proposal.to); s_config_hash = keccak256(proposal.to); } else { - try IConfigurable(_getContractById(id, false)).setConfig(proposal.to) {} catch { + try IConfigurable(_getContractById(id, false)).updateConfig(proposal.to) {} catch { revert InvalidConfigData(); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index aa44b0b421a..59920c65f41 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -42,7 +42,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { * - enabled: boolean representing if the allow list is active, when disabled all usage will be allowed * - proofSignerPublicKey: public key of the signer of the proof */ - function _setConfig(bytes memory config) internal override { + function _updateConfig(bytes memory config) internal override { (bool enabled, address proofSignerPublicKey) = abi.decode(config, (bool, address)); s_config = Config({enabled: enabled, proofSignerPublicKey: proofSignerPublicKey}); emit ConfigSet(enabled); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol index 836f888f584..6348143d83e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol @@ -16,5 +16,5 @@ interface IConfigurable { * @dev Only callable by the Router * @param config bytes containing config data */ - function setConfig(bytes calldata config) external; + function updateConfig(bytes calldata config) external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol index ecfa75158c5..4d7bbf150df 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol @@ -19,7 +19,7 @@ abstract contract OCR2Abstract is ITypeAndVersion { * @param offchainConfigVersion version of the serialization format used for "offchainConfig" parameter * @param offchainConfig serialized configuration used by the oracles exclusively and only passed through the contract */ - event OCRConfigSet( + event ConfigSet( uint32 previousConfigBlockNumber, bytes32 configDigest, uint64 configCount, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol index 3a9872bf60e..7b8d64798e9 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol @@ -173,7 +173,7 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { } s_configInfo.n = uint8(args.signers.length); - emit OCRConfigSet( + emit ConfigSet( previousConfigBlockNumber, s_configInfo.latestConfigDigest, s_configCount, diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index 65b5efd18da..21805865db4 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -31,8 +31,8 @@ var ( ) var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isAllowedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b506040516200114238038062001142833981016040819052620000349162000164565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b038416179055620000848162000099565b80516020909101206000555062000292915050565b60008082806020019051810190620000b291906200024f565b6040805180820182528315158082526001600160a01b0384166020928301819052600680546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200014b57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200017857600080fd5b8251620001858162000135565b602084810151919350906001600160401b0380821115620001a557600080fd5b818601915086601f830112620001ba57600080fd5b815181811115620001cf57620001cf6200014e565b604051601f8201601f19908116603f01168101908382118183101715620001fa57620001fa6200014e565b8160405282815289868487010111156200021357600080fd5b600093505b8284101562000237578484018601518185018701529285019262000218565b60008684830101528096505050505050509250929050565b600080604083850312156200026357600080fd5b825180151581146200027457600080fd5b6020840151909250620002878162000135565b809150509250929050565b610ea080620002a26000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c806382184c7b11610076578063a5e1d61d1161005b578063a5e1d61d14610158578063be8c97b01461017b578063fa5408011461018e57600080fd5b806382184c7b1461013d5780639883c10d1461015057600080fd5b8063354497aa116100a7578063354497aa146100f657806347663acb1461010957806380e8a1511461011c57600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb6101ef565b6040516100d89190610af2565b60405180910390f35b6100f46100ef366004610b83565b61020f565b005b6100f4610104366004610c44565b61044c565b6100f4610117366004610d13565b6104b3565b61012f61012a366004610d30565b6105b9565b6040519081526020016100d8565b6100f461014b366004610d13565b610617565b60005461012f565b61016b610166366004610d13565b610725565b60405190151581526020016100d8565b61016b610189366004610d13565b610749565b61012f61019c366004610d69565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610e6c60289139905090565b61021a600484610769565b15610251576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061025d85856105b9565b905060006102b8826040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b905060006102fc8286868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061079b92505050565b60065490915073ffffffffffffffffffffffffffffffffffffffff8083166101009092041614610358576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b63ffffffff333b1615801590816103a557503373ffffffffffffffffffffffffffffffffffffffff89161415806103a557503373ffffffffffffffffffffffffffffffffffffffff881614155b156103dc576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080156103ff57503373ffffffffffffffffffffffffffffffffffffffff881614155b15610436576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610441600288610838565b505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461049d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6104a68161085a565b8051602090910120600055565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610522573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105469190610d82565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146105aa576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6105b5600482610930565b5050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610686573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106aa9190610d82565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461070e576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610719600282610930565b506105b5600482610838565b60065460009060ff161515810361073e57506000919050565b610611600483610769565b60065460009060ff161515810361076257506001919050565b6106116002835b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b9392505050565b6000806000806107aa85610952565b6040805160008152602081018083528b905260ff8316918101919091526060810184905260808101839052929550909350915060019060a0016020604051602081039080840390855afa158015610805573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b60006107948373ffffffffffffffffffffffffffffffffffffffff84166109b0565b600080828060200190518101906108719190610d9f565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600680547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b60006107948373ffffffffffffffffffffffffffffffffffffffff84166109ff565b60008060008351604114610992576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505060208101516040820151606090920151909260009190911a90565b60008181526001830160205260408120546109f757508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610611565b506000610611565b60008181526001830160205260408120548015610ae8576000610a23600183610dd3565b8554909150600090610a3790600190610dd3565b9050818114610a9c576000866000018281548110610a5757610a57610e0d565b9060005260206000200154905080876000018481548110610a7a57610a7a610e0d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610aad57610aad610e3c565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610611565b6000915050610611565b600060208083528351808285015260005b81811015610b1f57858101830151858201604001528201610b03565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610b8057600080fd5b50565b60008060008060608587031215610b9957600080fd5b8435610ba481610b5e565b93506020850135610bb481610b5e565b9250604085013567ffffffffffffffff80821115610bd157600080fd5b818701915087601f830112610be557600080fd5b813581811115610bf457600080fd5b886020828501011115610c0657600080fd5b95989497505060200194505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610c5657600080fd5b813567ffffffffffffffff80821115610c6e57600080fd5b818401915084601f830112610c8257600080fd5b813581811115610c9457610c94610c15565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610cda57610cda610c15565b81604052828152876020848701011115610cf357600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610d2557600080fd5b813561079481610b5e565b60008060408385031215610d4357600080fd5b8235610d4e81610b5e565b91506020830135610d5e81610b5e565b809150509250929050565b600060208284031215610d7b57600080fd5b5035919050565b600060208284031215610d9457600080fd5b815161079481610b5e565b60008060408385031215610db257600080fd5b82518015158114610dc257600080fd5b6020840151909250610d5e81610b5e565b81810381811115610611577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isAllowedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60806040523480156200001157600080fd5b506040516200114238038062001142833981016040819052620000349162000164565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b038416179055620000848162000099565b80516020909101206000555062000292915050565b60008082806020019051810190620000b291906200024f565b6040805180820182528315158082526001600160a01b0384166020928301819052600680546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200014b57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200017857600080fd5b8251620001858162000135565b602084810151919350906001600160401b0380821115620001a557600080fd5b818601915086601f830112620001ba57600080fd5b815181811115620001cf57620001cf6200014e565b604051601f8201601f19908116603f01168101908382118183101715620001fa57620001fa6200014e565b8160405282815289868487010111156200021357600080fd5b600093505b8284101562000237578484018601518185018701529285019262000218565b60008684830101528096505050505050509250929050565b600080604083850312156200026357600080fd5b825180151581146200027457600080fd5b6020840151909250620002878162000135565b809150509250929050565b610ea080620002a26000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80638cc6acce11610076578063a5e1d61d1161005b578063a5e1d61d14610158578063be8c97b01461017b578063fa5408011461018e57600080fd5b80638cc6acce1461013d5780639883c10d1461015057600080fd5b806347663acb116100a757806347663acb146100f657806380e8a1511461010957806382184c7b1461012a57600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb6101ef565b6040516100d89190610af2565b60405180910390f35b6100f46100ef366004610b83565b61020f565b005b6100f4610104366004610c15565b61044c565b61011c610117366004610c32565b610552565b6040519081526020016100d8565b6100f4610138366004610c15565b6105b0565b6100f461014b366004610c9a565b6106be565b60005461011c565b61016b610166366004610c15565b610725565b60405190151581526020016100d8565b61016b610189366004610c15565b610749565b61011c61019c366004610d69565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610e6c60289139905090565b61021a600484610769565b15610251576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061025d8585610552565b905060006102b8826040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b905060006102fc8286868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061079b92505050565b60065490915073ffffffffffffffffffffffffffffffffffffffff8083166101009092041614610358576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b63ffffffff333b1615801590816103a557503373ffffffffffffffffffffffffffffffffffffffff89161415806103a557503373ffffffffffffffffffffffffffffffffffffffff881614155b156103dc576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080156103ff57503373ffffffffffffffffffffffffffffffffffffffff881614155b15610436576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610441600288610838565b505050505050505050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156104bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104df9190610d82565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610543576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61054e60048261085a565b5050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561061f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106439190610d82565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106a7576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106b260028261085a565b5061054e600482610838565b60015473ffffffffffffffffffffffffffffffffffffffff16331461070f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107188161087c565b8051602090910120600055565b60065460009060ff161515810361073e57506000919050565b6105aa600483610769565b60065460009060ff161515810361076257506001919050565b6105aa6002835b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b9392505050565b6000806000806107aa85610952565b6040805160008152602081018083528b905260ff8316918101919091526060810184905260808101839052929550909350915060019060a0016020604051602081039080840390855afa158015610805573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b60006107948373ffffffffffffffffffffffffffffffffffffffff84166109b0565b60006107948373ffffffffffffffffffffffffffffffffffffffff84166109ff565b600080828060200190518101906108939190610d9f565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600680547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b60008060008351604114610992576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505060208101516040820151606090920151909260009190911a90565b60008181526001830160205260408120546109f7575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556105aa565b5060006105aa565b60008181526001830160205260408120548015610ae8576000610a23600183610dd3565b8554909150600090610a3790600190610dd3565b9050818114610a9c576000866000018281548110610a5757610a57610e0d565b9060005260206000200154905080876000018481548110610a7a57610a7a610e0d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610aad57610aad610e3c565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506105aa565b60009150506105aa565b600060208083528351808285015260005b81811015610b1f57858101830151858201604001528201610b03565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610b8057600080fd5b50565b60008060008060608587031215610b9957600080fd5b8435610ba481610b5e565b93506020850135610bb481610b5e565b9250604085013567ffffffffffffffff80821115610bd157600080fd5b818701915087601f830112610be557600080fd5b813581811115610bf457600080fd5b886020828501011115610c0657600080fd5b95989497505060200194505050565b600060208284031215610c2757600080fd5b813561079481610b5e565b60008060408385031215610c4557600080fd5b8235610c5081610b5e565b91506020830135610c6081610b5e565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610cac57600080fd5b813567ffffffffffffffff80821115610cc457600080fd5b818401915084601f830112610cd857600080fd5b813581811115610cea57610cea610c6b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610d3057610d30610c6b565b81604052828152876020848701011115610d4957600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610d7b57600080fd5b5035919050565b600060208284031215610d9457600080fd5b815161079481610b5e565b60008060408385031215610db257600080fd5b82518015158114610dc257600080fd5b6020840151909250610c6081610b5e565b818103818111156105aa577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI @@ -327,18 +327,6 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) BlockS return _TermsOfServiceAllowList.Contract.BlockSender(&_TermsOfServiceAllowList.TransactOpts, sender) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) SetConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { - return _TermsOfServiceAllowList.contract.Transact(opts, "setConfig", config) -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) SetConfig(config []byte) (*types.Transaction, error) { - return _TermsOfServiceAllowList.Contract.SetConfig(&_TermsOfServiceAllowList.TransactOpts, config) -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) SetConfig(config []byte) (*types.Transaction, error) { - return _TermsOfServiceAllowList.Contract.SetConfig(&_TermsOfServiceAllowList.TransactOpts, config) -} - func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) UnblockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) { return _TermsOfServiceAllowList.contract.Transact(opts, "unblockSender", sender) } @@ -351,6 +339,18 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) Unbloc return _TermsOfServiceAllowList.Contract.UnblockSender(&_TermsOfServiceAllowList.TransactOpts, sender) } +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { + return _TermsOfServiceAllowList.contract.Transact(opts, "updateConfig", config) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) UpdateConfig(config []byte) (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.UpdateConfig(&_TermsOfServiceAllowList.TransactOpts, config) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) UpdateConfig(config []byte) (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.UpdateConfig(&_TermsOfServiceAllowList.TransactOpts, config) +} + type TermsOfServiceAllowListConfigSetIterator struct { Event *TermsOfServiceAllowListConfigSet @@ -503,10 +503,10 @@ type TermsOfServiceAllowListInterface interface { BlockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) - SetConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) - UnblockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) + UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) + FilterConfigSet(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigSetIterator, error) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListConfigSet) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 36df6713c6c..b2778bd5086 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -61,8 +61,8 @@ type IFunctionsCoordinatorRequest struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"OCRConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200599138038062005991833981016040819052620000349162000444565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006169350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000222919062000554565b985098509850985098509850985098509850600085136200025a576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160601b038a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e805461ffff19169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590620003fd908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160601b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200042957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200045a57600080fd5b620004658462000411565b602085810151919450906001600160401b03808211156200048557600080fd5b818701915087601f8301126200049a57600080fd5b815181811115620004af57620004af6200042e565b604051601f8201601f19908116603f01168101908382118183101715620004da57620004da6200042e565b816040528281528a86848701011115620004f357600080fd5b600093505b82841015620005175784840186015181850187015292850192620004f8565b6000868483010152809750505050505050620005366040850162000411565b90509250925092565b805163ffffffff811681146200042957600080fd5b60008060008060008060008060006101208a8c0312156200057457600080fd5b6200057f8a6200053f565b98506200058f60208b016200053f565b97506200059f60408b016200053f565b9650620005af60608b016200053f565b955060808a01519450620005c660a08b016200053f565b60c08b01519094506001600160601b0381168114620005e457600080fd5b60e08b015190935061ffff81168114620005fd57600080fd5b809250506101008a015190509295985092959850929598565b60805161535f62000632600039600061124f015261535f6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806385b214cf116100ee578063c3f909d411610097578063de9dfa4611610071578063de9dfa4614610492578063e1a82d6f146104a5578063e3d0e712146104e5578063f2fde38b146104f857600080fd5b8063c3f909d4146103a5578063d227d24514610477578063d328a91e1461048a57600080fd5b8063af1296d3116100c8578063af1296d31461036a578063afcb95d714610372578063b1dc65a41461039257600080fd5b806385b214cf1461030d5780638da5cb5b146103305780639883c10d1461035857600080fd5b806366316d8d1161015b578063807560311161013557806380756031146102ad57806381411834146102c057806381f1b938146102d557806381ff7048146102dd57600080fd5b806366316d8d1461027f57806379ba5097146102925780637f15e1661461029a57600080fd5b8063354497aa1161018c578063354497aa146102265780634665571814610239578063533989871461026957600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004613ddf565b61050b565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a9190613e85565b60405180910390f35b6101c6610221366004613eba565b610560565b6101c6610234366004613fe3565b610602565b61024c610247366004614053565b610669565b6040516bffffffffffffffffffffffff909116815260200161020a565b610271610699565b60405161020a92919061417a565b6101c661028d366004614224565b610948565b6101c6610ac6565b6101c66102a8366004613ddf565b610bc8565b6101c66102bb36600461425d565b610c18565b6102c8610ccf565b60405161020a91906142b2565b6101fd610d3e565b6004546002546040805163ffffffff8085168252640100000000909404909316602084015282015260600161020a565b61032061031b3660046142c5565b610e0f565b604051901515815260200161020a565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6008545b60405190815260200161020a565b61035c610ff9565b60408051600181526000602082018190529181019190915260600161020a565b6101c66103a0366004614323565b6110dc565b610413600c54600d54600a54600e54600f5463ffffffff8086169664010000000087048216966c01000000000000000000000000810483169695680100000000000000009091049092169373ffffffffffffffffffffffffffffffffffffffff9092169261ffff9092169190565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61024c6104853660046143da565b61180d565b6101fd6119d3565b61024c6104a0366004614053565b611a2a565b6104b86104b336600461444a565b611ac5565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b6101c66104f3366004614537565b611d07565b6101c6610506366004613eba565b6126eb565b6105136126fc565b600081900361054e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601461055b8284836146a5565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061059b57503373ffffffffffffffffffffffffffffffffffffffff8216145b6105d1576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660009081526013602052604081206105ff91613d24565b50565b60095473ffffffffffffffffffffffffffffffffffffffff163314610653576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61065c8161277f565b8051602090910120600855565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106e9573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261072f9190810190614824565b90506000815167ffffffffffffffff81111561074d5761074d613ed7565b60405190808252806020026020018201604052801561078057816020015b606081526020019060019003908161076b5790505b50905060005b825181101561093e57601360008483815181106107a5576107a5614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107f290614604565b905060000361082d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013600084838151811061084357610843614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461089090614604565b80601f01602080910402602001604051908101604052809291908181526020018280546108bc90614604565b80156109095780601f106108de57610100808354040283529160200191610909565b820191906000526020600020905b8154815290600101906020018083116108ec57829003601f168201915b505050505082828151811061092057610920614859565b60200260200101819052508080610936906148b7565b915050610786565b5090939092509050565b610950612a46565b806bffffffffffffffffffffffff166000036109865750336000908152601060205260409020546bffffffffffffffffffffffff165b336000908152601060205260409020546bffffffffffffffffffffffff808316911610156109e0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526010602052604081208054839290610a0d9084906bffffffffffffffffffffffff166148ef565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610aa957600080fd5b505af1158015610abd573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b4c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bd06126fc565b6000819003610c0b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601261055b8284836146a5565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c635750610c4233612bdf565b8015610c6357503373ffffffffffffffffffffffffffffffffffffffff8416145b610c99576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601360205260409020610cc98284836146a5565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610d3457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d09575b5050505050905090565b606060148054610d4d90614604565b9050600003610d88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60148054610d9590614604565b80601f0160208091040260200160405190810160405280929190818152602001828054610dc190614604565b8015610d345780601f10610de357610100808354040283529160200191610d34565b820191906000526020600020905b815481529060010190602001808311610df157509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314610e63576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e0840152600481015461010084015260050154610120830152610f715750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611083573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110a79190614935565b509350509250508280156110c957506110c08142614985565b8463ffffffff16105b156110d457600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161113291849163ffffffff851691908e908e9081908401838280828437600092019190915250612cf392505050565b611168576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461123d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b43565b61124b8b8b8b8b8b8b612cfc565b60007f0000000000000000000000000000000000000000000000000000000000000000156112a8576002826020015183604001516112899190614998565b61129391906149e0565b61129e906001614998565b60ff1690506112be565b60208201516112b8906001614998565b60ff1690505b888114611327576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b43565b888714611390576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b43565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156113d3576113d3614a02565b60028111156113e4576113e4614a02565b905250905060028160200151600281111561140157611401614a02565b14801561144857506007816000015160ff168154811061142357611423614859565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b43565b50505050506114bb613d5e565b6000808a8a6040516114ce929190614a31565b6040519081900381206114e5918e90602001614a41565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117ef57600060018489846020811061154e5761154e614859565b61155b91901a601b614998565b8e8e8681811061156d5761156d614859565b905060200201358d8d8781811061158657611586614859565b90506020020135604051600081526020016040526040516115c3949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115e5573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561166557611665614a02565b600281111561167657611676614a02565b905250925060018360200151600281111561169357611693614a02565b146116fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b43565b8251600090879060ff16601f811061171457611714614859565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611796576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b43565b8086846000015160ff16601f81106117b0576117b0614859565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526117db600186614998565b945050806117e8906148b7565b905061152f565b505050611800833383858e8e612daa565b5050505050505050505050565b6009546040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8716600482015263ffffffff8416602482015260009173ffffffffffffffffffffffffffffffffffffffff169081906310fc49c19060440160006040518083038186803b15801561188f57600080fd5b505afa1580156118a3573d6000803e3d6000fd5b50505050620f42408311156118e4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152509050600061197288888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610669915050565b905060006119b789898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611a2a915050565b90506119c58787848461304f565b9a9950505050505050505050565b6060601280546119e290614604565b9050600003611a1d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60128054610d9590614604565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611a9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611abe9190614a55565b9392505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff163314611b1f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611b2c6060860186614a72565b9050600003611b66576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060800160405280876020016020810190611b869190614ad7565b67ffffffffffffffff168152602090810190611ba490890189613eba565b73ffffffffffffffffffffffffffffffffffffffff168152602001611bcf60e0890160c08a01614af4565b63ffffffff1681523a6020909101529050611c3b611bf06060880188614a72565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611c359250505060a0890160808a01614b21565b836131b1565b92975090955093509150611c526020870187613eba565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c32611c9b60408b0160208c01614ad7565b611cab60608c0160408d01613eba565b611cb860608d018d614a72565b8d6080016020810190611ccb9190614b21565b8e60a001358f60c0016020810190611ce39190614af4565b604051611cf7989796959493929190614b3e565b60405180910390a3509193509193565b855185518560ff16601f831115611d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b43565b60008111611de4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b43565b818314611e72576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b43565b611e7d816003614be4565b8311611ee5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b43565b611eed6126fc565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f349088613779565b600654156120e957600654600090611f4e90600190614985565b9050600060068281548110611f6557611f65614859565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f9f57611f9f614859565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560068054919250908061201f5761201f614bfb565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061208857612088614bfb565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f34915050565b60005b81515181101561254e576000600560008460000151848151811061211257612112614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215c5761215c614a02565b146121c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b43565b6040805180820190915260ff821681526001602082015282518051600591600091859081106121f4576121f4614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561229557612295614a02565b0217905550600091506122a59050565b60056000846020015184815181106122bf576122bf614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230957612309614a02565b14612370576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b43565b6040805180820190915260ff8216815260208101600281525060056000846020015184815181106123a3576123a3614859565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561244457612444614a02565b02179055505082518051600692508390811061246257612462614859565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160079190839081106124de576124de614859565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612547816148b7565b90506120ec565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff4381168202928317855590830481169360019390926000926125e0928692908216911617614c2a565b92506101000a81548163ffffffff021916908363ffffffff16021790555061263f4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613796565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a09986126de988b98919763ffffffff909216969095919491939192614c47565b60405180910390a1611800565b6126f36126fc565b6105ff81613841565b60005473ffffffffffffffffffffffffffffffffffffffff16331461277d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b43565b565b6000806000806000806000806000898060200190518101906127a19190614ccd565b985098509850985098509850985098509850600085136127f0576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610b43565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526bffffffffffffffffffffffff8a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055600f829055517fd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c590612a32908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526bffffffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b6000612a50610ccf565b90508051600003612a8d576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051601154600091612aac916bffffffffffffffffffffffff16614d7d565b905060005b82518160ff161015612b80578160106000858460ff1681518110612ad757612ad7614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612b3f9190614da8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508080612b7890614dcd565b915050612ab1565b508151612b8d9082614dec565b60118054600090612bad9084906bffffffffffffffffffffffff166148ef565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015612c2d573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612c739190810190614824565b905060005b8151811015612ce9578373ffffffffffffffffffffffffffffffffffffffff16828281518110612caa57612caa614859565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612cd7575060019392505050565b80612ce1816148b7565b915050612c78565b5060009392505050565b60019392505050565b6000612d09826020614be4565b612d14856020614be4565b612d2088610144614e1c565b612d2a9190614e1c565b612d349190614e1c565b612d3f906000614e1c565b9050368114610abd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b43565b60608080612dba84860186614eaf565b825192955090935091501580612dd257508151835114155b80612ddf57508051835114155b15612e16576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8351811015613043576000612e7a858381518110612e3957612e39614859565b6020026020010151858481518110612e5357612e53614859565b6020026020010151858581518110612e6d57612e6d614859565b6020026020010151613936565b90506000816006811115612e9057612e90614a02565b1480612ead57506001816006811115612eab57612eab614a02565b145b15612f0857848281518110612ec457612ec4614859565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613030565b6002816006811115612f1c57612f1c614a02565b03612f6c57848281518110612f3357612f33614859565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613030565b6003816006811115612f8057612f80614a02565b03612fd057848281518110612f9757612f97614859565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613030565b6005816006811115612fe457612fe4614a02565b0361303057848281518110612ffb57612ffb614859565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a25b508061303b816148b7565b915050612e19565b50505050505050505050565b60008061305a610ff9565b905060008113613099576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b43565b600c5460009087906130cf9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c2a565b6130d99190614c2a565b63ffffffff1690506000612710600c60030154886130f79190614be4565b6131019190614f8c565b61310b9088614e1c565b90506000838361312384670de0b6b3a7640000614be4565b61312d9190614be4565b6131379190614f8c565b905060006131566bffffffffffffffffffffffff808916908a16614e1c565b905061316e816b033b2e3c9fd0803ce8000000614985565b8211156131a7576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119c58183614e1c565b600e5460009081908190819061ffff90811690871611156131fe576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061320a8887610669565b905060006132188988611a2a565b9050600061323088604001518960600151858561304f565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa1580156132b3573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526132f99190810190614fa0565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa15801561338a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133ae919061502c565b509150506bffffffffffffffffffffffff85166133cb83856148ef565b6bffffffffffffffffffffffff161015613411576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613490308e602001518f6000015185600161342e919061507e565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff1661357c9190614c2a565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee54229061372990849061509f565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b6000613783610ccf565b51111561379257613792612a46565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016137ba999897969594939291906151a1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036138c0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b43565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613a45576002915050611abe565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613aa3610ff9565b905060008113613ae2576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b43565b600081613af73a670de0b6b3a7640000614be4565b613b019190614f8c565b9050600083610100015182613b169190614be4565b905060008460a0015182613b2a9190614da8565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613b92908f908f908f908c908b903390600401615236565b60408051808303816000875af1158015613bb0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bd491906152a7565b9092509050613be38186614da8565b33600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601180549193909291613c4391859116614da8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613ca99190614da8565b60c08d015160a08e0151613cbd888d614da8565b613cc79190614da8565b613cd19190614da8565b8760ff166006811115613ce657613ce6614a02565b604051613cf79594939291906152d6565b60405180910390a28160ff166006811115613d1457613d14614a02565b9c9b505050505050505050505050565b508054613d3090614604565b6000825580601f10613d40575050565b601f0160209004906000526020600020908101906105ff9190613d7d565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613d925760008155600101613d7e565b5090565b60008083601f840112613da857600080fd5b50813567ffffffffffffffff811115613dc057600080fd5b602083019150836020828501011115613dd857600080fd5b9250929050565b60008060208385031215613df257600080fd5b823567ffffffffffffffff811115613e0957600080fd5b613e1585828601613d96565b90969095509350505050565b6000815180845260005b81811015613e4757602081850181015186830182015201613e2b565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611abe6020830184613e21565b73ffffffffffffffffffffffffffffffffffffffff811681146105ff57600080fd5b600060208284031215613ecc57600080fd5b8135611abe81613e98565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613f4d57613f4d613ed7565b604052919050565b600082601f830112613f6657600080fd5b813567ffffffffffffffff811115613f8057613f80613ed7565b613fb160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f06565b818152846020838601011115613fc657600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613ff557600080fd5b813567ffffffffffffffff81111561400c57600080fd5b61401884828501613f55565b949350505050565b67ffffffffffffffff811681146105ff57600080fd5b8035610ff481614020565b63ffffffff811681146105ff57600080fd5b60008082840360a081121561406757600080fd5b833567ffffffffffffffff8082111561407f57600080fd5b61408b87838801613f55565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156140bd57600080fd5b604051925060808301915082821081831117156140dc576140dc613ed7565b5060405260208401356140ee81614020565b815260408401356140fe81613e98565b6020820152606084013561411181614041565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561416f57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161413d565b509495945050505050565b60408152600061418d6040830185614129565b6020838203818501528185518084528284019150828160051b85010183880160005b838110156141fb577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526141e9838351613e21565b948601949250908501906001016141af565b50909998505050505050505050565b6bffffffffffffffffffffffff811681146105ff57600080fd5b6000806040838503121561423757600080fd5b823561424281613e98565b915060208301356142528161420a565b809150509250929050565b60008060006040848603121561427257600080fd5b833561427d81613e98565b9250602084013567ffffffffffffffff81111561429957600080fd5b6142a586828701613d96565b9497909650939450505050565b602081526000611abe6020830184614129565b6000602082840312156142d757600080fd5b5035919050565b60008083601f8401126142f057600080fd5b50813567ffffffffffffffff81111561430857600080fd5b6020830191508360208260051b8501011115613dd857600080fd5b60008060008060008060008060e0898b03121561433f57600080fd5b606089018a81111561435057600080fd5b8998503567ffffffffffffffff8082111561436a57600080fd5b6143768c838d01613d96565b909950975060808b013591508082111561438f57600080fd5b61439b8c838d016142de565b909750955060a08b01359150808211156143b457600080fd5b506143c18b828c016142de565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156143f257600080fd5b85356143fd81614020565b9450602086013567ffffffffffffffff81111561441957600080fd5b61442588828901613d96565b909550935050604086013561443981614041565b949793965091946060013592915050565b60006020828403121561445c57600080fd5b813567ffffffffffffffff81111561447357600080fd5b820160e08185031215611abe57600080fd5b600067ffffffffffffffff82111561449f5761449f613ed7565b5060051b60200190565b600082601f8301126144ba57600080fd5b813560206144cf6144ca83614485565b613f06565b82815260059290921b840181019181810190868411156144ee57600080fd5b8286015b8481101561451257803561450581613e98565b83529183019183016144f2565b509695505050505050565b60ff811681146105ff57600080fd5b8035610ff48161451d565b60008060008060008060c0878903121561455057600080fd5b863567ffffffffffffffff8082111561456857600080fd5b6145748a838b016144a9565b9750602089013591508082111561458a57600080fd5b6145968a838b016144a9565b96506145a460408a0161452c565b955060608901359150808211156145ba57600080fd5b6145c68a838b01613f55565b94506145d460808a01614036565b935060a08901359150808211156145ea57600080fd5b506145f789828a01613f55565b9150509295509295509295565b600181811c9082168061461857607f821691505b602082108103614651577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561055b57600081815260208120601f850160051c8101602086101561467e5750805b601f850160051c820191505b8181101561469d5782815560010161468a565b505050505050565b67ffffffffffffffff8311156146bd576146bd613ed7565b6146d1836146cb8354614604565b83614657565b6000601f84116001811461472357600085156146ed5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147b9565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147725786850135825560209485019460019092019101614752565b50868210156147ad577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b600082601f8301126147d157600080fd5b815160206147e16144ca83614485565b82815260059290921b8401810191818101908684111561480057600080fd5b8286015b8481101561451257805161481781613e98565b8352918301918301614804565b60006020828403121561483657600080fd5b815167ffffffffffffffff81111561484d57600080fd5b614018848285016147c0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036148e8576148e8614888565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561491457614914614888565b5092915050565b805169ffffffffffffffffffff81168114610ff457600080fd5b600080600080600060a0868803121561494d57600080fd5b6149568661491b565b94506020860151935060408601519250606086015191506149796080870161491b565b90509295509295909350565b8181038181111561069357610693614888565b60ff818116838216019081111561069357610693614888565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff8316806149f3576149f36149b1565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614a6757600080fd5b8151611abe8161420a565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614aa757600080fd5b83018035915067ffffffffffffffff821115614ac257600080fd5b602001915036819003821315613dd857600080fd5b600060208284031215614ae957600080fd5b8135611abe81614020565b600060208284031215614b0657600080fd5b8135611abe81614041565b61ffff811681146105ff57600080fd5b600060208284031215614b3357600080fd5b8135611abe81614b11565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b808202811582820484141761069357610693614888565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561491457614914614888565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614c778184018a614129565b90508281036080840152614c8b8189614129565b905060ff871660a084015282810360c0840152614ca88187613e21565b905067ffffffffffffffff851660e0840152828103610100840152613d148185613e21565b60008060008060008060008060006101208a8c031215614cec57600080fd5b8951614cf781614041565b60208b0151909950614d0881614041565b60408b0151909850614d1981614041565b60608b0151909750614d2a81614041565b60808b015160a08c01519197509550614d4281614041565b60c08b0151909450614d538161420a565b60e08b0151909350614d6481614b11565b809250506101008a015190509295985092959850929598565b60006bffffffffffffffffffffffff80841680614d9c57614d9c6149b1565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561491457614914614888565b600060ff821660ff8103614de357614de3614888565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614e1457614e14614888565b505092915050565b8082018082111561069357610693614888565b600082601f830112614e4057600080fd5b81356020614e506144ca83614485565b82815260059290921b84018101918181019086841115614e6f57600080fd5b8286015b8481101561451257803567ffffffffffffffff811115614e935760008081fd5b614ea18986838b0101613f55565b845250918301918301614e73565b600080600060608486031215614ec457600080fd5b833567ffffffffffffffff80821115614edc57600080fd5b818601915086601f830112614ef057600080fd5b81356020614f006144ca83614485565b82815260059290921b8401810191818101908a841115614f1f57600080fd5b948201945b83861015614f3d57853582529482019490820190614f24565b97505087013592505080821115614f5357600080fd5b614f5f87838801614e2f565b93506040860135915080821115614f7557600080fd5b50614f8286828701614e2f565b9150509250925092565b600082614f9b57614f9b6149b1565b500490565b600080600080600060a08688031215614fb857600080fd5b8551614fc38161420a565b6020870151909550614fd48161420a565b6040870151909450614fe581613e98565b6060870151909350614ff681613e98565b608087015190925067ffffffffffffffff81111561501357600080fd5b61501f888289016147c0565b9150509295509295909350565b60008060006060848603121561504157600080fd5b8351801515811461505157600080fd5b602085015190935061506281614020565b604085015190925061507381614020565b809150509250925092565b67ffffffffffffffff81811683821601908082111561491457614914614888565b815167ffffffffffffffff168152610140810160208301516150d9602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516150f1604084018263ffffffff169052565b50606083015160608301526080830151615123608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a083015161514360a08401826bffffffffffffffffffffffff169052565b5060c083015161516360c08401826bffffffffffffffffffffffff169052565b5060e083015161518360e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151e88285018b614129565b915083820360808501526151fc828a614129565b915060ff881660a085015283820360c08501526152198288613e21565b90861660e08501528381036101008501529050613d148185613e21565b86815260c06020820152600061524f60c0830188613e21565b82810360408401526152618188613e21565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156152ba57600080fd5b82516152c58161451d565b60208401519092506142528161420a565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a0810160078310615342577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620059f5380380620059f5833981016040819052620000349162000444565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006169350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000222919062000554565b985098509850985098509850985098509850600085136200025a576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160601b038a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e805461ffff19169091179055600f829055517f5dafb6dc181e59e476f118ac3f41ca1f23fbd444b37caa205d04e5b1260b258690620003fd908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160601b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200042957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200045a57600080fd5b620004658462000411565b602085810151919450906001600160401b03808211156200048557600080fd5b818701915087601f8301126200049a57600080fd5b815181811115620004af57620004af6200042e565b604051601f8201601f19908116603f01168101908382118183101715620004da57620004da6200042e565b816040528281528a86848701011115620004f357600080fd5b600093505b82841015620005175784840186015181850187015292850192620004f8565b6000868483010152809750505050505050620005366040850162000411565b90509250925092565b805163ffffffff811681146200042957600080fd5b60008060008060008060008060006101208a8c0312156200057457600080fd5b6200057f8a6200053f565b98506200058f60208b016200053f565b97506200059f60408b016200053f565b9650620005af60608b016200053f565b955060808a01519450620005c660a08b016200053f565b60c08b01519094506001600160601b0381168114620005e457600080fd5b60e08b015190935061ffff81168114620005fd57600080fd5b809250506101008a015190509295985092959850929598565b6080516153c362000632600039600061124f01526153c36000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063c3f909d411610097578063de9dfa4611610071578063de9dfa4614610492578063e1a82d6f146104a5578063e3d0e712146104e5578063f2fde38b146104f857600080fd5b8063c3f909d4146103a5578063d227d24514610477578063d328a91e1461048a57600080fd5b8063af1296d3116100c8578063af1296d31461036a578063afcb95d714610372578063b1dc65a41461039257600080fd5b80638cc6acce1461031d5780638da5cb5b146103305780639883c10d1461035857600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ad57806381f1b938146102c257806381ff7048146102ca57806385b214cf146102fa57600080fd5b806379ba50971461027f5780637f15e16614610287578063807560311461029a57600080fd5b8063466557181161018c5780634665571814610226578063533989871461025657806366316d8d1461026c57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004613e43565b61050b565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a9190613ee9565b60405180910390f35b6101c6610221366004613f1e565b610560565b61023961023436600461407a565b610602565b6040516bffffffffffffffffffffffff909116815260200161020a565b61025e610632565b60405161020a9291906141a1565b6101c661027a36600461424b565b6108e1565b6101c6610a5f565b6101c6610295366004613e43565b610b61565b6101c66102a8366004614284565b610bb1565b6102b5610c68565b60405161020a91906142d9565b6101fd610cd7565b6004546002546040805163ffffffff8085168252640100000000909404909316602084015282015260600161020a565b61030d6103083660046142ec565b610da8565b604051901515815260200161020a565b6101c661032b366004614305565b610f92565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6008545b60405190815260200161020a565b61035c610ff9565b60408051600181526000602082018190529181019190915260600161020a565b6101c66103a0366004614387565b6110dc565b610413600c54600d54600a54600e54600f5463ffffffff8086169664010000000087048216966c01000000000000000000000000810483169695680100000000000000009091049092169373ffffffffffffffffffffffffffffffffffffffff9092169261ffff9092169190565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61023961048536600461443e565b61180d565b6101fd6119d3565b6102396104a036600461407a565b611a2a565b6104b86104b33660046144ae565b611ac5565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b6101c66104f336600461459b565b611d07565b6101c6610506366004613f1e565b6126eb565b6105136126fc565b600081900361054e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601461055b828483614709565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061059b57503373ffffffffffffffffffffffffffffffffffffffff8216145b6105d1576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660009081526013602052604081206105ff91613d88565b50565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015610682573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526106c89190810190614888565b90506000815167ffffffffffffffff8111156106e6576106e6613f3b565b60405190808252806020026020018201604052801561071957816020015b60608152602001906001900390816107045790505b50905060005b82518110156108d7576013600084838151811061073e5761073e6148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461078b90614668565b90506000036107c6576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601360008483815181106107dc576107dc6148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461082990614668565b80601f016020809104026020016040519081016040528092919081815260200182805461085590614668565b80156108a25780601f10610877576101008083540402835291602001916108a2565b820191906000526020600020905b81548152906001019060200180831161088557829003601f168201915b50505050508282815181106108b9576108b96148bd565b602002602001018190525080806108cf9061491b565b91505061071f565b5090939092509050565b6108e961277f565b806bffffffffffffffffffffffff1660000361091f5750336000908152601060205260409020546bffffffffffffffffffffffff165b336000908152601060205260409020546bffffffffffffffffffffffff80831691161015610979576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260106020526040812080548392906109a69084906bffffffffffffffffffffffff16614953565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610a4257600080fd5b505af1158015610a56573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610ae5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610b696126fc565b6000819003610ba4576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601261055b828483614709565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610bfc5750610bdb33612918565b8015610bfc57503373ffffffffffffffffffffffffffffffffffffffff8416145b610c32576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601360205260409020610c62828483614709565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610ccd57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610ca2575b5050505050905090565b606060148054610ce690614668565b9050600003610d21576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60148054610d2e90614668565b80601f0160208091040260200160405190810160405280929190818152602001828054610d5a90614668565b8015610ccd5780601f10610d7c57610100808354040283529160200191610ccd565b820191906000526020600020905b815481529060010190602001808311610d8a57509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314610dfc576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e0840152600481015461010084015260050154610120830152610f0a5750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b60095473ffffffffffffffffffffffffffffffffffffffff163314610fe3576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610fec81612a2c565b8051602090910120600855565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611083573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110a79190614999565b509350509250508280156110c957506110c081426149e9565b8463ffffffff16105b156110d457600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161113291849163ffffffff851691908e908e9081908401838280828437600092019190915250612cf392505050565b611168576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461123d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610adc565b61124b8b8b8b8b8b8b612cfc565b60007f0000000000000000000000000000000000000000000000000000000000000000156112a85760028260200151836040015161128991906149fc565b6112939190614a44565b61129e9060016149fc565b60ff1690506112be565b60208201516112b89060016149fc565b60ff1690505b888114611327576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610adc565b888714611390576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610adc565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156113d3576113d3614a66565b60028111156113e4576113e4614a66565b905250905060028160200151600281111561140157611401614a66565b14801561144857506007816000015160ff1681548110611423576114236148bd565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610adc565b50505050506114bb613dc2565b6000808a8a6040516114ce929190614a95565b6040519081900381206114e5918e90602001614aa5565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117ef57600060018489846020811061154e5761154e6148bd565b61155b91901a601b6149fc565b8e8e8681811061156d5761156d6148bd565b905060200201358d8d87818110611586576115866148bd565b90506020020135604051600081526020016040526040516115c3949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115e5573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561166557611665614a66565b600281111561167657611676614a66565b905250925060018360200151600281111561169357611693614a66565b146116fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610adc565b8251600090879060ff16601f8110611714576117146148bd565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611796576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610adc565b8086846000015160ff16601f81106117b0576117b06148bd565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526117db6001866149fc565b945050806117e89061491b565b905061152f565b505050611800833383858e8e612daa565b5050505050505050505050565b6009546040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8716600482015263ffffffff8416602482015260009173ffffffffffffffffffffffffffffffffffffffff169081906310fc49c19060440160006040518083038186803b15801561188f57600080fd5b505afa1580156118a3573d6000803e3d6000fd5b50505050620f42408311156118e4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152509050600061197288888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610602915050565b905060006119b789898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611a2a915050565b90506119c5878784846130b3565b9a9950505050505050505050565b6060601280546119e290614668565b9050600003611a1d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60128054610d2e90614668565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611a9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611abe9190614ab9565b9392505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff163314611b1f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611b2c6060860186614ad6565b9050600003611b66576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060800160405280876020016020810190611b869190614b3b565b67ffffffffffffffff168152602090810190611ba490890189613f1e565b73ffffffffffffffffffffffffffffffffffffffff168152602001611bcf60e0890160c08a01614b58565b63ffffffff1681523a6020909101529050611c3b611bf06060880188614ad6565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611c359250505060a0890160808a01614b85565b83613215565b92975090955093509150611c526020870187613f1e565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c32611c9b60408b0160208c01614b3b565b611cab60608c0160408d01613f1e565b611cb860608d018d614ad6565b8d6080016020810190611ccb9190614b85565b8e60a001358f60c0016020810190611ce39190614b58565b604051611cf7989796959493929190614ba2565b60405180910390a3509193509193565b855185518560ff16601f831115611d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610adc565b60008111611de4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610adc565b818314611e72576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610adc565b611e7d816003614c48565b8311611ee5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610adc565b611eed6126fc565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f3490886137dd565b600654156120e957600654600090611f4e906001906149e9565b9050600060068281548110611f6557611f656148bd565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f9f57611f9f6148bd565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560068054919250908061201f5761201f614c5f565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061208857612088614c5f565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f34915050565b60005b81515181101561254e5760006005600084600001518481518110612112576121126148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215c5761215c614a66565b146121c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610adc565b6040805180820190915260ff821681526001602082015282518051600591600091859081106121f4576121f46148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561229557612295614a66565b0217905550600091506122a59050565b60056000846020015184815181106122bf576122bf6148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230957612309614a66565b14612370576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610adc565b6040805180820190915260ff8216815260208101600281525060056000846020015184815181106123a3576123a36148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561244457612444614a66565b021790555050825180516006925083908110612462576124626148bd565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160079190839081106124de576124de6148bd565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556125478161491b565b90506120ec565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff4381168202928317855590830481169360019390926000926125e0928692908216911617614c8e565b92506101000a81548163ffffffff021916908363ffffffff16021790555061263f4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516137fa565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05986126de988b98919763ffffffff909216969095919491939192614cab565b60405180910390a1611800565b6126f36126fc565b6105ff816138a5565b60005473ffffffffffffffffffffffffffffffffffffffff16331461277d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610adc565b565b6000612789610c68565b905080516000036127c6576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516011546000916127e5916bffffffffffffffffffffffff16614d31565b905060005b82518160ff1610156128b9578160106000858460ff1681518110612810576128106148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166128789190614d5c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080806128b190614d81565b9150506127ea565b5081516128c69082614da0565b601180546000906128e69084906bffffffffffffffffffffffff16614953565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015612966573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526129ac9190810190614888565b905060005b8151811015612a22578373ffffffffffffffffffffffffffffffffffffffff168282815181106129e3576129e36148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a10575060019392505050565b80612a1a8161491b565b9150506129b1565b5060009392505050565b600080600080600080600080600089806020019051810190612a4e9190614dd0565b98509850985098509850985098509850985060008513612a9d576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610adc565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526bffffffffffffffffffffffff8a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055600f829055517f5dafb6dc181e59e476f118ac3f41ca1f23fbd444b37caa205d04e5b1260b258690612cdf908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526bffffffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b60019392505050565b6000612d09826020614c48565b612d14856020614c48565b612d2088610144614e80565b612d2a9190614e80565b612d349190614e80565b612d3f906000614e80565b9050368114610a56576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610adc565b60608080612dba84860186614f13565b825192955090935091501580612dd257508151835114155b80612ddf57508051835114155b15612e16576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156130a7576000612e7a858381518110612e3957612e396148bd565b6020026020010151858481518110612e5357612e536148bd565b6020026020010151858581518110612e6d57612e6d6148bd565b602002602001015161399a565b90506000816006811115612e9057612e90614a66565b1480612ead57506001816006811115612eab57612eab614a66565b145b15612f0857848281518110612ec457612ec46148bd565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613094565b6002816006811115612f1c57612f1c614a66565b03612f6c57848281518110612f3357612f336148bd565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613094565b6003816006811115612f8057612f80614a66565b03612fd057848281518110612f9757612f976148bd565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613094565b6005816006811115612fe457612fe4614a66565b0361303457848281518110612ffb57612ffb6148bd565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a2613094565b600481600681111561304857613048614a66565b036130945784828151811061305f5761305f6148bd565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b508061309f8161491b565b915050612e19565b50505050505050505050565b6000806130be610ff9565b9050600081136130fd576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610adc565b600c5460009087906131339063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c8e565b61313d9190614c8e565b63ffffffff1690506000612710600c600301548861315b9190614c48565b6131659190614ff0565b61316f9088614e80565b90506000838361318784670de0b6b3a7640000614c48565b6131919190614c48565b61319b9190614ff0565b905060006131ba6bffffffffffffffffffffffff808916908a16614e80565b90506131d2816b033b2e3c9fd0803ce80000006149e9565b82111561320b576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119c58183614e80565b600e5460009081908190819061ffff9081169087161115613262576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061326e8887610602565b9050600061327c8988611a2a565b905060006132948860400151896060015185856130b3565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa158015613317573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261335d9190810190615004565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156133ee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134129190615090565b509150506bffffffffffffffffffffffff851661342f8385614953565b6bffffffffffffffffffffffff161015613475576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006134f4308e602001518f6000015185600161349291906150e2565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff166135e09190614c8e565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee54229061378d908490615103565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60006137e7610c68565b5111156137f6576137f661277f565b5050565b6000808a8a8a8a8a8a8a8a8a60405160200161381e99989796959493929190615205565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613924576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610adc565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613aa9576002915050611abe565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613b07610ff9565b905060008113613b46576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610adc565b600081613b5b3a670de0b6b3a7640000614c48565b613b659190614ff0565b9050600083610100015182613b7a9190614c48565b905060008460a0015182613b8e9190614d5c565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613bf6908f908f908f908c908b90339060040161529a565b60408051808303816000875af1158015613c14573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c38919061530b565b9092509050613c478186614d5c565b33600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601180549193909291613ca791859116614d5c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613d0d9190614d5c565b60c08d015160a08e0151613d21888d614d5c565b613d2b9190614d5c565b613d359190614d5c565b8760ff166006811115613d4a57613d4a614a66565b604051613d5b95949392919061533a565b60405180910390a28160ff166006811115613d7857613d78614a66565b9c9b505050505050505050505050565b508054613d9490614668565b6000825580601f10613da4575050565b601f0160209004906000526020600020908101906105ff9190613de1565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613df65760008155600101613de2565b5090565b60008083601f840112613e0c57600080fd5b50813567ffffffffffffffff811115613e2457600080fd5b602083019150836020828501011115613e3c57600080fd5b9250929050565b60008060208385031215613e5657600080fd5b823567ffffffffffffffff811115613e6d57600080fd5b613e7985828601613dfa565b90969095509350505050565b6000815180845260005b81811015613eab57602081850181015186830182015201613e8f565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611abe6020830184613e85565b73ffffffffffffffffffffffffffffffffffffffff811681146105ff57600080fd5b600060208284031215613f3057600080fd5b8135611abe81613efc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613fb157613fb1613f3b565b604052919050565b600082601f830112613fca57600080fd5b813567ffffffffffffffff811115613fe457613fe4613f3b565b61401560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f6a565b81815284602083860101111561402a57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff811681146105ff57600080fd5b8035610f8d81614047565b63ffffffff811681146105ff57600080fd5b60008082840360a081121561408e57600080fd5b833567ffffffffffffffff808211156140a657600080fd5b6140b287838801613fb9565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156140e457600080fd5b6040519250608083019150828210818311171561410357614103613f3b565b50604052602084013561411581614047565b8152604084013561412581613efc565b6020820152606084013561413881614068565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561419657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614164565b509495945050505050565b6040815260006141b46040830185614150565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614222577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614210838351613e85565b948601949250908501906001016141d6565b50909998505050505050505050565b6bffffffffffffffffffffffff811681146105ff57600080fd5b6000806040838503121561425e57600080fd5b823561426981613efc565b9150602083013561427981614231565b809150509250929050565b60008060006040848603121561429957600080fd5b83356142a481613efc565b9250602084013567ffffffffffffffff8111156142c057600080fd5b6142cc86828701613dfa565b9497909650939450505050565b602081526000611abe6020830184614150565b6000602082840312156142fe57600080fd5b5035919050565b60006020828403121561431757600080fd5b813567ffffffffffffffff81111561432e57600080fd5b61433a84828501613fb9565b949350505050565b60008083601f84011261435457600080fd5b50813567ffffffffffffffff81111561436c57600080fd5b6020830191508360208260051b8501011115613e3c57600080fd5b60008060008060008060008060e0898b0312156143a357600080fd5b606089018a8111156143b457600080fd5b8998503567ffffffffffffffff808211156143ce57600080fd5b6143da8c838d01613dfa565b909950975060808b01359150808211156143f357600080fd5b6143ff8c838d01614342565b909750955060a08b013591508082111561441857600080fd5b506144258b828c01614342565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561445657600080fd5b853561446181614047565b9450602086013567ffffffffffffffff81111561447d57600080fd5b61448988828901613dfa565b909550935050604086013561449d81614068565b949793965091946060013592915050565b6000602082840312156144c057600080fd5b813567ffffffffffffffff8111156144d757600080fd5b820160e08185031215611abe57600080fd5b600067ffffffffffffffff82111561450357614503613f3b565b5060051b60200190565b600082601f83011261451e57600080fd5b8135602061453361452e836144e9565b613f6a565b82815260059290921b8401810191818101908684111561455257600080fd5b8286015b8481101561457657803561456981613efc565b8352918301918301614556565b509695505050505050565b60ff811681146105ff57600080fd5b8035610f8d81614581565b60008060008060008060c087890312156145b457600080fd5b863567ffffffffffffffff808211156145cc57600080fd5b6145d88a838b0161450d565b975060208901359150808211156145ee57600080fd5b6145fa8a838b0161450d565b965061460860408a01614590565b9550606089013591508082111561461e57600080fd5b61462a8a838b01613fb9565b945061463860808a0161405d565b935060a089013591508082111561464e57600080fd5b5061465b89828a01613fb9565b9150509295509295509295565b600181811c9082168061467c57607f821691505b6020821081036146b5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561055b57600081815260208120601f850160051c810160208610156146e25750805b601f850160051c820191505b81811015614701578281556001016146ee565b505050505050565b67ffffffffffffffff83111561472157614721613f3b565b6147358361472f8354614668565b836146bb565b6000601f84116001811461478757600085156147515750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561481d565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147d657868501358255602094850194600190920191016147b6565b5086821015614811577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b600082601f83011261483557600080fd5b8151602061484561452e836144e9565b82815260059290921b8401810191818101908684111561486457600080fd5b8286015b8481101561457657805161487b81613efc565b8352918301918301614868565b60006020828403121561489a57600080fd5b815167ffffffffffffffff8111156148b157600080fd5b61433a84828501614824565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361494c5761494c6148ec565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614978576149786148ec565b5092915050565b805169ffffffffffffffffffff81168114610f8d57600080fd5b600080600080600060a086880312156149b157600080fd5b6149ba8661497f565b94506020860151935060408601519250606086015191506149dd6080870161497f565b90509295509295909350565b8181038181111561062c5761062c6148ec565b60ff818116838216019081111561062c5761062c6148ec565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a5757614a57614a15565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614acb57600080fd5b8151611abe81614231565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614b0b57600080fd5b83018035915067ffffffffffffffff821115614b2657600080fd5b602001915036819003821315613e3c57600080fd5b600060208284031215614b4d57600080fd5b8135611abe81614047565b600060208284031215614b6a57600080fd5b8135611abe81614068565b61ffff811681146105ff57600080fd5b600060208284031215614b9757600080fd5b8135611abe81614b75565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b808202811582820484141761062c5761062c6148ec565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614978576149786148ec565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cdb8184018a614150565b90508281036080840152614cef8189614150565b905060ff871660a084015282810360c0840152614d0c8187613e85565b905067ffffffffffffffff851660e0840152828103610100840152613d788185613e85565b60006bffffffffffffffffffffffff80841680614d5057614d50614a15565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614978576149786148ec565b600060ff821660ff8103614d9757614d976148ec565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614dc857614dc86148ec565b505092915050565b60008060008060008060008060006101208a8c031215614def57600080fd5b8951614dfa81614068565b60208b0151909950614e0b81614068565b60408b0151909850614e1c81614068565b60608b0151909750614e2d81614068565b60808b015160a08c01519197509550614e4581614068565b60c08b0151909450614e5681614231565b60e08b0151909350614e6781614b75565b809250506101008a015190509295985092959850929598565b8082018082111561062c5761062c6148ec565b600082601f830112614ea457600080fd5b81356020614eb461452e836144e9565b82815260059290921b84018101918181019086841115614ed357600080fd5b8286015b8481101561457657803567ffffffffffffffff811115614ef75760008081fd5b614f058986838b0101613fb9565b845250918301918301614ed7565b600080600060608486031215614f2857600080fd5b833567ffffffffffffffff80821115614f4057600080fd5b818601915086601f830112614f5457600080fd5b81356020614f6461452e836144e9565b82815260059290921b8401810191818101908a841115614f8357600080fd5b948201945b83861015614fa157853582529482019490820190614f88565b97505087013592505080821115614fb757600080fd5b614fc387838801614e93565b93506040860135915080821115614fd957600080fd5b50614fe686828701614e93565b9150509250925092565b600082614fff57614fff614a15565b500490565b600080600080600060a0868803121561501c57600080fd5b855161502781614231565b602087015190955061503881614231565b604087015190945061504981613efc565b606087015190935061505a81613efc565b608087015190925067ffffffffffffffff81111561507757600080fd5b61508388828901614824565b9150509295509295909350565b6000806000606084860312156150a557600080fd5b835180151581146150b557600080fd5b60208501519093506150c681614047565b60408501519092506150d781614047565b809150509250925092565b67ffffffffffffffff818116838216019080821115614978576149786148ec565b815167ffffffffffffffff1681526101408101602083015161513d602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615155604084018263ffffffff169052565b50606083015160608301526080830151615187608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a08301516151a760a08401826bffffffffffffffffffffffff169052565b5060c08301516151c760c08401826bffffffffffffffffffffffff169052565b5060e08301516151e760e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b16604085015281606085015261524c8285018b614150565b91508382036080850152615260828a614150565b915060ff881660a085015283820360c085015261527d8288613e85565b90861660e08501528381036101008501529050613d788185613e85565b86815260c0602082015260006152b360c0830188613e85565b82810360408401526152c58188613e85565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b6000806040838503121561531e57600080fd5b825161532981614581565b602084015190925061427981614231565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a08101600783106153a6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -602,28 +602,16 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SendRequest( return _FunctionsCoordinator.Contract.SendRequest(&_FunctionsCoordinator.TransactOpts, request) } -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setConfig", config) +func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetConfig(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { + return _FunctionsCoordinator.contract.Transact(opts, "setConfig", _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetConfig(config []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig(&_FunctionsCoordinator.TransactOpts, config) +func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetConfig(_signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.SetConfig(&_FunctionsCoordinator.TransactOpts, _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) } -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetConfig(config []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig(&_FunctionsCoordinator.TransactOpts, config) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetConfig0(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setConfig0", _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetConfig0(_signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig0(&_FunctionsCoordinator.TransactOpts, _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetConfig0(_signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig0(&_FunctionsCoordinator.TransactOpts, _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) +func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetConfig(_signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.SetConfig(&_FunctionsCoordinator.TransactOpts, _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) } func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetDONPublicKey(opts *bind.TransactOpts, donPublicKey []byte) (*types.Transaction, error) { @@ -686,6 +674,18 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) Transmit(rep return _FunctionsCoordinator.Contract.Transmit(&_FunctionsCoordinator.TransactOpts, reportContext, report, rs, ss, rawVs) } +func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { + return _FunctionsCoordinator.contract.Transact(opts, "updateConfig", config) +} + +func (_FunctionsCoordinator *FunctionsCoordinatorSession) UpdateConfig(config []byte) (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.UpdateConfig(&_FunctionsCoordinator.TransactOpts, config) +} + +func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) UpdateConfig(config []byte) (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.UpdateConfig(&_FunctionsCoordinator.TransactOpts, config) +} + type FunctionsCoordinatorBillingEndIterator struct { Event *FunctionsCoordinatorBillingEnd @@ -946,8 +946,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseBillingStart(log return event, nil } -type FunctionsCoordinatorConfigSetIterator struct { - Event *FunctionsCoordinatorConfigSet +type FunctionsCoordinatorConfigChangedIterator struct { + Event *FunctionsCoordinatorConfigChanged contract *bind.BoundContract event string @@ -958,7 +958,7 @@ type FunctionsCoordinatorConfigSetIterator struct { fail error } -func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { +func (it *FunctionsCoordinatorConfigChangedIterator) Next() bool { if it.fail != nil { return false @@ -967,7 +967,7 @@ func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigSet) + it.Event = new(FunctionsCoordinatorConfigChanged) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -982,7 +982,7 @@ func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigSet) + it.Event = new(FunctionsCoordinatorConfigChanged) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -997,16 +997,16 @@ func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { } } -func (it *FunctionsCoordinatorConfigSetIterator) Error() error { +func (it *FunctionsCoordinatorConfigChangedIterator) Error() error { return it.fail } -func (it *FunctionsCoordinatorConfigSetIterator) Close() error { +func (it *FunctionsCoordinatorConfigChangedIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsCoordinatorConfigSet struct { +type FunctionsCoordinatorConfigChanged struct { MaxCallbackGasLimit uint32 FeedStalenessSeconds uint32 GasOverheadBeforeCallback uint32 @@ -1018,6 +1018,131 @@ type FunctionsCoordinatorConfigSet struct { Raw types.Log } +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigChangedIterator, error) { + + logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigChanged") + if err != nil { + return nil, err + } + return &FunctionsCoordinatorConfigChangedIterator{contract: _FunctionsCoordinator.contract, event: "ConfigChanged", logs: logs, sub: sub}, nil +} + +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigChanged) (event.Subscription, error) { + + logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "ConfigChanged") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsCoordinatorConfigChanged) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigChanged", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigChanged(log types.Log) (*FunctionsCoordinatorConfigChanged, error) { + event := new(FunctionsCoordinatorConfigChanged) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigChanged", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FunctionsCoordinatorConfigSetIterator struct { + Event *FunctionsCoordinatorConfigSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsCoordinatorConfigSet) + 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(FunctionsCoordinatorConfigSet) + 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 *FunctionsCoordinatorConfigSetIterator) Error() error { + return it.fail +} + +func (it *FunctionsCoordinatorConfigSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsCoordinatorConfigSet struct { + PreviousConfigBlockNumber uint32 + ConfigDigest [32]byte + ConfigCount uint64 + Signers []common.Address + Transmitters []common.Address + F uint8 + OnchainConfig []byte + OffchainConfigVersion uint64 + OffchainConfig []byte + Raw types.Log +} + func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) { logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigSet") @@ -1324,8 +1449,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInsufficientGasP return event, nil } -type FunctionsCoordinatorInvalidRequestIDIterator struct { - Event *FunctionsCoordinatorInvalidRequestID +type FunctionsCoordinatorInsufficientSubscriptionBalanceIterator struct { + Event *FunctionsCoordinatorInsufficientSubscriptionBalance contract *bind.BoundContract event string @@ -1336,7 +1461,7 @@ type FunctionsCoordinatorInvalidRequestIDIterator struct { fail error } -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { +func (it *FunctionsCoordinatorInsufficientSubscriptionBalanceIterator) Next() bool { if it.fail != nil { return false @@ -1345,7 +1470,7 @@ func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInvalidRequestID) + it.Event = new(FunctionsCoordinatorInsufficientSubscriptionBalance) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1360,7 +1485,7 @@ func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInvalidRequestID) + it.Event = new(FunctionsCoordinatorInsufficientSubscriptionBalance) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1375,42 +1500,42 @@ func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { } } -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Error() error { +func (it *FunctionsCoordinatorInsufficientSubscriptionBalanceIterator) Error() error { return it.fail } -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Close() error { +func (it *FunctionsCoordinatorInsufficientSubscriptionBalanceIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsCoordinatorInvalidRequestID struct { +type FunctionsCoordinatorInsufficientSubscriptionBalance struct { RequestId [32]byte Raw types.Log } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInsufficientSubscriptionBalance(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientSubscriptionBalanceIterator, error) { var requestIdRule []interface{} for _, requestIdItem := range requestId { requestIdRule = append(requestIdRule, requestIdItem) } - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InvalidRequestID", requestIdRule) + logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InsufficientSubscriptionBalance", requestIdRule) if err != nil { return nil, err } - return &FunctionsCoordinatorInvalidRequestIDIterator{contract: _FunctionsCoordinator.contract, event: "InvalidRequestID", logs: logs, sub: sub}, nil + return &FunctionsCoordinatorInsufficientSubscriptionBalanceIterator{contract: _FunctionsCoordinator.contract, event: "InsufficientSubscriptionBalance", logs: logs, sub: sub}, nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInsufficientSubscriptionBalance(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientSubscriptionBalance, requestId [][32]byte) (event.Subscription, error) { var requestIdRule []interface{} for _, requestIdItem := range requestId { requestIdRule = append(requestIdRule, requestIdItem) } - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InvalidRequestID", requestIdRule) + logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InsufficientSubscriptionBalance", requestIdRule) if err != nil { return nil, err } @@ -1420,8 +1545,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInvalidRequestID select { case log := <-logs: - event := new(FunctionsCoordinatorInvalidRequestID) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", log); err != nil { + event := new(FunctionsCoordinatorInsufficientSubscriptionBalance) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientSubscriptionBalance", log); err != nil { return err } event.Raw = log @@ -1442,17 +1567,17 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInvalidRequestID }), nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) { - event := new(FunctionsCoordinatorInvalidRequestID) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", log); err != nil { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInsufficientSubscriptionBalance(log types.Log) (*FunctionsCoordinatorInsufficientSubscriptionBalance, error) { + event := new(FunctionsCoordinatorInsufficientSubscriptionBalance) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientSubscriptionBalance", log); err != nil { return nil, err } event.Raw = log return event, nil } -type FunctionsCoordinatorOCRConfigSetIterator struct { - Event *FunctionsCoordinatorOCRConfigSet +type FunctionsCoordinatorInvalidRequestIDIterator struct { + Event *FunctionsCoordinatorInvalidRequestID contract *bind.BoundContract event string @@ -1463,7 +1588,7 @@ type FunctionsCoordinatorOCRConfigSetIterator struct { fail error } -func (it *FunctionsCoordinatorOCRConfigSetIterator) Next() bool { +func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { if it.fail != nil { return false @@ -1472,7 +1597,7 @@ func (it *FunctionsCoordinatorOCRConfigSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOCRConfigSet) + it.Event = new(FunctionsCoordinatorInvalidRequestID) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1487,7 +1612,7 @@ func (it *FunctionsCoordinatorOCRConfigSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOCRConfigSet) + it.Event = new(FunctionsCoordinatorInvalidRequestID) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1502,40 +1627,42 @@ func (it *FunctionsCoordinatorOCRConfigSetIterator) Next() bool { } } -func (it *FunctionsCoordinatorOCRConfigSetIterator) Error() error { +func (it *FunctionsCoordinatorInvalidRequestIDIterator) Error() error { return it.fail } -func (it *FunctionsCoordinatorOCRConfigSetIterator) Close() error { +func (it *FunctionsCoordinatorInvalidRequestIDIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsCoordinatorOCRConfigSet struct { - PreviousConfigBlockNumber uint32 - ConfigDigest [32]byte - ConfigCount uint64 - Signers []common.Address - Transmitters []common.Address - F uint8 - OnchainConfig []byte - OffchainConfigVersion uint64 - OffchainConfig []byte - Raw types.Log +type FunctionsCoordinatorInvalidRequestID struct { + RequestId [32]byte + Raw types.Log } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterOCRConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorOCRConfigSetIterator, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) { - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "OCRConfigSet") + var requestIdRule []interface{} + for _, requestIdItem := range requestId { + requestIdRule = append(requestIdRule, requestIdItem) + } + + logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InvalidRequestID", requestIdRule) if err != nil { return nil, err } - return &FunctionsCoordinatorOCRConfigSetIterator{contract: _FunctionsCoordinator.contract, event: "OCRConfigSet", logs: logs, sub: sub}, nil + return &FunctionsCoordinatorInvalidRequestIDIterator{contract: _FunctionsCoordinator.contract, event: "InvalidRequestID", logs: logs, sub: sub}, nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOCRConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOCRConfigSet) (event.Subscription, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) { + + var requestIdRule []interface{} + for _, requestIdItem := range requestId { + requestIdRule = append(requestIdRule, requestIdItem) + } - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "OCRConfigSet") + logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InvalidRequestID", requestIdRule) if err != nil { return nil, err } @@ -1545,8 +1672,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOCRConfigSet(opt select { case log := <-logs: - event := new(FunctionsCoordinatorOCRConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OCRConfigSet", log); err != nil { + event := new(FunctionsCoordinatorInvalidRequestID) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", log); err != nil { return err } event.Raw = log @@ -1567,9 +1694,9 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOCRConfigSet(opt }), nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOCRConfigSet(log types.Log) (*FunctionsCoordinatorOCRConfigSet, error) { - event := new(FunctionsCoordinatorOCRConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OCRConfigSet", log); err != nil { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) { + event := new(FunctionsCoordinatorInvalidRequestID) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", log); err != nil { return nil, err } event.Raw = log @@ -2391,16 +2518,18 @@ func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (gene return _FunctionsCoordinator.ParseBillingEnd(log) case _FunctionsCoordinator.abi.Events["BillingStart"].ID: return _FunctionsCoordinator.ParseBillingStart(log) + case _FunctionsCoordinator.abi.Events["ConfigChanged"].ID: + return _FunctionsCoordinator.ParseConfigChanged(log) case _FunctionsCoordinator.abi.Events["ConfigSet"].ID: return _FunctionsCoordinator.ParseConfigSet(log) case _FunctionsCoordinator.abi.Events["CostExceedsCommitment"].ID: return _FunctionsCoordinator.ParseCostExceedsCommitment(log) case _FunctionsCoordinator.abi.Events["InsufficientGasProvided"].ID: return _FunctionsCoordinator.ParseInsufficientGasProvided(log) + case _FunctionsCoordinator.abi.Events["InsufficientSubscriptionBalance"].ID: + return _FunctionsCoordinator.ParseInsufficientSubscriptionBalance(log) case _FunctionsCoordinator.abi.Events["InvalidRequestID"].ID: return _FunctionsCoordinator.ParseInvalidRequestID(log) - case _FunctionsCoordinator.abi.Events["OCRConfigSet"].ID: - return _FunctionsCoordinator.ParseOCRConfigSet(log) case _FunctionsCoordinator.abi.Events["OracleRequest"].ID: return _FunctionsCoordinator.ParseOracleRequest(log) case _FunctionsCoordinator.abi.Events["OracleResponse"].ID: @@ -2427,8 +2556,12 @@ func (FunctionsCoordinatorBillingStart) Topic() common.Hash { return common.HexToHash("0x9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee5422") } +func (FunctionsCoordinatorConfigChanged) Topic() common.Hash { + return common.HexToHash("0x5dafb6dc181e59e476f118ac3f41ca1f23fbd444b37caa205d04e5b1260b2586") +} + func (FunctionsCoordinatorConfigSet) Topic() common.Hash { - return common.HexToHash("0xd681a73ddd7a4a82d52cdb418659eac88c00e7c03b10ec82af1f6da8345e55c5") + return common.HexToHash("0x1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05") } func (FunctionsCoordinatorCostExceedsCommitment) Topic() common.Hash { @@ -2439,12 +2572,12 @@ func (FunctionsCoordinatorInsufficientGasProvided) Topic() common.Hash { return common.HexToHash("0x357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e0") } -func (FunctionsCoordinatorInvalidRequestID) Topic() common.Hash { - return common.HexToHash("0xa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be") +func (FunctionsCoordinatorInsufficientSubscriptionBalance) Topic() common.Hash { + return common.HexToHash("0xb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d") } -func (FunctionsCoordinatorOCRConfigSet) Topic() common.Hash { - return common.HexToHash("0x324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a09") +func (FunctionsCoordinatorInvalidRequestID) Topic() common.Hash { + return common.HexToHash("0xa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be") } func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { @@ -2520,9 +2653,7 @@ type FunctionsCoordinatorInterface interface { SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) - SetConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) - - SetConfig0(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) + SetConfig(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) SetDONPublicKey(opts *bind.TransactOpts, donPublicKey []byte) (*types.Transaction, error) @@ -2534,6 +2665,8 @@ type FunctionsCoordinatorInterface interface { Transmit(opts *bind.TransactOpts, reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) + UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) + FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingEndIterator, error) WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingEnd, requestId [][32]byte) (event.Subscription, error) @@ -2546,6 +2679,12 @@ type FunctionsCoordinatorInterface interface { ParseBillingStart(log types.Log) (*FunctionsCoordinatorBillingStart, error) + FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigChangedIterator, error) + + WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigChanged) (event.Subscription, error) + + ParseConfigChanged(log types.Log) (*FunctionsCoordinatorConfigChanged, error) + FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigSet) (event.Subscription, error) @@ -2564,17 +2703,17 @@ type FunctionsCoordinatorInterface interface { ParseInsufficientGasProvided(log types.Log) (*FunctionsCoordinatorInsufficientGasProvided, error) - FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) + FilterInsufficientSubscriptionBalance(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientSubscriptionBalanceIterator, error) - WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) + WatchInsufficientSubscriptionBalance(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientSubscriptionBalance, requestId [][32]byte) (event.Subscription, error) - ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) + ParseInsufficientSubscriptionBalance(log types.Log) (*FunctionsCoordinatorInsufficientSubscriptionBalance, error) - FilterOCRConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorOCRConfigSetIterator, error) + FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) - WatchOCRConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOCRConfigSet) (event.Subscription, error) + WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) - ParseOCRConfigSet(log types.Log) (*FunctionsCoordinatorOCRConfigSet, error) + ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) FilterOracleRequest(opts *bind.FilterOpts, requestId [][32]byte, requestingContract []common.Address) (*FunctionsCoordinatorOracleRequestIterator, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index d258c7b8eb7..8cd21cf945d 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -31,8 +31,8 @@ var ( ) var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b506040516200612b3803806200612b833981016040819052620000449162000451565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620006cb9350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026491906200054e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052601180546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002dc916012919086019062000323565b509050507f02c673f957dfd44004b8ef12f6c1858031d7bd50b3918b09fb6f39bffede86a483838360405162000315939291906200065a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003c75791602002820160005b838211156200039357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200034d565b8015620003c55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000393565b505b50620003d5929150620003d9565b5090565b5b80821115620003d55760008155600101620003da565b805161ffff811681146200040357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000449576200044962000408565b604052919050565b600080600080608085870312156200046857600080fd5b6200047385620003f0565b9350602062000484818701620003f0565b60408701519094506001600160a01b0381168114620004a257600080fd5b60608701519093506001600160401b0380821115620004c057600080fd5b818801915088601f830112620004d557600080fd5b815181811115620004ea57620004ea62000408565b620004fe601f8201601f191685016200041e565b915080825289848285010111156200051557600080fd5b60005b818110156200053557838101850151838201860152840162000518565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056457600080fd5b83516001600160601b03811681146200057c57600080fd5b602085810151919450906001600160e01b0319811681146200059d57600080fd5b60408601519093506001600160401b0380821115620005bb57600080fd5b818701915087601f830112620005d057600080fd5b815181811115620005e557620005e562000408565b8060051b9150620005f88483016200041e565b818152918301840191848101908a8411156200061357600080fd5b938501935b838510156200064a578451925063ffffffff83168314620006395760008081fd5b828252938501939085019062000618565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bd57845163ffffffff168352938301939183019160010162000699565b509098975050505050505050565b615a5080620006db6000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610768578063eb523d6c1461077b578063f2fde38b1461078e57600080fd5b8063c4614d611461072f578063d7ae1d3014610742578063e72f6e301461075557600080fd5b8063b5643858116100c8578063b5643858146106fd578063b734c0f414610710578063badc3eb61461071857600080fd5b8063aab396bd146106cc578063b187bd26146106f257600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c769614610682578063a4c0ed36146106a6578063a9c9a918146106b957600080fd5b80639883c10d1461065f5780639f87fad714610667578063a21a23e41461067a57600080fd5b8063823597401161017657806382359740146106215780638da5cb5b146106345780638fde53171461065757600080fd5b80637341c10c1461060657806379ba50971461061957600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461052a5780636a6df79b146105bf57806371ec28ac146105f757600080fd5b806366316d8d146104dd57806366419970146104f0578063665871ec1461051757600080fd5b806354fd4d501161022f57806354fd4d501461045c57806355fedefa146104b35780635c975abb146104c657600080fd5b80633fd67e0514610402578063461d27621461043b57600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103d4578063385de9ae146103dc5780633e871e4d146103ef57600080fd5b80631ded3b36146103ab5780632a905ccc146103be57600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461036957600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc3660046149ec565b6107a1565b005b610301610311366004614a2b565b610821565b610301610324366004614a70565b610910565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103609190614b0b565b6103016103b9366004614b1e565b61091a565b6011546bffffffffffffffffffffffff16610347565b61030161094b565b6103016103ea366004614b91565b610970565b6103016103fd366004614cf1565b610b54565b610415610410366004614e52565b610e6e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610360565b61044e610449366004614f06565b611192565b604051908152602001610360565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610360565b61044e6104c13660046149ec565b6111f6565b60005460ff165b6040519015158152602001610360565b6103016104eb366004614f88565b61121a565b600b5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610360565b610301610525366004614fb4565b611446565b610597610538366004615029565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610360565b6105d26105cd366004615061565b61182f565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610360565b60405160648152602001610360565b610301610614366004614a2b565b611842565b6103016119ef565b61030161062f3660046149ec565b611b11565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d2565b610301611c59565b600a5461044e565b610301610675366004614a2b565b611cdd565b6104fe6120e7565b6106956106903660046149ec565b61229f565b6040516103609594939291906150d7565b6103016106b436600461512c565b61238d565b6105d26106c7366004615186565b6125b4565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761044e565b60005460ff166104cd565b61030161070b36600461519f565b6125c1565b6103016126da565b610720612950565b604051610360939291906151ba565b61039e61073d366004614b91565b612a2b565b610301610750366004614a2b565b612a40565b61030161076336600461521b565b612a99565b6104cd6107763660046149ec565b612cae565b610301610789366004615186565b612cb9565b61030161079c36600461521b565b612f42565b6107a9612f53565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610813576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61081d8282612f5b565b5050565b61082a8261332d565b6108326133e6565b61083a613423565b67ffffffffffffffff82166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff82811691161461081d5767ffffffffffffffff82166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61081d828261351d565b610922612f53565b61092b8261363d565b67ffffffffffffffff9091166000908152600c6020526040902060040155565b6109536136a6565b60005460ff16156109685761096661372c565b565b6109666137a9565b6109786136a6565b6000610985846000613804565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109af5750600a54610a23565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156109fc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a209190615236565b90505b8383604051610a3392919061524f565b60405180910390208103610a73576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610ada9062010000900461ffff164361528e565b9052600086815260066020908152604090912082518155908201516001820190610b049082615342565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b4590879084908890889061545c565b60405180910390a15050505050565b610b5c6136a6565b8151815181141580610b6e5750600881115b15610ba5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610ce1576000848260ff1681518110610bca57610bca6154b7565b602002602001015190506000848360ff1681518110610beb57610beb6154b7565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c56575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c8d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccc576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b50508080610cd9906154e6565b915050610ba8565b50600754600090610cfc9062010000900461ffff164361528e565b604080516060810182528681526020808201879052918101839052865192935091600391610d2e918391890190614835565b506020828101518051610d47926001850192019061487c565b506040820151816002015590505060005b84518160ff161015610e67577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610d9a57610d9a6154b7565b602002602001015160026000888560ff1681518110610dbb57610dbb6154b7565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e0757610e076154b7565b602002602001015185604051610e4d949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610e5f816154e6565b915050610d58565b5050505050565b600080610e796133e6565b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e08301523314610f87576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff16610fb0576002925050611187565b8060c00151816060015163ffffffff16610fca919061528e565b5a1015610fdb576003925050611187565b80608001516bffffffffffffffffffffffff16611001826060015163ffffffff16613906565b61100b9088615505565b868360e0015161101b9190615535565b6110259190615535565b6bffffffffffffffffffffffff161115611043576004925050611187565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018490556004820184905560059091018054909116905560608301519083015191945084916110e4918c918c918c916139a8565b80519091506110f45760016110f7565b60005b9350600061111e8360400151846080015185602001518660e001518c87602001518d613b26565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b0520836020015189898760000151611167578e611169565b8f5b6040516111799493929190615561565b60405180910390a351925050505b965096945050505050565b600061119c613da3565b6111a46133e6565b6111eb8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e109050565b979650505050505050565b67ffffffffffffffff81166000908152600c60205260408120600401545b92915050565b6112226133e6565b806bffffffffffffffffffffffff1660000361126a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff808316911610156112c4576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906112f19084906bffffffffffffffffffffffff166155b7565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff1661134891906155b7565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af11580156113ec573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061141091906155dc565b61081d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61144e6133e6565b60005b8181101561182a57600083838381811061146d5761146d6154b7565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e085015290935090506115568161363d565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff163381146115c2576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260a00151421015611600576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561166f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061169391906155dc565b1561181257608084015167ffffffffffffffff84166000908152600c6020819052604090912080549091906116e79084906c0100000000000000000000000090046bffffffffffffffffffffffff166155b7565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff808816845293529020805460019260099161176c91859169010000000000000000009004166155f9565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b505050505080806118229061561a565b915050611451565b505050565b600061183b8383613804565b9392505050565b61184b8261332d565b6118536133e6565b61185b613423565b67ffffffffffffffff82166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c016118d0576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611917575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600d6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610904565b60015473ffffffffffffffffffffffffffffffffffffffff163314611a70576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cc3565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b196133e6565b611b21613423565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff9182169116338114611bb0576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cc3565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611c616136a6565b600954431015611c9d576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b611ce68261332d565b611cee6133e6565b611cf6613423565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611dc6576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e1b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600c6020908152604080832060030180548251818502810185019093528083529192909190830182828015611e9657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e6b575b50505050509050600060018251611ead9190615652565b905060005b825181101561204b578473ffffffffffffffffffffffffffffffffffffffff16838281518110611ee457611ee46154b7565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612039576000838381518110611f1b57611f1b6154b7565b6020026020010151905080600c60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206003018381548110611f6157611f616154b7565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600c90915260409020600301805480611fdb57611fdb615665565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061204b565b806120438161561a565b915050611eb2565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600d6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60006120f16133e6565b6120f9613423565b600b805467ffffffffffffffff1690600061211383615694565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160c081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815260a0870186905297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915596516002840180549190921697169690961790955592518051929650909450919261224f92600385019291019061487c565b5060a0919091015160049091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b60008060008060606122b08661363d565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff918216985092169550909183018282801561237d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612352575b5050505050905091939590929450565b6123956133e6565b601054610100900473ffffffffffffffffffffffffffffffffffffffff1633146123eb576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612425576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612433828401846149ec565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff1661249f576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff16918691906124d68385615535565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff1661252d9190615535565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8828784612594919061528e565b6040805192835260208301919091520160405180910390a2505050505050565b6000611214826000613804565b6125c96136a6565b60075461ffff808316620100009092041603612611576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff9081169082161115612655576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff62010000909104811680835290841660208301529091820190612688904361528e565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b6126e26136a6565b60055443101561271e576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff16600161273b91906156bb565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff938416021790819055760100000000000000000000000000000000000000000000900416156127cc57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff8216101561294d57600060036000018260ff16815481106127f7576127f76154b7565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff8616908110612846576128466154b7565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a15050508080612945906154e6565b9150506127cf565b50565b600060608060036002015460036000016003600101818054806020026020016040519081016040528092919081815260200182805480156129b057602002820191906000526020600020905b81548152602001906001019080831161299c575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612a1957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129ee575b50505050509050925092509250909192565b6060612a3884848461422c565b949350505050565b612a498261332d565b612a516133e6565b612a59613423565b612a62826142fb565b15610813576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612aa1612f53565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612b15573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b399190615236565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115612b9d576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cc3565b8181101561182a576000612bb18284615652565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af1158015612c33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c5791906155dc565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b6000611214826142fb565b612cc16136a6565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612cfb906152a1565b80601f0160208091040260200160405190810160405280929190818152602001828054612d27906152a1565b8015612d745780601f10612d4957610100808354040283529160200191612d74565b820191906000526020600020905b815481529060010190602001808311612d5757829003601f168201915b5050505050815260200160028201548152505090508060400151431015612dc7576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612dec57612dd9816020015161444c565b6020808201518051910120600a55612e94565b612df7826000613804565b73ffffffffffffffffffffffffffffffffffffffff1663354497aa82602001516040518263ffffffff1660e01b8152600401612e339190614b0b565b600060405180830381600087803b158015612e4d57600080fd5b505af1925050508015612e5e575060015b612e94576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff166001612eb191906156bb565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612f369286926156d6565b60405180910390a15050565b612f4a6136a6565b61294d81614547565b6109666136a6565b612f636133e6565b67ffffffffffffffff82166000908152600c60209081526040808320815160c08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff90811682850152600283015416606082015260038201805484518187028101870190955280855291949293608086019390929083018282801561304457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613019575b505050918352505060049190910154602090910152805190915060005b82608001515181101561310757600d600084608001518381518110613088576130886154b7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055806130ff8161561a565b915050613061565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff000000000000000000000000000000000000000090811690915560028201805490911690559061318d60038301826148f6565b6004820160009055505080600b60088282829054906101000a90046bffffffffffffffffffffffff166131c091906155b7565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af1158015613265573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061328991906155dc565b6132bf576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680613397576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461081d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff1615610966576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61344e7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613804565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af11580156134bc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134e091906155dc565b1515600003610966576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cc3565b67ffffffffffffffff82166000908152600c6020526040812060040154601254911a90811061357d576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cc3565b6012805460ff8316908110613594576135946154b7565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561182a576012805460ff83169081106135e4576135e46154b7565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cc3565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1661294d576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cc3565b613734614642565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6137b1613da3565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861377f3390565b6000816138435760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16801561383d579050611214565b506138d1565b60005b60035460ff821610156138cf576003805460ff831690811061386a5761386a6154b7565b906000526020600020015484036138bd576004805460ff8316908110613892576138926154b7565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112149050565b806138c7816154e6565b915050613846565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cc3565b60006bffffffffffffffffffffffff8211156139a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cc3565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b906139eb908990899089906024016156fe565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a611388811015613aa857600080fd5b611388810390508660408204820311613ac057600080fd5b853b613acb57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613b4584613906565b613b4f9086615505565b9050600081613b5e8886615535565b613b689190615535565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c909152928320805492975093945084939291613bbf918591166155b7565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613bf99190615535565b336000908152600e602052604081208054909190613c269084906bffffffffffffffffffffffff16615535565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b94509092613c6d91859116615535565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff16613cec91906155b7565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613d7091859169010000000000000000009004166155f9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60005460ff1615610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cc3565b6000613e1b8561363d565b613e2533866146ae565b613e2f858361351d565b6000613e3b8888613804565b6040805160e08101825233815267ffffffffffffffff891660208083018290526000828152600c808352858220600181015473ffffffffffffffffffffffffffffffffffffffff90811687890152606087018e905261ffff8d166080880152948352925260049182015460a085015263ffffffff891660c085015293517fe1a82d6f0000000000000000000000000000000000000000000000000000000081529495509293849384939287169263e1a82d6f92613ef89201615729565b6080604051808303816000875af1158015613f17573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f3b91906157bc565b92975090945092509050613f50338a8561474a565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff1681526020018242613fd0919061528e565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e604051614216969594939291906157fa565b60405180910390a4505050509695505050505050565b6060600080808061423f8688018861585e565b9350935093509350600061425889600187878787613e10565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156142ee57818160208110614297576142976154b7565b1a60f81b8782815181106142ad576142ad6154b7565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806142e68161561a565b91505061427c565b5050505050509392505050565b67ffffffffffffffff81166000908152600c602090815260408083206003018054825181850281018501909352808352849383018282801561437357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614348575b5050505050905060005b8151811015614442576000600d600084848151811061439e5761439e6154b7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461442f57506001949350505050565b508061443a8161561a565b91505061437d565b5060009392505050565b60008060008380602001905181019061446591906158cf565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052601180547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145109160129190860190614914565b509050507f02c673f957dfd44004b8ef12f6c1858031d7bd50b3918b09fb6f39bffede86a4838383604051612ca0939291906159b8565b3373ffffffffffffffffffffffffffffffffffffffff8216036145c6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cc3565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cc3565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff1661081d576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b67ffffffffffffffff82166000908152600c6020819052604090912080548392906147949084906c0100000000000000000000000090046bffffffffffffffffffffffff16615535565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261480a9284929004166155f9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614870579160200282015b82811115614870578251825591602001919060010190614855565b506139a49291506149ba565b828054828255906000526020600020908101928215614870579160200282015b8281111561487057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061489c565b508054600082559060005260206000209081019061294d91906149ba565b828054828255906000526020600020906007016008900481019282156148705791602002820160005b8382111561498157835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261493d565b80156149b15782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614981565b50506139a49291505b5b808211156139a457600081556001016149bb565b803567ffffffffffffffff811681146149e757600080fd5b919050565b6000602082840312156149fe57600080fd5b61183b826149cf565b803573ffffffffffffffffffffffffffffffffffffffff811681146149e757600080fd5b60008060408385031215614a3e57600080fd5b614a47836149cf565b9150614a5560208401614a07565b90509250929050565b63ffffffff8116811461294d57600080fd5b60008060408385031215614a8357600080fd5b614a8c836149cf565b91506020830135614a9c81614a5e565b809150509250929050565b6000815180845260005b81811015614acd57602081850181015186830182015201614ab1565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b60208152600061183b6020830184614aa7565b60008060408385031215614b3157600080fd5b614b3a836149cf565b946020939093013593505050565b60008083601f840112614b5a57600080fd5b50813567ffffffffffffffff811115614b7257600080fd5b602083019150836020828501011115614b8a57600080fd5b9250929050565b600080600060408486031215614ba657600080fd5b83359250602084013567ffffffffffffffff811115614bc457600080fd5b614bd086828701614b48565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614c5357614c53614bdd565b604052919050565b600067ffffffffffffffff821115614c7557614c75614bdd565b5060051b60200190565b600082601f830112614c9057600080fd5b81356020614ca5614ca083614c5b565b614c0c565b82815260059290921b84018101918181019086841115614cc457600080fd5b8286015b84811015614ce657614cd981614a07565b8352918301918301614cc8565b509695505050505050565b60008060408385031215614d0457600080fd5b823567ffffffffffffffff80821115614d1c57600080fd5b818501915085601f830112614d3057600080fd5b81356020614d40614ca083614c5b565b82815260059290921b84018101918181019089841115614d5f57600080fd5b948201945b83861015614d7d57853582529482019490820190614d64565b96505086013592505080821115614d9357600080fd5b50614da085828601614c7f565b9150509250929050565b600082601f830112614dbb57600080fd5b813567ffffffffffffffff811115614dd557614dd5614bdd565b614e0660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614c0c565b818152846020838601011115614e1b57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461294d57600080fd5b60008060008060008060c08789031215614e6b57600080fd5b86359550602087013567ffffffffffffffff80821115614e8a57600080fd5b614e968a838b01614daa565b96506040890135915080821115614eac57600080fd5b50614eb989828a01614daa565b9450506060870135614eca81614e38565b92506080870135614eda81614e38565b9150614ee860a08801614a07565b90509295509295509295565b803561ffff811681146149e757600080fd5b60008060008060008060a08789031215614f1f57600080fd5b614f28876149cf565b9550602087013567ffffffffffffffff811115614f4457600080fd5b614f5089828a01614b48565b9096509450614f63905060408801614ef4565b92506060870135614f7381614a5e565b80925050608087013590509295509295509295565b60008060408385031215614f9b57600080fd5b614fa483614a07565b91506020830135614a9c81614e38565b60008060208385031215614fc757600080fd5b823567ffffffffffffffff80821115614fdf57600080fd5b818501915085601f830112614ff357600080fd5b81358181111561500257600080fd5b8660208260051b850101111561501757600080fd5b60209290920196919550909350505050565b6000806040838503121561503c57600080fd5b61504583614a07565b9150614a55602084016149cf565b801515811461294d57600080fd5b6000806040838503121561507457600080fd5b823591506020830135614a9c81615053565b600081518084526020808501945080840160005b838110156150cc57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161509a565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a0608082018190526000906111eb90830184615086565b6000806000806060858703121561514257600080fd5b61514b85614a07565b935060208501359250604085013567ffffffffffffffff81111561516e57600080fd5b61517a87828801614b48565b95989497509550505050565b60006020828403121561519857600080fd5b5035919050565b6000602082840312156151b157600080fd5b61183b82614ef4565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156151fb578451835293830193918301916001016151df565b5050848103604086015261520f8187615086565b98975050505050505050565b60006020828403121561522d57600080fd5b61183b82614a07565b60006020828403121561524857600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112145761121461525f565b600181811c908216806152b557607f821691505b6020821081036152ee577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561182a57600081815260208120601f850160051c8101602086101561531b5750805b601f850160051c820191505b8181101561533a57828155600101615327565b505050505050565b815167ffffffffffffffff81111561535c5761535c614bdd565b6153708161536a84546152a1565b846152f4565b602080601f8311600181146153c3576000841561538d5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561533a565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015615410578886015182559484019460019091019084016153f1565b508582101561544c57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036154fc576154fc61525f565b60010192915050565b6bffffffffffffffffffffffff81811683821602808216919082811461552d5761552d61525f565b505092915050565b6bffffffffffffffffffffffff81811683821601908082111561555a5761555a61525f565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006155ad6080830184614aa7565b9695505050505050565b6bffffffffffffffffffffffff82811682821603908082111561555a5761555a61525f565b6000602082840312156155ee57600080fd5b815161183b81615053565b67ffffffffffffffff81811683821601908082111561555a5761555a61525f565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361564b5761564b61525f565b5060010190565b818103818111156112145761121461525f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036156b1576156b161525f565b6001019392505050565b61ffff81811683821601908082111561555a5761555a61525f565b8381528260208201526060604082015260006156f56060830184614aa7565b95945050505050565b8381526060602082015260006157176060830185614aa7565b82810360408401526155ad8185614aa7565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015267ffffffffffffffff602085015116604084015280604085015116606084015250606083015160e06080840152615788610100840182614aa7565b905061ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b600080600080608085870312156157d257600080fd5b8451935060208501516157e481614e38565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261583b60c0830186614aa7565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b6000806000806080858703121561587457600080fd5b61587d856149cf565b9350602085013567ffffffffffffffff81111561589957600080fd5b6158a587828801614daa565b9350506158b460408601614ef4565b915060608501356158c481614a5e565b939692955090935050565b6000806000606084860312156158e457600080fd5b83516158ef81614e38565b809350506020808501517fffffffff000000000000000000000000000000000000000000000000000000008116811461592757600080fd5b604086015190935067ffffffffffffffff81111561594457600080fd5b8501601f8101871361595557600080fd5b8051615963614ca082614c5b565b81815260059190911b8201830190838101908983111561598257600080fd5b928401925b828410156159a957835161599a81614a5e565b82529284019290840190615987565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615a3557845163ffffffff1683529383019391830191600101615a13565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b50604051620061ae380380620061ae833981016040819052620000449162000451565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620006cb9350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026491906200054e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052601180546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002dc916012919086019062000323565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000315939291906200065a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003c75791602002820160005b838211156200039357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200034d565b8015620003c55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000393565b505b50620003d5929150620003d9565b5090565b5b80821115620003d55760008155600101620003da565b805161ffff811681146200040357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000449576200044962000408565b604052919050565b600080600080608085870312156200046857600080fd5b6200047385620003f0565b9350602062000484818701620003f0565b60408701519094506001600160a01b0381168114620004a257600080fd5b60608701519093506001600160401b0380821115620004c057600080fd5b818801915088601f830112620004d557600080fd5b815181811115620004ea57620004ea62000408565b620004fe601f8201601f191685016200041e565b915080825289848285010111156200051557600080fd5b60005b818110156200053557838101850151838201860152840162000518565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056457600080fd5b83516001600160601b03811681146200057c57600080fd5b602085810151919450906001600160e01b0319811681146200059d57600080fd5b60408601519093506001600160401b0380821115620005bb57600080fd5b818701915087601f830112620005d057600080fd5b815181811115620005e557620005e562000408565b8060051b9150620005f88483016200041e565b818152918301840191848101908a8411156200061357600080fd5b938501935b838510156200064a578451925063ffffffff83168314620006395760008081fd5b828252938501939085019062000618565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bd57845163ffffffff168352938301939183019160010162000699565b509098975050505050505050565b615ad380620006db6000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610768578063eb523d6c1461077b578063f2fde38b1461078e57600080fd5b8063c4614d611461072f578063d7ae1d3014610742578063e72f6e301461075557600080fd5b8063b5643858116100c8578063b5643858146106fd578063b734c0f414610710578063badc3eb61461071857600080fd5b8063aab396bd146106cc578063b187bd26146106f257600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c769614610682578063a4c0ed36146106a6578063a9c9a918146106b957600080fd5b80639883c10d1461065f5780639f87fad714610667578063a21a23e41461067a57600080fd5b8063823597401161017657806382359740146106215780638da5cb5b146106345780638fde53171461065757600080fd5b80637341c10c1461060657806379ba50971461061957600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461052a5780636a6df79b146105bf57806371ec28ac146105f757600080fd5b806366316d8d146104dd57806366419970146104f0578063665871ec1461051757600080fd5b806354fd4d501161022f57806354fd4d501461045c57806355fedefa146104b35780635c975abb146104c657600080fd5b80633fd67e0514610402578063461d27621461043b57600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103d4578063385de9ae146103dc5780633e871e4d146103ef57600080fd5b80631ded3b36146103ab5780632a905ccc146103be57600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461036957600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc366004614a6f565b6107a1565b005b610301610311366004614aae565b610821565b610301610324366004614af3565b610910565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103609190614b8e565b6103016103b9366004614ba1565b61091a565b6011546bffffffffffffffffffffffff16610347565b61030161094b565b6103016103ea366004614c14565b610970565b6103016103fd366004614d74565b610b54565b610415610410366004614ed5565b610e6e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610360565b61044e610449366004614f89565b611215565b604051908152602001610360565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610360565b61044e6104c1366004614a6f565b611279565b60005460ff165b6040519015158152602001610360565b6103016104eb36600461500b565b61129d565b600b5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610360565b610301610525366004615037565b6114c9565b6105976105383660046150ac565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610360565b6105d26105cd3660046150e4565b6118b2565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610360565b60405160648152602001610360565b610301610614366004614aae565b6118c5565b610301611a72565b61030161062f366004614a6f565b611b94565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d2565b610301611cdc565b600a5461044e565b610301610675366004614aae565b611d60565b6104fe61216a565b610695610690366004614a6f565b612322565b60405161036095949392919061515a565b6103016106b43660046151af565b612410565b6105d26106c7366004615209565b612637565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761044e565b60005460ff166104cd565b61030161070b366004615222565b612644565b61030161275d565b6107206129d3565b6040516103609392919061523d565b61039e61073d366004614c14565b612aae565b610301610750366004614aae565b612ac3565b61030161076336600461529e565b612b1c565b6104cd610776366004614a6f565b612d31565b610301610789366004615209565b612d3c565b61030161079c36600461529e565b612fc5565b6107a9612fd6565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610813576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61081d8282612fde565b5050565b61082a826133b0565b610832613469565b61083a6134a6565b67ffffffffffffffff82166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff82811691161461081d5767ffffffffffffffff82166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61081d82826135a0565b610922612fd6565b61092b826136c0565b67ffffffffffffffff9091166000908152600c6020526040902060040155565b610953613729565b60005460ff1615610968576109666137af565b565b61096661382c565b610978613729565b6000610985846000613887565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109af5750600a54610a23565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156109fc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a2091906152b9565b90505b8383604051610a339291906152d2565b60405180910390208103610a73576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610ada9062010000900461ffff1643615311565b9052600086815260066020908152604090912082518155908201516001820190610b0490826153c5565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b459087908490889088906154df565b60405180910390a15050505050565b610b5c613729565b8151815181141580610b6e5750600881115b15610ba5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610ce1576000848260ff1681518110610bca57610bca61553a565b602002602001015190506000848360ff1681518110610beb57610beb61553a565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c56575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c8d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccc576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b50508080610cd990615569565b915050610ba8565b50600754600090610cfc9062010000900461ffff1643615311565b604080516060810182528681526020808201879052918101839052865192935091600391610d2e9183918901906148b8565b506020828101518051610d4792600185019201906148ff565b506040820151816002015590505060005b84518160ff161015610e67577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610d9a57610d9a61553a565b602002602001015160026000888560ff1681518110610dbb57610dbb61553a565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e0757610e0761553a565b602002602001015185604051610e4d949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610e5f81615569565b915050610d58565b5050505050565b600080610e79613469565b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e08301523314610f87576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff16610fb057600292505061120a565b8060c00151816060015163ffffffff16610fca9190615311565b5a1015610fdb57600392505061120a565b60408082015167ffffffffffffffff166000908152600c602052205460608201516bffffffffffffffffffffffff9091169061101c9063ffffffff16613989565b6110269088615588565b868360e0015161103691906155b8565b61104091906155b8565b6bffffffffffffffffffffffff16111561105e57600492505061120a565b80608001516bffffffffffffffffffffffff16611084826060015163ffffffff16613989565b61108e9088615588565b868360e0015161109e91906155b8565b6110a891906155b8565b6bffffffffffffffffffffffff1611156110c657600592505061120a565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000090811690915560038201849055600482018490556005909101805490911690556060830151908301519194508491611167918c918c918c91613a2b565b805190915061117757600161117a565b60005b935060006111a18360400151846080015185602001518660e001518c87602001518d613ba9565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516111ea578e6111ec565b8f5b6040516111fc94939291906155e4565b60405180910390a351925050505b965096945050505050565b600061121f613e26565b611227613469565b61126e8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e939050565b979650505050505050565b67ffffffffffffffff81166000908152600c60205260408120600401545b92915050565b6112a5613469565b806bffffffffffffffffffffffff166000036112ed576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff80831691161015611347576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906113749084906bffffffffffffffffffffffff1661563a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff166113cb919061563a565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af115801561146f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611493919061565f565b61081d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114d1613469565b60005b818110156118ad5760008383838181106114f0576114f061553a565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e085015290935090506115d9816136c0565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16338114611645576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260a00151421015611683576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af11580156116f2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611716919061565f565b1561189557608084015167ffffffffffffffff84166000908152600c60208190526040909120805490919061176a9084906c0100000000000000000000000090046bffffffffffffffffffffffff1661563a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff80881684529352902080546001926009916117ef918591690100000000000000000090041661567c565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b505050505080806118a59061569d565b9150506114d4565b505050565b60006118be8383613887565b9392505050565b6118ce826133b0565b6118d6613469565b6118de6134a6565b67ffffffffffffffff82166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611953576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8616845290915290205460ff161561199a575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600d6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610904565b60015473ffffffffffffffffffffffffffffffffffffffff163314611af3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cc3565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b9c613469565b611ba46134a6565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff9182169116338114611c33576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cc3565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611ce4613729565b600954431015611d20576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b611d69826133b0565b611d71613469565b611d796134a6565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e49576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e9e576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600c6020908152604080832060030180548251818502810185019093528083529192909190830182828015611f1957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611eee575b50505050509050600060018251611f3091906156d5565b905060005b82518110156120ce578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f6757611f6761553a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120bc576000838381518110611f9e57611f9e61553a565b6020026020010151905080600c60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206003018381548110611fe457611fe461553a565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600c9091526040902060030180548061205e5761205e6156e8565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120ce565b806120c68161569d565b915050611f35565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600d6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000612174613469565b61217c6134a6565b600b805467ffffffffffffffff1690600061219683615717565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160c081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815260a0870186905297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff0000000000000000000000000000000000000000918216179091559651600284018054919092169716969096179095559251805192965090945091926122d29260038501929101906148ff565b5060a0919091015160049091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6000806000806060612333866136c0565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff918216985092169550909183018282801561240057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116123d5575b5050505050905091939590929450565b612418613469565b601054610100900473ffffffffffffffffffffffffffffffffffffffff16331461246e576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124a8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124b682840184614a6f565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff16612522576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff169186919061255983856155b8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff166125b091906155b8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126179190615311565b6040805192835260208301919091520160405180910390a2505050505050565b6000611297826000613887565b61264c613729565b60075461ffff808316620100009092041603612694576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff90811690821611156126d8576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff6201000090910481168083529084166020830152909182019061270b9043615311565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b612765613729565b6005544310156127a1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff1660016127be919061573e565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff9384160217908190557601000000000000000000000000000000000000000000009004161561284f57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff821610156129d057600060036000018260ff168154811061287a5761287a61553a565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff86169081106128c9576128c961553a565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a150505080806129c890615569565b915050612852565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a3357602002820191906000526020600020905b815481526020019060010190808311612a1f575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612a9c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a71575b50505050509050925092509250909192565b6060612abb8484846142af565b949350505050565b612acc826133b0565b612ad4613469565b612adc6134a6565b612ae58261437e565b15610813576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b24612fd6565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612b98573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bbc91906152b9565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115612c20576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cc3565b818110156118ad576000612c3482846156d5565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af1158015612cb6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cda919061565f565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112978261437e565b612d44613729565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612d7e90615324565b80601f0160208091040260200160405190810160405280929190818152602001828054612daa90615324565b8015612df75780601f10612dcc57610100808354040283529160200191612df7565b820191906000526020600020905b815481529060010190602001808311612dda57829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e4a576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612e6f57612e5c81602001516144cf565b6020808201518051910120600a55612f17565b612e7a826000613887565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612eb69190614b8e565b600060405180830381600087803b158015612ed057600080fd5b505af1925050508015612ee1575060015b612f17576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff166001612f34919061573e565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612fb9928692615759565b60405180910390a15050565b612fcd613729565b6129d0816145ca565b610966613729565b612fe6613469565b67ffffffffffffffff82166000908152600c60209081526040808320815160c08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff9081168285015260028301541660608201526003820180548451818702810187019095528085529194929360808601939092908301828280156130c757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161309c575b505050918352505060049190910154602090910152805190915060005b82608001515181101561318a57600d60008460800151838151811061310b5761310b61553a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055806131828161569d565b9150506130e4565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff00000000000000000000000000000000000000009081169091556002820180549091169055906132106003830182614979565b6004820160009055505080600b60088282829054906101000a90046bffffffffffffffffffffffff16613243919061563a565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af11580156132e8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061330c919061565f565b613342576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff168061341a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461081d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff1615610966576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6134d17fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613887565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561353f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613563919061565f565b1515600003610966576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cc3565b67ffffffffffffffff82166000908152600c6020526040812060040154601254911a908110613600576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cc3565b6012805460ff83169081106136175761361761553a565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff1611156118ad576012805460ff83169081106136675761366761553a565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cc3565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff166129d0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cc3565b6137b76146c5565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613834613e26565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138023390565b6000816138c65760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1680156138c0579050611297565b50613954565b60005b60035460ff82161015613952576003805460ff83169081106138ed576138ed61553a565b90600052602060002001548403613940576004805460ff83169081106139155761391561553a565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112979050565b8061394a81615569565b9150506138c9565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cc3565b60006bffffffffffffffffffffffff821115613a27576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cc3565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b90613a6e90899089908990602401615781565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a611388811015613b2b57600080fd5b611388810390508660408204820311613b4357600080fd5b853b613b4e57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613bc884613989565b613bd29086615588565b9050600081613be188866155b8565b613beb91906155b8565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c909152928320805492975093945084939291613c429185911661563a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613c7c91906155b8565b336000908152600e602052604081208054909190613ca99084906bffffffffffffffffffffffff166155b8565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b94509092613cf0918591166155b8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff16613d6f919061563a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613df3918591690100000000000000000090041661567c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60005460ff1615610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cc3565b6000613e9e856136c0565b613ea83386614731565b613eb285836135a0565b6000613ebe8888613887565b6040805160e08101825233815267ffffffffffffffff891660208083018290526000828152600c808352858220600181015473ffffffffffffffffffffffffffffffffffffffff90811687890152606087018e905261ffff8d166080880152948352925260049182015460a085015263ffffffff891660c085015293517fe1a82d6f0000000000000000000000000000000000000000000000000000000081529495509293849384939287169263e1a82d6f92613f7b92016157ac565b6080604051808303816000875af1158015613f9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613fbe919061583f565b92975090945092509050613fd3338a856147cd565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff16815260200182426140539190615311565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516142999695949392919061587d565b60405180910390a4505050509695505050505050565b606060008080806142c2868801886158e1565b935093509350935060006142db89600187878787613e93565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156143715781816020811061431a5761431a61553a565b1a60f81b8782815181106143305761433061553a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806143698161569d565b9150506142ff565b5050505050509392505050565b67ffffffffffffffff81166000908152600c60209081526040808320600301805482518185028101850190935280835284938301828280156143f657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116143cb575b5050505050905060005b81518110156144c5576000600d60008484815181106144215761442161553a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146144b257506001949350505050565b50806144bd8161569d565b915050614400565b5060009392505050565b6000806000838060200190518101906144e89190615952565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052601180547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145939160129190860190614997565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d2393929190615a3b565b3373ffffffffffffffffffffffffffffffffffffffff821603614649576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cc3565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cc3565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff1661081d576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b67ffffffffffffffff82166000908152600c6020819052604090912080548392906148179084906c0100000000000000000000000090046bffffffffffffffffffffffff166155b8565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261488d92849290041661567c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b8280548282559060005260206000209081019282156148f3579160200282015b828111156148f35782518255916020019190600101906148d8565b50613a27929150614a3d565b8280548282559060005260206000209081019282156148f3579160200282015b828111156148f357825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061491f565b50805460008255906000526020600020908101906129d09190614a3d565b828054828255906000526020600020906007016008900481019282156148f35791602002820160005b83821115614a0457835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026149c0565b8015614a345782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a04565b5050613a279291505b5b80821115613a275760008155600101614a3e565b803567ffffffffffffffff81168114614a6a57600080fd5b919050565b600060208284031215614a8157600080fd5b6118be82614a52565b803573ffffffffffffffffffffffffffffffffffffffff81168114614a6a57600080fd5b60008060408385031215614ac157600080fd5b614aca83614a52565b9150614ad860208401614a8a565b90509250929050565b63ffffffff811681146129d057600080fd5b60008060408385031215614b0657600080fd5b614b0f83614a52565b91506020830135614b1f81614ae1565b809150509250929050565b6000815180845260005b81811015614b5057602081850181015186830182015201614b34565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118be6020830184614b2a565b60008060408385031215614bb457600080fd5b614bbd83614a52565b946020939093013593505050565b60008083601f840112614bdd57600080fd5b50813567ffffffffffffffff811115614bf557600080fd5b602083019150836020828501011115614c0d57600080fd5b9250929050565b600080600060408486031215614c2957600080fd5b83359250602084013567ffffffffffffffff811115614c4757600080fd5b614c5386828701614bcb565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614cd657614cd6614c60565b604052919050565b600067ffffffffffffffff821115614cf857614cf8614c60565b5060051b60200190565b600082601f830112614d1357600080fd5b81356020614d28614d2383614cde565b614c8f565b82815260059290921b84018101918181019086841115614d4757600080fd5b8286015b84811015614d6957614d5c81614a8a565b8352918301918301614d4b565b509695505050505050565b60008060408385031215614d8757600080fd5b823567ffffffffffffffff80821115614d9f57600080fd5b818501915085601f830112614db357600080fd5b81356020614dc3614d2383614cde565b82815260059290921b84018101918181019089841115614de257600080fd5b948201945b83861015614e0057853582529482019490820190614de7565b96505086013592505080821115614e1657600080fd5b50614e2385828601614d02565b9150509250929050565b600082601f830112614e3e57600080fd5b813567ffffffffffffffff811115614e5857614e58614c60565b614e8960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614c8f565b818152846020838601011115614e9e57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129d057600080fd5b60008060008060008060c08789031215614eee57600080fd5b86359550602087013567ffffffffffffffff80821115614f0d57600080fd5b614f198a838b01614e2d565b96506040890135915080821115614f2f57600080fd5b50614f3c89828a01614e2d565b9450506060870135614f4d81614ebb565b92506080870135614f5d81614ebb565b9150614f6b60a08801614a8a565b90509295509295509295565b803561ffff81168114614a6a57600080fd5b60008060008060008060a08789031215614fa257600080fd5b614fab87614a52565b9550602087013567ffffffffffffffff811115614fc757600080fd5b614fd389828a01614bcb565b9096509450614fe6905060408801614f77565b92506060870135614ff681614ae1565b80925050608087013590509295509295509295565b6000806040838503121561501e57600080fd5b61502783614a8a565b91506020830135614b1f81614ebb565b6000806020838503121561504a57600080fd5b823567ffffffffffffffff8082111561506257600080fd5b818501915085601f83011261507657600080fd5b81358181111561508557600080fd5b8660208260051b850101111561509a57600080fd5b60209290920196919550909350505050565b600080604083850312156150bf57600080fd5b6150c883614a8a565b9150614ad860208401614a52565b80151581146129d057600080fd5b600080604083850312156150f757600080fd5b823591506020830135614b1f816150d6565b600081518084526020808501945080840160005b8381101561514f57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161511d565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061126e90830184615109565b600080600080606085870312156151c557600080fd5b6151ce85614a8a565b935060208501359250604085013567ffffffffffffffff8111156151f157600080fd5b6151fd87828801614bcb565b95989497509550505050565b60006020828403121561521b57600080fd5b5035919050565b60006020828403121561523457600080fd5b6118be82614f77565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561527e57845183529383019391830191600101615262565b505084810360408601526152928187615109565b98975050505050505050565b6000602082840312156152b057600080fd5b6118be82614a8a565b6000602082840312156152cb57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115611297576112976152e2565b600181811c9082168061533857607f821691505b602082108103615371577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156118ad57600081815260208120601f850160051c8101602086101561539e5750805b601f850160051c820191505b818110156153bd578281556001016153aa565b505050505050565b815167ffffffffffffffff8111156153df576153df614c60565b6153f3816153ed8454615324565b84615377565b602080601f83116001811461544657600084156154105750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556153bd565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561549357888601518255948401946001909101908401615474565b50858210156154cf57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361557f5761557f6152e2565b60010192915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155b0576155b06152e2565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156155dd576155dd6152e2565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006156306080830184614b2a565b9695505050505050565b6bffffffffffffffffffffffff8281168282160390808211156155dd576155dd6152e2565b60006020828403121561567157600080fd5b81516118be816150d6565b67ffffffffffffffff8181168382160190808211156155dd576155dd6152e2565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036156ce576156ce6152e2565b5060010190565b81810381811115611297576112976152e2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff808316818103615734576157346152e2565b6001019392505050565b61ffff8181168382160190808211156155dd576155dd6152e2565b8381528260208201526060604082015260006157786060830184614b2a565b95945050505050565b83815260606020820152600061579a6060830185614b2a565b82810360408401526156308185614b2a565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015267ffffffffffffffff602085015116604084015280604085015116606084015250606083015160e0608084015261580b610100840182614b2a565b905061ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b6000806000806080858703121561585557600080fd5b84519350602085015161586781614ebb565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c060608301526158be60c0830186614b2a565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b600080600080608085870312156158f757600080fd5b61590085614a52565b9350602085013567ffffffffffffffff81111561591c57600080fd5b61592887828801614e2d565b93505061593760408601614f77565b9150606085013561594781614ae1565b939692955090935050565b60008060006060848603121561596757600080fd5b835161597281614ebb565b809350506020808501517fffffffff00000000000000000000000000000000000000000000000000000000811681146159aa57600080fd5b604086015190935067ffffffffffffffff8111156159c757600080fd5b8501601f810187136159d857600080fd5b80516159e6614d2382614cde565b81815260059190911b82018301908381019089831115615a0557600080fd5b928401925b82841015615a2c578351615a1d81614ae1565b82529284019290840190615a0a565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615ab857845163ffffffff1683529383019391830191600101615a96565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -899,8 +899,8 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) ValidateProposedContra return _FunctionsRouter.Contract.ValidateProposedContracts(&_FunctionsRouter.TransactOpts, id, data) } -type FunctionsRouterConfigProposedIterator struct { - Event *FunctionsRouterConfigProposed +type FunctionsRouterConfigChangedIterator struct { + Event *FunctionsRouterConfigChanged contract *bind.BoundContract event string @@ -911,7 +911,7 @@ type FunctionsRouterConfigProposedIterator struct { fail error } -func (it *FunctionsRouterConfigProposedIterator) Next() bool { +func (it *FunctionsRouterConfigChangedIterator) Next() bool { if it.fail != nil { return false @@ -920,7 +920,7 @@ func (it *FunctionsRouterConfigProposedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsRouterConfigProposed) + it.Event = new(FunctionsRouterConfigChanged) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -935,7 +935,7 @@ func (it *FunctionsRouterConfigProposedIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsRouterConfigProposed) + it.Event = new(FunctionsRouterConfigChanged) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -950,34 +950,34 @@ func (it *FunctionsRouterConfigProposedIterator) Next() bool { } } -func (it *FunctionsRouterConfigProposedIterator) Error() error { +func (it *FunctionsRouterConfigChangedIterator) Error() error { return it.fail } -func (it *FunctionsRouterConfigProposedIterator) Close() error { +func (it *FunctionsRouterConfigChangedIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsRouterConfigProposed struct { - Id [32]byte - FromHash [32]byte - ToBytes []byte - Raw types.Log +type FunctionsRouterConfigChanged struct { + AdminFee *big.Int + HandleOracleFulfillmentSelector [4]byte + MaxCallbackGasLimits []uint32 + Raw types.Log } -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) { +func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) { - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigProposed") + logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigChanged") if err != nil { return nil, err } - return &FunctionsRouterConfigProposedIterator{contract: _FunctionsRouter.contract, event: "ConfigProposed", logs: logs, sub: sub}, nil + return &FunctionsRouterConfigChangedIterator{contract: _FunctionsRouter.contract, event: "ConfigChanged", logs: logs, sub: sub}, nil } -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) { +func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigChanged) (event.Subscription, error) { - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigProposed") + logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigChanged") if err != nil { return nil, err } @@ -987,8 +987,8 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigProposed(opts *bind. select { case log := <-logs: - event := new(FunctionsRouterConfigProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", log); err != nil { + event := new(FunctionsRouterConfigChanged) + if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigChanged", log); err != nil { return err } event.Raw = log @@ -1009,17 +1009,17 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigProposed(opts *bind. }), nil } -func (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) { - event := new(FunctionsRouterConfigProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", log); err != nil { +func (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigChanged(log types.Log) (*FunctionsRouterConfigChanged, error) { + event := new(FunctionsRouterConfigChanged) + if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigChanged", log); err != nil { return nil, err } event.Raw = log return event, nil } -type FunctionsRouterConfigSetIterator struct { - Event *FunctionsRouterConfigSet +type FunctionsRouterConfigProposedIterator struct { + Event *FunctionsRouterConfigProposed contract *bind.BoundContract event string @@ -1030,7 +1030,7 @@ type FunctionsRouterConfigSetIterator struct { fail error } -func (it *FunctionsRouterConfigSetIterator) Next() bool { +func (it *FunctionsRouterConfigProposedIterator) Next() bool { if it.fail != nil { return false @@ -1039,7 +1039,7 @@ func (it *FunctionsRouterConfigSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsRouterConfigSet) + it.Event = new(FunctionsRouterConfigProposed) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1054,7 +1054,7 @@ func (it *FunctionsRouterConfigSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsRouterConfigSet) + it.Event = new(FunctionsRouterConfigProposed) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -1069,34 +1069,34 @@ func (it *FunctionsRouterConfigSetIterator) Next() bool { } } -func (it *FunctionsRouterConfigSetIterator) Error() error { +func (it *FunctionsRouterConfigProposedIterator) Error() error { return it.fail } -func (it *FunctionsRouterConfigSetIterator) Close() error { +func (it *FunctionsRouterConfigProposedIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsRouterConfigSet struct { - AdminFee *big.Int - HandleOracleFulfillmentSelector [4]byte - MaxCallbackGasLimits []uint32 - Raw types.Log +type FunctionsRouterConfigProposed struct { + Id [32]byte + FromHash [32]byte + ToBytes []byte + Raw types.Log } -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsRouterConfigSetIterator, error) { +func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) { - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigSet") + logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigProposed") if err != nil { return nil, err } - return &FunctionsRouterConfigSetIterator{contract: _FunctionsRouter.contract, event: "ConfigSet", logs: logs, sub: sub}, nil + return &FunctionsRouterConfigProposedIterator{contract: _FunctionsRouter.contract, event: "ConfigProposed", logs: logs, sub: sub}, nil } -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigSet) (event.Subscription, error) { +func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) { - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigSet") + logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigProposed") if err != nil { return nil, err } @@ -1106,8 +1106,8 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigSet(opts *bind.Watch select { case log := <-logs: - event := new(FunctionsRouterConfigSet) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigSet", log); err != nil { + event := new(FunctionsRouterConfigProposed) + if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", log); err != nil { return err } event.Raw = log @@ -1128,9 +1128,9 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigSet(opts *bind.Watch }), nil } -func (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigSet(log types.Log) (*FunctionsRouterConfigSet, error) { - event := new(FunctionsRouterConfigSet) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigSet", log); err != nil { +func (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) { + event := new(FunctionsRouterConfigProposed) + if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", log); err != nil { return nil, err } event.Raw = log @@ -3564,10 +3564,10 @@ type GetSubscription struct { func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { + case _FunctionsRouter.abi.Events["ConfigChanged"].ID: + return _FunctionsRouter.ParseConfigChanged(log) case _FunctionsRouter.abi.Events["ConfigProposed"].ID: return _FunctionsRouter.ParseConfigProposed(log) - case _FunctionsRouter.abi.Events["ConfigSet"].ID: - return _FunctionsRouter.ParseConfigSet(log) case _FunctionsRouter.abi.Events["ConfigUpdated"].ID: return _FunctionsRouter.ParseConfigUpdated(log) case _FunctionsRouter.abi.Events["ContractProposed"].ID: @@ -3612,12 +3612,12 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig } } -func (FunctionsRouterConfigProposed) Topic() common.Hash { - return common.HexToHash("0x0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf") +func (FunctionsRouterConfigChanged) Topic() common.Hash { + return common.HexToHash("0xe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca") } -func (FunctionsRouterConfigSet) Topic() common.Hash { - return common.HexToHash("0x02c673f957dfd44004b8ef12f6c1858031d7bd50b3918b09fb6f39bffede86a4") +func (FunctionsRouterConfigProposed) Topic() common.Hash { + return common.HexToHash("0x0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf") } func (FunctionsRouterConfigUpdated) Topic() common.Hash { @@ -3791,17 +3791,17 @@ type FunctionsRouterInterface interface { ValidateProposedContracts(opts *bind.TransactOpts, id [32]byte, data []byte) (*types.Transaction, error) - FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) + FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) - WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) + WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigChanged) (event.Subscription, error) - ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) + ParseConfigChanged(log types.Log) (*FunctionsRouterConfigChanged, error) - FilterConfigSet(opts *bind.FilterOpts) (*FunctionsRouterConfigSetIterator, error) + FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) - WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigSet) (event.Subscription, error) + WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) - ParseConfigSet(log types.Log) (*FunctionsRouterConfigSet, error) + ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsRouterConfigUpdatedIterator, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index f567e9b464b..1130f9bf93f 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,10 +1,10 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a03725d15d3405d68bec96237a2155435a752c659c2b13b0746003f45e621ded +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 1020231df9e071930530d1d1e495bc0914311247633652fa1e2ce29e4bce39df functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin ea01c8210316c767b4925731a55ee03bfe5cf04f1c4663aa3115bbc36b94d01f -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin e6187f1a9f935fa78351bb39bbb1f1717594cdbeb0b82fe17755dea9a8992896 -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 0297b5b61baf49527475de73422943b31adc470398cc670c053b6d037a63b727 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b4c8fce90c7aaa68d1af53442e6c44505d090636a18e50b58c0d16d50dcf35aa +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 94c169b225c7d42ac104fa5be7609aaeaff3a18f00857654ab1c72208efb12c7 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From a5fad89751f734c2048444b79dee3987162f97a2 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Fri, 28 Jul 2023 10:52:51 -0400 Subject: [PATCH 025/270] small improvements for VL contracts (#9961) --- .../src/v0.8/tests/VerifiableLoadBase.sol | 23 +++++++------------ .../tests/VerifiableLoadLogTriggerUpkeep.sol | 2 +- .../tests/VerifiableLoadMercuryUpkeep.sol | 2 +- .../src/v0.8/tests/VerifiableLoadUpkeep.sol | 2 +- ...ifiable_load_log_trigger_upkeep_wrapper.go | 4 ++-- .../verifiable_load_mercury_upkeep_wrapper.go | 8 +++---- .../verifiable_load_upkeep_wrapper.go | 8 +++---- ...rapper-dependency-versions-do-not-edit.txt | 6 ++--- 8 files changed, 24 insertions(+), 31 deletions(-) diff --git a/contracts/src/v0.8/tests/VerifiableLoadBase.sol b/contracts/src/v0.8/tests/VerifiableLoadBase.sol index 78c345b87a5..8bb8a76df4a 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadBase.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadBase.sol @@ -5,15 +5,7 @@ import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/Enumerabl import "../dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol"; import {ArbSys} from "../dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; import "../dev/automation/2_1/AutomationRegistrar2_1.sol"; - -struct LogTriggerConfig { - address contractAddress; - uint8 filterSelector; // denotes which topics apply to filter ex 000, 101, 111...only last 3 bits apply - bytes32 topic0; - bytes32 topic1; - bytes32 topic2; - bytes32 topic3; -} +import {LogTriggerConfig} from "../dev/automation/2_1/AutomationUtils2_1.sol"; abstract contract VerifiableLoadBase is ConfirmedOwner { error IndexOutOfRange(); @@ -25,7 +17,8 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { using EnumerableSet for EnumerableSet.UintSet; ArbSys internal constant ARB_SYS = ArbSys(0x0000000000000000000000000000000000000064); - bytes32 public constant emittedSig = 0x97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf08; //keccak256(LogEmitted(uint256,uint256,address)) + //bytes32 public constant emittedSig = 0x97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf08; //keccak256(LogEmitted(uint256,uint256,address)) + bytes32 public immutable emittedSig = LogEmitted.selector; mapping(uint256 => uint256) public lastTopUpBlocks; mapping(uint256 => uint256) public intervals; @@ -59,15 +52,15 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { uint16 public immutable BUCKET_SIZE = 100; /** - * @param registrarAddress a registrar address - * @param useArb if this contract will use arbitrum block number + * @param _registrar a automation registrar 2.1 address + * @param _useArb if this contract will use arbitrum block number */ - constructor(address registrarAddress, bool useArb) ConfirmedOwner(msg.sender) { - registrar = AutomationRegistrar2_1(registrarAddress); + constructor(AutomationRegistrar2_1 _registrar, bool _useArb) ConfirmedOwner(msg.sender) { + registrar = _registrar; (address registryAddress, ) = registrar.getConfig(); registry = IKeeperRegistryMaster(payable(address(registryAddress))); linkToken = registrar.LINK(); - useArbitrumBlockNum = useArb; + useArbitrumBlockNum = _useArb; } receive() external payable { diff --git a/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol index 49f9158075f..2b95b26e069 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol @@ -13,7 +13,7 @@ contract VerifiableLoadLogTriggerUpkeep is VerifiableLoadBase, FeedLookupCompati string public feedParamKey = "feedIdHex"; string public timeParamKey = "blockNumber"; - constructor(address _registrar, bool _useArb) VerifiableLoadBase(_registrar, _useArb) {} + constructor(AutomationRegistrar2_1 _registrar, bool _useArb) VerifiableLoadBase(_registrar, _useArb) {} function setFeedsHex(string[] memory newFeeds) external { feedsHex = newFeeds; diff --git a/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol index 3cb834033f0..d772daccf28 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol @@ -13,7 +13,7 @@ contract VerifiableLoadMercuryUpkeep is VerifiableLoadBase, FeedLookupCompatible string public constant feedParamKey = "feedIdHex"; string public constant timeParamKey = "blockNumber"; - constructor(address registrarAddress, bool useArb) VerifiableLoadBase(registrarAddress, useArb) {} + constructor(AutomationRegistrar2_1 _registrar, bool useArb) VerifiableLoadBase(_registrar, useArb) {} function setFeedsHex(string[] memory newFeeds) external { feedsHex = newFeeds; diff --git a/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol index e3c2e300db9..cc4b914b3d9 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol @@ -4,7 +4,7 @@ pragma solidity 0.8.16; import "./VerifiableLoadBase.sol"; contract VerifiableLoadUpkeep is VerifiableLoadBase { - constructor(address registrarAddress, bool useArb) VerifiableLoadBase(registrarAddress, useArb) {} + constructor(AutomationRegistrar2_1 _registrar, bool useArb) VerifiableLoadBase(_registrar, useArb) {} function checkUpkeep(bytes calldata checkData) external returns (bool, bytes memory) { uint256 startGas = gasleft(); diff --git a/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go index e031ecc6b1a..327d33a4d48 100644 --- a/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go @@ -42,8 +42,8 @@ type Log struct { } var VerifiableLoadLogTriggerUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x6005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460a052610180604052604261010081815260c091829190620051ff61012039815260200160405180608001604052806042815260200162005241604291399052620000759060169060026200037e565b506040805180820190915260098152680cccacac892c890caf60bb1b6020820152601790620000a59082620004fa565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152601890620000d79082620004fa565b50348015620000e557600080fd5b5060405162005283380380620052838339810160408190526200010891620005dc565b81813380600081620001615760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000194576200019481620002d3565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001f1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200021791906200061f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200027d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002a3919062000650565b601280546001600160a01b0319166001600160a01b03929092169190911790555015156080525062000677915050565b336001600160a01b038216036200032d5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000158565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003c9579160200282015b82811115620003c95782518290620003b89082620004fa565b50916020019190600101906200039f565b50620003d7929150620003db565b5090565b80821115620003d7576000620003f28282620003fc565b50600101620003db565b5080546200040a906200046b565b6000825580601f106200041b575050565b601f0160209004906000526020600020908101906200043b91906200043e565b50565b5b80821115620003d757600081556001016200043f565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200048057607f821691505b602082108103620004a157634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620004f557600081815260208120601f850160051c81016020861015620004d05750805b601f850160051c820191505b81811015620004f157828155600101620004dc565b5050505b505050565b81516001600160401b0381111562000516576200051662000455565b6200052e816200052784546200046b565b84620004a7565b602080601f8311600181146200056657600084156200054d5750858301515b600019600386901b1c1916600185901b178555620004f1565b600085815260208120601f198616915b82811015620005975788860151825594840194600190910190840162000576565b5085821015620005b65787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b03811681146200043b57600080fd5b60008060408385031215620005f057600080fd5b8251620005fd81620005c6565b602084015190925080151581146200061457600080fd5b809150509250929050565b600080604083850312156200063357600080fd5b82516200064081620005c6565b6020939093015192949293505050565b6000602082840312156200066357600080fd5b81516200067081620005c6565b9392505050565b60805160a051614b54620006ab600039600081816104f00152611bf401526000818161082c01526130410152614b546000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610dc7578063f2fde38b14610ddd578063fba7ffa314610dfd578063fcdc1f6314610e2a57600080fd5b8063d6051a7214610d3a578063daee1aeb14610d5a578063dbef701e14610d7a578063e0114adb14610d9a57600080fd5b8063c357f1f3116100dc578063c357f1f314610c4c578063c804802214610ca6578063c98f10b014610cc6578063d355852814610cdb57600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c2c57600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b806346e7a63e116102e2578063636092e8116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063636092e8146107d8578063642f6cef1461081a57806369cdbadb1461085e57806369e9b7731461088b57600080fd5b806359710992116102b157806359710992146107615780635d4ee7f3146107765780635f17e6161461078b57806360457ff5146107ab57600080fd5b806346e7a63e146106c75780634b56a42e146106f457806351c98be31461071457806357970e931461073457600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c1461063957806340691db4146106595780634585e33b1461068757806345d2ec17146106a757600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b61042636600461378a565b610e57565b005b34801561043957600080fd5b5061042b6104483660046138ab565b610e6e565b34801561045957600080fd5b5061046d610468366004613947565b61122a565b60405161047a9190613969565b60405180910390f35b34801561048f57600080fd5b506104a361049e3660046139c4565b611329565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc3660046139f9565b611367565b60405161047a9190613a80565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a93565b611487565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613ae1565b61150a565b34801561058657600080fd5b506104a3610595366004613afe565b6116d4565b3480156105a657600080fd5b5061042b6105b5366004613b6f565b61173f565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a36106273660046139f9565b60036020526000908152604090205481565b34801561064557600080fd5b506104a36106543660046139f9565b6117d9565b34801561066557600080fd5b50610679610674366004613bb1565b611842565b60405161047a929190613c1e565b34801561069357600080fd5b5061042b6106a2366004613c7b565b611af3565b3480156106b357600080fd5b5061046d6106c2366004613a93565b611d44565b3480156106d357600080fd5b506104a36106e23660046139f9565b600a6020526000908152604090205481565b34801561070057600080fd5b5061067961070f366004613cb1565b611db3565b34801561072057600080fd5b5061042b61072f366004613d6e565b611e07565b34801561074057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561076d57600080fd5b5061042b611eab565b34801561078257600080fd5b5061042b612096565b34801561079757600080fd5b5061042b6107a6366004613947565b6121cd565b3480156107b757600080fd5b506104a36107c63660046139f9565b60076020526000908152604090205481565b3480156107e457600080fd5b506015546107fd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561082657600080fd5b5061084e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561086a57600080fd5b506104a36108793660046139f9565b60086020526000908152604090205481565b34801561089757600080fd5b5061042b6108a6366004613947565b60009182526008602052604090912055565b3480156108c457600080fd5b5061084e6108d33660046139f9565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a36109033660046139f9565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a36109303660046139f9565b60046020526000908152604090205481565b34801561094e57600080fd5b5061084e61095d3660046139f9565b61229a565b34801561096e57600080fd5b5061042b6122ec565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613dc5565b6123e9565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a3660046139f9565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a37366004613947565b61247a565b348015610a4857600080fd5b5061042b610a57366004613e11565b6126bf565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab3366004613947565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae03660046139f9565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b113660046139f9565b612808565b348015610b2257600080fd5b506104d1610b313660046139f9565b61286a565b348015610b4257600080fd5b506104a37f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0881565b348015610b7657600080fd5b5061042b610b85366004613afe565b612916565b348015610b9657600080fd5b5061042b610ba53660046139f9565b601455565b348015610bb657600080fd5b5061042b610bc5366004613e41565b61297f565b348015610bd657600080fd5b5061042b610be5366004613947565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c123660046139f9565b612a2a565b348015610c2357600080fd5b506104d1612ab0565b348015610c3857600080fd5b5061042b610c47366004613b6f565b612abd565b348015610c5857600080fd5b5061042b610c67366004613e66565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610cb257600080fd5b5061042b610cc13660046139f9565b612b57565b348015610cd257600080fd5b506104d1612bef565b348015610ce757600080fd5b5061042b610cf6366004613e83565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610d4657600080fd5b50610545610d55366004613947565b612bfc565b348015610d6657600080fd5b5061042b610d75366004613b6f565b612c65565b348015610d8657600080fd5b506104a3610d95366004613947565b612d30565b348015610da657600080fd5b506104a3610db53660046139f9565b60096020526000908152604090205481565b348015610dd357600080fd5b506104a360145481565b348015610de957600080fd5b5061042b610df8366004613ae1565b612d61565b348015610e0957600080fd5b506104a3610e183660046139f9565b60066020526000908152604090205481565b348015610e3657600080fd5b506104a3610e453660046139f9565b60026020526000908152604090205481565b8051610e6a90601690602084019061355a565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610f54908c1688613ecf565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610fd2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ff69190613f13565b5060008860ff1667ffffffffffffffff8111156110155761101561363a565b60405190808252806020026020018201604052801561103e578160200160208202803683370190505b50905060005b8960ff168160ff1610156111e757600061105d84612d75565b90508860ff16600103611195576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111089190810190613f7b565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111619085908590600401613fb0565b600060405180830381600087803b15801561117b57600080fd5b505af115801561118f573d6000803e3d6000fd5b50505050505b80838360ff16815181106111ab576111ab613fc9565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111df81613ff8565b915050611044565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516112179190613969565b60405180910390a1505050505050505050565b60606000611238600f612e43565b9050808410611273576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82600003611288576112858482614017565b92505b60008367ffffffffffffffff8111156112a3576112a361363a565b6040519080825280602002602001820160405280156112cc578160200160208202803683370190505b50905060005b8481101561131e576112ef6112e7828861402a565b600f90612e4d565b82828151811061130157611301613fc9565b6020908102919091010152806113168161403d565b9150506112d2565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061135157600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0860001b8152602001846040516020016113d891815260200190565b6040516020818303038152906040526113f090614075565b81526020016000801b81526020016000801b8152509050806040516020016114709190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156114eb57602002820191906000526020600020905b8154815260200190600101908083116114d7575b505050505090506114fd818251612e59565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa1580156115a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c491906140c5565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015611667573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168b91906140f3565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c6020908152604080832080548251818502810185019093528083526117359383018282801561172957602002820191906000526020600020905b815481526020019060010190808311611715575b50505050508484612ede565b90505b9392505050565b8060005b818160ff1610156117d3573063c8048022858560ff851681811061176957611769613fc9565b905060200201356040518263ffffffff1660e01b815260040161178e91815260200190565b600060405180830381600087803b1580156117a857600080fd5b505af11580156117bc573d6000803e3d6000fd5b5050505080806117cb90613ff8565b915050611743565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff161161183a576000858152600d6020908152604080832061ffff85168452909152902054611826908361402a565b91508061183281614110565b9150506117ef565b509392505050565b6000606060005a9050600061185561303d565b90507f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0861188560c0880188614131565b600081811061189657611896613fc9565b9050602002013503611a6b5760006118b160c0880188614131565b60018181106118c2576118c2613fc9565b905060200201356040516020016118db91815260200190565b60405160208183030381529060405290506000818060200190518101906119029190614199565b9050600061191360c08a018a614131565b600281811061192457611924613fc9565b9050602002013560405160200161193d91815260200190565b60405160208183030381529060405290506000818060200190518101906119649190614199565b6000848152600860205260409020549091505b805a6119839089614017565b61198f90613a9861402a565b10156119dd5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055816119d5816141b2565b925050611977565b601760166018848786604051602001611a00929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252611a6295949392916004016142cf565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f67000000000000000000000000000000000000000000000000000000000000006064820152608401611a62565b60005a9050600080611b0784860186613cb1565b9150915060008082806020019051810190611b229190614392565b6000828152600560209081526040808320546004909252822054939550919350909190611b4d61303d565b905082600003611b6d576000858152600560205260409020819055611cb1565b6000611b798583614017565b6000878152600e6020908152604080832054600d835281842061ffff909116808552908352818420805483518186028101860190945280845295965090949192909190830182828015611beb57602002820191906000526020600020905b815481526020019060010190808311611bd7575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611c665781611c2881614110565b60008a8152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055898352600c8252928220805493840181558252902001555b600085815260066020526040812054611ccb90600161402a565b6000878152600660209081526040808320849055600490915290208390559050611cf5868361247a565b604051308152829087907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a3611d37868a84612916565b5050505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611da657602002820191906000526020600020905b815481526020019060010190808311611d92575b5050505050905092915050565b6000606060008484604051602001611dcc9291906143b6565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611ea45730635f17e616868684818110611e2b57611e2b613fc9565b90506020020135856040518363ffffffff1660e01b8152600401611e5f92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611e7957600080fd5b505af1158015611e8d573d6000803e3d6000fd5b505050508080611e9c9061403d565b915050611e0b565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611f22573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f68919081019061444a565b80519091506000611f7761303d565b905060005b828110156117d3576000848281518110611f9857611f98613fc9565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015612018573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061203c91906144db565b90508060ff1660010361208157604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b5050808061208e9061403d565b915050611f7c565b61209e6130df565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561210d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906121319190614199565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af11580156121a9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6a9190613f13565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120612205916135b0565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611612261576000848152600d6020908152604080832061ffff85168452909152812061224f916135b0565b8061225981614110565b91505061221a565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b60008181526005602052604081205481036122b757506001919050565b6000828152600360209081526040808320546004909252909120546122da61303d565b6122e49190614017565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461236d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401611a62565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b590612443908690869086906004016144f8565b600060405180830381600087803b15801561245d57600080fd5b505af1158015612471573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124969083614017565b1115610e6a576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa15801561250c573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612552919081019061457a565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156125c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125eb9190614699565b60155490915061260f9082906c01000000000000000000000000900460ff16613ecf565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156117d3576015546126529085906bffffffffffffffffffffffff166126bf565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af1158015612747573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061276b9190613f13565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b1580156127ec57600080fd5b505af1158015612800573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561285e57602002820191906000526020600020905b81548152602001906001019080831161284a575b50505050509050919050565b6016818154811061287a57600080fd5b906000526020600020016000915090508054612895906141e7565b80601f01602080910402602001604051908101604052809291908181526020018280546128c1906141e7565b801561290e5780601f106128e35761010080835404028352916020019161290e565b820191906000526020600020905b8154815290600101906020018083116128f157829003601f168201915b505050505081565b6000838152600760205260409020545b805a6129329085614017565b61293e9061271061402a565b10156117d35781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612926565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b1580156129f757600080fd5b505af1158015612a0b573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a9c57600080fd5b505af1158015611ea4573d6000803e3d6000fd5b60178054612895906141e7565b8060005b818163ffffffff1610156117d3573063af953a4a858563ffffffff8516818110612aed57612aed613fc9565b905060200201356040518263ffffffff1660e01b8152600401612b1291815260200190565b600060405180830381600087803b158015612b2c57600080fd5b505af1158015612b40573d6000803e3d6000fd5b505050508080612b4f906146b6565b915050612ac1565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612bc357600080fd5b505af1158015612bd7573d6000803e3d6000fd5b50505050610e6a81600f61316290919063ffffffff16565b60188054612895906141e7565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612c5457602002820191906000526020600020905b815481526020019060010190808311612c40575b505050505090506114fd8185612e59565b8060005b818110156117d3576000848483818110612c8557612c85613fc9565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612cbe91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612cea929190613fb0565b600060405180830381600087803b158015612d0457600080fd5b505af1158015612d18573d6000803e3d6000fd5b50505050508080612d289061403d565b915050612c69565b600c6020528160005260406000208181548110612d4c57600080fd5b90600052602060002001600091509150505481565b612d696130df565b612d728161316e565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612dd09086906004016146cf565b6020604051808303816000875af1158015612def573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e139190614199565b9050612e20600f82613263565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b6000611323825490565b6000611738838361326f565b815160009081908190841580612e6f5750808510155b15612e78578094505b60008092505b85831015612ed457866001612e938585614017565b612e9d9190614017565b81518110612ead57612ead613fc9565b602002602001015181612ec0919061402a565b905082612ecc8161403d565b935050612e7e565b9694955050505050565b82516000908190831580612ef25750808410155b15612efb578093505b60008467ffffffffffffffff811115612f1657612f1661363a565b604051908082528060200260200182016040528015612f3f578160200160208202803683370190505b509050600092505b84831015612fad57866001612f5c8585614017565b612f669190614017565b81518110612f7657612f76613fc9565b6020026020010151818481518110612f9057612f90613fc9565b602090810291909101015282612fa58161403d565b935050612f47565b612fc681600060018451612fc19190614017565b613299565b85606403612fff578060018251612fdd9190614017565b81518110612fed57612fed613fc9565b60200260200101519350505050611738565b80606482518861300f9190614821565b613019919061488d565b8151811061302957613029613fc9565b602002602001015193505050509392505050565b60007f0000000000000000000000000000000000000000000000000000000000000000156130da57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156130b1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130d59190614199565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314613160576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611a62565b565b60006117388383613411565b3373ffffffffffffffffffffffffffffffffffffffff8216036131ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611a62565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000611738838361350b565b600082600001828154811061328657613286613fc9565b9060005260206000200154905092915050565b81818082036132a9575050505050565b60008560026132b887876148a1565b6132c291906148c1565b6132cc9087614929565b815181106132dc576132dc613fc9565b602002602001015190505b8183136133eb575b8086848151811061330257613302613fc9565b60200260200101511015613322578261331a81614951565b9350506132ef565b85828151811061333457613334613fc9565b6020026020010151811015613355578161334d81614982565b925050613322565b8183136133e65785828151811061336e5761336e613fc9565b602002602001015186848151811061338857613388613fc9565b60200260200101518785815181106133a2576133a2613fc9565b602002602001018885815181106133bb576133bb613fc9565b602090810291909101019190915252826133d481614951565b93505081806133e290614982565b9250505b6132e7565b818512156133fe576133fe868684613299565b8383121561280057612800868486613299565b600081815260018301602052604081205480156134fa576000613435600183614017565b855490915060009061344990600190614017565b90508181146134ae57600086600001828154811061346957613469613fc9565b906000526020600020015490508087600001848154811061348c5761348c613fc9565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134bf576134bf6149b3565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050611323565b6000915050611323565b5092915050565b600081815260018301602052604081205461355257508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155611323565b506000611323565b8280548282559060005260206000209081019282156135a0579160200282015b828111156135a057825182906135909082614a2d565b509160200191906001019061357a565b506135ac9291506135ce565b5090565b5080546000825590600052602060002090810190612d7291906135eb565b808211156135ac5760006135e28282613600565b506001016135ce565b5b808211156135ac57600081556001016135ec565b50805461360c906141e7565b6000825580601f1061361c575050565b601f016020900490600052602060002090810190612d7291906135eb565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561368d5761368d61363a565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156136da576136da61363a565b604052919050565b600067ffffffffffffffff8211156136fc576136fc61363a565b5060051b60200190565b600067ffffffffffffffff8211156137205761372061363a565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600061375f61375a84613706565b613693565b905082815283838301111561377357600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561379d57600080fd5b823567ffffffffffffffff808211156137b557600080fd5b818501915085601f8301126137c957600080fd5b81356137d761375a826136e2565b81815260059190911b830184019084810190888311156137f657600080fd5b8585015b83811015613843578035858111156138125760008081fd5b8601603f81018b136138245760008081fd5b6138358b898301356040840161374c565b8452509186019186016137fa565b5098975050505050505050565b60ff81168114612d7257600080fd5b63ffffffff81168114612d7257600080fd5b600082601f83011261388257600080fd5b6117388383356020850161374c565b6bffffffffffffffffffffffff81168114612d7257600080fd5b600080600080600080600060e0888a0312156138c657600080fd5b87356138d181613850565b965060208801356138e18161385f565b955060408801356138f181613850565b9450606088013567ffffffffffffffff81111561390d57600080fd5b6139198a828b01613871565b945050608088013561392a81613891565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561395a57600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b818110156139a157835183529284019291840191600101613985565b50909695505050505050565b803561ffff811681146139bf57600080fd5b919050565b6000806000606084860312156139d957600080fd5b833592506139e9602085016139ad565b9150604084013590509250925092565b600060208284031215613a0b57600080fd5b5035919050565b60005b83811015613a2d578181015183820152602001613a15565b50506000910152565b60008151808452613a4e816020860160208601613a12565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117386020830184613a36565b60008060408385031215613aa657600080fd5b82359150613ab6602084016139ad565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612d7257600080fd5b600060208284031215613af357600080fd5b813561173881613abf565b600080600060608486031215613b1357600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613b3c57600080fd5b50813567ffffffffffffffff811115613b5457600080fd5b6020830191508360208260051b850101111561150357600080fd5b60008060208385031215613b8257600080fd5b823567ffffffffffffffff811115613b9957600080fd5b613ba585828601613b2a565b90969095509350505050565b60008060408385031215613bc457600080fd5b823567ffffffffffffffff80821115613bdc57600080fd5b908401906101008287031215613bf157600080fd5b90925060208401359080821115613c0757600080fd5b50613c1485828601613871565b9150509250929050565b82151581526040602082015260006117356040830184613a36565b60008083601f840112613c4b57600080fd5b50813567ffffffffffffffff811115613c6357600080fd5b60208301915083602082850101111561150357600080fd5b60008060208385031215613c8e57600080fd5b823567ffffffffffffffff811115613ca557600080fd5b613ba585828601613c39565b60008060408385031215613cc457600080fd5b823567ffffffffffffffff80821115613cdc57600080fd5b818501915085601f830112613cf057600080fd5b81356020613d0061375a836136e2565b82815260059290921b84018101918181019089841115613d1f57600080fd5b8286015b84811015613d5757803586811115613d3b5760008081fd5b613d498c86838b0101613871565b845250918301918301613d23565b5096505086013592505080821115613c0757600080fd5b600080600060408486031215613d8357600080fd5b833567ffffffffffffffff811115613d9a57600080fd5b613da686828701613b2a565b9094509250506020840135613dba8161385f565b809150509250925092565b600080600060408486031215613dda57600080fd5b83359250602084013567ffffffffffffffff811115613df857600080fd5b613e0486828701613c39565b9497909650939450505050565b60008060408385031215613e2457600080fd5b823591506020830135613e3681613891565b809150509250929050565b60008060408385031215613e5457600080fd5b823591506020830135613e368161385f565b600060208284031215613e7857600080fd5b813561173881613891565b600060208284031215613e9557600080fd5b813561173881613850565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613efa57613efa613ea0565b02949350505050565b805180151581146139bf57600080fd5b600060208284031215613f2557600080fd5b61173882613f03565b600082601f830112613f3f57600080fd5b8151613f4d61375a82613706565b818152846020838601011115613f6257600080fd5b613f73826020830160208701613a12565b949350505050565b600060208284031215613f8d57600080fd5b815167ffffffffffffffff811115613fa457600080fd5b613f7384828501613f2e565b8281526040602082015260006117356040830184613a36565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361400e5761400e613ea0565b60010192915050565b8181038181111561132357611323613ea0565b8082018082111561132357611323613ea0565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406e5761406e613ea0565b5060010190565b805160208083015191908110156140b4577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b80516139bf81613abf565b600080604083850312156140d857600080fd5b82516140e381613abf565b6020939093015192949293505050565b60006020828403121561410557600080fd5b815161173881613abf565b600061ffff80831681810361412757614127613ea0565b6001019392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261416657600080fd5b83018035915067ffffffffffffffff82111561418157600080fd5b6020019150600581901b360382131561150357600080fd5b6000602082840312156141ab57600080fd5b5051919050565b6000816141c1576141c1613ea0565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600181811c908216806141fb57607f821691505b6020821081036140b4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60008154614241816141e7565b80855260206001838116801561425e5760018114614296576142c4565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b89010195506142c4565b866000528260002060005b858110156142bc5781548a82018601529083019084016142a1565b890184019650505b505050505092915050565b60a0815260006142e260a0830188614234565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015614354577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526143428383614234565b94860194925060019182019101614309565b50508681036040880152614368818b614234565b94505050505084606084015282810360808401526143868185613a36565b98975050505050505050565b600080604083850312156143a557600080fd5b505080516020909101519092909150565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b8381101561442b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614419868351613a36565b955093820193908201906001016143df565b5050858403818701525050506144418185613a36565b95945050505050565b6000602080838503121561445d57600080fd5b825167ffffffffffffffff81111561447457600080fd5b8301601f8101851361448557600080fd5b805161449361375a826136e2565b81815260059190911b820183019083810190878311156144b257600080fd5b928401925b828410156144d0578351825292840192908401906144b7565b979650505050505050565b6000602082840312156144ed57600080fd5b815161173881613850565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b80516139bf8161385f565b80516139bf81613891565b805167ffffffffffffffff811681146139bf57600080fd5b60006020828403121561458c57600080fd5b815167ffffffffffffffff808211156145a457600080fd5b9083019061014082860312156145b957600080fd5b6145c1613669565b6145ca836140ba565b81526145d86020840161454c565b60208201526040830151828111156145ef57600080fd5b6145fb87828601613f2e565b60408301525061460d60608401614557565b606082015261461e608084016140ba565b608082015261462f60a08401614562565b60a082015261464060c0840161454c565b60c082015261465160e08401614557565b60e0820152610100614664818501613f03565b90820152610120838101518381111561467c57600080fd5b61468888828701613f2e565b918301919091525095945050505050565b6000602082840312156146ab57600080fd5b815161173881613891565b600063ffffffff80831681810361412757614127613ea0565b60208152600082516101408060208501526146ee610160850183613a36565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261472a8483613a36565b935060408701519150614755606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e08701526147b68483613a36565b935060e087015191506101008187860301818801526147d58584613a36565b9450808801519250506101208187860301818801526147f48584613a36565b94508088015192505050614817828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561485957614859613ea0565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261489c5761489c61485e565b500490565b818103600083128015838313168383128216171561350457613504613ea0565b6000826148d0576148d061485e565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561492457614924613ea0565b500590565b808201828112600083128015821682158216171561494957614949613ea0565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406e5761406e613ea0565b60007f800000000000000000000000000000000000000000000000000000000000000082036141c1576141c1613ea0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f821115614a2857600081815260208120601f850160051c81016020861015614a095750805b601f850160051c820191505b8181101561280057828155600101614a15565b505050565b815167ffffffffffffffff811115614a4757614a4761363a565b614a5b81614a5584546141e7565b846149e2565b602080601f831160018114614aae5760008415614a785750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555612800565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015614afb57888601518255948401946001909101908401614adc565b5085821015614b3757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0526101a0604052604261012081815260e091829190620052386101403981526020016040518060800160405280604281526020016200527a60429139905262000099906016906002620003a2565b506040805180820190915260098152680cccacac892c890caf60bb1b6020820152601790620000c990826200051e565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152601890620000fb90826200051e565b503480156200010957600080fd5b50604051620052bc380380620052bc8339810160408190526200012c9162000600565b81813380600081620001855760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620001b857620001b881620002f7565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa15801562000215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200023b919062000643565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620002a1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002c7919062000674565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a052506200069b915050565b336001600160a01b03821603620003515760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200017c565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003ed579160200282015b82811115620003ed5782518290620003dc90826200051e565b5091602001919060010190620003c3565b50620003fb929150620003ff565b5090565b80821115620003fb57600062000416828262000420565b50600101620003ff565b5080546200042e906200048f565b6000825580601f106200043f575050565b601f0160209004906000526020600020908101906200045f919062000462565b50565b5b80821115620003fb576000815560010162000463565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620004a457607f821691505b602082108103620004c557634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200051957600081815260208120601f850160051c81016020861015620004f45750805b601f850160051c820191505b81811015620005155782815560010162000500565b5050505b505050565b81516001600160401b038111156200053a576200053a62000479565b62000552816200054b84546200048f565b84620004cb565b602080601f8311600181146200058a5760008415620005715750858301515b600019600386901b1c1916600185901b17855562000515565b600085815260208120601f198616915b82811015620005bb578886015182559484019460019091019084016200059a565b5085821015620005da5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b03811681146200045f57600080fd5b600080604083850312156200061457600080fd5b82516200062181620005ea565b602084015190925080151581146200063857600080fd5b809150509250929050565b600080604083850312156200065757600080fd5b82516200066481620005ea565b6020939093015192949293505050565b6000602082840312156200068757600080fd5b81516200069481620005ea565b9392505050565b60805160a05160c051614b51620006e7600039600081816104f00152611bf101526000818161082c015261303e015260008181610b480152818161139e01526118560152614b516000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610dc7578063f2fde38b14610ddd578063fba7ffa314610dfd578063fcdc1f6314610e2a57600080fd5b8063d6051a7214610d3a578063daee1aeb14610d5a578063dbef701e14610d7a578063e0114adb14610d9a57600080fd5b8063c357f1f3116100dc578063c357f1f314610c4c578063c804802214610ca6578063c98f10b014610cc6578063d355852814610cdb57600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c2c57600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b806346e7a63e116102e2578063636092e8116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063636092e8146107d8578063642f6cef1461081a57806369cdbadb1461085e57806369e9b7731461088b57600080fd5b806359710992116102b157806359710992146107615780635d4ee7f3146107765780635f17e6161461078b57806360457ff5146107ab57600080fd5b806346e7a63e146106c75780634b56a42e146106f457806351c98be31461071457806357970e931461073457600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c1461063957806340691db4146106595780634585e33b1461068757806345d2ec17146106a757600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b610426366004613787565b610e57565b005b34801561043957600080fd5b5061042b6104483660046138a8565b610e6e565b34801561045957600080fd5b5061046d610468366004613944565b61122a565b60405161047a9190613966565b60405180910390f35b34801561048f57600080fd5b506104a361049e3660046139c1565b611329565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc3660046139f6565b611367565b60405161047a9190613a7d565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a90565b611484565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613ade565b611507565b34801561058657600080fd5b506104a3610595366004613afb565b6116d1565b3480156105a657600080fd5b5061042b6105b5366004613b6c565b61173c565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a36106273660046139f6565b60036020526000908152604090205481565b34801561064557600080fd5b506104a36106543660046139f6565b6117d6565b34801561066557600080fd5b50610679610674366004613bae565b61183f565b60405161047a929190613c1b565b34801561069357600080fd5b5061042b6106a2366004613c78565b611af0565b3480156106b357600080fd5b5061046d6106c2366004613a90565b611d41565b3480156106d357600080fd5b506104a36106e23660046139f6565b600a6020526000908152604090205481565b34801561070057600080fd5b5061067961070f366004613cae565b611db0565b34801561072057600080fd5b5061042b61072f366004613d6b565b611e04565b34801561074057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561076d57600080fd5b5061042b611ea8565b34801561078257600080fd5b5061042b612093565b34801561079757600080fd5b5061042b6107a6366004613944565b6121ca565b3480156107b757600080fd5b506104a36107c63660046139f6565b60076020526000908152604090205481565b3480156107e457600080fd5b506015546107fd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561082657600080fd5b5061084e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561086a57600080fd5b506104a36108793660046139f6565b60086020526000908152604090205481565b34801561089757600080fd5b5061042b6108a6366004613944565b60009182526008602052604090912055565b3480156108c457600080fd5b5061084e6108d33660046139f6565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a36109033660046139f6565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a36109303660046139f6565b60046020526000908152604090205481565b34801561094e57600080fd5b5061084e61095d3660046139f6565b612297565b34801561096e57600080fd5b5061042b6122e9565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613dc2565b6123e6565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a3660046139f6565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a37366004613944565b612477565b348015610a4857600080fd5b5061042b610a57366004613e0e565b6126bc565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab3366004613944565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae03660046139f6565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b113660046139f6565b612805565b348015610b2257600080fd5b506104d1610b313660046139f6565b612867565b348015610b4257600080fd5b506104a37f000000000000000000000000000000000000000000000000000000000000000081565b348015610b7657600080fd5b5061042b610b85366004613afb565b612913565b348015610b9657600080fd5b5061042b610ba53660046139f6565b601455565b348015610bb657600080fd5b5061042b610bc5366004613e3e565b61297c565b348015610bd657600080fd5b5061042b610be5366004613944565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c123660046139f6565b612a27565b348015610c2357600080fd5b506104d1612aad565b348015610c3857600080fd5b5061042b610c47366004613b6c565b612aba565b348015610c5857600080fd5b5061042b610c67366004613e63565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610cb257600080fd5b5061042b610cc13660046139f6565b612b54565b348015610cd257600080fd5b506104d1612bec565b348015610ce757600080fd5b5061042b610cf6366004613e80565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610d4657600080fd5b50610545610d55366004613944565b612bf9565b348015610d6657600080fd5b5061042b610d75366004613b6c565b612c62565b348015610d8657600080fd5b506104a3610d95366004613944565b612d2d565b348015610da657600080fd5b506104a3610db53660046139f6565b60096020526000908152604090205481565b348015610dd357600080fd5b506104a360145481565b348015610de957600080fd5b5061042b610df8366004613ade565b612d5e565b348015610e0957600080fd5b506104a3610e183660046139f6565b60066020526000908152604090205481565b348015610e3657600080fd5b506104a3610e453660046139f6565b60026020526000908152604090205481565b8051610e6a906016906020840190613557565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610f54908c1688613ecc565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610fd2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ff69190613f10565b5060008860ff1667ffffffffffffffff81111561101557611015613637565b60405190808252806020026020018201604052801561103e578160200160208202803683370190505b50905060005b8960ff168160ff1610156111e757600061105d84612d72565b90508860ff16600103611195576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111089190810190613f78565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111619085908590600401613fad565b600060405180830381600087803b15801561117b57600080fd5b505af115801561118f573d6000803e3d6000fd5b50505050505b80838360ff16815181106111ab576111ab613fc6565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111df81613ff5565b915050611044565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516112179190613966565b60405180910390a1505050505050505050565b60606000611238600f612e40565b9050808410611273576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82600003611288576112858482614014565b92505b60008367ffffffffffffffff8111156112a3576112a3613637565b6040519080825280602002602001820160405280156112cc578160200160208202803683370190505b50905060005b8481101561131e576112ef6112e78288614027565b600f90612e4a565b82828151811061130157611301613fc6565b6020908102919091010152806113168161403a565b9150506112d2565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061135157600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f00000000000000000000000000000000000000000000000000000000000000008152602001846040516020016113d591815260200190565b6040516020818303038152906040526113ed90614072565b81526020016000801b81526020016000801b81525090508060405160200161146d9190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156114e857602002820191906000526020600020905b8154815260200190600101908083116114d4575b505050505090506114fa818251612e56565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa15801561159d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c191906140c2565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015611664573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168891906140f0565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c6020908152604080832080548251818502810185019093528083526117329383018282801561172657602002820191906000526020600020905b815481526020019060010190808311611712575b50505050508484612edb565b90505b9392505050565b8060005b818160ff1610156117d0573063c8048022858560ff851681811061176657611766613fc6565b905060200201356040518263ffffffff1660e01b815260040161178b91815260200190565b600060405180830381600087803b1580156117a557600080fd5b505af11580156117b9573d6000803e3d6000fd5b5050505080806117c890613ff5565b915050611740565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff1611611837576000858152600d6020908152604080832061ffff851684529091529020546118239083614027565b91508061182f8161410d565b9150506117ec565b509392505050565b6000606060005a9050600061185261303a565b90507f000000000000000000000000000000000000000000000000000000000000000061188260c088018861412e565b600081811061189357611893613fc6565b9050602002013503611a685760006118ae60c088018861412e565b60018181106118bf576118bf613fc6565b905060200201356040516020016118d891815260200190565b60405160208183030381529060405290506000818060200190518101906118ff9190614196565b9050600061191060c08a018a61412e565b600281811061192157611921613fc6565b9050602002013560405160200161193a91815260200190565b60405160208183030381529060405290506000818060200190518101906119619190614196565b6000848152600860205260409020549091505b805a6119809089614014565b61198c90613a98614027565b10156119da5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055816119d2816141af565b925050611974565b6017601660188487866040516020016119fd929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252611a5f95949392916004016142cc565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f67000000000000000000000000000000000000000000000000000000000000006064820152608401611a5f565b60005a9050600080611b0484860186613cae565b9150915060008082806020019051810190611b1f919061438f565b6000828152600560209081526040808320546004909252822054939550919350909190611b4a61303a565b905082600003611b6a576000858152600560205260409020819055611cae565b6000611b768583614014565b6000878152600e6020908152604080832054600d835281842061ffff909116808552908352818420805483518186028101860190945280845295965090949192909190830182828015611be857602002820191906000526020600020905b815481526020019060010190808311611bd4575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611c635781611c258161410d565b60008a8152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055898352600c8252928220805493840181558252902001555b600085815260066020526040812054611cc8906001614027565b6000878152600660209081526040808320849055600490915290208390559050611cf28683612477565b604051308152829087907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a3611d34868a84612913565b5050505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611da357602002820191906000526020600020905b815481526020019060010190808311611d8f575b5050505050905092915050565b6000606060008484604051602001611dc99291906143b3565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611ea15730635f17e616868684818110611e2857611e28613fc6565b90506020020135856040518363ffffffff1660e01b8152600401611e5c92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611e7657600080fd5b505af1158015611e8a573d6000803e3d6000fd5b505050508080611e999061403a565b915050611e08565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611f1f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f659190810190614447565b80519091506000611f7461303a565b905060005b828110156117d0576000848281518110611f9557611f95613fc6565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015612015573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061203991906144d8565b90508060ff1660010361207e57604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b5050808061208b9061403a565b915050611f79565b61209b6130dc565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561210a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061212e9190614196565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af11580156121a6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6a9190613f10565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120612202916135ad565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff161161225e576000848152600d6020908152604080832061ffff85168452909152812061224c916135ad565b806122568161410d565b915050612217565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b60008181526005602052604081205481036122b457506001919050565b6000828152600360209081526040808320546004909252909120546122d761303a565b6122e19190614014565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461236a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401611a5f565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b590612440908690869086906004016144f5565b600060405180830381600087803b15801561245a57600080fd5b505af115801561246e573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124939083614014565b1115610e6a576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612509573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261254f9190810190614577565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156125c4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125e89190614696565b60155490915061260c9082906c01000000000000000000000000900460ff16613ecc565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156117d05760155461264f9085906bffffffffffffffffffffffff166126bc565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af1158015612744573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127689190613f10565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b1580156127e957600080fd5b505af11580156127fd573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561285b57602002820191906000526020600020905b815481526020019060010190808311612847575b50505050509050919050565b6016818154811061287757600080fd5b906000526020600020016000915090508054612892906141e4565b80601f01602080910402602001604051908101604052809291908181526020018280546128be906141e4565b801561290b5780601f106128e05761010080835404028352916020019161290b565b820191906000526020600020905b8154815290600101906020018083116128ee57829003601f168201915b505050505081565b6000838152600760205260409020545b805a61292f9085614014565b61293b90612710614027565b10156117d05781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612923565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b1580156129f457600080fd5b505af1158015612a08573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a9957600080fd5b505af1158015611ea1573d6000803e3d6000fd5b60178054612892906141e4565b8060005b818163ffffffff1610156117d0573063af953a4a858563ffffffff8516818110612aea57612aea613fc6565b905060200201356040518263ffffffff1660e01b8152600401612b0f91815260200190565b600060405180830381600087803b158015612b2957600080fd5b505af1158015612b3d573d6000803e3d6000fd5b505050508080612b4c906146b3565b915050612abe565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612bc057600080fd5b505af1158015612bd4573d6000803e3d6000fd5b50505050610e6a81600f61315f90919063ffffffff16565b60188054612892906141e4565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612c5157602002820191906000526020600020905b815481526020019060010190808311612c3d575b505050505090506114fa8185612e56565b8060005b818110156117d0576000848483818110612c8257612c82613fc6565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612cbb91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612ce7929190613fad565b600060405180830381600087803b158015612d0157600080fd5b505af1158015612d15573d6000803e3d6000fd5b50505050508080612d259061403a565b915050612c66565b600c6020528160005260406000208181548110612d4957600080fd5b90600052602060002001600091509150505481565b612d666130dc565b612d6f8161316b565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612dcd9086906004016146cc565b6020604051808303816000875af1158015612dec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e109190614196565b9050612e1d600f82613260565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b6000611323825490565b6000611735838361326c565b815160009081908190841580612e6c5750808510155b15612e75578094505b60008092505b85831015612ed157866001612e908585614014565b612e9a9190614014565b81518110612eaa57612eaa613fc6565b602002602001015181612ebd9190614027565b905082612ec98161403a565b935050612e7b565b9694955050505050565b82516000908190831580612eef5750808410155b15612ef8578093505b60008467ffffffffffffffff811115612f1357612f13613637565b604051908082528060200260200182016040528015612f3c578160200160208202803683370190505b509050600092505b84831015612faa57866001612f598585614014565b612f639190614014565b81518110612f7357612f73613fc6565b6020026020010151818481518110612f8d57612f8d613fc6565b602090810291909101015282612fa28161403a565b935050612f44565b612fc381600060018451612fbe9190614014565b613296565b85606403612ffc578060018251612fda9190614014565b81518110612fea57612fea613fc6565b60200260200101519350505050611735565b80606482518861300c919061481e565b613016919061488a565b8151811061302657613026613fc6565b602002602001015193505050509392505050565b60007f0000000000000000000000000000000000000000000000000000000000000000156130d757606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156130ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130d29190614196565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331461315d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611a5f565b565b6000611735838361340e565b3373ffffffffffffffffffffffffffffffffffffffff8216036131ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611a5f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006117358383613508565b600082600001828154811061328357613283613fc6565b9060005260206000200154905092915050565b81818082036132a6575050505050565b60008560026132b5878761489e565b6132bf91906148be565b6132c99087614926565b815181106132d9576132d9613fc6565b602002602001015190505b8183136133e8575b808684815181106132ff576132ff613fc6565b6020026020010151101561331f57826133178161494e565b9350506132ec565b85828151811061333157613331613fc6565b6020026020010151811015613352578161334a8161497f565b92505061331f565b8183136133e35785828151811061336b5761336b613fc6565b602002602001015186848151811061338557613385613fc6565b602002602001015187858151811061339f5761339f613fc6565b602002602001018885815181106133b8576133b8613fc6565b602090810291909101019190915252826133d18161494e565b93505081806133df9061497f565b9250505b6132e4565b818512156133fb576133fb868684613296565b838312156127fd576127fd868486613296565b600081815260018301602052604081205480156134f7576000613432600183614014565b855490915060009061344690600190614014565b90508181146134ab57600086600001828154811061346657613466613fc6565b906000526020600020015490508087600001848154811061348957613489613fc6565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134bc576134bc6149b0565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050611323565b6000915050611323565b5092915050565b600081815260018301602052604081205461354f57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155611323565b506000611323565b82805482825590600052602060002090810192821561359d579160200282015b8281111561359d578251829061358d9082614a2a565b5091602001919060010190613577565b506135a99291506135cb565b5090565b5080546000825590600052602060002090810190612d6f91906135e8565b808211156135a95760006135df82826135fd565b506001016135cb565b5b808211156135a957600081556001016135e9565b508054613609906141e4565b6000825580601f10613619575050565b601f016020900490600052602060002090810190612d6f91906135e8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561368a5761368a613637565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156136d7576136d7613637565b604052919050565b600067ffffffffffffffff8211156136f9576136f9613637565b5060051b60200190565b600067ffffffffffffffff82111561371d5761371d613637565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600061375c61375784613703565b613690565b905082815283838301111561377057600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561379a57600080fd5b823567ffffffffffffffff808211156137b257600080fd5b818501915085601f8301126137c657600080fd5b81356137d4613757826136df565b81815260059190911b830184019084810190888311156137f357600080fd5b8585015b838110156138405780358581111561380f5760008081fd5b8601603f81018b136138215760008081fd5b6138328b8983013560408401613749565b8452509186019186016137f7565b5098975050505050505050565b60ff81168114612d6f57600080fd5b63ffffffff81168114612d6f57600080fd5b600082601f83011261387f57600080fd5b61173583833560208501613749565b6bffffffffffffffffffffffff81168114612d6f57600080fd5b600080600080600080600060e0888a0312156138c357600080fd5b87356138ce8161384d565b965060208801356138de8161385c565b955060408801356138ee8161384d565b9450606088013567ffffffffffffffff81111561390a57600080fd5b6139168a828b0161386e565b94505060808801356139278161388e565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561395757600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561399e57835183529284019291840191600101613982565b50909695505050505050565b803561ffff811681146139bc57600080fd5b919050565b6000806000606084860312156139d657600080fd5b833592506139e6602085016139aa565b9150604084013590509250925092565b600060208284031215613a0857600080fd5b5035919050565b60005b83811015613a2a578181015183820152602001613a12565b50506000910152565b60008151808452613a4b816020860160208601613a0f565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117356020830184613a33565b60008060408385031215613aa357600080fd5b82359150613ab3602084016139aa565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612d6f57600080fd5b600060208284031215613af057600080fd5b813561173581613abc565b600080600060608486031215613b1057600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613b3957600080fd5b50813567ffffffffffffffff811115613b5157600080fd5b6020830191508360208260051b850101111561150057600080fd5b60008060208385031215613b7f57600080fd5b823567ffffffffffffffff811115613b9657600080fd5b613ba285828601613b27565b90969095509350505050565b60008060408385031215613bc157600080fd5b823567ffffffffffffffff80821115613bd957600080fd5b908401906101008287031215613bee57600080fd5b90925060208401359080821115613c0457600080fd5b50613c118582860161386e565b9150509250929050565b82151581526040602082015260006117326040830184613a33565b60008083601f840112613c4857600080fd5b50813567ffffffffffffffff811115613c6057600080fd5b60208301915083602082850101111561150057600080fd5b60008060208385031215613c8b57600080fd5b823567ffffffffffffffff811115613ca257600080fd5b613ba285828601613c36565b60008060408385031215613cc157600080fd5b823567ffffffffffffffff80821115613cd957600080fd5b818501915085601f830112613ced57600080fd5b81356020613cfd613757836136df565b82815260059290921b84018101918181019089841115613d1c57600080fd5b8286015b84811015613d5457803586811115613d385760008081fd5b613d468c86838b010161386e565b845250918301918301613d20565b5096505086013592505080821115613c0457600080fd5b600080600060408486031215613d8057600080fd5b833567ffffffffffffffff811115613d9757600080fd5b613da386828701613b27565b9094509250506020840135613db78161385c565b809150509250925092565b600080600060408486031215613dd757600080fd5b83359250602084013567ffffffffffffffff811115613df557600080fd5b613e0186828701613c36565b9497909650939450505050565b60008060408385031215613e2157600080fd5b823591506020830135613e338161388e565b809150509250929050565b60008060408385031215613e5157600080fd5b823591506020830135613e338161385c565b600060208284031215613e7557600080fd5b81356117358161388e565b600060208284031215613e9257600080fd5b81356117358161384d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613ef757613ef7613e9d565b02949350505050565b805180151581146139bc57600080fd5b600060208284031215613f2257600080fd5b61173582613f00565b600082601f830112613f3c57600080fd5b8151613f4a61375782613703565b818152846020838601011115613f5f57600080fd5b613f70826020830160208701613a0f565b949350505050565b600060208284031215613f8a57600080fd5b815167ffffffffffffffff811115613fa157600080fd5b613f7084828501613f2b565b8281526040602082015260006117326040830184613a33565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361400b5761400b613e9d565b60010192915050565b8181038181111561132357611323613e9d565b8082018082111561132357611323613e9d565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406b5761406b613e9d565b5060010190565b805160208083015191908110156140b1577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b80516139bc81613abc565b600080604083850312156140d557600080fd5b82516140e081613abc565b6020939093015192949293505050565b60006020828403121561410257600080fd5b815161173581613abc565b600061ffff80831681810361412457614124613e9d565b6001019392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261416357600080fd5b83018035915067ffffffffffffffff82111561417e57600080fd5b6020019150600581901b360382131561150057600080fd5b6000602082840312156141a857600080fd5b5051919050565b6000816141be576141be613e9d565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600181811c908216806141f857607f821691505b6020821081036140b1577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000815461423e816141e4565b80855260206001838116801561425b5760018114614293576142c1565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b89010195506142c1565b866000528260002060005b858110156142b95781548a820186015290830190840161429e565b890184019650505b505050505092915050565b60a0815260006142df60a0830188614231565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015614351577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261433f8383614231565b94860194925060019182019101614306565b50508681036040880152614365818b614231565b94505050505084606084015282810360808401526143838185613a33565b98975050505050505050565b600080604083850312156143a257600080fd5b505080516020909101519092909150565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015614428577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614416868351613a33565b955093820193908201906001016143dc565b50508584038187015250505061443e8185613a33565b95945050505050565b6000602080838503121561445a57600080fd5b825167ffffffffffffffff81111561447157600080fd5b8301601f8101851361448257600080fd5b8051614490613757826136df565b81815260059190911b820183019083810190878311156144af57600080fd5b928401925b828410156144cd578351825292840192908401906144b4565b979650505050505050565b6000602082840312156144ea57600080fd5b81516117358161384d565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b80516139bc8161385c565b80516139bc8161388e565b805167ffffffffffffffff811681146139bc57600080fd5b60006020828403121561458957600080fd5b815167ffffffffffffffff808211156145a157600080fd5b9083019061014082860312156145b657600080fd5b6145be613666565b6145c7836140b7565b81526145d560208401614549565b60208201526040830151828111156145ec57600080fd5b6145f887828601613f2b565b60408301525061460a60608401614554565b606082015261461b608084016140b7565b608082015261462c60a0840161455f565b60a082015261463d60c08401614549565b60c082015261464e60e08401614554565b60e0820152610100614661818501613f00565b90820152610120838101518381111561467957600080fd5b61468588828701613f2b565b918301919091525095945050505050565b6000602082840312156146a857600080fd5b81516117358161388e565b600063ffffffff80831681810361412457614124613e9d565b60208152600082516101408060208501526146eb610160850183613a33565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0808685030160408701526147278483613a33565b935060408701519150614752606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e08701526147b38483613a33565b935060e087015191506101008187860301818801526147d28584613a33565b9450808801519250506101208187860301818801526147f18584613a33565b94508088015192505050614814828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561485657614856613e9d565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826148995761489961485b565b500490565b818103600083128015838313168383128216171561350157613501613e9d565b6000826148cd576148cd61485b565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561492157614921613e9d565b500590565b808201828112600083128015821682158216171561494657614946613e9d565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406b5761406b613e9d565b60007f800000000000000000000000000000000000000000000000000000000000000082036141be576141be613e9d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f821115614a2557600081815260208120601f850160051c81016020861015614a065750805b601f850160051c820191505b818110156127fd57828155600101614a12565b505050565b815167ffffffffffffffff811115614a4457614a44613637565b614a5881614a5284546141e4565b846149df565b602080601f831160018114614aab5760008415614a755750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556127fd565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015614af857888601518255948401946001909101908401614ad9565b5085821015614b3457878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var VerifiableLoadLogTriggerUpkeepABI = VerifiableLoadLogTriggerUpkeepMetaData.ABI diff --git a/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go index e517a0d92ce..325b7f482aa 100644 --- a/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go @@ -31,15 +31,15 @@ var ( ) var VerifiableLoadMercuryUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registrarAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x6005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460a0526101a0604052604261012081815260c0918291906200504661014039815260200160405180608001604052806042815260200162005088604291398152602001604051806080016040528060428152602001620050ca604291399052620000949060169060036200033b565b50348015620000a257600080fd5b506040516200510c3803806200510c833981016040819052620000c59162000428565b818133806000816200011e5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156200015157620001518162000290565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001ae573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001d491906200046b565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200023a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200026091906200049c565b601280546001600160a01b0319166001600160a01b03929092169190911790555015156080525062000634915050565b336001600160a01b03821603620002ea5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000115565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b82805482825590600052602060002090810192821562000386579160200282015b8281111562000386578251829062000375908262000568565b50916020019190600101906200035c565b506200039492915062000398565b5090565b8082111562000394576000620003af8282620003b9565b5060010162000398565b508054620003c790620004d9565b6000825580601f10620003d8575050565b601f016020900490600052602060002090810190620003f89190620003fb565b50565b5b80821115620003945760008155600101620003fc565b6001600160a01b0381168114620003f857600080fd5b600080604083850312156200043c57600080fd5b8251620004498162000412565b602084015190925080151581146200046057600080fd5b809150509250929050565b600080604083850312156200047f57600080fd5b82516200048c8162000412565b6020939093015192949293505050565b600060208284031215620004af57600080fd5b8151620004bc8162000412565b9392505050565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620004ee57607f821691505b6020821081036200050f57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200056357600081815260208120601f850160051c810160208610156200053e5750805b601f850160051c820191505b818110156200055f578281556001016200054a565b5050505b505050565b81516001600160401b03811115620005845762000584620004c3565b6200059c81620005958454620004d9565b8462000515565b602080601f831160018114620005d45760008415620005bb5750858301515b600019600386901b1c1916600185901b1785556200055f565b600085815260208120601f198616915b828110156200060557888601518255948401946001909101908401620005e4565b5085821015620006245787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a0516149de62000668600039600081816104f001526119bd01526000818161080c0152612fcd01526149de6000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610e2f578063f2fde38b14610e45578063fba7ffa314610e65578063fcdc1f6314610e9257600080fd5b8063d6051a7214610da2578063daee1aeb14610dc2578063dbef701e14610de2578063e0114adb14610e0257600080fd5b8063c357f1f3116100dc578063c357f1f314610c80578063c804802214610cda578063c98f10b014610cfa578063d355852814610d4357600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c6057600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b80634b56a42e116102e2578063642f6cef116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063642f6cef146107fa57806369cdbadb1461083e57806369e9b7731461086b5780636e04ff0d1461089857600080fd5b80635d4ee7f3116102b15780635d4ee7f3146107565780635f17e6161461076b57806360457ff51461078b578063636092e8146107b857600080fd5b80634b56a42e146106c657806351c98be3146106f457806357970e9314610714578063597109921461074157600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c146106395780634585e33b1461065957806345d2ec171461067957806346e7a63e1461069957600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b610426366004613716565b610ebf565b005b34801561043957600080fd5b5061042b610448366004613837565b610ed6565b34801561045957600080fd5b5061046d6104683660046138d3565b611292565b60405161047a91906138f5565b60405180910390f35b34801561048f57600080fd5b506104a361049e366004613950565b611391565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc366004613985565b6113cf565b60405161047a9190613a0c565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a1f565b6114ef565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613a6d565b611572565b34801561058657600080fd5b506104a3610595366004613a8a565b61173c565b3480156105a657600080fd5b5061042b6105b5366004613afb565b6117a7565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a3610627366004613985565b60036020526000908152604090205481565b34801561064557600080fd5b506104a3610654366004613985565b611841565b34801561066557600080fd5b5061042b610674366004613b7f565b6118aa565b34801561068557600080fd5b5061046d610694366004613a1f565b611ad5565b3480156106a557600080fd5b506104a36106b4366004613985565b600a6020526000908152604090205481565b3480156106d257600080fd5b506106e66106e1366004613bb5565b611b44565b60405161047a929190613c89565b34801561070057600080fd5b5061042b61070f366004613ca4565b611b98565b34801561072057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561074d57600080fd5b5061042b611c3c565b34801561076257600080fd5b5061042b611e27565b34801561077757600080fd5b5061042b6107863660046138d3565b611f5e565b34801561079757600080fd5b506104a36107a6366004613985565b60076020526000908152604090205481565b3480156107c457600080fd5b506015546107dd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561080657600080fd5b5061082e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561084a57600080fd5b506104a3610859366004613985565b60086020526000908152604090205481565b34801561087757600080fd5b5061042b6108863660046138d3565b60009182526008602052604090912055565b3480156108a457600080fd5b506106e66108b3366004613b7f565b61202b565b3480156108c457600080fd5b5061082e6108d3366004613985565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a3610903366004613985565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a3610930366004613985565b60046020526000908152604090205481565b34801561094e57600080fd5b5061082e61095d366004613985565b612240565b34801561096e57600080fd5b5061042b612292565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613cfb565b61238f565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a366004613985565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a373660046138d3565b612420565b348015610a4857600080fd5b5061042b610a57366004613d47565b612665565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab33660046138d3565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae0366004613985565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b11366004613985565b6127ae565b348015610b2257600080fd5b506104d1610b31366004613985565b612810565b348015610b4257600080fd5b506104a37f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0881565b348015610b7657600080fd5b5061042b610b85366004613a8a565b6128bc565b348015610b9657600080fd5b5061042b610ba5366004613985565b601455565b348015610bb657600080fd5b5061042b610bc5366004613d77565b612925565b348015610bd657600080fd5b5061042b610be53660046138d3565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c12366004613985565b6129d0565b348015610c2357600080fd5b506104d16040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525081565b348015610c6c57600080fd5b5061042b610c7b366004613afb565b612a56565b348015610c8c57600080fd5b5061042b610c9b366004613d9c565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610ce657600080fd5b5061042b610cf5366004613985565b612af0565b348015610d0657600080fd5b506104d16040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525081565b348015610d4f57600080fd5b5061042b610d5e366004613db9565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610dae57600080fd5b50610545610dbd3660046138d3565b612b88565b348015610dce57600080fd5b5061042b610ddd366004613afb565b612bf1565b348015610dee57600080fd5b506104a3610dfd3660046138d3565b612cbc565b348015610e0e57600080fd5b506104a3610e1d366004613985565b60096020526000908152604090205481565b348015610e3b57600080fd5b506104a360145481565b348015610e5157600080fd5b5061042b610e60366004613a6d565b612ced565b348015610e7157600080fd5b506104a3610e80366004613985565b60066020526000908152604090205481565b348015610e9e57600080fd5b506104a3610ead366004613985565b60026020526000908152604090205481565b8051610ed29060169060208401906134e6565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610fbc908c1688613e05565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af115801561103a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061105e9190613e49565b5060008860ff1667ffffffffffffffff81111561107d5761107d6135c6565b6040519080825280602002602001820160405280156110a6578160200160208202803683370190505b50905060005b8960ff168160ff16101561124f5760006110c584612d01565b90508860ff166001036111fd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa15801561112a573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111709190810190613eb1565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111c99085908590600401613ee6565b600060405180830381600087803b1580156111e357600080fd5b505af11580156111f7573d6000803e3d6000fd5b50505050505b80838360ff168151811061121357611213613eff565b6020908102919091018101919091526000918252600881526040808320889055600790915290208490558061124781613f2e565b9150506110ac565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161127f91906138f5565b60405180910390a1505050505050505050565b606060006112a0600f612dcf565b90508084106112db576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036112f0576112ed8482613f4d565b92505b60008367ffffffffffffffff81111561130b5761130b6135c6565b604051908082528060200260200182016040528015611334578160200160208202803683370190505b50905060005b848110156113865761135761134f8288613f60565b600f90612dd9565b82828151811061136957611369613eff565b60209081029190910101528061137e81613f73565b91505061133a565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106113b957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0860001b81526020018460405160200161144091815260200190565b60405160208183030381529060405261145890613fab565b81526020016000801b81526020016000801b8152509050806040516020016114d89190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561155357602002820191906000526020600020905b81548152602001906001019080831161153f575b50505050509050611565818251612de5565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611608573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061162c9190613ffb565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156116cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116f39190614029565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261179d9383018282801561179157602002820191906000526020600020905b81548152602001906001019080831161177d575b50505050508484612e6a565b90505b9392505050565b8060005b818160ff16101561183b573063c8048022858560ff85168181106117d1576117d1613eff565b905060200201356040518263ffffffff1660e01b81526004016117f691815260200190565b600060405180830381600087803b15801561181057600080fd5b505af1158015611824573d6000803e3d6000fd5b50505050808061183390613f2e565b9150506117ab565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff16116118a2576000858152600d6020908152604080832061ffff8516845290915290205461188e9083613f60565b91508061189a81614046565b915050611857565b509392505050565b60005a90506000806118be84860186613bb5565b915091506000818060200190518101906118d89190614067565b600081815260056020908152604080832054600490925282205492935091906118ff612fc9565b90508260000361191f576000848152600560205260409020819055611a7a565b6000848152600360205260408120546119388484613f4d565b6119429190613f4d565b6000868152600e6020908152604080832054600d835281842061ffff9091168085529083528184208054835181860281018601909452808452959650909491929091908301828280156119b457602002820191906000526020600020905b8154815260200190600101908083116119a0575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611a2f57816119f181614046565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b600084815260066020526040812054611a94906001613f60565b6000868152600660209081526040808320849055600490915290208390559050611abe8583612420565b611ac98589846128bc565b50505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611b3757602002820191906000526020600020905b815481526020019060010190808311611b23575b5050505050905092915050565b6000606060008484604051602001611b5d929190614080565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611c355730635f17e616868684818110611bbc57611bbc613eff565b90506020020135856040518363ffffffff1660e01b8152600401611bf092919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611c0a57600080fd5b505af1158015611c1e573d6000803e3d6000fd5b505050508080611c2d90613f73565b915050611b9c565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611cb3573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611cf99190810190614114565b80519091506000611d08612fc9565b905060005b8281101561183b576000848281518110611d2957611d29613eff565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611da9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dcd91906141a5565b90508060ff16600103611e1257604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611e1f90613f73565b915050611d0d565b611e2f61306b565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611e9e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ec29190614067565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611f3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed29190613e49565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611f969161353c565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611ff2576000848152600d6020908152604080832061ffff851684529091528120611fe09161353c565b80611fea81614046565b915050611fab565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a9050600061204285870187613985565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff81111561207b5761207b6135c6565b6040519080825280601f01601f1916602001820160405280156120a5576020820181803683370190505b506040516020016120b7929190613ee6565b604051602081830303815290604052905060006120d2612fc9565b905060006120df86612240565b90505b835a6120ee9089613f4d565b6120fa90612710613f60565b101561213b5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556120e2565b8061215357600083985098505050505050505061156b565b6040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525060166040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525084896040516020016121d591815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252612237959493929160040161420f565b60405180910390fd5b600081815260056020526040812054810361225d57506001919050565b600082815260036020908152604080832054600490925290912054612280612fc9565b61228a9190613f4d565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612313576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401612237565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b5906123e99086908690869060040161435c565b600060405180830381600087803b15801561240357600080fd5b505af1158015612417573d6000803e3d6000fd5b50505050505050565b60145460008381526002602052604090205461243c9083613f4d565b1115610ed2576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa1580156124b2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526124f891908101906143de565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa15801561256d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061259191906144fd565b6015549091506125b59082906c01000000000000000000000000900460ff16613e05565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff16101561183b576015546125f89085906bffffffffffffffffffffffff16612665565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af11580156126ed573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127119190613e49565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561279257600080fd5b505af11580156127a6573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561280457602002820191906000526020600020905b8154815260200190600101908083116127f0575b50505050509050919050565b6016818154811061282057600080fd5b90600052602060002001600091509050805461283b906141c2565b80601f0160208091040260200160405190810160405280929190818152602001828054612867906141c2565b80156128b45780601f10612889576101008083540402835291602001916128b4565b820191906000526020600020905b81548152906001019060200180831161289757829003601f168201915b505050505081565b6000838152600760205260409020545b805a6128d89085613f4d565b6128e490612710613f60565b101561183b5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556128cc565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561299d57600080fd5b505af11580156129b1573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a4257600080fd5b505af1158015611c35573d6000803e3d6000fd5b8060005b818163ffffffff16101561183b573063af953a4a858563ffffffff8516818110612a8657612a86613eff565b905060200201356040518263ffffffff1660e01b8152600401612aab91815260200190565b600060405180830381600087803b158015612ac557600080fd5b505af1158015612ad9573d6000803e3d6000fd5b505050508080612ae89061451a565b915050612a5a565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612b5c57600080fd5b505af1158015612b70573d6000803e3d6000fd5b50505050610ed281600f6130ee90919063ffffffff16565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612be057602002820191906000526020600020905b815481526020019060010190808311612bcc575b505050505090506115658185612de5565b8060005b8181101561183b576000848483818110612c1157612c11613eff565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612c4a91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612c76929190613ee6565b600060405180830381600087803b158015612c9057600080fd5b505af1158015612ca4573d6000803e3d6000fd5b50505050508080612cb490613f73565b915050612bf5565b600c6020528160005260406000208181548110612cd857600080fd5b90600052602060002001600091509150505481565b612cf561306b565b612cfe816130fa565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612d5c908690600401614533565b6020604051808303816000875af1158015612d7b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d9f9190614067565b9050612dac600f826131ef565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061138b825490565b60006117a083836131fb565b815160009081908190841580612dfb5750808510155b15612e04578094505b60008092505b85831015612e6057866001612e1f8585613f4d565b612e299190613f4d565b81518110612e3957612e39613eff565b602002602001015181612e4c9190613f60565b905082612e5881613f73565b935050612e0a565b9694955050505050565b82516000908190831580612e7e5750808410155b15612e87578093505b60008467ffffffffffffffff811115612ea257612ea26135c6565b604051908082528060200260200182016040528015612ecb578160200160208202803683370190505b509050600092505b84831015612f3957866001612ee88585613f4d565b612ef29190613f4d565b81518110612f0257612f02613eff565b6020026020010151818481518110612f1c57612f1c613eff565b602090810291909101015282612f3181613f73565b935050612ed3565b612f5281600060018451612f4d9190613f4d565b613225565b85606403612f8b578060018251612f699190613f4d565b81518110612f7957612f79613eff565b602002602001015193505050506117a0565b806064825188612f9b9190614685565b612fa591906146f1565b81518110612fb557612fb5613eff565b602002602001015193505050509392505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561306657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561303d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130619190614067565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff1633146130ec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612237565b565b60006117a0838361339d565b3373ffffffffffffffffffffffffffffffffffffffff821603613179576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612237565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006117a08383613497565b600082600001828154811061321257613212613eff565b9060005260206000200154905092915050565b8181808203613235575050505050565b60008560026132448787614705565b61324e9190614725565b613258908761478d565b8151811061326857613268613eff565b602002602001015190505b818313613377575b8086848151811061328e5761328e613eff565b602002602001015110156132ae57826132a6816147b5565b93505061327b565b8582815181106132c0576132c0613eff565b60200260200101518110156132e157816132d9816147e6565b9250506132ae565b818313613372578582815181106132fa576132fa613eff565b602002602001015186848151811061331457613314613eff565b602002602001015187858151811061332e5761332e613eff565b6020026020010188858151811061334757613347613eff565b60209081029190910101919091525282613360816147b5565b935050818061336e906147e6565b9250505b613273565b8185121561338a5761338a868684613225565b838312156127a6576127a6868486613225565b600081815260018301602052604081205480156134865760006133c1600183613f4d565b85549091506000906133d590600190613f4d565b905081811461343a5760008660000182815481106133f5576133f5613eff565b906000526020600020015490508087600001848154811061341857613418613eff565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061344b5761344b61483d565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061138b565b600091505061138b565b5092915050565b60008181526001830160205260408120546134de5750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561138b565b50600061138b565b82805482825590600052602060002090810192821561352c579160200282015b8281111561352c578251829061351c90826148b7565b5091602001919060010190613506565b5061353892915061355a565b5090565b5080546000825590600052602060002090810190612cfe9190613577565b8082111561353857600061356e828261358c565b5060010161355a565b5b808211156135385760008155600101613578565b508054613598906141c2565b6000825580601f106135a8575050565b601f016020900490600052602060002090810190612cfe9190613577565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715613619576136196135c6565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613666576136666135c6565b604052919050565b600067ffffffffffffffff821115613688576136886135c6565b5060051b60200190565b600067ffffffffffffffff8211156136ac576136ac6135c6565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b60006136eb6136e684613692565b61361f565b90508281528383830111156136ff57600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561372957600080fd5b823567ffffffffffffffff8082111561374157600080fd5b818501915085601f83011261375557600080fd5b81356137636136e68261366e565b81815260059190911b8301840190848101908883111561378257600080fd5b8585015b838110156137cf5780358581111561379e5760008081fd5b8601603f81018b136137b05760008081fd5b6137c18b89830135604084016136d8565b845250918601918601613786565b5098975050505050505050565b60ff81168114612cfe57600080fd5b63ffffffff81168114612cfe57600080fd5b600082601f83011261380e57600080fd5b6117a0838335602085016136d8565b6bffffffffffffffffffffffff81168114612cfe57600080fd5b600080600080600080600060e0888a03121561385257600080fd5b873561385d816137dc565b9650602088013561386d816137eb565b9550604088013561387d816137dc565b9450606088013567ffffffffffffffff81111561389957600080fd5b6138a58a828b016137fd565b94505060808801356138b68161381d565b9699959850939692959460a0840135945060c09093013592915050565b600080604083850312156138e657600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561392d57835183529284019291840191600101613911565b50909695505050505050565b803561ffff8116811461394b57600080fd5b919050565b60008060006060848603121561396557600080fd5b8335925061397560208501613939565b9150604084013590509250925092565b60006020828403121561399757600080fd5b5035919050565b60005b838110156139b95781810151838201526020016139a1565b50506000910152565b600081518084526139da81602086016020860161399e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117a060208301846139c2565b60008060408385031215613a3257600080fd5b82359150613a4260208401613939565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612cfe57600080fd5b600060208284031215613a7f57600080fd5b81356117a081613a4b565b600080600060608486031215613a9f57600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613ac857600080fd5b50813567ffffffffffffffff811115613ae057600080fd5b6020830191508360208260051b850101111561156b57600080fd5b60008060208385031215613b0e57600080fd5b823567ffffffffffffffff811115613b2557600080fd5b613b3185828601613ab6565b90969095509350505050565b60008083601f840112613b4f57600080fd5b50813567ffffffffffffffff811115613b6757600080fd5b60208301915083602082850101111561156b57600080fd5b60008060208385031215613b9257600080fd5b823567ffffffffffffffff811115613ba957600080fd5b613b3185828601613b3d565b60008060408385031215613bc857600080fd5b823567ffffffffffffffff80821115613be057600080fd5b818501915085601f830112613bf457600080fd5b81356020613c046136e68361366e565b82815260059290921b84018101918181019089841115613c2357600080fd5b8286015b84811015613c5b57803586811115613c3f5760008081fd5b613c4d8c86838b01016137fd565b845250918301918301613c27565b5096505086013592505080821115613c7257600080fd5b50613c7f858286016137fd565b9150509250929050565b821515815260406020820152600061179d60408301846139c2565b600080600060408486031215613cb957600080fd5b833567ffffffffffffffff811115613cd057600080fd5b613cdc86828701613ab6565b9094509250506020840135613cf0816137eb565b809150509250925092565b600080600060408486031215613d1057600080fd5b83359250602084013567ffffffffffffffff811115613d2e57600080fd5b613d3a86828701613b3d565b9497909650939450505050565b60008060408385031215613d5a57600080fd5b823591506020830135613d6c8161381d565b809150509250929050565b60008060408385031215613d8a57600080fd5b823591506020830135613d6c816137eb565b600060208284031215613dae57600080fd5b81356117a08161381d565b600060208284031215613dcb57600080fd5b81356117a0816137dc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613e3057613e30613dd6565b02949350505050565b8051801515811461394b57600080fd5b600060208284031215613e5b57600080fd5b6117a082613e39565b600082601f830112613e7557600080fd5b8151613e836136e682613692565b818152846020838601011115613e9857600080fd5b613ea982602083016020870161399e565b949350505050565b600060208284031215613ec357600080fd5b815167ffffffffffffffff811115613eda57600080fd5b613ea984828501613e64565b82815260406020820152600061179d60408301846139c2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103613f4457613f44613dd6565b60010192915050565b8181038181111561138b5761138b613dd6565b8082018082111561138b5761138b613dd6565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa457613fa4613dd6565b5060010190565b80516020808301519190811015613fea577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161394b81613a4b565b6000806040838503121561400e57600080fd5b825161401981613a4b565b6020939093015192949293505050565b60006020828403121561403b57600080fd5b81516117a081613a4b565b600061ffff80831681810361405d5761405d613dd6565b6001019392505050565b60006020828403121561407957600080fd5b5051919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156140f5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030185526140e38683516139c2565b955093820193908201906001016140a9565b50508584038187015250505061410b81856139c2565b95945050505050565b6000602080838503121561412757600080fd5b825167ffffffffffffffff81111561413e57600080fd5b8301601f8101851361414f57600080fd5b805161415d6136e68261366e565b81815260059190911b8201830190838101908783111561417c57600080fd5b928401925b8284101561419a57835182529284019290840190614181565b979650505050505050565b6000602082840312156141b757600080fd5b81516117a0816137dc565b600181811c908216806141d657607f821691505b602082108103613fea577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60a08152600061422260a08301886139c2565b602083820381850152818854808452828401915060058382821b86010160008c8152858120815b8581101561431c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0898503018752828254614284816141c2565b8087526001828116801561429f57600181146142d657614305565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0084168d8a01528c8315158b1b8a01019450614305565b8688528c8820885b848110156142fd5781548f828d01015283820191508e810190506142de565b8a018e019550505b50998b019992965050509190910190600101614249565b5050508781036040890152614331818c6139c2565b95505050505050846060840152828103608084015261435081856139c2565b98975050505050505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b805161394b816137eb565b805161394b8161381d565b805167ffffffffffffffff8116811461394b57600080fd5b6000602082840312156143f057600080fd5b815167ffffffffffffffff8082111561440857600080fd5b90830190610140828603121561441d57600080fd5b6144256135f5565b61442e83613ff0565b815261443c602084016143b0565b602082015260408301518281111561445357600080fd5b61445f87828601613e64565b604083015250614471606084016143bb565b606082015261448260808401613ff0565b608082015261449360a084016143c6565b60a08201526144a460c084016143b0565b60c08201526144b560e084016143bb565b60e08201526101006144c8818501613e39565b9082015261012083810151838111156144e057600080fd5b6144ec88828701613e64565b918301919091525095945050505050565b60006020828403121561450f57600080fd5b81516117a08161381d565b600063ffffffff80831681810361405d5761405d613dd6565b60208152600082516101408060208501526145526101608501836139c2565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261458e84836139c2565b9350604087015191506145b9606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e087015261461a84836139c2565b935060e0870151915061010081878603018188015261463985846139c2565b94508088015192505061012081878603018188015261465885846139c2565b9450808801519250505061467b828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156146bd576146bd613dd6565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082614700576147006146c2565b500490565b818103600083128015838313168383128216171561349057613490613dd6565b600082614734576147346146c2565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561478857614788613dd6565b500590565b80820182811260008312801582168215821617156147ad576147ad613dd6565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa457613fa4613dd6565b60007f8000000000000000000000000000000000000000000000000000000000000000820361481757614817613dd6565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f8211156148b257600081815260208120601f850160051c810160208610156148935750805b601f850160051c820191505b818110156127a65782815560010161489f565b505050565b815167ffffffffffffffff8111156148d1576148d16135c6565b6148e5816148df84546141c2565b8461486c565b602080601f83116001811461493857600084156149025750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556127a6565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561498557888601518255948401946001909101908401614966565b50858210156149c157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307835353533343434333264353535333434326434313532343234393534353235353464326435343435353335343465343535343030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0526101c0604052604261014081815260e09182919062005078610160398152602001604051806080016040528060428152602001620050ba604291398152602001604051806080016040528060428152602001620050fc604291399052620000b89060169060036200035f565b50348015620000c657600080fd5b506040516200513e3803806200513e833981016040819052620000e9916200044c565b81813380600081620001425760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000175576200017581620002b4565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001d2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001f891906200048f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200025e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002849190620004c0565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a0525062000658915050565b336001600160a01b038216036200030e5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000139565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003aa579160200282015b82811115620003aa57825182906200039990826200058c565b509160200191906001019062000380565b50620003b8929150620003bc565b5090565b80821115620003b8576000620003d38282620003dd565b50600101620003bc565b508054620003eb90620004fd565b6000825580601f10620003fc575050565b601f0160209004906000526020600020908101906200041c91906200041f565b50565b5b80821115620003b8576000815560010162000420565b6001600160a01b03811681146200041c57600080fd5b600080604083850312156200046057600080fd5b82516200046d8162000436565b602084015190925080151581146200048457600080fd5b809150509250929050565b60008060408385031215620004a357600080fd5b8251620004b08162000436565b6020939093015192949293505050565b600060208284031215620004d357600080fd5b8151620004e08162000436565b9392505050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200051257607f821691505b6020821081036200053357634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200058757600081815260208120601f850160051c81016020861015620005625750805b601f850160051c820191505b8181101562000583578281556001016200056e565b5050505b505050565b81516001600160401b03811115620005a857620005a8620004e7565b620005c081620005b98454620004fd565b8462000539565b602080601f831160018114620005f85760008415620005df5750858301515b600019600386901b1c1916600185901b17855562000583565b600085815260208120601f198616915b82811015620006295788860151825594840194600190910190840162000608565b5085821015620006485787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c0516149db6200069d600039600081816104f001526119ba01526000818161080c0152612fca015260008181610b48015261140601526149db6000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610e2f578063f2fde38b14610e45578063fba7ffa314610e65578063fcdc1f6314610e9257600080fd5b8063d6051a7214610da2578063daee1aeb14610dc2578063dbef701e14610de2578063e0114adb14610e0257600080fd5b8063c357f1f3116100dc578063c357f1f314610c80578063c804802214610cda578063c98f10b014610cfa578063d355852814610d4357600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c6057600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b80634b56a42e116102e2578063642f6cef116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063642f6cef146107fa57806369cdbadb1461083e57806369e9b7731461086b5780636e04ff0d1461089857600080fd5b80635d4ee7f3116102b15780635d4ee7f3146107565780635f17e6161461076b57806360457ff51461078b578063636092e8146107b857600080fd5b80634b56a42e146106c657806351c98be3146106f457806357970e9314610714578063597109921461074157600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c146106395780634585e33b1461065957806345d2ec171461067957806346e7a63e1461069957600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b610426366004613713565b610ebf565b005b34801561043957600080fd5b5061042b610448366004613834565b610ed6565b34801561045957600080fd5b5061046d6104683660046138d0565b611292565b60405161047a91906138f2565b60405180910390f35b34801561048f57600080fd5b506104a361049e36600461394d565b611391565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc366004613982565b6113cf565b60405161047a9190613a09565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a1c565b6114ec565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613a6a565b61156f565b34801561058657600080fd5b506104a3610595366004613a87565b611739565b3480156105a657600080fd5b5061042b6105b5366004613af8565b6117a4565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a3610627366004613982565b60036020526000908152604090205481565b34801561064557600080fd5b506104a3610654366004613982565b61183e565b34801561066557600080fd5b5061042b610674366004613b7c565b6118a7565b34801561068557600080fd5b5061046d610694366004613a1c565b611ad2565b3480156106a557600080fd5b506104a36106b4366004613982565b600a6020526000908152604090205481565b3480156106d257600080fd5b506106e66106e1366004613bb2565b611b41565b60405161047a929190613c86565b34801561070057600080fd5b5061042b61070f366004613ca1565b611b95565b34801561072057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561074d57600080fd5b5061042b611c39565b34801561076257600080fd5b5061042b611e24565b34801561077757600080fd5b5061042b6107863660046138d0565b611f5b565b34801561079757600080fd5b506104a36107a6366004613982565b60076020526000908152604090205481565b3480156107c457600080fd5b506015546107dd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561080657600080fd5b5061082e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561084a57600080fd5b506104a3610859366004613982565b60086020526000908152604090205481565b34801561087757600080fd5b5061042b6108863660046138d0565b60009182526008602052604090912055565b3480156108a457600080fd5b506106e66108b3366004613b7c565b612028565b3480156108c457600080fd5b5061082e6108d3366004613982565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a3610903366004613982565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a3610930366004613982565b60046020526000908152604090205481565b34801561094e57600080fd5b5061082e61095d366004613982565b61223d565b34801561096e57600080fd5b5061042b61228f565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613cf8565b61238c565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a366004613982565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a373660046138d0565b61241d565b348015610a4857600080fd5b5061042b610a57366004613d44565b612662565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab33660046138d0565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae0366004613982565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b11366004613982565b6127ab565b348015610b2257600080fd5b506104d1610b31366004613982565b61280d565b348015610b4257600080fd5b506104a37f000000000000000000000000000000000000000000000000000000000000000081565b348015610b7657600080fd5b5061042b610b85366004613a87565b6128b9565b348015610b9657600080fd5b5061042b610ba5366004613982565b601455565b348015610bb657600080fd5b5061042b610bc5366004613d74565b612922565b348015610bd657600080fd5b5061042b610be53660046138d0565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c12366004613982565b6129cd565b348015610c2357600080fd5b506104d16040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525081565b348015610c6c57600080fd5b5061042b610c7b366004613af8565b612a53565b348015610c8c57600080fd5b5061042b610c9b366004613d99565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610ce657600080fd5b5061042b610cf5366004613982565b612aed565b348015610d0657600080fd5b506104d16040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525081565b348015610d4f57600080fd5b5061042b610d5e366004613db6565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610dae57600080fd5b50610545610dbd3660046138d0565b612b85565b348015610dce57600080fd5b5061042b610ddd366004613af8565b612bee565b348015610dee57600080fd5b506104a3610dfd3660046138d0565b612cb9565b348015610e0e57600080fd5b506104a3610e1d366004613982565b60096020526000908152604090205481565b348015610e3b57600080fd5b506104a360145481565b348015610e5157600080fd5b5061042b610e60366004613a6a565b612cea565b348015610e7157600080fd5b506104a3610e80366004613982565b60066020526000908152604090205481565b348015610e9e57600080fd5b506104a3610ead366004613982565b60026020526000908152604090205481565b8051610ed29060169060208401906134e3565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610fbc908c1688613e02565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af115801561103a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061105e9190613e46565b5060008860ff1667ffffffffffffffff81111561107d5761107d6135c3565b6040519080825280602002602001820160405280156110a6578160200160208202803683370190505b50905060005b8960ff168160ff16101561124f5760006110c584612cfe565b90508860ff166001036111fd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa15801561112a573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111709190810190613eae565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111c99085908590600401613ee3565b600060405180830381600087803b1580156111e357600080fd5b505af11580156111f7573d6000803e3d6000fd5b50505050505b80838360ff168151811061121357611213613efc565b6020908102919091018101919091526000918252600881526040808320889055600790915290208490558061124781613f2b565b9150506110ac565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161127f91906138f2565b60405180910390a1505050505050505050565b606060006112a0600f612dcc565b90508084106112db576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036112f0576112ed8482613f4a565b92505b60008367ffffffffffffffff81111561130b5761130b6135c3565b604051908082528060200260200182016040528015611334578160200160208202803683370190505b50905060005b848110156113865761135761134f8288613f5d565b600f90612dd6565b82828151811061136957611369613efc565b60209081029190910101528061137e81613f70565b91505061133a565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106113b957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f000000000000000000000000000000000000000000000000000000000000000081526020018460405160200161143d91815260200190565b60405160208183030381529060405261145590613fa8565b81526020016000801b81526020016000801b8152509050806040516020016114d59190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561155057602002820191906000526020600020905b81548152602001906001019080831161153c575b50505050509050611562818251612de2565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611605573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116299190613ff8565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156116cc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116f09190614026565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261179a9383018282801561178e57602002820191906000526020600020905b81548152602001906001019080831161177a575b50505050508484612e67565b90505b9392505050565b8060005b818160ff161015611838573063c8048022858560ff85168181106117ce576117ce613efc565b905060200201356040518263ffffffff1660e01b81526004016117f391815260200190565b600060405180830381600087803b15801561180d57600080fd5b505af1158015611821573d6000803e3d6000fd5b50505050808061183090613f2b565b9150506117a8565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff161161189f576000858152600d6020908152604080832061ffff8516845290915290205461188b9083613f5d565b91508061189781614043565b915050611854565b509392505050565b60005a90506000806118bb84860186613bb2565b915091506000818060200190518101906118d59190614064565b600081815260056020908152604080832054600490925282205492935091906118fc612fc6565b90508260000361191c576000848152600560205260409020819055611a77565b6000848152600360205260408120546119358484613f4a565b61193f9190613f4a565b6000868152600e6020908152604080832054600d835281842061ffff9091168085529083528184208054835181860281018601909452808452959650909491929091908301828280156119b157602002820191906000526020600020905b81548152602001906001019080831161199d575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611a2c57816119ee81614043565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b600084815260066020526040812054611a91906001613f5d565b6000868152600660209081526040808320849055600490915290208390559050611abb858361241d565b611ac68589846128b9565b50505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611b3457602002820191906000526020600020905b815481526020019060010190808311611b20575b5050505050905092915050565b6000606060008484604051602001611b5a92919061407d565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611c325730635f17e616868684818110611bb957611bb9613efc565b90506020020135856040518363ffffffff1660e01b8152600401611bed92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611c0757600080fd5b505af1158015611c1b573d6000803e3d6000fd5b505050508080611c2a90613f70565b915050611b99565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611cb0573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611cf69190810190614111565b80519091506000611d05612fc6565b905060005b82811015611838576000848281518110611d2657611d26613efc565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611da6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dca91906141a2565b90508060ff16600103611e0f57604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611e1c90613f70565b915050611d0a565b611e2c613068565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611e9b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ebf9190614064565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611f37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed29190613e46565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611f9391613539565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611fef576000848152600d6020908152604080832061ffff851684529091528120611fdd91613539565b80611fe781614043565b915050611fa8565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a9050600061203f85870187613982565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115612078576120786135c3565b6040519080825280601f01601f1916602001820160405280156120a2576020820181803683370190505b506040516020016120b4929190613ee3565b604051602081830303815290604052905060006120cf612fc6565b905060006120dc8661223d565b90505b835a6120eb9089613f4a565b6120f790612710613f5d565b10156121385781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556120df565b80612150576000839850985050505050505050611568565b6040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525060166040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525084896040516020016121d291815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252612234959493929160040161420c565b60405180910390fd5b600081815260056020526040812054810361225a57506001919050565b60008281526003602090815260408083205460049092529091205461227d612fc6565b6122879190613f4a565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612310576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401612234565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b5906123e690869086908690600401614359565b600060405180830381600087803b15801561240057600080fd5b505af1158015612414573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124399083613f4a565b1115610ed2576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa1580156124af573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526124f591908101906143db565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa15801561256a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061258e91906144fa565b6015549091506125b29082906c01000000000000000000000000900460ff16613e02565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff161015611838576015546125f59085906bffffffffffffffffffffffff16612662565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af11580156126ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061270e9190613e46565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561278f57600080fd5b505af11580156127a3573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561280157602002820191906000526020600020905b8154815260200190600101908083116127ed575b50505050509050919050565b6016818154811061281d57600080fd5b906000526020600020016000915090508054612838906141bf565b80601f0160208091040260200160405190810160405280929190818152602001828054612864906141bf565b80156128b15780601f10612886576101008083540402835291602001916128b1565b820191906000526020600020905b81548152906001019060200180831161289457829003601f168201915b505050505081565b6000838152600760205260409020545b805a6128d59085613f4a565b6128e190612710613f5d565b10156118385781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556128c9565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561299a57600080fd5b505af11580156129ae573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a3f57600080fd5b505af1158015611c32573d6000803e3d6000fd5b8060005b818163ffffffff161015611838573063af953a4a858563ffffffff8516818110612a8357612a83613efc565b905060200201356040518263ffffffff1660e01b8152600401612aa891815260200190565b600060405180830381600087803b158015612ac257600080fd5b505af1158015612ad6573d6000803e3d6000fd5b505050508080612ae590614517565b915050612a57565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612b5957600080fd5b505af1158015612b6d573d6000803e3d6000fd5b50505050610ed281600f6130eb90919063ffffffff16565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612bdd57602002820191906000526020600020905b815481526020019060010190808311612bc9575b505050505090506115628185612de2565b8060005b81811015611838576000848483818110612c0e57612c0e613efc565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612c4791815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612c73929190613ee3565b600060405180830381600087803b158015612c8d57600080fd5b505af1158015612ca1573d6000803e3d6000fd5b50505050508080612cb190613f70565b915050612bf2565b600c6020528160005260406000208181548110612cd557600080fd5b90600052602060002001600091509150505481565b612cf2613068565b612cfb816130f7565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612d59908690600401614530565b6020604051808303816000875af1158015612d78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d9c9190614064565b9050612da9600f826131ec565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061138b825490565b600061179d83836131f8565b815160009081908190841580612df85750808510155b15612e01578094505b60008092505b85831015612e5d57866001612e1c8585613f4a565b612e269190613f4a565b81518110612e3657612e36613efc565b602002602001015181612e499190613f5d565b905082612e5581613f70565b935050612e07565b9694955050505050565b82516000908190831580612e7b5750808410155b15612e84578093505b60008467ffffffffffffffff811115612e9f57612e9f6135c3565b604051908082528060200260200182016040528015612ec8578160200160208202803683370190505b509050600092505b84831015612f3657866001612ee58585613f4a565b612eef9190613f4a565b81518110612eff57612eff613efc565b6020026020010151818481518110612f1957612f19613efc565b602090810291909101015282612f2e81613f70565b935050612ed0565b612f4f81600060018451612f4a9190613f4a565b613222565b85606403612f88578060018251612f669190613f4a565b81518110612f7657612f76613efc565b6020026020010151935050505061179d565b806064825188612f989190614682565b612fa291906146ee565b81518110612fb257612fb2613efc565b602002602001015193505050509392505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561306357606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561303a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061305e9190614064565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff1633146130e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612234565b565b600061179d838361339a565b3373ffffffffffffffffffffffffffffffffffffffff821603613176576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612234565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600061179d8383613494565b600082600001828154811061320f5761320f613efc565b9060005260206000200154905092915050565b8181808203613232575050505050565b60008560026132418787614702565b61324b9190614722565b613255908761478a565b8151811061326557613265613efc565b602002602001015190505b818313613374575b8086848151811061328b5761328b613efc565b602002602001015110156132ab57826132a3816147b2565b935050613278565b8582815181106132bd576132bd613efc565b60200260200101518110156132de57816132d6816147e3565b9250506132ab565b81831361336f578582815181106132f7576132f7613efc565b602002602001015186848151811061331157613311613efc565b602002602001015187858151811061332b5761332b613efc565b6020026020010188858151811061334457613344613efc565b6020908102919091010191909152528261335d816147b2565b935050818061336b906147e3565b9250505b613270565b8185121561338757613387868684613222565b838312156127a3576127a3868486613222565b600081815260018301602052604081205480156134835760006133be600183613f4a565b85549091506000906133d290600190613f4a565b90508181146134375760008660000182815481106133f2576133f2613efc565b906000526020600020015490508087600001848154811061341557613415613efc565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134485761344861483a565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061138b565b600091505061138b565b5092915050565b60008181526001830160205260408120546134db5750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561138b565b50600061138b565b828054828255906000526020600020908101928215613529579160200282015b82811115613529578251829061351990826148b4565b5091602001919060010190613503565b50613535929150613557565b5090565b5080546000825590600052602060002090810190612cfb9190613574565b8082111561353557600061356b8282613589565b50600101613557565b5b808211156135355760008155600101613575565b508054613595906141bf565b6000825580601f106135a5575050565b601f016020900490600052602060002090810190612cfb9190613574565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715613616576136166135c3565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613663576136636135c3565b604052919050565b600067ffffffffffffffff821115613685576136856135c3565b5060051b60200190565b600067ffffffffffffffff8211156136a9576136a96135c3565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b60006136e86136e38461368f565b61361c565b90508281528383830111156136fc57600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561372657600080fd5b823567ffffffffffffffff8082111561373e57600080fd5b818501915085601f83011261375257600080fd5b81356137606136e38261366b565b81815260059190911b8301840190848101908883111561377f57600080fd5b8585015b838110156137cc5780358581111561379b5760008081fd5b8601603f81018b136137ad5760008081fd5b6137be8b89830135604084016136d5565b845250918601918601613783565b5098975050505050505050565b60ff81168114612cfb57600080fd5b63ffffffff81168114612cfb57600080fd5b600082601f83011261380b57600080fd5b61179d838335602085016136d5565b6bffffffffffffffffffffffff81168114612cfb57600080fd5b600080600080600080600060e0888a03121561384f57600080fd5b873561385a816137d9565b9650602088013561386a816137e8565b9550604088013561387a816137d9565b9450606088013567ffffffffffffffff81111561389657600080fd5b6138a28a828b016137fa565b94505060808801356138b38161381a565b9699959850939692959460a0840135945060c09093013592915050565b600080604083850312156138e357600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561392a5783518352928401929184019160010161390e565b50909695505050505050565b803561ffff8116811461394857600080fd5b919050565b60008060006060848603121561396257600080fd5b8335925061397260208501613936565b9150604084013590509250925092565b60006020828403121561399457600080fd5b5035919050565b60005b838110156139b657818101518382015260200161399e565b50506000910152565b600081518084526139d781602086016020860161399b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061179d60208301846139bf565b60008060408385031215613a2f57600080fd5b82359150613a3f60208401613936565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612cfb57600080fd5b600060208284031215613a7c57600080fd5b813561179d81613a48565b600080600060608486031215613a9c57600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613ac557600080fd5b50813567ffffffffffffffff811115613add57600080fd5b6020830191508360208260051b850101111561156857600080fd5b60008060208385031215613b0b57600080fd5b823567ffffffffffffffff811115613b2257600080fd5b613b2e85828601613ab3565b90969095509350505050565b60008083601f840112613b4c57600080fd5b50813567ffffffffffffffff811115613b6457600080fd5b60208301915083602082850101111561156857600080fd5b60008060208385031215613b8f57600080fd5b823567ffffffffffffffff811115613ba657600080fd5b613b2e85828601613b3a565b60008060408385031215613bc557600080fd5b823567ffffffffffffffff80821115613bdd57600080fd5b818501915085601f830112613bf157600080fd5b81356020613c016136e38361366b565b82815260059290921b84018101918181019089841115613c2057600080fd5b8286015b84811015613c5857803586811115613c3c5760008081fd5b613c4a8c86838b01016137fa565b845250918301918301613c24565b5096505086013592505080821115613c6f57600080fd5b50613c7c858286016137fa565b9150509250929050565b821515815260406020820152600061179a60408301846139bf565b600080600060408486031215613cb657600080fd5b833567ffffffffffffffff811115613ccd57600080fd5b613cd986828701613ab3565b9094509250506020840135613ced816137e8565b809150509250925092565b600080600060408486031215613d0d57600080fd5b83359250602084013567ffffffffffffffff811115613d2b57600080fd5b613d3786828701613b3a565b9497909650939450505050565b60008060408385031215613d5757600080fd5b823591506020830135613d698161381a565b809150509250929050565b60008060408385031215613d8757600080fd5b823591506020830135613d69816137e8565b600060208284031215613dab57600080fd5b813561179d8161381a565b600060208284031215613dc857600080fd5b813561179d816137d9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613e2d57613e2d613dd3565b02949350505050565b8051801515811461394857600080fd5b600060208284031215613e5857600080fd5b61179d82613e36565b600082601f830112613e7257600080fd5b8151613e806136e38261368f565b818152846020838601011115613e9557600080fd5b613ea682602083016020870161399b565b949350505050565b600060208284031215613ec057600080fd5b815167ffffffffffffffff811115613ed757600080fd5b613ea684828501613e61565b82815260406020820152600061179a60408301846139bf565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103613f4157613f41613dd3565b60010192915050565b8181038181111561138b5761138b613dd3565b8082018082111561138b5761138b613dd3565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa157613fa1613dd3565b5060010190565b80516020808301519190811015613fe7577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161394881613a48565b6000806040838503121561400b57600080fd5b825161401681613a48565b6020939093015192949293505050565b60006020828403121561403857600080fd5b815161179d81613a48565b600061ffff80831681810361405a5761405a613dd3565b6001019392505050565b60006020828403121561407657600080fd5b5051919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156140f2577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030185526140e08683516139bf565b955093820193908201906001016140a6565b50508584038187015250505061410881856139bf565b95945050505050565b6000602080838503121561412457600080fd5b825167ffffffffffffffff81111561413b57600080fd5b8301601f8101851361414c57600080fd5b805161415a6136e38261366b565b81815260059190911b8201830190838101908783111561417957600080fd5b928401925b828410156141975783518252928401929084019061417e565b979650505050505050565b6000602082840312156141b457600080fd5b815161179d816137d9565b600181811c908216806141d357607f821691505b602082108103613fe7577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60a08152600061421f60a08301886139bf565b602083820381850152818854808452828401915060058382821b86010160008c8152858120815b85811015614319577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0898503018752828254614281816141bf565b8087526001828116801561429c57600181146142d357614302565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0084168d8a01528c8315158b1b8a01019450614302565b8688528c8820885b848110156142fa5781548f828d01015283820191508e810190506142db565b8a018e019550505b50998b019992965050509190910190600101614246565b505050878103604089015261432e818c6139bf565b95505050505050846060840152828103608084015261434d81856139bf565b98975050505050505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b8051613948816137e8565b80516139488161381a565b805167ffffffffffffffff8116811461394857600080fd5b6000602082840312156143ed57600080fd5b815167ffffffffffffffff8082111561440557600080fd5b90830190610140828603121561441a57600080fd5b6144226135f2565b61442b83613fed565b8152614439602084016143ad565b602082015260408301518281111561445057600080fd5b61445c87828601613e61565b60408301525061446e606084016143b8565b606082015261447f60808401613fed565b608082015261449060a084016143c3565b60a08201526144a160c084016143ad565b60c08201526144b260e084016143b8565b60e08201526101006144c5818501613e36565b9082015261012083810151838111156144dd57600080fd5b6144e988828701613e61565b918301919091525095945050505050565b60006020828403121561450c57600080fd5b815161179d8161381a565b600063ffffffff80831681810361405a5761405a613dd3565b602081526000825161014080602085015261454f6101608501836139bf565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261458b84836139bf565b9350604087015191506145b6606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e087015261461784836139bf565b935060e0870151915061010081878603018188015261463685846139bf565b94508088015192505061012081878603018188015261465585846139bf565b94508088015192505050614678828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156146ba576146ba613dd3565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826146fd576146fd6146bf565b500490565b818103600083128015838313168383128216171561348d5761348d613dd3565b600082614731576147316146bf565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561478557614785613dd3565b500590565b80820182811260008312801582168215821617156147aa576147aa613dd3565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa157613fa1613dd3565b60007f8000000000000000000000000000000000000000000000000000000000000000820361481457614814613dd3565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f8211156148af57600081815260208120601f850160051c810160208610156148905750805b601f850160051c820191505b818110156127a35782815560010161489c565b505050565b815167ffffffffffffffff8111156148ce576148ce6135c3565b6148e2816148dc84546141bf565b84614869565b602080601f83116001811461493557600084156148ff5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556127a3565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561498257888601518255948401946001909101908401614963565b50858210156149be57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307835353533343434333264353535333434326434313532343234393534353235353464326435343435353335343465343535343030303030303030303030303030", } var VerifiableLoadMercuryUpkeepABI = VerifiableLoadMercuryUpkeepMetaData.ABI var VerifiableLoadMercuryUpkeepBin = VerifiableLoadMercuryUpkeepMetaData.Bin -func DeployVerifiableLoadMercuryUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, registrarAddress common.Address, useArb bool) (common.Address, *types.Transaction, *VerifiableLoadMercuryUpkeep, error) { +func DeployVerifiableLoadMercuryUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, useArb bool) (common.Address, *types.Transaction, *VerifiableLoadMercuryUpkeep, error) { parsed, err := VerifiableLoadMercuryUpkeepMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -48,7 +48,7 @@ func DeployVerifiableLoadMercuryUpkeep(auth *bind.TransactOpts, backend bind.Con return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadMercuryUpkeepBin), backend, registrarAddress, useArb) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadMercuryUpkeepBin), backend, _registrar, useArb) if err != nil { return common.Address{}, nil, nil, err } diff --git a/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go index dae8eaf30bf..29edcdc0d9f 100644 --- a/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go @@ -31,15 +31,15 @@ var ( ) var VerifiableLoadUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"registrarAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60c06040526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460a0523480156200003a57600080fd5b50604051620044c2380380620044c28339810160408190526200005d91620002ec565b81813380600081620000b65760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000e957620000e98162000228565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa15801562000146573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200016c91906200032f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620001d2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001f8919062000360565b601280546001600160a01b0319166001600160a01b03929092169190911790555015156080525062000387915050565b336001600160a01b03821603620002825760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000ad565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620002e957600080fd5b50565b600080604083850312156200030057600080fd5b82516200030d81620002d3565b602084015190925080151581146200032457600080fd5b809150509250929050565b600080604083850312156200034357600080fd5b82516200035081620002d3565b6020939093015192949293505050565b6000602082840312156200037357600080fd5b81516200038081620002d3565b9392505050565b60805160a051614107620003bb6000396000818161049901526118630152600081816107870152612c9201526141076000f3fe6080604052600436106103905760003560e01c8063776898c8116101dc578063a72aa27e11610102578063d6051a72116100a0578063e45530831161006f578063e455308314610d06578063f2fde38b14610d1c578063fba7ffa314610d3c578063fcdc1f6314610d6957600080fd5b8063d6051a7214610c79578063daee1aeb14610c99578063dbef701e14610cb9578063e0114adb14610cd957600080fd5b8063becde0e1116100dc578063becde0e114610b80578063c357f1f314610ba0578063c804802214610bfa578063d355852814610c1a57600080fd5b8063a72aa27e14610b13578063a79c404314610b33578063af953a4a14610b6057600080fd5b8063948108f71161017a5780639d385eaa116101495780639d385eaa14610a7f578063a654824814610a9f578063a6b5947514610ad3578063a6c60d8914610af357600080fd5b8063948108f7146109c55780639ac542eb146109e55780639b42935414610a215780639b51fb0d14610a4e57600080fd5b80637e7a46dc116101b65780637e7a46dc1461092d5780638da5cb5b1461094d5780638fcb3fba14610978578063924ca578146109a557600080fd5b8063776898c8146108cb57806379ba5097146108eb5780637b1039991461090057600080fd5b806346e7a63e116102c1578063636092e81161025f5780636e04ff0d1161022e5780636e04ff0d146108135780637145f11b1461084157806373644cce14610871578063767213031461089e57600080fd5b8063636092e814610733578063642f6cef1461077557806369cdbadb146107b957806369e9b773146107e657600080fd5b8063597109921161029b57806359710992146106bc5780635d4ee7f3146106d15780635f17e616146106e657806360457ff51461070657600080fd5b806346e7a63e1461064257806351c98be31461066f57806357970e931461068f57600080fd5b806328c4b57b1161032e578063328ffd1111610308578063328ffd11146105b55780633ebe8d6c146105e25780634585e33b1461060257806345d2ec171461062257600080fd5b806328c4b57b146105235780632a9032d3146105435780632b20e3971461056357600080fd5b80630d4a4fb11161036a5780630d4a4fb11461045a57806312c5502714610487578063206c32e8146104ce57806320e3dbd41461050357600080fd5b806306c1cc00146103d457806306e3b632146103f6578063077ac6211461042c57600080fd5b366103cf57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b3480156103e057600080fd5b506103f46103ef36600461335c565b610d96565b005b34801561040257600080fd5b506104166104113660046133f8565b611152565b604051610423919061341a565b60405180910390f35b34801561043857600080fd5b5061044c610447366004613475565b611251565b604051908152602001610423565b34801561046657600080fd5b5061047a6104753660046134aa565b61128f565b6040516104239190613531565b34801561049357600080fd5b506104bb7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610423565b3480156104da57600080fd5b506104ee6104e9366004613544565b6113af565b60408051928352602083019190915201610423565b34801561050f57600080fd5b506103f461051e366004613592565b611432565b34801561052f57600080fd5b5061044c61053e3660046135af565b6115fc565b34801561054f57600080fd5b506103f461055e366004613620565b611667565b34801561056f57600080fd5b506011546105909073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610423565b3480156105c157600080fd5b5061044c6105d03660046134aa565b60036020526000908152604090205481565b3480156105ee57600080fd5b5061044c6105fd3660046134aa565b611701565b34801561060e57600080fd5b506103f461061d3660046136a4565b61176a565b34801561062e57600080fd5b5061041661063d366004613544565b611979565b34801561064e57600080fd5b5061044c61065d3660046134aa565b600a6020526000908152604090205481565b34801561067b57600080fd5b506103f461068a3660046136da565b6119e8565b34801561069b57600080fd5b506012546105909073ffffffffffffffffffffffffffffffffffffffff1681565b3480156106c857600080fd5b506103f4611a8c565b3480156106dd57600080fd5b506103f4611c77565b3480156106f257600080fd5b506103f46107013660046133f8565b611db2565b34801561071257600080fd5b5061044c6107213660046134aa565b60076020526000908152604090205481565b34801561073f57600080fd5b50601554610758906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610423565b34801561078157600080fd5b506107a97f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610423565b3480156107c557600080fd5b5061044c6107d43660046134aa565b60086020526000908152604090205481565b3480156107f257600080fd5b506103f46108013660046133f8565b60009182526008602052604090912055565b34801561081f57600080fd5b5061083361082e3660046136a4565b611e7f565b604051610423929190613731565b34801561084d57600080fd5b506107a961085c3660046134aa565b600b6020526000908152604090205460ff1681565b34801561087d57600080fd5b5061044c61088c3660046134aa565b6000908152600c602052604090205490565b3480156108aa57600080fd5b5061044c6108b93660046134aa565b60046020526000908152604090205481565b3480156108d757600080fd5b506107a96108e63660046134aa565b611fac565b3480156108f757600080fd5b506103f4611ffe565b34801561090c57600080fd5b506013546105909073ffffffffffffffffffffffffffffffffffffffff1681565b34801561093957600080fd5b506103f461094836600461374c565b612100565b34801561095957600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610590565b34801561098457600080fd5b5061044c6109933660046134aa565b60056020526000908152604090205481565b3480156109b157600080fd5b506103f46109c03660046133f8565b612191565b3480156109d157600080fd5b506103f46109e0366004613798565b6123d6565b3480156109f157600080fd5b50601554610a0f906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610423565b348015610a2d57600080fd5b506103f4610a3c3660046133f8565b60009182526009602052604090912055565b348015610a5a57600080fd5b506104bb610a693660046134aa565b600e6020526000908152604090205461ffff1681565b348015610a8b57600080fd5b50610416610a9a3660046134aa565b61251f565b348015610aab57600080fd5b5061044c7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0881565b348015610adf57600080fd5b506103f4610aee3660046135af565b612581565b348015610aff57600080fd5b506103f4610b0e3660046134aa565b601455565b348015610b1f57600080fd5b506103f4610b2e3660046137c8565b6125ea565b348015610b3f57600080fd5b506103f4610b4e3660046133f8565b60009182526007602052604090912055565b348015610b6c57600080fd5b506103f4610b7b3660046134aa565b612695565b348015610b8c57600080fd5b506103f4610b9b366004613620565b61271b565b348015610bac57600080fd5b506103f4610bbb3660046137ed565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610c0657600080fd5b506103f4610c153660046134aa565b6127b5565b348015610c2657600080fd5b506103f4610c3536600461380a565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610c8557600080fd5b506104ee610c943660046133f8565b61284d565b348015610ca557600080fd5b506103f4610cb4366004613620565b6128b6565b348015610cc557600080fd5b5061044c610cd43660046133f8565b612981565b348015610ce557600080fd5b5061044c610cf43660046134aa565b60096020526000908152604090205481565b348015610d1257600080fd5b5061044c60145481565b348015610d2857600080fd5b506103f4610d37366004613592565b6129b2565b348015610d4857600080fd5b5061044c610d573660046134aa565b60066020526000908152604090205481565b348015610d7557600080fd5b5061044c610d843660046134aa565b60026020526000908152604090205481565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610e7c908c1688613856565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610efa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1e919061389a565b5060008860ff1667ffffffffffffffff811115610f3d57610f3d6131fe565b604051908082528060200260200182016040528015610f66578160200160208202803683370190505b50905060005b8960ff168160ff16101561110f576000610f85846129c6565b90508860ff166001036110bd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015610fea573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526110309190810190613902565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906110899085908590600401613937565b600060405180830381600087803b1580156110a357600080fd5b505af11580156110b7573d6000803e3d6000fd5b50505050505b80838360ff16815181106110d3576110d3613950565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111078161397f565b915050610f6c565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161113f919061341a565b60405180910390a1505050505050505050565b60606000611160600f612a94565b905080841061119b576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036111b0576111ad848261399e565b92505b60008367ffffffffffffffff8111156111cb576111cb6131fe565b6040519080825280602002602001820160405280156111f4578160200160208202803683370190505b50905060005b848110156112465761121761120f82886139b1565b600f90612a9e565b82828151811061122957611229613950565b60209081029190910101528061123e816139c4565b9150506111fa565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061127957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf0860001b81526020018460405160200161130091815260200190565b604051602081830303815290604052611318906139fc565b81526020016000801b81526020016000801b8152509050806040516020016113989190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561141357602002820191906000526020600020905b8154815260200190600101908083116113ff575b50505050509050611425818251612aaa565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa1580156114c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114ec9190613a4c565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa15801561158f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115b39190613a7a565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261165d9383018282801561165157602002820191906000526020600020905b81548152602001906001019080831161163d575b50505050508484612b2f565b90505b9392505050565b8060005b818160ff1610156116fb573063c8048022858560ff851681811061169157611691613950565b905060200201356040518263ffffffff1660e01b81526004016116b691815260200190565b600060405180830381600087803b1580156116d057600080fd5b505af11580156116e4573d6000803e3d6000fd5b5050505080806116f39061397f565b91505061166b565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff1611611762576000858152600d6020908152604080832061ffff8516845290915290205461174e90836139b1565b91508061175a81613a97565b915050611717565b509392505050565b60005a9050600061177d83850185613ab8565b50600081815260056020908152604080832054600490925282205492935091906117a5612c8e565b9050826000036117c5576000848152600560205260409020819055611920565b6000848152600360205260408120546117de848461399e565b6117e8919061399e565b6000868152600e6020908152604080832054600d835281842061ffff90911680855290835281842080548351818602810186019094528084529596509094919290919083018282801561185a57602002820191906000526020600020905b815481526020019060010190808311611846575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff168151036118d5578161189781613a97565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b60008481526006602052604081205461193a9060016139b1565b60008681526006602090815260408083208490556004909152902083905590506119648583612191565b61196f858784612581565b5050505050505050565b6000828152600d6020908152604080832061ffff851684528252918290208054835181840281018401909452808452606093928301828280156119db57602002820191906000526020600020905b8154815260200190600101908083116119c7575b5050505050905092915050565b8160005b81811015611a855730635f17e616868684818110611a0c57611a0c613950565b90506020020135856040518363ffffffff1660e01b8152600401611a4092919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611a5a57600080fd5b505af1158015611a6e573d6000803e3d6000fd5b505050508080611a7d906139c4565b9150506119ec565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611b03573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611b499190810190613aff565b80519091506000611b58612c8e565b905060005b828110156116fb576000848281518110611b7957611b79613950565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611bf9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c1d9190613ba5565b90508060ff16600103611c6257604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611c6f906139c4565b915050611b5d565b611c7f612d30565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611cee573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d129190613bc2565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611d8a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dae919061389a565b5050565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611dea916131ab565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611e46576000848152600d6020908152604080832061ffff851684529091528120611e34916131ab565b80611e3e81613a97565b915050611dff565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a90506000611e96858701876134aa565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115611ecf57611ecf6131fe565b6040519080825280601f01601f191660200182016040528015611ef9576020820181803683370190505b50604051602001611f0b929190613937565b60405160208183030381529060405290506000611f26612c8e565b90506000611f3386611fac565b90505b835a611f42908961399e565b611f4e906127106139b1565b1015611f9c5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905581611f9481613bdb565b925050611f36565b9a91995090975050505050505050565b6000818152600560205260408120548103611fc957506001919050565b600082815260036020908152604080832054600490925290912054611fec612c8e565b611ff6919061399e565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612084576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b59061215a90869086908690600401613c10565b600060405180830381600087803b15801561217457600080fd5b505af1158015612188573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546121ad908361399e565b1115611dae576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612223573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526122699190810190613c92565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156122de573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123029190613db1565b6015549091506123269082906c01000000000000000000000000900460ff16613856565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156116fb576015546123699085906bffffffffffffffffffffffff166123d6565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af115801561245e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612482919061389a565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561250357600080fd5b505af1158015612517573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561257557602002820191906000526020600020905b815481526020019060010190808311612561575b50505050509050919050565b6000838152600760205260409020545b805a61259d908561399e565b6125a9906127106139b1565b10156116fb5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612591565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561266257600080fd5b505af1158015612676573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b15801561270757600080fd5b505af1158015611a85573d6000803e3d6000fd5b8060005b818163ffffffff1610156116fb573063af953a4a858563ffffffff851681811061274b5761274b613950565b905060200201356040518263ffffffff1660e01b815260040161277091815260200190565b600060405180830381600087803b15801561278a57600080fd5b505af115801561279e573d6000803e3d6000fd5b5050505080806127ad90613dce565b91505061271f565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561282157600080fd5b505af1158015612835573d6000803e3d6000fd5b50505050611dae81600f612db390919063ffffffff16565b6000828152600c602090815260408083208054825181850281018501909352808352849384939291908301828280156128a557602002820191906000526020600020905b815481526020019060010190808311612891575b505050505090506114258185612aaa565b8060005b818110156116fb5760008484838181106128d6576128d6613950565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc828360405160200161290f91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b815260040161293b929190613937565b600060405180830381600087803b15801561295557600080fd5b505af1158015612969573d6000803e3d6000fd5b50505050508080612979906139c4565b9150506128ba565b600c602052816000526040600020818154811061299d57600080fd5b90600052602060002001600091509150505481565b6129ba612d30565b6129c381612dbf565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612a21908690600401613de7565b6020604051808303816000875af1158015612a40573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a649190613bc2565b9050612a71600f82612eb4565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061124b825490565b60006116608383612ec0565b815160009081908190841580612ac05750808510155b15612ac9578094505b60008092505b85831015612b2557866001612ae4858561399e565b612aee919061399e565b81518110612afe57612afe613950565b602002602001015181612b1191906139b1565b905082612b1d816139c4565b935050612acf565b9694955050505050565b82516000908190831580612b435750808410155b15612b4c578093505b60008467ffffffffffffffff811115612b6757612b676131fe565b604051908082528060200260200182016040528015612b90578160200160208202803683370190505b509050600092505b84831015612bfe57866001612bad858561399e565b612bb7919061399e565b81518110612bc757612bc7613950565b6020026020010151818481518110612be157612be1613950565b602090810291909101015282612bf6816139c4565b935050612b98565b612c1781600060018451612c12919061399e565b612eea565b85606403612c50578060018251612c2e919061399e565b81518110612c3e57612c3e613950565b60200260200101519350505050611660565b806064825188612c609190613f39565b612c6a9190613fa5565b81518110612c7a57612c7a613950565b602002602001015193505050509392505050565b60007f000000000000000000000000000000000000000000000000000000000000000015612d2b57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612d02573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d269190613bc2565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314612db1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161207b565b565b60006116608383613062565b3373ffffffffffffffffffffffffffffffffffffffff821603612e3e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161207b565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000611660838361315c565b6000826000018281548110612ed757612ed7613950565b9060005260206000200154905092915050565b8181808203612efa575050505050565b6000856002612f098787613fb9565b612f139190613fd9565b612f1d9087614041565b81518110612f2d57612f2d613950565b602002602001015190505b81831361303c575b80868481518110612f5357612f53613950565b60200260200101511015612f735782612f6b81614069565b935050612f40565b858281518110612f8557612f85613950565b6020026020010151811015612fa65781612f9e8161409a565b925050612f73565b81831361303757858281518110612fbf57612fbf613950565b6020026020010151868481518110612fd957612fd9613950565b6020026020010151878581518110612ff357612ff3613950565b6020026020010188858151811061300c5761300c613950565b6020908102919091010191909152528261302581614069565b93505081806130339061409a565b9250505b612f38565b8185121561304f5761304f868684612eea565b8383121561251757612517868486612eea565b6000818152600183016020526040812054801561314b57600061308660018361399e565b855490915060009061309a9060019061399e565b90508181146130ff5760008660000182815481106130ba576130ba613950565b90600052602060002001549050808760000184815481106130dd576130dd613950565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613110576131106140cb565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061124b565b600091505061124b565b5092915050565b60008181526001830160205260408120546131a35750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561124b565b50600061124b565b50805460008255906000526020600020908101906129c391905b808211156131d957600081556001016131c5565b5090565b60ff811681146129c357600080fd5b63ffffffff811681146129c357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715613251576132516131fe565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561329e5761329e6131fe565b604052919050565b600067ffffffffffffffff8211156132c0576132c06131fe565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f8301126132fd57600080fd5b813561331061330b826132a6565b613257565b81815284602083860101111561332557600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129c357600080fd5b600080600080600080600060e0888a03121561337757600080fd5b8735613382816131dd565b96506020880135613392816131ec565b955060408801356133a2816131dd565b9450606088013567ffffffffffffffff8111156133be57600080fd5b6133ca8a828b016132ec565b94505060808801356133db81613342565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561340b57600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561345257835183529284019291840191600101613436565b50909695505050505050565b803561ffff8116811461347057600080fd5b919050565b60008060006060848603121561348a57600080fd5b8335925061349a6020850161345e565b9150604084013590509250925092565b6000602082840312156134bc57600080fd5b5035919050565b60005b838110156134de5781810151838201526020016134c6565b50506000910152565b600081518084526134ff8160208601602086016134c3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061166060208301846134e7565b6000806040838503121561355757600080fd5b823591506135676020840161345e565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff811681146129c357600080fd5b6000602082840312156135a457600080fd5b813561166081613570565b6000806000606084860312156135c457600080fd5b505081359360208301359350604090920135919050565b60008083601f8401126135ed57600080fd5b50813567ffffffffffffffff81111561360557600080fd5b6020830191508360208260051b850101111561142b57600080fd5b6000806020838503121561363357600080fd5b823567ffffffffffffffff81111561364a57600080fd5b613656858286016135db565b90969095509350505050565b60008083601f84011261367457600080fd5b50813567ffffffffffffffff81111561368c57600080fd5b60208301915083602082850101111561142b57600080fd5b600080602083850312156136b757600080fd5b823567ffffffffffffffff8111156136ce57600080fd5b61365685828601613662565b6000806000604084860312156136ef57600080fd5b833567ffffffffffffffff81111561370657600080fd5b613712868287016135db565b9094509250506020840135613726816131ec565b809150509250925092565b821515815260406020820152600061165d60408301846134e7565b60008060006040848603121561376157600080fd5b83359250602084013567ffffffffffffffff81111561377f57600080fd5b61378b86828701613662565b9497909650939450505050565b600080604083850312156137ab57600080fd5b8235915060208301356137bd81613342565b809150509250929050565b600080604083850312156137db57600080fd5b8235915060208301356137bd816131ec565b6000602082840312156137ff57600080fd5b813561166081613342565b60006020828403121561381c57600080fd5b8135611660816131dd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff8083168185168183048111821515161561388157613881613827565b02949350505050565b8051801515811461347057600080fd5b6000602082840312156138ac57600080fd5b6116608261388a565b600082601f8301126138c657600080fd5b81516138d461330b826132a6565b8181528460208386010111156138e957600080fd5b6138fa8260208301602087016134c3565b949350505050565b60006020828403121561391457600080fd5b815167ffffffffffffffff81111561392b57600080fd5b6138fa848285016138b5565b82815260406020820152600061165d60408301846134e7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361399557613995613827565b60010192915050565b8181038181111561124b5761124b613827565b8082018082111561124b5761124b613827565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f5576139f5613827565b5060010190565b80516020808301519190811015613a3b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161347081613570565b60008060408385031215613a5f57600080fd5b8251613a6a81613570565b6020939093015192949293505050565b600060208284031215613a8c57600080fd5b815161166081613570565b600061ffff808316818103613aae57613aae613827565b6001019392505050565b60008060408385031215613acb57600080fd5b82359150602083013567ffffffffffffffff811115613ae957600080fd5b613af5858286016132ec565b9150509250929050565b60006020808385031215613b1257600080fd5b825167ffffffffffffffff80821115613b2a57600080fd5b818501915085601f830112613b3e57600080fd5b815181811115613b5057613b506131fe565b8060051b9150613b61848301613257565b8181529183018401918481019088841115613b7b57600080fd5b938501935b83851015613b9957845182529385019390850190613b80565b98975050505050505050565b600060208284031215613bb757600080fd5b8151611660816131dd565b600060208284031215613bd457600080fd5b5051919050565b600081613bea57613bea613827565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b8051613470816131ec565b805161347081613342565b805167ffffffffffffffff8116811461347057600080fd5b600060208284031215613ca457600080fd5b815167ffffffffffffffff80821115613cbc57600080fd5b908301906101408286031215613cd157600080fd5b613cd961322d565b613ce283613a41565b8152613cf060208401613c64565b6020820152604083015182811115613d0757600080fd5b613d13878286016138b5565b604083015250613d2560608401613c6f565b6060820152613d3660808401613a41565b6080820152613d4760a08401613c7a565b60a0820152613d5860c08401613c64565b60c0820152613d6960e08401613c6f565b60e0820152610100613d7c81850161388a565b908201526101208381015183811115613d9457600080fd5b613da0888287016138b5565b918301919091525095945050505050565b600060208284031215613dc357600080fd5b815161166081613342565b600063ffffffff808316818103613aae57613aae613827565b6020815260008251610140806020850152613e066101608501836134e7565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe080868503016040870152613e4284836134e7565b935060408701519150613e6d606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e0870152613ece84836134e7565b935060e08701519150610100818786030181880152613eed85846134e7565b945080880151925050610120818786030181880152613f0c85846134e7565b94508088015192505050613f2f828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613f7157613f71613827565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082613fb457613fb4613f76565b500490565b818103600083128015838313168383128216171561315557613155613827565b600082613fe857613fe8613f76565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561403c5761403c613827565b500590565b808201828112600083128015821682158216171561406157614061613827565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f5576139f5613827565b60007f80000000000000000000000000000000000000000000000000000000000000008203613bea57613bea613827565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x60e06040527f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0523480156200005e57600080fd5b50604051620044f4380380620044f4833981016040819052620000819162000310565b81813380600081620000da5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156200010d576200010d816200024c565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa1580156200016a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000190919062000353565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620001f6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200021c919062000384565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a05250620003ab915050565b336001600160a01b03821603620002a65760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000d1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200030d57600080fd5b50565b600080604083850312156200032457600080fd5b82516200033181620002f7565b602084015190925080151581146200034857600080fd5b809150509250929050565b600080604083850312156200036757600080fd5b82516200037481620002f7565b6020939093015192949293505050565b6000602082840312156200039757600080fd5b8151620003a481620002f7565b9392505050565b60805160a05160c051614104620003f06000396000818161049901526118600152600081816107870152612c8f015260008181610ab101526112c601526141046000f3fe6080604052600436106103905760003560e01c8063776898c8116101dc578063a72aa27e11610102578063d6051a72116100a0578063e45530831161006f578063e455308314610d06578063f2fde38b14610d1c578063fba7ffa314610d3c578063fcdc1f6314610d6957600080fd5b8063d6051a7214610c79578063daee1aeb14610c99578063dbef701e14610cb9578063e0114adb14610cd957600080fd5b8063becde0e1116100dc578063becde0e114610b80578063c357f1f314610ba0578063c804802214610bfa578063d355852814610c1a57600080fd5b8063a72aa27e14610b13578063a79c404314610b33578063af953a4a14610b6057600080fd5b8063948108f71161017a5780639d385eaa116101495780639d385eaa14610a7f578063a654824814610a9f578063a6b5947514610ad3578063a6c60d8914610af357600080fd5b8063948108f7146109c55780639ac542eb146109e55780639b42935414610a215780639b51fb0d14610a4e57600080fd5b80637e7a46dc116101b65780637e7a46dc1461092d5780638da5cb5b1461094d5780638fcb3fba14610978578063924ca578146109a557600080fd5b8063776898c8146108cb57806379ba5097146108eb5780637b1039991461090057600080fd5b806346e7a63e116102c1578063636092e81161025f5780636e04ff0d1161022e5780636e04ff0d146108135780637145f11b1461084157806373644cce14610871578063767213031461089e57600080fd5b8063636092e814610733578063642f6cef1461077557806369cdbadb146107b957806369e9b773146107e657600080fd5b8063597109921161029b57806359710992146106bc5780635d4ee7f3146106d15780635f17e616146106e657806360457ff51461070657600080fd5b806346e7a63e1461064257806351c98be31461066f57806357970e931461068f57600080fd5b806328c4b57b1161032e578063328ffd1111610308578063328ffd11146105b55780633ebe8d6c146105e25780634585e33b1461060257806345d2ec171461062257600080fd5b806328c4b57b146105235780632a9032d3146105435780632b20e3971461056357600080fd5b80630d4a4fb11161036a5780630d4a4fb11461045a57806312c5502714610487578063206c32e8146104ce57806320e3dbd41461050357600080fd5b806306c1cc00146103d457806306e3b632146103f6578063077ac6211461042c57600080fd5b366103cf57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b3480156103e057600080fd5b506103f46103ef366004613359565b610d96565b005b34801561040257600080fd5b506104166104113660046133f5565b611152565b6040516104239190613417565b60405180910390f35b34801561043857600080fd5b5061044c610447366004613472565b611251565b604051908152602001610423565b34801561046657600080fd5b5061047a6104753660046134a7565b61128f565b604051610423919061352e565b34801561049357600080fd5b506104bb7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610423565b3480156104da57600080fd5b506104ee6104e9366004613541565b6113ac565b60408051928352602083019190915201610423565b34801561050f57600080fd5b506103f461051e36600461358f565b61142f565b34801561052f57600080fd5b5061044c61053e3660046135ac565b6115f9565b34801561054f57600080fd5b506103f461055e36600461361d565b611664565b34801561056f57600080fd5b506011546105909073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610423565b3480156105c157600080fd5b5061044c6105d03660046134a7565b60036020526000908152604090205481565b3480156105ee57600080fd5b5061044c6105fd3660046134a7565b6116fe565b34801561060e57600080fd5b506103f461061d3660046136a1565b611767565b34801561062e57600080fd5b5061041661063d366004613541565b611976565b34801561064e57600080fd5b5061044c61065d3660046134a7565b600a6020526000908152604090205481565b34801561067b57600080fd5b506103f461068a3660046136d7565b6119e5565b34801561069b57600080fd5b506012546105909073ffffffffffffffffffffffffffffffffffffffff1681565b3480156106c857600080fd5b506103f4611a89565b3480156106dd57600080fd5b506103f4611c74565b3480156106f257600080fd5b506103f46107013660046133f5565b611daf565b34801561071257600080fd5b5061044c6107213660046134a7565b60076020526000908152604090205481565b34801561073f57600080fd5b50601554610758906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610423565b34801561078157600080fd5b506107a97f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610423565b3480156107c557600080fd5b5061044c6107d43660046134a7565b60086020526000908152604090205481565b3480156107f257600080fd5b506103f46108013660046133f5565b60009182526008602052604090912055565b34801561081f57600080fd5b5061083361082e3660046136a1565b611e7c565b60405161042392919061372e565b34801561084d57600080fd5b506107a961085c3660046134a7565b600b6020526000908152604090205460ff1681565b34801561087d57600080fd5b5061044c61088c3660046134a7565b6000908152600c602052604090205490565b3480156108aa57600080fd5b5061044c6108b93660046134a7565b60046020526000908152604090205481565b3480156108d757600080fd5b506107a96108e63660046134a7565b611fa9565b3480156108f757600080fd5b506103f4611ffb565b34801561090c57600080fd5b506013546105909073ffffffffffffffffffffffffffffffffffffffff1681565b34801561093957600080fd5b506103f4610948366004613749565b6120fd565b34801561095957600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610590565b34801561098457600080fd5b5061044c6109933660046134a7565b60056020526000908152604090205481565b3480156109b157600080fd5b506103f46109c03660046133f5565b61218e565b3480156109d157600080fd5b506103f46109e0366004613795565b6123d3565b3480156109f157600080fd5b50601554610a0f906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610423565b348015610a2d57600080fd5b506103f4610a3c3660046133f5565b60009182526009602052604090912055565b348015610a5a57600080fd5b506104bb610a693660046134a7565b600e6020526000908152604090205461ffff1681565b348015610a8b57600080fd5b50610416610a9a3660046134a7565b61251c565b348015610aab57600080fd5b5061044c7f000000000000000000000000000000000000000000000000000000000000000081565b348015610adf57600080fd5b506103f4610aee3660046135ac565b61257e565b348015610aff57600080fd5b506103f4610b0e3660046134a7565b601455565b348015610b1f57600080fd5b506103f4610b2e3660046137c5565b6125e7565b348015610b3f57600080fd5b506103f4610b4e3660046133f5565b60009182526007602052604090912055565b348015610b6c57600080fd5b506103f4610b7b3660046134a7565b612692565b348015610b8c57600080fd5b506103f4610b9b36600461361d565b612718565b348015610bac57600080fd5b506103f4610bbb3660046137ea565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610c0657600080fd5b506103f4610c153660046134a7565b6127b2565b348015610c2657600080fd5b506103f4610c35366004613807565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610c8557600080fd5b506104ee610c943660046133f5565b61284a565b348015610ca557600080fd5b506103f4610cb436600461361d565b6128b3565b348015610cc557600080fd5b5061044c610cd43660046133f5565b61297e565b348015610ce557600080fd5b5061044c610cf43660046134a7565b60096020526000908152604090205481565b348015610d1257600080fd5b5061044c60145481565b348015610d2857600080fd5b506103f4610d3736600461358f565b6129af565b348015610d4857600080fd5b5061044c610d573660046134a7565b60066020526000908152604090205481565b348015610d7557600080fd5b5061044c610d843660046134a7565b60026020526000908152604090205481565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610e7c908c1688613853565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610efa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1e9190613897565b5060008860ff1667ffffffffffffffff811115610f3d57610f3d6131fb565b604051908082528060200260200182016040528015610f66578160200160208202803683370190505b50905060005b8960ff168160ff16101561110f576000610f85846129c3565b90508860ff166001036110bd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015610fea573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261103091908101906138ff565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906110899085908590600401613934565b600060405180830381600087803b1580156110a357600080fd5b505af11580156110b7573d6000803e3d6000fd5b50505050505b80838360ff16815181106110d3576110d361394d565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111078161397c565b915050610f6c565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161113f9190613417565b60405180910390a1505050505050505050565b60606000611160600f612a91565b905080841061119b576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036111b0576111ad848261399b565b92505b60008367ffffffffffffffff8111156111cb576111cb6131fb565b6040519080825280602002602001820160405280156111f4578160200160208202803683370190505b50905060005b848110156112465761121761120f82886139ae565b600f90612a9b565b8282815181106112295761122961394d565b60209081029190910101528061123e816139c1565b9150506111fa565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061127957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f00000000000000000000000000000000000000000000000000000000000000008152602001846040516020016112fd91815260200190565b604051602081830303815290604052611315906139f9565b81526020016000801b81526020016000801b8152509050806040516020016113959190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561141057602002820191906000526020600020905b8154815260200190600101908083116113fc575b50505050509050611422818251612aa7565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa1580156114c5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114e99190613a49565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa15801561158c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115b09190613a77565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261165a9383018282801561164e57602002820191906000526020600020905b81548152602001906001019080831161163a575b50505050508484612b2c565b90505b9392505050565b8060005b818160ff1610156116f8573063c8048022858560ff851681811061168e5761168e61394d565b905060200201356040518263ffffffff1660e01b81526004016116b391815260200190565b600060405180830381600087803b1580156116cd57600080fd5b505af11580156116e1573d6000803e3d6000fd5b5050505080806116f09061397c565b915050611668565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff161161175f576000858152600d6020908152604080832061ffff8516845290915290205461174b90836139ae565b91508061175781613a94565b915050611714565b509392505050565b60005a9050600061177a83850185613ab5565b50600081815260056020908152604080832054600490925282205492935091906117a2612c8b565b9050826000036117c257600084815260056020526040902081905561191d565b6000848152600360205260408120546117db848461399b565b6117e5919061399b565b6000868152600e6020908152604080832054600d835281842061ffff90911680855290835281842080548351818602810186019094528084529596509094919290919083018282801561185757602002820191906000526020600020905b815481526020019060010190808311611843575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff168151036118d2578161189481613a94565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b6000848152600660205260408120546119379060016139ae565b6000868152600660209081526040808320849055600490915290208390559050611961858361218e565b61196c85878461257e565b5050505050505050565b6000828152600d6020908152604080832061ffff851684528252918290208054835181840281018401909452808452606093928301828280156119d857602002820191906000526020600020905b8154815260200190600101908083116119c4575b5050505050905092915050565b8160005b81811015611a825730635f17e616868684818110611a0957611a0961394d565b90506020020135856040518363ffffffff1660e01b8152600401611a3d92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611a5757600080fd5b505af1158015611a6b573d6000803e3d6000fd5b505050508080611a7a906139c1565b9150506119e9565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611b00573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611b469190810190613afc565b80519091506000611b55612c8b565b905060005b828110156116f8576000848281518110611b7657611b7661394d565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c1a9190613ba2565b90508060ff16600103611c5f57604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611c6c906139c1565b915050611b5a565b611c7c612d2d565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611ceb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d0f9190613bbf565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611d87573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dab9190613897565b5050565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611de7916131a8565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611e43576000848152600d6020908152604080832061ffff851684529091528120611e31916131a8565b80611e3b81613a94565b915050611dfc565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a90506000611e93858701876134a7565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115611ecc57611ecc6131fb565b6040519080825280601f01601f191660200182016040528015611ef6576020820181803683370190505b50604051602001611f08929190613934565b60405160208183030381529060405290506000611f23612c8b565b90506000611f3086611fa9565b90505b835a611f3f908961399b565b611f4b906127106139ae565b1015611f995781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905581611f9181613bd8565b925050611f33565b9a91995090975050505050505050565b6000818152600560205260408120548103611fc657506001919050565b600082815260036020908152604080832054600490925290912054611fe9612c8b565b611ff3919061399b565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612081576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b59061215790869086908690600401613c0d565b600060405180830381600087803b15801561217157600080fd5b505af1158015612185573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546121aa908361399b565b1115611dab576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612220573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526122669190810190613c8f565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156122db573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122ff9190613dae565b6015549091506123239082906c01000000000000000000000000900460ff16613853565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156116f8576015546123669085906bffffffffffffffffffffffff166123d3565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af115801561245b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061247f9190613897565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561250057600080fd5b505af1158015612514573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561257257602002820191906000526020600020905b81548152602001906001019080831161255e575b50505050509050919050565b6000838152600760205260409020545b805a61259a908561399b565b6125a6906127106139ae565b10156116f85781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905561258e565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561265f57600080fd5b505af1158015612673573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b15801561270457600080fd5b505af1158015611a82573d6000803e3d6000fd5b8060005b818163ffffffff1610156116f8573063af953a4a858563ffffffff85168181106127485761274861394d565b905060200201356040518263ffffffff1660e01b815260040161276d91815260200190565b600060405180830381600087803b15801561278757600080fd5b505af115801561279b573d6000803e3d6000fd5b5050505080806127aa90613dcb565b91505061271c565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561281e57600080fd5b505af1158015612832573d6000803e3d6000fd5b50505050611dab81600f612db090919063ffffffff16565b6000828152600c602090815260408083208054825181850281018501909352808352849384939291908301828280156128a257602002820191906000526020600020905b81548152602001906001019080831161288e575b505050505090506114228185612aa7565b8060005b818110156116f85760008484838181106128d3576128d361394d565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc828360405160200161290c91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612938929190613934565b600060405180830381600087803b15801561295257600080fd5b505af1158015612966573d6000803e3d6000fd5b50505050508080612976906139c1565b9150506128b7565b600c602052816000526040600020818154811061299a57600080fd5b90600052602060002001600091509150505481565b6129b7612d2d565b6129c081612dbc565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612a1e908690600401613de4565b6020604051808303816000875af1158015612a3d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a619190613bbf565b9050612a6e600f82612eb1565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061124b825490565b600061165d8383612ebd565b815160009081908190841580612abd5750808510155b15612ac6578094505b60008092505b85831015612b2257866001612ae1858561399b565b612aeb919061399b565b81518110612afb57612afb61394d565b602002602001015181612b0e91906139ae565b905082612b1a816139c1565b935050612acc565b9694955050505050565b82516000908190831580612b405750808410155b15612b49578093505b60008467ffffffffffffffff811115612b6457612b646131fb565b604051908082528060200260200182016040528015612b8d578160200160208202803683370190505b509050600092505b84831015612bfb57866001612baa858561399b565b612bb4919061399b565b81518110612bc457612bc461394d565b6020026020010151818481518110612bde57612bde61394d565b602090810291909101015282612bf3816139c1565b935050612b95565b612c1481600060018451612c0f919061399b565b612ee7565b85606403612c4d578060018251612c2b919061399b565b81518110612c3b57612c3b61394d565b6020026020010151935050505061165d565b806064825188612c5d9190613f36565b612c679190613fa2565b81518110612c7757612c7761394d565b602002602001015193505050509392505050565b60007f000000000000000000000000000000000000000000000000000000000000000015612d2857606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612cff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d239190613bbf565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314612dae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612078565b565b600061165d838361305f565b3373ffffffffffffffffffffffffffffffffffffffff821603612e3b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612078565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600061165d8383613159565b6000826000018281548110612ed457612ed461394d565b9060005260206000200154905092915050565b8181808203612ef7575050505050565b6000856002612f068787613fb6565b612f109190613fd6565b612f1a908761403e565b81518110612f2a57612f2a61394d565b602002602001015190505b818313613039575b80868481518110612f5057612f5061394d565b60200260200101511015612f705782612f6881614066565b935050612f3d565b858281518110612f8257612f8261394d565b6020026020010151811015612fa35781612f9b81614097565b925050612f70565b81831361303457858281518110612fbc57612fbc61394d565b6020026020010151868481518110612fd657612fd661394d565b6020026020010151878581518110612ff057612ff061394d565b602002602001018885815181106130095761300961394d565b6020908102919091010191909152528261302281614066565b935050818061303090614097565b9250505b612f35565b8185121561304c5761304c868684612ee7565b8383121561251457612514868486612ee7565b6000818152600183016020526040812054801561314857600061308360018361399b565b85549091506000906130979060019061399b565b90508181146130fc5760008660000182815481106130b7576130b761394d565b90600052602060002001549050808760000184815481106130da576130da61394d565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061310d5761310d6140c8565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061124b565b600091505061124b565b5092915050565b60008181526001830160205260408120546131a05750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561124b565b50600061124b565b50805460008255906000526020600020908101906129c091905b808211156131d657600081556001016131c2565b5090565b60ff811681146129c057600080fd5b63ffffffff811681146129c057600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561324e5761324e6131fb565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561329b5761329b6131fb565b604052919050565b600067ffffffffffffffff8211156132bd576132bd6131fb565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f8301126132fa57600080fd5b813561330d613308826132a3565b613254565b81815284602083860101111561332257600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129c057600080fd5b600080600080600080600060e0888a03121561337457600080fd5b873561337f816131da565b9650602088013561338f816131e9565b9550604088013561339f816131da565b9450606088013567ffffffffffffffff8111156133bb57600080fd5b6133c78a828b016132e9565b94505060808801356133d88161333f565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561340857600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561344f57835183529284019291840191600101613433565b50909695505050505050565b803561ffff8116811461346d57600080fd5b919050565b60008060006060848603121561348757600080fd5b833592506134976020850161345b565b9150604084013590509250925092565b6000602082840312156134b957600080fd5b5035919050565b60005b838110156134db5781810151838201526020016134c3565b50506000910152565b600081518084526134fc8160208601602086016134c0565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061165d60208301846134e4565b6000806040838503121561355457600080fd5b823591506135646020840161345b565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff811681146129c057600080fd5b6000602082840312156135a157600080fd5b813561165d8161356d565b6000806000606084860312156135c157600080fd5b505081359360208301359350604090920135919050565b60008083601f8401126135ea57600080fd5b50813567ffffffffffffffff81111561360257600080fd5b6020830191508360208260051b850101111561142857600080fd5b6000806020838503121561363057600080fd5b823567ffffffffffffffff81111561364757600080fd5b613653858286016135d8565b90969095509350505050565b60008083601f84011261367157600080fd5b50813567ffffffffffffffff81111561368957600080fd5b60208301915083602082850101111561142857600080fd5b600080602083850312156136b457600080fd5b823567ffffffffffffffff8111156136cb57600080fd5b6136538582860161365f565b6000806000604084860312156136ec57600080fd5b833567ffffffffffffffff81111561370357600080fd5b61370f868287016135d8565b9094509250506020840135613723816131e9565b809150509250925092565b821515815260406020820152600061165a60408301846134e4565b60008060006040848603121561375e57600080fd5b83359250602084013567ffffffffffffffff81111561377c57600080fd5b6137888682870161365f565b9497909650939450505050565b600080604083850312156137a857600080fd5b8235915060208301356137ba8161333f565b809150509250929050565b600080604083850312156137d857600080fd5b8235915060208301356137ba816131e9565b6000602082840312156137fc57600080fd5b813561165d8161333f565b60006020828403121561381957600080fd5b813561165d816131da565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff8083168185168183048111821515161561387e5761387e613824565b02949350505050565b8051801515811461346d57600080fd5b6000602082840312156138a957600080fd5b61165d82613887565b600082601f8301126138c357600080fd5b81516138d1613308826132a3565b8181528460208386010111156138e657600080fd5b6138f78260208301602087016134c0565b949350505050565b60006020828403121561391157600080fd5b815167ffffffffffffffff81111561392857600080fd5b6138f7848285016138b2565b82815260406020820152600061165a60408301846134e4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361399257613992613824565b60010192915050565b8181038181111561124b5761124b613824565b8082018082111561124b5761124b613824565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f2576139f2613824565b5060010190565b80516020808301519190811015613a38577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161346d8161356d565b60008060408385031215613a5c57600080fd5b8251613a678161356d565b6020939093015192949293505050565b600060208284031215613a8957600080fd5b815161165d8161356d565b600061ffff808316818103613aab57613aab613824565b6001019392505050565b60008060408385031215613ac857600080fd5b82359150602083013567ffffffffffffffff811115613ae657600080fd5b613af2858286016132e9565b9150509250929050565b60006020808385031215613b0f57600080fd5b825167ffffffffffffffff80821115613b2757600080fd5b818501915085601f830112613b3b57600080fd5b815181811115613b4d57613b4d6131fb565b8060051b9150613b5e848301613254565b8181529183018401918481019088841115613b7857600080fd5b938501935b83851015613b9657845182529385019390850190613b7d565b98975050505050505050565b600060208284031215613bb457600080fd5b815161165d816131da565b600060208284031215613bd157600080fd5b5051919050565b600081613be757613be7613824565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b805161346d816131e9565b805161346d8161333f565b805167ffffffffffffffff8116811461346d57600080fd5b600060208284031215613ca157600080fd5b815167ffffffffffffffff80821115613cb957600080fd5b908301906101408286031215613cce57600080fd5b613cd661322a565b613cdf83613a3e565b8152613ced60208401613c61565b6020820152604083015182811115613d0457600080fd5b613d10878286016138b2565b604083015250613d2260608401613c6c565b6060820152613d3360808401613a3e565b6080820152613d4460a08401613c77565b60a0820152613d5560c08401613c61565b60c0820152613d6660e08401613c6c565b60e0820152610100613d79818501613887565b908201526101208381015183811115613d9157600080fd5b613d9d888287016138b2565b918301919091525095945050505050565b600060208284031215613dc057600080fd5b815161165d8161333f565b600063ffffffff808316818103613aab57613aab613824565b6020815260008251610140806020850152613e036101608501836134e4565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe080868503016040870152613e3f84836134e4565b935060408701519150613e6a606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e0870152613ecb84836134e4565b935060e08701519150610100818786030181880152613eea85846134e4565b945080880151925050610120818786030181880152613f0985846134e4565b94508088015192505050613f2c828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613f6e57613f6e613824565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082613fb157613fb1613f73565b500490565b818103600083128015838313168383128216171561315257613152613824565b600082613fe557613fe5613f73565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561403957614039613824565b500590565b808201828112600083128015821682158216171561405e5761405e613824565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f2576139f2613824565b60007f80000000000000000000000000000000000000000000000000000000000000008203613be757613be7613824565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000810000a", } var VerifiableLoadUpkeepABI = VerifiableLoadUpkeepMetaData.ABI var VerifiableLoadUpkeepBin = VerifiableLoadUpkeepMetaData.Bin -func DeployVerifiableLoadUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, registrarAddress common.Address, useArb bool) (common.Address, *types.Transaction, *VerifiableLoadUpkeep, error) { +func DeployVerifiableLoadUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, useArb bool) (common.Address, *types.Transaction, *VerifiableLoadUpkeep, error) { parsed, err := VerifiableLoadUpkeepMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -48,7 +48,7 @@ func DeployVerifiableLoadUpkeep(auth *bind.TransactOpts, backend bind.ContractBa return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadUpkeepBin), backend, registrarAddress, useArb) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadUpkeepBin), backend, _registrar, useArb) if err != nil { return common.Address{}, nil, nil, err } diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index fdf455f7518..535fd369b4d 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -65,9 +65,9 @@ type_and_version_interface_wrapper: ../../contracts/solc/v0.8.6/TypeAndVersionIn upkeep_counter_wrapper: ../../contracts/solc/v0.7/UpkeepCounter.abi ../../contracts/solc/v0.7/UpkeepCounter.bin 901961ebf18906febc1c350f02da85c7ea1c2a68da70cfd94efa27c837a48663 upkeep_perform_counter_restrictive_wrapper: ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.abi ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.bin 8975a058fba528e16d8414dc6f13946d17a145fcbc66cf25a32449b6fe1ce878 upkeep_transcoder: ../../contracts/solc/v0.8.6/UpkeepTranscoder.abi ../../contracts/solc/v0.8.6/UpkeepTranscoder.bin 336c92a981597be26508455f81a908a0784a817b129a59686c5b2c4afcba730a -verifiable_load_log_trigger_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin 7e03338febcd40b1b90eca22be9a3715662b33b40ce18a5d4d50ad29eda6f5e2 -verifiable_load_mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin 47babc359db1b1f2d1d9401eef3f3b86349fd7053b43ccf31ed3872c20979878 -verifiable_load_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin 42f190693bb49f1e76e0e396e0560c3e9152b7a01c6a9e62ed35d99b03f97a1e +verifiable_load_log_trigger_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin 42c14e414215ab00f587ce594947c0181e68e3f406ff9dfc5bc9f656394a7909 +verifiable_load_mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin 7a0b6c3ade3a0f3915252397cf68de9c31dc7cd3256b3c6cd1519f9caca008e3 +verifiable_load_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin 34ed896a4ed549642bba79bd38ea87b47bb1647b14ca607fe10538b302deeb3e vrf_consumer_v2: ../../contracts/solc/v0.8.6/VRFConsumerV2.abi ../../contracts/solc/v0.8.6/VRFConsumerV2.bin 9ef258bf8e9f8d880fd229ceb145593d91e24fc89366baa0bf19169c5787d15f vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.bin 3155c611e4d6882e9324b6e975033b31356776ea8b031ca63d63da37589d583b vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e From 7b05f0be1c94abe755e736373f930ccdbf086814 Mon Sep 17 00:00:00 2001 From: Mateusz Sekara Date: Fri, 28 Jul 2023 20:39:22 +0200 Subject: [PATCH 026/270] Postgres fails to compute proper execution plans when confirmationNumber is added to the left side of the filter condition (#9968) --- core/chains/evm/logpoller/orm.go | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/core/chains/evm/logpoller/orm.go b/core/chains/evm/logpoller/orm.go index ce8ce9edb95..73084f1dfe7 100644 --- a/core/chains/evm/logpoller/orm.go +++ b/core/chains/evm/logpoller/orm.go @@ -308,7 +308,7 @@ func (o *ORM) SelectLatestLogEventSigsAddrsWithConfs(fromBlock int64, addresses event_sig = ANY($2) AND address = ANY($3) AND block_number > $4 AND - (block_number + $5) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $5 GROUP BY event_sig, address ) ORDER BY block_number ASC @@ -331,7 +331,7 @@ func (o *ORM) SelectLatestBlockNumberEventSigsAddrsWithConfs(eventSigs []common. WHERE evm_chain_id = $1 AND event_sig = ANY($2) AND address = ANY($3) AND - (block_number + $4) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1)`, + block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $4`, o.chainID.Int64(), sigs, addrs, confs) if err != nil { return 0, err @@ -348,7 +348,7 @@ func (o *ORM) SelectDataWordRange(address common.Address, eventSig common.Hash, AND address = $2 AND event_sig = $3 AND substring(data from 32*$4+1 for 32) >= $5 AND substring(data from 32*$4+1 for 32) <= $6 - AND (block_number + $7) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $7 ORDER BY (evm_logs.block_number, evm_logs.log_index)`, utils.NewBig(o.chainID), address, eventSig.Bytes(), wordIndex, wordValueMin.Bytes(), wordValueMax.Bytes(), confs) if err != nil { return nil, err @@ -364,7 +364,7 @@ func (o *ORM) SelectDataWordGreaterThan(address common.Address, eventSig common. WHERE evm_logs.evm_chain_id = $1 AND address = $2 AND event_sig = $3 AND substring(data from 32*$4+1 for 32) >= $5 - AND (block_number + $6) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $6 ORDER BY (evm_logs.block_number, evm_logs.log_index)`, utils.NewBig(o.chainID), address, eventSig.Bytes(), wordIndex, wordValueMin.Bytes(), confs) if err != nil { return nil, err @@ -384,7 +384,7 @@ func (o *ORM) SelectIndexLogsTopicGreaterThan(address common.Address, eventSig c WHERE evm_logs.evm_chain_id = $1 AND address = $2 AND event_sig = $3 AND topics[$4] >= $5 - AND (block_number + $6) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $6 ORDER BY (evm_logs.block_number, evm_logs.log_index)`, utils.NewBig(o.chainID), address, eventSig.Bytes(), topicIndex+1, topicValueMin.Bytes(), confs) if err != nil { return nil, err @@ -405,7 +405,7 @@ func (o *ORM) SelectIndexLogsTopicRange(address common.Address, eventSig common. AND address = $2 AND event_sig = $3 AND topics[$4] >= $5 AND topics[$4] <= $6 - AND (block_number + $7) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $7 ORDER BY (evm_logs.block_number, evm_logs.log_index)`, utils.NewBig(o.chainID), address, eventSig.Bytes(), topicIndex+1, topicValueMin.Bytes(), topicValueMax.Bytes(), confs) if err != nil { return nil, err @@ -427,7 +427,7 @@ func (o *ORM) SelectIndexedLogs(address common.Address, eventSig common.Hash, to WHERE evm_logs.evm_chain_id = $1 AND address = $2 AND event_sig = $3 AND topics[$4] = ANY($5) - AND (block_number + $6) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $6 ORDER BY (evm_logs.block_number, evm_logs.log_index)`, utils.NewBig(o.chainID), address, eventSig.Bytes(), topicIndex+1, topicValuesBytes, confs) if err != nil { return nil, err @@ -475,7 +475,7 @@ func (o *ORM) SelectIndexedLogsCreatedAfter(address common.Address, eventSig com AND address = $2 AND event_sig = $3 AND topics[$4] = ANY($5) AND created_at > $6 - AND (block_number + $7) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $7 ORDER BY created_at ASC`, utils.NewBig(o.chainID), address, eventSig.Bytes(), topicIndex+1, topicValuesBytes, after, confs) if err != nil { return nil, err @@ -499,7 +499,7 @@ func (o *ORM) SelectIndexedLogsWithSigsExcluding(sigA, sigB common.Hash, topicIn AND address = $2 AND event_sig = $3 AND block_number BETWEEN $6 AND $7 - AND (block_number + $8) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $8 EXCEPT @@ -512,7 +512,7 @@ func (o *ORM) SelectIndexedLogsWithSigsExcluding(sigA, sigB common.Hash, topicIn AND a.event_sig = $3 AND b.event_sig = $4 AND b.block_number BETWEEN $6 AND $7 - AND (b.block_number + $8) <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) + AND b.block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $8 ORDER BY block_number,log_index ASC `, utils.NewBig(o.chainID), address, sigA.Bytes(), sigB.Bytes(), topicIndex+1, startBlock, endBlock, confs) From 6973ac29bcf348c95929b9bb82084ade94dce6af Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Fri, 28 Jul 2023 14:46:25 -0400 Subject: [PATCH 027/270] update VL contracts (#9976) * update VL contracts * update --- .../src/v0.8/tests/VerifiableLoadBase.sol | 5 + .../tests/VerifiableLoadLogTriggerUpkeep.sol | 40 +++++++- .../tests/VerifiableLoadMercuryUpkeep.sol | 2 +- .../src/v0.8/tests/VerifiableLoadUpkeep.sol | 2 +- ...ifiable_load_log_trigger_upkeep_wrapper.go | 98 ++++++++++++++++++- .../verifiable_load_mercury_upkeep_wrapper.go | 22 ++++- .../verifiable_load_upkeep_wrapper.go | 22 ++++- ...rapper-dependency-versions-do-not-edit.txt | 6 +- 8 files changed, 176 insertions(+), 21 deletions(-) diff --git a/contracts/src/v0.8/tests/VerifiableLoadBase.sol b/contracts/src/v0.8/tests/VerifiableLoadBase.sol index 8bb8a76df4a..4bb7907ed58 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadBase.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadBase.sol @@ -347,6 +347,11 @@ abstract contract VerifiableLoadBase is ConfirmedOwner { } } + function sendLog(uint256 upkeepId) external { + uint256 blockNum = getBlockNumber(); + emit LogEmitted(upkeepId, blockNum, address(this)); + } + function getDelaysLength(uint256 upkeepId) public view returns (uint256) { return delays[upkeepId].length; } diff --git a/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol index 2b95b26e069..a1842449110 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadLogTriggerUpkeep.sol @@ -12,8 +12,32 @@ contract VerifiableLoadLogTriggerUpkeep is VerifiableLoadBase, FeedLookupCompati ]; string public feedParamKey = "feedIdHex"; string public timeParamKey = "blockNumber"; + bool public autoLog; + bool public useMercury; - constructor(AutomationRegistrar2_1 _registrar, bool _useArb) VerifiableLoadBase(_registrar, _useArb) {} + /** + * @param _registrar a automation registrar 2.1 address + * @param _useArb if this contract will use arbitrum block number + * @param _autoLog if the upkeep will emit logs to trigger its next log trigger process + * @param _useMercury if the log trigger upkeeps will use mercury lookup + */ + constructor( + AutomationRegistrar2_1 _registrar, + bool _useArb, + bool _autoLog, + bool _useMercury + ) VerifiableLoadBase(_registrar, _useArb) { + autoLog = _autoLog; + useMercury = _useMercury; + } + + function setAutoLog(bool _autoLog) external { + autoLog = _autoLog; + } + + function setUseMercury(bool _useMercury) external { + useMercury = _useMercury; + } function setFeedsHex(string[] memory newFeeds) external { feedsHex = newFeeds; @@ -33,10 +57,16 @@ contract VerifiableLoadLogTriggerUpkeep is VerifiableLoadBase, FeedLookupCompati uint256 checkGasToBurn = checkGasToBurns[upkeepId]; while (startGas - gasleft() + 15000 < checkGasToBurn) { dummyMap[blockhash(blockNum)] = false; - blockNum--; } - revert FeedLookup(feedParamKey, feedsHex, timeParamKey, blockNum, abi.encode(upkeepId, blockNum)); + if (useMercury) { + revert FeedLookup(feedParamKey, feedsHex, timeParamKey, blockNum, abi.encode(upkeepId, blockNum)); + } + + // if we don't use mercury, create a perform data which resembles the output of checkCallback + bytes[] memory values = new bytes[](1); + bytes memory extraData = abi.encode(upkeepId, blockNum); + return (true, abi.encode(values, extraData)); } revert("could not find matching event sig"); } @@ -72,7 +102,9 @@ contract VerifiableLoadLogTriggerUpkeep is VerifiableLoadBase, FeedLookupCompati // minBalanceThresholdMultiplier (20) * min balance. If not, add addLinkAmount (0.2) to the upkeep // upkeepTopUpCheckInterval, minBalanceThresholdMultiplier, and addLinkAmount are configurable topUpFund(upkeepId, currentBlockNum); - emit LogEmitted(upkeepId, currentBlockNum, address(this)); + if (autoLog) { + emit LogEmitted(upkeepId, currentBlockNum, address(this)); + } burnPerformGas(upkeepId, startGas, currentBlockNum); } diff --git a/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol index d772daccf28..09e62f988a5 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadMercuryUpkeep.sol @@ -13,7 +13,7 @@ contract VerifiableLoadMercuryUpkeep is VerifiableLoadBase, FeedLookupCompatible string public constant feedParamKey = "feedIdHex"; string public constant timeParamKey = "blockNumber"; - constructor(AutomationRegistrar2_1 _registrar, bool useArb) VerifiableLoadBase(_registrar, useArb) {} + constructor(AutomationRegistrar2_1 _registrar, bool _useArb) VerifiableLoadBase(_registrar, _useArb) {} function setFeedsHex(string[] memory newFeeds) external { feedsHex = newFeeds; diff --git a/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol b/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol index cc4b914b3d9..bab75e9613c 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadUpkeep.sol @@ -4,7 +4,7 @@ pragma solidity 0.8.16; import "./VerifiableLoadBase.sol"; contract VerifiableLoadUpkeep is VerifiableLoadBase { - constructor(AutomationRegistrar2_1 _registrar, bool useArb) VerifiableLoadBase(_registrar, useArb) {} + constructor(AutomationRegistrar2_1 _registrar, bool _useArb) VerifiableLoadBase(_registrar, _useArb) {} function checkUpkeep(bytes calldata checkData) external returns (bool, bytes memory) { uint256 startGas = gasleft(); diff --git a/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go index 327d33a4d48..4840897e022 100644 --- a/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_log_trigger_upkeep_wrapper/verifiable_load_log_trigger_upkeep_wrapper.go @@ -42,15 +42,15 @@ type Log struct { } var VerifiableLoadLogTriggerUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0526101a0604052604261012081815260e091829190620052386101403981526020016040518060800160405280604281526020016200527a60429139905262000099906016906002620003a2565b506040805180820190915260098152680cccacac892c890caf60bb1b6020820152601790620000c990826200051e565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152601890620000fb90826200051e565b503480156200010957600080fd5b50604051620052bc380380620052bc8339810160408190526200012c9162000600565b81813380600081620001855760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620001b857620001b881620002f7565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa15801562000215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200023b919062000643565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620002a1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002c7919062000674565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a052506200069b915050565b336001600160a01b03821603620003515760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200017c565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003ed579160200282015b82811115620003ed5782518290620003dc90826200051e565b5091602001919060010190620003c3565b50620003fb929150620003ff565b5090565b80821115620003fb57600062000416828262000420565b50600101620003ff565b5080546200042e906200048f565b6000825580601f106200043f575050565b601f0160209004906000526020600020908101906200045f919062000462565b50565b5b80821115620003fb576000815560010162000463565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620004a457607f821691505b602082108103620004c557634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200051957600081815260208120601f850160051c81016020861015620004f45750805b601f850160051c820191505b81811015620005155782815560010162000500565b5050505b505050565b81516001600160401b038111156200053a576200053a62000479565b62000552816200054b84546200048f565b84620004cb565b602080601f8311600181146200058a5760008415620005715750858301515b600019600386901b1c1916600185901b17855562000515565b600085815260208120601f198616915b82811015620005bb578886015182559484019460019091019084016200059a565b5085821015620005da5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b03811681146200045f57600080fd5b600080604083850312156200061457600080fd5b82516200062181620005ea565b602084015190925080151581146200063857600080fd5b809150509250929050565b600080604083850312156200065757600080fd5b82516200066481620005ea565b6020939093015192949293505050565b6000602082840312156200068757600080fd5b81516200069481620005ea565b9392505050565b60805160a05160c051614b51620006e7600039600081816104f00152611bf101526000818161082c015261303e015260008181610b480152818161139e01526118560152614b516000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610dc7578063f2fde38b14610ddd578063fba7ffa314610dfd578063fcdc1f6314610e2a57600080fd5b8063d6051a7214610d3a578063daee1aeb14610d5a578063dbef701e14610d7a578063e0114adb14610d9a57600080fd5b8063c357f1f3116100dc578063c357f1f314610c4c578063c804802214610ca6578063c98f10b014610cc6578063d355852814610cdb57600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c2c57600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b806346e7a63e116102e2578063636092e8116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063636092e8146107d8578063642f6cef1461081a57806369cdbadb1461085e57806369e9b7731461088b57600080fd5b806359710992116102b157806359710992146107615780635d4ee7f3146107765780635f17e6161461078b57806360457ff5146107ab57600080fd5b806346e7a63e146106c75780634b56a42e146106f457806351c98be31461071457806357970e931461073457600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c1461063957806340691db4146106595780634585e33b1461068757806345d2ec17146106a757600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b610426366004613787565b610e57565b005b34801561043957600080fd5b5061042b6104483660046138a8565b610e6e565b34801561045957600080fd5b5061046d610468366004613944565b61122a565b60405161047a9190613966565b60405180910390f35b34801561048f57600080fd5b506104a361049e3660046139c1565b611329565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc3660046139f6565b611367565b60405161047a9190613a7d565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a90565b611484565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613ade565b611507565b34801561058657600080fd5b506104a3610595366004613afb565b6116d1565b3480156105a657600080fd5b5061042b6105b5366004613b6c565b61173c565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a36106273660046139f6565b60036020526000908152604090205481565b34801561064557600080fd5b506104a36106543660046139f6565b6117d6565b34801561066557600080fd5b50610679610674366004613bae565b61183f565b60405161047a929190613c1b565b34801561069357600080fd5b5061042b6106a2366004613c78565b611af0565b3480156106b357600080fd5b5061046d6106c2366004613a90565b611d41565b3480156106d357600080fd5b506104a36106e23660046139f6565b600a6020526000908152604090205481565b34801561070057600080fd5b5061067961070f366004613cae565b611db0565b34801561072057600080fd5b5061042b61072f366004613d6b565b611e04565b34801561074057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561076d57600080fd5b5061042b611ea8565b34801561078257600080fd5b5061042b612093565b34801561079757600080fd5b5061042b6107a6366004613944565b6121ca565b3480156107b757600080fd5b506104a36107c63660046139f6565b60076020526000908152604090205481565b3480156107e457600080fd5b506015546107fd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561082657600080fd5b5061084e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561086a57600080fd5b506104a36108793660046139f6565b60086020526000908152604090205481565b34801561089757600080fd5b5061042b6108a6366004613944565b60009182526008602052604090912055565b3480156108c457600080fd5b5061084e6108d33660046139f6565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a36109033660046139f6565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a36109303660046139f6565b60046020526000908152604090205481565b34801561094e57600080fd5b5061084e61095d3660046139f6565b612297565b34801561096e57600080fd5b5061042b6122e9565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613dc2565b6123e6565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a3660046139f6565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a37366004613944565b612477565b348015610a4857600080fd5b5061042b610a57366004613e0e565b6126bc565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab3366004613944565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae03660046139f6565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b113660046139f6565b612805565b348015610b2257600080fd5b506104d1610b313660046139f6565b612867565b348015610b4257600080fd5b506104a37f000000000000000000000000000000000000000000000000000000000000000081565b348015610b7657600080fd5b5061042b610b85366004613afb565b612913565b348015610b9657600080fd5b5061042b610ba53660046139f6565b601455565b348015610bb657600080fd5b5061042b610bc5366004613e3e565b61297c565b348015610bd657600080fd5b5061042b610be5366004613944565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c123660046139f6565b612a27565b348015610c2357600080fd5b506104d1612aad565b348015610c3857600080fd5b5061042b610c47366004613b6c565b612aba565b348015610c5857600080fd5b5061042b610c67366004613e63565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610cb257600080fd5b5061042b610cc13660046139f6565b612b54565b348015610cd257600080fd5b506104d1612bec565b348015610ce757600080fd5b5061042b610cf6366004613e80565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610d4657600080fd5b50610545610d55366004613944565b612bf9565b348015610d6657600080fd5b5061042b610d75366004613b6c565b612c62565b348015610d8657600080fd5b506104a3610d95366004613944565b612d2d565b348015610da657600080fd5b506104a3610db53660046139f6565b60096020526000908152604090205481565b348015610dd357600080fd5b506104a360145481565b348015610de957600080fd5b5061042b610df8366004613ade565b612d5e565b348015610e0957600080fd5b506104a3610e183660046139f6565b60066020526000908152604090205481565b348015610e3657600080fd5b506104a3610e453660046139f6565b60026020526000908152604090205481565b8051610e6a906016906020840190613557565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610f54908c1688613ecc565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610fd2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ff69190613f10565b5060008860ff1667ffffffffffffffff81111561101557611015613637565b60405190808252806020026020018201604052801561103e578160200160208202803683370190505b50905060005b8960ff168160ff1610156111e757600061105d84612d72565b90508860ff16600103611195576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa1580156110c2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111089190810190613f78565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111619085908590600401613fad565b600060405180830381600087803b15801561117b57600080fd5b505af115801561118f573d6000803e3d6000fd5b50505050505b80838360ff16815181106111ab576111ab613fc6565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111df81613ff5565b915050611044565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516112179190613966565b60405180910390a1505050505050505050565b60606000611238600f612e40565b9050808410611273576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82600003611288576112858482614014565b92505b60008367ffffffffffffffff8111156112a3576112a3613637565b6040519080825280602002602001820160405280156112cc578160200160208202803683370190505b50905060005b8481101561131e576112ef6112e78288614027565b600f90612e4a565b82828151811061130157611301613fc6565b6020908102919091010152806113168161403a565b9150506112d2565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061135157600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f00000000000000000000000000000000000000000000000000000000000000008152602001846040516020016113d591815260200190565b6040516020818303038152906040526113ed90614072565b81526020016000801b81526020016000801b81525090508060405160200161146d9190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156114e857602002820191906000526020600020905b8154815260200190600101908083116114d4575b505050505090506114fa818251612e56565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa15801561159d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115c191906140c2565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015611664573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061168891906140f0565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c6020908152604080832080548251818502810185019093528083526117329383018282801561172657602002820191906000526020600020905b815481526020019060010190808311611712575b50505050508484612edb565b90505b9392505050565b8060005b818160ff1610156117d0573063c8048022858560ff851681811061176657611766613fc6565b905060200201356040518263ffffffff1660e01b815260040161178b91815260200190565b600060405180830381600087803b1580156117a557600080fd5b505af11580156117b9573d6000803e3d6000fd5b5050505080806117c890613ff5565b915050611740565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff1611611837576000858152600d6020908152604080832061ffff851684529091529020546118239083614027565b91508061182f8161410d565b9150506117ec565b509392505050565b6000606060005a9050600061185261303a565b90507f000000000000000000000000000000000000000000000000000000000000000061188260c088018861412e565b600081811061189357611893613fc6565b9050602002013503611a685760006118ae60c088018861412e565b60018181106118bf576118bf613fc6565b905060200201356040516020016118d891815260200190565b60405160208183030381529060405290506000818060200190518101906118ff9190614196565b9050600061191060c08a018a61412e565b600281811061192157611921613fc6565b9050602002013560405160200161193a91815260200190565b60405160208183030381529060405290506000818060200190518101906119619190614196565b6000848152600860205260409020549091505b805a6119809089614014565b61198c90613a98614027565b10156119da5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055816119d2816141af565b925050611974565b6017601660188487866040516020016119fd929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252611a5f95949392916004016142cc565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f67000000000000000000000000000000000000000000000000000000000000006064820152608401611a5f565b60005a9050600080611b0484860186613cae565b9150915060008082806020019051810190611b1f919061438f565b6000828152600560209081526040808320546004909252822054939550919350909190611b4a61303a565b905082600003611b6a576000858152600560205260409020819055611cae565b6000611b768583614014565b6000878152600e6020908152604080832054600d835281842061ffff909116808552908352818420805483518186028101860190945280845295965090949192909190830182828015611be857602002820191906000526020600020905b815481526020019060010190808311611bd4575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611c635781611c258161410d565b60008a8152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055898352600c8252928220805493840181558252902001555b600085815260066020526040812054611cc8906001614027565b6000878152600660209081526040808320849055600490915290208390559050611cf28683612477565b604051308152829087907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a3611d34868a84612913565b5050505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611da357602002820191906000526020600020905b815481526020019060010190808311611d8f575b5050505050905092915050565b6000606060008484604051602001611dc99291906143b3565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611ea15730635f17e616868684818110611e2857611e28613fc6565b90506020020135856040518363ffffffff1660e01b8152600401611e5c92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611e7657600080fd5b505af1158015611e8a573d6000803e3d6000fd5b505050508080611e999061403a565b915050611e08565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611f1f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611f659190810190614447565b80519091506000611f7461303a565b905060005b828110156117d0576000848281518110611f9557611f95613fc6565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015612015573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061203991906144d8565b90508060ff1660010361207e57604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b5050808061208b9061403a565b915050611f79565b61209b6130dc565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561210a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061212e9190614196565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af11580156121a6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e6a9190613f10565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120612202916135ad565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff161161225e576000848152600d6020908152604080832061ffff85168452909152812061224c916135ad565b806122568161410d565b915050612217565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b60008181526005602052604081205481036122b457506001919050565b6000828152600360209081526040808320546004909252909120546122d761303a565b6122e19190614014565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461236a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401611a5f565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b590612440908690869086906004016144f5565b600060405180830381600087803b15801561245a57600080fd5b505af115801561246e573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124939083614014565b1115610e6a576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612509573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261254f9190810190614577565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156125c4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906125e89190614696565b60155490915061260c9082906c01000000000000000000000000900460ff16613ecc565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156117d05760155461264f9085906bffffffffffffffffffffffff166126bc565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af1158015612744573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127689190613f10565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b1580156127e957600080fd5b505af11580156127fd573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561285b57602002820191906000526020600020905b815481526020019060010190808311612847575b50505050509050919050565b6016818154811061287757600080fd5b906000526020600020016000915090508054612892906141e4565b80601f01602080910402602001604051908101604052809291908181526020018280546128be906141e4565b801561290b5780601f106128e05761010080835404028352916020019161290b565b820191906000526020600020905b8154815290600101906020018083116128ee57829003601f168201915b505050505081565b6000838152600760205260409020545b805a61292f9085614014565b61293b90612710614027565b10156117d05781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612923565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b1580156129f457600080fd5b505af1158015612a08573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a9957600080fd5b505af1158015611ea1573d6000803e3d6000fd5b60178054612892906141e4565b8060005b818163ffffffff1610156117d0573063af953a4a858563ffffffff8516818110612aea57612aea613fc6565b905060200201356040518263ffffffff1660e01b8152600401612b0f91815260200190565b600060405180830381600087803b158015612b2957600080fd5b505af1158015612b3d573d6000803e3d6000fd5b505050508080612b4c906146b3565b915050612abe565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612bc057600080fd5b505af1158015612bd4573d6000803e3d6000fd5b50505050610e6a81600f61315f90919063ffffffff16565b60188054612892906141e4565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612c5157602002820191906000526020600020905b815481526020019060010190808311612c3d575b505050505090506114fa8185612e56565b8060005b818110156117d0576000848483818110612c8257612c82613fc6565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612cbb91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612ce7929190613fad565b600060405180830381600087803b158015612d0157600080fd5b505af1158015612d15573d6000803e3d6000fd5b50505050508080612d259061403a565b915050612c66565b600c6020528160005260406000208181548110612d4957600080fd5b90600052602060002001600091509150505481565b612d666130dc565b612d6f8161316b565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612dcd9086906004016146cc565b6020604051808303816000875af1158015612dec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e109190614196565b9050612e1d600f82613260565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b6000611323825490565b6000611735838361326c565b815160009081908190841580612e6c5750808510155b15612e75578094505b60008092505b85831015612ed157866001612e908585614014565b612e9a9190614014565b81518110612eaa57612eaa613fc6565b602002602001015181612ebd9190614027565b905082612ec98161403a565b935050612e7b565b9694955050505050565b82516000908190831580612eef5750808410155b15612ef8578093505b60008467ffffffffffffffff811115612f1357612f13613637565b604051908082528060200260200182016040528015612f3c578160200160208202803683370190505b509050600092505b84831015612faa57866001612f598585614014565b612f639190614014565b81518110612f7357612f73613fc6565b6020026020010151818481518110612f8d57612f8d613fc6565b602090810291909101015282612fa28161403a565b935050612f44565b612fc381600060018451612fbe9190614014565b613296565b85606403612ffc578060018251612fda9190614014565b81518110612fea57612fea613fc6565b60200260200101519350505050611735565b80606482518861300c919061481e565b613016919061488a565b8151811061302657613026613fc6565b602002602001015193505050509392505050565b60007f0000000000000000000000000000000000000000000000000000000000000000156130d757606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156130ae573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130d29190614196565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331461315d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611a5f565b565b6000611735838361340e565b3373ffffffffffffffffffffffffffffffffffffffff8216036131ea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611a5f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006117358383613508565b600082600001828154811061328357613283613fc6565b9060005260206000200154905092915050565b81818082036132a6575050505050565b60008560026132b5878761489e565b6132bf91906148be565b6132c99087614926565b815181106132d9576132d9613fc6565b602002602001015190505b8183136133e8575b808684815181106132ff576132ff613fc6565b6020026020010151101561331f57826133178161494e565b9350506132ec565b85828151811061333157613331613fc6565b6020026020010151811015613352578161334a8161497f565b92505061331f565b8183136133e35785828151811061336b5761336b613fc6565b602002602001015186848151811061338557613385613fc6565b602002602001015187858151811061339f5761339f613fc6565b602002602001018885815181106133b8576133b8613fc6565b602090810291909101019190915252826133d18161494e565b93505081806133df9061497f565b9250505b6132e4565b818512156133fb576133fb868684613296565b838312156127fd576127fd868486613296565b600081815260018301602052604081205480156134f7576000613432600183614014565b855490915060009061344690600190614014565b90508181146134ab57600086600001828154811061346657613466613fc6565b906000526020600020015490508087600001848154811061348957613489613fc6565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134bc576134bc6149b0565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050611323565b6000915050611323565b5092915050565b600081815260018301602052604081205461354f57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155611323565b506000611323565b82805482825590600052602060002090810192821561359d579160200282015b8281111561359d578251829061358d9082614a2a565b5091602001919060010190613577565b506135a99291506135cb565b5090565b5080546000825590600052602060002090810190612d6f91906135e8565b808211156135a95760006135df82826135fd565b506001016135cb565b5b808211156135a957600081556001016135e9565b508054613609906141e4565b6000825580601f10613619575050565b601f016020900490600052602060002090810190612d6f91906135e8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561368a5761368a613637565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156136d7576136d7613637565b604052919050565b600067ffffffffffffffff8211156136f9576136f9613637565b5060051b60200190565b600067ffffffffffffffff82111561371d5761371d613637565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600061375c61375784613703565b613690565b905082815283838301111561377057600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561379a57600080fd5b823567ffffffffffffffff808211156137b257600080fd5b818501915085601f8301126137c657600080fd5b81356137d4613757826136df565b81815260059190911b830184019084810190888311156137f357600080fd5b8585015b838110156138405780358581111561380f5760008081fd5b8601603f81018b136138215760008081fd5b6138328b8983013560408401613749565b8452509186019186016137f7565b5098975050505050505050565b60ff81168114612d6f57600080fd5b63ffffffff81168114612d6f57600080fd5b600082601f83011261387f57600080fd5b61173583833560208501613749565b6bffffffffffffffffffffffff81168114612d6f57600080fd5b600080600080600080600060e0888a0312156138c357600080fd5b87356138ce8161384d565b965060208801356138de8161385c565b955060408801356138ee8161384d565b9450606088013567ffffffffffffffff81111561390a57600080fd5b6139168a828b0161386e565b94505060808801356139278161388e565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561395757600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561399e57835183529284019291840191600101613982565b50909695505050505050565b803561ffff811681146139bc57600080fd5b919050565b6000806000606084860312156139d657600080fd5b833592506139e6602085016139aa565b9150604084013590509250925092565b600060208284031215613a0857600080fd5b5035919050565b60005b83811015613a2a578181015183820152602001613a12565b50506000910152565b60008151808452613a4b816020860160208601613a0f565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006117356020830184613a33565b60008060408385031215613aa357600080fd5b82359150613ab3602084016139aa565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612d6f57600080fd5b600060208284031215613af057600080fd5b813561173581613abc565b600080600060608486031215613b1057600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613b3957600080fd5b50813567ffffffffffffffff811115613b5157600080fd5b6020830191508360208260051b850101111561150057600080fd5b60008060208385031215613b7f57600080fd5b823567ffffffffffffffff811115613b9657600080fd5b613ba285828601613b27565b90969095509350505050565b60008060408385031215613bc157600080fd5b823567ffffffffffffffff80821115613bd957600080fd5b908401906101008287031215613bee57600080fd5b90925060208401359080821115613c0457600080fd5b50613c118582860161386e565b9150509250929050565b82151581526040602082015260006117326040830184613a33565b60008083601f840112613c4857600080fd5b50813567ffffffffffffffff811115613c6057600080fd5b60208301915083602082850101111561150057600080fd5b60008060208385031215613c8b57600080fd5b823567ffffffffffffffff811115613ca257600080fd5b613ba285828601613c36565b60008060408385031215613cc157600080fd5b823567ffffffffffffffff80821115613cd957600080fd5b818501915085601f830112613ced57600080fd5b81356020613cfd613757836136df565b82815260059290921b84018101918181019089841115613d1c57600080fd5b8286015b84811015613d5457803586811115613d385760008081fd5b613d468c86838b010161386e565b845250918301918301613d20565b5096505086013592505080821115613c0457600080fd5b600080600060408486031215613d8057600080fd5b833567ffffffffffffffff811115613d9757600080fd5b613da386828701613b27565b9094509250506020840135613db78161385c565b809150509250925092565b600080600060408486031215613dd757600080fd5b83359250602084013567ffffffffffffffff811115613df557600080fd5b613e0186828701613c36565b9497909650939450505050565b60008060408385031215613e2157600080fd5b823591506020830135613e338161388e565b809150509250929050565b60008060408385031215613e5157600080fd5b823591506020830135613e338161385c565b600060208284031215613e7557600080fd5b81356117358161388e565b600060208284031215613e9257600080fd5b81356117358161384d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613ef757613ef7613e9d565b02949350505050565b805180151581146139bc57600080fd5b600060208284031215613f2257600080fd5b61173582613f00565b600082601f830112613f3c57600080fd5b8151613f4a61375782613703565b818152846020838601011115613f5f57600080fd5b613f70826020830160208701613a0f565b949350505050565b600060208284031215613f8a57600080fd5b815167ffffffffffffffff811115613fa157600080fd5b613f7084828501613f2b565b8281526040602082015260006117326040830184613a33565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361400b5761400b613e9d565b60010192915050565b8181038181111561132357611323613e9d565b8082018082111561132357611323613e9d565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406b5761406b613e9d565b5060010190565b805160208083015191908110156140b1577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b80516139bc81613abc565b600080604083850312156140d557600080fd5b82516140e081613abc565b6020939093015192949293505050565b60006020828403121561410257600080fd5b815161173581613abc565b600061ffff80831681810361412457614124613e9d565b6001019392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261416357600080fd5b83018035915067ffffffffffffffff82111561417e57600080fd5b6020019150600581901b360382131561150057600080fd5b6000602082840312156141a857600080fd5b5051919050565b6000816141be576141be613e9d565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b600181811c908216806141f857607f821691505b6020821081036140b1577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000815461423e816141e4565b80855260206001838116801561425b5760018114614293576142c1565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b89010195506142c1565b866000528260002060005b858110156142b95781548a820186015290830190840161429e565b890184019650505b505050505092915050565b60a0815260006142df60a0830188614231565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015614351577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261433f8383614231565b94860194925060019182019101614306565b50508681036040880152614365818b614231565b94505050505084606084015282810360808401526143838185613a33565b98975050505050505050565b600080604083850312156143a257600080fd5b505080516020909101519092909150565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015614428577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614416868351613a33565b955093820193908201906001016143dc565b50508584038187015250505061443e8185613a33565b95945050505050565b6000602080838503121561445a57600080fd5b825167ffffffffffffffff81111561447157600080fd5b8301601f8101851361448257600080fd5b8051614490613757826136df565b81815260059190911b820183019083810190878311156144af57600080fd5b928401925b828410156144cd578351825292840192908401906144b4565b979650505050505050565b6000602082840312156144ea57600080fd5b81516117358161384d565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b80516139bc8161385c565b80516139bc8161388e565b805167ffffffffffffffff811681146139bc57600080fd5b60006020828403121561458957600080fd5b815167ffffffffffffffff808211156145a157600080fd5b9083019061014082860312156145b657600080fd5b6145be613666565b6145c7836140b7565b81526145d560208401614549565b60208201526040830151828111156145ec57600080fd5b6145f887828601613f2b565b60408301525061460a60608401614554565b606082015261461b608084016140b7565b608082015261462c60a0840161455f565b60a082015261463d60c08401614549565b60c082015261464e60e08401614554565b60e0820152610100614661818501613f00565b90820152610120838101518381111561467957600080fd5b61468588828701613f2b565b918301919091525095945050505050565b6000602082840312156146a857600080fd5b81516117358161388e565b600063ffffffff80831681810361412457614124613e9d565b60208152600082516101408060208501526146eb610160850183613a33565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0808685030160408701526147278483613a33565b935060408701519150614752606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e08701526147b38483613a33565b935060e087015191506101008187860301818801526147d28584613a33565b9450808801519250506101208187860301818801526147f18584613a33565b94508088015192505050614814828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561485657614856613e9d565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826148995761489961485b565b500490565b818103600083128015838313168383128216171561350157613501613e9d565b6000826148cd576148cd61485b565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561492157614921613e9d565b500590565b808201828112600083128015821682158216171561494657614946613e9d565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361406b5761406b613e9d565b60007f800000000000000000000000000000000000000000000000000000000000000082036141be576141be613e9d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f821115614a2557600081815260208120601f850160051c81016020861015614a065750805b601f850160051c820191505b818110156127fd57828155600101614a12565b505050565b815167ffffffffffffffff811115614a4457614a44613637565b614a5881614a5284546141e4565b846149df565b602080601f831160018114614aab5760008415614a755750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556127fd565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015614af857888601518255948401946001909101908401614ad9565b5085821015614b3457878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"_autoLog\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"_useMercury\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"autoLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"sendLog\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_autoLog\",\"type\":\"bool\"}],\"name\":\"setAutoLog\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useMercury\",\"type\":\"bool\"}],\"name\":\"setUseMercury\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useMercury\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0526101a0604052604261012081815260e091829190620054fe6101403981526020016040518060800160405280604281526020016200554060429139905262000099906016906002620003c4565b506040805180820190915260098152680cccacac892c890caf60bb1b6020820152601790620000c9908262000540565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152601890620000fb908262000540565b503480156200010957600080fd5b5060405162005582380380620055828339810160408190526200012c9162000638565b83833380600081620001855760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620001b857620001b88162000319565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa15801562000215573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200023b919062000697565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620002a1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002c79190620006c8565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a052506019805461ffff191692151561ff001916929092176101009115159190910217905550620006ef9050565b336001600160a01b03821603620003735760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200017c565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b8280548282559060005260206000209081019282156200040f579160200282015b828111156200040f5782518290620003fe908262000540565b5091602001919060010190620003e5565b506200041d92915062000421565b5090565b808211156200041d57600062000438828262000442565b5060010162000421565b5080546200045090620004b1565b6000825580601f1062000461575050565b601f01602090049060005260206000209081019062000481919062000484565b50565b5b808211156200041d576000815560010162000485565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620004c657607f821691505b602082108103620004e757634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200053b57600081815260208120601f850160051c81016020861015620005165750805b601f850160051c820191505b81811015620005375782815560010162000522565b5050505b505050565b81516001600160401b038111156200055c576200055c6200049b565b62000574816200056d8454620004b1565b84620004ed565b602080601f831160018114620005ac5760008415620005935750858301515b600019600386901b1c1916600185901b17855562000537565b600085815260208120601f198616915b82811015620005dd57888601518255948401946001909101908401620005bc565b5085821015620005fc5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6001600160a01b03811681146200048157600080fd5b805180151581146200063357600080fd5b919050565b600080600080608085870312156200064f57600080fd5b84516200065c816200060c565b93506200066c6020860162000622565b92506200067c6040860162000622565b91506200068c6060860162000622565b905092959194509250565b60008060408385031215620006ab57600080fd5b8251620006b8816200060c565b6020939093015192949293505050565b600060208284031215620006db57600080fd5b8151620006e8816200060c565b9392505050565b60805160a05160c051614dc36200073b600039600081816105970152611e3e0152600081816108d301526130b3015260008181610c410152818161151c0152611a1c0152614dc36000f3fe60806040526004361061044e5760003560e01c806379ba509711610243578063af953a4a11610143578063d90c4a68116100bb578063e15e1b341161008a578063f2fde38b1161006f578063f2fde38b14610f5b578063fba7ffa314610f7b578063fcdc1f6314610fa857600080fd5b8063e15e1b3414610ef9578063e455308314610f4557600080fd5b8063d90c4a6814610e72578063daee1aeb14610e8c578063dbef701e14610eac578063e0114adb14610ecc57600080fd5b8063c41c815b11610112578063c98f10b0116100f7578063c98f10b014610dde578063d355852814610df3578063d6051a7214610e5257600080fd5b8063c41c815b14610d9f578063c804802214610dbe57600080fd5b8063af953a4a14610cf0578063afb28d1f14610d10578063becde0e114610d25578063c357f1f314610d4557600080fd5b80639b429354116101d6578063a6548248116101a5578063a6c60d891161018a578063a6c60d8914610c83578063a72aa27e14610ca3578063a79c404314610cc357600080fd5b8063a654824814610c2f578063a6b5947514610c6357600080fd5b80639b42935414610b915780639b51fb0d14610bbe5780639d385eaa14610bef5780639d6f1cc714610c0f57600080fd5b80638fcb3fba116102125780638fcb3fba14610ae8578063924ca57814610b15578063948108f714610b355780639ac542eb14610b5557600080fd5b806379ba509714610a5b5780637b10399914610a705780637e7a46dc14610a9d5780638da5cb5b14610abd57600080fd5b806346e7a63e1161034e578063636092e8116102e15780636b2120c6116102b057806373644cce1161029557806373644cce146109e15780637672130314610a0e578063776898c814610a3b57600080fd5b80636b2120c61461095f5780637145f11b146109b157600080fd5b8063636092e81461087f578063642f6cef146108c157806369cdbadb1461090557806369e9b7731461093257600080fd5b8063597109921161031d57806359710992146108085780635d4ee7f31461081d5780635f17e6161461083257806360457ff51461085257600080fd5b806346e7a63e1461076e5780634b56a42e1461079b57806351c98be3146107bb57806357970e93146107db57600080fd5b806320e3dbd4116103e1578063328ffd11116103b057806340691db41161039557806340691db4146107005780634585e33b1461072e57806345d2ec171461074e57600080fd5b8063328ffd11146106b35780633ebe8d6c146106e057600080fd5b806320e3dbd41461060157806328c4b57b146106215780632a9032d3146106415780632b20e3971461066157600080fd5b80630d4a4fb11161041d5780630d4a4fb1146105385780630e577d421461056557806312c5502714610585578063206c32e8146105cc57600080fd5b806305e251311461049257806306c1cc00146104b457806306e3b632146104d4578063077ac6211461050a57600080fd5b3661048d57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561049e57600080fd5b506104b26104ad3660046139e0565b610fd5565b005b3480156104c057600080fd5b506104b26104cf366004613b01565b610fec565b3480156104e057600080fd5b506104f46104ef366004613b9d565b6113a8565b6040516105019190613bbf565b60405180910390f35b34801561051657600080fd5b5061052a610525366004613c1a565b6114a7565b604051908152602001610501565b34801561054457600080fd5b50610558610553366004613c4f565b6114e5565b6040516105019190613cd6565b34801561057157600080fd5b506104b2610580366004613c4f565b611602565b34801561059157600080fd5b506105b97f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610501565b3480156105d857600080fd5b506105ec6105e7366004613ce9565b61164a565b60408051928352602083019190915201610501565b34801561060d57600080fd5b506104b261061c366004613d37565b6116cd565b34801561062d57600080fd5b5061052a61063c366004613d54565b611897565b34801561064d57600080fd5b506104b261065c366004613dc5565b611902565b34801561066d57600080fd5b5060115461068e9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610501565b3480156106bf57600080fd5b5061052a6106ce366004613c4f565b60036020526000908152604090205481565b3480156106ec57600080fd5b5061052a6106fb366004613c4f565b61199c565b34801561070c57600080fd5b5061072061071b366004613e07565b611a05565b604051610501929190613e74565b34801561073a57600080fd5b506104b2610749366004613ed1565b611d3d565b34801561075a57600080fd5b506104f4610769366004613ce9565b611f9a565b34801561077a57600080fd5b5061052a610789366004613c4f565b600a6020526000908152604090205481565b3480156107a757600080fd5b506107206107b6366004613f07565b612009565b3480156107c757600080fd5b506104b26107d6366004613fc4565b61205d565b3480156107e757600080fd5b5060125461068e9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561081457600080fd5b506104b2612101565b34801561082957600080fd5b506104b26122ec565b34801561083e57600080fd5b506104b261084d366004613b9d565b612423565b34801561085e57600080fd5b5061052a61086d366004613c4f565b60076020526000908152604090205481565b34801561088b57600080fd5b506015546108a4906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610501565b3480156108cd57600080fd5b506108f57f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610501565b34801561091157600080fd5b5061052a610920366004613c4f565b60086020526000908152604090205481565b34801561093e57600080fd5b506104b261094d366004613b9d565b60009182526008602052604090912055565b34801561096b57600080fd5b506104b261097a366004614029565b60198054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b3480156109bd57600080fd5b506108f56109cc366004613c4f565b600b6020526000908152604090205460ff1681565b3480156109ed57600080fd5b5061052a6109fc366004613c4f565b6000908152600c602052604090205490565b348015610a1a57600080fd5b5061052a610a29366004613c4f565b60046020526000908152604090205481565b348015610a4757600080fd5b506108f5610a56366004613c4f565b6124f0565b348015610a6757600080fd5b506104b2612542565b348015610a7c57600080fd5b5060135461068e9073ffffffffffffffffffffffffffffffffffffffff1681565b348015610aa957600080fd5b506104b2610ab8366004614046565b61263f565b348015610ac957600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff1661068e565b348015610af457600080fd5b5061052a610b03366004613c4f565b60056020526000908152604090205481565b348015610b2157600080fd5b506104b2610b30366004613b9d565b6126d0565b348015610b4157600080fd5b506104b2610b50366004614092565b612915565b348015610b6157600080fd5b50601554610b7f906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610501565b348015610b9d57600080fd5b506104b2610bac366004613b9d565b60009182526009602052604090912055565b348015610bca57600080fd5b506105b9610bd9366004613c4f565b600e6020526000908152604090205461ffff1681565b348015610bfb57600080fd5b506104f4610c0a366004613c4f565b612a5e565b348015610c1b57600080fd5b50610558610c2a366004613c4f565b612ac0565b348015610c3b57600080fd5b5061052a7f000000000000000000000000000000000000000000000000000000000000000081565b348015610c6f57600080fd5b506104b2610c7e366004613d54565b612b6c565b348015610c8f57600080fd5b506104b2610c9e366004613c4f565b601455565b348015610caf57600080fd5b506104b2610cbe3660046140c2565b612bd5565b348015610ccf57600080fd5b506104b2610cde366004613b9d565b60009182526007602052604090912055565b348015610cfc57600080fd5b506104b2610d0b366004613c4f565b612c80565b348015610d1c57600080fd5b50610558612d06565b348015610d3157600080fd5b506104b2610d40366004613dc5565b612d13565b348015610d5157600080fd5b506104b2610d603660046140e7565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610dab57600080fd5b506019546108f590610100900460ff1681565b348015610dca57600080fd5b506104b2610dd9366004613c4f565b612dad565b348015610dea57600080fd5b50610558612e45565b348015610dff57600080fd5b506104b2610e0e366004614104565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610e5e57600080fd5b506105ec610e6d366004613b9d565b612e52565b348015610e7e57600080fd5b506019546108f59060ff1681565b348015610e9857600080fd5b506104b2610ea7366004613dc5565b612ebb565b348015610eb857600080fd5b5061052a610ec7366004613b9d565b612f86565b348015610ed857600080fd5b5061052a610ee7366004613c4f565b60096020526000908152604090205481565b348015610f0557600080fd5b506104b2610f14366004614029565b601980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b348015610f5157600080fd5b5061052a60145481565b348015610f6757600080fd5b506104b2610f76366004613d37565b612fb7565b348015610f8757600080fd5b5061052a610f96366004613c4f565b60066020526000908152604090205481565b348015610fb457600080fd5b5061052a610fc3366004613c4f565b60026020526000908152604090205481565b8051610fe89060169060208401906137b0565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b39216906110d2908c1688614150565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015611150573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611174919061418f565b5060008860ff1667ffffffffffffffff81111561119357611193613890565b6040519080825280602002602001820160405280156111bc578160200160208202803683370190505b50905060005b8960ff168160ff1610156113655760006111db84612fcb565b90508860ff16600103611313576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015611240573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261128691908101906141f9565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906112df908590859060040161422e565b600060405180830381600087803b1580156112f957600080fd5b505af115801561130d573d6000803e3d6000fd5b50505050505b80838360ff168151811061132957611329614247565b6020908102919091018101919091526000918252600881526040808320889055600790915290208490558061135d81614276565b9150506111c2565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516113959190613bbf565b60405180910390a1505050505050505050565b606060006113b6600f613099565b90508084106113f1576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82600003611406576114038482614295565b92505b60008367ffffffffffffffff81111561142157611421613890565b60405190808252806020026020018201604052801561144a578160200160208202803683370190505b50905060005b8481101561149c5761146d61146582886142a8565b600f906130a3565b82828151811061147f5761147f614247565b602090810291909101015280611494816142bb565b915050611450565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106114cf57600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f000000000000000000000000000000000000000000000000000000000000000081526020018460405160200161155391815260200190565b60405160208183030381529060405261156b906142f3565b81526020016000801b81526020016000801b8152509050806040516020016115eb9190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b600061160c6130af565b604051308152909150819083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35050565b6000828152600d6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156116ae57602002820191906000526020600020905b81548152602001906001019080831161169a575b505050505090506116c0818251613151565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611763573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117879190614343565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa15801561182a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061184e9190614371565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c6020908152604080832080548251818502810185019093528083526118f8938301828280156118ec57602002820191906000526020600020905b8154815260200190600101908083116118d8575b505050505084846131d6565b90505b9392505050565b8060005b818160ff161015611996573063c8048022858560ff851681811061192c5761192c614247565b905060200201356040518263ffffffff1660e01b815260040161195191815260200190565b600060405180830381600087803b15801561196b57600080fd5b505af115801561197f573d6000803e3d6000fd5b50505050808061198e90614276565b915050611906565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff16116119fd576000858152600d6020908152604080832061ffff851684529091529020546119e990836142a8565b9150806119f58161438e565b9150506119b2565b509392505050565b6000606060005a90506000611a186130af565b90507f0000000000000000000000000000000000000000000000000000000000000000611a4860c08801886143af565b6000818110611a5957611a59614247565b9050602002013503611cb5576000611a7460c08801886143af565b6001818110611a8557611a85614247565b90506020020135604051602001611a9e91815260200190565b6040516020818303038152906040529050600081806020019051810190611ac59190614417565b90506000611ad660c08a018a6143af565b6002818110611ae757611ae7614247565b90506020020135604051602001611b0091815260200190565b6040516020818303038152906040529050600081806020019051810190611b279190614417565b6000848152600860205260409020549091505b805a611b469089614295565b611b5290613a986142a8565b1015611b935781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055611b3a565b601954610100900460ff1615611c3157601760166018848786604051602001611bc6929190918252602082015260400190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252611c289594939291600401614518565b60405180910390fd5b604080516001808252818301909252600091816020015b6060815260200190600190039081611c4857505060408051602081018890528082018690528151808203830181526060820190925291925090600190611c9490849084906080016145db565b6040516020818303038152906040529a509a505050505050505050506116c6565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f67000000000000000000000000000000000000000000000000000000000000006064820152608401611c28565b60005a9050600080611d5184860186613f07565b9150915060008082806020019051810190611d6c919061466f565b6000828152600560209081526040808320546004909252822054939550919350909190611d976130af565b905082600003611db7576000858152600560205260409020819055611efb565b6000611dc38583614295565b6000878152600e6020908152604080832054600d835281842061ffff909116808552908352818420805483518186028101860190945280845295965090949192909190830182828015611e3557602002820191906000526020600020905b815481526020019060010190808311611e21575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611eb05781611e728161438e565b60008a8152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000878152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055898352600c8252928220805493840181558252902001555b600085815260066020526040812054611f159060016142a8565b6000878152600660209081526040808320849055600490915290208390559050611f3f86836126d0565b60195460ff1615611f8257604051308152829087907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b611f8d868a84612b6c565b5050505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611ffc57602002820191906000526020600020905b815481526020019060010190808311611fe8575b5050505050905092915050565b60006060600084846040516020016120229291906145db565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b818110156120fa5730635f17e61686868481811061208157612081614247565b90506020020135856040518363ffffffff1660e01b81526004016120b592919091825263ffffffff16602082015260400190565b600060405180830381600087803b1580156120cf57600080fd5b505af11580156120e3573d6000803e3d6000fd5b5050505080806120f2906142bb565b915050612061565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015612178573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526121be9190810190614693565b805190915060006121cd6130af565b905060005b828110156119965760008482815181106121ee576121ee614247565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa15801561226e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122929190614724565b90508060ff166001036122d757604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b505080806122e4906142bb565b9150506121d2565b6122f4613335565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612363573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123879190614417565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af11580156123ff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610fe8919061418f565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c909152812061245b91613806565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff16116124b7576000848152600d6020908152604080832061ffff8516845290915281206124a591613806565b806124af8161438e565b915050612470565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b600081815260056020526040812054810361250d57506001919050565b6000828152600360209081526040808320546004909252909120546125306130af565b61253a9190614295565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146125c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401611c28565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b59061269990869086908690600401614741565b600060405180830381600087803b1580156126b357600080fd5b505af11580156126c7573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546126ec9083614295565b1115610fe8576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612762573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526127a891908101906147c3565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa15801561281d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061284191906148e2565b6015549091506128659082906c01000000000000000000000000900460ff16614150565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff161015611996576015546128a89085906bffffffffffffffffffffffff16612915565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af115801561299d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129c1919061418f565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b158015612a4257600080fd5b505af1158015612a56573d6000803e3d6000fd5b505050505050565b6000818152600c6020908152604091829020805483518184028101840190945280845260609392830182828015612ab457602002820191906000526020600020905b815481526020019060010190808311612aa0575b50505050509050919050565b60168181548110612ad057600080fd5b906000526020600020016000915090508054612aeb90614430565b80601f0160208091040260200160405190810160405280929190818152602001828054612b1790614430565b8015612b645780601f10612b3957610100808354040283529160200191612b64565b820191906000526020600020905b815481529060010190602001808311612b4757829003601f168201915b505050505081565b6000838152600760205260409020545b805a612b889085614295565b612b94906127106142a8565b10156119965781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612b7c565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b158015612c4d57600080fd5b505af1158015612c61573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612cf257600080fd5b505af11580156120fa573d6000803e3d6000fd5b60178054612aeb90614430565b8060005b818163ffffffff161015611996573063af953a4a858563ffffffff8516818110612d4357612d43614247565b905060200201356040518263ffffffff1660e01b8152600401612d6891815260200190565b600060405180830381600087803b158015612d8257600080fd5b505af1158015612d96573d6000803e3d6000fd5b505050508080612da5906148ff565b915050612d17565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612e1957600080fd5b505af1158015612e2d573d6000803e3d6000fd5b50505050610fe881600f6133b890919063ffffffff16565b60188054612aeb90614430565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612eaa57602002820191906000526020600020905b815481526020019060010190808311612e96575b505050505090506116c08185613151565b8060005b81811015611996576000848483818110612edb57612edb614247565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612f1491815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612f4092919061422e565b600060405180830381600087803b158015612f5a57600080fd5b505af1158015612f6e573d6000803e3d6000fd5b50505050508080612f7e906142bb565b915050612ebf565b600c6020528160005260406000208181548110612fa257600080fd5b90600052602060002001600091509150505481565b612fbf613335565b612fc8816133c4565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190613026908690600401614918565b6020604051808303816000875af1158015613045573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130699190614417565b9050613076600f826134b9565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b60006114a1825490565b60006118fb83836134c5565b60007f00000000000000000000000000000000000000000000000000000000000000001561314c57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613123573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131479190614417565b905090565b504390565b8151600090819081908415806131675750808510155b15613170578094505b60008092505b858310156131cc5786600161318b8585614295565b6131959190614295565b815181106131a5576131a5614247565b6020026020010151816131b891906142a8565b9050826131c4816142bb565b935050613176565b9694955050505050565b825160009081908315806131ea5750808410155b156131f3578093505b60008467ffffffffffffffff81111561320e5761320e613890565b604051908082528060200260200182016040528015613237578160200160208202803683370190505b509050600092505b848310156132a5578660016132548585614295565b61325e9190614295565b8151811061326e5761326e614247565b602002602001015181848151811061328857613288614247565b60209081029190910101528261329d816142bb565b93505061323f565b6132be816000600184516132b99190614295565b6134ef565b856064036132f75780600182516132d59190614295565b815181106132e5576132e5614247565b602002602001015193505050506118fb565b8060648251886133079190614a6a565b6133119190614ad6565b8151811061332157613321614247565b602002602001015193505050509392505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146133b6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611c28565b565b60006118fb8383613667565b3373ffffffffffffffffffffffffffffffffffffffff821603613443576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611c28565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006118fb8383613761565b60008260000182815481106134dc576134dc614247565b9060005260206000200154905092915050565b81818082036134ff575050505050565b600085600261350e8787614aea565b6135189190614b0a565b6135229087614b72565b8151811061353257613532614247565b602002602001015190505b818313613641575b8086848151811061355857613558614247565b60200260200101511015613578578261357081614b9a565b935050613545565b85828151811061358a5761358a614247565b60200260200101518110156135ab57816135a381614bcb565b925050613578565b81831361363c578582815181106135c4576135c4614247565b60200260200101518684815181106135de576135de614247565b60200260200101518785815181106135f8576135f8614247565b6020026020010188858151811061361157613611614247565b6020908102919091010191909152528261362a81614b9a565b935050818061363890614bcb565b9250505b61353d565b81851215613654576136548686846134ef565b83831215612a5657612a568684866134ef565b6000818152600183016020526040812054801561375057600061368b600183614295565b855490915060009061369f90600190614295565b90508181146137045760008660000182815481106136bf576136bf614247565b90600052602060002001549050808760000184815481106136e2576136e2614247565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061371557613715614c22565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506114a1565b60009150506114a1565b5092915050565b60008181526001830160205260408120546137a8575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556114a1565b5060006114a1565b8280548282559060005260206000209081019282156137f6579160200282015b828111156137f657825182906137e69082614c9c565b50916020019190600101906137d0565b50613802929150613824565b5090565b5080546000825590600052602060002090810190612fc89190613841565b808211156138025760006138388282613856565b50600101613824565b5b808211156138025760008155600101613842565b50805461386290614430565b6000825580601f10613872575050565b601f016020900490600052602060002090810190612fc89190613841565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff811182821017156138e3576138e3613890565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561393057613930613890565b604052919050565b600067ffffffffffffffff82111561395257613952613890565b5060051b60200190565b600067ffffffffffffffff82111561397657613976613890565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b60006139b56139b08461395c565b6138e9565b90508281528383830111156139c957600080fd5b828260208301376000602084830101529392505050565b600060208083850312156139f357600080fd5b823567ffffffffffffffff80821115613a0b57600080fd5b818501915085601f830112613a1f57600080fd5b8135613a2d6139b082613938565b81815260059190911b83018401908481019088831115613a4c57600080fd5b8585015b83811015613a9957803585811115613a685760008081fd5b8601603f81018b13613a7a5760008081fd5b613a8b8b89830135604084016139a2565b845250918601918601613a50565b5098975050505050505050565b60ff81168114612fc857600080fd5b63ffffffff81168114612fc857600080fd5b600082601f830112613ad857600080fd5b6118fb838335602085016139a2565b6bffffffffffffffffffffffff81168114612fc857600080fd5b600080600080600080600060e0888a031215613b1c57600080fd5b8735613b2781613aa6565b96506020880135613b3781613ab5565b95506040880135613b4781613aa6565b9450606088013567ffffffffffffffff811115613b6357600080fd5b613b6f8a828b01613ac7565b9450506080880135613b8081613ae7565b9699959850939692959460a0840135945060c09093013592915050565b60008060408385031215613bb057600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613bf757835183529284019291840191600101613bdb565b50909695505050505050565b803561ffff81168114613c1557600080fd5b919050565b600080600060608486031215613c2f57600080fd5b83359250613c3f60208501613c03565b9150604084013590509250925092565b600060208284031215613c6157600080fd5b5035919050565b60005b83811015613c83578181015183820152602001613c6b565b50506000910152565b60008151808452613ca4816020860160208601613c68565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006118fb6020830184613c8c565b60008060408385031215613cfc57600080fd5b82359150613d0c60208401613c03565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612fc857600080fd5b600060208284031215613d4957600080fd5b81356118fb81613d15565b600080600060608486031215613d6957600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613d9257600080fd5b50813567ffffffffffffffff811115613daa57600080fd5b6020830191508360208260051b85010111156116c657600080fd5b60008060208385031215613dd857600080fd5b823567ffffffffffffffff811115613def57600080fd5b613dfb85828601613d80565b90969095509350505050565b60008060408385031215613e1a57600080fd5b823567ffffffffffffffff80821115613e3257600080fd5b908401906101008287031215613e4757600080fd5b90925060208401359080821115613e5d57600080fd5b50613e6a85828601613ac7565b9150509250929050565b82151581526040602082015260006118f86040830184613c8c565b60008083601f840112613ea157600080fd5b50813567ffffffffffffffff811115613eb957600080fd5b6020830191508360208285010111156116c657600080fd5b60008060208385031215613ee457600080fd5b823567ffffffffffffffff811115613efb57600080fd5b613dfb85828601613e8f565b60008060408385031215613f1a57600080fd5b823567ffffffffffffffff80821115613f3257600080fd5b818501915085601f830112613f4657600080fd5b81356020613f566139b083613938565b82815260059290921b84018101918181019089841115613f7557600080fd5b8286015b84811015613fad57803586811115613f915760008081fd5b613f9f8c86838b0101613ac7565b845250918301918301613f79565b5096505086013592505080821115613e5d57600080fd5b600080600060408486031215613fd957600080fd5b833567ffffffffffffffff811115613ff057600080fd5b613ffc86828701613d80565b909450925050602084013561401081613ab5565b809150509250925092565b8015158114612fc857600080fd5b60006020828403121561403b57600080fd5b81356118fb8161401b565b60008060006040848603121561405b57600080fd5b83359250602084013567ffffffffffffffff81111561407957600080fd5b61408586828701613e8f565b9497909650939450505050565b600080604083850312156140a557600080fd5b8235915060208301356140b781613ae7565b809150509250929050565b600080604083850312156140d557600080fd5b8235915060208301356140b781613ab5565b6000602082840312156140f957600080fd5b81356118fb81613ae7565b60006020828403121561411657600080fd5b81356118fb81613aa6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff8083168185168183048111821515161561417b5761417b614121565b02949350505050565b8051613c158161401b565b6000602082840312156141a157600080fd5b81516118fb8161401b565b600082601f8301126141bd57600080fd5b81516141cb6139b08261395c565b8181528460208386010111156141e057600080fd5b6141f1826020830160208701613c68565b949350505050565b60006020828403121561420b57600080fd5b815167ffffffffffffffff81111561422257600080fd5b6141f1848285016141ac565b8281526040602082015260006118f86040830184613c8c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361428c5761428c614121565b60010192915050565b818103818111156114a1576114a1614121565b808201808211156114a1576114a1614121565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036142ec576142ec614121565b5060010190565b80516020808301519190811015614332577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b8051613c1581613d15565b6000806040838503121561435657600080fd5b825161436181613d15565b6020939093015192949293505050565b60006020828403121561438357600080fd5b81516118fb81613d15565b600061ffff8083168181036143a5576143a5614121565b6001019392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126143e457600080fd5b83018035915067ffffffffffffffff8211156143ff57600080fd5b6020019150600581901b36038213156116c657600080fd5b60006020828403121561442957600080fd5b5051919050565b600181811c9082168061444457607f821691505b602082108103614332577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b6000815461448a81614430565b8085526020600183811680156144a757600181146144df5761450d565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b890101955061450d565b866000528260002060005b858110156145055781548a82018601529083019084016144ea565b890184019650505b505050505092915050565b60a08152600061452b60a083018861447d565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b8381101561459d577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261458b838361447d565b94860194925060019182019101614552565b505086810360408801526145b1818b61447d565b94505050505084606084015282810360808401526145cf8185613c8c565b98975050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015614650577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa088870301855261463e868351613c8c565b95509382019390820190600101614604565b5050858403818701525050506146668185613c8c565b95945050505050565b6000806040838503121561468257600080fd5b505080516020909101519092909150565b600060208083850312156146a657600080fd5b825167ffffffffffffffff8111156146bd57600080fd5b8301601f810185136146ce57600080fd5b80516146dc6139b082613938565b81815260059190911b820183019083810190878311156146fb57600080fd5b928401925b8284101561471957835182529284019290840190614700565b979650505050505050565b60006020828403121561473657600080fd5b81516118fb81613aa6565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b8051613c1581613ab5565b8051613c1581613ae7565b805167ffffffffffffffff81168114613c1557600080fd5b6000602082840312156147d557600080fd5b815167ffffffffffffffff808211156147ed57600080fd5b90830190610140828603121561480257600080fd5b61480a6138bf565b61481383614338565b815261482160208401614795565b602082015260408301518281111561483857600080fd5b614844878286016141ac565b604083015250614856606084016147a0565b606082015261486760808401614338565b608082015261487860a084016147ab565b60a082015261488960c08401614795565b60c082015261489a60e084016147a0565b60e08201526101006148ad818501614184565b9082015261012083810151838111156148c557600080fd5b6148d1888287016141ac565b918301919091525095945050505050565b6000602082840312156148f457600080fd5b81516118fb81613ae7565b600063ffffffff8083168181036143a5576143a5614121565b6020815260008251610140806020850152614937610160850183613c8c565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0808685030160408701526149738483613c8c565b93506040870151915061499e606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e08701526149ff8483613c8c565b935060e08701519150610100818786030181880152614a1e8584613c8c565b945080880151925050610120818786030181880152614a3d8584613c8c565b94508088015192505050614a60828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614aa257614aa2614121565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082614ae557614ae5614aa7565b500490565b818103600083128015838313168383128216171561375a5761375a614121565b600082614b1957614b19614aa7565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f800000000000000000000000000000000000000000000000000000000000000083141615614b6d57614b6d614121565b500590565b8082018281126000831280158216821582161715614b9257614b92614121565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036142ec576142ec614121565b60007f80000000000000000000000000000000000000000000000000000000000000008203614bfc57614bfc614121565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f821115614c9757600081815260208120601f850160051c81016020861015614c785750805b601f850160051c820191505b81811015612a5657828155600101614c84565b505050565b815167ffffffffffffffff811115614cb657614cb6613890565b614cca81614cc48454614430565b84614c51565b602080601f831160018114614d1d5760008415614ce75750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555612a56565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015614d6a57888601518255948401946001909101908401614d4b565b5085821015614da657878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var VerifiableLoadLogTriggerUpkeepABI = VerifiableLoadLogTriggerUpkeepMetaData.ABI var VerifiableLoadLogTriggerUpkeepBin = VerifiableLoadLogTriggerUpkeepMetaData.Bin -func DeployVerifiableLoadLogTriggerUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, _useArb bool) (common.Address, *types.Transaction, *VerifiableLoadLogTriggerUpkeep, error) { +func DeployVerifiableLoadLogTriggerUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, _useArb bool, _autoLog bool, _useMercury bool) (common.Address, *types.Transaction, *VerifiableLoadLogTriggerUpkeep, error) { parsed, err := VerifiableLoadLogTriggerUpkeepMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -59,7 +59,7 @@ func DeployVerifiableLoadLogTriggerUpkeep(auth *bind.TransactOpts, backend bind. return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadLogTriggerUpkeepBin), backend, _registrar, _useArb) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadLogTriggerUpkeepBin), backend, _registrar, _useArb, _autoLog, _useMercury) if err != nil { return common.Address{}, nil, nil, err } @@ -226,6 +226,28 @@ func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSessi return _VerifiableLoadLogTriggerUpkeep.Contract.AddLinkAmount(&_VerifiableLoadLogTriggerUpkeep.CallOpts) } +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) AutoLog(opts *bind.CallOpts) (bool, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "autoLog") + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) AutoLog() (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AutoLog(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) AutoLog() (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.AutoLog(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) BucketedDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) { var out []interface{} err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "bucketedDelays", arg0, arg1, arg2) @@ -999,6 +1021,28 @@ func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSessi return _VerifiableLoadLogTriggerUpkeep.Contract.UseArbitrumBlockNum(&_VerifiableLoadLogTriggerUpkeep.CallOpts) } +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCaller) UseMercury(opts *bind.CallOpts) (bool, error) { + var out []interface{} + err := _VerifiableLoadLogTriggerUpkeep.contract.Call(opts, &out, "useMercury") + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) UseMercury() (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UseMercury(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepCallerSession) UseMercury() (bool, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.UseMercury(&_VerifiableLoadLogTriggerUpkeep.CallOpts) +} + func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "acceptOwnership") } @@ -1143,6 +1187,18 @@ func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorS return _VerifiableLoadLogTriggerUpkeep.Contract.PerformUpkeep(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, performData) } +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SendLog(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "sendLog", upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SendLog(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SendLog(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SendLog(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SendLog(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, upkeepId) +} + func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setAddLinkAmount", amount) } @@ -1155,6 +1211,18 @@ func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorS return _VerifiableLoadLogTriggerUpkeep.Contract.SetAddLinkAmount(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, amount) } +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetAutoLog(opts *bind.TransactOpts, _autoLog bool) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setAutoLog", _autoLog) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetAutoLog(_autoLog bool) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetAutoLog(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, _autoLog) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetAutoLog(_autoLog bool) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetAutoLog(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, _autoLog) +} + func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetCheckGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) { return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setCheckGasToBurn", upkeepId, value) } @@ -1263,6 +1331,18 @@ func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorS return _VerifiableLoadLogTriggerUpkeep.Contract.SetUpkeepTopUpCheckInterval(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, newInterval) } +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) SetUseMercury(opts *bind.TransactOpts, _useMercury bool) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "setUseMercury", _useMercury) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepSession) SetUseMercury(_useMercury bool) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetUseMercury(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, _useMercury) +} + +func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactorSession) SetUseMercury(_useMercury bool) (*types.Transaction, error) { + return _VerifiableLoadLogTriggerUpkeep.Contract.SetUseMercury(&_VerifiableLoadLogTriggerUpkeep.TransactOpts, _useMercury) +} + func (_VerifiableLoadLogTriggerUpkeep *VerifiableLoadLogTriggerUpkeepTransactor) TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) { return _VerifiableLoadLogTriggerUpkeep.contract.Transact(opts, "topUpFund", upkeepId, blockNum) } @@ -2151,6 +2231,8 @@ type VerifiableLoadLogTriggerUpkeepInterface interface { AddLinkAmount(opts *bind.CallOpts) (*big.Int, error) + AutoLog(opts *bind.CallOpts) (bool, error) + BucketedDelays(opts *bind.CallOpts, arg0 *big.Int, arg1 uint16, arg2 *big.Int) (*big.Int, error) Buckets(opts *bind.CallOpts, arg0 *big.Int) (uint16, error) @@ -2221,6 +2303,8 @@ type VerifiableLoadLogTriggerUpkeepInterface interface { UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) + UseMercury(opts *bind.CallOpts) (bool, error) + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) AddFunds(opts *bind.TransactOpts, upkeepId *big.Int, amount *big.Int) (*types.Transaction, error) @@ -2245,8 +2329,12 @@ type VerifiableLoadLogTriggerUpkeepInterface interface { PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) + SendLog(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) + SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + SetAutoLog(opts *bind.TransactOpts, _autoLog bool) (*types.Transaction, error) + SetCheckGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) SetConfig(opts *bind.TransactOpts, newRegistrar common.Address) (*types.Transaction, error) @@ -2265,6 +2353,8 @@ type VerifiableLoadLogTriggerUpkeepInterface interface { SetUpkeepTopUpCheckInterval(opts *bind.TransactOpts, newInterval *big.Int) (*types.Transaction, error) + SetUseMercury(opts *bind.TransactOpts, _useMercury bool) (*types.Transaction, error) + TopUpFund(opts *bind.TransactOpts, upkeepId *big.Int, blockNum *big.Int) (*types.Transaction, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go index 325b7f482aa..2d84e4c98b7 100644 --- a/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_mercury_upkeep_wrapper/verifiable_load_mercury_upkeep_wrapper.go @@ -31,15 +31,15 @@ var ( ) var VerifiableLoadMercuryUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0526101c0604052604261014081815260e09182919062005078610160398152602001604051806080016040528060428152602001620050ba604291398152602001604051806080016040528060428152602001620050fc604291399052620000b89060169060036200035f565b50348015620000c657600080fd5b506040516200513e3803806200513e833981016040819052620000e9916200044c565b81813380600081620001425760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000175576200017581620002b4565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001d2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001f891906200048f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200025e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002849190620004c0565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a0525062000658915050565b336001600160a01b038216036200030e5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000139565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003aa579160200282015b82811115620003aa57825182906200039990826200058c565b509160200191906001019062000380565b50620003b8929150620003bc565b5090565b80821115620003b8576000620003d38282620003dd565b50600101620003bc565b508054620003eb90620004fd565b6000825580601f10620003fc575050565b601f0160209004906000526020600020908101906200041c91906200041f565b50565b5b80821115620003b8576000815560010162000420565b6001600160a01b03811681146200041c57600080fd5b600080604083850312156200046057600080fd5b82516200046d8162000436565b602084015190925080151581146200048457600080fd5b809150509250929050565b60008060408385031215620004a357600080fd5b8251620004b08162000436565b6020939093015192949293505050565b600060208284031215620004d357600080fd5b8151620004e08162000436565b9392505050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200051257607f821691505b6020821081036200053357634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200058757600081815260208120601f850160051c81016020861015620005625750805b601f850160051c820191505b8181101562000583578281556001016200056e565b5050505b505050565b81516001600160401b03811115620005a857620005a8620004e7565b620005c081620005b98454620004fd565b8462000539565b602080601f831160018114620005f85760008415620005df5750858301515b600019600386901b1c1916600185901b17855562000583565b600085815260208120601f198616915b82811015620006295788860151825594840194600190910190840162000608565b5085821015620006485787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c0516149db6200069d600039600081816104f001526119ba01526000818161080c0152612fca015260008181610b48015261140601526149db6000f3fe6080604052600436106103c75760003560e01c806379ba5097116101f2578063a79c40431161010d578063d6051a72116100a0578063e45530831161006f578063e455308314610e2f578063f2fde38b14610e45578063fba7ffa314610e65578063fcdc1f6314610e9257600080fd5b8063d6051a7214610da2578063daee1aeb14610dc2578063dbef701e14610de2578063e0114adb14610e0257600080fd5b8063c357f1f3116100dc578063c357f1f314610c80578063c804802214610cda578063c98f10b014610cfa578063d355852814610d4357600080fd5b8063a79c404314610bca578063af953a4a14610bf7578063afb28d1f14610c17578063becde0e114610c6057600080fd5b80639b42935411610185578063a654824811610154578063a654824814610b36578063a6b5947514610b6a578063a6c60d8914610b8a578063a72aa27e14610baa57600080fd5b80639b42935414610a985780639b51fb0d14610ac55780639d385eaa14610af65780639d6f1cc714610b1657600080fd5b80638fcb3fba116101c15780638fcb3fba146109ef578063924ca57814610a1c578063948108f714610a3c5780639ac542eb14610a5c57600080fd5b806379ba5097146109625780637b103999146109775780637e7a46dc146109a45780638da5cb5b146109c457600080fd5b80634b56a42e116102e2578063642f6cef116102755780637145f11b116102445780637145f11b146108b857806373644cce146108e85780637672130314610915578063776898c81461094257600080fd5b8063642f6cef146107fa57806369cdbadb1461083e57806369e9b7731461086b5780636e04ff0d1461089857600080fd5b80635d4ee7f3116102b15780635d4ee7f3146107565780635f17e6161461076b57806360457ff51461078b578063636092e8146107b857600080fd5b80634b56a42e146106c657806351c98be3146106f457806357970e9314610714578063597109921461074157600080fd5b806328c4b57b1161035a5780633ebe8d6c116103295780633ebe8d6c146106395780634585e33b1461065957806345d2ec171461067957806346e7a63e1461069957600080fd5b806328c4b57b1461057a5780632a9032d31461059a5780632b20e397146105ba578063328ffd111461060c57600080fd5b80630d4a4fb1116103965780630d4a4fb1146104b157806312c55027146104de578063206c32e81461052557806320e3dbd41461055a57600080fd5b806305e251311461040b57806306c1cc001461042d57806306e3b6321461044d578063077ac6211461048357600080fd5b3661040657604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561041757600080fd5b5061042b610426366004613713565b610ebf565b005b34801561043957600080fd5b5061042b610448366004613834565b610ed6565b34801561045957600080fd5b5061046d6104683660046138d0565b611292565b60405161047a91906138f2565b60405180910390f35b34801561048f57600080fd5b506104a361049e36600461394d565b611391565b60405190815260200161047a565b3480156104bd57600080fd5b506104d16104cc366004613982565b6113cf565b60405161047a9190613a09565b3480156104ea57600080fd5b506105127f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161047a565b34801561053157600080fd5b50610545610540366004613a1c565b6114ec565b6040805192835260208301919091520161047a565b34801561056657600080fd5b5061042b610575366004613a6a565b61156f565b34801561058657600080fd5b506104a3610595366004613a87565b611739565b3480156105a657600080fd5b5061042b6105b5366004613af8565b6117a4565b3480156105c657600080fd5b506011546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161047a565b34801561061857600080fd5b506104a3610627366004613982565b60036020526000908152604090205481565b34801561064557600080fd5b506104a3610654366004613982565b61183e565b34801561066557600080fd5b5061042b610674366004613b7c565b6118a7565b34801561068557600080fd5b5061046d610694366004613a1c565b611ad2565b3480156106a557600080fd5b506104a36106b4366004613982565b600a6020526000908152604090205481565b3480156106d257600080fd5b506106e66106e1366004613bb2565b611b41565b60405161047a929190613c86565b34801561070057600080fd5b5061042b61070f366004613ca1565b611b95565b34801561072057600080fd5b506012546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b34801561074d57600080fd5b5061042b611c39565b34801561076257600080fd5b5061042b611e24565b34801561077757600080fd5b5061042b6107863660046138d0565b611f5b565b34801561079757600080fd5b506104a36107a6366004613982565b60076020526000908152604090205481565b3480156107c457600080fd5b506015546107dd906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161047a565b34801561080657600080fd5b5061082e7f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161047a565b34801561084a57600080fd5b506104a3610859366004613982565b60086020526000908152604090205481565b34801561087757600080fd5b5061042b6108863660046138d0565b60009182526008602052604090912055565b3480156108a457600080fd5b506106e66108b3366004613b7c565b612028565b3480156108c457600080fd5b5061082e6108d3366004613982565b600b6020526000908152604090205460ff1681565b3480156108f457600080fd5b506104a3610903366004613982565b6000908152600c602052604090205490565b34801561092157600080fd5b506104a3610930366004613982565b60046020526000908152604090205481565b34801561094e57600080fd5b5061082e61095d366004613982565b61223d565b34801561096e57600080fd5b5061042b61228f565b34801561098357600080fd5b506013546105e79073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109b057600080fd5b5061042b6109bf366004613cf8565b61238c565b3480156109d057600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105e7565b3480156109fb57600080fd5b506104a3610a0a366004613982565b60056020526000908152604090205481565b348015610a2857600080fd5b5061042b610a373660046138d0565b61241d565b348015610a4857600080fd5b5061042b610a57366004613d44565b612662565b348015610a6857600080fd5b50601554610a86906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161047a565b348015610aa457600080fd5b5061042b610ab33660046138d0565b60009182526009602052604090912055565b348015610ad157600080fd5b50610512610ae0366004613982565b600e6020526000908152604090205461ffff1681565b348015610b0257600080fd5b5061046d610b11366004613982565b6127ab565b348015610b2257600080fd5b506104d1610b31366004613982565b61280d565b348015610b4257600080fd5b506104a37f000000000000000000000000000000000000000000000000000000000000000081565b348015610b7657600080fd5b5061042b610b85366004613a87565b6128b9565b348015610b9657600080fd5b5061042b610ba5366004613982565b601455565b348015610bb657600080fd5b5061042b610bc5366004613d74565b612922565b348015610bd657600080fd5b5061042b610be53660046138d0565b60009182526007602052604090912055565b348015610c0357600080fd5b5061042b610c12366004613982565b6129cd565b348015610c2357600080fd5b506104d16040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525081565b348015610c6c57600080fd5b5061042b610c7b366004613af8565b612a53565b348015610c8c57600080fd5b5061042b610c9b366004613d99565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610ce657600080fd5b5061042b610cf5366004613982565b612aed565b348015610d0657600080fd5b506104d16040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525081565b348015610d4f57600080fd5b5061042b610d5e366004613db6565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610dae57600080fd5b50610545610dbd3660046138d0565b612b85565b348015610dce57600080fd5b5061042b610ddd366004613af8565b612bee565b348015610dee57600080fd5b506104a3610dfd3660046138d0565b612cb9565b348015610e0e57600080fd5b506104a3610e1d366004613982565b60096020526000908152604090205481565b348015610e3b57600080fd5b506104a360145481565b348015610e5157600080fd5b5061042b610e60366004613a6a565b612cea565b348015610e7157600080fd5b506104a3610e80366004613982565b60066020526000908152604090205481565b348015610e9e57600080fd5b506104a3610ead366004613982565b60026020526000908152604090205481565b8051610ed29060169060208401906134e3565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610fbc908c1688613e02565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af115801561103a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061105e9190613e46565b5060008860ff1667ffffffffffffffff81111561107d5761107d6135c3565b6040519080825280602002602001820160405280156110a6578160200160208202803683370190505b50905060005b8960ff168160ff16101561124f5760006110c584612cfe565b90508860ff166001036111fd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa15801561112a573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111709190810190613eae565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906111c99085908590600401613ee3565b600060405180830381600087803b1580156111e357600080fd5b505af11580156111f7573d6000803e3d6000fd5b50505050505b80838360ff168151811061121357611213613efc565b6020908102919091018101919091526000918252600881526040808320889055600790915290208490558061124781613f2b565b9150506110ac565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161127f91906138f2565b60405180910390a1505050505050505050565b606060006112a0600f612dcc565b90508084106112db576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036112f0576112ed8482613f4a565b92505b60008367ffffffffffffffff81111561130b5761130b6135c3565b604051908082528060200260200182016040528015611334578160200160208202803683370190505b50905060005b848110156113865761135761134f8288613f5d565b600f90612dd6565b82828151811061136957611369613efc565b60209081029190910101528061137e81613f70565b91505061133a565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106113b957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f000000000000000000000000000000000000000000000000000000000000000081526020018460405160200161143d91815260200190565b60405160208183030381529060405261145590613fa8565b81526020016000801b81526020016000801b8152509050806040516020016114d59190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561155057602002820191906000526020600020905b81548152602001906001019080831161153c575b50505050509050611562818251612de2565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611605573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116299190613ff8565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156116cc573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116f09190614026565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261179a9383018282801561178e57602002820191906000526020600020905b81548152602001906001019080831161177a575b50505050508484612e67565b90505b9392505050565b8060005b818160ff161015611838573063c8048022858560ff85168181106117ce576117ce613efc565b905060200201356040518263ffffffff1660e01b81526004016117f391815260200190565b600060405180830381600087803b15801561180d57600080fd5b505af1158015611821573d6000803e3d6000fd5b50505050808061183090613f2b565b9150506117a8565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff161161189f576000858152600d6020908152604080832061ffff8516845290915290205461188b9083613f5d565b91508061189781614043565b915050611854565b509392505050565b60005a90506000806118bb84860186613bb2565b915091506000818060200190518101906118d59190614064565b600081815260056020908152604080832054600490925282205492935091906118fc612fc6565b90508260000361191c576000848152600560205260409020819055611a77565b6000848152600360205260408120546119358484613f4a565b61193f9190613f4a565b6000868152600e6020908152604080832054600d835281842061ffff9091168085529083528184208054835181860281018601909452808452959650909491929091908301828280156119b157602002820191906000526020600020905b81548152602001906001019080831161199d575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611a2c57816119ee81614043565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b600084815260066020526040812054611a91906001613f5d565b6000868152600660209081526040808320849055600490915290208390559050611abb858361241d565b611ac68589846128b9565b50505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611b3457602002820191906000526020600020905b815481526020019060010190808311611b20575b5050505050905092915050565b6000606060008484604051602001611b5a92919061407d565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611c325730635f17e616868684818110611bb957611bb9613efc565b90506020020135856040518363ffffffff1660e01b8152600401611bed92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611c0757600080fd5b505af1158015611c1b573d6000803e3d6000fd5b505050508080611c2a90613f70565b915050611b99565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611cb0573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611cf69190810190614111565b80519091506000611d05612fc6565b905060005b82811015611838576000848281518110611d2657611d26613efc565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611da6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dca91906141a2565b90508060ff16600103611e0f57604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611e1c90613f70565b915050611d0a565b611e2c613068565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611e9b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ebf9190614064565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611f37573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ed29190613e46565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611f9391613539565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611fef576000848152600d6020908152604080832061ffff851684529091528120611fdd91613539565b80611fe781614043565b915050611fa8565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a9050600061203f85870187613982565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115612078576120786135c3565b6040519080825280601f01601f1916602001820160405280156120a2576020820181803683370190505b506040516020016120b4929190613ee3565b604051602081830303815290604052905060006120cf612fc6565b905060006120dc8661223d565b90505b835a6120eb9089613f4a565b6120f790612710613f5d565b10156121385781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556120df565b80612150576000839850985050505050505050611568565b6040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525060166040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525084896040516020016121d291815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e000000000000000000000000000000000000000000000000000000008252612234959493929160040161420c565b60405180910390fd5b600081815260056020526040812054810361225a57506001919050565b60008281526003602090815260408083205460049092529091205461227d612fc6565b6122879190613f4a565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612310576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401612234565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b5906123e690869086908690600401614359565b600060405180830381600087803b15801561240057600080fd5b505af1158015612414573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124399083613f4a565b1115610ed2576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa1580156124af573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526124f591908101906143db565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa15801561256a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061258e91906144fa565b6015549091506125b29082906c01000000000000000000000000900460ff16613e02565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff161015611838576015546125f59085906bffffffffffffffffffffffff16612662565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af11580156126ea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061270e9190613e46565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561278f57600080fd5b505af11580156127a3573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561280157602002820191906000526020600020905b8154815260200190600101908083116127ed575b50505050509050919050565b6016818154811061281d57600080fd5b906000526020600020016000915090508054612838906141bf565b80601f0160208091040260200160405190810160405280929190818152602001828054612864906141bf565b80156128b15780601f10612886576101008083540402835291602001916128b1565b820191906000526020600020905b81548152906001019060200180831161289457829003601f168201915b505050505081565b6000838152600760205260409020545b805a6128d59085613f4a565b6128e190612710613f5d565b10156118385781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556128c9565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561299a57600080fd5b505af11580156129ae573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612a3f57600080fd5b505af1158015611c32573d6000803e3d6000fd5b8060005b818163ffffffff161015611838573063af953a4a858563ffffffff8516818110612a8357612a83613efc565b905060200201356040518263ffffffff1660e01b8152600401612aa891815260200190565b600060405180830381600087803b158015612ac257600080fd5b505af1158015612ad6573d6000803e3d6000fd5b505050508080612ae590614517565b915050612a57565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612b5957600080fd5b505af1158015612b6d573d6000803e3d6000fd5b50505050610ed281600f6130eb90919063ffffffff16565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612bdd57602002820191906000526020600020905b815481526020019060010190808311612bc9575b505050505090506115628185612de2565b8060005b81811015611838576000848483818110612c0e57612c0e613efc565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612c4791815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612c73929190613ee3565b600060405180830381600087803b158015612c8d57600080fd5b505af1158015612ca1573d6000803e3d6000fd5b50505050508080612cb190613f70565b915050612bf2565b600c6020528160005260406000208181548110612cd557600080fd5b90600052602060002001600091509150505481565b612cf2613068565b612cfb816130f7565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612d59908690600401614530565b6020604051808303816000875af1158015612d78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d9c9190614064565b9050612da9600f826131ec565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061138b825490565b600061179d83836131f8565b815160009081908190841580612df85750808510155b15612e01578094505b60008092505b85831015612e5d57866001612e1c8585613f4a565b612e269190613f4a565b81518110612e3657612e36613efc565b602002602001015181612e499190613f5d565b905082612e5581613f70565b935050612e07565b9694955050505050565b82516000908190831580612e7b5750808410155b15612e84578093505b60008467ffffffffffffffff811115612e9f57612e9f6135c3565b604051908082528060200260200182016040528015612ec8578160200160208202803683370190505b509050600092505b84831015612f3657866001612ee58585613f4a565b612eef9190613f4a565b81518110612eff57612eff613efc565b6020026020010151818481518110612f1957612f19613efc565b602090810291909101015282612f2e81613f70565b935050612ed0565b612f4f81600060018451612f4a9190613f4a565b613222565b85606403612f88578060018251612f669190613f4a565b81518110612f7657612f76613efc565b6020026020010151935050505061179d565b806064825188612f989190614682565b612fa291906146ee565b81518110612fb257612fb2613efc565b602002602001015193505050509392505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561306357606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561303a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061305e9190614064565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff1633146130e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612234565b565b600061179d838361339a565b3373ffffffffffffffffffffffffffffffffffffffff821603613176576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612234565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600061179d8383613494565b600082600001828154811061320f5761320f613efc565b9060005260206000200154905092915050565b8181808203613232575050505050565b60008560026132418787614702565b61324b9190614722565b613255908761478a565b8151811061326557613265613efc565b602002602001015190505b818313613374575b8086848151811061328b5761328b613efc565b602002602001015110156132ab57826132a3816147b2565b935050613278565b8582815181106132bd576132bd613efc565b60200260200101518110156132de57816132d6816147e3565b9250506132ab565b81831361336f578582815181106132f7576132f7613efc565b602002602001015186848151811061331157613311613efc565b602002602001015187858151811061332b5761332b613efc565b6020026020010188858151811061334457613344613efc565b6020908102919091010191909152528261335d816147b2565b935050818061336b906147e3565b9250505b613270565b8185121561338757613387868684613222565b838312156127a3576127a3868486613222565b600081815260018301602052604081205480156134835760006133be600183613f4a565b85549091506000906133d290600190613f4a565b90508181146134375760008660000182815481106133f2576133f2613efc565b906000526020600020015490508087600001848154811061341557613415613efc565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134485761344861483a565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061138b565b600091505061138b565b5092915050565b60008181526001830160205260408120546134db5750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561138b565b50600061138b565b828054828255906000526020600020908101928215613529579160200282015b82811115613529578251829061351990826148b4565b5091602001919060010190613503565b50613535929150613557565b5090565b5080546000825590600052602060002090810190612cfb9190613574565b8082111561353557600061356b8282613589565b50600101613557565b5b808211156135355760008155600101613575565b508054613595906141bf565b6000825580601f106135a5575050565b601f016020900490600052602060002090810190612cfb9190613574565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff81118282101715613616576136166135c3565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613663576136636135c3565b604052919050565b600067ffffffffffffffff821115613685576136856135c3565b5060051b60200190565b600067ffffffffffffffff8211156136a9576136a96135c3565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b60006136e86136e38461368f565b61361c565b90508281528383830111156136fc57600080fd5b828260208301376000602084830101529392505050565b6000602080838503121561372657600080fd5b823567ffffffffffffffff8082111561373e57600080fd5b818501915085601f83011261375257600080fd5b81356137606136e38261366b565b81815260059190911b8301840190848101908883111561377f57600080fd5b8585015b838110156137cc5780358581111561379b5760008081fd5b8601603f81018b136137ad5760008081fd5b6137be8b89830135604084016136d5565b845250918601918601613783565b5098975050505050505050565b60ff81168114612cfb57600080fd5b63ffffffff81168114612cfb57600080fd5b600082601f83011261380b57600080fd5b61179d838335602085016136d5565b6bffffffffffffffffffffffff81168114612cfb57600080fd5b600080600080600080600060e0888a03121561384f57600080fd5b873561385a816137d9565b9650602088013561386a816137e8565b9550604088013561387a816137d9565b9450606088013567ffffffffffffffff81111561389657600080fd5b6138a28a828b016137fa565b94505060808801356138b38161381a565b9699959850939692959460a0840135945060c09093013592915050565b600080604083850312156138e357600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561392a5783518352928401929184019160010161390e565b50909695505050505050565b803561ffff8116811461394857600080fd5b919050565b60008060006060848603121561396257600080fd5b8335925061397260208501613936565b9150604084013590509250925092565b60006020828403121561399457600080fd5b5035919050565b60005b838110156139b657818101518382015260200161399e565b50506000910152565b600081518084526139d781602086016020860161399b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061179d60208301846139bf565b60008060408385031215613a2f57600080fd5b82359150613a3f60208401613936565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612cfb57600080fd5b600060208284031215613a7c57600080fd5b813561179d81613a48565b600080600060608486031215613a9c57600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613ac557600080fd5b50813567ffffffffffffffff811115613add57600080fd5b6020830191508360208260051b850101111561156857600080fd5b60008060208385031215613b0b57600080fd5b823567ffffffffffffffff811115613b2257600080fd5b613b2e85828601613ab3565b90969095509350505050565b60008083601f840112613b4c57600080fd5b50813567ffffffffffffffff811115613b6457600080fd5b60208301915083602082850101111561156857600080fd5b60008060208385031215613b8f57600080fd5b823567ffffffffffffffff811115613ba657600080fd5b613b2e85828601613b3a565b60008060408385031215613bc557600080fd5b823567ffffffffffffffff80821115613bdd57600080fd5b818501915085601f830112613bf157600080fd5b81356020613c016136e38361366b565b82815260059290921b84018101918181019089841115613c2057600080fd5b8286015b84811015613c5857803586811115613c3c5760008081fd5b613c4a8c86838b01016137fa565b845250918301918301613c24565b5096505086013592505080821115613c6f57600080fd5b50613c7c858286016137fa565b9150509250929050565b821515815260406020820152600061179a60408301846139bf565b600080600060408486031215613cb657600080fd5b833567ffffffffffffffff811115613ccd57600080fd5b613cd986828701613ab3565b9094509250506020840135613ced816137e8565b809150509250925092565b600080600060408486031215613d0d57600080fd5b83359250602084013567ffffffffffffffff811115613d2b57600080fd5b613d3786828701613b3a565b9497909650939450505050565b60008060408385031215613d5757600080fd5b823591506020830135613d698161381a565b809150509250929050565b60008060408385031215613d8757600080fd5b823591506020830135613d69816137e8565b600060208284031215613dab57600080fd5b813561179d8161381a565b600060208284031215613dc857600080fd5b813561179d816137d9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613e2d57613e2d613dd3565b02949350505050565b8051801515811461394857600080fd5b600060208284031215613e5857600080fd5b61179d82613e36565b600082601f830112613e7257600080fd5b8151613e806136e38261368f565b818152846020838601011115613e9557600080fd5b613ea682602083016020870161399b565b949350505050565b600060208284031215613ec057600080fd5b815167ffffffffffffffff811115613ed757600080fd5b613ea684828501613e61565b82815260406020820152600061179a60408301846139bf565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103613f4157613f41613dd3565b60010192915050565b8181038181111561138b5761138b613dd3565b8082018082111561138b5761138b613dd3565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa157613fa1613dd3565b5060010190565b80516020808301519190811015613fe7577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161394881613a48565b6000806040838503121561400b57600080fd5b825161401681613a48565b6020939093015192949293505050565b60006020828403121561403857600080fd5b815161179d81613a48565b600061ffff80831681810361405a5761405a613dd3565b6001019392505050565b60006020828403121561407657600080fd5b5051919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156140f2577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030185526140e08683516139bf565b955093820193908201906001016140a6565b50508584038187015250505061410881856139bf565b95945050505050565b6000602080838503121561412457600080fd5b825167ffffffffffffffff81111561413b57600080fd5b8301601f8101851361414c57600080fd5b805161415a6136e38261366b565b81815260059190911b8201830190838101908783111561417957600080fd5b928401925b828410156141975783518252928401929084019061417e565b979650505050505050565b6000602082840312156141b457600080fd5b815161179d816137d9565b600181811c908216806141d357607f821691505b602082108103613fe7577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60a08152600061421f60a08301886139bf565b602083820381850152818854808452828401915060058382821b86010160008c8152858120815b85811015614319577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0898503018752828254614281816141bf565b8087526001828116801561429c57600181146142d357614302565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0084168d8a01528c8315158b1b8a01019450614302565b8688528c8820885b848110156142fa5781548f828d01015283820191508e810190506142db565b8a018e019550505b50998b019992965050509190910190600101614246565b505050878103604089015261432e818c6139bf565b95505050505050846060840152828103608084015261434d81856139bf565b98975050505050505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b8051613948816137e8565b80516139488161381a565b805167ffffffffffffffff8116811461394857600080fd5b6000602082840312156143ed57600080fd5b815167ffffffffffffffff8082111561440557600080fd5b90830190610140828603121561441a57600080fd5b6144226135f2565b61442b83613fed565b8152614439602084016143ad565b602082015260408301518281111561445057600080fd5b61445c87828601613e61565b60408301525061446e606084016143b8565b606082015261447f60808401613fed565b608082015261449060a084016143c3565b60a08201526144a160c084016143ad565b60c08201526144b260e084016143b8565b60e08201526101006144c5818501613e36565b9082015261012083810151838111156144dd57600080fd5b6144e988828701613e61565b918301919091525095945050505050565b60006020828403121561450c57600080fd5b815161179d8161381a565b600063ffffffff80831681810361405a5761405a613dd3565b602081526000825161014080602085015261454f6101608501836139bf565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261458b84836139bf565b9350604087015191506145b6606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e087015261461784836139bf565b935060e0870151915061010081878603018188015261463685846139bf565b94508088015192505061012081878603018188015261465585846139bf565b94508088015192505050614678828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156146ba576146ba613dd3565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826146fd576146fd6146bf565b500490565b818103600083128015838313168383128216171561348d5761348d613dd3565b600082614731576147316146bf565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561478557614785613dd3565b500590565b80820182811260008312801582168215821617156147aa576147aa613dd3565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613fa157613fa1613dd3565b60007f8000000000000000000000000000000000000000000000000000000000000000820361481457614814613dd3565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f8211156148af57600081815260208120601f850160051c810160208610156148905750805b601f850160051c820191505b818110156127a35782815560010161489c565b505050565b815167ffffffffffffffff8111156148ce576148ce6135c3565b6148e2816148dc84546141bf565b84614869565b602080601f83116001811461493557600084156148ff5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556127a3565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561498257888601518255948401946001909101908401614963565b50858210156149be57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307835353533343434333264353535333434326434313532343234393534353235353464326435343435353335343465343535343030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"sendLog\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x7f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0526101c0604052604261014081815260e091829190620050fb6101603981526020016040518060800160405280604281526020016200513d6042913981526020016040518060800160405280604281526020016200517f604291399052620000b89060169060036200035f565b50348015620000c657600080fd5b50604051620051c1380380620051c1833981016040819052620000e9916200044c565b81813380600081620001425760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b038481169190911790915581161562000175576200017581620002b4565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa158015620001d2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001f891906200048f565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156200025e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620002849190620004c0565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a0525062000658915050565b336001600160a01b038216036200030e5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000139565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215620003aa579160200282015b82811115620003aa57825182906200039990826200058c565b509160200191906001019062000380565b50620003b8929150620003bc565b5090565b80821115620003b8576000620003d38282620003dd565b50600101620003bc565b508054620003eb90620004fd565b6000825580601f10620003fc575050565b601f0160209004906000526020600020908101906200041c91906200041f565b50565b5b80821115620003b8576000815560010162000420565b6001600160a01b03811681146200041c57600080fd5b600080604083850312156200046057600080fd5b82516200046d8162000436565b602084015190925080151581146200048457600080fd5b809150509250929050565b60008060408385031215620004a357600080fd5b8251620004b08162000436565b6020939093015192949293505050565b600060208284031215620004d357600080fd5b8151620004e08162000436565b9392505050565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200051257607f821691505b6020821081036200053357634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200058757600081815260208120601f850160051c81016020861015620005625750805b601f850160051c820191505b8181101562000583578281556001016200056e565b5050505b505050565b81516001600160401b03811115620005a857620005a8620004e7565b620005c081620005b98454620004fd565b8462000539565b602080601f831160018114620005f85760008415620005df5750858301515b600019600386901b1c1916600185901b17855562000583565b600085815260208120601f198616915b82811015620006295788860151825594840194600190910190840162000608565b5085821015620006485787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a05160c051614a5e6200069d6000396000818161052b0152611a3d0152600081816108470152612e69015260008181610b8301526114410152614a5e6000f3fe6080604052600436106103e25760003560e01c8063776898c81161020d578063a72aa27e11610128578063d3558528116100bb578063e0114adb1161008a578063f2fde38b1161006f578063f2fde38b14610e80578063fba7ffa314610ea0578063fcdc1f6314610ecd57600080fd5b8063e0114adb14610e3d578063e455308314610e6a57600080fd5b8063d355852814610d7e578063d6051a7214610ddd578063daee1aeb14610dfd578063dbef701e14610e1d57600080fd5b8063becde0e1116100f7578063becde0e114610c9b578063c357f1f314610cbb578063c804802214610d15578063c98f10b014610d3557600080fd5b8063a72aa27e14610be5578063a79c404314610c05578063af953a4a14610c32578063afb28d1f14610c5257600080fd5b80639ac542eb116101a05780639d6f1cc71161016f5780639d6f1cc714610b51578063a654824814610b71578063a6b5947514610ba5578063a6c60d8914610bc557600080fd5b80639ac542eb14610a975780639b42935414610ad35780639b51fb0d14610b005780639d385eaa14610b3157600080fd5b80638da5cb5b116101dc5780638da5cb5b146109ff5780638fcb3fba14610a2a578063924ca57814610a57578063948108f714610a7757600080fd5b8063776898c81461097d57806379ba50971461099d5780637b103999146109b25780637e7a46dc146109df57600080fd5b806346e7a63e116102fd578063636092e8116102905780636e04ff0d1161025f5780636e04ff0d146108d35780637145f11b146108f357806373644cce14610923578063767213031461095057600080fd5b8063636092e8146107f3578063642f6cef1461083557806369cdbadb1461087957806369e9b773146108a657600080fd5b806359710992116102cc578063597109921461077c5780635d4ee7f3146107915780635f17e616146107a657806360457ff5146107c657600080fd5b806346e7a63e146106d45780634b56a42e1461070157806351c98be31461072f57806357970e931461074f57600080fd5b806320e3dbd411610375578063328ffd1111610344578063328ffd11146106475780633ebe8d6c146106745780634585e33b1461069457806345d2ec17146106b457600080fd5b806320e3dbd41461059557806328c4b57b146105b55780632a9032d3146105d55780632b20e397146105f557600080fd5b80630d4a4fb1116103b15780630d4a4fb1146104cc5780630e577d42146104f957806312c5502714610519578063206c32e81461056057600080fd5b806305e251311461042657806306c1cc001461044857806306e3b63214610468578063077ac6211461049e57600080fd5b3661042157604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b34801561043257600080fd5b50610446610441366004613796565b610efa565b005b34801561045457600080fd5b506104466104633660046138b7565b610f11565b34801561047457600080fd5b50610488610483366004613953565b6112cd565b6040516104959190613975565b60405180910390f35b3480156104aa57600080fd5b506104be6104b93660046139d0565b6113cc565b604051908152602001610495565b3480156104d857600080fd5b506104ec6104e7366004613a05565b61140a565b6040516104959190613a8c565b34801561050557600080fd5b50610446610514366004613a05565b611527565b34801561052557600080fd5b5061054d7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610495565b34801561056c57600080fd5b5061058061057b366004613a9f565b61156f565b60408051928352602083019190915201610495565b3480156105a157600080fd5b506104466105b0366004613aed565b6115f2565b3480156105c157600080fd5b506104be6105d0366004613b0a565b6117bc565b3480156105e157600080fd5b506104466105f0366004613b7b565b611827565b34801561060157600080fd5b506011546106229073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610495565b34801561065357600080fd5b506104be610662366004613a05565b60036020526000908152604090205481565b34801561068057600080fd5b506104be61068f366004613a05565b6118c1565b3480156106a057600080fd5b506104466106af366004613bff565b61192a565b3480156106c057600080fd5b506104886106cf366004613a9f565b611b55565b3480156106e057600080fd5b506104be6106ef366004613a05565b600a6020526000908152604090205481565b34801561070d57600080fd5b5061072161071c366004613c35565b611bc4565b604051610495929190613d09565b34801561073b57600080fd5b5061044661074a366004613d24565b611c18565b34801561075b57600080fd5b506012546106229073ffffffffffffffffffffffffffffffffffffffff1681565b34801561078857600080fd5b50610446611cbc565b34801561079d57600080fd5b50610446611ea7565b3480156107b257600080fd5b506104466107c1366004613953565b611fde565b3480156107d257600080fd5b506104be6107e1366004613a05565b60076020526000908152604090205481565b3480156107ff57600080fd5b50601554610818906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610495565b34801561084157600080fd5b506108697f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610495565b34801561088557600080fd5b506104be610894366004613a05565b60086020526000908152604090205481565b3480156108b257600080fd5b506104466108c1366004613953565b60009182526008602052604090912055565b3480156108df57600080fd5b506107216108ee366004613bff565b6120ab565b3480156108ff57600080fd5b5061086961090e366004613a05565b600b6020526000908152604090205460ff1681565b34801561092f57600080fd5b506104be61093e366004613a05565b6000908152600c602052604090205490565b34801561095c57600080fd5b506104be61096b366004613a05565b60046020526000908152604090205481565b34801561098957600080fd5b50610869610998366004613a05565b6122c0565b3480156109a957600080fd5b50610446612312565b3480156109be57600080fd5b506013546106229073ffffffffffffffffffffffffffffffffffffffff1681565b3480156109eb57600080fd5b506104466109fa366004613d7b565b61240f565b348015610a0b57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610622565b348015610a3657600080fd5b506104be610a45366004613a05565b60056020526000908152604090205481565b348015610a6357600080fd5b50610446610a72366004613953565b6124a0565b348015610a8357600080fd5b50610446610a92366004613dc7565b6126e5565b348015610aa357600080fd5b50601554610ac1906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610495565b348015610adf57600080fd5b50610446610aee366004613953565b60009182526009602052604090912055565b348015610b0c57600080fd5b5061054d610b1b366004613a05565b600e6020526000908152604090205461ffff1681565b348015610b3d57600080fd5b50610488610b4c366004613a05565b61282e565b348015610b5d57600080fd5b506104ec610b6c366004613a05565b612890565b348015610b7d57600080fd5b506104be7f000000000000000000000000000000000000000000000000000000000000000081565b348015610bb157600080fd5b50610446610bc0366004613b0a565b61293c565b348015610bd157600080fd5b50610446610be0366004613a05565b601455565b348015610bf157600080fd5b50610446610c00366004613df7565b6129a5565b348015610c1157600080fd5b50610446610c20366004613953565b60009182526007602052604090912055565b348015610c3e57600080fd5b50610446610c4d366004613a05565b612a50565b348015610c5e57600080fd5b506104ec6040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525081565b348015610ca757600080fd5b50610446610cb6366004613b7b565b612ad6565b348015610cc757600080fd5b50610446610cd6366004613e1c565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610d2157600080fd5b50610446610d30366004613a05565b612b70565b348015610d4157600080fd5b506104ec6040518060400160405280600b81526020017f626c6f636b4e756d62657200000000000000000000000000000000000000000081525081565b348015610d8a57600080fd5b50610446610d99366004613e39565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610de957600080fd5b50610580610df8366004613953565b612c08565b348015610e0957600080fd5b50610446610e18366004613b7b565b612c71565b348015610e2957600080fd5b506104be610e38366004613953565b612d3c565b348015610e4957600080fd5b506104be610e58366004613a05565b60096020526000908152604090205481565b348015610e7657600080fd5b506104be60145481565b348015610e8c57600080fd5b50610446610e9b366004613aed565b612d6d565b348015610eac57600080fd5b506104be610ebb366004613a05565b60066020526000908152604090205481565b348015610ed957600080fd5b506104be610ee8366004613a05565b60026020526000908152604090205481565b8051610f0d906016906020840190613566565b5050565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610ff7908c1688613e85565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015611075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110999190613ec9565b5060008860ff1667ffffffffffffffff8111156110b8576110b8613646565b6040519080825280602002602001820160405280156110e1578160200160208202803683370190505b50905060005b8960ff168160ff16101561128a57600061110084612d81565b90508860ff16600103611238576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015611165573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526111ab9190810190613f31565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906112049085908590600401613f66565b600060405180830381600087803b15801561121e57600080fd5b505af1158015611232573d6000803e3d6000fd5b50505050505b80838360ff168151811061124e5761124e613f7f565b6020908102919091018101919091526000918252600881526040808320889055600790915290208490558061128281613fae565b9150506110e7565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c711816040516112ba9190613975565b60405180910390a1505050505050505050565b606060006112db600f612e4f565b9050808410611316576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260000361132b576113288482613fcd565b92505b60008367ffffffffffffffff81111561134657611346613646565b60405190808252806020026020018201604052801561136f578160200160208202803683370190505b50905060005b848110156113c15761139261138a8288613fe0565b600f90612e59565b8282815181106113a4576113a4613f7f565b6020908102919091010152806113b981613ff3565b915050611375565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106113f457600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f000000000000000000000000000000000000000000000000000000000000000081526020018460405160200161147891815260200190565b6040516020818303038152906040526114909061402b565b81526020016000801b81526020016000801b8152509050806040516020016115109190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000611531612e65565b604051308152909150819083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35050565b6000828152600d6020908152604080832061ffff8516845282528083208054825181850281018501909352808352849384939291908301828280156115d357602002820191906000526020600020905b8154815260200190600101908083116115bf575b505050505090506115e5818251612f07565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611688573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116ac919061407b565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa15801561174f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061177391906140a9565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261181d9383018282801561181157602002820191906000526020600020905b8154815260200190600101908083116117fd575b50505050508484612f8c565b90505b9392505050565b8060005b818160ff1610156118bb573063c8048022858560ff851681811061185157611851613f7f565b905060200201356040518263ffffffff1660e01b815260040161187691815260200190565b600060405180830381600087803b15801561189057600080fd5b505af11580156118a4573d6000803e3d6000fd5b5050505080806118b390613fae565b91505061182b565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff1611611922576000858152600d6020908152604080832061ffff8516845290915290205461190e9083613fe0565b91508061191a816140c6565b9150506118d7565b509392505050565b60005a905060008061193e84860186613c35565b9150915060008180602001905181019061195891906140e7565b6000818152600560209081526040808320546004909252822054929350919061197f612e65565b90508260000361199f576000848152600560205260409020819055611afa565b6000848152600360205260408120546119b88484613fcd565b6119c29190613fcd565b6000868152600e6020908152604080832054600d835281842061ffff909116808552908352818420805483518186028101860190945280845295965090949192909190830182828015611a3457602002820191906000526020600020905b815481526020019060010190808311611a20575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611aaf5781611a71816140c6565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b600084815260066020526040812054611b14906001613fe0565b6000868152600660209081526040808320849055600490915290208390559050611b3e85836124a0565b611b4985898461293c565b50505050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611bb757602002820191906000526020600020905b815481526020019060010190808311611ba3575b5050505050905092915050565b6000606060008484604051602001611bdd929190614100565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526001969095509350505050565b8160005b81811015611cb55730635f17e616868684818110611c3c57611c3c613f7f565b90506020020135856040518363ffffffff1660e01b8152600401611c7092919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611c8a57600080fd5b505af1158015611c9e573d6000803e3d6000fd5b505050508080611cad90613ff3565b915050611c1c565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611d33573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611d799190810190614194565b80519091506000611d88612e65565b905060005b828110156118bb576000848281518110611da957611da9613f7f565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611e29573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e4d9190614225565b90508060ff16600103611e9257604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611e9f90613ff3565b915050611d8d565b611eaf6130eb565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611f1e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611f4291906140e7565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611fba573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f0d9190613ec9565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120612016916135bc565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611612072576000848152600d6020908152604080832061ffff851684529091528120612060916135bc565b8061206a816140c6565b91505061202b565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a905060006120c285870187613a05565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff8111156120fb576120fb613646565b6040519080825280601f01601f191660200182016040528015612125576020820181803683370190505b50604051602001612137929190613f66565b60405160208183030381529060405290506000612152612e65565b9050600061215f866122c0565b90505b835a61216e9089613fcd565b61217a90612710613fe0565b10156121bb5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612162565b806121d35760008398509850505050505050506115eb565b6040518060400160405280600981526020017f666565644964486578000000000000000000000000000000000000000000000081525060166040518060400160405280600b81526020017f626c6f636b4e756d626572000000000000000000000000000000000000000000815250848960405160200161225591815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526122b7959493929160040161428f565b60405180910390fd5b60008181526005602052604081205481036122dd57506001919050565b600082815260036020908152604080832054600490925290912054612300612e65565b61230a9190613fcd565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612393576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016122b7565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b590612469908690869086906004016143dc565b600060405180830381600087803b15801561248357600080fd5b505af1158015612497573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546124bc9083613fcd565b1115610f0d576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612532573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612578919081019061445e565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156125ed573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612611919061457d565b6015549091506126359082906c01000000000000000000000000900460ff16613e85565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156118bb576015546126789085906bffffffffffffffffffffffff166126e5565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af115801561276d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906127919190613ec9565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561281257600080fd5b505af1158015612826573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561288457602002820191906000526020600020905b815481526020019060010190808311612870575b50505050509050919050565b601681815481106128a057600080fd5b9060005260206000200160009150905080546128bb90614242565b80601f01602080910402602001604051908101604052809291908181526020018280546128e790614242565b80156129345780601f1061290957610100808354040283529160200191612934565b820191906000526020600020905b81548152906001019060200180831161291757829003601f168201915b505050505081565b6000838152600760205260409020545b805a6129589085613fcd565b61296490612710613fe0565b10156118bb5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905561294c565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b158015612a1d57600080fd5b505af1158015612a31573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b158015612ac257600080fd5b505af1158015611cb5573d6000803e3d6000fd5b8060005b818163ffffffff1610156118bb573063af953a4a858563ffffffff8516818110612b0657612b06613f7f565b905060200201356040518263ffffffff1660e01b8152600401612b2b91815260200190565b600060405180830381600087803b158015612b4557600080fd5b505af1158015612b59573d6000803e3d6000fd5b505050508080612b689061459a565b915050612ada565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b158015612bdc57600080fd5b505af1158015612bf0573d6000803e3d6000fd5b50505050610f0d81600f61316e90919063ffffffff16565b6000828152600c60209081526040808320805482518185028101850190935280835284938493929190830182828015612c6057602002820191906000526020600020905b815481526020019060010190808311612c4c575b505050505090506115e58185612f07565b8060005b818110156118bb576000848483818110612c9157612c91613f7f565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc8283604051602001612cca91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612cf6929190613f66565b600060405180830381600087803b158015612d1057600080fd5b505af1158015612d24573d6000803e3d6000fd5b50505050508080612d3490613ff3565b915050612c75565b600c6020528160005260406000208181548110612d5857600080fd5b90600052602060002001600091509150505481565b612d756130eb565b612d7e8161317a565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612ddc9086906004016145b3565b6020604051808303816000875af1158015612dfb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e1f91906140e7565b9050612e2c600f8261326f565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b60006113c6825490565b6000611820838361327b565b60007f000000000000000000000000000000000000000000000000000000000000000015612f0257606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612ed9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612efd91906140e7565b905090565b504390565b815160009081908190841580612f1d5750808510155b15612f26578094505b60008092505b85831015612f8257866001612f418585613fcd565b612f4b9190613fcd565b81518110612f5b57612f5b613f7f565b602002602001015181612f6e9190613fe0565b905082612f7a81613ff3565b935050612f2c565b9694955050505050565b82516000908190831580612fa05750808410155b15612fa9578093505b60008467ffffffffffffffff811115612fc457612fc4613646565b604051908082528060200260200182016040528015612fed578160200160208202803683370190505b509050600092505b8483101561305b5786600161300a8585613fcd565b6130149190613fcd565b8151811061302457613024613f7f565b602002602001015181848151811061303e5761303e613f7f565b60209081029190910101528261305381613ff3565b935050612ff5565b6130748160006001845161306f9190613fcd565b6132a5565b856064036130ad57806001825161308b9190613fcd565b8151811061309b5761309b613f7f565b60200260200101519350505050611820565b8060648251886130bd9190614705565b6130c79190614771565b815181106130d7576130d7613f7f565b602002602001015193505050509392505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461316c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016122b7565b565b6000611820838361341d565b3373ffffffffffffffffffffffffffffffffffffffff8216036131f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016122b7565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006118208383613517565b600082600001828154811061329257613292613f7f565b9060005260206000200154905092915050565b81818082036132b5575050505050565b60008560026132c48787614785565b6132ce91906147a5565b6132d8908761480d565b815181106132e8576132e8613f7f565b602002602001015190505b8183136133f7575b8086848151811061330e5761330e613f7f565b6020026020010151101561332e578261332681614835565b9350506132fb565b85828151811061334057613340613f7f565b6020026020010151811015613361578161335981614866565b92505061332e565b8183136133f25785828151811061337a5761337a613f7f565b602002602001015186848151811061339457613394613f7f565b60200260200101518785815181106133ae576133ae613f7f565b602002602001018885815181106133c7576133c7613f7f565b602090810291909101019190915252826133e081614835565b93505081806133ee90614866565b9250505b6132f3565b8185121561340a5761340a8686846132a5565b83831215612826576128268684866132a5565b60008181526001830160205260408120548015613506576000613441600183613fcd565b855490915060009061345590600190613fcd565b90508181146134ba57600086600001828154811061347557613475613f7f565b906000526020600020015490508087600001848154811061349857613498613f7f565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806134cb576134cb6148bd565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506113c6565b60009150506113c6565b5092915050565b600081815260018301602052604081205461355e575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556113c6565b5060006113c6565b8280548282559060005260206000209081019282156135ac579160200282015b828111156135ac578251829061359c9082614937565b5091602001919060010190613586565b506135b89291506135da565b5090565b5080546000825590600052602060002090810190612d7e91906135f7565b808211156135b85760006135ee828261360c565b506001016135da565b5b808211156135b857600081556001016135f8565b50805461361890614242565b6000825580601f10613628575050565b601f016020900490600052602060002090810190612d7e91906135f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561369957613699613646565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156136e6576136e6613646565b604052919050565b600067ffffffffffffffff82111561370857613708613646565b5060051b60200190565b600067ffffffffffffffff82111561372c5761372c613646565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600061376b61376684613712565b61369f565b905082815283838301111561377f57600080fd5b828260208301376000602084830101529392505050565b600060208083850312156137a957600080fd5b823567ffffffffffffffff808211156137c157600080fd5b818501915085601f8301126137d557600080fd5b81356137e3613766826136ee565b81815260059190911b8301840190848101908883111561380257600080fd5b8585015b8381101561384f5780358581111561381e5760008081fd5b8601603f81018b136138305760008081fd5b6138418b8983013560408401613758565b845250918601918601613806565b5098975050505050505050565b60ff81168114612d7e57600080fd5b63ffffffff81168114612d7e57600080fd5b600082601f83011261388e57600080fd5b61182083833560208501613758565b6bffffffffffffffffffffffff81168114612d7e57600080fd5b600080600080600080600060e0888a0312156138d257600080fd5b87356138dd8161385c565b965060208801356138ed8161386b565b955060408801356138fd8161385c565b9450606088013567ffffffffffffffff81111561391957600080fd5b6139258a828b0161387d565b94505060808801356139368161389d565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561396657600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b818110156139ad57835183529284019291840191600101613991565b50909695505050505050565b803561ffff811681146139cb57600080fd5b919050565b6000806000606084860312156139e557600080fd5b833592506139f5602085016139b9565b9150604084013590509250925092565b600060208284031215613a1757600080fd5b5035919050565b60005b83811015613a39578181015183820152602001613a21565b50506000910152565b60008151808452613a5a816020860160208601613a1e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006118206020830184613a42565b60008060408385031215613ab257600080fd5b82359150613ac2602084016139b9565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612d7e57600080fd5b600060208284031215613aff57600080fd5b813561182081613acb565b600080600060608486031215613b1f57600080fd5b505081359360208301359350604090920135919050565b60008083601f840112613b4857600080fd5b50813567ffffffffffffffff811115613b6057600080fd5b6020830191508360208260051b85010111156115eb57600080fd5b60008060208385031215613b8e57600080fd5b823567ffffffffffffffff811115613ba557600080fd5b613bb185828601613b36565b90969095509350505050565b60008083601f840112613bcf57600080fd5b50813567ffffffffffffffff811115613be757600080fd5b6020830191508360208285010111156115eb57600080fd5b60008060208385031215613c1257600080fd5b823567ffffffffffffffff811115613c2957600080fd5b613bb185828601613bbd565b60008060408385031215613c4857600080fd5b823567ffffffffffffffff80821115613c6057600080fd5b818501915085601f830112613c7457600080fd5b81356020613c84613766836136ee565b82815260059290921b84018101918181019089841115613ca357600080fd5b8286015b84811015613cdb57803586811115613cbf5760008081fd5b613ccd8c86838b010161387d565b845250918301918301613ca7565b5096505086013592505080821115613cf257600080fd5b50613cff8582860161387d565b9150509250929050565b821515815260406020820152600061181d6040830184613a42565b600080600060408486031215613d3957600080fd5b833567ffffffffffffffff811115613d5057600080fd5b613d5c86828701613b36565b9094509250506020840135613d708161386b565b809150509250925092565b600080600060408486031215613d9057600080fd5b83359250602084013567ffffffffffffffff811115613dae57600080fd5b613dba86828701613bbd565b9497909650939450505050565b60008060408385031215613dda57600080fd5b823591506020830135613dec8161389d565b809150509250929050565b60008060408385031215613e0a57600080fd5b823591506020830135613dec8161386b565b600060208284031215613e2e57600080fd5b81356118208161389d565b600060208284031215613e4b57600080fd5b81356118208161385c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff80831681851681830481118215151615613eb057613eb0613e56565b02949350505050565b805180151581146139cb57600080fd5b600060208284031215613edb57600080fd5b61182082613eb9565b600082601f830112613ef557600080fd5b8151613f0361376682613712565b818152846020838601011115613f1857600080fd5b613f29826020830160208701613a1e565b949350505050565b600060208284031215613f4357600080fd5b815167ffffffffffffffff811115613f5a57600080fd5b613f2984828501613ee4565b82815260406020820152600061181d6040830184613a42565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103613fc457613fc4613e56565b60010192915050565b818103818111156113c6576113c6613e56565b808201808211156113c6576113c6613e56565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361402457614024613e56565b5060010190565b8051602080830151919081101561406a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b80516139cb81613acb565b6000806040838503121561408e57600080fd5b825161409981613acb565b6020939093015192949293505050565b6000602082840312156140bb57600080fd5b815161182081613acb565b600061ffff8083168181036140dd576140dd613e56565b6001019392505050565b6000602082840312156140f957600080fd5b5051919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015614175577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552614163868351613a42565b95509382019390820190600101614129565b50508584038187015250505061418b8185613a42565b95945050505050565b600060208083850312156141a757600080fd5b825167ffffffffffffffff8111156141be57600080fd5b8301601f810185136141cf57600080fd5b80516141dd613766826136ee565b81815260059190911b820183019083810190878311156141fc57600080fd5b928401925b8284101561421a57835182529284019290840190614201565b979650505050505050565b60006020828403121561423757600080fd5b81516118208161385c565b600181811c9082168061425657607f821691505b60208210810361406a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b60a0815260006142a260a0830188613a42565b602083820381850152818854808452828401915060058382821b86010160008c8152858120815b8581101561439c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe089850301875282825461430481614242565b8087526001828116801561431f576001811461435657614385565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0084168d8a01528c8315158b1b8a01019450614385565b8688528c8820885b8481101561437d5781548f828d01015283820191508e8101905061435e565b8a018e019550505b50998b0199929650505091909101906001016142c9565b50505087810360408901526143b1818c613a42565b9550505050505084606084015282810360808401526143d08185613a42565b98975050505050505050565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b80516139cb8161386b565b80516139cb8161389d565b805167ffffffffffffffff811681146139cb57600080fd5b60006020828403121561447057600080fd5b815167ffffffffffffffff8082111561448857600080fd5b90830190610140828603121561449d57600080fd5b6144a5613675565b6144ae83614070565b81526144bc60208401614430565b60208201526040830151828111156144d357600080fd5b6144df87828601613ee4565b6040830152506144f16060840161443b565b606082015261450260808401614070565b608082015261451360a08401614446565b60a082015261452460c08401614430565b60c082015261453560e0840161443b565b60e0820152610100614548818501613eb9565b90820152610120838101518381111561456057600080fd5b61456c88828701613ee4565b918301919091525095945050505050565b60006020828403121561458f57600080fd5b81516118208161389d565b600063ffffffff8083168181036140dd576140dd613e56565b60208152600082516101408060208501526145d2610160850183613a42565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08086850301604087015261460e8483613a42565b935060408701519150614639606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e087015261469a8483613a42565b935060e087015191506101008187860301818801526146b98584613a42565b9450808801519250506101208187860301818801526146d88584613a42565b945080880151925050506146fb828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561473d5761473d613e56565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261478057614780614742565b500490565b818103600083128015838313168383128216171561351057613510613e56565b6000826147b4576147b4614742565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561480857614808613e56565b500590565b808201828112600083128015821682158216171561482d5761482d613e56565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361402457614024613e56565b60007f8000000000000000000000000000000000000000000000000000000000000000820361489757614897613e56565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b601f82111561493257600081815260208120601f850160051c810160208610156149135750805b601f850160051c820191505b818110156128265782815560010161491f565b505050565b815167ffffffffffffffff81111561495157614951613646565b6149658161495f8454614242565b846148ec565b602080601f8311600181146149b857600084156149825750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555612826565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015614a05578886015182559484019460019091019084016149e6565b5085821015614a4157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307835353533343434333264353535333434326434313532343234393534353235353464326435343435353335343465343535343030303030303030303030303030", } var VerifiableLoadMercuryUpkeepABI = VerifiableLoadMercuryUpkeepMetaData.ABI var VerifiableLoadMercuryUpkeepBin = VerifiableLoadMercuryUpkeepMetaData.Bin -func DeployVerifiableLoadMercuryUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, useArb bool) (common.Address, *types.Transaction, *VerifiableLoadMercuryUpkeep, error) { +func DeployVerifiableLoadMercuryUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, _useArb bool) (common.Address, *types.Transaction, *VerifiableLoadMercuryUpkeep, error) { parsed, err := VerifiableLoadMercuryUpkeepMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -48,7 +48,7 @@ func DeployVerifiableLoadMercuryUpkeep(auth *bind.TransactOpts, backend bind.Con return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadMercuryUpkeepBin), backend, _registrar, useArb) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadMercuryUpkeepBin), backend, _registrar, _useArb) if err != nil { return common.Address{}, nil, nil, err } @@ -1132,6 +1132,18 @@ func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession return _VerifiableLoadMercuryUpkeep.Contract.PerformUpkeep(&_VerifiableLoadMercuryUpkeep.TransactOpts, performData) } +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) SendLog(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "sendLog", upkeepId) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepSession) SendLog(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.SendLog(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactorSession) SendLog(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadMercuryUpkeep.Contract.SendLog(&_VerifiableLoadMercuryUpkeep.TransactOpts, upkeepId) +} + func (_VerifiableLoadMercuryUpkeep *VerifiableLoadMercuryUpkeepTransactor) SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { return _VerifiableLoadMercuryUpkeep.contract.Transact(opts, "setAddLinkAmount", amount) } @@ -2234,6 +2246,8 @@ type VerifiableLoadMercuryUpkeepInterface interface { PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) + SendLog(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) + SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) SetCheckGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go b/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go index 29edcdc0d9f..41d3ee1ff61 100644 --- a/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go +++ b/core/gethwrappers/generated/verifiable_load_upkeep_wrapper/verifiable_load_upkeep_wrapper.go @@ -31,15 +31,15 @@ var ( ) var VerifiableLoadUpkeepMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", - Bin: "0x60e06040527f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0523480156200005e57600080fd5b50604051620044f4380380620044f4833981016040819052620000819162000310565b81813380600081620000da5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156200010d576200010d816200024c565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa1580156200016a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000190919062000353565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620001f6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200021c919062000384565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a05250620003ab915050565b336001600160a01b03821603620002a65760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000d1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200030d57600080fd5b50565b600080604083850312156200032457600080fd5b82516200033181620002f7565b602084015190925080151581146200034857600080fd5b809150509250929050565b600080604083850312156200036757600080fd5b82516200037481620002f7565b6020939093015192949293505050565b6000602082840312156200039757600080fd5b8151620003a481620002f7565b9392505050565b60805160a05160c051614104620003f06000396000818161049901526118600152600081816107870152612c8f015260008181610ab101526112c601526141046000f3fe6080604052600436106103905760003560e01c8063776898c8116101dc578063a72aa27e11610102578063d6051a72116100a0578063e45530831161006f578063e455308314610d06578063f2fde38b14610d1c578063fba7ffa314610d3c578063fcdc1f6314610d6957600080fd5b8063d6051a7214610c79578063daee1aeb14610c99578063dbef701e14610cb9578063e0114adb14610cd957600080fd5b8063becde0e1116100dc578063becde0e114610b80578063c357f1f314610ba0578063c804802214610bfa578063d355852814610c1a57600080fd5b8063a72aa27e14610b13578063a79c404314610b33578063af953a4a14610b6057600080fd5b8063948108f71161017a5780639d385eaa116101495780639d385eaa14610a7f578063a654824814610a9f578063a6b5947514610ad3578063a6c60d8914610af357600080fd5b8063948108f7146109c55780639ac542eb146109e55780639b42935414610a215780639b51fb0d14610a4e57600080fd5b80637e7a46dc116101b65780637e7a46dc1461092d5780638da5cb5b1461094d5780638fcb3fba14610978578063924ca578146109a557600080fd5b8063776898c8146108cb57806379ba5097146108eb5780637b1039991461090057600080fd5b806346e7a63e116102c1578063636092e81161025f5780636e04ff0d1161022e5780636e04ff0d146108135780637145f11b1461084157806373644cce14610871578063767213031461089e57600080fd5b8063636092e814610733578063642f6cef1461077557806369cdbadb146107b957806369e9b773146107e657600080fd5b8063597109921161029b57806359710992146106bc5780635d4ee7f3146106d15780635f17e616146106e657806360457ff51461070657600080fd5b806346e7a63e1461064257806351c98be31461066f57806357970e931461068f57600080fd5b806328c4b57b1161032e578063328ffd1111610308578063328ffd11146105b55780633ebe8d6c146105e25780634585e33b1461060257806345d2ec171461062257600080fd5b806328c4b57b146105235780632a9032d3146105435780632b20e3971461056357600080fd5b80630d4a4fb11161036a5780630d4a4fb11461045a57806312c5502714610487578063206c32e8146104ce57806320e3dbd41461050357600080fd5b806306c1cc00146103d457806306e3b632146103f6578063077ac6211461042c57600080fd5b366103cf57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b3480156103e057600080fd5b506103f46103ef366004613359565b610d96565b005b34801561040257600080fd5b506104166104113660046133f5565b611152565b6040516104239190613417565b60405180910390f35b34801561043857600080fd5b5061044c610447366004613472565b611251565b604051908152602001610423565b34801561046657600080fd5b5061047a6104753660046134a7565b61128f565b604051610423919061352e565b34801561049357600080fd5b506104bb7f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff9091168152602001610423565b3480156104da57600080fd5b506104ee6104e9366004613541565b6113ac565b60408051928352602083019190915201610423565b34801561050f57600080fd5b506103f461051e36600461358f565b61142f565b34801561052f57600080fd5b5061044c61053e3660046135ac565b6115f9565b34801561054f57600080fd5b506103f461055e36600461361d565b611664565b34801561056f57600080fd5b506011546105909073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610423565b3480156105c157600080fd5b5061044c6105d03660046134a7565b60036020526000908152604090205481565b3480156105ee57600080fd5b5061044c6105fd3660046134a7565b6116fe565b34801561060e57600080fd5b506103f461061d3660046136a1565b611767565b34801561062e57600080fd5b5061041661063d366004613541565b611976565b34801561064e57600080fd5b5061044c61065d3660046134a7565b600a6020526000908152604090205481565b34801561067b57600080fd5b506103f461068a3660046136d7565b6119e5565b34801561069b57600080fd5b506012546105909073ffffffffffffffffffffffffffffffffffffffff1681565b3480156106c857600080fd5b506103f4611a89565b3480156106dd57600080fd5b506103f4611c74565b3480156106f257600080fd5b506103f46107013660046133f5565b611daf565b34801561071257600080fd5b5061044c6107213660046134a7565b60076020526000908152604090205481565b34801561073f57600080fd5b50601554610758906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610423565b34801561078157600080fd5b506107a97f000000000000000000000000000000000000000000000000000000000000000081565b6040519015158152602001610423565b3480156107c557600080fd5b5061044c6107d43660046134a7565b60086020526000908152604090205481565b3480156107f257600080fd5b506103f46108013660046133f5565b60009182526008602052604090912055565b34801561081f57600080fd5b5061083361082e3660046136a1565b611e7c565b60405161042392919061372e565b34801561084d57600080fd5b506107a961085c3660046134a7565b600b6020526000908152604090205460ff1681565b34801561087d57600080fd5b5061044c61088c3660046134a7565b6000908152600c602052604090205490565b3480156108aa57600080fd5b5061044c6108b93660046134a7565b60046020526000908152604090205481565b3480156108d757600080fd5b506107a96108e63660046134a7565b611fa9565b3480156108f757600080fd5b506103f4611ffb565b34801561090c57600080fd5b506013546105909073ffffffffffffffffffffffffffffffffffffffff1681565b34801561093957600080fd5b506103f4610948366004613749565b6120fd565b34801561095957600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610590565b34801561098457600080fd5b5061044c6109933660046134a7565b60056020526000908152604090205481565b3480156109b157600080fd5b506103f46109c03660046133f5565b61218e565b3480156109d157600080fd5b506103f46109e0366004613795565b6123d3565b3480156109f157600080fd5b50601554610a0f906c01000000000000000000000000900460ff1681565b60405160ff9091168152602001610423565b348015610a2d57600080fd5b506103f4610a3c3660046133f5565b60009182526009602052604090912055565b348015610a5a57600080fd5b506104bb610a693660046134a7565b600e6020526000908152604090205461ffff1681565b348015610a8b57600080fd5b50610416610a9a3660046134a7565b61251c565b348015610aab57600080fd5b5061044c7f000000000000000000000000000000000000000000000000000000000000000081565b348015610adf57600080fd5b506103f4610aee3660046135ac565b61257e565b348015610aff57600080fd5b506103f4610b0e3660046134a7565b601455565b348015610b1f57600080fd5b506103f4610b2e3660046137c5565b6125e7565b348015610b3f57600080fd5b506103f4610b4e3660046133f5565b60009182526007602052604090912055565b348015610b6c57600080fd5b506103f4610b7b3660046134a7565b612692565b348015610b8c57600080fd5b506103f4610b9b36600461361d565b612718565b348015610bac57600080fd5b506103f4610bbb3660046137ea565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610c0657600080fd5b506103f4610c153660046134a7565b6127b2565b348015610c2657600080fd5b506103f4610c35366004613807565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610c8557600080fd5b506104ee610c943660046133f5565b61284a565b348015610ca557600080fd5b506103f4610cb436600461361d565b6128b3565b348015610cc557600080fd5b5061044c610cd43660046133f5565b61297e565b348015610ce557600080fd5b5061044c610cf43660046134a7565b60096020526000908152604090205481565b348015610d1257600080fd5b5061044c60145481565b348015610d2857600080fd5b506103f4610d3736600461358f565b6129af565b348015610d4857600080fd5b5061044c610d573660046134a7565b60066020526000908152604090205481565b348015610d7557600080fd5b5061044c610d843660046134a7565b60026020526000908152604090205481565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610e7c908c1688613853565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610efa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1e9190613897565b5060008860ff1667ffffffffffffffff811115610f3d57610f3d6131fb565b604051908082528060200260200182016040528015610f66578160200160208202803683370190505b50905060005b8960ff168160ff16101561110f576000610f85846129c3565b90508860ff166001036110bd576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015610fea573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261103091908101906138ff565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906110899085908590600401613934565b600060405180830381600087803b1580156110a357600080fd5b505af11580156110b7573d6000803e3d6000fd5b50505050505b80838360ff16815181106110d3576110d361394d565b602090810291909101810191909152600091825260088152604080832088905560079091529020849055806111078161397c565b915050610f6c565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161113f9190613417565b60405180910390a1505050505050505050565b60606000611160600f612a91565b905080841061119b576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036111b0576111ad848261399b565b92505b60008367ffffffffffffffff8111156111cb576111cb6131fb565b6040519080825280602002602001820160405280156111f4578160200160208202803683370190505b50905060005b848110156112465761121761120f82886139ae565b600f90612a9b565b8282815181106112295761122961394d565b60209081029190910101528061123e816139c1565b9150506111fa565b509150505b92915050565b600d602052826000526040600020602052816000526040600020818154811061127957600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f00000000000000000000000000000000000000000000000000000000000000008152602001846040516020016112fd91815260200190565b604051602081830303815290604052611315906139f9565b81526020016000801b81526020016000801b8152509050806040516020016113959190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561141057602002820191906000526020600020905b8154815260200190600101908083116113fc575b50505050509050611422818251612aa7565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa1580156114c5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114e99190613a49565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa15801561158c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115b09190613a77565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c60209081526040808320805482518185028101850190935280835261165a9383018282801561164e57602002820191906000526020600020905b81548152602001906001019080831161163a575b50505050508484612b2c565b90505b9392505050565b8060005b818160ff1610156116f8573063c8048022858560ff851681811061168e5761168e61394d565b905060200201356040518263ffffffff1660e01b81526004016116b391815260200190565b600060405180830381600087803b1580156116cd57600080fd5b505af11580156116e1573d6000803e3d6000fd5b5050505080806116f09061397c565b915050611668565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff161161175f576000858152600d6020908152604080832061ffff8516845290915290205461174b90836139ae565b91508061175781613a94565b915050611714565b509392505050565b60005a9050600061177a83850185613ab5565b50600081815260056020908152604080832054600490925282205492935091906117a2612c8b565b9050826000036117c257600084815260056020526040902081905561191d565b6000848152600360205260408120546117db848461399b565b6117e5919061399b565b6000868152600e6020908152604080832054600d835281842061ffff90911680855290835281842080548351818602810186019094528084529596509094919290919083018282801561185757602002820191906000526020600020905b815481526020019060010190808311611843575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff168151036118d2578161189481613a94565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b6000848152600660205260408120546119379060016139ae565b6000868152600660209081526040808320849055600490915290208390559050611961858361218e565b61196c85878461257e565b5050505050505050565b6000828152600d6020908152604080832061ffff851684528252918290208054835181840281018401909452808452606093928301828280156119d857602002820191906000526020600020905b8154815260200190600101908083116119c4575b5050505050905092915050565b8160005b81811015611a825730635f17e616868684818110611a0957611a0961394d565b90506020020135856040518363ffffffff1660e01b8152600401611a3d92919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611a5757600080fd5b505af1158015611a6b573d6000803e3d6000fd5b505050508080611a7a906139c1565b9150506119e9565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611b00573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611b469190810190613afc565b80519091506000611b55612c8b565b905060005b828110156116f8576000848281518110611b7657611b7661394d565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c1a9190613ba2565b90508060ff16600103611c5f57604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611c6c906139c1565b915050611b5a565b611c7c612d2d565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611ceb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d0f9190613bbf565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611d87573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dab9190613897565b5050565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611de7916131a8565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611e43576000848152600d6020908152604080832061ffff851684529091528120611e31916131a8565b80611e3b81613a94565b915050611dfc565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a90506000611e93858701876134a7565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115611ecc57611ecc6131fb565b6040519080825280601f01601f191660200182016040528015611ef6576020820181803683370190505b50604051602001611f08929190613934565b60405160208183030381529060405290506000611f23612c8b565b90506000611f3086611fa9565b90505b835a611f3f908961399b565b611f4b906127106139ae565b1015611f995781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905581611f9181613bd8565b925050611f33565b9a91995090975050505050505050565b6000818152600560205260408120548103611fc657506001919050565b600082815260036020908152604080832054600490925290912054611fe9612c8b565b611ff3919061399b565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff163314612081576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b59061215790869086908690600401613c0d565b600060405180830381600087803b15801561217157600080fd5b505af1158015612185573d6000803e3d6000fd5b50505050505050565b6014546000838152600260205260409020546121aa908361399b565b1115611dab576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612220573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526122669190810190613c8f565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa1580156122db573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906122ff9190613dae565b6015549091506123239082906c01000000000000000000000000900460ff16613853565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff1610156116f8576015546123669085906bffffffffffffffffffffffff166123d3565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af115801561245b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061247f9190613897565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561250057600080fd5b505af1158015612514573d6000803e3d6000fd5b505050505050565b6000818152600c602090815260409182902080548351818402810184019094528084526060939283018282801561257257602002820191906000526020600020905b81548152602001906001019080831161255e575b50505050509050919050565b6000838152600760205260409020545b805a61259a908561399b565b6125a6906127106139ae565b10156116f85781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905561258e565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b15801561265f57600080fd5b505af1158015612673573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b15801561270457600080fd5b505af1158015611a82573d6000803e3d6000fd5b8060005b818163ffffffff1610156116f8573063af953a4a858563ffffffff85168181106127485761274861394d565b905060200201356040518263ffffffff1660e01b815260040161276d91815260200190565b600060405180830381600087803b15801561278757600080fd5b505af115801561279b573d6000803e3d6000fd5b5050505080806127aa90613dcb565b91505061271c565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561281e57600080fd5b505af1158015612832573d6000803e3d6000fd5b50505050611dab81600f612db090919063ffffffff16565b6000828152600c602090815260408083208054825181850281018501909352808352849384939291908301828280156128a257602002820191906000526020600020905b81548152602001906001019080831161288e575b505050505090506114228185612aa7565b8060005b818110156116f85760008484838181106128d3576128d361394d565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc828360405160200161290c91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b8152600401612938929190613934565b600060405180830381600087803b15801561295257600080fd5b505af1158015612966573d6000803e3d6000fd5b50505050508080612976906139c1565b9150506128b7565b600c602052816000526040600020818154811061299a57600080fd5b90600052602060002001600091509150505481565b6129b7612d2d565b6129c081612dbc565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612a1e908690600401613de4565b6020604051808303816000875af1158015612a3d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a619190613bbf565b9050612a6e600f82612eb1565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b600061124b825490565b600061165d8383612ebd565b815160009081908190841580612abd5750808510155b15612ac6578094505b60008092505b85831015612b2257866001612ae1858561399b565b612aeb919061399b565b81518110612afb57612afb61394d565b602002602001015181612b0e91906139ae565b905082612b1a816139c1565b935050612acc565b9694955050505050565b82516000908190831580612b405750808410155b15612b49578093505b60008467ffffffffffffffff811115612b6457612b646131fb565b604051908082528060200260200182016040528015612b8d578160200160208202803683370190505b509050600092505b84831015612bfb57866001612baa858561399b565b612bb4919061399b565b81518110612bc457612bc461394d565b6020026020010151818481518110612bde57612bde61394d565b602090810291909101015282612bf3816139c1565b935050612b95565b612c1481600060018451612c0f919061399b565b612ee7565b85606403612c4d578060018251612c2b919061399b565b81518110612c3b57612c3b61394d565b6020026020010151935050505061165d565b806064825188612c5d9190613f36565b612c679190613fa2565b81518110612c7757612c7761394d565b602002602001015193505050509392505050565b60007f000000000000000000000000000000000000000000000000000000000000000015612d2857606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612cff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d239190613bbf565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff163314612dae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401612078565b565b600061165d838361305f565b3373ffffffffffffffffffffffffffffffffffffffff821603612e3b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401612078565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600061165d8383613159565b6000826000018281548110612ed457612ed461394d565b9060005260206000200154905092915050565b8181808203612ef7575050505050565b6000856002612f068787613fb6565b612f109190613fd6565b612f1a908761403e565b81518110612f2a57612f2a61394d565b602002602001015190505b818313613039575b80868481518110612f5057612f5061394d565b60200260200101511015612f705782612f6881614066565b935050612f3d565b858281518110612f8257612f8261394d565b6020026020010151811015612fa35781612f9b81614097565b925050612f70565b81831361303457858281518110612fbc57612fbc61394d565b6020026020010151868481518110612fd657612fd661394d565b6020026020010151878581518110612ff057612ff061394d565b602002602001018885815181106130095761300961394d565b6020908102919091010191909152528261302281614066565b935050818061303090614097565b9250505b612f35565b8185121561304c5761304c868684612ee7565b8383121561251457612514868486612ee7565b6000818152600183016020526040812054801561314857600061308360018361399b565b85549091506000906130979060019061399b565b90508181146130fc5760008660000182815481106130b7576130b761394d565b90600052602060002001549050808760000184815481106130da576130da61394d565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061310d5761310d6140c8565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061124b565b600091505061124b565b5092915050565b60008181526001830160205260408120546131a05750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561124b565b50600061124b565b50805460008255906000526020600020908101906129c091905b808211156131d657600081556001016131c2565b5090565b60ff811681146129c057600080fd5b63ffffffff811681146129c057600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff8111828210171561324e5761324e6131fb565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561329b5761329b6131fb565b604052919050565b600067ffffffffffffffff8211156132bd576132bd6131fb565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f8301126132fa57600080fd5b813561330d613308826132a3565b613254565b81815284602083860101111561332257600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129c057600080fd5b600080600080600080600060e0888a03121561337457600080fd5b873561337f816131da565b9650602088013561338f816131e9565b9550604088013561339f816131da565b9450606088013567ffffffffffffffff8111156133bb57600080fd5b6133c78a828b016132e9565b94505060808801356133d88161333f565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561340857600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b8181101561344f57835183529284019291840191600101613433565b50909695505050505050565b803561ffff8116811461346d57600080fd5b919050565b60008060006060848603121561348757600080fd5b833592506134976020850161345b565b9150604084013590509250925092565b6000602082840312156134b957600080fd5b5035919050565b60005b838110156134db5781810151838201526020016134c3565b50506000910152565b600081518084526134fc8160208601602086016134c0565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061165d60208301846134e4565b6000806040838503121561355457600080fd5b823591506135646020840161345b565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff811681146129c057600080fd5b6000602082840312156135a157600080fd5b813561165d8161356d565b6000806000606084860312156135c157600080fd5b505081359360208301359350604090920135919050565b60008083601f8401126135ea57600080fd5b50813567ffffffffffffffff81111561360257600080fd5b6020830191508360208260051b850101111561142857600080fd5b6000806020838503121561363057600080fd5b823567ffffffffffffffff81111561364757600080fd5b613653858286016135d8565b90969095509350505050565b60008083601f84011261367157600080fd5b50813567ffffffffffffffff81111561368957600080fd5b60208301915083602082850101111561142857600080fd5b600080602083850312156136b457600080fd5b823567ffffffffffffffff8111156136cb57600080fd5b6136538582860161365f565b6000806000604084860312156136ec57600080fd5b833567ffffffffffffffff81111561370357600080fd5b61370f868287016135d8565b9094509250506020840135613723816131e9565b809150509250925092565b821515815260406020820152600061165a60408301846134e4565b60008060006040848603121561375e57600080fd5b83359250602084013567ffffffffffffffff81111561377c57600080fd5b6137888682870161365f565b9497909650939450505050565b600080604083850312156137a857600080fd5b8235915060208301356137ba8161333f565b809150509250929050565b600080604083850312156137d857600080fd5b8235915060208301356137ba816131e9565b6000602082840312156137fc57600080fd5b813561165d8161333f565b60006020828403121561381957600080fd5b813561165d816131da565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff8083168185168183048111821515161561387e5761387e613824565b02949350505050565b8051801515811461346d57600080fd5b6000602082840312156138a957600080fd5b61165d82613887565b600082601f8301126138c357600080fd5b81516138d1613308826132a3565b8181528460208386010111156138e657600080fd5b6138f78260208301602087016134c0565b949350505050565b60006020828403121561391157600080fd5b815167ffffffffffffffff81111561392857600080fd5b6138f7848285016138b2565b82815260406020820152600061165a60408301846134e4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361399257613992613824565b60010192915050565b8181038181111561124b5761124b613824565b8082018082111561124b5761124b613824565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f2576139f2613824565b5060010190565b80516020808301519190811015613a38577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805161346d8161356d565b60008060408385031215613a5c57600080fd5b8251613a678161356d565b6020939093015192949293505050565b600060208284031215613a8957600080fd5b815161165d8161356d565b600061ffff808316818103613aab57613aab613824565b6001019392505050565b60008060408385031215613ac857600080fd5b82359150602083013567ffffffffffffffff811115613ae657600080fd5b613af2858286016132e9565b9150509250929050565b60006020808385031215613b0f57600080fd5b825167ffffffffffffffff80821115613b2757600080fd5b818501915085601f830112613b3b57600080fd5b815181811115613b4d57613b4d6131fb565b8060051b9150613b5e848301613254565b8181529183018401918481019088841115613b7857600080fd5b938501935b83851015613b9657845182529385019390850190613b7d565b98975050505050505050565b600060208284031215613bb457600080fd5b815161165d816131da565b600060208284031215613bd157600080fd5b5051919050565b600081613be757613be7613824565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b805161346d816131e9565b805161346d8161333f565b805167ffffffffffffffff8116811461346d57600080fd5b600060208284031215613ca157600080fd5b815167ffffffffffffffff80821115613cb957600080fd5b908301906101408286031215613cce57600080fd5b613cd661322a565b613cdf83613a3e565b8152613ced60208401613c61565b6020820152604083015182811115613d0457600080fd5b613d10878286016138b2565b604083015250613d2260608401613c6c565b6060820152613d3360808401613a3e565b6080820152613d4460a08401613c77565b60a0820152613d5560c08401613c61565b60c0820152613d6660e08401613c6c565b60e0820152610100613d79818501613887565b908201526101208381015183811115613d9157600080fd5b613d9d888287016138b2565b918301919091525095945050505050565b600060208284031215613dc057600080fd5b815161165d8161333f565b600063ffffffff808316818103613aab57613aab613824565b6020815260008251610140806020850152613e036101608501836134e4565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe080868503016040870152613e3f84836134e4565b935060408701519150613e6a606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e0870152613ecb84836134e4565b935060e08701519150610100818786030181880152613eea85846134e4565b945080880151925050610120818786030181880152613f0985846134e4565b94508088015192505050613f2c828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613f6e57613f6e613824565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600082613fb157613fb1613f73565b500490565b818103600083128015838313168383128216171561315257613152613824565b600082613fe557613fe5613f73565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f80000000000000000000000000000000000000000000000000000000000000008314161561403957614039613824565b500590565b808201828112600083128015821682158216171561405e5761405e613824565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036139f2576139f2613824565b60007f80000000000000000000000000000000000000000000000000000000000000008203613be757613be7613824565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"_registrar\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"_useArb\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"}],\"name\":\"LogEmitted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Received\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"UpkeepTopUp\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"UpkeepsRegistered\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BUCKET_SIZE\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"addLinkAmount\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchCancelUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"number\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"checkGasToBurn\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"performGasToBurn\",\"type\":\"uint256\"}],\"name\":\"batchRegisterUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"batchSendLogs\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"},{\"internalType\":\"uint32\",\"name\":\"interval\",\"type\":\"uint32\"}],\"name\":\"batchSetIntervals\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchUpdatePipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"upkeepIds\",\"type\":\"uint256[]\"}],\"name\":\"batchWithdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"bucketedDelays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"buckets\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"burnPerformGas\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"checkGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"counters\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"delays\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"dummyMap\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emittedSig\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"firstPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"gasLimits\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getBucketedDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getBucketedDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelays\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getDelaysLength\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"p\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getPxDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"bucket\",\"type\":\"uint16\"}],\"name\":\"getSumDelayInBucket\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getSumDelayLastNPerforms\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"intervals\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"lastTopUpBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"minBalanceThresholdMultiplier\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performDataSizes\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"performGasToBurns\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"previousPerformBlocks\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registrar\",\"outputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"registry\",\"outputs\":[{\"internalType\":\"contractIKeeperRegistryMaster\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"sendLog\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"setAddLinkAmount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setCheckGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAutomationRegistrar2_1\",\"name\":\"newRegistrar\",\"type\":\"address\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"}],\"name\":\"setInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"newMinBalanceThresholdMultiplier\",\"type\":\"uint8\"}],\"name\":\"setMinBalanceThresholdMultiplier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformDataSize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"setPerformGasToBurn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"newInterval\",\"type\":\"uint256\"}],\"name\":\"setUpkeepTopUpCheckInterval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"topUpFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"pipelineData\",\"type\":\"bytes\"}],\"name\":\"updateUpkeepPipelineData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTopUpCheckInterval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"withdrawLinks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"stateMutability\":\"payable\",\"type\":\"receive\"}]", + Bin: "0x60e06040527f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf086080526005601455601580546001600160681b0319166c140000000002c68af0bb140000179055606460c0523480156200005e57600080fd5b506040516200456738038062004567833981016040819052620000819162000310565b81813380600081620000da5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156200010d576200010d816200024c565b5050601180546001600160a01b0319166001600160a01b038516908117909155604080516330fe427560e21b815281516000945063c3f909d4926004808401939192918290030181865afa1580156200016a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000190919062000353565b50601380546001600160a01b0319166001600160a01b038381169190911790915560115460408051631b6b6d2360e01b81529051939450911691631b6b6d23916004808201926020929091908290030181865afa158015620001f6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200021c919062000384565b601280546001600160a01b0319166001600160a01b039290921691909117905550151560a05250620003ab915050565b336001600160a01b03821603620002a65760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000d1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b03811681146200030d57600080fd5b50565b600080604083850312156200032457600080fd5b82516200033181620002f7565b602084015190925080151581146200034857600080fd5b809150509250929050565b600080604083850312156200036757600080fd5b82516200037481620002f7565b6020939093015192949293505050565b6000602082840312156200039757600080fd5b8151620003a481620002f7565b9392505050565b60805160a05160c051614177620003f0600039600081816104c401526118d30152600081816107b20152612b1e015260008181610adc01526112f101526141776000f3fe60806040526004361061039b5760003560e01c8063776898c8116101dc578063a72aa27e11610102578063d6051a72116100a0578063e45530831161006f578063e455308314610d31578063f2fde38b14610d47578063fba7ffa314610d67578063fcdc1f6314610d9457600080fd5b8063d6051a7214610ca4578063daee1aeb14610cc4578063dbef701e14610ce4578063e0114adb14610d0457600080fd5b8063becde0e1116100dc578063becde0e114610bab578063c357f1f314610bcb578063c804802214610c25578063d355852814610c4557600080fd5b8063a72aa27e14610b3e578063a79c404314610b5e578063af953a4a14610b8b57600080fd5b8063948108f71161017a5780639d385eaa116101495780639d385eaa14610aaa578063a654824814610aca578063a6b5947514610afe578063a6c60d8914610b1e57600080fd5b8063948108f7146109f05780639ac542eb14610a105780639b42935414610a4c5780639b51fb0d14610a7957600080fd5b80637e7a46dc116101b65780637e7a46dc146109585780638da5cb5b146109785780638fcb3fba146109a3578063924ca578146109d057600080fd5b8063776898c8146108f657806379ba5097146109165780637b1039991461092b57600080fd5b806346e7a63e116102c1578063636092e81161025f5780636e04ff0d1161022e5780636e04ff0d1461083e5780637145f11b1461086c57806373644cce1461089c57806376721303146108c957600080fd5b8063636092e81461075e578063642f6cef146107a057806369cdbadb146107e457806369e9b7731461081157600080fd5b8063597109921161029b57806359710992146106e75780635d4ee7f3146106fc5780635f17e6161461071157806360457ff51461073157600080fd5b806346e7a63e1461066d57806351c98be31461069a57806357970e93146106ba57600080fd5b806320e3dbd411610339578063328ffd1111610308578063328ffd11146105e05780633ebe8d6c1461060d5780634585e33b1461062d57806345d2ec171461064d57600080fd5b806320e3dbd41461052e57806328c4b57b1461054e5780632a9032d31461056e5780632b20e3971461058e57600080fd5b80630d4a4fb1116103755780630d4a4fb1146104655780630e577d421461049257806312c55027146104b2578063206c32e8146104f957600080fd5b806306c1cc00146103df57806306e3b63214610401578063077ac6211461043757600080fd5b366103da57604080513381523460208201527f88a5966d370b9919b20f3e2c13ff65706f196a4e32cc2c12bf57088f88525874910160405180910390a1005b600080fd5b3480156103eb57600080fd5b506103ff6103fa3660046133cc565b610dc1565b005b34801561040d57600080fd5b5061042161041c366004613468565b61117d565b60405161042e919061348a565b60405180910390f35b34801561044357600080fd5b506104576104523660046134e5565b61127c565b60405190815260200161042e565b34801561047157600080fd5b5061048561048036600461351a565b6112ba565b60405161042e91906135a1565b34801561049e57600080fd5b506103ff6104ad36600461351a565b6113d7565b3480156104be57600080fd5b506104e67f000000000000000000000000000000000000000000000000000000000000000081565b60405161ffff909116815260200161042e565b34801561050557600080fd5b506105196105143660046135b4565b61141f565b6040805192835260208301919091520161042e565b34801561053a57600080fd5b506103ff610549366004613602565b6114a2565b34801561055a57600080fd5b5061045761056936600461361f565b61166c565b34801561057a57600080fd5b506103ff610589366004613690565b6116d7565b34801561059a57600080fd5b506011546105bb9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161042e565b3480156105ec57600080fd5b506104576105fb36600461351a565b60036020526000908152604090205481565b34801561061957600080fd5b5061045761062836600461351a565b611771565b34801561063957600080fd5b506103ff610648366004613714565b6117da565b34801561065957600080fd5b506104216106683660046135b4565b6119e9565b34801561067957600080fd5b5061045761068836600461351a565b600a6020526000908152604090205481565b3480156106a657600080fd5b506103ff6106b536600461374a565b611a58565b3480156106c657600080fd5b506012546105bb9073ffffffffffffffffffffffffffffffffffffffff1681565b3480156106f357600080fd5b506103ff611afc565b34801561070857600080fd5b506103ff611ce7565b34801561071d57600080fd5b506103ff61072c366004613468565b611e22565b34801561073d57600080fd5b5061045761074c36600461351a565b60076020526000908152604090205481565b34801561076a57600080fd5b50601554610783906bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff909116815260200161042e565b3480156107ac57600080fd5b506107d47f000000000000000000000000000000000000000000000000000000000000000081565b604051901515815260200161042e565b3480156107f057600080fd5b506104576107ff36600461351a565b60086020526000908152604090205481565b34801561081d57600080fd5b506103ff61082c366004613468565b60009182526008602052604090912055565b34801561084a57600080fd5b5061085e610859366004613714565b611eef565b60405161042e9291906137a1565b34801561087857600080fd5b506107d461088736600461351a565b600b6020526000908152604090205460ff1681565b3480156108a857600080fd5b506104576108b736600461351a565b6000908152600c602052604090205490565b3480156108d557600080fd5b506104576108e436600461351a565b60046020526000908152604090205481565b34801561090257600080fd5b506107d461091136600461351a565b61201c565b34801561092257600080fd5b506103ff61206e565b34801561093757600080fd5b506013546105bb9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561096457600080fd5b506103ff6109733660046137bc565b612170565b34801561098457600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff166105bb565b3480156109af57600080fd5b506104576109be36600461351a565b60056020526000908152604090205481565b3480156109dc57600080fd5b506103ff6109eb366004613468565b612201565b3480156109fc57600080fd5b506103ff610a0b366004613808565b612446565b348015610a1c57600080fd5b50601554610a3a906c01000000000000000000000000900460ff1681565b60405160ff909116815260200161042e565b348015610a5857600080fd5b506103ff610a67366004613468565b60009182526009602052604090912055565b348015610a8557600080fd5b506104e6610a9436600461351a565b600e6020526000908152604090205461ffff1681565b348015610ab657600080fd5b50610421610ac536600461351a565b61258f565b348015610ad657600080fd5b506104577f000000000000000000000000000000000000000000000000000000000000000081565b348015610b0a57600080fd5b506103ff610b1936600461361f565b6125f1565b348015610b2a57600080fd5b506103ff610b3936600461351a565b601455565b348015610b4a57600080fd5b506103ff610b59366004613838565b61265a565b348015610b6a57600080fd5b506103ff610b79366004613468565b60009182526007602052604090912055565b348015610b9757600080fd5b506103ff610ba636600461351a565b612705565b348015610bb757600080fd5b506103ff610bc6366004613690565b61278b565b348015610bd757600080fd5b506103ff610be636600461385d565b601580547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff92909216919091179055565b348015610c3157600080fd5b506103ff610c4036600461351a565b612825565b348015610c5157600080fd5b506103ff610c6036600461387a565b6015805460ff9092166c01000000000000000000000000027fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff909216919091179055565b348015610cb057600080fd5b50610519610cbf366004613468565b6128bd565b348015610cd057600080fd5b506103ff610cdf366004613690565b612926565b348015610cf057600080fd5b50610457610cff366004613468565b6129f1565b348015610d1057600080fd5b50610457610d1f36600461351a565b60096020526000908152604090205481565b348015610d3d57600080fd5b5061045760145481565b348015610d5357600080fd5b506103ff610d62366004613602565b612a22565b348015610d7357600080fd5b50610457610d8236600461351a565b60066020526000908152604090205481565b348015610da057600080fd5b50610457610daf36600461351a565b60026020526000908152604090205481565b6040805161018081018252600461014082019081527f746573740000000000000000000000000000000000000000000000000000000061016083015281528151602081810184526000808352818401929092523083850181905263ffffffff8b166060850152608084015260ff808a1660a08501528451808301865283815260c085015260e0840189905284519182019094529081526101008201526bffffffffffffffffffffffff8516610120820152601254601154919273ffffffffffffffffffffffffffffffffffffffff9182169263095ea7b3921690610ea7908c16886138c6565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526bffffffffffffffffffffffff1660248201526044016020604051808303816000875af1158015610f25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f49919061390a565b5060008860ff1667ffffffffffffffff811115610f6857610f6861326e565b604051908082528060200260200182016040528015610f91578160200160208202803683370190505b50905060005b8960ff168160ff16101561113a576000610fb084612a36565b90508860ff166001036110e8576040517f0d4a4fb1000000000000000000000000000000000000000000000000000000008152600481018290526000903090630d4a4fb190602401600060405180830381865afa158015611015573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261105b9190810190613972565b6013546040517f4ee88d3500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff1690634ee88d35906110b490859085906004016139a7565b600060405180830381600087803b1580156110ce57600080fd5b505af11580156110e2573d6000803e3d6000fd5b50505050505b80838360ff16815181106110fe576110fe6139c0565b60209081029190910181019190915260009182526008815260408083208890556007909152902084905580611132816139ef565b915050610f97565b507f2ee10f7eb180441fb9fbba75b10c0162b5390b557712c93426243ca8f383c7118160405161116a919061348a565b60405180910390a1505050505050505050565b6060600061118b600f612b04565b90508084106111c6576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826000036111db576111d88482613a0e565b92505b60008367ffffffffffffffff8111156111f6576111f661326e565b60405190808252806020026020018201604052801561121f578160200160208202803683370190505b50905060005b848110156112715761124261123a8288613a21565b600f90612b0e565b828281518110611254576112546139c0565b60209081029190910101528061126981613a34565b915050611225565b509150505b92915050565b600d60205282600052604060002060205281600052604060002081815481106112a457600080fd5b9060005260206000200160009250925050505481565b606060006040518060c001604052803073ffffffffffffffffffffffffffffffffffffffff168152602001600160ff1681526020017f000000000000000000000000000000000000000000000000000000000000000081526020018460405160200161132891815260200190565b60405160208183030381529060405261134090613a6c565b81526020016000801b81526020016000801b8152509050806040516020016113c09190600060c08201905073ffffffffffffffffffffffffffffffffffffffff835116825260ff602084015116602083015260408301516040830152606083015160608301526080830151608083015260a083015160a083015292915050565b604051602081830303815290604052915050919050565b60006113e1612b1a565b604051308152909150819083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35050565b6000828152600d6020908152604080832061ffff85168452825280832080548251818502810185019093528083528493849392919083018282801561148357602002820191906000526020600020905b81548152602001906001019080831161146f575b50505050509050611495818251612bbc565b92509250505b9250929050565b601180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8316908117909155604080517fc3f909d400000000000000000000000000000000000000000000000000000000815281516000939263c3f909d492600480820193918290030181865afa158015611538573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061155c9190613abc565b50601380547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691909117909155601154604080517f1b6b6d230000000000000000000000000000000000000000000000000000000081529051939450911691631b6b6d23916004808201926020929091908290030181865afa1580156115ff573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116239190613aea565b601280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff929092169190911790555050565b6000838152600c6020908152604080832080548251818502810185019093528083526116cd938301828280156116c157602002820191906000526020600020905b8154815260200190600101908083116116ad575b50505050508484612c41565b90505b9392505050565b8060005b818160ff16101561176b573063c8048022858560ff8516818110611701576117016139c0565b905060200201356040518263ffffffff1660e01b815260040161172691815260200190565b600060405180830381600087803b15801561174057600080fd5b505af1158015611754573d6000803e3d6000fd5b505050508080611763906139ef565b9150506116db565b50505050565b6000818152600e602052604081205461ffff1681805b8261ffff168161ffff16116117d2576000858152600d6020908152604080832061ffff851684529091529020546117be9083613a21565b9150806117ca81613b07565b915050611787565b509392505050565b60005a905060006117ed83850185613b28565b5060008181526005602090815260408083205460049092528220549293509190611815612b1a565b905082600003611835576000848152600560205260409020819055611990565b60008481526003602052604081205461184e8484613a0e565b6118589190613a0e565b6000868152600e6020908152604080832054600d835281842061ffff9091168085529083528184208054835181860281018601909452808452959650909491929091908301828280156118ca57602002820191906000526020600020905b8154815260200190600101908083116118b6575b505050505090507f000000000000000000000000000000000000000000000000000000000000000061ffff16815103611945578161190781613b07565b6000898152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff83161790559250505b506000868152600d6020908152604080832061ffff909416835292815282822080546001818101835591845282842001859055888352600c8252928220805493840181558252902001555b6000848152600660205260408120546119aa906001613a21565b60008681526006602090815260408083208490556004909152902083905590506119d48583612201565b6119df8587846125f1565b5050505050505050565b6000828152600d6020908152604080832061ffff85168452825291829020805483518184028101840190945280845260609392830182828015611a4b57602002820191906000526020600020905b815481526020019060010190808311611a37575b5050505050905092915050565b8160005b81811015611af55730635f17e616868684818110611a7c57611a7c6139c0565b90506020020135856040518363ffffffff1660e01b8152600401611ab092919091825263ffffffff16602082015260400190565b600060405180830381600087803b158015611aca57600080fd5b505af1158015611ade573d6000803e3d6000fd5b505050508080611aed90613a34565b915050611a5c565b5050505050565b6013546040517f06e3b632000000000000000000000000000000000000000000000000000000008152600060048201819052602482018190529173ffffffffffffffffffffffffffffffffffffffff16906306e3b63290604401600060405180830381865afa158015611b73573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052611bb99190810190613b6f565b80519091506000611bc8612b1a565b905060005b8281101561176b576000848281518110611be957611be96139c0565b60209081029190910101516013546040517f5147cd590000000000000000000000000000000000000000000000000000000081526004810183905291925060009173ffffffffffffffffffffffffffffffffffffffff90911690635147cd5990602401602060405180830381865afa158015611c69573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c8d9190613c15565b90508060ff16600103611cd257604051308152849083907f97009585a4d2440f981ab6f6eec514343e1e6b2aa9b991a26998e6806f41bf089060200160405180910390a35b50508080611cdf90613a34565b915050611bcd565b611cef612da0565b6012546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611d5e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d829190613c32565b6012546040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526024810183905291925073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044016020604051808303816000875af1158015611dfa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e1e919061390a565b5050565b60008281526003602090815260408083208490556005825280832083905560068252808320839055600c9091528120611e5a9161321b565b6000828152600e602052604081205461ffff16905b8161ffff168161ffff1611611eb6576000848152600d6020908152604080832061ffff851684529091528120611ea49161321b565b80611eae81613b07565b915050611e6f565b5050506000908152600e6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169055565b6000606060005a90506000611f068587018761351a565b60008181526009602090815260408083205460089092528220549293509190838367ffffffffffffffff811115611f3f57611f3f61326e565b6040519080825280601f01601f191660200182016040528015611f69576020820181803683370190505b50604051602001611f7b9291906139a7565b60405160208183030381529060405290506000611f96612b1a565b90506000611fa38661201c565b90505b835a611fb29089613a0e565b611fbe90612710613a21565b101561200c5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690558161200481613c4b565b925050611fa6565b9a91995090975050505050505050565b600081815260056020526040812054810361203957506001919050565b60008281526003602090815260408083205460049092529091205461205c612b1a565b6120669190613a0e565b101592915050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146120f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6013546040517fcd7f71b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063cd7f71b5906121ca90869086908690600401613c80565b600060405180830381600087803b1580156121e457600080fd5b505af11580156121f8573d6000803e3d6000fd5b50505050505050565b60145460008381526002602052604090205461221d9083613a0e565b1115611e1e576013546040517fc7c3a19a0000000000000000000000000000000000000000000000000000000081526004810184905260009173ffffffffffffffffffffffffffffffffffffffff169063c7c3a19a90602401600060405180830381865afa158015612293573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526122d99190810190613d02565b6013546040517fb657bc9c0000000000000000000000000000000000000000000000000000000081526004810186905291925060009173ffffffffffffffffffffffffffffffffffffffff9091169063b657bc9c90602401602060405180830381865afa15801561234e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123729190613e21565b6015549091506123969082906c01000000000000000000000000900460ff166138c6565b6bffffffffffffffffffffffff1682606001516bffffffffffffffffffffffff16101561176b576015546123d99085906bffffffffffffffffffffffff16612446565b60008481526002602090815260409182902085905560155482518781526bffffffffffffffffffffffff909116918101919091529081018490527f49d4100ab0124eb4a9a65dc4ea08d6412a43f6f05c49194983f5b322bcc0a5c09060600160405180910390a150505050565b6012546013546040517f095ea7b300000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff91821660048201526bffffffffffffffffffffffff8416602482015291169063095ea7b3906044016020604051808303816000875af11580156124ce573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124f2919061390a565b506013546040517f948108f7000000000000000000000000000000000000000000000000000000008152600481018490526bffffffffffffffffffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063948108f790604401600060405180830381600087803b15801561257357600080fd5b505af1158015612587573d6000803e3d6000fd5b505050505050565b6000818152600c60209081526040918290208054835181840281018401909452808452606093928301828280156125e557602002820191906000526020600020905b8154815260200190600101908083116125d1575b50505050509050919050565b6000838152600760205260409020545b805a61260d9085613a0e565b61261990612710613a21565b101561176b5781406000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055612601565b6013546040517fa72aa27e0000000000000000000000000000000000000000000000000000000081526004810184905263ffffffff8316602482015273ffffffffffffffffffffffffffffffffffffffff9091169063a72aa27e90604401600060405180830381600087803b1580156126d257600080fd5b505af11580156126e6573d6000803e3d6000fd5b505050600092835250600a602052604090912063ffffffff9091169055565b6013546040517f744bfe610000000000000000000000000000000000000000000000000000000081526004810183905230602482015273ffffffffffffffffffffffffffffffffffffffff9091169063744bfe6190604401600060405180830381600087803b15801561277757600080fd5b505af1158015611af5573d6000803e3d6000fd5b8060005b818163ffffffff16101561176b573063af953a4a858563ffffffff85168181106127bb576127bb6139c0565b905060200201356040518263ffffffff1660e01b81526004016127e091815260200190565b600060405180830381600087803b1580156127fa57600080fd5b505af115801561280e573d6000803e3d6000fd5b50505050808061281d90613e3e565b91505061278f565b6013546040517fc80480220000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff9091169063c804802290602401600060405180830381600087803b15801561289157600080fd5b505af11580156128a5573d6000803e3d6000fd5b50505050611e1e81600f612e2390919063ffffffff16565b6000828152600c6020908152604080832080548251818502810185019093528083528493849392919083018282801561291557602002820191906000526020600020905b815481526020019060010190808311612901575b505050505090506114958185612bbc565b8060005b8181101561176b576000848483818110612946576129466139c0565b9050602002013590503073ffffffffffffffffffffffffffffffffffffffff16637e7a46dc828360405160200161297f91815260200190565b6040516020818303038152906040526040518363ffffffff1660e01b81526004016129ab9291906139a7565b600060405180830381600087803b1580156129c557600080fd5b505af11580156129d9573d6000803e3d6000fd5b505050505080806129e990613a34565b91505061292a565b600c6020528160005260406000208181548110612a0d57600080fd5b90600052602060002001600091509150505481565b612a2a612da0565b612a3381612e2f565b50565b6011546040517f3f678e11000000000000000000000000000000000000000000000000000000008152600091829173ffffffffffffffffffffffffffffffffffffffff90911690633f678e1190612a91908690600401613e57565b6020604051808303816000875af1158015612ab0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ad49190613c32565b9050612ae1600f82612f24565b506060909201516000838152600a6020526040902063ffffffff90911690555090565b6000611276825490565b60006116d08383612f30565b60007f000000000000000000000000000000000000000000000000000000000000000015612bb757606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612b8e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bb29190613c32565b905090565b504390565b815160009081908190841580612bd25750808510155b15612bdb578094505b60008092505b85831015612c3757866001612bf68585613a0e565b612c009190613a0e565b81518110612c1057612c106139c0565b602002602001015181612c239190613a21565b905082612c2f81613a34565b935050612be1565b9694955050505050565b82516000908190831580612c555750808410155b15612c5e578093505b60008467ffffffffffffffff811115612c7957612c7961326e565b604051908082528060200260200182016040528015612ca2578160200160208202803683370190505b509050600092505b84831015612d1057866001612cbf8585613a0e565b612cc99190613a0e565b81518110612cd957612cd96139c0565b6020026020010151818481518110612cf357612cf36139c0565b602090810291909101015282612d0881613a34565b935050612caa565b612d2981600060018451612d249190613a0e565b612f5a565b85606403612d62578060018251612d409190613a0e565b81518110612d5057612d506139c0565b602002602001015193505050506116d0565b806064825188612d729190613fa9565b612d7c9190614015565b81518110612d8c57612d8c6139c0565b602002602001015193505050509392505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314612e21576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016120eb565b565b60006116d083836130d2565b3373ffffffffffffffffffffffffffffffffffffffff821603612eae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016120eb565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006116d083836131cc565b6000826000018281548110612f4757612f476139c0565b9060005260206000200154905092915050565b8181808203612f6a575050505050565b6000856002612f798787614029565b612f839190614049565b612f8d90876140b1565b81518110612f9d57612f9d6139c0565b602002602001015190505b8183136130ac575b80868481518110612fc357612fc36139c0565b60200260200101511015612fe35782612fdb816140d9565b935050612fb0565b858281518110612ff557612ff56139c0565b6020026020010151811015613016578161300e8161410a565b925050612fe3565b8183136130a75785828151811061302f5761302f6139c0565b6020026020010151868481518110613049576130496139c0565b6020026020010151878581518110613063576130636139c0565b6020026020010188858151811061307c5761307c6139c0565b60209081029190910101919091525282613095816140d9565b93505081806130a39061410a565b9250505b612fa8565b818512156130bf576130bf868684612f5a565b8383121561258757612587868486612f5a565b600081815260018301602052604081205480156131bb5760006130f6600183613a0e565b855490915060009061310a90600190613a0e565b905081811461316f57600086600001828154811061312a5761312a6139c0565b906000526020600020015490508087600001848154811061314d5761314d6139c0565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806131805761318061413b565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050611276565b6000915050611276565b5092915050565b600081815260018301602052604081205461321357508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155611276565b506000611276565b5080546000825590600052602060002090810190612a3391905b808211156132495760008155600101613235565b5090565b60ff81168114612a3357600080fd5b63ffffffff81168114612a3357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610140810167ffffffffffffffff811182821017156132c1576132c161326e565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561330e5761330e61326e565b604052919050565b600067ffffffffffffffff8211156133305761333061326e565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f83011261336d57600080fd5b813561338061337b82613316565b6132c7565b81815284602083860101111561339557600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612a3357600080fd5b600080600080600080600060e0888a0312156133e757600080fd5b87356133f28161324d565b965060208801356134028161325c565b955060408801356134128161324d565b9450606088013567ffffffffffffffff81111561342e57600080fd5b61343a8a828b0161335c565b945050608088013561344b816133b2565b9699959850939692959460a0840135945060c09093013592915050565b6000806040838503121561347b57600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b818110156134c2578351835292840192918401916001016134a6565b50909695505050505050565b803561ffff811681146134e057600080fd5b919050565b6000806000606084860312156134fa57600080fd5b8335925061350a602085016134ce565b9150604084013590509250925092565b60006020828403121561352c57600080fd5b5035919050565b60005b8381101561354e578181015183820152602001613536565b50506000910152565b6000815180845261356f816020860160208601613533565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006116d06020830184613557565b600080604083850312156135c757600080fd5b823591506135d7602084016134ce565b90509250929050565b73ffffffffffffffffffffffffffffffffffffffff81168114612a3357600080fd5b60006020828403121561361457600080fd5b81356116d0816135e0565b60008060006060848603121561363457600080fd5b505081359360208301359350604090920135919050565b60008083601f84011261365d57600080fd5b50813567ffffffffffffffff81111561367557600080fd5b6020830191508360208260051b850101111561149b57600080fd5b600080602083850312156136a357600080fd5b823567ffffffffffffffff8111156136ba57600080fd5b6136c68582860161364b565b90969095509350505050565b60008083601f8401126136e457600080fd5b50813567ffffffffffffffff8111156136fc57600080fd5b60208301915083602082850101111561149b57600080fd5b6000806020838503121561372757600080fd5b823567ffffffffffffffff81111561373e57600080fd5b6136c6858286016136d2565b60008060006040848603121561375f57600080fd5b833567ffffffffffffffff81111561377657600080fd5b6137828682870161364b565b90945092505060208401356137968161325c565b809150509250925092565b82151581526040602082015260006116cd6040830184613557565b6000806000604084860312156137d157600080fd5b83359250602084013567ffffffffffffffff8111156137ef57600080fd5b6137fb868287016136d2565b9497909650939450505050565b6000806040838503121561381b57600080fd5b82359150602083013561382d816133b2565b809150509250929050565b6000806040838503121561384b57600080fd5b82359150602083013561382d8161325c565b60006020828403121561386f57600080fd5b81356116d0816133b2565b60006020828403121561388c57600080fd5b81356116d08161324d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60006bffffffffffffffffffffffff808316818516818304811182151516156138f1576138f1613897565b02949350505050565b805180151581146134e057600080fd5b60006020828403121561391c57600080fd5b6116d0826138fa565b600082601f83011261393657600080fd5b815161394461337b82613316565b81815284602083860101111561395957600080fd5b61396a826020830160208701613533565b949350505050565b60006020828403121561398457600080fd5b815167ffffffffffffffff81111561399b57600080fd5b61396a84828501613925565b8281526040602082015260006116cd6040830184613557565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff8103613a0557613a05613897565b60010192915050565b8181038181111561127657611276613897565b8082018082111561127657611276613897565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613a6557613a65613897565b5060010190565b80516020808301519190811015613aab577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b80516134e0816135e0565b60008060408385031215613acf57600080fd5b8251613ada816135e0565b6020939093015192949293505050565b600060208284031215613afc57600080fd5b81516116d0816135e0565b600061ffff808316818103613b1e57613b1e613897565b6001019392505050565b60008060408385031215613b3b57600080fd5b82359150602083013567ffffffffffffffff811115613b5957600080fd5b613b658582860161335c565b9150509250929050565b60006020808385031215613b8257600080fd5b825167ffffffffffffffff80821115613b9a57600080fd5b818501915085601f830112613bae57600080fd5b815181811115613bc057613bc061326e565b8060051b9150613bd18483016132c7565b8181529183018401918481019088841115613beb57600080fd5b938501935b83851015613c0957845182529385019390850190613bf0565b98975050505050505050565b600060208284031215613c2757600080fd5b81516116d08161324d565b600060208284031215613c4457600080fd5b5051919050565b600081613c5a57613c5a613897565b507fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0190565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b80516134e08161325c565b80516134e0816133b2565b805167ffffffffffffffff811681146134e057600080fd5b600060208284031215613d1457600080fd5b815167ffffffffffffffff80821115613d2c57600080fd5b908301906101408286031215613d4157600080fd5b613d4961329d565b613d5283613ab1565b8152613d6060208401613cd4565b6020820152604083015182811115613d7757600080fd5b613d8387828601613925565b604083015250613d9560608401613cdf565b6060820152613da660808401613ab1565b6080820152613db760a08401613cea565b60a0820152613dc860c08401613cd4565b60c0820152613dd960e08401613cdf565b60e0820152610100613dec8185016138fa565b908201526101208381015183811115613e0457600080fd5b613e1088828701613925565b918301919091525095945050505050565b600060208284031215613e3357600080fd5b81516116d0816133b2565b600063ffffffff808316818103613b1e57613b1e613897565b6020815260008251610140806020850152613e76610160850183613557565b915060208501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe080868503016040870152613eb28483613557565b935060408701519150613edd606087018373ffffffffffffffffffffffffffffffffffffffff169052565b606087015163ffffffff811660808801529150608087015173ffffffffffffffffffffffffffffffffffffffff811660a0880152915060a087015160ff811660c0880152915060c08701519150808685030160e0870152613f3e8483613557565b935060e08701519150610100818786030181880152613f5d8584613557565b945080880151925050610120818786030181880152613f7c8584613557565b94508088015192505050613f9f828601826bffffffffffffffffffffffff169052565b5090949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615613fe157613fe1613897565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261402457614024613fe6565b500490565b81810360008312801583831316838312821617156131c5576131c5613897565b60008261405857614058613fe6565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff83147f8000000000000000000000000000000000000000000000000000000000000000831416156140ac576140ac613897565b500590565b80820182811260008312801582168215821617156140d1576140d1613897565b505092915050565b60007f7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203613a6557613a65613897565b60007f80000000000000000000000000000000000000000000000000000000000000008203613c5a57613c5a613897565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000810000a", } var VerifiableLoadUpkeepABI = VerifiableLoadUpkeepMetaData.ABI var VerifiableLoadUpkeepBin = VerifiableLoadUpkeepMetaData.Bin -func DeployVerifiableLoadUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, useArb bool) (common.Address, *types.Transaction, *VerifiableLoadUpkeep, error) { +func DeployVerifiableLoadUpkeep(auth *bind.TransactOpts, backend bind.ContractBackend, _registrar common.Address, _useArb bool) (common.Address, *types.Transaction, *VerifiableLoadUpkeep, error) { parsed, err := VerifiableLoadUpkeepMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -48,7 +48,7 @@ func DeployVerifiableLoadUpkeep(auth *bind.TransactOpts, backend bind.ContractBa return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadUpkeepBin), backend, _registrar, useArb) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(VerifiableLoadUpkeepBin), backend, _registrar, _useArb) if err != nil { return common.Address{}, nil, nil, err } @@ -1043,6 +1043,18 @@ func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) PerformUpkee return _VerifiableLoadUpkeep.Contract.PerformUpkeep(&_VerifiableLoadUpkeep.TransactOpts, performData) } +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) SendLog(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.contract.Transact(opts, "sendLog", upkeepId) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepSession) SendLog(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.SendLog(&_VerifiableLoadUpkeep.TransactOpts, upkeepId) +} + +func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactorSession) SendLog(upkeepId *big.Int) (*types.Transaction, error) { + return _VerifiableLoadUpkeep.Contract.SendLog(&_VerifiableLoadUpkeep.TransactOpts, upkeepId) +} + func (_VerifiableLoadUpkeep *VerifiableLoadUpkeepTransactor) SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { return _VerifiableLoadUpkeep.contract.Transact(opts, "setAddLinkAmount", amount) } @@ -2125,6 +2137,8 @@ type VerifiableLoadUpkeepInterface interface { PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) + SendLog(opts *bind.TransactOpts, upkeepId *big.Int) (*types.Transaction, error) + SetAddLinkAmount(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) SetCheckGasToBurn(opts *bind.TransactOpts, upkeepId *big.Int, value *big.Int) (*types.Transaction, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 535fd369b4d..4d191d021b2 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -65,9 +65,9 @@ type_and_version_interface_wrapper: ../../contracts/solc/v0.8.6/TypeAndVersionIn upkeep_counter_wrapper: ../../contracts/solc/v0.7/UpkeepCounter.abi ../../contracts/solc/v0.7/UpkeepCounter.bin 901961ebf18906febc1c350f02da85c7ea1c2a68da70cfd94efa27c837a48663 upkeep_perform_counter_restrictive_wrapper: ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.abi ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.bin 8975a058fba528e16d8414dc6f13946d17a145fcbc66cf25a32449b6fe1ce878 upkeep_transcoder: ../../contracts/solc/v0.8.6/UpkeepTranscoder.abi ../../contracts/solc/v0.8.6/UpkeepTranscoder.bin 336c92a981597be26508455f81a908a0784a817b129a59686c5b2c4afcba730a -verifiable_load_log_trigger_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin 42c14e414215ab00f587ce594947c0181e68e3f406ff9dfc5bc9f656394a7909 -verifiable_load_mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin 7a0b6c3ade3a0f3915252397cf68de9c31dc7cd3256b3c6cd1519f9caca008e3 -verifiable_load_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin 34ed896a4ed549642bba79bd38ea87b47bb1647b14ca607fe10538b302deeb3e +verifiable_load_log_trigger_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin 5d46568c3c468563a6e2a01554f42a49d5d39a8d475616723b4a003f8754ebfc +verifiable_load_mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin 1aff150cf8dfebe9f1bd6e35fdb41a39bb3bcae576a1a2d79a87c92b01b8bbaa +verifiable_load_upkeep_wrapper: ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin 2512e1e5e748bed60bf5a930351acd41c0d355a83126b56bdbf36cc62c5364fd vrf_consumer_v2: ../../contracts/solc/v0.8.6/VRFConsumerV2.abi ../../contracts/solc/v0.8.6/VRFConsumerV2.bin 9ef258bf8e9f8d880fd229ceb145593d91e24fc89366baa0bf19169c5787d15f vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.bin 3155c611e4d6882e9324b6e975033b31356776ea8b031ca63d63da37589d583b vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e From 2ac10a3e4f36b98d48f3696d012829a4b62b4ac8 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Fri, 28 Jul 2023 13:36:43 -0700 Subject: [PATCH 028/270] [Functions] Interfaces for LogPollerWrapper (#9966) Introduce a chain-agnostic LogPollerWrapper that will be provided by the Relayer. LogPollerWrapper needs to support Listener, ConfigProvider and ContractTransmitter (+ potentially more components in the future). --- core/services/functions/listener.go | 32 ++++---- core/services/functions/listener_test.go | 2 +- core/services/ocr2/delegate.go | 5 +- .../services/ocr2/plugins/functions/plugin.go | 3 + core/services/relay/evm/functions.go | 80 +++++++++++++++---- .../relay/evm/functions/logpoller_wrapper.go | 49 ++++++++++++ core/services/relay/evm/types/types.go | 14 ++++ 7 files changed, 152 insertions(+), 33 deletions(-) create mode 100644 core/services/relay/evm/functions/logpoller_wrapper.go diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index 98f1a2799d8..af52e9af197 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -23,6 +23,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/threshold" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + evmrelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/services/s4" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization/telem" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -137,6 +138,7 @@ type FunctionsListener struct { mailMon *utils.MailboxMonitor urlsMonEndpoint commontypes.MonitoringEndpoint decryptor threshold.Decryptor + logPollerWrapper evmrelayTypes.LogPollerWrapper } func formatRequestId(requestId [32]byte) string { @@ -155,22 +157,24 @@ func NewFunctionsListener( mailMon *utils.MailboxMonitor, urlsMonEndpoint commontypes.MonitoringEndpoint, decryptor threshold.Decryptor, + logPollerWrapper evmrelayTypes.LogPollerWrapper, ) *FunctionsListener { return &FunctionsListener{ - oracle: oracle, - oracleHexAddr: oracle.Address().Hex(), - job: job, - bridgeAccessor: bridgeAccessor, - logBroadcaster: logBroadcaster, - mbOracleEvents: utils.NewHighCapacityMailbox[log.Broadcast](), - chStop: make(chan struct{}), - pluginORM: pluginORM, - pluginConfig: pluginConfig, - s4Storage: s4Storage, - logger: lggr, - mailMon: mailMon, - urlsMonEndpoint: urlsMonEndpoint, - decryptor: decryptor, + oracle: oracle, + oracleHexAddr: oracle.Address().Hex(), + job: job, + bridgeAccessor: bridgeAccessor, + logBroadcaster: logBroadcaster, + mbOracleEvents: utils.NewHighCapacityMailbox[log.Broadcast](), + chStop: make(chan struct{}), + pluginORM: pluginORM, + pluginConfig: pluginConfig, + s4Storage: s4Storage, + logger: lggr, + mailMon: mailMon, + urlsMonEndpoint: urlsMonEndpoint, + decryptor: decryptor, + logPollerWrapper: logPollerWrapper, } } diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index 26f0f918b21..8f90d54b3a1 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -122,7 +122,7 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe monEndpoint := ingressAgent.GenMonitoringEndpoint("0xa", synchronization.FunctionsRequests) s4Storage := s4_mocks.NewStorage(t) - functionsListener := functions_service.NewFunctionsListener(oracleContract, jb, bridgeAccessor, pluginORM, pluginConfig, s4Storage, broadcaster, lggr, mailMon, monEndpoint, decryptor) + functionsListener := functions_service.NewFunctionsListener(oracleContract, jb, bridgeAccessor, pluginORM, pluginConfig, s4Storage, broadcaster, lggr, mailMon, monEndpoint, decryptor, nil) return &FunctionsListenerUniverse{ service: functionsListener, diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index c9c6d553617..d80aeab6c82 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -965,7 +965,7 @@ func (d *Delegate) newServicesOCR2Functions( return nil, fmt.Errorf("unsupported relay: %s", spec.Relay) } - createPluginProvider := func(pluginType functionsRelay.FunctionsPluginType, relayerName string) (types.PluginProvider, error) { + createPluginProvider := func(pluginType functionsRelay.FunctionsPluginType, relayerName string) (evmrelaytypes.FunctionsProvider, error) { return evmrelay.NewFunctionsProvider( d.chainSet, types.RelayArgs{ @@ -1081,6 +1081,7 @@ func (d *Delegate) newServicesOCR2Functions( URLsMonEndpoint: d.monitoringEndpointGen.GenMonitoringEndpoint(spec.ContractID, synchronization.FunctionsRequests), EthKeystore: d.ethKs, ThresholdKeyShare: thresholdKeyShare, + LogPollerWrapper: functionsProvider.LogPollerWrapper(), } functionsServices, err := functions.NewFunctionsServices(&functionsOracleArgs, &thresholdOracleArgs, &s4OracleArgs, &functionsServicesConfig) @@ -1099,7 +1100,7 @@ func (d *Delegate) newServicesOCR2Functions( d.cfg.JobPipeline().MaxSuccessfulRuns(), ) - return append([]job.ServiceCtx{runResultSaver, functionsProvider, s4Provider}, functionsServices...), nil + return append([]job.ServiceCtx{runResultSaver, functionsProvider, thresholdProvider, s4Provider}, functionsServices...), nil } // errorLog implements [loop.ErrorLog] diff --git a/core/services/ocr2/plugins/functions/plugin.go b/core/services/ocr2/plugins/functions/plugin.go index 3fedd7a1687..fff4b06a849 100644 --- a/core/services/ocr2/plugins/functions/plugin.go +++ b/core/services/ocr2/plugins/functions/plugin.go @@ -28,6 +28,7 @@ import ( s4_plugin "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/s4" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/threshold" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + evmrelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/services/s4" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -45,6 +46,7 @@ type FunctionsServicesConfig struct { URLsMonEndpoint commontypes.MonitoringEndpoint EthKeystore keystore.Eth ThresholdKeyShare []byte + LogPollerWrapper evmrelayTypes.LogPollerWrapper } const ( @@ -117,6 +119,7 @@ func NewFunctionsServices(functionsOracleArgs, thresholdOracleArgs, s4OracleArgs conf.MailMon, conf.URLsMonEndpoint, decryptor, + conf.LogPollerWrapper, ) allServices = append(allServices, functionsListener) diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index 169b42f1864..95e1bdb1744 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -1,6 +1,7 @@ package evm import ( + "context" "encoding/json" "strings" @@ -10,6 +11,8 @@ import ( "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "go.uber.org/multierr" relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" @@ -19,13 +22,17 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" functionsRelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) type functionsProvider struct { - *configWatcher + utils.StartStopOnce + configWatcher *configWatcher contractTransmitter ContractTransmitter + logPollerWrapper evmRelayTypes.LogPollerWrapper } var ( @@ -36,8 +43,56 @@ func (p *functionsProvider) ContractTransmitter() types.ContractTransmitter { return p.contractTransmitter } -func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs, lggr logger.Logger, ethKeystore keystore.Eth, pluginType functionsRelay.FunctionsPluginType) (relaytypes.Plugin, error) { - configWatcher, err := newFunctionsConfigProvider(pluginType, chainSet, rargs, lggr) +func (p *functionsProvider) LogPollerWrapper() evmRelayTypes.LogPollerWrapper { + return nil +} + +func (p *functionsProvider) Start(ctx context.Context) error { + return p.StartOnce("FunctionsProvider", func() error { + if err := p.configWatcher.Start(ctx); err != nil { + return err + } + return p.logPollerWrapper.Start(ctx) + }) +} + +func (p *functionsProvider) Close() error { + return p.StopOnce("FunctionsProvider", func() (err error) { + err = multierr.Combine(err, p.logPollerWrapper.Close()) + err = multierr.Combine(err, p.configWatcher.Close()) + return + }) +} + +// Forward all calls to the underlying configWatcher +func (p *functionsProvider) OffchainConfigDigester() ocrtypes.OffchainConfigDigester { + return p.configWatcher.OffchainConfigDigester() +} + +func (p *functionsProvider) ContractConfigTracker() ocrtypes.ContractConfigTracker { + return p.configWatcher.ContractConfigTracker() +} + +func (p *functionsProvider) HealthReport() map[string]error { + return p.configWatcher.HealthReport() +} + +func (p *functionsProvider) Name() string { + return p.configWatcher.Name() +} + +func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs, lggr logger.Logger, ethKeystore keystore.Eth, pluginType functionsRelay.FunctionsPluginType) (evmRelayTypes.FunctionsProvider, error) { + var relayConfig evmRelayTypes.RelayConfig + err := json.Unmarshal(rargs.RelayConfig, &relayConfig) + if err != nil { + return nil, err + } + chain, err := chainSet.Get(relayConfig.ChainID.ToInt()) + if err != nil { + return nil, err + } + logPollerWrapper := functions.NewLogPollerWrapper(chain.LogPoller(), lggr) + configWatcher, err := newFunctionsConfigProvider(pluginType, chain, rargs, relayConfig.FromBlock, logPollerWrapper, lggr) if err != nil { return nil, err } @@ -45,26 +100,19 @@ func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, par if err2 := json.Unmarshal(pargs.PluginConfig, &pluginConfig); err2 != nil { return nil, err2 } - contractTransmitter, err := newFunctionsContractTransmitter(pluginConfig.ContractVersion, rargs, pargs.TransmitterID, configWatcher, ethKeystore, lggr) + contractTransmitter, err := newFunctionsContractTransmitter(pluginConfig.ContractVersion, rargs, pargs.TransmitterID, configWatcher, ethKeystore, logPollerWrapper, lggr) if err != nil { return nil, err } return &functionsProvider{ configWatcher: configWatcher, contractTransmitter: contractTransmitter, + logPollerWrapper: logPollerWrapper, }, nil } -func newFunctionsConfigProvider(pluginType functionsRelay.FunctionsPluginType, chainSet evm.ChainSet, args relaytypes.RelayArgs, lggr logger.Logger) (*configWatcher, error) { - var relayConfig evmRelayTypes.RelayConfig - err := json.Unmarshal(args.RelayConfig, &relayConfig) - if err != nil { - return nil, err - } - chain, err := chainSet.Get(relayConfig.ChainID.ToInt()) - if err != nil { - return nil, err - } +func newFunctionsConfigProvider(pluginType functionsRelay.FunctionsPluginType, chain evm.Chain, args relaytypes.RelayArgs, fromBlock uint64, logPollerWrapper evmRelayTypes.LogPollerWrapper, lggr logger.Logger) (*configWatcher, error) { + if !common.IsHexAddress(args.ContractID) { return nil, errors.Errorf("invalid contractID, expected hex address") } @@ -88,10 +136,10 @@ func newFunctionsConfigProvider(pluginType functionsRelay.FunctionsPluginType, c }, } - return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, relayConfig.FromBlock, args.New), nil + return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, fromBlock, args.New), nil } -func newFunctionsContractTransmitter(contractVersion uint32, rargs relaytypes.RelayArgs, transmitterID string, configWatcher *configWatcher, ethKeystore keystore.Eth, lggr logger.Logger) (ContractTransmitter, error) { +func newFunctionsContractTransmitter(contractVersion uint32, rargs relaytypes.RelayArgs, transmitterID string, configWatcher *configWatcher, ethKeystore keystore.Eth, logPollerWrapper evmRelayTypes.LogPollerWrapper, lggr logger.Logger) (ContractTransmitter, error) { var relayConfig evmRelayTypes.RelayConfig if err := json.Unmarshal(rargs.RelayConfig, &relayConfig); err != nil { return nil, err diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go new file mode 100644 index 00000000000..a1ca2f12dbb --- /dev/null +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -0,0 +1,49 @@ +package functions + +import ( + "context" + + "github.com/ethereum/go-ethereum/common" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/logger" + evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" +) + +type logPollerWrapper struct { + logPoller logpoller.LogPoller + lggr logger.Logger +} + +var _ evmRelayTypes.LogPollerWrapper = &logPollerWrapper{} + +func NewLogPollerWrapper(logPoller logpoller.LogPoller, lggr logger.Logger) evmRelayTypes.LogPollerWrapper { + return &logPollerWrapper{ + logPoller: logPoller, + lggr: lggr, + } +} + +// TODO(FUN-381): Implement LogPollerWrapper with an API suiting all users. +func (l *logPollerWrapper) Start(context.Context) error { + return nil +} +func (l *logPollerWrapper) Close() error { + return nil +} + +func (l *logPollerWrapper) HealthReport() map[string]error { + return make(map[string]error) +} + +func (l *logPollerWrapper) Name() string { + return "LogPollerWrapper" +} + +func (l *logPollerWrapper) Ready() error { + return nil +} + +func (l *logPollerWrapper) LatestRoutes() (activeCoordinator common.Address, proposedCoordinator common.Address, err error) { + return common.Address{}, common.Address{}, nil +} diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index 3047dd180aa..f1c5f76be50 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -10,6 +10,8 @@ import ( ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -32,3 +34,15 @@ type ConfigPoller interface { Close() error Replay(ctx context.Context, fromBlock int64) error } + +// TODO(FUN-668): Move chain-agnostic types to Relayer +type FunctionsProvider interface { + relaytypes.PluginProvider + LogPollerWrapper() LogPollerWrapper +} + +// A LogPoller wrapper that understands router proxy contracts +type LogPollerWrapper interface { + relaytypes.Service + LatestRoutes() (activeCoordinator common.Address, proposedCoordinator common.Address, err error) +} From 49cde2d8dcf000fb8087eace4de3a798388a7c9b Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Fri, 28 Jul 2023 18:52:07 -0400 Subject: [PATCH 029/270] [Functions] (test) v1 contracts Go integration test (#9908) * (test): Add integration test for contracts v1 * (fix): V1 listener handle correctly stops awaiting * Requested changes * Change v1 integration test port * Increase MaxReportLengthBytes from 10k -> 15k --- core/services/functions/listener.go | 165 +++-- core/services/functions/listener_test.go | 187 ++--- .../{ => v0}/functions_integration_test.go | 8 +- .../{ => v0}/internal/testconstants.go | 0 .../{ => v0}/internal/testutils.go | 0 .../v1/functions_integration_test.go | 47 ++ .../v1/internal/testconstants.go | 13 + .../v1/internal/testutils.go | 679 ++++++++++++++++++ .../services/ocr2/plugins/functions/plugin.go | 9 +- 9 files changed, 952 insertions(+), 156 deletions(-) rename core/services/ocr2/plugins/functions/integration_tests/{ => v0}/functions_integration_test.go (95%) rename core/services/ocr2/plugins/functions/integration_tests/{ => v0}/internal/testconstants.go (100%) rename core/services/ocr2/plugins/functions/integration_tests/{ => v0}/internal/testutils.go (100%) create mode 100644 core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go create mode 100644 core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go create mode 100644 core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index af52e9af197..96fe37f7506 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -15,6 +15,7 @@ import ( "google.golang.org/protobuf/proto" "github.com/smartcontractkit/chainlink/v2/core/cbor" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" @@ -121,24 +122,24 @@ const ( type FunctionsListener struct { utils.StartStopOnce - oracle *ocr2dr_oracle.OCR2DROracle - oracleHexAddr string - job job.Job - bridgeAccessor BridgeAccessor - logBroadcaster log.Broadcaster - shutdownWaitGroup sync.WaitGroup - mbOracleEvents *utils.Mailbox[log.Broadcast] - serviceContext context.Context - serviceCancel context.CancelFunc - chStop chan struct{} - pluginORM ORM - pluginConfig config.PluginConfig - s4Storage s4.Storage - logger logger.Logger - mailMon *utils.MailboxMonitor - urlsMonEndpoint commontypes.MonitoringEndpoint - decryptor threshold.Decryptor - logPollerWrapper evmrelayTypes.LogPollerWrapper + client client.Client + contractAddressHex string + job job.Job + bridgeAccessor BridgeAccessor + logBroadcaster log.Broadcaster + shutdownWaitGroup sync.WaitGroup + mbOracleEvents *utils.Mailbox[log.Broadcast] + serviceContext context.Context + serviceCancel context.CancelFunc + chStop chan struct{} + pluginORM ORM + pluginConfig config.PluginConfig + s4Storage s4.Storage + logger logger.Logger + mailMon *utils.MailboxMonitor + urlsMonEndpoint commontypes.MonitoringEndpoint + decryptor threshold.Decryptor + logPollerWrapper evmrelayTypes.LogPollerWrapper } func formatRequestId(requestId [32]byte) string { @@ -146,8 +147,9 @@ func formatRequestId(requestId [32]byte) string { } func NewFunctionsListener( - oracle *ocr2dr_oracle.OCR2DROracle, job job.Job, + client client.Client, + contractAddressHex string, bridgeAccessor BridgeAccessor, pluginORM ORM, pluginConfig config.PluginConfig, @@ -160,21 +162,21 @@ func NewFunctionsListener( logPollerWrapper evmrelayTypes.LogPollerWrapper, ) *FunctionsListener { return &FunctionsListener{ - oracle: oracle, - oracleHexAddr: oracle.Address().Hex(), - job: job, - bridgeAccessor: bridgeAccessor, - logBroadcaster: logBroadcaster, - mbOracleEvents: utils.NewHighCapacityMailbox[log.Broadcast](), - chStop: make(chan struct{}), - pluginORM: pluginORM, - pluginConfig: pluginConfig, - s4Storage: s4Storage, - logger: lggr, - mailMon: mailMon, - urlsMonEndpoint: urlsMonEndpoint, - decryptor: decryptor, - logPollerWrapper: logPollerWrapper, + client: client, + contractAddressHex: contractAddressHex, + job: job, + bridgeAccessor: bridgeAccessor, + logBroadcaster: logBroadcaster, + mbOracleEvents: utils.NewHighCapacityMailbox[log.Broadcast](), + chStop: make(chan struct{}), + pluginORM: pluginORM, + pluginConfig: pluginConfig, + s4Storage: s4Storage, + logger: lggr, + mailMon: mailMon, + urlsMonEndpoint: urlsMonEndpoint, + decryptor: decryptor, + logPollerWrapper: logPollerWrapper, } } @@ -182,18 +184,49 @@ func NewFunctionsListener( func (l *FunctionsListener) Start(context.Context) error { return l.StartOnce("FunctionsListener", func() error { l.serviceContext, l.serviceCancel = context.WithCancel(context.Background()) - unsubscribeLogs := l.logBroadcaster.Register(l, log.ListenerOpts{ - Contract: l.oracle.Address(), - ParseLog: l.oracle.ParseLog, - LogsWithTopics: map[common.Hash][][]log.Topic{ - ocr2dr_oracle.OCR2DROracleOracleRequest{}.Topic(): {}, - ocr2dr_oracle.OCR2DROracleOracleResponse{}.Topic(): {}, - ocr2dr_oracle.OCR2DROracleUserCallbackError{}.Topic(): {}, - ocr2dr_oracle.OCR2DROracleUserCallbackRawError{}.Topic(): {}, - ocr2dr_oracle.OCR2DROracleResponseTransmitted{}.Topic(): {}, - }, - MinIncomingConfirmations: l.pluginConfig.MinIncomingConfirmations, - }) + contractAddress := common.HexToAddress(l.contractAddressHex) + var unsubscribeLogs func() + + switch l.pluginConfig.ContractVersion { + case 0: + oracleContract, err := ocr2dr_oracle.NewOCR2DROracle(contractAddress, l.client) + if err != nil { + return err + } + unsubscribeLogs = l.logBroadcaster.Register(l, log.ListenerOpts{ + Contract: oracleContract.Address(), + ParseLog: oracleContract.ParseLog, + LogsWithTopics: map[common.Hash][][]log.Topic{ + ocr2dr_oracle.OCR2DROracleOracleRequest{}.Topic(): {}, + ocr2dr_oracle.OCR2DROracleOracleResponse{}.Topic(): {}, + ocr2dr_oracle.OCR2DROracleUserCallbackError{}.Topic(): {}, + ocr2dr_oracle.OCR2DROracleUserCallbackRawError{}.Topic(): {}, + ocr2dr_oracle.OCR2DROracleResponseTransmitted{}.Topic(): {}, + }, + MinIncomingConfirmations: l.pluginConfig.MinIncomingConfirmations, + }) + case 1: + // TODO: Utilize Log Poller here instead to listen to: + // - Router.getContractById(PluginConfig.DONId, false) = current route + // - Router.getContractById(PluginConfig.DONId, false) = proposed route + // If current = proposed, only listen to current + coordinatorContract, err := functions_coordinator.NewFunctionsCoordinator(contractAddress, l.client) + if err != nil { + return err + } + unsubscribeLogs = l.logBroadcaster.Register(l, log.ListenerOpts{ + Contract: coordinatorContract.Address(), + ParseLog: coordinatorContract.ParseLog, + LogsWithTopics: map[common.Hash][][]log.Topic{ + functions_coordinator.FunctionsCoordinatorOracleRequest{}.Topic(): {}, + functions_coordinator.FunctionsCoordinatorOracleResponse{}.Topic(): {}, + }, + MinIncomingConfirmations: l.pluginConfig.MinIncomingConfirmations, + }) + default: + return errors.New("Functions: unsupported PluginConfig.ContractVersion") + } + if l.pluginConfig.ListenerEventHandlerTimeoutSec == 0 { l.logger.Warn("listenerEventHandlerTimeoutSec set to zero! ORM calls will never time out.") } @@ -233,7 +266,7 @@ func (l *FunctionsListener) HandleLog(lb log.Broadcast) { } switch log := log.(type) { - case *ocr2dr_oracle.OCR2DROracleOracleRequest, *ocr2dr_oracle.OCR2DROracleOracleResponse, *ocr2dr_oracle.OCR2DROracleUserCallbackError, *ocr2dr_oracle.OCR2DROracleUserCallbackRawError, *ocr2dr_oracle.OCR2DROracleResponseTransmitted: + case *ocr2dr_oracle.OCR2DROracleOracleRequest, *ocr2dr_oracle.OCR2DROracleOracleResponse, *ocr2dr_oracle.OCR2DROracleUserCallbackError, *ocr2dr_oracle.OCR2DROracleUserCallbackRawError, *ocr2dr_oracle.OCR2DROracleResponseTransmitted, *functions_coordinator.FunctionsCoordinatorOracleRequest, *functions_coordinator.FunctionsCoordinatorOracleResponse: wasOverCapacity := l.mbOracleEvents.Deliver(lb) if wasOverCapacity { l.logger.Error("OracleRequest log mailbox is over capacity - dropped the oldest log") @@ -280,6 +313,7 @@ func (l *FunctionsListener) processOracleEvents() { } switch log := log.(type) { + // Version 0 case *ocr2dr_oracle.OCR2DROracleOracleRequest: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleRequest").Inc() l.shutdownWaitGroup.Add(1) @@ -298,6 +332,16 @@ func (l *FunctionsListener) processOracleEvents() { go l.handleOracleResponse("UserCallbackRawError", log.RequestId, lb) case *ocr2dr_oracle.OCR2DROracleResponseTransmitted: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "ResponseTransmitted").Inc() + // Version 1 + case *functions_coordinator.FunctionsCoordinatorOracleRequest: + promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleRequest").Inc() + l.shutdownWaitGroup.Add(1) + go l.HandleOracleRequestV1(log, lb) + case *functions_coordinator.FunctionsCoordinatorOracleResponse: + promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleResponse").Inc() + l.shutdownWaitGroup.Add(1) + go l.handleOracleResponse("OracleResponse", log.RequestId, lb) + // TODO: handle other events default: l.logger.Warnf("Unexpected log type %T", log) } @@ -316,9 +360,9 @@ func (l *FunctionsListener) getNewHandlerContext() (context.Context, context.Can func (l *FunctionsListener) setError(ctx context.Context, requestId RequestID, errType ErrType, errBytes []byte) { if errType == INTERNAL_ERROR { - promRequestInternalError.WithLabelValues(l.oracleHexAddr).Inc() + promRequestInternalError.WithLabelValues(l.contractAddressHex).Inc() } else { - promRequestComputationError.WithLabelValues(l.oracleHexAddr).Inc() + promRequestComputationError.WithLabelValues(l.contractAddressHex).Inc() } readyForProcessing := errType != INTERNAL_ERROR if err := l.pluginORM.SetError(requestId, errType, errBytes, time.Now(), readyForProcessing, pg.WithParentCtx(ctx)); err != nil { @@ -343,7 +387,8 @@ func (l *FunctionsListener) getMaxSecretsSize(flags RequestFlags) uint32 { } // TODO (FUN-662): call from LogPoller in a separate goroutine -func (l *FunctionsListener) HandleOracleRequestV1(request *functions_coordinator.FunctionsCoordinatorOracleRequest, coordinatorContractAddress *common.Address, lb log.Broadcast) { +func (l *FunctionsListener) HandleOracleRequestV1(request *functions_coordinator.FunctionsCoordinatorOracleRequest, lb log.Broadcast) { + defer l.shutdownWaitGroup.Done() l.logger.Infow("oracle request v1 received", "requestID", formatRequestId(request.RequestId)) ctx, cancel := l.getNewHandlerContext() defer cancel() @@ -355,7 +400,7 @@ func (l *FunctionsListener) HandleOracleRequestV1(request *functions_coordinator ReceivedAt: time.Now(), Flags: request.Flags[:], CallbackGasLimit: &callbackGasLimit, - CoordinatorContractAddress: coordinatorContractAddress, + CoordinatorContractAddress: &request.Raw.Address, } if err := l.pluginORM.CreateRequest(newReq, pg.WithParentCtx(ctx)); err != nil { if errors.Is(err, ErrDuplicateRequestID) { @@ -368,7 +413,7 @@ func (l *FunctionsListener) HandleOracleRequestV1(request *functions_coordinator } l.markLogConsumed(lb, pg.WithParentCtx(ctx)) - promRequestDataSize.WithLabelValues(l.oracleHexAddr).Observe(float64(len(request.Data))) + promRequestDataSize.WithLabelValues(l.contractAddressHex).Observe(float64(len(request.Data))) requestData, err := l.parseCBOR(request.RequestId, request.Data, l.getMaxCBORsize(request.Flags)) if err != nil { l.setError(ctx, request.RequestId, USER_ERROR, []byte(err.Error())) @@ -396,7 +441,7 @@ func (l *FunctionsListener) handleOracleRequestV0(request *ocr2dr_oracle.OCR2DRO } l.markLogConsumed(lb, pg.WithParentCtx(ctx)) - promRequestDataSize.WithLabelValues(l.oracleHexAddr).Observe(float64(len(request.Data))) + promRequestDataSize.WithLabelValues(l.contractAddressHex).Observe(float64(len(request.Data))) requestData, err := l.parseCBOR(request.RequestId, request.Data, l.pluginConfig.MaxRequestSizeBytes) if err != nil { l.setError(ctx, request.RequestId, USER_ERROR, []byte(err.Error())) @@ -424,7 +469,7 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID Request startTime := time.Now() defer func() { duration := time.Since(startTime) - promComputationDuration.WithLabelValues(l.oracleHexAddr).Observe(float64(duration.Milliseconds())) + promComputationDuration.WithLabelValues(l.contractAddressHex).Observe(float64(duration.Milliseconds())) }() requestIDStr := formatRequestId(requestID) l.logger.Infow("processing request", "requestID", requestIDStr) @@ -480,10 +525,10 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID Request } l.logger.Debugw("saving computation error", "requestID", requestIDStr) l.setError(ctx, requestID, USER_ERROR, computationError) - promComputationErrorSize.WithLabelValues(l.oracleHexAddr).Set(float64(len(computationError))) + promComputationErrorSize.WithLabelValues(l.contractAddressHex).Set(float64(len(computationError))) } else { - promRequestComputationSuccess.WithLabelValues(l.oracleHexAddr).Inc() - promComputationResultSize.WithLabelValues(l.oracleHexAddr).Set(float64(len(computationResult))) + promRequestComputationSuccess.WithLabelValues(l.contractAddressHex).Inc() + promComputationResultSize.WithLabelValues(l.contractAddressHex).Set(float64(len(computationResult))) l.logger.Debugw("saving computation result", "requestID", requestIDStr) if err2 := l.pluginORM.SetResult(requestID, computationResult, time.Now(), pg.WithParentCtx(ctx)); err2 != nil { l.logger.Errorw("call to SetResult failed", "requestID", requestIDStr, "err", err2) @@ -500,7 +545,7 @@ func (l *FunctionsListener) handleOracleResponse(responseType string, requestID if err := l.pluginORM.SetConfirmed(requestID, pg.WithParentCtx(ctx)); err != nil { l.logger.Errorw("setting CONFIRMED state failed", "requestID", formatRequestId(requestID), "err", err) } - promRequestConfirmed.WithLabelValues(l.oracleHexAddr, responseType).Inc() + promRequestConfirmed.WithLabelValues(l.contractAddressHex, responseType).Inc() l.markLogConsumed(lb, pg.WithParentCtx(ctx)) } @@ -533,7 +578,7 @@ func (l *FunctionsListener) timeoutRequests() { break } if len(ids) > 0 { - promRequestTimeout.WithLabelValues(l.oracleHexAddr).Add(float64(len(ids))) + promRequestTimeout.WithLabelValues(l.contractAddressHex).Add(float64(len(ids))) var idStrs []string for _, id := range ids { idStrs = append(idStrs, formatRequestId(id)) @@ -579,7 +624,7 @@ func (l *FunctionsListener) pruneRequests() { break } if nPruned > 0 { - promPrunedRequests.WithLabelValues(l.oracleHexAddr).Add(float64(nPruned)) + promPrunedRequests.WithLabelValues(l.contractAddressHex).Add(float64(nPruned)) l.logger.Debugw("pruned requests from the DB", "nTotal", nTotal, "nPruned", nPruned, "elapsedMillis", elapsedMillis) } else { l.logger.Debugw("no pruned requests at this time", "nTotal", nTotal, "elapsedMillis", elapsedMillis) diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index 8f90d54b3a1..b7204a7a1f1 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -43,13 +43,14 @@ import ( ) type FunctionsListenerUniverse struct { - service *functions_service.FunctionsListener - bridgeAccessor *functions_mocks.BridgeAccessor - eaClient *functions_mocks.ExternalAdapterClient - pluginORM *functions_mocks.ORM - logBroadcaster *log_mocks.Broadcaster - ingressClient *sync_mocks.TelemetryIngressClient - decryptor *threshold_mocks.Decryptor + service *functions_service.FunctionsListener + bridgeAccessor *functions_mocks.BridgeAccessor + eaClient *functions_mocks.ExternalAdapterClient + pluginORM *functions_mocks.ORM + logBroadcaster *log_mocks.Broadcaster + ingressClient *sync_mocks.TelemetryIngressClient + decryptor *threshold_mocks.Decryptor + contractVersion uint32 } func ptr[T any](t T) *T { return &t } @@ -114,24 +115,25 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe err := json.Unmarshal(jsonConfig.Bytes(), &pluginConfig) require.NoError(t, err) - oracleContract, err := ocr2dr_oracle.NewOCR2DROracle(common.HexToAddress("0xa"), chain.Client()) - require.NoError(t, err) + contractAddress := "0xa" ingressClient := sync_mocks.NewTelemetryIngressClient(t) ingressAgent := telemetry.NewIngressAgentWrapper(ingressClient) - monEndpoint := ingressAgent.GenMonitoringEndpoint("0xa", synchronization.FunctionsRequests) + monEndpoint := ingressAgent.GenMonitoringEndpoint(contractAddress, synchronization.FunctionsRequests) s4Storage := s4_mocks.NewStorage(t) - functionsListener := functions_service.NewFunctionsListener(oracleContract, jb, bridgeAccessor, pluginORM, pluginConfig, s4Storage, broadcaster, lggr, mailMon, monEndpoint, decryptor, nil) + client := chain.Client() + functionsListener := functions_service.NewFunctionsListener(jb, client, contractAddress, bridgeAccessor, pluginORM, pluginConfig, s4Storage, broadcaster, lggr, mailMon, monEndpoint, decryptor, nil) return &FunctionsListenerUniverse{ - service: functionsListener, - bridgeAccessor: bridgeAccessor, - eaClient: eaClient, - pluginORM: pluginORM, - logBroadcaster: broadcaster, - ingressClient: ingressClient, - decryptor: decryptor, + service: functionsListener, + bridgeAccessor: bridgeAccessor, + eaClient: eaClient, + pluginORM: pluginORM, + logBroadcaster: broadcaster, + ingressClient: ingressClient, + decryptor: decryptor, + contractVersion: pluginConfig.ContractVersion, } } @@ -144,15 +146,29 @@ func PrepareAndStartFunctionsListener(t *testing.T, cbor []byte) (*FunctionsList log := log_mocks.NewBroadcast(t) uni.logBroadcaster.On("WasAlreadyConsumed", mock.Anything, mock.Anything).Return(false, nil) - logOracleRequest := ocr2dr_oracle.OCR2DROracleOracleRequest{ - RequestId: RequestID, - RequestingContract: common.Address{}, - RequestInitiator: common.Address{}, - SubscriptionId: uint64(SubscriptionID), - SubscriptionOwner: SubscriptionOwner, - Data: cbor, + switch uni.contractVersion { + case 0: + logOracleRequest := ocr2dr_oracle.OCR2DROracleOracleRequest{ + RequestId: RequestID, + RequestingContract: common.Address{}, + RequestInitiator: common.Address{}, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Data: cbor, + } + log.On("DecodedLog").Return(&logOracleRequest) + case 1: + logOracleRequest := functions_coordinator.FunctionsCoordinatorOracleRequest{ + RequestId: RequestID, + RequestingContract: common.Address{}, + RequestInitiator: common.Address{}, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Data: cbor, + } + log.On("DecodedLog").Return(&logOracleRequest) } - log.On("DecodedLog").Return(&logOracleRequest) + log.On("String").Return("") return uni, log, make(chan struct{}) } @@ -452,62 +468,63 @@ func TestFunctionsListener_PruneRequests(t *testing.T) { uni.service.Close() } -func TestFunctionsListener_HandleOracleRequestV1_Success(t *testing.T) { - testutils.SkipShortDB(t) - t.Parallel() - - uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) - - flags := [32]byte{} - flags[1] = 1 // tier no 1 of request size - request := functions_coordinator.FunctionsCoordinatorOracleRequest{ - RequestId: RequestID, - SubscriptionId: uint64(SubscriptionID), - SubscriptionOwner: SubscriptionOwner, - Flags: flags, - Data: make([]byte, 12), // tier 1 should allow for up to 100 bytes - } - - uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) - uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) - log := log_mocks.NewBroadcast(t) - uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) - log.On("String").Return("") - uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) - uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) - uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Return(nil) - err := uni.service.Start(testutils.Context(t)) - require.NoError(t, err) - - uni.service.HandleOracleRequestV1(&request, &request.RequestingContract, log) - uni.service.Close() -} - -func TestFunctionsListener_HandleOracleRequestV1_CBORTooBig(t *testing.T) { - testutils.SkipShortDB(t) - t.Parallel() - - uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) - - flags := [32]byte{} - flags[1] = 1 // tier no 1 of request size - request := functions_coordinator.FunctionsCoordinatorOracleRequest{ - RequestId: RequestID, - SubscriptionId: uint64(SubscriptionID), - SubscriptionOwner: SubscriptionOwner, - Flags: flags, - Data: make([]byte, 120), // tier 1 only allows for up to 100 bytes - } - - uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) - uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) - log := log_mocks.NewBroadcast(t) - uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) - log.On("String").Return("") - uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, []byte("request too big (max 100 bytes)"), mock.Anything, mock.Anything, mock.Anything).Return(nil) - err := uni.service.Start(testutils.Context(t)) - require.NoError(t, err) - - uni.service.HandleOracleRequestV1(&request, &request.RequestingContract, log) - uni.service.Close() -} +// func TestFunctionsListener_HandleOracleRequestV1_Success(t *testing.T) { +// testutils.SkipShortDB(t) +// t.Parallel() + +// uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) + +// flags := [32]byte{} +// flags[1] = 1 // tier no 1 of request size +// request := functions_coordinator.FunctionsCoordinatorOracleRequest{ +// RequestId: RequestID, +// SubscriptionId: uint64(SubscriptionID), +// SubscriptionOwner: SubscriptionOwner, +// Flags: flags, +// Data: make([]byte, 12), // tier 1 should allow for up to 100 bytes +// } + +// uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) +// uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) +// log := log_mocks.NewBroadcast(t) +// uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) +// log.On("String").Return("") +// uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) +// uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) +// uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Return(nil) +// err := uni.service.Start(testutils.Context(t)) +// require.NoError(t, err) + +// uni.service.HandleOracleRequestV1(&request, log) +// uni.service.Close() +// } + +// TODO +// func TestFunctionsListener_HandleOracleRequestV1_CBORTooBig(t *testing.T) { +// testutils.SkipShortDB(t) +// t.Parallel() + +// uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) + +// flags := [32]byte{} +// flags[1] = 1 // tier no 1 of request size +// request := functions_coordinator.FunctionsCoordinatorOracleRequest{ +// RequestId: RequestID, +// SubscriptionId: uint64(SubscriptionID), +// SubscriptionOwner: SubscriptionOwner, +// Flags: flags, +// Data: make([]byte, 120), // tier 1 only allows for up to 100 bytes +// } + +// uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) +// uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) +// log := log_mocks.NewBroadcast(t) +// uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) +// log.On("String").Return("") +// uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, []byte("request too big (max 100 bytes)"), mock.Anything, mock.Anything, mock.Anything).Return(nil) +// err := uni.service.Start(testutils.Context(t)) +// require.NoError(t, err) + +// uni.service.HandleOracleRequestV1(&request, log) +// uni.service.Close() +// } diff --git a/core/services/ocr2/plugins/functions/integration_tests/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go similarity index 95% rename from core/services/ocr2/plugins/functions/integration_tests/functions_integration_test.go rename to core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go index 855c435f26d..faefefa1723 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go @@ -5,7 +5,7 @@ import ( "time" functionsConfig "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" - utils "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/integration_tests/internal" + utils "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/integration_tests/v0/internal" ) var ( @@ -30,7 +30,7 @@ func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, MaxObservationLengthBytes: 10_000, - MaxReportLengthBytes: 10_000, + MaxReportLengthBytes: 15_000, MaxRequestBatchSize: uint32(batchSize), DefaultAggregationMethod: functionsConfig.AggregationMethod_AGGREGATION_MODE, UniqueReports: true, @@ -57,14 +57,14 @@ func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *te pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, MaxObservationLengthBytes: 10_000, - MaxReportLengthBytes: 10_000, + MaxReportLengthBytes: 15_000, MaxRequestBatchSize: uint32(batchSize), DefaultAggregationMethod: functionsConfig.AggregationMethod_AGGREGATION_MODE, UniqueReports: true, ThresholdPluginConfig: &functionsConfig.ThresholdReportingPluginConfig{ MaxQueryLengthBytes: 10_000, MaxObservationLengthBytes: 10_000, - MaxReportLengthBytes: 10_000, + MaxReportLengthBytes: 15_000, RequestCountLimit: 100, RequestTotalBytesLimit: 1_000, RequireLocalRequestCheck: true, diff --git a/core/services/ocr2/plugins/functions/integration_tests/internal/testconstants.go b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testconstants.go similarity index 100% rename from core/services/ocr2/plugins/functions/integration_tests/internal/testconstants.go rename to core/services/ocr2/plugins/functions/integration_tests/v0/internal/testconstants.go diff --git a/core/services/ocr2/plugins/functions/integration_tests/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go similarity index 100% rename from core/services/ocr2/plugins/functions/integration_tests/internal/testutils.go rename to core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go new file mode 100644 index 00000000000..f6f8d119e3a --- /dev/null +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -0,0 +1,47 @@ +package functions_test + +import ( + "testing" + "time" + + functionsConfig "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" + utils "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/integration_tests/v1/internal" +) + +var ( + // a batch of 8 max-length results uses around 2M gas (assuming 70k gas per client callback - see FunctionsClientExample.sol) + nOracleNodes = 4 + nClients = 50 + requestLenBytes = 1_000 + maxGas = 2_000_000 + maxTotalReportGas = 560_000 + batchSize = 8 +) + +func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { + // simulated chain with all contracts + owner, b, ticker, coordinatorContractAddress, coordinatorContract, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) + defer ticker.Stop() + + utils.SetupRouterRoutes(t, owner, routerContract, coordinatorContractAddress, allowListContractAddress) + b.Commit() + + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, coordinatorContractAddress, 39989, nOracleNodes, maxGas, nil, nil) + + pluginConfig := functionsConfig.ReportingPluginConfig{ + MaxQueryLengthBytes: 10_000, + MaxObservationLengthBytes: 10_000, + MaxReportLengthBytes: 15_000, + MaxRequestBatchSize: uint32(batchSize), + MaxReportTotalCallbackGas: uint32(maxTotalReportGas), + DefaultAggregationMethod: functionsConfig.AggregationMethod_AGGREGATION_MODE, + UniqueReports: true, + } + + // config for oracle contract + utils.SetOracleConfig(t, owner, coordinatorContract, oracleIdentities, batchSize, &pluginConfig) + utils.CommitWithFinality(b) + + // validate that all client contracts got correct responses to their requests + utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsBytes, 1*time.Minute) +} diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go new file mode 100644 index 00000000000..07aca3b2e77 --- /dev/null +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go @@ -0,0 +1,13 @@ +package testutils + +var ( + DefaultSecretsBytes = []byte{0xaa, 0xbb, 0xcc} + DefaultSecretsBase64 = "qrvM" + DefaultSecretsUrlsBytes = []byte{0x01, 0x02, 0x03} + DefaultSecretsUrlsBase64 = "AQID" + DefaultArg1 = "arg1" + DefaultArg2 = "arg2" + + // This has been generated using the Functions Toolkit (https://github.com/smartcontractkit/functions-toolkit/blob/main/src/SecretsManager.ts) and decrypts to the JSON string `{"0x0":"qrvM"}` + DefaultThresholdSecretsHex = "0x7b225444483243747874223a2265794a48636d393163434936496c41794e5459694c434a44496a6f69533035305a5559325448593056553168543341766148637955584a4b65545a68626b3177527939794f464e78576a59356158646d636a6c4f535430694c434a4d59574a6c62434936496b464251554642515546425155464251554642515546425155464251554642515546425155464251554642515546425155464251554642515545394969776956534936496b4a45536c6c7a51334e7a623055334d6e6444574846474e557056634770585a573157596e565265544d796431526d4d32786c636c705a647a4671536e6c47627a5256615735744e6d773355456855546e6b7962324e746155686f626c51354d564a6a4e6e5230656c70766147644255326372545430694c434a5658324a6863694936496b4a4961544e69627a5a45536d396a4d324d344d6c46614d5852724c325645536b4a484d336c5a556d783555306834576d684954697472623264575a306f33546e4e456232314b5931646853544979616d63305657644f556c526e57465272655570325458706952306c4a617a466e534851314f4430694c434a46496a6f694d7a524956466c354d544e474b307836596e5a584e7a6c314d6d356c655574514e6b397a656e467859335253513239705a315534534652704e4430694c434a47496a6f69557a5132596d6c6952545a584b314176546d744252445677575459796148426862316c6c6330684853556869556c56614e303155556c6f345554306966513d3d222c2253796d43747874223a2253764237652f4a556a552b433358757873384e5378316967454e517759755051623730306a4a6144222c224e6f6e6365223a224d31714b557a6b306b77374767593538227d" +) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go new file mode 100644 index 00000000000..c67e689234c --- /dev/null +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -0,0 +1,679 @@ +package testutils + +import ( + "encoding/hex" + "encoding/json" + "fmt" + "io" + "math/big" + "math/rand" + "net/http" + "net/http/httptest" + "net/url" + "sync" + "testing" + "time" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/eth/ethconfig" + "github.com/onsi/gomega" + "github.com/smartcontractkit/libocr/commontypes" + confighelper2 "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + ocrtypes2 "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/chainlink/v2/core/assets" + "github.com/smartcontractkit/chainlink/v2/core/bridges" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_allow_list" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_client_example" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_router" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_v3_aggregator_contract" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/functions" + "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ocr2key" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/p2pkey" + functionsConfig "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate" + "github.com/smartcontractkit/chainlink/v2/core/services/ocrbootstrap" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +var nilOpts *bind.CallOpts + +func ptr[T any](v T) *T { return &v } + +var allowListPrivateKey = "0xae78c8b502571dba876742437f8bc78b689cf8518356c0921393d89caaf284ce" + +func SetOracleConfig(t *testing.T, owner *bind.TransactOpts, coordinatorContract *functions_coordinator.FunctionsCoordinator, oracles []confighelper2.OracleIdentityExtra, batchSize int, functionsPluginConfig *functionsConfig.ReportingPluginConfig) { + S := make([]int, len(oracles)) + for i := 0; i < len(S); i++ { + S[i] = 1 + } + + reportingPluginConfigBytes, err := functionsConfig.EncodeReportingPluginConfig(&functionsConfig.ReportingPluginConfigWrapper{ + Config: functionsPluginConfig, + }) + require.NoError(t, err) + + signersKeys, transmittersAccounts, f, onchainConfig, offchainConfigVersion, offchainConfig, err := confighelper2.ContractSetConfigArgsForTests( + 2*time.Second, // deltaProgress + 1*time.Second, // deltaResend + 1*time.Second, // deltaRound + 500*time.Millisecond, // deltaGrace + 2*time.Second, // deltaStage + 5, // RMax (maxRounds) + S, // S (schedule of randomized transmission order) + oracles, + reportingPluginConfigBytes, + 200*time.Millisecond, // maxDurationQuery + 200*time.Millisecond, // maxDurationObservation + 200*time.Millisecond, // maxDurationReport + 200*time.Millisecond, // maxDurationAccept + 200*time.Millisecond, // maxDurationTransmit + 1, // f (max faulty oracles) + nil, // empty onChain config + ) + + var signers []common.Address + var transmitters []common.Address + for i := range signersKeys { + signers = append(signers, common.BytesToAddress(signersKeys[i])) + transmitters = append(transmitters, common.HexToAddress(string(transmittersAccounts[i]))) + } + require.NoError(t, err) + + _, err = coordinatorContract.SetConfig( + owner, + signers, + transmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig, + ) + require.NoError(t, err) + + time.Sleep(1000 * time.Millisecond) +} + +func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToken *link_token_interface.LinkToken, routerContractAddress common.Address, routerContract *functions_router.FunctionsRouter, clientContracts []deployedClientContract, allowListContract *functions_allow_list.TermsOfServiceAllowList) (subscriptionId uint64) { + allowed, err := allowListContract.IsAllowedSender(nilOpts, owner.From) + require.NoError(t, err) + if allowed == false { + messageHash, err := allowListContract.GetMessageHash(nilOpts, owner.From, owner.From) + require.NoError(t, err) + ethMessageHash, err := allowListContract.GetEthSignedMessageHash(nilOpts, messageHash) + require.NoError(t, err) + privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) + require.NoError(t, err) + proof, err := crypto.Sign(ethMessageHash[:], privateKey) + allowListContract.AcceptTermsOfService(owner, owner.From, owner.From, proof) + } + + _, err = routerContract.CreateSubscription(owner) + require.NoError(t, err) + + subscriptionID := uint64(1) + + numContracts := len(clientContracts) + for i := 0; i < numContracts; i++ { + _, err = routerContract.AddConsumer(owner, subscriptionID, clientContracts[i].Address) + require.NoError(t, err) + } + + data, err := utils.ABIEncode(`[{"type":"uint64"}]`, subscriptionID) + require.NoError(t, err) + + amount := big.NewInt(0).Mul(big.NewInt(int64(numContracts)), big.NewInt(2e18)) // 2 LINK per client + _, err = linkToken.TransferAndCall(owner, routerContractAddress, amount, data) + require.NoError(t, err) + + time.Sleep(1000 * time.Millisecond) + + return subscriptionID +} + +const finalityDepth int = 4 + +func CommitWithFinality(b *backends.SimulatedBackend) { + for i := 0; i < finalityDepth; i++ { + b.Commit() + } +} + +type deployedClientContract struct { + Address common.Address + Contract *functions_client_example.FunctionsClientExample +} + +func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, *backends.SimulatedBackend, *time.Ticker, common.Address, *functions_coordinator.FunctionsCoordinator, []deployedClientContract, common.Address, *functions_router.FunctionsRouter, *link_token_interface.LinkToken, common.Address, *functions_allow_list.TermsOfServiceAllowList) { + owner := testutils.MustNewSimTransactor(t) + sb := new(big.Int) + sb, _ = sb.SetString("100000000000000000000", 10) // 1 eth + genesisData := core.GenesisAlloc{owner.From: {Balance: sb}} + gasLimit := ethconfig.Defaults.Miner.GasCeil * 2 + b := backends.NewSimulatedBackend(genesisData, gasLimit) + b.Commit() + + // Initialize types + uint16Type, err := abi.NewType("uint16", "uint16", nil) + require.NoError(t, err) + uint32Type, err := abi.NewType("uint32", "uint32", nil) + require.NoError(t, err) + uint96Type, err := abi.NewType("uint96", "uint96", nil) + require.NoError(t, err) + uint256Type, err := abi.NewType("uint256", "uint256", nil) + require.NoError(t, err) + int256Type, err := abi.NewType("int256", "int256", nil) + require.NoError(t, err) + bytes4Type, err := abi.NewType("bytes4", "bytes4", nil) + require.NoError(t, err) + boolType, err := abi.NewType("bool", "bool", nil) + require.NoError(t, err) + addressType, err := abi.NewType("address", "address", nil) + require.NoError(t, err) + uint32ArrType, err := abi.NewType("uint32[]", "uint32[]", nil) + require.NoError(t, err) + + // Deploy LINK token + linkAddr, _, linkToken, err := link_token_interface.DeployLinkToken(owner, b) + require.NoError(t, err) + + // Deploy mock LINK/ETH price feed + linkEthFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(owner, b, 0, big.NewInt(5021530000000000)) + require.NoError(t, err) + + // Deploy Router contract + routerConfigABI := abi.Arguments{ + { + Type: uint96Type, + }, + { + Type: bytes4Type, + }, + { + Type: uint32ArrType, + }, + } + var adminFee = big.NewInt(0) + handleOracleFulfillmentSelectorSlice, err := hex.DecodeString("0ca76175") + require.NoError(t, err) + var handleOracleFulfillmentSelector [4]byte + copy(handleOracleFulfillmentSelector[:], handleOracleFulfillmentSelectorSlice[:4]) + maxCallbackGasLimits := []uint32{300_000, 500_000, 1_000_000} + routerConfig, err := routerConfigABI.Pack(adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits) + require.NoError(t, err) + var timelockBlocks = uint16(0) + var maximumTimelockBlocks = uint16(10) + routerAddress, _, routerContract, err := functions_router.DeployFunctionsRouter(owner, b, timelockBlocks, maximumTimelockBlocks, linkAddr, routerConfig) + require.NoError(t, err) + + // Deploy Allow List contract + allowListConfigABI := abi.Arguments{ + { + Type: boolType, + }, + { + Type: addressType, + }, + } + var enabled = false // TODO: true + privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) + proofSignerPublicKey := crypto.PubkeyToAddress(privateKey.PublicKey) + require.NoError(t, err) + allowListConfig, err := allowListConfigABI.Pack(enabled, proofSignerPublicKey) + require.NoError(t, err) + allowListAddress, _, allowListContract, err := functions_allow_list.DeployTermsOfServiceAllowList(owner, b, routerAddress, allowListConfig) + require.NoError(t, err) + + // Deploy Coordinator contract + coordinatorConfigABI := abi.Arguments{ + { + Type: uint32Type, + }, + { + Type: uint32Type, + }, + { + Type: uint32Type, + }, + { + Type: uint32Type, + }, + { + Type: int256Type, + }, + { + Type: uint32Type, + }, + { + Type: uint96Type, + }, + { + Type: uint16Type, + }, + { + Type: uint256Type, + }, + } + var maxCallbackGasLimit = uint32(450_000) + var feedStalenessSeconds = uint32(86_400) + var gasOverheadBeforeCallback = uint32(325_000) + var gasOverheadAfterCallback = uint32(50_000) + var fallbackNativePerUnitLink = big.NewInt(5_000_000_000_000_000) + var requestTimeoutSeconds = uint32(300) + var donFee = big.NewInt(0) + var maxSupportedRequestDataVersion = uint16(1) + var fulfillmentGasPriceOverEstimationBP = big.NewInt(6_600) + coordinatorConfig, err := coordinatorConfigABI.Pack( + maxCallbackGasLimit, + feedStalenessSeconds, + gasOverheadBeforeCallback, + gasOverheadAfterCallback, + fallbackNativePerUnitLink, + requestTimeoutSeconds, + donFee, + maxSupportedRequestDataVersion, + fulfillmentGasPriceOverEstimationBP, + ) + require.NoError(t, err) + coordinatorAddress, _, coordinatorContract, err := functions_coordinator.DeployFunctionsCoordinator(owner, b, routerAddress, coordinatorConfig, linkEthFeedAddr) + require.NoError(t, err) + + // Deploy Client contracts + clientContracts := []deployedClientContract{} + for i := 0; i < nClients; i++ { + clientContractAddress, _, clientContract, err := functions_client_example.DeployFunctionsClientExample(owner, b, routerAddress) + require.NoError(t, err) + clientContracts = append(clientContracts, deployedClientContract{ + Address: clientContractAddress, + Contract: clientContract, + }) + if i%10 == 0 { + // Max 10 requests per block + b.Commit() + } + } + + CommitWithFinality(b) + ticker := time.NewTicker(1 * time.Second) + go func() { + for range ticker.C { + b.Commit() + } + }() + return owner, b, ticker, coordinatorAddress, coordinatorContract, clientContracts, routerAddress, routerContract, linkToken, allowListAddress, allowListContract +} + +func SetupRouterRoutes(t *testing.T, owner *bind.TransactOpts, routerContract *functions_router.FunctionsRouter, coordinatorAddress common.Address, allowListAddress common.Address) { + allowListId, err := routerContract.GetAllowListId(nilOpts) + require.NoError(t, err) + var donId [32]byte + copy(donId[:], "1") + proposedContractSetIds := []([32]byte){allowListId, donId} + proposedContractSetAddresses := []common.Address{allowListAddress, coordinatorAddress} + _, err = routerContract.ProposeContractsUpdate(owner, proposedContractSetIds, proposedContractSetAddresses) + require.NoError(t, err) + + time.Sleep(1000 * time.Millisecond) + + _, err = routerContract.UpdateContracts(owner) + require.NoError(t, err) +} + +type Node struct { + App *cltest.TestApplication + PeerID string + Transmitter common.Address + Keybundle ocr2key.KeyBundle + OracleIdentity confighelper2.OracleIdentityExtra +} + +func StartNewNode( + t *testing.T, + owner *bind.TransactOpts, + port uint16, + dbName string, + b *backends.SimulatedBackend, + maxGas uint32, + p2pV2Bootstrappers []commontypes.BootstrapperLocator, + ocr2Keystore []byte, + thresholdKeyShare string, +) *Node { + p2pKey, err := p2pkey.NewV2() + require.NoError(t, err) + config, _ := heavyweight.FullTestDBV2(t, fmt.Sprintf("%s%d", dbName, port), func(c *chainlink.Config, s *chainlink.Secrets) { + c.Insecure.OCRDevelopmentMode = ptr(true) + + c.Feature.LogPoller = ptr(true) + + c.OCR.Enabled = ptr(false) + c.OCR2.Enabled = ptr(true) + + c.P2P.PeerID = ptr(p2pKey.PeerID()) + c.P2P.V1.Enabled = ptr(false) + c.P2P.V2.Enabled = ptr(true) + c.P2P.V2.DeltaDial = models.MustNewDuration(500 * time.Millisecond) + c.P2P.V2.DeltaReconcile = models.MustNewDuration(5 * time.Second) + c.P2P.V2.ListenAddresses = &[]string{fmt.Sprintf("127.0.0.1:%d", port)} + if len(p2pV2Bootstrappers) > 0 { + c.P2P.V2.DefaultBootstrappers = &p2pV2Bootstrappers + } + + c.EVM[0].LogPollInterval = models.MustNewDuration(1 * time.Second) + c.EVM[0].Transactions.ForwardersEnabled = ptr(false) + c.EVM[0].GasEstimator.LimitDefault = ptr(maxGas) + c.EVM[0].GasEstimator.Mode = ptr("FixedPrice") + c.EVM[0].GasEstimator.PriceDefault = assets.NewWei(big.NewInt(60112956)) + + if len(thresholdKeyShare) > 0 { + s.Threshold.ThresholdKeyShare = models.NewSecret(thresholdKeyShare) + } + }) + + app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, config, b, p2pKey) + + sendingKeys, err := app.KeyStore.Eth().EnabledKeysForChain(testutils.SimulatedChainID) + require.NoError(t, err) + require.Len(t, sendingKeys, 1) + transmitter := sendingKeys[0].Address + + // fund the transmitter address + n, err := b.NonceAt(testutils.Context(t), owner.From, nil) + require.NoError(t, err) + + tx := types.NewTransaction( + n, transmitter, + assets.Ether(1).ToInt(), + 21000, + assets.GWei(1).ToInt(), + nil) + signedTx, err := owner.Signer(owner.From, tx) + require.NoError(t, err) + err = b.SendTransaction(testutils.Context(t), signedTx) + require.NoError(t, err) + b.Commit() + + var kb ocr2key.KeyBundle + if ocr2Keystore != nil { + kb, err = app.GetKeyStore().OCR2().Import(ocr2Keystore, "testPassword") + } else { + kb, err = app.GetKeyStore().OCR2().Create("evm") + } + require.NoError(t, err) + + err = app.Start(testutils.Context(t)) + require.NoError(t, err) + + return &Node{ + App: app, + PeerID: p2pKey.PeerID().Raw(), + Transmitter: transmitter, + Keybundle: kb, + OracleIdentity: confighelper2.OracleIdentityExtra{ + OracleIdentity: confighelper2.OracleIdentity{ + OnchainPublicKey: kb.PublicKey(), + TransmitAccount: ocrtypes2.Account(transmitter.String()), + OffchainPublicKey: kb.OffchainPublicKey(), + PeerID: p2pKey.PeerID().Raw(), + }, + ConfigEncryptionPublicKey: kb.ConfigEncryptionPublicKey(), + }, + } +} + +func AddBootstrapJob(t *testing.T, app *cltest.TestApplication, contractAddress common.Address) job.Job { + job, err := ocrbootstrap.ValidatedBootstrapSpecToml(fmt.Sprintf(` + type = "bootstrap" + name = "functions-bootstrap" + schemaVersion = 1 + relay = "evm" + contractConfigConfirmations = 1 + contractConfigTrackerPollInterval = "1s" + contractID = "%s" + + [relayConfig] + chainID = 1337 + fromBlock = 1 + `, contractAddress)) + require.NoError(t, err) + err = app.AddJobV2(testutils.Context(t), &job) + require.NoError(t, err) + return job +} + +func AddOCR2Job(t *testing.T, app *cltest.TestApplication, contractAddress common.Address, keyBundleID string, transmitter common.Address, bridgeURL string) job.Job { + u, err := url.Parse(bridgeURL) + require.NoError(t, err) + require.NoError(t, app.BridgeORM().CreateBridgeType(&bridges.BridgeType{ + Name: "ea_bridge", + URL: models.WebURL(*u), + })) + var donId []byte + copy(donId[:], "1") + job, err := validate.ValidatedOracleSpecToml(app.Config.OCR2(), app.Config.Insecure(), fmt.Sprintf(` + type = "offchainreporting2" + name = "functions-node" + schemaVersion = 1 + relay = "evm" + contractID = "%s" + ocrKeyBundleID = "%s" + transmitterID = "%s" + contractConfigConfirmations = 1 + contractConfigTrackerPollInterval = "1s" + pluginType = "functions" + observationSource = """ + run_computation [type="bridge" name="ea_bridge" requestData="{\\"note\\": \\"observationSource is unused but the bridge is required\\"}"] + run_computation + """ + + [relayConfig] + chainID = 1337 + fromBlock = 1 + + [pluginConfig] + donId = "%s" + contractVersion = 1 + minIncomingConfirmations = 3 + requestTimeoutSec = 300 + requestTimeoutCheckFrequencySec = 10 + requestTimeoutBatchLookupSize = 20 + listenerEventHandlerTimeoutSec = 120 + maxRequestSizeBytes = 30720 + + [pluginConfig.decryptionQueueConfig] + completedCacheTimeoutSec = 300 + maxCiphertextBytes = 10_000 + maxCiphertextIdLength = 100 + maxQueueLength = 100 + decryptRequestTimeoutSec = 100 + + [pluginConfig.s4Constraints] + maxPayloadSizeBytes = 10_1000 + maxSlotsPerUser = 10 + `, contractAddress, keyBundleID, transmitter, hex.EncodeToString(donId))) + require.NoError(t, err) + err = app.AddJobV2(testutils.Context(t), &job) + require.NoError(t, err) + return job +} + +func StartNewMockEA(t *testing.T) *httptest.Server { + return httptest.NewServer(http.HandlerFunc(func(res http.ResponseWriter, req *http.Request) { + b, err := io.ReadAll(req.Body) + require.NoError(t, err) + var jsonMap map[string]any + require.NoError(t, json.Unmarshal(b, &jsonMap)) + var responsePayload []byte + if jsonMap["endpoint"].(string) == "lambda" { + responsePayload = mockEALambdaExecutionResponse(t, jsonMap) + } else if jsonMap["endpoint"].(string) == "fetcher" { + responsePayload = mockEASecretsFetchResponse(t, jsonMap) + } else { + require.Fail(t, "unknown external adapter endpoint '%s'", jsonMap["endpoint"].(string)) + } + res.WriteHeader(http.StatusOK) + _, err = res.Write(responsePayload) + require.NoError(t, err) + })) +} + +func mockEALambdaExecutionResponse(t *testing.T, request map[string]any) []byte { + data := request["data"].(map[string]any) + require.Equal(t, functions.LanguageJavaScript, int(data["language"].(float64))) + require.Equal(t, functions.LocationInline, int(data["codeLocation"].(float64))) + require.Equal(t, functions.LocationRemote, int(data["secretsLocation"].(float64))) + if data["secrets"] != DefaultSecretsBase64 && request["nodeProvidedSecrets"] != fmt.Sprintf(`{"0x0":"%s"}`, DefaultSecretsBase64) { + assert.Fail(t, "expected secrets or nodeProvidedSecrets to be '%s'", DefaultSecretsBase64) + } + args := data["args"].([]interface{}) + require.Equal(t, 2, len(args)) + require.Equal(t, DefaultArg1, args[0].(string)) + require.Equal(t, DefaultArg2, args[1].(string)) + source := data["source"].(string) + // prepend "0xab" to source and return as result + return []byte(fmt.Sprintf(`{"result": "success", "statusCode": 200, "data": {"result": "0xab%s", "error": ""}}`, source)) +} + +func mockEASecretsFetchResponse(t *testing.T, request map[string]any) []byte { + data := request["data"].(map[string]any) + require.Equal(t, "fetchThresholdEncryptedSecrets", data["requestType"]) + require.Equal(t, DefaultSecretsUrlsBase64, data["encryptedSecretsUrls"]) + return []byte(fmt.Sprintf(`{"result": "success", "statusCode": 200, "data": {"result": "%s", "error": ""}}`, DefaultThresholdSecretsHex)) +} + +// Mock EA prepends 0xab to source and user contract crops the answer to first 32 bytes +func GetExpectedResponse(source []byte) [32]byte { + var resp [32]byte + resp[0] = 0xab + for j := 0; j < 31; j++ { + if j >= len(source) { + break + } + resp[j+1] = source[j] + } + return resp +} + +func CreateFunctionsNodes( + t *testing.T, + owner *bind.TransactOpts, + b *backends.SimulatedBackend, + coordinatorContractAddress common.Address, + startingPort uint16, + nOracleNodes int, + maxGas int, + ocr2Keystores [][]byte, + thresholdKeyShares []string, +) (bootstrapNode *Node, oracleNodes []*cltest.TestApplication, oracleIdentites []confighelper2.OracleIdentityExtra) { + t.Helper() + + if len(thresholdKeyShares) != 0 && len(thresholdKeyShares) != nOracleNodes { + require.Fail(t, "thresholdKeyShares must be empty or have length equal to nOracleNodes") + } + if len(ocr2Keystores) != 0 && len(ocr2Keystores) != nOracleNodes { + require.Fail(t, "ocr2Keystores must be empty or have length equal to nOracleNodes") + } + if len(ocr2Keystores) != len(thresholdKeyShares) { + require.Fail(t, "ocr2Keystores and thresholdKeyShares must have the same length") + } + + bootstrapNode = StartNewNode(t, owner, startingPort, "bootstrap", b, uint32(maxGas), nil, nil, "") + AddBootstrapJob(t, bootstrapNode.App, coordinatorContractAddress) + + // oracle nodes with jobs, bridges and mock EAs + for i := 0; i < nOracleNodes; i++ { + var thresholdKeyShare string + if len(thresholdKeyShares) == 0 { + thresholdKeyShare = "" + } else { + thresholdKeyShare = thresholdKeyShares[i] + } + var ocr2Keystore []byte + if len(ocr2Keystores) == 0 { + ocr2Keystore = nil + } else { + ocr2Keystore = ocr2Keystores[i] + } + oracleNode := StartNewNode(t, owner, startingPort+1+uint16(i), fmt.Sprintf("oracle%d", i), b, uint32(maxGas), []commontypes.BootstrapperLocator{ + {PeerID: bootstrapNode.PeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", startingPort)}}, + }, ocr2Keystore, thresholdKeyShare) + oracleNodes = append(oracleNodes, oracleNode.App) + oracleIdentites = append(oracleIdentites, oracleNode.OracleIdentity) + + ea := StartNewMockEA(t) + t.Cleanup(ea.Close) + + _ = AddOCR2Job(t, oracleNodes[i], coordinatorContractAddress, oracleNode.Keybundle.ID(), oracleNode.Transmitter, ea.URL) + } + + return bootstrapNode, oracleNodes, oracleIdentites +} + +func ClientTestRequests( + t *testing.T, + owner *bind.TransactOpts, + b *backends.SimulatedBackend, + linkToken *link_token_interface.LinkToken, + routerAddress common.Address, + routerContract *functions_router.FunctionsRouter, + allowListContract *functions_allow_list.TermsOfServiceAllowList, + clientContracts []deployedClientContract, + requestLenBytes int, + expectedSecrets []byte, + timeout time.Duration, +) { + t.Helper() + var donId [32]byte + copy(donId[:], "1") + subscriptionId := CreateAndFundSubscriptions(t, owner, linkToken, routerAddress, routerContract, clientContracts, allowListContract) + // send requests + requestSources := make([][]byte, len(clientContracts)) + rnd := rand.New(rand.NewSource(666)) + for i, client := range clientContracts { + requestSources[i] = make([]byte, requestLenBytes) + for j := 0; j < requestLenBytes; j++ { + requestSources[i][j] = byte(rnd.Uint32() % 256) + } + _, err := client.Contract.SendRequest( + owner, + hex.EncodeToString(requestSources[i]), + expectedSecrets, + []string{DefaultArg1, DefaultArg2}, + subscriptionId, + donId, + ) + require.NoError(t, err) + } + CommitWithFinality(b) + + // validate that all client contracts got correct responses to their requests + var wg sync.WaitGroup + for i := 0; i < len(clientContracts); i++ { + ic := i + wg.Add(1) + go func() { + defer wg.Done() + gomega.NewGomegaWithT(t).Eventually(func() [32]byte { + answer, err := clientContracts[ic].Contract.LastResponse(nil) + require.NoError(t, err) + return answer + }, timeout, 1*time.Second).Should(gomega.Equal(GetExpectedResponse(requestSources[ic]))) + }() + } + wg.Wait() +} diff --git a/core/services/ocr2/plugins/functions/plugin.go b/core/services/ocr2/plugins/functions/plugin.go index fff4b06a849..3a13c0caba8 100644 --- a/core/services/ocr2/plugins/functions/plugin.go +++ b/core/services/ocr2/plugins/functions/plugin.go @@ -15,7 +15,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/bridges" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/functions" "github.com/smartcontractkit/chainlink/v2/core/services/gateway/connector" @@ -69,11 +68,6 @@ func NewFunctionsServices(functionsOracleArgs, thresholdOracleArgs, s4OracleArgs } allServices := []job.ServiceCtx{} - contractAddress := common.HexToAddress(conf.Job.OCR2OracleSpec.ContractID) - oracleContract, err := ocr2dr_oracle.NewOCR2DROracle(contractAddress, conf.Chain.Client()) - if err != nil { - return nil, errors.Wrapf(err, "Functions: failed to create a FunctionsOracle wrapper for address: %v", contractAddress) - } var decryptor threshold.Decryptor // thresholdOracleArgs nil check will be removed once the Threshold plugin is fully integrated w/ Functions @@ -108,8 +102,9 @@ func NewFunctionsServices(functionsOracleArgs, thresholdOracleArgs, s4OracleArgs listenerLogger := conf.Logger.Named("FunctionsListener") bridgeAccessor := functions.NewBridgeAccessor(conf.BridgeORM, FunctionsBridgeName, MaxAdapterResponseBytes) functionsListener := functions.NewFunctionsListener( - oracleContract, conf.Job, + conf.Chain.Client(), + conf.Job.OCR2OracleSpec.ContractID, bridgeAccessor, pluginORM, pluginConfig, From bc1e90ea41eacfbf4e3f764527303e42e819710f Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Sat, 29 Jul 2023 08:53:45 -0400 Subject: [PATCH 030/270] Bump version and update CHANGELOG for core v2.4.0 (#9935) (cherry picked from commit d0c54ead97a07a9759d9a51736c219c2c6a18681) --- VERSION | 2 +- docs/CHANGELOG.md | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 276cbf9e285..197c4d5c2d7 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.3.0 +2.4.0 diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 615eaa4ab45..38ec4d263d7 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,6 +9,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] +... + +## 2.4.0 - UNRELEASED ### Fixed - Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. From a41937f13981d8ff30e58cad8e0e82e605535099 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sat, 29 Jul 2023 12:39:29 -0700 Subject: [PATCH 031/270] [Functions] Don't use a static EVM Digester in Functions Digester (#9982) Contract address will soon be dynamic so we can't use a single base digester. Let's create one on each call. --- core/services/relay/evm/functions.go | 10 +---- .../relay/evm/functions/config_poller_test.go | 4 +- .../evm/functions/offchain_config_digester.go | 37 +++++++++++++------ 3 files changed, 30 insertions(+), 21 deletions(-) diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index 95e1bdb1744..c1eab5d1a98 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -9,7 +9,6 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" - "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "go.uber.org/multierr" @@ -128,14 +127,7 @@ func newFunctionsConfigProvider(pluginType functionsRelay.FunctionsPluginType, c return nil, err } - offchainConfigDigester := functionsRelay.FunctionsOffchainConfigDigester{ - PluginType: pluginType, - BaseDigester: evmutil.EVMOffchainConfigDigester{ - ChainID: chain.ID().Uint64(), - ContractAddress: contractAddress, - }, - } - + offchainConfigDigester := functionsRelay.NewFunctionsOffchainConfigDigester(pluginType, chain.ID().Uint64(), contractAddress) return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, fromBlock, args.New), nil } diff --git a/core/services/relay/evm/functions/config_poller_test.go b/core/services/relay/evm/functions/config_poller_test.go index e3300a59d69..68e7889d77d 100644 --- a/core/services/relay/evm/functions/config_poller_test.go +++ b/core/services/relay/evm/functions/config_poller_test.go @@ -40,7 +40,9 @@ func TestFunctionsConfigPoller(t *testing.T) { t.Run("ThresholdPlugin", func(t *testing.T) { runTest(t, functions.ThresholdPlugin, functions.ThresholdDigestPrefix) }) - // TODO: Test config poller for S4Plugin (requires S4Plugin to be implemented & corresponding updates to pluginConfig) + t.Run("S4Plugin", func(t *testing.T) { + runTest(t, functions.S4Plugin, functions.S4DigestPrefix) + }) } func runTest(t *testing.T, pluginType functions.FunctionsPluginType, expectedDigestPrefix ocrtypes2.ConfigDigestPrefix) { diff --git a/core/services/relay/evm/functions/offchain_config_digester.go b/core/services/relay/evm/functions/offchain_config_digester.go index edb43efd195..9c8da5a01bb 100644 --- a/core/services/relay/evm/functions/offchain_config_digester.go +++ b/core/services/relay/evm/functions/offchain_config_digester.go @@ -5,12 +5,13 @@ import ( "errors" "fmt" - "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" + "github.com/ethereum/go-ethereum/common" + "github.com/smartcontractkit/libocr/offchainreporting2/chains/evmutil" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ) var ( - _ types.OffchainConfigDigester = FunctionsOffchainConfigDigester{} + _ types.OffchainConfigDigester = functionsOffchainConfigDigester{} FunctionsDigestPrefix = types.ConfigDigestPrefixEVM // In order to support multiple OCR plugins with a single jobspec & OCR2Base contract, each plugin must have a unique config digest. // This is accomplished by overriding the single config digest from the contract with a unique prefix for each plugin via this custom offchain digester & config poller. @@ -18,19 +19,33 @@ var ( S4DigestPrefix = types.ConfigDigestPrefix(8) ) -type FunctionsOffchainConfigDigester struct { - PluginType FunctionsPluginType - BaseDigester evmutil.EVMOffchainConfigDigester +type functionsOffchainConfigDigester struct { + pluginType FunctionsPluginType + chainID uint64 + contractAddress common.Address } -func (d FunctionsOffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.ConfigDigest, error) { - configDigest, err := d.BaseDigester.ConfigDigest(cc) +func NewFunctionsOffchainConfigDigester(pluginType FunctionsPluginType, chainID uint64, contractAddress common.Address) *functionsOffchainConfigDigester { + return &functionsOffchainConfigDigester{ + pluginType: pluginType, + chainID: chainID, + contractAddress: contractAddress, + } +} + +func (d functionsOffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.ConfigDigest, error) { + baseDigester := evmutil.EVMOffchainConfigDigester{ + ChainID: d.chainID, + ContractAddress: d.contractAddress, + } + + configDigest, err := baseDigester.ConfigDigest(cc) if err != nil { return types.ConfigDigest{}, err } var prefix types.ConfigDigestPrefix - switch d.PluginType { + switch d.pluginType { case FunctionsPlugin: prefix = FunctionsDigestPrefix case ThresholdPlugin: @@ -46,8 +61,8 @@ func (d FunctionsOffchainConfigDigester) ConfigDigest(cc types.ContractConfig) ( return configDigest, nil } -func (d FunctionsOffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDigestPrefix, error) { - switch d.PluginType { +func (d functionsOffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDigestPrefix, error) { + switch d.pluginType { case FunctionsPlugin: return FunctionsDigestPrefix, nil case ThresholdPlugin: @@ -55,6 +70,6 @@ func (d FunctionsOffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDiges case S4Plugin: return S4DigestPrefix, nil default: - return 0, fmt.Errorf("unknown plugin type: %v", d.PluginType) + return 0, fmt.Errorf("unknown plugin type: %v", d.pluginType) } } From dd3d82c1748ed89600d35e3496de4b8f88a2e7af Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Sat, 29 Jul 2023 16:21:21 -0400 Subject: [PATCH 032/270] Apply only when paused modifier to all external non-view Router methods (#9981) --- .../src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol | 10 +++++++--- .../functions/dev/1_0_0/FunctionsSubscriptions.sol | 11 +++++++++++ .../generated/functions_router/functions_router.go | 2 +- ...erated-wrapper-dependency-versions-do-not-edit.txt | 2 +- 4 files changed, 20 insertions(+), 5 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index ee4df59b20e..f146dcd33d4 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -126,7 +126,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes memory data, uint16 dataVersion, uint32 callbackGasLimit - ) private returns (bytes32 requestId) { + ) private whenNotPaused returns (bytes32 requestId) { _isValidSubscription(subscriptionId); _isValidConsumer(msg.sender, subscriptionId); _isValidCallbackGasLimit(subscriptionId, callbackGasLimit); @@ -208,7 +208,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint16 dataVersion, uint32 callbackGasLimit, bytes32 donId - ) external override whenNotPaused returns (bytes32) { + ) external override returns (bytes32) { _nonReentrant(); return _sendRequest(donId, false, subscriptionId, data, dataVersion, callbackGasLimit); } @@ -223,7 +223,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 juelsPerGas, uint96 costWithoutFulfillment, address transmitter - ) external override returns (uint8 resultCode, uint96 callbackGasCostJuels) { + ) external override whenNotPaused returns (uint8 resultCode, uint96 callbackGasCostJuels) { _nonReentrant(); Commitment memory commitment = s_requestCommitments[requestId]; @@ -372,6 +372,10 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // | Modifiers | // ================================================================ + function _whenNotPaused() internal view override { + _requireNotPaused(); + } + function _onlyRouterOwner() internal view override { _validateOwnership(); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 74f0c83c52a..5c02ab769d0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -291,6 +291,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function oracleWithdraw(address recipient, uint96 amount) external override { + _whenNotPaused(); _nonReentrant(); if (amount == 0) { revert InvalidCalldata(); @@ -309,6 +310,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // | Deposit helper method | // ================================================================ function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override { + _whenNotPaused(); _nonReentrant(); if (msg.sender != address(LINK)) { revert OnlyCallableFromLink(); @@ -335,6 +337,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function createSubscription() external override returns (uint64 subscriptionId) { + _whenNotPaused(); _nonReentrant(); _onlySenderThatAcceptedToS(); @@ -356,6 +359,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function requestSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { + _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _nonReentrant(); _onlySenderThatAcceptedToS(); @@ -372,6 +376,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external override { + _whenNotPaused(); _nonReentrant(); _onlySenderThatAcceptedToS(); address previousOwner = s_subscriptions[subscriptionId].owner; @@ -388,6 +393,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function removeConsumer(uint64 subscriptionId, address consumer) external override { + _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _nonReentrant(); _onlySenderThatAcceptedToS(); @@ -419,6 +425,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function addConsumer(uint64 subscriptionId, address consumer) external override { + _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _nonReentrant(); _onlySenderThatAcceptedToS(); @@ -441,6 +448,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function cancelSubscription(uint64 subscriptionId, address to) external override { + _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _nonReentrant(); _onlySenderThatAcceptedToS(); @@ -512,6 +520,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external override { + _whenNotPaused(); _nonReentrant(); for (uint256 i = 0; i < requestIdsToTimeout.length; i++) { bytes32 requestId = requestIdsToTimeout[i]; @@ -564,4 +573,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function _onlySenderThatAcceptedToS() internal virtual; function _onlyRouterOwner() internal virtual; + + function _whenNotPaused() internal virtual; } diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 8cd21cf945d..6f3a5dec50b 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -32,7 +32,7 @@ var ( var FunctionsRouterMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b50604051620061ae380380620061ae833981016040819052620000449162000451565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620006cb9350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026491906200054e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052601180546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002dc916012919086019062000323565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000315939291906200065a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003c75791602002820160005b838211156200039357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200034d565b8015620003c55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000393565b505b50620003d5929150620003d9565b5090565b5b80821115620003d55760008155600101620003da565b805161ffff811681146200040357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000449576200044962000408565b604052919050565b600080600080608085870312156200046857600080fd5b6200047385620003f0565b9350602062000484818701620003f0565b60408701519094506001600160a01b0381168114620004a257600080fd5b60608701519093506001600160401b0380821115620004c057600080fd5b818801915088601f830112620004d557600080fd5b815181811115620004ea57620004ea62000408565b620004fe601f8201601f191685016200041e565b915080825289848285010111156200051557600080fd5b60005b818110156200053557838101850151838201860152840162000518565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056457600080fd5b83516001600160601b03811681146200057c57600080fd5b602085810151919450906001600160e01b0319811681146200059d57600080fd5b60408601519093506001600160401b0380821115620005bb57600080fd5b818701915087601f830112620005d057600080fd5b815181811115620005e557620005e562000408565b8060051b9150620005f88483016200041e565b818152918301840191848101908a8411156200061357600080fd5b938501935b838510156200064a578451925063ffffffff83168314620006395760008081fd5b828252938501939085019062000618565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bd57845163ffffffff168352938301939183019160010162000699565b509098975050505050505050565b615ad380620006db6000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610768578063eb523d6c1461077b578063f2fde38b1461078e57600080fd5b8063c4614d611461072f578063d7ae1d3014610742578063e72f6e301461075557600080fd5b8063b5643858116100c8578063b5643858146106fd578063b734c0f414610710578063badc3eb61461071857600080fd5b8063aab396bd146106cc578063b187bd26146106f257600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c769614610682578063a4c0ed36146106a6578063a9c9a918146106b957600080fd5b80639883c10d1461065f5780639f87fad714610667578063a21a23e41461067a57600080fd5b8063823597401161017657806382359740146106215780638da5cb5b146106345780638fde53171461065757600080fd5b80637341c10c1461060657806379ba50971461061957600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461052a5780636a6df79b146105bf57806371ec28ac146105f757600080fd5b806366316d8d146104dd57806366419970146104f0578063665871ec1461051757600080fd5b806354fd4d501161022f57806354fd4d501461045c57806355fedefa146104b35780635c975abb146104c657600080fd5b80633fd67e0514610402578063461d27621461043b57600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103d4578063385de9ae146103dc5780633e871e4d146103ef57600080fd5b80631ded3b36146103ab5780632a905ccc146103be57600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461036957600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc366004614a6f565b6107a1565b005b610301610311366004614aae565b610821565b610301610324366004614af3565b610910565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103609190614b8e565b6103016103b9366004614ba1565b61091a565b6011546bffffffffffffffffffffffff16610347565b61030161094b565b6103016103ea366004614c14565b610970565b6103016103fd366004614d74565b610b54565b610415610410366004614ed5565b610e6e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610360565b61044e610449366004614f89565b611215565b604051908152602001610360565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610360565b61044e6104c1366004614a6f565b611279565b60005460ff165b6040519015158152602001610360565b6103016104eb36600461500b565b61129d565b600b5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610360565b610301610525366004615037565b6114c9565b6105976105383660046150ac565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610360565b6105d26105cd3660046150e4565b6118b2565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610360565b60405160648152602001610360565b610301610614366004614aae565b6118c5565b610301611a72565b61030161062f366004614a6f565b611b94565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d2565b610301611cdc565b600a5461044e565b610301610675366004614aae565b611d60565b6104fe61216a565b610695610690366004614a6f565b612322565b60405161036095949392919061515a565b6103016106b43660046151af565b612410565b6105d26106c7366004615209565b612637565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761044e565b60005460ff166104cd565b61030161070b366004615222565b612644565b61030161275d565b6107206129d3565b6040516103609392919061523d565b61039e61073d366004614c14565b612aae565b610301610750366004614aae565b612ac3565b61030161076336600461529e565b612b1c565b6104cd610776366004614a6f565b612d31565b610301610789366004615209565b612d3c565b61030161079c36600461529e565b612fc5565b6107a9612fd6565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610813576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61081d8282612fde565b5050565b61082a826133b0565b610832613469565b61083a6134a6565b67ffffffffffffffff82166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff82811691161461081d5767ffffffffffffffff82166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61081d82826135a0565b610922612fd6565b61092b826136c0565b67ffffffffffffffff9091166000908152600c6020526040902060040155565b610953613729565b60005460ff1615610968576109666137af565b565b61096661382c565b610978613729565b6000610985846000613887565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109af5750600a54610a23565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156109fc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a2091906152b9565b90505b8383604051610a339291906152d2565b60405180910390208103610a73576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610ada9062010000900461ffff1643615311565b9052600086815260066020908152604090912082518155908201516001820190610b0490826153c5565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b459087908490889088906154df565b60405180910390a15050505050565b610b5c613729565b8151815181141580610b6e5750600881115b15610ba5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610ce1576000848260ff1681518110610bca57610bca61553a565b602002602001015190506000848360ff1681518110610beb57610beb61553a565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c56575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c8d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccc576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b50508080610cd990615569565b915050610ba8565b50600754600090610cfc9062010000900461ffff1643615311565b604080516060810182528681526020808201879052918101839052865192935091600391610d2e9183918901906148b8565b506020828101518051610d4792600185019201906148ff565b506040820151816002015590505060005b84518160ff161015610e67577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610d9a57610d9a61553a565b602002602001015160026000888560ff1681518110610dbb57610dbb61553a565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e0757610e0761553a565b602002602001015185604051610e4d949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610e5f81615569565b915050610d58565b5050505050565b600080610e79613469565b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e08301523314610f87576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff16610fb057600292505061120a565b8060c00151816060015163ffffffff16610fca9190615311565b5a1015610fdb57600392505061120a565b60408082015167ffffffffffffffff166000908152600c602052205460608201516bffffffffffffffffffffffff9091169061101c9063ffffffff16613989565b6110269088615588565b868360e0015161103691906155b8565b61104091906155b8565b6bffffffffffffffffffffffff16111561105e57600492505061120a565b80608001516bffffffffffffffffffffffff16611084826060015163ffffffff16613989565b61108e9088615588565b868360e0015161109e91906155b8565b6110a891906155b8565b6bffffffffffffffffffffffff1611156110c657600592505061120a565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000090811690915560038201849055600482018490556005909101805490911690556060830151908301519194508491611167918c918c918c91613a2b565b805190915061117757600161117a565b60005b935060006111a18360400151846080015185602001518660e001518c87602001518d613ba9565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516111ea578e6111ec565b8f5b6040516111fc94939291906155e4565b60405180910390a351925050505b965096945050505050565b600061121f613e26565b611227613469565b61126e8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e939050565b979650505050505050565b67ffffffffffffffff81166000908152600c60205260408120600401545b92915050565b6112a5613469565b806bffffffffffffffffffffffff166000036112ed576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff80831691161015611347576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906113749084906bffffffffffffffffffffffff1661563a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff166113cb919061563a565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af115801561146f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611493919061565f565b61081d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114d1613469565b60005b818110156118ad5760008383838181106114f0576114f061553a565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e085015290935090506115d9816136c0565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16338114611645576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260a00151421015611683576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af11580156116f2573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611716919061565f565b1561189557608084015167ffffffffffffffff84166000908152600c60208190526040909120805490919061176a9084906c0100000000000000000000000090046bffffffffffffffffffffffff1661563a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff80881684529352902080546001926009916117ef918591690100000000000000000090041661567c565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b505050505080806118a59061569d565b9150506114d4565b505050565b60006118be8383613887565b9392505050565b6118ce826133b0565b6118d6613469565b6118de6134a6565b67ffffffffffffffff82166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611953576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8616845290915290205460ff161561199a575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600d6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610904565b60015473ffffffffffffffffffffffffffffffffffffffff163314611af3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cc3565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b9c613469565b611ba46134a6565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff9182169116338114611c33576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cc3565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611ce4613729565b600954431015611d20576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b611d69826133b0565b611d71613469565b611d796134a6565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e49576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e9e576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600c6020908152604080832060030180548251818502810185019093528083529192909190830182828015611f1957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611eee575b50505050509050600060018251611f3091906156d5565b905060005b82518110156120ce578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f6757611f6761553a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120bc576000838381518110611f9e57611f9e61553a565b6020026020010151905080600c60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206003018381548110611fe457611fe461553a565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600c9091526040902060030180548061205e5761205e6156e8565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120ce565b806120c68161569d565b915050611f35565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600d6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000612174613469565b61217c6134a6565b600b805467ffffffffffffffff1690600061219683615717565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160c081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815260a0870186905297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff0000000000000000000000000000000000000000918216179091559651600284018054919092169716969096179095559251805192965090945091926122d29260038501929101906148ff565b5060a0919091015160049091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6000806000806060612333866136c0565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff918216985092169550909183018282801561240057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116123d5575b5050505050905091939590929450565b612418613469565b601054610100900473ffffffffffffffffffffffffffffffffffffffff16331461246e576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124a8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124b682840184614a6f565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff16612522576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff169186919061255983856155b8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff166125b091906155b8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126179190615311565b6040805192835260208301919091520160405180910390a2505050505050565b6000611297826000613887565b61264c613729565b60075461ffff808316620100009092041603612694576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff90811690821611156126d8576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff6201000090910481168083529084166020830152909182019061270b9043615311565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b612765613729565b6005544310156127a1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff1660016127be919061573e565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff9384160217908190557601000000000000000000000000000000000000000000009004161561284f57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff821610156129d057600060036000018260ff168154811061287a5761287a61553a565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff86169081106128c9576128c961553a565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a150505080806129c890615569565b915050612852565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a3357602002820191906000526020600020905b815481526020019060010190808311612a1f575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612a9c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a71575b50505050509050925092509250909192565b6060612abb8484846142af565b949350505050565b612acc826133b0565b612ad4613469565b612adc6134a6565b612ae58261437e565b15610813576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b24612fd6565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612b98573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bbc91906152b9565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115612c20576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cc3565b818110156118ad576000612c3482846156d5565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af1158015612cb6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cda919061565f565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112978261437e565b612d44613729565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612d7e90615324565b80601f0160208091040260200160405190810160405280929190818152602001828054612daa90615324565b8015612df75780601f10612dcc57610100808354040283529160200191612df7565b820191906000526020600020905b815481529060010190602001808311612dda57829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e4a576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612e6f57612e5c81602001516144cf565b6020808201518051910120600a55612f17565b612e7a826000613887565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612eb69190614b8e565b600060405180830381600087803b158015612ed057600080fd5b505af1925050508015612ee1575060015b612f17576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff166001612f34919061573e565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612fb9928692615759565b60405180910390a15050565b612fcd613729565b6129d0816145ca565b610966613729565b612fe6613469565b67ffffffffffffffff82166000908152600c60209081526040808320815160c08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff9081168285015260028301541660608201526003820180548451818702810187019095528085529194929360808601939092908301828280156130c757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161309c575b505050918352505060049190910154602090910152805190915060005b82608001515181101561318a57600d60008460800151838151811061310b5761310b61553a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055806131828161569d565b9150506130e4565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff00000000000000000000000000000000000000009081169091556002820180549091169055906132106003830182614979565b6004820160009055505080600b60088282829054906101000a90046bffffffffffffffffffffffff16613243919061563a565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af11580156132e8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061330c919061565f565b613342576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff168061341a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461081d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff1615610966576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6134d17fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613887565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561353f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613563919061565f565b1515600003610966576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cc3565b67ffffffffffffffff82166000908152600c6020526040812060040154601254911a908110613600576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cc3565b6012805460ff83169081106136175761361761553a565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff1611156118ad576012805460ff83169081106136675761366761553a565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cc3565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff166129d0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cc3565b6137b76146c5565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613834613e26565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138023390565b6000816138c65760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1680156138c0579050611297565b50613954565b60005b60035460ff82161015613952576003805460ff83169081106138ed576138ed61553a565b90600052602060002001548403613940576004805460ff83169081106139155761391561553a565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112979050565b8061394a81615569565b9150506138c9565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cc3565b60006bffffffffffffffffffffffff821115613a27576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cc3565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b90613a6e90899089908990602401615781565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a611388811015613b2b57600080fd5b611388810390508660408204820311613b4357600080fd5b853b613b4e57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613bc884613989565b613bd29086615588565b9050600081613be188866155b8565b613beb91906155b8565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c909152928320805492975093945084939291613c429185911661563a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613c7c91906155b8565b336000908152600e602052604081208054909190613ca99084906bffffffffffffffffffffffff166155b8565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b94509092613cf0918591166155b8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff16613d6f919061563a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613df3918591690100000000000000000090041661567c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60005460ff1615610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cc3565b6000613e9e856136c0565b613ea83386614731565b613eb285836135a0565b6000613ebe8888613887565b6040805160e08101825233815267ffffffffffffffff891660208083018290526000828152600c808352858220600181015473ffffffffffffffffffffffffffffffffffffffff90811687890152606087018e905261ffff8d166080880152948352925260049182015460a085015263ffffffff891660c085015293517fe1a82d6f0000000000000000000000000000000000000000000000000000000081529495509293849384939287169263e1a82d6f92613f7b92016157ac565b6080604051808303816000875af1158015613f9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613fbe919061583f565b92975090945092509050613fd3338a856147cd565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff16815260200182426140539190615311565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516142999695949392919061587d565b60405180910390a4505050509695505050505050565b606060008080806142c2868801886158e1565b935093509350935060006142db89600187878787613e93565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156143715781816020811061431a5761431a61553a565b1a60f81b8782815181106143305761433061553a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806143698161569d565b9150506142ff565b5050505050509392505050565b67ffffffffffffffff81166000908152600c60209081526040808320600301805482518185028101850190935280835284938301828280156143f657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116143cb575b5050505050905060005b81518110156144c5576000600d60008484815181106144215761442161553a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146144b257506001949350505050565b50806144bd8161569d565b915050614400565b5060009392505050565b6000806000838060200190518101906144e89190615952565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052601180547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145939160129190860190614997565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d2393929190615a3b565b3373ffffffffffffffffffffffffffffffffffffffff821603614649576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cc3565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610966576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cc3565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff1661081d576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cc3565b67ffffffffffffffff82166000908152600c6020819052604090912080548392906148179084906c0100000000000000000000000090046bffffffffffffffffffffffff166155b8565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261488d92849290041661567c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b8280548282559060005260206000209081019282156148f3579160200282015b828111156148f35782518255916020019190600101906148d8565b50613a27929150614a3d565b8280548282559060005260206000209081019282156148f3579160200282015b828111156148f357825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061491f565b50805460008255906000526020600020908101906129d09190614a3d565b828054828255906000526020600020906007016008900481019282156148f35791602002820160005b83821115614a0457835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026149c0565b8015614a345782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a04565b5050613a279291505b5b80821115613a275760008155600101614a3e565b803567ffffffffffffffff81168114614a6a57600080fd5b919050565b600060208284031215614a8157600080fd5b6118be82614a52565b803573ffffffffffffffffffffffffffffffffffffffff81168114614a6a57600080fd5b60008060408385031215614ac157600080fd5b614aca83614a52565b9150614ad860208401614a8a565b90509250929050565b63ffffffff811681146129d057600080fd5b60008060408385031215614b0657600080fd5b614b0f83614a52565b91506020830135614b1f81614ae1565b809150509250929050565b6000815180845260005b81811015614b5057602081850181015186830182015201614b34565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118be6020830184614b2a565b60008060408385031215614bb457600080fd5b614bbd83614a52565b946020939093013593505050565b60008083601f840112614bdd57600080fd5b50813567ffffffffffffffff811115614bf557600080fd5b602083019150836020828501011115614c0d57600080fd5b9250929050565b600080600060408486031215614c2957600080fd5b83359250602084013567ffffffffffffffff811115614c4757600080fd5b614c5386828701614bcb565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614cd657614cd6614c60565b604052919050565b600067ffffffffffffffff821115614cf857614cf8614c60565b5060051b60200190565b600082601f830112614d1357600080fd5b81356020614d28614d2383614cde565b614c8f565b82815260059290921b84018101918181019086841115614d4757600080fd5b8286015b84811015614d6957614d5c81614a8a565b8352918301918301614d4b565b509695505050505050565b60008060408385031215614d8757600080fd5b823567ffffffffffffffff80821115614d9f57600080fd5b818501915085601f830112614db357600080fd5b81356020614dc3614d2383614cde565b82815260059290921b84018101918181019089841115614de257600080fd5b948201945b83861015614e0057853582529482019490820190614de7565b96505086013592505080821115614e1657600080fd5b50614e2385828601614d02565b9150509250929050565b600082601f830112614e3e57600080fd5b813567ffffffffffffffff811115614e5857614e58614c60565b614e8960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614c8f565b818152846020838601011115614e9e57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129d057600080fd5b60008060008060008060c08789031215614eee57600080fd5b86359550602087013567ffffffffffffffff80821115614f0d57600080fd5b614f198a838b01614e2d565b96506040890135915080821115614f2f57600080fd5b50614f3c89828a01614e2d565b9450506060870135614f4d81614ebb565b92506080870135614f5d81614ebb565b9150614f6b60a08801614a8a565b90509295509295509295565b803561ffff81168114614a6a57600080fd5b60008060008060008060a08789031215614fa257600080fd5b614fab87614a52565b9550602087013567ffffffffffffffff811115614fc757600080fd5b614fd389828a01614bcb565b9096509450614fe6905060408801614f77565b92506060870135614ff681614ae1565b80925050608087013590509295509295509295565b6000806040838503121561501e57600080fd5b61502783614a8a565b91506020830135614b1f81614ebb565b6000806020838503121561504a57600080fd5b823567ffffffffffffffff8082111561506257600080fd5b818501915085601f83011261507657600080fd5b81358181111561508557600080fd5b8660208260051b850101111561509a57600080fd5b60209290920196919550909350505050565b600080604083850312156150bf57600080fd5b6150c883614a8a565b9150614ad860208401614a52565b80151581146129d057600080fd5b600080604083850312156150f757600080fd5b823591506020830135614b1f816150d6565b600081518084526020808501945080840160005b8381101561514f57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161511d565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061126e90830184615109565b600080600080606085870312156151c557600080fd5b6151ce85614a8a565b935060208501359250604085013567ffffffffffffffff8111156151f157600080fd5b6151fd87828801614bcb565b95989497509550505050565b60006020828403121561521b57600080fd5b5035919050565b60006020828403121561523457600080fd5b6118be82614f77565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561527e57845183529383019391830191600101615262565b505084810360408601526152928187615109565b98975050505050505050565b6000602082840312156152b057600080fd5b6118be82614a8a565b6000602082840312156152cb57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115611297576112976152e2565b600181811c9082168061533857607f821691505b602082108103615371577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156118ad57600081815260208120601f850160051c8101602086101561539e5750805b601f850160051c820191505b818110156153bd578281556001016153aa565b505050505050565b815167ffffffffffffffff8111156153df576153df614c60565b6153f3816153ed8454615324565b84615377565b602080601f83116001811461544657600084156154105750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556153bd565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561549357888601518255948401946001909101908401615474565b50858210156154cf57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361557f5761557f6152e2565b60010192915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155b0576155b06152e2565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156155dd576155dd6152e2565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006156306080830184614b2a565b9695505050505050565b6bffffffffffffffffffffffff8281168282160390808211156155dd576155dd6152e2565b60006020828403121561567157600080fd5b81516118be816150d6565b67ffffffffffffffff8181168382160190808211156155dd576155dd6152e2565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036156ce576156ce6152e2565b5060010190565b81810381811115611297576112976152e2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff808316818103615734576157346152e2565b6001019392505050565b61ffff8181168382160190808211156155dd576155dd6152e2565b8381528260208201526060604082015260006157786060830184614b2a565b95945050505050565b83815260606020820152600061579a6060830185614b2a565b82810360408401526156308185614b2a565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015267ffffffffffffffff602085015116604084015280604085015116606084015250606083015160e0608084015261580b610100840182614b2a565b905061ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b6000806000806080858703121561585557600080fd5b84519350602085015161586781614ebb565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c060608301526158be60c0830186614b2a565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b600080600080608085870312156158f757600080fd5b61590085614a52565b9350602085013567ffffffffffffffff81111561591c57600080fd5b61592887828801614e2d565b93505061593760408601614f77565b9150606085013561594781614ae1565b939692955090935050565b60008060006060848603121561596757600080fd5b835161597281614ebb565b809350506020808501517fffffffff00000000000000000000000000000000000000000000000000000000811681146159aa57600080fd5b604086015190935067ffffffffffffffff8111156159c757600080fd5b8501601f810187136159d857600080fd5b80516159e6614d2382614cde565b81815260059190911b82018301908381019089831115615a0557600080fd5b928401925b82841015615a2c578351615a1d81614ae1565b82529284019290840190615a0a565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615ab857845163ffffffff1683529383019391830191600101615a96565b50909897505050505050505056fea164736f6c6343000813000a", + Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b506040516200620638038062006206833981016040819052620000449162000451565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620006cb9350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026491906200054e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052601180546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002dc916012919086019062000323565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000315939291906200065a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003c75791602002820160005b838211156200039357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200034d565b8015620003c55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000393565b505b50620003d5929150620003d9565b5090565b5b80821115620003d55760008155600101620003da565b805161ffff811681146200040357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000449576200044962000408565b604052919050565b600080600080608085870312156200046857600080fd5b6200047385620003f0565b9350602062000484818701620003f0565b60408701519094506001600160a01b0381168114620004a257600080fd5b60608701519093506001600160401b0380821115620004c057600080fd5b818801915088601f830112620004d557600080fd5b815181811115620004ea57620004ea62000408565b620004fe601f8201601f191685016200041e565b915080825289848285010111156200051557600080fd5b60005b818110156200053557838101850151838201860152840162000518565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056457600080fd5b83516001600160601b03811681146200057c57600080fd5b602085810151919450906001600160e01b0319811681146200059d57600080fd5b60408601519093506001600160401b0380821115620005bb57600080fd5b818701915087601f830112620005d057600080fd5b815181811115620005e557620005e562000408565b8060051b9150620005f88483016200041e565b818152918301840191848101908a8411156200061357600080fd5b938501935b838510156200064a578451925063ffffffff83168314620006395760008081fd5b828252938501939085019062000618565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bd57845163ffffffff168352938301939183019160010162000699565b509098975050505050505050565b615b2b80620006db6000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610768578063eb523d6c1461077b578063f2fde38b1461078e57600080fd5b8063c4614d611461072f578063d7ae1d3014610742578063e72f6e301461075557600080fd5b8063b5643858116100c8578063b5643858146106fd578063b734c0f414610710578063badc3eb61461071857600080fd5b8063aab396bd146106cc578063b187bd26146106f257600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c769614610682578063a4c0ed36146106a6578063a9c9a918146106b957600080fd5b80639883c10d1461065f5780639f87fad714610667578063a21a23e41461067a57600080fd5b8063823597401161017657806382359740146106215780638da5cb5b146106345780638fde53171461065757600080fd5b80637341c10c1461060657806379ba50971461061957600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461052a5780636a6df79b146105bf57806371ec28ac146105f757600080fd5b806366316d8d146104dd57806366419970146104f0578063665871ec1461051757600080fd5b806354fd4d501161022f57806354fd4d501461045c57806355fedefa146104b35780635c975abb146104c657600080fd5b80633fd67e0514610402578063461d27621461043b57600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103d4578063385de9ae146103dc5780633e871e4d146103ef57600080fd5b80631ded3b36146103ab5780632a905ccc146103be57600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461036957600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc366004614ac7565b6107a1565b005b610301610311366004614b06565b610821565b610301610324366004614b4b565b610918565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103609190614be6565b6103016103b9366004614bf9565b610922565b6011546bffffffffffffffffffffffff16610347565b610301610953565b6103016103ea366004614c6c565b610978565b6103016103fd366004614dcc565b610b5c565b610415610410366004614f2d565b610e76565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610360565b61044e610449366004614fe1565b611225565b604051908152602001610360565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610360565b61044e6104c1366004614ac7565b611281565b60005460ff165b6040519015158152602001610360565b6103016104eb366004615063565b6112a5565b600b5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610360565b61030161052536600461508f565b6114d9565b610597610538366004615104565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610360565b6105d26105cd36600461513c565b6118ca565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610360565b60405160648152602001610360565b610301610614366004614b06565b6118dd565b610301611a92565b61030161062f366004614ac7565b611bb4565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d2565b610301611d04565b600a5461044e565b610301610675366004614b06565b611d88565b6104fe61219a565b610695610690366004614ac7565b61235a565b6040516103609594939291906151b2565b6103016106b4366004615207565b612448565b6105d26106c7366004615261565b612677565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761044e565b60005460ff166104cd565b61030161070b36600461527a565b612684565b61030161279d565b610720612a13565b60405161036093929190615295565b61039e61073d366004614c6c565b612aee565b610301610750366004614b06565b612b03565b6103016107633660046152f6565b612b64565b6104cd610776366004614ac7565b612d79565b610301610789366004615261565b612d84565b61030161079c3660046152f6565b61300d565b6107a961301e565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610813576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61081d8282613026565b5050565b6108296133f8565b61083282613400565b61083a6134b9565b6108426134f6565b67ffffffffffffffff82166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff82811691161461081d5767ffffffffffffffff82166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61081d82826135f0565b61092a61301e565b61093382613710565b67ffffffffffffffff9091166000908152600c6020526040902060040155565b61095b613779565b60005460ff16156109705761096e6137ff565b565b61096e61387c565b610980613779565b600061098d8460006138d7565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109b75750600a54610a2b565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a04573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a289190615311565b90505b8383604051610a3b92919061532a565b60405180910390208103610a7b576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610ae29062010000900461ffff1643615369565b9052600086815260066020908152604090912082518155908201516001820190610b0c908261541d565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b4d908790849088908890615537565b60405180910390a15050505050565b610b64613779565b8151815181141580610b765750600881115b15610bad576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610ce9576000848260ff1681518110610bd257610bd2615592565b602002602001015190506000848360ff1681518110610bf357610bf3615592565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c5e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c95576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cd4576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b50508080610ce1906155c1565b915050610bb0565b50600754600090610d049062010000900461ffff1643615369565b604080516060810182528681526020808201879052918101839052865192935091600391610d36918391890190614910565b506020828101518051610d4f9260018501920190614957565b506040820151816002015590505060005b84518160ff161015610e6f577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610da257610da2615592565b602002602001015160026000888560ff1681518110610dc357610dc3615592565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e0f57610e0f615592565b602002602001015185604051610e55949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610e67816155c1565b915050610d60565b5050505050565b600080610e816139d9565b610e896134b9565b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e08301523314610f97576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff16610fc057600292505061121a565b8060c00151816060015163ffffffff16610fda9190615369565b5a1015610feb57600392505061121a565b60408082015167ffffffffffffffff166000908152600c602052205460608201516bffffffffffffffffffffffff9091169061102c9063ffffffff16613a46565b61103690886155e0565b868360e001516110469190615610565b6110509190615610565b6bffffffffffffffffffffffff16111561106e57600492505061121a565b80608001516bffffffffffffffffffffffff16611094826060015163ffffffff16613a46565b61109e90886155e0565b868360e001516110ae9190615610565b6110b89190615610565b6bffffffffffffffffffffffff1611156110d657600592505061121a565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000090811690915560038201849055600482018490556005909101805490911690556060830151908301519194508491611177918c918c918c91613ae8565b805190915061118757600161118a565b60005b935060006111b18360400151846080015185602001518660e001518c87602001518d613c66565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516111fa578e6111fc565b8f5b60405161120c949392919061563c565b60405180910390a351925050505b965096945050505050565b600061122f6134b9565b6112768260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613ee39050565b979650505050505050565b67ffffffffffffffff81166000908152600c60205260408120600401545b92915050565b6112ad6133f8565b6112b56134b9565b806bffffffffffffffffffffffff166000036112fd576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff80831691161015611357576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906113849084906bffffffffffffffffffffffff16615692565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff166113db9190615692565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af115801561147f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a391906156b7565b61081d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114e16133f8565b6114e96134b9565b60005b818110156118c557600083838381811061150857611508615592565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e085015290935090506115f181613710565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1633811461165d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260a0015142101561169b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561170a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061172e91906156b7565b156118ad57608084015167ffffffffffffffff84166000908152600c6020819052604090912080549091906117829084906c0100000000000000000000000090046bffffffffffffffffffffffff16615692565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff808816845293529020805460019260099161180791859169010000000000000000009004166156d4565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b505050505080806118bd906156f5565b9150506114ec565b505050565b60006118d683836138d7565b9392505050565b6118e56133f8565b6118ee82613400565b6118f66134b9565b6118fe6134f6565b67ffffffffffffffff82166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611973576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8616845290915290205460ff16156119ba575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600d6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e0910161090c565b60015473ffffffffffffffffffffffffffffffffffffffff163314611b13576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610ccb565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611bbc6133f8565b611bc46134b9565b611bcc6134f6565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff9182169116338114611c5b576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610ccb565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611d0c613779565b600954431015611d48576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b611d906133f8565b611d9982613400565b611da16134b9565b611da96134f6565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e79576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610ccb565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ece576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600c6020908152604080832060030180548251818502810185019093528083529192909190830182828015611f4957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f1e575b50505050509050600060018251611f60919061572d565b905060005b82518110156120fe578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f9757611f97615592565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120ec576000838381518110611fce57611fce615592565b6020026020010151905080600c60008967ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600301838154811061201457612014615592565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600c9091526040902060030180548061208e5761208e615740565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120fe565b806120f6816156f5565b915050611f65565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600d6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60006121a46133f8565b6121ac6134b9565b6121b46134f6565b600b805467ffffffffffffffff169060006121ce8361576f565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160c081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815260a0870186905297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915596516002840180549190921697169690961790955592518051929650909450919261230a926003850192910190614957565b5060a0919091015160049091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061236b86613710565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff918216985092169550909183018282801561243857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161240d575b5050505050905091939590929450565b6124506133f8565b6124586134b9565b601054610100900473ffffffffffffffffffffffffffffffffffffffff1633146124ae576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124e8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124f682840184614ac7565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff16612562576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff16918691906125998385615610565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff166125f09190615610565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126579190615369565b6040805192835260208301919091520160405180910390a2505050505050565b600061129f8260006138d7565b61268c613779565b60075461ffff8083166201000090920416036126d4576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff9081169082161115612718576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff6201000090910481168083529084166020830152909182019061274b9043615369565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b6127a5613779565b6005544310156127e1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff1660016127fe9190615796565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff9384160217908190557601000000000000000000000000000000000000000000009004161561288f57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff82161015612a1057600060036000018260ff16815481106128ba576128ba615592565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff861690811061290957612909615592565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a15050508080612a08906155c1565b915050612892565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a7357602002820191906000526020600020905b815481526020019060010190808311612a5f575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612adc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612ab1575b50505050509050925092509250909192565b6060612afb848484614307565b949350505050565b612b0b6133f8565b612b1482613400565b612b1c6134b9565b612b246134f6565b612b2d826143d6565b15610813576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b6c61301e565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c049190615311565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115612c68576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610ccb565b818110156118c5576000612c7c828461572d565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af1158015612cfe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d2291906156b7565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b600061129f826143d6565b612d8c613779565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612dc69061537c565b80601f0160208091040260200160405190810160405280929190818152602001828054612df29061537c565b8015612e3f5780601f10612e1457610100808354040283529160200191612e3f565b820191906000526020600020905b815481529060010190602001808311612e2257829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e92576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612eb757612ea48160200151614527565b6020808201518051910120600a55612f5f565b612ec28260006138d7565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612efe9190614be6565b600060405180830381600087803b158015612f1857600080fd5b505af1925050508015612f29575060015b612f5f576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff166001612f7c9190615796565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926130019286926157b1565b60405180910390a15050565b613015613779565b612a1081614622565b61096e613779565b61302e6134b9565b67ffffffffffffffff82166000908152600c60209081526040808320815160c08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff90811682850152600283015416606082015260038201805484518187028101870190955280855291949293608086019390929083018282801561310f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116130e4575b505050918352505060049190910154602090910152805190915060005b8260800151518110156131d257600d60008460800151838151811061315357613153615592565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055806131ca816156f5565b91505061312c565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff000000000000000000000000000000000000000090811690915560028201805490911690559061325860038301826149d1565b6004820160009055505080600b60088282829054906101000a90046bffffffffffffffffffffffff1661328b9190615692565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af1158015613330573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061335491906156b7565b61338a576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b61096e6139d9565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff168061346a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461081d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff161561096e576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6135217fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006138d7565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561358f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135b391906156b7565b151560000361096e576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610ccb565b67ffffffffffffffff82166000908152600c6020526040812060040154601254911a908110613650576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610ccb565b6012805460ff831690811061366757613667615592565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff1611156118c5576012805460ff83169081106136b7576136b7615592565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610ccb565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16612a10576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff16331461096e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610ccb565b61380761471d565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6138846139d9565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138523390565b6000816139165760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16801561391057905061129f565b506139a4565b60005b60035460ff821610156139a2576003805460ff831690811061393d5761393d615592565b90600052602060002001548403613990576004805460ff831690811061396557613965615592565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16915061129f9050565b8061399a816155c1565b915050613919565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610ccb565b60005460ff161561096e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610ccb565b60006bffffffffffffffffffffffff821115613ae4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610ccb565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b90613b2b908990899089906024016157d9565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a611388811015613be857600080fd5b611388810390508660408204820311613c0057600080fd5b853b613c0b57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613c8584613a46565b613c8f90866155e0565b9050600081613c9e8886615610565b613ca89190615610565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c909152928320805492975093945084939291613cff91859116615692565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613d399190615610565b336000908152600e602052604081208054909190613d669084906bffffffffffffffffffffffff16615610565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b94509092613dad91859116615610565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff16613e2c9190615692565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613eb091859169010000000000000000009004166156d4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613eed6139d9565b613ef685613710565b613f003386614789565b613f0a85836135f0565b6000613f1688886138d7565b6040805160e08101825233815267ffffffffffffffff891660208083018290526000828152600c808352858220600181015473ffffffffffffffffffffffffffffffffffffffff90811687890152606087018e905261ffff8d166080880152948352925260049182015460a085015263ffffffff891660c085015293517fe1a82d6f0000000000000000000000000000000000000000000000000000000081529495509293849384939287169263e1a82d6f92613fd39201615804565b6080604051808303816000875af1158015613ff2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140169190615897565b9297509094509250905061402b338a85614825565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff16815260200182426140ab9190615369565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516142f1969594939291906158d5565b60405180910390a4505050509695505050505050565b6060600080808061431a86880188615939565b9350935093509350600061433389600187878787613ee3565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156143c95781816020811061437257614372615592565b1a60f81b87828151811061438857614388615592565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806143c1816156f5565b915050614357565b5050505050509392505050565b67ffffffffffffffff81166000908152600c602090815260408083206003018054825181850281018501909352808352849383018282801561444e57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614423575b5050505050905060005b815181101561451d576000600d600084848151811061447957614479615592565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461450a57506001949350505050565b5080614515816156f5565b915050614458565b5060009392505050565b60008060008380602001905181019061454091906159aa565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052601180547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145eb91601291908601906149ef565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d6b93929190615a93565b3373ffffffffffffffffffffffffffffffffffffffff8216036146a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610ccb565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff1661096e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610ccb565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff1661081d576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610ccb565b67ffffffffffffffff82166000908152600c60208190526040909120805483929061486f9084906c0100000000000000000000000090046bffffffffffffffffffffffff16615610565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926148e59284929004166156d4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b82805482825590600052602060002090810192821561494b579160200282015b8281111561494b578251825591602001919060010190614930565b50613ae4929150614a95565b82805482825590600052602060002090810192821561494b579160200282015b8281111561494b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614977565b5080546000825590600052602060002090810190612a109190614a95565b8280548282559060005260206000209060070160089004810192821561494b5791602002820160005b83821115614a5c57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a18565b8015614a8c5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a5c565b5050613ae49291505b5b80821115613ae45760008155600101614a96565b803567ffffffffffffffff81168114614ac257600080fd5b919050565b600060208284031215614ad957600080fd5b6118d682614aaa565b803573ffffffffffffffffffffffffffffffffffffffff81168114614ac257600080fd5b60008060408385031215614b1957600080fd5b614b2283614aaa565b9150614b3060208401614ae2565b90509250929050565b63ffffffff81168114612a1057600080fd5b60008060408385031215614b5e57600080fd5b614b6783614aaa565b91506020830135614b7781614b39565b809150509250929050565b6000815180845260005b81811015614ba857602081850181015186830182015201614b8c565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118d66020830184614b82565b60008060408385031215614c0c57600080fd5b614c1583614aaa565b946020939093013593505050565b60008083601f840112614c3557600080fd5b50813567ffffffffffffffff811115614c4d57600080fd5b602083019150836020828501011115614c6557600080fd5b9250929050565b600080600060408486031215614c8157600080fd5b83359250602084013567ffffffffffffffff811115614c9f57600080fd5b614cab86828701614c23565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d2e57614d2e614cb8565b604052919050565b600067ffffffffffffffff821115614d5057614d50614cb8565b5060051b60200190565b600082601f830112614d6b57600080fd5b81356020614d80614d7b83614d36565b614ce7565b82815260059290921b84018101918181019086841115614d9f57600080fd5b8286015b84811015614dc157614db481614ae2565b8352918301918301614da3565b509695505050505050565b60008060408385031215614ddf57600080fd5b823567ffffffffffffffff80821115614df757600080fd5b818501915085601f830112614e0b57600080fd5b81356020614e1b614d7b83614d36565b82815260059290921b84018101918181019089841115614e3a57600080fd5b948201945b83861015614e5857853582529482019490820190614e3f565b96505086013592505080821115614e6e57600080fd5b50614e7b85828601614d5a565b9150509250929050565b600082601f830112614e9657600080fd5b813567ffffffffffffffff811115614eb057614eb0614cb8565b614ee160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614ce7565b818152846020838601011115614ef657600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612a1057600080fd5b60008060008060008060c08789031215614f4657600080fd5b86359550602087013567ffffffffffffffff80821115614f6557600080fd5b614f718a838b01614e85565b96506040890135915080821115614f8757600080fd5b50614f9489828a01614e85565b9450506060870135614fa581614f13565b92506080870135614fb581614f13565b9150614fc360a08801614ae2565b90509295509295509295565b803561ffff81168114614ac257600080fd5b60008060008060008060a08789031215614ffa57600080fd5b61500387614aaa565b9550602087013567ffffffffffffffff81111561501f57600080fd5b61502b89828a01614c23565b909650945061503e905060408801614fcf565b9250606087013561504e81614b39565b80925050608087013590509295509295509295565b6000806040838503121561507657600080fd5b61507f83614ae2565b91506020830135614b7781614f13565b600080602083850312156150a257600080fd5b823567ffffffffffffffff808211156150ba57600080fd5b818501915085601f8301126150ce57600080fd5b8135818111156150dd57600080fd5b8660208260051b85010111156150f257600080fd5b60209290920196919550909350505050565b6000806040838503121561511757600080fd5b61512083614ae2565b9150614b3060208401614aaa565b8015158114612a1057600080fd5b6000806040838503121561514f57600080fd5b823591506020830135614b778161512e565b600081518084526020808501945080840160005b838110156151a757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615175565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061127690830184615161565b6000806000806060858703121561521d57600080fd5b61522685614ae2565b935060208501359250604085013567ffffffffffffffff81111561524957600080fd5b61525587828801614c23565b95989497509550505050565b60006020828403121561527357600080fd5b5035919050565b60006020828403121561528c57600080fd5b6118d682614fcf565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156152d6578451835293830193918301916001016152ba565b505084810360408601526152ea8187615161565b98975050505050505050565b60006020828403121561530857600080fd5b6118d682614ae2565b60006020828403121561532357600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561129f5761129f61533a565b600181811c9082168061539057607f821691505b6020821081036153c9577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156118c557600081815260208120601f850160051c810160208610156153f65750805b601f850160051c820191505b8181101561541557828155600101615402565b505050505050565b815167ffffffffffffffff81111561543757615437614cb8565b61544b81615445845461537c565b846153cf565b602080601f83116001811461549e57600084156154685750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615415565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156154eb578886015182559484019460019091019084016154cc565b508582101561552757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036155d7576155d761533a565b60010192915050565b6bffffffffffffffffffffffff8181168382160280821691908281146156085761560861533a565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156156355761563561533a565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006156886080830184614b82565b9695505050505050565b6bffffffffffffffffffffffff8281168282160390808211156156355761563561533a565b6000602082840312156156c957600080fd5b81516118d68161512e565b67ffffffffffffffff8181168382160190808211156156355761563561533a565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036157265761572661533a565b5060010190565b8181038181111561129f5761129f61533a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361578c5761578c61533a565b6001019392505050565b61ffff8181168382160190808211156156355761563561533a565b8381528260208201526060604082015260006157d06060830184614b82565b95945050505050565b8381526060602082015260006157f26060830185614b82565b82810360408401526156888185614b82565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015267ffffffffffffffff602085015116604084015280604085015116606084015250606083015160e06080840152615863610100840182614b82565b905061ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b600080600080608085870312156158ad57600080fd5b8451935060208501516158bf81614f13565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261591660c0830186614b82565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b6000806000806080858703121561594f57600080fd5b61595885614aaa565b9350602085013567ffffffffffffffff81111561597457600080fd5b61598087828801614e85565b93505061598f60408601614fcf565b9150606085013561599f81614b39565b939692955090935050565b6000806000606084860312156159bf57600080fd5b83516159ca81614f13565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615a0257600080fd5b604086015190935067ffffffffffffffff811115615a1f57600080fd5b8501601f81018713615a3057600080fd5b8051615a3e614d7b82614d36565b81815260059190911b82018301908381019089831115615a5d57600080fd5b928401925b82841015615a84578351615a7581614b39565b82529284019290840190615a62565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615b1057845163ffffffff1683529383019391830191600101615aee565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 1130f9bf93f..a4f5046baf0 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -4,7 +4,7 @@ functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfSer functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin ea01c8210316c767b4925731a55ee03bfe5cf04f1c4663aa3115bbc36b94d01f functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b4c8fce90c7aaa68d1af53442e6c44505d090636a18e50b58c0d16d50dcf35aa -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 94c169b225c7d42ac104fa5be7609aaeaff3a18f00857654ab1c72208efb12c7 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 19ac653ad69dd9c06cb511e02f6973075cfff8ffcd859dacf1405069743b0d0e ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From df336b972c86cd5ad5cc3b6567cb6c4d65f76d4b Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sat, 29 Jul 2023 15:42:19 -0700 Subject: [PATCH 033/270] [Functions] LogPollerWrapper support in relay components (#9978) 1. Subscribe to route updates in poller, transmitter and digester. 2. LogPollerWrapper support for v0 contracts (single, synchronous update). 3. LogPollerWrapper subscription management. 4. Stub of public API for the Listener (latest request/response). --- core/services/relay/evm/functions.go | 43 +++++++------ .../relay/evm/functions/config_poller.go | 53 +++++++++++----- .../relay/evm/functions/config_poller_test.go | 9 +-- .../evm/functions/contract_transmitter.go | 61 +++++++++++++------ .../functions/contract_transmitter_test.go | 9 ++- .../relay/evm/functions/logpoller_wrapper.go | 48 ++++++++++++--- .../evm/functions/offchain_config_digester.go | 33 +++++++--- core/services/relay/evm/types/types.go | 18 +++++- 8 files changed, 195 insertions(+), 79 deletions(-) diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index c1eab5d1a98..f1275d2d18b 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -9,7 +9,7 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" - "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "go.uber.org/multierr" @@ -21,7 +21,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" functionsRelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -34,16 +33,14 @@ type functionsProvider struct { logPollerWrapper evmRelayTypes.LogPollerWrapper } -var ( - _ relaytypes.Plugin = (*functionsProvider)(nil) -) +var _ evmRelayTypes.FunctionsProvider = (*functionsProvider)(nil) -func (p *functionsProvider) ContractTransmitter() types.ContractTransmitter { +func (p *functionsProvider) ContractTransmitter() ocrtypes.ContractTransmitter { return p.contractTransmitter } func (p *functionsProvider) LogPollerWrapper() evmRelayTypes.LogPollerWrapper { - return nil + return p.logPollerWrapper } func (p *functionsProvider) Start(ctx context.Context) error { @@ -90,15 +87,19 @@ func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, par if err != nil { return nil, err } - logPollerWrapper := functions.NewLogPollerWrapper(chain.LogPoller(), lggr) - configWatcher, err := newFunctionsConfigProvider(pluginType, chain, rargs, relayConfig.FromBlock, logPollerWrapper, lggr) - if err != nil { - return nil, err + if !common.IsHexAddress(rargs.ContractID) { + return nil, errors.Errorf("invalid contractID, expected hex address") } var pluginConfig config.PluginConfig if err2 := json.Unmarshal(pargs.PluginConfig, &pluginConfig); err2 != nil { return nil, err2 } + routerContractAddress := common.HexToAddress(rargs.ContractID) + logPollerWrapper := functionsRelay.NewLogPollerWrapper(routerContractAddress, pluginConfig.ContractVersion, chain.LogPoller(), lggr) + configWatcher, err := newFunctionsConfigProvider(pluginType, chain, rargs, relayConfig.FromBlock, logPollerWrapper, lggr) + if err != nil { + return nil, err + } contractTransmitter, err := newFunctionsContractTransmitter(pluginConfig.ContractVersion, rargs, pargs.TransmitterID, configWatcher, ethKeystore, logPollerWrapper, lggr) if err != nil { return nil, err @@ -111,24 +112,26 @@ func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, par } func newFunctionsConfigProvider(pluginType functionsRelay.FunctionsPluginType, chain evm.Chain, args relaytypes.RelayArgs, fromBlock uint64, logPollerWrapper evmRelayTypes.LogPollerWrapper, lggr logger.Logger) (*configWatcher, error) { - if !common.IsHexAddress(args.ContractID) { return nil, errors.Errorf("invalid contractID, expected hex address") } - contractAddress := common.HexToAddress(args.ContractID) + routerContractAddress := common.HexToAddress(args.ContractID) contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorMetaData.ABI)) if err != nil { return nil, errors.Wrap(err, "could not get contract ABI JSON") } - cp, err := functionsRelay.NewFunctionsConfigPoller(pluginType, chain.LogPoller(), contractAddress, lggr) + cp, err := functionsRelay.NewFunctionsConfigPoller(pluginType, chain.LogPoller(), lggr) if err != nil { return nil, err } + logPollerWrapper.SubscribeToUpdates("FunctionsConfigPoller", cp) + + offchainConfigDigester := functionsRelay.NewFunctionsOffchainConfigDigester(pluginType, chain.ID().Uint64()) + logPollerWrapper.SubscribeToUpdates("FunctionsOffchainConfigDigester", offchainConfigDigester) - offchainConfigDigester := functionsRelay.NewFunctionsOffchainConfigDigester(pluginType, chain.ID().Uint64(), contractAddress) - return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, fromBlock, args.New), nil + return newConfigWatcher(lggr, routerContractAddress, contractABI, offchainConfigDigester, cp, chain, fromBlock, args.New), nil } func newFunctionsContractTransmitter(contractVersion uint32, rargs relaytypes.RelayArgs, transmitterID string, configWatcher *configWatcher, ethKeystore keystore.Eth, logPollerWrapper evmRelayTypes.LogPollerWrapper, lggr logger.Logger) (ContractTransmitter, error) { @@ -189,8 +192,7 @@ func newFunctionsContractTransmitter(contractVersion uint32, rargs relaytypes.Re return nil, errors.Wrap(err, "failed to create transmitter") } - return functionsRelay.NewFunctionsContractTransmitter( - configWatcher.contractAddress, + functionsTransmitter, err := functionsRelay.NewFunctionsContractTransmitter( configWatcher.chain.Client(), configWatcher.contractABI, transmitter, @@ -199,4 +201,9 @@ func newFunctionsContractTransmitter(contractVersion uint32, rargs relaytypes.Re nil, contractVersion, ) + if err != nil { + return nil, err + } + logPollerWrapper.SubscribeToUpdates("FunctionsConfigTransmitter", functionsTransmitter) + return functionsTransmitter, err } diff --git a/core/services/relay/evm/functions/config_poller.go b/core/services/relay/evm/functions/config_poller.go index 0c8ef42adfa..4feff842ce3 100644 --- a/core/services/relay/evm/functions/config_poller.go +++ b/core/services/relay/evm/functions/config_poller.go @@ -4,6 +4,7 @@ import ( "context" "database/sql" "encoding/binary" + "sync/atomic" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" @@ -18,8 +19,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" ) -var _ types.ConfigPoller = &configPoller{} - type FunctionsPluginType int const ( @@ -30,12 +29,14 @@ const ( type configPoller struct { lggr logger.Logger - filterName string destChainLogPoller logpoller.LogPoller - addr common.Address + targetContract atomic.Pointer[common.Address] pluginType FunctionsPluginType } +var _ types.ConfigPoller = &configPoller{} +var _ types.RouteUpdateSubscriber = &configPoller{} + // ConfigSet Common to all OCR2 evm based contracts: https://github.com/smartcontractkit/libocr/blob/master/contract2/dev/OCR2Abstract.sol var ConfigSet common.Hash @@ -103,23 +104,15 @@ func configFromLog(logData []byte, pluginType FunctionsPluginType) (ocrtypes.Con } func configPollerFilterName(addr common.Address) string { - return logpoller.FilterName("OCR2ConfigPoller", addr.String()) + return logpoller.FilterName("FunctionsOCR2ConfigPoller", addr.String()) } -func NewFunctionsConfigPoller(pluginType FunctionsPluginType, destChainPoller logpoller.LogPoller, addr common.Address, lggr logger.Logger) (types.ConfigPoller, error) { - err := destChainPoller.RegisterFilter(logpoller.Filter{Name: configPollerFilterName(addr), EventSigs: []common.Hash{ConfigSet}, Addresses: []common.Address{addr}}) - if err != nil { - return nil, err - } - +func NewFunctionsConfigPoller(pluginType FunctionsPluginType, destChainPoller logpoller.LogPoller, lggr logger.Logger) (*configPoller, error) { cp := &configPoller{ lggr: lggr, - filterName: configPollerFilterName(addr), destChainLogPoller: destChainPoller, - addr: addr, pluginType: pluginType, } - return cp, nil } @@ -138,7 +131,12 @@ func (cp *configPoller) Replay(ctx context.Context, fromBlock int64) error { } func (cp *configPoller) LatestConfigDetails(ctx context.Context) (changedInBlock uint64, configDigest ocrtypes.ConfigDigest, err error) { - latest, err := cp.destChainLogPoller.LatestLogByEventSigWithConfs(ConfigSet, cp.addr, 1, pg.WithParentCtx(ctx)) + contractAddr := cp.targetContract.Load() + if contractAddr == nil { + return 0, ocrtypes.ConfigDigest{}, nil + } + + latest, err := cp.destChainLogPoller.LatestLogByEventSigWithConfs(ConfigSet, *contractAddr, 1, pg.WithParentCtx(ctx)) if err != nil { if errors.Is(err, sql.ErrNoRows) { return 0, ocrtypes.ConfigDigest{}, nil @@ -153,7 +151,14 @@ func (cp *configPoller) LatestConfigDetails(ctx context.Context) (changedInBlock } func (cp *configPoller) LatestConfig(ctx context.Context, changedInBlock uint64) (ocrtypes.ContractConfig, error) { - lgs, err := cp.destChainLogPoller.Logs(int64(changedInBlock), int64(changedInBlock), ConfigSet, cp.addr, pg.WithParentCtx(ctx)) + // NOTE: if targetContract changes between invocations of LatestConfigDetails() and LatestConfig() + // (unlikely), we'll return an error here and libocr will re-try. + contractAddr := cp.targetContract.Load() + if contractAddr == nil { + return ocrtypes.ContractConfig{}, errors.New("no target contract address set yet") + } + + lgs, err := cp.destChainLogPoller.Logs(int64(changedInBlock), int64(changedInBlock), ConfigSet, *contractAddr, pg.WithParentCtx(ctx)) if err != nil { return ocrtypes.ContractConfig{}, err } @@ -175,3 +180,19 @@ func (cp *configPoller) LatestBlockHeight(ctx context.Context) (blockHeight uint } return uint64(latest), nil } + +// called from LogPollerWrapper in a separate goroutine +func (cp *configPoller) UpdateRoutes(activeCoordinator common.Address, proposedCoordinator common.Address) error { + cp.targetContract.Store(&activeCoordinator) + // Register filters for both active and proposed + err := cp.destChainLogPoller.RegisterFilter(logpoller.Filter{Name: configPollerFilterName(activeCoordinator), EventSigs: []common.Hash{ConfigSet}, Addresses: []common.Address{activeCoordinator}}) + if err != nil { + return err + } + err = cp.destChainLogPoller.RegisterFilter(logpoller.Filter{Name: configPollerFilterName(proposedCoordinator), EventSigs: []common.Hash{ConfigSet}, Addresses: []common.Address{activeCoordinator}}) + if err != nil { + return err + } + // TODO: unregister old filter (needs refactor to get pg.Queryer) + return nil +} diff --git a/core/services/relay/evm/functions/config_poller_test.go b/core/services/relay/evm/functions/config_poller_test.go index 68e7889d77d..b6de78b49df 100644 --- a/core/services/relay/evm/functions/config_poller_test.go +++ b/core/services/relay/evm/functions/config_poller_test.go @@ -82,10 +82,11 @@ func runTest(t *testing.T, pluginType functions.FunctionsPluginType, expectedDig lp := logpoller.NewLogPoller(lorm, ethClient, lggr, 100*time.Millisecond, 1, 2, 2, 1000) defer lp.Close() require.NoError(t, lp.Start(ctx)) - logPoller, err := functions.NewFunctionsConfigPoller(pluginType, lp, ocrAddress, lggr) + configPoller, err := functions.NewFunctionsConfigPoller(pluginType, lp, lggr) require.NoError(t, err) + require.NoError(t, configPoller.UpdateRoutes(ocrAddress, ocrAddress)) // Should have no config to begin with. - _, config, err := logPoller.LatestConfigDetails(testutils.Context(t)) + _, config, err := configPoller.LatestConfigDetails(testutils.Context(t)) require.NoError(t, err) require.Equal(t, ocrtypes2.ConfigDigest{}, config) @@ -121,13 +122,13 @@ func runTest(t *testing.T, pluginType functions.FunctionsPluginType, expectedDig var digest [32]byte gomega.NewGomegaWithT(t).Eventually(func() bool { b.Commit() - configBlock, digest, err = logPoller.LatestConfigDetails(testutils.Context(t)) + configBlock, digest, err = configPoller.LatestConfigDetails(testutils.Context(t)) require.NoError(t, err) return ocrtypes2.ConfigDigest{} != digest }, testutils.WaitTimeout(t), 100*time.Millisecond).Should(gomega.BeTrue()) // Assert the config returned is the one we configured. - newConfig, err := logPoller.LatestConfig(testutils.Context(t), configBlock) + newConfig, err := configPoller.LatestConfig(testutils.Context(t), configBlock) require.NoError(t, err) // Get actual configDigest value from contracts diff --git a/core/services/relay/evm/functions/contract_transmitter.go b/core/services/relay/evm/functions/contract_transmitter.go index eda0ae1b78a..673c3a12011 100644 --- a/core/services/relay/evm/functions/contract_transmitter.go +++ b/core/services/relay/evm/functions/contract_transmitter.go @@ -6,11 +6,11 @@ import ( "encoding/hex" "fmt" "math/big" + "sync/atomic" "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" - gethcommon "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" @@ -21,6 +21,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/encoding" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -29,11 +30,9 @@ type FunctionsContractTransmitter interface { ocrtypes.ContractTransmitter } -var _ FunctionsContractTransmitter = &contractTransmitter{} - type Transmitter interface { - CreateEthTransaction(ctx context.Context, toAddress gethcommon.Address, payload []byte, txMeta *txmgr.TxMeta) error - FromAddress() gethcommon.Address + CreateEthTransaction(ctx context.Context, toAddress common.Address, payload []byte, txMeta *txmgr.TxMeta) error + FromAddress() common.Address } type ReportToEthMetadata func([]byte) (*txmgr.TxMeta, error) @@ -43,7 +42,7 @@ func reportToEvmTxMetaNoop([]byte) (*txmgr.TxMeta, error) { } type contractTransmitter struct { - contractAddress gethcommon.Address + contractAddress atomic.Pointer[common.Address] contractABI abi.ABI transmitter Transmitter transmittedEventSig common.Hash @@ -55,12 +54,14 @@ type contractTransmitter struct { reportCodec encoding.ReportCodec } +var _ FunctionsContractTransmitter = &contractTransmitter{} +var _ evmRelayTypes.RouteUpdateSubscriber = &contractTransmitter{} + func transmitterFilterName(addr common.Address) string { - return logpoller.FilterName("OCR ContractTransmitter", addr.String()) + return logpoller.FilterName("FunctionsOCR2ContractTransmitter", addr.String()) } func NewFunctionsContractTransmitter( - destAddressV0 gethcommon.Address, caller contractReader, contractABI abi.ABI, transmitter Transmitter, @@ -74,11 +75,6 @@ func NewFunctionsContractTransmitter( return nil, errors.New("invalid ABI, missing transmitted") } - // TODO(FUN-674): Read updates from correct contract. - err := lp.RegisterFilter(logpoller.Filter{Name: transmitterFilterName(destAddressV0), EventSigs: []common.Hash{transmitted.ID}, Addresses: []common.Address{destAddressV0}}) - if err != nil { - return nil, err - } if reportToEvmTxMeta == nil { reportToEvmTxMeta = reportToEvmTxMetaNoop } @@ -87,7 +83,6 @@ func NewFunctionsContractTransmitter( return nil, err } return &contractTransmitter{ - contractAddress: destAddressV0, contractABI: contractABI, transmitter: transmitter, transmittedEventSig: transmitted.ID, @@ -121,8 +116,14 @@ func (oc *contractTransmitter) Transmit(ctx context.Context, reportCtx ocrtypes. oc.lggr.Warnw("failed to generate tx metadata for report", "err", err) } - destinationContract := oc.contractAddress - if oc.contractVersion == 1 { + var destinationContract common.Address + if oc.contractVersion == 0 { + destinationContractPtr := oc.contractAddress.Load() + if destinationContractPtr == nil { + return errors.New("destination contract address not set") + } + destinationContract = *destinationContractPtr + } else if oc.contractVersion == 1 { requests, err2 := oc.reportCodec.DecodeReport(report) if err2 != nil { return errors.Wrap(err2, "DecodeReport failed") @@ -133,9 +134,11 @@ func (oc *contractTransmitter) Transmit(ctx context.Context, reportCtx ocrtypes. if len(requests[0].CoordinatorContract) != common.AddressLength { return fmt.Errorf("incorrect length of CoordinatorContract field: %d", len(requests[0].CoordinatorContract)) } - // NOTE: this is incorrect if batch contains requests destined for different contracts - // and there is currently no way areound it until we get rid of batching + // NOTE: this is incorrect if batch contains requests destined for different contracts (unlikely) + // it will be fixed when we get rid of batching destinationContract.SetBytes(requests[0].CoordinatorContract) + } else { + return fmt.Errorf("unsupported contract version: %d", oc.contractVersion) } oc.lggr.Debugw("Transmitting report", "report", hex.EncodeToString(report), "rawReportCtx", rawReportCtx, "contractAddress", destinationContract, "txMeta", txMeta) @@ -188,7 +191,11 @@ func callContract(ctx context.Context, addr common.Address, contractABI abi.ABI, // It is plugin independent, in particular avoids use of the plugin specific generated evm wrappers // by using the evm client Call directly for functions/events that are part of OCR2Abstract. func (oc *contractTransmitter) LatestConfigDigestAndEpoch(ctx context.Context) (ocrtypes.ConfigDigest, uint32, error) { - latestConfigDigestAndEpoch, err := callContract(ctx, oc.contractAddress, oc.contractABI, "latestConfigDigestAndEpoch", nil, oc.contractReader) + contractAddr := oc.contractAddress.Load() + if contractAddr == nil { + return ocrtypes.ConfigDigest{}, 0, errors.New("destination contract address not set") + } + latestConfigDigestAndEpoch, err := callContract(ctx, *contractAddr, oc.contractABI, "latestConfigDigestAndEpoch", nil, oc.contractReader) if err != nil { return ocrtypes.ConfigDigest{}, 0, err } @@ -205,7 +212,7 @@ func (oc *contractTransmitter) LatestConfigDigestAndEpoch(ctx context.Context) ( return ocrtypes.ConfigDigest{}, 0, err } latest, err := oc.lp.LatestLogByEventSigWithConfs( - oc.transmittedEventSig, oc.contractAddress, 1, pg.WithParentCtx(ctx)) + oc.transmittedEventSig, *contractAddr, 1, pg.WithParentCtx(ctx)) if err != nil { if errors.Is(err, sql.ErrNoRows) { // No transmissions yet @@ -230,3 +237,17 @@ func (oc *contractTransmitter) HealthReport() map[string]error { return map[string]error{oc.Name(): nil} } func (oc *contractTransmitter) Name() string { return oc.lggr.Name() } + +func (oc *contractTransmitter) UpdateRoutes(activeCoordinator common.Address, proposedCoordinator common.Address) error { + // transmitter only cares about the active coordinator + previousContract := oc.contractAddress.Swap(&activeCoordinator) + if previousContract != nil && *previousContract == activeCoordinator { + return nil + } + err := oc.lp.RegisterFilter(logpoller.Filter{Name: transmitterFilterName(activeCoordinator), EventSigs: []common.Hash{oc.transmittedEventSig}, Addresses: []common.Address{activeCoordinator}}) + if err != nil { + return err + } + // TODO: unregister old filter (needs refactor to get pg.Queryer) + return nil +} diff --git a/core/services/relay/evm/functions/contract_transmitter_test.go b/core/services/relay/evm/functions/contract_transmitter_test.go index b8bd98473da..fb4a071de2a 100644 --- a/core/services/relay/evm/functions/contract_transmitter_test.go +++ b/core/services/relay/evm/functions/contract_transmitter_test.go @@ -50,10 +50,11 @@ func TestContractTransmitter_LatestConfigDigestAndEpoch(t *testing.T) { require.NoError(t, err) lp.On("RegisterFilter", mock.Anything).Return(nil) - functionsTransmitter, err := functions.NewFunctionsContractTransmitter(gethcommon.Address{}, c, contractABI, &mockTransmitter{}, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { + functionsTransmitter, err := functions.NewFunctionsContractTransmitter(c, contractABI, &mockTransmitter{}, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { return &txmgr.TxMeta{}, nil }, 0) require.NoError(t, err) + require.NoError(t, functionsTransmitter.UpdateRoutes(gethcommon.Address{}, gethcommon.Address{})) digest, epoch, err := functionsTransmitter.LatestConfigDigestAndEpoch(testutils.Context(t)) require.NoError(t, err) @@ -74,10 +75,11 @@ func TestContractTransmitter_Transmit_V0(t *testing.T) { lp.On("RegisterFilter", mock.Anything).Return(nil) ocrTransmitter := mockTransmitter{} - ot, err := functions.NewFunctionsContractTransmitter(destAddress, c, contractABI, &ocrTransmitter, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { + ot, err := functions.NewFunctionsContractTransmitter(c, contractABI, &ocrTransmitter, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { return &txmgr.TxMeta{}, nil }, contractVersion) require.NoError(t, err) + require.NoError(t, ot.UpdateRoutes(destAddress, destAddress)) require.NoError(t, ot.Transmit(testutils.Context(t), ocrtypes.ReportContext{}, []byte("bar"), []ocrtypes.AttributedOnchainSignature{})) require.Equal(t, destAddress, ocrTransmitter.toAddress) @@ -95,10 +97,11 @@ func TestContractTransmitter_Transmit_V1(t *testing.T) { lp.On("RegisterFilter", mock.Anything).Return(nil) ocrTransmitter := mockTransmitter{} - ot, err := functions.NewFunctionsContractTransmitter(configuredDestAddress, c, contractABI, &ocrTransmitter, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { + ot, err := functions.NewFunctionsContractTransmitter(c, contractABI, &ocrTransmitter, lp, lggr, func(b []byte) (*txmgr.TxMeta, error) { return &txmgr.TxMeta{}, nil }, contractVersion) require.NoError(t, err) + require.NoError(t, ot.UpdateRoutes(configuredDestAddress, configuredDestAddress)) reqId, err := hex.DecodeString("000102030405060708090a0b0c0d0e0f000102030405060708090a0b0c0d0e0f") require.NoError(t, err) diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index a1ca2f12dbb..660c93a5a53 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -2,6 +2,7 @@ package functions import ( "context" + "sync" "github.com/ethereum/go-ethereum/common" @@ -11,21 +12,31 @@ import ( ) type logPollerWrapper struct { - logPoller logpoller.LogPoller - lggr logger.Logger + routerContract common.Address + contractVersion uint32 + logPoller logpoller.LogPoller + subscribers map[string]evmRelayTypes.RouteUpdateSubscriber + mu sync.RWMutex + lggr logger.Logger } var _ evmRelayTypes.LogPollerWrapper = &logPollerWrapper{} -func NewLogPollerWrapper(logPoller logpoller.LogPoller, lggr logger.Logger) evmRelayTypes.LogPollerWrapper { +func NewLogPollerWrapper(routerContract common.Address, contractVersion uint32, logPoller logpoller.LogPoller, lggr logger.Logger) evmRelayTypes.LogPollerWrapper { return &logPollerWrapper{ - logPoller: logPoller, - lggr: lggr, + routerContract: routerContract, + contractVersion: contractVersion, + logPoller: logPoller, + subscribers: make(map[string]evmRelayTypes.RouteUpdateSubscriber), + lggr: lggr, } } // TODO(FUN-381): Implement LogPollerWrapper with an API suiting all users. func (l *logPollerWrapper) Start(context.Context) error { + // TODO periodically update active and proposed coordinator contract addresses + // update own Logpoller filters accordingly + // push to all subscribers return nil } func (l *logPollerWrapper) Close() error { @@ -44,6 +55,29 @@ func (l *logPollerWrapper) Ready() error { return nil } -func (l *logPollerWrapper) LatestRoutes() (activeCoordinator common.Address, proposedCoordinator common.Address, err error) { - return common.Address{}, common.Address{}, nil +// "public" methods of LogPollerWrapper +func (l *logPollerWrapper) LatestRequests() ([]evmRelayTypes.OracleRequest, error) { + // TODO poll both active and proposed coordinators for requests and parse them + return nil, nil +} + +func (l *logPollerWrapper) LatestResponses() ([]evmRelayTypes.OracleResponse, error) { + // TODO poll both active and proposed coordinators for responses and parse them + return nil, nil +} + +// "internal" method called only by EVM relayer components +func (l *logPollerWrapper) SubscribeToUpdates(subscriberName string, subscriber evmRelayTypes.RouteUpdateSubscriber) { + if l.contractVersion == 0 { + // in V0, immediately set contract address to Oracle contract and never update again + err := subscriber.UpdateRoutes(l.routerContract, l.routerContract) + l.lggr.Errorw("LogPollerWrapper: Failed to update routes", "subscriberName", subscriberName, "error", err) + } else if l.contractVersion == 1 { + l.mu.Lock() + defer l.mu.Unlock() + l.subscribers[subscriberName] = subscriber + + // TODO remove when periodic updates are ready + _ = subscriber.UpdateRoutes(l.routerContract, l.routerContract) + } } diff --git a/core/services/relay/evm/functions/offchain_config_digester.go b/core/services/relay/evm/functions/offchain_config_digester.go index 9c8da5a01bb..b4467543d98 100644 --- a/core/services/relay/evm/functions/offchain_config_digester.go +++ b/core/services/relay/evm/functions/offchain_config_digester.go @@ -4,15 +4,19 @@ import ( "encoding/binary" "errors" "fmt" + "sync/atomic" "github.com/ethereum/go-ethereum/common" "github.com/smartcontractkit/libocr/offchainreporting2/chains/evmutil" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaytypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" ) var ( - _ types.OffchainConfigDigester = functionsOffchainConfigDigester{} - FunctionsDigestPrefix = types.ConfigDigestPrefixEVM + _ types.OffchainConfigDigester = &functionsOffchainConfigDigester{} + _ relaytypes.RouteUpdateSubscriber = &functionsOffchainConfigDigester{} + FunctionsDigestPrefix = types.ConfigDigestPrefixEVM // In order to support multiple OCR plugins with a single jobspec & OCR2Base contract, each plugin must have a unique config digest. // This is accomplished by overriding the single config digest from the contract with a unique prefix for each plugin via this custom offchain digester & config poller. ThresholdDigestPrefix = types.ConfigDigestPrefix(7) @@ -22,21 +26,24 @@ var ( type functionsOffchainConfigDigester struct { pluginType FunctionsPluginType chainID uint64 - contractAddress common.Address + contractAddress atomic.Pointer[common.Address] } -func NewFunctionsOffchainConfigDigester(pluginType FunctionsPluginType, chainID uint64, contractAddress common.Address) *functionsOffchainConfigDigester { +func NewFunctionsOffchainConfigDigester(pluginType FunctionsPluginType, chainID uint64) *functionsOffchainConfigDigester { return &functionsOffchainConfigDigester{ - pluginType: pluginType, - chainID: chainID, - contractAddress: contractAddress, + pluginType: pluginType, + chainID: chainID, } } -func (d functionsOffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.ConfigDigest, error) { +func (d *functionsOffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.ConfigDigest, error) { + contractAddress := d.contractAddress.Load() + if contractAddress == nil { + return types.ConfigDigest{}, errors.New("contract address not set") + } baseDigester := evmutil.EVMOffchainConfigDigester{ ChainID: d.chainID, - ContractAddress: d.contractAddress, + ContractAddress: *contractAddress, } configDigest, err := baseDigester.ConfigDigest(cc) @@ -61,7 +68,7 @@ func (d functionsOffchainConfigDigester) ConfigDigest(cc types.ContractConfig) ( return configDigest, nil } -func (d functionsOffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDigestPrefix, error) { +func (d *functionsOffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDigestPrefix, error) { switch d.pluginType { case FunctionsPlugin: return FunctionsDigestPrefix, nil @@ -73,3 +80,9 @@ func (d functionsOffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDiges return 0, fmt.Errorf("unknown plugin type: %v", d.pluginType) } } + +// called from LogPollerWrapper in a separate goroutine +func (d *functionsOffchainConfigDigester) UpdateRoutes(activeCoordinator common.Address, proposedCoordinator common.Address) error { + d.contractAddress.Store(&activeCoordinator) + return nil +} diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index f1c5f76be50..5954a228c8a 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -41,8 +41,24 @@ type FunctionsProvider interface { LogPollerWrapper() LogPollerWrapper } +type OracleRequest struct { + // TODO: define +} + +type OracleResponse struct { + // TODO: define +} + +type RouteUpdateSubscriber interface { + UpdateRoutes(activeCoordinator common.Address, proposedCoordinator common.Address) error +} + // A LogPoller wrapper that understands router proxy contracts type LogPollerWrapper interface { relaytypes.Service - LatestRoutes() (activeCoordinator common.Address, proposedCoordinator common.Address, err error) + LatestRequests() ([]OracleRequest, error) + LatestResponses() ([]OracleResponse, error) + + // TODO (FUN-668): Remove from the LOOP interface and only use internally within the EVM relayer + SubscribeToUpdates(name string, subscriber RouteUpdateSubscriber) } From c5f83e6a5f7e9f0bd8fc552a2d7a32daaac00224 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Sat, 29 Jul 2023 22:42:28 -0400 Subject: [PATCH 034/270] [Functions] Gas Golf for Rens (#9963) * golf acceptTermsOfService * golf createSubscription * packing them structs * Golf Commitment a bit more * golf deployment cost (doesn't count :( ) * golf storage layout FunctionsSubscriptions * Storage layout of FunctionsBilling * add foundry setup test * Mostly comments and code improvements + micro golf * I'm so sorry for stealing the mapping Deividas * This doesn't give points but has annoyed me for too long OCR2 doesn't pack nicely, even though it could combine s_owner, s_configCount and s_latestConfigBlockNumber into the same slot. My issue is mostly with ConfirmedOwnerWithProposal somehow making s_owner completely unpackable by following it with the not remotely as useful s_pendingOwner. Again, no gas savings for this competition but let's all agree that this is simply wrong * removing unused imports * unchecked ++i, please don't use this in prod * fix rebase issues * pack Commitment struct * pack Commitment * no gas in measurement but saves a storage slot * fix test, add type safety to config * undo ConfirmedOwnerWithProposal which has 0 gas impact 0 in the gas measurement test, but non-zero in setting OCR configs but since this is a shared file and CI is very angry if old contracts change Ill just undo this part * Revert v0_0_0 changes * Remove unchecked loop increments, replace with comments documenting bounds * Regenerate geth wrappers * (test): Amend go integration test client contract method --------- Co-authored-by: Rens Rooimans --- contracts/foundry.toml | 2 +- .../v0.8/functions/dev/1_0_0/Functions.sol | 4 +- .../functions/dev/1_0_0/FunctionsBilling.sol | 64 ++--- .../functions/dev/1_0_0/FunctionsClient.sol | 2 - .../dev/1_0_0/FunctionsCoordinator.sol | 15 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 13 +- .../dev/1_0_0/FunctionsSubscriptions.sol | 66 +++-- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 57 ++-- .../accessControl/TermsOfServiceAllowList.sol | 98 +++---- .../interfaces/ITermsOfServiceAllowList.sol | 4 +- .../1_0_0/example/FunctionsClientExample.sol | 29 +-- .../1_0_0/interfaces/IFunctionsBilling.sol | 6 +- .../interfaces/IFunctionsCoordinator.sol | 2 +- .../interfaces/IFunctionsSubscriptions.sol | 2 +- .../functions/dev/1_0_0/ocr/OCR2Abstract.sol | 2 +- .../v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol | 35 +-- .../tests/1_0_0/FunctionsRouter.t.sol | 118 +++++++++ .../FunctionsCoordinatorTestHelper.sol | 4 +- .../v.4.8.0/contracts/utils/Address.sol | 244 ++++++++++++++++++ .../test/v0.8/functions/v1/GasGolf.test.ts | 8 +- .../functions_allow_list.go | 2 +- .../functions_client_example.go | 108 ++++---- .../functions_coordinator.go | 16 +- .../functions_router/functions_router.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 8 +- .../v1/internal/testutils.go | 2 +- 26 files changed, 639 insertions(+), 274 deletions(-) create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol create mode 100644 contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol diff --git a/contracts/foundry.toml b/contracts/foundry.toml index b8e157b69c8..f7b3f8b39ad 100644 --- a/contracts/foundry.toml +++ b/contracts/foundry.toml @@ -17,7 +17,7 @@ block_timestamp = 1234567890 block_number = 12345 [profile.functions] -solc_version = '0.8.6' +solc_version = '0.8.19' src = 'src/v0.8/functions' test = 'src/v0.8/functions/tests' diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol b/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol index d6f9fc4efde..2c59102fd5e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol @@ -59,7 +59,7 @@ library Functions { if (self.args.length > 0) { CBOR.writeString(buffer, "args"); CBOR.startArray(buffer); - for (uint256 i = 0; i < self.args.length; i++) { + for (uint256 i = 0; i < self.args.length; ++i) { CBOR.writeString(buffer, self.args[i]); } CBOR.endSequence(buffer); @@ -78,7 +78,7 @@ library Functions { if (self.bytesArgs.length > 0) { CBOR.writeString(buffer, "bytesArgs"); CBOR.startArray(buffer); - for (uint256 i = 0; i < self.bytesArgs.length; i++) { + for (uint256 i = 0; i < self.bytesArgs.length; ++i) { CBOR.writeBytes(buffer, self.bytesArgs[i]); } CBOR.endSequence(buffer); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 9dfd98e4424..a53353f61c0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -7,7 +7,6 @@ import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol" import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {FulfillResult} from "./FulfillResultCodes.sol"; -import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; /** * @title Functions Billing contract @@ -15,22 +14,21 @@ import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/con * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ abstract contract FunctionsBilling is Routable, IFunctionsBilling { - AggregatorV3Interface private LINK_TO_NATIVE_FEED; - // ================================================================ // | Request Commitment state | // ================================================================ + struct Commitment { - uint64 subscriptionId; - address client; - uint32 callbackGasLimit; + uint64 subscriptionId; // ---------┐ + address client; // | + uint32 callbackGasLimit; // -------┘ + address don; // -------------------┐ + uint96 adminFee; // ---------------┘ + uint96 estimatedTotalCostJuels; // ┐ + uint80 donFee; // | + uint32 timestamp; // | + uint40 gasOverhead; // ------------┘ uint256 expectedGasPrice; - address don; - uint96 donFee; - uint96 adminFee; - uint96 estimatedTotalCostJuels; - uint256 gasOverhead; - uint256 timestamp; } mapping(bytes32 requestId => Commitment) private s_requestCommitments; @@ -39,8 +37,9 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ // | Configuration state | // ================================================================ + struct Config { - // Maxiumum amount of gas that can be given to a request's client callback + // Maximum amount of gas that can be given to a request's client callback uint32 maxCallbackGasLimit; // feedStalenessSeconds is how long before we consider the feed price to be stale // and fallback to fallbackNativePerUnitLink. @@ -53,16 +52,18 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // how many seconds it takes before we consider a request to be timed out uint32 requestTimeoutSeconds; // additional flat fee (in Juels of LINK) that will be split between Node Operators - uint96 donFee; - // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale - int256 fallbackNativePerUnitLink; + // Max value is 2^80 - 1 == 1.2m LINK. + uint80 donFee; // The highest support request data version supported by the node // All lower versions should also be supported uint16 maxSupportedRequestDataVersion; // Percentage of gas price overestimation to account for changes in gas price between request and response // Held as basis points (one hundredth of 1 percentage point) uint256 fulfillmentGasPriceOverEstimationBP; + // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale + int256 fallbackNativePerUnitLink; } + Config private s_config; event ConfigChanged( uint32 maxCallbackGasLimit, @@ -70,7 +71,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint32 gasOverheadBeforeCallback, uint32 gasOverheadAfterCallback, int256 fallbackNativePerUnitLink, - uint96 donFee, + uint80 donFee, uint16 maxSupportedRequestDataVersion, uint256 fulfillmentGasPriceOverEstimationBP ); @@ -88,9 +89,12 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ // | Balance state | // ================================================================ + mapping(address transmitter => uint96 balanceJuelsLink) private s_withdrawableTokens; // Pool together DON fees and disperse them on withdrawal - uint96 s_feePool; + uint96 internal s_feePool; + + AggregatorV3Interface private s_linkToNativeFeed; // ================================================================ // | Cost Events | @@ -109,7 +113,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // | Initialization | // ================================================================ constructor(address router, bytes memory config, address linkToNativeFeed) Routable(router, config) { - LINK_TO_NATIVE_FEED = AggregatorV3Interface(linkToNativeFeed); + s_linkToNativeFeed = AggregatorV3Interface(linkToNativeFeed); } // ================================================================ @@ -128,10 +132,10 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint32 gasOverheadBeforeCallback, int256 fallbackNativePerUnitLink, uint32 requestTimeoutSeconds, - uint96 donFee, + uint80 donFee, uint16 maxSupportedRequestDataVersion, uint256 fulfillmentGasPriceOverEstimationBP - ) = abi.decode(config, (uint32, uint32, uint32, uint32, int256, uint32, uint96, uint16, uint256)); + ) = abi.decode(config, (uint32, uint32, uint32, uint32, int256, uint32, uint80, uint16, uint256)); if (fallbackNativePerUnitLink <= 0) { revert InvalidLinkWeiPrice(fallbackNativePerUnitLink); @@ -183,7 +187,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { s_config.gasOverheadAfterCallback, s_config.fallbackNativePerUnitLink, s_config.gasOverheadBeforeCallback, - address(LINK_TO_NATIVE_FEED), + address(s_linkToNativeFeed), s_config.maxSupportedRequestDataVersion, s_config.fulfillmentGasPriceOverEstimationBP ); @@ -198,7 +202,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { function getDONFee( bytes memory /* requestData */, RequestBilling memory /* billing */ - ) public view override returns (uint96) { + ) public view override returns (uint80) { // NOTE: Optionally, compute additional fee here return s_config.donFee; } @@ -217,7 +221,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { function getFeedData() public view returns (int256) { uint32 feedStalenessSeconds = s_config.feedStalenessSeconds; bool staleFallback = feedStalenessSeconds > 0; - (, int256 weiPerUnitLink, , uint256 timestamp, ) = LINK_TO_NATIVE_FEED.latestRoundData(); + (, int256 weiPerUnitLink, , uint256 timestamp, ) = s_linkToNativeFeed.latestRoundData(); // solhint-disable-next-line not-rely-on-time if (staleFallback && feedStalenessSeconds < block.timestamp - timestamp) { weiPerUnitLink = s_config.fallbackNativePerUnitLink; @@ -300,7 +304,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } // Check that subscription can afford the estimated cost - uint96 donFee = getDONFee(data, billing); + uint80 donFee = getDONFee(data, billing); uint96 adminFee = getAdminFee(data, billing); uint96 estimatedCost = _calculateCostEstimate(billing.callbackGasLimit, billing.expectedGasPrice, donFee, adminFee); IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(s_router)); @@ -317,13 +321,13 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { billing.subscriptionId, billing.client, billing.callbackGasLimit, - billing.expectedGasPrice, address(this), - donFee, adminFee, estimatedCost, + donFee, + uint32(block.timestamp), s_config.gasOverheadBeforeCallback + s_config.gasOverheadAfterCallback, - block.timestamp + billing.expectedGasPrice ); s_requestCommitments[requestId] = commitment; @@ -455,13 +459,13 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { function _disperseFeePool() internal { // All transmitters are assumed to also be observers // Pay out the DON fee to all transmitters - // Bounded by "maxNumOracles" on OCR2Abstract.sol address[] memory transmitters = _getTransmitters(); if (transmitters.length == 0) { revert NoTransmittersSet(); } uint96 feePoolShare = s_feePool / uint96(transmitters.length); - for (uint8 i = 0; i < transmitters.length; i++) { + // Bounded by "maxNumOracles" on OCR2Abstract.sol + for (uint8 i = 0; i < transmitters.length; ++i) { s_withdrawableTokens[transmitters[i]] += feePoolShare; } s_feePool -= feePoolShare * uint96(transmitters.length); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol index 05f8cab1c19..d05c1c68130 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol @@ -4,8 +4,6 @@ pragma solidity ^0.8.19; import {Functions} from "./Functions.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsClient} from "./interfaces/IFunctionsClient.sol"; -import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; -import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; /** * @title The Chainlink Functions client contract diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 0098d4a1dbc..0b2e4fcf3bf 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -96,8 +96,9 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli * @dev check if node is in current transmitter list */ function _isTransmitter(address node) internal view returns (bool) { - address[] memory nodes = this.transmitters(); - for (uint256 i = 0; i < nodes.length; i++) { + address[] memory nodes = s_transmitters; + // Bounded by "maxNumOracles" on OCR2Abstract.sol + for (uint256 i = 0; i < nodes.length; ++i) { if (nodes[i] == node) { return true; } @@ -131,9 +132,10 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli * @inheritdoc IFunctionsCoordinator */ function getAllNodePublicKeys() external view override returns (address[] memory, bytes[] memory) { - address[] memory nodes = this.transmitters(); + address[] memory nodes = s_transmitters; bytes[] memory keys = new bytes[](nodes.length); - for (uint256 i = 0; i < nodes.length; i++) { + // Bounded by "maxNumOracles" on OCR2Abstract.sol + for (uint256 i = 0; i < nodes.length; ++i) { if (s_nodePublicKeys[nodes[i]].length == 0) { revert EmptyPublicKey(); } @@ -208,7 +210,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli uint256 /*initialGas*/, address /*transmitter*/, uint8 /*signerCount*/, - address[maxNumOracles] memory /*signers*/, + address[MAX_NUM_ORACLES] memory /*signers*/, bytes calldata report ) internal override { bytes32[] memory requestIds; @@ -224,7 +226,8 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli revert ReportInvalid(); } - for (uint256 i = 0; i < requestIds.length; i++) { + // Bounded by "MaxRequestBatchSize" on the Job's ReportingPluginConfig + for (uint256 i = 0; i < requestIds.length; ++i) { FulfillResult result = FulfillResult( _fulfillAndBill( requestIds[i], diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index f146dcd33d4..4f2c0b35a86 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -145,9 +145,9 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions ) = IFunctionsCoordinator(coordinatorAddress).sendRequest( IFunctionsCoordinator.Request( msg.sender, - subscriptionId, s_subscriptions[subscriptionId].owner, data, + subscriptionId, dataVersion, _getFlags(subscriptionId), callbackGasLimit @@ -158,14 +158,14 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Store a commitment about the request s_requestCommitments[requestId] = Commitment( + s_config.adminFee, coordinatorAddress, msg.sender, subscriptionId, callbackGasLimit, estimatedCost, - block.timestamp + requestTimeoutSeconds, - gasAfterPaymentCalculation, - s_config.adminFee + uint40(block.timestamp + requestTimeoutSeconds), + uint120(gasAfterPaymentCalculation) ); emit RequestStart( @@ -194,7 +194,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes32 requestId = _sendRequest(donId, true, subscriptionId, reqData, reqDataVersion, callbackGasLimit); // Convert to bytes as a more generic return output = new bytes(32); - for (uint256 i; i < 32; i++) { + // Bounded by 32 + for (uint256 i; i < 32; ++i) { output[i] = requestId[i]; } } @@ -381,7 +382,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } function _onlySenderThatAcceptedToS() internal override { - if (ITermsOfServiceAllowList(_getContractById(ALLOW_LIST_ID, false)).isAllowedSender(msg.sender) == false) { + if (!ITermsOfServiceAllowList(_getContractById(ALLOW_LIST_ID, false)).isAllowedSender(msg.sender)) { revert SenderMustAcceptTermsOfService(msg.sender); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 5c02ab769d0..11653bea8e3 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -13,13 +13,17 @@ import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/con * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677ReceiverInterface { + // Reentrancy guard + bool internal s_reentrancyLock; + error Reentrant(); + // ================================================================ // | Subscription state | // ================================================================ // We make the sub count public so that its possible to // get all the current subscriptions via getSubscription. - uint64 private s_currentsubscriptionId; + uint64 private s_currentSubscriptionId; // s_totalBalance tracks the total LINK sent to/from // this contract through onTokenTransfer, cancelSubscription and oracleWithdraw. @@ -27,6 +31,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // sent tokens using transfer and so we may need to use recoverFunds. uint96 private s_totalBalance; + // link token address + LinkTokenInterface private s_linkToken; + mapping(uint64 subscriptionId => IFunctionsSubscriptions.Subscription) internal s_subscriptions; // We need to maintain a list of addresses that can consume a subscription. @@ -64,14 +71,14 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ struct Commitment { - address coordinator; - address client; - uint64 subscriptionId; - uint32 callbackGasLimit; - uint96 estimatedCost; - uint256 timeoutTimestamp; - uint256 gasAfterPaymentCalculation; - uint96 adminFee; + uint96 adminFee; // -----------┐ + address coordinator; // -------┘ + address client; // ------------┐ + uint64 subscriptionId; // | + uint32 callbackGasLimit; // ---┘ + uint96 estimatedCost; // --------------┐ + uint40 timeoutTimestamp; // | + uint120 gasAfterPaymentCalculation; // ┘ max 1e36 gas } mapping(bytes32 requestId => Commitment) internal s_requestCommitments; @@ -81,20 +88,11 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei uint96 totalCostJuels; } - // ================================================================ - // | Other state | - // ================================================================ - // Reentrancy protection. - bool internal s_reentrancyLock; - error Reentrant(); - - LinkTokenInterface private LINK; - // ================================================================ // | Initialization | // ================================================================ constructor(address link) { - LINK = LinkTokenInterface(link); + s_linkToken = LinkTokenInterface(link); } // ================================================================ @@ -118,7 +116,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @inheritdoc IFunctionsSubscriptions */ function getSubscriptionCount() external view override returns (uint64) { - return s_currentsubscriptionId; + return s_currentSubscriptionId; } /** @@ -247,14 +245,14 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function recoverFunds(address to) external override { _onlyRouterOwner(); - uint256 externalBalance = LINK.balanceOf(address(this)); + uint256 externalBalance = s_linkToken.balanceOf(address(this)); uint256 internalBalance = uint256(s_totalBalance); if (internalBalance > externalBalance) { revert BalanceInvariantViolated(internalBalance, externalBalance); } if (internalBalance < externalBalance) { uint256 amount = externalBalance - internalBalance; - LINK.transfer(to, amount); + s_linkToken.transfer(to, amount); emit FundsRecovered(to, amount); } // If the balances are equal, nothing to be done. @@ -277,8 +275,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } s_withdrawableTokens[address(this)] -= amount; s_totalBalance -= amount; - if (!LINK.transfer(recipient, amount)) { - uint256 externalBalance = LINK.balanceOf(address(this)); + if (!s_linkToken.transfer(recipient, amount)) { + uint256 externalBalance = s_linkToken.balanceOf(address(this)); uint256 internalBalance = uint256(s_totalBalance); revert BalanceInvariantViolated(internalBalance, externalBalance); } @@ -301,7 +299,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } s_withdrawableTokens[msg.sender] -= amount; s_totalBalance -= amount; - if (!LINK.transfer(recipient, amount)) { + if (!s_linkToken.transfer(recipient, amount)) { revert InsufficientBalance(); } } @@ -312,7 +310,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override { _whenNotPaused(); _nonReentrant(); - if (msg.sender != address(LINK)) { + if (msg.sender != address(s_linkToken)) { revert OnlyCallableFromLink(); } if (data.length != 32) { @@ -340,9 +338,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _whenNotPaused(); _nonReentrant(); _onlySenderThatAcceptedToS(); - - s_currentsubscriptionId++; - subscriptionId = s_currentsubscriptionId; + subscriptionId = ++s_currentSubscriptionId; s_subscriptions[subscriptionId] = Subscription({ balance: 0, blockedBalance: 0, @@ -407,7 +403,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // Note bounded by MAX_CONSUMERS address[] memory consumers = s_subscriptions[subscriptionId].consumers; uint256 lastConsumerIndex = consumers.length - 1; - for (uint256 i = 0; i < consumers.length; i++) { + for (uint256 i = 0; i < consumers.length; ++i) { if (consumers[i] == consumer) { address last = consumers[lastConsumerIndex]; // Storage write to preserve last element @@ -464,12 +460,12 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei uint96 balance = sub.balance; // Note bounded by MAX_CONSUMERS; // If no consumers, does nothing. - for (uint256 i = 0; i < sub.consumers.length; i++) { + for (uint256 i = 0; i < sub.consumers.length; ++i) { delete s_consumers[sub.consumers[i]][subscriptionId]; } delete s_subscriptions[subscriptionId]; s_totalBalance -= balance; - if (!LINK.transfer(to, uint256(balance))) { + if (!s_linkToken.transfer(to, uint256(balance))) { revert InsufficientBalance(); } emit SubscriptionCanceled(subscriptionId, to, balance); @@ -484,7 +480,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function _pendingRequestExists(uint64 subscriptionId) internal view returns (bool) { address[] memory consumers = s_subscriptions[subscriptionId].consumers; - for (uint256 i = 0; i < consumers.length; i++) { + // Iterations will not exceed MAX_CONSUMERS + for (uint256 i = 0; i < consumers.length; ++i) { Consumer memory consumer = s_consumers[consumers[i]][subscriptionId]; if (consumer.initiatedRequests != consumer.completedRequests) { return true; @@ -522,7 +519,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external override { _whenNotPaused(); _nonReentrant(); - for (uint256 i = 0; i < requestIdsToTimeout.length; i++) { + for (uint256 i = 0; i < requestIdsToTimeout.length; ++i) { bytes32 requestId = requestIdsToTimeout[i]; Commitment memory request = s_requestCommitments[requestId]; uint64 subscriptionId = request.subscriptionId; @@ -554,6 +551,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ // | Modifiers | // ================================================================ + function _onlySubscriptionOwner(uint64 subscriptionId) internal view { address owner = s_subscriptions[subscriptionId].owner; if (owner == address(0)) { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index 5610f26f264..f77b14b80aa 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -8,13 +8,6 @@ import {Pausable} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/con import {IConfigurable} from "./interfaces/IConfigurable.sol"; abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, ConfirmedOwnerWithProposal { - // ================================================================ - // | Version state | - // ================================================================ - uint16 internal constant s_majorVersion = 1; - uint16 internal s_minorVersion = 0; - uint16 internal s_patchVersion = 0; - // ================================================================ // | Route state | // ================================================================ @@ -26,6 +19,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // ================================================================ // | Proposal state | // ================================================================ + uint8 internal constant MAX_PROPOSAL_SET_LENGTH = 8; struct ContractProposalSet { @@ -61,32 +55,45 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme error InvalidProposal(); error IdentifierIsReserved(bytes32 id); + // ================================================================ + // | Config state | + // ================================================================ + + bytes32 internal s_config_hash; + + error InvalidConfigData(); + + TimeLockProposal internal s_timelockProposal; + // ================================================================ + // | Version state | + // ================================================================ + + uint16 internal constant s_majorVersion = 1; + uint16 internal s_minorVersion = 0; + uint16 internal s_patchVersion = 0; + // ================================================================ // | Timelock state | // ================================================================ - uint16 internal MAXIMUM_TIMELOCK_BLOCKS; + + uint16 internal s_maximumTimelockBlocks; uint16 internal s_timelockBlocks; + struct TimeLockProposal { uint16 from; uint16 to; - uint256 timelockEndBlock; + uint224 timelockEndBlock; } - TimeLockProposal s_timelockProposal; + event TimeLockProposed(uint16 from, uint16 to); event TimeLockUpdated(uint16 from, uint16 to); error ProposedTimelockAboveMaximum(); error TimelockInEffect(); - // ================================================================ - // | Config state | - // ================================================================ - bytes32 internal s_config_hash; - - error InvalidConfigData(); - // ================================================================ // | Initialization | // ================================================================ + constructor( address newOwner, uint16 timelockBlocks, @@ -97,7 +104,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme s_timelockBlocks = timelockBlocks; // Set maximum number of blocks that the timelock can be // NOTE: this cannot be later modified - MAXIMUM_TIMELOCK_BLOCKS = maximumTimelockBlocks; + s_maximumTimelockBlocks = maximumTimelockBlocks; // Set the initial configuration for the Router s_route[routerId] = address(this); _updateConfig(selfConfig); @@ -126,7 +133,8 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme return currentImplementation; } } else { - for (uint8 i = 0; i < s_proposedContractSet.ids.length; i++) { + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { if (id == s_proposedContractSet.ids[i]) { // NOTE: proposals can be used immediately return s_proposedContractSet.to[i]; @@ -173,7 +181,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme revert InvalidProposal(); } // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < idsArrayLength; i++) { + for (uint8 i = 0; i < idsArrayLength; ++i) { bytes32 id = proposedContractSetIds[i]; address proposedContract = proposedContractSetAddresses[i]; if ( @@ -193,7 +201,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme s_proposedContractSet = ContractProposalSet(proposedContractSetIds, proposedContractSetAddresses, timelockEndBlock); // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < proposedContractSetIds.length; i++) { + for (uint8 i = 0; i < proposedContractSetIds.length; ++i) { emit ContractProposed( proposedContractSetIds[i], s_route[proposedContractSetIds[i]], @@ -225,7 +233,8 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme } s_minorVersion = s_minorVersion + 1; if (s_patchVersion != 0) s_patchVersion = 0; - for (uint8 i = 0; i < s_proposedContractSet.ids.length; i++) { + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { bytes32 id = s_proposedContractSet.ids[i]; address from = s_route[id]; address to = s_proposedContractSet.to[i]; @@ -300,10 +309,10 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme if (s_timelockBlocks == blocks) { revert InvalidProposal(); } - if (blocks > MAXIMUM_TIMELOCK_BLOCKS) { + if (blocks > s_maximumTimelockBlocks) { revert ProposedTimelockAboveMaximum(); } - s_timelockProposal = TimeLockProposal(s_timelockBlocks, blocks, block.number + s_timelockBlocks); + s_timelockProposal = TimeLockProposal(s_timelockBlocks, blocks, uint224(block.number + s_timelockBlocks)); } /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index 59920c65f41..7c9c1d8be61 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -1,41 +1,46 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {EnumerableSet} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.sol"; import {Routable, ITypeAndVersion} from "../Routable.sol"; -import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; + +import {Address} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol"; /** * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service */ - contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { - using EnumerableSet for EnumerableSet.AddressSet; + using Address for address; - EnumerableSet.AddressSet private s_allowedSenders; - EnumerableSet.AddressSet private s_blockedSenders; + mapping(address => bool) private s_allowedSenders; + mapping(address => bool) private s_blockedSenders; error InvalidProof(); error RecipientIsBlocked(); + // ================================================================ // | Configuration state | // ================================================================ + struct Config { bool enabled; address proofSignerPublicKey; } + Config private s_config; + event ConfigSet(bool enabled); // ================================================================ // | Initialization | // ================================================================ + constructor(address router, bytes memory config) Routable(router, config) {} // ================================================================ // | Configuration methods | // ================================================================ + /** * @notice Sets the configuration * @param config bytes of config data to set the following: @@ -58,6 +63,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { // ================================================================ // | Terms of Service methods | // ================================================================ + /** * @inheritdoc ITermsOfServiceAllowList */ @@ -76,116 +82,98 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { * @inheritdoc ITermsOfServiceAllowList */ function acceptTermsOfService(address acceptor, address recipient, bytes calldata proof) external override { - if (s_blockedSenders.contains(recipient)) { + if (s_blockedSenders[recipient]) { revert RecipientIsBlocked(); } // Validate that the proof is correct and has been signed - bytes32 messageHash = getMessageHash(acceptor, recipient); - bytes32 ethSignedMessageHash = getEthSignedMessageHash(messageHash); - address proofSigner = _getSigner(ethSignedMessageHash, proof); - if (proofSigner != s_config.proofSignerPublicKey) { - revert InvalidProof(); - } - - // Check if msg.sender is an EoA or contract - bool callerIsContractAccount = _isContract(msg.sender); - // If EoA, validate that msg.sender == acceptor == recipient - // This is to prevent EoAs from accepting for other EoAs - if (callerIsContractAccount == false && (msg.sender != acceptor || msg.sender != recipient)) { + if ( + _getSigner(getEthSignedMessageHash(getMessageHash(acceptor, recipient)), proof) != s_config.proofSignerPublicKey + ) { revert InvalidProof(); } // If contract, validate that msg.sender == recipient // This is to prevent EoAs from claiming contracts that they are not in control of - if (callerIsContractAccount && msg.sender != recipient) { + // If EoA, validate that msg.sender == acceptor == recipient + // This is to prevent EoAs from accepting for other EoAs + if (msg.sender != recipient || (msg.sender != acceptor && !msg.sender.isContract())) { revert InvalidProof(); } // Add recipient to the allow list - s_allowedSenders.add(recipient); + s_allowedSenders[recipient] = true; } /** * @inheritdoc ITermsOfServiceAllowList */ function isAllowedSender(address sender) public view override returns (bool) { - if (s_config.enabled == false) { + if (!s_config.enabled) { return true; } - return s_allowedSenders.contains(sender); + return s_allowedSenders[sender]; } /** * @inheritdoc ITermsOfServiceAllowList */ function isBlockedSender(address sender) public view override returns (bool) { - if (s_config.enabled == false) { + if (!s_config.enabled) { return false; } - return s_blockedSenders.contains(sender); + return s_blockedSenders[sender]; } // ================================================================ // | Owner methods | // ================================================================ - /** /** * @inheritdoc ITermsOfServiceAllowList */ function blockSender(address sender) external override onlyRouterOwner { - s_allowedSenders.remove(sender); - s_blockedSenders.add(sender); + s_allowedSenders[sender] = false; + s_blockedSenders[sender] = true; } /** * @inheritdoc ITermsOfServiceAllowList */ function unblockSender(address sender) external override onlyRouterOwner { - s_blockedSenders.remove(sender); + s_blockedSenders[sender] = false; } // ================================================================ - // | Internal helpers | + // | Signature checking | // ================================================================ - // NOTE: a contract account can appear to be an EoA if called during its constructor - // This is not a risk, because they will fail in acceptTermsOfService during acceptor == recipient - function _isContract(address _addr) private view returns (bool isContract) { - uint32 size; - // solhint-disable-next-line no-inline-assembly - assembly { - size := extcodesize(_addr) - } - return (size > 0); - } - function _getSigner(bytes32 _ethSignedMessageHash, bytes memory signature) private pure returns (address) { - (bytes32 r, bytes32 s, uint8 v) = _splitSignature(signature); - return ecrecover(_ethSignedMessageHash, v, r, s); - } + bytes32 r; + bytes32 s; + uint8 v; - function _splitSignature(bytes memory sig) private pure returns (bytes32 r, bytes32 s, uint8 v) { - if (sig.length != 65) { + if (signature.length != 65) { revert InvalidProof(); } // solhint-disable-next-line no-inline-assembly assembly { - /*/ - First 32 bytes stores the length of the signature + /*/ + First 32 bytes stores the length of the signature - add(sig, 32) = pointer of sig + 32 - effectively, skips first 32 bytes of signature + add(sig, 32) = pointer of sig + 32 + effectively, skips first 32 bytes of signature - mload(p) loads next 32 bytes starting at the memory address p into memory - */ + mload(p) loads next 32 bytes starting at the memory address p into memory + */ // first 32 bytes, after the length prefix - r := mload(add(sig, 32)) + r := mload(add(signature, 32)) // second 32 bytes - s := mload(add(sig, 64)) + s := mload(add(signature, 64)) // final byte (first byte of the next 32 bytes) - v := byte(0, mload(add(sig, 96))) + v := byte(0, mload(add(signature, 96))) } + + return ecrecover(_ethSignedMessageHash, v, r, s); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol index ff7ee47d7e5..b362f3a5543 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol @@ -44,13 +44,13 @@ interface ITermsOfServiceAllowList { function acceptTermsOfService(address acceptor, address recipient, bytes calldata proof) external; /** - * @notice Removes a sender's access if already authorized, and disallows re-acceptiong the Terms of Service + * @notice Removes a sender's access if already authorized, and disallows re-accepting the Terms of Service * @param sender - Address of the sender to block */ function blockSender(address sender) external; /** - * @notice Re-allows a previosly blocked sender to accept the Terms of Service + * @notice Re-allows a previously blocked sender to accept the Terms of Service * @param sender - Address of the sender to unblock */ function unblockSender(address sender) external; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol index c183579b975..27d7102fff8 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol @@ -13,11 +13,11 @@ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { uint32 public constant MAX_CALLBACK_GAS = 70_000; - bytes32 public lastRequestId; - bytes32 public lastResponse; - bytes32 public lastError; - uint32 public lastResponseLength; - uint32 public lastErrorLength; + bytes32 public s_lastRequestId; + bytes32 public s_lastResponse; + bytes32 public s_lastError; + uint32 public s_lastResponseLength; + uint32 public s_lastErrorLength; error UnexpectedRequestID(bytes32 requestId); @@ -41,7 +41,7 @@ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { req.initializeRequestForInlineJavaScript(source); if (encryptedSecretsReferences.length > 0) req.addSecretsReference(encryptedSecretsReferences); if (args.length > 0) req.addArgs(args); - lastRequestId = _sendRequest(req, subscriptionId, MAX_CALLBACK_GAS, jobId); + s_lastRequestId = _sendRequest(req, subscriptionId, MAX_CALLBACK_GAS, jobId); } /** @@ -52,23 +52,22 @@ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { * Either response or error parameter will be set, but never both */ function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal override { - if (lastRequestId != requestId) { + if (s_lastRequestId != requestId) { revert UnexpectedRequestID(requestId); } - // Save only the first 32 bytes of reponse/error to always fit within MAX_CALLBACK_GAS - lastResponse = bytesToBytes32(response); - lastResponseLength = uint32(response.length); - lastError = bytesToBytes32(err); - lastErrorLength = uint32(err.length); + // Save only the first 32 bytes of response/error to always fit within MAX_CALLBACK_GAS + s_lastResponse = bytesToBytes32(response); + s_lastResponseLength = uint32(response.length); + s_lastError = bytesToBytes32(err); + s_lastErrorLength = uint32(err.length); } - function bytesToBytes32(bytes memory b) private pure returns (bytes32) { - bytes32 out; + function bytesToBytes32(bytes memory b) private pure returns (bytes32 out) { uint256 maxLen = 32; if (b.length < 32) { maxLen = b.length; } - for (uint256 i = 0; i < maxLen; i++) { + for (uint256 i = 0; i < maxLen; ++i) { out |= bytes32(b[i]) >> (i * 8); } return out; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index 615e3bb9adb..cc0c0394276 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -48,7 +48,7 @@ interface IFunctionsBilling { * @param billing The request's billing configuration * @return fee Cost in Juels (1e18) of LINK */ - function getDONFee(bytes memory requestData, RequestBilling memory billing) external view returns (uint96); + function getDONFee(bytes memory requestData, RequestBilling memory billing) external view returns (uint80); /** * @notice Determine the fee that will be paid to the Router owner for operating the network @@ -59,7 +59,7 @@ interface IFunctionsBilling { function getAdminFee(bytes memory requestData, RequestBilling memory billing) external view returns (uint96); /** - * @notice Estimate the total cost that will be charged to a subscription to make a request: gas re-imbursement, plus DON fee, plus Registry fee + * @notice Estimate the total cost that will be charged to a subscription to make a request: gas re-reimbursement, plus DON fee, plus Registry fee * @param subscriptionId An identifier of the billing account * @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request * @param callbackGasLimit Gas limit for the fulfillment callback @@ -74,7 +74,7 @@ interface IFunctionsBilling { ) external view returns (uint96); /** - * @notice Remove a request comittment that the Router has determined to be stale + * @notice Remove a request commitment that the Router has determined to be stale * @dev Only callable by the Router * @param requestId - The request ID to remove */ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 62f5ad8af3f..2d1e0ed9d45 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -7,9 +7,9 @@ pragma solidity ^0.8.19; interface IFunctionsCoordinator { struct Request { address requestingContract; // The client contract that is sending the request - uint64 subscriptionId; // Identifier of the subscription that will be charged for the request address subscriptionOwner; // The owner of the subscription bytes data; // Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + uint64 subscriptionId; // Identifier of the subscription that will be charged for the request uint16 dataVersion; // The version of the structure of the encoded data bytes32 flags; // Per-subscription flags uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract can utilize diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index bc792cf020d..55c70187d5b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -8,8 +8,8 @@ interface IFunctionsSubscriptions { struct Subscription { // There are only 1e9*1e18 = 1e27 juels in existence, so the balance can fit in uint96 (2^96 ~ 7e28) uint96 balance; // Common LINK balance that is controlled by the Registry to be used for all consumer requests. - uint96 blockedBalance; // LINK balance that is reserved to pay for pending consumer requests. address owner; // Owner can fund/withdraw/cancel the sub. + uint96 blockedBalance; // LINK balance that is reserved to pay for pending consumer requests. address requestedOwner; // For safely transferring sub ownership. // Maintains the list of keys in s_consumers. // We do this for 2 reasons: diff --git a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol index 4d7bbf150df..ea4503a8b7d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Abstract.sol @@ -5,7 +5,7 @@ import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol abstract contract OCR2Abstract is ITypeAndVersion { // Maximum number of oracles the offchain reporting protocol is designed for - uint256 internal constant maxNumOracles = 31; + uint256 internal constant MAX_NUM_ORACLES = 31; /** * @notice triggers a new run of the offchain reporting protocol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol index 7b8d64798e9..b1a5ecbc7c5 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol @@ -16,6 +16,7 @@ import {OCR2Abstract} from "./OCR2Abstract.sol"; */ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { error ReportInvalid(); + error InvalidConfig(string message); bool internal immutable i_uniqueReports; @@ -25,6 +26,12 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { uint256 private constant maxUint32 = (1 << 32) - 1; + // incremented each time a new config is posted. This count is incorporated + // into the config digest, to prevent replay attacks. + uint32 internal s_configCount; + uint32 internal s_latestConfigBlockNumber; // makes it easier for offchain systems + // to extract config from logs. + // Storing these fields used on the hot path in a ConfigInfo variable reduces the // retrieval of all of them to a single SLOAD. If any further fields are // added, make sure that storage of the struct still takes at most 32 bytes. @@ -35,12 +42,6 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { } ConfigInfo internal s_configInfo; - // incremented each time a new config is posted. This count is incorporated - // into the config digest, to prevent replay attacks. - uint32 internal s_configCount; - uint32 internal s_latestConfigBlockNumber; // makes it easier for offchain systems - // to extract config from logs. - // Used for s_oracles[a].role, where a is an address, to track the purpose // of the address, or to indicate that the address is unset. enum Role { @@ -75,14 +76,14 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { // Reverts transaction if config args are invalid modifier checkConfigValid( - uint256 _numSigners, - uint256 _numTransmitters, - uint256 _f + uint256 numSigners, + uint256 numTransmitters, + uint256 f ) { - require(_numSigners <= maxNumOracles, "too many signers"); - require(_f > 0, "f must be positive"); - require(_numSigners == _numTransmitters, "oracle addresses out of registration"); - require(_numSigners > 3 * _f, "faulty-oracle f too high"); + if (numSigners > MAX_NUM_ORACLES) revert InvalidConfig("too many signers"); + if (f == 0) revert InvalidConfig("f must be positive"); + if (numSigners != numTransmitters) revert InvalidConfig("oracle addresses out of registration"); + if (numSigners <= 3 * f) revert InvalidConfig("faulty-oracle f too high"); _; } @@ -145,7 +146,8 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { s_transmitters.pop(); } - for (uint256 i = 0; i < args.signers.length; ++i) { + // Bounded by MAX_NUM_ORACLES in OCR2Abstract.sol + for (uint256 i = 0; i < args.signers.length; i++) { // add new signer/transmitter addresses require(s_oracles[args.signers[i]].role == Role.Unset, "repeated signer address"); s_oracles[args.signers[i]] = Oracle(uint8(i), Role.Signer); @@ -270,7 +272,7 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { uint256 initialGas, address transmitter, uint8 signerCount, - address[maxNumOracles] memory signers, + address[MAX_NUM_ORACLES] memory signers, bytes calldata report ) internal virtual; @@ -360,7 +362,7 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { ); } - address[maxNumOracles] memory signed; + address[MAX_NUM_ORACLES] memory signed; uint8 signerCount = 0; { @@ -368,6 +370,7 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { bytes32 h = keccak256(abi.encodePacked(keccak256(report), reportContext)); Oracle memory o; + // Bounded by MAX_NUM_ORACLES in OCR2Abstract.sol for (uint256 i = 0; i < rs.length; ++i) { address signer = ecrecover(h, uint8(rawVs[i]) + 27, rs[i], ss[i]); o = s_oracles[signer]; diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol new file mode 100644 index 00000000000..5c415cc5f82 --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -0,0 +1,118 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {BaseTest} from "./BaseTest.t.sol"; +import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; +import {FunctionsCoordinator} from "../../dev/1_0_0/FunctionsCoordinator.sol"; +import {FunctionsBilling} from "../../dev/1_0_0/FunctionsBilling.sol"; +import {MockV3Aggregator} from "../../../tests/MockV3Aggregator.sol"; +import {TermsOfServiceAllowList} from "../../dev/1_0_0/accessControl/TermsOfServiceAllowList.sol"; + +contract FunctionsRouterSetup is BaseTest { + FunctionsRouter internal s_functionsRouter; + FunctionsCoordinator internal s_functionsCoordinator; + MockV3Aggregator internal s_linkEthFeed; + TermsOfServiceAllowList internal s_termsOfServiceAllowList; + + uint16 internal s_timelockBlocks = 0; + uint16 internal s_maximumTimelockBlocks = 20; + uint96 internal s_adminFee = 561724823; + bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; + + address internal s_linkToken = 0x01BE23585060835E02B77ef475b0Cc51aA1e0709; + + int256 internal LINK_ETH_RATE = 5021530000000000; + + function setUp() public virtual override { + BaseTest.setUp(); + s_functionsRouter = new FunctionsRouter(s_timelockBlocks, s_maximumTimelockBlocks, s_linkToken, getRouterConfig()); + s_linkEthFeed = new MockV3Aggregator(0, LINK_ETH_RATE); + + s_termsOfServiceAllowList = new TermsOfServiceAllowList(address(s_functionsRouter), getTermsOfServiceConfig()); + } + + function getRouterConfig() public view returns (bytes memory) { + uint32[] memory maxCallbackGasLimits = new uint32[](1); + maxCallbackGasLimits[0] = type(uint32).max; + + // First create the struct to get some type safety + FunctionsRouter.Config memory routerConfig = FunctionsRouter.Config({ + adminFee: s_adminFee, + handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, + maxCallbackGasLimits: maxCallbackGasLimits + }); + + return + abi.encode( + routerConfig.adminFee, + routerConfig.handleOracleFulfillmentSelector, + routerConfig.maxCallbackGasLimits + ); + } + + function getCoordinatorConfig() public pure returns (bytes memory) { + FunctionsBilling.Config memory billingConfig = FunctionsBilling.Config({ + maxCallbackGasLimit: 5, + feedStalenessSeconds: 5, + gasOverheadAfterCallback: 5, + gasOverheadBeforeCallback: 5, + requestTimeoutSeconds: 1, + donFee: 5, + maxSupportedRequestDataVersion: 5, + fulfillmentGasPriceOverEstimationBP: 5, + fallbackNativePerUnitLink: 2874 + }); + + return + abi.encode( + billingConfig.maxCallbackGasLimit, + billingConfig.feedStalenessSeconds, + billingConfig.gasOverheadBeforeCallback, + billingConfig.gasOverheadAfterCallback, + billingConfig.requestTimeoutSeconds, + billingConfig.donFee, + billingConfig.maxSupportedRequestDataVersion, + billingConfig.fulfillmentGasPriceOverEstimationBP, + billingConfig.fallbackNativePerUnitLink + ); + } + + function getTermsOfServiceConfig() public pure returns (bytes memory) { + bool enabled = false; + address proofSignerPublicKey = address(132); + return abi.encode(enabled, proofSignerPublicKey); + } +} + +contract FunctionsRouter_createSubscription is FunctionsRouterSetup { + event SubscriptionCreated(uint64 indexed subscriptionId, address owner); + + function testCreateSubscriptionSuccess() public { + s_functionsCoordinator = new FunctionsCoordinator( + address(s_functionsRouter), + getCoordinatorConfig(), + address(s_linkEthFeed) + ); + + bytes32 allowListId = s_functionsRouter.getAllowListId(); + bytes32[] memory proposedContractSetIds = new bytes32[](2); + proposedContractSetIds[0] = bytes32("1"); + proposedContractSetIds[1] = allowListId; + address[] memory proposedContractSetAddresses = new address[](2); + proposedContractSetAddresses[0] = address(s_functionsCoordinator); + proposedContractSetAddresses[1] = address(s_termsOfServiceAllowList); + + s_functionsRouter.proposeContractsUpdate(proposedContractSetIds, proposedContractSetAddresses); + s_functionsRouter.updateContracts(); + + vm.expectEmit(); + emit SubscriptionCreated(1, OWNER); + + s_functionsRouter.createSubscription(); + + vm.expectEmit(); + emit SubscriptionCreated(2, OWNER); + + s_functionsRouter.createSubscription(); + } +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol index 0aa46ee8fcb..e2bcd12bfa6 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol @@ -17,13 +17,13 @@ contract FunctionsCoordinatorTestHelper is FunctionsCoordinator { } function callReport(bytes calldata report) external { - address[maxNumOracles] memory signers; + address[MAX_NUM_ORACLES] memory signers; signers[0] = msg.sender; _report(gasleft(), msg.sender, 1, signers, report); } function callReportMultipleSigners(bytes calldata report, address secondSigner) external { - address[maxNumOracles] memory signers; + address[MAX_NUM_ORACLES] memory signers; signers[0] = msg.sender; signers[1] = secondSigner; _report(gasleft(), msg.sender, 2, signers, report); diff --git a/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol b/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol new file mode 100644 index 00000000000..f71f7f93e7f --- /dev/null +++ b/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol @@ -0,0 +1,244 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.8.0) (utils/Address.sol) + +pragma solidity ^0.8.1; + +/** + * @dev Collection of functions related to the address type + */ +library Address { + /** + * @dev Returns true if `account` is a contract. + * + * [IMPORTANT] + * ==== + * It is unsafe to assume that an address for which this function returns + * false is an externally-owned account (EOA) and not a contract. + * + * Among others, `isContract` will return false for the following + * types of addresses: + * + * - an externally-owned account + * - a contract in construction + * - an address where a contract will be created + * - an address where a contract lived, but was destroyed + * ==== + * + * [IMPORTANT] + * ==== + * You shouldn't rely on `isContract` to protect against flash loan attacks! + * + * Preventing calls from contracts is highly discouraged. It breaks composability, breaks support for smart wallets + * like Gnosis Safe, and does not provide security since it can be circumvented by calling from a contract + * constructor. + * ==== + */ + function isContract(address account) internal view returns (bool) { + // This method relies on extcodesize/address.code.length, which returns 0 + // for contracts in construction, since the code is only stored at the end + // of the constructor execution. + + return account.code.length > 0; + } + + /** + * @dev Replacement for Solidity's `transfer`: sends `amount` wei to + * `recipient`, forwarding all available gas and reverting on errors. + * + * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost + * of certain opcodes, possibly making contracts go over the 2300 gas limit + * imposed by `transfer`, making them unable to receive funds via + * `transfer`. {sendValue} removes this limitation. + * + * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. + * + * IMPORTANT: because control is transferred to `recipient`, care must be + * taken to not create reentrancy vulnerabilities. Consider using + * {ReentrancyGuard} or the + * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. + */ + function sendValue(address payable recipient, uint256 amount) internal { + require(address(this).balance >= amount, "Address: insufficient balance"); + + (bool success, ) = recipient.call{value: amount}(""); + require(success, "Address: unable to send value, recipient may have reverted"); + } + + /** + * @dev Performs a Solidity function call using a low level `call`. A + * plain `call` is an unsafe replacement for a function call: use this + * function instead. + * + * If `target` reverts with a revert reason, it is bubbled up by this + * function (like regular Solidity function calls). + * + * Returns the raw returned data. To convert to the expected return value, + * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. + * + * Requirements: + * + * - `target` must be a contract. + * - calling `target` with `data` must not revert. + * + * _Available since v3.1._ + */ + function functionCall(address target, bytes memory data) internal returns (bytes memory) { + return functionCallWithValue(target, data, 0, "Address: low-level call failed"); + } + + /** + * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with + * `errorMessage` as a fallback revert reason when `target` reverts. + * + * _Available since v3.1._ + */ + function functionCall( + address target, + bytes memory data, + string memory errorMessage + ) internal returns (bytes memory) { + return functionCallWithValue(target, data, 0, errorMessage); + } + + /** + * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], + * but also transferring `value` wei to `target`. + * + * Requirements: + * + * - the calling contract must have an ETH balance of at least `value`. + * - the called Solidity function must be `payable`. + * + * _Available since v3.1._ + */ + function functionCallWithValue( + address target, + bytes memory data, + uint256 value + ) internal returns (bytes memory) { + return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); + } + + /** + * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but + * with `errorMessage` as a fallback revert reason when `target` reverts. + * + * _Available since v3.1._ + */ + function functionCallWithValue( + address target, + bytes memory data, + uint256 value, + string memory errorMessage + ) internal returns (bytes memory) { + require(address(this).balance >= value, "Address: insufficient balance for call"); + (bool success, bytes memory returndata) = target.call{value: value}(data); + return verifyCallResultFromTarget(target, success, returndata, errorMessage); + } + + /** + * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], + * but performing a static call. + * + * _Available since v3.3._ + */ + function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { + return functionStaticCall(target, data, "Address: low-level static call failed"); + } + + /** + * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], + * but performing a static call. + * + * _Available since v3.3._ + */ + function functionStaticCall( + address target, + bytes memory data, + string memory errorMessage + ) internal view returns (bytes memory) { + (bool success, bytes memory returndata) = target.staticcall(data); + return verifyCallResultFromTarget(target, success, returndata, errorMessage); + } + + /** + * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], + * but performing a delegate call. + * + * _Available since v3.4._ + */ + function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { + return functionDelegateCall(target, data, "Address: low-level delegate call failed"); + } + + /** + * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], + * but performing a delegate call. + * + * _Available since v3.4._ + */ + function functionDelegateCall( + address target, + bytes memory data, + string memory errorMessage + ) internal returns (bytes memory) { + (bool success, bytes memory returndata) = target.delegatecall(data); + return verifyCallResultFromTarget(target, success, returndata, errorMessage); + } + + /** + * @dev Tool to verify that a low level call to smart-contract was successful, and revert (either by bubbling + * the revert reason or using the provided one) in case of unsuccessful call or if target was not a contract. + * + * _Available since v4.8._ + */ + function verifyCallResultFromTarget( + address target, + bool success, + bytes memory returndata, + string memory errorMessage + ) internal view returns (bytes memory) { + if (success) { + if (returndata.length == 0) { + // only check isContract if the call was successful and the return data is empty + // otherwise we already know that it was a contract + require(isContract(target), "Address: call to non-contract"); + } + return returndata; + } else { + _revert(returndata, errorMessage); + } + } + + /** + * @dev Tool to verify that a low level call was successful, and revert if it wasn't, either by bubbling the + * revert reason or using the provided one. + * + * _Available since v4.3._ + */ + function verifyCallResult( + bool success, + bytes memory returndata, + string memory errorMessage + ) internal pure returns (bytes memory) { + if (success) { + return returndata; + } else { + _revert(returndata, errorMessage); + } + } + + function _revert(bytes memory returndata, string memory errorMessage) private pure { + // Look for revert reason and bubble it up if present + if (returndata.length > 0) { + // The easiest way to bubble the revert reason is using memory via assembly + /// @solidity memory-safe-assembly + assembly { + let returndata_size := mload(returndata) + revert(add(32, returndata), returndata_size) + } + } else { + revert(errorMessage); + } + } +} \ No newline at end of file diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index 3b7958390aa..cc7a7e0f128 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -1,12 +1,12 @@ import { ethers } from 'hardhat' import { BigNumber } from 'ethers' import { - getSetupFactory, + accessControlMockPrivateKey, FunctionsContracts, FunctionsRoles, - ids, getEventArg, - accessControlMockPrivateKey, + getSetupFactory, + ids, } from './utils' import { stringToBytes } from '../../../test-helpers/helpers' @@ -14,7 +14,7 @@ const setup = getSetupFactory() let contracts: FunctionsContracts let roles: FunctionsRoles -const baselineGasUsed = 944_073 +const baselineGasUsed = 754223 // TODO: Update baseline let currentGasUsed = 0 beforeEach(async () => { diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index 21805865db4..f189c72265c 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -32,7 +32,7 @@ var ( var TermsOfServiceAllowListMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isAllowedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b506040516200114238038062001142833981016040819052620000349162000164565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b038416179055620000848162000099565b80516020909101206000555062000292915050565b60008082806020019051810190620000b291906200024f565b6040805180820182528315158082526001600160a01b0384166020928301819052600680546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200014b57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200017857600080fd5b8251620001858162000135565b602084810151919350906001600160401b0380821115620001a557600080fd5b818601915086601f830112620001ba57600080fd5b815181811115620001cf57620001cf6200014e565b604051601f8201601f19908116603f01168101908382118183101715620001fa57620001fa6200014e565b8160405282815289868487010111156200021357600080fd5b600093505b8284101562000237578484018601518185018701529285019262000218565b60008684830101528096505050505050509250929050565b600080604083850312156200026357600080fd5b825180151581146200027457600080fd5b6020840151909250620002878162000135565b809150509250929050565b610ea080620002a26000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80638cc6acce11610076578063a5e1d61d1161005b578063a5e1d61d14610158578063be8c97b01461017b578063fa5408011461018e57600080fd5b80638cc6acce1461013d5780639883c10d1461015057600080fd5b806347663acb116100a757806347663acb146100f657806380e8a1511461010957806382184c7b1461012a57600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb6101ef565b6040516100d89190610af2565b60405180910390f35b6100f46100ef366004610b83565b61020f565b005b6100f4610104366004610c15565b61044c565b61011c610117366004610c32565b610552565b6040519081526020016100d8565b6100f4610138366004610c15565b6105b0565b6100f461014b366004610c9a565b6106be565b60005461011c565b61016b610166366004610c15565b610725565b60405190151581526020016100d8565b61016b610189366004610c15565b610749565b61011c61019c366004610d69565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610e6c60289139905090565b61021a600484610769565b15610251576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061025d8585610552565b905060006102b8826040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b905060006102fc8286868080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061079b92505050565b60065490915073ffffffffffffffffffffffffffffffffffffffff8083166101009092041614610358576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b63ffffffff333b1615801590816103a557503373ffffffffffffffffffffffffffffffffffffffff89161415806103a557503373ffffffffffffffffffffffffffffffffffffffff881614155b156103dc576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8080156103ff57503373ffffffffffffffffffffffffffffffffffffffff881614155b15610436576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610441600288610838565b505050505050505050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156104bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104df9190610d82565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610543576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61054e60048261085a565b5050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561061f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106439190610d82565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106a7576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106b260028261085a565b5061054e600482610838565b60015473ffffffffffffffffffffffffffffffffffffffff16331461070f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107188161087c565b8051602090910120600055565b60065460009060ff161515810361073e57506000919050565b6105aa600483610769565b60065460009060ff161515810361076257506001919050565b6105aa6002835b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b9392505050565b6000806000806107aa85610952565b6040805160008152602081018083528b905260ff8316918101919091526060810184905260808101839052929550909350915060019060a0016020604051602081039080840390855afa158015610805573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b60006107948373ffffffffffffffffffffffffffffffffffffffff84166109b0565b60006107948373ffffffffffffffffffffffffffffffffffffffff84166109ff565b600080828060200190518101906108939190610d9f565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600680547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b60008060008351604114610992576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b50505060208101516040820151606090920151909260009190911a90565b60008181526001830160205260408120546109f7575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556105aa565b5060006105aa565b60008181526001830160205260408120548015610ae8576000610a23600183610dd3565b8554909150600090610a3790600190610dd3565b9050818114610a9c576000866000018281548110610a5757610a57610e0d565b9060005260206000200154905080876000018481548110610a7a57610a7a610e0d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610aad57610aad610e3c565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506105aa565b60009150506105aa565b600060208083528351808285015260005b81811015610b1f57858101830151858201604001528201610b03565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610b8057600080fd5b50565b60008060008060608587031215610b9957600080fd5b8435610ba481610b5e565b93506020850135610bb481610b5e565b9250604085013567ffffffffffffffff80821115610bd157600080fd5b818701915087601f830112610be557600080fd5b813581811115610bf457600080fd5b886020828501011115610c0657600080fd5b95989497505060200194505050565b600060208284031215610c2757600080fd5b813561079481610b5e565b60008060408385031215610c4557600080fd5b8235610c5081610b5e565b91506020830135610c6081610b5e565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610cac57600080fd5b813567ffffffffffffffff80821115610cc457600080fd5b818401915084601f830112610cd857600080fd5b813581811115610cea57610cea610c6b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610d3057610d30610c6b565b81604052828152876020848701011115610d4957600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610d7b57600080fd5b5035919050565b600060208284031215610d9457600080fd5b815161079481610b5e565b60008060408385031215610db257600080fd5b82518015158114610dc257600080fd5b6020840151909250610c6081610b5e565b818103818111156105aa577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", + Bin: "0x60806040523480156200001157600080fd5b5060405162000f9738038062000f97833981016040819052620000349162000164565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b038416179055620000848162000099565b80516020909101206000555062000292915050565b60008082806020019051810190620000b291906200024f565b6040805180820182528315158082526001600160a01b0384166020928301819052600480546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200014b57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200017857600080fd5b8251620001858162000135565b602084810151919350906001600160401b0380821115620001a557600080fd5b818601915086601f830112620001ba57600080fd5b815181811115620001cf57620001cf6200014e565b604051601f8201601f19908116603f01168101908382118183101715620001fa57620001fa6200014e565b8160405282815289868487010111156200021357600080fd5b600093505b8284101562000237578484018601518185018701529285019262000218565b60008684830101528096505050505050509250929050565b600080604083850312156200026357600080fd5b825180151581146200027457600080fd5b6020840151909250620002878162000135565b809150509250929050565b610cf580620002a26000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80638cc6acce11610076578063a5e1d61d1161005b578063a5e1d61d146101b0578063be8c97b0146101d3578063fa540801146101e657600080fd5b80638cc6acce146101955780639883c10d146101a857600080fd5b806347663acb116100a757806347663acb146100f657806380e8a1511461010957806382184c7b1461018257600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb610247565b6040516100d891906109d8565b60405180910390f35b6100f46100ef366004610a69565b610267565b005b6100f4610104366004610afb565b6104a4565b610174610117366004610b1f565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b6040519081526020016100d8565b6100f4610190366004610afb565b6105e7565b6100f46101a3366004610b87565b610742565b600054610174565b6101c36101be366004610afb565b6107a9565b60405190151581526020016100d8565b6101c36101e1366004610afb565b6107ea565b6101746101f4366004610c56565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610cc160289139905090565b73ffffffffffffffffffffffffffffffffffffffff831660009081526003602052604090205460ff16156102c7576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600454610100900473ffffffffffffffffffffffffffffffffffffffff1661038961034d6101f487876040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b84848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061082b92505050565b73ffffffffffffffffffffffffffffffffffffffff16146103d6576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff841614158061041b57503373ffffffffffffffffffffffffffffffffffffffff85161480159061041b5750333b155b15610452576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505073ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905550565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610513573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105379190610c6f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461059b576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610656573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067a9190610c6f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106de576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00908116909155600390925290912080549091166001179055565b60015473ffffffffffffffffffffffffffffffffffffffff163314610793576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61079c81610902565b8051602090910120600055565b60045460009060ff166107be57506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205460ff1690565b60045460009060ff166107ff57506001919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b600080600080845160411461086c576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050602082810151604080850151606080870151835160008082529681018086528a9052951a928501839052840183905260808401819052919260019060a0016020604051602081039080840390855afa1580156108cf573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b600080828060200190518101906109199190610c8c565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600480547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b600060208083528351808285015260005b81811015610a05578581018301518582016040015282016109e9565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a6657600080fd5b50565b60008060008060608587031215610a7f57600080fd5b8435610a8a81610a44565b93506020850135610a9a81610a44565b9250604085013567ffffffffffffffff80821115610ab757600080fd5b818701915087601f830112610acb57600080fd5b813581811115610ada57600080fd5b886020828501011115610aec57600080fd5b95989497505060200194505050565b600060208284031215610b0d57600080fd5b8135610b1881610a44565b9392505050565b60008060408385031215610b3257600080fd5b8235610b3d81610a44565b91506020830135610b4d81610a44565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610b9957600080fd5b813567ffffffffffffffff80821115610bb157600080fd5b818401915084601f830112610bc557600080fd5b813581811115610bd757610bd7610b58565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610c1d57610c1d610b58565b81604052828152876020848701011115610c3657600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610c6857600080fd5b5035919050565b600060208284031215610c8157600080fd5b8151610b1881610a44565b60008060408385031215610c9f57600080fd5b82518015158114610caf57600080fd5b6020840151909250610b4d81610a4456fe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go index 728dcec7f84..7a300aee3f8 100644 --- a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go +++ b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go @@ -31,8 +31,8 @@ var ( ) var FunctionsClientExampleMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b50604051620019ed380380620019ed833981016040819052620000349162000198565b600080546001600160a01b0319166001600160a01b038316178155339081906001600160a01b038216620000af5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600180546001600160a01b0319166001600160a01b0384811691909117909155811615620000e257620000e281620000ec565b50505050620001ca565b336001600160a01b03821603620001465760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a6565b600280546001600160a01b0319166001600160a01b03838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b600060208284031215620001ab57600080fd5b81516001600160a01b0381168114620001c357600080fd5b9392505050565b61181380620001da6000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b48cffea1161005b578063b48cffea14610182578063f2fde38b14610192578063fc2a88c3146101a557600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b80632c29166b116100b25780632c29166b146100ff5780635fa353e71461012c57806362747e421461013f57600080fd5b80630ca76175146100ce57806329f0de3f146100e3575b600080fd5b6100e16100dc36600461125f565b6101ae565b005b6100ec60055481565b6040519081526020015b60405180910390f35b60065461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100e161013a366004611332565b61020f565b6100ec60045481565b6101176201117081565b6100e1610319565b60015460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6006546101179063ffffffff1681565b6100e16101a0366004611416565b61041f565b6100ec60035481565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ff576040517f5099014100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61020a838383610433565b505050565b610217610501565b6102586040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b61029a89898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105849050565b85156102e2576102e287878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105959050565b83156102fc576102fc6102f5858761144c565b82906105df565b61030b81846201117085610622565b600355505050505050505050565b60025473ffffffffffffffffffffffffffffffffffffffff16331461039f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560028054909116905560405173ffffffffffffffffffffffffffffffffffffffff909116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b610427610501565b61043081610646565b50565b8260035414610471576040517fd068bf5b00000000000000000000000000000000000000000000000000000000815260048101849052602401610396565b61047a8261073c565b6004558151600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104bc8161073c565b600555516006805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610396565b565b61059182600080846107c4565b5050565b80516000036105d0576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b805160000361061a576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b60008061062e8661085b565b905061063c81868686610bcc565b9695505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610396565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b600080600060209050602084511015610753575082515b60005b818110156107bb57610769816008611542565b85828151811061077b5761077b611559565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c9290921791806107b381611588565b915050610756565b50909392505050565b80516000036107ff576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83836002811115610812576108126114e4565b90816002811115610825576108256114e4565b9052506040840182801561083b5761083b6114e4565b9081801561084b5761084b6114e4565b9052506060909301929092525050565b6060610865611116565b805161087390610100610ca5565b506108b3816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d1f565b6108d281846000015160028111156108cd576108cd6114e4565b610d38565b610911816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d1f565b61092b81846040015160008111156108cd576108cd6114e4565b61096a816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d1f565b610978818460600151610d1f565b60a08301515115610a1e576109c2816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d1f565b6109cb81610d71565b60005b8360a0015151811015610a1457610a02828560a0015183815181106109f5576109f5611559565b6020026020010151610d1f565b80610a0c81611588565b9150506109ce565b50610a1e81610d95565b60808301515115610b1e57600083602001516002811115610a4157610a416114e4565b03610a78576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ab7816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d1f565b610ad181846020015160028111156108cd576108cd6114e4565b610b10816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d1f565b610b1e818460800151610db3565b60c08301515115610bc457610b68816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d1f565b610b7181610d71565b60005b8360c0015151811015610bba57610ba8828560c001518381518110610b9b57610b9b611559565b6020026020010151610db3565b80610bb281611588565b915050610b74565b50610bc481610d95565b515192915050565b600080546040517f461d276200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063461d276290610c2c9087908990600190899089906004016115c0565b6020604051808303816000875af1158015610c4b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c6f9190611660565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a2949350505050565b604080518082019091526060815260006020820152610cc5602083611679565b15610ced57610cd5602083611679565b610ce09060206116b4565b610cea90836116c7565b91505b602080840183905260405180855260008152908184010181811015610d1157600080fd5b604052508290505b92915050565b610d2c8260038351610dbc565b815161020a9082610ee3565b8151610d459060c2610f0b565b506105918282604051602001610d5d91815260200190565b604051602081830303815290604052610db3565b610d7c816004610f74565b600181602001818151610d8f91906116c7565b90525050565b610da0816007610f74565b600181602001818151610d8f91906116b4565b610d2c82600283515b60178167ffffffffffffffff1611610de9578251610de39060e0600585901b168317610f0b565b50505050565b60ff8167ffffffffffffffff1611610e2b578251610e12906018611fe0600586901b1617610f0b565b508251610de39067ffffffffffffffff83166001610f8b565b61ffff8167ffffffffffffffff1611610e6e578251610e55906019611fe0600586901b1617610f0b565b508251610de39067ffffffffffffffff83166002610f8b565b63ffffffff8167ffffffffffffffff1611610eb3578251610e9a90601a611fe0600586901b1617610f0b565b508251610de39067ffffffffffffffff83166004610f8b565b8251610eca90601b611fe0600586901b1617610f0b565b508251610de39067ffffffffffffffff83166008610f8b565b604080518082019091526060815260006020820152610f0483838451611010565b9392505050565b6040805180820190915260608152600060208201528251516000610f308260016116c7565b905084602001518210610f5157610f5185610f4c836002611542565b6110ff565b8451602083820101858153508051821115610f6a578181525b5093949350505050565b815161020a90601f611fe0600585901b1617610f0b565b6040805180820190915260608152600060208201528351516000610faf82856116c7565b90508560200151811115610fcc57610fcc86610f4c836002611542565b60006001610fdc866101006117fa565b610fe691906116b4565b90508651828101878319825116178152508051831115611004578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561103357600080fd5b835151600061104284836116c7565b9050856020015181111561105f5761105f86610f4c836002611542565b855180518382016020019160009180851115611079578482525b505050602086015b602086106110b957805182526110986020836116c7565b91506110a56020826116c7565b90506110b26020876116b4565b9550611081565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b815161110b8383610ca5565b50610de38382610ee3565b604051806040016040528061113e604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111c1576111c161114b565b604052919050565b600067ffffffffffffffff8311156111e3576111e361114b565b61121460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8601160161117a565b905082815283838301111561122857600080fd5b828260208301376000602084830101529392505050565b600082601f83011261125057600080fd5b610f04838335602085016111c9565b60008060006060848603121561127457600080fd5b83359250602084013567ffffffffffffffff8082111561129357600080fd5b61129f8783880161123f565b935060408601359150808211156112b557600080fd5b506112c28682870161123f565b9150509250925092565b60008083601f8401126112de57600080fd5b50813567ffffffffffffffff8111156112f657600080fd5b60208301915083602082850101111561130e57600080fd5b9250929050565b803567ffffffffffffffff8116811461132d57600080fd5b919050565b60008060008060008060008060a0898b03121561134e57600080fd5b883567ffffffffffffffff8082111561136657600080fd5b6113728c838d016112cc565b909a50985060208b013591508082111561138b57600080fd5b6113978c838d016112cc565b909850965060408b01359150808211156113b057600080fd5b818b0191508b601f8301126113c457600080fd5b8135818111156113d357600080fd5b8c60208260051b85010111156113e857600080fd5b60208301965080955050505061140060608a01611315565b9150608089013590509295985092959890939650565b60006020828403121561142857600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f0457600080fd5b600067ffffffffffffffff808411156114675761146761114b565b8360051b602061147881830161117a565b86815291850191818101903684111561149057600080fd5b865b848110156114d8578035868111156114aa5760008081fd5b880136601f8201126114bc5760008081fd5b6114ca3682358784016111c9565b845250918301918301611492565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d1957610d19611513565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115b9576115b9611513565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156115fe5788810183015185820160c0015282016115e2565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050611647604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561167257600080fd5b5051919050565b6000826116af577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d1957610d19611513565b80820180821115610d1957610d19611513565b600181815b8085111561173357817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561171957611719611513565b8085161561172657918102915b93841c93908002906116df565b509250929050565b60008261174a57506001610d19565b8161175757506000610d19565b816001811461176d576002811461177757611793565b6001915050610d19565b60ff84111561178857611788611513565b50506001821b610d19565b5060208310610133831016604e8410600b84101617156117b6575081810a610d19565b6117c083836116da565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117f2576117f2611513565b029392505050565b6000610f04838361173b56fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60806040523480156200001157600080fd5b50604051620019e3380380620019e3833981016040819052620000349162000198565b600080546001600160a01b0319166001600160a01b038316178155339081906001600160a01b038216620000af5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600180546001600160a01b0319166001600160a01b0384811691909117909155811615620000e257620000e281620000ec565b50505050620001ca565b336001600160a01b03821603620001465760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a6565b600280546001600160a01b0319166001600160a01b03838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b600060208284031215620001ab57600080fd5b81516001600160a01b0381168114620001c357600080fd5b9392505050565b61180980620001da6000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc366004611255565b6101ae565b005b6100ec60045481565b6040519081526020015b60405180910390f35b60065461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60055481565b6100e1610143366004611328565b61020f565b6101176201117081565b6100e1610319565b60015460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60035481565b6100e161019936600461140c565b61041f565b6006546101179063ffffffff1681565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ff576040517f5099014100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61020a838383610433565b505050565b610217610501565b6102586040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b61029a89898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105849050565b85156102e2576102e287878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105959050565b83156102fc576102fc6102f58587611442565b82906105df565b61030b81846201117085610622565b600355505050505050505050565b60025473ffffffffffffffffffffffffffffffffffffffff16331461039f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560028054909116905560405173ffffffffffffffffffffffffffffffffffffffff909116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b610427610501565b61043081610646565b50565b8260035414610471576040517fd068bf5b00000000000000000000000000000000000000000000000000000000815260048101849052602401610396565b61047a8261073c565b6004558151600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104bc8161073c565b600555516006805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610396565b565b61059182600080846107be565b5050565b80516000036105d0576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b805160000361061a576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b60008061062e86610855565b905061063c81868686610bc2565b9695505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610396565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60008060209050602083511015610751575081515b60005b818110156107b757610767816008611538565b8482815181106107795761077961154f565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107b08161157e565b9050610754565b5050919050565b80516000036107f9576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561080c5761080c6114da565b9081600281111561081f5761081f6114da565b90525060408401828015610835576108356114da565b90818015610845576108456114da565b9052506060909301929092525050565b606061085f61110c565b805161086d90610100610c9b565b506108ad816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d15565b6108cc81846000015160028111156108c7576108c76114da565b610d2e565b61090b816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d15565b61092581846040015160008111156108c7576108c76114da565b610964816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d15565b610972818460600151610d15565b60a08301515115610a16576109bc816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d15565b6109c581610d67565b60005b8360a0015151811015610a0c576109fc828560a0015183815181106109ef576109ef61154f565b6020026020010151610d15565b610a058161157e565b90506109c8565b50610a1681610d8b565b60808301515115610b1657600083602001516002811115610a3957610a396114da565b03610a70576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610aaf816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d15565b610ac981846020015160028111156108c7576108c76114da565b610b08816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d15565b610b16818460800151610da9565b60c08301515115610bba57610b60816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d15565b610b6981610d67565b60005b8360c0015151811015610bb057610ba0828560c001518381518110610b9357610b9361154f565b6020026020010151610da9565b610ba98161157e565b9050610b6c565b50610bba81610d8b565b515192915050565b600080546040517f461d276200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063461d276290610c229087908990600190899089906004016115b6565b6020604051808303816000875af1158015610c41573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c659190611656565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a2949350505050565b604080518082019091526060815260006020820152610cbb60208361166f565b15610ce357610ccb60208361166f565b610cd69060206116aa565b610ce090836116bd565b91505b602080840183905260405180855260008152908184010181811015610d0757600080fd5b604052508290505b92915050565b610d228260038351610db2565b815161020a9082610ed9565b8151610d3b9060c2610f01565b506105918282604051602001610d5391815260200190565b604051602081830303815290604052610da9565b610d72816004610f6a565b600181602001818151610d8591906116bd565b90525050565b610d96816007610f6a565b600181602001818151610d8591906116aa565b610d2282600283515b60178167ffffffffffffffff1611610ddf578251610dd99060e0600585901b168317610f01565b50505050565b60ff8167ffffffffffffffff1611610e21578251610e08906018611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166001610f81565b61ffff8167ffffffffffffffff1611610e64578251610e4b906019611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166002610f81565b63ffffffff8167ffffffffffffffff1611610ea9578251610e9090601a611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166004610f81565b8251610ec090601b611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166008610f81565b604080518082019091526060815260006020820152610efa83838451611006565b9392505050565b6040805180820190915260608152600060208201528251516000610f268260016116bd565b905084602001518210610f4757610f4785610f42836002611538565b6110f5565b8451602083820101858153508051821115610f60578181525b5093949350505050565b815161020a90601f611fe0600585901b1617610f01565b6040805180820190915260608152600060208201528351516000610fa582856116bd565b90508560200151811115610fc257610fc286610f42836002611538565b60006001610fd2866101006117f0565b610fdc91906116aa565b90508651828101878319825116178152508051831115610ffa578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561102957600080fd5b835151600061103884836116bd565b905085602001518111156110555761105586610f42836002611538565b85518051838201602001916000918085111561106f578482525b505050602086015b602086106110af578051825261108e6020836116bd565b915061109b6020826116bd565b90506110a86020876116aa565b9550611077565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111018383610c9b565b50610dd98382610ed9565b6040518060400160405280611134604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111b7576111b7611141565b604052919050565b600067ffffffffffffffff8311156111d9576111d9611141565b61120a60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f86011601611170565b905082815283838301111561121e57600080fd5b828260208301376000602084830101529392505050565b600082601f83011261124657600080fd5b610efa838335602085016111bf565b60008060006060848603121561126a57600080fd5b83359250602084013567ffffffffffffffff8082111561128957600080fd5b61129587838801611235565b935060408601359150808211156112ab57600080fd5b506112b886828701611235565b9150509250925092565b60008083601f8401126112d457600080fd5b50813567ffffffffffffffff8111156112ec57600080fd5b60208301915083602082850101111561130457600080fd5b9250929050565b803567ffffffffffffffff8116811461132357600080fd5b919050565b60008060008060008060008060a0898b03121561134457600080fd5b883567ffffffffffffffff8082111561135c57600080fd5b6113688c838d016112c2565b909a50985060208b013591508082111561138157600080fd5b61138d8c838d016112c2565b909850965060408b01359150808211156113a657600080fd5b818b0191508b601f8301126113ba57600080fd5b8135818111156113c957600080fd5b8c60208260051b85010111156113de57600080fd5b6020830196508095505050506113f660608a0161130b565b9150608089013590509295985092959890939650565b60006020828403121561141e57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610efa57600080fd5b600067ffffffffffffffff8084111561145d5761145d611141565b8360051b602061146e818301611170565b86815291850191818101903684111561148657600080fd5b865b848110156114ce578035868111156114a05760008081fd5b880136601f8201126114b25760008081fd5b6114c03682358784016111bf565b845250918301918301611488565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d0f57610d0f611509565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115af576115af611509565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156115f45788810183015185820160c0015282016115d8565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505061163d604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561166857600080fd5b5051919050565b6000826116a5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d0f57610d0f611509565b80820180821115610d0f57610d0f611509565b600181815b8085111561172957817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561170f5761170f611509565b8085161561171c57918102915b93841c93908002906116d5565b509250929050565b60008261174057506001610d0f565b8161174d57506000610d0f565b8160018114611763576002811461176d57611789565b6001915050610d0f565b60ff84111561177e5761177e611509565b50506001821b610d0f565b5060208310610133831016604e8410600b84101617156117ac575081810a610d0f565b6117b683836116d0565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117e8576117e8611509565b029392505050565b6000610efa838361173156fea164736f6c6343000813000a", } var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI @@ -193,75 +193,75 @@ func (_FunctionsClientExample *FunctionsClientExampleCallerSession) MAXCALLBACKG return _FunctionsClientExample.Contract.MAXCALLBACKGAS(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastError(opts *bind.CallOpts) ([32]byte, error) { +func (_FunctionsClientExample *FunctionsClientExampleCaller) Owner(opts *bind.CallOpts) (common.Address, error) { var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastError") + err := _FunctionsClientExample.contract.Call(opts, &out, "owner") if err != nil { - return *new([32]byte), err + return *new(common.Address), err } - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } -func (_FunctionsClientExample *FunctionsClientExampleSession) LastError() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastError(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleSession) Owner() (common.Address, error) { + return _FunctionsClientExample.Contract.Owner(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastError() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastError(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleCallerSession) Owner() (common.Address, error) { + return _FunctionsClientExample.Contract.Owner(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastErrorLength(opts *bind.CallOpts) (uint32, error) { +func (_FunctionsClientExample *FunctionsClientExampleCaller) SLastError(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastErrorLength") + err := _FunctionsClientExample.contract.Call(opts, &out, "s_lastError") if err != nil { - return *new(uint32), err + return *new([32]byte), err } - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) return out0, err } -func (_FunctionsClientExample *FunctionsClientExampleSession) LastErrorLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastErrorLength(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleSession) SLastError() ([32]byte, error) { + return _FunctionsClientExample.Contract.SLastError(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastErrorLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastErrorLength(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleCallerSession) SLastError() ([32]byte, error) { + return _FunctionsClientExample.Contract.SLastError(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastRequestId(opts *bind.CallOpts) ([32]byte, error) { +func (_FunctionsClientExample *FunctionsClientExampleCaller) SLastErrorLength(opts *bind.CallOpts) (uint32, error) { var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastRequestId") + err := _FunctionsClientExample.contract.Call(opts, &out, "s_lastErrorLength") if err != nil { - return *new([32]byte), err + return *new(uint32), err } - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) return out0, err } -func (_FunctionsClientExample *FunctionsClientExampleSession) LastRequestId() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastRequestId(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleSession) SLastErrorLength() (uint32, error) { + return _FunctionsClientExample.Contract.SLastErrorLength(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastRequestId() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastRequestId(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleCallerSession) SLastErrorLength() (uint32, error) { + return _FunctionsClientExample.Contract.SLastErrorLength(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastResponse(opts *bind.CallOpts) ([32]byte, error) { +func (_FunctionsClientExample *FunctionsClientExampleCaller) SLastRequestId(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastResponse") + err := _FunctionsClientExample.contract.Call(opts, &out, "s_lastRequestId") if err != nil { return *new([32]byte), err @@ -273,56 +273,56 @@ func (_FunctionsClientExample *FunctionsClientExampleCaller) LastResponse(opts * } -func (_FunctionsClientExample *FunctionsClientExampleSession) LastResponse() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastResponse(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleSession) SLastRequestId() ([32]byte, error) { + return _FunctionsClientExample.Contract.SLastRequestId(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastResponse() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastResponse(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleCallerSession) SLastRequestId() ([32]byte, error) { + return _FunctionsClientExample.Contract.SLastRequestId(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastResponseLength(opts *bind.CallOpts) (uint32, error) { +func (_FunctionsClientExample *FunctionsClientExampleCaller) SLastResponse(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastResponseLength") + err := _FunctionsClientExample.contract.Call(opts, &out, "s_lastResponse") if err != nil { - return *new(uint32), err + return *new([32]byte), err } - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) return out0, err } -func (_FunctionsClientExample *FunctionsClientExampleSession) LastResponseLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastResponseLength(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleSession) SLastResponse() ([32]byte, error) { + return _FunctionsClientExample.Contract.SLastResponse(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastResponseLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastResponseLength(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleCallerSession) SLastResponse() ([32]byte, error) { + return _FunctionsClientExample.Contract.SLastResponse(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCaller) Owner(opts *bind.CallOpts) (common.Address, error) { +func (_FunctionsClientExample *FunctionsClientExampleCaller) SLastResponseLength(opts *bind.CallOpts) (uint32, error) { var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "owner") + err := _FunctionsClientExample.contract.Call(opts, &out, "s_lastResponseLength") if err != nil { - return *new(common.Address), err + return *new(uint32), err } - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) return out0, err } -func (_FunctionsClientExample *FunctionsClientExampleSession) Owner() (common.Address, error) { - return _FunctionsClientExample.Contract.Owner(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleSession) SLastResponseLength() (uint32, error) { + return _FunctionsClientExample.Contract.SLastResponseLength(&_FunctionsClientExample.CallOpts) } -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) Owner() (common.Address, error) { - return _FunctionsClientExample.Contract.Owner(&_FunctionsClientExample.CallOpts) +func (_FunctionsClientExample *FunctionsClientExampleCallerSession) SLastResponseLength() (uint32, error) { + return _FunctionsClientExample.Contract.SLastResponseLength(&_FunctionsClientExample.CallOpts) } func (_FunctionsClientExample *FunctionsClientExampleTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { @@ -938,17 +938,17 @@ func (_FunctionsClientExample *FunctionsClientExample) Address() common.Address type FunctionsClientExampleInterface interface { MAXCALLBACKGAS(opts *bind.CallOpts) (uint32, error) - LastError(opts *bind.CallOpts) ([32]byte, error) + Owner(opts *bind.CallOpts) (common.Address, error) - LastErrorLength(opts *bind.CallOpts) (uint32, error) + SLastError(opts *bind.CallOpts) ([32]byte, error) - LastRequestId(opts *bind.CallOpts) ([32]byte, error) + SLastErrorLength(opts *bind.CallOpts) (uint32, error) - LastResponse(opts *bind.CallOpts) ([32]byte, error) + SLastRequestId(opts *bind.CallOpts) ([32]byte, error) - LastResponseLength(opts *bind.CallOpts) (uint32, error) + SLastResponse(opts *bind.CallOpts) ([32]byte, error) - Owner(opts *bind.CallOpts) (common.Address, error) + SLastResponseLength(opts *bind.CallOpts) (uint32, error) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index b2778bd5086..0bc810e8bb6 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -34,13 +34,13 @@ type FunctionsBillingCommitment struct { SubscriptionId uint64 Client common.Address CallbackGasLimit uint32 - ExpectedGasPrice *big.Int Don common.Address - DonFee *big.Int AdminFee *big.Int EstimatedTotalCostJuels *big.Int + DonFee *big.Int + Timestamp uint32 GasOverhead *big.Int - Timestamp *big.Int + ExpectedGasPrice *big.Int } type IFunctionsBillingRequestBilling struct { @@ -52,17 +52,17 @@ type IFunctionsBillingRequestBilling struct { type IFunctionsCoordinatorRequest struct { RequestingContract common.Address - SubscriptionId uint64 SubscriptionOwner common.Address Data []byte + SubscriptionId uint64 DataVersion uint16 Flags [32]byte CallbackGasLimit uint32 } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620059f5380380620059f5833981016040819052620000349162000444565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000153565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011b81620001fe565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006169350505050565b336001600160a01b03821603620001ad5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000222919062000554565b985098509850985098509850985098509850600085136200025a576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160601b038a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e805461ffff19169091179055600f829055517f5dafb6dc181e59e476f118ac3f41ca1f23fbd444b37caa205d04e5b1260b258690620003fd908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160601b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200042957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200045a57600080fd5b620004658462000411565b602085810151919450906001600160401b03808211156200048557600080fd5b818701915087601f8301126200049a57600080fd5b815181811115620004af57620004af6200042e565b604051601f8201601f19908116603f01168101908382118183101715620004da57620004da6200042e565b816040528281528a86848701011115620004f357600080fd5b600093505b82841015620005175784840186015181850187015292850192620004f8565b6000868483010152809750505050505050620005366040850162000411565b90509250925092565b805163ffffffff811681146200042957600080fd5b60008060008060008060008060006101208a8c0312156200057457600080fd5b6200057f8a6200053f565b98506200058f60208b016200053f565b97506200059f60408b016200053f565b9650620005af60608b016200053f565b955060808a01519450620005c660a08b016200053f565b60c08b01519094506001600160601b0381168114620005e457600080fd5b60e08b015190935061ffff81168114620005fd57600080fd5b809250506101008a015190509295985092959850929598565b6080516153c362000632600039600061124f01526153c36000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063c3f909d411610097578063de9dfa4611610071578063de9dfa4614610492578063e1a82d6f146104a5578063e3d0e712146104e5578063f2fde38b146104f857600080fd5b8063c3f909d4146103a5578063d227d24514610477578063d328a91e1461048a57600080fd5b8063af1296d3116100c8578063af1296d31461036a578063afcb95d714610372578063b1dc65a41461039257600080fd5b80638cc6acce1461031d5780638da5cb5b146103305780639883c10d1461035857600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ad57806381f1b938146102c257806381ff7048146102ca57806385b214cf146102fa57600080fd5b806379ba50971461027f5780637f15e16614610287578063807560311461029a57600080fd5b8063466557181161018c5780634665571814610226578063533989871461025657806366316d8d1461026c57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004613e43565b61050b565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a9190613ee9565b60405180910390f35b6101c6610221366004613f1e565b610560565b61023961023436600461407a565b610602565b6040516bffffffffffffffffffffffff909116815260200161020a565b61025e610632565b60405161020a9291906141a1565b6101c661027a36600461424b565b6108e1565b6101c6610a5f565b6101c6610295366004613e43565b610b61565b6101c66102a8366004614284565b610bb1565b6102b5610c68565b60405161020a91906142d9565b6101fd610cd7565b6004546002546040805163ffffffff8085168252640100000000909404909316602084015282015260600161020a565b61030d6103083660046142ec565b610da8565b604051901515815260200161020a565b6101c661032b366004614305565b610f92565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6008545b60405190815260200161020a565b61035c610ff9565b60408051600181526000602082018190529181019190915260600161020a565b6101c66103a0366004614387565b6110dc565b610413600c54600d54600a54600e54600f5463ffffffff8086169664010000000087048216966c01000000000000000000000000810483169695680100000000000000009091049092169373ffffffffffffffffffffffffffffffffffffffff9092169261ffff9092169190565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61023961048536600461443e565b61180d565b6101fd6119d3565b6102396104a036600461407a565b611a2a565b6104b86104b33660046144ae565b611ac5565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b6101c66104f336600461459b565b611d07565b6101c6610506366004613f1e565b6126eb565b6105136126fc565b600081900361054e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601461055b828483614709565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061059b57503373ffffffffffffffffffffffffffffffffffffffff8216145b6105d1576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660009081526013602052604081206105ff91613d88565b50565b600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff165b92915050565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015610682573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526106c89190810190614888565b90506000815167ffffffffffffffff8111156106e6576106e6613f3b565b60405190808252806020026020018201604052801561071957816020015b60608152602001906001900390816107045790505b50905060005b82518110156108d7576013600084838151811061073e5761073e6148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461078b90614668565b90506000036107c6576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601360008483815181106107dc576107dc6148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461082990614668565b80601f016020809104026020016040519081016040528092919081815260200182805461085590614668565b80156108a25780601f10610877576101008083540402835291602001916108a2565b820191906000526020600020905b81548152906001019060200180831161088557829003601f168201915b50505050508282815181106108b9576108b96148bd565b602002602001018190525080806108cf9061491b565b91505061071f565b5090939092509050565b6108e961277f565b806bffffffffffffffffffffffff1660000361091f5750336000908152601060205260409020546bffffffffffffffffffffffff165b336000908152601060205260409020546bffffffffffffffffffffffff80831691161015610979576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260106020526040812080548392906109a69084906bffffffffffffffffffffffff16614953565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610a4257600080fd5b505af1158015610a56573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610ae5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610b696126fc565b6000819003610ba4576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601261055b828483614709565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610bfc5750610bdb33612918565b8015610bfc57503373ffffffffffffffffffffffffffffffffffffffff8416145b610c32576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601360205260409020610c62828483614709565b50505050565b60606007805480602002602001604051908101604052809291908181526020018280548015610ccd57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610ca2575b5050505050905090565b606060148054610ce690614668565b9050600003610d21576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60148054610d2e90614668565b80601f0160208091040260200160405190810160405280929190818152602001828054610d5a90614668565b8015610ccd5780601f10610d7c57610100808354040283529160200191610ccd565b820191906000526020600020905b815481529060010190602001808311610d8a57509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314610dfc576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e0840152600481015461010084015260050154610120830152610f0a5750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b60095473ffffffffffffffffffffffffffffffffffffffff163314610fe3576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610fec81612a2c565b8051602090910120600855565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611083573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110a79190614999565b509350509250508280156110c957506110c081426149e9565b8463ffffffff16105b156110d457600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161113291849163ffffffff851691908e908e9081908401838280828437600092019190915250612cf392505050565b611168576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461123d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610adc565b61124b8b8b8b8b8b8b612cfc565b60007f0000000000000000000000000000000000000000000000000000000000000000156112a85760028260200151836040015161128991906149fc565b6112939190614a44565b61129e9060016149fc565b60ff1690506112be565b60208201516112b89060016149fc565b60ff1690505b888114611327576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610adc565b888714611390576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610adc565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156113d3576113d3614a66565b60028111156113e4576113e4614a66565b905250905060028160200151600281111561140157611401614a66565b14801561144857506007816000015160ff1681548110611423576114236148bd565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610adc565b50505050506114bb613dc2565b6000808a8a6040516114ce929190614a95565b6040519081900381206114e5918e90602001614aa5565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117ef57600060018489846020811061154e5761154e6148bd565b61155b91901a601b6149fc565b8e8e8681811061156d5761156d6148bd565b905060200201358d8d87818110611586576115866148bd565b90506020020135604051600081526020016040526040516115c3949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115e5573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561166557611665614a66565b600281111561167657611676614a66565b905250925060018360200151600281111561169357611693614a66565b146116fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610adc565b8251600090879060ff16601f8110611714576117146148bd565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611796576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610adc565b8086846000015160ff16601f81106117b0576117b06148bd565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526117db6001866149fc565b945050806117e89061491b565b905061152f565b505050611800833383858e8e612daa565b5050505050505050505050565b6009546040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8716600482015263ffffffff8416602482015260009173ffffffffffffffffffffffffffffffffffffffff169081906310fc49c19060440160006040518083038186803b15801561188f57600080fd5b505afa1580156118a3573d6000803e3d6000fd5b50505050620f42408311156118e4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152509050600061197288888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610602915050565b905060006119b789898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611a2a915050565b90506119c5878784846130b3565b9a9950505050505050505050565b6060601280546119e290614668565b9050600003611a1d576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60128054610d2e90614668565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611a9a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611abe9190614ab9565b9392505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff163314611b1f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611b2c6060860186614ad6565b9050600003611b66576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060800160405280876020016020810190611b869190614b3b565b67ffffffffffffffff168152602090810190611ba490890189613f1e565b73ffffffffffffffffffffffffffffffffffffffff168152602001611bcf60e0890160c08a01614b58565b63ffffffff1681523a6020909101529050611c3b611bf06060880188614ad6565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611c359250505060a0890160808a01614b85565b83613215565b92975090955093509150611c526020870187613f1e565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c32611c9b60408b0160208c01614b3b565b611cab60608c0160408d01613f1e565b611cb860608d018d614ad6565b8d6080016020810190611ccb9190614b85565b8e60a001358f60c0016020810190611ce39190614b58565b604051611cf7989796959493929190614ba2565b60405180910390a3509193509193565b855185518560ff16601f831115611d7a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610adc565b60008111611de4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610adc565b818314611e72576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610adc565b611e7d816003614c48565b8311611ee5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610adc565b611eed6126fc565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f3490886137dd565b600654156120e957600654600090611f4e906001906149e9565b9050600060068281548110611f6557611f656148bd565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f9f57611f9f6148bd565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560068054919250908061201f5761201f614c5f565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061208857612088614c5f565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f34915050565b60005b81515181101561254e5760006005600084600001518481518110612112576121126148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215c5761215c614a66565b146121c3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610adc565b6040805180820190915260ff821681526001602082015282518051600591600091859081106121f4576121f46148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561229557612295614a66565b0217905550600091506122a59050565b60056000846020015184815181106122bf576122bf6148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230957612309614a66565b14612370576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610adc565b6040805180820190915260ff8216815260208101600281525060056000846020015184815181106123a3576123a36148bd565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561244457612444614a66565b021790555050825180516006925083908110612462576124626148bd565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160079190839081106124de576124de6148bd565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556125478161491b565b90506120ec565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff4381168202928317855590830481169360019390926000926125e0928692908216911617614c8e565b92506101000a81548163ffffffff021916908363ffffffff16021790555061263f4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516137fa565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05986126de988b98919763ffffffff909216969095919491939192614cab565b60405180910390a1611800565b6126f36126fc565b6105ff816138a5565b60005473ffffffffffffffffffffffffffffffffffffffff16331461277d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610adc565b565b6000612789610c68565b905080516000036127c6576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516011546000916127e5916bffffffffffffffffffffffff16614d31565b905060005b82518160ff1610156128b9578160106000858460ff1681518110612810576128106148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166128789190614d5c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080806128b190614d81565b9150506127ea565b5081516128c69082614da0565b601180546000906128e69084906bffffffffffffffffffffffff16614953565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b8152600401600060405180830381865afa158015612966573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526129ac9190810190614888565b905060005b8151811015612a22578373ffffffffffffffffffffffffffffffffffffffff168282815181106129e3576129e36148bd565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a10575060019392505050565b80612a1a8161491b565b9150506129b1565b5060009392505050565b600080600080600080600080600089806020019051810190612a4e9190614dd0565b98509850985098509850985098509850985060008513612a9d576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610adc565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526bffffffffffffffffffffffff8a1660a0870181905260c087018d905261ffff8a1660e08801819052610100909701899052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d879055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055600f829055517f5dafb6dc181e59e476f118ac3f41ca1f23fbd444b37caa205d04e5b1260b258690612cdf908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526bffffffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b60019392505050565b6000612d09826020614c48565b612d14856020614c48565b612d2088610144614e80565b612d2a9190614e80565b612d349190614e80565b612d3f906000614e80565b9050368114610a56576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610adc565b60608080612dba84860186614f13565b825192955090935091501580612dd257508151835114155b80612ddf57508051835114155b15612e16576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156130a7576000612e7a858381518110612e3957612e396148bd565b6020026020010151858481518110612e5357612e536148bd565b6020026020010151858581518110612e6d57612e6d6148bd565b602002602001015161399a565b90506000816006811115612e9057612e90614a66565b1480612ead57506001816006811115612eab57612eab614a66565b145b15612f0857848281518110612ec457612ec46148bd565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613094565b6002816006811115612f1c57612f1c614a66565b03612f6c57848281518110612f3357612f336148bd565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613094565b6003816006811115612f8057612f80614a66565b03612fd057848281518110612f9757612f976148bd565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613094565b6005816006811115612fe457612fe4614a66565b0361303457848281518110612ffb57612ffb6148bd565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a2613094565b600481600681111561304857613048614a66565b036130945784828151811061305f5761305f6148bd565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b508061309f8161491b565b915050612e19565b50505050505050505050565b6000806130be610ff9565b9050600081136130fd576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610adc565b600c5460009087906131339063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c8e565b61313d9190614c8e565b63ffffffff1690506000612710600c600301548861315b9190614c48565b6131659190614ff0565b61316f9088614e80565b90506000838361318784670de0b6b3a7640000614c48565b6131919190614c48565b61319b9190614ff0565b905060006131ba6bffffffffffffffffffffffff808916908a16614e80565b90506131d2816b033b2e3c9fd0803ce80000006149e9565b82111561320b576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119c58183614e80565b600e5460009081908190819061ffff9081169087161115613262576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061326e8887610602565b9050600061327c8988611a2a565b905060006132948860400151896060015185856130b3565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa158015613317573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261335d9190810190615004565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156133ee573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134129190615090565b509150506bffffffffffffffffffffffff851661342f8385614953565b6bffffffffffffffffffffffff161015613475576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006134f4308e602001518f6000015185600161349291906150e2565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff166135e09190614c8e565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee54229061378d908490615103565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60006137e7610c68565b5111156137f6576137f661277f565b5050565b6000808a8a8a8a8a8a8a8a8a60405160200161381e99989796959493929190615205565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613924576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610adc565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613aa9576002915050611abe565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613b07610ff9565b905060008113613b46576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610adc565b600081613b5b3a670de0b6b3a7640000614c48565b613b659190614ff0565b9050600083610100015182613b7a9190614c48565b905060008460a0015182613b8e9190614d5c565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613bf6908f908f908f908c908b90339060040161529a565b60408051808303816000875af1158015613c14573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c38919061530b565b9092509050613c478186614d5c565b33600090815260106020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601180549193909291613ca791859116614d5c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613d0d9190614d5c565b60c08d015160a08e0151613d21888d614d5c565b613d2b9190614d5c565b613d359190614d5c565b8760ff166006811115613d4a57613d4a614a66565b604051613d5b95949392919061533a565b60405180910390a28160ff166006811115613d7857613d78614a66565b9c9b505050505050505050505050565b508054613d9490614668565b6000825580601f10613da4575050565b601f0160209004906000526020600020908101906105ff9190613de1565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613df65760008155600101613de2565b5090565b60008083601f840112613e0c57600080fd5b50813567ffffffffffffffff811115613e2457600080fd5b602083019150836020828501011115613e3c57600080fd5b9250929050565b60008060208385031215613e5657600080fd5b823567ffffffffffffffff811115613e6d57600080fd5b613e7985828601613dfa565b90969095509350505050565b6000815180845260005b81811015613eab57602081850181015186830182015201613e8f565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611abe6020830184613e85565b73ffffffffffffffffffffffffffffffffffffffff811681146105ff57600080fd5b600060208284031215613f3057600080fd5b8135611abe81613efc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613fb157613fb1613f3b565b604052919050565b600082601f830112613fca57600080fd5b813567ffffffffffffffff811115613fe457613fe4613f3b565b61401560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f6a565b81815284602083860101111561402a57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff811681146105ff57600080fd5b8035610f8d81614047565b63ffffffff811681146105ff57600080fd5b60008082840360a081121561408e57600080fd5b833567ffffffffffffffff808211156140a657600080fd5b6140b287838801613fb9565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156140e457600080fd5b6040519250608083019150828210818311171561410357614103613f3b565b50604052602084013561411581614047565b8152604084013561412581613efc565b6020820152606084013561413881614068565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561419657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614164565b509495945050505050565b6040815260006141b46040830185614150565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614222577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614210838351613e85565b948601949250908501906001016141d6565b50909998505050505050505050565b6bffffffffffffffffffffffff811681146105ff57600080fd5b6000806040838503121561425e57600080fd5b823561426981613efc565b9150602083013561427981614231565b809150509250929050565b60008060006040848603121561429957600080fd5b83356142a481613efc565b9250602084013567ffffffffffffffff8111156142c057600080fd5b6142cc86828701613dfa565b9497909650939450505050565b602081526000611abe6020830184614150565b6000602082840312156142fe57600080fd5b5035919050565b60006020828403121561431757600080fd5b813567ffffffffffffffff81111561432e57600080fd5b61433a84828501613fb9565b949350505050565b60008083601f84011261435457600080fd5b50813567ffffffffffffffff81111561436c57600080fd5b6020830191508360208260051b8501011115613e3c57600080fd5b60008060008060008060008060e0898b0312156143a357600080fd5b606089018a8111156143b457600080fd5b8998503567ffffffffffffffff808211156143ce57600080fd5b6143da8c838d01613dfa565b909950975060808b01359150808211156143f357600080fd5b6143ff8c838d01614342565b909750955060a08b013591508082111561441857600080fd5b506144258b828c01614342565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561445657600080fd5b853561446181614047565b9450602086013567ffffffffffffffff81111561447d57600080fd5b61448988828901613dfa565b909550935050604086013561449d81614068565b949793965091946060013592915050565b6000602082840312156144c057600080fd5b813567ffffffffffffffff8111156144d757600080fd5b820160e08185031215611abe57600080fd5b600067ffffffffffffffff82111561450357614503613f3b565b5060051b60200190565b600082601f83011261451e57600080fd5b8135602061453361452e836144e9565b613f6a565b82815260059290921b8401810191818101908684111561455257600080fd5b8286015b8481101561457657803561456981613efc565b8352918301918301614556565b509695505050505050565b60ff811681146105ff57600080fd5b8035610f8d81614581565b60008060008060008060c087890312156145b457600080fd5b863567ffffffffffffffff808211156145cc57600080fd5b6145d88a838b0161450d565b975060208901359150808211156145ee57600080fd5b6145fa8a838b0161450d565b965061460860408a01614590565b9550606089013591508082111561461e57600080fd5b61462a8a838b01613fb9565b945061463860808a0161405d565b935060a089013591508082111561464e57600080fd5b5061465b89828a01613fb9565b9150509295509295509295565b600181811c9082168061467c57607f821691505b6020821081036146b5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561055b57600081815260208120601f850160051c810160208610156146e25750805b601f850160051c820191505b81811015614701578281556001016146ee565b505050505050565b67ffffffffffffffff83111561472157614721613f3b565b6147358361472f8354614668565b836146bb565b6000601f84116001811461478757600085156147515750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561481d565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147d657868501358255602094850194600190920191016147b6565b5086821015614811577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b600082601f83011261483557600080fd5b8151602061484561452e836144e9565b82815260059290921b8401810191818101908684111561486457600080fd5b8286015b8481101561457657805161487b81613efc565b8352918301918301614868565b60006020828403121561489a57600080fd5b815167ffffffffffffffff8111156148b157600080fd5b61433a84828501614824565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361494c5761494c6148ec565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614978576149786148ec565b5092915050565b805169ffffffffffffffffffff81168114610f8d57600080fd5b600080600080600060a086880312156149b157600080fd5b6149ba8661497f565b94506020860151935060408601519250606086015191506149dd6080870161497f565b90509295509295909350565b8181038181111561062c5761062c6148ec565b60ff818116838216019081111561062c5761062c6148ec565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a5757614a57614a15565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614acb57600080fd5b8151611abe81614231565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614b0b57600080fd5b83018035915067ffffffffffffffff821115614b2657600080fd5b602001915036819003821315613e3c57600080fd5b600060208284031215614b4d57600080fd5b8135611abe81614047565b600060208284031215614b6a57600080fd5b8135611abe81614068565b61ffff811681146105ff57600080fd5b600060208284031215614b9757600080fd5b8135611abe81614b75565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b808202811582820484141761062c5761062c6148ec565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614978576149786148ec565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cdb8184018a614150565b90508281036080840152614cef8189614150565b905060ff871660a084015282810360c0840152614d0c8187613e85565b905067ffffffffffffffff851660e0840152828103610100840152613d788185613e85565b60006bffffffffffffffffffffffff80841680614d5057614d50614a15565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614978576149786148ec565b600060ff821660ff8103614d9757614d976148ec565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614dc857614dc86148ec565b505092915050565b60008060008060008060008060006101208a8c031215614def57600080fd5b8951614dfa81614068565b60208b0151909950614e0b81614068565b60408b0151909850614e1c81614068565b60608b0151909750614e2d81614068565b60808b015160a08c01519197509550614e4581614068565b60c08b0151909450614e5681614231565b60e08b0151909350614e6781614b75565b809250506101008a015190509295985092959850929598565b8082018082111561062c5761062c6148ec565b600082601f830112614ea457600080fd5b81356020614eb461452e836144e9565b82815260059290921b84018101918181019086841115614ed357600080fd5b8286015b8481101561457657803567ffffffffffffffff811115614ef75760008081fd5b614f058986838b0101613fb9565b845250918301918301614ed7565b600080600060608486031215614f2857600080fd5b833567ffffffffffffffff80821115614f4057600080fd5b818601915086601f830112614f5457600080fd5b81356020614f6461452e836144e9565b82815260059290921b8401810191818101908a841115614f8357600080fd5b948201945b83861015614fa157853582529482019490820190614f88565b97505087013592505080821115614fb757600080fd5b614fc387838801614e93565b93506040860135915080821115614fd957600080fd5b50614fe686828701614e93565b9150509250925092565b600082614fff57614fff614a15565b500490565b600080600080600060a0868803121561501c57600080fd5b855161502781614231565b602087015190955061503881614231565b604087015190945061504981613efc565b606087015190935061505a81613efc565b608087015190925067ffffffffffffffff81111561507757600080fd5b61508388828901614824565b9150509295509295909350565b6000806000606084860312156150a557600080fd5b835180151581146150b557600080fd5b60208501519093506150c681614047565b60408501519092506150d781614047565b809150509250925092565b67ffffffffffffffff818116838216019080821115614978576149786148ec565b815167ffffffffffffffff1681526101408101602083015161513d602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615155604084018263ffffffff169052565b50606083015160608301526080830151615187608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a08301516151a760a08401826bffffffffffffffffffffffff169052565b5060c08301516151c760c08401826bffffffffffffffffffffffff169052565b5060e08301516151e760e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b16604085015281606085015261524c8285018b614150565b91508382036080850152615260828a614150565b915060ff881660a085015283820360c085015261527d8288613e85565b90861660e08501528381036101008501529050613d788185613e85565b86815260c0602082015260006152b360c0830188613e85565b82810360408401526152c58188613e85565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b6000806040838503121561531e57600080fd5b825161532981614581565b602084015190925061427981614231565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a08101600783106153a6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162005bfd38038062005bfd833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000162565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600880546001600160a01b0319166001600160a01b0384161790556200011b816200020d565b805160209091012060075550600e80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001bc5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000231919062000572565b9850985098509850985098509850985098506000851362000269576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160501b038a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d9052600a8054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600b829055600c869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd73906200041b908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160501b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b955060808a01519450620005e460a08b016200055d565b60c08b01519094506001600160501b03811681146200060257600080fd5b60e08b015190935061ffff811681146200061b57600080fd5b809250506101008a015190509295985092959850929598565b6080516155ad62000650600039600061152101526155ad6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e1461053f578063de9dfa4614610547578063e3d0e7121461055a578063f2fde38b1461056d57600080fd5b8063b1dc65a41461040d578063c3f909d414610420578063d227d2451461050f57600080fd5b8063aecc12c5116100c8578063aecc12c5146103a5578063af1296d3146103e5578063afcb95d7146103ed57600080fd5b80638cc6acce146103585780638da5cb5b1461036b5780639883c10d1461039357600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ab57806381f1b938146102c057806381ff7048146102c857806385b214cf1461033557600080fd5b806379ba50971461027d5780637f15e16614610285578063807560311461029857600080fd5b8063466557181161018c5780634665571814610226578063533989871461025457806366316d8d1461026a57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c136600461404d565b610580565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a91906140f3565b60405180910390f35b6101c6610221366004614128565b6105d5565b610239610234366004614284565b610677565b60405169ffffffffffffffffffff909116815260200161020a565b61025c6106a5565b60405161020a9291906143ab565b6101c6610278366004614455565b610929565b6101c6610aa7565b6101c661029336600461404d565b610ba9565b6101c66102a636600461448e565b610bf9565b6102b3610cb0565b60405161020a91906144e3565b6101fd610d1f565b61031260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff94851681529390921660208401529082015260600161020a565b6103486103433660046144f6565b610df0565b604051901515815260200161020a565b6101c661036636600461450f565b611012565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6007545b60405190815260200161020a565b6103b86103b336600461454c565b611079565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b6103976112bb565b60408051600181526000602082018190529181019190915260600161020a565b6101c661041b3660046145cc565b6113ae565b6104ab600a54600c54600e54600b5463ffffffff8085169564010000000086048216956c010000000000000000000000008082048416969568010000000000000000830490941694930473ffffffffffffffffffffffffffffffffffffffff16927e0100000000000000000000000000000000000000000000000000000000000090910461ffff1691565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61052261051d366004614683565b611adf565b6040516bffffffffffffffffffffffff909116815260200161020a565b6101fd611cb1565b610522610555366004614284565b611d08565b6101c66105683660046147a5565b611da3565b6101c661057b366004614128565b6127c7565b6105886127d8565b60008190036105c3576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60116105d0828483614913565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061057503373ffffffffffffffffffffffffffffffffffffffff8216145b610646576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260106020526040812061067491613f92565b50565b600a5474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106e2575b505050505090506000815167ffffffffffffffff81111561073057610730614145565b60405190808252806020026020018201604052801561076357816020015b606081526020019060019003908161074e5790505b50905060005b825181101561091f576010600084838151811061078857610788614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107d590614872565b9050600003610810576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6010600084838151811061082657610826614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461087390614872565b80601f016020809104026020016040519081016040528092919081815260200182805461089f90614872565b80156108ec5780601f106108c1576101008083540402835291602001916108ec565b820191906000526020600020905b8154815290600101906020018083116108cf57829003601f168201915b505050505082828151811061090357610903614a2e565b60200260200101819052508061091890614a8c565b9050610769565b5090939092509050565b61093161285b565b806bffffffffffffffffffffffff166000036109675750336000908152600d60205260409020546bffffffffffffffffffffffff165b336000908152600d60205260409020546bffffffffffffffffffffffff808316911610156109c1576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906109ee9084906bffffffffffffffffffffffff16614ac4565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556008546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610a8a57600080fd5b505af1158015610a9e573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b2d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bb16127d8565b6000819003610bec576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105d0828483614913565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c445750610c23336129f2565b8015610c4457503373ffffffffffffffffffffffffffffffffffffffff8416145b610c7a576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601060205260409020610caa828483614913565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d1557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610cea575b5050505050905090565b606060118054610d2e90614872565b9050600003610d69576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60118054610d7690614872565b80601f0160208091040260200160405190810160405280929190818152602001828054610da290614872565b8015610d155780601f10610dc457610100808354040283529160200191610d15565b820191906000526020600020905b815481529060010190602001808311610dd257509395945050505050565b60085460009073ffffffffffffffffffffffffffffffffffffffff163314610e44576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260096020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff1661010084015260030154610120830152610f985750600092915050565b600083815260096020526040808220828155600181018390556002810180547fff000000000000000000000000000000000000000000000000000000000000001690556003018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b60085473ffffffffffffffffffffffffffffffffffffffff163314611063576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61106c81612adb565b8051602090910120600755565b60085460009081908190819073ffffffffffffffffffffffffffffffffffffffff1633146110d3576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110e06040860186614af0565b905060000361111a576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604051806080016040528087606001602081019061113a9190614b55565b67ffffffffffffffff16815260209081019061115890890189614128565b73ffffffffffffffffffffffffffffffffffffffff16815260200161118360e0890160c08a01614b72565b63ffffffff1681523a60209091015290506111ef6111a46040880188614af0565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506111e99250505060a0890160808a01614b9f565b83612dd6565b929750909550935091506112066020870187614128565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c3261124f60808b0160608c01614b55565b61125f60408c0160208d01614128565b61126c60408d018d614af0565b8d608001602081019061127f9190614b9f565b8e60a001358f60c00160208101906112979190614b72565b6040516112ab989796959493929190614bbc565b60405180910390a3509193509193565b600a54600e54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611355573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113799190614c7c565b5093505092505082801561139b57506113928142614ccc565b8463ffffffff16105b156113a657600c5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161140491849163ffffffff851691908e908e908190840183828082843760009201919091525061346392505050565b61143a576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461150f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b24565b61151d8b8b8b8b8b8b61346c565b60007f00000000000000000000000000000000000000000000000000000000000000001561157a5760028260200151836040015161155b9190614cdf565b6115659190614d27565b611570906001614cdf565b60ff169050611590565b602082015161158a906001614cdf565b60ff1690505b8881146115f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b24565b888714611662576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b24565b3360009081526004602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156116a5576116a5614d49565b60028111156116b6576116b6614d49565b90525090506002816020015160028111156116d3576116d3614d49565b14801561171a57506006816000015160ff16815481106116f5576116f5614a2e565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611780576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b24565b505050505061178d613fcc565b6000808a8a6040516117a0929190614d78565b6040519081900381206117b7918e90602001614d88565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611ac157600060018489846020811061182057611820614a2e565b61182d91901a601b614cdf565b8e8e8681811061183f5761183f614a2e565b905060200201358d8d8781811061185857611858614a2e565b9050602002013560405160008152602001604052604051611895949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156118b7573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561193757611937614d49565b600281111561194857611948614d49565b905250925060018360200151600281111561196557611965614d49565b146119cc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b24565b8251600090879060ff16601f81106119e6576119e6614a2e565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611a68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b24565b8086846000015160ff16601f8110611a8257611a82614a2e565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611aad600186614cdf565b94505080611aba90614a8c565b9050611801565b505050611ad2833383858e8e61351a565b5050505050505050505050565b6008546040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8716600482015263ffffffff8416602482015260009173ffffffffffffffffffffffffffffffffffffffff169081906310fc49c19060440160006040518083038186803b158015611b6157600080fd5b505afa158015611b75573d6000803e3d6000fd5b50505050620f4240831115611bb6576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611c4488888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610677915050565b69ffffffffffffffffffff1690506000611c9589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611d08915050565b9050611ca387878484613821565b9a9950505050505050505050565b6060600f8054611cc090614872565b9050600003611cfb576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610d7690614872565b600854604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611d78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d9c9190614d9c565b9392505050565b855185518560ff16601f831115611e16576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b24565b80600003611e80576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b24565b818314611f0e576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b24565b611f19816003614db9565b8311611f81576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b24565b611f896127d8565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611fd09088613983565b6005541561218557600554600090611fea90600190614ccc565b905060006005828154811061200157612001614a2e565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061203b5761203b614a2e565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000908116909155929091168084529220805490911690556005805491925090806120bb576120bb614dd0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061212457612124614dd0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611fd0915050565b60005b8151518110156125ec57600060046000846000015184815181106121ae576121ae614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121f8576121f8614d49565b1461225f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b24565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061229057612290614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561233157612331614d49565b0217905550600091506123419050565b600460008460200151848151811061235b5761235b614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156123a5576123a5614d49565b1461240c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b24565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061243f5761243f614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124e0576124e0614d49565b0217905550508251805160059250839081106124fe576124fe614a2e565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061257a5761257a614a2e565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125e481614a8c565b915050612188565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff43811682029290921780855592048116929182916014916126a491849174010000000000000000000000000000000000000000900416614dff565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127034630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516139a0565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05986127ba988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614e1c565b60405180910390a1611ad2565b6127cf6127d8565b61067481613a4b565b60005473ffffffffffffffffffffffffffffffffffffffff163314612859576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b24565b565b6000612865610cb0565b905080516000036128a2576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600e546000916128c1916bffffffffffffffffffffffff16614ea2565b905060005b82518160ff1610156129935781600d6000858460ff16815181106128ec576128ec614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129549190614ecd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061298c90614ef2565b90506128c6565b5081516129a09082614f11565b600e80546000906129c09084906bffffffffffffffffffffffff16614ac4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a5857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a2d575b5050505050905060005b8151811015612ad1578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a9457612a94614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612ac1575060019392505050565b612aca81614a8c565b9050612a62565b5060009392505050565b600080600080600080600080600089806020019051810190612afd9190614f41565b98509850985098509850985098509850985060008513612b4c576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610b24565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a166080860181905269ffffffffffffffffffff8a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d9052600a80547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600b829055600c869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd7390612dc2908b908b908a908c908b908a908a908a9063ffffffff988916815296881660208801529487166040870152929095166060850152608084015269ffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b600a5460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612e45576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612e518887610677565b90506000612e5f8988611d08565b90506000612e83886040015189606001518569ffffffffffffffffffff1685613821565b60085489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa158015612f06573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612f4c9190810190614fed565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015612fdd573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061300191906150d9565b509150506bffffffffffffffffffffffff851661301e8385614ac4565b6bffffffffffffffffffffffff161015613064576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006130e3308e602001518f60000151856001613081919061512b565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff168152602001600a600001600c9054906101000a900463ffffffff16600a60000160089054906101000a900463ffffffff166131cf9190614dff565b63ffffffff1664ffffffffff1681526020018f606001518152509050806009600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd82604051613413919061514c565b60405180910390a250600a54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613479826020614db9565b613484856020614db9565b61349088610144615261565b61349a9190615261565b6134a49190615261565b6134af906000615261565b9050368114610a9e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b24565b6060808061352a848601866152f4565b82519295509093509150158061354257508151835114155b8061354f57508051835114155b15613586576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156138155760006135ea8583815181106135a9576135a9614a2e565b60200260200101518584815181106135c3576135c3614a2e565b60200260200101518585815181106135dd576135dd614a2e565b6020026020010151613b40565b9050600081600681111561360057613600614d49565b148061361d5750600181600681111561361b5761361b614d49565b145b156136785784828151811061363457613634614a2e565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613804565b600281600681111561368c5761368c614d49565b036136dc578482815181106136a3576136a3614a2e565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613804565b60038160068111156136f0576136f0614d49565b036137405784828151811061370757613707614a2e565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613804565b600581600681111561375457613754614d49565b036137a45784828151811061376b5761376b614a2e565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a2613804565b60048160068111156137b8576137b8614d49565b03613804578482815181106137cf576137cf614a2e565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b5061380e81614a8c565b9050613589565b50505050505050505050565b60008061382c6112bb565b90506000811361386b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b24565b600a5460009087906138a19063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614dff565b6138ab9190614dff565b63ffffffff1690506000612710600a60010154886138c99190614db9565b6138d391906153d1565b6138dd9088615261565b9050600083836138f584670de0b6b3a7640000614db9565b6138ff9190614db9565b61390991906153d1565b905060006139286bffffffffffffffffffffffff808916908a16615261565b9050613940816b033b2e3c9fd0803ce8000000614ccc565b821115613979576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611ca38183615261565b600061398d610cb0565b51111561399c5761399c61285b565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016139c4999897969594939291906153e5565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613aca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b24565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600960209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613c95576002915050611d9c565b6000858152600960205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613ce56112bb565b905060008113613d24576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b24565b600081613d393a670de0b6b3a7640000614db9565b613d4391906153d1565b9050600083610100015164ffffffffff1682613d5f9190614db9565b905060008460c0015169ffffffffffffffffffff1682613d7f9190614ecd565b6008546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613de7908f908f908f908c908b90339060040161547a565b60408051808303816000875af1158015613e05573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613e2991906154eb565b9092509050613e388186614ecd565b336000908152600d6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600e805469ffffffffffffffffffff90921693909291613ea591859116614ecd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c001518489613f0b9190614ecd565b60808d015160c08e015169ffffffffffffffffffff16613f2b888d614ecd565b613f359190614ecd565b613f3f9190614ecd565b8760ff166006811115613f5457613f54614d49565b604051613f6595949392919061551a565b60405180910390a28160ff166006811115613f8257613f82614d49565b9c9b505050505050505050505050565b508054613f9e90614872565b6000825580601f10613fae575050565b601f0160209004906000526020600020908101906106749190613feb565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156140005760008155600101613fec565b5090565b60008083601f84011261401657600080fd5b50813567ffffffffffffffff81111561402e57600080fd5b60208301915083602082850101111561404657600080fd5b9250929050565b6000806020838503121561406057600080fd5b823567ffffffffffffffff81111561407757600080fd5b61408385828601614004565b90969095509350505050565b6000815180845260005b818110156140b557602081850181015186830182015201614099565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611d9c602083018461408f565b73ffffffffffffffffffffffffffffffffffffffff8116811461067457600080fd5b60006020828403121561413a57600080fd5b8135611d9c81614106565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156141bb576141bb614145565b604052919050565b600082601f8301126141d457600080fd5b813567ffffffffffffffff8111156141ee576141ee614145565b61421f60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614174565b81815284602083860101111561423457600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067457600080fd5b803561100d81614251565b63ffffffff8116811461067457600080fd5b60008082840360a081121561429857600080fd5b833567ffffffffffffffff808211156142b057600080fd5b6142bc878388016141c3565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156142ee57600080fd5b6040519250608083019150828210818311171561430d5761430d614145565b50604052602084013561431f81614251565b8152604084013561432f81614106565b6020820152606084013561434281614272565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156143a057815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161436e565b509495945050505050565b6040815260006143be604083018561435a565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561442c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261441a83835161408f565b948601949250908501906001016143e0565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461067457600080fd5b6000806040838503121561446857600080fd5b823561447381614106565b915060208301356144838161443b565b809150509250929050565b6000806000604084860312156144a357600080fd5b83356144ae81614106565b9250602084013567ffffffffffffffff8111156144ca57600080fd5b6144d686828701614004565b9497909650939450505050565b602081526000611d9c602083018461435a565b60006020828403121561450857600080fd5b5035919050565b60006020828403121561452157600080fd5b813567ffffffffffffffff81111561453857600080fd5b614544848285016141c3565b949350505050565b60006020828403121561455e57600080fd5b813567ffffffffffffffff81111561457557600080fd5b820160e08185031215611d9c57600080fd5b60008083601f84011261459957600080fd5b50813567ffffffffffffffff8111156145b157600080fd5b6020830191508360208260051b850101111561404657600080fd5b60008060008060008060008060e0898b0312156145e857600080fd5b606089018a8111156145f957600080fd5b8998503567ffffffffffffffff8082111561461357600080fd5b61461f8c838d01614004565b909950975060808b013591508082111561463857600080fd5b6146448c838d01614587565b909750955060a08b013591508082111561465d57600080fd5b5061466a8b828c01614587565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561469b57600080fd5b85356146a681614251565b9450602086013567ffffffffffffffff8111156146c257600080fd5b6146ce88828901614004565b90955093505060408601356146e281614272565b949793965091946060013592915050565b600067ffffffffffffffff82111561470d5761470d614145565b5060051b60200190565b600082601f83011261472857600080fd5b8135602061473d614738836146f3565b614174565b82815260059290921b8401810191818101908684111561475c57600080fd5b8286015b8481101561478057803561477381614106565b8352918301918301614760565b509695505050505050565b60ff8116811461067457600080fd5b803561100d8161478b565b60008060008060008060c087890312156147be57600080fd5b863567ffffffffffffffff808211156147d657600080fd5b6147e28a838b01614717565b975060208901359150808211156147f857600080fd5b6148048a838b01614717565b965061481260408a0161479a565b9550606089013591508082111561482857600080fd5b6148348a838b016141c3565b945061484260808a01614267565b935060a089013591508082111561485857600080fd5b5061486589828a016141c3565b9150509295509295509295565b600181811c9082168061488657607f821691505b6020821081036148bf577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105d057600081815260208120601f850160051c810160208610156148ec5750805b601f850160051c820191505b8181101561490b578281556001016148f8565b505050505050565b67ffffffffffffffff83111561492b5761492b614145565b61493f836149398354614872565b836148c5565b6000601f841160018114614991576000851561495b5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614a27565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156149e057868501358255602094850194600190920191016149c0565b5086821015614a1b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614abd57614abd614a5d565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614ae957614ae9614a5d565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614b2557600080fd5b83018035915067ffffffffffffffff821115614b4057600080fd5b60200191503681900382131561404657600080fd5b600060208284031215614b6757600080fd5b8135611d9c81614251565b600060208284031215614b8457600080fd5b8135611d9c81614272565b61ffff8116811461067457600080fd5b600060208284031215614bb157600080fd5b8135611d9c81614b8f565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461100d57600080fd5b600080600080600060a08688031215614c9457600080fd5b614c9d86614c62565b9450602086015193506040860151925060608601519150614cc060808701614c62565b90509295509295909350565b8181038181111561069f5761069f614a5d565b60ff818116838216019081111561069f5761069f614a5d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614d3a57614d3a614cf8565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614dae57600080fd5b8151611d9c8161443b565b808202811582820484141761069f5761069f614a5d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614ae957614ae9614a5d565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614e4c8184018a61435a565b90508281036080840152614e60818961435a565b905060ff871660a084015282810360c0840152614e7d818761408f565b905067ffffffffffffffff851660e0840152828103610100840152613f82818561408f565b60006bffffffffffffffffffffffff80841680614ec157614ec1614cf8565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614ae957614ae9614a5d565b600060ff821660ff8103614f0857614f08614a5d565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614f3957614f39614a5d565b505092915050565b60008060008060008060008060006101208a8c031215614f6057600080fd5b8951614f6b81614272565b60208b0151909950614f7c81614272565b60408b0151909850614f8d81614272565b60608b0151909750614f9e81614272565b60808b015160a08c01519197509550614fb681614272565b9350614fc460c08b01614c62565b925060e08a0151614fd481614b8f565b809250506101008a015190509295985092959850929598565b600080600080600060a0868803121561500557600080fd5b85516150108161443b565b809550506020808701516150238161443b565b604088015190955061503481614106565b606088015190945061504581614106565b608088015190935067ffffffffffffffff81111561506257600080fd5b8701601f8101891361507357600080fd5b8051615081614738826146f3565b81815260059190911b8201830190838101908b8311156150a057600080fd5b928401925b828410156150c75783516150b881614106565b825292840192908401906150a5565b80955050505050509295509295909350565b6000806000606084860312156150ee57600080fd5b835180151581146150fe57600080fd5b602085015190935061510f81614251565b604085015190925061512081614251565b809150509250925092565b67ffffffffffffffff818116838216019080821115614ae957614ae9614a5d565b815167ffffffffffffffff16815261014081016020830151615186602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161519e604084018263ffffffff169052565b5060608301516151c6606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516151e660808401826bffffffffffffffffffffffff169052565b5060a083015161520660a08401826bffffffffffffffffffffffff169052565b5060c083015161522460c084018269ffffffffffffffffffff169052565b5060e083015161523c60e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b8082018082111561069f5761069f614a5d565b600082601f83011261528557600080fd5b81356020615295614738836146f3565b82815260059290921b840181019181810190868411156152b457600080fd5b8286015b8481101561478057803567ffffffffffffffff8111156152d85760008081fd5b6152e68986838b01016141c3565b8452509183019183016152b8565b60008060006060848603121561530957600080fd5b833567ffffffffffffffff8082111561532157600080fd5b818601915086601f83011261533557600080fd5b81356020615345614738836146f3565b82815260059290921b8401810191818101908a84111561536457600080fd5b948201945b8386101561538257853582529482019490820190615369565b9750508701359250508082111561539857600080fd5b6153a487838801615274565b935060408601359150808211156153ba57600080fd5b506153c786828701615274565b9150509250925092565b6000826153e0576153e0614cf8565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b16604085015281606085015261542c8285018b61435a565b91508382036080850152615440828a61435a565b915060ff881660a085015283820360c085015261545d828861408f565b90861660e08501528381036101008501529050613f82818561408f565b86815260c06020820152600061549360c083018861408f565b82810360408401526154a5818861408f565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156154fe57600080fd5b82516155098161478b565b60208401519092506144838161443b565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a0810160078310615590577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -2553,11 +2553,11 @@ func (FunctionsCoordinatorBillingEnd) Topic() common.Hash { } func (FunctionsCoordinatorBillingStart) Topic() common.Hash { - return common.HexToHash("0x9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee5422") + return common.HexToHash("0xe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd") } func (FunctionsCoordinatorConfigChanged) Topic() common.Hash { - return common.HexToHash("0x5dafb6dc181e59e476f118ac3f41ca1f23fbd444b37caa205d04e5b1260b2586") + return common.HexToHash("0x9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd73") } func (FunctionsCoordinatorConfigSet) Topic() common.Hash { diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 6f3a5dec50b..81002c1ba6b 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -32,7 +32,7 @@ var ( var FunctionsRouterMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b506040516200620638038062006206833981016040819052620000449162000451565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506007805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001588162000249565b8051602090910120600a555050601080546001600160a01b0390931661010002610100600160a81b03199093169290921790915550620006cb9350505050565b336001600160a01b03821603620001f25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026491906200054e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052601180546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002dc916012919086019062000323565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000315939291906200065a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003c75791602002820160005b838211156200039357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200034d565b8015620003c55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000393565b505b50620003d5929150620003d9565b5090565b5b80821115620003d55760008155600101620003da565b805161ffff811681146200040357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000449576200044962000408565b604052919050565b600080600080608085870312156200046857600080fd5b6200047385620003f0565b9350602062000484818701620003f0565b60408701519094506001600160a01b0381168114620004a257600080fd5b60608701519093506001600160401b0380821115620004c057600080fd5b818801915088601f830112620004d557600080fd5b815181811115620004ea57620004ea62000408565b620004fe601f8201601f191685016200041e565b915080825289848285010111156200051557600080fd5b60005b818110156200053557838101850151838201860152840162000518565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056457600080fd5b83516001600160601b03811681146200057c57600080fd5b602085810151919450906001600160e01b0319811681146200059d57600080fd5b60408601519093506001600160401b0380821115620005bb57600080fd5b818701915087601f830112620005d057600080fd5b815181811115620005e557620005e562000408565b8060051b9150620005f88483016200041e565b818152918301840191848101908a8411156200061357600080fd5b938501935b838510156200064a578451925063ffffffff83168314620006395760008081fd5b828252938501939085019062000618565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bd57845163ffffffff168352938301939183019160010162000699565b509098975050505050505050565b615b2b80620006db6000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610768578063eb523d6c1461077b578063f2fde38b1461078e57600080fd5b8063c4614d611461072f578063d7ae1d3014610742578063e72f6e301461075557600080fd5b8063b5643858116100c8578063b5643858146106fd578063b734c0f414610710578063badc3eb61461071857600080fd5b8063aab396bd146106cc578063b187bd26146106f257600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c769614610682578063a4c0ed36146106a6578063a9c9a918146106b957600080fd5b80639883c10d1461065f5780639f87fad714610667578063a21a23e41461067a57600080fd5b8063823597401161017657806382359740146106215780638da5cb5b146106345780638fde53171461065757600080fd5b80637341c10c1461060657806379ba50971461061957600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461052a5780636a6df79b146105bf57806371ec28ac146105f757600080fd5b806366316d8d146104dd57806366419970146104f0578063665871ec1461051757600080fd5b806354fd4d501161022f57806354fd4d501461045c57806355fedefa146104b35780635c975abb146104c657600080fd5b80633fd67e0514610402578063461d27621461043b57600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103d4578063385de9ae146103dc5780633e871e4d146103ef57600080fd5b80631ded3b36146103ab5780632a905ccc146103be57600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461036957600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc366004614ac7565b6107a1565b005b610301610311366004614b06565b610821565b610301610324366004614b4b565b610918565b600b546801000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103609190614be6565b6103016103b9366004614bf9565b610922565b6011546bffffffffffffffffffffffff16610347565b610301610953565b6103016103ea366004614c6c565b610978565b6103016103fd366004614dcc565b610b5c565b610415610410366004614f2d565b610e76565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610360565b61044e610449366004614fe1565b611225565b604051908152602001610360565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610360565b61044e6104c1366004614ac7565b611281565b60005460ff165b6040519015158152602001610360565b6103016104eb366004615063565b6112a5565b600b5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610360565b61030161052536600461508f565b6114d9565b610597610538366004615104565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600d6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610360565b6105d26105cd36600461513c565b6118ca565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610360565b60405160648152602001610360565b610301610614366004614b06565b6118dd565b610301611a92565b61030161062f366004614ac7565b611bb4565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d2565b610301611d04565b600a5461044e565b610301610675366004614b06565b611d88565b6104fe61219a565b610695610690366004614ac7565b61235a565b6040516103609594939291906151b2565b6103016106b4366004615207565b612448565b6105d26106c7366004615261565b612677565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761044e565b60005460ff166104cd565b61030161070b36600461527a565b612684565b61030161279d565b610720612a13565b60405161036093929190615295565b61039e61073d366004614c6c565b612aee565b610301610750366004614b06565b612b03565b6103016107633660046152f6565b612b64565b6104cd610776366004614ac7565b612d79565b610301610789366004615261565b612d84565b61030161079c3660046152f6565b61300d565b6107a961301e565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610813576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61081d8282613026565b5050565b6108296133f8565b61083282613400565b61083a6134b9565b6108426134f6565b67ffffffffffffffff82166000908152600c602052604090206002015473ffffffffffffffffffffffffffffffffffffffff82811691161461081d5767ffffffffffffffff82166000818152600c602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff86169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61081d82826135f0565b61092a61301e565b61093382613710565b67ffffffffffffffff9091166000908152600c6020526040902060040155565b61095b613779565b60005460ff16156109705761096e6137ff565b565b61096e61387c565b610980613779565b600061098d8460006138d7565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109b75750600a54610a2b565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a04573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a289190615311565b90505b8383604051610a3b92919061532a565b60405180910390208103610a7b576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600754602090910190610ae29062010000900461ffff1643615369565b9052600086815260066020908152604090912082518155908201516001820190610b0c908261541d565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b4d908790849088908890615537565b60405180910390a15050505050565b610b64613779565b8151815181141580610b765750600881115b15610bad576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610ce9576000848260ff1681518110610bd257610bd2615592565b602002602001015190506000848360ff1681518110610bf357610bf3615592565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c5e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c95576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cd4576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b50508080610ce1906155c1565b915050610bb0565b50600754600090610d049062010000900461ffff1643615369565b604080516060810182528681526020808201879052918101839052865192935091600391610d36918391890190614910565b506020828101518051610d4f9260018501920190614957565b506040820151816002015590505060005b84518160ff161015610e6f577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610da257610da2615592565b602002602001015160026000888560ff1681518110610dc357610dc3615592565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e0f57610e0f615592565b602002602001015185604051610e55949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610e67816155c1565b915050610d60565b5050505050565b600080610e816139d9565b610e896134b9565b6000888152600f6020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff90811680835260018401549182169483019490945274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e08301523314610f97576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081015173ffffffffffffffffffffffffffffffffffffffff16610fc057600292505061121a565b8060c00151816060015163ffffffff16610fda9190615369565b5a1015610feb57600392505061121a565b60408082015167ffffffffffffffff166000908152600c602052205460608201516bffffffffffffffffffffffff9091169061102c9063ffffffff16613a46565b61103690886155e0565b868360e001516110469190615610565b6110509190615610565b6bffffffffffffffffffffffff16111561106e57600492505061121a565b80608001516bffffffffffffffffffffffff16611094826060015163ffffffff16613a46565b61109e90886155e0565b868360e001516110ae9190615610565b6110b89190615610565b6bffffffffffffffffffffffff1611156110d657600592505061121a565b6000898152600f60209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000090811690915560038201849055600482018490556005909101805490911690556060830151908301519194508491611177918c918c918c91613ae8565b805190915061118757600161118a565b60005b935060006111b18360400151846080015185602001518660e001518c87602001518d613c66565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516111fa578e6111fc565b8f5b60405161120c949392919061563c565b60405180910390a351925050505b965096945050505050565b600061122f6134b9565b6112768260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613ee39050565b979650505050505050565b67ffffffffffffffff81166000908152600c60205260408120600401545b92915050565b6112ad6133f8565b6112b56134b9565b806bffffffffffffffffffffffff166000036112fd576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e60205260409020546bffffffffffffffffffffffff80831691161015611357576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600e6020526040812080548392906113849084906bffffffffffffffffffffffff16615692565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600b60088282829054906101000a90046bffffffffffffffffffffffff166113db9190615692565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb906044016020604051808303816000875af115801561147f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a391906156b7565b61081d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114e16133f8565b6114e96134b9565b60005b818110156118c557600083838381811061150857611508615592565b602090810292909201356000818152600f8452604090819020815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169682019690965274010000000000000000000000000000000000000000860467ffffffffffffffff169281018390527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16606086015260028101546bffffffffffffffffffffffff9081166080870152600382015460a0870152600482015460c08701526005909101541660e085015290935090506115f181613710565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1633811461165d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260a0015142101561169b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561170a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061172e91906156b7565b156118ad57608084015167ffffffffffffffff84166000908152600c6020819052604090912080549091906117829084906c0100000000000000000000000090046bffffffffffffffffffffffff16615692565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208085015173ffffffffffffffffffffffffffffffffffffffff166000908152600d8252604080822067ffffffffffffffff808816845293529020805460019260099161180791859169010000000000000000009004166156d4565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600f6020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b505050505080806118bd906156f5565b9150506114ec565b505050565b60006118d683836138d7565b9392505050565b6118e56133f8565b6118ee82613400565b6118f66134b9565b6118fe6134f6565b67ffffffffffffffff82166000908152600c60205260409020600301547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611973576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8616845290915290205460ff16156119ba575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600d6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600c84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e0910161090c565b60015473ffffffffffffffffffffffffffffffffffffffff163314611b13576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610ccb565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611bbc6133f8565b611bc46134b9565b611bcc6134f6565b67ffffffffffffffff81166000908152600c60205260409020600181015460029091015473ffffffffffffffffffffffffffffffffffffffff9182169116338114611c5b576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610ccb565b67ffffffffffffffff83166000818152600c6020908152604091829020600181018054337fffffffffffffffffffffffff0000000000000000000000000000000000000000918216811790925560029092018054909216909155825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611d0c613779565b600954431015611d48576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b611d906133f8565b611d9982613400565b611da16134b9565b611da96134f6565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e79576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610ccb565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ece576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600c6020908152604080832060030180548251818502810185019093528083529192909190830182828015611f4957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f1e575b50505050509050600060018251611f60919061572d565b905060005b82518110156120fe578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f9757611f97615592565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120ec576000838381518110611fce57611fce615592565b6020026020010151905080600c60008967ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600301838154811061201457612014615592565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600c9091526040902060030180548061208e5761208e615740565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120fe565b806120f6816156f5565b915050611f65565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600d6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60006121a46133f8565b6121ac6134b9565b6121b46134f6565b600b805467ffffffffffffffff169060006121ce8361576f565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600b546040805160c081018252600080825260208083018281523384860190815260608501848152865185815280850188526080870190815260a0870186905297909816808552600c8452959093208451815492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091178155915160018301805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff00000000000000000000000000000000000000009182161790915596516002840180549190921697169690961790955592518051929650909450919261230a926003850192910190614957565b5060a0919091015160049091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061236b86613710565b67ffffffffffffffff86166000908152600c6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff918216985092169550909183018282801561243857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161240d575b5050505050905091939590929450565b6124506133f8565b6124586134b9565b601054610100900473ffffffffffffffffffffffffffffffffffffffff1633146124ae576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124e8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124f682840184614ac7565b67ffffffffffffffff81166000908152600c602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff16612562576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600c6020526040812080546bffffffffffffffffffffffff16918691906125998385615610565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600b60088282829054906101000a90046bffffffffffffffffffffffff166125f09190615610565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126579190615369565b6040805192835260208301919091520160405180910390a2505050505050565b600061129f8260006138d7565b61268c613779565b60075461ffff8083166201000090920416036126d4576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075461ffff9081169082161115612718576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff6201000090910481168083529084166020830152909182019061274b9043615369565b9052805160088054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009092169316929092179190911790556040015160095550565b6127a5613779565b6005544310156127e1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff1660016127fe9190615796565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff9384160217908190557601000000000000000000000000000000000000000000009004161561288f57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff82161015612a1057600060036000018260ff16815481106128ba576128ba615592565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff861690811061290957612909615592565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915560018054855189815293881694840194909452828501829052606083015261ffff7401000000000000000000000000000000000000000084048116608084015276010000000000000000000000000000000000000000000090930490921660a082015291519092507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99160c0908290030190a15050508080612a08906155c1565b915050612892565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a7357602002820191906000526020600020905b815481526020019060010190808311612a5f575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612adc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612ab1575b50505050509050925092509250909192565b6060612afb848484614307565b949350505050565b612b0b6133f8565b612b1482613400565b612b1c6134b9565b612b246134f6565b612b2d826143d6565b15610813576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b6c61301e565b6010546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612be0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c049190615311565b600b549091506801000000000000000090046bffffffffffffffffffffffff1681811115612c68576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610ccb565b818110156118c5576000612c7c828461572d565b6010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb906044016020604051808303816000875af1158015612cfe573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d2291906156b7565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b600061129f826143d6565b612d8c613779565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612dc69061537c565b80601f0160208091040260200160405190810160405280929190818152602001828054612df29061537c565b8015612e3f5780601f10612e1457610100808354040283529160200191612e3f565b820191906000526020600020905b815481529060010190602001808311612e2257829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e92576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612eb757612ea48160200151614527565b6020808201518051910120600a55612f5f565b612ec28260006138d7565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612efe9190614be6565b600060405180830381600087803b158015612f1857600080fd5b505af1925050508015612f29575060015b612f5f576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff166001612f7c9190615796565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926130019286926157b1565b60405180910390a15050565b613015613779565b612a1081614622565b61096e613779565b61302e6134b9565b67ffffffffffffffff82166000908152600c60209081526040808320815160c08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff90811682850152600283015416606082015260038201805484518187028101870190955280855291949293608086019390929083018282801561310f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116130e4575b505050918352505060049190910154602090910152805190915060005b8260800151518110156131d257600d60008460800151838151811061315357613153615592565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055806131ca816156f5565b91505061312c565b5067ffffffffffffffff84166000908152600c6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff000000000000000000000000000000000000000090811690915560028201805490911690559061325860038301826149d1565b6004820160009055505080600b60088282829054906101000a90046bffffffffffffffffffffffff1661328b9190615692565b82546bffffffffffffffffffffffff91821661010093840a90810290830219909116179092556010546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb906044016020604051808303816000875af1158015613330573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061335491906156b7565b61338a576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b61096e6139d9565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff168061346a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461081d576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60105460ff161561096e576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6135217fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006138d7565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561358f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135b391906156b7565b151560000361096e576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610ccb565b67ffffffffffffffff82166000908152600c6020526040812060040154601254911a908110613650576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610ccb565b6012805460ff831690811061366757613667615592565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff1611156118c5576012805460ff83169081106136b7576136b7615592565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610ccb565b67ffffffffffffffff81166000908152600c602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16612a10576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff16331461096e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610ccb565b61380761471d565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6138846139d9565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138523390565b6000816139165760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16801561391057905061129f565b506139a4565b60005b60035460ff821610156139a2576003805460ff831690811061393d5761393d615592565b90600052602060002001548403613990576004805460ff831690811061396557613965615592565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16915061129f9050565b8061399a816155c1565b915050613919565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610ccb565b60005460ff161561096e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610ccb565b60006bffffffffffffffffffffffff821115613ae4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610ccb565b5090565b60408051808201909152600080825260208201526011546040516000916c01000000000000000000000000900460e01b90613b2b908990899089906024016157d9565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a611388811015613be857600080fd5b611388810390508660408204820311613c0057600080fd5b853b613c0b57600080fd5b60008085516020870160008a8cf192505a601080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613c8584613a46565b613c8f90866155e0565b9050600081613c9e8886615610565b613ca89190615610565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600c909152928320805492975093945084939291613cff91859116615692565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613d399190615610565b336000908152600e602052604081208054909190613d669084906bffffffffffffffffffffffff16615610565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600e6020526040812080548b94509092613dad91859116615610565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555088600c60008c67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c8282829054906101000a90046bffffffffffffffffffffffff16613e2c9190615692565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600d6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613eb091859169010000000000000000009004166156d4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613eed6139d9565b613ef685613710565b613f003386614789565b613f0a85836135f0565b6000613f1688886138d7565b6040805160e08101825233815267ffffffffffffffff891660208083018290526000828152600c808352858220600181015473ffffffffffffffffffffffffffffffffffffffff90811687890152606087018e905261ffff8d166080880152948352925260049182015460a085015263ffffffff891660c085015293517fe1a82d6f0000000000000000000000000000000000000000000000000000000081529495509293849384939287169263e1a82d6f92613fd39201615804565b6080604051808303816000875af1158015613ff2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140169190615897565b9297509094509250905061402b338a85614825565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff16815260200182426140ab9190615369565b8152602001838152602001601160000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff16815250600f600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600c60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516142f1969594939291906158d5565b60405180910390a4505050509695505050505050565b6060600080808061431a86880188615939565b9350935093509350600061433389600187878787613ee3565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156143c95781816020811061437257614372615592565b1a60f81b87828151811061438857614388615592565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350806143c1816156f5565b915050614357565b5050505050509392505050565b67ffffffffffffffff81166000908152600c602090815260408083206003018054825181850281018501909352808352849383018282801561444e57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614423575b5050505050905060005b815181101561451d576000600d600084848151811061447957614479615592565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461450a57506001949350505050565b5080614515816156f5565b915050614458565b5060009392505050565b60008060008380602001905181019061454091906159aa565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052601180547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145eb91601291908601906149ef565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d6b93929190615a93565b3373ffffffffffffffffffffffffffffffffffffffff8216036146a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610ccb565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff1661096e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610ccb565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600d6020908152604080832067ffffffffffffffff8516845290915290205460ff1661081d576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610ccb565b67ffffffffffffffff82166000908152600c60208190526040909120805483929061486f9084906c0100000000000000000000000090046bffffffffffffffffffffffff16615610565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600d6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926148e59284929004166156d4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b82805482825590600052602060002090810192821561494b579160200282015b8281111561494b578251825591602001919060010190614930565b50613ae4929150614a95565b82805482825590600052602060002090810192821561494b579160200282015b8281111561494b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614977565b5080546000825590600052602060002090810190612a109190614a95565b8280548282559060005260206000209060070160089004810192821561494b5791602002820160005b83821115614a5c57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a18565b8015614a8c5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a5c565b5050613ae49291505b5b80821115613ae45760008155600101614a96565b803567ffffffffffffffff81168114614ac257600080fd5b919050565b600060208284031215614ad957600080fd5b6118d682614aaa565b803573ffffffffffffffffffffffffffffffffffffffff81168114614ac257600080fd5b60008060408385031215614b1957600080fd5b614b2283614aaa565b9150614b3060208401614ae2565b90509250929050565b63ffffffff81168114612a1057600080fd5b60008060408385031215614b5e57600080fd5b614b6783614aaa565b91506020830135614b7781614b39565b809150509250929050565b6000815180845260005b81811015614ba857602081850181015186830182015201614b8c565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118d66020830184614b82565b60008060408385031215614c0c57600080fd5b614c1583614aaa565b946020939093013593505050565b60008083601f840112614c3557600080fd5b50813567ffffffffffffffff811115614c4d57600080fd5b602083019150836020828501011115614c6557600080fd5b9250929050565b600080600060408486031215614c8157600080fd5b83359250602084013567ffffffffffffffff811115614c9f57600080fd5b614cab86828701614c23565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d2e57614d2e614cb8565b604052919050565b600067ffffffffffffffff821115614d5057614d50614cb8565b5060051b60200190565b600082601f830112614d6b57600080fd5b81356020614d80614d7b83614d36565b614ce7565b82815260059290921b84018101918181019086841115614d9f57600080fd5b8286015b84811015614dc157614db481614ae2565b8352918301918301614da3565b509695505050505050565b60008060408385031215614ddf57600080fd5b823567ffffffffffffffff80821115614df757600080fd5b818501915085601f830112614e0b57600080fd5b81356020614e1b614d7b83614d36565b82815260059290921b84018101918181019089841115614e3a57600080fd5b948201945b83861015614e5857853582529482019490820190614e3f565b96505086013592505080821115614e6e57600080fd5b50614e7b85828601614d5a565b9150509250929050565b600082601f830112614e9657600080fd5b813567ffffffffffffffff811115614eb057614eb0614cb8565b614ee160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614ce7565b818152846020838601011115614ef657600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612a1057600080fd5b60008060008060008060c08789031215614f4657600080fd5b86359550602087013567ffffffffffffffff80821115614f6557600080fd5b614f718a838b01614e85565b96506040890135915080821115614f8757600080fd5b50614f9489828a01614e85565b9450506060870135614fa581614f13565b92506080870135614fb581614f13565b9150614fc360a08801614ae2565b90509295509295509295565b803561ffff81168114614ac257600080fd5b60008060008060008060a08789031215614ffa57600080fd5b61500387614aaa565b9550602087013567ffffffffffffffff81111561501f57600080fd5b61502b89828a01614c23565b909650945061503e905060408801614fcf565b9250606087013561504e81614b39565b80925050608087013590509295509295509295565b6000806040838503121561507657600080fd5b61507f83614ae2565b91506020830135614b7781614f13565b600080602083850312156150a257600080fd5b823567ffffffffffffffff808211156150ba57600080fd5b818501915085601f8301126150ce57600080fd5b8135818111156150dd57600080fd5b8660208260051b85010111156150f257600080fd5b60209290920196919550909350505050565b6000806040838503121561511757600080fd5b61512083614ae2565b9150614b3060208401614aaa565b8015158114612a1057600080fd5b6000806040838503121561514f57600080fd5b823591506020830135614b778161512e565b600081518084526020808501945080840160005b838110156151a757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615175565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061127690830184615161565b6000806000806060858703121561521d57600080fd5b61522685614ae2565b935060208501359250604085013567ffffffffffffffff81111561524957600080fd5b61525587828801614c23565b95989497509550505050565b60006020828403121561527357600080fd5b5035919050565b60006020828403121561528c57600080fd5b6118d682614fcf565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156152d6578451835293830193918301916001016152ba565b505084810360408601526152ea8187615161565b98975050505050505050565b60006020828403121561530857600080fd5b6118d682614ae2565b60006020828403121561532357600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561129f5761129f61533a565b600181811c9082168061539057607f821691505b6020821081036153c9577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156118c557600081815260208120601f850160051c810160208610156153f65750805b601f850160051c820191505b8181101561541557828155600101615402565b505050505050565b815167ffffffffffffffff81111561543757615437614cb8565b61544b81615445845461537c565b846153cf565b602080601f83116001811461549e57600084156154685750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615415565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156154eb578886015182559484019460019091019084016154cc565b508582101561552757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036155d7576155d761533a565b60010192915050565b6bffffffffffffffffffffffff8181168382160280821691908281146156085761560861533a565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156156355761563561533a565b5092915050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006156886080830184614b82565b9695505050505050565b6bffffffffffffffffffffffff8281168282160390808211156156355761563561533a565b6000602082840312156156c957600080fd5b81516118d68161512e565b67ffffffffffffffff8181168382160190808211156156355761563561533a565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036157265761572661533a565b5060010190565b8181038181111561129f5761129f61533a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361578c5761578c61533a565b6001019392505050565b61ffff8181168382160190808211156156355761563561533a565b8381528260208201526060604082015260006157d06060830184614b82565b95945050505050565b8381526060602082015260006157f26060830185614b82565b82810360408401526156888185614b82565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015267ffffffffffffffff602085015116604084015280604085015116606084015250606083015160e06080840152615863610100840182614b82565b905061ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b600080600080608085870312156158ad57600080fd5b8451935060208501516158bf81614f13565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261591660c0830186614b82565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b6000806000806080858703121561594f57600080fd5b61595885614aaa565b9350602085013567ffffffffffffffff81111561597457600080fd5b61598087828801614e85565b93505061598f60408601614fcf565b9150606085013561599f81614b39565b939692955090935050565b6000806000606084860312156159bf57600080fd5b83516159ca81614f13565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615a0257600080fd5b604086015190935067ffffffffffffffff811115615a1f57600080fd5b8501601f81018713615a3057600080fd5b8051615a3e614d7b82614d36565b81815260059190911b82018301908381019089831115615a5d57600080fd5b928401925b82841015615a84578351615a7581614b39565b82529284019290840190615a62565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615b1057845163ffffffff1683529383019391830191600101615aee565b50909897505050505050505056fea164736f6c6343000813000a", + Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200619b3803806200619b833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615ab880620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610753578063eb523d6c14610766578063f2fde38b1461077957600080fd5b8063c4614d611461071a578063d7ae1d301461072d578063e72f6e301461074057600080fd5b8063b5643858116100c8578063b5643858146106e8578063b734c0f4146106fb578063badc3eb61461070357600080fd5b8063aab396bd146106b7578063b187bd26146106dd57600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c76961461066d578063a4c0ed3614610691578063a9c9a918146106a457600080fd5b80639883c10d1461064a5780639f87fad714610652578063a21a23e41461066557600080fd5b80638235974011610176578063823597401461060c5780638da5cb5b1461061f5780638fde53171461064257600080fd5b80637341c10c146105f157806379ba50971461060457600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d0146105155780636a6df79b146105aa57806371ec28ac146105e257600080fd5b806366316d8d146104bb57806366419970146104ce578063665871ec1461050257600080fd5b806354fd4d501161022f57806354fd4d501461046557806355fedefa146104915780635c975abb146104a457600080fd5b80633fd67e051461040b578063461d27621461044457600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103dd578063385de9ae146103e55780633e871e4d146103f857600080fd5b80631ded3b36146103b45780632a905ccc146103c757600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461037257600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc366004614a2c565b61078c565b005b610301610311366004614a6b565b610819565b610301610324366004614ab0565b61091e565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103699190614b4b565b6103016103c2366004614b5e565b610928565b600f546bffffffffffffffffffffffff16610350565b610301610959565b6103016103f3366004614bd1565b61097e565b610301610406366004614d31565b610b66565b61041e610419366004614e92565b610e80565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610369565b610457610452366004614f46565b61120b565b604051908152602001610369565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610369565b61045761049f366004614a2c565b611267565b60005460ff165b6040519015158152602001610369565b6103016104c9366004614fc8565b61128b565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610369565b610301610510366004614ff4565b6114ba565b610582610523366004615069565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610369565b6105bd6105b83660046150a1565b611887565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610369565b60405160648152602001610369565b6103016105ff366004614a6b565b61189a565b610301611a4f565b61030161061a366004614a2c565b611b71565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105bd565b610301611cc8565b600754610457565b610301610660366004614a6b565b611d77565b6104e9612187565b61068061067b366004614a2c565b612328565b604051610369959493929190615117565b61030161069f36600461516c565b612414565b6105bd6106b23660046151c6565b61264b565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610457565b60005460ff166104ab565b6103016106f63660046151df565b612658565b6103016127b7565b61070b6129cb565b604051610369939291906151fa565b6103a7610728366004614bd1565b612aa6565b61030161073b366004614a6b565b612abb565b61030161074e36600461525b565b612b1c565b6104ab610761366004614a2c565b612d2e565b6103016107743660046151c6565b612d39565b61030161078736600461525b565b612fa9565b610794612fba565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061080b576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108158282612fc2565b5050565b610821613338565b61082a82613340565b610832613406565b61083a61344f565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108155767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b6108158282613544565b610930612fba565b61093982613664565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b6109616136da565b60005460ff161561097657610974613760565b565b6109746137dd565b6109866136da565b6000610993846000613838565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109bd5750600754610a31565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a0a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a2e9190615276565b90505b8383604051610a4192919061528f565b60405180910390208103610a81576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610aec906601000000000000900461ffff16436152ce565b9052600086815260066020908152604090912082518155908201516001820190610b169082615382565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b5790879084908890889061549c565b60405180910390a15050505050565b610b6e6136da565b8151815181141580610b805750600881115b15610bb7576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610cf1576000848260ff1681518110610bdc57610bdc6154f7565b602002602001015190506000848360ff1681518110610bfd57610bfd6154f7565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c68575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c9f576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cde576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610cea90615526565b9050610bba565b50600954600090610d10906601000000000000900461ffff16436152ce565b604080516060810182528681526020808201879052918101839052865192935091600391610d42918391890190614875565b506020828101518051610d5b92600185019201906148bc565b506040820151816002015590505060005b84518160ff161015610e79577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610dae57610dae6154f7565b602002602001015160026000888560ff1681518110610dcf57610dcf6154f7565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e1b57610e1b6154f7565b602002602001015185604051610e61949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e7281615526565b9050610d6c565b5050505050565b600080610e8b613938565b610e93613406565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314610fd5576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff16610ffe576002925050611200565b8060e00151816080015163ffffffff166110189190615545565b6effffffffffffffffffffffffffffff165a101561103a576003925050611200565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff9091169061107d9063ffffffff166139a5565b6110879088615574565b82516110949088906155a4565b61109e91906155a4565b6bffffffffffffffffffffffff1611156110bc576004925050611200565b8060a001516bffffffffffffffffffffffff166110e2826080015163ffffffff166139a5565b6110ec9088615574565b82516110f99088906155a4565b61110391906155a4565b6bffffffffffffffffffffffff161115611121576005925050611200565b6000898152600e602052604080822082815560018101839055600201829055608083015190830151919450849161115d918c918c918c91613a47565b805190915061116d576001611170565b60005b9350600061119783606001518460a00151856040015186600001518c87602001518d613bcd565b9050826060015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516111e0578e6111e2565b8f5b6040516111f294939291906155c9565b60405180910390a351925050505b965096945050505050565b6000611215613406565b61125c8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e1f9050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b611293613338565b61129b613406565b806bffffffffffffffffffffffff166000036112e3576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561133d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061136a9084906bffffffffffffffffffffffff1661561f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113c1919061561f565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611460573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114849190615644565b610815576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114c2613338565b6114ca613406565b60005b818110156118825760008383838181106114e9576114e96154f7565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e082015290935091905061160c81613664565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16338114611685576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156116ca576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561173c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117609190615644565b1561186c5760a084015167ffffffffffffffff84166000908152600b6020526040812060010180549091906117a49084906bffffffffffffffffffffffff1661561f565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff80881684529152919020805460019260099161182b9185916901000000000000000000900416615661565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b50505050508061187b90615682565b90506114cd565b505050565b60006118938383613838565b9392505050565b6118a2613338565b6118ab82613340565b6118b3613406565b6118bb61344f565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611930576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611977575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610912565b60015473ffffffffffffffffffffffffffffffffffffffff163314611ad0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cd5565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b79613338565b611b81613406565b611b8961344f565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611c29576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cd5565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611cd06136da565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611d32576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b611d7f613338565b611d8882613340565b611d90613406565b611d9861344f565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e68576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cd5565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ebd576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f3857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f0d575b50505050509050600060018251611f4f91906156ba565b905060005b82518110156120eb578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f8657611f866154f7565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120db576000838381518110611fbd57611fbd6154f7565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110612003576120036154f7565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061207d5761207d6156cd565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120eb565b6120e481615682565b9050611f54565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000612191613338565b612199613406565b6121a161344f565b6009805481906121c7906901000000000000000000900467ffffffffffffffff166156fc565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c081018252600080825233602083015291810182905260608101829052919250608082019060405190808252806020026020018201604052801561223d578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926122d8926002850192909101906148bc565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061233986613664565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561240457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116123d9575b5050505050905091939590929450565b61241c613338565b612424613406565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612475576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124af576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124bd82840184614a2c565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612536576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff169186919061256d83856155a4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff166125c491906155a4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461262b91906152ce565b6040805192835260208301919091520160405180910390a2505050505050565b6000611285826000613838565b6126606136da565b60095461ffff808316660100000000000090920416036126ac576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff640100000000909104811690821611156126f8576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff660100000000000090910481168083529084166020830152909182019061272f90436152ce565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b6127bf6136da565b6005544310156127fb576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461280d9061ffff166001615723565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff9283161790819055620100009004161561287357600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff821610156129c857600060036000018260ff168154811061289e5761289e6154f7565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff86169081106128ed576128ed6154f7565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a1505050806129c190615526565b9050612876565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a2b57602002820191906000526020600020905b815481526020019060010190808311612a17575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612a9457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a69575b50505050509050925092509250909192565b6060612ab3848484614280565b949350505050565b612ac3613338565b612acc82613340565b612ad4613406565b612adc61344f565b612ae58261434d565b1561080b576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b24612fba565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612b93573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bb79190615276565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612c24576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cd5565b81811015611882576000612c3882846156ba565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612cb3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cd79190615644565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112858261434d565b612d416136da565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612d7b906152e1565b80601f0160208091040260200160405190810160405280929190818152602001828054612da7906152e1565b8015612df45780601f10612dc957610100808354040283529160200191612df4565b820191906000526020600020905b815481529060010190602001808311612dd757829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e47576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612e6c57612e59816020015161449c565b6020808201518051910120600755612f14565b612e77826000613838565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612eb39190614b4b565b600060405180830381600087803b158015612ecd57600080fd5b505af1925050508015612ede575060015b612f14576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612f2c9062010000900461ffff166001615723565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612f9d92869261573e565b60405180910390a15050565b612fb16136da565b6129c881614597565b6109746136da565b612fca613406565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156130ab57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613080575b505050918352505060039190910154602090910152805190915060005b82608001515181101561316c57600c6000846080015183815181106130ef576130ef6154f7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561316581615682565b90506130c8565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061319e6002830182614936565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff166131d1919061561f565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613270573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132949190615644565b6132ca576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b610974613938565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16806133b7576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610815576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095468010000000000000000900460ff1615610974576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61347a7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613838565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af11580156134e8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061350c9190615644565b610974576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cd5565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a9081106135a4576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cd5565b6010805460ff83169081106135bb576135bb6154f7565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611882576010805460ff831690811061360b5761360b6154f7565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cd5565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166129c8576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610974576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cd5565b613768614692565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6137e5613938565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137b33390565b6000816138775760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613871579050611285565b50613903565b60005b60035460ff82161015613901576003805460ff831690811061389e5761389e6154f7565b906000526020600020015484036138f1576004805460ff83169081106138c6576138c66154f7565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112859050565b6138fa81615526565b905061387a565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cd5565b60005460ff1615610974576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cd5565b60006bffffffffffffffffffffffff821115613a43576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cd5565b5090565b6040805180820190915260008082526020820152600f546040516000916c01000000000000000000000000900460e01b90613a8a90899089908990602401615766565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff166801000000000000000017905590506000805a611388811015613b4f57600080fd5b611388810390508660408204820311613b6757600080fd5b853b613b7257600080fd5b60008085516020870160008a8cf192505a600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613bec846139a5565b613bf69086615574565b9050600081613c0588866155a4565b613c0f91906155a4565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613c669185911661561f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613ca091906155a4565b336000908152600d602052604081208054909190613ccd9084906bffffffffffffffffffffffff166155a4565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613d14918591166155a4565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613d689185911661561f565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613dec9185916901000000000000000000900416615661565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613e29613938565b613e3285613664565b613e3c33866146fe565b613e468583613544565b6000613e528888613838565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c591613f1d91600401615791565b6080604051808303816000875af1158015613f3c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f609190615824565b92975090945092509050613f75338a8561479a565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c08101613feb83426152ce565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161426a96959493929190615862565b60405180910390a4505050509695505050505050565b60606000808080614293868801886158c6565b935093509350935060006142ac89600187878787613e1f565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614340578181602081106142eb576142eb6154f7565b1a60f81b878281518110614301576143016154f7565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061433981615682565b90506142d0565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156143c557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161439a575b5050505050905060005b8151811015614492576000600c60008484815181106143f0576143f06154f7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461448157506001949350505050565b5061448b81615682565b90506143cf565b5060009392505050565b6000806000838060200190518101906144b59190615937565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145609160109190860190614954565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d2093929190615a20565b3373ffffffffffffffffffffffffffffffffffffffff821603614616576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cd5565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610974576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cd5565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610815576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cd5565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906147d49084906bffffffffffffffffffffffff166155a4565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261484a928492900416615661565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b8280548282559060005260206000209081019282156148b0579160200282015b828111156148b0578251825591602001919060010190614895565b50613a439291506149fa565b8280548282559060005260206000209081019282156148b0579160200282015b828111156148b057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906148dc565b50805460008255906000526020600020908101906129c891906149fa565b828054828255906000526020600020906007016008900481019282156148b05791602002820160005b838211156149c157835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261497d565b80156149f15782816101000a81549063ffffffff02191690556004016020816003010492830192600103026149c1565b5050613a439291505b5b80821115613a4357600081556001016149fb565b803567ffffffffffffffff81168114614a2757600080fd5b919050565b600060208284031215614a3e57600080fd5b61189382614a0f565b803573ffffffffffffffffffffffffffffffffffffffff81168114614a2757600080fd5b60008060408385031215614a7e57600080fd5b614a8783614a0f565b9150614a9560208401614a47565b90509250929050565b63ffffffff811681146129c857600080fd5b60008060408385031215614ac357600080fd5b614acc83614a0f565b91506020830135614adc81614a9e565b809150509250929050565b6000815180845260005b81811015614b0d57602081850181015186830182015201614af1565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118936020830184614ae7565b60008060408385031215614b7157600080fd5b614b7a83614a0f565b946020939093013593505050565b60008083601f840112614b9a57600080fd5b50813567ffffffffffffffff811115614bb257600080fd5b602083019150836020828501011115614bca57600080fd5b9250929050565b600080600060408486031215614be657600080fd5b83359250602084013567ffffffffffffffff811115614c0457600080fd5b614c1086828701614b88565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614c9357614c93614c1d565b604052919050565b600067ffffffffffffffff821115614cb557614cb5614c1d565b5060051b60200190565b600082601f830112614cd057600080fd5b81356020614ce5614ce083614c9b565b614c4c565b82815260059290921b84018101918181019086841115614d0457600080fd5b8286015b84811015614d2657614d1981614a47565b8352918301918301614d08565b509695505050505050565b60008060408385031215614d4457600080fd5b823567ffffffffffffffff80821115614d5c57600080fd5b818501915085601f830112614d7057600080fd5b81356020614d80614ce083614c9b565b82815260059290921b84018101918181019089841115614d9f57600080fd5b948201945b83861015614dbd57853582529482019490820190614da4565b96505086013592505080821115614dd357600080fd5b50614de085828601614cbf565b9150509250929050565b600082601f830112614dfb57600080fd5b813567ffffffffffffffff811115614e1557614e15614c1d565b614e4660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614c4c565b818152846020838601011115614e5b57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129c857600080fd5b60008060008060008060c08789031215614eab57600080fd5b86359550602087013567ffffffffffffffff80821115614eca57600080fd5b614ed68a838b01614dea565b96506040890135915080821115614eec57600080fd5b50614ef989828a01614dea565b9450506060870135614f0a81614e78565b92506080870135614f1a81614e78565b9150614f2860a08801614a47565b90509295509295509295565b803561ffff81168114614a2757600080fd5b60008060008060008060a08789031215614f5f57600080fd5b614f6887614a0f565b9550602087013567ffffffffffffffff811115614f8457600080fd5b614f9089828a01614b88565b9096509450614fa3905060408801614f34565b92506060870135614fb381614a9e565b80925050608087013590509295509295509295565b60008060408385031215614fdb57600080fd5b614fe483614a47565b91506020830135614adc81614e78565b6000806020838503121561500757600080fd5b823567ffffffffffffffff8082111561501f57600080fd5b818501915085601f83011261503357600080fd5b81358181111561504257600080fd5b8660208260051b850101111561505757600080fd5b60209290920196919550909350505050565b6000806040838503121561507c57600080fd5b61508583614a47565b9150614a9560208401614a0f565b80151581146129c857600080fd5b600080604083850312156150b457600080fd5b823591506020830135614adc81615093565b600081518084526020808501945080840160005b8381101561510c57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016150da565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061125c908301846150c6565b6000806000806060858703121561518257600080fd5b61518b85614a47565b935060208501359250604085013567ffffffffffffffff8111156151ae57600080fd5b6151ba87828801614b88565b95989497509550505050565b6000602082840312156151d857600080fd5b5035919050565b6000602082840312156151f157600080fd5b61189382614f34565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561523b5784518352938301939183019160010161521f565b5050848103604086015261524f81876150c6565b98975050505050505050565b60006020828403121561526d57600080fd5b61189382614a47565b60006020828403121561528857600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112855761128561529f565b600181811c908216806152f557607f821691505b60208210810361532e577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561188257600081815260208120601f850160051c8101602086101561535b5750805b601f850160051c820191505b8181101561537a57828155600101615367565b505050505050565b815167ffffffffffffffff81111561539c5761539c614c1d565b6153b0816153aa84546152e1565b84615334565b602080601f83116001811461540357600084156153cd5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561537a565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561545057888601518255948401946001909101908401615431565b508582101561548c57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361553c5761553c61529f565b60010192915050565b6effffffffffffffffffffffffffffff81811683821601908082111561556d5761556d61529f565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461559c5761559c61529f565b505092915050565b6bffffffffffffffffffffffff81811683821601908082111561556d5761556d61529f565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006156156080830184614ae7565b9695505050505050565b6bffffffffffffffffffffffff82811682821603908082111561556d5761556d61529f565b60006020828403121561565657600080fd5b815161189381615093565b67ffffffffffffffff81811683821601908082111561556d5761556d61529f565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036156b3576156b361529f565b5060010190565b818103818111156112855761128561529f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157195761571961529f565b6001019392505050565b61ffff81811683821601908082111561556d5761556d61529f565b83815282602082015260606040820152600061575d6060830184614ae7565b95945050505050565b83815260606020820152600061577f6060830185614ae7565b82810360408401526156158185614ae7565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e060608401526157dc610100840182614ae7565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b6000806000806080858703121561583a57600080fd5b84519350602085015161584c81614e78565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c060608301526158a360c0830186614ae7565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b600080600080608085870312156158dc57600080fd5b6158e585614a0f565b9350602085013567ffffffffffffffff81111561590157600080fd5b61590d87828801614dea565b93505061591c60408601614f34565b9150606085013561592c81614a9e565b939692955090935050565b60008060006060848603121561594c57600080fd5b835161595781614e78565b809350506020808501517fffffffff000000000000000000000000000000000000000000000000000000008116811461598f57600080fd5b604086015190935067ffffffffffffffff8111156159ac57600080fd5b8501601f810187136159bd57600080fd5b80516159cb614ce082614c9b565b81815260059190911b820183019083810190898311156159ea57600080fd5b928401925b82841015615a11578351615a0281614a9e565b825292840192908401906159ef565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615a9d57845163ffffffff1683529383019391830191600101615a7b565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index a4f5046baf0..c02ec3feba2 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,10 +1,10 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 1020231df9e071930530d1d1e495bc0914311247633652fa1e2ce29e4bce39df +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin c1e05728f436bfc4ee2d93cc22b555c4d86b25b522ebe10b76203472927dfbbc functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 -functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin ea01c8210316c767b4925731a55ee03bfe5cf04f1c4663aa3115bbc36b94d01f -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b4c8fce90c7aaa68d1af53442e6c44505d090636a18e50b58c0d16d50dcf35aa -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 19ac653ad69dd9c06cb511e02f6973075cfff8ffcd859dacf1405069743b0d0e +functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 747aece848474708a007de3deb6d6e76c6407ac8850c84db6aa294acdf289d21 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin aefc4795c28e52f4cfb9f2374b7c31a19583fb113219c2378ef74dd351be1c8b +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 4cd0561e55e40ace00225c608ca5422282096ea8c8057b7b4f756d2c63cdb1e8 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index c67e689234c..e61032335dd 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -669,7 +669,7 @@ func ClientTestRequests( go func() { defer wg.Done() gomega.NewGomegaWithT(t).Eventually(func() [32]byte { - answer, err := clientContracts[ic].Contract.LastResponse(nil) + answer, err := clientContracts[ic].Contract.SLastResponse(nil) require.NoError(t, err) return answer }, timeout, 1*time.Second).Should(gomega.Equal(GetExpectedResponse(requestSources[ic]))) From 521a9885ddf9d288823a05e2821c486709c1efa5 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Sun, 30 Jul 2023 13:15:59 -0400 Subject: [PATCH 035/270] (feat): Return user callback return data (#9986) --- .../functions/dev/1_0_0/FunctionsRouter.sol | 47 ++++++++++++++----- .../functions_router/functions_router.go | 31 ++++++++++-- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 3 files changed, 64 insertions(+), 16 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 4f2c0b35a86..df6565c6030 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -9,6 +9,11 @@ import {ITermsOfServiceAllowList} from "./accessControl/interfaces/ITermsOfServi import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { + // We limit return data to a selector plus 4 words. This is to avoid + // malicious contracts from returning large amounts of data and causing + // repeated out-of-gas scenarios. + uint16 public constant MAX_CALLBACK_RETURN_BYTES = 4 + 4 * 32; + event RequestStart( bytes32 indexed requestId, bytes32 indexed donId, @@ -27,7 +32,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 totalCostJuels, address transmitter, uint8 resultCode, - bytes response + bytes response, + bytes returnData ); error OnlyCallableFromCoordinator(); @@ -38,6 +44,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions struct CallbackResult { bool success; uint256 gasUsed; + bytes returnData; } // Identifier for the route to the Terms of Service Allow List @@ -288,7 +295,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions receipt.totalCostJuels, transmitter, resultCode, - result.success ? response : err // TODO: handle more response data scenarios + result.success ? response : err, + result.returnData ); return (resultCode, receipt.callbackGasCostJuels); @@ -317,16 +325,25 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bool success; uint256 gasUsed; + // allocate return data memory ahead of time + bytes memory returnData = new bytes(MAX_CALLBACK_RETURN_BYTES); // solhint-disable-next-line no-inline-assembly assembly { + // solidity calls check that a contract actually exists at the destination, so we do the same + // Note we do this check prior to measuring gas so gasForCallExactCheck (our "cushion") + // doesn't need to account for it. + if iszero(extcodesize(client)) { + revert(0, 0) + } + let g := gas() - // GAS_FOR_CALL_EXACT_CHECK = 5000 - // Compute g -= GAS_FOR_CALL_EXACT_CHECK and check for underflow - // The gas actually passed to the callee is min(gasAmount, 63//64*gas available). + // GASFORCALLEXACTCHECK = 5000 + // Compute g -= gasForCallExactCheck and check for underflow + // The gas actually passed to the callee is _min(gasAmount, 63//64*gas available). // We want to ensure that we revert if gasAmount > 63//64*gas available // as we do not want to provide them with less, however that check itself costs - // gas. GAS_FOR_CALL_EXACT_CHECK ensures we have at least enough gas to be able + // gas. gasForCallExactCheck ensures we have at least enough gas to be able // to revert if gasAmount > 63//64*gas available. if lt(g, 5000) { revert(0, 0) @@ -337,19 +354,25 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions if iszero(gt(sub(g, div(g, 64)), callbackGasLimit)) { revert(0, 0) } - // solidity calls check that a contract actually exists at the destination, so we do the same - if iszero(extcodesize(client)) { - revert(0, 0) - } - // call and return whether we succeeded. ignore return data + // call and whether we succeeded // call(gas,addr,value,argsOffset,argsLength,retOffset,retLength) success := call(callbackGasLimit, client, 0, add(encodedCallback, 0x20), mload(encodedCallback), 0, 0) gasUsed := sub(g, gas()) + + // limit our copy to MAX_CALLBACK_RETURN_BYTES bytes + let toCopy := returndatasize() + if gt(toCopy, MAX_CALLBACK_RETURN_BYTES) { + toCopy := MAX_CALLBACK_RETURN_BYTES + } + // Store the length of the copied bytes + mstore(returnData, toCopy) + // copy the bytes from returnData[0:_toCopy] + returndatacopy(add(returnData, 0x20), 0, toCopy) } s_reentrancyLock = false; - result = CallbackResult(success, gasUsed); + result = CallbackResult(success, gasUsed, returnData); } /** diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 81002c1ba6b..0e9b25d74ca 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -31,8 +31,8 @@ var ( ) var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200619b3803806200619b833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615ab880620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102e95760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610753578063eb523d6c14610766578063f2fde38b1461077957600080fd5b8063c4614d611461071a578063d7ae1d301461072d578063e72f6e301461074057600080fd5b8063b5643858116100c8578063b5643858146106e8578063b734c0f4146106fb578063badc3eb61461070357600080fd5b8063aab396bd146106b7578063b187bd26146106dd57600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c76961461066d578063a4c0ed3614610691578063a9c9a918146106a457600080fd5b80639883c10d1461064a5780639f87fad714610652578063a21a23e41461066557600080fd5b80638235974011610176578063823597401461060c5780638da5cb5b1461061f5780638fde53171461064257600080fd5b80637341c10c146105f157806379ba50971461060457600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d0146105155780636a6df79b146105aa57806371ec28ac146105e257600080fd5b806366316d8d146104bb57806366419970146104ce578063665871ec1461050257600080fd5b806354fd4d501161022f57806354fd4d501461046557806355fedefa146104915780635c975abb146104a457600080fd5b80633fd67e051461040b578063461d27621461044457600080fd5b80631ded3b36116102a157806336566f061161028657806336566f06146103dd578063385de9ae146103e55780633e871e4d146103f857600080fd5b80631ded3b36146103b45780632a905ccc146103c757600080fd5b806310fc49c1116102d257806310fc49c11461031657806312b5834914610329578063181f5a771461037257600080fd5b806302bcc5b6146102ee57806304c357cb14610303575b600080fd5b6103016102fc366004614a2c565b61078c565b005b610301610311366004614a6b565b610819565b610301610324366004614ab0565b61091e565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103699190614b4b565b6103016103c2366004614b5e565b610928565b600f546bffffffffffffffffffffffff16610350565b610301610959565b6103016103f3366004614bd1565b61097e565b610301610406366004614d31565b610b66565b61041e610419366004614e92565b610e80565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610369565b610457610452366004614f46565b61120b565b604051908152602001610369565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610369565b61045761049f366004614a2c565b611267565b60005460ff165b6040519015158152602001610369565b6103016104c9366004614fc8565b61128b565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610369565b610301610510366004614ff4565b6114ba565b610582610523366004615069565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610369565b6105bd6105b83660046150a1565b611887565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610369565b60405160648152602001610369565b6103016105ff366004614a6b565b61189a565b610301611a4f565b61030161061a366004614a2c565b611b71565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105bd565b610301611cc8565b600754610457565b610301610660366004614a6b565b611d77565b6104e9612187565b61068061067b366004614a2c565b612328565b604051610369959493929190615117565b61030161069f36600461516c565b612414565b6105bd6106b23660046151c6565b61264b565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610457565b60005460ff166104ab565b6103016106f63660046151df565b612658565b6103016127b7565b61070b6129cb565b604051610369939291906151fa565b6103a7610728366004614bd1565b612aa6565b61030161073b366004614a6b565b612abb565b61030161074e36600461525b565b612b1c565b6104ab610761366004614a2c565b612d2e565b6103016107743660046151c6565b612d39565b61030161078736600461525b565b612fa9565b610794612fba565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061080b576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108158282612fc2565b5050565b610821613338565b61082a82613340565b610832613406565b61083a61344f565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108155767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b6108158282613544565b610930612fba565b61093982613664565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b6109616136da565b60005460ff161561097657610974613760565b565b6109746137dd565b6109866136da565b6000610993846000613838565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109bd5750600754610a31565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a0a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a2e9190615276565b90505b8383604051610a4192919061528f565b60405180910390208103610a81576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610aec906601000000000000900461ffff16436152ce565b9052600086815260066020908152604090912082518155908201516001820190610b169082615382565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b5790879084908890889061549c565b60405180910390a15050505050565b610b6e6136da565b8151815181141580610b805750600881115b15610bb7576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610cf1576000848260ff1681518110610bdc57610bdc6154f7565b602002602001015190506000848360ff1681518110610bfd57610bfd6154f7565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c68575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c9f576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cde576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610cea90615526565b9050610bba565b50600954600090610d10906601000000000000900461ffff16436152ce565b604080516060810182528681526020808201879052918101839052865192935091600391610d42918391890190614875565b506020828101518051610d5b92600185019201906148bc565b506040820151816002015590505060005b84518160ff161015610e79577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610dae57610dae6154f7565b602002602001015160026000888560ff1681518110610dcf57610dcf6154f7565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e1b57610e1b6154f7565b602002602001015185604051610e61949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e7281615526565b9050610d6c565b5050505050565b600080610e8b613938565b610e93613406565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314610fd5576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff16610ffe576002925050611200565b8060e00151816080015163ffffffff166110189190615545565b6effffffffffffffffffffffffffffff165a101561103a576003925050611200565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff9091169061107d9063ffffffff166139a5565b6110879088615574565b82516110949088906155a4565b61109e91906155a4565b6bffffffffffffffffffffffff1611156110bc576004925050611200565b8060a001516bffffffffffffffffffffffff166110e2826080015163ffffffff166139a5565b6110ec9088615574565b82516110f99088906155a4565b61110391906155a4565b6bffffffffffffffffffffffff161115611121576005925050611200565b6000898152600e602052604080822082815560018101839055600201829055608083015190830151919450849161115d918c918c918c91613a47565b805190915061116d576001611170565b60005b9350600061119783606001518460a00151856040015186600001518c87602001518d613bcd565b9050826060015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b05208360200151898987600001516111e0578e6111e2565b8f5b6040516111f294939291906155c9565b60405180910390a351925050505b965096945050505050565b6000611215613406565b61125c8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e1f9050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b611293613338565b61129b613406565b806bffffffffffffffffffffffff166000036112e3576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561133d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061136a9084906bffffffffffffffffffffffff1661561f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113c1919061561f565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611460573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114849190615644565b610815576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114c2613338565b6114ca613406565b60005b818110156118825760008383838181106114e9576114e96154f7565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e082015290935091905061160c81613664565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16338114611685576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156116ca576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561173c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117609190615644565b1561186c5760a084015167ffffffffffffffff84166000908152600b6020526040812060010180549091906117a49084906bffffffffffffffffffffffff1661561f565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff80881684529152919020805460019260099161182b9185916901000000000000000000900416615661565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b50505050508061187b90615682565b90506114cd565b505050565b60006118938383613838565b9392505050565b6118a2613338565b6118ab82613340565b6118b3613406565b6118bb61344f565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611930576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611977575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610912565b60015473ffffffffffffffffffffffffffffffffffffffff163314611ad0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cd5565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b79613338565b611b81613406565b611b8961344f565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611c29576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cd5565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611cd06136da565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611d32576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b611d7f613338565b611d8882613340565b611d90613406565b611d9861344f565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e68576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cd5565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ebd576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f3857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f0d575b50505050509050600060018251611f4f91906156ba565b905060005b82518110156120eb578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f8657611f866154f7565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120db576000838381518110611fbd57611fbd6154f7565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110612003576120036154f7565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061207d5761207d6156cd565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120eb565b6120e481615682565b9050611f54565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000612191613338565b612199613406565b6121a161344f565b6009805481906121c7906901000000000000000000900467ffffffffffffffff166156fc565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c081018252600080825233602083015291810182905260608101829052919250608082019060405190808252806020026020018201604052801561223d578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926122d8926002850192909101906148bc565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061233986613664565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561240457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116123d9575b5050505050905091939590929450565b61241c613338565b612424613406565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612475576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124af576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124bd82840184614a2c565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612536576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff169186919061256d83856155a4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff166125c491906155a4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461262b91906152ce565b6040805192835260208301919091520160405180910390a2505050505050565b6000611285826000613838565b6126606136da565b60095461ffff808316660100000000000090920416036126ac576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff640100000000909104811690821611156126f8576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff660100000000000090910481168083529084166020830152909182019061272f90436152ce565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b6127bf6136da565b6005544310156127fb576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461280d9061ffff166001615723565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff9283161790819055620100009004161561287357600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff821610156129c857600060036000018260ff168154811061289e5761289e6154f7565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff86169081106128ed576128ed6154f7565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a1505050806129c190615526565b9050612876565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a2b57602002820191906000526020600020905b815481526020019060010190808311612a17575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612a9457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a69575b50505050509050925092509250909192565b6060612ab3848484614280565b949350505050565b612ac3613338565b612acc82613340565b612ad4613406565b612adc61344f565b612ae58261434d565b1561080b576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b24612fba565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612b93573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bb79190615276565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612c24576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cd5565b81811015611882576000612c3882846156ba565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612cb3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cd79190615644565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112858261434d565b612d416136da565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612d7b906152e1565b80601f0160208091040260200160405190810160405280929190818152602001828054612da7906152e1565b8015612df45780601f10612dc957610100808354040283529160200191612df4565b820191906000526020600020905b815481529060010190602001808311612dd757829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e47576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612e6c57612e59816020015161449c565b6020808201518051910120600755612f14565b612e77826000613838565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612eb39190614b4b565b600060405180830381600087803b158015612ecd57600080fd5b505af1925050508015612ede575060015b612f14576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612f2c9062010000900461ffff166001615723565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612f9d92869261573e565b60405180910390a15050565b612fb16136da565b6129c881614597565b6109746136da565b612fca613406565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156130ab57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613080575b505050918352505060039190910154602090910152805190915060005b82608001515181101561316c57600c6000846080015183815181106130ef576130ef6154f7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561316581615682565b90506130c8565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061319e6002830182614936565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff166131d1919061561f565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613270573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132949190615644565b6132ca576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b610974613938565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16806133b7576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610815576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095468010000000000000000900460ff1615610974576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61347a7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613838565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af11580156134e8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061350c9190615644565b610974576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cd5565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a9081106135a4576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cd5565b6010805460ff83169081106135bb576135bb6154f7565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611882576010805460ff831690811061360b5761360b6154f7565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cd5565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166129c8576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610974576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cd5565b613768614692565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6137e5613938565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137b33390565b6000816138775760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613871579050611285565b50613903565b60005b60035460ff82161015613901576003805460ff831690811061389e5761389e6154f7565b906000526020600020015484036138f1576004805460ff83169081106138c6576138c66154f7565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112859050565b6138fa81615526565b905061387a565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cd5565b60005460ff1615610974576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cd5565b60006bffffffffffffffffffffffff821115613a43576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cd5565b5090565b6040805180820190915260008082526020820152600f546040516000916c01000000000000000000000000900460e01b90613a8a90899089908990602401615766565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff166801000000000000000017905590506000805a611388811015613b4f57600080fd5b611388810390508660408204820311613b6757600080fd5b853b613b7257600080fd5b60008085516020870160008a8cf192505a600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff1690556040805180820190915293151584529003602083015250979650505050505050565b60408051808201909152600080825260208201526000613bec846139a5565b613bf69086615574565b9050600081613c0588866155a4565b613c0f91906155a4565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613c669185911661561f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613ca091906155a4565b336000908152600d602052604081208054909190613ccd9084906bffffffffffffffffffffffff166155a4565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613d14918591166155a4565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613d689185911661561f565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613dec9185916901000000000000000000900416615661565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613e29613938565b613e3285613664565b613e3c33866146fe565b613e468583613544565b6000613e528888613838565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c591613f1d91600401615791565b6080604051808303816000875af1158015613f3c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f609190615824565b92975090945092509050613f75338a8561479a565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c08101613feb83426152ce565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161426a96959493929190615862565b60405180910390a4505050509695505050505050565b60606000808080614293868801886158c6565b935093509350935060006142ac89600187878787613e1f565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614340578181602081106142eb576142eb6154f7565b1a60f81b878281518110614301576143016154f7565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061433981615682565b90506142d0565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156143c557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161439a575b5050505050905060005b8151811015614492576000600c60008484815181106143f0576143f06154f7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461448157506001949350505050565b5061448b81615682565b90506143cf565b5060009392505050565b6000806000838060200190518101906144b59190615937565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145609160109190860190614954565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d2093929190615a20565b3373ffffffffffffffffffffffffffffffffffffffff821603614616576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cd5565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610974576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cd5565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610815576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cd5565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906147d49084906bffffffffffffffffffffffff166155a4565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261484a928492900416615661565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b8280548282559060005260206000209081019282156148b0579160200282015b828111156148b0578251825591602001919060010190614895565b50613a439291506149fa565b8280548282559060005260206000209081019282156148b0579160200282015b828111156148b057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906148dc565b50805460008255906000526020600020908101906129c891906149fa565b828054828255906000526020600020906007016008900481019282156148b05791602002820160005b838211156149c157835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261497d565b80156149f15782816101000a81549063ffffffff02191690556004016020816003010492830192600103026149c1565b5050613a439291505b5b80821115613a4357600081556001016149fb565b803567ffffffffffffffff81168114614a2757600080fd5b919050565b600060208284031215614a3e57600080fd5b61189382614a0f565b803573ffffffffffffffffffffffffffffffffffffffff81168114614a2757600080fd5b60008060408385031215614a7e57600080fd5b614a8783614a0f565b9150614a9560208401614a47565b90509250929050565b63ffffffff811681146129c857600080fd5b60008060408385031215614ac357600080fd5b614acc83614a0f565b91506020830135614adc81614a9e565b809150509250929050565b6000815180845260005b81811015614b0d57602081850181015186830182015201614af1565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118936020830184614ae7565b60008060408385031215614b7157600080fd5b614b7a83614a0f565b946020939093013593505050565b60008083601f840112614b9a57600080fd5b50813567ffffffffffffffff811115614bb257600080fd5b602083019150836020828501011115614bca57600080fd5b9250929050565b600080600060408486031215614be657600080fd5b83359250602084013567ffffffffffffffff811115614c0457600080fd5b614c1086828701614b88565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614c9357614c93614c1d565b604052919050565b600067ffffffffffffffff821115614cb557614cb5614c1d565b5060051b60200190565b600082601f830112614cd057600080fd5b81356020614ce5614ce083614c9b565b614c4c565b82815260059290921b84018101918181019086841115614d0457600080fd5b8286015b84811015614d2657614d1981614a47565b8352918301918301614d08565b509695505050505050565b60008060408385031215614d4457600080fd5b823567ffffffffffffffff80821115614d5c57600080fd5b818501915085601f830112614d7057600080fd5b81356020614d80614ce083614c9b565b82815260059290921b84018101918181019089841115614d9f57600080fd5b948201945b83861015614dbd57853582529482019490820190614da4565b96505086013592505080821115614dd357600080fd5b50614de085828601614cbf565b9150509250929050565b600082601f830112614dfb57600080fd5b813567ffffffffffffffff811115614e1557614e15614c1d565b614e4660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614c4c565b818152846020838601011115614e5b57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129c857600080fd5b60008060008060008060c08789031215614eab57600080fd5b86359550602087013567ffffffffffffffff80821115614eca57600080fd5b614ed68a838b01614dea565b96506040890135915080821115614eec57600080fd5b50614ef989828a01614dea565b9450506060870135614f0a81614e78565b92506080870135614f1a81614e78565b9150614f2860a08801614a47565b90509295509295509295565b803561ffff81168114614a2757600080fd5b60008060008060008060a08789031215614f5f57600080fd5b614f6887614a0f565b9550602087013567ffffffffffffffff811115614f8457600080fd5b614f9089828a01614b88565b9096509450614fa3905060408801614f34565b92506060870135614fb381614a9e565b80925050608087013590509295509295509295565b60008060408385031215614fdb57600080fd5b614fe483614a47565b91506020830135614adc81614e78565b6000806020838503121561500757600080fd5b823567ffffffffffffffff8082111561501f57600080fd5b818501915085601f83011261503357600080fd5b81358181111561504257600080fd5b8660208260051b850101111561505757600080fd5b60209290920196919550909350505050565b6000806040838503121561507c57600080fd5b61508583614a47565b9150614a9560208401614a0f565b80151581146129c857600080fd5b600080604083850312156150b457600080fd5b823591506020830135614adc81615093565b600081518084526020808501945080840160005b8381101561510c57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016150da565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061125c908301846150c6565b6000806000806060858703121561518257600080fd5b61518b85614a47565b935060208501359250604085013567ffffffffffffffff8111156151ae57600080fd5b6151ba87828801614b88565b95989497509550505050565b6000602082840312156151d857600080fd5b5035919050565b6000602082840312156151f157600080fd5b61189382614f34565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561523b5784518352938301939183019160010161521f565b5050848103604086015261524f81876150c6565b98975050505050505050565b60006020828403121561526d57600080fd5b61189382614a47565b60006020828403121561528857600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112855761128561529f565b600181811c908216806152f557607f821691505b60208210810361532e577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561188257600081815260208120601f850160051c8101602086101561535b5750805b601f850160051c820191505b8181101561537a57828155600101615367565b505050505050565b815167ffffffffffffffff81111561539c5761539c614c1d565b6153b0816153aa84546152e1565b84615334565b602080601f83116001811461540357600084156153cd5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561537a565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561545057888601518255948401946001909101908401615431565b508582101561548c57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff810361553c5761553c61529f565b60010192915050565b6effffffffffffffffffffffffffffff81811683821601908082111561556d5761556d61529f565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461559c5761559c61529f565b505092915050565b6bffffffffffffffffffffffff81811683821601908082111561556d5761556d61529f565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff831660408201526080606082015260006156156080830184614ae7565b9695505050505050565b6bffffffffffffffffffffffff82811682821603908082111561556d5761556d61529f565b60006020828403121561565657600080fd5b815161189381615093565b67ffffffffffffffff81811683821601908082111561556d5761556d61529f565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036156b3576156b361529f565b5060010190565b818103818111156112855761128561529f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157195761571961529f565b6001019392505050565b61ffff81811683821601908082111561556d5761556d61529f565b83815282602082015260606040820152600061575d6060830184614ae7565b95945050505050565b83815260606020820152600061577f6060830185614ae7565b82810360408401526156158185614ae7565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e060608401526157dc610100840182614ae7565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b6000806000806080858703121561583a57600080fd5b84519350602085015161584c81614e78565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c060608301526158a360c0830186614ae7565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b600080600080608085870312156158dc57600080fd5b6158e585614a0f565b9350602085013567ffffffffffffffff81111561590157600080fd5b61590d87828801614dea565b93505061591c60408601614f34565b9150606085013561592c81614a9e565b939692955090935050565b60008060006060848603121561594c57600080fd5b835161595781614e78565b809350506020808501517fffffffff000000000000000000000000000000000000000000000000000000008116811461598f57600080fd5b604086015190935067ffffffffffffffff8111156159ac57600080fd5b8501601f810187136159bd57600080fd5b80516159cb614ce082614c9b565b81815260059190911b820183019083810190898311156159ea57600080fd5b928401925b82841015615a11578351615a0281614a9e565b825292840192908401906159ef565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615a9d57845163ffffffff1683529383019391830191600101615a7b565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200621f3803806200621f833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615b3c80620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102f45760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610771578063eb523d6c14610784578063f2fde38b1461079757600080fd5b8063c4614d6114610738578063d7ae1d301461074b578063e72f6e301461075e57600080fd5b8063b5643858116100c8578063b564385814610706578063b734c0f414610719578063badc3eb61461072157600080fd5b8063aab396bd146106d5578063b187bd26146106fb57600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c76961461068b578063a4c0ed36146106af578063a9c9a918146106c257600080fd5b80639883c10d146106685780639f87fad714610670578063a21a23e41461068357600080fd5b80638235974011610176578063823597401461062a5780638da5cb5b1461063d5780638fde53171461066057600080fd5b80637341c10c1461060f57806379ba50971461062257600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461053b5780636a6df79b146105d057806371ec28ac1461060857600080fd5b806366316d8d146104e157806366419970146104f4578063665871ec1461052857600080fd5b806354fd4d501161022f57806354fd4d501461048b57806355fedefa146104b75780635c975abb146104ca57600080fd5b80633fd67e0514610431578063461d27621461046a57600080fd5b8063181f5a77116102ac57806336566f061161028657806336566f0614610403578063385de9ae1461040b5780633e871e4d1461041e57600080fd5b8063181f5a77146103985780631ded3b36146103da5780632a905ccc146103ed57600080fd5b80630c5d49cb116102dd5780630c5d49cb1461032157806310fc49c11461034157806312b583491461035457600080fd5b806302bcc5b6146102f957806304c357cb1461030e575b600080fd5b61030c610307366004614a9e565b6107aa565b005b61030c61031c366004614add565b610837565b610329608481565b60405161ffff90911681526020015b60405180910390f35b61030c61034f366004614b22565b61093c565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610338565b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103389190614bbd565b61030c6103e8366004614bd0565b610946565b600f546bffffffffffffffffffffffff1661037b565b61030c610977565b61030c610419366004614c43565b61099c565b61030c61042c366004614da3565b610b84565b61044461043f366004614f04565b610e9e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610338565b61047d610478366004614fb8565b61122f565b604051908152602001610338565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610338565b61047d6104c5366004614a9e565b61128b565b60005460ff165b6040519015158152602001610338565b61030c6104ef36600461503a565b6112af565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610338565b61030c610536366004615066565b6114de565b6105a86105493660046150db565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610338565b6105e36105de366004615113565b6118ab565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610338565b6064610329565b61030c61061d366004614add565b6118be565b61030c611a73565b61030c610638366004614a9e565b611b95565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105e3565b61030c611cec565b60075461047d565b61030c61067e366004614add565b611d9b565b61050f6121ab565b61069e610699366004614a9e565b61234c565b604051610338959493929190615189565b61030c6106bd3660046151de565b612438565b6105e36106d0366004615238565b61266f565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761047d565b60005460ff166104d1565b61030c610714366004615251565b61267c565b61030c6127db565b6107296129ef565b6040516103389392919061526c565b6103cd610746366004614c43565b612aca565b61030c610759366004614add565b612adf565b61030c61076c3660046152cd565b612b40565b6104d161077f366004614a9e565b612d52565b61030c610792366004615238565b612d5d565b61030c6107a53660046152cd565b612fcd565b6107b2612fde565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680610829576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108338282612fe6565b5050565b61083f61335c565b61084882613364565b61085061342a565b610858613473565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108335767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b6108338282613568565b61094e612fde565b61095782613688565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61097f6136fe565b60005460ff161561099457610992613784565b565b610992613801565b6109a46136fe565b60006109b184600061385c565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109db5750600754610a4f565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a28573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a4c91906152e8565b90505b8383604051610a5f929190615301565b60405180910390208103610a9f576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610b0a906601000000000000900461ffff1643615340565b9052600086815260066020908152604090912082518155908201516001820190610b3490826153f4565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b7590879084908890889061550e565b60405180910390a15050505050565b610b8c6136fe565b8151815181141580610b9e5750600881115b15610bd5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610d0f576000848260ff1681518110610bfa57610bfa615569565b602002602001015190506000848360ff1681518110610c1b57610c1b615569565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c86575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cbd576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cfc576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610d0890615598565b9050610bd8565b50600954600090610d2e906601000000000000900461ffff1643615340565b604080516060810182528681526020808201879052918101839052865192935091600391610d609183918901906148e7565b506020828101518051610d79926001850192019061492e565b506040820151816002015590505060005b84518160ff161015610e97577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610dcc57610dcc615569565b602002602001015160026000888560ff1681518110610ded57610ded615569565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e3957610e39615569565b602002602001015185604051610e7f949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e9081615598565b9050610d8a565b5050505050565b600080610ea961395c565b610eb161342a565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314610ff3576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff1661101c576002925050611224565b8060e00151816080015163ffffffff1661103691906155b7565b6effffffffffffffffffffffffffffff165a1015611058576003925050611224565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff9091169061109b9063ffffffff166139c9565b6110a590886155e6565b82516110b2908890615616565b6110bc9190615616565b6bffffffffffffffffffffffff1611156110da576004925050611224565b8060a001516bffffffffffffffffffffffff16611100826080015163ffffffff166139c9565b61110a90886155e6565b8251611117908890615616565b6111219190615616565b6bffffffffffffffffffffffff16111561113f576005925050611224565b6000898152600e602052604080822082815560018101839055600201829055608083015190830151919450849161117b918c918c918c91613a6b565b805190915061118b57600161118e565b60005b935060006111b583606001518460a00151856040015186600001518c87602001518d613c3f565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a8360200151898987600001516111fe578e611200565b8f5b886040015160405161121695949392919061563b565b60405180910390a351925050505b965096945050505050565b600061123961342a565b6112808260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e919050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b6112b761335c565b6112bf61342a565b806bffffffffffffffffffffffff16600003611307576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611361576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061138e9084906bffffffffffffffffffffffff16615699565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113e59190615699565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611484573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a891906156be565b610833576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114e661335c565b6114ee61342a565b60005b818110156118a657600083838381811061150d5761150d615569565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e082015290935091905061163081613688565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163381146116a9576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156116ee576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611760573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061178491906156be565b156118905760a084015167ffffffffffffffff84166000908152600b6020526040812060010180549091906117c89084906bffffffffffffffffffffffff16615699565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff80881684529152919020805460019260099161184f91859169010000000000000000009004166156db565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b50505050508061189f906156fc565b90506114f1565b505050565b60006118b7838361385c565b9392505050565b6118c661335c565b6118cf82613364565b6118d761342a565b6118df613473565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611954576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff161561199b575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610930565b60015473ffffffffffffffffffffffffffffffffffffffff163314611af4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cf3565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b9d61335c565b611ba561342a565b611bad613473565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611c4d576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cf3565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611cf46136fe565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611d56576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b611da361335c565b611dac82613364565b611db461342a565b611dbc613473565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e8c576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cf3565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ee1576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f5c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f31575b50505050509050600060018251611f739190615734565b905060005b825181101561210f578473ffffffffffffffffffffffffffffffffffffffff16838281518110611faa57611faa615569565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120ff576000838381518110611fe157611fe1615569565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600201838154811061202757612027615569565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b909152604090206002018054806120a1576120a1615747565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061210f565b612108816156fc565b9050611f78565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60006121b561335c565b6121bd61342a565b6121c5613473565b6009805481906121eb906901000000000000000000900467ffffffffffffffff16615776565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612261578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926122fc9260028501929091019061492e565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061235d86613688565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561242857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116123fd575b5050505050905091939590929450565b61244061335c565b61244861342a565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612499576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124d3576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124e182840184614a9e565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661255a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906125918385615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff166125e89190615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461264f9190615340565b6040805192835260208301919091520160405180910390a2505050505050565b60006112a982600061385c565b6126846136fe565b60095461ffff808316660100000000000090920416036126d0576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff6401000000009091048116908216111561271c576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff66010000000000009091048116808352908416602083015290918201906127539043615340565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b6127e36136fe565b60055443101561281f576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6009546128319061ffff16600161579d565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff9283161790819055620100009004161561289757600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff821610156129ec57600060036000018260ff16815481106128c2576128c2615569565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff861690811061291157612911615569565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a1505050806129e590615598565b905061289a565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a4f57602002820191906000526020600020905b815481526020019060010190808311612a3b575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612ab857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a8d575b50505050509050925092509250909192565b6060612ad78484846142f2565b949350505050565b612ae761335c565b612af082613364565b612af861342a565b612b00613473565b612b09826143bf565b15610829576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b48612fde565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612bb7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bdb91906152e8565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612c48576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cf3565b818110156118a6576000612c5c8284615734565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612cd7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cfb91906156be565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112a9826143bf565b612d656136fe565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612d9f90615353565b80601f0160208091040260200160405190810160405280929190818152602001828054612dcb90615353565b8015612e185780601f10612ded57610100808354040283529160200191612e18565b820191906000526020600020905b815481529060010190602001808311612dfb57829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e6b576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612e9057612e7d816020015161450e565b6020808201518051910120600755612f38565b612e9b82600061385c565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612ed79190614bbd565b600060405180830381600087803b158015612ef157600080fd5b505af1925050508015612f02575060015b612f38576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612f509062010000900461ffff16600161579d565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612fc19286926157b8565b60405180910390a15050565b612fd56136fe565b6129ec81614609565b6109926136fe565b612fee61342a565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156130cf57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116130a4575b505050918352505060039190910154602090910152805190915060005b82608001515181101561319057600c60008460800151838151811061311357613113615569565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613189816156fc565b90506130ec565b5067ffffffffffffffff84166000908152600b6020526040812081815560018101829055906131c260028301826149a8565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff166131f59190615699565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613294573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132b891906156be565b6132ee576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b61099261395c565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16806133db576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610833576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095468010000000000000000900460ff1615610992576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61349e7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097600061385c565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561350c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061353091906156be565b610992576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cf3565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a9081106135c8576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cf3565b6010805460ff83169081106135df576135df615569565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff1611156118a6576010805460ff831690811061362f5761362f615569565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cf3565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166129ec576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610992576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cf3565b61378c614704565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b61380961395c565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137d73390565b60008161389b5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1680156138955790506112a9565b50613927565b60005b60035460ff82161015613925576003805460ff83169081106138c2576138c2615569565b90600052602060002001548403613915576004805460ff83169081106138ea576138ea615569565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112a99050565b61391e81615598565b905061389e565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cf3565b60005460ff1615610992576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cf3565b60006bffffffffffffffffffffffff821115613a67576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cf3565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613ab6908990899089906024016157e0565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff16680100000000000000001790558051608480825260c0820190925291935060009283928392909182018180368337019050509050853b613b9a57600080fd5b5a611388811015613baa57600080fd5b611388810390508760408204820311613bc257600080fd5b60008086516020880160008b8df193505a900391503d6084811115613be5575060845b808252806000602084013e50600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff169055604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613c5e846139c9565b613c6890866155e6565b9050600081613c778886615616565b613c819190615616565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613cd891859116615699565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613d129190615616565b336000908152600d602052604081208054909190613d3f9084906bffffffffffffffffffffffff16615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613d8691859116615616565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613dda91859116615699565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613e5e91859169010000000000000000009004166156db565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613e9b61395c565b613ea485613688565b613eae3386614770565b613eb88583613568565b6000613ec4888861385c565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c591613f8f91600401615815565b6080604051808303816000875af1158015613fae573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613fd291906158a8565b92975090945092509050613fe7338a8561480c565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c0810161405d8342615340565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516142dc969594939291906158e6565b60405180910390a4505050509695505050505050565b606060008080806143058688018861594a565b9350935093509350600061431e89600187878787613e91565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156143b25781816020811061435d5761435d615569565b1a60f81b87828151811061437357614373615569565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506143ab816156fc565b9050614342565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561443757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161440c575b5050505050905060005b8151811015614504576000600c600084848151811061446257614462615569565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146144f357506001949350505050565b506144fd816156fc565b9050614441565b5060009392505050565b60008060008380602001905181019061452791906159bb565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145d291601091908601906149c6565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d4493929190615aa4565b3373ffffffffffffffffffffffffffffffffffffffff821603614688576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cf3565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610992576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cf3565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610833576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cf3565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906148469084906bffffffffffffffffffffffff16615616565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926148bc9284929004166156db565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614922579160200282015b82811115614922578251825591602001919060010190614907565b50613a67929150614a6c565b828054828255906000526020600020908101928215614922579160200282015b8281111561492257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061494e565b50805460008255906000526020600020908101906129ec9190614a6c565b828054828255906000526020600020906007016008900481019282156149225791602002820160005b83821115614a3357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026149ef565b8015614a635782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a33565b5050613a679291505b5b80821115613a675760008155600101614a6d565b803567ffffffffffffffff81168114614a9957600080fd5b919050565b600060208284031215614ab057600080fd5b6118b782614a81565b803573ffffffffffffffffffffffffffffffffffffffff81168114614a9957600080fd5b60008060408385031215614af057600080fd5b614af983614a81565b9150614b0760208401614ab9565b90509250929050565b63ffffffff811681146129ec57600080fd5b60008060408385031215614b3557600080fd5b614b3e83614a81565b91506020830135614b4e81614b10565b809150509250929050565b6000815180845260005b81811015614b7f57602081850181015186830182015201614b63565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118b76020830184614b59565b60008060408385031215614be357600080fd5b614bec83614a81565b946020939093013593505050565b60008083601f840112614c0c57600080fd5b50813567ffffffffffffffff811115614c2457600080fd5b602083019150836020828501011115614c3c57600080fd5b9250929050565b600080600060408486031215614c5857600080fd5b83359250602084013567ffffffffffffffff811115614c7657600080fd5b614c8286828701614bfa565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d0557614d05614c8f565b604052919050565b600067ffffffffffffffff821115614d2757614d27614c8f565b5060051b60200190565b600082601f830112614d4257600080fd5b81356020614d57614d5283614d0d565b614cbe565b82815260059290921b84018101918181019086841115614d7657600080fd5b8286015b84811015614d9857614d8b81614ab9565b8352918301918301614d7a565b509695505050505050565b60008060408385031215614db657600080fd5b823567ffffffffffffffff80821115614dce57600080fd5b818501915085601f830112614de257600080fd5b81356020614df2614d5283614d0d565b82815260059290921b84018101918181019089841115614e1157600080fd5b948201945b83861015614e2f57853582529482019490820190614e16565b96505086013592505080821115614e4557600080fd5b50614e5285828601614d31565b9150509250929050565b600082601f830112614e6d57600080fd5b813567ffffffffffffffff811115614e8757614e87614c8f565b614eb860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cbe565b818152846020838601011115614ecd57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129ec57600080fd5b60008060008060008060c08789031215614f1d57600080fd5b86359550602087013567ffffffffffffffff80821115614f3c57600080fd5b614f488a838b01614e5c565b96506040890135915080821115614f5e57600080fd5b50614f6b89828a01614e5c565b9450506060870135614f7c81614eea565b92506080870135614f8c81614eea565b9150614f9a60a08801614ab9565b90509295509295509295565b803561ffff81168114614a9957600080fd5b60008060008060008060a08789031215614fd157600080fd5b614fda87614a81565b9550602087013567ffffffffffffffff811115614ff657600080fd5b61500289828a01614bfa565b9096509450615015905060408801614fa6565b9250606087013561502581614b10565b80925050608087013590509295509295509295565b6000806040838503121561504d57600080fd5b61505683614ab9565b91506020830135614b4e81614eea565b6000806020838503121561507957600080fd5b823567ffffffffffffffff8082111561509157600080fd5b818501915085601f8301126150a557600080fd5b8135818111156150b457600080fd5b8660208260051b85010111156150c957600080fd5b60209290920196919550909350505050565b600080604083850312156150ee57600080fd5b6150f783614ab9565b9150614b0760208401614a81565b80151581146129ec57600080fd5b6000806040838503121561512657600080fd5b823591506020830135614b4e81615105565b600081518084526020808501945080840160005b8381101561517e57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161514c565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061128090830184615138565b600080600080606085870312156151f457600080fd5b6151fd85614ab9565b935060208501359250604085013567ffffffffffffffff81111561522057600080fd5b61522c87828801614bfa565b95989497509550505050565b60006020828403121561524a57600080fd5b5035919050565b60006020828403121561526357600080fd5b6118b782614fa6565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156152ad57845183529383019391830191600101615291565b505084810360408601526152c18187615138565b98975050505050505050565b6000602082840312156152df57600080fd5b6118b782614ab9565b6000602082840312156152fa57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112a9576112a9615311565b600181811c9082168061536757607f821691505b6020821081036153a0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156118a657600081815260208120601f850160051c810160208610156153cd5750805b601f850160051c820191505b818110156153ec578281556001016153d9565b505050505050565b815167ffffffffffffffff81111561540e5761540e614c8f565b6154228161541c8454615353565b846153a6565b602080601f831160018114615475576000841561543f5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556153ec565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156154c2578886015182559484019460019091019084016154a3565b50858210156154fe57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036155ae576155ae615311565b60010192915050565b6effffffffffffffffffffffffffffff8181168382160190808211156155df576155df615311565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461560e5761560e615311565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156155df576155df615311565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061568760a0830185614b59565b82810360808401526152c18185614b59565b6bffffffffffffffffffffffff8281168282160390808211156155df576155df615311565b6000602082840312156156d057600080fd5b81516118b781615105565b67ffffffffffffffff8181168382160190808211156155df576155df615311565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361572d5761572d615311565b5060010190565b818103818111156112a9576112a9615311565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361579357615793615311565b6001019392505050565b61ffff8181168382160190808211156155df576155df615311565b8381528260208201526060604082015260006157d76060830184614b59565b95945050505050565b8381526060602082015260006157f96060830185614b59565b828103604084015261580b8185614b59565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e06060840152615860610100840182614b59565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b600080600080608085870312156158be57600080fd5b8451935060208501516158d081614eea565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261592760c0830186614b59565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b6000806000806080858703121561596057600080fd5b61596985614a81565b9350602085013567ffffffffffffffff81111561598557600080fd5b61599187828801614e5c565b9350506159a060408601614fa6565b915060608501356159b081614b10565b939692955090935050565b6000806000606084860312156159d057600080fd5b83516159db81614eea565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615a1357600080fd5b604086015190935067ffffffffffffffff811115615a3057600080fd5b8501601f81018713615a4157600080fd5b8051615a4f614d5282614d0d565b81815260059190911b82018301908381019089831115615a6e57600080fd5b928401925b82841015615a95578351615a8681614b10565b82529284019290840190615a73565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615b2157845163ffffffff1683529383019391830191600101615aff565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -171,6 +171,28 @@ func (_FunctionsRouter *FunctionsRouterTransactorRaw) Transact(opts *bind.Transa return _FunctionsRouter.Contract.contract.Transact(opts, method, params...) } +func (_FunctionsRouter *FunctionsRouterCaller) MAXCALLBACKRETURNBYTES(opts *bind.CallOpts) (uint16, error) { + var out []interface{} + err := _FunctionsRouter.contract.Call(opts, &out, "MAX_CALLBACK_RETURN_BYTES") + + if err != nil { + return *new(uint16), err + } + + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + + return out0, err + +} + +func (_FunctionsRouter *FunctionsRouterSession) MAXCALLBACKRETURNBYTES() (uint16, error) { + return _FunctionsRouter.Contract.MAXCALLBACKRETURNBYTES(&_FunctionsRouter.CallOpts) +} + +func (_FunctionsRouter *FunctionsRouterCallerSession) MAXCALLBACKRETURNBYTES() (uint16, error) { + return _FunctionsRouter.Contract.MAXCALLBACKRETURNBYTES(&_FunctionsRouter.CallOpts) +} + func (_FunctionsRouter *FunctionsRouterCaller) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getAdminFee") @@ -2072,6 +2094,7 @@ type FunctionsRouterRequestEnd struct { Transmitter common.Address ResultCode uint8 Response []byte + ReturnData []byte Raw types.Log } @@ -3649,7 +3672,7 @@ func (FunctionsRouterPaused) Topic() common.Hash { } func (FunctionsRouterRequestEnd) Topic() common.Hash { - return common.HexToHash("0x526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b0520") + return common.HexToHash("0x45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a") } func (FunctionsRouterRequestStart) Topic() common.Hash { @@ -3701,6 +3724,8 @@ func (_FunctionsRouter *FunctionsRouter) Address() common.Address { } type FunctionsRouterInterface interface { + MAXCALLBACKRETURNBYTES(opts *bind.CallOpts) (uint16, error) + GetAdminFee(opts *bind.CallOpts) (*big.Int, error) GetAllowListId(opts *bind.CallOpts) ([32]byte, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index c02ec3feba2..e0f9b1d986f 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -4,7 +4,7 @@ functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfSer functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 747aece848474708a007de3deb6d6e76c6407ac8850c84db6aa294acdf289d21 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin aefc4795c28e52f4cfb9f2374b7c31a19583fb113219c2378ef74dd351be1c8b -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 4cd0561e55e40ace00225c608ca5422282096ea8c8057b7b4f756d2c63cdb1e8 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 44fc70ab0fd16a37e16222e01de3f836d94f9a491b422db6e298581cd7843f45 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From e55151f3e95f8cc86457d64ddac15abc13e44e8d Mon Sep 17 00:00:00 2001 From: Ryan Nelson <130587585+ryannelsonsmartcontract@users.noreply.github.com> Date: Sun, 30 Jul 2023 14:21:22 -0400 Subject: [PATCH 036/270] Functions Gas Golf (#9960) * Removed unnecessary _nonReentrant call from oracleWithdraw * Changed access from internal to external for ownerWithdraw * More reentrancy guard removal * Set FunctionsClient and Routable routers to immutable * Keep subscription methods protected against reentrancy * (test): Add reentrancy unit tests * Remove reentrancy lock because of CEI pattern's protection (-8500 gas) * Amend line from merging develop * Regenerate geth wrappers * (test): Lower test's sub funding to prevent flakes from gasprice fluctuations * (test): Pin tx.gasprice for reentrancy test --------- Co-authored-by: Justin Kaseman --- .../functions/dev/1_0_0/FunctionsClient.sol | 12 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 14 +- .../dev/1_0_0/FunctionsSubscriptions.sol | 19 +- .../src/v0.8/functions/dev/1_0_0/Routable.sol | 2 +- .../testhelpers/FunctionsClientTestHelper.sol | 27 + .../v1/FunctionsSubscriptions.test.ts | 1293 ++++++++++------- .../functions_allow_list.go | 2 +- .../functions_client_example.go | 2 +- .../functions_coordinator.go | 2 +- .../functions_router/functions_router.go | 18 +- ...rapper-dependency-versions-do-not-edit.txt | 8 +- 11 files changed, 824 insertions(+), 575 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol index d05c1c68130..9d18ef6a9e5 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol @@ -10,7 +10,7 @@ import {IFunctionsClient} from "./interfaces/IFunctionsClient.sol"; * @notice Contract writers can inherit this contract in order to create Chainlink Functions requests */ abstract contract FunctionsClient is IFunctionsClient { - IFunctionsRouter internal s_router; + IFunctionsRouter internal immutable s_router; event RequestSent(bytes32 indexed id); event RequestFulfilled(bytes32 indexed id); @@ -18,7 +18,7 @@ abstract contract FunctionsClient is IFunctionsClient { error OnlyRouterCanFufill(); constructor(address router) { - setRouter(router); + s_router = IFunctionsRouter(router); } /** @@ -75,14 +75,6 @@ abstract contract FunctionsClient is IFunctionsClient { fulfillRequest(requestId, response, err); } - /** - * @notice Sets the stored router address - * @param router The address of Functions router contract - */ - function setRouter(address router) internal { - s_router = IFunctionsRouter(router); - } - /** * @notice Gets the stored address of the router contract * @return The address of the router contract diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index df6565c6030..ad5e4eadef2 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -133,7 +133,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes memory data, uint16 dataVersion, uint32 callbackGasLimit - ) private whenNotPaused returns (bytes32 requestId) { + ) private returns (bytes32 requestId) { + _whenNotPaused(); _isValidSubscription(subscriptionId); _isValidConsumer(msg.sender, subscriptionId); _isValidCallbackGasLimit(subscriptionId, callbackGasLimit); @@ -217,7 +218,6 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint32 callbackGasLimit, bytes32 donId ) external override returns (bytes32) { - _nonReentrant(); return _sendRequest(donId, false, subscriptionId, data, dataVersion, callbackGasLimit); } @@ -231,8 +231,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 juelsPerGas, uint96 costWithoutFulfillment, address transmitter - ) external override whenNotPaused returns (uint8 resultCode, uint96 callbackGasCostJuels) { - _nonReentrant(); + ) external override returns (uint8 resultCode, uint96 callbackGasCostJuels) { + _whenNotPaused(); Commitment memory commitment = s_requestCommitments[requestId]; @@ -315,9 +315,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions response, err ); - // Do not allow any non-view/non-pure coordinator functions to be called - // during the consumers callback code via reentrancyLock. - s_reentrancyLock = true; + // Call with explicitly the amount of callback gas requested // Important to not let them exhaust the gas budget and avoid payment. // NOTE: that callWithExactGas will revert if we do not have sufficient gas @@ -370,8 +368,6 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions returndatacopy(add(returnData, 0x20), 0, toCopy) } - s_reentrancyLock = false; - result = CallbackResult(success, gasUsed, returnData); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 11653bea8e3..454f7585b53 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -264,8 +264,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei * @param recipient where to send the funds * @param amount amount to withdraw */ - function ownerWithdraw(address recipient, uint96 amount) internal { - _nonReentrant(); + function ownerWithdraw(address recipient, uint96 amount) external { _onlyRouterOwner(); if (amount == 0) { amount = s_withdrawableTokens[address(this)]; @@ -290,7 +289,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function oracleWithdraw(address recipient, uint96 amount) external override { _whenNotPaused(); - _nonReentrant(); if (amount == 0) { revert InvalidCalldata(); } @@ -309,7 +307,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override { _whenNotPaused(); - _nonReentrant(); if (msg.sender != address(s_linkToken)) { revert OnlyCallableFromLink(); } @@ -336,7 +333,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function createSubscription() external override returns (uint64 subscriptionId) { _whenNotPaused(); - _nonReentrant(); _onlySenderThatAcceptedToS(); subscriptionId = ++s_currentSubscriptionId; s_subscriptions[subscriptionId] = Subscription({ @@ -357,7 +353,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function requestSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); - _nonReentrant(); _onlySenderThatAcceptedToS(); // Proposing to address(0) would never be claimable, so don't need to check. @@ -373,7 +368,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external override { _whenNotPaused(); - _nonReentrant(); _onlySenderThatAcceptedToS(); address previousOwner = s_subscriptions[subscriptionId].owner; address nextOwner = s_subscriptions[subscriptionId].requestedOwner; @@ -391,7 +385,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function removeConsumer(uint64 subscriptionId, address consumer) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); - _nonReentrant(); _onlySenderThatAcceptedToS(); Consumer memory consumerData = s_consumers[consumer][subscriptionId]; if (!consumerData.allowed) { @@ -423,7 +416,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function addConsumer(uint64 subscriptionId, address consumer) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); - _nonReentrant(); _onlySenderThatAcceptedToS(); // Already maxed, cannot add any more consumers. if (s_subscriptions[subscriptionId].consumers.length == MAX_CONSUMERS) { @@ -446,7 +438,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function cancelSubscription(uint64 subscriptionId, address to) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); - _nonReentrant(); _onlySenderThatAcceptedToS(); if (_pendingRequestExists(subscriptionId)) { revert PendingRequestExists(); @@ -455,7 +446,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } function _cancelSubscriptionHelper(uint64 subscriptionId, address to) private { - _nonReentrant(); Subscription memory sub = s_subscriptions[subscriptionId]; uint96 balance = sub.balance; // Note bounded by MAX_CONSUMERS; @@ -518,7 +508,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external override { _whenNotPaused(); - _nonReentrant(); for (uint256 i = 0; i < requestIdsToTimeout.length; ++i) { bytes32 requestId = requestIdsToTimeout[i]; Commitment memory request = s_requestCommitments[requestId]; @@ -562,12 +551,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } } - function _nonReentrant() internal view { - if (s_reentrancyLock) { - revert Reentrant(); - } - } - function _onlySenderThatAcceptedToS() internal virtual; function _onlyRouterOwner() internal virtual; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index 876bbcc4fd7..cb0eb348d49 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -10,7 +10,7 @@ import {IOwnable} from "../../../shared/interfaces/IOwnable.sol"; abstract contract Routable is ITypeAndVersion, IConfigurable { bytes32 internal s_config_hash; - IRouterBase internal s_router; + IRouterBase internal immutable s_router; error RouterMustBeSet(); error OnlyCallableByRouter(); diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index b8b5b5a88a9..296c1873c0e 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -3,6 +3,7 @@ pragma solidity ^0.8.6; import {FunctionsClient, Functions} from "../../../dev/1_0_0/FunctionsClient.sol"; import {ITermsOfServiceAllowList} from "../../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; +import {IFunctionsSubscriptions} from "../../../dev/1_0_0/interfaces/IFunctionsSubscriptions.sol"; contract FunctionsClientTestHelper is FunctionsClient { using Functions for Functions.Request; @@ -12,6 +13,11 @@ contract FunctionsClientTestHelper is FunctionsClient { bool private s_revertFulfillRequest; bool private s_doInvalidOperation; + bool private s_doInvalidReentrantOperation; + bool private s_doValidReentrantOperation; + + uint64 private s_subscriptionId; + bytes32 private s_donId; constructor(address router) FunctionsClient(router) {} @@ -52,6 +58,10 @@ contract FunctionsClientTestHelper is FunctionsClient { allowList.acceptTermsOfService(acceptor, recipient, proof); } + function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external { + IFunctionsSubscriptions(address(s_router)).acceptSubscriptionOwnerTransfer(subscriptionId); + } + function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal override { if (s_revertFulfillRequest) { revert("asked to revert"); @@ -61,6 +71,12 @@ contract FunctionsClientTestHelper is FunctionsClient { uint256 y = 0; x = x / y; } + if (s_doValidReentrantOperation) { + sendSimpleRequestWithJavaScript("somedata", s_subscriptionId, s_donId, 20_000); + } + if (s_doInvalidReentrantOperation) { + IFunctionsSubscriptions(address(s_router)).cancelSubscription(s_subscriptionId, msg.sender); + } emit FulfillRequestInvoked(requestId, response, err); } @@ -71,4 +87,15 @@ contract FunctionsClientTestHelper is FunctionsClient { function setDoInvalidOperation(bool on) external { s_doInvalidOperation = on; } + + function setDoInvalidReentrantOperation(bool on, uint64 subscriptionId) external { + s_doInvalidReentrantOperation = on; + s_subscriptionId = subscriptionId; + } + + function setDoValidReentrantOperation(bool on, uint64 subscriptionId, bytes32 donId) external { + s_doValidReentrantOperation = on; + s_subscriptionId = subscriptionId; + s_donId = donId; + } } diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index b4180b62371..79af43d20bb 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -8,7 +8,11 @@ import { FunctionsRoles, createSubscription, acceptTermsOfService, + ids, + getEventArg, + accessControlMockPrivateKey, } from './utils' +import { numToBytes32, stringToBytes } from '../../../test-helpers/helpers' const setup = getSetupFactory() let contracts: FunctionsContracts @@ -21,553 +25,786 @@ beforeEach(async () => { }) describe('Functions Router - Subscriptions', () => { - describe('Subscription management', () => { - describe('#createSubscription', async function () { - it('can create a subscription', async function () { - await acceptTermsOfService( - contracts.accessControl, - roles.subOwner, - roles.subOwnerAddress, - ) - await expect( - contracts.router.connect(roles.subOwner).createSubscription(), - ) - .to.emit(contracts.router, 'SubscriptionCreated') - .withArgs(1, roles.subOwnerAddress) - const s = await contracts.router.getSubscription(1) - expect(s.balance.toString()).to.equal('0') - expect(s.owner).to.equal(roles.subOwnerAddress) - }) - it('subscription id increments', async function () { - await acceptTermsOfService( - contracts.accessControl, - roles.subOwner, - roles.subOwnerAddress, - ) - await expect( - contracts.router.connect(roles.subOwner).createSubscription(), - ) - .to.emit(contracts.router, 'SubscriptionCreated') - .withArgs(1, roles.subOwnerAddress) - await expect( - contracts.router.connect(roles.subOwner).createSubscription(), - ) - .to.emit(contracts.router, 'SubscriptionCreated') - .withArgs(2, roles.subOwnerAddress) - }) - it('cannot create more than the max', async function () { - const subId = createSubscription( - roles.subOwner, - [], - contracts.router, - contracts.accessControl, - ) - for (let i = 0; i < 100; i++) { - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, randomAddressString()) - } - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(subId, randomAddressString()), - ).to.be.revertedWith(`TooManyConsumers()`) - }) - }) + // describe('Subscription management', () => { + // describe('#createSubscription', async function () { + // it('can create a subscription', async function () { + // await acceptTermsOfService( + // contracts.accessControl, + // roles.subOwner, + // roles.subOwnerAddress, + // ) + // await expect( + // contracts.router.connect(roles.subOwner).createSubscription(), + // ) + // .to.emit(contracts.router, 'SubscriptionCreated') + // .withArgs(1, roles.subOwnerAddress) + // const s = await contracts.router.getSubscription(1) + // expect(s.balance.toString()).to.equal('0') + // expect(s.owner).to.equal(roles.subOwnerAddress) + // }) + // it('subscription id increments', async function () { + // await acceptTermsOfService( + // contracts.accessControl, + // roles.subOwner, + // roles.subOwnerAddress, + // ) + // await expect( + // contracts.router.connect(roles.subOwner).createSubscription(), + // ) + // .to.emit(contracts.router, 'SubscriptionCreated') + // .withArgs(1, roles.subOwnerAddress) + // await expect( + // contracts.router.connect(roles.subOwner).createSubscription(), + // ) + // .to.emit(contracts.router, 'SubscriptionCreated') + // .withArgs(2, roles.subOwnerAddress) + // }) + // it('cannot create more than the max', async function () { + // const subId = createSubscription( + // roles.subOwner, + // [], + // contracts.router, + // contracts.accessControl, + // ) + // for (let i = 0; i < 100; i++) { + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, randomAddressString()) + // } + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, randomAddressString()), + // ).to.be.revertedWith(`TooManyConsumers()`) + // }) + // }) - describe('#requestSubscriptionOwnerTransfer', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - }) - it('rejects non-owner', async function () { - await expect( - contracts.router - .connect(roles.stranger) - .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ).to.be.revertedWith(`MustBeSubOwner()`) - }) - it('owner can request transfer', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ) - .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') - .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - // Same request is a noop - await expect( - contracts.router - .connect(roles.subOwner) - .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ).to.not.emit(contracts.router, 'SubscriptionOwnerTransferRequested') - }) - }) + // describe('#requestSubscriptionOwnerTransfer', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // }) + // it('rejects non-owner', async function () { + // await expect( + // contracts.router + // .connect(roles.stranger) + // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), + // ).to.be.revertedWith(`MustBeSubOwner()`) + // }) + // it('owner can request transfer', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), + // ) + // .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + // .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) + // // Same request is a noop + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), + // ).to.not.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + // }) + // }) - describe('#acceptSubscriptionOwnerTransfer', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - }) - it('subscription must exist', async function () { - // 0x0 is requested owner - await expect( - contracts.router - .connect(roles.subOwner) - .acceptSubscriptionOwnerTransfer(1203123123), - ).to.be.revertedWith(`MustBeRequestedOwner`) - }) - it('must be requested owner to accept', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ) - await expect( - contracts.router - .connect(roles.subOwner) - .acceptSubscriptionOwnerTransfer(subId), - ).to.be.revertedWith(`MustBeRequestedOwner("${roles.strangerAddress}")`) - }) - it('requested owner can accept', async function () { - await acceptTermsOfService( - contracts.accessControl, - roles.stranger, - roles.strangerAddress, - ) - await expect( - contracts.router - .connect(roles.subOwner) - .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ) - .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') - .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - await expect( - contracts.router - .connect(roles.stranger) - .acceptSubscriptionOwnerTransfer(subId), - ) - .to.emit(contracts.router, 'SubscriptionOwnerTransferred') - .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - }) - }) + // describe('#acceptSubscriptionOwnerTransfer', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // }) + // it('subscription must exist', async function () { + // // 0x0 is requested owner + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .acceptSubscriptionOwnerTransfer(1203123123), + // ).to.be.revertedWith(`MustBeRequestedOwner`) + // }) + // it('must be requested owner to accept', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), + // ) + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .acceptSubscriptionOwnerTransfer(subId), + // ).to.be.revertedWith(`MustBeRequestedOwner("${roles.strangerAddress}")`) + // }) + // it('requested owner can accept', async function () { + // await acceptTermsOfService( + // contracts.accessControl, + // roles.stranger, + // roles.strangerAddress, + // ) + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), + // ) + // .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + // .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) + // await expect( + // contracts.router + // .connect(roles.stranger) + // .acceptSubscriptionOwnerTransfer(subId), + // ) + // .to.emit(contracts.router, 'SubscriptionOwnerTransferred') + // .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) + // }) + // }) - describe('#addConsumer', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - }) - it('subscription must exist', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(1203123123, roles.strangerAddress), - ).to.be.revertedWith(`InvalidSubscription`) - }) - it('must be owner', async function () { - await expect( - contracts.router - .connect(roles.stranger) - .addConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`MustBeSubOwner()`) - }) - it('add is idempotent', async function () { - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress) - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress), - ).to.not.be.reverted - }) - it('cannot add more than maximum', async function () { - // There is one consumer, add another 99 to hit the max - for (let i = 0; i < 99; i++) { - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, randomAddressString()) - } - // Adding one more should fail - // await contracts.router.connect(roles.subOwner).addConsumer(subId, roles.strangerAddress); - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`TooManyConsumers()`) - // Same is true if we first create with the maximum - const consumers: string[] = [] - for (let i = 0; i < 100; i++) { - consumers.push(randomAddressString()) - } - subId = await createSubscription( - roles.subOwner, - consumers, - contracts.router, - contracts.accessControl, - ) - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`TooManyConsumers()`) - }) - it('owner can update', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress), - ) - .to.emit(contracts.router, 'SubscriptionConsumerAdded') - .withArgs(subId, roles.strangerAddress) - }) - }) + // describe('#addConsumer', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // }) + // it('subscription must exist', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(1203123123, roles.strangerAddress), + // ).to.be.revertedWith(`InvalidSubscription`) + // }) + // it('must be owner', async function () { + // await expect( + // contracts.router + // .connect(roles.stranger) + // .addConsumer(subId, roles.strangerAddress), + // ).to.be.revertedWith(`MustBeSubOwner()`) + // }) + // it('add is idempotent', async function () { + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress) + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress), + // ).to.not.be.reverted + // }) + // it('cannot add more than maximum', async function () { + // // There is one consumer, add another 99 to hit the max + // for (let i = 0; i < 99; i++) { + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, randomAddressString()) + // } + // // Adding one more should fail + // // await contracts.router.connect(roles.subOwner).addConsumer(subId, roles.strangerAddress); + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress), + // ).to.be.revertedWith(`TooManyConsumers()`) + // // Same is true if we first create with the maximum + // const consumers: string[] = [] + // for (let i = 0; i < 100; i++) { + // consumers.push(randomAddressString()) + // } + // subId = await createSubscription( + // roles.subOwner, + // consumers, + // contracts.router, + // contracts.accessControl, + // ) + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress), + // ).to.be.revertedWith(`TooManyConsumers()`) + // }) + // it('owner can update', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress), + // ) + // .to.emit(contracts.router, 'SubscriptionConsumerAdded') + // .withArgs(subId, roles.strangerAddress) + // }) + // }) - describe('#removeConsumer', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - }) - it('subscription must exist', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .removeConsumer(1203123123, roles.strangerAddress), - ).to.be.revertedWith(`InvalidSubscription`) - }) - it('must be owner', async function () { - await expect( - contracts.router - .connect(roles.stranger) - .removeConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`MustBeSubOwner()`) - }) - it('owner can update', async function () { - const subBefore = await contracts.router.getSubscription(subId) - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress) - await expect( - contracts.router - .connect(roles.subOwner) - .removeConsumer(subId, roles.strangerAddress), - ) - .to.emit(contracts.router, 'SubscriptionConsumerRemoved') - .withArgs(subId, roles.strangerAddress) - const subAfter = await contracts.router.getSubscription(subId) - // Subscription should NOT contain the removed consumer - expect(subBefore.consumers).to.deep.equal(subAfter.consumers) - }) - it('can remove all consumers', async function () { - // Testing the handling of zero. - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress) - await contracts.router - .connect(roles.subOwner) - .removeConsumer(subId, roles.strangerAddress) - await contracts.router - .connect(roles.subOwner) - .removeConsumer(subId, roles.consumerAddress) - // Should be empty - const subAfter = await contracts.router.getSubscription(subId) - expect(subAfter.consumers).to.deep.equal([]) - }) - }) + // describe('#removeConsumer', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // }) + // it('subscription must exist', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .removeConsumer(1203123123, roles.strangerAddress), + // ).to.be.revertedWith(`InvalidSubscription`) + // }) + // it('must be owner', async function () { + // await expect( + // contracts.router + // .connect(roles.stranger) + // .removeConsumer(subId, roles.strangerAddress), + // ).to.be.revertedWith(`MustBeSubOwner()`) + // }) + // it('owner can update', async function () { + // const subBefore = await contracts.router.getSubscription(subId) + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress) + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .removeConsumer(subId, roles.strangerAddress), + // ) + // .to.emit(contracts.router, 'SubscriptionConsumerRemoved') + // .withArgs(subId, roles.strangerAddress) + // const subAfter = await contracts.router.getSubscription(subId) + // // Subscription should NOT contain the removed consumer + // expect(subBefore.consumers).to.deep.equal(subAfter.consumers) + // }) + // it('can remove all consumers', async function () { + // // Testing the handling of zero. + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress) + // await contracts.router + // .connect(roles.subOwner) + // .removeConsumer(subId, roles.strangerAddress) + // await contracts.router + // .connect(roles.subOwner) + // .removeConsumer(subId, roles.consumerAddress) + // // Should be empty + // const subAfter = await contracts.router.getSubscription(subId) + // expect(subAfter.consumers).to.deep.equal([]) + // }) + // }) - describe('#pendingRequestExists', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) + // describe('#pendingRequestExists', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) - await contracts.linkToken - .connect(roles.subOwner) - .transferAndCall( - contracts.router.address, - BigNumber.from('130790416713017745'), - ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - ) - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, contracts.client.address) - }) - it('returns false when there is no latest pending request', async function () { - expect( - await contracts.router - .connect(roles.subOwner) - .pendingRequestExists(subId), - ).to.be.false - }) - it('returns true when the latest request is pending', async function () { - await contracts.client - .connect(roles.consumer) - .sendSimpleRequestWithJavaScript( - `return 'hello world'`, - subId, - donLabel, - 20_000, - ) - expect( - await contracts.router - .connect(roles.subOwner) - .pendingRequestExists(subId), - ).to.be.true - }) - }) + // await contracts.linkToken + // .connect(roles.subOwner) + // .transferAndCall( + // contracts.router.address, + // BigNumber.from('130790416713017745'), + // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + // ) + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, contracts.client.address) + // }) + // it('returns false when there is no latest pending request', async function () { + // expect( + // await contracts.router + // .connect(roles.subOwner) + // .pendingRequestExists(subId), + // ).to.be.false + // }) + // it('returns true when the latest request is pending', async function () { + // await contracts.client + // .connect(roles.consumer) + // .sendSimpleRequestWithJavaScript( + // `return 'hello world'`, + // subId, + // donLabel, + // 20_000, + // ) + // expect( + // await contracts.router + // .connect(roles.subOwner) + // .pendingRequestExists(subId), + // ).to.be.true + // }) + // }) - describe('#cancelSubscription', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - }) - it('subscription must exist', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .cancelSubscription(1203123123, roles.subOwnerAddress), - ).to.be.revertedWith(`InvalidSubscription`) - }) - it('must be owner', async function () { - await expect( - contracts.router - .connect(roles.stranger) - .cancelSubscription(subId, roles.subOwnerAddress), - ).to.be.revertedWith(`MustBeSubOwner()`) - }) - it('can cancel', async function () { - await contracts.linkToken - .connect(roles.subOwner) - .transferAndCall( - contracts.router.address, - BigNumber.from('1000'), - ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - ) - await expect( - contracts.router - .connect(roles.subOwner) - .cancelSubscription(subId, roles.strangerAddress), - ) - .to.emit(contracts.router, 'SubscriptionCanceled') - .withArgs(subId, roles.strangerAddress, BigNumber.from('1000')) - const strangerBalance = await contracts.linkToken.balanceOf( - roles.strangerAddress, - ) - expect(strangerBalance.toString()).to.equal('1000000000000001000') - await expect( - contracts.router.connect(roles.subOwner).getSubscription(subId), - ).to.be.revertedWith('InvalidSubscription') - }) - it('can add same consumer after canceling', async function () { - await contracts.linkToken - .connect(roles.subOwner) - .transferAndCall( - contracts.router.address, - BigNumber.from('1000'), - ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - ) - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress) - await contracts.router - .connect(roles.subOwner) - .cancelSubscription(subId, roles.strangerAddress) - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - // The cancel should have removed this consumer, so we can add it again. - await expect( - contracts.router - .connect(roles.subOwner) - .addConsumer(subId, roles.strangerAddress), - ).to.not.be.reverted - }) - it('cannot cancel with pending request', async function () { - await contracts.linkToken - .connect(roles.subOwner) - .transferAndCall( - contracts.router.address, - BigNumber.from('130790416713017745'), - ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - ) - await contracts.router - .connect(roles.subOwner) - .addConsumer(subId, contracts.client.address) - await contracts.client - .connect(roles.consumer) - .sendSimpleRequestWithJavaScript( - `return 'hello world'`, - subId, - donLabel, - 20_000, - ) - // Should revert with outstanding requests - await expect( - contracts.router - .connect(roles.subOwner) - .cancelSubscription(subId, roles.strangerAddress), - ).to.be.revertedWith('PendingRequestExists()') - // However the owner is able to cancel - // funds go to the sub owner. - await expect( - contracts.router - .connect(roles.defaultAccount) - .ownerCancelSubscription(subId), - ) - .to.emit(contracts.router, 'SubscriptionCanceled') - .withArgs( - subId, - roles.subOwnerAddress, - BigNumber.from('130790416713017745'), - ) - }) + // describe('#cancelSubscription', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // }) + // it('subscription must exist', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .cancelSubscription(1203123123, roles.subOwnerAddress), + // ).to.be.revertedWith(`InvalidSubscription`) + // }) + // it('must be owner', async function () { + // await expect( + // contracts.router + // .connect(roles.stranger) + // .cancelSubscription(subId, roles.subOwnerAddress), + // ).to.be.revertedWith(`MustBeSubOwner()`) + // }) + // it('can cancel', async function () { + // await contracts.linkToken + // .connect(roles.subOwner) + // .transferAndCall( + // contracts.router.address, + // BigNumber.from('1000'), + // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + // ) + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .cancelSubscription(subId, roles.strangerAddress), + // ) + // .to.emit(contracts.router, 'SubscriptionCanceled') + // .withArgs(subId, roles.strangerAddress, BigNumber.from('1000')) + // const strangerBalance = await contracts.linkToken.balanceOf( + // roles.strangerAddress, + // ) + // expect(strangerBalance.toString()).to.equal('1000000000000001000') + // await expect( + // contracts.router.connect(roles.subOwner).getSubscription(subId), + // ).to.be.revertedWith('InvalidSubscription') + // }) + // it('can add same consumer after canceling', async function () { + // await contracts.linkToken + // .connect(roles.subOwner) + // .transferAndCall( + // contracts.router.address, + // BigNumber.from('1000'), + // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + // ) + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress) + // await contracts.router + // .connect(roles.subOwner) + // .cancelSubscription(subId, roles.strangerAddress) + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // // The cancel should have removed this consumer, so we can add it again. + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, roles.strangerAddress), + // ).to.not.be.reverted + // }) + // it('cannot cancel with pending request', async function () { + // await contracts.linkToken + // .connect(roles.subOwner) + // .transferAndCall( + // contracts.router.address, + // BigNumber.from('130790416713017745'), + // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + // ) + // await contracts.router + // .connect(roles.subOwner) + // .addConsumer(subId, contracts.client.address) + // await contracts.client + // .connect(roles.consumer) + // .sendSimpleRequestWithJavaScript( + // `return 'hello world'`, + // subId, + // donLabel, + // 20_000, + // ) + // // Should revert with outstanding requests + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .cancelSubscription(subId, roles.strangerAddress), + // ).to.be.revertedWith('PendingRequestExists()') + // // However the owner is able to cancel + // // funds go to the sub owner. + // await expect( + // contracts.router + // .connect(roles.defaultAccount) + // .ownerCancelSubscription(subId), + // ) + // .to.emit(contracts.router, 'SubscriptionCanceled') + // .withArgs( + // subId, + // roles.subOwnerAddress, + // BigNumber.from('130790416713017745'), + // ) + // }) + // }) + + // describe('#recoverFunds', async function () { + // let subId: number + // beforeEach(async () => { + // subId = await createSubscription( + // roles.subOwner, + // [roles.consumerAddress], + // contracts.router, + // contracts.accessControl, + // ) + // }) + + // it('function that should change internal balance do', async function () { + // type bf = [() => Promise, BigNumber] + // const balanceChangingFns: Array = [ + // [ + // async function () { + // const s = ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]) + // await contracts.linkToken + // .connect(roles.subOwner) + // .transferAndCall( + // contracts.router.address, + // BigNumber.from('1000'), + // s, + // ) + // }, + // BigNumber.from('1000'), + // ], + // [ + // async function () { + // await contracts.router + // .connect(roles.subOwner) + // .cancelSubscription(subId, roles.strangerAddress) + // }, + // BigNumber.from('-1000'), + // ], + // ] + // for (const [fn, expectedBalanceChange] of balanceChangingFns) { + // const startingBalance = await contracts.router.getTotalBalance() + // await fn() + // const endingBalance = await contracts.router.getTotalBalance() + // expect(endingBalance.sub(startingBalance.toString())).to.equal( + // expectedBalanceChange.toString(), + // ) + // } + // }) + // it('only owner can recover', async function () { + // await expect( + // contracts.router + // .connect(roles.subOwner) + // .recoverFunds(roles.strangerAddress), + // ).to.be.revertedWith('Only callable by owner') + // }) + + // it('owner can recover link transferred', async function () { + // // Set the internal balance + // expect( + // await contracts.linkToken.balanceOf(roles.strangerAddress), + // ).to.equal(BigNumber.from('1000000000000000000')) + // const subscription = ethers.utils.defaultAbiCoder.encode( + // ['uint64'], + // [subId], + // ) + // await contracts.linkToken + // .connect(roles.subOwner) + // .transferAndCall( + // contracts.router.address, + // BigNumber.from('1000'), + // subscription, + // ) + // // Circumvent internal balance + // await contracts.linkToken + // .connect(roles.subOwner) + // .transfer(contracts.router.address, BigNumber.from('1000')) + // // Should recover this 1000 + // await expect( + // contracts.router + // .connect(roles.defaultAccount) + // .recoverFunds(roles.strangerAddress), + // ) + // .to.emit(contracts.router, 'FundsRecovered') + // .withArgs(roles.strangerAddress, BigNumber.from('1000')) + // expect( + // await contracts.linkToken.balanceOf(roles.strangerAddress), + // ).to.equal(BigNumber.from('1000000000000001000')) + // }) + // }) + // }) + + // describe('#oracleWithdraw', async function () { + // it('cannot withdraw with no balance', async function () { + // await expect( + // contracts.router + // .connect(roles.oracleNode) + // .oracleWithdraw(randomAddressString(), BigNumber.from('100')), + // ).to.be.revertedWith(`InsufficientBalance`) + // }) + // }) + + // describe('#flagsSet', async function () { + // it('get flags that were previously set', async function () { + // const flags = ethers.utils.formatBytes32String('arbitrary_byte_values') + // await acceptTermsOfService( + // contracts.accessControl, + // roles.subOwner, + // roles.subOwnerAddress, + // ) + // await expect( + // contracts.router.connect(roles.subOwner).createSubscription(), + // ) + // .to.emit(contracts.router, 'SubscriptionCreated') + // .withArgs(1, roles.subOwnerAddress) + // await contracts.router.setFlags(1, flags) + // expect(await contracts.router.getFlags(1)).to.equal(flags) + // }) + // }) + + describe('#reentrancy', async function () { + // Use a fixed gas price for these tests + const gasPrice = 3000000000 // 3 gwei + + it('allows callbacks to start another request if they have sufficient funds', async function () { + const subscriptionId = await createSubscription( + roles.subOwner, + [contracts.client.address], + contracts.router, + contracts.accessControl, + contracts.linkToken, + ) + + // Set test helper flag + await contracts.client.setDoValidReentrantOperation( + true, + subscriptionId, + ids.donId, + ) + + // Set flag so they have enough callback gas + const flags = new Uint8Array(32) + flags[0] = 1 + await contracts.router + .connect(roles.defaultAccount) + .setFlags(subscriptionId, flags) + + // Send request + const tx = await contracts.client.sendSimpleRequestWithJavaScript( + 'function run(){return response}', + subscriptionId, + ids.donId, + 400_000, + { gasPrice }, + ) + const { events } = await tx.wait() + const requestId = getEventArg(events, 'RequestSent', 0) + await expect(tx) + .to.emit(contracts.client, 'RequestSent') + .withArgs(requestId) + + const response = stringToBytes('response') + const error = stringToBytes('') + const abi = ethers.utils.defaultAbiCoder + + const report = abi.encode( + ['bytes32[]', 'bytes[]', 'bytes[]'], + [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ) + + await expect(contracts.coordinator.callReport(report, { gasPrice })) + .to.emit(contracts.coordinator, 'OracleResponse') + .withArgs(requestId, await roles.defaultAccount.getAddress()) + .to.emit(contracts.coordinator, 'BillingEnd') + .to.emit(contracts.client, 'FulfillRequestInvoked') + .withArgs(requestId, response, error) + .to.emit(contracts.client, 'SendRequestInvoked') }) - describe('#recoverFunds', async function () { - let subId: number - beforeEach(async () => { - subId = await createSubscription( - roles.subOwner, - [roles.consumerAddress], - contracts.router, - contracts.accessControl, - ) - }) - - it('function that should change internal balance do', async function () { - type bf = [() => Promise, BigNumber] - const balanceChangingFns: Array = [ - [ - async function () { - const s = ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]) - await contracts.linkToken - .connect(roles.subOwner) - .transferAndCall( - contracts.router.address, - BigNumber.from('1000'), - s, - ) - }, - BigNumber.from('1000'), - ], - [ - async function () { - await contracts.router - .connect(roles.subOwner) - .cancelSubscription(subId, roles.strangerAddress) - }, - BigNumber.from('-1000'), - ], - ] - for (const [fn, expectedBalanceChange] of balanceChangingFns) { - const startingBalance = await contracts.router.getTotalBalance() - await fn() - const endingBalance = await contracts.router.getTotalBalance() - expect(endingBalance.sub(startingBalance.toString())).to.equal( - expectedBalanceChange.toString(), - ) - } - }) - it('only owner can recover', async function () { - await expect( - contracts.router - .connect(roles.subOwner) - .recoverFunds(roles.strangerAddress), - ).to.be.revertedWith('Only callable by owner') - }) - - it('owner can recover link transferred', async function () { - // Set the internal balance - expect( - await contracts.linkToken.balanceOf(roles.strangerAddress), - ).to.equal(BigNumber.from('1000000000000000000')) - const subscription = ethers.utils.defaultAbiCoder.encode( - ['uint64'], - [subId], - ) - await contracts.linkToken - .connect(roles.subOwner) - .transferAndCall( - contracts.router.address, - BigNumber.from('1000'), - subscription, - ) - // Circumvent internal balance - await contracts.linkToken - .connect(roles.subOwner) - .transfer(contracts.router.address, BigNumber.from('1000')) - // Should recover this 1000 - await expect( - contracts.router - .connect(roles.defaultAccount) - .recoverFunds(roles.strangerAddress), + it('prevents callbacks from starting another request if have insufficient funds', async function () { + await acceptTermsOfService( + contracts.accessControl, + roles.subOwner, + roles.subOwnerAddress, + ) + const createSubTx = await contracts.router + .connect(roles.subOwner) + .createSubscription() + const createSubReceipt = await createSubTx.wait() + const subscriptionId = + createSubReceipt.events[0].args['subscriptionId'].toNumber() + await contracts.router + .connect(roles.subOwner) + .addConsumer(subscriptionId, contracts.client.address) + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('300000000000000000'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subscriptionId]), ) - .to.emit(contracts.router, 'FundsRecovered') - .withArgs(roles.strangerAddress, BigNumber.from('1000')) - expect( - await contracts.linkToken.balanceOf(roles.strangerAddress), - ).to.equal(BigNumber.from('1000000000000001000')) - }) - }) - }) - describe('#oracleWithdraw', async function () { - it('cannot withdraw with no balance', async function () { - await expect( - contracts.router - .connect(roles.oracleNode) - .oracleWithdraw(randomAddressString(), BigNumber.from('100')), - ).to.be.revertedWith(`InsufficientBalance`) + // Set test helper flag + await contracts.client.setDoValidReentrantOperation( + true, + subscriptionId, + ids.donId, + ) + + // Set flag so they have enough callback gas + const flags = new Uint8Array(32) + flags[0] = 1 + await contracts.router + .connect(roles.defaultAccount) + .setFlags(subscriptionId, flags) + + // Send request + const tx = await contracts.client.sendSimpleRequestWithJavaScript( + 'function run(){return response}', + subscriptionId, + ids.donId, + 400_000, + { gasPrice }, + ) + const { events } = await tx.wait() + const requestId = getEventArg(events, 'RequestSent', 0) + await expect(tx) + .to.emit(contracts.client, 'RequestSent') + .withArgs(requestId) + + const response = stringToBytes('response') + const error = stringToBytes('') + const abi = ethers.utils.defaultAbiCoder + + const report = abi.encode( + ['bytes32[]', 'bytes[]', 'bytes[]'], + [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ) + + await expect(contracts.coordinator.callReport(report, { gasPrice })) + .to.emit(contracts.coordinator, 'OracleResponse') + .withArgs(requestId, await roles.defaultAccount.getAddress()) + .to.emit(contracts.client, 'FulfillRequestInvoked') + .withArgs(requestId, response, error) + .to.emit(contracts.coordinator, 'BillingEnd') + .withArgs( + requestId, + subscriptionId, + () => true, + () => true, + () => true, + 1, // Result code for callback failing + ) }) - }) - describe('#flagsSet', async function () { - it('get flags that were previously set', async function () { - const flags = ethers.utils.formatBytes32String('arbitrary_byte_values') + it('callbacks are unable to improperly use subscription methods', async function () { await acceptTermsOfService( contracts.accessControl, roles.subOwner, roles.subOwnerAddress, ) - await expect( - contracts.router.connect(roles.subOwner).createSubscription(), + const createSubTx = await contracts.router + .connect(roles.subOwner) + .createSubscription() + const createSubReceipt = await createSubTx.wait() + const subscriptionId = + createSubReceipt.events[0].args['subscriptionId'].toNumber() + await contracts.router + .connect(roles.subOwner) + .addConsumer(subscriptionId, contracts.client.address) + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('1000000000000000000'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subscriptionId]), + ) + + // Set flag so they have enough callback gas + const flags = new Uint8Array(32) + flags[0] = 1 + await contracts.router + .connect(roles.defaultAccount) + .setFlags(subscriptionId, flags) + + // Accept ToS for client contract + const acceptorAddress = roles.subOwnerAddress + const recipientAddress = contracts.client.address + const messageHash = await contracts.accessControl.getMessageHash( + acceptorAddress, + recipientAddress, + ) + const wallet = new ethers.Wallet(accessControlMockPrivateKey) + const proof = await wallet.signMessage(ethers.utils.arrayify(messageHash)) + await contracts.client + .connect(roles.subOwner) + .acceptTermsOfService(acceptorAddress, recipientAddress, proof) + + // Transfer Subscription ownership to client contract so that it can call subscription methods + await contracts.router + .connect(roles.subOwner) + .requestSubscriptionOwnerTransfer( + subscriptionId, + contracts.client.address, + ) + await contracts.client.acceptSubscriptionOwnerTransfer(subscriptionId) + + // Set test helper flag + await contracts.client.setDoInvalidReentrantOperation( + true, + subscriptionId, + ) + + // Send request + const tx = await contracts.client.sendSimpleRequestWithJavaScript( + 'function run(){return response}', + subscriptionId, + ids.donId, + 400_000, + { gasPrice }, ) - .to.emit(contracts.router, 'SubscriptionCreated') - .withArgs(1, roles.subOwnerAddress) - await contracts.router.setFlags(1, flags) - expect(await contracts.router.getFlags(1)).to.equal(flags) + const { events } = await tx.wait() + const requestId = getEventArg(events, 'RequestSent', 0) + await expect(tx) + .to.emit(contracts.client, 'RequestSent') + .withArgs(requestId) + + const response = stringToBytes('response') + const error = stringToBytes('') + const abi = ethers.utils.defaultAbiCoder + + const report = abi.encode( + ['bytes32[]', 'bytes[]', 'bytes[]'], + [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ) + + await expect(contracts.coordinator.callReport(report, { gasPrice })) + .to.emit(contracts.coordinator, 'OracleResponse') + .withArgs(requestId, await roles.defaultAccount.getAddress()) + .to.emit(contracts.client, 'FulfillRequestInvoked') + .withArgs(requestId, response, error) + .to.emit(contracts.coordinator, 'BillingEnd') + .withArgs( + requestId, + subscriptionId, + () => true, + () => true, + () => true, + 1, // Result code for callback failing + ) }) }) }) diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index f189c72265c..41e8a2264ab 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -32,7 +32,7 @@ var ( var TermsOfServiceAllowListMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isAllowedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b5060405162000f9738038062000f97833981016040819052620000349162000164565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b038416179055620000848162000099565b80516020909101206000555062000292915050565b60008082806020019051810190620000b291906200024f565b6040805180820182528315158082526001600160a01b0384166020928301819052600480546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200014b57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200017857600080fd5b8251620001858162000135565b602084810151919350906001600160401b0380821115620001a557600080fd5b818601915086601f830112620001ba57600080fd5b815181811115620001cf57620001cf6200014e565b604051601f8201601f19908116603f01168101908382118183101715620001fa57620001fa6200014e565b8160405282815289868487010111156200021357600080fd5b600093505b8284101562000237578484018601518185018701529285019262000218565b60008684830101528096505050505050509250929050565b600080604083850312156200026357600080fd5b825180151581146200027457600080fd5b6020840151909250620002878162000135565b809150509250929050565b610cf580620002a26000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80638cc6acce11610076578063a5e1d61d1161005b578063a5e1d61d146101b0578063be8c97b0146101d3578063fa540801146101e657600080fd5b80638cc6acce146101955780639883c10d146101a857600080fd5b806347663acb116100a757806347663acb146100f657806380e8a1511461010957806382184c7b1461018257600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb610247565b6040516100d891906109d8565b60405180910390f35b6100f46100ef366004610a69565b610267565b005b6100f4610104366004610afb565b6104a4565b610174610117366004610b1f565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b6040519081526020016100d8565b6100f4610190366004610afb565b6105e7565b6100f46101a3366004610b87565b610742565b600054610174565b6101c36101be366004610afb565b6107a9565b60405190151581526020016100d8565b6101c36101e1366004610afb565b6107ea565b6101746101f4366004610c56565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610cc160289139905090565b73ffffffffffffffffffffffffffffffffffffffff831660009081526003602052604090205460ff16156102c7576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600454610100900473ffffffffffffffffffffffffffffffffffffffff1661038961034d6101f487876040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b84848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061082b92505050565b73ffffffffffffffffffffffffffffffffffffffff16146103d6576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff841614158061041b57503373ffffffffffffffffffffffffffffffffffffffff85161480159061041b5750333b155b15610452576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505073ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905550565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610513573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105379190610c6f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461059b576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b600160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610656573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061067a9190610c6f565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106de576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260026020908152604080832080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00908116909155600390925290912080549091166001179055565b60015473ffffffffffffffffffffffffffffffffffffffff163314610793576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61079c81610902565b8051602090910120600055565b60045460009060ff166107be57506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205460ff1690565b60045460009060ff166107ff57506001919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b600080600080845160411461086c576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050602082810151604080850151606080870151835160008082529681018086528a9052951a928501839052840183905260808401819052919260019060a0016020604051602081039080840390855afa1580156108cf573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b600080828060200190518101906109199190610c8c565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600480547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b600060208083528351808285015260005b81811015610a05578581018301518582016040015282016109e9565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a6657600080fd5b50565b60008060008060608587031215610a7f57600080fd5b8435610a8a81610a44565b93506020850135610a9a81610a44565b9250604085013567ffffffffffffffff80821115610ab757600080fd5b818701915087601f830112610acb57600080fd5b813581811115610ada57600080fd5b886020828501011115610aec57600080fd5b95989497505060200194505050565b600060208284031215610b0d57600080fd5b8135610b1881610a44565b9392505050565b60008060408385031215610b3257600080fd5b8235610b3d81610a44565b91506020830135610b4d81610a44565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610b9957600080fd5b813567ffffffffffffffff80821115610bb157600080fd5b818401915084601f830112610bc557600080fd5b813581811115610bd757610bd7610b58565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610c1d57610c1d610b58565b81604052828152876020848701011115610c3657600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610c6857600080fd5b5035919050565b600060208284031215610c8157600080fd5b8151610b1881610a44565b60008060408385031215610c9f57600080fd5b82518015158114610caf57600080fd5b6020840151909250610b4d81610a4456fe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162000fbe38038062000fbe833981016040819052620000349162000156565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660805262000076816200008b565b80516020909101206000555062000284915050565b60008082806020019051810190620000a4919062000241565b6040805180820182528315158082526001600160a01b0384166020928301819052600380546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013d57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016a57600080fd5b8251620001778162000127565b602084810151919350906001600160401b03808211156200019757600080fd5b818601915086601f830112620001ac57600080fd5b815181811115620001c157620001c162000140565b604051601f8201601f19908116603f01168101908382118183101715620001ec57620001ec62000140565b8160405282815289868487010111156200020557600080fd5b600093505b828410156200022957848401860151818501870152928501926200020a565b60008684830101528096505050505050509250929050565b600080604083850312156200025557600080fd5b825180151581146200026657600080fd5b6020840151909250620002798162000127565b809150509250929050565b608051610d10620002ae600039600081816104a9015281816105ea01526107570152610d106000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80638cc6acce11610076578063a5e1d61d1161005b578063a5e1d61d146101b0578063be8c97b0146101d3578063fa540801146101e657600080fd5b80638cc6acce146101955780639883c10d146101a857600080fd5b806347663acb116100a757806347663acb146100f657806380e8a1511461010957806382184c7b1461018257600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb610247565b6040516100d891906109f3565b60405180910390f35b6100f46100ef366004610a84565b610267565b005b6100f4610104366004610b16565b6104a7565b610174610117366004610b3a565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b6040519081526020016100d8565b6100f4610190366004610b16565b6105e8565b6100f46101a3366004610ba2565b61073f565b600054610174565b6101c36101be366004610b16565b6107c4565b60405190151581526020016100d8565b6101c36101e1366004610b16565b610805565b6101746101f4366004610c71565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610cdc60289139905090565b73ffffffffffffffffffffffffffffffffffffffff831660009081526002602052604090205460ff16156102c7576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600354610100900473ffffffffffffffffffffffffffffffffffffffff1661038961034d6101f487876040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b84848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061084692505050565b73ffffffffffffffffffffffffffffffffffffffff16146103d6576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff841614158061041b57503373ffffffffffffffffffffffffffffffffffffffff85161480159061041b5750333b155b15610452576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505073ffffffffffffffffffffffffffffffffffffffff16600090815260016020819052604090912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016909117905550565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610514573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105389190610c8a565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461059c576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610655573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106799190610c8a565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106dd576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260016020818152604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0090811690915560029092529092208054909216179055565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146107ae576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107b78161091d565b8051602090910120600055565b60035460009060ff166107d957506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b60035460009060ff1661081a57506001919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526001602052604090205460ff1690565b6000806000808451604114610887576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050602082810151604080850151606080870151835160008082529681018086528a9052951a928501839052840183905260808401819052919260019060a0016020604051602081039080840390855afa1580156108ea573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b600080828060200190518101906109349190610ca7565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600380547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b600060208083528351808285015260005b81811015610a2057858101830151858201604001528201610a04565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a8157600080fd5b50565b60008060008060608587031215610a9a57600080fd5b8435610aa581610a5f565b93506020850135610ab581610a5f565b9250604085013567ffffffffffffffff80821115610ad257600080fd5b818701915087601f830112610ae657600080fd5b813581811115610af557600080fd5b886020828501011115610b0757600080fd5b95989497505060200194505050565b600060208284031215610b2857600080fd5b8135610b3381610a5f565b9392505050565b60008060408385031215610b4d57600080fd5b8235610b5881610a5f565b91506020830135610b6881610a5f565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610bb457600080fd5b813567ffffffffffffffff80821115610bcc57600080fd5b818401915084601f830112610be057600080fd5b813581811115610bf257610bf2610b73565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610c3857610c38610b73565b81604052828152876020848701011115610c5157600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610c8357600080fd5b5035919050565b600060208284031215610c9c57600080fd5b8151610b3381610a5f565b60008060408385031215610cba57600080fd5b82518015158114610cca57600080fd5b6020840151909250610b6881610a5f56fe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go index 7a300aee3f8..ab7b65b454d 100644 --- a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go +++ b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go @@ -32,7 +32,7 @@ var ( var FunctionsClientExampleMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b50604051620019e3380380620019e3833981016040819052620000349162000198565b600080546001600160a01b0319166001600160a01b038316178155339081906001600160a01b038216620000af5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600180546001600160a01b0319166001600160a01b0384811691909117909155811615620000e257620000e281620000ec565b50505050620001ca565b336001600160a01b03821603620001465760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a6565b600280546001600160a01b0319166001600160a01b03838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b600060208284031215620001ab57600080fd5b81516001600160a01b0381168114620001c357600080fd5b9392505050565b61180980620001da6000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc366004611255565b6101ae565b005b6100ec60045481565b6040519081526020015b60405180910390f35b60065461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60055481565b6100e1610143366004611328565b61020f565b6101176201117081565b6100e1610319565b60015460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60035481565b6100e161019936600461140c565b61041f565b6006546101179063ffffffff1681565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ff576040517f5099014100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61020a838383610433565b505050565b610217610501565b6102586040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b61029a89898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105849050565b85156102e2576102e287878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105959050565b83156102fc576102fc6102f58587611442565b82906105df565b61030b81846201117085610622565b600355505050505050505050565b60025473ffffffffffffffffffffffffffffffffffffffff16331461039f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560028054909116905560405173ffffffffffffffffffffffffffffffffffffffff909116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b610427610501565b61043081610646565b50565b8260035414610471576040517fd068bf5b00000000000000000000000000000000000000000000000000000000815260048101849052602401610396565b61047a8261073c565b6004558151600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104bc8161073c565b600555516006805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610396565b565b61059182600080846107be565b5050565b80516000036105d0576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b805160000361061a576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b60008061062e86610855565b905061063c81868686610bc2565b9695505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610396565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60008060209050602083511015610751575081515b60005b818110156107b757610767816008611538565b8482815181106107795761077961154f565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107b08161157e565b9050610754565b5050919050565b80516000036107f9576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561080c5761080c6114da565b9081600281111561081f5761081f6114da565b90525060408401828015610835576108356114da565b90818015610845576108456114da565b9052506060909301929092525050565b606061085f61110c565b805161086d90610100610c9b565b506108ad816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d15565b6108cc81846000015160028111156108c7576108c76114da565b610d2e565b61090b816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d15565b61092581846040015160008111156108c7576108c76114da565b610964816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d15565b610972818460600151610d15565b60a08301515115610a16576109bc816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d15565b6109c581610d67565b60005b8360a0015151811015610a0c576109fc828560a0015183815181106109ef576109ef61154f565b6020026020010151610d15565b610a058161157e565b90506109c8565b50610a1681610d8b565b60808301515115610b1657600083602001516002811115610a3957610a396114da565b03610a70576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610aaf816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d15565b610ac981846020015160028111156108c7576108c76114da565b610b08816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d15565b610b16818460800151610da9565b60c08301515115610bba57610b60816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d15565b610b6981610d67565b60005b8360c0015151811015610bb057610ba0828560c001518381518110610b9357610b9361154f565b6020026020010151610da9565b610ba98161157e565b9050610b6c565b50610bba81610d8b565b515192915050565b600080546040517f461d276200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063461d276290610c229087908990600190899089906004016115b6565b6020604051808303816000875af1158015610c41573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c659190611656565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a2949350505050565b604080518082019091526060815260006020820152610cbb60208361166f565b15610ce357610ccb60208361166f565b610cd69060206116aa565b610ce090836116bd565b91505b602080840183905260405180855260008152908184010181811015610d0757600080fd5b604052508290505b92915050565b610d228260038351610db2565b815161020a9082610ed9565b8151610d3b9060c2610f01565b506105918282604051602001610d5391815260200190565b604051602081830303815290604052610da9565b610d72816004610f6a565b600181602001818151610d8591906116bd565b90525050565b610d96816007610f6a565b600181602001818151610d8591906116aa565b610d2282600283515b60178167ffffffffffffffff1611610ddf578251610dd99060e0600585901b168317610f01565b50505050565b60ff8167ffffffffffffffff1611610e21578251610e08906018611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166001610f81565b61ffff8167ffffffffffffffff1611610e64578251610e4b906019611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166002610f81565b63ffffffff8167ffffffffffffffff1611610ea9578251610e9090601a611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166004610f81565b8251610ec090601b611fe0600586901b1617610f01565b508251610dd99067ffffffffffffffff83166008610f81565b604080518082019091526060815260006020820152610efa83838451611006565b9392505050565b6040805180820190915260608152600060208201528251516000610f268260016116bd565b905084602001518210610f4757610f4785610f42836002611538565b6110f5565b8451602083820101858153508051821115610f60578181525b5093949350505050565b815161020a90601f611fe0600585901b1617610f01565b6040805180820190915260608152600060208201528351516000610fa582856116bd565b90508560200151811115610fc257610fc286610f42836002611538565b60006001610fd2866101006117f0565b610fdc91906116aa565b90508651828101878319825116178152508051831115610ffa578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561102957600080fd5b835151600061103884836116bd565b905085602001518111156110555761105586610f42836002611538565b85518051838201602001916000918085111561106f578482525b505050602086015b602086106110af578051825261108e6020836116bd565b915061109b6020826116bd565b90506110a86020876116aa565b9550611077565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111018383610c9b565b50610dd98382610ed9565b6040518060400160405280611134604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111b7576111b7611141565b604052919050565b600067ffffffffffffffff8311156111d9576111d9611141565b61120a60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f86011601611170565b905082815283838301111561121e57600080fd5b828260208301376000602084830101529392505050565b600082601f83011261124657600080fd5b610efa838335602085016111bf565b60008060006060848603121561126a57600080fd5b83359250602084013567ffffffffffffffff8082111561128957600080fd5b61129587838801611235565b935060408601359150808211156112ab57600080fd5b506112b886828701611235565b9150509250925092565b60008083601f8401126112d457600080fd5b50813567ffffffffffffffff8111156112ec57600080fd5b60208301915083602082850101111561130457600080fd5b9250929050565b803567ffffffffffffffff8116811461132357600080fd5b919050565b60008060008060008060008060a0898b03121561134457600080fd5b883567ffffffffffffffff8082111561135c57600080fd5b6113688c838d016112c2565b909a50985060208b013591508082111561138157600080fd5b61138d8c838d016112c2565b909850965060408b01359150808211156113a657600080fd5b818b0191508b601f8301126113ba57600080fd5b8135818111156113c957600080fd5b8c60208260051b85010111156113de57600080fd5b6020830196508095505050506113f660608a0161130b565b9150608089013590509295985092959890939650565b60006020828403121561141e57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610efa57600080fd5b600067ffffffffffffffff8084111561145d5761145d611141565b8360051b602061146e818301611170565b86815291850191818101903684111561148657600080fd5b865b848110156114ce578035868111156114a05760008081fd5b880136601f8201126114b25760008081fd5b6114c03682358784016111bf565b845250918301918301611488565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d0f57610d0f611509565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115af576115af611509565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156115f45788810183015185820160c0015282016115d8565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505061163d604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561166857600080fd5b5051919050565b6000826116a5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d0f57610d0f611509565b80820180821115610d0f57610d0f611509565b600181815b8085111561172957817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561170f5761170f611509565b8085161561171c57918102915b93841c93908002906116d5565b509250929050565b60008261174057506001610d0f565b8161174d57506000610d0f565b8160018114611763576002811461176d57611789565b6001915050610d0f565b60ff84111561177e5761177e611509565b50506001821b610d0f565b5060208310610133831016604e8410600b84101617156117ac575081810a610d0f565b6117b683836116d0565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117e8576117e8611509565b029392505050565b6000610efa838361173156fea164736f6c6343000813000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001a1538038062001a15833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b608051611840620001d5600039600081816101c60152610c1b01526118406000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc36600461128c565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e161014336600461135f565b61022d565b6101176201117081565b6100e1610337565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e1610199366004611443565b610439565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517f5099014100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361044d565b505050565b61023561051b565b6102766040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6102b889898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061059e9050565b85156103005761030087878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105af9050565b831561031a5761031a6103138587611479565b82906105f9565b6103298184620111708561063c565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61044161051b565b61044a81610660565b50565b826002541461048b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103b4565b61049482610755565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104d681610755565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461059c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103b4565b565b6105ab82600080846107d7565b5050565b80516000036105ea576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610634576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b6000806106488661086e565b905061065681868686610bdb565b9695505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103b4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806020905060208351101561076a575081515b60005b818110156107d05761078081600861156f565b84828151811061079257610792611586565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107c9816115b5565b905061076d565b5050919050565b8051600003610812576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561082557610825611511565b9081600281111561083857610838611511565b9052506040840182801561084e5761084e611511565b9081801561085e5761085e611511565b9052506060909301929092525050565b6060610878611143565b805161088690610100610cd2565b506108c6816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d4c565b6108e581846000015160028111156108e0576108e0611511565b610d65565b610924816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d4c565b61093e81846040015160008111156108e0576108e0611511565b61097d816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d4c565b61098b818460600151610d4c565b60a08301515115610a2f576109d5816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d4c565b6109de81610d9e565b60005b8360a0015151811015610a2557610a15828560a001518381518110610a0857610a08611586565b6020026020010151610d4c565b610a1e816115b5565b90506109e1565b50610a2f81610dc2565b60808301515115610b2f57600083602001516002811115610a5257610a52611511565b03610a89576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ac8816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d4c565b610ae281846020015160028111156108e0576108e0611511565b610b21816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d4c565b610b2f818460800151610de0565b60c08301515115610bd357610b79816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d4c565b610b8281610d9e565b60005b8360c0015151811015610bc957610bb9828560c001518381518110610bac57610bac611586565b6020026020010151610de0565b610bc2816115b5565b9050610b85565b50610bd381610dc2565b515192915050565b6040517f461d276200000000000000000000000000000000000000000000000000000000815260009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063461d276290610c599087908990600190899089906004016115ed565b6020604051808303816000875af1158015610c78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9c919061168d565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a2949350505050565b604080518082019091526060815260006020820152610cf26020836116a6565b15610d1a57610d026020836116a6565b610d0d9060206116e1565b610d1790836116f4565b91505b602080840183905260405180855260008152908184010181811015610d3e57600080fd5b604052508290505b92915050565b610d598260038351610de9565b81516102289082610f10565b8151610d729060c2610f38565b506105ab8282604051602001610d8a91815260200190565b604051602081830303815290604052610de0565b610da9816004610fa1565b600181602001818151610dbc91906116f4565b90525050565b610dcd816007610fa1565b600181602001818151610dbc91906116e1565b610d5982600283515b60178167ffffffffffffffff1611610e16578251610e109060e0600585901b168317610f38565b50505050565b60ff8167ffffffffffffffff1611610e58578251610e3f906018611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166001610fb8565b61ffff8167ffffffffffffffff1611610e9b578251610e82906019611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166002610fb8565b63ffffffff8167ffffffffffffffff1611610ee0578251610ec790601a611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166004610fb8565b8251610ef790601b611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166008610fb8565b604080518082019091526060815260006020820152610f318383845161103d565b9392505050565b6040805180820190915260608152600060208201528251516000610f5d8260016116f4565b905084602001518210610f7e57610f7e85610f7983600261156f565b61112c565b8451602083820101858153508051821115610f97578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f38565b6040805180820190915260608152600060208201528351516000610fdc82856116f4565b90508560200151811115610ff957610ff986610f7983600261156f565b6000600161100986610100611827565b61101391906116e1565b90508651828101878319825116178152508051831115611031578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561106057600080fd5b835151600061106f84836116f4565b9050856020015181111561108c5761108c86610f7983600261156f565b8551805183820160200191600091808511156110a6578482525b505050602086015b602086106110e657805182526110c56020836116f4565b91506110d26020826116f4565b90506110df6020876116e1565b95506110ae565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111388383610cd2565b50610e108382610f10565b604051806040016040528061116b604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111ee576111ee611178565b604052919050565b600067ffffffffffffffff83111561121057611210611178565b61124160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116016111a7565b905082815283838301111561125557600080fd5b828260208301376000602084830101529392505050565b600082601f83011261127d57600080fd5b610f31838335602085016111f6565b6000806000606084860312156112a157600080fd5b83359250602084013567ffffffffffffffff808211156112c057600080fd5b6112cc8783880161126c565b935060408601359150808211156112e257600080fd5b506112ef8682870161126c565b9150509250925092565b60008083601f84011261130b57600080fd5b50813567ffffffffffffffff81111561132357600080fd5b60208301915083602082850101111561133b57600080fd5b9250929050565b803567ffffffffffffffff8116811461135a57600080fd5b919050565b60008060008060008060008060a0898b03121561137b57600080fd5b883567ffffffffffffffff8082111561139357600080fd5b61139f8c838d016112f9565b909a50985060208b01359150808211156113b857600080fd5b6113c48c838d016112f9565b909850965060408b01359150808211156113dd57600080fd5b818b0191508b601f8301126113f157600080fd5b81358181111561140057600080fd5b8c60208260051b850101111561141557600080fd5b60208301965080955050505061142d60608a01611342565b9150608089013590509295985092959890939650565b60006020828403121561145557600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f3157600080fd5b600067ffffffffffffffff8084111561149457611494611178565b8360051b60206114a58183016111a7565b8681529185019181810190368411156114bd57600080fd5b865b84811015611505578035868111156114d75760008081fd5b880136601f8201126114e95760008081fd5b6114f73682358784016111f6565b8452509183019183016114bf565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d4657610d46611540565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115e6576115e6611540565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b8181101561162b5788810183015185820160c00152820161160f565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050611674604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561169f57600080fd5b5051919050565b6000826116dc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d4657610d46611540565b80820180821115610d4657610d46611540565b600181815b8085111561176057817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561174657611746611540565b8085161561175357918102915b93841c939080029061170c565b509250929050565b60008261177757506001610d46565b8161178457506000610d46565b816001811461179a57600281146117a4576117c0565b6001915050610d46565b60ff8411156117b5576117b5611540565b50506001821b610d46565b5060208310610133831016604e8410600b84101617156117e3575081810a610d46565b6117ed8383611707565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561181f5761181f611540565b029392505050565b6000610f31838361176856fea164736f6c6343000813000a", } var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 0bc810e8bb6..bfc31cf0633 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -62,7 +62,7 @@ type IFunctionsCoordinatorRequest struct { var FunctionsCoordinatorMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162005bfd38038062005bfd833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000162565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b600880546001600160a01b0319166001600160a01b0384161790556200011b816200020d565b805160209091012060075550600e80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001bc5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000231919062000572565b9850985098509850985098509850985098506000851362000269576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160501b038a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d9052600a8054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600b829055600c869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd73906200041b908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160501b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b955060808a01519450620005e460a08b016200055d565b60c08b01519094506001600160501b03811681146200060257600080fd5b60e08b015190935061ffff811681146200061b57600080fd5b809250506101008a015190509295985092959850929598565b6080516155ad62000650600039600061152101526155ad6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e1461053f578063de9dfa4614610547578063e3d0e7121461055a578063f2fde38b1461056d57600080fd5b8063b1dc65a41461040d578063c3f909d414610420578063d227d2451461050f57600080fd5b8063aecc12c5116100c8578063aecc12c5146103a5578063af1296d3146103e5578063afcb95d7146103ed57600080fd5b80638cc6acce146103585780638da5cb5b1461036b5780639883c10d1461039357600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ab57806381f1b938146102c057806381ff7048146102c857806385b214cf1461033557600080fd5b806379ba50971461027d5780637f15e16614610285578063807560311461029857600080fd5b8063466557181161018c5780634665571814610226578063533989871461025457806366316d8d1461026a57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c136600461404d565b610580565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a91906140f3565b60405180910390f35b6101c6610221366004614128565b6105d5565b610239610234366004614284565b610677565b60405169ffffffffffffffffffff909116815260200161020a565b61025c6106a5565b60405161020a9291906143ab565b6101c6610278366004614455565b610929565b6101c6610aa7565b6101c661029336600461404d565b610ba9565b6101c66102a636600461448e565b610bf9565b6102b3610cb0565b60405161020a91906144e3565b6101fd610d1f565b61031260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff94851681529390921660208401529082015260600161020a565b6103486103433660046144f6565b610df0565b604051901515815260200161020a565b6101c661036636600461450f565b611012565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6007545b60405190815260200161020a565b6103b86103b336600461454c565b611079565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b6103976112bb565b60408051600181526000602082018190529181019190915260600161020a565b6101c661041b3660046145cc565b6113ae565b6104ab600a54600c54600e54600b5463ffffffff8085169564010000000086048216956c010000000000000000000000008082048416969568010000000000000000830490941694930473ffffffffffffffffffffffffffffffffffffffff16927e0100000000000000000000000000000000000000000000000000000000000090910461ffff1691565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61052261051d366004614683565b611adf565b6040516bffffffffffffffffffffffff909116815260200161020a565b6101fd611cb1565b610522610555366004614284565b611d08565b6101c66105683660046147a5565b611da3565b6101c661057b366004614128565b6127c7565b6105886127d8565b60008190036105c3576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60116105d0828483614913565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061057503373ffffffffffffffffffffffffffffffffffffffff8216145b610646576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260106020526040812061067491613f92565b50565b600a5474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106e2575b505050505090506000815167ffffffffffffffff81111561073057610730614145565b60405190808252806020026020018201604052801561076357816020015b606081526020019060019003908161074e5790505b50905060005b825181101561091f576010600084838151811061078857610788614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107d590614872565b9050600003610810576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6010600084838151811061082657610826614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461087390614872565b80601f016020809104026020016040519081016040528092919081815260200182805461089f90614872565b80156108ec5780601f106108c1576101008083540402835291602001916108ec565b820191906000526020600020905b8154815290600101906020018083116108cf57829003601f168201915b505050505082828151811061090357610903614a2e565b60200260200101819052508061091890614a8c565b9050610769565b5090939092509050565b61093161285b565b806bffffffffffffffffffffffff166000036109675750336000908152600d60205260409020546bffffffffffffffffffffffff165b336000908152600d60205260409020546bffffffffffffffffffffffff808316911610156109c1576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906109ee9084906bffffffffffffffffffffffff16614ac4565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556008546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610a8a57600080fd5b505af1158015610a9e573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b2d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bb16127d8565b6000819003610bec576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105d0828483614913565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c445750610c23336129f2565b8015610c4457503373ffffffffffffffffffffffffffffffffffffffff8416145b610c7a576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601060205260409020610caa828483614913565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d1557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610cea575b5050505050905090565b606060118054610d2e90614872565b9050600003610d69576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60118054610d7690614872565b80601f0160208091040260200160405190810160405280929190818152602001828054610da290614872565b8015610d155780601f10610dc457610100808354040283529160200191610d15565b820191906000526020600020905b815481529060010190602001808311610dd257509395945050505050565b60085460009073ffffffffffffffffffffffffffffffffffffffff163314610e44576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260096020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff1661010084015260030154610120830152610f985750600092915050565b600083815260096020526040808220828155600181018390556002810180547fff000000000000000000000000000000000000000000000000000000000000001690556003018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b60085473ffffffffffffffffffffffffffffffffffffffff163314611063576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61106c81612adb565b8051602090910120600755565b60085460009081908190819073ffffffffffffffffffffffffffffffffffffffff1633146110d3576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110e06040860186614af0565b905060000361111a576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000604051806080016040528087606001602081019061113a9190614b55565b67ffffffffffffffff16815260209081019061115890890189614128565b73ffffffffffffffffffffffffffffffffffffffff16815260200161118360e0890160c08a01614b72565b63ffffffff1681523a60209091015290506111ef6111a46040880188614af0565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506111e99250505060a0890160808a01614b9f565b83612dd6565b929750909550935091506112066020870187614128565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c3261124f60808b0160608c01614b55565b61125f60408c0160208d01614128565b61126c60408d018d614af0565b8d608001602081019061127f9190614b9f565b8e60a001358f60c00160208101906112979190614b72565b6040516112ab989796959493929190614bbc565b60405180910390a3509193509193565b600a54600e54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611355573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113799190614c7c565b5093505092505082801561139b57506113928142614ccc565b8463ffffffff16105b156113a657600c5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161140491849163ffffffff851691908e908e908190840183828082843760009201919091525061346392505050565b61143a576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461150f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b24565b61151d8b8b8b8b8b8b61346c565b60007f00000000000000000000000000000000000000000000000000000000000000001561157a5760028260200151836040015161155b9190614cdf565b6115659190614d27565b611570906001614cdf565b60ff169050611590565b602082015161158a906001614cdf565b60ff1690505b8881146115f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b24565b888714611662576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b24565b3360009081526004602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156116a5576116a5614d49565b60028111156116b6576116b6614d49565b90525090506002816020015160028111156116d3576116d3614d49565b14801561171a57506006816000015160ff16815481106116f5576116f5614a2e565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611780576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b24565b505050505061178d613fcc565b6000808a8a6040516117a0929190614d78565b6040519081900381206117b7918e90602001614d88565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611ac157600060018489846020811061182057611820614a2e565b61182d91901a601b614cdf565b8e8e8681811061183f5761183f614a2e565b905060200201358d8d8781811061185857611858614a2e565b9050602002013560405160008152602001604052604051611895949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156118b7573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561193757611937614d49565b600281111561194857611948614d49565b905250925060018360200151600281111561196557611965614d49565b146119cc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b24565b8251600090879060ff16601f81106119e6576119e6614a2e565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611a68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b24565b8086846000015160ff16601f8110611a8257611a82614a2e565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611aad600186614cdf565b94505080611aba90614a8c565b9050611801565b505050611ad2833383858e8e61351a565b5050505050505050505050565b6008546040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8716600482015263ffffffff8416602482015260009173ffffffffffffffffffffffffffffffffffffffff169081906310fc49c19060440160006040518083038186803b158015611b6157600080fd5b505afa158015611b75573d6000803e3d6000fd5b50505050620f4240831115611bb6576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611c4488888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610677915050565b69ffffffffffffffffffff1690506000611c9589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611d08915050565b9050611ca387878484613821565b9a9950505050505050505050565b6060600f8054611cc090614872565b9050600003611cfb576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610d7690614872565b600854604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc9160048083019260209291908290030181865afa158015611d78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d9c9190614d9c565b9392505050565b855185518560ff16601f831115611e16576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b24565b80600003611e80576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b24565b818314611f0e576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b24565b611f19816003614db9565b8311611f81576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b24565b611f896127d8565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611fd09088613983565b6005541561218557600554600090611fea90600190614ccc565b905060006005828154811061200157612001614a2e565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061203b5761203b614a2e565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000908116909155929091168084529220805490911690556005805491925090806120bb576120bb614dd0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061212457612124614dd0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611fd0915050565b60005b8151518110156125ec57600060046000846000015184815181106121ae576121ae614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121f8576121f8614d49565b1461225f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b24565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061229057612290614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561233157612331614d49565b0217905550600091506123419050565b600460008460200151848151811061235b5761235b614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156123a5576123a5614d49565b1461240c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b24565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061243f5761243f614a2e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124e0576124e0614d49565b0217905550508251805160059250839081106124fe576124fe614a2e565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061257a5761257a614a2e565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125e481614a8c565b915050612188565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff43811682029290921780855592048116929182916014916126a491849174010000000000000000000000000000000000000000900416614dff565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127034630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516139a0565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05986127ba988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614e1c565b60405180910390a1611ad2565b6127cf6127d8565b61067481613a4b565b60005473ffffffffffffffffffffffffffffffffffffffff163314612859576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b24565b565b6000612865610cb0565b905080516000036128a2576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600e546000916128c1916bffffffffffffffffffffffff16614ea2565b905060005b82518160ff1610156129935781600d6000858460ff16815181106128ec576128ec614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129549190614ecd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061298c90614ef2565b90506128c6565b5081516129a09082614f11565b600e80546000906129c09084906bffffffffffffffffffffffff16614ac4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a5857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a2d575b5050505050905060005b8151811015612ad1578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a9457612a94614a2e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612ac1575060019392505050565b612aca81614a8c565b9050612a62565b5060009392505050565b600080600080600080600080600089806020019051810190612afd9190614f41565b98509850985098509850985098509850985060008513612b4c576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610b24565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a166080860181905269ffffffffffffffffffff8a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d9052600a80547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600b829055600c869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd7390612dc2908b908b908a908c908b908a908a908a9063ffffffff988916815296881660208801529487166040870152929095166060850152608084015269ffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b600a5460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612e45576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612e518887610677565b90506000612e5f8988611d08565b90506000612e83886040015189606001518569ffffffffffffffffffff1685613821565b60085489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c769690602401600060405180830381865afa158015612f06573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612f4c9190810190614fed565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015612fdd573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061300191906150d9565b509150506bffffffffffffffffffffffff851661301e8385614ac4565b6bffffffffffffffffffffffff161015613064576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006130e3308e602001518f60000151856001613081919061512b565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff168152602001600a600001600c9054906101000a900463ffffffff16600a60000160089054906101000a900463ffffffff166131cf9190614dff565b63ffffffff1664ffffffffff1681526020018f606001518152509050806009600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd82604051613413919061514c565b60405180910390a250600a54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613479826020614db9565b613484856020614db9565b61349088610144615261565b61349a9190615261565b6134a49190615261565b6134af906000615261565b9050368114610a9e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b24565b6060808061352a848601866152f4565b82519295509093509150158061354257508151835114155b8061354f57508051835114155b15613586576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156138155760006135ea8583815181106135a9576135a9614a2e565b60200260200101518584815181106135c3576135c3614a2e565b60200260200101518585815181106135dd576135dd614a2e565b6020026020010151613b40565b9050600081600681111561360057613600614d49565b148061361d5750600181600681111561361b5761361b614d49565b145b156136785784828151811061363457613634614a2e565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613804565b600281600681111561368c5761368c614d49565b036136dc578482815181106136a3576136a3614a2e565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613804565b60038160068111156136f0576136f0614d49565b036137405784828151811061370757613707614a2e565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613804565b600581600681111561375457613754614d49565b036137a45784828151811061376b5761376b614a2e565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a2613804565b60048160068111156137b8576137b8614d49565b03613804578482815181106137cf576137cf614a2e565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b5061380e81614a8c565b9050613589565b50505050505050505050565b60008061382c6112bb565b90506000811361386b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b24565b600a5460009087906138a19063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614dff565b6138ab9190614dff565b63ffffffff1690506000612710600a60010154886138c99190614db9565b6138d391906153d1565b6138dd9088615261565b9050600083836138f584670de0b6b3a7640000614db9565b6138ff9190614db9565b61390991906153d1565b905060006139286bffffffffffffffffffffffff808916908a16615261565b9050613940816b033b2e3c9fd0803ce8000000614ccc565b821115613979576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611ca38183615261565b600061398d610cb0565b51111561399c5761399c61285b565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016139c4999897969594939291906153e5565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613aca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b24565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600960209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613c95576002915050611d9c565b6000858152600960205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613ce56112bb565b905060008113613d24576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b24565b600081613d393a670de0b6b3a7640000614db9565b613d4391906153d1565b9050600083610100015164ffffffffff1682613d5f9190614db9565b905060008460c0015169ffffffffffffffffffff1682613d7f9190614ecd565b6008546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613de7908f908f908f908c908b90339060040161547a565b60408051808303816000875af1158015613e05573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613e2991906154eb565b9092509050613e388186614ecd565b336000908152600d6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600e805469ffffffffffffffffffff90921693909291613ea591859116614ecd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c001518489613f0b9190614ecd565b60808d015160c08e015169ffffffffffffffffffff16613f2b888d614ecd565b613f359190614ecd565b613f3f9190614ecd565b8760ff166006811115613f5457613f54614d49565b604051613f6595949392919061551a565b60405180910390a28160ff166006811115613f8257613f82614d49565b9c9b505050505050505050505050565b508054613f9e90614872565b6000825580601f10613fae575050565b601f0160209004906000526020600020908101906106749190613feb565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156140005760008155600101613fec565b5090565b60008083601f84011261401657600080fd5b50813567ffffffffffffffff81111561402e57600080fd5b60208301915083602082850101111561404657600080fd5b9250929050565b6000806020838503121561406057600080fd5b823567ffffffffffffffff81111561407757600080fd5b61408385828601614004565b90969095509350505050565b6000815180845260005b818110156140b557602081850181015186830182015201614099565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611d9c602083018461408f565b73ffffffffffffffffffffffffffffffffffffffff8116811461067457600080fd5b60006020828403121561413a57600080fd5b8135611d9c81614106565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156141bb576141bb614145565b604052919050565b600082601f8301126141d457600080fd5b813567ffffffffffffffff8111156141ee576141ee614145565b61421f60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614174565b81815284602083860101111561423457600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067457600080fd5b803561100d81614251565b63ffffffff8116811461067457600080fd5b60008082840360a081121561429857600080fd5b833567ffffffffffffffff808211156142b057600080fd5b6142bc878388016141c3565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156142ee57600080fd5b6040519250608083019150828210818311171561430d5761430d614145565b50604052602084013561431f81614251565b8152604084013561432f81614106565b6020820152606084013561434281614272565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156143a057815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161436e565b509495945050505050565b6040815260006143be604083018561435a565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561442c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261441a83835161408f565b948601949250908501906001016143e0565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461067457600080fd5b6000806040838503121561446857600080fd5b823561447381614106565b915060208301356144838161443b565b809150509250929050565b6000806000604084860312156144a357600080fd5b83356144ae81614106565b9250602084013567ffffffffffffffff8111156144ca57600080fd5b6144d686828701614004565b9497909650939450505050565b602081526000611d9c602083018461435a565b60006020828403121561450857600080fd5b5035919050565b60006020828403121561452157600080fd5b813567ffffffffffffffff81111561453857600080fd5b614544848285016141c3565b949350505050565b60006020828403121561455e57600080fd5b813567ffffffffffffffff81111561457557600080fd5b820160e08185031215611d9c57600080fd5b60008083601f84011261459957600080fd5b50813567ffffffffffffffff8111156145b157600080fd5b6020830191508360208260051b850101111561404657600080fd5b60008060008060008060008060e0898b0312156145e857600080fd5b606089018a8111156145f957600080fd5b8998503567ffffffffffffffff8082111561461357600080fd5b61461f8c838d01614004565b909950975060808b013591508082111561463857600080fd5b6146448c838d01614587565b909750955060a08b013591508082111561465d57600080fd5b5061466a8b828c01614587565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561469b57600080fd5b85356146a681614251565b9450602086013567ffffffffffffffff8111156146c257600080fd5b6146ce88828901614004565b90955093505060408601356146e281614272565b949793965091946060013592915050565b600067ffffffffffffffff82111561470d5761470d614145565b5060051b60200190565b600082601f83011261472857600080fd5b8135602061473d614738836146f3565b614174565b82815260059290921b8401810191818101908684111561475c57600080fd5b8286015b8481101561478057803561477381614106565b8352918301918301614760565b509695505050505050565b60ff8116811461067457600080fd5b803561100d8161478b565b60008060008060008060c087890312156147be57600080fd5b863567ffffffffffffffff808211156147d657600080fd5b6147e28a838b01614717565b975060208901359150808211156147f857600080fd5b6148048a838b01614717565b965061481260408a0161479a565b9550606089013591508082111561482857600080fd5b6148348a838b016141c3565b945061484260808a01614267565b935060a089013591508082111561485857600080fd5b5061486589828a016141c3565b9150509295509295509295565b600181811c9082168061488657607f821691505b6020821081036148bf577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105d057600081815260208120601f850160051c810160208610156148ec5750805b601f850160051c820191505b8181101561490b578281556001016148f8565b505050505050565b67ffffffffffffffff83111561492b5761492b614145565b61493f836149398354614872565b836148c5565b6000601f841160018114614991576000851561495b5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614a27565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156149e057868501358255602094850194600190920191016149c0565b5086821015614a1b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614abd57614abd614a5d565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614ae957614ae9614a5d565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614b2557600080fd5b83018035915067ffffffffffffffff821115614b4057600080fd5b60200191503681900382131561404657600080fd5b600060208284031215614b6757600080fd5b8135611d9c81614251565b600060208284031215614b8457600080fd5b8135611d9c81614272565b61ffff8116811461067457600080fd5b600060208284031215614bb157600080fd5b8135611d9c81614b8f565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461100d57600080fd5b600080600080600060a08688031215614c9457600080fd5b614c9d86614c62565b9450602086015193506040860151925060608601519150614cc060808701614c62565b90509295509295909350565b8181038181111561069f5761069f614a5d565b60ff818116838216019081111561069f5761069f614a5d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614d3a57614d3a614cf8565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614dae57600080fd5b8151611d9c8161443b565b808202811582820484141761069f5761069f614a5d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614ae957614ae9614a5d565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614e4c8184018a61435a565b90508281036080840152614e60818961435a565b905060ff871660a084015282810360c0840152614e7d818761408f565b905067ffffffffffffffff851660e0840152828103610100840152613f82818561408f565b60006bffffffffffffffffffffffff80841680614ec157614ec1614cf8565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614ae957614ae9614a5d565b600060ff821660ff8103614f0857614f08614a5d565b60010192915050565b6bffffffffffffffffffffffff818116838216028082169190828114614f3957614f39614a5d565b505092915050565b60008060008060008060008060006101208a8c031215614f6057600080fd5b8951614f6b81614272565b60208b0151909950614f7c81614272565b60408b0151909850614f8d81614272565b60608b0151909750614f9e81614272565b60808b015160a08c01519197509550614fb681614272565b9350614fc460c08b01614c62565b925060e08a0151614fd481614b8f565b809250506101008a015190509295985092959850929598565b600080600080600060a0868803121561500557600080fd5b85516150108161443b565b809550506020808701516150238161443b565b604088015190955061503481614106565b606088015190945061504581614106565b608088015190935067ffffffffffffffff81111561506257600080fd5b8701601f8101891361507357600080fd5b8051615081614738826146f3565b81815260059190911b8201830190838101908b8311156150a057600080fd5b928401925b828410156150c75783516150b881614106565b825292840192908401906150a5565b80955050505050509295509295909350565b6000806000606084860312156150ee57600080fd5b835180151581146150fe57600080fd5b602085015190935061510f81614251565b604085015190925061512081614251565b809150509250925092565b67ffffffffffffffff818116838216019080821115614ae957614ae9614a5d565b815167ffffffffffffffff16815261014081016020830151615186602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161519e604084018263ffffffff169052565b5060608301516151c6606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516151e660808401826bffffffffffffffffffffffff169052565b5060a083015161520660a08401826bffffffffffffffffffffffff169052565b5060c083015161522460c084018269ffffffffffffffffffff169052565b5060e083015161523c60e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b8082018082111561069f5761069f614a5d565b600082601f83011261528557600080fd5b81356020615295614738836146f3565b82815260059290921b840181019181810190868411156152b457600080fd5b8286015b8481101561478057803567ffffffffffffffff8111156152d85760008081fd5b6152e68986838b01016141c3565b8452509183019183016152b8565b60008060006060848603121561530957600080fd5b833567ffffffffffffffff8082111561532157600080fd5b818601915086601f83011261533557600080fd5b81356020615345614738836146f3565b82815260059290921b8401810191818101908a84111561536457600080fd5b948201945b8386101561538257853582529482019490820190615369565b9750508701359250508082111561539857600080fd5b6153a487838801615274565b935060408601359150808211156153ba57600080fd5b506153c786828701615274565b9150509250925092565b6000826153e0576153e0614cf8565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b16604085015281606085015261542c8285018b61435a565b91508382036080850152615440828a61435a565b915060ff881660a085015283820360c085015261545d828861408f565b90861660e08501528381036101008501529050613f82818561408f565b86815260c06020820152600061549360c083018861408f565b82810360408401526154a5818861408f565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156154fe57600080fd5b82516155098161478b565b60208401519092506144838161443b565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a0810160078310615590577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005cf438038062005cf4833981016040819052620000349162000454565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006269350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000564565b985098509850985098509850985098509850600085136200025b576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160501b038a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a829055600b869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd73906200040d908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160501b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046a57600080fd5b620004758462000421565b602085810151919450906001600160401b03808211156200049557600080fd5b818701915087601f830112620004aa57600080fd5b815181811115620004bf57620004bf6200043e565b604051601f8201601f19908116603f01168101908382118183101715620004ea57620004ea6200043e565b816040528281528a868487010111156200050357600080fd5b600093505b8284101562000527578484018601518185018701529285019262000508565b6000868483010152809750505050505050620005466040850162000421565b90509250925092565b805163ffffffff811681146200043957600080fd5b60008060008060008060008060006101208a8c0312156200058457600080fd5b6200058f8a6200054f565b98506200059f60208b016200054f565b9750620005af60408b016200054f565b9650620005bf60608b016200054f565b955060808a01519450620005d660a08b016200054f565b60c08b01519094506001600160501b0381168114620005f457600080fd5b60e08b015190935061ffff811681146200060d57600080fd5b809250506101008a015190509295985092959850929598565b60805160a0516156776200067d60003960008181610a6001528181610e2801528181611065015281816110ef01528181611b9901528181611d9d01528181612f4f0152613e560152600061159401526156776000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e1461053f578063de9dfa4614610547578063e3d0e7121461055a578063f2fde38b1461056d57600080fd5b8063b1dc65a41461040d578063c3f909d414610420578063d227d2451461050f57600080fd5b8063aecc12c5116100c8578063aecc12c5146103a5578063af1296d3146103e5578063afcb95d7146103ed57600080fd5b80638cc6acce146103585780638da5cb5b1461036b5780639883c10d1461039357600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ab57806381f1b938146102c057806381ff7048146102c857806385b214cf1461033557600080fd5b806379ba50971461027d5780637f15e16614610285578063807560311461029857600080fd5b8063466557181161018c5780634665571814610226578063533989871461025457806366316d8d1461026a57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004614117565b610580565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a91906141bd565b60405180910390f35b6101c66102213660046141f2565b6105d5565b61023961023436600461434e565b610677565b60405169ffffffffffffffffffff909116815260200161020a565b61025c6106a5565b60405161020a929190614475565b6101c661027836600461451f565b610929565b6101c6610ac5565b6101c6610293366004614117565b610bc7565b6101c66102a6366004614558565b610c17565b6102b3610cce565b60405161020a91906145ad565b6101fd610d3d565b61031260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff94851681529390921660208401529082015260600161020a565b6103486103433660046145c0565b610e0e565b604051901515815260200161020a565b6101c66103663660046145d9565b61104d565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6007545b60405190815260200161020a565b6103b86103b3366004614616565b6110d2565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b61039761132e565b60408051600181526000602082018190529181019190915260600161020a565b6101c661041b366004614696565b611421565b6104ab600954600b54600d54600a5463ffffffff8085169564010000000086048216956c010000000000000000000000008082048416969568010000000000000000830490941694930473ffffffffffffffffffffffffffffffffffffffff16927e0100000000000000000000000000000000000000000000000000000000000090910461ffff1691565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61052261051d36600461474d565b611b52565b6040516bffffffffffffffffffffffff909116815260200161020a565b6101fd611d42565b61052261055536600461434e565b611d99565b6101c661056836600461486f565b611e31565b6101c661057b3660046141f2565b612855565b610588612866565b60008190036105c3576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105d08284836149dd565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061057503373ffffffffffffffffffffffffffffffffffffffff8216145b610646576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f602052604081206106749161405c565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106e2575b505050505090506000815167ffffffffffffffff8111156107305761073061420f565b60405190808252806020026020018201604052801561076357816020015b606081526020019060019003908161074e5790505b50905060005b825181101561091f57600f600084838151811061078857610788614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107d59061493c565b9050600003610810576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061082657610826614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546108739061493c565b80601f016020809104026020016040519081016040528092919081815260200182805461089f9061493c565b80156108ec5780601f106108c1576101008083540402835291602001916108ec565b820191906000526020600020905b8154815290600101906020018083116108cf57829003601f168201915b505050505082828151811061090357610903614af8565b60200260200101819052508061091890614b56565b9050610769565b5090939092509050565b6109316128e9565b806bffffffffffffffffffffffff166000036109675750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109c1576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109ee9084906bffffffffffffffffffffffff16614b8e565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116600483015291841660248201527f00000000000000000000000000000000000000000000000000000000000000009250908216906366316d8d90604401600060405180830381600087803b158015610aa857600080fd5b505af1158015610abc573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b4b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bcf612866565b6000819003610c0a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105d08284836149dd565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c625750610c4133612a80565b8015610c6257503373ffffffffffffffffffffffffffffffffffffffff8416145b610c98576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cc88284836149dd565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d3357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d08575b5050505050905090565b606060108054610d4c9061493c565b9050600003610d87576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610d949061493c565b80601f0160208091040260200160405190810160405280929190818152602001828054610dc09061493c565b8015610d335780601f10610de257610100808354040283529160200191610d33565b820191906000526020600020905b815481529060010190602001808311610df057509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e7f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff1661010084015260030154610120830152610fd35750600092915050565b600083815260086020526040808220828155600181018390556002810180547fff000000000000000000000000000000000000000000000000000000000000001690556003018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146110bc576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110c581612b69565b8051602090910120600755565b60008080803373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611146576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111536040860186614bba565b905060000361118d576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808760600160208101906111ad9190614c1f565b67ffffffffffffffff1681526020908101906111cb908901896141f2565b73ffffffffffffffffffffffffffffffffffffffff1681526020016111f660e0890160c08a01614c3c565b63ffffffff1681523a60209091015290506112626112176040880188614bba565b8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061125c9250505060a0890160808a01614c69565b83612e64565b9297509095509350915061127960208701876141f2565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c326112c260808b0160608c01614c1f565b6112d260408c0160208d016141f2565b6112df60408d018d614bba565b8d60800160208101906112f29190614c69565b8e60a001358f60c001602081019061130a9190614c3c565b60405161131e989796959493929190614c86565b60405180910390a3509193509193565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156113c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113ec9190614d46565b5093505092505082801561140e57506114058142614d96565b8463ffffffff16105b1561141957600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161147791849163ffffffff851691908e908e908190840183828082843760009201919091525061350f92505050565b6114ad576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b42565b6115908b8b8b8b8b8b613518565b60007f0000000000000000000000000000000000000000000000000000000000000000156115ed576002826020015183604001516115ce9190614da9565b6115d89190614df1565b6115e3906001614da9565b60ff169050611603565b60208201516115fd906001614da9565b60ff1690505b88811461166c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b42565b8887146116d5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b42565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561171857611718614e13565b600281111561172957611729614e13565b905250905060028160200151600281111561174657611746614e13565b14801561178d57506006816000015160ff168154811061176857611768614af8565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6117f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b42565b5050505050611800614096565b6000808a8a604051611813929190614e42565b60405190819003812061182a918e90602001614e52565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b3457600060018489846020811061189357611893614af8565b6118a091901a601b614da9565b8e8e868181106118b2576118b2614af8565b905060200201358d8d878181106118cb576118cb614af8565b9050602002013560405160008152602001604052604051611908949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561192a573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119aa576119aa614e13565b60028111156119bb576119bb614e13565b90525092506001836020015160028111156119d8576119d8614e13565b14611a3f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b42565b8251600090879060ff16601f8110611a5957611a59614af8565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611adb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b42565b8086846000015160ff16601f8110611af557611af5614af8565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b20600186614da9565b94505080611b2d90614b56565b9050611874565b505050611b45833383858e8e6135c6565b5050505050505050505050565b6040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8616600482015263ffffffff831660248201526000907f00000000000000000000000000000000000000000000000000000000000000009073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611bf257600080fd5b505afa158015611c06573d6000803e3d6000fd5b50505050620f4240831115611c47576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611cd588888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610677915050565b69ffffffffffffffffffff1690506000611d2689898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611d99915050565b9050611d34878784846138cd565b9a9950505050505050505050565b6060600e8054611d519061493c565b9050600003611d8c576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610d949061493c565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611e06573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e2a9190614e66565b9392505050565b855185518560ff16601f831115611ea4576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b42565b80600003611f0e576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b42565b818314611f9c576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b42565b611fa7816003614e83565b831161200f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b42565b612017612866565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a081018690529061205e9088613a2f565b600554156122135760055460009061207890600190614d96565b905060006005828154811061208f5761208f614af8565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff909216935090849081106120c9576120c9614af8565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061214957612149614e9a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806121b2576121b2614e9a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061205e915050565b60005b81515181101561267a576000600460008460000151848151811061223c5761223c614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561228657612286614e13565b146122ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b42565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061231e5761231e614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156123bf576123bf614e13565b0217905550600091506123cf9050565b60046000846020015184815181106123e9576123e9614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561243357612433614e13565b1461249a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b42565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106124cd576124cd614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561256e5761256e614e13565b02179055505082518051600592508390811061258c5761258c614af8565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061260857612608614af8565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061267281614b56565b915050612216565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161273291849174010000000000000000000000000000000000000000900416614ec9565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127914630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613a4c565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612848988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614ee6565b60405180910390a1611b45565b61285d612866565b61067481613af7565b60005473ffffffffffffffffffffffffffffffffffffffff1633146128e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b42565b565b60006128f3610cce565b90508051600003612930576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d5460009161294f916bffffffffffffffffffffffff16614f6c565b905060005b82518160ff161015612a215781600c6000858460ff168151811061297a5761297a614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129e29190614f97565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612a1a90614fbc565b9050612954565b508151612a2e9082614fdb565b600d8054600090612a4e9084906bffffffffffffffffffffffff16614b8e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612ae657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612abb575b5050505050905060005b8151811015612b5f578373ffffffffffffffffffffffffffffffffffffffff16828281518110612b2257612b22614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612b4f575060019392505050565b612b5881614b56565b9050612af0565b5060009392505050565b600080600080600080600080600089806020019051810190612b8b919061500b565b98509850985098509850985098509850985060008513612bda576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610b42565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a166080860181905269ffffffffffffffffffff8a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d9052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a829055600b869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd7390612e50908b908b908a908c908b908a908a908a9063ffffffff988916815296881660208801529487166040870152929095166060850152608084015269ffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b60095460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612ed3576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612edf8887610677565b90506000612eed8988611d99565b90506000612f11886040015189606001518569ffffffffffffffffffff16856138cd565b88516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612fb2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612ff891908101906150b7565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015613089573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130ad91906151a3565b509150506bffffffffffffffffffffffff85166130ca8385614b8e565b6bffffffffffffffffffffffff161015613110576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061318f308e602001518f6000015185600161312d91906151f5565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff1681526020016009600001600c9054906101000a900463ffffffff16600960000160089054906101000a900463ffffffff1661327b9190614ec9565b63ffffffff1664ffffffffff1681526020018f606001518152509050806008600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd826040516134bf9190615216565b60405180910390a250600954909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613525826020614e83565b613530856020614e83565b61353c8861014461532b565b613546919061532b565b613550919061532b565b61355b90600061532b565b9050368114610abc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b42565b606080806135d6848601866153be565b8251929550909350915015806135ee57508151835114155b806135fb57508051835114155b15613632576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156138c157600061369685838151811061365557613655614af8565b602002602001015185848151811061366f5761366f614af8565b602002602001015185858151811061368957613689614af8565b6020026020010151613bec565b905060008160068111156136ac576136ac614e13565b14806136c9575060018160068111156136c7576136c7614e13565b145b15613724578482815181106136e0576136e0614af8565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a26138b0565b600281600681111561373857613738614e13565b036137885784828151811061374f5761374f614af8565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a26138b0565b600381600681111561379c5761379c614e13565b036137ec578482815181106137b3576137b3614af8565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a26138b0565b600581600681111561380057613800614e13565b036138505784828151811061381757613817614af8565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a26138b0565b600481600681111561386457613864614e13565b036138b05784828151811061387b5761387b614af8565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b506138ba81614b56565b9050613635565b50505050505050505050565b6000806138d861132e565b905060008113613917576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b42565b600954600090879061394d9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614ec9565b6139579190614ec9565b63ffffffff1690506000612710600960010154886139759190614e83565b61397f919061549b565b613989908861532b565b9050600083836139a184670de0b6b3a7640000614e83565b6139ab9190614e83565b6139b5919061549b565b905060006139d46bffffffffffffffffffffffff808916908a1661532b565b90506139ec816b033b2e3c9fd0803ce8000000614d96565b821115613a25576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611d34818361532b565b6000613a39610cce565b511115613a4857613a486128e9565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613a70999897969594939291906154af565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613b76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b42565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600860209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613d41576002915050611e2a565b6000858152600860205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613d9161132e565b905060008113613dd0576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b42565b600081613de53a670de0b6b3a7640000614e83565b613def919061549b565b9050600083610100015164ffffffffff1682613e0b9190614e83565b905060008460c0015169ffffffffffffffffffff1682613e2b9190614f97565b6040517f3fd67e050000000000000000000000000000000000000000000000000000000081529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff841690633fd67e0590613eb1908f908f908f908c908b903390600401615544565b60408051808303816000875af1158015613ecf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ef391906155b5565b9092509050613f028186614f97565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600d805469ffffffffffffffffffff90921693909291613f6f91859116614f97565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c001518489613fd59190614f97565b60808d015160c08e015169ffffffffffffffffffff16613ff5888d614f97565b613fff9190614f97565b6140099190614f97565b8760ff16600681111561401e5761401e614e13565b60405161402f9594939291906155e4565b60405180910390a28160ff16600681111561404c5761404c614e13565b9c9b505050505050505050505050565b5080546140689061493c565b6000825580601f10614078575050565b601f01602090049060005260206000209081019061067491906140b5565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156140ca57600081556001016140b6565b5090565b60008083601f8401126140e057600080fd5b50813567ffffffffffffffff8111156140f857600080fd5b60208301915083602082850101111561411057600080fd5b9250929050565b6000806020838503121561412a57600080fd5b823567ffffffffffffffff81111561414157600080fd5b61414d858286016140ce565b90969095509350505050565b6000815180845260005b8181101561417f57602081850181015186830182015201614163565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611e2a6020830184614159565b73ffffffffffffffffffffffffffffffffffffffff8116811461067457600080fd5b60006020828403121561420457600080fd5b8135611e2a816141d0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156142855761428561420f565b604052919050565b600082601f83011261429e57600080fd5b813567ffffffffffffffff8111156142b8576142b861420f565b6142e960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161423e565b8181528460208386010111156142fe57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067457600080fd5b80356110488161431b565b63ffffffff8116811461067457600080fd5b60008082840360a081121561436257600080fd5b833567ffffffffffffffff8082111561437a57600080fd5b6143868783880161428d565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156143b857600080fd5b604051925060808301915082821081831117156143d7576143d761420f565b5060405260208401356143e98161431b565b815260408401356143f9816141d0565b6020820152606084013561440c8161433c565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561446a57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614438565b509495945050505050565b6040815260006144886040830185614424565b6020838203818501528185518084528284019150828160051b85010183880160005b838110156144f6577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526144e4838351614159565b948601949250908501906001016144aa565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461067457600080fd5b6000806040838503121561453257600080fd5b823561453d816141d0565b9150602083013561454d81614505565b809150509250929050565b60008060006040848603121561456d57600080fd5b8335614578816141d0565b9250602084013567ffffffffffffffff81111561459457600080fd5b6145a0868287016140ce565b9497909650939450505050565b602081526000611e2a6020830184614424565b6000602082840312156145d257600080fd5b5035919050565b6000602082840312156145eb57600080fd5b813567ffffffffffffffff81111561460257600080fd5b61460e8482850161428d565b949350505050565b60006020828403121561462857600080fd5b813567ffffffffffffffff81111561463f57600080fd5b820160e08185031215611e2a57600080fd5b60008083601f84011261466357600080fd5b50813567ffffffffffffffff81111561467b57600080fd5b6020830191508360208260051b850101111561411057600080fd5b60008060008060008060008060e0898b0312156146b257600080fd5b606089018a8111156146c357600080fd5b8998503567ffffffffffffffff808211156146dd57600080fd5b6146e98c838d016140ce565b909950975060808b013591508082111561470257600080fd5b61470e8c838d01614651565b909750955060a08b013591508082111561472757600080fd5b506147348b828c01614651565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561476557600080fd5b85356147708161431b565b9450602086013567ffffffffffffffff81111561478c57600080fd5b614798888289016140ce565b90955093505060408601356147ac8161433c565b949793965091946060013592915050565b600067ffffffffffffffff8211156147d7576147d761420f565b5060051b60200190565b600082601f8301126147f257600080fd5b81356020614807614802836147bd565b61423e565b82815260059290921b8401810191818101908684111561482657600080fd5b8286015b8481101561484a57803561483d816141d0565b835291830191830161482a565b509695505050505050565b60ff8116811461067457600080fd5b803561104881614855565b60008060008060008060c0878903121561488857600080fd5b863567ffffffffffffffff808211156148a057600080fd5b6148ac8a838b016147e1565b975060208901359150808211156148c257600080fd5b6148ce8a838b016147e1565b96506148dc60408a01614864565b955060608901359150808211156148f257600080fd5b6148fe8a838b0161428d565b945061490c60808a01614331565b935060a089013591508082111561492257600080fd5b5061492f89828a0161428d565b9150509295509295509295565b600181811c9082168061495057607f821691505b602082108103614989577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105d057600081815260208120601f850160051c810160208610156149b65750805b601f850160051c820191505b818110156149d5578281556001016149c2565b505050505050565b67ffffffffffffffff8311156149f5576149f561420f565b614a0983614a03835461493c565b8361498f565b6000601f841160018114614a5b5760008515614a255750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614af1565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b82811015614aaa5786850135825560209485019460019092019101614a8a565b5086821015614ae5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614b8757614b87614b27565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614bb357614bb3614b27565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614bef57600080fd5b83018035915067ffffffffffffffff821115614c0a57600080fd5b60200191503681900382131561411057600080fd5b600060208284031215614c3157600080fd5b8135611e2a8161431b565b600060208284031215614c4e57600080fd5b8135611e2a8161433c565b61ffff8116811461067457600080fd5b600060208284031215614c7b57600080fd5b8135611e2a81614c59565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461104857600080fd5b600080600080600060a08688031215614d5e57600080fd5b614d6786614d2c565b9450602086015193506040860151925060608601519150614d8a60808701614d2c565b90509295509295909350565b8181038181111561069f5761069f614b27565b60ff818116838216019081111561069f5761069f614b27565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614e0457614e04614dc2565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614e7857600080fd5b8151611e2a81614505565b808202811582820484141761069f5761069f614b27565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614bb357614bb3614b27565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614f168184018a614424565b90508281036080840152614f2a8189614424565b905060ff871660a084015282810360c0840152614f478187614159565b905067ffffffffffffffff851660e084015282810361010084015261404c8185614159565b60006bffffffffffffffffffffffff80841680614f8b57614f8b614dc2565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614bb357614bb3614b27565b600060ff821660ff8103614fd257614fd2614b27565b60010192915050565b6bffffffffffffffffffffffff81811683821602808216919082811461500357615003614b27565b505092915050565b60008060008060008060008060006101208a8c03121561502a57600080fd5b89516150358161433c565b60208b01519099506150468161433c565b60408b01519098506150578161433c565b60608b01519097506150688161433c565b60808b015160a08c015191975095506150808161433c565b935061508e60c08b01614d2c565b925060e08a015161509e81614c59565b809250506101008a015190509295985092959850929598565b600080600080600060a086880312156150cf57600080fd5b85516150da81614505565b809550506020808701516150ed81614505565b60408801519095506150fe816141d0565b606088015190945061510f816141d0565b608088015190935067ffffffffffffffff81111561512c57600080fd5b8701601f8101891361513d57600080fd5b805161514b614802826147bd565b81815260059190911b8201830190838101908b83111561516a57600080fd5b928401925b82841015615191578351615182816141d0565b8252928401929084019061516f565b80955050505050509295509295909350565b6000806000606084860312156151b857600080fd5b835180151581146151c857600080fd5b60208501519093506151d98161431b565b60408501519092506151ea8161431b565b809150509250925092565b67ffffffffffffffff818116838216019080821115614bb357614bb3614b27565b815167ffffffffffffffff16815261014081016020830151615250602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615268604084018263ffffffff169052565b506060830151615290606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516152b060808401826bffffffffffffffffffffffff169052565b5060a08301516152d060a08401826bffffffffffffffffffffffff169052565b5060c08301516152ee60c084018269ffffffffffffffffffff169052565b5060e083015161530660e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b8082018082111561069f5761069f614b27565b600082601f83011261534f57600080fd5b8135602061535f614802836147bd565b82815260059290921b8401810191818101908684111561537e57600080fd5b8286015b8481101561484a57803567ffffffffffffffff8111156153a25760008081fd5b6153b08986838b010161428d565b845250918301918301615382565b6000806000606084860312156153d357600080fd5b833567ffffffffffffffff808211156153eb57600080fd5b818601915086601f8301126153ff57600080fd5b8135602061540f614802836147bd565b82815260059290921b8401810191818101908a84111561542e57600080fd5b948201945b8386101561544c57853582529482019490820190615433565b9750508701359250508082111561546257600080fd5b61546e8783880161533e565b9350604086013591508082111561548457600080fd5b506154918682870161533e565b9150509250925092565b6000826154aa576154aa614dc2565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526154f68285018b614424565b9150838203608085015261550a828a614424565b915060ff881660a085015283820360c08501526155278288614159565b90861660e0850152838103610100850152905061404c8185614159565b86815260c06020820152600061555d60c0830188614159565b828103604084015261556f8188614159565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156155c857600080fd5b82516155d381614855565b602084015190925061454d81614505565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a081016007831061565a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 0e9b25d74ca..1edf8bddce7 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -31,8 +31,8 @@ var ( ) var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200621f3803806200621f833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615b3c80620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102f45760003560e01c80637341c10c11610191578063aab396bd116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610771578063eb523d6c14610784578063f2fde38b1461079757600080fd5b8063c4614d6114610738578063d7ae1d301461074b578063e72f6e301461075e57600080fd5b8063b5643858116100c8578063b564385814610706578063b734c0f414610719578063badc3eb61461072157600080fd5b8063aab396bd146106d5578063b187bd26146106fb57600080fd5b80639883c10d11610145578063a47c76961161011f578063a47c76961461068b578063a4c0ed36146106af578063a9c9a918146106c257600080fd5b80639883c10d146106685780639f87fad714610670578063a21a23e41461068357600080fd5b80638235974011610176578063823597401461062a5780638da5cb5b1461063d5780638fde53171461066057600080fd5b80637341c10c1461060f57806379ba50971461062257600080fd5b80633fd67e051161024a57806366316d8d116101fe578063674603d0116101d8578063674603d01461053b5780636a6df79b146105d057806371ec28ac1461060857600080fd5b806366316d8d146104e157806366419970146104f4578063665871ec1461052857600080fd5b806354fd4d501161022f57806354fd4d501461048b57806355fedefa146104b75780635c975abb146104ca57600080fd5b80633fd67e0514610431578063461d27621461046a57600080fd5b8063181f5a77116102ac57806336566f061161028657806336566f0614610403578063385de9ae1461040b5780633e871e4d1461041e57600080fd5b8063181f5a77146103985780631ded3b36146103da5780632a905ccc146103ed57600080fd5b80630c5d49cb116102dd5780630c5d49cb1461032157806310fc49c11461034157806312b583491461035457600080fd5b806302bcc5b6146102f957806304c357cb1461030e575b600080fd5b61030c610307366004614a9e565b6107aa565b005b61030c61031c366004614add565b610837565b610329608481565b60405161ffff90911681526020015b60405180910390f35b61030c61034f366004614b22565b61093c565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610338565b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103389190614bbd565b61030c6103e8366004614bd0565b610946565b600f546bffffffffffffffffffffffff1661037b565b61030c610977565b61030c610419366004614c43565b61099c565b61030c61042c366004614da3565b610b84565b61044461043f366004614f04565b610e9e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610338565b61047d610478366004614fb8565b61122f565b604051908152602001610338565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610338565b61047d6104c5366004614a9e565b61128b565b60005460ff165b6040519015158152602001610338565b61030c6104ef36600461503a565b6112af565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610338565b61030c610536366004615066565b6114de565b6105a86105493660046150db565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610338565b6105e36105de366004615113565b6118ab565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610338565b6064610329565b61030c61061d366004614add565b6118be565b61030c611a73565b61030c610638366004614a9e565b611b95565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105e3565b61030c611cec565b60075461047d565b61030c61067e366004614add565b611d9b565b61050f6121ab565b61069e610699366004614a9e565b61234c565b604051610338959493929190615189565b61030c6106bd3660046151de565b612438565b6105e36106d0366004615238565b61266f565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761047d565b60005460ff166104d1565b61030c610714366004615251565b61267c565b61030c6127db565b6107296129ef565b6040516103389392919061526c565b6103cd610746366004614c43565b612aca565b61030c610759366004614add565b612adf565b61030c61076c3660046152cd565b612b40565b6104d161077f366004614a9e565b612d52565b61030c610792366004615238565b612d5d565b61030c6107a53660046152cd565b612fcd565b6107b2612fde565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680610829576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108338282612fe6565b5050565b61083f61335c565b61084882613364565b61085061342a565b610858613473565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108335767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b6108338282613568565b61094e612fde565b61095782613688565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61097f6136fe565b60005460ff161561099457610992613784565b565b610992613801565b6109a46136fe565b60006109b184600061385c565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109db5750600754610a4f565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a28573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a4c91906152e8565b90505b8383604051610a5f929190615301565b60405180910390208103610a9f576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610b0a906601000000000000900461ffff1643615340565b9052600086815260066020908152604090912082518155908201516001820190610b3490826153f4565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b7590879084908890889061550e565b60405180910390a15050505050565b610b8c6136fe565b8151815181141580610b9e5750600881115b15610bd5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610d0f576000848260ff1681518110610bfa57610bfa615569565b602002602001015190506000848360ff1681518110610c1b57610c1b615569565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c86575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cbd576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cfc576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610d0890615598565b9050610bd8565b50600954600090610d2e906601000000000000900461ffff1643615340565b604080516060810182528681526020808201879052918101839052865192935091600391610d609183918901906148e7565b506020828101518051610d79926001850192019061492e565b506040820151816002015590505060005b84518160ff161015610e97577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610dcc57610dcc615569565b602002602001015160026000888560ff1681518110610ded57610ded615569565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e3957610e39615569565b602002602001015185604051610e7f949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e9081615598565b9050610d8a565b5050505050565b600080610ea961395c565b610eb161342a565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314610ff3576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff1661101c576002925050611224565b8060e00151816080015163ffffffff1661103691906155b7565b6effffffffffffffffffffffffffffff165a1015611058576003925050611224565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff9091169061109b9063ffffffff166139c9565b6110a590886155e6565b82516110b2908890615616565b6110bc9190615616565b6bffffffffffffffffffffffff1611156110da576004925050611224565b8060a001516bffffffffffffffffffffffff16611100826080015163ffffffff166139c9565b61110a90886155e6565b8251611117908890615616565b6111219190615616565b6bffffffffffffffffffffffff16111561113f576005925050611224565b6000898152600e602052604080822082815560018101839055600201829055608083015190830151919450849161117b918c918c918c91613a6b565b805190915061118b57600161118e565b60005b935060006111b583606001518460a00151856040015186600001518c87602001518d613c3f565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a8360200151898987600001516111fe578e611200565b8f5b886040015160405161121695949392919061563b565b60405180910390a351925050505b965096945050505050565b600061123961342a565b6112808260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613e919050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b6112b761335c565b6112bf61342a565b806bffffffffffffffffffffffff16600003611307576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611361576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061138e9084906bffffffffffffffffffffffff16615699565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113e59190615699565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611484573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a891906156be565b610833576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6114e661335c565b6114ee61342a565b60005b818110156118a657600083838381811061150d5761150d615569565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e082015290935091905061163081613688565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163381146116a9576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156116ee576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611760573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061178491906156be565b156118905760a084015167ffffffffffffffff84166000908152600b6020526040812060010180549091906117c89084906bffffffffffffffffffffffff16615699565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff80881684529152919020805460019260099161184f91859169010000000000000000009004166156db565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b50505050508061189f906156fc565b90506114f1565b505050565b60006118b7838361385c565b9392505050565b6118c661335c565b6118cf82613364565b6118d761342a565b6118df613473565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611954576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff161561199b575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610930565b60015473ffffffffffffffffffffffffffffffffffffffff163314611af4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610cf3565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b9d61335c565b611ba561342a565b611bad613473565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611c4d576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610cf3565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611cf46136fe565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611d56576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b611da361335c565b611dac82613364565b611db461342a565b611dbc613473565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e8c576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cf3565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ee1576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f5c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f31575b50505050509050600060018251611f739190615734565b905060005b825181101561210f578473ffffffffffffffffffffffffffffffffffffffff16838281518110611faa57611faa615569565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120ff576000838381518110611fe157611fe1615569565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600201838154811061202757612027615569565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b909152604090206002018054806120a1576120a1615747565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061210f565b612108816156fc565b9050611f78565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60006121b561335c565b6121bd61342a565b6121c5613473565b6009805481906121eb906901000000000000000000900467ffffffffffffffff16615776565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612261578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926122fc9260028501929091019061492e565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061235d86613688565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561242857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116123fd575b5050505050905091939590929450565b61244061335c565b61244861342a565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612499576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146124d3576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006124e182840184614a9e565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661255a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906125918385615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff166125e89190615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461264f9190615340565b6040805192835260208301919091520160405180910390a2505050505050565b60006112a982600061385c565b6126846136fe565b60095461ffff808316660100000000000090920416036126d0576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff6401000000009091048116908216111561271c576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff66010000000000009091048116808352908416602083015290918201906127539043615340565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b6127e36136fe565b60055443101561281f576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6009546128319061ffff16600161579d565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff9283161790819055620100009004161561289757600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff821610156129ec57600060036000018260ff16815481106128c2576128c2615569565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff861690811061291157612911615569565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a1505050806129e590615598565b905061289a565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612a4f57602002820191906000526020600020905b815481526020019060010190808311612a3b575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612ab857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a8d575b50505050509050925092509250909192565b6060612ad78484846142f2565b949350505050565b612ae761335c565b612af082613364565b612af861342a565b612b00613473565b612b09826143bf565b15610829576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612b48612fde565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612bb7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612bdb91906152e8565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612c48576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610cf3565b818110156118a6576000612c5c8284615734565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612cd7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cfb91906156be565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112a9826143bf565b612d656136fe565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612d9f90615353565b80601f0160208091040260200160405190810160405280929190818152602001828054612dcb90615353565b8015612e185780601f10612ded57610100808354040283529160200191612e18565b820191906000526020600020905b815481529060010190602001808311612dfb57829003601f168201915b5050505050815260200160028201548152505090508060400151431015612e6b576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612e9057612e7d816020015161450e565b6020808201518051910120600755612f38565b612e9b82600061385c565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612ed79190614bbd565b600060405180830381600087803b158015612ef157600080fd5b505af1925050508015612f02575060015b612f38576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612f509062010000900461ffff16600161579d565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f4792612fc19286926157b8565b60405180910390a15050565b612fd56136fe565b6129ec81614609565b6109926136fe565b612fee61342a565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156130cf57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116130a4575b505050918352505060039190910154602090910152805190915060005b82608001515181101561319057600c60008460800151838151811061311357613113615569565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613189816156fc565b90506130ec565b5067ffffffffffffffff84166000908152600b6020526040812081815560018101829055906131c260028301826149a8565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff166131f59190615699565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613294573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132b891906156be565b6132ee576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b61099261395c565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16806133db576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610833576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095468010000000000000000900460ff1615610992576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61349e7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097600061385c565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561350c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061353091906156be565b610992576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610cf3565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a9081106135c8576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610cf3565b6010805460ff83169081106135df576135df615569565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff1611156118a6576010805460ff831690811061362f5761362f615569565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610cf3565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166129ec576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610992576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610cf3565b61378c614704565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b61380961395c565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137d73390565b60008161389b5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1680156138955790506112a9565b50613927565b60005b60035460ff82161015613925576003805460ff83169081106138c2576138c2615569565b90600052602060002001548403613915576004805460ff83169081106138ea576138ea615569565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112a99050565b61391e81615598565b905061389e565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610cf3565b60005460ff1615610992576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610cf3565b60006bffffffffffffffffffffffff821115613a67576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610cf3565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613ab6908990899089906024016157e0565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff16680100000000000000001790558051608480825260c0820190925291935060009283928392909182018180368337019050509050853b613b9a57600080fd5b5a611388811015613baa57600080fd5b611388810390508760408204820311613bc257600080fd5b60008086516020880160008b8df193505a900391503d6084811115613be5575060845b808252806000602084013e50600980547fffffffffffffffffffffffffffffffffffffffffffffff00ffffffffffffffff169055604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613c5e846139c9565b613c6890866155e6565b9050600081613c778886615616565b613c819190615616565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613cd891859116615699565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613d129190615616565b336000908152600d602052604081208054909190613d3f9084906bffffffffffffffffffffffff16615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613d8691859116615616565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613dda91859116615699565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613e5e91859169010000000000000000009004166156db565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613e9b61395c565b613ea485613688565b613eae3386614770565b613eb88583613568565b6000613ec4888861385c565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c591613f8f91600401615815565b6080604051808303816000875af1158015613fae573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613fd291906158a8565b92975090945092509050613fe7338a8561480c565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c0810161405d8342615340565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516142dc969594939291906158e6565b60405180910390a4505050509695505050505050565b606060008080806143058688018861594a565b9350935093509350600061431e89600187878787613e91565b60408051602080825281830190925291925060208201818036833701905050955060005b60208110156143b25781816020811061435d5761435d615569565b1a60f81b87828151811061437357614373615569565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506143ab816156fc565b9050614342565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561443757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161440c575b5050505050905060005b8151811015614504576000600c600084848151811061446257614462615569565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146144f357506001949350505050565b506144fd816156fc565b9050614441565b5060009392505050565b60008060008380602001905181019061452791906159bb565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926145d291601091908601906149c6565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612d4493929190615aa4565b3373ffffffffffffffffffffffffffffffffffffffff821603614688576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610cf3565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610992576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610cf3565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610833576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610cf3565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906148469084906bffffffffffffffffffffffff16615616565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926148bc9284929004166156db565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614922579160200282015b82811115614922578251825591602001919060010190614907565b50613a67929150614a6c565b828054828255906000526020600020908101928215614922579160200282015b8281111561492257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061494e565b50805460008255906000526020600020908101906129ec9190614a6c565b828054828255906000526020600020906007016008900481019282156149225791602002820160005b83821115614a3357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026149ef565b8015614a635782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a33565b5050613a679291505b5b80821115613a675760008155600101614a6d565b803567ffffffffffffffff81168114614a9957600080fd5b919050565b600060208284031215614ab057600080fd5b6118b782614a81565b803573ffffffffffffffffffffffffffffffffffffffff81168114614a9957600080fd5b60008060408385031215614af057600080fd5b614af983614a81565b9150614b0760208401614ab9565b90509250929050565b63ffffffff811681146129ec57600080fd5b60008060408385031215614b3557600080fd5b614b3e83614a81565b91506020830135614b4e81614b10565b809150509250929050565b6000815180845260005b81811015614b7f57602081850181015186830182015201614b63565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006118b76020830184614b59565b60008060408385031215614be357600080fd5b614bec83614a81565b946020939093013593505050565b60008083601f840112614c0c57600080fd5b50813567ffffffffffffffff811115614c2457600080fd5b602083019150836020828501011115614c3c57600080fd5b9250929050565b600080600060408486031215614c5857600080fd5b83359250602084013567ffffffffffffffff811115614c7657600080fd5b614c8286828701614bfa565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d0557614d05614c8f565b604052919050565b600067ffffffffffffffff821115614d2757614d27614c8f565b5060051b60200190565b600082601f830112614d4257600080fd5b81356020614d57614d5283614d0d565b614cbe565b82815260059290921b84018101918181019086841115614d7657600080fd5b8286015b84811015614d9857614d8b81614ab9565b8352918301918301614d7a565b509695505050505050565b60008060408385031215614db657600080fd5b823567ffffffffffffffff80821115614dce57600080fd5b818501915085601f830112614de257600080fd5b81356020614df2614d5283614d0d565b82815260059290921b84018101918181019089841115614e1157600080fd5b948201945b83861015614e2f57853582529482019490820190614e16565b96505086013592505080821115614e4557600080fd5b50614e5285828601614d31565b9150509250929050565b600082601f830112614e6d57600080fd5b813567ffffffffffffffff811115614e8757614e87614c8f565b614eb860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cbe565b818152846020838601011115614ecd57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff811681146129ec57600080fd5b60008060008060008060c08789031215614f1d57600080fd5b86359550602087013567ffffffffffffffff80821115614f3c57600080fd5b614f488a838b01614e5c565b96506040890135915080821115614f5e57600080fd5b50614f6b89828a01614e5c565b9450506060870135614f7c81614eea565b92506080870135614f8c81614eea565b9150614f9a60a08801614ab9565b90509295509295509295565b803561ffff81168114614a9957600080fd5b60008060008060008060a08789031215614fd157600080fd5b614fda87614a81565b9550602087013567ffffffffffffffff811115614ff657600080fd5b61500289828a01614bfa565b9096509450615015905060408801614fa6565b9250606087013561502581614b10565b80925050608087013590509295509295509295565b6000806040838503121561504d57600080fd5b61505683614ab9565b91506020830135614b4e81614eea565b6000806020838503121561507957600080fd5b823567ffffffffffffffff8082111561509157600080fd5b818501915085601f8301126150a557600080fd5b8135818111156150b457600080fd5b8660208260051b85010111156150c957600080fd5b60209290920196919550909350505050565b600080604083850312156150ee57600080fd5b6150f783614ab9565b9150614b0760208401614a81565b80151581146129ec57600080fd5b6000806040838503121561512657600080fd5b823591506020830135614b4e81615105565b600081518084526020808501945080840160005b8381101561517e57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161514c565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061128090830184615138565b600080600080606085870312156151f457600080fd5b6151fd85614ab9565b935060208501359250604085013567ffffffffffffffff81111561522057600080fd5b61522c87828801614bfa565b95989497509550505050565b60006020828403121561524a57600080fd5b5035919050565b60006020828403121561526357600080fd5b6118b782614fa6565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156152ad57845183529383019391830191600101615291565b505084810360408601526152c18187615138565b98975050505050505050565b6000602082840312156152df57600080fd5b6118b782614ab9565b6000602082840312156152fa57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112a9576112a9615311565b600181811c9082168061536757607f821691505b6020821081036153a0577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156118a657600081815260208120601f850160051c810160208610156153cd5750805b601f850160051c820191505b818110156153ec578281556001016153d9565b505050505050565b815167ffffffffffffffff81111561540e5761540e614c8f565b6154228161541c8454615353565b846153a6565b602080601f831160018114615475576000841561543f5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556153ec565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156154c2578886015182559484019460019091019084016154a3565b50858210156154fe57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036155ae576155ae615311565b60010192915050565b6effffffffffffffffffffffffffffff8181168382160190808211156155df576155df615311565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461560e5761560e615311565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156155df576155df615311565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061568760a0830185614b59565b82810360808401526152c18185614b59565b6bffffffffffffffffffffffff8281168282160390808211156155df576155df615311565b6000602082840312156156d057600080fd5b81516118b781615105565b67ffffffffffffffff8181168382160190808211156155df576155df615311565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361572d5761572d615311565b5060010190565b818103818111156112a9576112a9615311565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361579357615793615311565b6001019392505050565b61ffff8181168382160190808211156155df576155df615311565b8381528260208201526060604082015260006157d76060830184614b59565b95945050505050565b8381526060602082015260006157f96060830185614b59565b828103604084015261580b8185614b59565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e06060840152615860610100840182614b59565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b600080600080608085870312156158be57600080fd5b8451935060208501516158d081614eea565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261592760c0830186614b59565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b6000806000806080858703121561596057600080fd5b61596985614a81565b9350602085013567ffffffffffffffff81111561598557600080fd5b61599187828801614e5c565b9350506159a060408601614fa6565b915060608501356159b081614b10565b939692955090935050565b6000806000606084860312156159d057600080fd5b83516159db81614eea565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615a1357600080fd5b604086015190935067ffffffffffffffff811115615a3057600080fd5b8501601f81018713615a4157600080fd5b8051615a4f614d5282614d0d565b81815260059190911b82018301908381019089831115615a6e57600080fd5b928401925b82841015615a95578351615a8681614b10565b82529284019290840190615a73565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615b2157845163ffffffff1683529383019391830191600101615aff565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200641638038062006416833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615d3380620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806371ec28ac1161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d41461078f578063eb523d6c146107a2578063f2fde38b146107b557600080fd5b8063c4614d6114610756578063d7ae1d3014610769578063e72f6e301461077c57600080fd5b8063b5643858116100c8578063b564385814610724578063b734c0f414610737578063badc3eb61461073f57600080fd5b8063a9c9a918146106e0578063aab396bd146106f3578063b187bd261461071957600080fd5b80638fde531711610150578063a21a23e41161012a578063a21a23e4146106a1578063a47c7696146106a9578063a4c0ed36146106cd57600080fd5b80638fde53171461067e5780639883c10d146106865780639f87fad71461068e57600080fd5b806379ba50971161018157806379ba50971461064057806382359740146106485780638da5cb5b1461065b57600080fd5b806371ec28ac146106265780637341c10c1461062d57600080fd5b80633fd67e05116102555780635ed6dfba11610209578063665871ec116101e3578063665871ec14610546578063674603d0146105595780636a6df79b146105ee57600080fd5b80635ed6dfba146104ec57806366316d8d146104ff578063664199701461051257600080fd5b806354fd4d501161023a57806354fd4d501461049657806355fedefa146104c25780635c975abb146104d557600080fd5b80633fd67e051461043c578063461d27621461047557600080fd5b8063181f5a77116102b757806336566f061161029157806336566f061461040e578063385de9ae146104165780633e871e4d1461042957600080fd5b8063181f5a77146103a35780631ded3b36146103e55780632a905ccc146103f857600080fd5b80630c5d49cb116102e85780630c5d49cb1461032c57806310fc49c11461034c57806312b583491461035f57600080fd5b806302bcc5b61461030457806304c357cb14610319575b600080fd5b610317610312366004614c95565b6107c8565b005b610317610327366004614cd4565b610855565b610334608481565b60405161ffff90911681526020015b60405180910390f35b61031761035a366004614d19565b610952565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610343565b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103439190614db4565b6103176103f3366004614dc7565b61095c565b600f546bffffffffffffffffffffffff16610386565b61031761098d565b610317610424366004614e3a565b6109b2565b610317610437366004614f9a565b610b9a565b61044f61044a3660046150fb565b610eb4565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610343565b6104886104833660046151af565b61123d565b604051908152602001610343565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610343565b6104886104d0366004614c95565b611291565b60005460ff165b6040519015158152602001610343565b6103176104fa366004615231565b6112b5565b61031761050d366004615231565b611591565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610343565b61031761055436600461525d565b6117b8565b6105c66105673660046152d2565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610343565b6106016105fc36600461530a565b611b7d565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610343565b6064610334565b61031761063b366004614cd4565b611b90565b610317611d3d565b610317610656366004614c95565b611e5f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610601565b610317611fae565b600754610488565b61031761069c366004614cd4565b61205d565b61052d612465565b6106bc6106b7366004614c95565b6125fe565b604051610343959493929190615380565b6103176106db3660046153d5565b6126ea565b6106016106ee36600461542f565b612919565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610488565b60005460ff166104dc565b610317610732366004615448565b612926565b610317612a85565b610747612c99565b60405161034393929190615463565b6103d8610764366004614e3a565b612d74565b610317610777366004614cd4565b612d89565b61031761078a3660046154c4565b612de2565b6104dc61079d366004614c95565b612ff4565b6103176107b036600461542f565b612fff565b6103176107c33660046154c4565b61326f565b6107d0613280565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680610847576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108518282613288565b5050565b61085d6135f6565b610866826135fe565b61086e6136c4565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108515767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61085182826137b9565b610964613280565b61096d826138d9565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61099561394f565b60005460ff16156109aa576109a86139d5565b565b6109a8613a52565b6109ba61394f565b60006109c7846000613aad565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109f15750600754610a65565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a3e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a6291906154df565b90505b8383604051610a759291906154f8565b60405180910390208103610ab5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610b20906601000000000000900461ffff1643615537565b9052600086815260066020908152604090912082518155908201516001820190610b4a90826155eb565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b8b908790849088908890615705565b60405180910390a15050505050565b610ba261394f565b8151815181141580610bb45750600881115b15610beb576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610d25576000848260ff1681518110610c1057610c10615760565b602002602001015190506000848360ff1681518110610c3157610c31615760565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c9c575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cd3576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610d12576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610d1e9061578f565b9050610bee565b50600954600090610d44906601000000000000900461ffff1643615537565b604080516060810182528681526020808201879052918101839052865192935091600391610d76918391890190614ade565b506020828101518051610d8f9260018501920190614b25565b506040820151816002015590505060005b84518160ff161015610ead577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610de257610de2615760565b602002602001015160026000888560ff1681518110610e0357610e03615760565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e4f57610e4f615760565b602002602001015185604051610e95949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610ea68161578f565b9050610da0565b5050505050565b600080610ebf6135f6565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314611001576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff1661102a576002925050611232565b8060e00151816080015163ffffffff1661104491906157ae565b6effffffffffffffffffffffffffffff165a1015611066576003925050611232565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff909116906110a99063ffffffff16613bad565b6110b390886157dd565b82516110c090889061580d565b6110ca919061580d565b6bffffffffffffffffffffffff1611156110e8576004925050611232565b8060a001516bffffffffffffffffffffffff1661110e826080015163ffffffff16613bad565b61111890886157dd565b825161112590889061580d565b61112f919061580d565b6bffffffffffffffffffffffff16111561114d576005925050611232565b6000898152600e6020526040808220828155600181018390556002018290556080830151908301519194508491611189918c918c918c91613c4f565b805190915061119957600161119c565b60005b935060006111c383606001518460a00151856040015186600001518c87602001518d613dc9565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a83602001518989876000015161120c578e61120e565b8f5b8860400151604051611224959493929190615832565b60405180910390a351925050505b965096945050505050565b60006112868260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915061401b9050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b6112bd613280565b806bffffffffffffffffffffffff166000036112f35750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561134d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d60205260408120805483929061137a9084906bffffffffffffffffffffffff16615890565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113d19190615890565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611470573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061149491906158b5565b61085157600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611507573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061152b91906154df565b6009546040517fa99da302000000000000000000000000000000000000000000000000000000008152710100000000000000000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610d09565b6115996135f6565b806bffffffffffffffffffffffff166000036115e1576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561163b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906116689084906bffffffffffffffffffffffff16615890565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166116bf9190615890565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561175e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061178291906158b5565b610851576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117c06135f6565b60005b81811015611b785760008383838181106117df576117df615760565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e0820152909350919050611902816138d9565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633811461197b576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156119c0576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611a32573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a5691906158b5565b15611b625760a084015167ffffffffffffffff84166000908152600b602052604081206001018054909190611a9a9084906bffffffffffffffffffffffff16615890565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff808816845291529190208054600192600991611b2191859169010000000000000000009004166158d2565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b505050505080611b71906158f3565b90506117c3565b505050565b6000611b898383613aad565b9392505050565b611b986135f6565b611ba1826135fe565b611ba96136c4565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611c1e576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611c65575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610946565b60015473ffffffffffffffffffffffffffffffffffffffff163314611dbe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610d09565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611e676135f6565b611e6f6136c4565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611f0f576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610d09565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611fb661394f565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015612018576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b6120656135f6565b61206e826135fe565b6120766136c4565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152612146576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b806040015167ffffffffffffffff16816020015167ffffffffffffffff161461219b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b602090815260408083206002018054825181850281018501909352808352919290919083018282801561221657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116121eb575b5050505050905060006001825161222d919061592b565b905060005b82518110156123c9578473ffffffffffffffffffffffffffffffffffffffff1683828151811061226457612264615760565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036123b957600083838151811061229b5761229b615760565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106122e1576122e1615760565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061235b5761235b61593e565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506123c9565b6123c2816158f3565b9050612232565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b600061246f6135f6565b6124776136c4565b60098054819061249d906901000000000000000000900467ffffffffffffffff1661596d565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612513578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926125ae92600285019290910190614b25565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061260f866138d9565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126da57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116126af575b5050505050905091939590929450565b6126f26135f6565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612743576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461277d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061278b82840184614c95565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff169186919061283b838561580d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff16612892919061580d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128f99190615537565b6040805192835260208301919091520160405180910390a2505050505050565b60006112af826000613aad565b61292e61394f565b60095461ffff8083166601000000000000909204160361297a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff640100000000909104811690821611156129c6576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff66010000000000009091048116808352908416602083015290918201906129fd9043615537565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a8d61394f565b600554431015612ac9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612adb9061ffff166001615994565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff92831617908190556201000090041615612b4157600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff82161015612c9657600060036000018260ff1681548110612b6c57612b6c615760565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff8616908110612bbb57612bbb615760565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a150505080612c8f9061578f565b9050612b44565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612cf957602002820191906000526020600020905b815481526020019060010190808311612ce5575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612d6257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d37575b50505050509050925092509250909192565b6060612d8184848461447c565b949350505050565b612d916135f6565b612d9a826135fe565b612da26136c4565b612dab82614549565b15610847576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612dea613280565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612e59573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e7d91906154df565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612eea576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610d09565b81811015611b78576000612efe828461592b565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612f79573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f9d91906158b5565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112af82614549565b61300761394f565b600060066000838152602001908152602001600020604051806060016040529081600082015481526020016001820180546130419061554a565b80601f016020809104026020016040519081016040528092919081815260200182805461306d9061554a565b80156130ba5780601f1061308f576101008083540402835291602001916130ba565b820191906000526020600020905b81548152906001019060200180831161309d57829003601f168201915b505050505081526020016002820154815250509050806040015143101561310d576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816131325761311f8160200151614698565b60208082015180519101206007556131da565b61313d826000613aad565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016131799190614db4565b600060405180830381600087803b15801561319357600080fd5b505af19250505080156131a4575060015b6131da576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6009546131f29062010000900461ffff166001615994565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926132639286926159af565b60405180910390a15050565b61327761394f565b612c9681614793565b6109a861394f565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561336957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161333e575b505050918352505060039190910154602090910152805190915060005b82608001515181101561342a57600c6000846080015183815181106133ad576133ad615760565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613423816158f3565b9050613386565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061345c6002830182614b9f565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff1661348f9190615890565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561352e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061355291906158b5565b613588576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b6109a861488e565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613675576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610851576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6136ef7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613aad565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561375d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061378191906158b5565b6109a8576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610d09565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110613819576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610d09565b6010805460ff831690811061383057613830615760565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611b78576010805460ff831690811061388057613880615760565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610d09565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612c96576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff1633146109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d09565b6139dd6148fb565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613a5a61488e565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a283390565b600081613aec5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613ae65790506112af565b50613b78565b60005b60035460ff82161015613b76576003805460ff8316908110613b1357613b13615760565b90600052602060002001548403613b66576004805460ff8316908110613b3b57613b3b615760565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112af9050565b613b6f8161578f565b9050613aef565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610d09565b60006bffffffffffffffffffffffff821115613c4b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610d09565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613c9a908990899089906024016159d7565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613d4c57600080fd5b5a611388811015613d5c57600080fd5b611388810390508760408204820311613d7457600080fd5b60008086516020880160008b8df193505a900391503d6084811115613d97575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613de884613bad565b613df290866157dd565b9050600081613e01888661580d565b613e0b919061580d565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613e6291859116615890565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613e9c919061580d565b336000908152600d602052604081208054909190613ec99084906bffffffffffffffffffffffff1661580d565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613f109185911661580d565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613f6491859116615890565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613fe891859169010000000000000000009004166158d2565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60006140256135f6565b61402e856138d9565b6140383386614967565b61404285836137b9565b600061404e8888613aad565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c59161411991600401615a0c565b6080604051808303816000875af1158015614138573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061415c9190615a9f565b92975090945092509050614171338a85614a03565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c081016141e78342615537565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161446696959493929190615add565b60405180910390a4505050509695505050505050565b6060600080808061448f86880188615b41565b935093509350935060006144a88960018787878761401b565b60408051602080825281830190925291925060208201818036833701905050955060005b602081101561453c578181602081106144e7576144e7615760565b1a60f81b8782815181106144fd576144fd615760565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350614535816158f3565b90506144cc565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156145c157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614596575b5050505050905060005b815181101561468e576000600c60008484815181106145ec576145ec615760565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461467d57506001949350505050565b50614687816158f3565b90506145cb565b5060009392505050565b6000806000838060200190518101906146b19190615bb2565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c021781558351959850939650919450909261475c9160109190860190614bbd565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612fe693929190615c9b565b3373ffffffffffffffffffffffffffffffffffffffff821603614812576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d09565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16156109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610d09565b60005460ff166109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610d09565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610851576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b67ffffffffffffffff82166000908152600b602052604081206001018054839290614a3d9084906bffffffffffffffffffffffff1661580d565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614ab39284929004166158d2565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614b19579160200282015b82811115614b19578251825591602001919060010190614afe565b50613c4b929150614c63565b828054828255906000526020600020908101928215614b19579160200282015b82811115614b1957825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614b45565b5080546000825590600052602060002090810190612c969190614c63565b82805482825590600052602060002090600701600890048101928215614b195791602002820160005b83821115614c2a57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614be6565b8015614c5a5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614c2a565b5050613c4b9291505b5b80821115613c4b5760008155600101614c64565b803567ffffffffffffffff81168114614c9057600080fd5b919050565b600060208284031215614ca757600080fd5b611b8982614c78565b803573ffffffffffffffffffffffffffffffffffffffff81168114614c9057600080fd5b60008060408385031215614ce757600080fd5b614cf083614c78565b9150614cfe60208401614cb0565b90509250929050565b63ffffffff81168114612c9657600080fd5b60008060408385031215614d2c57600080fd5b614d3583614c78565b91506020830135614d4581614d07565b809150509250929050565b6000815180845260005b81811015614d7657602081850181015186830182015201614d5a565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611b896020830184614d50565b60008060408385031215614dda57600080fd5b614de383614c78565b946020939093013593505050565b60008083601f840112614e0357600080fd5b50813567ffffffffffffffff811115614e1b57600080fd5b602083019150836020828501011115614e3357600080fd5b9250929050565b600080600060408486031215614e4f57600080fd5b83359250602084013567ffffffffffffffff811115614e6d57600080fd5b614e7986828701614df1565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614efc57614efc614e86565b604052919050565b600067ffffffffffffffff821115614f1e57614f1e614e86565b5060051b60200190565b600082601f830112614f3957600080fd5b81356020614f4e614f4983614f04565b614eb5565b82815260059290921b84018101918181019086841115614f6d57600080fd5b8286015b84811015614f8f57614f8281614cb0565b8352918301918301614f71565b509695505050505050565b60008060408385031215614fad57600080fd5b823567ffffffffffffffff80821115614fc557600080fd5b818501915085601f830112614fd957600080fd5b81356020614fe9614f4983614f04565b82815260059290921b8401810191818101908984111561500857600080fd5b948201945b838610156150265785358252948201949082019061500d565b9650508601359250508082111561503c57600080fd5b5061504985828601614f28565b9150509250929050565b600082601f83011261506457600080fd5b813567ffffffffffffffff81111561507e5761507e614e86565b6150af60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614eb5565b8181528460208386010111156150c457600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612c9657600080fd5b60008060008060008060c0878903121561511457600080fd5b86359550602087013567ffffffffffffffff8082111561513357600080fd5b61513f8a838b01615053565b9650604089013591508082111561515557600080fd5b5061516289828a01615053565b9450506060870135615173816150e1565b92506080870135615183816150e1565b915061519160a08801614cb0565b90509295509295509295565b803561ffff81168114614c9057600080fd5b60008060008060008060a087890312156151c857600080fd5b6151d187614c78565b9550602087013567ffffffffffffffff8111156151ed57600080fd5b6151f989828a01614df1565b909650945061520c90506040880161519d565b9250606087013561521c81614d07565b80925050608087013590509295509295509295565b6000806040838503121561524457600080fd5b61524d83614cb0565b91506020830135614d45816150e1565b6000806020838503121561527057600080fd5b823567ffffffffffffffff8082111561528857600080fd5b818501915085601f83011261529c57600080fd5b8135818111156152ab57600080fd5b8660208260051b85010111156152c057600080fd5b60209290920196919550909350505050565b600080604083850312156152e557600080fd5b6152ee83614cb0565b9150614cfe60208401614c78565b8015158114612c9657600080fd5b6000806040838503121561531d57600080fd5b823591506020830135614d45816152fc565b600081518084526020808501945080840160005b8381101561537557815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615343565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a0608082018190526000906112869083018461532f565b600080600080606085870312156153eb57600080fd5b6153f485614cb0565b935060208501359250604085013567ffffffffffffffff81111561541757600080fd5b61542387828801614df1565b95989497509550505050565b60006020828403121561544157600080fd5b5035919050565b60006020828403121561545a57600080fd5b611b898261519d565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154a457845183529383019391830191600101615488565b505084810360408601526154b8818761532f565b98975050505050505050565b6000602082840312156154d657600080fd5b611b8982614cb0565b6000602082840312156154f157600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112af576112af615508565b600181811c9082168061555e57607f821691505b602082108103615597577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611b7857600081815260208120601f850160051c810160208610156155c45750805b601f850160051c820191505b818110156155e3578281556001016155d0565b505050505050565b815167ffffffffffffffff81111561560557615605614e86565b61561981615613845461554a565b8461559d565b602080601f83116001811461566c57600084156156365750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556155e3565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156156b95788860151825594840194600190910190840161569a565b50858210156156f557878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036157a5576157a5615508565b60010192915050565b6effffffffffffffffffffffffffffff8181168382160190808211156157d6576157d6615508565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461580557615805615508565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156157d6576157d6615508565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061587e60a0830185614d50565b82810360808401526154b88185614d50565b6bffffffffffffffffffffffff8281168282160390808211156157d6576157d6615508565b6000602082840312156158c757600080fd5b8151611b89816152fc565b67ffffffffffffffff8181168382160190808211156157d6576157d6615508565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361592457615924615508565b5060010190565b818103818111156112af576112af615508565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361598a5761598a615508565b6001019392505050565b61ffff8181168382160190808211156157d6576157d6615508565b8381528260208201526060604082015260006159ce6060830184614d50565b95945050505050565b8381526060602082015260006159f06060830185614d50565b8281036040840152615a028185614d50565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e06060840152615a57610100840182614d50565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b60008060008060808587031215615ab557600080fd5b845193506020850151615ac7816150e1565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615b1e60c0830186614d50565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b60008060008060808587031215615b5757600080fd5b615b6085614c78565b9350602085013567ffffffffffffffff811115615b7c57600080fd5b615b8887828801615053565b935050615b976040860161519d565b91506060850135615ba781614d07565b939692955090935050565b600080600060608486031215615bc757600080fd5b8351615bd2816150e1565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615c0a57600080fd5b604086015190935067ffffffffffffffff811115615c2757600080fd5b8501601f81018713615c3857600080fd5b8051615c46614f4982614f04565b81815260059190911b82018301908381019089831115615c6557600080fd5b928401925b82841015615c8c578351615c7d81614d07565b82529284019290840190615c6a565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615d1857845163ffffffff1683529383019391830191600101615cf6565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -741,6 +741,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) OwnerCancelSubscriptio return _FunctionsRouter.Contract.OwnerCancelSubscription(&_FunctionsRouter.TransactOpts, subscriptionId) } +func (_FunctionsRouter *FunctionsRouterTransactor) OwnerWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "ownerWithdraw", recipient, amount) +} + +func (_FunctionsRouter *FunctionsRouterSession) OwnerWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { + return _FunctionsRouter.Contract.OwnerWithdraw(&_FunctionsRouter.TransactOpts, recipient, amount) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) OwnerWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { + return _FunctionsRouter.Contract.OwnerWithdraw(&_FunctionsRouter.TransactOpts, recipient, amount) +} + func (_FunctionsRouter *FunctionsRouterTransactor) ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "proposeConfigUpdate", id, config) } @@ -3786,6 +3798,8 @@ type FunctionsRouterInterface interface { OwnerCancelSubscription(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) + OwnerWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) + ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetAddresses []common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e0f9b1d986f..fd4d7384cdc 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,10 +1,10 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin c1e05728f436bfc4ee2d93cc22b555c4d86b25b522ebe10b76203472927dfbbc +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 58333476259ad385d98bb1eaccbd6f91d79feda86dcc90e30edb21f38f150cbe functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 -functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 747aece848474708a007de3deb6d6e76c6407ac8850c84db6aa294acdf289d21 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin aefc4795c28e52f4cfb9f2374b7c31a19583fb113219c2378ef74dd351be1c8b -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 44fc70ab0fd16a37e16222e01de3f836d94f9a491b422db6e298581cd7843f45 +functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 36b045452a98ac0c845d1e23017dd19eac560177a5b51d85ea1bfed314907141 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin cf271fe0d9111ce6f506cdea64ef80a19cdb89ec53574c15e1094a5084e356ea ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From d581fc61435713389d0f16bd9ba689f23b4b498d Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sun, 30 Jul 2023 11:30:45 -0700 Subject: [PATCH 037/270] [Functions] LogPollerWrapper implementation (#9987) --- .../ocr2/plugins/functions/config/config.go | 1 + core/services/relay/evm/functions.go | 5 +- .../evm/functions/contract_transmitter.go | 12 +- .../relay/evm/functions/logpoller_wrapper.go | 279 ++++++++++++++++-- .../evm/functions/logpoller_wrapper_test.go | 47 +++ core/services/relay/evm/types/types.go | 17 +- 6 files changed, 319 insertions(+), 42 deletions(-) create mode 100644 core/services/relay/evm/functions/logpoller_wrapper_test.go diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index ae59ffc574e..1f20b6a833a 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -29,6 +29,7 @@ type PluginConfig struct { PruneCheckFrequencySec uint32 `json:"pruneCheckFrequencySec"` PruneBatchSize uint32 `json:"pruneBatchSize"` ListenerEventHandlerTimeoutSec uint32 `json:"listenerEventHandlerTimeoutSec"` + ContractUpdateCheckFrequencySec uint32 `json:"contractUpdateCheckFrequencySec"` MaxRequestSizeBytes uint32 `json:"maxRequestSizeBytes"` MaxRequestSizesList []uint32 `json:"maxRequestSizesList"` MaxSecretsSizesList []uint32 `json:"maxSecretsSizesList"` diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index f1275d2d18b..3e458e97a9c 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -95,7 +95,10 @@ func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, par return nil, err2 } routerContractAddress := common.HexToAddress(rargs.ContractID) - logPollerWrapper := functionsRelay.NewLogPollerWrapper(routerContractAddress, pluginConfig.ContractVersion, chain.LogPoller(), lggr) + logPollerWrapper, err := functionsRelay.NewLogPollerWrapper(routerContractAddress, pluginConfig, chain.Client(), chain.LogPoller(), lggr) + if err != nil { + return nil, err + } configWatcher, err := newFunctionsConfigProvider(pluginType, chain, rargs, relayConfig.FromBlock, logPollerWrapper, lggr) if err != nil { return nil, err diff --git a/core/services/relay/evm/functions/contract_transmitter.go b/core/services/relay/evm/functions/contract_transmitter.go index 673c3a12011..97afa67d2b1 100644 --- a/core/services/relay/evm/functions/contract_transmitter.go +++ b/core/services/relay/evm/functions/contract_transmitter.go @@ -3,7 +3,6 @@ package functions import ( "context" "database/sql" - "encoding/hex" "fmt" "math/big" "sync/atomic" @@ -124,24 +123,26 @@ func (oc *contractTransmitter) Transmit(ctx context.Context, reportCtx ocrtypes. } destinationContract = *destinationContractPtr } else if oc.contractVersion == 1 { + oc.lggr.Debugw("FunctionsContractTransmitter: start", "reportLenBytes", len(report)) requests, err2 := oc.reportCodec.DecodeReport(report) if err2 != nil { - return errors.Wrap(err2, "DecodeReport failed") + return errors.Wrap(err2, "FunctionsContractTransmitter: DecodeReport failed") } if len(requests) == 0 { - return errors.New("no requests in report") + return errors.New("FunctionsContractTransmitter: no requests in report") } if len(requests[0].CoordinatorContract) != common.AddressLength { - return fmt.Errorf("incorrect length of CoordinatorContract field: %d", len(requests[0].CoordinatorContract)) + return fmt.Errorf("FunctionsContractTransmitter: incorrect length of CoordinatorContract field: %d", len(requests[0].CoordinatorContract)) } // NOTE: this is incorrect if batch contains requests destined for different contracts (unlikely) // it will be fixed when we get rid of batching destinationContract.SetBytes(requests[0].CoordinatorContract) + oc.lggr.Debugw("FunctionsContractTransmitter: ready", "nRequests", len(requests), "coordinatorContract", destinationContract.Hex()) } else { return fmt.Errorf("unsupported contract version: %d", oc.contractVersion) } - oc.lggr.Debugw("Transmitting report", "report", hex.EncodeToString(report), "rawReportCtx", rawReportCtx, "contractAddress", destinationContract, "txMeta", txMeta) + oc.lggr.Debugw("FunctionsContractTransmitter: transmitting report", "contractAddress", destinationContract, "txMeta", txMeta) payload, err := oc.contractABI.Pack("transmit", rawReportCtx, []byte(report), rs, ss, vs) if err != nil { @@ -244,6 +245,7 @@ func (oc *contractTransmitter) UpdateRoutes(activeCoordinator common.Address, pr if previousContract != nil && *previousContract == activeCoordinator { return nil } + oc.lggr.Debugw("FunctionsContractTransmitter: updating routes", "previousContract", previousContract, "activeCoordinator", activeCoordinator) err := oc.lp.RegisterFilter(logpoller.Filter{Name: transmitterFilterName(activeCoordinator), EventSigs: []common.Hash{oc.transmittedEventSig}, Addresses: []common.Address{activeCoordinator}}) if err != nil { return err diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 660c93a5a53..4e4b7e3050e 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -3,44 +3,87 @@ package functions import ( "context" "sync" + "time" + "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_router" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) type logPollerWrapper struct { - routerContract common.Address - contractVersion uint32 - logPoller logpoller.LogPoller - subscribers map[string]evmRelayTypes.RouteUpdateSubscriber - mu sync.RWMutex - lggr logger.Logger + utils.StartStopOnce + + routerContract *functions_router.FunctionsRouter + pluginConfig config.PluginConfig + client client.Client + logPoller logpoller.LogPoller + subscribers map[string]evmRelayTypes.RouteUpdateSubscriber + activeCoordinator common.Address + proposedCoordinator common.Address + nextBlock int64 + mu sync.Mutex + closeWait sync.WaitGroup + stopCh utils.StopChan + lggr logger.Logger } var _ evmRelayTypes.LogPollerWrapper = &logPollerWrapper{} -func NewLogPollerWrapper(routerContract common.Address, contractVersion uint32, logPoller logpoller.LogPoller, lggr logger.Logger) evmRelayTypes.LogPollerWrapper { - return &logPollerWrapper{ - routerContract: routerContract, - contractVersion: contractVersion, - logPoller: logPoller, - subscribers: make(map[string]evmRelayTypes.RouteUpdateSubscriber), - lggr: lggr, +func NewLogPollerWrapper(routerContractAddress common.Address, pluginConfig config.PluginConfig, client client.Client, logPoller logpoller.LogPoller, lggr logger.Logger) (evmRelayTypes.LogPollerWrapper, error) { + routerContract, err := functions_router.NewFunctionsRouter(routerContractAddress, client) + if err != nil { + return nil, err } + + return &logPollerWrapper{ + routerContract: routerContract, + pluginConfig: pluginConfig, + logPoller: logPoller, + client: client, + subscribers: make(map[string]evmRelayTypes.RouteUpdateSubscriber), + stopCh: make(utils.StopChan), + lggr: lggr, + }, nil } -// TODO(FUN-381): Implement LogPollerWrapper with an API suiting all users. func (l *logPollerWrapper) Start(context.Context) error { - // TODO periodically update active and proposed coordinator contract addresses - // update own Logpoller filters accordingly - // push to all subscribers - return nil + return l.StartOnce("LogPollerWrapper", func() error { + l.lggr.Info("starting LogPollerWrapper") + l.mu.Lock() + defer l.mu.Unlock() + if l.pluginConfig.ContractVersion == 0 { + l.activeCoordinator = l.routerContract.Address() + l.proposedCoordinator = l.routerContract.Address() + } else if l.pluginConfig.ContractVersion == 1 { + nextBlock, err := l.logPoller.LatestBlock() + l.nextBlock = nextBlock + if err != nil { + l.lggr.Error("LogPollerWrapper: LatestBlock() failed, starting from 0") + } else { + l.lggr.Debugw("LogPollerWrapper: LatestBlock() got starting block", "block", nextBlock) + } + l.closeWait.Add(1) + go l.checkForRouteUpdates() + } + return nil + }) } + func (l *logPollerWrapper) Close() error { - return nil + return l.StopOnce("LogPollerWrapper", func() (err error) { + l.lggr.Info("closing LogPollerWrapper") + close(l.stopCh) + l.closeWait.Wait() + return nil + }) } func (l *logPollerWrapper) HealthReport() map[string]error { @@ -55,29 +98,201 @@ func (l *logPollerWrapper) Ready() error { return nil } -// "public" methods of LogPollerWrapper -func (l *logPollerWrapper) LatestRequests() ([]evmRelayTypes.OracleRequest, error) { - // TODO poll both active and proposed coordinators for requests and parse them - return nil, nil -} +// methods of LogPollerWrapper +func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmRelayTypes.OracleResponse, error) { + l.mu.Lock() + coordinators := []common.Address{l.activeCoordinator} + if l.activeCoordinator != l.proposedCoordinator { + coordinators = append(coordinators, l.proposedCoordinator) + } + nextBlock := l.nextBlock + latest, err := l.logPoller.LatestBlock() + if err != nil { + l.mu.Unlock() + return nil, nil, err + } + if latest >= nextBlock { + l.nextBlock = latest + 1 + } + l.mu.Unlock() + + // outside of the lock + resultsReq := []evmRelayTypes.OracleRequest{} + resultsResp := []evmRelayTypes.OracleResponse{} + if latest < nextBlock { + l.lggr.Debugw("LatestEvents: no new blocks to check", "latest", latest, "nextBlock", nextBlock) + return resultsReq, resultsResp, nil + } -func (l *logPollerWrapper) LatestResponses() ([]evmRelayTypes.OracleResponse, error) { - // TODO poll both active and proposed coordinators for responses and parse them - return nil, nil + for _, coordinator := range coordinators { + requestLogs, err := l.logPoller.Logs(nextBlock, latest, functions_coordinator.FunctionsCoordinatorOracleRequest{}.Topic(), coordinator) + if err != nil { + l.lggr.Errorw("LatestEvents: fetching request logs from LogPoller failed", "latest", latest, "nextBlock", nextBlock) + return nil, nil, err + } + responseLogs, err := l.logPoller.Logs(nextBlock, latest, functions_coordinator.FunctionsCoordinatorOracleResponse{}.Topic(), coordinator) + if err != nil { + l.lggr.Errorw("LatestEvents: fetching response logs from LogPoller failed", "latest", latest, "nextBlock", nextBlock) + return nil, nil, err + } + + parsingContract, err := functions_coordinator.NewFunctionsCoordinator(coordinator, l.client) + if err != nil { + l.lggr.Error("LatestEvents: creating a contract instance for parsing failed") + return nil, nil, err + } + + l.lggr.Debugw("LatestEvents: parsing logs", "nRequestLogs", len(requestLogs), "nResponseLogs", len(responseLogs), "coordinatorAddress", coordinator.Hex()) + for _, log := range requestLogs { + gethLog := log.ToGethLog() + oracleRequest, err := parsingContract.ParseOracleRequest(gethLog) + if err != nil { + l.lggr.Errorw("LatestEvents: failed to parse a request log, skipping") + continue + } + resultsReq = append(resultsReq, evmRelayTypes.OracleRequest{ + RequestId: oracleRequest.RequestId, + RequestingContract: oracleRequest.RequestingContract, + RequestInitiator: oracleRequest.RequestInitiator, + SubscriptionId: oracleRequest.SubscriptionId, + SubscriptionOwner: oracleRequest.SubscriptionOwner, + Data: oracleRequest.Data, + DataVersion: oracleRequest.DataVersion, + Flags: oracleRequest.Flags, + CallbackGasLimit: oracleRequest.CallbackGasLimit, + TxHash: oracleRequest.Raw.TxHash, + CoordinatorContract: coordinator, + }) + } + for _, log := range responseLogs { + gethLog := log.ToGethLog() + oracleResponse, err := parsingContract.ParseOracleResponse(gethLog) + if err != nil { + l.lggr.Errorw("LatestEvents: failed to parse a response log, skipping") + continue + } + resultsResp = append(resultsResp, evmRelayTypes.OracleResponse{ + RequestId: oracleResponse.RequestId, + }) + } + } + + l.lggr.Debugw("LatestEvents: done", "nRequestLogs", len(resultsReq), "nResponseLogs", len(resultsResp), "nextBlock", nextBlock, "latest", latest) + return resultsReq, resultsResp, nil } // "internal" method called only by EVM relayer components func (l *logPollerWrapper) SubscribeToUpdates(subscriberName string, subscriber evmRelayTypes.RouteUpdateSubscriber) { - if l.contractVersion == 0 { + if l.pluginConfig.ContractVersion == 0 { // in V0, immediately set contract address to Oracle contract and never update again - err := subscriber.UpdateRoutes(l.routerContract, l.routerContract) + err := subscriber.UpdateRoutes(l.routerContract.Address(), l.routerContract.Address()) l.lggr.Errorw("LogPollerWrapper: Failed to update routes", "subscriberName", subscriberName, "error", err) - } else if l.contractVersion == 1 { + } else if l.pluginConfig.ContractVersion == 1 { l.mu.Lock() defer l.mu.Unlock() l.subscribers[subscriberName] = subscriber - // TODO remove when periodic updates are ready - _ = subscriber.UpdateRoutes(l.routerContract, l.routerContract) + // TODO remove when periodic updates are ready and integration tests are properly migrated + _ = subscriber.UpdateRoutes(l.routerContract.Address(), l.routerContract.Address()) } } + +func (l *logPollerWrapper) checkForRouteUpdates() { + defer l.closeWait.Done() + freqSec := l.pluginConfig.ContractUpdateCheckFrequencySec + if freqSec == 0 { + l.lggr.Errorw("ContractUpdateCheckFrequencySec is zero - route update checks disabled") + return + } + + updateOnce := func() { + // NOTE: timeout == frequency here, could be changed to a separate config value + timeoutCtx, cancel := utils.ContextFromChanWithTimeout(l.stopCh, time.Duration(l.pluginConfig.ContractUpdateCheckFrequencySec)*time.Second) + defer cancel() + active, proposed, err := l.getCurrentCoordinators(timeoutCtx) + if err != nil { + l.lggr.Errorw("LogPollerWrapper: error calling getCurrentCoordinators", "err", err) + } + l.handleRouteUpdate(active, proposed) + } + + updateOnce() // update once right away + ticker := time.NewTicker(time.Duration(freqSec) * time.Second) + defer ticker.Stop() + for { + select { + case <-l.stopCh: + return + case <-ticker.C: + updateOnce() + } + } +} + +func (l *logPollerWrapper) getCurrentCoordinators(ctx context.Context) (common.Address, common.Address, error) { + if l.pluginConfig.ContractVersion == 0 { + return l.routerContract.Address(), l.routerContract.Address(), nil + } + var donId [32]byte + copy(donId[:], []byte(l.pluginConfig.DONId)) + + activeCoordinator, err := l.routerContract.GetContractById(&bind.CallOpts{ + Pending: false, + Context: ctx, + }, donId, false) + if err != nil { + return common.Address{}, common.Address{}, err + } + + proposedCoordinator, err := l.routerContract.GetContractById(&bind.CallOpts{ + Pending: false, + Context: ctx, + }, donId, true) + if err != nil { + return common.Address{}, common.Address{}, err + } + + return activeCoordinator, proposedCoordinator, nil +} + +func (l *logPollerWrapper) handleRouteUpdate(activeCoordinator common.Address, proposedCoordinator common.Address) { + l.mu.Lock() + defer l.mu.Unlock() + if activeCoordinator == l.activeCoordinator && proposedCoordinator == l.proposedCoordinator { + l.lggr.Debug("LogPollerWrapper: no changes to routes") + return + } + errActive := l.registerFilters(activeCoordinator) + errProposed := l.registerFilters(proposedCoordinator) + if errActive != nil || errProposed != nil { + l.lggr.Errorw("LogPollerWrapper: Failed to register filters", "errorActive", errActive, "errorProposed", errProposed) + return + } + + l.lggr.Debugw("LogPollerWrapper: new routes", "activeCoordinator", activeCoordinator.Hex(), "proposedCoordinator", proposedCoordinator.Hex()) + l.activeCoordinator = activeCoordinator + l.proposedCoordinator = proposedCoordinator + + for _, subscriber := range l.subscribers { + err := subscriber.UpdateRoutes(activeCoordinator, proposedCoordinator) + if err != nil { + l.lggr.Errorw("LogPollerWrapper: Failed to update routes", "error", err) + } + } +} + +func filterName(addr common.Address) string { + return logpoller.FilterName("FunctionsLogPollerWrapper", addr.String()) +} + +func (l *logPollerWrapper) registerFilters(coordinatorAddress common.Address) error { + return l.logPoller.RegisterFilter( + logpoller.Filter{ + Name: filterName(coordinatorAddress), + EventSigs: []common.Hash{ + functions_coordinator.FunctionsCoordinatorOracleRequest{}.Topic(), + functions_coordinator.FunctionsCoordinatorOracleResponse{}.Topic(), + }, + Addresses: []common.Address{coordinatorAddress}, + }) +} diff --git a/core/services/relay/evm/functions/logpoller_wrapper_test.go b/core/services/relay/evm/functions/logpoller_wrapper_test.go new file mode 100644 index 00000000000..ea493880d89 --- /dev/null +++ b/core/services/relay/evm/functions/logpoller_wrapper_test.go @@ -0,0 +1,47 @@ +package functions_test + +import ( + "encoding/hex" + "testing" + + gethcommon "github.com/ethereum/go-ethereum/common" + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" + + evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + lpmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" +) + +func TestLogPollerWrapper_BasicEmptyEvents(t *testing.T) { + t.Parallel() + + lggr := logger.TestLogger(t) + client := evmclimocks.NewClient(t) + lp := lpmocks.NewLogPoller(t) + config := config.PluginConfig{ + ContractUpdateCheckFrequencySec: 1000000, // only once + ContractVersion: 1, + } + lpWrapper, err := functions.NewLogPollerWrapper(gethcommon.Address{}, config, client, lp, lggr) + require.NoError(t, err) + + lp.On("LatestBlock").Return(int64(100), nil) + lp.On("Logs", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return([]logpoller.Log{}, nil) + + contractAddr, err := hex.DecodeString("0000000000000000000000000000000000000000000000000000000000000001") + require.NoError(t, err) + client.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(contractAddr, nil) + lp.On("RegisterFilter", mock.Anything).Return(nil) + + require.NoError(t, lpWrapper.Start(testutils.Context(t))) + reqs, resps, err := lpWrapper.LatestEvents() + require.NoError(t, err) + require.Equal(t, 0, len(reqs)) + require.Equal(t, 0, len(resps)) + lpWrapper.Close() +} diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index 5954a228c8a..d0c814535ea 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -42,11 +42,21 @@ type FunctionsProvider interface { } type OracleRequest struct { - // TODO: define + RequestId [32]byte + RequestingContract common.Address + RequestInitiator common.Address + SubscriptionId uint64 + SubscriptionOwner common.Address + Data []byte + DataVersion uint16 + Flags [32]byte + CallbackGasLimit uint64 + TxHash common.Hash + CoordinatorContract common.Address } type OracleResponse struct { - // TODO: define + RequestId [32]byte } type RouteUpdateSubscriber interface { @@ -56,8 +66,7 @@ type RouteUpdateSubscriber interface { // A LogPoller wrapper that understands router proxy contracts type LogPollerWrapper interface { relaytypes.Service - LatestRequests() ([]OracleRequest, error) - LatestResponses() ([]OracleResponse, error) + LatestEvents() ([]OracleRequest, []OracleResponse, error) // TODO (FUN-668): Remove from the LOOP interface and only use internally within the EVM relayer SubscribeToUpdates(name string, subscriber RouteUpdateSubscriber) From 50c6c19108332c1b091004191fbe9ec017918b58 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Sun, 30 Jul 2023 20:02:56 -0400 Subject: [PATCH 038/270] [Functions] ToS allow list (#9985) * Use ReadAccessController interface within ToS Allowlist & add method for get all * (test): Amend ToS test for new getter name * Remove ToS Allow List's overloaded .hasAccess() --- .../functions/dev/1_0_0/FunctionsRouter.sol | 6 +-- .../accessControl/TermsOfServiceAllowList.sol | 24 +++++++---- .../interfaces/ITermsOfServiceAllowList.sol | 15 ++++--- .../shared/interfaces/IAccessController.sol | 6 +++ .../v1/TermsOfServiceAllowList.test.ts | 4 +- .../functions_allow_list.go | 42 +++++++++++++++---- .../functions_router/functions_router.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 4 +- .../v1/internal/testutils.go | 2 +- 9 files changed, 74 insertions(+), 31 deletions(-) create mode 100644 contracts/src/v0.8/shared/interfaces/IAccessController.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index ad5e4eadef2..ddb69b3fed8 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -5,7 +5,7 @@ import {RouterBase, ITypeAndVersion} from "./RouterBase.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; -import {ITermsOfServiceAllowList} from "./accessControl/interfaces/ITermsOfServiceAllowList.sol"; +import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { @@ -400,8 +400,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions _validateOwnership(); } - function _onlySenderThatAcceptedToS() internal override { - if (!ITermsOfServiceAllowList(_getContractById(ALLOW_LIST_ID, false)).isAllowedSender(msg.sender)) { + function _onlySenderThatAcceptedToS() internal view override { + if (!IAccessController(_getContractById(ALLOW_LIST_ID, false)).hasAccess(msg.sender, new bytes(0))) { revert SenderMustAcceptTermsOfService(msg.sender); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index 7c9c1d8be61..dedc5c2900e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -3,16 +3,19 @@ pragma solidity ^0.8.19; import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.sol"; import {Routable, ITypeAndVersion} from "../Routable.sol"; +import {IAccessController} from "../../../../shared/interfaces/IAccessController.sol"; +import {EnumerableSet} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; import {Address} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol"; /** * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service */ -contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { +contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessController { using Address for address; + using EnumerableSet for EnumerableSet.AddressSet; - mapping(address => bool) private s_allowedSenders; + EnumerableSet.AddressSet private s_allowedSenders; mapping(address => bool) private s_blockedSenders; error InvalidProof(); @@ -102,23 +105,30 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { } // Add recipient to the allow list - s_allowedSenders[recipient] = true; + s_allowedSenders.add(recipient); } /** * @inheritdoc ITermsOfServiceAllowList */ - function isAllowedSender(address sender) public view override returns (bool) { + function getAllAllowedSenders() external view override returns (address[] memory) { + return s_allowedSenders.values(); + } + + /** + * @inheritdoc IAccessController + */ + function hasAccess(address user, bytes calldata /* data */) external view override returns (bool) { if (!s_config.enabled) { return true; } - return s_allowedSenders[sender]; + return s_allowedSenders.contains(user); } /** * @inheritdoc ITermsOfServiceAllowList */ - function isBlockedSender(address sender) public view override returns (bool) { + function isBlockedSender(address sender) external view override returns (bool) { if (!s_config.enabled) { return false; } @@ -133,7 +143,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList { * @inheritdoc ITermsOfServiceAllowList */ function blockSender(address sender) external override onlyRouterOwner { - s_allowedSenders[sender] = false; + s_allowedSenders.remove(sender); s_blockedSenders[sender] = true; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol index b362f3a5543..b3093520bc0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol @@ -22,18 +22,21 @@ interface ITermsOfServiceAllowList { function getEthSignedMessageHash(bytes32 messageHash) external pure returns (bytes32); /** - * @notice Check if the address is authorized for usage + * @notice Check if the address is blocked for usage * @param sender The transaction sender's address * @return True or false */ - function isAllowedSender(address sender) external returns (bool); + function isBlockedSender(address sender) external returns (bool); /** - * @notice Check if the address is blocked for usage - * @param sender The transaction sender's address - * @return True or false + * @notice Get a list of all allowed senders + * @dev WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed + * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that + * this function has an unbounded cost, and using it as part of a state-changing function may render the function + * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. + * @return addresses - all allowed addresses */ - function isBlockedSender(address sender) external returns (bool); + function getAllAllowedSenders() external view returns (address[] memory); /** * @notice Allows access to the sender based on acceptance of the Terms of Service diff --git a/contracts/src/v0.8/shared/interfaces/IAccessController.sol b/contracts/src/v0.8/shared/interfaces/IAccessController.sol new file mode 100644 index 00000000000..07cb7a154d4 --- /dev/null +++ b/contracts/src/v0.8/shared/interfaces/IAccessController.sol @@ -0,0 +1,6 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +interface IAccessController { + function hasAccess(address user, bytes calldata data) external view returns (bool); +} diff --git a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts index e7adeab490a..661c9f81700 100644 --- a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts +++ b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts @@ -43,7 +43,7 @@ describe('ToS Access Control', () => { roles.subOwnerAddress, ) expect( - await contracts.accessControl.isAllowedSender(roles.subOwnerAddress), + await contracts.accessControl.hasAccess(roles.subOwnerAddress, '0x'), ).to.equal(true) }) it('cannot be done by Externally Owned Accounts if recipient another EoA', async () => { @@ -69,7 +69,7 @@ describe('ToS Access Control', () => { .acceptTermsOfService(acceptorAddress, recipientAddress, proof) expect( - await contracts.accessControl.isAllowedSender(recipientAddress), + await contracts.accessControl.hasAccess(recipientAddress, '0x'), ).to.equal(true) }) it('cannot be done by Contract Accounts that if they are not the recipient', async () => { diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index 41e8a2264ab..c1853515445 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -31,8 +31,8 @@ var ( ) var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isAllowedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162000fbe38038062000fbe833981016040819052620000349162000156565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660805262000076816200008b565b80516020909101206000555062000284915050565b60008082806020019051810190620000a4919062000241565b6040805180820182528315158082526001600160a01b0384166020928301819052600380546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013d57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016a57600080fd5b8251620001778162000127565b602084810151919350906001600160401b03808211156200019757600080fd5b818601915086601f830112620001ac57600080fd5b815181811115620001c157620001c162000140565b604051601f8201601f19908116603f01168101908382118183101715620001ec57620001ec62000140565b8160405282815289868487010111156200020557600080fd5b600093505b828410156200022957848401860151818501870152928501926200020a565b60008684830101528096505050505050509250929050565b600080604083850312156200025557600080fd5b825180151581146200026657600080fd5b6020840151909250620002798162000127565b809150509250929050565b608051610d10620002ae600039600081816104a9015281816105ea01526107570152610d106000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c80638cc6acce11610076578063a5e1d61d1161005b578063a5e1d61d146101b0578063be8c97b0146101d3578063fa540801146101e657600080fd5b80638cc6acce146101955780639883c10d146101a857600080fd5b806347663acb116100a757806347663acb146100f657806380e8a1511461010957806382184c7b1461018257600080fd5b8063181f5a77146100c35780632179d447146100e1575b600080fd5b6100cb610247565b6040516100d891906109f3565b60405180910390f35b6100f46100ef366004610a84565b610267565b005b6100f4610104366004610b16565b6104a7565b610174610117366004610b3a565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b6040519081526020016100d8565b6100f4610190366004610b16565b6105e8565b6100f46101a3366004610ba2565b61073f565b600054610174565b6101c36101be366004610b16565b6107c4565b60405190151581526020016100d8565b6101c36101e1366004610b16565b610805565b6101746101f4366004610c71565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610cdc60289139905090565b73ffffffffffffffffffffffffffffffffffffffff831660009081526002602052604090205460ff16156102c7576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600354610100900473ffffffffffffffffffffffffffffffffffffffff1661038961034d6101f487876040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b16603482015260009060480160405160208183030381529060405280519060200120905092915050565b84848080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061084692505050565b73ffffffffffffffffffffffffffffffffffffffff16146103d6576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff841614158061041b57503373ffffffffffffffffffffffffffffffffffffffff85161480159061041b5750333b155b15610452576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505073ffffffffffffffffffffffffffffffffffffffff16600090815260016020819052604090912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016909117905550565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610514573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105389190610c8a565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461059c576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610655573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106799190610c8a565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106dd576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260016020818152604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0090811690915560029092529092208054909216179055565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146107ae576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107b78161091d565b8051602090910120600055565b60035460009060ff166107d957506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b60035460009060ff1661081a57506001919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526001602052604090205460ff1690565b6000806000808451604114610887576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050602082810151604080850151606080870151835160008082529681018086528a9052951a928501839052840183905260808401819052919260019060a0016020604051602081039080840390855afa1580156108ea573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b600080828060200190518101906109349190610ca7565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600380547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b600060208083528351808285015260005b81811015610a2057858101830151858201604001528201610a04565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a8157600080fd5b50565b60008060008060608587031215610a9a57600080fd5b8435610aa581610a5f565b93506020850135610ab581610a5f565b9250604085013567ffffffffffffffff80821115610ad257600080fd5b818701915087601f830112610ae657600080fd5b813581811115610af557600080fd5b886020828501011115610b0757600080fd5b95989497505060200194505050565b600060208284031215610b2857600080fd5b8135610b3381610a5f565b9392505050565b60008060408385031215610b4d57600080fd5b8235610b5881610a5f565b91506020830135610b6881610a5f565b809150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610bb457600080fd5b813567ffffffffffffffff80821115610bcc57600080fd5b818401915084601f830112610be057600080fd5b813581811115610bf257610bf2610b73565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610c3857610c38610b73565b81604052828152876020848701011115610c5157600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610c8357600080fd5b5035919050565b600060208284031215610c9c57600080fd5b8151610b3381610a5f565b60008060408385031215610cba57600080fd5b82518015158114610cca57600080fd5b6020840151909250610b6881610a5f56fe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620012b6380380620012b6833981016040819052620000349162000156565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660805262000076816200008b565b80516020909101206000555062000284915050565b60008082806020019051810190620000a4919062000241565b6040805180820182528315158082526001600160a01b0384166020928301819052600480546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013d57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016a57600080fd5b8251620001778162000127565b602084810151919350906001600160401b03808211156200019757600080fd5b818601915086601f830112620001ac57600080fd5b815181811115620001c157620001c162000140565b604051601f8201601f19908116603f01168101908382118183101715620001ec57620001ec62000140565b8160405282815289868487010111156200020557600080fd5b600093505b828410156200022957848401860151818501870152928501926200020a565b60008684830101528096505050505050509250929050565b600080604083850312156200025557600080fd5b825180151581146200026657600080fd5b6020840151909250620002798162000127565b809150509250929050565b608051611008620002ae600039600081816103d6015281816105b0015261071601526110086000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c8063817ef62e116100815780639883c10d1161005b5780639883c10d14610193578063a5e1d61d1461019b578063fa540801146101ae57600080fd5b8063817ef62e1461015857806382184c7b1461016d5780638cc6acce1461018057600080fd5b806347663acb116100b257806347663acb146101015780636b14daf81461011457806380e8a1511461013757600080fd5b8063181f5a77146100ce5780632179d447146100ec575b600080fd5b6100d661020f565b6040516100e39190610b8f565b60405180910390f35b6100ff6100fa366004610c69565b61022f565b005b6100ff61010f366004610cce565b6103d4565b610127610122366004610ceb565b610515565b60405190151581526020016100e3565b61014a610145366004610d40565b61053f565b6040519081526020016100e3565b61016061059d565b6040516100e39190610d79565b6100ff61017b366004610cce565b6105ae565b6100ff61018e366004610e02565b6106fe565b60005461014a565b6101276101a9366004610cce565b610783565b61014a6101bc366004610ed1565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610fd460289139905090565b73ffffffffffffffffffffffffffffffffffffffff831660009081526003602052604090205460ff161561028f576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600454610100900473ffffffffffffffffffffffffffffffffffffffff166102f96102bd6101bc878761053f565b84848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506107c492505050565b73ffffffffffffffffffffffffffffffffffffffff1614610346576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff841614158061038b57503373ffffffffffffffffffffffffffffffffffffffff85161480159061038b5750333b155b156103c2576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103cd60018461089b565b5050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610441573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104659190610eea565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146104c9576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60045460009060ff1661052a57506001610538565b6105356001856108bd565b90505b9392505050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60606105a960016108ec565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561061b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061063f9190610eea565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106a3576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106ae6001826108f9565b5073ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461076d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107768161091b565b8051602090910120600055565b60045460009060ff1661079857506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205460ff1690565b6000806000808451604114610805576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050602082810151604080850151606080870151835160008082529681018086528a9052951a928501839052840183905260808401819052919260019060a0016020604051602081039080840390855afa158015610868573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b60006105388373ffffffffffffffffffffffffffffffffffffffff84166109f1565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001830160205260408120541515610538565b6060600061053883610a40565b60006105388373ffffffffffffffffffffffffffffffffffffffff8416610a9c565b600080828060200190518101906109329190610f07565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600480547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6000818152600183016020526040812054610a3857508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610597565b506000610597565b606081600001805480602002602001604051908101604052809291908181526020018280548015610a9057602002820191906000526020600020905b815481526020019060010190808311610a7c575b50505050509050919050565b60008181526001830160205260408120548015610b85576000610ac0600183610f3b565b8554909150600090610ad490600190610f3b565b9050818114610b39576000866000018281548110610af457610af4610f75565b9060005260206000200154905080876000018481548110610b1757610b17610f75565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610b4a57610b4a610fa4565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610597565b6000915050610597565b600060208083528351808285015260005b81811015610bbc57858101830151858201604001528201610ba0565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610c1d57600080fd5b50565b60008083601f840112610c3257600080fd5b50813567ffffffffffffffff811115610c4a57600080fd5b602083019150836020828501011115610c6257600080fd5b9250929050565b60008060008060608587031215610c7f57600080fd5b8435610c8a81610bfb565b93506020850135610c9a81610bfb565b9250604085013567ffffffffffffffff811115610cb657600080fd5b610cc287828801610c20565b95989497509550505050565b600060208284031215610ce057600080fd5b813561053881610bfb565b600080600060408486031215610d0057600080fd5b8335610d0b81610bfb565b9250602084013567ffffffffffffffff811115610d2757600080fd5b610d3386828701610c20565b9497909650939450505050565b60008060408385031215610d5357600080fd5b8235610d5e81610bfb565b91506020830135610d6e81610bfb565b809150509250929050565b6020808252825182820181905260009190848201906040850190845b81811015610dc757835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610d95565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610e1457600080fd5b813567ffffffffffffffff80821115610e2c57600080fd5b818401915084601f830112610e4057600080fd5b813581811115610e5257610e52610dd3565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610e9857610e98610dd3565b81604052828152876020848701011115610eb157600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610ee357600080fd5b5035919050565b600060208284031215610efc57600080fd5b815161053881610bfb565b60008060408385031215610f1a57600080fd5b82518015158114610f2a57600080fd5b6020840151909250610d6e81610bfb565b81810381811115610597577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI @@ -171,6 +171,28 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorRaw) Transact(o return _TermsOfServiceAllowList.Contract.contract.Transact(opts, method, params...) } +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetAllAllowedSenders(opts *bind.CallOpts) ([]common.Address, error) { + var out []interface{} + err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getAllAllowedSenders") + + if err != nil { + return *new([]common.Address), err + } + + out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) + + return out0, err + +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) GetAllAllowedSenders() ([]common.Address, error) { + return _TermsOfServiceAllowList.Contract.GetAllAllowedSenders(&_TermsOfServiceAllowList.CallOpts) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetAllAllowedSenders() ([]common.Address, error) { + return _TermsOfServiceAllowList.Contract.GetAllAllowedSenders(&_TermsOfServiceAllowList.CallOpts) +} + func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getConfigHash") @@ -237,9 +259,9 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetMessage return _TermsOfServiceAllowList.Contract.GetMessageHash(&_TermsOfServiceAllowList.CallOpts, acceptor, recipient) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) IsAllowedSender(opts *bind.CallOpts, sender common.Address) (bool, error) { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) HasAccess(opts *bind.CallOpts, user common.Address, arg1 []byte) (bool, error) { var out []interface{} - err := _TermsOfServiceAllowList.contract.Call(opts, &out, "isAllowedSender", sender) + err := _TermsOfServiceAllowList.contract.Call(opts, &out, "hasAccess", user, arg1) if err != nil { return *new(bool), err @@ -251,12 +273,12 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) IsAllowedSender(o } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) IsAllowedSender(sender common.Address) (bool, error) { - return _TermsOfServiceAllowList.Contract.IsAllowedSender(&_TermsOfServiceAllowList.CallOpts, sender) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) HasAccess(user common.Address, arg1 []byte) (bool, error) { + return _TermsOfServiceAllowList.Contract.HasAccess(&_TermsOfServiceAllowList.CallOpts, user, arg1) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) IsAllowedSender(sender common.Address) (bool, error) { - return _TermsOfServiceAllowList.Contract.IsAllowedSender(&_TermsOfServiceAllowList.CallOpts, sender) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) HasAccess(user common.Address, arg1 []byte) (bool, error) { + return _TermsOfServiceAllowList.Contract.HasAccess(&_TermsOfServiceAllowList.CallOpts, user, arg1) } func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) IsBlockedSender(opts *bind.CallOpts, sender common.Address) (bool, error) { @@ -487,13 +509,15 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowList) Address() common.Addres } type TermsOfServiceAllowListInterface interface { + GetAllAllowedSenders(opts *bind.CallOpts) ([]common.Address, error) + GetConfigHash(opts *bind.CallOpts) ([32]byte, error) GetEthSignedMessageHash(opts *bind.CallOpts, messageHash [32]byte) ([32]byte, error) GetMessageHash(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) - IsAllowedSender(opts *bind.CallOpts, sender common.Address) (bool, error) + HasAccess(opts *bind.CallOpts, user common.Address, arg1 []byte) (bool, error) IsBlockedSender(opts *bind.CallOpts, sender common.Address) (bool, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 1edf8bddce7..ce06b00d82d 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -32,7 +32,7 @@ var ( var FunctionsRouterMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200641638038062006416833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615d3380620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806371ec28ac1161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d41461078f578063eb523d6c146107a2578063f2fde38b146107b557600080fd5b8063c4614d6114610756578063d7ae1d3014610769578063e72f6e301461077c57600080fd5b8063b5643858116100c8578063b564385814610724578063b734c0f414610737578063badc3eb61461073f57600080fd5b8063a9c9a918146106e0578063aab396bd146106f3578063b187bd261461071957600080fd5b80638fde531711610150578063a21a23e41161012a578063a21a23e4146106a1578063a47c7696146106a9578063a4c0ed36146106cd57600080fd5b80638fde53171461067e5780639883c10d146106865780639f87fad71461068e57600080fd5b806379ba50971161018157806379ba50971461064057806382359740146106485780638da5cb5b1461065b57600080fd5b806371ec28ac146106265780637341c10c1461062d57600080fd5b80633fd67e05116102555780635ed6dfba11610209578063665871ec116101e3578063665871ec14610546578063674603d0146105595780636a6df79b146105ee57600080fd5b80635ed6dfba146104ec57806366316d8d146104ff578063664199701461051257600080fd5b806354fd4d501161023a57806354fd4d501461049657806355fedefa146104c25780635c975abb146104d557600080fd5b80633fd67e051461043c578063461d27621461047557600080fd5b8063181f5a77116102b757806336566f061161029157806336566f061461040e578063385de9ae146104165780633e871e4d1461042957600080fd5b8063181f5a77146103a35780631ded3b36146103e55780632a905ccc146103f857600080fd5b80630c5d49cb116102e85780630c5d49cb1461032c57806310fc49c11461034c57806312b583491461035f57600080fd5b806302bcc5b61461030457806304c357cb14610319575b600080fd5b610317610312366004614c95565b6107c8565b005b610317610327366004614cd4565b610855565b610334608481565b60405161ffff90911681526020015b60405180910390f35b61031761035a366004614d19565b610952565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610343565b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103439190614db4565b6103176103f3366004614dc7565b61095c565b600f546bffffffffffffffffffffffff16610386565b61031761098d565b610317610424366004614e3a565b6109b2565b610317610437366004614f9a565b610b9a565b61044f61044a3660046150fb565b610eb4565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610343565b6104886104833660046151af565b61123d565b604051908152602001610343565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610343565b6104886104d0366004614c95565b611291565b60005460ff165b6040519015158152602001610343565b6103176104fa366004615231565b6112b5565b61031761050d366004615231565b611591565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610343565b61031761055436600461525d565b6117b8565b6105c66105673660046152d2565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610343565b6106016105fc36600461530a565b611b7d565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610343565b6064610334565b61031761063b366004614cd4565b611b90565b610317611d3d565b610317610656366004614c95565b611e5f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610601565b610317611fae565b600754610488565b61031761069c366004614cd4565b61205d565b61052d612465565b6106bc6106b7366004614c95565b6125fe565b604051610343959493929190615380565b6103176106db3660046153d5565b6126ea565b6106016106ee36600461542f565b612919565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610488565b60005460ff166104dc565b610317610732366004615448565b612926565b610317612a85565b610747612c99565b60405161034393929190615463565b6103d8610764366004614e3a565b612d74565b610317610777366004614cd4565b612d89565b61031761078a3660046154c4565b612de2565b6104dc61079d366004614c95565b612ff4565b6103176107b036600461542f565b612fff565b6103176107c33660046154c4565b61326f565b6107d0613280565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680610847576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108518282613288565b5050565b61085d6135f6565b610866826135fe565b61086e6136c4565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108515767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61085182826137b9565b610964613280565b61096d826138d9565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61099561394f565b60005460ff16156109aa576109a86139d5565b565b6109a8613a52565b6109ba61394f565b60006109c7846000613aad565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109f15750600754610a65565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a3e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a6291906154df565b90505b8383604051610a759291906154f8565b60405180910390208103610ab5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610b20906601000000000000900461ffff1643615537565b9052600086815260066020908152604090912082518155908201516001820190610b4a90826155eb565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b8b908790849088908890615705565b60405180910390a15050505050565b610ba261394f565b8151815181141580610bb45750600881115b15610beb576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610d25576000848260ff1681518110610c1057610c10615760565b602002602001015190506000848360ff1681518110610c3157610c31615760565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c9c575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cd3576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610d12576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610d1e9061578f565b9050610bee565b50600954600090610d44906601000000000000900461ffff1643615537565b604080516060810182528681526020808201879052918101839052865192935091600391610d76918391890190614ade565b506020828101518051610d8f9260018501920190614b25565b506040820151816002015590505060005b84518160ff161015610ead577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610de257610de2615760565b602002602001015160026000888560ff1681518110610e0357610e03615760565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e4f57610e4f615760565b602002602001015185604051610e95949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610ea68161578f565b9050610da0565b5050505050565b600080610ebf6135f6565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314611001576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff1661102a576002925050611232565b8060e00151816080015163ffffffff1661104491906157ae565b6effffffffffffffffffffffffffffff165a1015611066576003925050611232565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff909116906110a99063ffffffff16613bad565b6110b390886157dd565b82516110c090889061580d565b6110ca919061580d565b6bffffffffffffffffffffffff1611156110e8576004925050611232565b8060a001516bffffffffffffffffffffffff1661110e826080015163ffffffff16613bad565b61111890886157dd565b825161112590889061580d565b61112f919061580d565b6bffffffffffffffffffffffff16111561114d576005925050611232565b6000898152600e6020526040808220828155600181018390556002018290556080830151908301519194508491611189918c918c918c91613c4f565b805190915061119957600161119c565b60005b935060006111c383606001518460a00151856040015186600001518c87602001518d613dc9565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a83602001518989876000015161120c578e61120e565b8f5b8860400151604051611224959493929190615832565b60405180910390a351925050505b965096945050505050565b60006112868260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915061401b9050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b6112bd613280565b806bffffffffffffffffffffffff166000036112f35750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561134d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d60205260408120805483929061137a9084906bffffffffffffffffffffffff16615890565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113d19190615890565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611470573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061149491906158b5565b61085157600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611507573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061152b91906154df565b6009546040517fa99da302000000000000000000000000000000000000000000000000000000008152710100000000000000000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610d09565b6115996135f6565b806bffffffffffffffffffffffff166000036115e1576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561163b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906116689084906bffffffffffffffffffffffff16615890565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166116bf9190615890565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561175e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061178291906158b5565b610851576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117c06135f6565b60005b81811015611b785760008383838181106117df576117df615760565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e0820152909350919050611902816138d9565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633811461197b576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156119c0576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611a32573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a5691906158b5565b15611b625760a084015167ffffffffffffffff84166000908152600b602052604081206001018054909190611a9a9084906bffffffffffffffffffffffff16615890565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff808816845291529190208054600192600991611b2191859169010000000000000000009004166158d2565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b505050505080611b71906158f3565b90506117c3565b505050565b6000611b898383613aad565b9392505050565b611b986135f6565b611ba1826135fe565b611ba96136c4565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611c1e576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611c65575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610946565b60015473ffffffffffffffffffffffffffffffffffffffff163314611dbe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610d09565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611e676135f6565b611e6f6136c4565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611f0f576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610d09565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611fb661394f565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015612018576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b6120656135f6565b61206e826135fe565b6120766136c4565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152612146576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b806040015167ffffffffffffffff16816020015167ffffffffffffffff161461219b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b602090815260408083206002018054825181850281018501909352808352919290919083018282801561221657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116121eb575b5050505050905060006001825161222d919061592b565b905060005b82518110156123c9578473ffffffffffffffffffffffffffffffffffffffff1683828151811061226457612264615760565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036123b957600083838151811061229b5761229b615760565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106122e1576122e1615760565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061235b5761235b61593e565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506123c9565b6123c2816158f3565b9050612232565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b600061246f6135f6565b6124776136c4565b60098054819061249d906901000000000000000000900467ffffffffffffffff1661596d565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612513578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926125ae92600285019290910190614b25565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061260f866138d9565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126da57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116126af575b5050505050905091939590929450565b6126f26135f6565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612743576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461277d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061278b82840184614c95565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff169186919061283b838561580d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff16612892919061580d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128f99190615537565b6040805192835260208301919091520160405180910390a2505050505050565b60006112af826000613aad565b61292e61394f565b60095461ffff8083166601000000000000909204160361297a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff640100000000909104811690821611156129c6576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff66010000000000009091048116808352908416602083015290918201906129fd9043615537565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a8d61394f565b600554431015612ac9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612adb9061ffff166001615994565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff92831617908190556201000090041615612b4157600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff82161015612c9657600060036000018260ff1681548110612b6c57612b6c615760565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff8616908110612bbb57612bbb615760565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a150505080612c8f9061578f565b9050612b44565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612cf957602002820191906000526020600020905b815481526020019060010190808311612ce5575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612d6257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d37575b50505050509050925092509250909192565b6060612d8184848461447c565b949350505050565b612d916135f6565b612d9a826135fe565b612da26136c4565b612dab82614549565b15610847576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612dea613280565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612e59573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e7d91906154df565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612eea576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610d09565b81811015611b78576000612efe828461592b565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612f79573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f9d91906158b5565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112af82614549565b61300761394f565b600060066000838152602001908152602001600020604051806060016040529081600082015481526020016001820180546130419061554a565b80601f016020809104026020016040519081016040528092919081815260200182805461306d9061554a565b80156130ba5780601f1061308f576101008083540402835291602001916130ba565b820191906000526020600020905b81548152906001019060200180831161309d57829003601f168201915b505050505081526020016002820154815250509050806040015143101561310d576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816131325761311f8160200151614698565b60208082015180519101206007556131da565b61313d826000613aad565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016131799190614db4565b600060405180830381600087803b15801561319357600080fd5b505af19250505080156131a4575060015b6131da576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6009546131f29062010000900461ffff166001615994565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926132639286926159af565b60405180910390a15050565b61327761394f565b612c9681614793565b6109a861394f565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561336957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161333e575b505050918352505060039190910154602090910152805190915060005b82608001515181101561342a57600c6000846080015183815181106133ad576133ad615760565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613423816158f3565b9050613386565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061345c6002830182614b9f565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff1661348f9190615890565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561352e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061355291906158b5565b613588576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b6109a861488e565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613675576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610851576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6136ef7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613aad565b6040517fbe8c97b000000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff919091169063be8c97b0906024016020604051808303816000875af115801561375d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061378191906158b5565b6109a8576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610d09565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110613819576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610d09565b6010805460ff831690811061383057613830615760565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611b78576010805460ff831690811061388057613880615760565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610d09565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612c96576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff1633146109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d09565b6139dd6148fb565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613a5a61488e565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a283390565b600081613aec5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613ae65790506112af565b50613b78565b60005b60035460ff82161015613b76576003805460ff8316908110613b1357613b13615760565b90600052602060002001548403613b66576004805460ff8316908110613b3b57613b3b615760565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112af9050565b613b6f8161578f565b9050613aef565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610d09565b60006bffffffffffffffffffffffff821115613c4b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610d09565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613c9a908990899089906024016159d7565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613d4c57600080fd5b5a611388811015613d5c57600080fd5b611388810390508760408204820311613d7457600080fd5b60008086516020880160008b8df193505a900391503d6084811115613d97575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613de884613bad565b613df290866157dd565b9050600081613e01888661580d565b613e0b919061580d565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613e6291859116615890565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613e9c919061580d565b336000908152600d602052604081208054909190613ec99084906bffffffffffffffffffffffff1661580d565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613f109185911661580d565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613f6491859116615890565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613fe891859169010000000000000000009004166158d2565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60006140256135f6565b61402e856138d9565b6140383386614967565b61404285836137b9565b600061404e8888613aad565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c59161411991600401615a0c565b6080604051808303816000875af1158015614138573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061415c9190615a9f565b92975090945092509050614171338a85614a03565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c081016141e78342615537565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161446696959493929190615add565b60405180910390a4505050509695505050505050565b6060600080808061448f86880188615b41565b935093509350935060006144a88960018787878761401b565b60408051602080825281830190925291925060208201818036833701905050955060005b602081101561453c578181602081106144e7576144e7615760565b1a60f81b8782815181106144fd576144fd615760565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350614535816158f3565b90506144cc565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156145c157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614596575b5050505050905060005b815181101561468e576000600c60008484815181106145ec576145ec615760565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461467d57506001949350505050565b50614687816158f3565b90506145cb565b5060009392505050565b6000806000838060200190518101906146b19190615bb2565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c021781558351959850939650919450909261475c9160109190860190614bbd565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612fe693929190615c9b565b3373ffffffffffffffffffffffffffffffffffffffff821603614812576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d09565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16156109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610d09565b60005460ff166109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610d09565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610851576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b67ffffffffffffffff82166000908152600b602052604081206001018054839290614a3d9084906bffffffffffffffffffffffff1661580d565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614ab39284929004166158d2565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614b19579160200282015b82811115614b19578251825591602001919060010190614afe565b50613c4b929150614c63565b828054828255906000526020600020908101928215614b19579160200282015b82811115614b1957825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614b45565b5080546000825590600052602060002090810190612c969190614c63565b82805482825590600052602060002090600701600890048101928215614b195791602002820160005b83821115614c2a57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614be6565b8015614c5a5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614c2a565b5050613c4b9291505b5b80821115613c4b5760008155600101614c64565b803567ffffffffffffffff81168114614c9057600080fd5b919050565b600060208284031215614ca757600080fd5b611b8982614c78565b803573ffffffffffffffffffffffffffffffffffffffff81168114614c9057600080fd5b60008060408385031215614ce757600080fd5b614cf083614c78565b9150614cfe60208401614cb0565b90509250929050565b63ffffffff81168114612c9657600080fd5b60008060408385031215614d2c57600080fd5b614d3583614c78565b91506020830135614d4581614d07565b809150509250929050565b6000815180845260005b81811015614d7657602081850181015186830182015201614d5a565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611b896020830184614d50565b60008060408385031215614dda57600080fd5b614de383614c78565b946020939093013593505050565b60008083601f840112614e0357600080fd5b50813567ffffffffffffffff811115614e1b57600080fd5b602083019150836020828501011115614e3357600080fd5b9250929050565b600080600060408486031215614e4f57600080fd5b83359250602084013567ffffffffffffffff811115614e6d57600080fd5b614e7986828701614df1565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614efc57614efc614e86565b604052919050565b600067ffffffffffffffff821115614f1e57614f1e614e86565b5060051b60200190565b600082601f830112614f3957600080fd5b81356020614f4e614f4983614f04565b614eb5565b82815260059290921b84018101918181019086841115614f6d57600080fd5b8286015b84811015614f8f57614f8281614cb0565b8352918301918301614f71565b509695505050505050565b60008060408385031215614fad57600080fd5b823567ffffffffffffffff80821115614fc557600080fd5b818501915085601f830112614fd957600080fd5b81356020614fe9614f4983614f04565b82815260059290921b8401810191818101908984111561500857600080fd5b948201945b838610156150265785358252948201949082019061500d565b9650508601359250508082111561503c57600080fd5b5061504985828601614f28565b9150509250929050565b600082601f83011261506457600080fd5b813567ffffffffffffffff81111561507e5761507e614e86565b6150af60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614eb5565b8181528460208386010111156150c457600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612c9657600080fd5b60008060008060008060c0878903121561511457600080fd5b86359550602087013567ffffffffffffffff8082111561513357600080fd5b61513f8a838b01615053565b9650604089013591508082111561515557600080fd5b5061516289828a01615053565b9450506060870135615173816150e1565b92506080870135615183816150e1565b915061519160a08801614cb0565b90509295509295509295565b803561ffff81168114614c9057600080fd5b60008060008060008060a087890312156151c857600080fd5b6151d187614c78565b9550602087013567ffffffffffffffff8111156151ed57600080fd5b6151f989828a01614df1565b909650945061520c90506040880161519d565b9250606087013561521c81614d07565b80925050608087013590509295509295509295565b6000806040838503121561524457600080fd5b61524d83614cb0565b91506020830135614d45816150e1565b6000806020838503121561527057600080fd5b823567ffffffffffffffff8082111561528857600080fd5b818501915085601f83011261529c57600080fd5b8135818111156152ab57600080fd5b8660208260051b85010111156152c057600080fd5b60209290920196919550909350505050565b600080604083850312156152e557600080fd5b6152ee83614cb0565b9150614cfe60208401614c78565b8015158114612c9657600080fd5b6000806040838503121561531d57600080fd5b823591506020830135614d45816152fc565b600081518084526020808501945080840160005b8381101561537557815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615343565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a0608082018190526000906112869083018461532f565b600080600080606085870312156153eb57600080fd5b6153f485614cb0565b935060208501359250604085013567ffffffffffffffff81111561541757600080fd5b61542387828801614df1565b95989497509550505050565b60006020828403121561544157600080fd5b5035919050565b60006020828403121561545a57600080fd5b611b898261519d565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154a457845183529383019391830191600101615488565b505084810360408601526154b8818761532f565b98975050505050505050565b6000602082840312156154d657600080fd5b611b8982614cb0565b6000602082840312156154f157600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112af576112af615508565b600181811c9082168061555e57607f821691505b602082108103615597577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611b7857600081815260208120601f850160051c810160208610156155c45750805b601f850160051c820191505b818110156155e3578281556001016155d0565b505050505050565b815167ffffffffffffffff81111561560557615605614e86565b61561981615613845461554a565b8461559d565b602080601f83116001811461566c57600084156156365750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556155e3565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156156b95788860151825594840194600190910190840161569a565b50858210156156f557878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036157a5576157a5615508565b60010192915050565b6effffffffffffffffffffffffffffff8181168382160190808211156157d6576157d6615508565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461580557615805615508565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156157d6576157d6615508565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061587e60a0830185614d50565b82810360808401526154b88185614d50565b6bffffffffffffffffffffffff8281168282160390808211156157d6576157d6615508565b6000602082840312156158c757600080fd5b8151611b89816152fc565b67ffffffffffffffff8181168382160190808211156157d6576157d6615508565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361592457615924615508565b5060010190565b818103818111156112af576112af615508565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361598a5761598a615508565b6001019392505050565b61ffff8181168382160190808211156157d6576157d6615508565b8381528260208201526060604082015260006159ce6060830184614d50565b95945050505050565b8381526060602082015260006159f06060830185614d50565b8281036040840152615a028185614d50565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e06060840152615a57610100840182614d50565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b60008060008060808587031215615ab557600080fd5b845193506020850151615ac7816150e1565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615b1e60c0830186614d50565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b60008060008060808587031215615b5757600080fd5b615b6085614c78565b9350602085013567ffffffffffffffff811115615b7c57600080fd5b615b8887828801615053565b935050615b976040860161519d565b91506060850135615ba781614d07565b939692955090935050565b600080600060608486031215615bc757600080fd5b8351615bd2816150e1565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615c0a57600080fd5b604086015190935067ffffffffffffffff811115615c2757600080fd5b8501601f81018713615c3857600080fd5b8051615c46614f4982614f04565b81815260059190911b82018301908381019089831115615c6557600080fd5b928401925b82841015615c8c578351615c7d81614d07565b82529284019290840190615c6a565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615d1857845163ffffffff1683529383019391830191600101615cf6565b50909897505050505050505056fea164736f6c6343000813000a", + Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200645738038062006457833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615d7480620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806371ec28ac1161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d41461078f578063eb523d6c146107a2578063f2fde38b146107b557600080fd5b8063c4614d6114610756578063d7ae1d3014610769578063e72f6e301461077c57600080fd5b8063b5643858116100c8578063b564385814610724578063b734c0f414610737578063badc3eb61461073f57600080fd5b8063a9c9a918146106e0578063aab396bd146106f3578063b187bd261461071957600080fd5b80638fde531711610150578063a21a23e41161012a578063a21a23e4146106a1578063a47c7696146106a9578063a4c0ed36146106cd57600080fd5b80638fde53171461067e5780639883c10d146106865780639f87fad71461068e57600080fd5b806379ba50971161018157806379ba50971461064057806382359740146106485780638da5cb5b1461065b57600080fd5b806371ec28ac146106265780637341c10c1461062d57600080fd5b80633fd67e05116102555780635ed6dfba11610209578063665871ec116101e3578063665871ec14610546578063674603d0146105595780636a6df79b146105ee57600080fd5b80635ed6dfba146104ec57806366316d8d146104ff578063664199701461051257600080fd5b806354fd4d501161023a57806354fd4d501461049657806355fedefa146104c25780635c975abb146104d557600080fd5b80633fd67e051461043c578063461d27621461047557600080fd5b8063181f5a77116102b757806336566f061161029157806336566f061461040e578063385de9ae146104165780633e871e4d1461042957600080fd5b8063181f5a77146103a35780631ded3b36146103e55780632a905ccc146103f857600080fd5b80630c5d49cb116102e85780630c5d49cb1461032c57806310fc49c11461034c57806312b583491461035f57600080fd5b806302bcc5b61461030457806304c357cb14610319575b600080fd5b610317610312366004614ca7565b6107c8565b005b610317610327366004614ce6565b610855565b610334608481565b60405161ffff90911681526020015b60405180910390f35b61031761035a366004614d2b565b610952565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610343565b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103439190614dc6565b6103176103f3366004614dd9565b61095c565b600f546bffffffffffffffffffffffff16610386565b61031761098d565b610317610424366004614e4c565b6109b2565b610317610437366004614fac565b610b9a565b61044f61044a36600461510d565b610eb4565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610343565b6104886104833660046151c1565b61123d565b604051908152602001610343565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610343565b6104886104d0366004614ca7565b611291565b60005460ff165b6040519015158152602001610343565b6103176104fa366004615243565b6112b5565b61031761050d366004615243565b611591565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610343565b61031761055436600461526f565b6117b8565b6105c66105673660046152e4565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610343565b6106016105fc36600461531c565b611b7d565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610343565b6064610334565b61031761063b366004614ce6565b611b90565b610317611d3d565b610317610656366004614ca7565b611e5f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610601565b610317611fae565b600754610488565b61031761069c366004614ce6565b61205d565b61052d612465565b6106bc6106b7366004614ca7565b6125fe565b604051610343959493929190615392565b6103176106db3660046153e7565b6126ea565b6106016106ee366004615441565b612919565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610488565b60005460ff166104dc565b61031761073236600461545a565b612926565b610317612a85565b610747612c99565b60405161034393929190615475565b6103d8610764366004614e4c565b612d74565b610317610777366004614ce6565b612d89565b61031761078a3660046154d6565b612de2565b6104dc61079d366004614ca7565b612ff4565b6103176107b0366004615441565b612fff565b6103176107c33660046154d6565b61326f565b6107d0613280565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680610847576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108518282613288565b5050565b61085d6135f6565b610866826135fe565b61086e6136c4565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108515767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61085182826137cb565b610964613280565b61096d826138eb565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b610995613961565b60005460ff16156109aa576109a86139e7565b565b6109a8613a64565b6109ba613961565b60006109c7846000613abf565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109f15750600754610a65565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a3e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a6291906154f1565b90505b8383604051610a7592919061550a565b60405180910390208103610ab5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610b20906601000000000000900461ffff1643615549565b9052600086815260066020908152604090912082518155908201516001820190610b4a90826155fd565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b8b908790849088908890615717565b60405180910390a15050505050565b610ba2613961565b8151815181141580610bb45750600881115b15610beb576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610d25576000848260ff1681518110610c1057610c10615772565b602002602001015190506000848360ff1681518110610c3157610c31615772565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c9c575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cd3576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610d12576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610d1e906157a1565b9050610bee565b50600954600090610d44906601000000000000900461ffff1643615549565b604080516060810182528681526020808201879052918101839052865192935091600391610d76918391890190614af0565b506020828101518051610d8f9260018501920190614b37565b506040820151816002015590505060005b84518160ff161015610ead577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610de257610de2615772565b602002602001015160026000888560ff1681518110610e0357610e03615772565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e4f57610e4f615772565b602002602001015185604051610e95949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610ea6816157a1565b9050610da0565b5050505050565b600080610ebf6135f6565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314611001576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff1661102a576002925050611232565b8060e00151816080015163ffffffff1661104491906157c0565b6effffffffffffffffffffffffffffff165a1015611066576003925050611232565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff909116906110a99063ffffffff16613bbf565b6110b390886157ef565b82516110c090889061581f565b6110ca919061581f565b6bffffffffffffffffffffffff1611156110e8576004925050611232565b8060a001516bffffffffffffffffffffffff1661110e826080015163ffffffff16613bbf565b61111890886157ef565b825161112590889061581f565b61112f919061581f565b6bffffffffffffffffffffffff16111561114d576005925050611232565b6000898152600e6020526040808220828155600181018390556002018290556080830151908301519194508491611189918c918c918c91613c61565b805190915061119957600161119c565b60005b935060006111c383606001518460a00151856040015186600001518c87602001518d613ddb565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a83602001518989876000015161120c578e61120e565b8f5b8860400151604051611224959493929190615844565b60405180910390a351925050505b965096945050505050565b60006112868260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915061402d9050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b6112bd613280565b806bffffffffffffffffffffffff166000036112f35750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561134d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d60205260408120805483929061137a9084906bffffffffffffffffffffffff166158a2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113d191906158a2565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611470573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061149491906158c7565b61085157600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611507573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061152b91906154f1565b6009546040517fa99da302000000000000000000000000000000000000000000000000000000008152710100000000000000000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610d09565b6115996135f6565b806bffffffffffffffffffffffff166000036115e1576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561163b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906116689084906bffffffffffffffffffffffff166158a2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166116bf91906158a2565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561175e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061178291906158c7565b610851576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117c06135f6565b60005b81811015611b785760008383838181106117df576117df615772565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e0820152909350919050611902816138eb565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633811461197b576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156119c0576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611a32573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a5691906158c7565b15611b625760a084015167ffffffffffffffff84166000908152600b602052604081206001018054909190611a9a9084906bffffffffffffffffffffffff166158a2565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff808816845291529190208054600192600991611b2191859169010000000000000000009004166158e4565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b505050505080611b7190615905565b90506117c3565b505050565b6000611b898383613abf565b9392505050565b611b986135f6565b611ba1826135fe565b611ba96136c4565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611c1e576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611c65575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610946565b60015473ffffffffffffffffffffffffffffffffffffffff163314611dbe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610d09565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611e676135f6565b611e6f6136c4565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611f0f576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610d09565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611fb6613961565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015612018576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b6120656135f6565b61206e826135fe565b6120766136c4565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152612146576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b806040015167ffffffffffffffff16816020015167ffffffffffffffff161461219b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b602090815260408083206002018054825181850281018501909352808352919290919083018282801561221657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116121eb575b5050505050905060006001825161222d919061593d565b905060005b82518110156123c9578473ffffffffffffffffffffffffffffffffffffffff1683828151811061226457612264615772565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036123b957600083838151811061229b5761229b615772565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106122e1576122e1615772565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061235b5761235b615950565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506123c9565b6123c281615905565b9050612232565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b600061246f6135f6565b6124776136c4565b60098054819061249d906901000000000000000000900467ffffffffffffffff1661597f565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612513578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926125ae92600285019290910190614b37565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061260f866138eb565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126da57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116126af575b5050505050905091939590929450565b6126f26135f6565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612743576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461277d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061278b82840184614ca7565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff169186919061283b838561581f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff16612892919061581f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128f99190615549565b6040805192835260208301919091520160405180910390a2505050505050565b60006112af826000613abf565b61292e613961565b60095461ffff8083166601000000000000909204160361297a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff640100000000909104811690821611156129c6576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff66010000000000009091048116808352908416602083015290918201906129fd9043615549565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a8d613961565b600554431015612ac9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612adb9061ffff1660016159a6565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff92831617908190556201000090041615612b4157600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff82161015612c9657600060036000018260ff1681548110612b6c57612b6c615772565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff8616908110612bbb57612bbb615772565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a150505080612c8f906157a1565b9050612b44565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612cf957602002820191906000526020600020905b815481526020019060010190808311612ce5575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612d6257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d37575b50505050509050925092509250909192565b6060612d8184848461448e565b949350505050565b612d916135f6565b612d9a826135fe565b612da26136c4565b612dab8261455b565b15610847576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612dea613280565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612e59573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e7d91906154f1565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612eea576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610d09565b81811015611b78576000612efe828461593d565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612f79573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f9d91906158c7565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112af8261455b565b613007613961565b600060066000838152602001908152602001600020604051806060016040529081600082015481526020016001820180546130419061555c565b80601f016020809104026020016040519081016040528092919081815260200182805461306d9061555c565b80156130ba5780601f1061308f576101008083540402835291602001916130ba565b820191906000526020600020905b81548152906001019060200180831161309d57829003601f168201915b505050505081526020016002820154815250509050806040015143101561310d576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816131325761311f81602001516146aa565b60208082015180519101206007556131da565b61313d826000613abf565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016131799190614dc6565b600060405180830381600087803b15801561319357600080fd5b505af19250505080156131a4575060015b6131da576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6009546131f29062010000900461ffff1660016159a6565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926132639286926159c1565b60405180910390a15050565b613277613961565b612c96816147a5565b6109a8613961565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561336957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161333e575b505050918352505060039190910154602090910152805190915060005b82608001515181101561342a57600c6000846080015183815181106133ad576133ad615772565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561342381615905565b9050613386565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061345c6002830182614bb1565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff1661348f91906158a2565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561352e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061355291906158c7565b613588576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b6109a86148a0565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613675576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610851576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6136ef7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613abf565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613752903390602481016159e9565b602060405180830381865afa15801561376f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061379391906158c7565b6109a8576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610d09565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a90811061382b576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610d09565b6010805460ff831690811061384257613842615772565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611b78576010805460ff831690811061389257613892615772565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610d09565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612c96576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff1633146109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d09565b6139ef61490d565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613a6c6148a0565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a3a3390565b600081613afe5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613af85790506112af565b50613b8a565b60005b60035460ff82161015613b88576003805460ff8316908110613b2557613b25615772565b90600052602060002001548403613b78576004805460ff8316908110613b4d57613b4d615772565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112af9050565b613b81816157a1565b9050613b01565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610d09565b60006bffffffffffffffffffffffff821115613c5d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610d09565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613cac90899089908990602401615a18565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613d5e57600080fd5b5a611388811015613d6e57600080fd5b611388810390508760408204820311613d8657600080fd5b60008086516020880160008b8df193505a900391503d6084811115613da9575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613dfa84613bbf565b613e0490866157ef565b9050600081613e13888661581f565b613e1d919061581f565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613e74918591166158a2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613eae919061581f565b336000908152600d602052604081208054909190613edb9084906bffffffffffffffffffffffff1661581f565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613f229185911661581f565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613f76918591166158a2565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613ffa91859169010000000000000000009004166158e4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60006140376135f6565b614040856138eb565b61404a3386614979565b61405485836137cb565b60006140608888613abf565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c59161412b91600401615a4d565b6080604051808303816000875af115801561414a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061416e9190615ae0565b92975090945092509050614183338a85614a15565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c081016141f98342615549565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161447896959493929190615b1e565b60405180910390a4505050509695505050505050565b606060008080806144a186880188615b82565b935093509350935060006144ba8960018787878761402d565b60408051602080825281830190925291925060208201818036833701905050955060005b602081101561454e578181602081106144f9576144f9615772565b1a60f81b87828151811061450f5761450f615772565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061454781615905565b90506144de565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156145d357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116145a8575b5050505050905060005b81518110156146a0576000600c60008484815181106145fe576145fe615772565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461468f57506001949350505050565b5061469981615905565b90506145dd565b5060009392505050565b6000806000838060200190518101906146c39190615bf3565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c021781558351959850939650919450909261476e9160109190860190614bcf565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612fe693929190615cdc565b3373ffffffffffffffffffffffffffffffffffffffff821603614824576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d09565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16156109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610d09565b60005460ff166109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610d09565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610851576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b67ffffffffffffffff82166000908152600b602052604081206001018054839290614a4f9084906bffffffffffffffffffffffff1661581f565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614ac59284929004166158e4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614b2b579160200282015b82811115614b2b578251825591602001919060010190614b10565b50613c5d929150614c75565b828054828255906000526020600020908101928215614b2b579160200282015b82811115614b2b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614b57565b5080546000825590600052602060002090810190612c969190614c75565b82805482825590600052602060002090600701600890048101928215614b2b5791602002820160005b83821115614c3c57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614bf8565b8015614c6c5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614c3c565b5050613c5d9291505b5b80821115613c5d5760008155600101614c76565b803567ffffffffffffffff81168114614ca257600080fd5b919050565b600060208284031215614cb957600080fd5b611b8982614c8a565b803573ffffffffffffffffffffffffffffffffffffffff81168114614ca257600080fd5b60008060408385031215614cf957600080fd5b614d0283614c8a565b9150614d1060208401614cc2565b90509250929050565b63ffffffff81168114612c9657600080fd5b60008060408385031215614d3e57600080fd5b614d4783614c8a565b91506020830135614d5781614d19565b809150509250929050565b6000815180845260005b81811015614d8857602081850181015186830182015201614d6c565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611b896020830184614d62565b60008060408385031215614dec57600080fd5b614df583614c8a565b946020939093013593505050565b60008083601f840112614e1557600080fd5b50813567ffffffffffffffff811115614e2d57600080fd5b602083019150836020828501011115614e4557600080fd5b9250929050565b600080600060408486031215614e6157600080fd5b83359250602084013567ffffffffffffffff811115614e7f57600080fd5b614e8b86828701614e03565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614f0e57614f0e614e98565b604052919050565b600067ffffffffffffffff821115614f3057614f30614e98565b5060051b60200190565b600082601f830112614f4b57600080fd5b81356020614f60614f5b83614f16565b614ec7565b82815260059290921b84018101918181019086841115614f7f57600080fd5b8286015b84811015614fa157614f9481614cc2565b8352918301918301614f83565b509695505050505050565b60008060408385031215614fbf57600080fd5b823567ffffffffffffffff80821115614fd757600080fd5b818501915085601f830112614feb57600080fd5b81356020614ffb614f5b83614f16565b82815260059290921b8401810191818101908984111561501a57600080fd5b948201945b838610156150385785358252948201949082019061501f565b9650508601359250508082111561504e57600080fd5b5061505b85828601614f3a565b9150509250929050565b600082601f83011261507657600080fd5b813567ffffffffffffffff81111561509057615090614e98565b6150c160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614ec7565b8181528460208386010111156150d657600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612c9657600080fd5b60008060008060008060c0878903121561512657600080fd5b86359550602087013567ffffffffffffffff8082111561514557600080fd5b6151518a838b01615065565b9650604089013591508082111561516757600080fd5b5061517489828a01615065565b9450506060870135615185816150f3565b92506080870135615195816150f3565b91506151a360a08801614cc2565b90509295509295509295565b803561ffff81168114614ca257600080fd5b60008060008060008060a087890312156151da57600080fd5b6151e387614c8a565b9550602087013567ffffffffffffffff8111156151ff57600080fd5b61520b89828a01614e03565b909650945061521e9050604088016151af565b9250606087013561522e81614d19565b80925050608087013590509295509295509295565b6000806040838503121561525657600080fd5b61525f83614cc2565b91506020830135614d57816150f3565b6000806020838503121561528257600080fd5b823567ffffffffffffffff8082111561529a57600080fd5b818501915085601f8301126152ae57600080fd5b8135818111156152bd57600080fd5b8660208260051b85010111156152d257600080fd5b60209290920196919550909350505050565b600080604083850312156152f757600080fd5b61530083614cc2565b9150614d1060208401614c8a565b8015158114612c9657600080fd5b6000806040838503121561532f57600080fd5b823591506020830135614d578161530e565b600081518084526020808501945080840160005b8381101561538757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615355565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061128690830184615341565b600080600080606085870312156153fd57600080fd5b61540685614cc2565b935060208501359250604085013567ffffffffffffffff81111561542957600080fd5b61543587828801614e03565b95989497509550505050565b60006020828403121561545357600080fd5b5035919050565b60006020828403121561546c57600080fd5b611b89826151af565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154b65784518352938301939183019160010161549a565b505084810360408601526154ca8187615341565b98975050505050505050565b6000602082840312156154e857600080fd5b611b8982614cc2565b60006020828403121561550357600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112af576112af61551a565b600181811c9082168061557057607f821691505b6020821081036155a9577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611b7857600081815260208120601f850160051c810160208610156155d65750805b601f850160051c820191505b818110156155f5578281556001016155e2565b505050505050565b815167ffffffffffffffff81111561561757615617614e98565b61562b81615625845461555c565b846155af565b602080601f83116001811461567e57600084156156485750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556155f5565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156156cb578886015182559484019460019091019084016156ac565b508582101561570757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036157b7576157b761551a565b60010192915050565b6effffffffffffffffffffffffffffff8181168382160190808211156157e8576157e861551a565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146158175761581761551a565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156157e8576157e861551a565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061589060a0830185614d62565b82810360808401526154ca8185614d62565b6bffffffffffffffffffffffff8281168282160390808211156157e8576157e861551a565b6000602082840312156158d957600080fd5b8151611b898161530e565b67ffffffffffffffff8181168382160190808211156157e8576157e861551a565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036159365761593661551a565b5060010190565b818103818111156112af576112af61551a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361599c5761599c61551a565b6001019392505050565b61ffff8181168382160190808211156157e8576157e861551a565b8381528260208201526060604082015260006159e06060830184614d62565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612d816040830184614d62565b838152606060208201526000615a316060830185614d62565b8281036040840152615a438185614d62565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e06060840152615a98610100840182614d62565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b60008060008060808587031215615af657600080fd5b845193506020850151615b08816150f3565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615b5f60c0830186614d62565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b60008060008060808587031215615b9857600080fd5b615ba185614c8a565b9350602085013567ffffffffffffffff811115615bbd57600080fd5b615bc987828801615065565b935050615bd8604086016151af565b91506060850135615be881614d19565b939692955090935050565b600080600060608486031215615c0857600080fd5b8351615c13816150f3565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615c4b57600080fd5b604086015190935067ffffffffffffffff811115615c6857600080fd5b8501601f81018713615c7957600080fd5b8051615c87614f5b82614f16565b81815260059190911b82018301908381019089831115615ca657600080fd5b928401925b82841015615ccd578351615cbe81614d19565b82529284019290840190615cab565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615d5957845163ffffffff1683529383019391830191600101615d37565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index fd4d7384cdc..a168583fff8 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,10 +1,10 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 58333476259ad385d98bb1eaccbd6f91d79feda86dcc90e30edb21f38f150cbe +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin b549b681bdc14eb3dd40422acf253c07cf58d62088539ecfe42ddb01d48d508a functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 36b045452a98ac0c845d1e23017dd19eac560177a5b51d85ea1bfed314907141 -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin cf271fe0d9111ce6f506cdea64ef80a19cdb89ec53574c15e1094a5084e356ea +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 2a8755a8915af6b28efb73e51cc36c8050877800995bd376975b61441c791c45 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index e61032335dd..4e732e143b7 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -111,7 +111,7 @@ func SetOracleConfig(t *testing.T, owner *bind.TransactOpts, coordinatorContract } func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToken *link_token_interface.LinkToken, routerContractAddress common.Address, routerContract *functions_router.FunctionsRouter, clientContracts []deployedClientContract, allowListContract *functions_allow_list.TermsOfServiceAllowList) (subscriptionId uint64) { - allowed, err := allowListContract.IsAllowedSender(nilOpts, owner.From) + allowed, err := allowListContract.HasAccess(nilOpts, owner.From, []byte{}) require.NoError(t, err) if allowed == false { messageHash, err := allowListContract.GetMessageHash(nilOpts, owner.From, owner.From) From cb0958b7f89f941acd235eb49603cde8d0cea6fe Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sun, 30 Jul 2023 19:10:33 -0700 Subject: [PATCH 039/270] [Functions] Allowlist v1 (#9993) --- .../gateway/handlers/functions/allowlist.go | 49 ++++++++++++++++--- .../handlers/functions/allowlist_test.go | 43 +++++++++------- 2 files changed, 66 insertions(+), 26 deletions(-) diff --git a/core/services/gateway/handlers/functions/allowlist.go b/core/services/gateway/handlers/functions/allowlist.go index 0ba679f3e88..f05738ade40 100644 --- a/core/services/gateway/handlers/functions/allowlist.go +++ b/core/services/gateway/handlers/functions/allowlist.go @@ -13,6 +13,7 @@ import ( "github.com/pkg/errors" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_allow_list" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" @@ -22,6 +23,7 @@ import ( type OnchainAllowlistConfig struct { // ContractAddress is required ContractAddress common.Address `json:"contractAddress"` + ContractVersion uint32 `json:"contractVersion"` BlockConfirmations uint `json:"blockConfirmations"` // UpdateFrequencySec can be zero to disable periodic updates UpdateFrequencySec uint `json:"updateFrequencySec"` @@ -29,7 +31,8 @@ type OnchainAllowlistConfig struct { } // OnchainAllowlist maintains an allowlist of addresses fetched from the blockchain (EVM-only). -// Use UpdateFromContract() for a one-time update or set OnchainAllowlistConfig.UpdateFrequencySec for period updates. +// Use UpdateFromContract() for a one-time update or set OnchainAllowlistConfig.UpdateFrequencySec +// for repeated updates. // All methods are thread-safe. // //go:generate mockery --quiet --name OnchainAllowlist --output ./mocks/ --case=underscore @@ -46,7 +49,8 @@ type onchainAllowlist struct { config OnchainAllowlistConfig allowlist atomic.Pointer[map[common.Address]struct{}] client evmclient.Client - contract *ocr2dr_oracle.OCR2DROracle + contractV0 *ocr2dr_oracle.OCR2DROracle + contractV1 *functions_allow_list.TermsOfServiceAllowList blockConfirmations *big.Int lggr logger.Logger closeWait sync.WaitGroup @@ -60,14 +64,19 @@ func NewOnchainAllowlist(client evmclient.Client, config OnchainAllowlistConfig, if lggr == nil { return nil, errors.New("logger is nil") } - contract, err := ocr2dr_oracle.NewOCR2DROracle(config.ContractAddress, client) + contractV0, err := ocr2dr_oracle.NewOCR2DROracle(config.ContractAddress, client) if err != nil { return nil, fmt.Errorf("unexpected error during NewOCR2DROracle: %s", err) } + contractV1, err := functions_allow_list.NewTermsOfServiceAllowList(config.ContractAddress, client) + if err != nil { + return nil, fmt.Errorf("unexpected error during functions_router.NewFunctionsRouter: %s", err) + } allowlist := &onchainAllowlist{ config: config, client: client, - contract: contract, + contractV0: contractV0, + contractV1: contractV1, blockConfirmations: big.NewInt(int64(config.BlockConfirmations)), lggr: lggr.Named("OnchainAllowlist"), stopCh: make(utils.StopChan), @@ -137,7 +146,30 @@ func (a *onchainAllowlist) UpdateFromContract(ctx context.Context) error { return errors.New("LatestBlockHeight returned nil") } blockNum := big.NewInt(0).Sub(latestBlockHeight, a.blockConfirmations) - addrList, err := a.contract.GetAuthorizedSenders(&bind.CallOpts{ + if a.config.ContractVersion == 0 { + return a.updateFromContractV0(ctx, blockNum) + } else if a.config.ContractVersion == 1 { + return a.updateFromContractV1(ctx, blockNum) + } else { + return fmt.Errorf("unknown contract version %d", a.config.ContractVersion) + } +} + +func (a *onchainAllowlist) updateFromContractV0(ctx context.Context, blockNum *big.Int) error { + addrList, err := a.contractV0.GetAuthorizedSenders(&bind.CallOpts{ + Pending: false, + BlockNumber: blockNum, + Context: ctx, + }) + if err != nil { + return errors.Wrap(err, "error calling GetAuthorizedSenders") + } + a.update(addrList) + return nil +} + +func (a *onchainAllowlist) updateFromContractV1(ctx context.Context, blockNum *big.Int) error { + addrList, err := a.contractV1.GetAllAllowedSenders(&bind.CallOpts{ Pending: false, BlockNumber: blockNum, Context: ctx, @@ -145,11 +177,14 @@ func (a *onchainAllowlist) UpdateFromContract(ctx context.Context) error { if err != nil { return errors.Wrap(err, "error calling GetAuthorizedSenders") } + a.update(addrList) + return nil +} +func (a *onchainAllowlist) update(addrList []common.Address) { newAllowlist := make(map[common.Address]struct{}) for _, addr := range addrList { newAllowlist[addr] = struct{}{} } a.allowlist.Store(&newAllowlist) - a.lggr.Infow("allowlist updated successfully", "len", len(addrList), "blockNumber", blockNum) - return nil + a.lggr.Infow("allowlist updated successfully", "len", len(addrList)) } diff --git a/core/services/gateway/handlers/functions/allowlist_test.go b/core/services/gateway/handlers/functions/allowlist_test.go index e8c5a5f662a..9ec6ef30457 100644 --- a/core/services/gateway/handlers/functions/allowlist_test.go +++ b/core/services/gateway/handlers/functions/allowlist_test.go @@ -39,27 +39,31 @@ func sampleEncodedAllowlist(t *testing.T) []byte { func TestAllowlist_UpdateAndCheck(t *testing.T) { t.Parallel() - client := mocks.NewClient(t) - client.On("LatestBlockHeight", mock.Anything).Return(big.NewInt(42), nil) - client.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(sampleEncodedAllowlist(t), nil) - config := functions.OnchainAllowlistConfig{ - ContractAddress: common.Address{}, - BlockConfirmations: 1, - } - allowlist, err := functions.NewOnchainAllowlist(client, config, logger.TestLogger(t)) - require.NoError(t, err) + for _, version := range []uint32{0, 1} { + client := mocks.NewClient(t) + client.On("LatestBlockHeight", mock.Anything).Return(big.NewInt(42), nil) + // both contract versions have the same return type + client.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(sampleEncodedAllowlist(t), nil) + config := functions.OnchainAllowlistConfig{ + ContractVersion: version, + ContractAddress: common.Address{}, + BlockConfirmations: 1, + } + allowlist, err := functions.NewOnchainAllowlist(client, config, logger.TestLogger(t)) + require.NoError(t, err) - err = allowlist.Start(testutils.Context(t)) - require.NoError(t, err) - t.Cleanup(func() { - assert.NoError(t, allowlist.Close()) - }) + err = allowlist.Start(testutils.Context(t)) + require.NoError(t, err) + t.Cleanup(func() { + assert.NoError(t, allowlist.Close()) + }) - require.NoError(t, allowlist.UpdateFromContract(testutils.Context(t))) - require.False(t, allowlist.Allow(common.Address{})) - require.True(t, allowlist.Allow(common.HexToAddress(addr1))) - require.True(t, allowlist.Allow(common.HexToAddress(addr2))) - require.False(t, allowlist.Allow(common.HexToAddress(addr3))) + require.NoError(t, allowlist.UpdateFromContract(testutils.Context(t))) + require.False(t, allowlist.Allow(common.Address{})) + require.True(t, allowlist.Allow(common.HexToAddress(addr1))) + require.True(t, allowlist.Allow(common.HexToAddress(addr2))) + require.False(t, allowlist.Allow(common.HexToAddress(addr3))) + } } func TestAllowlist_UpdatePeriodically(t *testing.T) { @@ -73,6 +77,7 @@ func TestAllowlist_UpdatePeriodically(t *testing.T) { }).Return(sampleEncodedAllowlist(t), nil) config := functions.OnchainAllowlistConfig{ ContractAddress: common.Address{}, + ContractVersion: 0, BlockConfirmations: 1, UpdateFrequencySec: 1, UpdateTimeoutSec: 1, From 00500b1fa0e7c6b80549a0579c09e18060931fd6 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sun, 30 Jul 2023 19:53:40 -0700 Subject: [PATCH 040/270] [Functions] Listener: support router contracts via LogPollerWrapper (#9992) Partial credit goes to @justinkaseman - this PR re-uses parts of PR #9979. --- core/services/functions/listener.go | 111 +++++++++++------- .../ocr2/plugins/functions/config/config.go | 39 +++--- .../v1/functions_integration_test.go | 5 +- .../v1/internal/testconstants.go | 1 + .../v1/internal/testutils.go | 18 +-- .../relay/evm/functions/logpoller_wrapper.go | 3 - 6 files changed, 100 insertions(+), 77 deletions(-) diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index 96fe37f7506..ca168b6aa13 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -205,24 +205,11 @@ func (l *FunctionsListener) Start(context.Context) error { }, MinIncomingConfirmations: l.pluginConfig.MinIncomingConfirmations, }) + l.shutdownWaitGroup.Add(1) + go l.processOracleEventsV0() case 1: - // TODO: Utilize Log Poller here instead to listen to: - // - Router.getContractById(PluginConfig.DONId, false) = current route - // - Router.getContractById(PluginConfig.DONId, false) = proposed route - // If current = proposed, only listen to current - coordinatorContract, err := functions_coordinator.NewFunctionsCoordinator(contractAddress, l.client) - if err != nil { - return err - } - unsubscribeLogs = l.logBroadcaster.Register(l, log.ListenerOpts{ - Contract: coordinatorContract.Address(), - ParseLog: coordinatorContract.ParseLog, - LogsWithTopics: map[common.Hash][][]log.Topic{ - functions_coordinator.FunctionsCoordinatorOracleRequest{}.Topic(): {}, - functions_coordinator.FunctionsCoordinatorOracleResponse{}.Topic(): {}, - }, - MinIncomingConfirmations: l.pluginConfig.MinIncomingConfirmations, - }) + l.shutdownWaitGroup.Add(1) + go l.processOracleEventsV1() default: return errors.New("Functions: unsupported PluginConfig.ContractVersion") } @@ -230,13 +217,14 @@ func (l *FunctionsListener) Start(context.Context) error { if l.pluginConfig.ListenerEventHandlerTimeoutSec == 0 { l.logger.Warn("listenerEventHandlerTimeoutSec set to zero! ORM calls will never time out.") } - l.shutdownWaitGroup.Add(4) - go l.processOracleEvents() + l.shutdownWaitGroup.Add(3) go l.timeoutRequests() go l.pruneRequests() go func() { <-l.chStop - unsubscribeLogs() + if unsubscribeLogs != nil { + unsubscribeLogs() // v0 only + } l.shutdownWaitGroup.Done() }() @@ -281,7 +269,7 @@ func (l *FunctionsListener) JobID() int32 { return l.job.ID } -func (l *FunctionsListener) processOracleEvents() { +func (l *FunctionsListener) processOracleEventsV0() { defer l.shutdownWaitGroup.Done() for { select { @@ -321,27 +309,17 @@ func (l *FunctionsListener) processOracleEvents() { case *ocr2dr_oracle.OCR2DROracleOracleResponse: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleResponse").Inc() l.shutdownWaitGroup.Add(1) - go l.handleOracleResponse("OracleResponse", log.RequestId, lb) + go l.handleOracleResponseV0("OracleResponse", log.RequestId, lb) case *ocr2dr_oracle.OCR2DROracleUserCallbackError: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "UserCallbackError").Inc() l.shutdownWaitGroup.Add(1) - go l.handleOracleResponse("UserCallbackError", log.RequestId, lb) + go l.handleOracleResponseV0("UserCallbackError", log.RequestId, lb) case *ocr2dr_oracle.OCR2DROracleUserCallbackRawError: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "UserCallbackRawError").Inc() l.shutdownWaitGroup.Add(1) - go l.handleOracleResponse("UserCallbackRawError", log.RequestId, lb) + go l.handleOracleResponseV0("UserCallbackRawError", log.RequestId, lb) case *ocr2dr_oracle.OCR2DROracleResponseTransmitted: promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "ResponseTransmitted").Inc() - // Version 1 - case *functions_coordinator.FunctionsCoordinatorOracleRequest: - promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleRequest").Inc() - l.shutdownWaitGroup.Add(1) - go l.HandleOracleRequestV1(log, lb) - case *functions_coordinator.FunctionsCoordinatorOracleResponse: - promOracleEvent.WithLabelValues(log.Raw.Address.Hex(), "OracleResponse").Inc() - l.shutdownWaitGroup.Add(1) - go l.handleOracleResponse("OracleResponse", log.RequestId, lb) - // TODO: handle other events default: l.logger.Warnf("Unexpected log type %T", log) } @@ -350,6 +328,40 @@ func (l *FunctionsListener) processOracleEvents() { } } +func (l *FunctionsListener) processOracleEventsV1() { + defer l.shutdownWaitGroup.Done() + freqMillis := l.pluginConfig.ListenerEventsCheckFrequencyMillis + if freqMillis == 0 { + l.logger.Errorw("ListenerEventsCheckFrequencyMillis must set to more than 0 in PluginConfig") + return + } + ticker := time.NewTicker(time.Duration(freqMillis) * time.Millisecond) + defer ticker.Stop() + for { + select { + case <-l.chStop: + return + case <-ticker.C: + requests, responses, err := l.logPollerWrapper.LatestEvents() + if err != nil { + l.logger.Errorw("error when calling LatestEvents()", "err", err) + break + } + l.logger.Debugw("processOracleEventsV1: processing v1 events", "nRequests", len(requests), "nResponses", len(responses)) + for _, request := range requests { + request := request + l.shutdownWaitGroup.Add(1) + go l.handleOracleRequestV1(&request) + } + for _, response := range responses { + response := response + l.shutdownWaitGroup.Add(1) + go l.handleOracleResponseV1(&response) + } + } + } +} + func (l *FunctionsListener) getNewHandlerContext() (context.Context, context.CancelFunc) { timeoutSec := l.pluginConfig.ListenerEventHandlerTimeoutSec if timeoutSec == 0 { @@ -386,32 +398,29 @@ func (l *FunctionsListener) getMaxSecretsSize(flags RequestFlags) uint32 { return l.pluginConfig.MaxSecretsSizesList[idx] } -// TODO (FUN-662): call from LogPoller in a separate goroutine -func (l *FunctionsListener) HandleOracleRequestV1(request *functions_coordinator.FunctionsCoordinatorOracleRequest, lb log.Broadcast) { +func (l *FunctionsListener) handleOracleRequestV1(request *evmrelayTypes.OracleRequest) { defer l.shutdownWaitGroup.Done() - l.logger.Infow("oracle request v1 received", "requestID", formatRequestId(request.RequestId)) + l.logger.Infow("handleOracleRequestV1: oracle request v1 received", "requestID", formatRequestId(request.RequestId)) ctx, cancel := l.getNewHandlerContext() defer cancel() callbackGasLimit := uint32(request.CallbackGasLimit) newReq := &Request{ RequestID: request.RequestId, - RequestTxHash: &request.Raw.TxHash, + RequestTxHash: &request.TxHash, ReceivedAt: time.Now(), Flags: request.Flags[:], CallbackGasLimit: &callbackGasLimit, - CoordinatorContractAddress: &request.Raw.Address, + CoordinatorContractAddress: &request.CoordinatorContract, } if err := l.pluginORM.CreateRequest(newReq, pg.WithParentCtx(ctx)); err != nil { if errors.Is(err, ErrDuplicateRequestID) { - l.logger.Warnw("received a log with duplicate request ID", "requestID", formatRequestId(request.RequestId), "err", err) - l.markLogConsumed(lb, pg.WithParentCtx(ctx)) + l.logger.Warnw("handleOracleRequestV1: received a log with duplicate request ID", "requestID", formatRequestId(request.RequestId), "err", err) } else { - l.logger.Errorw("failed to create a DB entry for new request", "requestID", formatRequestId(request.RequestId), "err", err) + l.logger.Errorw("handleOracleRequestV1: failed to create a DB entry for new request", "requestID", formatRequestId(request.RequestId), "err", err) } return } - l.markLogConsumed(lb, pg.WithParentCtx(ctx)) promRequestDataSize.WithLabelValues(l.contractAddressHex).Observe(float64(len(request.Data))) requestData, err := l.parseCBOR(request.RequestId, request.Data, l.getMaxCBORsize(request.Flags)) @@ -536,7 +545,19 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID Request } } -func (l *FunctionsListener) handleOracleResponse(responseType string, requestID [32]byte, lb log.Broadcast) { +func (l *FunctionsListener) handleOracleResponseV1(response *evmrelayTypes.OracleResponse) { + defer l.shutdownWaitGroup.Done() + l.logger.Infow("oracle response v1 received", "requestID", formatRequestId(response.RequestId)) + + ctx, cancel := l.getNewHandlerContext() + defer cancel() + if err := l.pluginORM.SetConfirmed(response.RequestId, pg.WithParentCtx(ctx)); err != nil { + l.logger.Errorw("setting CONFIRMED state failed", "requestID", formatRequestId(response.RequestId), "err", err) + } + promRequestConfirmed.WithLabelValues(l.contractAddressHex, "OracleResponse").Inc() +} + +func (l *FunctionsListener) handleOracleResponseV0(responseType string, requestID [32]byte, lb log.Broadcast) { defer l.shutdownWaitGroup.Done() l.logger.Infow("oracle response received", "type", responseType, "requestID", formatRequestId(requestID)) @@ -650,7 +671,7 @@ func (l *FunctionsListener) reportSourceCodeDomains(requestId RequestID, domains func (l *FunctionsListener) getSecrets(ctx context.Context, eaClient ExternalAdapterClient, requestID string, subscriptionOwner common.Address, requestData *RequestData) (decryptedSecrets string, userError, internalError error) { if l.decryptor == nil { - l.logger.Errorf("Decryptor not configured") + l.logger.Warn("Decryptor not configured") return "", nil, nil } diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index 1f20b6a833a..42feaeb8d6d 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -19,25 +19,26 @@ import ( // This config is part of the job spec and is loaded only once on node boot/job creation. type PluginConfig struct { - DONId string `json:"donId"` - ContractVersion uint32 `json:"contractVersion"` - MinIncomingConfirmations uint32 `json:"minIncomingConfirmations"` - RequestTimeoutSec uint32 `json:"requestTimeoutSec"` - RequestTimeoutCheckFrequencySec uint32 `json:"requestTimeoutCheckFrequencySec"` - RequestTimeoutBatchLookupSize uint32 `json:"requestTimeoutBatchLookupSize"` - PruneMaxStoredRequests uint32 `json:"pruneMaxStoredRequests"` - PruneCheckFrequencySec uint32 `json:"pruneCheckFrequencySec"` - PruneBatchSize uint32 `json:"pruneBatchSize"` - ListenerEventHandlerTimeoutSec uint32 `json:"listenerEventHandlerTimeoutSec"` - ContractUpdateCheckFrequencySec uint32 `json:"contractUpdateCheckFrequencySec"` - MaxRequestSizeBytes uint32 `json:"maxRequestSizeBytes"` - MaxRequestSizesList []uint32 `json:"maxRequestSizesList"` - MaxSecretsSizesList []uint32 `json:"maxSecretsSizesList"` - GatewayConnectorConfig *connector.ConnectorConfig `json:"gatewayConnectorConfig"` - OnchainAllowlist *functions.OnchainAllowlistConfig `json:"onchainAllowlist"` - RateLimiter *common.RateLimiterConfig `json:"rateLimiter"` - S4Constraints *s4.Constraints `json:"s4Constraints"` - DecryptionQueueConfig *DecryptionQueueConfig `json:"decryptionQueueConfig"` + DONId string `json:"donId"` + ContractVersion uint32 `json:"contractVersion"` + MinIncomingConfirmations uint32 `json:"minIncomingConfirmations"` + RequestTimeoutSec uint32 `json:"requestTimeoutSec"` + RequestTimeoutCheckFrequencySec uint32 `json:"requestTimeoutCheckFrequencySec"` + RequestTimeoutBatchLookupSize uint32 `json:"requestTimeoutBatchLookupSize"` + PruneMaxStoredRequests uint32 `json:"pruneMaxStoredRequests"` + PruneCheckFrequencySec uint32 `json:"pruneCheckFrequencySec"` + PruneBatchSize uint32 `json:"pruneBatchSize"` + ListenerEventHandlerTimeoutSec uint32 `json:"listenerEventHandlerTimeoutSec"` + ListenerEventsCheckFrequencyMillis uint32 `json:"listenerEventsCheckFrequencyMillis"` + ContractUpdateCheckFrequencySec uint32 `json:"contractUpdateCheckFrequencySec"` + MaxRequestSizeBytes uint32 `json:"maxRequestSizeBytes"` + MaxRequestSizesList []uint32 `json:"maxRequestSizesList"` + MaxSecretsSizesList []uint32 `json:"maxSecretsSizesList"` + GatewayConnectorConfig *connector.ConnectorConfig `json:"gatewayConnectorConfig"` + OnchainAllowlist *functions.OnchainAllowlistConfig `json:"onchainAllowlist"` + RateLimiter *common.RateLimiterConfig `json:"rateLimiter"` + S4Constraints *s4.Constraints `json:"s4Constraints"` + DecryptionQueueConfig *DecryptionQueueConfig `json:"decryptionQueueConfig"` } type DecryptionQueueConfig struct { diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index f6f8d119e3a..366605f4918 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -10,12 +10,13 @@ import ( var ( // a batch of 8 max-length results uses around 2M gas (assuming 70k gas per client callback - see FunctionsClientExample.sol) + // TODO: revisit gas limit vs batch sizing once necessary contract changes are made nOracleNodes = 4 nClients = 50 requestLenBytes = 1_000 maxGas = 2_000_000 maxTotalReportGas = 560_000 - batchSize = 8 + batchSize = 2 ) func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { @@ -26,7 +27,7 @@ func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { utils.SetupRouterRoutes(t, owner, routerContract, coordinatorContractAddress, allowListContractAddress) b.Commit() - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, coordinatorContractAddress, 39989, nOracleNodes, maxGas, nil, nil) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, coordinatorContractAddress, 39989, nOracleNodes, maxGas, nil, nil) pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go index 07aca3b2e77..3a5cad74003 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go @@ -7,6 +7,7 @@ var ( DefaultSecretsUrlsBase64 = "AQID" DefaultArg1 = "arg1" DefaultArg2 = "arg2" + DefaultDONId = "1" // This has been generated using the Functions Toolkit (https://github.com/smartcontractkit/functions-toolkit/blob/main/src/SecretsManager.ts) and decrypts to the JSON string `{"0x0":"qrvM"}` DefaultThresholdSecretsHex = "0x7b225444483243747874223a2265794a48636d393163434936496c41794e5459694c434a44496a6f69533035305a5559325448593056553168543341766148637955584a4b65545a68626b3177527939794f464e78576a59356158646d636a6c4f535430694c434a4d59574a6c62434936496b464251554642515546425155464251554642515546425155464251554642515546425155464251554642515546425155464251554642515545394969776956534936496b4a45536c6c7a51334e7a623055334d6e6444574846474e557056634770585a573157596e565265544d796431526d4d32786c636c705a647a4671536e6c47627a5256615735744e6d773355456855546e6b7962324e746155686f626c51354d564a6a4e6e5230656c70766147644255326372545430694c434a5658324a6863694936496b4a4961544e69627a5a45536d396a4d324d344d6c46614d5852724c325645536b4a484d336c5a556d783555306834576d684954697472623264575a306f33546e4e456232314b5931646853544979616d63305657644f556c526e57465272655570325458706952306c4a617a466e534851314f4430694c434a46496a6f694d7a524956466c354d544e474b307836596e5a584e7a6c314d6d356c655574514e6b397a656e467859335253513239705a315534534652704e4430694c434a47496a6f69557a5132596d6c6952545a584b314176546d744252445677575459796148426862316c6c6330684853556869556c56614e303155556c6f345554306966513d3d222c2253796d43747874223a2253764237652f4a556a552b433358757873384e5378316967454e517759755051623730306a4a6144222c224e6f6e6365223a224d31714b557a6b306b77374767593538227d" diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 4e732e143b7..f7fd1bcc444 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -323,7 +323,7 @@ func SetupRouterRoutes(t *testing.T, owner *bind.TransactOpts, routerContract *f allowListId, err := routerContract.GetAllowListId(nilOpts) require.NoError(t, err) var donId [32]byte - copy(donId[:], "1") + copy(donId[:], DefaultDONId) proposedContractSetIds := []([32]byte){allowListId, donId} proposedContractSetAddresses := []common.Address{allowListAddress, coordinatorAddress} _, err = routerContract.ProposeContractsUpdate(owner, proposedContractSetIds, proposedContractSetAddresses) @@ -463,8 +463,6 @@ func AddOCR2Job(t *testing.T, app *cltest.TestApplication, contractAddress commo Name: "ea_bridge", URL: models.WebURL(*u), })) - var donId []byte - copy(donId[:], "1") job, err := validate.ValidatedOracleSpecToml(app.Config.OCR2(), app.Config.Insecure(), fmt.Sprintf(` type = "offchainreporting2" name = "functions-node" @@ -493,7 +491,9 @@ func AddOCR2Job(t *testing.T, app *cltest.TestApplication, contractAddress commo requestTimeoutCheckFrequencySec = 10 requestTimeoutBatchLookupSize = 20 listenerEventHandlerTimeoutSec = 120 + listenerEventsCheckFrequencyMillis = 1000 maxRequestSizeBytes = 30720 + contractUpdateCheckFrequencySec = 1 [pluginConfig.decryptionQueueConfig] completedCacheTimeoutSec = 300 @@ -505,7 +505,7 @@ func AddOCR2Job(t *testing.T, app *cltest.TestApplication, contractAddress commo [pluginConfig.s4Constraints] maxPayloadSizeBytes = 10_1000 maxSlotsPerUser = 10 - `, contractAddress, keyBundleID, transmitter, hex.EncodeToString(donId))) + `, contractAddress, keyBundleID, transmitter, DefaultDONId)) require.NoError(t, err) err = app.AddJobV2(testutils.Context(t), &job) require.NoError(t, err) @@ -573,7 +573,8 @@ func CreateFunctionsNodes( t *testing.T, owner *bind.TransactOpts, b *backends.SimulatedBackend, - coordinatorContractAddress common.Address, + routerAddress common.Address, + coordinatorAddress common.Address, startingPort uint16, nOracleNodes int, maxGas int, @@ -593,7 +594,8 @@ func CreateFunctionsNodes( } bootstrapNode = StartNewNode(t, owner, startingPort, "bootstrap", b, uint32(maxGas), nil, nil, "") - AddBootstrapJob(t, bootstrapNode.App, coordinatorContractAddress) + // TODO(FUN-696): refactor bootstrap job to support Functions relayers + AddBootstrapJob(t, bootstrapNode.App, coordinatorAddress) // oracle nodes with jobs, bridges and mock EAs for i := 0; i < nOracleNodes; i++ { @@ -618,7 +620,7 @@ func CreateFunctionsNodes( ea := StartNewMockEA(t) t.Cleanup(ea.Close) - _ = AddOCR2Job(t, oracleNodes[i], coordinatorContractAddress, oracleNode.Keybundle.ID(), oracleNode.Transmitter, ea.URL) + _ = AddOCR2Job(t, oracleNodes[i], routerAddress, oracleNode.Keybundle.ID(), oracleNode.Transmitter, ea.URL) } return bootstrapNode, oracleNodes, oracleIdentites @@ -639,7 +641,7 @@ func ClientTestRequests( ) { t.Helper() var donId [32]byte - copy(donId[:], "1") + copy(donId[:], []byte(DefaultDONId)) subscriptionId := CreateAndFundSubscriptions(t, owner, linkToken, routerAddress, routerContract, clientContracts, allowListContract) // send requests requestSources := make([][]byte, len(clientContracts)) diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 4e4b7e3050e..c5ca076c16f 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -191,9 +191,6 @@ func (l *logPollerWrapper) SubscribeToUpdates(subscriberName string, subscriber l.mu.Lock() defer l.mu.Unlock() l.subscribers[subscriberName] = subscriber - - // TODO remove when periodic updates are ready and integration tests are properly migrated - _ = subscriber.UpdateRoutes(l.routerContract.Address(), l.routerContract.Address()) } } From 126fbafe39e05958b68a6aa0e4159baa29bf1073 Mon Sep 17 00:00:00 2001 From: Sri Kidambi <1702865+kidambisrinivas@users.noreply.github.com> Date: Mon, 31 Jul 2023 15:37:38 +0100 Subject: [PATCH 041/270] Adding reqCount to VRFV2+ Subscription (#9995) * Adding reqCount to VRFV2+ Subscription * Prettify sol files * Prettify sol interface files * Updated comment --------- Co-authored-by: Sri Kidambi --- contracts/.gas-snapshot | 38 ++++++++++++++++--- .../dev/interfaces/IVRFSubscriptionV2Plus.sol | 6 ++- .../src/v0.8/dev/vrf/SubscriptionAPI.sol | 13 +++++-- .../src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 6 ++- .../vrf/VRFCoordinatorV2Plus_Migration.t.sol | 5 +-- .../test/v0.8/foundry/vrf/VRFV2Plus.t.sol | 12 +++--- .../vrf_coordinator_v2plus.go | 10 +++-- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 8 files changed, 66 insertions(+), 26 deletions(-) diff --git a/contracts/.gas-snapshot b/contracts/.gas-snapshot index fee527e4686..15c5b599d6e 100644 --- a/contracts/.gas-snapshot +++ b/contracts/.gas-snapshot @@ -1,17 +1,43 @@ +AutomationForwarder_forward:testBasicSuccess() (gas: 87621) +AutomationForwarder_forward:testNotAuthorizedReverts() (gas: 20812) +AutomationForwarder_forward:testWrongFunctionSelectorSuccess() (gas: 17949) +AutomationForwarder_updateRegistry:testBasicSuccess() (gas: 14577) +AutomationForwarder_updateRegistry:testNotFromRegistryNotAuthorizedReverts() (gas: 13893) EIP_712_1014_4337:testEIP712EIP4337AndCreateSmartContractAccount() (gas: 910680) EIP_712_1014_4337:testEIP712EIP4337AndCreateSmartContractAccountWithPaymaster() (gas: 2299908) EIP_712_1014_4337:testEIP712EIP4337AndCreateSmartContractAccountWithPaymasterForVRFRequest() (gas: 2893568) EIP_712_1014_4337:testEIP712EIP4337WithExistingSmartContractAccount() (gas: 875294) -FunctionsOracle_sendRequest:testEmptyRequestDataReverts() (gas: 13408) +FunctionsOracle_sendRequest:testEmptyRequestDataReverts() (gas: 13430) FunctionsOracle_setDONPublicKey:testEmptyPublicKeyReverts() (gas: 10974) FunctionsOracle_setDONPublicKey:testOnlyOwnerReverts() (gas: 11255) -FunctionsOracle_setDONPublicKey:testSetDONPublicKeySuccess() (gas: 126409) +FunctionsOracle_setDONPublicKey:testSetDONPublicKeySuccess() (gas: 126453) FunctionsOracle_setDONPublicKey:testSetDONPublicKey_gas() (gas: 97558) -FunctionsOracle_setRegistry:testEmptyPublicKeyReverts() (gas: 10613) -FunctionsOracle_setRegistry:testOnlyOwnerReverts() (gas: 10905) -FunctionsOracle_setRegistry:testSetRegistrySuccess() (gas: 35769) +FunctionsOracle_setRegistry:testEmptyPublicKeyReverts() (gas: 10635) +FunctionsOracle_setRegistry:testOnlyOwnerReverts() (gas: 10927) +FunctionsOracle_setRegistry:testSetRegistrySuccess() (gas: 35791) FunctionsOracle_setRegistry:testSetRegistry_gas() (gas: 31987) -FunctionsOracle_typeAndVersion:testTypeAndVersionSuccess() (gas: 6950) +FunctionsOracle_typeAndVersion:testTypeAndVersionSuccess() (gas: 6905) +FunctionsRouter_createSubscription:testCreateSubscriptionSuccess() (gas: 4946892) +HeartbeatRequester_getAggregatorRequestHeartbeat:testBasicSuccess() (gas: 75412) +HeartbeatRequester_getAggregatorRequestHeartbeat:testHeartbeatNotPermittedReverts() (gas: 21730) +HeartbeatRequester_permitHeartbeat:testBasicDeployerSuccess() (gas: 48280) +HeartbeatRequester_permitHeartbeat:testBasicSuccess() (gas: 45856) +HeartbeatRequester_permitHeartbeat:testOnlyCallableByOwnerReverts() (gas: 13796) +HeartbeatRequester_removeHeartbeat:testBasicSuccess() (gas: 30192) +HeartbeatRequester_removeHeartbeat:testOnlyCallableByOwnerReverts() (gas: 11629) +HeartbeatRequester_removeHeartbeat:testRemoveNoPermitsSuccess() (gas: 15660) +VRFCoordinatorV2Plus_Migration:testDeregister() (gas: 98037) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCaller() (gas: 27076) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCoordinator() (gas: 17633) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenPendingFulfillment() (gas: 239503) +VRFCoordinatorV2Plus_Migration:testMigration() (gas: 447420) +VRFV2Plus:testCreateSubscription() (gas: 92680) +VRFV2Plus:testRegisterProvingKey() (gas: 100709) +VRFV2Plus:testRequestAndFulfillRandomWordsLINK() (gas: 669592) +VRFV2Plus:testRequestAndFulfillRandomWordsNative() (gas: 620387) +VRFV2Plus:testSetConfig() (gas: 72716) +VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsLINKWrapper() (gas: 374856) +VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsNativeWrapper() (gas: 275074) VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesAMiddleDigest() (gas: 24243) VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesTheFirstDigest() (gas: 24210) VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyUnsetsDigestsInSequence() (gas: 44307) diff --git a/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol b/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol index 741f8f59066..655a585207f 100644 --- a/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol +++ b/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol @@ -60,12 +60,16 @@ interface IVRFSubscriptionV2Plus { * @param subId - ID of the subscription * @return balance - LINK balance of the subscription in juels. * @return ethBalance - ETH balance of the subscription in wei. + * @return reqCount - Requests count of subscription. * @return owner - owner of the subscription. * @return consumers - list of consumer address which are able to use this subscription. */ function getSubscription( uint256 subId - ) external view returns (uint96 balance, uint96 ethBalance, address owner, address[] memory consumers); + ) + external + view + returns (uint96 balance, uint96 ethBalance, uint64 reqCount, address owner, address[] memory consumers); /** * @notice Fund a subscription with ETH. diff --git a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol index a26149ea728..dae882f6723 100644 --- a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol +++ b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol @@ -41,8 +41,7 @@ abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, ERC677Rece // a uint96 is large enough to hold around ~8e28 wei, or 80 billion ether. // That should be enough to cover most (if not all) subscriptions. uint96 ethBalance; // Common eth balance used for all consumer requests. - - // TODO: put back request count? + uint64 reqCount; } // We use the config for the mgmt APIs struct SubscriptionConfig { @@ -227,13 +226,19 @@ abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, ERC677Rece */ function getSubscription( uint256 subId - ) public view override returns (uint96 balance, uint96 ethBalance, address owner, address[] memory consumers) { + ) + public + view + override + returns (uint96 balance, uint96 ethBalance, uint64 reqCount, address owner, address[] memory consumers) + { if (s_subscriptionConfigs[subId].owner == address(0)) { revert InvalidSubscription(); } return ( s_subscriptions[subId].balance, s_subscriptions[subId].ethBalance, + s_subscriptions[subId].reqCount, s_subscriptionConfigs[subId].owner, s_subscriptionConfigs[subId].consumers ); @@ -248,7 +253,7 @@ abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, ERC677Rece ); s_currentSubNonce++; address[] memory consumers = new address[](0); - s_subscriptions[subId] = Subscription({balance: 0, ethBalance: 0}); + s_subscriptions[subId] = Subscription({balance: 0, ethBalance: 0, reqCount: 0}); s_subscriptionConfigs[subId] = SubscriptionConfig({ owner: msg.sender, requestedOwner: address(0), diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 783f6cccc4c..816e6406445 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -430,6 +430,10 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { // to give the callee their requested amount. bool success = callWithExactGas(rc.callbackGasLimit, rc.sender, resp); + // Increment the req count for the subscription. + uint64 reqCount = s_subscriptions[rc.subId].reqCount; + s_subscriptions[rc.subId].reqCount = reqCount + 1; + // stack too deep error { bool nativePayment = _fromBytes(rc.extraArgs).nativePayment; @@ -676,7 +680,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { if (!isTargetRegistered(newCoordinator)) { revert CoordinatorNotRegistered(newCoordinator); } - (uint96 balance, uint96 ethBalance, address owner, address[] memory consumers) = getSubscription(subId); + (uint96 balance, uint96 ethBalance, , address owner, address[] memory consumers) = getSubscription(subId); require(owner == msg.sender, "Not subscription owner"); require(!pendingRequestExists(subId), "Pending request exists"); diff --git a/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol b/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol index 2ab9b5979d8..34271a129eb 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFCoordinatorV2Plus_Migration.t.sol @@ -118,9 +118,8 @@ contract VRFCoordinatorV2Plus_Migration is BaseTest { v1Coordinator.addConsumer(subId, address(testConsumer)); // subscription exists in V1 coordinator before migration - (uint96 balance, uint96 ethBalance, address owner, address[] memory consumers) = v1Coordinator.getSubscription( - subId - ); + (uint96 balance, uint96 ethBalance, uint64 reqCount, address owner, address[] memory consumers) = v1Coordinator + .getSubscription(subId); assertEq(balance, DEFAULT_LINK_FUNDING); assertEq(ethBalance, DEFAULT_NATIVE_FUNDING); assertEq(owner, address(OWNER)); diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol index b9bfd7e2887..60b8ff8e097 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol @@ -247,10 +247,10 @@ contract VRFV2Plus is BaseTest { sender: address(s_testConsumer), extraArgs: VRFV2PlusClient._argsToBytes(VRFV2PlusClient.ExtraArgsV1({nativePayment: true})) }); - (, uint96 ethBalanceBefore, , ) = s_testCoordinator.getSubscription(subId); + (, uint96 ethBalanceBefore, , , ) = s_testCoordinator.getSubscription(subId); vm.expectEmit(true, true, false, true); uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; - emit RandomWordsFulfilled(requestId, outputSeed, subId, 122500, rc.extraArgs, true); + emit RandomWordsFulfilled(requestId, outputSeed, subId, 123150, rc.extraArgs, true); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); @@ -266,7 +266,7 @@ contract VRFV2Plus is BaseTest { // billed_fee = baseFeeWei + flatFeeWei + l1CostWei // billed_fee = baseFeeWei + 0 + 0 // billed_fee = 150_000 - (, uint96 ethBalanceAfter, , ) = s_testCoordinator.getSubscription(subId); + (, uint96 ethBalanceAfter, , , ) = s_testCoordinator.getSubscription(subId); assertApproxEqAbs(ethBalanceAfter, ethBalanceBefore - 120_000, 10_000); } @@ -356,10 +356,10 @@ contract VRFV2Plus is BaseTest { sender: address(s_testConsumer), extraArgs: VRFV2PlusClient._argsToBytes(VRFV2PlusClient.ExtraArgsV1({nativePayment: false})) }); - (uint96 linkBalanceBefore, , , ) = s_testCoordinator.getSubscription(subId); + (uint96 linkBalanceBefore, , , , ) = s_testCoordinator.getSubscription(subId); vm.expectEmit(true, true, false, true); uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; - emit RandomWordsFulfilled(requestId, outputSeed, subId, 290978, rc.extraArgs, true); + emit RandomWordsFulfilled(requestId, outputSeed, subId, 292278, rc.extraArgs, true); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); @@ -376,7 +376,7 @@ contract VRFV2Plus is BaseTest { // billed_fee = baseFeeWei + 0 // billed_fee = 280_000 // note: delta is doubled from the native test to account for more variance due to the link/eth ratio - (uint96 linkBalanceAfter, , , ) = s_testCoordinator.getSubscription(subId); + (uint96 linkBalanceAfter, , , , ) = s_testCoordinator.getSubscription(subId); assertApproxEqAbs(linkBalanceAfter, linkBalanceBefore - 280_000, 20_000); } } diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index 4a44fc4162e..9bdbdfa4ccd 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -66,8 +66,8 @@ type VRFV2PlusClientRandomWordsRequest struct { } var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200609738038062006097833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615eb7620001e0600039600081816105f80152613aef0152615eb76000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610947578063ee9d2d381461096e578063f2fde38b1461099b57600080fd5b8063dc311dd3146108e4578063e72f6e3014610914578063e8509bff1461093457600080fd5b8063d98e620e116100bb578063d98e620e1461086e578063da2f26101461088e578063dac83d29146108c457600080fd5b8063bec4c08c1461080e578063caf70c4a1461082e578063cb6317971461084e57600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107ae578063b08c8795146107ce578063b2a7cac5146107ee57600080fd5b8063a4c0ed361461074e578063a8cb447b1461076e578063aa433aff1461078e57600080fd5b80639b1c385e116101745780639b1c385e146106df5780639d40a6fd146106ff578063a21a23e41461073957600080fd5b806386fe91c7146106955780638da5cb5b146106c157600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461061a5780636f64f03f1461066057806379ba50971461068057600080fd5b806364d51a2a146105b157806366316d8d146105c6578063689c4517146105e657600080fd5b806346d8d4861161022d57806346d8d4861461055157806357133e64146105715780635d06b4ab1461059157600080fd5b806340d6bb82146104f657806341af6c871461052157600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610482578063330987b31461049e578063405b84fa146104d657600080fd5b80630ae095401461040257806315c48b84146104225780631b6b6d231461044a57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103e257600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109bb565b60405161031a93929190615992565b60405180910390f35b34801561032f57600080fd5b5061034361033e3660046152f8565b610a37565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600f546103b19061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff93841660208601529183169184019190915216606082015260800161031a565b3480156103ee57600080fd5b506103436103fd366004615439565b610bf9565b34801561040e57600080fd5b5061034361041d3660046156f6565b610d8d565b34801561042e57600080fd5b5061043760c881565b60405161ffff909116815260200161031a565b34801561045657600080fd5b5060035461046a906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b34801561048e57600080fd5b506040516001815260200161031a565b3480156104aa57600080fd5b506104be6104b936600461550c565b610e79565b6040516001600160601b03909116815260200161031a565b3480156104e257600080fd5b506103436104f13660046156f6565b611338565b34801561050257600080fd5b5061050c6101f481565b60405163ffffffff909116815260200161031a565b34801561052d57600080fd5b5061054161053c36600461548e565b611717565b604051901515815260200161031a565b34801561055d57600080fd5b5061034361056c366004615315565b611919565b34801561057d57600080fd5b5061034361058c36600461534a565b611ab4565b34801561059d57600080fd5b506103436105ac3660046152f8565b611b2d565b3480156105bd57600080fd5b50610437606481565b3480156105d257600080fd5b506103436105e1366004615315565b611c04565b3480156105f257600080fd5b5061046a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561062657600080fd5b506010546106439063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561066c57600080fd5b5061034361067b366004615383565b611dc0565b34801561068c57600080fd5b50610343611ed8565b3480156106a157600080fd5b506008546104be906801000000000000000090046001600160601b031681565b3480156106cd57600080fd5b506000546001600160a01b031661046a565b3480156106eb57600080fd5b5061035b6106fa366004615608565b611f89565b34801561070b57600080fd5b506008546107209067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561074557600080fd5b5061035b6123ca565b34801561075a57600080fd5b506103436107693660046153b0565b61262a565b34801561077a57600080fd5b506103436107893660046152f8565b612819565b34801561079a57600080fd5b506103436107a936600461548e565b612935565b3480156107ba57600080fd5b5060045461046a906001600160a01b031681565b3480156107da57600080fd5b506103436107e9366004615658565b612995565b3480156107fa57600080fd5b5061034361080936600461548e565b612b1f565b34801561081a57600080fd5b506103436108293660046156f6565b612c8c565b34801561083a57600080fd5b5061035b610849366004615455565b612e5f565b34801561085a57600080fd5b506103436108693660046156f6565b612e8f565b34801561087a57600080fd5b5061035b61088936600461548e565b6131ac565b34801561089a57600080fd5b5061046a6108a936600461548e565b600b602052600090815260409020546001600160a01b031681565b3480156108d057600080fd5b506103436108df3660046156f6565b6131cd565b3480156108f057600080fd5b506109046108ff36600461548e565b613305565b60405161031a9493929190615b90565b34801561092057600080fd5b5061034361092f3660046152f8565b6133e8565b61034361094236600461548e565b6135b0565b34801561095357600080fd5b506008546104be90600160a01b90046001600160601b031681565b34801561097a57600080fd5b5061035b61098936600461548e565b600d6020526000908152604090205481565b3480156109a757600080fd5b506103436109b63660046152f8565b613708565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a2557602002820191906000526020600020905b815481526020019060010190808311610a11575b50505050509050925092509250909192565b610a3f613719565b60115460005b81811015610bcc57826001600160a01b031660118281548110610a6a57610a6a615e3b565b6000918252602090912001546001600160a01b03161415610bba576011610a92600184615d33565b81548110610aa257610aa2615e3b565b600091825260209091200154601180546001600160a01b039092169183908110610ace57610ace615e3b565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b05600185615d33565b81548110610b1557610b15615e3b565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b5457610b54615e25565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bc481615da2565b915050610a45565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c01613719565b604080518082018252600091610c30919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031680610c6c57604051631dfd6e1360e21b815260048101839052602401610bed565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d445782600c8281548110610ca757610ca7615e3b565b90600052602060002001541415610d3257600c805460009190610ccc90600190615d33565b81548110610cdc57610cdc615e3b565b9060005260206000200154905080600c8381548110610cfd57610cfd615e3b565b600091825260209091200155600c805480610d1a57610d1a615e25565b60019003818190600052602060002001600090559055505b80610d3c81615da2565b915050610c89565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d8091815260200190565b60405180910390a2505050565b60008281526006602052604090205482906001600160a01b031680610dc557604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610df957604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b600280541415610e395760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055610e4684611717565b15610e6457604051631685ecdd60e31b815260040160405180910390fd5b610e6e8484613775565b505060016002555050565b6000600280541415610ebb5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b6002805560005a90506000610ed0858561390c565b90506000610ee4608086016060870161571b565b63ffffffff1667ffffffffffffffff811115610f0257610f02615e51565b604051908082528060200260200182016040528015610f2b578160200160208202803683370190505b50905060005b610f41608087016060880161571b565b63ffffffff16811015610fb657826040015181604051602001610f6e929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f9957610f99615e3b565b602090810291909101015280610fae81615da2565b915050610f31565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161100791908690602401615a05565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b0319909416939093179092529150600090611083906110679060608b01908b0161571b565b63ffffffff1661107d60a08b0160808c016152f8565b84613c61565b9050600061109c61109760a08b018b615bd5565b613caf565b51600f549091506000906110c79089906a0100000000000000000000900463ffffffff163a85613d5e565b905081156111d0576020808b01356000908152600790915260409020546001600160601b03808316600160601b90920416101561111757604051631e9acf1760e31b815260040160405180910390fd5b60208a81013560009081526007909152604090208054829190600c9061114e908490600160601b90046001600160601b0316615d4a565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b03168352600a9091528120805485945090926111a791859116615cde565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506112bc565b6020808b01356000908152600790915260409020546001600160601b038083169116101561121157604051631e9acf1760e31b815260040160405180910390fd5b6020808b01356000908152600790915260408120805483929061123e9084906001600160601b0316615d4a565b82546101009290920a6001600160601b0381810219909316918316021790915588516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261129791859116615cde565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006112d76040518060200160405280851515815250613dae565b90508a6020013588602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8a6040015185858960405161131c9493929190615b55565b60405180910390a35060016002559a9950505050505050505050565b61134181613e34565b61136957604051635428d44960e01b81526001600160a01b0382166004820152602401610bed565b60008060008061137886613305565b9350935093509350336001600160a01b0316826001600160a01b0316146113e15760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610bed565b6113ea86611717565b156114375760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610bed565b60006040518060c0016040528061144c600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016114a0919061591d565b60405160208183030381529060405290506114ba88613e9e565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061150c90859060040161590a565b6000604051808303818588803b15801561152557600080fd5b505af1158015611539573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561159557600080fd5b505af11580156115a9573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115cd9190615471565b6116195760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610bed565b60005b83518110156116ca5783818151811061163757611637615e3b565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561169f57600080fd5b505af11580156116b3573d6000803e3d6000fd5b5050505080806116c290615da2565b91505061161c565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600660209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287969395860193909291908301828280156117a157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611783575b505050505081525050905060005b81604001515181101561190f5760005b600c548110156118fc5760006118c5600c83815481106117e1576117e1615e3b565b90600052602060002001548560400151858151811061180257611802615e3b565b602002602001015188600560008960400151898151811061182557611825615e3b565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156118e95750600195945050505050565b50806118f481615da2565b9150506117bf565b508061190781615da2565b9150506117af565b5060009392505050565b6002805414156119595760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055336000908152600a60205260409020546001600160601b038083169116101561199957604051631e9acf1760e31b815260040160405180910390fd5b336000908152600a6020526040812080548392906119c19084906001600160601b0316615d4a565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600860148282829054906101000a90046001600160601b0316611a099190615d4a565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611a83576040519150601f19603f3d011682016040523d82523d6000602084013e611a88565b606091505b5050905080611aaa57604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611abc613719565b6003546001600160a01b031615611aff576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b039384166001600160a01b03199182161790915560048054929093169116179055565b611b35613719565b611b3e81613e34565b15611b80576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610bed565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611c445760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055336000908152600960205260409020546001600160601b0380831691161015611c8457604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611cac9084906001600160601b0316615d4a565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550806008808282829054906101000a90046001600160601b0316611cf39190615d4a565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d6257600080fd5b505af1158015611d76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d9a9190615471565b611db757604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611dc8613719565b604080518082018252600091611df7919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031615611e4c576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610bed565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d80565b6001546001600160a01b03163314611f325760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610bed565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6000600280541415611fcb5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556020808301356000908152600690915260409020546001600160a01b031661200a57604051630fb532db60e11b815260040160405180910390fd5b33600090815260056020908152604080832085830135845290915290205467ffffffffffffffff168061205c576040516379bfd40160e01b815260208401356004820152336024820152604401610bed565b600f5461ffff16612073606085016040860161563d565b61ffff161080612096575060c8612090606085016040860161563d565b61ffff16115b156120dc576120ab606084016040850161563d565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610bed565b600f5462010000900463ffffffff166120fb608085016060860161571b565b63ffffffff16111561216457612117608084016060850161571b565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610bed565b6101f461217760a085016080860161571b565b63ffffffff1611156121d65761219360a084016080850161571b565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610bed565b60006121e3826001615cb2565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061226f9061109790890189615bd5565b9050600061227c82613dae565b9050836122876140ef565b60208a013561229c60808c0160608d0161571b565b6122ac60a08d0160808e0161571b565b33866040516020016122c49796959493929190615a92565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061233b919061563d565b8e606001602081019061234e919061571b565b8f6080016020810190612361919061571b565b8960405161237496959493929190615a53565b60405180910390a4505033600090815260056020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b600060028054141561240c5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b6002805560003361241e600143615d33565b600854604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b77ffffffffffffffffffffffffffffffffffffffffffffffff1916606882015260700160408051601f1981840301815291905280516020909101206008805491925067ffffffffffffffff9091169060006124af83615dbd565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff8111156124f1576124f1615e51565b60405190808252806020026020018201604052801561251a578160200160208202803683370190505b5060408051808201825260008082526020808301828152878352600782528483209351845491516001600160601b03908116600160601b0277ffffffffffffffffffffffffffffffffffffffffffffffff199093169116171790925582516060810184523381528083018281528185018681528884526006855294909220815181546001600160a01b039182166001600160a01b031991821617835593516001830180549190921694169390931790925592518051949550929390926125e7926002850192910190615123565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b60028054141561266a5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556003546001600160a01b031633146126b2576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146126ec576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006126fa8284018461548e565b6000818152600660205260409020549091506001600160a01b031661273257604051630fb532db60e11b815260040160405180910390fd5b600081815260076020526040812080546001600160601b0316918691906127598385615cde565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550846008808282829054906101000a90046001600160601b03166127a09190615cde565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846127f39190615c9a565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b612821613719565b6008544790600160a01b90046001600160601b031681811115612861576040516354ced18160e11b81526004810182905260248101839052604401610bed565b818110156129305760006128758284615d33565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128c4576040519150601f19603f3d011682016040523d82523d6000602084013e6128c9565b606091505b50509050806128eb57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b61293d613719565b6000818152600660205260409020546001600160a01b031661297257604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040902054610bf69082906001600160a01b0316613775565b61299d613719565b60c861ffff871611156129d75760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610bed565b600082136129fb576040516321ea67b360e11b815260048101839052602401610bed565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612b5f5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556000818152600660205260409020546001600160a01b0316612b9857604051630fb532db60e11b815260040160405180910390fd5b6000818152600660205260409020600101546001600160a01b03163314612c0a57600081815260066020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610bed565b6000818152600660209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526006602052604090205482906001600160a01b031680612cc457604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612cf857604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b600280541415612d385760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028080556000858152600660205260409020015460641415612d87576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff1615612dbf57610e6e565b6001600160a01b03831660008181526005602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600683528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612e7291906158fc565b604051602081830303815290604052805190602001209050919050565b60008281526006602052604090205482906001600160a01b031680612ec757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612efb57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b600280541415612f3b5760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b60028055612f4884611717565b15612f6657604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff16612fc3576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610bed565b60008481526006602090815260408083206002018054825181850281018501909352808352919290919083018282801561302657602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613008575b5050505050905060006001825161303d9190615d33565b905060005b825181101561314957856001600160a01b031683828151811061306757613067615e3b565b60200260200101516001600160a01b0316141561313757600083838151811061309257613092615e3b565b6020026020010151905080600660008a815260200190815260200160002060020183815481106130c4576130c4615e3b565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260069091526040902060020180548061310f5761310f615e25565b600082815260209020810160001990810180546001600160a01b031916905501905550613149565b8061314181615da2565b915050613042565b506001600160a01b03851660008181526005602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a79101612804565b600c81815481106131bc57600080fd5b600091825260209091200154905081565b60008281526006602052604090205482906001600160a01b03168061320557604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461323957604051636c51fda960e11b81526001600160a01b0382166004820152602401610bed565b6002805414156132795760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556000848152600660205260409020600101546001600160a01b03848116911614610e6e5760008481526006602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e4c565b600081815260066020526040812054819081906060906001600160a01b031661334157604051630fb532db60e11b815260040160405180910390fd5b60008581526007602090815260408083205460068352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b900416946001600160a01b039093169391928391908301828280156133d257602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133b4575b5050505050905093509350935093509193509193565b6133f0613719565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561344d57600080fd5b505afa158015613461573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061348591906154a7565b6008549091506801000000000000000090046001600160601b0316818111156134cb576040516354ced18160e11b81526004810182905260248101839052604401610bed565b818110156129305760006134df8284615d33565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561352f57600080fd5b505af1158015613543573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135679190615471565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6002805414156135f05760405162461bcd60e51b815260206004820152601f6024820152600080516020615e8b8339815191526044820152606401610bed565b600280556000818152600660205260409020546001600160a01b031661362957604051630fb532db60e11b815260040160405180910390fd5b60008181526007602052604090208054600160601b90046001600160601b0316903490600c6136588385615cde565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600860148282829054906101000a90046001600160601b03166136a09190615cde565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136f39190615c9a565b60408051928352602083019190915201612c7b565b613710613719565b610bf681614188565b6000546001600160a01b031633146137735760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bed565b565b60008061378184613e9e565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137de57600080fd5b505af11580156137f2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138169190615471565b61383357604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613889576040519150601f19603f3d011682016040523d82523d6000602084013e61388e565b606091505b50509050806138b057604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905281830181905282518084018452919290916139559186906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b03168061399157604051631dfd6e1360e21b815260048101839052602401610bed565b6000828660c001356040516020016139b3929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613a12576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613a206020880188615736565b6020880135613a3560608a0160408b0161571b565b613a4560808b0160608c0161571b565b613a5560a08c0160808d016152f8565b613a6260a08d018d615bd5565b604051602001613a79989796959493929190615adc565b604051602081830303815290604052805190602001208114613ac7576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613ade613ad96020890189615736565b614232565b905080613bec576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613b2160208a018a615736565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613b6157600080fd5b505afa158015613b75573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b9991906154a7565b905080613bec57613bad6020880188615736565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610bed565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c34613c2e368c90038c018c615564565b83614339565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613c7357600080fd5b611388810390508460408204820311613c8b57600080fd5b50823b613c9757600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613cd85750604080516020810190915260008152613c5b565b7f92fd133800000000000000000000000000000000000000000000000000000000613d038385615d72565b6001600160e01b03191614613d44576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d518260048186615c70565b810190613ca891906154c0565b60008115613d8c57601054613d859086908690640100000000900463ffffffff16866143a4565b9050613da6565b601054613da3908690869063ffffffff168661440e565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613de791511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613e9557826001600160a01b031660118281548110613e5f57613e5f615e3b565b6000918252602090912001546001600160a01b03161415613e835750600192915050565b80613e8d81615da2565b915050613e38565b50600092915050565b6000818152600660209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613f2a57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613f0c575b5050509190925250505060008581526007602090815260408083208151808301909252546001600160601b03808216808452600160601b9092041692820183905296509094509192505b826040015151811015613fec576005600084604001518381518110613f9b57613f9b615e3b565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613fe481615da2565b915050613f74565b50600085815260066020526040812080546001600160a01b031990811682556001820180549091169055906140246002830182615188565b50506000858152600760205260409020805477ffffffffffffffffffffffffffffffffffffffffffffffff1916905560088054859190819061407c9084906801000000000000000090046001600160601b0316615d4a565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600860148282829054906101000a90046001600160601b03166140c49190615d4a565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b1811480614104575062066eed81145b156141815760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561414357600080fd5b505afa158015614157573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061417b91906154a7565b91505090565b4391505090565b6001600160a01b0381163314156141e15760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bed565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b1811480614247575062066eed81145b15614329576101008367ffffffffffffffff166142626140ef565b61426c9190615d33565b1180614289575061427b6140ef565b8367ffffffffffffffff1610155b156142975750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156142f157600080fd5b505afa158015614305573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ca891906154a7565b505067ffffffffffffffff164090565b600061436d8360000151846020015185604001518660600151868860a001518960c001518a60e001518b6101000151614515565b600383602001516040516020016143859291906159f1565b60408051601f1981840301815291905280516020909101209392505050565b6000806143af614750565b905060005a6143be8888615c9a565b6143c89190615d33565b6143d29085615d14565b905060006143eb63ffffffff871664e8d4a51000615d14565b9050826143f88284615c9a565b6144029190615c9a565b98975050505050505050565b6000806144196147ac565b90506000811361443f576040516321ea67b360e11b815260048101829052602401610bed565b6000614449614750565b9050600082825a61445a8b8b615c9a565b6144649190615d33565b61446e9088615d14565b6144789190615c9a565b61448a90670de0b6b3a7640000615d14565b6144949190615d00565b905060006144ad63ffffffff881664e8d4a51000615d14565b90506144c5816b033b2e3c9fd0803ce8000000615d33565b8211156144fe576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6145088183615c9a565b9998505050505050505050565b61451e89614893565b61456a5760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610bed565b61457388614893565b6145bf5760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610bed565b6145c883614893565b6146145760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610bed565b61461d82614893565b6146695760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610bed565b614675878a888761496c565b6146c15760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610bed565b60006146cd8a87614aa1565b905060006146e0898b878b868989614b05565b905060006146f1838d8d8a86614c25565b9050808a146147425760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610bed565b505050505050505050505050565b60004661a4b1811480614765575062066eed81145b156147a457606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561414357600080fd5b600091505090565b600f5460048054604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000946601000000000000900463ffffffff169384151593869384936001600160a01b039092169263feaf968c928282019260a09290829003018186803b15801561482657600080fd5b505afa15801561483a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061485e9190615760565b50945090925084915050801561488257506148798242615d33565b8463ffffffff16105b15613da65750600e54949350505050565b80516000906401000003d019116148ec5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610bed565b60208201516401000003d019116149455760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610bed565b60208201516401000003d0199080096149658360005b6020020151614c65565b1492915050565b60006001600160a01b0382166149c45760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610bed565b6020840151600090600116156149db57601c6149de565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614a79573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614aa96151a6565b614ad660018484604051602001614ac2939291906158db565b604051602081830303815290604052614c89565b90505b614ae281614893565b613c5b578051604080516020810192909252614afe9101614ac2565b9050614ad9565b614b0d6151a6565b825186516401000003d0199081900691061415614b6c5760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610bed565b614b77878988614cd8565b614bc35760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610bed565b614bce848685614cd8565b614c1a5760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610bed565b614402868484614e12565b600060028686868587604051602001614c439695949392919061587c565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614c916151a6565b614c9a82614ed9565b8152614caf614caa82600061495b565b614f14565b602082018190526002900660011415614cd3576020810180516401000003d0190390525b919050565b600082614d275760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610bed565b83516020850151600090614d3d90600290615de5565b15614d4957601c614d4c565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614dbe573d6000803e3d6000fd5b505050602060405103519050600086604051602001614ddd919061586a565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614e1a6151a6565b835160208086015185519186015160009384938493614e3b93909190614f34565b919450925090506401000003d019858209600114614e9b5760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610bed565b60405180604001604052806401000003d01980614eba57614eba615e0f565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614cd357604080516020808201939093528151808203840181529082019091528051910120614ee1565b6000613c5b826002614f2d6401000003d0196001615c9a565b901c615014565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614f74838385856150b6565b9098509050614f8588828e886150da565b9098509050614f9688828c876150da565b90985090506000614fa98d878b856150da565b9098509050614fba888286866150b6565b9098509050614fcb88828e896150da565b9098509050818114615000576401000003d019818a0998506401000003d01982890997506401000003d0198183099650615004565b8196505b5050505050509450945094915050565b60008061501f6151c4565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a08201526150516151e2565b60208160c0846005600019fa9250826150ac5760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610bed565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b828054828255906000526020600020908101928215615178579160200282015b8281111561517857825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190615143565b50615184929150615200565b5090565b5080546000825590600052602060002090810190610bf69190615200565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156151845760008155600101615201565b8035614cd381615e67565b8060408101831015613c5b57600080fd5b600082601f83011261524257600080fd5b61524a615c23565b80838560408601111561525c57600080fd5b60005b600281101561527e57813584526020938401939091019060010161525f565b509095945050505050565b600060c0828403121561529b57600080fd5b50919050565b803561ffff81168114614cd357600080fd5b803563ffffffff81168114614cd357600080fd5b805169ffffffffffffffffffff81168114614cd357600080fd5b80356001600160601b0381168114614cd357600080fd5b60006020828403121561530a57600080fd5b8135613ca881615e67565b6000806040838503121561532857600080fd5b823561533381615e67565b9150615341602084016152e1565b90509250929050565b6000806040838503121561535d57600080fd5b823561536881615e67565b9150602083013561537881615e67565b809150509250929050565b6000806060838503121561539657600080fd5b82356153a181615e67565b91506153418460208501615220565b600080600080606085870312156153c657600080fd5b84356153d181615e67565b935060208501359250604085013567ffffffffffffffff808211156153f557600080fd5b818701915087601f83011261540957600080fd5b81358181111561541857600080fd5b88602082850101111561542a57600080fd5b95989497505060200194505050565b60006040828403121561544b57600080fd5b613ca88383615220565b60006040828403121561546757600080fd5b613ca88383615231565b60006020828403121561548357600080fd5b8151613ca881615e7c565b6000602082840312156154a057600080fd5b5035919050565b6000602082840312156154b957600080fd5b5051919050565b6000602082840312156154d257600080fd5b6040516020810181811067ffffffffffffffff821117156154f5576154f5615e51565b604052823561550381615e7c565b81529392505050565b6000808284036101c081121561552157600080fd5b6101a08082121561553157600080fd5b849350830135905067ffffffffffffffff81111561554e57600080fd5b61555a85828601615289565b9150509250929050565b60006101a0828403121561557757600080fd5b61557f615c4c565b6155898484615231565b81526155988460408501615231565b60208201526080830135604082015260a0830135606082015260c083013560808201526155c760e08401615215565b60a08201526101006155db85828601615231565b60c08301526155ee856101408601615231565b60e083015261018084013581830152508091505092915050565b60006020828403121561561a57600080fd5b813567ffffffffffffffff81111561563157600080fd5b613da684828501615289565b60006020828403121561564f57600080fd5b613ca8826152a1565b60008060008060008086880360e081121561567257600080fd5b61567b886152a1565b9650615689602089016152b3565b9550615697604089016152b3565b94506156a5606089016152b3565b9350608088013592506040609f19820112156156c057600080fd5b506156c9615c23565b6156d560a089016152b3565b81526156e360c089016152b3565b6020820152809150509295509295509295565b6000806040838503121561570957600080fd5b82359150602083013561537881615e67565b60006020828403121561572d57600080fd5b613ca8826152b3565b60006020828403121561574857600080fd5b813567ffffffffffffffff81168114613ca857600080fd5b600080600080600060a0868803121561577857600080fd5b615781866152c7565b94506020860151935060408601519250606086015191506157a4608087016152c7565b90509295509295909350565b600081518084526020808501945080840160005b838110156157e95781516001600160a01b0316875295820195908201906001016157c4565b509495945050505050565b8060005b60028110156158175781518452602093840193909101906001016157f8565b50505050565b6000815180845260005b8181101561584357602081850181015186830182015201615827565b81811115615855576000602083870101525b50601f01601f19169290920160200192915050565b61587481836157f4565b604001919050565b86815261588c60208201876157f4565b61589960608201866157f4565b6158a660a08201856157f4565b6158b360e08201846157f4565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526158eb60208201846157f4565b606081019190915260800192915050565b60408101613c5b82846157f4565b602081526000613ca8602083018461581d565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261596360e08401826157b0565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159e3578451835293830193918301916001016159c7565b509098975050505050505050565b82815260608101613ca860208301846157f4565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a4657845183529383019391830191600101615a2a565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261440260c083018461581d565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261450860e083018461581d565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b7d608083018561581d565b9050821515606083015295945050505050565b60006001600160601b0380871683528086166020840152506001600160a01b038416604083015260806060830152615bcb60808301846157b0565b9695505050505050565b6000808335601e19843603018112615bec57600080fd5b83018035915067ffffffffffffffff821115615c0757600080fd5b602001915036819003821315615c1c57600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c4657615c46615e51565b60405290565b604051610120810167ffffffffffffffff81118282101715615c4657615c46615e51565b60008085851115615c8057600080fd5b83861115615c8d57600080fd5b5050820193919092039150565b60008219821115615cad57615cad615df9565b500190565b600067ffffffffffffffff808316818516808303821115615cd557615cd5615df9565b01949350505050565b60006001600160601b03808316818516808303821115615cd557615cd5615df9565b600082615d0f57615d0f615e0f565b500490565b6000816000190483118215151615615d2e57615d2e615df9565b500290565b600082821015615d4557615d45615df9565b500390565b60006001600160601b0383811690831681811015615d6a57615d6a615df9565b039392505050565b6001600160e01b03198135818116916004851015615d9a5780818660040360031b1b83161692505b505092915050565b6000600019821415615db657615db6615df9565b5060010190565b600067ffffffffffffffff80831681811415615ddb57615ddb615df9565b6001019392505050565b600082615df457615df4615e0f565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610bf657600080fd5b8015158114610bf657600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200618338038062006183833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615fa3620001e0600039600081816105f80152613bcc0152615fa36000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610948578063ee9d2d381461096f578063f2fde38b1461099c57600080fd5b8063dc311dd3146108e4578063e72f6e3014610915578063e8509bff1461093557600080fd5b8063d98e620e116100bb578063d98e620e1461086e578063da2f26101461088e578063dac83d29146108c457600080fd5b8063bec4c08c1461080e578063caf70c4a1461082e578063cb6317971461084e57600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107ae578063b08c8795146107ce578063b2a7cac5146107ee57600080fd5b8063a4c0ed361461074e578063a8cb447b1461076e578063aa433aff1461078e57600080fd5b80639b1c385e116101745780639b1c385e146106df5780639d40a6fd146106ff578063a21a23e41461073957600080fd5b806386fe91c7146106955780638da5cb5b146106c157600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461061a5780636f64f03f1461066057806379ba50971461068057600080fd5b806364d51a2a146105b157806366316d8d146105c6578063689c4517146105e657600080fd5b806346d8d4861161022d57806346d8d4861461055157806357133e64146105715780635d06b4ab1461059157600080fd5b806340d6bb82146104f657806341af6c871461052157600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610482578063330987b31461049e578063405b84fa146104d657600080fd5b80630ae095401461040257806315c48b84146104225780631b6b6d231461044a57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103e257600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109bc565b60405161031a93929190615a6d565b60405180910390f35b34801561032f57600080fd5b5061034361033e3660046153d3565b610a38565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600f546103b19061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff93841660208601529183169184019190915216606082015260800161031a565b3480156103ee57600080fd5b506103436103fd366004615514565b610bfa565b34801561040e57600080fd5b5061034361041d3660046157d1565b610d8e565b34801561042e57600080fd5b5061043760c881565b60405161ffff909116815260200161031a565b34801561045657600080fd5b5060035461046a906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b34801561048e57600080fd5b506040516001815260200161031a565b3480156104aa57600080fd5b506104be6104b93660046155e7565b610e7a565b6040516001600160601b03909116815260200161031a565b3480156104e257600080fd5b506103436104f13660046157d1565b6113b6565b34801561050257600080fd5b5061050c6101f481565b60405163ffffffff909116815260200161031a565b34801561052d57600080fd5b5061054161053c366004615569565b611796565b604051901515815260200161031a565b34801561055d57600080fd5b5061034361056c3660046153f0565b611998565b34801561057d57600080fd5b5061034361058c366004615425565b611b33565b34801561059d57600080fd5b506103436105ac3660046153d3565b611bac565b3480156105bd57600080fd5b50610437606481565b3480156105d257600080fd5b506103436105e13660046153f0565b611c83565b3480156105f257600080fd5b5061046a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561062657600080fd5b506010546106439063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561066c57600080fd5b5061034361067b36600461545e565b611e3f565b34801561068c57600080fd5b50610343611f57565b3480156106a157600080fd5b506008546104be906801000000000000000090046001600160601b031681565b3480156106cd57600080fd5b506000546001600160a01b031661046a565b3480156106eb57600080fd5b5061035b6106fa3660046156e3565b612008565b34801561070b57600080fd5b506008546107209067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561074557600080fd5b5061035b612449565b34801561075a57600080fd5b5061034361076936600461548b565b6126ee565b34801561077a57600080fd5b506103436107893660046153d3565b6128dd565b34801561079a57600080fd5b506103436107a9366004615569565b6129f9565b3480156107ba57600080fd5b5060045461046a906001600160a01b031681565b3480156107da57600080fd5b506103436107e9366004615733565b612a59565b3480156107fa57600080fd5b50610343610809366004615569565b612be3565b34801561081a57600080fd5b506103436108293660046157d1565b612d50565b34801561083a57600080fd5b5061035b610849366004615530565b612f23565b34801561085a57600080fd5b506103436108693660046157d1565b612f53565b34801561087a57600080fd5b5061035b610889366004615569565b613270565b34801561089a57600080fd5b5061046a6108a9366004615569565b600b602052600090815260409020546001600160a01b031681565b3480156108d057600080fd5b506103436108df3660046157d1565b613291565b3480156108f057600080fd5b506109046108ff366004615569565b6133c9565b60405161031a959493929190615c6b565b34801561092157600080fd5b506103436109303660046153d3565b6134c5565b610343610943366004615569565b61368d565b34801561095457600080fd5b506008546104be90600160a01b90046001600160601b031681565b34801561097b57600080fd5b5061035b61098a366004615569565b600d6020526000908152604090205481565b3480156109a857600080fd5b506103436109b73660046153d3565b6137e5565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a2657602002820191906000526020600020905b815481526020019060010190808311610a12575b50505050509050925092509250909192565b610a406137f6565b60115460005b81811015610bcd57826001600160a01b031660118281548110610a6b57610a6b615f27565b6000918252602090912001546001600160a01b03161415610bbb576011610a93600184615e1f565b81548110610aa357610aa3615f27565b600091825260209091200154601180546001600160a01b039092169183908110610acf57610acf615f27565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b06600185615e1f565b81548110610b1657610b16615f27565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b5557610b55615f11565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bc581615e8e565b915050610a46565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c026137f6565b604080518082018252600091610c31919084906002908390839080828437600092019190915250612f23915050565b6000818152600b60205260409020549091506001600160a01b031680610c6d57604051631dfd6e1360e21b815260048101839052602401610bee565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d455782600c8281548110610ca857610ca8615f27565b90600052602060002001541415610d3357600c805460009190610ccd90600190615e1f565b81548110610cdd57610cdd615f27565b9060005260206000200154905080600c8381548110610cfe57610cfe615f27565b600091825260209091200155600c805480610d1b57610d1b615f11565b60019003818190600052602060002001600090559055505b80610d3d81615e8e565b915050610c8a565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d8191815260200190565b60405180910390a2505050565b60008281526006602052604090205482906001600160a01b031680610dc657604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610dfa57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b600280541415610e3a5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028055610e4784611796565b15610e6557604051631685ecdd60e31b815260040160405180910390fd5b610e6f8484613852565b505060016002555050565b6000600280541415610ebc5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b6002805560005a90506000610ed185856139e9565b90506000610ee560808601606087016157f6565b63ffffffff1667ffffffffffffffff811115610f0357610f03615f3d565b604051908082528060200260200182016040528015610f2c578160200160208202803683370190505b50905060005b610f4260808701606088016157f6565b63ffffffff16811015610fb757826040015181604051602001610f6f929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f9a57610f9a615f27565b602090810291909101015280610faf81615e8e565b915050610f32565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161100891908690602401615ae0565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b0319909416939093179092529150600090611084906110689060608b01908b016157f6565b63ffffffff1661107e60a08b0160808c016153d3565b84613d3e565b602089810135600090815260079091526040902054909150600160c01b900467ffffffffffffffff166110b8816001615d9e565b6020808b01356000908152600790915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915561111961111460a08c018c615cc1565b613d8c565b51600f54909150600090611144908a906a0100000000000000000000900463ffffffff163a85613e3b565b9050811561124d576020808c01356000908152600790915260409020546001600160601b03808316600160601b90920416101561119457604051631e9acf1760e31b815260040160405180910390fd5b60208b81013560009081526007909152604090208054829190600c906111cb908490600160601b90046001600160601b0316615e36565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600a90915281208054859450909261122491859116615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550611339565b6020808c01356000908152600790915260409020546001600160601b038083169116101561128e57604051631e9acf1760e31b815260040160405180910390fd5b6020808c0135600090815260079091526040812080548392906112bb9084906001600160601b0316615e36565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261131491859116615dca565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113546040518060200160405280851515815250613e8b565b90508b6020013589602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8b6040015185858a6040516113999493929190615c30565b60405180910390a35060016002559b9a5050505050505050505050565b6113bf81613f11565b6113e757604051635428d44960e01b81526001600160a01b0382166004820152602401610bee565b6000806000806113f6866133c9565b945094505093509350336001600160a01b0316826001600160a01b0316146114605760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610bee565b61146986611796565b156114b65760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610bee565b60006040518060c001604052806114cb600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b0316815250905060008160405160200161151f91906159f8565b604051602081830303815290604052905061153988613f7b565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061158b9085906004016159e5565b6000604051808303818588803b1580156115a457600080fd5b505af11580156115b8573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561161457600080fd5b505af1158015611628573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061164c919061554c565b6116985760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610bee565b60005b8351811015611749578381815181106116b6576116b6615f27565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561171e57600080fd5b505af1158015611732573d6000803e3d6000fd5b50505050808061174190615e8e565b91505061169b565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600660209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561182057602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611802575b505050505081525050905060005b81604001515181101561198e5760005b600c5481101561197b576000611944600c838154811061186057611860615f27565b90600052602060002001548560400151858151811061188157611881615f27565b60200260200101518860056000896040015189815181106118a4576118a4615f27565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119685750600195945050505050565b508061197381615e8e565b91505061183e565b508061198681615e8e565b91505061182e565b5060009392505050565b6002805414156119d85760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028055336000908152600a60205260409020546001600160601b0380831691161015611a1857604051631e9acf1760e31b815260040160405180910390fd5b336000908152600a602052604081208054839290611a409084906001600160601b0316615e36565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600860148282829054906101000a90046001600160601b0316611a889190615e36565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611b02576040519150601f19603f3d011682016040523d82523d6000602084013e611b07565b606091505b5050905080611b2957604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611b3b6137f6565b6003546001600160a01b031615611b7e576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b039384166001600160a01b03199182161790915560048054929093169116179055565b611bb46137f6565b611bbd81613f11565b15611bff576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610bee565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611cc35760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028055336000908152600960205260409020546001600160601b0380831691161015611d0357604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611d2b9084906001600160601b0316615e36565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550806008808282829054906101000a90046001600160601b0316611d729190615e36565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611de157600080fd5b505af1158015611df5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e19919061554c565b611e3657604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611e476137f6565b604080518082018252600091611e76919084906002908390839080828437600092019190915250612f23915050565b6000818152600b60205260409020549091506001600160a01b031615611ecb576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610bee565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d81565b6001546001600160a01b03163314611fb15760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610bee565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600060028054141561204a5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556020808301356000908152600690915260409020546001600160a01b031661208957604051630fb532db60e11b815260040160405180910390fd5b33600090815260056020908152604080832085830135845290915290205467ffffffffffffffff16806120db576040516379bfd40160e01b815260208401356004820152336024820152604401610bee565b600f5461ffff166120f26060850160408601615718565b61ffff161080612115575060c861210f6060850160408601615718565b61ffff16115b1561215b5761212a6060840160408501615718565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610bee565b600f5462010000900463ffffffff1661217a60808501606086016157f6565b63ffffffff1611156121e35761219660808401606085016157f6565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610bee565b6101f46121f660a08501608086016157f6565b63ffffffff1611156122555761221260a08401608085016157f6565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610bee565b6000612262826001615d9e565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e0808501849052855180860390910181526101009094019094528251920191909120929350906000906122ee9061111490890189615cc1565b905060006122fb82613e8b565b9050836123066141ca565b60208a013561231b60808c0160608d016157f6565b61232b60a08d0160808e016157f6565b33866040516020016123439796959493929190615b6d565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d60400160208101906123ba9190615718565b8e60600160208101906123cd91906157f6565b8f60800160208101906123e091906157f6565b896040516123f396959493929190615b2e565b60405180910390a4505033600090815260056020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b600060028054141561248b5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b6002805560003361249d600143615e1f565b600854604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206008805491925067ffffffffffffffff90911690600061253583615ea9565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561257757612577615f3d565b6040519080825280602002602001820160405280156125a0578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526007835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526006855294909120825181546001600160a01b03199081166001600160a01b0392831617835592516001830180549094169116179091559251805194955090936126ab92600285019201906151fe565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b60028054141561272e5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556003546001600160a01b03163314612776576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146127b0576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006127be82840184615569565b6000818152600660205260409020549091506001600160a01b03166127f657604051630fb532db60e11b815260040160405180910390fd5b600081815260076020526040812080546001600160601b03169186919061281d8385615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550846008808282829054906101000a90046001600160601b03166128649190615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846128b79190615d86565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b6128e56137f6565b6008544790600160a01b90046001600160601b031681811115612925576040516354ced18160e11b81526004810182905260248101839052604401610bee565b818110156129f45760006129398284615e1f565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d8060008114612988576040519150601f19603f3d011682016040523d82523d6000602084013e61298d565b606091505b50509050806129af57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b612a016137f6565b6000818152600660205260409020546001600160a01b0316612a3657604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040902054610bf79082906001600160a01b0316613852565b612a616137f6565b60c861ffff87161115612a9b5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610bee565b60008213612abf576040516321ea67b360e11b815260048101839052602401610bee565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612c235760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556000818152600660205260409020546001600160a01b0316612c5c57604051630fb532db60e11b815260040160405180910390fd5b6000818152600660205260409020600101546001600160a01b03163314612cce57600081815260066020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610bee565b6000818152600660209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526006602052604090205482906001600160a01b031680612d8857604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612dbc57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b600280541415612dfc5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028080556000858152600660205260409020015460641415612e4b576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff1615612e8357610e6f565b6001600160a01b03831660008181526005602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600683528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612f3691906159d7565b604051602081830303815290604052805190602001209050919050565b60008281526006602052604090205482906001600160a01b031680612f8b57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612fbf57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b600280541415612fff5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b6002805561300c84611796565b1561302a57604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff16613087576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610bee565b6000848152600660209081526040808320600201805482518185028101850190935280835291929091908301828280156130ea57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116130cc575b505050505090506000600182516131019190615e1f565b905060005b825181101561320d57856001600160a01b031683828151811061312b5761312b615f27565b60200260200101516001600160a01b031614156131fb57600083838151811061315657613156615f27565b6020026020010151905080600660008a8152602001908152602001600020600201838154811061318857613188615f27565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394909416939093179092558981526006909152604090206002018054806131d3576131d3615f11565b600082815260209020810160001990810180546001600160a01b03191690550190555061320d565b8061320581615e8e565b915050613106565b506001600160a01b03851660008181526005602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a791016128c8565b600c818154811061328057600080fd5b600091825260209091200154905081565b60008281526006602052604090205482906001600160a01b0316806132c957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b038216146132fd57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b60028054141561333d5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556000848152600660205260409020600101546001600160a01b03848116911614610e6f5760008481526006602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612f10565b6000818152600660205260408120548190819081906060906001600160a01b031661340757604051630fb532db60e11b815260040160405180910390fd5b60008681526007602090815260408083205460068352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156134ab57602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161348d575b505050505090509450945094509450945091939590929450565b6134cd6137f6565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561352a57600080fd5b505afa15801561353e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135629190615582565b6008549091506801000000000000000090046001600160601b0316818111156135a8576040516354ced18160e11b81526004810182905260248101839052604401610bee565b818110156129f45760006135bc8284615e1f565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561360c57600080fd5b505af1158015613620573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613644919061554c565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6002805414156136cd5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556000818152600660205260409020546001600160a01b031661370657604051630fb532db60e11b815260040160405180910390fd5b60008181526007602052604090208054600160601b90046001600160601b0316903490600c6137358385615dca565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600860148282829054906101000a90046001600160601b031661377d9190615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846137d09190615d86565b60408051928352602083019190915201612d3f565b6137ed6137f6565b610bf781614263565b6000546001600160a01b031633146138505760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bee565b565b60008061385e84613f7b565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156138bb57600080fd5b505af11580156138cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138f3919061554c565b61391057604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613966576040519150601f19603f3d011682016040523d82523d6000602084013e61396b565b606091505b505090508061398d57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b604080516060810182526000808252602082018190528183018190528251808401845291929091613a329186906002908390839080828437600092019190915250612f23915050565b6000818152600b60205260409020549091506001600160a01b031680613a6e57604051631dfd6e1360e21b815260048101839052602401610bee565b6000828660c00135604051602001613a90929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613aef576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613afd6020880188615811565b6020880135613b1260608a0160408b016157f6565b613b2260808b0160608c016157f6565b613b3260a08c0160808d016153d3565b613b3f60a08d018d615cc1565b604051602001613b56989796959493929190615bb7565b604051602081830303815290604052805190602001208114613ba4576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613bbb613bb66020890189615811565b61430d565b905080613cc9576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613bfe60208a018a615811565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613c3e57600080fd5b505afa158015613c52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c769190615582565b905080613cc957613c8a6020880188615811565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610bee565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613d11613d0b368c90038c018c61563f565b83614414565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613d5057600080fd5b611388810390508460408204820311613d6857600080fd5b50823b613d7457600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613db55750604080516020810190915260008152613d38565b7f92fd133800000000000000000000000000000000000000000000000000000000613de08385615e5e565b6001600160e01b03191614613e21576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613e2e8260048186615d5c565b810190613d85919061559b565b60008115613e6957601054613e629086908690640100000000900463ffffffff168661447f565b9050613e83565b601054613e80908690869063ffffffff16866144e9565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613ec491511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613f7257826001600160a01b031660118281548110613f3c57613f3c615f27565b6000918252602090912001546001600160a01b03161415613f605750600192915050565b80613f6a81615e8e565b915050613f15565b50600092915050565b6000818152600660209081526040808320815160608101835281546001600160a01b0390811682526001830154168185015260028201805484518187028101870186528181528796879694959486019391929083018282801561400757602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613fe9575b505050919092525050506000858152600760209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b8260400151518110156140e557600560008460400151838151811061409457614094615f27565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff19169055806140dd81615e8e565b91505061406d565b50600085815260066020526040812080546001600160a01b0319908116825560018201805490911690559061411d6002830182615263565b50506000858152600760205260408120556008805485919081906141579084906801000000000000000090046001600160601b0316615e36565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600860148282829054906101000a90046001600160601b031661419f9190615e36565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b18114806141df575062066eed81145b1561425c5760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561421e57600080fd5b505afa158015614232573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142569190615582565b91505090565b4391505090565b6001600160a01b0381163314156142bc5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bee565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b1811480614322575062066eed81145b15614404576101008367ffffffffffffffff1661433d6141ca565b6143479190615e1f565b118061436457506143566141ca565b8367ffffffffffffffff1610155b156143725750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156143cc57600080fd5b505afa1580156143e0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d859190615582565b505067ffffffffffffffff164090565b60006144488360000151846020015185604001518660600151868860a001518960c001518a60e001518b61010001516145f0565b60038360200151604051602001614460929190615acc565b60408051601f1981840301815291905280516020909101209392505050565b60008061448a61482b565b905060005a6144998888615d86565b6144a39190615e1f565b6144ad9085615e00565b905060006144c663ffffffff871664e8d4a51000615e00565b9050826144d38284615d86565b6144dd9190615d86565b98975050505050505050565b6000806144f4614887565b90506000811361451a576040516321ea67b360e11b815260048101829052602401610bee565b600061452461482b565b9050600082825a6145358b8b615d86565b61453f9190615e1f565b6145499088615e00565b6145539190615d86565b61456590670de0b6b3a7640000615e00565b61456f9190615dec565b9050600061458863ffffffff881664e8d4a51000615e00565b90506145a0816b033b2e3c9fd0803ce8000000615e1f565b8211156145d9576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6145e38183615d86565b9998505050505050505050565b6145f98961496e565b6146455760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610bee565b61464e8861496e565b61469a5760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610bee565b6146a38361496e565b6146ef5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610bee565b6146f88261496e565b6147445760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610bee565b614750878a8887614a47565b61479c5760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610bee565b60006147a88a87614b7c565b905060006147bb898b878b868989614be0565b905060006147cc838d8d8a86614d00565b9050808a1461481d5760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610bee565b505050505050505050505050565b60004661a4b1811480614840575062066eed81145b1561487f57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561421e57600080fd5b600091505090565b600f5460048054604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000946601000000000000900463ffffffff169384151593869384936001600160a01b039092169263feaf968c928282019260a09290829003018186803b15801561490157600080fd5b505afa158015614915573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614939919061583b565b50945090925084915050801561495d57506149548242615e1f565b8463ffffffff16105b15613e835750600e54949350505050565b80516000906401000003d019116149c75760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610bee565b60208201516401000003d01911614a205760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610bee565b60208201516401000003d019908009614a408360005b6020020151614d40565b1492915050565b60006001600160a01b038216614a9f5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610bee565b602084015160009060011615614ab657601c614ab9565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614b54573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614b84615281565b614bb160018484604051602001614b9d939291906159b6565b604051602081830303815290604052614d64565b90505b614bbd8161496e565b613d38578051604080516020810192909252614bd99101614b9d565b9050614bb4565b614be8615281565b825186516401000003d0199081900691061415614c475760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610bee565b614c52878988614db3565b614c9e5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610bee565b614ca9848685614db3565b614cf55760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610bee565b6144dd868484614eed565b600060028686868587604051602001614d1e96959493929190615957565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614d6c615281565b614d7582614fb4565b8152614d8a614d85826000614a36565b614fef565b602082018190526002900660011415614dae576020810180516401000003d0190390525b919050565b600082614e025760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610bee565b83516020850151600090614e1890600290615ed1565b15614e2457601c614e27565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614e99573d6000803e3d6000fd5b505050602060405103519050600086604051602001614eb89190615945565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614ef5615281565b835160208086015185519186015160009384938493614f169390919061500f565b919450925090506401000003d019858209600114614f765760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610bee565b60405180604001604052806401000003d01980614f9557614f95615efb565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614dae57604080516020808201939093528151808203840181529082019091528051910120614fbc565b6000613d388260026150086401000003d0196001615d86565b901c6150ef565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a089050600061504f83838585615191565b909850905061506088828e886151b5565b909850905061507188828c876151b5565b909850905060006150848d878b856151b5565b909850905061509588828686615191565b90985090506150a688828e896151b5565b90985090508181146150db576401000003d019818a0998506401000003d01982890997506401000003d01981830996506150df565b8196505b5050505050509450945094915050565b6000806150fa61529f565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a082015261512c6152bd565b60208160c0846005600019fa9250826151875760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610bee565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b828054828255906000526020600020908101928215615253579160200282015b8281111561525357825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019061521e565b5061525f9291506152db565b5090565b5080546000825590600052602060002090810190610bf791906152db565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561525f57600081556001016152dc565b8035614dae81615f53565b8060408101831015613d3857600080fd5b600082601f83011261531d57600080fd5b615325615d0f565b80838560408601111561533757600080fd5b60005b600281101561535957813584526020938401939091019060010161533a565b509095945050505050565b600060c0828403121561537657600080fd5b50919050565b803561ffff81168114614dae57600080fd5b803563ffffffff81168114614dae57600080fd5b805169ffffffffffffffffffff81168114614dae57600080fd5b80356001600160601b0381168114614dae57600080fd5b6000602082840312156153e557600080fd5b8135613d8581615f53565b6000806040838503121561540357600080fd5b823561540e81615f53565b915061541c602084016153bc565b90509250929050565b6000806040838503121561543857600080fd5b823561544381615f53565b9150602083013561545381615f53565b809150509250929050565b6000806060838503121561547157600080fd5b823561547c81615f53565b915061541c84602085016152fb565b600080600080606085870312156154a157600080fd5b84356154ac81615f53565b935060208501359250604085013567ffffffffffffffff808211156154d057600080fd5b818701915087601f8301126154e457600080fd5b8135818111156154f357600080fd5b88602082850101111561550557600080fd5b95989497505060200194505050565b60006040828403121561552657600080fd5b613d8583836152fb565b60006040828403121561554257600080fd5b613d85838361530c565b60006020828403121561555e57600080fd5b8151613d8581615f68565b60006020828403121561557b57600080fd5b5035919050565b60006020828403121561559457600080fd5b5051919050565b6000602082840312156155ad57600080fd5b6040516020810181811067ffffffffffffffff821117156155d0576155d0615f3d565b60405282356155de81615f68565b81529392505050565b6000808284036101c08112156155fc57600080fd5b6101a08082121561560c57600080fd5b849350830135905067ffffffffffffffff81111561562957600080fd5b61563585828601615364565b9150509250929050565b60006101a0828403121561565257600080fd5b61565a615d38565b615664848461530c565b8152615673846040850161530c565b60208201526080830135604082015260a0830135606082015260c083013560808201526156a260e084016152f0565b60a08201526101006156b68582860161530c565b60c08301526156c985610140860161530c565b60e083015261018084013581830152508091505092915050565b6000602082840312156156f557600080fd5b813567ffffffffffffffff81111561570c57600080fd5b613e8384828501615364565b60006020828403121561572a57600080fd5b613d858261537c565b60008060008060008086880360e081121561574d57600080fd5b6157568861537c565b96506157646020890161538e565b95506157726040890161538e565b94506157806060890161538e565b9350608088013592506040609f198201121561579b57600080fd5b506157a4615d0f565b6157b060a0890161538e565b81526157be60c0890161538e565b6020820152809150509295509295509295565b600080604083850312156157e457600080fd5b82359150602083013561545381615f53565b60006020828403121561580857600080fd5b613d858261538e565b60006020828403121561582357600080fd5b813567ffffffffffffffff81168114613d8557600080fd5b600080600080600060a0868803121561585357600080fd5b61585c866153a2565b945060208601519350604086015192506060860151915061587f608087016153a2565b90509295509295909350565b600081518084526020808501945080840160005b838110156158c45781516001600160a01b03168752958201959082019060010161589f565b509495945050505050565b8060005b60028110156158f25781518452602093840193909101906001016158d3565b50505050565b6000815180845260005b8181101561591e57602081850181015186830182015201615902565b81811115615930576000602083870101525b50601f01601f19169290920160200192915050565b61594f81836158cf565b604001919050565b86815261596760208201876158cf565b61597460608201866158cf565b61598160a08201856158cf565b61598e60e08201846158cf565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526159c660208201846158cf565b606081019190915260800192915050565b60408101613d3882846158cf565b602081526000613d8560208301846158f8565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c06080840152615a3e60e084018261588b565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615abe57845183529383019391830191600101615aa2565b509098975050505050505050565b82815260608101613d8560208301846158cf565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615b2157845183529383019391830191600101615b05565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a08301526144dd60c08301846158f8565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c08301526145e360e08301846158f8565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615c5860808301856158f8565b9050821515606083015295945050505050565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615cb660a083018461588b565b979650505050505050565b6000808335601e19843603018112615cd857600080fd5b83018035915067ffffffffffffffff821115615cf357600080fd5b602001915036819003821315615d0857600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615d3257615d32615f3d565b60405290565b604051610120810167ffffffffffffffff81118282101715615d3257615d32615f3d565b60008085851115615d6c57600080fd5b83861115615d7957600080fd5b5050820193919092039150565b60008219821115615d9957615d99615ee5565b500190565b600067ffffffffffffffff808316818516808303821115615dc157615dc1615ee5565b01949350505050565b60006001600160601b03808316818516808303821115615dc157615dc1615ee5565b600082615dfb57615dfb615efb565b500490565b6000816000190483118215151615615e1a57615e1a615ee5565b500290565b600082821015615e3157615e31615ee5565b500390565b60006001600160601b0383811690831681811015615e5657615e56615ee5565b039392505050565b6001600160e01b03198135818116916004851015615e865780818660040360031b1b83161692505b505092915050565b6000600019821415615ea257615ea2615ee5565b5060010190565b600067ffffffffffffffff80831681811415615ec757615ec7615ee5565b6001019392505050565b600082615ee057615ee0615efb565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610bf757600080fd5b8015158114610bf757600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI @@ -375,8 +375,9 @@ func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusCaller) GetSubscription(opts *b outstruct.Balance = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) outstruct.EthBalance = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - outstruct.Owner = *abi.ConvertType(out[2], new(common.Address)).(*common.Address) - outstruct.Consumers = *abi.ConvertType(out[3], new([]common.Address)).(*[]common.Address) + outstruct.ReqCount = *abi.ConvertType(out[2], new(uint64)).(*uint64) + outstruct.Owner = *abi.ConvertType(out[3], new(common.Address)).(*common.Address) + outstruct.Consumers = *abi.ConvertType(out[4], new([]common.Address)).(*[]common.Address) return *outstruct, err @@ -3554,6 +3555,7 @@ func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusFilterer) ParseSubscriptionOwne type GetSubscription struct { Balance *big.Int EthBalance *big.Int + ReqCount uint64 Owner common.Address Consumers []common.Address } diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 4d191d021b2..57f772b9797 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -73,7 +73,7 @@ vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsume vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 6216568e976884b3a5b6664c8877f71f11fd50419f08bd43e08eaf4f6e920cf4 +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 109aa4e3d3ca95738d8da15aefc2bf8b09b8f90204ef1a1176ca2d0a8ffe9a9a vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c From c272befd714d827c890582d74df838345ed1caa7 Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Mon, 31 Jul 2023 17:54:58 +0200 Subject: [PATCH 042/270] move {test/vendor, dev/vendor, shared/vendor}-> ./vendor (#9994) * move test/vendor -> shared/vendor * move OZ folder shared/vendor/openzeppelin-solidity/v.4.8.0 -> vendor/openzeppelin-solidity/v4.8.0 * bump mock helper & dev code version dependency removes the need to include a v4.3.1, 4.7.3 should behave the same way * rm moved OZ folder * move OZ and CBORUtils * move last shared vendor to top level vendor * move arb and optimism dev vendor * move entrypoint and arb-bridge-eth * move address to correct vendor --- .../native_solc_compile_all_transmission | 2 +- .../automation/2_0/KeeperRegistryBase2_0.sol | 2 +- .../v0.8/dev/ArbitrumCrossDomainForwarder.sol | 4 +- .../v0.8/dev/ArbitrumCrossDomainGovernor.sol | 4 +- .../v0.8/dev/ArbitrumSequencerUptimeFeed.sol | 2 +- contracts/src/v0.8/dev/ArbitrumValidator.sol | 6 +- .../v0.8/dev/OptimismCrossDomainForwarder.sol | 4 +- .../v0.8/dev/OptimismCrossDomainGovernor.sol | 4 +- contracts/src/v0.8/dev/OptimismValidator.sol | 2 +- .../automation/2_1/KeeperRegistryBase2_1.sol | 2 +- .../tests/LogTriggeredFeedLookup.sol | 2 +- .../dev/interfaces/IArbitrumDelayedInbox.sol | 2 +- .../v0.8/dev/transmission/4337/Paymaster.sol | 4 +- .../src/v0.8/dev/transmission/4337/SCA.sol | 4 +- .../src/precompiles/ArbGasInfo.sol | 39 ---- .../src/precompiles/ArbSys.sol | 150 ------------ .../L2/predeploys/OVM_GasPriceOracle.sol | 162 ------------- .../v4.3.1/contracts/utils/Address.sol | 216 ------------------ .../v0.8/functions/dev/0_0_0/Functions.sol | 2 +- .../dev/0_0_0/FunctionsBillingRegistry.sol | 6 +- .../functions/dev/0_0_0/FunctionsOracle.sol | 2 +- .../AuthorizedOriginReceiver.sol | 2 +- .../AuthorizedOriginReceiverUpgradeable.sol | 4 +- .../accessControl/AuthorizedReceiver.sol | 2 +- .../ConfirmedOwnerUpgradeable.sol | 2 +- .../dev/0_0_0/ocr/OCR2BaseUpgradeable.sol | 2 +- .../v0.8/functions/dev/1_0_0/Functions.sol | 2 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 2 +- .../dev/1_0_0/FunctionsSubscriptions.sol | 2 +- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 2 +- .../accessControl/TermsOfServiceAllowList.sol | 4 +- .../AuthorizedOriginReceiverUpgradeable.sol | 4 +- .../testhelpers/mocks/AuthorizedReceiver.sol | 2 +- .../mocks/ConfirmedOwnerUpgradeable.sol | 2 +- .../FunctionsBillingRegistryMigration.sol | 6 +- .../FunctionsBillingRegistryOriginal.sol | 6 +- .../mocks/FunctionsOracleMigration.sol | 2 +- .../mocks/FunctionsOracleOriginal.sol | 2 +- .../testhelpers/mocks/OCR2BaseUpgradeable.sol | 2 +- contracts/src/v0.8/llo-feeds/Verifier.sol | 2 +- .../src/v0.8/llo-feeds/VerifierProxy.sol | 2 +- .../v0.8/llo-feeds/interfaces/IVerifier.sol | 2 +- .../llo-feeds/test/BaseVerifierTest.t.sol | 2 +- .../test/VerifierProxySetVerifierTest.t.sol | 2 +- contracts/src/v0.8/tests/MercuryUpkeep.sol | 2 +- .../src/v0.8/tests/MockArbitrumInbox.sol | 4 +- .../src/v0.8/tests/VerifiableLoadBase.sol | 2 +- .../@ensdomains/buffer/0.1.0/Buffer.sol | 0 .../messaging/iOVM_CrossDomainMessenger.sol | 0 .../src/v0.8/{shared => }/vendor/IERC165.sol | 0 .../vendor/MockOVMCrossDomainMessenger.sol | 2 +- .../src/v0.8/{tests => }/vendor/MultiSend.sol | 0 .../contracts/bridge/interfaces/IBridge.sol | 0 .../contracts/bridge/interfaces/IInbox.sol | 0 .../bridge/interfaces/IMessageProvider.sol | 0 .../libraries/AddressAliasHelper.sol | 0 .../vendor/entrypoint/core/EntryPoint.sol | 0 .../vendor/entrypoint/core/Helpers.sol | 0 .../vendor/entrypoint/core/SenderCreator.sol | 0 .../vendor/entrypoint/core/StakeManager.sol | 0 .../vendor/entrypoint/interfaces/IAccount.sol | 0 .../entrypoint/interfaces/IAggregator.sol | 0 .../entrypoint/interfaces/IEntryPoint.sol | 0 .../entrypoint/interfaces/IPaymaster.sol | 0 .../entrypoint/interfaces/IStakeManager.sol | 0 .../entrypoint/interfaces/UserOperation.sol | 0 .../vendor/entrypoint/utils/Exec.sol | 0 .../v4.8.1/proxy/utils/Initializable.sol | 0 .../v4.8.1/security/PausableUpgradeable.sol | 0 .../v4.8.1/utils/AddressUpgradeable.sol | 0 .../v4.8.1/utils/ContextUpgradeable.sol | 0 .../v4.8.0}/contracts/security/Pausable.sol | 0 .../v4.8.0}/contracts/utils/Address.sol | 0 .../v4.8.0}/contracts/utils/Context.sol | 0 .../v4.8.0}/contracts/utils/SafeCast.sol | 0 .../contracts/utils/structs/EnumerableSet.sol | 0 .../vendor/solidity-cborutils/v2.0.0/CBOR.sol | 0 .../dev/ArbitrumCrossDomainGovernor.test.ts | 2 +- .../dev/OptimismCrossDomainForwarder.test.ts | 2 +- .../dev/OptimismCrossDomainGovernor.test.ts | 4 +- .../transmission/EIP_712_1014_4337.t.sol | 6 +- 81 files changed, 69 insertions(+), 636 deletions(-) delete mode 100644 contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol delete mode 100644 contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol delete mode 100644 contracts/src/v0.8/dev/vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol delete mode 100644 contracts/src/v0.8/dev/vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol rename contracts/src/v0.8/{shared => }/vendor/@ensdomains/buffer/0.1.0/Buffer.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol (100%) rename contracts/src/v0.8/{shared => }/vendor/IERC165.sol (100%) rename contracts/src/v0.8/{tests => }/vendor/MockOVMCrossDomainMessenger.sol (95%) rename contracts/src/v0.8/{tests => }/vendor/MultiSend.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IMessageProvider.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/core/EntryPoint.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/core/Helpers.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/core/SenderCreator.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/core/StakeManager.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/interfaces/IAccount.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/interfaces/IAggregator.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/interfaces/IEntryPoint.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/interfaces/IPaymaster.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/interfaces/IStakeManager.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/interfaces/UserOperation.sol (100%) rename contracts/src/v0.8/{dev => }/vendor/entrypoint/utils/Exec.sol (100%) rename contracts/src/v0.8/{shared/vendor/@openzeppelin/contracts-upgradeable => vendor/openzeppelin-contracts-upgradeable}/v4.8.1/proxy/utils/Initializable.sol (100%) rename contracts/src/v0.8/{shared/vendor/@openzeppelin/contracts-upgradeable => vendor/openzeppelin-contracts-upgradeable}/v4.8.1/security/PausableUpgradeable.sol (100%) rename contracts/src/v0.8/{shared/vendor/@openzeppelin/contracts-upgradeable => vendor/openzeppelin-contracts-upgradeable}/v4.8.1/utils/AddressUpgradeable.sol (100%) rename contracts/src/v0.8/{shared/vendor/@openzeppelin/contracts-upgradeable => vendor/openzeppelin-contracts-upgradeable}/v4.8.1/utils/ContextUpgradeable.sol (100%) rename contracts/src/v0.8/{shared/vendor/openzeppelin-solidity/v.4.8.0 => vendor/openzeppelin-solidity/v4.8.0}/contracts/security/Pausable.sol (100%) rename contracts/src/v0.8/{shared/vendor/openzeppelin-solidity/v.4.8.0 => vendor/openzeppelin-solidity/v4.8.0}/contracts/utils/Address.sol (100%) rename contracts/src/v0.8/{shared/vendor/openzeppelin-solidity/v.4.8.0 => vendor/openzeppelin-solidity/v4.8.0}/contracts/utils/Context.sol (100%) rename contracts/src/v0.8/{shared/vendor/openzeppelin-solidity/v.4.8.0 => vendor/openzeppelin-solidity/v4.8.0}/contracts/utils/SafeCast.sol (100%) rename contracts/src/v0.8/{shared/vendor/openzeppelin-solidity/v.4.8.0 => vendor/openzeppelin-solidity/v4.8.0}/contracts/utils/structs/EnumerableSet.sol (100%) rename contracts/src/v0.8/{shared => }/vendor/solidity-cborutils/v2.0.0/CBOR.sol (100%) diff --git a/contracts/scripts/transmission/native_solc_compile_all_transmission b/contracts/scripts/transmission/native_solc_compile_all_transmission index 833d86bce9b..0e4752d2735 100755 --- a/contracts/scripts/transmission/native_solc_compile_all_transmission +++ b/contracts/scripts/transmission/native_solc_compile_all_transmission @@ -17,4 +17,4 @@ $SCRIPTPATH/native_solc8_15_compile dev/transmission/testhelpers/SmartContractAc $SCRIPTPATH/native_solc8_15_compile dev/transmission/testhelpers/Greeter.sol # Vendor -$SCRIPTPATH/native_solc8_15_compile dev/vendor/entrypoint/core/EntryPoint.sol +$SCRIPTPATH/native_solc8_15_compile vendor/entrypoint/core/EntryPoint.sol diff --git a/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol b/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol index 1f2fab2ee7a..cda4ad0b0be 100644 --- a/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol +++ b/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol @@ -4,7 +4,7 @@ pragma solidity 0.8.6; import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; import "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol"; import "../../vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol"; -import {ArbSys} from "../../dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import {ArbSys} from "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; import "../ExecutionPrevention.sol"; import {OnchainConfig, State, UpkeepFailureReason} from "../../interfaces/automation/2_0/AutomationRegistryInterface2_0.sol"; import "../../ConfirmedOwner.sol"; diff --git a/contracts/src/v0.8/dev/ArbitrumCrossDomainForwarder.sol b/contracts/src/v0.8/dev/ArbitrumCrossDomainForwarder.sol index 63cae522548..cc04e0e4a00 100644 --- a/contracts/src/v0.8/dev/ArbitrumCrossDomainForwarder.sol +++ b/contracts/src/v0.8/dev/ArbitrumCrossDomainForwarder.sol @@ -2,8 +2,8 @@ pragma solidity ^0.8.0; import "../interfaces/TypeAndVersionInterface.sol"; -import "./vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; -import "./vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "./../vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; +import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; import "./CrossDomainForwarder.sol"; /** diff --git a/contracts/src/v0.8/dev/ArbitrumCrossDomainGovernor.sol b/contracts/src/v0.8/dev/ArbitrumCrossDomainGovernor.sol index 930926ce4c2..8e93bd2935d 100644 --- a/contracts/src/v0.8/dev/ArbitrumCrossDomainGovernor.sol +++ b/contracts/src/v0.8/dev/ArbitrumCrossDomainGovernor.sol @@ -2,8 +2,8 @@ pragma solidity ^0.8.0; import "./interfaces/DelegateForwarderInterface.sol"; -import "./vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; -import "./vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "./../vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; +import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; import "./ArbitrumCrossDomainForwarder.sol"; /** diff --git a/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol b/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol index 5efc5a07ef4..cb8ab9f0976 100644 --- a/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol +++ b/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.4; -import {AddressAliasHelper} from "./vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; +import {AddressAliasHelper} from "./../vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; import {ForwarderInterface} from "./interfaces/ForwarderInterface.sol"; import {AggregatorInterface} from "../interfaces/AggregatorInterface.sol"; import {AggregatorV3Interface} from "../interfaces/AggregatorV3Interface.sol"; diff --git a/contracts/src/v0.8/dev/ArbitrumValidator.sol b/contracts/src/v0.8/dev/ArbitrumValidator.sol index dd856c130a7..4e8d9a8537e 100644 --- a/contracts/src/v0.8/dev/ArbitrumValidator.sol +++ b/contracts/src/v0.8/dev/ArbitrumValidator.sol @@ -11,9 +11,9 @@ import "../SimpleWriteAccessController.sol"; import "./interfaces/ArbitrumSequencerUptimeFeedInterface.sol"; import "./interfaces/FlagsInterface.sol"; import "./interfaces/IArbitrumDelayedInbox.sol"; -import "./vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; -import "./vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; -import "./vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "./../vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol"; +import "../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; /** * @title ArbitrumValidator - makes xDomain L2 Flags contract call (using L2 xDomain Forwarder contract) diff --git a/contracts/src/v0.8/dev/OptimismCrossDomainForwarder.sol b/contracts/src/v0.8/dev/OptimismCrossDomainForwarder.sol index 15a64512516..9da3db692b9 100644 --- a/contracts/src/v0.8/dev/OptimismCrossDomainForwarder.sol +++ b/contracts/src/v0.8/dev/OptimismCrossDomainForwarder.sol @@ -5,8 +5,8 @@ import "../interfaces/TypeAndVersionInterface.sol"; /* ./dev dependencies - to be moved from ./dev after audit */ import "./CrossDomainForwarder.sol"; -import "./vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol"; -import "./vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "../vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol"; +import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; /** * @title OptimismCrossDomainForwarder - L1 xDomain account representation diff --git a/contracts/src/v0.8/dev/OptimismCrossDomainGovernor.sol b/contracts/src/v0.8/dev/OptimismCrossDomainGovernor.sol index ef77a1f2f6b..4c878b36068 100644 --- a/contracts/src/v0.8/dev/OptimismCrossDomainGovernor.sol +++ b/contracts/src/v0.8/dev/OptimismCrossDomainGovernor.sol @@ -2,8 +2,8 @@ pragma solidity ^0.8.0; import "./interfaces/DelegateForwarderInterface.sol"; -import "./vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol"; -import "./vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "../vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol"; +import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; import "./OptimismCrossDomainForwarder.sol"; /** diff --git a/contracts/src/v0.8/dev/OptimismValidator.sol b/contracts/src/v0.8/dev/OptimismValidator.sol index ba5a5da53cf..f08f2e323de 100644 --- a/contracts/src/v0.8/dev/OptimismValidator.sol +++ b/contracts/src/v0.8/dev/OptimismValidator.sol @@ -9,7 +9,7 @@ import "../SimpleWriteAccessController.sol"; import "./interfaces/OptimismSequencerUptimeFeedInterface.sol"; import "@eth-optimism/contracts/L1/messaging/IL1CrossDomainMessenger.sol"; -import "./vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; /** * @title OptimismValidator - makes cross chain call to update the Sequencer Uptime Feed on L2 diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index db6d1acd26d..3d4251e7d5f 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -6,7 +6,7 @@ import "../../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol import "../../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol"; import "../../../vendor/@eth-optimism/contracts/0.8.9/contracts/L2/predeploys/OVM_GasPriceOracle.sol"; import "../../../automation/ExecutionPrevention.sol"; -import {ArbSys} from "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import {ArbSys} from "../../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; import "./interfaces/FeedLookupCompatibleInterface.sol"; import "./interfaces/ILogAutomation.sol"; import {IAutomationForwarder} from "./interfaces/IAutomationForwarder.sol"; diff --git a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol index e40a719e73d..c2d91c90405 100644 --- a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol +++ b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.16; import {ILogAutomation, Log} from "../2_1/interfaces/ILogAutomation.sol"; import "../2_1/interfaces/FeedLookupCompatibleInterface.sol"; -import {ArbSys} from "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import {ArbSys} from "../../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; interface IVerifierProxy { /** diff --git a/contracts/src/v0.8/dev/interfaces/IArbitrumDelayedInbox.sol b/contracts/src/v0.8/dev/interfaces/IArbitrumDelayedInbox.sol index cb2228db72b..d209551b0c9 100644 --- a/contracts/src/v0.8/dev/interfaces/IArbitrumDelayedInbox.sol +++ b/contracts/src/v0.8/dev/interfaces/IArbitrumDelayedInbox.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol"; +import "../../vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol"; /** * @notice This interface extends Arbitrum's IInbox interface to include diff --git a/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol b/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol index cd474ddb47d..a61b4cfbee2 100644 --- a/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol +++ b/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.15; -import "../../vendor/entrypoint/interfaces/IPaymaster.sol"; +import "../../../vendor/entrypoint/interfaces/IPaymaster.sol"; import "./SCALibrary.sol"; -import "../../vendor/entrypoint/core/Helpers.sol"; +import "../../../vendor/entrypoint/core/Helpers.sol"; import "../../../interfaces/LinkTokenInterface.sol"; import "../../../interfaces/AggregatorV3Interface.sol"; import "./SCALibrary.sol"; diff --git a/contracts/src/v0.8/dev/transmission/4337/SCA.sol b/contracts/src/v0.8/dev/transmission/4337/SCA.sol index 5013d7f5d21..bf1ddf41af9 100644 --- a/contracts/src/v0.8/dev/transmission/4337/SCA.sol +++ b/contracts/src/v0.8/dev/transmission/4337/SCA.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT -import "../../vendor/entrypoint/interfaces/IAccount.sol"; +import "../../../vendor/entrypoint/interfaces/IAccount.sol"; import "./SCALibrary.sol"; -import "../../vendor/entrypoint/core/Helpers.sol"; +import "../../../vendor/entrypoint/core/Helpers.sol"; /// TODO: decide on a compiler version. Must not be dynamic, and must be > 0.8.12. pragma solidity 0.8.15; diff --git a/contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol b/contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol deleted file mode 100644 index e27417018ff..00000000000 --- a/contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol +++ /dev/null @@ -1,39 +0,0 @@ -pragma solidity >=0.4.21 <0.9.0; - -interface ArbGasInfo { - // return gas prices in wei, assuming the specified aggregator is used - // ( - // per L2 tx, - // per L1 calldata unit, (zero byte = 4 units, nonzero byte = 16 units) - // per storage allocation, - // per ArbGas base, - // per ArbGas congestion, - // per ArbGas total - // ) - function getPricesInWeiWithAggregator(address aggregator) external view returns (uint, uint, uint, uint, uint, uint); - - // return gas prices in wei, as described above, assuming the caller's preferred aggregator is used - // if the caller hasn't specified a preferred aggregator, the default aggregator is assumed - function getPricesInWei() external view returns (uint, uint, uint, uint, uint, uint); - - // return prices in ArbGas (per L2 tx, per L1 calldata unit, per storage allocation), - // assuming the specified aggregator is used - function getPricesInArbGasWithAggregator(address aggregator) external view returns (uint, uint, uint); - - // return gas prices in ArbGas, as described above, assuming the caller's preferred aggregator is used - // if the caller hasn't specified a preferred aggregator, the default aggregator is assumed - function getPricesInArbGas() external view returns (uint, uint, uint); - - // return gas accounting parameters (speedLimitPerSecond, gasPoolMax, maxTxGasLimit) - function getGasAccountingParams() external view returns (uint, uint, uint); - - // get ArbOS's estimate of the L1 gas price in wei - function getL1GasPriceEstimate() external view returns(uint); - - // set ArbOS's estimate of the L1 gas price in wei - // reverts unless called by chain owner or designated gas oracle (if any) - function setL1GasPriceEstimate(uint priceInWei) external; - - // get L1 gas fees paid by the current transaction (txBaseFeeWei, calldataFeeWei) - function getCurrentTxL1GasFees() external view returns(uint); -} \ No newline at end of file diff --git a/contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol b/contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol deleted file mode 100644 index 6966acb8a21..00000000000 --- a/contracts/src/v0.8/dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol +++ /dev/null @@ -1,150 +0,0 @@ -// Copyright 2021-2022, Offchain Labs, Inc. -// For license information, see https://github.com/nitro/blob/master/LICENSE -// SPDX-License-Identifier: BUSL-1.1 - -pragma solidity >=0.4.21 <0.9.0; - -/** - * @title System level functionality - * @notice For use by contracts to interact with core L2-specific functionality. - * Precompiled contract that exists in every Arbitrum chain at address(100), 0x0000000000000000000000000000000000000064. - */ -interface ArbSys { - /** - * @notice Get Arbitrum block number (distinct from L1 block number; Arbitrum genesis block has block number 0) - * @return block number as int - */ - function arbBlockNumber() external view returns (uint256); - - /** - * @notice Get Arbitrum block hash (reverts unless currentBlockNum-256 <= arbBlockNum < currentBlockNum) - * @return block hash - */ - function arbBlockHash(uint256 arbBlockNum) external view returns (bytes32); - - /** - * @notice Gets the rollup's unique chain identifier - * @return Chain identifier as int - */ - function arbChainID() external view returns (uint256); - - /** - * @notice Get internal version number identifying an ArbOS build - * @return version number as int - */ - function arbOSVersion() external view returns (uint256); - - /** - * @notice Returns 0 since Nitro has no concept of storage gas - * @return uint 0 - */ - function getStorageGasAvailable() external view returns (uint256); - - /** - * @notice (deprecated) check if current call is top level (meaning it was triggered by an EoA or a L1 contract) - * @dev this call has been deprecated and may be removed in a future release - * @return true if current execution frame is not a call by another L2 contract - */ - function isTopLevelCall() external view returns (bool); - - /** - * @notice map L1 sender contract address to its L2 alias - * @param sender sender address - * @param unused argument no longer used - * @return aliased sender address - */ - function mapL1SenderContractAddressToL2Alias(address sender, address unused) - external - pure - returns (address); - - /** - * @notice check if the caller (of this caller of this) is an aliased L1 contract address - * @return true iff the caller's address is an alias for an L1 contract address - */ - function wasMyCallersAddressAliased() external view returns (bool); - - /** - * @notice return the address of the caller (of this caller of this), without applying L1 contract address aliasing - * @return address of the caller's caller, without applying L1 contract address aliasing - */ - function myCallersAddressWithoutAliasing() external view returns (address); - - /** - * @notice Send given amount of Eth to dest from sender. - * This is a convenience function, which is equivalent to calling sendTxToL1 with empty data. - * @param destination recipient address on L1 - * @return unique identifier for this L2-to-L1 transaction. - */ - function withdrawEth(address destination) external payable returns (uint256); - - /** - * @notice Send a transaction to L1 - * @dev it is not possible to execute on the L1 any L2-to-L1 transaction which contains data - * to a contract address without any code (as enforced by the Bridge contract). - * @param destination recipient address on L1 - * @param data (optional) calldata for L1 contract call - * @return a unique identifier for this L2-to-L1 transaction. - */ - function sendTxToL1(address destination, bytes calldata data) - external - payable - returns (uint256); - - /** - * @notice Get send Merkle tree state - * @return size number of sends in the history - * @return root root hash of the send history - * @return partials hashes of partial subtrees in the send history tree - */ - function sendMerkleTreeState() - external - view - returns ( - uint256 size, - bytes32 root, - bytes32[] memory partials - ); - - /** - * @notice creates a send txn from L2 to L1 - * @param position = (level << 192) + leaf = (0 << 192) + leaf = leaf - */ - event L2ToL1Tx( - address caller, - address indexed destination, - uint256 indexed hash, - uint256 indexed position, - uint256 arbBlockNum, - uint256 ethBlockNum, - uint256 timestamp, - uint256 callvalue, - bytes data - ); - - /// @dev DEPRECATED in favour of the new L2ToL1Tx event above after the nitro upgrade - event L2ToL1Transaction( - address caller, - address indexed destination, - uint256 indexed uniqueId, - uint256 indexed batchNumber, - uint256 indexInBatch, - uint256 arbBlockNum, - uint256 ethBlockNum, - uint256 timestamp, - uint256 callvalue, - bytes data - ); - - /** - * @notice logs a merkle branch for proof synthesis - * @param reserved an index meant only to align the 4th index with L2ToL1Transaction's 4th event - * @param hash the merkle hash - * @param position = (level << 192) + leaf - */ - event SendMerkleUpdate( - uint256 indexed reserved, - bytes32 indexed hash, - uint256 indexed position - ); -} diff --git a/contracts/src/v0.8/dev/vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol b/contracts/src/v0.8/dev/vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol deleted file mode 100644 index 2ab825f8333..00000000000 --- a/contracts/src/v0.8/dev/vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol +++ /dev/null @@ -1,162 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity 0.8.6; - -/* External Imports */ -import { Ownable } from "@openzeppelin/contracts/access/Ownable.sol"; - -/** - * @title OVM_GasPriceOracle - * @dev This contract exposes the current l2 gas price, a measure of how congested the network - * currently is. This measure is used by the Sequencer to determine what fee to charge for - * transactions. When the system is more congested, the l2 gas price will increase and fees - * will also increase as a result. - * - * All public variables are set while generating the initial L2 state. The - * constructor doesn't run in practice as the L2 state generation script uses - * the deployed bytecode instead of running the initcode. - */ -contract OVM_GasPriceOracle is Ownable { - /************* - * Variables * - *************/ - - // Current L2 gas price - uint256 public gasPrice; - // Current L1 base fee - uint256 public l1BaseFee; - // Amortized cost of batch submission per transaction - uint256 public overhead; - // Value to scale the fee up by - uint256 public scalar; - // Number of decimals of the scalar - uint256 public decimals; - - /*************** - * Constructor * - ***************/ - - /** - * @param _owner Address that will initially own this contract. - */ - constructor(address _owner) Ownable() { - transferOwnership(_owner); - } - - /********** - * Events * - **********/ - - event GasPriceUpdated(uint256); - event L1BaseFeeUpdated(uint256); - event OverheadUpdated(uint256); - event ScalarUpdated(uint256); - event DecimalsUpdated(uint256); - - /******************** - * Public Functions * - ********************/ - - /** - * Allows the owner to modify the l2 gas price. - * @param _gasPrice New l2 gas price. - */ - // slither-disable-next-line external-function - function setGasPrice(uint256 _gasPrice) public onlyOwner { - gasPrice = _gasPrice; - emit GasPriceUpdated(_gasPrice); - } - - /** - * Allows the owner to modify the l1 base fee. - * @param _baseFee New l1 base fee - */ - // slither-disable-next-line external-function - function setL1BaseFee(uint256 _baseFee) public onlyOwner { - l1BaseFee = _baseFee; - emit L1BaseFeeUpdated(_baseFee); - } - - /** - * Allows the owner to modify the overhead. - * @param _overhead New overhead - */ - // slither-disable-next-line external-function - function setOverhead(uint256 _overhead) public onlyOwner { - overhead = _overhead; - emit OverheadUpdated(_overhead); - } - - /** - * Allows the owner to modify the scalar. - * @param _scalar New scalar - */ - // slither-disable-next-line external-function - function setScalar(uint256 _scalar) public onlyOwner { - scalar = _scalar; - emit ScalarUpdated(_scalar); - } - - /** - * Allows the owner to modify the decimals. - * @param _decimals New decimals - */ - // slither-disable-next-line external-function - function setDecimals(uint256 _decimals) public onlyOwner { - decimals = _decimals; - emit DecimalsUpdated(_decimals); - } - - /** - * Computes the L1 portion of the fee - * based on the size of the RLP encoded tx - * and the current l1BaseFee - * @param _data Unsigned RLP encoded tx, 6 elements - * @return L1 fee that should be paid for the tx - */ - // slither-disable-next-line external-function - function getL1Fee(bytes memory _data) public view returns (uint256) { - uint256 l1GasUsed = getL1GasUsed(_data); - uint256 l1Fee = l1GasUsed * l1BaseFee; - uint256 divisor = 10**decimals; - uint256 unscaled = l1Fee * scalar; - uint256 scaled = unscaled / divisor; - return scaled; - } - - // solhint-disable max-line-length - /** - * Computes the amount of L1 gas used for a transaction - * The overhead represents the per batch gas overhead of - * posting both transaction and state roots to L1 given larger - * batch sizes. - * 4 gas for 0 byte - * https://github.com/ethereum/go-ethereum/blob/9ada4a2e2c415e6b0b51c50e901336872e028872/params/protocol_params.go#L33 - * 16 gas for non zero byte - * https://github.com/ethereum/go-ethereum/blob/9ada4a2e2c415e6b0b51c50e901336872e028872/params/protocol_params.go#L87 - * This will need to be updated if calldata gas prices change - * Account for the transaction being unsigned - * Padding is added to account for lack of signature on transaction - * 1 byte for RLP V prefix - * 1 byte for V - * 1 byte for RLP R prefix - * 32 bytes for R - * 1 byte for RLP S prefix - * 32 bytes for S - * Total: 68 bytes of padding - * @param _data Unsigned RLP encoded tx, 6 elements - * @return Amount of L1 gas used for a transaction - */ - // solhint-enable max-line-length - function getL1GasUsed(bytes memory _data) public view returns (uint256) { - uint256 total = 0; - for (uint256 i = 0; i < _data.length; i++) { - if (_data[i] == 0) { - total += 4; - } else { - total += 16; - } - } - uint256 unsigned = total + overhead; - return unsigned + (68 * 16); - } -} \ No newline at end of file diff --git a/contracts/src/v0.8/dev/vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol b/contracts/src/v0.8/dev/vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol deleted file mode 100644 index 5b9c5b3ba9c..00000000000 --- a/contracts/src/v0.8/dev/vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol +++ /dev/null @@ -1,216 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.0; - -/** - * @dev Collection of functions related to the address type - */ -library Address { - /** - * @dev Returns true if `account` is a contract. - * - * [IMPORTANT] - * ==== - * It is unsafe to assume that an address for which this function returns - * false is an externally-owned account (EOA) and not a contract. - * - * Among others, `isContract` will return false for the following - * types of addresses: - * - * - an externally-owned account - * - a contract in construction - * - an address where a contract will be created - * - an address where a contract lived, but was destroyed - * ==== - */ - function isContract(address account) internal view returns (bool) { - // This method relies on extcodesize, which returns 0 for contracts in - // construction, since the code is only stored at the end of the - // constructor execution. - - uint256 size; - assembly { - size := extcodesize(account) - } - return size > 0; - } - - /** - * @dev Replacement for Solidity's `transfer`: sends `amount` wei to - * `recipient`, forwarding all available gas and reverting on errors. - * - * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost - * of certain opcodes, possibly making contracts go over the 2300 gas limit - * imposed by `transfer`, making them unable to receive funds via - * `transfer`. {sendValue} removes this limitation. - * - * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more]. - * - * IMPORTANT: because control is transferred to `recipient`, care must be - * taken to not create reentrancy vulnerabilities. Consider using - * {ReentrancyGuard} or the - * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern]. - */ - function sendValue(address payable recipient, uint256 amount) internal { - require(address(this).balance >= amount, "Address: insufficient balance"); - - (bool success, ) = recipient.call{value: amount}(""); - require(success, "Address: unable to send value, recipient may have reverted"); - } - - /** - * @dev Performs a Solidity function call using a low level `call`. A - * plain `call` is an unsafe replacement for a function call: use this - * function instead. - * - * If `target` reverts with a revert reason, it is bubbled up by this - * function (like regular Solidity function calls). - * - * Returns the raw returned data. To convert to the expected return value, - * use https://solidity.readthedocs.io/en/latest/units-and-global-variables.html?highlight=abi.decode#abi-encoding-and-decoding-functions[`abi.decode`]. - * - * Requirements: - * - * - `target` must be a contract. - * - calling `target` with `data` must not revert. - * - * _Available since v3.1._ - */ - function functionCall(address target, bytes memory data) internal returns (bytes memory) { - return functionCall(target, data, "Address: low-level call failed"); - } - - /** - * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], but with - * `errorMessage` as a fallback revert reason when `target` reverts. - * - * _Available since v3.1._ - */ - function functionCall( - address target, - bytes memory data, - string memory errorMessage - ) internal returns (bytes memory) { - return functionCallWithValue(target, data, 0, errorMessage); - } - - /** - * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], - * but also transferring `value` wei to `target`. - * - * Requirements: - * - * - the calling contract must have an ETH balance of at least `value`. - * - the called Solidity function must be `payable`. - * - * _Available since v3.1._ - */ - function functionCallWithValue( - address target, - bytes memory data, - uint256 value - ) internal returns (bytes memory) { - return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); - } - - /** - * @dev Same as {xref-Address-functionCallWithValue-address-bytes-uint256-}[`functionCallWithValue`], but - * with `errorMessage` as a fallback revert reason when `target` reverts. - * - * _Available since v3.1._ - */ - function functionCallWithValue( - address target, - bytes memory data, - uint256 value, - string memory errorMessage - ) internal returns (bytes memory) { - require(address(this).balance >= value, "Address: insufficient balance for call"); - require(isContract(target), "Address: call to non-contract"); - - (bool success, bytes memory returndata) = target.call{value: value}(data); - return verifyCallResult(success, returndata, errorMessage); - } - - /** - * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], - * but performing a static call. - * - * _Available since v3.3._ - */ - function functionStaticCall(address target, bytes memory data) internal view returns (bytes memory) { - return functionStaticCall(target, data, "Address: low-level static call failed"); - } - - /** - * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], - * but performing a static call. - * - * _Available since v3.3._ - */ - function functionStaticCall( - address target, - bytes memory data, - string memory errorMessage - ) internal view returns (bytes memory) { - require(isContract(target), "Address: static call to non-contract"); - - (bool success, bytes memory returndata) = target.staticcall(data); - return verifyCallResult(success, returndata, errorMessage); - } - - /** - * @dev Same as {xref-Address-functionCall-address-bytes-}[`functionCall`], - * but performing a delegate call. - * - * _Available since v3.4._ - */ - function functionDelegateCall(address target, bytes memory data) internal returns (bytes memory) { - return functionDelegateCall(target, data, "Address: low-level delegate call failed"); - } - - /** - * @dev Same as {xref-Address-functionCall-address-bytes-string-}[`functionCall`], - * but performing a delegate call. - * - * _Available since v3.4._ - */ - function functionDelegateCall( - address target, - bytes memory data, - string memory errorMessage - ) internal returns (bytes memory) { - require(isContract(target), "Address: delegate call to non-contract"); - - (bool success, bytes memory returndata) = target.delegatecall(data); - return verifyCallResult(success, returndata, errorMessage); - } - - /** - * @dev Tool to verifies that a low level call was successful, and revert if it wasn't, either by bubbling the - * revert reason using the provided one. - * - * _Available since v4.3._ - */ - function verifyCallResult( - bool success, - bytes memory returndata, - string memory errorMessage - ) internal pure returns (bytes memory) { - if (success) { - return returndata; - } else { - // Look for revert reason and bubble it up if present - if (returndata.length > 0) { - // The easiest way to bubble the revert reason is using memory via assembly - - assembly { - let returndata_size := mload(returndata) - revert(add(32, returndata), returndata_size) - } - } else { - revert(errorMessage); - } - } - } -} diff --git a/contracts/src/v0.8/functions/dev/0_0_0/Functions.sol b/contracts/src/v0.8/functions/dev/0_0_0/Functions.sol index d5ff5f663e6..478149d8dda 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/Functions.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/Functions.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {CBOR, Buffer} from "../../../shared/vendor/solidity-cborutils/v2.0.0/CBOR.sol"; +import {CBOR, Buffer} from "../../../vendor/solidity-cborutils/v2.0.0/CBOR.sol"; /** * @title Library for Chainlink Functions diff --git a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol index 4c35c4232b9..69145509680 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol @@ -10,9 +10,9 @@ import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterfa import {IAuthorizedOriginReceiver} from "./accessControl/interfaces/IAuthorizedOriginReceiver.sol"; import {ConfirmedOwnerUpgradeable} from "./accessControl/ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./accessControl/AuthorizedReceiver.sol"; -import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; -import {PausableUpgradeable} from "../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; -import {Initializable} from "../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {PausableUpgradeable} from "../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; +import {Initializable} from "../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title Functions Billing Registry contract diff --git a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsOracle.sol b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsOracle.sol index e392e867903..b1233eeb526 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsOracle.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsOracle.sol @@ -4,7 +4,7 @@ pragma solidity ^0.8.6; import {IFunctionsOracle, IFunctionsBillingRegistry} from "./interfaces/IFunctionsOracle.sol"; import {OCR2BaseUpgradeable} from "./ocr/OCR2BaseUpgradeable.sol"; import {AuthorizedOriginReceiverUpgradeable} from "./accessControl/AuthorizedOriginReceiverUpgradeable.sol"; -import {Initializable} from "../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title Functions Oracle contract diff --git a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiver.sol b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiver.sol index 655b32a03f2..16918072fba 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiver.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiver.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {EnumerableSet} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; +import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; import {IAuthorizedOriginReceiver} from "./interfaces/IAuthorizedOriginReceiver.sol"; /** diff --git a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiverUpgradeable.sol b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiverUpgradeable.sol index ec75452cccc..762bcb67b9f 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiverUpgradeable.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedOriginReceiverUpgradeable.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {EnumerableSet} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; -import {Initializable} from "../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; +import {Initializable} from "../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; import {IAuthorizedOriginReceiver} from "./interfaces/IAuthorizedOriginReceiver.sol"; /** diff --git a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedReceiver.sol b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedReceiver.sol index 365dd24d567..92d8af6891d 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedReceiver.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/AuthorizedReceiver.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {EnumerableSet} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; +import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; import {IAuthorizedReceiver} from "./interfaces/IAuthorizedReceiver.sol"; abstract contract AuthorizedReceiver is IAuthorizedReceiver { diff --git a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol index bf9165cc066..8bba0bb78b0 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.6; import {OwnableInterface} from "../../../../interfaces/OwnableInterface.sol"; -import {Initializable} from "../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title The ConfirmedOwnerUpgradeable contract diff --git a/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2BaseUpgradeable.sol b/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2BaseUpgradeable.sol index eeb966dd037..25481ceb73e 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2BaseUpgradeable.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2BaseUpgradeable.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.0; import {ConfirmedOwnerUpgradeable} from "../accessControl/ConfirmedOwnerUpgradeable.sol"; import {OCR2Abstract} from "./OCR2Abstract.sol"; -import {Initializable} from "../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @notice Onchain verification of reports from the offchain reporting protocol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol b/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol index 2c59102fd5e..3f84fb3d358 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {CBOR, Buffer} from "../../../shared/vendor/solidity-cborutils/v2.0.0/CBOR.sol"; +import {CBOR, Buffer} from "../../../vendor/solidity-cborutils/v2.0.0/CBOR.sol"; /** * @title Library for Chainlink Functions diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index ddb69b3fed8..e188e6f5259 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -6,7 +6,7 @@ import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; -import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { // We limit return data to a selector plus 4 words. This is to avoid diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 454f7585b53..b39ad1cad12 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -5,7 +5,7 @@ import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol" import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; -import {SafeCast} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; /** * @title Functions Subscriptions contract diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index f77b14b80aa..81754d49ad7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -4,7 +4,7 @@ pragma solidity ^0.8.19; import {IRouterBase} from "./interfaces/IRouterBase.sol"; import {ConfirmedOwnerWithProposal} from "../../../ConfirmedOwnerWithProposal.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; -import {Pausable} from "../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/security/Pausable.sol"; +import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; import {IConfigurable} from "./interfaces/IConfigurable.sol"; abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, ConfirmedOwnerWithProposal { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index dedc5c2900e..a3b49a35a9c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -5,8 +5,8 @@ import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.so import {Routable, ITypeAndVersion} from "../Routable.sol"; import {IAccessController} from "../../../../shared/interfaces/IAccessController.sol"; -import {EnumerableSet} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; -import {Address} from "../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol"; +import {Address} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol"; +import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; /** * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedOriginReceiverUpgradeable.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedOriginReceiverUpgradeable.sol index fe26965d729..4c963e46c86 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedOriginReceiverUpgradeable.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedOriginReceiverUpgradeable.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {EnumerableSet} from "../../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {EnumerableSet} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; /** diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedReceiver.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedReceiver.sol index 27df650b8af..52078ff6447 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedReceiver.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/AuthorizedReceiver.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {EnumerableSet} from "../../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol"; +import {EnumerableSet} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; import {AuthorizedReceiverInterface} from "./AuthorizedReceiverInterface.sol"; abstract contract AuthorizedReceiver is AuthorizedReceiverInterface { diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol index a03e2b583de..a6e7ae0760c 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.6; import {OwnableInterface} from "../../../../../interfaces/OwnableInterface.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title The ConfirmedOwnerUpgradeable contract diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol index a3b31e6c35e..5c1a033535c 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol @@ -11,9 +11,9 @@ import {ERC677ReceiverInterface} from "../../../../../interfaces/ERC677ReceiverI import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; -import {SafeCast} from "../../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; -import {PausableUpgradeable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {SafeCast} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {PausableUpgradeable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title Functions Billing Registry contract diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol index 54bef1d0a66..2ae9684c924 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol @@ -11,9 +11,9 @@ import {ERC677ReceiverInterface} from "../../../../../interfaces/ERC677ReceiverI import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; -import {SafeCast} from "../../../../../shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol"; -import {PausableUpgradeable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {SafeCast} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {PausableUpgradeable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title Functions Billing Registry contract diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleMigration.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleMigration.sol index 0c3c85a4330..ccc65007842 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleMigration.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleMigration.sol @@ -5,7 +5,7 @@ import {FunctionsOracleInterface} from "./FunctionsOracleInterface.sol"; import {FunctionsBillingRegistryInterface} from "./FunctionsBillingRegistryInterface.sol"; import {OCR2BaseUpgradeable} from "./OCR2BaseUpgradeable.sol"; import {AuthorizedOriginReceiverUpgradeable} from "./AuthorizedOriginReceiverUpgradeable.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title Functions Oracle contract diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleOriginal.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleOriginal.sol index 0b0417ca18b..0ff5ad1b6cc 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleOriginal.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsOracleOriginal.sol @@ -5,7 +5,7 @@ import {FunctionsOracleInterface} from "./FunctionsOracleInterface.sol"; import {FunctionsBillingRegistryInterface} from "./FunctionsBillingRegistryInterface.sol"; import {OCR2BaseUpgradeable} from "./OCR2BaseUpgradeable.sol"; import {AuthorizedOriginReceiverUpgradeable} from "./AuthorizedOriginReceiverUpgradeable.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title Functions Oracle contract diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/OCR2BaseUpgradeable.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/OCR2BaseUpgradeable.sol index e852740deb0..b768d716583 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/OCR2BaseUpgradeable.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/OCR2BaseUpgradeable.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.0; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {OCR2Abstract} from "./OCR2Abstract.sol"; -import {Initializable} from "../../../../../shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; +import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @notice Onchain verification of reports from the offchain reporting protocol diff --git a/contracts/src/v0.8/llo-feeds/Verifier.sol b/contracts/src/v0.8/llo-feeds/Verifier.sol index e8b002df883..2cba744d0cc 100644 --- a/contracts/src/v0.8/llo-feeds/Verifier.sol +++ b/contracts/src/v0.8/llo-feeds/Verifier.sol @@ -5,7 +5,7 @@ import {ConfirmedOwner} from "../ConfirmedOwner.sol"; import {IVerifier} from "./interfaces/IVerifier.sol"; import {IVerifierProxy} from "./interfaces/IVerifierProxy.sol"; import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; -import {IERC165} from "../shared/vendor/IERC165.sol"; +import {IERC165} from "../vendor/IERC165.sol"; // OCR2 standard uint256 constant MAX_NUM_ORACLES = 31; diff --git a/contracts/src/v0.8/llo-feeds/VerifierProxy.sol b/contracts/src/v0.8/llo-feeds/VerifierProxy.sol index 60ad52b1810..0f071a06cd2 100644 --- a/contracts/src/v0.8/llo-feeds/VerifierProxy.sol +++ b/contracts/src/v0.8/llo-feeds/VerifierProxy.sol @@ -6,7 +6,7 @@ import {IVerifierProxy} from "./interfaces/IVerifierProxy.sol"; import {IVerifier} from "./interfaces/IVerifier.sol"; import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; import {AccessControllerInterface} from "../interfaces/AccessControllerInterface.sol"; -import {IERC165} from "../shared/vendor/IERC165.sol"; +import {IERC165} from "../vendor/IERC165.sol"; /** * The verifier proxy contract is the gateway for all report verification requests diff --git a/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol b/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol index 53dd6c6f3e5..b0e8b358d50 100644 --- a/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol +++ b/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.16; -import {IERC165} from "../../shared/vendor/IERC165.sol"; +import {IERC165} from "../../vendor/IERC165.sol"; interface IVerifier is IERC165 { /** diff --git a/contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol index a57e6c23781..f91ef741ed9 100644 --- a/contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.16; import {Test} from "forge-std/Test.sol"; import {VerifierProxy} from "../VerifierProxy.sol"; -import {IERC165} from "../../shared/vendor/IERC165.sol"; +import {IERC165} from "../../vendor/IERC165.sol"; import {IVerifier} from "../interfaces/IVerifier.sol"; import {ErroredVerifier} from "./mocks/ErroredVerifier.sol"; import {Verifier} from "../Verifier.sol"; diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol index 2e40706f2a3..2cc4062e0a4 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol @@ -5,7 +5,7 @@ import {BaseTestWithConfiguredVerifier} from "./BaseVerifierTest.t.sol"; import {IVerifier} from "../interfaces/IVerifier.sol"; import {VerifierProxy} from "../VerifierProxy.sol"; import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; -import {IERC165} from "../../shared/vendor/IERC165.sol"; +import {IERC165} from "../../vendor/IERC165.sol"; contract VerifierProxyInitializeVerifierTest is BaseTestWithConfiguredVerifier { function test_revertsIfNotCorrectVerifier() public { diff --git a/contracts/src/v0.8/tests/MercuryUpkeep.sol b/contracts/src/v0.8/tests/MercuryUpkeep.sol index 336d2ba4a73..f523aa528c6 100644 --- a/contracts/src/v0.8/tests/MercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/MercuryUpkeep.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.15; import "../interfaces/automation/AutomationCompatibleInterface.sol"; import "../dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol"; -import {ArbSys} from "../dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import {ArbSys} from "../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; //interface IVerifierProxy { // /** diff --git a/contracts/src/v0.8/tests/MockArbitrumInbox.sol b/contracts/src/v0.8/tests/MockArbitrumInbox.sol index 0c90d19b324..cd85ed4d6ea 100644 --- a/contracts/src/v0.8/tests/MockArbitrumInbox.sol +++ b/contracts/src/v0.8/tests/MockArbitrumInbox.sol @@ -1,5 +1,5 @@ -import {IInbox} from "../dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol"; -import {IBridge} from "../dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol"; +import {IInbox} from "../vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol"; +import {IBridge} from "../vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol"; contract MockArbitrumInbox is IInbox { event RetryableTicketNoRefundAliasRewriteCreated( diff --git a/contracts/src/v0.8/tests/VerifiableLoadBase.sol b/contracts/src/v0.8/tests/VerifiableLoadBase.sol index 4bb7907ed58..03f581dab1d 100644 --- a/contracts/src/v0.8/tests/VerifiableLoadBase.sol +++ b/contracts/src/v0.8/tests/VerifiableLoadBase.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.16; import "../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; import "../dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol"; -import {ArbSys} from "../dev/vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; +import {ArbSys} from "../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; import "../dev/automation/2_1/AutomationRegistrar2_1.sol"; import {LogTriggerConfig} from "../dev/automation/2_1/AutomationUtils2_1.sol"; diff --git a/contracts/src/v0.8/shared/vendor/@ensdomains/buffer/0.1.0/Buffer.sol b/contracts/src/v0.8/vendor/@ensdomains/buffer/0.1.0/Buffer.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/@ensdomains/buffer/0.1.0/Buffer.sol rename to contracts/src/v0.8/vendor/@ensdomains/buffer/0.1.0/Buffer.sol diff --git a/contracts/src/v0.8/dev/vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol b/contracts/src/v0.8/vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol rename to contracts/src/v0.8/vendor/@eth-optimism/contracts/0.4.7/contracts/optimistic-ethereum/iOVM/bridge/messaging/iOVM_CrossDomainMessenger.sol diff --git a/contracts/src/v0.8/shared/vendor/IERC165.sol b/contracts/src/v0.8/vendor/IERC165.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/IERC165.sol rename to contracts/src/v0.8/vendor/IERC165.sol diff --git a/contracts/src/v0.8/tests/vendor/MockOVMCrossDomainMessenger.sol b/contracts/src/v0.8/vendor/MockOVMCrossDomainMessenger.sol similarity index 95% rename from contracts/src/v0.8/tests/vendor/MockOVMCrossDomainMessenger.sol rename to contracts/src/v0.8/vendor/MockOVMCrossDomainMessenger.sol index ebb53f4ecc0..1266b484b8b 100644 --- a/contracts/src/v0.8/tests/vendor/MockOVMCrossDomainMessenger.sol +++ b/contracts/src/v0.8/vendor/MockOVMCrossDomainMessenger.sol @@ -2,7 +2,7 @@ pragma solidity >=0.7.6 <0.9.0; -import "../../dev/vendor/openzeppelin-solidity/v4.3.1/contracts/utils/Address.sol"; +import "./openzeppelin-solidity/v4.7.0/contracts/utils/Address.sol"; /** * @title iOVM_CrossDomainMessenger diff --git a/contracts/src/v0.8/tests/vendor/MultiSend.sol b/contracts/src/v0.8/vendor/MultiSend.sol similarity index 100% rename from contracts/src/v0.8/tests/vendor/MultiSend.sol rename to contracts/src/v0.8/vendor/MultiSend.sol diff --git a/contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol b/contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol rename to contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IBridge.sol diff --git a/contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol b/contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol rename to contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IInbox.sol diff --git a/contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IMessageProvider.sol b/contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IMessageProvider.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IMessageProvider.sol rename to contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/bridge/interfaces/IMessageProvider.sol diff --git a/contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol b/contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol rename to contracts/src/v0.8/vendor/arb-bridge-eth/v0.8.0-custom/contracts/libraries/AddressAliasHelper.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/core/EntryPoint.sol b/contracts/src/v0.8/vendor/entrypoint/core/EntryPoint.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/core/EntryPoint.sol rename to contracts/src/v0.8/vendor/entrypoint/core/EntryPoint.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/core/Helpers.sol b/contracts/src/v0.8/vendor/entrypoint/core/Helpers.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/core/Helpers.sol rename to contracts/src/v0.8/vendor/entrypoint/core/Helpers.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/core/SenderCreator.sol b/contracts/src/v0.8/vendor/entrypoint/core/SenderCreator.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/core/SenderCreator.sol rename to contracts/src/v0.8/vendor/entrypoint/core/SenderCreator.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/core/StakeManager.sol b/contracts/src/v0.8/vendor/entrypoint/core/StakeManager.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/core/StakeManager.sol rename to contracts/src/v0.8/vendor/entrypoint/core/StakeManager.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IAccount.sol b/contracts/src/v0.8/vendor/entrypoint/interfaces/IAccount.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IAccount.sol rename to contracts/src/v0.8/vendor/entrypoint/interfaces/IAccount.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IAggregator.sol b/contracts/src/v0.8/vendor/entrypoint/interfaces/IAggregator.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IAggregator.sol rename to contracts/src/v0.8/vendor/entrypoint/interfaces/IAggregator.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IEntryPoint.sol b/contracts/src/v0.8/vendor/entrypoint/interfaces/IEntryPoint.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IEntryPoint.sol rename to contracts/src/v0.8/vendor/entrypoint/interfaces/IEntryPoint.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IPaymaster.sol b/contracts/src/v0.8/vendor/entrypoint/interfaces/IPaymaster.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IPaymaster.sol rename to contracts/src/v0.8/vendor/entrypoint/interfaces/IPaymaster.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IStakeManager.sol b/contracts/src/v0.8/vendor/entrypoint/interfaces/IStakeManager.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/interfaces/IStakeManager.sol rename to contracts/src/v0.8/vendor/entrypoint/interfaces/IStakeManager.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/interfaces/UserOperation.sol b/contracts/src/v0.8/vendor/entrypoint/interfaces/UserOperation.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/interfaces/UserOperation.sol rename to contracts/src/v0.8/vendor/entrypoint/interfaces/UserOperation.sol diff --git a/contracts/src/v0.8/dev/vendor/entrypoint/utils/Exec.sol b/contracts/src/v0.8/vendor/entrypoint/utils/Exec.sol similarity index 100% rename from contracts/src/v0.8/dev/vendor/entrypoint/utils/Exec.sol rename to contracts/src/v0.8/vendor/entrypoint/utils/Exec.sol diff --git a/contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol b/contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol rename to contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol diff --git a/contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol b/contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol rename to contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol diff --git a/contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/utils/AddressUpgradeable.sol b/contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/utils/AddressUpgradeable.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/utils/AddressUpgradeable.sol rename to contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/utils/AddressUpgradeable.sol diff --git a/contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/utils/ContextUpgradeable.sol b/contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/utils/ContextUpgradeable.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/@openzeppelin/contracts-upgradeable/v4.8.1/utils/ContextUpgradeable.sol rename to contracts/src/v0.8/vendor/openzeppelin-contracts-upgradeable/v4.8.1/utils/ContextUpgradeable.sol diff --git a/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/security/Pausable.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/security/Pausable.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol diff --git a/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Address.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol diff --git a/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Context.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Context.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/Context.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Context.sol diff --git a/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/SafeCast.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol diff --git a/contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/openzeppelin-solidity/v.4.8.0/contracts/utils/structs/EnumerableSet.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol diff --git a/contracts/src/v0.8/shared/vendor/solidity-cborutils/v2.0.0/CBOR.sol b/contracts/src/v0.8/vendor/solidity-cborutils/v2.0.0/CBOR.sol similarity index 100% rename from contracts/src/v0.8/shared/vendor/solidity-cborutils/v2.0.0/CBOR.sol rename to contracts/src/v0.8/vendor/solidity-cborutils/v2.0.0/CBOR.sol diff --git a/contracts/test/v0.8/dev/ArbitrumCrossDomainGovernor.test.ts b/contracts/test/v0.8/dev/ArbitrumCrossDomainGovernor.test.ts index 115e2ef3aad..c7a8098800c 100644 --- a/contracts/test/v0.8/dev/ArbitrumCrossDomainGovernor.test.ts +++ b/contracts/test/v0.8/dev/ArbitrumCrossDomainGovernor.test.ts @@ -39,7 +39,7 @@ before(async () => { owner, ) multisendFactory = await ethers.getContractFactory( - 'src/v0.8/tests/vendor/MultiSend.sol:MultiSend', + 'src/v0.8/vendor/MultiSend.sol:MultiSend', owner, ) }) diff --git a/contracts/test/v0.8/dev/OptimismCrossDomainForwarder.test.ts b/contracts/test/v0.8/dev/OptimismCrossDomainForwarder.test.ts index 062b0969676..2668f4ea672 100644 --- a/contracts/test/v0.8/dev/OptimismCrossDomainForwarder.test.ts +++ b/contracts/test/v0.8/dev/OptimismCrossDomainForwarder.test.ts @@ -34,7 +34,7 @@ before(async () => { owner, ) crossDomainMessengerFactory = await ethers.getContractFactory( - 'src/v0.8/tests/vendor/MockOVMCrossDomainMessenger.sol:MockOVMCrossDomainMessenger', + 'src/v0.8/vendor/MockOVMCrossDomainMessenger.sol:MockOVMCrossDomainMessenger', ) }) diff --git a/contracts/test/v0.8/dev/OptimismCrossDomainGovernor.test.ts b/contracts/test/v0.8/dev/OptimismCrossDomainGovernor.test.ts index 7f2807d33f4..53c3f4ef254 100644 --- a/contracts/test/v0.8/dev/OptimismCrossDomainGovernor.test.ts +++ b/contracts/test/v0.8/dev/OptimismCrossDomainGovernor.test.ts @@ -36,11 +36,11 @@ before(async () => { owner, ) multisendFactory = await ethers.getContractFactory( - 'src/v0.8/tests/vendor/MultiSend.sol:MultiSend', + 'src/v0.8/vendor/MultiSend.sol:MultiSend', owner, ) crossDomainMessengerFactory = await ethers.getContractFactory( - 'src/v0.8/tests/vendor/MockOVMCrossDomainMessenger.sol:MockOVMCrossDomainMessenger', + 'src/v0.8/vendor/MockOVMCrossDomainMessenger.sol:MockOVMCrossDomainMessenger', ) }) diff --git a/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol b/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol index 27e19ddcb82..9bf97d69693 100644 --- a/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol +++ b/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol @@ -6,9 +6,9 @@ import "../../../../src/v0.8/dev/transmission/testhelpers/SmartContractAccountHe import "../../../../src/v0.8/dev/transmission/4337/SCA.sol"; import "../../../../src/v0.8/dev/transmission/testhelpers/Greeter.sol"; import "../../../../src/v0.8/dev/transmission/4337/Paymaster.sol"; -import "../../../../src/v0.8/dev/vendor/entrypoint/interfaces/UserOperation.sol"; -import "../../../../src/v0.8/dev/vendor/entrypoint/core/EntryPoint.sol"; -import "../../../../src/v0.8/dev/vendor/entrypoint/interfaces/IEntryPoint.sol"; +import "../../../../src/v0.8/vendor/entrypoint/interfaces/UserOperation.sol"; +import "../../../../src/v0.8/vendor/entrypoint/core/EntryPoint.sol"; +import "../../../../src/v0.8/vendor/entrypoint/interfaces/IEntryPoint.sol"; import "../../../../src/v0.8/dev/transmission/4337/SCALibrary.sol"; import "../../../../src/v0.8/mocks/MockLinkToken.sol"; import "../../../../src/v0.8/interfaces/LinkTokenInterface.sol"; From 9c9dc53fc83e43bd593498fc516b4cf04330b4dd Mon Sep 17 00:00:00 2001 From: JonWong203 <82334955+JonWong203@users.noreply.github.com> Date: Mon, 31 Jul 2023 16:28:25 -0400 Subject: [PATCH 043/270] protobuf updated (#10008) --- .../telem/telem_automation_custom.pb.go | 201 +++++++++++++----- .../telem/telem_automation_custom.proto | 19 +- 2 files changed, 158 insertions(+), 62 deletions(-) diff --git a/core/services/synchronization/telem/telem_automation_custom.pb.go b/core/services/synchronization/telem/telem_automation_custom.pb.go index 707a7a0c826..507a169167e 100644 --- a/core/services/synchronization/telem/telem_automation_custom.pb.go +++ b/core/services/synchronization/telem/telem_automation_custom.pb.go @@ -25,10 +25,9 @@ type BlockNumber struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - NodeId string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"` - Timetsamp uint64 `protobuf:"varint,2,opt,name=timetsamp,proto3" json:"timetsamp,omitempty"` - BlockNumber uint64 `protobuf:"varint,3,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` - BlockHash string `protobuf:"bytes,4,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"` + Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + BlockNumber uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` + BlockHash string `protobuf:"bytes,3,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"` } func (x *BlockNumber) Reset() { @@ -63,16 +62,9 @@ func (*BlockNumber) Descriptor() ([]byte, []int) { return file_telem_automation_custom_proto_rawDescGZIP(), []int{0} } -func (x *BlockNumber) GetNodeId() string { +func (x *BlockNumber) GetTimestamp() uint64 { if x != nil { - return x.NodeId - } - return "" -} - -func (x *BlockNumber) GetTimetsamp() uint64 { - if x != nil { - return x.Timetsamp + return x.Timestamp } return 0 } @@ -96,9 +88,8 @@ type NodeVersion struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - NodeId string `protobuf:"bytes,1,opt,name=node_id,json=nodeId,proto3" json:"node_id,omitempty"` - Timestamp uint64 `protobuf:"varint,2,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - NodeVersion uint32 `protobuf:"varint,3,opt,name=node_version,json=nodeVersion,proto3" json:"node_version,omitempty"` + Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + NodeVersion string `protobuf:"bytes,2,opt,name=node_version,json=nodeVersion,proto3" json:"node_version,omitempty"` } func (x *NodeVersion) Reset() { @@ -133,13 +124,6 @@ func (*NodeVersion) Descriptor() ([]byte, []int) { return file_telem_automation_custom_proto_rawDescGZIP(), []int{1} } -func (x *NodeVersion) GetNodeId() string { - if x != nil { - return x.NodeId - } - return "" -} - func (x *NodeVersion) GetTimestamp() uint64 { if x != nil { return x.Timestamp @@ -147,39 +131,127 @@ func (x *NodeVersion) GetTimestamp() uint64 { return 0 } -func (x *NodeVersion) GetNodeVersion() uint32 { +func (x *NodeVersion) GetNodeVersion() string { if x != nil { return x.NodeVersion } - return 0 + return "" +} + +type AutomationTelemWrapper struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + // Types that are assignable to Msg: + // + // *AutomationTelemWrapper_BlockNumber + // *AutomationTelemWrapper_NodeVersion + Msg isAutomationTelemWrapper_Msg `protobuf_oneof:"msg"` +} + +func (x *AutomationTelemWrapper) Reset() { + *x = AutomationTelemWrapper{} + if protoimpl.UnsafeEnabled { + mi := &file_telem_automation_custom_proto_msgTypes[2] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *AutomationTelemWrapper) String() string { + return protoimpl.X.MessageStringOf(x) } +func (*AutomationTelemWrapper) ProtoMessage() {} + +func (x *AutomationTelemWrapper) ProtoReflect() protoreflect.Message { + mi := &file_telem_automation_custom_proto_msgTypes[2] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use AutomationTelemWrapper.ProtoReflect.Descriptor instead. +func (*AutomationTelemWrapper) Descriptor() ([]byte, []int) { + return file_telem_automation_custom_proto_rawDescGZIP(), []int{2} +} + +func (m *AutomationTelemWrapper) GetMsg() isAutomationTelemWrapper_Msg { + if m != nil { + return m.Msg + } + return nil +} + +func (x *AutomationTelemWrapper) GetBlockNumber() *BlockNumber { + if x, ok := x.GetMsg().(*AutomationTelemWrapper_BlockNumber); ok { + return x.BlockNumber + } + return nil +} + +func (x *AutomationTelemWrapper) GetNodeVersion() *NodeVersion { + if x, ok := x.GetMsg().(*AutomationTelemWrapper_NodeVersion); ok { + return x.NodeVersion + } + return nil +} + +type isAutomationTelemWrapper_Msg interface { + isAutomationTelemWrapper_Msg() +} + +type AutomationTelemWrapper_BlockNumber struct { + BlockNumber *BlockNumber `protobuf:"bytes,1,opt,name=block_number,json=blockNumber,proto3,oneof"` +} + +type AutomationTelemWrapper_NodeVersion struct { + NodeVersion *NodeVersion `protobuf:"bytes,2,opt,name=node_version,json=nodeVersion,proto3,oneof"` +} + +func (*AutomationTelemWrapper_BlockNumber) isAutomationTelemWrapper_Msg() {} + +func (*AutomationTelemWrapper_NodeVersion) isAutomationTelemWrapper_Msg() {} + var File_telem_automation_custom_proto protoreflect.FileDescriptor var file_telem_automation_custom_proto_rawDesc = []byte{ 0x0a, 0x1d, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x5f, 0x61, 0x75, 0x74, 0x6f, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, - 0x05, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x22, 0x86, 0x01, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x17, 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x69, - 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x64, 0x12, - 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x74, 0x73, 0x61, 0x6d, 0x70, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x74, 0x73, 0x61, 0x6d, 0x70, 0x12, 0x21, 0x0a, - 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, - 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x04, - 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x22, - 0x67, 0x0a, 0x0b, 0x4e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x17, - 0x0a, 0x07, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x06, 0x6e, 0x6f, 0x64, 0x65, 0x49, 0x64, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, - 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x76, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0b, 0x6e, 0x6f, 0x64, - 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x42, 0x4e, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, - 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x63, 0x6f, 0x6e, 0x74, - 0x72, 0x61, 0x63, 0x74, 0x6b, 0x69, 0x74, 0x2f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, - 0x6b, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, - 0x65, 0x73, 0x2f, 0x73, 0x79, 0x6e, 0x63, 0x68, 0x72, 0x6f, 0x6e, 0x69, 0x7a, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x2f, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x05, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x22, 0x6d, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, + 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, + 0x61, 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, + 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, + 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, + 0x6b, 0x48, 0x61, 0x73, 0x68, 0x22, 0x4e, 0x0a, 0x0b, 0x4e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, + 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, + 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, + 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, + 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6e, 0x6f, 0x64, 0x65, 0x56, 0x65, + 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0x91, 0x01, 0x0a, 0x16, 0x41, 0x75, 0x74, 0x6f, 0x6d, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x65, 0x6c, 0x65, 0x6d, 0x57, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, + 0x12, 0x37, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x2e, 0x42, + 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x48, 0x00, 0x52, 0x0b, 0x62, 0x6c, + 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x37, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, + 0x65, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, + 0x12, 0x2e, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, + 0x69, 0x6f, 0x6e, 0x48, 0x00, 0x52, 0x0b, 0x6e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, + 0x6f, 0x6e, 0x42, 0x05, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x42, 0x4e, 0x5a, 0x4c, 0x67, 0x69, 0x74, + 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x63, 0x6f, 0x6e, + 0x74, 0x72, 0x61, 0x63, 0x74, 0x6b, 0x69, 0x74, 0x2f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x69, + 0x6e, 0x6b, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, + 0x63, 0x65, 0x73, 0x2f, 0x73, 0x79, 0x6e, 0x63, 0x68, 0x72, 0x6f, 0x6e, 0x69, 0x7a, 0x61, 0x74, + 0x69, 0x6f, 0x6e, 0x2f, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, + 0x33, } var ( @@ -194,17 +266,20 @@ func file_telem_automation_custom_proto_rawDescGZIP() []byte { return file_telem_automation_custom_proto_rawDescData } -var file_telem_automation_custom_proto_msgTypes = make([]protoimpl.MessageInfo, 2) +var file_telem_automation_custom_proto_msgTypes = make([]protoimpl.MessageInfo, 3) var file_telem_automation_custom_proto_goTypes = []interface{}{ - (*BlockNumber)(nil), // 0: telem.BlockNumber - (*NodeVersion)(nil), // 1: telem.NodeVersion + (*BlockNumber)(nil), // 0: telem.BlockNumber + (*NodeVersion)(nil), // 1: telem.NodeVersion + (*AutomationTelemWrapper)(nil), // 2: telem.AutomationTelemWrapper } var file_telem_automation_custom_proto_depIdxs = []int32{ - 0, // [0:0] is the sub-list for method output_type - 0, // [0:0] is the sub-list for method input_type - 0, // [0:0] is the sub-list for extension type_name - 0, // [0:0] is the sub-list for extension extendee - 0, // [0:0] is the sub-list for field type_name + 0, // 0: telem.AutomationTelemWrapper.block_number:type_name -> telem.BlockNumber + 1, // 1: telem.AutomationTelemWrapper.node_version:type_name -> telem.NodeVersion + 2, // [2:2] is the sub-list for method output_type + 2, // [2:2] is the sub-list for method input_type + 2, // [2:2] is the sub-list for extension type_name + 2, // [2:2] is the sub-list for extension extendee + 0, // [0:2] is the sub-list for field type_name } func init() { file_telem_automation_custom_proto_init() } @@ -237,6 +312,22 @@ func file_telem_automation_custom_proto_init() { return nil } } + file_telem_automation_custom_proto_msgTypes[2].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*AutomationTelemWrapper); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + } + file_telem_automation_custom_proto_msgTypes[2].OneofWrappers = []interface{}{ + (*AutomationTelemWrapper_BlockNumber)(nil), + (*AutomationTelemWrapper_NodeVersion)(nil), } type x struct{} out := protoimpl.TypeBuilder{ @@ -244,7 +335,7 @@ func file_telem_automation_custom_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_telem_automation_custom_proto_rawDesc, NumEnums: 0, - NumMessages: 2, + NumMessages: 3, NumExtensions: 0, NumServices: 0, }, diff --git a/core/services/synchronization/telem/telem_automation_custom.proto b/core/services/synchronization/telem/telem_automation_custom.proto index c83ca5bbf27..a1b338c6899 100644 --- a/core/services/synchronization/telem/telem_automation_custom.proto +++ b/core/services/synchronization/telem/telem_automation_custom.proto @@ -5,16 +5,21 @@ option go_package = "github.com/smartcontractkit/chainlink/v2/core/services/sync package telem; message BlockNumber { - string node_id = 1; - uint64 timetsamp = 2; - uint64 block_number = 3; - string block_hash = 4; + uint64 timestamp = 1; + uint64 block_number = 2; + string block_hash = 3; } message NodeVersion { - string node_id = 1; - uint64 timestamp = 2; - uint32 node_version = 3; + uint64 timestamp = 1; + string node_version = 2; +} + +message AutomationTelemWrapper{ + oneof msg { + BlockNumber block_number = 1; + NodeVersion node_version = 2; + } } // // StreamsLookup contains the metadata about a mercury request From 7558a6435363d201b7830b87bc0a6ca7dac21d53 Mon Sep 17 00:00:00 2001 From: Lukasz <120112546+lukaszcl@users.noreply.github.com> Date: Mon, 31 Jul 2023 22:48:08 +0200 Subject: [PATCH 044/270] Decouple chainlink client used in tests from K8s (#9779) * Decouple chainlink client used in tests Chainlink node client should be decoupled from K8s. This allows to use it in non-k8s environments like local docker containers. * Fix k8 client * Fix --- integration-tests/actions/actions.go | 26 +- .../actions/automation_ocr_helpers.go | 7 +- integration-tests/actions/keeper_helpers.go | 6 +- integration-tests/actions/ocr2_helpers.go | 14 +- .../ocr2vrf_actions/ocr2vrf_config_helpers.go | 8 +- .../actions/ocr2vrf_actions/ocr2vrf_steps.go | 4 +- integration-tests/actions/ocr_helpers.go | 28 +- .../actions/operator_forwarder_helpers.go | 2 +- .../actions/vrfv2_actions/vrfv2_steps.go | 6 +- integration-tests/client/chainlink.go | 271 ++++++------------ integration-tests/client/chainlink_k8s.go | 125 ++++++++ integration-tests/client/chainlink_models.go | 34 ++- .../contracts/contract_models.go | 2 +- .../contracts/ethereum_contracts.go | 4 +- integration-tests/performance/cron_test.go | 8 +- .../performance/directrequest_test.go | 4 +- integration-tests/performance/flux_test.go | 4 +- integration-tests/performance/keeper_test.go | 6 +- integration-tests/performance/ocr_test.go | 2 +- integration-tests/performance/vrf_test.go | 2 +- integration-tests/reorg/reorg_test.go | 2 +- integration-tests/smoke/automation_test.go | 2 +- integration-tests/smoke/keeper_test.go | 2 +- integration-tests/soak/vrfv2_test.go | 2 +- integration-tests/testsetups/don_evm_chain.go | 2 +- .../testsetups/keeper_benchmark.go | 4 +- integration-tests/testsetups/ocr.go | 6 +- integration-tests/testsetups/profile.go | 6 +- integration-tests/testsetups/vrfv2.go | 6 +- 29 files changed, 313 insertions(+), 282 deletions(-) create mode 100644 integration-tests/client/chainlink_k8s.go diff --git a/integration-tests/actions/actions.go b/integration-tests/actions/actions.go index 9ca2e341233..759bd552c37 100644 --- a/integration-tests/actions/actions.go +++ b/integration-tests/actions/actions.go @@ -32,7 +32,7 @@ var ContractDeploymentInterval = 200 // FundChainlinkNodes will fund all of the provided Chainlink nodes with a set amount of native currency func FundChainlinkNodes( - nodes []*client.Chainlink, + nodes []*client.ChainlinkK8sClient, client blockchain.EVMClient, amount *big.Float, ) error { @@ -55,7 +55,7 @@ func FundChainlinkNodes( // FundChainlinkNodesAddress will fund all of the provided Chainlink nodes address at given index with a set amount of native currency func FundChainlinkNodesAddress( - nodes []*client.Chainlink, + nodes []*client.ChainlinkK8sClient, client blockchain.EVMClient, amount *big.Float, keyIndex int, @@ -79,7 +79,7 @@ func FundChainlinkNodesAddress( // FundChainlinkNodesAddress will fund all of the provided Chainlink nodes addresses with a set amount of native currency func FundChainlinkNodesAddresses( - nodes []*client.Chainlink, + nodes []*client.ChainlinkK8sClient, client blockchain.EVMClient, amount *big.Float, ) error { @@ -104,7 +104,7 @@ func FundChainlinkNodesAddresses( // FundChainlinkNodes will fund all of the provided Chainlink nodes with a set amount of native currency func FundChainlinkNodesLink( - nodes []*client.Chainlink, + nodes []*client.ChainlinkK8sClient, blockchain blockchain.EVMClient, linkToken contracts.LinkToken, linkAmount *big.Int, @@ -123,7 +123,7 @@ func FundChainlinkNodesLink( } // ChainlinkNodeAddresses will return all the on-chain wallet addresses for a set of Chainlink nodes -func ChainlinkNodeAddresses(nodes []*client.Chainlink) ([]common.Address, error) { +func ChainlinkNodeAddresses(nodes []*client.ChainlinkK8sClient) ([]common.Address, error) { addresses := make([]common.Address, 0) for _, node := range nodes { primaryAddress, err := node.PrimaryEthAddress() @@ -136,7 +136,7 @@ func ChainlinkNodeAddresses(nodes []*client.Chainlink) ([]common.Address, error) } // ChainlinkNodeAddressesAtIndex will return all the on-chain wallet addresses for a set of Chainlink nodes -func ChainlinkNodeAddressesAtIndex(nodes []*client.Chainlink, keyIndex int) ([]common.Address, error) { +func ChainlinkNodeAddressesAtIndex(nodes []*client.ChainlinkK8sClient, keyIndex int) ([]common.Address, error) { addresses := make([]common.Address, 0) for _, node := range nodes { nodeAddresses, err := node.EthAddresses() @@ -149,7 +149,7 @@ func ChainlinkNodeAddressesAtIndex(nodes []*client.Chainlink, keyIndex int) ([]c } // SetChainlinkAPIPageSize specifies the page size from the Chainlink API, useful for high volume testing -func SetChainlinkAPIPageSize(nodes []*client.Chainlink, pageSize int) { +func SetChainlinkAPIPageSize(nodes []*client.ChainlinkK8sClient, pageSize int) { for _, n := range nodes { n.SetPageSize(pageSize) } @@ -192,7 +192,7 @@ func EncodeOnChainVRFProvingKey(vrfKey client.VRFKey) ([2]*big.Int, error) { // GetMockserverInitializerDataForOTPE creates mocked weiwatchers data needed for otpe func GetMockserverInitializerDataForOTPE( OCRInstances []contracts.OffchainAggregator, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, ) (interface{}, error) { var contractsInfo []ctfClient.ContractInfoJSON @@ -240,7 +240,7 @@ func TeardownSuite( t *testing.T, env *environment.Environment, logsFolderPath string, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, optionalTestReporter testreporters.TestReporter, // Optionally pass in a test reporter to log further metrics failingLogLevel zapcore.Level, // Examines logs after the test, and fails the test if any Chainlink logs are found at or above provided level clients ...blockchain.EVMClient, @@ -285,7 +285,7 @@ func TeardownSuite( func TeardownRemoteSuite( t *testing.T, env *environment.Environment, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, optionalTestReporter testreporters.TestReporter, // Optionally pass in a test reporter to log further metrics client blockchain.EVMClient, ) error { @@ -308,7 +308,7 @@ func TeardownRemoteSuite( return err } -func DeleteAllJobs(chainlinkNodes []*client.Chainlink) error { +func DeleteAllJobs(chainlinkNodes []*client.ChainlinkK8sClient) error { for _, node := range chainlinkNodes { jobs, _, err := node.ReadJobs() if err != nil { @@ -329,7 +329,7 @@ func DeleteAllJobs(chainlinkNodes []*client.Chainlink) error { } // Returns all the funds from the chainlink nodes to the networks default address -func returnFunds(chainlinkNodes []*client.Chainlink, blockchainClient blockchain.EVMClient) error { +func returnFunds(chainlinkNodes []*client.ChainlinkK8sClient, blockchainClient blockchain.EVMClient) error { if blockchainClient == nil { log.Warn().Msg("No blockchain client found, unable to return funds from chainlink nodes.") } @@ -391,7 +391,7 @@ func EncodeOnChainExternalJobID(jobID uuid.UUID) [32]byte { func UpgradeChainlinkNodeVersions( testEnvironment *environment.Environment, newImage, newVersion string, - nodes ...*client.Chainlink, + nodes ...*client.ChainlinkK8sClient, ) error { if newImage == "" && newVersion == "" { return errors.New("unable to upgrade node version, found empty image and version, must provide either a new image or a new version") diff --git a/integration-tests/actions/automation_ocr_helpers.go b/integration-tests/actions/automation_ocr_helpers.go index 350943dbb6a..01abbeb3188 100644 --- a/integration-tests/actions/automation_ocr_helpers.go +++ b/integration-tests/actions/automation_ocr_helpers.go @@ -30,7 +30,7 @@ import ( func BuildAutoOCR2ConfigVars( t *testing.T, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, registryConfig contracts.KeeperRegistrySettings, registrar string, deltaStage time.Duration, @@ -40,7 +40,7 @@ func BuildAutoOCR2ConfigVars( func BuildAutoOCR2ConfigVarsWithKeyIndex( t *testing.T, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, registryConfig contracts.KeeperRegistrySettings, registrar string, deltaStage time.Duration, @@ -119,14 +119,13 @@ func BuildAutoOCR2ConfigVarsWithKeyIndex( // CreateOCRKeeperJobs bootstraps the first node and to the other nodes sends ocr jobs func CreateOCRKeeperJobs( t *testing.T, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, registryAddr string, chainID int64, keyIndex int, ) { l := utils.GetTestLogger(t) bootstrapNode := chainlinkNodes[0] - bootstrapNode.InternalIP() bootstrapP2PIds, err := bootstrapNode.MustReadP2PKeys() require.NoError(t, err, "Shouldn't fail reading P2P keys from bootstrap node") bootstrapP2PId := bootstrapP2PIds.Data[0].Attributes.PeerID diff --git a/integration-tests/actions/keeper_helpers.go b/integration-tests/actions/keeper_helpers.go index f83e2dd6dd4..4a1ad439766 100644 --- a/integration-tests/actions/keeper_helpers.go +++ b/integration-tests/actions/keeper_helpers.go @@ -24,7 +24,7 @@ var ZeroAddress = common.Address{} func CreateKeeperJobs( t *testing.T, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, keeperRegistry contracts.KeeperRegistry, ocrConfig contracts.OCRv2Config, ) { @@ -57,7 +57,7 @@ func CreateKeeperJobs( func CreateKeeperJobsWithKeyIndex( t *testing.T, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, keeperRegistry contracts.KeeperRegistry, keyIndex int, ocrConfig contracts.OCRv2Config, @@ -89,7 +89,7 @@ func CreateKeeperJobsWithKeyIndex( } } -func DeleteKeeperJobsWithId(t *testing.T, chainlinkNodes []*client.Chainlink, id int) { +func DeleteKeeperJobsWithId(t *testing.T, chainlinkNodes []*client.ChainlinkK8sClient, id int) { for _, chainlinkNode := range chainlinkNodes { err := chainlinkNode.MustDeleteJob(strconv.Itoa(id)) require.NoError(t, err, "Deleting KeeperV2 Job shouldn't fail") diff --git a/integration-tests/actions/ocr2_helpers.go b/integration-tests/actions/ocr2_helpers.go index 6c7d054be00..3c37233a0d3 100644 --- a/integration-tests/actions/ocr2_helpers.go +++ b/integration-tests/actions/ocr2_helpers.go @@ -101,7 +101,7 @@ func ConfigureOCRv2AggregatorContracts( } // BuildMedianOCR2Config builds a default OCRv2 config for the given chainlink nodes for a standard median aggregation job -func BuildMedianOCR2Config(workerNodes []*client.Chainlink) (*contracts.OCRv2Config, error) { +func BuildMedianOCR2Config(workerNodes []*client.ChainlinkK8sClient) (*contracts.OCRv2Config, error) { S, oracleIdentities, err := GetOracleIdentities(workerNodes) if err != nil { return nil, err @@ -157,13 +157,13 @@ func BuildMedianOCR2Config(workerNodes []*client.Chainlink) (*contracts.OCRv2Con } // GetOracleIdentities retrieves all chainlink nodes' OCR2 config identities with defaul key index -func GetOracleIdentities(chainlinkNodes []*client.Chainlink) ([]int, []confighelper.OracleIdentityExtra, error) { +func GetOracleIdentities(chainlinkNodes []*client.ChainlinkK8sClient) ([]int, []confighelper.OracleIdentityExtra, error) { return GetOracleIdentitiesWithKeyIndex(chainlinkNodes, 0) } // GetOracleIdentitiesWithKeyIndex retrieves all chainlink nodes' OCR2 config identities by key index func GetOracleIdentitiesWithKeyIndex( - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, keyIndex int, ) ([]int, []confighelper.OracleIdentityExtra, error) { S := make([]int, len(chainlinkNodes)) @@ -203,7 +203,7 @@ func GetOracleIdentitiesWithKeyIndex( offchainPkBytesFixed := [ed25519.PublicKeySize]byte{} n := copy(offchainPkBytesFixed[:], offchainPkBytes) if n != ed25519.PublicKeySize { - return fmt.Errorf("Wrong number of elements copied") + return fmt.Errorf("wrong number of elements copied") } configPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.ConfigPublicKey, "ocr2cfg_evm_")) @@ -214,7 +214,7 @@ func GetOracleIdentitiesWithKeyIndex( configPkBytesFixed := [ed25519.PublicKeySize]byte{} n = copy(configPkBytesFixed[:], configPkBytes) if n != ed25519.PublicKeySize { - return fmt.Errorf("Wrong number of elements copied") + return fmt.Errorf("wrong number of elements copied") } onchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OnChainPublicKey, "ocr2on_evm_")) @@ -251,8 +251,8 @@ func GetOracleIdentitiesWithKeyIndex( // read from different adapters, to be used in combination with SetAdapterResponses func CreateOCRv2Jobs( ocrInstances []contracts.OffchainAggregatorV2, - bootstrapNode *client.Chainlink, - workerChainlinkNodes []*client.Chainlink, + bootstrapNode *client.ChainlinkK8sClient, + workerChainlinkNodes []*client.ChainlinkK8sClient, mockserver *ctfClient.MockserverClient, mockServerPath string, // Path on the mock server for the Chainlink nodes to query mockServerValue int, // Value to get from the mock server when querying the path diff --git a/integration-tests/actions/ocr2vrf_actions/ocr2vrf_config_helpers.go b/integration-tests/actions/ocr2vrf_actions/ocr2vrf_config_helpers.go index 83033710f41..05b983c2f1e 100644 --- a/integration-tests/actions/ocr2vrf_actions/ocr2vrf_config_helpers.go +++ b/integration-tests/actions/ocr2vrf_actions/ocr2vrf_config_helpers.go @@ -33,8 +33,8 @@ import ( // CreateOCR2VRFJobs bootstraps the first node and to the other nodes sends ocr jobs func CreateOCR2VRFJobs( t *testing.T, - bootstrapNode *client.Chainlink, - nonBootstrapNodes []*client.Chainlink, + bootstrapNode *client.ChainlinkK8sClient, + nonBootstrapNodes []*client.ChainlinkK8sClient, OCR2VRFPluginConfig *OCR2VRFPluginConfig, chainID int64, keyIndex int, @@ -48,7 +48,7 @@ func CreateOCR2VRFJobs( func createNonBootstrapJobs( t *testing.T, - nonBootstrapNodes []*client.Chainlink, + nonBootstrapNodes []*client.ChainlinkK8sClient, OCR2VRFPluginConfig *OCR2VRFPluginConfig, chainID int64, keyIndex int, @@ -95,7 +95,7 @@ func createNonBootstrapJobs( } } -func createBootstrapJob(t *testing.T, bootstrapNode *client.Chainlink, dkgAddress string, chainID int64) string { +func createBootstrapJob(t *testing.T, bootstrapNode *client.ChainlinkK8sClient, dkgAddress string, chainID int64) string { bootstrapP2PIds, err := bootstrapNode.MustReadP2PKeys() require.NoError(t, err, "Shouldn't fail reading P2P keys from bootstrap node") bootstrapP2PId := bootstrapP2PIds.Data[0].Attributes.PeerID diff --git a/integration-tests/actions/ocr2vrf_actions/ocr2vrf_steps.go b/integration-tests/actions/ocr2vrf_actions/ocr2vrf_steps.go index e78ac9828fb..c550fe73a22 100644 --- a/integration-tests/actions/ocr2vrf_actions/ocr2vrf_steps.go +++ b/integration-tests/actions/ocr2vrf_actions/ocr2vrf_steps.go @@ -72,7 +72,7 @@ func SetAndWaitForDKGProcessToFinish(t *testing.T, ocr2VRFPluginConfig *OCR2VRFP func SetAndGetOCR2VRFPluginConfig( t *testing.T, - nonBootstrapNodes []*client.Chainlink, + nonBootstrapNodes []*client.ChainlinkK8sClient, dkg contracts.DKG, vrfBeacon contracts.VRFBeacon, coordinator contracts.VRFCoordinatorV3, @@ -292,7 +292,7 @@ func SetupOCR2VRFUniverse( contractDeployer contracts.ContractDeployer, chainClient blockchain.EVMClient, nodeAddresses []common.Address, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, testNetwork blockchain.EVMNetwork, ) (contracts.DKG, contracts.VRFCoordinatorV3, contracts.VRFBeacon, contracts.VRFBeaconConsumer, *big.Int) { diff --git a/integration-tests/actions/ocr_helpers.go b/integration-tests/actions/ocr_helpers.go index 0325a64f101..9531123c970 100644 --- a/integration-tests/actions/ocr_helpers.go +++ b/integration-tests/actions/ocr_helpers.go @@ -26,8 +26,8 @@ func DeployOCRContracts( numberOfContracts int, linkTokenContract contracts.LinkToken, contractDeployer contracts.ContractDeployer, - bootstrapNode *client.Chainlink, - workerNodes []*client.Chainlink, + bootstrapNode *client.ChainlinkK8sClient, + workerNodes []*client.ChainlinkK8sClient, client blockchain.EVMClient, ) ([]contracts.OffchainAggregator, error) { // Deploy contracts @@ -118,7 +118,7 @@ func DeployOCRContractsForwarderFlow( numberOfContracts int, linkTokenContract contracts.LinkToken, contractDeployer contracts.ContractDeployer, - workerNodes []*client.Chainlink, + workerNodes []*client.ChainlinkK8sClient, forwarderAddresses []common.Address, client blockchain.EVMClient, ) []contracts.OffchainAggregator { @@ -182,8 +182,8 @@ func DeployOCRContractsForwarderFlow( // read from different adapters, to be used in combination with SetAdapterResponses func CreateOCRJobs( ocrInstances []contracts.OffchainAggregator, - bootstrapNode *client.Chainlink, - workerNodes []*client.Chainlink, + bootstrapNode *client.ChainlinkK8sClient, + workerNodes []*client.ChainlinkK8sClient, mockValue int, mockserver *ctfClient.MockserverClient, ) error { @@ -237,10 +237,11 @@ func CreateOCRJobs( return fmt.Errorf("creating bridge job have failed: %w", err) } + bootstrapPeers := []*client.ChainlinkClient{bootstrapNode.ChainlinkClient} ocrSpec := &client.OCRTaskJobSpec{ ContractAddress: ocrInstance.Address(), P2PPeerID: nodeP2PId, - P2PBootstrapPeers: []*client.Chainlink{bootstrapNode}, + P2PBootstrapPeers: bootstrapPeers, KeyBundleID: nodeOCRKeyId, TransmitterAddress: nodeTransmitterAddress, ObservationSource: client.ObservationSourceSpecBridge(bta), @@ -259,8 +260,8 @@ func CreateOCRJobs( func CreateOCRJobsWithForwarder( t *testing.T, ocrInstances []contracts.OffchainAggregator, - bootstrapNode *client.Chainlink, - workerNodes []*client.Chainlink, + bootstrapNode *client.ChainlinkK8sClient, + workerNodes []*client.ChainlinkK8sClient, mockValue int, mockserver *ctfClient.MockserverClient, ) { @@ -298,10 +299,11 @@ func CreateOCRJobsWithForwarder( err = node.MustCreateBridge(bta) require.NoError(t, err, "Failed creating bridge on OCR node %d", nodeIndex+1) + bootstrapPeers := []*client.ChainlinkClient{bootstrapNode.ChainlinkClient} ocrSpec := &client.OCRTaskJobSpec{ ContractAddress: ocrInstance.Address(), P2PPeerID: nodeP2PId, - P2PBootstrapPeers: []*client.Chainlink{bootstrapNode}, + P2PBootstrapPeers: bootstrapPeers, KeyBundleID: nodeOCRKeyId, TransmitterAddress: nodeTransmitterAddress, ObservationSource: client.ObservationSourceSpecBridge(bta), @@ -338,7 +340,7 @@ func StartNewRound( func SetAdapterResponse( response int, ocrInstance contracts.OffchainAggregator, - chainlinkNode *client.Chainlink, + chainlinkNode *client.ChainlinkK8sClient, mockserver *ctfClient.MockserverClient, ) error { nodeContractPairID, err := BuildNodeContractPairID(chainlinkNode, ocrInstance) @@ -358,7 +360,7 @@ func SetAdapterResponse( func SetAllAdapterResponsesToTheSameValue( response int, ocrInstances []contracts.OffchainAggregator, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, mockserver *ctfClient.MockserverClient, ) error { eg := &errgroup.Group{} @@ -380,7 +382,7 @@ func SetAllAdapterResponsesToDifferentValues( t *testing.T, responses []int, ocrInstances []contracts.OffchainAggregator, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, mockserver *ctfClient.MockserverClient, ) { require.Equal(t, len(chainlinkNodes)-1, len(responses), @@ -394,7 +396,7 @@ func SetAllAdapterResponsesToDifferentValues( } // BuildNodeContractPairID builds a UUID based on a related pair of a Chainlink node and OCR contract -func BuildNodeContractPairID(node *client.Chainlink, ocrInstance contracts.OffchainAggregator) (string, error) { +func BuildNodeContractPairID(node *client.ChainlinkK8sClient, ocrInstance contracts.OffchainAggregator) (string, error) { if node == nil { return "", fmt.Errorf("chainlink node is nil") } diff --git a/integration-tests/actions/operator_forwarder_helpers.go b/integration-tests/actions/operator_forwarder_helpers.go index b812fb18b71..7add64fbe99 100644 --- a/integration-tests/actions/operator_forwarder_helpers.go +++ b/integration-tests/actions/operator_forwarder_helpers.go @@ -184,7 +184,7 @@ func TrackForwarder( t *testing.T, chainClient blockchain.EVMClient, authorizedForwarder common.Address, - node *client.Chainlink, + node *client.ChainlinkK8sClient, ) { l := utils.GetTestLogger(t) chainID := chainClient.GetChainID() diff --git a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go index 73debdbecc5..153a8fae6fa 100644 --- a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go +++ b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go @@ -48,7 +48,7 @@ func DeployVRFV2Contracts( func CreateVRFV2Jobs( t *testing.T, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, coordinator contracts.VRFCoordinatorV2, c blockchain.EVMClient, minIncomingConfirmations uint16, @@ -125,14 +125,14 @@ func SetupVRFV2Universe( mockETHLinkFeed contracts.MockETHLINKFeed, contractDeployer contracts.ContractDeployer, chainClient blockchain.EVMClient, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, testNetwork blockchain.EVMNetwork, existingTestEnvironment *environment.Environment, chainlinkNodeFundingAmountEth *big.Float, vrfSubscriptionFundingAmountInLink *big.Int, newEnvNamespacePrefix string, newEnvTTL time.Duration, -) (VRFV2Contracts, []*client.Chainlink, []VRFV2JobInfo, *environment.Environment) { +) (VRFV2Contracts, []*client.ChainlinkK8sClient, []VRFV2JobInfo, *environment.Environment) { vrfV2Contracts := DeployVRFV2Contracts( t, diff --git a/integration-tests/client/chainlink.go b/integration-tests/client/chainlink.go index b87377ca4e2..4f1c1f2c818 100644 --- a/integration-tests/client/chainlink.go +++ b/integration-tests/client/chainlink.go @@ -5,8 +5,6 @@ import ( "fmt" "math/big" "net/http" - "os" - "regexp" "strings" "sync" "time" @@ -15,8 +13,6 @@ import ( "github.com/go-resty/resty/v2" "github.com/rs/zerolog/log" "golang.org/x/sync/errgroup" - - "github.com/smartcontractkit/chainlink-env/environment" ) const ( @@ -36,7 +32,7 @@ var ( } ) -type Chainlink struct { +type ChainlinkClient struct { APIClient *resty.Client Config *ChainlinkConfig pageSize int @@ -44,16 +40,25 @@ type Chainlink struct { ethAddresses []string } -// NewChainlink creates a new Chainlink model using a provided config -func NewChainlink(c *ChainlinkConfig) (*Chainlink, error) { - rc := resty.New().SetBaseURL(c.URL) - - if c.HTTPTimeout != nil { - rc.SetTimeout(*c.HTTPTimeout) +// NewChainlinkClient creates a new Chainlink model using a provided config +func NewChainlinkClient(c *ChainlinkConfig) (*ChainlinkClient, error) { + rc, err := initRestyClient(c.URL, c.Email, c.Password, c.HTTPTimeout) + if err != nil { + return nil, err } + return &ChainlinkClient{ + Config: c, + APIClient: rc, + pageSize: 25, + }, nil +} - session := &Session{Email: c.Email, Password: c.Password} - +func initRestyClient(url string, email string, password string, timeout *time.Duration) (*resty.Client, error) { + rc := resty.New().SetBaseURL(url) + if timeout != nil { + rc.SetTimeout(*timeout) + } + session := &Session{Email: email, Password: password} // Retry the connection on boot up, sometimes pods can still be starting up and not ready to accept connections var resp *resty.Response var err error @@ -61,9 +66,9 @@ func NewChainlink(c *ChainlinkConfig) (*Chainlink, error) { for i := 0; i < retryCount; i++ { resp, err = rc.R().SetBody(session).Post("/sessions") if err != nil { - log.Debug().Err(err).Str("URL", c.URL).Interface("Session Details", session).Msg("Error connecting to Chainlink node, retrying") + log.Debug().Err(err).Str("URL", url).Interface("Session Details", session).Msg("Error connecting to Chainlink node, retrying") time.Sleep(3 * time.Second) - } else { // Connection successful + } else { break } } @@ -71,25 +76,16 @@ func NewChainlink(c *ChainlinkConfig) (*Chainlink, error) { return nil, fmt.Errorf("error connecting to chainlink node after %d attempts: %w", retryCount, err) } rc.SetCookies(resp.Cookies()) - return &Chainlink{ - Config: c, - APIClient: rc, - pageSize: 25, - }, nil + return rc, nil } // URL Chainlink instance http url -func (c *Chainlink) URL() string { +func (c *ChainlinkClient) URL() string { return c.Config.URL } -// Name Chainlink instance chart/service name -func (c *Chainlink) Name() string { - return c.Config.ChartName -} - // CreateJobRaw creates a Chainlink job based on the provided spec string -func (c *Chainlink) CreateJobRaw(spec string) (*Job, *http.Response, error) { +func (c *ChainlinkClient) CreateJobRaw(spec string) (*Job, *http.Response, error) { job := &Job{} log.Info().Str("Node URL", c.Config.URL).Msg("Creating Job") log.Trace().Str("Node URL", c.Config.URL).Str("Job Body", spec).Msg("Creating Job") @@ -107,7 +103,7 @@ func (c *Chainlink) CreateJobRaw(spec string) (*Job, *http.Response, error) { // MustCreateJob creates a Chainlink job based on the provided spec struct and returns error if // the request is unsuccessful -func (c *Chainlink) MustCreateJob(spec JobSpec) (*Job, error) { +func (c *ChainlinkClient) MustCreateJob(spec JobSpec) (*Job, error) { job, resp, err := c.CreateJob(spec) if err != nil { return nil, err @@ -116,7 +112,7 @@ func (c *Chainlink) MustCreateJob(spec JobSpec) (*Job, error) { } // CreateJob creates a Chainlink job based on the provided spec struct -func (c *Chainlink) CreateJob(spec JobSpec) (*Job, *http.Response, error) { +func (c *ChainlinkClient) CreateJob(spec JobSpec) (*Job, *http.Response, error) { job := &Job{} specString, err := spec.String() if err != nil { @@ -137,7 +133,7 @@ func (c *Chainlink) CreateJob(spec JobSpec) (*Job, *http.Response, error) { } // ReadJobs reads all jobs from the Chainlink node -func (c *Chainlink) ReadJobs() (*ResponseSlice, *http.Response, error) { +func (c *ChainlinkClient) ReadJobs() (*ResponseSlice, *http.Response, error) { specObj := &ResponseSlice{} log.Info().Str(NodeURL, c.Config.URL).Msg("Getting Jobs") resp, err := c.APIClient.R(). @@ -150,7 +146,7 @@ func (c *Chainlink) ReadJobs() (*ResponseSlice, *http.Response, error) { } // ReadJob reads a job with the provided ID from the Chainlink node -func (c *Chainlink) ReadJob(id string) (*Response, *http.Response, error) { +func (c *ChainlinkClient) ReadJob(id string) (*Response, *http.Response, error) { specObj := &Response{} log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Reading Job") resp, err := c.APIClient.R(). @@ -167,7 +163,7 @@ func (c *Chainlink) ReadJob(id string) (*Response, *http.Response, error) { // MustDeleteJob deletes a job with a provided ID from the Chainlink node and returns error if // the request is unsuccessful -func (c *Chainlink) MustDeleteJob(id string) error { +func (c *ChainlinkClient) MustDeleteJob(id string) error { resp, err := c.DeleteJob(id) if err != nil { return err @@ -176,7 +172,7 @@ func (c *Chainlink) MustDeleteJob(id string) error { } // DeleteJob deletes a job with a provided ID from the Chainlink node -func (c *Chainlink) DeleteJob(id string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteJob(id string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Deleting Job") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -190,7 +186,7 @@ func (c *Chainlink) DeleteJob(id string) (*http.Response, error) { } // CreateSpec creates a job spec on the Chainlink node -func (c *Chainlink) CreateSpec(spec string) (*Spec, *http.Response, error) { +func (c *ChainlinkClient) CreateSpec(spec string) (*Spec, *http.Response, error) { s := &Spec{} r := strings.NewReplacer("\n", "", " ", "", "\\", "") // Makes it more compact and readable for logging log.Info().Str(NodeURL, c.Config.URL).Str("Spec", r.Replace(spec)).Msg("Creating Spec") @@ -205,7 +201,7 @@ func (c *Chainlink) CreateSpec(spec string) (*Spec, *http.Response, error) { } // ReadSpec reads a job spec with the provided ID on the Chainlink node -func (c *Chainlink) ReadSpec(id string) (*Response, *http.Response, error) { +func (c *ChainlinkClient) ReadSpec(id string) (*Response, *http.Response, error) { specObj := &Response{} log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Reading Spec") resp, err := c.APIClient.R(). @@ -222,7 +218,7 @@ func (c *Chainlink) ReadSpec(id string) (*Response, *http.Response, error) { // MustReadRunsByJob attempts to read all runs for a job and returns error if // the request is unsuccessful -func (c *Chainlink) MustReadRunsByJob(jobID string) (*JobRunsResponse, error) { +func (c *ChainlinkClient) MustReadRunsByJob(jobID string) (*JobRunsResponse, error) { runsObj, resp, err := c.ReadRunsByJob(jobID) if err != nil { return nil, err @@ -231,7 +227,7 @@ func (c *Chainlink) MustReadRunsByJob(jobID string) (*JobRunsResponse, error) { } // ReadRunsByJob reads all runs for a job -func (c *Chainlink) ReadRunsByJob(jobID string) (*JobRunsResponse, *http.Response, error) { +func (c *ChainlinkClient) ReadRunsByJob(jobID string) (*JobRunsResponse, *http.Response, error) { runsObj := &JobRunsResponse{} log.Debug().Str(NodeURL, c.Config.URL).Str("JobID", jobID).Msg("Reading runs for a job") resp, err := c.APIClient.R(). @@ -247,7 +243,7 @@ func (c *Chainlink) ReadRunsByJob(jobID string) (*JobRunsResponse, *http.Respons } // DeleteSpec deletes a job spec with the provided ID from the Chainlink node -func (c *Chainlink) DeleteSpec(id string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteSpec(id string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Deleting Spec") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -262,7 +258,7 @@ func (c *Chainlink) DeleteSpec(id string) (*http.Response, error) { // MustCreateBridge creates a bridge on the Chainlink node based on the provided attributes and returns error if // the request is unsuccessful -func (c *Chainlink) MustCreateBridge(bta *BridgeTypeAttributes) error { +func (c *ChainlinkClient) MustCreateBridge(bta *BridgeTypeAttributes) error { resp, err := c.CreateBridge(bta) if err != nil { return err @@ -270,7 +266,7 @@ func (c *Chainlink) MustCreateBridge(bta *BridgeTypeAttributes) error { return VerifyStatusCode(resp.StatusCode, http.StatusOK) } -func (c *Chainlink) CreateBridge(bta *BridgeTypeAttributes) (*http.Response, error) { +func (c *ChainlinkClient) CreateBridge(bta *BridgeTypeAttributes) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("Name", bta.Name).Msg("Creating Bridge") resp, err := c.APIClient.R(). SetBody(bta). @@ -282,7 +278,7 @@ func (c *Chainlink) CreateBridge(bta *BridgeTypeAttributes) (*http.Response, err } // ReadBridge reads a bridge from the Chainlink node based on the provided name -func (c *Chainlink) ReadBridge(name string) (*BridgeType, *http.Response, error) { +func (c *ChainlinkClient) ReadBridge(name string) (*BridgeType, *http.Response, error) { bt := BridgeType{} log.Info().Str(NodeURL, c.Config.URL).Str("Name", name).Msg("Reading Bridge") resp, err := c.APIClient.R(). @@ -298,7 +294,7 @@ func (c *Chainlink) ReadBridge(name string) (*BridgeType, *http.Response, error) } // DeleteBridge deletes a bridge on the Chainlink node based on the provided name -func (c *Chainlink) DeleteBridge(name string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteBridge(name string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("Name", name).Msg("Deleting Bridge") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -312,7 +308,7 @@ func (c *Chainlink) DeleteBridge(name string) (*http.Response, error) { } // CreateOCRKey creates an OCRKey on the Chainlink node -func (c *Chainlink) CreateOCRKey() (*OCRKey, *http.Response, error) { +func (c *ChainlinkClient) CreateOCRKey() (*OCRKey, *http.Response, error) { ocrKey := &OCRKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating OCR Key") resp, err := c.APIClient.R(). @@ -326,7 +322,7 @@ func (c *Chainlink) CreateOCRKey() (*OCRKey, *http.Response, error) { // MustReadOCRKeys reads all OCRKeys from the Chainlink node and returns error if // the request is unsuccessful -func (c *Chainlink) MustReadOCRKeys() (*OCRKeys, error) { +func (c *ChainlinkClient) MustReadOCRKeys() (*OCRKeys, error) { ocrKeys := &OCRKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading OCR Keys") resp, err := c.APIClient.R(). @@ -348,7 +344,7 @@ func (c *Chainlink) MustReadOCRKeys() (*OCRKeys, error) { } // DeleteOCRKey deletes an OCRKey based on the provided ID -func (c *Chainlink) DeleteOCRKey(id string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteOCRKey(id string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Deleting OCR Key") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -362,7 +358,7 @@ func (c *Chainlink) DeleteOCRKey(id string) (*http.Response, error) { } // CreateOCR2Key creates an OCR2Key on the Chainlink node -func (c *Chainlink) CreateOCR2Key(chain string) (*OCR2Key, *http.Response, error) { +func (c *ChainlinkClient) CreateOCR2Key(chain string) (*OCR2Key, *http.Response, error) { ocr2Key := &OCR2Key{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating OCR2 Key") resp, err := c.APIClient.R(). @@ -378,7 +374,7 @@ func (c *Chainlink) CreateOCR2Key(chain string) (*OCR2Key, *http.Response, error } // ReadOCR2Keys reads all OCR2Keys from the Chainlink node -func (c *Chainlink) ReadOCR2Keys() (*OCR2Keys, *http.Response, error) { +func (c *ChainlinkClient) ReadOCR2Keys() (*OCR2Keys, *http.Response, error) { ocr2Keys := &OCR2Keys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading OCR2 Keys") resp, err := c.APIClient.R(). @@ -388,7 +384,7 @@ func (c *Chainlink) ReadOCR2Keys() (*OCR2Keys, *http.Response, error) { } // MustReadOCR2Keys reads all OCR2Keys from the Chainlink node returns err if response not 200 -func (c *Chainlink) MustReadOCR2Keys() (*OCR2Keys, error) { +func (c *ChainlinkClient) MustReadOCR2Keys() (*OCR2Keys, error) { ocr2Keys := &OCR2Keys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading OCR2 Keys") resp, err := c.APIClient.R(). @@ -402,7 +398,7 @@ func (c *Chainlink) MustReadOCR2Keys() (*OCR2Keys, error) { } // DeleteOCR2Key deletes an OCR2Key based on the provided ID -func (c *Chainlink) DeleteOCR2Key(id string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteOCR2Key(id string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Deleting OCR2 Key") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -416,7 +412,7 @@ func (c *Chainlink) DeleteOCR2Key(id string) (*http.Response, error) { } // CreateP2PKey creates an P2PKey on the Chainlink node -func (c *Chainlink) CreateP2PKey() (*P2PKey, *http.Response, error) { +func (c *ChainlinkClient) CreateP2PKey() (*P2PKey, *http.Response, error) { p2pKey := &P2PKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating P2P Key") resp, err := c.APIClient.R(). @@ -430,7 +426,7 @@ func (c *Chainlink) CreateP2PKey() (*P2PKey, *http.Response, error) { // MustReadP2PKeys reads all P2PKeys from the Chainlink node and returns error if // the request is unsuccessful -func (c *Chainlink) MustReadP2PKeys() (*P2PKeys, error) { +func (c *ChainlinkClient) MustReadP2PKeys() (*P2PKeys, error) { p2pKeys := &P2PKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading P2P Keys") resp, err := c.APIClient.R(). @@ -452,7 +448,7 @@ func (c *Chainlink) MustReadP2PKeys() (*P2PKeys, error) { } // DeleteP2PKey deletes a P2PKey on the Chainlink node based on the provided ID -func (c *Chainlink) DeleteP2PKey(id int) (*http.Response, error) { +func (c *ChainlinkClient) DeleteP2PKey(id int) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Int("ID", id).Msg("Deleting P2P Key") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -467,7 +463,7 @@ func (c *Chainlink) DeleteP2PKey(id int) (*http.Response, error) { // MustReadETHKeys reads all ETH keys from the Chainlink node and returns error if // the request is unsuccessful -func (c *Chainlink) MustReadETHKeys() (*ETHKeys, error) { +func (c *ChainlinkClient) MustReadETHKeys() (*ETHKeys, error) { ethKeys := ÐKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading ETH Keys") resp, err := c.APIClient.R(). @@ -484,7 +480,7 @@ func (c *Chainlink) MustReadETHKeys() (*ETHKeys, error) { } // UpdateEthKeyMaxGasPriceGWei updates the maxGasPriceGWei for an eth key -func (c *Chainlink) UpdateEthKeyMaxGasPriceGWei(keyId string, gWei int) (*ETHKey, *http.Response, error) { +func (c *ChainlinkClient) UpdateEthKeyMaxGasPriceGWei(keyId string, gWei int) (*ETHKey, *http.Response, error) { ethKey := ÐKey{} log.Info().Str(NodeURL, c.Config.URL).Str("ID", keyId).Int("maxGasPriceGWei", gWei).Msg("Update maxGasPriceGWei for eth key") resp, err := c.APIClient.R(). @@ -507,7 +503,7 @@ func (c *Chainlink) UpdateEthKeyMaxGasPriceGWei(keyId string, gWei int) (*ETHKey } // ReadPrimaryETHKey reads updated information about the Chainlink's primary ETH key -func (c *Chainlink) ReadPrimaryETHKey() (*ETHKeyData, error) { +func (c *ChainlinkClient) ReadPrimaryETHKey() (*ETHKeyData, error) { ethKeys, err := c.MustReadETHKeys() if err != nil { return nil, err @@ -519,7 +515,7 @@ func (c *Chainlink) ReadPrimaryETHKey() (*ETHKeyData, error) { } // ReadETHKeyAtIndex reads updated information about the Chainlink's ETH key at given index -func (c *Chainlink) ReadETHKeyAtIndex(keyIndex int) (*ETHKeyData, error) { +func (c *ChainlinkClient) ReadETHKeyAtIndex(keyIndex int) (*ETHKeyData, error) { ethKeys, err := c.MustReadETHKeys() if err != nil { return nil, err @@ -531,7 +527,7 @@ func (c *Chainlink) ReadETHKeyAtIndex(keyIndex int) (*ETHKeyData, error) { } // PrimaryEthAddress returns the primary ETH address for the Chainlink node -func (c *Chainlink) PrimaryEthAddress() (string, error) { +func (c *ChainlinkClient) PrimaryEthAddress() (string, error) { if c.primaryEthAddress == "" { ethKeys, err := c.MustReadETHKeys() if err != nil { @@ -543,7 +539,7 @@ func (c *Chainlink) PrimaryEthAddress() (string, error) { } // EthAddresses returns the ETH addresses for the Chainlink node -func (c *Chainlink) EthAddresses() ([]string, error) { +func (c *ChainlinkClient) EthAddresses() ([]string, error) { if len(c.ethAddresses) == 0 { ethKeys, err := c.MustReadETHKeys() c.ethAddresses = make([]string, len(ethKeys.Data)) @@ -558,7 +554,7 @@ func (c *Chainlink) EthAddresses() ([]string, error) { } // EthAddresses returns the ETH addresses of the Chainlink node for a specific chain id -func (c *Chainlink) EthAddressesForChain(chainId string) ([]string, error) { +func (c *ChainlinkClient) EthAddressesForChain(chainId string) ([]string, error) { var ethAddresses []string ethKeys, err := c.MustReadETHKeys() if err != nil { @@ -573,7 +569,7 @@ func (c *Chainlink) EthAddressesForChain(chainId string) ([]string, error) { } // PrimaryEthAddressForChain returns the primary ETH address for the Chainlink node for mentioned chain -func (c *Chainlink) PrimaryEthAddressForChain(chainId string) (string, error) { +func (c *ChainlinkClient) PrimaryEthAddressForChain(chainId string) (string, error) { ethKeys, err := c.MustReadETHKeys() if err != nil { return "", err @@ -587,7 +583,7 @@ func (c *Chainlink) PrimaryEthAddressForChain(chainId string) (string, error) { } // ExportEVMKeys exports Chainlink private EVM keys -func (c *Chainlink) ExportEVMKeys() ([]*ExportedEVMKey, error) { +func (c *ChainlinkClient) ExportEVMKeys() ([]*ExportedEVMKey, error) { exportedKeys := make([]*ExportedEVMKey, 0) keys, err := c.MustReadETHKeys() if err != nil { @@ -615,7 +611,7 @@ func (c *Chainlink) ExportEVMKeys() ([]*ExportedEVMKey, error) { } // ExportEVMKeysForChain exports Chainlink private EVM keys for a particular chain -func (c *Chainlink) ExportEVMKeysForChain(chainid string) ([]*ExportedEVMKey, error) { +func (c *ChainlinkClient) ExportEVMKeysForChain(chainid string) ([]*ExportedEVMKey, error) { exportedKeys := make([]*ExportedEVMKey, 0) keys, err := c.MustReadETHKeys() if err != nil { @@ -643,7 +639,7 @@ func (c *Chainlink) ExportEVMKeysForChain(chainid string) ([]*ExportedEVMKey, er } // CreateTxKey creates a tx key on the Chainlink node -func (c *Chainlink) CreateTxKey(chain string, chainId string) (*TxKey, *http.Response, error) { +func (c *ChainlinkClient) CreateTxKey(chain string, chainId string) (*TxKey, *http.Response, error) { txKey := &TxKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating Tx Key") resp, err := c.APIClient.R(). @@ -660,7 +656,7 @@ func (c *Chainlink) CreateTxKey(chain string, chainId string) (*TxKey, *http.Res } // ReadTxKeys reads all tx keys from the Chainlink node -func (c *Chainlink) ReadTxKeys(chain string) (*TxKeys, *http.Response, error) { +func (c *ChainlinkClient) ReadTxKeys(chain string) (*TxKeys, *http.Response, error) { txKeys := &TxKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading Tx Keys") resp, err := c.APIClient.R(). @@ -676,7 +672,7 @@ func (c *Chainlink) ReadTxKeys(chain string) (*TxKeys, *http.Response, error) { } // DeleteTxKey deletes an tx key based on the provided ID -func (c *Chainlink) DeleteTxKey(chain string, id string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteTxKey(chain string, id string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("ID", id).Msg("Deleting Tx Key") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -692,7 +688,7 @@ func (c *Chainlink) DeleteTxKey(chain string, id string) (*http.Response, error) // MustReadTransactionAttempts reads all transaction attempts on the Chainlink node // and returns error if the request is unsuccessful -func (c *Chainlink) MustReadTransactionAttempts() (*TransactionsData, error) { +func (c *ChainlinkClient) MustReadTransactionAttempts() (*TransactionsData, error) { txsData := &TransactionsData{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading Transaction Attempts") resp, err := c.APIClient.R(). @@ -706,7 +702,7 @@ func (c *Chainlink) MustReadTransactionAttempts() (*TransactionsData, error) { } // ReadTransactions reads all transactions made by the Chainlink node -func (c *Chainlink) ReadTransactions() (*TransactionsData, *http.Response, error) { +func (c *ChainlinkClient) ReadTransactions() (*TransactionsData, *http.Response, error) { txsData := &TransactionsData{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading Transactions") resp, err := c.APIClient.R(). @@ -721,7 +717,7 @@ func (c *Chainlink) ReadTransactions() (*TransactionsData, *http.Response, error // MustSendNativeToken sends native token (ETH usually) of a specified amount from one of its addresses to the target address // and returns error if the request is unsuccessful // WARNING: The txdata object that Chainlink sends back is almost always blank. -func (c *Chainlink) MustSendNativeToken(amount *big.Int, fromAddress, toAddress string) (TransactionData, error) { +func (c *ChainlinkClient) MustSendNativeToken(amount *big.Int, fromAddress, toAddress string) (TransactionData, error) { request := SendEtherRequest{ DestinationAddress: toAddress, FromAddress: fromAddress, @@ -748,7 +744,7 @@ func (c *Chainlink) MustSendNativeToken(amount *big.Int, fromAddress, toAddress } // ReadVRFKeys reads all VRF keys from the Chainlink node -func (c *Chainlink) ReadVRFKeys() (*VRFKeys, *http.Response, error) { +func (c *ChainlinkClient) ReadVRFKeys() (*VRFKeys, *http.Response, error) { vrfKeys := &VRFKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading VRF Keys") resp, err := c.APIClient.R(). @@ -765,7 +761,7 @@ func (c *Chainlink) ReadVRFKeys() (*VRFKeys, *http.Response, error) { // MustCreateVRFKey creates a VRF key on the Chainlink node // and returns error if the request is unsuccessful -func (c *Chainlink) MustCreateVRFKey() (*VRFKey, error) { +func (c *ChainlinkClient) MustCreateVRFKey() (*VRFKey, error) { vrfKey := &VRFKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating VRF Key") resp, err := c.APIClient.R(). @@ -778,7 +774,7 @@ func (c *Chainlink) MustCreateVRFKey() (*VRFKey, error) { } // ExportVRFKey exports a vrf key by key id -func (c *Chainlink) ExportVRFKey(keyId string) (*VRFExportKey, *http.Response, error) { +func (c *ChainlinkClient) ExportVRFKey(keyId string) (*VRFExportKey, *http.Response, error) { vrfExportKey := &VRFExportKey{} log.Info().Str(NodeURL, c.Config.URL).Str("ID", keyId).Msg("Exporting VRF Key") resp, err := c.APIClient.R(). @@ -794,7 +790,7 @@ func (c *Chainlink) ExportVRFKey(keyId string) (*VRFExportKey, *http.Response, e } // ImportVRFKey import vrf key -func (c *Chainlink) ImportVRFKey(vrfExportKey *VRFExportKey) (*VRFKey, *http.Response, error) { +func (c *ChainlinkClient) ImportVRFKey(vrfExportKey *VRFExportKey) (*VRFKey, *http.Response, error) { vrfKey := &VRFKey{} log.Info().Str(NodeURL, c.Config.URL).Str("ID", vrfExportKey.VrfKey.Address).Msg("Importing VRF Key") resp, err := c.APIClient.R(). @@ -809,7 +805,7 @@ func (c *Chainlink) ImportVRFKey(vrfExportKey *VRFExportKey) (*VRFKey, *http.Res // MustCreateDkgSignKey creates a DKG Sign key on the Chainlink node // and returns error if the request is unsuccessful -func (c *Chainlink) MustCreateDkgSignKey() (*DKGSignKey, error) { +func (c *ChainlinkClient) MustCreateDkgSignKey() (*DKGSignKey, error) { dkgSignKey := &DKGSignKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating DKG Sign Key") resp, err := c.APIClient.R(). @@ -823,7 +819,7 @@ func (c *Chainlink) MustCreateDkgSignKey() (*DKGSignKey, error) { // MustCreateDkgEncryptKey creates a DKG Encrypt key on the Chainlink node // and returns error if the request is unsuccessful -func (c *Chainlink) MustCreateDkgEncryptKey() (*DKGEncryptKey, error) { +func (c *ChainlinkClient) MustCreateDkgEncryptKey() (*DKGEncryptKey, error) { dkgEncryptKey := &DKGEncryptKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating DKG Encrypt Key") resp, err := c.APIClient.R(). @@ -836,7 +832,7 @@ func (c *Chainlink) MustCreateDkgEncryptKey() (*DKGEncryptKey, error) { } // MustReadDKGSignKeys reads all DKG Sign Keys from the Chainlink node returns err if response not 200 -func (c *Chainlink) MustReadDKGSignKeys() (*DKGSignKeys, error) { +func (c *ChainlinkClient) MustReadDKGSignKeys() (*DKGSignKeys, error) { dkgSignKeys := &DKGSignKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading DKG Sign Keys") resp, err := c.APIClient.R(). @@ -850,7 +846,7 @@ func (c *Chainlink) MustReadDKGSignKeys() (*DKGSignKeys, error) { } // MustReadDKGEncryptKeys reads all DKG Encrypt Keys from the Chainlink node returns err if response not 200 -func (c *Chainlink) MustReadDKGEncryptKeys() (*DKGEncryptKeys, error) { +func (c *ChainlinkClient) MustReadDKGEncryptKeys() (*DKGEncryptKeys, error) { dkgEncryptKeys := &DKGEncryptKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading DKG Encrypt Keys") resp, err := c.APIClient.R(). @@ -864,7 +860,7 @@ func (c *Chainlink) MustReadDKGEncryptKeys() (*DKGEncryptKeys, error) { } // CreateCSAKey creates a CSA key on the Chainlink node, only 1 CSA key per noe -func (c *Chainlink) CreateCSAKey() (*CSAKey, *http.Response, error) { +func (c *ChainlinkClient) CreateCSAKey() (*CSAKey, *http.Response, error) { csaKey := &CSAKey{} log.Info().Str(NodeURL, c.Config.URL).Msg("Creating CSA Key") resp, err := c.APIClient.R(). @@ -877,7 +873,7 @@ func (c *Chainlink) CreateCSAKey() (*CSAKey, *http.Response, error) { } // ReadCSAKeys reads CSA keys from the Chainlink node -func (c *Chainlink) ReadCSAKeys() (*CSAKeys, *http.Response, error) { +func (c *ChainlinkClient) ReadCSAKeys() (*CSAKeys, *http.Response, error) { csaKeys := &CSAKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading CSA Keys") resp, err := c.APIClient.R(). @@ -893,7 +889,7 @@ func (c *Chainlink) ReadCSAKeys() (*CSAKeys, *http.Response, error) { } // CreateEI creates an EI on the Chainlink node based on the provided attributes and returns the respective secrets -func (c *Chainlink) CreateEI(eia *EIAttributes) (*EIKeyCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateEI(eia *EIAttributes) (*EIKeyCreate, *http.Response, error) { ei := EIKeyCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Name", eia.Name).Msg("Creating External Initiator") resp, err := c.APIClient.R(). @@ -907,7 +903,7 @@ func (c *Chainlink) CreateEI(eia *EIAttributes) (*EIKeyCreate, *http.Response, e } // ReadEIs reads all of the configured EIs from the Chainlink node -func (c *Chainlink) ReadEIs() (*EIKeys, *http.Response, error) { +func (c *ChainlinkClient) ReadEIs() (*EIKeys, *http.Response, error) { ei := EIKeys{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading EI Keys") resp, err := c.APIClient.R(). @@ -920,7 +916,7 @@ func (c *Chainlink) ReadEIs() (*EIKeys, *http.Response, error) { } // DeleteEI deletes an external initiator in the Chainlink node based on the provided name -func (c *Chainlink) DeleteEI(name string) (*http.Response, error) { +func (c *ChainlinkClient) DeleteEI(name string) (*http.Response, error) { log.Info().Str(NodeURL, c.Config.URL).Str("Name", name).Msg("Deleting EI") resp, err := c.APIClient.R(). SetPathParams(map[string]string{ @@ -934,7 +930,7 @@ func (c *Chainlink) DeleteEI(name string) (*http.Response, error) { } // CreateCosmosChain creates a cosmos chain -func (c *Chainlink) CreateCosmosChain(chain *CosmosChainAttributes) (*CosmosChainCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateCosmosChain(chain *CosmosChainAttributes) (*CosmosChainCreate, *http.Response, error) { response := CosmosChainCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Chain ID", chain.ChainID).Msg("Creating Cosmos Chain") resp, err := c.APIClient.R(). @@ -948,7 +944,7 @@ func (c *Chainlink) CreateCosmosChain(chain *CosmosChainAttributes) (*CosmosChai } // CreateCosmosNode creates a cosmos node -func (c *Chainlink) CreateCosmosNode(node *CosmosNodeAttributes) (*CosmosNodeCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateCosmosNode(node *CosmosNodeAttributes) (*CosmosNodeCreate, *http.Response, error) { response := CosmosNodeCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Name", node.Name).Msg("Creating Cosmos Node") resp, err := c.APIClient.R(). @@ -962,7 +958,7 @@ func (c *Chainlink) CreateCosmosNode(node *CosmosNodeAttributes) (*CosmosNodeCre } // CreateSolanaChain creates a solana chain -func (c *Chainlink) CreateSolanaChain(chain *SolanaChainAttributes) (*SolanaChainCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateSolanaChain(chain *SolanaChainAttributes) (*SolanaChainCreate, *http.Response, error) { response := SolanaChainCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Chain ID", chain.ChainID).Msg("Creating Solana Chain") resp, err := c.APIClient.R(). @@ -976,7 +972,7 @@ func (c *Chainlink) CreateSolanaChain(chain *SolanaChainAttributes) (*SolanaChai } // CreateSolanaNode creates a solana node -func (c *Chainlink) CreateSolanaNode(node *SolanaNodeAttributes) (*SolanaNodeCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateSolanaNode(node *SolanaNodeAttributes) (*SolanaNodeCreate, *http.Response, error) { response := SolanaNodeCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Name", node.Name).Msg("Creating Solana Node") resp, err := c.APIClient.R(). @@ -990,7 +986,7 @@ func (c *Chainlink) CreateSolanaNode(node *SolanaNodeAttributes) (*SolanaNodeCre } // CreateStarkNetChain creates a starknet chain -func (c *Chainlink) CreateStarkNetChain(chain *StarkNetChainAttributes) (*StarkNetChainCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateStarkNetChain(chain *StarkNetChainAttributes) (*StarkNetChainCreate, *http.Response, error) { response := StarkNetChainCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Chain ID", chain.ChainID).Msg("Creating StarkNet Chain") resp, err := c.APIClient.R(). @@ -1004,7 +1000,7 @@ func (c *Chainlink) CreateStarkNetChain(chain *StarkNetChainAttributes) (*StarkN } // CreateStarkNetNode creates a starknet node -func (c *Chainlink) CreateStarkNetNode(node *StarkNetNodeAttributes) (*StarkNetNodeCreate, *http.Response, error) { +func (c *ChainlinkClient) CreateStarkNetNode(node *StarkNetNodeAttributes) (*StarkNetNodeCreate, *http.Response, error) { response := StarkNetNodeCreate{} log.Info().Str(NodeURL, c.Config.URL).Str("Name", node.Name).Msg("Creating StarkNet Node") resp, err := c.APIClient.R(). @@ -1018,13 +1014,13 @@ func (c *Chainlink) CreateStarkNetNode(node *StarkNetNodeAttributes) (*StarkNetN } // InternalIP retrieves the inter-cluster IP of the Chainlink node, for use with inter-node communications -func (c *Chainlink) InternalIP() string { +func (c *ChainlinkClient) InternalIP() string { return c.Config.InternalIP } // Profile starts a profile session on the Chainlink node for a pre-determined length, then runs the provided function // to profile it. -func (c *Chainlink) Profile(profileTime time.Duration, profileFunction func(*Chainlink)) (*ChainlinkProfileResults, error) { +func (c *ChainlinkClient) Profile(profileTime time.Duration, profileFunction func(*ChainlinkClient)) (*ChainlinkProfileResults, error) { profileSeconds := int(profileTime.Seconds()) profileResults := NewBlankChainlinkProfileResults() profileErrorGroup := new(errgroup.Group) @@ -1085,70 +1081,10 @@ func (c *Chainlink) Profile(profileTime time.Duration, profileFunction func(*Cha } // SetPageSize globally sets the page -func (c *Chainlink) SetPageSize(size int) { +func (c *ChainlinkClient) SetPageSize(size int) { c.pageSize = size } -// ConnectChainlinkNodes creates new Chainlink clients -func ConnectChainlinkNodes(e *environment.Environment) ([]*Chainlink, error) { - var clients []*Chainlink - for _, nodeDetails := range e.ChainlinkNodeDetails { - c, err := NewChainlink(&ChainlinkConfig{ - URL: nodeDetails.LocalIP, - Email: "notreal@fakeemail.ch", - Password: "fj293fbBnlQ!f9vNs", - InternalIP: parseHostname(nodeDetails.InternalIP), - ChartName: nodeDetails.ChartName, - PodName: nodeDetails.PodName, - }) - if err != nil { - return nil, err - } - log.Debug(). - Str("URL", c.Config.URL). - Str("Internal IP", c.Config.InternalIP). - Str("Chart Name", c.Config.ChartName). - Str("Pod Name", c.Config.PodName). - Msg("Connected to Chainlink node") - clients = append(clients, c) - } - return clients, nil -} - -// ReconnectChainlinkNodes reconnects to Chainlink nodes after they have been modified, say through a Helm upgrade -// Note: Experimental as of now, will likely not work predictably. -func ReconnectChainlinkNodes(testEnvironment *environment.Environment, nodes []*Chainlink) (err error) { - for _, node := range nodes { - for _, details := range testEnvironment.ChainlinkNodeDetails { - if details.ChartName == node.Config.ChartName { // Make the link from client to pod consistent - node, err = NewChainlink(&ChainlinkConfig{ - URL: details.LocalIP, - Email: "notreal@fakeemail.ch", - Password: "fj293fbBnlQ!f9vNs", - InternalIP: parseHostname(details.InternalIP), - ChartName: details.ChartName, - PodName: details.PodName, - }) - if err != nil { - return err - } - log.Debug(). - Str("URL", node.Config.URL). - Str("Internal IP", node.Config.InternalIP). - Str("Chart Name", node.Config.ChartName). - Str("Pod Name", node.Config.PodName). - Msg("Reconnected to Chainlink node") - } - } - } - return nil -} - -func parseHostname(s string) string { - r := regexp.MustCompile(`://(?P.*):`) - return r.FindStringSubmatch(s)[1] -} - func VerifyStatusCode(actStatusCd, expStatusCd int) error { if actStatusCd != expStatusCd { return fmt.Errorf( @@ -1160,7 +1096,7 @@ func VerifyStatusCode(actStatusCd, expStatusCd int) error { return nil } -func CreateNodeKeysBundle(nodes []*Chainlink, chainName string, chainId string) ([]NodeKeysBundle, []*CLNodesWithKeys, error) { +func CreateNodeKeysBundle(nodes []*ChainlinkClient, chainName string, chainId string) ([]NodeKeysBundle, []*CLNodesWithKeys, error) { nkb := make([]NodeKeysBundle, 0) var clNodes []*CLNodesWithKeys for _, n := range nodes { @@ -1227,7 +1163,7 @@ func CreateNodeKeysBundle(nodes []*Chainlink, chainName string, chainId string) } // TrackForwarder track forwarder address in db. -func (c *Chainlink) TrackForwarder(chainID *big.Int, address common.Address) (*Forwarder, *http.Response, error) { +func (c *ChainlinkClient) TrackForwarder(chainID *big.Int, address common.Address) (*Forwarder, *http.Response, error) { response := &Forwarder{} request := ForwarderAttributes{ ChainID: chainID.String(), @@ -1253,7 +1189,7 @@ func (c *Chainlink) TrackForwarder(chainID *big.Int, address common.Address) (*F } // GetForwarders get list of tracked forwarders -func (c *Chainlink) GetForwarders() (*Forwarders, *http.Response, error) { +func (c *ChainlinkClient) GetForwarders() (*Forwarders, *http.Response, error) { response := &Forwarders{} log.Info().Str(NodeURL, c.Config.URL).Msg("Reading Tracked Forwarders") resp, err := c.APIClient.R(). @@ -1268,32 +1204,3 @@ func (c *Chainlink) GetForwarders() (*Forwarders, *http.Response, error) { } return response, resp.RawResponse, err } - -// UpgradeVersion upgrades the chainlink node to the new version -// Note: You need to call Run() on the test environment for changes to take effect -// Note: This function is not thread safe, call from a single thread -func (c *Chainlink) UpgradeVersion(testEnvironment *environment.Environment, newImage, newVersion string) error { - if newVersion == "" { - return fmt.Errorf("new version is empty") - } - if newImage == "" { - newImage = os.Getenv("CHAINLINK_IMAGE") - } - log.Info(). - Str("Chart Name", c.Config.ChartName). - Str("Old Image", os.Getenv("CHAINLINK_IMAGE")). - Str("Old Version", os.Getenv("CHAINLINK_VERSION")). - Str("New Image", newImage). - Str("New Version", newVersion). - Msg("Upgrading Chainlink Node") - upgradeVals := map[string]any{ - "chainlink": map[string]any{ - "image": map[string]any{ - "image": newImage, - "version": newVersion, - }, - }, - } - testEnvironment, err := testEnvironment.UpdateHelm(c.Config.ChartName, upgradeVals) - return err -} diff --git a/integration-tests/client/chainlink_k8s.go b/integration-tests/client/chainlink_k8s.go new file mode 100644 index 00000000000..08364041a8b --- /dev/null +++ b/integration-tests/client/chainlink_k8s.go @@ -0,0 +1,125 @@ +// Package client enables interaction with APIs of test components like the mockserver and Chainlink nodes +package client + +import ( + "fmt" + "os" + "regexp" + + "github.com/rs/zerolog/log" + + "github.com/smartcontractkit/chainlink-env/environment" +) + +type ChainlinkK8sClient struct { + ChartName string + PodName string + *ChainlinkClient +} + +// NewChainlink creates a new Chainlink model using a provided config +func NewChainlinkK8sClient(c *ChainlinkConfig, podName, chartName string) (*ChainlinkK8sClient, error) { + rc, err := initRestyClient(c.URL, c.Email, c.Password, c.HTTPTimeout) + if err != nil { + return nil, err + } + return &ChainlinkK8sClient{ + ChainlinkClient: &ChainlinkClient{ + APIClient: rc, + pageSize: 25, + Config: c, + }, + ChartName: chartName, + PodName: podName, + }, nil +} + +// UpgradeVersion upgrades the chainlink node to the new version +// Note: You need to call Run() on the test environment for changes to take effect +// Note: This function is not thread safe, call from a single thread +func (c *ChainlinkK8sClient) UpgradeVersion(testEnvironment *environment.Environment, newImage, newVersion string) error { + if newVersion == "" { + return fmt.Errorf("new version is empty") + } + if newImage == "" { + newImage = os.Getenv("CHAINLINK_IMAGE") + } + log.Info(). + Str("Chart Name", c.ChartName). + Str("Old Image", os.Getenv("CHAINLINK_IMAGE")). + Str("Old Version", os.Getenv("CHAINLINK_VERSION")). + Str("New Image", newImage). + Str("New Version", newVersion). + Msg("Upgrading Chainlink Node") + upgradeVals := map[string]any{ + "chainlink": map[string]any{ + "image": map[string]any{ + "image": newImage, + "version": newVersion, + }, + }, + } + testEnvironment, err := testEnvironment.UpdateHelm(c.ChartName, upgradeVals) + return err +} + +// Name Chainlink instance chart/service name +func (c *ChainlinkK8sClient) Name() string { + return c.ChartName +} + +func parseHostname(s string) string { + r := regexp.MustCompile(`://(?P.*):`) + return r.FindStringSubmatch(s)[1] +} + +// ConnectChainlinkNodes creates new Chainlink clients +func ConnectChainlinkNodes(e *environment.Environment) ([]*ChainlinkK8sClient, error) { + var clients []*ChainlinkK8sClient + for _, nodeDetails := range e.ChainlinkNodeDetails { + c, err := NewChainlinkK8sClient(&ChainlinkConfig{ + URL: nodeDetails.LocalIP, + Email: "notreal@fakeemail.ch", + Password: "fj293fbBnlQ!f9vNs", + InternalIP: parseHostname(nodeDetails.InternalIP), + }, nodeDetails.PodName, nodeDetails.ChartName) + if err != nil { + return nil, err + } + log.Debug(). + Str("URL", c.Config.URL). + Str("Internal IP", c.Config.InternalIP). + Str("Chart Name", nodeDetails.ChartName). + Str("Pod Name", nodeDetails.PodName). + Msg("Connected to Chainlink node") + clients = append(clients, c) + } + return clients, nil +} + +// ReconnectChainlinkNodes reconnects to Chainlink nodes after they have been modified, say through a Helm upgrade +// Note: Experimental as of now, will likely not work predictably. +func ReconnectChainlinkNodes(testEnvironment *environment.Environment, nodes []*ChainlinkK8sClient) (err error) { + for _, node := range nodes { + for _, details := range testEnvironment.ChainlinkNodeDetails { + if details.ChartName == node.ChartName { // Make the link from client to pod consistent + node, err = NewChainlinkK8sClient(&ChainlinkConfig{ + URL: details.LocalIP, + Email: "notreal@fakeemail.ch", + Password: "fj293fbBnlQ!f9vNs", + InternalIP: parseHostname(details.InternalIP), + }, details.PodName, details.ChartName) + if err != nil { + return err + } + log.Debug(). + Str("URL", node.Config.URL). + Str("Internal IP", node.Config.InternalIP). + Str("Chart Name", node.ChartName). + Str("Pod Name", node.PodName). + Msg("Reconnected to Chainlink node") + } + } + } + return nil +} diff --git a/integration-tests/client/chainlink_models.go b/integration-tests/client/chainlink_models.go index 2a3d2a42a53..bb6698ba95c 100644 --- a/integration-tests/client/chainlink_models.go +++ b/integration-tests/client/chainlink_models.go @@ -21,9 +21,7 @@ type ChainlinkConfig struct { URL string Email string Password string - InternalIP string // Can change if the node is restarted. Prefer RemoteURL if possible - ChartName string - PodName string + InternalIP string HTTPTimeout *time.Duration } @@ -851,20 +849,20 @@ p2pPeerID = "{{.P2PPeerID}}"` // OCRTaskJobSpec represents an OCR job that is given to other nodes, meant to communicate with the bootstrap node, // and provide their answers type OCRTaskJobSpec struct { - Name string `toml:"name"` - BlockChainTimeout time.Duration `toml:"blockchainTimeout"` // Optional - ContractConfirmations int `toml:"contractConfigConfirmations"` // Optional - TrackerPollInterval time.Duration `toml:"contractConfigTrackerPollInterval"` // Optional - TrackerSubscribeInterval time.Duration `toml:"contractConfigTrackerSubscribeInterval"` // Optional - ForwardingAllowed bool `toml:"forwardingAllowed"` // Optional, by default false - ContractAddress string `toml:"contractAddress"` // Address of the OCR contract - P2PBootstrapPeers []*Chainlink `toml:"p2pBootstrapPeers"` // P2P ID of the bootstrap node - IsBootstrapPeer bool `toml:"isBootstrapPeer"` // Typically false - P2PPeerID string `toml:"p2pPeerID"` // This node's P2P ID - KeyBundleID string `toml:"keyBundleID"` // ID of this node's OCR key bundle - MonitoringEndpoint string `toml:"monitoringEndpoint"` // Typically "chain.link:4321" - TransmitterAddress string `toml:"transmitterAddress"` // ETH address this node will use to transmit its answer - ObservationSource string `toml:"observationSource"` // List of commands for the Chainlink node + Name string `toml:"name"` + BlockChainTimeout time.Duration `toml:"blockchainTimeout"` // Optional + ContractConfirmations int `toml:"contractConfigConfirmations"` // Optional + TrackerPollInterval time.Duration `toml:"contractConfigTrackerPollInterval"` // Optional + TrackerSubscribeInterval time.Duration `toml:"contractConfigTrackerSubscribeInterval"` // Optional + ForwardingAllowed bool `toml:"forwardingAllowed"` // Optional, by default false + ContractAddress string `toml:"contractAddress"` // Address of the OCR contract + P2PBootstrapPeers []*ChainlinkClient `toml:"p2pBootstrapPeers"` // P2P ID of the bootstrap node + IsBootstrapPeer bool `toml:"isBootstrapPeer"` // Typically false + P2PPeerID string `toml:"p2pPeerID"` // This node's P2P ID + KeyBundleID string `toml:"keyBundleID"` // ID of this node's OCR key bundle + MonitoringEndpoint string `toml:"monitoringEndpoint"` // Typically "chain.link:4321" + TransmitterAddress string `toml:"transmitterAddress"` // ETH address this node will use to transmit its answer + ObservationSource string `toml:"observationSource"` // List of commands for the Chainlink node } // P2PData holds the remote ip and the peer id and port @@ -1291,7 +1289,7 @@ func NewBlankChainlinkProfileResults() *ChainlinkProfileResults { } type CLNodesWithKeys struct { - Node *Chainlink + Node *ChainlinkClient KeysBundle NodeKeysBundle } diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index cdae8ec3cc2..8e54a5b15bb 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -139,7 +139,7 @@ type OffchainAggregator interface { Address() string Fund(nativeAmount *big.Float) error GetContractData(ctx context.Context) (*OffchainAggregatorData, error) - SetConfig(chainlinkNodes []*client.Chainlink, ocrConfig OffChainAggregatorConfig, transmitters []common.Address) error + SetConfig(chainlinkNodes []*client.ChainlinkK8sClient, ocrConfig OffChainAggregatorConfig, transmitters []common.Address) error SetPayees([]string, []string) error RequestNewRound() error GetLatestAnswer(ctx context.Context) (*big.Int, error) diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index 198d747f296..2f64122b299 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -779,7 +779,7 @@ func (o *EthereumOffchainAggregator) SetPayees( // SetConfig sets the payees and the offchain reporting protocol configuration func (o *EthereumOffchainAggregator) SetConfig( - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, ocrConfig OffChainAggregatorConfig, transmitters []common.Address, ) error { @@ -791,7 +791,7 @@ func (o *EthereumOffchainAggregator) SetConfig( return err } if len(ocrKeys.Data) == 0 { - return fmt.Errorf("no OCR keys found for node %s", node.Config.ChartName) + return fmt.Errorf("no OCR keys found for node %s", node.ChartName) } primaryOCRKey := ocrKeys.Data[0] if err != nil { diff --git a/integration-tests/performance/cron_test.go b/integration-tests/performance/cron_test.go index 0833b270ad4..933014a1698 100644 --- a/integration-tests/performance/cron_test.go +++ b/integration-tests/performance/cron_test.go @@ -36,7 +36,7 @@ func TestMain(m *testing.M) { func CleanupPerformanceTest( t *testing.T, testEnvironment *environment.Environment, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, testReporter testreporters.ChainlinkProfileTestReporter, chainClient blockchain.EVMClient, ) { @@ -61,8 +61,8 @@ func TestCronPerformance(t *testing.T) { err = mockServer.SetValuePath("/variable", 5) require.NoError(t, err, "Setting value path in mockserver shouldn't fail") - profileFunction := func(chainlinkNode *client.Chainlink) { - if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1] { + profileFunction := func(chainlinkNode *client.ChainlinkClient) { + if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1].ChainlinkClient { // Not the last node, hence not all nodes started profiling yet. return } @@ -96,7 +96,7 @@ func TestCronPerformance(t *testing.T) { profileTest := testsetups.NewChainlinkProfileTest(testsetups.ChainlinkProfileTestInputs{ ProfileFunction: profileFunction, ProfileDuration: 30 * time.Second, - ChainlinkNodes: []*client.Chainlink{chainlinkNode}, + ChainlinkNodes: []*client.ChainlinkK8sClient{chainlinkNode}, }) // Register cleanup for any test t.Cleanup(func() { diff --git a/integration-tests/performance/directrequest_test.go b/integration-tests/performance/directrequest_test.go index f5fe04576a7..47a16de1091 100644 --- a/integration-tests/performance/directrequest_test.go +++ b/integration-tests/performance/directrequest_test.go @@ -87,8 +87,8 @@ func TestDirectRequestPerformance(t *testing.T) { }) require.NoError(t, err, "Creating direct_request job shouldn't fail") - profileFunction := func(chainlinkNode *client.Chainlink) { - if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1] { + profileFunction := func(chainlinkNode *client.ChainlinkClient) { + if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1].ChainlinkClient { // Not the last node, hence not all nodes started profiling yet. return } diff --git a/integration-tests/performance/flux_test.go b/integration-tests/performance/flux_test.go index 0838ccae3bb..ecacce90ca7 100644 --- a/integration-tests/performance/flux_test.go +++ b/integration-tests/performance/flux_test.go @@ -109,8 +109,8 @@ func TestFluxPerformance(t *testing.T) { require.NoError(t, err, "Creating flux job shouldn't fail for node %d", i+1) } - profileFunction := func(chainlinkNode *client.Chainlink) { - if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1] { + profileFunction := func(chainlinkNode *client.ChainlinkClient) { + if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1].ChainlinkClient { // Not the last node, hence not all nodes started profiling yet. return } diff --git a/integration-tests/performance/keeper_test.go b/integration-tests/performance/keeper_test.go index 0f900c63dd6..346f0897d47 100644 --- a/integration-tests/performance/keeper_test.go +++ b/integration-tests/performance/keeper_test.go @@ -62,8 +62,8 @@ func TestKeeperPerformance(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - profileFunction := func(chainlinkNode *client.Chainlink) { - if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1] { + profileFunction := func(chainlinkNode *client.ChainlinkClient) { + if chainlinkNode != chainlinkNodes[len(chainlinkNodes)-1].ChainlinkClient { // Not the last node, hence not all nodes started profiling yet. return } @@ -130,7 +130,7 @@ func setupKeeperTest( ) ( *environment.Environment, blockchain.EVMClient, - []*client.Chainlink, + []*client.ChainlinkK8sClient, contracts.ContractDeployer, contracts.LinkToken, ) { diff --git a/integration-tests/performance/ocr_test.go b/integration-tests/performance/ocr_test.go index 713767fe7a8..25791161bc2 100644 --- a/integration-tests/performance/ocr_test.go +++ b/integration-tests/performance/ocr_test.go @@ -56,7 +56,7 @@ func TestOCRBasic(t *testing.T) { err = chainClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") - profileFunction := func(chainlinkNode *client.Chainlink) { + profileFunction := func(chainlinkNode *client.ChainlinkClient) { err = actions.CreateOCRJobs(ocrInstances, bootstrapNode, workerNodes, 5, mockServer) require.NoError(t, err) err = actions.StartNewRound(1, ocrInstances, chainClient) diff --git a/integration-tests/performance/vrf_test.go b/integration-tests/performance/vrf_test.go index c14df261d14..2074eecaf78 100644 --- a/integration-tests/performance/vrf_test.go +++ b/integration-tests/performance/vrf_test.go @@ -62,7 +62,7 @@ func TestVRFBasic(t *testing.T) { err = chainClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") - profileFunction := func(chainlinkNode *client.Chainlink) { + profileFunction := func(chainlinkNode *client.ChainlinkClient) { nodeKey, err := chainlinkNode.MustCreateVRFKey() require.NoError(t, err, "Creating VRF key shouldn't fail") l.Debug().Interface("Key JSON", nodeKey).Msg("Created proving key") diff --git a/integration-tests/reorg/reorg_test.go b/integration-tests/reorg/reorg_test.go index cf124c36887..1a1deed2734 100644 --- a/integration-tests/reorg/reorg_test.go +++ b/integration-tests/reorg/reorg_test.go @@ -59,7 +59,7 @@ func TestMain(m *testing.M) { func CleanupReorgTest( t *testing.T, testEnvironment *environment.Environment, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, chainClient blockchain.EVMClient, ) { if chainClient != nil { diff --git a/integration-tests/smoke/automation_test.go b/integration-tests/smoke/automation_test.go index fa8a18d1d8b..8b1f4b50580 100644 --- a/integration-tests/smoke/automation_test.go +++ b/integration-tests/smoke/automation_test.go @@ -785,7 +785,7 @@ func setupAutomationTest( statefulDb bool, ) ( chainClient blockchain.EVMClient, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, contractDeployer contracts.ContractDeployer, linkToken contracts.LinkToken, registry contracts.KeeperRegistry, diff --git a/integration-tests/smoke/keeper_test.go b/integration-tests/smoke/keeper_test.go index e328bf8481d..e38124f6dd6 100644 --- a/integration-tests/smoke/keeper_test.go +++ b/integration-tests/smoke/keeper_test.go @@ -1111,7 +1111,7 @@ func setupKeeperTest( testName string, ) ( chainClient blockchain.EVMClient, - chainlinkNodes []*client.Chainlink, + chainlinkNodes []*client.ChainlinkK8sClient, contractDeployer contracts.ContractDeployer, linkToken contracts.LinkToken, onlyStartRunner bool, diff --git a/integration-tests/soak/vrfv2_test.go b/integration-tests/soak/vrfv2_test.go index cc64474de90..f6e9ba99b25 100644 --- a/integration-tests/soak/vrfv2_test.go +++ b/integration-tests/soak/vrfv2_test.go @@ -124,7 +124,7 @@ func TestVRFV2Soak(t *testing.T) { vrfV2SoakTest.Run(t) } -func printDebugData(l zerolog.Logger, vrfV2Contracts vrfv2_actions.VRFV2Contracts, chainlinkNodesAfterRedeployment []*client.Chainlink) { +func printDebugData(l zerolog.Logger, vrfV2Contracts vrfv2_actions.VRFV2Contracts, chainlinkNodesAfterRedeployment []*client.ChainlinkK8sClient) { subscription, err := vrfV2Contracts.Coordinator.GetSubscription(nil, vrfv2_constants.SubID) if err != nil { l.Error().Err(err). diff --git a/integration-tests/testsetups/don_evm_chain.go b/integration-tests/testsetups/don_evm_chain.go index ec01d8e9784..a9e69b32f49 100644 --- a/integration-tests/testsetups/don_evm_chain.go +++ b/integration-tests/testsetups/don_evm_chain.go @@ -23,7 +23,7 @@ type DonChain struct { EVMNetwork *blockchain.EVMNetwork ContractDeployer contracts.ContractDeployer LinkTokenContract contracts.LinkToken - ChainlinkNodes []*client.Chainlink + ChainlinkNodes []*client.ChainlinkK8sClient Mockserver *ctfClient.MockserverClient } diff --git a/integration-tests/testsetups/keeper_benchmark.go b/integration-tests/testsetups/keeper_benchmark.go index 358a266c605..9ef0cd82ea1 100644 --- a/integration-tests/testsetups/keeper_benchmark.go +++ b/integration-tests/testsetups/keeper_benchmark.go @@ -45,7 +45,7 @@ type KeeperBenchmarkTest struct { upkeepIDs [][]*big.Int env *environment.Environment - chainlinkNodes []*client.Chainlink + chainlinkNodes []*client.ChainlinkK8sClient chainClient blockchain.EVMClient contractDeployer contracts.ContractDeployer @@ -393,7 +393,7 @@ func (k *KeeperBenchmarkTest) subscribeToUpkeepPerformedEvent( func (k *KeeperBenchmarkTest) TearDownVals(t *testing.T) ( *testing.T, *environment.Environment, - []*client.Chainlink, + []*client.ChainlinkK8sClient, reportModel.TestReporter, blockchain.EVMClient, ) { diff --git a/integration-tests/testsetups/ocr.go b/integration-tests/testsetups/ocr.go index e4cf46fa02a..4b8016464fa 100644 --- a/integration-tests/testsetups/ocr.go +++ b/integration-tests/testsetups/ocr.go @@ -35,8 +35,8 @@ type OCRSoakTest struct { OperatorForwarderFlow bool testEnvironment *environment.Environment - bootstrapNode *client.Chainlink - workerNodes []*client.Chainlink + bootstrapNode *client.ChainlinkK8sClient + workerNodes []*client.ChainlinkK8sClient chainClient blockchain.EVMClient mockServer *ctfClient.MockserverClient mockPath string @@ -235,7 +235,7 @@ testLoop: func (o *OCRSoakTest) TearDownVals(t *testing.T) ( *testing.T, *environment.Environment, - []*client.Chainlink, + []*client.ChainlinkK8sClient, reportModel.TestReporter, blockchain.EVMClient, ) { diff --git a/integration-tests/testsetups/profile.go b/integration-tests/testsetups/profile.go index 81acd2edaaa..6f978cdebee 100644 --- a/integration-tests/testsetups/profile.go +++ b/integration-tests/testsetups/profile.go @@ -25,9 +25,9 @@ type ChainlinkProfileTest struct { // ChainlinkProfileTestInputs are the inputs necessary to run a profiling tests type ChainlinkProfileTestInputs struct { - ProfileFunction func(*client.Chainlink) + ProfileFunction func(*client.ChainlinkClient) ProfileDuration time.Duration - ChainlinkNodes []*client.Chainlink + ChainlinkNodes []*client.ChainlinkK8sClient } // NewChainlinkProfileTest prepares a new keeper Chainlink profiling test to be run @@ -63,7 +63,7 @@ func (c *ChainlinkProfileTest) Run() { } // Networks returns the networks that the test is running on -func (c *ChainlinkProfileTest) TearDownVals() (*environment.Environment, []*client.Chainlink, reportModel.TestReporter, blockchain.EVMClient) { +func (c *ChainlinkProfileTest) TearDownVals() (*environment.Environment, []*client.ChainlinkK8sClient, reportModel.TestReporter, blockchain.EVMClient) { return c.env, c.Inputs.ChainlinkNodes, &c.TestReporter, c.c } diff --git a/integration-tests/testsetups/vrfv2.go b/integration-tests/testsetups/vrfv2.go index f50d1c5a43e..55d33fb958c 100644 --- a/integration-tests/testsetups/vrfv2.go +++ b/integration-tests/testsetups/vrfv2.go @@ -31,7 +31,7 @@ type VRFV2SoakTest struct { TestReporter testreporters.VRFV2SoakTestReporter testEnvironment *environment.Environment - ChainlinkNodes []*client.Chainlink + ChainlinkNodes []*client.ChainlinkK8sClient chainClient blockchain.EVMClient DefaultNetwork blockchain.EVMClient @@ -59,7 +59,7 @@ type VRFV2SoakTestInputs struct { } // NewVRFV2SoakTest creates a new vrfv2 soak test to setup and run -func NewVRFV2SoakTest(inputs *VRFV2SoakTestInputs, chainlinkNodes []*client.Chainlink) *VRFV2SoakTest { +func NewVRFV2SoakTest(inputs *VRFV2SoakTestInputs, chainlinkNodes []*client.ChainlinkK8sClient) *VRFV2SoakTest { return &VRFV2SoakTest{ Inputs: inputs, TestReporter: testreporters.VRFV2SoakTestReporter{ @@ -162,7 +162,7 @@ func requestAndValidate(t *VRFV2SoakTest, requestNumber int) { func (v *VRFV2SoakTest) TearDownVals(t *testing.T) ( *testing.T, *environment.Environment, - []*client.Chainlink, + []*client.ChainlinkK8sClient, reportModel.TestReporter, blockchain.EVMClient, ) { From fb4d5017f299bdb33627a0ee3392d0a30b768a8c Mon Sep 17 00:00:00 2001 From: Tate Date: Mon, 31 Jul 2023 15:27:56 -0600 Subject: [PATCH 045/270] Update splits to only run unit tests for packages that have tests (#10009) --- .../split-tests/src/handlers/golang.mts | 51 +++++++++++++++++++ .github/actions/split-tests/src/index.mts | 17 ++----- .github/actions/split-tests/src/types.mts | 12 +++++ 3 files changed, 67 insertions(+), 13 deletions(-) create mode 100644 .github/actions/split-tests/src/handlers/golang.mts diff --git a/.github/actions/split-tests/src/handlers/golang.mts b/.github/actions/split-tests/src/handlers/golang.mts new file mode 100644 index 00000000000..e08d55303f5 --- /dev/null +++ b/.github/actions/split-tests/src/handlers/golang.mts @@ -0,0 +1,51 @@ +import { execSync } from "child_process"; +import { + GolangConfig, + GoSplits, + GoPackageData, + TestsBySplit, +} from "../types.mjs"; +import { simpleSplit } from "../splitter.mjs"; + +export interface GetGoPackagesReturn { + packages: string[]; + testsBySplit: TestsBySplit; + splits: GoSplits; + serializedSplits: string +} + +export function getPackageList( + config: GolangConfig, +): GetGoPackagesReturn { + const { numOfSplits } = config; + const rawPackages = execSync( + "go list -json ./... | jq -s '[.[] | {ImportPath, TestGoFiles}]'", + { encoding: "utf8" } + ); + const packages: GoPackageData[] = JSON.parse(rawPackages.trimEnd()); + const filteredData = packages.filter( + (item) => item.TestGoFiles && item.TestGoFiles.length > 0 + ); + const packagePaths = filteredData.map((item) => item.ImportPath); + return handleSplit(packagePaths, numOfSplits); +} + +function handleSplit( + packages: string[], + numOfSplits: number +): GetGoPackagesReturn { + console.log(`${packages.length} packages to split...`); + const packagesBySplit = simpleSplit(packages, [], numOfSplits); + const splits: GoSplits = packagesBySplit.map((pkgs, i) => ({ + idx: `${i + 1}`, + id: `${i + 1}/${numOfSplits}`, + pkgs: pkgs.join(" "), + })); + const o: GetGoPackagesReturn = { + packages, + testsBySplit: packagesBySplit, + splits, + serializedSplits: JSON.stringify(splits), + }; + return o; +} diff --git a/.github/actions/split-tests/src/index.mts b/.github/actions/split-tests/src/index.mts index d67354942e5..5befde03dc6 100644 --- a/.github/actions/split-tests/src/index.mts +++ b/.github/actions/split-tests/src/index.mts @@ -11,6 +11,7 @@ import { } from "./types.mjs"; import {sieveSlowTests} from "./sieve.mjs"; import {simpleSplit} from "./splitter.mjs"; +import { getPackageList, GetGoPackagesReturn } from "../src/handlers/golang.mjs"; /** * Get a JSON formatted config file @@ -47,19 +48,9 @@ async function main() { main(); async function handleGolang(config: GolangConfig) { - const {numOfSplits} = config; - const rawPackages = await $`go list ./...`; - const packages = rawPackages.stdout.trimEnd().split("\n"); - console.log(`${packages.length} packages to split...`); - const packagesBySplit = simpleSplit(packages, [], numOfSplits); - const splits: GoSplits = packagesBySplit.map((pkgs, i) => ({ - idx: `${i + 1}`, - id: `${i + 1}/${numOfSplits}`, - pkgs: pkgs.join(" "), - })); - const serializedSplits = JSON.stringify(splits); - setOutput("splits", serializedSplits); - createSummary(packages, packagesBySplit, splits); + const p: GetGoPackagesReturn = getPackageList(config) + setOutput("splits", p.serializedSplits); + createSummary(p.packages, p.testsBySplit, p.splits); } async function handleSolidity(config: SolidityConfig) { diff --git a/.github/actions/split-tests/src/types.mts b/.github/actions/split-tests/src/types.mts index cbc550a63a5..157680cafb2 100644 --- a/.github/actions/split-tests/src/types.mts +++ b/.github/actions/split-tests/src/types.mts @@ -93,3 +93,15 @@ export interface SolidityConfig { slowTests?: string[]; }[]; } + +export interface GoPackageData { + /** + * The package path + */ + ImportPath: string; + /** + * The list of go files asociated with the package + */ + TestGoFiles: string[] | undefined; + // there are many other variables in the data but they are not needed yet +} From 888ff77edabbed88cca5e1ff861a9ee4892a4f84 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Mon, 31 Jul 2023 15:49:20 -0700 Subject: [PATCH 046/270] [Functions] Consistent order and types of billing config (#10011) --- .../functions/dev/1_0_0/FunctionsBilling.sol | 44 ++++++------ .../1_0_0/interfaces/IFunctionsBilling.sol | 30 +++++---- .../functions/v1/FunctionsCoordinator.test.ts | 4 +- contracts/test/v0.8/functions/v1/utils.ts | 8 +-- .../functions_coordinator.go | 27 +++++--- ...rapper-dependency-versions-do-not-edit.txt | 2 +- .../v1/functions_integration_test.go | 4 +- .../v1/internal/testutils.go | 67 ++++++------------- .../evm/functions/contract_transmitter.go | 4 +- 9 files changed, 89 insertions(+), 101 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index a53353f61c0..1275adee2a7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -70,10 +70,11 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint32 feedStalenessSeconds, uint32 gasOverheadBeforeCallback, uint32 gasOverheadAfterCallback, - int256 fallbackNativePerUnitLink, + uint32 requestTimeoutSeconds, uint80 donFee, uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP + uint256 fulfillmentGasPriceOverEstimationBP, + int256 fallbackNativePerUnitLink ); error UnsupportedRequestDataVersion(); @@ -128,14 +129,14 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { ( uint32 maxCallbackGasLimit, uint32 feedStalenessSeconds, - uint32 gasOverheadAfterCallback, uint32 gasOverheadBeforeCallback, - int256 fallbackNativePerUnitLink, + uint32 gasOverheadAfterCallback, uint32 requestTimeoutSeconds, uint80 donFee, uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP - ) = abi.decode(config, (uint32, uint32, uint32, uint32, int256, uint32, uint80, uint16, uint256)); + uint256 fulfillmentGasPriceOverEstimationBP, + int256 fallbackNativePerUnitLink + ) = abi.decode(config, (uint32, uint32, uint32, uint32, uint32, uint80, uint16, uint256, int256)); if (fallbackNativePerUnitLink <= 0) { revert InvalidLinkWeiPrice(fallbackNativePerUnitLink); @@ -143,23 +144,24 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { s_config = Config({ maxCallbackGasLimit: maxCallbackGasLimit, feedStalenessSeconds: feedStalenessSeconds, - gasOverheadAfterCallback: gasOverheadAfterCallback, gasOverheadBeforeCallback: gasOverheadBeforeCallback, + gasOverheadAfterCallback: gasOverheadAfterCallback, requestTimeoutSeconds: requestTimeoutSeconds, donFee: donFee, - fallbackNativePerUnitLink: fallbackNativePerUnitLink, maxSupportedRequestDataVersion: maxSupportedRequestDataVersion, - fulfillmentGasPriceOverEstimationBP: fulfillmentGasPriceOverEstimationBP + fulfillmentGasPriceOverEstimationBP: fulfillmentGasPriceOverEstimationBP, + fallbackNativePerUnitLink: fallbackNativePerUnitLink }); emit ConfigChanged( maxCallbackGasLimit, feedStalenessSeconds, gasOverheadBeforeCallback, gasOverheadAfterCallback, - fallbackNativePerUnitLink, + requestTimeoutSeconds, donFee, maxSupportedRequestDataVersion, - fulfillmentGasPriceOverEstimationBP + fulfillmentGasPriceOverEstimationBP, + fallbackNativePerUnitLink ); } @@ -173,23 +175,27 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { returns ( uint32 maxCallbackGasLimit, uint32 feedStalenessSeconds, - uint256 gasOverheadAfterCallback, - int256 fallbackNativePerUnitLink, uint32 gasOverheadBeforeCallback, - address linkPriceFeed, + uint32 gasOverheadAfterCallback, + uint32 requestTimeoutSeconds, + uint80 donFee, uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP + uint256 fulfillmentGasPriceOverEstimationBP, + int256 fallbackNativePerUnitLink, + address linkPriceFeed ) { return ( s_config.maxCallbackGasLimit, s_config.feedStalenessSeconds, - s_config.gasOverheadAfterCallback, - s_config.fallbackNativePerUnitLink, s_config.gasOverheadBeforeCallback, - address(s_linkToNativeFeed), + s_config.gasOverheadAfterCallback, + s_config.requestTimeoutSeconds, + s_config.donFee, s_config.maxSupportedRequestDataVersion, - s_config.fulfillmentGasPriceOverEstimationBP + s_config.fulfillmentGasPriceOverEstimationBP, + s_config.fallbackNativePerUnitLink, + address(s_linkToNativeFeed) ); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index cc0c0394276..f3268229d9b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -19,27 +19,31 @@ interface IFunctionsBilling { /** * @notice Gets the configuration of the Chainlink Functions billing registry - * @return maxGasLimit global max for request gas limit - * @return stalenessSeconds if the eth/link feed is more stale then this, use the fallback price - * @return gasAfterPaymentCalculation gas used in doing accounting after completing the gas measurement - * @return fallbackWeiPerUnitLink fallback eth/link price in the case of a stale feed - * @return gasOverhead average gas execution cost used in estimating total cost - * @return linkPriceFeed address of contract for a conversion price between LINK token and native token + * @return maxCallbackGasLimit global max for request gas limit + * @return feedStalenessSeconds if the eth/link feed is more stale then this, use the fallback price + * @return gasOverheadBeforeCallback gas used in doing accounting before completing the gas measurement + * @return gasOverheadAfterCallback gas used in doing accounting after completing the gas measurement + * @return requestTimeoutSeconds e2e timeout for a request + * @return donFee extra fee added to every request * @return maxSupportedRequestDataVersion The highest support request data version supported by the node * @return fulfillmentGasPriceOverEstimationBP Percentage of gas price overestimation to account for changes in gas price between request and response. Held as basis points (one hundredth of 1 percentage point) + * @return fallbackNativePerUnitLink fallback native/link price in the case of a stale feed + * @return linkPriceFeed address of contract for a conversion price between LINK token and native token */ function getConfig() external view returns ( - uint32 maxGasLimit, - uint32 stalenessSeconds, - uint256 gasAfterPaymentCalculation, - int256 fallbackWeiPerUnitLink, - uint32 gasOverhead, - address linkPriceFeed, + uint32 maxCallbackGasLimit, + uint32 feedStalenessSeconds, + uint32 gasOverheadBeforeCallback, + uint32 gasOverheadAfterCallback, + uint32 requestTimeoutSeconds, + uint80 donFee, uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP + uint256 fulfillmentGasPriceOverEstimationBP, + int256 fallbackNativePerUnitLink, + address linkPriceFeed ); /** diff --git a/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts b/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts index 29ef0b5b640..ae20fa7588d 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts @@ -28,11 +28,11 @@ describe('Functions Coordinator', () => { 'uint32', 'uint32', 'uint32', - 'int256', 'uint32', - 'uint96', + 'uint80', 'uint16', 'uint256', + 'int256', ], [ ...Object.values({ diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index 6f535dddb92..8f818e12e3b 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -72,9 +72,9 @@ export type CoordinatorConfig = { gasOverheadAfterCallback: number requestTimeoutSeconds: number donFee: number - fallbackNativePerUnitLink: BigNumber maxSupportedRequestDataVersion: number fulfillmentGasPriceOverEstimationBP: number + fallbackNativePerUnitLink: BigNumber } const fallbackNativePerUnitLink = 5000000000000000 export const coordinatorConfig: CoordinatorConfig = { @@ -84,9 +84,9 @@ export const coordinatorConfig: CoordinatorConfig = { gasOverheadAfterCallback: 44_615, requestTimeoutSeconds: 300, donFee: 0, - fallbackNativePerUnitLink: BigNumber.from(fallbackNativePerUnitLink), maxSupportedRequestDataVersion: 1, fulfillmentGasPriceOverEstimationBP: 0, + fallbackNativePerUnitLink: BigNumber.from(fallbackNativePerUnitLink), } export const accessControlMockPublicKey = '0x32237412cC0321f56422d206e505dB4B3871AF5c' @@ -241,11 +241,11 @@ export function getSetupFactory(): () => { 'uint32', 'uint32', 'uint32', - 'int256', 'uint32', - 'uint96', + 'uint80', 'uint16', 'uint256', + 'int256', ], [...Object.values(coordinatorConfig)], ) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index bfc31cf0633..311bee4b306 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -61,8 +61,8 @@ type IFunctionsCoordinatorRequest struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005cf438038062005cf4833981016040819052620000349162000454565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006269350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000564565b985098509850985098509850985098509850600085136200025b576040516321ea67b360e11b81526004810186905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a16608086018190526001600160501b038a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a829055600b869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd73906200040d908b908b908a908c908b908a908a908a9063ffffffff98891681529688166020880152948716604087015292909516606085015260808401526001600160501b039390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043957600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046a57600080fd5b620004758462000421565b602085810151919450906001600160401b03808211156200049557600080fd5b818701915087601f830112620004aa57600080fd5b815181811115620004bf57620004bf6200043e565b604051601f8201601f19908116603f01168101908382118183101715620004ea57620004ea6200043e565b816040528281528a868487010111156200050357600080fd5b600093505b8284101562000527578484018601518185018701529285019262000508565b6000868483010152809750505050505050620005466040850162000421565b90509250925092565b805163ffffffff811681146200043957600080fd5b60008060008060008060008060006101208a8c0312156200058457600080fd5b6200058f8a6200054f565b98506200059f60208b016200054f565b9750620005af60408b016200054f565b9650620005bf60608b016200054f565b955060808a01519450620005d660a08b016200054f565b60c08b01519094506001600160501b0381168114620005f457600080fd5b60e08b015190935061ffff811681146200060d57600080fd5b809250506101008a015190509295985092959850929598565b60805160a0516156776200067d60003960008181610a6001528181610e2801528181611065015281816110ef01528181611b9901528181611d9d01528181612f4f0152613e560152600061159401526156776000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e1461053f578063de9dfa4614610547578063e3d0e7121461055a578063f2fde38b1461056d57600080fd5b8063b1dc65a41461040d578063c3f909d414610420578063d227d2451461050f57600080fd5b8063aecc12c5116100c8578063aecc12c5146103a5578063af1296d3146103e5578063afcb95d7146103ed57600080fd5b80638cc6acce146103585780638da5cb5b1461036b5780639883c10d1461039357600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ab57806381f1b938146102c057806381ff7048146102c857806385b214cf1461033557600080fd5b806379ba50971461027d5780637f15e16614610285578063807560311461029857600080fd5b8063466557181161018c5780634665571814610226578063533989871461025457806366316d8d1461026a57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004614117565b610580565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a91906141bd565b60405180910390f35b6101c66102213660046141f2565b6105d5565b61023961023436600461434e565b610677565b60405169ffffffffffffffffffff909116815260200161020a565b61025c6106a5565b60405161020a929190614475565b6101c661027836600461451f565b610929565b6101c6610ac5565b6101c6610293366004614117565b610bc7565b6101c66102a6366004614558565b610c17565b6102b3610cce565b60405161020a91906145ad565b6101fd610d3d565b61031260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff94851681529390921660208401529082015260600161020a565b6103486103433660046145c0565b610e0e565b604051901515815260200161020a565b6101c66103663660046145d9565b61104d565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6007545b60405190815260200161020a565b6103b86103b3366004614616565b6110d2565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b61039761132e565b60408051600181526000602082018190529181019190915260600161020a565b6101c661041b366004614696565b611421565b6104ab600954600b54600d54600a5463ffffffff8085169564010000000086048216956c010000000000000000000000008082048416969568010000000000000000830490941694930473ffffffffffffffffffffffffffffffffffffffff16927e0100000000000000000000000000000000000000000000000000000000000090910461ffff1691565b6040805163ffffffff998a168152978916602089015287019590955260608601939093529416608084015273ffffffffffffffffffffffffffffffffffffffff90931660a083015261ffff90921660c082015260e08101919091526101000161020a565b61052261051d36600461474d565b611b52565b6040516bffffffffffffffffffffffff909116815260200161020a565b6101fd611d42565b61052261055536600461434e565b611d99565b6101c661056836600461486f565b611e31565b6101c661057b3660046141f2565b612855565b610588612866565b60008190036105c3576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105d08284836149dd565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061057503373ffffffffffffffffffffffffffffffffffffffff8216145b610646576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f602052604081206106749161405c565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106e2575b505050505090506000815167ffffffffffffffff8111156107305761073061420f565b60405190808252806020026020018201604052801561076357816020015b606081526020019060019003908161074e5790505b50905060005b825181101561091f57600f600084838151811061078857610788614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107d59061493c565b9050600003610810576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061082657610826614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546108739061493c565b80601f016020809104026020016040519081016040528092919081815260200182805461089f9061493c565b80156108ec5780601f106108c1576101008083540402835291602001916108ec565b820191906000526020600020905b8154815290600101906020018083116108cf57829003601f168201915b505050505082828151811061090357610903614af8565b60200260200101819052508061091890614b56565b9050610769565b5090939092509050565b6109316128e9565b806bffffffffffffffffffffffff166000036109675750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109c1576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109ee9084906bffffffffffffffffffffffff16614b8e565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116600483015291841660248201527f00000000000000000000000000000000000000000000000000000000000000009250908216906366316d8d90604401600060405180830381600087803b158015610aa857600080fd5b505af1158015610abc573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b4b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bcf612866565b6000819003610c0a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105d08284836149dd565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c625750610c4133612a80565b8015610c6257503373ffffffffffffffffffffffffffffffffffffffff8416145b610c98576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cc88284836149dd565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d3357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d08575b5050505050905090565b606060108054610d4c9061493c565b9050600003610d87576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610d949061493c565b80601f0160208091040260200160405190810160405280929190818152602001828054610dc09061493c565b8015610d335780601f10610de257610100808354040283529160200191610d33565b820191906000526020600020905b815481529060010190602001808311610df057509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e7f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff1661010084015260030154610120830152610fd35750600092915050565b600083815260086020526040808220828155600181018390556002810180547fff000000000000000000000000000000000000000000000000000000000000001690556003018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146110bc576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110c581612b69565b8051602090910120600755565b60008080803373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611146576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111536040860186614bba565b905060000361118d576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808760600160208101906111ad9190614c1f565b67ffffffffffffffff1681526020908101906111cb908901896141f2565b73ffffffffffffffffffffffffffffffffffffffff1681526020016111f660e0890160c08a01614c3c565b63ffffffff1681523a60209091015290506112626112176040880188614bba565b8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061125c9250505060a0890160808a01614c69565b83612e64565b9297509095509350915061127960208701876141f2565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c326112c260808b0160608c01614c1f565b6112d260408c0160208d016141f2565b6112df60408d018d614bba565b8d60800160208101906112f29190614c69565b8e60a001358f60c001602081019061130a9190614c3c565b60405161131e989796959493929190614c86565b60405180910390a3509193509193565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156113c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113ec9190614d46565b5093505092505082801561140e57506114058142614d96565b8463ffffffff16105b1561141957600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161147791849163ffffffff851691908e908e908190840183828082843760009201919091525061350f92505050565b6114ad576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b42565b6115908b8b8b8b8b8b613518565b60007f0000000000000000000000000000000000000000000000000000000000000000156115ed576002826020015183604001516115ce9190614da9565b6115d89190614df1565b6115e3906001614da9565b60ff169050611603565b60208201516115fd906001614da9565b60ff1690505b88811461166c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b42565b8887146116d5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b42565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561171857611718614e13565b600281111561172957611729614e13565b905250905060028160200151600281111561174657611746614e13565b14801561178d57506006816000015160ff168154811061176857611768614af8565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6117f3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b42565b5050505050611800614096565b6000808a8a604051611813929190614e42565b60405190819003812061182a918e90602001614e52565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b3457600060018489846020811061189357611893614af8565b6118a091901a601b614da9565b8e8e868181106118b2576118b2614af8565b905060200201358d8d878181106118cb576118cb614af8565b9050602002013560405160008152602001604052604051611908949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561192a573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119aa576119aa614e13565b60028111156119bb576119bb614e13565b90525092506001836020015160028111156119d8576119d8614e13565b14611a3f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b42565b8251600090879060ff16601f8110611a5957611a59614af8565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611adb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b42565b8086846000015160ff16601f8110611af557611af5614af8565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b20600186614da9565b94505080611b2d90614b56565b9050611874565b505050611b45833383858e8e6135c6565b5050505050505050505050565b6040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8616600482015263ffffffff831660248201526000907f00000000000000000000000000000000000000000000000000000000000000009073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611bf257600080fd5b505afa158015611c06573d6000803e3d6000fd5b50505050620f4240831115611c47576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611cd588888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610677915050565b69ffffffffffffffffffff1690506000611d2689898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611d99915050565b9050611d34878784846138cd565b9a9950505050505050505050565b6060600e8054611d519061493c565b9050600003611d8c576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610d949061493c565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611e06573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e2a9190614e66565b9392505050565b855185518560ff16601f831115611ea4576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b42565b80600003611f0e576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b42565b818314611f9c576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b42565b611fa7816003614e83565b831161200f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b42565b612017612866565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a081018690529061205e9088613a2f565b600554156122135760055460009061207890600190614d96565b905060006005828154811061208f5761208f614af8565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff909216935090849081106120c9576120c9614af8565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061214957612149614e9a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806121b2576121b2614e9a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061205e915050565b60005b81515181101561267a576000600460008460000151848151811061223c5761223c614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561228657612286614e13565b146122ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b42565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061231e5761231e614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156123bf576123bf614e13565b0217905550600091506123cf9050565b60046000846020015184815181106123e9576123e9614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561243357612433614e13565b1461249a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b42565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106124cd576124cd614af8565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561256e5761256e614e13565b02179055505082518051600592508390811061258c5761258c614af8565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061260857612608614af8565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061267281614b56565b915050612216565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161273291849174010000000000000000000000000000000000000000900416614ec9565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127914630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613a4c565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612848988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614ee6565b60405180910390a1611b45565b61285d612866565b61067481613af7565b60005473ffffffffffffffffffffffffffffffffffffffff1633146128e7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b42565b565b60006128f3610cce565b90508051600003612930576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d5460009161294f916bffffffffffffffffffffffff16614f6c565b905060005b82518160ff161015612a215781600c6000858460ff168151811061297a5761297a614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129e29190614f97565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612a1a90614fbc565b9050612954565b508151612a2e9082614fdb565b600d8054600090612a4e9084906bffffffffffffffffffffffff16614b8e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612ae657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612abb575b5050505050905060005b8151811015612b5f578373ffffffffffffffffffffffffffffffffffffffff16828281518110612b2257612b22614af8565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612b4f575060019392505050565b612b5881614b56565b9050612af0565b5060009392505050565b600080600080600080600080600089806020019051810190612b8b919061500b565b98509850985098509850985098509850985060008513612bda576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101869052602401610b42565b604080516101208101825263ffffffff808c168083528b8216602084018190528a83168486018190528c841660608601819052938a166080860181905269ffffffffffffffffffff8a1660a0870181905261ffff8a1660c0880181905260e088018a90526101009097018d9052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a829055600b869055517f9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd7390612e50908b908b908a908c908b908a908a908a9063ffffffff988916815296881660208801529487166040870152929095166060850152608084015269ffffffffffffffffffff9390931660a083015261ffff9290921660c082015260e08101919091526101000190565b60405180910390a150505050505050505050565b60095460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612ed3576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612edf8887610677565b90506000612eed8988611d99565b90506000612f11886040015189606001518569ffffffffffffffffffff16856138cd565b88516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612fb2573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612ff891908101906150b7565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015613089573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130ad91906151a3565b509150506bffffffffffffffffffffffff85166130ca8385614b8e565b6bffffffffffffffffffffffff161015613110576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061318f308e602001518f6000015185600161312d91906151f5565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff1681526020016009600001600c9054906101000a900463ffffffff16600960000160089054906101000a900463ffffffff1661327b9190614ec9565b63ffffffff1664ffffffffff1681526020018f606001518152509050806008600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd826040516134bf9190615216565b60405180910390a250600954909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613525826020614e83565b613530856020614e83565b61353c8861014461532b565b613546919061532b565b613550919061532b565b61355b90600061532b565b9050368114610abc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b42565b606080806135d6848601866153be565b8251929550909350915015806135ee57508151835114155b806135fb57508051835114155b15613632576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156138c157600061369685838151811061365557613655614af8565b602002602001015185848151811061366f5761366f614af8565b602002602001015185858151811061368957613689614af8565b6020026020010151613bec565b905060008160068111156136ac576136ac614e13565b14806136c9575060018160068111156136c7576136c7614e13565b145b15613724578482815181106136e0576136e0614af8565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a26138b0565b600281600681111561373857613738614e13565b036137885784828151811061374f5761374f614af8565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a26138b0565b600381600681111561379c5761379c614e13565b036137ec578482815181106137b3576137b3614af8565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a26138b0565b600581600681111561380057613800614e13565b036138505784828151811061381757613817614af8565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a26138b0565b600481600681111561386457613864614e13565b036138b05784828151811061387b5761387b614af8565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b506138ba81614b56565b9050613635565b50505050505050505050565b6000806138d861132e565b905060008113613917576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b42565b600954600090879061394d9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614ec9565b6139579190614ec9565b63ffffffff1690506000612710600960010154886139759190614e83565b61397f919061549b565b613989908861532b565b9050600083836139a184670de0b6b3a7640000614e83565b6139ab9190614e83565b6139b5919061549b565b905060006139d46bffffffffffffffffffffffff808916908a1661532b565b90506139ec816b033b2e3c9fd0803ce8000000614d96565b821115613a25576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611d34818361532b565b6000613a39610cce565b511115613a4857613a486128e9565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613a70999897969594939291906154af565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613b76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b42565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600860209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613d41576002915050611e2a565b6000858152600860205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613d9161132e565b905060008113613dd0576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b42565b600081613de53a670de0b6b3a7640000614e83565b613def919061549b565b9050600083610100015164ffffffffff1682613e0b9190614e83565b905060008460c0015169ffffffffffffffffffff1682613e2b9190614f97565b6040517f3fd67e050000000000000000000000000000000000000000000000000000000081529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff841690633fd67e0590613eb1908f908f908f908c908b903390600401615544565b60408051808303816000875af1158015613ecf573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ef391906155b5565b9092509050613f028186614f97565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600d805469ffffffffffffffffffff90921693909291613f6f91859116614f97565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c001518489613fd59190614f97565b60808d015160c08e015169ffffffffffffffffffff16613ff5888d614f97565b613fff9190614f97565b6140099190614f97565b8760ff16600681111561401e5761401e614e13565b60405161402f9594939291906155e4565b60405180910390a28160ff16600681111561404c5761404c614e13565b9c9b505050505050505050505050565b5080546140689061493c565b6000825580601f10614078575050565b601f01602090049060005260206000209081019061067491906140b5565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156140ca57600081556001016140b6565b5090565b60008083601f8401126140e057600080fd5b50813567ffffffffffffffff8111156140f857600080fd5b60208301915083602082850101111561411057600080fd5b9250929050565b6000806020838503121561412a57600080fd5b823567ffffffffffffffff81111561414157600080fd5b61414d858286016140ce565b90969095509350505050565b6000815180845260005b8181101561417f57602081850181015186830182015201614163565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611e2a6020830184614159565b73ffffffffffffffffffffffffffffffffffffffff8116811461067457600080fd5b60006020828403121561420457600080fd5b8135611e2a816141d0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156142855761428561420f565b604052919050565b600082601f83011261429e57600080fd5b813567ffffffffffffffff8111156142b8576142b861420f565b6142e960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161423e565b8181528460208386010111156142fe57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067457600080fd5b80356110488161431b565b63ffffffff8116811461067457600080fd5b60008082840360a081121561436257600080fd5b833567ffffffffffffffff8082111561437a57600080fd5b6143868783880161428d565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156143b857600080fd5b604051925060808301915082821081831117156143d7576143d761420f565b5060405260208401356143e98161431b565b815260408401356143f9816141d0565b6020820152606084013561440c8161433c565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561446a57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614438565b509495945050505050565b6040815260006144886040830185614424565b6020838203818501528185518084528284019150828160051b85010183880160005b838110156144f6577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526144e4838351614159565b948601949250908501906001016144aa565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461067457600080fd5b6000806040838503121561453257600080fd5b823561453d816141d0565b9150602083013561454d81614505565b809150509250929050565b60008060006040848603121561456d57600080fd5b8335614578816141d0565b9250602084013567ffffffffffffffff81111561459457600080fd5b6145a0868287016140ce565b9497909650939450505050565b602081526000611e2a6020830184614424565b6000602082840312156145d257600080fd5b5035919050565b6000602082840312156145eb57600080fd5b813567ffffffffffffffff81111561460257600080fd5b61460e8482850161428d565b949350505050565b60006020828403121561462857600080fd5b813567ffffffffffffffff81111561463f57600080fd5b820160e08185031215611e2a57600080fd5b60008083601f84011261466357600080fd5b50813567ffffffffffffffff81111561467b57600080fd5b6020830191508360208260051b850101111561411057600080fd5b60008060008060008060008060e0898b0312156146b257600080fd5b606089018a8111156146c357600080fd5b8998503567ffffffffffffffff808211156146dd57600080fd5b6146e98c838d016140ce565b909950975060808b013591508082111561470257600080fd5b61470e8c838d01614651565b909750955060a08b013591508082111561472757600080fd5b506147348b828c01614651565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561476557600080fd5b85356147708161431b565b9450602086013567ffffffffffffffff81111561478c57600080fd5b614798888289016140ce565b90955093505060408601356147ac8161433c565b949793965091946060013592915050565b600067ffffffffffffffff8211156147d7576147d761420f565b5060051b60200190565b600082601f8301126147f257600080fd5b81356020614807614802836147bd565b61423e565b82815260059290921b8401810191818101908684111561482657600080fd5b8286015b8481101561484a57803561483d816141d0565b835291830191830161482a565b509695505050505050565b60ff8116811461067457600080fd5b803561104881614855565b60008060008060008060c0878903121561488857600080fd5b863567ffffffffffffffff808211156148a057600080fd5b6148ac8a838b016147e1565b975060208901359150808211156148c257600080fd5b6148ce8a838b016147e1565b96506148dc60408a01614864565b955060608901359150808211156148f257600080fd5b6148fe8a838b0161428d565b945061490c60808a01614331565b935060a089013591508082111561492257600080fd5b5061492f89828a0161428d565b9150509295509295509295565b600181811c9082168061495057607f821691505b602082108103614989577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105d057600081815260208120601f850160051c810160208610156149b65750805b601f850160051c820191505b818110156149d5578281556001016149c2565b505050505050565b67ffffffffffffffff8311156149f5576149f561420f565b614a0983614a03835461493c565b8361498f565b6000601f841160018114614a5b5760008515614a255750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614af1565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b82811015614aaa5786850135825560209485019460019092019101614a8a565b5086821015614ae5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614b8757614b87614b27565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614bb357614bb3614b27565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614bef57600080fd5b83018035915067ffffffffffffffff821115614c0a57600080fd5b60200191503681900382131561411057600080fd5b600060208284031215614c3157600080fd5b8135611e2a8161431b565b600060208284031215614c4e57600080fd5b8135611e2a8161433c565b61ffff8116811461067457600080fd5b600060208284031215614c7b57600080fd5b8135611e2a81614c59565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461104857600080fd5b600080600080600060a08688031215614d5e57600080fd5b614d6786614d2c565b9450602086015193506040860151925060608601519150614d8a60808701614d2c565b90509295509295909350565b8181038181111561069f5761069f614b27565b60ff818116838216019081111561069f5761069f614b27565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614e0457614e04614dc2565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614e7857600080fd5b8151611e2a81614505565b808202811582820484141761069f5761069f614b27565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614bb357614bb3614b27565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614f168184018a614424565b90508281036080840152614f2a8189614424565b905060ff871660a084015282810360c0840152614f478187614159565b905067ffffffffffffffff851660e084015282810361010084015261404c8185614159565b60006bffffffffffffffffffffffff80841680614f8b57614f8b614dc2565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614bb357614bb3614b27565b600060ff821660ff8103614fd257614fd2614b27565b60010192915050565b6bffffffffffffffffffffffff81811683821602808216919082811461500357615003614b27565b505092915050565b60008060008060008060008060006101208a8c03121561502a57600080fd5b89516150358161433c565b60208b01519099506150468161433c565b60408b01519098506150578161433c565b60608b01519097506150688161433c565b60808b015160a08c015191975095506150808161433c565b935061508e60c08b01614d2c565b925060e08a015161509e81614c59565b809250506101008a015190509295985092959850929598565b600080600080600060a086880312156150cf57600080fd5b85516150da81614505565b809550506020808701516150ed81614505565b60408801519095506150fe816141d0565b606088015190945061510f816141d0565b608088015190935067ffffffffffffffff81111561512c57600080fd5b8701601f8101891361513d57600080fd5b805161514b614802826147bd565b81815260059190911b8201830190838101908b83111561516a57600080fd5b928401925b82841015615191578351615182816141d0565b8252928401929084019061516f565b80955050505050509295509295909350565b6000806000606084860312156151b857600080fd5b835180151581146151c857600080fd5b60208501519093506151d98161431b565b60408501519092506151ea8161431b565b809150509250925092565b67ffffffffffffffff818116838216019080821115614bb357614bb3614b27565b815167ffffffffffffffff16815261014081016020830151615250602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615268604084018263ffffffff169052565b506060830151615290606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516152b060808401826bffffffffffffffffffffffff169052565b5060a08301516152d060a08401826bffffffffffffffffffffffff169052565b5060c08301516152ee60c084018269ffffffffffffffffffff169052565b5060e083015161530660e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b8082018082111561069f5761069f614b27565b600082601f83011261534f57600080fd5b8135602061535f614802836147bd565b82815260059290921b8401810191818101908684111561537e57600080fd5b8286015b8481101561484a57803567ffffffffffffffff8111156153a25760008081fd5b6153b08986838b010161428d565b845250918301918301615382565b6000806000606084860312156153d357600080fd5b833567ffffffffffffffff808211156153eb57600080fd5b818601915086601f8301126153ff57600080fd5b8135602061540f614802836147bd565b82815260059290921b8401810191818101908a84111561542e57600080fd5b948201945b8386101561544c57853582529482019490820190615433565b9750508701359250508082111561546257600080fd5b61546e8783880161533e565b9350604086013591508082111561548457600080fd5b506154918682870161533e565b9150509250925092565b6000826154aa576154aa614dc2565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526154f68285018b614424565b9150838203608085015261550a828a614424565b915060ff881660a085015283820360c08501526155278288614159565b90861660e0850152838103610100850152905061404c8185614159565b86815260c06020820152600061555d60c0830188614159565b828103604084015261556f8188614159565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156155c857600080fd5b82516155d381614855565b602084015190925061454d81614505565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a081016007831061565a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005d1f38038062005d1f833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516156946200068b60003960008181610a6f01528181610e3701528181611074015281816110fe01528181611ba801528181611dac01528181612f6c0152613e73015260006115a301526156946000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e1461054e578063de9dfa4614610556578063e3d0e71214610569578063f2fde38b1461057c57600080fd5b8063b1dc65a41461040d578063c3f909d414610420578063d227d2451461051e57600080fd5b8063aecc12c5116100c8578063aecc12c5146103a5578063af1296d3146103e5578063afcb95d7146103ed57600080fd5b80638cc6acce146103585780638da5cb5b1461036b5780639883c10d1461039357600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ab57806381f1b938146102c057806381ff7048146102c857806385b214cf1461033557600080fd5b806379ba50971461027d5780637f15e16614610285578063807560311461029857600080fd5b8063466557181161018c5780634665571814610226578063533989871461025457806366316d8d1461026a57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004614134565b61058f565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a91906141da565b60405180910390f35b6101c661022136600461420f565b6105e4565b61023961023436600461436b565b610686565b60405169ffffffffffffffffffff909116815260200161020a565b61025c6106b4565b60405161020a929190614492565b6101c661027836600461453c565b610938565b6101c6610ad4565b6101c6610293366004614134565b610bd6565b6101c66102a6366004614575565b610c26565b6102b3610cdd565b60405161020a91906145ca565b6101fd610d4c565b61031260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff94851681529390921660208401529082015260600161020a565b6103486103433660046145dd565b610e1d565b604051901515815260200161020a565b6101c66103663660046145f6565b61105c565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6007545b60405190815260200161020a565b6103b86103b3366004614633565b6110e1565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b61039761133d565b60408051600181526000602082018190529181019190915260600161020a565b6101c661041b3660046146b3565b611430565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff166101208201526101400161020a565b61053161052c36600461476a565b611b61565b6040516bffffffffffffffffffffffff909116815260200161020a565b6101fd611d51565b61053161056436600461436b565b611da8565b6101c661057736600461488c565b611e40565b6101c661058a36600461420f565b612864565b610597612875565b60008190036105d2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105df8284836149fa565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061f57503373ffffffffffffffffffffffffffffffffffffffff8216145b610655576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061068391614079565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561071c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106f1575b505050505090506000815167ffffffffffffffff81111561073f5761073f61422c565b60405190808252806020026020018201604052801561077257816020015b606081526020019060019003908161075d5790505b50905060005b825181101561092e57600f600084838151811061079757610797614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107e490614959565b905060000361081f576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061083557610835614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461088290614959565b80601f01602080910402602001604051908101604052809291908181526020018280546108ae90614959565b80156108fb5780601f106108d0576101008083540402835291602001916108fb565b820191906000526020600020905b8154815290600101906020018083116108de57829003601f168201915b505050505082828151811061091257610912614b15565b60200260200101819052508061092790614b73565b9050610778565b5090939092509050565b6109406128f8565b806bffffffffffffffffffffffff166000036109765750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109d0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109fd9084906bffffffffffffffffffffffff16614bab565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116600483015291841660248201527f00000000000000000000000000000000000000000000000000000000000000009250908216906366316d8d90604401600060405180830381600087803b158015610ab757600080fd5b505af1158015610acb573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b5a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bde612875565b6000819003610c19576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105df8284836149fa565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c715750610c5033612a8f565b8015610c7157503373ffffffffffffffffffffffffffffffffffffffff8416145b610ca7576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cd78284836149fa565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d4257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d17575b5050505050905090565b606060108054610d5b90614959565b9050600003610d96576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610da390614959565b80601f0160208091040260200160405190810160405280929190818152602001828054610dcf90614959565b8015610d425780601f10610df157610100808354040283529160200191610d42565b820191906000526020600020905b815481529060010190602001808311610dff57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e8e576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff1661010084015260030154610120830152610fe25750600092915050565b600083815260086020526040808220828155600181018390556002810180547fff000000000000000000000000000000000000000000000000000000000000001690556003018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146110cb576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110d481612b78565b8051602090910120600755565b60008080803373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611155576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111626040860186614bd7565b905060000361119c576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808760600160208101906111bc9190614c3c565b67ffffffffffffffff1681526020908101906111da9089018961420f565b73ffffffffffffffffffffffffffffffffffffffff16815260200161120560e0890160c08a01614c59565b63ffffffff1681523a60209091015290506112716112266040880188614bd7565b8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061126b9250505060a0890160808a01614c86565b83612e81565b92975090955093509150611288602087018761420f565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c326112d160808b0160608c01614c3c565b6112e160408c0160208d0161420f565b6112ee60408d018d614bd7565b8d60800160208101906113019190614c86565b8e60a001358f60c00160208101906113199190614c59565b60405161132d989796959493929190614ca3565b60405180910390a3509193509193565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156113d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113fb9190614d63565b5093505092505082801561141d57506114148142614db3565b8463ffffffff16105b1561142857600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161148691849163ffffffff851691908e908e908190840183828082843760009201919091525061352c92505050565b6114bc576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611591576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b51565b61159f8b8b8b8b8b8b613535565b60007f0000000000000000000000000000000000000000000000000000000000000000156115fc576002826020015183604001516115dd9190614dc6565b6115e79190614e0e565b6115f2906001614dc6565b60ff169050611612565b602082015161160c906001614dc6565b60ff1690505b88811461167b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b51565b8887146116e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b51565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561172757611727614e30565b600281111561173857611738614e30565b905250905060028160200151600281111561175557611755614e30565b14801561179c57506006816000015160ff168154811061177757611777614b15565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611802576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b51565b505050505061180f6140b3565b6000808a8a604051611822929190614e5f565b604051908190038120611839918e90602001614e6f565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b435760006001848984602081106118a2576118a2614b15565b6118af91901a601b614dc6565b8e8e868181106118c1576118c1614b15565b905060200201358d8d878181106118da576118da614b15565b9050602002013560405160008152602001604052604051611917949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611939573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119b9576119b9614e30565b60028111156119ca576119ca614e30565b90525092506001836020015160028111156119e7576119e7614e30565b14611a4e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b51565b8251600090879060ff16601f8110611a6857611a68614b15565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611aea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b51565b8086846000015160ff16601f8110611b0457611b04614b15565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b2f600186614dc6565b94505080611b3c90614b73565b9050611883565b505050611b54833383858e8e6135e3565b5050505050505050505050565b6040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8616600482015263ffffffff831660248201526000907f00000000000000000000000000000000000000000000000000000000000000009073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611c0157600080fd5b505afa158015611c15573d6000803e3d6000fd5b50505050620f4240831115611c56576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611ce488888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610686915050565b69ffffffffffffffffffff1690506000611d3589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611da8915050565b9050611d43878784846138ea565b9a9950505050505050505050565b6060600e8054611d6090614959565b9050600003611d9b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610da390614959565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611e15573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e399190614e83565b9392505050565b855185518560ff16601f831115611eb3576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b51565b80600003611f1d576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b51565b818314611fab576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b51565b611fb6816003614ea0565b831161201e576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b51565b612026612875565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a081018690529061206d9088613a4c565b600554156122225760055460009061208790600190614db3565b905060006005828154811061209e5761209e614b15565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff909216935090849081106120d8576120d8614b15565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061215857612158614eb7565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806121c1576121c1614eb7565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061206d915050565b60005b815151811015612689576000600460008460000151848151811061224b5761224b614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561229557612295614e30565b146122fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b51565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061232d5761232d614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156123ce576123ce614e30565b0217905550600091506123de9050565b60046000846020015184815181106123f8576123f8614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561244257612442614e30565b146124a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b51565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106124dc576124dc614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561257d5761257d614e30565b02179055505082518051600592508390811061259b5761259b614b15565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061261757612617614b15565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061268181614b73565b915050612225565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161274191849174010000000000000000000000000000000000000000900416614ee6565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127a04630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613a69565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612857988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614f03565b60405180910390a1611b54565b61286c612875565b61068381613b14565b60005473ffffffffffffffffffffffffffffffffffffffff1633146128f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b51565b565b6000612902610cdd565b9050805160000361293f576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d5460009161295e916bffffffffffffffffffffffff16614f89565b905060005b82518160ff161015612a305781600c6000858460ff168151811061298957612989614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129f19190614fb4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612a2990614fd9565b9050612963565b508151612a3d9082614ff8565b600d8054600090612a5d9084906bffffffffffffffffffffffff16614bab565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612af557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612aca575b5050505050905060005b8151811015612b6e578373ffffffffffffffffffffffffffffffffffffffff16828281518110612b3157612b31614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612b5e575060019392505050565b612b6781614b73565b9050612aff565b5060009392505050565b600080600080600080600080600089806020019051810190612b9a9190615028565b98509850985098509850985098509850985060008113612be9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b51565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612e6d908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60095460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612ef0576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612efc8887610686565b90506000612f0a8988611da8565b90506000612f2e886040015189606001518569ffffffffffffffffffff16856138ea565b88516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612fcf573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261301591908101906150d4565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156130a6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130ca91906151c0565b509150506bffffffffffffffffffffffff85166130e78385614bab565b6bffffffffffffffffffffffff16101561312d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006131ac308e602001518f6000015185600161314a9190615212565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff1681526020016009600001600c9054906101000a900463ffffffff16600960000160089054906101000a900463ffffffff166132989190614ee6565b63ffffffff1664ffffffffff1681526020018f606001518152509050806008600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd826040516134dc9190615233565b60405180910390a250600954909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613542826020614ea0565b61354d856020614ea0565b61355988610144615348565b6135639190615348565b61356d9190615348565b613578906000615348565b9050368114610acb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b51565b606080806135f3848601866153db565b82519295509093509150158061360b57508151835114155b8061361857508051835114155b1561364f576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156138de5760006136b385838151811061367257613672614b15565b602002602001015185848151811061368c5761368c614b15565b60200260200101518585815181106136a6576136a6614b15565b6020026020010151613c09565b905060008160068111156136c9576136c9614e30565b14806136e6575060018160068111156136e4576136e4614e30565b145b15613741578482815181106136fd576136fd614b15565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a26138cd565b600281600681111561375557613755614e30565b036137a55784828151811061376c5761376c614b15565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a26138cd565b60038160068111156137b9576137b9614e30565b03613809578482815181106137d0576137d0614b15565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a26138cd565b600581600681111561381d5761381d614e30565b0361386d5784828151811061383457613834614b15565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a26138cd565b600481600681111561388157613881614e30565b036138cd5784828151811061389857613898614b15565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b506138d781614b73565b9050613652565b50505050505050505050565b6000806138f561133d565b905060008113613934576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b51565b600954600090879061396a9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614ee6565b6139749190614ee6565b63ffffffff1690506000612710600960010154886139929190614ea0565b61399c91906154b8565b6139a69088615348565b9050600083836139be84670de0b6b3a7640000614ea0565b6139c89190614ea0565b6139d291906154b8565b905060006139f16bffffffffffffffffffffffff808916908a16615348565b9050613a09816b033b2e3c9fd0803ce8000000614db3565b821115613a42576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611d438183615348565b6000613a56610cdd565b511115613a6557613a656128f8565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613a8d999897969594939291906154cc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613b93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b51565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600860209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613d5e576002915050611e39565b6000858152600860205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613dae61133d565b905060008113613ded576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b51565b600081613e023a670de0b6b3a7640000614ea0565b613e0c91906154b8565b9050600083610100015164ffffffffff1682613e289190614ea0565b905060008460c0015169ffffffffffffffffffff1682613e489190614fb4565b6040517f3fd67e050000000000000000000000000000000000000000000000000000000081529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff841690633fd67e0590613ece908f908f908f908c908b903390600401615561565b60408051808303816000875af1158015613eec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f1091906155d2565b9092509050613f1f8186614fb4565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600d805469ffffffffffffffffffff90921693909291613f8c91859116614fb4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c001518489613ff29190614fb4565b60808d015160c08e015169ffffffffffffffffffff16614012888d614fb4565b61401c9190614fb4565b6140269190614fb4565b8760ff16600681111561403b5761403b614e30565b60405161404c959493929190615601565b60405180910390a28160ff16600681111561406957614069614e30565b9c9b505050505050505050505050565b50805461408590614959565b6000825580601f10614095575050565b601f01602090049060005260206000209081019061068391906140d2565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156140e757600081556001016140d3565b5090565b60008083601f8401126140fd57600080fd5b50813567ffffffffffffffff81111561411557600080fd5b60208301915083602082850101111561412d57600080fd5b9250929050565b6000806020838503121561414757600080fd5b823567ffffffffffffffff81111561415e57600080fd5b61416a858286016140eb565b90969095509350505050565b6000815180845260005b8181101561419c57602081850181015186830182015201614180565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611e396020830184614176565b73ffffffffffffffffffffffffffffffffffffffff8116811461068357600080fd5b60006020828403121561422157600080fd5b8135611e39816141ed565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156142a2576142a261422c565b604052919050565b600082601f8301126142bb57600080fd5b813567ffffffffffffffff8111156142d5576142d561422c565b61430660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161425b565b81815284602083860101111561431b57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461068357600080fd5b803561105781614338565b63ffffffff8116811461068357600080fd5b60008082840360a081121561437f57600080fd5b833567ffffffffffffffff8082111561439757600080fd5b6143a3878388016142aa565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156143d557600080fd5b604051925060808301915082821081831117156143f4576143f461422c565b50604052602084013561440681614338565b81526040840135614416816141ed565b6020820152606084013561442981614359565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561448757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614455565b509495945050505050565b6040815260006144a56040830185614441565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614513577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614501838351614176565b948601949250908501906001016144c7565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461068357600080fd5b6000806040838503121561454f57600080fd5b823561455a816141ed565b9150602083013561456a81614522565b809150509250929050565b60008060006040848603121561458a57600080fd5b8335614595816141ed565b9250602084013567ffffffffffffffff8111156145b157600080fd5b6145bd868287016140eb565b9497909650939450505050565b602081526000611e396020830184614441565b6000602082840312156145ef57600080fd5b5035919050565b60006020828403121561460857600080fd5b813567ffffffffffffffff81111561461f57600080fd5b61462b848285016142aa565b949350505050565b60006020828403121561464557600080fd5b813567ffffffffffffffff81111561465c57600080fd5b820160e08185031215611e3957600080fd5b60008083601f84011261468057600080fd5b50813567ffffffffffffffff81111561469857600080fd5b6020830191508360208260051b850101111561412d57600080fd5b60008060008060008060008060e0898b0312156146cf57600080fd5b606089018a8111156146e057600080fd5b8998503567ffffffffffffffff808211156146fa57600080fd5b6147068c838d016140eb565b909950975060808b013591508082111561471f57600080fd5b61472b8c838d0161466e565b909750955060a08b013591508082111561474457600080fd5b506147518b828c0161466e565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561478257600080fd5b853561478d81614338565b9450602086013567ffffffffffffffff8111156147a957600080fd5b6147b5888289016140eb565b90955093505060408601356147c981614359565b949793965091946060013592915050565b600067ffffffffffffffff8211156147f4576147f461422c565b5060051b60200190565b600082601f83011261480f57600080fd5b8135602061482461481f836147da565b61425b565b82815260059290921b8401810191818101908684111561484357600080fd5b8286015b8481101561486757803561485a816141ed565b8352918301918301614847565b509695505050505050565b60ff8116811461068357600080fd5b803561105781614872565b60008060008060008060c087890312156148a557600080fd5b863567ffffffffffffffff808211156148bd57600080fd5b6148c98a838b016147fe565b975060208901359150808211156148df57600080fd5b6148eb8a838b016147fe565b96506148f960408a01614881565b9550606089013591508082111561490f57600080fd5b61491b8a838b016142aa565b945061492960808a0161434e565b935060a089013591508082111561493f57600080fd5b5061494c89828a016142aa565b9150509295509295509295565b600181811c9082168061496d57607f821691505b6020821081036149a6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105df57600081815260208120601f850160051c810160208610156149d35750805b601f850160051c820191505b818110156149f2578281556001016149df565b505050505050565b67ffffffffffffffff831115614a1257614a1261422c565b614a2683614a208354614959565b836149ac565b6000601f841160018114614a785760008515614a425750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614b0e565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b82811015614ac75786850135825560209485019460019092019101614aa7565b5086821015614b02577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614ba457614ba4614b44565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614bd057614bd0614b44565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614c0c57600080fd5b83018035915067ffffffffffffffff821115614c2757600080fd5b60200191503681900382131561412d57600080fd5b600060208284031215614c4e57600080fd5b8135611e3981614338565b600060208284031215614c6b57600080fd5b8135611e3981614359565b61ffff8116811461068357600080fd5b600060208284031215614c9857600080fd5b8135611e3981614c76565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461105757600080fd5b600080600080600060a08688031215614d7b57600080fd5b614d8486614d49565b9450602086015193506040860151925060608601519150614da760808701614d49565b90509295509295909350565b818103818111156106ae576106ae614b44565b60ff81811683821601908111156106ae576106ae614b44565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614e2157614e21614ddf565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614e9557600080fd5b8151611e3981614522565b80820281158282048414176106ae576106ae614b44565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614bd057614bd0614b44565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614f338184018a614441565b90508281036080840152614f478189614441565b905060ff871660a084015282810360c0840152614f648187614176565b905067ffffffffffffffff851660e08401528281036101008401526140698185614176565b60006bffffffffffffffffffffffff80841680614fa857614fa8614ddf565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614bd057614bd0614b44565b600060ff821660ff8103614fef57614fef614b44565b60010192915050565b6bffffffffffffffffffffffff81811683821602808216919082811461502057615020614b44565b505092915050565b60008060008060008060008060006101208a8c03121561504757600080fd5b895161505281614359565b60208b015190995061506381614359565b60408b015190985061507481614359565b60608b015190975061508581614359565b60808b015190965061509681614359565b94506150a460a08b01614d49565b935060c08a01516150b481614c76565b8093505060e08a015191506101008a015190509295985092959850929598565b600080600080600060a086880312156150ec57600080fd5b85516150f781614522565b8095505060208087015161510a81614522565b604088015190955061511b816141ed565b606088015190945061512c816141ed565b608088015190935067ffffffffffffffff81111561514957600080fd5b8701601f8101891361515a57600080fd5b805161516861481f826147da565b81815260059190911b8201830190838101908b83111561518757600080fd5b928401925b828410156151ae57835161519f816141ed565b8252928401929084019061518c565b80955050505050509295509295909350565b6000806000606084860312156151d557600080fd5b835180151581146151e557600080fd5b60208501519093506151f681614338565b604085015190925061520781614338565b809150509250925092565b67ffffffffffffffff818116838216019080821115614bd057614bd0614b44565b815167ffffffffffffffff1681526101408101602083015161526d602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615285604084018263ffffffff169052565b5060608301516152ad606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516152cd60808401826bffffffffffffffffffffffff169052565b5060a08301516152ed60a08401826bffffffffffffffffffffffff169052565b5060c083015161530b60c084018269ffffffffffffffffffff169052565b5060e083015161532360e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b808201808211156106ae576106ae614b44565b600082601f83011261536c57600080fd5b8135602061537c61481f836147da565b82815260059290921b8401810191818101908684111561539b57600080fd5b8286015b8481101561486757803567ffffffffffffffff8111156153bf5760008081fd5b6153cd8986838b01016142aa565b84525091830191830161539f565b6000806000606084860312156153f057600080fd5b833567ffffffffffffffff8082111561540857600080fd5b818601915086601f83011261541c57600080fd5b8135602061542c61481f836147da565b82815260059290921b8401810191818101908a84111561544b57600080fd5b948201945b8386101561546957853582529482019490820190615450565b9750508701359250508082111561547f57600080fd5b61548b8783880161535b565b935060408601359150808211156154a157600080fd5b506154ae8682870161535b565b9150509250925092565b6000826154c7576154c7614ddf565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526155138285018b614441565b91508382036080850152615527828a614441565b915060ff881660a085015283820360c08501526155448288614176565b90861660e085015283810361010085015290506140698185614176565b86815260c06020820152600061557a60c0830188614176565b828103604084015261558c8188614176565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156155e557600080fd5b82516155f081614872565b602084015190925061456a81614522565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a0810160078310615677577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -281,12 +281,14 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.Ca outstruct.MaxCallbackGasLimit = *abi.ConvertType(out[0], new(uint32)).(*uint32) outstruct.FeedStalenessSeconds = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.GasOverheadAfterCallback = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) - outstruct.FallbackNativePerUnitLink = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) - outstruct.GasOverheadBeforeCallback = *abi.ConvertType(out[4], new(uint32)).(*uint32) - outstruct.LinkPriceFeed = *abi.ConvertType(out[5], new(common.Address)).(*common.Address) + outstruct.GasOverheadBeforeCallback = *abi.ConvertType(out[2], new(uint32)).(*uint32) + outstruct.GasOverheadAfterCallback = *abi.ConvertType(out[3], new(uint32)).(*uint32) + outstruct.RequestTimeoutSeconds = *abi.ConvertType(out[4], new(uint32)).(*uint32) + outstruct.DonFee = *abi.ConvertType(out[5], new(*big.Int)).(**big.Int) outstruct.MaxSupportedRequestDataVersion = *abi.ConvertType(out[6], new(uint16)).(*uint16) outstruct.FulfillmentGasPriceOverEstimationBP = *abi.ConvertType(out[7], new(*big.Int)).(**big.Int) + outstruct.FallbackNativePerUnitLink = *abi.ConvertType(out[8], new(*big.Int)).(**big.Int) + outstruct.LinkPriceFeed = *abi.ConvertType(out[9], new(common.Address)).(*common.Address) return *outstruct, err @@ -1011,10 +1013,11 @@ type FunctionsCoordinatorConfigChanged struct { FeedStalenessSeconds uint32 GasOverheadBeforeCallback uint32 GasOverheadAfterCallback uint32 - FallbackNativePerUnitLink *big.Int + RequestTimeoutSeconds uint32 DonFee *big.Int MaxSupportedRequestDataVersion uint16 FulfillmentGasPriceOverEstimationBP *big.Int + FallbackNativePerUnitLink *big.Int Raw types.Log } @@ -2494,12 +2497,14 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseTransmitted(log type GetConfig struct { MaxCallbackGasLimit uint32 FeedStalenessSeconds uint32 - GasOverheadAfterCallback *big.Int - FallbackNativePerUnitLink *big.Int GasOverheadBeforeCallback uint32 - LinkPriceFeed common.Address + GasOverheadAfterCallback uint32 + RequestTimeoutSeconds uint32 + DonFee *big.Int MaxSupportedRequestDataVersion uint16 FulfillmentGasPriceOverEstimationBP *big.Int + FallbackNativePerUnitLink *big.Int + LinkPriceFeed common.Address } type LatestConfigDetails struct { ConfigCount uint32 @@ -2557,7 +2562,7 @@ func (FunctionsCoordinatorBillingStart) Topic() common.Hash { } func (FunctionsCoordinatorConfigChanged) Topic() common.Hash { - return common.HexToHash("0x9136fb3a39fbe82d27ef8048354b8fcc93cf828f72e5c877d8135fde8dc7fd73") + return common.HexToHash("0x3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f") } func (FunctionsCoordinatorConfigSet) Topic() common.Hash { diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index a168583fff8..66d9e0afb70 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../. functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin b549b681bdc14eb3dd40422acf253c07cf58d62088539ecfe42ddb01d48d508a functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 36b045452a98ac0c845d1e23017dd19eac560177a5b51d85ea1bfed314907141 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b5f070d0f0cd78553aa97b0dda9721074e72589818765baeef71622d21a9c6a5 functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 2a8755a8915af6b28efb73e51cc36c8050877800995bd376975b61441c791c45 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index 366605f4918..9614eeb835f 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -14,9 +14,9 @@ var ( nOracleNodes = 4 nClients = 50 requestLenBytes = 1_000 - maxGas = 2_000_000 + maxGas = 1_700_000 maxTotalReportGas = 560_000 - batchSize = 2 + batchSize = 8 ) func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index f7fd1bcc444..33849ebeab1 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -113,7 +113,7 @@ func SetOracleConfig(t *testing.T, owner *bind.TransactOpts, coordinatorContract func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToken *link_token_interface.LinkToken, routerContractAddress common.Address, routerContract *functions_router.FunctionsRouter, clientContracts []deployedClientContract, allowListContract *functions_allow_list.TermsOfServiceAllowList) (subscriptionId uint64) { allowed, err := allowListContract.HasAccess(nilOpts, owner.From, []byte{}) require.NoError(t, err) - if allowed == false { + if !allowed { messageHash, err := allowListContract.GetMessageHash(nilOpts, owner.From, owner.From) require.NoError(t, err) ethMessageHash, err := allowListContract.GetEthSignedMessageHash(nilOpts, messageHash) @@ -121,6 +121,7 @@ func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToke privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) require.NoError(t, err) proof, err := crypto.Sign(ethMessageHash[:], privateKey) + require.NoError(t, err) allowListContract.AcceptTermsOfService(owner, owner.From, owner.From, proof) } @@ -174,6 +175,8 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, require.NoError(t, err) uint32Type, err := abi.NewType("uint32", "uint32", nil) require.NoError(t, err) + uint80Type, err := abi.NewType("uint80", "uint80", nil) + require.NoError(t, err) uint96Type, err := abi.NewType("uint96", "uint96", nil) require.NoError(t, err) uint256Type, err := abi.NewType("uint256", "uint256", nil) @@ -199,15 +202,9 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, // Deploy Router contract routerConfigABI := abi.Arguments{ - { - Type: uint96Type, - }, - { - Type: bytes4Type, - }, - { - Type: uint32ArrType, - }, + {Type: uint96Type}, // adminFee + {Type: bytes4Type}, // handleOracleFulfillmentSelector + {Type: uint32ArrType}, // maxCallbackGasLimits } var adminFee = big.NewInt(0) handleOracleFulfillmentSelectorSlice, err := hex.DecodeString("0ca76175") @@ -224,12 +221,8 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, // Deploy Allow List contract allowListConfigABI := abi.Arguments{ - { - Type: boolType, - }, - { - Type: addressType, - }, + {Type: boolType}, // enabled + {Type: addressType}, // proofSignerPublicKey } var enabled = false // TODO: true privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) @@ -240,55 +233,37 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, allowListAddress, _, allowListContract, err := functions_allow_list.DeployTermsOfServiceAllowList(owner, b, routerAddress, allowListConfig) require.NoError(t, err) - // Deploy Coordinator contract + // Deploy Coordinator contract (matches _updateConfig() in FunctionsBilling.sol) coordinatorConfigABI := abi.Arguments{ - { - Type: uint32Type, - }, - { - Type: uint32Type, - }, - { - Type: uint32Type, - }, - { - Type: uint32Type, - }, - { - Type: int256Type, - }, - { - Type: uint32Type, - }, - { - Type: uint96Type, - }, - { - Type: uint16Type, - }, - { - Type: uint256Type, - }, + {Type: uint32Type}, // maxCallbackGasLimit + {Type: uint32Type}, // feedStalenessSeconds + {Type: uint32Type}, // gasOverheadBeforeCallback + {Type: uint32Type}, // gasOverheadAfterCallback + {Type: uint32Type}, // requestTimeoutSeconds + {Type: uint80Type}, // donFee + {Type: uint16Type}, // maxSupportedRequestDataVersion + {Type: uint256Type}, // fulfillmentGasPriceOverEstimationBP + {Type: int256Type}, // fallbackNativePerUnitLink } var maxCallbackGasLimit = uint32(450_000) var feedStalenessSeconds = uint32(86_400) var gasOverheadBeforeCallback = uint32(325_000) var gasOverheadAfterCallback = uint32(50_000) - var fallbackNativePerUnitLink = big.NewInt(5_000_000_000_000_000) var requestTimeoutSeconds = uint32(300) var donFee = big.NewInt(0) var maxSupportedRequestDataVersion = uint16(1) var fulfillmentGasPriceOverEstimationBP = big.NewInt(6_600) + var fallbackNativePerUnitLink = big.NewInt(5_000_000_000_000_000) coordinatorConfig, err := coordinatorConfigABI.Pack( maxCallbackGasLimit, feedStalenessSeconds, gasOverheadBeforeCallback, gasOverheadAfterCallback, - fallbackNativePerUnitLink, requestTimeoutSeconds, donFee, maxSupportedRequestDataVersion, fulfillmentGasPriceOverEstimationBP, + fallbackNativePerUnitLink, ) require.NoError(t, err) coordinatorAddress, _, coordinatorContract, err := functions_coordinator.DeployFunctionsCoordinator(owner, b, routerAddress, coordinatorConfig, linkEthFeedAddr) diff --git a/core/services/relay/evm/functions/contract_transmitter.go b/core/services/relay/evm/functions/contract_transmitter.go index 97afa67d2b1..ecbe3c49f96 100644 --- a/core/services/relay/evm/functions/contract_transmitter.go +++ b/core/services/relay/evm/functions/contract_transmitter.go @@ -141,14 +141,12 @@ func (oc *contractTransmitter) Transmit(ctx context.Context, reportCtx ocrtypes. } else { return fmt.Errorf("unsupported contract version: %d", oc.contractVersion) } - - oc.lggr.Debugw("FunctionsContractTransmitter: transmitting report", "contractAddress", destinationContract, "txMeta", txMeta) - payload, err := oc.contractABI.Pack("transmit", rawReportCtx, []byte(report), rs, ss, vs) if err != nil { return errors.Wrap(err, "abi.Pack failed") } + oc.lggr.Debugw("FunctionsContractTransmitter: transmitting report", "contractAddress", destinationContract, "txMeta", txMeta, "payloadSize", len(payload)) return errors.Wrap(oc.transmitter.CreateEthTransaction(ctx, destinationContract, payload, txMeta), "failed to send Eth transaction") } From c3ae941bed3c866591588269b143cf511434bc0c Mon Sep 17 00:00:00 2001 From: JonWong203 <82334955+JonWong203@users.noreply.github.com> Date: Mon, 31 Jul 2023 21:26:54 -0400 Subject: [PATCH 047/270] CaptureAutomationCustomTelem Job spec flag (#9977) * getter function * rename * config changes * removed flag from ocr1 configs * test update + config-docs * 1 CONFIG.md 1 line * tests and toml defaults added * default values/variables for testdata/.../validate * rename + embed/testdata flag * toml fixed --- core/config/docs/core.toml | 2 ++ core/config/ocr2_config.go | 1 + core/config/toml/types.go | 4 ++++ core/services/chainlink/config_ocr2.go | 4 ++++ core/services/chainlink/config_ocr2_test.go | 1 + core/services/chainlink/config_test.go | 2 ++ .../chainlink/testdata/config-empty-effective.toml | 1 + core/services/chainlink/testdata/config-full.toml | 1 + .../chainlink/testdata/config-multi-chain-effective.toml | 1 + core/services/job/models.go | 1 + core/web/resolver/config_test.go | 4 ++-- core/web/resolver/testdata/config-empty-effective.toml | 1 + core/web/resolver/testdata/config-full.toml | 1 + .../resolver/testdata/config-multi-chain-effective.toml | 1 + docs/CONFIG.md | 7 +++++++ testdata/scripts/node/validate/default.txtar | 1 + .../node/validate/disk-based-logging-disabled.txtar | 1 + .../scripts/node/validate/disk-based-logging-no-dir.txtar | 1 + testdata/scripts/node/validate/disk-based-logging.txtar | 1 + testdata/scripts/node/validate/invalid.txtar | 1 + testdata/scripts/node/validate/valid.txtar | 1 + 21 files changed, 36 insertions(+), 2 deletions(-) diff --git a/core/config/docs/core.toml b/core/config/docs/core.toml index 39f35047ae0..7253cbd1aad 100644 --- a/core/config/docs/core.toml +++ b/core/config/docs/core.toml @@ -303,6 +303,8 @@ DatabaseTimeout = '10s' # Default KeyBundleID = '7a5f66bbe6594259325bf2b4f5b1a9c900000000000000000000000000000000' # Example # CaptureEATelemetry toggles collecting extra information from External Adaptares CaptureEATelemetry = false # Default +# CaptureAutomationCustomTelemetry toggles collecting automation specific telemetry +CaptureAutomationCustomTelemetry = false # Default # DefaultTransactionQueueDepth controls the queue size for `DropOldestStrategy` in OCR2. Set to 0 to use `SendEvery` strategy instead. DefaultTransactionQueueDepth = 1 # Default # SimulateTransactions enables transaction simulation for OCR2. diff --git a/core/config/ocr2_config.go b/core/config/ocr2_config.go index 6b522ea79eb..a2ea79741b4 100644 --- a/core/config/ocr2_config.go +++ b/core/config/ocr2_config.go @@ -20,4 +20,5 @@ type OCR2 interface { CaptureEATelemetry() bool DefaultTransactionQueueDepth() uint32 SimulateTransactions() bool + CaptureAutomationCustomTelemetry() bool } diff --git a/core/config/toml/types.go b/core/config/toml/types.go index e4dd190d9a5..9ae77def085 100644 --- a/core/config/toml/types.go +++ b/core/config/toml/types.go @@ -791,6 +791,7 @@ type OCR2 struct { DatabaseTimeout *models.Duration KeyBundleID *models.Sha256Hash CaptureEATelemetry *bool + CaptureAutomationCustomTelemetry *bool DefaultTransactionQueueDepth *uint32 SimulateTransactions *bool TraceLogging *bool @@ -824,6 +825,9 @@ func (o *OCR2) setFrom(f *OCR2) { if v := f.CaptureEATelemetry; v != nil { o.CaptureEATelemetry = v } + if v := f.CaptureAutomationCustomTelemetry; v != nil { + o.CaptureAutomationCustomTelemetry = v + } if v := f.DefaultTransactionQueueDepth; v != nil { o.DefaultTransactionQueueDepth = v } diff --git a/core/services/chainlink/config_ocr2.go b/core/services/chainlink/config_ocr2.go index 59df8cb14eb..801abb380d6 100644 --- a/core/services/chainlink/config_ocr2.go +++ b/core/services/chainlink/config_ocr2.go @@ -57,6 +57,10 @@ func (o *ocr2Config) CaptureEATelemetry() bool { return *o.c.CaptureEATelemetry } +func (o *ocr2Config) CaptureAutomationCustomTelemetry() bool { + return *o.c.CaptureAutomationCustomTelemetry +} + func (o *ocr2Config) DefaultTransactionQueueDepth() uint32 { return *o.c.DefaultTransactionQueueDepth } diff --git a/core/services/chainlink/config_ocr2_test.go b/core/services/chainlink/config_ocr2_test.go index 5702c9a89d4..66427489241 100644 --- a/core/services/chainlink/config_ocr2_test.go +++ b/core/services/chainlink/config_ocr2_test.go @@ -38,6 +38,7 @@ func TestOCR2Config(t *testing.T) { require.Equal(t, false, ocr2Cfg.TraceLogging()) require.Equal(t, uint32(1), ocr2Cfg.DefaultTransactionQueueDepth()) require.Equal(t, false, ocr2Cfg.CaptureEATelemetry()) + require.Equal(t, false, ocr2Cfg.CaptureAutomationCustomTelemetry()) keyBundleID, err := ocr2Cfg.KeyBundleID() require.NoError(t, err) diff --git a/core/services/chainlink/config_test.go b/core/services/chainlink/config_test.go index d8bc7c3bdc1..4ce91f4d11c 100644 --- a/core/services/chainlink/config_test.go +++ b/core/services/chainlink/config_test.go @@ -348,6 +348,7 @@ func TestConfig_Marshal(t *testing.T) { DatabaseTimeout: models.MustNewDuration(8 * time.Second), KeyBundleID: ptr(models.MustSha256HashFromHex("7a5f66bbe6594259325bf2b4f5b1a9c9")), CaptureEATelemetry: ptr(false), + CaptureAutomationCustomTelemetry: ptr(false), DefaultTransactionQueueDepth: ptr[uint32](1), SimulateTransactions: ptr(false), TraceLogging: ptr(false), @@ -772,6 +773,7 @@ ContractTransmitterTransmitTimeout = '1m0s' DatabaseTimeout = '8s' KeyBundleID = '7a5f66bbe6594259325bf2b4f5b1a9c900000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/core/services/chainlink/testdata/config-empty-effective.toml b/core/services/chainlink/testdata/config-empty-effective.toml index 65c5511c581..8c3eef53f6a 100644 --- a/core/services/chainlink/testdata/config-empty-effective.toml +++ b/core/services/chainlink/testdata/config-empty-effective.toml @@ -118,6 +118,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/core/services/chainlink/testdata/config-full.toml b/core/services/chainlink/testdata/config-full.toml index 865bd6d7e4b..c269fbfedb8 100644 --- a/core/services/chainlink/testdata/config-full.toml +++ b/core/services/chainlink/testdata/config-full.toml @@ -118,6 +118,7 @@ ContractTransmitterTransmitTimeout = '1m0s' DatabaseTimeout = '8s' KeyBundleID = '7a5f66bbe6594259325bf2b4f5b1a9c900000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/core/services/chainlink/testdata/config-multi-chain-effective.toml b/core/services/chainlink/testdata/config-multi-chain-effective.toml index 73a0d5867a3..cbd5d14f481 100644 --- a/core/services/chainlink/testdata/config-multi-chain-effective.toml +++ b/core/services/chainlink/testdata/config-multi-chain-effective.toml @@ -118,6 +118,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '20s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/core/services/job/models.go b/core/services/job/models.go index d5e72c78514..afab19b3b77 100644 --- a/core/services/job/models.go +++ b/core/services/job/models.go @@ -365,6 +365,7 @@ type OCR2OracleSpec struct { CreatedAt time.Time `toml:"-"` UpdatedAt time.Time `toml:"-"` CaptureEATelemetry bool `toml:"captureEATelemetry"` + CaptureAutomationCustomTelemetry bool `toml:"captureAutomationCustomTelemetry"` } // GetID is a getter function that returns the ID of the spec. diff --git a/core/web/resolver/config_test.go b/core/web/resolver/config_test.go index c86fdb9a759..a04b3fa2484 100644 --- a/core/web/resolver/config_test.go +++ b/core/web/resolver/config_test.go @@ -52,7 +52,7 @@ func TestResolver_ConfigV2(t *testing.T) { authenticated: true, before: func(f *gqlTestFramework) { opts := chainlink.GeneralConfigOpts{ - ConfigStrings: []string{configFull}, + ConfigStrings: []string{configFull}, SecretsStrings: []string{}, } cfg, err := opts.New() @@ -67,7 +67,7 @@ func TestResolver_ConfigV2(t *testing.T) { authenticated: true, before: func(f *gqlTestFramework) { opts := chainlink.GeneralConfigOpts{ - ConfigStrings: []string{configMulti}, + ConfigStrings: []string{configMulti}, SecretsStrings: []string{}, } cfg, err := opts.New() diff --git a/core/web/resolver/testdata/config-empty-effective.toml b/core/web/resolver/testdata/config-empty-effective.toml index 65c5511c581..8c3eef53f6a 100644 --- a/core/web/resolver/testdata/config-empty-effective.toml +++ b/core/web/resolver/testdata/config-empty-effective.toml @@ -118,6 +118,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/core/web/resolver/testdata/config-full.toml b/core/web/resolver/testdata/config-full.toml index c746bcfa900..08ba7e0ee6c 100644 --- a/core/web/resolver/testdata/config-full.toml +++ b/core/web/resolver/testdata/config-full.toml @@ -118,6 +118,7 @@ ContractTransmitterTransmitTimeout = '1m0s' DatabaseTimeout = '8s' KeyBundleID = '7a5f66bbe6594259325bf2b4f5b1a9c900000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/core/web/resolver/testdata/config-multi-chain-effective.toml b/core/web/resolver/testdata/config-multi-chain-effective.toml index 73a0d5867a3..cbd5d14f481 100644 --- a/core/web/resolver/testdata/config-multi-chain-effective.toml +++ b/core/web/resolver/testdata/config-multi-chain-effective.toml @@ -118,6 +118,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '20s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/docs/CONFIG.md b/docs/CONFIG.md index e466473ee68..b7ca09bd3b3 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -730,6 +730,7 @@ ContractTransmitterTransmitTimeout = '10s' # Default DatabaseTimeout = '10s' # Default KeyBundleID = '7a5f66bbe6594259325bf2b4f5b1a9c900000000000000000000000000000000' # Example CaptureEATelemetry = false # Default +CaptureAutomationCustomTelemetry = false # Default DefaultTransactionQueueDepth = 1 # Default SimulateTransactions = false # Default TraceLogging = false # Default @@ -824,6 +825,12 @@ CaptureEATelemetry = false # Default ``` CaptureEATelemetry toggles collecting extra information from External Adaptares +### CaptureAutomationCustomTelemetry +```toml +CaptureAutomationCustomTelemetry = false # Default +``` +CaptureAutomationCustomTelemetry toggles collecting automation specific telemetry + ### DefaultTransactionQueueDepth ```toml DefaultTransactionQueueDepth = 1 # Default diff --git a/testdata/scripts/node/validate/default.txtar b/testdata/scripts/node/validate/default.txtar index 1e105504fc8..8a678e96cb9 100644 --- a/testdata/scripts/node/validate/default.txtar +++ b/testdata/scripts/node/validate/default.txtar @@ -130,6 +130,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/testdata/scripts/node/validate/disk-based-logging-disabled.txtar b/testdata/scripts/node/validate/disk-based-logging-disabled.txtar index f5a736cdf88..1692480a698 100644 --- a/testdata/scripts/node/validate/disk-based-logging-disabled.txtar +++ b/testdata/scripts/node/validate/disk-based-logging-disabled.txtar @@ -174,6 +174,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar b/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar index a0bc7458875..7f6104afeca 100644 --- a/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar +++ b/testdata/scripts/node/validate/disk-based-logging-no-dir.txtar @@ -174,6 +174,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/testdata/scripts/node/validate/disk-based-logging.txtar b/testdata/scripts/node/validate/disk-based-logging.txtar index 4347aadb00c..e5d5151376e 100644 --- a/testdata/scripts/node/validate/disk-based-logging.txtar +++ b/testdata/scripts/node/validate/disk-based-logging.txtar @@ -174,6 +174,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/testdata/scripts/node/validate/invalid.txtar b/testdata/scripts/node/validate/invalid.txtar index 136c697b202..974bb507f9a 100644 --- a/testdata/scripts/node/validate/invalid.txtar +++ b/testdata/scripts/node/validate/invalid.txtar @@ -164,6 +164,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false diff --git a/testdata/scripts/node/validate/valid.txtar b/testdata/scripts/node/validate/valid.txtar index e1b5fb481f1..0fc036a899c 100644 --- a/testdata/scripts/node/validate/valid.txtar +++ b/testdata/scripts/node/validate/valid.txtar @@ -171,6 +171,7 @@ ContractTransmitterTransmitTimeout = '10s' DatabaseTimeout = '10s' KeyBundleID = '0000000000000000000000000000000000000000000000000000000000000000' CaptureEATelemetry = false +CaptureAutomationCustomTelemetry = false DefaultTransactionQueueDepth = 1 SimulateTransactions = false TraceLogging = false From 4b7d846a9011fffe7130f6810394741f16c87a9d Mon Sep 17 00:00:00 2001 From: Sri Kidambi <1702865+kidambisrinivas@users.noreply.github.com> Date: Tue, 1 Aug 2023 14:23:18 +0100 Subject: [PATCH 048/270] VRF V2+ Event Log Test Fix (#10018) * Hardcoded exact gas used causing issues in test, testing against range * Compare specific event log fields while skipping the gas payment field --------- Co-authored-by: Sri Kidambi --- .../test/v0.8/foundry/vrf/VRFV2Plus.t.sol | 32 ++++++++++++++++--- 1 file changed, 28 insertions(+), 4 deletions(-) diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol index 60b8ff8e097..9fd4b02a9fe 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol @@ -10,6 +10,7 @@ import {BlockhashStore} from "../../../../src/v0.8/dev/BlockhashStore.sol"; import {VRFV2PlusConsumerExample} from "../../../../src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol"; import {VRFV2PlusClient} from "../../../../src/v0.8/dev/vrf/libraries/VRFV2PlusClient.sol"; import {console} from "forge-std/console.sol"; +import {VmSafe} from "forge-std/Vm.sol"; /* * USAGE INSTRUCTIONS: @@ -248,10 +249,21 @@ contract VRFV2Plus is BaseTest { extraArgs: VRFV2PlusClient._argsToBytes(VRFV2PlusClient.ExtraArgsV1({nativePayment: true})) }); (, uint96 ethBalanceBefore, , , ) = s_testCoordinator.getSubscription(subId); - vm.expectEmit(true, true, false, true); + uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; - emit RandomWordsFulfilled(requestId, outputSeed, subId, 123150, rc.extraArgs, true); + vm.recordLogs(); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); + VmSafe.Log[] memory entries = vm.getRecordedLogs(); + assertEq(entries[0].topics[1], bytes32(uint256(requestId))); + assertEq(entries[0].topics[2], bytes32(uint256(subId))); + (uint256 loggedOutputSeed, , bytes memory loggedExtraArgs, bool loggedSuccess) = abi.decode( + entries[0].data, + (uint256, uint256, bytes, bool) + ); + assertEq(loggedOutputSeed, outputSeed); + assertEq(loggedExtraArgs, rc.extraArgs); + assertEq(loggedSuccess, true); + (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); @@ -357,10 +369,22 @@ contract VRFV2Plus is BaseTest { extraArgs: VRFV2PlusClient._argsToBytes(VRFV2PlusClient.ExtraArgsV1({nativePayment: false})) }); (uint96 linkBalanceBefore, , , , ) = s_testCoordinator.getSubscription(subId); - vm.expectEmit(true, true, false, true); + uint256 outputSeed = s_testCoordinator.getRandomnessFromProofExternal(proof, rc).randomness; - emit RandomWordsFulfilled(requestId, outputSeed, subId, 292278, rc.extraArgs, true); + vm.recordLogs(); s_testCoordinator.fulfillRandomWords{gas: 1_500_000}(proof, rc); + + VmSafe.Log[] memory entries = vm.getRecordedLogs(); + assertEq(entries[0].topics[1], bytes32(uint256(requestId))); + assertEq(entries[0].topics[2], bytes32(uint256(subId))); + (uint256 loggedOutputSeed, , bytes memory loggedExtraArgs, bool loggedSuccess) = abi.decode( + entries[0].data, + (uint256, uint256, bytes, bool) + ); + assertEq(loggedOutputSeed, outputSeed); + assertEq(loggedExtraArgs, rc.extraArgs); + assertEq(loggedSuccess, true); + (fulfilled, , ) = s_testConsumer.s_requests(requestId); assertEq(fulfilled, true); From 04199b234781cd70a71010887b6c785d28236cf8 Mon Sep 17 00:00:00 2001 From: Augustus <14297860+augustbleeds@users.noreply.github.com> Date: Tue, 1 Aug 2023 10:04:33 -0400 Subject: [PATCH 049/270] BCI-897: Fix Cosmos Integration Tests (#9973) * rename FallbackGasPriceUAtom to FallbackGasPrice * revert config.md formatting * one test passes * update TestTxm_Integration to use uatom * update cosmos packages * update tests * Add Base soak test config (#9860) * Base(Mainnet) + Optimism hotfix * Add soak config * revert ocr config changes * adjust confirmations * bump cl env and ctf * Add patch * Add patch * Update base test config --------- Co-authored-by: simsonraj * bump libocr to c5e49b4195ac49bbf9ea3b122f24b3e19dbb8c4a (#9891) * fix arb min gas bug (#9872) * add admin privilege config (#9902) * update cosmos packages * add await logic * add back go tags * update imports * tools/ci: add install_wasmd script * .github/actions: add initial setup-wasmd action * .github/workflows: add setup-wasmd step to core workflow * update wasmd version * remove comment * remove debugging code * generate new wasmbech32 address * tidy * config docs * tidy * postgres version --------- Co-authored-by: Calvin Wang Co-authored-by: Calvin <78729586+calvwang9@users.noreply.github.com> Co-authored-by: David Cauchi <13139524+davidcauchi@users.noreply.github.com> Co-authored-by: simsonraj Co-authored-by: Jordan Krage Co-authored-by: Ryan Hall Co-authored-by: cfal --- .github/actions/setup-wasmd/action.yml | 22 ++++++++++ .github/workflows/ci-core.yml | 2 + core/chains/cosmos/cosmostxm/main_test.go | 2 +- .../cosmos/cosmostxm/txm_internal_test.go | 8 +++- core/chains/cosmos/cosmostxm/txm_test.go | 41 ++++++++++-------- core/cmd/cosmos_transaction_commands_test.go | 32 +++++++++++--- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/testdata/cosmos/my_first_contract.wasm | Bin 129231 -> 134733 bytes go.mod | 2 +- go.sum | 4 +- integration-tests/go.sum | 2 +- tools/ci/install_wasmd | 14 ++++++ 13 files changed, 102 insertions(+), 33 deletions(-) create mode 100644 .github/actions/setup-wasmd/action.yml create mode 100755 tools/ci/install_wasmd diff --git a/.github/actions/setup-wasmd/action.yml b/.github/actions/setup-wasmd/action.yml new file mode 100644 index 00000000000..46fb84ba3ef --- /dev/null +++ b/.github/actions/setup-wasmd/action.yml @@ -0,0 +1,22 @@ +name: Setup Cosmos wasmd +description: Setup Cosmos wasmd, used for integration tests +runs: + using: composite + steps: + - uses: actions/cache@v3 + id: cache + name: Cache wasmd-build + with: + path: ~/wasmd-build + # this caching works without cloning the repo because the install_wasmd contains + # the commit hash. + key: ${{ runner.os }}-wasmd-cli-${{ hashFiles('./tools/ci/install_wasmd') }} + + - if: ${{ steps.cache.outputs.cache-hit != 'true' }} + name: Install wasmd + shell: bash + run: ./tools/ci/install_wasmd + + - name: Export wasmd path to env + shell: bash + run: echo "PATH=$HOME/wasmd-build/bin:$PATH" >> $GITHUB_ENV diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 29aafcda453..db8533b44ea 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -160,6 +160,8 @@ jobs: uses: ./.github/actions/setup-go - name: Setup Solana uses: ./.github/actions/setup-solana + - name: Setup wasmd + uses: ./.github/actions/setup-wasmd - name: Setup Postgres uses: ./.github/actions/setup-postgres - name: Touching core/web/assets/index.html diff --git a/core/chains/cosmos/cosmostxm/main_test.go b/core/chains/cosmos/cosmostxm/main_test.go index 24f2533e6df..5d01e418927 100644 --- a/core/chains/cosmos/cosmostxm/main_test.go +++ b/core/chains/cosmos/cosmostxm/main_test.go @@ -9,7 +9,7 @@ import ( func TestMain(m *testing.M) { params.InitCosmosSdk( - /* bech32Prefix= */ "cosmos", + /* bech32Prefix= */ "wasm", /* token= */ "atom", ) code := m.Run() diff --git a/core/chains/cosmos/cosmostxm/txm_internal_test.go b/core/chains/cosmos/cosmostxm/txm_internal_test.go index e4bc1eda9ca..5b766d528da 100644 --- a/core/chains/cosmos/cosmostxm/txm_internal_test.go +++ b/core/chains/cosmos/cosmostxm/txm_internal_test.go @@ -61,9 +61,13 @@ func TestTxm(t *testing.T) { require.NoError(t, err) sender2, err := cosmostypes.AccAddressFromBech32(k2.PublicKeyStr()) require.NoError(t, err) - contract, err := cosmostypes.AccAddressFromBech32("cosmos1z94322r480rhye2atp8z7v0wm37pk36ghzkdnd") + k3, err := ks.Cosmos().Create() require.NoError(t, err) - contract2, err := cosmostypes.AccAddressFromBech32("cosmos1pe6e59rzm5upts599wl8hrvh95afy859yrcva8") + contract, err := cosmostypes.AccAddressFromBech32(k3.PublicKeyStr()) + require.NoError(t, err) + k4, err := ks.Cosmos().Create() + require.NoError(t, err) + contract2, err := cosmostypes.AccAddressFromBech32(k4.PublicKeyStr()) require.NoError(t, err) logCfg := pgtest.NewQConfig(true) chainID := cosmostest.RandomChainID() diff --git a/core/chains/cosmos/cosmostxm/txm_test.go b/core/chains/cosmos/cosmostxm/txm_test.go index 3ae1f89b3f1..d13100e06bf 100644 --- a/core/chains/cosmos/cosmostxm/txm_test.go +++ b/core/chains/cosmos/cosmostxm/txm_test.go @@ -1,18 +1,19 @@ -//go:build integration && wasmd +//go:build integration package cosmostxm_test import ( + "fmt" "testing" "time" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" + "github.com/cometbft/cometbft/abci/types" sdk "github.com/cosmos/cosmos-sdk/types" txtypes "github.com/cosmos/cosmos-sdk/types/tx" banktypes "github.com/cosmos/cosmos-sdk/x/bank/types" "github.com/google/uuid" "github.com/onsi/gomega" - "github.com/shopspring/decimal" "github.com/stretchr/testify/require" cosmosclient "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/client" @@ -22,6 +23,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos/cosmostxm" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/cosmostest" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" @@ -33,15 +35,13 @@ import ( ) func TestTxm_Integration(t *testing.T) { - // TODO(BCI-978): cleanup once SetupLocalCosmosNode is updated - chainID := cosmotest.RandomChainID() + chainID := cosmostest.RandomChainID() fallbackGasPrice := sdk.NewDecCoinFromDec("uatom", sdk.MustNewDecFromStr("0.01")) - chain := cosmos.CosmosConfig{ChainID: &chainID, Enabled: ptr(true), Chain: coscfg.Chain{ - FallbackGasPrice: ptr(decimal.RequireFromString("0.01")), - GasLimitMultiplier: ptr(decimal.RequireFromString("1.5")), - }} + cosmosChain := coscfg.Chain{} + cosmosChain.SetDefaults() + chainConfig := cosmos.CosmosConfig{ChainID: &chainID, Enabled: ptr(true), Chain: cosmosChain} cfg, db := heavyweight.FullTestDBNoFixturesV2(t, "cosmos_txm", func(c *chainlink.Config, s *chainlink.Secrets) { - c.Cosmos = cosmos.CosmosConfigs{&chain} + c.Cosmos = cosmos.CosmosConfigs{&chainConfig} }) lggr := logger.TestLogger(t) logCfg := pgtest.NewQConfig(true) @@ -51,12 +51,14 @@ func TestTxm_Integration(t *testing.T) { }), }, lggr) orm := cosmostxm.NewORM(chainID, db, lggr, logCfg) - eb := pg.NewEventBroadcaster(cfg.DatabaseURL(), 0, 0, lggr, uuid.New()) + eb := pg.NewEventBroadcaster(cfg.Database().URL(), 0, 0, lggr, uuid.New()) require.NoError(t, eb.Start(testutils.Context(t))) t.Cleanup(func() { require.NoError(t, eb.Close()) }) ks := keystore.New(db, utils.FastScryptParams, lggr, pgtest.NewQConfig(true)) - accounts, testdir, tendermintURL := cosmosclient.SetupLocalCosmosNode(t, "42") - tc, err := cosmosclient.NewClient("42", tendermintURL, cosmos.DefaultRequestTimeout, lggr) + zeConfig := sdk.GetConfig() + fmt.Println(zeConfig) + accounts, testdir, tendermintURL := cosmosclient.SetupLocalCosmosNode(t, chainID, "uatom") + tc, err := cosmosclient.NewClient(chainID, tendermintURL, cosmos.DefaultRequestTimeout, lggr) require.NoError(t, err) // First create a transmitter key and fund it with 1k uatom @@ -67,13 +69,16 @@ func TestTxm_Integration(t *testing.T) { require.NoError(t, err) an, sn, err := tc.Account(accounts[0].Address) require.NoError(t, err) - _, err = tc.SignAndBroadcast([]sdk.Msg{banktypes.NewMsgSend(accounts[0].Address, transmitterID, sdk.NewCoins(sdk.NewInt64Coin("uatom", 100000)))}, - an, sn, gpe.GasPrices()["uatom"], accounts[0].PrivateKey, txtypes.BroadcastMode_BROADCAST_MODE_BLOCK) + resp, err := tc.SignAndBroadcast([]sdk.Msg{banktypes.NewMsgSend(accounts[0].Address, transmitterID, sdk.NewCoins(sdk.NewInt64Coin("uatom", 100000)))}, + an, sn, gpe.GasPrices()["uatom"], accounts[0].PrivateKey, txtypes.BroadcastMode_BROADCAST_MODE_SYNC) + tx, success := cosmosclient.AwaitTxCommitted(t, tc, resp.TxResponse.TxHash) + require.True(t, success) + require.Equal(t, types.CodeTypeOK, tx.TxResponse.Code) require.NoError(t, err) // TODO: find a way to pull this test artifact from // the chainlink-cosmos repo instead of copying it to cores testdata - contractID := cosmosclient.DeployTestContract(t, tendermintURL, accounts[0], cosmosclient.Account{ + contractID := cosmosclient.DeployTestContract(t, tendermintURL, chainID, "uatom", accounts[0], cosmosclient.Account{ Name: "transmitter", PrivateKey: cosmostxm.NewKeyWrapper(transmitterKey), Address: transmitterID, @@ -81,7 +86,7 @@ func TestTxm_Integration(t *testing.T) { tcFn := func() (cosmosclient.ReaderWriter, error) { return tc, nil } // Start txm - txm := cosmostxm.NewTxm(db, tcFn, *gpe, chainID, &chain, ks.Cosmos(), lggr, pgtest.NewQConfig(true), eb) + txm := cosmostxm.NewTxm(db, tcFn, *gpe, chainID, &chainConfig, ks.Cosmos(), lggr, pgtest.NewQConfig(true), eb) require.NoError(t, txm.Start(testutils.Context(t))) // Change the contract state @@ -100,7 +105,7 @@ func TestTxm_Integration(t *testing.T) { require.NoError(t, err) t.Log("contract value", string(d)) return string(d) == `{"count":5}` - }, 10*time.Second, time.Second).Should(gomega.BeTrue()) + }, 20*time.Second, time.Second).Should(gomega.BeTrue()) // Ensure messages are completed gomega.NewWithT(t).Eventually(func() bool { msgs, err := orm.GetMsgsState(Confirmed, 5) @@ -130,7 +135,7 @@ func TestTxm_Integration(t *testing.T) { require.NoError(t, err) t.Log("errored", len(errored), "succeeded", len(succeeded)) return 2 == len(succeeded) && 2 == len(errored) - }, 10*time.Second, time.Second).Should(gomega.BeTrue()) + }, 20*time.Second, time.Second).Should(gomega.BeTrue()) // Observe the messages have been marked as completed require.NoError(t, txm.Close()) diff --git a/core/cmd/cosmos_transaction_commands_test.go b/core/cmd/cosmos_transaction_commands_test.go index f95f2bdf40a..a736a96050e 100644 --- a/core/cmd/cosmos_transaction_commands_test.go +++ b/core/cmd/cosmos_transaction_commands_test.go @@ -1,9 +1,10 @@ -//go:build integration && wasmd +//go:build integration package cmd_test import ( "flag" + "os" "strconv" "testing" "time" @@ -14,9 +15,13 @@ import ( "github.com/urfave/cli" cosmosclient "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/client" + coscfg "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/config" cosmosdb "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/db" "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/denom" + "github.com/smartcontractkit/chainlink-relay/pkg/utils" + "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/params" + "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos/cosmostxm" "github.com/smartcontractkit/chainlink/v2/core/cmd" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" @@ -27,17 +32,34 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/cosmoskey" ) +func TestMain(m *testing.M) { + params.InitCosmosSdk( + /* bech32Prefix= */ "wasm", + /* token= */ "atom", + ) + code := m.Run() + os.Exit(code) +} + func TestShell_SendCosmosCoins(t *testing.T) { // TODO(BCI-978): cleanup once SetupLocalCosmosNode is updated chainID := cosmostest.RandomChainID() - accounts, _, _ := cosmosclient.SetupLocalCosmosNode(t, chainID) + accounts, _, url := cosmosclient.SetupLocalCosmosNode(t, chainID, "uatom") require.Greater(t, len(accounts), 1) - app := cosmosStartNewApplication(t) + cosmosChain := coscfg.Chain{} + cosmosChain.SetDefaults() + nodes := cosmos.CosmosNodes{ + &coscfg.Node{ + Name: ptr("random"), + TendermintURL: utils.MustParseURL(url), + }, + } + chainConfig := cosmos.CosmosConfig{ChainID: &chainID, Enabled: ptr(true), Chain: cosmosChain, Nodes: nodes} + app := cosmosStartNewApplication(t, &chainConfig) from := accounts[0] to := accounts[1] require.NoError(t, app.GetKeyStore().Cosmos().Add(cosmoskey.Raw(from.PrivateKey.Bytes()).Key())) - chain, err := app.GetChains().Cosmos.Chain(testutils.Context(t), chainID) require.NoError(t, err) @@ -67,7 +89,7 @@ func TestShell_SendCosmosCoins(t *testing.T) { {amount: "30.000001"}, {amount: "1000", expErr: "is too low for this transaction to be executed:"}, {amount: "0", expErr: "amount must be greater than zero:"}, - {amount: "asdf", expErr: "invalid coin: failed to set decimal string:"}, + {amount: "asdf", expErr: "invalid coin: failed to set decimal string"}, } { tt := tt t.Run(tt.amount, func(t *testing.T) { diff --git a/core/scripts/go.mod b/core/scripts/go.mod index ce41a83f334..502d024e7ca 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -296,7 +296,7 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 1b2acc16078..1a06e8fde7e 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1429,8 +1429,8 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b h1:vh4N/K+TMG8oV7L2i4U8q5aMjlVgf5M8TAZJCsXUh4U= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b/go.mod h1:TtLMvOtGV9hwNg59iJj+Sa0vL0Kq3o3eF+6uSIRixDc= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726/go.mod h1:TtLMvOtGV9hwNg59iJj+Sa0vL0Kq3o3eF+6uSIRixDc= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= diff --git a/core/testdata/cosmos/my_first_contract.wasm b/core/testdata/cosmos/my_first_contract.wasm index 60742583752819c23b7e7645d4ec83a56fef74f8..e89b47b39383230cd7e01c218dc3970ac7635767 100644 GIT binary patch literal 134733 zcmeFaf4p7wS?9Zc>|bZ^v(MT21%aew?M<{Nnj@)$38mC#o!d|lu(X%!pqJMLS~9{p zl!ic&&ZTf_Q<_R>siH=UHdASdQ>sz%iX+ZMrM{w~%{XY|h#Hl8qop>ER5K&$eSevIAD6s1YwfkZKcC;v^L@VG6ta2w@t7wu|JQYE_wn7=MbULF`)!XJej8oa49}wLA}V_gZi>f6KX?19yCZMkAM-1{ zTOEYfc-kqt;L6Xj%1?iy3cRS@bNAhMN6C*SkNmyz_Ri+P(gU8+KoN$MrYg zbi?)3x8_#ZGb+6EmYd$rn}5GEid56f-uSL}Tz^aXtasbax9|GqZ`nHYnrrXax%;Mn z_ipcG?eOvLoo{C(yRY5#uD8wXe0S7SOJh54_~vi;F_q(rs`;FJ%bPMC1P5vqFBxxsIk){d%>RjsedXxKl3N1AFPb87V z^=30kV(4RKiwE=nOH?_D5~i9qx%zMYtu^Y+babR%PurvIc3O{W6sjjFz-~}X|Ebr; zs-&JIb!tYfR#$!2l19>PBqJ)(jB5U$73ZD(XM>1UBBHf4jZ+Odj?yt*qo^6LUZdYp z8jUq$Dvh6UW?ZX@#>dyHKpMwq)#~xC_+9U+r*X8RaaMXyoX^f4jym^5`7^V>V%Ouk zHa`%z8}Hcpj(6^UcM^4Oy5+XpufOH?n}qZWn>+8^`Sy2l_qw_PH@c{G{mnPO^X+>1 zj`j^Z%OAI_*uC@Ccipsm=WW+QZM(0({hhm`+g9Cl3-|x-`nT^C&ThNuowr#yB;%MEGVx%S!{cV55i+P7VQ+s-r@`6O7#kH(w7`6uFsiKNwU zj>a9k8;s~uyI3!>kzUVVkMJ@Z$>Zrkb8FJlvnU&x&Np8eMV&0pqYI;2*2rtq12vvC zy>_#x-L$58KAjJ!K~v4Lsno`kHD@lf9-CR(Tj6~UYh?*f?@P|6VoD=n40LCm&E)YF zUN=t`*3CcueDu1|XELq9xANXJE!DDm?;|l_XiX%&9W)T-(bgmq99ns6nm_B+{vhUI zMy*ZB>Op&38c}X^Icyto@@k;ay0QSW!+sMGr_e<)?M z`JFgU!feuFHuRS;pUW!qVVI|%Pr`hdxaPwMH6OYh&L<7?fh3qu>hno8A7)?9hkEno zlP)nIfK{1K>ht+%7j~$L9S+4agGRv*En&&|0eT4hpgZ`1i}6Ft_`zPo5Bw^Lm}d+5 zp*5EuTABF4YD3vpqu>W#l}*jz2VNLI%&S%ML#x6M>Q2LG27XYZ;)i*43x2TI#t)5r zHiq1L`(vY3czZS$=``}a@$_UA^~3XgEo?K9?1=}htX{h(tLOFG`}Hi|(T^!h8+mPa zeyb@Kq_=e2kkGswDxV`X5pPBB z5Q&Js6q>v$hvHIpCa+8I=|uxX`;^LBgCze1K$(c5tx*Iw*QWEI3ZRswi0|5ZWMt)M*c>m$3_c!rW)bC`qO=;901tYC# z-L>Jo2jDzJBZGSN)?^>T1gs@@XYHxk+3dTRQIc<&&PJ!AslWZ%W54p_KmN;4{op;l zeF={TUGX`KvQ(eL+7Th*5`KSS~-# zw756M;iw+UciILeNddl{Jx;?grRHrPyi|f}HNxo77$yCVKV5<$qP7r#v zqBerdY9KDmR!aeJ(UeA$)n@X<#ZE1kt)_wWhqW+ZzWlyY%*1&zo&P<*(Ic|_)LL2$ zEGR4*43eidlsv-*hmwcaCV4wX zx)t-Tp4DaEHRqdm%_@@WNF{Leg(R*8gQ!_xs6NCH-L?7+VMupUl>tL_RBX>4_FKHf zS_G^OVTck~nDa1HFBL;WYN?(HzuvetZ8$Xy@v3YpSPu=erg>r3!@OFh^-vd`6k`a; zXar=aQK^A>bqi$JYePm;I6(3Ceoz9dxd7Nr0lQfRb~9@V*tPkh!wz!fa!ezwJjqB$bJaI?kCB1{mW7r3weAiR!m;&$Hp#`(Ff!F zAEGz$Xe>Okmg3%CwIUNJ?%m7nWV9#l%ltegp(P7s(4~2Ax@i8+(0bBOLhJ9wNQF~w z?Vmx_6K)J)N940G0Cv$TZcoP3{WG~f&2>H3zvcR>)P_84-R|yT5{bmupq6iD$h7>A z8hUm{H_1onbF7nf^4Ys@?I(FETjUI;)#G^=4dfF-4RiY;o6s(e7E#IEs3Ftdn;r-n zRP*M$qxmYD7)1c&Cn~jXEFqZypt7_O&uM|q zC4XV5-hI3?>@d!YyM{U%AJs!p2}2kvkz35JV=BAJT~kg#6JgPt?kCv(vNIV8Z{&em zu|x_wp(M(=iE{2_qj~ENo{a41VxLoHbi9+T*uj%De-sKbuwapGLoB9Qx+y(^NzKq( zJG!IRwbSS_MZq9Jgzm^_Tg2>Cxepc|&QSE1=FeMi4m?@t>J5-?OP&*;a8ysY@DM{o z*f8$|j|3kn*)Ukxx;oesK3I$tgL9+X5^*$kV1A_e0TT=b<>3Z_Q7|@IVr;a)*r+fzTE!TsVh%zT=!@hD5(kR7 zTRkm$)13?-zr)CZ=JZTq6uT4A)p*e5mzt;`<(_~Pgo62B0bOV5F@y(~*fh-0I2sc( z;dhWB-T3UR);~+`)S`tueIS${0(UkZN0?$YJUz(M6?Usg#KTe_bWtL$Hd>!E$^}w7 z45M9)`glcRUWddKeN9H!=YJSfPFvFsViGTcTUR#MIBQ+q*9gSQkj-I+J=NNlKCa=* zxrwFU;(j}Ci6JMWD@~vyH729CfMC-*4eFz8`zxhUN)aEl#~(#v>4xM!wz4{^b>qC* zCnSuJbd7;qWF4v1OM=X&B;w6V@$}MCdE_*R%+~8wyoSKj9B<3U8TFA&lhO84ZL~)* zczBYR`q!R>ZZYT!#d{I0Y%!&K!C*{NMy9LcmU1*Lx^&b`Mz87DdEOu4QEMvdpQCv% z`45fCKk3!_VtRE%52ag0OQWV)>uA<`C+`vF(K|?O%;7XK&7CXO2@T8@>!v;gQ?xy} zn6`RBtwv|(t2#_%l##Dd>y89zjn#r%Hf%2|VV2lL^?owy4^=G>!YCw>#)7JS9?}p! zo{REZ79z%$(@*2pJRT6V*3-Rd!rM@+pb-PgJA80bgF)InzHS8)N&D{eNHN!&Q2$u$CC16hKOVW%((}&vkd|P*L7Qy zlfs$O-~}Sk;EX~>3G;j+_T`K;e;jjtC7uXo%y@`|TSSftMcGQ%qCk^4I4T#jQPF(N zA(=$nnW3bh>+I}oc4?ks%L4N?AZ|QIN3PArvo+XK3W|?sD~*&a$UiQHK#+gj+8jsC z667Dpr^IOFVnP0uu4Od_)64P*Xw`xc$uP*DXrPR&5)>at`fLPE6UpOof2FR6V_A_a z8EF0XX=Vb%H5m{SaXDvOsyE&%QP5*}y}C4aRTAXzgqRoF{!DGXd_i zq0ujvC1mdm!Se(o6zxb<2x}6|4(hxOfqd%<`h!dd$(zi1F#2R}Ps9`(wE}QFo>d?M zEUWKh_+}&)qCgM{@G$$4`ISRZ%=)y>ODwLBt^X0al_lKiH*kDveIu_!2z0ZE-NrPN z*lkR+iH*7+jum)J8K1L;Omi?9IVR24S&Ih^E-DbyLyc@M`COgZ`J+G+<57hz%%Q4hq^XLlQq4(=tjCP~E zIc@fUgn#1jg$JlAF}9SNxEb*k^v^w$}KS+cnt65JgZWJKZ)PG0!wJQhCZmn`AXXXt z7t_%55r1uJTKZJ3jKLRvu4f~{WgP(*jdE#ijfh!iHRXKZQ%WM$K`<^v?+$D}4NZaa zfVrAvvn04jSP{)7M&<4YG#aiHbhO1U$r>XZR=KpGs=SNqC<=c$J%zjr&uAbPnv`C$ zkanfvqXlyK@fMs;brk5zom^aRUR^F6%WY*umkjDc0Z+G6+u0#!xfr_!)k?ABEQ=Ax z4KoQ#-Et`Pk0}e=O~-aK1Zx`>tWD+R)#Oszx)aFl^;7v4bzwh2UU27KUtj~bQM|Tq zX!2HZC*yn-4y9VYcpcSYv0CXzrp^U;&P798)R6h-HAu_xZgx<^4pM^h^FjiG9?=8oOsJ5zl*8r|oV$GbZyZpNtqmt(o!le;AF8}F(K0n`HO zVL9B_#?U`lcEav1NL(UG#MBaYEf2?_&gjlmOVc zYj1$cfsht>OOR|*Qp{u|kKNRG0loxi;FCo%Nh8J83rfYG@bO!`PtRW_eG)l~aw%@_ z$Jh!6TS`O{kO_mqvM}<;z&38$2Y5!g^`s*weuTqP4PiNkhA{Kyjotvgkh|=0*@1XX zVX&n-K!O3GebNFAx!Nr8-{DIufvdq)l*Oh9uxAh+WHU&3;QUK?ATfn+X$PY5L3ktz zM!y{8|LA@H8kPTNs@Zp*^I)pCs`^Ej6(uY^7#H%&Y?1qo6niYK!i-w^x24NIPd&}W z^SxM7gFzESomijXhun-fkG_3?!&}dYZ1i4F5rwWX-00vwXdmd8YtkhL8e$Z#HCm-S z2=n-@9?Y*|I)8aG33P}^gP>Oo-C6X)LkxP#Ugj=vOHwpCcs9}nT(?R8)wGSIEgS%lRUn-n+jCik(Q!x z9@>2xOEy$U^8TA?r-n3~PtS)YC^)Kk~SvKu^tdKH$ZeXbJ3~g4uf3117hq2Cyk`<)Id}fLV^|abfgo zo|B1@W8MpcNFgG@+`Jl-ofah~FxmC`8aMVY=hyyy;`d9e-~|-Cnr9PALBfxS@D_Xc z8iZbUL+Jli53$iHJdtc>a59L@wXsoNGF*6e+Qyr;JRj7MtQk~40_pEVTIY5g)s2zU z2BQ;=!EB0)(jCkuuMB^-0kgq(P?%UR5wmI4k|DRUn!FFetOu=f3F%TyrQUmg3;`Nb z8Z>MT#qY!+5}Hb=+J=|ID~Bs4smK7UiQfVkclqi|Ws&-0GfoK^*_3NoJR76&BFmG3 ziqQ&Jr-nT;&(ry>^ON=W)NKtuEv#Tdmn5HPUbY6WP-6olMoXOm!n)cOb@f_p;t zWc1#oTmcB{YHBBOE0{JzHTPx|6JVc~o>HTzBL???UVTDjcbU|Kd^bYWL57sO`S)!nkI2g~j(v+Qb$ z(~jF>L7dkVg*ppb=(+LH@>!i=3L3nIe8Pqddb$5g#wqD6121;FjEX#9oxj^-QKjaA zvg4Kd$BQY~!ju&1M`Rqd!i6 zOjnD~1q|SDmg1Z2C?L6Civ)4Lr&x3c066`!Xyg2Yde~v*04r6Tppu)SXzI`Z_!ocT zk)JyDGtWnF?M49GRuocWmBMhQ$N8N!=62!%t~p%@(v3wrfCTcigEeBA)@G>EIuJG@ zJj+qlfwG{G-Ggz1{rbG7VDb8~v~Fwq_Ow5a)m*b=3WUWdtIkd|4{D;Vo-I5aRT2ZH zU7A0WSOi2F9>@Ha2!sK7)EBBnZvk*xdN=@Ptf&h@39wD+QG);bEsems0(Hfb14xqI zm(@efCS+6@PcqDmZvGrUp15y-i^}3j@T^py~h8fR!Tb)};Wlo5)vaK%Cw&a-W z=7^Dw#VaRSR2}B=V4MVkS4gE*EUGdjt((&H)dLA8sE=%i;2OfDQNL^S3nlUNE$|am zqCjPLD(Ywae{K*7!NDsA%hjJqG?)tka?Hgy&Se6Y6e95;!X?^Ijt;3@zLMzgSV?TS zaF8>q(P<2qXsRw7E_GvCqM@FLr9_iFU0+HZ%bG9|%-=NPruqJutyajFE!smVh5V;6 zo2gbav;-SmK&udjfoP1CY_P3?SbY(5(Xky`f2^>bT2uD*u+QHP`Co5u0eOh+UvQ=@OO+qc%Hh!`TnMNt6 zh7^+KFW9h-ic3vcOJXEbjsdmN{{hbEQ%2*=HljxctTMZA#*Z%t+*{FKvMIJ z1{{aKS8-yQU&fRaM<}4l;BmVbVVIOf!2@DDmGt{lasOPS3ZuQudqnUUxh?^bQtA>s zGC65M{b9xh_8Xj)cl)tRKtbs>gLXbSGghldkvz0^{+b!dp?u_0gPpB%2sn&Kl5~R> z!VFk#qNtyq`set4{S7!QvetS2VJoM06`I+hMdit86R6s9DPrWcm+j_B05x{*hQiTe z&TIP{#Ao#JRve@a{G*b0aMxhN)pC#|-p`BP5BW_-A0V(#P!t?GZ|WJ+ZH1#iunmm7 z))SNryv}XLbt^86o(|M|RM*<;qTjQtMJ_&<*m|FUz7KcB_?P>=>7d|ZCxAtHSrn~> zpH1nBq<=1uVKnHn`;2~E|6i?*5O~q(6s1}9wMoOOHfd_WdzKPa@RYF{Jq-CCGuyd5%GTj{&|Fml zEZ}-uOLeZt6fWe=;#@EDWg>YYtf4Y$i)}xj^vwdpu`JZy3L&^$9yQ#a4r}sU+u>fc%0?fdQ4dSh$mV&W#u;LyZM5zXq-^6imitz!(PsaIQTLgUQ81&m{ z*JgeY4;n|HvQLZk{y0l6TSqDYPow^tWILSNl+a=+6^m0G6=y3YUD-&bSS_96!pWO|(PYAwSJCri^brLx%>Z0U$7|;J zf&ujIM$9+$R!Zz)vXSGEkI-CCNytssK|-wG-UBJU@9`cJtnEW(!HQcq{Px<2r1+Jh zKFlJ+tCKQXr51sb?8}S0U26!Ux1==MtsYfLj) zU+$zC#30BBx-*x!Ls+D_dtj5y6ZOkpOLFkCHD)54Umv<#EB0N(3X>ZI;c3N1gR#sR z3l@`4x8hud47oG2wbd+>wPipB{zMj39jkWLv6Aq}5nB9R#0v9oq>T#MK!cx1$X;R=YNsMyP-g7-kNLPxYWGFC$U@rOo=~mH)EeaLI`Gx3j3n<W#A~Hd9N`gQCGFab!=x{XO*CXOIx-Y77VzQGZ%F29L0_AI7r4puB50me>uxeq zv*unGR8>v54R+sQMp5YZ!#)pSIvM>69R_k)+)<7*Im(0xhK_RVMhv-pWs{E=Q}JMB zJ*b6WETyH@31gA?D12qYYG#H&wkR7DGUh9z-o{*7YNwGI;PREBp)u&LDQQ{De^Ju1 z8KmVH)K|Qgw5-p2%`At$ss|O|D|#OjX%O;q5`Z5oKC8)1^s(e7Ass+wax-*HNC#tE ze$J>Rax$@^(^7a^K*qv{1h-5p3?o~zSC`{U_n;hH6}cDUjmt?}Y|W~)4esHrIj$y5 zmy@<2+oi1>(<(z~`aT-7JHg$8IaQ07SzQI;{fwv^qB|sNDSV41V8b9h%bUFw_>wX+ zC0-!Rtv#d-WxW53nNw<{h$%bE6}K| zWFx_p29rfH>q&u9xMm9%K)jg?5T4+&a%-|Ni*j@e;yt;TeCLd(=PJE6%Fa-FZKSvl zt32`=T3m1%wE9DEDDu2bD9CUJ1sU#0q#fdJAw}WAoB@T=Y~jENU;%!D&wSuPHv1EE zVB`*Z7xNsKBseahfH{9m3s*m-WIlx_Kw57d5729w@c%%nRkZillKMS~7L(>I8^eEU6wl(mTnQ~85?}ah?X71#^$iV z>UUv*6`y3dz^WuwEjtQjzMokLTk8v~=9)hGVQj0Z9(&VuMY7#D`j{Htw)A2eWQ@=aO;%&D-a8lq)av>qy5iYsQ%G^+#R zKi&ajIhZlV(2v+rJ-A0;&O&b=pZ8Y3hA{O)vT*e4~QYLPOJ&lePg(Us1iT;^NgiC zYW;^^S^r_f;c7X7Nq*51ug{km4U_Vk!TC8cF^M0v-`k*(BO7Bc1MJ=iL2@byTfYIP zYycErF+xURqXNvf`CMLhF!@$xRKMz3fv;}=$3&j?6dtJeAjRR}~I_k{T;jXh2K!_dO5imr&fWvDL0Z5>m zr!mPIWN;|`afi}qL@G+|Qxn*ox^0*bWijH8Fh{&5U=D@@E_x{PlaO?uKVRUj24 zL6ScK&FiECUO1_6!~uB&kJ%PZLol25UmAkF!fDX+mq*C>a?G;0ZQ5Ylhj>51? zFB?DxSceC;reT@x>NCXVlZ^i_U59F78@(cKOHQsN*f8Kia+sTJf3tE-*g!IYqoB=BXKh;bknSFuY#g7(Uj7y}63oeWv=9#ms?V~P)_yL&m zCsnJRjfj3*`KVguq$eLF*C6gy@)NU^WI4vdnZ1>v3@wYf_3Hrlll0a5fmjP>UbmM2 zhk4@~dr{*Gz0Da{=u?rCB|0VPRI6Gq7fTOls14II5v7I_*gkq^PeoZXtOwEwq5l zg4z$nyU#ILA>Nk(k)#wk3P2KhOOrUlU@OSvKdF;WuOweA!WTilpHZ!@G1DRxyd{@2dIHa!?T7^40#uBR*{p6^8s{4URnoE(@G31MBK^howhq z28;`hKUW*g7dJsw`^rwR99WV|;{25cryU!1+*yxplG6Cgf@p3F2Ake0uc!6UrD383 z@j&jUtlJVMS|MM$9&08=y${PKevz`ohcS{!)VU}(o ziitHW4IAt#x1AP~X|kTq4pv#PF}ijj&hlaq+kEK`D?)IgVJ{(QfKyVkL48+Ilr&0YWpn8cM1%T0Y=_)yr_I}8cP@NOVvSE|^N0i*- z{{sIpSTB&|`{C~Q8M^@AOiK|3cbl42n^uUot(k&>3C30HFHf1agQjdJ|2}mlS?On5 zwmjLtv~;wyJdlMvA3|Pc#TYMWT{sy3B8~`3k>(hzAdtg`Pbm+3+{jjFuMMQMEP*cl z5+7yhm-rz|z7#zX@i`oOU zEC#c98&#^hd_T6{o26rG1C@5PDpiQ1 z2j-Ya%&2tc#B(_0ubfxYDm?g+MZKDbAWRbLwxKuddMGzbq-y=>4z~waSN&o9NI(qg%<8TK+S7*wjO#Du4KBQ8IwlK(E-r zQu@y<%|q6p9m5GX9@1GLil-1qVHt~M1l?z2+OVG!17{h4WvXx#C*`m1j)ajWN?8q& zD6Y2uzn8h}wUI0x(PA7iVi?qtXcC8wP#EA7$#%jjh{HDq3Bd+Gai^5tOAfkK*l(e7 zmNj7J!YdFnvy*(qJUYo&W39#!>iOS+rJxo`MxD<87r)Q*lYFhxD;`3V+Ny@oAig9Q z)`2eu2No1TH0AlMC5ARXc-9z3%!mmpV#dX64QK&dLk~4SejycQX?W;xXlaNx>!lwm zC0ZDstm<*EL2PBeYDq?9)a0KPDH9YEx9iwRuBEah7b$ol%Drj2MaXp_#mU`Wl=g9W z&EO6yNu5td`{L4{<$M#-eiKq8WY=1X_+b_c=viD(rj$%34^_B~rQUVlG zHgYpV%MRL~7ZeQjLUeXmFXp@ihBplDa!`2ca=uBFCs3WjilK#PfAzoK*N`EmI3wfK z`ivtgE+tqzjL^a=Rue>&5{%b|UJbT1l1!$XSQ4lgs?!8O69{+XCRNPZeH>x^a6AC) zI@=?JrJl6C9(HV_o|~t&TpZjmNV01!FND_??M`0BUF9_2VIEL ziXF`y3~grC;W(>ot(2KnP7q5Pn@LUtIb$osDvx0^obP(# zSp@W=WPXin2YJ%O9RV=f%>I?SG8(phWeN2*e*E%GTXpVvDwP|FSBoKii4>bfY+;S_`<^ax2&^_@0REhvZCe zNjWYCe0I75d_B|=Q{f{ZtYU}niG(IjlwYz<)zm1QS-Pb@?CiJ1A7E6k5|aO{}LN@$^ov=DY?AiD$1( z;?->bQ6qd*0rEjMhV;2$v(}BO^q~U1y9&NYQK=FyQmJYQn`s9NQPz|eqEgf<6V+w~ zqn)}gfvg1^J=7ASk})e}9TpG~&o-u5YE`2_tCGRT=`#8b0e1{STV%ad&AzJe7eFPq zNuYdBML_L9Lltq=l>N)p6^H@z(5E_gel;DKhAAQ*xD#bthX!yG~V< z-Z_>-8kHXxbeRV8*Cuxoli4-o)+9M%Lu-<9Ygw&#c9Gifp2Eggu@Lr=#Y`_UD{z@{ zAT?{~Nd7Dw<$4Ll@Ro&jNWz~E;7$#3{eCdR-&W8*xlggMtFFL}rFPbMVYi}u8#Il1iYZ23qE{3twNCV3Yepg>%KftNTcH zbfNLDa)9Cx@8{j9IN@fo0!aqN@p}>&Iz}Oxx|iJ4<1Fyfd2tXgQ6AwgG+{84qg4LR z^qxqT)`bPr3H|1y7{zZ$I;=O0cMJ@}uLEg{`t=8Kc^W>aTbM{w+RJG^b|ebYp@@v; zW}LM+|NZ~?d*5(rp71>xp%S0~ThWe-L!WNtOF@aK*1mkCBZ!pP@D=#-(Su~zi6?bx zSBjpqZDVo%DRxar)UBx7bT#GTpNQ}RJO4Z1U_^s)8fVee$3V?Vw%IC;3$Bs4vcuxy z{LJb6qaUbfq8?jrtH04q`>Mb9ls{~zmz{LLS>Eb+yKlwEwk^(HEKUK^Nwdm})CoYv z&RKur^?gr*kRP_sZbs^+5Qdta7!+qyWvCvdu_k@MPhKsQN|Sx?C#BSn(-IB^Ji>Lj zSGGJ3%TKc>hQr2*L}&HXZKo_Jzp7c5OW5aNI~cWiNtrsLdHd9r6+3+fW+qDyJA-qyJD?E=yFzmVzDb$2Ot0qdt?r*t7`1? zjo^x5O+8VaxKc-F3R_xm@P4Ef?O*`uf3~0in%(3@^OWOA?BM!FIJn+7#cSVi*vw&J z@ib@3MW4Q#)efAoneO4(Mpm^HKKF8A?3Hq&nSJJO^jTcU@v{-hgytMxgr&(y$6&DI zIl|tys|CJr*!&G5I*xgANb6W^cC+!pEbV5qt*r7$tXVuP$t&$?OJ~tm*9>>SG|N2} zL)5Sx)oS|Kq&<8$95u-sRcih&X?L=tDHcvt+ofUIkiA!SX;gdNrA`SzarCQZ&9t!3 z3e?zUREES>F|?XNi)O!0lbbE}TN(+C<}t~!ma)9d+_b2YFY{h&HWk2r(9jhCYxj!+ zmUx{2TU6HY1GTNyi0rVIwrg6nQ_#8SlW?3nS*(&`g*#hJvPkp>_{u~sh=u7}(ltj# zK^ewIC0RIFta#Tq1>2EQ3(9Ghwx7cgXaKQMr50+mVOiSpH4adQTJZb`q=c{_I-|U8 ziLa~yw~}!$A#JA&dDDJWr!|f8k-*0|3kPwEOz?a;1vP8~45y%KOd@lU0Z7s2%vfbORSUxsD4RaF&f)y&5=5tmn#fhLUswCLd>@`-$WtUHxMVB+#0N`*YP# z1o?qdnIyMBuYYo&vw@Q3O^YHpi}Md%aK?&SorPSOG}{B&FYg%ri7lxT)@H39|L zKBQXMhvbJ(Wq<)vlVNWM_@$3(LsCP@=vm_thPUBe+8ySl3WB7tyr$4K4M&#%YG6*R z?b|Mf2IiH=N@EP0l8tVe%NoOA1%F2WwooRm6fJS4B>-IFl^|>14Em)8S6HWZ8APwymR_Ky_1!`)msohrNI^3;Dpk4kf^Dcns;}knl@A=2K(XQV`l_`SX6dq! z$upQ8?vO$ojMzC;syv}%7@?9)$@)G+;Tu~07`jG&SQ#A($Vck1O8n3^|9n}=8^JXu zAW$6;2Wy#YoargHOE8^jd_Ccg;4MpFtzOYoinJRtu2uvNmv|30VV>dxwv8g-R7)uD zAMB((mJ`fF7cIZkMIJlsK;zj*hfz zphRV0=MN4k(JK8*S8(hQ>n83B`zPF6!FPyW7c=N7*1x&rcp&v&?mv3rBF?1Nu;CLI>guUl-=kOqHh<$23J?zkFtH1 zODBKeKl7=;-^VxRSNk$O6x~dc!qUlk#)thNZ4WDoOa_U4tW9ovy|)Lp5H(A@iV)fO zq}sgE=a1PT?P8Xqgi%;_gO@k@ru?Gg-=pJv_LpG)^*)k6-~qgX!1Qe+)`pnHvOpRh zi}#R~eXDS_LRJy1j~=uT4>`8gkd@NqiCC?mh(^dCP}BS8xYG$w;@*2Y|JG0LCbiv6 zl#FpRK}i#ZJ``Y}i^R;15TMX+k9Hu1@cwapInA3pVo!e@bG2SS--?@ZC)M?!4hFQv zME5cGA|T7@Z>Ic!=di-ct&y-P3jxZIZkU%vhP0gnRH{KKWR8#`I(#YU zFkE{|P!ZCrqL@hCOKPxzn^2;UDQOanSVk;+g+&3ZYHQ4lSafgi^yMv0Lv$}z%wjejTer0FA88r$pbA~elM_<%!p`uQ2VM~$VUW~5_m_Vp> zgKbi{0>z9fgkSW#{P-#a0;Fvcq96^ZfL6hbKx?f-3o2DeQWi~MCJ2dF#D9VW5fe$4 zseC8pkkd8%UI6#brxa|ip2$)WA41L;et(>F(ptUIY>mj(U~D{BBCl|!6oRtH5$i#b zyz-IO3To3zD=8l}{gHX)ChWA2)k-0c%2IWIgclYbIkotipMhE=LWEwi<#MG`F9kO) zS4t6k+JaEaK?uIJX>ETpFpe2W5l+1=1hhJzO$e*Ig@RUaFhV=Cv5wbGq?ferFxz`G zcoHqY;a1-9*I_60 zmCwMGKSKmaD~96_qZTLdLb@L)G7pr#yXzYx0Qz0?wJgSf1TeR`hQR9KZ!;9u4}UAf;i^*x5K!Ng==-r^ zK9f1NsVK&aL6!nccij1)?1bP3Ne+A+MdUAt2Ae}jfG7FwHi`WveL?c1Tm)f7P>Uo6 zT3bI)l(VKBhH~^5C}L0OLYA2CH#^TnAk$=f%juG{teJ0 z;EtPS{O~Z*Sjx)=dKgp4cR^`&j+ggOV?*nN3Xh zzDX2)NWm>unH~oae0e*`4>G)y`tj7gfaU~7?2bT^E|gy`HGV3lnPhv0l~9Or@N3q* zynQ<-1DP`5GaXs1gly#vOTf9^jL4PGjdKVQ_P*6D7EMHAkh%9>-!W1&8WgoD;$_rm z)unEV6(HUa{WFTHJhNizP_;V$m^g>e%4@*$W!XtW5vx;YPANdJ8k~PLRMc}vbv~of?v>wY4wTWw{Sdfg>T^)S=He$_XLLD zyU|Cnhg4O^2=q_B*pM_o+PAOs)bry;#9>G*0c&IzF&;?m0vnbn$_J?Pyct;-ss_hU zFY%#j;Kfk4&y;6p4~H59V}`nY;ZRAo_OaS}(_D(H>+=-zDDE#sD=4f*!Ot*&x=(R9 z?P9V=tMJ!)Hv!+Tz+_ob3LLZ8_)iZACINrr&i!(zww;c3ED9_*?cDH$V6 zR+%UIBOG+Q9KbYO|Mv=m&Y-}#-1T^5WF)fHq5o%J3BwUz7e1~hT5}}Vw1}kZGzlGS z8USfc)a&&KAlLFr6LzY1Egv=^b1;1P!J06vEDlMtTMd$!tII>ukc%9R^CyJv1ay~p zqeG>D8T#-Vgg)U&R?>2%18V-{>ywopZ9m`#*7rV*?PQ;yiF#zeD2NWl>W)1<2yNXR zB-DarzjI&*;LXOp^#%Uys)GRa|Dyj?@d(GbXelDaO4T~$q2Xa=mN(6^=kSSEE)Q~^ z?cO%`@1N&&>195MS4I<9F z`a(#WANSQ)twnj_dcVsp8Qlm#76ZyJhU?VwqyE%B5c*VX2Y+#R%K&iO(TVm2<^!>( z7hw8C2!%Ytlx0zEyB5_ju(a;1P0ZFYe-97ms!nOdrw#2eR~=^D$P0F+@-t2bU$k6avq!Ju=2fc(uQP4J^T={ zhOL8;)c7FsL;xdh z0ZCdB#$6|~!EVE64<qrupR|uc7d}ihAocw3F z=&J}DAbb|0=Om;rJeKqgnTNu$j*se?N|1XnadDj@Q|ypWWQJ_dda)KPsVpuO4$xsy z{+L)b?rnut#R@#J3e9Q-xY#R5^i(SF6e)6o*LL({Q!b)LaU#|zw8skRVT@R`X2}Hy zl_DU!L48KI)!{ zfF$w`R)Gh#d>-!v*e?Om;%I6E-@V zQCZT6cH2wWly3ibzArpGWFHKPzWO4EY?tj+DQi<=3O-FQfq_(7pw0O5^h6Q00j}pb^qM zIIUGDtf|#K+Tb#|a+zttS0A{I6N*8^%xQN@mLA zy7KNI?+)u8oIRi{1kQo80|3tmM{JWyV+T$1g*ZD`oMw+x-qc>#LbHIUufuWMxFW~# z1S32_a~Ve=%9ADuPa$Y(`pyx{K8#GZPSAx`Pz$%wrj)cLsmtROCQw`JgIAdYqvD{s z|8kCxA%zun1?tb7&R@WuoQP~&wt^-3m-)TPcYs>@{1>agKVSaHaq>J9mONto_I%I% z<@!6G2R}lik+8%eql7j{f}Y`sO_J0JE^UVx82Uu=Mr{?=t$1xx84yqMQ$-`8JogWk zFxYi$`Lc>)`ttRCiX`YHw|aQZ#G?FZ3F7>z3ap|{$s4yNPnnpcE4|mIql~11CvB$} zKac3-5~2bIBTFAzwk2~emgxy9k1Rti(ig@{tbwjW%1{%}MT&-yqhbA2N-$8{&&{A7 z6RNl#D%Q{elh*uGf4@7pr38JoV+Y!%og_pYsy) z?-%I0Ds(&N;n`4WR;ONR)m|xZF(&{NB2>mxzPIE!>zN!qoq#xz=m=@U0ge2#V!5PT94bDR z?JUYVmJ%v#9f%%IvziraaWS@~C1ryEK02diUrh;{B6-A4%AWPlhfP(=*SwSwJ?%LK z3XK%EQ-nD8!YNbAC^(D(btm^MCGP_E#)l%j_uqdQ0(&2SI=uleE+7Giaoe(nAy5e@ z)ZG#!2dpL!5y|mkY8u}o(5h)YMz6Ll(d!El-YGms<3>XRI|Kkw+uo-1d^$2au;_z|&II-VoI|eV z10S;yX3$l}Gb-bGrbf0vnJ339PxjlB6T>HTu88balmij`Wwb?$8qju!1Y~ton1K&% zdZZZ%Fw((A;5n=z4&qNw0ftB4L(A-Dh}UJ}&OQ2yPbtck3IakZ2`ug}Ot^k9?kk|j zs0R9yfWuFDxB-59;sC(A0stE&CfNBE_)$|pXNey%G7V~)ojriHNF>xC^W}TzHMOe*9J7I}44$ zj1x8j83D@rU{`&J{Y3;}=Y=jihOdy^DgoH-{To?W4@qA5O!&1=zgAkS{JKlAvN3)s zRz|vz89nqRKtYjTVRy(=%U_Hue?tCHHqOvpIyJbnrTmyf2oQde>A6B;g1KVJoXiSQ zK`H#~drOuF9oxsK+B76pro(dy>W9SJ05kx!-<4|tIIerkCjc)p;0bh$kiUSvcaDI5 zLMn^4E!4u_=UrtPiOERBuaO>sH!UhsSe868TUqAu-J!j2B=2cn1#O}szecC z7M`4{AkEF3mPaEw3m-osI@Cg~zSsUOdMZ&+<9XbaDQ?4`LYF+cVV$tpj+ z^=LJ~c2FY7f@zO)=K(fk3=Wn8Y{xV*JiK^dr&?pE%#E;ZuUY`yFBx%DE2qk68xx~( zOxh9zP^>^Oe4+^-Bf@q9`08F?k~(Hi#)(AnoQdQ)`#c=kv#Gv2Xvbq-JtRFn{ix+|6?IW z`FhsJ)e5Ir+@>DFjCE%c)%?yu3sboK_MoO*w?JcEfkskwh|<_?@#O+~DGsy0(&980 zX?#l`%d=&>g!~gTiZ`;rSi~EpJBn(TSTzM4S+$#tF7<$8XkS<;zKj4!LG%QUtb-Ut z5pyvJpJG~qZ<34GL)a5-nIlLZ|2(;6Gw%9smokfvT#Xcgg>GR~t4t+^EdEdj^< zIAEBOcq)aS+Q3f0tc+r{#9FGkHj*J_lLGXlc=L?#GpYHUKqtD+$j@E*O9G9tN zA;&|E+Ss{d|+DsRm}W?RJK=0mkrxS>p5Vzi1yi7kRj@5U)u;2 zgzs2XzrZLB5yMCMpmNnx)G^SdqK;dJg|}E?MIDVSU*l27#mUmP@j;dr{|3E)sw7Kk zXt`oGT_USmg^(_uGhL%X{3W|$b%=biJMTw#+8#go&?ZiCCmL1qsH2l^h&tk^7agy)xUQm(9KxS!qsotwTPk=c>Ij}J>ganm{Yweu z!T&(OzM8;C811VGO_impaF2sL3+l4wg%MI-C`Za?wEiAlEbMrX5x|`;!bJp-y!0El zSd<-GYl0>bc=y?(AngU~`Jz{J#P@p?g)|6Yz!!3N!cdG1VQIvuAU zF9a;qt2Yup`yx56Wyw-J!_vrW0c?Sg_V{=Z)7el;Z)9FL9JHOWXUCSmAfU-;7+BXC zdW=!2s7NVZoi&Jo$((hdhKXnUdP4)Zw(bfJS42&!PEWIREfO~DuE0yO7X3@nioe@_ zCy}_;_Hc`AJm?)Y&@wPJrAYPD;_pPghMKe(v#D!{ler z}WI3QTQh~}z~W<96tisJj3nC-kfsb^@N!>9vA&kyQKsBN#Vd`HE; zeNCW#R=*)DMcK`sUDbg)w3wgK~dDM~kgW z;R=a-2obwmt2lgA?Bk;IgL$KP*Z7y{S~lpq8^}G`$l5xBH+qTk zQ#`!Jw+L#Uo{Sfw&3+-Z>Kc9ko2$7n&8xUD%PVuZ}RxiL1b%3ShE-<|tF>Y5z<%QU+jkxVr&m#G|c% za)e%NZ~zP|;C9Fjmt$HdBEb7a9HNpMPaGnqByotyg0Lf$rU97+#bP915fbfHXb~tZ zLW>c^2i2;Df=WdeI+nBeosBG@S|eDMp;xF*a}vp^rjoY@UHilZG-?6m-aIm9Wk6O> zLA8)npjvT~XxQj>Fsef1m_cJ9yNd;dmVJb(hxdzxpa_;6VZU`E7p=qNqIIw$S_hGV z*1MTvZ53K)ATNT}N1fKYPU}YU8^KzS?dB*leH6ya`RYLMf} z43lIS9;FKpk3O?7Jc?a2FFgABvyzVIA0AF@1Elf~Eg2sEV^@XEU*S=5{|PFPXL==z zyIih5O-OXR3K2}UM8m`=mu5>_EwQrz_&a=}tpLhS+J%|G?Qw3eQzOSXuSVBrVvJ?3 zWS!V4n9s-9Mie}yZ&fC!eM}TyW1@4!6kkh8lm(dRv^EP%k_sF=btFGOUW+9^FXk7H z$hC>mUhe|6L!8s{gkwCFSgwwBmC8?Xn51*dF$e=y$}tz!`g%?vAeBp|92w}jRKpgj>=;|6NDS_!FZMhAB@OPaOv8~cAs5;zC+hGht4L@#-TI+ z!8W-TjhTPQ5izuT7XE=XG|z{VrQn_kh0Fo$%73%5=v*Q)`a-(`VJ+lY13-(JQcPJ4 z(%*sww4hs_iY?h03d<(>0V>AueBr5ynf)nBwtT7}S($5VDN4eNTGCOwkJ6?RddWCQ z9@affcmRdM>jQ>N+s<)b^a+eZ&ttsDx!4FrJv%Gox~-Jlp1B`zdU2x4=l4UWJU}P*<`!^N&BrO8P1bUNcZoH zAvOvXQjN$4?o8v^T0Nm3%TL1gva_jG8x={9wo~9n-BD-K&u6h=L?)7JoXw)b)~Jqh z3Y`ew{NuxxxiZw3$u5cH1%)(rQW4&$K_>a5u#z0T z00MZ(cnjfF@RnHmfH(n3@c^RcknX(=iRJ}T2nJb13P~$yNuW)Q7bAoyZ(H?P4o|?C z8{JIsDtwx{c(iJUQvv@^0K4M|Zq zj!brzU+z@-BifDjlG+ZR@2oVfh1CSQ1W};A(v=$CRGO^;= z@S=CcA{RlbZ4xn!Q=mCNXo%liK|BaoGM$kB60xi^HC{B9vnEqkB$vR4i~>uMAcA8X zK>6zyhZtEjh??0(R*ma+vhkKIAoUcehwFZYI_$|p3Q|{ycm86ktCEx9*!lV+4$>?JK%U?t-_tXyOZq_1QW@2HwsvEr3Fv7 zqbK`it}aF17icJkhLx=J1Jx#{r-~%5}&Bu_?Km^TK>L z$29poH)jOtoW;FQ#GM~%#*KT5?NM|yq7C+#;Jh0&v5{?Ygs&p?elEsNS?xC%zJ627 zQEYb00kCAI5q-NWlZr~Fr)To-xiu%pB<5%RGIGSP&^jRUxHetXsn2BTW$QwlFzT1F#>H7=nD{!(Njv%p^)nfr8moJf^=9-F8m;AzF=YEg<5X+R zxW$zp)pPw(ryzrWzzN#RAJ-fG(Hn#>|2PeYH<*|Ksu?~DO8YWpUxG*A$mqHGCC~t5 z!sQWjkq&xG8aK7B7*_GRlw~q%F3IEF8nG%^xX55{mIy9M{_vc3E>)7iywTK%ry`er ziJ99$r*&8B8lS+bVK%D6{Lg&qDr?C6yZcr;?ihN_DzeVJXNyc*oRjqCkcv8}SzJ-3 zC!sr)Q{r#_;6K9r`UBwdyCH$}j_;x2Xb80{Y={Q1>g)wDE%*U2#1?64Jm6}ZM|z)( zg?XTB?DPw9erHZnBxJfyguupuEWLCcrz)5dlJC}3!ODxXgL=}+tyMgmzrV^cCf#W2 z3m^G`pZ~jKKgSn2I{zi%jByifL_g!+-y0jmy;Ff5;@&eHhXQ0HY-#OyPO)T=H=HYz zq5wJ0A^&Ie^cLHlKYlA_GhaoAmi1{iblZ$MpyQW`-tXuq#4LG=3Grcb`HT|;V08T%e&oRjSt1_IML?Ze@L{;@Pp^jWGn|Er&*krll!Tc9+~pVrSa^b=0w3^)B;t)CF9prr%hb?(bU zdeP25X%`zpeu(?t|5Q1L$bZp50tG{)AOe4HIG$v?{u#|`Kn(`OF+4V=U*mLpR0O@+ zdhCaPT7Bs!##nX4_+Zr$!)$SWNOe~&J^>Nm;u8=V3@5-~h0@nm0jb%8TA%&HKSL)g z@}Jj*h@2{mG?;xc`FZ4E%SuiTznLcS-F!Pjt-*!!SzAxOHyQ5)wyw!V#!~1fa2dtz zj7UEwEd`|*Ad&%+Gj*Wo{H~K$;jxCXe8X5ind*HP!j6M5rLrXzEGR+212J*|4Sh!t z4X8`NG&Rd=PBPWn+n2C|79<}eHFSM%%$a*!XP1-^knC(6#Dk4k;^F1aNHXI^Oo?J& z?KyQ`CDATK5=Foq%8x^QvIY6R_?Jmi21xt>q0hvfA57+O18doHxS`~Oz?j+@CW}FE ze)9VdbGO#E1i*YKH8@RDgT9d;`q%^bU$(}ngY#>^-pkfFwx9-_Z8h*`85L188_WJs zF3Mk}4@nd(wwb#KpWMdHUGYhYFkm&M6`jui67u|LP^Nt8Mf6!x#_H)DOJBskd0Mof zI|$bAfTygC^PN6eLYYbx>q3H~u)S=yHCeCMMz=Z??4 zVALCNZ=Zp8UWsEnA4Rs%(VSyDTas#V@2bv^*8FoJ%pPIIXpPv!`l){LRTKpZPkb27 z_ct-(-Jz5dqKA};3a&-hJozVwnI(G5j`>rJcXUNeA_XOIus9SBwPfLM@z=9-pl_u( zKeN8l#}yI}0wSH&1Fz*z)1Y`=rDQVcG$H|)v#I`=MG-e#5W9F$bP!_6D_T|K`mLz1 zvd_=|OZ!x8gPunFU`Iso>oh2s!Xe=nvqbVKqf-Sdg~=rUi_kB#lT3r0G)X8$lYDf! zN!rQ*;V`Tz9CyVapi54nb@EK}(Y&VJ!17WUlFJ7!HGUb<#yt>BTtek_6sD-!!W4@A znjt^?07%;gZZDY5AJ_eZ9|6ZFVtgkxu8m5VnRT7EM9KrM2kHLB2Q!EtC<_wnBxSC2 z^c@Pha?rEJ!yQS@`f?80g1}5RiFK_{yY)2~KWGB)-ajBEyHlV4h*>MjfU2g!=mp^v z^#T`sFil#1w2zY?Fp=lp<49SW)9rv`g#ZP|y7k*W@r3iSjX#0M7Qn5;NV#mmC+^+M zjYSzVY4U;XKZn)`M*ErD36wTy@`?e8{cXpb)?t;DC30oCHB{md?k(m?-kfP$9RUZc zhsmz8wuro*G4jg}zGURK255Z7Bzct@a13;c+6o$c#aB#XKp=rlC>`Y@ua^reGXjtX zAVb{oY2$QjA_>+6{3E@J5XztVq!>yhNznfABOv-|@Vk7SlN2lKoGR+PXAVg)G13Uq z?a6#fup@AXlweC2q69nrl4}v4*7<{OeC8~CLsQ|{6Va4G!ltBnzY&5WTx7d3aapIp zn{wZkN1fkJ{{Mq4Gnfb0M?jIR7^E-zAj?JPn*#Nq4Syo4Bhwwbz^jJ5vs$U(KNBB26ls&gY*uwb2n)=zUhIMia8l z&xuR&)h4C*!#rG$|Im6&!sqM<`kTpHOo($wDKINQSo2hRHPyP!=TR*FJ(@8OTUiwW4jB8yKcT1qRNTRGm$W1IQB_INBG~fv!H2i z?`MEoh4VBnvpe?i!z@Rq3~P|JOH&Z`Xh)Z{1eqLcT~0s?KfJHZ_G8cpUy}oXN_h&M zu}p8@q{Gp{m@_M9ZJ+SiWVD_-{TkLHe!fX_s2xks_D?p1IPL84^eZS#=~pe;4LtX~ zj^&r=fTOMaU`w&I)a*AzZ{ZVguxarTDT4>BQ}Y6}xT4%RDO~Vs6|bPsR8wpA-X?1_ zgCgwnaO`aPIt}C1cF+?WFO_|72CK5~d9e|ew94SWn1-H@_-my)g{T=@7lljsx1NoN zVc3MTHPWH5t*sHq>|`~4JeLJ3aZw#EA`Q29hrT{xnhDM4n6q=D6oqz-eqRNnTB{EX zZn#2UQ7#;`V%#b7l|@w9uh&r&mUgC<6xP*$Lh9?S#<45jzEYMNBK%cs{?IIT*ZQ< zTE2K4)nPIFAR+5hHGUcwY#BDRMG&ATtzQ-Im8fVNq{qBM=w4{C?OFg~Z%EVJqXjNU zADZG#-Lb5(0~2<)_|9xx8fNWLb7HNngREfo%3F3U*TYxBDos$)6G_8v0RIpONmrz# z2)n!BmqPTD*NrVK$}^}ly0@vN>ju(VwjO_8v{NwpZliJ|sGFT@Z*;D`0V)SVa(GJE zZjy$Yj3$7L$*KZ;3DDqZ#_)A9qa~-*`>K@6nUh7@>r19j>ardpX0m>att>3PxE|uP zqA(Z^T{ZH@`7>_XhY2ZPGff$mA!#>^-u%#o++~l;4#aDx(U{<6 zpR@oUmk>p=Db8KJQg}pJY}yw84&f0=hREA9;o&-&K_Wa@Zg=64C>s**_#KgPm8yIueVLTRd_XEOMGH=pU~TJ+u`Jgz~}#@C#zImXbt7-q3;ag zl|Lv#ZS=0K4#v>`wLs)|4-xs@UpYknk8eoE?-{upgY7u}H=8aqa4e|_{N;aZzZ=^# z_ip�TeSgb#9K zPT=44pwdp(md}0(yA(;Lc_SBgn_(29=9)z0FGDvUeiH2boBYUUh+F-c$F0&k2Hj6j zHSQj)(#Bq>WEIPY>NaaqgC@x&gjx9@Mw=WiM!@9~ZK1DcOpCy9p1hd_+C+s|^c*C; z53&J`IVfjl8oQRf3*}L;;yT?&8MU=R@sj-H(}xvxnxDg@@$w;(K{D2e;QSiWEGJkC z9;f2|>a5kRq0sWSe`%Pn1S4kh(Z2d%o-EhK5Mhh2Z;vU|TF=ImQ>7D3x@cVF**L8; zM*Gm@Ajw~UG2#@Nq`YR#39R#}sK1(mLX@Ji42Krs*FjULAVW%tRb28Heh?6T4iM%? zKLkwI=g;Xu*id;kyD%@aOes>6Io*)v2g&qn_|BpO(#xwb69X5X?zS}Ac>St6~Ju*ros&Mr&TDkbWbHrA9S>Xj0WN{LlviAJSF zvr=MZS)v(Aj6f=^Fq}Dc{=L~5Qy1R5CtEx9P5eD;YJ$IKPYw9HW@v#I?A^0x z&o+opz-(29=xB)T`AFsY5Dg=h$+asbhG=M4N^~kEhG^(iN{m)Y4AH;`zDiVfD<_!*f{8}LaUJ@F5l_3fZZ-wghd`0E?5DhCdbPQLO zSXn7CM8nETiB**nLo}?alvrIUF+{`aN{Ka<5<@hssgyXQQeudPGb$y{tdtNM-ipwO zIct`==v+|g14DZ%@A7MnkhPV;RuOVm<@pdHXH}+ocBRA+A!k=gtgDn5B4k~q#QI8! zAwt$yO1!F4Vu+AeRZ5&wDKSLIIh7I{DkX*p*`N}J5Iz(a5VG=Xh>)zCb@LiQALSU2 z5cOf9EMdquI%`}-B z{wAkHEUGUtiZuC9VljQ$M2ikfET%7;m|DXUi|NZIt3ksOi|NZI-&-D*SWI8?iP%bs z#q?zpGtJwOzWmzB1zQf1B_}eBp~1Q$9E39JkVIFRxFr?7P+|~z$e);x;75zs1;(E$ z9*}vQI6?e(2ruIk5@4E>jxgnTAx9#>d!y?|;-M29A?zys9l1tbgK zL6BG2@JFD`;owbxVt+!7SMbdZ)m}iXY@31@`QhpFSLzv@d|9DBKD^epyy@~`?*U$#>ht47b% ziLb0wRhqSp1iW0qL2h}2f7O>Jl6W~z#4~3q!$k(2RBLLI?~3z(Q5N>nqB3 zcvP>CB81P4V@Y-kK|$b|eY|KsFOW|%~tFow+FF;0jL4vFOqli&$Xlo>K+5|UtB zN$`X?B!eeRLahJycdF{X`?_1Ju_qqE>$}x*>eQ*T)u}2=l}B&0K>sS|N7wQlCXB$@rNp3Ka}^;H^2 z*r}zbU;;xuHmZV>a&PF9JgPO^>0E}(rP;|JeivkA9>F+s$BRQbI0=z4G8Lg1TnmoB zYl+2Rf?bX;z-vGE33)btV`o|}#nyY14IcCXR`qGtAb~;49hddrpu(VuZ0X<{pA4k{ zdR{0QtMZl(uJFlHCA0H`=9ZQ!S>}_W9LZ!h`mSUYc*w7K!gKD8m(OgMaWPJ)>Tw`7!xN%?J4*w|TCyV*0KBhjJ zIAJ4%vO9mA9>iI1(`Pmjf>)A>LB;yvACtd`cu*JhmnxP|dkjDHq=t%uR(^*on-g;9 z!iBlBxD;M=TYR9xQCvVbN`sYZqmErse$x%NR6$!RbgwV8odf(HKWtC`$K!`hkSVx& zK-fd8>!UTSP;h4}^ksdDlsidl-077yu>HRClS>*W)0xcq+8GZ^GCtSoviueWZ(ZwpQ6=4h-L$$mikD_iA z9Yl7qydTN%%IPGsTK=+yn_p)sbQtIRct?O>!iCw-W?VlY6{|9dE%FE2`<6H$60b-u zfe^W@!M~388c4LXUThNLhLGK+3%rmIRZFyMniFMOKx+wbA2O7{0;d;P^ z>^s8^{~xFVWb>Xwjd1#&a?B@~#M3X2t?KP8X>l#0#XgAh=awdm+}7au7Q12nf&lYO z1{inDho|FBrce2o?#j|@8|r(G0?|r6G@r3iwN--|HKQ3{KiR;qK{$Y_@1|k#l)-5X zQjw1`y%Yk;d95@PhTW^4sL1gvzR5?zS+oq*_8*E_9Ll;n{PHxI`HG)pOvFu=IJ5dN zYS80WZY8-Rf7W|m6W+@?no?3%zMNGmWbDe%K%r)AbfJFtp+vAe6e|%9Oe%qnE7WS%jlkBp-EEncJ|7DC-(eVB(j7^e`# zxzmTCpd|sMqf!tK9*4@~LeR;UYaW8wFK!_OovPR076qNA66T@d6f1Wj3PM^4K_?v+ zL8mLhF;Ngcp%XyRa?3RjLG0AB5Q5GMb(}Z_y-r0yK|ON^-`V=WVHxGYmrAn2$p~G? zE_6%u#Mj_=&x=_(@0S>%{>#&y&3>ln9`s zb+TmcU#L}TUz8xEy0X4^pmNh-O5|efi!DhFa=0=1R}i9Stz0iHS7kk7(kk{t9fv0U*@ zZI~#NE_ZTJ8w+^3_xx`Kxz{Jc628m}qK<#5cruZxl=e+e2Z|@<+gm&--@f7rnVdgT zJkg+he|T!zDs<6po=%B+t56+y8l_`}C36R)S?wBngZb#~`I{woQ8~6ZvAB@@^f_7? z5iyuuiq%uiAJf1vvrx2rKf13$oIk+({QL3)`ux=x^-FGH?Icit9w#30^3>gZe$tPm zXL@dy$vV4cH|n@mR1>%Kf{WBO+g!ODt-`N)t%rTCo-mEBCyVlxmNLKBUPPE3q=}_{ zsahZOD%~w+=`VW?r9O$-=2>j7RE!p+e+0-$2#lQF_bb5eJmk`&ETXnMt84WnUOz>Z z+ohiiK=$PK{7W+Pq=G)C`&ap6t9<@L$`&CRi;||@7U^zeWLn}QjZNwvi&?rX&Q&C( z9iX6|>lq>1lYws>-NkIRbwd*L$HWecBzeMchHb$};7{7NJeRY8f;l<6MAd}*n5JQzSWx9*HmhGOz4{MsOyf0Ej zvkL1U?oijEy)UsP5vqePIBd~KbvQ*rR5g1wkb}CY6+eq|rlUA9p$FM|m5`S__RKOO zv-GT}rnnoMzOiY@tKA03^ki0@yey)>KoUx1m)1Dd+Rmfde+~Y{goAl=fJF`N#UtwI zM*hyC)}`^dy~aY+uF(A&ap7ZU$l(+BW_gI;hL+H3#F~&)*0QYXZ0KtK1c0i$bj)1-q@b4b%6S3YSi^!+eblb{f{`D!jr_1I#E@Iv4<0l!B4Nyy^g%sfjHOiw z?_#B&HwtY@xL}T*@y8Y+u6$*(8MCl_?-ygX7jZ5>I8U-J!#HzPYrC5;6lgdmEN|Ub zOR|&1(IBgU(zrlr>`)r}wPb)HlsObGnGliGn-&(a}2M%Jrl1JCfDuVu7jUl15wB8An{X{oKa` zO{z2gjqi-2eZ|cs0RY=hB2WlOGDz*BQQ*c}JvF+hJ+78A@?%G?V#B@}c3=ulF*VaJ zat2V85M3mKl%-9;XZ70L1gOy>poG$~a1Bl7aB_E!)*`ppq6L0R)|zZES*wwOSHwm^W(#y;>o7(@ zQyxnOhZq+P)Y>f@>=*F#0MLuCxv`_Ab&3Pw4@VBPj>5|FK$?u{LC#R6iJnBcsdqOaiGu$y0?Pac_9zw< zK@?OX)YvBN);CblIb{lZ00P>-AO&UH^QY+pq_~s{qo^l&E+`0!dZPRcMLk-6ezNGAyB=+sf}BLFzTKDzgT*R+oc z;W>BE8a6umhyi)rqxN@_LY^{aJz6oxKqC_>5*~J`NMCOYQiz!0;Dn1^G%%&a`2rZd zj6123Pb8c z&9uMSHNX3u4Sif(i@kh1wXN%%wuLU3yZ)2v$6hgymiq5VnOq0@Ob-;9j>O@djmARU zLg#nt2@A`4<2I48Aq>v6nTYtHm<1EAvXt7K@c68q0cY(z@Xm0C@?JbBY|1wu=g0V_ zFz-Wp-@8kInFG(%xppD?!Rg>j>WiB4aha~L)ZJ7Xr|7w-acW*^#Ex~bQ!5_aBwL!D zs$)MY`9Ardw8okV(X6sE+K2kg^3rp3|M8T$U3d0JSIz=6Ugj^5-U_J?_rD&wZsql9 zb*=l>S09$6?}ZfanofmPIWMMi2U*rWo%YfG4xp^r`)f<}H>oW#<$gu-a>_bPt}mr% zn4yG(xrjHYN}V;=r-kNxxli!AL_eQ8CCrHzISg?*;W->Q3ti1MBcU0*@1vx1RgzlM zhS<(8Y4o2%d_hNp=!82w&?M0UX9p6X&25yv%fH##C<);?uUNyga6_e6as)(|nrgcP ztRFa&dYI@6O?FG*&k_))t6N^*3GPn^1Y2`5^1htPm?D@Jcf7l`x?fD$DZ)6E0)2AX zrNC(`tT4P~k9*@0wF2D}mLp$hw_I)&nQ(%KTzJ6UDJKpuOSEiypqbZ1a_a})V53fr z;o&TM5H$+P^vt=e`060Bb1B+&%4X&1=!ea|5Byoat`Brlnal9)5!Q+t43QlHMi*6= z)cbmSko6Ti#o1aZLZUwH4Y7XUJl+1FqbMEg(!ZhrR4e2AbP^3IZdMN~3PfOY8jvU0 z>r@8l=7egZKb3F;b9M#uD8Ed%GVCqlLV zJYk2$^dYk?rl)iaLIz#0eP><0%gh>@@zFck>=ph&S<1@!tY=YDNh#c3 z60!(tMD(1ON9{EtR5V<4f@Y}vM_tRsHK89Jd8I)c@WLp|pYelNq-wEwF28T&ocuoV z$?c--2su#9dcaC{GKXuT8gTePrLl}OZVdfY;2i_vW6=DH#4+zVELn41I!26M)jISv z>&GE5z)-k^P^I;fBw{+QYNEcR&0A$p5$*OOb8#9(b_|&j(h-vOH$`cVX0*9ZCv{Zp zB-4NxX-BFBGP*o@0vMz)J!VrzHm)GMP0Ih6?QNi?h91cMsco|#fPBmWS&{bhLMkbT zvyy^^BgST+i1*Xz*UL1iSx@?po*3Uxa+kf-fQ_Mt-S#9$Xm*kNY$}(vA>0xMrc)V> z?+O!cg9XQRb%L_!#u#Rg8~9=`?T+eSKd{QmQaQzIW7B+E={~Kb3LBOtAQ+Z*!Xh+N zlWn;`M|8VkdQw1pl$|82t+Pu|KRdf&OS>BwAxG>6CTp4XBiJ6eo=k}l^eVJn!if#n@19= zvq_>?C_?T;2pYlqpsbA-bSp|IJc>LYIiuTHugF+ThnU7^&Z^^sJQG6qdJV}mAlkJz zHST`4h~}edNpz9g%h-D?ixXYB=+N7l@%DGt28lMX>N zNt7)pza+W3jY;-9$<;qka@m1cI?J7{w%noNZOK*ZXKjWTBd-wp5v0#6lAd06{crM0 zi4iC64#G<>G(P$fUNtR%p}$J`U$XorzFcdRVrBHVNswQbXJPqegvdZaxia}>0|xn3 za|2@l-1LiI4>%R8Mz{!@R>n*dM^XM)|K;&t>LOlJqA70JH))px+}4oN z&|K=Gtfn^dbrM<0U7kql2>A%{UgK9!(SKd_g6o(z-Z8oh;i83P?x1VJP=E*KSQ1c= z{|BUKrCt&+;)X{OP<&<-Kw5=Bfl*w8i~vcfonC0n9e}KI&$RCCjp`r=e2M3KR&z9- zKabgzcs}m7BQhIXPj@8AWee1U9Pns)zrq+?-8zsOVfLH_xpZ=jO#5+zXUta9$$nuWJxN#V@E_cwy1MiQ;crazy{w z>8}oIb3&SZ;M@$Aj9qkIgz5LLr`kzv1>^*Nupx?0R7uiQ`ds^U>-(9mM1G-0`-Vcc zU7EQTSRBQvF^h?;r~hsS8f5O7(E-chn9(zuv4S3W1;HFhngazhQr4&1c>AK*y&i32 zFmFSvZM)4tP`Z zzd)ryTdwBXJ<76b2dOIEc+GOHv^9Q2ffYwU9HCc~^_VNm`s#6U9MmpfrH0Ue_GP2p z&Js3t3{|jgV6#+hJ(iSh7iAp;lC{_;Y!_uU8*j7`IncJhdmV=|Q4N04M(Daihk6ku z=;>7IjT?#sPIrQ{DW9cvoAFZP-RbnyZs1JX1j!{`!irYq}}jj%|3w<1H; zF(gwn@_oKiQELvPTN&+hRaef)u~u-4IAX1w5vcV(%i*Z?enUjAqY|l;Lso;3+G~ZF z$ke*bswq@RV^Oz>%-%U7Gte)QQS-MuGpoW(y;LVixKS^GUbE~A+=ocYL7%2*p2Fo=AjDa@uz~in*g5OKU&4#9FDqc;4;=$9Mh5StQ zW?}hhaufM!3MXA-#0{18I09jpMCyY{NE{&}McUnxpKMVaY&*<8pfV9^pCv+j=X^Hz z17UY1DVhLkuN&@sEu^T((xhmdEqgF$Zxk^fMxr!-U*-FSf@Kf3Eja(aBp}fPIgT`K zoF-h&5ry(!$T8+cA-%SMGMYFv&y#{-;2g#BVV z@>htc6(xZ`aI-Rc1uu}fG(;Q>D`(>J;eT^fSiX|oy^<)>+)j6X;i#!9I!p}DiBdbV z=w{DHTZ+{&ojVdFd%jC#0P=7!BfM z1g`VbXXD0cx;`HdMmN%pr}1A=(FdBRy$?PG*~l{Z65X*f`hDktw9M)|y@Mo8UlhJh zGdos3w5(r&q&V}xKl)p;=Kqsd#Aaw$HQwUje=$9}E@2vj4si=C?tp7$rh5M%HXR_P zMa+?bXp@YmDehYYV`EJ17KR2RPiMYkl>h65gz3uB(sRYXbrM{!|4gO?wd18z2D}EK zhH92ny}+%_Irt_iCGQXu2!BtuhnN21tBMkY3(5S-ITX)Y3fWjca!Q>v0K@VZ*J`F%Fxf=zOth)` z=GJ>ijJ@XCy%cVAkK;zlI~&F=dZ1VF?iA;eiX>ckx%E z^hiGbIA=1QIJUvR`_Esx>+iqx$B+Mc^aBe!`YTa#Bu~EzT0FlXBkpg*-OmQM-vM|3 zGva(bWp506e3%>fF1!2TipS>eU*b4|QI%6Y7j}}Et~F2f^pinHbN##~?tb|KI^6vp z-*Wd49NpbtYQRRZhNo<@fkAg9w-R67WC8rNaQ7SceBLG$13%u#7~s$AjN z&v5FW<(&EyRJ;!U{xjVtG(cd)LIyyykpG$Z`=yi~-ruji%Y!L9;`|QVzzhPVaQNG_ zLgrO#zdbz5YBc#4{uBGk3WPSy)~yWivG@hxAT!j;^A8Ly%^dEM(Mx4@;LSSC!z zn=@rn^djdFjLThj_Mb5)&FS-UEi2_h;)n?PPj!-q4aZRcouy)4JMFjY>B&NgoT6?k z%52IDuN{^$A&cvQP@X&YWTx-HdIoHkuAelAQO(|!lzN-XGjrgu9=(5F(3mg6+1ECy z^g`;6FOX3NpHVB&IOc>sm?6O|Rj|8y3Mz0O4@U*;94s4-!-a4XVJ+c2RsfOR%j2gm z!rKC!c1Ei>7nWqd(;KWBXQD(!Mbf5l6&krEifgpu*npLqh?HOj9TtPVqgpG+x#!vP zslf*HHV=?>X^VX4UT`5fKWVN)j{`A^1z}4ARRdIgQ8#prhecD>9dz8M7IeIk&n!^3 z{4LC^5zGnjo?d}8%9dT8YQG;m%Q}4uo3hRYd$OMk)Y`)ZO095V^Oh((MMsq^6)M@s zk5~$H2xl@<70{QOa;(#L0BJ!P^crD4Di8OW3{iq=Xi+8Wy9|cM6=`umSE8w&)|D7p zm^J=HMZMUWDt2#Ea4ci^C{p(xe~3y&6M_55#PnbK7+1M?ni9hb-w4OfIC~+k|2PNR zt1*vxHp{dn&zDj_V_9OIM7>LOS}KVSSmYl!Pb+dw@Pg6jJ$%pU3NoKn)%V;<$p4bd z@iMg=k%Qu=cs?%pJ_vYGcB)&3#!e{eIQA(~$KgHEY&hMeRT-?jEu6%VvSULCYi&@n z1ZYXHw_<^GVOJI-%Q@#F{pTJRL&+&0oX^r;$=0UIaF=PVr9yK0T~Kv*Pj4Sbaxx~h zw$AELGy$vg$@YCx^RGIe?Da0n66=ulbaqalRvQpv&xTb3nejz5mCi#&RxeP}-9<^~ z9CJyqp#@4h_;7%UBOmEFuy|CMaFi}k($gnU61s$)Is67S+R8Myj-b$9Hf&X`Q?Z1* z2a3{3>)_OxiSux$7*?%7>cpaW=TZCi>_eEhOxcZmsyNlrMHuN*J;Be(X#|STuc|xXzOa`u2Y0xNcwP* z^s!!yY9Ei?v45<05Hnh5=P42#%yQ5HRTl#J15_{=LDkQvup*Us&2qfQ5%aiU55|%5 z6rmn~qnLC7$C?JQTU*4L*!qmx<5kBmS^j^*{1P0gKl=%Fe&SR6Iou%s99%AEk_^6{ zKg}ynB{zOpO8N6jS?@^suumy|S4!#5UeEuP;smsCpECVP=bHE_r~Hu099S@=_!VV} zH;K_`<+g+Pzo^*7`B!xDsC!ZOuj-F)f?m}B!8XJ#SND{X^etGOm`&D3%Wo)UZNZdc zCZ&|0R?42-&Hi^bR?Nbu>}xICY*N?h*?LG!Dl3E~6`7IL?8_vd?$r4S8sUx+&W zMfG-1M_0bgD|NbtaVg~irR?uW`J7LwVOmQ0kW!x1k#fIFNjf@@-OA2{rWs2bPWnUU z(ot=njWyl~T2J(!&2|E5^iK3v78&+1{9-0J@w0&uDc`)TxP{yPz&qPF(bP3HLJJeA zmt6I$q@3D^nwBc^VB=j{3|hbG4UvU%>97vZ5HukD7hQ@kq|hg0O-|>jeW|@F-gpMB zpfdEo^{8;7D77~w61B-d=D*5@pb^X9wEiKO5_rJ6Q>4FUAOr89UTd0lsKawJ%B3UTrkI3Cz@=GK3TaCm zfBF433*^)_bw(zrwSn#Rr3Qi8qc=!P5NNp?1cYi3Rkj<%?65T`rF;}`-yn4?4hVIi zYmnp3Bw2y~Sil)47}b$YA{rW#xR&tR3pxwNcs4lG(+UvkpPOHJ|oi^nB> zSL98dG?wIF@{gzMkg+8Hw0}Ia9~W$r|D1nZ?oP=1`^Q|~v)vhDf8Za_b*Jb3vVUCR z4q5xV&$`5yYYsojf7d^r=d{+J@sC$%nmEb-_%kl?6~=G#Px{AIn#xV`pY@N+%%06Z z>>n4)#!T{m_%)ZeUxO^k|I9xwm#+)4S3H`A^36wG;@^*C9wzzY{`pOg>}LJrl}5f{ zFi8KF0YL}X8XBZXRU2zb{vSc+Iih+U$C?Du`U;0BIVq43@aoRQPUu|GRZM={{gSKc z0Gw0Jz+~|xLqVn1PSXp^ABMeqe?DZP9>&~}+KhP8SwR!~%;m z(Vg0n*e)*lDLR|1_H@D-$YsLQy{n9|uFBG)vTCYt#E94?QWdIObWRjiD*Qk9U-?xR z-6K>10mDhsC^ZO#8h0e8^+3d)qIOOV49^arG;W!ndp+}Tx81n_&iP`o_ z<+JA%llNsvnI<;GbhQzqp+65QXlY&_%zI(*(FR~4c-=U(!CCvSF$d5KgYLh>;IZQI z=r#?nzIJ%@+^UU73;Q}oJchQ+YwZ^$WRAT-YR*N+Ko*@OlQO2``Q0Iz=ZR!q;|@;} zQI1DNduq%bO%*~@^WK&%!FzHoOXB5}Pl_Jk20@qG^vkayl$u}*ygj1bzQ}G9W>zWd zpa*t0!tufA6Jd{Pt1sl#GQxLEmtYO@nFm};gCCOGFTLw7HAmNhJ9sg>jQL04c7TqEm)I}t9D zfnDBIfG&U#uF_jHsYkqUOeEBEgh&Gni&Y~0ojoMy+v@PmhiedzTxKL&)Lv>O`7A{1m!8Y=* zgvT2Q8j15SN25%!vh6da2{Hj58m23dav1N;QN8r9HXH zmMl>~6pBv$E+dN`Mbb%)VfU=WHPr|e6&5*s^c=a66LR2IIffh-heV&T!M3FNG34kg z)#0`3Bex?TDCIyWIEFfUOF3XMERe~UK!DhS3uRV35bq6pjGIoxA;ut*{Kd~9n*R{d zOvhhNzl%1}sdpoKp&E;L%tfNSuC(b!Be7DZ8)UT6jk&TbDoL9Qqq|vgbzhv#7adP= z7RYAB$uAy?Tjq<4jfjr}Iy1_wI57rkmYn3O?JN7)8_oe&nI>Qn4B*?IY&dSooWM)z zu6*{9R3VIfVmD?6)$Ajm$KaUV`@|g^bTGIL708hWYu%Ddmd`$h^ah`cFKSia6Iqp1c(xtOWZQcat;S5 zY4%%=+_q>V0TAc0qT>uixCq+}8XLiMT^MW(CBA9(Z46^!=`bzONHo<;vx8#!uoxts zq(wI-OtV|lp<>v*@N`CBRwD#bh(cU)iE2%xXpm=;n<)zRg#=S%A0EVLoXviKcijNi zr+Elg+3w$o5P#9n1YS;)E>*| z3*2FoTkK)T<<7H(n{}?h(zYS5JV624v{nm}-IJZ8qi^^8M){jP**APg)C1IJE}-Yy z_WQ_86!_d(8Y{BY`5M#wB|tRu6}g|kB6zjk-wt-VOc*UP2fT*PzN%1-%mK;Tp!Kqv z0MzHFy(34;W!+xyU5<>+wT=z>Ko6Fba>SoDA!P&dwNcE46H24n#b$nV)P_Cac6O)# z5$i-k)?5bqbc6D|#efOWNiI>5AQ08giR*Sky_j;sj7=H9wnG99(XZ8pRgj(=2qdFsekORw)xwLh4=2>nZ(CDUmv%5+-R0 zQ%lI+(Arz`rHH*XS4L@($EB%gFga~ASy%p#0((XmEoWDn?rK-}0{@H#r7>AE#6nPH zyo6)k%weojU`&d(@LkzX9-&E+2;0o?r(tvqS(L#G`D00bTs2tNSp`lfc+D&LsW05)*AQHquQ4h8UAqPeKhZq2o=MuFK(G(8 z1~$?UVWA@sf)pOGry$Gvk!9Z@41CkzJ1(THIqvZ^FGn?BtcCl18@zBl(r5%LFJWy~ zcIRtQK8|lB!=Bbig}WS)w_KTRKpX=qGY*^fsUZw{Xx5HHE_cyl>mu|bQ;PaShlL(o zWG_m36h|(Kla`Ap(wL4juZV#>t-)HWp7c#^p{IybL2Z%5kaFPJ9C82&Up1vgMl72| zISahkNjxuE7DRLuM3t~ph$>j87ce%raN+{*Pefw1S-HKPoC^}YQ)*VE&U)eLq^8^8 z*;2CyqL-X#Ve^J4N}d#hveZp|QzQ_*$UPr_WIl^GGQ^wMy~Ufb<(S{l%siSuo+OoG zo7)QF8Hc0hB#b2L+u64)<()3X17*oz--jMF;#{s!UK`@P`yq6YljXZa?Lj}J7sF26 z=G_?Vn{9R%InfLT4@NgWP6J@(N;rtc@60 zMWX$_RZExAL(#vaw*IY{;~v+M*Aw?~+lOqu+On=lr8rN>LqSX>d44tIl6sRy$G)IrJ`5}~gQ<_Yp z`eP%o*R;rgv?6~Y3H#A9UtJAqnvv-|8q`oU_ENN-0c6F{k+LUz(-Rm!W|6!=){}=X z&Fe2~t*KVD8`ETCndAZ*4;V2sVD509gRuaYxRG|*=Fgcn+hZPT_zlN2HM>OOW;Hm! zwcCLfCEIj+B$(zKPbCRZHuXn$w55J1o_lE0{eLJGznCugHV#edENOB1(4>!5P~x4_ zvt!oYz+%h8lpPOaZ6l7t9nq6f{@j0alO9n{fT!jvzho~WmnK$k3pqj_&2zf^(RTj7 zho9`JaJ842xw?atHqk#=4IKdDKwD22&yr7bT^sj8uF4yP3R3l&mv*ha#3{ z+L<>|X-wYCFKxdotz4Gsr^__gaNCF*;1V7OIIF-!M5i3U_8!5SOy- zT+K$|MTOy(LsI6|@I_yP=tBtfbro$j%RiGiNa#@<>QE39t zNjYmnQLezUxvGI^@FOq$($k;4^WQ)5xjP7D8~l}zANt~pKmM~n@t#^O%AcM6f*@Ou zZy=VrDGCm=%GT+c!&PWVt@hs%7qGlPCt{DCjH23i(u=l z!Ukc8(VJfdE#*Hk71+1Kr(FwY$NH_P3mrfkdVsJ|MpcjoLn%-?}Tu zL#J~$IMR$GQL=~=Rn-K;R>)Z8{q@VOJWitUZ&~X+3LuJ|pcNdjCek7+S_9+LCJZ7b z2xNxKprzE&T}o9z2KTCeRt@KqkT{xEuD1hG*)}uL$c;F%%_I){PyTwGsTO~E(8?9s z8RrNvA>R_vQE)Fi>kWKSd^1!>d)+ZZX?;JSl05aLWx{~FPwTGa3J##S{#z>IbMYCq zKW`+9oo2;I>ha+ZQT|Q20R!d<91UHtFy>heKOgh(7PVSv7h?cV){QK&`=|YCo?NkT zvQfOZ>-djd@)4=C9H$(ek+V;ajzj6bo(FE32Ex_7wHb}>X1<2P;_1=+DpcxjIzE5k z(Ei8;M=)q{+0{S89%x-T)71Qul)|kyQ201!BZ5HKn-b5C+*f?hs!a~hBV{a$PKUYz zo0LNm%9(T4?!2-K!f-WQyIdbQpqekLC5xmODvTv<7&AzuAX02D=U4sFIJ9c19m>jYXS^`(F)IR{O)uc8knoi{=Cdrd=(<+5H;aQdZ0mn3((K|>Z zgx;{rm|evYLsEYzPS$zC&g@t!3a|f$(#G}QgbqNutY1C;vJJvGzin53KfSb_GXn3( zKj!)ipOq4)yQiDB2nX}uHXYDsYUaq61fB!y23S}I{xx0tDVM+=T@ZT~H4hVG)YPBQ z@PQERybifm4?8dwD&%NHf7|fT_;hzO-c6WKYJ;*shEBlde7LCGnO%frw%XV~Pr1U_T32-TH3hGx#1?osM%^y$~iCV>nbp=G%Z%vy5;Zc}( zUUImVRf2MPdlucg%W)G*O{eJ!0R63)A<#`tKoH}7Y{sHr_1p9=VQyZnV((UaXRYAO z)$04(Y7Olx)$MVl%l?=FCrCu~l`_g~WG#d-q<<(A#!sDwvsA0Y3}vCU3{)e`s3!f* zXb^+|8hU}FPlLCoW_@9+{jI;mc*T_sD=f`0DreW>P#7a$?c~6;&|D*Ss*^mOTNw34 zUbc6VK2Z`z+3VVWOG7$lUL=1gjBmIpGZ{`AO6)kM+?H9mM39pZLw)zUsKIIz>7{J_ zp3`hGXfe(^u4%^0B~tVj={cS0k+jy4;>ZvI^A&+GgMbBDbdABIPo_Tyx@Pi4Jjm(P z)FpC?9O9Ugfg@>w5H%nvPplVeJw@8AZC2mY^{vs68|S5r{0m zxz9aB;=Oa~CU6m-fP=A=zsPNTTP;f<4f2Mj(T%cntks+t=qRPRXf!_!V+$-ZWK8Yq z8qI`JQG$DsY$sN;Oa0IdWiK)j64Zd+pa#IIoh21`OKj|J7nqp_WMfp>LL;*Vae%Bg-US5LtSggi9e6JSo&k zWEhn-rMYB_Q5=NNu4|AZattTn(eS%Ju76%>oeUMmk)cp<)Mi>`R+Z*TEcPCWRmtH{ zFlK-559x#h{*$dQU0xPHeSsk+of+*$PjrBu za9OE{QSEhG#Ywn>dP^xPZ6YQZG;|cbtvn*)>H_lCDS}6nx1knz@G}6KAJY1wqYToA(05F~ zQPM~BAPq^ho{d#!Rf6=u__LLr;@LzN-k{!^)lm3gYMY3o0@U;J; zYmw}EJv`&T=vpLuK@ZRQFS-`V4wk>XqzAoG<6bO3yrKua(U+IY53}Fmi{9wVtNIci z?$H;$(U-f+4}0~XH~MmK`Qbi2=#9R7to*P~4|=07_m>|Y(u3aU%OiStz(43(e0fX{ z5Bo2=7RmPO;ZgrZ*CN?ddU(Qr(X~i+Ko3v)FS-`Vp4G$C{)?_fvgh^ijQ^r*k?aLM zJmwMe#CU+(6Qkf>{s z>^?o*>%Zt)B-^KlkNGdU7Rl}}fAMm*U@*AByDauLSsji;)`PsrL}(<+I_ zqsYai{#XpF4i!>KQs}!`qQa6AyiO(P-~yjQU<97%bc5n&ph;- z0~v)@PK~8tTTM=vyY_lBD=6%gP6l;|Y*OETRVEiJJ_nnzl$Qb1j-nKHfoGDQmOB=! zma^-bYE7i0VvE2yzGYgkfQ_H4=a89sbB9nFYKzI#@xEnph&I@bmChcPg z%2^lOC^FtTNX9fYqjactnO@Z`7|vj4J+O*m(N=J!*}^M9ZuA8__PO>;iH%6+Yy|D_;Ly!j&cU*g<qECOQ_Vyq+S&fvyDqpgd}F z^Pt1h(S#18hNz_)g4XTk!m=ek%HOD@5Hct$oPo`7E+qQ09Dz_Xj#gKq;@Lz?O}bEh z>ZzxLY`_lRmVrf-cy$}N-)%6(;L39#2Byf6DOgirU!C?6_?^QPy?he(WgRTQt7~RS zLoRZLQ?XM97`N^wxHKDS9{d9gH7pwQ_M11YJaudWHJl>r&Evy31evR|1mlWBlvH?sAD71}DWIM+SqW6G8+XWk5A| zt1?Z?I#^8@{|3Yk9pkK#8D0#1w3 z@{?GN(=a5=WEsofb(*xTGS{u!0Z8R7lS54`$|B%Y4R*(W7dqssQGZgIk<};Ta`=Zs zg-NM4Dq_-tipr5tAr+^L3e_E+Gd7DL;%h-vn5lwtW2k`b22_;6l?yO{yPgqj9pxk{ z{RHnSkf7Uu1aq;O`;fLj(9!nV$->8+clRU|?Zy`YOEy-*fYHPSy>5e!NuTICNLV2d zAr6ACO+00qg~Y#WGnZ?lW%2@vR1oaiex;f}XF%Xq^Q6iK$!?s%sjW;s(ojm1FtD#- zC}I?u7ZDw92^A^Uh|`MFp75PQA#y*QS0qbG6iTOlLQX~; zqe`COh1^|y;4qLHY4m~Vz}k7-yBwM{o6HkA*$jeac&|6L*C`!lz+pc3mp)s36=|KD zQH?R0r^y<^0`7L^)vS_vX}YbP?KO8DwJW&w*U{SP3c#a*^``XVm|kIkL%=oPzJBKZ z+PAw62Yj{`Zm<1%VoN4?(EzOa-@D*~`YU$Tn>&-m>X}&tSxVPPpfsX%9dM(J9b(1O zn*4IABnr4f6!3DqhOki)&8YM|URHKfawT63A)2U!nxgzpTP>tw^B13o5h_Sg_{m@8 zDOUslrO(pm6g67^D|Br=>7>b{!1854{B8kL``g&#o_TxVA`k*e2vG#Z6*g|89vd(J zwQtfet>>@^J?yq6F}VPi_{0I_SsQs-juNl2^P9>b(Xx-5`d8xoi>`!-QuAlrJM?Y( zer42;W1h zmV1%%(+)o!DN!6`<|z$ju8mIPa>@35FG&Ttt%KI?3J6$soKyHhOpviyEN?i{R+qY# z@?`1CC|es{p*zOBY|uFCy*ypPrRVZA<03J2S+a%+4;^!x@BO3wLgFaz>!Taz$8tAOD(O+x-+C!?#N*qvhV50W#S$A0f#ZE zGd#MQRHjIw_N*k6@9BaNPyp|slQ6|?Xw%8+Nghu)gzm0bb@Y7i#?akeY5-V-rGdfk zN)R1_ovJ#5=&l#5Vtlz?HbvIZ+jIfwK!+~70K{+;7kX|y854s!>odgU;MLd{uDIXh z#d1V^R9jbs0U9eTsly+Gmd#NS)Zr)Xh39rp^I+=m*HgEg4pkVn2deV_iTs()moY<~ zT5TeIK$Zq)yl{`k!@5=&!ySC-b}RRZz!!7t&fg@b1B)O@o$hiWUMUPkodTLh-L>wo z%ltL-*A@P{#$T_nE1`n!pK-Kxl6K6E6HMsD+?z(VKF&q?qRc0uI@}-PfCS^31Bj>< z8-{Xo0R^KxC5jQNTMB>iGRNN>&O(tUO34&y>5`ZQ zFN*3EA&*UgDfb*bnqSO|74We?=KeAM)L)RGuR2wKtJj?Y#Pu?jInS4B#I$|bRdBm5;FsYa@)a=)=9F44W<+ZWuOEYsP!rJIFJ%+ z4Y&q#hQ?8M@$z(>gV<;)&L2HeYO6bcV}3V@YynGn@v`h>Z7nq6dJ(=LJrrP6cq*)D zL|}GXHK`)c<5h9GB^a%-0{&X{U|r1gT4{{Xh;Csx^t;v~d&5FH1PjdN+a`&8 z$ZpxZ{30BEMW~c`@B)jKDa}?EqXyYxWvxx5&D~<SR;TF)@nQ3FwhVH z3J5Z-QcnbKZl~IO9efUcC$_A~Qi~eZS8jOE7Cnw1a zm~N9_?2i$37GlYu6r!Hn+9t@?VspZ>5qxTd{>$MZE29iY6TNxOa=;b|j*2%W5`?67 zFeB7-Vlo$e0lOPoZ!KDc2RJpAD!u*+35hK=qGTOVsWit+d2KUSDAWLqPR|S`2qBy6 zE@r5~HiV_m2*n6I%wSDntb-uZQHE{z`Uj|PD=?3f300tXimo8 z7>nww`CoT@%VSlQqdRg`}7AF*}YP1O}r<1ZgDn z4ZRf{5yALR%@dJ!cp`8>0Fj&#PC>(+0I>KWoNm!}JWyK6@j!*rk`7a$_k6sz^@)H0 zq2w5u^GMj0d?8s>J5-7LgvB5f^K<-sEF)=cgp{!jNoFfDOO0MK2-T5|E_J_*9aW&G z*(WD~R}&QX&Nx6CG(f-ButD#PBCl^d2_W^kp;0f71ous8yJ!rVp-T*9MRJZGNLo`# z5^6Vf#nQ{Fg_e0^mDu_;Z60BkspC;@#$RKVN~+ThVa7qh>L?RK^MFA0ECB)YYy+Y3 z#{ln>>-fy=5UimHeo~QZcrg1(p{e35V7QJoA9Kg;>g9M9pG}Vf3iwk3%O&O>p|!n< zzuPS5ud$s)ob}UKp@%rYSj^kPyS1k$T1%ZmY*k1jE(*1VwhP6pXoYf&W~tCFU#K}O zv@e!Q6C)rjc3B4Kd?%v|8t|xw3kuJY9EM;i-#GOZoGj~~&sn!^qN9EjG7;t~LeQ%p zJ9?3dHSfY6Jd|$U`iWu=2(?$NG+76Wjq86B(`DYvB%vdQn26*w?e6#)FPtTq0UHY~TzQt%oQu8!}qkA5=+ z#i6+UH^U-Q-#5GSWz+exnI=6fi>VKpgy_lo2zBS^56HI{Ba4V!T7|nkm?))!y7Rs8 zOO=%;qby5}6OJvCaB5;hY#8VQ0v#i&OY!=Kfqnp}O58J~y7T9QWJ>b^6esZ-vkRGa zVfz*zhd)kAWIv-~a z+={hAWSiL&Ta;C$A6QPk;c?v!1K`iKpP6pZasy$|zWpSA`vAH@17)w#rP$>5hqn!A ze>%e&%1pPGIjP&s)0fZQ`JuaS+r<`tQbR=Y#S4x=g?^eWci?I9zE2o-5|jum7E4jCw@wl_`K2vvSqe59HmBJiI6LJZ48 zz@;jM9qcs4H6U{51mg{z^!@QB(=s@l4#k&Ho8= zDxdQK{^pb>=-PZPwjrd|_AnJu#{v~ZIzkf)kV~~%cBxi%;ECp|y1Yx3=_T({S&6??vzlD0@OimZl@pSnyftu08dU$fxQoqBxrVqGB3JEKsiwj& zNm25)av!{{TIAt8t8hwrR-tn9tk#ALFGFFUY6%s+B{Sd6l9Ly;PL$wgg+(hbn{_H$ z`3vKZPDrZ#dMDMc&YiPKmp~3qx{5VRt@@D;zeC`-NCwAoX_66vocPW!0M8^kO!O3< zGq)CA8iHrPp5JQL%2n4E2dZ-^fJr>qH;=K}dyfvt3BfQMJG?qFr$50St|`MSm(CeY zY=0XhRXl$AUuvLaRkvIoGY~p7sxmxZVwAB4?21(6wYn_1!tR^{-cf@&0v@dvyRb6Q zNZV(b2LHwE>}=i97?nbJPP2l`xmi{K#WSWSxza=jLR$su751QBEltB%84Z!Kui@d*1RyZO)Uyf#2C!ATWNV)y zB2(8I$w!%=w7_r5jEyHY0CpLQS{`B}m$w$rAZ0~}059MKXI&1>7Ud2o^r4IovgNW0 z0U%54kY%vILNZwjRN1p$ov~rkFdjSLz@vfP(5?Wqwh31^%_)&Y z?Wau?&k_^yMGjR8%vJKJ*R0vBm#uHJeroQ$mML8!0@cvr0zzW{I@$w!7Z%yU*A;-m zu1dvFO*8vMmk9_+1}BeccDO>8S`5_Sp+k3l>l1(al_l>3kZADG7rwmuJ!pu`s<{R* z8lX6#Qi89Em>mTccGj7_+p^6z+xNGBu-P+sFq&=l@|VqX;_3WbG;I6oh<%Xh-<*|V zJ%f9HFPc5f_a1%UfA^aY_q|WwXMgL%hhA}J( zk1@e5Y;h$As5}^rGmI7}7U$O}=mJyYM*z|6Bj8MPP)5RqL6o#T7>zLnfgqp@(N8sK zIxr_%j0Dj~elJ4RgrKV80bl{(o9s9wcZ{GR370W#li*P|j_%x9n6gu(PjOrJC%pN~?hADyj(U_Q5ikHK!g+W1ST)QV<$t%iY|3fKUUa^7) zh=p1U%`1odPF}e#WlUl1c9lo2*V16b+D7$>+YKU>Hx3{haVqavTzKNR^PV{FyeE!3 z?}^haF`l>>ZbF~cOkwPW(RCIAA3{Y}GRy(iP+BrN3h@HKfFn5sh;XbJZfFz0&2H}8 zUP2M3ky`UVU5s~I29d(q=jPKRVsn>PsY?`f;aQ}pl~LA=soOjC00N^qPMF;~YE2cX z@0#W7atJ~--wkw%d(xeZ1=pnD`s)gi<0Ym&Fk^H5sZQG`0OgNxC`BuExc<~&^*P>H zQgoG?DtlTIC9r3pLBj#FGGLIp$PN#}oRal=l)1VM4srtq;>p*TX#h?dMC2HzQGBxi zc9T*(!r6a4ARLgvr?qr$bMiG=?*h$nQ1eCcB_^oY=$cwGj!&qV15;~FIN4D`)1|6? zEiP17H+h9LmGseMwMGW+CXF?l%Xe3|haQGeu`kXEZd+r9S-X^@Z(HMxqjrw@`|&W~ z0E}oFgdw^;t*{BZ_ZIF|YopT`v{Ms}=+uqnkt%d!H=9PJB?B#g88**d$Gp0q2!tqP zTGalc6PKV^ISirySE2JY+U{o|j9wBk6mVZcwS%bG>`tKI(MXCvHj!|NLFDymhKx;F z*PeBbp=6!%nr@8COTMA_dPy`E=u?2E9dN0kV8cn^#oc+tpe9R}NR3wbpLww4ExTiC zyJOLgv-1%a%^)?OGo4+qXzo0V=FYQd?mUYY{b~MRf`WZ=jQ2`Ehmn*DX($;i8a^wA zrJcE88OYQ|1bCdP9P!iz1Vm!`ip_n*z62<`0>*)0FRd;1(m|sQuL%U@;3TT#Py|hA z&~B;3ay#so$luR?1L%jeU#mY@xY9$t)%;atV7EkrM*^IWkIV(?g^DpZu^0&}i?q#1 z_ih@}wR_TRgk9UgqnQSW`{>tkEu7N{mxYQ2PcmqmQjiT*aI;Zsp7}T#p}X@#cfQ)q z&c*J!o#UJ;W9)B%BMqHM({b9r9FpKpdxKlE++r)+E`@e*LRx4C6(M=R^%-;nmbDi5 zyT+Ch2^`SePSvwusv2(%yfd|}hCx||4(4pZ4{{YDId|Er4@ndwMrjeT2r&lv*ir=% za_5PVJ5Pk%c_Nh2Ct4yeM2PQZcbXCWXa5)q1FNma6BY3)i#P-dvfN%Q@I1URe{ zKFC279DIP0RyLsUBU$()=~Mfa9yiDH5(BX+%URaCYQX}jtx})r0l5B1wtGytW4{h zhA{z(1|=$mX@-PUViV{{4iKAQ#wjagh88ntz<0KyAhq5bGeN(Pt^;=BDkWAMRI6Ee z8l2yvb6i+PH=RY3&brmqJVpl#Msj!Fo}Zv+956wztUEQKCQ8!;y{%=fqRVeLrwb&& zCf@D)XSjE<8rA$s?#!ISyoX-urb7 z;Xh*R8wucQVP}Y!d9;C;zmX?}^5~Dsv+eXq(qw_z^EnR2p!dVG3Qy-T zDRT3ioRY08Bjky8rpAVHPuZ@#y1VvdTxiDKFtCLoYe;-p6gP}XQQX*0a`tII8RLgg z4Ds6y%!jO7vD%=;$7(}YjHX7C!#GS3Nst;e&RwqxL(H~svE!}A&-Bs9YOiGjl%)L(H6czHP;|67JUAlY7jdI zl^XPi?FMnA+u^%qk!#Q**PunNL5mLCAe!8dGt&-WrFjwkwMfm2bqTTcNKdqY*QlQs zbu{ZU-SHw9k;O#pvSuxB!rh$_ju*DxTqN7o;nG6X2(Ua7ostE zE4CDT)vJ-j=@OP}5)+|hL08|m^&aaKyE68g>MRV1F(Pm$sGBb>PHZ@SJ4$;VWJE{Xw>11vy;ZHS^+>*ISX!H5b zk<8b!S(w*Hf@DTLaM@ss>1alGOM{Y6h6trlR zRA!~)YD9yXX=Cej6udseyIRI+L^uyMjoe*j>KY{B@n)NAWJ zKS{f!+k6j@tmpxG)vZDeMnPaoE-BC}9t)NHLt<;;^BT+f^9J0!p{~(*OxESnoa5aY zs$N1<^MfqhvB{Den+q`2Ax8{n+u~5vG)Lk9b!WL9vP}lajq6SbKp#eTv~X{0tp8$k z8t0jjpiH-F{^crIKGM zpN&)9Y6gvWkNi&mXnx>xZ`{EB?|y>&DlD)xUD+DUQ%XJgceKC<>GY}c%3+N3?Uh>i|6w?b*I>J54?`w z99~y(ypHlTHo%h`Po2E3QsQ-$60ehJDe*c;n6c!IUoi=xTR3*?jB%SK%Nh2@&giDV z&SGO{3|(c8N1*_cLC|WXc)XP%H-vGQ)WRb#jKB!JOn9WciY%xNkAIT5PVcqm*s^r$ zWoAT&mVu0KF-_95yP4(HNo6nH%`77*2?11{htyoB^}G2o)w8QE-?W zcJmit3k^@agsnccsexu68!-h^t80t+2jx(MI8!#D@tQ|y4Gd`=BlToq11Or#p1v$r zT-4=!HYOBNjfEn>*1{aBvEHIw*uP-KL2E%;6{$3=Ig`~TDXXuNI&dit_?rYI1PN0z zkd1AXr>L4FW4>bwodq7|1%x+4@@E91St2CaRr^AcRNY?I1XALu$j`Ik6=~k`W}{by zLxBShzeO2V{GgxUBf)Ib<~KFHccd9I`0J>|R(`mNtxWT*!iAfV1zn6|WLnRIRQI*W zg7hc@{wXM!s^q;e;HERjNp!f9CbZ@|c5F0KgzrsY2TsT?;HVl~YP2K5wZhZ?x2ui(6_6YBRUglmaa-is`?F zmYUK8cm&>*62#sVU0}5-u?IH8#L(AtmS0wix~$a?%fxUMaJ#hWHfzBDL))>KT&wgI znq&AY_37rWf&xG=Z>(FN5OU&98bAYcAD<;kbneH7i6&{X*tvA9!bEGomxML#lx{1t zXQk{wckA4LDlfwSfs;g_&EKF3ddAFfw5|zrM@AbJdB|fUXo}KIc&?y@GC& znszb(VIbyD;@bVO{1{+C3<*__Sr**X9D#r`$m&eP7nI9;DRZYsd3O>~G-eYM6e5Qd43;69Nsp7S+8p6rRV9v9H}@c`zNkj~f7NQWtLgb< zon%!cNa%k`F{!5`qYWnN_L3_RuS>k?U{eUl_q6t_61FM?mbzGy5E>F4cQh79sQZ#J z$xl_pLsFRl>XKL_^heD{EV&k->Z|!ZYCiHbp?E~AVr#&i;^y%n$s?^m0I?hdYc4FX zU3>3nzD$dxn2CllP!%#W>&2oF4HI=a?KTFoJaA|5hIy}A1+x_kvQ2`+mdPXZ`mlj= zY6Ok2445YH=`oS4^Mph-uZ=r34{xpWF&2ruSfe(m!ZvO!B`L)`w ze4r~r{o5baKE8Npdb+h^=X5qbkqvF$oZUJyy)B#A-J0AoHgW6K6C>lBTjLWuhIUNM zj88|^$o-4Cbn)xv*Tb)uU-?@f&ozGi{08_f;X8lM^( zo*tPPAD$TJX?S{DYh>%T>FJRjt>JA$BjdM>Y@TWX(Bzhx@y$~}JK36=5`?!64~>nr zHfI}eY)#FKO|M-$Gk)vj(9RX-Z_Fmfv!U^99)@?f{Ca0%XO-@BoT#tU3IzGxzcnHsY>3IHz ze^zP3GgH$OJ2nlCj}G#C$JEwMGn3wk+&nbh zav$vLj*+dCycuuZddu*{<`!t&F|~DMd}?}Ve0qcr{^i)vrq)>Nw$|{>bnB*>P1LY; zXzG@+ksTw`H@0?;?YUumyai!Q%?uBN_txa(#N^P}twVdJCPvpoL3`HkZjDb*@7dXc zq$Wo;QOZ;v?nYaC4EuD@&Iy`BLF3a?SNnc`52e!WD!kPDw~UN$nTSpSH=?5ozf<|0 z#%~$Fq3o?AQ#;3o_GBYFc8;}nP~MPeC!1_dgE6Rqem5YqnQ{80H9XzgJhrEU_D-jq z)srB6c=cshZn<*!;)^$5e&O&HmtVML_`=JEhA+9~(u*#<@S-a&9KNh|`Ow9ethw@% zi&u}0Y?>T`I-t0TVe4>+Wn_G-^> zYx-&psDOe>v-|~f-DeR7QNM{y@{*nc;f{bd~LFo4e=YFaCu+|A>B^WiOx6A z>>L{zruRdsyt|KY;-7Qt-90op!dT8W^6d$qCe$}F&cGYloV|NweEPCWvh&W%R%XwW zM!fhXu4-#J4fLL!$Gb|Gt1G0L85=X2bQ~I%GihT^Oft}k4S~0iPrUvTe&TtMTWfk) z{AX&_$i&(mdsf{S#{y6H9K0<+a@-H!q()l2FAO`hh}&)Ir3wz&6M%8lquW^ z@A|iwXZ6)(Ts6)%`sb}J4K+!sD0*HQM4jlMAD)(uJj z_{@%$ng|AtBu~EyOp*s{_z7B*<@m`QwZa3`v{Wy)2mAH??O9t)*am zH`ycX>`jL4a6 z4WYDb8f#?|uWK_#cyHbMqNg?Wjm~q4~bwPhUy17)>1JqS+ z`=@v=!}=J{YU>T?iLy?zTer2w+a!g2o|u_7AZE5~X-#^XYq#ZJk~b^Ww<>X#$c7*x zZ@%UV@k&_*8s``Ddo78xg_^!uB7$Wk9rA1IA3<#(C?op^f#r=DXCO`&(AmCGDjx~Lxg z2=$2m1w;8+I0(;IaxV@4>Y?%RiD~rtq0N~urs&gsl%;Y)9*t?y#?5d4{SyNyAm6CMWk~TP7y0a5Gb}`$iZDtw#3VR<;d*q{Otw zFtA%zF1*Afwb_s2ELUS?%iz5r+c7jML{D!6p*v8-vZ)CvwiDy63@bGAwMrR^+h3>?sG^RBE^bE>Xs z<(QY#Z9Svo#JC2>JX!#L(HQp(Cn!&pTEvJ*jT(4LIq6u}DsZ=QsFg&ugz6 zn%Z{F#N-YJ!7*16O;gABm&$yLFB9Jm=oD|wE<*8QYjGdi0$}|Kt)G?Iczb88@?lq^s9k8OwJtjmpQ^yYhvuI5G z)5C(5hWknUMW6)G_ZEP>{FmO4E#$i+!?I7IHAZ0FGA5SALl zE4!)SV~*pkMGX+kxe&u5BfsQH$Uil*b$ke)43?~Q`9{8rzlZPJAO`;_n&q4H7Y`F% zYfzcrsyx0#2R{Fe9=vx6I{)sbP^BX>|F%ta=>Fc>6cl&L`$y_lAHQ{E_XxDKX;1cJ zt;vbC*|Jld%nW)5D2mqbPF_w&dpN^JGz5)3;j_q;Bzh}pU*JTk-WE z-=yP&Z+Hub7%)GEY8O=dH)ojnGecu*-J#LszuwC?!P)Mt&;wIQsNq(b9^OPc z*KdP+eu!Qxe|t0ELeBF0t9XBt@3|Ho=}NsteS)V7a+=axMw8qMdi&0a>1)(2h@s6M z5$~Sfa)rOWu63Kgdn*XN348`@Qct;FjXQ^4pWY$UqmC*)vfgF5;(1Q~bv&2xr4;4z z#m8>iHg?mt$#+fM`i_|~e7X7N&7N|cGHzq_8>iLHga1vg^5*{|SMia6E6SaioY*PH z2EEeRhS!nKK8tAt|ef#%ZHS6&$uHsYPbuO{m61oBa9xmU(B72;9rkFV%IDC5Dd?y{_h4Sv^y>yAe zq3PjmZXiVW^RC7_Uzj5c$Ji{H@FE@LcS$Eca|2iP<6qIAFYxnF*0)ZwAYNvC4%7}~k2$SAGz)@}I0rgoyF zW^zf4i3j5N(DV(iu~L~<+$tMD)QB2{0yhKbTTy>d9Jh_oV6+!_5NfQdwQ8iH^Hw^D zw0JY2HcKyr_pQ8Q)eW1rOCuFek?bWEtjzi21MX+gkE9#e9~0E8!Y2*taE}Xb6Ot`F zwx))M;LTH_FI0(D>-`LZQ$LFa3KA2z)NAm%R<={4HH(pCEhdsc?ohUIdUB?P7iHs? zp|L65NEOUBN>*y!ZmrxtrD33nz%{EbUA4wLqE<8OWHe;DTF+Va zXcJ@Z4gBO^(Z7;E7yi-d$_?q|gOLA5|4Qi>_7uMpIJP0^^P8^Tuwib4qv#KSLHb`P z`{%irzvVmB{v8vWov)+kb@k{+splMiveCoy2f1&Sp6}#d{^>#I>0mr>F9G+k0Uaqb3vnJxg^FMJf6QlgxC_SGXyD5(FUC-*$@Vs=+v)sO` zO5gQdPCvl2)Pj(|f6n*CbDo#@=eFAvH`b0J#VSnhY&f+xl=Xe2l?oi5zdz*lZb_5H zQ+sx7f{7t5wrr8(3Sb}hqSG9;L)m33H;u@l<{?=X9VCxj zoCsNXh%s4z)9QA6U4pr-o`=BiAv9cd=+JS}|630I-$Vbj{?J>Fv;Bwuxwn7WIrZq-*Vm)_ z_`Q$cGJek@qu+NvzZLw><99Bno;S)vfIjib?{hAf z3o>*h?&acmn5%T1a5ZCiWBd78zRRT*zMr@f;!He3l$b%dGMIMGV!*wJQwN1=C$lNT z(JRy`o#aItCO7g8{M0`E-o@_+_}$2l$r_7Qy%vyE7BEg!4uoc)=F8v3A# zEtz-tZo${m+KdnSQ*W%BN%G9iHFppKs!w zTx-J9&HRM7KpVp6d-%y=rSI?M_db5*G(X6*ra|;h|3nu*%ZVh%{ZW~B>}S;|%I?4ljgL5KVthRp_Bbk0#D zQw>J48qBhv=EJgO$24&4qb~K`X6h17&!3+VfW0Mqem1pjVunCPTt;ttvuw3&1;+Ho zq3Mko5wj4i#Z22v%6gTuPvQFKTu3p{;_V6@nw8 z*vex-oT&q`*2jpDe&;^$+0OJ=_s*Gf&z|r5_MGp0=i76>@7vuV3{pYQg`_OykTn$;{XPgUrV_5_ctfzWl1qG_5( z^J+fLuLU$+Gqj)<@@O6ivG({peow%odkjy|6Y^?akJsz)_I z=kxh}0iW(Od_iBxulYTGuixi~KyAP7H~c|=D4+#A0dK$;@CO0`JzxZafsn509^I?^ zbiW?Zb=}Z|ddScWkKr|ZhTjMnx?vbWBNWtvo}f4A3;KhBpdK`W!C)u^O$@>1LqIwN zXdyT?lSRKrJykI!99GL_gC$$7QavHi^YMOPfB|57fsIFkXA9x~9gx_Z_)*ryZBeT{ zG2ShO$}_$t8N3W?ct;L!?@{+OXUCUz`V ziV0|}hRv@i33e(TtM?_)V6v!qlcHw27$iK15EtALaGptMqCSQnqyCK#Ix6je6m>{* zt$@SYe<$Qjr=b7y!Tsc|55e%}!~gXl-#aKf;B&$k0rg_)G?&XYJ!&|Ka~5XwcV<81 zX*&cl`(kdK&5$!5d>x;+vmk_E0aMhBwI%FNY0SLB7|OgUfZGo^?B4zX%LC$!e zpz)3KgLx)mS_gvhD^;cvnJs1!^JuFjvGBaoXp0i{N0rnbs^@lHKZ{NhCRWh@6JfX$Hz9SzI#;jX0Vs!#oIZbHz~-!}@8~pppWT1p;E9t1pRBld<(91n z4jy{-*s1sH9)0P}!$*(RH;$juGNbMOHEZ`i_x!;>AAa?uGcA2u>*rrw8#L$N@xf_( z{(`QY+_q)+?B28d#rTfNBdOSZ>GFauW8|pOHS5+l|7`JVNBWPy``*QC zgPhtnwC6PK86#y=!5MkVZtmjqzTbt>!yfR^A-s&C}L@ZX|{rX-zTzD4B2YN=7A7 zgrHO_S%q#(9+^s8WOGGEj*=!fQ1by{*A{C!_4LumsUp$J^XAs1$Y&x_%LJ%hP0a%& zn>cKofZ)A46!W5pB}v8#Z^3q&gq%2;AL2|wsW=^H+H&|@DIXQ0dGt2ChwR1s@iBZH zzimAszk^TWQ|JtT7GI4Gu7|?gcf9+a zY^+HiWUqa8=bYOXEm^kw zfh{}tJoBgi-Fp^v9e8NQ(4{<~!^s?i+%B^xmv|gGv{26D%lR?XUS{qT3TYuNk^Gj% z8zY9Crbro;H6b!vlC?B=s)KYK@1}|*tF=&WWUvEfUp_nk8N ziHi}R1LX>KDn(Y^PjBOGL>7}CY#%Fkk1#)17D)?JYwu=LVTzn--WM55?j7w&?QO~z z1oK2WUsZq>4kuX@N2>FkVID>L%X&UEzbI{>3dJj&V;V-9e;FYlI*HHrF*w)<@-8;0wYU8_W zq;9}r3)vM^<<|4<-1H%vx#V;;->SCfU#{3(UZ$xPU0cso;O*_h^RBeJxNEAuX|P?t ziq7gtDKH9cXN_Im15F z0H73{208_xfwqK1qToDK3Ak3kECKRBmGGc)L~MytWle&MVph(rI$Jsy+A;XT~io69C%4iNn0yGL|VoH+WYu^|P2s~MYBe^&ae%0_4 zw}h}oMxe{lVmuW6oKP$yfxHh)fYyqPB9;UNBQ4)UH7N6_1U`YJLMIUkLM0%Qu!QlW z1l|!QvI`P?xSB&R7jR@XYF9a7F6Q79Y$|TTaMy>nXJQ_0z*)&QR3v3uTttJuVO)%E z1kPi4id;f& z;eSBe1jw`TB#E7w$M^xYodgDz=VXLGgOLY`KI5dh*fb*OSr^DhITq=@;#XR~j;SB1PkR7G* z$N^NHQHp#A+6*`&DR4lXFLLeX0NB;y^Ol9rGFw6sB(`>Ac_MjXZJG+{GVDQ*Kzh=Z F^l!75ZlwSK literal 129231 zcmeFa3%Fh9S>L%X`*zMg=Vc_ipeJ3N?edAs4eaEg_ z-DtM)CozT>^$w*7iwR@dz-tTns$^PVI-bq?1o%ARK?Az*q{}>8m9dsB&+F8{}lU67)p~1A$ zcDj;rrBkhTN5zv?_|NK6!2Z(+5?bx41Y^lFT20c7p?5X%ZkBgjDgRciUCj(BGDXel z&P3K~Wr@u#&)29C|1Zn4<*jylSGs3Uo9Qj@T$1li%YFM!B>lZfdHnsKuYbGmndrRh z)_1*o_xrM>fBT*9*>m%qdu|tbT-m+#-do@KUar2SZD>e#^lrZ6j(5LPFW)zL%dOST z_pZGC&ONv8{_dOKd8;t_p4;Dj=Z)Kv@0+~wM(FJ38*jbymOSm>c;jui-h9`M@3{Fr zx8~WzW6ZNm`|o+pe@(ycU!HhQw(g)KIqzBTkfBlx%zHak3 z{zCQ*52bJa$N%K5ui5nv|LNQQ(f_pRJ-fgD_3!+jU-yn%{w%$E?#7$H>!z#T{O#Aj z<=d|Lj@KMaH~m=pqv_mh&ZIw=eKvi~re98HnG@Pk$@@?et%#Pp4o1 zE9u;(*Ztq=e@dTA|0w;#^o4X^_Wta@rAM+&f0gdfek41X9m{?+`?2iDv(IF|m`%R) zC!J4b-#?jk_ony1Iw=pPyGHGeNs-QG$*`O4DAFyUV@J^~d-HnKnM(UbcQ)&ddOU0C z*;RU7^vZOw%-#%pl+gYBsB?KnG0GIZ`Ev6WNzyOUGPxpYS=~`jZ#rJTWWcao^21)X_wpQ%QJ9N z*=D|j`N5#7W<|FTnWk!AX>)Lb$VCtUzBg(ys)`^|W~U+Q&9FrY-OrD54N_<-TJ<0y zh%2q`XhLst5d*e)(5SZ#GFT z2d{lbTfYDOCz97ChG(?~l`zD*H6szVCK6fDS{dj=^_)1`bIG>s2H-k*d3JpT)KkfP z`ON+k$>2~{bT;J>HDlMWp=asJP#nHz4>*j6Q z2E7`nl+BdVJ&+ynDYEOMzzV|S_D_6A*QLp74x?V3s3L2B!bq_*7$sm-&+Qd@N!Qd?p|OkQvH-y{l9ziFuDLN5o$MmS`jyihNl03+R*sZ#u340mDrk;Zllf^Vjd-ir$ znMrJ_cBMy|Tc|qfl%IT{5|e^y`DyM^Y*Ni?Ew>?xI$gQ8f^t=ZLemn%324$A6*4rn z0b-F2-V0h`=Ul{8Fj{_Q!I*wGO1Mh~2K4c09DRoNb`yOj5m$}63(?nYqOV6TsYhIzUF%03l%?uoY@K=fKHq*${X*t0l*7d{fnqtBybA(aH@gA}9POsM3e>Rn> z^9EbxNRU{`&|5Tm_4JylwJ>>kxKa18*F|q_Nj{o-1%Zx&p(kd@<;Q@`Y<4;wnw0oL zDmct$&!*VM{60gk`aMN!*bPMrQt0#h=4V>j^5w1N{VYr!BTNsI4A-{LR3E?`E8Bx# z&X{O2rAM2RWbP0C!{?HXeXxt)5DOH{)6~^(n?$O)(7gJliX#c22KSqc&0S_mcrXSTw7zhPrZD zK@|lZG%5&;G)b*3$&WS}iARANFyXj#26~7#%Y8fmGzU`LB4?j{v9V-0S!S{!Y3}_{ zjM%4x-klt03@2@Dbt8XFb|e3ecp{KLfUsKzH~?1Mrp^UtaLQu0_cmk!CFt{gazu=c z;4NbXYL_bmhfQ5N)faqTXtZ%xqYb^>lH6Uh1P?;DVu`e7i4_7sgC(daT9KxYEYZId ziPdqg=w3aY!v~Lx^16^dR<{{!sJKqCqU=hqFMQ2B!PVO`$x+IEitrps6 zrlv*XLa_^{_*OK2D3ct8E6h4afy>Z*Cf$}jl&P9iOA56}z-sWL7W867xIb2f9b`#V zRlf`w6c`t0%$~~2GX|YCs(%J*yJ{LoA@;m4lP6?`Ej{OFyk}9I1`AL{r{&>nKHD4m zpQMGz1iW9X$H001di<6Gz=y)etD2NPWj|; z>41q*h(5Wg3V{MD;}wD}5Z5Fz^OH(wNRgH<(~X6*G^! zir*Yym&gkRd`XeWzFX;UH_R8){tSP!=T{hgs}`CEZA{;}#6{ORrdY#Avdy)rlYk_g zQ_N|A9(CkR4bENxXtyLcHw*=y1o`%?)p7aucHyeTomaze8?}ObyFN4}qn*Y~SQf_IrKlU_e?6%9mc94NtLk3<#*hjZP26EeS8F-TM#i3oJp-sah zTas&QJ0J^oKslfZr0aSHj_%48gNQYESWTFAOH$S%Pj-j*A|7bfA`hxFHmnq@?#Hcw zwQdDu<$d!r?bga{Wp`y|1|VI!_B_oK0>tv?4@w+%WC;L7i!BhgDPR0Izx?UW)u@3~ z#zEVRgHu27um9*ze&>nj%s9wo9MC`p#kWQAGk9cO(6V|i{m$vhVvT-K%+nLjP8e(D zPoA&NpBjyi44$-RjVv(y!kCxT$u{1`6tE6#ERs%=%OBPtT7xC)_GOqFJZl4C`4ZDd zI`yJ#jI&y@!Nu(ro$2Kw)~Q#C5KtpvH%k2jnOO<6yj<$xp-l36xg0kW<1YVQwmMmu zP?qgyg2V`eR>#c4o~ak75%pNxXybHbV|t}Zc+*Y0#kqQWP43$RC(8UMoB{2=v8G)f z1lsl4xdnS5a|@Nx9m*Um2VrDacMoNiNolUfx_Xi(Ee~gdbwwscY(A-`XtNe^`P3AJ zGmScwwsrYs&#LKoPbk((Od&!e7jA7#DC?Kg8kqiRYOg2y^bfI}TS=l2QC7ZXUh<%v zxEA)1$qpB2!gHyKpOrF`0sxT5t-(*F)VY5C@wu1M2Zk$EO0909)$2n;*U19dk`OjT zi1Z0ahw2FIm2=75 zcDK2>=uMg4p)K1Le-I|RIFAbTR zaZX`+LP40Gp@8Y7Q`nzVm|io(Y-*yWHh|wXk}LX;5Ahm?(>3hf=n%qc*e@#v!Kz*+ zSPl5&IH=)1F}N_ex0!^QFhIu)#?*nHG=MJlbKzqkL~M98M6S|em`v})N!^VEbMw$h zv*`FI;P2xSR5=grAtuDz`vcC&*a^b3Ad0Gk7txIsLUf zoBb0ROXdo$?PIYwW7!~M%I1!^b~)SMBHNNk#kO1rareeiUVdWl{LHIcX$Op-{l9kF zK}Y4~cg@fAvn2l4HoXOJq^6BrcwlDG^29Jl;pFA!tN8Q#$yK}g!BpKn-K8+$JJw}F zopi`*3bANs0Rr-+R`8~fBG^;9LWpD{3JVNSQp#l~Yi?XF$2?GY%32Ig8FoQdzG&-D zYFQ*8nZeW9><+k&pW9?Jba25LYf`Qbo%j`2Zjr-L)3o~eRN5(%*AqK0tn-dKAC|vI z3@*+`%WkOxDYU;%9jnL&N?(!Oq9u{bvzus1eq*NfwZY|B0hC}U$az4;_3erQjFpKc z(4`s&&df+tB1{q}T;-XdeDM5wo1r=Q(}+E9C>9`3lQ3VKmz<*rD_=LIy-nF2 zqqbVJwGvxRWm(d=Ox&Ny4$0&vMv$11GtEL8HjR8Rtfznw?34(S*$9%&X9vj}&I2TG zxM+|V1l@1P`4$x{0Ex}(;y^;%Nh#$e)e|5L3IYLRxhAC|60#h91*(BU31g8*QecK& zE@7tNOCmEN)JJQC`snSfl!J(d2sLS z5SjX$S=tUuEhd7D90+-_R_6bNC^5CmgH)WFM#3ieL3Qq>*h!`6XXLX)_Ka1Vd1W*I&C`Vh) zgUk*7f}$BEh8oelmez9_#s)@pz#y&)_-k;S{wes z%r))lvuIigK2}YBUbA=0T6Q7kmG>mt!B|Ikn^mGB%dbdYi?n4=LFwAR{6cjpb$ul- zpZJi}^>(h9-VLUtiHlsGU1OK8ab;-0Qih#sABPq;S-k&oTi9@xtl(+ejFP~MRxN}$ z3GaF#M12d)x(xQ2V}WR&L0CZ54glR)8C@o3z_zeW@2)KM1<1T^47uD{TB|W~TMl4Nh zYKo=NMp#%gZ5^tksHx7R(9=~=A{GtZF>|`}z{H6V!+tUyS~TH!SYmr3r3XNJ3^ZLu zK+7m_LaS(5D_c=T)QU-alqQIpR{3*PFb$a}>C-BY>XEIqA!NabR@5et3@uTbR@4YE z5iCad*%Fo`CDsydz=_1{B$rS6r9x_8Oiyh!(1tqLIlZQsk}0%id?d&)+Q;cKgohC- zS`}JT!=W_;0IgZ8$5I3F3WbE5)4(EWGk$L_%4+KI(*l znDxi7B^SJ**GIX~(_H3~;d*{2_(|~Bv zanYPTu;;zQAdZLLw=oXKhNIEKg^t4zrgfyny+>7_Ps`SoJe3C_I!AUgm?gusu$dN! zne-!RVcQMz@(APU4mRlF5u(icJ(>=I`Wja1+IzH#kmcI}vKFzoUZKAf53E?Ov9lZD z@nY@cbH#)Ewfh#Lf4rCox5yw^DyI=PZetEh8RF7ZdTEHZW0VB~bXtK}W}sm?AQ?%p z7tpiBC3xj9yozv3gq~R>iwuV@6V$+IzRf^~ne+$_zi@7%q6dbtVE%5u;;Vz6Nr(BUGBC=S#XN{k)c48Jgz7%(B3Rh)MC z%1v$2w1DbCYPJo@pCL3m#bE z7(2)C6)$v79XAGjwNcV5bD@aBM#GP3K_c94nO}`QZ3x1tVOoU6!@6gaMbbo0A$_xP z5EJd`NjTRRMV9YGckWi4QJR%^Nc|oT!Lp%@L*q>j*cjD{xZBJyPXJ%YEklZVi_;;dQ`keuz&XLmRu-Pan1ZR`$)#e!^Qu_~;2 ztd!tcbSEm3JF@ZFR`(-GnJplq6 z3@VTQE5R4W?=ZfxJn|BRn~gNxy^m=ML;7AVw*EqNSEp-R?Fe)PbJ zq%4>v@Ec$zC2<|=w8g|ek}VO-VZIhOr4|rP0mGvqmeX@9AsLV5415O-=8a5Ji|p31 zor&{^?L2#au^k<8`Dz7rPIDNs4i+M~F_09>Ug~THfG={+W)MnYd@Z|r>7|#x^==Lp zmH8ggk66X_G{u(KDlK9EFf_uTGG${oiJSVCoHR;gkF3QHXXt z3IT?$NG`Lw7kU(e{dJ+yq&f=GeX|C~i=Gac*a%J55(J!|`;*`P-#_+|=l}gL{duwt zc&fV2p&7&f&CWh>D6WNd<9LCxQDPF^IcE!Na4KZ!@Ef+W9R^MuYzHv9r?r<6X{qy$ zc?`m~BK_Dqt(~@x1-`X2eUc{j`K7jWKo5$rPdOD$)!?T&1Hax3Atbvu(&34bl%GTK z0Z)N-4QQ!Jx+?*63ltkTXb&FVc0H~bD%=da84AwbmS23R0eZVTLPE34)2tJ)+@UZaDy0q0gVh-RY4AqGRC8|DWybs@SE6YBwuZb|MK9P#L5 z7}CF8Jfw;97?Q_Vd`MMq#kAs1erVv|^Z* z4*{r2Cn%9gR!o|Sy5F{tW)^|X%7hIc>%`>g@qUp#nDI1mwAgq6eTchAzGp#&J6I&6MDbOzeRQ>e_O*+O- zcv(9B3ssw@;csuy@mYvw(kLc~yYfNV9#dl-b}zQWt8iGnUFWVJQ`^!rZ+rPsLC3f` zaa12s&Fuu;xyFOfqn&?Lez&4N73p53eOC3`a>Wm;WIKxccj(h%kE zk^K!FWoMi)+R7ByD_p@eAMNNb113U(pS>L?1{}~VNNV*VV;6I zIoKipN_i&AXSok-u9-|+w1o*qVDlBMC{+yJ9%FE~z@duh3iklgX-na9z7YRP!pR&_ z!AXwj0!w`EKmYdU|KP)a_B+4wrv@ki2BCV9rZ<2oF||2)(-J`kj)OWXGG>q1HQQh~ z#X*9N`6UUF&frlyXb>MhuZL|tWGOE`{6jtL>Y=sn*2d{rvIe(d z!|u{12q{!VkL5JU!I;F*GDS7Z1P`%qry@L)35aC_YtzVPIXYEH=am)GZ4{f&B62pG zO*orvwfGVG^fHP^b=s=bsgTxCr+-I*3`>QhK!#G`h>_(pn>tm_i1JhWD|OnDI{gLi zLn<6O)}+Gu3dJ=xjKwuJnv(5U&ZG!**8m~1(F>+(rk$z5fN2#S3vP7Eb;LG^P46VI zVf3Y#Mvp*-&f9?t*hDEcS~d8oYSxI}D5ZwoTOdO$RVUPNYHc;#2c5dFwBnV~n9{a4 zFRN|SvblzJ)=f)Wd+8`E$dkb%bTp{wKMHeBK(xeN^E`o5b!(y37*Df%}NVA2Moqj|@ z#S$Stx2w!!kgc_tHp}OJ{r~(>M=6@r3YClwW2TZ|)?H9y5oMe*Ur@5gj5-rfLPD>p zt$WckG{;UTNXbUx*tQt!zI2p|BoCw^qOjjKEc(iQP#f-bo?U_j1PJ_xJ2y76P^vfLMj{+wy~g9_G^F2N6jBmkdbe zG=OI8P*kQBeYVK{WhZO<;g3^c!?1W`*v2qgkTc4(8InWdbSwtz;#6-WPUV0w4Ole9 zU>9a6vQTU-Jxnl&=bh#)jLQfVx~)U8wlQ=8-%q&J*eWNfZG(m&CE2KoHv0f_I9QF! zuU7sD_d%PfwaL(0m`M>c6lplkL{fE|(M7b3LNP-Tm_S;>lRI`XbK}Hj_CIOY9UdKI zG;xq(YQ@&NhlO0@0#2(RlJX2*cL~F}T#ZX)s!6R~^1C3QRargHeG&N~J@VrG0I? z&{0-5+Nj2UIy_0au-0dw9q*DHaBSD!EQ2#INk1n5EMR4pQ>@SiFLbt1R}EAd=4?Wq zVJ_E(F?GOPJ;R*6+%RG%XRm0=t)Ao-E7w}y4Hgupw0JMevMOC08`MR`lH_A)6MdmV zZ?x(nt?3JPqWF3t&$gqdWiYox1QmNm@)*oqOvARC=k1EfOzQNc<-A$88=Xh9iLXU3 z9=2&CfnN(|{PFy1Ch6H}ul#D9KuN~n=qFI@oS;PTMO9Qat+Mw2Dy$%X)s6=I>;)bT z2q`e2eofRF3ZV?~C-F3Z$pYzv3qK9;`%~$R7SMI#&(8vwK6s{CN{9ufTh=KWthSQXYum${$Ww{PDI z`2w6vaO?PlZ|_4uDK2TpG5yTKth2Yav!z4WH5^W7h%L_QN<6Szx7vs7PY?&bxz}td zZiwVFwE`O&4&IV%MB39p8)QhR-Ii}OURj?+2q}Evx7ZFlMrg;tG!geDTdB~cJm=?oi=O|}`~9Ev8FmKgTU z(mc7pWY_?kQjS-ZHtyjQIR+q7}4CbZN_H0E82#~ zF%3kGdk*#Z@I1Yj_7;MzuTfQt-=z-MIKzU(BH`6+eJ zDU^%aeIsEtg=+2sLzue_=MF$XhBCB_c6!-nQ9;4l@Ew2FhL1Izh&@XilimiCi~JA~ zeEw)K$O(smkhIPF9KDJRnK~e{lXJe!51S$;69QYokyz$i|7`6kg{XXpfj-Zx7lEnk z*obsuY+xvlEkX#E_+-z}45_<@wpwz>(8P_93h_3unL^@hY$*n8fU&8ceXiECF)@4( z>b4}R%ufP8%l{{H3A)wfw9bA>8nW`ZlQRRB{vd2D7c}G9euY-tIMMk+mT+`H|29C0 z1eT~SU*%x(U25h+Oi1+r^~>}-VLRb+tqY@FKbmJ9w`@pz>LUl z6O*=F;f0$J$G-Z{*Kk8D@)181P11>|Epy4_PiuL7!Q(C8mk#5bUkIhZq zKk8{ee$jiBA;0RqVq0>w$ggZP%(Rnh3VO6$xYxX=E(8waA@)X>@^cu4;WlL>sAdHi z>@X=S%Q%k-H^4+LHy}nBXD$4C9>q0U%?np1N4S~0b|tj?B{mo}HRY*pWH^Lx0B-Lb_ zzJk#$G>E)g#*3lD*RYejCZ(g?!}fGq6UcnWBs{^ ztEO-VD`VKWj2Y!AslwIU^_!V=F_JSW5^Jysp(v5216Kt(WuqGuJT>Fljs<(R=5T0t zyH>eIld?4d3T&ZU(v@&DLCarLa1%8FRN$*gzd~B{?TVb?IeU;=3aG$QKUL*;ChK;` z-MGZ}lX}+euh@D3f+#E1TW#-Tn})IED*eiy8J(Cf)~gk z_~6YN>sApIH7J6wW{nLXqN0VRay;w90@5~vk4u`Spr6=~yRAq%TOv~Y1}=;()tevurPPW!m{0c84oC8=Z<)pF5nZjo0HYbn?qCG4D(e>=bVv&V z#+LAXoYa%c?wj4R9r2$HiP|%*l%+XHP-kq^8d1SEHd_an<1L|iNR6nij%j}^(rbF0F3|Ts%4Kz}r->9jHe&abqzYSuPeg>udTpg&iWmF2oI;!npycu4+XQWaZ zRuT{iYYOV7xgf0QnL}98f}0A$dKmsp}$_13M&)LrnZQ@`rSQ*6{~*RL!uVB?ikkC8G*uU$1X zUM_|Jr6V#BTw&nIFqh2dT~%xmgi7X;@4TxDX`!m^9yw=4CBPBlW|#>`=Vl9GrT()a z0nEU(JNU6f@{r2D^ev)lMW?59J0MA>e)qNBVvGD~`K@)cblo-RF)k4Nsq7-glSLd}g~I2O6Ldt0Be0p{2jY*ds@trlZ%)3N;%)>~;g8Jh)I z@S*sMd&(D<98NXbs==}aAp=SyU4B{q$Et?)cX3+E#|gCR{X}tel1seM=d!Ro3pVOxSCMJdkR+NSjGA$og^6b({ozCA zy@t$CPqcij$KpXMU?7xM#vGK+{i^!jjK2-_yU$Q5B@nCkoM?@vsG2jpFa>`vb?$k$v}|0B za0hT|&S<-$1NDrxrJWIPEi$Dxx`B69Y9q3~$qnQ$PFl=w#Jo^qTgxd?c2+*d>Y~jp zD-T&_!=u1`4*!!}B3b!`hm;FSY2rdd?Bf}H7=JG83{!23#MM=vtE;eO?IEgCnfQX8 z2iNr>T_5o0Te;Nk`?1!i(d?j{)MX13Ls^ON7e@Nubr|?9?o2kNV^zA$dmk;Oh*z=U?YCA~ZYR^1lseKRb zO}wbMP0=v;jK3^W$B)8=kC*X$EN3Y>RN%-3>Ae{GrhJFfe4Vq@j`{_fZ==T)rg$m$ zZy9NyN5+&h6MGaQBx`9;AjFXL1bWPdq96!0{L{PTqt?RJD(w-m1*=pPX?Ji#Bf2Vy z;CVci@`cL@k6wBxLqQa+Ri(BPiD z!gfUV#ynI3Z$chbS{~68OL-@6%Xx7k!p zRzEXX+9GAm#esJLXW(b?rGpqc6tKNz5hZ9nqj6`0%Su!7h$rj3F98AyWfCCM3~^S0 zHO5fE2WtG}LaoBrztXCZWrtLTZX<07-h~57QFcg5>;ba!eHymuI&iDp`%Wi5K)smt34i0lwOLLeNf0 z_+;XA+oD-ny0dyvfA3Tx{7Scj`4mHt=EhT(+0l1}3bZ*OfQSGdVI9S1J!oJ}$tKna zckJRS=SmMQ;{hX=tt^|DX=vBiH7?=V3|>CsPto`#YfHXAMllTp+m|pI;@-pZPq^{0 zddbdh%7HUX9pdTb8D51wi+TCy^^K;)uHU~0=b;=zhH_I5wv^!#%l4I?v=co3V51;| z=y&x2?lQ`_# zCds7g)C*nvLV$!ipP69)oy0b?56lE$__m{-F<3U^>5A5B8D^`1raGg@XMCE%3(}jo z2EwPUqYGhnv2WiA!ffS17;Erf(xm^ZJr=wx{_$1S$UhzDpWa{y@A@po#m*$!Na?fe zR=kC$>%4^&gAY&#=5}f7oKJ+kT>+F+XpgR0GElU#R0;4c<20K{SO^rb*;gqZGZf!M z8OGKr^u=lCG4%)!8;`ZbW337`)RooKYVepA%_<&?!)Hne0v$vUH}Rz^nNAv%T{EyY zk3E%^wdG7EfH;#`lHJQ_*_aFk)nqcG!z+1t5lp7THWib>jE{h`Eq+QgHx&@pxHPB0 zWGs}{Or{A|`US-Zhx=5(M_#biGq zCNuF9kEH}A6QHU-f&{hT2vGIC7to0aA{Z8>S9ZW_VFa&EH)`Y{UAibFpz<*u?2v z99Lw;#rE|G*^Y9(k-7HB zwX_%WNvOOcZ1!UQGWS8X2Gn6v3u=XfLos8Rp6FRd4ikJs2tWvt;kzS zn-@IyF$nlrE_G?+#rrKeXrSFC_@o^5@Y_#vJDYi$OwEj&r$N^VyH?6C>+-3((g|Wl z2b7^$->W8agZmxpOB;F1D)ejnDWv@*S2ha)m9~;8^0!KAsct>t7xJWXp$F4ZCi$p&}t6_LOQj~ zWA@1zd6hzxuwIRb!7tcLfkcp6B;TW4pL32}uZgdX1S(G@Cvk66BU>bgK;Qr-!MH6e z9G8#S2_=`r1Rns3T)^-VGX%_oxh z<%OTT@hu12%}DUyV0k_s6fAi7fiY_U}WRgfJMs0W)S9n5l_P$ zxED+UtUGvGnFBY~Ha8S^E}NS#g<}p_c(qlsmF%+*R5GnqDrrWLl18s)4+K&YKXfCB z2O?~;0hTr+YOsM!ZJr#c8H4@OqUAm8CX>O=QlyrL3YF5z(*ix>`+Ua+t;*b*OmgE={chVC*MS)&zTcv?8j6k zfix6IROjwNqLq(QKl=iB(Qx7MwluwwoopRXO@#!;RQ-FJ@S7C2;`d6%<(>vX%V%wB zW&lK1Qh#P6M0V2ylSKS=E6gMgVCMmHph5>==LsmNo&a{9fP(mhzTIgt;PK84svsCJ z_yhtGqUKdcXl-_w%d~}@u0yoA)~1Ob&!+L+B2mfc0rHKlQZ3uQTxrei5D^uTq7j}7 z-~tPTl1VU!qK(luHOlliT8zMir45*O1YmY5gkUndM~x9~7A&*{@7rERN40}s4KMDXpxC)owEqCAX>hrWtAjZkX2E_ zf|IaRRQZDvCgu-5FB4!JAYpZ5JVM_$;!vSKU6rkNAMscoPu+-;lfj2%ql;iuzeJ(4 zj$=$r%-S6fbIp31_r)p8htEObdAe;rQCPw_3nqw4E4 zZ>05g=B0ejKZ2)>$zS9-PIRI~w&e@;$MIhDOMS55jD4YbNFw|)jO{==V$-}*WDG15 z_{q$pm)3#O-hRPrPZZKPc24CPe`4n(PGw3~jRBYqrEK_KobC>%d@qvUBdMSCL7Uq< z!mZlPuFdXbZs71rhwa^V`$nDfA-|FrV}ExpFW2wCg%kzua!LMD=dCW6w;O#@=}fsFr<>=?;0q-(%#= zi&DkY#o8M-E0Q(N4pZ{?xWP+2Y>Cu)WNMoTyV(;RLE_wj zNi8my7wIsO3poA{aka!5Bz*x%XOQp#6TO#SS0Fo=T@!&+2>h%R>7>$?I&?vC*$+#iG6ux@=~1=mvK?G$ga<-MZL4M`&ZLN`0!%4c!RnX zei=RZb?}Htly{m5*mMA;eQ$kGEDtsG9ZCE8F3jZ=!q0KDt(=}hg5~43#AOuiokFvs z)<{&xty59axdw&xo})P%vsmrtV4Rxa-f-LqTR0qcb16JJa&*#hI`?OvQHI!e5)gG?yPFcIhD(fsS zAEB-tyQDcTJ#BOOFqf0wz+o=e_~jukIY*>sk(0$Gaxn7pc`g;;=khd{`ivHr$UpzK zd0y_Lnhn+pX{1NxZ$U8ytG7qNzP?#{P``KxU(|CP>u2>Fs-59Fhz>+C*CvI_gEYKq z@Xg%g3R!`{R#D8uas<|5YXd1hK&!je@$SBzh#316kDb$kjKtgUFN3y)TK#A_FdivV zBPI@|BYbWrp-=6a_dAKfMH=UCAOgj*ksQxQ29hESlF0g+fvu~D&%%n}&D*n6_#P_C z3&`S4nh`B~@tVRa<5H5^j_a$Slj7om@R47=hDNTpTQ()*>BK^mi7^e7U4=M5OP==o<(~{7HG4nKTTR(|zU)Sa4C{ zw{dR}E!+q)PV6LtVq3qH@LAqYmE+#Gj1uCWvGnQ|vv5I(dEmQfMd4NR{tkO2zI&*C zCp1FvoZEEr4}8P%$XDoL%Wx%5_ZtPg4~(TCNf-r$XnxC;$!v@j(gy3~j+ZAP|b zdJ5OBv9-Gn3T-K}-LlBGrbQ8*JqYIxlJg5^Fwm?HXe8V$a1uHgo$R%EaznP(ZT(Y~ zt$!T62V38yrW^Ruo59wHNJNUq(~%t*J+au>Utqm8Z8^!9FJ{pJaH>1A&;fV>2jGh$ zQ}mEK0F&IHB>@H|qNz`J0I=kxQ}kS-4RxnWY^@R{2w@J_a~TGFGT7>;f&=iytlWKD;g^5UbEA6RGz__ z5J&x2Ty?;nFw^SEK6?UG;u8T)FgXKEWTihNUaqY4Q@T5BbtJTFEB%adFmGg~%ZlTi z8-Jf2x6)4`@rhlTnZ8fIRKrf^i$$o__Yu#;Ux6dFQv@4#5;K}?dW{YTmMP_MX23KX z*e1$Q+!n7!#<$b9i-XAKN@0^?Tau4v<_V}!{MyywOeUF*WSY1T7R_OMn4;Dh59Jt$jznasilczCf&)G|x}Dih z1?^o>yw;c49hZEGDI3~nt(|x}!2)-5yHW#zeeMhJA!jK_gAi6G4%?QbbmG}T??`5^DORp6 zOtEooVTy&vEX=p513-7)?>gv^0^CBk%|pas-b8 zM-b@fgp?%PMciuPN}x09U6DLTk1}3Q^Q+)STe1+`s|-5^U=thC>jhIu8!?4o9{6Jw z`33CwPg8GH+|qS!=^FBL%sM&#;uiZtw=<74su3@yfjU>m3YG-^+{8pJ7m1=i1OT3^ zm?j9h0b{kjp3{>sjeXtPA^@>1ivZ|TNe$QEN`-F4Gwtx5M2Oz@O2a!$cZ_!!m-CLC z`PBMhnwEekQ_7JX<{$I$*fHUb$*RA=F9cwgp(uapoSDOSe-fJTJPh)f<;oeB%a z!)s`BwE_Um;tkiiRvj*Dqc0BsOLcezz~>wz0I*-!bUIOeT4_S;SASXw8X+)rCPVEu;K>&^Qyu^<+QMeibNJhbh z2+5U(d{F!D7C|MK-V#Rk6x|^s)W|Oi5n@#$nc%8QHU?&L>_}sJT%i_TOK3p*BA*2l zgiZw$j>=p2uVHgXc%TtXAS}=bCcI!|fYlW(i}GpehFHNIlL6+2*#ZpnIb9H4E{b(B+;#mhZeq&!YP-;V8YY7 zs{##A;&{yz18J%mZCkc=#Dmn=x+jf@yl{?nskpcM=5ng`Ta1BcW^Z`OV1+36gsWj0 zC?0j9V5Qf1+hWs^86B`QVu73|j~9u3X>iELR^74@t6M%4Q|Gu4J;XOfjUobQHK2zD z9L9KgLx!RMHE1>UpY{~I<%smuZiP;uae z5vN9+0?)OFK|A+@%TM@0^35XZKK)|hMjkY=naGwDMc`qyI5_Ib#tC$llZBCPWTdRA z`sg+ER%yFWAV}@Qp&ngOuL5q!l>#8&rriuk(vT~~jTA(du+*rbTq(C1+^`^?{{XV= z>$n3mZ0kv!4yqM#OMs$GdqJ|;Cqr9|)vKIowCBi1AT!@=Iy(XLXxXI}( z?n9SHXmOLw=cKqvRvwoI(Y~Mw{oJ-_U9@rq_08m%;$OOk(~^~%wk^Xa(3JbsRA#Z^NoRu3A?5dIYf%HnMvGzS&etKrouSKo~#wDsmAIXYxwcI;v2I z9^5%3WjW5_C=Zcst?lUzKOZ^Z;# zYN{;{&fDR+#049$eadYvPxvKcvad8_BU>-L(dH@{`wUionhvLPY2SBez12)}?X>4g z$1-tOhA2+?C$zMk9I;;29Ta-nlDu99A1zrqtOEHdoU9g3bvd0!9DLRd~bds;)hmrRL{ zn719UI%rgQwGB%GRYXm;BaLUd)3%&A`SMoteb^UBDVOzZGLSej5ciU+2%9tdQe zh^E%y8wAa}hH}dsTj!XY!`i<=gBNdyifP`-OvQ}70x6s8s|Xw=uIj3c%B z2RyWC{7JAW>*YAV8c+Ef{_$8tDfTFX+s7GiPMxV4WU? zFZTaQ{f1%$qa&ISqg*2b2H(oBqZO*EFi952VBc=rmq|g@ z-%*TMhYpZ9Fj}?0Ez_1mP)?Ld!L1uW4Z}HM4L^)!7l(7)o*ZgCk-f;*-q2* zmEbd0{3hL%@NLS3Kl|oN=o8d^Fli0})7vA%r#ab}h|-`a3m2`+$CN|t-~eV1A_7SF*p)u*vp}4+vW!w#P37! z-sV?{FuHe1S8>#n1d0v?l5#Wy14e3}fH)|nhhcAg0|TF}y4VUqBLpn(@*QgWYYg(11`nMrV(5C^I9J(<}JI3AQ? z@qy{=G-B1`>!qL+Zj76yQ^?)jVvNzu52ro9pIKt?N!l;)BPS>gT7EU{PbYIP{>4xK z(Vu?&Q-AT-Nq@6143iZnB@uvDW-*E?2}pNA%B6!hEh-#dasq`K<#Rtw=k&rEwZX|W z>A$vWIj3c;0{cdw+!~_&!S^2ggQWjWRwuz=NCzLWw9)C{u>I=E8B5T_#iugXDfHwM zS$~aJ842UoA&(!<`h9=Q&9(h6rB(MFVU1fOGh=+HNi|EpYt=Uf>mLe5bh%^YfQ4=%pOk=HLs(9{l~8 zrQSnu)L1}o-`Rh74DgZ7{I^K9B*tuQW41tbA5-fj(6HS3#tzkkz)L?-JqRTEW7UH| zjXzR72+Z?Pd;m`2;Kd`oq5pX9B)%CmN* zv^|AgUB=Zq4G<(#WXCQf?oxV)JhI=_q%bOL(9Tkfu!hbmntAbI4M_2#LK%eAvgZua zl^Ai>U_$02>(xL~XR&>xsq_9>|A(_?$2Do&0Hp1r&_5R?ET*=Xqn*Xn_BBE~?`VRf zCY_o@@tefNPa(y{V0=p=kZ8okS?QCq3vh8J{fgude(Xn2h`h)02Y(<<+xkKa8B{Q( z_*@1hFn=%26>Z00O9wZW7Dw-mILw{eMxJ#FhjZ>!$2vH@hw+dfFgoM+_;2l?P-5k#)+YGFYUFbhp@T zAa4wkCVRFx5q90m%ve<0gwAA&{@zLa8}i-!Z>6N>7K5iC8S0wplHWw~Zj*ut!9 z@Q5g*O8`3H#8k88HZ2lrY3T>HSB;#pazRcAISyQH&~J1iEl~m1t7HQk0Xq&F_a<}O zZNscAQ3yh=0*!UAeTTl3X_4`8M7@gN3qLxJE`cVQK?;cvAQ8(o`cJK48+O!u!S zPlfw?tF%Hw_707^wWEP*;nNTeNSTl$cop*;$8$9cUj)d?y+}~o@yHYhH_9jT32V{C zuqziqv5BOSI`f@Mo%!#UNS%p^wkUDtTL6+Yd6jU|?#Pf?Ww1mrAPn_kE7`T6N4~ZN zfbm21#*(=*Ao-m=W7&dLXQjtc)WWlJQl;6;MWn$rhqN)!DplrL6MGs<1p7_q;nz~) z%%w!e(?M-2g-_*vu>no&tQE7Uh;mP5$3nJQHaaCVl<@PlKIuMPdCIz6#Bmw7vVy>! z_&L{#fL4RbGq`_)Lt00LtM%9u)*bv2h4tYVyYxW>hmRFy%4#o^ROd5K&R5P+9UF$P|)mB4Y-B zOz46~sb_6cCc^^JN+wxGVe7I%>Z@1LDAE)~Stcw7u#+k325dJE-Ahv$H(K%C&2qD+ zQLO6NGOG&*H*U-=)ZS|2Alo{aiD7InHiPzkrN{%{SE>XFE=II5C1hsw{S~$(&DIIz zlq8V8aA#uVHpvf;*DE5+nyHv>M&0R3G^Mn1(=^3O3p*4u_^#@_Fd2qHs}&tYu`;oQ0meeg z7+x#^R=Y=3o(Wo9`+A$2n5U?+@!QrkQ(esMW3kImG8X&SpC zycFtN*yto!!&3;mj-UYYWD8@W<;rWZT}QDg{Qoc%neRRni}hS^Qv#721j`dQ?q&0X zZ-OTOe@{tkBEP8l$a9Pu9L*)ReR&Nwx~P=2dF4BrU^gand0sTuK*R*HrjTD;r81_{ z$aE%-Eq$^ZQ%Jl;#*~SKrP9;Ffq8lV{7ft1V;4|xN~X*5&;Ff`-D@j(T0Zy03F74> zEky7o<$^S;RU1lXR|fbqFQjM3)87tmBpt9~-)#mZm#x9O(Nmm$Fg0Zy9&*sOSRxO0qyZX6#qX`S zzIujARXN^Pa^9?Zf2Nc;Tvapv?KE*ZjDI1k_s!2tr!D_4OIocQ`NT=M&jRiNBm#A& z<%dKtx?}ePSOD}2usa24S5aDiOeMN1q0n-!64uW1YG)bGQH%2T)AHw3a-~YzoK(^T z8e@f`%i~U)-$N?`g;@~7HTV2f_e8<|uCRA^jlH`UU~lgI`;>>2;Em16ZcnpD;nXKw z2!7@WnEP-x)Kv)kGWMKej;EUe1TEZJ8yDirW23$-mgdCa0z^aw z9ym`;B*0tID$1L9^3YEy04w1!ygYlmg&Z(0?1RfPA>PIdECvfIJg@z)mUO}%DjOns z&Zz7I+3Gt47?OR8)FXHrR`gQ?2t>2-U_V5xpoR9#g{4IX$gu}v?mh}n$skFSc|M1#u#okFv z{Rqq_JocxCq0N{0FTdM2rjRqNRpxgpqS^ds_Gqau0~?U#zs^{0@Cl7@yFQn#6_E)Y zG$C3#_{DTI_4r)p{?TfEodE@~`q7b2g|pf7EiFRKZH_b&*1?=0G&ey~*x`(Rw)e3i zXXX`MEi($@;!{My#nyntHXP_J_`*p(Puju0@eME~;*7yKq0=tgOEw6WhknNbNW&`6 zt)VX~yBuws=_FbvL<^L?VGoL*ONZ<>+{rhkfucn*wFezV`uFvn>9pwTmVKaC>+bQn z-h)Nv$2`_xYjT#h2S>0kvIktssbP;%0n(mQr=i=fThGx@&Vny1de<@eDUOZw`q)B~ zSnW)7@>=8$HuH5z%6@q%lPvnz%Jwg&ubXb$sIlOSNnU77?fKX9clF#$>06O8Is(Q1^qq$<&BlxR0fTw0ZAH%fFG zCDvCZI*k$r=rETJl=x1FW|F*lL#)v;~ZubI2-!D98?6%Xz& z*3Nw+f7i{;^7oRt5q~e8+rZ!Tb8Gm!VQ%o?eqgs<#b+O!L!L>by_7t#p9ky0gVW#o z0CzpVd*M|N?AOcQ0hKjdw4H4K&c#7&cf+ zs(53a&16iTm6s4c6&+vFco(s8X?S;O<6XqY`tWXj<6XqYhVX7f<6XqYE5f^1G~PvQ zyfVCdW#e7M#;d}+S2f;M*yu#wXv(TVx#DXL8yw2JPwHms&1j51;h`aE3OE^&k0y&{ z*Wpj;^WQIg_(W0;%V$2qii%RtOV@hj_l2M2%{P`uKE|7u>Twl}{~v{X~3So=|x@qCe{hv!qwvJI`2p*P$OL-=gm(h!ks zQLE-WWw*WQ-Ko;Gs+WjbHRowv!nLZGh*~wr7phCRR`n85tLp0wbqUw1ULtDM94OQ! zT&sGCs8w@mRh+VXkrbC!{Th=SNCd1uY$8!=hY%@?xJ4Us?Limgg!;tcNT^!he{mtb zJy+3NpwInPd1VrMM0fwMh#5lhyD?&}3bzmdIY+Zl%Bn|x=`y`;y>>QW_YEhp4~J_x z4m?~Psr5pBp=>vI8x$}4X7*;R>jMoKx#?UoT+46HuYL3>Eug*?MOySQnBq$cboif< z4P|w%C?J<~#0A#UUnVlkzP?{9D>F`QrN%_X)HU#Cr&v}@Nk*>(C-jlomsNAtv+$#P_FDaw z$+xYyR`s>au~uhmdGgVK-zZ=nS@__I_<%HplUFJDj{W}nXf)GuuUN(qieBiYY0bZ; z>gSoNmC17Ndx}*I8?>&bO~${x{N6jtZ@K&N2aC1)!Lt?!Fzbr}6p55)c1TVk1u*B? z{WYLV%xt&3H-2k+s^WHNmwuZ(YwX9_k4m z5B>sjo$C>)m>bBIS;twQxdMk|ZWcK-x3$kO7+}9xTdaHVdZw?h^G##G@jn!s`W0ev z{V-$97_!4P5CqS!B7)YIFj!lxIdEl?AQbMs4@Zgg!*b3riti&8>$)2h`&Z2}2M)A) z?ewb|DDi;pQ?C|!mm9Ptkj=N^M{Ep!UrHa4FJ&TV|6C^W8C4qRl;&m{M~u8*==jeK zz4DOu0_b(rP)|jKMZ%~X$l&GEYVJ$o?A68Ee>_b_e<=#2$hFgCp^;WtE}!kH=@p27 zanPtQs?Uvb+yv1U4!EIHX4g)yq!c+kO#OQqH#Z~*vNuEWdhLFfzjlj*{EB7%W_U)g zT|M|~H#*>}vh`-Pm0r7U@Yim4ba~x=GYL!d+7*MpmQa5yOxr0tZzgw2ge(6SW^wtbn&6=C)XsJNFspz@`-y$)p&>Aw-_ZUqy_ZUf< zB2pWBj3j4G$PRvi<6mhRHmOW3waG{^D@32IlX(zMJ+)Xqz!0=_ITKjdEP;+z>%;{@ zd{aIct+8uGy>cEf`L(pbLhfo$B*2Qz8owe8zE)+`zAZhMb_SmN7#5$<5-Tyq|2Q5t zw)i0tsDcZ&^9>$PT@`5=HUXymu&q*`frT6xMJlm8_{~&1EWrqg|DmCD@K_32!GpT~ zSwe*ti`6$u5>1mWbT(UlY$-Nl4z>sJ5h9x9mhu^Xv)d&6~ zgM(IjQnJ7{0=IgJL+Cx zX>=F*(@5kRj%8EIUEPLTh{?(yt-%i?opSI z>YDQ>TtNof8=Q=Kia8H6;Usc8259e5j84eJ6u+aFOE#%EjsboP7-xp+daqW-bV`N& zwHyR$2y;2yGhu=~XwC*e75w-iYTL6*T4j3bUc26i0Wlup#_S1alkOt`rM$E}A=qe> zZg8~^MOcab27f9^uKoqil_II<_Q@7hNAOM3zs0}s454PA+ozG(__K;s6B|DisQ7ea z)bgC*8p>I(>V7%rkuh1K!Z)=43uVKgI=s4GUn9u$F`pZ?2lJkFD}e}5|U$8o5x zvAqApbqwZ`4qy+VlSwgAVNG&N!pVe(A&PDRM9bELO#Xl%o-vX*^o4t$?@tU;EnFxE z1(|BphMgU>p9tDGMD@pVri03GY$Hynlnzqs&%i*Zr-af2t@4SF2b@-;h!>Y3)(it$ z`KboEWdAhEdZPgQxs;VMC^-#m!$MGKh0iP@QyhTyBhykk2=QGN0$ZAaQK|h1$`S!u z9+1U~mK|Wc%g%w$wVdg4m_HG4|b(qU7aJP>;v7NK1i|v0~A?+ z*ztXv;Hgr^W(JrljMU`Hz!GUf#5y@37^7ZwhCwM!J`WWsZBV3s$(rG!;x6i1-@dT~2aizsKWkBXnF+X7a(oBUgc4k5DoPpaC936g8AgmK-r7Y>BKp5y~AG%J16fo?$3FCSC`I;dNLzgI{ z5^V-sd$NE;77FH{ULYyV(8N>|M(b!*loLp!CF$jND|+DzZjoLPXLG;Xpcg1!6w`&Q zXeW{kwDR&KW5z>36#Dr>5cSZbUwuTO28@Unaj?N@98oWWpQ9XScZi}CBr}{{$F?8T zActdI;nb)<>ly?#JtFq`Tlg;7V)k)&*I)SBrNHdEA$|GEetleB7< zE24)w7sU=L+rr598XOzn$m6@I2#}SBz(BdZe3~CwTwYCLl4>&K)QaQ@w_)3kZB*hG z_O!Q>$+%xvAQ6l^O}efXS!(uV3M{?DabcDZ1kWVOkK+CRGwSWEz%udT6BxOP{~IBWU+A6 z0&F#?zEFco8sEVJ5ZHF$*UW<8hC8GUVA#aQ$?Ij#q-fIMLbrCf~&x{Ef)gN`1E$r+7>zp4dT8fT}~g%UC%TYl{Oe%;KMN%j+}$AX`;`(V?|5aqh4Fx&s~D=<2CS zh{oMmoFt3FXgP!B>kC4U{j~ToTXFeddSnK_ONx-(7y45oWP%1NqS9iZj*md8xTcwyx;ddq4ej#tnRYT1Yi(0viG4!&5hn(r zN;SuTOX^sx>FG{}>5@q%PPcp3>8d}QE+5vs zhoLS#-Hmo)H3aHdMOn&vcFIT7IxcWIfUM9;M*HC!p(_na2$gYLVx*EFDO#_NWSU>XMl_5UIODU~ zrA62rNr=&KT)~5O81~T`BA;}KWNhog2L~#zCUW5idtPmNS+vA_pa%r;&>nG1DVv^B zK;}qX)50tdtSe@;3M-n``!ea<6pu8h_lU#H$oFT}yUsT{treZez5f1f8Cm~LTA$7^ z1lXb6dR_839I_?(#oRtUa2E1W33#h31UPmXfYXu-4i*I!K41pne&qK{l-EwTbh>(P zJKs`ZVD*RWt~7R=UUN1MYfoKLbJ(2*cu153RVG;0E#R=p!JXiFZ!A`e6!se!6OflF z@)#n;nPZ_y0alr91lTpxn(9wZaI++r1xA$IA;mmPYYI~Kigk|yIR@5J%7MusZgdjP zg-UyB4evM&=VH{R!IMcRboMPz>RcDBsBcc9ZR>ANep&YjcXF?{w4!03Q{??@XgfpF zdfS@-dP^U)Q~J7PTq2uwxq?e(%SUsdx!g6(0=?q$4iaz6E*&lSv_q3_QK@jx#%E3N49-i;}H)Q-xrM$s5~ZC6KmW zDNsyA@nEGww^BTr2?sLRnTbK$$?JeD2zU`0Jl3mxAaxj!EN=_U~ii}0^Vj1EKO17I#JV! z1i?5%3>KR zSYfJ_!sIgkFj2WMIA1>UOzNniaBS3rFzTr=YC8wy6TtUr!fqVJQyW6F5l-hh6BjNu zMw+b(-9A*(t1S{50d-4)sSgBXU-pZsozv?*iROAW#yX$`f-4ZVas-Wfi4i{{)};L~ zom$R*=-7rNtVv1QdWE+I=+8x31a&*_PxrD~@DORW>mLhW92orLb z6)OUAg;&0OI*weY32ebg5ST-1?vN9^Aa<~#dp;~FBW@K1jNj=UGTV}*V%IGRET)9O zr9>NFzd~!98NM*wv?xbPwAUADytCMc>I({Q8y%fhNsgk3uUNyzs){c4!CT8x64zMP zcbF>4FF5G?S`E?9qagapq*}@TgG|_k{~^`a7kpln^v7j;L9DN&k>L|QP?P^t(+Aux zNOb){%vu$7(GN#SR7eX9ik@O{LH>u@p$(Jh3#ESjL7&vm<4OszQsydaUl@z}+~@sc z(QZlJPya6Xg>nS{izYv%RVu-+1q%uOE`r~pJuS-wY&pYe;sp?n=%@ac92@%IEPHaWFj5;FKGjIA$8>Di3om@sBIp#T5t z?o9yXs;d0|w^VgicXcNf2xJ9bw+IPj>Fi0f?qW#M0DOESrj0cJBxIHo$(8RM=hoyaaS zVsk9HEw>ysCt2)b-{$JPOvMIAe8B=hX7lq=yVMQ8y|mU5cjX;)TeXIda^e-W!Z}<5 z6&ND()KYNy_S2mwOhC=9B?;5Yev|`HYcq zSGzLC5kwd$M_Z|o>Dtg!{m9*b`e<3a}u}PVy&@;{jP>k>&VVt|Jm6sYoiFu9VBg2djN{+~S~{3Z4r+ zWJ)+_n9vT+rA=tZT<<~aL(IXnLJ#guscCWdCxxhs-x7(%({+26N(hq~Fi{B{OcRvlCfP!=9*Z9EZ!RQ@HPQbsKoUO5LdtSUpW2_rxkK$jkBz$TRtM zHZioo*urN-3s`g;qa9}XxB6wG4_Rt*2Kr3i6jmLmFPTkjKD915`B9eUC&l<(Mjh9i ziv0&%qbCdC_ZqSSBXCi2x^epuoVDqtX(9uFo76RC8%CvM#@QxHcDdC_QlfuFH<=UZ z3#0(!62PVG^kWG>z0(e1ODktzuLgcL|9pxdjnj82}gsZs!wo9g)4)H)_N#eJNjdCCDUbxdxT<8jwg z`hOLR;{Y6lCEAq|%55U<3Goo==Tg{=kj$5a(dkH))IhQ&HIVd*aam+j{z(*~XrgdUM9KhBrD8QWG`uUMhwnJV#z3>5Kid53>6WnaWO5{F>P&j3$`2w`+0d6+8n`1ER93eqwV4S*Co4`pOEN5y) z%M@lQ#?(=Eb)YRBApz%5s03uyq)1Mi&vQ)yl=|S|qsFYnY!2v>yWp;Qlu%#EliI(&pfoW#9Bil5y zLlkYAxf5mWBqQ^WHJIp-o=IRFMcnUhXLSHKZ>D4$5VjUTS$|gT9|~2c98N|X>&I3l zjq;$^QTd5CTcOz4#I6bug=+@nUls-O`JKs!2R|y0LGFTxpP{)fFJoQRqCGQ!be10R zWIjL(c$?bI3I6U%!7(KrsFrl<%!tS9<3*u)Q zoCGn$EkQ;nNVAPdr%elX2S1X+j98f?Bo?CH}QHXBJq#Y;!jk|JodiB<+CLv zt$XZ_v~|Z`5>(FmP7ZLSuJ6K%Y~RP0{sj7tZTA@K`ShPu4}wM(G6~MVrCR1`>9{>E z&OU>jryQbkBo!G_HE<%Mh!&`x& z`5%wo=)n{(!nU*A+bgYsc8JZwMe(*`e*k9E(f+uj94INnaG#>^<}@F1@yS~n92w%e zEs>$bAUpPHjU0~*!BQUi*a01EH}-<4-!f%mZINRNK1L!g`!Rw;p06rT`El|*nB);@ zAy0Dc)!2Hzr=<<;7gs%RcJ+vekmuv7Cwmc5dU@4&c|qa8&Hu=@(^ns}I>nJ<9vr7|Qq{7O#D|5j@p+h4Vmm5^G%d#ZkaH#Jn6XO zC!0+3n!DA5S#g`z>x1}LpLM}$&FI%b{GB8?Q&yND{_7+-!>my8JCfijTHXrc-~6@9 zdz#de3d z;$nt4Q)I*6t>81K zJB{4KJkyB*>-=zcgwSig!fl`{J!!M;%VK9bYCS%V+;-$eyps*c@sx{WMC_sX%_AeZ z?Wq59o>beoN;7GV4v8tnC+O7b(&qxdVR!7e=7N>33L2y;@@r8_Toox=hARUqvy}Lj z+X)>FR5{^P&np!8fAnAWQ;0f8CA0*m1bVHOuptAx5rZu|;g7H(AxtU~_Ou3j5{vn6 zrc13b#2gcc+x%J<{H>V*o4>Qo!f(PLQK&(Jl&FU)MFo>tfB=2Q0Da7dq=6dJ<6Ub| zvjn~`=z6CVKy?7jtw}@?Rt>mAECiRj}+cJhYca& z7}&V8$bnnhi0ACA)ge75}>^o5=mhWtPJZ=6p_lB4y7R$5!K!^{H2 z=*duz6QwsF=a+QOZ9-q^LD~o0T!qBN>KJfrPU2*_8<%2tLSz$H8Ow=jU?gHh+drio(6rraG>>p_vzr zu88?zywV8r2FsO^OSF;lL{X@R-MUhPgWACyp2azUU*O*qr_#Q5=IL))aiAVfP;<1Fqq0WI7 z(dP&v9eLtWh0k}!n^Sx*??yF1e6Bi`$A+4i<$D?M&ja#!CmG$w9Ra`EhAYfOuhORPP%?oZ zbILR9beQQ7M$<6NA`BDC5Ju-2^GZ2IS57%8r!hr5$YBlfj#!R-<6Jq2S9uQYaOmq! z_hGKUZ)&B8r`Dk_PJ`AO+j{W^WDUYJiJ{?Ss39h1vkok=7UhNp+B7$rgVTUVa;Kdl6jnn}EsjpmR6xiBNNymMms7Cgkxz%*G#7J}uO!0cLJ&GOYUHpvPh%&f-zfbCiSUfkv~JtH%X9Z*~A}pXDvf0-7MQ8V7mj4w4}j) zw!zb4lM2W|Z{n&pnC7PWl$GA;H#K&byJw0QJgoQ;74MQ~p;K4c^f)I*=;mcl6pGh6 zh_JFVE=1&Vt=qT^t~yo+5vpviI<_ML@PHHIz$~V4I3SD|rfTHgm_uM^3JaeE6&ZvI zR=Y4Z5Icp|CFdwbY@C8x>qI^~T0o~I8nkmzBj=nWWkAW-4H%qqH(P41U1{X?B z#w^CS*2P)K;ykf;HA~Eks?<Qfeq_h=u~f#c zZlCrtyVgLROXpi-taZ!`ngyYDb%8c&cPn+9j6*_ef`k#ZpAu0N{`4~bU}e0@mnxYfR*vHi~ke-?xcL`R4sBHd|h|I@6@U*G7CvJx-i8JcP zf(V`=hSszu;@*acbIF*+YVGbzfLtzax)>_KF6r)gu0#T8gm^l41V9FoDZKwcI)!s_ zDYlTEAt+oBw%H+FcB)L+6O$jquPGF?Oy`E#O|_IOG(aD=%7_qsORzUjM?>H#Ae42E z+}%8S^6?a1H%_l~d82_S%Im@5W(;-H4YygRXW(cQf~~8*|F0R_xgwj%M~FXpR&ERi3d5`n&Y4NC|Qhh zQ{12x@3bT#uS$aK({OkXWrb)&6v79QfHpL0q*Q89MoBw|d?6Rkb&|VkMR7}qYZQ%i zjS?8t5?7uw9H&F(4td)VwkXY3-W$fQlhWvGyC=-Rr=*Z?7;UUk*jSQNib*Rmip?N0 z8a!AwL0MOPfs2HUaKROwV@4=9;s2f)Yd6NlCm|OP09{AO*vnc zvL{$5m9m>Hlu-*>kg}h)QTUCu{)r)Z`xBpgW3uGqiQC&kxGBW#amNK%9l{!u+mUeO zC)8ZXU%S+@WjGJdP|I!V91B3Bd^I^3njNv0bd0LEl|yi|3AiJOMyI;Wm?5o>c&aM3 zNV(za7bAQn~yW|c5<-}bx)ut@1o_=N+rziI1xS)Z; z0#M49t_{4P{o*3o~*7XO{VPRvUk|5-Mr>FGqwCscwBlOLgQ0f?C-7E z4+rVlhlv7gcc*S-%4|bnOyDu9 z)MT7GgqW@hjXuhOMU2-F(m74eje50NQtdJzOdBZ4!6dmnB0Yt+NyL^^JUf`&)=)i8 z(Z0ffO$;|@CuK8f>ye2;ad&uqu(I|afSLhDQ+7;q;?3Qd36YgJslEwOsi@1c3NmRU zR`a!m{iz7BT&jf>FCvN+{5iM+DF$EALn^h&v>n1O^?iTw?*miJ#*E=tO<~lQ3wCN*Du% z6ZCaLG!6z~RTF@YJ0gIlxva-9#ipkzpAZJkP_D56VyR_30G(u?p8$x)V$jLf%yBU2 z6h({zT>)!i5z}KEciKEht8`E^AF3B_Yb$YAV`Lg!F=~`pNLmd3@%<>maceyCHwi5> zqR8z9O(Kf9s7XXox+GiDrC%3B6w!M{6nVr4l+W%4NQmN{X+bbsE+1f(#1TcQaF{lN z9Vz+H)kZ|>ekDZ}Gn7R)ClN)JLq;`S)~Q4B%pC)D$&5@==#Y9n6rWrd-GENq1SIG! zOWzW@fW-ZyiTHsk5vQy1t)shhbK0F6N6Ef{i>%EBUI6O?ys}{f6)n_@C0O6x0<4$m zxh=f1#IP3l`q=rDjIPG*Rnp4+AE@$}P+26lVi{?rmyxBe*epOX9BbHU1UFUb-KwC| zt_p)D>%RtVe3(Z=Q+2v5TJcR<6%55^XIcebz<7lMIxUrpG zFWisALCpYPOmjk52@bYs#xc#uWM-pCc|Uvy#@l0U!z8MV>OYVH(xC8O%*f z+l-6WWqyqy;O@!b*n;@Lmy!;}dqJxBjQCFBmaaA1SiMJChA`UH*Op$E8U+_>WdR&^ zekr_$y*;vs>R18L3WJiS9un6Y)}v@hB2-bmKWG9{VrdExKx-ZX1{i^c$s-TVz?UT* zo2io$cgd8v@2c| zKk}7i=rme8O2_W@_c4b1sBV9^e~$`0*}cbi`y2Vb>kb!dI^p?O59k9q%6C%siI&x? z`ussc#_{<(KqZ#jnW?WztpCD$JQpYp%m~0S1pmjm3AnzbiCLe&+e21F#$a5qQdnne zF%v>Bgff;tE^C`%mUSeEU7@q0Aa#j;z}m|?UL<_5O$aUFbTB_0!jQ)ZXgWeBncS@& zGZsXV8@?930`+GOk1>Tl>j}aaRO1LW)Z(TD;~S zODIx$u~RZB&H4B5lHM_c++5NG(l&y65zgcCmXIK6jH0(vT@~Yqn;6h(dlupr&4v- zP(usHI)-0|Z-m5{&d%VZVY`?_YbLUF#5Y4Mc!T8rrzVam!Fx3=ZIl{;SIn6_<*)mQ zan*M`I%2Q$}@XNd7o!jGA$jN}^EsKUn(OeoEUOXf6dm>Ll zAZ<11q-kE>9eEeeu=K2XC11O_lcjvO-=-Q&bX-H%giNOP__hG zrZEAz{2kvG#lJ-ZlL{Fx>d~TK|S=z6LA^1Ko1av0V;vpX%7A2fVwDm6zEe= zvb4y3AJ9-dcQmo5$EOhBo}$9V1bA(TyldLL9#(lEuiGikAL@zE#i)lUI21p2_<(0t z7|Bh@pJfj5Ic57$tDIN-a3$lXApsw>Sk91W$xt$?r=g4jE>Zx`o$IFd$AaXJZmXqzm|8}iRiXwdm9z9sLJ%^MFsrCZ?k%J(@80QY~)@6v<(2R1&Smf z=h_*zksUGld3*>DT+C0srka-SAP3A$j1oJcu4BVJu@HKCR zkjxQ5IJZ(`;ywytL{8RdECgZtsX?iZ1+yy!cAl@F7eF0FSc5L4VF1(&A)rp1C0`dN z_$VkB;=OxpJXuPvgSM~vaNTc^zkQ9tel<1}`SmC!-KBIh_=!iSZ7E%)|ym+XXvtpuR#Vv{eXH zvK10^6(+-O6{cOI+90VGTo8=(_@R^{6>n2D3o^}c+<7(FRlLkVEQ6t%fx-x2q9YLu zWN;HhQijivv`}hgiaR7lTXfioe~@sMMspRS#=oGnl zOkE#Sm^_BW445R@f5hR4Q0`(*5Qln2a;30o1jj)}g4lK^%(BMY zFlHm05LNyMKPm}3iaJM*w_h5MpsN&`A2nSlO&*HSPC(|6>pHJ>VdwCe#%@$G8E;ZxM9TlH0* z+wm=WYtox~XDPYA?tnvZecq>l=9~h08tN->vtsu0j{zz25Pe@d2kWd3?Xpw_4 z5cwSqli2K;2xBx4_P}~dz9$M$YM^sSxHig~oKRl=fq99zC$tbID5;Zk1KdkWbXqMX z<%(QDEAl%cHYu6dUX{~I-aMadv zD{s^&mnWmVjjRpQ@|5(#9AN5=7Kd5e0ivzk6L&$}>i`{LDWHeRNU(=w%?$3JKm=eR zFe+;hJjY=g95BNasw~$ga83u$=?e@IRgiC@8$29{aXag&j$fOG%=#2f6lhq*&kh~} zg$8dt93iC!&xVc?#}1yg_yGrI6w=m7(FDYk_?--k^iwLE5KZFoIJ92r?NAy92_;5- zVXSn72S)!$NSfmBZ|3ImoV672AuohB{5@1+1Pvs%FA~_P7 zMGnzg4X%?}0?916F(6TZyF54zN^*%FkTTtjZpdU(YI1ZAxWM{|5Zq0zbXFjaGSS>v zQL4OWnFy?%SVxg%91k^lm+#COlv#Ax6b&OzMZ#tTjD&#%NLl{2wA%o1N$0|o$FvGb z#3t)tYta0GrKi%Ou%2;L53p#c2T7Mxm>?q}((g#bL>acFMI)RFA+=T_l^a0klDgz@ zeh)f_FgFyu6YZcXFg_W0Gvb1`$#Ynt)mn52eN5_Mvyp@{(nz*R@j8VR9X7F6%!VY4 zvS<_?&I&2m{D`cMRVw5`EK*`ablr@tBaOah*V9W8A#7@j9rA0YCG3;GX>NolS5T7GUpF;t*kOr ztFsHF>hUzH zc7k;}2wHqgaFRh_sm#XLWFo;l9S5<7G+i>jS!mRRb*sljc_0vo1fWg>Lx7xuAV_F| z?2e)ZOoIdjuGJ|BvI=U37Gyv`--S72T4F=N{k+Vxg#3{39vc&pUTKzzO@q~jwCFYj z2Xx!EK2QXlgR+8QPfQs$#gajwZWbarB;XCE4Clo35CTW6PXSb$qHJqKV3;aQ1Jv5_ zL}7uMrEDBPi%55r@v!F1tlFN;fl7$N0eEsQCoe=CzX2O*-`vn0O{SYnLfKDJBML;B zmd-SyY`6~IPSvM!o2}NU?PZslGtpABnv8o43Qig+AtYC+^ic;lJnYp1hD3?51!9CX zTcCE0CAL7U=237BmQ+-GvjqlKTOc)R2_r}hf?|MGgVD;g-Ebt}YIcDJ4YWDtVcNlF zsFhY(d)TDJ)W!K6(xomlDI0A3DUhk6MUdj3G`PeC#b_>G-gwQs97LjZ_q43mQ`DqSXoQA1%AtJ6J`vTK!B|Jsugb& z4+CLK8-t>I@_6LLILU!24`guDZ+dK0#C+|cg9kGq{Ml;q0kWLrMb1RWtg6qAPC9E! zg+M5*`vT@71OQvs@Wk`6iXgJn1AL~MdZJQK)ZEjJ)}O@F6i1zCn8^Z;Jd8(DtSs?% zl?-g;JAiEy`>j*o`Ed9Y`zH~#OYbeP>xFLp80yVKR$!Cif|dI3h;$!JkTXB9A4B&g z=-1PIhL5s^>yGX#^V3K71+J9xyDEWkP^0{IommZ_N2dJpp*R-GpGlVp=Lr{tR)BZL z(lsw?l%KoaVI2&oxtSzJDTf=(efN@DM_YpwZK_hGCJ$NJ)FL%6yTIc?7;;Q-1T3%$ zeTt;x7oREB12|%3nkm9UfQFRR%?>&V7Kvn)QOKAxuI*KYO3s!hR6AQ11Y7em(F~JW z1Uk}^1AdRhfuy<=46K0IYrGpUiC8+eh~rGaXr^q@PuL>MfC*cK2HKk&(v&TVOr)$S ze){CJ0S!j^BK15p0GFl2c+q5|9@+NtbxnffQ z>KtK&jpX2lXc20O%~4?P=hDKbn`l~%fcjB`uufWYjVUIL(~_WM2%S*@aH!RAv*0h&7tYLQQ;1YNSTdWXfKk6CG3;EkglC3g2eCUu_KNj#I`#uz09jK@E?Y zuTvW~*$UELMWgmhrqw_6$QJov(9V!uXW|wC;%7115>E^8z)HX?XG5)x07>payI z44jmw@6vMt%nmt8+E>%$GtER`#;;sl?0VLFXzE_oY?c@!5>_+xjtl6G`fxE&LWgoD zE2cIF$s^;?p+b!g;qqxXD9ld)mhHU&rqx=v?CoQk_^zY{)U%QO1w#MBwgztp{67oQU@#JI~}sRgEKyn23U<1>=hY{iFoKBNoN~eV;Ur0z+Z`Wt?}h}xSPI4@ zUuAOqb8%V7b#$hhptbNhEu2{;cT@Ej{Dwf`jD`DE;-Lcv7Wrq$Kq0U6L2d+e{s-;O z$HaDt=IDiFEdcv%fDKUGhE0(Rq}f2q0%fF;ZBm#iG5}ZY*i&8qh>%hBM#1BRaK<|& zlpQdXtJCDFcM9%Y{|TzNyA{byUFrjnQ)dA)so8M>C3I6lk>b~;Xz3Cv-OVPp?LL6M z;uUzpQc-d~rYNnw{xfJ0fg-cRsWL|@m+>N%>BR@YBIPAQ9|GqY^)VlXwd%)49=6kh z^?*tA+dxB!qd+qbU|<+^fKlZJ4v{_1*E|wn1VGwS1q|bm0w&vJL-eG{7bFgSVzqAU zVoq*Jx2x+l1%$era9=OJzpnqK;{}sZ-*mVewgvDk=Gn8oG*OB0O7IAKJp-jC_Y!&A zOULmVPgC@c9{xRL^$cRg)pPN++e^$5Z?1=Axt;iGgzqAh20M>`VX2fP!@Zz%I`1w& z{wV%HEUyO}EtyHJTqEnHla-D&{v$*;XQItvlC;h=sIJ-AGjW91YK9SPD{pj~f|b)< za?c)nGFI++ZFgy!Igd&^m-WkssydOWl=K!q_U*OT9R?AQ-+IzrTA|$F%#M{vEM(QZ z)q`&%BiHHB@7+2U%OJp45QKwjwAfKvXhnFfBrU(q87j)R*i&ELE9$J552i2g3rYfs zs`kqt4>)Mg@IB+&mr-X`EJ#&;MyoK*QmAVh{Q^;m7>TLF27dM zwta6xwX$EpKTF?D$g-<1FdxETrMfxVi|~kt!92c~o(u@|@X7fXl9w*CwSXpZ?!s8- zMTz&B1W&^6@TvDAe5!m14@%Y!!0U_;;dDlj{yvbfET{w@X26R)P5MV3JmAHX;*lRE zJo$UcDH!nG5bePTQb8lk^n&T4$Ot*5BWV|j*>`lH1kx#{6M59gqJy6=BE0Qc0Y&UT zT3{-O$S{;n1#kyqfH(&KgD2$TiBcz3D8&(jd?f=o0ydZ=O+Y3Y(qBp{sRv}j{^U-B z(@mEF5=-1hnL?gq0=gAXr@IvZiA?(IuJ$L3gK?2 znq~sI{Pqt4+OObJ@vnJ{7ZD3%dsy!W0BiY1#}9oY;MbTZr+^_?a&}8{jX1q+^^+dy zl#jGWa1QGcmPueG!ml$rNXh^kb&<@HvOiNnT|EPkq8bAP)0N65y)ffwdjlQ>2aFZk zrh!w9M7U!^MGdqYcb2}{iK6Q0uZ1)JLHDn5Rn~-;c<+yaLFQ0qqd4&!^;IK}^@yv%S5NY(e6j$TmqZ4x88pK?tk_H}N^DQ4&}pqdGf1>Tymw zbWtow^Sh{1PT)j#$_Z*EOIn*Hs>37gRF~S} zC3f&hWJj1p%>(dzj&TzaV*6f?tfW%=VXXyYtt!36qnf;WTBN6htZNjlWe{!QFe{8U z)6pd=H)hs6q}I9v`{< z*QJ$DW3k#LjyV`eJ0h6S+y({@FxrT)zJS6?ND4aEdvHQ40T#B!EV>r2yhvyeO4^qb zH3_5K3}hn_GG2%SsQ?8zDV`M(l^%(ZlO8dJzNu*kIIm&Ezfh3Sc?-s40A?OwYN~4~ zsDUkdPdGE+vOKN?YliCpHdRI#j;H@(PhxL`Rh0Gh)iX@WW&4%qTX%spNUvTZ6w@*u zZ1C7&hcddh>Y@?RcWWuv(%95#^@5djFejuCagX3n(re0-Jgxq)&jZ63K%h>COEe<# zfgfo!(NIYNwMx(^(ng4X0-I4KSshVfjS@(X9CzN9E^=fvVfZ1l)#+wod;l7(MXFF+ zdqi5HurmdAt+$9oPK885YyV{W__d!u8G5yzhR5Ih$pJ)eH(dHx1LkRyT#iu+!8~pV zAW3{u`PXiF^CpE(OG7^w%W)y=u9gOYwS6jy-z>o<<|9Jy4@yfMplWQcrlXVN6UI|u zwF%hZw&kzD9AB09n-Yd>Y$`rASw0M7j&p_8tkN-JBRTB@G0;W~FF@5G0A)SO$<|1> zHYPI4o5wts&cjyV#Jbx?JEKOnQkY$cI2Jmie5)S<6rE+jE!AeP!eSs?itI!Xu!#3l z6Vx&X3)VBVNJrhUz9bX4Dc=>ow1SL6U0+i$-)e+sbaR|tO!n8LIm$CrSvk%)Dq540 zLoeE@t&yl%-x~1~8&881wQrFQzAAdPVCAt7MNk0Z>S+^DYvz~CT%xa4v@jv?w51mv zbqN2DHo5P{4|7D6Z~nbjgytJ(IeGD>?pD=_<&F($^2lJd6|1QwayUkK+xP{W#n2VZ zE0c}3sbFrQvl2CPaG9OTK5RJ_(;VhMFAmPUej|zrr9)c|!-n~^H zdea^6z3T%9zOlY^SjNEMdPMw{@If<;NT-aYoFF6%WuWBfZMaMq!`BAUV6)`D1Jv0B@sN=|%z z1&|D#7Bhv%;_mov(ujkwdNDhg>P`>T(Sn+Hd?|7u9uFqBQox8iyyd(#EemIfv@8oF zm(z@K;?c5fw%b#EDDMRYER?j}eL$v?3YauoDP{%j@$X&lcwg+g?Fa&Gg=GtC0oJ0B{^AZO`nhLYBLv8tJWsooS9qB>7 z)8a0(vP1w~~ zEj|hon(9crqLp+&vr|?-$T$&@#xQ;Wke2^Uh73!}*I%Sx?hJ6|s-4#e7D7@nc8bnx zJSds}SUt3$!9MBsYF7K4K;LE;LnxVSMh*B82=WTp@%#+lYu>W|et>G(>7Q0eL3Q_e z5O?j}gXmX>|M2^r-P<*C)fjF3qB|}IZD!96d#^QGs7Z&K(x62bv1WNWSOY$RmTr{T z!P^`JH7M9n3{=8}`d(lS0gpg{z9@{(gzHK8=U zWYGy$QZHKwf#V)iutoxeB|e0TK#y9JsL)Y^gco6UBxG!p(ky)oG9~IuRMdb5I$fT< z7AJIofTC*E#0du5&1Gh%=JL(|BvL#zmf}o=^Wzkd8W*H`Owwad!oY8TPJNTXu}HHw%me#u4|II@A#jUsxr4F<@G z^&lN%K{bgNOew^o?!k~?@D*WzF1aZiN_aGzzG$FLc~ovFPQeWz_(R!dbV1JK0Ai9! zG!jV@sfDEa-I@n7u<#+ZxELaFpe(-Kvd(avtPMKJbSkVN8u+Ft&KMEed2OtztDu6& z9yXgsCM`4(T$B2uTu2sHmOD>YHX)rSs|!hJRD&9Ip%!Lbeo6XAUDQ{9|!aIQK{fMMk5`KW6aq z7w&yk-r>l7|Ewu>RJ`0mm5v)aY!O~MY&o@xEiz1ABm>I`l0ZC+T|M87Kr4}uaWCTOe1dF^u zk>t)smf8@K#C~k}ybDWT3jz);NF-Dpi69FXttiq8W8#oZmFV7GD?*K{wSwYNNE2!G zRn&*MC=U3V!;>dlueReXS1*e60)~GEkd@p|PV$&*={Wh0->P{|YK?fdi~&y{erW z?-Nwis?7KTN~inC^?GXjYL{f}D062}b(B9jYLpGFs2cEtS>PPPjJ2RPw2^!jvcn6= z>Y5SI4C3RxETL3~)X8BhR$k|M-C) zKQ!riV21pv@&7V*r8I3Jh7ua#VQ1QFsYcpr@7KSgt+?u8Z=|h}e>t_?ABz8$Ms&~j zyt6#!QT#G49$IztH@uM}#9yoU1AEUoQv43Zk9^^K^G9xj)ovSG!H^}m@1wUq^GGQM zEXA#F`K#BRL=wA?Wt@^A5SDJ_pKkovk55!W7}GfEI7E)FT>pyOj09QJ>}+~FV&9;L zAXTI#=&Rb@cNG4+%N`mq#3`Z@FGg@?ZJpsH!31> zo*F;}G6rE-R$l-BZEfRJGpU%W+$HJdK7+IwYH)pF$|gKQz;v~_r1gnZBkM4_%SN^{ zvp_l1HyB1{SE-`uW|6Q9{I+Y{K?#v?8qJ zZ+aM7HZ#7HhcU%Hxq!2f#CdLZ#wJ>QI#;EOrj)yxLjJ0ek?4ig9*S3btGreJ_u~)T z`>uC=?rU$|y~-`>Ea zR`Oh~XB*nj>@d0xp(uCd9oMnEKyc-Ce9jX@Nkr{(8EN?J@G`vm_+CrC>fC)&Q&$Cl zMz!be+iRo0YVM!W?&J6EUG=&5-tfNHe>gV+W9Aa|k&%OU-u3Rg-uWAE)o$y@Y+Ta3 z>!{;r^e2pO^1I771q?8W_g*I68UF|JPP=&MO@7?ljlUn?xEftxq(JKNRS$C^t%;Tk zvSTWO^o_2FHYT~Qw7PztscW~ZE6TasBPvvj0Ckh&)Mi#k;<0A6sY$fIJ3c)MWWFPK zv#e#McQlw%8u_rAGh>N^jthbJT*Sml!A3Z3?n6%5sxepAC1lZ3D;gMczzHG9!Ahe; z$+U*Wx_gMB!HJ*MH7T8SC?OUpEHTm|lZN$4VEtQ^9m6>1I?;mSb~~_wVp&0KPw! ze1(hTj#f3Ux-6A6H(i!8D@snnHOxo%ztKl$+t;!bwzsG_W?4$*IU$=y)#@fd8K5rw zE^9edKq`eQkmQ9dLnS)MvVi>rpHl}w1X(lVBg7%ONXppVjb^jPb%fkz`H9<2mj)E* z51zPdlx>5R?|_Cz>7bi}PRD4DUBQ!C$Uqf1Q1P%8JgG`a!<>BLU?dMc>j{`r2P*kh zVlW-Gg6G5Yt1EcpK*uvsF+x^m4(K#kx!5LTThh2uuS`NnWwo-&AbjJf9j&mkAmG5j zVg*IWaw8*rwYsc)ReIQW*1dEIOVg{FBIJ>gtTCmYTs)6_pVzUuaMA7#55GAnfKn)) zR+lVnyL7``)~ViV1{{m?+Ojxv;3nBoJl6yE9_sj9AUW?C-& zV?8hdxpEjp|98RjDLUV7JdiGC4rm!Pf-Q{b5AzD2WPX}T48Vj}=>e$%lVvCKN*8;~ zZJEh5xiBik3Gv~PV!LLGDK)l{L_2hBMnHaRX|$F;%8s5AMp9`4Npm|koRR&q4p-o9 zkZi2jx^5zIpY>Sdit{^4rxACDb+^2VSJecmsBhSey(PiMv~J?C>7-p#vz?*{kd!36 zpu-b66q<8f{phme*N&r9Q2ZUmparLL7*(@Kr74GPrMQirm}c140?}!kAV7LVYoXA% zCdMH+rq{|rk8;_84vKq2~=I{u-5DseIO~h&$1)R0=Am&9dDR8|``rfF; z_t4LKsweqYUKMeXfD|6$@(rQq2lTXz27CDM8`j@wvm#1*$yFB^hUrm#bbA{88$~nT z_0b1XAW0f(XL*=mF5lMH$d<5pCOe{8IS#a3jLN~X5QdVF0(M_#Etq&C?;=CnZcHlC zP9+b37tBO$HV#H#=EUi-Z2w}Cyvm#?tiYVe08p@u-PLxvLF2wXzB5YI?~Vo}H3`UJ zr1>TZNV~&|(Zn9?`&e1?%r;P724C(yV=Nd>WWirQoSOb@dreaO5l6g!EGeQomSBKp zzAA@QHj7+Z6@I+;XGs@$!$-O{kC7k~m_{C%4LJlL-#^se^>K153`@jQ9T*ILcL6bS}Ox6Z#kn z7-{eW4b=^i>5QSdo)AmZQ!kw4PgU_JzdzU=fAWWCuHpTsuN~@+e_C2I!27%R^ZxFs z`uyXc@;YJ7fIk0GosZvjsA)BU_kMi1J8rY&fA>aS$vI$tCx>oaj;~n!>3=yu^GR6T zVI;gkqf9TDFj}I)VC=WC#HF==8IS3)#wlX)4x9pFc>wyFM-H$k>U5}x&5hD&-y2-a zGE`u3Ab_w(=Psak3dF#j!VHF1IW$6$WN>quO!Wn8%#b6$Z=DbJW2;w6$1;dFDyHR~%uGQ};?=6V$x@fH~ zrr9hS-dl*_yDmCgszrBr#wE zfZ(R_)F2vLb;Sd0L9V`aWP$x98NM$6aSTdN5VD_*V9HLyqvj1wP{@k%7 z?5Z5s?`zALl|pfBFJHwy)m$pCNA>gCmS#E^s&mlue0-~HxgyE=nA6&Xw4;*4&C=v) z<)pot3iH0_d1zD-H^BQBgPIfZ)kDr>hb^BBZa{6Ir3FsUheO!?6x~h}G?HnO-OuLr z4R{l@7$phBUI9?G-Z-(owG?St6CGgz+fr0JlB8hu+(GRi9Ztd4EN4tM32cvVg-G4rhPE49f7*q z2lF0J09yUXoD9XpEK=iVhmdOsb!I?<3J0>C3TpTPC{-&o1^Zp@j=fRS-rC)2POdW> z8YpPWG_(i3(KA=)1+>hEsN(AU2H!c0CO(^{%eDs04B@s^fhX^V2{Z#F=#1YZEc-}a znLxsvAgz5^&X3qWX4rpe`yTQ+GtX8Yu&v?c8hMByrp*Ch?h(fd=GU|!Nha}COj18U zIRYNqG$UkmchqPCl0!nW2}#f_J}A#+kc7BN!Y#9vrHH0vZGt_Sat5@cvhdmfkWJiYDt3y~dPb5fMrd~KKk=*uI1t7o*s zgDi+{i@JE&JQxVAui34+cAu^M=fhF{^SM>IeQi1Bl_L{-Z1b4vI1<&S+z~%AM|uOR z#_sKZdfNcr)6%pyCK)5w=G_6M+dX*uDwZjEd3KwJRO&e3OrBU~<3s4?vCIJ(cbU># zgX}sAl-`vl3hk6(<$OdrbM-kj7r=T&|6-hI*>#DQT{jThkU3OlT|QDW9!1T(X>p;v zk8zLi?a^6z_=V(jWdqu6;uaM9kxwvy#uyP(N^=P^7ZNi}=eCRWtn$Tew3J9MfJ`RsO zieO<(?r|$S*2#PHx|4~U)DI2aI;62@Nt*yXq6LM;lq_dDljR6b(r%S zGe@}Yyao-0Zqy=!ur$*cgRzk3hH+LPQlv?7Xc4`2ZvJj-u*o};KAa!~2$5zG^u2rc`>}%ZrfOkpo`op%XiYhALaP4Mju!QRk*j z(ax@+Em8lD%E0E{{+)Tx{rNl^_!amS`8D#(#x)Tx@oVPS!fyhFnxT*R^S|LgInV z!+o0uY2iR+aB%+c;J|z`b@tBR*g0@b|NMc%)d~Xs~X&Z+Jhx)f}=1TPR6Envx4GXt9@q#Ma{MOqJAvPc{5qp&bq#Lo?c5c0ZQa&e*-CkxL*$MIDnmf5 zvMK89i>#5+a34cb**H|$)Vpi`0Px*7f8+8^n>TK*v@c%Txoqk3_9aUeZ`i!JvSI0h zg&R6IEnnPTS+;c1f{lwe%^uIIfkD0>&vmP%fSP4uN8@qvL|U9rfSAy5Zg-VyYc=UphKccmO3*oPC6Bq&66Kbdb*8&fU6e-R7== z!6C-iVSYykqdQdT=(s|UBNUV-UUy9OZ|Ld+5FH(>>^WYQV3qp7EKD0#UvUDE=YTz( z*HqRpx*K;cto1s)ddc}Nx^uDmI$x(o5F7@ziIrk zG)D6l;?N61t*2XzOGn3W-_C)~ZL?;tkH9z3Z2biT1M4G0aBl|bBYvW7Gx@1({fX}B zPv7;owQFz?Jc>4VReC9U{hWN+=-gR6m3Gtcw%)Fd3|^XoZ9+7Tal70_Q&7rP7+Ss)zx~i*hXzAkU^wXoc(XGUZw%*B8ZOx`xuyA>F zI^VvSl#`}0+}c_h+S0!XLb(q5Ghh=?6f;FCn;;FYPYWnRbRImb3~dxG8l2bF-?4Sq zT*KPAX^ymmTN8Q3T+x~i{pm^uc!URK%Ut)(pWVKQyeU$s)+dx=x|5l@ZXH5JVS zO5lB85?6Jv74^+}?tO%MMd#=7Q`_`+ zH2yd$ek+L91<|c%q9mHdPdKEpn$7PFerNJaY2+NZL8`?%N6Pk5^D`qLcL+!t)cca&}+ zzo!Ok5Kp>>2IqHf+&H||;mgCtvUe5bzmA{kW{Oq@`Z{|Z59^5FZCr4w;x zLvJM#9_n;e|}o{pSCJ!$xXQQ;pFmi(B;KQt=-;ZgDbJSzTQ zN5!+US63g)gmvXVHY%RWx9j5bL4E!r;cWXj_o1$Qd{*k>`vg<=V*WXj_RpF#lw@#t zg9*E1C`H=ykd`dVKtkbDGvOTJb4P_mS z5%S5#;a_A#23&=FOFX$W>G8%b$~18rD-eJ1a=+o5c0jq~gVutCv&9oh@#r zF6Ld5kSN+Uv?q!dD)JL0R+%GE9{r^tb#$X6x^9A#Xr6o@ zQ?YflW;ciufr=s3j(XohJul%YTvki6VM!rrcm?m0EYI)k>+2svKk3{QB_&nICrzt) zs`0(@lCz$5c}Mg-=}ZpUlyyTTl75ZK(-&Pag!*+25rIr*a4d9a!Ufa28UUW%62!pzbSRY+jK~W~?Dll1gFxouOzts{@Q`9vWsS!IX zy}i-k@HQ#A(y~zZx6sCZX<+lBD|klzn?b_?>Pc9by=?A8ZB(07$fho#Cpn~l(yyVN z74W!|3i{?&u0{VQDne;Qx^{}3b=z7sFS=Y>JxO=YNxSLb%4|d)S8Fy@n3i2?15L^H zXkK(>f3$6&ADw8(GFuOa2KtA^Pnkl(&pxJWMcv*OZK09s)WE>5XmkI76>jP_`fC@6 zUuli5u0&gCkVLggFNT7Ol?y#E`NZ^KQHS%f7D#cQ6K(D65uk^*0MM<-lF?wlg!2Br zN`y8YCAIX^kAZnlJr1KSC)SDQPjc3YtHC$Xm@EfhLU^ecAABF&CNHF1&e@xPMd16> z9g!RA?~i(gK7xwu66=hv0l>O|lU^#DkW!kDFPoBer2Jq;e;*o8FSFmu$bQI_a~b7G z$+9$ChPQV1ks%X5l+=@`nOFAr8=4!%7M^VB+_tUK2Oj>!sX0KY0#bcqmy zmK?dUnf8edXWM)6sPMCs@KcXcTOlh0yC8~}V>)97Zo?#}i6nwC+}leVZ=dXxA(29n z#v~znB!)7P5T#4=WzwIQq`xXrbj_XvF0DVo3A8E489+dUBkqc}bq;i*m@;#sE2<>Q z5wi}sw5Z7fG_q^Szm&4m{DWQB^mSr3LfN(<{WS3+*=hV120MxJ9w1KQMbajQ&{}1t zwd@p9Uz7ZoC(XM|txLXLkyh!DDEV5$DwLVT9+qkVly}96WgFvXb?xW^XEyALURD|C z?})bXT`VXS3#1h6=d5R{ym?C5JB>0^7-O{T1o>Zv zbd}mL&WSMM4tMsRb2e!uLOh?RM1VBUDpM6|g>EBW{kafh=RnuSD&%hFyA+^gAfj!< z8^l~vbn^BSFA)|KRM%!%U4+I-?0v*dCayLhDU=6cFdHk`G4CLq8=F9cK>nvjK&Qe@*bU$5BGd&QQ4%ldadXSf$L za=d9%f)P#zwmEq6w6ZM#Jd>vu1J2|rx{$($a{CARx5=EsNYu9>BArF`ZCa2#7mghp zE1|A!E6Hb+po*Y2htf&p-9Z~9dViK@k!N-sYwhXV)a9gHtPb0UD}%^P#`t7}Fk5V2 z|2iz>TdJ1WM2{ZstBOo%PU?7sx`da%=c)Nyn(m%6cxr*9ji+dhcwI#>Noz?ePexJr zjIq!JCP%=?b1ivg%&eOWgx|?`vHMk>LmRg^B=z-!T?$fJ>#p%HYOM=b2_GO%Xs=L zPS4~MV0YHw8qIpv`R(mL9eMM!Rxy6QieL5k#jCUqm9}=Z zMjPoqWoz}I8z(v$(Q$J2Mg4{WBl!O zT}m6aRIZKUE6!iDW^`vgFD>)!lqH(_H1&CF|0bu3N2fSd{8Z|a`kaPe!FyXKyoYxg z$X7W-19Nz@38;6H|LJNcqc%Tn=zY}lQtJOCKeaOrf5XD@{RhynS|1nqthe7w!o#O! zQjQtcClB(m_SdR~hi1Mra#o!;@h+>}utc__*>qTFO07_7UZI6V(=_}k-i3bIaFhw( z#k)kSG+tq$b{hU2?-Ebb@MFBoYLpF2d`!cC;9cT>Hr$#CACIauZ&X;rm8PFed^TJf zm0sa&d<$W*`80p?sQ8Ja!csMrziL1+-hcEpfc0%|4WMSF#L~32Q_c|sZy`=1Y+8S6 zu}#BgCH1A;$oTQ#uB{s&WN?hln`L7HAonNbJj_$=`&XW1^)5*HWaZi_`!u^~XS8(g zhA!E>l9tT#iq9z9no3%itfdiUoXvNMC8NtuMZ&SxLdQa7;V~PlnOx1d@KmCHb?M=4 zwC^g~cQ-%bZfn~!PJQNSr_Y*w#+h^Gwl7$?Xz`Mz%a*TL8LvA3Sr@Fn@S-)(zW9>o zTzc7aFTdi-tDg7#7rgLA>pM4W+*H}p)!oy(b=&rV`gCiPgjbW&(rv!RrR?h`?cmVx zj-A);dReWSGv~~k|EHBOZ+@+`CsWds$y2Lw?z%rM|C#f(1^1|bo(@#cHx!DEO{M0; zhg&90EKfS__{k@n=yFY&I&J!lnJ1lmN@OE>I2p>ra{-J}xDh>km@(}*>+Hja&pG!z zm+^nzzt(bxo^<7$qyu&EsX+(0xCB|~q^*jB*}I$Hb^Ole_ZU3-x-HJRPN7_r^*{P}GIlN!WFZ*pR;q|f- zAWwYjOlN+X6M5c2-evN*pQmJ<^l1w5`daug;$_N81EICO=AGPCo{I2Gwwx#fYKJPE! z_dd?zU-o+^;Xm0YXYK6hx!EZC;esQSHAh=mpN|s*aFC$^lWxCxTSv>UqehgXP+aTESiM^yuNd2eS{+|NF`n2 zTKh;@U!-iA4({MNh3CyY1%o#xbzY2pQu6w0mWXA3HWR72KGcuT2GW@N!ZSN=8wn>8 z{LZvlTFel5Z5h}CGMOc*wBk6p6&T70w%M8+Ijgv>QDjo}%2qyps;3GTfr8H-4b$Qz?tX$X1=2dPh?)LB#-{O>|cjZ-3lAf@!AmK*&tidV23k` zGC+)vt?kQ5>Jst=Q)|2KO2rJzQ}cd3>nUmZujU)*P{pOHx1w--!*EwG`k)*b)Q)uS z$+X+cZ!5ouzjr3(FC^T`FAYmaSAEgTo8~mliK3TBuZUhTt7+Dp*-bA}dFfp3tW7A;!5Xvw0biE6@#4ix7B5}AZ1M8NE0(k`S+Hc`l0{1vFIlo=>5^qjmM>Ycw0-G< zr3;rXTDo}YlBG+R;tRfX#j^Hg3zjWhwrJVnWlNSVUAAo5@?|TQw=Z9?eBts%%NH+S zvV7_CWy_Z@U$KHFuAurA6up9MEBMqY$9P*k+Kh2p>)vN<#OfTK8!cGjd1=3Y&P39D z&BCmo@HT$i`Hc&@#D?_zg${OSKukqz)9?bqTEZHWcMy(Ina>*S#w`QD{w?H>NGIB> zHVkz3FR9)$!+i;LVcMjG$(yV7fG zzJ}RkvISso7J1bEb9sucjP1wJzteTJb1P4QZ68yXBD@VO z!S{*2Ycyu*Wwx`NXbiMiLf-qyGl8@}=BX+BQ=TGDX&JS(4J|x4qJ-=JS&@jY%q)Xi ze2!*0N4MG5qO?7em$+5k4xVE7t9VK*O3NNItjT)G{B7*27?M{j155gC+ zO z!_e@b&tG@iy!p3%^salp^3Cu4n6Y?G5q(Vc!T)4Ur z6i#TlEO&l5H}rFp8YVV(z`Xtc zJujX-^6BEp-<`2MY-(6uTwQGDa>|p#7v^5jICA6EnN24)UXmMmO~Z%Z-#jI^;61rL zKRB(>oX?N^)ucUJ%h%32qk-7hd9*MwZzpA;OIKYr3= z|Ab&lFs)@~{-olmes|at+#P%?_;&Mm8owKSFZh9fF#k~Si{O{hq1>ave*_?^-+cO6 z=U%$@4exr_yBi9POV2s?dH?tRZ{;RWUApXfSMUDNM?U(wB?pgt)vI6st}6No`z~F( zsq*4a-8Exoq1aTKJZ0&Mj{P5e;QNisZhqtbLep92Zti-+oBG%N^50&#;V<5C`mC$| z^49mf@BO#!zvHj({$fL^`Gk`?&b#2bAGqynU%$05ZF<`?&pq!;U(Q9(c;;!d7A^0% z=-HQCb_J$QaBTg?%I2QIYhSVZHShn>NAEmv|3^N$>uY`eZ+>ap%kv>avN`nU&l|bn zq;SE+nYmLNPtKp2e^ze786zKRI5l@_ZdP$|$sf6S&$7l7n~Ed1tOz$28{1Fh0JRx; zf93Mr#rgTUrb1(3WpsM3xp8UOk)K}3H5V>hvushzqQbml)1K2VzjRjdjOWdqJf-o{ z+{qKqpD?Y^)NoPp^v2=RdGQ$yXXTq3p35=I-9KWK_ zv~*6cJaXXdO;fIJ-InLc=Er^iOxKu z{nj)4Kd^pIu>atklYf73uJ^}Vm%Qun!6kq2JD2)R?^$|kOXso=Pk3ng{Hd)g+GlpI z{=X-`=h=t4J1i3#30AvB%yzD5OQP+;XDca$-#+`3Q|*Y(JzEe!O8wv zzbUEa3}fDF^n>3p*5H7DGj-+ssA*P%jZQ-l&I8C^0WkQNpBNNW z+RGZK062qPs>-MRuqV$yFZW!%)6ZPKSPTj$=iU-}%W?~g{sjNTyg!jrCRqu2Ff`{C LwidkgBZvNfH*|U9 diff --git a/go.mod b/go.mod index 333a2b2005b..19bfd5df103 100644 --- a/go.mod +++ b/go.mod @@ -66,7 +66,7 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d diff --git a/go.sum b/go.sum index ee241534c5b..1aca3fcc6d1 100644 --- a/go.sum +++ b/go.sum @@ -1434,8 +1434,8 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b h1:vh4N/K+TMG8oV7L2i4U8q5aMjlVgf5M8TAZJCsXUh4U= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b/go.mod h1:TtLMvOtGV9hwNg59iJj+Sa0vL0Kq3o3eF+6uSIRixDc= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726/go.mod h1:TtLMvOtGV9hwNg59iJj+Sa0vL0Kq3o3eF+6uSIRixDc= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 10f017cd519..c6293a5e61f 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1362,7 +1362,7 @@ github.com/slack-go/slack v0.12.2 h1:x3OppyMyGIbbiyFhsBmpf9pwkUzMhthJMRNmNlA4LaQ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQdlMQKOw= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230725012331-9007d9fb0d7b h1:vh4N/K+TMG8oV7L2i4U8q5aMjlVgf5M8TAZJCsXUh4U= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= github.com/smartcontractkit/chainlink-env v0.35.2 h1:KhlY2LgEq5e6Or5qlkCGIv0MJjJUA0mMVTgLdWptRAM= github.com/smartcontractkit/chainlink-env v0.35.2/go.mod h1:hMOkTDW5k0C5B5lup1+xpPiZQPkq84YGLuFDVdTKU7A= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= diff --git a/tools/ci/install_wasmd b/tools/ci/install_wasmd new file mode 100755 index 00000000000..f12b9d173b1 --- /dev/null +++ b/tools/ci/install_wasmd @@ -0,0 +1,14 @@ +#!/usr/bin/env bash + +set -euo pipefail + +# commit on branch releases/v0.40.x +GIT_TAG="v0.40.1" + +CHECKOUT_DIR="${HOME}/wasmd-checkout" +BUILD_DIR="${HOME}/wasmd-build" + +git clone https://github.com/CosmWasm/wasmd --branch "releases/v0.40.x" "${CHECKOUT_DIR}" +cd "${CHECKOUT_DIR}" +git checkout "${GIT_TAG}" +GOPATH="${BUILD_DIR}" make install From 140fae8ab108511b6b1a75f56c0b4c14afbe109b Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Tue, 1 Aug 2023 19:04:59 +0300 Subject: [PATCH 050/270] Refactor basic tests with testcontainers (#9970) * wip * wip - cron * wip - 5+ tests, ragep2p issues * rollback ocr/ocr2 * comments, cleanup * increase timeouts * rollback go.mod * re-use mercury env as a boilerplate * re-use mercury env as a boilerplate * fix action's Go version * update go.mod from develop * explicitly login into aws registry * update deps * set explicit go version * re-trigger * github-action v2.2.2 * fix the client * reusable envs * review fixes * review fixes --- .github/workflows/integration-tests.yml | 5 +- charts/chainlink-cluster/devspace.yaml | 2 +- integration-tests/client/chainlink.go | 4 +- integration-tests/docker/README.md | 21 + integration-tests/docker/cmd/test_env.go | 76 + integration-tests/docker/docker.go | 30 + integration-tests/docker/test_env/cl_node.go | 256 ++++ integration-tests/docker/test_env/geth.go | 241 ++++ .../docker/test_env/mockserver.go | 109 ++ integration-tests/docker/test_env/test_env.go | 254 ++++ .../docker/test_env/test_env_builder.go | 198 +++ .../docker/test_env/test_env_config.go | 42 + integration-tests/go.mod | 120 +- integration-tests/go.sum | 1284 ++++++++++++++++- integration-tests/smoke/cron_test.go | 80 +- integration-tests/smoke/flux_test.go | 124 +- integration-tests/smoke/runlog_test.go | 97 +- integration-tests/smoke/vrf_test.go | 96 +- integration-tests/types/envcommon/common.go | 86 ++ integration-tests/types/node/node_config.go | 79 + integration-tests/types/types.go | 52 + integration-tests/utils/cl_node_jobs.go | 128 ++ integration-tests/utils/log.go | 19 + integration-tests/utils/templates/geth.go | 71 + .../utils/templates/node_secrets.go | 44 + 25 files changed, 3165 insertions(+), 353 deletions(-) create mode 100644 integration-tests/docker/README.md create mode 100644 integration-tests/docker/cmd/test_env.go create mode 100644 integration-tests/docker/docker.go create mode 100644 integration-tests/docker/test_env/cl_node.go create mode 100644 integration-tests/docker/test_env/geth.go create mode 100644 integration-tests/docker/test_env/mockserver.go create mode 100644 integration-tests/docker/test_env/test_env.go create mode 100644 integration-tests/docker/test_env/test_env_builder.go create mode 100644 integration-tests/docker/test_env/test_env_config.go create mode 100644 integration-tests/types/envcommon/common.go create mode 100644 integration-tests/types/node/node_config.go create mode 100644 integration-tests/types/types.go create mode 100644 integration-tests/utils/cl_node_jobs.go create mode 100644 integration-tests/utils/log.go create mode 100644 integration-tests/utils/templates/geth.go create mode 100644 integration-tests/utils/templates/node_secrets.go diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index e5955400505..de5f97c0681 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -208,8 +208,9 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.3 env: + TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }} @@ -218,6 +219,8 @@ jobs: test_download_vendor_packages_command: cd ./integration-tests && go mod download cl_repo: ${{ env.CHAINLINK_IMAGE }} cl_image_tag: ${{ github.sha }} + go_version: '1.20.5' + aws_registries: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} artifacts_location: ./integration-tests/smoke/logs publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} diff --git a/charts/chainlink-cluster/devspace.yaml b/charts/chainlink-cluster/devspace.yaml index 26998ab4f71..63b6f112fec 100644 --- a/charts/chainlink-cluster/devspace.yaml +++ b/charts/chainlink-cluster/devspace.yaml @@ -19,7 +19,7 @@ pipelines: run: |- run_dependencies --all # 1. Deploy any projects this project needs (see "dependencies") ensure_pull_secrets --all # 2. Ensure pull secrets - build_images --all -t $(git describe --always) # 3. Build, tag (git commit hash) and push all images (see "images") + build_images --all -t $(git rev-parse --short HEAD) # 3. Build, tag (git commit hash) and push all images (see "images") create_deployments --all # 4. Deploy Helm charts and manifests specfied as "deployments" images: diff --git a/integration-tests/client/chainlink.go b/integration-tests/client/chainlink.go index 4f1c1f2c818..ffda44c3148 100644 --- a/integration-tests/client/chainlink.go +++ b/integration-tests/client/chainlink.go @@ -62,12 +62,12 @@ func initRestyClient(url string, email string, password string, timeout *time.Du // Retry the connection on boot up, sometimes pods can still be starting up and not ready to accept connections var resp *resty.Response var err error - retryCount := 5 + retryCount := 20 for i := 0; i < retryCount; i++ { resp, err = rc.R().SetBody(session).Post("/sessions") if err != nil { log.Debug().Err(err).Str("URL", url).Interface("Session Details", session).Msg("Error connecting to Chainlink node, retrying") - time.Sleep(3 * time.Second) + time.Sleep(5 * time.Second) } else { break } diff --git a/integration-tests/docker/README.md b/integration-tests/docker/README.md new file mode 100644 index 00000000000..b8ef1fc49d2 --- /dev/null +++ b/integration-tests/docker/README.md @@ -0,0 +1,21 @@ +## Docker environment +This folder contains Chainlink cluster environment created with `testcontainers-go` + +### CLI for Local Testing Environment + +The command-line interface (CLI) located at `./integration-tests/docker/cmd/test_env.go` can be utilized to initiate a local testing environment. It is intended to replace Docker Compose in the near future. + + +Example: +``` +# Set required envs +export CHAINLINK_IMAGE="" +export CHAINLINK_VERSION="" +# Stream logs to Loki +export LOKI_TOKEN=... +export LOKI_URL=https://${loki_host}/loki/api/v1/push + +cd ./integration-tests/docker/cmd + +go run test_env.go start-env cl-cluster +``` \ No newline at end of file diff --git a/integration-tests/docker/cmd/test_env.go b/integration-tests/docker/cmd/test_env.go new file mode 100644 index 00000000000..059df5a3b62 --- /dev/null +++ b/integration-tests/docker/cmd/test_env.go @@ -0,0 +1,76 @@ +package main + +import ( + "io" + defaultlog "log" + "os" + "os/signal" + "syscall" + + "github.com/rs/zerolog" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/smartcontractkit/chainlink/integration-tests/utils" + "github.com/spf13/cobra" + "github.com/testcontainers/testcontainers-go" +) + +func main() { + rootCmd := &cobra.Command{ + Use: "test_env", + Short: "CL cluster docker test env management tool", + } + + startEnvCmd := &cobra.Command{ + Use: "start-env", + Short: "Start new docker test env", + } + rootCmd.AddCommand(startEnvCmd) + + startFullEnvCmd := &cobra.Command{ + Use: "cl-cluster", + Short: "Basic CL cluster", + RunE: func(cmd *cobra.Command, args []string) error { + utils.SetupGlobalLogger() + log.Info().Msg("Starting CL cluster test environment..") + + _, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(6). + Build() + if err != nil { + return err + } + + log.Info().Msg("Cl cluster is ready") + + handleExitSignal() + + return nil + }, + } + startEnvCmd.AddCommand(startFullEnvCmd) + + // Set default log level for non-testcontainer code + zerolog.SetGlobalLevel(zerolog.InfoLevel) + + // Discard testcontainers logs + testcontainers.Logger = defaultlog.New(io.Discard, "", defaultlog.LstdFlags) + + if err := rootCmd.Execute(); err != nil { + log.Error().Err(err).Msg("Error") + os.Exit(1) + } +} + +func handleExitSignal() { + // Create a channel to receive exit signals + exitChan := make(chan os.Signal, 1) + signal.Notify(exitChan, os.Interrupt, syscall.SIGTERM) + + log.Info().Msg("Press Ctrl+C to destroy the test environment") + + // Block until an exit signal is received + <-exitChan +} diff --git a/integration-tests/docker/docker.go b/integration-tests/docker/docker.go new file mode 100644 index 00000000000..d5803e0a163 --- /dev/null +++ b/integration-tests/docker/docker.go @@ -0,0 +1,30 @@ +package docker + +import ( + "context" + "fmt" + + "github.com/google/uuid" + "github.com/rs/zerolog/log" + tc "github.com/testcontainers/testcontainers-go" +) + +func CreateNetwork() (*tc.DockerNetwork, error) { + uuidObj, _ := uuid.NewRandom() + var networkName = fmt.Sprintf("network-%s", uuidObj.String()) + network, err := tc.GenericNetwork(context.Background(), tc.GenericNetworkRequest{ + NetworkRequest: tc.NetworkRequest{ + Name: networkName, + CheckDuplicate: true, + }, + }) + if err != nil { + return nil, err + } + dockerNetwork, ok := network.(*tc.DockerNetwork) + if !ok { + return nil, fmt.Errorf("failed to cast network to *dockertest.Network") + } + log.Trace().Any("network", dockerNetwork).Msgf("created network") + return dockerNetwork, nil +} diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go new file mode 100644 index 00000000000..901423b6335 --- /dev/null +++ b/integration-tests/docker/test_env/cl_node.go @@ -0,0 +1,256 @@ +package test_env + +import ( + "context" + "fmt" + "io/ioutil" + "os" + "strings" + "time" + + "github.com/pkg/errors" + + "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/common" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/client" + env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" + "github.com/smartcontractkit/chainlink/integration-tests/types/node" + "github.com/smartcontractkit/chainlink/integration-tests/utils" + "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" + "math/big" +) + +type ClNode struct { + env.EnvComponent + API *client.ChainlinkClient + NodeConfigOpts node.NodeConfigOpts + DbC *tc.Container + DbCName string + DbOpts env.PgOpts +} + +func NewClNode(compOpts env.EnvComponentOpts, opts node.NodeConfigOpts, dbContainerName string) *ClNode { + return &ClNode{ + EnvComponent: env.NewEnvComponent("cl-node", compOpts), + DbCName: dbContainerName, + NodeConfigOpts: opts, + DbOpts: env.NewDefaultPgOpts("cl-node", compOpts.Networks), + } +} + +func (m *ClNode) AddBootstrapJob(verifierAddr common.Address, fromBlock uint64, chainId int64, + feedId [32]byte) (*client.Job, error) { + spec := utils.BuildBootstrapSpec(verifierAddr, chainId, fromBlock, feedId) + return m.API.MustCreateJob(spec) +} + +func (m *ClNode) GetContainerName() string { + name, err := m.EnvComponent.Container.Name(context.Background()) + if err != nil { + return "" + } + return strings.Replace(name, "/", "", -1) +} + +func (m *ClNode) GetPeerUrl() (string, error) { + p2pKeys, err := m.API.MustReadP2PKeys() + if err != nil { + return "", err + } + p2pId := p2pKeys.Data[0].Attributes.PeerID + + return fmt.Sprintf("%s@%s:%d", p2pId, m.GetContainerName(), 6690), nil +} + +func (m *ClNode) GetNodeCSAKeys() (*client.CSAKeys, error) { + csaKeys, _, err := m.API.ReadCSAKeys() + if err != nil { + return nil, err + } + return csaKeys, err +} + +func (m *ClNode) ChainlinkNodeAddress() (common.Address, error) { + addr, err := m.API.PrimaryEthAddress() + if err != nil { + return common.Address{}, err + } + return common.HexToAddress(addr), nil +} + +func (m *ClNode) Fund(g *Geth, amount *big.Float) error { + toAddress, err := m.API.PrimaryEthAddress() + if err != nil { + return err + } + gasEstimates, err := g.EthClient.EstimateGas(ethereum.CallMsg{}) + if err != nil { + return err + } + return g.EthClient.Fund(toAddress, amount, gasEstimates) +} + +func (m *ClNode) StartContainer(lw *logwatch.LogWatch) error { + pgReq := env.GetPgContainerRequest(m.DbCName, m.DbOpts) + pgC, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ + ContainerRequest: *pgReq, + Started: true, + Reuse: true, + }) + if err != nil { + return err + } + + nodeSecrets, err := templates.ExecuteNodeSecretsTemplate(pgReq.Name, "5432") + if err != nil { + return err + } + clReq, err := m.getContainerRequest(nodeSecrets) + if err != nil { + return err + } + clC, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ + ContainerRequest: *clReq, + Started: true, + Reuse: true, + }) + if err != nil { + return errors.Wrapf(err, "could not start chainlink node container") + } + if lw != nil { + if err := lw.ConnectContainer(context.Background(), clC, "chainlink", true); err != nil { + return err + } + } + ctName, err := clC.Name(context.Background()) + if err != nil { + return err + } + ctName = strings.Replace(ctName, "/", "", -1) + clEndpoint, err := clC.Endpoint(context.Background(), "http") + if err != nil { + return err + } + + log.Info().Str("containerName", ctName). + Str("clEndpoint", clEndpoint). + Msg("Started Chainlink Node container") + + clClient, err := client.NewChainlinkClient(&client.ChainlinkConfig{ + URL: clEndpoint, + Email: "local@local.com", + Password: "localdevpassword", + }) + if err != nil { + return errors.Wrapf(err, "could not connect Node HTTP Client") + } + + m.EnvComponent.Container = clC + m.DbC = &pgC + m.API = clClient + + return nil +} + +func (m *ClNode) getContainerRequest(secrets string) ( + *tc.ContainerRequest, error) { + configFile, err := ioutil.TempFile("", "node_config") + if err != nil { + return nil, err + } + config, err := node.ExecuteNodeConfigTemplate(m.NodeConfigOpts) + if err != nil { + return nil, err + } + _, err = configFile.WriteString(config) + if err != nil { + return nil, err + } + + secretsFile, err := ioutil.TempFile("", "node_secrets") + if err != nil { + return nil, err + } + _, err = secretsFile.WriteString(secrets) + if err != nil { + return nil, err + } + + adminCreds := "local@local.com\nlocaldevpassword" + adminCredsFile, err := ioutil.TempFile("", "admin_creds") + if err != nil { + return nil, err + } + _, err = adminCredsFile.WriteString(adminCreds) + if err != nil { + return nil, err + } + + apiCreds := "local@local.com\nlocaldevpassword" + apiCredsFile, err := ioutil.TempFile("", "api_creds") + if err != nil { + return nil, err + } + _, err = apiCredsFile.WriteString(apiCreds) + if err != nil { + return nil, err + } + + configPath := "/home/cl-node-config.toml" + secretsPath := "/home/cl-node-secrets.toml" + adminCredsPath := "/home/admin-credentials.txt" + apiCredsPath := "/home/api-credentials.txt" + + image, ok := os.LookupEnv("CHAINLINK_IMAGE") + if !ok { + return nil, errors.New("CHAINLINK_IMAGE env must be set") + } + tag, ok := os.LookupEnv("CHAINLINK_VERSION") + if !ok { + return nil, errors.New("CHAINLINK_VERSION env must be set") + } + + return &tc.ContainerRequest{ + Name: m.EnvComponent.ContainerName, + Image: fmt.Sprintf("%s:%s", image, tag), + ExposedPorts: []string{"6688/tcp"}, + Entrypoint: []string{"chainlink", + "-c", configPath, + "-s", secretsPath, + "node", "start", "-d", + "-p", adminCredsPath, + "-a", apiCredsPath, + }, + Networks: m.Networks, + WaitingFor: tcwait.ForHTTP("/health"). + WithPort("6688/tcp"). + WithStartupTimeout(90 * time.Second). + WithPollInterval(1 * time.Second), + Files: []tc.ContainerFile{ + { + HostFilePath: configFile.Name(), + ContainerFilePath: configPath, + FileMode: 0644, + }, + { + HostFilePath: secretsFile.Name(), + ContainerFilePath: secretsPath, + FileMode: 0644, + }, + { + HostFilePath: adminCredsFile.Name(), + ContainerFilePath: adminCredsPath, + FileMode: 0644, + }, + { + HostFilePath: apiCredsFile.Name(), + ContainerFilePath: apiCredsPath, + FileMode: 0644, + }, + }, + }, nil +} diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go new file mode 100644 index 00000000000..720de6fea27 --- /dev/null +++ b/integration-tests/docker/test_env/geth.go @@ -0,0 +1,241 @@ +package test_env + +import ( + "context" + "fmt" + "io/ioutil" + "strings" + + "github.com/ethereum/go-ethereum/accounts" + "github.com/ethereum/go-ethereum/accounts/keystore" + "github.com/pkg/errors" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" + env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" + "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" + "time" +) + +const ( + // RootFundingAddr is the static key that hardhat is using + // https://hardhat.org/hardhat-runner/docs/getting-started + // if you need more keys, keep them compatible, so we can swap Geth to Ganache/Hardhat in the future + RootFundingAddr = `0xf39fd6e51aad88f6f4ce6ab8827279cfffb92266` + RootFundingWallet = `{"address":"f39fd6e51aad88f6f4ce6ab8827279cfffb92266","crypto":{"cipher":"aes-128-ctr","ciphertext":"c36afd6e60b82d6844530bd6ab44dbc3b85a53e826c3a7f6fc6a75ce38c1e4c6","cipherparams":{"iv":"f69d2bb8cd0cb6274535656553b61806"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":262144,"p":1,"r":8,"salt":"80d5f5e38ba175b6b89acfc8ea62a6f163970504af301292377ff7baafedab53"},"mac":"f2ecec2c4d05aacc10eba5235354c2fcc3776824f81ec6de98022f704efbf065"},"id":"e5c124e9-e280-4b10-a27b-d7f3e516b408","version":3}` +) + +type Geth struct { + env.EnvComponent + ExternalHttpUrl string + InternalHttpUrl string + ExternalWsUrl string + InternalWsUrl string + EthClient blockchain.EVMClient + ContractDeployer contracts.ContractDeployer +} + +func NewGeth(compOpts env.EnvComponentOpts) *Geth { + return &Geth{ + EnvComponent: env.NewEnvComponent("geth", compOpts), + } +} + +func (m *Geth) StartContainer(lw *logwatch.LogWatch) error { + r, _, _, err := m.getGethContainerRequest(m.Networks) + if err != nil { + return err + } + ct, err := tc.GenericContainer(context.Background(), + tc.GenericContainerRequest{ + ContainerRequest: *r, + Started: true, + Reuse: true, + }) + if err != nil { + return errors.Wrapf(err, "cannot start geth container") + } + if lw != nil { + if err := lw.ConnectContainer(context.Background(), ct, "geth", true); err != nil { + return err + } + } + host, err := ct.Host(context.Background()) + if err != nil { + return err + } + httpPort, err := ct.MappedPort(context.Background(), "8544/tcp") + if err != nil { + return err + } + wsPort, err := ct.MappedPort(context.Background(), "8545/tcp") + if err != nil { + return err + } + ctName, err := ct.Name(context.Background()) + if err != nil { + return err + } + ctName = strings.Replace(ctName, "/", "", -1) + + m.EnvComponent.Container = ct + m.ExternalHttpUrl = fmt.Sprintf("http://%s:%s", host, httpPort.Port()) + m.InternalHttpUrl = fmt.Sprintf("http://%s:8544", ctName) + m.ExternalWsUrl = fmt.Sprintf("ws://%s:%s", host, wsPort.Port()) + m.InternalWsUrl = fmt.Sprintf("ws://%s:8545", ctName) + + networkConfig := blockchain.SimulatedEVMNetwork + networkConfig.Name = "geth" + networkConfig.URLs = []string{m.ExternalWsUrl} + networkConfig.HTTPURLs = []string{m.ExternalWsUrl} + + bc, err := blockchain.NewEVMClientFromNetwork(networkConfig) + if err != nil { + return err + } + m.EthClient = bc + cd, err := contracts.NewContractDeployer(bc) + if err != nil { + return err + } + m.ContractDeployer = cd + + log.Info().Str("containerName", ctName). + Str("internalHttpUrl", m.InternalHttpUrl). + Str("externalHttpUrl", m.ExternalHttpUrl). + Str("externalWsUrl", m.ExternalWsUrl). + Str("internalWsUrl", m.InternalWsUrl). + Msg("Started Geth container") + + return nil +} + +func (m *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, *keystore.KeyStore, *accounts.Account, error) { + chainId := "1337" + blocktime := "1" + + initScriptFile, err := ioutil.TempFile("", "init_script") + if err != nil { + return nil, nil, nil, err + } + _, err = initScriptFile.WriteString(templates.InitGethScript) + if err != nil { + return nil, nil, nil, err + } + keystoreDir, err := ioutil.TempDir("", "keystore") + if err != nil { + return nil, nil, nil, err + } + // Create keystore and ethereum account + ks := keystore.NewKeyStore(keystoreDir, keystore.StandardScryptN, keystore.StandardScryptP) + account, err := ks.NewAccount("") + if err != nil { + return nil, ks, &account, err + } + genesisJsonStr, err := templates.BuildGenesisJson(chainId, account.Address.Hex()) + if err != nil { + return nil, ks, &account, err + } + genesisFile, err := ioutil.TempFile("", "genesis_json") + if err != nil { + return nil, ks, &account, err + } + _, err = genesisFile.WriteString(genesisJsonStr) + if err != nil { + return nil, ks, &account, err + } + key1File, err := ioutil.TempFile(keystoreDir, "key1") + if err != nil { + return nil, ks, &account, err + } + _, err = key1File.WriteString(RootFundingWallet) + if err != nil { + return nil, ks, &account, err + } + configDir, err := ioutil.TempDir("", "config") + if err != nil { + return nil, ks, &account, err + } + err = ioutil.WriteFile(configDir+"/password.txt", []byte(""), 0644) + if err != nil { + return nil, ks, &account, err + } + + return &tc.ContainerRequest{ + Name: m.ContainerName, + Image: "ethereum/client-go:stable", + ExposedPorts: []string{"8544/tcp", "8545/tcp"}, + Networks: networks, + WaitingFor: tcwait.ForLog("Commit new sealing work"). + WithStartupTimeout(999 * time.Second). + WithPollInterval(1 * time.Second), + Entrypoint: []string{"sh", "./root/init.sh", + "--dev", + "--password", "/root/config/password.txt", + "--datadir", + "/root/.ethereum/devchain", + "--unlock", + RootFundingAddr, + "--mine", + "--miner.etherbase", + RootFundingAddr, + "--ipcdisable", + "--http", + "--http.vhosts", + "*", + "--http.addr", + "0.0.0.0", + "--http.port=8544", + "--ws", + "--ws.origins", + "*", + "--ws.addr", + "0.0.0.0", + "--ws.port=8545", + "--graphql", + "-graphql.corsdomain", + "*", + "--allow-insecure-unlock", + "--rpc.allow-unprotected-txs", + "--http.api", + "eth,web3,debug", + "--http.corsdomain", + "*", + "--vmdebug", + fmt.Sprintf("--networkid=%s", chainId), + "--rpc.txfeecap", + "0", + "--dev.period", + blocktime, + }, + Files: []tc.ContainerFile{ + { + HostFilePath: initScriptFile.Name(), + ContainerFilePath: "/root/init.sh", + FileMode: 0644, + }, + { + HostFilePath: genesisFile.Name(), + ContainerFilePath: "/root/genesis.json", + FileMode: 0644, + }, + }, + Mounts: tc.ContainerMounts{ + tc.ContainerMount{ + Source: tc.GenericBindMountSource{ + HostPath: keystoreDir, + }, + Target: "/root/.ethereum/devchain/keystore/", + }, + tc.ContainerMount{ + Source: tc.GenericBindMountSource{ + HostPath: configDir, + }, + Target: "/root/config/", + }, + }, + }, ks, &account, nil +} diff --git a/integration-tests/docker/test_env/mockserver.go b/integration-tests/docker/test_env/mockserver.go new file mode 100644 index 00000000000..2810ef74609 --- /dev/null +++ b/integration-tests/docker/test_env/mockserver.go @@ -0,0 +1,109 @@ +package test_env + +import ( + "context" + "fmt" + "net/url" + "strings" + "time" + + "github.com/pkg/errors" + "github.com/rs/zerolog/log" + ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" +) + +type MockServer struct { + env.EnvComponent + Client *ctfClient.MockserverClient + Endpoint string + InternalEndpoint string + EAMockUrls []*url.URL +} + +func NewMockServer(compOpts env.EnvComponentOpts) *MockServer { + return &MockServer{ + EnvComponent: env.NewEnvComponent("mockserver", compOpts), + } +} + +func (m *MockServer) SetExternalAdapterMocks(count int) error { + for i := 0; i < count; i++ { + path := fmt.Sprintf("/ea-%d", i) + err := m.Client.SetRandomValuePath(path) + if err != nil { + return err + } + cName, err := m.EnvComponent.Container.Name(context.Background()) + if err != nil { + return err + } + cName = strings.Replace(cName, "/", "", -1) + eaUrl, err := url.Parse(fmt.Sprintf("http://%s:%s%s", + cName, "1080", path)) + if err != nil { + return err + } + m.EAMockUrls = append(m.EAMockUrls, eaUrl) + } + return nil +} + +func (m *MockServer) StartContainer(lw *logwatch.LogWatch) error { + c, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ + ContainerRequest: m.getContainerRequest(), + Started: true, + Reuse: true, + }) + if err != nil { + return errors.Wrapf(err, "cannot start mock server container") + } + if lw != nil { + if err := lw.ConnectContainer(context.Background(), c, m.ContainerName, true); err != nil { + return err + } + } + cName, err := c.Name(context.Background()) + if err != nil { + return err + } + cName = strings.Replace(cName, "/", "", -1) + endpoint, err := c.Endpoint(context.Background(), "http") + if err != nil { + return err + } + log.Info().Any("endpoint", endpoint).Str("containerName", cName). + Msgf("Started mockserver container") + m.Endpoint = endpoint + m.InternalEndpoint = fmt.Sprintf("http://%s:%s", cName, "1080") + + client := ctfClient.NewMockserverClient(&ctfClient.MockserverConfig{ + LocalURL: endpoint, + ClusterURL: m.InternalEndpoint, + }) + if err != nil { + return errors.Wrapf(err, "cannot connect to mockserver client") + } + m.EnvComponent.Container = c + m.Client = client + + return nil +} + +func (m *MockServer) getContainerRequest() tc.ContainerRequest { + return tc.ContainerRequest{ + Name: m.ContainerName, + Image: "mockserver/mockserver:5.11.2", + ExposedPorts: []string{"1080/tcp"}, + Env: map[string]string{ + "SERVER_PORT": "1080", + }, + Networks: m.Networks, + WaitingFor: tcwait.ForLog("INFO 1080 started on port: 1080"). + WithStartupTimeout(30 * time.Second). + WithPollInterval(100 * time.Millisecond), + } +} diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go new file mode 100644 index 00000000000..f336ac225a9 --- /dev/null +++ b/integration-tests/docker/test_env/test_env.go @@ -0,0 +1,254 @@ +package test_env + +import ( + "crypto/ed25519" + "encoding/hex" + "strings" + "sync" + + "fmt" + "github.com/ethereum/go-ethereum/common" + "github.com/google/uuid" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/integration-tests/docker" + env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" + "github.com/smartcontractkit/chainlink/integration-tests/types/node" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" + "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + tc "github.com/testcontainers/testcontainers-go" + "go.uber.org/multierr" + "math/big" +) + +type CLClusterTestEnv struct { + cfg *TestEnvConfig + Network *tc.DockerNetwork + LogWatch *logwatch.LogWatch + CLNodes []*ClNode + Geth *Geth + MockServer *MockServer +} + +func NewTestEnv() (*CLClusterTestEnv, error) { + network, err := docker.CreateNetwork() + if err != nil { + return nil, err + } + networks := []string{network.Name} + return &CLClusterTestEnv{ + Network: network, + Geth: NewGeth(env.EnvComponentOpts{ + Networks: networks, + }), + MockServer: NewMockServer(env.EnvComponentOpts{ + Networks: networks, + }), + }, nil +} + +func NewTestEnvFromCfg(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { + network, err := docker.CreateNetwork() + if err != nil { + return nil, err + } + networks := []string{network.Name} + log.Info().Interface("Cfg", cfg).Send() + return &CLClusterTestEnv{ + cfg: cfg, + Network: network, + Geth: NewGeth(env.EnvComponentOpts{ + ReuseContainerName: cfg.Geth.ContainerName, + Networks: networks, + }), + MockServer: NewMockServer(env.EnvComponentOpts{ + ReuseContainerName: cfg.MockServer.ContainerName, + Networks: networks, + }), + }, nil +} + +func (m *CLClusterTestEnv) StartGeth() error { + return m.Geth.StartContainer(m.LogWatch) +} + +func (m *CLClusterTestEnv) StartMockServer() error { + return m.MockServer.StartContainer(m.LogWatch) +} + +// StartClNodes start one bootstrap node and {count} OCR nodes +func (m *CLClusterTestEnv) StartClNodes(nodeConfigOpts node.NodeConfigOpts, count int) error { + var wg sync.WaitGroup + var errs = []error{} + var mu sync.Mutex + + // Start nodes + for i := 0; i < count; i++ { + i := i + wg.Add(1) + go func() { + defer wg.Done() + dbContainerName := fmt.Sprintf("cl-db-%s", uuid.NewString()) + opts := env.EnvComponentOpts{ + Networks: []string{m.Network.Name}, + } + if m.cfg != nil { + opts.ReuseContainerName = m.cfg.Nodes[i].NodeContainerName + dbContainerName = m.cfg.Nodes[i].DbContainerName + } + n := NewClNode(opts, nodeConfigOpts, dbContainerName) + err := n.StartContainer(m.LogWatch) + if err != nil { + mu.Lock() + errs = append(errs, err) + mu.Unlock() + } else { + mu.Lock() + m.CLNodes = append(m.CLNodes, n) + mu.Unlock() + } + }() + } + + wg.Wait() + + if len(errs) > 0 { + return multierr.Combine(errs...) + } + return nil +} + +func (m *CLClusterTestEnv) GetDefaultNodeConfigOpts() node.NodeConfigOpts { + return node.NodeConfigOpts{ + EVM: struct { + HttpUrl string + WsUrl string + }{ + HttpUrl: m.Geth.InternalHttpUrl, + WsUrl: m.Geth.InternalWsUrl, + }, + } +} + +// ChainlinkNodeAddresses will return all the on-chain wallet addresses for a set of Chainlink nodes +func (m *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { + addresses := make([]common.Address, 0) + for _, n := range m.CLNodes { + primaryAddress, err := n.ChainlinkNodeAddress() + if err != nil { + return nil, err + } + addresses = append(addresses, primaryAddress) + } + return addresses, nil +} + +// FundChainlinkNodes will fund all the provided Chainlink nodes with a set amount of native currency +func (m *CLClusterTestEnv) FundChainlinkNodes(amount *big.Float) error { + for _, cl := range m.CLNodes { + if err := cl.Fund(m.Geth, amount); err != nil { + return err + } + } + return m.Geth.EthClient.WaitForEvents() +} + +func (m *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { + var keys []string + for _, n := range m.CLNodes { + csaKeys, err := n.GetNodeCSAKeys() + if err != nil { + return nil, err + } + keys = append(keys, csaKeys.Data[0].ID) + } + return keys, nil +} + +func getOracleIdentities(chainlinkNodes []ClNode) ([]int, []confighelper.OracleIdentityExtra) { + S := make([]int, len(chainlinkNodes)) + oracleIdentities := make([]confighelper.OracleIdentityExtra, len(chainlinkNodes)) + sharedSecretEncryptionPublicKeys := make([]ocrtypes.ConfigEncryptionPublicKey, len(chainlinkNodes)) + var wg sync.WaitGroup + for i, cl := range chainlinkNodes { + wg.Add(1) + go func(i int, cl ClNode) error { + defer wg.Done() + + ocr2Keys, err := cl.API.MustReadOCR2Keys() + if err != nil { + return err + } + var ocr2Config client.OCR2KeyAttributes + for _, key := range ocr2Keys.Data { + if key.Attributes.ChainType == string(chaintype.EVM) { + ocr2Config = key.Attributes + break + } + } + + keys, err := cl.API.MustReadP2PKeys() + if err != nil { + return err + } + p2pKeyID := keys.Data[0].Attributes.PeerID + + offchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OffChainPublicKey, "ocr2off_evm_")) + if err != nil { + return err + } + + offchainPkBytesFixed := [ed25519.PublicKeySize]byte{} + copy(offchainPkBytesFixed[:], offchainPkBytes) + if err != nil { + return err + } + + configPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.ConfigPublicKey, "ocr2cfg_evm_")) + if err != nil { + return err + } + + configPkBytesFixed := [ed25519.PublicKeySize]byte{} + copy(configPkBytesFixed[:], configPkBytes) + if err != nil { + return err + } + + onchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OnChainPublicKey, "ocr2on_evm_")) + if err != nil { + return err + } + + csaKeys, _, err := cl.API.ReadCSAKeys() + if err != nil { + return err + } + + sharedSecretEncryptionPublicKeys[i] = configPkBytesFixed + oracleIdentities[i] = confighelper.OracleIdentityExtra{ + OracleIdentity: confighelper.OracleIdentity{ + OnchainPublicKey: onchainPkBytes, + OffchainPublicKey: offchainPkBytesFixed, + PeerID: p2pKeyID, + TransmitAccount: ocrtypes.Account(csaKeys.Data[0].ID), + }, + ConfigEncryptionPublicKey: configPkBytesFixed, + } + S[i] = 1 + + return nil + }(i, cl) + } + wg.Wait() + + return S, oracleIdentities +} + +func (m *CLClusterTestEnv) Terminate() error { + // TESTCONTAINERS_RYUK_DISABLED=false by defualt so ryuk will remove all + // the containers and the network + return nil +} diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go new file mode 100644 index 00000000000..266a27388ff --- /dev/null +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -0,0 +1,198 @@ +package test_env + +import ( + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/types/node" + "os" +) + +type CLTestEnvBuilder struct { + hasLogWatch bool + hasGeth bool + hasMockServer bool + clNodesCount int + externalAdapterCount int + customNodeCsaKeys []string + defaultNodeCsaKeys []string +} + +func NewCLTestEnvBuilder() *CLTestEnvBuilder { + return &CLTestEnvBuilder{ + externalAdapterCount: 1, + } +} + +func (m *CLTestEnvBuilder) WithLogWatcher() *CLTestEnvBuilder { + m.hasLogWatch = true + return m +} + +func (m *CLTestEnvBuilder) WithCLNodes(clNodesCount int) *CLTestEnvBuilder { + m.clNodesCount = clNodesCount + return m +} + +func (m *CLTestEnvBuilder) WithGeth() *CLTestEnvBuilder { + m.hasGeth = true + return m +} + +func (m *CLTestEnvBuilder) WithMockServer(externalAdapterCount int) *CLTestEnvBuilder { + m.hasMockServer = true + m.externalAdapterCount = externalAdapterCount + return m +} + +func (m *CLTestEnvBuilder) Build() (*CLClusterTestEnv, error) { + envConfigPath, isSet := os.LookupEnv("TEST_ENV_CONFIG_PATH") + if isSet { + cfg, err := NewTestEnvConfigFromFile(envConfigPath) + if err != nil { + return nil, err + } + _ = os.Setenv("TESTCONTAINERS_RYUK_DISABLED", "true") + return m.connectExistingEnv(cfg) + } else { + return m.buildNewEnv() + } +} + +func (m *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { + log.Info(). + Bool("hasGeth", m.hasGeth). + Bool("hasMockServer", m.hasMockServer). + Int("externalAdapterCount", m.externalAdapterCount). + Int("clNodesCount", m.clNodesCount). + Strs("customNodeCsaKeys", m.customNodeCsaKeys). + Strs("defaultNodeCsaKeys", m.defaultNodeCsaKeys). + Msg("Building CL cluster test environment..") + te, err := NewTestEnvFromCfg(cfg) + if err != nil { + return te, err + } + + if m.hasLogWatch { + lw, err := logwatch.NewLogWatch(nil, nil) + if err != nil { + return te, err + } + te.LogWatch = lw + } + + if m.hasMockServer { + err := te.StartMockServer() + if err != nil { + return te, err + } + err = te.MockServer.SetExternalAdapterMocks(m.externalAdapterCount) + if err != nil { + return te, err + } + } + + if m.hasGeth { + err := te.StartGeth() + if err != nil { + return te, err + } + } + + var nodeCsaKeys []string + + // Start Chainlink Nodes + if m.clNodesCount > 0 { + // Create nodes + nodeConfOpts := node.NodeConfigOpts{ + EVM: struct { + HttpUrl string + WsUrl string + }{ + HttpUrl: te.Geth.InternalHttpUrl, + WsUrl: te.Geth.InternalWsUrl, + }, + } + err = te.StartClNodes(nodeConfOpts, m.clNodesCount) + if err != nil { + return te, err + } + + nodeCsaKeys, err = te.GetNodeCSAKeys() + if err != nil { + return te, err + } + m.defaultNodeCsaKeys = nodeCsaKeys + } + + return te, nil +} + +func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { + log.Info(). + Bool("hasGeth", m.hasGeth). + Bool("hasMockServer", m.hasMockServer). + Int("externalAdapterCount", m.externalAdapterCount). + Int("clNodesCount", m.clNodesCount). + Strs("customNodeCsaKeys", m.customNodeCsaKeys). + Strs("defaultNodeCsaKeys", m.defaultNodeCsaKeys). + Msg("Building CL cluster test environment..") + + te, err := NewTestEnv() + if err != nil { + return te, err + } + + if m.hasLogWatch { + lw, err := logwatch.NewLogWatch(nil, nil) + if err != nil { + return te, err + } + te.LogWatch = lw + } + + if m.hasMockServer { + err := te.StartMockServer() + if err != nil { + return te, err + } + err = te.MockServer.SetExternalAdapterMocks(m.externalAdapterCount) + if err != nil { + return te, err + } + } + + if m.hasGeth { + err := te.StartGeth() + if err != nil { + return te, err + } + } + + var nodeCsaKeys []string + + // Start Chainlink Nodes + if m.clNodesCount > 0 { + // Create nodes + nodeConfOpts := node.NodeConfigOpts{ + EVM: struct { + HttpUrl string + WsUrl string + }{ + HttpUrl: te.Geth.InternalHttpUrl, + WsUrl: te.Geth.InternalWsUrl, + }, + } + err = te.StartClNodes(nodeConfOpts, m.clNodesCount) + if err != nil { + return te, err + } + + nodeCsaKeys, err = te.GetNodeCSAKeys() + if err != nil { + return te, err + } + m.defaultNodeCsaKeys = nodeCsaKeys + } + + return te, nil +} diff --git a/integration-tests/docker/test_env/test_env_config.go b/integration-tests/docker/test_env/test_env_config.go new file mode 100644 index 00000000000..da38575a86a --- /dev/null +++ b/integration-tests/docker/test_env/test_env_config.go @@ -0,0 +1,42 @@ +package test_env + +import ( + "encoding/json" + + env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" +) + +type TestEnvConfig struct { + Networks []string `json:"networks"` + Geth GethConfig `json:"geth"` + MockServer MockServerConfig `json:"mockserver"` + Nodes []ClNodeConfig `json:"nodes"` +} + +type MockServerConfig struct { + ContainerName string `json:"container_name"` + EAMockUrls []string `json:"external_adapters_mock_urls"` +} + +type GethConfig struct { + ContainerName string `json:"container_name"` +} + +type ClNodeConfig struct { + NodeContainerName string `json:"container_name"` + DbContainerName string `json:"db_container_name"` +} + +func NewTestEnvConfigFromFile(path string) (*TestEnvConfig, error) { + c := &TestEnvConfig{} + err := env.ParseJSONFile(path, c) + if err != nil { + return nil, err + } + return c, nil +} + +func (c *TestEnvConfig) Json() string { + b, _ := json.Marshal(c) + return string(b) +} diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 5ac50f3dc8d..13a1d444240 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -18,14 +18,17 @@ require ( github.com/rs/zerolog v1.29.1 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-env v0.35.2 - github.com/smartcontractkit/chainlink-testing-framework v1.14.0 + github.com/smartcontractkit/chainlink-testing-framework v1.14.1-0.20230731095810-a70b0af9a909 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac github.com/smartcontractkit/ocr2keepers v0.7.2 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c + github.com/spf13/cobra v1.6.1 github.com/stretchr/testify v1.8.4 + github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a github.com/umbracle/ethgo v0.1.3 go.dedis.ch/kyber/v3 v3.1.0 + go.uber.org/multierr v1.11.0 go.uber.org/zap v1.24.0 golang.org/x/sync v0.3.0 gopkg.in/guregu/null.v4 v4.0.0 @@ -41,11 +44,17 @@ require ( github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 // indirect github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d // indirect github.com/DataDog/zstd v1.5.2 // indirect + github.com/K-Phoen/grabana v0.21.17 // indirect + github.com/K-Phoen/sdk v0.12.2 // indirect github.com/MakeNowJust/heredoc v1.0.0 // indirect github.com/Masterminds/semver/v3 v3.2.1 // indirect - github.com/OneOfOne/xxhash v1.2.6 // indirect + github.com/Microsoft/go-winio v0.6.1 // indirect github.com/VictoriaMetrics/fastcache v1.10.0 // indirect github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 // indirect + github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129 // indirect + github.com/armon/go-metrics v0.4.1 // indirect + github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 // indirect + github.com/aws/aws-sdk-go v1.44.276 // indirect github.com/aws/constructs-go/constructs/v10 v10.1.255 // indirect github.com/aws/jsii-runtime-go v1.75.0 // indirect github.com/aybabtme/rgbterm v0.0.0-20170906152045-cc83f3b3ce59 // indirect @@ -56,7 +65,9 @@ require ( github.com/btcsuite/btcd v0.23.4 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect github.com/bytedance/sonic v1.9.1 // indirect + github.com/c2h5oh/datasize v0.0.0-20200112174442-28bbd4740fee // indirect github.com/cdk8s-team/cdk8s-core-go/cdk8s/v2 v2.7.5 // indirect + github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cespare/xxhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect github.com/chai2010/gettext-go v1.0.2 // indirect @@ -71,30 +82,40 @@ require ( github.com/cometbft/cometbft v0.37.2 // indirect github.com/cometbft/cometbft-db v0.7.0 // indirect github.com/confio/ics23/go v0.9.0 // indirect + github.com/containerd/containerd v1.6.19 // indirect + github.com/coreos/go-semver v0.3.0 // indirect + github.com/coreos/go-systemd/v22 v22.5.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect github.com/cosmos/cosmos-proto v1.0.0-beta.2 // indirect github.com/cosmos/cosmos-sdk v0.47.4 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogoproto v1.4.10 // indirect github.com/cosmos/ledger-cosmos-go v0.12.1 // indirect + github.com/cpuguy83/dockercfg v0.3.1 // indirect github.com/danieljoos/wincred v1.1.2 // indirect - github.com/davecgh/go-spew v1.1.1 // indirect + github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c // indirect github.com/deckarep/golang-set/v2 v2.3.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect + github.com/dennwc/varint v1.0.0 // indirect github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70 // indirect github.com/dgraph-io/badger/v2 v2.2007.4 // indirect github.com/dgraph-io/ristretto v0.1.1 // indirect github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect + github.com/docker/distribution v2.8.2+incompatible // indirect + github.com/docker/docker v24.0.2+incompatible // indirect + github.com/docker/go-connections v0.4.0 // indirect github.com/docker/go-units v0.5.0 // indirect github.com/dustin/go-humanize v1.0.1 // indirect github.com/dvsekhvalnov/jose2go v1.5.0 // indirect - github.com/emicklei/go-restful/v3 v3.9.0 // indirect + github.com/edsrzf/mmap-go v1.1.0 // indirect + github.com/emicklei/go-restful/v3 v3.10.1 // indirect github.com/evanphx/json-patch v5.6.0+incompatible // indirect github.com/evanphx/json-patch/v5 v5.6.0 // indirect github.com/exponent-io/jsonpath v0.0.0-20210407135951-1de76d718b3f // indirect github.com/fatih/camelcase v1.0.0 // indirect github.com/fatih/color v1.15.0 // indirect + github.com/felixge/httpsnoop v1.0.3 // indirect github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6 // indirect github.com/fsnotify/fsnotify v1.6.0 // indirect github.com/fvbommel/sortorder v1.0.2 // indirect @@ -115,9 +136,15 @@ require ( github.com/go-logr/logr v1.2.4 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-ole/go-ole v1.2.6 // indirect + github.com/go-openapi/analysis v0.21.4 // indirect + github.com/go-openapi/errors v0.20.3 // indirect github.com/go-openapi/jsonpointer v0.19.6 // indirect github.com/go-openapi/jsonreference v0.20.2 // indirect + github.com/go-openapi/loads v0.21.2 // indirect + github.com/go-openapi/spec v0.20.8 // indirect + github.com/go-openapi/strfmt v0.21.7 // indirect github.com/go-openapi/swag v0.22.3 // indirect + github.com/go-openapi/validate v0.22.1 // indirect github.com/go-playground/locales v0.14.1 // indirect github.com/go-playground/universal-translator v0.18.1 // indirect github.com/go-playground/validator/v10 v10.14.0 // indirect @@ -125,7 +152,9 @@ require ( github.com/goccy/go-json v0.10.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gofrs/flock v0.8.1 // indirect + github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.3 // indirect + github.com/gogo/status v1.1.1 // indirect github.com/golang/glog v1.1.0 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect @@ -139,22 +168,38 @@ require ( github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 // indirect github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 // indirect github.com/gorilla/context v1.1.1 // indirect + github.com/gorilla/mux v1.8.0 // indirect github.com/gorilla/securecookie v1.1.1 // indirect github.com/gorilla/sessions v1.2.1 // indirect github.com/gorilla/websocket v1.5.0 // indirect + github.com/gosimple/slug v1.13.1 // indirect + github.com/gosimple/unidecode v1.0.1 // indirect + github.com/grafana/dskit v0.0.0-20230201083518-528d8a7d52f2 // indirect + github.com/grafana/loki v1.6.2-0.20230403212622-90888a0cc737 // indirect + github.com/grafana/loki/pkg/push v0.0.0-20230127102416-571f88bc5765 // indirect + github.com/grafana/regexp v0.0.0-20221122212121-6b5c0a4cb7fd // indirect github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79 // indirect + github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 // indirect github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.0-rc.0 // indirect github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.0.0-rc.3 // indirect github.com/grpc-ecosystem/grpc-gateway v1.16.0 // indirect github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c // indirect github.com/gtank/merlin v0.1.1 // indirect github.com/gtank/ristretto255 v0.1.2 // indirect + github.com/hashicorp/consul/api v1.21.0 // indirect github.com/hashicorp/errwrap v1.1.0 // indirect - github.com/hashicorp/go-hclog v1.4.0 // indirect + github.com/hashicorp/go-cleanhttp v0.5.2 // indirect + github.com/hashicorp/go-hclog v1.5.0 // indirect + github.com/hashicorp/go-immutable-radix v1.3.1 // indirect + github.com/hashicorp/go-msgpack v0.5.5 // indirect github.com/hashicorp/go-multierror v1.1.1 // indirect github.com/hashicorp/go-plugin v1.4.10 // indirect + github.com/hashicorp/go-rootcerts v1.0.2 // indirect + github.com/hashicorp/go-sockaddr v1.0.2 // indirect github.com/hashicorp/golang-lru v0.6.0 // indirect github.com/hashicorp/hcl v1.0.0 // indirect + github.com/hashicorp/memberlist v0.5.0 // indirect + github.com/hashicorp/serf v0.10.1 // indirect github.com/hashicorp/yamux v0.0.0-20200609203250-aecfd211c9ce // indirect github.com/hdevalence/ed25519consensus v0.1.0 // indirect github.com/holiman/bloomfilter/v2 v2.0.3 // indirect @@ -179,11 +224,13 @@ require ( github.com/jackpal/go-nat-pmp v1.0.2 // indirect github.com/jbenet/go-temp-err-catcher v0.1.0 // indirect github.com/jbenet/goprocess v0.1.4 // indirect + github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/jmhodges/levigo v1.0.0 // indirect github.com/jmoiron/sqlx v1.3.5 // indirect github.com/josharian/intern v1.0.0 // indirect github.com/jpillora/backoff v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect + github.com/julienschmidt/httprouter v1.3.0 // indirect github.com/klauspost/compress v1.16.3 // indirect github.com/klauspost/cpuid/v2 v2.2.4 // indirect github.com/koron/go-ssdp v0.0.2 // indirect @@ -237,17 +284,22 @@ require ( github.com/mattn/go-isatty v0.0.19 // indirect github.com/mattn/go-runewidth v0.0.14 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect + github.com/miekg/dns v1.1.54 // indirect github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 // indirect github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 // indirect - github.com/minio/sha256-simd v0.1.1 // indirect + github.com/minio/sha256-simd v1.0.0 // indirect + github.com/mitchellh/go-homedir v1.1.0 // indirect github.com/mitchellh/go-testing-interface v1.14.1 // indirect github.com/mitchellh/go-wordwrap v1.0.1 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect + github.com/moby/patternmatcher v0.5.0 // indirect github.com/moby/spdystream v0.2.0 // indirect - github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae // indirect + github.com/moby/sys/sequential v0.5.0 // indirect + github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect + github.com/morikuni/aec v1.0.0 // indirect github.com/mostynb/zstdpool-freelist v0.0.0-20201229113212-927304c0c3b1 // indirect github.com/mr-tron/base58 v1.2.0 // indirect github.com/mtibben/percent v0.2.1 // indirect @@ -262,8 +314,15 @@ require ( github.com/multiformats/go-multistream v0.2.2 // indirect github.com/multiformats/go-varint v0.0.6 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect + github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect github.com/oklog/run v1.1.0 // indirect + github.com/oklog/ulid v1.3.1 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect + github.com/opencontainers/go-digest v1.0.0 // indirect + github.com/opencontainers/image-spec v1.1.0-rc3 // indirect + github.com/opencontainers/runc v1.1.7 // indirect + github.com/opentracing-contrib/go-grpc v0.0.0-20210225150812-73cb765af46e // indirect + github.com/opentracing-contrib/go-stdlib v1.0.0 // indirect github.com/opentracing/opentracing-go v1.2.0 // indirect github.com/pelletier/go-toml v1.9.5 // indirect github.com/pelletier/go-toml/v2 v2.0.8 // indirect @@ -271,10 +330,14 @@ require ( github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c // indirect + github.com/prometheus/alertmanager v0.25.0 // indirect github.com/prometheus/client_golang v1.16.0 // indirect github.com/prometheus/client_model v0.4.0 // indirect github.com/prometheus/common v0.44.0 // indirect + github.com/prometheus/common/sigv4 v0.1.0 // indirect + github.com/prometheus/exporter-toolkit v0.10.0 // indirect github.com/prometheus/procfs v0.11.0 // indirect + github.com/prometheus/prometheus v0.45.0 // indirect github.com/pyroscope-io/client v0.7.1 // indirect github.com/pyroscope-io/godeltaprof v0.1.0 // indirect github.com/rivo/uniseg v0.4.4 // indirect @@ -283,6 +346,8 @@ require ( github.com/russross/blackfriday v1.6.0 // indirect github.com/sasha-s/go-deadlock v0.3.1 // indirect github.com/scylladb/go-reflectx v1.0.1 // indirect + github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 // indirect + github.com/sercand/kuberesolver v2.4.0+incompatible // indirect github.com/shirou/gopsutil v3.21.11+incompatible // indirect github.com/shirou/gopsutil/v3 v3.22.12 // indirect github.com/shopspring/decimal v1.3.1 // indirect @@ -290,16 +355,17 @@ require ( github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect + github.com/smartcontractkit/wasp v0.2.7 // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect github.com/spaolacci/murmur3 v1.1.0 // indirect github.com/spf13/afero v1.9.3 // indirect github.com/spf13/cast v1.5.1 // indirect - github.com/spf13/cobra v1.6.1 // indirect github.com/spf13/jwalterweatherman v1.1.0 // indirect github.com/spf13/pflag v1.0.5 // indirect github.com/spf13/viper v1.15.0 // indirect github.com/status-im/keycard-go v0.2.0 // indirect + github.com/stretchr/objx v0.5.0 // indirect github.com/subosito/gotenv v1.4.2 // indirect github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d // indirect github.com/tecbot/gorocksdb v0.0.0-20191217155057-f0fad39f321c // indirect @@ -313,9 +379,13 @@ require ( github.com/tklauser/numcpus v0.6.1 // indirect github.com/twitchyliquid64/golang-asm v0.15.1 // indirect github.com/tyler-smith/go-bip39 v1.1.0 // indirect + github.com/uber/jaeger-client-go v2.30.0+incompatible // indirect + github.com/uber/jaeger-lib v2.4.1+incompatible // indirect github.com/ugorji/go/codec v1.2.11 // indirect github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722 // indirect github.com/valyala/fastjson v1.4.1 // indirect + github.com/weaveworks/common v0.0.0-20221201103051-7c2720a9024d // indirect + github.com/weaveworks/promrus v1.2.0 // indirect github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1 // indirect github.com/whyrusleeping/multiaddr-filter v0.0.0-20160516205228-e903e4adabd7 // indirect github.com/x448/float16 v0.8.4 // indirect @@ -326,18 +396,24 @@ require ( github.com/zondax/ledger-go v0.14.1 // indirect go.dedis.ch/fixbuf v1.0.3 // indirect go.etcd.io/bbolt v1.3.7 // indirect + go.etcd.io/etcd/api/v3 v3.5.7 // indirect + go.etcd.io/etcd/client/pkg/v3 v3.5.7 // indirect + go.etcd.io/etcd/client/v3 v3.5.7 // indirect + go.mongodb.org/mongo-driver v1.11.3 // indirect go.opencensus.io v0.24.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.42.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.42.0 // indirect go.opentelemetry.io/otel v1.16.0 // indirect go.opentelemetry.io/otel/metric v1.16.0 // indirect go.opentelemetry.io/otel/sdk v1.16.0 // indirect go.opentelemetry.io/otel/trace v1.16.0 // indirect go.starlark.net v0.0.0-20220817180228-f738f5508c12 // indirect go.uber.org/atomic v1.11.0 // indirect - go.uber.org/multierr v1.11.0 // indirect + go.uber.org/goleak v1.2.1 // indirect + go.uber.org/ratelimit v0.2.0 // indirect golang.org/x/arch v0.4.0 // indirect golang.org/x/crypto v0.11.0 // indirect - golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb // indirect + golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1 // indirect golang.org/x/lint v0.0.0-20210508222113-6edffad5e616 // indirect golang.org/x/mod v0.12.0 // indirect golang.org/x/net v0.12.0 // indirect @@ -361,19 +437,20 @@ require ( gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect - k8s.io/api v0.25.11 // indirect + k8s.io/api v0.26.2 // indirect k8s.io/apiextensions-apiserver v0.25.3 // indirect - k8s.io/apimachinery v0.25.11 // indirect + k8s.io/apimachinery v0.26.2 // indirect k8s.io/cli-runtime v0.25.11 // indirect - k8s.io/client-go v0.25.11 // indirect + k8s.io/client-go v0.26.2 // indirect k8s.io/component-base v0.25.11 // indirect - k8s.io/klog/v2 v2.80.1 // indirect - k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 // indirect + k8s.io/klog/v2 v2.100.1 // indirect + k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect k8s.io/kubectl v0.25.11 // indirect - k8s.io/utils v0.0.0-20221107191617-1a15be271d1d // indirect + k8s.io/utils v0.0.0-20230308161112-d77c459e9343 // indirect + nhooyr.io/websocket v1.8.7 // indirect pgregory.net/rapid v0.5.5 // indirect sigs.k8s.io/controller-runtime v0.13.0 // indirect - sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 // indirect + sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd // indirect sigs.k8s.io/kustomize/api v0.12.1 // indirect sigs.k8s.io/kustomize/kyaml v0.13.9 // indirect sigs.k8s.io/structured-merge-diff/v4 v4.2.3 // indirect @@ -385,9 +462,18 @@ replace ( // See https://github.com/ugorji/go/issues/279 github.com/btcsuite/btcd => github.com/btcsuite/btcd v0.22.1 + github.com/go-kit/log => github.com/go-kit/log v0.2.1 + // replicating the replace directive on cosmos SDK github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + + github.com/prometheus/prometheus => github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2 + github.com/sercand/kuberesolver v2.4.0+incompatible => github.com/sercand/kuberesolver/v5 v5.1.0 + + k8s.io/api => k8s.io/api v0.25.4 + k8s.io/client-go => k8s.io/client-go v0.25.4 + k8s.io/kube-openapi => k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d ) diff --git a/integration-tests/go.sum b/integration-tests/go.sum index c6293a5e61f..fa3cc50d325 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -18,28 +18,501 @@ cloud.google.com/go v0.65.0/go.mod h1:O5N8zS7uWy9vkA9vayVHs65eM1ubvY4h553ofrNHOb cloud.google.com/go v0.72.0/go.mod h1:M+5Vjvlc2wnp6tjzE102Dw08nGShTscUx2nZMufOKPI= cloud.google.com/go v0.74.0/go.mod h1:VV1xSbzvo+9QJOxLDaJfTjx5e+MePCpCWwvftOeQmWk= cloud.google.com/go v0.75.0/go.mod h1:VGuuCn7PG0dwsd5XPVm2Mm3wlh3EL55/79EKB6hlPTY= +cloud.google.com/go v0.78.0/go.mod h1:QjdrLG0uq+YwhjoVOLsS1t7TW8fs36kLs4XO5R5ECHg= +cloud.google.com/go v0.79.0/go.mod h1:3bzgcEeQlzbuEAYu4mrWhKqWjmpprinYgKJLgKHnbb8= +cloud.google.com/go v0.81.0/go.mod h1:mk/AM35KwGk/Nm2YSeZbxXdrNK3KZOYHmLkOqC2V6E0= +cloud.google.com/go v0.83.0/go.mod h1:Z7MJUsANfY0pYPdw0lbnivPx4/vhy/e2FEkSkF7vAVY= +cloud.google.com/go v0.84.0/go.mod h1:RazrYuxIK6Kb7YrzzhPoLmCVzl7Sup4NrbKPg8KHSUM= +cloud.google.com/go v0.87.0/go.mod h1:TpDYlFy7vuLzZMMZ+B6iRiELaY7z/gJPaqbMx6mlWcY= +cloud.google.com/go v0.90.0/go.mod h1:kRX0mNRHe0e2rC6oNakvwQqzyDmg57xJ+SZU1eT2aDQ= +cloud.google.com/go v0.93.3/go.mod h1:8utlLll2EF5XMAV15woO4lSbWQlk8rer9aLOfLh7+YI= +cloud.google.com/go v0.94.1/go.mod h1:qAlAugsXlC+JWO+Bke5vCtc9ONxjQT3drlTTnAplMW4= +cloud.google.com/go v0.97.0/go.mod h1:GF7l59pYBVlXQIBLx3a761cZ41F9bBH3JUlihCt2Udc= +cloud.google.com/go v0.99.0/go.mod h1:w0Xx2nLzqWJPuozYQX+hFfCSI8WioryfRDzkoI/Y2ZA= +cloud.google.com/go v0.100.1/go.mod h1:fs4QogzfH5n2pBXBP9vRiU+eCny7lD2vmFZy79Iuw1U= +cloud.google.com/go v0.100.2/go.mod h1:4Xra9TjzAeYHrl5+oeLlzbM2k3mjVhZh4UqTZ//w99A= +cloud.google.com/go v0.102.0/go.mod h1:oWcCzKlqJ5zgHQt9YsaeTY9KzIvjyy0ArmiBUgpQ+nc= +cloud.google.com/go v0.102.1/go.mod h1:XZ77E9qnTEnrgEOvr4xzfdX5TRo7fB4T2F4O6+34hIU= +cloud.google.com/go v0.104.0/go.mod h1:OO6xxXdJyvuJPcEPBLN9BJPD+jep5G1+2U5B5gkRYtA= +cloud.google.com/go v0.105.0/go.mod h1:PrLgOJNe5nfE9UMxKxgXj4mD3voiP+YQ6gdt6KMFOKM= +cloud.google.com/go v0.107.0/go.mod h1:wpc2eNrD7hXUTy8EKS10jkxpZBjASrORK7goS+3YX2I= +cloud.google.com/go v0.110.0/go.mod h1:SJnCLqQ0FCFGSZMUNUf84MV3Aia54kn7pi8st7tMzaY= cloud.google.com/go v0.110.4 h1:1JYyxKMN9hd5dR2MYTPWkGUgcoxVVhg0LKNKEo0qvmk= +cloud.google.com/go/accessapproval v1.4.0/go.mod h1:zybIuC3KpDOvotz59lFe5qxRZx6C75OtwbisN56xYB4= +cloud.google.com/go/accessapproval v1.5.0/go.mod h1:HFy3tuiGvMdcd/u+Cu5b9NkO1pEICJ46IR82PoUdplw= +cloud.google.com/go/accessapproval v1.6.0/go.mod h1:R0EiYnwV5fsRFiKZkPHr6mwyk2wxUJ30nL4j2pcFY2E= +cloud.google.com/go/accesscontextmanager v1.3.0/go.mod h1:TgCBehyr5gNMz7ZaH9xubp+CE8dkrszb4oK9CWyvD4o= +cloud.google.com/go/accesscontextmanager v1.4.0/go.mod h1:/Kjh7BBu/Gh83sv+K60vN9QE5NJcd80sU33vIe2IFPE= +cloud.google.com/go/accesscontextmanager v1.6.0/go.mod h1:8XCvZWfYw3K/ji0iVnp+6pu7huxoQTLmxAbVjbloTtM= +cloud.google.com/go/aiplatform v1.22.0/go.mod h1:ig5Nct50bZlzV6NvKaTwmplLLddFx0YReh9WfTO5jKw= +cloud.google.com/go/aiplatform v1.24.0/go.mod h1:67UUvRBKG6GTayHKV8DBv2RtR1t93YRu5B1P3x99mYY= +cloud.google.com/go/aiplatform v1.27.0/go.mod h1:Bvxqtl40l0WImSb04d0hXFU7gDOiq9jQmorivIiWcKg= +cloud.google.com/go/aiplatform v1.35.0/go.mod h1:7MFT/vCaOyZT/4IIFfxH4ErVg/4ku6lKv3w0+tFTgXQ= +cloud.google.com/go/analytics v0.11.0/go.mod h1:DjEWCu41bVbYcKyvlws9Er60YE4a//bK6mnhWvQeFNI= +cloud.google.com/go/analytics v0.12.0/go.mod h1:gkfj9h6XRf9+TS4bmuhPEShsh3hH8PAZzm/41OOhQd4= +cloud.google.com/go/analytics v0.18.0/go.mod h1:ZkeHGQlcIPkw0R/GW+boWHhCOR43xz9RN/jn7WcqfIE= +cloud.google.com/go/apigateway v1.3.0/go.mod h1:89Z8Bhpmxu6AmUxuVRg/ECRGReEdiP3vQtk4Z1J9rJk= +cloud.google.com/go/apigateway v1.4.0/go.mod h1:pHVY9MKGaH9PQ3pJ4YLzoj6U5FUDeDFBllIz7WmzJoc= +cloud.google.com/go/apigateway v1.5.0/go.mod h1:GpnZR3Q4rR7LVu5951qfXPJCHquZt02jf7xQx7kpqN8= +cloud.google.com/go/apigeeconnect v1.3.0/go.mod h1:G/AwXFAKo0gIXkPTVfZDd2qA1TxBXJ3MgMRBQkIi9jc= +cloud.google.com/go/apigeeconnect v1.4.0/go.mod h1:kV4NwOKqjvt2JYR0AoIWo2QGfoRtn/pkS3QlHp0Ni04= +cloud.google.com/go/apigeeconnect v1.5.0/go.mod h1:KFaCqvBRU6idyhSNyn3vlHXc8VMDJdRmwDF6JyFRqZ8= +cloud.google.com/go/apigeeregistry v0.4.0/go.mod h1:EUG4PGcsZvxOXAdyEghIdXwAEi/4MEaoqLMLDMIwKXY= +cloud.google.com/go/apigeeregistry v0.5.0/go.mod h1:YR5+s0BVNZfVOUkMa5pAR2xGd0A473vA5M7j247o1wM= +cloud.google.com/go/apikeys v0.4.0/go.mod h1:XATS/yqZbaBK0HOssf+ALHp8jAlNHUgyfprvNcBIszU= +cloud.google.com/go/apikeys v0.5.0/go.mod h1:5aQfwY4D+ewMMWScd3hm2en3hCj+BROlyrt3ytS7KLI= +cloud.google.com/go/appengine v1.4.0/go.mod h1:CS2NhuBuDXM9f+qscZ6V86m1MIIqPj3WC/UoEuR1Sno= +cloud.google.com/go/appengine v1.5.0/go.mod h1:TfasSozdkFI0zeoxW3PTBLiNqRmzraodCWatWI9Dmak= +cloud.google.com/go/appengine v1.6.0/go.mod h1:hg6i0J/BD2cKmDJbaFSYHFyZkgBEfQrDg/X0V5fJn84= +cloud.google.com/go/area120 v0.5.0/go.mod h1:DE/n4mp+iqVyvxHN41Vf1CR602GiHQjFPusMFW6bGR4= +cloud.google.com/go/area120 v0.6.0/go.mod h1:39yFJqWVgm0UZqWTOdqkLhjoC7uFfgXRC8g/ZegeAh0= +cloud.google.com/go/area120 v0.7.1/go.mod h1:j84i4E1RboTWjKtZVWXPqvK5VHQFJRF2c1Nm69pWm9k= +cloud.google.com/go/artifactregistry v1.6.0/go.mod h1:IYt0oBPSAGYj/kprzsBjZ/4LnG/zOcHyFHjWPCi6SAQ= +cloud.google.com/go/artifactregistry v1.7.0/go.mod h1:mqTOFOnGZx8EtSqK/ZWcsm/4U8B77rbcLP6ruDU2Ixk= +cloud.google.com/go/artifactregistry v1.8.0/go.mod h1:w3GQXkJX8hiKN0v+at4b0qotwijQbYUqF2GWkZzAhC0= +cloud.google.com/go/artifactregistry v1.9.0/go.mod h1:2K2RqvA2CYvAeARHRkLDhMDJ3OXy26h3XW+3/Jh2uYc= +cloud.google.com/go/artifactregistry v1.11.2/go.mod h1:nLZns771ZGAwVLzTX/7Al6R9ehma4WUEhZGWV6CeQNQ= +cloud.google.com/go/asset v1.5.0/go.mod h1:5mfs8UvcM5wHhqtSv8J1CtxxaQq3AdBxxQi2jGW/K4o= +cloud.google.com/go/asset v1.7.0/go.mod h1:YbENsRK4+xTiL+Ofoj5Ckf+O17kJtgp3Y3nn4uzZz5s= +cloud.google.com/go/asset v1.8.0/go.mod h1:mUNGKhiqIdbr8X7KNayoYvyc4HbbFO9URsjbytpUaW0= +cloud.google.com/go/asset v1.9.0/go.mod h1:83MOE6jEJBMqFKadM9NLRcs80Gdw76qGuHn8m3h8oHQ= +cloud.google.com/go/asset v1.10.0/go.mod h1:pLz7uokL80qKhzKr4xXGvBQXnzHn5evJAEAtZiIb0wY= +cloud.google.com/go/asset v1.11.1/go.mod h1:fSwLhbRvC9p9CXQHJ3BgFeQNM4c9x10lqlrdEUYXlJo= +cloud.google.com/go/assuredworkloads v1.5.0/go.mod h1:n8HOZ6pff6re5KYfBXcFvSViQjDwxFkAkmUFffJRbbY= +cloud.google.com/go/assuredworkloads v1.6.0/go.mod h1:yo2YOk37Yc89Rsd5QMVECvjaMKymF9OP+QXWlKXUkXw= +cloud.google.com/go/assuredworkloads v1.7.0/go.mod h1:z/736/oNmtGAyU47reJgGN+KVoYoxeLBoj4XkKYscNI= +cloud.google.com/go/assuredworkloads v1.8.0/go.mod h1:AsX2cqyNCOvEQC8RMPnoc0yEarXQk6WEKkxYfL6kGIo= +cloud.google.com/go/assuredworkloads v1.9.0/go.mod h1:kFuI1P78bplYtT77Tb1hi0FMxM0vVpRC7VVoJC3ZoT0= +cloud.google.com/go/assuredworkloads v1.10.0/go.mod h1:kwdUQuXcedVdsIaKgKTp9t0UJkE5+PAVNhdQm4ZVq2E= +cloud.google.com/go/automl v1.5.0/go.mod h1:34EjfoFGMZ5sgJ9EoLsRtdPSNZLcfflJR39VbVNS2M0= +cloud.google.com/go/automl v1.6.0/go.mod h1:ugf8a6Fx+zP0D59WLhqgTDsQI9w07o64uf/Is3Nh5p8= +cloud.google.com/go/automl v1.7.0/go.mod h1:RL9MYCCsJEOmt0Wf3z9uzG0a7adTT1fe+aObgSpkCt8= +cloud.google.com/go/automl v1.8.0/go.mod h1:xWx7G/aPEe/NP+qzYXktoBSDfjO+vnKMGgsApGJJquM= +cloud.google.com/go/automl v1.12.0/go.mod h1:tWDcHDp86aMIuHmyvjuKeeHEGq76lD7ZqfGLN6B0NuU= +cloud.google.com/go/baremetalsolution v0.3.0/go.mod h1:XOrocE+pvK1xFfleEnShBlNAXf+j5blPPxrhjKgnIFc= +cloud.google.com/go/baremetalsolution v0.4.0/go.mod h1:BymplhAadOO/eBa7KewQ0Ppg4A4Wplbn+PsFKRLo0uI= +cloud.google.com/go/baremetalsolution v0.5.0/go.mod h1:dXGxEkmR9BMwxhzBhV0AioD0ULBmuLZI8CdwalUxuss= +cloud.google.com/go/batch v0.3.0/go.mod h1:TR18ZoAekj1GuirsUsR1ZTKN3FC/4UDnScjT8NXImFE= +cloud.google.com/go/batch v0.4.0/go.mod h1:WZkHnP43R/QCGQsZ+0JyG4i79ranE2u8xvjq/9+STPE= +cloud.google.com/go/batch v0.7.0/go.mod h1:vLZN95s6teRUqRQ4s3RLDsH8PvboqBK+rn1oevL159g= +cloud.google.com/go/beyondcorp v0.2.0/go.mod h1:TB7Bd+EEtcw9PCPQhCJtJGjk/7TC6ckmnSFS+xwTfm4= +cloud.google.com/go/beyondcorp v0.3.0/go.mod h1:E5U5lcrcXMsCuoDNyGrpyTm/hn7ne941Jz2vmksAxW8= +cloud.google.com/go/beyondcorp v0.4.0/go.mod h1:3ApA0mbhHx6YImmuubf5pyW8srKnCEPON32/5hj+RmM= cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= +cloud.google.com/go/bigquery v1.42.0/go.mod h1:8dRTJxhtG+vwBKzE5OseQn/hiydoQN3EedCaOdYmxRA= +cloud.google.com/go/bigquery v1.43.0/go.mod h1:ZMQcXHsl+xmU1z36G2jNGZmKp9zNY5BUua5wDgmNCfw= +cloud.google.com/go/bigquery v1.44.0/go.mod h1:0Y33VqXTEsbamHJvJHdFmtqHvMIY28aK1+dFsvaChGc= +cloud.google.com/go/bigquery v1.48.0/go.mod h1:QAwSz+ipNgfL5jxiaK7weyOhzdoAy1zFm0Nf1fysJac= +cloud.google.com/go/billing v1.4.0/go.mod h1:g9IdKBEFlItS8bTtlrZdVLWSSdSyFUZKXNS02zKMOZY= +cloud.google.com/go/billing v1.5.0/go.mod h1:mztb1tBc3QekhjSgmpf/CV4LzWXLzCArwpLmP2Gm88s= +cloud.google.com/go/billing v1.6.0/go.mod h1:WoXzguj+BeHXPbKfNWkqVtDdzORazmCjraY+vrxcyvI= +cloud.google.com/go/billing v1.7.0/go.mod h1:q457N3Hbj9lYwwRbnlD7vUpyjq6u5U1RAOArInEiD5Y= +cloud.google.com/go/billing v1.12.0/go.mod h1:yKrZio/eu+okO/2McZEbch17O5CB5NpZhhXG6Z766ss= +cloud.google.com/go/binaryauthorization v1.1.0/go.mod h1:xwnoWu3Y84jbuHa0zd526MJYmtnVXn0syOjaJgy4+dM= +cloud.google.com/go/binaryauthorization v1.2.0/go.mod h1:86WKkJHtRcv5ViNABtYMhhNWRrD1Vpi//uKEy7aYEfI= +cloud.google.com/go/binaryauthorization v1.3.0/go.mod h1:lRZbKgjDIIQvzYQS1p99A7/U1JqvqeZg0wiI5tp6tg0= +cloud.google.com/go/binaryauthorization v1.4.0/go.mod h1:tsSPQrBd77VLplV70GUhBf/Zm3FsKmgSqgm4UmiDItk= +cloud.google.com/go/binaryauthorization v1.5.0/go.mod h1:OSe4OU1nN/VswXKRBmciKpo9LulY41gch5c68htf3/Q= +cloud.google.com/go/certificatemanager v1.3.0/go.mod h1:n6twGDvcUBFu9uBgt4eYvvf3sQ6My8jADcOVwHmzadg= +cloud.google.com/go/certificatemanager v1.4.0/go.mod h1:vowpercVFyqs8ABSmrdV+GiFf2H/ch3KyudYQEMM590= +cloud.google.com/go/certificatemanager v1.6.0/go.mod h1:3Hh64rCKjRAX8dXgRAyOcY5vQ/fE1sh8o+Mdd6KPgY8= +cloud.google.com/go/channel v1.8.0/go.mod h1:W5SwCXDJsq/rg3tn3oG0LOxpAo6IMxNa09ngphpSlnk= +cloud.google.com/go/channel v1.9.0/go.mod h1:jcu05W0my9Vx4mt3/rEHpfxc9eKi9XwsdDL8yBMbKUk= +cloud.google.com/go/channel v1.11.0/go.mod h1:IdtI0uWGqhEeatSB62VOoJ8FSUhJ9/+iGkJVqp74CGE= +cloud.google.com/go/cloudbuild v1.3.0/go.mod h1:WequR4ULxlqvMsjDEEEFnOG5ZSRSgWOywXYDb1vPE6U= +cloud.google.com/go/cloudbuild v1.4.0/go.mod h1:5Qwa40LHiOXmz3386FrjrYM93rM/hdRr7b53sySrTqA= +cloud.google.com/go/cloudbuild v1.7.0/go.mod h1:zb5tWh2XI6lR9zQmsm1VRA+7OCuve5d8S+zJUul8KTg= +cloud.google.com/go/clouddms v1.3.0/go.mod h1:oK6XsCDdW4Ib3jCCBugx+gVjevp2TMXFtgxvPSee3OM= +cloud.google.com/go/clouddms v1.4.0/go.mod h1:Eh7sUGCC+aKry14O1NRljhjyrr0NFC0G2cjwX0cByRk= +cloud.google.com/go/clouddms v1.5.0/go.mod h1:QSxQnhikCLUw13iAbffF2CZxAER3xDGNHjsTAkQJcQA= +cloud.google.com/go/cloudtasks v1.5.0/go.mod h1:fD92REy1x5woxkKEkLdvavGnPJGEn8Uic9nWuLzqCpY= +cloud.google.com/go/cloudtasks v1.6.0/go.mod h1:C6Io+sxuke9/KNRkbQpihnW93SWDU3uXt92nu85HkYI= +cloud.google.com/go/cloudtasks v1.7.0/go.mod h1:ImsfdYWwlWNJbdgPIIGJWC+gemEGTBK/SunNQQNCAb4= +cloud.google.com/go/cloudtasks v1.8.0/go.mod h1:gQXUIwCSOI4yPVK7DgTVFiiP0ZW/eQkydWzwVMdHxrI= +cloud.google.com/go/cloudtasks v1.9.0/go.mod h1:w+EyLsVkLWHcOaqNEyvcKAsWp9p29dL6uL9Nst1cI7Y= +cloud.google.com/go/compute v0.1.0/go.mod h1:GAesmwr110a34z04OlxYkATPBEfVhkymfTBXtfbBFow= +cloud.google.com/go/compute v1.3.0/go.mod h1:cCZiE1NHEtai4wiufUhW8I8S1JKkAnhnQJWM7YD99wM= +cloud.google.com/go/compute v1.5.0/go.mod h1:9SMHyhJlzhlkJqrPAc839t2BZFTSk6Jdj6mkzQJeu0M= +cloud.google.com/go/compute v1.6.0/go.mod h1:T29tfhtVbq1wvAPo0E3+7vhgmkOYeXjhFvz/FMzPu0s= +cloud.google.com/go/compute v1.6.1/go.mod h1:g85FgpzFvNULZ+S8AYq87axRKuf2Kh7deLqV/jJ3thU= +cloud.google.com/go/compute v1.7.0/go.mod h1:435lt8av5oL9P3fv1OEzSbSUe+ybHXGMPQHHZWZxy9U= +cloud.google.com/go/compute v1.10.0/go.mod h1:ER5CLbMxl90o2jtNbGSbtfOpQKR0t15FOtRsugnLrlU= +cloud.google.com/go/compute v1.12.0/go.mod h1:e8yNOBcBONZU1vJKCvCoDw/4JQsA0dpM4x/6PIIOocU= +cloud.google.com/go/compute v1.12.1/go.mod h1:e8yNOBcBONZU1vJKCvCoDw/4JQsA0dpM4x/6PIIOocU= +cloud.google.com/go/compute v1.13.0/go.mod h1:5aPTS0cUNMIc1CE546K+Th6weJUNQErARyZtRXDJ8GE= +cloud.google.com/go/compute v1.14.0/go.mod h1:YfLtxrj9sU4Yxv+sXzZkyPjEyPBZfXHUvjxega5vAdo= +cloud.google.com/go/compute v1.15.1/go.mod h1:bjjoF/NtFUrkD/urWfdHaKuOPDR5nWIs63rR+SXhcpA= +cloud.google.com/go/compute v1.18.0/go.mod h1:1X7yHxec2Ga+Ss6jPyjxRxpu2uu7PLgsOVXvgU0yacs= cloud.google.com/go/compute v1.20.1 h1:6aKEtlUiwEpJzM001l0yFkpXmUVXaN8W+fbkb2AZNbg= +cloud.google.com/go/compute/metadata v0.1.0/go.mod h1:Z1VN+bulIf6bt4P/C37K4DyZYZEXYonfTBHHFPO/4UU= +cloud.google.com/go/compute/metadata v0.2.0/go.mod h1:zFmK7XCadkQkj6TtorcaGlCW1hT1fIilQDwofLpJ20k= +cloud.google.com/go/compute/metadata v0.2.1/go.mod h1:jgHgmJd2RKBGzXqF5LR2EZMGxBkeanZ9wwa75XHJgOM= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= +cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= +cloud.google.com/go/contactcenterinsights v1.3.0/go.mod h1:Eu2oemoePuEFc/xKFPjbTuPSj0fYJcPls9TFlPNnHHY= +cloud.google.com/go/contactcenterinsights v1.4.0/go.mod h1:L2YzkGbPsv+vMQMCADxJoT9YiTTnSEd6fEvCeHTYVck= +cloud.google.com/go/contactcenterinsights v1.6.0/go.mod h1:IIDlT6CLcDoyv79kDv8iWxMSTZhLxSCofVV5W6YFM/w= +cloud.google.com/go/container v1.6.0/go.mod h1:Xazp7GjJSeUYo688S+6J5V+n/t+G5sKBTFkKNudGRxg= +cloud.google.com/go/container v1.7.0/go.mod h1:Dp5AHtmothHGX3DwwIHPgq45Y8KmNsgN3amoYfxVkLo= +cloud.google.com/go/container v1.13.1/go.mod h1:6wgbMPeQRw9rSnKBCAJXnds3Pzj03C4JHamr8asWKy4= +cloud.google.com/go/containeranalysis v0.5.1/go.mod h1:1D92jd8gRR/c0fGMlymRgxWD3Qw9C1ff6/T7mLgVL8I= +cloud.google.com/go/containeranalysis v0.6.0/go.mod h1:HEJoiEIu+lEXM+k7+qLCci0h33lX3ZqoYFdmPcoO7s4= +cloud.google.com/go/containeranalysis v0.7.0/go.mod h1:9aUL+/vZ55P2CXfuZjS4UjQ9AgXoSw8Ts6lemfmxBxI= +cloud.google.com/go/datacatalog v1.3.0/go.mod h1:g9svFY6tuR+j+hrTw3J2dNcmI0dzmSiyOzm8kpLq0a0= +cloud.google.com/go/datacatalog v1.5.0/go.mod h1:M7GPLNQeLfWqeIm3iuiruhPzkt65+Bx8dAKvScX8jvs= +cloud.google.com/go/datacatalog v1.6.0/go.mod h1:+aEyF8JKg+uXcIdAmmaMUmZ3q1b/lKLtXCmXdnc0lbc= +cloud.google.com/go/datacatalog v1.7.0/go.mod h1:9mEl4AuDYWw81UGc41HonIHH7/sn52H0/tc8f8ZbZIE= +cloud.google.com/go/datacatalog v1.8.0/go.mod h1:KYuoVOv9BM8EYz/4eMFxrr4DUKhGIOXxZoKYF5wdISM= +cloud.google.com/go/datacatalog v1.8.1/go.mod h1:RJ58z4rMp3gvETA465Vg+ag8BGgBdnRPEMMSTr5Uv+M= +cloud.google.com/go/datacatalog v1.12.0/go.mod h1:CWae8rFkfp6LzLumKOnmVh4+Zle4A3NXLzVJ1d1mRm0= +cloud.google.com/go/dataflow v0.6.0/go.mod h1:9QwV89cGoxjjSR9/r7eFDqqjtvbKxAK2BaYU6PVk9UM= +cloud.google.com/go/dataflow v0.7.0/go.mod h1:PX526vb4ijFMesO1o202EaUmouZKBpjHsTlCtB4parQ= +cloud.google.com/go/dataflow v0.8.0/go.mod h1:Rcf5YgTKPtQyYz8bLYhFoIV/vP39eL7fWNcSOyFfLJE= +cloud.google.com/go/dataform v0.3.0/go.mod h1:cj8uNliRlHpa6L3yVhDOBrUXH+BPAO1+KFMQQNSThKo= +cloud.google.com/go/dataform v0.4.0/go.mod h1:fwV6Y4Ty2yIFL89huYlEkwUPtS7YZinZbzzj5S9FzCE= +cloud.google.com/go/dataform v0.5.0/go.mod h1:GFUYRe8IBa2hcomWplodVmUx/iTL0FrsauObOM3Ipr0= +cloud.google.com/go/dataform v0.6.0/go.mod h1:QPflImQy33e29VuapFdf19oPbE4aYTJxr31OAPV+ulA= +cloud.google.com/go/datafusion v1.4.0/go.mod h1:1Zb6VN+W6ALo85cXnM1IKiPw+yQMKMhB9TsTSRDo/38= +cloud.google.com/go/datafusion v1.5.0/go.mod h1:Kz+l1FGHB0J+4XF2fud96WMmRiq/wj8N9u007vyXZ2w= +cloud.google.com/go/datafusion v1.6.0/go.mod h1:WBsMF8F1RhSXvVM8rCV3AeyWVxcC2xY6vith3iw3S+8= +cloud.google.com/go/datalabeling v0.5.0/go.mod h1:TGcJ0G2NzcsXSE/97yWjIZO0bXj0KbVlINXMG9ud42I= +cloud.google.com/go/datalabeling v0.6.0/go.mod h1:WqdISuk/+WIGeMkpw/1q7bK/tFEZxsrFJOJdY2bXvTQ= +cloud.google.com/go/datalabeling v0.7.0/go.mod h1:WPQb1y08RJbmpM3ww0CSUAGweL0SxByuW2E+FU+wXcM= +cloud.google.com/go/dataplex v1.3.0/go.mod h1:hQuRtDg+fCiFgC8j0zV222HvzFQdRd+SVX8gdmFcZzA= +cloud.google.com/go/dataplex v1.4.0/go.mod h1:X51GfLXEMVJ6UN47ESVqvlsRplbLhcsAt0kZCCKsU0A= +cloud.google.com/go/dataplex v1.5.2/go.mod h1:cVMgQHsmfRoI5KFYq4JtIBEUbYwc3c7tXmIDhRmNNVQ= +cloud.google.com/go/dataproc v1.7.0/go.mod h1:CKAlMjII9H90RXaMpSxQ8EU6dQx6iAYNPcYPOkSbi8s= +cloud.google.com/go/dataproc v1.8.0/go.mod h1:5OW+zNAH0pMpw14JVrPONsxMQYMBqJuzORhIBfBn9uI= +cloud.google.com/go/dataproc v1.12.0/go.mod h1:zrF3aX0uV3ikkMz6z4uBbIKyhRITnxvr4i3IjKsKrw4= +cloud.google.com/go/dataqna v0.5.0/go.mod h1:90Hyk596ft3zUQ8NkFfvICSIfHFh1Bc7C4cK3vbhkeo= +cloud.google.com/go/dataqna v0.6.0/go.mod h1:1lqNpM7rqNLVgWBJyk5NF6Uen2PHym0jtVJonplVsDA= +cloud.google.com/go/dataqna v0.7.0/go.mod h1:Lx9OcIIeqCrw1a6KdO3/5KMP1wAmTc0slZWwP12Qq3c= cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= +cloud.google.com/go/datastore v1.10.0/go.mod h1:PC5UzAmDEkAmkfaknstTYbNpgE49HAgW2J1gcgUfmdM= +cloud.google.com/go/datastream v1.2.0/go.mod h1:i/uTP8/fZwgATHS/XFu0TcNUhuA0twZxxQ3EyCUQMwo= +cloud.google.com/go/datastream v1.3.0/go.mod h1:cqlOX8xlyYF/uxhiKn6Hbv6WjwPPuI9W2M9SAXwaLLQ= +cloud.google.com/go/datastream v1.4.0/go.mod h1:h9dpzScPhDTs5noEMQVWP8Wx8AFBRyS0s8KWPx/9r0g= +cloud.google.com/go/datastream v1.5.0/go.mod h1:6TZMMNPwjUqZHBKPQ1wwXpb0d5VDVPl2/XoS5yi88q4= +cloud.google.com/go/datastream v1.6.0/go.mod h1:6LQSuswqLa7S4rPAOZFVjHIG3wJIjZcZrw8JDEDJuIs= +cloud.google.com/go/deploy v1.4.0/go.mod h1:5Xghikd4VrmMLNaF6FiRFDlHb59VM59YoDQnOUdsH/c= +cloud.google.com/go/deploy v1.5.0/go.mod h1:ffgdD0B89tToyW/U/D2eL0jN2+IEV/3EMuXHA0l4r+s= +cloud.google.com/go/deploy v1.6.0/go.mod h1:f9PTHehG/DjCom3QH0cntOVRm93uGBDt2vKzAPwpXQI= +cloud.google.com/go/dialogflow v1.15.0/go.mod h1:HbHDWs33WOGJgn6rfzBW1Kv807BE3O1+xGbn59zZWI4= +cloud.google.com/go/dialogflow v1.16.1/go.mod h1:po6LlzGfK+smoSmTBnbkIZY2w8ffjz/RcGSS+sh1el0= +cloud.google.com/go/dialogflow v1.17.0/go.mod h1:YNP09C/kXA1aZdBgC/VtXX74G/TKn7XVCcVumTflA+8= +cloud.google.com/go/dialogflow v1.18.0/go.mod h1:trO7Zu5YdyEuR+BhSNOqJezyFQ3aUzz0njv7sMx/iek= +cloud.google.com/go/dialogflow v1.19.0/go.mod h1:JVmlG1TwykZDtxtTXujec4tQ+D8SBFMoosgy+6Gn0s0= +cloud.google.com/go/dialogflow v1.29.0/go.mod h1:b+2bzMe+k1s9V+F2jbJwpHPzrnIyHihAdRFMtn2WXuM= +cloud.google.com/go/dialogflow v1.31.0/go.mod h1:cuoUccuL1Z+HADhyIA7dci3N5zUssgpBJmCzI6fNRB4= +cloud.google.com/go/dlp v1.6.0/go.mod h1:9eyB2xIhpU0sVwUixfBubDoRwP+GjeUoxxeueZmqvmM= +cloud.google.com/go/dlp v1.7.0/go.mod h1:68ak9vCiMBjbasxeVD17hVPxDEck+ExiHavX8kiHG+Q= +cloud.google.com/go/dlp v1.9.0/go.mod h1:qdgmqgTyReTz5/YNSSuueR8pl7hO0o9bQ39ZhtgkWp4= +cloud.google.com/go/documentai v1.7.0/go.mod h1:lJvftZB5NRiFSX4moiye1SMxHx0Bc3x1+p9e/RfXYiU= +cloud.google.com/go/documentai v1.8.0/go.mod h1:xGHNEB7CtsnySCNrCFdCyyMz44RhFEEX2Q7UD0c5IhU= +cloud.google.com/go/documentai v1.9.0/go.mod h1:FS5485S8R00U10GhgBC0aNGrJxBP8ZVpEeJ7PQDZd6k= +cloud.google.com/go/documentai v1.10.0/go.mod h1:vod47hKQIPeCfN2QS/jULIvQTugbmdc0ZvxxfQY1bg4= +cloud.google.com/go/documentai v1.16.0/go.mod h1:o0o0DLTEZ+YnJZ+J4wNfTxmDVyrkzFvttBXXtYRMHkM= +cloud.google.com/go/domains v0.6.0/go.mod h1:T9Rz3GasrpYk6mEGHh4rymIhjlnIuB4ofT1wTxDeT4Y= +cloud.google.com/go/domains v0.7.0/go.mod h1:PtZeqS1xjnXuRPKE/88Iru/LdfoRyEHYA9nFQf4UKpg= +cloud.google.com/go/domains v0.8.0/go.mod h1:M9i3MMDzGFXsydri9/vW+EWz9sWb4I6WyHqdlAk0idE= +cloud.google.com/go/edgecontainer v0.1.0/go.mod h1:WgkZ9tp10bFxqO8BLPqv2LlfmQF1X8lZqwW4r1BTajk= +cloud.google.com/go/edgecontainer v0.2.0/go.mod h1:RTmLijy+lGpQ7BXuTDa4C4ssxyXT34NIuHIgKuP4s5w= +cloud.google.com/go/edgecontainer v0.3.0/go.mod h1:FLDpP4nykgwwIfcLt6zInhprzw0lEi2P1fjO6Ie0qbc= +cloud.google.com/go/errorreporting v0.3.0/go.mod h1:xsP2yaAp+OAW4OIm60An2bbLpqIhKXdWR/tawvl7QzU= +cloud.google.com/go/essentialcontacts v1.3.0/go.mod h1:r+OnHa5jfj90qIfZDO/VztSFqbQan7HV75p8sA+mdGI= +cloud.google.com/go/essentialcontacts v1.4.0/go.mod h1:8tRldvHYsmnBCHdFpvU+GL75oWiBKl80BiqlFh9tp+8= +cloud.google.com/go/essentialcontacts v1.5.0/go.mod h1:ay29Z4zODTuwliK7SnX8E86aUF2CTzdNtvv42niCX0M= +cloud.google.com/go/eventarc v1.7.0/go.mod h1:6ctpF3zTnaQCxUjHUdcfgcA1A2T309+omHZth7gDfmc= +cloud.google.com/go/eventarc v1.8.0/go.mod h1:imbzxkyAU4ubfsaKYdQg04WS1NvncblHEup4kvF+4gw= +cloud.google.com/go/eventarc v1.10.0/go.mod h1:u3R35tmZ9HvswGRBnF48IlYgYeBcPUCjkr4BTdem2Kw= +cloud.google.com/go/filestore v1.3.0/go.mod h1:+qbvHGvXU1HaKX2nD0WEPo92TP/8AQuCVEBXNY9z0+w= +cloud.google.com/go/filestore v1.4.0/go.mod h1:PaG5oDfo9r224f8OYXURtAsY+Fbyq/bLYoINEK8XQAI= +cloud.google.com/go/filestore v1.5.0/go.mod h1:FqBXDWBp4YLHqRnVGveOkHDf8svj9r5+mUDLupOWEDs= cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk= +cloud.google.com/go/firestore v1.9.0/go.mod h1:HMkjKHNTtRyZNiMzu7YAsLr9K3X2udY2AMwDaMEQiiE= +cloud.google.com/go/functions v1.6.0/go.mod h1:3H1UA3qiIPRWD7PeZKLvHZ9SaQhR26XIJcC0A5GbvAk= +cloud.google.com/go/functions v1.7.0/go.mod h1:+d+QBcWM+RsrgZfV9xo6KfA1GlzJfxcfZcRPEhDDfzg= +cloud.google.com/go/functions v1.8.0/go.mod h1:RTZ4/HsQjIqIYP9a9YPbU+QFoQsAlYgrwOXJWHn1POY= +cloud.google.com/go/functions v1.9.0/go.mod h1:Y+Dz8yGguzO3PpIjhLTbnqV1CWmgQ5UwtlpzoyquQ08= +cloud.google.com/go/functions v1.10.0/go.mod h1:0D3hEOe3DbEvCXtYOZHQZmD+SzYsi1YbI7dGvHfldXw= +cloud.google.com/go/gaming v1.5.0/go.mod h1:ol7rGcxP/qHTRQE/RO4bxkXq+Fix0j6D4LFPzYTIrDM= +cloud.google.com/go/gaming v1.6.0/go.mod h1:YMU1GEvA39Qt3zWGyAVA9bpYz/yAhTvaQ1t2sK4KPUA= +cloud.google.com/go/gaming v1.7.0/go.mod h1:LrB8U7MHdGgFG851iHAfqUdLcKBdQ55hzXy9xBJz0+w= +cloud.google.com/go/gaming v1.8.0/go.mod h1:xAqjS8b7jAVW0KFYeRUxngo9My3f33kFmua++Pi+ggM= +cloud.google.com/go/gaming v1.9.0/go.mod h1:Fc7kEmCObylSWLO334NcO+O9QMDyz+TKC4v1D7X+Bc0= +cloud.google.com/go/gkebackup v0.2.0/go.mod h1:XKvv/4LfG829/B8B7xRkk8zRrOEbKtEam6yNfuQNH60= +cloud.google.com/go/gkebackup v0.3.0/go.mod h1:n/E671i1aOQvUxT541aTkCwExO/bTer2HDlj4TsBRAo= +cloud.google.com/go/gkebackup v0.4.0/go.mod h1:byAyBGUwYGEEww7xsbnUTBHIYcOPy/PgUWUtOeRm9Vg= +cloud.google.com/go/gkeconnect v0.5.0/go.mod h1:c5lsNAg5EwAy7fkqX/+goqFsU1Da/jQFqArp+wGNr/o= +cloud.google.com/go/gkeconnect v0.6.0/go.mod h1:Mln67KyU/sHJEBY8kFZ0xTeyPtzbq9StAVvEULYK16A= +cloud.google.com/go/gkeconnect v0.7.0/go.mod h1:SNfmVqPkaEi3bF/B3CNZOAYPYdg7sU+obZ+QTky2Myw= +cloud.google.com/go/gkehub v0.9.0/go.mod h1:WYHN6WG8w9bXU0hqNxt8rm5uxnk8IH+lPY9J2TV7BK0= +cloud.google.com/go/gkehub v0.10.0/go.mod h1:UIPwxI0DsrpsVoWpLB0stwKCP+WFVG9+y977wO+hBH0= +cloud.google.com/go/gkehub v0.11.0/go.mod h1:JOWHlmN+GHyIbuWQPl47/C2RFhnFKH38jH9Ascu3n0E= +cloud.google.com/go/gkemulticloud v0.3.0/go.mod h1:7orzy7O0S+5kq95e4Hpn7RysVA7dPs8W/GgfUtsPbrA= +cloud.google.com/go/gkemulticloud v0.4.0/go.mod h1:E9gxVBnseLWCk24ch+P9+B2CoDFJZTyIgLKSalC7tuI= +cloud.google.com/go/gkemulticloud v0.5.0/go.mod h1:W0JDkiyi3Tqh0TJr//y19wyb1yf8llHVto2Htf2Ja3Y= +cloud.google.com/go/grafeas v0.2.0/go.mod h1:KhxgtF2hb0P191HlY5besjYm6MqTSTj3LSI+M+ByZHc= +cloud.google.com/go/gsuiteaddons v1.3.0/go.mod h1:EUNK/J1lZEZO8yPtykKxLXI6JSVN2rg9bN8SXOa0bgM= +cloud.google.com/go/gsuiteaddons v1.4.0/go.mod h1:rZK5I8hht7u7HxFQcFei0+AtfS9uSushomRlg+3ua1o= +cloud.google.com/go/gsuiteaddons v1.5.0/go.mod h1:TFCClYLd64Eaa12sFVmUyG62tk4mdIsI7pAnSXRkcFo= +cloud.google.com/go/iam v0.1.0/go.mod h1:vcUNEa0pEm0qRVpmWepWaFMIAI8/hjB9mO8rNCJtF6c= +cloud.google.com/go/iam v0.3.0/go.mod h1:XzJPvDayI+9zsASAFO68Hk07u3z+f+JrT2xXNdp4bnY= +cloud.google.com/go/iam v0.5.0/go.mod h1:wPU9Vt0P4UmCux7mqtRu6jcpPAb74cP1fh50J3QpkUc= +cloud.google.com/go/iam v0.6.0/go.mod h1:+1AH33ueBne5MzYccyMHtEKqLE4/kJOibtffMHDMFMc= +cloud.google.com/go/iam v0.7.0/go.mod h1:H5Br8wRaDGNc8XP3keLc4unfUUZeyH3Sfl9XpQEYOeg= +cloud.google.com/go/iam v0.8.0/go.mod h1:lga0/y3iH6CX7sYqypWJ33hf7kkfXJag67naqGESjkE= +cloud.google.com/go/iam v0.11.0/go.mod h1:9PiLDanza5D+oWFZiH1uG+RnRCfEGKoyl6yo4cgWZGY= +cloud.google.com/go/iam v0.12.0/go.mod h1:knyHGviacl11zrtZUoDuYpDgLjvr28sLQaG0YB2GYAY= +cloud.google.com/go/iap v1.4.0/go.mod h1:RGFwRJdihTINIe4wZ2iCP0zF/qu18ZwyKxrhMhygBEc= +cloud.google.com/go/iap v1.5.0/go.mod h1:UH/CGgKd4KyohZL5Pt0jSKE4m3FR51qg6FKQ/z/Ix9A= +cloud.google.com/go/iap v1.6.0/go.mod h1:NSuvI9C/j7UdjGjIde7t7HBz+QTwBcapPE07+sSRcLk= +cloud.google.com/go/ids v1.1.0/go.mod h1:WIuwCaYVOzHIj2OhN9HAwvW+DBdmUAdcWlFxRl+KubM= +cloud.google.com/go/ids v1.2.0/go.mod h1:5WXvp4n25S0rA/mQWAg1YEEBBq6/s+7ml1RDCW1IrcY= +cloud.google.com/go/ids v1.3.0/go.mod h1:JBdTYwANikFKaDP6LtW5JAi4gubs57SVNQjemdt6xV4= +cloud.google.com/go/iot v1.3.0/go.mod h1:r7RGh2B61+B8oz0AGE+J72AhA0G7tdXItODWsaA2oLs= +cloud.google.com/go/iot v1.4.0/go.mod h1:dIDxPOn0UvNDUMD8Ger7FIaTuvMkj+aGk94RPP0iV+g= +cloud.google.com/go/iot v1.5.0/go.mod h1:mpz5259PDl3XJthEmh9+ap0affn/MqNSP4My77Qql9o= +cloud.google.com/go/kms v1.4.0/go.mod h1:fajBHndQ+6ubNw6Ss2sSd+SWvjL26RNo/dr7uxsnnOA= +cloud.google.com/go/kms v1.5.0/go.mod h1:QJS2YY0eJGBg3mnDfuaCyLauWwBJiHRboYxJ++1xJNg= +cloud.google.com/go/kms v1.6.0/go.mod h1:Jjy850yySiasBUDi6KFUwUv2n1+o7QZFyuUJg6OgjA0= +cloud.google.com/go/kms v1.9.0/go.mod h1:qb1tPTgfF9RQP8e1wq4cLFErVuTJv7UsSC915J8dh3w= +cloud.google.com/go/language v1.4.0/go.mod h1:F9dRpNFQmJbkaop6g0JhSBXCNlO90e1KWx5iDdxbWic= +cloud.google.com/go/language v1.6.0/go.mod h1:6dJ8t3B+lUYfStgls25GusK04NLh3eDLQnWM3mdEbhI= +cloud.google.com/go/language v1.7.0/go.mod h1:DJ6dYN/W+SQOjF8e1hLQXMF21AkH2w9wiPzPCJa2MIE= +cloud.google.com/go/language v1.8.0/go.mod h1:qYPVHf7SPoNNiCL2Dr0FfEFNil1qi3pQEyygwpgVKB8= +cloud.google.com/go/language v1.9.0/go.mod h1:Ns15WooPM5Ad/5no/0n81yUetis74g3zrbeJBE+ptUY= +cloud.google.com/go/lifesciences v0.5.0/go.mod h1:3oIKy8ycWGPUyZDR/8RNnTOYevhaMLqh5vLUXs9zvT8= +cloud.google.com/go/lifesciences v0.6.0/go.mod h1:ddj6tSX/7BOnhxCSd3ZcETvtNr8NZ6t/iPhY2Tyfu08= +cloud.google.com/go/lifesciences v0.8.0/go.mod h1:lFxiEOMqII6XggGbOnKiyZ7IBwoIqA84ClvoezaA/bo= +cloud.google.com/go/logging v1.6.1/go.mod h1:5ZO0mHHbvm8gEmeEUHrmDlTDSu5imF6MUP9OfilNXBw= +cloud.google.com/go/logging v1.7.0/go.mod h1:3xjP2CjkM3ZkO73aj4ASA5wRPGGCRrPIAeNqVNkzY8M= +cloud.google.com/go/longrunning v0.1.1/go.mod h1:UUFxuDWkv22EuY93jjmDMFT5GPQKeFVJBIF6QlTqdsE= +cloud.google.com/go/longrunning v0.3.0/go.mod h1:qth9Y41RRSUE69rDcOn6DdK3HfQfsUI0YSmW3iIlLJc= +cloud.google.com/go/longrunning v0.4.1/go.mod h1:4iWDqhBZ70CvZ6BfETbvam3T8FMvLK+eFj0E6AaRQTo= +cloud.google.com/go/managedidentities v1.3.0/go.mod h1:UzlW3cBOiPrzucO5qWkNkh0w33KFtBJU281hacNvsdE= +cloud.google.com/go/managedidentities v1.4.0/go.mod h1:NWSBYbEMgqmbZsLIyKvxrYbtqOsxY1ZrGM+9RgDqInM= +cloud.google.com/go/managedidentities v1.5.0/go.mod h1:+dWcZ0JlUmpuxpIDfyP5pP5y0bLdRwOS4Lp7gMni/LA= +cloud.google.com/go/maps v0.1.0/go.mod h1:BQM97WGyfw9FWEmQMpZ5T6cpovXXSd1cGmFma94eubI= +cloud.google.com/go/maps v0.6.0/go.mod h1:o6DAMMfb+aINHz/p/jbcY+mYeXBoZoxTfdSQ8VAJaCw= +cloud.google.com/go/mediatranslation v0.5.0/go.mod h1:jGPUhGTybqsPQn91pNXw0xVHfuJ3leR1wj37oU3y1f4= +cloud.google.com/go/mediatranslation v0.6.0/go.mod h1:hHdBCTYNigsBxshbznuIMFNe5QXEowAuNmmC7h8pu5w= +cloud.google.com/go/mediatranslation v0.7.0/go.mod h1:LCnB/gZr90ONOIQLgSXagp8XUW1ODs2UmUMvcgMfI2I= +cloud.google.com/go/memcache v1.4.0/go.mod h1:rTOfiGZtJX1AaFUrOgsMHX5kAzaTQ8azHiuDoTPzNsE= +cloud.google.com/go/memcache v1.5.0/go.mod h1:dk3fCK7dVo0cUU2c36jKb4VqKPS22BTkf81Xq617aWM= +cloud.google.com/go/memcache v1.6.0/go.mod h1:XS5xB0eQZdHtTuTF9Hf8eJkKtR3pVRCcvJwtm68T3rA= +cloud.google.com/go/memcache v1.7.0/go.mod h1:ywMKfjWhNtkQTxrWxCkCFkoPjLHPW6A7WOTVI8xy3LY= +cloud.google.com/go/memcache v1.9.0/go.mod h1:8oEyzXCu+zo9RzlEaEjHl4KkgjlNDaXbCQeQWlzNFJM= +cloud.google.com/go/metastore v1.5.0/go.mod h1:2ZNrDcQwghfdtCwJ33nM0+GrBGlVuh8rakL3vdPY3XY= +cloud.google.com/go/metastore v1.6.0/go.mod h1:6cyQTls8CWXzk45G55x57DVQ9gWg7RiH65+YgPsNh9s= +cloud.google.com/go/metastore v1.7.0/go.mod h1:s45D0B4IlsINu87/AsWiEVYbLaIMeUSoxlKKDqBGFS8= +cloud.google.com/go/metastore v1.8.0/go.mod h1:zHiMc4ZUpBiM7twCIFQmJ9JMEkDSyZS9U12uf7wHqSI= +cloud.google.com/go/metastore v1.10.0/go.mod h1:fPEnH3g4JJAk+gMRnrAnoqyv2lpUCqJPWOodSaf45Eo= +cloud.google.com/go/monitoring v1.7.0/go.mod h1:HpYse6kkGo//7p6sT0wsIC6IBDET0RhIsnmlA53dvEk= +cloud.google.com/go/monitoring v1.8.0/go.mod h1:E7PtoMJ1kQXWxPjB6mv2fhC5/15jInuulFdYYtlcvT4= +cloud.google.com/go/monitoring v1.12.0/go.mod h1:yx8Jj2fZNEkL/GYZyTLS4ZtZEZN8WtDEiEqG4kLK50w= +cloud.google.com/go/networkconnectivity v1.4.0/go.mod h1:nOl7YL8odKyAOtzNX73/M5/mGZgqqMeryi6UPZTk/rA= +cloud.google.com/go/networkconnectivity v1.5.0/go.mod h1:3GzqJx7uhtlM3kln0+x5wyFvuVH1pIBJjhCpjzSt75o= +cloud.google.com/go/networkconnectivity v1.6.0/go.mod h1:OJOoEXW+0LAxHh89nXd64uGG+FbQoeH8DtxCHVOMlaM= +cloud.google.com/go/networkconnectivity v1.7.0/go.mod h1:RMuSbkdbPwNMQjB5HBWD5MpTBnNm39iAVpC3TmsExt8= +cloud.google.com/go/networkconnectivity v1.10.0/go.mod h1:UP4O4sWXJG13AqrTdQCD9TnLGEbtNRqjuaaA7bNjF5E= +cloud.google.com/go/networkmanagement v1.4.0/go.mod h1:Q9mdLLRn60AsOrPc8rs8iNV6OHXaGcDdsIQe1ohekq8= +cloud.google.com/go/networkmanagement v1.5.0/go.mod h1:ZnOeZ/evzUdUsnvRt792H0uYEnHQEMaz+REhhzJRcf4= +cloud.google.com/go/networkmanagement v1.6.0/go.mod h1:5pKPqyXjB/sgtvB5xqOemumoQNB7y95Q7S+4rjSOPYY= +cloud.google.com/go/networksecurity v0.5.0/go.mod h1:xS6fOCoqpVC5zx15Z/MqkfDwH4+m/61A3ODiDV1xmiQ= +cloud.google.com/go/networksecurity v0.6.0/go.mod h1:Q5fjhTr9WMI5mbpRYEbiexTzROf7ZbDzvzCrNl14nyU= +cloud.google.com/go/networksecurity v0.7.0/go.mod h1:mAnzoxx/8TBSyXEeESMy9OOYwo1v+gZ5eMRnsT5bC8k= +cloud.google.com/go/notebooks v1.2.0/go.mod h1:9+wtppMfVPUeJ8fIWPOq1UnATHISkGXGqTkxeieQ6UY= +cloud.google.com/go/notebooks v1.3.0/go.mod h1:bFR5lj07DtCPC7YAAJ//vHskFBxA5JzYlH68kXVdk34= +cloud.google.com/go/notebooks v1.4.0/go.mod h1:4QPMngcwmgb6uw7Po99B2xv5ufVoIQ7nOGDyL4P8AgA= +cloud.google.com/go/notebooks v1.5.0/go.mod h1:q8mwhnP9aR8Hpfnrc5iN5IBhrXUy8S2vuYs+kBJ/gu0= +cloud.google.com/go/notebooks v1.7.0/go.mod h1:PVlaDGfJgj1fl1S3dUwhFMXFgfYGhYQt2164xOMONmE= +cloud.google.com/go/optimization v1.1.0/go.mod h1:5po+wfvX5AQlPznyVEZjGJTMr4+CAkJf2XSTQOOl9l4= +cloud.google.com/go/optimization v1.2.0/go.mod h1:Lr7SOHdRDENsh+WXVmQhQTrzdu9ybg0NecjHidBq6xs= +cloud.google.com/go/optimization v1.3.1/go.mod h1:IvUSefKiwd1a5p0RgHDbWCIbDFgKuEdB+fPPuP0IDLI= +cloud.google.com/go/orchestration v1.3.0/go.mod h1:Sj5tq/JpWiB//X/q3Ngwdl5K7B7Y0KZ7bfv0wL6fqVA= +cloud.google.com/go/orchestration v1.4.0/go.mod h1:6W5NLFWs2TlniBphAViZEVhrXRSMgUGDfW7vrWKvsBk= +cloud.google.com/go/orchestration v1.6.0/go.mod h1:M62Bevp7pkxStDfFfTuCOaXgaaqRAga1yKyoMtEoWPQ= +cloud.google.com/go/orgpolicy v1.4.0/go.mod h1:xrSLIV4RePWmP9P3tBl8S93lTmlAxjm06NSm2UTmKvE= +cloud.google.com/go/orgpolicy v1.5.0/go.mod h1:hZEc5q3wzwXJaKrsx5+Ewg0u1LxJ51nNFlext7Tanwc= +cloud.google.com/go/orgpolicy v1.10.0/go.mod h1:w1fo8b7rRqlXlIJbVhOMPrwVljyuW5mqssvBtU18ONc= +cloud.google.com/go/osconfig v1.7.0/go.mod h1:oVHeCeZELfJP7XLxcBGTMBvRO+1nQ5tFG9VQTmYS2Fs= +cloud.google.com/go/osconfig v1.8.0/go.mod h1:EQqZLu5w5XA7eKizepumcvWx+m8mJUhEwiPqWiZeEdg= +cloud.google.com/go/osconfig v1.9.0/go.mod h1:Yx+IeIZJ3bdWmzbQU4fxNl8xsZ4amB+dygAwFPlvnNo= +cloud.google.com/go/osconfig v1.10.0/go.mod h1:uMhCzqC5I8zfD9zDEAfvgVhDS8oIjySWh+l4WK6GnWw= +cloud.google.com/go/osconfig v1.11.0/go.mod h1:aDICxrur2ogRd9zY5ytBLV89KEgT2MKB2L/n6x1ooPw= +cloud.google.com/go/oslogin v1.4.0/go.mod h1:YdgMXWRaElXz/lDk1Na6Fh5orF7gvmJ0FGLIs9LId4E= +cloud.google.com/go/oslogin v1.5.0/go.mod h1:D260Qj11W2qx/HVF29zBg+0fd6YCSjSqLUkY/qEenQU= +cloud.google.com/go/oslogin v1.6.0/go.mod h1:zOJ1O3+dTU8WPlGEkFSh7qeHPPSoxrcMbbK1Nm2iX70= +cloud.google.com/go/oslogin v1.7.0/go.mod h1:e04SN0xO1UNJ1M5GP0vzVBFicIe4O53FOfcixIqTyXo= +cloud.google.com/go/oslogin v1.9.0/go.mod h1:HNavntnH8nzrn8JCTT5fj18FuJLFJc4NaZJtBnQtKFs= +cloud.google.com/go/phishingprotection v0.5.0/go.mod h1:Y3HZknsK9bc9dMi+oE8Bim0lczMU6hrX0UpADuMefr0= +cloud.google.com/go/phishingprotection v0.6.0/go.mod h1:9Y3LBLgy0kDTcYET8ZH3bq/7qni15yVUoAxiFxnlSUA= +cloud.google.com/go/phishingprotection v0.7.0/go.mod h1:8qJI4QKHoda/sb/7/YmMQ2omRLSLYSu9bU0EKCNI+Lk= +cloud.google.com/go/policytroubleshooter v1.3.0/go.mod h1:qy0+VwANja+kKrjlQuOzmlvscn4RNsAc0e15GGqfMxg= +cloud.google.com/go/policytroubleshooter v1.4.0/go.mod h1:DZT4BcRw3QoO8ota9xw/LKtPa8lKeCByYeKTIf/vxdE= +cloud.google.com/go/policytroubleshooter v1.5.0/go.mod h1:Rz1WfV+1oIpPdN2VvvuboLVRsB1Hclg3CKQ53j9l8vw= +cloud.google.com/go/privatecatalog v0.5.0/go.mod h1:XgosMUvvPyxDjAVNDYxJ7wBW8//hLDDYmnsNcMGq1K0= +cloud.google.com/go/privatecatalog v0.6.0/go.mod h1:i/fbkZR0hLN29eEWiiwue8Pb+GforiEIBnV9yrRUOKI= +cloud.google.com/go/privatecatalog v0.7.0/go.mod h1:2s5ssIFO69F5csTXcwBP7NPFTZvps26xGzvQ2PQaBYg= cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= +cloud.google.com/go/pubsub v1.26.0/go.mod h1:QgBH3U/jdJy/ftjPhTkyXNj543Tin1pRYcdcPRnFIRI= +cloud.google.com/go/pubsub v1.27.1/go.mod h1:hQN39ymbV9geqBnfQq6Xf63yNhUAhv9CZhzp5O6qsW0= +cloud.google.com/go/pubsub v1.28.0/go.mod h1:vuXFpwaVoIPQMGXqRyUQigu/AX1S3IWugR9xznmcXX8= +cloud.google.com/go/pubsublite v1.5.0/go.mod h1:xapqNQ1CuLfGi23Yda/9l4bBCKz/wC3KIJ5gKcxveZg= +cloud.google.com/go/pubsublite v1.6.0/go.mod h1:1eFCS0U11xlOuMFV/0iBqw3zP12kddMeCbj/F3FSj9k= +cloud.google.com/go/recaptchaenterprise v1.3.1/go.mod h1:OdD+q+y4XGeAlxRaMn1Y7/GveP6zmq76byL6tjPE7d4= +cloud.google.com/go/recaptchaenterprise/v2 v2.1.0/go.mod h1:w9yVqajwroDNTfGuhmOjPDN//rZGySaf6PtFVcSCa7o= +cloud.google.com/go/recaptchaenterprise/v2 v2.2.0/go.mod h1:/Zu5jisWGeERrd5HnlS3EUGb/D335f9k51B/FVil0jk= +cloud.google.com/go/recaptchaenterprise/v2 v2.3.0/go.mod h1:O9LwGCjrhGHBQET5CA7dd5NwwNQUErSgEDit1DLNTdo= +cloud.google.com/go/recaptchaenterprise/v2 v2.4.0/go.mod h1:Am3LHfOuBstrLrNCBrlI5sbwx9LBg3te2N6hGvHn2mE= +cloud.google.com/go/recaptchaenterprise/v2 v2.5.0/go.mod h1:O8LzcHXN3rz0j+LBC91jrwI3R+1ZSZEWrfL7XHgNo9U= +cloud.google.com/go/recaptchaenterprise/v2 v2.6.0/go.mod h1:RPauz9jeLtB3JVzg6nCbe12qNoaa8pXc4d/YukAmcnA= +cloud.google.com/go/recommendationengine v0.5.0/go.mod h1:E5756pJcVFeVgaQv3WNpImkFP8a+RptV6dDLGPILjvg= +cloud.google.com/go/recommendationengine v0.6.0/go.mod h1:08mq2umu9oIqc7tDy8sx+MNJdLG0fUi3vaSVbztHgJ4= +cloud.google.com/go/recommendationengine v0.7.0/go.mod h1:1reUcE3GIu6MeBz/h5xZJqNLuuVjNg1lmWMPyjatzac= +cloud.google.com/go/recommender v1.5.0/go.mod h1:jdoeiBIVrJe9gQjwd759ecLJbxCDED4A6p+mqoqDvTg= +cloud.google.com/go/recommender v1.6.0/go.mod h1:+yETpm25mcoiECKh9DEScGzIRyDKpZ0cEhWGo+8bo+c= +cloud.google.com/go/recommender v1.7.0/go.mod h1:XLHs/W+T8olwlGOgfQenXBTbIseGclClff6lhFVe9Bs= +cloud.google.com/go/recommender v1.8.0/go.mod h1:PkjXrTT05BFKwxaUxQmtIlrtj0kph108r02ZZQ5FE70= +cloud.google.com/go/recommender v1.9.0/go.mod h1:PnSsnZY7q+VL1uax2JWkt/UegHssxjUVVCrX52CuEmQ= +cloud.google.com/go/redis v1.7.0/go.mod h1:V3x5Jq1jzUcg+UNsRvdmsfuFnit1cfe3Z/PGyq/lm4Y= +cloud.google.com/go/redis v1.8.0/go.mod h1:Fm2szCDavWzBk2cDKxrkmWBqoCiL1+Ctwq7EyqBCA/A= +cloud.google.com/go/redis v1.9.0/go.mod h1:HMYQuajvb2D0LvMgZmLDZW8V5aOC/WxstZHiy4g8OiA= +cloud.google.com/go/redis v1.10.0/go.mod h1:ThJf3mMBQtW18JzGgh41/Wld6vnDDc/F/F35UolRZPM= +cloud.google.com/go/redis v1.11.0/go.mod h1:/X6eicana+BWcUda5PpwZC48o37SiFVTFSs0fWAJ7uQ= +cloud.google.com/go/resourcemanager v1.3.0/go.mod h1:bAtrTjZQFJkiWTPDb1WBjzvc6/kifjj4QBYuKCCoqKA= +cloud.google.com/go/resourcemanager v1.4.0/go.mod h1:MwxuzkumyTX7/a3n37gmsT3py7LIXwrShilPh3P1tR0= +cloud.google.com/go/resourcemanager v1.5.0/go.mod h1:eQoXNAiAvCf5PXxWxXjhKQoTMaUSNrEfg+6qdf/wots= +cloud.google.com/go/resourcesettings v1.3.0/go.mod h1:lzew8VfESA5DQ8gdlHwMrqZs1S9V87v3oCnKCWoOuQU= +cloud.google.com/go/resourcesettings v1.4.0/go.mod h1:ldiH9IJpcrlC3VSuCGvjR5of/ezRrOxFtpJoJo5SmXg= +cloud.google.com/go/resourcesettings v1.5.0/go.mod h1:+xJF7QSG6undsQDfsCJyqWXyBwUoJLhetkRMDRnIoXA= +cloud.google.com/go/retail v1.8.0/go.mod h1:QblKS8waDmNUhghY2TI9O3JLlFk8jybHeV4BF19FrE4= +cloud.google.com/go/retail v1.9.0/go.mod h1:g6jb6mKuCS1QKnH/dpu7isX253absFl6iE92nHwlBUY= +cloud.google.com/go/retail v1.10.0/go.mod h1:2gDk9HsL4HMS4oZwz6daui2/jmKvqShXKQuB2RZ+cCc= +cloud.google.com/go/retail v1.11.0/go.mod h1:MBLk1NaWPmh6iVFSz9MeKG/Psyd7TAgm6y/9L2B4x9Y= +cloud.google.com/go/retail v1.12.0/go.mod h1:UMkelN/0Z8XvKymXFbD4EhFJlYKRx1FGhQkVPU5kF14= +cloud.google.com/go/run v0.2.0/go.mod h1:CNtKsTA1sDcnqqIFR3Pb5Tq0usWxJJvsWOCPldRU3Do= +cloud.google.com/go/run v0.3.0/go.mod h1:TuyY1+taHxTjrD0ZFk2iAR+xyOXEA0ztb7U3UNA0zBo= +cloud.google.com/go/run v0.8.0/go.mod h1:VniEnuBwqjigv0A7ONfQUaEItaiCRVujlMqerPPiktM= +cloud.google.com/go/scheduler v1.4.0/go.mod h1:drcJBmxF3aqZJRhmkHQ9b3uSSpQoltBPGPxGAWROx6s= +cloud.google.com/go/scheduler v1.5.0/go.mod h1:ri073ym49NW3AfT6DZi21vLZrG07GXr5p3H1KxN5QlI= +cloud.google.com/go/scheduler v1.6.0/go.mod h1:SgeKVM7MIwPn3BqtcBntpLyrIJftQISRrYB5ZtT+KOk= +cloud.google.com/go/scheduler v1.7.0/go.mod h1:jyCiBqWW956uBjjPMMuX09n3x37mtyPJegEWKxRsn44= +cloud.google.com/go/scheduler v1.8.0/go.mod h1:TCET+Y5Gp1YgHT8py4nlg2Sew8nUHMqcpousDgXJVQc= +cloud.google.com/go/secretmanager v1.6.0/go.mod h1:awVa/OXF6IiyaU1wQ34inzQNc4ISIDIrId8qE5QGgKA= +cloud.google.com/go/secretmanager v1.8.0/go.mod h1:hnVgi/bN5MYHd3Gt0SPuTPPp5ENina1/LxM+2W9U9J4= +cloud.google.com/go/secretmanager v1.9.0/go.mod h1:b71qH2l1yHmWQHt9LC80akm86mX8AL6X1MA01dW8ht4= +cloud.google.com/go/secretmanager v1.10.0/go.mod h1:MfnrdvKMPNra9aZtQFvBcvRU54hbPD8/HayQdlUgJpU= +cloud.google.com/go/security v1.5.0/go.mod h1:lgxGdyOKKjHL4YG3/YwIL2zLqMFCKs0UbQwgyZmfJl4= +cloud.google.com/go/security v1.7.0/go.mod h1:mZklORHl6Bg7CNnnjLH//0UlAlaXqiG7Lb9PsPXLfD0= +cloud.google.com/go/security v1.8.0/go.mod h1:hAQOwgmaHhztFhiQ41CjDODdWP0+AE1B3sX4OFlq+GU= +cloud.google.com/go/security v1.9.0/go.mod h1:6Ta1bO8LXI89nZnmnsZGp9lVoVWXqsVbIq/t9dzI+2Q= +cloud.google.com/go/security v1.10.0/go.mod h1:QtOMZByJVlibUT2h9afNDWRZ1G96gVywH8T5GUSb9IA= +cloud.google.com/go/security v1.12.0/go.mod h1:rV6EhrpbNHrrxqlvW0BWAIawFWq3X90SduMJdFwtLB8= +cloud.google.com/go/securitycenter v1.13.0/go.mod h1:cv5qNAqjY84FCN6Y9z28WlkKXyWsgLO832YiWwkCWcU= +cloud.google.com/go/securitycenter v1.14.0/go.mod h1:gZLAhtyKv85n52XYWt6RmeBdydyxfPeTrpToDPw4Auc= +cloud.google.com/go/securitycenter v1.15.0/go.mod h1:PeKJ0t8MoFmmXLXWm41JidyzI3PJjd8sXWaVqg43WWk= +cloud.google.com/go/securitycenter v1.16.0/go.mod h1:Q9GMaLQFUD+5ZTabrbujNWLtSLZIZF7SAR0wWECrjdk= +cloud.google.com/go/securitycenter v1.18.1/go.mod h1:0/25gAzCM/9OL9vVx4ChPeM/+DlfGQJDwBy/UC8AKK0= +cloud.google.com/go/servicecontrol v1.4.0/go.mod h1:o0hUSJ1TXJAmi/7fLJAedOovnujSEvjKCAFNXPQ1RaU= +cloud.google.com/go/servicecontrol v1.5.0/go.mod h1:qM0CnXHhyqKVuiZnGKrIurvVImCs8gmqWsDoqe9sU1s= +cloud.google.com/go/servicecontrol v1.11.0/go.mod h1:kFmTzYzTUIuZs0ycVqRHNaNhgR+UMUpw9n02l/pY+mc= +cloud.google.com/go/servicedirectory v1.4.0/go.mod h1:gH1MUaZCgtP7qQiI+F+A+OpeKF/HQWgtAddhTbhL2bs= +cloud.google.com/go/servicedirectory v1.5.0/go.mod h1:QMKFL0NUySbpZJ1UZs3oFAmdvVxhhxB6eJ/Vlp73dfg= +cloud.google.com/go/servicedirectory v1.6.0/go.mod h1:pUlbnWsLH9c13yGkxCmfumWEPjsRs1RlmJ4pqiNjVL4= +cloud.google.com/go/servicedirectory v1.7.0/go.mod h1:5p/U5oyvgYGYejufvxhgwjL8UVXjkuw7q5XcG10wx1U= +cloud.google.com/go/servicedirectory v1.8.0/go.mod h1:srXodfhY1GFIPvltunswqXpVxFPpZjf8nkKQT7XcXaY= +cloud.google.com/go/servicemanagement v1.4.0/go.mod h1:d8t8MDbezI7Z2R1O/wu8oTggo3BI2GKYbdG4y/SJTco= +cloud.google.com/go/servicemanagement v1.5.0/go.mod h1:XGaCRe57kfqu4+lRxaFEAuqmjzF0r+gWHjWqKqBvKFo= +cloud.google.com/go/servicemanagement v1.6.0/go.mod h1:aWns7EeeCOtGEX4OvZUWCCJONRZeFKiptqKf1D0l/Jc= +cloud.google.com/go/serviceusage v1.3.0/go.mod h1:Hya1cozXM4SeSKTAgGXgj97GlqUvF5JaoXacR1JTP/E= +cloud.google.com/go/serviceusage v1.4.0/go.mod h1:SB4yxXSaYVuUBYUml6qklyONXNLt83U0Rb+CXyhjEeU= +cloud.google.com/go/serviceusage v1.5.0/go.mod h1:w8U1JvqUqwJNPEOTQjrMHkw3IaIFLoLsPLvsE3xueec= +cloud.google.com/go/shell v1.3.0/go.mod h1:VZ9HmRjZBsjLGXusm7K5Q5lzzByZmJHf1d0IWHEN5X4= +cloud.google.com/go/shell v1.4.0/go.mod h1:HDxPzZf3GkDdhExzD/gs8Grqk+dmYcEjGShZgYa9URw= +cloud.google.com/go/shell v1.6.0/go.mod h1:oHO8QACS90luWgxP3N9iZVuEiSF84zNyLytb+qE2f9A= +cloud.google.com/go/spanner v1.41.0/go.mod h1:MLYDBJR/dY4Wt7ZaMIQ7rXOTLjYrmxLE/5ve9vFfWos= +cloud.google.com/go/spanner v1.44.0/go.mod h1:G8XIgYdOK+Fbcpbs7p2fiprDw4CaZX63whnSMLVBxjk= +cloud.google.com/go/speech v1.6.0/go.mod h1:79tcr4FHCimOp56lwC01xnt/WPJZc4v3gzyT7FoBkCM= +cloud.google.com/go/speech v1.7.0/go.mod h1:KptqL+BAQIhMsj1kOP2la5DSEEerPDuOP/2mmkhHhZQ= +cloud.google.com/go/speech v1.8.0/go.mod h1:9bYIl1/tjsAnMgKGHKmBZzXKEkGgtU+MpdDPTE9f7y0= +cloud.google.com/go/speech v1.9.0/go.mod h1:xQ0jTcmnRFFM2RfX/U+rk6FQNUF6DQlydUSyoooSpco= +cloud.google.com/go/speech v1.14.1/go.mod h1:gEosVRPJ9waG7zqqnsHpYTOoAS4KouMRLDFMekpJ0J0= cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= cloud.google.com/go/storage v1.14.0/go.mod h1:GrKmX003DSIwi9o29oFT7YDnHYwZoctc3fOKtUw0Xmo= +cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq6kuBTW58Y= +cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= +cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= +cloud.google.com/go/storage v1.28.1/go.mod h1:Qnisd4CqDdo6BGs2AD5LLnEsmSQ80wQ5ogcBBKhU86Y= +cloud.google.com/go/storagetransfer v1.5.0/go.mod h1:dxNzUopWy7RQevYFHewchb29POFv3/AaBgnhqzqiK0w= +cloud.google.com/go/storagetransfer v1.6.0/go.mod h1:y77xm4CQV/ZhFZH75PLEXY0ROiS7Gh6pSKrM8dJyg6I= +cloud.google.com/go/storagetransfer v1.7.0/go.mod h1:8Giuj1QNb1kfLAiWM1bN6dHzfdlDAVC9rv9abHot2W4= +cloud.google.com/go/talent v1.1.0/go.mod h1:Vl4pt9jiHKvOgF9KoZo6Kob9oV4lwd/ZD5Cto54zDRw= +cloud.google.com/go/talent v1.2.0/go.mod h1:MoNF9bhFQbiJ6eFD3uSsg0uBALw4n4gaCaEjBw9zo8g= +cloud.google.com/go/talent v1.3.0/go.mod h1:CmcxwJ/PKfRgd1pBjQgU6W3YBwiewmUzQYH5HHmSCmM= +cloud.google.com/go/talent v1.4.0/go.mod h1:ezFtAgVuRf8jRsvyE6EwmbTK5LKciD4KVnHuDEFmOOA= +cloud.google.com/go/talent v1.5.0/go.mod h1:G+ODMj9bsasAEJkQSzO2uHQWXHHXUomArjWQQYkqK6c= +cloud.google.com/go/texttospeech v1.4.0/go.mod h1:FX8HQHA6sEpJ7rCMSfXuzBcysDAuWusNNNvN9FELDd8= +cloud.google.com/go/texttospeech v1.5.0/go.mod h1:oKPLhR4n4ZdQqWKURdwxMy0uiTS1xU161C8W57Wkea4= +cloud.google.com/go/texttospeech v1.6.0/go.mod h1:YmwmFT8pj1aBblQOI3TfKmwibnsfvhIBzPXcW4EBovc= +cloud.google.com/go/tpu v1.3.0/go.mod h1:aJIManG0o20tfDQlRIej44FcwGGl/cD0oiRyMKG19IQ= +cloud.google.com/go/tpu v1.4.0/go.mod h1:mjZaX8p0VBgllCzF6wcU2ovUXN9TONFLd7iz227X2Xg= +cloud.google.com/go/tpu v1.5.0/go.mod h1:8zVo1rYDFuW2l4yZVY0R0fb/v44xLh3llq7RuV61fPM= +cloud.google.com/go/trace v1.3.0/go.mod h1:FFUE83d9Ca57C+K8rDl/Ih8LwOzWIV1krKgxg6N0G28= +cloud.google.com/go/trace v1.4.0/go.mod h1:UG0v8UBqzusp+z63o7FK74SdFE+AXpCLdFb1rshXG+Y= +cloud.google.com/go/trace v1.8.0/go.mod h1:zH7vcsbAhklH8hWFig58HvxcxyQbaIqMarMg9hn5ECA= +cloud.google.com/go/translate v1.3.0/go.mod h1:gzMUwRjvOqj5i69y/LYLd8RrNQk+hOmIXTi9+nb3Djs= +cloud.google.com/go/translate v1.4.0/go.mod h1:06Dn/ppvLD6WvA5Rhdp029IX2Mi3Mn7fpMRLPvXT5Wg= +cloud.google.com/go/translate v1.6.0/go.mod h1:lMGRudH1pu7I3n3PETiOB2507gf3HnfLV8qlkHZEyos= +cloud.google.com/go/video v1.8.0/go.mod h1:sTzKFc0bUSByE8Yoh8X0mn8bMymItVGPfTuUBUyRgxk= +cloud.google.com/go/video v1.9.0/go.mod h1:0RhNKFRF5v92f8dQt0yhaHrEuH95m068JYOvLZYnJSw= +cloud.google.com/go/video v1.13.0/go.mod h1:ulzkYlYgCp15N2AokzKjy7MQ9ejuynOJdf1tR5lGthk= +cloud.google.com/go/videointelligence v1.6.0/go.mod h1:w0DIDlVRKtwPCn/C4iwZIJdvC69yInhW0cfi+p546uU= +cloud.google.com/go/videointelligence v1.7.0/go.mod h1:k8pI/1wAhjznARtVT9U1llUaFNPh7muw8QyOUpavru4= +cloud.google.com/go/videointelligence v1.8.0/go.mod h1:dIcCn4gVDdS7yte/w+koiXn5dWVplOZkE+xwG9FgK+M= +cloud.google.com/go/videointelligence v1.9.0/go.mod h1:29lVRMPDYHikk3v8EdPSaL8Ku+eMzDljjuvRs105XoU= +cloud.google.com/go/videointelligence v1.10.0/go.mod h1:LHZngX1liVtUhZvi2uNS0VQuOzNi2TkY1OakiuoUOjU= +cloud.google.com/go/vision v1.2.0/go.mod h1:SmNwgObm5DpFBme2xpyOyasvBc1aPdjvMk2bBk0tKD0= +cloud.google.com/go/vision/v2 v2.2.0/go.mod h1:uCdV4PpN1S0jyCyq8sIM42v2Y6zOLkZs+4R9LrGYwFo= +cloud.google.com/go/vision/v2 v2.3.0/go.mod h1:UO61abBx9QRMFkNBbf1D8B1LXdS2cGiiCRx0vSpZoUo= +cloud.google.com/go/vision/v2 v2.4.0/go.mod h1:VtI579ll9RpVTrdKdkMzckdnwMyX2JILb+MhPqRbPsY= +cloud.google.com/go/vision/v2 v2.5.0/go.mod h1:MmaezXOOE+IWa+cS7OhRRLK2cNv1ZL98zhqFFZaaH2E= +cloud.google.com/go/vision/v2 v2.6.0/go.mod h1:158Hes0MvOS9Z/bDMSFpjwsUrZ5fPrdwuyyvKSGAGMY= +cloud.google.com/go/vmmigration v1.2.0/go.mod h1:IRf0o7myyWFSmVR1ItrBSFLFD/rJkfDCUTO4vLlJvsE= +cloud.google.com/go/vmmigration v1.3.0/go.mod h1:oGJ6ZgGPQOFdjHuocGcLqX4lc98YQ7Ygq8YQwHh9A7g= +cloud.google.com/go/vmmigration v1.5.0/go.mod h1:E4YQ8q7/4W9gobHjQg4JJSgXXSgY21nA5r8swQV+Xxc= +cloud.google.com/go/vmwareengine v0.1.0/go.mod h1:RsdNEf/8UDvKllXhMz5J40XxDrNJNN4sagiox+OI208= +cloud.google.com/go/vmwareengine v0.2.2/go.mod h1:sKdctNJxb3KLZkE/6Oui94iw/xs9PRNC2wnNLXsHvH8= +cloud.google.com/go/vpcaccess v1.4.0/go.mod h1:aQHVbTWDYUR1EbTApSVvMq1EnT57ppDmQzZ3imqIk4w= +cloud.google.com/go/vpcaccess v1.5.0/go.mod h1:drmg4HLk9NkZpGfCmZ3Tz0Bwnm2+DKqViEpeEpOq0m8= +cloud.google.com/go/vpcaccess v1.6.0/go.mod h1:wX2ILaNhe7TlVa4vC5xce1bCnqE3AeH27RV31lnmZes= +cloud.google.com/go/webrisk v1.4.0/go.mod h1:Hn8X6Zr+ziE2aNd8SliSDWpEnSS1u4R9+xXZmFiHmGE= +cloud.google.com/go/webrisk v1.5.0/go.mod h1:iPG6fr52Tv7sGk0H6qUFzmL3HHZev1htXuWDEEsqMTg= +cloud.google.com/go/webrisk v1.6.0/go.mod h1:65sW9V9rOosnc9ZY7A7jsy1zoHS5W9IAXv6dGqhMQMc= +cloud.google.com/go/webrisk v1.7.0/go.mod h1:mVMHgEYH0r337nmt1JyLthzMr6YxwN1aAIEc2fTcq7A= +cloud.google.com/go/webrisk v1.8.0/go.mod h1:oJPDuamzHXgUc+b8SiHRcVInZQuybnvEW72PqTc7sSg= +cloud.google.com/go/websecurityscanner v1.3.0/go.mod h1:uImdKm2wyeXQevQJXeh8Uun/Ym1VqworNDlBXQevGMo= +cloud.google.com/go/websecurityscanner v1.4.0/go.mod h1:ebit/Fp0a+FWu5j4JOmJEV8S8CzdTkAS77oDsiSqYWQ= +cloud.google.com/go/websecurityscanner v1.5.0/go.mod h1:Y6xdCPy81yi0SQnDY1xdNTNpfY1oAgXUlcfN3B3eSng= +cloud.google.com/go/workflows v1.6.0/go.mod h1:6t9F5h/unJz41YqfBmqSASJSXccBLtD1Vwf+KmJENM0= +cloud.google.com/go/workflows v1.7.0/go.mod h1:JhSrZuVZWuiDfKEFxU0/F1PQjmpnpcoISEXH2bcHC3M= +cloud.google.com/go/workflows v1.8.0/go.mod h1:ysGhmEajwZxGn1OhGOGKsTXc5PyxOc0vfKf5Af+to4M= +cloud.google.com/go/workflows v1.9.0/go.mod h1:ZGkj1aFIOd9c8Gerkjjq7OW7I5+l6cSvT3ujaO/WwSA= +cloud.google.com/go/workflows v1.10.0/go.mod h1:fZ8LmRmZQWacon9UCX1r/g/DfAXx5VcPALq2CxzdePw= contrib.go.opencensus.io/exporter/stackdriver v0.12.6/go.mod h1:8x999/OcIPy5ivx/wDiV7Gx4D+VUPODf0mWRGRc5kSk= contrib.go.opencensus.io/exporter/stackdriver v0.13.4/go.mod h1:aXENhDJ1Y4lIg4EUaVTwzvYETVNZk10Pu26tevFKLUc= contrib.go.opencensus.io/exporter/stackdriver v0.13.5 h1:TNaexHK16gPUoc7uzELKOU7JULqccn1NDuqUxmxSqfo= @@ -55,17 +528,28 @@ dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7 filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= filippo.io/edwards25519 v1.0.0 h1:0wAIcmJUqRdI8IJ/3eGi5/HwXZWPujYXXlkrQogz0Ek= filippo.io/edwards25519 v1.0.0/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= +gioui.org v0.0.0-20210308172011-57750fc8a0a6/go.mod h1:RSH6KIUZ0p2xy5zHDxgAM4zumjgTw83q2ge/PI+yyw8= +git.sr.ht/~sbinet/gg v0.3.1/go.mod h1:KGYtlADtqsqANL9ueOFkWymvzUvLMQllU5Ixo+8v3pc= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMbk2FiG/kXiLl8BRyzTWDw7gX/Hz7Dd5eDMs= github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4/go.mod h1:hN7oaIRCjzsZ2dE+yG5k+rsdt3qcwykqK6HVGcKwsw4= github.com/99designs/keyring v1.2.1 h1:tYLp1ULvO7i3fI5vE21ReQuj99QFSs7lGm0xWyJo87o= github.com/99designs/keyring v1.2.1/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA= +github.com/AdaLogics/go-fuzz-headers v0.0.0-20210715213245-6c3934b029d8 h1:V8krnnfGj4pV65YLUm3C0/8bl7V5Nry2Pwvy3ru/wLc= github.com/AlekSi/pointer v1.1.0 h1:SSDMPcXD9jSl8FPy9cRzoRaMJtm9g9ggGTxecRUbQoI= github.com/AlekSi/pointer v1.1.0/go.mod h1:y7BvfRI3wXPWKXEBhU71nbnIEEZX0QTSB2Bj48UJIZE= github.com/AndreasBriese/bbloom v0.0.0-20180913140656-343706a395b7/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/Azure/azure-sdk-for-go v65.0.0+incompatible h1:HzKLt3kIwMm4KeJYTdx9EbjRYTySD/t8i1Ee/W5EGXw= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= +github.com/Azure/go-autorest v14.2.0+incompatible h1:V5VMDjClD3GiElqLWO7mz2MxNAK/vTfRHdAubSIPRgs= +github.com/Azure/go-autorest/autorest v0.11.28 h1:ndAExarwr5Y+GaHE6VCaY1kyS/HwwGGyuimVhWsHOEM= +github.com/Azure/go-autorest/autorest/adal v0.9.22 h1:/GblQdIudfEM3AWWZ0mrYJQSd7JS4S/Mbzh6F0ov0Xc= +github.com/Azure/go-autorest/autorest/date v0.3.0 h1:7gUk1U5M/CQbp9WoqinNzJar+8KY+LPI6wiWrP/myHw= +github.com/Azure/go-autorest/autorest/to v0.4.0 h1:oXVqrxakqqV1UZdSazDOPOLvOIz+XA683u8EctwboHk= +github.com/Azure/go-autorest/autorest/validation v0.3.1 h1:AgyqjAd94fwNAoTjl/WQXg4VvFeRFpO+UhNyRXqF1ac= +github.com/Azure/go-autorest/logger v0.2.1 h1:IG7i4p/mDa2Ce4TRyAO8IHnVhAVF3RFU+ZtXWSmf4Tg= +github.com/Azure/go-autorest/tracing v0.6.0 h1:TYi4+3m5t6K48TGI9AUdb+IzbnSxvnvUMfuitfgcfuo= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v1.2.1 h1:9F2/+DoOYIOksmaJFPw1tGFy1eDnIJXg+UHjuD8lTak= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= @@ -75,12 +559,19 @@ github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3 github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/CosmWasm/wasmd v0.40.1 h1:LxbO78t/6S8TkeQlUrJ0m5O87HtAwLx4RGHq3rdrOEU= github.com/CosmWasm/wasmvm v1.2.4 h1:6OfeZuEcEH/9iqwrg2pkeVtDCkMoj9U6PpKtcrCyVrQ= +github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/zstd v1.5.2 h1:vUG4lAyuPCXO0TLbXvPv7EB7cNK1QV/luu55UHLrrn8= github.com/DataDog/zstd v1.5.2/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= github.com/Depado/ginprom v1.7.11 h1:qOhxW/NJZkNkkG4TQrzAZklX8SUTjTfLA73zIUNIpww= github.com/GeertJohan/go.incremental v1.0.0/go.mod h1:6fAjUhbVuX1KcMD3c8TEgVUqmo4seqhv0i0kdATSkM0= github.com/GeertJohan/go.rice v1.0.0/go.mod h1:eH6gbSOAUv07dQuZVnBmoDP8mgsM1rtixis4Tib9if0= +github.com/HdrHistogram/hdrhistogram-go v1.1.2 h1:5IcZpTvzydCQeHzK4Ef/D5rrSqwxob0t8PQPMybUNFM= +github.com/JohnCGriffin/overflow v0.0.0-20211019200055-46fa312c352c/go.mod h1:X0CRv0ky0k6m906ixxpzmDRLvX58TFUKS2eePweuyxk= github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= +github.com/K-Phoen/grabana v0.21.17 h1:mO/9DvJWC/qpTF/X5jQDm5eKgCBaCGypP/tEfXAvKfg= +github.com/K-Phoen/grabana v0.21.17/go.mod h1:vbASQt9UiQhX4lC3/opLpJMJ8m+hsTUU2FwkQMytHK4= +github.com/K-Phoen/sdk v0.12.2 h1:0QofDlKE+lloyBOzhjEEMW21061zts/WIpfpQ5NLLAs= +github.com/K-Phoen/sdk v0.12.2/go.mod h1:qmM0wO23CtoDux528MXPpYvS4XkRWkWX6rvX9Za8EVU= github.com/Kubuxu/go-os-helper v0.0.1/go.mod h1:N8B+I7vPCT80IcP58r50u4+gEEcsZETFUpAzWW2ep1Y= github.com/MakeNowJust/heredoc v1.0.0 h1:cXCdzVdstXyiTqTvfqk9SDHpKNjxuom+DOlyEeQ4pzQ= github.com/MakeNowJust/heredoc v1.0.0/go.mod h1:mG5amYoWBHf8vpLOuehzbGGw0EHxpZZ6lCpQ4fNJ8LE= @@ -88,36 +579,60 @@ github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0 github.com/Masterminds/semver/v3 v3.2.1 h1:RN9w6+7QoMeJVGyfmbcgs28Br8cvmnucEXnY0rYXWg0= github.com/Masterminds/semver/v3 v3.2.1/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= +github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= +github.com/Microsoft/hcsshim v0.9.7 h1:mKNHW/Xvv1aFH87Jb6ERDzXTJTLPlmzfZ28VBFD/bfg= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OneOfOne/xxhash v1.2.6 h1:U68crOE3y3MPttCMQGywZOLrTeF5HHJ3/vDBCJn9/bA= -github.com/OneOfOne/xxhash v1.2.6/go.mod h1:eZbhyaAYD41SGSSsnmcpxVoRiQ/MPUTjUdIIOT9Um7Q= +github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= +github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= github.com/VictoriaMetrics/fastcache v1.10.0 h1:5hDJnLsKLpnUEToub7ETuRu8RCkb40woBZAUiKonXzY= github.com/VictoriaMetrics/fastcache v1.10.0/go.mod h1:tjiYeEfYXCqacuvYw/7UoDIeJaNxq6132xHICNP77w8= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= +github.com/ajstarks/deck v0.0.0-20200831202436-30c9fc6549a9/go.mod h1:JynElWSGnm/4RlzPXRlREEwqTHAN3T56Bv2ITsFT3gY= +github.com/ajstarks/deck/generate v0.0.0-20210309230005-c3f852c02e19/go.mod h1:T13YZdzov6OU0A1+RfKZiZN9ca6VeKdBdyDV+BY97Tk= +github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3/J6wwsYMMT4xOr94bZjxIelGM0+d/wbFw= +github.com/ajstarks/svgo v0.0.0-20211024235047-1546f124cd8b/go.mod h1:1KcenG0jGWcpt8ov532z81sp/kMMUG485J2InIOyADM= github.com/akavel/rsrc v0.8.0/go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c= +github.com/alecthomas/kingpin/v2 v2.3.1/go.mod h1:oYL5vtsvEHZGHxU7DMp32Dvx+qL+ptGn6lWaot2vCNE= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= +github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= +github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= +github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 h1:s6gZFSlWYmbqAuRjVTiNNhvNRfY2Wxp9nhfyel4rklc= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= github.com/allegro/bigcache v1.2.1 h1:hg1sY1raCwic3Vnsvje6TT7/pnZba83LeFck5NrFKSc= github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129 h1:MzBOUgng9orim59UnfUTLRjMpd09C5uEVQ6RPGeCaVI= github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129/go.mod h1:rFgpPQZYZ8vdbc+48xibu8ALc3yeyd64IhHS+PU6Yyg= +github.com/andybalholm/brotli v1.0.4/go.mod h1:fO7iG3H7G2nSZ7m0zPUDn85XEX2GTukHGRSepvi9Eig= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= +github.com/apache/arrow/go/v10 v10.0.1/go.mod h1:YvhnlEePVnBS4+0z3fhPfUy7W1Ikj0Ih0vcRo/gZ1M0= +github.com/apache/thrift v0.16.0/go.mod h1:PHK3hniurgQaNMZYaCLEqXKsYK8upmhPbmdP2FXSqgU= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-metrics v0.4.1 h1:hR91U9KYmb6bLBYLQjyM+3j+rcd/UhE+G78SFnF8gJA= +github.com/armon/go-metrics v0.4.1/go.mod h1:E6amYzXo6aW1tqzoZGT755KkbgrJsSdpwZ+3JqfkOG4= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= +github.com/armon/go-radix v1.0.0/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= +github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= +github.com/asaskevich/govalidator v0.0.0-20200907205600-7a23bdc65eef/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= +github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so= +github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= github.com/avast/retry-go v3.0.0+incompatible h1:4SOWQ7Qs+oroOTQOYnAHqelpCO0biHSxpiH9JdtuBj0= github.com/avast/retry-go/v4 v4.3.4 h1:pHLkL7jvCvP317I8Ge+Km2Yhntv3SdkJm7uekkqbKhM= github.com/aws/aws-sdk-go v1.22.1/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.23.20/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= +github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= +github.com/aws/aws-sdk-go v1.38.35/go.mod h1:hcU610XS61/+aQV88ixoOzUoG7v3b31pl2zKMmprdro= +github.com/aws/aws-sdk-go v1.44.276 h1:ywPlx9C5Yc482dUgAZ9bHpQ6onVvJvYE9FJWsNDCEy0= +github.com/aws/aws-sdk-go v1.44.276/go.mod h1:aVsgQcEevwlmQ7qHE9I3h+dtQgpqhFB+i8Phjh7fkwI= github.com/aws/constructs-go/constructs/v10 v10.1.255 h1:5hARfEmhBqHSTQf/C3QLA3sWOxO2Dfja0iA1W7ZcI7g= github.com/aws/constructs-go/constructs/v10 v10.1.255/go.mod h1:DCdBSjN04Ck2pajCacTD4RKFqSA7Utya8d62XreYctI= github.com/aws/jsii-runtime-go v1.75.0 h1:NhpUfyiL7/wsRuUekFsz8FFBCYLfPD/l61kKg9kL/a4= @@ -138,6 +653,8 @@ github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsy github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= github.com/blendle/zapdriver v1.3.1 h1:C3dydBOWYRiOk+B8X9IVZ5IOe+7cl+tGOexN4QqHfpE= github.com/blendle/zapdriver v1.3.1/go.mod h1:mdXfREi6u5MArG4j9fewC+FGnXaBR+T4Ox4J2u4eHCc= +github.com/boombuler/barcode v1.0.0/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8= +github.com/boombuler/barcode v1.0.1/go.mod h1:paBWMcWSl3LHKBqUq+rly7CNSldXjb2rDl3JlRe0mD8= github.com/btcsuite/btcd v0.22.1 h1:CnwP9LM/M9xuRrGSCGeMVs9iv09uMqwsVX7EeIpgV2c= github.com/btcsuite/btcd v0.22.1/go.mod h1:wqgTSL29+50LRkmOVknEdmt8ZojIzhuWvgu/iptuN7Y= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= @@ -158,11 +675,17 @@ github.com/bxcodec/faker v2.0.1+incompatible h1:P0KUpUw5w6WJXwrPfv35oc91i4d8nf40 github.com/bytedance/sonic v1.5.0/go.mod h1:ED5hyg4y6t3/9Ku1R6dU/4KyJ48DZ4jPhfY1O2AihPM= github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s= github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= +github.com/c2h5oh/datasize v0.0.0-20200112174442-28bbd4740fee h1:BnPxIde0gjtTnc9Er7cxvBk8DHLWhEux0SxayC8dP6I= +github.com/c2h5oh/datasize v0.0.0-20200112174442-28bbd4740fee/go.mod h1:S/7n9copUssQ56c7aAgHqftWO4LTf4xY6CGWt8Bc+3M= github.com/cdk8s-team/cdk8s-core-go/cdk8s/v2 v2.7.5 h1:rvc39Ol6z3MvaBzXkxFC6Nfsnixq/dRypushKDd7Nc0= github.com/cdk8s-team/cdk8s-core-go/cdk8s/v2 v2.7.5/go.mod h1:R/pdNYDYFQk+tuuOo7QES1kkv6OLmp5ze2XBZQIVffM= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= +github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= +github.com/cenkalti/backoff/v4 v4.2.1/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= +github.com/census-instrumentation/opencensus-proto v0.3.0/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= +github.com/census-instrumentation/opencensus-proto v0.4.1/go.mod h1:4T9NM4+4Vw91VeyqjLS6ao50K5bOcLKN6Q42XnYaRYw= github.com/cespare/cp v1.1.1 h1:nCb6ZLdB7NRaqsm91JtQTAme2SKJzXVsdPIPkyJr1MU= github.com/cespare/xxhash v1.1.0 h1:a6HrQnmkObjyL+Gs60czilIUGqrzKutQD6XZog3p+ko= github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= @@ -186,6 +709,8 @@ github.com/chzyer/readline v1.5.1/go.mod h1:Eh+b79XXUwfKfcPLepksvw2tcLE/Ct21YObk github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= github.com/chzyer/test v1.0.0 h1:p3BQDXSxOhOG0P9z6/hGnII4LGiEPOYBhs8asl/fC04= github.com/chzyer/test v1.0.0/go.mod h1:2JlltgoNkt4TW/z9V/IzDdFaMTM2JPIi26O1pF38GC8= +github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= +github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/cli/go-gh/v2 v2.0.0 h1:JAgQY7VNHletsO0Eqr+/PzF7fF5QEjhY2t2+Tev3vmk= github.com/cli/go-gh/v2 v2.0.0/go.mod h1:2/ox3Dnc8wDBT5bnTAH1aKGy6Qt1ztlFBe10EufnvoA= github.com/cli/safeexec v1.0.0 h1:0VngyaIyqACHdcMNWfo6+KdUYnqEr2Sg+bSP1pdF+dI= @@ -195,7 +720,16 @@ github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDk github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= +github.com/cncf/udpa/go v0.0.0-20210930031921-04548b0d99d4/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= +github.com/cncf/udpa/go v0.0.0-20220112060539-c52dc94e7fbe/go.mod h1:6pvJx4me5XPnfI9Z40ddWsdw2W/uZgQLFXToKeRcDiI= github.com/cncf/xds/go v0.0.0-20210312221358-fbca930ec8ed/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20210805033703-aa0b78936158/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20210922020428-25de7278fc84/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20211001041855-01bcc9b48dfe/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20211011173535-cb28da3451f1/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20220314180256-7f1daf1720fc/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20230105202645-06c439db220b/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= +github.com/cncf/xds/go v0.0.0-20230310173818-32f1caf87195/go.mod h1:eXthEFrGJvWHgFFCl3hGmgk+/aYT6PnTQLykKQRLhEs= github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4 h1:/inchEIKaYC1Akx+H+gqO04wryn5h75LSazbRlnya1k= github.com/cockroachdb/apd v1.1.0 h1:3LFP3629v+1aKXU5Q37mxmRxX/pIu1nijXydLShEq5I= github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= @@ -210,6 +744,7 @@ github.com/cockroachdb/pebble v0.0.0-20230209160836-829675f94811 h1:ytcWPaNPhNoG github.com/cockroachdb/pebble v0.0.0-20230209160836-829675f94811/go.mod h1:Nb5lgvnQ2+oGlE/EyZy4+2/CxRh9KfvCXnag1vtpxVM= github.com/cockroachdb/redact v1.1.3 h1:AKZds10rFSIj7qADf0g46UixK8NNLwWTNdCIGS5wfSQ= github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= github.com/cometbft/cometbft v0.37.2 h1:XB0yyHGT0lwmJlFmM4+rsRnczPlHoAKFX6K8Zgc2/Jc= github.com/cometbft/cometbft v0.37.2/go.mod h1:Y2MMMN//O5K4YKd8ze4r9jmk4Y7h0ajqILXbH5JQFVs= @@ -217,6 +752,8 @@ github.com/cometbft/cometbft-db v0.7.0 h1:uBjbrBx4QzU0zOEnU8KxoDl18dMNgDh+zZRUE0 github.com/cometbft/cometbft-db v0.7.0/go.mod h1:yiKJIm2WKrt6x8Cyxtq9YTEcIMPcEe4XPxhgX59Fzf0= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= +github.com/containerd/containerd v1.6.19 h1:F0qgQPrG0P2JPgwpxWxYavrVeXAG0ezUIB9Z/4FTUAU= +github.com/containerd/containerd v1.6.19/go.mod h1:HZCDMn4v/Xl2579/MvtOC2M206i+JJ6VxFWU/NetrGY= github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -227,6 +764,8 @@ github.com/coreos/go-semver v0.3.0 h1:wkHLiw0WNATZnSG7epLsujiMCgPAc9xhjJ4tgnAxmf github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= +github.com/coreos/go-systemd/v22 v22.4.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= +github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= @@ -246,6 +785,8 @@ github.com/cosmos/ibc-go/v7 v7.0.1 h1:NIBNRWjlOoFvFQu1ZlgwkaSeHO5avf4C1YQiWegt8j github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab h1:I9ialKTQo7248V827Bba4OuKPmk+FPzmTVHsLXaIJWw= github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVNihy1Y984w= github.com/cosmos/ledger-cosmos-go v0.12.1/go.mod h1:dhO6kj+Y+AHIOgAe4L9HL/6NDdyyth4q238I9yFpD2g= +github.com/cpuguy83/dockercfg v0.3.1 h1:/FpZ+JaygUR/lZP2NlFI2DVfrOEMAIKP5wWEJdoYe9E= +github.com/cpuguy83/dockercfg v0.3.1/go.mod h1:sugsbF4//dDlL/i+S+rtpIWp+5h0BHJHfjj5/jFyUJc= github.com/cpuguy83/go-md2man v1.0.10 h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk= github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= @@ -253,15 +794,15 @@ github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHH github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.11 h1:07n33Z8lZxZ2qwegKbObQohDhXDQxiMMz1NOUGYlesw= -github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= +github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= github.com/daaku/go.zipexe v1.0.0/go.mod h1:z8IiR6TsVLEYKwXAoE/I+8ys/sDkgTzSL0CLnGVd57E= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= github.com/danielkov/gin-helmet v0.0.0-20171108135313-1387e224435e h1:5jVSh2l/ho6ajWhSPNN84eHEdq3dp0T7+f6r3Tc6hsk= 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= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= +github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davidlazar/go-crypto v0.0.0-20170701192655-dcfb0a7ac018/go.mod h1:rQYf4tfk5sSwFsnDg3qYaBxSjsD9S8+59vW0dKUgme4= github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c h1:pFUpOrbxDR6AkioZ1ySsx5yxlDQZ8stG2b88gTPxgJU= github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c/go.mod h1:6UhI8N9EjYm1c2odKpFpAYeR8dsBeM7PtzQhRgxRr9U= @@ -271,6 +812,8 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= +github.com/dennwc/varint v1.0.0 h1:kGNFFSSw8ToIy3obO/kKr8U9GZYUAxQEVuix4zfDWzE= +github.com/dennwc/varint v1.0.0/go.mod h1:hnItb35rvZvJrbTALZtY/iQfDs48JKRG1RPpgziApxA= github.com/dfuse-io/logging v0.0.0-20201110202154-26697de88c79/go.mod h1:V+ED4kT/t/lKtH99JQmKIb0v9WL3VaYkJ36CfHlVECI= github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70 h1:CuJS05R9jmNlUK8GOxrEELPbfXm0EuGh/30LjkjN5vo= github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70/go.mod h1:EoK/8RFbMEteaCaz89uessDTnCWjbbcr+DXcBh4el5o= @@ -290,8 +833,13 @@ github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUn github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= +github.com/digitalocean/godo v1.97.0 h1:p9w1yCcWMZcxFSLPToNGXA96WfUVLXqoHti6GzVomL4= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= +github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= +github.com/docker/docker v24.0.2+incompatible h1:eATx+oLz9WdNVkQrr0qjQ8HvRJ4bOOxfzEo8R+dA3cg= +github.com/docker/docker v24.0.2+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= +github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docopt/docopt-go v0.0.0-20180111231733-ee0de3bc6815/go.mod h1:WwZ+bS3ebgob9U8Nd0kOddGdZWjyMGR8Wziv+TBNwSE= @@ -300,10 +848,12 @@ github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkp github.com/dustin/go-humanize v1.0.1/go.mod h1:Mu1zIs6XwVuF/gI1OepvI0qD18qycQx+mFykh5fBlto= github.com/dvsekhvalnov/jose2go v1.5.0 h1:3j8ya4Z4kMCwT5nXIKFSV84YS+HdqSSO0VsTQxaLAeM= github.com/dvsekhvalnov/jose2go v1.5.0/go.mod h1:QsHjhyTlD/lAVqn/NSbVZmSCGeDehTB/mPZadG+mhXU= +github.com/edsrzf/mmap-go v1.1.0 h1:6EUwBLQ/Mcr1EYLE4Tn1VdW1A4ckqCQWZBw8Hr0kjpQ= +github.com/edsrzf/mmap-go v1.1.0/go.mod h1:19H/e8pUPLicwkyNgOykDXkJ9F0MHE+Z52B8EIth78Q= github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= github.com/elazarl/goproxy v0.0.0-20180725130230-947c36da3153 h1:yUdfgN0XgIJw7foRItutHYUIhlcKzcSf5vDpdhQAKTc= -github.com/emicklei/go-restful/v3 v3.9.0 h1:XwGDlfxEnQZzuopoqxwSEllNcCOM9DhhFyhFIIGKwxE= -github.com/emicklei/go-restful/v3 v3.9.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= +github.com/emicklei/go-restful/v3 v3.10.1 h1:rc42Y5YTp7Am7CS630D7JmhRjq4UlEUuEKfrDac4bSQ= +github.com/emicklei/go-restful/v3 v3.10.1/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= @@ -311,7 +861,15 @@ github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5y github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/go-control-plane v0.9.9-0.20210512163311-63b5d3c536b0/go.mod h1:hliV/p42l8fGbc6Y9bQ70uLwIvmJyVE5k4iMKlh8wCQ= +github.com/envoyproxy/go-control-plane v0.9.10-0.20210907150352-cf90f659a021/go.mod h1:AFq3mo9L8Lqqiid3OhADV3RfLJnjiw63cSpi+fDTRC0= +github.com/envoyproxy/go-control-plane v0.10.2-0.20220325020618-49ff273808a1/go.mod h1:KJwIaB5Mv44NWtYuAOFCVOjcI94vtpEz2JU/D2v6IjE= +github.com/envoyproxy/go-control-plane v0.10.3/go.mod h1:fJJn/j26vwOu972OllsvAgJJM//w9BV6Fxbg2LuVd34= +github.com/envoyproxy/go-control-plane v0.11.0/go.mod h1:VnHyVMpzcLvCFt9yUz1UnCwHLhwx1WguiVDV7pTG/tI= +github.com/envoyproxy/go-control-plane v0.11.1-0.20230524094728-9239064ad72f h1:7T++XKzy4xg7PKy+bM+Sa9/oe1OC88yz2hXQUISoXfA= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= +github.com/envoyproxy/protoc-gen-validate v0.6.7/go.mod h1:dyJXwwfPK2VSqiB9Klm1J6romD608Ba7Hij42vrOBCo= +github.com/envoyproxy/protoc-gen-validate v0.9.1/go.mod h1:OKNgG7TCp5pF4d6XftA0++PMirau2/yoOwVac3AbF2w= +github.com/envoyproxy/protoc-gen-validate v0.10.0/go.mod h1:DRjgyB0I43LtJapqN6NiRwroiAU2PaFuvk/vjgh61ss= github.com/envoyproxy/protoc-gen-validate v0.10.1 h1:c0g45+xCJhdgFGw7a5QAfdS4byAbud7miNWJ1WwEVf8= github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= github.com/ethereum/go-ethereum v1.12.0 h1:bdnhLPtqETd4m3mS8BGMNvBTf36bO5bx/hxE2zljOa0= @@ -335,11 +893,15 @@ github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYF github.com/fatih/color v1.15.0 h1:kOqh6YHBtK8aywxGerMG2Eq3H6Qgoqeo13Bk2Mv/nBs= github.com/fatih/color v1.15.0/go.mod h1:0h5ZqXfHYED7Bhv2ZJamyIOUej9KtShiJESRwBDUSsw= github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= -github.com/felixge/httpsnoop v1.0.2 h1:+nS9g82KMXccJ/wp0zyRW9ZBHFETmMGtkk+2CTTrW4o= +github.com/felixge/httpsnoop v1.0.1/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/felixge/httpsnoop v1.0.3 h1:s/nj+GCswXYzN5v2DpNMuMQYe+0DDwt5WVCU6CWBdXk= +github.com/felixge/httpsnoop v1.0.3/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= github.com/fjl/memsize v0.0.0-20190710130421-bcb5799ab5e5 h1:FtmdgXiUlNeRsoNMFlKLDt+S+6hbjVMEW6RGQ7aUf7c= github.com/flowstack/go-jsonschema v0.1.1/go.mod h1:yL7fNggx1o8rm9RlgXv7hTBWxdBM0rVwpMwimd3F3N0= github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6 h1:u/UEqS66A5ckRmS4yNpjmVH56sVtS/RfclBAYocb4as= github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6/go.mod h1:1i71OnUq3iUe1ma7Lr6yG6/rjvM3emb6yoL7xLFzcVQ= +github.com/fogleman/gg v1.2.1-0.20190220221249-0403632d5b90/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= +github.com/fogleman/gg v1.3.0/go.mod h1:R/bRT+9gY/C5z7JzPU0zXsXHKM4/ayA+zqcVNZzPa1k= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= github.com/frankban/quicktest v1.14.4 h1:g2rn0vABPOOXmZUj+vbmUp0lPoXEMuhTpIluN0XL9UY= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= @@ -378,24 +940,32 @@ github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NB github.com/gin-contrib/sse v0.1.0 h1:Y/yl/+YNO8GZSjAhjMsSuLt29uWRFHdHYUb5lYOV9qE= github.com/gin-contrib/sse v0.1.0/go.mod h1:RHrZQHXnP2xjPF+u1gW/2HnVO7nvIa9PG3Gm+fLHvGI= github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= +github.com/gin-gonic/gin v1.6.3/go.mod h1:75u5sXoLsGZoRN5Sgbi1eraJ4GU3++wFwWzhwvtwp4M= github.com/gin-gonic/gin v1.9.1 h1:4idEAncQnU5cB7BeOkPtxjfCSye0AAm1R0RVIqJ+Jmg= github.com/gin-gonic/gin v1.9.1/go.mod h1:hPrL7YrpYKXt5YId3A/Tnip5kqbEAP+KLuI3SUcPTeU= github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= +github.com/go-fonts/dejavu v0.1.0/go.mod h1:4Wt4I4OU2Nq9asgDCteaAaWZOV24E+0/Pwo0gppep4g= +github.com/go-fonts/latin-modern v0.2.0/go.mod h1:rQVLdDMK+mK1xscDwsqM5J8U2jrRa3T0ecnM9pNujks= +github.com/go-fonts/liberation v0.1.1/go.mod h1:K6qoJYypsmfVjWg8KOVDQhLc8UDgIK2HYqyqAO9z7GY= +github.com/go-fonts/liberation v0.2.0/go.mod h1:K6qoJYypsmfVjWg8KOVDQhLc8UDgIK2HYqyqAO9z7GY= +github.com/go-fonts/stix v0.1.0/go.mod h1:w/c1f0ldAUlJmLBvlbkvVXLAD+tAMqobIIQpmnUIzUY= github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= +github.com/go-kit/kit v0.9.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= github.com/go-kit/kit v0.12.0 h1:e4o3o3IsBfAKQh5Qbbiqyfu97Ku7jrO/JbohvztANh4= github.com/go-kit/kit v0.12.0/go.mod h1:lHd+EkCZPIwYItmGDDRdhinkzX2A1sj+M9biaEaizzs= -github.com/go-kit/log v0.1.0/go.mod h1:zbhenjAZHb184qTLMA9ZjW7ThYL0H2mk7Q6pNt4vbaY= github.com/go-kit/log v0.2.1 h1:MRVx0/zhvdseW+Gza6N9rVzU/IVzaeE1SFI4raAhmBU= github.com/go-kit/log v0.2.1/go.mod h1:NwTd00d/i8cPZ3xOwwiv2PO5MOcx78fFErGNcVmBjv0= +github.com/go-latex/latex v0.0.0-20210118124228-b3d85cf34e07/go.mod h1:CO1AlKB2CSIqUrmQPqA0gdRIlnLEY0gK5JGjh37zN5U= +github.com/go-latex/latex v0.0.0-20210823091927-c0d11ff05a81/go.mod h1:SX0U8uGpxhq9o2S/CELCSUxEWWAuoCUcVCQWv7G2OCk= github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= -github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG1KdI/P7A= +github.com/go-logfmt/logfmt v0.5.1/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logfmt/logfmt v0.6.0 h1:wGYYu3uicYdqXVgoYbvnkrPVXkuLM1p1ifugDMEdRi4= github.com/go-logfmt/logfmt v0.6.0/go.mod h1:WYhtIu8zTZfxdn5+rREduYbwxfcBr/Vr6KEVveWlfTs= github.com/go-logr/logr v1.2.0/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= @@ -408,17 +978,52 @@ github.com/go-logr/zapr v1.2.3 h1:a9vnzlIBPQBBkeaR9IuMUfmVOrQlkoC4YfPoFkX3T7A= github.com/go-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= github.com/go-ole/go-ole v1.2.6 h1:/Fpf6oFPoeFik9ty7siob0G6Ke8QvQEuVcuChpwXzpY= github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= +github.com/go-openapi/analysis v0.21.2/go.mod h1:HZwRk4RRisyG8vx2Oe6aqeSQcoxRp47Xkp3+K6q+LdY= +github.com/go-openapi/analysis v0.21.4 h1:ZDFLvSNxpDaomuCueM0BlSXxpANBlFYiBvr+GXrvIHc= +github.com/go-openapi/analysis v0.21.4/go.mod h1:4zQ35W4neeZTqh3ol0rv/O8JBbka9QyAgQRPp9y3pfo= +github.com/go-openapi/errors v0.19.8/go.mod h1:cM//ZKUKyO06HSwqAelJ5NsEMMcpa6VpXe8DOa1Mi1M= +github.com/go-openapi/errors v0.19.9/go.mod h1:cM//ZKUKyO06HSwqAelJ5NsEMMcpa6VpXe8DOa1Mi1M= +github.com/go-openapi/errors v0.20.2/go.mod h1:cM//ZKUKyO06HSwqAelJ5NsEMMcpa6VpXe8DOa1Mi1M= +github.com/go-openapi/errors v0.20.3 h1:rz6kiC84sqNQoqrtulzaL/VERgkoCyB6WdEkc2ujzUc= +github.com/go-openapi/errors v0.20.3/go.mod h1:Z3FlZ4I8jEGxjUK+bugx3on2mIAk4txuAOhlsB1FSgk= +github.com/go-openapi/jsonpointer v0.19.3/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= +github.com/go-openapi/jsonpointer v0.19.5/go.mod h1:Pl9vOtqEWErmShwVjC8pYs9cog34VGT37dQOVbmoatg= github.com/go-openapi/jsonpointer v0.19.6 h1:eCs3fxoIi3Wh6vtgmLTOjdhSpiqphQ+DaPn38N2ZdrE= github.com/go-openapi/jsonpointer v0.19.6/go.mod h1:osyAmYz/mB/C3I+WsTTSgw1ONzaLJoLCyoi6/zppojs= +github.com/go-openapi/jsonreference v0.19.6/go.mod h1:diGHMEHg2IqXZGKxqyvWdfWU/aim5Dprw5bqpKkTvns= +github.com/go-openapi/jsonreference v0.20.0/go.mod h1:Ag74Ico3lPc+zR+qjn4XBUmXymS4zJbYVCZmcgkasdo= github.com/go-openapi/jsonreference v0.20.2 h1:3sVjiK66+uXK/6oQ8xgcRKcFgQ5KXa2KvnJRumpMGbE= github.com/go-openapi/jsonreference v0.20.2/go.mod h1:Bl1zwGIM8/wsvqjsOQLJ/SH+En5Ap4rVB5KVcIDZG2k= +github.com/go-openapi/loads v0.21.1/go.mod h1:/DtAMXXneXFjbQMGEtbamCZb+4x7eGwkvZCvBmwUG+g= +github.com/go-openapi/loads v0.21.2 h1:r2a/xFIYeZ4Qd2TnGpWDIQNcP80dIaZgf704za8enro= +github.com/go-openapi/loads v0.21.2/go.mod h1:Jq58Os6SSGz0rzh62ptiu8Z31I+OTHqmULx5e/gJbNw= +github.com/go-openapi/spec v0.20.4/go.mod h1:faYFR1CvsJZ0mNsmsphTMSoRrNV3TEDoAM7FOEWeq8I= +github.com/go-openapi/spec v0.20.6/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA= +github.com/go-openapi/spec v0.20.8 h1:ubHmXNY3FCIOinT8RNrrPfGc9t7I1qhPtdOGoG2AxRU= +github.com/go-openapi/spec v0.20.8/go.mod h1:2OpW+JddWPrpXSCIX8eOx7lZ5iyuWj3RYR6VaaBKcWA= +github.com/go-openapi/strfmt v0.21.0/go.mod h1:ZRQ409bWMj+SOgXofQAGTIo2Ebu72Gs+WaRADcS5iNg= +github.com/go-openapi/strfmt v0.21.1/go.mod h1:I/XVKeLc5+MM5oPNN7P6urMOpuLXEcNrCX/rPGuWb0k= +github.com/go-openapi/strfmt v0.21.3/go.mod h1:k+RzNO0Da+k3FrrynSNN8F7n/peCmQQqbbXjtDfvmGg= +github.com/go-openapi/strfmt v0.21.7 h1:rspiXgNWgeUzhjo1YU01do6qsahtJNByjLVbPLNHb8k= +github.com/go-openapi/strfmt v0.21.7/go.mod h1:adeGTkxE44sPyLk0JV235VQAO/ZXUr8KAzYjclFs3ew= +github.com/go-openapi/swag v0.19.5/go.mod h1:POnQmlKehdgb5mhVOsnJFsivZCEZ/vjK9gh66Z9tfKk= +github.com/go-openapi/swag v0.19.15/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= +github.com/go-openapi/swag v0.21.1/go.mod h1:QYRuS/SOXUCsnplDa677K7+DxSOj6IPNl/eQntq43wQ= github.com/go-openapi/swag v0.22.3 h1:yMBqmnQ0gyZvEb/+KzuWZOXgllrXT4SADYbvDaXHv/g= github.com/go-openapi/swag v0.22.3/go.mod h1:UzaqsxGiab7freDnrUUra0MwWfN/q7tE4j+VcZ0yl14= +github.com/go-openapi/validate v0.22.1 h1:G+c2ub6q47kfX1sOBLwIQwzBVt8qmOAARyo/9Fqs9NU= +github.com/go-openapi/validate v0.22.1/go.mod h1:rjnrwK57VJ7A8xqfpAOEKRH8yQSGUriMu5/zuPSQ1hg= +github.com/go-pdf/fpdf v0.5.0/go.mod h1:HzcnA+A23uwogo0tp9yU+l3V+KXhiESpt1PMayhOh5M= +github.com/go-pdf/fpdf v0.6.0/go.mod h1:HzcnA+A23uwogo0tp9yU+l3V+KXhiESpt1PMayhOh5M= +github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= github.com/go-playground/assert/v2 v2.2.0 h1:JvknZsQTYeFEAhQwI4qEt9cyV5ONwRHC+lYKSsYSR8s= +github.com/go-playground/locales v0.13.0/go.mod h1:taPMhCMXrRLJO55olJkUXHZBHCxTMfnGwq/HNwmWNS8= github.com/go-playground/locales v0.14.1 h1:EWaQ/wswjilfKLTECiXz7Rh+3BjFhfDFKv/oXslEjJA= github.com/go-playground/locales v0.14.1/go.mod h1:hxrqLVvrK65+Rwrd5Fc6F2O76J/NuW9t0sjnWqG1slY= +github.com/go-playground/universal-translator v0.17.0/go.mod h1:UkSxE5sNxxRwHyU+Scu5vgOQjsIJAF8j9muTVoKLVtA= github.com/go-playground/universal-translator v0.18.1 h1:Bcnm0ZwsGyWbCzImXv+pAJnYK9S473LQFuzCbDbfSFY= github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91TpwSH2VMlDf28Uj24BCp08ZFTUY= +github.com/go-playground/validator/v10 v10.2.0/go.mod h1:uOYAAleCW8F/7oMFd6aG0GOhaH6EGOAJShg8Id5JGkI= github.com/go-playground/validator/v10 v10.14.0 h1:vgvQWe3XCz3gIeFDm/HnTIbj6UGmg/+t63MyGU2n5js= github.com/go-playground/validator/v10 v10.14.0/go.mod h1:9iXMNT7sEkjXb0I+enO7QXmzG6QCsPWY4zveKFVRSyU= github.com/go-resty/resty/v2 v2.7.0 h1:me+K9p3uhSmXtrBZ4k9jcEAfJmuC8IivWHwaLZwPrFY= @@ -434,9 +1039,38 @@ github.com/go-test/deep v1.0.4 h1:u2CU3YKy9I2pmu9pX0eq50wCgjfGIt539SqR7FbHiho= github.com/go-test/deep v1.0.4/go.mod h1:wGDj63lr65AM2AQyKZd/NYHGb0R+1RLqB8NKt3aSFNA= github.com/go-webauthn/revoke v0.1.9 h1:gSJ1ckA9VaKA2GN4Ukp+kiGTk1/EXtaDb1YE8RknbS0= github.com/go-webauthn/webauthn v0.8.2 h1:8KLIbpldjz9KVGHfqEgJNbkhd7bbRXhNw4QWFJE15oA= +github.com/go-zookeeper/zk v1.0.3 h1:7M2kwOsc//9VeeFiPtf+uSJlVpU66x9Ba5+8XK7/TDg= +github.com/gobuffalo/attrs v0.0.0-20190224210810-a9411de4debd/go.mod h1:4duuawTqi2wkkpB4ePgWMaai6/Kc6WEz83bhFwpHzj0= +github.com/gobuffalo/depgen v0.0.0-20190329151759-d478694a28d3/go.mod h1:3STtPUQYuzV0gBVOY3vy6CfMm/ljR4pABfrTeHNLHUY= +github.com/gobuffalo/depgen v0.1.0/go.mod h1:+ifsuy7fhi15RWncXQQKjWS9JPkdah5sZvtHc2RXGlg= +github.com/gobuffalo/envy v1.6.15/go.mod h1:n7DRkBerg/aorDM8kbduw5dN3oXGswK5liaSCx4T5NI= +github.com/gobuffalo/envy v1.7.0/go.mod h1:n7DRkBerg/aorDM8kbduw5dN3oXGswK5liaSCx4T5NI= +github.com/gobuffalo/flect v0.1.0/go.mod h1:d2ehjJqGOH/Kjqcoz+F7jHTBbmDb38yXA598Hb50EGs= +github.com/gobuffalo/flect v0.1.1/go.mod h1:8JCgGVbRjJhVgD6399mQr4fx5rRfGKVzFjbj6RE/9UI= +github.com/gobuffalo/flect v0.1.3/go.mod h1:8JCgGVbRjJhVgD6399mQr4fx5rRfGKVzFjbj6RE/9UI= +github.com/gobuffalo/genny v0.0.0-20190329151137-27723ad26ef9/go.mod h1:rWs4Z12d1Zbf19rlsn0nurr75KqhYp52EAGGxTbBhNk= +github.com/gobuffalo/genny v0.0.0-20190403191548-3ca520ef0d9e/go.mod h1:80lIj3kVJWwOrXWWMRzzdhW3DsrdjILVil/SFKBzF28= +github.com/gobuffalo/genny v0.1.0/go.mod h1:XidbUqzak3lHdS//TPu2OgiFB+51Ur5f7CSnXZ/JDvo= +github.com/gobuffalo/genny v0.1.1/go.mod h1:5TExbEyY48pfunL4QSXxlDOmdsD44RRq4mVZ0Ex28Xk= +github.com/gobuffalo/gitgen v0.0.0-20190315122116-cc086187d211/go.mod h1:vEHJk/E9DmhejeLeNt7UVvlSGv3ziL+djtTr3yyzcOw= +github.com/gobuffalo/gogen v0.0.0-20190315121717-8f38393713f5/go.mod h1:V9QVDIxsgKNZs6L2IYiGR8datgMhB577vzTDqypH360= +github.com/gobuffalo/gogen v0.1.0/go.mod h1:8NTelM5qd8RZ15VjQTFkAW6qOMx5wBbW4dSCS3BY8gg= +github.com/gobuffalo/gogen v0.1.1/go.mod h1:y8iBtmHmGc4qa3urIyo1shvOD8JftTtfcKi+71xfDNE= +github.com/gobuffalo/logger v0.0.0-20190315122211-86e12af44bc2/go.mod h1:QdxcLw541hSGtBnhUc4gaNIXRjiDppFGaDqzbrBd3v8= +github.com/gobuffalo/mapi v1.0.1/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc= +github.com/gobuffalo/mapi v1.0.2/go.mod h1:4VAGh89y6rVOvm5A8fKFxYG+wIW6LO1FMTG9hnKStFc= +github.com/gobuffalo/packd v0.0.0-20190315124812-a385830c7fc0/go.mod h1:M2Juc+hhDXf/PnmBANFCqx4DM3wRbgDvnVWeG2RIxq4= +github.com/gobuffalo/packd v0.1.0/go.mod h1:M2Juc+hhDXf/PnmBANFCqx4DM3wRbgDvnVWeG2RIxq4= +github.com/gobuffalo/packr/v2 v2.0.9/go.mod h1:emmyGweYTm6Kdper+iywB6YK5YzuKchGtJQZ0Odn4pQ= +github.com/gobuffalo/packr/v2 v2.2.0/go.mod h1:CaAwI0GPIAv+5wKLtv8Afwl+Cm78K/I/VCm/3ptBN+0= +github.com/gobuffalo/syncx v0.0.0-20190224160051-33c29581e754/go.mod h1:HhnNqWY95UYwwW3uSASeV7vtgYkT2t16hJgV3AEPUpw= +github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee h1:s+21KNqlpePfkah2I+gwHF8xmJWRjooY+5248k6m4A0= github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= +github.com/gobwas/pool v0.2.0 h1:QEmUOlnSjWtnpRGHF3SauEiOsy82Cup83Vf2LcMlnc8= github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= +github.com/gobwas/ws v1.0.2 h1:CoAavW/wd/kulfZmSIBt6p24n4j7tHgNVCjsfHVNUbo= github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= +github.com/goccy/go-json v0.9.11/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU= github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= @@ -447,13 +1081,19 @@ github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14j github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= github.com/gofrs/uuid v4.3.1+incompatible h1:0/KbAdpx3UXAx1kEOWHJeOkpbgRFGHVgv+CFIY7dBJI= github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= +github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.4.1 h1:1Yx4Myt7BxzvUr5ldGSbwYiZG6t9wGBZ+8/fX3Wvtq0= github.com/gogo/googleapis v1.4.1/go.mod h1:2lpHqI5OcWCtVElxXnPt+s8oJvMpySlOyM6xDCrzib4= +github.com/gogo/status v1.0.3/go.mod h1:SavQ51ycCLnc7dGyJxp8YAmudx8xqiVrRf+6IXRsugc= github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= +github.com/gogo/status v1.1.1 h1:DuHXlSFHNKqTQ+/ACf5Vs6r4X/dH2EgIzR9Vr+H65kg= +github.com/gogo/status v1.1.1/go.mod h1:jpG3dM5QPcqu19Hg8lkUhBFBa3TcLs1DG7+2Jqci7oU= github.com/golang-jwt/jwt v3.2.2+incompatible h1:IfV12K8xAKAnZqdXVzCZ+TOjboZ2keLg81eXfW3O+oY= github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= +github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= +github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= github.com/golang/glog v1.1.0 h1:/d3pCKDPWNnvIWe0vVUpNP32qc8U3PDVxySP/y360qE= github.com/golang/glog v1.1.0/go.mod h1:pfYeQZ3JWZoXTV5sFc986z3HTpwQs9At6P4ImfuP3NQ= github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= @@ -469,7 +1109,9 @@ github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4= +github.com/golang/mock v1.5.0/go.mod h1:CWnOUgYIOo4TcNZ0wHX3YZCqsaM1I1Jvs6v3mP3KVu8= github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc= +github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.0/go.mod h1:Qd/q+1AKNOZr9uGQzbzCmRO6sUih6GTPZv6a1/R87v0= github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= @@ -486,10 +1128,12 @@ github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QD github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/snappy v0.0.0-20180518054509-2e65f85255db/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.3/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= @@ -499,6 +1143,7 @@ github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Z github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.1.2 h1:xf4v41cLI2Z6FxbKm+8Bu+m8ifhj15JuZ9sa0jZCMUU= github.com/google/btree v1.1.2/go.mod h1:qOPhT0dTNdNzV6Z/lhRX0YXUafgPLFUh+gZMl761Gm4= +github.com/google/flatbuffers v2.0.8+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/gnostic v0.6.9 h1:ZK/5VhkoX835RikCHpSUJV9a+S3e1zLh59YnyWeBW+0= github.com/google/gnostic v0.6.9/go.mod h1:Nm8234We1lq6iB9OmlgNv3nH91XLLVZHCDayfA3xq+E= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -514,6 +1159,7 @@ github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.6/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.7/go.mod h1:n+brtR0CgQNWTVd5ZUFpTBC8YFBDLK/h/bpaJ8/DtOE= +github.com/google/go-cmp v0.5.8/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= @@ -531,6 +1177,8 @@ github.com/google/gopacket v1.1.19/go.mod h1:iJ8V8n6KS+z2U1A8pUwu8bW5SyEMkXJB8Yo github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= +github.com/google/martian/v3 v3.2.1/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= +github.com/google/martian/v3 v3.3.2/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= @@ -541,7 +1189,12 @@ github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hf github.com/google/pprof v0.0.0-20201023163331-3e6fc7fc9c4c/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201203190320-1bf35d6f28c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20201218002935-b9804c9f04c2/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210122040257-d980be63207e/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210226084205-cbba55b83ad5/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20210407192527-94a9f03dee38/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210601050228-01bbb1931b22/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210609004039-a478d1d731e9/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= +github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLew5upagYY7GY0pfYCcupk39gWOCRROcvE= github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 h1:hR7/MlvK23p6+lIw9SN1TigNLn9ZnF3W4SYRKq2gAHs= github.com/google/pprof v0.0.0-20230602150820-91b7bce49751/go.mod h1:Jh3hGz2jkYak8qXPD19ryItVnUgpgeqzdkY/D0EaeuA= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= @@ -552,14 +1205,31 @@ github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I= github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99a87aa/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= +github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= +github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= +github.com/googleapis/enterprise-certificate-proxy v0.2.1/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= +github.com/googleapis/enterprise-certificate-proxy v0.2.3/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= +github.com/googleapis/gax-go/v2 v2.1.0/go.mod h1:Q3nei7sK6ybPYH7twZdmQpAd1MKb7pfu6SK+H1/DsU0= +github.com/googleapis/gax-go/v2 v2.1.1/go.mod h1:hddJymUZASv3XPyGkUpKj8pPO47Rmb0eJc8R6ouapiM= +github.com/googleapis/gax-go/v2 v2.2.0/go.mod h1:as02EH8zWkzwUoLbBaFeQ+arQaj/OthfcblKl4IGNaM= +github.com/googleapis/gax-go/v2 v2.3.0/go.mod h1:b8LNqSzNabLiUpXKkY7HAR5jr6bIT99EXz9pXxye9YM= +github.com/googleapis/gax-go/v2 v2.4.0/go.mod h1:XOTVJ59hdnfJLIP/dh8n5CGryZR2LxK9wbMD5+iXC6c= +github.com/googleapis/gax-go/v2 v2.5.1/go.mod h1:h6B0KMMFNtI2ddbGJn3T3ZbwkeT6yqEF02fYlzkUCyo= +github.com/googleapis/gax-go/v2 v2.6.0/go.mod h1:1mjbznJAPHFpesgE5ucqfYEscaz5kMdcIDwU/6+DDoY= +github.com/googleapis/gax-go/v2 v2.7.0/go.mod h1:TEop28CZZQ2y+c0VxMUmu1lV+fQx57QpBWsYpwqHJx8= +github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= +github.com/gophercloud/gophercloud v1.2.0 h1:1oXyj4g54KBg/kFtCdMM6jtxSzeIyg8wv4z1HoGPp1E= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/context v1.1.1 h1:AWwleXJkX/nhcU9bZSnZoi3h/qGYqQAGhq6zZe/aQW8= github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= github.com/gorilla/handlers v1.5.1 h1:9lRY6j8DEeeBT10CvO9hGW0gmky0BprnvDI5vfhUHH4= +github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= +github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/rpc v1.2.0/go.mod h1:V4h9r+4sF5HnzqbwIez0fKSpANP0zlYd3qR7p36jkTQ= github.com/gorilla/securecookie v1.1.1 h1:miw7JPhV+b/lAHSXz4qd/nN9jRiAFV5FwjeKyCS8BvQ= github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4= @@ -569,12 +1239,26 @@ github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/ad github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/gosimple/slug v1.13.1 h1:bQ+kpX9Qa6tHRaK+fZR0A0M2Kd7Pa5eHPPsb1JpHD+Q= +github.com/gosimple/slug v1.13.1/go.mod h1:UiRaFH+GEilHstLUmcBgWcI42viBN7mAb818JrYOeFQ= +github.com/gosimple/unidecode v1.0.1 h1:hZzFTMMqSswvf0LBJZCZgThIZrpDHFXux9KeGmn6T/o= +github.com/gosimple/unidecode v1.0.1/go.mod h1:CP0Cr1Y1kogOtx0bJblKzsVWrqYaqfNOnHzpgWw4Awc= +github.com/grafana/dskit v0.0.0-20230201083518-528d8a7d52f2 h1:IOks+FXJ6iO/pfbaVEf4efNw+YzYBYNCkCabyrbkFTM= +github.com/grafana/dskit v0.0.0-20230201083518-528d8a7d52f2/go.mod h1:zj+5BNZAVmQafV583uLTAOzRr963KPdEm4d6NPmtbwg= +github.com/grafana/loki v1.6.2-0.20230403212622-90888a0cc737 h1:o45+fZAYRtTjx+9fFml9LZxsCmLX65l39eWDgvdkIr0= +github.com/grafana/loki v1.6.2-0.20230403212622-90888a0cc737/go.mod h1:kxNnWCr4EMobhndjy7a2Qpm7jkLPnJW2ariYvY77hLE= +github.com/grafana/loki/pkg/push v0.0.0-20230127102416-571f88bc5765 h1:VXitROTlmZtLzvokNe8ZbUKpmwldM4Hy1zdNRO32jKU= +github.com/grafana/loki/pkg/push v0.0.0-20230127102416-571f88bc5765/go.mod h1:DhJMrd2QInI/1CNtTN43BZuTmkccdizW1jZ+F6aHkhY= +github.com/grafana/regexp v0.0.0-20221122212121-6b5c0a4cb7fd h1:PpuIBO5P3e9hpqBD0O/HjhShYuM6XE0i/lbE6J94kww= +github.com/grafana/regexp v0.0.0-20221122212121-6b5c0a4cb7fd/go.mod h1:M5qHK+eWfAv8VR/265dIuEpL3fNfeC21tXXp9itM24A= github.com/graph-gophers/dataloader v5.0.0+incompatible h1:R+yjsbrNq1Mo3aPG+Z/EKYrXrXXUNJHOgbRt+U6jOug= github.com/graph-gophers/graphql-go v1.3.0 h1:Eb9x/q6MFpCLz7jBCiP/WTxjSDrYLR1QY41SORZyNJ0= github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79 h1:+ngKgrYPPJrOjhax5N+uePQ0Fh1Z7PheYoUI/0nzkPA= github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= +github.com/grpc-ecosystem/go-grpc-middleware v1.1.0/go.mod h1:f5nM7jw/oeRSadq3xCzHAvxcr8HZnzsqU6ILg/0NiiE= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= +github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.0-rc.0 h1:mdLirNAJBxnGgyB6pjZLcs6ue/6eZGBui6gXspfq4ks= github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.0-rc.0/go.mod h1:kdXbOySqcQeTxiqglW7aahTmWZy3Pgi6SYL36yvKeyA= github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.0.0-rc.3 h1:o95KDiV/b1xdkumY5YbLR0/n2+wBxUpgf3HgfKgTyLI= @@ -583,6 +1267,9 @@ github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgf github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= github.com/grpc-ecosystem/grpc-gateway v1.16.0 h1:gmcG1KaJ57LophUzW0Hy8NmPhnMZb4M0+kPpLofRdBo= github.com/grpc-ecosystem/grpc-gateway v1.16.0/go.mod h1:BDjrQk3hbvj6Nolgz8mAMFbcEtjT1g+wF4CSlocrBnw= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.7.0/go.mod h1:hgWBS7lorOAVIJEQMi4ZsPv9hVvWI6+ch50m39Pf2Ks= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.11.3/go.mod h1:o//XUCC/F+yRGJoPO/VU0GSB0f8Nhgmxx0VIRUvaC0w= +github.com/grpc-ecosystem/grpc-opentracing v0.0.0-20180507213350-8e809c8a8645/go.mod h1:6iZfnjpejD4L/4DwD7NryNaJyCQdzwWwH2MWhCA90Kw= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c h1:6rhixN/i8ZofjG1Y75iExal34USq5p+wiN1tpie8IrU= github.com/gsterjov/go-libsecret v0.0.0-20161001094733-a6f4afe4910c/go.mod h1:NMPJylDgVpX0MLRlPy15sqSwOFv/U1GZ2m21JhFfek0= github.com/gtank/merlin v0.1.1-0.20191105220539-8318aed1a79f/go.mod h1:T86dnYJhcGOh5BjZFCJWTDeTK7XW8uE+E21Cy/bIQ+s= @@ -593,27 +1280,45 @@ github.com/gtank/ristretto255 v0.1.2/go.mod h1:Ph5OpO6c7xKUGROZfWVLiJf9icMDwUeIv github.com/gxed/hashland/keccakpg v0.0.1/go.mod h1:kRzw3HkwxFU1mpmPP8v1WyQzwdGfmKFJ6tItnhQ67kU= github.com/gxed/hashland/murmur3 v0.0.1/go.mod h1:KjXop02n4/ckmZSnY2+HKcLud/tcmvhST0bie/0lS48= github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q= +github.com/hashicorp/consul/api v1.21.0 h1:WMR2JiyuaQWRAMFaOGiYfY4Q4HRpyYRe/oYQofjyduM= +github.com/hashicorp/consul/api v1.21.0/go.mod h1:f8zVJwBcLdr1IQnfdfszjUM0xzp31Zl3bpws3pL9uFM= github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= +github.com/hashicorp/consul/sdk v0.13.1 h1:EygWVWWMczTzXGpO93awkHFzfUka6hLYJ0qhETd+6lY= +github.com/hashicorp/cronexpr v1.1.1 h1:NJZDd87hGXjoZBdvyCF9mX4DCq5Wy7+A/w+A7q0wn6c= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I= github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/go-bexpr v0.1.10 h1:9kuI5PFotCboP3dkDYFr/wi0gg0QVbSNz5oFRpxn4uE= +github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= -github.com/hashicorp/go-hclog v1.4.0 h1:ctuWFGrhFha8BnnzxqeRGidlEcQkDyL5u8J8t5eA11I= -github.com/hashicorp/go-hclog v1.4.0/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= +github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= +github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= +github.com/hashicorp/go-hclog v1.5.0 h1:bI2ocEMgcVlz55Oj1xZNBsVi900c7II+fWDyV9o+13c= +github.com/hashicorp/go-hclog v1.5.0/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc= +github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= +github.com/hashicorp/go-msgpack v0.5.5 h1:i9R9JSrqIz0QVLz3sz+i3YJdT7TTSLcfLLzJi9aZTuI= +github.com/hashicorp/go-msgpack v0.5.5/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA= github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+lD48awMYo= github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM= +github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs= +github.com/hashicorp/go-retryablehttp v0.7.2 h1:AcYqCvkpalPnPF2pn0KamgwamS42TqUDDYFRKq/RAd0= github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= +github.com/hashicorp/go-rootcerts v1.0.2 h1:jzhAVGtqPKbwpyCPELlgNWhE1znq+qwJtW5Oi2viEzc= +github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8= github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= +github.com/hashicorp/go-sockaddr v1.0.2 h1:ztczhD1jLxIRjVejw8gFomI1BQZOe2WoVOu0SyteCQc= +github.com/hashicorp/go-sockaddr v1.0.2/go.mod h1:rB4wwRAUzs07qva3c5SdrY/NEtAUjGlgmH/UkBUC97A= github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go-uuid v1.0.3 h1:2gKiV6YVmrJ1i2CKKa9obLvRieoRGviZFL26PcT/Co8= github.com/hashicorp/go-version v1.2.0/go.mod h1:fltr4n8CU8Ke44wwGCBoEymUuxUHl09ZGVZPK5anwXA= +github.com/hashicorp/go-version v1.6.0 h1:feTTfFNnjP967rlCxM/I9g701jU+RN74YKx2mOkIeek= github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= @@ -625,13 +1330,20 @@ github.com/hashicorp/hcl v1.0.0 h1:0Anlzjpi4vEasTeNFn2mLJgTSwt0+6sfsiTG8qcWGx4= github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= +github.com/hashicorp/mdns v1.0.4/go.mod h1:mtBihi+LeNXGtG8L9dX59gAEa12BDtBQSp4v/YAJqrc= github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= +github.com/hashicorp/memberlist v0.5.0 h1:EtYPN8DpAURiapus508I4n9CzHs2W+8NZGbmmR/prTM= +github.com/hashicorp/memberlist v0.5.0/go.mod h1:yvyXLpo0QaGE59Y7hDTsTzDD25JYBZ4mHgHUZ8lrOI0= +github.com/hashicorp/nomad/api v0.0.0-20230308192510-48e7d70fcd4b h1:EkuSTU8c/63q4LMayj8ilgg/4I5PXDFVcnqKfs9qcwI= github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= +github.com/hashicorp/serf v0.10.1 h1:Z1H2J60yRKvfDYAOZLd2MU0ND4AH/WDz7xYHDWQsIPY= +github.com/hashicorp/serf v0.10.1/go.mod h1:yL2t6BqATOLGc5HF7qbFkTfXoPIY0WZdWHfEvMqbG+4= github.com/hashicorp/yamux v0.0.0-20200609203250-aecfd211c9ce h1:7UnVY3T/ZnHUrfviiAgIUjg2PXxsQfs5bphsG8F7Keo= github.com/hashicorp/yamux v0.0.0-20200609203250-aecfd211c9ce/go.mod h1:+NfK9FKeTrX5uv1uIXGdwYDTeHna2qgaIlx54MXqjAM= github.com/hdevalence/ed25519consensus v0.1.0 h1:jtBwzzcHuTmFrQN6xQZn6CQEO/V9f7HsjsjeEZ6auqU= github.com/hdevalence/ed25519consensus v0.1.0/go.mod h1:w3BHWjwJbFU29IRHL1Iqkw3sus+7FctEyM4RqDxYNzo= github.com/henvic/httpretty v0.0.6 h1:JdzGzKZBajBfnvlMALXXMVQWxWMF/ofTy8C3/OSUTxs= +github.com/hetznercloud/hcloud-go v1.41.0 h1:KJGFRRc68QiVu4PrEP5BmCQVveCP2CM26UGQUKGpIUs= github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= github.com/holiman/uint256 v1.2.2 h1:TXKcSGc2WaxPD2+bmzAsVthL4+pEN0YwXcL5qED83vk= @@ -643,6 +1355,7 @@ github.com/huin/goupnp v1.0.3 h1:N8No57ls+MnjlB+JPiCVSOyy/ot7MJTqlo7rn+NYSqQ= github.com/huin/goupnp v1.0.3/go.mod h1:ZxNlw5WqJj6wSsRK5+YfflQGXYfccj5VgQsMNixHM7Y= github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3iZrZfqZzyLl6l7F3c6L1oWn7OICBi6o= github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= +github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.15 h1:M8XP7IuFNsqUx6VPK2P9OSmsYsI/YFaGil0uD21V3dM= @@ -652,6 +1365,7 @@ github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANyt github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +github.com/ionos-cloud/sdk-go/v6 v6.1.4 h1:BJHhFA8Q1SZC7VOXqKKr2BV2ysQ2/4hlk1e4hZte7GY= github.com/ipfs/go-cid v0.0.1/go.mod h1:GHWU/WuQdMPmIosc4Yn1bcCT7dSeX4lBafM7iqUPQvM= github.com/ipfs/go-cid v0.0.2/go.mod h1:GHWU/WuQdMPmIosc4Yn1bcCT7dSeX4lBafM7iqUPQvM= github.com/ipfs/go-cid v0.0.3/go.mod h1:GHWU/WuQdMPmIosc4Yn1bcCT7dSeX4lBafM7iqUPQvM= @@ -767,10 +1481,15 @@ github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgf github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= +github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= +github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= +github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= +github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= github.com/jmoiron/sqlx v1.3.5 h1:vFFPA71p1o5gAeqtEAwLU4dnX2napprKtHr7PYIcN3g= github.com/jmoiron/sqlx v1.3.5/go.mod h1:nRVWtLre0KfCLJvgxzCsLVMogSvQ1zNJtpYr2Ccp0mQ= +github.com/joho/godotenv v1.3.0/go.mod h1:7hK45KPybAkOC6peb+G5yklZfMxEjkZhHbwpqxOKXbg= github.com/joho/godotenv v1.4.0 h1:3l4+N6zfMWnkbPEXKng2o2/MR5mSwTrBih4ZEkkz1lg= github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= @@ -780,37 +1499,52 @@ github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.9/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= +github.com/json-iterator/go v1.1.10/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= +github.com/json-iterator/go v1.1.11/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= +github.com/julienschmidt/httprouter v1.3.0 h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U= +github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= +github.com/jung-kurt/gofpdf v1.0.0/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= +github.com/jung-kurt/gofpdf v1.0.3-0.20190309125859-24315acbbda5/go.mod h1:7Id9E/uU8ce6rXgefFLlgrJj/GYY22cpxn+r32jIOes= github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= github.com/kami-zh/go-capturer v0.0.0-20171211120116-e492ea43421d/go.mod h1:P2viExyCEfeWGU259JnaQ34Inuec4R38JCyBx2edgD0= +github.com/karrick/godirwalk v1.8.0/go.mod h1:H5KPZjojv4lE+QYImBI8xVtrBRgYrIVsaRPx4tDPEn4= +github.com/karrick/godirwalk v1.10.3/go.mod h1:RoGL9dQei4vP9ilrpETWE8CLOZ1kiN0LhBygSwrAsHA= github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8= github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE= github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2R1rmoTE= github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= +github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8= github.com/kelseyhightower/envconfig v1.4.0 h1:Im6hONhd3pLkfDFsbRgu68RDNkGF1r3dvMUtDTo2cv8= github.com/kelseyhightower/envconfig v1.4.0/go.mod h1:cccZRl6mQpaq41TPp5QxidR+Sa3axMbJDNb//FQX6Gg= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= +github.com/klauspost/asmfmt v1.3.2/go.mod h1:AG8TuvYojzulgDAMCnYn50l/5QV3Bs/tp6j0HLHbNSE= github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= +github.com/klauspost/compress v1.10.3/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.11.4/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= +github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= github.com/klauspost/compress v1.16.3 h1:XuJt9zzcnaz6a16/OU53ZjWp/v7/42WcR5t2a0PcNQY= github.com/klauspost/compress v1.16.3/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= +github.com/klauspost/cpuid/v2 v2.0.4/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.2.4 h1:acbojRNwl3o09bUq+yDCtZFc1aiwaAAxtcn8YkZXnvk= github.com/klauspost/cpuid/v2 v2.2.4/go.mod h1:RVVoqg1df56z8g3pUjL/3lE5UfnlrJX8tyFgg4nqhuY= +github.com/kolo/xmlrpc v0.0.0-20220921171641-a4b6fa1dd06b h1:udzkj9S/zlT5X367kqJis0QP7YMxobob6zhzq6Yre00= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= +github.com/konsorten/go-windows-terminal-sequences v1.0.3/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/koron/go-ssdp v0.0.0-20191105050749-2e1c40ed0b5d/go.mod h1:5Ky9EC2xfoUKUor0Hjgi2BJhCSXJfMOFlmyYrVKGQMk= github.com/koron/go-ssdp v0.0.2 h1:fL3wAoyT6hXHQlORyXUW4Q23kkQpJRgEAYcZB5BR71o= github.com/koron/go-ssdp v0.0.2/go.mod h1:XoLfkAiA2KeZsYh4DbHxD7h3nR2AZNqVQOa+LJuqPYs= @@ -832,6 +1566,7 @@ github.com/labstack/echo/v4 v4.5.0/go.mod h1:czIriw4a0C1dFun+ObrXp7ok03xON0N1awS github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/leanovate/gopter v0.2.10-0.20210127095200-9abe2343507a h1:dHCfT5W7gghzPtfsW488uPmEOm85wewI+ypUwibyTdU= github.com/leanovate/gopter v0.2.10-0.20210127095200-9abe2343507a/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= +github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= @@ -1047,20 +1782,29 @@ github.com/libp2p/go-yamux/v2 v2.0.0 h1:vSGhAy5u6iHBq11ZDcyHH4Blcf9xlBhT4WQDoOE9 github.com/libp2p/go-yamux/v2 v2.0.0/go.mod h1:NVWira5+sVUIU6tu1JWvaRn1dRnG+cawOJiflsAM+7U= github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de h1:9TO3cAIGXtEhnIaL+V+BEER86oLrvS+kWobKpbJuye0= github.com/liggitt/tabwriter v0.0.0-20181228230101-89fcab3d43de/go.mod h1:zAbeS9B/r2mtpb6U+EI2rYA5OAXxsYw6wTamcNW+zcE= +github.com/linode/linodego v1.14.1 h1:uGxQyy0BidoEpLGdvfi4cPgEW+0YUFsEGrLEhcTfjNc= github.com/logrusorgru/aurora v2.0.3+incompatible h1:tOpm7WcpBTn4fjmVfgpQq0EfczGlG91VSDkswnjF5A8= github.com/logrusorgru/aurora v2.0.3+incompatible/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4= github.com/lucasb-eyer/go-colorful v1.2.0 h1:1nnpGOrhyZZuNyfu1QjKiUICQ74+3FNCN69Aj6K7nkY= github.com/lufia/plan9stats v0.0.0-20211012122336-39d0f177ccd0/go.mod h1:zJYVVT2jmtg6P3p1VtQj7WsuWi/y4VnjVBn7F8KPB3I= +github.com/lyft/protoc-gen-star v0.6.0/go.mod h1:TGAoBVkt8w7MPG72TrKIu85MIdXwDuzJYeZuUPFPNwA= +github.com/lyft/protoc-gen-star v0.6.1/go.mod h1:TGAoBVkt8w7MPG72TrKIu85MIdXwDuzJYeZuUPFPNwA= +github.com/lyft/protoc-gen-star/v2 v2.0.1/go.mod h1:RcCdONR2ScXaYnQC5tUzxzlpA3WVYF7/opLeUgcQs/o= github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/magiconair/properties v1.8.7 h1:IeQXZAiQcpL9mgcAe1Nu6cX9LLw6ExEHKjN0VQdvPDY= github.com/magiconair/properties v1.8.7/go.mod h1:Dhd985XPs7jluiymwWYZ0G4Z61jb3vdS329zhj2hYo0= github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= +github.com/mailru/easyjson v0.7.6/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= github.com/manifoldco/promptui v0.9.0 h1:3V4HzJk1TtXW1MTZMP7mdlwbBpIinw3HztaIlYthEiA= github.com/manifoldco/promptui v0.9.0/go.mod h1:ka04sppxSGFAtxX0qhlYQjISsg9mR4GWtQEhdbn6Pgg= github.com/manyminds/api2go v0.0.0-20171030193247-e7b693844a6f h1:tVvGiZQFjOXP+9YyGqSA6jE55x1XVxmoPYudncxrZ8U= +github.com/markbates/oncer v0.0.0-20181203154359-bf2de49a0be2/go.mod h1:Ld9puTsIW75CHf65OeIOkyKbteujpZVXDpWK6YGZbxE= +github.com/markbates/safe v1.0.1/go.mod h1:nAqgmRi7cY2nqMc92/bSEeQA+R4OheNU2T1kNSCBdG0= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= @@ -1088,6 +1832,7 @@ github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/mattn/go-sqlite3 v1.14.6/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= +github.com/mattn/go-sqlite3 v1.14.14/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= github.com/mattn/go-sqlite3 v2.0.3+incompatible h1:gXHsfypPkaMZrKbD5209QV9jbUTJKjyR5WD3HYQSd+U= github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= @@ -1098,39 +1843,54 @@ github.com/mgutz/ansi v0.0.0-20170206155736-9520e82c474b/go.mod h1:01TrycV0kFyex github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/miekg/dns v1.1.12/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= +github.com/miekg/dns v1.1.26/go.mod h1:bPDLeHnStXmXAq1m/Ch/hvfNHr14JKNPMBo3VZKjuso= github.com/miekg/dns v1.1.28/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7xM= github.com/miekg/dns v1.1.31/go.mod h1:KNUDUusw/aVsxyTYZM1oqvCicbwhgbNgztCETuNZ7xM= +github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI= +github.com/miekg/dns v1.1.54 h1:5jon9mWcb0sFJGpnI99tOMhCPyJ+RPVz5b63MQG0VWI= +github.com/miekg/dns v1.1.54/go.mod h1:uInx36IzPl7FYnDcMeVWxj9byh7DutNykX4G9Sj60FY= github.com/mimoo/StrobeGo v0.0.0-20181016162300-f8f6d4d2b643/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0 h1:QRUSJEgZn2Snx0EmT/QLXibWjSUDjKWvXIT19NBVp94= github.com/mimoo/StrobeGo v0.0.0-20210601165009-122bf33a46e0/go.mod h1:43+3pMjjKimDBf5Kr4ZFNGbLql1zKkbImw+fZbw3geM= +github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8/go.mod h1:mC1jAcsrzbxHt8iiaC+zU4b1ylILSosueou12R++wfY= github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 h1:lYpkrQH5ajf0OXOcUbGjvZxxijuBwbbmlSxLiuofa+g= github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1/go.mod h1:pD8RvIylQ358TN4wwqatJ8rNavkEINozVn9DtGI3dfQ= +github.com/minio/c2goasm v0.0.0-20190812172519-36a3d3bbc4f3/go.mod h1:RagcQ7I8IeTMnF8JTXieKnO4Z6JCsikNEzj0DwauVzE= github.com/minio/sha256-simd v0.0.0-20190131020904-2d45a736cd16/go.mod h1:2FMWW+8GMoPweT6+pI63m9YE3Lmw4J71hV56Chs1E/U= github.com/minio/sha256-simd v0.0.0-20190328051042-05b4dd3047e5/go.mod h1:2FMWW+8GMoPweT6+pI63m9YE3Lmw4J71hV56Chs1E/U= github.com/minio/sha256-simd v0.1.0/go.mod h1:2FMWW+8GMoPweT6+pI63m9YE3Lmw4J71hV56Chs1E/U= github.com/minio/sha256-simd v0.1.1-0.20190913151208-6de447530771/go.mod h1:B5e1o+1/KgNmWrSQK08Y6Z1Vb5pwIktudl0J58iy0KM= -github.com/minio/sha256-simd v0.1.1 h1:5QHSlgo3nt5yKOJrC7W8w7X+NFl8cMPZm96iu8kKUJU= github.com/minio/sha256-simd v0.1.1/go.mod h1:B5e1o+1/KgNmWrSQK08Y6Z1Vb5pwIktudl0J58iy0KM= +github.com/minio/sha256-simd v1.0.0 h1:v1ta+49hkWZyvaKwrQB8elexRqm6Y0aMLjCNsrYxo6g= +github.com/minio/sha256-simd v1.0.0/go.mod h1:OuYzVNI5vcoYIAmbIvHPl3N3jUzVedXbKy5RFepssQM= github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= +github.com/mitchellh/cli v1.1.0/go.mod h1:xcISNoH86gajksDmfB23e/pu+B+GeFRMYmoHXxx3xhI= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-homedir v1.1.0 h1:lukF9ziXFxDFPkA1vsr5zpc1XuPDn/wFntq5mG+4E0Y= github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= github.com/mitchellh/go-testing-interface v1.14.1 h1:jrgshOhYAUVNMAJiKbEu7EqAwgJJ2JqpQmpLJOu07cU= github.com/mitchellh/go-testing-interface v1.14.1/go.mod h1:gfgS7OtZj6MA4U1UrDRp04twqAjfvlZyCfX3sDjEym8= +github.com/mitchellh/go-wordwrap v1.0.0/go.mod h1:ZXFpozHsX6DPmq2I0TCekCxypsnAUbP2oI0UX1GXzOo= github.com/mitchellh/go-wordwrap v1.0.1 h1:TLuKupo69TCn6TQSyGxwI1EblZZEsQ0vMlAFQflz0v0= github.com/mitchellh/go-wordwrap v1.0.1/go.mod h1:R62XHJLzvMFRBbcrT7m7WgmE1eOyTSsCt+hzestvNj0= github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +github.com/mitchellh/mapstructure v1.3.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= +github.com/moby/patternmatcher v0.5.0 h1:YCZgJOeULcxLw1Q+sVR636pmS7sPEn1Qo2iAN6M7DBo= +github.com/moby/patternmatcher v0.5.0/go.mod h1:hDPoyOpDY7OrrMDLaYoY3hf52gNCR/YOUYxkhApJIxc= github.com/moby/spdystream v0.2.0 h1:cjW1zVyyoiM0T7b6UoySUFqzXMoqRckQtXwGPiBhOM8= github.com/moby/spdystream v0.2.0/go.mod h1:f7i0iNDQJ059oMTcWxx8MA/zKFIuD/lY+0GqbN2Wy8c= -github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae h1:O4SWKdcHVCvYqyDV+9CJA1fcDN2L11Bule0iFy3YlAI= -github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae/go.mod h1:E2VnQOmVuvZB6UYnnDB0qG5Nq/1tD9acaOpo6xmt0Kw= +github.com/moby/sys/sequential v0.5.0 h1:OPvI35Lzn9K04PBbCLW0g4LcFAJgHsvXsRyewg5lXtc= +github.com/moby/sys/sequential v0.5.0/go.mod h1:tH2cOOs5V9MlPiXcQzRC+eEyab644PWKGRYaaV5ZZlo= +github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= +github.com/moby/term v0.5.0/go.mod h1:8FzsFHVUBGZdbDsJw/ot+X+d5HLUbvklYLJ9uGfcI3Y= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -1140,6 +1900,9 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 h1:n6/2gBQ3RWajuToeY6ZtZTIKv2v7ThUy5KKusIT0yc0= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= +github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc= +github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= +github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= github.com/mostynb/zstdpool-freelist v0.0.0-20201229113212-927304c0c3b1 h1:mPMvm6X6tf4w8y7j9YIt6V9jfWhL6QlbEc7CCmeQlWk= github.com/mostynb/zstdpool-freelist v0.0.0-20201229113212-927304c0c3b1/go.mod h1:ye2e/VUEtE2BHE+G/QcKkcLQVAEJoYRFj5VUOQatCRE= github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= @@ -1210,6 +1973,7 @@ github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f h1:KUppIJq7/+SVif2QVs3tOP0zanoHgBEVAwHxUSIzRqU= +github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= github.com/nats-io/jwt v0.3.0/go.mod h1:fRYCDE99xlTsqUzISS1Bi75UBJ6ljOJQOAAu5VglpSg= github.com/nats-io/nats.go v1.9.1/go.mod h1:ZjDU1L/7fJ09jvUSRVBR2e7+RnLiiIQyqyzEE/Zbp4w= github.com/nats-io/nkeys v0.1.0/go.mod h1:xpnFELMwJABBLVhffcfd1MZx6VsNRFpEugbxziKVo7w= @@ -1222,6 +1986,7 @@ github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= github.com/oklog/run v1.1.0 h1:GEenZ1cK0+q0+wsJew9qUg/DyD8k3JzYsZAi5gYi2mA= github.com/oklog/run v1.1.0/go.mod h1:sVPdnTZT1zYwAJeCMu2Th4T21pA3FPOQRfWjQlk7DVU= +github.com/oklog/ulid v1.3.1 h1:EGfNDEx6MqHz8B3uNV6QAib1UR2Lm97sHi3ocA6ESJ4= github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= @@ -1247,16 +2012,29 @@ github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9 github.com/onsi/gomega v1.27.8 h1:gegWiwZjBsf2DgiSbf5hpokZ98JVDMcWkUiigk6/KXc= github.com/onsi/gomega v1.27.8/go.mod h1:2J8vzI/s+2shY9XHRApDkdgPo1TKT7P2u6fXeJKFnNQ= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= +github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.0-rc3 h1:fzg1mXZFj8YdPeNkRXMg+zb88BFV0Ys52cJydRwBkb8= +github.com/opencontainers/image-spec v1.1.0-rc3/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= github.com/opencontainers/runc v1.1.7 h1:y2EZDS8sNng4Ksf0GUYNhKbTShZJPJg1FiXJNH/uoCk= +github.com/opencontainers/runc v1.1.7/go.mod h1:CbUumNnWCuTGFukNXahoo/RFBZvDAgRh/smNYNOhA50= +github.com/opentracing-contrib/go-grpc v0.0.0-20180928155321-4b5a12d3ff02/go.mod h1:JNdpVEzCpXBgIiv4ds+TzhN1hrtxq6ClLrTlT9OQRSc= +github.com/opentracing-contrib/go-grpc v0.0.0-20210225150812-73cb765af46e h1:4cPxUYdgaGzZIT5/j0IfqOrrXmq6bG8AwvwisMXpdrg= +github.com/opentracing-contrib/go-grpc v0.0.0-20210225150812-73cb765af46e/go.mod h1:DYR5Eij8rJl8h7gblRrOZ8g0kW1umSpKqYIBTgeDtLo= +github.com/opentracing-contrib/go-stdlib v0.0.0-20190519235532-cf7a6c988dc9/go.mod h1:PLldrQSroqzH70Xl+1DQcGnefIbqsKR7UDaiux3zV+w= +github.com/opentracing-contrib/go-stdlib v1.0.0 h1:TBS7YuVotp8myLon4Pv7BtCBzOTo1DeZCld0Z63mW2w= +github.com/opentracing-contrib/go-stdlib v1.0.0/go.mod h1:qtI1ogk+2JhVPIXVc6q+NHziSmy2W5GbdQZFUHADCBU= github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= +github.com/ovh/go-ovh v1.3.0 h1:mvZaddk4E4kLcXhzb+cxBsMPYp2pHqiQpWYkInsuZPQ= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= +github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= +github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/patrickmn/go-cache v2.1.0+incompatible h1:HRMgzkcYKYpi3C8ajMPV8OFXaaRUnok+kx1WdO15EQc= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= +github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE= github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pelletier/go-toml/v2 v2.0.8 h1:0ctb6s9mE31h0/lhu+J6OPmVeDxJn+kYnJc2jZR9tGQ= @@ -1266,6 +2044,10 @@ github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= +github.com/phpdave11/gofpdf v1.4.2/go.mod h1:zpO6xFn9yxo3YLyMvW8HcKWVdbNqgIfOOp2dXMnm1mY= +github.com/phpdave11/gofpdi v1.0.12/go.mod h1:vBmVV0Do6hSBHC8uKUQ71JGW+ZGQq74llk/7bXwjDoI= +github.com/phpdave11/gofpdi v1.0.13/go.mod h1:vBmVV0Do6hSBHC8uKUQ71JGW+ZGQq74llk/7bXwjDoI= +github.com/pierrec/lz4/v4 v4.1.15/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= @@ -1273,32 +2055,67 @@ github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINE github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pkg/sftp v1.10.1/go.mod h1:lYOWFsE0bwd1+KfKJaKeuokY15vzFx25BLbzYYoAxZI= github.com/pkg/sftp v1.13.1/go.mod h1:3HaPG6Dq1ILlpPZRO0HVMrsydcdLt6HRDccSgb87qRg= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= +github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= github.com/pressly/goose/v3 v3.5.3 h1:lIQIIXVbdO2RuQtJBS1e7MZjKEk0demVWt6i0YPiOrg= +github.com/prometheus/alertmanager v0.25.0 h1:vbXKUR6PYRiZPRIKfmXaG+dmCKG52RtPL4Btl8hQGvg= +github.com/prometheus/alertmanager v0.25.0/go.mod h1:MEZ3rFVHqKZsw7IcNS/m4AWZeXThmJhumpiWR4eHU/w= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= +github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= +github.com/prometheus/client_golang v1.4.0/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= +github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= +github.com/prometheus/client_golang v1.11.0/go.mod h1:Z6t4BnS23TR94PD6BsDNk8yVqroYurpAkEiz0P2BEV0= +github.com/prometheus/client_golang v1.12.1/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= +github.com/prometheus/client_golang v1.13.0/go.mod h1:vTeo+zgvILHsnnj/39Ou/1fPN5nJFOEMgftOUOmlvYQ= +github.com/prometheus/client_golang v1.14.0/go.mod h1:8vpkKitgIVNcqrRBWh1C4TIUQgYNtG/XQE4E/Zae36Y= +github.com/prometheus/client_golang v1.15.1/go.mod h1:e9yaBhRPU2pPNsZwE+JdQl0KEt1N9XgF6zxWmaC0xOk= github.com/prometheus/client_golang v1.16.0 h1:yk/hx9hDbrGHovbci4BY+pRMfSuuat626eFsHb7tmT8= github.com/prometheus/client_golang v1.16.0/go.mod h1:Zsulrv/L9oM40tJ7T815tM89lFEugiJ9HzIqaAx4LKc= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= +github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= +github.com/prometheus/client_model v0.3.0/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= github.com/prometheus/client_model v0.4.0 h1:5lQXD3cAg1OXBf4Wq03gTrXHeaV0TQvGfUooCfx1yqY= github.com/prometheus/client_model v0.4.0/go.mod h1:oMQmHW1/JoDwqLtg57MGgP/Fb1CJEYF2imWWhWtMkYU= github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= +github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= +github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= +github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= +github.com/prometheus/common v0.26.0/go.mod h1:M7rCNAaPfAosfx8veZJCuw84e35h3Cfd9VFqTh1DIvc= +github.com/prometheus/common v0.29.0/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= +github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= +github.com/prometheus/common v0.37.0/go.mod h1:phzohg0JFMnBEFGxTDbfu3QyL5GI8gTQJFhYO5B3mfA= +github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc= github.com/prometheus/common v0.44.0 h1:+5BrQJwiBB9xsMygAB3TNvpQKOwlkc25LbISbrdOOfY= github.com/prometheus/common v0.44.0/go.mod h1:ofAIvZbQ1e/nugmZGz4/qCb9Ap1VoSTIO7x0VV9VvuY= +github.com/prometheus/common/sigv4 v0.1.0 h1:qoVebwtwwEhS85Czm2dSROY5fTo2PAPEVdDeppTwGX4= +github.com/prometheus/common/sigv4 v0.1.0/go.mod h1:2Jkxxk9yYvCkE5G1sQT7GuEXm57JrvHu9k5YwTjsNtI= +github.com/prometheus/exporter-toolkit v0.8.2/go.mod h1:00shzmJL7KxcsabLWcONwpyNEuWhREOnFqZW7vadFS0= +github.com/prometheus/exporter-toolkit v0.10.0 h1:yOAzZTi4M22ZzVxD+fhy1URTuNRj/36uQJJ5S8IPza8= +github.com/prometheus/exporter-toolkit v0.10.0/go.mod h1:+sVFzuvV5JDyw+Ih6p3zFxZNVnKQa3x5qPmDSiPu4ZY= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= +github.com/prometheus/procfs v0.0.2/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= +github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= +github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= +github.com/prometheus/procfs v0.6.0/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= +github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= +github.com/prometheus/procfs v0.8.0/go.mod h1:z7EfXMXOkbkqb9IINtpCn86r/to3BnA0uaxHdg830/4= +github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY= github.com/prometheus/procfs v0.11.0 h1:5EAgkfkMl659uZPbe9AS2N68a7Cc1TJbPEuGzFuRbyk= github.com/prometheus/procfs v0.11.0/go.mod h1:nwNm2aOCAYw8uTR/9bWRREkZFxAUcWzPHWJq+XBB/FM= -github.com/prometheus/prometheus v0.45.0 h1:O/uG+Nw4kNxx/jDPxmjsSDd+9Ohql6E7ZSY1x5x/0KI= +github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2 h1:i5hmbBzR+VeL5pPl1ZncsJ1bpg3SO66bwkE1msJBsMA= +github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2/go.mod h1:Mm42Acga98xgA+u5yTaC3ki3i0rJEJWFpbdHN7q2trk= github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= github.com/pyroscope-io/client v0.7.1 h1:yFRhj3vbgjBxehvxQmedmUWJQ4CAfCHhn+itPsuWsHw= github.com/pyroscope-io/client v0.7.1/go.mod h1:4h21iOU4pUOq0prKyDlvYRL+SCKsBc5wKiEtV+rJGqU= @@ -1307,6 +2124,7 @@ github.com/pyroscope-io/godeltaprof v0.1.0/go.mod h1:psMITXp90+8pFenXkKIpNhrfmI9 github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/regen-network/protobuf v1.3.3-alpha.regen.1 h1:OHEc+q5iIAXpqiqFKeLpu5NwTIkVXUs48vFMwzqpqY4= github.com/regen-network/protobuf v1.3.3-alpha.regen.1/go.mod h1:2DjTFR1HhMQhiWC5sZ4OhQ3+NtdbZ6oBDKQwq5Ou+FI= +github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.4.4 h1:8TfxU8dW6PdqD27gjM8MVNuicgxIjxpm4K7x4jp8sis= github.com/rivo/uniseg v0.4.4/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= @@ -1314,6 +2132,8 @@ github.com/robfig/cron/v3 v3.0.1 h1:WdRxkvbJztn8LMz/QEvLN5sBU+xKpSqwwUO1Pjr4qDs= github.com/robfig/cron/v3 v3.0.1/go.mod h1:eQICP3HwyT7UooqI/z+Ov+PtYAWygg1TEWWzGIFLtro= github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= +github.com/rogpeppe/go-internal v1.1.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= +github.com/rogpeppe/go-internal v1.2.2/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= @@ -1333,15 +2153,21 @@ github.com/russross/blackfriday v1.6.0/go.mod h1:ti0ldHuxg49ri4ksnFxlkCfN+hvslNl github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/ruudk/golang-pdf417 v0.0.0-20181029194003-1af4ab5afa58/go.mod h1:6lfFZQK844Gfx8o5WFuvpxWRwnSoipWe/p622j1v06w= +github.com/ruudk/golang-pdf417 v0.0.0-20201230142125-a7e3863a1245/go.mod h1:pQAZKsJ8yyVxGRWYNEm9oFB8ieLgKFnamEyDmSA0BRk= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/sasha-s/go-deadlock v0.3.1 h1:sqv7fDNShgjcaxkO0JNcOAlr8B9+cV5Ey/OB71efZx0= github.com/sasha-s/go-deadlock v0.3.1/go.mod h1:F73l+cr82YSh10GxyRI6qZiCgK64VaZjwesgfQ1/iLM= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= +github.com/scaleway/scaleway-sdk-go v1.0.0-beta.14 h1:yFl3jyaSVLNYXlnNYM5z2pagEk1dYQhfr1p20T1NyKY= github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtmuhtR2uUrrJOpYzYRvbcPAid+g= github.com/scylladb/go-reflectx v1.0.1 h1:b917wZM7189pZdlND9PbIJ6NQxfDPfBvUaQ7cjj1iZQ= github.com/scylladb/go-reflectx v1.0.1/go.mod h1:rWnOfDIRWBGN0miMLIcoPt/Dhi2doCMZqwMCJ3KupFc= +github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529 h1:nn5Wsu0esKSJiIVhscUtVbo7ada43DJhG55ua/hjS5I= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= +github.com/sercand/kuberesolver/v5 v5.1.0 h1:YLqreB1vUFbZHSidcqI5ChMp+RIRmop0brQOeUFWiRw= +github.com/sercand/kuberesolver/v5 v5.1.0/go.mod h1:Fs1KbKhVRnB2aDWN12NjKCB+RgYMWZJ294T3BtmVCpQ= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= github.com/sergi/go-diff v1.2.0 h1:XU+rvMAioB0UC3q1MFrIQy4Vo5/4VsRDQQXHsEya6xQ= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= @@ -1354,8 +2180,10 @@ github.com/shopspring/decimal v1.3.1 h1:2Usl1nmF/WZucqkFZhnfFYxxxu8LG21F6nPQBE5g github.com/shopspring/decimal v1.3.1/go.mod h1:DKyhrW/HYNuLGql+MJL6WCR6knT2jwCFRcu2hWCYk4o= github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= +github.com/sirupsen/logrus v1.4.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= +github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/slack-go/slack v0.12.2 h1:x3OppyMyGIbbiyFhsBmpf9pwkUzMhthJMRNmNlA4LaQ= @@ -1369,8 +2197,8 @@ github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d h1:4jSCp6i/p/EIaAkYQDxPK8nXDuv0fBXzKIcVYzetCoI= -github.com/smartcontractkit/chainlink-testing-framework v1.14.0 h1:XJSE2xnXCij1Pdnykg1YUeFwfuaDQmpiMHQmygf2xYk= -github.com/smartcontractkit/chainlink-testing-framework v1.14.0/go.mod h1:Wio/JS9GuEAWOI0k46sUs4+/wLMZnZKz9IwCpdV/miY= +github.com/smartcontractkit/chainlink-testing-framework v1.14.1-0.20230731095810-a70b0af9a909 h1:mpObCUxX5PKy/Xm5qGLmhftRrk54G1uuxx1nqar1nBM= +github.com/smartcontractkit/chainlink-testing-framework v1.14.1-0.20230731095810-a70b0af9a909/go.mod h1:QVZ+0AZchJQttnpaYxgINEKxlFgmi4HxtptZLOc9YHg= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= @@ -1381,6 +2209,8 @@ github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a h1:/ZJnNxcdJ75yDJHnKMjd3G9oZ6lcQRvFUdmiR2DPAgQ= +github.com/smartcontractkit/wasp v0.2.7 h1:9SZ1grPvoNDpxCcQgQi917ifXrjt5JhV/J978HkD0d4= +github.com/smartcontractkit/wasp v0.2.7/go.mod h1:gS2oenc6VEGfewgeqDpVFOSrCZIZX10rVl1PAo+vsxc= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= @@ -1394,11 +2224,15 @@ github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasO github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= +github.com/spf13/afero v1.3.3/go.mod h1:5KUK8ByomD5Ti5Artl0RtHeI5pTF7MIDuXL3yY520V4= +github.com/spf13/afero v1.6.0/go.mod h1:Ai8FlHk4v/PARR026UzYexafAt9roJ7LcLMAmO6Z93I= +github.com/spf13/afero v1.9.2/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= github.com/spf13/afero v1.9.3 h1:41FoI0fD7OR7mGcKE/aOiLkGreyf8ifIOQmJANWogMk= github.com/spf13/afero v1.9.3/go.mod h1:iUV7ddyEEZPO5gA3zD4fJt6iStLlL+Lg4m2cihcDf8Y= github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cast v1.5.1 h1:R+kOtfhWQE6TVQzY+4D7wJLBgkdVasCEFxSUBYBYIlA= github.com/spf13/cast v1.5.1/go.mod h1:b9PdjNptOpzXr7Rq1q9gJML/2cdGQAo69NKzQ10KN48= +github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= github.com/spf13/cobra v1.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI= github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= @@ -1453,6 +2287,8 @@ github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 h1:3SNcvBmEPE1YlB github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125/go.mod h1:M8agBzgqHIhgj7wEn9/0hJUZcrvt9VY+Ln+S1I5Mha0= github.com/test-go/testify v1.1.4 h1:Tf9lntrKUMHiXQ07qBScBTSA0dhYQlu83hswqelv1iE= github.com/test-go/testify v1.1.4/go.mod h1:rH7cfJo/47vWGdi4GPj16x3/t1xGOj2YxzmNQzk2ghU= +github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a h1:ssL/ZDrMCIu+MRv3+3zlPKnETExI52cngtbBHv4VQ70= +github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a/go.mod h1:IgGARdvGrTYx/tWIwda1GEaV8ivfm3iHqYaTnlHkh1U= github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a h1:YuO+afVc3eqrjiCUizNCxI53bl/BnPiVwXqLzqYTqgU= github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a/go.mod h1:/sfW47zCZp9FrtGcWyo1VjbgDaodxX9ovZvgLb/MxaA= github.com/thlib/go-timezone-local v0.0.0-20210907160436-ef149e42d28e h1:BuzhfgfWQbX0dWzYzT1zsORLnHRv3bcRcsaUk0VmXA8= @@ -1462,6 +2298,7 @@ github.com/tidwall/gjson v1.14.4 h1:uo0p8EbA09J7RQaflQ1aBRffTR7xedD2bcIVSYxLnkM= github.com/tidwall/gjson v1.14.4/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= github.com/tidwall/match v1.1.1 h1:+Ho715JplO36QYgwN9PGYNhgZvoUSc9X2c80KVTi+GA= github.com/tidwall/match v1.1.1/go.mod h1:eRSPERbgtNPcGhD8UCthc6PmLEQXEWd3PRB5JTxsfmM= +github.com/tidwall/pretty v1.0.0/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= github.com/tidwall/pretty v1.2.0 h1:RWIZEg2iJ8/g6fDDYzMpobmaoGh5OLl4AXtGUGPcqCs= github.com/tidwall/pretty v1.2.0/go.mod h1:ITEVvHYasfjBbM0u2Pg8T2nJnzm8xPwvNhhsoaGGjNU= github.com/tklauser/go-sysconf v0.3.11 h1:89WgdJhk5SNwJfu+GKyYveZ4IaJ7xAkecBo+KdJV0CM= @@ -1470,10 +2307,17 @@ github.com/tklauser/numcpus v0.6.0/go.mod h1:FEZLMke0lhOUG6w2JadTzp0a+Nl8PF/GFkQ github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= +github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= github.com/tyler-smith/go-bip39 v1.1.0/go.mod h1:gUYDtqQw1JS3ZJ8UWVcGTGqqr6YIN3CWg+kkNaLt55U= +github.com/uber/jaeger-client-go v2.28.0+incompatible/go.mod h1:WVhlPFC8FDjOFMMWRy2pZqQJSXxYSwNYOkTr/Z6d3Kk= +github.com/uber/jaeger-client-go v2.30.0+incompatible h1:D6wyKGCecFaSRUpo8lCVbaOOb6ThwMmTEbhRwtKR97o= +github.com/uber/jaeger-client-go v2.30.0+incompatible/go.mod h1:WVhlPFC8FDjOFMMWRy2pZqQJSXxYSwNYOkTr/Z6d3Kk= +github.com/uber/jaeger-lib v2.2.0+incompatible/go.mod h1:ComeNDZlWwrWnDv8aPp0Ba6+uUTzImX/AauajbLI56U= +github.com/uber/jaeger-lib v2.4.1+incompatible h1:td4jdvLcExb4cBISKIpHuGoVXh+dVKhn2Um6rjCsSsg= +github.com/uber/jaeger-lib v2.4.1+incompatible/go.mod h1:ComeNDZlWwrWnDv8aPp0Ba6+uUTzImX/AauajbLI56U= github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= @@ -1496,6 +2340,11 @@ github.com/valyala/fastjson v1.4.1/go.mod h1:nV6MsjxL2IMJQUoHDIrjEI7oLyeqK6aBD7E github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= +github.com/vultr/govultr/v2 v2.17.2 h1:gej/rwr91Puc/tgh+j33p/BLR16UrIPnSr+AIwYWZQs= +github.com/weaveworks/common v0.0.0-20221201103051-7c2720a9024d h1:9Z/HiqeGN+LOnmotAMpFEQjuXZ4AGAVFG0rC1laP5Go= +github.com/weaveworks/common v0.0.0-20221201103051-7c2720a9024d/go.mod h1:Fnq3+U51tMkPRMC6Wr7zKGUeFFYX4YjNrNK50iU0fcE= +github.com/weaveworks/promrus v1.2.0 h1:jOLf6pe6/vss4qGHjXmGz4oDJQA+AOCqEL3FvvZGz7M= +github.com/weaveworks/promrus v1.2.0/go.mod h1:SaE82+OJ91yqjrE1rsvBWVzNZKcHYFtMUyS1+Ogs/KA= github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1 h1:EKhdznlJHPMoKr0XTrX+IlJs1LH3lyx2nfr1dOlZ79k= github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1/go.mod h1:8UvriyWtv5Q5EOgjHaSseUEdkQfvwFv1I/In/O2M9gc= github.com/whyrusleeping/go-logging v0.0.0-20170515211332-0457bb6b88fc/go.mod h1:bopw91TMyo8J3tvftk8xmU2kPmlrt4nScJQZU2hE5EM= @@ -1507,15 +2356,22 @@ github.com/whyrusleeping/multiaddr-filter v0.0.0-20160516205228-e903e4adabd7/go. github.com/x-cray/logrus-prefixed-formatter v0.5.2/go.mod h1:2duySbKsL6M18s5GU7VPsoEPHyzalCE06qoARUCeBBE= github.com/x448/float16 v0.8.4 h1:qLwI1I70+NjRFUR3zs1JPUCgaCXSh3SW62uAKT1mSBM= github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= +github.com/xdg-go/pbkdf2 v1.0.0/go.mod h1:jrpuAogTd400dnrH08LKmI/xc1MbPOebTwRqcT5RDeI= +github.com/xdg-go/scram v1.0.2/go.mod h1:1WAq6h33pAW+iRreB34OORO2Nf7qel3VV3fjBj+hCSs= +github.com/xdg-go/scram v1.1.1/go.mod h1:RaEWvsqvNKKvBPvcKeFjrG2cJqOkHTiyTpzz23ni57g= +github.com/xdg-go/stringprep v1.0.2/go.mod h1:8F9zXuvzgwmyT5DUm4GUfZGDdT3W+LCvS6+da4O5kxM= +github.com/xdg-go/stringprep v1.0.3/go.mod h1:W3f5j4i+9rC0kuIEJL0ky1VpHXQU3ocBgklLGvcBnW8= github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= +github.com/xhit/go-str2duration v1.2.0/go.mod h1:3cPSlfZlUHVlneIVfePFWcJZsuwf+P1v2SRTV4cUmp4= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xlab/treeprint v1.1.0 h1:G/1DjNkPpfZCFt9CSh6b5/nY4VimlbHF3Rh4obvtzDk= github.com/xlab/treeprint v1.1.0/go.mod h1:gj5Gd3gPdKtR1ikdDK6fnFLdmIS0X30kTTuNd/WEJu0= github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= +github.com/youmark/pkcs8 v0.0.0-20181117223130-1be2e3e5546d/go.mod h1:rHwXgn7JulP+udvsHwJoVG1YGAP6VLg4y9I5dyZdqmA= github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= @@ -1524,11 +2380,14 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= +github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13 h1:fVcFKWvrslecOb/tg+Cc05dkeYx540o0FuFt3nUVDoE= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= +github.com/zeebo/assert v1.3.0/go.mod h1:Pq9JiuJQpG8JLJdtkwrJESF0Foym2/D9XMU5ciN/wJ0= +github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA= github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= github.com/zondax/hid v0.9.1 h1:gQe66rtmyZ8VeGFcOpbuH3r7erYtNEAezCAYu8LdkJo= github.com/zondax/hid v0.9.1/go.mod h1:l5wttcP0jwtdLjqjMMWFVEE7d1zO0jvSPA9OPZxWpEM= @@ -1547,6 +2406,17 @@ go.dedis.ch/protobuf v1.0.11/go.mod h1:97QR256dnkimeNdfmURz0wAMNVbd1VmLXhG1CrTYr go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= go.etcd.io/bbolt v1.3.7 h1:j+zJOnnEjF/kyHlDDgGnVL/AIqIJPq8UoB2GSNfkUfQ= go.etcd.io/bbolt v1.3.7/go.mod h1:N9Mkw9X8x5fupy0IKsmuqVtoGDyxsaDlbk4Rd05IAQw= +go.etcd.io/etcd/api/v3 v3.5.7 h1:sbcmosSVesNrWOJ58ZQFitHMdncusIifYcrBfwrlJSY= +go.etcd.io/etcd/api/v3 v3.5.7/go.mod h1:9qew1gCdDDLu+VwmeG+iFpL+QlpHTo7iubavdVDgCAA= +go.etcd.io/etcd/client/pkg/v3 v3.5.7 h1:y3kf5Gbp4e4q7egZdn5T7W9TSHUvkClN6u+Rq9mEOmg= +go.etcd.io/etcd/client/pkg/v3 v3.5.7/go.mod h1:o0Abi1MK86iad3YrWhgUsbGx1pmTS+hrORWc2CamuhY= +go.etcd.io/etcd/client/v3 v3.5.7 h1:u/OhpiuCgYY8awOHlhIhmGIGpxfBU/GZBUP3m/3/Iz4= +go.etcd.io/etcd/client/v3 v3.5.7/go.mod h1:sOWmj9DZUMyAngS7QQwCyAXXAL6WhgTOPLNS/NabQgw= +go.mongodb.org/mongo-driver v1.7.3/go.mod h1:NqaYOwnXWr5Pm7AOpO5QFxKJ503nbMse/R79oO62zWg= +go.mongodb.org/mongo-driver v1.7.5/go.mod h1:VXEWRZ6URJIkUq2SCAyapmhH0ZLRBP+FT4xhp5Zvxng= +go.mongodb.org/mongo-driver v1.10.0/go.mod h1:wsihk0Kdgv8Kqu1Anit4sfK+22vSFbUrAVEYRhCXrA8= +go.mongodb.org/mongo-driver v1.11.3 h1:Ql6K6qYHEzB6xvu4+AU0BoRoqf9vFPcc4o7MUIdPW8Y= +go.mongodb.org/mongo-driver v1.11.3/go.mod h1:PTSz5yu21bkT/wXpkS7WR5f0ddqw5quethTUn9WM+2g= go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.22.1/go.mod h1:Ap50jQcDJrx6rB6VgeeFPtuPIf3wMRvRfrfYDO6+BmA= @@ -1554,10 +2424,13 @@ go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk= +go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.42.0 h1:ZOLJc06r4CB42laIXg/7udr0pbZyuAihN10A/XuiQRY= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.42.0/go.mod h1:5z+/ZWJQKXa9YT34fQNx5K8Hd1EoIhvtUygUQPqEOgQ= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.42.0 h1:pginetY7+onl4qN1vl0xW/V/v6OBZ0vVdH+esuJgvmM= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.42.0/go.mod h1:XiYsayHc36K3EByOO6nbAXnAWbrUxdjUROCEeeROOH8= go.opentelemetry.io/otel v1.16.0 h1:Z7GVAX/UkAXPKsy94IU+i6thsQS4nb7LviLpnaNeW8s= go.opentelemetry.io/otel v1.16.0/go.mod h1:vl0h9NUa1D5s1nv3A5vZOYWn8av4K8Ml6JDeHrT/bx4= go.opentelemetry.io/otel/metric v1.16.0 h1:RbrpwVG1Hfv85LgnZ7+txXioPDoh6EdbZHo26Q3hqOo= @@ -1567,11 +2440,14 @@ go.opentelemetry.io/otel/sdk v1.16.0/go.mod h1:tMsIuKXuuIWPBAOrH+eHtvhTL+SntFtXF go.opentelemetry.io/otel/trace v1.16.0 h1:8JRpaObFoW0pxuVPapkgH8UhHQj+bJW8jJsCZEu5MQs= go.opentelemetry.io/otel/trace v1.16.0/go.mod h1:Yt9vYq1SdNz3xdjZZK7wcXv1qv2pwLkqr2QVwea0ef0= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= +go.opentelemetry.io/proto/otlp v0.15.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= +go.opentelemetry.io/proto/otlp v0.19.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= go.starlark.net v0.0.0-20220817180228-f738f5508c12 h1:xOBJXWGEDwU5xSDxH6macxO11Us0AH2fTa9rmsbbF7g= go.starlark.net v0.0.0-20220817180228-f738f5508c12/go.mod h1:VZcBMdr3cT3PnBoWunTabuSEXwVAH+ZJ5zxfs3AdASk= go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= +go.uber.org/atomic v1.5.1/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/atomic v1.6.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ= go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc= go.uber.org/atomic v1.11.0 h1:ZvwS0R+56ePWxUNi+Atn9dWONBPp/AUETXlHW0DxSjE= @@ -1579,6 +2455,7 @@ go.uber.org/atomic v1.11.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0 go.uber.org/goleak v1.0.0/go.mod h1:8a7PlsEVH3e/a/GLqe5IIrQx6GzcnRmZEufDUTk4A7A= go.uber.org/goleak v1.1.11/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ= go.uber.org/goleak v1.2.1 h1:NBol2c7O1ZokfZ0LEU9K6Whx/KnwvepVetCUhtKja4A= +go.uber.org/goleak v1.2.1/go.mod h1:qlT2yGI9QafXHhZZLxlSuNsMw3FFLxBr+tBRlmO1xH4= go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4= go.uber.org/multierr v1.5.0/go.mod h1:FeouvMocqHpRaaGuG9EjoKcStLC43Zu/fmqdUMPcKYU= @@ -1608,6 +2485,7 @@ golang.org/x/crypto v0.0.0-20190211182817-74369b46fc67/go.mod h1:6SG95UA2DQfeDnf golang.org/x/crypto v0.0.0-20190225124518-7f87c0fbb88b/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190411191339-88737f569e3a/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= +golang.org/x/crypto v0.0.0-20190422162423-af44ce270edf/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= golang.org/x/crypto v0.0.0-20190426145343-a29dc8fdc734/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190513172903-22d7a77e9e5f/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -1616,11 +2494,13 @@ golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20190618222545-ea8f1a30c443/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20190923035154-9ee001bba392/go.mod h1:/lpIB1dKB+9EgE3H3cr1v9wB50oz8l4C4h62xy7jSTY= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191206172530-e9b2fee46413/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20191227163750-53104e6ec876/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200115085410-6d4e4cb37c7d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/crypto v0.0.0-20200302210943-78000ba7a073/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200423211502-4bdfaf469ed5/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200602180216-279210d13fed/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -1635,23 +2515,41 @@ golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= +golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= +golang.org/x/crypto v0.0.0-20221012134737-56aed061732a/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58= golang.org/x/crypto v0.11.0 h1:6Ewdq3tDic1mg5xRO4milcWCfMVQhI4NkqWWvqejpuA= golang.org/x/crypto v0.11.0/go.mod h1:xgJhtzW8F9jGdVFWZESrid1U1bjeNy4zgy5cRr/CIio= +golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190125153040-c74c464bbbf2/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= +golang.org/x/exp v0.0.0-20191002040644-a1355ae1e2c3/go.mod h1:NOZ3BPKG0ec/BKJQgnvsSFpcKLM5xXVWnvZS97DWHgE= golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb h1:xIApU0ow1zwMa2uL1VDNeQlNVFTWMQxZUZCMDy0Q4Us= -golang.org/x/exp v0.0.0-20230711153332-06a737ee72cb/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= +golang.org/x/exp v0.0.0-20220827204233-334a2380cb91/go.mod h1:cyybsKvd6eL0RnXn6p/Grxp8F5bW7iYuBgsNCOHpMYE= +golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1 h1:MGwJjxBy0HJshjDNfLsYO8xppfqWlA5ZT9OhtUUhTNw= +golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1/go.mod h1:FXUEEKJgO7OQYeo8N01OfiKP8RXMtf6e8aTskBGqWdc= +golang.org/x/image v0.0.0-20180708004352-c73c2afc3b81/go.mod h1:ux5Hcp/YLpHSI86hEcLt0YII63i6oz57MZXIpbrjZUs= golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20190910094157-69e4b8554b2a/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20200119044424-58c23975cae1/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20200430140353-33d19683fad8/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20200618115811-c13761719519/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20201208152932-35266b937fa6/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20210216034530-4410531fe030/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= +golang.org/x/image v0.0.0-20210607152325-775e3b0c77b9/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= +golang.org/x/image v0.0.0-20210628002857-a66eb6448b8d/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= +golang.org/x/image v0.0.0-20211028202545-6944b10bf410/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= +golang.org/x/image v0.0.0-20220302094943-723b81ca9867/go.mod h1:023OzeP/+EPmXeapQh35lcL3II3LrY8Ic+EFFKVhULM= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= @@ -1676,7 +2574,12 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.5.0/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= +golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= +golang.org/x/mod v0.7.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= +golang.org/x/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1697,11 +2600,13 @@ golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= +golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190827160401-ba9fcec4b297/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20190921015927-1a5e07d1ff72/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190923162816-aa69164e4478/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -1724,18 +2629,42 @@ golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwY golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= +golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8= +golang.org/x/net v0.0.0-20210421230115-4e50805a0758/go.mod h1:72T/g9IO56b78aLF+1Kcs5dz7/ng1VjMUvfKvpfy+jM= golang.org/x/net v0.0.0-20210423184538-5f58ad60dda6/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= +golang.org/x/net v0.0.0-20210503060351-7fd8e65b6420/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210510120150-4163338589ed/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20210805182204-aaa1db679c0d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20210813160813-60bc85c4be6d/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211029224645-99673261e6eb/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220325170049-de3da57026de/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220412020605-290c469a71a5/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220617184016-355a448f1bc9/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220624214902-1bab6f366d9e/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= +golang.org/x/net v0.0.0-20220909164309-bea034e7d591/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= +golang.org/x/net v0.0.0-20221012135044-0b7e1fb9d458/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= +golang.org/x/net v0.0.0-20221014081412-f15817d10f9b/go.mod h1:YDH+HFinaLZZlnHAfSS6ZXJJ9M9t4Dl22yv3iI2vPwk= +golang.org/x/net v0.1.0/go.mod h1:Cx3nUiGt4eDBEyega/BKRp+/AlGL8hYe7U9odMt2Cco= +golang.org/x/net v0.2.0/go.mod h1:KqCZLdyyvdV855qA2rE3GC2aiw5xGR5TEjj8smXukLY= +golang.org/x/net v0.4.0/go.mod h1:MBQ8lrhLObU/6UmLb4fmbmk5OcyYmqtbGd/9yIeKjEE= +golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= +golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= +golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= golang.org/x/net v0.12.0 h1:cfawfvKITfUsFCeJIHJrbSxpeu/E81khclypR0GVT50= golang.org/x/net v0.12.0/go.mod h1:zEVYFnQC7m/vmpQFELhcD1EWkZlX69l4oqgmer6hfKA= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= @@ -1747,13 +2676,33 @@ golang.org/x/oauth2 v0.0.0-20200902213428-5d25da1a8d43/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20201109201403-9fd604954f58/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20201208152858-08078c50e5b5/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210413134643-5e61552d6c78/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210514164344-f6687ab2804c/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210628180205-a41e5a781914/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210805134026-6f1e6394065a/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20210819190943-2bc19b11175f/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= +golang.org/x/oauth2 v0.0.0-20220223155221-ee480838109b/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220309155454-6242fa91716a/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220411215720-9780585627b5/go.mod h1:DAh4E804XQdzx2j+YRIaUnCqCV2RuMz24cGBJ5QYIrc= +golang.org/x/oauth2 v0.0.0-20220608161450-d0670ef3b1eb/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= +golang.org/x/oauth2 v0.0.0-20220622183110-fd043fe589d2/go.mod h1:jaDAt6Dkxork7LmZnYtzbRWj0W47D86a3TGe0YHBvmE= +golang.org/x/oauth2 v0.0.0-20220822191816-0ebed06d0094/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= +golang.org/x/oauth2 v0.0.0-20220909003341-f21342109be1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= +golang.org/x/oauth2 v0.0.0-20221006150949-b44042a4b9c1/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= +golang.org/x/oauth2 v0.0.0-20221014153046-6fdb5e3db783/go.mod h1:h4gKUeWbJ4rQPri7E0u6Gs4e9Ri2zaLxzw5DI5XGrYg= +golang.org/x/oauth2 v0.4.0/go.mod h1:RznEsdpjGAINPTOF0UH/t+xJ75L18YO3Ho6Pyn+uRec= +golang.org/x/oauth2 v0.5.0/go.mod h1:9/XBHVqLaWO3/BRHs5jbpYCnOZVjj5V0ndyaAM7KB4I= +golang.org/x/oauth2 v0.6.0/go.mod h1:ycmewcwgD4Rpr3eZJLSB4Kyyljb3qDh40vJ8STE5HKw= golang.org/x/oauth2 v0.10.0 h1:zHCpF2Khkwy4mMB4bv0U37YtJdTGW8jI0glAApi0Kh8= golang.org/x/oauth2 v0.10.0/go.mod h1:kTpgurOux7LqtuxjuyZa4Gj2gdezIt/jQtGnNFfypQI= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190412183630-56d357773e84/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1761,7 +2710,11 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220601150217-0de741cfad7f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220819030929-7fc1605a5dde/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220929204114-8fcdb60fdcc0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.1.0/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.3.0 h1:ftCYgMx6zT/asHUrPw8BLLscYtGznsLAnjq5RH9P66E= golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1782,10 +2735,12 @@ golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190405154228-4b34438f7a67/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190419153524-e8e3143a4f4a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190526052359-791d8a0f4d09/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190531175056-4c3a928424d2/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1794,6 +2749,7 @@ golang.org/x/sys v0.0.0-20190804053845-51ab0e2deafa/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190922100055-0a153f010e69/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1801,6 +2757,7 @@ golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200106162015-b016eb3dc98e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1815,6 +2772,8 @@ golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1824,34 +2783,63 @@ golang.org/x/sys v0.0.0-20201204225414-ed752295db88/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210220050731-9a76102bfb43/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210303074136-134d130e1a04/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210304124612-50617c2ba197/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210420072515-93ed5bcd2bfe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210819135213-f52c844e1c1c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210823070655-63515b42dcdf/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210908233432-aa78b53d3365/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211124211545-fe61309f8881/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20211210111614-af8b64212486/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220128215802-99c3d69c2c27/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220227234510-4e6760a101f9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220310020820-b874c991c1a5/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220328115105-d36c6a25d886/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220405052023-b1e9470b6e64/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220502124256-b6088ccd6cba/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220610221304-9f5ed59c137d/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220624220833-87e55d714810/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220704084225-05e143d24a9e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220829200755-d48e67d00261/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.2.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.3.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1861,7 +2849,12 @@ golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXR golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20201210144234-2321bbc49cbf/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= +golang.org/x/term v0.1.0/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= +golang.org/x/term v0.2.0/go.mod h1:TVmDHMZPmdnySmBfhjOoOdhjzdE1h4u1VwSiw2l1Nuc= +golang.org/x/term v0.3.0/go.mod h1:q750SLmJuPmVoN1blW3UFBPREJfb1KmY3vwxfr+nFDA= +golang.org/x/term v0.4.0/go.mod h1:9P2UbLfCdcvo3p/nzKvsmas4TnlujnuoV9hGgYzW1lQ= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= +golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= golang.org/x/term v0.10.0 h1:3R7pNqamzBraeqj/Tj8qt1aQ2HpmlC+Cx/qL/7hn4/c= golang.org/x/term v0.10.0/go.mod h1:lpqdcUyK/oCiQxvxVrppt5ggO2KCZ5QblwqPnfZ6d5o= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1873,36 +2866,50 @@ golang.org/x/text v0.3.4/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.5/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.6/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= +golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= +golang.org/x/text v0.4.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= +golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= +golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= +golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= golang.org/x/text v0.11.0 h1:LAntKIrcmeSKERyiOh0XMV39LXS8IE9UL2yP7+f5ij4= golang.org/x/text v0.11.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.0.0-20220922220347-f3bd1da661af/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.1.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/tools v0.0.0-20180525024113-a5b4c53f6e8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181130052023-1c3d964395ce/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190206041539-40960b6deb8e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190329151228-23e29df326fe/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190416151739-9c9e1878f421/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190420181800-aa740d480789/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190425163242-31fd60d6bfdc/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= +golang.org/x/tools v0.0.0-20190531172133-b3315ee88b7d/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190823170909-c4a336ef6a2f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20190907020128-2ca718005c18/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20190927191325-030b2cf1153e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191010075000-0337d82405ff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191029041327-9cc4af7d6b2c/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -1940,6 +2947,7 @@ golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/tools v0.0.0-20201124115921-2c860bdd6e78/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= @@ -1947,9 +2955,16 @@ golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= +golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +golang.org/x/tools v0.1.4/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= +golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= +golang.org/x/tools v0.3.0/go.mod h1:/rWhSS2+zyEVwoJf8YAX6L2f0ntZ7Kn/mGgAWcipA5k= +golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= +golang.org/x/tools v0.7.0/go.mod h1:4pg6aUX35JBAogB10C9AtvVL+qowtN4pT3CGSQex14s= golang.org/x/tools v0.11.0 h1:EMCa6U9S2LtZXLAMoWiR/R8dAQFRqbAitmbJ2UKhoi8= golang.org/x/tools v0.11.0/go.mod h1:anzJrxPjNtfgiYQYirP2CPGzGLxrH2u2QBhn6Bf3qY8= golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1958,11 +2973,22 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= 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= +golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= +golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= +golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= gomodules.xyz/jsonpatch/v2 v2.2.0 h1:4pT439QV83L+G9FkcCriY6EkpcK6r6bK+A5FBUMI7qY= gomodules.xyz/jsonpatch/v2 v2.2.0/go.mod h1:WXp+iVDkoLQqPudfQ9GBlwB2eZ5DKOnjQZCYdOS8GPY= +gonum.org/v1/gonum v0.0.0-20180816165407-929014505bf4/go.mod h1:Y+Yx5eoAFn32cQvJDxZx5Dpnq+c3wtXuadVZAcxbbBo= +gonum.org/v1/gonum v0.8.2/go.mod h1:oe/vMfY3deqTw+1EZJhuvEW2iwGF1bW9wwu7XCu0+v0= +gonum.org/v1/gonum v0.9.3/go.mod h1:TZumC3NeyVQskjXqmyWt4S3bINhy7B4eYwW69EbyX+0= +gonum.org/v1/gonum v0.11.0/go.mod h1:fSG4YDCxxUZQJ7rKsQrj0gMOg00Il0Z96/qMA4bVQhA= gonum.org/v1/gonum v0.13.0 h1:a0T3bh+7fhRyqeNbiC3qVHYmkiQgit3wnNan/2c0HMM= gonum.org/v1/gonum v0.13.0/go.mod h1:/WPYRckkfWrhWefxyYTfrTtQR0KH4iyHNuzxqXAKyAU= +gonum.org/v1/netlib v0.0.0-20190313105609-8cb42192e0e0/go.mod h1:wa6Ws7BG/ESfp6dHfk7C6KdzKA7wR7u/rKwOGE66zvw= +gonum.org/v1/plot v0.0.0-20190515093506-e2840ee46a6b/go.mod h1:Wt8AAjI+ypCyYX3nZBvf6cAIx93T+c/OS2HFAYskSZc= +gonum.org/v1/plot v0.9.0/go.mod h1:3Pcqqmp6RHvJI72kgb8fThyUnav364FOsdDo2aGW5lY= +gonum.org/v1/plot v0.10.1/go.mod h1:VZW5OlhkL1mysU9vaqNHnsy86inf6Ot+jB3r+BczCEo= google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= @@ -1983,6 +3009,42 @@ google.golang.org/api v0.30.0/go.mod h1:QGmEvQ87FHZNiUVJkT14jQNYJ4ZJjdRF23ZXz513 google.golang.org/api v0.35.0/go.mod h1:/XrVsuzM0rZmrsbjJutiuftIzeuTQcEeaYcSk/mQ1dg= google.golang.org/api v0.36.0/go.mod h1:+z5ficQTmoYpPn8LCUNVpK5I7hwkpjbcgqA7I34qYtE= google.golang.org/api v0.40.0/go.mod h1:fYKFpnQN0DsDSKRVRcQSDQNtqWPfM9i+zNPxepjRCQ8= +google.golang.org/api v0.41.0/go.mod h1:RkxM5lITDfTzmyKFPt+wGrCJbVfniCr2ool8kTBzRTU= +google.golang.org/api v0.43.0/go.mod h1:nQsDGjRXMo4lvh5hP0TKqF244gqhGcr/YSIykhUk/94= +google.golang.org/api v0.47.0/go.mod h1:Wbvgpq1HddcWVtzsVLyfLp8lDg6AA241LmgIL59tHXo= +google.golang.org/api v0.48.0/go.mod h1:71Pr1vy+TAZRPkPs/xlCf5SsU8WjuAWv1Pfjbtukyy4= +google.golang.org/api v0.50.0/go.mod h1:4bNT5pAuq5ji4SRZm+5QIkjny9JAyVD/3gaSihNefaw= +google.golang.org/api v0.51.0/go.mod h1:t4HdrdoNgyN5cbEfm7Lum0lcLDLiise1F8qDKX00sOU= +google.golang.org/api v0.54.0/go.mod h1:7C4bFFOvVDGXjfDTAsgGwDgAxRDeQ4X8NvUedIt6z3k= +google.golang.org/api v0.55.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= +google.golang.org/api v0.56.0/go.mod h1:38yMfeP1kfjsl8isn0tliTjIb1rJXcQi4UXlbqivdVE= +google.golang.org/api v0.57.0/go.mod h1:dVPlbZyBo2/OjBpmvNdpn2GRm6rPy75jyU7bmhdrMgI= +google.golang.org/api v0.61.0/go.mod h1:xQRti5UdCmoCEqFxcz93fTl338AVqDgyaDRuOZ3hg9I= +google.golang.org/api v0.63.0/go.mod h1:gs4ij2ffTRXwuzzgJl/56BdwJaA194ijkfn++9tDuPo= +google.golang.org/api v0.67.0/go.mod h1:ShHKP8E60yPsKNw/w8w+VYaj9H6buA5UqDp8dhbQZ6g= +google.golang.org/api v0.70.0/go.mod h1:Bs4ZM2HGifEvXwd50TtW70ovgJffJYw2oRCOFU/SkfA= +google.golang.org/api v0.71.0/go.mod h1:4PyU6e6JogV1f9eA4voyrTY2batOLdgZ5qZ5HOCc4j8= +google.golang.org/api v0.74.0/go.mod h1:ZpfMZOVRMywNyvJFeqL9HRWBgAuRfSjJFpe9QtRRyDs= +google.golang.org/api v0.75.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= +google.golang.org/api v0.77.0/go.mod h1:pU9QmyHLnzlpar1Mjt4IbapUCy8J+6HD6GeELN69ljA= +google.golang.org/api v0.78.0/go.mod h1:1Sg78yoMLOhlQTeF+ARBoytAcH1NNyyl390YMy6rKmw= +google.golang.org/api v0.80.0/go.mod h1:xY3nI94gbvBrE0J6NHXhxOmW97HG7Khjkku6AFB3Hyg= +google.golang.org/api v0.84.0/go.mod h1:NTsGnUFJMYROtiquksZHBWtHfeMC7iYthki7Eq3pa8o= +google.golang.org/api v0.85.0/go.mod h1:AqZf8Ep9uZ2pyTvgL+x0D3Zt0eoT9b5E8fmzfu6FO2g= +google.golang.org/api v0.90.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= +google.golang.org/api v0.93.0/go.mod h1:+Sem1dnrKlrXMR/X0bPnMWyluQe4RsNoYfmNLhOIkzw= +google.golang.org/api v0.95.0/go.mod h1:eADj+UBuxkh5zlrSntJghuNeg8HwQ1w5lTKkuqaETEI= +google.golang.org/api v0.96.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= +google.golang.org/api v0.97.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= +google.golang.org/api v0.98.0/go.mod h1:w7wJQLTM+wvQpNf5JyEcBoxK0RH7EDrh/L4qfsuJ13s= +google.golang.org/api v0.99.0/go.mod h1:1YOf74vkVndF7pG6hIHuINsM7eWwpVTAfNMNiL91A08= +google.golang.org/api v0.100.0/go.mod h1:ZE3Z2+ZOr87Rx7dqFsdRQkRBk36kDtp/h+QpHbB7a70= +google.golang.org/api v0.102.0/go.mod h1:3VFl6/fzoA+qNuS1N1/VfXY4LjoXN/wzeIp7TweWwGo= +google.golang.org/api v0.103.0/go.mod h1:hGtW6nK1AC+d9si/UBhw8Xli+QMOf6xyNAyJw4qU9w0= +google.golang.org/api v0.106.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/O9MY= +google.golang.org/api v0.107.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/O9MY= +google.golang.org/api v0.108.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/O9MY= +google.golang.org/api v0.110.0/go.mod h1:7FC4Vvx1Mooxh8C5HWjzZHcavuS2f6pmJpZx60ca7iI= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -2017,6 +3079,7 @@ google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfG google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200324203455-a04cca1dde73/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= +google.golang.org/genproto v0.0.0-20200423170343-7949de9c1215/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= google.golang.org/genproto v0.0.0-20200513103714-09dca8ec2884/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= @@ -2033,9 +3096,96 @@ google.golang.org/genproto v0.0.0-20201201144952-b05cb90ed32e/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210222152913-aa3ee6e6a81c/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210329143202-679c6ae281ee/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= +google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= +google.golang.org/genproto v0.0.0-20210513213006-bf773b8c8384/go.mod h1:P3QM42oQyzQSnHPnZ/vqoCdDmzH28fzWByN9asMeM8A= +google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= +google.golang.org/genproto v0.0.0-20210604141403-392c879c8b08/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= +google.golang.org/genproto v0.0.0-20210608205507-b6d2f5bf0d7d/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= +google.golang.org/genproto v0.0.0-20210713002101-d411969a0d9a/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k= +google.golang.org/genproto v0.0.0-20210716133855-ce7ef5c701ea/go.mod h1:AxrInvYm1dci+enl5hChSFPOmmUF1+uAa/UsgNRWd7k= +google.golang.org/genproto v0.0.0-20210728212813-7823e685a01f/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48= +google.golang.org/genproto v0.0.0-20210805201207-89edb61ffb67/go.mod h1:ob2IJxKrgPT52GcgX759i1sleT07tiKowYBGbczaW48= +google.golang.org/genproto v0.0.0-20210813162853-db860fec028c/go.mod h1:cFeNkxwySK631ADgubI+/XFU/xp8FD5KIVV4rj8UC5w= +google.golang.org/genproto v0.0.0-20210821163610-241b8fcbd6c8/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210828152312-66f60bf46e71/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210831024726-fe130286e0e2/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210903162649-d08c68adba83/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210909211513-a8c4777a87af/go.mod h1:eFjDcFEctNawg4eG61bRv87N7iHBWyVhJu7u1kqDUXY= +google.golang.org/genproto v0.0.0-20210924002016-3dee208752a0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211118181313-81c1377c94b1/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211206160659-862468c7d6e0/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211208223120-3a66f561d7aa/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20211221195035-429b39de9b1c/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= google.golang.org/genproto v0.0.0-20220107163113-42d7afdf6368/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220126215142-9970aeb2e350/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220207164111-0872dc986b00/go.mod h1:5CzLGKJ67TSI2B9POpiiyGha0AjJvZIUgRMt1dSmuhc= +google.golang.org/genproto v0.0.0-20220218161850-94dd64e39d7c/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220222213610-43724f9ea8cf/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220304144024-325a89244dc8/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220310185008-1973136f34c6/go.mod h1:kGP+zUP2Ddo0ayMi4YuN7C3WZyJvGLZRh8Z5wnAqvEI= +google.golang.org/genproto v0.0.0-20220324131243-acbaeb5b85eb/go.mod h1:hAL49I2IFola2sVEjAn7MEwsja0xp51I0tlGAf9hz4E= +google.golang.org/genproto v0.0.0-20220329172620-7be39ac1afc7/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220407144326-9054f6ed7bac/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220413183235-5e96e2839df9/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220414192740-2d67ff6cf2b4/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220421151946-72621c1f0bd3/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220429170224-98d788798c3e/go.mod h1:8w6bsBMX6yCPbAVTeqQHvzxW0EIFigd5lZyahWgyfDo= +google.golang.org/genproto v0.0.0-20220502173005-c8bf987b8c21/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220505152158-f39f71e6c8f3/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220518221133-4f43b3371335/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220523171625-347a074981d8/go.mod h1:RAyBrSAP7Fh3Nc84ghnVLDPuV51xc9agzmm4Ph6i0Q4= +google.golang.org/genproto v0.0.0-20220608133413-ed9918b62aac/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220616135557-88e70c0c3a90/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220617124728-180714bec0ad/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220624142145-8cd45d7dbd1f/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220628213854-d9e0b6570c03/go.mod h1:KEWEmljWE5zPzLBa/oHl6DaEt9LmfH6WtH1OHIvleBA= +google.golang.org/genproto v0.0.0-20220722212130-b98a9ff5e252/go.mod h1:GkXuJDJ6aQ7lnJcRF+SJVgFdQhypqgl3LB1C9vabdRE= +google.golang.org/genproto v0.0.0-20220801145646-83ce21fca29f/go.mod h1:iHe1svFLAZg9VWz891+QbRMwUv9O/1Ww+/mngYeThbc= +google.golang.org/genproto v0.0.0-20220815135757-37a418bb8959/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220817144833-d7fd3f11b9b1/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220822174746-9e6da59bd2fc/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220829144015-23454907ede3/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220829175752-36a9c930ecbf/go.mod h1:dbqgFATTzChvnt+ujMdZwITVAJHFtfyN1qUhDqEiIlk= +google.golang.org/genproto v0.0.0-20220913154956-18f8339a66a5/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220914142337-ca0e39ece12f/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220915135415-7fd63a7952de/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220916172020-2692e8806bfa/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220919141832-68c03719ef51/go.mod h1:0Nb8Qy+Sk5eDzHnzlStwW3itdNaWoZA5XeSG+R3JHSo= +google.golang.org/genproto v0.0.0-20220920201722-2b89144ce006/go.mod h1:ht8XFiar2npT/g4vkk7O0WYS1sHOHbdujxbEp7CJWbw= +google.golang.org/genproto v0.0.0-20220926165614-551eb538f295/go.mod h1:woMGP53BroOrRY3xTxlbr8Y3eB/nzAvvFM83q7kG2OI= +google.golang.org/genproto v0.0.0-20220926220553-6981cbe3cfce/go.mod h1:woMGP53BroOrRY3xTxlbr8Y3eB/nzAvvFM83q7kG2OI= +google.golang.org/genproto v0.0.0-20221010155953-15ba04fc1c0e/go.mod h1:3526vdqwhZAwq4wsRUaVG555sVgsNmIjRtO7t/JH29U= +google.golang.org/genproto v0.0.0-20221014173430-6e2ab493f96b/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= +google.golang.org/genproto v0.0.0-20221014213838-99cd37c6964a/go.mod h1:1vXfmgAz9N9Jx0QA82PqRVauvCz1SGSz739p0f183jM= +google.golang.org/genproto v0.0.0-20221024153911-1573dae28c9c/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= +google.golang.org/genproto v0.0.0-20221024183307-1bc688fe9f3e/go.mod h1:9qHF0xnpdSfF6knlcsnpzUu5y+rpwgbvsyGAZPBMg4s= +google.golang.org/genproto v0.0.0-20221027153422-115e99e71e1c/go.mod h1:CGI5F/G+E5bKwmfYo09AXuVN4dD894kIKUFmVbP2/Fo= +google.golang.org/genproto v0.0.0-20221109142239-94d6d90a7d66/go.mod h1:rZS5c/ZVYMaOGBfO68GWtjOw/eLaZM1X6iVtgjZ+EWg= +google.golang.org/genproto v0.0.0-20221114212237-e4508ebdbee1/go.mod h1:rZS5c/ZVYMaOGBfO68GWtjOw/eLaZM1X6iVtgjZ+EWg= +google.golang.org/genproto v0.0.0-20221117204609-8f9c96812029/go.mod h1:rZS5c/ZVYMaOGBfO68GWtjOw/eLaZM1X6iVtgjZ+EWg= +google.golang.org/genproto v0.0.0-20221118155620-16455021b5e6/go.mod h1:rZS5c/ZVYMaOGBfO68GWtjOw/eLaZM1X6iVtgjZ+EWg= +google.golang.org/genproto v0.0.0-20221201164419-0e50fba7f41c/go.mod h1:rZS5c/ZVYMaOGBfO68GWtjOw/eLaZM1X6iVtgjZ+EWg= +google.golang.org/genproto v0.0.0-20221201204527-e3fa12d562f3/go.mod h1:rZS5c/ZVYMaOGBfO68GWtjOw/eLaZM1X6iVtgjZ+EWg= +google.golang.org/genproto v0.0.0-20221202195650-67e5cbc046fd/go.mod h1:cTsE614GARnxrLsqKREzmNYJACSWWpAWdNMwnD7c2BE= +google.golang.org/genproto v0.0.0-20221227171554-f9683d7f8bef/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230110181048-76db0878b65f/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230112194545-e10362b5ecf9/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230113154510-dbe35b8444a5/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230123190316-2c411cf9d197/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230124163310-31e0e69b6fc2/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230125152338-dcaf20b6aeaa/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230127162408-596548ed4efa/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230209215440-0dfe4f8abfcc/go.mod h1:RGgjbofJ8xD9Sq1VVhDM1Vok1vRONV+rg+CjzG4SZKM= +google.golang.org/genproto v0.0.0-20230216225411-c8e22ba71e44/go.mod h1:8B0gmkoRebU8ukX6HP+4wrVQUY1+6PkQ44BSyIlflHA= +google.golang.org/genproto v0.0.0-20230222225845-10f96fb3dbec/go.mod h1:3Dl5ZL0q0isWJt+FVcfpQyirqemEuLAK/iFvg1UP1Hw= +google.golang.org/genproto v0.0.0-20230306155012-7f2fa6fef1f4/go.mod h1:NWraEVixdDnqcqQ30jipen1STv2r/n24Wb7twVTGR4s= google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130 h1:Au6te5hbKUV8pIYWHqOUZ1pva5qK/rwbIhoXEUB9Lu8= google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130/go.mod h1:O9kGHb51iE/nOGvQaDUuadVYqovW56s5emA88lQnj6Y= google.golang.org/genproto/googleapis/api v0.0.0-20230629202037-9506855d4529 h1:s5YSX+ZH5b5vS9rnpGymvIyMpLRJizowqDlOuyjXnTk= @@ -2064,11 +3214,31 @@ google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= +google.golang.org/grpc v1.37.1/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= +google.golang.org/grpc v1.39.0/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= +google.golang.org/grpc v1.39.1/go.mod h1:PImNr+rS9TWYb2O4/emRugxiyHZ5JyHW5F+RPnDzfrE= google.golang.org/grpc v1.40.0/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= +google.golang.org/grpc v1.40.1/go.mod h1:ogyxbiOoUXAkP+4+xa6PZSE9DZgIHtSpzjDTB9KAK34= +google.golang.org/grpc v1.42.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU= +google.golang.org/grpc v1.44.0/go.mod h1:k+4IHHFw41K8+bbowsex27ge2rCb65oeWqe4jJ590SU= +google.golang.org/grpc v1.45.0/go.mod h1:lN7owxKUQEqMfSyQikvvk5tf/6zMPsrK+ONuO11+0rQ= +google.golang.org/grpc v1.46.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.46.2/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.47.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.48.0/go.mod h1:vN9eftEi1UMyUsIF80+uQXhHjbXYbm0uXoFCACuMGWk= +google.golang.org/grpc v1.49.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= +google.golang.org/grpc v1.50.0/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= +google.golang.org/grpc v1.50.1/go.mod h1:ZgQEeidpAuNRZ8iRrlBKXZQP1ghovWIVhdJRyCDK+GI= +google.golang.org/grpc v1.51.0/go.mod h1:wgNDFcnuBGmxLKI/qn4T+m5BtEBYXJPvibbUPsAIPww= +google.golang.org/grpc v1.52.0/go.mod h1:pu6fVzoFb+NBYNAvQL08ic+lvB2IojljRYuun5vorUY= +google.golang.org/grpc v1.53.0/go.mod h1:OnIrk0ipVdj4N5d9IUoFUx72/VlD7+jUsHwZgwSMQpw= +google.golang.org/grpc v1.55.0/go.mod h1:iYEXKGkEBhg1PjZQvoYEVPTDkHo1/bjTnfwTeGONTY8= google.golang.org/grpc v1.56.2 h1:fVRFRnXvU+x6C4IlHZewvJOVHoOv1TUuQyoRsYnB4bI= google.golang.org/grpc v1.56.2/go.mod h1:I9bI3vqKfayGqPUAwGdOSu7kt6oIJLixfffKrpXqQ9s= +google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/grpc/examples v0.0.0-20210424002626-9572fd6faeae/go.mod h1:Ly7ZA/ARzg8fnPU9TyZIxoz33sEUuWX7txiqs8lPTgE= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= @@ -2083,12 +3253,16 @@ google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlba google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20200227125254-8fa46927fb4f/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20200902074654-038fdea0a05b/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= @@ -2121,18 +3295,19 @@ gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.3/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.5/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0-20200605160147-a5ece683394c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -2141,26 +3316,63 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= -k8s.io/api v0.25.11 h1:4mjYDfE3yp22jrytjH0knwgzjXKkxHX4D01ZCAazvZM= -k8s.io/api v0.25.11/go.mod h1:bK4UvD4bthtutNlvensrfBX21PRQ/vs2cIYggHkOOAo= +honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= +k8s.io/api v0.25.4 h1:3YO8J4RtmG7elEgaWMb4HgmpS2CfY1QlaOz9nwB+ZSs= +k8s.io/api v0.25.4/go.mod h1:IG2+RzyPQLllQxnhzD8KQNEu4c4YvyDTpSMztf4A0OQ= k8s.io/apiextensions-apiserver v0.25.3 h1:bfI4KS31w2f9WM1KLGwnwuVlW3RSRPuIsfNF/3HzR0k= k8s.io/apiextensions-apiserver v0.25.3/go.mod h1:ZJqwpCkxIx9itilmZek7JgfUAM0dnTsA48I4krPqRmo= -k8s.io/apimachinery v0.25.11 h1:2EhfdrSAMvBxsswvOGCEymKk4ZnHZkranuZqdR0rsO4= -k8s.io/apimachinery v0.25.11/go.mod h1:IFwbcNi3gKkfDhuy0VYu3+BwbxbiIov3p6FR8ge1Epc= +k8s.io/apimachinery v0.26.2 h1:da1u3D5wfR5u2RpLhE/ZtZS2P7QvDgLZTi9wrNZl/tQ= +k8s.io/apimachinery v0.26.2/go.mod h1:ats7nN1LExKHvJ9TmwootT00Yz05MuYqPXEXaVeOy5I= k8s.io/cli-runtime v0.25.11 h1:GE2yNZm1tN+MJtw1SGMOLesLF7Kp7NVAVqRSTbXfu4o= k8s.io/cli-runtime v0.25.11/go.mod h1:r/nEINuHVEpgGhcd2WamU7hD1t/lMnSz8XM44Autltc= -k8s.io/client-go v0.25.11 h1:DJQ141UsbNRI6wYSlcYLP5J5BW5Wq7Bgm42Ztq2SW70= -k8s.io/client-go v0.25.11/go.mod h1:41Xs7p1SfhoReUnmjjYCfCNWFiq4xSkexwJfbxF2F7A= +k8s.io/client-go v0.25.4 h1:3RNRDffAkNU56M/a7gUfXaEzdhZlYhoW8dgViGy5fn8= +k8s.io/client-go v0.25.4/go.mod h1:8trHCAC83XKY0wsBIpbirZU4NTUpbuhc2JnI7OruGZw= k8s.io/component-base v0.25.11 h1:3QmISCE9n9CJkVpTA4spQO1IZCrLlOwbKdzSN9dqZZA= k8s.io/component-base v0.25.11/go.mod h1:wFR4pfB+xTc6FBak+RoWRNeTmelGE4XWJP/xVOvn3vM= -k8s.io/klog/v2 v2.80.1 h1:atnLQ121W371wYYFawwYx1aEY2eUfs4l3J72wtgAwV4= -k8s.io/klog/v2 v2.80.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= -k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280 h1:+70TFaan3hfJzs+7VK2o+OGxg8HsuBr/5f6tVAjDu6E= -k8s.io/kube-openapi v0.0.0-20221012153701-172d655c2280/go.mod h1:+Axhij7bCpeqhklhUTe3xmOn6bWxolyZEeyaFpjGtl4= +k8s.io/klog/v2 v2.100.1 h1:7WCHKK6K8fNhTqfBhISHQ97KrnJNFZMcQvKp7gP/tmg= +k8s.io/klog/v2 v2.100.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= +k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d h1:VcFq5n7wCJB2FQMCIHfC+f+jNcGgNMar1uKd6rVlifU= +k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d/go.mod h1:y5VtZWM9sHHc2ZodIH/6SHzXj+TPU5USoA8lcIeKEKY= k8s.io/kubectl v0.25.11 h1:6bsft5Gan6BCvQ7cJbDRFjTm4Zfq8GuUYpsWAdVngYE= k8s.io/kubectl v0.25.11/go.mod h1:8mIfgkFgT+yJ8/TlmPW1qoRh46H2si9q5nW8id7i9iM= -k8s.io/utils v0.0.0-20221107191617-1a15be271d1d h1:0Smp/HP1OH4Rvhe+4B8nWGERtlqAGSftbSbbmm45oFs= -k8s.io/utils v0.0.0-20221107191617-1a15be271d1d/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +k8s.io/utils v0.0.0-20230308161112-d77c459e9343 h1:m7tbIjXGcGIAtpmQr7/NAi7RsWoW3E7Zcm4jI1HicTc= +k8s.io/utils v0.0.0-20230308161112-d77c459e9343/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +lukechampine.com/uint128 v1.1.1/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= +lukechampine.com/uint128 v1.2.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= +modernc.org/cc/v3 v3.36.0/go.mod h1:NFUHyPn4ekoC/JHeZFfZurN6ixxawE1BnVonP/oahEI= +modernc.org/cc/v3 v3.36.2/go.mod h1:NFUHyPn4ekoC/JHeZFfZurN6ixxawE1BnVonP/oahEI= +modernc.org/cc/v3 v3.36.3/go.mod h1:NFUHyPn4ekoC/JHeZFfZurN6ixxawE1BnVonP/oahEI= +modernc.org/ccgo/v3 v3.0.0-20220428102840-41399a37e894/go.mod h1:eI31LL8EwEBKPpNpA4bU1/i+sKOwOrQy8D87zWUcRZc= +modernc.org/ccgo/v3 v3.0.0-20220430103911-bc99d88307be/go.mod h1:bwdAnOoaIt8Ax9YdWGjxWsdkPcZyRPHqrOvJxaKAKGw= +modernc.org/ccgo/v3 v3.16.4/go.mod h1:tGtX0gE9Jn7hdZFeU88slbTh1UtCYKusWOoCJuvkWsQ= +modernc.org/ccgo/v3 v3.16.6/go.mod h1:tGtX0gE9Jn7hdZFeU88slbTh1UtCYKusWOoCJuvkWsQ= +modernc.org/ccgo/v3 v3.16.8/go.mod h1:zNjwkizS+fIFDrDjIAgBSCLkWbJuHF+ar3QRn+Z9aws= +modernc.org/ccgo/v3 v3.16.9/go.mod h1:zNMzC9A9xeNUepy6KuZBbugn3c0Mc9TeiJO4lgvkJDo= +modernc.org/ccorpus v1.11.6/go.mod h1:2gEUTrWqdpH2pXsmTM1ZkjeSrUWDpjMu2T6m29L/ErQ= +modernc.org/httpfs v1.0.6/go.mod h1:7dosgurJGp0sPaRanU53W4xZYKh14wfzX420oZADeHM= +modernc.org/libc v0.0.0-20220428101251-2d5f3daf273b/go.mod h1:p7Mg4+koNjc8jkqwcoFBJx7tXkpj00G77X7A72jXPXA= +modernc.org/libc v1.16.0/go.mod h1:N4LD6DBE9cf+Dzf9buBlzVJndKr/iJHG97vGLHYnb5A= +modernc.org/libc v1.16.1/go.mod h1:JjJE0eu4yeK7tab2n4S1w8tlWd9MxXLRzheaRnAKymU= +modernc.org/libc v1.16.17/go.mod h1:hYIV5VZczAmGZAnG15Vdngn5HSF5cSkbvfz2B7GRuVU= +modernc.org/libc v1.16.19/go.mod h1:p7Mg4+koNjc8jkqwcoFBJx7tXkpj00G77X7A72jXPXA= +modernc.org/libc v1.17.0/go.mod h1:XsgLldpP4aWlPlsjqKRdHPqCxCjISdHfM/yeWC5GyW0= +modernc.org/libc v1.17.1/go.mod h1:FZ23b+8LjxZs7XtFMbSzL/EhPxNbfZbErxEHc7cbD9s= +modernc.org/mathutil v1.2.2/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= +modernc.org/mathutil v1.4.1/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= +modernc.org/mathutil v1.5.0/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= +modernc.org/memory v1.1.1/go.mod h1:/0wo5ibyrQiaoUoH7f9D8dnglAmILJ5/cxZlRECf+Nw= +modernc.org/memory v1.2.0/go.mod h1:/0wo5ibyrQiaoUoH7f9D8dnglAmILJ5/cxZlRECf+Nw= +modernc.org/memory v1.2.1/go.mod h1:PkUhL0Mugw21sHPeskwZW4D6VscE/GQJOnIpCnW6pSU= +modernc.org/opt v0.1.1/go.mod h1:WdSiB5evDcignE70guQKxYUl14mgWtbClRi5wmkkTX0= +modernc.org/opt v0.1.3/go.mod h1:WdSiB5evDcignE70guQKxYUl14mgWtbClRi5wmkkTX0= +modernc.org/sqlite v1.18.1/go.mod h1:6ho+Gow7oX5V+OiOQ6Tr4xeqbx13UZ6t+Fw9IRUG4d4= +modernc.org/strutil v1.1.1/go.mod h1:DE+MQQ/hjKBZS2zNInV5hhcipt5rLPWkmpbGeW5mmdw= +modernc.org/strutil v1.1.3/go.mod h1:MEHNA7PdEnEwLvspRMtWTNnp2nnyvMfkimT1NKNAGbw= +modernc.org/tcl v1.13.1/go.mod h1:XOLfOwzhkljL4itZkK6T72ckMgvj0BDsnKNdZVUOecw= +modernc.org/token v1.0.0/go.mod h1:UGzOrNV1mAFSEB63lOFHIpNRUVMvYTc6yu1SMY/XTDM= +modernc.org/z v1.5.1/go.mod h1:eWFB510QWW5Th9YGZT81s+LwvaAs3Q2yr4sP0rmLkv8= +nhooyr.io/websocket v1.8.7 h1:usjR2uOr/zjjkVMy0lW+PPohFok7PCow5sDjLgX4P4g= +nhooyr.io/websocket v1.8.7/go.mod h1:B70DZP8IakI65RVQ51MsWP/8jndNma26DVA/nFSCgW0= pgregory.net/rapid v0.5.5 h1:jkgx1TjbQPD/feRoK+S/mXw9e1uj6WilpHrXJowi6oA= pgregory.net/rapid v0.5.5/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= @@ -2169,8 +3381,8 @@ rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= sigs.k8s.io/controller-runtime v0.13.0 h1:iqa5RNciy7ADWnIc8QxCbOX5FEKVR3uxVxKHRMc2WIQ= sigs.k8s.io/controller-runtime v0.13.0/go.mod h1:Zbz+el8Yg31jubvAEyglRZGdLAjplZl+PgtYNI6WNTI= -sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2 h1:iXTIw73aPyC+oRdyqqvVJuloN1p0AC/kzH07hu3NE+k= -sigs.k8s.io/json v0.0.0-20220713155537-f223a00ba0e2/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd h1:EDPBXCAspyGV4jQlpZSudPeMmr1bNJefnuqLsRAsHZo= +sigs.k8s.io/json v0.0.0-20221116044647-bc3834ca7abd/go.mod h1:B8JuhiUyNFVKdsE8h686QcCxMaH6HrOAZj4vswFpcB0= sigs.k8s.io/kustomize/api v0.12.1 h1:7YM7gW3kYBwtKvoY216ZzY+8hM+lV53LUayghNRJ0vM= sigs.k8s.io/kustomize/api v0.12.1/go.mod h1:y3JUhimkZkR6sbLNwfJHxvo1TCLwuwm14sCYnkH6S1s= sigs.k8s.io/kustomize/kyaml v0.13.9 h1:Qz53EAaFFANyNgyOEJbT/yoIHygK40/ZcvU3rgry2Tk= diff --git a/integration-tests/smoke/cron_test.go b/integration-tests/smoke/cron_test.go index d11007e1f66..30eadb8f16b 100644 --- a/integration-tests/smoke/cron_test.go +++ b/integration-tests/smoke/cron_test.go @@ -2,56 +2,35 @@ package smoke import ( "fmt" - "strings" - "testing" - "github.com/google/uuid" "github.com/onsi/gomega" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - - "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/stretchr/testify/require" + "testing" ) func TestCronBasic(t *testing.T) { t.Parallel() - testEnvironment := setupCronTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Creating mockserver client shouldn't fail") - chainlinkNode := chainlinkNodes[0] - err = mockServer.SetValuePath("/variable", 5) + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(1). + Build() + require.NoError(t, err) + err = env.MockServer.Client.SetValuePath("/variable", 5) require.NoError(t, err, "Setting value path in mockserver shouldn't fail") - // Register cleanup for any test - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, nil) - require.NoError(t, err, "Error tearing down environment") - }) bta := &client.BridgeTypeAttributes{ - Name: fmt.Sprintf("variable-%s", uuid.New().String()), - URL: fmt.Sprintf("%s/variable", mockServer.Config.ClusterURL), + Name: fmt.Sprintf("variable-%s", uuid.NewString()), + URL: fmt.Sprintf("%s/variable", env.MockServer.InternalEndpoint), RequestData: "{}", } - err = chainlinkNode.MustCreateBridge(bta) + err = env.CLNodes[0].API.MustCreateBridge(bta) require.NoError(t, err, "Creating bridge in chainlink node shouldn't fail") - job, err := chainlinkNode.MustCreateJob(&client.CronJobSpec{ + job, err := env.CLNodes[0].API.MustCreateJob(&client.CronJobSpec{ Schedule: "CRON_TZ=UTC * * * * * *", ObservationSource: client.ObservationSourceSpecBridge(bta), }) @@ -59,7 +38,7 @@ func TestCronBasic(t *testing.T) { gom := gomega.NewGomegaWithT(t) gom.Eventually(func(g gomega.Gomega) { - jobRuns, err := chainlinkNode.MustReadRunsByJob(job.Data.ID) + jobRuns, err := env.CLNodes[0].API.MustReadRunsByJob(job.Data.ID) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Reading Job run data shouldn't fail") g.Expect(len(jobRuns.Data)).Should(gomega.BeNumerically(">=", 5), "Expected number of job runs to be greater than 5, but got %d", len(jobRuns.Data)) @@ -67,32 +46,5 @@ func TestCronBasic(t *testing.T) { for _, jr := range jobRuns.Data { g.Expect(jr.Attributes.Errors).Should(gomega.Equal([]interface{}{nil}), "Job run %s shouldn't have errors", jr.ID) } - }, "2m", "1s").Should(gomega.Succeed()) -} - -func setupCronTest(t *testing.T) (testEnvironment *environment.Environment) { - network := networks.SelectedNetwork - evmConfig := ethereum.New(nil) - if !network.Simulated { - evmConfig = ethereum.New(ðereum.Props{ - NetworkName: network.Name, - Simulated: network.Simulated, - WsURLs: network.URLs, - }) - } - cd, err := chainlink.NewDeployment(1, map[string]interface{}{ - "toml": client.AddNetworksConfig("", network), - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-cron-%s", strings.ReplaceAll(strings.ToLower(network.Name), " ", "-")), - Test: t, - }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(evmConfig). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error launching test environment") - return testEnvironment + }, "20m", "3s").Should(gomega.Succeed()) } diff --git a/integration-tests/smoke/flux_test.go b/integration-tests/smoke/flux_test.go index b13b078a47d..b76721ac3b3 100644 --- a/integration-tests/smoke/flux_test.go +++ b/integration-tests/smoke/flux_test.go @@ -3,78 +3,54 @@ package smoke import ( "context" "fmt" - "math/big" - "strings" - "testing" - "time" - "github.com/ethereum/go-ethereum/common" "github.com/google/uuid" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" "github.com/smartcontractkit/chainlink-testing-framework/utils" - - "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/stretchr/testify/require" + "math/big" + "strings" + "testing" + "time" ) func TestFluxBasic(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - testEnvironment, testNetwork := setupFluxTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } - - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - nodeAddresses, err := actions.ChainlinkNodeAddresses(chainlinkNodes) - require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Creating mock server client shouldn't fail") - // Register cleanup - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - - chainClient.ParallelTransactions(true) - adapterUUID := uuid.New().String() + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(3). + Build() + require.NoError(t, err) + nodeAddresses, err := env.ChainlinkNodeAddresses() + require.NoError(t, err, "Retrieving on-chain wallet addresses for chainlink nodes shouldn't fail") + env.Geth.EthClient.ParallelTransactions(true) + + adapterUUID := uuid.NewString() adapterPath := fmt.Sprintf("/variable-%s", adapterUUID) - err = mockServer.SetValuePath(adapterPath, 1e5) + err = env.MockServer.Client.SetValuePath(adapterPath, 1e5) require.NoError(t, err, "Setting mockserver value path shouldn't fail") - linkToken, err := contractDeployer.DeployLinkTokenContract() + linkToken, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - fluxInstance, err := contractDeployer.DeployFluxAggregatorContract(linkToken.Address(), contracts.DefaultFluxAggregatorOptions()) + fluxInstance, err := env.Geth.ContractDeployer.DeployFluxAggregatorContract(linkToken.Address(), contracts.DefaultFluxAggregatorOptions()) require.NoError(t, err, "Deploying Flux Aggregator Contract shouldn't fail") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Failed waiting for deployment of flux aggregator contract") err = linkToken.Transfer(fluxInstance.Address(), big.NewInt(1e18)) require.NoError(t, err, "Funding Flux Aggregator Contract shouldn't fail") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Failed waiting for funding of flux aggregator contract") err = fluxInstance.UpdateAvailableFunds() require.NoError(t, err, "Updating the available funds on the Flux Aggregator Contract shouldn't fail") - err = actions.FundChainlinkNodes(chainlinkNodes, chainClient, big.NewFloat(.02)) + err = env.FundChainlinkNodes(big.NewFloat(.02)) require.NoError(t, err, "Funding chainlink nodes with ETH shouldn't fail") err = fluxInstance.SetOracles( @@ -87,19 +63,21 @@ func TestFluxBasic(t *testing.T) { RestartDelayRounds: 0, }) require.NoError(t, err, "Setting oracle options in the Flux Aggregator contract shouldn't fail") - err = chainClient.WaitForEvents() + + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") oracles, err := fluxInstance.GetOracles(context.Background()) require.NoError(t, err, "Getting oracle details from the Flux aggregator contract shouldn't fail") l.Info().Str("Oracles", strings.Join(oracles, ",")).Msg("Oracles set") - adapterFullURL := fmt.Sprintf("%s%s", mockServer.Config.ClusterURL, adapterPath) + adapterFullURL := fmt.Sprintf("%s%s", env.MockServer.Client.Config.ClusterURL, adapterPath) + l.Info().Str("AdapterFullURL", adapterFullURL).Send() bta := &client.BridgeTypeAttributes{ Name: fmt.Sprintf("variable-%s", adapterUUID), URL: adapterFullURL, } - for i, n := range chainlinkNodes { - err = n.MustCreateBridge(bta) + for i, n := range env.CLNodes { + err = n.API.MustCreateBridge(bta) require.NoError(t, err, "Creating bridge shouldn't fail for node %d", i+1) fluxSpec := &client.FluxMonitorJobSpec{ @@ -111,19 +89,18 @@ func TestFluxBasic(t *testing.T) { IdleTimerDisabled: true, ObservationSource: client.ObservationSourceSpecBridge(bta), } - _, err = n.MustCreateJob(fluxSpec) + _, err = n.API.MustCreateJob(fluxSpec) require.NoError(t, err, "Creating flux job shouldn't fail for node %d", i+1) } // initial value set is performed before jobs creation - fluxRoundTimeout := 2 * time.Minute + fluxRoundTimeout := 1 * time.Minute fluxRound := contracts.NewFluxAggregatorRoundConfirmer(fluxInstance, big.NewInt(1), fluxRoundTimeout) - chainClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) - err = chainClient.WaitForEvents() + env.Geth.EthClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") data, err := fluxInstance.GetContractData(context.Background()) require.NoError(t, err, "Getting contract data from flux aggregator contract shouldn't fail") - l.Info().Interface("Data", data).Msg("Round data") require.Equal(t, int64(1e5), data.LatestRoundData.Answer.Int64(), "Expected latest round answer to be %d, but found %d", int64(1e5), data.LatestRoundData.Answer.Int64()) require.Equal(t, int64(1), data.LatestRoundData.RoundId.Int64(), @@ -136,10 +113,10 @@ func TestFluxBasic(t *testing.T) { "Expected allocated funds to be %d, but found %d", int64(3), data.AllocatedFunds.Int64()) fluxRound = contracts.NewFluxAggregatorRoundConfirmer(fluxInstance, big.NewInt(2), fluxRoundTimeout) - chainClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) - err = mockServer.SetValuePath(adapterPath, 1e10) + env.Geth.EthClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) + err = env.MockServer.Client.SetValuePath(adapterPath, 1e10) require.NoError(t, err, "Setting value path in mock server shouldn't fail") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") data, err = fluxInstance.GetContractData(context.Background()) require.NoError(t, err, "Getting contract data from flux aggregator contract shouldn't fail") @@ -159,32 +136,3 @@ func TestFluxBasic(t *testing.T) { "Expected flux aggregator contract's withdrawable payment to be %d, but found %d", int64(2), payment.Int64()) } } - -func setupFluxTest(t *testing.T) (testEnvironment *environment.Environment, testNetwork blockchain.EVMNetwork) { - testNetwork = networks.SelectedNetwork - evmConf := ethereum.New(nil) - if !testNetwork.Simulated { - evmConf = ethereum.New(ðereum.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) - } - baseTOML := `[OCR] -Enabled = true` - cd, err := chainlink.NewDeployment(3, map[string]interface{}{ - "toml": client.AddNetworksConfig(baseTOML, testNetwork), - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-flux-%s", strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(evmConf). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error running test environment") - return testEnvironment, testNetwork -} diff --git a/integration-tests/smoke/runlog_test.go b/integration-tests/smoke/runlog_test.go index 63147763b41..aa90062a2bc 100644 --- a/integration-tests/smoke/runlog_test.go +++ b/integration-tests/smoke/runlog_test.go @@ -3,75 +3,51 @@ package smoke import ( "context" "fmt" - "math/big" - "strings" - "testing" - "github.com/google/uuid" "github.com/onsi/gomega" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" "github.com/smartcontractkit/chainlink-testing-framework/utils" - - "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/stretchr/testify/require" + "math/big" + "strings" + "testing" ) func TestRunLogBasic(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - testEnvironment, testNetwork := setupRunLogTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } - - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Error connecting to mockserver") - err = actions.FundChainlinkNodes(chainlinkNodes, chainClient, big.NewFloat(.01)) + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(1). + Build() + require.NoError(t, err) + + err = env.FundChainlinkNodes(big.NewFloat(.01)) require.NoError(t, err, "Funding chainlink nodes with ETH shouldn't fail") - lt, err := contractDeployer.DeployLinkTokenContract() + lt, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - oracle, err := contractDeployer.DeployOracle(lt.Address()) + oracle, err := env.Geth.ContractDeployer.DeployOracle(lt.Address()) require.NoError(t, err, "Deploying Oracle Contract shouldn't fail") - consumer, err := contractDeployer.DeployAPIConsumer(lt.Address()) + consumer, err := env.Geth.ContractDeployer.DeployAPIConsumer(lt.Address()) require.NoError(t, err, "Deploying Consumer Contract shouldn't fail") - err = chainClient.SetDefaultWallet(0) + err = env.Geth.EthClient.SetDefaultWallet(0) require.NoError(t, err, "Setting default wallet shouldn't fail") err = lt.Transfer(consumer.Address(), big.NewInt(2e18)) require.NoError(t, err, "Transferring %d to consumer contract shouldn't fail", big.NewInt(2e18)) - err = mockServer.SetValuePath("/variable", 5) + err = env.MockServer.Client.SetValuePath("/variable", 5) require.NoError(t, err, "Setting mockserver value path shouldn't fail") jobUUID := uuid.New() bta := client.BridgeTypeAttributes{ Name: fmt.Sprintf("five-%s", jobUUID.String()), - URL: fmt.Sprintf("%s/variable", mockServer.Config.ClusterURL), + URL: fmt.Sprintf("%s/variable", env.MockServer.Client.Config.ClusterURL), } - err = chainlinkNodes[0].MustCreateBridge(&bta) + err = env.CLNodes[0].API.MustCreateBridge(&bta) require.NoError(t, err, "Creating bridge shouldn't fail") os := &client.DirectRequestTxPipelineSpec{ @@ -81,8 +57,8 @@ func TestRunLogBasic(t *testing.T) { ost, err := os.String() require.NoError(t, err, "Building observation source spec shouldn't fail") - _, err = chainlinkNodes[0].MustCreateJob(&client.DirectRequestJobSpec{ - Name: "direct_request", + _, err = env.CLNodes[0].API.MustCreateJob(&client.DirectRequestJobSpec{ + Name: fmt.Sprintf("direct-request-%s", uuid.NewString()), MinIncomingConfirmations: "1", ContractAddress: oracle.Address(), ExternalJobID: jobUUID.String(), @@ -97,7 +73,7 @@ func TestRunLogBasic(t *testing.T) { oracle.Address(), jobID, big.NewInt(1e18), - fmt.Sprintf("%s/variable", mockServer.Config.ClusterURL), + fmt.Sprintf("%s/variable", env.MockServer.Client.Config.ClusterURL), "data,result", big.NewInt(100), ) @@ -112,30 +88,3 @@ func TestRunLogBasic(t *testing.T) { g.Expect(d.Int64()).Should(gomega.BeNumerically("==", 5), "Expected the on-chain data to be 5, but found %d", d.Int64()) }, "2m", "1s").Should(gomega.Succeed()) } - -func setupRunLogTest(t *testing.T) (testEnvironment *environment.Environment, testNetwork blockchain.EVMNetwork) { - testNetwork = networks.SelectedNetwork - evmConfig := ethereum.New(nil) - if !testNetwork.Simulated { - evmConfig = ethereum.New(ðereum.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) - } - cd, err := chainlink.NewDeployment(1, map[string]interface{}{ - "toml": client.AddNetworksConfig("", testNetwork), - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-runlog-%s", strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(evmConfig). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error running test environment") - return testEnvironment, testNetwork -} diff --git a/integration-tests/smoke/vrf_test.go b/integration-tests/smoke/vrf_test.go index 232cb719d25..f3201fe95ad 100644 --- a/integration-tests/smoke/vrf_test.go +++ b/integration-tests/smoke/vrf_test.go @@ -3,71 +3,52 @@ package smoke import ( "context" "fmt" - "math/big" - "strings" - "testing" - "time" - "github.com/google/uuid" "github.com/onsi/gomega" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" - "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/stretchr/testify/require" + "math/big" + "testing" + "time" ) func TestVRFBasic(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - testEnvironment, testNetwork := setupVRFTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } - - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting client shouldn't fail") - cd, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - chainClient.ParallelTransactions(true) - - err = actions.FundChainlinkNodes(chainlinkNodes, chainClient, big.NewFloat(.01)) + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(1). + Build() + require.NoError(t, err) + env.Geth.EthClient.ParallelTransactions(true) + + err = env.FundChainlinkNodes(big.NewFloat(.01)) require.NoError(t, err, "Funding chainlink nodes with ETH shouldn't fail") - lt, err := cd.DeployLinkTokenContract() + lt, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - bhs, err := cd.DeployBlockhashStore() + bhs, err := env.Geth.ContractDeployer.DeployBlockhashStore() require.NoError(t, err, "Deploying Blockhash store shouldn't fail") - coordinator, err := cd.DeployVRFCoordinator(lt.Address(), bhs.Address()) + coordinator, err := env.Geth.ContractDeployer.DeployVRFCoordinator(lt.Address(), bhs.Address()) require.NoError(t, err, "Deploying VRF coordinator shouldn't fail") - consumer, err := cd.DeployVRFConsumer(lt.Address(), coordinator.Address()) + consumer, err := env.Geth.ContractDeployer.DeployVRFConsumer(lt.Address(), coordinator.Address()) require.NoError(t, err, "Deploying VRF consumer contract shouldn't fail") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Failed to wait for VRF setup contracts to deploy") err = lt.Transfer(consumer.Address(), big.NewInt(2e18)) require.NoError(t, err, "Funding consumer contract shouldn't fail") - _, err = cd.DeployVRFContract() + _, err = env.Geth.ContractDeployer.DeployVRFContract() require.NoError(t, err, "Deploying VRF contract shouldn't fail") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") - for _, n := range chainlinkNodes { - nodeKey, err := n.MustCreateVRFKey() + for _, n := range env.CLNodes { + nodeKey, err := n.API.MustCreateVRFKey() require.NoError(t, err, "Creating VRF key shouldn't fail") l.Debug().Interface("Key JSON", nodeKey).Msg("Created proving key") pubKeyCompressed := nodeKey.Data.ID @@ -77,7 +58,7 @@ func TestVRFBasic(t *testing.T) { } ost, err := os.String() require.NoError(t, err, "Building observation source spec shouldn't fail") - job, err := n.MustCreateJob(&client.VRFJobSpec{ + job, err := n.API.MustCreateJob(&client.VRFJobSpec{ Name: fmt.Sprintf("vrf-%s", jobUUID), CoordinatorAddress: coordinator.Address(), MinIncomingConfirmations: 1, @@ -87,7 +68,7 @@ func TestVRFBasic(t *testing.T) { }) require.NoError(t, err, "Creating VRF Job shouldn't fail") - oracleAddr, err := n.PrimaryEthAddress() + oracleAddr, err := n.API.PrimaryEthAddress() require.NoError(t, err, "Getting primary ETH address of chainlink node shouldn't fail") provingKey, err := actions.EncodeOnChainVRFProvingKey(*nodeKey) require.NoError(t, err, "Encoding on-chain VRF Proving key shouldn't fail") @@ -109,7 +90,7 @@ func TestVRFBasic(t *testing.T) { gom := gomega.NewGomegaWithT(t) timeout := time.Minute * 2 gom.Eventually(func(g gomega.Gomega) { - jobRuns, err := chainlinkNodes[0].MustReadRunsByJob(job.Data.ID) + jobRuns, err := env.CLNodes[0].API.MustReadRunsByJob(job.Data.ID) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Job execution shouldn't fail") out, err := consumer.RandomnessOutput(context.Background()) @@ -127,28 +108,3 @@ func TestVRFBasic(t *testing.T) { }, timeout, "1s").Should(gomega.Succeed()) } } - -func setupVRFTest(t *testing.T) (testEnvironment *environment.Environment, testNetwork blockchain.EVMNetwork) { - testNetwork = networks.SelectedNetwork - evmConfig := ethereum.New(nil) - if !testNetwork.Simulated { - evmConfig = ethereum.New(ðereum.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) - } - cd, err := chainlink.NewDeployment(1, map[string]interface{}{ - "toml": client.AddNetworksConfig("", testNetwork), - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-vrf-%s", strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - }). - AddHelm(evmConfig). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error running test environment") - return testEnvironment, testNetwork -} diff --git a/integration-tests/types/envcommon/common.go b/integration-tests/types/envcommon/common.go new file mode 100644 index 00000000000..2bbf5c9bf91 --- /dev/null +++ b/integration-tests/types/envcommon/common.go @@ -0,0 +1,86 @@ +package envcommon + +import ( + "encoding/json" + "fmt" + "github.com/google/uuid" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" + "io/ioutil" + "os" + "time" +) + +type PgOpts struct { + User string + Password string + DbName string + Networks []string + Port string +} + +func NewDefaultPgOpts(dbName string, networks []string) PgOpts { + return PgOpts{ + Port: "5432", + User: "postgres", + Password: "test", + DbName: dbName, + Networks: networks, + } +} + +func GetPgContainerRequest(name string, opts PgOpts) *tc.ContainerRequest { + return &tc.ContainerRequest{ + Name: name, + Image: "postgres:15.3", + ExposedPorts: []string{fmt.Sprintf("%s/tcp", opts.Port)}, + Env: map[string]string{ + "POSTGRES_USER": opts.User, + "POSTGRES_DB": opts.DbName, + "POSTGRES_PASSWORD": opts.Password, + }, + Networks: opts.Networks, + WaitingFor: tcwait.ForExec([]string{"psql", "-h", "localhost", + "-U", opts.User, "-c", "select", "1", "-d", opts.DbName}). + WithStartupTimeout(10 * time.Second), + } +} + +type EnvComponent struct { + ContainerName string + Container tc.Container + Networks []string +} + +type EnvComponentOpts struct { + ReuseContainerName string + Networks []string +} + +func NewEnvComponent(componentType string, opts EnvComponentOpts) EnvComponent { + var name string + if opts.ReuseContainerName != "" { + name = opts.ReuseContainerName + } else { + name = fmt.Sprintf("%s-%s", componentType, uuid.NewString()) + } + + return EnvComponent{ + ContainerName: name, + Networks: opts.Networks, + } +} + +func ParseJSONFile(path string, v any) error { + jsonFile, err := os.Open(path) + if err != nil { + return err + } + defer jsonFile.Close() + b, _ := ioutil.ReadAll(jsonFile) + err = json.Unmarshal(b, v) + if err != nil { + return err + } + return nil +} diff --git a/integration-tests/types/node/node_config.go b/integration-tests/types/node/node_config.go new file mode 100644 index 00000000000..5cd3491598d --- /dev/null +++ b/integration-tests/types/node/node_config.go @@ -0,0 +1,79 @@ +package node + +import ( + "bytes" + "fmt" + "os" + "text/template" +) + +var NodeConfigTemplate = `RootDir = '/home/chainlink' + +[Database] +MaxIdleConns = 20 +MaxOpenConns = 40 +MigrateOnStartup = true + +[Log] +Level = 'debug' +JSONConsole = true + +[WebServer] +AllowOrigins = '*' +HTTPPort = 6688 +SecureCookies = false +SessionTimeout = '999h0m0s' + +[WebServer.TLS] +HTTPSPort = 0 + +[WebServer.RateLimit] +Authenticated = 2000 +Unauthenticated = 100 + +[[EVM]] +ChainID = "1337" +AutoCreateKey = true +finalityDepth = 1 +MinContractPayment = '0' + +[[EVM.Nodes]] +WSURL = "{{ .EVM.WsUrl }}" +HTTPURL = "{{ .EVM.HttpUrl }}" +Name = "1337_primary_local_0" +SendOnly = false + +[Feature] +LogPoller = true +FeedsManager = true +UICSAKeys = true + +[OCR] +Enabled = true + +[P2P] +[P2P.V1] +Enabled = true +ListenIP = '0.0.0.0' +ListenPort = 6690 +` + +type NodeConfigOpts struct { + EVM struct { + HttpUrl string + WsUrl string + } +} + +func ExecuteNodeConfigTemplate(opts NodeConfigOpts) (string, error) { + t, err := template.New("node-config").Parse(NodeConfigTemplate) + if err != nil { + fmt.Println("Error parsing template:", err) + os.Exit(1) + } + + var buf bytes.Buffer + err = t.Execute(&buf, opts) + + return buf.String(), err +} diff --git a/integration-tests/types/types.go b/integration-tests/types/types.go new file mode 100644 index 00000000000..c45c39f480c --- /dev/null +++ b/integration-tests/types/types.go @@ -0,0 +1,52 @@ +package types + +import "github.com/ethereum/go-ethereum/common" + +type MercuryServerType string + +const ( + MS_WSRPC MercuryServerType = "wsrpc" + MS_WS MercuryServerType = "ws" + MS_REST MercuryServerType = "rest" + MS_ALL MercuryServerType = "all" +) + +type MercuryServerOpts struct { + Server struct { + DevMode bool + AutomaticMigrations bool + Service string + Port string + } + RPC struct { + PrivateKey string + NodePubKeys []string + Port string + } + Database struct { + Url string + WriterInstanceUrl string + EncryptionKey string + } + Bootstrap struct { + Username string + Password string + } + WSRPCUrlInternal string + WSRPCUrlExternal string +} + +type User struct { + Id string + Username string + Password string +} + +type MercuryOCRConfig struct { + Signers []common.Address + Transmitters [][32]byte + F uint8 + OnchainConfig []byte + OffchainConfigVersion uint64 + OffchainConfig []byte +} diff --git a/integration-tests/utils/cl_node_jobs.go b/integration-tests/utils/cl_node_jobs.go new file mode 100644 index 00000000000..16b0c167cfe --- /dev/null +++ b/integration-tests/utils/cl_node_jobs.go @@ -0,0 +1,128 @@ +package utils + +import ( + "bytes" + "fmt" + "net/url" + "text/template" + "time" + + "github.com/ethereum/go-ethereum/common" + "github.com/google/uuid" + "github.com/lib/pq" + coreClient "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "gopkg.in/guregu/null.v4" +) + +func BuildBootstrapSpec(verifierAddr common.Address, chainID int64, fromBlock uint64, feedId [32]byte) *coreClient.OCR2TaskJobSpec { + hash := common.BytesToHash(feedId[:]) + return &coreClient.OCR2TaskJobSpec{ + Name: fmt.Sprintf("bootstrap-%s", uuid.NewString()), + JobType: "bootstrap", + OCR2OracleSpec: job.OCR2OracleSpec{ + ContractID: verifierAddr.String(), + Relay: "evm", + FeedID: &hash, + RelayConfig: map[string]interface{}{ + "chainID": int(chainID), + }, + ContractConfigTrackerPollInterval: *models.NewInterval(time.Second * 15), + }, + } +} + +func BuildOCRSpec( + verifierAddr common.Address, chainID int64, fromBlock uint64, + feedId [32]byte, bridges []coreClient.BridgeTypeAttributes, + csaPubKey string, msRemoteUrl string, msPubKey string, + nodeOCRKey string, p2pV2Bootstrapper string, allowedFaults int) *coreClient.OCR2TaskJobSpec { + + tmpl, err := template.New("os").Parse(` +{{range $i, $b := .Bridges}} +{{$b.Name}}_payload [type=bridge name="{{$b.Name}}" timeout="50ms" requestData="{}"]; +{{$b.Name}}_median [type=jsonparse path="data,result"]; +{{$b.Name}}_bid [type=jsonparse path="data,result"]; +{{$b.Name}}_ask [type=jsonparse path="data,result"]; + +{{$b.Name}}_median_multiply [type=multiply times=10]; +{{$b.Name}}_bid_multiply [type=multiply times=10]; +{{$b.Name}}_ask_multiply [type=multiply times=10]; +{{end}} + + +{{range $i, $b := .Bridges}} +{{$b.Name}}_payload -> {{$b.Name}}_median -> {{$b.Name}}_median_multiply -> benchmark_price; +{{end}} + +benchmark_price [type=median allowedFaults={{.AllowedFaults}} index=0]; + +{{range $i, $b := .Bridges}} +{{$b.Name}}_payload -> {{$b.Name}}_bid -> {{$b.Name}}_bid_multiply -> bid_price; +{{end}} + +bid_price [type=median allowedFaults={{.AllowedFaults}} index=1]; + +{{range $i, $b := .Bridges}} +{{$b.Name}}_payload -> {{$b.Name}}_ask -> {{$b.Name}}_ask_multiply -> ask_price; +{{end}} + +ask_price [type=median allowedFaults={{.AllowedFaults}} index=2]; + `) + if err != nil { + panic(err) + } + data := struct { + Bridges []coreClient.BridgeTypeAttributes + AllowedFaults int + }{ + Bridges: bridges, + AllowedFaults: allowedFaults, + } + var buf bytes.Buffer + err = tmpl.Execute(&buf, data) + if err != nil { + panic(err) + } + observationSource := buf.String() + + hash := common.BytesToHash(feedId[:]) + return &coreClient.OCR2TaskJobSpec{ + Name: fmt.Sprintf("ocr2-%s", uuid.NewString()), + JobType: "offchainreporting2", + MaxTaskDuration: "1s", + ForwardingAllowed: false, + OCR2OracleSpec: job.OCR2OracleSpec{ + PluginType: "mercury", + PluginConfig: map[string]interface{}{ + "serverURL": fmt.Sprintf("\"%s\"", msRemoteUrl), + "serverPubKey": fmt.Sprintf("\"%s\"", msPubKey), + }, + Relay: "evm", + RelayConfig: map[string]interface{}{ + "chainID": int(chainID), + "fromBlock": fromBlock, + }, + ContractConfigTrackerPollInterval: *models.NewInterval(time.Second * 15), + ContractID: verifierAddr.String(), + FeedID: &hash, + OCRKeyBundleID: null.StringFrom(nodeOCRKey), + TransmitterID: null.StringFrom(csaPubKey), + P2PV2Bootstrappers: pq.StringArray{p2pV2Bootstrapper}, + }, + ObservationSource: observationSource, + } +} + +func BuildBridges(eaUrls []*url.URL) []coreClient.BridgeTypeAttributes { + var bridges []coreClient.BridgeTypeAttributes + for _, url := range eaUrls { + bridges = append(bridges, coreClient.BridgeTypeAttributes{ + Name: fmt.Sprintf("bridge_%s", uuid.NewString()[0:6]), + URL: url.String(), + RequestData: "{}", + }) + } + return bridges +} diff --git a/integration-tests/utils/log.go b/integration-tests/utils/log.go new file mode 100644 index 00000000000..a86333cc882 --- /dev/null +++ b/integration-tests/utils/log.go @@ -0,0 +1,19 @@ +package utils + +import ( + "github.com/rs/zerolog" + "github.com/rs/zerolog/log" + "os" +) + +func SetupGlobalLogger() { + lvlStr := os.Getenv("GLOBAL_LOG_LEVEL") + if lvlStr == "" { + lvlStr = "info" + } + lvl, err := zerolog.ParseLevel(lvlStr) + if err != nil { + panic(err) + } + log.Logger = log.Output(zerolog.ConsoleWriter{Out: os.Stderr}).Level(lvl) +} diff --git a/integration-tests/utils/templates/geth.go b/integration-tests/utils/templates/geth.go new file mode 100644 index 00000000000..db4eee1c1d6 --- /dev/null +++ b/integration-tests/utils/templates/geth.go @@ -0,0 +1,71 @@ +package templates + +import ( + "bytes" + "fmt" + "os" + "text/template" +) + +var InitGethScript = ` +#!/bin/bash +if [ ! -d /root/.ethereum/keystore ]; then + echo "/root/.ethereum/keystore not found, running 'geth init'..." + geth init /root/genesis.json + echo "...done!" +fi + +geth "$@" +` + +var GenesisJson = ` +{ + "config": { + "chainId": {{ .ChainId }}, + "homesteadBlock": 0, + "eip150Block": 0, + "eip155Block": 0, + "eip158Block": 0, + "eip160Block": 0, + "byzantiumBlock": 0, + "constantinopleBlock": 0, + "petersburgBlock": 0, + "istanbulBlock": 0, + "muirGlacierBlock": 0, + "berlinBlock": 0, + "londonBlock": 0 + }, + "nonce": "0x0000000000000042", + "mixhash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "difficulty": "1", + "coinbase": "0x3333333333333333333333333333333333333333", + "parentHash": "0x0000000000000000000000000000000000000000000000000000000000000000", + "extraData": "0x", + "gasLimit": "8000000000", + "alloc": { + "{{ .AccountAddr }}": { + "balance": "20000000000000000000000" + } + } + }` + +func BuildGenesisJson(chainId, accountAddr string) (string, error) { + data := struct { + AccountAddr string + ChainId string + }{ + AccountAddr: accountAddr, + ChainId: chainId, + } + + t, err := template.New("genesis-json").Parse(GenesisJson) + if err != nil { + fmt.Println("Error parsing template:", err) + os.Exit(1) + } + + var buf bytes.Buffer + err = t.Execute(&buf, data) + + return buf.String(), err +} diff --git a/integration-tests/utils/templates/node_secrets.go b/integration-tests/utils/templates/node_secrets.go new file mode 100644 index 00000000000..2bc3235715e --- /dev/null +++ b/integration-tests/utils/templates/node_secrets.go @@ -0,0 +1,44 @@ +package templates + +import ( + "bytes" + "fmt" + "os" + "text/template" +) + +var NodeSecretsTemplate = ` +[Database] +URL = 'postgresql://postgres:test@{{ .PgHost }}:{{ .PgPort }}/cl-node?sslmode=disable' # Required +AllowSimplePasswords = true + +[Password] +Keystore = '................' # Required + +[Mercury.Credentials.cred1] +# URL = 'http://host.docker.internal:3000/reports' +URL = 'localhost:1338' +Username = 'node' +Password = 'nodepass' +` + +func ExecuteNodeSecretsTemplate(pgHost string, pgPort string) (string, error) { + data := struct { + PgHost string + PgPort string + }{ + PgHost: pgHost, + PgPort: pgPort, + } + + t, err := template.New("node-secrets").Parse(NodeSecretsTemplate) + if err != nil { + fmt.Println("Error parsing template:", err) + os.Exit(1) + } + + var buf bytes.Buffer + err = t.Execute(&buf, data) + + return buf.String(), err +} From 83868a7b7fc453cb9cd5dded46bd9e77229b4170 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Tue, 1 Aug 2023 13:16:59 -0400 Subject: [PATCH 051/270] release/2.3.0 -> develop (#9975) * Bump version and update CHANGELOG for core v2.3.0 * Add base config (#9865) * Add base config * Updated Docs * Base goerli config to match Optimism goerli --------- Co-authored-by: simsonraj (cherry picked from commit ee724fc32951f2c8f7f234695afc4dbf0591eeea) * Base(Mainnet) + Optimism hotfix (#9862) * Base(Mainnet) + Optimism hotfix * Revert "Base(Mainnet) + Optimism hotfix" This reverts commit a13e8487eff0935b3eacf78bc020288842028c96. * Base+ optimism hotfix for non-successfull ocr rounds * fix tests (cherry picked from commit 38e9e4a0ba0e19e6a87a258e10c850921f2301c9) * Added automation gaslimit for Base (#9878) (cherry picked from commit 22a60fbcad22367cca4d1ec7604b169e3a38108f) * re run config docs generate * Finalize date on changelog for 2.3.0 --------- Co-authored-by: David Cauchi <13139524+davidcauchi@users.noreply.github.com> Co-authored-by: Simson --- docs/CHANGELOG.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 38ec4d263d7..bd0ff534a6a 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -18,7 +18,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. -## 2.3.0 - UNRELEASED + + +## 2.3.0 - 2023-07-28 ### Added - Add a new field called `Order` (range from 1 to 100) to `EVM.Nodes` that is used for the `PriorityLevel` node selector and also as a tie-breaker for `HighestHead` and `TotalDifficulty`. `Order` levels are considered in ascending order. If not defined it will default to `Order = 100` (last level). @@ -73,8 +75,6 @@ Node operators may wish to add alerting based around these metrics. - Legacy chain types Optimism and Optimism2. OptimismBedrock is now used to handle Optimism's special cases. - Optimism Kovan configurations along with legacy error messages. - - # 2.2.0 - 2023-06-12 ### Added From 1d3fa2235c268c25fc3c6e2f6cbc11fbf5858936 Mon Sep 17 00:00:00 2001 From: AJ Grande Date: Tue, 1 Aug 2023 13:33:45 -0400 Subject: [PATCH 052/270] feat: use upstream golanci-lint-action and bump to latest (v1.53.3) (#10024) --- .github/workflows/ci-core.yml | 9 ++------- .tool-versions | 2 +- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index db8533b44ea..a710fbfb64c 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -78,15 +78,10 @@ jobs: cache: false - name: golangci-lint if: needs.init.outputs.on_trigger_lint == 'true' - ## - # XXX: change this to the official action once multiple --out-format args are supported. - # See: https://github.com/golangci/golangci-lint-action/issues/612 - ## - uses: smartcontractkit/golangci-lint-action@54ab6c5f11d66a92d14c3f7cc41ea13f676644bd # feature/multiple-output-formats-backup + uses: golangci/golangci-lint-action@639cd343e1d3b897ff35927a75193d57cfcba299 # v3.6.0 with: - version: v1.53.2 + version: v1.53.3 only-new-issues: ${{ github.event.schedule == '' }} # show only new issues, unless it's a scheduled run - allow-extra-out-format-args: true args: --out-format checkstyle:golangci-lint-report.xml - name: Print lint report artifact if: always() diff --git a/.tool-versions b/.tool-versions index 33d3adb2849..c7deac35bf5 100644 --- a/.tool-versions +++ b/.tool-versions @@ -4,5 +4,5 @@ nodejs 16.16.0 postgres 13.3 helm 3.10.3 zig 0.10.1 -golangci-lint 1.53.2 +golangci-lint 1.53.3 shellspec 0.28.1 From d7872def491a905472c5b1df2712f812a8c64d0f Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Tue, 1 Aug 2023 14:17:40 -0400 Subject: [PATCH 053/270] [Functions] Various v1 improvements (#9991) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Move FulfillResultCodes to interfaces folder * Rename Function.sol setArgs -> addArgs * Rename Routable s_config_hash -> s_configHash * Make Routable updateConfig public for re-use in constructor * Move comment out of IConfigurable * Make Routable s_router private with an internal getter * Rename constant to ROUTER_ID * Rename RouterBase s_config_hash -> s_configHash * Rename Routable.sol -> HasRouter.sol * Add IOwnableRouter interface * FunctionsSubscriptions MustBeSubOwner -> MustBeSubscriptionOwner * Make RouterBase variable private * RouterBase togglePause -> pause/unpause * Use full semantic version in typeAndVersion * ToS Allow List rename proof -> signature * Change acceptTermsOfService arguments from signature to raw r,s,v * Prettier format 💅 * Remove RouterBase versioning * Move RequestTimedOut event to Router * Rename requestSubscriptionOwnerTransfer -> proposeSubscriptionOwnerTransfer * (test): Update tests for changes * (test): Add v0 gas test * Regenerate geth wrappers * use ConfirmedOwner and uint256 * Revert _handleConfigUpdate * Add RequestDeleted event to FunctionsBilling * Use uint256 in loops * Use separate import for ITypeAndVersion * Use public constants for typeAndVersion getters * (test): Use v0.8 mocks * Regen geth wrappers --------- Co-authored-by: Rens Rooimans --- .../v0.8/functions/dev/1_0_0/Functions.sol | 8 +- .../functions/dev/1_0_0/FunctionsBilling.sol | 24 +- .../dev/1_0_0/FunctionsCoordinator.sol | 8 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 4 +- .../dev/1_0_0/FunctionsSubscriptions.sol | 25 +- .../dev/1_0_0/{Routable.sol => HasRouter.sol} | 26 +- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 90 +- .../accessControl/TermsOfServiceAllowList.sol | 67 +- .../interfaces/ITermsOfServiceAllowList.sol | 6 +- .../1_0_0/example/FunctionsClientExample.sol | 2 +- .../{ => interfaces}/FulfillResultCodes.sol | 0 .../dev/1_0_0/interfaces/IConfigurable.sol | 1 - .../interfaces/IFunctionsSubscriptions.sol | 6 +- .../dev/1_0_0/interfaces/IOwnableRouter.sol | 12 + .../dev/1_0_0/interfaces/IRouterBase.sol | 19 +- .../testhelpers/FunctionsClientTestHelper.sol | 4 +- .../1_0_0/testhelpers/FunctionsTestHelper.sol | 4 +- .../v0/FunctionsBillingRegistry.test.ts | 4 +- ...unctionsBillingRegistryUpgradeable.test.ts | 4 +- .../v0.8/functions/v0/FunctionsClient.test.ts | 4 +- .../v0.8/functions/v0/FunctionsOracle.test.ts | 4 +- .../v0/FunctionsOracleUpgradeable.test.ts | 4 +- contracts/test/v0.8/functions/v0/Gas.test.ts | 158 +++ .../v0.8/functions/v1/FunctionsRouter.test.ts | 2 +- .../v1/FunctionsSubscriptions.test.ts | 1109 +++++++++-------- .../test/v0.8/functions/v1/GasGolf.test.ts | 15 +- .../test/v0.8/functions/v1/RouterBase.test.ts | 44 +- .../v1/TermsOfServiceAllowList.test.ts | 29 +- contracts/test/v0.8/functions/v1/utils.ts | 11 +- .../functions_allow_list.go | 18 +- .../functions_coordinator.go | 272 ++-- .../functions_router/functions_router.go | 244 +++- ...rapper-dependency-versions-do-not-edit.txt | 6 +- .../v1/internal/testutils.go | 10 +- 34 files changed, 1233 insertions(+), 1011 deletions(-) rename contracts/src/v0.8/functions/dev/1_0_0/{Routable.sol => HasRouter.sol} (67%) rename contracts/src/v0.8/functions/dev/1_0_0/{ => interfaces}/FulfillResultCodes.sol (100%) create mode 100644 contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol create mode 100644 contracts/test/v0.8/functions/v0/Gas.test.ts diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol b/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol index 3f84fb3d358..8a3dc336bc7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol @@ -150,22 +150,22 @@ library Functions { } /** - * @notice Adds args for the user run function + * @notice Sets args for the user run function * @param self The initialized request * @param args The array of string args (must not be empty) */ - function addArgs(Request memory self, string[] memory args) internal pure { + function setArgs(Request memory self, string[] memory args) internal pure { if (args.length == 0) revert EmptyArgs(); self.args = args; } /** - * @notice Adds bytes args for the user run function + * @notice Sets bytes args for the user run function * @param self The initialized request * @param args The array of bytes args (must not be empty) */ - function addBytesArgs(Request memory self, bytes[] memory args) internal pure { + function setBytesArgs(Request memory self, bytes[] memory args) internal pure { if (args.length == 0) revert EmptyArgs(); self.bytesArgs = args; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 1275adee2a7..9e830ed1150 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -1,19 +1,19 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {Routable} from "./Routable.sol"; +import {HasRouter} from "./HasRouter.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; -import {FulfillResult} from "./FulfillResultCodes.sol"; +import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; /** * @title Functions Billing contract * @notice Contract that calculates payment from users to the nodes of the Decentralized Oracle Network (DON). * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ -abstract contract FunctionsBilling is Routable, IFunctionsBilling { +abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { // ================================================================ // | Request Commitment state | // ================================================================ @@ -32,7 +32,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } mapping(bytes32 requestId => Commitment) private s_requestCommitments; - event RequestTimedOut(bytes32 indexed requestId); + event CommitmentDeleted(bytes32 requestId); // ================================================================ // | Configuration state | @@ -113,7 +113,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ // | Initialization | // ================================================================ - constructor(address router, bytes memory config, address linkToNativeFeed) Routable(router, config) { + constructor(address router, bytes memory config, address linkToNativeFeed) HasRouter(router, config) { s_linkToNativeFeed = AggregatorV3Interface(linkToNativeFeed); } @@ -221,7 +221,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { RequestBilling memory /* billing */ ) public view override returns (uint96) { // NOTE: Optionally, compute additional fee here - return IFunctionsRouter(address(s_router)).getAdminFee(); + return IFunctionsRouter(address(_getRouter())).getAdminFee(); } function getFeedData() public view returns (int256) { @@ -248,7 +248,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint256 gasPrice ) external view override returns (uint96) { // Reasonable ceilings to prevent integer overflows - IFunctionsRouter router = IFunctionsRouter(address(s_router)); + IFunctionsRouter router = IFunctionsRouter(address(_getRouter())); router.isValidCallbackGasLimit(subscriptionId, callbackGasLimit); if (gasPrice > 1_000_000) { revert InvalidCalldata(); @@ -313,7 +313,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint80 donFee = getDONFee(data, billing); uint96 adminFee = getAdminFee(data, billing); uint96 estimatedCost = _calculateCostEstimate(billing.callbackGasLimit, billing.expectedGasPrice, donFee, adminFee); - IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(s_router)); + IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(_getRouter())); (uint96 balance, uint96 blockedBalance, , , ) = subscriptions.getSubscription(billing.subscriptionId); (, uint64 initiatedRequests, ) = subscriptions.getConsumer(billing.client, billing.subscriptionId); @@ -392,7 +392,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint96 costWithoutFulfillment = gasOverheadJuels + commitment.donFee; // The Functions Router will perform the callback to the client contract - IFunctionsRouter router = IFunctionsRouter(address(s_router)); + IFunctionsRouter router = IFunctionsRouter(address(_getRouter())); (uint8 result, uint96 callbackCostJuels) = router.fulfill( requestId, response, @@ -434,7 +434,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } // Delete commitment delete s_requestCommitments[requestId]; - emit RequestTimedOut(requestId); + emit CommitmentDeleted(requestId); return true; } @@ -458,7 +458,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { revert InsufficientBalance(); } s_withdrawableTokens[msg.sender] -= amount; - IFunctionsSubscriptions router = IFunctionsSubscriptions(address(s_router)); + IFunctionsSubscriptions router = IFunctionsSubscriptions(address(_getRouter())); router.oracleWithdraw(recipient, amount); } @@ -471,7 +471,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } uint96 feePoolShare = s_feePool / uint96(transmitters.length); // Bounded by "maxNumOracles" on OCR2Abstract.sol - for (uint8 i = 0; i < transmitters.length; ++i) { + for (uint256 i = 0; i < transmitters.length; ++i) { s_withdrawableTokens[transmitters[i]] += feePoolShare; } s_feePool -= feePoolShare * uint96(transmitters.length); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 0b2e4fcf3bf..33d9a569bc9 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -4,8 +4,8 @@ pragma solidity ^0.8.19; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {IFunctionsBilling, FunctionsBilling} from "./FunctionsBilling.sol"; import {OCR2Base} from "./ocr/OCR2Base.sol"; -import {FulfillResult} from "./FulfillResultCodes.sol"; -import {ITypeAndVersion} from "./Routable.sol"; +import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; +import {ITypeAndVersion} from "./HasRouter.sol"; /** * @title Functions Coordinator contract @@ -48,9 +48,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli /** * @inheritdoc ITypeAndVersion */ - function typeAndVersion() public pure override returns (string memory) { - return "Functions Coordinator v1"; - } + string public constant override typeAndVersion = "Functions Coordinator v1.0.0"; /** * @inheritdoc IFunctionsCoordinator diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index e188e6f5259..13fd3480dae 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -83,9 +83,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions /** * @inheritdoc ITypeAndVersion */ - function typeAndVersion() public pure override returns (string memory) { - return "Functions Router v1"; - } + string public constant override typeAndVersion = "Functions Router v1.0.0"; /** * @inheritdoc IFunctionsRouter diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index b39ad1cad12..4eba036d07a 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -57,7 +57,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei error InvalidSubscription(); error OnlyCallableFromLink(); error InvalidCalldata(); - error MustBeSubOwner(); + error MustBeSubscriptionOwner(); error PendingRequestExists(); error MustBeRequestedOwner(address proposedOwner); error BalanceInvariantViolated(uint256 internalBalance, uint256 externalBalance); // Should never happen @@ -88,6 +88,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei uint96 totalCostJuels; } + event RequestTimedOut(bytes32 indexed requestId); + // ================================================================ // | Initialization | // ================================================================ @@ -350,7 +352,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function requestSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { + function proposeSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _onlySenderThatAcceptedToS(); @@ -517,7 +519,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _isValidSubscription(subscriptionId); address owner = s_subscriptions[subscriptionId].owner; if (msg.sender != owner) { - revert MustBeSubOwner(); + revert MustBeSubscriptionOwner(); } // Check that request has exceeded allowed request time @@ -526,14 +528,15 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } IFunctionsBilling coordinator = IFunctionsBilling(request.coordinator); + coordinator.deleteCommitment(requestId); - if (coordinator.deleteCommitment(requestId)) { - // Release blocked balance - s_subscriptions[subscriptionId].blockedBalance -= request.estimatedCost; - s_consumers[request.client][subscriptionId].completedRequests += 1; - // Delete commitment - delete s_requestCommitments[requestId]; - } + // Release blocked balance + s_subscriptions[subscriptionId].blockedBalance -= request.estimatedCost; + s_consumers[request.client][subscriptionId].completedRequests += 1; + // Delete commitment + delete s_requestCommitments[requestId]; + + emit RequestTimedOut(requestId); } } @@ -547,7 +550,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei revert InvalidSubscription(); } if (msg.sender != owner) { - revert MustBeSubOwner(); + revert MustBeSubscriptionOwner(); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol similarity index 67% rename from contracts/src/v0.8/functions/dev/1_0_0/Routable.sol rename to contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol index cb0eb348d49..9cef8e1d8d4 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol @@ -4,13 +4,12 @@ pragma solidity ^0.8.19; import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; -import {IRouterBase} from "./interfaces/IRouterBase.sol"; -import {IOwnable} from "../../../shared/interfaces/IOwnable.sol"; +import {IOwnableRouter} from "./interfaces/IOwnableRouter.sol"; -abstract contract Routable is ITypeAndVersion, IConfigurable { - bytes32 internal s_config_hash; +abstract contract HasRouter is ITypeAndVersion, IConfigurable { + bytes32 internal s_configHash; - IRouterBase internal immutable s_router; + IOwnableRouter internal immutable s_router; error RouterMustBeSet(); error OnlyCallableByRouter(); @@ -23,16 +22,20 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { if (router == address(0)) { revert RouterMustBeSet(); } - s_router = IRouterBase(router); + s_router = IOwnableRouter(router); _updateConfig(config); - s_config_hash = keccak256(config); + s_configHash = keccak256(config); + } + + function _getRouter() internal view returns (IOwnableRouter router) { + return s_router; } /** * @inheritdoc IConfigurable */ function getConfigHash() external view override returns (bytes32 config) { - return s_config_hash; + return s_configHash; } /** @@ -43,10 +46,11 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { /** * @inheritdoc IConfigurable + * @dev Only callable by the Router */ - function updateConfig(bytes memory config) external override onlyRouter { + function updateConfig(bytes memory config) public override onlyRouter { _updateConfig(config); - s_config_hash = keccak256(config); + s_configHash = keccak256(config); } /** @@ -63,7 +67,7 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { * @notice Reverts if called by anyone other than the router owner. */ modifier onlyRouterOwner() { - if (msg.sender != IOwnable(address(s_router)).owner()) { + if (msg.sender != s_router.owner()) { revert OnlyCallableByRouterOwner(); } _; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index 81754d49ad7..a8a7985ca62 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -1,26 +1,28 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IRouterBase} from "./interfaces/IRouterBase.sol"; -import {ConfirmedOwnerWithProposal} from "../../../ConfirmedOwnerWithProposal.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; -import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; +import {IRouterBase} from "./interfaces/IRouterBase.sol"; import {IConfigurable} from "./interfaces/IConfigurable.sol"; -abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, ConfirmedOwnerWithProposal { +import {ConfirmedOwner} from "../../../ConfirmedOwner.sol"; + +import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; + +abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, ConfirmedOwner { // ================================================================ // | Route state | // ================================================================ mapping(bytes32 id => address routableContract) internal s_route; error RouteNotFound(bytes32 id); // Use empty bytes to self-identify, since it does not have an id - bytes32 internal constant routerId = bytes32(0); + bytes32 private constant ROUTER_ID = bytes32(0); // ================================================================ // | Proposal state | // ================================================================ - uint8 internal constant MAX_PROPOSAL_SET_LENGTH = 8; + uint8 private constant MAX_PROPOSAL_SET_LENGTH = 8; struct ContractProposalSet { bytes32[] ids; @@ -35,13 +37,11 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme address proposedContractSetToAddress, uint256 timelockEndBlock ); + event ContractUpdated( bytes32 proposedContractSetId, address proposedContractSetFromAddress, - address proposedContractSetToAddress, - uint16 major, - uint16 minor, - uint16 patch + address proposedContractSetToAddress ); struct ConfigProposal { @@ -49,7 +49,8 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme bytes to; uint256 timelockEndBlock; } - mapping(bytes32 id => ConfigProposal) internal s_proposedConfig; + + mapping(bytes32 id => ConfigProposal) private s_proposedConfig; event ConfigProposed(bytes32 id, bytes32 fromHash, bytes toBytes); event ConfigUpdated(bytes32 id, bytes32 fromHash, bytes toBytes); error InvalidProposal(); @@ -59,24 +60,17 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // | Config state | // ================================================================ - bytes32 internal s_config_hash; + bytes32 internal s_configHash; error InvalidConfigData(); TimeLockProposal internal s_timelockProposal; - // ================================================================ - // | Version state | - // ================================================================ - - uint16 internal constant s_majorVersion = 1; - uint16 internal s_minorVersion = 0; - uint16 internal s_patchVersion = 0; // ================================================================ // | Timelock state | // ================================================================ - uint16 internal s_maximumTimelockBlocks; + uint16 private immutable s_maximumTimelockBlocks; uint16 internal s_timelockBlocks; struct TimeLockProposal { @@ -99,27 +93,15 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme uint16 timelockBlocks, uint16 maximumTimelockBlocks, bytes memory selfConfig - ) ConfirmedOwnerWithProposal(newOwner, address(0)) Pausable() { + ) ConfirmedOwner(newOwner) Pausable() { // Set initial value for the number of blocks of the timelock s_timelockBlocks = timelockBlocks; // Set maximum number of blocks that the timelock can be - // NOTE: this cannot be later modified s_maximumTimelockBlocks = maximumTimelockBlocks; // Set the initial configuration for the Router - s_route[routerId] = address(this); + s_route[ROUTER_ID] = address(this); _updateConfig(selfConfig); - s_config_hash = keccak256(selfConfig); - } - - // ================================================================ - // | Version methods | - // ================================================================ - - /** - * @inheritdoc IRouterBase - */ - function version() external view override returns (uint16, uint16, uint16) { - return (s_majorVersion, s_minorVersion, s_patchVersion); + s_configHash = keccak256(selfConfig); } // ================================================================ @@ -134,7 +116,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme } } else { // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { + for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { if (id == s_proposedContractSet.ids[i]) { // NOTE: proposals can be used immediately return s_proposedContractSet.to[i]; @@ -181,7 +163,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme revert InvalidProposal(); } // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < idsArrayLength; ++i) { + for (uint256 i = 0; i < idsArrayLength; ++i) { bytes32 id = proposedContractSetIds[i]; address proposedContract = proposedContractSetAddresses[i]; if ( @@ -191,7 +173,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme revert InvalidProposal(); } // Reserved ids cannot be set - if (id == routerId) { + if (id == ROUTER_ID) { revert IdentifierIsReserved(id); } } @@ -201,7 +183,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme s_proposedContractSet = ContractProposalSet(proposedContractSetIds, proposedContractSetAddresses, timelockEndBlock); // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < proposedContractSetIds.length; ++i) { + for (uint256 i = 0; i < proposedContractSetIds.length; ++i) { emit ContractProposed( proposedContractSetIds[i], s_route[proposedContractSetIds[i]], @@ -231,15 +213,13 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme if (block.number < s_proposedContractSet.timelockEndBlock) { revert TimelockInEffect(); } - s_minorVersion = s_minorVersion + 1; - if (s_patchVersion != 0) s_patchVersion = 0; // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { + for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { bytes32 id = s_proposedContractSet.ids[i]; address from = s_route[id]; address to = s_proposedContractSet.to[i]; s_route[id] = to; - emit ContractUpdated(id, from, to, s_majorVersion, s_minorVersion, s_patchVersion); + emit ContractUpdated(id, from, to); } } @@ -251,7 +231,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme * @return config hash of config bytes */ function getConfigHash() external view returns (bytes32 config) { - return s_config_hash; + return s_configHash; } /** @@ -267,7 +247,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme address implAddr = _getContractById(id, false); bytes32 currentConfigHash; if (implAddr == address(this)) { - currentConfigHash = s_config_hash; + currentConfigHash = s_configHash; } else { currentConfigHash = IConfigurable(implAddr).getConfigHash(); } @@ -286,15 +266,14 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme if (block.number < proposal.timelockEndBlock) { revert TimelockInEffect(); } - if (id == routerId) { + if (id == ROUTER_ID) { _updateConfig(proposal.to); - s_config_hash = keccak256(proposal.to); + s_configHash = keccak256(proposal.to); } else { try IConfigurable(_getContractById(id, false)).updateConfig(proposal.to) {} catch { revert InvalidConfigData(); } } - s_patchVersion = s_patchVersion + 1; emit ConfigUpdated(id, proposal.fromHash, proposal.to); } @@ -339,11 +318,14 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme /** * @inheritdoc IRouterBase */ - function togglePaused() external override onlyOwner { - if (Pausable.paused()) { - _unpause(); - } else { - _pause(); - } + function pause() external override onlyOwner { + _pause(); + } + + /** + * @inheritdoc IRouterBase + */ + function unpause() external override onlyOwner { + _unpause(); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index a3b49a35a9c..ec966b7730f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -2,8 +2,9 @@ pragma solidity ^0.8.19; import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.sol"; -import {Routable, ITypeAndVersion} from "../Routable.sol"; +import {HasRouter} from "../HasRouter.sol"; import {IAccessController} from "../../../../shared/interfaces/IAccessController.sol"; +import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol"; import {Address} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol"; import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; @@ -11,14 +12,15 @@ import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/con /** * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service */ -contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessController { +contract TermsOfServiceAllowList is HasRouter, ITermsOfServiceAllowList, IAccessController { using Address for address; using EnumerableSet for EnumerableSet.AddressSet; EnumerableSet.AddressSet private s_allowedSenders; mapping(address => bool) private s_blockedSenders; - error InvalidProof(); + error InvalidSignature(); + error InvalidUsage(); error RecipientIsBlocked(); // ================================================================ @@ -27,7 +29,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC struct Config { bool enabled; - address proofSignerPublicKey; + address signerPublicKey; } Config private s_config; @@ -38,7 +40,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC // | Initialization | // ================================================================ - constructor(address router, bytes memory config) Routable(router, config) {} + constructor(address router, bytes memory config) HasRouter(router, config) {} // ================================================================ // | Configuration methods | @@ -48,20 +50,18 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC * @notice Sets the configuration * @param config bytes of config data to set the following: * - enabled: boolean representing if the allow list is active, when disabled all usage will be allowed - * - proofSignerPublicKey: public key of the signer of the proof + * - signerPublicKey: public key of the signer of the proof */ function _updateConfig(bytes memory config) internal override { - (bool enabled, address proofSignerPublicKey) = abi.decode(config, (bool, address)); - s_config = Config({enabled: enabled, proofSignerPublicKey: proofSignerPublicKey}); + (bool enabled, address signerPublicKey) = abi.decode(config, (bool, address)); + s_config = Config({enabled: enabled, signerPublicKey: signerPublicKey}); emit ConfigSet(enabled); } /** * @inheritdoc ITypeAndVersion */ - function typeAndVersion() public pure override returns (string memory) { - return "Functions Terms of Service Allow List v1"; - } + string public constant override typeAndVersion = "Functions Terms of Service Allow List v1.0.0"; // ================================================================ // | Terms of Service methods | @@ -84,16 +84,14 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC /** * @inheritdoc ITermsOfServiceAllowList */ - function acceptTermsOfService(address acceptor, address recipient, bytes calldata proof) external override { + function acceptTermsOfService(address acceptor, address recipient, bytes32 r, bytes32 s, uint8 v) external override { if (s_blockedSenders[recipient]) { revert RecipientIsBlocked(); } - // Validate that the proof is correct and has been signed - if ( - _getSigner(getEthSignedMessageHash(getMessageHash(acceptor, recipient)), proof) != s_config.proofSignerPublicKey - ) { - revert InvalidProof(); + // Validate that the signature is correct and the correct data has been signed + if (ecrecover(getEthSignedMessageHash(getMessageHash(acceptor, recipient)), v, r, s) != s_config.signerPublicKey) { + revert InvalidSignature(); } // If contract, validate that msg.sender == recipient @@ -101,7 +99,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC // If EoA, validate that msg.sender == acceptor == recipient // This is to prevent EoAs from accepting for other EoAs if (msg.sender != recipient || (msg.sender != acceptor && !msg.sender.isContract())) { - revert InvalidProof(); + revert InvalidUsage(); } // Add recipient to the allow list @@ -153,37 +151,4 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC function unblockSender(address sender) external override onlyRouterOwner { s_blockedSenders[sender] = false; } - - // ================================================================ - // | Signature checking | - // ================================================================ - - function _getSigner(bytes32 _ethSignedMessageHash, bytes memory signature) private pure returns (address) { - bytes32 r; - bytes32 s; - uint8 v; - - if (signature.length != 65) { - revert InvalidProof(); - } - // solhint-disable-next-line no-inline-assembly - assembly { - /*/ - First 32 bytes stores the length of the signature - - add(sig, 32) = pointer of sig + 32 - effectively, skips first 32 bytes of signature - - mload(p) loads next 32 bytes starting at the memory address p into memory - */ - // first 32 bytes, after the length prefix - r := mload(add(signature, 32)) - // second 32 bytes - s := mload(add(signature, 64)) - // final byte (first byte of the next 32 bytes) - v := byte(0, mload(add(signature, 96))) - } - - return ecrecover(_ethSignedMessageHash, v, r, s); - } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol index b3093520bc0..e9388335e01 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol @@ -42,9 +42,11 @@ interface ITermsOfServiceAllowList { * @notice Allows access to the sender based on acceptance of the Terms of Service * @param acceptor - The wallet address that has accepted the Terms of Service on the UI * @param recipient - The recipient address that the acceptor is taking responsibility for - * @param proof - Signed data produced by the Chainlink Functions Subscription UI + * @param r - ECDSA signature r data produced by the Chainlink Functions Subscription UI + * @param s - ECDSA signature s produced by the Chainlink Functions Subscription UI + * @param v - ECDSA signature v produced by the Chainlink Functions Subscription UI */ - function acceptTermsOfService(address acceptor, address recipient, bytes calldata proof) external; + function acceptTermsOfService(address acceptor, address recipient, bytes32 r, bytes32 s, uint8 v) external; /** * @notice Removes a sender's access if already authorized, and disallows re-accepting the Terms of Service diff --git a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol index 27d7102fff8..fec5a2bfa49 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol @@ -40,7 +40,7 @@ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { Functions.Request memory req; req.initializeRequestForInlineJavaScript(source); if (encryptedSecretsReferences.length > 0) req.addSecretsReference(encryptedSecretsReferences); - if (args.length > 0) req.addArgs(args); + if (args.length > 0) req.setArgs(args); s_lastRequestId = _sendRequest(req, subscriptionId, MAX_CALLBACK_GAS, jobId); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FulfillResultCodes.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol similarity index 100% rename from contracts/src/v0.8/functions/dev/1_0_0/FulfillResultCodes.sol rename to contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol index 6348143d83e..4aebd575498 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol @@ -13,7 +13,6 @@ interface IConfigurable { /** * @notice Set the contract's configuration - * @dev Only callable by the Router * @param config bytes containing config data */ function updateConfig(bytes calldata config) external; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 55c70187d5b..f483a15578b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -119,15 +119,15 @@ interface IFunctionsSubscriptions { function createSubscription() external returns (uint64); /** - * @notice Request subscription owner transfer. + * @notice Propose a new owner for a subscription. * @dev Only callable by the Subscription's owner * @param subscriptionId - ID of the subscription * @param newOwner - proposed new owner of the subscription */ - function requestSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external; + function proposeSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external; /** - * @notice Request subscription owner transfer. + * @notice Accept an ownership transfer. * @param subscriptionId - ID of the subscription * @dev will revert if original owner of subscriptionId has * not requested that msg.sender become the new owner. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol new file mode 100644 index 00000000000..5d98f610ace --- /dev/null +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol @@ -0,0 +1,12 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {IRouterBase} from "./IRouterBase.sol"; +import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; + +/** + * @title Chainlink base Router interface with Ownable. + */ +interface IOwnableRouter is IOwnable, IRouterBase { + +} diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol index a88a8b12598..7e6d6f0c3dd 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol @@ -5,15 +5,6 @@ pragma solidity ^0.8.19; * @title Chainlink base Router interface. */ interface IRouterBase { - /** - * @notice Returns the latest semantic version of the system - * @dev See https://semver.org/ for more details - * @return major The current major version number - * @return minor The current minor version number - * @return patch The current patch version number - */ - function version() external view returns (uint16 major, uint16 minor, uint16 patch); - /** * @notice Get the current contract given an ID * @param id A bytes32 identifier for the route @@ -88,8 +79,14 @@ interface IRouterBase { function isPaused() external view returns (bool); /** - * @dev Toggles the stopped state. + * @dev Puts the system into an emergency stopped state. + * @dev Only callable by owner + */ + function pause() external; + + /** + * @dev Takes the system out of an emergency stopped state. * @dev Only callable by owner */ - function togglePaused() external; + function unpause() external; } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index 296c1873c0e..8bd6236c778 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -52,10 +52,10 @@ contract FunctionsClientTestHelper is FunctionsClient { emit SendRequestInvoked(requestId, sourceCode, subscriptionId); } - function acceptTermsOfService(address acceptor, address recipient, bytes calldata proof) external { + function acceptTermsOfService(address acceptor, address recipient, bytes32 r, bytes32 s, uint8 v) external { bytes32 allowListId = s_router.getAllowListId(); ITermsOfServiceAllowList allowList = ITermsOfServiceAllowList(s_router.getContractById(allowListId)); - allowList.acceptTermsOfService(acceptor, recipient, proof); + allowList.acceptTermsOfService(acceptor, recipient, r, s, v); } function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external { diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol index 782f3bb4e22..a4bd6d97472 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol @@ -29,7 +29,7 @@ contract FunctionsTestHelper { function addEmptyArgs() public pure { Functions.Request memory r; string[] memory args; - r.addArgs(args); + r.setArgs(args); } function addTwoArgs(string memory arg1, string memory arg2) public { @@ -37,7 +37,7 @@ contract FunctionsTestHelper { args[0] = arg1; args[1] = arg2; Functions.Request memory r = s_req; - r.addArgs(args); + r.setArgs(args); storeRequest(r); } diff --git a/contracts/test/v0.8/functions/v0/FunctionsBillingRegistry.test.ts b/contracts/test/v0.8/functions/v0/FunctionsBillingRegistry.test.ts index a174297c6ed..b9110aea615 100644 --- a/contracts/test/v0.8/functions/v0/FunctionsBillingRegistry.test.ts +++ b/contracts/test/v0.8/functions/v0/FunctionsBillingRegistry.test.ts @@ -69,12 +69,12 @@ before(async () => { ) linkTokenFactory = await ethers.getContractFactory( - 'src/v0.4/LinkToken.sol:LinkToken', + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', roles.consumer, ) mockAggregatorV3Factory = await ethers.getContractFactory( - 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', roles.consumer, ) }) diff --git a/contracts/test/v0.8/functions/v0/FunctionsBillingRegistryUpgradeable.test.ts b/contracts/test/v0.8/functions/v0/FunctionsBillingRegistryUpgradeable.test.ts index 643602d86b0..04a7db0b2c0 100644 --- a/contracts/test/v0.8/functions/v0/FunctionsBillingRegistryUpgradeable.test.ts +++ b/contracts/test/v0.8/functions/v0/FunctionsBillingRegistryUpgradeable.test.ts @@ -68,12 +68,12 @@ before(async () => { ) linkTokenFactory = await ethers.getContractFactory( - 'src/v0.4/LinkToken.sol:LinkToken', + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', roles.consumer, ) mockAggregatorV3Factory = await ethers.getContractFactory( - 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', roles.consumer, ) }) diff --git a/contracts/test/v0.8/functions/v0/FunctionsClient.test.ts b/contracts/test/v0.8/functions/v0/FunctionsClient.test.ts index 28eb9daae72..4a474aadef2 100644 --- a/contracts/test/v0.8/functions/v0/FunctionsClient.test.ts +++ b/contracts/test/v0.8/functions/v0/FunctionsClient.test.ts @@ -48,12 +48,12 @@ before(async () => { ) linkTokenFactory = await ethers.getContractFactory( - 'src/v0.4/LinkToken.sol:LinkToken', + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', roles.consumer, ) mockAggregatorV3Factory = await ethers.getContractFactory( - 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', roles.consumer, ) }) diff --git a/contracts/test/v0.8/functions/v0/FunctionsOracle.test.ts b/contracts/test/v0.8/functions/v0/FunctionsOracle.test.ts index dfb392d9428..ae44e1b037e 100644 --- a/contracts/test/v0.8/functions/v0/FunctionsOracle.test.ts +++ b/contracts/test/v0.8/functions/v0/FunctionsOracle.test.ts @@ -43,12 +43,12 @@ before(async () => { ) linkTokenFactory = await ethers.getContractFactory( - 'src/v0.4/LinkToken.sol:LinkToken', + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', roles.consumer, ) mockAggregatorV3Factory = await ethers.getContractFactory( - 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', roles.consumer, ) }) diff --git a/contracts/test/v0.8/functions/v0/FunctionsOracleUpgradeable.test.ts b/contracts/test/v0.8/functions/v0/FunctionsOracleUpgradeable.test.ts index 64bacbc5562..f127692373a 100644 --- a/contracts/test/v0.8/functions/v0/FunctionsOracleUpgradeable.test.ts +++ b/contracts/test/v0.8/functions/v0/FunctionsOracleUpgradeable.test.ts @@ -59,12 +59,12 @@ before(async () => { ) linkTokenFactory = await ethers.getContractFactory( - 'src/v0.4/LinkToken.sol:LinkToken', + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', roles.consumer, ) mockAggregatorV3Factory = await ethers.getContractFactory( - 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', roles.consumer, ) }) diff --git a/contracts/test/v0.8/functions/v0/Gas.test.ts b/contracts/test/v0.8/functions/v0/Gas.test.ts new file mode 100644 index 00000000000..c84e017972f --- /dev/null +++ b/contracts/test/v0.8/functions/v0/Gas.test.ts @@ -0,0 +1,158 @@ +import { ethers } from 'hardhat' +import { expect } from 'chai' +import { Contract, ContractFactory } from 'ethers' +import { Roles, getUsers } from '../../../test-helpers/setup' +import { stringToBytes } from '../../../test-helpers/helpers' + +let concreteFunctionsClientFactory: ContractFactory +let functionsOracleFactory: ContractFactory +let functionsBillingRegistryFactory: ContractFactory +let linkTokenFactory: ContractFactory +let mockAggregatorV3Factory: ContractFactory +let roles: Roles + +function getEventArg(events: any, eventName: string, argIndex: number) { + if (Array.isArray(events)) { + const event = events.find((e: any) => e.event == eventName) + if (event && Array.isArray(event.args) && event.args.length > 0) { + return event.args[argIndex] + } + } + return undefined +} + +const baselineGasUsed = 641560 +let currentGasUsed = 0 + +before(async () => { + roles = (await getUsers()).roles + + concreteFunctionsClientFactory = await ethers.getContractFactory( + 'src/v0.8/functions/tests/0_0_0/testhelpers/FunctionsClientTestHelper.sol:FunctionsClientTestHelper', + roles.defaultAccount, + ) + functionsOracleFactory = await ethers.getContractFactory( + 'src/v0.8/functions/tests/0_0_0/testhelpers/FunctionsOracleHelper.sol:FunctionsOracleHelper', + roles.defaultAccount, + ) + + functionsBillingRegistryFactory = await ethers.getContractFactory( + 'src/v0.8/functions/tests/0_0_0/testhelpers/FunctionsBillingRegistryWithInit.sol:FunctionsBillingRegistryWithInit', + roles.defaultAccount, + ) + + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', + roles.consumer, + ) + + mockAggregatorV3Factory = await ethers.getContractFactory( + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', + roles.consumer, + ) +}) + +after(() => { + const score = currentGasUsed - baselineGasUsed + console.log( + `\n ⛳ Baseline gas used : ${baselineGasUsed} gas`, + ) + console.log(`\n Current gas used : ${currentGasUsed} gas`) + console.log(`\n 🚩 Delta : ${score} gas`) +}) + +let subscriptionId: number + +let client: Contract +let oracle: Contract +let registry: Contract +let linkToken: Contract +let mockLinkEth: Contract + +beforeEach(async () => { + // Deploy + linkToken = await linkTokenFactory.connect(roles.defaultAccount).deploy() + mockLinkEth = await mockAggregatorV3Factory.deploy( + 0, + ethers.BigNumber.from(5021530000000000), + ) + oracle = await functionsOracleFactory.connect(roles.defaultAccount).deploy() + registry = await functionsBillingRegistryFactory + .connect(roles.defaultAccount) + .deploy(linkToken.address, mockLinkEth.address, oracle.address) + + // Setup contracts + await oracle.setRegistry(registry.address) + await oracle.deactivateAuthorizedReceiver() + client = await concreteFunctionsClientFactory + .connect(roles.defaultAccount) + .deploy(oracle.address) + await registry.setAuthorizedSenders([oracle.address]) + + await registry.setConfig( + 1_000_000, + 86_400, + 21_000 + 5_000 + 2_100 + 20_000 + 2 * 2_100 - 15_000 + 7_315, + ethers.BigNumber.from('5000000000000000'), + 100_000, + 300, + ) +}) + +describe('Gas', () => { + it('uses the expected amount of gas', async () => { + // Setup accounts + const createSubTx = await registry + .connect(roles.defaultAccount) + .createSubscription() + const createSubscriptionTxReceipt = await createSubTx.wait() + subscriptionId = + createSubscriptionTxReceipt.events[0].args['subscriptionId'].toNumber() + const createSubscriptionGasUsed = createSubscriptionTxReceipt.gasUsed + + const addConsumerTx = await registry + .connect(roles.defaultAccount) + .addConsumer(subscriptionId, client.address) + const { gasUsed: addConsumerTxGasUsed } = await addConsumerTx.wait() + + const transferAndCallTx = await linkToken + .connect(roles.defaultAccount) + .transferAndCall( + registry.address, + ethers.BigNumber.from('115957983815660167'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subscriptionId]), + ) + const { gasUsed: transferAndCallTxGasUsed } = await transferAndCallTx.wait() + + const requestTx = await client.sendSimpleRequestWithJavaScript( + 'function run(){return response}', + subscriptionId, + ) + + const { events, gasUsed: requestTxGasUsed } = await requestTx.wait() + const requestId = getEventArg(events, 'RequestSent', 0) + await expect(requestTx).to.emit(client, 'RequestSent').withArgs(requestId) + + const response = stringToBytes('response') + const error = stringToBytes('') + const abi = ethers.utils.defaultAbiCoder + + const report = abi.encode( + ['bytes32[]', 'bytes[]', 'bytes[]'], + [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ) + + const fulfillmentTx = await oracle.callReport(report, { + gasLimit: 300_000, + }) + + const { gasUsed: fulfillmentTxGasUsed } = await fulfillmentTx.wait() + + currentGasUsed = createSubscriptionGasUsed + .add(addConsumerTxGasUsed) + .add(transferAndCallTxGasUsed) + .add(requestTxGasUsed) + .add(fulfillmentTxGasUsed) + .toNumber() + }) +}) diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index 9425376b6b4..0748735ed05 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -16,7 +16,7 @@ describe('Functions Router - Request lifecycle', () => { describe('Getters', () => { it('#typeAndVersion', async () => { expect(await contracts.router.typeAndVersion()).to.be.equal( - 'Functions Router v1', + 'Functions Router v1.0.0', ) }) it('#adminFee', async () => { diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 79af43d20bb..4df70003276 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -12,7 +12,7 @@ import { getEventArg, accessControlMockPrivateKey, } from './utils' -import { numToBytes32, stringToBytes } from '../../../test-helpers/helpers' +import { stringToBytes } from '../../../test-helpers/helpers' const setup = getSetupFactory() let contracts: FunctionsContracts @@ -25,555 +25,555 @@ beforeEach(async () => { }) describe('Functions Router - Subscriptions', () => { - // describe('Subscription management', () => { - // describe('#createSubscription', async function () { - // it('can create a subscription', async function () { - // await acceptTermsOfService( - // contracts.accessControl, - // roles.subOwner, - // roles.subOwnerAddress, - // ) - // await expect( - // contracts.router.connect(roles.subOwner).createSubscription(), - // ) - // .to.emit(contracts.router, 'SubscriptionCreated') - // .withArgs(1, roles.subOwnerAddress) - // const s = await contracts.router.getSubscription(1) - // expect(s.balance.toString()).to.equal('0') - // expect(s.owner).to.equal(roles.subOwnerAddress) - // }) - // it('subscription id increments', async function () { - // await acceptTermsOfService( - // contracts.accessControl, - // roles.subOwner, - // roles.subOwnerAddress, - // ) - // await expect( - // contracts.router.connect(roles.subOwner).createSubscription(), - // ) - // .to.emit(contracts.router, 'SubscriptionCreated') - // .withArgs(1, roles.subOwnerAddress) - // await expect( - // contracts.router.connect(roles.subOwner).createSubscription(), - // ) - // .to.emit(contracts.router, 'SubscriptionCreated') - // .withArgs(2, roles.subOwnerAddress) - // }) - // it('cannot create more than the max', async function () { - // const subId = createSubscription( - // roles.subOwner, - // [], - // contracts.router, - // contracts.accessControl, - // ) - // for (let i = 0; i < 100; i++) { - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, randomAddressString()) - // } - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, randomAddressString()), - // ).to.be.revertedWith(`TooManyConsumers()`) - // }) - // }) - - // describe('#requestSubscriptionOwnerTransfer', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // }) - // it('rejects non-owner', async function () { - // await expect( - // contracts.router - // .connect(roles.stranger) - // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - // ).to.be.revertedWith(`MustBeSubOwner()`) - // }) - // it('owner can request transfer', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - // ) - // .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') - // .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - // // Same request is a noop - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - // ).to.not.emit(contracts.router, 'SubscriptionOwnerTransferRequested') - // }) - // }) - - // describe('#acceptSubscriptionOwnerTransfer', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // }) - // it('subscription must exist', async function () { - // // 0x0 is requested owner - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .acceptSubscriptionOwnerTransfer(1203123123), - // ).to.be.revertedWith(`MustBeRequestedOwner`) - // }) - // it('must be requested owner to accept', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - // ) - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .acceptSubscriptionOwnerTransfer(subId), - // ).to.be.revertedWith(`MustBeRequestedOwner("${roles.strangerAddress}")`) - // }) - // it('requested owner can accept', async function () { - // await acceptTermsOfService( - // contracts.accessControl, - // roles.stranger, - // roles.strangerAddress, - // ) - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .requestSubscriptionOwnerTransfer(subId, roles.strangerAddress), - // ) - // .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') - // .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - // await expect( - // contracts.router - // .connect(roles.stranger) - // .acceptSubscriptionOwnerTransfer(subId), - // ) - // .to.emit(contracts.router, 'SubscriptionOwnerTransferred') - // .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - // }) - // }) - - // describe('#addConsumer', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // }) - // it('subscription must exist', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(1203123123, roles.strangerAddress), - // ).to.be.revertedWith(`InvalidSubscription`) - // }) - // it('must be owner', async function () { - // await expect( - // contracts.router - // .connect(roles.stranger) - // .addConsumer(subId, roles.strangerAddress), - // ).to.be.revertedWith(`MustBeSubOwner()`) - // }) - // it('add is idempotent', async function () { - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress) - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress), - // ).to.not.be.reverted - // }) - // it('cannot add more than maximum', async function () { - // // There is one consumer, add another 99 to hit the max - // for (let i = 0; i < 99; i++) { - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, randomAddressString()) - // } - // // Adding one more should fail - // // await contracts.router.connect(roles.subOwner).addConsumer(subId, roles.strangerAddress); - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress), - // ).to.be.revertedWith(`TooManyConsumers()`) - // // Same is true if we first create with the maximum - // const consumers: string[] = [] - // for (let i = 0; i < 100; i++) { - // consumers.push(randomAddressString()) - // } - // subId = await createSubscription( - // roles.subOwner, - // consumers, - // contracts.router, - // contracts.accessControl, - // ) - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress), - // ).to.be.revertedWith(`TooManyConsumers()`) - // }) - // it('owner can update', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress), - // ) - // .to.emit(contracts.router, 'SubscriptionConsumerAdded') - // .withArgs(subId, roles.strangerAddress) - // }) - // }) - - // describe('#removeConsumer', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // }) - // it('subscription must exist', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .removeConsumer(1203123123, roles.strangerAddress), - // ).to.be.revertedWith(`InvalidSubscription`) - // }) - // it('must be owner', async function () { - // await expect( - // contracts.router - // .connect(roles.stranger) - // .removeConsumer(subId, roles.strangerAddress), - // ).to.be.revertedWith(`MustBeSubOwner()`) - // }) - // it('owner can update', async function () { - // const subBefore = await contracts.router.getSubscription(subId) - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress) - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .removeConsumer(subId, roles.strangerAddress), - // ) - // .to.emit(contracts.router, 'SubscriptionConsumerRemoved') - // .withArgs(subId, roles.strangerAddress) - // const subAfter = await contracts.router.getSubscription(subId) - // // Subscription should NOT contain the removed consumer - // expect(subBefore.consumers).to.deep.equal(subAfter.consumers) - // }) - // it('can remove all consumers', async function () { - // // Testing the handling of zero. - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress) - // await contracts.router - // .connect(roles.subOwner) - // .removeConsumer(subId, roles.strangerAddress) - // await contracts.router - // .connect(roles.subOwner) - // .removeConsumer(subId, roles.consumerAddress) - // // Should be empty - // const subAfter = await contracts.router.getSubscription(subId) - // expect(subAfter.consumers).to.deep.equal([]) - // }) - // }) - - // describe('#pendingRequestExists', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - - // await contracts.linkToken - // .connect(roles.subOwner) - // .transferAndCall( - // contracts.router.address, - // BigNumber.from('130790416713017745'), - // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - // ) - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, contracts.client.address) - // }) - // it('returns false when there is no latest pending request', async function () { - // expect( - // await contracts.router - // .connect(roles.subOwner) - // .pendingRequestExists(subId), - // ).to.be.false - // }) - // it('returns true when the latest request is pending', async function () { - // await contracts.client - // .connect(roles.consumer) - // .sendSimpleRequestWithJavaScript( - // `return 'hello world'`, - // subId, - // donLabel, - // 20_000, - // ) - // expect( - // await contracts.router - // .connect(roles.subOwner) - // .pendingRequestExists(subId), - // ).to.be.true - // }) - // }) - - // describe('#cancelSubscription', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // }) - // it('subscription must exist', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .cancelSubscription(1203123123, roles.subOwnerAddress), - // ).to.be.revertedWith(`InvalidSubscription`) - // }) - // it('must be owner', async function () { - // await expect( - // contracts.router - // .connect(roles.stranger) - // .cancelSubscription(subId, roles.subOwnerAddress), - // ).to.be.revertedWith(`MustBeSubOwner()`) - // }) - // it('can cancel', async function () { - // await contracts.linkToken - // .connect(roles.subOwner) - // .transferAndCall( - // contracts.router.address, - // BigNumber.from('1000'), - // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - // ) - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .cancelSubscription(subId, roles.strangerAddress), - // ) - // .to.emit(contracts.router, 'SubscriptionCanceled') - // .withArgs(subId, roles.strangerAddress, BigNumber.from('1000')) - // const strangerBalance = await contracts.linkToken.balanceOf( - // roles.strangerAddress, - // ) - // expect(strangerBalance.toString()).to.equal('1000000000000001000') - // await expect( - // contracts.router.connect(roles.subOwner).getSubscription(subId), - // ).to.be.revertedWith('InvalidSubscription') - // }) - // it('can add same consumer after canceling', async function () { - // await contracts.linkToken - // .connect(roles.subOwner) - // .transferAndCall( - // contracts.router.address, - // BigNumber.from('1000'), - // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - // ) - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress) - // await contracts.router - // .connect(roles.subOwner) - // .cancelSubscription(subId, roles.strangerAddress) - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // // The cancel should have removed this consumer, so we can add it again. - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, roles.strangerAddress), - // ).to.not.be.reverted - // }) - // it('cannot cancel with pending request', async function () { - // await contracts.linkToken - // .connect(roles.subOwner) - // .transferAndCall( - // contracts.router.address, - // BigNumber.from('130790416713017745'), - // ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), - // ) - // await contracts.router - // .connect(roles.subOwner) - // .addConsumer(subId, contracts.client.address) - // await contracts.client - // .connect(roles.consumer) - // .sendSimpleRequestWithJavaScript( - // `return 'hello world'`, - // subId, - // donLabel, - // 20_000, - // ) - // // Should revert with outstanding requests - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .cancelSubscription(subId, roles.strangerAddress), - // ).to.be.revertedWith('PendingRequestExists()') - // // However the owner is able to cancel - // // funds go to the sub owner. - // await expect( - // contracts.router - // .connect(roles.defaultAccount) - // .ownerCancelSubscription(subId), - // ) - // .to.emit(contracts.router, 'SubscriptionCanceled') - // .withArgs( - // subId, - // roles.subOwnerAddress, - // BigNumber.from('130790416713017745'), - // ) - // }) - // }) - - // describe('#recoverFunds', async function () { - // let subId: number - // beforeEach(async () => { - // subId = await createSubscription( - // roles.subOwner, - // [roles.consumerAddress], - // contracts.router, - // contracts.accessControl, - // ) - // }) - - // it('function that should change internal balance do', async function () { - // type bf = [() => Promise, BigNumber] - // const balanceChangingFns: Array = [ - // [ - // async function () { - // const s = ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]) - // await contracts.linkToken - // .connect(roles.subOwner) - // .transferAndCall( - // contracts.router.address, - // BigNumber.from('1000'), - // s, - // ) - // }, - // BigNumber.from('1000'), - // ], - // [ - // async function () { - // await contracts.router - // .connect(roles.subOwner) - // .cancelSubscription(subId, roles.strangerAddress) - // }, - // BigNumber.from('-1000'), - // ], - // ] - // for (const [fn, expectedBalanceChange] of balanceChangingFns) { - // const startingBalance = await contracts.router.getTotalBalance() - // await fn() - // const endingBalance = await contracts.router.getTotalBalance() - // expect(endingBalance.sub(startingBalance.toString())).to.equal( - // expectedBalanceChange.toString(), - // ) - // } - // }) - // it('only owner can recover', async function () { - // await expect( - // contracts.router - // .connect(roles.subOwner) - // .recoverFunds(roles.strangerAddress), - // ).to.be.revertedWith('Only callable by owner') - // }) - - // it('owner can recover link transferred', async function () { - // // Set the internal balance - // expect( - // await contracts.linkToken.balanceOf(roles.strangerAddress), - // ).to.equal(BigNumber.from('1000000000000000000')) - // const subscription = ethers.utils.defaultAbiCoder.encode( - // ['uint64'], - // [subId], - // ) - // await contracts.linkToken - // .connect(roles.subOwner) - // .transferAndCall( - // contracts.router.address, - // BigNumber.from('1000'), - // subscription, - // ) - // // Circumvent internal balance - // await contracts.linkToken - // .connect(roles.subOwner) - // .transfer(contracts.router.address, BigNumber.from('1000')) - // // Should recover this 1000 - // await expect( - // contracts.router - // .connect(roles.defaultAccount) - // .recoverFunds(roles.strangerAddress), - // ) - // .to.emit(contracts.router, 'FundsRecovered') - // .withArgs(roles.strangerAddress, BigNumber.from('1000')) - // expect( - // await contracts.linkToken.balanceOf(roles.strangerAddress), - // ).to.equal(BigNumber.from('1000000000000001000')) - // }) - // }) - // }) - - // describe('#oracleWithdraw', async function () { - // it('cannot withdraw with no balance', async function () { - // await expect( - // contracts.router - // .connect(roles.oracleNode) - // .oracleWithdraw(randomAddressString(), BigNumber.from('100')), - // ).to.be.revertedWith(`InsufficientBalance`) - // }) - // }) - - // describe('#flagsSet', async function () { - // it('get flags that were previously set', async function () { - // const flags = ethers.utils.formatBytes32String('arbitrary_byte_values') - // await acceptTermsOfService( - // contracts.accessControl, - // roles.subOwner, - // roles.subOwnerAddress, - // ) - // await expect( - // contracts.router.connect(roles.subOwner).createSubscription(), - // ) - // .to.emit(contracts.router, 'SubscriptionCreated') - // .withArgs(1, roles.subOwnerAddress) - // await contracts.router.setFlags(1, flags) - // expect(await contracts.router.getFlags(1)).to.equal(flags) - // }) - // }) + describe('Subscription management', () => { + describe('#createSubscription', async function () { + it('can create a subscription', async function () { + await acceptTermsOfService( + contracts.accessControl, + roles.subOwner, + roles.subOwnerAddress, + ) + await expect( + contracts.router.connect(roles.subOwner).createSubscription(), + ) + .to.emit(contracts.router, 'SubscriptionCreated') + .withArgs(1, roles.subOwnerAddress) + const s = await contracts.router.getSubscription(1) + expect(s.balance.toString()).to.equal('0') + expect(s.owner).to.equal(roles.subOwnerAddress) + }) + it('subscription id increments', async function () { + await acceptTermsOfService( + contracts.accessControl, + roles.subOwner, + roles.subOwnerAddress, + ) + await expect( + contracts.router.connect(roles.subOwner).createSubscription(), + ) + .to.emit(contracts.router, 'SubscriptionCreated') + .withArgs(1, roles.subOwnerAddress) + await expect( + contracts.router.connect(roles.subOwner).createSubscription(), + ) + .to.emit(contracts.router, 'SubscriptionCreated') + .withArgs(2, roles.subOwnerAddress) + }) + it('cannot create more than the max', async function () { + const subId = createSubscription( + roles.subOwner, + [], + contracts.router, + contracts.accessControl, + ) + for (let i = 0; i < 100; i++) { + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, randomAddressString()) + } + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(subId, randomAddressString()), + ).to.be.revertedWith(`TooManyConsumers()`) + }) + }) + + describe('#proposeSubscriptionOwnerTransfer', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + }) + it('rejects non-owner', async function () { + await expect( + contracts.router + .connect(roles.stranger) + .proposeSubscriptionOwnerTransfer(subId, roles.strangerAddress), + ).to.be.revertedWith(`MustBeSubscriptionOwner()`) + }) + it('owner can request transfer', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .proposeSubscriptionOwnerTransfer(subId, roles.strangerAddress), + ) + .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) + // Same request is a noop + await expect( + contracts.router + .connect(roles.subOwner) + .proposeSubscriptionOwnerTransfer(subId, roles.strangerAddress), + ).to.not.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + }) + }) + + describe('#acceptSubscriptionOwnerTransfer', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + }) + it('subscription must exist', async function () { + // 0x0 is requested owner + await expect( + contracts.router + .connect(roles.subOwner) + .acceptSubscriptionOwnerTransfer(1203123123), + ).to.be.revertedWith(`MustBeRequestedOwner`) + }) + it('must be requested owner to accept', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .proposeSubscriptionOwnerTransfer(subId, roles.strangerAddress), + ) + await expect( + contracts.router + .connect(roles.subOwner) + .acceptSubscriptionOwnerTransfer(subId), + ).to.be.revertedWith(`MustBeRequestedOwner("${roles.strangerAddress}")`) + }) + it('requested owner can accept', async function () { + await acceptTermsOfService( + contracts.accessControl, + roles.stranger, + roles.strangerAddress, + ) + await expect( + contracts.router + .connect(roles.subOwner) + .proposeSubscriptionOwnerTransfer(subId, roles.strangerAddress), + ) + .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) + await expect( + contracts.router + .connect(roles.stranger) + .acceptSubscriptionOwnerTransfer(subId), + ) + .to.emit(contracts.router, 'SubscriptionOwnerTransferred') + .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) + }) + }) + + describe('#addConsumer', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + }) + it('subscription must exist', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(1203123123, roles.strangerAddress), + ).to.be.revertedWith(`InvalidSubscription`) + }) + it('must be owner', async function () { + await expect( + contracts.router + .connect(roles.stranger) + .addConsumer(subId, roles.strangerAddress), + ).to.be.revertedWith(`MustBeSubscriptionOwner()`) + }) + it('add is idempotent', async function () { + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress) + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress), + ).to.not.be.reverted + }) + it('cannot add more than maximum', async function () { + // There is one consumer, add another 99 to hit the max + for (let i = 0; i < 99; i++) { + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, randomAddressString()) + } + // Adding one more should fail + // await contracts.router.connect(roles.subOwner).addConsumer(subId, roles.strangerAddress); + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress), + ).to.be.revertedWith(`TooManyConsumers()`) + // Same is true if we first create with the maximum + const consumers: string[] = [] + for (let i = 0; i < 100; i++) { + consumers.push(randomAddressString()) + } + subId = await createSubscription( + roles.subOwner, + consumers, + contracts.router, + contracts.accessControl, + ) + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress), + ).to.be.revertedWith(`TooManyConsumers()`) + }) + it('owner can update', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress), + ) + .to.emit(contracts.router, 'SubscriptionConsumerAdded') + .withArgs(subId, roles.strangerAddress) + }) + }) + + describe('#removeConsumer', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + }) + it('subscription must exist', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .removeConsumer(1203123123, roles.strangerAddress), + ).to.be.revertedWith(`InvalidSubscription`) + }) + it('must be owner', async function () { + await expect( + contracts.router + .connect(roles.stranger) + .removeConsumer(subId, roles.strangerAddress), + ).to.be.revertedWith(`MustBeSubscriptionOwner()`) + }) + it('owner can update', async function () { + const subBefore = await contracts.router.getSubscription(subId) + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress) + await expect( + contracts.router + .connect(roles.subOwner) + .removeConsumer(subId, roles.strangerAddress), + ) + .to.emit(contracts.router, 'SubscriptionConsumerRemoved') + .withArgs(subId, roles.strangerAddress) + const subAfter = await contracts.router.getSubscription(subId) + // Subscription should NOT contain the removed consumer + expect(subBefore.consumers).to.deep.equal(subAfter.consumers) + }) + it('can remove all consumers', async function () { + // Testing the handling of zero. + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress) + await contracts.router + .connect(roles.subOwner) + .removeConsumer(subId, roles.strangerAddress) + await contracts.router + .connect(roles.subOwner) + .removeConsumer(subId, roles.consumerAddress) + // Should be empty + const subAfter = await contracts.router.getSubscription(subId) + expect(subAfter.consumers).to.deep.equal([]) + }) + }) + + describe('#pendingRequestExists', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('130790416713017745'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + ) + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, contracts.client.address) + }) + it('returns false when there is no latest pending request', async function () { + expect( + await contracts.router + .connect(roles.subOwner) + .pendingRequestExists(subId), + ).to.be.false + }) + it('returns true when the latest request is pending', async function () { + await contracts.client + .connect(roles.consumer) + .sendSimpleRequestWithJavaScript( + `return 'hello world'`, + subId, + donLabel, + 20_000, + ) + expect( + await contracts.router + .connect(roles.subOwner) + .pendingRequestExists(subId), + ).to.be.true + }) + }) + + describe('#cancelSubscription', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + }) + it('subscription must exist', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .cancelSubscription(1203123123, roles.subOwnerAddress), + ).to.be.revertedWith(`InvalidSubscription`) + }) + it('must be owner', async function () { + await expect( + contracts.router + .connect(roles.stranger) + .cancelSubscription(subId, roles.subOwnerAddress), + ).to.be.revertedWith(`MustBeSubscriptionOwner()`) + }) + it('can cancel', async function () { + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('1000'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + ) + await expect( + contracts.router + .connect(roles.subOwner) + .cancelSubscription(subId, roles.strangerAddress), + ) + .to.emit(contracts.router, 'SubscriptionCanceled') + .withArgs(subId, roles.strangerAddress, BigNumber.from('1000')) + const strangerBalance = await contracts.linkToken.balanceOf( + roles.strangerAddress, + ) + expect(strangerBalance.toString()).to.equal('1000000000000001000') + await expect( + contracts.router.connect(roles.subOwner).getSubscription(subId), + ).to.be.revertedWith('InvalidSubscription') + }) + it('can add same consumer after canceling', async function () { + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('1000'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + ) + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress) + await contracts.router + .connect(roles.subOwner) + .cancelSubscription(subId, roles.strangerAddress) + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + // The cancel should have removed this consumer, so we can add it again. + await expect( + contracts.router + .connect(roles.subOwner) + .addConsumer(subId, roles.strangerAddress), + ).to.not.be.reverted + }) + it('cannot cancel with pending request', async function () { + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('130790416713017745'), + ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]), + ) + await contracts.router + .connect(roles.subOwner) + .addConsumer(subId, contracts.client.address) + await contracts.client + .connect(roles.consumer) + .sendSimpleRequestWithJavaScript( + `return 'hello world'`, + subId, + donLabel, + 20_000, + ) + // Should revert with outstanding requests + await expect( + contracts.router + .connect(roles.subOwner) + .cancelSubscription(subId, roles.strangerAddress), + ).to.be.revertedWith('PendingRequestExists()') + // However the owner is able to cancel + // funds go to the sub owner. + await expect( + contracts.router + .connect(roles.defaultAccount) + .ownerCancelSubscription(subId), + ) + .to.emit(contracts.router, 'SubscriptionCanceled') + .withArgs( + subId, + roles.subOwnerAddress, + BigNumber.from('130790416713017745'), + ) + }) + }) + + describe('#recoverFunds', async function () { + let subId: number + beforeEach(async () => { + subId = await createSubscription( + roles.subOwner, + [roles.consumerAddress], + contracts.router, + contracts.accessControl, + ) + }) + + it('function that should change internal balance do', async function () { + type bf = [() => Promise, BigNumber] + const balanceChangingFns: Array = [ + [ + async function () { + const s = ethers.utils.defaultAbiCoder.encode(['uint64'], [subId]) + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('1000'), + s, + ) + }, + BigNumber.from('1000'), + ], + [ + async function () { + await contracts.router + .connect(roles.subOwner) + .cancelSubscription(subId, roles.strangerAddress) + }, + BigNumber.from('-1000'), + ], + ] + for (const [fn, expectedBalanceChange] of balanceChangingFns) { + const startingBalance = await contracts.router.getTotalBalance() + await fn() + const endingBalance = await contracts.router.getTotalBalance() + expect(endingBalance.sub(startingBalance.toString())).to.equal( + expectedBalanceChange.toString(), + ) + } + }) + it('only owner can recover', async function () { + await expect( + contracts.router + .connect(roles.subOwner) + .recoverFunds(roles.strangerAddress), + ).to.be.revertedWith('Only callable by owner') + }) + + it('owner can recover link transferred', async function () { + // Set the internal balance + expect( + await contracts.linkToken.balanceOf(roles.strangerAddress), + ).to.equal(BigNumber.from('1000000000000000000')) + const subscription = ethers.utils.defaultAbiCoder.encode( + ['uint64'], + [subId], + ) + await contracts.linkToken + .connect(roles.subOwner) + .transferAndCall( + contracts.router.address, + BigNumber.from('1000'), + subscription, + ) + // Circumvent internal balance + await contracts.linkToken + .connect(roles.subOwner) + .transfer(contracts.router.address, BigNumber.from('1000')) + // Should recover this 1000 + await expect( + contracts.router + .connect(roles.defaultAccount) + .recoverFunds(roles.strangerAddress), + ) + .to.emit(contracts.router, 'FundsRecovered') + .withArgs(roles.strangerAddress, BigNumber.from('1000')) + expect( + await contracts.linkToken.balanceOf(roles.strangerAddress), + ).to.equal(BigNumber.from('1000000000000001000')) + }) + }) + }) + + describe('#oracleWithdraw', async function () { + it('cannot withdraw with no balance', async function () { + await expect( + contracts.router + .connect(roles.oracleNode) + .oracleWithdraw(randomAddressString(), BigNumber.from('100')), + ).to.be.revertedWith(`InsufficientBalance`) + }) + }) + + describe('#flagsSet', async function () { + it('get flags that were previously set', async function () { + const flags = ethers.utils.formatBytes32String('arbitrary_byte_values') + await acceptTermsOfService( + contracts.accessControl, + roles.subOwner, + roles.subOwnerAddress, + ) + await expect( + contracts.router.connect(roles.subOwner).createSubscription(), + ) + .to.emit(contracts.router, 'SubscriptionCreated') + .withArgs(1, roles.subOwnerAddress) + await contracts.router.setFlags(1, flags) + expect(await contracts.router.getFlags(1)).to.equal(flags) + }) + }) describe('#reentrancy', async function () { // Use a fixed gas price for these tests @@ -748,15 +748,18 @@ describe('Functions Router - Subscriptions', () => { recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) - const proof = await wallet.signMessage(ethers.utils.arrayify(messageHash)) + const flatSignature = await wallet.signMessage( + ethers.utils.arrayify(messageHash), + ) + const { r, s, v } = ethers.utils.splitSignature(flatSignature) await contracts.client .connect(roles.subOwner) - .acceptTermsOfService(acceptorAddress, recipientAddress, proof) + .acceptTermsOfService(acceptorAddress, recipientAddress, r, s, v) // Transfer Subscription ownership to client contract so that it can call subscription methods await contracts.router .connect(roles.subOwner) - .requestSubscriptionOwnerTransfer( + .proposeSubscriptionOwnerTransfer( subscriptionId, contracts.client.address, ) diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index cc7a7e0f128..e80dc469ed0 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -14,7 +14,7 @@ const setup = getSetupFactory() let contracts: FunctionsContracts let roles: FunctionsRoles -const baselineGasUsed = 754223 // TODO: Update baseline +const baselineGasUsed = 793891 let currentGasUsed = 0 beforeEach(async () => { @@ -36,10 +36,19 @@ describe('Gas Golf', () => { roles.consumerAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) - const proof = await wallet.signMessage(ethers.utils.arrayify(messageHash)) + const flatSignature = await wallet.signMessage( + ethers.utils.arrayify(messageHash), + ) + const { r, s, v } = ethers.utils.splitSignature(flatSignature) const acceptTermsOfServiceTx = await contracts.accessControl .connect(roles.consumer) - .acceptTermsOfService(roles.consumerAddress, roles.consumerAddress, proof) + .acceptTermsOfService( + roles.consumerAddress, + roles.consumerAddress, + r, + s, + v, + ) const { gasUsed: acceptTermsOfServiceGasUsed } = await acceptTermsOfServiceTx.wait() diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 2d4d0a897f5..786ce796088 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -59,11 +59,6 @@ describe('FunctionsRouter - Base', () => { }) it('Owner can update config of the Router', async () => { - const [ - beforeSystemVersionMajor, - beforeSystemVersionMinor, - beforeSystemVersionPatch, - ] = await contracts.router.version() const beforeConfigHash = await contracts.router.getConfigHash() await expect( @@ -79,24 +74,12 @@ describe('FunctionsRouter - Base', () => { contracts.router, 'ConfigUpdated', ) - const [ - afterSystemVersionMajor, - afterSystemVersionMinor, - afterSystemVersionPatch, - ] = await contracts.router.version() + const afterConfigHash = await contracts.router.getConfigHash() - expect(afterSystemVersionMajor).to.equal(beforeSystemVersionMajor) - expect(afterSystemVersionMinor).to.equal(beforeSystemVersionMinor) - expect(afterSystemVersionPatch).to.equal(beforeSystemVersionPatch + 1) expect(beforeConfigHash).to.not.equal(afterConfigHash) }) it('Config of a contract on a route can be updated', async () => { - const [ - beforeSystemVersionMajor, - beforeSystemVersionMinor, - beforeSystemVersionPatch, - ] = await contracts.router.version() const beforeConfigHash = await contracts.coordinator.getConfigHash() await expect( @@ -127,15 +110,8 @@ describe('FunctionsRouter - Base', () => { contracts.router, 'ConfigUpdated', ) - const [ - afterSystemVersionMajor, - afterSystemVersionMinor, - afterSystemVersionPatch, - ] = await contracts.router.version() + const afterConfigHash = await contracts.router.getConfigHash() - expect(afterSystemVersionMajor).to.equal(beforeSystemVersionMajor) - expect(afterSystemVersionMinor).to.equal(beforeSystemVersionMinor) - expect(afterSystemVersionPatch).to.equal(beforeSystemVersionPatch + 1) expect(beforeConfigHash).to.not.equal(afterConfigHash) }) @@ -216,11 +192,6 @@ describe('FunctionsRouter - Base', () => { contracts.mockLinkEth.address, ) - const [ - beforeSystemVersionMajor, - beforeSystemVersionMinor, - beforeSystemVersionPatch, - ] = await contracts.router.version() await expect( contracts.router['getContractById(bytes32)'](ids.donId2), ).to.be.revertedWith('RouteNotFound') @@ -271,15 +242,6 @@ describe('FunctionsRouter - Base', () => { expect( await contracts.router['getContractById(bytes32)'](ids.donId4), ).to.equal(coordinator4.address) - - const [ - afterSystemVersionMajor, - afterSystemVersionMinor, - afterSystemVersionPatch, - ] = await contracts.router.version() - expect(afterSystemVersionMajor).to.equal(beforeSystemVersionMajor) - expect(afterSystemVersionMinor).to.equal(beforeSystemVersionMinor + 1) - expect(afterSystemVersionPatch).to.equal(beforeSystemVersionPatch) }) it('non-owner is unable to propose contract updates', async () => { @@ -373,7 +335,7 @@ describe('FunctionsRouter - Base', () => { contracts.linkToken, ) - await contracts.router.togglePaused() + await contracts.router.pause() await expect( contracts.client.sendSimpleRequestWithJavaScript( diff --git a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts index 661c9f81700..47329fbcbdf 100644 --- a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts +++ b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts @@ -18,23 +18,26 @@ beforeEach(async () => { describe('ToS Access Control', () => { describe('Accepting', () => { - it('can only be done with a valid proof', async () => { + it('can only be done with a valid signature', async () => { const messageHash = await contracts.accessControl.getMessageHash( roles.strangerAddress, roles.strangerAddress, ) - const proof = await roles.stranger.signMessage( + const flatSignature = await roles.stranger.signMessage( ethers.utils.arrayify(messageHash), ) + const { r, s, v } = ethers.utils.splitSignature(flatSignature) await expect( contracts.accessControl .connect(roles.stranger) .acceptTermsOfService( roles.strangerAddress, roles.strangerAddress, - proof, + r, + s, + v, ), - ).to.be.revertedWith('InvalidProof') + ).to.be.revertedWith('InvalidSignature') }) it('can be done by Externally Owned Accounts if recipient themself', async () => { await acceptTermsOfService( @@ -53,7 +56,7 @@ describe('ToS Access Control', () => { roles.subOwner, roles.strangerAddress, ), - ).to.be.revertedWith('InvalidProof') + ).to.be.revertedWith('InvalidUsage') }) it('can be done by Contract Accounts if recipient themself', async () => { const acceptorAddress = roles.consumerAddress @@ -63,10 +66,13 @@ describe('ToS Access Control', () => { recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) - const proof = await wallet.signMessage(ethers.utils.arrayify(messageHash)) + const flatSignature = await wallet.signMessage( + ethers.utils.arrayify(messageHash), + ) + const { r, s, v } = ethers.utils.splitSignature(flatSignature) await contracts.client .connect(roles.consumer) - .acceptTermsOfService(acceptorAddress, recipientAddress, proof) + .acceptTermsOfService(acceptorAddress, recipientAddress, r, s, v) expect( await contracts.accessControl.hasAccess(recipientAddress, '0x'), @@ -80,12 +86,15 @@ describe('ToS Access Control', () => { recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) - const proof = await wallet.signMessage(ethers.utils.arrayify(messageHash)) + const flatSignature = await wallet.signMessage( + ethers.utils.arrayify(messageHash), + ) + let { r, s, v } = ethers.utils.splitSignature(flatSignature) await expect( contracts.client .connect(roles.consumer) - .acceptTermsOfService(acceptorAddress, recipientAddress, proof), - ).to.be.revertedWith('InvalidProof') + .acceptTermsOfService(acceptorAddress, recipientAddress, r, s, v), + ).to.be.revertedWith('InvalidUsage') }) }) diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index 8f818e12e3b..52178627577 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -123,11 +123,11 @@ export async function setupRolesAndFactories(): Promise<{ roles.consumer, ) const linkTokenFactory = await ethers.getContractFactory( - 'src/v0.4/LinkToken.sol:LinkToken', + 'src/v0.8/mocks/MockLinkToken.sol:MockLinkToken', roles.defaultAccount, ) const mockAggregatorV3Factory = await ethers.getContractFactory( - 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', + 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', roles.defaultAccount, ) return { @@ -162,10 +162,13 @@ export async function acceptTermsOfService( recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) - const proof = await wallet.signMessage(ethers.utils.arrayify(messageHash)) + const flatSignature = await wallet.signMessage( + ethers.utils.arrayify(messageHash), + ) + const { r, s, v } = ethers.utils.splitSignature(flatSignature) return accessControl .connect(acceptor) - .acceptTermsOfService(acceptorAddress, recipientAddress, proof) + .acceptTermsOfService(acceptorAddress, recipientAddress, r, s, v) } export async function createSubscription( diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index c1853515445..39732cfdc4d 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -31,8 +31,8 @@ var ( ) var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidProof\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"proof\",\"type\":\"bytes\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620012b6380380620012b6833981016040819052620000349162000156565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660805262000076816200008b565b80516020909101206000555062000284915050565b60008082806020019051810190620000a4919062000241565b6040805180820182528315158082526001600160a01b0384166020928301819052600480546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013d57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016a57600080fd5b8251620001778162000127565b602084810151919350906001600160401b03808211156200019757600080fd5b818601915086601f830112620001ac57600080fd5b815181811115620001c157620001c162000140565b604051601f8201601f19908116603f01168101908382118183101715620001ec57620001ec62000140565b8160405282815289868487010111156200020557600080fd5b600093505b828410156200022957848401860151818501870152928501926200020a565b60008684830101528096505050505050509250929050565b600080604083850312156200025557600080fd5b825180151581146200026657600080fd5b6020840151909250620002798162000127565b809150509250929050565b608051611008620002ae600039600081816103d6015281816105b0015261071601526110086000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c8063817ef62e116100815780639883c10d1161005b5780639883c10d14610193578063a5e1d61d1461019b578063fa540801146101ae57600080fd5b8063817ef62e1461015857806382184c7b1461016d5780638cc6acce1461018057600080fd5b806347663acb116100b257806347663acb146101015780636b14daf81461011457806380e8a1511461013757600080fd5b8063181f5a77146100ce5780632179d447146100ec575b600080fd5b6100d661020f565b6040516100e39190610b8f565b60405180910390f35b6100ff6100fa366004610c69565b61022f565b005b6100ff61010f366004610cce565b6103d4565b610127610122366004610ceb565b610515565b60405190151581526020016100e3565b61014a610145366004610d40565b61053f565b6040519081526020016100e3565b61016061059d565b6040516100e39190610d79565b6100ff61017b366004610cce565b6105ae565b6100ff61018e366004610e02565b6106fe565b60005461014a565b6101276101a9366004610cce565b610783565b61014a6101bc366004610ed1565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6060604051806060016040528060288152602001610fd460289139905090565b73ffffffffffffffffffffffffffffffffffffffff831660009081526003602052604090205460ff161561028f576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600454610100900473ffffffffffffffffffffffffffffffffffffffff166102f96102bd6101bc878761053f565b84848080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506107c492505050565b73ffffffffffffffffffffffffffffffffffffffff1614610346576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff841614158061038b57503373ffffffffffffffffffffffffffffffffffffffff85161480159061038b5750333b155b156103c2576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103cd60018461089b565b5050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610441573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104659190610eea565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146104c9576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60045460009060ff1661052a57506001610538565b6105356001856108bd565b90505b9392505050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60606105a960016108ec565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561061b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061063f9190610eea565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106a3576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106ae6001826108f9565b5073ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461076d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107768161091b565b8051602090910120600055565b60045460009060ff1661079857506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205460ff1690565b6000806000808451604114610805576040517f09bde33900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050602082810151604080850151606080870151835160008082529681018086528a9052951a928501839052840183905260808401819052919260019060a0016020604051602081039080840390855afa158015610868573d6000803e3d6000fd5b50506040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00151979650505050505050565b60006105388373ffffffffffffffffffffffffffffffffffffffff84166109f1565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001830160205260408120541515610538565b6060600061053883610a40565b60006105388373ffffffffffffffffffffffffffffffffffffffff8416610a9c565b600080828060200190518101906109329190610f07565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600480547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6000818152600183016020526040812054610a3857508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610597565b506000610597565b606081600001805480602002602001604051908101604052809291908181526020018280548015610a9057602002820191906000526020600020905b815481526020019060010190808311610a7c575b50505050509050919050565b60008181526001830160205260408120548015610b85576000610ac0600183610f3b565b8554909150600090610ad490600190610f3b565b9050818114610b39576000866000018281548110610af457610af4610f75565b9060005260206000200154905080876000018481548110610b1757610b17610f75565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610b4a57610b4a610fa4565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610597565b6000915050610597565b600060208083528351808285015260005b81811015610bbc57858101830151858201604001528201610ba0565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610c1d57600080fd5b50565b60008083601f840112610c3257600080fd5b50813567ffffffffffffffff811115610c4a57600080fd5b602083019150836020828501011115610c6257600080fd5b9250929050565b60008060008060608587031215610c7f57600080fd5b8435610c8a81610bfb565b93506020850135610c9a81610bfb565b9250604085013567ffffffffffffffff811115610cb657600080fd5b610cc287828801610c20565b95989497509550505050565b600060208284031215610ce057600080fd5b813561053881610bfb565b600080600060408486031215610d0057600080fd5b8335610d0b81610bfb565b9250602084013567ffffffffffffffff811115610d2757600080fd5b610d3386828701610c20565b9497909650939450505050565b60008060408385031215610d5357600080fd5b8235610d5e81610bfb565b91506020830135610d6e81610bfb565b809150509250929050565b6020808252825182820181905260009190848201906040850190845b81811015610dc757835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610d95565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610e1457600080fd5b813567ffffffffffffffff80821115610e2c57600080fd5b818401915084601f830112610e4057600080fd5b813581811115610e5257610e52610dd3565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610e9857610e98610dd3565b81604052828152876020848701011115610eb157600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610ee357600080fd5b5035919050565b600060208284031215610efc57600080fd5b815161053881610bfb565b60008060408385031215610f1a57600080fd5b82518015158114610f2a57600080fd5b6020840151909250610d6e81610bfb565b81810381811115610597577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c697374207631a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620011e2380380620011e2833981016040819052620000349162000156565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660805262000076816200008b565b80516020909101206000555062000284915050565b60008082806020019051810190620000a4919062000241565b6040805180820182528315158082526001600160a01b0384166020928301819052600480546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013d57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016a57600080fd5b8251620001778162000127565b602084810151919350906001600160401b03808211156200019757600080fd5b818601915086601f830112620001ac57600080fd5b815181811115620001c157620001c162000140565b604051601f8201601f19908116603f01168101908382118183101715620001ec57620001ec62000140565b8160405282815289868487010111156200020557600080fd5b600093505b828410156200022957848401860151818501870152928501926200020a565b60008684830101528096505050505050509250929050565b600080604083850312156200025557600080fd5b825180151581146200026657600080fd5b6020840151909250620002798162000127565b809150509250929050565b608051610f34620002ae600039600081816103ee015281816105c8015261072e0152610f346000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c8063817ef62e116100815780639883c10d1161005b5780639883c10d14610193578063a5e1d61d1461019b578063fa540801146101ae57600080fd5b8063817ef62e1461015857806382184c7b1461016d5780638cc6acce1461018057600080fd5b806347663acb116100b257806347663acb146101015780636b14daf81461011457806380e8a1511461013757600080fd5b8063181f5a77146100ce5780633908c4d4146100ec575b600080fd5b6100d661020f565b6040516100e39190610ad0565b60405180910390f35b6100ff6100fa366004610b61565b61022b565b005b6100ff61010f366004610bc6565b6103ec565b610127610122366004610be3565b61052d565b60405190151581526020016100e3565b61014a610145366004610c68565b610557565b6040519081526020016100e3565b6101606105b5565b6040516100e39190610ca1565b6100ff61017b366004610bc6565b6105c6565b6100ff61018e366004610d2a565b610716565b60005461014a565b6101276101a9366004610bc6565b61079b565b61014a6101bc366004610df9565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6040518060600160405280602c8152602001610efc602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526003602052604090205460ff161561028b576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600454610100900473ffffffffffffffffffffffffffffffffffffffff1660016102b86101bc8888610557565b6040805160008152602081018083529290925260ff851690820152606081018690526080810185905260a0016020604051602081039080840390855afa158015610306573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff161461035d576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff85161415806103a257503373ffffffffffffffffffffffffffffffffffffffff8616148015906103a25750333b155b156103d9576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103e46001856107dc565b505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610459573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061047d9190610e12565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146104e1576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60045460009060ff1661054257506001610550565b61054d6001856107fe565b90505b9392505050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60606105c1600161082d565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610633573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106579190610e12565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106bb576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c660018261083a565b5073ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610785576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61078e8161085c565b8051602090910120600055565b60045460009060ff166107b057506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205460ff1690565b60006105508373ffffffffffffffffffffffffffffffffffffffff8416610932565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001830160205260408120541515610550565b6060600061055083610981565b60006105508373ffffffffffffffffffffffffffffffffffffffff84166109dd565b600080828060200190518101906108739190610e2f565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600480547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6000818152600183016020526040812054610979575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556105af565b5060006105af565b6060816000018054806020026020016040519081016040528092919081815260200182805480156109d157602002820191906000526020600020905b8154815260200190600101908083116109bd575b50505050509050919050565b60008181526001830160205260408120548015610ac6576000610a01600183610e63565b8554909150600090610a1590600190610e63565b9050818114610a7a576000866000018281548110610a3557610a35610e9d565b9060005260206000200154905080876000018481548110610a5857610a58610e9d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610a8b57610a8b610ecc565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506105af565b60009150506105af565b600060208083528351808285015260005b81811015610afd57858101830151858201604001528201610ae1565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610b5e57600080fd5b50565b600080600080600060a08688031215610b7957600080fd5b8535610b8481610b3c565b94506020860135610b9481610b3c565b93506040860135925060608601359150608086013560ff81168114610bb857600080fd5b809150509295509295909350565b600060208284031215610bd857600080fd5b813561055081610b3c565b600080600060408486031215610bf857600080fd5b8335610c0381610b3c565b9250602084013567ffffffffffffffff80821115610c2057600080fd5b818601915086601f830112610c3457600080fd5b813581811115610c4357600080fd5b876020828501011115610c5557600080fd5b6020830194508093505050509250925092565b60008060408385031215610c7b57600080fd5b8235610c8681610b3c565b91506020830135610c9681610b3c565b809150509250929050565b6020808252825182820181905260009190848201906040850190845b81811015610cef57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610cbd565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610d3c57600080fd5b813567ffffffffffffffff80821115610d5457600080fd5b818401915084601f830112610d6857600080fd5b813581811115610d7a57610d7a610cfb565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610dc057610dc0610cfb565b81604052828152876020848701011115610dd957600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610e0b57600080fd5b5035919050565b600060208284031215610e2457600080fd5b815161055081610b3c565b60008060408385031215610e4257600080fd5b82518015158114610e5257600080fd5b6020840151909250610c9681610b3c565b818103818111156105af577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI @@ -325,16 +325,16 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) TypeAndVer return _TermsOfServiceAllowList.Contract.TypeAndVersion(&_TermsOfServiceAllowList.CallOpts) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) AcceptTermsOfService(opts *bind.TransactOpts, acceptor common.Address, recipient common.Address, proof []byte) (*types.Transaction, error) { - return _TermsOfServiceAllowList.contract.Transact(opts, "acceptTermsOfService", acceptor, recipient, proof) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) AcceptTermsOfService(opts *bind.TransactOpts, acceptor common.Address, recipient common.Address, r [32]byte, s [32]byte, v uint8) (*types.Transaction, error) { + return _TermsOfServiceAllowList.contract.Transact(opts, "acceptTermsOfService", acceptor, recipient, r, s, v) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) AcceptTermsOfService(acceptor common.Address, recipient common.Address, proof []byte) (*types.Transaction, error) { - return _TermsOfServiceAllowList.Contract.AcceptTermsOfService(&_TermsOfServiceAllowList.TransactOpts, acceptor, recipient, proof) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) AcceptTermsOfService(acceptor common.Address, recipient common.Address, r [32]byte, s [32]byte, v uint8) (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.AcceptTermsOfService(&_TermsOfServiceAllowList.TransactOpts, acceptor, recipient, r, s, v) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) AcceptTermsOfService(acceptor common.Address, recipient common.Address, proof []byte) (*types.Transaction, error) { - return _TermsOfServiceAllowList.Contract.AcceptTermsOfService(&_TermsOfServiceAllowList.TransactOpts, acceptor, recipient, proof) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) AcceptTermsOfService(acceptor common.Address, recipient common.Address, r [32]byte, s [32]byte, v uint8) (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.AcceptTermsOfService(&_TermsOfServiceAllowList.TransactOpts, acceptor, recipient, r, s, v) } func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) BlockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) { @@ -523,7 +523,7 @@ type TermsOfServiceAllowListInterface interface { TypeAndVersion(opts *bind.CallOpts) (string, error) - AcceptTermsOfService(opts *bind.TransactOpts, acceptor common.Address, recipient common.Address, proof []byte) (*types.Transaction, error) + AcceptTermsOfService(opts *bind.TransactOpts, acceptor common.Address, recipient common.Address, r [32]byte, s [32]byte, v uint8) (*types.Transaction, error) BlockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 311bee4b306..2c9c6bb4e92 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -61,8 +61,8 @@ type IFunctionsCoordinatorRequest struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005d1f38038062005d1f833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516156946200068b60003960008181610a6f01528181610e3701528181611074015281816110fe01528181611ba801528181611dac01528181612f6c0152613e73015260006115a301526156946000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e1461054e578063de9dfa4614610556578063e3d0e71214610569578063f2fde38b1461057c57600080fd5b8063b1dc65a41461040d578063c3f909d414610420578063d227d2451461051e57600080fd5b8063aecc12c5116100c8578063aecc12c5146103a5578063af1296d3146103e5578063afcb95d7146103ed57600080fd5b80638cc6acce146103585780638da5cb5b1461036b5780639883c10d1461039357600080fd5b806379ba50971161015b578063814118341161013557806381411834146102ab57806381f1b938146102c057806381ff7048146102c857806385b214cf1461033557600080fd5b806379ba50971461027d5780637f15e16614610285578063807560311461029857600080fd5b8063466557181161018c5780634665571814610226578063533989871461025457806366316d8d1461026a57600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac14610213575b600080fd5b6101c66101c1366004614134565b61058f565b005b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b60405161020a91906141da565b60405180910390f35b6101c661022136600461420f565b6105e4565b61023961023436600461436b565b610686565b60405169ffffffffffffffffffff909116815260200161020a565b61025c6106b4565b60405161020a929190614492565b6101c661027836600461453c565b610938565b6101c6610ad4565b6101c6610293366004614134565b610bd6565b6101c66102a6366004614575565b610c26565b6102b3610cdd565b60405161020a91906145ca565b6101fd610d4c565b61031260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff94851681529390921660208401529082015260600161020a565b6103486103433660046145dd565b610e1d565b604051901515815260200161020a565b6101c66103663660046145f6565b61105c565b60005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161020a565b6007545b60405190815260200161020a565b6103b86103b3366004614633565b6110e1565b604080519485526bffffffffffffffffffffffff909316602085015291830152606082015260800161020a565b61039761133d565b60408051600181526000602082018190529181019190915260600161020a565b6101c661041b3660046146b3565b611430565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff166101208201526101400161020a565b61053161052c36600461476a565b611b61565b6040516bffffffffffffffffffffffff909116815260200161020a565b6101fd611d51565b61053161056436600461436b565b611da8565b6101c661057736600461488c565b611e40565b6101c661058a36600461420f565b612864565b610597612875565b60008190036105d2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105df8284836149fa565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061f57503373ffffffffffffffffffffffffffffffffffffffff8216145b610655576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061068391614079565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561071c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106f1575b505050505090506000815167ffffffffffffffff81111561073f5761073f61422c565b60405190808252806020026020018201604052801561077257816020015b606081526020019060019003908161075d5790505b50905060005b825181101561092e57600f600084838151811061079757610797614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107e490614959565b905060000361081f576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061083557610835614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461088290614959565b80601f01602080910402602001604051908101604052809291908181526020018280546108ae90614959565b80156108fb5780601f106108d0576101008083540402835291602001916108fb565b820191906000526020600020905b8154815290600101906020018083116108de57829003601f168201915b505050505082828151811061091257610912614b15565b60200260200101819052508061092790614b73565b9050610778565b5090939092509050565b6109406128f8565b806bffffffffffffffffffffffff166000036109765750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109d0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109fd9084906bffffffffffffffffffffffff16614bab565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116600483015291841660248201527f00000000000000000000000000000000000000000000000000000000000000009250908216906366316d8d90604401600060405180830381600087803b158015610ab757600080fd5b505af1158015610acb573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b5a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610bde612875565b6000819003610c19576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105df8284836149fa565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c715750610c5033612a8f565b8015610c7157503373ffffffffffffffffffffffffffffffffffffffff8416145b610ca7576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cd78284836149fa565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d4257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d17575b5050505050905090565b606060108054610d5b90614959565b9050600003610d96576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610da390614959565b80601f0160208091040260200160405190810160405280929190818152602001828054610dcf90614959565b8015610d425780601f10610df157610100808354040283529160200191610d42565b820191906000526020600020905b815481529060010190602001808311610dff57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e8e576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff1661010084015260030154610120830152610fe25750600092915050565b600083815260086020526040808220828155600181018390556002810180547fff000000000000000000000000000000000000000000000000000000000000001690556003018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146110cb576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110d481612b78565b8051602090910120600755565b60008080803373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611155576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6111626040860186614bd7565b905060000361119c576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808760600160208101906111bc9190614c3c565b67ffffffffffffffff1681526020908101906111da9089018961420f565b73ffffffffffffffffffffffffffffffffffffffff16815260200161120560e0890160c08a01614c59565b63ffffffff1681523a60209091015290506112716112266040880188614bd7565b8080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061126b9250505060a0890160808a01614c86565b83612e81565b92975090955093509150611288602087018761420f565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c326112d160808b0160608c01614c3c565b6112e160408c0160208d0161420f565b6112ee60408d018d614bd7565b8d60800160208101906113019190614c86565b8e60a001358f60c00160208101906113199190614c59565b60405161132d989796959493929190614ca3565b60405180910390a3509193509193565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156113d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113fb9190614d63565b5093505092505082801561141d57506114148142614db3565b8463ffffffff16105b1561142857600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161148691849163ffffffff851691908e908e908190840183828082843760009201919091525061352c92505050565b6114bc576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611591576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b51565b61159f8b8b8b8b8b8b613535565b60007f0000000000000000000000000000000000000000000000000000000000000000156115fc576002826020015183604001516115dd9190614dc6565b6115e79190614e0e565b6115f2906001614dc6565b60ff169050611612565b602082015161160c906001614dc6565b60ff1690505b88811461167b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b51565b8887146116e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b51565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561172757611727614e30565b600281111561173857611738614e30565b905250905060028160200151600281111561175557611755614e30565b14801561179c57506006816000015160ff168154811061177757611777614b15565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611802576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b51565b505050505061180f6140b3565b6000808a8a604051611822929190614e5f565b604051908190038120611839918e90602001614e6f565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b435760006001848984602081106118a2576118a2614b15565b6118af91901a601b614dc6565b8e8e868181106118c1576118c1614b15565b905060200201358d8d878181106118da576118da614b15565b9050602002013560405160008152602001604052604051611917949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611939573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119b9576119b9614e30565b60028111156119ca576119ca614e30565b90525092506001836020015160028111156119e7576119e7614e30565b14611a4e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b51565b8251600090879060ff16601f8110611a6857611a68614b15565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611aea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b51565b8086846000015160ff16601f8110611b0457611b04614b15565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b2f600186614dc6565b94505080611b3c90614b73565b9050611883565b505050611b54833383858e8e6135e3565b5050505050505050505050565b6040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8616600482015263ffffffff831660248201526000907f00000000000000000000000000000000000000000000000000000000000000009073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611c0157600080fd5b505afa158015611c15573d6000803e3d6000fd5b50505050620f4240831115611c56576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611ce488888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610686915050565b69ffffffffffffffffffff1690506000611d3589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611da8915050565b9050611d43878784846138ea565b9a9950505050505050505050565b6060600e8054611d6090614959565b9050600003611d9b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610da390614959565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611e15573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e399190614e83565b9392505050565b855185518560ff16601f831115611eb3576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b51565b80600003611f1d576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b51565b818314611fab576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b51565b611fb6816003614ea0565b831161201e576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b51565b612026612875565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a081018690529061206d9088613a4c565b600554156122225760055460009061208790600190614db3565b905060006005828154811061209e5761209e614b15565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff909216935090849081106120d8576120d8614b15565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061215857612158614eb7565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806121c1576121c1614eb7565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061206d915050565b60005b815151811015612689576000600460008460000151848151811061224b5761224b614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561229557612295614e30565b146122fc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b51565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061232d5761232d614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156123ce576123ce614e30565b0217905550600091506123de9050565b60046000846020015184815181106123f8576123f8614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561244257612442614e30565b146124a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b51565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106124dc576124dc614b15565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561257d5761257d614e30565b02179055505082518051600592508390811061259b5761259b614b15565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061261757612617614b15565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061268181614b73565b915050612225565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161274191849174010000000000000000000000000000000000000000900416614ee6565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127a04630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613a69565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612857988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614f03565b60405180910390a1611b54565b61286c612875565b61068381613b14565b60005473ffffffffffffffffffffffffffffffffffffffff1633146128f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b51565b565b6000612902610cdd565b9050805160000361293f576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d5460009161295e916bffffffffffffffffffffffff16614f89565b905060005b82518160ff161015612a305781600c6000858460ff168151811061298957612989614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129f19190614fb4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612a2990614fd9565b9050612963565b508151612a3d9082614ff8565b600d8054600090612a5d9084906bffffffffffffffffffffffff16614bab565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612af557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612aca575b5050505050905060005b8151811015612b6e578373ffffffffffffffffffffffffffffffffffffffff16828281518110612b3157612b31614b15565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612b5e575060019392505050565b612b6781614b73565b9050612aff565b5060009392505050565b600080600080600080600080600089806020019051810190612b9a9190615028565b98509850985098509850985098509850985060008113612be9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b51565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612e6d908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60095460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612ef0576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612efc8887610686565b90506000612f0a8988611da8565b90506000612f2e886040015189606001518569ffffffffffffffffffff16856138ea565b88516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612fcf573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261301591908101906150d4565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156130a6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130ca91906151c0565b509150506bffffffffffffffffffffffff85166130e78385614bab565b6bffffffffffffffffffffffff16101561312d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006131ac308e602001518f6000015185600161314a9190615212565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff1681526020016009600001600c9054906101000a900463ffffffff16600960000160089054906101000a900463ffffffff166132989190614ee6565b63ffffffff1664ffffffffff1681526020018f606001518152509050806008600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd826040516134dc9190615233565b60405180910390a250600954909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613542826020614ea0565b61354d856020614ea0565b61355988610144615348565b6135639190615348565b61356d9190615348565b613578906000615348565b9050368114610acb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b51565b606080806135f3848601866153db565b82519295509093509150158061360b57508151835114155b8061361857508051835114155b1561364f576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156138de5760006136b385838151811061367257613672614b15565b602002602001015185848151811061368c5761368c614b15565b60200260200101518585815181106136a6576136a6614b15565b6020026020010151613c09565b905060008160068111156136c9576136c9614e30565b14806136e6575060018160068111156136e4576136e4614e30565b145b15613741578482815181106136fd576136fd614b15565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a26138cd565b600281600681111561375557613755614e30565b036137a55784828151811061376c5761376c614b15565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a26138cd565b60038160068111156137b9576137b9614e30565b03613809578482815181106137d0576137d0614b15565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a26138cd565b600581600681111561381d5761381d614e30565b0361386d5784828151811061383457613834614b15565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a26138cd565b600481600681111561388157613881614e30565b036138cd5784828151811061389857613898614b15565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b506138d781614b73565b9050613652565b50505050505050505050565b6000806138f561133d565b905060008113613934576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b51565b600954600090879061396a9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614ee6565b6139749190614ee6565b63ffffffff1690506000612710600960010154886139929190614ea0565b61399c91906154b8565b6139a69088615348565b9050600083836139be84670de0b6b3a7640000614ea0565b6139c89190614ea0565b6139d291906154b8565b905060006139f16bffffffffffffffffffffffff808916908a16615348565b9050613a09816b033b2e3c9fd0803ce8000000614db3565b821115613a42576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611d438183615348565b6000613a56610cdd565b511115613a6557613a656128f8565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613a8d999897969594939291906154cc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613b93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b51565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600860209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613d5e576002915050611e39565b6000858152600860205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613dae61133d565b905060008113613ded576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b51565b600081613e023a670de0b6b3a7640000614ea0565b613e0c91906154b8565b9050600083610100015164ffffffffff1682613e289190614ea0565b905060008460c0015169ffffffffffffffffffff1682613e489190614fb4565b6040517f3fd67e050000000000000000000000000000000000000000000000000000000081529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff841690633fd67e0590613ece908f908f908f908c908b903390600401615561565b60408051808303816000875af1158015613eec573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f1091906155d2565b9092509050613f1f8186614fb4565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600d805469ffffffffffffffffffff90921693909291613f8c91859116614fb4565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c001518489613ff29190614fb4565b60808d015160c08e015169ffffffffffffffffffff16614012888d614fb4565b61401c9190614fb4565b6140269190614fb4565b8760ff16600681111561403b5761403b614e30565b60405161404c959493929190615601565b60405180910390a28160ff16600681111561406957614069614e30565b9c9b505050505050505050505050565b50805461408590614959565b6000825580601f10614095575050565b601f01602090049060005260206000209081019061068391906140d2565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156140e757600081556001016140d3565b5090565b60008083601f8401126140fd57600080fd5b50813567ffffffffffffffff81111561411557600080fd5b60208301915083602082850101111561412d57600080fd5b9250929050565b6000806020838503121561414757600080fd5b823567ffffffffffffffff81111561415e57600080fd5b61416a858286016140eb565b90969095509350505050565b6000815180845260005b8181101561419c57602081850181015186830182015201614180565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611e396020830184614176565b73ffffffffffffffffffffffffffffffffffffffff8116811461068357600080fd5b60006020828403121561422157600080fd5b8135611e39816141ed565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156142a2576142a261422c565b604052919050565b600082601f8301126142bb57600080fd5b813567ffffffffffffffff8111156142d5576142d561422c565b61430660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161425b565b81815284602083860101111561431b57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461068357600080fd5b803561105781614338565b63ffffffff8116811461068357600080fd5b60008082840360a081121561437f57600080fd5b833567ffffffffffffffff8082111561439757600080fd5b6143a3878388016142aa565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156143d557600080fd5b604051925060808301915082821081831117156143f4576143f461422c565b50604052602084013561440681614338565b81526040840135614416816141ed565b6020820152606084013561442981614359565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b8381101561448757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614455565b509495945050505050565b6040815260006144a56040830185614441565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614513577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614501838351614176565b948601949250908501906001016144c7565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461068357600080fd5b6000806040838503121561454f57600080fd5b823561455a816141ed565b9150602083013561456a81614522565b809150509250929050565b60008060006040848603121561458a57600080fd5b8335614595816141ed565b9250602084013567ffffffffffffffff8111156145b157600080fd5b6145bd868287016140eb565b9497909650939450505050565b602081526000611e396020830184614441565b6000602082840312156145ef57600080fd5b5035919050565b60006020828403121561460857600080fd5b813567ffffffffffffffff81111561461f57600080fd5b61462b848285016142aa565b949350505050565b60006020828403121561464557600080fd5b813567ffffffffffffffff81111561465c57600080fd5b820160e08185031215611e3957600080fd5b60008083601f84011261468057600080fd5b50813567ffffffffffffffff81111561469857600080fd5b6020830191508360208260051b850101111561412d57600080fd5b60008060008060008060008060e0898b0312156146cf57600080fd5b606089018a8111156146e057600080fd5b8998503567ffffffffffffffff808211156146fa57600080fd5b6147068c838d016140eb565b909950975060808b013591508082111561471f57600080fd5b61472b8c838d0161466e565b909750955060a08b013591508082111561474457600080fd5b506147518b828c0161466e565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561478257600080fd5b853561478d81614338565b9450602086013567ffffffffffffffff8111156147a957600080fd5b6147b5888289016140eb565b90955093505060408601356147c981614359565b949793965091946060013592915050565b600067ffffffffffffffff8211156147f4576147f461422c565b5060051b60200190565b600082601f83011261480f57600080fd5b8135602061482461481f836147da565b61425b565b82815260059290921b8401810191818101908684111561484357600080fd5b8286015b8481101561486757803561485a816141ed565b8352918301918301614847565b509695505050505050565b60ff8116811461068357600080fd5b803561105781614872565b60008060008060008060c087890312156148a557600080fd5b863567ffffffffffffffff808211156148bd57600080fd5b6148c98a838b016147fe565b975060208901359150808211156148df57600080fd5b6148eb8a838b016147fe565b96506148f960408a01614881565b9550606089013591508082111561490f57600080fd5b61491b8a838b016142aa565b945061492960808a0161434e565b935060a089013591508082111561493f57600080fd5b5061494c89828a016142aa565b9150509295509295509295565b600181811c9082168061496d57607f821691505b6020821081036149a6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105df57600081815260208120601f850160051c810160208610156149d35750805b601f850160051c820191505b818110156149f2578281556001016149df565b505050505050565b67ffffffffffffffff831115614a1257614a1261422c565b614a2683614a208354614959565b836149ac565b6000601f841160018114614a785760008515614a425750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614b0e565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b82811015614ac75786850135825560209485019460019092019101614aa7565b5086821015614b02577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614ba457614ba4614b44565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614bd057614bd0614b44565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614c0c57600080fd5b83018035915067ffffffffffffffff821115614c2757600080fd5b60200191503681900382131561412d57600080fd5b600060208284031215614c4e57600080fd5b8135611e3981614338565b600060208284031215614c6b57600080fd5b8135611e3981614359565b61ffff8116811461068357600080fd5b600060208284031215614c9857600080fd5b8135611e3981614c76565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461105757600080fd5b600080600080600060a08688031215614d7b57600080fd5b614d8486614d49565b9450602086015193506040860151925060608601519150614da760808701614d49565b90509295509295909350565b818103818111156106ae576106ae614b44565b60ff81811683821601908111156106ae576106ae614b44565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614e2157614e21614ddf565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614e9557600080fd5b8151611e3981614522565b80820281158282048414176106ae576106ae614b44565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614bd057614bd0614b44565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614f338184018a614441565b90508281036080840152614f478189614441565b905060ff871660a084015282810360c0840152614f648187614176565b905067ffffffffffffffff851660e08401528281036101008401526140698185614176565b60006bffffffffffffffffffffffff80841680614fa857614fa8614ddf565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614bd057614bd0614b44565b600060ff821660ff8103614fef57614fef614b44565b60010192915050565b6bffffffffffffffffffffffff81811683821602808216919082811461502057615020614b44565b505092915050565b60008060008060008060008060006101208a8c03121561504757600080fd5b895161505281614359565b60208b015190995061506381614359565b60408b015190985061507481614359565b60608b015190975061508581614359565b60808b015190965061509681614359565b94506150a460a08b01614d49565b935060c08a01516150b481614c76565b8093505060e08a015191506101008a015190509295985092959850929598565b600080600080600060a086880312156150ec57600080fd5b85516150f781614522565b8095505060208087015161510a81614522565b604088015190955061511b816141ed565b606088015190945061512c816141ed565b608088015190935067ffffffffffffffff81111561514957600080fd5b8701601f8101891361515a57600080fd5b805161516861481f826147da565b81815260059190911b8201830190838101908b83111561518757600080fd5b928401925b828410156151ae57835161519f816141ed565b8252928401929084019061518c565b80955050505050509295509295909350565b6000806000606084860312156151d557600080fd5b835180151581146151e557600080fd5b60208501519093506151f681614338565b604085015190925061520781614338565b809150509250925092565b67ffffffffffffffff818116838216019080821115614bd057614bd0614b44565b815167ffffffffffffffff1681526101408101602083015161526d602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615285604084018263ffffffff169052565b5060608301516152ad606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516152cd60808401826bffffffffffffffffffffffff169052565b5060a08301516152ed60a08401826bffffffffffffffffffffffff169052565b5060c083015161530b60c084018269ffffffffffffffffffff169052565b5060e083015161532360e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b808201808211156106ae576106ae614b44565b600082601f83011261536c57600080fd5b8135602061537c61481f836147da565b82815260059290921b8401810191818101908684111561539b57600080fd5b8286015b8481101561486757803567ffffffffffffffff8111156153bf5760008081fd5b6153cd8986838b01016142aa565b84525091830191830161539f565b6000806000606084860312156153f057600080fd5b833567ffffffffffffffff8082111561540857600080fd5b818601915086601f83011261541c57600080fd5b8135602061542c61481f836147da565b82815260059290921b8401810191818101908a84111561544b57600080fd5b948201945b8386101561546957853582529482019490820190615450565b9750508701359250508082111561547f57600080fd5b61548b8783880161535b565b935060408601359150808211156154a157600080fd5b506154ae8682870161535b565b9150509250925092565b6000826154c7576154c7614ddf565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526155138285018b614441565b91508382036080850152615527828a614441565b915060ff881660a085015283820360c08501526155448288614176565b90861660e085015283810361010085015290506140698185614176565b86815260c06020820152600061557a60c0830188614176565b828103604084015261558c8188614176565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156155e557600080fd5b82516155f081614872565b602084015190925061456a81614522565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a0810160078310615677577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005d3738038062005d37833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516156ac6200068b60003960008181610a3901528181610e5c015281816110ac0152818161113601528181611b9e01528181611de601528181612f680152613eaa015260006115db01526156ac6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610555578063de9dfa461461055d578063e3d0e71214610570578063f2fde38b1461058357600080fd5b8063b1dc65a414610414578063c3f909d414610427578063d227d2451461052557600080fd5b8063aecc12c5116100c8578063aecc12c5146103ac578063af1296d3146103ec578063afcb95d7146103f457600080fd5b80638cc6acce1461035f5780638da5cb5b146103725780639883c10d1461039a57600080fd5b806379ba50971161015b578063814118341161013557806381411834146102b257806381f1b938146102c757806381ff7048146102cf57806385b214cf1461033c57600080fd5b806379ba5097146102845780637f15e1661461028c578063807560311461029f57600080fd5b8063466557181161018c578063466557181461022d578063533989871461025b57806366316d8d1461027157600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac1461021a575b600080fd5b6101c66101c136600461416b565b610596565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190614211565b60405180910390f35b6101c6610228366004614246565b6105eb565b61024061023b3660046143a2565b61068d565b60405169ffffffffffffffffffff9091168152602001610211565b6102636106bb565b6040516102119291906144c9565b6101c661027f366004614573565b61093f565b6101c6610af9565b6101c661029a36600461416b565b610bfb565b6101c66102ad3660046145ac565b610c4b565b6102ba610d02565b6040516102119190614601565b610204610d71565b61031960015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b61034f61034a366004614614565b610e42565b6040519015158152602001610211565b6101c661036d36600461462d565b611094565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6007545b604051908152602001610211565b6103bf6103ba36600461466a565b611119565b604080519485526bffffffffffffffffffffffff9093166020850152918301526060820152608001610211565b61039e611375565b604080516001815260006020820181905291810191909152606001610211565b6101c66104223660046146ea565b611468565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff1661012082015261014001610211565b6105386105333660046147a1565b611b99565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611d8b565b61053861056b3660046143a2565b611de2565b6101c661057e3660046148c3565b611e7a565b6101c6610591366004614246565b61289e565b61059e6128af565b60008190036105d9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105e6828483614a31565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061062657503373ffffffffffffffffffffffffffffffffffffffff8216145b61065c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061068a916140b0565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561072357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106f8575b505050505090506000815167ffffffffffffffff81111561074657610746614263565b60405190808252806020026020018201604052801561077957816020015b60608152602001906001900390816107645790505b50905060005b825181101561093557600f600084838151811061079e5761079e614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107eb90614990565b9050600003610826576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061083c5761083c614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461088990614990565b80601f01602080910402602001604051908101604052809291908181526020018280546108b590614990565b80156109025780601f106108d757610100808354040283529160200191610902565b820191906000526020600020905b8154815290600101906020018083116108e557829003601f168201915b505050505082828151811061091957610919614b4c565b60200260200101819052508061092e90614baa565b905061077f565b5090939092509050565b610947612932565b806bffffffffffffffffffffffff1660000361097d5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109d7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c602052604081208054839290610a049084906bffffffffffffffffffffffff16614be2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610a5b7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610adc57600080fd5b505af1158015610af0573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c036128af565b6000819003610c3e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105e6828483614a31565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c965750610c7533612ac3565b8015610c9657503373ffffffffffffffffffffffffffffffffffffffff8416145b610ccc576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cfc828483614a31565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d6757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d3c575b5050505050905090565b606060108054610d8090614990565b9050600003610dbb576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610dc890614990565b80601f0160208091040260200160405190810160405280929190818152602001828054610df490614990565b8015610d675780601f10610e1657610100808354040283529160200191610d67565b820191906000526020600020905b815481529060010190602001808311610e2457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610eb3576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff16610100840152600301546101208301526110075750600092915050565b600083815260086020526040808220828155600181018390556002810180547fff0000000000000000000000000000000000000000000000000000000000000016905560030191909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906110819085815260200190565b60405180910390a160019150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611103576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61110c81612bac565b8051602090910120600755565b60008080803373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461118d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61119a6040860186614c0e565b90506000036111d4576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808760600160208101906111f49190614c73565b67ffffffffffffffff16815260209081019061121290890189614246565b73ffffffffffffffffffffffffffffffffffffffff16815260200161123d60e0890160c08a01614c90565b63ffffffff1681523a60209091015290506112a961125e6040880188614c0e565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506112a39250505060a0890160808a01614cbd565b83612eb5565b929750909550935091506112c06020870187614246565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c3261130960808b0160608c01614c73565b61131960408c0160208d01614246565b61132660408d018d614c0e565b8d60800160208101906113399190614cbd565b8e60a001358f60c00160208101906113519190614c90565b604051611365989796959493929190614cda565b60405180910390a3509193509193565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa15801561140f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114339190614d9a565b50935050925050828015611455575061144c8142614dea565b8463ffffffff16105b1561146057600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c0135916114be91849163ffffffff851691908e908e908190840183828082843760009201919091525061356392505050565b6114f4576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146115c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b76565b6115d78b8b8b8b8b8b61356c565b60007f000000000000000000000000000000000000000000000000000000000000000015611634576002826020015183604001516116159190614dfd565b61161f9190614e45565b61162a906001614dfd565b60ff16905061164a565b6020820151611644906001614dfd565b60ff1690505b8881146116b3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b76565b88871461171c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b76565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561175f5761175f614e67565b600281111561177057611770614e67565b905250905060028160200151600281111561178d5761178d614e67565b1480156117d457506006816000015160ff16815481106117af576117af614b4c565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b61183a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b76565b50505050506118476140ea565b6000808a8a60405161185a929190614e96565b604051908190038120611871918e90602001614ea6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b7b5760006001848984602081106118da576118da614b4c565b6118e791901a601b614dfd565b8e8e868181106118f9576118f9614b4c565b905060200201358d8d8781811061191257611912614b4c565b905060200201356040516000815260200160405260405161194f949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611971573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119f1576119f1614e67565b6002811115611a0257611a02614e67565b9052509250600183602001516002811115611a1f57611a1f614e67565b14611a86576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b76565b8251600090879060ff16601f8110611aa057611aa0614b4c565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611b22576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b76565b8086846000015160ff16601f8110611b3c57611b3c614b4c565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b67600186614dfd565b94505080611b7490614baa565b90506118bb565b505050611b8c833383858e8e61361a565b5050505050505050505050565b6000807f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8916600482015263ffffffff8616602482015290915073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611c3b57600080fd5b505afa158015611c4f573d6000803e3d6000fd5b50505050620f4240831115611c90576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611d1e88888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061068d915050565b69ffffffffffffffffffff1690506000611d6f89898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611de2915050565b9050611d7d87878484613921565b9a9950505050505050505050565b6060600e8054611d9a90614990565b9050600003611dd5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610dc890614990565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611e4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e739190614eba565b9392505050565b855185518560ff16601f831115611eed576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b76565b80600003611f57576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b76565b818314611fe5576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b76565b611ff0816003614ed7565b8311612058576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b76565b6120606128af565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a08101869052906120a79088613a83565b6005541561225c576005546000906120c190600190614dea565b90506000600582815481106120d8576120d8614b4c565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061211257612112614b4c565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061219257612192614eee565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806121fb576121fb614eee565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120a7915050565b60005b8151518110156126c3576000600460008460000151848151811061228557612285614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122cf576122cf614e67565b14612336576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b76565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061236757612367614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561240857612408614e67565b0217905550600091506124189050565b600460008460200151848151811061243257612432614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561247c5761247c614e67565b146124e3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b76565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061251657612516614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156125b7576125b7614e67565b0217905550508251805160059250839081106125d5576125d5614b4c565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061265157612651614b4c565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806126bb81614baa565b91505061225f565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161277b91849174010000000000000000000000000000000000000000900416614f1d565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127da4630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613aa0565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612891988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614f3a565b60405180910390a1611b8c565b6128a66128af565b61068a81613b4b565b60005473ffffffffffffffffffffffffffffffffffffffff163314612930576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b76565b565b600061293c610d02565b90508051600003612979576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d54600091612998916bffffffffffffffffffffffff16614fc0565b905060005b8251811015612a645781600c60008584815181106129bd576129bd614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612a259190614feb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612a5d90614baa565b905061299d565b508151612a719082615010565b600d8054600090612a919084906bffffffffffffffffffffffff16614be2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612b2957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612afe575b5050505050905060005b8151811015612ba2578373ffffffffffffffffffffffffffffffffffffffff16828281518110612b6557612b65614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612b92575060019392505050565b612b9b81614baa565b9050612b33565b5060009392505050565b600080600080600080600080600089806020019051810190612bce9190615040565b98509850985098509850985098509850985060008113612c1d576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b76565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612ea1908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60095460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612f24576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612f30888761068d565b90506000612f3e8988611de2565b90506000612f62886040015189606001518569ffffffffffffffffffff1685613921565b905060007f000000000000000000000000000000000000000000000000000000000000000089516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015613006573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261304c91908101906150ec565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156130dd573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061310191906151d8565b509150506bffffffffffffffffffffffff851661311e8385614be2565b6bffffffffffffffffffffffff161015613164576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006131e3308e602001518f60000151856001613181919061522a565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff1681526020016009600001600c9054906101000a900463ffffffff16600960000160089054906101000a900463ffffffff166132cf9190614f1d565b63ffffffff1664ffffffffff1681526020018f606001518152509050806008600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd82604051613513919061524b565b60405180910390a250600954909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613579826020614ed7565b613584856020614ed7565b61359088610144615360565b61359a9190615360565b6135a49190615360565b6135af906000615360565b9050368114610af0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b76565b6060808061362a848601866153f3565b82519295509093509150158061364257508151835114155b8061364f57508051835114155b15613686576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156139155760006136ea8583815181106136a9576136a9614b4c565b60200260200101518584815181106136c3576136c3614b4c565b60200260200101518585815181106136dd576136dd614b4c565b6020026020010151613c40565b9050600081600681111561370057613700614e67565b148061371d5750600181600681111561371b5761371b614e67565b145b156137785784828151811061373457613734614b4c565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613904565b600281600681111561378c5761378c614e67565b036137dc578482815181106137a3576137a3614b4c565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613904565b60038160068111156137f0576137f0614e67565b036138405784828151811061380757613807614b4c565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613904565b600581600681111561385457613854614e67565b036138a45784828151811061386b5761386b614b4c565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a2613904565b60048160068111156138b8576138b8614e67565b03613904578482815181106138cf576138cf614b4c565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b5061390e81614baa565b9050613689565b50505050505050505050565b60008061392c611375565b90506000811361396b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b76565b60095460009087906139a19063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614f1d565b6139ab9190614f1d565b63ffffffff1690506000612710600960010154886139c99190614ed7565b6139d391906154d0565b6139dd9088615360565b9050600083836139f584670de0b6b3a7640000614ed7565b6139ff9190614ed7565b613a0991906154d0565b90506000613a286bffffffffffffffffffffffff808916908a16615360565b9050613a40816b033b2e3c9fd0803ce8000000614dea565b821115613a79576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611d7d8183615360565b6000613a8d610d02565b511115613a9c57613a9c612932565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613ac4999897969594939291906154e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613bca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b76565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600860209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613d95576002915050611e73565b6000858152600860205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613de5611375565b905060008113613e24576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b76565b600081613e393a670de0b6b3a7640000614ed7565b613e4391906154d0565b9050600083610100015164ffffffffff1682613e5f9190614ed7565b905060008460c0015169ffffffffffffffffffff1682613e7f9190614feb565b6040517f3fd67e050000000000000000000000000000000000000000000000000000000081529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff841690633fd67e0590613f05908f908f908f908c908b903390600401615579565b60408051808303816000875af1158015613f23573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f4791906155ea565b9092509050613f568186614feb565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600d805469ffffffffffffffffffff90921693909291613fc391859116614feb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c0015184896140299190614feb565b60808d015160c08e015169ffffffffffffffffffff16614049888d614feb565b6140539190614feb565b61405d9190614feb565b8760ff16600681111561407257614072614e67565b604051614083959493929190615619565b60405180910390a28160ff1660068111156140a0576140a0614e67565b9c9b505050505050505050505050565b5080546140bc90614990565b6000825580601f106140cc575050565b601f01602090049060005260206000209081019061068a9190614109565b604051806103e00160405280601f906020820280368337509192915050565b5b8082111561411e576000815560010161410a565b5090565b60008083601f84011261413457600080fd5b50813567ffffffffffffffff81111561414c57600080fd5b60208301915083602082850101111561416457600080fd5b9250929050565b6000806020838503121561417e57600080fd5b823567ffffffffffffffff81111561419557600080fd5b6141a185828601614122565b90969095509350505050565b6000815180845260005b818110156141d3576020818501810151868301820152016141b7565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611e7360208301846141ad565b73ffffffffffffffffffffffffffffffffffffffff8116811461068a57600080fd5b60006020828403121561425857600080fd5b8135611e7381614224565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156142d9576142d9614263565b604052919050565b600082601f8301126142f257600080fd5b813567ffffffffffffffff81111561430c5761430c614263565b61433d60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614292565b81815284602083860101111561435257600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461068a57600080fd5b803561108f8161436f565b63ffffffff8116811461068a57600080fd5b60008082840360a08112156143b657600080fd5b833567ffffffffffffffff808211156143ce57600080fd5b6143da878388016142e1565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561440c57600080fd5b6040519250608083019150828210818311171561442b5761442b614263565b50604052602084013561443d8161436f565b8152604084013561444d81614224565b6020820152606084013561446081614390565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156144be57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161448c565b509495945050505050565b6040815260006144dc6040830185614478565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561454a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526145388383516141ad565b948601949250908501906001016144fe565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461068a57600080fd5b6000806040838503121561458657600080fd5b823561459181614224565b915060208301356145a181614559565b809150509250929050565b6000806000604084860312156145c157600080fd5b83356145cc81614224565b9250602084013567ffffffffffffffff8111156145e857600080fd5b6145f486828701614122565b9497909650939450505050565b602081526000611e736020830184614478565b60006020828403121561462657600080fd5b5035919050565b60006020828403121561463f57600080fd5b813567ffffffffffffffff81111561465657600080fd5b614662848285016142e1565b949350505050565b60006020828403121561467c57600080fd5b813567ffffffffffffffff81111561469357600080fd5b820160e08185031215611e7357600080fd5b60008083601f8401126146b757600080fd5b50813567ffffffffffffffff8111156146cf57600080fd5b6020830191508360208260051b850101111561416457600080fd5b60008060008060008060008060e0898b03121561470657600080fd5b606089018a81111561471757600080fd5b8998503567ffffffffffffffff8082111561473157600080fd5b61473d8c838d01614122565b909950975060808b013591508082111561475657600080fd5b6147628c838d016146a5565b909750955060a08b013591508082111561477b57600080fd5b506147888b828c016146a5565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156147b957600080fd5b85356147c48161436f565b9450602086013567ffffffffffffffff8111156147e057600080fd5b6147ec88828901614122565b909550935050604086013561480081614390565b949793965091946060013592915050565b600067ffffffffffffffff82111561482b5761482b614263565b5060051b60200190565b600082601f83011261484657600080fd5b8135602061485b61485683614811565b614292565b82815260059290921b8401810191818101908684111561487a57600080fd5b8286015b8481101561489e57803561489181614224565b835291830191830161487e565b509695505050505050565b60ff8116811461068a57600080fd5b803561108f816148a9565b60008060008060008060c087890312156148dc57600080fd5b863567ffffffffffffffff808211156148f457600080fd5b6149008a838b01614835565b9750602089013591508082111561491657600080fd5b6149228a838b01614835565b965061493060408a016148b8565b9550606089013591508082111561494657600080fd5b6149528a838b016142e1565b945061496060808a01614385565b935060a089013591508082111561497657600080fd5b5061498389828a016142e1565b9150509295509295509295565b600181811c908216806149a457607f821691505b6020821081036149dd577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105e657600081815260208120601f850160051c81016020861015614a0a5750805b601f850160051c820191505b81811015614a2957828155600101614a16565b505050505050565b67ffffffffffffffff831115614a4957614a49614263565b614a5d83614a578354614990565b836149e3565b6000601f841160018114614aaf5760008515614a795750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614b45565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b82811015614afe5786850135825560209485019460019092019101614ade565b5086821015614b39577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614bdb57614bdb614b7b565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614c0757614c07614b7b565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614c4357600080fd5b83018035915067ffffffffffffffff821115614c5e57600080fd5b60200191503681900382131561416457600080fd5b600060208284031215614c8557600080fd5b8135611e738161436f565b600060208284031215614ca257600080fd5b8135611e7381614390565b61ffff8116811461068a57600080fd5b600060208284031215614ccf57600080fd5b8135611e7381614cad565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461108f57600080fd5b600080600080600060a08688031215614db257600080fd5b614dbb86614d80565b9450602086015193506040860151925060608601519150614dde60808701614d80565b90509295509295909350565b818103818111156106b5576106b5614b7b565b60ff81811683821601908111156106b5576106b5614b7b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614e5857614e58614e16565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614ecc57600080fd5b8151611e7381614559565b80820281158282048414176106b5576106b5614b7b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614c0757614c07614b7b565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614f6a8184018a614478565b90508281036080840152614f7e8189614478565b905060ff871660a084015282810360c0840152614f9b81876141ad565b905067ffffffffffffffff851660e08401528281036101008401526140a081856141ad565b60006bffffffffffffffffffffffff80841680614fdf57614fdf614e16565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614c0757614c07614b7b565b6bffffffffffffffffffffffff81811683821602808216919082811461503857615038614b7b565b505092915050565b60008060008060008060008060006101208a8c03121561505f57600080fd5b895161506a81614390565b60208b015190995061507b81614390565b60408b015190985061508c81614390565b60608b015190975061509d81614390565b60808b01519096506150ae81614390565b94506150bc60a08b01614d80565b935060c08a01516150cc81614cad565b8093505060e08a015191506101008a015190509295985092959850929598565b600080600080600060a0868803121561510457600080fd5b855161510f81614559565b8095505060208087015161512281614559565b604088015190955061513381614224565b606088015190945061514481614224565b608088015190935067ffffffffffffffff81111561516157600080fd5b8701601f8101891361517257600080fd5b805161518061485682614811565b81815260059190911b8201830190838101908b83111561519f57600080fd5b928401925b828410156151c65783516151b781614224565b825292840192908401906151a4565b80955050505050509295509295909350565b6000806000606084860312156151ed57600080fd5b835180151581146151fd57600080fd5b602085015190935061520e8161436f565b604085015190925061521f8161436f565b809150509250925092565b67ffffffffffffffff818116838216019080821115614c0757614c07614b7b565b815167ffffffffffffffff16815261014081016020830151615285602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161529d604084018263ffffffff169052565b5060608301516152c5606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516152e560808401826bffffffffffffffffffffffff169052565b5060a083015161530560a08401826bffffffffffffffffffffffff169052565b5060c083015161532360c084018269ffffffffffffffffffff169052565b5060e083015161533b60e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b808201808211156106b5576106b5614b7b565b600082601f83011261538457600080fd5b8135602061539461485683614811565b82815260059290921b840181019181810190868411156153b357600080fd5b8286015b8481101561489e57803567ffffffffffffffff8111156153d75760008081fd5b6153e58986838b01016142e1565b8452509183019183016153b7565b60008060006060848603121561540857600080fd5b833567ffffffffffffffff8082111561542057600080fd5b818601915086601f83011261543457600080fd5b8135602061544461485683614811565b82815260059290921b8401810191818101908a84111561546357600080fd5b948201945b8386101561548157853582529482019490820190615468565b9750508701359250508082111561549757600080fd5b6154a387838801615373565b935060408601359150808211156154b957600080fd5b506154c686828701615373565b9150509250925092565b6000826154df576154df614e16565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b16604085015281606085015261552b8285018b614478565b9150838203608085015261553f828a614478565b915060ff881660a085015283820360c085015261555c82886141ad565b90861660e085015283810361010085015290506140a081856141ad565b86815260c06020820152600061559260c08301886141ad565b82810360408401526155a481886141ad565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156155fd57600080fd5b8251615608816148a9565b60208401519092506145a181614559565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a081016007831061568f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -948,6 +948,123 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseBillingStart(log return event, nil } +type FunctionsCoordinatorCommitmentDeletedIterator struct { + Event *FunctionsCoordinatorCommitmentDeleted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsCoordinatorCommitmentDeletedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsCoordinatorCommitmentDeleted) + 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(FunctionsCoordinatorCommitmentDeleted) + 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 *FunctionsCoordinatorCommitmentDeletedIterator) Error() error { + return it.fail +} + +func (it *FunctionsCoordinatorCommitmentDeletedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsCoordinatorCommitmentDeleted struct { + RequestId [32]byte + Raw types.Log +} + +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterCommitmentDeleted(opts *bind.FilterOpts) (*FunctionsCoordinatorCommitmentDeletedIterator, error) { + + logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "CommitmentDeleted") + if err != nil { + return nil, err + } + return &FunctionsCoordinatorCommitmentDeletedIterator{contract: _FunctionsCoordinator.contract, event: "CommitmentDeleted", logs: logs, sub: sub}, nil +} + +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchCommitmentDeleted(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCommitmentDeleted) (event.Subscription, error) { + + logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "CommitmentDeleted") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsCoordinatorCommitmentDeleted) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "CommitmentDeleted", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseCommitmentDeleted(log types.Log) (*FunctionsCoordinatorCommitmentDeleted, error) { + event := new(FunctionsCoordinatorCommitmentDeleted) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "CommitmentDeleted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type FunctionsCoordinatorConfigChangedIterator struct { Event *FunctionsCoordinatorConfigChanged @@ -2249,133 +2366,6 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOwnershipTransfe return event, nil } -type FunctionsCoordinatorRequestTimedOutIterator struct { - Event *FunctionsCoordinatorRequestTimedOut - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorRequestTimedOutIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorRequestTimedOut) - 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(FunctionsCoordinatorRequestTimedOut) - 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 *FunctionsCoordinatorRequestTimedOutIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorRequestTimedOutIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorRequestTimedOut struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorRequestTimedOutIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "RequestTimedOut", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorRequestTimedOutIterator{contract: _FunctionsCoordinator.contract, event: "RequestTimedOut", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorRequestTimedOut, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "RequestTimedOut", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorRequestTimedOut) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "RequestTimedOut", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseRequestTimedOut(log types.Log) (*FunctionsCoordinatorRequestTimedOut, error) { - event := new(FunctionsCoordinatorRequestTimedOut) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "RequestTimedOut", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - type FunctionsCoordinatorTransmittedIterator struct { Event *FunctionsCoordinatorTransmitted @@ -2523,6 +2513,8 @@ func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (gene return _FunctionsCoordinator.ParseBillingEnd(log) case _FunctionsCoordinator.abi.Events["BillingStart"].ID: return _FunctionsCoordinator.ParseBillingStart(log) + case _FunctionsCoordinator.abi.Events["CommitmentDeleted"].ID: + return _FunctionsCoordinator.ParseCommitmentDeleted(log) case _FunctionsCoordinator.abi.Events["ConfigChanged"].ID: return _FunctionsCoordinator.ParseConfigChanged(log) case _FunctionsCoordinator.abi.Events["ConfigSet"].ID: @@ -2543,8 +2535,6 @@ func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (gene return _FunctionsCoordinator.ParseOwnershipTransferRequested(log) case _FunctionsCoordinator.abi.Events["OwnershipTransferred"].ID: return _FunctionsCoordinator.ParseOwnershipTransferred(log) - case _FunctionsCoordinator.abi.Events["RequestTimedOut"].ID: - return _FunctionsCoordinator.ParseRequestTimedOut(log) case _FunctionsCoordinator.abi.Events["Transmitted"].ID: return _FunctionsCoordinator.ParseTransmitted(log) @@ -2561,6 +2551,10 @@ func (FunctionsCoordinatorBillingStart) Topic() common.Hash { return common.HexToHash("0xe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd") } +func (FunctionsCoordinatorCommitmentDeleted) Topic() common.Hash { + return common.HexToHash("0x8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416") +} + func (FunctionsCoordinatorConfigChanged) Topic() common.Hash { return common.HexToHash("0x3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f") } @@ -2601,10 +2595,6 @@ func (FunctionsCoordinatorOwnershipTransferred) Topic() common.Hash { return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") } -func (FunctionsCoordinatorRequestTimedOut) Topic() common.Hash { - return common.HexToHash("0xf1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af414") -} - func (FunctionsCoordinatorTransmitted) Topic() common.Hash { return common.HexToHash("0xb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62") } @@ -2684,6 +2674,12 @@ type FunctionsCoordinatorInterface interface { ParseBillingStart(log types.Log) (*FunctionsCoordinatorBillingStart, error) + FilterCommitmentDeleted(opts *bind.FilterOpts) (*FunctionsCoordinatorCommitmentDeletedIterator, error) + + WatchCommitmentDeleted(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCommitmentDeleted) (event.Subscription, error) + + ParseCommitmentDeleted(log types.Log) (*FunctionsCoordinatorCommitmentDeleted, error) + FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigChangedIterator, error) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigChanged) (event.Subscription, error) @@ -2744,12 +2740,6 @@ type FunctionsCoordinatorInterface interface { ParseOwnershipTransferred(log types.Log) (*FunctionsCoordinatorOwnershipTransferred, error) - FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorRequestTimedOutIterator, error) - - WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorRequestTimedOut, requestId [][32]byte) (event.Subscription, error) - - ParseRequestTimedOut(log types.Log) (*FunctionsCoordinatorRequestTimedOut, error) - FilterTransmitted(opts *bind.FilterOpts) (*FunctionsCoordinatorTransmittedIterator, error) WatchTransmitted(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorTransmitted) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index ce06b00d82d..137f4d8c830 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -31,8 +31,8 @@ var ( ) var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526009805463ffffffff191690553480156200001e57600080fd5b506040516200645738038062006457833981016040819052620000419162000459565b6000805460ff1916815582903390869086908590849081620000aa5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e457620000e481620001a0565b50506009805461ffff8481166401000000000261ffff60201b199187166601000000000000029190911663ffffffff60201b19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b03191630179055620001668162000251565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d39350505050565b336001600160a01b03821603620001fa5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a1565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200026c919062000556565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002e491601091908601906200032b565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200031d9392919062000662565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003cf5791602002820160005b838211156200039b57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000355565b8015620003cd5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200039b565b505b50620003dd929150620003e1565b5090565b5b80821115620003dd5760008155600101620003e2565b805161ffff811681146200040b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000451576200045162000410565b604052919050565b600080600080608085870312156200047057600080fd5b6200047b85620003f8565b935060206200048c818701620003f8565b60408701519094506001600160a01b0381168114620004aa57600080fd5b60608701519093506001600160401b0380821115620004c857600080fd5b818801915088601f830112620004dd57600080fd5b815181811115620004f257620004f262000410565b62000506601f8201601f1916850162000426565b915080825289848285010111156200051d57600080fd5b60005b818110156200053d57838101850151838201860152840162000520565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200056c57600080fd5b83516001600160601b03811681146200058457600080fd5b602085810151919450906001600160e01b031981168114620005a557600080fd5b60408601519093506001600160401b0380821115620005c357600080fd5b818701915087601f830112620005d857600080fd5b815181811115620005ed57620005ed62000410565b8060051b91506200060084830162000426565b818152918301840191848101908a8411156200061b57600080fd5b938501935b8385101562000652578451925063ffffffff83168314620006415760008081fd5b828252938501939085019062000620565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c557845163ffffffff1683529383019391830191600101620006a1565b509098975050505050505050565b615d7480620006e36000396000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806371ec28ac1161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d41461078f578063eb523d6c146107a2578063f2fde38b146107b557600080fd5b8063c4614d6114610756578063d7ae1d3014610769578063e72f6e301461077c57600080fd5b8063b5643858116100c8578063b564385814610724578063b734c0f414610737578063badc3eb61461073f57600080fd5b8063a9c9a918146106e0578063aab396bd146106f3578063b187bd261461071957600080fd5b80638fde531711610150578063a21a23e41161012a578063a21a23e4146106a1578063a47c7696146106a9578063a4c0ed36146106cd57600080fd5b80638fde53171461067e5780639883c10d146106865780639f87fad71461068e57600080fd5b806379ba50971161018157806379ba50971461064057806382359740146106485780638da5cb5b1461065b57600080fd5b806371ec28ac146106265780637341c10c1461062d57600080fd5b80633fd67e05116102555780635ed6dfba11610209578063665871ec116101e3578063665871ec14610546578063674603d0146105595780636a6df79b146105ee57600080fd5b80635ed6dfba146104ec57806366316d8d146104ff578063664199701461051257600080fd5b806354fd4d501161023a57806354fd4d501461049657806355fedefa146104c25780635c975abb146104d557600080fd5b80633fd67e051461043c578063461d27621461047557600080fd5b8063181f5a77116102b757806336566f061161029157806336566f061461040e578063385de9ae146104165780633e871e4d1461042957600080fd5b8063181f5a77146103a35780631ded3b36146103e55780632a905ccc146103f857600080fd5b80630c5d49cb116102e85780630c5d49cb1461032c57806310fc49c11461034c57806312b583491461035f57600080fd5b806302bcc5b61461030457806304c357cb14610319575b600080fd5b610317610312366004614ca7565b6107c8565b005b610317610327366004614ce6565b610855565b610334608481565b60405161ffff90911681526020015b60405180910390f35b61031761035a366004614d2b565b610952565b6009547101000000000000000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610343565b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103439190614dc6565b6103176103f3366004614dd9565b61095c565b600f546bffffffffffffffffffffffff16610386565b61031761098d565b610317610424366004614e4c565b6109b2565b610317610437366004614fac565b610b9a565b61044f61044a36600461510d565b610eb4565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610343565b6104886104833660046151c1565b61123d565b604051908152602001610343565b600954604080516001815261ffff80841660208301526201000090930490921690820152606001610343565b6104886104d0366004614ca7565b611291565b60005460ff165b6040519015158152602001610343565b6103176104fa366004615243565b6112b5565b61031761050d366004615243565b611591565b6009546901000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610343565b61031761055436600461526f565b6117b8565b6105c66105673660046152e4565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610343565b6106016105fc36600461531c565b611b7d565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610343565b6064610334565b61031761063b366004614ce6565b611b90565b610317611d3d565b610317610656366004614ca7565b611e5f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610601565b610317611fae565b600754610488565b61031761069c366004614ce6565b61205d565b61052d612465565b6106bc6106b7366004614ca7565b6125fe565b604051610343959493929190615392565b6103176106db3660046153e7565b6126ea565b6106016106ee366004615441565b612919565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610488565b60005460ff166104dc565b61031761073236600461545a565b612926565b610317612a85565b610747612c99565b60405161034393929190615475565b6103d8610764366004614e4c565b612d74565b610317610777366004614ce6565b612d89565b61031761078a3660046154d6565b612de2565b6104dc61079d366004614ca7565b612ff4565b6103176107b0366004615441565b612fff565b6103176107c33660046154d6565b61326f565b6107d0613280565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680610847576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108518282613288565b5050565b61085d6135f6565b610866826135fe565b61086e6136c4565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108515767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b61085182826137cb565b610964613280565b61096d826138eb565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b610995613961565b60005460ff16156109aa576109a86139e7565b565b6109a8613a64565b6109ba613961565b60006109c7846000613abf565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109f15750600754610a65565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a3e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a6291906154f1565b90505b8383604051610a7592919061550a565b60405180910390208103610ab5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610b20906601000000000000900461ffff1643615549565b9052600086815260066020908152604090912082518155908201516001820190610b4a90826155fd565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b8b908790849088908890615717565b60405180910390a15050505050565b610ba2613961565b8151815181141580610bb45750600881115b15610beb576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b818160ff161015610d25576000848260ff1681518110610c1057610c10615772565b602002602001015190506000848360ff1681518110610c3157610c31615772565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c9c575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cd3576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610d12576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610d1e906157a1565b9050610bee565b50600954600090610d44906601000000000000900461ffff1643615549565b604080516060810182528681526020808201879052918101839052865192935091600391610d76918391890190614af0565b506020828101518051610d8f9260018501920190614b37565b506040820151816002015590505060005b84518160ff161015610ead577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610de257610de2615772565b602002602001015160026000888560ff1681518110610e0357610e03615772565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868460ff1681518110610e4f57610e4f615772565b602002602001015185604051610e95949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610ea6816157a1565b9050610da0565b5050505050565b600080610ebf6135f6565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314611001576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff1661102a576002925050611232565b8060e00151816080015163ffffffff1661104491906157c0565b6effffffffffffffffffffffffffffff165a1015611066576003925050611232565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff909116906110a99063ffffffff16613bbf565b6110b390886157ef565b82516110c090889061581f565b6110ca919061581f565b6bffffffffffffffffffffffff1611156110e8576004925050611232565b8060a001516bffffffffffffffffffffffff1661110e826080015163ffffffff16613bbf565b61111890886157ef565b825161112590889061581f565b61112f919061581f565b6bffffffffffffffffffffffff16111561114d576005925050611232565b6000898152600e6020526040808220828155600181018390556002018290556080830151908301519194508491611189918c918c918c91613c61565b805190915061119957600161119c565b60005b935060006111c383606001518460a00151856040015186600001518c87602001518d613ddb565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a83602001518989876000015161120c578e61120e565b8f5b8860400151604051611224959493929190615844565b60405180910390a351925050505b965096945050505050565b60006112868260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915061402d9050565b979650505050505050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b6112bd613280565b806bffffffffffffffffffffffff166000036112f35750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561134d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d60205260408120805483929061137a9084906bffffffffffffffffffffffff166158a2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166113d191906158a2565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611470573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061149491906158c7565b61085157600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611507573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061152b91906154f1565b6009546040517fa99da302000000000000000000000000000000000000000000000000000000008152710100000000000000000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610d09565b6115996135f6565b806bffffffffffffffffffffffff166000036115e1576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561163b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906116689084906bffffffffffffffffffffffff166158a2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960118282829054906101000a90046bffffffffffffffffffffffff166116bf91906158a2565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561175e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061178291906158c7565b610851576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6117c06135f6565b60005b81811015611b785760008383838181106117df576117df615772565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e0820152909350919050611902816138eb565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633811461197b576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff164210156119c0576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611a32573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a5691906158c7565b15611b625760a084015167ffffffffffffffff84166000908152600b602052604081206001018054909190611a9a9084906bffffffffffffffffffffffff166158a2565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff808816845291529190208054600192600991611b2191859169010000000000000000009004166158e4565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040812081815560018101829055600201555b505050505080611b7190615905565b90506117c3565b505050565b6000611b898383613abf565b9392505050565b611b986135f6565b611ba1826135fe565b611ba96136c4565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611c1e576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611c65575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610946565b60015473ffffffffffffffffffffffffffffffffffffffff163314611dbe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610d09565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611e676135f6565b611e6f6136c4565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611f0f576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610d09565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611fb6613961565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015612018576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980547fffffffffffffffffffffffffffffffffffffffffffffffff0000ffffffffffff166201000090920461ffff16660100000000000002919091179055565b6120656135f6565b61206e826135fe565b6120766136c4565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152612146576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b806040015167ffffffffffffffff16816020015167ffffffffffffffff161461219b576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b602090815260408083206002018054825181850281018501909352808352919290919083018282801561221657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116121eb575b5050505050905060006001825161222d919061593d565b905060005b82518110156123c9578473ffffffffffffffffffffffffffffffffffffffff1683828151811061226457612264615772565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036123b957600083838151811061229b5761229b615772565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106122e1576122e1615772565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061235b5761235b615950565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506123c9565b6123c281615905565b9050612232565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b600061246f6135f6565b6124776136c4565b60098054819061249d906901000000000000000000900467ffffffffffffffff1661597f565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612513578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926125ae92600285019290910190614b37565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061260f866138eb565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126da57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116126af575b5050505050905091939590929450565b6126f26135f6565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612743576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461277d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061278b82840184614ca7565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff169186919061283b838561581f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960118282829054906101000a90046bffffffffffffffffffffffff16612892919061581f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128f99190615549565b6040805192835260208301919091520160405180910390a2505050505050565b60006112af826000613abf565b61292e613961565b60095461ffff8083166601000000000000909204160361297a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095461ffff640100000000909104811690821611156129c6576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff66010000000000009091048116808352908416602083015290918201906129fd9043615549565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a8d613961565b600554431015612ac9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954612adb9061ffff1660016159a6565b600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001661ffff92831617908190556201000090041615612b4157600980547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff1690555b60005b60035460ff82161015612c9657600060036000018260ff1681548110612b6c57612b6c615772565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929160ff8616908110612bbb57612bbb615772565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9283169081179091556009548451888152928716938301939093529281018390526001606082015261ffff80831660808301526201000090920490911660a08201529091507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e99060c00160405180910390a150505080612c8f906157a1565b9050612b44565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612cf957602002820191906000526020600020905b815481526020019060010190808311612ce5575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612d6257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d37575b50505050509050925092509250909192565b6060612d8184848461448e565b949350505050565b612d916135f6565b612d9a826135fe565b612da26136c4565b612dab8261455b565b15610847576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612dea613280565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612e59573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e7d91906154f1565b6009549091507101000000000000000000000000000000000090046bffffffffffffffffffffffff1681811115612eea576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610d09565b81811015611b78576000612efe828461593d565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612f79573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f9d91906158c7565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b60006112af8261455b565b613007613961565b600060066000838152602001908152602001600020604051806060016040529081600082015481526020016001820180546130419061555c565b80601f016020809104026020016040519081016040528092919081815260200182805461306d9061555c565b80156130ba5780601f1061308f576101008083540402835291602001916130ba565b820191906000526020600020905b81548152906001019060200180831161309d57829003601f168201915b505050505081526020016002820154815250509050806040015143101561310d576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816131325761311f81602001516146aa565b60208082015180519101206007556131da565b61313d826000613abf565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016131799190614dc6565b600060405180830381600087803b15801561319357600080fd5b505af19250505080156131a4575060015b6131da576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6009546131f29062010000900461ffff1660016159a6565b6009805461ffff9290921662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926132639286926159c1565b60405180910390a15050565b613277613961565b612c96816147a5565b6109a8613961565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561336957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161333e575b505050918352505060039190910154602090910152805190915060005b82608001515181101561342a57600c6000846080015183815181106133ad576133ad615772565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561342381615905565b9050613386565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061345c6002830182614bb1565b6003820160009055505080600960118282829054906101000a90046bffffffffffffffffffffffff1661348f91906158a2565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561352e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061355291906158c7565b613588576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b6109a86148a0565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613675576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610851576040517f7aa88a7800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6136ef7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976000613abf565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613752903390602481016159e9565b602060405180830381865afa15801561376f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061379391906158c7565b6109a8576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610d09565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a90811061382b576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610d09565b6010805460ff831690811061384257613842615772565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611b78576010805460ff831690811061389257613892615772565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610d09565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612c96576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff1633146109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d09565b6139ef61490d565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613a6c6148a0565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a3a3390565b600081613afe5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613af85790506112af565b50613b8a565b60005b60035460ff82161015613b88576003805460ff8316908110613b2557613b25615772565b90600052602060002001548403613b78576004805460ff8316908110613b4d57613b4d615772565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1691506112af9050565b613b81816157a1565b9050613b01565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610d09565b60006bffffffffffffffffffffffff821115613c5d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610d09565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613cac90899089908990602401615a18565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613d5e57600080fd5b5a611388811015613d6e57600080fd5b611388810390508760408204820311613d8657600080fd5b60008086516020880160008b8df193505a900391503d6084811115613da9575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613dfa84613bbf565b613e0490866157ef565b9050600081613e13888661581f565b613e1d919061581f565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613e74918591166158a2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613eae919061581f565b336000908152600d602052604081208054909190613edb9084906bffffffffffffffffffffffff1661581f565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613f229185911661581f565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613f76918591166158a2565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613ffa91859169010000000000000000009004166158e4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60006140376135f6565b614040856138eb565b61404a3386614979565b61405485836137cb565b60006140608888613abf565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c59161412b91600401615a4d565b6080604051808303816000875af115801561414a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061416e9190615ae0565b92975090945092509050614183338a85614a15565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c081016141f98342615549565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161447896959493929190615b1e565b60405180910390a4505050509695505050505050565b606060008080806144a186880188615b82565b935093509350935060006144ba8960018787878761402d565b60408051602080825281830190925291925060208201818036833701905050955060005b602081101561454e578181602081106144f9576144f9615772565b1a60f81b87828151811061450f5761450f615772565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061454781615905565b90506144de565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156145d357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116145a8575b5050505050905060005b81518110156146a0576000600c60008484815181106145fe576145fe615772565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461468f57506001949350505050565b5061469981615905565b90506145dd565b5060009392505050565b6000806000838060200190518101906146c39190615bf3565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c021781558351959850939650919450909261476e9160109190860190614bcf565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612fe693929190615cdc565b3373ffffffffffffffffffffffffffffffffffffffff821603614824576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d09565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16156109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610d09565b60005460ff166109a8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610d09565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610851576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610d09565b67ffffffffffffffff82166000908152600b602052604081206001018054839290614a4f9084906bffffffffffffffffffffffff1661581f565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614ac59284929004166158e4565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614b2b579160200282015b82811115614b2b578251825591602001919060010190614b10565b50613c5d929150614c75565b828054828255906000526020600020908101928215614b2b579160200282015b82811115614b2b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614b57565b5080546000825590600052602060002090810190612c969190614c75565b82805482825590600052602060002090600701600890048101928215614b2b5791602002820160005b83821115614c3c57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614bf8565b8015614c6c5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614c3c565b5050613c5d9291505b5b80821115613c5d5760008155600101614c76565b803567ffffffffffffffff81168114614ca257600080fd5b919050565b600060208284031215614cb957600080fd5b611b8982614c8a565b803573ffffffffffffffffffffffffffffffffffffffff81168114614ca257600080fd5b60008060408385031215614cf957600080fd5b614d0283614c8a565b9150614d1060208401614cc2565b90509250929050565b63ffffffff81168114612c9657600080fd5b60008060408385031215614d3e57600080fd5b614d4783614c8a565b91506020830135614d5781614d19565b809150509250929050565b6000815180845260005b81811015614d8857602081850181015186830182015201614d6c565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611b896020830184614d62565b60008060408385031215614dec57600080fd5b614df583614c8a565b946020939093013593505050565b60008083601f840112614e1557600080fd5b50813567ffffffffffffffff811115614e2d57600080fd5b602083019150836020828501011115614e4557600080fd5b9250929050565b600080600060408486031215614e6157600080fd5b83359250602084013567ffffffffffffffff811115614e7f57600080fd5b614e8b86828701614e03565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614f0e57614f0e614e98565b604052919050565b600067ffffffffffffffff821115614f3057614f30614e98565b5060051b60200190565b600082601f830112614f4b57600080fd5b81356020614f60614f5b83614f16565b614ec7565b82815260059290921b84018101918181019086841115614f7f57600080fd5b8286015b84811015614fa157614f9481614cc2565b8352918301918301614f83565b509695505050505050565b60008060408385031215614fbf57600080fd5b823567ffffffffffffffff80821115614fd757600080fd5b818501915085601f830112614feb57600080fd5b81356020614ffb614f5b83614f16565b82815260059290921b8401810191818101908984111561501a57600080fd5b948201945b838610156150385785358252948201949082019061501f565b9650508601359250508082111561504e57600080fd5b5061505b85828601614f3a565b9150509250929050565b600082601f83011261507657600080fd5b813567ffffffffffffffff81111561509057615090614e98565b6150c160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614ec7565b8181528460208386010111156150d657600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612c9657600080fd5b60008060008060008060c0878903121561512657600080fd5b86359550602087013567ffffffffffffffff8082111561514557600080fd5b6151518a838b01615065565b9650604089013591508082111561516757600080fd5b5061517489828a01615065565b9450506060870135615185816150f3565b92506080870135615195816150f3565b91506151a360a08801614cc2565b90509295509295509295565b803561ffff81168114614ca257600080fd5b60008060008060008060a087890312156151da57600080fd5b6151e387614c8a565b9550602087013567ffffffffffffffff8111156151ff57600080fd5b61520b89828a01614e03565b909650945061521e9050604088016151af565b9250606087013561522e81614d19565b80925050608087013590509295509295509295565b6000806040838503121561525657600080fd5b61525f83614cc2565b91506020830135614d57816150f3565b6000806020838503121561528257600080fd5b823567ffffffffffffffff8082111561529a57600080fd5b818501915085601f8301126152ae57600080fd5b8135818111156152bd57600080fd5b8660208260051b85010111156152d257600080fd5b60209290920196919550909350505050565b600080604083850312156152f757600080fd5b61530083614cc2565b9150614d1060208401614c8a565b8015158114612c9657600080fd5b6000806040838503121561532f57600080fd5b823591506020830135614d578161530e565b600081518084526020808501945080840160005b8381101561538757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615355565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a06080820181905260009061128690830184615341565b600080600080606085870312156153fd57600080fd5b61540685614cc2565b935060208501359250604085013567ffffffffffffffff81111561542957600080fd5b61543587828801614e03565b95989497509550505050565b60006020828403121561545357600080fd5b5035919050565b60006020828403121561546c57600080fd5b611b89826151af565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154b65784518352938301939183019160010161549a565b505084810360408601526154ca8187615341565b98975050505050505050565b6000602082840312156154e857600080fd5b611b8982614cc2565b60006020828403121561550357600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156112af576112af61551a565b600181811c9082168061557057607f821691505b6020821081036155a9577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611b7857600081815260208120601f850160051c810160208610156155d65750805b601f850160051c820191505b818110156155f5578281556001016155e2565b505050505050565b815167ffffffffffffffff81111561561757615617614e98565b61562b81615625845461555c565b846155af565b602080601f83116001811461567e57600084156156485750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556155f5565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156156cb578886015182559484019460019091019084016156ac565b508582101561570757878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060ff821660ff81036157b7576157b761551a565b60010192915050565b6effffffffffffffffffffffffffffff8181168382160190808211156157e8576157e861551a565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146158175761581761551a565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156157e8576157e861551a565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061589060a0830185614d62565b82810360808401526154ca8185614d62565b6bffffffffffffffffffffffff8281168282160390808211156157e8576157e861551a565b6000602082840312156158d957600080fd5b8151611b898161530e565b67ffffffffffffffff8181168382160190808211156157e8576157e861551a565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036159365761593661551a565b5060010190565b818103818111156112af576112af61551a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff80831681810361599c5761599c61551a565b6001019392505050565b61ffff8181168382160190808211156157e8576157e861551a565b8381528260208201526060604082015260006159e06060830184614d62565b95945050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612d816040830184614d62565b838152606060208201526000615a316060830185614d62565b8281036040840152615a438185614d62565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e06060840152615a98610100840182614d62565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b60008060008060808587031215615af657600080fd5b845193506020850151615b08816150f3565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615b5f60c0830186614d62565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b60008060008060808587031215615b9857600080fd5b615ba185614c8a565b9350602085013567ffffffffffffffff811115615bbd57600080fd5b615bc987828801615065565b935050615bd8604086016151af565b91506060850135615be881614d19565b939692955090935050565b600080600060608486031215615c0857600080fd5b8351615c13816150f3565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615c4b57600080fd5b604086015190935067ffffffffffffffff811115615c6857600080fd5b8501601f81018713615c7957600080fd5b8051615c87614f5b82614f16565b81815260059190911b82018301908381019089831115615ca657600080fd5b928401925b82841015615ccd578351615cbe81614d19565b82529284019290840190615cab565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615d5957845163ffffffff1683529383019391830191600101615d37565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620062b9380380620062b9833981016040819052620000349162000431565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006ab9350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200024491906200052e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002bc916010919086019062000303565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051620002f5939291906200063a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003a75791602002820160005b838211156200037357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200032d565b8015620003a55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000373565b505b50620003b5929150620003b9565b5090565b5b80821115620003b55760008155600101620003ba565b805161ffff81168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004295762000429620003e8565b604052919050565b600080600080608085870312156200044857600080fd5b6200045385620003d0565b9350602062000464818701620003d0565b60408701519094506001600160a01b03811681146200048257600080fd5b60608701519093506001600160401b0380821115620004a057600080fd5b818801915088601f830112620004b557600080fd5b815181811115620004ca57620004ca620003e8565b620004de601f8201601f19168501620003fe565b91508082528984828501011115620004f557600080fd5b60005b8181101562000515578381018501518382018601528401620004f8565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200054457600080fd5b83516001600160601b03811681146200055c57600080fd5b602085810151919450906001600160e01b0319811681146200057d57600080fd5b60408601519093506001600160401b03808211156200059b57600080fd5b818701915087601f830112620005b057600080fd5b815181811115620005c557620005c5620003e8565b8060051b9150620005d8848301620003fe565b818152918301840191848101908a841115620005f357600080fd5b938501935b838510156200062a578451925063ffffffff83168314620006195760008081fd5b8282529385019390850190620005f8565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b818110156200069d57845163ffffffff168352938301939183019160010162000679565b509098975050505050505050565b608051615bf2620006c7600039600061292f0152615bf26000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c80637341c10c1161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610766578063eb523d6c14610779578063f2fde38b1461078c57600080fd5b8063c4614d611461072d578063d7ae1d3014610740578063e72f6e301461075357600080fd5b8063b5643858116100c8578063b5643858146106fb578063b734c0f41461070e578063badc3eb61461071657600080fd5b8063a9c9a918146106b7578063aab396bd146106ca578063b187bd26146106f057600080fd5b80638fde531711610150578063a21a23e41161012a578063a21a23e414610678578063a47c769614610680578063a4c0ed36146106a457600080fd5b80638fde5317146106555780639883c10d1461065d5780639f87fad71461066557600080fd5b8063823597401161018157806382359740146106175780638456cb591461062a5780638da5cb5b1461063257600080fd5b80637341c10c146105fc57806379ba50971461060f57600080fd5b8063461d27621161025557806366316d8d11610209578063674603d0116101e3578063674603d0146105285780636a6df79b146105bd57806371ec28ac146105f557600080fd5b806366316d8d146104d457806366419970146104e7578063665871ec1461051557600080fd5b806355fedefa1161023a57806355fedefa146104975780635c975abb146104aa5780635ed6dfba146104c157600080fd5b8063461d2762146104635780634b8832d31461048457600080fd5b80631ded3b36116102b75780633e871e4d116102915780633e871e4d1461040f5780633f4ba83a146104225780633fd67e051461042a57600080fd5b80631ded3b36146103d35780632a905ccc146103e6578063385de9ae146103fc57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038a57600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614b5f565b61079f565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b610317610347366004614b8c565b61082c565b6009546b01000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610330565b6103c66040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614c27565b6103176103e1366004614c3a565b610836565b600f546bffffffffffffffffffffffff1661036d565b61031761040a366004614cad565b610867565b61031761041d366004614e31565b610a45565b610317610d40565b61043d610438366004614f92565b610d52565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610330565b610476610471366004615046565b6110db565b604051908152602001610330565b6103176104923660046150c8565b61112f565b6104766104a5366004614b5f565b61122c565b60005460ff165b6040519015158152602001610330565b6103176104cf3660046150fb565b611250565b6103176104e23660046150fb565b611526565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b610317610523366004615127565b61174d565b61059561053636600461519c565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b6105d06105cb3660046151d4565b611b36565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6064610321565b61031761060a3660046150c8565b611b49565b610317611cf6565b610317610625366004614b5f565b611e18565b610317611f67565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d0565b610317611f77565b600754610476565b6103176106733660046150c8565b61201f565b6104fc612427565b61069361068e366004614b5f565b6125bb565b60405161033095949392919061524a565b6103176106b236600461529f565b6126a7565b6105d06106c53660046152f9565b6128d6565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610476565b60005460ff166104b1565b610317610709366004615312565b6128e3565b610317612a44565b61071e612bb2565b6040516103309392919061532d565b6103c661073b366004614cad565b612c8d565b61031761074e3660046150c8565b612ca2565b61031761076136600461538e565b612cfb565b6104b1610774366004614b5f565b612f07565b6103176107873660046152f9565b612f12565b61031761079a36600461538e565b613130565b6107a7613141565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061081e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108288282613149565b5050565b61082882826134b7565b61083e613141565b610847826135d7565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61086f61364d565b600061087c8460006136d3565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036108a6575060075461091a565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156108f3573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061091791906153a9565b90505b838360405161092a9291906153c2565b6040518091039020810361096a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050908252506009546020909101906109cb9061ffff1643615401565b90526000868152600660209081526040909120825181559082015160018201906109f590826154b5565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610a369087908490889088906155cf565b60405180910390a15050505050565b610a4d61364d565b8151815181141580610a5f5750600881115b15610a96576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610bc7576000848281518110610ab557610ab561562a565b602002602001015190506000848381518110610ad357610ad361562a565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610b3e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610b75576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610bb4576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610bc090615659565b9050610a99565b50600954600090610bdc9061ffff1643615401565b604080516060810182528681526020808201879052918101839052865192935091600391610c0e9183918901906149a8565b506020828101518051610c2792600185019201906149ef565b506040820151816002015590505060005b8451811015610d39577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610c7457610c7461562a565b602002602001015160026000888581518110610c9257610c9261562a565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610cdb57610cdb61562a565b602002602001015185604051610d21949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610d3281615659565b9050610c38565b5050505050565b610d4861364d565b610d506137ca565b565b600080610d5d613847565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314610e9f576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff16610ec85760029250506110d0565b8060e00151816080015163ffffffff16610ee29190615691565b6effffffffffffffffffffffffffffff165a1015610f045760039250506110d0565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff90911690610f479063ffffffff1661384f565b610f5190886156c0565b8251610f5e9088906156f0565b610f6891906156f0565b6bffffffffffffffffffffffff161115610f865760049250506110d0565b8060a001516bffffffffffffffffffffffff16610fac826080015163ffffffff1661384f565b610fb690886156c0565b8251610fc39088906156f0565b610fcd91906156f0565b6bffffffffffffffffffffffff161115610feb5760059250506110d0565b6000898152600e6020526040808220828155600181018390556002018290556080830151908301519194508491611027918c918c918c916138f1565b805190915061103757600161103a565b60005b9350600061106183606001518460a00151856040015186600001518c87602001518d613a6b565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a8360200151898987600001516110aa578e6110ac565b8f5b88604001516040516110c2959493929190615715565b60405180910390a351925050505b965096945050505050565b60006111248260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613cbd9050565b979650505050505050565b611137613847565b6111408261411e565b6111486141e4565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108285767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b611258613141565b806bffffffffffffffffffffffff1660000361128e5750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff808316911610156112e8576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906113159084906bffffffffffffffffffffffff16615773565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff1661136c9190615773565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561140b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061142f9190615798565b61082857600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa1580156114a2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114c691906153a9565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610bab565b61152e613847565b806bffffffffffffffffffffffff16600003611576576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff808316911610156115d0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906115fd9084906bffffffffffffffffffffffff16615773565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166116549190615773565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156116f3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117179190615798565b610828576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611755613847565b60005b81811015611b315760008383838181106117745761177461562a565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e0820152909350919050611897816135d7565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16338114611910576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611955576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af11580156119c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119eb9190615798565b5060a084015167ffffffffffffffff84166000908152600b602052604081206001018054909190611a2b9084906bffffffffffffffffffffffff16615773565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff808816845291529190208054600192600991611ab291859169010000000000000000009004166157b5565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040808220828155600181018390556002018290555186917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050505080611b2a90615659565b9050611758565b505050565b6000611b4283836136d3565b9392505050565b611b51613847565b611b5a8261411e565b611b626141e4565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611bd7576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611c1e575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611220565b60015473ffffffffffffffffffffffffffffffffffffffff163314611d77576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610bab565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611e20613847565b611e286141e4565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611ec8576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610bab565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611f6f61364d565b610d506142eb565b611f7f61364d565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611fe1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b612027613847565b6120308261411e565b6120386141e4565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152612108576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610bab565b806040015167ffffffffffffffff16816020015167ffffffffffffffff161461215d576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b60209081526040808320600201805482518185028101850190935280835291929091908301828280156121d857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116121ad575b505050505090506000600182516121ef91906157d6565b905060005b825181101561238b578473ffffffffffffffffffffffffffffffffffffffff168382815181106122265761222661562a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff160361237b57600083838151811061225d5761225d61562a565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106122a3576122a361562a565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061231d5761231d6157e9565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061238b565b61238481615659565b90506121f4565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000612431613847565b6124396141e4565b6009805460039061245a906301000000900467ffffffffffffffff16615818565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156124d0578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261256b926002850192909101906149ef565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b60008060008060606125cc866135d7565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561269757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161266c575b5050505050905091939590929450565b6126af613847565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612700576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461273a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061274882840184614b5f565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166127c1576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906127f883856156f0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff1661284f91906156f0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128b69190615401565b6040805192835260208301919091520160405180910390a2505050505050565b600061124a8260006136d3565b6128eb61364d565b60095461ffff80831691160361292d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff16111561298f576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff908116808352908416602083015290918201906129bc9043615401565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a4c61364d565b600554431015612a88576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612baf57600060036000018281548110612aad57612aad61562a565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612af957612af961562a565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612ba890615659565b9050612a8b565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612c1257602002820191906000526020600020905b815481526020019060010190808311612bfe575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612c7b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612c50575b50505050509050925092509250909192565b6060612c9a848484614346565b949350505050565b612caa613847565b612cb38261411e565b612cbb6141e4565b612cc482614413565b1561081e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d03613141565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612d72573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d9691906153a9565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612dfd576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610bab565b81811015611b31576000612e1182846157d6565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612e8c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612eb09190615798565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b600061124a82614413565b612f1a61364d565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612f5490615414565b80601f0160208091040260200160405190810160405280929190818152602001828054612f8090615414565b8015612fcd5780601f10612fa257610100808354040283529160200191612fcd565b820191906000526020600020905b815481529060010190602001808311612fb057829003601f168201915b5050505050815260200160028201548152505090508060400151431015613020576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613045576130328160200151614562565b60208082015180519101206007556130ed565b6130508260006136d3565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b815260040161308c9190614c27565b600060405180830381600087803b1580156130a657600080fd5b505af19250505080156130b7575060015b6130ed576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261312492869261583f565b60405180910390a15050565b61313861364d565b612baf8161465d565b610d5061364d565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561322a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116131ff575b505050918352505060039190910154602090910152805190915060005b8260800151518110156132eb57600c60008460800151838151811061326e5761326e61562a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556132e481615659565b9050613247565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061331d6002830182614a69565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff166133509190615773565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156133ef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134139190615798565b613449576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110613517576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610bab565b6010805460ff831690811061352e5761352e61562a565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611b31576010805460ff831690811061357e5761357e61562a565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610bab565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612baf576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610d50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bab565b6000816137125760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16801561370c57905061124a565b50613795565b60005b6003548110156137935760038054829081106137335761373361562a565b906000526020600020015484036137835760048054829081106137585761375861562a565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16915061124a9050565b61378c81615659565b9050613715565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610bab565b6137d2614758565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b610d506147c4565b60006bffffffffffffffffffffffff8211156138ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610bab565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b9061393c90899089908990602401615867565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b6139ee57600080fd5b5a6113888110156139fe57600080fd5b611388810390508760408204820311613a1657600080fd5b60008086516020880160008b8df193505a900391503d6084811115613a39575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613a8a8461384f565b613a9490866156c0565b9050600081613aa388866156f0565b613aad91906156f0565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613b0491859116615773565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613b3e91906156f0565b336000908152600d602052604081208054909190613b6b9084906bffffffffffffffffffffffff166156f0565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613bb2918591166156f0565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613c0691859116615773565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613c8a91859169010000000000000000009004166157b5565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613cc7613847565b613cd0856135d7565b613cda3386614831565b613ce485836134b7565b6000613cf088886136d3565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c591613dbb9160040161589c565b6080604051808303816000875af1158015613dda573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613dfe919061592f565b92975090945092509050613e13338a856148cd565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c08101613e898342615401565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516141089695949392919061596d565b60405180910390a4505050509695505050505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680614195576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610828576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61420f7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006136d3565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890614272903390602481016159d1565b602060405180830381865afa15801561428f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142b39190615798565b610d50576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610bab565b6142f36147c4565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861381d3390565b6060600080808061435986880188615a00565b9350935093509350600061437289600187878787613cbd565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614406578181602081106143b1576143b161562a565b1a60f81b8782815181106143c7576143c761562a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506143ff81615659565b9050614396565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561448b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614460575b5050505050905060005b8151811015614558576000600c60008484815181106144b6576144b661562a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461454757506001949350505050565b5061455181615659565b9050614495565b5060009392505050565b60008060008380602001905181019061457b9190615a71565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926146269160109190860190614a87565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612ef993929190615b5a565b3373ffffffffffffffffffffffffffffffffffffffff8216036146dc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bab565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610d50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610bab565b60005460ff1615610d50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610bab565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610828576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610bab565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906149079084906bffffffffffffffffffffffff166156f0565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261497d9284929004166157b5565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b8280548282559060005260206000209081019282156149e3579160200282015b828111156149e35782518255916020019190600101906149c8565b506138ed929150614b2d565b8280548282559060005260206000209081019282156149e3579160200282015b828111156149e357825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614a0f565b5080546000825590600052602060002090810190612baf9190614b2d565b828054828255906000526020600020906007016008900481019282156149e35791602002820160005b83821115614af457835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614ab0565b8015614b245782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614af4565b50506138ed9291505b5b808211156138ed5760008155600101614b2e565b803567ffffffffffffffff81168114614b5a57600080fd5b919050565b600060208284031215614b7157600080fd5b611b4282614b42565b63ffffffff81168114612baf57600080fd5b60008060408385031215614b9f57600080fd5b614ba883614b42565b91506020830135614bb881614b7a565b809150509250929050565b6000815180845260005b81811015614be957602081850181015186830182015201614bcd565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611b426020830184614bc3565b60008060408385031215614c4d57600080fd5b614c5683614b42565b946020939093013593505050565b60008083601f840112614c7657600080fd5b50813567ffffffffffffffff811115614c8e57600080fd5b602083019150836020828501011115614ca657600080fd5b9250929050565b600080600060408486031215614cc257600080fd5b83359250602084013567ffffffffffffffff811115614ce057600080fd5b614cec86828701614c64565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d6f57614d6f614cf9565b604052919050565b600067ffffffffffffffff821115614d9157614d91614cf9565b5060051b60200190565b803573ffffffffffffffffffffffffffffffffffffffff81168114614b5a57600080fd5b600082601f830112614dd057600080fd5b81356020614de5614de083614d77565b614d28565b82815260059290921b84018101918181019086841115614e0457600080fd5b8286015b84811015614e2657614e1981614d9b565b8352918301918301614e08565b509695505050505050565b60008060408385031215614e4457600080fd5b823567ffffffffffffffff80821115614e5c57600080fd5b818501915085601f830112614e7057600080fd5b81356020614e80614de083614d77565b82815260059290921b84018101918181019089841115614e9f57600080fd5b948201945b83861015614ebd57853582529482019490820190614ea4565b96505086013592505080821115614ed357600080fd5b50614ee085828601614dbf565b9150509250929050565b600082601f830112614efb57600080fd5b813567ffffffffffffffff811115614f1557614f15614cf9565b614f4660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614d28565b818152846020838601011115614f5b57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612baf57600080fd5b60008060008060008060c08789031215614fab57600080fd5b86359550602087013567ffffffffffffffff80821115614fca57600080fd5b614fd68a838b01614eea565b96506040890135915080821115614fec57600080fd5b50614ff989828a01614eea565b945050606087013561500a81614f78565b9250608087013561501a81614f78565b915061502860a08801614d9b565b90509295509295509295565b803561ffff81168114614b5a57600080fd5b60008060008060008060a0878903121561505f57600080fd5b61506887614b42565b9550602087013567ffffffffffffffff81111561508457600080fd5b61509089828a01614c64565b90965094506150a3905060408801615034565b925060608701356150b381614b7a565b80925050608087013590509295509295509295565b600080604083850312156150db57600080fd5b6150e483614b42565b91506150f260208401614d9b565b90509250929050565b6000806040838503121561510e57600080fd5b61511783614d9b565b91506020830135614bb881614f78565b6000806020838503121561513a57600080fd5b823567ffffffffffffffff8082111561515257600080fd5b818501915085601f83011261516657600080fd5b81358181111561517557600080fd5b8660208260051b850101111561518a57600080fd5b60209290920196919550909350505050565b600080604083850312156151af57600080fd5b6151b883614d9b565b91506150f260208401614b42565b8015158114612baf57600080fd5b600080604083850312156151e757600080fd5b823591506020830135614bb8816151c6565b600081518084526020808501945080840160005b8381101561523f57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161520d565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090611124908301846151f9565b600080600080606085870312156152b557600080fd5b6152be85614d9b565b935060208501359250604085013567ffffffffffffffff8111156152e157600080fd5b6152ed87828801614c64565b95989497509550505050565b60006020828403121561530b57600080fd5b5035919050565b60006020828403121561532457600080fd5b611b4282615034565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561536e57845183529383019391830191600101615352565b5050848103604086015261538281876151f9565b98975050505050505050565b6000602082840312156153a057600080fd5b611b4282614d9b565b6000602082840312156153bb57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561124a5761124a6153d2565b600181811c9082168061542857607f821691505b602082108103615461577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611b3157600081815260208120601f850160051c8101602086101561548e5750805b601f850160051c820191505b818110156154ad5782815560010161549a565b505050505050565b815167ffffffffffffffff8111156154cf576154cf614cf9565b6154e3816154dd8454615414565b84615467565b602080601f83116001811461553657600084156155005750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556154ad565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561558357888601518255948401946001909101908401615564565b50858210156155bf57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361568a5761568a6153d2565b5060010190565b6effffffffffffffffffffffffffffff8181168382160190808211156156b9576156b96153d2565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146156e8576156e86153d2565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156156b9576156b96153d2565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061576160a0830185614bc3565b82810360808401526153828185614bc3565b6bffffffffffffffffffffffff8281168282160390808211156156b9576156b96153d2565b6000602082840312156157aa57600080fd5b8151611b42816151c6565b67ffffffffffffffff8181168382160190808211156156b9576156b96153d2565b8181038181111561124a5761124a6153d2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff808316818103615835576158356153d2565b6001019392505050565b83815282602082015260606040820152600061585e6060830184614bc3565b95945050505050565b8381526060602082015260006158806060830185614bc3565b82810360408401526158928185614bc3565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e060608401526158e7610100840182614bc3565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b6000806000806080858703121561594557600080fd5b84519350602085015161595781614f78565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c060608301526159ae60c0830186614bc3565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612c9a6040830184614bc3565b60008060008060808587031215615a1657600080fd5b615a1f85614b42565b9350602085013567ffffffffffffffff811115615a3b57600080fd5b615a4787828801614eea565b935050615a5660408601615034565b91506060850135615a6681614b7a565b939692955090935050565b600080600060608486031215615a8657600080fd5b8351615a9181614f78565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615ac957600080fd5b604086015190935067ffffffffffffffff811115615ae657600080fd5b8501601f81018713615af757600080fd5b8051615b05614de082614d77565b81815260059190911b82018301908381019089831115615b2457600080fd5b928401925b82841015615b4b578351615b3c81614b7a565b82529284019290840190615b29565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615bd757845163ffffffff1683529383019391830191600101615bb5565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -609,30 +609,6 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) TypeAndVersion() (string, return _FunctionsRouter.Contract.TypeAndVersion(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) Version(opts *bind.CallOpts) (uint16, uint16, uint16, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "version") - - if err != nil { - return *new(uint16), *new(uint16), *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - out1 := *abi.ConvertType(out[1], new(uint16)).(*uint16) - out2 := *abi.ConvertType(out[2], new(uint16)).(*uint16) - - return out0, out1, out2, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) Version() (uint16, uint16, uint16, error) { - return _FunctionsRouter.Contract.Version(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) Version() (uint16, uint16, uint16, error) { - return _FunctionsRouter.Contract.Version(&_FunctionsRouter.CallOpts) -} - func (_FunctionsRouter *FunctionsRouterTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "acceptOwnership") } @@ -753,6 +729,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) OwnerWithdraw(recipien return _FunctionsRouter.Contract.OwnerWithdraw(&_FunctionsRouter.TransactOpts, recipient, amount) } +func (_FunctionsRouter *FunctionsRouterTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "pause") +} + +func (_FunctionsRouter *FunctionsRouterSession) Pause() (*types.Transaction, error) { + return _FunctionsRouter.Contract.Pause(&_FunctionsRouter.TransactOpts) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) Pause() (*types.Transaction, error) { + return _FunctionsRouter.Contract.Pause(&_FunctionsRouter.TransactOpts) +} + func (_FunctionsRouter *FunctionsRouterTransactor) ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "proposeConfigUpdate", id, config) } @@ -777,6 +765,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeContractsUpdate return _FunctionsRouter.Contract.ProposeContractsUpdate(&_FunctionsRouter.TransactOpts, proposedContractSetIds, proposedContractSetAddresses) } +func (_FunctionsRouter *FunctionsRouterTransactor) ProposeSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "proposeSubscriptionOwnerTransfer", subscriptionId, newOwner) +} + +func (_FunctionsRouter *FunctionsRouterSession) ProposeSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { + return _FunctionsRouter.Contract.ProposeSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { + return _FunctionsRouter.Contract.ProposeSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) +} + func (_FunctionsRouter *FunctionsRouterTransactor) ProposeTimelockBlocks(opts *bind.TransactOpts, blocks uint16) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "proposeTimelockBlocks", blocks) } @@ -813,18 +813,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) RemoveConsumer(subscri return _FunctionsRouter.Contract.RemoveConsumer(&_FunctionsRouter.TransactOpts, subscriptionId, consumer) } -func (_FunctionsRouter *FunctionsRouterTransactor) RequestSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "requestSubscriptionOwnerTransfer", subscriptionId, newOwner) -} - -func (_FunctionsRouter *FunctionsRouterSession) RequestSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RequestSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) RequestSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RequestSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) -} - func (_FunctionsRouter *FunctionsRouterTransactor) SendRequest(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "sendRequest", subscriptionId, data, dataVersion, callbackGasLimit, donId) } @@ -861,18 +849,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) TimeoutRequests(reques return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestIdsToTimeout) } -func (_FunctionsRouter *FunctionsRouterTransactor) TogglePaused(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "togglePaused") -} - -func (_FunctionsRouter *FunctionsRouterSession) TogglePaused() (*types.Transaction, error) { - return _FunctionsRouter.Contract.TogglePaused(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) TogglePaused() (*types.Transaction, error) { - return _FunctionsRouter.Contract.TogglePaused(&_FunctionsRouter.TransactOpts) -} - func (_FunctionsRouter *FunctionsRouterTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "transferOwnership", to) } @@ -885,6 +861,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) TransferOwnership(to c return _FunctionsRouter.Contract.TransferOwnership(&_FunctionsRouter.TransactOpts, to) } +func (_FunctionsRouter *FunctionsRouterTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "unpause") +} + +func (_FunctionsRouter *FunctionsRouterSession) Unpause() (*types.Transaction, error) { + return _FunctionsRouter.Contract.Unpause(&_FunctionsRouter.TransactOpts) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) Unpause() (*types.Transaction, error) { + return _FunctionsRouter.Contract.Unpause(&_FunctionsRouter.TransactOpts) +} + func (_FunctionsRouter *FunctionsRouterTransactor) UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "updateConfig", id) } @@ -1474,9 +1462,6 @@ type FunctionsRouterContractUpdated struct { ProposedContractSetId [32]byte ProposedContractSetFromAddress common.Address ProposedContractSetToAddress common.Address - Major uint16 - Minor uint16 - Patch uint16 Raw types.Log } @@ -2331,6 +2316,133 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestStart(log types.Log return event, nil } +type FunctionsRouterRequestTimedOutIterator struct { + Event *FunctionsRouterRequestTimedOut + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsRouterRequestTimedOutIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsRouterRequestTimedOut) + 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(FunctionsRouterRequestTimedOut) + 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 *FunctionsRouterRequestTimedOutIterator) Error() error { + return it.fail +} + +func (it *FunctionsRouterRequestTimedOutIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsRouterRequestTimedOut struct { + RequestId [32]byte + Raw types.Log +} + +func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRouterRequestTimedOutIterator, error) { + + var requestIdRule []interface{} + for _, requestIdItem := range requestId { + requestIdRule = append(requestIdRule, requestIdItem) + } + + logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "RequestTimedOut", requestIdRule) + if err != nil { + return nil, err + } + return &FunctionsRouterRequestTimedOutIterator{contract: _FunctionsRouter.contract, event: "RequestTimedOut", logs: logs, sub: sub}, nil +} + +func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestTimedOut, requestId [][32]byte) (event.Subscription, error) { + + var requestIdRule []interface{} + for _, requestIdItem := range requestId { + requestIdRule = append(requestIdRule, requestIdItem) + } + + logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "RequestTimedOut", requestIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsRouterRequestTimedOut) + if err := _FunctionsRouter.contract.UnpackLog(event, "RequestTimedOut", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestTimedOut(log types.Log) (*FunctionsRouterRequestTimedOut, error) { + event := new(FunctionsRouterRequestTimedOut) + if err := _FunctionsRouter.contract.UnpackLog(event, "RequestTimedOut", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type FunctionsRouterSubscriptionCanceledIterator struct { Event *FunctionsRouterSubscriptionCanceled @@ -3621,6 +3733,8 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig return _FunctionsRouter.ParseRequestEnd(log) case _FunctionsRouter.abi.Events["RequestStart"].ID: return _FunctionsRouter.ParseRequestStart(log) + case _FunctionsRouter.abi.Events["RequestTimedOut"].ID: + return _FunctionsRouter.ParseRequestTimedOut(log) case _FunctionsRouter.abi.Events["SubscriptionCanceled"].ID: return _FunctionsRouter.ParseSubscriptionCanceled(log) case _FunctionsRouter.abi.Events["SubscriptionConsumerAdded"].ID: @@ -3664,7 +3778,7 @@ func (FunctionsRouterContractProposed) Topic() common.Hash { } func (FunctionsRouterContractUpdated) Topic() common.Hash { - return common.HexToHash("0xf17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e9") + return common.HexToHash("0xf8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf94") } func (FunctionsRouterFundsRecovered) Topic() common.Hash { @@ -3691,6 +3805,10 @@ func (FunctionsRouterRequestStart) Topic() common.Hash { return common.HexToHash("0x7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54") } +func (FunctionsRouterRequestTimedOut) Topic() common.Hash { + return common.HexToHash("0xf1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af414") +} + func (FunctionsRouterSubscriptionCanceled) Topic() common.Hash { return common.HexToHash("0xe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815") } @@ -3778,8 +3896,6 @@ type FunctionsRouterInterface interface { TypeAndVersion(opts *bind.CallOpts) (string, error) - Version(opts *bind.CallOpts) (uint16, uint16, uint16, error) - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) AcceptSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) @@ -3800,28 +3916,30 @@ type FunctionsRouterInterface interface { OwnerWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) + Pause(opts *bind.TransactOpts) (*types.Transaction, error) + ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetAddresses []common.Address) (*types.Transaction, error) + ProposeSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) + ProposeTimelockBlocks(opts *bind.TransactOpts, blocks uint16) (*types.Transaction, error) RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) RemoveConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) - RequestSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) - SendRequest(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) - TogglePaused(opts *bind.TransactOpts) (*types.Transaction, error) - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + Unpause(opts *bind.TransactOpts) (*types.Transaction, error) + UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) @@ -3896,6 +4014,12 @@ type FunctionsRouterInterface interface { ParseRequestStart(log types.Log) (*FunctionsRouterRequestStart, error) + FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRouterRequestTimedOutIterator, error) + + WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestTimedOut, requestId [][32]byte) (event.Subscription, error) + + ParseRequestTimedOut(log types.Log) (*FunctionsRouterRequestTimedOut, error) + FilterSubscriptionCanceled(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionCanceledIterator, error) WatchSubscriptionCanceled(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionCanceled, subscriptionId []uint64) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 66d9e0afb70..d77ac34caab 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,10 +1,10 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin b549b681bdc14eb3dd40422acf253c07cf58d62088539ecfe42ddb01d48d508a +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 666319c8b9b06d75db166d87a7338a79e9abe9eff71b73ea905f16f9e7cc95cf functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b5f070d0f0cd78553aa97b0dda9721074e72589818765baeef71622d21a9c6a5 -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 2a8755a8915af6b28efb73e51cc36c8050877800995bd376975b61441c791c45 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin bc0d4aa6e244f7d2dbd29b2abadcef8c7db0bc7223475e7485273a1709412d7c +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 00604c0ef992a6cdbe836a49628403f444a434e3e2a9ae3359ac59ca677f5afe ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 33849ebeab1..0d69bc8c095 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -120,9 +120,13 @@ func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToke require.NoError(t, err) privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) require.NoError(t, err) - proof, err := crypto.Sign(ethMessageHash[:], privateKey) - require.NoError(t, err) - allowListContract.AcceptTermsOfService(owner, owner.From, owner.From, proof) + flatSignature, err := crypto.Sign(ethMessageHash[:], privateKey) + var r [32]byte + copy(r[:], flatSignature[:32]) + var s [32]byte + copy(s[:], flatSignature[32:64]) + v := uint8(flatSignature[65]) + allowListContract.AcceptTermsOfService(owner, owner.From, owner.From, r, s, v) } _, err = routerContract.CreateSubscription(owner) From b789fa0a36f18de3a91a4ae99be707314cc48ec1 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Tue, 1 Aug 2023 17:14:06 -0400 Subject: [PATCH 054/270] [TT-448] Enable Tests to Save State (#9820) * Enable Tests to Save State * Setup better organization * Simple refactor and cleanup * Begin reloaded connections * A little cleanup * Include volume * Basic logic * Update versions * Caught some edge cases * Add in kill timer * Reporting * Include shutdown * Include exit * Better debug * Fix reading file * Fix bad contract type cast * Logging * Fix logs and backoff limit * Track test interruptions * Randomize the failures * Random seconds * More backoffs * Non-nil test reporter * Fix block number * Use namespace in remote envs * Update chaos * Update versions * Replace client go * Pin k8s versions * Save interruption * Better reporting * More realistic test death * Remove debug * Fix timing on restart * Check out our smoke * Use updated versions * Fix imports * Reduce duplication --- integration-tests/.tool-versions | 2 +- integration-tests/actions/actions.go | 11 +- integration-tests/actions/ocr_helpers.go | 24 +- integration-tests/client/chainlink_k8s.go | 26 + .../contracts/contract_deployer.go | 19 + integration-tests/go.mod | 21 +- integration-tests/go.sum | 25 +- integration-tests/networks/known_networks.go | 1 + integration-tests/soak/forwarder_ocr_test.go | 101 +-- integration-tests/soak/ocr_test.go | 119 +--- integration-tests/testreporters/ocr.go | 70 +- .../testsetups/keeper_benchmark.go | 6 +- integration-tests/testsetups/ocr.go | 619 +++++++++++++----- integration-tests/testsetups/vrfv2.go | 6 +- 14 files changed, 623 insertions(+), 427 deletions(-) diff --git a/integration-tests/.tool-versions b/integration-tests/.tool-versions index 8a715d61a2b..cc7693190ea 100644 --- a/integration-tests/.tool-versions +++ b/integration-tests/.tool-versions @@ -1,4 +1,4 @@ -golang 1.20.5 +golang 1.20.6 k3d 5.4.6 kubectl 1.25.5 nodejs 18.13.0 diff --git a/integration-tests/actions/actions.go b/integration-tests/actions/actions.go index 759bd552c37..aa454aca257 100644 --- a/integration-tests/actions/actions.go +++ b/integration-tests/actions/actions.go @@ -284,14 +284,14 @@ func TeardownSuite( // soak tests func TeardownRemoteSuite( t *testing.T, - env *environment.Environment, + namespace string, chainlinkNodes []*client.ChainlinkK8sClient, optionalTestReporter testreporters.TestReporter, // Optionally pass in a test reporter to log further metrics client blockchain.EVMClient, ) error { l := utils.GetTestLogger(t) var err error - if err = testreporters.SendReport(t, env, "./", optionalTestReporter); err != nil { + if err = testreporters.SendReport(t, namespace, "./", optionalTestReporter); err != nil { l.Warn().Err(err).Msg("Error writing test report") } // Delete all jobs to stop depleting the funds @@ -301,7 +301,7 @@ func TeardownRemoteSuite( } if err = returnFunds(chainlinkNodes, client); err != nil { - l.Error().Err(err).Str("Namespace", env.Cfg.Namespace). + l.Error().Err(err).Str("Namespace", namespace). Msg("Error attempting to return funds from chainlink nodes to network's default wallet. " + "Environment is left running so you can try manually!") } @@ -310,6 +310,9 @@ func TeardownRemoteSuite( func DeleteAllJobs(chainlinkNodes []*client.ChainlinkK8sClient) error { for _, node := range chainlinkNodes { + if node == nil { + return fmt.Errorf("found a nil chainlink node in the list of chainlink nodes while tearing down: %v", chainlinkNodes) + } jobs, _, err := node.ReadJobs() if err != nil { return errors.Wrap(err, "error reading jobs from chainlink node") @@ -331,7 +334,7 @@ func DeleteAllJobs(chainlinkNodes []*client.ChainlinkK8sClient) error { // Returns all the funds from the chainlink nodes to the networks default address func returnFunds(chainlinkNodes []*client.ChainlinkK8sClient, blockchainClient blockchain.EVMClient) error { if blockchainClient == nil { - log.Warn().Msg("No blockchain client found, unable to return funds from chainlink nodes.") + return errors.New("blockchain client is nil, unable to return funds from chainlink nodes") } log.Info().Msg("Attempting to return Chainlink node funds to default network wallets") if blockchainClient.NetworkSimulated() { diff --git a/integration-tests/actions/ocr_helpers.go b/integration-tests/actions/ocr_helpers.go index 9531123c970..bff96c73042 100644 --- a/integration-tests/actions/ocr_helpers.go +++ b/integration-tests/actions/ocr_helpers.go @@ -379,20 +379,28 @@ func SetAllAdapterResponsesToTheSameValue( // SetAllAdapterResponsesToDifferentValues sets the mock responses in mockserver that are read by chainlink nodes // to simulate different adapters. This sets all adapter responses for each node and contract to different responses func SetAllAdapterResponsesToDifferentValues( - t *testing.T, responses []int, ocrInstances []contracts.OffchainAggregator, chainlinkNodes []*client.ChainlinkK8sClient, mockserver *ctfClient.MockserverClient, -) { - require.Equal(t, len(chainlinkNodes)-1, len(responses), - "Amount of answers %d should be equal to the amount of Chainlink nodes - 1 for the bootstrap %d", len(responses), len(chainlinkNodes)-1) - for _, ocrInstance := range ocrInstances { - for nodeIndex := 1; nodeIndex < len(chainlinkNodes); nodeIndex++ { - err := SetAdapterResponse(responses[nodeIndex-1], ocrInstance, chainlinkNodes[nodeIndex], mockserver) - require.NoError(t, err) +) error { + if len(responses) != len(ocrInstances)*len(chainlinkNodes) { + return fmt.Errorf( + "amount of responses %d should be equal to the amount of OCR instances %d times the amount of Chainlink nodes %d", + len(responses), len(ocrInstances), len(chainlinkNodes), + ) + } + eg := &errgroup.Group{} + for _, o := range ocrInstances { + ocrInstance := o + for ni := 1; ni < len(chainlinkNodes); ni++ { + nodeIndex := ni + eg.Go(func() error { + return SetAdapterResponse(responses[nodeIndex-1], ocrInstance, chainlinkNodes[nodeIndex], mockserver) + }) } } + return eg.Wait() } // BuildNodeContractPairID builds a UUID based on a related pair of a Chainlink node and OCR contract diff --git a/integration-tests/client/chainlink_k8s.go b/integration-tests/client/chainlink_k8s.go index 08364041a8b..5586f320f27 100644 --- a/integration-tests/client/chainlink_k8s.go +++ b/integration-tests/client/chainlink_k8s.go @@ -123,3 +123,29 @@ func ReconnectChainlinkNodes(testEnvironment *environment.Environment, nodes []* } return nil } + +// ConnectChainlinkNodeURLs creates new Chainlink clients based on just URLs, should only be used inside K8s tests +func ConnectChainlinkNodeURLs(urls []string) ([]*ChainlinkK8sClient, error) { + var clients []*ChainlinkK8sClient + for _, url := range urls { + c, err := ConnectChainlinkNodeURL(url) + if err != nil { + return nil, err + } + clients = append(clients, c) + } + return clients, nil +} + +// ConnectChainlinkNodeURL creates a new Chainlink client based on just a URL, should only be used inside K8s tests +func ConnectChainlinkNodeURL(url string) (*ChainlinkK8sClient, error) { + return NewChainlinkK8sClient(&ChainlinkConfig{ + URL: url, + Email: "notreal@fakeemail.ch", + Password: "fj293fbBnlQ!f9vNs", + InternalIP: parseHostname(url), + }, + parseHostname(url), // a decent guess + "connectedNodeByURL", // an intentionally bad decision + ) +} diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 2de959db6de..4089174e012 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -52,6 +52,7 @@ type ContractDeployer interface { DeployLinkTokenContract() (LinkToken, error) LoadLinkToken(address common.Address) (LinkToken, error) DeployOffChainAggregator(linkAddr string, offchainOptions OffchainOptions) (OffchainAggregator, error) + LoadOffChainAggregator(address *common.Address) (OffchainAggregator, error) DeployVRFContract() (VRF, error) DeployMockETHLINKFeed(answer *big.Int) (MockETHLINKFeed, error) LoadETHLINKFeed(address common.Address) (MockETHLINKFeed, error) @@ -403,6 +404,24 @@ func (e *EthereumContractDeployer) DeployOffChainAggregator( }, err } +// LoadOffChainAggregator loads an already deployed offchain aggregator contract +func (e *EthereumContractDeployer) LoadOffChainAggregator(address *common.Address) (OffchainAggregator, error) { + instance, err := e.client.LoadContract("OffChainAggregator", *address, func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return offchainaggregator.NewOffchainAggregator(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumOffchainAggregator{ + address: address, + client: e.client, + ocr: instance.(*offchainaggregator.OffchainAggregator), + }, err +} + // DeployAPIConsumer deploys api consumer for oracle func (e *EthereumContractDeployer) DeployAPIConsumer(linkAddr string) (APIConsumer, error) { addr, _, instance, err := e.client.DeployContract("TestAPIConsumer", func( diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 13a1d444240..95edc41bb7e 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -14,11 +14,12 @@ require ( github.com/lib/pq v1.10.9 github.com/manifoldco/promptui v0.9.0 github.com/onsi/gomega v1.27.8 + github.com/pelletier/go-toml/v2 v2.0.9 github.com/pkg/errors v0.9.1 github.com/rs/zerolog v1.29.1 github.com/slack-go/slack v0.12.2 - github.com/smartcontractkit/chainlink-env v0.35.2 - github.com/smartcontractkit/chainlink-testing-framework v1.14.1-0.20230731095810-a70b0af9a909 + github.com/smartcontractkit/chainlink-env v0.36.0 + github.com/smartcontractkit/chainlink-testing-framework v1.15.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac github.com/smartcontractkit/ocr2keepers v0.7.2 @@ -34,6 +35,13 @@ require ( gopkg.in/guregu/null.v4 v4.0.0 ) +// Pin K8s versions as their updates are highly disruptive and go mod keeps wanting to update them +replace ( + k8s.io/api => k8s.io/api v0.25.11 + k8s.io/client-go => k8s.io/client-go v0.25.11 + k8s.io/kube-openapi => k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d +) + require ( contrib.go.opencensus.io/exporter/stackdriver v0.13.5 // indirect cosmossdk.io/errors v1.0.0 // indirect @@ -325,7 +333,6 @@ require ( github.com/opentracing-contrib/go-stdlib v1.0.0 // indirect github.com/opentracing/opentracing-go v1.2.0 // indirect github.com/pelletier/go-toml v1.9.5 // indirect - github.com/pelletier/go-toml/v2 v2.0.8 // indirect github.com/peterbourgon/diskv v2.0.1+incompatible // indirect github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect @@ -443,8 +450,8 @@ require ( k8s.io/cli-runtime v0.25.11 // indirect k8s.io/client-go v0.26.2 // indirect k8s.io/component-base v0.25.11 // indirect - k8s.io/klog/v2 v2.100.1 // indirect - k8s.io/kube-openapi v0.0.0-20230501164219-8b0f38b5fd1f // indirect + k8s.io/klog/v2 v2.90.1 // indirect + k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d // indirect k8s.io/kubectl v0.25.11 // indirect k8s.io/utils v0.0.0-20230308161112-d77c459e9343 // indirect nhooyr.io/websocket v1.8.7 // indirect @@ -472,8 +479,4 @@ replace ( github.com/prometheus/prometheus => github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2 github.com/sercand/kuberesolver v2.4.0+incompatible => github.com/sercand/kuberesolver/v5 v5.1.0 - - k8s.io/api => k8s.io/api v0.25.4 - k8s.io/client-go => k8s.io/client-go v0.25.4 - k8s.io/kube-openapi => k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d ) diff --git a/integration-tests/go.sum b/integration-tests/go.sum index fa3cc50d325..bd864cbb61d 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2037,8 +2037,8 @@ github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/9 github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE= github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= -github.com/pelletier/go-toml/v2 v2.0.8 h1:0ctb6s9mE31h0/lhu+J6OPmVeDxJn+kYnJc2jZR9tGQ= -github.com/pelletier/go-toml/v2 v2.0.8/go.mod h1:vuYfssBdrU2XDZ9bYydBu6t+6a6PYNcZljzZR9VXg+4= +github.com/pelletier/go-toml/v2 v2.0.9 h1:uH2qQXheeefCCkuBBSLi7jCiSmj3VRh2+Goq2N7Xxu0= +github.com/pelletier/go-toml/v2 v2.0.9/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= github.com/peterbourgon/diskv v2.0.1+incompatible h1:UBdAOUP5p4RWqPBg048CAvpKN+vxiaj6gdUUzhl4XmI= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= @@ -2191,14 +2191,14 @@ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= -github.com/smartcontractkit/chainlink-env v0.35.2 h1:KhlY2LgEq5e6Or5qlkCGIv0MJjJUA0mMVTgLdWptRAM= -github.com/smartcontractkit/chainlink-env v0.35.2/go.mod h1:hMOkTDW5k0C5B5lup1+xpPiZQPkq84YGLuFDVdTKU7A= +github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= +github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d h1:4jSCp6i/p/EIaAkYQDxPK8nXDuv0fBXzKIcVYzetCoI= -github.com/smartcontractkit/chainlink-testing-framework v1.14.1-0.20230731095810-a70b0af9a909 h1:mpObCUxX5PKy/Xm5qGLmhftRrk54G1uuxx1nqar1nBM= -github.com/smartcontractkit/chainlink-testing-framework v1.14.1-0.20230731095810-a70b0af9a909/go.mod h1:QVZ+0AZchJQttnpaYxgINEKxlFgmi4HxtptZLOc9YHg= +github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87gFQ27MAv4Iat7aoCnM3K87/d0r4Aho= +github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= @@ -2269,7 +2269,6 @@ github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1F github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= @@ -3317,20 +3316,20 @@ honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= -k8s.io/api v0.25.4 h1:3YO8J4RtmG7elEgaWMb4HgmpS2CfY1QlaOz9nwB+ZSs= -k8s.io/api v0.25.4/go.mod h1:IG2+RzyPQLllQxnhzD8KQNEu4c4YvyDTpSMztf4A0OQ= +k8s.io/api v0.25.11 h1:4mjYDfE3yp22jrytjH0knwgzjXKkxHX4D01ZCAazvZM= +k8s.io/api v0.25.11/go.mod h1:bK4UvD4bthtutNlvensrfBX21PRQ/vs2cIYggHkOOAo= k8s.io/apiextensions-apiserver v0.25.3 h1:bfI4KS31w2f9WM1KLGwnwuVlW3RSRPuIsfNF/3HzR0k= k8s.io/apiextensions-apiserver v0.25.3/go.mod h1:ZJqwpCkxIx9itilmZek7JgfUAM0dnTsA48I4krPqRmo= k8s.io/apimachinery v0.26.2 h1:da1u3D5wfR5u2RpLhE/ZtZS2P7QvDgLZTi9wrNZl/tQ= k8s.io/apimachinery v0.26.2/go.mod h1:ats7nN1LExKHvJ9TmwootT00Yz05MuYqPXEXaVeOy5I= k8s.io/cli-runtime v0.25.11 h1:GE2yNZm1tN+MJtw1SGMOLesLF7Kp7NVAVqRSTbXfu4o= k8s.io/cli-runtime v0.25.11/go.mod h1:r/nEINuHVEpgGhcd2WamU7hD1t/lMnSz8XM44Autltc= -k8s.io/client-go v0.25.4 h1:3RNRDffAkNU56M/a7gUfXaEzdhZlYhoW8dgViGy5fn8= -k8s.io/client-go v0.25.4/go.mod h1:8trHCAC83XKY0wsBIpbirZU4NTUpbuhc2JnI7OruGZw= +k8s.io/client-go v0.25.11 h1:DJQ141UsbNRI6wYSlcYLP5J5BW5Wq7Bgm42Ztq2SW70= +k8s.io/client-go v0.25.11/go.mod h1:41Xs7p1SfhoReUnmjjYCfCNWFiq4xSkexwJfbxF2F7A= k8s.io/component-base v0.25.11 h1:3QmISCE9n9CJkVpTA4spQO1IZCrLlOwbKdzSN9dqZZA= k8s.io/component-base v0.25.11/go.mod h1:wFR4pfB+xTc6FBak+RoWRNeTmelGE4XWJP/xVOvn3vM= -k8s.io/klog/v2 v2.100.1 h1:7WCHKK6K8fNhTqfBhISHQ97KrnJNFZMcQvKp7gP/tmg= -k8s.io/klog/v2 v2.100.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= +k8s.io/klog/v2 v2.90.1 h1:m4bYOKall2MmOiRaR1J+We67Do7vm9KiQVlT96lnHUw= +k8s.io/klog/v2 v2.90.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d h1:VcFq5n7wCJB2FQMCIHfC+f+jNcGgNMar1uKd6rVlifU= k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d/go.mod h1:y5VtZWM9sHHc2ZodIH/6SHzXj+TPU5USoA8lcIeKEKY= k8s.io/kubectl v0.25.11 h1:6bsft5Gan6BCvQ7cJbDRFjTm4Zfq8GuUYpsWAdVngYE= diff --git a/integration-tests/networks/known_networks.go b/integration-tests/networks/known_networks.go index a047ad024f5..524bd421d2d 100644 --- a/integration-tests/networks/known_networks.go +++ b/integration-tests/networks/known_networks.go @@ -8,6 +8,7 @@ import ( "time" "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/utils" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" diff --git a/integration-tests/soak/forwarder_ocr_test.go b/integration-tests/soak/forwarder_ocr_test.go index f2b3ec649f6..e8bcea0f5b8 100644 --- a/integration-tests/soak/forwarder_ocr_test.go +++ b/integration-tests/soak/forwarder_ocr_test.go @@ -1,106 +1,37 @@ package soak import ( - "fmt" - "math/big" - "os" - "strings" "testing" - "time" "github.com/stretchr/testify/require" - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/networks" "github.com/smartcontractkit/chainlink/integration-tests/testsetups" ) -func TestMain(m *testing.M) { - os.Exit(m.Run()) -} - func TestForwarderOCRSoak(t *testing.T) { l := utils.GetTestLogger(t) - testEnvironment, network := SetupForwarderOCRSoakEnv(t) - if testEnvironment.WillUseRemoteRunner() { + // Use this variable to pass in any custom EVM specific TOML values to your Chainlink nodes + customNetworkTOML := `[EVM.Transactions] +ForwardersEnabled = true` + // Uncomment below for debugging TOML issues on the node + // fmt.Println("Using Chainlink TOML\n---------------------") + // fmt.Println(client.AddNetworkDetailedConfig(config.BaseOCRP2PV1Config, customNetworkTOML, network)) + // fmt.Println("---------------------") + + ocrSoakTest, err := testsetups.NewOCRSoakTest(t, true) + require.NoError(t, err, "Error creating soak test") + ocrSoakTest.DeployEnvironment(customNetworkTOML) + if ocrSoakTest.Environment().WillUseRemoteRunner() { return } - - chainClient, err := blockchain.NewEVMClient(network, testEnvironment) - require.NoError(t, err, "Error connecting to blockchain") - ocrSoakTest := testsetups.NewOCRSoakTest(&testsetups.OCRSoakTestInputs{ - BlockchainClient: chainClient, - TestDuration: time.Minute * 15, - NumberOfContracts: 2, - ChainlinkNodeFunding: big.NewFloat(.1), - ExpectedRoundTime: time.Minute * 2, - TimeBetweenRounds: time.Minute * 1, - StartingAdapterValue: 5, - }) t.Cleanup(func() { - if err = actions.TeardownRemoteSuite(ocrSoakTest.TearDownVals(t)); err != nil { - l.Error().Err(err).Msg("Error when tearing down remote suite") + if err := actions.TeardownRemoteSuite(ocrSoakTest.TearDownVals(t)); err != nil { + l.Error().Err(err).Msg("Error tearing down environment") } }) - ocrSoakTest.OperatorForwarderFlow = true - ocrSoakTest.Setup(t, testEnvironment) - l.Info().Msg("Setup soak test") - ocrSoakTest.Run(t) -} - -func SetupForwarderOCRSoakEnv(t *testing.T) (*environment.Environment, blockchain.EVMNetwork) { - var ( - ocrForwarderBaseTOML = `[OCR] - Enabled = true - - [Feature] - LogPoller = true - - [P2P] - [P2P.V1] - Enabled = true - ListenIP = '0.0.0.0' - ListenPort = 6690` - - ocrForwarderNetworkDetailTOML = `[EVM.Transactions] - ForwardersEnabled = true` - ) - network := networks.SelectedNetwork // Environment currently being used to soak test on - - baseEnvironmentConfig := &environment.Config{ - TTL: time.Hour * 720, // 30 days, - NamespacePrefix: fmt.Sprintf( - "soak-forwarder-ocr-%s", - strings.ReplaceAll(strings.ToLower(network.Name), " ", "-"), - ), - Test: t, - } - - cd, err := chainlink.NewDeployment(6, map[string]interface{}{ - "toml": client.AddNetworkDetailedConfig(ocrForwarderBaseTOML, ocrForwarderNetworkDetailTOML, network), - }) - require.NoError(t, err, "Error creating chainlink deployment") - // Values you want each node to have the exact same of (e.g. eth_chain_id) - testEnvironment := environment.New(baseEnvironmentConfig). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(ethereum.New(ðereum.Props{ - NetworkName: network.Name, - Simulated: network.Simulated, - WsURLs: network.URLs, - })). - AddHelmCharts(cd) - - err = testEnvironment.Run() - require.NoError(t, err, "Error launching test environment") - return testEnvironment, network + ocrSoakTest.Setup() + ocrSoakTest.Run() } diff --git a/integration-tests/soak/ocr_test.go b/integration-tests/soak/ocr_test.go index 27000cd10a8..c0fd0a4525f 100644 --- a/integration-tests/soak/ocr_test.go +++ b/integration-tests/soak/ocr_test.go @@ -1,123 +1,44 @@ package soak import ( - "fmt" - "math/big" - "os" - "strconv" - "strings" "testing" - "time" - "github.com/kelseyhightower/envconfig" "github.com/stretchr/testify/require" - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/config" - "github.com/smartcontractkit/chainlink/integration-tests/networks" "github.com/smartcontractkit/chainlink/integration-tests/testsetups" ) func TestOCRSoak(t *testing.T) { l := utils.GetTestLogger(t) - testEnvironment, network, testInputs := SetupOCRSoakEnv(t) - if testEnvironment.WillUseRemoteRunner() { - return - } - - chainClient, err := blockchain.NewEVMClient(network, testEnvironment) - require.NoError(t, err, "Error connecting to network") - - ocrSoakTest := testsetups.NewOCRSoakTest(&testsetups.OCRSoakTestInputs{ - BlockchainClient: chainClient, - TestDuration: testInputs.TestDuration, - NumberOfContracts: 2, - ChainlinkNodeFunding: big.NewFloat(testInputs.ChainlinkNodeFunding), - ExpectedRoundTime: time.Minute * 2, - TimeBetweenRounds: testInputs.TimeBetweenRounds, - StartingAdapterValue: 5, - }) - t.Cleanup(func() { - if err := actions.TeardownRemoteSuite(ocrSoakTest.TearDownVals(t)); err != nil { - l.Error().Err(err).Msg("Error tearing down environment") - } - }) - ocrSoakTest.Setup(t, testEnvironment) - l.Info().Msg("Set up soak test") - ocrSoakTest.Run(t) -} - -func SetupOCRSoakEnv(t *testing.T) (*environment.Environment, blockchain.EVMNetwork, OcrSoakInputs) { - var testInputs OcrSoakInputs - err := envconfig.Process("OCR", &testInputs) - require.NoError(t, err, "Error reading OCR soak test inputs") - testInputs.setForRemoteRunner() - network := networks.SelectedNetwork // Environment currently being used to soak test on - - baseEnvironmentConfig := &environment.Config{ - TTL: time.Hour * 720, // 30 days, - NamespacePrefix: fmt.Sprintf( - "soak-ocr-%s", - strings.ReplaceAll(strings.ToLower(network.Name), " ", "-"), - ), - Test: t, - } - // Use this variable to pass in any custom EVM specific TOML values to your Chainlink nodes customNetworkTOML := `` // Uncomment below for debugging TOML issues on the node // fmt.Println("Using Chainlink TOML\n---------------------") // fmt.Println(client.AddNetworkDetailedConfig(config.BaseOCRP2PV1Config, customNetworkTOML, network)) // fmt.Println("---------------------") - cd, err := chainlink.NewDeployment(6, map[string]any{ - "toml": client.AddNetworkDetailedConfig(config.BaseOCRP2PV1Config, customNetworkTOML, network), - "db": map[string]any{ - "stateful": true, // stateful DB by default for soak tests - }, - "chainlink": map[string]any{ - "p2p_port": "6690", - }, - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment := environment.New(baseEnvironmentConfig). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(ethereum.New(ðereum.Props{ - NetworkName: network.Name, - Simulated: network.Simulated, - WsURLs: network.URLs, - })). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error launching test environment") - return testEnvironment, network, testInputs -} -type OcrSoakInputs struct { - TestDuration time.Duration `envconfig:"TEST_DURATION" default:"15m"` - ChainlinkNodeFunding float64 `envconfig:"CHAINLINK_NODE_FUNDING" default:".1"` - TimeBetweenRounds time.Duration `envconfig:"TIME_BETWEEN_ROUNDS" default:"1m"` -} - -func (i OcrSoakInputs) setForRemoteRunner() { - os.Setenv("TEST_OCR_TEST_DURATION", i.TestDuration.String()) - os.Setenv("TEST_OCR_CHAINLINK_NODE_FUNDING", strconv.FormatFloat(i.ChainlinkNodeFunding, 'f', -1, 64)) - os.Setenv("TEST_OCR_TIME_BETWEEN_ROUNDS", i.TimeBetweenRounds.String()) - - selectedNetworks := strings.Split(os.Getenv("SELECTED_NETWORKS"), ",") - for _, networkPrefix := range selectedNetworks { - urlEnv := fmt.Sprintf("%s_URLS", networkPrefix) - httpEnv := fmt.Sprintf("%s_HTTP_URLS", networkPrefix) - os.Setenv(fmt.Sprintf("TEST_%s", urlEnv), os.Getenv(urlEnv)) - os.Setenv(fmt.Sprintf("TEST_%s", httpEnv), os.Getenv(httpEnv)) + ocrSoakTest, err := testsetups.NewOCRSoakTest(t, false) + require.NoError(t, err, "Error creating soak test") + if !ocrSoakTest.Interrupted() { + ocrSoakTest.DeployEnvironment(customNetworkTOML) + } + if ocrSoakTest.Environment().WillUseRemoteRunner() { + return + } + t.Cleanup(func() { + if err := actions.TeardownRemoteSuite(ocrSoakTest.TearDownVals(t)); err != nil { + l.Error().Err(err).Msg("Error tearing down environment") + } + }) + if ocrSoakTest.Interrupted() { + err = ocrSoakTest.LoadState() + require.NoError(t, err, "Error loading state") + ocrSoakTest.Resume() + } else { + ocrSoakTest.Setup() + ocrSoakTest.Run() } } diff --git a/integration-tests/testreporters/ocr.go b/integration-tests/testreporters/ocr.go index 818d4192e87..a04718ea228 100644 --- a/integration-tests/testreporters/ocr.go +++ b/integration-tests/testreporters/ocr.go @@ -19,7 +19,7 @@ import ( // OCRSoakTestReporter collates all OCRAnswerUpdated events into a single report type OCRSoakTestReporter struct { - TestDuration time.Duration + StartTime time.Time AnomaliesDetected bool anomalies [][]string @@ -34,37 +34,38 @@ type TimeLineEvent interface { CSV() [][]string } -// RPCIssue is a single RPC issue, either a disconnect or reconnect -type RPCIssue struct { - StartTime time.Time - Message string +// TestIssue is a single RPC issue, either a disconnect or reconnect +type TestIssue struct { + StartTime time.Time `toml:"startTime"` + Message string `toml:"message"` } -func (r *RPCIssue) Time() time.Time { +func (r *TestIssue) Time() time.Time { return r.StartTime } -func (r *RPCIssue) CSV() [][]string { - return [][]string{{r.StartTime.Format("2006-01-02 15:04:05.00 MST"), r.Message}} +func (r *TestIssue) CSV() [][]string { + return [][]string{{r.StartTime.Format("2006-01-02 15:04:05.00 MST"), "Test Issue!", r.Message}} } -// OCRTestState indicates that a round per contract should complete within this time with this answer -type OCRTestState struct { - StartTime time.Time - EndTime time.Time // Time when the round should end, only used for analysis - Answer int64 - anomalous bool - anomalies [][]string - FoundEvents map[string][]*FoundEvent // Address -> FoundEvents, possible to have multiple found events per round, and need to call it out - TimeLineEvents []TimeLineEvent +// OCRRoundState indicates that a round per contract should complete within this time with this answer +type OCRRoundState struct { + StartTime time.Time `toml:"startTime"` + EndTime time.Time `toml:"endTime"` // Time when the round should end, only used for analysis + Answer int64 `toml:"answer"` + Anomalous bool `toml:"anomalous"` // Whether the round was anomalous + FoundEvents map[string][]*FoundEvent `toml:"foundEvents"` // Address -> FoundEvents, possible to have multiple found events per round, and need to call it out + TimeLineEvents []TimeLineEvent `toml:"timeLineEvents"` + + anomalies [][]string } -func (e *OCRTestState) Time() time.Time { +func (e *OCRRoundState) Time() time.Time { return e.StartTime } // CSV returns a CSV representation of the test state and all events -func (e *OCRTestState) CSV() [][]string { +func (e *OCRRoundState) CSV() [][]string { rows := [][]string{{e.StartTime.Format("2006-01-02 15:04:05.00 MST"), fmt.Sprintf("Expecting new Answer: %d", e.Answer)}} for _, anomaly := range e.anomalies { rows = append(rows, anomaly) @@ -76,31 +77,31 @@ func (e *OCRTestState) CSV() [][]string { // 1. There is a FoundEvent for every address // 2. There is only one FoundEvent for every address // 3. The answer is correct -func (e *OCRTestState) Validate() bool { +func (e *OCRRoundState) Validate() bool { anomalies := [][]string{} for address, eventList := range e.FoundEvents { if len(eventList) == 0 { - e.anomalous = true + e.Anomalous = true anomalies = append(anomalies, []string{ - e.StartTime.Format("2006-01-02 15:04:05.00 MST"), fmt.Sprintf("No AnswerUpdated for address '%s'", address), + e.StartTime.Format("2006-01-02 15:04:05.00 MST"), "Anomaly Found!", fmt.Sprintf("No AnswerUpdated for address '%s'", address), }) } else if len(eventList) > 1 { - e.anomalous = true - anomalies = append(anomalies, []string{e.StartTime.Format("2006-01-02 15:04:05.00 MST"), + e.Anomalous = true + anomalies = append(anomalies, []string{e.StartTime.Format("2006-01-02 15:04:05.00 MST"), "Anomaly Found!", fmt.Sprintf("Multiple AnswerUpdated for address '%s', possible double-transmission", address)}, ) } else { event := eventList[0] if event.Answer != e.Answer { - e.anomalous = true - anomalies = append(e.anomalies, []string{e.StartTime.Format("2006-01-02 15:04:05.00 MST"), + e.Anomalous = true + anomalies = append(e.anomalies, []string{e.StartTime.Format("2006-01-02 15:04:05.00 MST"), "Anomaly Found!", fmt.Sprintf("FoundEvent for address '%s' has wrong answer '%d'", address, event.Answer)}, ) } } } e.anomalies = anomalies - return e.anomalous + return e.Anomalous } // FoundEvent is a single round update event @@ -128,7 +129,7 @@ func (a *FoundEvent) CSV() [][]string { } // RecordEvents takes in a list of test states and RPC issues, orders them, and records them in the timeline -func (o *OCRSoakTestReporter) RecordEvents(testStates []*OCRTestState, rpcIssues []*RPCIssue) { +func (o *OCRSoakTestReporter) RecordEvents(testStates []*OCRRoundState, testIssues []*TestIssue) { events := []TimeLineEvent{} for _, expectedEvent := range testStates { if expectedEvent.Validate() { @@ -138,11 +139,12 @@ func (o *OCRSoakTestReporter) RecordEvents(testStates []*OCRTestState, rpcIssues events = append(events, expectedEvent) events = append(events, expectedEvent.TimeLineEvents...) } - if len(rpcIssues) > 0 { + if len(testIssues) > 0 { o.AnomaliesDetected = true } - for _, rpcIssue := range rpcIssues { - events = append(events, rpcIssue) + for _, testIssue := range testIssues { + events = append(events, testIssue) + o.anomalies = append(o.anomalies, testIssue.CSV()...) } sort.Slice(events, func(i, j int) bool { return events[i].Time().Before(events[j].Time()) @@ -178,8 +180,10 @@ func (o *OCRSoakTestReporter) WriteReport(folderLocation string) error { err = ocrReportWriter.Write([]string{ "Namespace", o.namespace, + "Started At", + o.StartTime.Format("2006-01-02 15:04:05.00 MST"), "Test Duration", - o.TestDuration.String(), + time.Since(o.StartTime).String(), }) if err != nil { return err @@ -245,7 +249,7 @@ func (o *OCRSoakTestReporter) SendSlackNotification(t *testing.T, slackClient *s headerText = ":warning: OCR Soak Test Found Anomalies :warning:" } messageBlocks := testreporters.CommonSlackNotificationBlocks( - headerText, o.namespace, o.csvLocation, + headerText, fmt.Sprintf("%s | Test took: %s", o.namespace, time.Since(o.StartTime).Truncate(time.Second).String()), o.csvLocation, ) ts, err := testreporters.SendSlackMessage(slackClient, slack.MsgOptionBlocks(messageBlocks...)) if err != nil { diff --git a/integration-tests/testsetups/keeper_benchmark.go b/integration-tests/testsetups/keeper_benchmark.go index 9ef0cd82ea1..c6430072877 100644 --- a/integration-tests/testsetups/keeper_benchmark.go +++ b/integration-tests/testsetups/keeper_benchmark.go @@ -45,6 +45,7 @@ type KeeperBenchmarkTest struct { upkeepIDs [][]*big.Int env *environment.Environment + namespace string chainlinkNodes []*client.ChainlinkK8sClient chainClient blockchain.EVMClient contractDeployer contracts.ContractDeployer @@ -102,6 +103,7 @@ func (k *KeeperBenchmarkTest) Setup(t *testing.T, env *environment.Environment) k.TestReporter.Summary.StartTime = startTime.UnixMilli() k.ensureInputValues(t) k.env = env + k.namespace = k.env.Cfg.Namespace inputs := k.Inputs k.keeperRegistries = make([]contracts.KeeperRegistry, len(inputs.RegistryVersions)) @@ -392,12 +394,12 @@ func (k *KeeperBenchmarkTest) subscribeToUpkeepPerformedEvent( // TearDownVals returns the networks that the test is running on func (k *KeeperBenchmarkTest) TearDownVals(t *testing.T) ( *testing.T, - *environment.Environment, + string, []*client.ChainlinkK8sClient, reportModel.TestReporter, blockchain.EVMClient, ) { - return t, k.env, k.chainlinkNodes, &k.TestReporter, k.chainClient + return t, k.namespace, k.chainlinkNodes, &k.TestReporter, k.chainClient } // ensureValues ensures that all values needed to run the test are present diff --git a/integration-tests/testsetups/ocr.go b/integration-tests/testsetups/ocr.go index 4b8016464fa..679c23b3060 100644 --- a/integration-tests/testsetups/ocr.go +++ b/integration-tests/testsetups/ocr.go @@ -3,19 +3,33 @@ package testsetups import ( "context" + "fmt" + "io/ioutil" "math/big" + "math/rand" + "os" + "os/signal" "sort" + "strconv" + "strings" + "syscall" "testing" "time" geth "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" + "github.com/kelseyhightower/envconfig" + "github.com/pelletier/go-toml/v2" "github.com/rs/zerolog" "github.com/rs/zerolog/log" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink-env/environment" + "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" + "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" + "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" + mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" reportModel "github.com/smartcontractkit/chainlink-testing-framework/testreporters" @@ -24,27 +38,35 @@ import ( "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/integration-tests/config" "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/networks" "github.com/smartcontractkit/chainlink/integration-tests/testreporters" ) +const saveFileLocation = "/persistence/ocr-soak-test-state.toml" + // OCRSoakTest defines a typical OCR soak test type OCRSoakTest struct { Inputs *OCRSoakTestInputs TestReporter testreporters.OCRSoakTestReporter OperatorForwarderFlow bool - testEnvironment *environment.Environment - bootstrapNode *client.ChainlinkK8sClient - workerNodes []*client.ChainlinkK8sClient - chainClient blockchain.EVMClient - mockServer *ctfClient.MockserverClient - mockPath string - filterQuery geth.FilterQuery - - ocrTestStates []*testreporters.OCRTestState - rpcIssues []*testreporters.RPCIssue - combinedEvents [][]string + t *testing.T + startTime time.Time + timeLeft time.Duration + startingBlockNum uint64 + testEnvironment *environment.Environment + namespace string + log zerolog.Logger + bootstrapNode *client.ChainlinkK8sClient + workerNodes []*client.ChainlinkK8sClient + chainClient blockchain.EVMClient + mockServer *ctfClient.MockserverClient + filterQuery geth.FilterQuery + + ocrRoundStates []*testreporters.OCRRoundState + testIssues []*testreporters.TestIssue ocrInstances []contracts.OffchainAggregator ocrInstanceMap map[string]contracts.OffchainAggregator // address : instance @@ -52,75 +74,156 @@ type OCRSoakTest struct { // OCRSoakTestInputs define required inputs to run an OCR soak test type OCRSoakTestInputs struct { - BlockchainClient blockchain.EVMClient // Client for the test to connect to the blockchain with - TestDuration time.Duration // How long to run the test for - NumberOfContracts int // Number of OCR contracts to launch - ChainlinkNodeFunding *big.Float // Amount of ETH to fund each chainlink node with - ExpectedRoundTime time.Duration // How long each round is expected to take - TimeBetweenRounds time.Duration // How long to wait after a completed round to start a new one, set 0 for instant - StartingAdapterValue int + TestDuration time.Duration `envconfig:"TEST_DURATION" default:"15m"` // How long to run the test for + NumberOfContracts int `envconfig:"NUMBER_CONTRACTS" default:"2"` // Number of OCR contracts to launch + ChainlinkNodeFunding float64 `envconfig:"CHAINLINK_NODE_FUNDING" default:".1"` // Amount of native currency to fund each chainlink node with + bigChainlinkNodeFunding *big.Float // Convenience conversions for funding + TimeBetweenRounds time.Duration `envconfig:"TIME_BETWEEN_ROUNDS" default:"1m"` // How long to wait before starting a new round; controls frequency of rounds +} + +func (i OCRSoakTestInputs) setForRemoteRunner() { + os.Setenv("TEST_OCR_TEST_DURATION", i.TestDuration.String()) + os.Setenv("TEST_OCR_NUMBER_CONTRACTS", fmt.Sprint(i.NumberOfContracts)) + os.Setenv("TEST_OCR_CHAINLINK_NODE_FUNDING", strconv.FormatFloat(i.ChainlinkNodeFunding, 'f', -1, 64)) + os.Setenv("TEST_OCR_TIME_BETWEEN_ROUNDS", i.TimeBetweenRounds.String()) + + selectedNetworks := strings.Split(os.Getenv("SELECTED_NETWORKS"), ",") + for _, networkPrefix := range selectedNetworks { + urlEnv := fmt.Sprintf("%s_URLS", networkPrefix) + httpEnv := fmt.Sprintf("%s_HTTP_URLS", networkPrefix) + os.Setenv(fmt.Sprintf("TEST_%s", urlEnv), os.Getenv(urlEnv)) + os.Setenv(fmt.Sprintf("TEST_%s", httpEnv), os.Getenv(httpEnv)) + } } // NewOCRSoakTest creates a new OCR soak test to setup and run -func NewOCRSoakTest(inputs *OCRSoakTestInputs) *OCRSoakTest { - if inputs.StartingAdapterValue == 0 { - inputs.StartingAdapterValue = 5 +func NewOCRSoakTest(t *testing.T, forwarderFlow bool) (*OCRSoakTest, error) { + var testInputs OCRSoakTestInputs + err := envconfig.Process("OCR", &testInputs) + if err != nil { + return nil, err } - return &OCRSoakTest{ - Inputs: inputs, + testInputs.setForRemoteRunner() + + test := &OCRSoakTest{ + Inputs: &testInputs, + OperatorForwarderFlow: forwarderFlow, TestReporter: testreporters.OCRSoakTestReporter{ - TestDuration: inputs.TestDuration, + StartTime: time.Now(), }, - ocrTestStates: make([]*testreporters.OCRTestState, 0), - mockPath: "ocr", + t: t, + startTime: time.Now(), + timeLeft: testInputs.TestDuration, + log: utils.GetTestLogger(t), + ocrRoundStates: make([]*testreporters.OCRRoundState, 0), ocrInstanceMap: make(map[string]contracts.OffchainAggregator), } + test.ensureInputValues() + return test, nil } -// Setup sets up the test environment, deploying contracts and funding chainlink nodes -func (o *OCRSoakTest) Setup(t *testing.T, env *environment.Environment) { - l := utils.GetTestLogger(t) - o.ensureInputValues(t) - o.testEnvironment = env - var err error +// DeployEnvironment deploys the test environment, starting all Chainlink nodes and other components for the test +func (o *OCRSoakTest) DeployEnvironment(customChainlinkNetworkTOML string) { + network := networks.SelectedNetwork // Environment currently being used to soak test on + nsPre := "soak-ocr-" + if o.OperatorForwarderFlow { + nsPre = fmt.Sprintf("%sforwarder-", nsPre) + } + nsPre = fmt.Sprintf("%s%s", nsPre, strings.ReplaceAll(strings.ToLower(network.Name), " ", "-")) + baseEnvironmentConfig := &environment.Config{ + TTL: time.Hour * 720, // 30 days, + NamespacePrefix: nsPre, + Test: o.t, + } + cd, err := chainlink.NewDeployment(6, map[string]any{ + "toml": client.AddNetworkDetailedConfig(config.BaseOCRP2PV1Config, customChainlinkNetworkTOML, network), + "db": map[string]any{ + "stateful": true, // stateful DB by default for soak tests + }, + }) + require.NoError(o.t, err, "Error creating chainlink deployment") + testEnvironment := environment.New(baseEnvironmentConfig). + AddHelm(mockservercfg.New(nil)). + AddHelm(mockserver.New(nil)). + AddHelm(ethereum.New(ðereum.Props{ + NetworkName: network.Name, + Simulated: network.Simulated, + WsURLs: network.URLs, + })). + AddHelmCharts(cd) + err = testEnvironment.Run() + require.NoError(o.t, err, "Error launching test environment") + o.testEnvironment = testEnvironment + o.namespace = testEnvironment.Cfg.Namespace +} + +// LoadEnvironment loads an existing test environment using the provided URLs +func (o *OCRSoakTest) LoadEnvironment(chainlinkURLs []string, chainURL, mockServerURL string) { + var ( + network = networks.SelectedNetwork + err error + ) + o.chainClient, err = blockchain.ConnectEVMClient(network) + require.NoError(o.t, err, "Error connecting to EVM client") + chainlinkNodes, err := client.ConnectChainlinkNodeURLs(chainlinkURLs) + require.NoError(o.t, err, "Error connecting to chainlink nodes") + o.bootstrapNode, o.workerNodes = chainlinkNodes[0], chainlinkNodes[1:] + o.mockServer, err = ctfClient.ConnectMockServerURL(mockServerURL) + require.NoError(o.t, err, "Error connecting to mockserver") +} + +// Environment returns the full K8s test environment +func (o *OCRSoakTest) Environment() *environment.Environment { + return o.testEnvironment +} + +func (o *OCRSoakTest) Setup() { + var ( + err error + network = networks.SelectedNetwork + ) + // Environment currently being used to soak test on // Make connections to soak test resources + o.chainClient, err = blockchain.NewEVMClient(network, o.testEnvironment) + require.NoError(o.t, err, "Error creating EVM client") contractDeployer, err := contracts.NewContractDeployer(o.chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - nodes, err := client.ConnectChainlinkNodes(env) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") + require.NoError(o.t, err, "Unable to create contract deployer") + require.NotNil(o.t, contractDeployer, "Contract deployer shouldn't be nil") + nodes, err := client.ConnectChainlinkNodes(o.testEnvironment) + require.NoError(o.t, err, "Connecting to chainlink nodes shouldn't fail") o.bootstrapNode, o.workerNodes = nodes[0], nodes[1:] - o.mockServer, err = ctfClient.ConnectMockServer(env) - require.NoError(t, err, "Creating mockserver clients shouldn't fail") + o.mockServer, err = ctfClient.ConnectMockServer(o.testEnvironment) + require.NoError(o.t, err, "Creating mockserver clients shouldn't fail") o.chainClient.ParallelTransactions(true) // Deploy LINK linkTokenContract, err := contractDeployer.DeployLinkTokenContract() - require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") + require.NoError(o.t, err, "Deploying Link Token Contract shouldn't fail") // Fund Chainlink nodes, excluding the bootstrap node - err = actions.FundChainlinkNodes(o.workerNodes, o.chainClient, o.Inputs.ChainlinkNodeFunding) - require.NoError(t, err, "Error funding Chainlink nodes") + err = actions.FundChainlinkNodes(o.workerNodes, o.chainClient, o.Inputs.bigChainlinkNodeFunding) + require.NoError(o.t, err, "Error funding Chainlink nodes") if o.OperatorForwarderFlow { contractLoader, err := contracts.NewContractLoader(o.chainClient) - require.NoError(t, err, "Loading contracts shouldn't fail") + require.NoError(o.t, err, "Loading contracts shouldn't fail") operators, authorizedForwarders, _ := actions.DeployForwarderContracts( - t, contractDeployer, linkTokenContract, o.chainClient, len(o.workerNodes), + o.t, contractDeployer, linkTokenContract, o.chainClient, len(o.workerNodes), ) forwarderNodesAddresses, err := actions.ChainlinkNodeAddresses(o.workerNodes) - require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") + require.NoError(o.t, err, "Retrieving on-chain wallet addresses for chainlink nodes shouldn't fail") for i := range o.workerNodes { actions.AcceptAuthorizedReceiversOperator( - t, operators[i], authorizedForwarders[i], []common.Address{forwarderNodesAddresses[i]}, o.chainClient, contractLoader, + o.t, operators[i], authorizedForwarders[i], []common.Address{forwarderNodesAddresses[i]}, o.chainClient, contractLoader, ) - require.NoError(t, err, "Accepting Authorize Receivers on Operator shouldn't fail") - actions.TrackForwarder(t, o.chainClient, authorizedForwarders[i], o.workerNodes[i]) + require.NoError(o.t, err, "Accepting Authorize Receivers on Operator shouldn't fail") + actions.TrackForwarder(o.t, o.chainClient, authorizedForwarders[i], o.workerNodes[i]) err = o.chainClient.WaitForEvents() } o.ocrInstances = actions.DeployOCRContractsForwarderFlow( - t, + o.t, o.Inputs.NumberOfContracts, linkTokenContract, contractDeployer, @@ -137,118 +240,295 @@ func (o *OCRSoakTest) Setup(t *testing.T, env *environment.Environment) { o.workerNodes, o.chainClient, ) - require.NoError(t, err) + require.NoError(o.t, err) } err = o.chainClient.WaitForEvents() - require.NoError(t, err, "Error waiting for OCR contracts to be deployed") + require.NoError(o.t, err, "Error waiting for OCR contracts to be deployed") for _, ocrInstance := range o.ocrInstances { o.ocrInstanceMap[ocrInstance.Address()] = ocrInstance } - l.Info().Msg("OCR Soak Test Setup Complete") + o.log.Info().Msg("OCR Soak Test Setup Complete") } // Run starts the OCR soak test -func (o *OCRSoakTest) Run(t *testing.T) { - l := utils.GetTestLogger(t) - +func (o *OCRSoakTest) Run() { ctx, cancel := context.WithTimeout(context.Background(), time.Second*5) latestBlockNum, err := o.chainClient.LatestBlockNumber(ctx) cancel() - require.NoError(t, err, "Error getting current block number") + require.NoError(o.t, err, "Error getting current block number") + o.startingBlockNum = latestBlockNum + + startingValue := 5 + if o.OperatorForwarderFlow { + actions.CreateOCRJobsWithForwarder(o.t, o.ocrInstances, o.bootstrapNode, o.workerNodes, startingValue, o.mockServer) + } else { + err := actions.CreateOCRJobs(o.ocrInstances, o.bootstrapNode, o.workerNodes, startingValue, o.mockServer) + require.NoError(o.t, err, "Error creating OCR jobs") + } + + o.log.Info(). + Str("Test Duration", o.Inputs.TestDuration.Truncate(time.Second).String()). + Int("Number of OCR Contracts", len(o.ocrInstances)). + Msg("Starting OCR Soak Test") + + o.testLoop(o.Inputs.TestDuration, startingValue) +} + +// Networks returns the networks that the test is running on +func (o *OCRSoakTest) TearDownVals(t *testing.T) ( + *testing.T, + string, + []*client.ChainlinkK8sClient, + reportModel.TestReporter, + blockchain.EVMClient, +) { + return t, o.namespace, append(o.workerNodes, o.bootstrapNode), &o.TestReporter, o.chainClient +} + +// ********************* +// Recovery if the test is shut-down/rebalanced by K8s +// ********************* + +// OCRSoakTestState contains all the info needed by the test to recover from a K8s rebalance, assuming the test was in a running state +type OCRSoakTestState struct { + Namespace string `toml:"namespace"` + OCRRoundStates []*testreporters.OCRRoundState `toml:"ocrRoundStates"` + TestIssues []*testreporters.TestIssue `toml:"testIssues"` + StartingBlockNum uint64 `toml:"startingBlockNum"` + StartTime time.Time `toml:"startTime"` + TimeRunning time.Duration `toml:"timeRunning"` + TestDuration time.Duration `toml:"testDuration"` + OCRContractAddresses []string `toml:"ocrContractAddresses"` + + BootStrapNodeURL string `toml:"bootstrapNodeURL"` + WorkerNodeURLs []string `toml:"workerNodeURLs"` + ChainURL string `toml:"chainURL"` + MockServerURL string `toml:"mockServerURL"` +} + +// SaveState saves the current state of the test to a TOML file +func (o *OCRSoakTest) SaveState() error { + ocrAddresses := make([]string, len(o.ocrInstances)) + for i, ocrInstance := range o.ocrInstances { + ocrAddresses[i] = ocrInstance.Address() + } + workerNodeURLs := make([]string, len(o.workerNodes)) + for i, workerNode := range o.workerNodes { + workerNodeURLs[i] = workerNode.URL() + } + + testState := &OCRSoakTestState{ + Namespace: o.namespace, + OCRRoundStates: o.ocrRoundStates, + TestIssues: o.testIssues, + StartingBlockNum: o.startingBlockNum, + StartTime: o.startTime, + TimeRunning: time.Since(o.startTime), + TestDuration: o.Inputs.TestDuration, + OCRContractAddresses: ocrAddresses, + + ChainURL: o.chainClient.GetNetworkConfig().URL, + MockServerURL: "http://mockserver:1080", // TODO: Make this dynamic + BootStrapNodeURL: o.bootstrapNode.URL(), + WorkerNodeURLs: workerNodeURLs, + } + data, err := toml.Marshal(testState) + if err != nil { + return err + } + // #nosec G306 - let everyone read + if err = os.WriteFile(saveFileLocation, data, 0644); err != nil { + return err + } + fmt.Println("---Saved State---") + fmt.Println(saveFileLocation) + fmt.Println("-----------------") + fmt.Println(string(data)) + fmt.Println("-----------------") + return nil +} + +// LoadState loads the test state from a TOML file +func (o *OCRSoakTest) LoadState() error { + if !o.Interrupted() { + return fmt.Errorf("no save file found at '%s'", saveFileLocation) + } + + testState := &OCRSoakTestState{} + saveData, err := ioutil.ReadFile(saveFileLocation) + if err != nil { + return err + } + err = toml.Unmarshal(saveData, testState) + if err != nil { + return err + } + fmt.Println("---Loaded State---") + fmt.Println(saveFileLocation) + fmt.Println("------------------") + fmt.Println(string(saveData)) + fmt.Println("------------------") + + o.namespace = testState.Namespace + o.TestReporter = testreporters.OCRSoakTestReporter{ + StartTime: testState.StartTime, + } + o.ocrRoundStates = testState.OCRRoundStates + o.testIssues = testState.TestIssues + o.Inputs.TestDuration = testState.TestDuration + o.timeLeft = testState.TestDuration - testState.TimeRunning + o.startTime = testState.StartTime + o.startingBlockNum = testState.StartingBlockNum + + network := networks.SelectedNetwork + o.chainClient, err = blockchain.ConnectEVMClient(network) + if err != nil { + return err + } + contractDeployer, err := contracts.NewContractDeployer(o.chainClient) + if err != nil { + return err + } + o.bootstrapNode, err = client.ConnectChainlinkNodeURL(testState.BootStrapNodeURL) + if err != nil { + return err + } + o.workerNodes, err = client.ConnectChainlinkNodeURLs(testState.WorkerNodeURLs) + if err != nil { + return err + } + + o.ocrInstances = make([]contracts.OffchainAggregator, len(testState.OCRContractAddresses)) + for i, addr := range testState.OCRContractAddresses { + address := common.HexToAddress(addr) + instance, err := contractDeployer.LoadOffChainAggregator(&address) + if err != nil { + return err + } + o.ocrInstances[i] = instance + } + o.mockServer, err = ctfClient.ConnectMockServerURL(testState.MockServerURL) + if err != nil { + return err + } + + return err +} + +func (o *OCRSoakTest) Resume() { + o.testIssues = append(o.testIssues, &testreporters.TestIssue{ + StartTime: time.Now(), + Message: "Test Resumed", + }) + log.Info().Str("Time Left", o.Inputs.TestDuration.String()).Msg("Resuming OCR Soak Test") ocrAddresses := make([]common.Address, len(o.ocrInstances)) for i, ocrInstance := range o.ocrInstances { ocrAddresses[i] = common.HexToAddress(ocrInstance.Address()) } contractABI, err := offchainaggregator.OffchainAggregatorMetaData.GetAbi() - require.NoError(t, err, "Error retrieving OCR contract ABI") + require.NoError(o.t, err, "Error retrieving OCR contract ABI") o.filterQuery = geth.FilterQuery{ Addresses: ocrAddresses, Topics: [][]common.Hash{{contractABI.Events["AnswerUpdated"].ID}}, - FromBlock: big.NewInt(0).SetUint64(latestBlockNum), + FromBlock: big.NewInt(0).SetUint64(o.startingBlockNum), } - if o.OperatorForwarderFlow { - actions.CreateOCRJobsWithForwarder(t, o.ocrInstances, o.bootstrapNode, o.workerNodes, 5, o.mockServer) - } else { - err := actions.CreateOCRJobs(o.ocrInstances, o.bootstrapNode, o.workerNodes, 5, o.mockServer) - require.NoError(t, err, "Error creating OCR jobs") - } + startingValue := 5 + o.testLoop(o.timeLeft, startingValue) - l.Info(). - Str("Test Duration", o.Inputs.TestDuration.Truncate(time.Second).String()). - Int("Number of OCR Contracts", len(o.ocrInstances)). - Msg("Starting OCR Soak Test") + o.log.Info().Msg("Test Complete, collecting on-chain events") - testDuration := time.After(o.Inputs.TestDuration) + err = o.collectEvents() + log.Error().Err(err).Interface("Query", o.filterQuery).Msg("Error collecting on-chain events, expect malformed report") + o.TestReporter.RecordEvents(o.ocrRoundStates, o.testIssues) +} - // ********************* - // ***** Test Loop ***** - // ********************* - lastAdapterValue, currentAdapterValue := o.Inputs.StartingAdapterValue, o.Inputs.StartingAdapterValue*25 - newRoundTrigger := time.NewTimer(0) +// Interrupted indicates whether the test was interrupted by something like a K8s rebalance or not +func (o *OCRSoakTest) Interrupted() bool { + _, err := os.Stat(saveFileLocation) + return err == nil +} + +// ********************* +// ****** Helpers ****** +// ********************* + +// testLoop is the primary test loop that will trigger new rounds and watch events +func (o *OCRSoakTest) testLoop(testDuration time.Duration, newValue int) { + endTest := time.After(testDuration) + interruption := make(chan os.Signal, 1) + signal.Notify(interruption, os.Kill, os.Interrupt, syscall.SIGTERM) + lastValue := 0 + newRoundTrigger := time.NewTimer(0) // Want to trigger a new round ASAP defer newRoundTrigger.Stop() - err = o.observeOCREvents(l) - require.NoError(t, err, "Error subscribing to OCR events") + err := o.observeOCREvents() + require.NoError(o.t, err, "Error subscribing to OCR events") -testLoop: for { select { - case <-testDuration: - break testLoop + case <-interruption: + saveStart := time.Now() + o.log.Warn().Msg("Test interrupted, saving state before shut down") + o.testIssues = append(o.testIssues, &testreporters.TestIssue{ + StartTime: time.Now(), + Message: "Test Interrupted", + }) + if err := o.SaveState(); err != nil { + o.log.Error().Err(err).Msg("Error saving state") + } + log.Warn().Str("Time Taken", time.Since(saveStart).String()).Msg("Saved state") + os.Exit(1) + case <-endTest: + return case <-newRoundTrigger.C: - lastAdapterValue, currentAdapterValue = currentAdapterValue, lastAdapterValue - err := o.triggerNewRound(t, currentAdapterValue) - + err := o.triggerNewRound(newValue) timerReset := o.Inputs.TimeBetweenRounds if err != nil { - l.Error().Err(err).Int("Seconds Waiting", 5).Msg("Error triggering new round, waiting and trying again") timerReset = time.Second * 5 + o.log.Error().Err(err). + Str("Waiting", timerReset.String()). + Msg("Error triggering new round, waiting and trying again. Possible connection issues with mockserver") } newRoundTrigger.Reset(timerReset) + + // Change value for the next round + newValue = rand.Intn(256) + 1 // #nosec G404 - not everything needs to be cryptographically secure + for newValue == lastValue { + newValue = rand.Intn(256) + 1 // #nosec G404 - kudos to you if you actually find a way to exploit this + } + lastValue = newValue case t := <-o.chainClient.ConnectionIssue(): - o.rpcIssues = append(o.rpcIssues, &testreporters.RPCIssue{ + o.testIssues = append(o.testIssues, &testreporters.TestIssue{ StartTime: t, Message: "RPC Connection Lost", }) case t := <-o.chainClient.ConnectionRestored(): - o.rpcIssues = append(o.rpcIssues, &testreporters.RPCIssue{ + o.testIssues = append(o.testIssues, &testreporters.TestIssue{ StartTime: t, Message: "RPC Connection Restored", }) } } - - l.Info().Msg("Test Complete, collecting on-chain events to be collected") - // Keep trying to collect events until we get them, no exceptions - timeout := time.Second * 5 - err = o.collectEvents(l, timeout) - for err != nil { - timeout *= 2 - err = o.collectEvents(l, timeout) - } - o.TestReporter.RecordEvents(o.ocrTestStates, o.rpcIssues) } -// Networks returns the networks that the test is running on -func (o *OCRSoakTest) TearDownVals(t *testing.T) ( - *testing.T, - *environment.Environment, - []*client.ChainlinkK8sClient, - reportModel.TestReporter, - blockchain.EVMClient, -) { - return t, o.testEnvironment, append(o.workerNodes, o.bootstrapNode), &o.TestReporter, o.chainClient -} - -// ********************* -// ****** Helpers ****** -// ********************* - // observeOCREvents subscribes to OCR events and logs them to the test logger // WARNING: Should only be used for observation and logging. This is not a reliable way to collect events. -func (o *OCRSoakTest) observeOCREvents(logger zerolog.Logger) error { +func (o *OCRSoakTest) observeOCREvents() error { + // set the filter query to listen for AnswerUpdated events on all OCR contracts + ocrAddresses := make([]common.Address, len(o.ocrInstances)) + for i, ocrInstance := range o.ocrInstances { + ocrAddresses[i] = common.HexToAddress(ocrInstance.Address()) + } + contractABI, err := offchainaggregator.OffchainAggregatorMetaData.GetAbi() + require.NoError(o.t, err, "Error retrieving OCR contract ABI") + o.filterQuery = geth.FilterQuery{ + Addresses: ocrAddresses, + Topics: [][]common.Hash{{contractABI.Events["AnswerUpdated"].ID}}, + FromBlock: big.NewInt(0).SetUint64(o.startingBlockNum), + } + eventLogs := make(chan types.Log) ctx, cancel := context.WithTimeout(context.Background(), 5*time.Second) defer cancel() @@ -271,7 +551,7 @@ func (o *OCRSoakTest) observeOCREvents(logger zerolog.Logger) error { Msg("Error parsing event as AnswerUpdated") continue } - logger.Info(). + o.log.Info(). Str("Address", event.Address.Hex()). Uint64("Block Number", event.BlockNumber). Uint64("Round ID", answerUpdated.RoundId.Uint64()). @@ -279,7 +559,7 @@ func (o *OCRSoakTest) observeOCREvents(logger zerolog.Logger) error { Msg("Answer Updated Event") case err = <-eventSub.Err(): for err != nil { - logger.Trace(). + o.log.Trace(). Err(err). Interface("Query", o.filterQuery). Msg("Error while subscribed to OCR Logs. Resubscribing") @@ -294,72 +574,61 @@ func (o *OCRSoakTest) observeOCREvents(logger zerolog.Logger) error { } // triggers a new OCR round by setting a new mock adapter value -func (o *OCRSoakTest) triggerNewRound(t *testing.T, currentAdapterValue int) error { - l := utils.GetTestLogger(t) - - if len(o.ocrTestStates) > 0 { - o.ocrTestStates[len(o.ocrTestStates)-1].EndTime = time.Now() +func (o *OCRSoakTest) triggerNewRound(newValue int) error { + if len(o.ocrRoundStates) > 0 { + o.ocrRoundStates[len(o.ocrRoundStates)-1].EndTime = time.Now() } - var ( - err error - attemptCount = 5 - ) - - // It's possible the adapter is temporarily down, so we try a few times if we get errors - for attemptCount > 0 { - attemptCount-- - err = actions.SetAllAdapterResponsesToTheSameValue(currentAdapterValue, o.ocrInstances, o.workerNodes, o.mockServer) - if err == nil { - break - } - log.Warn().Err(err). - Int("Attempts left", attemptCount). - Msg("Error setting adapter responses, adapter possibly temporarily down, trying again") - } + err := actions.SetAllAdapterResponsesToTheSameValue(newValue, o.ocrInstances, o.workerNodes, o.mockServer) if err != nil { return err } - expectedState := &testreporters.OCRTestState{ + expectedState := &testreporters.OCRRoundState{ StartTime: time.Now(), - Answer: int64(currentAdapterValue), + Answer: int64(newValue), FoundEvents: make(map[string][]*testreporters.FoundEvent), } for _, ocrInstance := range o.ocrInstances { expectedState.FoundEvents[ocrInstance.Address()] = make([]*testreporters.FoundEvent, 0) } - o.ocrTestStates = append(o.ocrTestStates, expectedState) - l.Info(). - Int("Value", currentAdapterValue). + o.ocrRoundStates = append(o.ocrRoundStates, expectedState) + o.log.Info(). + Int("Value", newValue). Msg("Starting a New OCR Round") return nil } -func (o *OCRSoakTest) collectEvents(logger zerolog.Logger, timeout time.Duration) error { +func (o *OCRSoakTest) collectEvents() error { start := time.Now() - o.ocrTestStates[len(o.ocrTestStates)-1].EndTime = start // Set end time for last expected event - logger.Info().Msg("Collecting on-chain events") - ctx, cancel := context.WithTimeout(context.Background(), timeout) - defer cancel() - contractEvents, err := o.chainClient.FilterLogs(ctx, o.filterQuery) - if err != nil { - log.Error(). - Err(err). - Str("Time", time.Since(start).String()). - Msg("Error collecting on-chain events") - return err + if len(o.ocrRoundStates) == 0 { + return fmt.Errorf("error collecting on-chain events, no rounds have been started") + } + o.ocrRoundStates[len(o.ocrRoundStates)-1].EndTime = start // Set end time for last expected event + o.log.Info().Msg("Collecting on-chain events") + + // We must retrieve the events, use exponential backoff for timeout to retry + var ( + contractEvents []types.Log + err error + timeout = time.Second * 15 + ) + for err != nil { + log.Info().Interface("Filter Query", o.filterQuery).Str("Timeout", timeout.String()).Msg("Retrieving on-chain events") + ctx, cancel := context.WithTimeout(context.Background(), timeout) + contractEvents, err = o.chainClient.FilterLogs(ctx, o.filterQuery) + cancel() + if err != nil { + log.Warn().Interface("Filter Query", o.filterQuery).Str("Timeout", timeout.String()).Msg("Error collecting on-chain events, trying again") + timeout *= 2 + } } sortedFoundEvents := make([]*testreporters.FoundEvent, 0) for _, event := range contractEvents { answerUpdated, err := o.ocrInstances[0].ParseEventAnswerUpdated(event) if err != nil { - log.Error(). - Err(err). - Str("Time", time.Since(start).String()). - Msg("Error collecting on-chain events") - return err + return fmt.Errorf("error parsing EventAnswerUpdated for event: %v, %w", event, err) } sortedFoundEvents = append(sortedFoundEvents, &testreporters.FoundEvent{ StartTime: time.Unix(answerUpdated.UpdatedAt.Int64(), 0), @@ -378,35 +647,43 @@ func (o *OCRSoakTest) collectEvents(logger zerolog.Logger, timeout time.Duration // Now match each found event with the expected event time frame expectedIndex := 0 for _, event := range sortedFoundEvents { - if !event.StartTime.Before(o.ocrTestStates[expectedIndex].EndTime) { + if !event.StartTime.Before(o.ocrRoundStates[expectedIndex].EndTime) { expectedIndex++ - if expectedIndex >= len(o.ocrTestStates) { - logger.Warn(). + if expectedIndex >= len(o.ocrRoundStates) { + o.log.Warn(). Str("Event Time", event.StartTime.String()). - Str("Expected End Time", o.ocrTestStates[expectedIndex].EndTime.String()). + Str("Expected End Time", o.ocrRoundStates[expectedIndex].EndTime.String()). Msg("Found events after last expected end time, adding event to that final report, things might be weird") } } - o.ocrTestStates[expectedIndex].FoundEvents[event.Address] = append(o.ocrTestStates[expectedIndex].FoundEvents[event.Address], event) - o.ocrTestStates[expectedIndex].TimeLineEvents = append(o.ocrTestStates[expectedIndex].TimeLineEvents, event) + o.ocrRoundStates[expectedIndex].FoundEvents[event.Address] = append(o.ocrRoundStates[expectedIndex].FoundEvents[event.Address], event) + o.ocrRoundStates[expectedIndex].TimeLineEvents = append(o.ocrRoundStates[expectedIndex].TimeLineEvents, event) } - logger.Info(). + o.log.Info(). Str("Time", time.Since(start).String()). Msg("Collected on-chain events") return nil } // ensureValues ensures that all values needed to run the test are present -func (o *OCRSoakTest) ensureInputValues(t *testing.T) { +func (o *OCRSoakTest) ensureInputValues() error { inputs := o.Inputs - require.NotNil(t, inputs.BlockchainClient, "Need a valid blockchain client to use for the test") - o.chainClient = inputs.BlockchainClient - require.GreaterOrEqual(t, inputs.NumberOfContracts, 1, "Expecting at least 1 OCR contract") - fund, _ := inputs.ChainlinkNodeFunding.Float64() - require.Greater(t, fund, 0.0, "Expecting non-zero chainlink node funding amount") - require.GreaterOrEqual(t, inputs.TestDuration, time.Minute*1, "Expected test duration to be more than a minute") - require.GreaterOrEqual(t, inputs.ExpectedRoundTime, time.Second, "Expected ExpectedRoundTime to be greater than 1 second") - require.NotNil(t, inputs.TimeBetweenRounds, "Expected TimeBetweenRounds to be set") - require.Less(t, inputs.TimeBetweenRounds, time.Hour, "TimeBetweenRounds must be less than 1 hour") + if inputs.NumberOfContracts <= 0 { + return fmt.Errorf("Number of OCR contracts must be greater than 0, found %d", inputs.NumberOfContracts) + } + if inputs.ChainlinkNodeFunding <= 0 { + return fmt.Errorf("Chainlink node funding must be greater than 0, found %f", inputs.ChainlinkNodeFunding) + } + if inputs.TestDuration <= time.Minute { + return fmt.Errorf("Test duration must be greater than 1 minute, found %s", inputs.TestDuration.String()) + } + if inputs.TimeBetweenRounds >= time.Hour { + return fmt.Errorf("Time between rounds must be less than 1 hour, found %s", inputs.TimeBetweenRounds.String()) + } + if inputs.TimeBetweenRounds < time.Second*30 { + return fmt.Errorf("Time between rounds must be greater or equal to 30 seconds, found %s", inputs.TimeBetweenRounds.String()) + } + o.Inputs.bigChainlinkNodeFunding = big.NewFloat(inputs.ChainlinkNodeFunding) + return nil } diff --git a/integration-tests/testsetups/vrfv2.go b/integration-tests/testsetups/vrfv2.go index 55d33fb958c..7afe9cf2cca 100644 --- a/integration-tests/testsetups/vrfv2.go +++ b/integration-tests/testsetups/vrfv2.go @@ -31,6 +31,7 @@ type VRFV2SoakTest struct { TestReporter testreporters.VRFV2SoakTestReporter testEnvironment *environment.Environment + namespace string ChainlinkNodes []*client.ChainlinkK8sClient chainClient blockchain.EVMClient DefaultNetwork blockchain.EVMClient @@ -73,6 +74,7 @@ func NewVRFV2SoakTest(inputs *VRFV2SoakTestInputs, chainlinkNodes []*client.Chai func (v *VRFV2SoakTest) Setup(t *testing.T, env *environment.Environment) { v.ensureInputValues(t) v.testEnvironment = env + v.namespace = v.testEnvironment.Cfg.Namespace v.chainClient.ParallelTransactions(true) } @@ -161,12 +163,12 @@ func requestAndValidate(t *VRFV2SoakTest, requestNumber int) { // Networks returns the networks that the test is running on func (v *VRFV2SoakTest) TearDownVals(t *testing.T) ( *testing.T, - *environment.Environment, + string, []*client.ChainlinkK8sClient, reportModel.TestReporter, blockchain.EVMClient, ) { - return t, v.testEnvironment, v.ChainlinkNodes, &v.TestReporter, v.chainClient + return t, v.namespace, v.ChainlinkNodes, &v.TestReporter, v.chainClient } // ensureValues ensures that all values needed to run the test are present From 47cc000cf867c45ec734d68bce2f27cc1e691090 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Tue, 1 Aug 2023 19:32:12 -0400 Subject: [PATCH 055/270] [Functions] (feat): Request commitment hashes & metadata (#9898) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Move FulfillResultCodes to interfaces folder * Rename Function.sol setArgs -> addArgs * Rename Routable s_config_hash -> s_configHash * Make Routable updateConfig public for re-use in constructor * Move comment out of IConfigurable * Make Routable s_router private with an internal getter * Rename constant to ROUTER_ID * Rename RouterBase s_config_hash -> s_configHash * Rename Routable.sol -> HasRouter.sol * Add IOwnableRouter interface * FunctionsSubscriptions MustBeSubOwner -> MustBeSubscriptionOwner * Make RouterBase variable private * RouterBase togglePause -> pause/unpause * Use full semantic version in typeAndVersion * ToS Allow List rename proof -> signature * Change acceptTermsOfService arguments from signature to raw r,s,v * Prettier format 💅 * Remove RouterBase versioning * Move RequestTimedOut event to Router * Rename requestSubscriptionOwnerTransfer -> proposeSubscriptionOwnerTransfer * (test): Update tests for changes * (test): Add v0 gas test * Regenerate geth wrappers * (feat): Store request commitments on-chain as hashes * Regenerate geth wrappers * Send commitment data back with Report * Roll back event changes for a separate PR * Regenerate geth wrappers * Rename Commitment -> OnchainMetadata for consistency * Regenerate geth wrappers * Rename GasOverhead -> GasOverheadJuels * Cleanup diff * Re-use commitment for passing data between Router<>Coordinator * Use named struct params * Allow anyone to time out requests * Remove Coordinator's billing events * InvalidId vs. InvalidCommitment * Remove errant space * Clean up diff slightly * Regen geth wrappers * (test): amend test events * (test): Bump up MaxObservationLengthBytes --- .../functions/dev/1_0_0/FunctionsBilling.sol | 108 ++---- .../dev/1_0_0/FunctionsCoordinator.sol | 61 ++-- .../functions/dev/1_0_0/FunctionsRouter.sol | 81 ++--- .../dev/1_0_0/FunctionsSubscriptions.sol | 57 +--- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 1 - .../1_0_0/interfaces/FulfillResultCodes.sol | 3 +- .../interfaces/IFunctionsCoordinator.sol | 9 +- .../1_0_0/interfaces/IFunctionsRequest.sol | 18 + .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 13 +- .../interfaces/IFunctionsSubscriptions.sol | 7 +- .../v0.8/functions/v1/FunctionsClient.test.ts | 18 +- .../v1/FunctionsSubscriptions.test.ts | 69 +++- .../test/v0.8/functions/v1/GasGolf.test.ts | 16 +- .../test/v0.8/functions/v1/RouterBase.test.ts | 6 + contracts/test/v0.8/functions/v1/utils.ts | 6 +- .../functions_coordinator.go | 318 +----------------- .../functions_router/functions_router.go | 46 ++- ...rapper-dependency-versions-do-not-edit.txt | 4 +- core/services/functions/listener.go | 1 + .../v1/functions_integration_test.go | 2 +- .../relay/evm/functions/logpoller_wrapper.go | 1 + core/services/relay/evm/types/types.go | 1 + 22 files changed, 305 insertions(+), 541 deletions(-) create mode 100644 contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 9e830ed1150..c7f3fd71651 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -4,6 +4,7 @@ pragma solidity ^0.8.19; import {HasRouter} from "./HasRouter.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; +import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; @@ -18,19 +19,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { // | Request Commitment state | // ================================================================ - struct Commitment { - uint64 subscriptionId; // ---------┐ - address client; // | - uint32 callbackGasLimit; // -------┘ - address don; // -------------------┐ - uint96 adminFee; // ---------------┘ - uint96 estimatedTotalCostJuels; // ┐ - uint80 donFee; // | - uint32 timestamp; // | - uint40 gasOverhead; // ------------┘ - uint256 expectedGasPrice; - } - mapping(bytes32 requestId => Commitment) private s_requestCommitments; + mapping(bytes32 requestId => bytes32 commitmentHash) private s_requestCommitments; event CommitmentDeleted(bytes32 requestId); @@ -97,19 +86,6 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { AggregatorV3Interface private s_linkToNativeFeed; - // ================================================================ - // | Cost Events | - // ================================================================ - event BillingStart(bytes32 indexed requestId, Commitment commitment); - event BillingEnd( - bytes32 indexed requestId, - uint64 subscriptionId, - uint96 signerPayment, - uint96 transmitterPayment, - uint96 totalCost, - FulfillResult result - ); - // ================================================================ // | Initialization | // ================================================================ @@ -294,16 +270,13 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { * @param data - Encoded Chainlink Functions request data, use FunctionsClient API to encode a request * @param requestDataVersion - Version number of the structure of the request data * @param billing - Billing configuration for the request - * @return requestId - A unique identifier of the request. Can be used to match a request to a response in fulfillRequest. - * @return estimatedCost - The estimated cost in Juels of LINK that will be charged to the subscription if all callback gas is used - * @return gasOverheadAfterCallback - The amount of gas that will be used after the user's callback - * @return requestTimeoutSeconds - The number of seconds that this request can remain unfilled before being considered stale + * @return commitment - The parameters of the request that must be held consistent at response time */ function _startBilling( bytes memory data, uint16 requestDataVersion, RequestBilling memory billing - ) internal returns (bytes32, uint96, uint256, uint256) { + ) internal returns (IFunctionsRequest.Commitment memory commitment) { // Nodes should support all past versions of the structure if (requestDataVersion > s_config.maxSupportedRequestDataVersion) { revert UnsupportedRequestDataVersion(); @@ -323,23 +296,21 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { bytes32 requestId = computeRequestId(address(this), billing.client, billing.subscriptionId, initiatedRequests + 1); - Commitment memory commitment = Commitment( - billing.subscriptionId, - billing.client, - billing.callbackGasLimit, - address(this), - adminFee, - estimatedCost, - donFee, - uint32(block.timestamp), - s_config.gasOverheadBeforeCallback + s_config.gasOverheadAfterCallback, - billing.expectedGasPrice - ); - s_requestCommitments[requestId] = commitment; - - emit BillingStart(requestId, commitment); + commitment = IFunctionsRequest.Commitment({ + adminFee: adminFee, + coordinator: address(this), + client: billing.client, + subscriptionId: billing.subscriptionId, + callbackGasLimit: billing.callbackGasLimit, + estimatedTotalCostJuels: estimatedCost, + timeoutTimestamp: uint40(block.timestamp + s_config.requestTimeoutSeconds), + requestId: requestId, + donFee: donFee, + gasOverheadBeforeCallback: s_config.gasOverheadBeforeCallback, + gasOverheadAfterCallback: s_config.gasOverheadAfterCallback + }); - return (requestId, estimatedCost, s_config.gasOverheadAfterCallback, s_config.requestTimeoutSeconds); + s_requestCommitments[requestId] = keccak256(abi.encode(commitment)); } /** @@ -366,18 +337,18 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { function _fulfillAndBill( bytes32 requestId, bytes memory response, - bytes memory err - ) - internal - returns ( - /* bytes calldata metadata, */ - FulfillResult - ) - { - Commitment memory commitment = s_requestCommitments[requestId]; - if (commitment.don == address(0)) { + bytes memory err, + bytes memory onchainMetadata, + bytes memory /* offchainMetadata TODO: use in getDonFee() for dynamic billing */ + ) internal returns (FulfillResult) { + IFunctionsRequest.Commitment memory commitment = abi.decode(onchainMetadata, (IFunctionsRequest.Commitment)); + if (s_requestCommitments[requestId] == bytes32(0)) { return FulfillResult.INVALID_REQUEST_ID; } + + if (s_requestCommitments[requestId] != keccak256(abi.encode(commitment))) { + return FulfillResult.INVALID_COMMITMENT; + } delete s_requestCommitments[requestId]; int256 weiPerUnitLink; @@ -388,18 +359,19 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { // (1e18 juels/link) * (wei/gas) / (wei/link) = juels per gas uint256 juelsPerGas = (1e18 * tx.gasprice) / uint256(weiPerUnitLink); // Gas overhead without callback - uint96 gasOverheadJuels = uint96(juelsPerGas * commitment.gasOverhead); - uint96 costWithoutFulfillment = gasOverheadJuels + commitment.donFee; + uint96 gasOverheadJuels = uint96( + juelsPerGas * (commitment.gasOverheadBeforeCallback + commitment.gasOverheadAfterCallback) + ); // The Functions Router will perform the callback to the client contract IFunctionsRouter router = IFunctionsRouter(address(_getRouter())); (uint8 result, uint96 callbackCostJuels) = router.fulfill( - requestId, response, err, uint96(juelsPerGas), - costWithoutFulfillment, - msg.sender + gasOverheadJuels + commitment.donFee, // costWithoutFulfillment + msg.sender, + commitment ); // Reimburse the transmitter for the fulfillment gas cost @@ -408,15 +380,6 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { // Saves on storage writes that would otherwise be charged to the user s_feePool += commitment.donFee; - emit BillingEnd( - requestId, - commitment.subscriptionId, - commitment.donFee, - gasOverheadJuels + callbackCostJuels, - gasOverheadJuels + callbackCostJuels + commitment.donFee + commitment.adminFee, - FulfillResult(result) - ); - return FulfillResult(result); } @@ -427,9 +390,8 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { * @inheritdoc IFunctionsBilling */ function deleteCommitment(bytes32 requestId) external override onlyRouter returns (bool) { - Commitment memory commitment = s_requestCommitments[requestId]; // Ensure that commitment exists - if (commitment.don == address(0)) { + if (s_requestCommitments[requestId] == bytes32(0)) { return false; } // Delete commitment diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 33d9a569bc9..dc14a17410b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -6,6 +6,7 @@ import {IFunctionsBilling, FunctionsBilling} from "./FunctionsBilling.sol"; import {OCR2Base} from "./ocr/OCR2Base.sol"; import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; import {ITypeAndVersion} from "./HasRouter.sol"; +import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; /** * @title Functions Coordinator contract @@ -22,7 +23,8 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli bytes data, uint16 dataVersion, bytes32 flags, - uint64 callbackGasLimit + uint64 callbackGasLimit, + bytes commitment ); event OracleResponse(bytes32 indexed requestId, address transmitter); event InvalidRequestID(bytes32 indexed requestId); @@ -147,31 +149,22 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli */ function sendRequest( Request calldata request - ) - external - override - onlyRouter - returns (bytes32 requestId, uint96 estimatedCost, uint256 gasAfterPaymentCalculation, uint256 requestTimeoutSeconds) - { + ) external override onlyRouter returns (IFunctionsRequest.Commitment memory commitment) { if (request.data.length == 0) { revert EmptyRequestData(); } - RequestBilling memory billing = IFunctionsBilling.RequestBilling( - request.subscriptionId, - request.requestingContract, - request.callbackGasLimit, - tx.gasprice - ); + RequestBilling memory billing = IFunctionsBilling.RequestBilling({ + subscriptionId: request.subscriptionId, + client: request.requestingContract, + callbackGasLimit: request.callbackGasLimit, + expectedGasPrice: tx.gasprice + }); - (requestId, estimatedCost, gasAfterPaymentCalculation, requestTimeoutSeconds) = _startBilling( - request.data, - request.dataVersion, - billing - ); + commitment = _startBilling(request.data, request.dataVersion, billing); emit OracleRequest( - requestId, + commitment.requestId, request.requestingContract, tx.origin, request.subscriptionId, @@ -179,7 +172,8 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli request.data, request.dataVersion, request.flags, - request.callbackGasLimit + request.callbackGasLimit, + abi.encode(commitment) ); } @@ -214,25 +208,26 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli bytes32[] memory requestIds; bytes[] memory results; bytes[] memory errors; - ( - requestIds, - results, - errors - /*metadata, TODO: usage metadata through report*/ - ) = abi.decode(report, (bytes32[], bytes[], bytes[])); - if (requestIds.length == 0 || requestIds.length != results.length || requestIds.length != errors.length) { + bytes[] memory onchainMetadata; + bytes[] memory offchainMetadata; + (requestIds, results, errors, onchainMetadata, offchainMetadata) = abi.decode( + report, + (bytes32[], bytes[], bytes[], bytes[], bytes[]) + ); + if ( + requestIds.length == 0 || + requestIds.length != results.length || + requestIds.length != errors.length || + requestIds.length != onchainMetadata.length || + requestIds.length != offchainMetadata.length + ) { revert ReportInvalid(); } // Bounded by "MaxRequestBatchSize" on the Job's ReportingPluginConfig for (uint256 i = 0; i < requestIds.length; ++i) { FulfillResult result = FulfillResult( - _fulfillAndBill( - requestIds[i], - results[i], - errors[i] - /* metadata[i], */ - ) + _fulfillAndBill(requestIds[i], results[i], errors[i], onchainMetadata[i], offchainMetadata[i]) ); if (result == FulfillResult.USER_SUCCESS || result == FulfillResult.USER_ERROR) { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 13fd3480dae..839c598a339 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -6,6 +6,7 @@ import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; +import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { @@ -135,20 +136,12 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions _whenNotPaused(); _isValidSubscription(subscriptionId); _isValidConsumer(msg.sender, subscriptionId); - _isValidCallbackGasLimit(subscriptionId, callbackGasLimit); + isValidCallbackGasLimit(subscriptionId, callbackGasLimit); address coordinatorAddress = _getContractById(donId, useProposed); // Forward request to DON - uint96 estimatedCost; - uint256 gasAfterPaymentCalculation; // Used to ensure that the transmitter supplies enough gas - uint256 requestTimeoutSeconds; - ( - requestId, - estimatedCost, - gasAfterPaymentCalculation, // Used to ensure that the transmitter supplies enough gas - requestTimeoutSeconds - ) = IFunctionsCoordinator(coordinatorAddress).sendRequest( + IFunctionsRequest.Commitment memory commitment = IFunctionsCoordinator(coordinatorAddress).sendRequest( IFunctionsCoordinator.Request( msg.sender, s_subscriptions[subscriptionId].owner, @@ -160,22 +153,29 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions ) ); - _markRequestInFlight(msg.sender, subscriptionId, estimatedCost); + _markRequestInFlight(msg.sender, subscriptionId, commitment.estimatedTotalCostJuels); // Store a commitment about the request - s_requestCommitments[requestId] = Commitment( - s_config.adminFee, - coordinatorAddress, - msg.sender, - subscriptionId, - callbackGasLimit, - estimatedCost, - uint40(block.timestamp + requestTimeoutSeconds), - uint120(gasAfterPaymentCalculation) + s_requestCommitments[commitment.requestId] = keccak256( + abi.encode( + IFunctionsRequest.Commitment({ + adminFee: s_config.adminFee, + coordinator: coordinatorAddress, + client: msg.sender, + subscriptionId: subscriptionId, + callbackGasLimit: callbackGasLimit, + estimatedTotalCostJuels: commitment.estimatedTotalCostJuels, + timeoutTimestamp: commitment.timeoutTimestamp, + requestId: commitment.requestId, + donFee: commitment.donFee, + gasOverheadBeforeCallback: commitment.gasOverheadBeforeCallback, + gasOverheadAfterCallback: commitment.gasOverheadAfterCallback + }) + ) ); emit RequestStart( - requestId, + commitment.requestId, donId, subscriptionId, s_subscriptions[subscriptionId].owner, @@ -186,7 +186,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions callbackGasLimit ); - return requestId; + return commitment.requestId; } function _validateProposedContracts( @@ -223,28 +223,31 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions * @inheritdoc IFunctionsRouter */ function fulfill( - bytes32 requestId, bytes memory response, bytes memory err, uint96 juelsPerGas, uint96 costWithoutFulfillment, - address transmitter + address transmitter, + IFunctionsRequest.Commitment memory commitment ) external override returns (uint8 resultCode, uint96 callbackGasCostJuels) { _whenNotPaused(); - Commitment memory commitment = s_requestCommitments[requestId]; - if (msg.sender != commitment.coordinator) { revert OnlyCallableFromCoordinator(); } - if (commitment.client == address(0)) { + if (s_requestCommitments[commitment.requestId] == bytes32(0)) { resultCode = 2; // FulfillResult.INVALID_REQUEST_ID return (resultCode, callbackGasCostJuels); } + if (keccak256(abi.encode(commitment)) != s_requestCommitments[commitment.requestId]) { + resultCode = 7; // FulfillResult.INVALID_REQUEST_ID + return (resultCode, callbackGasCostJuels); + } + // Check that the transmitter has supplied enough gas for the callback to succeed - if (gasleft() < commitment.callbackGasLimit + commitment.gasAfterPaymentCalculation) { + if (gasleft() < commitment.callbackGasLimit + commitment.gasOverheadAfterCallback) { resultCode = 3; // IFunctionsRouter.FulfillResult.INSUFFICIENT_GAS; return (resultCode, callbackGasCostJuels); } @@ -261,7 +264,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Check that the cost has not exceeded the quoted cost if ( commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > - commitment.estimatedCost + commitment.estimatedTotalCostJuels ) { resultCode = 5; // IFunctionsRouter.FulfillResult.COST_EXCEEDS_COMMITMENT return (resultCode, callbackGasCostJuels); @@ -270,16 +273,22 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // If checks pass, continue as default, 0 = USER_SUCCESS; resultCode = 0; - delete s_requestCommitments[requestId]; + delete s_requestCommitments[commitment.requestId]; - CallbackResult memory result = _callback(requestId, response, err, commitment.callbackGasLimit, commitment.client); + CallbackResult memory result = _callback( + commitment.requestId, + response, + err, + commitment.callbackGasLimit, + commitment.client + ); resultCode = result.success ? 0 // FulfillResult.USER_SUCCESS : 1; // FulfillResult.USER_ERROR Receipt memory receipt = _pay( commitment.subscriptionId, - commitment.estimatedCost, + commitment.estimatedTotalCostJuels, commitment.client, commitment.adminFee, juelsPerGas, @@ -288,7 +297,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions ); emit RequestEnd( - requestId, + commitment.requestId, commitment.subscriptionId, receipt.totalCostJuels, transmitter, @@ -372,11 +381,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions /** * @inheritdoc IFunctionsRouter */ - function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) external view { - _isValidCallbackGasLimit(subscriptionId, callbackGasLimit); - } - - function _isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) internal view { + function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) public view { uint8 index = uint8(_getFlags(subscriptionId)[GAS_FLAG_INDEX]); if (index >= s_config.maxCallbackGasLimits.length) { revert InvalidGasFlagValue(index); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 4eba036d07a..56bbe344ce1 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -5,6 +5,7 @@ import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol" import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; +import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; /** @@ -70,18 +71,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // | Request state | // ================================================================ - struct Commitment { - uint96 adminFee; // -----------┐ - address coordinator; // -------┘ - address client; // ------------┐ - uint64 subscriptionId; // | - uint32 callbackGasLimit; // ---┘ - uint96 estimatedCost; // --------------┐ - uint40 timeoutTimestamp; // | - uint120 gasAfterPaymentCalculation; // ┘ max 1e36 gas - } - - mapping(bytes32 requestId => Commitment) internal s_requestCommitments; + mapping(bytes32 requestId => bytes32 commitmentHash) internal s_requestCommitments; struct Receipt { uint96 callbackGasCostJuels; @@ -175,13 +165,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @notice Sets a request as in-flight * @dev Only callable within the Router - * @param client - - * @param subscriptionId - - * @param estimatedCost - */ - function _markRequestInFlight(address client, uint64 subscriptionId, uint96 estimatedCost) internal { + function _markRequestInFlight(address client, uint64 subscriptionId, uint96 estimatedTotalCostJuels) internal { // Earmark subscription funds - s_subscriptions[subscriptionId].blockedBalance += estimatedCost; + s_subscriptions[subscriptionId].blockedBalance += estimatedTotalCostJuels; // Increment sent requests s_consumers[client][subscriptionId].initiatedRequests += 1; @@ -190,17 +177,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @notice Moves funds from one subscription account to another. * @dev Only callable by the Coordinator contract that is saved in the request commitment - * @param subscriptionId - - * @param estimatedCost - - * @param client - - * @param adminFee - - * @param juelsPerGas - - * @param gasUsed - - * @param costWithoutCallbackJuels - */ function _pay( uint64 subscriptionId, - uint96 estimatedCost, + uint96 estimatedTotalCostJuels, address client, uint96 adminFee, uint96 juelsPerGas, @@ -222,7 +202,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei s_withdrawableTokens[address(this)] += adminFee; // Unblock earmarked funds - s_subscriptions[subscriptionId].blockedBalance -= estimatedCost; + s_subscriptions[subscriptionId].blockedBalance -= estimatedTotalCostJuels; // Increment finished requests s_consumers[client][subscriptionId].completedRequests += 1; } @@ -508,18 +488,15 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external override { + function timeoutRequests(IFunctionsRequest.Commitment[] calldata requestsToTimeoutByCommitment) external override { _whenNotPaused(); - for (uint256 i = 0; i < requestIdsToTimeout.length; ++i) { - bytes32 requestId = requestIdsToTimeout[i]; - Commitment memory request = s_requestCommitments[requestId]; - uint64 subscriptionId = request.subscriptionId; - - // Check that the message sender is the subscription owner - _isValidSubscription(subscriptionId); - address owner = s_subscriptions[subscriptionId].owner; - if (msg.sender != owner) { - revert MustBeSubscriptionOwner(); + for (uint256 i = 0; i < requestsToTimeoutByCommitment.length; ++i) { + IFunctionsRequest.Commitment memory request = requestsToTimeoutByCommitment[i]; + bytes32 requestId = request.requestId; + + // Check that request ID is valid + if (keccak256(abi.encode(request)) != s_requestCommitments[requestId]) { + revert InvalidCalldata(); } // Check that request has exceeded allowed request time @@ -528,11 +505,11 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } IFunctionsBilling coordinator = IFunctionsBilling(request.coordinator); - coordinator.deleteCommitment(requestId); + coordinator.deleteCommitment(requestId); // Release blocked balance - s_subscriptions[subscriptionId].blockedBalance -= request.estimatedCost; - s_consumers[request.client][subscriptionId].completedRequests += 1; + s_subscriptions[request.subscriptionId].blockedBalance -= request.estimatedTotalCostJuels; + s_consumers[request.client][request.subscriptionId].completedRequests += 1; // Delete commitment delete s_requestCommitments[requestId]; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index a8a7985ca62..f4a1f5ad22d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -49,7 +49,6 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme bytes to; uint256 timelockEndBlock; } - mapping(bytes32 id => ConfigProposal) private s_proposedConfig; event ConfigProposed(bytes32 id, bytes32 fromHash, bytes toBytes); event ConfigUpdated(bytes32 id, bytes32 fromHash, bytes toBytes); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol index 7ff5d0e0ad9..1178474a5d2 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol @@ -8,5 +8,6 @@ enum FulfillResult { INSUFFICIENT_GAS, // 3 INSUFFICIENT_SUBSCRIPTION_BALANCE, // 4 COST_EXCEEDS_COMMITMENT, // 5 - INTERNAL_ERROR // 6 + INTERNAL_ERROR, // 6 + INVALID_COMMITMENT // 7 } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 2d1e0ed9d45..57462a5b0aa 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -1,6 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; +import {IFunctionsRequest} from "./IFunctionsRequest.sol"; + /** * @title Chainlink Functions oracle interface. */ @@ -70,10 +72,7 @@ interface IFunctionsCoordinator { * @notice Sends a request (encoded as data) using the provided subscriptionId * @dev Callable only by the Router * @param request The request information, @dev see the struct for field descriptions - * @return requestId A unique request identifier (unique per DON) - * @return estimatedCost The cost in Juels of LINK that the request is estimated to charge if market conditions were to stay the same - * @return gasAfterPaymentCalculation The amount of gas overhead that will be used after balances have already been changed - * @return requestTimeoutSeconds The amount of time in seconds before this request is considered stale + * @return commitment - The parameters of the request that must be held consistent at response time */ - function sendRequest(Request calldata request) external returns (bytes32, uint96, uint256, uint256); + function sendRequest(Request calldata request) external returns (IFunctionsRequest.Commitment memory commitment); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol new file mode 100644 index 00000000000..fe53163d7da --- /dev/null +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol @@ -0,0 +1,18 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +interface IFunctionsRequest { + struct Commitment { + uint96 adminFee; // -----------┐ + address coordinator; // -------┘ + address client; // ------------┐ + uint64 subscriptionId; // | + uint32 callbackGasLimit; // ---┘ + uint96 estimatedTotalCostJuels; // TODO pack the following + uint40 timeoutTimestamp; + bytes32 requestId; + uint80 donFee; + uint40 gasOverheadBeforeCallback; + uint40 gasOverheadAfterCallback; + } +} diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index 4936261330f..f09409a9443 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -2,6 +2,7 @@ pragma solidity ^0.8.19; import {IRouterBase} from "./IRouterBase.sol"; +import {IFunctionsRequest} from "./IFunctionsRequest.sol"; /** * @title Chainlink Functions Router interface. @@ -43,22 +44,22 @@ interface IFunctionsRouter is IRouterBase { * - calling back the data that the Oracle returned to the client contract * - pay the DON for processing the request * @dev Only callable by the Coordinator contract that is saved in the commitment - * @param requestId The identifier for the request * @param response response data from DON consensus * @param err error from DON consensus - * @param juelsPerGas - - * @param costWithoutFulfillment - - * @param transmitter - + * @param juelsPerGas - current rate of juels/gas + * @param costWithoutFulfillment - The cost of processing the request (in Juels of LINK ), without fulfillment + * @param transmitter - The Node that transmitted the OCR report + * @param commitment - The parameters of the request that must be held consistent between request and response time * @return fulfillResult - * @return callbackGasCostJuels - */ function fulfill( - bytes32 requestId, bytes memory response, bytes memory err, uint96 juelsPerGas, uint96 costWithoutFulfillment, - address transmitter + address transmitter, + IFunctionsRequest.Commitment memory commitment ) external returns (uint8, uint96); /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index f483a15578b..d22ab447d4c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -1,6 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; +import {IFunctionsRequest} from "./IFunctionsRequest.sol"; + /** * @title Chainlink Functions Subscription interface. */ @@ -77,9 +79,10 @@ interface IFunctionsSubscriptions { /** * @notice Time out all expired requests: unlocks funds and removes the ability for the request to be fulfilled - * @param requestIdsToTimeout - A list of request IDs to time out + * @param requestsToTimeoutByCommitment - A list of request commitments to time out + * @dev The commitment can be found on the "OracleRequest" event created when sending the request. */ - function timeoutRequests(bytes32[] calldata requestIdsToTimeout) external; + function timeoutRequests(IFunctionsRequest.Commitment[] calldata requestsToTimeoutByCommitment) external; /** * @notice Oracle withdraw LINK earned through fulfilling requests diff --git a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts index 744d8a851d4..ba1ff5959e3 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts @@ -58,6 +58,7 @@ describe('Functions Client', () => { anyValue, flags, callbackGas, + anyValue, ) }) @@ -153,16 +154,25 @@ describe('Functions Client', () => { const response = stringToBytes('response') const error = stringToBytes('') const abi = ethers.utils.defaultAbiCoder - + const oracleRequestEvent = await contracts.coordinator.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] + const offchainMetadata = stringToBytes('') const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]'], - [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], + [ + [ethers.utils.hexZeroPad(requestId, 32)], + [response], + [error], + [onchainMetadata], + [offchainMetadata], + ], ) await expect(contracts.coordinator.callReport(report)) .to.emit(contracts.coordinator, 'OracleResponse') .withArgs(requestId, await roles.defaultAccount.getAddress()) - .to.emit(contracts.coordinator, 'BillingEnd') .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) }) diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 4df70003276..90f77fce151 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -619,16 +619,35 @@ describe('Functions Router - Subscriptions', () => { const response = stringToBytes('response') const error = stringToBytes('') const abi = ethers.utils.defaultAbiCoder - + const oracleRequestEvent = await contracts.coordinator.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] + const offchainMetadata = stringToBytes('') const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]'], - [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], + [ + [ethers.utils.hexZeroPad(requestId, 32)], + [response], + [error], + [onchainMetadata], + [offchainMetadata], + ], ) await expect(contracts.coordinator.callReport(report, { gasPrice })) .to.emit(contracts.coordinator, 'OracleResponse') .withArgs(requestId, await roles.defaultAccount.getAddress()) - .to.emit(contracts.coordinator, 'BillingEnd') + .to.emit(contracts.router, 'RequestEnd') + .withArgs( + requestId, + subscriptionId, + () => true, + () => true, + 0, // Result code for callback failing + () => true, + () => true, + ) .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) .to.emit(contracts.client, 'SendRequestInvoked') @@ -688,10 +707,20 @@ describe('Functions Router - Subscriptions', () => { const response = stringToBytes('response') const error = stringToBytes('') const abi = ethers.utils.defaultAbiCoder - + const oracleRequestEvent = await contracts.coordinator.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] + const offchainMetadata = stringToBytes('') const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]'], - [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], + [ + [ethers.utils.hexZeroPad(requestId, 32)], + [response], + [error], + [onchainMetadata], + [offchainMetadata], + ], ) await expect(contracts.coordinator.callReport(report, { gasPrice })) @@ -699,14 +728,15 @@ describe('Functions Router - Subscriptions', () => { .withArgs(requestId, await roles.defaultAccount.getAddress()) .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) - .to.emit(contracts.coordinator, 'BillingEnd') + .to.emit(contracts.router, 'RequestEnd') .withArgs( requestId, subscriptionId, () => true, () => true, - () => true, 1, // Result code for callback failing + () => true, + () => true, ) }) @@ -788,10 +818,20 @@ describe('Functions Router - Subscriptions', () => { const response = stringToBytes('response') const error = stringToBytes('') const abi = ethers.utils.defaultAbiCoder - + const oracleRequestEvent = await contracts.coordinator.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] + const offchainMetadata = stringToBytes('') const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]'], - [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], + [ + [ethers.utils.hexZeroPad(requestId, 32)], + [response], + [error], + [onchainMetadata], + [offchainMetadata], + ], ) await expect(contracts.coordinator.callReport(report, { gasPrice })) @@ -799,14 +839,15 @@ describe('Functions Router - Subscriptions', () => { .withArgs(requestId, await roles.defaultAccount.getAddress()) .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) - .to.emit(contracts.coordinator, 'BillingEnd') + .to.emit(contracts.router, 'RequestEnd') .withArgs( requestId, subscriptionId, () => true, () => true, - () => true, 1, // Result code for callback failing + () => true, + () => true, ) }) }) diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index e80dc469ed0..c7d9db434da 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -86,13 +86,23 @@ describe('Gas Golf', () => { ) const { gasUsed: requestTxGasUsed, events } = await requestTx.wait() const requestId = getEventArg(events, 'RequestSent', 0) - + const oracleRequestEvent = await contracts.coordinator.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) // DON's transmitter submits a response const response = stringToBytes('woah, thats fancy') const error = stringToBytes('') + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] + const offchainMetadata = stringToBytes('') const report = ethers.utils.defaultAbiCoder.encode( - ['bytes32[]', 'bytes[]', 'bytes[]'], - [[ethers.utils.hexZeroPad(requestId, 32)], [response], [error]], + ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], + [ + [ethers.utils.hexZeroPad(requestId, 32)], + [response], + [error], + [onchainMetadata], + [offchainMetadata], + ], ) const fulfillmentTx = await contracts.coordinator.callReport(report) const { gasUsed: fulfillmentTxGasUsed } = await fulfillmentTx.wait() diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 786ce796088..c3adfd8b9bf 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -217,10 +217,16 @@ describe('FunctionsRouter - Base', () => { const { events } = await requestProposedTx.wait() const requestId = getEventArg(events, 'RequestSent', 0) + const oracleRequestEvent = await coordinator2.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] const report = encodeReport( ethers.utils.hexZeroPad(requestId, 32), stringToHex('hello world'), stringToHex(''), + onchainMetadata, + stringToHex(''), ) await expect( diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index 52178627577..d06f9d11bef 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -47,11 +47,13 @@ export const encodeReport = ( requestId: string, result: string, err: string, + onchainMetadata: string, + offchainMetadata: string, ) => { const abi = ethers.utils.defaultAbiCoder return abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]'], - [[requestId], [result], [err]], + ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], + [[requestId], [result], [err], [onchainMetadata], [offchainMetadata]], ) } diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 2c9c6bb4e92..fc6e78ee5d3 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -30,19 +30,6 @@ var ( _ = abi.ConvertType ) -type FunctionsBillingCommitment struct { - SubscriptionId uint64 - Client common.Address - CallbackGasLimit uint32 - Don common.Address - AdminFee *big.Int - EstimatedTotalCostJuels *big.Int - DonFee *big.Int - Timestamp uint32 - GasOverhead *big.Int - ExpectedGasPrice *big.Int -} - type IFunctionsBillingRequestBilling struct { SubscriptionId uint64 Client common.Address @@ -60,9 +47,23 @@ type IFunctionsCoordinatorRequest struct { CallbackGasLimit uint32 } +type IFunctionsRequestCommitment struct { + AdminFee *big.Int + Coordinator common.Address + Client common.Address + SubscriptionId uint64 + CallbackGasLimit uint32 + EstimatedTotalCostJuels *big.Int + TimeoutTimestamp *big.Int + RequestId [32]byte + DonFee *big.Int + GasOverheadBeforeCallback *big.Int + GasOverheadAfterCallback *big.Int +} + var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint32\",\"name\":\"timestamp\",\"type\":\"uint32\"},{\"internalType\":\"uint40\",\"name\":\"gasOverhead\",\"type\":\"uint40\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005d3738038062005d37833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516156ac6200068b60003960008181610a3901528181610e5c015281816110ac0152818161113601528181611b9e01528181611de601528181612f680152613eaa015260006115db01526156ac6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610555578063de9dfa461461055d578063e3d0e71214610570578063f2fde38b1461058357600080fd5b8063b1dc65a414610414578063c3f909d414610427578063d227d2451461052557600080fd5b8063aecc12c5116100c8578063aecc12c5146103ac578063af1296d3146103ec578063afcb95d7146103f457600080fd5b80638cc6acce1461035f5780638da5cb5b146103725780639883c10d1461039a57600080fd5b806379ba50971161015b578063814118341161013557806381411834146102b257806381f1b938146102c757806381ff7048146102cf57806385b214cf1461033c57600080fd5b806379ba5097146102845780637f15e1661461028c578063807560311461029f57600080fd5b8063466557181161018c578063466557181461022d578063533989871461025b57806366316d8d1461027157600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac1461021a575b600080fd5b6101c66101c136600461416b565b610596565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190614211565b60405180910390f35b6101c6610228366004614246565b6105eb565b61024061023b3660046143a2565b61068d565b60405169ffffffffffffffffffff9091168152602001610211565b6102636106bb565b6040516102119291906144c9565b6101c661027f366004614573565b61093f565b6101c6610af9565b6101c661029a36600461416b565b610bfb565b6101c66102ad3660046145ac565b610c4b565b6102ba610d02565b6040516102119190614601565b610204610d71565b61031960015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b61034f61034a366004614614565b610e42565b6040519015158152602001610211565b6101c661036d36600461462d565b611094565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6007545b604051908152602001610211565b6103bf6103ba36600461466a565b611119565b604080519485526bffffffffffffffffffffffff9093166020850152918301526060820152608001610211565b61039e611375565b604080516001815260006020820181905291810191909152606001610211565b6101c66104223660046146ea565b611468565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff1661012082015261014001610211565b6105386105333660046147a1565b611b99565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611d8b565b61053861056b3660046143a2565b611de2565b6101c661057e3660046148c3565b611e7a565b6101c6610591366004614246565b61289e565b61059e6128af565b60008190036105d9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105e6828483614a31565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061062657503373ffffffffffffffffffffffffffffffffffffffff8216145b61065c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061068a916140b0565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561072357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106f8575b505050505090506000815167ffffffffffffffff81111561074657610746614263565b60405190808252806020026020018201604052801561077957816020015b60608152602001906001900390816107645790505b50905060005b825181101561093557600f600084838151811061079e5761079e614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107eb90614990565b9050600003610826576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061083c5761083c614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461088990614990565b80601f01602080910402602001604051908101604052809291908181526020018280546108b590614990565b80156109025780601f106108d757610100808354040283529160200191610902565b820191906000526020600020905b8154815290600101906020018083116108e557829003601f168201915b505050505082828151811061091957610919614b4c565b60200260200101819052508061092e90614baa565b905061077f565b5090939092509050565b610947612932565b806bffffffffffffffffffffffff1660000361097d5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109d7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c602052604081208054839290610a049084906bffffffffffffffffffffffff16614be2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610a5b7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610adc57600080fd5b505af1158015610af0573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c036128af565b6000819003610c3e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105e6828483614a31565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c965750610c7533612ac3565b8015610c9657503373ffffffffffffffffffffffffffffffffffffffff8416145b610ccc576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cfc828483614a31565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d6757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d3c575b5050505050905090565b606060108054610d8090614990565b9050600003610dbb576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610dc890614990565b80601f0160208091040260200160405190810160405280929190818152602001828054610df490614990565b8015610d675780601f10610e1657610100808354040283529160200191610d67565b820191906000526020600020905b815481529060010190602001808311610e2457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610eb3576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff90811694820194909452600182015492831660608201819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff9081166080830152600283015490811660a08301526c01000000000000000000000000810469ffffffffffffffffffff1660c0830152760100000000000000000000000000000000000000000000810490941660e08201527a01000000000000000000000000000000000000000000000000000090930464ffffffffff16610100840152600301546101208301526110075750600092915050565b600083815260086020526040808220828155600181018390556002810180547fff0000000000000000000000000000000000000000000000000000000000000016905560030191909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906110819085815260200190565b60405180910390a160019150505b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611103576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61110c81612bac565b8051602090910120600755565b60008080803373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461118d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61119a6040860186614c0e565b90506000036111d4576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808760600160208101906111f49190614c73565b67ffffffffffffffff16815260209081019061121290890189614246565b73ffffffffffffffffffffffffffffffffffffffff16815260200161123d60e0890160c08a01614c90565b63ffffffff1681523a60209091015290506112a961125e6040880188614c0e565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506112a39250505060a0890160808a01614cbd565b83612eb5565b929750909550935091506112c06020870187614246565b73ffffffffffffffffffffffffffffffffffffffff16857fd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c3261130960808b0160608c01614c73565b61131960408c0160208d01614246565b61132660408d018d614c0e565b8d60800160208101906113399190614cbd565b8e60a001358f60c00160208101906113519190614c90565b604051611365989796959493929190614cda565b60405180910390a3509193509193565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa15801561140f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114339190614d9a565b50935050925050828015611455575061144c8142614dea565b8463ffffffff16105b1561146057600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c0135916114be91849163ffffffff851691908e908e908190840183828082843760009201919091525061356392505050565b6114f4576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146115c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b76565b6115d78b8b8b8b8b8b61356c565b60007f000000000000000000000000000000000000000000000000000000000000000015611634576002826020015183604001516116159190614dfd565b61161f9190614e45565b61162a906001614dfd565b60ff16905061164a565b6020820151611644906001614dfd565b60ff1690505b8881146116b3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b76565b88871461171c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b76565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561175f5761175f614e67565b600281111561177057611770614e67565b905250905060028160200151600281111561178d5761178d614e67565b1480156117d457506006816000015160ff16815481106117af576117af614b4c565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b61183a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b76565b50505050506118476140ea565b6000808a8a60405161185a929190614e96565b604051908190038120611871918e90602001614ea6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b7b5760006001848984602081106118da576118da614b4c565b6118e791901a601b614dfd565b8e8e868181106118f9576118f9614b4c565b905060200201358d8d8781811061191257611912614b4c565b905060200201356040516000815260200160405260405161194f949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611971573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119f1576119f1614e67565b6002811115611a0257611a02614e67565b9052509250600183602001516002811115611a1f57611a1f614e67565b14611a86576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b76565b8251600090879060ff16601f8110611aa057611aa0614b4c565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611b22576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b76565b8086846000015160ff16601f8110611b3c57611b3c614b4c565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b67600186614dfd565b94505080611b7490614baa565b90506118bb565b505050611b8c833383858e8e61361a565b5050505050505050505050565b6000807f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8916600482015263ffffffff8616602482015290915073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611c3b57600080fd5b505afa158015611c4f573d6000803e3d6000fd5b50505050620f4240831115611c90576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611d1e88888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061068d915050565b69ffffffffffffffffffff1690506000611d6f89898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611de2915050565b9050611d7d87878484613921565b9a9950505050505050505050565b6060600e8054611d9a90614990565b9050600003611dd5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610dc890614990565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611e4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e739190614eba565b9392505050565b855185518560ff16601f831115611eed576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b76565b80600003611f57576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b76565b818314611fe5576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b76565b611ff0816003614ed7565b8311612058576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b76565b6120606128af565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a08101869052906120a79088613a83565b6005541561225c576005546000906120c190600190614dea565b90506000600582815481106120d8576120d8614b4c565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061211257612112614b4c565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061219257612192614eee565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806121fb576121fb614eee565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120a7915050565b60005b8151518110156126c3576000600460008460000151848151811061228557612285614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122cf576122cf614e67565b14612336576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b76565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061236757612367614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561240857612408614e67565b0217905550600091506124189050565b600460008460200151848151811061243257612432614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561247c5761247c614e67565b146124e3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b76565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061251657612516614b4c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156125b7576125b7614e67565b0217905550508251805160059250839081106125d5576125d5614b4c565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061265157612651614b4c565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806126bb81614baa565b91505061225f565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161277b91849174010000000000000000000000000000000000000000900416614f1d565b92506101000a81548163ffffffff021916908363ffffffff1602179055506127da4630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613aa0565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612891988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614f3a565b60405180910390a1611b8c565b6128a66128af565b61068a81613b4b565b60005473ffffffffffffffffffffffffffffffffffffffff163314612930576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b76565b565b600061293c610d02565b90508051600003612979576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d54600091612998916bffffffffffffffffffffffff16614fc0565b905060005b8251811015612a645781600c60008584815181106129bd576129bd614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612a259190614feb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612a5d90614baa565b905061299d565b508151612a719082615010565b600d8054600090612a919084906bffffffffffffffffffffffff16614be2565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612b2957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612afe575b5050505050905060005b8151811015612ba2578373ffffffffffffffffffffffffffffffffffffffff16828281518110612b6557612b65614b4c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612b92575060019392505050565b612b9b81614baa565b9050612b33565b5060009392505050565b600080600080600080600080600089806020019051810190612bce9190615040565b98509850985098509850985098509850985060008113612c1d576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b76565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612ea1908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60095460009081908190819061ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169087161115612f24576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612f30888761068d565b90506000612f3e8988611de2565b90506000612f62886040015189606001518569ffffffffffffffffffff1685613921565b905060007f000000000000000000000000000000000000000000000000000000000000000089516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015613006573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261304c91908101906150ec565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156130dd573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061310191906151d8565b509150506bffffffffffffffffffffffff851661311e8385614be2565b6bffffffffffffffffffffffff161015613164576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006131e3308e602001518f60000151856001613181919061522a565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff1681526020018a69ffffffffffffffffffff1681526020014263ffffffff1681526020016009600001600c9054906101000a900463ffffffff16600960000160089054906101000a900463ffffffff166132cf9190614f1d565b63ffffffff1664ffffffffff1681526020018f606001518152509050806008600084815260200190815260200160002060008201518160000160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060208201518160000160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff160217905550604082015181600001601c6101000a81548163ffffffff021916908363ffffffff16021790555060608201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160010160146101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548169ffffffffffffffffffff021916908369ffffffffffffffffffff16021790555060e08201518160020160166101000a81548163ffffffff021916908363ffffffff16021790555061010082015181600201601a6101000a81548164ffffffffff021916908364ffffffffff1602179055506101208201518160030155905050817fe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd82604051613513919061524b565b60405180910390a250600954909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60019392505050565b6000613579826020614ed7565b613584856020614ed7565b61359088610144615360565b61359a9190615360565b6135a49190615360565b6135af906000615360565b9050368114610af0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b76565b6060808061362a848601866153f3565b82519295509093509150158061364257508151835114155b8061364f57508051835114155b15613686576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518110156139155760006136ea8583815181106136a9576136a9614b4c565b60200260200101518584815181106136c3576136c3614b4c565b60200260200101518585815181106136dd576136dd614b4c565b6020026020010151613c40565b9050600081600681111561370057613700614e67565b148061371d5750600181600681111561371b5761371b614e67565b145b156137785784828151811061373457613734614b4c565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a2613904565b600281600681111561378c5761378c614e67565b036137dc578482815181106137a3576137a3614b4c565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a2613904565b60038160068111156137f0576137f0614e67565b036138405784828151811061380757613807614b4c565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a2613904565b600581600681111561385457613854614e67565b036138a45784828151811061386b5761386b614b4c565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a2613904565b60048160068111156138b8576138b8614e67565b03613904578482815181106138cf576138cf614b4c565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b5061390e81614baa565b9050613689565b50505050505050505050565b60008061392c611375565b90506000811361396b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b76565b60095460009087906139a19063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614f1d565b6139ab9190614f1d565b63ffffffff1690506000612710600960010154886139c99190614ed7565b6139d391906154d0565b6139dd9088615360565b9050600083836139f584670de0b6b3a7640000614ed7565b6139ff9190614ed7565b613a0991906154d0565b90506000613a286bffffffffffffffffffffffff808916908a16615360565b9050613a40816b033b2e3c9fd0803ce8000000614dea565b821115613a79576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611d7d8183615360565b6000613a8d610d02565b511115613a9c57613a9c612932565b5050565b6000808a8a8a8a8a8a8a8a8a604051602001613ac4999897969594939291906154e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613bca576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b76565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600860209081526040808320815161014081018352815467ffffffffffffffff8116825273ffffffffffffffffffffffffffffffffffffffff68010000000000000000820481169583019590955263ffffffff7c01000000000000000000000000000000000000000000000000000000009091048116938201939093526001820154938416606082018190526bffffffffffffffffffffffff7401000000000000000000000000000000000000000090950485166080830152600283015494851660a083015269ffffffffffffffffffff6c0100000000000000000000000086041660c0830152760100000000000000000000000000000000000000000000850490931660e082015264ffffffffff7a0100000000000000000000000000000000000000000000000000009094049390931661010084015260030154610120830152613d95576002915050611e73565b6000858152600860205260408120818155600181018290556002810180547fff00000000000000000000000000000000000000000000000000000000000000169055600301819055613de5611375565b905060008113613e24576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b76565b600081613e393a670de0b6b3a7640000614ed7565b613e4391906154d0565b9050600083610100015164ffffffffff1682613e5f9190614ed7565b905060008460c0015169ffffffffffffffffffff1682613e7f9190614feb565b6040517f3fd67e050000000000000000000000000000000000000000000000000000000081529091507f000000000000000000000000000000000000000000000000000000000000000090600090819073ffffffffffffffffffffffffffffffffffffffff841690633fd67e0590613f05908f908f908f908c908b903390600401615579565b60408051808303816000875af1158015613f23573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f4791906155ea565b9092509050613f568186614feb565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560c08a0151600d805469ffffffffffffffffffff90921693909291613fc391859116614feb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60c0015184896140299190614feb565b60808d015160c08e015169ffffffffffffffffffff16614049888d614feb565b6140539190614feb565b61405d9190614feb565b8760ff16600681111561407257614072614e67565b604051614083959493929190615619565b60405180910390a28160ff1660068111156140a0576140a0614e67565b9c9b505050505050505050505050565b5080546140bc90614990565b6000825580601f106140cc575050565b601f01602090049060005260206000209081019061068a9190614109565b604051806103e00160405280601f906020820280368337509192915050565b5b8082111561411e576000815560010161410a565b5090565b60008083601f84011261413457600080fd5b50813567ffffffffffffffff81111561414c57600080fd5b60208301915083602082850101111561416457600080fd5b9250929050565b6000806020838503121561417e57600080fd5b823567ffffffffffffffff81111561419557600080fd5b6141a185828601614122565b90969095509350505050565b6000815180845260005b818110156141d3576020818501810151868301820152016141b7565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611e7360208301846141ad565b73ffffffffffffffffffffffffffffffffffffffff8116811461068a57600080fd5b60006020828403121561425857600080fd5b8135611e7381614224565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156142d9576142d9614263565b604052919050565b600082601f8301126142f257600080fd5b813567ffffffffffffffff81111561430c5761430c614263565b61433d60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614292565b81815284602083860101111561435257600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461068a57600080fd5b803561108f8161436f565b63ffffffff8116811461068a57600080fd5b60008082840360a08112156143b657600080fd5b833567ffffffffffffffff808211156143ce57600080fd5b6143da878388016142e1565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561440c57600080fd5b6040519250608083019150828210818311171561442b5761442b614263565b50604052602084013561443d8161436f565b8152604084013561444d81614224565b6020820152606084013561446081614390565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156144be57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161448c565b509495945050505050565b6040815260006144dc6040830185614478565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561454a577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08784030185526145388383516141ad565b948601949250908501906001016144fe565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461068a57600080fd5b6000806040838503121561458657600080fd5b823561459181614224565b915060208301356145a181614559565b809150509250929050565b6000806000604084860312156145c157600080fd5b83356145cc81614224565b9250602084013567ffffffffffffffff8111156145e857600080fd5b6145f486828701614122565b9497909650939450505050565b602081526000611e736020830184614478565b60006020828403121561462657600080fd5b5035919050565b60006020828403121561463f57600080fd5b813567ffffffffffffffff81111561465657600080fd5b614662848285016142e1565b949350505050565b60006020828403121561467c57600080fd5b813567ffffffffffffffff81111561469357600080fd5b820160e08185031215611e7357600080fd5b60008083601f8401126146b757600080fd5b50813567ffffffffffffffff8111156146cf57600080fd5b6020830191508360208260051b850101111561416457600080fd5b60008060008060008060008060e0898b03121561470657600080fd5b606089018a81111561471757600080fd5b8998503567ffffffffffffffff8082111561473157600080fd5b61473d8c838d01614122565b909950975060808b013591508082111561475657600080fd5b6147628c838d016146a5565b909750955060a08b013591508082111561477b57600080fd5b506147888b828c016146a5565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156147b957600080fd5b85356147c48161436f565b9450602086013567ffffffffffffffff8111156147e057600080fd5b6147ec88828901614122565b909550935050604086013561480081614390565b949793965091946060013592915050565b600067ffffffffffffffff82111561482b5761482b614263565b5060051b60200190565b600082601f83011261484657600080fd5b8135602061485b61485683614811565b614292565b82815260059290921b8401810191818101908684111561487a57600080fd5b8286015b8481101561489e57803561489181614224565b835291830191830161487e565b509695505050505050565b60ff8116811461068a57600080fd5b803561108f816148a9565b60008060008060008060c087890312156148dc57600080fd5b863567ffffffffffffffff808211156148f457600080fd5b6149008a838b01614835565b9750602089013591508082111561491657600080fd5b6149228a838b01614835565b965061493060408a016148b8565b9550606089013591508082111561494657600080fd5b6149528a838b016142e1565b945061496060808a01614385565b935060a089013591508082111561497657600080fd5b5061498389828a016142e1565b9150509295509295509295565b600181811c908216806149a457607f821691505b6020821081036149dd577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105e657600081815260208120601f850160051c81016020861015614a0a5750805b601f850160051c820191505b81811015614a2957828155600101614a16565b505050505050565b67ffffffffffffffff831115614a4957614a49614263565b614a5d83614a578354614990565b836149e3565b6000601f841160018114614aaf5760008515614a795750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614b45565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b82811015614afe5786850135825560209485019460019092019101614ade565b5086821015614b39577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614bdb57614bdb614b7b565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614c0757614c07614b7b565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614c4357600080fd5b83018035915067ffffffffffffffff821115614c5e57600080fd5b60200191503681900382131561416457600080fd5b600060208284031215614c8557600080fd5b8135611e738161436f565b600060208284031215614ca257600080fd5b8135611e7381614390565b61ffff8116811461068a57600080fd5b600060208284031215614ccf57600080fd5b8135611e7381614cad565b600073ffffffffffffffffffffffffffffffffffffffff808b16835267ffffffffffffffff8a16602084015280891660408401525060e060608301528560e0830152610100868882850137600083880182015261ffff9590951660808301525060a081019290925263ffffffff1660c0820152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01690910101949350505050565b805169ffffffffffffffffffff8116811461108f57600080fd5b600080600080600060a08688031215614db257600080fd5b614dbb86614d80565b9450602086015193506040860151925060608601519150614dde60808701614d80565b90509295509295909350565b818103818111156106b5576106b5614b7b565b60ff81811683821601908111156106b5576106b5614b7b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614e5857614e58614e16565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b600060208284031215614ecc57600080fd5b8151611e7381614559565b80820281158282048414176106b5576106b5614b7b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614c0757614c07614b7b565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614f6a8184018a614478565b90508281036080840152614f7e8189614478565b905060ff871660a084015282810360c0840152614f9b81876141ad565b905067ffffffffffffffff851660e08401528281036101008401526140a081856141ad565b60006bffffffffffffffffffffffff80841680614fdf57614fdf614e16565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614c0757614c07614b7b565b6bffffffffffffffffffffffff81811683821602808216919082811461503857615038614b7b565b505092915050565b60008060008060008060008060006101208a8c03121561505f57600080fd5b895161506a81614390565b60208b015190995061507b81614390565b60408b015190985061508c81614390565b60608b015190975061509d81614390565b60808b01519096506150ae81614390565b94506150bc60a08b01614d80565b935060c08a01516150cc81614cad565b8093505060e08a015191506101008a015190509295985092959850929598565b600080600080600060a0868803121561510457600080fd5b855161510f81614559565b8095505060208087015161512281614559565b604088015190955061513381614224565b606088015190945061514481614224565b608088015190935067ffffffffffffffff81111561516157600080fd5b8701601f8101891361517257600080fd5b805161518061485682614811565b81815260059190911b8201830190838101908b83111561519f57600080fd5b928401925b828410156151c65783516151b781614224565b825292840192908401906151a4565b80955050505050509295509295909350565b6000806000606084860312156151ed57600080fd5b835180151581146151fd57600080fd5b602085015190935061520e8161436f565b604085015190925061521f8161436f565b809150509250925092565b67ffffffffffffffff818116838216019080821115614c0757614c07614b7b565b815167ffffffffffffffff16815261014081016020830151615285602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161529d604084018263ffffffff169052565b5060608301516152c5606084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060808301516152e560808401826bffffffffffffffffffffffff169052565b5060a083015161530560a08401826bffffffffffffffffffffffff169052565b5060c083015161532360c084018269ffffffffffffffffffff169052565b5060e083015161533b60e084018263ffffffff169052565b506101008381015164ffffffffff811684830152505061012092830151919092015290565b808201808211156106b5576106b5614b7b565b600082601f83011261538457600080fd5b8135602061539461485683614811565b82815260059290921b840181019181810190868411156153b357600080fd5b8286015b8481101561489e57803567ffffffffffffffff8111156153d75760008081fd5b6153e58986838b01016142e1565b8452509183019183016153b7565b60008060006060848603121561540857600080fd5b833567ffffffffffffffff8082111561542057600080fd5b818601915086601f83011261543457600080fd5b8135602061544461485683614811565b82815260059290921b8401810191818101908a84111561546357600080fd5b948201945b8386101561548157853582529482019490820190615468565b9750508701359250508082111561549757600080fd5b6154a387838801615373565b935060408601359150808211156154b957600080fd5b506154c686828701615373565b9150509250925092565b6000826154df576154df614e16565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b16604085015281606085015261552b8285018b614478565b9150838203608085015261553f828a614478565b915060ff881660a085015283820360c085015261555c82886141ad565b90861660e085015283810361010085015290506140a081856141ad565b86815260c06020820152600061559260c08301886141ad565b82810360408401526155a481886141ad565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b600080604083850312156155fd57600080fd5b8251615608816148a9565b60208401519092506145a181614559565b67ffffffffffffffff8616815269ffffffffffffffffffff851660208201526bffffffffffffffffffffffff84811660408301528316606082015260a081016007831061568f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b826080830152969550505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005a9438038062005a94833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516154096200068b60003960008181610a1901528181610e3c01528181610f1a01528181610ff801528181611a9401528181611cde01528181612eb00152613b09015260006114d101526154096000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610535578063de9dfa461461053d578063e3d0e71214610550578063f2fde38b1461056357600080fd5b8063b1dc65a4146103f4578063c3f909d414610407578063d227d2451461050557600080fd5b8063aecc12c5116100c8578063aecc12c5146103ac578063af1296d3146103cc578063afcb95d7146103d457600080fd5b80638cc6acce1461035f5780638da5cb5b146103725780639883c10d1461039a57600080fd5b806379ba50971161015b578063814118341161013557806381411834146102b257806381f1b938146102c757806381ff7048146102cf57806385b214cf1461033c57600080fd5b806379ba5097146102845780637f15e1661461028c578063807560311461029f57600080fd5b8063466557181161018c578063466557181461022d578063533989871461025b57806366316d8d1461027157600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac1461021a575b600080fd5b6101c66101c1366004613d5a565b610576565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190613e00565b60405180910390f35b6101c6610228366004613e35565b6105cb565b61024061023b366004613fbb565b61066d565b60405169ffffffffffffffffffff9091168152602001610211565b61026361069b565b6040516102119291906140e2565b6101c661027f36600461418c565b61091f565b6101c6610ad9565b6101c661029a366004613d5a565b610bdb565b6101c66102ad3660046141c5565b610c2b565b6102ba610ce2565b604051610211919061421a565b610204610d51565b61031960015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b61034f61034a36600461422d565b610e22565b6040519015158152602001610211565b6101c661036d366004614246565b610f02565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6007545b604051908152602001610211565b6103bf6103ba366004614283565b610f87565b60405161021191906143e4565b61039e61126b565b604080516001815260006020820181905291810191909152606001610211565b6101c6610402366004614438565b61135e565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff1661012082015261014001610211565b6105186105133660046144ef565b611a8f565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611c83565b61051861054b366004613fbb565b611cda565b6101c661055e366004614611565b611d72565b6101c6610571366004613e35565b612796565b61057e6127a7565b60008190036105b9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105c682848361477f565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061060657503373ffffffffffffffffffffffffffffffffffffffff8216145b61063c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061066a91613c9f565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106d8575b505050505090506000815167ffffffffffffffff81111561072657610726613e52565b60405190808252806020026020018201604052801561075957816020015b60608152602001906001900390816107445790505b50905060005b825181101561091557600f600084838151811061077e5761077e61489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107cb906146de565b9050600003610806576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061081c5761081c61489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610869906146de565b80601f0160208091040260200160405190810160405280929190818152602001828054610895906146de565b80156108e25780601f106108b7576101008083540402835291602001916108e2565b820191906000526020600020905b8154815290600101906020018083116108c557829003601f168201915b50505050508282815181106108f9576108f961489a565b60200260200101819052508061090e906148f8565b905061075f565b5090939092509050565b61092761282a565b806bffffffffffffffffffffffff1660000361095d5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109b7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109e49084906bffffffffffffffffffffffff16614930565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610a3b7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610abc57600080fd5b505af1158015610ad0573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610be36127a7565b6000819003610c1e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105c682848361477f565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c765750610c55336129bb565b8015610c7657503373ffffffffffffffffffffffffffffffffffffffff8416145b610cac576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cdc82848361477f565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d4757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d1c575b5050505050905090565b606060108054610d60906146de565b9050600003610d9b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610da8906146de565b80601f0160208091040260200160405190810160405280929190818152602001828054610dd4906146de565b8015610d475780601f10610df657610100808354040283529160200191610d47565b820191906000526020600020905b815481529060010190602001808311610e0457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e93576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902054610eae57506000919050565b60008281526008602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610ef19084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f71576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610f7a81612aa4565b8051602090910120600755565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461104f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61105c604083018361495c565b9050600003611096576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808460600160208101906110b691906149c1565b67ffffffffffffffff1681526020908101906110d490860186613e35565b73ffffffffffffffffffffffffffffffffffffffff1681526020016110ff60e0860160c087016149de565b63ffffffff1681523a602090910152905061116b611120604085018561495c565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506111659250505060a0860160808701614a0b565b83612dad565b915061117a6020840184613e35565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3328660600160208101906111ca91906149c1565b6111da6040890160208a01613e35565b6111e760408a018a61495c565b6111f760a08c0160808d01614a0b565b60a08c013561120c60e08e0160c08f016149de565b8c60405160200161121d91906143e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261125d999897969594939291614a28565b60405180910390a350919050565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611305573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113299190614af5565b5093505092505082801561134b57506113428142614b45565b8463ffffffff16105b1561135657600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c0135916113b491849163ffffffff851691908e908e908190840183828082843760009201919091525061328592505050565b6113ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146114bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b56565b6114cd8b8b8b8b8b8b61328e565b60007f00000000000000000000000000000000000000000000000000000000000000001561152a5760028260200151836040015161150b9190614b58565b6115159190614ba0565b611520906001614b58565b60ff169050611540565b602082015161153a906001614b58565b60ff1690505b8881146115a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b56565b888714611612576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b56565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561165557611655614bc2565b600281111561166657611666614bc2565b905250905060028160200151600281111561168357611683614bc2565b1480156116ca57506006816000015160ff16815481106116a5576116a561489a565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611730576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b56565b505050505061173d613cd9565b6000808a8a604051611750929190614bf1565b604051908190038120611767918e90602001614c01565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611a715760006001848984602081106117d0576117d061489a565b6117dd91901a601b614b58565b8e8e868181106117ef576117ef61489a565b905060200201358d8d878181106118085761180861489a565b9050602002013560405160008152602001604052604051611845949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611867573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156118e7576118e7614bc2565b60028111156118f8576118f8614bc2565b905250925060018360200151600281111561191557611915614bc2565b1461197c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b56565b8251600090879060ff16601f81106119965761199661489a565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611a18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b56565b8086846000015160ff16601f8110611a3257611a3261489a565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611a5d600186614b58565b94505080611a6a906148f8565b90506117b1565b505050611a82833383858e8e61333c565b5050505050505050505050565b6000807f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8916600482015263ffffffff8616602482015290915073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611b3157600080fd5b505afa158015611b45573d6000803e3d6000fd5b50505050620f4240831115611b86576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611c1488888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061066d915050565b69ffffffffffffffffffff1690506000611c6589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611cda915050565b9050611c738787848461369a565b9450505050505b95945050505050565b6060600e8054611c92906146de565b9050600003611ccd576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610da8906146de565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611d47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d6b9190614c20565b9392505050565b855185518560ff16601f831115611de5576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b56565b80600003611e4f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b56565b818314611edd576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b56565b611ee8816003614c3d565b8311611f50576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b56565b611f586127a7565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f9f908861380a565b6005541561215457600554600090611fb990600190614b45565b9050600060058281548110611fd057611fd061489a565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200a5761200a61489a565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208a5761208a614c54565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120f3576120f3614c54565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f9f915050565b60005b8151518110156125bb576000600460008460000151848151811061217d5761217d61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121c7576121c7614bc2565b1461222e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b56565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225f5761225f61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561230057612300614bc2565b0217905550600091506123109050565b600460008460200151848151811061232a5761232a61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561237457612374614bc2565b146123db576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b56565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240e5761240e61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124af576124af614bc2565b0217905550508251805160059250839081106124cd576124cd61489a565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106125495761254961489a565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125b3816148f8565b915050612157565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161267391849174010000000000000000000000000000000000000000900416614c83565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126d24630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613827565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612789988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614ca0565b60405180910390a1611a82565b61279e6127a7565b61066a816138d2565b60005473ffffffffffffffffffffffffffffffffffffffff163314612828576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b56565b565b6000612834610ce2565b90508051600003612871576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d54600091612890916bffffffffffffffffffffffff16614d36565b905060005b825181101561295c5781600c60008584815181106128b5576128b561489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff1661291d9190614d61565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612955906148f8565b9050612895565b5081516129699082614d86565b600d80546000906129899084906bffffffffffffffffffffffff16614930565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a2157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129f6575b5050505050905060005b8151811015612a9a578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5d57612a5d61489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a8a575060019392505050565b612a93816148f8565b9050612a2b565b5060009392505050565b600080600080600080600080600089806020019051810190612ac69190614dc1565b98509850985098509850985098509850985060008113612b15576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d99908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260095461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115612e6c576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612e78858461066d565b90506000612e868685611cda565b90506000612eaa856040015186606001518569ffffffffffffffffffff168561369a565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612f4e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612f949190810190614e78565b50505060208a01518a516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015613025573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130499190614f6f565b509150506bffffffffffffffffffffffff85166130668385614930565b6bffffffffffffffffffffffff1610156130ac576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061312b308b602001518c600001518560016130c99190614fc1565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b60408051610160810182526bffffffffffffffffffffffff808b168252306020808401919091528e015173ffffffffffffffffffffffffffffffffffffffff16828401528d5167ffffffffffffffff166060830152918d015163ffffffff908116608083015291891660a08201526009549293509160c08301916131c49170010000000000000000000000000000000090041642614fe2565b64ffffffffff168152602080820184905269ffffffffffffffffffff8b1660408084019190915260095463ffffffff680100000000000000008204811660608601526c01000000000000000000000000909104166080909301929092529051919a50613232918b91016143e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260089092529091205550959998505050505050505050565b60019392505050565b600061329b826020614c3d565b6132a6856020614c3d565b6132b288610144614fe2565b6132bc9190614fe2565b6132c69190614fe2565b6132d1906000614fe2565b9050368114610ad0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b56565b60608080808061334e868801886150d0565b845194995092975090955093509150158061336b57508351855114155b8061337857508251855114155b8061338557508151855114155b8061339257508051855114155b156133c9576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561368c5760006134618783815181106133ec576133ec61489a565b60200260200101518784815181106134065761340661489a565b60200260200101518785815181106134205761342061489a565b602002602001015187868151811061343a5761343a61489a565b60200260200101518787815181106134545761345461489a565b60200260200101516139c7565b9050600081600781111561347757613477614bc2565b14806134945750600181600781111561349257613492614bc2565b145b156134ef578682815181106134ab576134ab61489a565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a261367b565b600281600781111561350357613503614bc2565b036135535786828151811061351a5761351a61489a565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a261367b565b600381600781111561356757613567614bc2565b036135b75786828151811061357e5761357e61489a565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a261367b565b60058160078111156135cb576135cb614bc2565b0361361b578682815181106135e2576135e261489a565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a261367b565b600481600781111561362f5761362f614bc2565b0361367b578682815181106136465761364661489a565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b50613685816148f8565b90506133cc565b505050505050505050505050565b6000806136a561126b565b9050600081136136e4576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b600954600090879061371a9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c83565b6137249190614c83565b63ffffffff1690506000612710600960010154886137429190614c3d565b61374c91906151a2565b6137569088614fe2565b90506000838361376e84670de0b6b3a7640000614c3d565b6137789190614c3d565b61378291906151a2565b905060006137a16bffffffffffffffffffffffff808916908a16614fe2565b90506137b9816b033b2e3c9fd0803ce8000000614b45565b8211156137f2576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6137fc8183614fe2565b9a9950505050505050505050565b6000613814610ce2565b5111156138235761382361282a565b5050565b6000808a8a8a8a8a8a8a8a8a60405160200161384b999897969594939291906151b6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613951576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b56565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906139de9190615260565b6000888152600860205260409020549091506139fe576002915050611c7a565b80604051602001613a0f91906143e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600890935291205414613a61576007915050611c7a565b6000878152600860205260408120819055613a7a61126b565b905060008113613ab9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b600081613ace3a670de0b6b3a7640000614c3d565b613ad891906151a2565b90506000836101400151846101200151613af29190615333565b613b039064ffffffffff1683614c3d565b905060007f000000000000000000000000000000000000000000000000000000000000000090506000808273ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288d8d888b610100015169ffffffffffffffffffff1689613b699190614d61565b338d6040518763ffffffff1660e01b8152600401613b8c96959493929190615351565b60408051808303816000875af1158015613baa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bce91906153cd565b9092509050613bdd8185614d61565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100890151600d805469ffffffffffffffffffff90921693909291613c4b91859116614d61565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508160ff166007811115613c8e57613c8e614bc2565b9d9c50505050505050505050505050565b508054613cab906146de565b6000825580601f10613cbb575050565b601f01602090049060005260206000209081019061066a9190613cf8565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613d0d5760008155600101613cf9565b5090565b60008083601f840112613d2357600080fd5b50813567ffffffffffffffff811115613d3b57600080fd5b602083019150836020828501011115613d5357600080fd5b9250929050565b60008060208385031215613d6d57600080fd5b823567ffffffffffffffff811115613d8457600080fd5b613d9085828601613d11565b90969095509350505050565b6000815180845260005b81811015613dc257602081850181015186830182015201613da6565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611d6b6020830184613d9c565b73ffffffffffffffffffffffffffffffffffffffff8116811461066a57600080fd5b600060208284031215613e4757600080fd5b8135611d6b81613e13565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715613ea557613ea5613e52565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613ef257613ef2613e52565b604052919050565b600082601f830112613f0b57600080fd5b813567ffffffffffffffff811115613f2557613f25613e52565b613f5660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613eab565b818152846020838601011115613f6b57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461066a57600080fd5b8035610efd81613f88565b63ffffffff8116811461066a57600080fd5b60008082840360a0811215613fcf57600080fd5b833567ffffffffffffffff80821115613fe757600080fd5b613ff387838801613efa565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561402557600080fd5b6040519250608083019150828210818311171561404457614044613e52565b50604052602084013561405681613f88565b8152604084013561406681613e13565b6020820152606084013561407981613fa9565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156140d757815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140a5565b509495945050505050565b6040815260006140f56040830185614091565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614163577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614151838351613d9c565b94860194925090850190600101614117565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461066a57600080fd5b6000806040838503121561419f57600080fd5b82356141aa81613e13565b915060208301356141ba81614172565b809150509250929050565b6000806000604084860312156141da57600080fd5b83356141e581613e13565b9250602084013567ffffffffffffffff81111561420157600080fd5b61420d86828701613d11565b9497909650939450505050565b602081526000611d6b6020830184614091565b60006020828403121561423f57600080fd5b5035919050565b60006020828403121561425857600080fd5b813567ffffffffffffffff81111561426f57600080fd5b61427b84828501613efa565b949350505050565b60006020828403121561429557600080fd5b813567ffffffffffffffff8111156142ac57600080fd5b820160e08185031215611d6b57600080fd5b80516bffffffffffffffffffffffff16825260208101516142f7602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604081015161431f604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606081015161433b606084018267ffffffffffffffff169052565b506080810151614353608084018263ffffffff169052565b5060a081015161437360a08401826bffffffffffffffffffffffff169052565b5060c081015161438c60c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143b58285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610cdc565b610160810161069582846142be565b60008083601f84011261440557600080fd5b50813567ffffffffffffffff81111561441d57600080fd5b6020830191508360208260051b8501011115613d5357600080fd5b60008060008060008060008060e0898b03121561445457600080fd5b606089018a81111561446557600080fd5b8998503567ffffffffffffffff8082111561447f57600080fd5b61448b8c838d01613d11565b909950975060808b01359150808211156144a457600080fd5b6144b08c838d016143f3565b909750955060a08b01359150808211156144c957600080fd5b506144d68b828c016143f3565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561450757600080fd5b853561451281613f88565b9450602086013567ffffffffffffffff81111561452e57600080fd5b61453a88828901613d11565b909550935050604086013561454e81613fa9565b949793965091946060013592915050565b600067ffffffffffffffff82111561457957614579613e52565b5060051b60200190565b600082601f83011261459457600080fd5b813560206145a96145a48361455f565b613eab565b82815260059290921b840181019181810190868411156145c857600080fd5b8286015b848110156145ec5780356145df81613e13565b83529183019183016145cc565b509695505050505050565b60ff8116811461066a57600080fd5b8035610efd816145f7565b60008060008060008060c0878903121561462a57600080fd5b863567ffffffffffffffff8082111561464257600080fd5b61464e8a838b01614583565b9750602089013591508082111561466457600080fd5b6146708a838b01614583565b965061467e60408a01614606565b9550606089013591508082111561469457600080fd5b6146a08a838b01613efa565b94506146ae60808a01613f9e565b935060a08901359150808211156146c457600080fd5b506146d189828a01613efa565b9150509295509295509295565b600181811c908216806146f257607f821691505b60208210810361472b577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105c657600081815260208120601f850160051c810160208610156147585750805b601f850160051c820191505b8181101561477757828155600101614764565b505050505050565b67ffffffffffffffff83111561479757614797613e52565b6147ab836147a583546146de565b83614731565b6000601f8411600181146147fd57600085156147c75750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614893565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561484c578685013582556020948501946001909201910161482c565b5086821015614887577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614929576149296148c9565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614955576149556148c9565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261499157600080fd5b83018035915067ffffffffffffffff8211156149ac57600080fd5b602001915036819003821315613d5357600080fd5b6000602082840312156149d357600080fd5b8135611d6b81613f88565b6000602082840312156149f057600080fd5b8135611d6b81613fa9565b61ffff8116811461066a57600080fd5b600060208284031215614a1d57600080fd5b8135611d6b816149fb565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614ac560c085018763ffffffff169052565b818482030160e0850152613c8e82820186613d9c565b805169ffffffffffffffffffff81168114610efd57600080fd5b600080600080600060a08688031215614b0d57600080fd5b614b1686614adb565b9450602086015193506040860151925060608601519150614b3960808701614adb565b90509295509295909350565b81810381811115610695576106956148c9565b60ff8181168382160190811115610695576106956148c9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614bb357614bb3614b71565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b8051610efd81614172565b600060208284031215614c3257600080fd5b8151611d6b81614172565b8082028115828204841417610695576106956148c9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614955576149556148c9565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cd08184018a614091565b90508281036080840152614ce48189614091565b905060ff871660a084015282810360c0840152614d018187613d9c565b905067ffffffffffffffff851660e0840152828103610100840152614d268185613d9c565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614d5557614d55614b71565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614955576149556148c9565b6bffffffffffffffffffffffff818116838216028082169190828114614dae57614dae6148c9565b505092915050565b8051610efd81613fa9565b60008060008060008060008060006101208a8c031215614de057600080fd5b8951614deb81613fa9565b60208b0151909950614dfc81613fa9565b60408b0151909850614e0d81613fa9565b60608b0151909750614e1e81613fa9565b60808b0151909650614e2f81613fa9565b9450614e3d60a08b01614adb565b935060c08a0151614e4d816149fb565b8093505060e08a015191506101008a015190509295985092959850929598565b8051610efd81613e13565b600080600080600060a08688031215614e9057600080fd5b8551614e9b81614172565b80955050602080870151614eae81614172565b6040880151909550614ebf81613e13565b6060880151909450614ed081613e13565b608088015190935067ffffffffffffffff811115614eed57600080fd5b8701601f81018913614efe57600080fd5b8051614f0c6145a48261455f565b81815260059190911b8201830190838101908b831115614f2b57600080fd5b928401925b82841015614f52578351614f4381613e13565b82529284019290840190614f30565b80955050505050509295509295909350565b8051610efd81613f88565b600080600060608486031215614f8457600080fd5b83518015158114614f9457600080fd5b6020850151909350614fa581613f88565b6040850151909250614fb681613f88565b809150509250925092565b67ffffffffffffffff818116838216019080821115614955576149556148c9565b80820180821115610695576106956148c9565b600082601f83011261500657600080fd5b813560206150166145a48361455f565b82815260059290921b8401810191818101908684111561503557600080fd5b8286015b848110156145ec5780358352918301918301615039565b600082601f83011261506157600080fd5b813560206150716145a48361455f565b82815260059290921b8401810191818101908684111561509057600080fd5b8286015b848110156145ec57803567ffffffffffffffff8111156150b45760008081fd5b6150c28986838b0101613efa565b845250918301918301615094565b600080600080600060a086880312156150e857600080fd5b853567ffffffffffffffff8082111561510057600080fd5b61510c89838a01614ff5565b9650602088013591508082111561512257600080fd5b61512e89838a01615050565b9550604088013591508082111561514457600080fd5b61515089838a01615050565b9450606088013591508082111561516657600080fd5b61517289838a01615050565b9350608088013591508082111561518857600080fd5b5061519588828901615050565b9150509295509295909350565b6000826151b1576151b1614b71565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151fd8285018b614091565b91508382036080850152615211828a614091565b915060ff881660a085015283820360c085015261522e8288613d9c565b90861660e08501528381036101008501529050614d268185613d9c565b805164ffffffffff81168114610efd57600080fd5b6000610160828403121561527357600080fd5b61527b613e81565b61528483614c15565b815261529260208401614e6d565b60208201526152a360408401614e6d565b60408201526152b460608401614f64565b60608201526152c560808401614db6565b60808201526152d660a08401614c15565b60a08201526152e760c0840161524b565b60c082015260e083015160e0820152610100615304818501614adb565b9082015261012061531684820161524b565b9082015261014061532884820161524b565b908201529392505050565b64ffffffffff818116838216019080821115614955576149556148c9565b60006102008083526153658184018a613d9c565b905082810360208401526153798189613d9c565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153c2905060a08301846142be565b979650505050505050565b600080604083850312156153e057600080fd5b82516153eb816145f7565b60208401519092506141ba8161417256fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -688,266 +689,6 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) UpdateConfig return _FunctionsCoordinator.Contract.UpdateConfig(&_FunctionsCoordinator.TransactOpts, config) } -type FunctionsCoordinatorBillingEndIterator struct { - Event *FunctionsCoordinatorBillingEnd - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorBillingEndIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorBillingEnd) - 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(FunctionsCoordinatorBillingEnd) - 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 *FunctionsCoordinatorBillingEndIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorBillingEndIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorBillingEnd struct { - RequestId [32]byte - SubscriptionId uint64 - SignerPayment *big.Int - TransmitterPayment *big.Int - TotalCost *big.Int - Result uint8 - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingEndIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "BillingEnd", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorBillingEndIterator{contract: _FunctionsCoordinator.contract, event: "BillingEnd", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingEnd, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "BillingEnd", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorBillingEnd) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingEnd", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseBillingEnd(log types.Log) (*FunctionsCoordinatorBillingEnd, error) { - event := new(FunctionsCoordinatorBillingEnd) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingEnd", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorBillingStartIterator struct { - Event *FunctionsCoordinatorBillingStart - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorBillingStartIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorBillingStart) - 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(FunctionsCoordinatorBillingStart) - 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 *FunctionsCoordinatorBillingStartIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorBillingStartIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorBillingStart struct { - RequestId [32]byte - Commitment FunctionsBillingCommitment - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterBillingStart(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingStartIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "BillingStart", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorBillingStartIterator{contract: _FunctionsCoordinator.contract, event: "BillingStart", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchBillingStart(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingStart, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "BillingStart", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorBillingStart) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingStart", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseBillingStart(log types.Log) (*FunctionsCoordinatorBillingStart, error) { - event := new(FunctionsCoordinatorBillingStart) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingStart", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - type FunctionsCoordinatorCommitmentDeletedIterator struct { Event *FunctionsCoordinatorCommitmentDeleted @@ -1893,6 +1634,7 @@ type FunctionsCoordinatorOracleRequest struct { DataVersion uint16 Flags [32]byte CallbackGasLimit uint64 + Commitment []byte Raw types.Log } @@ -2509,10 +2251,6 @@ type LatestConfigDigestAndEpoch struct { func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { - case _FunctionsCoordinator.abi.Events["BillingEnd"].ID: - return _FunctionsCoordinator.ParseBillingEnd(log) - case _FunctionsCoordinator.abi.Events["BillingStart"].ID: - return _FunctionsCoordinator.ParseBillingStart(log) case _FunctionsCoordinator.abi.Events["CommitmentDeleted"].ID: return _FunctionsCoordinator.ParseCommitmentDeleted(log) case _FunctionsCoordinator.abi.Events["ConfigChanged"].ID: @@ -2543,14 +2281,6 @@ func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (gene } } -func (FunctionsCoordinatorBillingEnd) Topic() common.Hash { - return common.HexToHash("0x30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff03535") -} - -func (FunctionsCoordinatorBillingStart) Topic() common.Hash { - return common.HexToHash("0xe2cc993cebc49ce369b0174671d90dbae2201decdae368805de999b437336dcd") -} - func (FunctionsCoordinatorCommitmentDeleted) Topic() common.Hash { return common.HexToHash("0x8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416") } @@ -2580,7 +2310,7 @@ func (FunctionsCoordinatorInvalidRequestID) Topic() common.Hash { } func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { - return common.HexToHash("0xd6bf2929a5458fc22a90821275e4f54e2566c579e4bb3d38184880bf1701762c") + return common.HexToHash("0xd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3") } func (FunctionsCoordinatorOracleResponse) Topic() common.Hash { @@ -2662,18 +2392,6 @@ type FunctionsCoordinatorInterface interface { UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) - FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingEndIterator, error) - - WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingEnd, requestId [][32]byte) (event.Subscription, error) - - ParseBillingEnd(log types.Log) (*FunctionsCoordinatorBillingEnd, error) - - FilterBillingStart(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingStartIterator, error) - - WatchBillingStart(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingStart, requestId [][32]byte) (event.Subscription, error) - - ParseBillingStart(log types.Log) (*FunctionsCoordinatorBillingStart, error) - FilterCommitmentDeleted(opts *bind.FilterOpts) (*FunctionsCoordinatorCommitmentDeletedIterator, error) WatchCommitmentDeleted(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCommitmentDeleted) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 137f4d8c830..e20f82317d0 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -30,9 +30,23 @@ var ( _ = abi.ConvertType ) +type IFunctionsRequestCommitment struct { + AdminFee *big.Int + Coordinator common.Address + Client common.Address + SubscriptionId uint64 + CallbackGasLimit uint32 + EstimatedTotalCostJuels *big.Int + TimeoutTimestamp *big.Int + RequestId [32]byte + DonFee *big.Int + GasOverheadBeforeCallback *big.Int + GasOverheadAfterCallback *big.Int +} + var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620062b9380380620062b9833981016040819052620000349162000431565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006ab9350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200024491906200052e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002bc916010919086019062000303565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051620002f5939291906200063a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003a75791602002820160005b838211156200037357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200032d565b8015620003a55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000373565b505b50620003b5929150620003b9565b5090565b5b80821115620003b55760008155600101620003ba565b805161ffff81168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004295762000429620003e8565b604052919050565b600080600080608085870312156200044857600080fd5b6200045385620003d0565b9350602062000464818701620003d0565b60408701519094506001600160a01b03811681146200048257600080fd5b60608701519093506001600160401b0380821115620004a057600080fd5b818801915088601f830112620004b557600080fd5b815181811115620004ca57620004ca620003e8565b620004de601f8201601f19168501620003fe565b91508082528984828501011115620004f557600080fd5b60005b8181101562000515578381018501518382018601528401620004f8565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200054457600080fd5b83516001600160601b03811681146200055c57600080fd5b602085810151919450906001600160e01b0319811681146200057d57600080fd5b60408601519093506001600160401b03808211156200059b57600080fd5b818701915087601f830112620005b057600080fd5b815181811115620005c557620005c5620003e8565b8060051b9150620005d8848301620003fe565b818152918301840191848101908a841115620005f357600080fd5b938501935b838510156200062a578451925063ffffffff83168314620006195760008081fd5b8282529385019390850190620005f8565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b818110156200069d57845163ffffffff168352938301939183019160010162000679565b509098975050505050505050565b608051615bf2620006c7600039600061292f0152615bf26000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c80637341c10c1161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610766578063eb523d6c14610779578063f2fde38b1461078c57600080fd5b8063c4614d611461072d578063d7ae1d3014610740578063e72f6e301461075357600080fd5b8063b5643858116100c8578063b5643858146106fb578063b734c0f41461070e578063badc3eb61461071657600080fd5b8063a9c9a918146106b7578063aab396bd146106ca578063b187bd26146106f057600080fd5b80638fde531711610150578063a21a23e41161012a578063a21a23e414610678578063a47c769614610680578063a4c0ed36146106a457600080fd5b80638fde5317146106555780639883c10d1461065d5780639f87fad71461066557600080fd5b8063823597401161018157806382359740146106175780638456cb591461062a5780638da5cb5b1461063257600080fd5b80637341c10c146105fc57806379ba50971461060f57600080fd5b8063461d27621161025557806366316d8d11610209578063674603d0116101e3578063674603d0146105285780636a6df79b146105bd57806371ec28ac146105f557600080fd5b806366316d8d146104d457806366419970146104e7578063665871ec1461051557600080fd5b806355fedefa1161023a57806355fedefa146104975780635c975abb146104aa5780635ed6dfba146104c157600080fd5b8063461d2762146104635780634b8832d31461048457600080fd5b80631ded3b36116102b75780633e871e4d116102915780633e871e4d1461040f5780633f4ba83a146104225780633fd67e051461042a57600080fd5b80631ded3b36146103d35780632a905ccc146103e6578063385de9ae146103fc57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038a57600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614b5f565b61079f565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b610317610347366004614b8c565b61082c565b6009546b01000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610330565b6103c66040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614c27565b6103176103e1366004614c3a565b610836565b600f546bffffffffffffffffffffffff1661036d565b61031761040a366004614cad565b610867565b61031761041d366004614e31565b610a45565b610317610d40565b61043d610438366004614f92565b610d52565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610330565b610476610471366004615046565b6110db565b604051908152602001610330565b6103176104923660046150c8565b61112f565b6104766104a5366004614b5f565b61122c565b60005460ff165b6040519015158152602001610330565b6103176104cf3660046150fb565b611250565b6103176104e23660046150fb565b611526565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b610317610523366004615127565b61174d565b61059561053636600461519c565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b6105d06105cb3660046151d4565b611b36565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6064610321565b61031761060a3660046150c8565b611b49565b610317611cf6565b610317610625366004614b5f565b611e18565b610317611f67565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105d0565b610317611f77565b600754610476565b6103176106733660046150c8565b61201f565b6104fc612427565b61069361068e366004614b5f565b6125bb565b60405161033095949392919061524a565b6103176106b236600461529f565b6126a7565b6105d06106c53660046152f9565b6128d6565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610476565b60005460ff166104b1565b610317610709366004615312565b6128e3565b610317612a44565b61071e612bb2565b6040516103309392919061532d565b6103c661073b366004614cad565b612c8d565b61031761074e3660046150c8565b612ca2565b61031761076136600461538e565b612cfb565b6104b1610774366004614b5f565b612f07565b6103176107873660046152f9565b612f12565b61031761079a36600461538e565b613130565b6107a7613141565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061081e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108288282613149565b5050565b61082882826134b7565b61083e613141565b610847826135d7565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61086f61364d565b600061087c8460006136d3565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036108a6575060075461091a565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156108f3573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061091791906153a9565b90505b838360405161092a9291906153c2565b6040518091039020810361096a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152505050908252506009546020909101906109cb9061ffff1643615401565b90526000868152600660209081526040909120825181559082015160018201906109f590826154b5565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610a369087908490889088906155cf565b60405180910390a15050505050565b610a4d61364d565b8151815181141580610a5f5750600881115b15610a96576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610bc7576000848281518110610ab557610ab561562a565b602002602001015190506000848381518110610ad357610ad361562a565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610b3e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610b75576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610bb4576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b505080610bc090615659565b9050610a99565b50600954600090610bdc9061ffff1643615401565b604080516060810182528681526020808201879052918101839052865192935091600391610c0e9183918901906149a8565b506020828101518051610c2792600185019201906149ef565b506040820151816002015590505060005b8451811015610d39577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610c7457610c7461562a565b602002602001015160026000888581518110610c9257610c9261562a565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610cdb57610cdb61562a565b602002602001015185604051610d21949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610d3281615659565b9050610c38565b5050505050565b610d4861364d565b610d506137ca565b565b600080610d5d613847565b6000888152600e602090815260409182902082516101008101845281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff90811695840186905260018501549081169684019690965274010000000000000000000000000000000000000000860467ffffffffffffffff1660608401527c010000000000000000000000000000000000000000000000000000000090950463ffffffff16608083015260029092015493841660a082015290830464ffffffffff1660c0820152710100000000000000000000000000000000009092046effffffffffffffffffffffffffffff1660e08301523314610e9f576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604081015173ffffffffffffffffffffffffffffffffffffffff16610ec85760029250506110d0565b8060e00151816080015163ffffffff16610ee29190615691565b6effffffffffffffffffffffffffffff165a1015610f045760039250506110d0565b606081015167ffffffffffffffff166000908152600b602052604090205460808201516bffffffffffffffffffffffff90911690610f479063ffffffff1661384f565b610f5190886156c0565b8251610f5e9088906156f0565b610f6891906156f0565b6bffffffffffffffffffffffff161115610f865760049250506110d0565b8060a001516bffffffffffffffffffffffff16610fac826080015163ffffffff1661384f565b610fb690886156c0565b8251610fc39088906156f0565b610fcd91906156f0565b6bffffffffffffffffffffffff161115610feb5760059250506110d0565b6000898152600e6020526040808220828155600181018390556002018290556080830151908301519194508491611027918c918c918c916138f1565b805190915061103757600161103a565b60005b9350600061106183606001518460a00151856040015186600001518c87602001518d613a6b565b9050826060015167ffffffffffffffff168b7f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a8360200151898987600001516110aa578e6110ac565b8f5b88604001516040516110c2959493929190615715565b60405180910390a351925050505b965096945050505050565b60006111248260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a9150613cbd9050565b979650505050505050565b611137613847565b6111408261411e565b6111486141e4565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108285767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b611258613141565b806bffffffffffffffffffffffff1660000361128e5750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff808316911610156112e8576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906113159084906bffffffffffffffffffffffff16615773565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff1661136c9190615773565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561140b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061142f9190615798565b61082857600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa1580156114a2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114c691906153a9565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610bab565b61152e613847565b806bffffffffffffffffffffffff16600003611576576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff808316911610156115d0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906115fd9084906bffffffffffffffffffffffff16615773565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166116549190615773565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156116f3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117179190615798565b610828576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611755613847565b60005b81811015611b315760008383838181106117745761177461562a565b602090810292909201356000818152600e845260409081902081516101008101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009182900473ffffffffffffffffffffffffffffffffffffffff9081169884019890985260018401549788169483019490945274010000000000000000000000000000000000000000870467ffffffffffffffff16606083018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16608083015260029092015492831660a082015290820464ffffffffff1660c0820152710100000000000000000000000000000000009091046effffffffffffffffffffffffffffff1660e0820152909350919050611897816135d7565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16338114611910576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611955576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810186905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af11580156119c7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906119eb9190615798565b5060a084015167ffffffffffffffff84166000908152600b602052604081206001018054909190611a2b9084906bffffffffffffffffffffffff16615773565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408085015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff808816845291529190208054600192600991611ab291859169010000000000000000009004166157b5565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000858152600e6020526040808220828155600181018390556002018290555186917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050505080611b2a90615659565b9050611758565b505050565b6000611b4283836136d3565b9392505050565b611b51613847565b611b5a8261411e565b611b626141e4565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611bd7576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611c1e575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611220565b60015473ffffffffffffffffffffffffffffffffffffffff163314611d77576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610bab565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611e20613847565b611e286141e4565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611ec8576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610bab565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611f6f61364d565b610d506142eb565b611f7f61364d565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611fe1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b612027613847565b6120308261411e565b6120386141e4565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152612108576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610bab565b806040015167ffffffffffffffff16816020015167ffffffffffffffff161461215d576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b60209081526040808320600201805482518185028101850190935280835291929091908301828280156121d857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116121ad575b505050505090506000600182516121ef91906157d6565b905060005b825181101561238b578473ffffffffffffffffffffffffffffffffffffffff168382815181106122265761222661562a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff160361237b57600083838151811061225d5761225d61562a565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106122a3576122a361562a565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b9091526040902060020180548061231d5761231d6157e9565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061238b565b61238481615659565b90506121f4565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000612431613847565b6124396141e4565b6009805460039061245a906301000000900467ffffffffffffffff16615818565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156124d0578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261256b926002850192909101906149ef565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b60008060008060606125cc866135d7565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561269757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161266c575b5050505050905091939590929450565b6126af613847565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612700576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461273a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061274882840184614b5f565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166127c1576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906127f883856156f0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff1661284f91906156f0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128b69190615401565b6040805192835260208301919091520160405180910390a2505050505050565b600061124a8260006136d3565b6128eb61364d565b60095461ffff80831691160361292d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff16111561298f576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff908116808352908416602083015290918201906129bc9043615401565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a4c61364d565b600554431015612a88576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612baf57600060036000018281548110612aad57612aad61562a565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612af957612af961562a565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612ba890615659565b9050612a8b565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612c1257602002820191906000526020600020905b815481526020019060010190808311612bfe575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612c7b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612c50575b50505050509050925092509250909192565b6060612c9a848484614346565b949350505050565b612caa613847565b612cb38261411e565b612cbb6141e4565b612cc482614413565b1561081e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d03613141565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612d72573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d9691906153a9565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612dfd576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610bab565b81811015611b31576000612e1182846157d6565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612e8c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612eb09190615798565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b600061124a82614413565b612f1a61364d565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612f5490615414565b80601f0160208091040260200160405190810160405280929190818152602001828054612f8090615414565b8015612fcd5780601f10612fa257610100808354040283529160200191612fcd565b820191906000526020600020905b815481529060010190602001808311612fb057829003601f168201915b5050505050815260200160028201548152505090508060400151431015613020576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613045576130328160200151614562565b60208082015180519101206007556130ed565b6130508260006136d3565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b815260040161308c9190614c27565b600060405180830381600087803b1580156130a657600080fd5b505af19250505080156130b7575060015b6130ed576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261312492869261583f565b60405180910390a15050565b61313861364d565b612baf8161465d565b610d5061364d565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561322a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116131ff575b505050918352505060039190910154602090910152805190915060005b8260800151518110156132eb57600c60008460800151838151811061326e5761326e61562a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556132e481615659565b9050613247565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061331d6002830182614a69565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff166133509190615773565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156133ef573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134139190615798565b613449576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110613517576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff82166004820152602401610bab565b6010805460ff831690811061352e5761352e61562a565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115611b31576010805460ff831690811061357e5761357e61562a565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610bab565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612baf576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610d50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bab565b6000816137125760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff16801561370c57905061124a565b50613795565b60005b6003548110156137935760038054829081106137335761373361562a565b906000526020600020015484036137835760048054829081106137585761375861562a565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16915061124a9050565b61378c81615659565b9050613715565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610bab565b6137d2614758565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b610d506147c4565b60006bffffffffffffffffffffffff8211156138ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610bab565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b9061393c90899089908990602401615867565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b6139ee57600080fd5b5a6113888110156139fe57600080fd5b611388810390508760408204820311613a1657600080fd5b60008086516020880160008b8df193505a900391503d6084811115613a39575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613a8a8461384f565b613a9490866156c0565b9050600081613aa388866156f0565b613aad91906156f0565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613b0491859116615773565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613b3e91906156f0565b336000908152600d602052604081208054909190613b6b9084906bffffffffffffffffffffffff166156f0565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613bb2918591166156f0565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613c0691859116615773565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613c8a91859169010000000000000000009004166157b5565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6000613cc7613847565b613cd0856135d7565b613cda3386614831565b613ce485836134b7565b6000613cf088886136d3565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c50000000000000000000000000000000000000000000000000000000081529394509192839283929086169163aecc12c591613dbb9160040161589c565b6080604051808303816000875af1158015613dda573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613dfe919061592f565b92975090945092509050613e13338a856148cd565b6040805161010081018252600f546bffffffffffffffffffffffff908116825273ffffffffffffffffffffffffffffffffffffffff87166020830152339282019290925267ffffffffffffffff8b16606082015263ffffffff8816608082015290841660a082015260c08101613e898342615401565b64ffffffffff168152602001836effffffffffffffffffffffffffffff16815250600e600087815260200190815260200160002060008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060608201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550608082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060c082015181600201600c6101000a81548164ffffffffff021916908364ffffffffff16021790555060e08201518160020160116101000a8154816effffffffffffffffffffffffffffff02191690836effffffffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600b60008e67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e6040516141089695949392919061596d565b60405180910390a4505050509695505050505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680614195576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610828576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61420f7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006136d3565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890614272903390602481016159d1565b602060405180830381865afa15801561428f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142b39190615798565b610d50576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610bab565b6142f36147c4565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a25861381d3390565b6060600080808061435986880188615a00565b9350935093509350600061437289600187878787613cbd565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614406578181602081106143b1576143b161562a565b1a60f81b8782815181106143c7576143c761562a565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053506143ff81615659565b9050614396565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561448b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614460575b5050505050905060005b8151811015614558576000600c60008484815181106144b6576144b661562a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461454757506001949350505050565b5061455181615659565b9050614495565b5060009392505050565b60008060008380602001905181019061457b9190615a71565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c02178155835195985093965091945090926146269160109190860190614a87565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612ef993929190615b5a565b3373ffffffffffffffffffffffffffffffffffffffff8216036146dc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bab565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610d50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610bab565b60005460ff1615610d50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610bab565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610828576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610bab565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906149079084906bffffffffffffffffffffffff166156f0565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261497d9284929004166157b5565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b8280548282559060005260206000209081019282156149e3579160200282015b828111156149e35782518255916020019190600101906149c8565b506138ed929150614b2d565b8280548282559060005260206000209081019282156149e3579160200282015b828111156149e357825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614a0f565b5080546000825590600052602060002090810190612baf9190614b2d565b828054828255906000526020600020906007016008900481019282156149e35791602002820160005b83821115614af457835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614ab0565b8015614b245782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614af4565b50506138ed9291505b5b808211156138ed5760008155600101614b2e565b803567ffffffffffffffff81168114614b5a57600080fd5b919050565b600060208284031215614b7157600080fd5b611b4282614b42565b63ffffffff81168114612baf57600080fd5b60008060408385031215614b9f57600080fd5b614ba883614b42565b91506020830135614bb881614b7a565b809150509250929050565b6000815180845260005b81811015614be957602081850181015186830182015201614bcd565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611b426020830184614bc3565b60008060408385031215614c4d57600080fd5b614c5683614b42565b946020939093013593505050565b60008083601f840112614c7657600080fd5b50813567ffffffffffffffff811115614c8e57600080fd5b602083019150836020828501011115614ca657600080fd5b9250929050565b600080600060408486031215614cc257600080fd5b83359250602084013567ffffffffffffffff811115614ce057600080fd5b614cec86828701614c64565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d6f57614d6f614cf9565b604052919050565b600067ffffffffffffffff821115614d9157614d91614cf9565b5060051b60200190565b803573ffffffffffffffffffffffffffffffffffffffff81168114614b5a57600080fd5b600082601f830112614dd057600080fd5b81356020614de5614de083614d77565b614d28565b82815260059290921b84018101918181019086841115614e0457600080fd5b8286015b84811015614e2657614e1981614d9b565b8352918301918301614e08565b509695505050505050565b60008060408385031215614e4457600080fd5b823567ffffffffffffffff80821115614e5c57600080fd5b818501915085601f830112614e7057600080fd5b81356020614e80614de083614d77565b82815260059290921b84018101918181019089841115614e9f57600080fd5b948201945b83861015614ebd57853582529482019490820190614ea4565b96505086013592505080821115614ed357600080fd5b50614ee085828601614dbf565b9150509250929050565b600082601f830112614efb57600080fd5b813567ffffffffffffffff811115614f1557614f15614cf9565b614f4660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614d28565b818152846020838601011115614f5b57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff81168114612baf57600080fd5b60008060008060008060c08789031215614fab57600080fd5b86359550602087013567ffffffffffffffff80821115614fca57600080fd5b614fd68a838b01614eea565b96506040890135915080821115614fec57600080fd5b50614ff989828a01614eea565b945050606087013561500a81614f78565b9250608087013561501a81614f78565b915061502860a08801614d9b565b90509295509295509295565b803561ffff81168114614b5a57600080fd5b60008060008060008060a0878903121561505f57600080fd5b61506887614b42565b9550602087013567ffffffffffffffff81111561508457600080fd5b61509089828a01614c64565b90965094506150a3905060408801615034565b925060608701356150b381614b7a565b80925050608087013590509295509295509295565b600080604083850312156150db57600080fd5b6150e483614b42565b91506150f260208401614d9b565b90509250929050565b6000806040838503121561510e57600080fd5b61511783614d9b565b91506020830135614bb881614f78565b6000806020838503121561513a57600080fd5b823567ffffffffffffffff8082111561515257600080fd5b818501915085601f83011261516657600080fd5b81358181111561517557600080fd5b8660208260051b850101111561518a57600080fd5b60209290920196919550909350505050565b600080604083850312156151af57600080fd5b6151b883614d9b565b91506150f260208401614b42565b8015158114612baf57600080fd5b600080604083850312156151e757600080fd5b823591506020830135614bb8816151c6565b600081518084526020808501945080840160005b8381101561523f57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161520d565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090611124908301846151f9565b600080600080606085870312156152b557600080fd5b6152be85614d9b565b935060208501359250604085013567ffffffffffffffff8111156152e157600080fd5b6152ed87828801614c64565b95989497509550505050565b60006020828403121561530b57600080fd5b5035919050565b60006020828403121561532457600080fd5b611b4282615034565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561536e57845183529383019391830191600101615352565b5050848103604086015261538281876151f9565b98975050505050505050565b6000602082840312156153a057600080fd5b611b4282614d9b565b6000602082840312156153bb57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561124a5761124a6153d2565b600181811c9082168061542857607f821691505b602082108103615461577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f821115611b3157600081815260208120601f850160051c8101602086101561548e5750805b601f850160051c820191505b818110156154ad5782815560010161549a565b505050505050565b815167ffffffffffffffff8111156154cf576154cf614cf9565b6154e3816154dd8454615414565b84615467565b602080601f83116001811461553657600084156155005750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556154ad565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561558357888601518255948401946001909101908401615564565b50858210156155bf57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361568a5761568a6153d2565b5060010190565b6effffffffffffffffffffffffffffff8181168382160190808211156156b9576156b96153d2565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146156e8576156e86153d2565b505092915050565b6bffffffffffffffffffffffff8181168382160190808211156156b9576156b96153d2565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a06060820152600061576160a0830185614bc3565b82810360808401526153828185614bc3565b6bffffffffffffffffffffffff8281168282160390808211156156b9576156b96153d2565b6000602082840312156157aa57600080fd5b8151611b42816151c6565b67ffffffffffffffff8181168382160190808211156156b9576156b96153d2565b8181038181111561124a5761124a6153d2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff808316818103615835576158356153d2565b6001019392505050565b83815282602082015260606040820152600061585e6060830184614bc3565b95945050505050565b8381526060602082015260006158806060830185614bc3565b82810360408401526158928185614bc3565b9695505050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e060608401526158e7610100840182614bc3565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b6000806000806080858703121561594557600080fd5b84519350602085015161595781614f78565b6040860151606090960151949790965092505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c060608301526159ae60c0830186614bc3565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612c9a6040830184614bc3565b60008060008060808587031215615a1657600080fd5b615a1f85614b42565b9350602085013567ffffffffffffffff811115615a3b57600080fd5b615a4787828801614eea565b935050615a5660408601615034565b91506060850135615a6681614b7a565b939692955090935050565b600080600060608486031215615a8657600080fd5b8351615a9181614f78565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615ac957600080fd5b604086015190935067ffffffffffffffff811115615ae657600080fd5b8501601f81018713615af757600080fd5b8051615b05614de082614d77565b81815260059190911b82018301908381019089831115615b2457600080fd5b928401925b82841015615b4b578351615b3c81614b7a565b82529284019290840190615b29565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615bd757845163ffffffff1683529383019391830191600101615bb5565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200636f3803806200636f833981016040819052620000349162000431565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006ab9350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200024491906200052e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002bc916010919086019062000303565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051620002f5939291906200063a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003a75791602002820160005b838211156200037357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200032d565b8015620003a55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000373565b505b50620003b5929150620003b9565b5090565b5b80821115620003b55760008155600101620003ba565b805161ffff81168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004295762000429620003e8565b604052919050565b600080600080608085870312156200044857600080fd5b6200045385620003d0565b9350602062000464818701620003d0565b60408701519094506001600160a01b03811681146200048257600080fd5b60608701519093506001600160401b0380821115620004a057600080fd5b818801915088601f830112620004b557600080fd5b815181811115620004ca57620004ca620003e8565b620004de601f8201601f19168501620003fe565b91508082528984828501011115620004f557600080fd5b60005b8181101562000515578381018501518382018601528401620004f8565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200054457600080fd5b83516001600160601b03811681146200055c57600080fd5b602085810151919450906001600160e01b0319811681146200057d57600080fd5b60408601519093506001600160401b03808211156200059b57600080fd5b818701915087601f830112620005b057600080fd5b815181811115620005c557620005c5620003e8565b8060051b9150620005d8848301620003fe565b818152918301840191848101908a841115620005f357600080fd5b938501935b838510156200062a578451925063ffffffff83168314620006195760008081fd5b8282529385019390850190620005f8565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b818110156200069d57845163ffffffff168352938301939183019160010162000679565b509098975050505050505050565b608051615ca8620006c760003960006128980152615ca86000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610766578063eb523d6c14610779578063f2fde38b1461078c57600080fd5b8063c4614d611461072d578063d7ae1d3014610740578063e72f6e301461075357600080fd5b8063b5643858116100c8578063b5643858146106fb578063b734c0f41461070e578063badc3eb61461071657600080fd5b8063a9c9a918146106b7578063aab396bd146106ca578063b187bd26146106f057600080fd5b80639883c10d11610150578063a21a23e41161012a578063a21a23e414610678578063a47c769614610680578063a4c0ed36146106a457600080fd5b80639883c10d146106245780639f87fad71461062c578063a1d4c8281461063f57600080fd5b80638456cb59116101815780638456cb59146105f15780638da5cb5b146105f95780638fde53171461061c57600080fd5b806379ba5097146105d657806382359740146105de57600080fd5b80634b8832d31161025557806366419970116102095780636e3b3323116101e35780636e3b3323146105a957806371ec28ac146105bc5780637341c10c146105c357600080fd5b806366419970146104ae578063674603d0146104dc5780636a6df79b1461057157600080fd5b80635c975abb1161023a5780635c975abb146104715780635ed6dfba1461048857806366316d8d1461049b57600080fd5b80634b8832d31461044b57806355fedefa1461045e57600080fd5b80631ded3b36116102b75780633e871e4d116102915780633e871e4d1461040f5780633f4ba83a14610422578063461d27621461042a57600080fd5b80631ded3b36146103d35780632a905ccc146103e6578063385de9ae146103fc57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038a57600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614889565b61079f565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b6103176103473660046148c3565b61082c565b6009546b01000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610330565b6103c66040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614960565b6103176103e1366004614973565b610956565b600f546bffffffffffffffffffffffff1661036d565b61031761040a3660046149e8565b610987565b61031761041d366004614ba1565b610b65565b610317610e5b565b61043d610438366004614c6c565b610e6d565b604051908152602001610330565b610317610459366004614cf0565b610ec1565b61043d61046c366004614889565b610fbe565b60005460ff165b6040519015158152602001610330565b610317610496366004614d43565b610fe2565b6103176104a9366004614d43565b6112b8565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b6105496104ea366004614d71565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b61058461057f366004614dad565b6114df565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105b7366004614dd2565b6114f2565b6064610321565b6103176105d1366004614cf0565b6117c8565b610317611975565b6103176105ec366004614889565b611a97565b610317611be6565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610584565b610317611bf6565b60075461043d565b61031761063a366004614cf0565b611c9e565b61065261064d366004614feb565b6120a6565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610330565b6104c3612390565b61069361068e366004614889565b612524565b6040516103309594939291906150e9565b6103176106b236600461513e565b612610565b6105846106c536600461519a565b61283f565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761043d565b60005460ff16610478565b6103176107093660046151b3565b61284c565b6103176129ad565b61071e612b1b565b604051610330939291906151ce565b6103c661073b3660046149e8565b612bf6565b61031761074e366004614cf0565b612c0b565b61031761076136600461522f565b612c64565b610478610774366004614889565b612e70565b61031761078736600461519a565b612e7b565b61031761079a36600461522f565b613099565b6107a76130aa565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061081e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61082882826130b2565b5050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110610891576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6010805460ff83169081106108a8576108a861524c565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115610951576010805460ff83169081106108f8576108f861524c565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610888565b505050565b61095e6130aa565b61096782613420565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61098f613496565b600061099c84600061351c565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109c65750600754610a3a565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a37919061527b565b90505b8383604051610a4a929190615294565b60405180910390208103610a8a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610aeb9061ffff16436152d3565b9052600086815260066020908152604090912082518155908201516001820190610b159082615387565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b569087908490889088906154a1565b60405180910390a15050505050565b610b6d613496565b8151815181141580610b7f5750600881115b15610bb6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ce2576000848281518110610bd557610bd561524c565b602002602001015190506000848381518110610bf357610bf361524c565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c5e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c95576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccf576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610888565b505080610cdb906154fc565b9050610bb9565b50600954600090610cf79061ffff16436152d3565b604080516060810182528681526020808201879052918101839052865192935091600391610d299183918901906146c9565b506020828101518051610d429260018501920190614710565b506040820151816002015590505060005b8451811015610e54577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610d8f57610d8f61524c565b602002602001015160026000888581518110610dad57610dad61524c565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610df657610df661524c565b602002602001015185604051610e3c949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e4d816154fc565b9050610d53565b5050505050565b610e63613496565b610e6b613613565b565b6000610eb68260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a91506136909050565b979650505050505050565b610ec96139c9565b610ed2826139d1565b610eda613a97565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108285767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b610fea6130aa565b806bffffffffffffffffffffffff166000036110205750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561107a576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906110a79084906bffffffffffffffffffffffff16615534565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166110fe9190615534565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561119d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c19190615560565b61082857600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611234573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611258919061527b565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610888565b6112c06139c9565b806bffffffffffffffffffffffff16600003611308576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611362576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061138f9084906bffffffffffffffffffffffff16615534565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166113e69190615534565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611485573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a99190615560565b610828576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006114eb838361351c565b9392505050565b6114fa6139c9565b60005b818110156109515760008383838181106115195761151961524c565b90506101600201803603810190611530919061557d565b905060008160e001519050600e60008281526020019081526020016000205482604051602001611560919061559a565b60405160208183030381529060405280519060200120146115ad576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156115f2576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611664573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116889190615560565b5060a0830151606084015167ffffffffffffffff166000908152600b6020526040812060010180549091906116cc9084906bffffffffffffffffffffffff16615534565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c6020908152828220606087015167ffffffffffffffff90811684529152919020805460019260099161175891859169010000000000000000009004166156c9565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806117c1906154fc565b90506114fd565b6117d06139c9565b6117d9826139d1565b6117e1613a97565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611856576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff161561189d575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610fb2565b60015473ffffffffffffffffffffffffffffffffffffffff1633146119f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610888565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611a9f6139c9565b611aa7613a97565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611b47576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610888565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611bee613496565b610e6b613b9e565b611bfe613496565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611c60576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611ca66139c9565b611caf826139d1565b611cb7613a97565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d87576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ddc576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611e5757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e2c575b50505050509050600060018251611e6e91906156ea565b905060005b825181101561200a578473ffffffffffffffffffffffffffffffffffffffff16838281518110611ea557611ea561524c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611ffa576000838381518110611edc57611edc61524c565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611f2257611f2261524c565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b90915260409020600201805480611f9c57611f9c6156fd565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061200a565b612003816154fc565b9050611e73565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000806120b16139c9565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461211a576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e602052604090205461213b5760029150612385565b600e60008460e0015181526020019081526020016000205483604051602001612164919061559a565b60405160208183030381529060405280519060200120146121885760079150612385565b826101400151836080015163ffffffff166121a3919061572c565b64ffffffffff165a10156121ba5760039150612385565b606083015167ffffffffffffffff166000908152600b602052604090205460808401516bffffffffffffffffffffffff909116906121fd9063ffffffff16613bf9565b612207908861574a565b8451612214908890615772565b61221e9190615772565b6bffffffffffffffffffffffff16111561223b5760049150612385565b8260a001516bffffffffffffffffffffffff16612261846080015163ffffffff16613bf9565b61226b908861574a565b8451612278908890615772565b6122829190615772565b6bffffffffffffffffffffffff16111561229f5760059150612385565b60009150600e60008460e0015181526020019081526020016000206000905560006122d98460e001518a8a87608001518860400151613c9b565b80519091506122e95760016122ec565b60005b9250600061231385606001518660a00151876040015188600001518c87602001518d613e15565b9050846060015167ffffffffffffffff168560e001517f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a836020015189888760000151612360578e612362565b8f5b8860400151604051612378959493929190615797565b60405180910390a3519150505b965096945050505050565b600061239a6139c9565b6123a2613a97565b600980546003906123c3906301000000900467ffffffffffffffff166157f5565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612439578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926124d492600285019290910190614710565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061253586613420565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561260057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116125d5575b5050505050905091939590929450565b6126186139c9565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612669576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146126a3576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006126b182840184614889565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661272a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906127618385615772565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff166127b89190615772565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461281f91906152d3565b6040805192835260208301919091520160405180910390a2505050505050565b6000610fdc82600061351c565b612854613496565b60095461ffff808316911603612896576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff1611156128f8576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff9081168083529084166020830152909182019061292590436152d3565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b6129b5613496565b6005544310156129f1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612b1857600060036000018281548110612a1657612a1661524c565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612a6257612a6261524c565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612b11906154fc565b90506129f4565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612b7b57602002820191906000526020600020905b815481526020019060010190808311612b67575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612be457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612bb9575b50505050509050925092509250909192565b6060612c03848484614067565b949350505050565b612c136139c9565b612c1c826139d1565b612c24613a97565b612c2d82614134565b1561081e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612c6c6130aa565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612cdb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cff919061527b565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612d66576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610888565b81811015610951576000612d7a82846156ea565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612df5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e199190615560565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b6000610fdc82614134565b612e83613496565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612ebd906152e6565b80601f0160208091040260200160405190810160405280929190818152602001828054612ee9906152e6565b8015612f365780601f10612f0b57610100808354040283529160200191612f36565b820191906000526020600020905b815481529060010190602001808311612f1957829003601f168201915b5050505050815260200160028201548152505090508060400151431015612f89576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612fae57612f9b8160200151614283565b6020808201518051910120600755613056565b612fb982600061351c565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612ff59190614960565b600060405180830381600087803b15801561300f57600080fd5b505af1925050508015613020575060015b613056576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261308d92869261581c565b60405180910390a15050565b6130a1613496565b612b188161437e565b610e6b613496565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561319357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613168575b505050918352505060039190910154602090910152805190915060005b82608001515181101561325457600c6000846080015183815181106131d7576131d761524c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561324d816154fc565b90506131b0565b5067ffffffffffffffff84166000908152600b602052604081208181556001810182905590613286600283018261478a565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff166132b99190615534565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613358573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061337c9190615560565b6133b2576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612b18576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610888565b60008161355b5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613555579050610fdc565b506135de565b60005b6003548110156135dc57600380548290811061357c5761357c61524c565b906000526020600020015484036135cc5760048054829081106135a1576135a161524c565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150610fdc9050565b6135d5816154fc565b905061355e565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610888565b61361b614479565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b600061369a6139c9565b6136a385613420565b6136ad33866144e5565b6136b7858361082c565b60006136c3888861351c565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c500000000000000000000000000000000000000000000000000000000815293945091929184169163aecc12c59161378a91600401615844565b610160604051808303816000875af11580156137aa573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137ce9190615919565b90506137df33888360a00151614581565b604051806101600160405280600f60000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff168152506040516020016138ec919061559a565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152828252805160209182012060e0850180516000908152600e8452848120929092555167ffffffffffffffff8c16808352600b9093529290205490928c92917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54916139b1916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908e908e908e906159ec565b60405180910390a460e0015198975050505050505050565b610e6b61465c565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613a48576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610828576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ac27fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097600061351c565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613b2590339060248101615a50565b602060405180830381865afa158015613b42573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b669190615560565b610e6b576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610888565b613ba661465c565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586136663390565b60006bffffffffffffffffffffffff821115613c97576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610888565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613ce690899089908990602401615a7f565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613d9857600080fd5b5a611388811015613da857600080fd5b611388810390508760408204820311613dc057600080fd5b60008086516020880160008b8df193505a900391503d6084811115613de3575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613e3484613bf9565b613e3e908661574a565b9050600081613e4d8886615772565b613e579190615772565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613eae91859116615534565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613ee89190615772565b336000908152600d602052604081208054909190613f159084906bffffffffffffffffffffffff16615772565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613f5c91859116615772565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613fb091859116615534565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161403491859169010000000000000000009004166156c9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6060600080808061407a86880188615ab4565b9350935093509350600061409389600187878787613690565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614127578181602081106140d2576140d261524c565b1a60f81b8782815181106140e8576140e861524c565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350614120816154fc565b90506140b7565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156141ac57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614181575b5050505050905060005b8151811015614279576000600c60008484815181106141d7576141d761524c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461426857506001949350505050565b50614272816154fc565b90506141b6565b5060009392505050565b60008060008380602001905181019061429c9190615b27565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c021781558351959850939650919450909261434791601091908601906147a8565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612e6293929190615c10565b3373ffffffffffffffffffffffffffffffffffffffff8216036143fd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610888565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610888565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610828576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906145bb9084906bffffffffffffffffffffffff16615772565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926146319284929004166156c9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610888565b828054828255906000526020600020908101928215614704579160200282015b828111156147045782518255916020019190600101906146e9565b50613c9792915061484e565b828054828255906000526020600020908101928215614704579160200282015b8281111561470457825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614730565b5080546000825590600052602060002090810190612b18919061484e565b828054828255906000526020600020906007016008900481019282156147045791602002820160005b8382111561481557835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026147d1565b80156148455782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614815565b5050613c979291505b5b80821115613c97576000815560010161484f565b67ffffffffffffffff81168114612b1857600080fd5b803561488481614863565b919050565b60006020828403121561489b57600080fd5b81356114eb81614863565b63ffffffff81168114612b1857600080fd5b8035614884816148a6565b600080604083850312156148d657600080fd5b82356148e181614863565b915060208301356148f1816148a6565b809150509250929050565b6000815180845260005b8181101561492257602081850181015186830182015201614906565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114eb60208301846148fc565b6000806040838503121561498657600080fd5b823561499181614863565b946020939093013593505050565b60008083601f8401126149b157600080fd5b50813567ffffffffffffffff8111156149c957600080fd5b6020830191508360208285010111156149e157600080fd5b9250929050565b6000806000604084860312156149fd57600080fd5b83359250602084013567ffffffffffffffff811115614a1b57600080fd5b614a278682870161499f565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614a8757614a87614a34565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614ad457614ad4614a34565b604052919050565b600067ffffffffffffffff821115614af657614af6614a34565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff81168114612b1857600080fd5b803561488481614b00565b600082601f830112614b3e57600080fd5b81356020614b53614b4e83614adc565b614a8d565b82815260059290921b84018101918181019086841115614b7257600080fd5b8286015b84811015614b96578035614b8981614b00565b8352918301918301614b76565b509695505050505050565b60008060408385031215614bb457600080fd5b823567ffffffffffffffff80821115614bcc57600080fd5b818501915085601f830112614be057600080fd5b81356020614bf0614b4e83614adc565b82815260059290921b84018101918181019089841115614c0f57600080fd5b948201945b83861015614c2d57853582529482019490820190614c14565b96505086013592505080821115614c4357600080fd5b50614c5085828601614b2d565b9150509250929050565b803561ffff8116811461488457600080fd5b60008060008060008060a08789031215614c8557600080fd5b8635614c9081614863565b9550602087013567ffffffffffffffff811115614cac57600080fd5b614cb889828a0161499f565b9096509450614ccb905060408801614c5a565b92506060870135614cdb816148a6565b80925050608087013590509295509295509295565b60008060408385031215614d0357600080fd5b8235614d0e81614863565b915060208301356148f181614b00565b6bffffffffffffffffffffffff81168114612b1857600080fd5b803561488481614d1e565b60008060408385031215614d5657600080fd5b8235614d6181614b00565b915060208301356148f181614d1e565b60008060408385031215614d8457600080fd5b8235614d8f81614b00565b915060208301356148f181614863565b8015158114612b1857600080fd5b60008060408385031215614dc057600080fd5b8235915060208301356148f181614d9f565b60008060208385031215614de557600080fd5b823567ffffffffffffffff80821115614dfd57600080fd5b818501915085601f830112614e1157600080fd5b813581811115614e2057600080fd5b86602061016083028501011115614e3657600080fd5b60209290920196919550909350505050565b600082601f830112614e5957600080fd5b813567ffffffffffffffff811115614e7357614e73614a34565b614ea460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a8d565b818152846020838601011115614eb957600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff81168114612b1857600080fd5b803561488481614ed6565b69ffffffffffffffffffff81168114612b1857600080fd5b803561488481614ef4565b60006101608284031215614f2a57600080fd5b614f32614a63565b9050614f3d82614d38565b8152614f4b60208301614b22565b6020820152614f5c60408301614b22565b6040820152614f6d60608301614879565b6060820152614f7e608083016148b8565b6080820152614f8f60a08301614d38565b60a0820152614fa060c08301614ee9565b60c082015260e082013560e0820152610100614fbd818401614f0c565b90820152610120614fcf838201614ee9565b90820152610140614fe1838201614ee9565b9082015292915050565b600080600080600080610200878903121561500557600080fd5b863567ffffffffffffffff8082111561501d57600080fd5b6150298a838b01614e48565b9750602089013591508082111561503f57600080fd5b5061504c89828a01614e48565b955050604087013561505d81614d1e565b9350606087013561506d81614d1e565b9250608087013561507d81614b00565b915061508c8860a08901614f17565b90509295509295509295565b600081518084526020808501945080840160005b838110156150de57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016150ac565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090610eb690830184615098565b6000806000806060858703121561515457600080fd5b843561515f81614b00565b935060208501359250604085013567ffffffffffffffff81111561518257600080fd5b61518e8782880161499f565b95989497509550505050565b6000602082840312156151ac57600080fd5b5035919050565b6000602082840312156151c557600080fd5b6114eb82614c5a565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561520f578451835293830193918301916001016151f3565b505084810360408601526152238187615098565b98975050505050505050565b60006020828403121561524157600080fd5b81356114eb81614b00565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561528d57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610fdc57610fdc6152a4565b600181811c908216806152fa57607f821691505b602082108103615333577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561095157600081815260208120601f850160051c810160208610156153605750805b601f850160051c820191505b8181101561537f5782815560010161536c565b505050505050565b815167ffffffffffffffff8111156153a1576153a1614a34565b6153b5816153af84546152e6565b84615339565b602080601f83116001811461540857600084156153d25750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561537f565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561545557888601518255948401946001909101908401615436565b508582101561549157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361552d5761552d6152a4565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615559576155596152a4565b5092915050565b60006020828403121561557257600080fd5b81516114eb81614d9f565b6000610160828403121561559057600080fd5b6114eb8383614f17565b81516bffffffffffffffffffffffff168152610160810160208301516155d8602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615600604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606083015161561c606084018267ffffffffffffffff169052565b506080830151615634608084018263ffffffff169052565b5060a083015161565460a08401826bffffffffffffffffffffffff169052565b5060c083015161566d60c084018264ffffffffff169052565b5060e083015160e0830152610100808401516156968285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff818116838216019080821115615559576155596152a4565b81810381811115610fdc57610fdc6152a4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b64ffffffffff818116838216019080821115615559576155596152a4565b6bffffffffffffffffffffffff8181168382160280821691908281146156c1576156c16152a4565b6bffffffffffffffffffffffff818116838216019080821115615559576155596152a4565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a0606082015260006157e360a08301856148fc565b828103608084015261522381856148fc565b600067ffffffffffffffff808316818103615812576158126152a4565b6001019392505050565b83815282602082015260606040820152600061583b60608301846148fc565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e0606084015261588f6101008401826148fc565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b805161488481614d1e565b805161488481614b00565b805161488481614863565b8051614884816148a6565b805161488481614ed6565b805161488481614ef4565b6000610160828403121561592c57600080fd5b615934614a63565b61593d836158d7565b815261594b602084016158e2565b602082015261595c604084016158e2565b604082015261596d606084016158ed565b606082015261597e608084016158f8565b608082015261598f60a084016158d7565b60a08201526159a060c08401615903565b60c082015260e083015160e08201526101006159bd81850161590e565b908201526101206159cf848201615903565b908201526101406159e1848201615903565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615a2d60c08301866148fc565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612c0360408301846148fc565b838152606060208201526000615a9860608301856148fc565b8281036040840152615aaa81856148fc565b9695505050505050565b60008060008060808587031215615aca57600080fd5b8435615ad581614863565b9350602085013567ffffffffffffffff811115615af157600080fd5b615afd87828801614e48565b935050615b0c60408601614c5a565b91506060850135615b1c816148a6565b939692955090935050565b600080600060608486031215615b3c57600080fd5b8351615b4781614d1e565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615b7f57600080fd5b604086015190935067ffffffffffffffff811115615b9c57600080fd5b8501601f81018713615bad57600080fd5b8051615bbb614b4e82614adc565b81815260059190911b82018301908381019089831115615bda57600080fd5b928401925b82841015615c01578351615bf2816148a6565b82529284019290840190615bdf565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615c8d57845163ffffffff1683529383019391830191600101615c6b565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -669,16 +683,16 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) CreateSubscription() ( return _FunctionsRouter.Contract.CreateSubscription(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "fulfill", requestId, response, err, juelsPerGas, costWithoutFulfillment, transmitter) +func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "fulfill", response, err, juelsPerGas, costWithoutFulfillment, transmitter, commitment) } -func (_FunctionsRouter *FunctionsRouterSession) Fulfill(requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, requestId, response, err, juelsPerGas, costWithoutFulfillment, transmitter) +func (_FunctionsRouter *FunctionsRouterSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutFulfillment, transmitter, commitment) } -func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, requestId, response, err, juelsPerGas, costWithoutFulfillment, transmitter) +func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutFulfillment, transmitter, commitment) } func (_FunctionsRouter *FunctionsRouterTransactor) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { @@ -837,16 +851,16 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) SetFlags(subscriptionI return _FunctionsRouter.Contract.SetFlags(&_FunctionsRouter.TransactOpts, subscriptionId, flags) } -func (_FunctionsRouter *FunctionsRouterTransactor) TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "timeoutRequests", requestIdsToTimeout) +func (_FunctionsRouter *FunctionsRouterTransactor) TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "timeoutRequests", requestsToTimeoutByCommitment) } -func (_FunctionsRouter *FunctionsRouterSession) TimeoutRequests(requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestIdsToTimeout) +func (_FunctionsRouter *FunctionsRouterSession) TimeoutRequests(requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestsToTimeoutByCommitment) } -func (_FunctionsRouter *FunctionsRouterTransactorSession) TimeoutRequests(requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestIdsToTimeout) +func (_FunctionsRouter *FunctionsRouterTransactorSession) TimeoutRequests(requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestsToTimeoutByCommitment) } func (_FunctionsRouter *FunctionsRouterTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { @@ -3906,7 +3920,7 @@ type FunctionsRouterInterface interface { CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) - Fulfill(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) + Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) @@ -3934,7 +3948,7 @@ type FunctionsRouterInterface interface { SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) - TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) + TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index d77ac34caab..a3f2602e96f 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,8 +3,8 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../. functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 666319c8b9b06d75db166d87a7338a79e9abe9eff71b73ea905f16f9e7cc95cf functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin bc0d4aa6e244f7d2dbd29b2abadcef8c7db0bc7223475e7485273a1709412d7c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 00604c0ef992a6cdbe836a49628403f444a434e3e2a9ae3359ac59ca677f5afe +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 9e5662eef996c0572071e12d4ddd82018a8b846b97a048ea962af94c181d8391 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 04e953ed36312263c903beb630d998386ff9d58e39c662c4afa59b755f8a9c64 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index ca168b6aa13..8380241cc4f 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -412,6 +412,7 @@ func (l *FunctionsListener) handleOracleRequestV1(request *evmrelayTypes.OracleR Flags: request.Flags[:], CallbackGasLimit: &callbackGasLimit, CoordinatorContractAddress: &request.CoordinatorContract, + OnchainMetadata: request.OnchainMetadata, } if err := l.pluginORM.CreateRequest(newReq, pg.WithParentCtx(ctx)); err != nil { if errors.Is(err, ErrDuplicateRequestID) { diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index 9614eeb835f..7d42a100be9 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -31,7 +31,7 @@ func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, - MaxObservationLengthBytes: 10_000, + MaxObservationLengthBytes: 15_000, MaxReportLengthBytes: 15_000, MaxRequestBatchSize: uint32(batchSize), MaxReportTotalCallbackGas: uint32(maxTotalReportGas), diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index c5ca076c16f..25f24f45118 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -161,6 +161,7 @@ func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmR Flags: oracleRequest.Flags, CallbackGasLimit: oracleRequest.CallbackGasLimit, TxHash: oracleRequest.Raw.TxHash, + OnchainMetadata: oracleRequest.Commitment, CoordinatorContract: coordinator, }) } diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index d0c814535ea..5fa8e0cf323 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -53,6 +53,7 @@ type OracleRequest struct { CallbackGasLimit uint64 TxHash common.Hash CoordinatorContract common.Address + OnchainMetadata []byte } type OracleResponse struct { From f6c613f2a73ecb56a783d881b774086c960575c7 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Tue, 1 Aug 2023 19:48:48 -0700 Subject: [PATCH 056/270] [Functions] Consolidate events emitted on request processing (#10039) * [Functions] Consolidate events emitted on request processing 1. Emit OracleResponse and delete request from state only on USER_SUCCESS/ERROR. 2. Consolidate all specific events into RequestNotProcessed with an error code. 3. Remove INTERNAL_ERROR and re-order event enums to match our docs. * (test): Update test for event RequestEnd -> RequestProcessed --------- Co-authored-by: Justin Kaseman --- .../functions/dev/1_0_0/FunctionsBilling.sol | 17 +- .../dev/1_0_0/FunctionsCoordinator.sol | 12 - .../functions/dev/1_0_0/FunctionsRouter.sol | 24 +- .../1_0_0/interfaces/FulfillResultCodes.sol | 9 +- .../v1/FunctionsSubscriptions.test.ts | 6 +- .../functions_coordinator.go | 560 +----------------- .../functions_router/functions_router.go | 196 +++++- ...rapper-dependency-versions-do-not-edit.txt | 4 +- 8 files changed, 207 insertions(+), 621 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index c7f3fd71651..c4f91a2ea7e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -349,7 +349,6 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { if (s_requestCommitments[requestId] != keccak256(abi.encode(commitment))) { return FulfillResult.INVALID_COMMITMENT; } - delete s_requestCommitments[requestId]; int256 weiPerUnitLink; weiPerUnitLink = getFeedData(); @@ -374,13 +373,17 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { commitment ); - // Reimburse the transmitter for the fulfillment gas cost - s_withdrawableTokens[msg.sender] = gasOverheadJuels + callbackCostJuels; - // Put donFee into the pool of fees, to be split later - // Saves on storage writes that would otherwise be charged to the user - s_feePool += commitment.donFee; + FulfillResult fulfillResult = FulfillResult(result); + if (fulfillResult == FulfillResult.USER_SUCCESS || fulfillResult == FulfillResult.USER_ERROR) { + delete s_requestCommitments[requestId]; + // Reimburse the transmitter for the fulfillment gas cost + s_withdrawableTokens[msg.sender] = gasOverheadJuels + callbackCostJuels; + // Put donFee into the pool of fees, to be split later + // Saves on storage writes that would otherwise be charged to the user + s_feePool += commitment.donFee; + } - return FulfillResult(result); + return fulfillResult; } // ================================================================ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index dc14a17410b..f27bb6b0d7b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -27,10 +27,6 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli bytes commitment ); event OracleResponse(bytes32 indexed requestId, address transmitter); - event InvalidRequestID(bytes32 indexed requestId); - event InsufficientGasProvided(bytes32 indexed requestId); - event CostExceedsCommitment(bytes32 indexed requestId); - event InsufficientSubscriptionBalance(bytes32 indexed requestId); error EmptyRequestData(); error InconsistentReportData(); @@ -232,14 +228,6 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli if (result == FulfillResult.USER_SUCCESS || result == FulfillResult.USER_ERROR) { emit OracleResponse(requestIds[i], msg.sender); - } else if (result == FulfillResult.INVALID_REQUEST_ID) { - emit InvalidRequestID(requestIds[i]); - } else if (result == FulfillResult.INSUFFICIENT_GAS) { - emit InsufficientGasProvided(requestIds[i]); - } else if (result == FulfillResult.COST_EXCEEDS_COMMITMENT) { - emit CostExceedsCommitment(requestIds[i]); - } else if (result == FulfillResult.INSUFFICIENT_SUBSCRIPTION_BALANCE) { - emit InsufficientSubscriptionBalance(requestIds[i]); } } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 839c598a339..b6cd6cea938 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -5,6 +5,7 @@ import {RouterBase, ITypeAndVersion} from "./RouterBase.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; +import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; @@ -27,7 +28,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint32 callbackGasLimit ); - event RequestEnd( + event RequestProcessed( bytes32 indexed requestId, uint64 indexed subscriptionId, uint96 totalCostJuels, @@ -37,6 +38,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes returnData ); + event RequestNotProcessed(bytes32 indexed requestId, address coordinator, address transmitter, uint8 resultCode); + error OnlyCallableFromCoordinator(); error SenderMustAcceptTermsOfService(address sender); error InvalidGasFlagValue(uint8 value); @@ -237,18 +240,21 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } if (s_requestCommitments[commitment.requestId] == bytes32(0)) { - resultCode = 2; // FulfillResult.INVALID_REQUEST_ID + resultCode = uint8(FulfillResult.INVALID_REQUEST_ID); + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } if (keccak256(abi.encode(commitment)) != s_requestCommitments[commitment.requestId]) { - resultCode = 7; // FulfillResult.INVALID_REQUEST_ID + resultCode = uint8(FulfillResult.INVALID_COMMITMENT); + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } // Check that the transmitter has supplied enough gas for the callback to succeed if (gasleft() < commitment.callbackGasLimit + commitment.gasOverheadAfterCallback) { - resultCode = 3; // IFunctionsRouter.FulfillResult.INSUFFICIENT_GAS; + resultCode = uint8(FulfillResult.INSUFFICIENT_GAS_PROVIDED); + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } @@ -257,7 +263,9 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > s_subscriptions[commitment.subscriptionId].balance ) { - resultCode = 4; // IFunctionsRouter.FulfillResult.INSUFFICIENT_SUBSCRIPTION_BALANCE + resultCode = uint8(FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION); + delete s_requestCommitments[commitment.requestId]; + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } @@ -266,7 +274,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > commitment.estimatedTotalCostJuels ) { - resultCode = 5; // IFunctionsRouter.FulfillResult.COST_EXCEEDS_COMMITMENT + resultCode = uint8(FulfillResult.COST_EXCEEDS_COMMITMENT); + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } @@ -296,7 +305,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions costWithoutFulfillment ); - emit RequestEnd( + // resultCode must be 0 or 1 here + emit RequestProcessed( commitment.requestId, commitment.subscriptionId, receipt.totalCostJuels, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol index 1178474a5d2..86418cd2f3d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol @@ -5,9 +5,8 @@ enum FulfillResult { USER_SUCCESS, // 0 USER_ERROR, // 1 INVALID_REQUEST_ID, // 2 - INSUFFICIENT_GAS, // 3 - INSUFFICIENT_SUBSCRIPTION_BALANCE, // 4 - COST_EXCEEDS_COMMITMENT, // 5 - INTERNAL_ERROR, // 6 - INVALID_COMMITMENT // 7 + COST_EXCEEDS_COMMITMENT, // 3 + INSUFFICIENT_GAS_PROVIDED, // 4 + SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION, // 5 + INVALID_COMMITMENT // 6 } diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 90f77fce151..0f088129d70 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -638,7 +638,7 @@ describe('Functions Router - Subscriptions', () => { await expect(contracts.coordinator.callReport(report, { gasPrice })) .to.emit(contracts.coordinator, 'OracleResponse') .withArgs(requestId, await roles.defaultAccount.getAddress()) - .to.emit(contracts.router, 'RequestEnd') + .to.emit(contracts.router, 'RequestProcessed') .withArgs( requestId, subscriptionId, @@ -728,7 +728,7 @@ describe('Functions Router - Subscriptions', () => { .withArgs(requestId, await roles.defaultAccount.getAddress()) .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) - .to.emit(contracts.router, 'RequestEnd') + .to.emit(contracts.router, 'RequestProcessed') .withArgs( requestId, subscriptionId, @@ -839,7 +839,7 @@ describe('Functions Router - Subscriptions', () => { .withArgs(requestId, await roles.defaultAccount.getAddress()) .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) - .to.emit(contracts.router, 'RequestEnd') + .to.emit(contracts.router, 'RequestProcessed') .withArgs( requestId, subscriptionId, diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index fc6e78ee5d3..79002bc752d 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -62,8 +62,8 @@ type IFunctionsRequestCommitment struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientSubscriptionBalance\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005a9438038062005a94833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516154096200068b60003960008181610a1901528181610e3c01528181610f1a01528181610ff801528181611a9401528181611cde01528181612eb00152613b09015260006114d101526154096000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610535578063de9dfa461461053d578063e3d0e71214610550578063f2fde38b1461056357600080fd5b8063b1dc65a4146103f4578063c3f909d414610407578063d227d2451461050557600080fd5b8063aecc12c5116100c8578063aecc12c5146103ac578063af1296d3146103cc578063afcb95d7146103d457600080fd5b80638cc6acce1461035f5780638da5cb5b146103725780639883c10d1461039a57600080fd5b806379ba50971161015b578063814118341161013557806381411834146102b257806381f1b938146102c757806381ff7048146102cf57806385b214cf1461033c57600080fd5b806379ba5097146102845780637f15e1661461028c578063807560311461029f57600080fd5b8063466557181161018c578063466557181461022d578063533989871461025b57806366316d8d1461027157600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac1461021a575b600080fd5b6101c66101c1366004613d5a565b610576565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190613e00565b60405180910390f35b6101c6610228366004613e35565b6105cb565b61024061023b366004613fbb565b61066d565b60405169ffffffffffffffffffff9091168152602001610211565b61026361069b565b6040516102119291906140e2565b6101c661027f36600461418c565b61091f565b6101c6610ad9565b6101c661029a366004613d5a565b610bdb565b6101c66102ad3660046141c5565b610c2b565b6102ba610ce2565b604051610211919061421a565b610204610d51565b61031960015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b61034f61034a36600461422d565b610e22565b6040519015158152602001610211565b6101c661036d366004614246565b610f02565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6007545b604051908152602001610211565b6103bf6103ba366004614283565b610f87565b60405161021191906143e4565b61039e61126b565b604080516001815260006020820181905291810191909152606001610211565b6101c6610402366004614438565b61135e565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff1661012082015261014001610211565b6105186105133660046144ef565b611a8f565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611c83565b61051861054b366004613fbb565b611cda565b6101c661055e366004614611565b611d72565b6101c6610571366004613e35565b612796565b61057e6127a7565b60008190036105b9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105c682848361477f565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061060657503373ffffffffffffffffffffffffffffffffffffffff8216145b61063c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061066a91613c9f565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106d8575b505050505090506000815167ffffffffffffffff81111561072657610726613e52565b60405190808252806020026020018201604052801561075957816020015b60608152602001906001900390816107445790505b50905060005b825181101561091557600f600084838151811061077e5761077e61489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107cb906146de565b9050600003610806576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061081c5761081c61489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610869906146de565b80601f0160208091040260200160405190810160405280929190818152602001828054610895906146de565b80156108e25780601f106108b7576101008083540402835291602001916108e2565b820191906000526020600020905b8154815290600101906020018083116108c557829003601f168201915b50505050508282815181106108f9576108f961489a565b60200260200101819052508061090e906148f8565b905061075f565b5090939092509050565b61092761282a565b806bffffffffffffffffffffffff1660000361095d5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109b7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109e49084906bffffffffffffffffffffffff16614930565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610a3b7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610abc57600080fd5b505af1158015610ad0573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610be36127a7565b6000819003610c1e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105c682848361477f565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c765750610c55336129bb565b8015610c7657503373ffffffffffffffffffffffffffffffffffffffff8416145b610cac576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cdc82848361477f565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d4757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d1c575b5050505050905090565b606060108054610d60906146de565b9050600003610d9b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610da8906146de565b80601f0160208091040260200160405190810160405280929190818152602001828054610dd4906146de565b8015610d475780601f10610df657610100808354040283529160200191610d47565b820191906000526020600020905b815481529060010190602001808311610e0457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e93576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902054610eae57506000919050565b60008281526008602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610ef19084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f71576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610f7a81612aa4565b8051602090910120600755565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461104f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61105c604083018361495c565b9050600003611096576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808460600160208101906110b691906149c1565b67ffffffffffffffff1681526020908101906110d490860186613e35565b73ffffffffffffffffffffffffffffffffffffffff1681526020016110ff60e0860160c087016149de565b63ffffffff1681523a602090910152905061116b611120604085018561495c565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506111659250505060a0860160808701614a0b565b83612dad565b915061117a6020840184613e35565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3328660600160208101906111ca91906149c1565b6111da6040890160208a01613e35565b6111e760408a018a61495c565b6111f760a08c0160808d01614a0b565b60a08c013561120c60e08e0160c08f016149de565b8c60405160200161121d91906143e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261125d999897969594939291614a28565b60405180910390a350919050565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611305573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113299190614af5565b5093505092505082801561134b57506113428142614b45565b8463ffffffff16105b1561135657600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c0135916113b491849163ffffffff851691908e908e908190840183828082843760009201919091525061328592505050565b6113ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146114bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b56565b6114cd8b8b8b8b8b8b61328e565b60007f00000000000000000000000000000000000000000000000000000000000000001561152a5760028260200151836040015161150b9190614b58565b6115159190614ba0565b611520906001614b58565b60ff169050611540565b602082015161153a906001614b58565b60ff1690505b8881146115a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b56565b888714611612576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b56565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561165557611655614bc2565b600281111561166657611666614bc2565b905250905060028160200151600281111561168357611683614bc2565b1480156116ca57506006816000015160ff16815481106116a5576116a561489a565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611730576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b56565b505050505061173d613cd9565b6000808a8a604051611750929190614bf1565b604051908190038120611767918e90602001614c01565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611a715760006001848984602081106117d0576117d061489a565b6117dd91901a601b614b58565b8e8e868181106117ef576117ef61489a565b905060200201358d8d878181106118085761180861489a565b9050602002013560405160008152602001604052604051611845949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611867573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156118e7576118e7614bc2565b60028111156118f8576118f8614bc2565b905250925060018360200151600281111561191557611915614bc2565b1461197c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b56565b8251600090879060ff16601f81106119965761199661489a565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611a18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b56565b8086846000015160ff16601f8110611a3257611a3261489a565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611a5d600186614b58565b94505080611a6a906148f8565b90506117b1565b505050611a82833383858e8e61333c565b5050505050505050505050565b6000807f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8916600482015263ffffffff8616602482015290915073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611b3157600080fd5b505afa158015611b45573d6000803e3d6000fd5b50505050620f4240831115611b86576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611c1488888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061066d915050565b69ffffffffffffffffffff1690506000611c6589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611cda915050565b9050611c738787848461369a565b9450505050505b95945050505050565b6060600e8054611c92906146de565b9050600003611ccd576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610da8906146de565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611d47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d6b9190614c20565b9392505050565b855185518560ff16601f831115611de5576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b56565b80600003611e4f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b56565b818314611edd576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b56565b611ee8816003614c3d565b8311611f50576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b56565b611f586127a7565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f9f908861380a565b6005541561215457600554600090611fb990600190614b45565b9050600060058281548110611fd057611fd061489a565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200a5761200a61489a565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208a5761208a614c54565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120f3576120f3614c54565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f9f915050565b60005b8151518110156125bb576000600460008460000151848151811061217d5761217d61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121c7576121c7614bc2565b1461222e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b56565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225f5761225f61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561230057612300614bc2565b0217905550600091506123109050565b600460008460200151848151811061232a5761232a61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561237457612374614bc2565b146123db576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b56565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240e5761240e61489a565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124af576124af614bc2565b0217905550508251805160059250839081106124cd576124cd61489a565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106125495761254961489a565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125b3816148f8565b915050612157565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161267391849174010000000000000000000000000000000000000000900416614c83565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126d24630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613827565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612789988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614ca0565b60405180910390a1611a82565b61279e6127a7565b61066a816138d2565b60005473ffffffffffffffffffffffffffffffffffffffff163314612828576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b56565b565b6000612834610ce2565b90508051600003612871576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d54600091612890916bffffffffffffffffffffffff16614d36565b905060005b825181101561295c5781600c60008584815181106128b5576128b561489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff1661291d9190614d61565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612955906148f8565b9050612895565b5081516129699082614d86565b600d80546000906129899084906bffffffffffffffffffffffff16614930565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a2157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129f6575b5050505050905060005b8151811015612a9a578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5d57612a5d61489a565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a8a575060019392505050565b612a93816148f8565b9050612a2b565b5060009392505050565b600080600080600080600080600089806020019051810190612ac69190614dc1565b98509850985098509850985098509850985060008113612b15576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d99908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260095461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115612e6c576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612e78858461066d565b90506000612e868685611cda565b90506000612eaa856040015186606001518569ffffffffffffffffffff168561369a565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612f4e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612f949190810190614e78565b50505060208a01518a516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015613025573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130499190614f6f565b509150506bffffffffffffffffffffffff85166130668385614930565b6bffffffffffffffffffffffff1610156130ac576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061312b308b602001518c600001518560016130c99190614fc1565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b60408051610160810182526bffffffffffffffffffffffff808b168252306020808401919091528e015173ffffffffffffffffffffffffffffffffffffffff16828401528d5167ffffffffffffffff166060830152918d015163ffffffff908116608083015291891660a08201526009549293509160c08301916131c49170010000000000000000000000000000000090041642614fe2565b64ffffffffff168152602080820184905269ffffffffffffffffffff8b1660408084019190915260095463ffffffff680100000000000000008204811660608601526c01000000000000000000000000909104166080909301929092529051919a50613232918b91016143e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260089092529091205550959998505050505050505050565b60019392505050565b600061329b826020614c3d565b6132a6856020614c3d565b6132b288610144614fe2565b6132bc9190614fe2565b6132c69190614fe2565b6132d1906000614fe2565b9050368114610ad0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b56565b60608080808061334e868801886150d0565b845194995092975090955093509150158061336b57508351855114155b8061337857508251855114155b8061338557508151855114155b8061339257508051855114155b156133c9576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561368c5760006134618783815181106133ec576133ec61489a565b60200260200101518784815181106134065761340661489a565b60200260200101518785815181106134205761342061489a565b602002602001015187868151811061343a5761343a61489a565b60200260200101518787815181106134545761345461489a565b60200260200101516139c7565b9050600081600781111561347757613477614bc2565b14806134945750600181600781111561349257613492614bc2565b145b156134ef578682815181106134ab576134ab61489a565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a261367b565b600281600781111561350357613503614bc2565b036135535786828151811061351a5761351a61489a565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a261367b565b600381600781111561356757613567614bc2565b036135b75786828151811061357e5761357e61489a565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a261367b565b60058160078111156135cb576135cb614bc2565b0361361b578682815181106135e2576135e261489a565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a261367b565b600481600781111561362f5761362f614bc2565b0361367b578682815181106136465761364661489a565b60200260200101517fb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d60405160405180910390a25b50613685816148f8565b90506133cc565b505050505050505050505050565b6000806136a561126b565b9050600081136136e4576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b600954600090879061371a9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c83565b6137249190614c83565b63ffffffff1690506000612710600960010154886137429190614c3d565b61374c91906151a2565b6137569088614fe2565b90506000838361376e84670de0b6b3a7640000614c3d565b6137789190614c3d565b61378291906151a2565b905060006137a16bffffffffffffffffffffffff808916908a16614fe2565b90506137b9816b033b2e3c9fd0803ce8000000614b45565b8211156137f2576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6137fc8183614fe2565b9a9950505050505050505050565b6000613814610ce2565b5111156138235761382361282a565b5050565b6000808a8a8a8a8a8a8a8a8a60405160200161384b999897969594939291906151b6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613951576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b56565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906139de9190615260565b6000888152600860205260409020549091506139fe576002915050611c7a565b80604051602001613a0f91906143e4565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600890935291205414613a61576007915050611c7a565b6000878152600860205260408120819055613a7a61126b565b905060008113613ab9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b600081613ace3a670de0b6b3a7640000614c3d565b613ad891906151a2565b90506000836101400151846101200151613af29190615333565b613b039064ffffffffff1683614c3d565b905060007f000000000000000000000000000000000000000000000000000000000000000090506000808273ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288d8d888b610100015169ffffffffffffffffffff1689613b699190614d61565b338d6040518763ffffffff1660e01b8152600401613b8c96959493929190615351565b60408051808303816000875af1158015613baa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bce91906153cd565b9092509050613bdd8185614d61565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100890151600d805469ffffffffffffffffffff90921693909291613c4b91859116614d61565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508160ff166007811115613c8e57613c8e614bc2565b9d9c50505050505050505050505050565b508054613cab906146de565b6000825580601f10613cbb575050565b601f01602090049060005260206000209081019061066a9190613cf8565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613d0d5760008155600101613cf9565b5090565b60008083601f840112613d2357600080fd5b50813567ffffffffffffffff811115613d3b57600080fd5b602083019150836020828501011115613d5357600080fd5b9250929050565b60008060208385031215613d6d57600080fd5b823567ffffffffffffffff811115613d8457600080fd5b613d9085828601613d11565b90969095509350505050565b6000815180845260005b81811015613dc257602081850181015186830182015201613da6565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611d6b6020830184613d9c565b73ffffffffffffffffffffffffffffffffffffffff8116811461066a57600080fd5b600060208284031215613e4757600080fd5b8135611d6b81613e13565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715613ea557613ea5613e52565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613ef257613ef2613e52565b604052919050565b600082601f830112613f0b57600080fd5b813567ffffffffffffffff811115613f2557613f25613e52565b613f5660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613eab565b818152846020838601011115613f6b57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461066a57600080fd5b8035610efd81613f88565b63ffffffff8116811461066a57600080fd5b60008082840360a0811215613fcf57600080fd5b833567ffffffffffffffff80821115613fe757600080fd5b613ff387838801613efa565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08401121561402557600080fd5b6040519250608083019150828210818311171561404457614044613e52565b50604052602084013561405681613f88565b8152604084013561406681613e13565b6020820152606084013561407981613fa9565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b838110156140d757815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140a5565b509495945050505050565b6040815260006140f56040830185614091565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614163577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614151838351613d9c565b94860194925090850190600101614117565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461066a57600080fd5b6000806040838503121561419f57600080fd5b82356141aa81613e13565b915060208301356141ba81614172565b809150509250929050565b6000806000604084860312156141da57600080fd5b83356141e581613e13565b9250602084013567ffffffffffffffff81111561420157600080fd5b61420d86828701613d11565b9497909650939450505050565b602081526000611d6b6020830184614091565b60006020828403121561423f57600080fd5b5035919050565b60006020828403121561425857600080fd5b813567ffffffffffffffff81111561426f57600080fd5b61427b84828501613efa565b949350505050565b60006020828403121561429557600080fd5b813567ffffffffffffffff8111156142ac57600080fd5b820160e08185031215611d6b57600080fd5b80516bffffffffffffffffffffffff16825260208101516142f7602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604081015161431f604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606081015161433b606084018267ffffffffffffffff169052565b506080810151614353608084018263ffffffff169052565b5060a081015161437360a08401826bffffffffffffffffffffffff169052565b5060c081015161438c60c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143b58285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610cdc565b610160810161069582846142be565b60008083601f84011261440557600080fd5b50813567ffffffffffffffff81111561441d57600080fd5b6020830191508360208260051b8501011115613d5357600080fd5b60008060008060008060008060e0898b03121561445457600080fd5b606089018a81111561446557600080fd5b8998503567ffffffffffffffff8082111561447f57600080fd5b61448b8c838d01613d11565b909950975060808b01359150808211156144a457600080fd5b6144b08c838d016143f3565b909750955060a08b01359150808211156144c957600080fd5b506144d68b828c016143f3565b999c989b50969995989497949560c00135949350505050565b60008060008060006080868803121561450757600080fd5b853561451281613f88565b9450602086013567ffffffffffffffff81111561452e57600080fd5b61453a88828901613d11565b909550935050604086013561454e81613fa9565b949793965091946060013592915050565b600067ffffffffffffffff82111561457957614579613e52565b5060051b60200190565b600082601f83011261459457600080fd5b813560206145a96145a48361455f565b613eab565b82815260059290921b840181019181810190868411156145c857600080fd5b8286015b848110156145ec5780356145df81613e13565b83529183019183016145cc565b509695505050505050565b60ff8116811461066a57600080fd5b8035610efd816145f7565b60008060008060008060c0878903121561462a57600080fd5b863567ffffffffffffffff8082111561464257600080fd5b61464e8a838b01614583565b9750602089013591508082111561466457600080fd5b6146708a838b01614583565b965061467e60408a01614606565b9550606089013591508082111561469457600080fd5b6146a08a838b01613efa565b94506146ae60808a01613f9e565b935060a08901359150808211156146c457600080fd5b506146d189828a01613efa565b9150509295509295509295565b600181811c908216806146f257607f821691505b60208210810361472b577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105c657600081815260208120601f850160051c810160208610156147585750805b601f850160051c820191505b8181101561477757828155600101614764565b505050505050565b67ffffffffffffffff83111561479757614797613e52565b6147ab836147a583546146de565b83614731565b6000601f8411600181146147fd57600085156147c75750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614893565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561484c578685013582556020948501946001909201910161482c565b5086821015614887577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614929576149296148c9565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614955576149556148c9565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261499157600080fd5b83018035915067ffffffffffffffff8211156149ac57600080fd5b602001915036819003821315613d5357600080fd5b6000602082840312156149d357600080fd5b8135611d6b81613f88565b6000602082840312156149f057600080fd5b8135611d6b81613fa9565b61ffff8116811461066a57600080fd5b600060208284031215614a1d57600080fd5b8135611d6b816149fb565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614ac560c085018763ffffffff169052565b818482030160e0850152613c8e82820186613d9c565b805169ffffffffffffffffffff81168114610efd57600080fd5b600080600080600060a08688031215614b0d57600080fd5b614b1686614adb565b9450602086015193506040860151925060608601519150614b3960808701614adb565b90509295509295909350565b81810381811115610695576106956148c9565b60ff8181168382160190811115610695576106956148c9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614bb357614bb3614b71565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b8051610efd81614172565b600060208284031215614c3257600080fd5b8151611d6b81614172565b8082028115828204841417610695576106956148c9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614955576149556148c9565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cd08184018a614091565b90508281036080840152614ce48189614091565b905060ff871660a084015282810360c0840152614d018187613d9c565b905067ffffffffffffffff851660e0840152828103610100840152614d268185613d9c565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614d5557614d55614b71565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614955576149556148c9565b6bffffffffffffffffffffffff818116838216028082169190828114614dae57614dae6148c9565b505092915050565b8051610efd81613fa9565b60008060008060008060008060006101208a8c031215614de057600080fd5b8951614deb81613fa9565b60208b0151909950614dfc81613fa9565b60408b0151909850614e0d81613fa9565b60608b0151909750614e1e81613fa9565b60808b0151909650614e2f81613fa9565b9450614e3d60a08b01614adb565b935060c08a0151614e4d816149fb565b8093505060e08a015191506101008a015190509295985092959850929598565b8051610efd81613e13565b600080600080600060a08688031215614e9057600080fd5b8551614e9b81614172565b80955050602080870151614eae81614172565b6040880151909550614ebf81613e13565b6060880151909450614ed081613e13565b608088015190935067ffffffffffffffff811115614eed57600080fd5b8701601f81018913614efe57600080fd5b8051614f0c6145a48261455f565b81815260059190911b8201830190838101908b831115614f2b57600080fd5b928401925b82841015614f52578351614f4381613e13565b82529284019290840190614f30565b80955050505050509295509295909350565b8051610efd81613f88565b600080600060608486031215614f8457600080fd5b83518015158114614f9457600080fd5b6020850151909350614fa581613f88565b6040850151909250614fb681613f88565b809150509250925092565b67ffffffffffffffff818116838216019080821115614955576149556148c9565b80820180821115610695576106956148c9565b600082601f83011261500657600080fd5b813560206150166145a48361455f565b82815260059290921b8401810191818101908684111561503557600080fd5b8286015b848110156145ec5780358352918301918301615039565b600082601f83011261506157600080fd5b813560206150716145a48361455f565b82815260059290921b8401810191818101908684111561509057600080fd5b8286015b848110156145ec57803567ffffffffffffffff8111156150b45760008081fd5b6150c28986838b0101613efa565b845250918301918301615094565b600080600080600060a086880312156150e857600080fd5b853567ffffffffffffffff8082111561510057600080fd5b61510c89838a01614ff5565b9650602088013591508082111561512257600080fd5b61512e89838a01615050565b9550604088013591508082111561514457600080fd5b61515089838a01615050565b9450606088013591508082111561516657600080fd5b61517289838a01615050565b9350608088013591508082111561518857600080fd5b5061519588828901615050565b9150509295509295909350565b6000826151b1576151b1614b71565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151fd8285018b614091565b91508382036080850152615211828a614091565b915060ff881660a085015283820360c085015261522e8288613d9c565b90861660e08501528381036101008501529050614d268185613d9c565b805164ffffffffff81168114610efd57600080fd5b6000610160828403121561527357600080fd5b61527b613e81565b61528483614c15565b815261529260208401614e6d565b60208201526152a360408401614e6d565b60408201526152b460608401614f64565b60608201526152c560808401614db6565b60808201526152d660a08401614c15565b60a08201526152e760c0840161524b565b60c082015260e083015160e0820152610100615304818501614adb565b9082015261012061531684820161524b565b9082015261014061532884820161524b565b908201529392505050565b64ffffffffff818116838216019080821115614955576149556148c9565b60006102008083526153658184018a613d9c565b905082810360208401526153798189613d9c565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153c2905060a08301846142be565b979650505050505050565b600080604083850312156153e057600080fd5b82516153eb816145f7565b60208401519092506141ba8161417256fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b506040516200593e3803806200593e833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516152b36200068b60003960008181610a1901528181610e3c01528181610f1a01528181610ff801528181611a9401528181611cde01528181612eb0015261396a015260006114d101526152b36000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610535578063de9dfa461461053d578063e3d0e71214610550578063f2fde38b1461056357600080fd5b8063b1dc65a4146103f4578063c3f909d414610407578063d227d2451461050557600080fd5b8063aecc12c5116100c8578063aecc12c5146103ac578063af1296d3146103cc578063afcb95d7146103d457600080fd5b80638cc6acce1461035f5780638da5cb5b146103725780639883c10d1461039a57600080fd5b806379ba50971161015b578063814118341161013557806381411834146102b257806381f1b938146102c757806381ff7048146102cf57806385b214cf1461033c57600080fd5b806379ba5097146102845780637f15e1661461028c578063807560311461029f57600080fd5b8063466557181161018c578063466557181461022d578063533989871461025b57806366316d8d1461027157600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac1461021a575b600080fd5b6101c66101c1366004613c04565b610576565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190613caa565b60405180910390f35b6101c6610228366004613cdf565b6105cb565b61024061023b366004613e65565b61066d565b60405169ffffffffffffffffffff9091168152602001610211565b61026361069b565b604051610211929190613f8c565b6101c661027f366004614036565b61091f565b6101c6610ad9565b6101c661029a366004613c04565b610bdb565b6101c66102ad36600461406f565b610c2b565b6102ba610ce2565b60405161021191906140c4565b610204610d51565b61031960015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b61034f61034a3660046140d7565b610e22565b6040519015158152602001610211565b6101c661036d3660046140f0565b610f02565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6007545b604051908152602001610211565b6103bf6103ba36600461412d565b610f87565b604051610211919061428e565b61039e61126b565b604080516001815260006020820181905291810191909152606001610211565b6101c66104023660046142e2565b61135e565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff1661012082015261014001610211565b610518610513366004614399565b611a8f565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611c83565b61051861054b366004613e65565b611cda565b6101c661055e3660046144bb565b611d72565b6101c6610571366004613cdf565b612796565b61057e6127a7565b60008190036105b9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105c6828483614629565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061060657503373ffffffffffffffffffffffffffffffffffffffff8216145b61063c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061066a91613b49565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106d8575b505050505090506000815167ffffffffffffffff81111561072657610726613cfc565b60405190808252806020026020018201604052801561075957816020015b60608152602001906001900390816107445790505b50905060005b825181101561091557600f600084838151811061077e5761077e614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107cb90614588565b9050600003610806576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061081c5761081c614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086990614588565b80601f016020809104026020016040519081016040528092919081815260200182805461089590614588565b80156108e25780601f106108b7576101008083540402835291602001916108e2565b820191906000526020600020905b8154815290600101906020018083116108c557829003601f168201915b50505050508282815181106108f9576108f9614744565b60200260200101819052508061090e906147a2565b905061075f565b5090939092509050565b61092761282a565b806bffffffffffffffffffffffff1660000361095d5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109b7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109e49084906bffffffffffffffffffffffff166147da565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610a3b7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610abc57600080fd5b505af1158015610ad0573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610be36127a7565b6000819003610c1e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105c6828483614629565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c765750610c55336129bb565b8015610c7657503373ffffffffffffffffffffffffffffffffffffffff8416145b610cac576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cdc828483614629565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d4757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d1c575b5050505050905090565b606060108054610d6090614588565b9050600003610d9b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610da890614588565b80601f0160208091040260200160405190810160405280929190818152602001828054610dd490614588565b8015610d475780601f10610df657610100808354040283529160200191610d47565b820191906000526020600020905b815481529060010190602001808311610e0457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e93576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902054610eae57506000919050565b60008281526008602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610ef19084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f71576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610f7a81612aa4565b8051602090910120600755565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461104f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61105c6040830183614806565b9050600003611096576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808460600160208101906110b6919061486b565b67ffffffffffffffff1681526020908101906110d490860186613cdf565b73ffffffffffffffffffffffffffffffffffffffff1681526020016110ff60e0860160c08701614888565b63ffffffff1681523a602090910152905061116b6111206040850185614806565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506111659250505060a08601608087016148b5565b83612dad565b915061117a6020840184613cdf565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3328660600160208101906111ca919061486b565b6111da6040890160208a01613cdf565b6111e760408a018a614806565b6111f760a08c0160808d016148b5565b60a08c013561120c60e08e0160c08f01614888565b8c60405160200161121d919061428e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261125d9998979695949392916148d2565b60405180910390a350919050565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611305573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611329919061499f565b5093505092505082801561134b575061134281426149ef565b8463ffffffff16105b1561135657600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c0135916113b491849163ffffffff851691908e908e908190840183828082843760009201919091525061328592505050565b6113ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146114bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b56565b6114cd8b8b8b8b8b8b61328e565b60007f00000000000000000000000000000000000000000000000000000000000000001561152a5760028260200151836040015161150b9190614a02565b6115159190614a4a565b611520906001614a02565b60ff169050611540565b602082015161153a906001614a02565b60ff1690505b8881146115a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b56565b888714611612576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b56565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561165557611655614a6c565b600281111561166657611666614a6c565b905250905060028160200151600281111561168357611683614a6c565b1480156116ca57506006816000015160ff16815481106116a5576116a5614744565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611730576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b56565b505050505061173d613b83565b6000808a8a604051611750929190614a9b565b604051908190038120611767918e90602001614aab565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611a715760006001848984602081106117d0576117d0614744565b6117dd91901a601b614a02565b8e8e868181106117ef576117ef614744565b905060200201358d8d8781811061180857611808614744565b9050602002013560405160008152602001604052604051611845949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611867573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156118e7576118e7614a6c565b60028111156118f8576118f8614a6c565b905250925060018360200151600281111561191557611915614a6c565b1461197c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b56565b8251600090879060ff16601f811061199657611996614744565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611a18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b56565b8086846000015160ff16601f8110611a3257611a32614744565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611a5d600186614a02565b94505080611a6a906147a2565b90506117b1565b505050611a82833383858e8e61333c565b5050505050505050505050565b6000807f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8916600482015263ffffffff8616602482015290915073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611b3157600080fd5b505afa158015611b45573d6000803e3d6000fd5b50505050620f4240831115611b86576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611c1488888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061066d915050565b69ffffffffffffffffffff1690506000611c6589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611cda915050565b9050611c738787848461350a565b9450505050505b95945050505050565b6060600e8054611c9290614588565b9050600003611ccd576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610da890614588565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611d47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d6b9190614aca565b9392505050565b855185518560ff16601f831115611de5576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b56565b80600003611e4f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b56565b818314611edd576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b56565b611ee8816003614ae7565b8311611f50576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b56565b611f586127a7565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f9f908861367a565b6005541561215457600554600090611fb9906001906149ef565b9050600060058281548110611fd057611fd0614744565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200a5761200a614744565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208a5761208a614afe565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120f3576120f3614afe565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f9f915050565b60005b8151518110156125bb576000600460008460000151848151811061217d5761217d614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121c7576121c7614a6c565b1461222e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b56565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225f5761225f614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561230057612300614a6c565b0217905550600091506123109050565b600460008460200151848151811061232a5761232a614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561237457612374614a6c565b146123db576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b56565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240e5761240e614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124af576124af614a6c565b0217905550508251805160059250839081106124cd576124cd614744565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061254957612549614744565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125b3816147a2565b915050612157565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161267391849174010000000000000000000000000000000000000000900416614b2d565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126d24630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613697565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612789988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614b4a565b60405180910390a1611a82565b61279e6127a7565b61066a81613742565b60005473ffffffffffffffffffffffffffffffffffffffff163314612828576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b56565b565b6000612834610ce2565b90508051600003612871576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d54600091612890916bffffffffffffffffffffffff16614be0565b905060005b825181101561295c5781600c60008584815181106128b5576128b5614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff1661291d9190614c0b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612955906147a2565b9050612895565b5081516129699082614c30565b600d80546000906129899084906bffffffffffffffffffffffff166147da565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a2157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129f6575b5050505050905060005b8151811015612a9a578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5d57612a5d614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a8a575060019392505050565b612a93816147a2565b9050612a2b565b5060009392505050565b600080600080600080600080600089806020019051810190612ac69190614c6b565b98509850985098509850985098509850985060008113612b15576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d99908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260095461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115612e6c576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612e78858461066d565b90506000612e868685611cda565b90506000612eaa856040015186606001518569ffffffffffffffffffff168561350a565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612f4e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612f949190810190614d22565b50505060208a01518a516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015613025573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130499190614e19565b509150506bffffffffffffffffffffffff851661306683856147da565b6bffffffffffffffffffffffff1610156130ac576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061312b308b602001518c600001518560016130c99190614e6b565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b60408051610160810182526bffffffffffffffffffffffff808b168252306020808401919091528e015173ffffffffffffffffffffffffffffffffffffffff16828401528d5167ffffffffffffffff166060830152918d015163ffffffff908116608083015291891660a08201526009549293509160c08301916131c49170010000000000000000000000000000000090041642614e8c565b64ffffffffff168152602080820184905269ffffffffffffffffffff8b1660408084019190915260095463ffffffff680100000000000000008204811660608601526c01000000000000000000000000909104166080909301929092529051919a50613232918b910161428e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260089092529091205550959998505050505050505050565b60019392505050565b600061329b826020614ae7565b6132a6856020614ae7565b6132b288610144614e8c565b6132bc9190614e8c565b6132c69190614e8c565b6132d1906000614e8c565b9050368114610ad0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b56565b60608080808061334e86880188614f7a565b845194995092975090955093509150158061336b57508351855114155b8061337857508251855114155b8061338557508151855114155b8061339257508051855114155b156133c9576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b85518110156134fc5760006134618783815181106133ec576133ec614744565b602002602001015187848151811061340657613406614744565b602002602001015187858151811061342057613420614744565b602002602001015187868151811061343a5761343a614744565b602002602001015187878151811061345457613454614744565b6020026020010151613837565b9050600081600681111561347757613477614a6c565b14806134945750600181600681111561349257613492614a6c565b145b156134eb578682815181106134ab576134ab614744565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b506134f5816147a2565b90506133cc565b505050505050505050505050565b60008061351561126b565b905060008113613554576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b600954600090879061358a9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614b2d565b6135949190614b2d565b63ffffffff1690506000612710600960010154886135b29190614ae7565b6135bc919061504c565b6135c69088614e8c565b9050600083836135de84670de0b6b3a7640000614ae7565b6135e89190614ae7565b6135f2919061504c565b905060006136116bffffffffffffffffffffffff808916908a16614e8c565b9050613629816b033b2e3c9fd0803ce80000006149ef565b821115613662576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61366c8183614e8c565b9a9950505050505050505050565b6000613684610ce2565b5111156136935761369361282a565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136bb99989796959493929190615060565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b56565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808380602001905181019061384e919061510a565b60008881526008602052604090205490915061386e576002915050611c7a565b8060405160200161387f919061428e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526008909352912054146138d1576006915050611c7a565b60006138db61126b565b90506000811361391a576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b60008161392f3a670de0b6b3a7640000614ae7565b613939919061504c565b9050600083610140015184610120015161395391906151dd565b6139649064ffffffffff1683614ae7565b905060007f000000000000000000000000000000000000000000000000000000000000000090506000808273ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288d8d888b610100015169ffffffffffffffffffff16896139ca9190614c0b565b338d6040518763ffffffff1660e01b81526004016139ed969594939291906151fb565b60408051808303816000875af1158015613a0b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a2f9190615277565b9150915060008260ff166006811115613a4a57613a4a614a6c565b90506000816006811115613a6057613a60614a6c565b1480613a7d57506001816006811115613a7b57613a7b614a6c565b145b15613b385760008e815260086020526040812055613a9b8286614c0b565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9384161790556101008a0151600d805469ffffffffffffffffffff90921693909291613b0991859116614c0b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b9d9c50505050505050505050505050565b508054613b5590614588565b6000825580601f10613b65575050565b601f01602090049060005260206000209081019061066a9190613ba2565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613bb75760008155600101613ba3565b5090565b60008083601f840112613bcd57600080fd5b50813567ffffffffffffffff811115613be557600080fd5b602083019150836020828501011115613bfd57600080fd5b9250929050565b60008060208385031215613c1757600080fd5b823567ffffffffffffffff811115613c2e57600080fd5b613c3a85828601613bbb565b90969095509350505050565b6000815180845260005b81811015613c6c57602081850181015186830182015201613c50565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611d6b6020830184613c46565b73ffffffffffffffffffffffffffffffffffffffff8116811461066a57600080fd5b600060208284031215613cf157600080fd5b8135611d6b81613cbd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715613d4f57613d4f613cfc565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d9c57613d9c613cfc565b604052919050565b600082601f830112613db557600080fd5b813567ffffffffffffffff811115613dcf57613dcf613cfc565b613e0060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613d55565b818152846020838601011115613e1557600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461066a57600080fd5b8035610efd81613e32565b63ffffffff8116811461066a57600080fd5b60008082840360a0811215613e7957600080fd5b833567ffffffffffffffff80821115613e9157600080fd5b613e9d87838801613da4565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe084011215613ecf57600080fd5b60405192506080830191508282108183111715613eee57613eee613cfc565b506040526020840135613f0081613e32565b81526040840135613f1081613cbd565b60208201526060840135613f2381613e53565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b83811015613f8157815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613f4f565b509495945050505050565b604081526000613f9f6040830185613f3b565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561400d577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613ffb838351613c46565b94860194925090850190600101613fc1565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461066a57600080fd5b6000806040838503121561404957600080fd5b823561405481613cbd565b915060208301356140648161401c565b809150509250929050565b60008060006040848603121561408457600080fd5b833561408f81613cbd565b9250602084013567ffffffffffffffff8111156140ab57600080fd5b6140b786828701613bbb565b9497909650939450505050565b602081526000611d6b6020830184613f3b565b6000602082840312156140e957600080fd5b5035919050565b60006020828403121561410257600080fd5b813567ffffffffffffffff81111561411957600080fd5b61412584828501613da4565b949350505050565b60006020828403121561413f57600080fd5b813567ffffffffffffffff81111561415657600080fd5b820160e08185031215611d6b57600080fd5b80516bffffffffffffffffffffffff16825260208101516141a1602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408101516141c9604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608101516141e5606084018267ffffffffffffffff169052565b5060808101516141fd608084018263ffffffff169052565b5060a081015161421d60a08401826bffffffffffffffffffffffff169052565b5060c081015161423660c084018264ffffffffff169052565b5060e081015160e08301526101008082015161425f8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610cdc565b61016081016106958284614168565b60008083601f8401126142af57600080fd5b50813567ffffffffffffffff8111156142c757600080fd5b6020830191508360208260051b8501011115613bfd57600080fd5b60008060008060008060008060e0898b0312156142fe57600080fd5b606089018a81111561430f57600080fd5b8998503567ffffffffffffffff8082111561432957600080fd5b6143358c838d01613bbb565b909950975060808b013591508082111561434e57600080fd5b61435a8c838d0161429d565b909750955060a08b013591508082111561437357600080fd5b506143808b828c0161429d565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156143b157600080fd5b85356143bc81613e32565b9450602086013567ffffffffffffffff8111156143d857600080fd5b6143e488828901613bbb565b90955093505060408601356143f881613e53565b949793965091946060013592915050565b600067ffffffffffffffff82111561442357614423613cfc565b5060051b60200190565b600082601f83011261443e57600080fd5b8135602061445361444e83614409565b613d55565b82815260059290921b8401810191818101908684111561447257600080fd5b8286015b8481101561449657803561448981613cbd565b8352918301918301614476565b509695505050505050565b60ff8116811461066a57600080fd5b8035610efd816144a1565b60008060008060008060c087890312156144d457600080fd5b863567ffffffffffffffff808211156144ec57600080fd5b6144f88a838b0161442d565b9750602089013591508082111561450e57600080fd5b61451a8a838b0161442d565b965061452860408a016144b0565b9550606089013591508082111561453e57600080fd5b61454a8a838b01613da4565b945061455860808a01613e48565b935060a089013591508082111561456e57600080fd5b5061457b89828a01613da4565b9150509295509295509295565b600181811c9082168061459c57607f821691505b6020821081036145d5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105c657600081815260208120601f850160051c810160208610156146025750805b601f850160051c820191505b818110156146215782815560010161460e565b505050505050565b67ffffffffffffffff83111561464157614641613cfc565b6146558361464f8354614588565b836145db565b6000601f8411600181146146a757600085156146715750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561473d565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156146f657868501358255602094850194600190920191016146d6565b5086821015614731577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036147d3576147d3614773565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156147ff576147ff614773565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261483b57600080fd5b83018035915067ffffffffffffffff82111561485657600080fd5b602001915036819003821315613bfd57600080fd5b60006020828403121561487d57600080fd5b8135611d6b81613e32565b60006020828403121561489a57600080fd5b8135611d6b81613e53565b61ffff8116811461066a57600080fd5b6000602082840312156148c757600080fd5b8135611d6b816148a5565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a085015261496f60c085018763ffffffff169052565b818482030160e0850152613b3882820186613c46565b805169ffffffffffffffffffff81168114610efd57600080fd5b600080600080600060a086880312156149b757600080fd5b6149c086614985565b94506020860151935060408601519250606086015191506149e360808701614985565b90509295509295909350565b8181038181111561069557610695614773565b60ff818116838216019081111561069557610695614773565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a5d57614a5d614a1b565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b8051610efd8161401c565b600060208284031215614adc57600080fd5b8151611d6b8161401c565b808202811582820484141761069557610695614773565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156147ff576147ff614773565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614b7a8184018a613f3b565b90508281036080840152614b8e8189613f3b565b905060ff871660a084015282810360c0840152614bab8187613c46565b905067ffffffffffffffff851660e0840152828103610100840152614bd08185613c46565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614bff57614bff614a1b565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156147ff576147ff614773565b6bffffffffffffffffffffffff818116838216028082169190828114614c5857614c58614773565b505092915050565b8051610efd81613e53565b60008060008060008060008060006101208a8c031215614c8a57600080fd5b8951614c9581613e53565b60208b0151909950614ca681613e53565b60408b0151909850614cb781613e53565b60608b0151909750614cc881613e53565b60808b0151909650614cd981613e53565b9450614ce760a08b01614985565b935060c08a0151614cf7816148a5565b8093505060e08a015191506101008a015190509295985092959850929598565b8051610efd81613cbd565b600080600080600060a08688031215614d3a57600080fd5b8551614d458161401c565b80955050602080870151614d588161401c565b6040880151909550614d6981613cbd565b6060880151909450614d7a81613cbd565b608088015190935067ffffffffffffffff811115614d9757600080fd5b8701601f81018913614da857600080fd5b8051614db661444e82614409565b81815260059190911b8201830190838101908b831115614dd557600080fd5b928401925b82841015614dfc578351614ded81613cbd565b82529284019290840190614dda565b80955050505050509295509295909350565b8051610efd81613e32565b600080600060608486031215614e2e57600080fd5b83518015158114614e3e57600080fd5b6020850151909350614e4f81613e32565b6040850151909250614e6081613e32565b809150509250925092565b67ffffffffffffffff8181168382160190808211156147ff576147ff614773565b8082018082111561069557610695614773565b600082601f830112614eb057600080fd5b81356020614ec061444e83614409565b82815260059290921b84018101918181019086841115614edf57600080fd5b8286015b848110156144965780358352918301918301614ee3565b600082601f830112614f0b57600080fd5b81356020614f1b61444e83614409565b82815260059290921b84018101918181019086841115614f3a57600080fd5b8286015b8481101561449657803567ffffffffffffffff811115614f5e5760008081fd5b614f6c8986838b0101613da4565b845250918301918301614f3e565b600080600080600060a08688031215614f9257600080fd5b853567ffffffffffffffff80821115614faa57600080fd5b614fb689838a01614e9f565b96506020880135915080821115614fcc57600080fd5b614fd889838a01614efa565b95506040880135915080821115614fee57600080fd5b614ffa89838a01614efa565b9450606088013591508082111561501057600080fd5b61501c89838a01614efa565b9350608088013591508082111561503257600080fd5b5061503f88828901614efa565b9150509295509295909350565b60008261505b5761505b614a1b565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526150a78285018b613f3b565b915083820360808501526150bb828a613f3b565b915060ff881660a085015283820360c08501526150d88288613c46565b90861660e08501528381036101008501529050614bd08185613c46565b805164ffffffffff81168114610efd57600080fd5b6000610160828403121561511d57600080fd5b615125613d2b565b61512e83614abf565b815261513c60208401614d17565b602082015261514d60408401614d17565b604082015261515e60608401614e0e565b606082015261516f60808401614c60565b608082015261518060a08401614abf565b60a082015261519160c084016150f5565b60c082015260e083015160e08201526101006151ae818501614985565b908201526101206151c08482016150f5565b908201526101406151d28482016150f5565b908201529392505050565b64ffffffffff8181168382160190808211156147ff576147ff614773565b600061020080835261520f8184018a613c46565b905082810360208401526152238189613c46565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff86166080850152915061526c905060a0830184614168565b979650505050505050565b6000806040838503121561528a57600080fd5b8251615295816144a1565b60208401519092506140648161401c56fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -1056,514 +1056,6 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigSet(log ty return event, nil } -type FunctionsCoordinatorCostExceedsCommitmentIterator struct { - Event *FunctionsCoordinatorCostExceedsCommitment - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorCostExceedsCommitmentIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorCostExceedsCommitment) - 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(FunctionsCoordinatorCostExceedsCommitment) - 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 *FunctionsCoordinatorCostExceedsCommitmentIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorCostExceedsCommitmentIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorCostExceedsCommitment struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterCostExceedsCommitment(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorCostExceedsCommitmentIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "CostExceedsCommitment", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorCostExceedsCommitmentIterator{contract: _FunctionsCoordinator.contract, event: "CostExceedsCommitment", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchCostExceedsCommitment(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCostExceedsCommitment, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "CostExceedsCommitment", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorCostExceedsCommitment) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "CostExceedsCommitment", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseCostExceedsCommitment(log types.Log) (*FunctionsCoordinatorCostExceedsCommitment, error) { - event := new(FunctionsCoordinatorCostExceedsCommitment) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "CostExceedsCommitment", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorInsufficientGasProvidedIterator struct { - Event *FunctionsCoordinatorInsufficientGasProvided - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorInsufficientGasProvidedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInsufficientGasProvided) - 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(FunctionsCoordinatorInsufficientGasProvided) - 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 *FunctionsCoordinatorInsufficientGasProvidedIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorInsufficientGasProvidedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorInsufficientGasProvided struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInsufficientGasProvided(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientGasProvidedIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InsufficientGasProvided", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorInsufficientGasProvidedIterator{contract: _FunctionsCoordinator.contract, event: "InsufficientGasProvided", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInsufficientGasProvided(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientGasProvided, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InsufficientGasProvided", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorInsufficientGasProvided) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientGasProvided", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInsufficientGasProvided(log types.Log) (*FunctionsCoordinatorInsufficientGasProvided, error) { - event := new(FunctionsCoordinatorInsufficientGasProvided) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientGasProvided", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorInsufficientSubscriptionBalanceIterator struct { - Event *FunctionsCoordinatorInsufficientSubscriptionBalance - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorInsufficientSubscriptionBalanceIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInsufficientSubscriptionBalance) - 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(FunctionsCoordinatorInsufficientSubscriptionBalance) - 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 *FunctionsCoordinatorInsufficientSubscriptionBalanceIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorInsufficientSubscriptionBalanceIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorInsufficientSubscriptionBalance struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInsufficientSubscriptionBalance(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientSubscriptionBalanceIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InsufficientSubscriptionBalance", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorInsufficientSubscriptionBalanceIterator{contract: _FunctionsCoordinator.contract, event: "InsufficientSubscriptionBalance", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInsufficientSubscriptionBalance(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientSubscriptionBalance, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InsufficientSubscriptionBalance", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorInsufficientSubscriptionBalance) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientSubscriptionBalance", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInsufficientSubscriptionBalance(log types.Log) (*FunctionsCoordinatorInsufficientSubscriptionBalance, error) { - event := new(FunctionsCoordinatorInsufficientSubscriptionBalance) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientSubscriptionBalance", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorInvalidRequestIDIterator struct { - Event *FunctionsCoordinatorInvalidRequestID - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInvalidRequestID) - 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(FunctionsCoordinatorInvalidRequestID) - 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 *FunctionsCoordinatorInvalidRequestIDIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorInvalidRequestID struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InvalidRequestID", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorInvalidRequestIDIterator{contract: _FunctionsCoordinator.contract, event: "InvalidRequestID", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InvalidRequestID", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorInvalidRequestID) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) { - event := new(FunctionsCoordinatorInvalidRequestID) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - type FunctionsCoordinatorOracleRequestIterator struct { Event *FunctionsCoordinatorOracleRequest @@ -2257,14 +1749,6 @@ func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (gene return _FunctionsCoordinator.ParseConfigChanged(log) case _FunctionsCoordinator.abi.Events["ConfigSet"].ID: return _FunctionsCoordinator.ParseConfigSet(log) - case _FunctionsCoordinator.abi.Events["CostExceedsCommitment"].ID: - return _FunctionsCoordinator.ParseCostExceedsCommitment(log) - case _FunctionsCoordinator.abi.Events["InsufficientGasProvided"].ID: - return _FunctionsCoordinator.ParseInsufficientGasProvided(log) - case _FunctionsCoordinator.abi.Events["InsufficientSubscriptionBalance"].ID: - return _FunctionsCoordinator.ParseInsufficientSubscriptionBalance(log) - case _FunctionsCoordinator.abi.Events["InvalidRequestID"].ID: - return _FunctionsCoordinator.ParseInvalidRequestID(log) case _FunctionsCoordinator.abi.Events["OracleRequest"].ID: return _FunctionsCoordinator.ParseOracleRequest(log) case _FunctionsCoordinator.abi.Events["OracleResponse"].ID: @@ -2293,22 +1777,6 @@ func (FunctionsCoordinatorConfigSet) Topic() common.Hash { return common.HexToHash("0x1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05") } -func (FunctionsCoordinatorCostExceedsCommitment) Topic() common.Hash { - return common.HexToHash("0x689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc8") -} - -func (FunctionsCoordinatorInsufficientGasProvided) Topic() common.Hash { - return common.HexToHash("0x357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e0") -} - -func (FunctionsCoordinatorInsufficientSubscriptionBalance) Topic() common.Hash { - return common.HexToHash("0xb83d9204606ee3780daa106ad026c4c2853f5af126edbb8fe15e813e62dbd94d") -} - -func (FunctionsCoordinatorInvalidRequestID) Topic() common.Hash { - return common.HexToHash("0xa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be") -} - func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { return common.HexToHash("0xd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3") } @@ -2410,30 +1878,6 @@ type FunctionsCoordinatorInterface interface { ParseConfigSet(log types.Log) (*FunctionsCoordinatorConfigSet, error) - FilterCostExceedsCommitment(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorCostExceedsCommitmentIterator, error) - - WatchCostExceedsCommitment(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCostExceedsCommitment, requestId [][32]byte) (event.Subscription, error) - - ParseCostExceedsCommitment(log types.Log) (*FunctionsCoordinatorCostExceedsCommitment, error) - - FilterInsufficientGasProvided(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientGasProvidedIterator, error) - - WatchInsufficientGasProvided(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientGasProvided, requestId [][32]byte) (event.Subscription, error) - - ParseInsufficientGasProvided(log types.Log) (*FunctionsCoordinatorInsufficientGasProvided, error) - - FilterInsufficientSubscriptionBalance(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientSubscriptionBalanceIterator, error) - - WatchInsufficientSubscriptionBalance(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientSubscriptionBalance, requestId [][32]byte) (event.Subscription, error) - - ParseInsufficientSubscriptionBalance(log types.Log) (*FunctionsCoordinatorInsufficientSubscriptionBalance, error) - - FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) - - WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) - - ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) - FilterOracleRequest(opts *bind.FilterOpts, requestId [][32]byte, requestingContract []common.Address) (*FunctionsCoordinatorOracleRequestIterator, error) WatchOracleRequest(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOracleRequest, requestId [][32]byte, requestingContract []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index e20f82317d0..a513754933c 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -45,8 +45,8 @@ type IFunctionsRequestCommitment struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200636f3803806200636f833981016040819052620000349162000431565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006ab9350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200024491906200052e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002bc916010919086019062000303565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051620002f5939291906200063a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003a75791602002820160005b838211156200037357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200032d565b8015620003a55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000373565b505b50620003b5929150620003b9565b5090565b5b80821115620003b55760008155600101620003ba565b805161ffff81168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004295762000429620003e8565b604052919050565b600080600080608085870312156200044857600080fd5b6200045385620003d0565b9350602062000464818701620003d0565b60408701519094506001600160a01b03811681146200048257600080fd5b60608701519093506001600160401b0380821115620004a057600080fd5b818801915088601f830112620004b557600080fd5b815181811115620004ca57620004ca620003e8565b620004de601f8201601f19168501620003fe565b91508082528984828501011115620004f557600080fd5b60005b8181101562000515578381018501518382018601528401620004f8565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200054457600080fd5b83516001600160601b03811681146200055c57600080fd5b602085810151919450906001600160e01b0319811681146200057d57600080fd5b60408601519093506001600160401b03808211156200059b57600080fd5b818701915087601f830112620005b057600080fd5b815181811115620005c557620005c5620003e8565b8060051b9150620005d8848301620003fe565b818152918301840191848101908a841115620005f357600080fd5b938501935b838510156200062a578451925063ffffffff83168314620006195760008081fd5b8282529385019390850190620005f8565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b818110156200069d57845163ffffffff168352938301939183019160010162000679565b509098975050505050505050565b608051615ca8620006c760003960006128980152615ca86000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610766578063eb523d6c14610779578063f2fde38b1461078c57600080fd5b8063c4614d611461072d578063d7ae1d3014610740578063e72f6e301461075357600080fd5b8063b5643858116100c8578063b5643858146106fb578063b734c0f41461070e578063badc3eb61461071657600080fd5b8063a9c9a918146106b7578063aab396bd146106ca578063b187bd26146106f057600080fd5b80639883c10d11610150578063a21a23e41161012a578063a21a23e414610678578063a47c769614610680578063a4c0ed36146106a457600080fd5b80639883c10d146106245780639f87fad71461062c578063a1d4c8281461063f57600080fd5b80638456cb59116101815780638456cb59146105f15780638da5cb5b146105f95780638fde53171461061c57600080fd5b806379ba5097146105d657806382359740146105de57600080fd5b80634b8832d31161025557806366419970116102095780636e3b3323116101e35780636e3b3323146105a957806371ec28ac146105bc5780637341c10c146105c357600080fd5b806366419970146104ae578063674603d0146104dc5780636a6df79b1461057157600080fd5b80635c975abb1161023a5780635c975abb146104715780635ed6dfba1461048857806366316d8d1461049b57600080fd5b80634b8832d31461044b57806355fedefa1461045e57600080fd5b80631ded3b36116102b75780633e871e4d116102915780633e871e4d1461040f5780633f4ba83a14610422578063461d27621461042a57600080fd5b80631ded3b36146103d35780632a905ccc146103e6578063385de9ae146103fc57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038a57600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614889565b61079f565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b6103176103473660046148c3565b61082c565b6009546b01000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610330565b6103c66040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614960565b6103176103e1366004614973565b610956565b600f546bffffffffffffffffffffffff1661036d565b61031761040a3660046149e8565b610987565b61031761041d366004614ba1565b610b65565b610317610e5b565b61043d610438366004614c6c565b610e6d565b604051908152602001610330565b610317610459366004614cf0565b610ec1565b61043d61046c366004614889565b610fbe565b60005460ff165b6040519015158152602001610330565b610317610496366004614d43565b610fe2565b6103176104a9366004614d43565b6112b8565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b6105496104ea366004614d71565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b61058461057f366004614dad565b6114df565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105b7366004614dd2565b6114f2565b6064610321565b6103176105d1366004614cf0565b6117c8565b610317611975565b6103176105ec366004614889565b611a97565b610317611be6565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610584565b610317611bf6565b60075461043d565b61031761063a366004614cf0565b611c9e565b61065261064d366004614feb565b6120a6565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610330565b6104c3612390565b61069361068e366004614889565b612524565b6040516103309594939291906150e9565b6103176106b236600461513e565b612610565b6105846106c536600461519a565b61283f565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761043d565b60005460ff16610478565b6103176107093660046151b3565b61284c565b6103176129ad565b61071e612b1b565b604051610330939291906151ce565b6103c661073b3660046149e8565b612bf6565b61031761074e366004614cf0565b612c0b565b61031761076136600461522f565b612c64565b610478610774366004614889565b612e70565b61031761078736600461519a565b612e7b565b61031761079a36600461522f565b613099565b6107a76130aa565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061081e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61082882826130b2565b5050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110610891576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6010805460ff83169081106108a8576108a861524c565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115610951576010805460ff83169081106108f8576108f861524c565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610888565b505050565b61095e6130aa565b61096782613420565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61098f613496565b600061099c84600061351c565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109c65750600754610a3a565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a37919061527b565b90505b8383604051610a4a929190615294565b60405180910390208103610a8a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610aeb9061ffff16436152d3565b9052600086815260066020908152604090912082518155908201516001820190610b159082615387565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b569087908490889088906154a1565b60405180910390a15050505050565b610b6d613496565b8151815181141580610b7f5750600881115b15610bb6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ce2576000848281518110610bd557610bd561524c565b602002602001015190506000848381518110610bf357610bf361524c565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c5e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c95576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccf576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610888565b505080610cdb906154fc565b9050610bb9565b50600954600090610cf79061ffff16436152d3565b604080516060810182528681526020808201879052918101839052865192935091600391610d299183918901906146c9565b506020828101518051610d429260018501920190614710565b506040820151816002015590505060005b8451811015610e54577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610d8f57610d8f61524c565b602002602001015160026000888581518110610dad57610dad61524c565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610df657610df661524c565b602002602001015185604051610e3c949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e4d816154fc565b9050610d53565b5050505050565b610e63613496565b610e6b613613565b565b6000610eb68260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a91506136909050565b979650505050505050565b610ec96139c9565b610ed2826139d1565b610eda613a97565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108285767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b610fea6130aa565b806bffffffffffffffffffffffff166000036110205750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561107a576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906110a79084906bffffffffffffffffffffffff16615534565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166110fe9190615534565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561119d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c19190615560565b61082857600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611234573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611258919061527b565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610888565b6112c06139c9565b806bffffffffffffffffffffffff16600003611308576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611362576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061138f9084906bffffffffffffffffffffffff16615534565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166113e69190615534565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611485573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a99190615560565b610828576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006114eb838361351c565b9392505050565b6114fa6139c9565b60005b818110156109515760008383838181106115195761151961524c565b90506101600201803603810190611530919061557d565b905060008160e001519050600e60008281526020019081526020016000205482604051602001611560919061559a565b60405160208183030381529060405280519060200120146115ad576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156115f2576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611664573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116889190615560565b5060a0830151606084015167ffffffffffffffff166000908152600b6020526040812060010180549091906116cc9084906bffffffffffffffffffffffff16615534565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c6020908152828220606087015167ffffffffffffffff90811684529152919020805460019260099161175891859169010000000000000000009004166156c9565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806117c1906154fc565b90506114fd565b6117d06139c9565b6117d9826139d1565b6117e1613a97565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611856576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff161561189d575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610fb2565b60015473ffffffffffffffffffffffffffffffffffffffff1633146119f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610888565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611a9f6139c9565b611aa7613a97565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611b47576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610888565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611bee613496565b610e6b613b9e565b611bfe613496565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611c60576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611ca66139c9565b611caf826139d1565b611cb7613a97565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d87576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ddc576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611e5757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e2c575b50505050509050600060018251611e6e91906156ea565b905060005b825181101561200a578473ffffffffffffffffffffffffffffffffffffffff16838281518110611ea557611ea561524c565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611ffa576000838381518110611edc57611edc61524c565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611f2257611f2261524c565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b90915260409020600201805480611f9c57611f9c6156fd565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061200a565b612003816154fc565b9050611e73565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000806120b16139c9565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461211a576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e602052604090205461213b5760029150612385565b600e60008460e0015181526020019081526020016000205483604051602001612164919061559a565b60405160208183030381529060405280519060200120146121885760079150612385565b826101400151836080015163ffffffff166121a3919061572c565b64ffffffffff165a10156121ba5760039150612385565b606083015167ffffffffffffffff166000908152600b602052604090205460808401516bffffffffffffffffffffffff909116906121fd9063ffffffff16613bf9565b612207908861574a565b8451612214908890615772565b61221e9190615772565b6bffffffffffffffffffffffff16111561223b5760049150612385565b8260a001516bffffffffffffffffffffffff16612261846080015163ffffffff16613bf9565b61226b908861574a565b8451612278908890615772565b6122829190615772565b6bffffffffffffffffffffffff16111561229f5760059150612385565b60009150600e60008460e0015181526020019081526020016000206000905560006122d98460e001518a8a87608001518860400151613c9b565b80519091506122e95760016122ec565b60005b9250600061231385606001518660a00151876040015188600001518c87602001518d613e15565b9050846060015167ffffffffffffffff168560e001517f45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a836020015189888760000151612360578e612362565b8f5b8860400151604051612378959493929190615797565b60405180910390a3519150505b965096945050505050565b600061239a6139c9565b6123a2613a97565b600980546003906123c3906301000000900467ffffffffffffffff166157f5565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612439578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926124d492600285019290910190614710565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061253586613420565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000093849004811699509290930490911695509183018282801561260057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116125d5575b5050505050905091939590929450565b6126186139c9565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612669576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146126a3576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006126b182840184614889565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661272a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906127618385615772565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff166127b89190615772565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461281f91906152d3565b6040805192835260208301919091520160405180910390a2505050505050565b6000610fdc82600061351c565b612854613496565b60095461ffff808316911603612896576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff1611156128f8576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff9081168083529084166020830152909182019061292590436152d3565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b6129b5613496565b6005544310156129f1576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612b1857600060036000018281548110612a1657612a1661524c565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612a6257612a6261524c565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612b11906154fc565b90506129f4565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612b7b57602002820191906000526020600020905b815481526020019060010190808311612b67575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612be457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612bb9575b50505050509050925092509250909192565b6060612c03848484614067565b949350505050565b612c136139c9565b612c1c826139d1565b612c24613a97565b612c2d82614134565b1561081e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612c6c6130aa565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612cdb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612cff919061527b565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612d66576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610888565b81811015610951576000612d7a82846156ea565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612df5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e199190615560565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b6000610fdc82614134565b612e83613496565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612ebd906152e6565b80601f0160208091040260200160405190810160405280929190818152602001828054612ee9906152e6565b8015612f365780601f10612f0b57610100808354040283529160200191612f36565b820191906000526020600020905b815481529060010190602001808311612f1957829003601f168201915b5050505050815260200160028201548152505090508060400151431015612f89576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81612fae57612f9b8160200151614283565b6020808201518051910120600755613056565b612fb982600061351c565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b8152600401612ff59190614960565b600060405180830381600087803b15801561300f57600080fd5b505af1925050508015613020575060015b613056576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261308d92869261581c565b60405180910390a15050565b6130a1613496565b612b188161437e565b610e6b613496565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561319357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613168575b505050918352505060039190910154602090910152805190915060005b82608001515181101561325457600c6000846080015183815181106131d7576131d761524c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561324d816154fc565b90506131b0565b5067ffffffffffffffff84166000908152600b602052604081208181556001810182905590613286600283018261478a565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff166132b99190615534565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613358573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061337c9190615560565b6133b2576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612b18576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610888565b60008161355b5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613555579050610fdc565b506135de565b60005b6003548110156135dc57600380548290811061357c5761357c61524c565b906000526020600020015484036135cc5760048054829081106135a1576135a161524c565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150610fdc9050565b6135d5816154fc565b905061355e565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610888565b61361b614479565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b600061369a6139c9565b6136a385613420565b6136ad33866144e5565b6136b7858361082c565b60006136c3888861351c565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c500000000000000000000000000000000000000000000000000000000815293945091929184169163aecc12c59161378a91600401615844565b610160604051808303816000875af11580156137aa573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137ce9190615919565b90506137df33888360a00151614581565b604051806101600160405280600f60000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff168152506040516020016138ec919061559a565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152828252805160209182012060e0850180516000908152600e8452848120929092555167ffffffffffffffff8c16808352600b9093529290205490928c92917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54916139b1916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908e908e908e906159ec565b60405180910390a460e0015198975050505050505050565b610e6b61465c565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613a48576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610828576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ac27fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097600061351c565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613b2590339060248101615a50565b602060405180830381865afa158015613b42573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b669190615560565b610e6b576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610888565b613ba661465c565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586136663390565b60006bffffffffffffffffffffffff821115613c97576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610888565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613ce690899089908990602401615a7f565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613d9857600080fd5b5a611388811015613da857600080fd5b611388810390508760408204820311613dc057600080fd5b60008086516020880160008b8df193505a900391503d6084811115613de3575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613e3484613bf9565b613e3e908661574a565b9050600081613e4d8886615772565b613e579190615772565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613eae91859116615534565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613ee89190615772565b336000908152600d602052604081208054909190613f159084906bffffffffffffffffffffffff16615772565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b94509092613f5c91859116615772565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d94509092613fb091859116615534565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161403491859169010000000000000000009004166156c9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6060600080808061407a86880188615ab4565b9350935093509350600061409389600187878787613690565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614127578181602081106140d2576140d261524c565b1a60f81b8782815181106140e8576140e861524c565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350614120816154fc565b90506140b7565b5050505050509392505050565b67ffffffffffffffff81166000908152600b60209081526040808320600201805482518185028101850190935280835284938301828280156141ac57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614181575b5050505050905060005b8151811015614279576000600c60008484815181106141d7576141d761524c565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461426857506001949350505050565b50614272816154fc565b90506141b6565b5060009392505050565b60008060008380602001905181019061429c9190615b27565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c021781558351959850939650919450909261434791601091908601906147a8565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612e6293929190615c10565b3373ffffffffffffffffffffffffffffffffffffffff8216036143fd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610888565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610888565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610828576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906145bb9084906bffffffffffffffffffffffff16615772565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926146319284929004166156c9565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610888565b828054828255906000526020600020908101928215614704579160200282015b828111156147045782518255916020019190600101906146e9565b50613c9792915061484e565b828054828255906000526020600020908101928215614704579160200282015b8281111561470457825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614730565b5080546000825590600052602060002090810190612b18919061484e565b828054828255906000526020600020906007016008900481019282156147045791602002820160005b8382111561481557835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026147d1565b80156148455782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614815565b5050613c979291505b5b80821115613c97576000815560010161484f565b67ffffffffffffffff81168114612b1857600080fd5b803561488481614863565b919050565b60006020828403121561489b57600080fd5b81356114eb81614863565b63ffffffff81168114612b1857600080fd5b8035614884816148a6565b600080604083850312156148d657600080fd5b82356148e181614863565b915060208301356148f1816148a6565b809150509250929050565b6000815180845260005b8181101561492257602081850181015186830182015201614906565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114eb60208301846148fc565b6000806040838503121561498657600080fd5b823561499181614863565b946020939093013593505050565b60008083601f8401126149b157600080fd5b50813567ffffffffffffffff8111156149c957600080fd5b6020830191508360208285010111156149e157600080fd5b9250929050565b6000806000604084860312156149fd57600080fd5b83359250602084013567ffffffffffffffff811115614a1b57600080fd5b614a278682870161499f565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614a8757614a87614a34565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614ad457614ad4614a34565b604052919050565b600067ffffffffffffffff821115614af657614af6614a34565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff81168114612b1857600080fd5b803561488481614b00565b600082601f830112614b3e57600080fd5b81356020614b53614b4e83614adc565b614a8d565b82815260059290921b84018101918181019086841115614b7257600080fd5b8286015b84811015614b96578035614b8981614b00565b8352918301918301614b76565b509695505050505050565b60008060408385031215614bb457600080fd5b823567ffffffffffffffff80821115614bcc57600080fd5b818501915085601f830112614be057600080fd5b81356020614bf0614b4e83614adc565b82815260059290921b84018101918181019089841115614c0f57600080fd5b948201945b83861015614c2d57853582529482019490820190614c14565b96505086013592505080821115614c4357600080fd5b50614c5085828601614b2d565b9150509250929050565b803561ffff8116811461488457600080fd5b60008060008060008060a08789031215614c8557600080fd5b8635614c9081614863565b9550602087013567ffffffffffffffff811115614cac57600080fd5b614cb889828a0161499f565b9096509450614ccb905060408801614c5a565b92506060870135614cdb816148a6565b80925050608087013590509295509295509295565b60008060408385031215614d0357600080fd5b8235614d0e81614863565b915060208301356148f181614b00565b6bffffffffffffffffffffffff81168114612b1857600080fd5b803561488481614d1e565b60008060408385031215614d5657600080fd5b8235614d6181614b00565b915060208301356148f181614d1e565b60008060408385031215614d8457600080fd5b8235614d8f81614b00565b915060208301356148f181614863565b8015158114612b1857600080fd5b60008060408385031215614dc057600080fd5b8235915060208301356148f181614d9f565b60008060208385031215614de557600080fd5b823567ffffffffffffffff80821115614dfd57600080fd5b818501915085601f830112614e1157600080fd5b813581811115614e2057600080fd5b86602061016083028501011115614e3657600080fd5b60209290920196919550909350505050565b600082601f830112614e5957600080fd5b813567ffffffffffffffff811115614e7357614e73614a34565b614ea460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a8d565b818152846020838601011115614eb957600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff81168114612b1857600080fd5b803561488481614ed6565b69ffffffffffffffffffff81168114612b1857600080fd5b803561488481614ef4565b60006101608284031215614f2a57600080fd5b614f32614a63565b9050614f3d82614d38565b8152614f4b60208301614b22565b6020820152614f5c60408301614b22565b6040820152614f6d60608301614879565b6060820152614f7e608083016148b8565b6080820152614f8f60a08301614d38565b60a0820152614fa060c08301614ee9565b60c082015260e082013560e0820152610100614fbd818401614f0c565b90820152610120614fcf838201614ee9565b90820152610140614fe1838201614ee9565b9082015292915050565b600080600080600080610200878903121561500557600080fd5b863567ffffffffffffffff8082111561501d57600080fd5b6150298a838b01614e48565b9750602089013591508082111561503f57600080fd5b5061504c89828a01614e48565b955050604087013561505d81614d1e565b9350606087013561506d81614d1e565b9250608087013561507d81614b00565b915061508c8860a08901614f17565b90509295509295509295565b600081518084526020808501945080840160005b838110156150de57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016150ac565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090610eb690830184615098565b6000806000806060858703121561515457600080fd5b843561515f81614b00565b935060208501359250604085013567ffffffffffffffff81111561518257600080fd5b61518e8782880161499f565b95989497509550505050565b6000602082840312156151ac57600080fd5b5035919050565b6000602082840312156151c557600080fd5b6114eb82614c5a565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561520f578451835293830193918301916001016151f3565b505084810360408601526152238187615098565b98975050505050505050565b60006020828403121561524157600080fd5b81356114eb81614b00565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561528d57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610fdc57610fdc6152a4565b600181811c908216806152fa57607f821691505b602082108103615333577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561095157600081815260208120601f850160051c810160208610156153605750805b601f850160051c820191505b8181101561537f5782815560010161536c565b505050505050565b815167ffffffffffffffff8111156153a1576153a1614a34565b6153b5816153af84546152e6565b84615339565b602080601f83116001811461540857600084156153d25750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561537f565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561545557888601518255948401946001909101908401615436565b508582101561549157878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361552d5761552d6152a4565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615559576155596152a4565b5092915050565b60006020828403121561557257600080fd5b81516114eb81614d9f565b6000610160828403121561559057600080fd5b6114eb8383614f17565b81516bffffffffffffffffffffffff168152610160810160208301516155d8602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615600604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606083015161561c606084018267ffffffffffffffff169052565b506080830151615634608084018263ffffffff169052565b5060a083015161565460a08401826bffffffffffffffffffffffff169052565b5060c083015161566d60c084018264ffffffffff169052565b5060e083015160e0830152610100808401516156968285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff818116838216019080821115615559576155596152a4565b81810381811115610fdc57610fdc6152a4565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b64ffffffffff818116838216019080821115615559576155596152a4565b6bffffffffffffffffffffffff8181168382160280821691908281146156c1576156c16152a4565b6bffffffffffffffffffffffff818116838216019080821115615559576155596152a4565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a0606082015260006157e360a08301856148fc565b828103608084015261522381856148fc565b600067ffffffffffffffff808316818103615812576158126152a4565b6001019392505050565b83815282602082015260606040820152600061583b60608301846148fc565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e0606084015261588f6101008401826148fc565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b805161488481614d1e565b805161488481614b00565b805161488481614863565b8051614884816148a6565b805161488481614ed6565b805161488481614ef4565b6000610160828403121561592c57600080fd5b615934614a63565b61593d836158d7565b815261594b602084016158e2565b602082015261595c604084016158e2565b604082015261596d606084016158ed565b606082015261597e608084016158f8565b608082015261598f60a084016158d7565b60a08201526159a060c08401615903565b60c082015260e083015160e08201526101006159bd81850161590e565b908201526101206159cf848201615903565b908201526101406159e1848201615903565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615a2d60c08301866148fc565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612c0360408301846148fc565b838152606060208201526000615a9860608301856148fc565b8281036040840152615aaa81856148fc565b9695505050505050565b60008060008060808587031215615aca57600080fd5b8435615ad581614863565b9350602085013567ffffffffffffffff811115615af157600080fd5b615afd87828801614e48565b935050615b0c60408601614c5a565b91506060850135615b1c816148a6565b939692955090935050565b600080600060608486031215615b3c57600080fd5b8351615b4781614d1e565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615b7f57600080fd5b604086015190935067ffffffffffffffff811115615b9c57600080fd5b8501601f81018713615bad57600080fd5b8051615bbb614b4e82614adc565b81815260059190911b82018301908381019089831115615bda57600080fd5b928401925b82841015615c01578351615bf2816148a6565b82529284019290840190615bdf565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615c8d57845163ffffffff1683529383019391830191600101615c6b565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200645138038062006451833981016040819052620000349162000431565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006ab9350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200024491906200052e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002bc916010919086019062000303565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051620002f5939291906200063a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003a75791602002820160005b838211156200037357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200032d565b8015620003a55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000373565b505b50620003b5929150620003b9565b5090565b5b80821115620003b55760008155600101620003ba565b805161ffff81168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004295762000429620003e8565b604052919050565b600080600080608085870312156200044857600080fd5b6200045385620003d0565b9350602062000464818701620003d0565b60408701519094506001600160a01b03811681146200048257600080fd5b60608701519093506001600160401b0380821115620004a057600080fd5b818801915088601f830112620004b557600080fd5b815181811115620004ca57620004ca620003e8565b620004de601f8201601f19168501620003fe565b91508082528984828501011115620004f557600080fd5b60005b8181101562000515578381018501518382018601528401620004f8565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200054457600080fd5b83516001600160601b03811681146200055c57600080fd5b602085810151919450906001600160e01b0319811681146200057d57600080fd5b60408601519093506001600160401b03808211156200059b57600080fd5b818701915087601f830112620005b057600080fd5b815181811115620005c557620005c5620003e8565b8060051b9150620005d8848301620003fe565b818152918301840191848101908a841115620005f357600080fd5b938501935b838510156200062a578451925063ffffffff83168314620006195760008081fd5b8282529385019390850190620005f8565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b818110156200069d57845163ffffffff168352938301939183019160010162000679565b509098975050505050505050565b608051615d8a620006c7600039600061297a0152615d8a6000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610766578063eb523d6c14610779578063f2fde38b1461078c57600080fd5b8063c4614d611461072d578063d7ae1d3014610740578063e72f6e301461075357600080fd5b8063b5643858116100c8578063b5643858146106fb578063b734c0f41461070e578063badc3eb61461071657600080fd5b8063a9c9a918146106b7578063aab396bd146106ca578063b187bd26146106f057600080fd5b80639883c10d11610150578063a21a23e41161012a578063a21a23e414610678578063a47c769614610680578063a4c0ed36146106a457600080fd5b80639883c10d146106245780639f87fad71461062c578063a1d4c8281461063f57600080fd5b80638456cb59116101815780638456cb59146105f15780638da5cb5b146105f95780638fde53171461061c57600080fd5b806379ba5097146105d657806382359740146105de57600080fd5b80634b8832d31161025557806366419970116102095780636e3b3323116101e35780636e3b3323146105a957806371ec28ac146105bc5780637341c10c146105c357600080fd5b806366419970146104ae578063674603d0146104dc5780636a6df79b1461057157600080fd5b80635c975abb1161023a5780635c975abb146104715780635ed6dfba1461048857806366316d8d1461049b57600080fd5b80634b8832d31461044b57806355fedefa1461045e57600080fd5b80631ded3b36116102b75780633e871e4d116102915780633e871e4d1461040f5780633f4ba83a14610422578063461d27621461042a57600080fd5b80631ded3b36146103d35780632a905ccc146103e6578063385de9ae146103fc57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038a57600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b61031761031236600461496b565b61079f565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b6103176103473660046149a5565b61082c565b6009546b01000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610330565b6103c66040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614a42565b6103176103e1366004614a55565b610956565b600f546bffffffffffffffffffffffff1661036d565b61031761040a366004614aca565b610987565b61031761041d366004614c83565b610b65565b610317610e5b565b61043d610438366004614d4e565b610e6d565b604051908152602001610330565b610317610459366004614dd2565b610ec1565b61043d61046c36600461496b565b610fbe565b60005460ff165b6040519015158152602001610330565b610317610496366004614e25565b610fe2565b6103176104a9366004614e25565b6112b8565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b6105496104ea366004614e53565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b61058461057f366004614e8f565b6114df565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105b7366004614eb4565b6114f2565b6064610321565b6103176105d1366004614dd2565b6117c8565b610317611975565b6103176105ec36600461496b565b611a97565b610317611be6565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610584565b610317611bf6565b60075461043d565b61031761063a366004614dd2565b611c9e565b61065261064d3660046150cd565b6120a6565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610330565b6104c3612472565b61069361068e36600461496b565b612606565b6040516103309594939291906151cb565b6103176106b2366004615220565b6126f2565b6105846106c536600461527c565b612921565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761043d565b60005460ff16610478565b610317610709366004615295565b61292e565b610317612a8f565b61071e612bfd565b604051610330939291906152b0565b6103c661073b366004614aca565b612cd8565b61031761074e366004614dd2565b612ced565b610317610761366004615311565b612d46565b61047861077436600461496b565b612f52565b61031761078736600461527c565b612f5d565b61031761079a366004615311565b61317b565b6107a761318c565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061081e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108288282613194565b5050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110610891576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6010805460ff83169081106108a8576108a861532e565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115610951576010805460ff83169081106108f8576108f861532e565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610888565b505050565b61095e61318c565b61096782613502565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61098f613578565b600061099c8460006135fe565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109c65750600754610a3a565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a37919061535d565b90505b8383604051610a4a929190615376565b60405180910390208103610a8a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610aeb9061ffff16436153b5565b9052600086815260066020908152604090912082518155908201516001820190610b159082615469565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b56908790849088908890615583565b60405180910390a15050505050565b610b6d613578565b8151815181141580610b7f5750600881115b15610bb6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ce2576000848281518110610bd557610bd561532e565b602002602001015190506000848381518110610bf357610bf361532e565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c5e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c95576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccf576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610888565b505080610cdb906155de565b9050610bb9565b50600954600090610cf79061ffff16436153b5565b604080516060810182528681526020808201879052918101839052865192935091600391610d299183918901906147ab565b506020828101518051610d4292600185019201906147f2565b506040820151816002015590505060005b8451811015610e54577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610d8f57610d8f61532e565b602002602001015160026000888581518110610dad57610dad61532e565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610df657610df661532e565b602002602001015185604051610e3c949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e4d816155de565b9050610d53565b5050505050565b610e63613578565b610e6b6136f5565b565b6000610eb68260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a91506137729050565b979650505050505050565b610ec9613aab565b610ed282613ab3565b610eda613b79565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108285767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b610fea61318c565b806bffffffffffffffffffffffff166000036110205750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561107a576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906110a79084906bffffffffffffffffffffffff16615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166110fe9190615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561119d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c19190615642565b61082857600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611234573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611258919061535d565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610888565b6112c0613aab565b806bffffffffffffffffffffffff16600003611308576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611362576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061138f9084906bffffffffffffffffffffffff16615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166113e69190615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611485573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a99190615642565b610828576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006114eb83836135fe565b9392505050565b6114fa613aab565b60005b818110156109515760008383838181106115195761151961532e565b90506101600201803603810190611530919061565f565b905060008160e001519050600e60008281526020019081526020016000205482604051602001611560919061567c565b60405160208183030381529060405280519060200120146115ad576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156115f2576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611664573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116889190615642565b5060a0830151606084015167ffffffffffffffff166000908152600b6020526040812060010180549091906116cc9084906bffffffffffffffffffffffff16615616565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c6020908152828220606087015167ffffffffffffffff90811684529152919020805460019260099161175891859169010000000000000000009004166157ab565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806117c1906155de565b90506114fd565b6117d0613aab565b6117d982613ab3565b6117e1613b79565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611856576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff161561189d575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610fb2565b60015473ffffffffffffffffffffffffffffffffffffffff1633146119f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610888565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611a9f613aab565b611aa7613b79565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611b47576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610888565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611bee613578565b610e6b613c80565b611bfe613578565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611c60576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611ca6613aab565b611caf82613ab3565b611cb7613b79565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d87576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ddc576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611e5757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e2c575b50505050509050600060018251611e6e91906157cc565b905060005b825181101561200a578473ffffffffffffffffffffffffffffffffffffffff16838281518110611ea557611ea561532e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611ffa576000838381518110611edc57611edc61532e565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611f2257611f2261532e565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b90915260409020600201805480611f9c57611f9c6157df565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061200a565b612003816155de565b9050611e73565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000806120b1613aab565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461211a576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e60205260409020546121af5760025b91508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516121a29392919073ffffffffffffffffffffffffffffffffffffffff938416815291909216602082015260ff91909116604082015260600190565b60405180910390a2612467565b600e60008460e00151815260200190815260200160002054836040516020016121d8919061567c565b60405160208183030381529060405280519060200120146121fa576006612135565b826101400151836080015163ffffffff16612215919061580e565b64ffffffffff165a101561222a576004612135565b606083015167ffffffffffffffff166000908152600b602052604090205460808401516bffffffffffffffffffffffff9091169061226d9063ffffffff16613cdb565b612277908861582c565b8451612284908890615854565b61228e9190615854565b6bffffffffffffffffffffffff16111561231f5760e0830180516000908152600e6020908152604080832092909255915182860151825173ffffffffffffffffffffffffffffffffffffffff9182168152908816938101939093526005918301829052909350907f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1906060016121a2565b8260a001516bffffffffffffffffffffffff16612345846080015163ffffffff16613cdb565b61234f908861582c565b845161235c908890615854565b6123669190615854565b6bffffffffffffffffffffffff161115612381576003612135565b60009150600e60008460e0015181526020019081526020016000206000905560006123bb8460e001518a8a87608001518860400151613d7d565b80519091506123cb5760016123ce565b60005b925060006123f585606001518660a00151876040015188600001518c87602001518d613ef7565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151612442578e612444565b8f5b886040015160405161245a959493929190615879565b60405180910390a3519150505b965096945050505050565b600061247c613aab565b612484613b79565b600980546003906124a5906301000000900467ffffffffffffffff166158d7565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c081018252600080825233602083015291810182905260608101829052919250608082019060405190808252806020026020018201604052801561251b578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926125b6926002850192909101906147f2565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061261786613502565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126e257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116126b7575b5050505050905091939590929450565b6126fa613aab565b600a5473ffffffffffffffffffffffffffffffffffffffff16331461274b576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612785576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006127938284018461496b565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661280c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906128438385615854565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff1661289a9190615854565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461290191906153b5565b6040805192835260208301919091520160405180910390a2505050505050565b6000610fdc8260006135fe565b612936613578565b60095461ffff808316911603612978576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff1611156129da576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff90811680835290841660208301529091820190612a0790436153b5565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a97613578565b600554431015612ad3576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612bfa57600060036000018281548110612af857612af861532e565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612b4457612b4461532e565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612bf3906155de565b9050612ad6565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612c5d57602002820191906000526020600020905b815481526020019060010190808311612c49575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612cc657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612c9b575b50505050509050925092509250909192565b6060612ce5848484614149565b949350505050565b612cf5613aab565b612cfe82613ab3565b612d06613b79565b612d0f82614216565b1561081e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d4e61318c565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612dbd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612de1919061535d565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612e48576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610888565b81811015610951576000612e5c82846157cc565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612ed7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612efb9190615642565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b6000610fdc82614216565b612f65613578565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612f9f906153c8565b80601f0160208091040260200160405190810160405280929190818152602001828054612fcb906153c8565b80156130185780601f10612fed57610100808354040283529160200191613018565b820191906000526020600020905b815481529060010190602001808311612ffb57829003601f168201915b505050505081526020016002820154815250509050806040015143101561306b576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816130905761307d8160200151614365565b6020808201518051910120600755613138565b61309b8260006135fe565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016130d79190614a42565b600060405180830381600087803b1580156130f157600080fd5b505af1925050508015613102575060015b613138576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261316f9286926158fe565b60405180910390a15050565b613183613578565b612bfa81614460565b610e6b613578565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561327557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161324a575b505050918352505060039190910154602090910152805190915060005b82608001515181101561333657600c6000846080015183815181106132b9576132b961532e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561332f816155de565b9050613292565b5067ffffffffffffffff84166000908152600b602052604081208181556001810182905590613368600283018261486c565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff1661339b9190615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561343a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061345e9190615642565b613494576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612bfa576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610888565b60008161363d5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613637579050610fdc565b506136c0565b60005b6003548110156136be57600380548290811061365e5761365e61532e565b906000526020600020015484036136ae5760048054829081106136835761368361532e565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150610fdc9050565b6136b7816155de565b9050613640565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610888565b6136fd61455b565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b600061377c613aab565b61378585613502565b61378f33866145c7565b613799858361082c565b60006137a588886135fe565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c500000000000000000000000000000000000000000000000000000000815293945091929184169163aecc12c59161386c91600401615926565b610160604051808303816000875af115801561388c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138b091906159fb565b90506138c133888360a00151614663565b604051806101600160405280600f60000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff168152506040516020016139ce919061567c565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152828252805160209182012060e0850180516000908152600e8452848120929092555167ffffffffffffffff8c16808352600b9093529290205490928c92917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613a93916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908e908e908e90615ace565b60405180910390a460e0015198975050505050505050565b610e6b61473e565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613b2a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610828576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ba47fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006135fe565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613c0790339060248101615b32565b602060405180830381865afa158015613c24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c489190615642565b610e6b576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610888565b613c8861473e565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137483390565b60006bffffffffffffffffffffffff821115613d79576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610888565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613dc890899089908990602401615b61565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613e7a57600080fd5b5a611388811015613e8a57600080fd5b611388810390508760408204820311613ea257600080fd5b60008086516020880160008b8df193505a900391503d6084811115613ec5575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613f1684613cdb565b613f20908661582c565b9050600081613f2f8886615854565b613f399190615854565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613f9091859116615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613fca9190615854565b336000908152600d602052604081208054909190613ff79084906bffffffffffffffffffffffff16615854565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b9450909261403e91859116615854565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d9450909261409291859116615616565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161411691859169010000000000000000009004166157ab565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6060600080808061415c86880188615b96565b9350935093509350600061417589600187878787613772565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614209578181602081106141b4576141b461532e565b1a60f81b8782815181106141ca576141ca61532e565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350614202816155de565b9050614199565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561428e57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614263575b5050505050905060005b815181101561435b576000600c60008484815181106142b9576142b961532e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461434a57506001949350505050565b50614354816155de565b9050614298565b5060009392505050565b60008060008380602001905181019061437e9190615c09565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092614429916010919086019061488a565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612f4493929190615cf2565b3373ffffffffffffffffffffffffffffffffffffffff8216036144df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610888565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610888565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610828576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b67ffffffffffffffff82166000908152600b60205260408120600101805483929061469d9084906bffffffffffffffffffffffff16615854565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926147139284929004166157ab565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610888565b8280548282559060005260206000209081019282156147e6579160200282015b828111156147e65782518255916020019190600101906147cb565b50613d79929150614930565b8280548282559060005260206000209081019282156147e6579160200282015b828111156147e657825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614812565b5080546000825590600052602060002090810190612bfa9190614930565b828054828255906000526020600020906007016008900481019282156147e65791602002820160005b838211156148f757835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026148b3565b80156149275782816101000a81549063ffffffff02191690556004016020816003010492830192600103026148f7565b5050613d799291505b5b80821115613d795760008155600101614931565b67ffffffffffffffff81168114612bfa57600080fd5b803561496681614945565b919050565b60006020828403121561497d57600080fd5b81356114eb81614945565b63ffffffff81168114612bfa57600080fd5b803561496681614988565b600080604083850312156149b857600080fd5b82356149c381614945565b915060208301356149d381614988565b809150509250929050565b6000815180845260005b81811015614a04576020818501810151868301820152016149e8565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114eb60208301846149de565b60008060408385031215614a6857600080fd5b8235614a7381614945565b946020939093013593505050565b60008083601f840112614a9357600080fd5b50813567ffffffffffffffff811115614aab57600080fd5b602083019150836020828501011115614ac357600080fd5b9250929050565b600080600060408486031215614adf57600080fd5b83359250602084013567ffffffffffffffff811115614afd57600080fd5b614b0986828701614a81565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614b6957614b69614b16565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614bb657614bb6614b16565b604052919050565b600067ffffffffffffffff821115614bd857614bd8614b16565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff81168114612bfa57600080fd5b803561496681614be2565b600082601f830112614c2057600080fd5b81356020614c35614c3083614bbe565b614b6f565b82815260059290921b84018101918181019086841115614c5457600080fd5b8286015b84811015614c78578035614c6b81614be2565b8352918301918301614c58565b509695505050505050565b60008060408385031215614c9657600080fd5b823567ffffffffffffffff80821115614cae57600080fd5b818501915085601f830112614cc257600080fd5b81356020614cd2614c3083614bbe565b82815260059290921b84018101918181019089841115614cf157600080fd5b948201945b83861015614d0f57853582529482019490820190614cf6565b96505086013592505080821115614d2557600080fd5b50614d3285828601614c0f565b9150509250929050565b803561ffff8116811461496657600080fd5b60008060008060008060a08789031215614d6757600080fd5b8635614d7281614945565b9550602087013567ffffffffffffffff811115614d8e57600080fd5b614d9a89828a01614a81565b9096509450614dad905060408801614d3c565b92506060870135614dbd81614988565b80925050608087013590509295509295509295565b60008060408385031215614de557600080fd5b8235614df081614945565b915060208301356149d381614be2565b6bffffffffffffffffffffffff81168114612bfa57600080fd5b803561496681614e00565b60008060408385031215614e3857600080fd5b8235614e4381614be2565b915060208301356149d381614e00565b60008060408385031215614e6657600080fd5b8235614e7181614be2565b915060208301356149d381614945565b8015158114612bfa57600080fd5b60008060408385031215614ea257600080fd5b8235915060208301356149d381614e81565b60008060208385031215614ec757600080fd5b823567ffffffffffffffff80821115614edf57600080fd5b818501915085601f830112614ef357600080fd5b813581811115614f0257600080fd5b86602061016083028501011115614f1857600080fd5b60209290920196919550909350505050565b600082601f830112614f3b57600080fd5b813567ffffffffffffffff811115614f5557614f55614b16565b614f8660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614b6f565b818152846020838601011115614f9b57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff81168114612bfa57600080fd5b803561496681614fb8565b69ffffffffffffffffffff81168114612bfa57600080fd5b803561496681614fd6565b6000610160828403121561500c57600080fd5b615014614b45565b905061501f82614e1a565b815261502d60208301614c04565b602082015261503e60408301614c04565b604082015261504f6060830161495b565b60608201526150606080830161499a565b608082015261507160a08301614e1a565b60a082015261508260c08301614fcb565b60c082015260e082013560e082015261010061509f818401614fee565b908201526101206150b1838201614fcb565b908201526101406150c3838201614fcb565b9082015292915050565b60008060008060008061020087890312156150e757600080fd5b863567ffffffffffffffff808211156150ff57600080fd5b61510b8a838b01614f2a565b9750602089013591508082111561512157600080fd5b5061512e89828a01614f2a565b955050604087013561513f81614e00565b9350606087013561514f81614e00565b9250608087013561515f81614be2565b915061516e8860a08901614ff9565b90509295509295509295565b600081518084526020808501945080840160005b838110156151c057815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161518e565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090610eb69083018461517a565b6000806000806060858703121561523657600080fd5b843561524181614be2565b935060208501359250604085013567ffffffffffffffff81111561526457600080fd5b61527087828801614a81565b95989497509550505050565b60006020828403121561528e57600080fd5b5035919050565b6000602082840312156152a757600080fd5b6114eb82614d3c565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156152f1578451835293830193918301916001016152d5565b50508481036040860152615305818761517a565b98975050505050505050565b60006020828403121561532357600080fd5b81356114eb81614be2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561536f57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610fdc57610fdc615386565b600181811c908216806153dc57607f821691505b602082108103615415577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561095157600081815260208120601f850160051c810160208610156154425750805b601f850160051c820191505b818110156154615782815560010161544e565b505050505050565b815167ffffffffffffffff81111561548357615483614b16565b6154978161549184546153c8565b8461541b565b602080601f8311600181146154ea57600084156154b45750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615461565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561553757888601518255948401946001909101908401615518565b508582101561557357878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361560f5761560f615386565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561563b5761563b615386565b5092915050565b60006020828403121561565457600080fd5b81516114eb81614e81565b6000610160828403121561567257600080fd5b6114eb8383614ff9565b81516bffffffffffffffffffffffff168152610160810160208301516156ba602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516156e2604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516156fe606084018267ffffffffffffffff169052565b506080830151615716608084018263ffffffff169052565b5060a083015161573660a08401826bffffffffffffffffffffffff169052565b5060c083015161574f60c084018264ffffffffff169052565b5060e083015160e0830152610100808401516157788285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff81811683821601908082111561563b5761563b615386565b81810381811115610fdc57610fdc615386565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b64ffffffffff81811683821601908082111561563b5761563b615386565b6bffffffffffffffffffffffff8181168382160280821691908281146157a3576157a3615386565b6bffffffffffffffffffffffff81811683821601908082111561563b5761563b615386565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a0606082015260006158c560a08301856149de565b828103608084015261530581856149de565b600067ffffffffffffffff8083168181036158f4576158f4615386565b6001019392505050565b83815282602082015260606040820152600061591d60608301846149de565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e060608401526159716101008401826149de565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b805161496681614e00565b805161496681614be2565b805161496681614945565b805161496681614988565b805161496681614fb8565b805161496681614fd6565b60006101608284031215615a0e57600080fd5b615a16614b45565b615a1f836159b9565b8152615a2d602084016159c4565b6020820152615a3e604084016159c4565b6040820152615a4f606084016159cf565b6060820152615a60608084016159da565b6080820152615a7160a084016159b9565b60a0820152615a8260c084016159e5565b60c082015260e083015160e0820152610100615a9f8185016159f0565b90820152610120615ab18482016159e5565b90820152610140615ac38482016159e5565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615b0f60c08301866149de565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612ce560408301846149de565b838152606060208201526000615b7a60608301856149de565b8281036040840152615b8c81856149de565b9695505050505050565b60008060008060808587031215615bac57600080fd5b8435615bb781614945565b9350602085013567ffffffffffffffff811115615bd357600080fd5b615bdf87828801614f2a565b935050615bee60408601614d3c565b91506060850135615bfe81614988565b939692955090935050565b600080600060608486031215615c1e57600080fd5b8351615c2981614e00565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615c6157600080fd5b604086015190935067ffffffffffffffff811115615c7e57600080fd5b8501601f81018713615c8f57600080fd5b8051615c9d614c3082614bbe565b81815260059190911b82018301908381019089831115615cbc57600080fd5b928401925b82841015615ce3578351615cd481614988565b82529284019290840190615cc1565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615d6f57845163ffffffff1683529383019391830191600101615d4d565b50909897505050505050505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -2038,8 +2038,8 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParsePaused(log types.Log) (*Fu return event, nil } -type FunctionsRouterRequestEndIterator struct { - Event *FunctionsRouterRequestEnd +type FunctionsRouterRequestNotProcessedIterator struct { + Event *FunctionsRouterRequestNotProcessed contract *bind.BoundContract event string @@ -2050,7 +2050,7 @@ type FunctionsRouterRequestEndIterator struct { fail error } -func (it *FunctionsRouterRequestEndIterator) Next() bool { +func (it *FunctionsRouterRequestNotProcessedIterator) Next() bool { if it.fail != nil { return false @@ -2059,7 +2059,7 @@ func (it *FunctionsRouterRequestEndIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsRouterRequestEnd) + it.Event = new(FunctionsRouterRequestNotProcessed) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2074,7 +2074,7 @@ func (it *FunctionsRouterRequestEndIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsRouterRequestEnd) + it.Event = new(FunctionsRouterRequestNotProcessed) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -2089,16 +2089,146 @@ func (it *FunctionsRouterRequestEndIterator) Next() bool { } } -func (it *FunctionsRouterRequestEndIterator) Error() error { +func (it *FunctionsRouterRequestNotProcessedIterator) Error() error { return it.fail } -func (it *FunctionsRouterRequestEndIterator) Close() error { +func (it *FunctionsRouterRequestNotProcessedIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsRouterRequestEnd struct { +type FunctionsRouterRequestNotProcessed struct { + RequestId [32]byte + Coordinator common.Address + Transmitter common.Address + ResultCode uint8 + Raw types.Log +} + +func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestNotProcessed(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRouterRequestNotProcessedIterator, error) { + + var requestIdRule []interface{} + for _, requestIdItem := range requestId { + requestIdRule = append(requestIdRule, requestIdItem) + } + + logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "RequestNotProcessed", requestIdRule) + if err != nil { + return nil, err + } + return &FunctionsRouterRequestNotProcessedIterator{contract: _FunctionsRouter.contract, event: "RequestNotProcessed", logs: logs, sub: sub}, nil +} + +func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestNotProcessed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestNotProcessed, requestId [][32]byte) (event.Subscription, error) { + + var requestIdRule []interface{} + for _, requestIdItem := range requestId { + requestIdRule = append(requestIdRule, requestIdItem) + } + + logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "RequestNotProcessed", requestIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsRouterRequestNotProcessed) + if err := _FunctionsRouter.contract.UnpackLog(event, "RequestNotProcessed", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestNotProcessed(log types.Log) (*FunctionsRouterRequestNotProcessed, error) { + event := new(FunctionsRouterRequestNotProcessed) + if err := _FunctionsRouter.contract.UnpackLog(event, "RequestNotProcessed", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FunctionsRouterRequestProcessedIterator struct { + Event *FunctionsRouterRequestProcessed + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsRouterRequestProcessedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsRouterRequestProcessed) + 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(FunctionsRouterRequestProcessed) + 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 *FunctionsRouterRequestProcessedIterator) Error() error { + return it.fail +} + +func (it *FunctionsRouterRequestProcessedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsRouterRequestProcessed struct { RequestId [32]byte SubscriptionId uint64 TotalCostJuels *big.Int @@ -2109,7 +2239,7 @@ type FunctionsRouterRequestEnd struct { Raw types.Log } -func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestEnd(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestEndIterator, error) { +func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestProcessed(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestProcessedIterator, error) { var requestIdRule []interface{} for _, requestIdItem := range requestId { @@ -2120,14 +2250,14 @@ func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestEnd(opts *bind.Fil subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) } - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "RequestEnd", requestIdRule, subscriptionIdRule) + logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "RequestProcessed", requestIdRule, subscriptionIdRule) if err != nil { return nil, err } - return &FunctionsRouterRequestEndIterator{contract: _FunctionsRouter.contract, event: "RequestEnd", logs: logs, sub: sub}, nil + return &FunctionsRouterRequestProcessedIterator{contract: _FunctionsRouter.contract, event: "RequestProcessed", logs: logs, sub: sub}, nil } -func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestEnd(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestEnd, requestId [][32]byte, subscriptionId []uint64) (event.Subscription, error) { +func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestProcessed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestProcessed, requestId [][32]byte, subscriptionId []uint64) (event.Subscription, error) { var requestIdRule []interface{} for _, requestIdItem := range requestId { @@ -2138,7 +2268,7 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestEnd(opts *bind.Watc subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) } - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "RequestEnd", requestIdRule, subscriptionIdRule) + logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "RequestProcessed", requestIdRule, subscriptionIdRule) if err != nil { return nil, err } @@ -2148,8 +2278,8 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestEnd(opts *bind.Watc select { case log := <-logs: - event := new(FunctionsRouterRequestEnd) - if err := _FunctionsRouter.contract.UnpackLog(event, "RequestEnd", log); err != nil { + event := new(FunctionsRouterRequestProcessed) + if err := _FunctionsRouter.contract.UnpackLog(event, "RequestProcessed", log); err != nil { return err } event.Raw = log @@ -2170,9 +2300,9 @@ func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestEnd(opts *bind.Watc }), nil } -func (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestEnd(log types.Log) (*FunctionsRouterRequestEnd, error) { - event := new(FunctionsRouterRequestEnd) - if err := _FunctionsRouter.contract.UnpackLog(event, "RequestEnd", log); err != nil { +func (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestProcessed(log types.Log) (*FunctionsRouterRequestProcessed, error) { + event := new(FunctionsRouterRequestProcessed) + if err := _FunctionsRouter.contract.UnpackLog(event, "RequestProcessed", log); err != nil { return nil, err } event.Raw = log @@ -3743,8 +3873,10 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig return _FunctionsRouter.ParseOwnershipTransferred(log) case _FunctionsRouter.abi.Events["Paused"].ID: return _FunctionsRouter.ParsePaused(log) - case _FunctionsRouter.abi.Events["RequestEnd"].ID: - return _FunctionsRouter.ParseRequestEnd(log) + case _FunctionsRouter.abi.Events["RequestNotProcessed"].ID: + return _FunctionsRouter.ParseRequestNotProcessed(log) + case _FunctionsRouter.abi.Events["RequestProcessed"].ID: + return _FunctionsRouter.ParseRequestProcessed(log) case _FunctionsRouter.abi.Events["RequestStart"].ID: return _FunctionsRouter.ParseRequestStart(log) case _FunctionsRouter.abi.Events["RequestTimedOut"].ID: @@ -3811,8 +3943,12 @@ func (FunctionsRouterPaused) Topic() common.Hash { return common.HexToHash("0x62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258") } -func (FunctionsRouterRequestEnd) Topic() common.Hash { - return common.HexToHash("0x45bb48b6ec798595a260f114720360b95cc58c94c6ddd37a1acc3896ec94a23a") +func (FunctionsRouterRequestNotProcessed) Topic() common.Hash { + return common.HexToHash("0x1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1") +} + +func (FunctionsRouterRequestProcessed) Topic() common.Hash { + return common.HexToHash("0x47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b") } func (FunctionsRouterRequestStart) Topic() common.Hash { @@ -4016,11 +4152,17 @@ type FunctionsRouterInterface interface { ParsePaused(log types.Log) (*FunctionsRouterPaused, error) - FilterRequestEnd(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestEndIterator, error) + FilterRequestNotProcessed(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRouterRequestNotProcessedIterator, error) + + WatchRequestNotProcessed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestNotProcessed, requestId [][32]byte) (event.Subscription, error) + + ParseRequestNotProcessed(log types.Log) (*FunctionsRouterRequestNotProcessed, error) + + FilterRequestProcessed(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestProcessedIterator, error) - WatchRequestEnd(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestEnd, requestId [][32]byte, subscriptionId []uint64) (event.Subscription, error) + WatchRequestProcessed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestProcessed, requestId [][32]byte, subscriptionId []uint64) (event.Subscription, error) - ParseRequestEnd(log types.Log) (*FunctionsRouterRequestEnd, error) + ParseRequestProcessed(log types.Log) (*FunctionsRouterRequestProcessed, error) FilterRequestStart(opts *bind.FilterOpts, requestId [][32]byte, donId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestStartIterator, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index a3f2602e96f..a311539432c 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,8 +3,8 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../. functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 666319c8b9b06d75db166d87a7338a79e9abe9eff71b73ea905f16f9e7cc95cf functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 9e5662eef996c0572071e12d4ddd82018a8b846b97a048ea962af94c181d8391 -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 04e953ed36312263c903beb630d998386ff9d58e39c662c4afa59b755f8a9c64 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin c8af757c84f65f0e0193824195190fd2976b749e997dc6f5d0e533dbe0fcf162 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 56b680ad59eb95d29358575e9e1cd3e333be5c3e100897abb0c08e61866814ab ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From a5f343e2fed5a2767ce72ae19150d65de3ea60cd Mon Sep 17 00:00:00 2001 From: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Date: Tue, 1 Aug 2023 23:30:06 -0500 Subject: [PATCH 057/270] MAX_CONSUMERS is now configurable (#10035) * MAX_CONSUMERS is now configurable * fixed test * Addressed feedback & updated test * Update pnpm-lock.yaml Added back removed newline * Update pnpm-lock.yaml Fixed unnecessary change * Gas golf: -11379 gas - use internal virtual getter & pass adminFee from Router->Coordinator in args * regenerate geth wrappers --------- Co-authored-by: Justin Kaseman --- .../functions/dev/1_0_0/FunctionsBilling.sol | 30 ++++---- .../dev/1_0_0/FunctionsCoordinator.sol | 3 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 30 ++++---- .../dev/1_0_0/FunctionsSubscriptions.sol | 23 ++---- .../v0.8/functions/dev/1_0_0/HasRouter.sol | 8 +-- .../1_0_0/interfaces/IFunctionsBilling.sol | 6 +- .../interfaces/IFunctionsCoordinator.sol | 1 + .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 20 +++++- .../interfaces/IFunctionsSubscriptions.sol | 6 -- ...Router.sol => IOwnableFunctionsRouter.sol} | 4 +- .../tests/1_0_0/FunctionsRouter.t.sol | 6 +- .../v0.8/functions/v1/FunctionsRouter.test.ts | 14 +++- .../test/v0.8/functions/v1/RouterBase.test.ts | 25 ++++--- contracts/test/v0.8/functions/v1/utils.ts | 4 +- .../functions_coordinator.go | 20 +++--- .../functions_router/functions_router.go | 71 +++++++------------ ...rapper-dependency-versions-do-not-edit.txt | 4 +- .../v1/internal/testutils.go | 4 +- 18 files changed, 144 insertions(+), 135 deletions(-) rename contracts/src/v0.8/functions/dev/1_0_0/interfaces/{IOwnableRouter.sol => IOwnableFunctionsRouter.sol} (61%) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index c4f91a2ea7e..1072a3d8ea3 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -8,6 +8,7 @@ import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; +import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; /** * @title Functions Billing contract @@ -192,12 +193,9 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { /** * @inheritdoc IFunctionsBilling */ - function getAdminFee( - bytes memory /* requestData */, - RequestBilling memory /* billing */ - ) public view override returns (uint96) { - // NOTE: Optionally, compute additional fee here - return IFunctionsRouter(address(_getRouter())).getAdminFee(); + function getAdminFee() public view override returns (uint96) { + IFunctionsRouter.Config memory config = _getRouter().getConfig(); + return config.adminFee; } function getFeedData() public view returns (int256) { @@ -224,14 +222,13 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { uint256 gasPrice ) external view override returns (uint96) { // Reasonable ceilings to prevent integer overflows - IFunctionsRouter router = IFunctionsRouter(address(_getRouter())); - router.isValidCallbackGasLimit(subscriptionId, callbackGasLimit); + _getRouter().isValidCallbackGasLimit(subscriptionId, callbackGasLimit); if (gasPrice > 1_000_000) { revert InvalidCalldata(); } - RequestBilling memory billing = RequestBilling(subscriptionId, msg.sender, callbackGasLimit, gasPrice); + uint96 adminFee = getAdminFee(); + RequestBilling memory billing = RequestBilling(subscriptionId, msg.sender, callbackGasLimit, gasPrice, adminFee); uint96 donFee = getDONFee(data, billing); - uint96 adminFee = getAdminFee(data, billing); return _calculateCostEstimate(callbackGasLimit, gasPrice, donFee, adminFee); } @@ -284,8 +281,12 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { // Check that subscription can afford the estimated cost uint80 donFee = getDONFee(data, billing); - uint96 adminFee = getAdminFee(data, billing); - uint96 estimatedCost = _calculateCostEstimate(billing.callbackGasLimit, billing.expectedGasPrice, donFee, adminFee); + uint96 estimatedCost = _calculateCostEstimate( + billing.callbackGasLimit, + billing.expectedGasPrice, + donFee, + billing.adminFee + ); IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(_getRouter())); (uint96 balance, uint96 blockedBalance, , , ) = subscriptions.getSubscription(billing.subscriptionId); (, uint64 initiatedRequests, ) = subscriptions.getConsumer(billing.client, billing.subscriptionId); @@ -297,7 +298,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { bytes32 requestId = computeRequestId(address(this), billing.client, billing.subscriptionId, initiatedRequests + 1); commitment = IFunctionsRequest.Commitment({ - adminFee: adminFee, + adminFee: billing.adminFee, coordinator: address(this), client: billing.client, subscriptionId: billing.subscriptionId, @@ -363,8 +364,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { ); // The Functions Router will perform the callback to the client contract - IFunctionsRouter router = IFunctionsRouter(address(_getRouter())); - (uint8 result, uint96 callbackCostJuels) = router.fulfill( + (uint8 result, uint96 callbackCostJuels) = _getRouter().fulfill( response, err, uint96(juelsPerGas), diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index f27bb6b0d7b..3c0453b730a 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -154,7 +154,8 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli subscriptionId: request.subscriptionId, client: request.requestingContract, callbackGasLimit: request.callbackGasLimit, - expectedGasPrice: tx.gasprice + expectedGasPrice: tx.gasprice, + adminFee: request.adminFee }); commitment = _startBilling(request.data, request.dataVersion, billing); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index b6cd6cea938..54ac1e73573 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -58,14 +58,6 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // ================================================================ // | Configuration state | // ================================================================ - struct Config { - // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network - uint96 adminFee; - // The function selector that is used when calling back to the Client contract - bytes4 handleOracleFulfillmentSelector; - // List of max callback gas limits used by flag with GAS_FLAG_INDEX - uint32[] maxCallbackGasLimits; - } Config private s_config; event ConfigChanged(uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] maxCallbackGasLimits); @@ -99,8 +91,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions /** * @inheritdoc IFunctionsRouter */ - function getAdminFee() external view override returns (uint96) { - return s_config.adminFee; + function getConfig() external view override returns (Config memory) { + return s_config; } // ================================================================ @@ -112,11 +104,14 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions * - adminFee: fee that will be paid to the Router owner for operating the network */ function _updateConfig(bytes memory config) internal override { - (uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] memory maxCallbackGasLimits) = abi.decode( - config, - (uint96, bytes4, uint32[]) - ); + ( + uint16 maxConsumers, + uint96 adminFee, + bytes4 handleOracleFulfillmentSelector, + uint32[] memory maxCallbackGasLimits + ) = abi.decode(config, (uint16, uint96, bytes4, uint32[])); s_config = Config({ + maxConsumers: maxConsumers, adminFee: adminFee, handleOracleFulfillmentSelector: handleOracleFulfillmentSelector, maxCallbackGasLimits: maxCallbackGasLimits @@ -152,7 +147,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions subscriptionId, dataVersion, _getFlags(subscriptionId), - callbackGasLimit + callbackGasLimit, + s_config.adminFee ) ); @@ -401,6 +397,10 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } } + function _getMaxConsumers() internal view override returns (uint16) { + return s_config.maxConsumers; + } + // ================================================================ // | Modifiers | // ================================================================ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 56bbe344ce1..c1c6743e0b3 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -6,6 +6,7 @@ import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterfa import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; +import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; /** @@ -36,11 +37,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei LinkTokenInterface private s_linkToken; mapping(uint64 subscriptionId => IFunctionsSubscriptions.Subscription) internal s_subscriptions; - - // We need to maintain a list of addresses that can consume a subscription. - // This bound ensures we are able to loop over them as needed. - // Should a user require more consumers, they can use multiple subscriptions. - uint16 private constant MAX_CONSUMERS = 100; mapping(address consumer => mapping(uint64 subscriptionId => IFunctionsSubscriptions.Consumer)) internal s_consumers; event SubscriptionCreated(uint64 indexed subscriptionId, address owner); @@ -90,13 +86,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ // | Getter methods | // ================================================================ - /** - * @inheritdoc IFunctionsSubscriptions - */ - function getMaxConsumers() external pure override returns (uint16) { - return MAX_CONSUMERS; - } - /** * @inheritdoc IFunctionsSubscriptions */ @@ -375,7 +364,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei if (consumerData.initiatedRequests != consumerData.completedRequests) { revert ConsumerRequestsInFlight(); } - // Note bounded by MAX_CONSUMERS + // Note bounded by config.maxConsumers address[] memory consumers = s_subscriptions[subscriptionId].consumers; uint256 lastConsumerIndex = consumers.length - 1; for (uint256 i = 0; i < consumers.length; ++i) { @@ -400,7 +389,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _onlySubscriptionOwner(subscriptionId); _onlySenderThatAcceptedToS(); // Already maxed, cannot add any more consumers. - if (s_subscriptions[subscriptionId].consumers.length == MAX_CONSUMERS) { + if (s_subscriptions[subscriptionId].consumers.length == _getMaxConsumers()) { revert TooManyConsumers(); } if (s_consumers[consumer][subscriptionId].allowed) { @@ -430,7 +419,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function _cancelSubscriptionHelper(uint64 subscriptionId, address to) private { Subscription memory sub = s_subscriptions[subscriptionId]; uint96 balance = sub.balance; - // Note bounded by MAX_CONSUMERS; + // Note bounded by config.maxConsumers // If no consumers, does nothing. for (uint256 i = 0; i < sub.consumers.length; ++i) { delete s_consumers[sub.consumers[i]][subscriptionId]; @@ -452,7 +441,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function _pendingRequestExists(uint64 subscriptionId) internal view returns (bool) { address[] memory consumers = s_subscriptions[subscriptionId].consumers; - // Iterations will not exceed MAX_CONSUMERS + // Iterations will not exceed config.maxConsumers for (uint256 i = 0; i < consumers.length; ++i) { Consumer memory consumer = s_consumers[consumers[i]][subscriptionId]; if (consumer.initiatedRequests != consumer.completedRequests) { @@ -482,6 +471,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei return _getFlags(subscriptionId); } + function _getMaxConsumers() internal view virtual returns (uint16); + // ================================================================ // | Request Timeout Methods | // ================================================================ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol index 9cef8e1d8d4..4f01d0eff5c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol @@ -4,12 +4,12 @@ pragma solidity ^0.8.19; import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; -import {IOwnableRouter} from "./interfaces/IOwnableRouter.sol"; +import {IOwnableFunctionsRouter} from "./interfaces/IOwnableFunctionsRouter.sol"; abstract contract HasRouter is ITypeAndVersion, IConfigurable { bytes32 internal s_configHash; - IOwnableRouter internal immutable s_router; + IOwnableFunctionsRouter internal immutable s_router; error RouterMustBeSet(); error OnlyCallableByRouter(); @@ -22,12 +22,12 @@ abstract contract HasRouter is ITypeAndVersion, IConfigurable { if (router == address(0)) { revert RouterMustBeSet(); } - s_router = IOwnableRouter(router); + s_router = IOwnableFunctionsRouter(router); _updateConfig(config); s_configHash = keccak256(config); } - function _getRouter() internal view returns (IOwnableRouter router) { + function _getRouter() internal view returns (IOwnableFunctionsRouter router) { return s_router; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index f3268229d9b..f727bb192e1 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -15,6 +15,8 @@ interface IFunctionsBilling { uint32 callbackGasLimit; // the expected gas price used to execute the transaction uint256 expectedGasPrice; + // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network + uint96 adminFee; } /** @@ -56,11 +58,9 @@ interface IFunctionsBilling { /** * @notice Determine the fee that will be paid to the Router owner for operating the network - * @param requestData Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - * @param billing The request's billing configuration * @return fee Cost in Juels (1e18) of LINK */ - function getAdminFee(bytes memory requestData, RequestBilling memory billing) external view returns (uint96); + function getAdminFee() external view returns (uint96); /** * @notice Estimate the total cost that will be charged to a subscription to make a request: gas re-reimbursement, plus DON fee, plus Registry fee diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 57462a5b0aa..457d1acd87a 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -15,6 +15,7 @@ interface IFunctionsCoordinator { uint16 dataVersion; // The version of the structure of the encoded data bytes32 flags; // Per-subscription flags uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract can utilize + uint96 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network } /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index f09409a9443..76cd29722df 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -8,6 +8,20 @@ import {IFunctionsRequest} from "./IFunctionsRequest.sol"; * @title Chainlink Functions Router interface. */ interface IFunctionsRouter is IRouterBase { + struct Config { + // Maximum number of consumers which can be added to a single subscription + // This bound ensures we are able to loop over all subscription consumers as needed, + // without exceeding gas limits. + // Should a user require more consumers, they can use multiple subscriptions. + uint16 maxConsumers; + // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network + uint96 adminFee; + // The function selector that is used when calling back to the Client contract + bytes4 handleOracleFulfillmentSelector; + // List of max callback gas limits used by flag with GAS_FLAG_INDEX + uint32[] maxCallbackGasLimits; + } + /** * @notice The identifier of the route to retrieve the address of the access control contract * The access control contract controls which accounts can manage subscriptions @@ -16,10 +30,10 @@ interface IFunctionsRouter is IRouterBase { function getAllowListId() external pure returns (bytes32); /** - * @notice The fee that will be paid to the Router owner for operating the network - * @return fee Cost in Juels (1e18) of LINK + * @notice The router configuration + * @return config - the router configuration */ - function getAdminFee() external view returns (uint96); + function getConfig() external view returns (Config memory); /** * @notice Sends a request (encoded as data) using the provided subscriptionId diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index d22ab447d4c..7a8aaf5685f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -59,12 +59,6 @@ interface IFunctionsSubscriptions { uint64 subscriptionId ) external view returns (bool allowed, uint64 initiatedRequests, uint64 completedRequests); - /** - * @notice Get the maximum number of consumers that can be added to one subscription - * @return maxConsumers - maximum number of consumers that can be added to one subscription - */ - function getMaxConsumers() external view returns (uint16); - /** * @notice Get details about the total amount of LINK within the system * @return totalBalance - total Juels of LINK held by the contract diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol similarity index 61% rename from contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol rename to contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol index 5d98f610ace..8c2ba69ec98 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol @@ -1,12 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IRouterBase} from "./IRouterBase.sol"; +import {IFunctionsRouter} from "./IFunctionsRouter.sol"; import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; /** * @title Chainlink base Router interface with Ownable. */ -interface IOwnableRouter is IOwnable, IRouterBase { +interface IOwnableFunctionsRouter is IOwnable, IFunctionsRouter { } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index 5c415cc5f82..21cdd8342ea 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -3,6 +3,7 @@ pragma solidity ^0.8.0; import {BaseTest} from "./BaseTest.t.sol"; import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; +import {IFunctionsRouter} from "../../dev/1_0_0/interfaces/IFunctionsRouter.sol"; import {FunctionsCoordinator} from "../../dev/1_0_0/FunctionsCoordinator.sol"; import {FunctionsBilling} from "../../dev/1_0_0/FunctionsBilling.sol"; import {MockV3Aggregator} from "../../../tests/MockV3Aggregator.sol"; @@ -16,6 +17,7 @@ contract FunctionsRouterSetup is BaseTest { uint16 internal s_timelockBlocks = 0; uint16 internal s_maximumTimelockBlocks = 20; + uint16 internal s_maxConsumers = 100; uint96 internal s_adminFee = 561724823; bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; @@ -36,7 +38,8 @@ contract FunctionsRouterSetup is BaseTest { maxCallbackGasLimits[0] = type(uint32).max; // First create the struct to get some type safety - FunctionsRouter.Config memory routerConfig = FunctionsRouter.Config({ + IFunctionsRouter.Config memory routerConfig = IFunctionsRouter.Config({ + maxConsumers: s_maxConsumers, adminFee: s_adminFee, handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, maxCallbackGasLimits: maxCallbackGasLimits @@ -44,6 +47,7 @@ contract FunctionsRouterSetup is BaseTest { return abi.encode( + routerConfig.maxConsumers, routerConfig.adminFee, routerConfig.handleOracleFulfillmentSelector, routerConfig.maxCallbackGasLimits diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index 0748735ed05..b954aeced3a 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -19,9 +19,17 @@ describe('Functions Router - Request lifecycle', () => { 'Functions Router v1.0.0', ) }) - it('#adminFee', async () => { - expect(await contracts.router.getAdminFee()).to.be.equal( - functionsRouterConfig.adminFee, + it('#config', async () => { + const config = await contracts.router.getConfig() + expect(config.maxConsumers).to.be.equal( + functionsRouterConfig.maxConsumers, + ) + expect(config.adminFee).to.be.equal(functionsRouterConfig.adminFee) + expect(config.handleOracleFulfillmentSelector).to.be.equal( + functionsRouterConfig.handleOracleFulfillmentSelector, + ) + expect(config.maxCallbackGasLimits.toString()).to.be.equal( + functionsRouterConfig.maxCallbackGasLimits.toString(), ) }) }) diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index c3adfd8b9bf..55c554413ee 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -11,6 +11,7 @@ import { encodeReport, stringToHex, getEventArg, + functionsRouterConfig, } from './utils' const setup = getSetupFactory() @@ -37,8 +38,8 @@ describe('FunctionsRouter - Base', () => { contracts.router.proposeConfigUpdate( ids.routerId, ethers.utils.defaultAbiCoder.encode( - ['uint96', 'bytes4'], - [1, 0x0ca76175], + ['uint16', 'uint96', 'bytes4', 'uint32[]'], + [2000, 1, 0x0ca76175, [300_000, 500_000]], ), ), ).to.emit(contracts.router, 'ConfigProposed') @@ -65,8 +66,8 @@ describe('FunctionsRouter - Base', () => { contracts.router.proposeConfigUpdate( ids.routerId, ethers.utils.defaultAbiCoder.encode( - ['uint96', 'bytes4', 'uint32[]'], - [1, 0x0ca76175, [300_000, 500_000]], + ['uint16', 'uint96', 'bytes4', 'uint32[]'], + [2000, 1, 0x0ca76175, [300_000, 500_000]], ), ), ).to.emit(contracts.router, 'ConfigProposed') @@ -116,9 +117,15 @@ describe('FunctionsRouter - Base', () => { }) it('returns the config set on the Router', async () => { - expect( - await contracts.router.connect(roles.stranger).getAdminFee(), - ).to.equal(0) + const config = await contracts.router.connect(roles.stranger).getConfig() + expect(config.maxConsumers).to.equal(functionsRouterConfig.maxConsumers) + expect(config.adminFee).to.equal(functionsRouterConfig.adminFee) + expect(config.handleOracleFulfillmentSelector).to.equal( + functionsRouterConfig.handleOracleFulfillmentSelector, + ) + expect(config.maxCallbackGasLimits.toString()).to.equal( + functionsRouterConfig.maxCallbackGasLimits.toString(), + ) }) }) @@ -282,8 +289,8 @@ describe('FunctionsRouter - Base', () => { await contracts.router.proposeConfigUpdate( ids.routerId, ethers.utils.defaultAbiCoder.encode( - ['uint96', 'bytes4'], - [20, 0x0ca76175], + ['uint16', 'uint96', 'bytes4', 'uint32[]'], + [2000, 1, 0x0ca76175, [300_000, 500_000]], ), ) await expect( diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index d06f9d11bef..ad3a01b9bd3 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -58,11 +58,13 @@ export const encodeReport = ( } export type FunctionsRouterConfig = { + maxConsumers: number adminFee: number handleOracleFulfillmentSelector: string maxCallbackGasLimits: number[] } export const functionsRouterConfig: FunctionsRouterConfig = { + maxConsumers: 100, adminFee: 0, handleOracleFulfillmentSelector: '0x0ca76175', maxCallbackGasLimits: [300_000, 500_000, 1_000_000], @@ -227,7 +229,7 @@ export function getSetupFactory(): () => { linkEthRate, ) const routerConfigBytes = ethers.utils.defaultAbiCoder.encode( - ['uint96', 'bytes4', 'uint32[]'], + ['uint16', 'uint96', 'bytes4', 'uint32[]'], [...Object.values(functionsRouterConfig)], ) const startingTimelockBlocks = 0 diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 79002bc752d..fe3daaf8e1d 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -35,6 +35,7 @@ type IFunctionsBillingRequestBilling struct { Client common.Address CallbackGasLimit uint32 ExpectedGasPrice *big.Int + AdminFee *big.Int } type IFunctionsCoordinatorRequest struct { @@ -45,6 +46,7 @@ type IFunctionsCoordinatorRequest struct { DataVersion uint16 Flags [32]byte CallbackGasLimit uint32 + AdminFee *big.Int } type IFunctionsRequestCommitment struct { @@ -62,8 +64,8 @@ type IFunctionsRequestCommitment struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b506040516200593e3803806200593e833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516152b36200068b60003960008181610a1901528181610e3c01528181610f1a01528181610ff801528181611a9401528181611cde01528181612eb0015261396a015260006114d101526152b36000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c80638cc6acce116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e14610535578063de9dfa461461053d578063e3d0e71214610550578063f2fde38b1461056357600080fd5b8063b1dc65a4146103f4578063c3f909d414610407578063d227d2451461050557600080fd5b8063aecc12c5116100c8578063aecc12c5146103ac578063af1296d3146103cc578063afcb95d7146103d457600080fd5b80638cc6acce1461035f5780638da5cb5b146103725780639883c10d1461039a57600080fd5b806379ba50971161015b578063814118341161013557806381411834146102b257806381f1b938146102c757806381ff7048146102cf57806385b214cf1461033c57600080fd5b806379ba5097146102845780637f15e1661461028c578063807560311461029f57600080fd5b8063466557181161018c578063466557181461022d578063533989871461025b57806366316d8d1461027157600080fd5b8063083a5466146101b3578063181f5a77146101c857806326ceabac1461021a575b600080fd5b6101c66101c1366004613c04565b610576565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190613caa565b60405180910390f35b6101c6610228366004613cdf565b6105cb565b61024061023b366004613e65565b61066d565b60405169ffffffffffffffffffff9091168152602001610211565b61026361069b565b604051610211929190613f8c565b6101c661027f366004614036565b61091f565b6101c6610ad9565b6101c661029a366004613c04565b610bdb565b6101c66102ad36600461406f565b610c2b565b6102ba610ce2565b60405161021191906140c4565b610204610d51565b61031960015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b61034f61034a3660046140d7565b610e22565b6040519015158152602001610211565b6101c661036d3660046140f0565b610f02565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6007545b604051908152602001610211565b6103bf6103ba36600461412d565b610f87565b604051610211919061428e565b61039e61126b565b604080516001815260006020820181905291810191909152606001610211565b6101c66104023660046142e2565b61135e565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff1661012082015261014001610211565b610518610513366004614399565b611a8f565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611c83565b61051861054b366004613e65565b611cda565b6101c661055e3660046144bb565b611d72565b6101c6610571366004613cdf565b612796565b61057e6127a7565b60008190036105b9576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105c6828483614629565b505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061060657503373ffffffffffffffffffffffffffffffffffffffff8216145b61063c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061066a91613b49565b50565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b6060806000600680548060200260200160405190810160405280929190818152602001828054801561070357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116106d8575b505050505090506000815167ffffffffffffffff81111561072657610726613cfc565b60405190808252806020026020018201604052801561075957816020015b60608152602001906001900390816107445790505b50905060005b825181101561091557600f600084838151811061077e5761077e614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546107cb90614588565b9050600003610806576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f600084838151811061081c5761081c614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086990614588565b80601f016020809104026020016040519081016040528092919081815260200182805461089590614588565b80156108e25780601f106108b7576101008083540402835291602001916108e2565b820191906000526020600020905b8154815290600101906020018083116108c557829003601f168201915b50505050508282815181106108f9576108f9614744565b60200260200101819052508061090e906147a2565b905061075f565b5090939092509050565b61092761282a565b806bffffffffffffffffffffffff1660000361095d5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff808316911610156109b7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906109e49084906bffffffffffffffffffffffff166147da565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610a3b7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610abc57600080fd5b505af1158015610ad0573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b5f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610be36127a7565b6000819003610c1e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105c6828483614629565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610c765750610c55336129bb565b8015610c7657503373ffffffffffffffffffffffffffffffffffffffff8416145b610cac576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610cdc828483614629565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610d4757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610d1c575b5050505050905090565b606060108054610d6090614588565b9050600003610d9b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610da890614588565b80601f0160208091040260200160405190810160405280929190818152602001828054610dd490614588565b8015610d475780601f10610df657610100808354040283529160200191610d47565b820191906000526020600020905b815481529060010190602001808311610e0457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610e93576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902054610eae57506000919050565b60008281526008602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610ef19084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f71576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610f7a81612aa4565b8051602090910120600755565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461104f576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61105c6040830183614806565b9050600003611096576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808460600160208101906110b6919061486b565b67ffffffffffffffff1681526020908101906110d490860186613cdf565b73ffffffffffffffffffffffffffffffffffffffff1681526020016110ff60e0860160c08701614888565b63ffffffff1681523a602090910152905061116b6111206040850185614806565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506111659250505060a08601608087016148b5565b83612dad565b915061117a6020840184613cdf565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3328660600160208101906111ca919061486b565b6111da6040890160208a01613cdf565b6111e760408a018a614806565b6111f760a08c0160808d016148b5565b60a08c013561120c60e08e0160c08f01614888565b8c60405160200161121d919061428e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529082905261125d9998979695949392916148d2565b60405180910390a350919050565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa158015611305573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611329919061499f565b5093505092505082801561134b575061134281426149ef565b8463ffffffff16105b1561135657600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c0135916113b491849163ffffffff851691908e908e908190840183828082843760009201919091525061328592505050565b6113ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146114bf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610b56565b6114cd8b8b8b8b8b8b61328e565b60007f00000000000000000000000000000000000000000000000000000000000000001561152a5760028260200151836040015161150b9190614a02565b6115159190614a4a565b611520906001614a02565b60ff169050611540565b602082015161153a906001614a02565b60ff1690505b8881146115a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610b56565b888714611612576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610b56565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561165557611655614a6c565b600281111561166657611666614a6c565b905250905060028160200151600281111561168357611683614a6c565b1480156116ca57506006816000015160ff16815481106116a5576116a5614744565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611730576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610b56565b505050505061173d613b83565b6000808a8a604051611750929190614a9b565b604051908190038120611767918e90602001614aab565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611a715760006001848984602081106117d0576117d0614744565b6117dd91901a601b614a02565b8e8e868181106117ef576117ef614744565b905060200201358d8d8781811061180857611808614744565b9050602002013560405160008152602001604052604051611845949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611867573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156118e7576118e7614a6c565b60028111156118f8576118f8614a6c565b905250925060018360200151600281111561191557611915614a6c565b1461197c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610b56565b8251600090879060ff16601f811061199657611996614744565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611a18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610b56565b8086846000015160ff16601f8110611a3257611a32614744565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611a5d600186614a02565b94505080611a6a906147a2565b90506117b1565b505050611a82833383858e8e61333c565b5050505050505050505050565b6000807f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8916600482015263ffffffff8616602482015290915073ffffffffffffffffffffffffffffffffffffffff8216906310fc49c19060440160006040518083038186803b158015611b3157600080fd5b505afa158015611b45573d6000803e3d6000fd5b50505050620f4240831115611b86576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600060405180608001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff1681526020018581525090506000611c1488888080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525086925061066d915050565b69ffffffffffffffffffff1690506000611c6589898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611cda915050565b9050611c738787848461350a565b9450505050505b95945050505050565b6060600e8054611c9290614588565b9050600003611ccd576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610da890614588565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015611d47573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d6b9190614aca565b9392505050565b855185518560ff16601f831115611de5576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610b56565b80600003611e4f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610b56565b818314611edd576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610b56565b611ee8816003614ae7565b8311611f50576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610b56565b611f586127a7565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f9f908861367a565b6005541561215457600554600090611fb9906001906149ef565b9050600060058281548110611fd057611fd0614744565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200a5761200a614744565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208a5761208a614afe565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120f3576120f3614afe565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f9f915050565b60005b8151518110156125bb576000600460008460000151848151811061217d5761217d614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121c7576121c7614a6c565b1461222e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610b56565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225f5761225f614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561230057612300614a6c565b0217905550600091506123109050565b600460008460200151848151811061232a5761232a614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561237457612374614a6c565b146123db576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610b56565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240e5761240e614744565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124af576124af614a6c565b0217905550508251805160059250839081106124cd576124cd614744565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061254957612549614744565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125b3816147a2565b915050612157565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161267391849174010000000000000000000000000000000000000000900416614b2d565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126d24630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613697565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612789988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614b4a565b60405180910390a1611a82565b61279e6127a7565b61066a81613742565b60005473ffffffffffffffffffffffffffffffffffffffff163314612828576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b56565b565b6000612834610ce2565b90508051600003612871576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d54600091612890916bffffffffffffffffffffffff16614be0565b905060005b825181101561295c5781600c60008584815181106128b5576128b5614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff1661291d9190614c0b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612955906147a2565b9050612895565b5081516129699082614c30565b600d80546000906129899084906bffffffffffffffffffffffff166147da565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a2157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129f6575b5050505050905060005b8151811015612a9a578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5d57612a5d614744565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a8a575060019392505050565b612a93816147a2565b9050612a2b565b5060009392505050565b600080600080600080600080600089806020019051810190612ac69190614c6b565b98509850985098509850985098509850985060008113612b15576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d99908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260095461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115612e6c576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612e78858461066d565b90506000612e868685611cda565b90506000612eaa856040015186606001518569ffffffffffffffffffff168561350a565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015612f4e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052612f949190810190614d22565b50505060208a01518a516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa158015613025573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906130499190614e19565b509150506bffffffffffffffffffffffff851661306683856147da565b6bffffffffffffffffffffffff1610156130ac576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061312b308b602001518c600001518560016130c99190614e6b565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b60408051610160810182526bffffffffffffffffffffffff808b168252306020808401919091528e015173ffffffffffffffffffffffffffffffffffffffff16828401528d5167ffffffffffffffff166060830152918d015163ffffffff908116608083015291891660a08201526009549293509160c08301916131c49170010000000000000000000000000000000090041642614e8c565b64ffffffffff168152602080820184905269ffffffffffffffffffff8b1660408084019190915260095463ffffffff680100000000000000008204811660608601526c01000000000000000000000000909104166080909301929092529051919a50613232918b910161428e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260089092529091205550959998505050505050505050565b60019392505050565b600061329b826020614ae7565b6132a6856020614ae7565b6132b288610144614e8c565b6132bc9190614e8c565b6132c69190614e8c565b6132d1906000614e8c565b9050368114610ad0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610b56565b60608080808061334e86880188614f7a565b845194995092975090955093509150158061336b57508351855114155b8061337857508251855114155b8061338557508151855114155b8061339257508051855114155b156133c9576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b85518110156134fc5760006134618783815181106133ec576133ec614744565b602002602001015187848151811061340657613406614744565b602002602001015187858151811061342057613420614744565b602002602001015187868151811061343a5761343a614744565b602002602001015187878151811061345457613454614744565b6020026020010151613837565b9050600081600681111561347757613477614a6c565b14806134945750600181600681111561349257613492614a6c565b145b156134eb578682815181106134ab576134ab614744565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b506134f5816147a2565b90506133cc565b505050505050505050505050565b60008061351561126b565b905060008113613554576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b600954600090879061358a9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614b2d565b6135949190614b2d565b63ffffffff1690506000612710600960010154886135b29190614ae7565b6135bc919061504c565b6135c69088614e8c565b9050600083836135de84670de0b6b3a7640000614ae7565b6135e89190614ae7565b6135f2919061504c565b905060006136116bffffffffffffffffffffffff808916908a16614e8c565b9050613629816b033b2e3c9fd0803ce80000006149ef565b821115613662576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61366c8183614e8c565b9a9950505050505050505050565b6000613684610ce2565b5111156136935761369361282a565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136bb99989796959493929190615060565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b56565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808380602001905181019061384e919061510a565b60008881526008602052604090205490915061386e576002915050611c7a565b8060405160200161387f919061428e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526008909352912054146138d1576006915050611c7a565b60006138db61126b565b90506000811361391a576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610b56565b60008161392f3a670de0b6b3a7640000614ae7565b613939919061504c565b9050600083610140015184610120015161395391906151dd565b6139649064ffffffffff1683614ae7565b905060007f000000000000000000000000000000000000000000000000000000000000000090506000808273ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288d8d888b610100015169ffffffffffffffffffff16896139ca9190614c0b565b338d6040518763ffffffff1660e01b81526004016139ed969594939291906151fb565b60408051808303816000875af1158015613a0b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a2f9190615277565b9150915060008260ff166006811115613a4a57613a4a614a6c565b90506000816006811115613a6057613a60614a6c565b1480613a7d57506001816006811115613a7b57613a7b614a6c565b145b15613b385760008e815260086020526040812055613a9b8286614c0b565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9384161790556101008a0151600d805469ffffffffffffffffffff90921693909291613b0991859116614c0b565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b9d9c50505050505050505050505050565b508054613b5590614588565b6000825580601f10613b65575050565b601f01602090049060005260206000209081019061066a9190613ba2565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613bb75760008155600101613ba3565b5090565b60008083601f840112613bcd57600080fd5b50813567ffffffffffffffff811115613be557600080fd5b602083019150836020828501011115613bfd57600080fd5b9250929050565b60008060208385031215613c1757600080fd5b823567ffffffffffffffff811115613c2e57600080fd5b613c3a85828601613bbb565b90969095509350505050565b6000815180845260005b81811015613c6c57602081850181015186830182015201613c50565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000611d6b6020830184613c46565b73ffffffffffffffffffffffffffffffffffffffff8116811461066a57600080fd5b600060208284031215613cf157600080fd5b8135611d6b81613cbd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715613d4f57613d4f613cfc565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d9c57613d9c613cfc565b604052919050565b600082601f830112613db557600080fd5b813567ffffffffffffffff811115613dcf57613dcf613cfc565b613e0060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613d55565b818152846020838601011115613e1557600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461066a57600080fd5b8035610efd81613e32565b63ffffffff8116811461066a57600080fd5b60008082840360a0811215613e7957600080fd5b833567ffffffffffffffff80821115613e9157600080fd5b613e9d87838801613da4565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe084011215613ecf57600080fd5b60405192506080830191508282108183111715613eee57613eee613cfc565b506040526020840135613f0081613e32565b81526040840135613f1081613cbd565b60208201526060840135613f2381613e53565b60408201526080939093013560608401525092909150565b600081518084526020808501945080840160005b83811015613f8157815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613f4f565b509495945050505050565b604081526000613f9f6040830185613f3b565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561400d577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613ffb838351613c46565b94860194925090850190600101613fc1565b50909998505050505050505050565b6bffffffffffffffffffffffff8116811461066a57600080fd5b6000806040838503121561404957600080fd5b823561405481613cbd565b915060208301356140648161401c565b809150509250929050565b60008060006040848603121561408457600080fd5b833561408f81613cbd565b9250602084013567ffffffffffffffff8111156140ab57600080fd5b6140b786828701613bbb565b9497909650939450505050565b602081526000611d6b6020830184613f3b565b6000602082840312156140e957600080fd5b5035919050565b60006020828403121561410257600080fd5b813567ffffffffffffffff81111561411957600080fd5b61412584828501613da4565b949350505050565b60006020828403121561413f57600080fd5b813567ffffffffffffffff81111561415657600080fd5b820160e08185031215611d6b57600080fd5b80516bffffffffffffffffffffffff16825260208101516141a1602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408101516141c9604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608101516141e5606084018267ffffffffffffffff169052565b5060808101516141fd608084018263ffffffff169052565b5060a081015161421d60a08401826bffffffffffffffffffffffff169052565b5060c081015161423660c084018264ffffffffff169052565b5060e081015160e08301526101008082015161425f8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610cdc565b61016081016106958284614168565b60008083601f8401126142af57600080fd5b50813567ffffffffffffffff8111156142c757600080fd5b6020830191508360208260051b8501011115613bfd57600080fd5b60008060008060008060008060e0898b0312156142fe57600080fd5b606089018a81111561430f57600080fd5b8998503567ffffffffffffffff8082111561432957600080fd5b6143358c838d01613bbb565b909950975060808b013591508082111561434e57600080fd5b61435a8c838d0161429d565b909750955060a08b013591508082111561437357600080fd5b506143808b828c0161429d565b999c989b50969995989497949560c00135949350505050565b6000806000806000608086880312156143b157600080fd5b85356143bc81613e32565b9450602086013567ffffffffffffffff8111156143d857600080fd5b6143e488828901613bbb565b90955093505060408601356143f881613e53565b949793965091946060013592915050565b600067ffffffffffffffff82111561442357614423613cfc565b5060051b60200190565b600082601f83011261443e57600080fd5b8135602061445361444e83614409565b613d55565b82815260059290921b8401810191818101908684111561447257600080fd5b8286015b8481101561449657803561448981613cbd565b8352918301918301614476565b509695505050505050565b60ff8116811461066a57600080fd5b8035610efd816144a1565b60008060008060008060c087890312156144d457600080fd5b863567ffffffffffffffff808211156144ec57600080fd5b6144f88a838b0161442d565b9750602089013591508082111561450e57600080fd5b61451a8a838b0161442d565b965061452860408a016144b0565b9550606089013591508082111561453e57600080fd5b61454a8a838b01613da4565b945061455860808a01613e48565b935060a089013591508082111561456e57600080fd5b5061457b89828a01613da4565b9150509295509295509295565b600181811c9082168061459c57607f821691505b6020821081036145d5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105c657600081815260208120601f850160051c810160208610156146025750805b601f850160051c820191505b818110156146215782815560010161460e565b505050505050565b67ffffffffffffffff83111561464157614641613cfc565b6146558361464f8354614588565b836145db565b6000601f8411600181146146a757600085156146715750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561473d565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156146f657868501358255602094850194600190920191016146d6565b5086821015614731577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036147d3576147d3614773565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156147ff576147ff614773565b5092915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261483b57600080fd5b83018035915067ffffffffffffffff82111561485657600080fd5b602001915036819003821315613bfd57600080fd5b60006020828403121561487d57600080fd5b8135611d6b81613e32565b60006020828403121561489a57600080fd5b8135611d6b81613e53565b61ffff8116811461066a57600080fd5b6000602082840312156148c757600080fd5b8135611d6b816148a5565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a085015261496f60c085018763ffffffff169052565b818482030160e0850152613b3882820186613c46565b805169ffffffffffffffffffff81168114610efd57600080fd5b600080600080600060a086880312156149b757600080fd5b6149c086614985565b94506020860151935060408601519250606086015191506149e360808701614985565b90509295509295909350565b8181038181111561069557610695614773565b60ff818116838216019081111561069557610695614773565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a5d57614a5d614a1b565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b8051610efd8161401c565b600060208284031215614adc57600080fd5b8151611d6b8161401c565b808202811582820484141761069557610695614773565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156147ff576147ff614773565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614b7a8184018a613f3b565b90508281036080840152614b8e8189613f3b565b905060ff871660a084015282810360c0840152614bab8187613c46565b905067ffffffffffffffff851660e0840152828103610100840152614bd08185613c46565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614bff57614bff614a1b565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156147ff576147ff614773565b6bffffffffffffffffffffffff818116838216028082169190828114614c5857614c58614773565b505092915050565b8051610efd81613e53565b60008060008060008060008060006101208a8c031215614c8a57600080fd5b8951614c9581613e53565b60208b0151909950614ca681613e53565b60408b0151909850614cb781613e53565b60608b0151909750614cc881613e53565b60808b0151909650614cd981613e53565b9450614ce760a08b01614985565b935060c08a0151614cf7816148a5565b8093505060e08a015191506101008a015190509295985092959850929598565b8051610efd81613cbd565b600080600080600060a08688031215614d3a57600080fd5b8551614d458161401c565b80955050602080870151614d588161401c565b6040880151909550614d6981613cbd565b6060880151909450614d7a81613cbd565b608088015190935067ffffffffffffffff811115614d9757600080fd5b8701601f81018913614da857600080fd5b8051614db661444e82614409565b81815260059190911b8201830190838101908b831115614dd557600080fd5b928401925b82841015614dfc578351614ded81613cbd565b82529284019290840190614dda565b80955050505050509295509295909350565b8051610efd81613e32565b600080600060608486031215614e2e57600080fd5b83518015158114614e3e57600080fd5b6020850151909350614e4f81613e32565b6040850151909250614e6081613e32565b809150509250925092565b67ffffffffffffffff8181168382160190808211156147ff576147ff614773565b8082018082111561069557610695614773565b600082601f830112614eb057600080fd5b81356020614ec061444e83614409565b82815260059290921b84018101918181019086841115614edf57600080fd5b8286015b848110156144965780358352918301918301614ee3565b600082601f830112614f0b57600080fd5b81356020614f1b61444e83614409565b82815260059290921b84018101918181019086841115614f3a57600080fd5b8286015b8481101561449657803567ffffffffffffffff811115614f5e5760008081fd5b614f6c8986838b0101613da4565b845250918301918301614f3e565b600080600080600060a08688031215614f9257600080fd5b853567ffffffffffffffff80821115614faa57600080fd5b614fb689838a01614e9f565b96506020880135915080821115614fcc57600080fd5b614fd889838a01614efa565b95506040880135915080821115614fee57600080fd5b614ffa89838a01614efa565b9450606088013591508082111561501057600080fd5b61501c89838a01614efa565b9350608088013591508082111561503257600080fd5b5061503f88828901614efa565b9150509295509295909350565b60008261505b5761505b614a1b565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526150a78285018b613f3b565b915083820360808501526150bb828a613f3b565b915060ff881660a085015283820360c08501526150d88288613c46565b90861660e08501528381036101008501529050614bd08185613c46565b805164ffffffffff81168114610efd57600080fd5b6000610160828403121561511d57600080fd5b615125613d2b565b61512e83614abf565b815261513c60208401614d17565b602082015261514d60408401614d17565b604082015261515e60608401614e0e565b606082015261516f60808401614c60565b608082015261518060a08401614abf565b60a082015261519160c084016150f5565b60c082015260e083015160e08201526101006151ae818501614985565b908201526101206151c08482016150f5565b908201526101406151d28482016150f5565b908201529392505050565b64ffffffffff8181168382160190808211156147ff576147ff614773565b600061020080835261520f8184018a613c46565b905082810360208401526152238189613c46565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff86166080850152915061526c905060a0830184614168565b979650505050505050565b6000806040838503121561528a57600080fd5b8251615295816144a1565b60208401519092506140648161401c56fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005adb38038062005adb833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516154506200068b6000396000818161069101528181610ac801528181610eeb01528181610fc9015281816118cb01528181611b650152818161313d015261399a0152600061129c01526154506000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806385b214cf116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610526578063d328a91e14610539578063e3d0e71214610541578063f2fde38b1461055457600080fd5b8063b1dc65a4146103f5578063bdd7e88014610408578063c3f909d41461042857600080fd5b80639883c10d116100c85780639883c10d146103bb578063af1296d3146103cd578063afcb95d7146103d557600080fd5b806385b214cf1461035d5780638cc6acce146103805780638da5cb5b1461039357600080fd5b806366316d8d1161015b578063807560311161013557806380756031146102c057806381411834146102d357806381f1b938146102e857806381ff7048146102f057600080fd5b806366316d8d1461029257806379ba5097146102a55780637f15e166146102ad57600080fd5b806326ceabac1161018c57806326ceabac146102445780632a905ccc14610257578063533989871461027c57600080fd5b8063083a5466146101b35780630e7ada39146101c8578063181f5a77146101fb575b600080fd5b6101c66101c1366004613c2d565b610567565b005b6101db6101d6366004613e5a565b6105bc565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b6102376040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101f29190613f8f565b6101c6610252366004613fa9565b6105ea565b61025f61068c565b6040516bffffffffffffffffffffffff90911681526020016101f2565b61028461074a565b6040516101f2929190614017565b6101c66102a03660046140a7565b6109ce565b6101c6610b88565b6101c66102bb366004613c2d565b610c8a565b6101c66102ce3660046140e0565b610cda565b6102db610d91565b6040516101f29190614135565b610237610e00565b61033a60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101f2565b61037061036b366004614148565b610ed1565b60405190151581526020016101f2565b6101c661038e366004614161565b610fb1565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101f2565b6007545b6040519081526020016101f2565b6103bf611036565b6040805160018152600060208201819052918101919091526060016101f2565b6101c66104033660046141e3565b611129565b61041b61041636600461429a565b61185a565b6040516101f291906143fc565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101f2565b61025f61053436600461440b565b611b61565b610237611d2d565b6101c661054f36600461452d565b611d84565b6101c6610562366004613fa9565b6127a8565b61056f6127b9565b60008190036105aa576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105b782848361469b565b505050565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061062557503373ffffffffffffffffffffffffffffffffffffffff8216145b61065b576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061068991613b72565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106fa573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261074091908101906147dc565b6020015192915050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107b257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610787575b505050505090506000815167ffffffffffffffff8111156107d5576107d5613c6f565b60405190808252806020026020018201604052801561080857816020015b60608152602001906001900390816107f35790505b50905060005b82518110156109c457600f600084838151811061082d5761082d614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461087a906145fa565b90506000036108b5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f60008483815181106108cb576108cb614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610918906145fa565b80601f0160208091040260200160405190810160405280929190818152602001828054610944906145fa565b80156109915780601f1061096657610100808354040283529160200191610991565b820191906000526020600020905b81548152906001019060200180831161097457829003601f168201915b50505050508282815181106109a8576109a8614906565b6020026020010181905250806109bd90614964565b905061080e565b5090939092509050565b6109d661283c565b806bffffffffffffffffffffffff16600003610a0c5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff80831691161015610a66576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c602052604081208054839290610a939084906bffffffffffffffffffffffff1661499c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610aea7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b6b57600080fd5b505af1158015610b7f573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610c0e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c926127b9565b6000819003610ccd576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105b782848361469b565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d255750610d04336129cd565b8015610d2557503373ffffffffffffffffffffffffffffffffffffffff8416145b610d5b576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610d8b82848361469b565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610df657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dcb575b5050505050905090565b606060108054610e0f906145fa565b9050600003610e4a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610e57906145fa565b80601f0160208091040260200160405190810160405280929190818152602001828054610e83906145fa565b8015610df65780601f10610ea557610100808354040283529160200191610df6565b820191906000526020600020905b815481529060010190602001808311610eb357509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f42576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902054610f5d57506000919050565b60008281526008602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610fa09084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611020576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61102981612ab6565b8051602090910120600755565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110d0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110f491906149e2565b50935050925050828015611116575061110d8142614a32565b8463ffffffff16105b1561112157600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161117f91849163ffffffff851691908e908e9081908401838280828437600092019190915250612dbf92505050565b6111b5576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461128a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610c05565b6112988b8b8b8b8b8b612dc8565b60007f0000000000000000000000000000000000000000000000000000000000000000156112f5576002826020015183604001516112d69190614a45565b6112e09190614a8d565b6112eb906001614a45565b60ff16905061130b565b6020820151611305906001614a45565b60ff1690505b888114611374576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610c05565b8887146113dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610c05565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561142057611420614aaf565b600281111561143157611431614aaf565b905250905060028160200151600281111561144e5761144e614aaf565b14801561149557506006816000015160ff168154811061147057611470614906565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610c05565b5050505050611508613bac565b6000808a8a60405161151b929190614ade565b604051908190038120611532918e90602001614aee565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561183c57600060018489846020811061159b5761159b614906565b6115a891901a601b614a45565b8e8e868181106115ba576115ba614906565b905060200201358d8d878181106115d3576115d3614906565b9050602002013560405160008152602001604052604051611610949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611632573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156116b2576116b2614aaf565b60028111156116c3576116c3614aaf565b90525092506001836020015160028111156116e0576116e0614aaf565b14611747576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610c05565b8251600090879060ff16601f811061176157611761614906565b602002015173ffffffffffffffffffffffffffffffffffffffff16146117e3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610c05565b8086846000015160ff16601f81106117fd576117fd614906565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611828600186614a45565b9450508061183590614964565b905061157c565b50505061184d833383858e8e612e76565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611922576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61192f6040830183614b02565b9050600003611969576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a001604052808460600160208101906119899190614b67565b67ffffffffffffffff1681526020908101906119a790860186613fa9565b73ffffffffffffffffffffffffffffffffffffffff1681526020016119d260e0860160c08701614b84565b63ffffffff1681523a60208201526040016119f4610100860160e08701614ba1565b6bffffffffffffffffffffffff1690529050611a61611a166040850185614b02565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a5b9250505060a0860160808701614bbe565b83613044565b9150611a706020840184613fa9565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611ac09190614b67565b611ad06040890160208a01613fa9565b611add60408a018a614b02565b611aed60a08c0160808d01614bbe565b60a08c0135611b0260e08e0160c08f01614b84565b8c604051602001611b1391906143fc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b53999897969594939291614bdb565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611c0157600080fd5b505afa158015611c15573d6000803e3d6000fd5b50505050620f4240821115611c56576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c6061068c565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611d0488888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105bc915050565b69ffffffffffffffffffff169050611d1e86868386613539565b93505050505b95945050505050565b6060600e8054611d3c906145fa565b9050600003611d77576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610e57906145fa565b855185518560ff16601f831115611df7576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610c05565b80600003611e61576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610c05565b818314611eef576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610c05565b611efa816003614c9f565b8311611f62576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610c05565b611f6a6127b9565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611fb190886136a9565b6005541561216657600554600090611fcb90600190614a32565b9050600060058281548110611fe257611fe2614906565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061201c5761201c614906565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061209c5761209c614cb6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061210557612105614cb6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611fb1915050565b60005b8151518110156125cd576000600460008460000151848151811061218f5761218f614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121d9576121d9614aaf565b14612240576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610c05565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061227157612271614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561231257612312614aaf565b0217905550600091506123229050565b600460008460200151848151811061233c5761233c614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561238657612386614aaf565b146123ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610c05565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061242057612420614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124c1576124c1614aaf565b0217905550508251805160059250839081106124df576124df614906565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061255b5761255b614906565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125c581614964565b915050612169565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161268591849174010000000000000000000000000000000000000000900416614ce5565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126e44630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516136c6565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861279b988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614d02565b60405180910390a161184d565b6127b06127b9565b61068981613771565b60005473ffffffffffffffffffffffffffffffffffffffff16331461283a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c05565b565b6000612846610d91565b90508051600003612883576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d546000916128a2916bffffffffffffffffffffffff16614d88565b905060005b825181101561296e5781600c60008584815181106128c7576128c7614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff1661292f9190614db3565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061296790614964565b90506128a7565b50815161297b9082614dd8565b600d805460009061299b9084906bffffffffffffffffffffffff1661499c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a3357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a08575b5050505050905060005b8151811015612aac578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a6f57612a6f614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a9c575060019392505050565b612aa581614964565b9050612a3d565b5060009392505050565b600080600080600080600080600089806020019051810190612ad89190614e08565b98509850985098509850985098509850985060008113612b27576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610c05565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612dab908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60019392505050565b6000612dd5826020614c9f565b612de0856020614c9f565b612dec88610144614eb4565b612df69190614eb4565b612e009190614eb4565b612e0b906000614eb4565b9050368114610b7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610c05565b606080808080612e8886880188614fa2565b8451949950929750909550935091501580612ea557508351855114155b80612eb257508251855114155b80612ebf57508151855114155b80612ecc57508051855114155b15612f03576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8551811015613036576000612f9b878381518110612f2657612f26614906565b6020026020010151878481518110612f4057612f40614906565b6020026020010151878581518110612f5a57612f5a614906565b6020026020010151878681518110612f7457612f74614906565b6020026020010151878781518110612f8e57612f8e614906565b6020026020010151613866565b90506000816006811115612fb157612fb1614aaf565b1480612fce57506001816006811115612fcc57612fcc614aaf565b145b1561302557868281518110612fe557612fe5614906565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061302f81614964565b9050612f06565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260095461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115613103576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061310f85846105bc565b90506000613137846040015185606001518469ffffffffffffffffffff168760800151613539565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa1580156131db573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052613221919081019061507f565b505050602089015189516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156132b2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132d69190615176565b509150506bffffffffffffffffffffffff85166132f3838561499c565b6bffffffffffffffffffffffff161015613339576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006133b8308a602001518b6000015185600161335691906151c8565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001876bffffffffffffffffffffffff168152602001600960000160109054906101000a900463ffffffff1663ffffffff16426134799190614eb4565b64ffffffffff168152602080820184905269ffffffffffffffffffff8a1660408084019190915260095463ffffffff680100000000000000008204811660608601526c010000000000000000000000009091041660809093019290925290519199506134e7918a91016143fc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815281516020928301206000938452600890925290912055509498975050505050505050565b600080613544611036565b905060008113613583576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610c05565b60095460009087906135b99063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614ce5565b6135c39190614ce5565b63ffffffff1690506000612710600960010154886135e19190614c9f565b6135eb91906151e9565b6135f59088614eb4565b90506000838361360d84670de0b6b3a7640000614c9f565b6136179190614c9f565b61362191906151e9565b905060006136406bffffffffffffffffffffffff808916908a16614eb4565b9050613658816b033b2e3c9fd0803ce8000000614a32565b821115613691576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61369b8183614eb4565b9a9950505050505050505050565b60006136b3610d91565b5111156136c2576136c261283c565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136ea999897969594939291906151fd565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137f0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c05565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808380602001905181019061387d91906152a7565b60008881526008602052604090205490915061389d576002915050611d24565b806040516020016138ae91906143fc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600890935291205414613900576006915050611d24565b600061390a611036565b905060008113613949576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610c05565b60008161395e3a670de0b6b3a7640000614c9f565b61396891906151e9565b90506000836101400151846101200151613982919061537a565b6139939064ffffffffff1683614c9f565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139f49190614db3565b338c6040518763ffffffff1660e01b8152600401613a1796959493929190615398565b60408051808303816000875af1158015613a35573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a599190615414565b9150915060008260ff166006811115613a7457613a74614aaf565b90506000816006811115613a8a57613a8a614aaf565b1480613aa757506001816006811115613aa557613aa5614aaf565b145b15613b625760008d815260086020526040812055613ac58285614db3565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100890151600d805469ffffffffffffffffffff90921693909291613b3391859116614db3565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b9c9b505050505050505050505050565b508054613b7e906145fa565b6000825580601f10613b8e575050565b601f0160209004906000526020600020908101906106899190613bcb565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613be05760008155600101613bcc565b5090565b60008083601f840112613bf657600080fd5b50813567ffffffffffffffff811115613c0e57600080fd5b602083019150836020828501011115613c2657600080fd5b9250929050565b60008060208385031215613c4057600080fd5b823567ffffffffffffffff811115613c5757600080fd5b613c6385828601613be4565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613cc157613cc1613c6f565b60405290565b6040516080810167ffffffffffffffff81118282101715613cc157613cc1613c6f565b604051610160810167ffffffffffffffff81118282101715613cc157613cc1613c6f565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d5557613d55613c6f565b604052919050565b600082601f830112613d6e57600080fd5b813567ffffffffffffffff811115613d8857613d88613c6f565b613db960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613d0e565b818152846020838601011115613dce57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461068957600080fd5b8035610fac81613deb565b73ffffffffffffffffffffffffffffffffffffffff8116811461068957600080fd5b63ffffffff8116811461068957600080fd5b6bffffffffffffffffffffffff8116811461068957600080fd5b60008082840360c0811215613e6e57600080fd5b833567ffffffffffffffff811115613e8557600080fd5b613e9186828701613d5d565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613ec457600080fd5b50613ecd613c9e565b6020840135613edb81613deb565b81526040840135613eeb81613e0c565b60208201526060840135613efe81613e2e565b60408201526080840135606082015260a0840135613f1b81613e40565b6080820152919491935090915050565b6000815180845260005b81811015613f5157602081850181015186830182015201613f35565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613fa26020830184613f2b565b9392505050565b600060208284031215613fbb57600080fd5b8135613fa281613e0c565b600081518084526020808501945080840160005b8381101561400c57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613fda565b509495945050505050565b60408152600061402a6040830185613fc6565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614098577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614086838351613f2b565b9486019492509085019060010161404c565b50909998505050505050505050565b600080604083850312156140ba57600080fd5b82356140c581613e0c565b915060208301356140d581613e40565b809150509250929050565b6000806000604084860312156140f557600080fd5b833561410081613e0c565b9250602084013567ffffffffffffffff81111561411c57600080fd5b61412886828701613be4565b9497909650939450505050565b602081526000613fa26020830184613fc6565b60006020828403121561415a57600080fd5b5035919050565b60006020828403121561417357600080fd5b813567ffffffffffffffff81111561418a57600080fd5b61419684828501613d5d565b949350505050565b60008083601f8401126141b057600080fd5b50813567ffffffffffffffff8111156141c857600080fd5b6020830191508360208260051b8501011115613c2657600080fd5b60008060008060008060008060e0898b0312156141ff57600080fd5b606089018a81111561421057600080fd5b8998503567ffffffffffffffff8082111561422a57600080fd5b6142368c838d01613be4565b909950975060808b013591508082111561424f57600080fd5b61425b8c838d0161419e565b909750955060a08b013591508082111561427457600080fd5b506142818b828c0161419e565b999c989b50969995989497949560c00135949350505050565b6000602082840312156142ac57600080fd5b813567ffffffffffffffff8111156142c357600080fd5b82016101008185031215613fa257600080fd5b80516bffffffffffffffffffffffff168252602081015161430f602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614337604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614353606084018267ffffffffffffffff169052565b50608081015161436b608084018263ffffffff169052565b5060a081015161438b60a08401826bffffffffffffffffffffffff169052565b5060c08101516143a460c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143cd8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d8b565b61016081016105e482846142d6565b60008060008060006080868803121561442357600080fd5b853561442e81613deb565b9450602086013567ffffffffffffffff81111561444a57600080fd5b61445688828901613be4565b909550935050604086013561446a81613e2e565b949793965091946060013592915050565b600067ffffffffffffffff82111561449557614495613c6f565b5060051b60200190565b600082601f8301126144b057600080fd5b813560206144c56144c08361447b565b613d0e565b82815260059290921b840181019181810190868411156144e457600080fd5b8286015b848110156145085780356144fb81613e0c565b83529183019183016144e8565b509695505050505050565b60ff8116811461068957600080fd5b8035610fac81614513565b60008060008060008060c0878903121561454657600080fd5b863567ffffffffffffffff8082111561455e57600080fd5b61456a8a838b0161449f565b9750602089013591508082111561458057600080fd5b61458c8a838b0161449f565b965061459a60408a01614522565b955060608901359150808211156145b057600080fd5b6145bc8a838b01613d5d565b94506145ca60808a01613e01565b935060a08901359150808211156145e057600080fd5b506145ed89828a01613d5d565b9150509295509295509295565b600181811c9082168061460e57607f821691505b602082108103614647577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105b757600081815260208120601f850160051c810160208610156146745750805b601f850160051c820191505b8181101561469357828155600101614680565b505050505050565b67ffffffffffffffff8311156146b3576146b3613c6f565b6146c7836146c183546145fa565b8361464d565b6000601f84116001811461471957600085156146e35750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147af565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147685786850135825560209485019460019092019101614748565b50868210156147a3577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461068957600080fd5b8051610fac81613e40565b8051610fac81613e2e565b600060208083850312156147ef57600080fd5b825167ffffffffffffffff8082111561480757600080fd5b908401906080828703121561481b57600080fd5b614823613cc7565b825161482e816147b6565b81528284015161483d81613e40565b8185015260408301517fffffffff000000000000000000000000000000000000000000000000000000008116811461487457600080fd5b604082015260608301518281111561488b57600080fd5b80840193505086601f8401126148a057600080fd5b825191506148b06144c08361447b565b82815260059290921b830184019184810190888411156148cf57600080fd5b938501935b838510156148f65784516148e781613e2e565b825293850193908501906148d4565b6060830152509695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361499557614995614935565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156149c1576149c1614935565b5092915050565b805169ffffffffffffffffffff81168114610fac57600080fd5b600080600080600060a086880312156149fa57600080fd5b614a03866149c8565b9450602086015193506040860151925060608601519150614a26608087016149c8565b90509295509295909350565b818103818111156105e4576105e4614935565b60ff81811683821601908111156105e4576105e4614935565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614aa057614aa0614a5e565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614b3757600080fd5b83018035915067ffffffffffffffff821115614b5257600080fd5b602001915036819003821315613c2657600080fd5b600060208284031215614b7957600080fd5b8135613fa281613deb565b600060208284031215614b9657600080fd5b8135613fa281613e2e565b600060208284031215614bb357600080fd5b8135613fa281613e40565b600060208284031215614bd057600080fd5b8135613fa2816147b6565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c7860c085018763ffffffff169052565b818482030160e0850152614c8e82820186613f2b565b9d9c50505050505050505050505050565b80820281158282048414176105e4576105e4614935565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156149c1576149c1614935565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614d328184018a613fc6565b90508281036080840152614d468189613fc6565b905060ff871660a084015282810360c0840152614d638187613f2b565b905067ffffffffffffffff851660e0840152828103610100840152613b628185613f2b565b60006bffffffffffffffffffffffff80841680614da757614da7614a5e565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156149c1576149c1614935565b6bffffffffffffffffffffffff818116838216028082169190828114614e0057614e00614935565b505092915050565b60008060008060008060008060006101208a8c031215614e2757600080fd5b8951614e3281613e2e565b60208b0151909950614e4381613e2e565b60408b0151909850614e5481613e2e565b60608b0151909750614e6581613e2e565b60808b0151909650614e7681613e2e565b9450614e8460a08b016149c8565b935060c08a0151614e94816147b6565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105e4576105e4614935565b600082601f830112614ed857600080fd5b81356020614ee86144c08361447b565b82815260059290921b84018101918181019086841115614f0757600080fd5b8286015b848110156145085780358352918301918301614f0b565b600082601f830112614f3357600080fd5b81356020614f436144c08361447b565b82815260059290921b84018101918181019086841115614f6257600080fd5b8286015b8481101561450857803567ffffffffffffffff811115614f865760008081fd5b614f948986838b0101613d5d565b845250918301918301614f66565b600080600080600060a08688031215614fba57600080fd5b853567ffffffffffffffff80821115614fd257600080fd5b614fde89838a01614ec7565b96506020880135915080821115614ff457600080fd5b61500089838a01614f22565b9550604088013591508082111561501657600080fd5b61502289838a01614f22565b9450606088013591508082111561503857600080fd5b61504489838a01614f22565b9350608088013591508082111561505a57600080fd5b5061506788828901614f22565b9150509295509295909350565b8051610fac81613e0c565b600080600080600060a0868803121561509757600080fd5b85516150a281613e40565b809550506020808701516150b581613e40565b60408801519095506150c681613e0c565b60608801519094506150d781613e0c565b608088015190935067ffffffffffffffff8111156150f457600080fd5b8701601f8101891361510557600080fd5b80516151136144c08261447b565b81815260059190911b8201830190838101908b83111561513257600080fd5b928401925b8284101561515957835161514a81613e0c565b82529284019290840190615137565b80955050505050509295509295909350565b8051610fac81613deb565b60008060006060848603121561518b57600080fd5b8351801515811461519b57600080fd5b60208501519093506151ac81613deb565b60408501519092506151bd81613deb565b809150509250925092565b67ffffffffffffffff8181168382160190808211156149c1576149c1614935565b6000826151f8576151f8614a5e565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526152448285018b613fc6565b91508382036080850152615258828a613fc6565b915060ff881660a085015283820360c08501526152758288613f2b565b90861660e08501528381036101008501529050613b628185613f2b565b805164ffffffffff81168114610fac57600080fd5b600061016082840312156152ba57600080fd5b6152c2613cea565b6152cb836147c6565b81526152d960208401615074565b60208201526152ea60408401615074565b60408201526152fb6060840161516b565b606082015261530c608084016147d1565b608082015261531d60a084016147c6565b60a082015261532e60c08401615292565b60c082015260e083015160e082015261010061534b8185016149c8565b9082015261012061535d848201615292565b9082015261014061536f848201615292565b908201529392505050565b64ffffffffff8181168382160190808211156149c1576149c1614935565b60006102008083526153ac8184018a613f2b565b905082810360208401526153c08189613f2b565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150615409905060a08301846142d6565b979650505050505050565b6000806040838503121561542757600080fd5b825161543281614513565b60208401519092506140d581613e4056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -224,9 +226,9 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) EstimateCost(sub return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPrice) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAdminFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getAdminFee", arg0, arg1) + err := _FunctionsCoordinator.contract.Call(opts, &out, "getAdminFee") if err != nil { return *new(*big.Int), err @@ -238,12 +240,12 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAdminFee(opts *bind. } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetAdminFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetAdminFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) +func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetAdminFee() (*big.Int, error) { + return _FunctionsCoordinator.Contract.GetAdminFee(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetAdminFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetAdminFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetAdminFee() (*big.Int, error) { + return _FunctionsCoordinator.Contract.GetAdminFee(&_FunctionsCoordinator.CallOpts) } func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAllNodePublicKeys(opts *bind.CallOpts) ([]common.Address, [][]byte, error) { @@ -1804,7 +1806,7 @@ func (_FunctionsCoordinator *FunctionsCoordinator) Address() common.Address { type FunctionsCoordinatorInterface interface { EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) - GetAdminFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) + GetAdminFee(opts *bind.CallOpts) (*big.Int, error) GetAllNodePublicKeys(opts *bind.CallOpts) ([]common.Address, [][]byte, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index a513754933c..44c59d6afad 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -44,9 +44,16 @@ type IFunctionsRequestCommitment struct { GasOverheadAfterCallback *big.Int } +type IFunctionsRouterConfig struct { + MaxConsumers uint16 + AdminFee *big.Int + HandleOracleFulfillmentSelector [4]byte + MaxCallbackGasLimits []uint32 +} + var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMaxConsumers\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200645138038062006451833981016040819052620000349162000431565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006ab9350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000838060200190518101906200024491906200052e565b604080516060810182526001600160601b0385168082526001600160e01b03198516602080840191909152928201849052600f80546001600160801b0319169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092620002bc916010919086019062000303565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051620002f5939291906200063a565b60405180910390a150505050565b82805482825590600052602060002090600701600890048101928215620003a75791602002820160005b838211156200037357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200032d565b8015620003a55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000373565b505b50620003b5929150620003b9565b5090565b5b80821115620003b55760008155600101620003ba565b805161ffff81168114620003e357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004295762000429620003e8565b604052919050565b600080600080608085870312156200044857600080fd5b6200045385620003d0565b9350602062000464818701620003d0565b60408701519094506001600160a01b03811681146200048257600080fd5b60608701519093506001600160401b0380821115620004a057600080fd5b818801915088601f830112620004b557600080fd5b815181811115620004ca57620004ca620003e8565b620004de601f8201601f19168501620003fe565b91508082528984828501011115620004f557600080fd5b60005b8181101562000515578381018501518382018601528401620004f8565b5060008482840101525080935050505092959194509250565b6000806000606084860312156200054457600080fd5b83516001600160601b03811681146200055c57600080fd5b602085810151919450906001600160e01b0319811681146200057d57600080fd5b60408601519093506001600160401b03808211156200059b57600080fd5b818701915087601f830112620005b057600080fd5b815181811115620005c557620005c5620003e8565b8060051b9150620005d8848301620003fe565b818152918301840191848101908a841115620005f357600080fd5b938501935b838510156200062a578451925063ffffffff83168314620006195760008081fd5b8282529385019390850190620005f8565b8096505050505050509250925092565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b818110156200069d57845163ffffffff168352938301939183019160010162000679565b509098975050505050505050565b608051615d8a620006c7600039600061297a0152615d8a6000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063a9c9a918116100ee578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610766578063eb523d6c14610779578063f2fde38b1461078c57600080fd5b8063c4614d611461072d578063d7ae1d3014610740578063e72f6e301461075357600080fd5b8063b5643858116100c8578063b5643858146106fb578063b734c0f41461070e578063badc3eb61461071657600080fd5b8063a9c9a918146106b7578063aab396bd146106ca578063b187bd26146106f057600080fd5b80639883c10d11610150578063a21a23e41161012a578063a21a23e414610678578063a47c769614610680578063a4c0ed36146106a457600080fd5b80639883c10d146106245780639f87fad71461062c578063a1d4c8281461063f57600080fd5b80638456cb59116101815780638456cb59146105f15780638da5cb5b146105f95780638fde53171461061c57600080fd5b806379ba5097146105d657806382359740146105de57600080fd5b80634b8832d31161025557806366419970116102095780636e3b3323116101e35780636e3b3323146105a957806371ec28ac146105bc5780637341c10c146105c357600080fd5b806366419970146104ae578063674603d0146104dc5780636a6df79b1461057157600080fd5b80635c975abb1161023a5780635c975abb146104715780635ed6dfba1461048857806366316d8d1461049b57600080fd5b80634b8832d31461044b57806355fedefa1461045e57600080fd5b80631ded3b36116102b75780633e871e4d116102915780633e871e4d1461040f5780633f4ba83a14610422578063461d27621461042a57600080fd5b80631ded3b36146103d35780632a905ccc146103e6578063385de9ae146103fc57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038a57600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b61031761031236600461496b565b61079f565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b6103176103473660046149a5565b61082c565b6009546b01000000000000000000000090046bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff9091168152602001610330565b6103c66040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614a42565b6103176103e1366004614a55565b610956565b600f546bffffffffffffffffffffffff1661036d565b61031761040a366004614aca565b610987565b61031761041d366004614c83565b610b65565b610317610e5b565b61043d610438366004614d4e565b610e6d565b604051908152602001610330565b610317610459366004614dd2565b610ec1565b61043d61046c36600461496b565b610fbe565b60005460ff165b6040519015158152602001610330565b610317610496366004614e25565b610fe2565b6103176104a9366004614e25565b6112b8565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b6105496104ea366004614e53565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b61058461057f366004614e8f565b6114df565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105b7366004614eb4565b6114f2565b6064610321565b6103176105d1366004614dd2565b6117c8565b610317611975565b6103176105ec36600461496b565b611a97565b610317611be6565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610584565b610317611bf6565b60075461043d565b61031761063a366004614dd2565b611c9e565b61065261064d3660046150cd565b6120a6565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610330565b6104c3612472565b61069361068e36600461496b565b612606565b6040516103309594939291906151cb565b6103176106b2366004615220565b6126f2565b6105846106c536600461527c565b612921565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761043d565b60005460ff16610478565b610317610709366004615295565b61292e565b610317612a8f565b61071e612bfd565b604051610330939291906152b0565b6103c661073b366004614aca565b612cd8565b61031761074e366004614dd2565b612ced565b610317610761366004615311565b612d46565b61047861077436600461496b565b612f52565b61031761078736600461527c565b612f5d565b61031761079a366004615311565b61317b565b6107a761318c565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061081e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108288282613194565b5050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110610891576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6010805460ff83169081106108a8576108a861532e565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff161115610951576010805460ff83169081106108f8576108f861532e565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610888565b505050565b61095e61318c565b61096782613502565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61098f613578565b600061099c8460006135fe565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109c65750600754610a3a565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610a13573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a37919061535d565b90505b8383604051610a4a929190615376565b60405180910390208103610a8a576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610aeb9061ffff16436153b5565b9052600086815260066020908152604090912082518155908201516001820190610b159082615469565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b56908790849088908890615583565b60405180910390a15050505050565b610b6d613578565b8151815181141580610b7f5750600881115b15610bb6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ce2576000848281518110610bd557610bd561532e565b602002602001015190506000848381518110610bf357610bf361532e565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c5e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c95576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610ccf576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610888565b505080610cdb906155de565b9050610bb9565b50600954600090610cf79061ffff16436153b5565b604080516060810182528681526020808201879052918101839052865192935091600391610d299183918901906147ab565b506020828101518051610d4292600185019201906147f2565b506040820151816002015590505060005b8451811015610e54577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610d8f57610d8f61532e565b602002602001015160026000888581518110610dad57610dad61532e565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610df657610df661532e565b602002602001015185604051610e3c949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e4d816155de565b9050610d53565b5050505050565b610e63613578565b610e6b6136f5565b565b6000610eb68260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a91506137729050565b979650505050505050565b610ec9613aab565b610ed282613ab3565b610eda613b79565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108285767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b610fea61318c565b806bffffffffffffffffffffffff166000036110205750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561107a576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906110a79084906bffffffffffffffffffffffff16615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166110fe9190615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561119d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c19190615642565b61082857600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611234573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611258919061535d565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610888565b6112c0613aab565b806bffffffffffffffffffffffff16600003611308576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611362576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061138f9084906bffffffffffffffffffffffff16615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166113e69190615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611485573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114a99190615642565b610828576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006114eb83836135fe565b9392505050565b6114fa613aab565b60005b818110156109515760008383838181106115195761151961532e565b90506101600201803603810190611530919061565f565b905060008160e001519050600e60008281526020019081526020016000205482604051602001611560919061567c565b60405160208183030381529060405280519060200120146115ad576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156115f2576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611664573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116889190615642565b5060a0830151606084015167ffffffffffffffff166000908152600b6020526040812060010180549091906116cc9084906bffffffffffffffffffffffff16615616565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c6020908152828220606087015167ffffffffffffffff90811684529152919020805460019260099161175891859169010000000000000000009004166157ab565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806117c1906155de565b90506114fd565b6117d0613aab565b6117d982613ab3565b6117e1613b79565b67ffffffffffffffff82166000908152600b60205260409020600201547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff9c01611856576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff161561189d575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610fb2565b60015473ffffffffffffffffffffffffffffffffffffffff1633146119f6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610888565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611a9f613aab565b611aa7613b79565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611b47576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610888565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611bee613578565b610e6b613c80565b611bfe613578565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611c60576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611ca6613aab565b611caf82613ab3565b611cb7613b79565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d87576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611ddc576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611e5757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e2c575b50505050509050600060018251611e6e91906157cc565b905060005b825181101561200a578473ffffffffffffffffffffffffffffffffffffffff16838281518110611ea557611ea561532e565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611ffa576000838381518110611edc57611edc61532e565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611f2257611f2261532e565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b90915260409020600201805480611f9c57611f9c6157df565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190555061200a565b612003816155de565b9050611e73565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b6000806120b1613aab565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461211a576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e60205260409020546121af5760025b91508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516121a29392919073ffffffffffffffffffffffffffffffffffffffff938416815291909216602082015260ff91909116604082015260600190565b60405180910390a2612467565b600e60008460e00151815260200190815260200160002054836040516020016121d8919061567c565b60405160208183030381529060405280519060200120146121fa576006612135565b826101400151836080015163ffffffff16612215919061580e565b64ffffffffff165a101561222a576004612135565b606083015167ffffffffffffffff166000908152600b602052604090205460808401516bffffffffffffffffffffffff9091169061226d9063ffffffff16613cdb565b612277908861582c565b8451612284908890615854565b61228e9190615854565b6bffffffffffffffffffffffff16111561231f5760e0830180516000908152600e6020908152604080832092909255915182860151825173ffffffffffffffffffffffffffffffffffffffff9182168152908816938101939093526005918301829052909350907f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1906060016121a2565b8260a001516bffffffffffffffffffffffff16612345846080015163ffffffff16613cdb565b61234f908861582c565b845161235c908890615854565b6123669190615854565b6bffffffffffffffffffffffff161115612381576003612135565b60009150600e60008460e0015181526020019081526020016000206000905560006123bb8460e001518a8a87608001518860400151613d7d565b80519091506123cb5760016123ce565b60005b925060006123f585606001518660a00151876040015188600001518c87602001518d613ef7565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151612442578e612444565b8f5b886040015160405161245a959493929190615879565b60405180910390a3519150505b965096945050505050565b600061247c613aab565b612484613b79565b600980546003906124a5906301000000900467ffffffffffffffff166158d7565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c081018252600080825233602083015291810182905260608101829052919250608082019060405190808252806020026020018201604052801561251b578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926125b6926002850192909101906147f2565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606061261786613502565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126e257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116126b7575b5050505050905091939590929450565b6126fa613aab565b600a5473ffffffffffffffffffffffffffffffffffffffff16331461274b576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612785576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006127938284018461496b565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661280c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906128438385615854565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff1661289a9190615854565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461290191906153b5565b6040805192835260208301919091520160405180910390a2505050505050565b6000610fdc8260006135fe565b612936613578565b60095461ffff808316911603612978576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff1611156129da576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff90811680835290841660208301529091820190612a0790436153b5565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a97613578565b600554431015612ad3576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612bfa57600060036000018281548110612af857612af861532e565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612b4457612b4461532e565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612bf3906155de565b9050612ad6565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612c5d57602002820191906000526020600020905b815481526020019060010190808311612c49575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612cc657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612c9b575b50505050509050925092509250909192565b6060612ce5848484614149565b949350505050565b612cf5613aab565b612cfe82613ab3565b612d06613b79565b612d0f82614216565b1561081e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612d4e61318c565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612dbd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612de1919061535d565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612e48576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610888565b81811015610951576000612e5c82846157cc565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612ed7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612efb9190615642565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b43660091015b60405180910390a150505050565b6000610fdc82614216565b612f65613578565b60006006600083815260200190815260200160002060405180606001604052908160008201548152602001600182018054612f9f906153c8565b80601f0160208091040260200160405190810160405280929190818152602001828054612fcb906153c8565b80156130185780601f10612fed57610100808354040283529160200191613018565b820191906000526020600020905b815481529060010190602001808311612ffb57829003601f168201915b505050505081526020016002820154815250509050806040015143101561306b576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816130905761307d8160200151614365565b6020808201518051910120600755613138565b61309b8260006135fe565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016130d79190614a42565b600060405180830381600087803b1580156130f157600080fd5b505af1925050508015613102575060015b613138576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261316f9286926158fe565b60405180910390a15050565b613183613578565b612bfa81614460565b610e6b613578565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561327557602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161324a575b505050918352505060039190910154602090910152805190915060005b82608001515181101561333657600c6000846080015183815181106132b9576132b961532e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561332f816155de565b9050613292565b5067ffffffffffffffff84166000908152600b602052604081208181556001810182905590613368600283018261486c565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff1661339b9190615616565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561343a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061345e9190615642565b613494576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612bfa576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610888565b60008161363d5760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613637579050610fdc565b506136c0565b60005b6003548110156136be57600380548290811061365e5761365e61532e565b906000526020600020015484036136ae5760048054829081106136835761368361532e565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150610fdc9050565b6136b7816155de565b9050613640565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610888565b6136fd61455b565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b600061377c613aab565b61378585613502565b61378f33866145c7565b613799858361082c565b60006137a588886135fe565b6040805160e08101825233815267ffffffffffffffff89166000818152600b602081815285832080546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff908116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c084015292517faecc12c500000000000000000000000000000000000000000000000000000000815293945091929184169163aecc12c59161386c91600401615926565b610160604051808303816000875af115801561388c573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138b091906159fb565b90506138c133888360a00151614663565b604051806101600160405280600f60000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff168152506040516020016139ce919061567c565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152828252805160209182012060e0850180516000908152600e8452848120929092555167ffffffffffffffff8c16808352600b9093529290205490928c92917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613a93916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908e908e908e90615ace565b60405180910390a460e0015198975050505050505050565b610e6b61473e565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613b2a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610828576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ba47fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006135fe565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613c0790339060248101615b32565b602060405180830381865afa158015613c24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c489190615642565b610e6b576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610888565b613c8861473e565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137483390565b60006bffffffffffffffffffffffff821115613d79576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610888565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916c01000000000000000000000000900460e01b90613dc890899089908990602401615b61565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613e7a57600080fd5b5a611388811015613e8a57600080fd5b611388810390508760408204820311613ea257600080fd5b60008086516020880160008b8df193505a900391503d6084811115613ec5575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613f1684613cdb565b613f20908661582c565b9050600081613f2f8886615854565b613f399190615854565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b909152928320805492975093945084939291613f9091859116615616565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613fca9190615854565b336000908152600d602052604081208054909190613ff79084906bffffffffffffffffffffffff16615854565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b9450909261403e91859116615854565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d9450909261409291859116615616565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161411691859169010000000000000000009004166157ab565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6060600080808061415c86880188615b96565b9350935093509350600061417589600187878787613772565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614209578181602081106141b4576141b461532e565b1a60f81b8782815181106141ca576141ca61532e565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a905350614202816155de565b9050614199565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561428e57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311614263575b5050505050905060005b815181101561435b576000600c60008484815181106142b9576142b961532e565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461434a57506001949350505050565b50614354816155de565b9050614298565b5060009392505050565b60008060008380602001905181019061437e9190615c09565b604080516060810182526bffffffffffffffffffffffff85168082527fffffffff000000000000000000000000000000000000000000000000000000008516602080840191909152928201849052600f80547fffffffffffffffffffffffffffffffff00000000000000000000000000000000169091176c0100000000000000000000000060e087901c0217815583519598509396509194509092614429916010919086019061488a565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051612f4493929190615cf2565b3373ffffffffffffffffffffffffffffffffffffffff8216036144df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610888565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610888565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610828576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610888565b67ffffffffffffffff82166000908152600b60205260408120600101805483929061469d9084906bffffffffffffffffffffffff16615854565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff80891685529252909120805460019450909284926147139284929004166157ab565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e6b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610888565b8280548282559060005260206000209081019282156147e6579160200282015b828111156147e65782518255916020019190600101906147cb565b50613d79929150614930565b8280548282559060005260206000209081019282156147e6579160200282015b828111156147e657825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614812565b5080546000825590600052602060002090810190612bfa9190614930565b828054828255906000526020600020906007016008900481019282156147e65791602002820160005b838211156148f757835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026148b3565b80156149275782816101000a81549063ffffffff02191690556004016020816003010492830192600103026148f7565b5050613d799291505b5b80821115613d795760008155600101614931565b67ffffffffffffffff81168114612bfa57600080fd5b803561496681614945565b919050565b60006020828403121561497d57600080fd5b81356114eb81614945565b63ffffffff81168114612bfa57600080fd5b803561496681614988565b600080604083850312156149b857600080fd5b82356149c381614945565b915060208301356149d381614988565b809150509250929050565b6000815180845260005b81811015614a04576020818501810151868301820152016149e8565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114eb60208301846149de565b60008060408385031215614a6857600080fd5b8235614a7381614945565b946020939093013593505050565b60008083601f840112614a9357600080fd5b50813567ffffffffffffffff811115614aab57600080fd5b602083019150836020828501011115614ac357600080fd5b9250929050565b600080600060408486031215614adf57600080fd5b83359250602084013567ffffffffffffffff811115614afd57600080fd5b614b0986828701614a81565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614b6957614b69614b16565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614bb657614bb6614b16565b604052919050565b600067ffffffffffffffff821115614bd857614bd8614b16565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff81168114612bfa57600080fd5b803561496681614be2565b600082601f830112614c2057600080fd5b81356020614c35614c3083614bbe565b614b6f565b82815260059290921b84018101918181019086841115614c5457600080fd5b8286015b84811015614c78578035614c6b81614be2565b8352918301918301614c58565b509695505050505050565b60008060408385031215614c9657600080fd5b823567ffffffffffffffff80821115614cae57600080fd5b818501915085601f830112614cc257600080fd5b81356020614cd2614c3083614bbe565b82815260059290921b84018101918181019089841115614cf157600080fd5b948201945b83861015614d0f57853582529482019490820190614cf6565b96505086013592505080821115614d2557600080fd5b50614d3285828601614c0f565b9150509250929050565b803561ffff8116811461496657600080fd5b60008060008060008060a08789031215614d6757600080fd5b8635614d7281614945565b9550602087013567ffffffffffffffff811115614d8e57600080fd5b614d9a89828a01614a81565b9096509450614dad905060408801614d3c565b92506060870135614dbd81614988565b80925050608087013590509295509295509295565b60008060408385031215614de557600080fd5b8235614df081614945565b915060208301356149d381614be2565b6bffffffffffffffffffffffff81168114612bfa57600080fd5b803561496681614e00565b60008060408385031215614e3857600080fd5b8235614e4381614be2565b915060208301356149d381614e00565b60008060408385031215614e6657600080fd5b8235614e7181614be2565b915060208301356149d381614945565b8015158114612bfa57600080fd5b60008060408385031215614ea257600080fd5b8235915060208301356149d381614e81565b60008060208385031215614ec757600080fd5b823567ffffffffffffffff80821115614edf57600080fd5b818501915085601f830112614ef357600080fd5b813581811115614f0257600080fd5b86602061016083028501011115614f1857600080fd5b60209290920196919550909350505050565b600082601f830112614f3b57600080fd5b813567ffffffffffffffff811115614f5557614f55614b16565b614f8660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614b6f565b818152846020838601011115614f9b57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff81168114612bfa57600080fd5b803561496681614fb8565b69ffffffffffffffffffff81168114612bfa57600080fd5b803561496681614fd6565b6000610160828403121561500c57600080fd5b615014614b45565b905061501f82614e1a565b815261502d60208301614c04565b602082015261503e60408301614c04565b604082015261504f6060830161495b565b60608201526150606080830161499a565b608082015261507160a08301614e1a565b60a082015261508260c08301614fcb565b60c082015260e082013560e082015261010061509f818401614fee565b908201526101206150b1838201614fcb565b908201526101406150c3838201614fcb565b9082015292915050565b60008060008060008061020087890312156150e757600080fd5b863567ffffffffffffffff808211156150ff57600080fd5b61510b8a838b01614f2a565b9750602089013591508082111561512157600080fd5b5061512e89828a01614f2a565b955050604087013561513f81614e00565b9350606087013561514f81614e00565b9250608087013561515f81614be2565b915061516e8860a08901614ff9565b90509295509295509295565b600081518084526020808501945080840160005b838110156151c057815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161518e565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090610eb69083018461517a565b6000806000806060858703121561523657600080fd5b843561524181614be2565b935060208501359250604085013567ffffffffffffffff81111561526457600080fd5b61527087828801614a81565b95989497509550505050565b60006020828403121561528e57600080fd5b5035919050565b6000602082840312156152a757600080fd5b6114eb82614d3c565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156152f1578451835293830193918301916001016152d5565b50508481036040860152615305818761517a565b98975050505050505050565b60006020828403121561532357600080fd5b81356114eb81614be2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561536f57600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610fdc57610fdc615386565b600181811c908216806153dc57607f821691505b602082108103615415577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561095157600081815260208120601f850160051c810160208610156154425750805b601f850160051c820191505b818110156154615782815560010161544e565b505050505050565b815167ffffffffffffffff81111561548357615483614b16565b6154978161549184546153c8565b8461541b565b602080601f8311600181146154ea57600084156154b45750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615461565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561553757888601518255948401946001909101908401615518565b508582101561557357878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361560f5761560f615386565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561563b5761563b615386565b5092915050565b60006020828403121561565457600080fd5b81516114eb81614e81565b6000610160828403121561567257600080fd5b6114eb8383614ff9565b81516bffffffffffffffffffffffff168152610160810160208301516156ba602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516156e2604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516156fe606084018267ffffffffffffffff169052565b506080830151615716608084018263ffffffff169052565b5060a083015161573660a08401826bffffffffffffffffffffffff169052565b5060c083015161574f60c084018264ffffffffff169052565b5060e083015160e0830152610100808401516157788285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff81811683821601908082111561563b5761563b615386565b81810381811115610fdc57610fdc615386565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b64ffffffffff81811683821601908082111561563b5761563b615386565b6bffffffffffffffffffffffff8181168382160280821691908281146157a3576157a3615386565b6bffffffffffffffffffffffff81811683821601908082111561563b5761563b615386565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a0606082015260006158c560a08301856149de565b828103608084015261530581856149de565b600067ffffffffffffffff8083168181036158f4576158f4615386565b6001019392505050565b83815282602082015260606040820152600061591d60608301846149de565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff80845116602084015280602085015116604084015250604083015160e060608401526159716101008401826149de565b905067ffffffffffffffff606085015116608084015261ffff60808501511660a084015260a084015160c084015263ffffffff60c08501511660e08401528091505092915050565b805161496681614e00565b805161496681614be2565b805161496681614945565b805161496681614988565b805161496681614fb8565b805161496681614fd6565b60006101608284031215615a0e57600080fd5b615a16614b45565b615a1f836159b9565b8152615a2d602084016159c4565b6020820152615a3e604084016159c4565b6040820152615a4f606084016159cf565b6060820152615a60608084016159da565b6080820152615a7160a084016159b9565b60a0820152615a8260c084016159e5565b60c082015260e083015160e0820152610100615a9f8185016159f0565b90820152610120615ab18482016159e5565b90820152610140615ac38482016159e5565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615b0f60c08301866149de565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612ce560408301846149de565b838152606060208201526000615b7a60608301856149de565b8281036040840152615b8c81856149de565b9695505050505050565b60008060008060808587031215615bac57600080fd5b8435615bb781614945565b9350602085013567ffffffffffffffff811115615bd357600080fd5b615bdf87828801614f2a565b935050615bee60408601614d3c565b91506060850135615bfe81614988565b939692955090935050565b600080600060608486031215615c1e57600080fd5b8351615c2981614e00565b809350506020808501517fffffffff0000000000000000000000000000000000000000000000000000000081168114615c6157600080fd5b604086015190935067ffffffffffffffff811115615c7e57600080fd5b8501601f81018713615c8f57600080fd5b8051615c9d614c3082614bbe565b81815260059190911b82018301908381019089831115615cbc57600080fd5b928401925b82841015615ce3578351615cd481614988565b82529284019290840190615cc1565b80955050505050509250925092565b6000606082016bffffffffffffffffffffffff8616835260207fffffffff0000000000000000000000000000000000000000000000000000000086168185015260606040850152818551808452608086019150828701935060005b81811015615d6f57845163ffffffff1683529383019391830191600101615d4d565b50909897505050505050505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumers\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200666b3803806200666b83398101604081905262000034916200044b565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d79350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000808480602001905181019062000245919062000548565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600f80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002d591601091908601906200031d565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200030e9392919062000666565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003c15791602002820160005b838211156200038d57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000347565b8015620003bf5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200038d565b505b50620003cf929150620003d3565b5090565b5b80821115620003cf5760008155600101620003d4565b805161ffff81168114620003fd57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000443576200044362000402565b604052919050565b600080600080608085870312156200046257600080fd5b6200046d85620003ea565b935060206200047e818701620003ea565b60408701519094506001600160a01b03811681146200049c57600080fd5b60608701519093506001600160401b0380821115620004ba57600080fd5b818801915088601f830112620004cf57600080fd5b815181811115620004e457620004e462000402565b620004f8601f8201601f1916850162000418565b915080825289848285010111156200050f57600080fd5b60005b818110156200052f57838101850151838201860152840162000512565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055f57600080fd5b6200056a85620003ea565b602086810151919550906001600160601b03811681146200058a57600080fd5b60408701519094506001600160e01b031981168114620005a957600080fd5b60608701519093506001600160401b0380821115620005c757600080fd5b818801915088601f830112620005dc57600080fd5b815181811115620005f157620005f162000402565b8060051b91506200060484830162000418565b818152918301840191848101908b8411156200061f57600080fd5b938501935b8385101562000656578451925063ffffffff83168314620006455760008081fd5b828252938501939085019062000624565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c957845163ffffffff1683529383019391830191600101620006a5565b509098975050505050505050565b608051615f78620006f3600039600061294f0152615f786000f3fe608060405234801561001057600080fd5b50600436106102f45760003560e01c80638456cb5911610191578063b187bd26116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610752578063eb523d6c14610765578063f2fde38b1461077857600080fd5b8063c4614d6114610719578063d7ae1d301461072c578063e72f6e301461073f57600080fd5b8063b734c0f4116100c8578063b734c0f4146106e5578063badc3eb6146106ed578063c3f909d41461070457600080fd5b8063b187bd26146106c7578063b5643858146106d257600080fd5b8063a1d4c82811610145578063a4c0ed361161011f578063a4c0ed361461067b578063a9c9a9181461068e578063aab396bd146106a157600080fd5b8063a1d4c82814610616578063a21a23e41461064f578063a47c76961461065757600080fd5b80638fde5317116101765780638fde5317146105f35780639883c10d146105fb5780639f87fad71461060357600080fd5b80638456cb59146105c85780638da5cb5b146105d057600080fd5b806355fedefa1161024a578063674603d0116101fe5780637341c10c116101d85780637341c10c1461059a57806379ba5097146105ad57806382359740146105b557600080fd5b8063674603d0146104ba5780636a6df79b1461054f5780636e3b33231461058757600080fd5b80635ed6dfba1161022f5780635ed6dfba1461046657806366316d8d14610479578063664199701461048c57600080fd5b806355fedefa1461043c5780635c975abb1461044f57600080fd5b80631ded3b36116102ac5780633f4ba83a116102865780633f4ba83a14610400578063461d2762146104085780634b8832d31461042957600080fd5b80631ded3b36146103c7578063385de9ae146103da5780633e871e4d146103ed57600080fd5b806310fc49c1116102dd57806310fc49c11461032e57806312b5834914610341578063181f5a771461037e57600080fd5b806302bcc5b6146102f95780630c5d49cb1461030e575b600080fd5b61030c610307366004614ab1565b61078b565b005b610316608481565b60405161ffff90911681526020015b60405180910390f35b61030c61033c366004614aeb565b610818565b6009546b01000000000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610325565b6103ba6040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103259190614b88565b61030c6103d5366004614b9b565b610942565b61030c6103e8366004614c10565b610973565b61030c6103fb366004614dc9565b610b51565b61030c610e47565b61041b610416366004614e92565b610e59565b604051908152602001610325565b61030c610437366004614f17565b610ead565b61041b61044a366004614ab1565b610faa565b60005460ff165b6040519015158152602001610325565b61030c610474366004614f6a565b610fce565b61030c610487366004614f6a565b6112a4565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610325565b6105276104c8366004614f98565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610325565b61056261055d366004614fd4565b6114cb565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610325565b61030c610595366004614ff9565b6114de565b61030c6105a8366004614f17565b6117b4565b61030c61194a565b61030c6105c3366004614ab1565b611a6c565b61030c611bbb565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610562565b61030c611bcb565b60075461041b565b61030c610611366004614f17565b611c73565b610629610624366004615212565b61207b565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610325565b6104a1612447565b61066a610665366004614ab1565b6125db565b604051610325959493929190615310565b61030c610689366004615365565b6126c7565b61056261069c3660046153c1565b6128f6565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761041b565b60005460ff16610456565b61030c6106e03660046153da565b612903565b61030c612a64565b6106f5612bd2565b604051610325939291906153f7565b61070c612cad565b604051610325919061548e565b6103ba610727366004614c10565b612dc4565b61030c61073a366004614f17565b612dd9565b61030c61074d3660046154fb565b612e32565b610456610760366004614ab1565b61303d565b61030c6107733660046153c1565b613048565b61030c6107863660046154fb565b613266565b610793613277565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061080a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610814828261327f565b5050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a90811061087d576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6010805460ff831690811061089457610894615518565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561093d576010805460ff83169081106108e4576108e4615518565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610874565b505050565b61094a613277565b610953826135ed565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61097b613663565b60006109888460006136e9565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109b25750600754610a26565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156109ff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a239190615547565b90505b8383604051610a36929190615560565b60405180910390208103610a76576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610ad79061ffff164361559f565b9052600086815260066020908152604090912082518155908201516001820190610b019082615653565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b4290879084908890889061576d565b60405180910390a15050505050565b610b59613663565b8151815181141580610b6b5750600881115b15610ba2576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610cce576000848281518110610bc157610bc1615518565b602002602001015190506000848381518110610bdf57610bdf615518565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c4a575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c81576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cbb576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610874565b505080610cc7906157c8565b9050610ba5565b50600954600090610ce39061ffff164361559f565b604080516060810182528681526020808201879052918101839052865192935091600391610d159183918901906148f1565b506020828101518051610d2e9260018501920190614938565b506040820151816002015590505060005b8451811015610e40577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610d7b57610d7b615518565b602002602001015160026000888581518110610d9957610d99615518565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610de257610de2615518565b602002602001015185604051610e28949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e39816157c8565b9050610d3f565b5050505050565b610e4f613663565b610e576137e0565b565b6000610ea28260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915061385d9050565b979650505050505050565b610eb5613bb3565b610ebe82613bbb565b610ec6613c81565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108145767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b610fd6613277565b806bffffffffffffffffffffffff1660000361100c5750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611066576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906110939084906bffffffffffffffffffffffff16615800565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166110ea9190615800565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611189573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111ad919061582c565b61081457600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611220573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112449190615547565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610874565b6112ac613bb3565b806bffffffffffffffffffffffff166000036112f4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561134e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061137b9084906bffffffffffffffffffffffff16615800565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166113d29190615800565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611471573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611495919061582c565b610814576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006114d783836136e9565b9392505050565b6114e6613bb3565b60005b8181101561093d57600083838381811061150557611505615518565b9050610160020180360381019061151c9190615849565b905060008160e001519050600e6000828152602001908152602001600020548260405160200161154c9190615866565b6040516020818303038152906040528051906020012014611599576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156115de576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611650573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611674919061582c565b5060a0830151606084015167ffffffffffffffff166000908152600b6020526040812060010180549091906116b89084906bffffffffffffffffffffffff16615800565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c6020908152828220606087015167ffffffffffffffff9081168452915291902080546001926009916117449185916901000000000000000000900416615995565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806117ad906157c8565b90506114e9565b6117bc613bb3565b6117c582613bbb565b6117cd613c81565b600f5467ffffffffffffffff83166000908152600b602052604090206002015461ffff909116900361182b576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611872575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610f9e565b60015473ffffffffffffffffffffffffffffffffffffffff1633146119cb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610874565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611a74613bb3565b611a7c613c81565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611b1c576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610874565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611bc3613663565b610e57613d88565b611bd3613663565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611c35576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611c7b613bb3565b611c8482613bbb565b611c8c613c81565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d5c576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610874565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611db1576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611e2c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e01575b50505050509050600060018251611e4391906159b6565b905060005b8251811015611fdf578473ffffffffffffffffffffffffffffffffffffffff16838281518110611e7a57611e7a615518565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611fcf576000838381518110611eb157611eb1615518565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611ef757611ef7615518565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b90915260409020600201805480611f7157611f716159c9565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611fdf565b611fd8816157c8565b9050611e48565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b600080612086613bb3565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146120ef576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e60205260409020546121845760025b91508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516121779392919073ffffffffffffffffffffffffffffffffffffffff938416815291909216602082015260ff91909116604082015260600190565b60405180910390a261243c565b600e60008460e00151815260200190815260200160002054836040516020016121ad9190615866565b60405160208183030381529060405280519060200120146121cf57600661210a565b826101400151836080015163ffffffff166121ea91906159f8565b64ffffffffff165a10156121ff57600461210a565b606083015167ffffffffffffffff166000908152600b602052604090205460808401516bffffffffffffffffffffffff909116906122429063ffffffff16613de3565b61224c9088615a16565b8451612259908890615a3e565b6122639190615a3e565b6bffffffffffffffffffffffff1611156122f45760e0830180516000908152600e6020908152604080832092909255915182860151825173ffffffffffffffffffffffffffffffffffffffff9182168152908816938101939093526005918301829052909350907f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee190606001612177565b8260a001516bffffffffffffffffffffffff1661231a846080015163ffffffff16613de3565b6123249088615a16565b8451612331908890615a3e565b61233b9190615a3e565b6bffffffffffffffffffffffff16111561235657600361210a565b60009150600e60008460e0015181526020019081526020016000206000905560006123908460e001518a8a87608001518860400151613e85565b80519091506123a05760016123a3565b60005b925060006123ca85606001518660a00151876040015188600001518c87602001518d614001565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151612417578e612419565b8f5b886040015160405161242f959493929190615a63565b60405180910390a3519150505b965096945050505050565b6000612451613bb3565b612459613c81565b6009805460039061247a906301000000900467ffffffffffffffff16615ac1565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156124f0578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261258b92600285019290910190614938565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b60008060008060606125ec866135ed565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126b757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161268c575b5050505050905091939590929450565b6126cf613bb3565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612720576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461275a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061276882840184614ab1565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166127e1576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906128188385615a3e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff1661286f9190615a3e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128d6919061559f565b6040805192835260208301919091520160405180910390a2505050505050565b6000610fc88260006136e9565b61290b613663565b60095461ffff80831691160361294d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff1611156129af576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff908116808352908416602083015290918201906129dc904361559f565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a6c613663565b600554431015612aa8576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612bcf57600060036000018281548110612acd57612acd615518565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612b1957612b19615518565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612bc8906157c8565b9050612aab565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612c3257602002820191906000526020600020905b815481526020019060010190808311612c1e575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612c9b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612c70575b50505050509050925092509250909192565b604080516080810182526000808252602082018190529181019190915260608082015260408051608081018252600f805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff0000000000000000000000000000000000000000000000000000000016838501526010805485518184028101840190965280865293949293606086019392830182828015612db657602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612d795790505b505050505081525050905090565b6060612dd1848484614253565b949350505050565b612de1613bb3565b612dea82613bbb565b612df2613c81565b612dfb82614320565b1561080a576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612e3a613277565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ea9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ecd9190615547565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612f34576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610874565b8181101561093d576000612f4882846159b6565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612fc3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612fe7919061582c565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6000610fc882614320565b613050613663565b6000600660008381526020019081526020016000206040518060600160405290816000820154815260200160018201805461308a906155b2565b80601f01602080910402602001604051908101604052809291908181526020018280546130b6906155b2565b80156131035780601f106130d857610100808354040283529160200191613103565b820191906000526020600020905b8154815290600101906020018083116130e657829003601f168201915b5050505050815260200160028201548152505090508060400151431015613156576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8161317b57613168816020015161446f565b6020808201518051910120600755613223565b6131868260006136e9565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016131c29190614b88565b600060405180830381600087803b1580156131dc57600080fd5b505af19250505080156131ed575060015b613223576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261325a928692615ae8565b60405180910390a15050565b61326e613663565b612bcf816145a6565b610e57613663565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561336057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613335575b505050918352505060039190910154602090910152805190915060005b82608001515181101561342157600c6000846080015183815181106133a4576133a4615518565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561341a816157c8565b905061337d565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061345360028301826149b2565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff166134869190615800565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613525573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613549919061582c565b61357f576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612bcf576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610874565b6000816137285760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613722579050610fc8565b506137ab565b60005b6003548110156137a957600380548290811061374957613749615518565b9060005260206000200154840361379957600480548290811061376e5761376e615518565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150610fc89050565b6137a2816157c8565b905061372b565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610874565b6137e86146a1565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613867613bb3565b613870856135ed565b61387a338661470d565b6138848583610818565b600061389088886136e9565b604080516101008101825233815267ffffffffffffffff89166000818152600b6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c0840152600f546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e88000000000000000000000000000000000000000000000000000000000815293945091929184169163bdd7e8809161397491600401615b10565b610160604051808303816000875af1158015613994573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139b89190615c11565b90506139c933888360a001516147a9565b604051806101600160405280600f60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613ad69190615866565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152828252805160209182012060e0850180516000908152600e8452848120929092555167ffffffffffffffff8c16808352600b9093529290205490928c92917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613b9b916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908e908e908e90615ce4565b60405180910390a460e0015198975050505050505050565b610e57614884565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613c32576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610814576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613cac7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006136e9565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613d0f90339060248101615d48565b602060405180830381865afa158015613d2c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d50919061582c565b610e57576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610874565b613d90614884565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138333390565b60006bffffffffffffffffffffffff821115613e81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610874565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916e010000000000000000000000000000900460e01b90613ed290899089908990602401615d77565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613f8457600080fd5b5a611388811015613f9457600080fd5b611388810390508760408204820311613fac57600080fd5b60008086516020880160008b8df193505a900391503d6084811115613fcf575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b6040805180820190915260008082526020820152600061402084613de3565b61402a9086615a16565b90506000816140398886615a3e565b6140439190615a3e565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b90915292832080549297509394508493929161409a91859116615800565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846140d49190615a3e565b336000908152600d6020526040812080549091906141019084906bffffffffffffffffffffffff16615a3e565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b9450909261414891859116615a3e565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d9450909261419c91859116615800565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f168552925290912080546001926009916142209185916901000000000000000000900416615995565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6060600080808061426686880188615dac565b9350935093509350600061427f8960018787878761385d565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614313578181602081106142be576142be615518565b1a60f81b8782815181106142d4576142d4615518565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061430c816157c8565b90506142a3565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561439857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161436d575b5050505050905060005b8151811015614465576000600c60008484815181106143c3576143c3615518565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461445457506001949350505050565b5061445e816157c8565b90506143a2565b5060009392505050565b600080600080848060200190518101906144899190615e21565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600f80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a50949850929650909450909261456f91601091908601906149d0565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051610b4293929190615f1c565b3373ffffffffffffffffffffffffffffffffffffffff821603614625576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610874565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610874565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610814576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610874565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906147e39084906bffffffffffffffffffffffff16615a3e565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614859928492900416615995565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610874565b82805482825590600052602060002090810192821561492c579160200282015b8281111561492c578251825591602001919060010190614911565b50613e81929150614a76565b82805482825590600052602060002090810192821561492c579160200282015b8281111561492c57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614958565b5080546000825590600052602060002090810190612bcf9190614a76565b8280548282559060005260206000209060070160089004810192821561492c5791602002820160005b83821115614a3d57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026149f9565b8015614a6d5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a3d565b5050613e819291505b5b80821115613e815760008155600101614a77565b67ffffffffffffffff81168114612bcf57600080fd5b8035614aac81614a8b565b919050565b600060208284031215614ac357600080fd5b81356114d781614a8b565b63ffffffff81168114612bcf57600080fd5b8035614aac81614ace565b60008060408385031215614afe57600080fd5b8235614b0981614a8b565b91506020830135614b1981614ace565b809150509250929050565b6000815180845260005b81811015614b4a57602081850181015186830182015201614b2e565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114d76020830184614b24565b60008060408385031215614bae57600080fd5b8235614bb981614a8b565b946020939093013593505050565b60008083601f840112614bd957600080fd5b50813567ffffffffffffffff811115614bf157600080fd5b602083019150836020828501011115614c0957600080fd5b9250929050565b600080600060408486031215614c2557600080fd5b83359250602084013567ffffffffffffffff811115614c4357600080fd5b614c4f86828701614bc7565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614caf57614caf614c5c565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614cfc57614cfc614c5c565b604052919050565b600067ffffffffffffffff821115614d1e57614d1e614c5c565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff81168114612bcf57600080fd5b8035614aac81614d28565b600082601f830112614d6657600080fd5b81356020614d7b614d7683614d04565b614cb5565b82815260059290921b84018101918181019086841115614d9a57600080fd5b8286015b84811015614dbe578035614db181614d28565b8352918301918301614d9e565b509695505050505050565b60008060408385031215614ddc57600080fd5b823567ffffffffffffffff80821115614df457600080fd5b818501915085601f830112614e0857600080fd5b81356020614e18614d7683614d04565b82815260059290921b84018101918181019089841115614e3757600080fd5b948201945b83861015614e5557853582529482019490820190614e3c565b96505086013592505080821115614e6b57600080fd5b50614e7885828601614d55565b9150509250929050565b61ffff81168114612bcf57600080fd5b60008060008060008060a08789031215614eab57600080fd5b8635614eb681614a8b565b9550602087013567ffffffffffffffff811115614ed257600080fd5b614ede89828a01614bc7565b9096509450506040870135614ef281614e82565b92506060870135614f0281614ace565b80925050608087013590509295509295509295565b60008060408385031215614f2a57600080fd5b8235614f3581614a8b565b91506020830135614b1981614d28565b6bffffffffffffffffffffffff81168114612bcf57600080fd5b8035614aac81614f45565b60008060408385031215614f7d57600080fd5b8235614f8881614d28565b91506020830135614b1981614f45565b60008060408385031215614fab57600080fd5b8235614fb681614d28565b91506020830135614b1981614a8b565b8015158114612bcf57600080fd5b60008060408385031215614fe757600080fd5b823591506020830135614b1981614fc6565b6000806020838503121561500c57600080fd5b823567ffffffffffffffff8082111561502457600080fd5b818501915085601f83011261503857600080fd5b81358181111561504757600080fd5b8660206101608302850101111561505d57600080fd5b60209290920196919550909350505050565b600082601f83011261508057600080fd5b813567ffffffffffffffff81111561509a5761509a614c5c565b6150cb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cb5565b8181528460208386010111156150e057600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff81168114612bcf57600080fd5b8035614aac816150fd565b69ffffffffffffffffffff81168114612bcf57600080fd5b8035614aac8161511b565b6000610160828403121561515157600080fd5b615159614c8b565b905061516482614f5f565b815261517260208301614d4a565b602082015261518360408301614d4a565b604082015261519460608301614aa1565b60608201526151a560808301614ae0565b60808201526151b660a08301614f5f565b60a08201526151c760c08301615110565b60c082015260e082013560e08201526101006151e4818401615133565b908201526101206151f6838201615110565b90820152610140615208838201615110565b9082015292915050565b600080600080600080610200878903121561522c57600080fd5b863567ffffffffffffffff8082111561524457600080fd5b6152508a838b0161506f565b9750602089013591508082111561526657600080fd5b5061527389828a0161506f565b955050604087013561528481614f45565b9350606087013561529481614f45565b925060808701356152a481614d28565b91506152b38860a0890161513e565b90509295509295509295565b600081518084526020808501945080840160005b8381101561530557815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016152d3565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090610ea2908301846152bf565b6000806000806060858703121561537b57600080fd5b843561538681614d28565b935060208501359250604085013567ffffffffffffffff8111156153a957600080fd5b6153b587828801614bc7565b95989497509550505050565b6000602082840312156153d357600080fd5b5035919050565b6000602082840312156153ec57600080fd5b81356114d781614e82565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154385784518352938301939183019160010161541c565b5050848103604086015261544c81876152bf565b98975050505050505050565b600081518084526020808501945080840160005b8381101561530557815163ffffffff168752958201959082019060010161546c565b6020815261ffff82511660208201526bffffffffffffffffffffffff60208301511660408201527fffffffff00000000000000000000000000000000000000000000000000000000604083015116606082015260006060830151608080840152612dd160a0840182615458565b60006020828403121561550d57600080fd5b81356114d781614d28565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561555957600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610fc857610fc8615570565b600181811c908216806155c657607f821691505b6020821081036155ff577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561093d57600081815260208120601f850160051c8101602086101561562c5750805b601f850160051c820191505b8181101561564b57828155600101615638565b505050505050565b815167ffffffffffffffff81111561566d5761566d614c5c565b6156818161567b84546155b2565b84615605565b602080601f8311600181146156d4576000841561569e5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561564b565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561572157888601518255948401946001909101908401615702565b508582101561575d57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036157f9576157f9615570565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561582557615825615570565b5092915050565b60006020828403121561583e57600080fd5b81516114d781614fc6565b6000610160828403121561585c57600080fd5b6114d7838361513e565b81516bffffffffffffffffffffffff168152610160810160208301516158a4602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516158cc604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516158e8606084018267ffffffffffffffff169052565b506080830151615900608084018263ffffffff169052565b5060a083015161592060a08401826bffffffffffffffffffffffff169052565b5060c083015161593960c084018264ffffffffff169052565b5060e083015160e0830152610100808401516159628285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff81811683821601908082111561582557615825615570565b81810381811115610fc857610fc8615570565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b64ffffffffff81811683821601908082111561582557615825615570565b6bffffffffffffffffffffffff81811683821602808216919082811461598d5761598d615570565b6bffffffffffffffffffffffff81811683821601908082111561582557615825615570565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a060608201526000615aaf60a0830185614b24565b828103608084015261544c8185614b24565b600067ffffffffffffffff808316818103615ade57615ade615570565b6001019392505050565b838152826020820152606060408201526000615b076060830184614b24565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615b5d610120850183614b24565b91506060850151615b7a608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615bac60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614aac81614f45565b8051614aac81614d28565b8051614aac81614a8b565b8051614aac81614ace565b8051614aac816150fd565b8051614aac8161511b565b60006101608284031215615c2457600080fd5b615c2c614c8b565b615c3583615bcf565b8152615c4360208401615bda565b6020820152615c5460408401615bda565b6040820152615c6560608401615be5565b6060820152615c7660808401615bf0565b6080820152615c8760a08401615bcf565b60a0820152615c9860c08401615bfb565b60c082015260e083015160e0820152610100615cb5818501615c06565b90820152610120615cc7848201615bfb565b90820152610140615cd9848201615bfb565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615d2560c0830186614b24565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612dd16040830184614b24565b838152606060208201526000615d906060830185614b24565b8281036040840152615da28185614b24565b9695505050505050565b60008060008060808587031215615dc257600080fd5b8435615dcd81614a8b565b9350602085013567ffffffffffffffff811115615de957600080fd5b615df58782880161506f565b9350506040850135615e0681614e82565b91506060850135615e1681614ace565b939692955090935050565b60008060008060808587031215615e3757600080fd5b8451615e4281614e82565b80945050602080860151615e5581614f45565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615e8b57600080fd5b606087015190935067ffffffffffffffff811115615ea857600080fd5b8601601f81018813615eb957600080fd5b8051615ec7614d7682614d04565b81815260059190911b8201830190838101908a831115615ee657600080fd5b928401925b82841015615f0d578351615efe81614ace565b82529284019290840190615eeb565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615b07606083018461545856fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -207,48 +214,48 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) MAXCALLBACKRETURNBYTES() ( return _FunctionsRouter.Contract.MAXCALLBACKRETURNBYTES(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetAllowListId(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getAdminFee") + err := _FunctionsRouter.contract.Call(opts, &out, "getAllowListId") if err != nil { - return *new(*big.Int), err + return *new([32]byte), err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetAdminFee() (*big.Int, error) { - return _FunctionsRouter.Contract.GetAdminFee(&_FunctionsRouter.CallOpts) +func (_FunctionsRouter *FunctionsRouterSession) GetAllowListId() ([32]byte, error) { + return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetAdminFee() (*big.Int, error) { - return _FunctionsRouter.Contract.GetAdminFee(&_FunctionsRouter.CallOpts) +func (_FunctionsRouter *FunctionsRouterCallerSession) GetAllowListId() ([32]byte, error) { + return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetAllowListId(opts *bind.CallOpts) ([32]byte, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) { var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getAllowListId") + err := _FunctionsRouter.contract.Call(opts, &out, "getConfig") if err != nil { - return *new([32]byte), err + return *new(IFunctionsRouterConfig), err } - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + out0 := *abi.ConvertType(out[0], new(IFunctionsRouterConfig)).(*IFunctionsRouterConfig) return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetAllowListId() ([32]byte, error) { - return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) +func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (IFunctionsRouterConfig, error) { + return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetAllowListId() ([32]byte, error) { - return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) +func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (IFunctionsRouterConfig, error) { + return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } func (_FunctionsRouter *FunctionsRouterCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { @@ -370,28 +377,6 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetFlags(subscriptionId ui return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCaller) GetMaxConsumers(opts *bind.CallOpts) (uint16, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getMaxConsumers") - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetMaxConsumers() (uint16, error) { - return _FunctionsRouter.Contract.GetMaxConsumers(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetMaxConsumers() (uint16, error) { - return _FunctionsRouter.Contract.GetMaxConsumers(&_FunctionsRouter.CallOpts) -} - func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getProposedContractSet") @@ -4006,10 +3991,10 @@ func (_FunctionsRouter *FunctionsRouter) Address() common.Address { type FunctionsRouterInterface interface { MAXCALLBACKRETURNBYTES(opts *bind.CallOpts) (uint16, error) - GetAdminFee(opts *bind.CallOpts) (*big.Int, error) - GetAllowListId(opts *bind.CallOpts) ([32]byte, error) + GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) + GetConfigHash(opts *bind.CallOpts) ([32]byte, error) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, @@ -4022,8 +4007,6 @@ type FunctionsRouterInterface interface { GetFlags(opts *bind.CallOpts, subscriptionId uint64) ([32]byte, error) - GetMaxConsumers(opts *bind.CallOpts) (uint16, error) - GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index a311539432c..857c960e0a7 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,8 +3,8 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../. functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 666319c8b9b06d75db166d87a7338a79e9abe9eff71b73ea905f16f9e7cc95cf functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin c8af757c84f65f0e0193824195190fd2976b749e997dc6f5d0e533dbe0fcf162 -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 56b680ad59eb95d29358575e9e1cd3e333be5c3e100897abb0c08e61866814ab +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 607be9fa262f499aeadb5572907eb9ed78c3ca1595a14ef0ef1bbeeda8da94bc +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 31b716f2bd9e26d5fd41d2c239cf102622de78b7aafcbb041d1298cb72079a09 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 0d69bc8c095..e00729b9fdd 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -206,17 +206,19 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, // Deploy Router contract routerConfigABI := abi.Arguments{ + {Type: uint16Type}, // maxConsumers {Type: uint96Type}, // adminFee {Type: bytes4Type}, // handleOracleFulfillmentSelector {Type: uint32ArrType}, // maxCallbackGasLimits } + var maxConsumers = uint16(100) var adminFee = big.NewInt(0) handleOracleFulfillmentSelectorSlice, err := hex.DecodeString("0ca76175") require.NoError(t, err) var handleOracleFulfillmentSelector [4]byte copy(handleOracleFulfillmentSelector[:], handleOracleFulfillmentSelectorSlice[:4]) maxCallbackGasLimits := []uint32{300_000, 500_000, 1_000_000} - routerConfig, err := routerConfigABI.Pack(adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits) + routerConfig, err := routerConfigABI.Pack(maxConsumers, adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits) require.NoError(t, err) var timelockBlocks = uint16(0) var maximumTimelockBlocks = uint16(10) From 600365a7a27508d699dbd4b994fafba7dc288659 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Wed, 2 Aug 2023 02:18:14 -0400 Subject: [PATCH 058/270] [Functions] Various changes from review #2 (#10014) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Move FulfillResultCodes to interfaces folder * Rename Function.sol setArgs -> addArgs * Rename Routable s_config_hash -> s_configHash * Make Routable updateConfig public for re-use in constructor * Move comment out of IConfigurable * Make Routable s_router private with an internal getter * Rename constant to ROUTER_ID * Rename RouterBase s_config_hash -> s_configHash * Rename Routable.sol -> HasRouter.sol * Add IOwnableRouter interface * FunctionsSubscriptions MustBeSubOwner -> MustBeSubscriptionOwner * Make RouterBase variable private * RouterBase togglePause -> pause/unpause * Use full semantic version in typeAndVersion * ToS Allow List rename proof -> signature * Change acceptTermsOfService arguments from signature to raw r,s,v * Prettier format 💅 * Remove RouterBase versioning * Move RequestTimedOut event to Router * Rename requestSubscriptionOwnerTransfer -> proposeSubscriptionOwnerTransfer * (test): Update tests for changes * (test): Add v0 gas test * Regenerate geth wrappers * Use FulfillResult within FunctionsRouter * FunctionsRouter getConfig getter * Strip down FunctionsClient.sol * Rename GAS_FLAX_INDEX -> MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX * Use named params in structs in FunctionsRouter * Use named params in RouterBase.sol * Split overloaded getContractById into getContractById & getProposedContractById * Cast IFunctionsCoordinator earlier in the sendRequest flow * Split updateConfig flow into updateConfigSelf vs. updateConfig * Reduce contract size by removing Router's config hash getter * Remove second ToS Allow List message helper * FunctionsRouter assign variable for fulfillmentCost * Use abi.encode to convert bytes32 -> bytes * Turn RouterBase.validateProposedContracts -> FunctionsRouter.sendRequestToProposed * Add extra guards against double applying config updates * Delete contract proposal set once applied * Re-use _onlySubscriptionOwner * Pass _pay gasUsed as uint96 * Remove config hashes * Regenerate geth wrappers * Amend merge conflict * Regenerate geth wrappers * Prettier & gethwrappers * (test): amend foundry test --- .../functions/dev/1_0_0/FunctionsBilling.sol | 15 +- .../functions/dev/1_0_0/FunctionsClient.sol | 23 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 219 ++++++++-------- .../dev/1_0_0/FunctionsSubscriptions.sol | 49 +--- .../v0.8/functions/dev/1_0_0/HasRouter.sol | 11 - .../v0.8/functions/dev/1_0_0/RouterBase.sol | 150 +++++------ .../accessControl/TermsOfServiceAllowList.sol | 14 +- .../interfaces/ITermsOfServiceAllowList.sol | 9 +- .../dev/1_0_0/interfaces/IConfigurable.sol | 6 - .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 26 +- .../interfaces/IFunctionsSubscriptions.sol | 13 +- .../dev/1_0_0/interfaces/IRouterBase.sol | 18 +- .../tests/1_0_0/FunctionsRouter.t.sol | 6 +- .../testhelpers/FunctionsClientTestHelper.sol | 11 +- .../v0.8/functions/v1/FunctionsRouter.test.ts | 10 +- .../v1/FunctionsSubscriptions.test.ts | 8 +- .../test/v0.8/functions/v1/GasGolf.test.ts | 4 +- .../test/v0.8/functions/v1/RouterBase.test.ts | 25 +- .../v1/TermsOfServiceAllowList.test.ts | 14 +- contracts/test/v0.8/functions/v1/utils.ts | 6 +- .../functions_allow_list.go | 66 +---- .../functions_coordinator.go | 28 +-- .../functions_router/functions_router.go | 237 +++++++++--------- ...rapper-dependency-versions-do-not-edit.txt | 6 +- .../v1/internal/testutils.go | 6 +- 25 files changed, 409 insertions(+), 571 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 1072a3d8ea3..da28d2d09d7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -194,8 +194,8 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { * @inheritdoc IFunctionsBilling */ function getAdminFee() public view override returns (uint96) { - IFunctionsRouter.Config memory config = _getRouter().getConfig(); - return config.adminFee; + (, uint96 adminFee, , ) = _getRouter().getConfig(); + return adminFee; } function getFeedData() public view returns (int256) { @@ -288,10 +288,10 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { billing.adminFee ); IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(_getRouter())); - (uint96 balance, uint96 blockedBalance, , , ) = subscriptions.getSubscription(billing.subscriptionId); + IFunctionsSubscriptions.Subscription memory subscription = subscriptions.getSubscription(billing.subscriptionId); (, uint64 initiatedRequests, ) = subscriptions.getConsumer(billing.client, billing.subscriptionId); - if (balance - blockedBalance < estimatedCost) { + if (subscription.balance - subscription.blockedBalance < estimatedCost) { revert InsufficientBalance(); } @@ -364,7 +364,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { ); // The Functions Router will perform the callback to the client contract - (uint8 result, uint96 callbackCostJuels) = _getRouter().fulfill( + (FulfillResult resultCode, uint96 callbackCostJuels) = _getRouter().fulfill( response, err, uint96(juelsPerGas), @@ -373,8 +373,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { commitment ); - FulfillResult fulfillResult = FulfillResult(result); - if (fulfillResult == FulfillResult.USER_SUCCESS || fulfillResult == FulfillResult.USER_ERROR) { + if (resultCode == FulfillResult.USER_SUCCESS || resultCode == FulfillResult.USER_ERROR) { delete s_requestCommitments[requestId]; // Reimburse the transmitter for the fulfillment gas cost s_withdrawableTokens[msg.sender] = gasOverheadJuels + callbackCostJuels; @@ -383,7 +382,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { s_feePool += commitment.donFee; } - return fulfillResult; + return resultCode; } // ================================================================ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol index 9d18ef6a9e5..cd9da840838 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol @@ -67,29 +67,10 @@ abstract contract FunctionsClient is IFunctionsClient { /** * @inheritdoc IFunctionsClient */ - function handleOracleFulfillment( - bytes32 requestId, - bytes memory response, - bytes memory err - ) external override onlyRouter { - fulfillRequest(requestId, response, err); - } - - /** - * @notice Gets the stored address of the router contract - * @return The address of the router contract - */ - function getRouter() internal view returns (address) { - return address(s_router); - } - - /** - * @dev Reverts if the request is not from the Router - */ - modifier onlyRouter() { + function handleOracleFulfillment(bytes32 requestId, bytes memory response, bytes memory err) external override { if (msg.sender != address(s_router)) { revert OnlyRouterCanFufill(); } - _; + fulfillRequest(requestId, response, err); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 54ac1e73573..114b725878b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -2,6 +2,7 @@ pragma solidity ^0.8.19; import {RouterBase, ITypeAndVersion} from "./RouterBase.sol"; +import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; @@ -33,12 +34,17 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint64 indexed subscriptionId, uint96 totalCostJuels, address transmitter, - uint8 resultCode, + FulfillResult resultCode, bytes response, bytes returnData ); - event RequestNotProcessed(bytes32 indexed requestId, address coordinator, address transmitter, uint8 resultCode); + event RequestNotProcessed( + bytes32 indexed requestId, + address coordinator, + address transmitter, + FulfillResult resultCode + ); error OnlyCallableFromCoordinator(); error SenderMustAcceptTermsOfService(address sender); @@ -53,7 +59,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Identifier for the route to the Terms of Service Allow List bytes32 private constant ALLOW_LIST_ID = keccak256("Functions Terms of Service Allow List"); - uint8 private constant GAS_FLAG_INDEX = 0; + uint8 private constant MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX = 0; // ================================================================ // | Configuration state | @@ -91,8 +97,13 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions /** * @inheritdoc IFunctionsRouter */ - function getConfig() external view override returns (Config memory) { - return s_config; + function getConfig() external view override returns (uint16, uint96, bytes4, uint32[] memory) { + return ( + s_config.maxConsumersPerSubscription, + s_config.adminFee, + s_config.handleOracleFulfillmentSelector, + s_config.maxCallbackGasLimits + ); } // ================================================================ @@ -105,13 +116,13 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions */ function _updateConfig(bytes memory config) internal override { ( - uint16 maxConsumers, + uint16 maxConsumersPerSubscription, uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] memory maxCallbackGasLimits ) = abi.decode(config, (uint16, uint96, bytes4, uint32[])); s_config = Config({ - maxConsumers: maxConsumers, + maxConsumersPerSubscription: maxConsumersPerSubscription, adminFee: adminFee, handleOracleFulfillmentSelector: handleOracleFulfillmentSelector, maxCallbackGasLimits: maxCallbackGasLimits @@ -123,43 +134,67 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // | Request methods | // ================================================================ + /** + * @inheritdoc IFunctionsRouter + */ + function sendRequest( + uint64 subscriptionId, + bytes calldata data, + uint16 dataVersion, + uint32 callbackGasLimit, + bytes32 donId + ) external override returns (bytes32) { + IFunctionsCoordinator coordinator = IFunctionsCoordinator(getContractById(donId)); + return _sendRequest(donId, coordinator, subscriptionId, data, dataVersion, callbackGasLimit); + } + + /** + * @inheritdoc IFunctionsRouter + */ + function sendRequestToProposed( + uint64 subscriptionId, + bytes calldata data, + uint16 dataVersion, + uint32 callbackGasLimit, + bytes32 donId + ) external override returns (bytes32) { + IFunctionsCoordinator coordinator = IFunctionsCoordinator(getProposedContractById(donId)); + return _sendRequest(donId, coordinator, subscriptionId, data, dataVersion, callbackGasLimit); + } + function _sendRequest( bytes32 donId, - bool useProposed, + IFunctionsCoordinator coordinator, uint64 subscriptionId, bytes memory data, uint16 dataVersion, uint32 callbackGasLimit - ) private returns (bytes32 requestId) { + ) private returns (bytes32) { _whenNotPaused(); _isValidSubscription(subscriptionId); _isValidConsumer(msg.sender, subscriptionId); isValidCallbackGasLimit(subscriptionId, callbackGasLimit); - address coordinatorAddress = _getContractById(donId, useProposed); - // Forward request to DON - IFunctionsRequest.Commitment memory commitment = IFunctionsCoordinator(coordinatorAddress).sendRequest( - IFunctionsCoordinator.Request( - msg.sender, - s_subscriptions[subscriptionId].owner, - data, - subscriptionId, - dataVersion, - _getFlags(subscriptionId), - callbackGasLimit, - s_config.adminFee - ) + IFunctionsRequest.Commitment memory commitment = coordinator.sendRequest( + IFunctionsCoordinator.Request({ + requestingContract: msg.sender, + subscriptionOwner: s_subscriptions[subscriptionId].owner, + data: data, + subscriptionId: subscriptionId, + dataVersion: dataVersion, + flags: getFlags(subscriptionId), + callbackGasLimit: callbackGasLimit, + adminFee: s_config.adminFee + }) ); - _markRequestInFlight(msg.sender, subscriptionId, commitment.estimatedTotalCostJuels); - // Store a commitment about the request s_requestCommitments[commitment.requestId] = keccak256( abi.encode( IFunctionsRequest.Commitment({ adminFee: s_config.adminFee, - coordinator: coordinatorAddress, + coordinator: address(coordinator), client: msg.sender, subscriptionId: subscriptionId, callbackGasLimit: callbackGasLimit, @@ -173,49 +208,21 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions ) ); - emit RequestStart( - commitment.requestId, - donId, - subscriptionId, - s_subscriptions[subscriptionId].owner, - msg.sender, - tx.origin, - data, - dataVersion, - callbackGasLimit - ); - - return commitment.requestId; - } + _markRequestInFlight(msg.sender, subscriptionId, commitment.estimatedTotalCostJuels); - function _validateProposedContracts( - bytes32 donId, - bytes calldata data - ) internal override returns (bytes memory output) { - (uint64 subscriptionId, bytes memory reqData, uint16 reqDataVersion, uint32 callbackGasLimit) = abi.decode( - data, - (uint64, bytes, uint16, uint32) - ); - bytes32 requestId = _sendRequest(donId, true, subscriptionId, reqData, reqDataVersion, callbackGasLimit); - // Convert to bytes as a more generic return - output = new bytes(32); - // Bounded by 32 - for (uint256 i; i < 32; ++i) { - output[i] = requestId[i]; - } - } + emit RequestStart({ + requestId: commitment.requestId, + donId: donId, + subscriptionId: subscriptionId, + subscriptionOwner: s_subscriptions[subscriptionId].owner, + requestingContract: msg.sender, + requestInitiator: tx.origin, + data: data, + dataVersion: dataVersion, + callbackGasLimit: callbackGasLimit + }); - /** - * @inheritdoc IFunctionsRouter - */ - function sendRequest( - uint64 subscriptionId, - bytes calldata data, - uint16 dataVersion, - uint32 callbackGasLimit, - bytes32 donId - ) external override returns (bytes32) { - return _sendRequest(donId, false, subscriptionId, data, dataVersion, callbackGasLimit); + return commitment.requestId; } /** @@ -225,10 +232,10 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes memory response, bytes memory err, uint96 juelsPerGas, - uint96 costWithoutFulfillment, + uint96 costWithoutCallback, address transmitter, IFunctionsRequest.Commitment memory commitment - ) external override returns (uint8 resultCode, uint96 callbackGasCostJuels) { + ) external override returns (FulfillResult resultCode, uint96 callbackGasCostJuels) { _whenNotPaused(); if (msg.sender != commitment.coordinator) { @@ -236,47 +243,42 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } if (s_requestCommitments[commitment.requestId] == bytes32(0)) { - resultCode = uint8(FulfillResult.INVALID_REQUEST_ID); + resultCode = FulfillResult.INVALID_REQUEST_ID; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } if (keccak256(abi.encode(commitment)) != s_requestCommitments[commitment.requestId]) { - resultCode = uint8(FulfillResult.INVALID_COMMITMENT); + resultCode = FulfillResult.INVALID_COMMITMENT; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } // Check that the transmitter has supplied enough gas for the callback to succeed if (gasleft() < commitment.callbackGasLimit + commitment.gasOverheadAfterCallback) { - resultCode = uint8(FulfillResult.INSUFFICIENT_GAS_PROVIDED); + resultCode = FulfillResult.INSUFFICIENT_GAS_PROVIDED; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } - // Check that the subscription can still afford - if ( - commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > - s_subscriptions[commitment.subscriptionId].balance - ) { - resultCode = uint8(FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION); - delete s_requestCommitments[commitment.requestId]; - emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); - } + { + uint96 callbackCost = juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit); + uint96 totalCostJuels = commitment.adminFee + costWithoutCallback + callbackCost; - // Check that the cost has not exceeded the quoted cost - if ( - commitment.adminFee + costWithoutFulfillment + (juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit)) > - commitment.estimatedTotalCostJuels - ) { - resultCode = uint8(FulfillResult.COST_EXCEEDS_COMMITMENT); - emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); - } + // Check that the subscription can still afford + if (totalCostJuels > s_subscriptions[commitment.subscriptionId].balance) { + resultCode = FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION; + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); + return (resultCode, callbackGasCostJuels); + } - // If checks pass, continue as default, 0 = USER_SUCCESS; - resultCode = 0; + // Check that the cost has not exceeded the quoted cost + if (totalCostJuels > commitment.estimatedTotalCostJuels) { + resultCode = FulfillResult.COST_EXCEEDS_COMMITMENT; + emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); + return (resultCode, callbackGasCostJuels); + } + } delete s_requestCommitments[commitment.requestId]; @@ -287,9 +289,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions commitment.callbackGasLimit, commitment.client ); - resultCode = result.success - ? 0 // FulfillResult.USER_SUCCESS - : 1; // FulfillResult.USER_ERROR + resultCode = result.success ? FulfillResult.USER_SUCCESS : FulfillResult.USER_ERROR; Receipt memory receipt = _pay( commitment.subscriptionId, @@ -297,20 +297,19 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions commitment.client, commitment.adminFee, juelsPerGas, - result.gasUsed, - costWithoutFulfillment + SafeCast.toUint96(result.gasUsed), + costWithoutCallback ); - // resultCode must be 0 or 1 here - emit RequestProcessed( - commitment.requestId, - commitment.subscriptionId, - receipt.totalCostJuels, - transmitter, - resultCode, - result.success ? response : err, - result.returnData - ); + emit RequestProcessed({ + requestId: commitment.requestId, + subscriptionId: commitment.subscriptionId, + totalCostJuels: receipt.totalCostJuels, + transmitter: transmitter, + resultCode: resultCode, + response: result.success ? response : err, + returnData: result.returnData + }); return (resultCode, receipt.callbackGasCostJuels); } @@ -388,7 +387,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions * @inheritdoc IFunctionsRouter */ function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) public view { - uint8 index = uint8(_getFlags(subscriptionId)[GAS_FLAG_INDEX]); + uint8 index = uint8(getFlags(subscriptionId)[MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX]); if (index >= s_config.maxCallbackGasLimits.length) { revert InvalidGasFlagValue(index); } @@ -398,7 +397,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } function _getMaxConsumers() internal view override returns (uint16) { - return s_config.maxConsumers; + return s_config.maxConsumersPerSubscription; } // ================================================================ @@ -414,7 +413,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } function _onlySenderThatAcceptedToS() internal view override { - if (!IAccessController(_getContractById(ALLOW_LIST_ID, false)).hasAccess(msg.sender, new bytes(0))) { + if (!IAccessController(getContractById(ALLOW_LIST_ID)).hasAccess(msg.sender, new bytes(0))) { revert SenderMustAcceptTermsOfService(msg.sender); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index c1c6743e0b3..9c1863aaa9f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -15,10 +15,6 @@ import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/u * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677ReceiverInterface { - // Reentrancy guard - bool internal s_reentrancyLock; - error Reentrant(); - // ================================================================ // | Subscription state | // ================================================================ @@ -49,14 +45,14 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei error TooManyConsumers(); error InsufficientBalance(); - error InvalidConsumer(uint64 subscriptionId, address consumer); + error InvalidConsumer(); error ConsumerRequestsInFlight(); error InvalidSubscription(); error OnlyCallableFromLink(); error InvalidCalldata(); error MustBeSubscriptionOwner(); error PendingRequestExists(); - error MustBeRequestedOwner(address proposedOwner); + error MustBeProposedOwner(); error BalanceInvariantViolated(uint256 internalBalance, uint256 externalBalance); // Should never happen event FundsRecovered(address to, uint256 amount); @@ -103,21 +99,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function getSubscription( - uint64 subscriptionId - ) - external - view - override - returns (uint96 balance, uint96 blockedBalance, address owner, address requestedOwner, address[] memory consumers) - { + function getSubscription(uint64 subscriptionId) external view override returns (Subscription memory) { _isValidSubscription(subscriptionId); - balance = s_subscriptions[subscriptionId].balance; - blockedBalance = s_subscriptions[subscriptionId].blockedBalance; - owner = s_subscriptions[subscriptionId].owner; - requestedOwner = s_subscriptions[subscriptionId].requestedOwner; - consumers = s_subscriptions[subscriptionId].consumers; + return s_subscriptions[subscriptionId]; } /** @@ -144,7 +129,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function _isValidConsumer(address client, uint64 subscriptionId) internal view { if (!s_consumers[client][subscriptionId].allowed) { - revert InvalidConsumer(subscriptionId, client); + revert InvalidConsumer(); } } @@ -173,10 +158,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei address client, uint96 adminFee, uint96 juelsPerGas, - uint256 gasUsed, + uint96 gasUsed, uint96 costWithoutCallbackJuels ) internal returns (Receipt memory receipt) { - uint96 callbackGasCostJuels = juelsPerGas * SafeCast.toUint96(gasUsed); + uint96 callbackGasCostJuels = juelsPerGas * gasUsed; uint96 totalCostJuels = costWithoutCallbackJuels + adminFee + callbackGasCostJuels; receipt = Receipt(callbackGasCostJuels, totalCostJuels); @@ -204,11 +189,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function ownerCancelSubscription(uint64 subscriptionId) external override { _onlyRouterOwner(); - address owner = s_subscriptions[subscriptionId].owner; - if (owner == address(0)) { - revert InvalidSubscription(); - } - _cancelSubscriptionHelper(subscriptionId, owner); + _isValidSubscription(subscriptionId); + _cancelSubscriptionHelper(subscriptionId, s_subscriptions[subscriptionId].owner); } /** @@ -343,7 +325,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei address previousOwner = s_subscriptions[subscriptionId].owner; address nextOwner = s_subscriptions[subscriptionId].requestedOwner; if (nextOwner != msg.sender) { - revert MustBeRequestedOwner(nextOwner); + revert MustBeProposedOwner(); } s_subscriptions[subscriptionId].owner = msg.sender; s_subscriptions[subscriptionId].requestedOwner = address(0); @@ -359,7 +341,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _onlySenderThatAcceptedToS(); Consumer memory consumerData = s_consumers[consumer][subscriptionId]; if (!consumerData.allowed) { - revert InvalidConsumer(subscriptionId, consumer); + revert InvalidConsumer(); } if (consumerData.initiatedRequests != consumerData.completedRequests) { revert ConsumerRequestsInFlight(); @@ -460,15 +442,11 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei s_subscriptions[subscriptionId].flags = flags; } - function _getFlags(uint64 subscriptionId) internal view returns (bytes32) { - return s_subscriptions[subscriptionId].flags; - } - /** * @inheritdoc IFunctionsSubscriptions */ - function getFlags(uint64 subscriptionId) external view returns (bytes32) { - return _getFlags(subscriptionId); + function getFlags(uint64 subscriptionId) public view returns (bytes32) { + return s_subscriptions[subscriptionId].flags; } function _getMaxConsumers() internal view virtual returns (uint16); @@ -496,7 +474,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } IFunctionsBilling coordinator = IFunctionsBilling(request.coordinator); - coordinator.deleteCommitment(requestId); // Release blocked balance s_subscriptions[request.subscriptionId].blockedBalance -= request.estimatedTotalCostJuels; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol index 4f01d0eff5c..4b5f4295421 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol @@ -7,8 +7,6 @@ import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IOwnableFunctionsRouter} from "./interfaces/IOwnableFunctionsRouter.sol"; abstract contract HasRouter is ITypeAndVersion, IConfigurable { - bytes32 internal s_configHash; - IOwnableFunctionsRouter internal immutable s_router; error RouterMustBeSet(); @@ -24,20 +22,12 @@ abstract contract HasRouter is ITypeAndVersion, IConfigurable { } s_router = IOwnableFunctionsRouter(router); _updateConfig(config); - s_configHash = keccak256(config); } function _getRouter() internal view returns (IOwnableFunctionsRouter router) { return s_router; } - /** - * @inheritdoc IConfigurable - */ - function getConfigHash() external view override returns (bytes32 config) { - return s_configHash; - } - /** * @dev Must be implemented by inheriting contract * Use to set configuration state @@ -50,7 +40,6 @@ abstract contract HasRouter is ITypeAndVersion, IConfigurable { */ function updateConfig(bytes memory config) public override onlyRouter { _updateConfig(config); - s_configHash = keccak256(config); } /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index f4a1f5ad22d..a5c0a9f9842 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -38,29 +38,23 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme uint256 timelockEndBlock ); - event ContractUpdated( - bytes32 proposedContractSetId, - address proposedContractSetFromAddress, - address proposedContractSetToAddress - ); + event ContractUpdated(bytes32 id, address from, address to); struct ConfigProposal { - bytes32 fromHash; bytes to; uint256 timelockEndBlock; } mapping(bytes32 id => ConfigProposal) private s_proposedConfig; - event ConfigProposed(bytes32 id, bytes32 fromHash, bytes toBytes); - event ConfigUpdated(bytes32 id, bytes32 fromHash, bytes toBytes); + event ConfigProposed(bytes32 id, bytes toBytes); + event ConfigUpdated(bytes32 id, bytes toBytes); error InvalidProposal(); error IdentifierIsReserved(bytes32 id); + error AlreadyApplied(); // ================================================================ // | Config state | // ================================================================ - bytes32 internal s_configHash; - error InvalidConfigData(); TimeLockProposal internal s_timelockProposal; @@ -100,43 +94,34 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // Set the initial configuration for the Router s_route[ROUTER_ID] = address(this); _updateConfig(selfConfig); - s_configHash = keccak256(selfConfig); } // ================================================================ // | Route methods | // ================================================================ - function _getContractById(bytes32 id, bool useProposed) internal view returns (address) { - if (!useProposed) { - address currentImplementation = s_route[id]; - if (currentImplementation != address(0)) { - return currentImplementation; - } - } else { - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { - if (id == s_proposedContractSet.ids[i]) { - // NOTE: proposals can be used immediately - return s_proposedContractSet.to[i]; - } - } - } - revert RouteNotFound(id); - } - /** * @inheritdoc IRouterBase */ - function getContractById(bytes32 id) external view override returns (address routeDestination) { - routeDestination = _getContractById(id, false); + function getContractById(bytes32 id) public view override returns (address) { + address currentImplementation = s_route[id]; + if (currentImplementation != address(0)) { + return currentImplementation; + } + revert RouteNotFound(id); } /** * @inheritdoc IRouterBase */ - function getContractById(bytes32 id, bool useProposed) external view override returns (address routeDestination) { - routeDestination = _getContractById(id, useProposed); + function getProposedContractById(bytes32 id) public view override returns (address) { + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { + if (id == s_proposedContractSet.ids[i]) { + return s_proposedContractSet.to[i]; + } + } + revert RouteNotFound(id); } // ================================================================ @@ -179,32 +164,23 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme uint256 timelockEndBlock = block.number + s_timelockBlocks; - s_proposedContractSet = ContractProposalSet(proposedContractSetIds, proposedContractSetAddresses, timelockEndBlock); + s_proposedContractSet = ContractProposalSet({ + ids: proposedContractSetIds, + to: proposedContractSetAddresses, + timelockEndBlock: timelockEndBlock + }); // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH for (uint256 i = 0; i < proposedContractSetIds.length; ++i) { - emit ContractProposed( - proposedContractSetIds[i], - s_route[proposedContractSetIds[i]], - proposedContractSetAddresses[i], - timelockEndBlock - ); + emit ContractProposed({ + proposedContractSetId: proposedContractSetIds[i], + proposedContractSetFromAddress: s_route[proposedContractSetIds[i]], + proposedContractSetToAddress: proposedContractSetAddresses[i], + timelockEndBlock: timelockEndBlock + }); } } - /** - * @inheritdoc IRouterBase - */ - function validateProposedContracts(bytes32 id, bytes calldata data) external override returns (bytes memory) { - return _validateProposedContracts(id, data); - } - - /** - * @dev Must be implemented by the inheriting contract - * Use to test an end to end request through the system - */ - function _validateProposedContracts(bytes32 id, bytes calldata data) internal virtual returns (bytes memory); - /** * @inheritdoc IRouterBase */ @@ -218,20 +194,15 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme address from = s_route[id]; address to = s_proposedContractSet.to[i]; s_route[id] = to; - emit ContractUpdated(id, from, to); + emit ContractUpdated({id: id, from: from, to: to}); } + + delete s_proposedContractSet; } // ================================================================ // | Config Proposal methods | // ================================================================ - /** - * @notice Get the hash of the Router's current configuration - * @return config hash of config bytes - */ - function getConfigHash() external view returns (bytes32 config) { - return s_configHash; - } /** * @dev Must be implemented by inheriting contract @@ -242,19 +213,29 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme /** * @inheritdoc IRouterBase */ - function proposeConfigUpdate(bytes32 id, bytes calldata config) external override onlyOwner { - address implAddr = _getContractById(id, false); - bytes32 currentConfigHash; - if (implAddr == address(this)) { - currentConfigHash = s_configHash; - } else { - currentConfigHash = IConfigurable(implAddr).getConfigHash(); - } - if (currentConfigHash == keccak256(config)) { - revert InvalidProposal(); + function proposeConfigUpdateSelf(bytes calldata config) external override onlyOwner { + s_proposedConfig[ROUTER_ID] = ConfigProposal({to: config, timelockEndBlock: block.number + s_timelockBlocks}); + emit ConfigProposed({id: ROUTER_ID, toBytes: config}); + } + + /** + * @inheritdoc IRouterBase + */ + function updateConfigSelf() external override onlyOwner { + ConfigProposal memory proposal = s_proposedConfig[ROUTER_ID]; + if (block.number < proposal.timelockEndBlock) { + revert TimelockInEffect(); } - s_proposedConfig[id] = ConfigProposal(currentConfigHash, config, block.number + s_timelockBlocks); - emit ConfigProposed(id, currentConfigHash, config); + _updateConfig(proposal.to); + emit ConfigUpdated({id: ROUTER_ID, toBytes: proposal.to}); + } + + /** + * @inheritdoc IRouterBase + */ + function proposeConfigUpdate(bytes32 id, bytes calldata config) external override onlyOwner { + s_proposedConfig[id] = ConfigProposal({to: config, timelockEndBlock: block.number + s_timelockBlocks}); + emit ConfigProposed({id: id, toBytes: config}); } /** @@ -262,18 +243,14 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme */ function updateConfig(bytes32 id) external override onlyOwner { ConfigProposal memory proposal = s_proposedConfig[id]; + if (block.number < proposal.timelockEndBlock) { revert TimelockInEffect(); } - if (id == ROUTER_ID) { - _updateConfig(proposal.to); - s_configHash = keccak256(proposal.to); - } else { - try IConfigurable(_getContractById(id, false)).updateConfig(proposal.to) {} catch { - revert InvalidConfigData(); - } - } - emit ConfigUpdated(id, proposal.fromHash, proposal.to); + + IConfigurable(getContractById(id)).updateConfig(proposal.to); + + emit ConfigUpdated({id: id, toBytes: proposal.to}); } // ================================================================ @@ -290,7 +267,11 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme if (blocks > s_maximumTimelockBlocks) { revert ProposedTimelockAboveMaximum(); } - s_timelockProposal = TimeLockProposal(s_timelockBlocks, blocks, uint224(block.number + s_timelockBlocks)); + s_timelockProposal = TimeLockProposal({ + from: s_timelockBlocks, + to: blocks, + timelockEndBlock: uint224(block.number + s_timelockBlocks) + }); } /** @@ -300,6 +281,9 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme if (block.number < s_timelockProposal.timelockEndBlock) { revert TimelockInEffect(); } + if (s_timelockBlocks == s_timelockProposal.to) { + revert AlreadyApplied(); + } s_timelockBlocks = s_timelockProposal.to; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index ec966b7730f..f5a5d1fadb2 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -70,17 +70,10 @@ contract TermsOfServiceAllowList is HasRouter, ITermsOfServiceAllowList, IAccess /** * @inheritdoc ITermsOfServiceAllowList */ - function getMessageHash(address acceptor, address recipient) public pure override returns (bytes32) { + function getMessage(address acceptor, address recipient) public pure override returns (bytes32) { return keccak256(abi.encodePacked(acceptor, recipient)); } - /** - * @inheritdoc ITermsOfServiceAllowList - */ - function getEthSignedMessageHash(bytes32 messageHash) public pure override returns (bytes32) { - return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", messageHash)); - } - /** * @inheritdoc ITermsOfServiceAllowList */ @@ -90,7 +83,10 @@ contract TermsOfServiceAllowList is HasRouter, ITermsOfServiceAllowList, IAccess } // Validate that the signature is correct and the correct data has been signed - if (ecrecover(getEthSignedMessageHash(getMessageHash(acceptor, recipient)), v, r, s) != s_config.signerPublicKey) { + bytes32 prefixedMessage = keccak256( + abi.encodePacked("\x19Ethereum Signed Message:\n32", getMessage(acceptor, recipient)) + ); + if (ecrecover(prefixedMessage, v, r, s) != s_config.signerPublicKey) { revert InvalidSignature(); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol index e9388335e01..dd662f02b56 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol @@ -12,14 +12,7 @@ interface ITermsOfServiceAllowList { * @param recipient - The recipient address that the acceptor is taking responsibility for * @return Hash of the message data */ - function getMessageHash(address acceptor, address recipient) external pure returns (bytes32); - - /** - * @notice Wrap a bytes32 message as an ethereum signed message - * @param messageHash - Message hash produced from "getMessageHash" - * @return Hash of the message data packed as "\x19Ethereum Signed Message\n" + len(msg) + msg - */ - function getEthSignedMessageHash(bytes32 messageHash) external pure returns (bytes32); + function getMessage(address acceptor, address recipient) external pure returns (bytes32); /** * @notice Check if the address is blocked for usage diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol index 4aebd575498..6953bf37b09 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol @@ -5,12 +5,6 @@ pragma solidity ^0.8.19; * @title Configurable contract interface. */ interface IConfigurable { - /** - * @notice Get the hash of the current configuration - * @return config hash of config bytes - */ - function getConfigHash() external returns (bytes32 config); - /** * @notice Set the contract's configuration * @param config bytes containing config data diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index 76cd29722df..aa7868ba56f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -2,6 +2,7 @@ pragma solidity ^0.8.19; import {IRouterBase} from "./IRouterBase.sol"; +import {FulfillResult} from "./FulfillResultCodes.sol"; import {IFunctionsRequest} from "./IFunctionsRequest.sol"; /** @@ -13,7 +14,7 @@ interface IFunctionsRouter is IRouterBase { // This bound ensures we are able to loop over all subscription consumers as needed, // without exceeding gas limits. // Should a user require more consumers, they can use multiple subscriptions. - uint16 maxConsumers; + uint16 maxConsumersPerSubscription; // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network uint96 adminFee; // The function selector that is used when calling back to the Client contract @@ -31,9 +32,8 @@ interface IFunctionsRouter is IRouterBase { /** * @notice The router configuration - * @return config - the router configuration */ - function getConfig() external view returns (Config memory); + function getConfig() external view returns (uint16, uint96, bytes4, uint32[] memory); /** * @notice Sends a request (encoded as data) using the provided subscriptionId @@ -53,6 +53,24 @@ interface IFunctionsRouter is IRouterBase { bytes32 donId ) external returns (bytes32); + /** + * @notice Sends a request (encoded as data) to the proposed contracts + * @param subscriptionId A unique subscription ID allocated by billing system, + * a client can make requests from different contracts referencing the same subscription + * @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + * @param dataVersion Gas limit for the fulfillment callback + * @param callbackGasLimit Gas limit for the fulfillment callback + * @param donId An identifier used to determine which route to send the request along + * @return requestId A unique request identifier + */ + function sendRequestToProposed( + uint64 subscriptionId, + bytes calldata data, + uint16 dataVersion, + uint32 callbackGasLimit, + bytes32 donId + ) external returns (bytes32); + /** * @notice Fulfill the request by: * - calling back the data that the Oracle returned to the client contract @@ -74,7 +92,7 @@ interface IFunctionsRouter is IRouterBase { uint96 costWithoutFulfillment, address transmitter, IFunctionsRequest.Commitment memory commitment - ) external returns (uint8, uint96); + ) external returns (FulfillResult, uint96); /** * @notice Validate requested gas limit is below the subscription max. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 7a8aaf5685f..93d16f70488 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -32,18 +32,9 @@ interface IFunctionsSubscriptions { /** * @notice Get details about a subscription. * @param subscriptionId - ID of the subscription - * @return balance - LINK balance of the subscription in juels. - * @return blockedBalance - amount of LINK balance of the subscription in juels that is blocked for an in flight request. - * @return owner - owner of the subscription. - * @return requestedOwner - proposed owner to move ownership of the subscription to. - * @return consumers - list of consumer address which are able to use this subscription. + * @return subscription - list of consumer address which are able to use this subscription. */ - function getSubscription( - uint64 subscriptionId - ) - external - view - returns (uint96 balance, uint96 blockedBalance, address owner, address requestedOwner, address[] memory consumers); + function getSubscription(uint64 subscriptionId) external view returns (Subscription memory); /** * @notice Get details about a consumer of a subscription. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol index 7e6d6f0c3dd..aaae944264b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol @@ -17,7 +17,7 @@ interface IRouterBase { * @param id A bytes32 identifier for the route * @return contract The current or proposed contract address */ - function getContractById(bytes32 id, bool useProposed) external view returns (address); + function getProposedContractById(bytes32 id) external view returns (address); /** * @notice Return the latest proprosal set @@ -34,16 +34,24 @@ interface IRouterBase { function proposeContractsUpdate(bytes32[] memory proposalSetIds, address[] memory proposalSetAddresses) external; /** - * @notice Tests a proposal for the ability to make a successful upgrade + * @notice Updates the current contract routes to the proposed contracts + * @dev Only callable once timelock has passed + * @dev Only callable by owner */ - function validateProposedContracts(bytes32 id, bytes calldata data) external returns (bytes memory); + function updateContracts() external; /** - * @notice Updates the current contract routes to the proposed contracts + * @notice Proposes new configuration data for the Router contract itself + * @dev Only callable by owner + */ + function proposeConfigUpdateSelf(bytes calldata config) external; + + /** + * @notice Updates configuration data for the Router contract itself * @dev Only callable once timelock has passed * @dev Only callable by owner */ - function updateContracts() external; + function updateConfigSelf() external; /** * @notice Proposes new configuration data for the current (not proposed) contract diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index 21cdd8342ea..fe9fd46930f 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -17,7 +17,7 @@ contract FunctionsRouterSetup is BaseTest { uint16 internal s_timelockBlocks = 0; uint16 internal s_maximumTimelockBlocks = 20; - uint16 internal s_maxConsumers = 100; + uint16 internal s_maxConsumersPerSubscription = 100; uint96 internal s_adminFee = 561724823; bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; @@ -39,7 +39,7 @@ contract FunctionsRouterSetup is BaseTest { // First create the struct to get some type safety IFunctionsRouter.Config memory routerConfig = IFunctionsRouter.Config({ - maxConsumers: s_maxConsumers, + maxConsumersPerSubscription: s_maxConsumersPerSubscription, adminFee: s_adminFee, handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, maxCallbackGasLimits: maxCallbackGasLimits @@ -47,7 +47,7 @@ contract FunctionsRouterSetup is BaseTest { return abi.encode( - routerConfig.maxConsumers, + routerConfig.maxConsumersPerSubscription, routerConfig.adminFee, routerConfig.handleOracleFulfillmentSelector, routerConfig.maxCallbackGasLimits diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index 8bd6236c778..50ee1a77840 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -42,11 +42,12 @@ contract FunctionsClientTestHelper is FunctionsClient { uint32 callbackGasLimit = 20_000; request.initializeRequestForInlineJavaScript(sourceCode); bytes memory requestData = Functions.encodeCBOR(request); - requestId = bytes32( - s_router.validateProposedContracts( - donId, - abi.encode(subscriptionId, requestData, Functions.REQUEST_DATA_VERSION, callbackGasLimit) - ) + requestId = s_router.sendRequestToProposed( + subscriptionId, + requestData, + Functions.REQUEST_DATA_VERSION, + callbackGasLimit, + donId ); emit RequestSent(requestId); emit SendRequestInvoked(requestId, sourceCode, subscriptionId); diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index b954aeced3a..4f1031ee7d8 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -21,14 +21,12 @@ describe('Functions Router - Request lifecycle', () => { }) it('#config', async () => { const config = await contracts.router.getConfig() - expect(config.maxConsumers).to.be.equal( - functionsRouterConfig.maxConsumers, - ) - expect(config.adminFee).to.be.equal(functionsRouterConfig.adminFee) - expect(config.handleOracleFulfillmentSelector).to.be.equal( + expect(config[0]).to.be.equal(functionsRouterConfig.maxConsumers) + expect(config[1]).to.be.equal(functionsRouterConfig.adminFee) + expect(config[2]).to.be.equal( functionsRouterConfig.handleOracleFulfillmentSelector, ) - expect(config.maxCallbackGasLimits.toString()).to.be.equal( + expect(config[3].toString()).to.be.equal( functionsRouterConfig.maxCallbackGasLimits.toString(), ) }) diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 0f088129d70..8cf513297e6 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -129,7 +129,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.subOwner) .acceptSubscriptionOwnerTransfer(1203123123), - ).to.be.revertedWith(`MustBeRequestedOwner`) + ).to.be.revertedWith(`MustBeProposedOwner`) }) it('must be requested owner to accept', async function () { await expect( @@ -141,7 +141,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.subOwner) .acceptSubscriptionOwnerTransfer(subId), - ).to.be.revertedWith(`MustBeRequestedOwner("${roles.strangerAddress}")`) + ).to.be.revertedWith(`MustBeProposedOwner`) }) it('requested owner can accept', async function () { await acceptTermsOfService( @@ -773,13 +773,13 @@ describe('Functions Router - Subscriptions', () => { // Accept ToS for client contract const acceptorAddress = roles.subOwnerAddress const recipientAddress = contracts.client.address - const messageHash = await contracts.accessControl.getMessageHash( + const message = await contracts.accessControl.getMessage( acceptorAddress, recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) const flatSignature = await wallet.signMessage( - ethers.utils.arrayify(messageHash), + ethers.utils.arrayify(message), ) const { r, s, v } = ethers.utils.splitSignature(flatSignature) await contracts.client diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index c7d9db434da..0a89562db9a 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -31,13 +31,13 @@ after(() => { describe('Gas Golf', () => { it('taking a swing', async () => { // User signs Terms of Service - const messageHash = await contracts.accessControl.getMessageHash( + const message = await contracts.accessControl.getMessage( roles.consumerAddress, roles.consumerAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) const flatSignature = await wallet.signMessage( - ethers.utils.arrayify(messageHash), + ethers.utils.arrayify(message), ) const { r, s, v } = ethers.utils.splitSignature(flatSignature) const acceptTermsOfServiceTx = await contracts.accessControl diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 55c554413ee..4797dd61af4 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -60,28 +60,27 @@ describe('FunctionsRouter - Base', () => { }) it('Owner can update config of the Router', async () => { - const beforeConfigHash = await contracts.router.getConfigHash() + const beforeConfig = await contracts.router.getConfig() await expect( - contracts.router.proposeConfigUpdate( - ids.routerId, + contracts.router.proposeConfigUpdateSelf( ethers.utils.defaultAbiCoder.encode( ['uint16', 'uint96', 'bytes4', 'uint32[]'], [2000, 1, 0x0ca76175, [300_000, 500_000]], ), ), ).to.emit(contracts.router, 'ConfigProposed') - await expect(contracts.router.updateConfig(ids.routerId)).to.emit( + await expect(contracts.router.updateConfigSelf()).to.emit( contracts.router, 'ConfigUpdated', ) - const afterConfigHash = await contracts.router.getConfigHash() - expect(beforeConfigHash).to.not.equal(afterConfigHash) + const afterConfig = await contracts.router.getConfig() + expect(beforeConfig).to.not.equal(afterConfig) }) it('Config of a contract on a route can be updated', async () => { - const beforeConfigHash = await contracts.coordinator.getConfigHash() + const beforeConfig = await contracts.coordinator.getConfig() await expect( contracts.router.proposeConfigUpdate( @@ -112,18 +111,18 @@ describe('FunctionsRouter - Base', () => { 'ConfigUpdated', ) - const afterConfigHash = await contracts.router.getConfigHash() - expect(beforeConfigHash).to.not.equal(afterConfigHash) + const afterConfig = await contracts.router.getConfig() + expect(beforeConfig).to.not.equal(afterConfig) }) it('returns the config set on the Router', async () => { const config = await contracts.router.connect(roles.stranger).getConfig() - expect(config.maxConsumers).to.equal(functionsRouterConfig.maxConsumers) - expect(config.adminFee).to.equal(functionsRouterConfig.adminFee) - expect(config.handleOracleFulfillmentSelector).to.equal( + expect(config[0]).to.equal(functionsRouterConfig.maxConsumers) + expect(config[1]).to.equal(functionsRouterConfig.adminFee) + expect(config[2]).to.equal( functionsRouterConfig.handleOracleFulfillmentSelector, ) - expect(config.maxCallbackGasLimits.toString()).to.equal( + expect(config[3].toString()).to.equal( functionsRouterConfig.maxCallbackGasLimits.toString(), ) }) diff --git a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts index 47329fbcbdf..261196d1b36 100644 --- a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts +++ b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts @@ -19,12 +19,12 @@ beforeEach(async () => { describe('ToS Access Control', () => { describe('Accepting', () => { it('can only be done with a valid signature', async () => { - const messageHash = await contracts.accessControl.getMessageHash( + const message = await contracts.accessControl.getMessage( roles.strangerAddress, roles.strangerAddress, ) const flatSignature = await roles.stranger.signMessage( - ethers.utils.arrayify(messageHash), + ethers.utils.arrayify(message), ) const { r, s, v } = ethers.utils.splitSignature(flatSignature) await expect( @@ -61,13 +61,13 @@ describe('ToS Access Control', () => { it('can be done by Contract Accounts if recipient themself', async () => { const acceptorAddress = roles.consumerAddress const recipientAddress = contracts.client.address - const messageHash = await contracts.accessControl.getMessageHash( + const message = await contracts.accessControl.getMessage( acceptorAddress, recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) const flatSignature = await wallet.signMessage( - ethers.utils.arrayify(messageHash), + ethers.utils.arrayify(message), ) const { r, s, v } = ethers.utils.splitSignature(flatSignature) await contracts.client @@ -81,15 +81,15 @@ describe('ToS Access Control', () => { it('cannot be done by Contract Accounts that if they are not the recipient', async () => { const acceptorAddress = roles.consumerAddress const recipientAddress = contracts.coordinator.address - const messageHash = await contracts.accessControl.getMessageHash( + const message = await contracts.accessControl.getMessage( acceptorAddress, recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) const flatSignature = await wallet.signMessage( - ethers.utils.arrayify(messageHash), + ethers.utils.arrayify(message), ) - let { r, s, v } = ethers.utils.splitSignature(flatSignature) + const { r, s, v } = ethers.utils.splitSignature(flatSignature) await expect( contracts.client .connect(roles.consumer) diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index ad3a01b9bd3..8eddd04029a 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -161,14 +161,12 @@ export async function acceptTermsOfService( recipientAddress: string, ) { const acceptorAddress = await acceptor.getAddress() - const messageHash = await accessControl.getMessageHash( + const message = await accessControl.getMessage( acceptorAddress, recipientAddress, ) const wallet = new ethers.Wallet(accessControlMockPrivateKey) - const flatSignature = await wallet.signMessage( - ethers.utils.arrayify(messageHash), - ) + const flatSignature = await wallet.signMessage(ethers.utils.arrayify(message)) const { r, s, v } = ethers.utils.splitSignature(flatSignature) return accessControl .connect(acceptor) diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index 39732cfdc4d..02f71ba6926 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -31,8 +31,8 @@ var ( ) var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"messageHash\",\"type\":\"bytes32\"}],\"name\":\"getEthSignedMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessageHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620011e2380380620011e2833981016040819052620000349162000156565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660805262000076816200008b565b80516020909101206000555062000284915050565b60008082806020019051810190620000a4919062000241565b6040805180820182528315158082526001600160a01b0384166020928301819052600480546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013d57600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016a57600080fd5b8251620001778162000127565b602084810151919350906001600160401b03808211156200019757600080fd5b818601915086601f830112620001ac57600080fd5b815181811115620001c157620001c162000140565b604051601f8201601f19908116603f01168101908382118183101715620001ec57620001ec62000140565b8160405282815289868487010111156200020557600080fd5b600093505b828410156200022957848401860151818501870152928501926200020a565b60008684830101528096505050505050509250929050565b600080604083850312156200025557600080fd5b825180151581146200026657600080fd5b6020840151909250620002798162000127565b809150509250929050565b608051610f34620002ae600039600081816103ee015281816105c8015261072e0152610f346000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c8063817ef62e116100815780639883c10d1161005b5780639883c10d14610193578063a5e1d61d1461019b578063fa540801146101ae57600080fd5b8063817ef62e1461015857806382184c7b1461016d5780638cc6acce1461018057600080fd5b806347663acb116100b257806347663acb146101015780636b14daf81461011457806380e8a1511461013757600080fd5b8063181f5a77146100ce5780633908c4d4146100ec575b600080fd5b6100d661020f565b6040516100e39190610ad0565b60405180910390f35b6100ff6100fa366004610b61565b61022b565b005b6100ff61010f366004610bc6565b6103ec565b610127610122366004610be3565b61052d565b60405190151581526020016100e3565b61014a610145366004610c68565b610557565b6040519081526020016100e3565b6101606105b5565b6040516100e39190610ca1565b6100ff61017b366004610bc6565b6105c6565b6100ff61018e366004610d2a565b610716565b60005461014a565b6101276101a9366004610bc6565b61079b565b61014a6101bc366004610df9565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c8101829052600090605c01604051602081830303815290604052805190602001209050919050565b6040518060600160405280602c8152602001610efc602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526003602052604090205460ff161561028b576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600454610100900473ffffffffffffffffffffffffffffffffffffffff1660016102b86101bc8888610557565b6040805160008152602081018083529290925260ff851690820152606081018690526080810185905260a0016020604051602081039080840390855afa158015610306573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff161461035d576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff85161415806103a257503373ffffffffffffffffffffffffffffffffffffffff8616148015906103a25750333b155b156103d9576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103e46001856107dc565b505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610459573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061047d9190610e12565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146104e1576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60045460009060ff1661054257506001610550565b61054d6001856107fe565b90505b9392505050565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60606105c1600161082d565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610633573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106579190610e12565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106bb576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c660018261083a565b5073ffffffffffffffffffffffffffffffffffffffff16600090815260036020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610785576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61078e8161085c565b8051602090910120600055565b60045460009060ff166107b057506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526003602052604090205460ff1690565b60006105508373ffffffffffffffffffffffffffffffffffffffff8416610932565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001830160205260408120541515610550565b6060600061055083610981565b60006105508373ffffffffffffffffffffffffffffffffffffffff84166109dd565b600080828060200190518101906108739190610e2f565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600480547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6000818152600183016020526040812054610979575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556105af565b5060006105af565b6060816000018054806020026020016040519081016040528092919081815260200182805480156109d157602002820191906000526020600020905b8154815260200190600101908083116109bd575b50505050509050919050565b60008181526001830160205260408120548015610ac6576000610a01600183610e63565b8554909150600090610a1590600190610e63565b9050818114610a7a576000866000018281548110610a3557610a35610e9d565b9060005260206000200154905080876000018481548110610a5857610a58610e9d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610a8b57610a8b610ecc565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506105af565b60009150506105af565b600060208083528351808285015260005b81811015610afd57858101830151858201604001528201610ae1565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610b5e57600080fd5b50565b600080600080600060a08688031215610b7957600080fd5b8535610b8481610b3c565b94506020860135610b9481610b3c565b93506040860135925060608601359150608086013560ff81168114610bb857600080fd5b809150509295509295909350565b600060208284031215610bd857600080fd5b813561055081610b3c565b600080600060408486031215610bf857600080fd5b8335610c0381610b3c565b9250602084013567ffffffffffffffff80821115610c2057600080fd5b818601915086601f830112610c3457600080fd5b813581811115610c4357600080fd5b876020828501011115610c5557600080fd5b6020830194508093505050509250925092565b60008060408385031215610c7b57600080fd5b8235610c8681610b3c565b91506020830135610c9681610b3c565b809150509250929050565b6020808252825182820181905260009190848201906040850190845b81811015610cef57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610cbd565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610d3c57600080fd5b813567ffffffffffffffff80821115610d5457600080fd5b818401915084601f830112610d6857600080fd5b813581811115610d7a57610d7a610cfb565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610dc057610dc0610cfb565b81604052828152876020848701011115610dd957600080fd5b826020860160208301376000928101602001929092525095945050505050565b600060208284031215610e0b57600080fd5b5035919050565b600060208284031215610e2457600080fd5b815161055081610b3c565b60008060408385031215610e4257600080fd5b82518015158114610e5257600080fd5b6020840151909250610c9681610b3c565b818103818111156105af577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200118e3803806200118e83398101604081905262000034916200014b565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b038216608052620000768162000080565b5050505062000279565b6000808280602001905181019062000099919062000236565b6040805180820182528315158082526001600160a01b0384166020928301819052600380546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013257600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200015f57600080fd5b82516200016c816200011c565b602084810151919350906001600160401b03808211156200018c57600080fd5b818601915086601f830112620001a157600080fd5b815181811115620001b657620001b662000135565b604051601f8201601f19908116603f01168101908382118183101715620001e157620001e162000135565b816040528281528986848701011115620001fa57600080fd5b600093505b828410156200021e5784840186015181850187015292850192620001ff565b60008684830101528096505050505050509250929050565b600080604083850312156200024a57600080fd5b825180151581146200025b57600080fd5b60208401519092506200026e816200011c565b809150509250929050565b608051610eeb620002a3600039600081816103cb0152818161054701526106ad0152610eeb6000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c8063817ef62e116100765780638cc6acce1161005b5780638cc6acce14610139578063a39b06e31461014c578063a5e1d61d1461016d57600080fd5b8063817ef62e1461011157806382184c7b1461012657600080fd5b8063181f5a77146100a85780633908c4d4146100c657806347663acb146100db5780636b14daf8146100ee575b600080fd5b6100b0610180565b6040516100bd9190610aa3565b60405180910390f35b6100d96100d4366004610b31565b61019c565b005b6100d96100e9366004610b96565b6103c9565b6101016100fc366004610bb3565b61050a565b60405190151581526020016100bd565b610119610534565b6040516100bd9190610c38565b6100d9610134366004610b96565b610545565b6100d9610147366004610cc1565b610695565b61015f61015a366004610d90565b610710565b6040519081526020016100bd565b61010161017b366004610b96565b61076e565b6040518060600160405280602c8152602001610eb3602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526002602052604090205460ff16156101fc576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006102088686610710565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206003546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156102e2573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610339576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061037e57503373ffffffffffffffffffffffffffffffffffffffff87161480159061037e5750333b155b156103b5576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103c06000866107af565b50505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610436573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061045a9190610dc9565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146104be576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60035460009060ff1661051f5750600161052d565b61052a6000856107d1565b90505b9392505050565b60606105406000610800565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156105b2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105d69190610dc9565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461063a576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61064560008261080d565b5073ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610704576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61070d8161082f565b50565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60035460009060ff1661078357506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b600061052d8373ffffffffffffffffffffffffffffffffffffffff8416610905565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561052d565b6060600061052d83610954565b600061052d8373ffffffffffffffffffffffffffffffffffffffff84166109b0565b600080828060200190518101906108469190610de6565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600380547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b600081815260018301602052604081205461094c57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610768565b506000610768565b6060816000018054806020026020016040519081016040528092919081815260200182805480156109a457602002820191906000526020600020905b815481526020019060010190808311610990575b50505050509050919050565b60008181526001830160205260408120548015610a995760006109d4600183610e1a565b85549091506000906109e890600190610e1a565b9050818114610a4d576000866000018281548110610a0857610a08610e54565b9060005260206000200154905080876000018481548110610a2b57610a2b610e54565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610a5e57610a5e610e83565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610768565b6000915050610768565b600060208083528351808285015260005b81811015610ad057858101830151858201604001528201610ab4565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff8116811461070d57600080fd5b600080600080600060a08688031215610b4957600080fd5b8535610b5481610b0f565b94506020860135610b6481610b0f565b93506040860135925060608601359150608086013560ff81168114610b8857600080fd5b809150509295509295909350565b600060208284031215610ba857600080fd5b813561052d81610b0f565b600080600060408486031215610bc857600080fd5b8335610bd381610b0f565b9250602084013567ffffffffffffffff80821115610bf057600080fd5b818601915086601f830112610c0457600080fd5b813581811115610c1357600080fd5b876020828501011115610c2557600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b81811015610c8657835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610c54565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610cd357600080fd5b813567ffffffffffffffff80821115610ceb57600080fd5b818401915084601f830112610cff57600080fd5b813581811115610d1157610d11610c92565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610d5757610d57610c92565b81604052828152876020848701011115610d7057600080fd5b826020860160208301376000928101602001929092525095945050505050565b60008060408385031215610da357600080fd5b8235610dae81610b0f565b91506020830135610dbe81610b0f565b809150509250929050565b600060208284031215610ddb57600080fd5b815161052d81610b0f565b60008060408385031215610df957600080fd5b82518015158114610e0957600080fd5b6020840151909250610dbe81610b0f565b81810381811115610768577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI @@ -193,9 +193,9 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetAllAllo return _TermsOfServiceAllowList.Contract.GetAllAllowedSenders(&_TermsOfServiceAllowList.CallOpts) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetMessage(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) { var out []interface{} - err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getConfigHash") + err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getMessage", acceptor, recipient) if err != nil { return *new([32]byte), err @@ -207,56 +207,12 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetConfigHash(opt } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) GetConfigHash() ([32]byte, error) { - return _TermsOfServiceAllowList.Contract.GetConfigHash(&_TermsOfServiceAllowList.CallOpts) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) GetMessage(acceptor common.Address, recipient common.Address) ([32]byte, error) { + return _TermsOfServiceAllowList.Contract.GetMessage(&_TermsOfServiceAllowList.CallOpts, acceptor, recipient) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetConfigHash() ([32]byte, error) { - return _TermsOfServiceAllowList.Contract.GetConfigHash(&_TermsOfServiceAllowList.CallOpts) -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetEthSignedMessageHash(opts *bind.CallOpts, messageHash [32]byte) ([32]byte, error) { - var out []interface{} - err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getEthSignedMessageHash", messageHash) - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) GetEthSignedMessageHash(messageHash [32]byte) ([32]byte, error) { - return _TermsOfServiceAllowList.Contract.GetEthSignedMessageHash(&_TermsOfServiceAllowList.CallOpts, messageHash) -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetEthSignedMessageHash(messageHash [32]byte) ([32]byte, error) { - return _TermsOfServiceAllowList.Contract.GetEthSignedMessageHash(&_TermsOfServiceAllowList.CallOpts, messageHash) -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetMessageHash(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) { - var out []interface{} - err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getMessageHash", acceptor, recipient) - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) GetMessageHash(acceptor common.Address, recipient common.Address) ([32]byte, error) { - return _TermsOfServiceAllowList.Contract.GetMessageHash(&_TermsOfServiceAllowList.CallOpts, acceptor, recipient) -} - -func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetMessageHash(acceptor common.Address, recipient common.Address) ([32]byte, error) { - return _TermsOfServiceAllowList.Contract.GetMessageHash(&_TermsOfServiceAllowList.CallOpts, acceptor, recipient) +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetMessage(acceptor common.Address, recipient common.Address) ([32]byte, error) { + return _TermsOfServiceAllowList.Contract.GetMessage(&_TermsOfServiceAllowList.CallOpts, acceptor, recipient) } func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) HasAccess(opts *bind.CallOpts, user common.Address, arg1 []byte) (bool, error) { @@ -511,11 +467,7 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowList) Address() common.Addres type TermsOfServiceAllowListInterface interface { GetAllAllowedSenders(opts *bind.CallOpts) ([]common.Address, error) - GetConfigHash(opts *bind.CallOpts) ([32]byte, error) - - GetEthSignedMessageHash(opts *bind.CallOpts, messageHash [32]byte) ([32]byte, error) - - GetMessageHash(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) + GetMessage(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) HasAccess(opts *bind.CallOpts, user common.Address, arg1 []byte) (bool, error) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index fe3daaf8e1d..c76a387bf8f 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -64,8 +64,8 @@ type IFunctionsRequestCommitment struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005adb38038062005adb833981016040819052620000349162000462565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000154565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001ff565b805160209091012060075550600d80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006349350505050565b336001600160a01b03821603620001ae5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000223919062000572565b985098509850985098509850985098509850600081136200025b576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260098054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f906200041b908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200044757600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200047857600080fd5b62000483846200042f565b602085810151919450906001600160401b0380821115620004a357600080fd5b818701915087601f830112620004b857600080fd5b815181811115620004cd57620004cd6200044c565b604051601f8201601f19908116603f01168101908382118183101715620004f857620004f86200044c565b816040528281528a868487010111156200051157600080fd5b600093505b8284101562000535578484018601518185018701529285019262000516565b600086848301015280975050505050505062000554604085016200042f565b90509250925092565b805163ffffffff811681146200044757600080fd5b60008060008060008060008060006101208a8c0312156200059257600080fd5b6200059d8a6200055d565b9850620005ad60208b016200055d565b9750620005bd60408b016200055d565b9650620005cd60608b016200055d565b9550620005dd60808b016200055d565b60a08b01519095506001600160501b0381168114620005fb57600080fd5b60c08b015190945061ffff811681146200061457600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a0516154506200068b6000396000818161069101528181610ac801528181610eeb01528181610fc9015281816118cb01528181611b650152818161313d015261399a0152600061129c01526154506000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806385b214cf116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610526578063d328a91e14610539578063e3d0e71214610541578063f2fde38b1461055457600080fd5b8063b1dc65a4146103f5578063bdd7e88014610408578063c3f909d41461042857600080fd5b80639883c10d116100c85780639883c10d146103bb578063af1296d3146103cd578063afcb95d7146103d557600080fd5b806385b214cf1461035d5780638cc6acce146103805780638da5cb5b1461039357600080fd5b806366316d8d1161015b578063807560311161013557806380756031146102c057806381411834146102d357806381f1b938146102e857806381ff7048146102f057600080fd5b806366316d8d1461029257806379ba5097146102a55780637f15e166146102ad57600080fd5b806326ceabac1161018c57806326ceabac146102445780632a905ccc14610257578063533989871461027c57600080fd5b8063083a5466146101b35780630e7ada39146101c8578063181f5a77146101fb575b600080fd5b6101c66101c1366004613c2d565b610567565b005b6101db6101d6366004613e5a565b6105bc565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b6102376040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101f29190613f8f565b6101c6610252366004613fa9565b6105ea565b61025f61068c565b6040516bffffffffffffffffffffffff90911681526020016101f2565b61028461074a565b6040516101f2929190614017565b6101c66102a03660046140a7565b6109ce565b6101c6610b88565b6101c66102bb366004613c2d565b610c8a565b6101c66102ce3660046140e0565b610cda565b6102db610d91565b6040516101f29190614135565b610237610e00565b61033a60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101f2565b61037061036b366004614148565b610ed1565b60405190151581526020016101f2565b6101c661038e366004614161565b610fb1565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101f2565b6007545b6040519081526020016101f2565b6103bf611036565b6040805160018152600060208201819052918101919091526060016101f2565b6101c66104033660046141e3565b611129565b61041b61041636600461429a565b61185a565b6040516101f291906143fc565b600954600a54600b54600d546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101f2565b61025f61053436600461440b565b611b61565b610237611d2d565b6101c661054f36600461452d565b611d84565b6101c6610562366004613fa9565b6127a8565b61056f6127b9565b60008190036105aa576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60106105b782848361469b565b505050565b60095474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061062557503373ffffffffffffffffffffffffffffffffffffffff8216145b61065b576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600f6020526040812061068991613b72565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106fa573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261074091908101906147dc565b6020015192915050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107b257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610787575b505050505090506000815167ffffffffffffffff8111156107d5576107d5613c6f565b60405190808252806020026020018201604052801561080857816020015b60608152602001906001900390816107f35790505b50905060005b82518110156109c457600f600084838151811061082d5761082d614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461087a906145fa565b90506000036108b5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f60008483815181106108cb576108cb614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610918906145fa565b80601f0160208091040260200160405190810160405280929190818152602001828054610944906145fa565b80156109915780601f1061096657610100808354040283529160200191610991565b820191906000526020600020905b81548152906001019060200180831161097457829003601f168201915b50505050508282815181106109a8576109a8614906565b6020026020010181905250806109bd90614964565b905061080e565b5090939092509050565b6109d661283c565b806bffffffffffffffffffffffff16600003610a0c5750336000908152600c60205260409020546bffffffffffffffffffffffff165b336000908152600c60205260409020546bffffffffffffffffffffffff80831691161015610a66576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c602052604081208054839290610a939084906bffffffffffffffffffffffff1661499c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610aea7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b6b57600080fd5b505af1158015610b7f573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610c0e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c926127b9565b6000819003610ccd576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e6105b782848361469b565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d255750610d04336129cd565b8015610d2557503373ffffffffffffffffffffffffffffffffffffffff8416145b610d5b576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f60205260409020610d8b82848361469b565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610df657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dcb575b5050505050905090565b606060108054610e0f906145fa565b9050600003610e4a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60108054610e57906145fa565b80601f0160208091040260200160405190810160405280929190818152602001828054610e83906145fa565b8015610df65780601f10610ea557610100808354040283529160200191610df6565b820191906000526020600020905b815481529060010190602001808311610eb357509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f42576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260086020526040902054610f5d57506000919050565b60008281526008602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610fa09084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611020576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61102981612ab6565b8051602090910120600755565b600954600d54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110d0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110f491906149e2565b50935050925050828015611116575061110d8142614a32565b8463ffffffff16105b1561112157600b5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161117f91849163ffffffff851691908e908e9081908401838280828437600092019190915250612dbf92505050565b6111b5576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461128a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610c05565b6112988b8b8b8b8b8b612dc8565b60007f0000000000000000000000000000000000000000000000000000000000000000156112f5576002826020015183604001516112d69190614a45565b6112e09190614a8d565b6112eb906001614a45565b60ff16905061130b565b6020820151611305906001614a45565b60ff1690505b888114611374576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610c05565b8887146113dd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610c05565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561142057611420614aaf565b600281111561143157611431614aaf565b905250905060028160200151600281111561144e5761144e614aaf565b14801561149557506006816000015160ff168154811061147057611470614906565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610c05565b5050505050611508613bac565b6000808a8a60405161151b929190614ade565b604051908190038120611532918e90602001614aee565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561183c57600060018489846020811061159b5761159b614906565b6115a891901a601b614a45565b8e8e868181106115ba576115ba614906565b905060200201358d8d878181106115d3576115d3614906565b9050602002013560405160008152602001604052604051611610949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611632573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156116b2576116b2614aaf565b60028111156116c3576116c3614aaf565b90525092506001836020015160028111156116e0576116e0614aaf565b14611747576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610c05565b8251600090879060ff16601f811061176157611761614906565b602002015173ffffffffffffffffffffffffffffffffffffffff16146117e3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610c05565b8086846000015160ff16601f81106117fd576117fd614906565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611828600186614a45565b9450508061183590614964565b905061157c565b50505061184d833383858e8e612e76565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611922576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61192f6040830183614b02565b9050600003611969576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a001604052808460600160208101906119899190614b67565b67ffffffffffffffff1681526020908101906119a790860186613fa9565b73ffffffffffffffffffffffffffffffffffffffff1681526020016119d260e0860160c08701614b84565b63ffffffff1681523a60208201526040016119f4610100860160e08701614ba1565b6bffffffffffffffffffffffff1690529050611a61611a166040850185614b02565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a5b9250505060a0860160808701614bbe565b83613044565b9150611a706020840184613fa9565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611ac09190614b67565b611ad06040890160208a01613fa9565b611add60408a018a614b02565b611aed60a08c0160808d01614bbe565b60a08c0135611b0260e08e0160c08f01614b84565b8c604051602001611b1391906143fc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b53999897969594939291614bdb565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611c0157600080fd5b505afa158015611c15573d6000803e3d6000fd5b50505050620f4240821115611c56576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c6061068c565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611d0488888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105bc915050565b69ffffffffffffffffffff169050611d1e86868386613539565b93505050505b95945050505050565b6060600e8054611d3c906145fa565b9050600003611d77576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e8054610e57906145fa565b855185518560ff16601f831115611df7576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610c05565b80600003611e61576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610c05565b818314611eef576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610c05565b611efa816003614c9f565b8311611f62576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610c05565b611f6a6127b9565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611fb190886136a9565b6005541561216657600554600090611fcb90600190614a32565b9050600060058281548110611fe257611fe2614906565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061201c5761201c614906565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061209c5761209c614cb6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061210557612105614cb6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611fb1915050565b60005b8151518110156125cd576000600460008460000151848151811061218f5761218f614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121d9576121d9614aaf565b14612240576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610c05565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061227157612271614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561231257612312614aaf565b0217905550600091506123229050565b600460008460200151848151811061233c5761233c614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561238657612386614aaf565b146123ed576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610c05565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061242057612420614906565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124c1576124c1614aaf565b0217905550508251805160059250839081106124df576124df614906565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061255b5761255b614906565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125c581614964565b915050612169565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161268591849174010000000000000000000000000000000000000000900416614ce5565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126e44630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516136c6565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861279b988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614d02565b60405180910390a161184d565b6127b06127b9565b61068981613771565b60005473ffffffffffffffffffffffffffffffffffffffff16331461283a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c05565b565b6000612846610d91565b90508051600003612883576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600d546000916128a2916bffffffffffffffffffffffff16614d88565b905060005b825181101561296e5781600c60008584815181106128c7576128c7614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff1661292f9190614db3565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061296790614964565b90506128a7565b50815161297b9082614dd8565b600d805460009061299b9084906bffffffffffffffffffffffff1661499c565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a3357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612a08575b5050505050905060005b8151811015612aac578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a6f57612a6f614906565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a9c575060019392505050565b612aa581614964565b9050612a3d565b5060009392505050565b600080600080600080600080600089806020019051810190612ad89190614e08565b98509850985098509850985098509850985060008113612b27576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610c05565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600980547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b169098179990991795909516959095179290921794909416949094179290921792909216179055600a839055600b829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612dab908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60019392505050565b6000612dd5826020614c9f565b612de0856020614c9f565b612dec88610144614eb4565b612df69190614eb4565b612e009190614eb4565b612e0b906000614eb4565b9050368114610b7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610c05565b606080808080612e8886880188614fa2565b8451949950929750909550935091501580612ea557508351855114155b80612eb257508251855114155b80612ebf57508151855114155b80612ecc57508051855114155b15612f03576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8551811015613036576000612f9b878381518110612f2657612f26614906565b6020026020010151878481518110612f4057612f40614906565b6020026020010151878581518110612f5a57612f5a614906565b6020026020010151878681518110612f7457612f74614906565b6020026020010151878781518110612f8e57612f8e614906565b6020026020010151613866565b90506000816006811115612fb157612fb1614aaf565b1480612fce57506001816006811115612fcc57612fcc614aaf565b145b1561302557868281518110612fe557612fe5614906565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061302f81614964565b9050612f06565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260095461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115613103576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061310f85846105bc565b90506000613137846040015185606001518469ffffffffffffffffffff168760800151613539565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa1580156131db573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052613221919081019061507f565b505050602089015189516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d090604401606060405180830381865afa1580156132b2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132d69190615176565b509150506bffffffffffffffffffffffff85166132f3838561499c565b6bffffffffffffffffffffffff161015613339576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006133b8308a602001518b6000015185600161335691906151c8565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001876bffffffffffffffffffffffff168152602001600960000160109054906101000a900463ffffffff1663ffffffff16426134799190614eb4565b64ffffffffff168152602080820184905269ffffffffffffffffffff8a1660408084019190915260095463ffffffff680100000000000000008204811660608601526c010000000000000000000000009091041660809093019290925290519199506134e7918a91016143fc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815281516020928301206000938452600890925290912055509498975050505050505050565b600080613544611036565b905060008113613583576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610c05565b60095460009087906135b99063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614ce5565b6135c39190614ce5565b63ffffffff1690506000612710600960010154886135e19190614c9f565b6135eb91906151e9565b6135f59088614eb4565b90506000838361360d84670de0b6b3a7640000614c9f565b6136179190614c9f565b61362191906151e9565b905060006136406bffffffffffffffffffffffff808916908a16614eb4565b9050613658816b033b2e3c9fd0803ce8000000614a32565b821115613691576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61369b8183614eb4565b9a9950505050505050505050565b60006136b3610d91565b5111156136c2576136c261283c565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136ea999897969594939291906151fd565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137f0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c05565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808380602001905181019061387d91906152a7565b60008881526008602052604090205490915061389d576002915050611d24565b806040516020016138ae91906143fc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600890935291205414613900576006915050611d24565b600061390a611036565b905060008113613949576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610c05565b60008161395e3a670de0b6b3a7640000614c9f565b61396891906151e9565b90506000836101400151846101200151613982919061537a565b6139939064ffffffffff1683614c9f565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139f49190614db3565b338c6040518763ffffffff1660e01b8152600401613a1796959493929190615398565b60408051808303816000875af1158015613a35573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a599190615414565b9150915060008260ff166006811115613a7457613a74614aaf565b90506000816006811115613a8a57613a8a614aaf565b1480613aa757506001816006811115613aa557613aa5614aaf565b145b15613b625760008d815260086020526040812055613ac58285614db3565b336000908152600c6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100890151600d805469ffffffffffffffffffff90921693909291613b3391859116614db3565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b9c9b505050505050505050505050565b508054613b7e906145fa565b6000825580601f10613b8e575050565b601f0160209004906000526020600020908101906106899190613bcb565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613be05760008155600101613bcc565b5090565b60008083601f840112613bf657600080fd5b50813567ffffffffffffffff811115613c0e57600080fd5b602083019150836020828501011115613c2657600080fd5b9250929050565b60008060208385031215613c4057600080fd5b823567ffffffffffffffff811115613c5757600080fd5b613c6385828601613be4565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613cc157613cc1613c6f565b60405290565b6040516080810167ffffffffffffffff81118282101715613cc157613cc1613c6f565b604051610160810167ffffffffffffffff81118282101715613cc157613cc1613c6f565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d5557613d55613c6f565b604052919050565b600082601f830112613d6e57600080fd5b813567ffffffffffffffff811115613d8857613d88613c6f565b613db960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613d0e565b818152846020838601011115613dce57600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461068957600080fd5b8035610fac81613deb565b73ffffffffffffffffffffffffffffffffffffffff8116811461068957600080fd5b63ffffffff8116811461068957600080fd5b6bffffffffffffffffffffffff8116811461068957600080fd5b60008082840360c0811215613e6e57600080fd5b833567ffffffffffffffff811115613e8557600080fd5b613e9186828701613d5d565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613ec457600080fd5b50613ecd613c9e565b6020840135613edb81613deb565b81526040840135613eeb81613e0c565b60208201526060840135613efe81613e2e565b60408201526080840135606082015260a0840135613f1b81613e40565b6080820152919491935090915050565b6000815180845260005b81811015613f5157602081850181015186830182015201613f35565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613fa26020830184613f2b565b9392505050565b600060208284031215613fbb57600080fd5b8135613fa281613e0c565b600081518084526020808501945080840160005b8381101561400c57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613fda565b509495945050505050565b60408152600061402a6040830185613fc6565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614098577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614086838351613f2b565b9486019492509085019060010161404c565b50909998505050505050505050565b600080604083850312156140ba57600080fd5b82356140c581613e0c565b915060208301356140d581613e40565b809150509250929050565b6000806000604084860312156140f557600080fd5b833561410081613e0c565b9250602084013567ffffffffffffffff81111561411c57600080fd5b61412886828701613be4565b9497909650939450505050565b602081526000613fa26020830184613fc6565b60006020828403121561415a57600080fd5b5035919050565b60006020828403121561417357600080fd5b813567ffffffffffffffff81111561418a57600080fd5b61419684828501613d5d565b949350505050565b60008083601f8401126141b057600080fd5b50813567ffffffffffffffff8111156141c857600080fd5b6020830191508360208260051b8501011115613c2657600080fd5b60008060008060008060008060e0898b0312156141ff57600080fd5b606089018a81111561421057600080fd5b8998503567ffffffffffffffff8082111561422a57600080fd5b6142368c838d01613be4565b909950975060808b013591508082111561424f57600080fd5b61425b8c838d0161419e565b909750955060a08b013591508082111561427457600080fd5b506142818b828c0161419e565b999c989b50969995989497949560c00135949350505050565b6000602082840312156142ac57600080fd5b813567ffffffffffffffff8111156142c357600080fd5b82016101008185031215613fa257600080fd5b80516bffffffffffffffffffffffff168252602081015161430f602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614337604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614353606084018267ffffffffffffffff169052565b50608081015161436b608084018263ffffffff169052565b5060a081015161438b60a08401826bffffffffffffffffffffffff169052565b5060c08101516143a460c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143cd8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d8b565b61016081016105e482846142d6565b60008060008060006080868803121561442357600080fd5b853561442e81613deb565b9450602086013567ffffffffffffffff81111561444a57600080fd5b61445688828901613be4565b909550935050604086013561446a81613e2e565b949793965091946060013592915050565b600067ffffffffffffffff82111561449557614495613c6f565b5060051b60200190565b600082601f8301126144b057600080fd5b813560206144c56144c08361447b565b613d0e565b82815260059290921b840181019181810190868411156144e457600080fd5b8286015b848110156145085780356144fb81613e0c565b83529183019183016144e8565b509695505050505050565b60ff8116811461068957600080fd5b8035610fac81614513565b60008060008060008060c0878903121561454657600080fd5b863567ffffffffffffffff8082111561455e57600080fd5b61456a8a838b0161449f565b9750602089013591508082111561458057600080fd5b61458c8a838b0161449f565b965061459a60408a01614522565b955060608901359150808211156145b057600080fd5b6145bc8a838b01613d5d565b94506145ca60808a01613e01565b935060a08901359150808211156145e057600080fd5b506145ed89828a01613d5d565b9150509295509295509295565b600181811c9082168061460e57607f821691505b602082108103614647577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105b757600081815260208120601f850160051c810160208610156146745750805b601f850160051c820191505b8181101561469357828155600101614680565b505050505050565b67ffffffffffffffff8311156146b3576146b3613c6f565b6146c7836146c183546145fa565b8361464d565b6000601f84116001811461471957600085156146e35750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556147af565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147685786850135825560209485019460019092019101614748565b50868210156147a3577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461068957600080fd5b8051610fac81613e40565b8051610fac81613e2e565b600060208083850312156147ef57600080fd5b825167ffffffffffffffff8082111561480757600080fd5b908401906080828703121561481b57600080fd5b614823613cc7565b825161482e816147b6565b81528284015161483d81613e40565b8185015260408301517fffffffff000000000000000000000000000000000000000000000000000000008116811461487457600080fd5b604082015260608301518281111561488b57600080fd5b80840193505086601f8401126148a057600080fd5b825191506148b06144c08361447b565b82815260059290921b830184019184810190888411156148cf57600080fd5b938501935b838510156148f65784516148e781613e2e565b825293850193908501906148d4565b6060830152509695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361499557614995614935565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156149c1576149c1614935565b5092915050565b805169ffffffffffffffffffff81168114610fac57600080fd5b600080600080600060a086880312156149fa57600080fd5b614a03866149c8565b9450602086015193506040860151925060608601519150614a26608087016149c8565b90509295509295909350565b818103818111156105e4576105e4614935565b60ff81811683821601908111156105e4576105e4614935565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614aa057614aa0614a5e565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614b3757600080fd5b83018035915067ffffffffffffffff821115614b5257600080fd5b602001915036819003821315613c2657600080fd5b600060208284031215614b7957600080fd5b8135613fa281613deb565b600060208284031215614b9657600080fd5b8135613fa281613e2e565b600060208284031215614bb357600080fd5b8135613fa281613e40565b600060208284031215614bd057600080fd5b8135613fa2816147b6565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c7860c085018763ffffffff169052565b818482030160e0850152614c8e82820186613f2b565b9d9c50505050505050505050505050565b80820281158282048414176105e4576105e4614935565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156149c1576149c1614935565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614d328184018a613fc6565b90508281036080840152614d468189613fc6565b905060ff871660a084015282810360c0840152614d638187613f2b565b905067ffffffffffffffff851660e0840152828103610100840152613b628185613f2b565b60006bffffffffffffffffffffffff80841680614da757614da7614a5e565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156149c1576149c1614935565b6bffffffffffffffffffffffff818116838216028082169190828114614e0057614e00614935565b505092915050565b60008060008060008060008060006101208a8c031215614e2757600080fd5b8951614e3281613e2e565b60208b0151909950614e4381613e2e565b60408b0151909850614e5481613e2e565b60608b0151909750614e6581613e2e565b60808b0151909650614e7681613e2e565b9450614e8460a08b016149c8565b935060c08a0151614e94816147b6565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105e4576105e4614935565b600082601f830112614ed857600080fd5b81356020614ee86144c08361447b565b82815260059290921b84018101918181019086841115614f0757600080fd5b8286015b848110156145085780358352918301918301614f0b565b600082601f830112614f3357600080fd5b81356020614f436144c08361447b565b82815260059290921b84018101918181019086841115614f6257600080fd5b8286015b8481101561450857803567ffffffffffffffff811115614f865760008081fd5b614f948986838b0101613d5d565b845250918301918301614f66565b600080600080600060a08688031215614fba57600080fd5b853567ffffffffffffffff80821115614fd257600080fd5b614fde89838a01614ec7565b96506020880135915080821115614ff457600080fd5b61500089838a01614f22565b9550604088013591508082111561501657600080fd5b61502289838a01614f22565b9450606088013591508082111561503857600080fd5b61504489838a01614f22565b9350608088013591508082111561505a57600080fd5b5061506788828901614f22565b9150509295509295909350565b8051610fac81613e0c565b600080600080600060a0868803121561509757600080fd5b85516150a281613e40565b809550506020808701516150b581613e40565b60408801519095506150c681613e0c565b60608801519094506150d781613e0c565b608088015190935067ffffffffffffffff8111156150f457600080fd5b8701601f8101891361510557600080fd5b80516151136144c08261447b565b81815260059190911b8201830190838101908b83111561513257600080fd5b928401925b8284101561515957835161514a81613e0c565b82529284019290840190615137565b80955050505050509295509295909350565b8051610fac81613deb565b60008060006060848603121561518b57600080fd5b8351801515811461519b57600080fd5b60208501519093506151ac81613deb565b60408501519092506151bd81613deb565b809150509250925092565b67ffffffffffffffff8181168382160190808211156149c1576149c1614935565b6000826151f8576151f8614a5e565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526152448285018b613fc6565b91508382036080850152615258828a613fc6565b915060ff881660a085015283820360c08501526152758288613f2b565b90861660e08501528381036101008501529050613b628185613f2b565b805164ffffffffff81168114610fac57600080fd5b600061016082840312156152ba57600080fd5b6152c2613cea565b6152cb836147c6565b81526152d960208401615074565b60208201526152ea60408401615074565b60408201526152fb6060840161516b565b606082015261530c608084016147d1565b608082015261531d60a084016147c6565b60a082015261532e60c08401615292565b60c082015260e083015160e082015261010061534b8185016149c8565b9082015261012061535d848201615292565b9082015261014061536f848201615292565b908201529392505050565b64ffffffffff8181168382160190808211156149c1576149c1614935565b60006102008083526153ac8184018a613f2b565b905082810360208401526153c08189613f2b565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150615409905060a08301846142d6565b979650505050505050565b6000806040838503121561542757600080fd5b825161543281614513565b60208401519092506140d581613e4056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005ab338038062005ab3833981016040819052620000349162000458565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b03909216919091179055506200062a9350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000219919062000568565b9850985098509850985098509850985098506000811362000251576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260088054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f9062000411908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043d57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046e57600080fd5b620004798462000425565b602085810151919450906001600160401b03808211156200049957600080fd5b818701915087601f830112620004ae57600080fd5b815181811115620004c357620004c362000442565b604051601f8201601f19908116603f01168101908382118183101715620004ee57620004ee62000442565b816040528281528a868487010111156200050757600080fd5b600093505b828410156200052b57848401860151818501870152928501926200050c565b60008684830101528097505050505050506200054a6040850162000425565b90509250925092565b805163ffffffff811681146200043d57600080fd5b60008060008060008060008060006101208a8c0312156200058857600080fd5b620005938a62000553565b9850620005a360208b0162000553565b9750620005b360408b0162000553565b9650620005c360608b0162000553565b9550620005d360808b0162000553565b60a08b01519095506001600160501b0381168114620005f157600080fd5b60c08b015190945061ffff811681146200060a57600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a051615432620006816000396000818161068201528181610ab901528181610edc01528181610fba015281816118af01528181611b4901528181613121015261397d0152600061128001526154326000f3fe608060405234801561001057600080fd5b50600436106101a35760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610517578063d328a91e1461052a578063e3d0e71214610532578063f2fde38b1461054557600080fd5b8063b1dc65a4146103e6578063bdd7e880146103f9578063c3f909d41461041957600080fd5b80638da5cb5b116100c85780638da5cb5b14610388578063af1296d3146103b0578063afcb95d7146103c657600080fd5b806381ff7048146102e557806385b214cf146103525780638cc6acce1461037557600080fd5b806366316d8d11610150578063807560311161012a57806380756031146102b557806381411834146102c857806381f1b938146102dd57600080fd5b806366316d8d1461028757806379ba50971461029a5780637f15e166146102a257600080fd5b806326ceabac1161018157806326ceabac146102395780632a905ccc1461024c578063533989871461027157600080fd5b8063083a5466146101a85780630e7ada39146101bd578063181f5a77146101f0575b600080fd5b6101bb6101b6366004613bf7565b610558565b005b6101d06101cb366004613e24565b6105ad565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b61022c6040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101e79190613f59565b6101bb610247366004613f73565b6105db565b61025461067d565b6040516bffffffffffffffffffffffff90911681526020016101e7565b61027961073b565b6040516101e7929190613fe1565b6101bb610295366004614071565b6109bf565b6101bb610b79565b6101bb6102b0366004613bf7565b610c7b565b6101bb6102c33660046140aa565b610ccb565b6102d0610d82565b6040516101e791906140ff565b61022c610df1565b61032f60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101e7565b610365610360366004614112565b610ec2565b60405190151581526020016101e7565b6101bb61038336600461412b565b610fa2565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101e7565b6103b861101a565b6040519081526020016101e7565b6040805160018152600060208201819052918101919091526060016101e7565b6101bb6103f43660046141ad565b61110d565b61040c610407366004614264565b61183e565b6040516101e791906143c6565b600854600954600a54600c546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101e7565b6102546105253660046143d5565b611b45565b61022c611d11565b6101bb6105403660046144ee565b611d68565b6101bb610553366004613f73565b61278c565b61056061279d565b600081900361059b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105a882848361465c565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061657503373ffffffffffffffffffffffffffffffffffffffff8216145b61064c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e6020526040812061067a91613b3c565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106eb573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052610731919081019061479d565b5090949350505050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107a357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610778575b505050505090506000815167ffffffffffffffff8111156107c6576107c6613c39565b6040519080825280602002602001820160405280156107f957816020015b60608152602001906001900390816107e45790505b50905060005b82518110156109b557600e600084838151811061081e5761081e614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086b906145bb565b90506000036108a6576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e60008483815181106108bc576108bc614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610909906145bb565b80601f0160208091040260200160405190810160405280929190818152602001828054610935906145bb565b80156109825780601f1061095757610100808354040283529160200191610982565b820191906000526020600020905b81548152906001019060200180831161096557829003601f168201915b505050505082828151811061099957610999614898565b6020026020010181905250806109ae906148f6565b90506107ff565b5090939092509050565b6109c7612820565b806bffffffffffffffffffffffff166000036109fd5750336000908152600b60205260409020546bffffffffffffffffffffffff165b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a57576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a849084906bffffffffffffffffffffffff1661492e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610adb7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b5c57600080fd5b505af1158015610b70573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610bff576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c8361279d565b6000819003610cbe576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105a882848361465c565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d165750610cf5336129b1565b8015610d1657503373ffffffffffffffffffffffffffffffffffffffff8416145b610d4c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610d7c82848361465c565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610de757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dbc575b5050505050905090565b6060600f8054610e00906145bb565b9050600003610e3b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610e48906145bb565b80601f0160208091040260200160405190810160405280929190818152602001828054610e74906145bb565b8015610de75780601f10610e9657610100808354040283529160200191610de7565b820191906000526020600020905b815481529060010190602001808311610ea457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f33576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260076020526040902054610f4e57506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610f919084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611011576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61067a81612a9a565b600854600c54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d89190614974565b509350509250508280156110fa57506110f181426149c4565b8463ffffffff16105b1561110557600a5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161116391849163ffffffff851691908e908e9081908401838280828437600092019190915250612da392505050565b611199576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461126e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610bf6565b61127c8b8b8b8b8b8b612dac565b60007f0000000000000000000000000000000000000000000000000000000000000000156112d9576002826020015183604001516112ba91906149d7565b6112c49190614a1f565b6112cf9060016149d7565b60ff1690506112ef565b60208201516112e99060016149d7565b60ff1690505b888114611358576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610bf6565b8887146113c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610bf6565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561140457611404614a41565b600281111561141557611415614a41565b905250905060028160200151600281111561143257611432614a41565b14801561147957506006816000015160ff168154811061145457611454614898565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610bf6565b50505050506114ec613b76565b6000808a8a6040516114ff929190614a70565b604051908190038120611516918e90602001614a80565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561182057600060018489846020811061157f5761157f614898565b61158c91901a601b6149d7565b8e8e8681811061159e5761159e614898565b905060200201358d8d878181106115b7576115b7614898565b90506020020135604051600081526020016040526040516115f4949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611616573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561169657611696614a41565b60028111156116a7576116a7614a41565b90525092506001836020015160028111156116c4576116c4614a41565b1461172b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610bf6565b8251600090879060ff16601f811061174557611745614898565b602002015173ffffffffffffffffffffffffffffffffffffffff16146117c7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610bf6565b8086846000015160ff16601f81106117e1576117e1614898565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261180c6001866149d7565b94505080611819906148f6565b9050611560565b505050611831833383858e8e612e5a565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611906576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119136040830183614a94565b905060000361194d576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a0016040528084606001602081019061196d9190614af9565b67ffffffffffffffff16815260209081019061198b90860186613f73565b73ffffffffffffffffffffffffffffffffffffffff1681526020016119b660e0860160c08701614b16565b63ffffffff1681523a60208201526040016119d8610100860160e08701614b33565b6bffffffffffffffffffffffff1690529050611a456119fa6040850185614a94565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a3f9250505060a0860160808701614b50565b83613028565b9150611a546020840184613f73565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611aa49190614af9565b611ab46040890160208a01613f73565b611ac160408a018a614a94565b611ad160a08c0160808d01614b50565b60a08c0135611ae660e08e0160c08f01614b16565b8c604051602001611af791906143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b37999897969594939291614b6d565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611be557600080fd5b505afa158015611bf9573d6000803e3d6000fd5b50505050620f4240821115611c3a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c4461067d565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611ce888888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105ad915050565b69ffffffffffffffffffff169050611d028686838661351c565b93505050505b95945050505050565b6060600d8054611d20906145bb565b9050600003611d5b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610e48906145bb565b855185518560ff16601f831115611ddb576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610bf6565b80600003611e45576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610bf6565b818314611ed3576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610bf6565b611ede816003614c31565b8311611f46576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610bf6565b611f4e61279d565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f95908861368c565b6005541561214a57600554600090611faf906001906149c4565b9050600060058281548110611fc657611fc6614898565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200057612000614898565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208057612080614c48565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120e9576120e9614c48565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f95915050565b60005b8151518110156125b1576000600460008460000151848151811061217357612173614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121bd576121bd614a41565b14612224576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610bf6565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225557612255614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122f6576122f6614a41565b0217905550600091506123069050565b600460008460200151848151811061232057612320614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561236a5761236a614a41565b146123d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610bf6565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240457612404614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124a5576124a5614a41565b0217905550508251805160059250839081106124c3576124c3614898565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061253f5761253f614898565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125a9816148f6565b91505061214d565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161266991849174010000000000000000000000000000000000000000900416614c77565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126c84630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516136a9565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861277f988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614c94565b60405180910390a1611831565b61279461279d565b61067a81613754565b60005473ffffffffffffffffffffffffffffffffffffffff16331461281e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bf6565b565b600061282a610d82565b90508051600003612867576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612886916bffffffffffffffffffffffff16614d2a565b905060005b82518110156129525781600b60008584815181106128ab576128ab614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129139190614d55565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061294b906148f6565b905061288b565b50815161295f9082614d7a565b600c805460009061297f9084906bffffffffffffffffffffffff1661492e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a1757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129ec575b5050505050905060005b8151811015612a90578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5357612a53614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a80575060019392505050565b612a89816148f6565b9050612a21565b5060009392505050565b600080600080600080600080600089806020019051810190612abc9190614daa565b98509850985098509850985098509850985060008113612b0b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600880547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d8f908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60019392505050565b6000612db9826020614c31565b612dc4856020614c31565b612dd088610144614e56565b612dda9190614e56565b612de49190614e56565b612def906000614e56565b9050368114610b70576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610bf6565b606080808080612e6c86880188614f44565b8451949950929750909550935091501580612e8957508351855114155b80612e9657508251855114155b80612ea357508151855114155b80612eb057508051855114155b15612ee7576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561301a576000612f7f878381518110612f0a57612f0a614898565b6020026020010151878481518110612f2457612f24614898565b6020026020010151878581518110612f3e57612f3e614898565b6020026020010151878681518110612f5857612f58614898565b6020026020010151878781518110612f7257612f72614898565b6020026020010151613849565b90506000816006811115612f9557612f95614a41565b1480612fb257506001816006811115612fb057612fb0614a41565b145b1561300957868281518110612fc957612fc9614898565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b50613013816148f6565b9050612eea565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260085461ffff7e01000000000000000000000000000000000000000000000000000000000000909104811690841611156130e7576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006130f385846105ad565b9050600061311b846040015185606001518469ffffffffffffffffffff16876080015161351c565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa1580156131bd573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526132039190810190615085565b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529192506000919084169063674603d090604401606060405180830381865afa15801561328e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132b29190615154565b50604084015184519193506bffffffffffffffffffffffff871692506132d79161492e565b6bffffffffffffffffffffffff16101561331d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061339c3089602001518a6000015185600161333a91906151a6565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060405180610160016040528089608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896020015173ffffffffffffffffffffffffffffffffffffffff168152602001896000015167ffffffffffffffff168152602001896040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001600860000160109054906101000a900463ffffffff1663ffffffff164261345d9190614e56565b64ffffffffff168152602080820184905269ffffffffffffffffffff891660408084019190915260085463ffffffff680100000000000000008204811660608601526c010000000000000000000000009091041660809093019290925290519198506134cb918991016143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555093979650505050505050565b60008061352761101a565b905060008113613566576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b600854600090879061359c9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c77565b6135a69190614c77565b63ffffffff1690506000612710600860010154886135c49190614c31565b6135ce91906151c7565b6135d89088614e56565b9050600083836135f084670de0b6b3a7640000614c31565b6135fa9190614c31565b61360491906151c7565b905060006136236bffffffffffffffffffffffff808916908a16614e56565b905061363b816b033b2e3c9fd0803ce80000006149c4565b821115613674576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61367e8183614e56565b9a9950505050505050505050565b6000613696610d82565b5111156136a5576136a5612820565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136cd999897969594939291906151db565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137d3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bf6565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906138609190615285565b600088815260076020526040902054909150613880576002915050611d08565b8060405160200161389191906143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526007909352912054146138e3576006915050611d08565b60006138ed61101a565b90506000811361392c576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b6000816139413a670de0b6b3a7640000614c31565b61394b91906151c7565b905060008361014001518461012001516139659190615358565b6139769064ffffffffff1683614c31565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139d79190614d55565b338c6040518763ffffffff1660e01b81526004016139fa96959493929190615376565b60408051808303816000875af1158015613a18573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3c91906153f2565b90925090506000826006811115613a5557613a55614a41565b1480613a7257506001826006811115613a7057613a70614a41565b145b15613b2d5760008c815260076020526040812055613a908184614d55565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100880151600c805469ffffffffffffffffffff90921693909291613afe91859116614d55565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509a9950505050505050505050565b508054613b48906145bb565b6000825580601f10613b58575050565b601f01602090049060005260206000209081019061067a9190613b95565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613baa5760008155600101613b96565b5090565b60008083601f840112613bc057600080fd5b50813567ffffffffffffffff811115613bd857600080fd5b602083019150836020828501011115613bf057600080fd5b9250929050565b60008060208385031215613c0a57600080fd5b823567ffffffffffffffff811115613c2157600080fd5b613c2d85828601613bae565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b60405290565b60405160c0810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b604051610160810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d1f57613d1f613c39565b604052919050565b600082601f830112613d3857600080fd5b813567ffffffffffffffff811115613d5257613d52613c39565b613d8360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613cd8565b818152846020838601011115613d9857600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067a57600080fd5b8035610f9d81613db5565b73ffffffffffffffffffffffffffffffffffffffff8116811461067a57600080fd5b63ffffffff8116811461067a57600080fd5b6bffffffffffffffffffffffff8116811461067a57600080fd5b60008082840360c0811215613e3857600080fd5b833567ffffffffffffffff811115613e4f57600080fd5b613e5b86828701613d27565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613e8e57600080fd5b50613e97613c68565b6020840135613ea581613db5565b81526040840135613eb581613dd6565b60208201526060840135613ec881613df8565b60408201526080840135606082015260a0840135613ee581613e0a565b6080820152919491935090915050565b6000815180845260005b81811015613f1b57602081850181015186830182015201613eff565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613f6c6020830184613ef5565b9392505050565b600060208284031215613f8557600080fd5b8135613f6c81613dd6565b600081518084526020808501945080840160005b83811015613fd657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613fa4565b509495945050505050565b604081526000613ff46040830185613f90565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614062577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614050838351613ef5565b94860194925090850190600101614016565b50909998505050505050505050565b6000806040838503121561408457600080fd5b823561408f81613dd6565b9150602083013561409f81613e0a565b809150509250929050565b6000806000604084860312156140bf57600080fd5b83356140ca81613dd6565b9250602084013567ffffffffffffffff8111156140e657600080fd5b6140f286828701613bae565b9497909650939450505050565b602081526000613f6c6020830184613f90565b60006020828403121561412457600080fd5b5035919050565b60006020828403121561413d57600080fd5b813567ffffffffffffffff81111561415457600080fd5b61416084828501613d27565b949350505050565b60008083601f84011261417a57600080fd5b50813567ffffffffffffffff81111561419257600080fd5b6020830191508360208260051b8501011115613bf057600080fd5b60008060008060008060008060e0898b0312156141c957600080fd5b606089018a8111156141da57600080fd5b8998503567ffffffffffffffff808211156141f457600080fd5b6142008c838d01613bae565b909950975060808b013591508082111561421957600080fd5b6142258c838d01614168565b909750955060a08b013591508082111561423e57600080fd5b5061424b8b828c01614168565b999c989b50969995989497949560c00135949350505050565b60006020828403121561427657600080fd5b813567ffffffffffffffff81111561428d57600080fd5b82016101008185031215613f6c57600080fd5b80516bffffffffffffffffffffffff16825260208101516142d9602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614301604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606081015161431d606084018267ffffffffffffffff169052565b506080810151614335608084018263ffffffff169052565b5060a081015161435560a08401826bffffffffffffffffffffffff169052565b5060c081015161436e60c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143978285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d7c565b61016081016105d582846142a0565b6000806000806000608086880312156143ed57600080fd5b85356143f881613db5565b9450602086013567ffffffffffffffff81111561441457600080fd5b61442088828901613bae565b909550935050604086013561443481613df8565b949793965091946060013592915050565b600067ffffffffffffffff82111561445f5761445f613c39565b5060051b60200190565b600082601f83011261447a57600080fd5b8135602061448f61448a83614445565b613cd8565b82815260059290921b840181019181810190868411156144ae57600080fd5b8286015b848110156144d25780356144c581613dd6565b83529183019183016144b2565b509695505050505050565b803560ff81168114610f9d57600080fd5b60008060008060008060c0878903121561450757600080fd5b863567ffffffffffffffff8082111561451f57600080fd5b61452b8a838b01614469565b9750602089013591508082111561454157600080fd5b61454d8a838b01614469565b965061455b60408a016144dd565b9550606089013591508082111561457157600080fd5b61457d8a838b01613d27565b945061458b60808a01613dcb565b935060a08901359150808211156145a157600080fd5b506145ae89828a01613d27565b9150509295509295509295565b600181811c908216806145cf57607f821691505b602082108103614608577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105a857600081815260208120601f850160051c810160208610156146355750805b601f850160051c820191505b8181101561465457828155600101614641565b505050505050565b67ffffffffffffffff83111561467457614674613c39565b6146888361468283546145bb565b8361460e565b6000601f8411600181146146da57600085156146a45750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614770565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147295786850135825560209485019460019092019101614709565b5086821015614764577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461067a57600080fd5b8051610f9d81613e0a565b8051610f9d81613df8565b600080600080608085870312156147b357600080fd5b84516147be81614777565b809450506020808601516147d181613e0a565b60408701519094507fffffffff000000000000000000000000000000000000000000000000000000008116811461480757600080fd5b606087015190935067ffffffffffffffff81111561482457600080fd5b8601601f8101881361483557600080fd5b805161484361448a82614445565b81815260059190911b8201830190838101908a83111561486257600080fd5b928401925b8284101561488957835161487a81613df8565b82529284019290840190614867565b979a9699509497505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614927576149276148c7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614953576149536148c7565b5092915050565b805169ffffffffffffffffffff81168114610f9d57600080fd5b600080600080600060a0868803121561498c57600080fd5b6149958661495a565b94506020860151935060408601519250606086015191506149b86080870161495a565b90509295509295909350565b818103818111156105d5576105d56148c7565b60ff81811683821601908111156105d5576105d56148c7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a3257614a326149f0565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614ac957600080fd5b83018035915067ffffffffffffffff821115614ae457600080fd5b602001915036819003821315613bf057600080fd5b600060208284031215614b0b57600080fd5b8135613f6c81613db5565b600060208284031215614b2857600080fd5b8135613f6c81613df8565b600060208284031215614b4557600080fd5b8135613f6c81613e0a565b600060208284031215614b6257600080fd5b8135613f6c81614777565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c0a60c085018763ffffffff169052565b818482030160e0850152614c2082820186613ef5565b9d9c50505050505050505050505050565b80820281158282048414176105d5576105d56148c7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614953576149536148c7565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cc48184018a613f90565b90508281036080840152614cd88189613f90565b905060ff871660a084015282810360c0840152614cf58187613ef5565b905067ffffffffffffffff851660e0840152828103610100840152614d1a8185613ef5565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614d4957614d496149f0565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614953576149536148c7565b6bffffffffffffffffffffffff818116838216028082169190828114614da257614da26148c7565b505092915050565b60008060008060008060008060006101208a8c031215614dc957600080fd5b8951614dd481613df8565b60208b0151909950614de581613df8565b60408b0151909850614df681613df8565b60608b0151909750614e0781613df8565b60808b0151909650614e1881613df8565b9450614e2660a08b0161495a565b935060c08a0151614e3681614777565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105d5576105d56148c7565b600082601f830112614e7a57600080fd5b81356020614e8a61448a83614445565b82815260059290921b84018101918181019086841115614ea957600080fd5b8286015b848110156144d25780358352918301918301614ead565b600082601f830112614ed557600080fd5b81356020614ee561448a83614445565b82815260059290921b84018101918181019086841115614f0457600080fd5b8286015b848110156144d257803567ffffffffffffffff811115614f285760008081fd5b614f368986838b0101613d27565b845250918301918301614f08565b600080600080600060a08688031215614f5c57600080fd5b853567ffffffffffffffff80821115614f7457600080fd5b614f8089838a01614e69565b96506020880135915080821115614f9657600080fd5b614fa289838a01614ec4565b95506040880135915080821115614fb857600080fd5b614fc489838a01614ec4565b94506060880135915080821115614fda57600080fd5b614fe689838a01614ec4565b93506080880135915080821115614ffc57600080fd5b5061500988828901614ec4565b9150509295509295909350565b8051610f9d81613dd6565b600082601f83011261503257600080fd5b8151602061504261448a83614445565b82815260059290921b8401810191818101908684111561506157600080fd5b8286015b848110156144d257805161507881613dd6565b8352918301918301615065565b60006020828403121561509757600080fd5b815167ffffffffffffffff808211156150af57600080fd5b9083019060c082860312156150c357600080fd5b6150cb613c91565b82516150d681613e0a565b815260208301516150e681613dd6565b602082015260408301516150f981613e0a565b604082015261510a60608401615016565b606082015260808301518281111561512157600080fd5b61512d87828601615021565b60808301525060a083015160a082015280935050505092915050565b8051610f9d81613db5565b60008060006060848603121561516957600080fd5b8351801515811461517957600080fd5b602085015190935061518a81613db5565b604085015190925061519b81613db5565b809150509250925092565b67ffffffffffffffff818116838216019080821115614953576149536148c7565b6000826151d6576151d66149f0565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526152228285018b613f90565b91508382036080850152615236828a613f90565b915060ff881660a085015283820360c08501526152538288613ef5565b90861660e08501528381036101008501529050614d1a8185613ef5565b805164ffffffffff81168114610f9d57600080fd5b6000610160828403121561529857600080fd5b6152a0613cb4565b6152a983614787565b81526152b760208401615016565b60208201526152c860408401615016565b60408201526152d960608401615149565b60608201526152ea60808401614792565b60808201526152fb60a08401614787565b60a082015261530c60c08401615270565b60c082015260e083015160e082015261010061532981850161495a565b9082015261012061533b848201615270565b9082015261014061534d848201615270565b908201529392505050565b64ffffffffff818116838216019080821115614953576149536148c7565b600061020080835261538a8184018a613ef5565b9050828103602084015261539e8189613ef5565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153e7905060a08301846142a0565b979650505050505050565b6000806040838503121561540557600080fd5b82516007811061541457600080fd5b602084015190925061409f81613e0a56fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -309,28 +309,6 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (Get return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getConfigHash") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfigHash() ([32]byte, error) { - return _FunctionsCoordinator.Contract.GetConfigHash(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfigHash() ([32]byte, error) { - return _FunctionsCoordinator.Contract.GetConfigHash(&_FunctionsCoordinator.CallOpts) -} - func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { var out []interface{} err := _FunctionsCoordinator.contract.Call(opts, &out, "getDONFee", arg0, arg1) @@ -1814,8 +1792,6 @@ type FunctionsCoordinatorInterface interface { error) - GetConfigHash(opts *bind.CallOpts) ([32]byte, error) - GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) GetDONPublicKey(opts *bind.CallOpts) ([]byte, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 44c59d6afad..1a4079979f0 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -44,16 +44,18 @@ type IFunctionsRequestCommitment struct { GasOverheadAfterCallback *big.Int } -type IFunctionsRouterConfig struct { - MaxConsumers uint16 - AdminFee *big.Int - HandleOracleFulfillmentSelector [4]byte - MaxCallbackGasLimits []uint32 +type IFunctionsSubscriptionsSubscription struct { + Balance *big.Int + Owner common.Address + BlockedBalance *big.Int + RequestedOwner common.Address + Consumers []common.Address + Flags [32]byte } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumers\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200666b3803806200666b83398101604081905262000034916200044b565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d98162000178565b50506009805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e8162000229565b80516020909101206007555050600a80546001600160a01b0319166001600160a01b03939093169290921790915550620006d79350505050565b336001600160a01b03821603620001d25760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000808480602001905181019062000245919062000548565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600f80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002d591601091908601906200031d565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca8383836040516200030e9392919062000666565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003c15791602002820160005b838211156200038d57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000347565b8015620003bf5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200038d565b505b50620003cf929150620003d3565b5090565b5b80821115620003cf5760008155600101620003d4565b805161ffff81168114620003fd57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b038111828210171562000443576200044362000402565b604052919050565b600080600080608085870312156200046257600080fd5b6200046d85620003ea565b935060206200047e818701620003ea565b60408701519094506001600160a01b03811681146200049c57600080fd5b60608701519093506001600160401b0380821115620004ba57600080fd5b818801915088601f830112620004cf57600080fd5b815181811115620004e457620004e462000402565b620004f8601f8201601f1916850162000418565b915080825289848285010111156200050f57600080fd5b60005b818110156200052f57838101850151838201860152840162000512565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055f57600080fd5b6200056a85620003ea565b602086810151919550906001600160601b03811681146200058a57600080fd5b60408701519094506001600160e01b031981168114620005a957600080fd5b60608701519093506001600160401b0380821115620005c757600080fd5b818801915088601f830112620005dc57600080fd5b815181811115620005f157620005f162000402565b8060051b91506200060484830162000418565b818152918301840191848101908b8411156200061f57600080fd5b938501935b8385101562000656578451925063ffffffff83168314620006455760008081fd5b828252938501939085019062000624565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006c957845163ffffffff1683529383019391830191600101620006a5565b509098975050505050505050565b608051615f78620006f3600039600061294f0152615f786000f3fe608060405234801561001057600080fd5b50600436106102f45760003560e01c80638456cb5911610191578063b187bd26116100e3578063c4614d6111610097578063e82ad7d411610071578063e82ad7d414610752578063eb523d6c14610765578063f2fde38b1461077857600080fd5b8063c4614d6114610719578063d7ae1d301461072c578063e72f6e301461073f57600080fd5b8063b734c0f4116100c8578063b734c0f4146106e5578063badc3eb6146106ed578063c3f909d41461070457600080fd5b8063b187bd26146106c7578063b5643858146106d257600080fd5b8063a1d4c82811610145578063a4c0ed361161011f578063a4c0ed361461067b578063a9c9a9181461068e578063aab396bd146106a157600080fd5b8063a1d4c82814610616578063a21a23e41461064f578063a47c76961461065757600080fd5b80638fde5317116101765780638fde5317146105f35780639883c10d146105fb5780639f87fad71461060357600080fd5b80638456cb59146105c85780638da5cb5b146105d057600080fd5b806355fedefa1161024a578063674603d0116101fe5780637341c10c116101d85780637341c10c1461059a57806379ba5097146105ad57806382359740146105b557600080fd5b8063674603d0146104ba5780636a6df79b1461054f5780636e3b33231461058757600080fd5b80635ed6dfba1161022f5780635ed6dfba1461046657806366316d8d14610479578063664199701461048c57600080fd5b806355fedefa1461043c5780635c975abb1461044f57600080fd5b80631ded3b36116102ac5780633f4ba83a116102865780633f4ba83a14610400578063461d2762146104085780634b8832d31461042957600080fd5b80631ded3b36146103c7578063385de9ae146103da5780633e871e4d146103ed57600080fd5b806310fc49c1116102dd57806310fc49c11461032e57806312b5834914610341578063181f5a771461037e57600080fd5b806302bcc5b6146102f95780630c5d49cb1461030e575b600080fd5b61030c610307366004614ab1565b61078b565b005b610316608481565b60405161ffff90911681526020015b60405180910390f35b61030c61033c366004614aeb565b610818565b6009546b01000000000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610325565b6103ba6040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103259190614b88565b61030c6103d5366004614b9b565b610942565b61030c6103e8366004614c10565b610973565b61030c6103fb366004614dc9565b610b51565b61030c610e47565b61041b610416366004614e92565b610e59565b604051908152602001610325565b61030c610437366004614f17565b610ead565b61041b61044a366004614ab1565b610faa565b60005460ff165b6040519015158152602001610325565b61030c610474366004614f6a565b610fce565b61030c610487366004614f6a565b6112a4565b6009546301000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610325565b6105276104c8366004614f98565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610325565b61056261055d366004614fd4565b6114cb565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610325565b61030c610595366004614ff9565b6114de565b61030c6105a8366004614f17565b6117b4565b61030c61194a565b61030c6105c3366004614ab1565b611a6c565b61030c611bbb565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610562565b61030c611bcb565b60075461041b565b61030c610611366004614f17565b611c73565b610629610624366004615212565b61207b565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610325565b6104a1612447565b61066a610665366004614ab1565b6125db565b604051610325959493929190615310565b61030c610689366004615365565b6126c7565b61056261069c3660046153c1565b6128f6565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761041b565b60005460ff16610456565b61030c6106e03660046153da565b612903565b61030c612a64565b6106f5612bd2565b604051610325939291906153f7565b61070c612cad565b604051610325919061548e565b6103ba610727366004614c10565b612dc4565b61030c61073a366004614f17565b612dd9565b61030c61074d3660046154fb565b612e32565b610456610760366004614ab1565b61303d565b61030c6107733660046153c1565b613048565b61030c6107863660046154fb565b613266565b610793613277565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff168061080a576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610814828261327f565b5050565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a90811061087d576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6010805460ff831690811061089457610894615518565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561093d576010805460ff83169081106108e4576108e4615518565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610874565b505050565b61094a613277565b610953826135ed565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b61097b613663565b60006109888460006136e9565b905060003073ffffffffffffffffffffffffffffffffffffffff8316036109b25750600754610a26565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156109ff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a239190615547565b90505b8383604051610a36929190615560565b60405180910390208103610a76576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600954602090910190610ad79061ffff164361559f565b9052600086815260066020908152604090912082518155908201516001820190610b019082615653565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610b4290879084908890889061576d565b60405180910390a15050505050565b610b59613663565b8151815181141580610b6b5750600881115b15610ba2576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610cce576000848281518110610bc157610bc1615518565b602002602001015190506000848381518110610bdf57610bdf615518565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c4a575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c81576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cbb576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610874565b505080610cc7906157c8565b9050610ba5565b50600954600090610ce39061ffff164361559f565b604080516060810182528681526020808201879052918101839052865192935091600391610d159183918901906148f1565b506020828101518051610d2e9260018501920190614938565b506040820151816002015590505060005b8451811015610e40577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610d7b57610d7b615518565b602002602001015160026000888581518110610d9957610d99615518565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610de257610de2615518565b602002602001015185604051610e28949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e39816157c8565b9050610d3f565b5050505050565b610e4f613663565b610e576137e0565b565b6000610ea28260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915061385d9050565b979650505050505050565b610eb5613bb3565b610ebe82613bbb565b610ec6613c81565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146108145767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25050565b67ffffffffffffffff81166000908152600b60205260408120600301545b92915050565b610fd6613277565b806bffffffffffffffffffffffff1660000361100c5750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff80831691161015611066576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906110939084906bffffffffffffffffffffffff16615800565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166110ea9190615800565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611189573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111ad919061582c565b61081457600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611220573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112449190615547565b6009546040517fa99da3020000000000000000000000000000000000000000000000000000000081526b0100000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610874565b6112ac613bb3565b806bffffffffffffffffffffffff166000036112f4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff8083169116101561134e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260408120805483929061137b9084906bffffffffffffffffffffffff16615800565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806009600b8282829054906101000a90046bffffffffffffffffffffffff166113d29190615800565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015611471573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611495919061582c565b610814576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006114d783836136e9565b9392505050565b6114e6613bb3565b60005b8181101561093d57600083838381811061150557611505615518565b9050610160020180360381019061151c9190615849565b905060008160e001519050600e6000828152602001908152602001600020548260405160200161154c9190615866565b6040516020818303038152906040528051906020012014611599576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156115de576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af1158015611650573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611674919061582c565b5060a0830151606084015167ffffffffffffffff166000908152600b6020526040812060010180549091906116b89084906bffffffffffffffffffffffff16615800565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c6020908152828220606087015167ffffffffffffffff9081168452915291902080546001926009916117449185916901000000000000000000900416615995565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806117ad906157c8565b90506114e9565b6117bc613bb3565b6117c582613bbb565b6117cd613c81565b600f5467ffffffffffffffff83166000908152600b602052604090206002015461ffff909116900361182b576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff1615611872575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610f9e565b60015473ffffffffffffffffffffffffffffffffffffffff1633146119cb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610874565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611a74613bb3565b611a7c613c81565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611b1c576040517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610874565b67ffffffffffffffff83166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611bc3613663565b610e57613d88565b611bd3613663565b60085464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611c35576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600980546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611c7b613bb3565b611c8482613bbb565b611c8c613c81565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d5c576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8416600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610874565b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611db1576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611e2c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e01575b50505050509050600060018251611e4391906159b6565b905060005b8251811015611fdf578473ffffffffffffffffffffffffffffffffffffffff16838281518110611e7a57611e7a615518565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611fcf576000838381518110611eb157611eb1615518565b6020026020010151905080600b60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611ef757611ef7615518565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600b90915260409020600201805480611f7157611f716159c9565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611fdf565b611fd8816157c8565b9050611e48565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600c6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b600080612086613bb3565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146120ef576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e60205260409020546121845760025b91508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516121779392919073ffffffffffffffffffffffffffffffffffffffff938416815291909216602082015260ff91909116604082015260600190565b60405180910390a261243c565b600e60008460e00151815260200190815260200160002054836040516020016121ad9190615866565b60405160208183030381529060405280519060200120146121cf57600661210a565b826101400151836080015163ffffffff166121ea91906159f8565b64ffffffffff165a10156121ff57600461210a565b606083015167ffffffffffffffff166000908152600b602052604090205460808401516bffffffffffffffffffffffff909116906122429063ffffffff16613de3565b61224c9088615a16565b8451612259908890615a3e565b6122639190615a3e565b6bffffffffffffffffffffffff1611156122f45760e0830180516000908152600e6020908152604080832092909255915182860151825173ffffffffffffffffffffffffffffffffffffffff9182168152908816938101939093526005918301829052909350907f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee190606001612177565b8260a001516bffffffffffffffffffffffff1661231a846080015163ffffffff16613de3565b6123249088615a16565b8451612331908890615a3e565b61233b9190615a3e565b6bffffffffffffffffffffffff16111561235657600361210a565b60009150600e60008460e0015181526020019081526020016000206000905560006123908460e001518a8a87608001518860400151613e85565b80519091506123a05760016123a3565b60005b925060006123ca85606001518660a00151876040015188600001518c87602001518d614001565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151612417578e612419565b8f5b886040015160405161242f959493929190615a63565b60405180910390a3519150505b965096945050505050565b6000612451613bb3565b612459613c81565b6009805460039061247a906301000000900467ffffffffffffffff16615ac1565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156124f0578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261258b92600285019290910190614938565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b60008060008060606125ec866135ed565b67ffffffffffffffff86166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169b508416995073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009384900481169950929093049091169550918301828280156126b757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161268c575b5050505050905091939590929450565b6126cf613bb3565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612720576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461275a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061276882840184614ab1565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166127e1576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906128188385615a3e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846009600b8282829054906101000a90046bffffffffffffffffffffffff1661286f9190615a3e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128d6919061559f565b6040805192835260208301919091520160405180910390a2505050505050565b6000610fc88260006136e9565b61290b613663565b60095461ffff80831691160361294d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff1611156129af576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260095461ffff908116808352908416602083015290918201906129dc904361559f565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516008805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612a6c613663565b600554431015612aa8576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612bcf57600060036000018281548110612acd57612acd615518565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612b1957612b19615518565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612bc8906157c8565b9050612aab565b50565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612c3257602002820191906000526020600020905b815481526020019060010190808311612c1e575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612c9b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612c70575b50505050509050925092509250909192565b604080516080810182526000808252602082018190529181019190915260608082015260408051608081018252600f805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff0000000000000000000000000000000000000000000000000000000016838501526010805485518184028101840190965280865293949293606086019392830182828015612db657602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612d795790505b505050505081525050905090565b6060612dd1848484614253565b949350505050565b612de1613bb3565b612dea82613bbb565b612df2613c81565b612dfb82614320565b1561080a576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612e3a613277565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ea9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ecd9190615547565b6009549091506b01000000000000000000000090046bffffffffffffffffffffffff1681811115612f34576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610874565b8181101561093d576000612f4882846159b6565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015612fc3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612fe7919061582c565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6000610fc882614320565b613050613663565b6000600660008381526020019081526020016000206040518060600160405290816000820154815260200160018201805461308a906155b2565b80601f01602080910402602001604051908101604052809291908181526020018280546130b6906155b2565b80156131035780601f106130d857610100808354040283529160200191613103565b820191906000526020600020905b8154815290600101906020018083116130e657829003601f168201915b5050505050815260200160028201548152505090508060400151431015613156576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8161317b57613168816020015161446f565b6020808201518051910120600755613223565b6131868260006136e9565b73ffffffffffffffffffffffffffffffffffffffff16638cc6acce82602001516040518263ffffffff1660e01b81526004016131c29190614b88565b600060405180830381600087803b1580156131dc57600080fd5b505af19250505080156131ed575060015b613223576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f479261325a928692615ae8565b60405180910390a15050565b61326e613663565b612bcf816145a6565b610e57613663565b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561336057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613335575b505050918352505060039190910154602090910152805190915060005b82608001515181101561342157600c6000846080015183815181106133a4576133a4615518565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561341a816157c8565b905061337d565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061345360028301826149b2565b60038201600090555050806009600b8282829054906101000a90046bffffffffffffffffffffffff166134869190615800565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af1158015613525573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613549919061582c565b61357f576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612bcf576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610874565b6000816137285760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168015613722579050610fc8565b506137ab565b60005b6003548110156137a957600380548290811061374957613749615518565b9060005260206000200154840361379957600480548290811061376e5761376e615518565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169150610fc89050565b6137a2816157c8565b905061372b565b505b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610874565b6137e86146a1565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613867613bb3565b613870856135ed565b61387a338661470d565b6138848583610818565b600061389088886136e9565b604080516101008101825233815267ffffffffffffffff89166000818152600b6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018e90526060870186905261ffff8d1660808801529484529190526003015460a084015263ffffffff881660c0840152600f546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e88000000000000000000000000000000000000000000000000000000000815293945091929184169163bdd7e8809161397491600401615b10565b610160604051808303816000875af1158015613994573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139b89190615c11565b90506139c933888360a001516147a9565b604051806101600160405280600f60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018373ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613ad69190615866565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152828252805160209182012060e0850180516000908152600e8452848120929092555167ffffffffffffffff8c16808352600b9093529290205490928c92917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613b9b916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908e908e908e90615ce4565b60405180910390a460e0015198975050505050505050565b610e57614884565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613c32576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610814576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613cac7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760006136e9565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613d0f90339060248101615d48565b602060405180830381865afa158015613d2c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d50919061582c565b610e57576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610874565b613d90614884565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138333390565b60006bffffffffffffffffffffffff821115613e81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610874565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916e010000000000000000000000000000900460e01b90613ed290899089908990602401615d77565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613f8457600080fd5b5a611388811015613f9457600080fd5b611388810390508760408204820311613fac57600080fd5b60008086516020880160008b8df193505a900391503d6084811115613fcf575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b6040805180820190915260008082526020820152600061402084613de3565b61402a9086615a16565b90506000816140398886615a3e565b6140439190615a3e565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b90915292832080549297509394508493929161409a91859116615800565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846140d49190615a3e565b336000908152600d6020526040812080549091906141019084906bffffffffffffffffffffffff16615a3e565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b9450909261414891859116615a3e565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d9450909261419c91859116615800565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f168552925290912080546001926009916142209185916901000000000000000000900416615995565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b6060600080808061426686880188615dac565b9350935093509350600061427f8960018787878761385d565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614313578181602081106142be576142be615518565b1a60f81b8782815181106142d4576142d4615518565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535061430c816157c8565b90506142a3565b5050505050509392505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561439857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161436d575b5050505050905060005b8151811015614465576000600c60008484815181106143c3576143c3615518565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff811615158252610100810483169482018590526901000000000000000000900490911691810182905292501461445457506001949350505050565b5061445e816157c8565b90506143a2565b5060009392505050565b600080600080848060200190518101906144899190615e21565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600f80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a50949850929650909450909261456f91601091908601906149d0565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051610b4293929190615f1c565b3373ffffffffffffffffffffffffffffffffffffffff821603614625576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610874565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610874565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff16610814576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff83166024820152604401610874565b67ffffffffffffffff82166000908152600b6020526040812060010180548392906147e39084906bffffffffffffffffffffffff16615a3e565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614859928492900416615995565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e57576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610874565b82805482825590600052602060002090810192821561492c579160200282015b8281111561492c578251825591602001919060010190614911565b50613e81929150614a76565b82805482825590600052602060002090810192821561492c579160200282015b8281111561492c57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614958565b5080546000825590600052602060002090810190612bcf9190614a76565b8280548282559060005260206000209060070160089004810192821561492c5791602002820160005b83821115614a3d57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026149f9565b8015614a6d5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a3d565b5050613e819291505b5b80821115613e815760008155600101614a77565b67ffffffffffffffff81168114612bcf57600080fd5b8035614aac81614a8b565b919050565b600060208284031215614ac357600080fd5b81356114d781614a8b565b63ffffffff81168114612bcf57600080fd5b8035614aac81614ace565b60008060408385031215614afe57600080fd5b8235614b0981614a8b565b91506020830135614b1981614ace565b809150509250929050565b6000815180845260005b81811015614b4a57602081850181015186830182015201614b2e565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114d76020830184614b24565b60008060408385031215614bae57600080fd5b8235614bb981614a8b565b946020939093013593505050565b60008083601f840112614bd957600080fd5b50813567ffffffffffffffff811115614bf157600080fd5b602083019150836020828501011115614c0957600080fd5b9250929050565b600080600060408486031215614c2557600080fd5b83359250602084013567ffffffffffffffff811115614c4357600080fd5b614c4f86828701614bc7565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614caf57614caf614c5c565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614cfc57614cfc614c5c565b604052919050565b600067ffffffffffffffff821115614d1e57614d1e614c5c565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff81168114612bcf57600080fd5b8035614aac81614d28565b600082601f830112614d6657600080fd5b81356020614d7b614d7683614d04565b614cb5565b82815260059290921b84018101918181019086841115614d9a57600080fd5b8286015b84811015614dbe578035614db181614d28565b8352918301918301614d9e565b509695505050505050565b60008060408385031215614ddc57600080fd5b823567ffffffffffffffff80821115614df457600080fd5b818501915085601f830112614e0857600080fd5b81356020614e18614d7683614d04565b82815260059290921b84018101918181019089841115614e3757600080fd5b948201945b83861015614e5557853582529482019490820190614e3c565b96505086013592505080821115614e6b57600080fd5b50614e7885828601614d55565b9150509250929050565b61ffff81168114612bcf57600080fd5b60008060008060008060a08789031215614eab57600080fd5b8635614eb681614a8b565b9550602087013567ffffffffffffffff811115614ed257600080fd5b614ede89828a01614bc7565b9096509450506040870135614ef281614e82565b92506060870135614f0281614ace565b80925050608087013590509295509295509295565b60008060408385031215614f2a57600080fd5b8235614f3581614a8b565b91506020830135614b1981614d28565b6bffffffffffffffffffffffff81168114612bcf57600080fd5b8035614aac81614f45565b60008060408385031215614f7d57600080fd5b8235614f8881614d28565b91506020830135614b1981614f45565b60008060408385031215614fab57600080fd5b8235614fb681614d28565b91506020830135614b1981614a8b565b8015158114612bcf57600080fd5b60008060408385031215614fe757600080fd5b823591506020830135614b1981614fc6565b6000806020838503121561500c57600080fd5b823567ffffffffffffffff8082111561502457600080fd5b818501915085601f83011261503857600080fd5b81358181111561504757600080fd5b8660206101608302850101111561505d57600080fd5b60209290920196919550909350505050565b600082601f83011261508057600080fd5b813567ffffffffffffffff81111561509a5761509a614c5c565b6150cb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cb5565b8181528460208386010111156150e057600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff81168114612bcf57600080fd5b8035614aac816150fd565b69ffffffffffffffffffff81168114612bcf57600080fd5b8035614aac8161511b565b6000610160828403121561515157600080fd5b615159614c8b565b905061516482614f5f565b815261517260208301614d4a565b602082015261518360408301614d4a565b604082015261519460608301614aa1565b60608201526151a560808301614ae0565b60808201526151b660a08301614f5f565b60a08201526151c760c08301615110565b60c082015260e082013560e08201526101006151e4818401615133565b908201526101206151f6838201615110565b90820152610140615208838201615110565b9082015292915050565b600080600080600080610200878903121561522c57600080fd5b863567ffffffffffffffff8082111561524457600080fd5b6152508a838b0161506f565b9750602089013591508082111561526657600080fd5b5061527389828a0161506f565b955050604087013561528481614f45565b9350606087013561529481614f45565b925060808701356152a481614d28565b91506152b38860a0890161513e565b90509295509295509295565b600081518084526020808501945080840160005b8381101561530557815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016152d3565b509495945050505050565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a060808201819052600090610ea2908301846152bf565b6000806000806060858703121561537b57600080fd5b843561538681614d28565b935060208501359250604085013567ffffffffffffffff8111156153a957600080fd5b6153b587828801614bc7565b95989497509550505050565b6000602082840312156153d357600080fd5b5035919050565b6000602082840312156153ec57600080fd5b81356114d781614e82565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154385784518352938301939183019160010161541c565b5050848103604086015261544c81876152bf565b98975050505050505050565b600081518084526020808501945080840160005b8381101561530557815163ffffffff168752958201959082019060010161546c565b6020815261ffff82511660208201526bffffffffffffffffffffffff60208301511660408201527fffffffff00000000000000000000000000000000000000000000000000000000604083015116606082015260006060830151608080840152612dd160a0840182615458565b60006020828403121561550d57600080fd5b81356114d781614d28565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60006020828403121561555957600080fd5b5051919050565b8183823760009101908152919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610fc857610fc8615570565b600181811c908216806155c657607f821691505b6020821081036155ff577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561093d57600081815260208120601f850160051c8101602086101561562c5750805b601f850160051c820191505b8181101561564b57828155600101615638565b505050505050565b815167ffffffffffffffff81111561566d5761566d614c5c565b6156818161567b84546155b2565b84615605565b602080601f8311600181146156d4576000841561569e5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855561564b565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561572157888601518255948401946001909101908401615702565b508582101561575d57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036157f9576157f9615570565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561582557615825615570565b5092915050565b60006020828403121561583e57600080fd5b81516114d781614fc6565b6000610160828403121561585c57600080fd5b6114d7838361513e565b81516bffffffffffffffffffffffff168152610160810160208301516158a4602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516158cc604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516158e8606084018267ffffffffffffffff169052565b506080830151615900608084018263ffffffff169052565b5060a083015161592060a08401826bffffffffffffffffffffffff169052565b5060c083015161593960c084018264ffffffffff169052565b5060e083015160e0830152610100808401516159628285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff81811683821601908082111561582557615825615570565b81810381811115610fc857610fc8615570565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b64ffffffffff81811683821601908082111561582557615825615570565b6bffffffffffffffffffffffff81811683821602808216919082811461598d5761598d615570565b6bffffffffffffffffffffffff81811683821601908082111561582557615825615570565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015260ff8416604082015260a060608201526000615aaf60a0830185614b24565b828103608084015261544c8185614b24565b600067ffffffffffffffff808316818103615ade57615ade615570565b6001019392505050565b838152826020820152606060408201526000615b076060830184614b24565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615b5d610120850183614b24565b91506060850151615b7a608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615bac60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614aac81614f45565b8051614aac81614d28565b8051614aac81614a8b565b8051614aac81614ace565b8051614aac816150fd565b8051614aac8161511b565b60006101608284031215615c2457600080fd5b615c2c614c8b565b615c3583615bcf565b8152615c4360208401615bda565b6020820152615c5460408401615bda565b6040820152615c6560608401615be5565b6060820152615c7660808401615bf0565b6080820152615c8760a08401615bcf565b60a0820152615c9860c08401615bfb565b60c082015260e083015160e0820152610100615cb5818501615c06565b90820152610120615cc7848201615bfb565b90820152610140615cd9848201615bfb565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615d2560c0830186614b24565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000612dd16040830184614b24565b838152606060208201526000615d906060830185614b24565b8281036040840152615da28185614b24565b9695505050505050565b60008060008060808587031215615dc257600080fd5b8435615dcd81614a8b565b9350602085013567ffffffffffffffff811115615de957600080fd5b615df58782880161506f565b9350506040850135615e0681614e82565b91506060850135615e1681614ace565b939692955090935050565b60008060008060808587031215615e3757600080fd5b8451615e4281614e82565b80945050602080860151615e5581614f45565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615e8b57600080fd5b606087015190935067ffffffffffffffff811115615ea857600080fd5b8601601f81018813615eb957600080fd5b8051615ec7614d7682614d04565b81815260059190911b8201830190838101908a831115615ee657600080fd5b928401925b82841015615f0d578351615efe81614ace565b82529284019290840190615eeb565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615b07606083018461545856fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AlreadyApplied\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"\",\"type\":\"uint32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620066d0380380620066d0833981016040819052620000349162000441565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d9816200016e565b50506008805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e816200021f565b5050600980546001600160a01b0319166001600160a01b03949094169390931790925550620006cd945050505050565b336001600160a01b03821603620001c85760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080600080848060200190518101906200023b91906200053e565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600e80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002cb91600f919086019062000313565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000304939291906200065c565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003b75791602002820160005b838211156200038357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200033d565b8015620003b55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000383565b505b50620003c5929150620003c9565b5090565b5b80821115620003c55760008155600101620003ca565b805161ffff81168114620003f357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004395762000439620003f8565b604052919050565b600080600080608085870312156200045857600080fd5b6200046385620003e0565b9350602062000474818701620003e0565b60408701519094506001600160a01b03811681146200049257600080fd5b60608701519093506001600160401b0380821115620004b057600080fd5b818801915088601f830112620004c557600080fd5b815181811115620004da57620004da620003f8565b620004ee601f8201601f191685016200040e565b915080825289848285010111156200050557600080fd5b60005b818110156200052557838101850151838201860152840162000508565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055557600080fd5b6200056085620003e0565b602086810151919550906001600160601b03811681146200058057600080fd5b60408701519094506001600160e01b0319811681146200059f57600080fd5b60608701519093506001600160401b0380821115620005bd57600080fd5b818801915088601f830112620005d257600080fd5b815181811115620005e757620005e7620003f8565b8060051b9150620005fa8483016200040e565b818152918301840191848101908b8411156200061557600080fd5b938501935b838510156200064c578451925063ffffffff831683146200063b5760008081fd5b82825293850193908501906200061a565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bf57845163ffffffff16835293830193918301916001016200069b565b509098975050505050505050565b608051615fe7620006e96000396000612af60152615fe76000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063aab396bd116100ee578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f1461076f578063eb523d6c14610782578063f2fde38b1461079557600080fd5b8063d7ae1d3014610736578063e72f6e3014610749578063e82ad7d41461075c57600080fd5b8063b734c0f4116100c8578063b734c0f4146106ff578063badc3eb614610707578063c3f909d41461071e57600080fd5b8063aab396bd146106bb578063b187bd26146106e1578063b5643858146106ec57600080fd5b80639f87fad711610150578063a47c76961161012a578063a47c769614610675578063a4c0ed3614610695578063a9c9a918146106a857600080fd5b80639f87fad714610639578063a1d4c8281461064c578063a21a23e41461066d57600080fd5b80638456cb59116101815780638456cb59146106065780638da5cb5b1461060e5780638fde53171461063157600080fd5b806379ba5097146105eb57806382359740146105f357600080fd5b8063461d27621161025557806366316d8d116102095780636a2215de116101e35780636a2215de1461058d5780636e3b3323146105c55780637341c10c146105d857600080fd5b806366316d8d146104b857806366419970146104cb578063674603d0146104f857600080fd5b806355fedefa1161023a57806355fedefa146104615780635c975abb1461048e5780635ed6dfba146104a557600080fd5b8063461d27621461043b5780634b8832d31461044e57600080fd5b80631c024539116102b75780633e871e4d116102915780633e871e4d146103ff5780633f4ba83a1461041257806341db4ca31461041a57600080fd5b80631c024539146103d15780631ded3b36146103d9578063385de9ae146103ec57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038857600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614ac3565b6107a8565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b610317610347366004614b04565b610807565b6008546a010000000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610330565b6103c46040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614ba1565b610317610931565b6103176103e7366004614bb4565b610a93565b6103176103fa366004614c29565b610ac4565b61031761040d366004614de2565b610b8d565b610317610e83565b61042d610428366004614eab565b610e95565b604051908152602001610330565b61042d610449366004614eab565b610ef5565b61031761045c366004614f30565b610f01565b61042d61046f366004614ac3565b67ffffffffffffffff166000908152600a602052604090206003015490565b60005460ff165b6040519015158152602001610330565b6103176104b3366004614f83565b610fff565b6103176104c6366004614f83565b6112d4565b60085462010000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b610565610506366004614fb1565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600b6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b6105a061059b366004614fdf565b6114fb565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105d3366004614ff8565b6115ba565b6103176105e6366004614f30565b611890565b610317611a26565b610317610601366004614ac3565b611b48565b610317611c7f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105a0565b610317611c8f565b610317610647366004614f30565b611d81565b61065f61065a366004615211565b612161565b6040516103309291906152f9565b6104df61254d565b610688610683366004614ac3565b6126e0565b6040516103309190615373565b6103176106a33660046153fb565b612815565b6105a06106b6366004614fdf565b612a44565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761042d565b60005460ff16610495565b6103176106fa366004615457565b612aaa565b610317612c0b565b61070f612d9f565b60405161033093929190615474565b610726612e7a565b60405161033094939291906154ff565b610317610744366004614f30565b612f45565b610317610757366004615562565b612fa8565b61049561076a366004614ac3565b6131b2565b61031761077d36600461557f565b6131c3565b610317610790366004614fdf565b6132aa565b6103176107a3366004615562565b613466565b6107b0613477565b6107b98161347f565b67ffffffffffffffff81166000908152600a60205260409020546108049082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166134f5565b50565b67ffffffffffffffff82166000908152600a6020526040812060030154600f54911a90811061086c576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600f805460ff8316908110610883576108836155c1565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561092c57600f805460ff83169081106108d3576108d36155c1565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610863565b505050565b610939613863565b60008080526006602052604080518082019091527f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f880548290829061097d906155f0565b80601f01602080910402602001604051908101604052809291908181526020018280546109a9906155f0565b80156109f65780601f106109cb576101008083540402835291602001916109f6565b820191906000526020600020905b8154815290600101906020018083116109d957829003601f168201915b5050505050815260200160018201548152505090508060200151431015610a49576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051610a54906138e9565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a889160009190615643565b60405180910390a150565b610a9b613477565b610aa48261347f565b67ffffffffffffffff9091166000908152600a6020526040902060030155565b610acc613863565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600854602090910190610b219061ffff1643615693565b9052600084815260066020526040902081518190610b3f90826156f4565b50602082015181600101559050507fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a838383604051610b809392919061580e565b60405180910390a1505050565b610b95613863565b8151815181141580610ba75750600881115b15610bde576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610d0a576000848281518110610bfd57610bfd6155c1565b602002602001015190506000848381518110610c1b57610c1b6155c1565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c86575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cbd576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cf7576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610863565b505080610d0390615862565b9050610be1565b50600854600090610d1f9061ffff1643615693565b604080516060810182528681526020808201879052918101839052865192935091600391610d51918391890190614903565b506020828101518051610d6a926001850192019061494a565b506040820151816002015590505060005b8451811015610e7c577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610db757610db76155c1565b602002602001015160026000888581518110610dd557610dd56155c1565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e1e57610e1e6155c1565b602002602001015185604051610e64949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e7581615862565b9050610d7b565b5050505050565b610e8b613863565b610e93613a2f565b565b600080610ea1836114fb565b9050610ee983828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613aac9050565b98975050505050505050565b600080610ea183612a44565b610f09613dfc565b610f1282613e04565b610f1a613eca565b67ffffffffffffffff82166000908152600a602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c010000000000000000000000009092041614610ffb5767ffffffffffffffff82166000818152600a602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b611007613477565b806bffffffffffffffffffffffff1660000361103d5750306000908152600c60205260409020546bffffffffffffffffffffffff165b306000908152600c60205260409020546bffffffffffffffffffffffff80831691161015611097576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600c6020526040812080548392906110c49084906bffffffffffffffffffffffff1661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806008600a8282829054906101000a90046bffffffffffffffffffffffff1661111b919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156111ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111de91906158c6565b610ffb576009546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611251573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061127591906158e8565b6008546040517fa99da3020000000000000000000000000000000000000000000000000000000081526a01000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610863565b6112dc613dfc565b806bffffffffffffffffffffffff16600003611324576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c60205260409020546bffffffffffffffffffffffff8083169116101561137e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906113ab9084906bffffffffffffffffffffffff1661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806008600a8282829054906101000a90046bffffffffffffffffffffffff16611402919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156114a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114c591906158c6565b610ffb576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b60035460ff82161015611584576003805460ff8316908110611523576115236155c1565b90600052602060002001548303611574576004805460ff831690811061154b5761154b6155c1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61157d81615901565b90506114ff565b506040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101839052602401610863565b6115c2613dfc565b60005b8181101561092c5760008383838181106115e1576115e16155c1565b905061016002018036038101906115f89190615920565b905060008160e001519050600d60008281526020019081526020016000205482604051602001611628919061593d565b6040516020818303038152906040528051906020012014611675576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156116ba576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561172c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061175091906158c6565b5060a0830151606084015167ffffffffffffffff166000908152600a6020526040812060010180549091906117949084906bffffffffffffffffffffffff1661589a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600b6020908152828220606087015167ffffffffffffffff9081168452915291902080546001926009916118209185916901000000000000000000900416615a6c565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600d60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061188990615862565b90506115c5565b611898613dfc565b6118a182613e04565b6118a9613eca565b600e5467ffffffffffffffff83166000908152600a602052604090206002015461ffff9091169003611907576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b6020908152604080832067ffffffffffffffff8616845290915290205460ff161561194e575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600b6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600a84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610ff2565b60015473ffffffffffffffffffffffffffffffffffffffff163314611aa7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610863565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b50613dfc565b611b58613eca565b67ffffffffffffffff81166000908152600a60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611be0576040517f02b543c600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000818152600a602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611c87613863565b610e93613fcf565b611c97613863565b60075464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611cf9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075460085461ffff620100009092048216911603611d43576040517ea8180600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600754600880546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611d89613dfc565b611d9282613e04565b611d9a613eca565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e42576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e97576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600a6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f1257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611ee7575b50505050509050600060018251611f299190615a8d565b905060005b82518110156120c5578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f6057611f606155c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120b5576000838381518110611f9757611f976155c1565b6020026020010151905080600a60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611fdd57611fdd6155c1565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600a9091526040902060020180548061205757612057615aa0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120c5565b6120be81615862565b9050611f2e565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600b6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60008061216c613dfc565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146121d5576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600d602052604090205461223a57600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b60405180910390a2612542565b600d60008460e0015181526020019081526020016000205483604051602001612263919061593d565b60405160208183030381529060405280519060200120146122be57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b826101400151836080015163ffffffff166122d99190615b01565b64ffffffffff165a101561232757600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b600061233c846080015163ffffffff1661402a565b6123469088615b1f565b905060008187866000015161235b9190615b47565b6123659190615b47565b606086015167ffffffffffffffff166000908152600a60205260409020549091506bffffffffffffffffffffffff90811690821611156123ee57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123df93929190615acf565b60405180910390a25050612542565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561245657600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123df93929190615acf565b5050600d60008460e00151815260200190815260200160002060009055600061248e8460e001518a8a876080015188604001516140cc565b805190915061249e5760016124a1565b60005b925060006124d085606001518660a00151876040015188600001518c6124ca886020015161402a565b8d614248565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b83602001518988876000015161251d578e61251f565b8f5b8860400151604051612535959493929190615b6c565b60405180910390a3519150505b965096945050505050565b6000612557613dfc565b61255f613eca565b6008805460029061257f9062010000900467ffffffffffffffff16615bce565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156125f5578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600a825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926126909260028501929091019061494a565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261271a8261347f565b67ffffffffffffffff82166000908152600a6020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156127fb57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116127d0575b505050505081526020016003820154815250509050919050565b61281d613dfc565b60095473ffffffffffffffffffffffffffffffffffffffff16331461286e576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146128a8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006128b682840184614ac3565b67ffffffffffffffff81166000908152600a60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661292f576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600a6020526040812080546bffffffffffffffffffffffff16918691906129668385615b47565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846008600a8282829054906101000a90046bffffffffffffffffffffffff166129bd9190615b47565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8828784612a249190615693565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff168015612a755792915050565b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610863565b612ab2613863565b60085461ffff808316911603612af4576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff161115612b56576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260085461ffff90811680835290841660208301529091820190612b839043615693565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516007805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612c13613863565b600554431015612c4f576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612d7657600060036000018281548110612c7457612c746155c1565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612cc057612cc06155c1565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612d6f90615862565b9050612c52565b5060036000612d8582826149c4565b612d936001830160006149c4565b60028201600090555050565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612dff57602002820191906000526020600020905b815481526020019060010190808311612deb575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612e6857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e3d575b50505050509050925092509250909192565b600e54600f8054604080516020808402820181019092528281526000948594859460609461ffff8416946bffffffffffffffffffffffff62010000860416946e010000000000000000000000000000900460e01b93929091839190830182828015612f3057602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ef35790505b50505050509050935093509350935090919293565b612f4d613dfc565b612f5682613e04565b612f5e613eca565b612f6782614491565b15612f9e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ffb82826134f5565b612fb0613477565b6009546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561301f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061304391906158e8565b6008549091506a010000000000000000000090046bffffffffffffffffffffffff16818111156130a9576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610863565b8181101561092c5760006130bd8284615a8d565b6009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015613138573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061315c91906158c6565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b60006131bd82614491565b92915050565b6131cb613863565b6040805160606020601f850181900402820181018352918101838152909182919085908590819085018382808284376000920191909152505050908252506008546020909101906132209061ffff1643615693565b905260008052600660205280517f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f890819061325b90826156f4565b50602091909101516001909101556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a9061329e906000908590859061580e565b60405180910390a15050565b6132b2613863565b60008181526006602052604080822081518083019092528054829082906132d8906155f0565b80601f0160208091040260200160405190810160405280929190818152602001828054613304906155f0565b80156133515780601f1061332657610100808354040283529160200191613351565b820191906000526020600020905b81548152906001019060200180831161333457829003601f168201915b50505050508152602001600182015481525050905080602001514310156133a4576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6133ad82612a44565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161340191600401614ba1565b600060405180830381600087803b15801561341b57600080fd5b505af115801561342f573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c7935061329e9250859190615643565b61346e613863565b610804816145e0565b610e93613863565b67ffffffffffffffff81166000908152600a60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600a60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156135d657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116135ab575b505050918352505060039190910154602090910152805190915060005b82608001515181101561369757600b60008460800151838151811061361a5761361a6155c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561369081615862565b90506135f3565b5067ffffffffffffffff84166000908152600a6020526040812081815560018101829055906136c960028301826149c4565b60038201600090555050806008600a8282829054906101000a90046bffffffffffffffffffffffff166136fc919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561379b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137bf91906158c6565b6137f5576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610863565b600080600080848060200190518101906139039190615c0b565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600e80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a5094985092965090945090926139e991600f91908601906149e2565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051613a2093929190615d06565b60405180910390a15050505050565b613a376146db565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613ab6613dfc565b613abf8561347f565b613ac93386614747565b613ad38583610807565b604080516101008101825233815267ffffffffffffffff87166000818152600a6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b1660808801529484529190526003015460a084015263ffffffff861660c0840152600e546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e88091613bb39190600401615d5e565b610160604051808303816000875af1158015613bd3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bf79190615e49565b9050604051806101600160405280600e60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613d06919061593d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600d90935291205560a0810151613d6090339088906147bb565b60e081015167ffffffffffffffff87166000818152600a60205260409081902054905191928b9290917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613de5916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908d908d908d90615f1c565b60405180910390a460e00151979650505050505050565b610e93614896565b67ffffffffffffffff81166000908152600a60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e7b576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610ffb576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ef37fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097612a44565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613f5690339060248101615f80565b602060405180830381865afa158015613f73573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f9791906158c6565b610e93576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610863565b613fd7614896565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a823390565b60006bffffffffffffffffffffffff8211156140c8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610863565b5090565b60408051606080820183526000808352602083015291810191909152600e546040516000916e010000000000000000000000000000900460e01b9061411990899089908990602401615faf565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b6141cb57600080fd5b5a6113888110156141db57600080fd5b6113888103905087604082048203116141f357600080fd5b60008086516020880160008b8df193505a900391503d6084811115614216575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006142688486615b1f565b90506000816142778886615b47565b6142819190615b47565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600a9091529283208054929750939450849392916142d89185911661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846143129190615b47565b336000908152600c60205260408120805490919061433f9084906bffffffffffffffffffffffff16615b47565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600c6020526040812080548b9450909261438691859116615b47565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600a6020526040812060010180548d945090926143da9185911661589a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600b6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161445e9185916901000000000000000000900416615a6c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b67ffffffffffffffff81166000908152600a602090815260408083206002018054825181850281018501909352808352849383018282801561450957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116144de575b5050505050905060005b81518110156145d6576000600b6000848481518110614534576145346155c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146145c557506001949350505050565b506145cf81615862565b9050614513565b5060009392505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361465f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610863565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610863565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600b6020908152604080832067ffffffffffffffff8516845290915290205460ff16610ffb576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600a6020526040812060010180548392906147f59084906bffffffffffffffffffffffff16615b47565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600b6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261486b928492900416615a6c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610863565b82805482825590600052602060002090810192821561493e579160200282015b8281111561493e578251825591602001919060010190614923565b506140c8929150614a88565b82805482825590600052602060002090810192821561493e579160200282015b8281111561493e57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061496a565b50805460008255906000526020600020908101906108049190614a88565b8280548282559060005260206000209060070160089004810192821561493e5791602002820160005b83821115614a4f57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a0b565b8015614a7f5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a4f565b50506140c89291505b5b808211156140c85760008155600101614a89565b67ffffffffffffffff8116811461080457600080fd5b8035614abe81614a9d565b919050565b600060208284031215614ad557600080fd5b8135614ae081614a9d565b9392505050565b63ffffffff8116811461080457600080fd5b8035614abe81614ae7565b60008060408385031215614b1757600080fd5b8235614b2281614a9d565b91506020830135614b3281614ae7565b809150509250929050565b6000815180845260005b81811015614b6357602081850181015186830182015201614b47565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614ae06020830184614b3d565b60008060408385031215614bc757600080fd5b8235614bd281614a9d565b946020939093013593505050565b60008083601f840112614bf257600080fd5b50813567ffffffffffffffff811115614c0a57600080fd5b602083019150836020828501011115614c2257600080fd5b9250929050565b600080600060408486031215614c3e57600080fd5b83359250602084013567ffffffffffffffff811115614c5c57600080fd5b614c6886828701614be0565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614cc857614cc8614c75565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d1557614d15614c75565b604052919050565b600067ffffffffffffffff821115614d3757614d37614c75565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461080457600080fd5b8035614abe81614d41565b600082601f830112614d7f57600080fd5b81356020614d94614d8f83614d1d565b614cce565b82815260059290921b84018101918181019086841115614db357600080fd5b8286015b84811015614dd7578035614dca81614d41565b8352918301918301614db7565b509695505050505050565b60008060408385031215614df557600080fd5b823567ffffffffffffffff80821115614e0d57600080fd5b818501915085601f830112614e2157600080fd5b81356020614e31614d8f83614d1d565b82815260059290921b84018101918181019089841115614e5057600080fd5b948201945b83861015614e6e57853582529482019490820190614e55565b96505086013592505080821115614e8457600080fd5b50614e9185828601614d6e565b9150509250929050565b61ffff8116811461080457600080fd5b60008060008060008060a08789031215614ec457600080fd5b8635614ecf81614a9d565b9550602087013567ffffffffffffffff811115614eeb57600080fd5b614ef789828a01614be0565b9096509450506040870135614f0b81614e9b565b92506060870135614f1b81614ae7565b80925050608087013590509295509295509295565b60008060408385031215614f4357600080fd5b8235614f4e81614a9d565b91506020830135614b3281614d41565b6bffffffffffffffffffffffff8116811461080457600080fd5b8035614abe81614f5e565b60008060408385031215614f9657600080fd5b8235614fa181614d41565b91506020830135614b3281614f5e565b60008060408385031215614fc457600080fd5b8235614fcf81614d41565b91506020830135614b3281614a9d565b600060208284031215614ff157600080fd5b5035919050565b6000806020838503121561500b57600080fd5b823567ffffffffffffffff8082111561502357600080fd5b818501915085601f83011261503757600080fd5b81358181111561504657600080fd5b8660206101608302850101111561505c57600080fd5b60209290920196919550909350505050565b600082601f83011261507f57600080fd5b813567ffffffffffffffff81111561509957615099614c75565b6150ca60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cce565b8181528460208386010111156150df57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461080457600080fd5b8035614abe816150fc565b69ffffffffffffffffffff8116811461080457600080fd5b8035614abe8161511a565b6000610160828403121561515057600080fd5b615158614ca4565b905061516382614f78565b815261517160208301614d63565b602082015261518260408301614d63565b604082015261519360608301614ab3565b60608201526151a460808301614af9565b60808201526151b560a08301614f78565b60a08201526151c660c0830161510f565b60c082015260e082013560e08201526101006151e3818401615132565b908201526101206151f583820161510f565b9082015261014061520783820161510f565b9082015292915050565b600080600080600080610200878903121561522b57600080fd5b863567ffffffffffffffff8082111561524357600080fd5b61524f8a838b0161506e565b9750602089013591508082111561526557600080fd5b5061527289828a0161506e565b955050604087013561528381614f5e565b9350606087013561529381614f5e565b925060808701356152a381614d41565b91506152b28860a0890161513d565b90509295509295509295565b600781106152f5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161530782856152be565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561536857815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615336565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526153e560e0840182615322565b905060a084015160c08401528091505092915050565b6000806000806060858703121561541157600080fd5b843561541c81614d41565b935060208501359250604085013567ffffffffffffffff81111561543f57600080fd5b61544b87828801614be0565b95989497509550505050565b60006020828403121561546957600080fd5b8135614ae081614e9b565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154b557845183529383019391830191600101615499565b50508481036040860152610ee98187615322565b600081518084526020808501945080840160005b8381101561536857815163ffffffff16875295820195908201906001016154dd565b61ffff851681526bffffffffffffffffffffffff841660208201527fffffffff000000000000000000000000000000000000000000000000000000008316604082015260806060820152600061555860808301846154c9565b9695505050505050565b60006020828403121561557457600080fd5b8135614ae081614d41565b6000806020838503121561559257600080fd5b823567ffffffffffffffff8111156155a957600080fd5b6155b585828601614be0565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c9082168061560457607f821691505b60208210810361563d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b82815260406020820152600061565c6040830184614b3d565b949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156131bd576131bd615664565b601f82111561092c57600081815260208120601f850160051c810160208610156156cd5750805b601f850160051c820191505b818110156156ec578281556001016156d9565b505050505050565b815167ffffffffffffffff81111561570e5761570e614c75565b6157228161571c84546155f0565b846156a6565b602080601f831160018114615775576000841561573f5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156ec565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157c2578886015182559484019460019091019084016157a3565b50858210156157fe57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361589357615893615664565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158bf576158bf615664565b5092915050565b6000602082840312156158d857600080fd5b81518015158114614ae057600080fd5b6000602082840312156158fa57600080fd5b5051919050565b600060ff821660ff810361591757615917615664565b60010192915050565b6000610160828403121561593357600080fd5b614ae0838361513d565b81516bffffffffffffffffffffffff1681526101608101602083015161597b602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516159a3604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159bf606084018267ffffffffffffffff169052565b5060808301516159d7608084018263ffffffff169052565b5060a08301516159f760a08401826bffffffffffffffffffffffff169052565b5060c0830151615a1060c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a398285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff8181168382160190808211156158bf576158bf615664565b818103818111156131bd576131bd615664565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161565c60408301846152be565b64ffffffffff8181168382160190808211156158bf576158bf615664565b6bffffffffffffffffffffffff818116838216028082169190828114615a6457615a64615664565b6bffffffffffffffffffffffff8181168382160190808211156158bf576158bf615664565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615ba660408201856152be565b60a060608201526000615bbc60a0830185614b3d565b8281036080840152610ee98185614b3d565b600067ffffffffffffffff808316818103615beb57615beb615664565b6001019392505050565b8051614abe81614f5e565b8051614abe81614ae7565b60008060008060808587031215615c2157600080fd5b8451615c2c81614e9b565b80945050602080860151615c3f81614f5e565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615c7557600080fd5b606087015190935067ffffffffffffffff811115615c9257600080fd5b8601601f81018813615ca357600080fd5b8051615cb1614d8f82614d1d565b81815260059190911b8201830190838101908a831115615cd057600080fd5b928401925b82841015615cf7578351615ce881614ae7565b82529284019290840190615cd5565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615d5560608301846154c9565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615dab610120850183614b3d565b91506060850151615dc8608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615dfa60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614abe81614d41565b8051614abe81614a9d565b8051614abe816150fc565b8051614abe8161511a565b60006101608284031215615e5c57600080fd5b615e64614ca4565b615e6d83615bf5565b8152615e7b60208401615e1d565b6020820152615e8c60408401615e1d565b6040820152615e9d60608401615e28565b6060820152615eae60808401615c00565b6080820152615ebf60a08401615bf5565b60a0820152615ed060c08401615e33565b60c082015260e083015160e0820152610100615eed818501615e3e565b90820152610120615eff848201615e33565b90820152610140615f11848201615e33565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615f5d60c0830186614b3d565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff8316815260406020820152600061565c6040830184614b3d565b838152606060208201526000615fc86060830185614b3d565b82810360408401526155588185614b3d56fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -236,50 +238,31 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetAllowListId() ([32]byte return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (uint16, *big.Int, [4]byte, []uint32, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getConfig") if err != nil { - return *new(IFunctionsRouterConfig), err + return *new(uint16), *new(*big.Int), *new([4]byte), *new([]uint32), err } - out0 := *abi.ConvertType(out[0], new(IFunctionsRouterConfig)).(*IFunctionsRouterConfig) + out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) + out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + out2 := *abi.ConvertType(out[2], new([4]byte)).(*[4]byte) + out3 := *abi.ConvertType(out[3], new([]uint32)).(*[]uint32) - return out0, err + return out0, out1, out2, out3, err } -func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (IFunctionsRouterConfig, error) { +func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (uint16, *big.Int, [4]byte, []uint32, error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (IFunctionsRouterConfig, error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (uint16, *big.Int, [4]byte, []uint32, error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getConfigHash") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetConfigHash() ([32]byte, error) { - return _FunctionsRouter.Contract.GetConfigHash(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfigHash() ([32]byte, error) { - return _FunctionsRouter.Contract.GetConfigHash(&_FunctionsRouter.CallOpts) -} - func (_FunctionsRouter *FunctionsRouterCaller) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, error) { @@ -311,9 +294,9 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetConsumer(client common. return _FunctionsRouter.Contract.GetConsumer(&_FunctionsRouter.CallOpts, client, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCaller) GetContractById(opts *bind.CallOpts, id [32]byte, useProposed bool) (common.Address, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) { var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getContractById", id, useProposed) + err := _FunctionsRouter.contract.Call(opts, &out, "getContractById", id) if err != nil { return *new(common.Address), err @@ -325,56 +308,56 @@ func (_FunctionsRouter *FunctionsRouterCaller) GetContractById(opts *bind.CallOp } -func (_FunctionsRouter *FunctionsRouterSession) GetContractById(id [32]byte, useProposed bool) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById(&_FunctionsRouter.CallOpts, id, useProposed) +func (_FunctionsRouter *FunctionsRouterSession) GetContractById(id [32]byte) (common.Address, error) { + return _FunctionsRouter.Contract.GetContractById(&_FunctionsRouter.CallOpts, id) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetContractById(id [32]byte, useProposed bool) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById(&_FunctionsRouter.CallOpts, id, useProposed) +func (_FunctionsRouter *FunctionsRouterCallerSession) GetContractById(id [32]byte) (common.Address, error) { + return _FunctionsRouter.Contract.GetContractById(&_FunctionsRouter.CallOpts, id) } -func (_FunctionsRouter *FunctionsRouterCaller) GetContractById0(opts *bind.CallOpts, id [32]byte) (common.Address, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetFlags(opts *bind.CallOpts, subscriptionId uint64) ([32]byte, error) { var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getContractById0", id) + err := _FunctionsRouter.contract.Call(opts, &out, "getFlags", subscriptionId) if err != nil { - return *new(common.Address), err + return *new([32]byte), err } - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetContractById0(id [32]byte) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById0(&_FunctionsRouter.CallOpts, id) +func (_FunctionsRouter *FunctionsRouterSession) GetFlags(subscriptionId uint64) ([32]byte, error) { + return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetContractById0(id [32]byte) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById0(&_FunctionsRouter.CallOpts, id) +func (_FunctionsRouter *FunctionsRouterCallerSession) GetFlags(subscriptionId uint64) ([32]byte, error) { + return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCaller) GetFlags(opts *bind.CallOpts, subscriptionId uint64) ([32]byte, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) { var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getFlags", subscriptionId) + err := _FunctionsRouter.contract.Call(opts, &out, "getProposedContractById", id) if err != nil { - return *new([32]byte), err + return *new(common.Address), err } - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetFlags(subscriptionId uint64) ([32]byte, error) { - return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) +func (_FunctionsRouter *FunctionsRouterSession) GetProposedContractById(id [32]byte) (common.Address, error) { + return _FunctionsRouter.Contract.GetProposedContractById(&_FunctionsRouter.CallOpts, id) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetFlags(subscriptionId uint64) ([32]byte, error) { - return _FunctionsRouter.Contract.GetFlags(&_FunctionsRouter.CallOpts, subscriptionId) +func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractById(id [32]byte) (common.Address, error) { + return _FunctionsRouter.Contract.GetProposedContractById(&_FunctionsRouter.CallOpts, id) } func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) { @@ -401,36 +384,25 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() ( return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getSubscription", subscriptionId) - outstruct := new(GetSubscription) if err != nil { - return *outstruct, err + return *new(IFunctionsSubscriptionsSubscription), err } - outstruct.Balance = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - outstruct.BlockedBalance = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - outstruct.Owner = *abi.ConvertType(out[2], new(common.Address)).(*common.Address) - outstruct.RequestedOwner = *abi.ConvertType(out[3], new(common.Address)).(*common.Address) - outstruct.Consumers = *abi.ConvertType(out[4], new([]common.Address)).(*[]common.Address) + out0 := *abi.ConvertType(out[0], new(IFunctionsSubscriptionsSubscription)).(*IFunctionsSubscriptionsSubscription) - return *outstruct, err + return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { +func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) } @@ -668,16 +640,16 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) CreateSubscription() ( return _FunctionsRouter.Contract.CreateSubscription(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "fulfill", response, err, juelsPerGas, costWithoutFulfillment, transmitter, commitment) +func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "fulfill", response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } -func (_FunctionsRouter *FunctionsRouterSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { - return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutFulfillment, transmitter, commitment) +func (_FunctionsRouter *FunctionsRouterSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } -func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { - return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutFulfillment, transmitter, commitment) +func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { + return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } func (_FunctionsRouter *FunctionsRouterTransactor) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { @@ -752,6 +724,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeConfigUpdate(id return _FunctionsRouter.Contract.ProposeConfigUpdate(&_FunctionsRouter.TransactOpts, id, config) } +func (_FunctionsRouter *FunctionsRouterTransactor) ProposeConfigUpdateSelf(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "proposeConfigUpdateSelf", config) +} + +func (_FunctionsRouter *FunctionsRouterSession) ProposeConfigUpdateSelf(config []byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.ProposeConfigUpdateSelf(&_FunctionsRouter.TransactOpts, config) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeConfigUpdateSelf(config []byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.ProposeConfigUpdateSelf(&_FunctionsRouter.TransactOpts, config) +} + func (_FunctionsRouter *FunctionsRouterTransactor) ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetAddresses []common.Address) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "proposeContractsUpdate", proposedContractSetIds, proposedContractSetAddresses) } @@ -824,6 +808,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) SendRequest(subscripti return _FunctionsRouter.Contract.SendRequest(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) } +func (_FunctionsRouter *FunctionsRouterTransactor) SendRequestToProposed(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "sendRequestToProposed", subscriptionId, data, dataVersion, callbackGasLimit, donId) +} + +func (_FunctionsRouter *FunctionsRouterSession) SendRequestToProposed(subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.SendRequestToProposed(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) SendRequestToProposed(subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.SendRequestToProposed(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) +} + func (_FunctionsRouter *FunctionsRouterTransactor) SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "setFlags", subscriptionId, flags) } @@ -884,6 +880,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateConfig(id [32]by return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, id) } +func (_FunctionsRouter *FunctionsRouterTransactor) UpdateConfigSelf(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "updateConfigSelf") +} + +func (_FunctionsRouter *FunctionsRouterSession) UpdateConfigSelf() (*types.Transaction, error) { + return _FunctionsRouter.Contract.UpdateConfigSelf(&_FunctionsRouter.TransactOpts) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateConfigSelf() (*types.Transaction, error) { + return _FunctionsRouter.Contract.UpdateConfigSelf(&_FunctionsRouter.TransactOpts) +} + func (_FunctionsRouter *FunctionsRouterTransactor) UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "updateContracts") } @@ -908,18 +916,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateTimelockBlocks() return _FunctionsRouter.Contract.UpdateTimelockBlocks(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) ValidateProposedContracts(opts *bind.TransactOpts, id [32]byte, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "validateProposedContracts", id, data) -} - -func (_FunctionsRouter *FunctionsRouterSession) ValidateProposedContracts(id [32]byte, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ValidateProposedContracts(&_FunctionsRouter.TransactOpts, id, data) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ValidateProposedContracts(id [32]byte, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ValidateProposedContracts(&_FunctionsRouter.TransactOpts, id, data) -} - type FunctionsRouterConfigChangedIterator struct { Event *FunctionsRouterConfigChanged @@ -1100,10 +1096,9 @@ func (it *FunctionsRouterConfigProposedIterator) Close() error { } type FunctionsRouterConfigProposed struct { - Id [32]byte - FromHash [32]byte - ToBytes []byte - Raw types.Log + Id [32]byte + ToBytes []byte + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) { @@ -1219,10 +1214,9 @@ func (it *FunctionsRouterConfigUpdatedIterator) Close() error { } type FunctionsRouterConfigUpdated struct { - Id [32]byte - FromHash [32]byte - ToBytes []byte - Raw types.Log + Id [32]byte + ToBytes []byte + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsRouterConfigUpdatedIterator, error) { @@ -1458,10 +1452,10 @@ func (it *FunctionsRouterContractUpdatedIterator) Close() error { } type FunctionsRouterContractUpdated struct { - ProposedContractSetId [32]byte - ProposedContractSetFromAddress common.Address - ProposedContractSetToAddress common.Address - Raw types.Log + Id [32]byte + From common.Address + To common.Address + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterContractUpdated(opts *bind.FilterOpts) (*FunctionsRouterContractUpdatedIterator, error) { @@ -3830,13 +3824,6 @@ type GetConsumer struct { InitiatedRequests uint64 CompletedRequests uint64 } -type GetSubscription struct { - Balance *big.Int - BlockedBalance *big.Int - Owner common.Address - RequestedOwner common.Address - Consumers []common.Address -} func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { @@ -3897,11 +3884,11 @@ func (FunctionsRouterConfigChanged) Topic() common.Hash { } func (FunctionsRouterConfigProposed) Topic() common.Hash { - return common.HexToHash("0x0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf") + return common.HexToHash("0xdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a") } func (FunctionsRouterConfigUpdated) Topic() common.Hash { - return common.HexToHash("0xc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47") + return common.HexToHash("0xd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c7") } func (FunctionsRouterContractProposed) Topic() common.Hash { @@ -3993,25 +3980,21 @@ type FunctionsRouterInterface interface { GetAllowListId(opts *bind.CallOpts) ([32]byte, error) - GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) - - GetConfigHash(opts *bind.CallOpts) ([32]byte, error) + GetConfig(opts *bind.CallOpts) (uint16, *big.Int, [4]byte, []uint32, error) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, error) - GetContractById(opts *bind.CallOpts, id [32]byte, useProposed bool) (common.Address, error) - - GetContractById0(opts *bind.CallOpts, id [32]byte) (common.Address, error) + GetContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) GetFlags(opts *bind.CallOpts, subscriptionId uint64) ([32]byte, error) - GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) + GetProposedContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) - GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, + GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) - error) + GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) GetSubscriptionCount(opts *bind.CallOpts) (uint64, error) @@ -4039,7 +4022,7 @@ type FunctionsRouterInterface interface { CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) - Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) + Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) @@ -4053,6 +4036,8 @@ type FunctionsRouterInterface interface { ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) + ProposeConfigUpdateSelf(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) + ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetAddresses []common.Address) (*types.Transaction, error) ProposeSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) @@ -4065,6 +4050,8 @@ type FunctionsRouterInterface interface { SendRequest(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) + SendRequestToProposed(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) + SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) @@ -4075,12 +4062,12 @@ type FunctionsRouterInterface interface { UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) + UpdateConfigSelf(opts *bind.TransactOpts) (*types.Transaction, error) + UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) UpdateTimelockBlocks(opts *bind.TransactOpts) (*types.Transaction, error) - ValidateProposedContracts(opts *bind.TransactOpts, id [32]byte, data []byte) (*types.Transaction, error) - FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigChanged) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 857c960e0a7..0f2a76161d2 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,10 +1,10 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 666319c8b9b06d75db166d87a7338a79e9abe9eff71b73ea905f16f9e7cc95cf +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a6a0fae8fe9c6124f03bf66208fc74eac185be57919e9a3906f4020f0bde2074 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 607be9fa262f499aeadb5572907eb9ed78c3ca1595a14ef0ef1bbeeda8da94bc -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 31b716f2bd9e26d5fd41d2c239cf102622de78b7aafcbb041d1298cb72079a09 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 9f3279ec5b9d6e724c596b5e315a07d64dea43e26f33eacd38145790d0cb92d6 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 2047f8424d3038672f347ef5e6b401f0347b42f64defd43033cc75e0ac537287 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index e00729b9fdd..7dc23007bb3 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -114,13 +114,11 @@ func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToke allowed, err := allowListContract.HasAccess(nilOpts, owner.From, []byte{}) require.NoError(t, err) if !allowed { - messageHash, err := allowListContract.GetMessageHash(nilOpts, owner.From, owner.From) - require.NoError(t, err) - ethMessageHash, err := allowListContract.GetEthSignedMessageHash(nilOpts, messageHash) + message, err := allowListContract.GetMessage(nilOpts, owner.From, owner.From) require.NoError(t, err) privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) require.NoError(t, err) - flatSignature, err := crypto.Sign(ethMessageHash[:], privateKey) + flatSignature, err := crypto.Sign(message[:], privateKey) var r [32]byte copy(r[:], flatSignature[:32]) var s [32]byte From 148c9be0c067ef256300e796eed3137393679e81 Mon Sep 17 00:00:00 2001 From: jinhoonbang Date: Wed, 2 Aug 2023 02:49:07 -0700 Subject: [PATCH 059/270] vrf v2 integration tests (#9964) * run existing tests with native payment; add tests for migration and cancel subscription * run prettier * add missing tests * fix failing tests * fix failing test * address comment * add some logging to debug test flakes * debugging flakey tests * fix tests * failing test --------- Co-authored-by: Makram --- contracts/scripts/native_solc_compile_all | 1 + .../dev/interfaces/IVRFCoordinatorV2Plus.sol | 4 +- .../testhelpers/VRFV2PlusConsumerExample.sol | 19 +- core/chains/evm/txmgr/txmgr_test.go | 2 + .../vrf_coordinator_v2_plus_v2_example.go | 480 +++++++++++ .../vrfv2plus_consumer_example.go | 32 +- ...rapper-dependency-versions-do-not-edit.txt | 3 +- core/gethwrappers/go_generate.go | 1 + core/services/blockhashstore/feeder_test.go | 257 +++++- core/services/job/job_orm_test.go | 85 ++ core/services/vrf/delegate.go | 16 +- core/services/vrf/delegate_test.go | 34 + .../vrf/v2/coordinator_v2x_interface.go | 29 +- .../vrf/v2/integration_helpers_test.go | 117 +-- .../vrf/v2/integration_v2_plus_test.go | 779 ++++++++++++++---- core/services/vrf/v2/integration_v2_test.go | 61 +- core/services/vrf/v2/listener_v2.go | 54 +- core/services/vrf/v2/listener_v2_test.go | 75 ++ .../services/vrf/v2/listener_v2_types_test.go | 41 + .../vrf/vrftesthelpers/consumer_v2.go | 30 + 20 files changed, 1864 insertions(+), 256 deletions(-) create mode 100644 core/gethwrappers/generated/vrf_coordinator_v2_plus_v2_example/vrf_coordinator_v2_plus_v2_example.go diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 82e8724774c..47e779a769f 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -111,6 +111,7 @@ $SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusWrapperConsumerE $SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol $SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol $SCRIPTPATH/native_solc8_6_compile dev/vrf/libraries/VRFV2PlusClient.sol +$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol # VRF V2 Wrapper $SCRIPTPATH/native_solc8_6_compile vrf/VRFV2Wrapper.sol diff --git a/contracts/src/v0.8/dev/interfaces/IVRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/interfaces/IVRFCoordinatorV2Plus.sol index 3b6f5b6773c..ea37fb83875 100644 --- a/contracts/src/v0.8/dev/interfaces/IVRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/interfaces/IVRFCoordinatorV2Plus.sol @@ -36,7 +36,7 @@ interface IVRFCoordinatorV2Plus { * numWords - The number of uint256 random values you'd like to receive * in your fulfillRandomWords callback. Note these numbers are expanded in a * secure way by the VRFCoordinator from a single random value supplied by the oracle. - * nativePayment - Whether payment should be made in ETH or LINK. + * extraArgs - abi-encoded extra args * @return requestId - A unique identifier of the request. Can be used to match * a request to a response in fulfillRandomWords. */ @@ -110,4 +110,6 @@ interface IVRFCoordinatorV2Plus { * otherwise. */ function pendingRequestExists(uint256 subId) external view returns (bool); + + function fundSubscriptionWithEth(uint256 subId) external payable; } diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol index 8178704597e..598375420fd 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol @@ -4,7 +4,6 @@ pragma solidity ^0.8.0; import "../../../interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; -import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../../../ConfirmedOwner.sol"; /// @notice This contract is used for testing only and should not be used for production. @@ -33,19 +32,35 @@ contract VRFV2PlusConsumerExample is ConfirmedOwner, VRFConsumerBaseV2Plus { return resp.randomWords[idx]; } - function createSubscriptionAndFund(uint96 amount) external { + function subscribe() internal returns (uint256) { if (s_subId == 0) { s_subId = s_vrfCoordinatorApiV1.createSubscription(); s_vrfCoordinatorApiV1.addConsumer(s_subId, address(this)); } + return s_subId; + } + + function createSubscriptionAndFundNative() external payable { + subscribe(); + s_vrfCoordinatorApiV1.fundSubscriptionWithEth{value: msg.value}(s_subId); + } + + function createSubscriptionAndFund(uint96 amount) external { + subscribe(); // Approve the link transfer. s_linkToken.transferAndCall(address(s_vrfCoordinator), amount, abi.encode(s_subId)); } function topUpSubscription(uint96 amount) external { + require(s_subId != 0, "sub not set"); s_linkToken.transferAndCall(address(s_vrfCoordinator), amount, abi.encode(s_subId)); } + function topUpSubscriptionNative() external payable { + require(s_subId != 0, "sub not set"); + s_vrfCoordinatorApiV1.fundSubscriptionWithEth{value: msg.value}(s_subId); + } + function fulfillRandomWords(uint256 requestId, uint256[] memory randomWords) internal override { require(requestId == s_recentRequestId, "request ID is incorrect"); s_requests[requestId].randomWords = randomWords; diff --git a/core/chains/evm/txmgr/txmgr_test.go b/core/chains/evm/txmgr/txmgr_test.go index 99138e3c1e8..c3c995e8abf 100644 --- a/core/chains/evm/txmgr/txmgr_test.go +++ b/core/chains/evm/txmgr/txmgr_test.go @@ -248,6 +248,7 @@ func TestTxm_CreateTransaction(t *testing.T) { pgtest.MustExec(t, db, `DELETE FROM eth_txes`) testDefaultSubID := uint64(2) testDefaultMaxLink := "1000000000000000000" + testDefaultMaxEth := "2000000000000000000" // max uint256 is 1.1579209e+77 testDefaultGlobalSubID := crypto.Keccak256Hash([]byte("sub id")).String() jobID := int32(25) @@ -258,6 +259,7 @@ func TestTxm_CreateTransaction(t *testing.T) { RequestID: &requestID, RequestTxHash: &requestTxHash, MaxLink: &testDefaultMaxLink, // 1e18 + MaxEth: &testDefaultMaxEth, // 2e18 SubID: &testDefaultSubID, GlobalSubID: &testDefaultGlobalSubID, } diff --git a/core/gethwrappers/generated/vrf_coordinator_v2_plus_v2_example/vrf_coordinator_v2_plus_v2_example.go b/core/gethwrappers/generated/vrf_coordinator_v2_plus_v2_example/vrf_coordinator_v2_plus_v2_example.go new file mode 100644 index 00000000000..93faeada261 --- /dev/null +++ b/core/gethwrappers/generated/vrf_coordinator_v2_plus_v2_example/vrf_coordinator_v2_plus_v2_example.go @@ -0,0 +1,480 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package vrf_coordinator_v2_plus_v2_example + +import ( + "errors" + "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" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type VRFV2PlusClientRandomWordsRequest struct { + KeyHash [32]byte + SubId *big.Int + RequestConfirmations uint16 + CallbackGasLimit uint32 + NumWords uint32 + ExtraArgs []byte +} + +var VRFCoordinatorV2PlusV2ExampleMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"prevCoordinator\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"transferredValue\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"expectedValue\",\"type\":\"uint96\"}],\"name\":\"InvalidNativeBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"requestVersion\",\"type\":\"uint8\"},{\"internalType\":\"uint8\",\"name\":\"expectedVersion\",\"type\":\"uint8\"}],\"name\":\"InvalidVersion\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"previousCoordinator\",\"type\":\"address\"}],\"name\":\"MustBePreviousCoordinator\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestID\",\"type\":\"uint256\"}],\"name\":\"generateFakeRandomness\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"uint96\",\"name\":\"linkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"nativeBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedData\",\"type\":\"bytes\"}],\"name\":\"onMigration\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_link\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_prevCoordinator\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestConsumerMapping\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_requestId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_subscriptions\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"linkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"nativeBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalLinkBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalNativeBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x6080604052600060035534801561001557600080fd5b50604051610f65380380610f6583398101604081905261003491610081565b600580546001600160a01b039384166001600160a01b031991821617909155600480549290931691161790556100b4565b80516001600160a01b038116811461007c57600080fd5b919050565b6000806040838503121561009457600080fd5b61009d83610065565b91506100ab60208401610065565b90509250929050565b610ea2806100c36000396000f3fe6080604052600436106100c75760003560e01c8063ce3f471911610074578063dc311dd31161004e578063dc311dd314610325578063e89e106a14610355578063ed8b558f1461036b57600080fd5b8063ce3f4719146102c3578063d6100d1c146102d8578063da4f5e6d146102f857600080fd5b806386175f58116100a557806386175f581461022557806393f3acb6146102685780639b1c385e1461029557600080fd5b80630495f265146100cc578063086597b31461018157806318e3dd27146101d3575b600080fd5b3480156100d857600080fd5b5061013b6100e7366004610c86565b6000602081905290815260409020805460029091015473ffffffffffffffffffffffffffffffffffffffff909116906bffffffffffffffffffffffff808216916c0100000000000000000000000090041683565b6040805173ffffffffffffffffffffffffffffffffffffffff90941684526bffffffffffffffffffffffff92831660208501529116908201526060015b60405180910390f35b34801561018d57600080fd5b506004546101ae9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610178565b3480156101df57600080fd5b50600254610208906c0100000000000000000000000090046bffffffffffffffffffffffff1681565b6040516bffffffffffffffffffffffff9091168152602001610178565b34801561023157600080fd5b506101ae610240366004610c86565b60016020526000908152604090205473ffffffffffffffffffffffffffffffffffffffff1681565b34801561027457600080fd5b50610288610283366004610c86565b610390565b6040516101789190610d63565b3480156102a157600080fd5b506102b56102b0366004610b81565b61043b565b604051908152602001610178565b6102d66102d1366004610b0f565b61044c565b005b3480156102e457600080fd5b506102d66102f3366004610c86565b610746565b34801561030457600080fd5b506005546101ae9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561033157600080fd5b50610345610340366004610c86565b6107ce565b6040516101789493929190610cda565b34801561036157600080fd5b506102b560035481565b34801561037757600080fd5b50600254610208906bffffffffffffffffffffffff1681565b6040805160018082528183019092526060916000919060208083019080368337019050509050826040516020016103fe918152604060208201819052600a908201527f6e6f742072616e646f6d00000000000000000000000000000000000000000000606082015260800190565b6040516020818303038152906040528051906020012060001c8160008151811061042a5761042a610e37565b602090810291909101015292915050565b6000610446336108f9565b92915050565b60045473ffffffffffffffffffffffffffffffffffffffff1633146104c557600480546040517ff5828f73000000000000000000000000000000000000000000000000000000008152339281019290925273ffffffffffffffffffffffffffffffffffffffff1660248201526044015b60405180910390fd5b60006104d382840184610bc3565b9050806000015160ff166001146105255780516040517f8df4607c00000000000000000000000000000000000000000000000000000000815260ff9091166004820152600160248201526044016104bc565b8060a001516bffffffffffffffffffffffff16341461058c5760a08101516040517f6acf13500000000000000000000000000000000000000000000000000000000081523460048201526bffffffffffffffffffffffff90911660248201526044016104bc565b60408051608080820183528383015173ffffffffffffffffffffffffffffffffffffffff90811683526060808601516020808601918252938701516bffffffffffffffffffffffff9081168688015260a0880151169185019190915282860151600090815280845294909420835181547fffffffffffffffffffffffff00000000000000000000000000000000000000001692169190911781559251805192939261063d9260018501920190610965565b506040820151600291820180546060909401516bffffffffffffffffffffffff9283167fffffffffffffffff000000000000000000000000000000000000000000000000909516949094176c01000000000000000000000000948316850217905560a084015182549093600c926106b8928692900416610dd8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508060800151600260008282829054906101000a90046bffffffffffffffffffffffff166107139190610dd8565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550505050565b60008181526001602052604090205473ffffffffffffffffffffffffffffffffffffffff1680631fe543e38361077b81610390565b6040518363ffffffff1660e01b8152600401610798929190610d76565b600060405180830381600087803b1580156107b257600080fd5b505af11580156107c6573d6000803e3d6000fd5b505050505050565b6000818152602081905260408120546060908290819073ffffffffffffffffffffffffffffffffffffffff16610830576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008581526020818152604091829020805460028201546001909201805485518186028101860190965280865273ffffffffffffffffffffffffffffffffffffffff9092169490936bffffffffffffffffffffffff808516946c010000000000000000000000009004169285918301828280156108e357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116108b8575b5050505050925093509350935093509193509193565b6000600354600161090a9190610dc0565b6003819055600081815260016020526040902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff94909416939093179092555090565b8280548282559060005260206000209081019282156109df579160200282015b828111156109df57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190610985565b506109eb9291506109ef565b5090565b5b808211156109eb57600081556001016109f0565b803573ffffffffffffffffffffffffffffffffffffffff81168114610a2857600080fd5b919050565b600082601f830112610a3e57600080fd5b8135602067ffffffffffffffff80831115610a5b57610a5b610e66565b8260051b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f83011681018181108482111715610a9e57610a9e610e66565b60405284815283810192508684018288018501891015610abd57600080fd5b600092505b85831015610ae757610ad381610a04565b845292840192600192909201918401610ac2565b50979650505050505050565b80356bffffffffffffffffffffffff81168114610a2857600080fd5b60008060208385031215610b2257600080fd5b823567ffffffffffffffff80821115610b3a57600080fd5b818501915085601f830112610b4e57600080fd5b813581811115610b5d57600080fd5b866020828501011115610b6f57600080fd5b60209290920196919550909350505050565b600060208284031215610b9357600080fd5b813567ffffffffffffffff811115610baa57600080fd5b820160c08185031215610bbc57600080fd5b9392505050565b600060208284031215610bd557600080fd5b813567ffffffffffffffff80821115610bed57600080fd5b9083019060c08286031215610c0157600080fd5b610c09610d97565b823560ff81168114610c1a57600080fd5b815260208381013590820152610c3260408401610a04565b6040820152606083013582811115610c4957600080fd5b610c5587828601610a2d565b606083015250610c6760808401610af3565b6080820152610c7860a08401610af3565b60a082015295945050505050565b600060208284031215610c9857600080fd5b5035919050565b600081518084526020808501945080840160005b83811015610ccf57815187529582019590820190600101610cb3565b509495945050505050565b60006080820173ffffffffffffffffffffffffffffffffffffffff8088168452602060808186015282885180855260a087019150828a01945060005b81811015610d34578551851683529483019491830191600101610d16565b50506bffffffffffffffffffffffff978816604087015295909616606090940193909352509195945050505050565b602081526000610bbc6020830184610c9f565b828152604060208201526000610d8f6040830184610c9f565b949350505050565b60405160c0810167ffffffffffffffff81118282101715610dba57610dba610e66565b60405290565b60008219821115610dd357610dd3610e08565b500190565b60006bffffffffffffffffffffffff808316818516808303821115610dff57610dff610e08565b01949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var VRFCoordinatorV2PlusV2ExampleABI = VRFCoordinatorV2PlusV2ExampleMetaData.ABI + +var VRFCoordinatorV2PlusV2ExampleBin = VRFCoordinatorV2PlusV2ExampleMetaData.Bin + +func DeployVRFCoordinatorV2PlusV2Example(auth *bind.TransactOpts, backend bind.ContractBackend, link common.Address, prevCoordinator common.Address) (common.Address, *types.Transaction, *VRFCoordinatorV2PlusV2Example, error) { + parsed, err := VRFCoordinatorV2PlusV2ExampleMetaData.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(VRFCoordinatorV2PlusV2ExampleBin), backend, link, prevCoordinator) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &VRFCoordinatorV2PlusV2Example{VRFCoordinatorV2PlusV2ExampleCaller: VRFCoordinatorV2PlusV2ExampleCaller{contract: contract}, VRFCoordinatorV2PlusV2ExampleTransactor: VRFCoordinatorV2PlusV2ExampleTransactor{contract: contract}, VRFCoordinatorV2PlusV2ExampleFilterer: VRFCoordinatorV2PlusV2ExampleFilterer{contract: contract}}, nil +} + +type VRFCoordinatorV2PlusV2Example struct { + address common.Address + abi abi.ABI + VRFCoordinatorV2PlusV2ExampleCaller + VRFCoordinatorV2PlusV2ExampleTransactor + VRFCoordinatorV2PlusV2ExampleFilterer +} + +type VRFCoordinatorV2PlusV2ExampleCaller struct { + contract *bind.BoundContract +} + +type VRFCoordinatorV2PlusV2ExampleTransactor struct { + contract *bind.BoundContract +} + +type VRFCoordinatorV2PlusV2ExampleFilterer struct { + contract *bind.BoundContract +} + +type VRFCoordinatorV2PlusV2ExampleSession struct { + Contract *VRFCoordinatorV2PlusV2Example + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type VRFCoordinatorV2PlusV2ExampleCallerSession struct { + Contract *VRFCoordinatorV2PlusV2ExampleCaller + CallOpts bind.CallOpts +} + +type VRFCoordinatorV2PlusV2ExampleTransactorSession struct { + Contract *VRFCoordinatorV2PlusV2ExampleTransactor + TransactOpts bind.TransactOpts +} + +type VRFCoordinatorV2PlusV2ExampleRaw struct { + Contract *VRFCoordinatorV2PlusV2Example +} + +type VRFCoordinatorV2PlusV2ExampleCallerRaw struct { + Contract *VRFCoordinatorV2PlusV2ExampleCaller +} + +type VRFCoordinatorV2PlusV2ExampleTransactorRaw struct { + Contract *VRFCoordinatorV2PlusV2ExampleTransactor +} + +func NewVRFCoordinatorV2PlusV2Example(address common.Address, backend bind.ContractBackend) (*VRFCoordinatorV2PlusV2Example, error) { + abi, err := abi.JSON(strings.NewReader(VRFCoordinatorV2PlusV2ExampleABI)) + if err != nil { + return nil, err + } + contract, err := bindVRFCoordinatorV2PlusV2Example(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &VRFCoordinatorV2PlusV2Example{address: address, abi: abi, VRFCoordinatorV2PlusV2ExampleCaller: VRFCoordinatorV2PlusV2ExampleCaller{contract: contract}, VRFCoordinatorV2PlusV2ExampleTransactor: VRFCoordinatorV2PlusV2ExampleTransactor{contract: contract}, VRFCoordinatorV2PlusV2ExampleFilterer: VRFCoordinatorV2PlusV2ExampleFilterer{contract: contract}}, nil +} + +func NewVRFCoordinatorV2PlusV2ExampleCaller(address common.Address, caller bind.ContractCaller) (*VRFCoordinatorV2PlusV2ExampleCaller, error) { + contract, err := bindVRFCoordinatorV2PlusV2Example(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &VRFCoordinatorV2PlusV2ExampleCaller{contract: contract}, nil +} + +func NewVRFCoordinatorV2PlusV2ExampleTransactor(address common.Address, transactor bind.ContractTransactor) (*VRFCoordinatorV2PlusV2ExampleTransactor, error) { + contract, err := bindVRFCoordinatorV2PlusV2Example(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &VRFCoordinatorV2PlusV2ExampleTransactor{contract: contract}, nil +} + +func NewVRFCoordinatorV2PlusV2ExampleFilterer(address common.Address, filterer bind.ContractFilterer) (*VRFCoordinatorV2PlusV2ExampleFilterer, error) { + contract, err := bindVRFCoordinatorV2PlusV2Example(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &VRFCoordinatorV2PlusV2ExampleFilterer{contract: contract}, nil +} + +func bindVRFCoordinatorV2PlusV2Example(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := VRFCoordinatorV2PlusV2ExampleMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VRFCoordinatorV2PlusV2Example.Contract.VRFCoordinatorV2PlusV2ExampleCaller.contract.Call(opts, result, method, params...) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.VRFCoordinatorV2PlusV2ExampleTransactor.contract.Transfer(opts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.VRFCoordinatorV2PlusV2ExampleTransactor.contract.Transact(opts, method, params...) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VRFCoordinatorV2PlusV2Example.Contract.contract.Call(opts, result, method, params...) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.contract.Transfer(opts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.contract.Transact(opts, method, params...) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) GenerateFakeRandomness(opts *bind.CallOpts, requestID *big.Int) ([]*big.Int, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "generateFakeRandomness", requestID) + + if err != nil { + return *new([]*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) GenerateFakeRandomness(requestID *big.Int) ([]*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.GenerateFakeRandomness(&_VRFCoordinatorV2PlusV2Example.CallOpts, requestID) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) GenerateFakeRandomness(requestID *big.Int) ([]*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.GenerateFakeRandomness(&_VRFCoordinatorV2PlusV2Example.CallOpts, requestID) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) GetSubscription(opts *bind.CallOpts, subId *big.Int) (GetSubscription, + + error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "getSubscription", subId) + + outstruct := new(GetSubscription) + if err != nil { + return *outstruct, err + } + + outstruct.Owner = *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + outstruct.Consumers = *abi.ConvertType(out[1], new([]common.Address)).(*[]common.Address) + outstruct.LinkBalance = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) + outstruct.NativeBalance = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) GetSubscription(subId *big.Int) (GetSubscription, + + error) { + return _VRFCoordinatorV2PlusV2Example.Contract.GetSubscription(&_VRFCoordinatorV2PlusV2Example.CallOpts, subId) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) GetSubscription(subId *big.Int) (GetSubscription, + + error) { + return _VRFCoordinatorV2PlusV2Example.Contract.GetSubscription(&_VRFCoordinatorV2PlusV2Example.CallOpts, subId) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) SLink(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_link") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) SLink() (common.Address, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SLink(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) SLink() (common.Address, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SLink(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) SPrevCoordinator(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_prevCoordinator") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) SPrevCoordinator() (common.Address, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SPrevCoordinator(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) SPrevCoordinator() (common.Address, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SPrevCoordinator(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) SRequestConsumerMapping(opts *bind.CallOpts, arg0 *big.Int) (common.Address, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_requestConsumerMapping", arg0) + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) SRequestConsumerMapping(arg0 *big.Int) (common.Address, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SRequestConsumerMapping(&_VRFCoordinatorV2PlusV2Example.CallOpts, arg0) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) SRequestConsumerMapping(arg0 *big.Int) (common.Address, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SRequestConsumerMapping(&_VRFCoordinatorV2PlusV2Example.CallOpts, arg0) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) SRequestId(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_requestId") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) SRequestId() (*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SRequestId(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) SRequestId() (*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SRequestId(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) SSubscriptions(opts *bind.CallOpts, arg0 *big.Int) (SSubscriptions, + + error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_subscriptions", arg0) + + outstruct := new(SSubscriptions) + if err != nil { + return *outstruct, err + } + + outstruct.Owner = *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + outstruct.LinkBalance = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + outstruct.NativeBalance = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) SSubscriptions(arg0 *big.Int) (SSubscriptions, + + error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SSubscriptions(&_VRFCoordinatorV2PlusV2Example.CallOpts, arg0) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) SSubscriptions(arg0 *big.Int) (SSubscriptions, + + error) { + return _VRFCoordinatorV2PlusV2Example.Contract.SSubscriptions(&_VRFCoordinatorV2PlusV2Example.CallOpts, arg0) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) STotalLinkBalance(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_totalLinkBalance") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) STotalLinkBalance() (*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.STotalLinkBalance(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) STotalLinkBalance() (*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.STotalLinkBalance(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCaller) STotalNativeBalance(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFCoordinatorV2PlusV2Example.contract.Call(opts, &out, "s_totalNativeBalance") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) STotalNativeBalance() (*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.STotalNativeBalance(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleCallerSession) STotalNativeBalance() (*big.Int, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.STotalNativeBalance(&_VRFCoordinatorV2PlusV2Example.CallOpts) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactor) FulfillRandomWords(opts *bind.TransactOpts, requestId *big.Int) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.contract.Transact(opts, "fulfillRandomWords", requestId) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) FulfillRandomWords(requestId *big.Int) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.FulfillRandomWords(&_VRFCoordinatorV2PlusV2Example.TransactOpts, requestId) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactorSession) FulfillRandomWords(requestId *big.Int) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.FulfillRandomWords(&_VRFCoordinatorV2PlusV2Example.TransactOpts, requestId) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactor) OnMigration(opts *bind.TransactOpts, encodedData []byte) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.contract.Transact(opts, "onMigration", encodedData) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) OnMigration(encodedData []byte) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.OnMigration(&_VRFCoordinatorV2PlusV2Example.TransactOpts, encodedData) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactorSession) OnMigration(encodedData []byte) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.OnMigration(&_VRFCoordinatorV2PlusV2Example.TransactOpts, encodedData) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactor) RequestRandomWords(opts *bind.TransactOpts, arg0 VRFV2PlusClientRandomWordsRequest) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.contract.Transact(opts, "requestRandomWords", arg0) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleSession) RequestRandomWords(arg0 VRFV2PlusClientRandomWordsRequest) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.RequestRandomWords(&_VRFCoordinatorV2PlusV2Example.TransactOpts, arg0) +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2ExampleTransactorSession) RequestRandomWords(arg0 VRFV2PlusClientRandomWordsRequest) (*types.Transaction, error) { + return _VRFCoordinatorV2PlusV2Example.Contract.RequestRandomWords(&_VRFCoordinatorV2PlusV2Example.TransactOpts, arg0) +} + +type GetSubscription struct { + Owner common.Address + Consumers []common.Address + LinkBalance *big.Int + NativeBalance *big.Int +} +type SSubscriptions struct { + Owner common.Address + LinkBalance *big.Int + NativeBalance *big.Int +} + +func (_VRFCoordinatorV2PlusV2Example *VRFCoordinatorV2PlusV2Example) Address() common.Address { + return _VRFCoordinatorV2PlusV2Example.address +} + +type VRFCoordinatorV2PlusV2ExampleInterface interface { + GenerateFakeRandomness(opts *bind.CallOpts, requestID *big.Int) ([]*big.Int, error) + + GetSubscription(opts *bind.CallOpts, subId *big.Int) (GetSubscription, + + error) + + SLink(opts *bind.CallOpts) (common.Address, error) + + SPrevCoordinator(opts *bind.CallOpts) (common.Address, error) + + SRequestConsumerMapping(opts *bind.CallOpts, arg0 *big.Int) (common.Address, error) + + SRequestId(opts *bind.CallOpts) (*big.Int, error) + + SSubscriptions(opts *bind.CallOpts, arg0 *big.Int) (SSubscriptions, + + error) + + STotalLinkBalance(opts *bind.CallOpts) (*big.Int, error) + + STotalNativeBalance(opts *bind.CallOpts) (*big.Int, error) + + FulfillRandomWords(opts *bind.TransactOpts, requestId *big.Int) (*types.Transaction, error) + + OnMigration(opts *bind.TransactOpts, encodedData []byte) (*types.Transaction, error) + + RequestRandomWords(opts *bind.TransactOpts, arg0 VRFV2PlusClientRandomWordsRequest) (*types.Transaction, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generated/vrfv2plus_consumer_example/vrfv2plus_consumer_example.go b/core/gethwrappers/generated/vrfv2plus_consumer_example/vrfv2plus_consumer_example.go index 350dcd4315b..ce2d4fd13cc 100644 --- a/core/gethwrappers/generated/vrfv2plus_consumer_example/vrfv2plus_consumer_example.go +++ b/core/gethwrappers/generated/vrfv2plus_consumer_example/vrfv2plus_consumer_example.go @@ -31,8 +31,8 @@ var ( ) var VRFV2PlusConsumerExampleMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"vrfCoordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"have\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"want\",\"type\":\"address\"}],\"name\":\"OnlyCoordinatorCanFulfill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"have\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"}],\"name\":\"OnlyOwnerOrCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"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\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"createSubscriptionAndFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"idx\",\"type\":\"uint256\"}],\"name\":\"getRandomness\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"randomWord\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"internalType\":\"uint256[]\",\"name\":\"randomWords\",\"type\":\"uint256[]\"}],\"name\":\"rawFulfillRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"nativePayment\",\"type\":\"bool\"}],\"name\":\"requestRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_recentRequestId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requests\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"fulfilled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_subId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_vrfCoordinatorApiV1\",\"outputs\":[{\"internalType\":\"contractIVRFCoordinatorV2Plus\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_vrfCoordinator\",\"type\":\"address\"}],\"name\":\"setCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"setSubId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"topUpSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"name\":\"updateSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b506040516200169b3803806200169b8339810160408190526200003491620001cc565b8133806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf8162000103565b5050600280546001600160a01b03199081166001600160a01b0394851617909155600580548216958416959095179094555060038054909316911617905562000204565b6001600160a01b0381163314156200015e5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001c757600080fd5b919050565b60008060408385031215620001e057600080fd5b620001eb83620001af565b9150620001fb60208401620001af565b90509250929050565b61148780620002146000396000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c80638098004311610097578063cf62c8ab11610066578063cf62c8ab14610283578063de367c8e14610296578063eff27017146102b6578063f2fde38b146102c957600080fd5b806380980043146101c55780638da5cb5b146101d85780638ea98117146101f6578063a168fa891461020957600080fd5b80635d7d53e3116100d35780635d7d53e314610166578063706da1ca1461016f5780637725135b1461017857806379ba5097146101bd57600080fd5b80631fe543e31461010557806329e5d8311461011a5780632fa4e4421461014057806336bfffed14610153575b600080fd5b6101186101133660046110c0565b6102dc565b005b61012d610128366004611164565b610362565b6040519081526020015b60405180910390f35b61011861014e3660046111f1565b61049f565b610118610161366004610fcd565b610558565b61012d60045481565b61012d60065481565b6003546101989073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610137565b610118610690565b6101186101d336600461108e565b600655565b60005473ffffffffffffffffffffffffffffffffffffffff16610198565b610118610204366004610fab565b61078d565b61025161021736600461108e565b6007602052600090815260409020805460019091015460ff821691610100900473ffffffffffffffffffffffffffffffffffffffff169083565b60408051931515845273ffffffffffffffffffffffffffffffffffffffff909216602084015290820152606001610137565b6101186102913660046111f1565b610898565b6005546101989073ffffffffffffffffffffffffffffffffffffffff1681565b6101186102c4366004611186565b610a0f565b6101186102d7366004610fab565b610bfa565b60025473ffffffffffffffffffffffffffffffffffffffff163314610354576002546040517f1cf993f400000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff90911660248201526044015b60405180910390fd5b61035e8282610c0e565b5050565b60008281526007602090815260408083208151608081018352815460ff811615158252610100900473ffffffffffffffffffffffffffffffffffffffff1681850152600182015481840152600282018054845181870281018701909552808552869592946060860193909291908301828280156103fe57602002820191906000526020600020905b8154815260200190600101908083116103ea575b5050505050815250509050806040015160001415610478576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265717565737420494420697320696e636f7272656374000000000000000000604482015260640161034b565b8060600151838151811061048e5761048e61140e565b602002602001015191505092915050565b60035460025460065460408051602081019290925273ffffffffffffffffffffffffffffffffffffffff93841693634000aea09316918591015b6040516020818303038152906040526040518463ffffffff1660e01b81526004016105069392919061128a565b602060405180830381600087803b15801561052057600080fd5b505af1158015610534573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061035e9190611071565b6006546105c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f7375624944206e6f742073657400000000000000000000000000000000000000604482015260640161034b565b60005b815181101561035e57600554600654835173ffffffffffffffffffffffffffffffffffffffff9092169163bec4c08c91908590859081106106075761060761140e565b60200260200101516040518363ffffffff1660e01b815260040161064b92919091825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b15801561066557600080fd5b505af1158015610679573d6000803e3d6000fd5b505050508080610688906113ae565b9150506105c4565b60015473ffffffffffffffffffffffffffffffffffffffff163314610711576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161034b565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60005473ffffffffffffffffffffffffffffffffffffffff1633148015906107cd575060025473ffffffffffffffffffffffffffffffffffffffff163314155b1561085157336107f260005473ffffffffffffffffffffffffffffffffffffffff1690565b6002546040517f061db9c100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9384166004820152918316602483015291909116604482015260640161034b565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b60065461049f57600560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a21a23e46040518163ffffffff1660e01b8152600401602060405180830381600087803b15801561090957600080fd5b505af115801561091d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061094191906110a7565b60068190556005546040517fbec4c08c000000000000000000000000000000000000000000000000000000008152600481019290925230602483015273ffffffffffffffffffffffffffffffffffffffff169063bec4c08c90604401600060405180830381600087803b1580156109b757600080fd5b505af11580156109cb573d6000803e3d6000fd5b5050505060035460025460065460405173ffffffffffffffffffffffffffffffffffffffff93841693634000aea093169185916104d9919060200190815260200190565b60006040518060c0016040528084815260200160065481526020018661ffff1681526020018763ffffffff1681526020018563ffffffff168152602001610a656040518060200160405280861515815250610cd9565b90526002546040517f9b1c385e00000000000000000000000000000000000000000000000000000000815291925060009173ffffffffffffffffffffffffffffffffffffffff90911690639b1c385e90610ac39085906004016112d6565b602060405180830381600087803b158015610add57600080fd5b505af1158015610af1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b1591906110a7565b604080516080810182526000808252336020808401918252838501868152855184815280830187526060860190815287855260078352959093208451815493517fffffffffffffffffffffff0000000000000000000000000000000000000000009094169015157fffffffffffffffffffffff0000000000000000000000000000000000000000ff161761010073ffffffffffffffffffffffffffffffffffffffff9094169390930292909217825591516001820155925180519495509193849392610be8926002850192910190610f0e565b50505060049190915550505050505050565b610c02610d95565b610c0b81610e18565b50565b6004548214610c79576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265717565737420494420697320696e636f7272656374000000000000000000604482015260640161034b565b60008281526007602090815260409091208251610c9e92600290920191840190610f0e565b5050600090815260076020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401610d1291511515815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915292915050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610e16576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161034b565b565b73ffffffffffffffffffffffffffffffffffffffff8116331415610e98576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161034b565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215610f49579160200282015b82811115610f49578251825591602001919060010190610f2e565b50610f55929150610f59565b5090565b5b80821115610f555760008155600101610f5a565b803573ffffffffffffffffffffffffffffffffffffffff81168114610f9257600080fd5b919050565b803563ffffffff81168114610f9257600080fd5b600060208284031215610fbd57600080fd5b610fc682610f6e565b9392505050565b60006020808385031215610fe057600080fd5b823567ffffffffffffffff811115610ff757600080fd5b8301601f8101851361100857600080fd5b803561101b6110168261138a565b61133b565b80828252848201915084840188868560051b870101111561103b57600080fd5b600094505b838510156110655761105181610f6e565b835260019490940193918501918501611040565b50979650505050505050565b60006020828403121561108357600080fd5b8151610fc68161146c565b6000602082840312156110a057600080fd5b5035919050565b6000602082840312156110b957600080fd5b5051919050565b600080604083850312156110d357600080fd5b8235915060208084013567ffffffffffffffff8111156110f257600080fd5b8401601f8101861361110357600080fd5b80356111116110168261138a565b80828252848201915084840189868560051b870101111561113157600080fd5b600094505b83851015611154578035835260019490940193918501918501611136565b5080955050505050509250929050565b6000806040838503121561117757600080fd5b50508035926020909101359150565b600080600080600060a0868803121561119e57600080fd5b6111a786610f97565b9450602086013561ffff811681146111be57600080fd5b93506111cc60408701610f97565b92506060860135915060808601356111e38161146c565b809150509295509295909350565b60006020828403121561120357600080fd5b81356bffffffffffffffffffffffff81168114610fc657600080fd5b6000815180845260005b8181101561124557602081850181015186830182015201611229565b81811115611257576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff831660208201526060604082015260006112cd606083018461121f565b95945050505050565b60208152815160208201526020820151604082015261ffff60408301511660608201526000606083015163ffffffff80821660808501528060808601511660a0850152505060a083015160c08084015261133360e084018261121f565b949350505050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156113825761138261143d565b604052919050565b600067ffffffffffffffff8211156113a4576113a461143d565b5060051b60200190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415611407577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b8015158114610c0b57600080fdfea164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"vrfCoordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"have\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"want\",\"type\":\"address\"}],\"name\":\"OnlyCoordinatorCanFulfill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"have\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"}],\"name\":\"OnlyOwnerOrCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"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\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"createSubscriptionAndFund\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscriptionAndFundNative\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"idx\",\"type\":\"uint256\"}],\"name\":\"getRandomness\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"randomWord\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"internalType\":\"uint256[]\",\"name\":\"randomWords\",\"type\":\"uint256[]\"}],\"name\":\"rawFulfillRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"nativePayment\",\"type\":\"bool\"}],\"name\":\"requestRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_linkToken\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_recentRequestId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requests\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"fulfilled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_subId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_vrfCoordinatorApiV1\",\"outputs\":[{\"internalType\":\"contractIVRFCoordinatorV2Plus\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_vrfCoordinator\",\"type\":\"address\"}],\"name\":\"setCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"setSubId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"topUpSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"topUpSubscriptionNative\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"name\":\"updateSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60806040523480156200001157600080fd5b506040516200197e3803806200197e8339810160408190526200003491620001cc565b8133806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf8162000103565b5050600280546001600160a01b03199081166001600160a01b0394851617909155600580548216958416959095179094555060038054909316911617905562000204565b6001600160a01b0381163314156200015e5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001c757600080fd5b919050565b60008060408385031215620001e057600080fd5b620001eb83620001af565b9150620001fb60208401620001af565b90509250929050565b61176a80620002146000396000f3fe6080604052600436106101295760003560e01c806380980043116100a5578063b96dbba711610074578063de367c8e11610059578063de367c8e14610378578063eff27017146103a5578063f2fde38b146103c557600080fd5b8063b96dbba714610350578063cf62c8ab1461035857600080fd5b8063809800431461025e5780638da5cb5b1461027e5780638ea98117146102a9578063a168fa89146102c957600080fd5b806336bfffed116100fc578063706da1ca116100e1578063706da1ca146101e15780637725135b146101f757806379ba50971461024957600080fd5b806336bfffed146101ab5780635d7d53e3146101cb57600080fd5b80631d2b2afd1461012e5780631fe543e31461013857806329e5d831146101585780632fa4e4421461018b575b600080fd5b6101366103e5565b005b34801561014457600080fd5b506101366101533660046113a3565b6104e0565b34801561016457600080fd5b50610178610173366004611447565b610561565b6040519081526020015b60405180910390f35b34801561019757600080fd5b506101366101a63660046114d4565b61069e565b3480156101b757600080fd5b506101366101c63660046112b0565b6107c0565b3480156101d757600080fd5b5061017860045481565b3480156101ed57600080fd5b5061017860065481565b34801561020357600080fd5b506003546102249073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610182565b34801561025557600080fd5b506101366108f8565b34801561026a57600080fd5b50610136610279366004611371565b600655565b34801561028a57600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff16610224565b3480156102b557600080fd5b506101366102c436600461128e565b6109f5565b3480156102d557600080fd5b5061031e6102e4366004611371565b6007602052600090815260409020805460019091015460ff821691610100900473ffffffffffffffffffffffffffffffffffffffff169083565b60408051931515845273ffffffffffffffffffffffffffffffffffffffff909216602084015290820152606001610182565b610136610b00565b34801561036457600080fd5b506101366103733660046114d4565b610b66565b34801561038457600080fd5b506005546102249073ffffffffffffffffffffffffffffffffffffffff1681565b3480156103b157600080fd5b506101366103c0366004611469565b610bad565b3480156103d157600080fd5b506101366103e036600461128e565b610d98565b600654610453576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600b60248201527f737562206e6f742073657400000000000000000000000000000000000000000060448201526064015b60405180910390fd5b6005546006546040517fe8509bff000000000000000000000000000000000000000000000000000000008152600481019190915273ffffffffffffffffffffffffffffffffffffffff9091169063e8509bff9034906024015b6000604051808303818588803b1580156104c557600080fd5b505af11580156104d9573d6000803e3d6000fd5b5050505050565b60025473ffffffffffffffffffffffffffffffffffffffff163314610553576002546040517f1cf993f400000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff909116602482015260440161044a565b61055d8282610dac565b5050565b60008281526007602090815260408083208151608081018352815460ff811615158252610100900473ffffffffffffffffffffffffffffffffffffffff1681850152600182015481840152600282018054845181870281018701909552808552869592946060860193909291908301828280156105fd57602002820191906000526020600020905b8154815260200190600101908083116105e9575b5050505050815250509050806040015160001415610677576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265717565737420494420697320696e636f7272656374000000000000000000604482015260640161044a565b8060600151838151811061068d5761068d6116f1565b602002602001015191505092915050565b600654610707576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600b60248201527f737562206e6f7420736574000000000000000000000000000000000000000000604482015260640161044a565b60035460025460065460408051602081019290925273ffffffffffffffffffffffffffffffffffffffff93841693634000aea09316918591015b6040516020818303038152906040526040518463ffffffff1660e01b815260040161076e9392919061156d565b602060405180830381600087803b15801561078857600080fd5b505af115801561079c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061055d9190611354565b600654610829576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152600d60248201527f7375624944206e6f742073657400000000000000000000000000000000000000604482015260640161044a565b60005b815181101561055d57600554600654835173ffffffffffffffffffffffffffffffffffffffff9092169163bec4c08c919085908590811061086f5761086f6116f1565b60200260200101516040518363ffffffff1660e01b81526004016108b392919091825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b1580156108cd57600080fd5b505af11580156108e1573d6000803e3d6000fd5b5050505080806108f090611691565b91505061082c565b60015473ffffffffffffffffffffffffffffffffffffffff163314610979576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161044a565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610a35575060025473ffffffffffffffffffffffffffffffffffffffff163314155b15610ab95733610a5a60005473ffffffffffffffffffffffffffffffffffffffff1690565b6002546040517f061db9c100000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9384166004820152918316602483015291909116604482015260640161044a565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92909216919091179055565b610b08610e77565b506005546006546040517fe8509bff000000000000000000000000000000000000000000000000000000008152600481019190915273ffffffffffffffffffffffffffffffffffffffff9091169063e8509bff9034906024016104ac565b610b6e610e77565b5060035460025460065460408051602081019290925273ffffffffffffffffffffffffffffffffffffffff93841693634000aea0931691859101610741565b60006040518060c0016040528084815260200160065481526020018661ffff1681526020018763ffffffff1681526020018563ffffffff168152602001610c036040518060200160405280861515815250610fbc565b90526002546040517f9b1c385e00000000000000000000000000000000000000000000000000000000815291925060009173ffffffffffffffffffffffffffffffffffffffff90911690639b1c385e90610c619085906004016115b9565b602060405180830381600087803b158015610c7b57600080fd5b505af1158015610c8f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cb3919061138a565b604080516080810182526000808252336020808401918252838501868152855184815280830187526060860190815287855260078352959093208451815493517fffffffffffffffffffffff0000000000000000000000000000000000000000009094169015157fffffffffffffffffffffff0000000000000000000000000000000000000000ff161761010073ffffffffffffffffffffffffffffffffffffffff9094169390930292909217825591516001820155925180519495509193849392610d869260028501929101906111f1565b50505060049190915550505050505050565b610da0611078565b610da9816110fb565b50565b6004548214610e17576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265717565737420494420697320696e636f7272656374000000000000000000604482015260640161044a565b60008281526007602090815260409091208251610e3c926002909201918401906111f1565b5050600090815260076020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b600060065460001415610fb557600560009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663a21a23e46040518163ffffffff1660e01b8152600401602060405180830381600087803b158015610eee57600080fd5b505af1158015610f02573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f26919061138a565b60068190556005546040517fbec4c08c000000000000000000000000000000000000000000000000000000008152600481019290925230602483015273ffffffffffffffffffffffffffffffffffffffff169063bec4c08c90604401600060405180830381600087803b158015610f9c57600080fd5b505af1158015610fb0573d6000803e3d6000fd5b505050505b5060065490565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401610ff591511515815260200190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915292915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146110f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161044a565b565b73ffffffffffffffffffffffffffffffffffffffff811633141561117b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161044a565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b82805482825590600052602060002090810192821561122c579160200282015b8281111561122c578251825591602001919060010190611211565b5061123892915061123c565b5090565b5b80821115611238576000815560010161123d565b803573ffffffffffffffffffffffffffffffffffffffff8116811461127557600080fd5b919050565b803563ffffffff8116811461127557600080fd5b6000602082840312156112a057600080fd5b6112a982611251565b9392505050565b600060208083850312156112c357600080fd5b823567ffffffffffffffff8111156112da57600080fd5b8301601f810185136112eb57600080fd5b80356112fe6112f98261166d565b61161e565b80828252848201915084840188868560051b870101111561131e57600080fd5b600094505b838510156113485761133481611251565b835260019490940193918501918501611323565b50979650505050505050565b60006020828403121561136657600080fd5b81516112a98161174f565b60006020828403121561138357600080fd5b5035919050565b60006020828403121561139c57600080fd5b5051919050565b600080604083850312156113b657600080fd5b8235915060208084013567ffffffffffffffff8111156113d557600080fd5b8401601f810186136113e657600080fd5b80356113f46112f98261166d565b80828252848201915084840189868560051b870101111561141457600080fd5b600094505b83851015611437578035835260019490940193918501918501611419565b5080955050505050509250929050565b6000806040838503121561145a57600080fd5b50508035926020909101359150565b600080600080600060a0868803121561148157600080fd5b61148a8661127a565b9450602086013561ffff811681146114a157600080fd5b93506114af6040870161127a565b92506060860135915060808601356114c68161174f565b809150509295509295909350565b6000602082840312156114e657600080fd5b81356bffffffffffffffffffffffff811681146112a957600080fd5b6000815180845260005b818110156115285760208185018101518683018201520161150c565b8181111561153a576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b73ffffffffffffffffffffffffffffffffffffffff841681526bffffffffffffffffffffffff831660208201526060604082015260006115b06060830184611502565b95945050505050565b60208152815160208201526020820151604082015261ffff60408301511660608201526000606083015163ffffffff80821660808501528060808601511660a0850152505060a083015160c08084015261161660e0840182611502565b949350505050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561166557611665611720565b604052919050565b600067ffffffffffffffff82111561168757611687611720565b5060051b60200190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156116ea577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b8015158114610da957600080fdfea164736f6c6343000806000a", } var VRFV2PlusConsumerExampleABI = VRFV2PlusConsumerExampleMetaData.ABI @@ -358,6 +358,18 @@ func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactorSession) Crea return _VRFV2PlusConsumerExample.Contract.CreateSubscriptionAndFund(&_VRFV2PlusConsumerExample.TransactOpts, amount) } +func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactor) CreateSubscriptionAndFundNative(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFV2PlusConsumerExample.contract.Transact(opts, "createSubscriptionAndFundNative") +} + +func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleSession) CreateSubscriptionAndFundNative() (*types.Transaction, error) { + return _VRFV2PlusConsumerExample.Contract.CreateSubscriptionAndFundNative(&_VRFV2PlusConsumerExample.TransactOpts) +} + +func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactorSession) CreateSubscriptionAndFundNative() (*types.Transaction, error) { + return _VRFV2PlusConsumerExample.Contract.CreateSubscriptionAndFundNative(&_VRFV2PlusConsumerExample.TransactOpts) +} + func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactor) RawFulfillRandomWords(opts *bind.TransactOpts, requestId *big.Int, randomWords []*big.Int) (*types.Transaction, error) { return _VRFV2PlusConsumerExample.contract.Transact(opts, "rawFulfillRandomWords", requestId, randomWords) } @@ -418,6 +430,18 @@ func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactorSession) TopU return _VRFV2PlusConsumerExample.Contract.TopUpSubscription(&_VRFV2PlusConsumerExample.TransactOpts, amount) } +func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactor) TopUpSubscriptionNative(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFV2PlusConsumerExample.contract.Transact(opts, "topUpSubscriptionNative") +} + +func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleSession) TopUpSubscriptionNative() (*types.Transaction, error) { + return _VRFV2PlusConsumerExample.Contract.TopUpSubscriptionNative(&_VRFV2PlusConsumerExample.TransactOpts) +} + +func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactorSession) TopUpSubscriptionNative() (*types.Transaction, error) { + return _VRFV2PlusConsumerExample.Contract.TopUpSubscriptionNative(&_VRFV2PlusConsumerExample.TransactOpts) +} + func (_VRFV2PlusConsumerExample *VRFV2PlusConsumerExampleTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _VRFV2PlusConsumerExample.contract.Transact(opts, "transferOwnership", to) } @@ -765,6 +789,8 @@ type VRFV2PlusConsumerExampleInterface interface { CreateSubscriptionAndFund(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + CreateSubscriptionAndFundNative(opts *bind.TransactOpts) (*types.Transaction, error) + RawFulfillRandomWords(opts *bind.TransactOpts, requestId *big.Int, randomWords []*big.Int) (*types.Transaction, error) RequestRandomWords(opts *bind.TransactOpts, callbackGasLimit uint32, requestConfirmations uint16, numWords uint32, keyHash [32]byte, nativePayment bool) (*types.Transaction, error) @@ -775,6 +801,8 @@ type VRFV2PlusConsumerExampleInterface interface { TopUpSubscription(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + TopUpSubscriptionNative(opts *bind.TransactOpts) (*types.Transaction, error) + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) UpdateSubscription(opts *bind.TransactOpts, consumers []common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 57f772b9797..2289abb182a 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -73,6 +73,7 @@ vrf_consumer_v2_plus_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsume vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2UpgradeableExample.bin f1790a9a2f2a04c730593e483459709cb89e897f8a19d7a3ac0cfe6a97265e6e vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b +vrf_coordinator_v2_plus_v2_example: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.bin 02d0ec25e4f3d72f818e7ebc2b5f5949a94889ab0da091f0d3e7f5e4a20a0bb6 vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 109aa4e3d3ca95738d8da15aefc2bf8b09b8f90204ef1a1176ca2d0a8ffe9a9a vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d @@ -92,7 +93,7 @@ vrfv2_wrapper: ../../contracts/solc/v0.8.6/VRFV2Wrapper.abi ../../contracts/solc vrfv2_wrapper_consumer_example: ../../contracts/solc/v0.8.6/VRFV2WrapperConsumerExample.abi ../../contracts/solc/v0.8.6/VRFV2WrapperConsumerExample.bin 3c5c9f1c501e697a7e77e959b48767e2a0bb1372393fd7686f7aaef3eb794231 vrfv2_wrapper_interface: ../../contracts/solc/v0.8.6/VRFV2WrapperInterface.abi ../../contracts/solc/v0.8.6/VRFV2WrapperInterface.bin ff8560169de171a68b360b7438d13863682d07040d984fd0fb096b2379421003 vrfv2plus_client: ../../contracts/solc/v0.8.6/VRFV2PlusClient.abi ../../contracts/solc/v0.8.6/VRFV2PlusClient.bin 3ffbfa4971a7e5f46051a26b1722613f265d89ea1867547ecec58500953a9501 -vrfv2plus_consumer_example: ../../contracts/solc/v0.8.6/VRFV2PlusConsumerExample.abi ../../contracts/solc/v0.8.6/VRFV2PlusConsumerExample.bin 54a54bd8760e6fa8c6e7ff05c0a7fc883c0b55f5d711d4b5a6cd5b48a51e0bdd +vrfv2plus_consumer_example: ../../contracts/solc/v0.8.6/VRFV2PlusConsumerExample.abi ../../contracts/solc/v0.8.6/VRFV2PlusConsumerExample.bin 5cfc2977029d558dc6363a5d4953bb165d94932d248ea003dbb7ebf4b8b938bf vrfv2plus_reverting_example: ../../contracts/solc/v0.8.6/VRFV2PlusRevertingExample.abi ../../contracts/solc/v0.8.6/VRFV2PlusRevertingExample.bin 93e8af756ad31107224560baf3472445af56300a7ad11cb8304c77707a73e082 vrfv2plus_wrapper: ../../contracts/solc/v0.8.6/VRFV2PlusWrapper.abi ../../contracts/solc/v0.8.6/VRFV2PlusWrapper.bin 06f705f62d5f94c8315dbd680c1eb9ad0e650bfa0292de8eb5757b2fd21edb04 vrfv2plus_wrapper_consumer_example: ../../contracts/solc/v0.8.6/VRFV2PlusWrapperConsumerExample.abi ../../contracts/solc/v0.8.6/VRFV2PlusWrapperConsumerExample.bin d4ddf86da21b87c013f551b2563ab68712ea9d4724894664d5778f6b124f4e78 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 82b304f26bb..b7e31a9281a 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -112,6 +112,7 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFV2PlusRevertingExample.abi ../../contracts/solc/v0.8.6/VRFV2PlusRevertingExample.bin VRFV2PlusRevertingExample vrfv2plus_reverting_example //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.abi ../../contracts/solc/v0.8.6/VRFConsumerV2PlusUpgradeableExample.bin VRFConsumerV2PlusUpgradeableExample vrf_consumer_v2_plus_upgradeable_example //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFV2PlusClient.abi ../../contracts/solc/v0.8.6/VRFV2PlusClient.bin VRFV2PlusClient vrfv2plus_client +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.bin VRFCoordinatorV2Plus_V2Example vrf_coordinator_v2_plus_v2_example // Aggregators //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/AggregatorV2V3Interface.abi ../../contracts/solc/v0.8.6/AggregatorV2V3Interface.bin AggregatorV2V3Interface aggregator_v2v3_interface diff --git a/core/services/blockhashstore/feeder_test.go b/core/services/blockhashstore/feeder_test.go index c6f8c1f4302..1205f09e3a6 100644 --- a/core/services/blockhashstore/feeder_test.go +++ b/core/services/blockhashstore/feeder_test.go @@ -19,12 +19,15 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/solidity_vrf_coordinator_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/logger" ) const ( // VRF-only events. + randomWordsRequestedV2Plus string = "RandomWordsRequested" + randomWordsFulfilledV2Plus string = "RandomWordsFulfilled" randomWordsRequestedV2 string = "RandomWordsRequested" randomWordsFulfilledV2 string = "RandomWordsFulfilled" randomWordsRequestedV1 string = "RandomnessRequest" @@ -36,8 +39,9 @@ const ( ) var ( - vrfCoordinatorV2ABI = evmtypes.MustGetABI(vrf_coordinator_v2.VRFCoordinatorV2MetaData.ABI) - vrfCoordinatorV1ABI = evmtypes.MustGetABI(solidity_vrf_coordinator_interface.VRFCoordinatorMetaData.ABI) + vrfCoordinatorV2PlusABI = evmtypes.MustGetABI(vrf_coordinator_v2plus.VRFCoordinatorV2PlusMetaData.ABI) + vrfCoordinatorV2ABI = evmtypes.MustGetABI(vrf_coordinator_v2.VRFCoordinatorV2MetaData.ABI) + vrfCoordinatorV1ABI = evmtypes.MustGetABI(solidity_vrf_coordinator_interface.VRFCoordinatorMetaData.ABI) _ Coordinator = &TestCoordinator{} _ BHS = &TestBHS{} @@ -429,6 +433,99 @@ func TestFeederWithLogPollerVRFv2(t *testing.T) { } } +func TestFeederWithLogPollerVRFv2Plus(t *testing.T) { + + var coordinatorAddress = common.HexToAddress("0x514910771AF9Ca656af840dff83E8264EcF986CA") + + for _, test := range tests { + t.Run(test.name, func(t *testing.T) { + // Instantiate log poller & coordinator. + lp := &mocklp.LogPoller{} + lp.On("RegisterFilter", mock.Anything).Return(nil) + c, err := vrf_coordinator_v2plus.NewVRFCoordinatorV2Plus(coordinatorAddress, nil) + require.NoError(t, err) + coordinator := &V2PlusCoordinator{ + c: c, + lp: lp, + } + + // Assert search window. + latest := int64(test.latest) + fromBlock := mathutil.Max(latest-int64(test.lookback), 0) + toBlock := mathutil.Max(latest-int64(test.wait), 0) + + // Construct request logs. + var requestLogs []logpoller.Log + for _, r := range test.requests { + if r.Block < uint64(fromBlock) || r.Block > uint64(toBlock) { + continue // do not include blocks outside our search window + } + reqId, ok := big.NewInt(0).SetString(r.ID, 10) + require.True(t, ok) + requestLogs = append( + requestLogs, + newRandomnessRequestedLogV2Plus(t, r.Block, reqId, coordinatorAddress), + ) + } + + // Construct fulfillment logs. + var fulfillmentLogs []logpoller.Log + for _, r := range test.fulfillments { + reqId, ok := big.NewInt(0).SetString(r.ID, 10) + require.True(t, ok) + fulfillmentLogs = append( + fulfillmentLogs, + newRandomnessFulfilledLogV2Plus(t, r.Block, reqId, coordinatorAddress), + ) + } + + // Mock log poller. + lp.On("LatestBlock", mock.Anything). + Return(latest, nil) + lp.On( + "LogsWithSigs", + fromBlock, + toBlock, + []common.Hash{ + vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsRequested{}.Topic(), + }, + coordinatorAddress, + mock.Anything, + ).Return(requestLogs, nil) + lp.On( + "LogsWithSigs", + fromBlock, + latest, + []common.Hash{ + vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsFulfilled{}.Topic(), + }, + coordinatorAddress, + mock.Anything, + ).Return(fulfillmentLogs, nil) + + // Instantiate feeder. + feeder := NewFeeder( + logger.TestLogger(t), + coordinator, + &test.bhs, + test.wait, + test.lookback, + func(ctx context.Context) (uint64, error) { + return test.latest, nil + }) + + // Run feeder and assert correct results. + err = feeder.Run(testutils.Context(t)) + if test.expectedErrMsg == "" { + require.NoError(t, err) + } else { + require.EqualError(t, err, test.expectedErrMsg) + } + require.ElementsMatch(t, test.expectedStored, test.bhs.Stored) + }) + } +} + func TestFeeder_CachesStoredBlocks(t *testing.T) { coordinator := &TestCoordinator{ RequestEvents: []Event{{Block: 100, ID: "1000"}}, @@ -697,3 +794,159 @@ func newRandomnessFulfilledLogV2( } return lg } + +func newRandomnessRequestedLogV2Plus( + t *testing.T, + requestBlock uint64, + requestID *big.Int, + coordinatorAddress common.Address, +) logpoller.Log { + e := vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsRequested{ + RequestId: requestID, + PreSeed: big.NewInt(0), + MinimumRequestConfirmations: 0, + CallbackGasLimit: 0, + NumWords: 0, + Sender: common.HexToAddress("0xeFF41C8725be95e66F6B10489B6bF34b08055853"), + ExtraArgs: []byte{}, + SubId: big.NewInt(0), + Raw: types.Log{ + BlockNumber: requestBlock, + }, + } + var unindexed abi.Arguments + for _, a := range vrfCoordinatorV2PlusABI.Events[randomWordsRequestedV2Plus].Inputs { + if !a.Indexed { + unindexed = append(unindexed, a) + } + } + nonIndexedData, err := unindexed.Pack( + e.RequestId, + e.PreSeed, + e.MinimumRequestConfirmations, + e.CallbackGasLimit, + e.NumWords, + e.ExtraArgs, + ) + require.NoError(t, err) + + keyHashType, err := abi.NewType("bytes32", "", nil) + require.NoError(t, err) + + subIdType, err := abi.NewType("uint256", "", nil) + require.NoError(t, err) + + senderType, err := abi.NewType("address", "", nil) + require.NoError(t, err) + + keyHashArg := abi.Arguments{abi.Argument{ + Name: "keyHash", + Type: keyHashType, + Indexed: true, + }} + subIdArg := abi.Arguments{abi.Argument{ + Name: "subId", + Type: subIdType, + Indexed: true, + }} + + senderArg := abi.Arguments{abi.Argument{ + Name: "sender", + Type: senderType, + Indexed: true, + }} + + topic1, err := keyHashArg.Pack(e.KeyHash) + require.NoError(t, err) + topic2, err := subIdArg.Pack(e.SubId) + require.NoError(t, err) + topic3, err := senderArg.Pack(e.Sender) + require.NoError(t, err) + + topic0 := vrfCoordinatorV2PlusABI.Events[randomWordsRequestedV2Plus].ID + lg := logpoller.Log{ + Address: coordinatorAddress, + Data: nonIndexedData, + Topics: [][]byte{ + // first topic is the event signature + topic0.Bytes(), + // second topic is keyHash since it's indexed + topic1, + // third topic is subId since it's indexed + topic2, + // third topic is sender since it's indexed + topic3, + }, + BlockNumber: int64(requestBlock), + EventSig: topic0, + } + return lg +} + +func newRandomnessFulfilledLogV2Plus( + t *testing.T, + requestBlock uint64, + requestID *big.Int, + coordinatorAddress common.Address, +) logpoller.Log { + e := vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsFulfilled{ + RequestId: requestID, + OutputSeed: big.NewInt(0), + Payment: big.NewInt(0), + Success: true, + Raw: types.Log{ + BlockNumber: requestBlock, + }, + SubID: big.NewInt(0), + } + var unindexed abi.Arguments + for _, a := range vrfCoordinatorV2PlusABI.Events[randomWordsFulfilledV2Plus].Inputs { + if !a.Indexed { + unindexed = append(unindexed, a) + } + } + nonIndexedData, err := unindexed.Pack( + e.OutputSeed, + e.Payment, + e.ExtraArgs, + e.Success, + ) + require.NoError(t, err) + + requestIdType, err := abi.NewType("uint256", "", nil) + require.NoError(t, err) + subIdType, err := abi.NewType("uint256", "", nil) + require.NoError(t, err) + + requestIdArg := abi.Arguments{abi.Argument{ + Name: "requestId", + Type: requestIdType, + Indexed: true, + }} + subIdArg := abi.Arguments{abi.Argument{ + Name: "subID", + Type: subIdType, + Indexed: true, + }} + + topic1, err := requestIdArg.Pack(e.RequestId) + require.NoError(t, err) + topic2, err := subIdArg.Pack(e.SubID) + require.NoError(t, err) + + topic0 := vrfCoordinatorV2PlusABI.Events[randomWordsFulfilledV2Plus].ID + lg := logpoller.Log{ + Address: coordinatorAddress, + Data: nonIndexedData, + Topics: [][]byte{ + // first topic is the event signature + topic0.Bytes(), + // second topic is requestId since it's indexed + topic1, + topic2, + }, + BlockNumber: int64(requestBlock), + EventSig: topic0, + } + return lg +} diff --git a/core/services/job/job_orm_test.go b/core/services/job/job_orm_test.go index ce03dbaa0e3..4b7f9a7ea7b 100644 --- a/core/services/job/job_orm_test.go +++ b/core/services/job/job_orm_test.go @@ -251,6 +251,7 @@ func TestORM(t *testing.T) { require.Equal(t, jb.BlockhashStoreSpec.ID, savedJob.BlockhashStoreSpec.ID) require.Equal(t, jb.BlockhashStoreSpec.CoordinatorV1Address, savedJob.BlockhashStoreSpec.CoordinatorV1Address) require.Equal(t, jb.BlockhashStoreSpec.CoordinatorV2Address, savedJob.BlockhashStoreSpec.CoordinatorV2Address) + require.Equal(t, jb.BlockhashStoreSpec.CoordinatorV2PlusAddress, savedJob.BlockhashStoreSpec.CoordinatorV2PlusAddress) require.Equal(t, jb.BlockhashStoreSpec.WaitBlocks, savedJob.BlockhashStoreSpec.WaitBlocks) require.Equal(t, jb.BlockhashStoreSpec.LookbackBlocks, savedJob.BlockhashStoreSpec.LookbackBlocks) require.Equal(t, jb.BlockhashStoreSpec.BlockhashStoreAddress, savedJob.BlockhashStoreSpec.BlockhashStoreAddress) @@ -479,6 +480,90 @@ func TestORM_CreateJob_VRFV2(t *testing.T) { cltest.AssertCount(t, db, "jobs", 0) } +func TestORM_CreateJob_VRFV2Plus(t *testing.T) { + config := configtest.NewTestGeneralConfig(t) + db := pgtest.NewSqlxDB(t) + keyStore := cltest.NewKeyStore(t, db, config.Database()) + require.NoError(t, keyStore.OCR().Add(cltest.DefaultOCRKey)) + + lggr := logger.TestLogger(t) + pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) + bridgesORM := bridges.NewORM(db, lggr, config.Database()) + cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + + fromAddresses := []string{cltest.NewEIP55Address().String(), cltest.NewEIP55Address().String()} + jb, err := vrfcommon.ValidatedVRFSpec(testspecs.GenerateVRFSpec( + testspecs.VRFSpecParams{ + VRFVersion: vrfcommon.V2Plus, + RequestedConfsDelay: 10, + FromAddresses: fromAddresses, + ChunkSize: 25, + BackoffInitialDelay: time.Minute, + BackoffMaxDelay: time.Hour, + GasLanePrice: assets.GWei(100), + }). + Toml()) + require.NoError(t, err) + + require.NoError(t, jobORM.CreateJob(&jb)) + cltest.AssertCount(t, db, "vrf_specs", 1) + cltest.AssertCount(t, db, "jobs", 1) + var requestedConfsDelay int64 + require.NoError(t, db.Get(&requestedConfsDelay, `SELECT requested_confs_delay FROM vrf_specs LIMIT 1`)) + require.Equal(t, int64(10), requestedConfsDelay) + var batchFulfillmentEnabled bool + require.NoError(t, db.Get(&batchFulfillmentEnabled, `SELECT batch_fulfillment_enabled FROM vrf_specs LIMIT 1`)) + require.False(t, batchFulfillmentEnabled) + var batchFulfillmentGasMultiplier float64 + require.NoError(t, db.Get(&batchFulfillmentGasMultiplier, `SELECT batch_fulfillment_gas_multiplier FROM vrf_specs LIMIT 1`)) + require.Equal(t, float64(1.0), batchFulfillmentGasMultiplier) + var requestTimeout time.Duration + require.NoError(t, db.Get(&requestTimeout, `SELECT request_timeout FROM vrf_specs LIMIT 1`)) + require.Equal(t, 24*time.Hour, requestTimeout) + var backoffInitialDelay time.Duration + require.NoError(t, db.Get(&backoffInitialDelay, `SELECT backoff_initial_delay FROM vrf_specs LIMIT 1`)) + require.Equal(t, time.Minute, backoffInitialDelay) + var backoffMaxDelay time.Duration + require.NoError(t, db.Get(&backoffMaxDelay, `SELECT backoff_max_delay FROM vrf_specs LIMIT 1`)) + require.Equal(t, time.Hour, backoffMaxDelay) + var chunkSize int + require.NoError(t, db.Get(&chunkSize, `SELECT chunk_size FROM vrf_specs LIMIT 1`)) + require.Equal(t, 25, chunkSize) + var gasLanePrice assets.Wei + require.NoError(t, db.Get(&gasLanePrice, `SELECT gas_lane_price FROM vrf_specs LIMIT 1`)) + require.Equal(t, jb.VRFSpec.GasLanePrice, &gasLanePrice) + var fa pq.ByteaArray + require.NoError(t, db.Get(&fa, `SELECT from_addresses FROM vrf_specs LIMIT 1`)) + var actual []string + for _, b := range fa { + actual = append(actual, common.BytesToAddress(b).String()) + } + require.ElementsMatch(t, fromAddresses, actual) + var vrfOwnerAddress ethkey.EIP55Address + require.Error(t, db.Get(&vrfOwnerAddress, `SELECT vrf_owner_address FROM vrf_specs LIMIT 1`)) + require.NoError(t, jobORM.DeleteJob(jb.ID)) + cltest.AssertCount(t, db, "vrf_specs", 0) + cltest.AssertCount(t, db, "jobs", 0) + + jb, err = vrfcommon.ValidatedVRFSpec(testspecs.GenerateVRFSpec(testspecs.VRFSpecParams{ + VRFVersion: vrfcommon.V2Plus, + RequestTimeout: 1 * time.Hour, + FromAddresses: fromAddresses, + }).Toml()) + require.NoError(t, err) + require.NoError(t, jobORM.CreateJob(&jb)) + cltest.AssertCount(t, db, "vrf_specs", 1) + cltest.AssertCount(t, db, "jobs", 1) + require.NoError(t, db.Get(&requestedConfsDelay, `SELECT requested_confs_delay FROM vrf_specs LIMIT 1`)) + require.Equal(t, int64(0), requestedConfsDelay) + require.NoError(t, db.Get(&requestTimeout, `SELECT request_timeout FROM vrf_specs LIMIT 1`)) + require.Equal(t, 1*time.Hour, requestTimeout) + require.NoError(t, jobORM.DeleteJob(jb.ID)) + cltest.AssertCount(t, db, "vrf_specs", 0) + cltest.AssertCount(t, db, "jobs", 0) +} + func TestORM_CreateJob_OCRBootstrap(t *testing.T) { config := configtest.NewTestGeneralConfig(t) db := pgtest.NewSqlxDB(t) diff --git a/core/services/vrf/delegate.go b/core/services/vrf/delegate.go index b3c3fb74da4..a4b5fd1a85d 100644 --- a/core/services/vrf/delegate.go +++ b/core/services/vrf/delegate.go @@ -126,10 +126,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { ) lV1 := l.Named("VRFListener") lV2 := l.Named("VRFListenerV2") - - if vrfOwner == nil { - lV2.Infow("Running without VRFOwnerAddress set on the spec") - } + lV2Plus := l.Named("VRFListenerV2Plus") for _, task := range pl.Tasks { if _, ok := task.(*pipeline.VRFTaskV2Plus); ok { @@ -144,7 +141,9 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { if err := CheckFromAddressMaxGasPrices(jb, chain.Config().EVM().GasEstimator().PriceMaxKey); err != nil { return nil, err } - + if vrfOwner != nil { + return nil, errors.New("VRF Owner is not supported for VRF V2 Plus") + } linkEthFeedAddress, err := coordinatorV2Plus.LINKETHFEED(nil) if err != nil { return nil, errors.Wrap(err, "LINKETHFEED") @@ -157,7 +156,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { return []job.ServiceCtx{v2.New( chain.Config().EVM(), chain.Config().EVM().GasEstimator(), - lV2, + lV2Plus, chain.Client(), chain.ID(), chain.LogBroadcaster(), @@ -173,7 +172,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { d.mailMon, utils.NewHighCapacityMailbox[log.Broadcast](), func() {}, - GetStartingResponseCountsV2(d.q, lV2, chainId.Uint64(), chain.Config().EVM().FinalityDepth()), + GetStartingResponseCountsV2(d.q, lV2Plus, chainId.Uint64(), chain.Config().EVM().FinalityDepth()), chain.HeadBroadcaster(), vrfcommon.NewLogDeduper(int(chain.Config().EVM().FinalityDepth())))}, nil } @@ -198,6 +197,9 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { if err != nil { return nil, errors.Wrap(err, "NewAggregatorV3Interface") } + if vrfOwner == nil { + lV2.Infow("Running without VRFOwnerAddress set on the spec") + } return []job.ServiceCtx{v2.New( chain.Config().EVM(), diff --git a/core/services/vrf/delegate_test.go b/core/services/vrf/delegate_test.go index 4b7f023b41a..3d8466b665a 100644 --- a/core/services/vrf/delegate_test.go +++ b/core/services/vrf/delegate_test.go @@ -673,3 +673,37 @@ func Test_FromAddressMaxGasPricesAllEqual(t *testing.T) { assert.False(tt, vrf.FromAddressMaxGasPricesAllEqual(jb, cfg.PriceMaxKey)) }) } + +func Test_VRFV2PlusServiceFailsWhenVRFOwnerProvided(t *testing.T) { + db := pgtest.NewSqlxDB(t) + cfg := configtest.NewTestGeneralConfig(t) + vuni := buildVrfUni(t, db, cfg) + + mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) + + vd := vrf.NewDelegate( + db, + vuni.ks, + vuni.pr, + vuni.prm, + vuni.cc, + logger.TestLogger(t), + cfg.Database(), + mailMon) + chain, err := vuni.cc.Get(testutils.FixtureChainID) + require.NoError(t, err) + vs := testspecs.GenerateVRFSpec(testspecs.VRFSpecParams{ + VRFVersion: vrfcommon.V2Plus, + PublicKey: vuni.vrfkey.PublicKey.String(), + FromAddresses: []string{string(vuni.submitter.Hex())}, + GasLanePrice: chain.Config().EVM().GasEstimator().PriceMax(), + }) + toml := "vrfOwnerAddress=\"0xF62fEFb54a0af9D32CDF0Db21C52710844c7eddb\"\n" + vs.Toml() + jb, err := vrfcommon.ValidatedVRFSpec(toml) + require.NoError(t, err) + err = vuni.jrm.CreateJob(&jb) + require.NoError(t, err) + _, err = vd.ServicesForSpec(jb) + require.Error(t, err) + require.Equal(t, "VRF Owner is not supported for VRF V2 Plus", err.Error()) +} diff --git a/core/services/vrf/v2/coordinator_v2x_interface.go b/core/services/vrf/v2/coordinator_v2x_interface.go index 98b543c33c2..95088b01292 100644 --- a/core/services/vrf/v2/coordinator_v2x_interface.go +++ b/core/services/vrf/v2/coordinator_v2x_interface.go @@ -7,6 +7,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" + "github.com/pkg/errors" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated" @@ -21,11 +22,6 @@ var ( _ CoordinatorV2_X = (*coordinatorV2Plus)(nil) ) -var ( - _ CoordinatorV2_X = (*coordinatorV2)(nil) - _ CoordinatorV2_X = (*coordinatorV2Plus)(nil) -) - // CoordinatorV2_X is an interface that allows us to use the same code for // both the V2 and V2Plus coordinators. type CoordinatorV2_X interface { @@ -48,6 +44,8 @@ type CoordinatorV2_X interface { RemoveConsumer(opts *bind.TransactOpts, subID *big.Int, consumer common.Address) (*types.Transaction, error) CancelSubscription(opts *bind.TransactOpts, subID *big.Int, to common.Address) (*types.Transaction, error) GetCommitment(opts *bind.CallOpts, requestID *big.Int) ([32]byte, error) + Migrate(opts *bind.TransactOpts, subID *big.Int, newCoordinator common.Address) (*types.Transaction, error) + FundSubscriptionWithEth(opts *bind.TransactOpts, subID *big.Int, amount *big.Int) (*types.Transaction, error) } type coordinatorV2 struct { @@ -168,6 +166,14 @@ func (c *coordinatorV2) GetCommitment(opts *bind.CallOpts, requestID *big.Int) ( return c.coordinator.GetCommitment(opts, requestID) } +func (c *coordinatorV2) Migrate(opts *bind.TransactOpts, subID *big.Int, newCoordinator common.Address) (*types.Transaction, error) { + panic("migrate not implemented for v2") +} + +func (c *coordinatorV2) FundSubscriptionWithEth(opts *bind.TransactOpts, subID *big.Int, amount *big.Int) (*types.Transaction, error) { + panic("fund subscription with Eth not implemented for v2") +} + type coordinatorV2Plus struct { vrfVersion vrfcommon.Version coordinator *vrf_coordinator_v2plus.VRFCoordinatorV2Plus @@ -298,6 +304,19 @@ func (c *coordinatorV2Plus) GetCommitment(opts *bind.CallOpts, requestID *big.In return c.coordinator.SRequestCommitments(opts, requestID) } +func (c *coordinatorV2Plus) Migrate(opts *bind.TransactOpts, subID *big.Int, newCoordinator common.Address) (*types.Transaction, error) { + return c.coordinator.Migrate(opts, subID, newCoordinator) +} + +func (c *coordinatorV2Plus) FundSubscriptionWithEth(opts *bind.TransactOpts, subID *big.Int, amount *big.Int) (*types.Transaction, error) { + if opts == nil { + return nil, errors.New("*bind.TransactOpts cannot be nil") + } + o := *opts + o.Value = amount + return c.coordinator.FundSubscriptionWithEth(&o, subID) +} + var ( _ RandomWordsRequestedIterator = (*v2RandomWordsRequestedIterator)(nil) _ RandomWordsRequestedIterator = (*v2PlusRandomWordsRequestedIterator)(nil) diff --git a/core/services/vrf/v2/integration_helpers_test.go b/core/services/vrf/v2/integration_helpers_test.go index 9a085af576c..3af45a61ae9 100644 --- a/core/services/vrf/v2/integration_helpers_test.go +++ b/core/services/vrf/v2/integration_helpers_test.go @@ -51,6 +51,7 @@ func testSingleConsumerHappyPath( batchCoordinatorAddress common.Address, vrfOwnerAddress *common.Address, vrfVersion vrfcommon.Version, + nativePayment bool, assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, @@ -75,7 +76,7 @@ func testSingleConsumerHappyPath( app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, config, uni.backend, ownerKey, key1, key2) // Create a subscription and fund with 5 LINK. - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), coordinator, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), coordinator, uni.backend, nativePayment) // Fund gas lanes. sendEth(t, ownerKey, uni.backend, key1.Address, 10) @@ -99,7 +100,7 @@ func testSingleConsumerHappyPath( // Make the first randomness request. numWords := uint32(20) - requestID1, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend) + requestID1, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) // Wait for fulfillment to be queued. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -117,13 +118,13 @@ func testSingleConsumerHappyPath( // In particular: // * success should be true // * payment should be exactly the amount specified as the premium in the coordinator fee config - rwfe := assertRandomWordsFulfilled(t, requestID1, true, coordinator) + rwfe := assertRandomWordsFulfilled(t, requestID1, true, coordinator, nativePayment) if len(assertions) > 0 { assertions[0](t, coordinator, rwfe, subID) } // Make the second randomness request and assert fulfillment is successful - requestID2, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend) + requestID2, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) gomega.NewGomegaWithT(t).Eventually(func() bool { uni.backend.Commit() runs, err := app.PipelineORM().GetAllRuns() @@ -137,7 +138,7 @@ func testSingleConsumerHappyPath( // In particular: // * success should be true // * payment should be exactly the amount specified as the premium in the coordinator fee config - rwfe = assertRandomWordsFulfilled(t, requestID2, true, coordinator) + rwfe = assertRandomWordsFulfilled(t, requestID2, true, coordinator, nativePayment) if len(assertions) > 0 { assertions[0](t, coordinator, rwfe, subID) } @@ -169,6 +170,7 @@ func testMultipleConsumersNeedBHS( batchCoordinatorAddress common.Address, vrfOwnerAddress *common.Address, vrfVersion vrfcommon.Version, + nativePayment bool, assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, @@ -251,7 +253,7 @@ func testMultipleConsumersNeedBHS( consumerContract := consumerContracts[i] // Create a subscription and fund with 0 LINK. - _, subID := subscribeVRF(t, consumer, consumerContract, coordinator, uni.backend, new(big.Int)) + _, subID := subscribeVRF(t, consumer, consumerContract, coordinator, uni.backend, new(big.Int), nativePayment) if vrfVersion == vrfcommon.V2 { require.Equal(t, uint64(i+1), subID.Uint64()) } @@ -259,7 +261,7 @@ func testMultipleConsumersNeedBHS( // Make the randomness request. It will not yet succeed since it is underfunded. numWords := uint32(20) - requestID, requestBlock := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend) + requestID, requestBlock := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) // Wait 101 blocks. for i := 0; i < 100; i++ { @@ -273,8 +275,7 @@ func testMultipleConsumersNeedBHS( } // Fund the subscription - _, err := consumerContract.TopUpSubscription(consumer, big.NewInt(5e18 /* 5 LINK */)) - require.NoError(t, err) + topUpSubscription(t, consumer, consumerContract, uni.backend, big.NewInt(5e18 /* 5 LINK */), nativePayment) // Wait for fulfillment to be queued. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -287,7 +288,7 @@ func testMultipleConsumersNeedBHS( mine(t, requestID, subID, uni.backend, db, vrfVersion) - rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator) + rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator, nativePayment) if len(assertions) > 0 { assertions[0](t, coordinator, rwfe) } @@ -343,6 +344,7 @@ func testSingleConsumerHappyPathBatchFulfillment( numRequests int, bigGasCallback bool, vrfVersion vrfcommon.Version, + nativePayment bool, assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, @@ -363,7 +365,7 @@ func testSingleConsumerHappyPathBatchFulfillment( app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, config, uni.backend, ownerKey, key1) // Create a subscription and fund with 5 LINK. - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), coordinator, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), coordinator, uni.backend, nativePayment) // Fund gas lane. sendEth(t, ownerKey, uni.backend, key1.Address, 10) @@ -388,14 +390,14 @@ func testSingleConsumerHappyPathBatchFulfillment( numWords := uint32(2) var reqIDs []*big.Int for i := 0; i < numRequests; i++ { - requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend) + requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) reqIDs = append(reqIDs, requestID) } if bigGasCallback { // Make one randomness request with the max callback gas limit. // It should live in a batch on it's own. - requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 2_500_000, coordinator, uni.backend) + requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 2_500_000, coordinator, uni.backend, nativePayment) reqIDs = append(reqIDs, requestID) } @@ -419,9 +421,9 @@ func testSingleConsumerHappyPathBatchFulfillment( // contract is written. var rwfe v22.RandomWordsFulfilled if i == (len(reqIDs) - 1) { - rwfe = assertRandomWordsFulfilled(t, requestID, true, coordinator) + rwfe = assertRandomWordsFulfilled(t, requestID, true, coordinator, nativePayment) } else { - rwfe = assertRandomWordsFulfilled(t, requestID, false, coordinator) + rwfe = assertRandomWordsFulfilled(t, requestID, false, coordinator, nativePayment) } if len(assertions) > 0 { assertions[0](t, coordinator, rwfe, subID) @@ -446,6 +448,7 @@ func testSingleConsumerNeedsTopUp( initialFundingAmount *big.Int, topUpAmount *big.Int, vrfVersion vrfcommon.Version, + nativePayment bool, assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, @@ -464,7 +467,7 @@ func testSingleConsumerNeedsTopUp( app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, config, uni.backend, ownerKey, key) // Create and fund a subscription - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, initialFundingAmount, coordinator, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, initialFundingAmount, coordinator, uni.backend, nativePayment) // Fund expensive gas lane. sendEth(t, ownerKey, uni.backend, key.Address, 10) @@ -486,7 +489,7 @@ func testSingleConsumerNeedsTopUp( keyHash := jbs[0].VRFSpec.PublicKey.MustHash() numWords := uint32(20) - requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend) + requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) // Fulfillment will not be enqueued because subscriber doesn't have enough LINK. gomega.NewGomegaWithT(t).Consistently(func() bool { @@ -498,8 +501,8 @@ func testSingleConsumerNeedsTopUp( }, 5*time.Second, 1*time.Second).Should(gomega.BeTrue()) // Top up subscription with enough LINK to see the job through. - _, err := consumerContract.TopUpSubscription(consumer, topUpAmount) - require.NoError(t, err) + topUpSubscription(t, consumer, consumerContract, uni.backend, topUpAmount, nativePayment) + uni.backend.Commit() // Wait for fulfillment to go through. gomega.NewWithT(t).Eventually(func() bool { @@ -515,7 +518,7 @@ func testSingleConsumerNeedsTopUp( mine(t, requestID, subID, uni.backend, db, vrfVersion) // Assert the state of the RandomWordsFulfilled event. - rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator) + rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator, nativePayment) if len(assertions) > 0 { assertions[0](t, coordinator, rwfe) } @@ -540,6 +543,7 @@ func testBlockHeaderFeeder( batchCoordinatorAddress common.Address, vrfOwnerAddress *common.Address, vrfVersion vrfcommon.Version, + nativePayment bool, assertions ...func( t *testing.T, coordinator v22.CoordinatorV2_X, @@ -607,7 +611,7 @@ func testBlockHeaderFeeder( consumerContract := consumerContracts[i] // Create a subscription and fund with 0 LINK. - _, subID := subscribeVRF(t, consumer, consumerContract, coordinator, uni.backend, new(big.Int)) + _, subID := subscribeVRF(t, consumer, consumerContract, coordinator, uni.backend, new(big.Int), nativePayment) if vrfVersion == vrfcommon.V2 { require.Equal(t, uint64(i+1), subID.Uint64()) } @@ -615,7 +619,7 @@ func testBlockHeaderFeeder( // Make the randomness request. It will not yet succeed since it is underfunded. numWords := uint32(20) - requestID, requestBlock := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend) + requestID, requestBlock := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) // Wait 256 blocks. for i := 0; i < 256; i++ { @@ -624,8 +628,7 @@ func testBlockHeaderFeeder( verifyBlockhashStored(t, uni, requestBlock) // Fund the subscription - _, err := consumerContract.TopUpSubscription(consumer, big.NewInt(5e18 /* 5 LINK */)) - require.NoError(t, err) + topUpSubscription(t, consumer, consumerContract, uni.backend, big.NewInt(5e18), nativePayment) // Wait for fulfillment to be queued. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -638,7 +641,7 @@ func testBlockHeaderFeeder( mine(t, requestID, subID, uni.backend, db, vrfVersion) - rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator) + rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator, nativePayment) if len(assertions) > 0 { assertions[0](t, coordinator, rwfe) } @@ -845,7 +848,7 @@ func testSingleConsumerForcedFulfillment( // In this particular case: // * success should be true // * payment should be zero (forced fulfillment) - rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator) + rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator, false) require.Equal(t, "0", rwfe.Payment().String()) // Check that the RandomWordsForced event is emitted correctly. @@ -870,6 +873,7 @@ func testSingleConsumerEIP150( batchCoordinatorAddress common.Address, batchEnabled bool, vrfVersion vrfcommon.Version, + nativePayment bool, ) { callBackGasLimit := int64(2_500_000) // base callback gas. eip150Fee := callBackGasLimit / 64 // premium needed for callWithExactGas @@ -893,7 +897,7 @@ func testSingleConsumerEIP150( consumerContractAddress := uni.consumerContractAddresses[0] // Create a subscription and fund with 500 LINK. subAmount := big.NewInt(1).Mul(big.NewInt(5e18), big.NewInt(100)) - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, subAmount, uni.rootContract, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, subAmount, uni.rootContract, uni.backend, nativePayment) // Fund gas lane. sendEth(t, ownerKey, uni.backend, key1.Address, 10) @@ -916,7 +920,7 @@ func testSingleConsumerEIP150( // Make the first randomness request. numWords := uint32(1) - requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, uint32(callBackGasLimit), uni.rootContract, uni.backend) + requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, uint32(callBackGasLimit), uni.rootContract, uni.backend, nativePayment) // Wait for simulation to pass. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -937,6 +941,7 @@ func testSingleConsumerEIP150Revert( batchCoordinatorAddress common.Address, batchEnabled bool, vrfVersion vrfcommon.Version, + nativePayment bool, ) { callBackGasLimit := int64(2_500_000) // base callback gas. eip150Fee := int64(0) // no premium given for callWithExactGas @@ -960,7 +965,7 @@ func testSingleConsumerEIP150Revert( consumerContractAddress := uni.consumerContractAddresses[0] // Create a subscription and fund with 500 LINK. subAmount := big.NewInt(1).Mul(big.NewInt(5e18), big.NewInt(100)) - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, subAmount, uni.rootContract, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, subAmount, uni.rootContract, uni.backend, nativePayment) // Fund gas lane. sendEth(t, ownerKey, uni.backend, key1.Address, 10) @@ -983,7 +988,7 @@ func testSingleConsumerEIP150Revert( // Make the first randomness request. numWords := uint32(1) - requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, uint32(callBackGasLimit), uni.rootContract, uni.backend) + requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, uint32(callBackGasLimit), uni.rootContract, uni.backend, nativePayment) // Simulation should not pass. gomega.NewGomegaWithT(t).Consistently(func() bool { @@ -1004,6 +1009,7 @@ func testSingleConsumerBigGasCallbackSandwich( batchCoordinatorAddress common.Address, batchEnabled bool, vrfVersion vrfcommon.Version, + nativePayment bool, ) { key1 := cltest.MustGenerateRandomKey(t) gasLanePriceWei := assets.GWei(100) @@ -1021,7 +1027,7 @@ func testSingleConsumerBigGasCallbackSandwich( consumerContract := uni.consumerContracts[0] consumerContractAddress := uni.consumerContractAddresses[0] - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, assets.Ether(2).ToInt(), uni.rootContract, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, assets.Ether(2).ToInt(), uni.rootContract, uni.backend, nativePayment) // Fund gas lane. sendEth(t, ownerKey, uni.backend, key1.Address, 10) @@ -1047,7 +1053,7 @@ func testSingleConsumerBigGasCallbackSandwich( reqIDs := []*big.Int{} callbackGasLimits := []uint32{2_500_000, 50_000, 1_500_000} for _, limit := range callbackGasLimits { - requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, limit, uni.rootContract, uni.backend) + requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, limit, uni.rootContract, uni.backend, nativePayment) reqIDs = append(reqIDs, requestID) uni.backend.Commit() } @@ -1080,7 +1086,7 @@ func testSingleConsumerBigGasCallbackSandwich( mine(t, reqIDs[1], subID, uni.backend, db, vrfVersion) // Assert the random word was fulfilled - assertRandomWordsFulfilled(t, reqIDs[1], false, uni.rootContract) + assertRandomWordsFulfilled(t, reqIDs[1], false, uni.rootContract, nativePayment) // Assert that we've still only completed 1 run before adding new requests. runs, err = app.PipelineORM().GetAllRuns() @@ -1090,7 +1096,7 @@ func testSingleConsumerBigGasCallbackSandwich( // Make some randomness requests, each one block apart, this time without a low-gas request present in the callbackGasLimit slice. callbackGasLimits = []uint32{2_500_000, 2_500_000, 2_500_000} for _, limit := range callbackGasLimits { - _, _ = requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, limit, uni.rootContract, uni.backend) + _, _ = requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, limit, uni.rootContract, uni.backend, nativePayment) uni.backend.Commit() } @@ -1113,6 +1119,7 @@ func testSingleConsumerMultipleGasLanes( batchCoordinatorAddress common.Address, batchEnabled bool, vrfVersion vrfcommon.Version, + nativePayment bool, ) { cheapKey := cltest.MustGenerateRandomKey(t) expensiveKey := cltest.MustGenerateRandomKey(t) @@ -1138,7 +1145,7 @@ func testSingleConsumerMultipleGasLanes( consumerContractAddress := uni.consumerContractAddresses[0] // Create a subscription and fund with 5 LINK. - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), uni.rootContract, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), uni.rootContract, uni.backend, nativePayment) // Fund gas lanes. sendEth(t, ownerKey, uni.backend, cheapKey.Address, 10) @@ -1163,7 +1170,7 @@ func testSingleConsumerMultipleGasLanes( numWords := uint32(20) cheapRequestID, _ := - requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, cheapHash, subID, numWords, 500_000, uni.rootContract, uni.backend) + requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, cheapHash, subID, numWords, 500_000, uni.rootContract, uni.backend, nativePayment) // Wait for fulfillment to be queued for cheap key hash. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -1178,12 +1185,12 @@ func testSingleConsumerMultipleGasLanes( mine(t, cheapRequestID, subID, uni.backend, db, vrfVersion) // Assert correct state of RandomWordsFulfilled event. - assertRandomWordsFulfilled(t, cheapRequestID, true, uni.rootContract) + assertRandomWordsFulfilled(t, cheapRequestID, true, uni.rootContract, nativePayment) // Assert correct number of random words sent by coordinator. assertNumRandomWords(t, consumerContract, numWords) - expensiveRequestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, expensiveHash, subID, numWords, 500_000, uni.rootContract, uni.backend) + expensiveRequestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, expensiveHash, subID, numWords, 500_000, uni.rootContract, uni.backend, nativePayment) // We should not have any new fulfillments until a top up. gomega.NewWithT(t).Consistently(func() bool { @@ -1195,8 +1202,7 @@ func testSingleConsumerMultipleGasLanes( }, 5*time.Second, 1*time.Second).Should(gomega.BeTrue()) // Top up subscription with enough LINK to see the job through. 100 LINK should do the trick. - _, err := consumerContract.TopUpSubscription(consumer, decimal.RequireFromString("100e18").BigInt()) - require.NoError(t, err) + topUpSubscription(t, consumer, consumerContract, uni.backend, decimal.RequireFromString("100e18").BigInt(), nativePayment) // Wait for fulfillment to be queued for expensive key hash. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -1211,12 +1217,23 @@ func testSingleConsumerMultipleGasLanes( mine(t, expensiveRequestID, subID, uni.backend, db, vrfVersion) // Assert correct state of RandomWordsFulfilled event. - assertRandomWordsFulfilled(t, expensiveRequestID, true, uni.rootContract) + assertRandomWordsFulfilled(t, expensiveRequestID, true, uni.rootContract, nativePayment) // Assert correct number of random words sent by coordinator. assertNumRandomWords(t, consumerContract, numWords) } +func topUpSubscription(t *testing.T, consumer *bind.TransactOpts, consumerContract vrftesthelpers.VRFConsumerContract, backend *backends.SimulatedBackend, fundingAmount *big.Int, nativePayment bool) { + if nativePayment { + _, err := consumerContract.TopUpSubscriptionNative(consumer, fundingAmount) + require.NoError(t, err) + } else { + _, err := consumerContract.TopUpSubscription(consumer, fundingAmount) + require.NoError(t, err) + } + backend.Commit() +} + func testSingleConsumerAlwaysRevertingCallbackStillFulfilled( t *testing.T, ownerKey ethkey.KeyV2, @@ -1224,6 +1241,7 @@ func testSingleConsumerAlwaysRevertingCallbackStillFulfilled( batchCoordinatorAddress common.Address, batchEnabled bool, vrfVersion vrfcommon.Version, + nativePayment bool, ) { key := cltest.MustGenerateRandomKey(t) gasLanePriceWei := assets.GWei(10) @@ -1241,7 +1259,7 @@ func testSingleConsumerAlwaysRevertingCallbackStillFulfilled( consumerContractAddress := uni.revertingConsumerContractAddress // Create a subscription and fund with 5 LINK. - subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), uni.rootContract, uni.backend) + subID := subscribeAndAssertSubscriptionCreatedEvent(t, consumerContract, consumer, consumerContractAddress, big.NewInt(5e18), uni.rootContract, uni.backend, nativePayment) // Fund gas lane. sendEth(t, ownerKey, uni.backend, key.Address, 10) @@ -1264,7 +1282,7 @@ func testSingleConsumerAlwaysRevertingCallbackStillFulfilled( // Make the randomness request. numWords := uint32(20) - requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, uni.rootContract, uni.backend) + requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, uni.rootContract, uni.backend, nativePayment) // Wait for fulfillment to be queued. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -1279,7 +1297,7 @@ func testSingleConsumerAlwaysRevertingCallbackStillFulfilled( mine(t, requestID, subID, uni.backend, db, vrfVersion) // Assert correct state of RandomWordsFulfilled event. - assertRandomWordsFulfilled(t, requestID, false, uni.rootContract) + assertRandomWordsFulfilled(t, requestID, false, uni.rootContract, nativePayment) t.Log("Done!") } @@ -1290,6 +1308,7 @@ func testConsumerProxyHappyPath( batchCoordinatorAddress common.Address, batchEnabled bool, vrfVersion vrfcommon.Version, + nativePayment bool, ) { key1 := cltest.MustGenerateRandomKey(t) key2 := cltest.MustGenerateRandomKey(t) @@ -1313,7 +1332,7 @@ func testConsumerProxyHappyPath( // Create a subscription and fund with 5 LINK. subID := subscribeAndAssertSubscriptionCreatedEvent( t, consumerContract, consumerOwner, consumerContractAddress, - assets.Ether(5).ToInt(), uni.rootContract, uni.backend) + assets.Ether(5).ToInt(), uni.rootContract, uni.backend, nativePayment) // Create gas lane. sendEth(t, ownerKey, uni.backend, key1.Address, 10) @@ -1338,7 +1357,7 @@ func testConsumerProxyHappyPath( // Make the first randomness request. numWords := uint32(20) requestID1, _ := requestRandomnessAndAssertRandomWordsRequestedEvent( - t, consumerContract, consumerOwner, keyHash, subID, numWords, 750_000, uni.rootContract, uni.backend) + t, consumerContract, consumerOwner, keyHash, subID, numWords, 750_000, uni.rootContract, uni.backend, nativePayment) // Wait for fulfillment to be queued. gomega.NewGomegaWithT(t).Eventually(func() bool { @@ -1353,7 +1372,7 @@ func testConsumerProxyHappyPath( mine(t, requestID1, subID, uni.backend, db, vrfVersion) // Assert correct state of RandomWordsFulfilled event. - assertRandomWordsFulfilled(t, requestID1, true, uni.rootContract) + assertRandomWordsFulfilled(t, requestID1, true, uni.rootContract, nativePayment) // Gas available will be around 724,385, which means that 750,000 - 724,385 = 25,615 gas was used. // This is ~20k more than what the non-proxied consumer uses. @@ -1364,7 +1383,7 @@ func testConsumerProxyHappyPath( // Make the second randomness request and assert fulfillment is successful requestID2, _ := requestRandomnessAndAssertRandomWordsRequestedEvent( - t, consumerContract, consumerOwner, keyHash, subID, numWords, 750_000, uni.rootContract, uni.backend) + t, consumerContract, consumerOwner, keyHash, subID, numWords, 750_000, uni.rootContract, uni.backend, nativePayment) gomega.NewGomegaWithT(t).Eventually(func() bool { uni.backend.Commit() runs, err := app.PipelineORM().GetAllRuns() @@ -1373,7 +1392,7 @@ func testConsumerProxyHappyPath( return len(runs) == 2 }, testutils.WaitTimeout(t), time.Second).Should(gomega.BeTrue()) mine(t, requestID2, subID, uni.backend, db, vrfVersion) - assertRandomWordsFulfilled(t, requestID2, true, uni.rootContract) + assertRandomWordsFulfilled(t, requestID2, true, uni.rootContract, nativePayment) // Assert correct number of random words sent by coordinator. assertNumRandomWords(t, consumerContract, numWords) diff --git a/core/services/vrf/v2/integration_v2_plus_test.go b/core/services/vrf/v2/integration_v2_plus_test.go index 02b5fab6b68..6cd5900d01b 100644 --- a/core/services/vrf/v2/integration_v2_plus_test.go +++ b/core/services/vrf/v2/integration_v2_plus_test.go @@ -4,6 +4,7 @@ import ( "math/big" "strings" "testing" + "time" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi/bind" @@ -12,10 +13,12 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/core" "github.com/ethereum/go-ethereum/eth/ethconfig" + "github.com/onsi/gomega" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/assets" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/batch_blockhash_store" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/batch_vrf_coordinator_v2plus" @@ -24,6 +27,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_v3_aggregator_contract" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_consumer_v2_plus_upgradeable_example" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_consumer_v2_upgradeable_example" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2_plus_v2_example" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_malicious_consumer_v2_plus" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_v2plus_single_consumer" @@ -33,9 +37,12 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrfv2plus_consumer_example" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrfv2plus_reverting_example" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/vrfkey" "github.com/smartcontractkit/chainlink/v2/core/services/signatures/secp256k1" "github.com/smartcontractkit/chainlink/v2/core/services/vrf/extraargs" "github.com/smartcontractkit/chainlink/v2/core/services/vrf/proof" @@ -50,6 +57,8 @@ type coordinatorV2PlusUniverse struct { submanager *bind.TransactOpts // Subscription owner batchCoordinatorContract *batch_vrf_coordinator_v2plus.BatchVRFCoordinatorV2Plus batchCoordinatorContractAddress common.Address + migrationTestCoordinator *vrf_coordinator_v2_plus_v2_example.VRFCoordinatorV2PlusV2Example + migrationTestCoordinatorAddress common.Address } func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumers int) coordinatorV2PlusUniverse { @@ -125,6 +134,15 @@ func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumer require.NoError(t, err) backend.Commit() + migrationTestCoordinatorAddress, _, migrationTestCoordinator, err := vrf_coordinator_v2_plus_v2_example.DeployVRFCoordinatorV2PlusV2Example( + neil, backend, linkAddress, coordinatorAddress) + require.NoError(t, err) + backend.Commit() + + _, err = coordinatorContract.RegisterMigratableCoordinator(neil, migrationTestCoordinatorAddress) + require.NoError(t, err) + backend.Commit() + // Deploy batch VRF V2 coordinator batchCoordinatorAddress, _, batchCoordinatorContract, err := batch_vrf_coordinator_v2plus.DeployBatchVRFCoordinatorV2Plus( @@ -267,6 +285,8 @@ func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumer batchCoordinatorContract: batchCoordinatorContract, batchCoordinatorContractAddress: batchCoordinatorAddress, submanager: submanager, + migrationTestCoordinator: migrationTestCoordinator, + migrationTestCoordinatorAddress: migrationTestCoordinatorAddress, } } @@ -274,75 +294,152 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment(t *testi t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) - testSingleConsumerHappyPathBatchFulfillment( - t, - ownerKey, - uni.coordinatorV2UniverseCommon, - uni.vrfConsumers[0], - uni.consumerContracts[0], - uni.consumerContractAddresses[0], - uni.rootContract, - uni.rootContractAddress, - uni.batchCoordinatorContractAddress, - nil, - 5, // number of requests to send - false, // don't send big callback - vrfcommon.V2Plus, - func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { - _, err := coordinator.GetSubscription(nil, rwfe.SubID()) - require.NoError(t, err) - require.Equal(t, expectedSubID, rwfe.SubID()) - }, - ) + t.Run("link payment", func(tt *testing.T) { + testSingleConsumerHappyPathBatchFulfillment( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + 5, // number of requests to send + false, // don't send big callback + vrfcommon.V2Plus, + false, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }, + ) + }) + + t.Run("native payment", func(tt *testing.T) { + testSingleConsumerHappyPathBatchFulfillment( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + 5, // number of requests to send + false, // don't send big callback + vrfcommon.V2Plus, + true, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }, + ) + }) } func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment_BigGasCallback(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) - testSingleConsumerHappyPathBatchFulfillment( - t, - ownerKey, - uni.coordinatorV2UniverseCommon, - uni.vrfConsumers[0], - uni.consumerContracts[0], - uni.consumerContractAddresses[0], - uni.rootContract, - uni.rootContractAddress, - uni.batchCoordinatorContractAddress, - nil, - 5, // number of requests to send - true, // send big callback - vrfcommon.V2Plus, - func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { - _, err := coordinator.GetSubscription(nil, rwfe.SubID()) - require.NoError(t, err) - require.Equal(t, expectedSubID, rwfe.SubID()) - }, - ) + t.Run("link payment", func(tt *testing.T) { + testSingleConsumerHappyPathBatchFulfillment( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + 5, // number of requests to send + true, // send big callback + vrfcommon.V2Plus, + false, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }, + ) + }) + + t.Run("native payment", func(tt *testing.T) { + testSingleConsumerHappyPathBatchFulfillment( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + 5, // number of requests to send + true, // send big callback + vrfcommon.V2Plus, + true, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }, + ) + }) } func TestVRFV2PlusIntegration_SingleConsumer_HappyPath(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) - testSingleConsumerHappyPath( - t, - ownerKey, - uni.coordinatorV2UniverseCommon, - uni.vrfConsumers[0], - uni.consumerContracts[0], - uni.consumerContractAddresses[0], - uni.rootContract, - uni.rootContractAddress, - uni.batchCoordinatorContractAddress, - nil, - vrfcommon.V2Plus, - func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { - _, err := coordinator.GetSubscription(nil, rwfe.SubID()) - require.NoError(t, err) - require.Equal(t, expectedSubID, rwfe.SubID()) - }) + t.Run("link payment", func(tt *testing.T) { + testSingleConsumerHappyPath( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + vrfcommon.V2Plus, + false, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }) + }) + t.Run("native payment", func(tt *testing.T) { + testSingleConsumerHappyPath( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + vrfcommon.V2Plus, + true, + func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { + _, err := coordinator.GetSubscription(nil, rwfe.SubID()) + require.NoError(t, err) + require.Equal(t, expectedSubID, rwfe.SubID()) + }) + }) } func TestVRFV2PlusIntegration_SingleConsumer_EOA_Request(t *testing.T) { @@ -386,6 +483,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_EIP150_HappyPath(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2Plus, + false, ) } @@ -400,6 +498,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_EIP150_Revert(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2Plus, + false, ) } @@ -407,57 +506,118 @@ func TestVRFV2PlusIntegration_SingleConsumer_NeedsBlockhashStore(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 2) - testMultipleConsumersNeedBHS( - t, - ownerKey, - uni.coordinatorV2UniverseCommon, - uni.vrfConsumers, - uni.consumerContracts, - uni.consumerContractAddresses, - uni.rootContract, - uni.rootContractAddress, - uni.batchCoordinatorContractAddress, - nil, - vrfcommon.V2Plus) + t.Run("link payment", func(tt *testing.T) { + testMultipleConsumersNeedBHS( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers, + uni.consumerContracts, + uni.consumerContractAddresses, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + vrfcommon.V2Plus, + false, + ) + }) + t.Run("native payment", func(tt *testing.T) { + testMultipleConsumersNeedBHS( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers, + uni.consumerContracts, + uni.consumerContractAddresses, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + vrfcommon.V2Plus, + true, + ) + }) } func TestVRFV2PlusIntegration_SingleConsumer_BlockHeaderFeeder(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) - testBlockHeaderFeeder( - t, - ownerKey, - uni.coordinatorV2UniverseCommon, - uni.vrfConsumers, - uni.consumerContracts, - uni.consumerContractAddresses, - uni.rootContract, - uni.rootContractAddress, - uni.batchCoordinatorContractAddress, - nil, - vrfcommon.V2Plus) + t.Run("link payment", func(tt *testing.T) { + testBlockHeaderFeeder( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers, + uni.consumerContracts, + uni.consumerContractAddresses, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + vrfcommon.V2Plus, + false, + ) + }) + t.Run("native payment", func(tt *testing.T) { + testBlockHeaderFeeder( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers, + uni.consumerContracts, + uni.consumerContractAddresses, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + vrfcommon.V2Plus, + true, + ) + }) } func TestVRFV2PlusIntegration_SingleConsumer_NeedsTopUp(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) - testSingleConsumerNeedsTopUp( - t, - ownerKey, - uni.coordinatorV2UniverseCommon, - uni.vrfConsumers[0], - uni.consumerContracts[0], - uni.consumerContractAddresses[0], - uni.rootContract, - uni.rootContractAddress, - uni.batchCoordinatorContractAddress, - nil, - assets.Ether(1).ToInt(), // initial funding of 1 LINK - assets.Ether(100).ToInt(), // top up of 100 LINK - vrfcommon.V2Plus, - ) + t.Run("link payment", func(tt *testing.T) { + testSingleConsumerNeedsTopUp( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + assets.Ether(1).ToInt(), // initial funding of 1 LINK + assets.Ether(100).ToInt(), // top up of 100 LINK + vrfcommon.V2Plus, + false, + ) + }) + t.Run("native payment", func(tt *testing.T) { + testSingleConsumerNeedsTopUp( + t, + ownerKey, + uni.coordinatorV2UniverseCommon, + uni.vrfConsumers[0], + uni.consumerContracts[0], + uni.consumerContractAddresses[0], + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + nil, + big.NewInt(1e17), // initial funding of 0.1 ETH + assets.Ether(100).ToInt(), // top up of 100 ETH + vrfcommon.V2Plus, + true, + ) + }) } func TestVRFV2PlusIntegration_SingleConsumer_BigGasCallback_Sandwich(t *testing.T) { @@ -470,6 +630,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_BigGasCallback_Sandwich(t *testing. uni.batchCoordinatorContractAddress, false, vrfcommon.V2Plus, + false, ) } @@ -483,6 +644,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_MultipleGasLanes(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2Plus, + false, ) } @@ -496,6 +658,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_AlwaysRevertingCallback_StillFulfil uni.batchCoordinatorContractAddress, false, vrfcommon.V2Plus, + false, ) } @@ -509,6 +672,7 @@ func TestVRFV2PlusIntegration_ConsumerProxy_HappyPath(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2Plus, + false, ) } @@ -677,6 +841,9 @@ func TestVRFV2PlusIntegration_RequestCost(t *testing.T) { big.NewInt(1000000000000000000)) // 0.1 LINK require.NoError(tt, err) uni.backend.Commit() + _, err = carolContract.TopUpSubscriptionNative(carol, + big.NewInt(2000000000000000000)) // 0.2 ETH + uni.backend.Commit() // Ensure even with large number of consumers its still cheap var addrs []common.Address for i := 0; i < 99; i++ { @@ -684,12 +851,17 @@ func TestVRFV2PlusIntegration_RequestCost(t *testing.T) { } _, err = carolContract.UpdateSubscription(carol, addrs) require.NoError(tt, err) - estimate := estimateGas(tt, uni.backend, common.Address{}, + linkEstimate := estimateGas(tt, uni.backend, common.Address{}, + carolContractAddress, uni.consumerABI, + "requestRandomWords", uint32(10000), uint16(2), uint32(1), + vrfkey.PublicKey.MustHash(), false) + tt.Log("gas estimate of non-proxied requestRandomWords with LINK payment:", linkEstimate) + nativeEstimate := estimateGas(tt, uni.backend, common.Address{}, carolContractAddress, uni.consumerABI, "requestRandomWords", uint32(10000), uint16(2), uint32(1), vrfkey.PublicKey.MustHash(), false) - tt.Log("gas estimate of non-proxied requestRandomWords:", estimate) - assert.Less(tt, estimate, uint64(127_000), + tt.Log("gas estimate of non-proxied requestRandomWords with Native payment:", nativeEstimate) + assert.Less(tt, nativeEstimate, uint64(127_000), "requestRandomWords tx gas cost more than expected") }) @@ -759,6 +931,51 @@ func TestVRFV2PlusIntegration_MaxConsumersCost(t *testing.T) { assert.Less(t, estimate, uint64(100000)) } +func requestAndEstimateFulfillmentCost( + t *testing.T, + subID *big.Int, + consumer *bind.TransactOpts, + vrfkey vrfkey.KeyV2, + minConfs uint16, + gas uint32, + numWords uint32, + consumerContract vrftesthelpers.VRFConsumerContract, + consumerContractAddress common.Address, + uni coordinatorV2UniverseCommon, + app *cltest.TestApplication, + nativePayment bool, + lowerBound, upperBound uint64, +) { + _, err := consumerContract.RequestRandomness(consumer, vrfkey.PublicKey.MustHash(), subID, minConfs, gas, numWords, nativePayment) + require.NoError(t, err) + for i := 0; i < int(minConfs); i++ { + uni.backend.Commit() + } + + requestLog := FindLatestRandomnessRequestedLog(t, uni.rootContract, vrfkey.PublicKey.MustHash()) + s, err := proof.BigToSeed(requestLog.PreSeed()) + require.NoError(t, err) + extraArgs, err := extraargs.ExtraArgsV1(nativePayment) + require.NoError(t, err) + proof, rc, err := proof.GenerateProofResponseV2Plus(app.GetKeyStore().VRF(), vrfkey.ID(), proof.PreSeedDataV2Plus{ + PreSeed: s, + BlockHash: requestLog.Raw().BlockHash, + BlockNum: requestLog.Raw().BlockNumber, + SubId: subID, + CallbackGasLimit: gas, + NumWords: numWords, + Sender: consumerContractAddress, + ExtraArgs: extraArgs, + }) + require.NoError(t, err) + gasEstimate := estimateGas(t, uni.backend, common.Address{}, + uni.rootContractAddress, uni.coordinatorABI, + "fulfillRandomWords", proof, rc) + t.Log("consumer fulfillment gas estimate:", gasEstimate) + assert.Greater(t, gasEstimate, lowerBound) + assert.Less(t, gasEstimate, upperBound) +} + func TestVRFV2PlusIntegration_FulfillmentCost(t *testing.T) { key := cltest.MustGenerateRandomKey(t) uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) @@ -776,10 +993,6 @@ func TestVRFV2PlusIntegration_FulfillmentCost(t *testing.T) { require.NoError(t, err) uni.backend.Commit() - var ( - nonProxiedConsumerGasEstimate uint64 - proxiedConsumerGasEstimate uint64 - ) t.Run("non-proxied consumer", func(tt *testing.T) { carol := uni.vrfConsumers[0] carolContract := uni.consumerContracts[0] @@ -789,41 +1002,51 @@ func TestVRFV2PlusIntegration_FulfillmentCost(t *testing.T) { big.NewInt(1000000000000000000)) // 0.1 LINK require.NoError(tt, err) uni.backend.Commit() - subId, err := carolContract.SSubId(nil) + subID, err := carolContract.SSubId(nil) + require.NoError(tt, err) + _, err = carolContract.TopUpSubscriptionNative(carol, + big.NewInt(2000000000000000000)) // 0.2 ETH require.NoError(tt, err) - gasRequested := 50_000 nw := 1 requestedIncomingConfs := 3 - _, err = carolContract.RequestRandomness(carol, vrfkey.PublicKey.MustHash(), subId, uint16(requestedIncomingConfs), uint32(gasRequested), uint32(nw), false) - require.NoError(t, err) - for i := 0; i < requestedIncomingConfs; i++ { - uni.backend.Commit() - } + t.Run("native payment", func(tt *testing.T) { + requestAndEstimateFulfillmentCost( + t, + subID, + carol, + vrfkey, + uint16(requestedIncomingConfs), + uint32(gasRequested), + uint32(nw), + carolContract, + carolContractAddress, + uni.coordinatorV2UniverseCommon, + app, + true, + 120_000, + 500_000, + ) + }) - requestLog := FindLatestRandomnessRequestedLog(tt, uni.rootContract, vrfkey.PublicKey.MustHash()) - s, err := proof.BigToSeed(requestLog.PreSeed()) - require.NoError(t, err) - extraArgs, err := extraargs.ExtraArgsV1(false) - require.NoError(t, err) - proof, rc, err := proof.GenerateProofResponseV2Plus(app.GetKeyStore().VRF(), vrfkey.ID(), proof.PreSeedDataV2Plus{ - PreSeed: s, - BlockHash: requestLog.Raw().BlockHash, - BlockNum: requestLog.Raw().BlockNumber, - SubId: subId, - CallbackGasLimit: uint32(gasRequested), - NumWords: uint32(nw), - Sender: carolContractAddress, - ExtraArgs: extraArgs, + t.Run("link payment", func(tt *testing.T) { + requestAndEstimateFulfillmentCost( + t, + subID, + carol, + vrfkey, + uint16(requestedIncomingConfs), + uint32(gasRequested), + uint32(nw), + carolContract, + carolContractAddress, + uni.coordinatorV2UniverseCommon, + app, + false, + 120_000, + 500_000, + ) }) - require.NoError(tt, err) - nonProxiedConsumerGasEstimate = estimateGas(tt, uni.backend, common.Address{}, - uni.rootContractAddress, uni.coordinatorABI, - "fulfillRandomWords", proof, rc) - t.Log("non-proxied consumer fulfillment gas estimate:", nonProxiedConsumerGasEstimate) - // Establish very rough bounds on fulfillment cost - assert.Greater(tt, nonProxiedConsumerGasEstimate, uint64(120_000)) - assert.Less(tt, nonProxiedConsumerGasEstimate, uint64(500_000)) }) t.Run("proxied consumer", func(tt *testing.T) { @@ -834,41 +1057,27 @@ func TestVRFV2PlusIntegration_FulfillmentCost(t *testing.T) { _, err = consumerContract.CreateSubscriptionAndFund(consumerOwner, assets.Ether(5).ToInt()) require.NoError(t, err) uni.backend.Commit() - subId, err := consumerContract.SSubId(nil) + subID, err := consumerContract.SSubId(nil) require.NoError(t, err) gasRequested := 50_000 nw := 1 requestedIncomingConfs := 3 - _, err = consumerContract.RequestRandomness(consumerOwner, vrfkey.PublicKey.MustHash(), subId, uint16(requestedIncomingConfs), uint32(gasRequested), uint32(nw), false) - require.NoError(t, err) - for i := 0; i < requestedIncomingConfs; i++ { - uni.backend.Commit() - } - - requestLog := FindLatestRandomnessRequestedLog(t, uni.rootContract, vrfkey.PublicKey.MustHash()) - require.Equal(tt, subId, requestLog.SubID()) - s, err := proof.BigToSeed(requestLog.PreSeed()) - require.NoError(t, err) - extraArgs, err := extraargs.ExtraArgsV1(false) - require.NoError(t, err) - proof, rc, err := proof.GenerateProofResponseV2Plus(app.GetKeyStore().VRF(), vrfkey.ID(), proof.PreSeedDataV2Plus{ - PreSeed: s, - BlockHash: requestLog.Raw().BlockHash, - BlockNum: requestLog.Raw().BlockNumber, - SubId: subId, - CallbackGasLimit: uint32(gasRequested), - NumWords: uint32(nw), - Sender: consumerContractAddress, - ExtraArgs: extraArgs, - }) - require.NoError(t, err) - proxiedConsumerGasEstimate = estimateGas(t, uni.backend, common.Address{}, - uni.rootContractAddress, uni.coordinatorABI, - "fulfillRandomWords", proof, rc) - t.Log("proxied consumer fulfillment gas estimate", proxiedConsumerGasEstimate) - // Establish very rough bounds on fulfillment cost - assert.Greater(t, proxiedConsumerGasEstimate, uint64(120_000)) - assert.Less(t, proxiedConsumerGasEstimate, uint64(500_000)) + requestAndEstimateFulfillmentCost( + t, + subID, + consumerOwner, + vrfkey, + uint16(requestedIncomingConfs), + uint32(gasRequested), + uint32(nw), + consumerContract, + consumerContractAddress, + uni.coordinatorV2UniverseCommon, + app, + false, + 120_000, + 500_000, + ) }) } @@ -880,3 +1089,247 @@ func AssertEthBalances(t *testing.T, backend *backends.SimulatedBackend, address assert.Equal(t, balances[i].String(), b.String(), "invalid balance for %v", a) } } + +func setupSubscriptionAndFund( + t *testing.T, + uni coordinatorV2UniverseCommon, + consumer *bind.TransactOpts, + consumerContract vrftesthelpers.VRFConsumerContract, + consumerAddress common.Address, + linkAmount *big.Int, + nativeAmount *big.Int) *big.Int { + _, err := uni.rootContract.CreateSubscription(consumer) + require.NoError(t, err) + uni.backend.Commit() + + iter, err := uni.rootContract.FilterSubscriptionCreated(nil, nil) + require.NoError(t, err) + require.True(t, iter.Next(), "could not find SubscriptionCreated event for subID") + subID := iter.Event().SubID() + + _, err = consumerContract.SetSubID(consumer, subID) + require.NoError(t, err) + + _, err = uni.rootContract.AddConsumer(consumer, subID, consumerAddress) + require.NoError(t, err, "failed to add consumer") + uni.backend.Commit() + + b, err := utils.ABIEncode(`[{"type":"uint256"}]`, subID) + require.NoError(t, err) + _, err = uni.linkContract.TransferAndCall( + uni.sergey, uni.rootContractAddress, linkAmount, b) + require.NoError(t, err, "failed to fund sub") + uni.backend.Commit() + + _, err = uni.rootContract.FundSubscriptionWithEth(consumer, subID, nativeAmount) + require.NoError(t, err, "failed to fund sub with native") + uni.backend.Commit() + + return subID +} + +func TestVRFV2PlusIntegration_Migration(t *testing.T) { + t.Parallel() + ownerKey := cltest.MustGenerateRandomKey(t) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + key1 := cltest.MustGenerateRandomKey(t) + gasLanePriceWei := assets.GWei(10) + config, db := heavyweight.FullTestDBV2(t, "vrfv2plus_migration", func(c *chainlink.Config, s *chainlink.Secrets) { + simulatedOverrides(t, assets.GWei(10), toml.KeySpecific{ + // Gas lane. + Key: ptr(key1.EIP55Address), + GasEstimator: toml.KeySpecificGasEstimator{PriceMax: gasLanePriceWei}, + })(c, s) + c.EVM[0].GasEstimator.LimitDefault = ptr[uint32](5_000_000) + c.EVM[0].MinIncomingConfirmations = ptr[uint32](2) + }) + app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, config, uni.backend, ownerKey, key1) + + // Create a subscription and fund with 5 LINK. + consumerContract := uni.consumerContracts[0] + consumer := uni.vrfConsumers[0] + consumerAddress := uni.consumerContractAddresses[0] + + subID := setupSubscriptionAndFund( + t, + uni.coordinatorV2UniverseCommon, + consumer, + consumerContract, + consumerAddress, + new(big.Int).SetUint64(5e18), + new(big.Int).SetUint64(3e18), + ) + + // Fund gas lane. + sendEth(t, ownerKey, uni.backend, key1.Address, 10) + require.NoError(t, app.Start(testutils.Context(t))) + + // Create VRF job using key1 and key2 on the same gas lane. + jbs := createVRFJobs( + t, + [][]ethkey.KeyV2{{key1}}, + app, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + uni.coordinatorV2UniverseCommon, + nil, + vrfcommon.V2Plus, + false, + gasLanePriceWei) + keyHash := jbs[0].VRFSpec.PublicKey.MustHash() + + // Make some randomness requests. + numWords := uint32(2) + + requestID, _ := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, uni.rootContract, uni.backend, false) + + // Wait for fulfillment to be queued. + gomega.NewGomegaWithT(t).Eventually(func() bool { + uni.backend.Commit() + runs, err := app.PipelineORM().GetAllRuns() + require.NoError(t, err) + t.Log("runs", len(runs)) + return len(runs) == 1 + }, testutils.WaitTimeout(t), time.Second).Should(gomega.BeTrue()) + + mine(t, requestID, subID, uni.backend, db, vrfcommon.V2Plus) + assertRandomWordsFulfilled(t, requestID, true, uni.rootContract, false) + + // Assert correct number of random words sent by coordinator. + assertNumRandomWords(t, consumerContract, numWords) + + rw, err := consumerContract.SRandomWords(nil, big.NewInt(0)) + require.NoError(t, err) + + subV1, err := uni.rootContract.GetSubscription(nil, subID) + require.NoError(t, err) + + _, err = uni.rootContract.Migrate(consumer, subID, uni.migrationTestCoordinatorAddress) + require.NoError(t, err) + uni.backend.Commit() + + subV2, err := uni.migrationTestCoordinator.GetSubscription(nil, subID) + require.NoError(t, err) + + totalLinkBalance, err := uni.migrationTestCoordinator.STotalLinkBalance(nil) + require.NoError(t, err) + totalNativeBalance, err := uni.migrationTestCoordinator.STotalNativeBalance(nil) + require.NoError(t, err) + linkContractBalance, err := uni.linkContract.BalanceOf(nil, uni.migrationTestCoordinatorAddress) + require.NoError(t, err) + balance, err := uni.backend.BalanceAt(testutils.Context(t), uni.migrationTestCoordinatorAddress, nil) + require.NoError(t, err) + + require.Equal(t, subV1.Balance(), totalLinkBalance) + require.Equal(t, subV1.EthBalance(), totalNativeBalance) + require.Equal(t, subV1.Balance(), linkContractBalance) + require.Equal(t, subV1.EthBalance(), balance) + + require.Equal(t, subV1.Balance(), subV2.LinkBalance) + require.Equal(t, subV1.EthBalance(), subV2.NativeBalance) + require.Equal(t, subV1.Owner(), subV2.Owner) + require.Equal(t, len(subV1.Consumers()), len(subV2.Consumers)) + for i, c := range subV1.Consumers() { + require.Equal(t, c, subV2.Consumers[i]) + } + + minRequestConfirmations := uint16(2) + requestID2, rw2 := requestRandomnessAndValidate( + t, + consumer, + consumerContract, + keyHash, + subID, + minRequestConfirmations, + 50_000, + numWords, + uni, + true, + ) + require.NotEqual(t, requestID, requestID2) + require.NotEqual(t, rw, rw2) + requestID3, rw3 := requestRandomnessAndValidate( + t, + consumer, + consumerContract, + keyHash, + subID, + minRequestConfirmations, + 50_000, + numWords, + uni, + false, + ) + require.NotEqual(t, requestID2, requestID3) + require.NotEqual(t, rw2, rw3) +} + +func requestRandomnessAndValidate(t *testing.T, + consumer *bind.TransactOpts, + consumerContract vrftesthelpers.VRFConsumerContract, + keyHash common.Hash, + subID *big.Int, + minConfs uint16, + gas, numWords uint32, + uni coordinatorV2PlusUniverse, + nativePayment bool) (*big.Int, *big.Int) { + _, err := consumerContract.RequestRandomness( + consumer, + keyHash, + subID, + minConfs, + gas, + numWords, + nativePayment, // test link payment works after migration + ) + require.NoError(t, err) + uni.backend.Commit() + + requestID, err := consumerContract.SRequestId(nil) + require.NoError(t, err) + + _, err = uni.migrationTestCoordinator.FulfillRandomWords(uni.neil, requestID) + require.NoError(t, err) + uni.backend.Commit() + + rw, err := consumerContract.SRandomWords(nil, big.NewInt(0)) + require.NoError(t, err) + + return requestID, rw +} + +func TestVRFV2PlusIntegration_CancelSubscription(t *testing.T) { + key := cltest.MustGenerateRandomKey(t) + uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) + consumer := uni.vrfConsumers[0] + consumerContract := uni.consumerContracts[0] + consumerContractAddress := uni.consumerContractAddresses[0] + linkAmount := new(big.Int).SetUint64(5e18) + nativeAmount := new(big.Int).SetUint64(3e18) + subID := setupSubscriptionAndFund( + t, + uni.coordinatorV2UniverseCommon, + consumer, + consumerContract, + consumerContractAddress, + linkAmount, + nativeAmount, + ) + + linkBalanceBeforeCancel, err := uni.linkContract.BalanceOf(nil, uni.neil.From) + require.NoError(t, err) + nativeBalanceBeforeCancel, err := uni.backend.BalanceAt(testutils.Context(t), uni.neil.From, nil) + require.NoError(t, err) + + // non-owner cannot cancel subscription + _, err = uni.rootContract.CancelSubscription(uni.neil, subID, consumer.From) + require.Error(t, err) + + _, err = uni.rootContract.CancelSubscription(consumer, subID, uni.neil.From) + require.NoError(t, err) + uni.backend.Commit() + + AssertLinkBalance(t, uni.linkContract, uni.neil.From, linkBalanceBeforeCancel.Add(linkBalanceBeforeCancel, linkAmount)) + AssertNativeBalance(t, uni.backend, uni.neil.From, nativeBalanceBeforeCancel.Add(nativeBalanceBeforeCancel, nativeAmount)) +} diff --git a/core/services/vrf/v2/integration_v2_test.go b/core/services/vrf/v2/integration_v2_test.go index c2cbac95ec6..f0747baf800 100644 --- a/core/services/vrf/v2/integration_v2_test.go +++ b/core/services/vrf/v2/integration_v2_test.go @@ -477,9 +477,15 @@ func subscribeVRF( consumerContract vrftesthelpers.VRFConsumerContract, coordinator v22.CoordinatorV2_X, backend *backends.SimulatedBackend, - fundingJuels *big.Int, + fundingAmount *big.Int, + nativePayment bool, ) (v22.Subscription, *big.Int) { - _, err := consumerContract.CreateSubscriptionAndFund(author, fundingJuels) + var err error + if nativePayment { + _, err = consumerContract.CreateSubscriptionAndFundNative(author, fundingAmount) + } else { + _, err = consumerContract.CreateSubscriptionAndFund(author, fundingAmount) + } require.NoError(t, err) backend.Commit() @@ -488,6 +494,13 @@ func subscribeVRF( sub, err := coordinator.GetSubscription(nil, subID) require.NoError(t, err) + + if nativePayment { + require.Equal(t, fundingAmount.String(), sub.EthBalance().String()) + } else { + require.Equal(t, fundingAmount.String(), sub.Balance().String()) + } + return sub, subID } @@ -635,6 +648,7 @@ func requestRandomnessAndAssertRandomWordsRequestedEvent( cbGasLimit uint32, coordinator v22.CoordinatorV2_X, backend *backends.SimulatedBackend, + nativePayment bool, ) (requestID *big.Int, requestBlockNumber uint64) { minRequestConfirmations := uint16(2) _, err := vrfConsumerHandle.RequestRandomness( @@ -644,7 +658,7 @@ func requestRandomnessAndAssertRandomWordsRequestedEvent( minRequestConfirmations, cbGasLimit, numWords, - false, + nativePayment, ) require.NoError(t, err) backend.Commit() @@ -667,6 +681,7 @@ func requestRandomnessAndAssertRandomWordsRequestedEvent( require.Equal(t, cbGasLimit, event.CallbackGasLimit(), "callback gas limit of event and of request not equal") require.Equal(t, minRequestConfirmations, event.MinimumRequestConfirmations(), "min request confirmations of event and of request not equal") require.Equal(t, numWords, event.NumWords(), "num words of event and of request not equal") + require.Equal(t, nativePayment, event.NativePayment()) return requestID, event.Raw().BlockNumber } @@ -679,13 +694,13 @@ func subscribeAndAssertSubscriptionCreatedEvent( vrfConsumerHandle vrftesthelpers.VRFConsumerContract, consumerOwner *bind.TransactOpts, consumerContractAddress common.Address, - fundingJuels *big.Int, + fundingAmount *big.Int, coordinator v22.CoordinatorV2_X, backend *backends.SimulatedBackend, + nativePayment bool, ) *big.Int { // Create a subscription and fund with LINK. - sub, subID := subscribeVRF(t, consumerOwner, vrfConsumerHandle, coordinator, backend, fundingJuels) - require.Equal(t, fundingJuels.String(), sub.Balance().String()) + _, subID := subscribeVRF(t, consumerOwner, vrfConsumerHandle, coordinator, backend, fundingAmount, nativePayment) // Assert the subscription event in the coordinator contract. iter, err := coordinator.FilterSubscriptionCreated(nil, []*big.Int{subID}) @@ -708,6 +723,7 @@ func assertRandomWordsFulfilled( requestID *big.Int, expectedSuccess bool, coordinator v22.CoordinatorV2_X, + nativePayment bool, ) (rwfe v22.RandomWordsFulfilled) { // Check many times in case there are delays processing the event // this could happen occasionally and cause flaky tests. @@ -719,6 +735,7 @@ func assertRandomWordsFulfilled( for filter.Next() { require.Equal(t, expectedSuccess, filter.Event().Success(), "fulfillment event success not correct, expected: %+v, actual: %+v", expectedSuccess, filter.Event().Success()) require.Equal(t, requestID, filter.Event().RequestID()) + require.Equal(t, nativePayment, filter.Event().NativePayment()) found = true rwfe = filter.Event() } @@ -853,6 +870,7 @@ func TestVRFV2Integration_SingleConsumer_HappyPath_BatchFulfillment(t *testing.T 5, // number of requests to send false, // don't send big callback vrfcommon.V2, + false, ) } @@ -874,6 +892,7 @@ func TestVRFV2Integration_SingleConsumer_HappyPath_BatchFulfillment_BigGasCallba 5, // number of requests to send true, // send big callback vrfcommon.V2, + false, ) } @@ -893,6 +912,7 @@ func TestVRFV2Integration_SingleConsumer_HappyPath(t *testing.T) { uni.batchCoordinatorContractAddress, ptr(uni.vrfOwnerAddress), vrfcommon.V2, + false, func(t *testing.T, coordinator v22.CoordinatorV2_X, rwfe v22.RandomWordsFulfilled, expectedSubID *big.Int) { require.PanicsWithValue(t, "VRF V2 RandomWordsFulfilled does not implement SubID", func() { rwfe.SubID() @@ -1057,6 +1077,7 @@ func TestVRFV2Integration_SingleConsumer_EIP150_HappyPath(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2, + false, ) } @@ -1071,6 +1092,7 @@ func TestVRFV2Integration_SingleConsumer_EIP150_Revert(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2, + false, ) } @@ -1170,7 +1192,7 @@ func TestVRFV2Integration_SingleConsumer_Wrapper(t *testing.T) { mine(t, requestID, new(big.Int).SetUint64(wrapperSubID), uni.backend, db, vrfcommon.V2) // Assert correct state of RandomWordsFulfilled event. - assertRandomWordsFulfilled(t, requestID, true, uni.rootContract) + assertRandomWordsFulfilled(t, requestID, true, uni.rootContract, false) t.Log("Done!") } @@ -1250,7 +1272,7 @@ func TestVRFV2Integration_Wrapper_High_Gas(t *testing.T) { mine(t, requestID, new(big.Int).SetUint64(wrapperSubID), uni.backend, db, vrfcommon.V2) // Assert correct state of RandomWordsFulfilled event. - assertRandomWordsFulfilled(t, requestID, true, uni.rootContract) + assertRandomWordsFulfilled(t, requestID, true, uni.rootContract, false) t.Log("Done!") } @@ -1271,6 +1293,7 @@ func TestVRFV2Integration_SingleConsumer_NeedsBlockhashStore(t *testing.T) { uni.batchCoordinatorContractAddress, ptr(uni.vrfOwnerAddress), vrfcommon.V2, + false, ) } @@ -1290,6 +1313,7 @@ func TestVRFV2Integration_SingleConsumer_BlockHeaderFeeder(t *testing.T) { uni.batchCoordinatorContractAddress, ptr(uni.vrfOwnerAddress), vrfcommon.V2, + false, ) } @@ -1311,6 +1335,7 @@ func TestVRFV2Integration_SingleConsumer_NeedsTopUp(t *testing.T) { assets.Ether(1).ToInt(), // initial funding of 1 LINK assets.Ether(100).ToInt(), // top up of 100 LINK vrfcommon.V2, + false, ) } @@ -1324,6 +1349,7 @@ func TestVRFV2Integration_SingleConsumer_BigGasCallback_Sandwich(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2, + false, ) } @@ -1337,6 +1363,7 @@ func TestVRFV2Integration_SingleConsumer_MultipleGasLanes(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2, + false, ) } @@ -1350,6 +1377,7 @@ func TestVRFV2Integration_SingleConsumer_AlwaysRevertingCallback_StillFulfilled( uni.batchCoordinatorContractAddress, false, vrfcommon.V2, + false, ) } @@ -1363,6 +1391,7 @@ func TestVRFV2Integration_ConsumerProxy_HappyPath(t *testing.T) { uni.batchCoordinatorContractAddress, false, vrfcommon.V2, + false, ) } @@ -2128,12 +2157,22 @@ func FindLatestRandomnessRequestedLog(t *testing.T, return rf[latest] } +func AssertLinkBalance(t *testing.T, linkContract *link_token_interface.LinkToken, address common.Address, balance *big.Int) { + b, err := linkContract.BalanceOf(nil, address) + require.NoError(t, err) + assert.Equal(t, balance.String(), b.String(), "invalid balance for %v", address) +} + +func AssertNativeBalance(t *testing.T, backend *backends.SimulatedBackend, address common.Address, balance *big.Int) { + b, err := backend.BalanceAt(testutils.Context(t), address, nil) + require.NoError(t, err) + assert.Equal(t, balance.String(), b.String(), "invalid balance for %v", address) +} + func AssertLinkBalances(t *testing.T, linkContract *link_token_interface.LinkToken, addresses []common.Address, balances []*big.Int) { require.Equal(t, len(addresses), len(balances)) for i, a := range addresses { - b, err := linkContract.BalanceOf(nil, a) - require.NoError(t, err) - assert.Equal(t, balances[i].String(), b.String(), "invalid balance for %v", a) + AssertLinkBalance(t, linkContract, a, balances[i]) } } diff --git a/core/services/vrf/v2/listener_v2.go b/core/services/vrf/v2/listener_v2.go index 37267742c85..e653cf67550 100644 --- a/core/services/vrf/v2/listener_v2.go +++ b/core/services/vrf/v2/listener_v2.go @@ -97,6 +97,8 @@ const ( AND CAST(meta->>'GlobalSubId' AS NUMERIC) = $2 AND state IN ('unconfirmed', 'unstarted', 'in_progress') GROUP BY meta->>'GlobalSubId'` + + CouldNotDetermineIfLogConsumedMsg = "Could not determine if log was already consumed" ) type errPossiblyInsufficientFunds struct{} @@ -235,7 +237,7 @@ type listenerV2 struct { // Wait group to wait on all goroutines to shut down. wg *sync.WaitGroup - // aggregator client to get link/eth feed prices from chain. + // aggregator client to get link/eth feed prices from chain. Can be nil for VRF V2 plus aggregator aggregator_v3_interface.AggregatorV3InterfaceInterface // deduper prevents processing duplicate requests from the log broadcaster. @@ -389,8 +391,8 @@ func (lsn *listenerV2) pruneConfirmedRequestCounts() { // Determine a set of logs that are confirmed // and the subscription has sufficient balance to fulfill, // given a eth call with the max gas price. -// Note we have to consider the pending reqs already in the txm as already "spent" link, -// using a max link consumed in their metadata. +// Note we have to consider the pending reqs already in the txm as already "spent" link or native, +// using a max link or max native consumed in their metadata. // A user will need a minBalance capable of fulfilling a single req at the max gas price or nothing will happen. // This is acceptable as users can choose different keyhashes which have different max gas prices. // Other variables which can change the bill amount between our eth call simulation and tx execution: @@ -604,6 +606,7 @@ func (lsn *listenerV2) processRequestsPerSubBatchHelper( startBalanceNoReserved *big.Int, reqs []pendingRequest, subIsActive bool, + nativePayment bool, ) (processed map[string]struct{}) { start := time.Now() processed = make(map[string]struct{}) @@ -631,6 +634,7 @@ func (lsn *listenerV2) processRequestsPerSubBatchHelper( "startBalanceNoReserved", startBalanceNoReserved.String(), "batchMaxGas", batchMaxGas, "subIsActive", subIsActive, + "nativePayment", nativePayment, ) defer func() { @@ -736,7 +740,7 @@ func (lsn *listenerV2) processRequestsPerSubBatchHelper( } if startBalanceNoReserved.Cmp(p.fundsNeeded) < 0 && errors.Is(p.err, errPossiblyInsufficientFunds{}) { - ll.Infow("Insufficient link balance to fulfill a request based on estimate, breaking", "err", p.err) + ll.Infow("Insufficient balance to fulfill a request based on estimate, breaking", "err", p.err) outOfBalance = true // break out of this inner loop to process the currently constructed batch @@ -834,11 +838,11 @@ func (lsn *listenerV2) processRequestsPerSubBatch( wg.Add(2) go func() { defer wg.Done() - nativeProcessed = lsn.processRequestsPerSubBatchHelper(ctx, subID, startEthBalance, startBalanceNoReserveEth, nativeRequests, subIsActive) + nativeProcessed = lsn.processRequestsPerSubBatchHelper(ctx, subID, startEthBalance, startBalanceNoReserveEth, nativeRequests, subIsActive, true) }() go func() { defer wg.Done() - linkProcessed = lsn.processRequestsPerSubBatchHelper(ctx, subID, startLinkBalance, startBalanceNoReserveLink, linkRequests, subIsActive) + linkProcessed = lsn.processRequestsPerSubBatchHelper(ctx, subID, startLinkBalance, startBalanceNoReserveLink, linkRequests, subIsActive, false) }() wg.Wait() // combine the processed link and native requests into the processed map @@ -958,6 +962,7 @@ func (lsn *listenerV2) processRequestsPerSubHelper( startBalanceNoReserved *big.Int, reqs []pendingRequest, subIsActive bool, + nativePayment bool, ) (processed map[string]struct{}) { start := time.Now() processed = make(map[string]struct{}) @@ -968,6 +973,7 @@ func (lsn *listenerV2) processRequestsPerSubHelper( "startBalance", startBalance.String(), "startBalanceNoReserved", startBalanceNoReserved.String(), "subIsActive", subIsActive, + "nativePayment", nativePayment, ) defer func() { @@ -1061,7 +1067,7 @@ func (lsn *listenerV2) processRequestsPerSubHelper( } if startBalanceNoReserved.Cmp(p.fundsNeeded) < 0 { - ll.Infow("Insufficient link balance to fulfill a request based on estimate, returning", "err", p.err) + ll.Infow("Insufficient balance to fulfill a request based on estimate, returning", "err", p.err) return processed } @@ -1082,7 +1088,7 @@ func (lsn *listenerV2) processRequestsPerSubHelper( if startBalanceNoReserved.Cmp(p.maxFee) < 0 { // Insufficient funds, have to wait for a user top up. Leave it unprocessed for now - ll.Infow("Insufficient link balance to fulfill a request, returning") + ll.Infow("Insufficient balance to fulfill a request, returning") return processed } @@ -1214,7 +1220,8 @@ func (lsn *listenerV2) processRequestsPerSub( startEthBalance, startBalanceNoReserveEth, nativeRequests, - subIsActive) + subIsActive, + true) }() go func() { defer wg.Done() @@ -1224,7 +1231,8 @@ func (lsn *listenerV2) processRequestsPerSub( startLinkBalance, startBalanceNoReserveLink, linkRequests, - subIsActive) + subIsActive, + false) }() wg.Wait() // combine the native and link processed requests into the processed map @@ -1570,7 +1578,27 @@ func (lsn *listenerV2) handleLog(lb log.Broadcast, minConfs uint32) { lsn.l.Debugw("Received fulfilled log", "reqID", v.RequestId, "success", v.Success) consumed, err := lsn.logBroadcaster.WasAlreadyConsumed(lb) if err != nil { - lsn.l.Errorw("Could not determine if log was already consumed", "err", err, "txHash", lb.RawLog().TxHash) + lsn.l.Errorw(CouldNotDetermineIfLogConsumedMsg, "err", err, "txHash", lb.RawLog().TxHash) + return + } else if consumed { + return + } + lsn.respCountMu.Lock() + lsn.respCount[v.RequestId.String()]++ + lsn.respCountMu.Unlock() + lsn.blockNumberToReqID.Insert(fulfilledReqV2{ + blockNumber: v.Raw.BlockNumber, + reqID: v.RequestId.String(), + }) + lsn.markLogAsConsumed(lb) + return + } + + if v, ok := lb.DecodedLog().(*vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsFulfilled); ok { + lsn.l.Debugw("Received fulfilled log", "reqID", v.RequestId, "success", v.Success) + consumed, err := lsn.logBroadcaster.WasAlreadyConsumed(lb) + if err != nil { + lsn.l.Errorw(CouldNotDetermineIfLogConsumedMsg, "err", err, "txHash", lb.RawLog().TxHash) return } else if consumed { return @@ -1591,7 +1619,7 @@ func (lsn *listenerV2) handleLog(lb log.Broadcast, minConfs uint32) { lsn.l.Errorw("Failed to parse log", "err", err, "txHash", lb.RawLog().TxHash) consumed, err := lsn.logBroadcaster.WasAlreadyConsumed(lb) if err != nil { - lsn.l.Errorw("Could not determine if log was already consumed", "err", err, "txHash", lb.RawLog().TxHash) + lsn.l.Errorw(CouldNotDetermineIfLogConsumedMsg, "err", err, "txHash", lb.RawLog().TxHash) return } else if consumed { return @@ -1670,7 +1698,7 @@ func uniqueReqs(reqs []pendingRequest) int { } // GasProofVerification is an upper limit on the gas used for verifying the VRF proof on-chain. -// It can be used to estimate the amount of LINK needed to fulfill a request. +// It can be used to estimate the amount of LINK or native needed to fulfill a request. const GasProofVerification uint32 = 200_000 // EstimateFeeJuels estimates the amount of link needed to fulfill a request diff --git a/core/services/vrf/v2/listener_v2_test.go b/core/services/vrf/v2/listener_v2_test.go index cf18f74134d..dd63ec8208e 100644 --- a/core/services/vrf/v2/listener_v2_test.go +++ b/core/services/vrf/v2/listener_v2_test.go @@ -2,6 +2,7 @@ package v2 import ( "math/big" + "sync" "testing" "time" @@ -10,15 +11,19 @@ import ( "github.com/google/uuid" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" + "github.com/theodesp/go-heaps/pairing" "github.com/smartcontractkit/sqlx" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/vrf/vrfcommon" txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" txmgrtypes "github.com/smartcontractkit/chainlink/v2/common/txmgr/types" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -418,3 +423,73 @@ func TestListener_Backoff(t *testing.T) { }) } } + +func TestListener_handleLog(tt *testing.T) { + lb := mocks.NewBroadcaster(tt) + chainID := int64(2) + minConfs := uint32(3) + blockNumber := uint64(5) + requestID := int64(6) + tt.Run("v2", func(t *testing.T) { + j, err := vrfcommon.ValidatedVRFSpec(testspecs.GenerateVRFSpec(testspecs.VRFSpecParams{ + VRFVersion: vrfcommon.V2, + RequestedConfsDelay: 10, + FromAddresses: []string{"0xF2982b7Ef6E3D8BB738f8Ea20502229781f6Ad97"}, + }).Toml()) + require.NoError(t, err) + fulfilledLog := vrf_coordinator_v2.VRFCoordinatorV2RandomWordsFulfilled{ + RequestId: big.NewInt(requestID), + Raw: types.Log{BlockNumber: blockNumber}, + } + log := log.NewLogBroadcast(types.Log{}, *big.NewInt(chainID), &fulfilledLog) + lb.On("WasAlreadyConsumed", log).Return(false, nil).Once() + lb.On("MarkConsumed", log).Return(nil).Once() + defer lb.AssertExpectations(t) + listener := &listenerV2{ + respCount: map[string]uint64{}, + job: j, + blockNumberToReqID: pairing.New(), + latestHeadMu: sync.RWMutex{}, + logBroadcaster: lb, + l: logger.TestLogger(t), + } + listener.handleLog(log, minConfs) + require.Equal(t, listener.respCount[fulfilledLog.RequestId.String()], uint64(1)) + req, ok := listener.blockNumberToReqID.FindMin().(fulfilledReqV2) + require.True(t, ok) + require.Equal(t, req.blockNumber, blockNumber) + require.Equal(t, req.reqID, "6") + }) + + tt.Run("v2 plus", func(t *testing.T) { + j, err := vrfcommon.ValidatedVRFSpec(testspecs.GenerateVRFSpec(testspecs.VRFSpecParams{ + VRFVersion: vrfcommon.V2Plus, + RequestedConfsDelay: 10, + FromAddresses: []string{"0xF2982b7Ef6E3D8BB738f8Ea20502229781f6Ad97"}, + }).Toml()) + require.NoError(t, err) + fulfilledLog := vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsFulfilled{ + RequestId: big.NewInt(requestID), + Raw: types.Log{BlockNumber: blockNumber}, + } + log := log.NewLogBroadcast(types.Log{}, *big.NewInt(chainID), &fulfilledLog) + lb.On("WasAlreadyConsumed", log).Return(false, nil).Once() + lb.On("MarkConsumed", log).Return(nil).Once() + defer lb.AssertExpectations(t) + listener := &listenerV2{ + respCount: map[string]uint64{}, + job: j, + blockNumberToReqID: pairing.New(), + latestHeadMu: sync.RWMutex{}, + logBroadcaster: lb, + l: logger.TestLogger(t), + } + listener.handleLog(log, minConfs) + require.Equal(t, listener.respCount[fulfilledLog.RequestId.String()], uint64(1)) + req, ok := listener.blockNumberToReqID.FindMin().(fulfilledReqV2) + require.True(t, ok) + require.Equal(t, req.blockNumber, blockNumber) + require.Equal(t, req.reqID, "6") + }) + +} diff --git a/core/services/vrf/v2/listener_v2_types_test.go b/core/services/vrf/v2/listener_v2_types_test.go index 2e27980dd41..11bb7c98769 100644 --- a/core/services/vrf/v2/listener_v2_types_test.go +++ b/core/services/vrf/v2/listener_v2_types_test.go @@ -10,6 +10,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log/mocks" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" "github.com/smartcontractkit/chainlink/v2/core/services/vrf/vrfcommon" @@ -54,3 +55,43 @@ func Test_BatchFulfillments_AddRun(t *testing.T) { }, fromAddress) require.Len(t, bfs.fulfillments, 2) } + +func Test_BatchFulfillments_AddRun_V2Plus(t *testing.T) { + batchLimit := uint32(2500) + bfs := newBatchFulfillments(batchLimit, vrfcommon.V2Plus) + fromAddress := testutils.NewAddress() + for i := 0; i < 4; i++ { + bfs.addRun(vrfPipelineResult{ + gasLimit: 500, + req: pendingRequest{ + req: NewV2PlusRandomWordsRequested(&vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsRequested{ + RequestId: big.NewInt(1), + Raw: types.Log{ + TxHash: common.HexToHash("0xd8d7ecc4800d25fa53ce0372f13a416d98907a7ef3d8d3bdd79cf4fe75529c65"), + }, + }), + lb: mocks.NewBroadcast(t), + }, + run: pipeline.NewRun(pipeline.Spec{}, pipeline.Vars{}), + }, fromAddress) + require.Len(t, bfs.fulfillments, 1) + } + + require.Equal(t, uint32(2000), bfs.fulfillments[0].totalGasLimit) + + // This addition should create and add a new batch + bfs.addRun(vrfPipelineResult{ + gasLimit: 500, + req: pendingRequest{ + req: NewV2PlusRandomWordsRequested(&vrf_coordinator_v2plus.VRFCoordinatorV2PlusRandomWordsRequested{ + RequestId: big.NewInt(1), + Raw: types.Log{ + TxHash: common.HexToHash("0xd8d7ecc4800d25fa53ce0372f13a416d98907a7ef3d8d3bdd79cf4fe75529c65"), + }, + }), + lb: mocks.NewBroadcast(t), + }, + run: pipeline.NewRun(pipeline.Spec{}, pipeline.Vars{}), + }, fromAddress) + require.Len(t, bfs.fulfillments, 2) +} diff --git a/core/services/vrf/vrftesthelpers/consumer_v2.go b/core/services/vrf/vrftesthelpers/consumer_v2.go index 5d647ec3abb..ec3d727f7ab 100644 --- a/core/services/vrf/vrftesthelpers/consumer_v2.go +++ b/core/services/vrf/vrftesthelpers/consumer_v2.go @@ -25,13 +25,16 @@ var ( // the example contracts used for the integration tests. type VRFConsumerContract interface { CreateSubscriptionAndFund(opts *bind.TransactOpts, fundingJuels *big.Int) (*gethtypes.Transaction, error) + CreateSubscriptionAndFundNative(opts *bind.TransactOpts, fundingAmount *big.Int) (*gethtypes.Transaction, error) SSubId(opts *bind.CallOpts) (*big.Int, error) SRequestId(opts *bind.CallOpts) (*big.Int, error) RequestRandomness(opts *bind.TransactOpts, keyHash [32]byte, subID *big.Int, minReqConfs uint16, callbackGasLimit uint32, numWords uint32, payInEth bool) (*gethtypes.Transaction, error) SRandomWords(opts *bind.CallOpts, randomwordIdx *big.Int) (*big.Int, error) TopUpSubscription(opts *bind.TransactOpts, amount *big.Int) (*gethtypes.Transaction, error) + TopUpSubscriptionNative(opts *bind.TransactOpts, amount *big.Int) (*gethtypes.Transaction, error) SGasAvailable(opts *bind.CallOpts) (*big.Int, error) UpdateSubscription(opts *bind.TransactOpts, consumers []common.Address) (*gethtypes.Transaction, error) + SetSubID(opts *bind.TransactOpts, subID *big.Int) (*gethtypes.Transaction, error) } type ConsumerType string @@ -298,3 +301,30 @@ func (c *vrfConsumerContract) UpdateSubscription(opts *bind.TransactOpts, consum } return nil, errors.New("UpdateSubscription is not supported") } + +func (c *vrfConsumerContract) SetSubID(opts *bind.TransactOpts, subID *big.Int) (*gethtypes.Transaction, error) { + if c.consumerType == VRFV2PlusConsumer { + return c.vrfV2PlusConsumer.SetSubId(opts, subID) + } + return nil, errors.New("SetSubID is not supported") +} + +func (c *vrfConsumerContract) CreateSubscriptionAndFundNative(opts *bind.TransactOpts, fundingAmount *big.Int) (*gethtypes.Transaction, error) { + if c.consumerType == VRFV2PlusConsumer { + // copy object to not mutate original opts + o := *opts + o.Value = fundingAmount + return c.vrfV2PlusConsumer.CreateSubscriptionAndFundNative(&o) + } + return nil, errors.New("CreateSubscriptionAndFundNative is not supported") +} + +func (c *vrfConsumerContract) TopUpSubscriptionNative(opts *bind.TransactOpts, amount *big.Int) (*gethtypes.Transaction, error) { + if c.consumerType == VRFV2PlusConsumer { + // copy object to not mutate original opts + o := *opts + o.Value = amount + return c.vrfV2PlusConsumer.TopUpSubscriptionNative(&o) + } + return nil, errors.New("TopUpSubscriptionNative is not supported") +} From 1517911e4184102cf14fc4198f3fefd5cfef5a34 Mon Sep 17 00:00:00 2001 From: Lukasz <120112546+lukaszcl@users.noreply.github.com> Date: Wed, 2 Aug 2023 11:49:12 +0200 Subject: [PATCH 060/270] Docker tests cleanup (#10040) * Clean up env components and use functional options * Include add mercury ocr job in cl node * Fix cl node * Fix * Fix * Fix pg port * Fix geth * remove deprecated io/ioutil * Small fix to trigger new builds on CI --------- Co-authored-by: skudasov --- integration-tests/docker/test_env/cl_node.go | 271 ++++++++++++++---- .../docker/test_env/env_component.go | 21 ++ integration-tests/docker/test_env/geth.go | 88 +++--- .../docker/test_env/mockserver.go | 34 +-- integration-tests/docker/test_env/postgres.go | 84 ++++++ integration-tests/docker/test_env/test_env.go | 130 +-------- integration-tests/types/envcommon/common.go | 65 ----- .../utils/templates/node_secrets.go | 14 +- 8 files changed, 407 insertions(+), 300 deletions(-) create mode 100644 integration-tests/docker/test_env/env_component.go create mode 100644 integration-tests/docker/test_env/postgres.go diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 901423b6335..a59bb1781ee 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -2,141 +2,213 @@ package test_env import ( "context" + "crypto/ed25519" + "encoding/hex" "fmt" - "io/ioutil" + "net/url" "os" "strings" + "sync" "time" + "github.com/google/uuid" "github.com/pkg/errors" + "math/big" + "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/client" - env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" "github.com/smartcontractkit/chainlink/integration-tests/types/node" "github.com/smartcontractkit/chainlink/integration-tests/utils" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" + "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" - "math/big" ) type ClNode struct { - env.EnvComponent + EnvComponent API *client.ChainlinkClient NodeConfigOpts node.NodeConfigOpts - DbC *tc.Container - DbCName string - DbOpts env.PgOpts + PostgresDb *PostgresDb +} + +type ClNodeOption = func(c *ClNode) + +// Sets custom node container name if name is not empty +func WithNodeContainerName(name string) ClNodeOption { + return func(c *ClNode) { + if name != "" { + c.ContainerName = name + } + } } -func NewClNode(compOpts env.EnvComponentOpts, opts node.NodeConfigOpts, dbContainerName string) *ClNode { - return &ClNode{ - EnvComponent: env.NewEnvComponent("cl-node", compOpts), - DbCName: dbContainerName, - NodeConfigOpts: opts, - DbOpts: env.NewDefaultPgOpts("cl-node", compOpts.Networks), +// Sets custom node db container name if name is not empty +func WithDbContainerName(name string) ClNodeOption { + return func(c *ClNode) { + if name != "" { + c.PostgresDb.ContainerName = name + } + } +} + +func NewClNode(networks []string, nodeConfOpts node.NodeConfigOpts, opts ...ClNodeOption) *ClNode { + nodeDefaultCName := fmt.Sprintf("%s-%s", "cl-node", uuid.NewString()[0:3]) + pgDefaultCName := fmt.Sprintf("pg-%s", nodeDefaultCName) + pgDb := NewPostgresDb(networks, WithPostgresDbContainerName(pgDefaultCName)) + n := &ClNode{ + EnvComponent: EnvComponent{ + ContainerName: nodeDefaultCName, + Networks: networks, + }, + NodeConfigOpts: nodeConfOpts, + PostgresDb: pgDb, + } + for _, opt := range opts { + opt(n) } + return n } -func (m *ClNode) AddBootstrapJob(verifierAddr common.Address, fromBlock uint64, chainId int64, +func (n *ClNode) AddBootstrapJob(verifierAddr common.Address, fromBlock uint64, chainId int64, feedId [32]byte) (*client.Job, error) { spec := utils.BuildBootstrapSpec(verifierAddr, chainId, fromBlock, feedId) - return m.API.MustCreateJob(spec) + return n.API.MustCreateJob(spec) } -func (m *ClNode) GetContainerName() string { - name, err := m.EnvComponent.Container.Name(context.Background()) +func (n *ClNode) AddMercuryOCRJob(verifierAddr common.Address, fromBlock uint64, chainId int64, + feedId [32]byte, customAllowedFaults *int, bootstrapUrl string, + mercuryServerUrl string, mercuryServerPubKey string, + eaUrls []*url.URL) (*client.Job, error) { + + csaKeys, _, err := n.API.ReadCSAKeys() + if err != nil { + return nil, err + } + csaPubKey := csaKeys.Data[0].ID + + nodeOCRKeys, err := n.API.MustReadOCR2Keys() + if err != nil { + return nil, err + } + + var nodeOCRKeyId []string + for _, key := range nodeOCRKeys.Data { + if key.Attributes.ChainType == string(chaintype.EVM) { + nodeOCRKeyId = append(nodeOCRKeyId, key.ID) + break + } + } + + bridges := utils.BuildBridges(eaUrls) + for _, b := range bridges { + err = n.API.MustCreateBridge(&b) + if err != nil { + return nil, err + } + } + + var allowedFaults int + if customAllowedFaults != nil { + allowedFaults = *customAllowedFaults + } else { + allowedFaults = 2 + } + + spec := utils.BuildOCRSpec( + verifierAddr, chainId, fromBlock, feedId, bridges, + csaPubKey, mercuryServerUrl, mercuryServerPubKey, nodeOCRKeyId[0], + bootstrapUrl, allowedFaults) + + return n.API.MustCreateJob(spec) +} + +func (n *ClNode) GetContainerName() string { + name, err := n.EnvComponent.Container.Name(context.Background()) if err != nil { return "" } return strings.Replace(name, "/", "", -1) } -func (m *ClNode) GetPeerUrl() (string, error) { - p2pKeys, err := m.API.MustReadP2PKeys() +func (n *ClNode) GetPeerUrl() (string, error) { + p2pKeys, err := n.API.MustReadP2PKeys() if err != nil { return "", err } p2pId := p2pKeys.Data[0].Attributes.PeerID - return fmt.Sprintf("%s@%s:%d", p2pId, m.GetContainerName(), 6690), nil + return fmt.Sprintf("%s@%s:%d", p2pId, n.GetContainerName(), 6690), nil } -func (m *ClNode) GetNodeCSAKeys() (*client.CSAKeys, error) { - csaKeys, _, err := m.API.ReadCSAKeys() +func (n *ClNode) GetNodeCSAKeys() (*client.CSAKeys, error) { + csaKeys, _, err := n.API.ReadCSAKeys() if err != nil { return nil, err } return csaKeys, err } -func (m *ClNode) ChainlinkNodeAddress() (common.Address, error) { - addr, err := m.API.PrimaryEthAddress() +func (n *ClNode) ChainlinkNodeAddress() (common.Address, error) { + addr, err := n.API.PrimaryEthAddress() if err != nil { return common.Address{}, err } return common.HexToAddress(addr), nil } -func (m *ClNode) Fund(g *Geth, amount *big.Float) error { - toAddress, err := m.API.PrimaryEthAddress() +func (n *ClNode) Fund(evmClient blockchain.EVMClient, amount *big.Float) error { + toAddress, err := n.API.PrimaryEthAddress() if err != nil { return err } - gasEstimates, err := g.EthClient.EstimateGas(ethereum.CallMsg{}) + gasEstimates, err := evmClient.EstimateGas(ethereum.CallMsg{}) if err != nil { return err } - return g.EthClient.Fund(toAddress, amount, gasEstimates) + return evmClient.Fund(toAddress, amount, gasEstimates) } -func (m *ClNode) StartContainer(lw *logwatch.LogWatch) error { - pgReq := env.GetPgContainerRequest(m.DbCName, m.DbOpts) - pgC, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ - ContainerRequest: *pgReq, - Started: true, - Reuse: true, - }) +func (n *ClNode) StartContainer(lw *logwatch.LogWatch) error { + err := n.PostgresDb.StartContainer(lw) if err != nil { return err } - - nodeSecrets, err := templates.ExecuteNodeSecretsTemplate(pgReq.Name, "5432") + nodeSecrets, err := templates.ExecuteNodeSecretsTemplate( + n.PostgresDb.DbName, n.PostgresDb.ContainerName, n.PostgresDb.Port) if err != nil { return err } - clReq, err := m.getContainerRequest(nodeSecrets) + cReq, err := n.getContainerRequest(nodeSecrets) if err != nil { return err } - clC, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ - ContainerRequest: *clReq, + container, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ + ContainerRequest: *cReq, Started: true, Reuse: true, }) if err != nil { - return errors.Wrapf(err, "could not start chainlink node container") + return errors.Wrapf(err, "could not start Chainlink Node container") } if lw != nil { - if err := lw.ConnectContainer(context.Background(), clC, "chainlink", true); err != nil { + if err := lw.ConnectContainer(context.Background(), container, "chainlink", true); err != nil { return err } } - ctName, err := clC.Name(context.Background()) - if err != nil { - return err - } - ctName = strings.Replace(ctName, "/", "", -1) - clEndpoint, err := clC.Endpoint(context.Background(), "http") + clEndpoint, err := container.Endpoint(context.Background(), "http") if err != nil { return err } - log.Info().Str("containerName", ctName). + log.Info().Str("containerName", n.ContainerName). Str("clEndpoint", clEndpoint). Msg("Started Chainlink Node container") @@ -149,20 +221,19 @@ func (m *ClNode) StartContainer(lw *logwatch.LogWatch) error { return errors.Wrapf(err, "could not connect Node HTTP Client") } - m.EnvComponent.Container = clC - m.DbC = &pgC - m.API = clClient + n.Container = container + n.API = clClient return nil } -func (m *ClNode) getContainerRequest(secrets string) ( +func (n *ClNode) getContainerRequest(secrets string) ( *tc.ContainerRequest, error) { - configFile, err := ioutil.TempFile("", "node_config") + configFile, err := os.CreateTemp("", "node_config") if err != nil { return nil, err } - config, err := node.ExecuteNodeConfigTemplate(m.NodeConfigOpts) + config, err := node.ExecuteNodeConfigTemplate(n.NodeConfigOpts) if err != nil { return nil, err } @@ -171,7 +242,7 @@ func (m *ClNode) getContainerRequest(secrets string) ( return nil, err } - secretsFile, err := ioutil.TempFile("", "node_secrets") + secretsFile, err := os.CreateTemp("", "node_secrets") if err != nil { return nil, err } @@ -181,7 +252,7 @@ func (m *ClNode) getContainerRequest(secrets string) ( } adminCreds := "local@local.com\nlocaldevpassword" - adminCredsFile, err := ioutil.TempFile("", "admin_creds") + adminCredsFile, err := os.CreateTemp("", "admin_creds") if err != nil { return nil, err } @@ -191,7 +262,7 @@ func (m *ClNode) getContainerRequest(secrets string) ( } apiCreds := "local@local.com\nlocaldevpassword" - apiCredsFile, err := ioutil.TempFile("", "api_creds") + apiCredsFile, err := os.CreateTemp("", "api_creds") if err != nil { return nil, err } @@ -215,7 +286,7 @@ func (m *ClNode) getContainerRequest(secrets string) ( } return &tc.ContainerRequest{ - Name: m.EnvComponent.ContainerName, + Name: n.EnvComponent.ContainerName, Image: fmt.Sprintf("%s:%s", image, tag), ExposedPorts: []string{"6688/tcp"}, Entrypoint: []string{"chainlink", @@ -225,7 +296,7 @@ func (m *ClNode) getContainerRequest(secrets string) ( "-p", adminCredsPath, "-a", apiCredsPath, }, - Networks: m.Networks, + Networks: n.Networks, WaitingFor: tcwait.ForHTTP("/health"). WithPort("6688/tcp"). WithStartupTimeout(90 * time.Second). @@ -254,3 +325,83 @@ func (m *ClNode) getContainerRequest(secrets string) ( }, }, nil } + +func GetOracleIdentities(chainlinkNodes []*ClNode) ([]int, []confighelper.OracleIdentityExtra) { + S := make([]int, len(chainlinkNodes)) + oracleIdentities := make([]confighelper.OracleIdentityExtra, len(chainlinkNodes)) + sharedSecretEncryptionPublicKeys := make([]ocrtypes.ConfigEncryptionPublicKey, len(chainlinkNodes)) + var wg sync.WaitGroup + for i, cl := range chainlinkNodes { + wg.Add(1) + go func(i int, cl *ClNode) error { + defer wg.Done() + + ocr2Keys, err := cl.API.MustReadOCR2Keys() + if err != nil { + return err + } + var ocr2Config client.OCR2KeyAttributes + for _, key := range ocr2Keys.Data { + if key.Attributes.ChainType == string(chaintype.EVM) { + ocr2Config = key.Attributes + break + } + } + + keys, err := cl.API.MustReadP2PKeys() + if err != nil { + return err + } + p2pKeyID := keys.Data[0].Attributes.PeerID + + offchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OffChainPublicKey, "ocr2off_evm_")) + if err != nil { + return err + } + + offchainPkBytesFixed := [ed25519.PublicKeySize]byte{} + copy(offchainPkBytesFixed[:], offchainPkBytes) + if err != nil { + return err + } + + configPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.ConfigPublicKey, "ocr2cfg_evm_")) + if err != nil { + return err + } + + configPkBytesFixed := [ed25519.PublicKeySize]byte{} + copy(configPkBytesFixed[:], configPkBytes) + if err != nil { + return err + } + + onchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OnChainPublicKey, "ocr2on_evm_")) + if err != nil { + return err + } + + csaKeys, _, err := cl.API.ReadCSAKeys() + if err != nil { + return err + } + + sharedSecretEncryptionPublicKeys[i] = configPkBytesFixed + oracleIdentities[i] = confighelper.OracleIdentityExtra{ + OracleIdentity: confighelper.OracleIdentity{ + OnchainPublicKey: onchainPkBytes, + OffchainPublicKey: offchainPkBytesFixed, + PeerID: p2pKeyID, + TransmitAccount: ocrtypes.Account(csaKeys.Data[0].ID), + }, + ConfigEncryptionPublicKey: configPkBytesFixed, + } + S[i] = 1 + + return nil + }(i, cl) + } + wg.Wait() + + return S, oracleIdentities +} diff --git a/integration-tests/docker/test_env/env_component.go b/integration-tests/docker/test_env/env_component.go new file mode 100644 index 00000000000..e6f6fc4b8a6 --- /dev/null +++ b/integration-tests/docker/test_env/env_component.go @@ -0,0 +1,21 @@ +package test_env + +import ( + tc "github.com/testcontainers/testcontainers-go" +) + +type EnvComponent struct { + ContainerName string + Container tc.Container + Networks []string +} + +type EnvComponentOption = func(c *EnvComponent) + +func WithContainerName(name string) EnvComponentOption { + return func(c *EnvComponent) { + if name != "" { + c.ContainerName = name + } + } +} diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index 720de6fea27..77bceed1797 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -3,21 +3,20 @@ package test_env import ( "context" "fmt" - "io/ioutil" - "strings" + "time" "github.com/ethereum/go-ethereum/accounts" "github.com/ethereum/go-ethereum/accounts/keystore" + "github.com/google/uuid" "github.com/pkg/errors" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/contracts" - env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" - "time" + "os" ) const ( @@ -29,23 +28,30 @@ const ( ) type Geth struct { - env.EnvComponent + EnvComponent ExternalHttpUrl string InternalHttpUrl string ExternalWsUrl string InternalWsUrl string - EthClient blockchain.EVMClient + EthClient *blockchain.EthereumClient ContractDeployer contracts.ContractDeployer } -func NewGeth(compOpts env.EnvComponentOpts) *Geth { - return &Geth{ - EnvComponent: env.NewEnvComponent("geth", compOpts), +func NewGeth(networks []string, opts ...EnvComponentOption) *Geth { + g := &Geth{ + EnvComponent: EnvComponent{ + ContainerName: fmt.Sprintf("%s-%s", "geth", uuid.NewString()[0:3]), + Networks: networks, + }, } + for _, opt := range opts { + opt(&g.EnvComponent) + } + return g } -func (m *Geth) StartContainer(lw *logwatch.LogWatch) error { - r, _, _, err := m.getGethContainerRequest(m.Networks) +func (g *Geth) StartContainer(lw *logwatch.LogWatch) error { + r, _, _, err := g.getGethContainerRequest(g.Networks) if err != nil { return err } @@ -75,49 +81,55 @@ func (m *Geth) StartContainer(lw *logwatch.LogWatch) error { if err != nil { return err } - ctName, err := ct.Name(context.Background()) - if err != nil { - return err - } - ctName = strings.Replace(ctName, "/", "", -1) - m.EnvComponent.Container = ct - m.ExternalHttpUrl = fmt.Sprintf("http://%s:%s", host, httpPort.Port()) - m.InternalHttpUrl = fmt.Sprintf("http://%s:8544", ctName) - m.ExternalWsUrl = fmt.Sprintf("ws://%s:%s", host, wsPort.Port()) - m.InternalWsUrl = fmt.Sprintf("ws://%s:8545", ctName) + g.EnvComponent.Container = ct + g.ExternalHttpUrl = fmt.Sprintf("http://%s:%s", host, httpPort.Port()) + g.InternalHttpUrl = fmt.Sprintf("http://%s:8544", g.ContainerName) + g.ExternalWsUrl = fmt.Sprintf("ws://%s:%s", host, wsPort.Port()) + g.InternalWsUrl = fmt.Sprintf("ws://%s:8545", g.ContainerName) networkConfig := blockchain.SimulatedEVMNetwork networkConfig.Name = "geth" - networkConfig.URLs = []string{m.ExternalWsUrl} - networkConfig.HTTPURLs = []string{m.ExternalWsUrl} + networkConfig.URLs = []string{g.ExternalWsUrl} + networkConfig.HTTPURLs = []string{g.ExternalWsUrl} bc, err := blockchain.NewEVMClientFromNetwork(networkConfig) if err != nil { return err } - m.EthClient = bc + // Get blockchain.EthereumClient as this is the only possible client for Geth + switch val := bc.(type) { + case *blockchain.EthereumMultinodeClient: + ethClient, ok := val.Clients[0].(*blockchain.EthereumClient) + if !ok { + return errors.Errorf("could not get blockchain.EthereumClient from %+v", val) + } + g.EthClient = ethClient + default: + return errors.Errorf("%+v not supported for geth", val) + } + cd, err := contracts.NewContractDeployer(bc) if err != nil { return err } - m.ContractDeployer = cd + g.ContractDeployer = cd - log.Info().Str("containerName", ctName). - Str("internalHttpUrl", m.InternalHttpUrl). - Str("externalHttpUrl", m.ExternalHttpUrl). - Str("externalWsUrl", m.ExternalWsUrl). - Str("internalWsUrl", m.InternalWsUrl). + log.Info().Str("containerName", g.ContainerName). + Str("internalHttpUrl", g.InternalHttpUrl). + Str("externalHttpUrl", g.ExternalHttpUrl). + Str("externalWsUrl", g.ExternalWsUrl). + Str("internalWsUrl", g.InternalWsUrl). Msg("Started Geth container") return nil } -func (m *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, *keystore.KeyStore, *accounts.Account, error) { +func (g *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, *keystore.KeyStore, *accounts.Account, error) { chainId := "1337" blocktime := "1" - initScriptFile, err := ioutil.TempFile("", "init_script") + initScriptFile, err := os.CreateTemp("", "init_script") if err != nil { return nil, nil, nil, err } @@ -125,7 +137,7 @@ func (m *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, if err != nil { return nil, nil, nil, err } - keystoreDir, err := ioutil.TempDir("", "keystore") + keystoreDir, err := os.MkdirTemp("", "keystore") if err != nil { return nil, nil, nil, err } @@ -139,7 +151,7 @@ func (m *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, if err != nil { return nil, ks, &account, err } - genesisFile, err := ioutil.TempFile("", "genesis_json") + genesisFile, err := os.CreateTemp("", "genesis_json") if err != nil { return nil, ks, &account, err } @@ -147,7 +159,7 @@ func (m *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, if err != nil { return nil, ks, &account, err } - key1File, err := ioutil.TempFile(keystoreDir, "key1") + key1File, err := os.CreateTemp(keystoreDir, "key1") if err != nil { return nil, ks, &account, err } @@ -155,17 +167,17 @@ func (m *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, if err != nil { return nil, ks, &account, err } - configDir, err := ioutil.TempDir("", "config") + configDir, err := os.MkdirTemp("", "config") if err != nil { return nil, ks, &account, err } - err = ioutil.WriteFile(configDir+"/password.txt", []byte(""), 0644) + err = os.WriteFile(configDir+"/password.txt", []byte(""), 0600) if err != nil { return nil, ks, &account, err } return &tc.ContainerRequest{ - Name: m.ContainerName, + Name: g.ContainerName, Image: "ethereum/client-go:stable", ExposedPorts: []string{"8544/tcp", "8545/tcp"}, Networks: networks, diff --git a/integration-tests/docker/test_env/mockserver.go b/integration-tests/docker/test_env/mockserver.go index 2810ef74609..102c04b08cf 100644 --- a/integration-tests/docker/test_env/mockserver.go +++ b/integration-tests/docker/test_env/mockserver.go @@ -7,27 +7,34 @@ import ( "strings" "time" + "github.com/google/uuid" "github.com/pkg/errors" "github.com/rs/zerolog/log" ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" - env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" ) type MockServer struct { - env.EnvComponent + EnvComponent Client *ctfClient.MockserverClient Endpoint string InternalEndpoint string EAMockUrls []*url.URL } -func NewMockServer(compOpts env.EnvComponentOpts) *MockServer { - return &MockServer{ - EnvComponent: env.NewEnvComponent("mockserver", compOpts), +func NewMockServer(networks []string, opts ...EnvComponentOption) *MockServer { + ms := &MockServer{ + EnvComponent: EnvComponent{ + ContainerName: fmt.Sprintf("%s-%s", "mockserver", uuid.NewString()[0:3]), + Networks: networks, + }, + } + for _, opt := range opts { + opt(&ms.EnvComponent) } + return ms } func (m *MockServer) SetExternalAdapterMocks(count int) error { @@ -59,35 +66,30 @@ func (m *MockServer) StartContainer(lw *logwatch.LogWatch) error { Reuse: true, }) if err != nil { - return errors.Wrapf(err, "cannot start mock server container") + return errors.Wrapf(err, "cannot start MockServer container") } + m.Container = c if lw != nil { if err := lw.ConnectContainer(context.Background(), c, m.ContainerName, true); err != nil { return err } } - cName, err := c.Name(context.Background()) - if err != nil { - return err - } - cName = strings.Replace(cName, "/", "", -1) endpoint, err := c.Endpoint(context.Background(), "http") if err != nil { return err } - log.Info().Any("endpoint", endpoint).Str("containerName", cName). - Msgf("Started mockserver container") + log.Info().Any("endpoint", endpoint).Str("containerName", m.ContainerName). + Msgf("Started MockServer container") m.Endpoint = endpoint - m.InternalEndpoint = fmt.Sprintf("http://%s:%s", cName, "1080") + m.InternalEndpoint = fmt.Sprintf("http://%s:%s", m.ContainerName, "1080") client := ctfClient.NewMockserverClient(&ctfClient.MockserverConfig{ LocalURL: endpoint, ClusterURL: m.InternalEndpoint, }) if err != nil { - return errors.Wrapf(err, "cannot connect to mockserver client") + return errors.Wrapf(err, "cannot connect to MockServer client") } - m.EnvComponent.Container = c m.Client = client return nil diff --git a/integration-tests/docker/test_env/postgres.go b/integration-tests/docker/test_env/postgres.go new file mode 100644 index 00000000000..7c2782f14a2 --- /dev/null +++ b/integration-tests/docker/test_env/postgres.go @@ -0,0 +1,84 @@ +package test_env + +import ( + "context" + "fmt" + "time" + + "github.com/google/uuid" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" +) + +type PostgresDb struct { + EnvComponent + User string + Password string + DbName string + Port string +} + +type PostgresDbOption = func(c *PostgresDb) + +// Sets custom container name if name is not empty +func WithPostgresDbContainerName(name string) PostgresDbOption { + return func(c *PostgresDb) { + if name != "" { + c.ContainerName = name + } + } +} + +func NewPostgresDb(networks []string, opts ...PostgresDbOption) *PostgresDb { + pg := &PostgresDb{ + EnvComponent: EnvComponent{ + ContainerName: fmt.Sprintf("%s-%s", "postgres-db", uuid.NewString()[0:3]), + Networks: networks, + }, + User: "postgres", + Password: "test", + DbName: "testdb", + Port: "5432", + } + for _, opt := range opts { + opt(pg) + } + return pg +} + +func (pg *PostgresDb) StartContainer(lw *logwatch.LogWatch) error { + req := pg.getContainerRequest() + c, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ + ContainerRequest: *req, + Started: true, + Reuse: true, + }) + if err != nil { + return err + } + pg.Container = c + + log.Info().Str("containerName", pg.ContainerName). + Msg("Started Postgres DB container") + + return nil +} + +func (pg *PostgresDb) getContainerRequest() *tc.ContainerRequest { + return &tc.ContainerRequest{ + Name: pg.ContainerName, + Image: "postgres:15.3", + ExposedPorts: []string{fmt.Sprintf("%s/tcp", pg.Port)}, + Env: map[string]string{ + "POSTGRES_USER": pg.User, + "POSTGRES_DB": pg.DbName, + "POSTGRES_PASSWORD": pg.Password, + }, + Networks: pg.Networks, + WaitingFor: tcwait.ForExec([]string{"psql", "-h", "localhost", + "-U", pg.User, "-c", "select", "1", "-d", pg.DbName}). + WithStartupTimeout(10 * time.Second), + } +} diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index f336ac225a9..088bf833bd9 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -1,26 +1,17 @@ package test_env import ( - "crypto/ed25519" - "encoding/hex" - "strings" "sync" - "fmt" + "math/big" + "github.com/ethereum/go-ethereum/common" - "github.com/google/uuid" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" - "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/docker" - env "github.com/smartcontractkit/chainlink/integration-tests/types/envcommon" "github.com/smartcontractkit/chainlink/integration-tests/types/node" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" - ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" - "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" tc "github.com/testcontainers/testcontainers-go" "go.uber.org/multierr" - "math/big" ) type CLClusterTestEnv struct { @@ -39,13 +30,9 @@ func NewTestEnv() (*CLClusterTestEnv, error) { } networks := []string{network.Name} return &CLClusterTestEnv{ - Network: network, - Geth: NewGeth(env.EnvComponentOpts{ - Networks: networks, - }), - MockServer: NewMockServer(env.EnvComponentOpts{ - Networks: networks, - }), + Network: network, + Geth: NewGeth(networks), + MockServer: NewMockServer(networks), }, nil } @@ -57,16 +44,10 @@ func NewTestEnvFromCfg(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { networks := []string{network.Name} log.Info().Interface("Cfg", cfg).Send() return &CLClusterTestEnv{ - cfg: cfg, - Network: network, - Geth: NewGeth(env.EnvComponentOpts{ - ReuseContainerName: cfg.Geth.ContainerName, - Networks: networks, - }), - MockServer: NewMockServer(env.EnvComponentOpts{ - ReuseContainerName: cfg.MockServer.ContainerName, - Networks: networks, - }), + cfg: cfg, + Network: network, + Geth: NewGeth(networks, WithContainerName(cfg.Geth.ContainerName)), + MockServer: NewMockServer(networks, WithContainerName(cfg.MockServer.ContainerName)), }, nil } @@ -90,15 +71,14 @@ func (m *CLClusterTestEnv) StartClNodes(nodeConfigOpts node.NodeConfigOpts, coun wg.Add(1) go func() { defer wg.Done() - dbContainerName := fmt.Sprintf("cl-db-%s", uuid.NewString()) - opts := env.EnvComponentOpts{ - Networks: []string{m.Network.Name}, - } + var nodeContainerName, dbContainerName string if m.cfg != nil { - opts.ReuseContainerName = m.cfg.Nodes[i].NodeContainerName + nodeContainerName = m.cfg.Nodes[i].NodeContainerName dbContainerName = m.cfg.Nodes[i].DbContainerName } - n := NewClNode(opts, nodeConfigOpts, dbContainerName) + n := NewClNode([]string{m.Network.Name}, nodeConfigOpts, + WithNodeContainerName(nodeContainerName), + WithDbContainerName(dbContainerName)) err := n.StartContainer(m.LogWatch) if err != nil { mu.Lock() @@ -148,7 +128,7 @@ func (m *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { // FundChainlinkNodes will fund all the provided Chainlink nodes with a set amount of native currency func (m *CLClusterTestEnv) FundChainlinkNodes(amount *big.Float) error { for _, cl := range m.CLNodes { - if err := cl.Fund(m.Geth, amount); err != nil { + if err := cl.Fund(m.Geth.EthClient, amount); err != nil { return err } } @@ -167,86 +147,6 @@ func (m *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { return keys, nil } -func getOracleIdentities(chainlinkNodes []ClNode) ([]int, []confighelper.OracleIdentityExtra) { - S := make([]int, len(chainlinkNodes)) - oracleIdentities := make([]confighelper.OracleIdentityExtra, len(chainlinkNodes)) - sharedSecretEncryptionPublicKeys := make([]ocrtypes.ConfigEncryptionPublicKey, len(chainlinkNodes)) - var wg sync.WaitGroup - for i, cl := range chainlinkNodes { - wg.Add(1) - go func(i int, cl ClNode) error { - defer wg.Done() - - ocr2Keys, err := cl.API.MustReadOCR2Keys() - if err != nil { - return err - } - var ocr2Config client.OCR2KeyAttributes - for _, key := range ocr2Keys.Data { - if key.Attributes.ChainType == string(chaintype.EVM) { - ocr2Config = key.Attributes - break - } - } - - keys, err := cl.API.MustReadP2PKeys() - if err != nil { - return err - } - p2pKeyID := keys.Data[0].Attributes.PeerID - - offchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OffChainPublicKey, "ocr2off_evm_")) - if err != nil { - return err - } - - offchainPkBytesFixed := [ed25519.PublicKeySize]byte{} - copy(offchainPkBytesFixed[:], offchainPkBytes) - if err != nil { - return err - } - - configPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.ConfigPublicKey, "ocr2cfg_evm_")) - if err != nil { - return err - } - - configPkBytesFixed := [ed25519.PublicKeySize]byte{} - copy(configPkBytesFixed[:], configPkBytes) - if err != nil { - return err - } - - onchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OnChainPublicKey, "ocr2on_evm_")) - if err != nil { - return err - } - - csaKeys, _, err := cl.API.ReadCSAKeys() - if err != nil { - return err - } - - sharedSecretEncryptionPublicKeys[i] = configPkBytesFixed - oracleIdentities[i] = confighelper.OracleIdentityExtra{ - OracleIdentity: confighelper.OracleIdentity{ - OnchainPublicKey: onchainPkBytes, - OffchainPublicKey: offchainPkBytesFixed, - PeerID: p2pKeyID, - TransmitAccount: ocrtypes.Account(csaKeys.Data[0].ID), - }, - ConfigEncryptionPublicKey: configPkBytesFixed, - } - S[i] = 1 - - return nil - }(i, cl) - } - wg.Wait() - - return S, oracleIdentities -} - func (m *CLClusterTestEnv) Terminate() error { // TESTCONTAINERS_RYUK_DISABLED=false by defualt so ryuk will remove all // the containers and the network diff --git a/integration-tests/types/envcommon/common.go b/integration-tests/types/envcommon/common.go index 2bbf5c9bf91..607c481f33f 100644 --- a/integration-tests/types/envcommon/common.go +++ b/integration-tests/types/envcommon/common.go @@ -2,75 +2,10 @@ package envcommon import ( "encoding/json" - "fmt" - "github.com/google/uuid" - tc "github.com/testcontainers/testcontainers-go" - tcwait "github.com/testcontainers/testcontainers-go/wait" "io/ioutil" "os" - "time" ) -type PgOpts struct { - User string - Password string - DbName string - Networks []string - Port string -} - -func NewDefaultPgOpts(dbName string, networks []string) PgOpts { - return PgOpts{ - Port: "5432", - User: "postgres", - Password: "test", - DbName: dbName, - Networks: networks, - } -} - -func GetPgContainerRequest(name string, opts PgOpts) *tc.ContainerRequest { - return &tc.ContainerRequest{ - Name: name, - Image: "postgres:15.3", - ExposedPorts: []string{fmt.Sprintf("%s/tcp", opts.Port)}, - Env: map[string]string{ - "POSTGRES_USER": opts.User, - "POSTGRES_DB": opts.DbName, - "POSTGRES_PASSWORD": opts.Password, - }, - Networks: opts.Networks, - WaitingFor: tcwait.ForExec([]string{"psql", "-h", "localhost", - "-U", opts.User, "-c", "select", "1", "-d", opts.DbName}). - WithStartupTimeout(10 * time.Second), - } -} - -type EnvComponent struct { - ContainerName string - Container tc.Container - Networks []string -} - -type EnvComponentOpts struct { - ReuseContainerName string - Networks []string -} - -func NewEnvComponent(componentType string, opts EnvComponentOpts) EnvComponent { - var name string - if opts.ReuseContainerName != "" { - name = opts.ReuseContainerName - } else { - name = fmt.Sprintf("%s-%s", componentType, uuid.NewString()) - } - - return EnvComponent{ - ContainerName: name, - Networks: opts.Networks, - } -} - func ParseJSONFile(path string, v any) error { jsonFile, err := os.Open(path) if err != nil { diff --git a/integration-tests/utils/templates/node_secrets.go b/integration-tests/utils/templates/node_secrets.go index 2bc3235715e..a40c553df85 100644 --- a/integration-tests/utils/templates/node_secrets.go +++ b/integration-tests/utils/templates/node_secrets.go @@ -9,7 +9,7 @@ import ( var NodeSecretsTemplate = ` [Database] -URL = 'postgresql://postgres:test@{{ .PgHost }}:{{ .PgPort }}/cl-node?sslmode=disable' # Required +URL = 'postgresql://postgres:test@{{ .PgHost }}:{{ .PgPort }}/{{ .PgDbName }}?sslmode=disable' # Required AllowSimplePasswords = true [Password] @@ -22,13 +22,15 @@ Username = 'node' Password = 'nodepass' ` -func ExecuteNodeSecretsTemplate(pgHost string, pgPort string) (string, error) { +func ExecuteNodeSecretsTemplate(pgDbName, pgHost, pgPort string) (string, error) { data := struct { - PgHost string - PgPort string + PgDbName string + PgHost string + PgPort string }{ - PgHost: pgHost, - PgPort: pgPort, + PgDbName: pgDbName, + PgHost: pgHost, + PgPort: pgPort, } t, err := template.New("node-secrets").Parse(NodeSecretsTemplate) From 0de87189577f2f4690cb84c293c765c0760d8be9 Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Wed, 2 Aug 2023 16:03:12 +0200 Subject: [PATCH 061/270] Cleanup Solidity scripts folder (#10001) * cleanup scripts, mv vrf separate file * extract legacy solidity compils * extract automation compile bump versions to 0.8.16 * streamline ocr2vrf script * native_solc_compile_all final form * fix functions mock & final form 6,7,auto,feeds,func * fix SCRIPTPATH 6 7 and final form all runners * improve box drawing * gen wrappers * reference moved wrappers --- GNUmakefile | 3 +- contracts/scripts/native_solc6_compile | 15 -- contracts/scripts/native_solc7_compile | 15 -- contracts/scripts/native_solc8_15_compile | 19 --- contracts/scripts/native_solc8_16_compile | 19 --- .../scripts/native_solc8_19_compile_ocr2vrf | 23 --- contracts/scripts/native_solc8_6_compile | 22 --- contracts/scripts/native_solc_compile_all | 154 ++---------------- contracts/scripts/native_solc_compile_all_6 | 44 +++++ contracts/scripts/native_solc_compile_all_7 | 41 +++++ .../native_solc_compile_all_automation | 68 ++++++++ .../scripts/native_solc_compile_all_feeds | 35 ++++ .../scripts/native_solc_compile_all_functions | 38 +++-- contracts/scripts/native_solc_compile_all_llo | 4 + .../scripts/native_solc_compile_all_logpoller | 29 ++++ .../scripts/native_solc_compile_all_ocr2vrf | 39 ++++- .../native_solc_compile_all_transmission | 37 +++++ contracts/scripts/native_solc_compile_all_vrf | 84 ++++++++++ .../scripts/native_solc_compile_events_mock | 12 -- .../native_solc_compile_all_transmission | 20 --- contracts/src/v0.8/tests/LogEmitter.sol | 1 + contracts/src/v0.8/tests/MercuryUpkeep.sol | 2 +- .../functions_billing_registry_events_mock.go | 0 .../functions_oracle_events_mock.go | 0 ...rapper-dependency-versions-do-not-edit.txt | 2 + core/gethwrappers/functions/go_generate.go | 3 + .../generated/log_emitter/log_emitter.go | 2 +- .../mercury_upkeep_wrapper.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 8 +- core/gethwrappers/go_generate.go | 9 +- .../contracts/contract_deployer.go | 11 +- .../contracts/contract_models.go | 6 +- .../contracts/ethereum_contracts.go | 10 +- 33 files changed, 431 insertions(+), 346 deletions(-) delete mode 100755 contracts/scripts/native_solc6_compile delete mode 100755 contracts/scripts/native_solc7_compile delete mode 100755 contracts/scripts/native_solc8_15_compile delete mode 100755 contracts/scripts/native_solc8_16_compile delete mode 100755 contracts/scripts/native_solc8_19_compile_ocr2vrf delete mode 100755 contracts/scripts/native_solc8_6_compile create mode 100755 contracts/scripts/native_solc_compile_all_6 create mode 100755 contracts/scripts/native_solc_compile_all_7 create mode 100755 contracts/scripts/native_solc_compile_all_automation create mode 100755 contracts/scripts/native_solc_compile_all_feeds create mode 100755 contracts/scripts/native_solc_compile_all_logpoller create mode 100755 contracts/scripts/native_solc_compile_all_transmission create mode 100755 contracts/scripts/native_solc_compile_all_vrf delete mode 100755 contracts/scripts/native_solc_compile_events_mock delete mode 100755 contracts/scripts/transmission/native_solc_compile_all_transmission rename core/gethwrappers/{ => functions}/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go (100%) rename core/gethwrappers/{ => functions}/generated/functions_oracle_events_mock/functions_oracle_events_mock.go (100%) diff --git a/GNUmakefile b/GNUmakefile index cf0f7aba9e4..fb821b3880f 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -91,12 +91,11 @@ abigen: ## Build & install abigen. .PHONY: go-solidity-wrappers go-solidity-wrappers: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - ./contracts/scripts/native_solc_compile_all go generate ./core/gethwrappers .PHONY: go-solidity-wrappers-transmission go-solidity-wrappers-transmission: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - ./contracts/scripts/transmission/native_solc_compile_all_transmission + ./contracts/scripts/native_solc_compile_all_transmission go generate ./core/gethwrappers/transmission .PHONY: go-solidity-wrappers-ocr2vrf diff --git a/contracts/scripts/native_solc6_compile b/contracts/scripts/native_solc6_compile deleted file mode 100755 index ae3be9b56d0..00000000000 --- a/contracts/scripts/native_solc6_compile +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -# This script generates .abi and .bin files for a selected .sol contract. -# Example call: -# ./contracts/scripts/native_solc_compile dev/Operator.sol -# -# The resulting abi and bin files are stored in ./contracts/solc/v0.6 - -SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd .. && pwd -P )" - -solc-select use 0.6.6 -solc --overwrite --optimize --optimize-runs 1000000 --metadata-hash none \ - -o $SCRIPTPATH/solc/v0.6 \ - --abi --bin --allow-paths $SCRIPTPATH/src/v0.6,$SCRIPTPATH/src/v0.6/dev,$SCRIPTPATH/src/v0.6/interfaces,$SCRIPTPATH/src/v0.6/examples,$SCRIPTPATH/src/v0.6/tests,$SCRIPTPATH/src/v0.6/vendor \ - $SCRIPTPATH/src/v0.6/$1 diff --git a/contracts/scripts/native_solc7_compile b/contracts/scripts/native_solc7_compile deleted file mode 100755 index dc4c08e72e7..00000000000 --- a/contracts/scripts/native_solc7_compile +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -# This script generates .abi and .bin files for a selected .sol contract. -# Example call: -# ./contracts/scripts/native_solc_compile dev/Operator.sol -# -# The resulting abi and bin files are stored in ./contracts/solc/v0.7 - -SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd .. && pwd -P )" - -solc-select use 0.7.6 -solc --overwrite --optimize --optimize-runs 1000000 --metadata-hash none \ - -o $SCRIPTPATH/solc/v0.7 \ - --abi --bin --allow-paths $SCRIPTPATH/src/v0.7,$SCRIPTPATH/src/v0.7/dev,$SCRIPTPATH/src/v0.7/interfaces,$SCRIPTPATH/src/v0.7/tests,$SCRIPTPATH/src/v0.7/vendor \ - $SCRIPTPATH/src/v0.7/$1 \ No newline at end of file diff --git a/contracts/scripts/native_solc8_15_compile b/contracts/scripts/native_solc8_15_compile deleted file mode 100755 index 944a53a7e1a..00000000000 --- a/contracts/scripts/native_solc8_15_compile +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/env bash - -# This script generates .abi and .bin files for a selected .sol contract. -# Example call: -# ./contracts/scripts/native_solc_compile dev/Operator.sol -# -# The resulting abi and bin files are stored in ./contracts/solc/v0.8 - -ROOT="$( - cd "$(dirname "$0")" >/dev/null 2>&1 - cd ../../ && pwd -P -)" - -solc-select use 0.8.15 -solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs 1000000 --metadata-hash none \ - -o $ROOT/contracts/solc/v0.8.15 \ - --abi --bin \ - --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/src/v0.8/dev,$ROOT/contracts/src/v0.8/interfaces,$ROOT/contracts/src/v0.8/mocks,$ROOT/contracts/src/v0.8/tests,$ROOT/contracts/src/v0.8/vendor,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts@4.3.3/node_modules/@openzeppelin/contracts,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts-upgradeable@4.7.3/node_modules/@openzeppelin/contracts-upgradeable \ - $ROOT/contracts/src/v0.8/$1 diff --git a/contracts/scripts/native_solc8_16_compile b/contracts/scripts/native_solc8_16_compile deleted file mode 100755 index d6083d50fa1..00000000000 --- a/contracts/scripts/native_solc8_16_compile +++ /dev/null @@ -1,19 +0,0 @@ -#!/usr/bin/env bash - -# This script generates .abi and .bin files for a selected .sol contract. -# Example call: -# ./contracts/scripts/native_solc_compile dev/Operator.sol -# -# The resulting abi and bin files are stored in ./contracts/solc/v0.8 - -ROOT="$( - cd "$(dirname "$0")" >/dev/null 2>&1 - cd ../../ && pwd -P -)" - -solc-select use 0.8.16 -solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs 1000000 --metadata-hash none \ - -o $ROOT/contracts/solc/v0.8.16 \ - --abi --bin \ - --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/src/v0.8/dev,$ROOT/contracts/src/v0.8/interfaces,$ROOT/contracts/src/v0.8/mocks,$ROOT/contracts/src/v0.8/tests,$ROOT/contracts/src/v0.8/vendor,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts@4.3.3/node_modules/@openzeppelin/contracts,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts-upgradeable@4.7.3/node_modules/@openzeppelin/contracts-upgradeable \ - $ROOT/contracts/src/v0.8/$1 diff --git a/contracts/scripts/native_solc8_19_compile_ocr2vrf b/contracts/scripts/native_solc8_19_compile_ocr2vrf deleted file mode 100755 index a3779430aff..00000000000 --- a/contracts/scripts/native_solc8_19_compile_ocr2vrf +++ /dev/null @@ -1,23 +0,0 @@ -#!/usr/bin/env bash - -# This script generates .abi and .bin files for a selected .sol contract. -# Example call: -# ./contracts/scripts/native_solc_compile dev/Operator.sol -# -# The resulting abi and bin files are stored in ./contracts/solc/v0.8 - -ROOT="$( - cd "$(dirname "$0")" >/dev/null 2>&1 - cd ../../ && pwd -P -)" - -solc-select use 0.8.19 -# Optionally set optimize runs from arguments (default = 1000) -OPTIMIZE_RUNS="${3}" - -solc-select use 0.8.19 -solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ - -o $ROOT/contracts/solc/v0.8.19 \ - --abi --bin \ - --allow-paths $ROOT/contracts/src/v0.8,$ROOT/../$2/contracts,$ROOT/contracts/src/v0.8/dev,$ROOT/contracts/src/v0.8/interfaces,$ROOT/contracts/src/v0.8/mocks,$ROOT/contracts/src/v0.8/tests,$ROOT/contracts/src/v0.8/vendor,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts@4.3.3/node_modules/@openzeppelin/contracts,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts-upgradeable@4.7.3/node_modules/@openzeppelin/contracts-upgradeable \ - $ROOT/contracts/src/v0.8/$1 diff --git a/contracts/scripts/native_solc8_6_compile b/contracts/scripts/native_solc8_6_compile deleted file mode 100755 index bd60589e0e5..00000000000 --- a/contracts/scripts/native_solc8_6_compile +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env bash - -# This script generates .abi and .bin files for a selected .sol contract. -# Example call: -# ./contracts/scripts/native_solc_compile dev/Operator.sol -# -# The resulting abi and bin files are stored in ./contracts/solc/v0.8 - -ROOT="$( - cd "$(dirname "$0")" >/dev/null 2>&1 - cd ../../ && pwd -P -)" - -# Optionally set optimize runs from arguments (default = 1000000) -OPTIMIZE_RUNS="${2:-1000000}" - -solc-select use 0.8.6 -solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ - -o $ROOT/contracts/solc/v0.8.6 \ - --abi --bin \ - --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/src/v0.8/dev,$ROOT/contracts/src/v0.8/interfaces,$ROOT/contracts/src/v0.8/mocks,$ROOT/contracts/src/v0.8/tests,$ROOT/contracts/src/v0.8/vendor,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts@4.3.3/node_modules/@openzeppelin/contracts,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts-upgradeable@4.7.3/node_modules/@openzeppelin/contracts-upgradeable,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts-upgradeable@4.8.1/node_modules/@openzeppelin/contracts-upgradeable \ - $ROOT/contracts/src/v0.8/$1 diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 47e779a769f..18a00372917 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -2,149 +2,17 @@ set -e +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling *all* contracts... │" +echo " └──────────────────────────────────────────────┘" + SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" -echo $SCRIPTPATH python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt -solc-select install 0.6.6 -solc-select install 0.7.6 -solc-select install 0.8.6 -solc-select install 0.8.15 -solc-select install 0.8.16 -solc-select install 0.8.19 - -$SCRIPTPATH/native_solc6_compile Flags.sol -$SCRIPTPATH/native_solc6_compile Oracle.sol -$SCRIPTPATH/native_solc6_compile FluxAggregator.sol -$SCRIPTPATH/native_solc6_compile VRF.sol -$SCRIPTPATH/native_solc6_compile VRFCoordinator.sol -$SCRIPTPATH/native_solc6_compile tests/VRFRequestIDBaseTestHelper.sol -$SCRIPTPATH/native_solc6_compile tests/VRFTestHelper.sol -$SCRIPTPATH/native_solc6_compile Chainlink.sol -$SCRIPTPATH/native_solc6_compile VRFRequestIDBase.sol -$SCRIPTPATH/native_solc6_compile tests/VRFConsumer.sol -$SCRIPTPATH/native_solc6_compile ChainlinkClient.sol -$SCRIPTPATH/native_solc6_compile VRFConsumerBase.sol -$SCRIPTPATH/native_solc6_compile BlockhashStore.sol -$SCRIPTPATH/native_solc6_compile tests/TestAPIConsumer.sol -$SCRIPTPATH/native_solc6_compile tests/MockETHLINKAggregator.sol -$SCRIPTPATH/native_solc6_compile tests/MockGASAggregator.sol - -$SCRIPTPATH/native_solc7_compile tests/MultiWordConsumer.sol -$SCRIPTPATH/native_solc7_compile Operator.sol -$SCRIPTPATH/native_solc7_compile AuthorizedForwarder.sol -$SCRIPTPATH/native_solc7_compile AuthorizedReceiver.sol -$SCRIPTPATH/native_solc7_compile OperatorFactory.sol -$SCRIPTPATH/native_solc7_compile tests/Consumer.sol -$SCRIPTPATH/native_solc7_compile tests/VRFCoordinatorMock.sol - -# Keeper -$SCRIPTPATH/native_solc7_compile KeeperRegistry1_1.sol -$SCRIPTPATH/native_solc7_compile UpkeepRegistrationRequests.sol -$SCRIPTPATH/native_solc7_compile tests/UpkeepPerformCounterRestrictive.sol -$SCRIPTPATH/native_solc7_compile tests/UpkeepCounter.sol -$SCRIPTPATH/native_solc8_6_compile automation/upkeeps/CronUpkeepFactory.sol -$SCRIPTPATH/native_solc8_6_compile automation/1_2/KeeperRegistrar1_2.sol -$SCRIPTPATH/native_solc8_6_compile automation/1_2/KeeperRegistry1_2.sol -$SCRIPTPATH/native_solc8_6_compile automation/1_2/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.sol -$SCRIPTPATH/native_solc8_6_compile automation/1_3/KeeperRegistry1_3.sol -$SCRIPTPATH/native_solc8_6_compile automation/1_3/KeeperRegistryLogic1_3.sol -$SCRIPTPATH/native_solc8_6_compile automation/2_0/KeeperRegistrar2_0.sol -$SCRIPTPATH/native_solc8_6_compile automation/2_0/KeeperRegistry2_0.sol -$SCRIPTPATH/native_solc8_6_compile automation/2_0/KeeperRegistryLogic2_0.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationRegistrar2_1.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistry2_1.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistryLogicA2_1.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/KeeperRegistryLogicB2_1.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/interfaces/ILogAutomation.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationUtils2_1.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/2_1/AutomationForwarderLogic.sol -$SCRIPTPATH/native_solc8_6_compile dev/automation/tests/LogUpkeepCounter.sol -$SCRIPTPATH/native_solc8_16_compile dev/automation/tests/LogTriggeredFeedLookup.sol -$SCRIPTPATH/native_solc8_6_compile automation/UpkeepTranscoder.sol -$SCRIPTPATH/native_solc8_16_compile tests/VerifiableLoadUpkeep.sol -$SCRIPTPATH/native_solc8_16_compile tests/VerifiableLoadMercuryUpkeep.sol -$SCRIPTPATH/native_solc8_16_compile tests/VerifiableLoadLogTriggerUpkeep.sol -$SCRIPTPATH/native_solc8_15_compile tests/MercuryUpkeep.sol -$SCRIPTPATH/native_solc8_15_compile dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol -$SCRIPTPATH/native_solc8_16_compile tests/AutomationConsumerBenchmark.sol -$SCRIPTPATH/native_solc8_6_compile automation/mocks/MockAggregatorProxy.sol - -# Aggregators -$SCRIPTPATH/native_solc8_6_compile interfaces/AggregatorV2V3Interface.sol - -$SCRIPTPATH/native_solc8_6_compile Chainlink.sol -$SCRIPTPATH/native_solc8_6_compile ChainlinkClient.sol - -# VRF -$SCRIPTPATH/native_solc8_6_compile vrf/VRFRequestIDBase.sol -$SCRIPTPATH/native_solc8_6_compile vrf/VRFConsumerBase.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFConsumer.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFRequestIDBaseTestHelper.sol -$SCRIPTPATH/native_solc8_6_compile mocks/VRFCoordinatorMock.sol - -# VRF V2 -$SCRIPTPATH/native_solc8_6_compile vrf/VRFConsumerBaseV2.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFConsumerV2.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFMaliciousConsumerV2.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFTestHelper.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFV2RevertingExample.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFV2ProxyAdmin.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFV2TransparentUpgradeableProxy.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFConsumerV2UpgradeableExample.sol -$SCRIPTPATH/native_solc8_6_compile vrf/BatchBlockhashStore.sol -$SCRIPTPATH/native_solc8_6_compile vrf/BatchVRFCoordinatorV2.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFCoordinatorV2TestHelper.sol -$SCRIPTPATH/native_solc8_6_compile vrf/VRFCoordinatorV2.sol 10000 -$SCRIPTPATH/native_solc8_6_compile vrf/VRFOwner.sol - -# VRF V2Plus -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/VRFCoordinatorV2Plus.sol 1000 -$SCRIPTPATH/native_solc8_6_compile dev/vrf/BatchVRFCoordinatorV2Plus.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/VRFV2PlusWrapper.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFMaliciousConsumerV2Plus.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusExternalSubOwnerExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusSingleConsumerExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusWrapperConsumerExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/libraries/VRFV2PlusClient.sol -$SCRIPTPATH/native_solc8_6_compile dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol - -# VRF V2 Wrapper -$SCRIPTPATH/native_solc8_6_compile vrf/VRFV2Wrapper.sol -$SCRIPTPATH/native_solc8_6_compile interfaces/VRFV2WrapperInterface.sol -$SCRIPTPATH/native_solc8_6_compile vrf/VRFV2WrapperConsumerBase.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFV2WrapperConsumerExample.sol - -# VRF Consumers and Mocks -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFExternalSubOwnerExample.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFSingleConsumerExample.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFOwnerlessConsumerExample.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFLoadTestExternalSubOwner.sol -$SCRIPTPATH/native_solc8_6_compile vrf/testhelpers/VRFV2LoadTestWithMetrics.sol - -# Keepers x VRF v2 -$SCRIPTPATH/native_solc8_6_compile KeepersVRFConsumer.sol - -# Feeds -$SCRIPTPATH/native_solc8_6_compile dev/DerivedPriceFeed.sol - -# Log tester -$SCRIPTPATH/native_solc8_6_compile tests/LogEmitter.sol - -# Chainlink Functions -$SCRIPTPATH/native_solc_compile_all_functions - -# llo-feeds -$SCRIPTPATH/native_solc_compile_all_llo - -# Mocks -$SCRIPTPATH/native_solc8_6_compile mocks/FunctionsOracleEventsMock.sol -$SCRIPTPATH/native_solc8_6_compile mocks/FunctionsBillingRegistryEventsMock.sol -# Transmission -$SCRIPTPATH/transmission/native_solc_compile_all_transmission +# 6 and 7 are legacy contracts, for each other 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 6 7 feeds functions llo transmission vrf automation logpoller +do + $SCRIPTPATH/native_solc_compile_all_$product +done diff --git a/contracts/scripts/native_solc_compile_all_6 b/contracts/scripts/native_solc_compile_all_6 new file mode 100755 index 00000000000..7f8f4fa6957 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_6 @@ -0,0 +1,44 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling legacy Solidity 0.6 contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.6.6" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v0.6 \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.6 \ + $ROOT/contracts/src/v0.6/$1 +} + +compileContract Flags.sol +compileContract Oracle.sol +compileContract FluxAggregator.sol +compileContract VRF.sol +compileContract VRFCoordinator.sol +compileContract tests/VRFRequestIDBaseTestHelper.sol +compileContract tests/VRFTestHelper.sol +compileContract Chainlink.sol +compileContract VRFRequestIDBase.sol +compileContract tests/VRFConsumer.sol +compileContract ChainlinkClient.sol +compileContract VRFConsumerBase.sol +compileContract BlockhashStore.sol +compileContract tests/TestAPIConsumer.sol +compileContract tests/MockETHLINKAggregator.sol +compileContract tests/MockGASAggregator.sol \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_7 b/contracts/scripts/native_solc_compile_all_7 new file mode 100755 index 00000000000..090b0d8baee --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_7 @@ -0,0 +1,41 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling legacy Solidity 0.7 contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.7.6" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v0.7 \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.7 \ + $ROOT/contracts/src/v0.7/$1 +} + +compileContract tests/MultiWordConsumer.sol +compileContract Operator.sol +compileContract AuthorizedForwarder.sol +compileContract AuthorizedReceiver.sol +compileContract OperatorFactory.sol +compileContract tests/Consumer.sol +compileContract tests/VRFCoordinatorMock.sol + +# Keeper/Automation +compileContract KeeperRegistry1_1.sol +compileContract UpkeepRegistrationRequests.sol +compileContract tests/UpkeepPerformCounterRestrictive.sol +compileContract tests/UpkeepCounter.sol \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_automation b/contracts/scripts/native_solc_compile_all_automation new file mode 100755 index 00000000000..5c9c9e8811d --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_automation @@ -0,0 +1,68 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Automation contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.6" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + + +compileContract () { + solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/node_modules\ + $ROOT/contracts/src/v0.8/$1 +} + +compileContract automation/upkeeps/CronUpkeepFactory.sol +compileContract automation/1_2/KeeperRegistrar1_2.sol +compileContract automation/1_2/KeeperRegistry1_2.sol +compileContract automation/1_2/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.sol +compileContract automation/1_3/KeeperRegistry1_3.sol +compileContract automation/1_3/KeeperRegistryLogic1_3.sol +compileContract automation/2_0/KeeperRegistrar2_0.sol +compileContract automation/2_0/KeeperRegistry2_0.sol +compileContract automation/2_0/KeeperRegistryLogic2_0.sol +compileContract automation/UpkeepTranscoder.sol +compileContract automation/mocks/MockAggregatorProxy.sol +compileContract dev/automation/tests/LogUpkeepCounter.sol + +# Keepers x VRF v2 +compileContract KeepersVRFConsumer.sol + + +SOLC_VERSION="0.8.16" + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + +# v0.8.16 +compileContract dev/automation/2_1/AutomationRegistrar2_1.sol +compileContract dev/automation/2_1/KeeperRegistry2_1.sol +compileContract dev/automation/2_1/KeeperRegistryLogicA2_1.sol +compileContract dev/automation/2_1/KeeperRegistryLogicB2_1.sol +compileContract dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +compileContract dev/automation/2_1/interfaces/ILogAutomation.sol +compileContract dev/automation/2_1/AutomationUtils2_1.sol +compileContract dev/automation/2_1/AutomationForwarderLogic.sol +compileContract dev/automation/tests/LogTriggeredFeedLookup.sol +compileContract dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol + +compileContract tests/VerifiableLoadUpkeep.sol +compileContract tests/VerifiableLoadMercuryUpkeep.sol +compileContract tests/VerifiableLoadLogTriggerUpkeep.sol +compileContract tests/AutomationConsumerBenchmark.sol +compileContract tests/MercuryUpkeep.sol diff --git a/contracts/scripts/native_solc_compile_all_feeds b/contracts/scripts/native_solc_compile_all_feeds new file mode 100755 index 00000000000..e37ca833ac6 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_feeds @@ -0,0 +1,35 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Feeds contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.6" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8\ + $ROOT/contracts/src/v0.8/$1 +} + +# Aggregators +compileContract interfaces/AggregatorV2V3Interface.sol +compileContract Chainlink.sol +compileContract ChainlinkClient.sol + +# Feeds +compileContract dev/DerivedPriceFeed.sol \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_functions b/contracts/scripts/native_solc_compile_all_functions index 10aa78bece7..a0d4f146314 100755 --- a/contracts/scripts/native_solc_compile_all_functions +++ b/contracts/scripts/native_solc_compile_all_functions @@ -2,53 +2,59 @@ set -e -# Optionally set optimize runs from arguments (default = 1000000) -OPTIMIZE_RUNS="${2:-1000000}" +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Functions contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.6" +OPTIMIZE_RUNS=1000000 SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt -ROOT="$( - cd "$(dirname "$0")" >/dev/null 2>&1 - cd ../../ && pwd -P -)" +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + compileContract () { - solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ -o $ROOT/contracts/solc/v$SOLC_VERSION/functions/$1 \ --abi --bin \ - --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/src/v0.8/functions,$ROOT/contracts/node_modules/.pnpm/@openzeppelin+contracts-upgradeable@4.8.1/node_modules/@openzeppelin/contracts-upgradeable \ + --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/src/v0.8/functions \ $ROOT/contracts/src/v0.8/functions/$2 } ########################## # Version 0 (Testnet Beta) ########################## -## Set solidity version -SOLC_VERSION="0.8.6" -solc-select install $SOLC_VERSION -solc-select use $SOLC_VERSION -export SOLC_VERSION=$SOLC_VERSION -####################### + compileContract 0_0_0 dev/0_0_0/Functions.sol compileContract 0_0_0 dev/0_0_0/FunctionsBillingRegistry.sol compileContract 0_0_0 dev/0_0_0/FunctionsClient.sol compileContract 0_0_0 dev/0_0_0/FunctionsOracle.sol compileContract 0_0_0 dev/0_0_0/example/FunctionsClientExample.sol + # Test helpers compileContract 0_0_0 tests/0_0_0/testhelpers/FunctionsBillingRegistryWithInit.sol compileContract 0_0_0 tests/0_0_0/testhelpers/FunctionsOracleWithInit.sol +# Mocks +compileContract 0_0_0 ../mocks/FunctionsOracleEventsMock.sol +compileContract 0_0_0 ../mocks/FunctionsBillingRegistryEventsMock.sol + + ############################ # Version 1 (Mainnet Preview) ############################ -## Set solidity version + SOLC_VERSION="0.8.19" solc-select install $SOLC_VERSION solc-select use $SOLC_VERSION export SOLC_VERSION=$SOLC_VERSION -####################### + compileContract 1_0_0 dev/1_0_0/Functions.sol compileContract 1_0_0 dev/1_0_0/FunctionsRouter.sol compileContract 1_0_0 dev/1_0_0/FunctionsCoordinator.sol diff --git a/contracts/scripts/native_solc_compile_all_llo b/contracts/scripts/native_solc_compile_all_llo index b454bcfcb77..0aad167b35a 100755 --- a/contracts/scripts/native_solc_compile_all_llo +++ b/contracts/scripts/native_solc_compile_all_llo @@ -2,6 +2,10 @@ set -e +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Low Latency Oracle contracts... │" +echo " └──────────────────────────────────────────────┘" + SOLC_VERSION="0.8.16" OPTIMIZE_RUNS=15000 diff --git a/contracts/scripts/native_solc_compile_all_logpoller b/contracts/scripts/native_solc_compile_all_logpoller new file mode 100755 index 00000000000..91a0606dba8 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_logpoller @@ -0,0 +1,29 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling LogPoller contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.19" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8\ + $ROOT/contracts/src/v0.8/$1 +} + + +compileContract tests/LogEmitter.sol \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_ocr2vrf b/contracts/scripts/native_solc_compile_all_ocr2vrf index 70576d40727..42478d7ebc2 100755 --- a/contracts/scripts/native_solc_compile_all_ocr2vrf +++ b/contracts/scripts/native_solc_compile_all_ocr2vrf @@ -2,17 +2,38 @@ set -e +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling OCR2 VRF contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.19" +OPTIMIZE_RUNS=1000000 +# The VRF contracts are not contained in the `chainlink` repository. +# Change me. +FOLDER="ocr2vrf-origin" + +echo "Compiling OCR2VRF contracts..." + SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" -echo $SCRIPTPATH +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1; cd ../../ && pwd -P )" python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt -solc-select install 0.8.19 -## Change me. -FOLDER="ocr2vrf-origin" +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + + +compileContract () { + solc --overwrite --optimize --optimize-runs $2 --metadata-hash none \ + -o $ROOT/contracts/solc/v0.8.19 \ + --abi --bin \ + --allow-paths $ROOT/../$FOLDER/contracts \ + $ROOT/$1 +} # OCR2VRF -$SCRIPTPATH/native_solc8_19_compile_ocr2vrf ../../../../$FOLDER/contracts/DKG.sol $FOLDER 1000000 -$SCRIPTPATH/native_solc8_19_compile_ocr2vrf ../../../../$FOLDER/contracts/VRFBeacon.sol $FOLDER 1000000 -$SCRIPTPATH/native_solc8_19_compile_ocr2vrf ../../../../$FOLDER/contracts/VRFCoordinator.sol $FOLDER 1 -$SCRIPTPATH/native_solc8_19_compile_ocr2vrf ../../../../$FOLDER/contracts/test/TestBeaconVRFConsumer.sol $FOLDER 1000000 -$SCRIPTPATH/native_solc8_19_compile_ocr2vrf ../../../../$FOLDER/contracts/test/LoadTestBeaconVRFConsumer.sol $FOLDER 1000000 +compileContract ../$FOLDER/contracts/DKG.sol $OPTIMIZE_RUNS +compileContract ../$FOLDER/contracts/VRFBeacon.sol $OPTIMIZE_RUNS +compileContract ../$FOLDER/contracts/VRFCoordinator.sol 1 +compileContract ../$FOLDER/contracts/test/TestBeaconVRFConsumer.sol $OPTIMIZE_RUNS +compileContract ../$FOLDER/contracts/test/LoadTestBeaconVRFConsumer.sol $OPTIMIZE_RUNS diff --git a/contracts/scripts/native_solc_compile_all_transmission b/contracts/scripts/native_solc_compile_all_transmission new file mode 100755 index 00000000000..6537757f429 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_transmission @@ -0,0 +1,37 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Transmission contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.15" +OPTIMIZE_RUNS=1000000 + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8\ + $ROOT/contracts/src/v0.8/$1 +} + +# Contracts +compileContract dev/transmission/4337/SCA.sol +compileContract dev/transmission/4337/Paymaster.sol +compileContract dev/transmission/4337/SmartContractAccountFactory.sol + +# Testhelpers +compileContract dev/transmission/testhelpers/SmartContractAccountHelper.sol +compileContract dev/transmission/testhelpers/Greeter.sol + +# Vendor +compileContract vendor/entrypoint/core/EntryPoint.sol diff --git a/contracts/scripts/native_solc_compile_all_vrf b/contracts/scripts/native_solc_compile_all_vrf new file mode 100755 index 00000000000..bce353df965 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_vrf @@ -0,0 +1,84 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling VRF contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.6" +OPTIMIZE_RUNS=1000000 + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + +compileContract () { + solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/node_modules\ + $ROOT/contracts/src/v0.8/$1 +} + +compileContractAltOpts () { + solc @openzeppelin/=$ROOT/contracts/node_modules/@openzeppelin/ --overwrite --optimize --optimize-runs $2 --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8,$ROOT/contracts/node_modules\ + $ROOT/contracts/src/v0.8/$1 +} + +# VRF +compileContract vrf/VRFRequestIDBase.sol +compileContract vrf/VRFConsumerBase.sol +compileContract vrf/testhelpers/VRFConsumer.sol +compileContract vrf/testhelpers/VRFRequestIDBaseTestHelper.sol +compileContract mocks/VRFCoordinatorMock.sol + +# VRF V2 +compileContract vrf/VRFConsumerBaseV2.sol +compileContract vrf/testhelpers/VRFConsumerV2.sol +compileContract vrf/testhelpers/VRFMaliciousConsumerV2.sol +compileContract vrf/testhelpers/VRFTestHelper.sol +compileContract vrf/testhelpers/VRFV2RevertingExample.sol +compileContract vrf/testhelpers/VRFV2ProxyAdmin.sol +compileContract vrf/testhelpers/VRFV2TransparentUpgradeableProxy.sol +compileContract vrf/testhelpers/VRFConsumerV2UpgradeableExample.sol +compileContract vrf/BatchBlockhashStore.sol +compileContract vrf/BatchVRFCoordinatorV2.sol +compileContract vrf/testhelpers/VRFCoordinatorV2TestHelper.sol +compileContractAltOpts vrf/VRFCoordinatorV2.sol 10000 +compileContract vrf/VRFOwner.sol + +# VRF V2Plus +compileContract dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol +compileContractAltOpts dev/vrf/VRFCoordinatorV2Plus.sol 1000 +compileContract dev/vrf/BatchVRFCoordinatorV2Plus.sol +compileContract dev/vrf/VRFV2PlusWrapper.sol +compileContract dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol +compileContract dev/vrf/testhelpers/VRFMaliciousConsumerV2Plus.sol +compileContract dev/vrf/testhelpers/VRFV2PlusExternalSubOwnerExample.sol +compileContract dev/vrf/testhelpers/VRFV2PlusSingleConsumerExample.sol +compileContract dev/vrf/testhelpers/VRFV2PlusWrapperConsumerExample.sol +compileContract dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol +compileContract dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol +compileContract dev/vrf/libraries/VRFV2PlusClient.sol +compileContract dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol + +# VRF V2 Wrapper +compileContract vrf/VRFV2Wrapper.sol +compileContract interfaces/VRFV2WrapperInterface.sol +compileContract vrf/VRFV2WrapperConsumerBase.sol +compileContract vrf/testhelpers/VRFV2WrapperConsumerExample.sol + +# VRF Consumers and Mocks +compileContract vrf/testhelpers/VRFExternalSubOwnerExample.sol +compileContract vrf/testhelpers/VRFSingleConsumerExample.sol +compileContract vrf/testhelpers/VRFOwnerlessConsumerExample.sol +compileContract vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol +compileContract vrf/testhelpers/VRFLoadTestExternalSubOwner.sol +compileContract vrf/testhelpers/VRFV2LoadTestWithMetrics.sol + diff --git a/contracts/scripts/native_solc_compile_events_mock b/contracts/scripts/native_solc_compile_events_mock deleted file mode 100755 index 381e4068d57..00000000000 --- a/contracts/scripts/native_solc_compile_events_mock +++ /dev/null @@ -1,12 +0,0 @@ -#!/usr/bin/env bash - -set -e - -SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" -echo $SCRIPTPATH -python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt -solc-select install 0.8.6 - -# Mocks -$SCRIPTPATH/native_solc8_6_compile mocks/FunctionsOracleEventsMock.sol -$SCRIPTPATH/native_solc8_6_compile mocks/FunctionsBillingRegistryEventsMock.sol \ No newline at end of file diff --git a/contracts/scripts/transmission/native_solc_compile_all_transmission b/contracts/scripts/transmission/native_solc_compile_all_transmission deleted file mode 100755 index 0e4752d2735..00000000000 --- a/contracts/scripts/transmission/native_solc_compile_all_transmission +++ /dev/null @@ -1,20 +0,0 @@ -#!/usr/bin/env bash - -set -e - -SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ..; pwd -P )" -echo $SCRIPTPATH -python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt -solc-select install 0.8.15 - -# Contracts -$SCRIPTPATH/native_solc8_15_compile dev/transmission/4337/SCA.sol -$SCRIPTPATH/native_solc8_15_compile dev/transmission/4337/Paymaster.sol -$SCRIPTPATH/native_solc8_15_compile dev/transmission/4337/SmartContractAccountFactory.sol - -# Testhelpers -$SCRIPTPATH/native_solc8_15_compile dev/transmission/testhelpers/SmartContractAccountHelper.sol -$SCRIPTPATH/native_solc8_15_compile dev/transmission/testhelpers/Greeter.sol - -# Vendor -$SCRIPTPATH/native_solc8_15_compile vendor/entrypoint/core/EntryPoint.sol diff --git a/contracts/src/v0.8/tests/LogEmitter.sol b/contracts/src/v0.8/tests/LogEmitter.sol index 4d7b9799eb1..d3f950c5ccb 100644 --- a/contracts/src/v0.8/tests/LogEmitter.sol +++ b/contracts/src/v0.8/tests/LogEmitter.sol @@ -1,3 +1,4 @@ +// SPDX-License-Identifier: MIT pragma solidity ^0.8.0; contract LogEmitter { diff --git a/contracts/src/v0.8/tests/MercuryUpkeep.sol b/contracts/src/v0.8/tests/MercuryUpkeep.sol index f523aa528c6..941670b338a 100644 --- a/contracts/src/v0.8/tests/MercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/MercuryUpkeep.sol @@ -1,4 +1,4 @@ -pragma solidity 0.8.15; +pragma solidity 0.8.16; import "../interfaces/automation/AutomationCompatibleInterface.sol"; import "../dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol"; diff --git a/core/gethwrappers/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go b/core/gethwrappers/functions/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go similarity index 100% rename from core/gethwrappers/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go rename to core/gethwrappers/functions/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go diff --git a/core/gethwrappers/generated/functions_oracle_events_mock/functions_oracle_events_mock.go b/core/gethwrappers/functions/generated/functions_oracle_events_mock/functions_oracle_events_mock.go similarity index 100% rename from core/gethwrappers/generated/functions_oracle_events_mock/functions_oracle_events_mock.go rename to core/gethwrappers/functions/generated/functions_oracle_events_mock/functions_oracle_events_mock.go diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 0f2a76161d2..51f2da2f2ab 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,9 +1,11 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a6a0fae8fe9c6124f03bf66208fc74eac185be57919e9a3906f4020f0bde2074 +functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 9f3279ec5b9d6e724c596b5e315a07d64dea43e26f33eacd38145790d0cb92d6 +functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 2047f8424d3038672f347ef5e6b401f0347b42f64defd43033cc75e0ac537287 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 diff --git a/core/gethwrappers/functions/go_generate.go b/core/gethwrappers/functions/go_generate.go index 54d5ea4fe66..d46b233e98c 100644 --- a/core/gethwrappers/functions/go_generate.go +++ b/core/gethwrappers/functions/go_generate.go @@ -11,6 +11,9 @@ package gethwrappers //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleWithInit.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleWithInit.bin OCR2DROracle ocr2dr_oracle //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryWithInit.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryWithInit.bin OCR2DRRegistry ocr2dr_registry +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin FunctionsOracleEventsMock functions_oracle_events_mock +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin FunctionsBillingRegistryEventsMock functions_billing_registry_events_mock + // Version 1 (Mainnet Preview) //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin Functions functions //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin FunctionsClient functions_client diff --git a/core/gethwrappers/generated/log_emitter/log_emitter.go b/core/gethwrappers/generated/log_emitter/log_emitter.go index 84fe5d5d6fe..4f0189dfdea 100644 --- a/core/gethwrappers/generated/log_emitter/log_emitter.go +++ b/core/gethwrappers/generated/log_emitter/log_emitter.go @@ -32,7 +32,7 @@ var ( var LogEmitterMetaData = &bind.MetaData{ ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"Log1\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"Log2\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"name\":\"Log3\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"v\",\"type\":\"uint256[]\"}],\"name\":\"EmitLog1\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"v\",\"type\":\"uint256[]\"}],\"name\":\"EmitLog2\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"v\",\"type\":\"string[]\"}],\"name\":\"EmitLog3\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b5061053e806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063696933c914610046578063bc253bc01461005b578063d9c21f461461006e575b600080fd5b6100596100543660046102f5565b610081565b005b6100596100693660046102f5565b6100f5565b61005961007c3660046101c7565b610159565b60005b81518110156100f1577f46692c0e59ca9cd1ad8f984a9d11715ec83424398b7eed4e05c8ce84662415a88282815181106100c0576100c06104d3565b60200260200101516040516100d791815260200190565b60405180910390a1806100e981610473565b915050610084565b5050565b60005b81518110156100f157818181518110610113576101136104d3565b60200260200101517f624fb00c2ce79f34cb543884c3af64816dce0f4cec3d32661959e49d488a7a9360405160405180910390a28061015181610473565b9150506100f8565b60005b81518110156100f1577fb94ec34dfe32a8a7170992a093976368d1e63decf8f0bc0b38a8eb89cc9f95cf828281518110610198576101986104d3565b60200260200101516040516101ad919061038d565b60405180910390a1806101bf81610473565b91505061015c565b600060208083850312156101da57600080fd5b823567ffffffffffffffff808211156101f257600080fd5b8185019150601f868184011261020757600080fd5b823561021a6102158261044f565b610400565b8082825286820191508686018a888560051b890101111561023a57600080fd5b60005b848110156102e55781358781111561025457600080fd5b8801603f81018d1361026557600080fd5b8981013560408982111561027b5761027b610502565b6102aa8c7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08b85011601610400565b8281528f828486010111156102be57600080fd5b828285018e83013760009281018d019290925250855250928801929088019060010161023d565b50909a9950505050505050505050565b6000602080838503121561030857600080fd5b823567ffffffffffffffff81111561031f57600080fd5b8301601f8101851361033057600080fd5b803561033e6102158261044f565b80828252848201915084840188868560051b870101111561035e57600080fd5b600094505b83851015610381578035835260019490940193918501918501610363565b50979650505050505050565b600060208083528351808285015260005b818110156103ba5785810183015185820160400152820161039e565b818111156103cc576000604083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016929092016040019392505050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561044757610447610502565b604052919050565b600067ffffffffffffffff82111561046957610469610502565b5060051b60200190565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8214156104cc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", + Bin: "0x608060405234801561001057600080fd5b5061052b806100206000396000f3fe608060405234801561001057600080fd5b50600436106100415760003560e01c8063696933c914610046578063bc253bc01461005b578063d9c21f461461006e575b600080fd5b610059610054366004610269565b610081565b005b610059610069366004610269565b6100f5565b61005961007c3660046102ff565b610159565b60005b81518110156100f1577f46692c0e59ca9cd1ad8f984a9d11715ec83424398b7eed4e05c8ce84662415a88282815181106100c0576100c0610424565b60200260200101516040516100d791815260200190565b60405180910390a1806100e981610453565b915050610084565b5050565b60005b81518110156100f15781818151811061011357610113610424565b60200260200101517f624fb00c2ce79f34cb543884c3af64816dce0f4cec3d32661959e49d488a7a9360405160405180910390a28061015181610453565b9150506100f8565b60005b81518110156100f1577fb94ec34dfe32a8a7170992a093976368d1e63decf8f0bc0b38a8eb89cc9f95cf82828151811061019857610198610424565b60200260200101516040516101ad91906104b2565b60405180910390a1806101bf81610453565b91505061015c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561023d5761023d6101c7565b604052919050565b600067ffffffffffffffff82111561025f5761025f6101c7565b5060051b60200190565b6000602080838503121561027c57600080fd5b823567ffffffffffffffff81111561029357600080fd5b8301601f810185136102a457600080fd5b80356102b76102b282610245565b6101f6565b81815260059190911b820183019083810190878311156102d657600080fd5b928401925b828410156102f4578335825292840192908401906102db565b979650505050505050565b6000602080838503121561031257600080fd5b823567ffffffffffffffff8082111561032a57600080fd5b8185019150601f868184011261033f57600080fd5b823561034d6102b282610245565b81815260059190911b8401850190858101908983111561036c57600080fd5b8686015b83811015610416578035868111156103885760008081fd5b8701603f81018c1361039a5760008081fd5b888101356040888211156103b0576103b06101c7565b6103df8b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08a850116016101f6565b8281528e828486010111156103f45760008081fd5b828285018d83013760009281018c019290925250845250918701918701610370565b509998505050505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036104ab577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b5060010190565b600060208083528351808285015260005b818110156104df578581018301518582016040015282016104c3565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116850101925050509291505056fea164736f6c6343000813000a", } var LogEmitterABI = LogEmitterMetaData.ABI diff --git a/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go b/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go index 86dab6cf1b4..9d4d49cbab7 100644 --- a/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go +++ b/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go @@ -32,7 +32,7 @@ var ( var MercuryUpkeepMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_testRange\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_useL1BlockNumber\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"origin\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"v0\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"v1\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"ed\",\"type\":\"bytes\"}],\"name\":\"MercuryPerformEvent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"callbackReturnBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"counter\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feeds\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"interval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"previousPerformBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"setCallbackReturnBool\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"setShouldRevertCallback\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"shouldRevertCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"testRange\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useL1BlockNumber\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162001312380380620013128339810160408190526200003491620001f7565b60008381556001839055600281905560038190556004556040805180820190915260098152680cccacac8928890caf60bb1b60208201526006906200007a9082620002dc565b5060405180604001604052806040518060800160405280604281526020016200128e604291398152602001604051806080016040528060428152602001620012d0604291399052620000d190600590600262000120565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152600790620001039082620002dc565b50151560805250506008805461ff001916610100179055620003a8565b8280548282559060005260206000209081019282156200016b579160200282015b828111156200016b57825182906200015a9082620002dc565b509160200191906001019062000141565b50620001799291506200017d565b5090565b80821115620001795760006200019482826200019e565b506001016200017d565b508054620001ac906200024d565b6000825580601f10620001bd575050565b601f016020900490600052602060002090810190620001dd9190620001e0565b50565b5b80821115620001795760008155600101620001e1565b6000806000606084860312156200020d57600080fd5b8351925060208401519150604084015180151581146200022c57600080fd5b809150509250925092565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200026257607f821691505b6020821081036200028357634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002d757600081815260208120601f850160051c81016020861015620002b25750805b601f850160051c820191505b81811015620002d357828155600101620002be565b5050505b505050565b81516001600160401b03811115620002f857620002f862000237565b62000310816200030984546200024d565b8462000289565b602080601f8311600181146200034857600084156200032f5750858301515b600019600386901b1c1916600185901b178555620002d3565b600085815260208120601f198616915b82811015620003795788860151825594840194600190910190840162000358565b5085821015620003985787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b608051610eb5620003d960003960008181610170015281816102bf015281816105ef01526107220152610eb56000f3fe608060405234801561001057600080fd5b506004361061011b5760003560e01c80635b48391a116100b2578063917d895f11610081578063afb28d1f11610066578063afb28d1f146102a3578063c98f10b0146102ab578063d832d92f146102b357600080fd5b8063917d895f14610291578063947a36fb1461029a57600080fd5b80635b48391a1461022757806361bc221a1461026c5780636250a13a146102755780636e04ff0d1461027e57600080fd5b80634585e33b116100ee5780634585e33b146101925780634a5479f3146101a75780634b56a42e146101c75780634bdb3862146101e857600080fd5b806302be021f14610120578063102d538b146101425780632cb15864146101545780632d02b93b1461016b575b600080fd5b60085461012d9060ff1681565b60405190151581526020015b60405180910390f35b60085461012d90610100900460ff1681565b61015d60035481565b604051908152602001610139565b61012d7f000000000000000000000000000000000000000000000000000000000000000081565b6101a56101a03660046107f1565b6102bb565b005b6101ba6101b5366004610863565b610414565b60405161013991906108e7565b6101da6101d5366004610a0d565b6104c0565b604051610139929190610af3565b6101a56101f6366004610b16565b600880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b6101a5610235366004610b16565b60088054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b61015d60045481565b61015d60005481565b6101da61028c3660046107f1565b610593565b61015d60025481565b61015d60015481565b6101ba6106f2565b6101ba6106ff565b61012d61070c565b60007f0000000000000000000000000000000000000000000000000000000000000000156102ea57504361035d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610336573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061035a9190610b38565b90505b60035460000361036d5760038190555b60008061037c84860186610a0d565b60028590556004549193509150610394906001610b80565b60045581518390339032907fec3208363089f292bf230caa1cd39f9dc25d98a341b935d9ebd7a95e2ec82af19086906000906103d2576103d2610b98565b6020026020010151866001815181106103ed576103ed610b98565b60200260200101518660405161040593929190610bc7565b60405180910390a45050505050565b6005818154811061042457600080fd5b90600052602060002001600091509050805461043f90610c0a565b80601f016020809104026020016040519081016040528092919081815260200182805461046b90610c0a565b80156104b85780601f1061048d576101008083540402835291602001916104b8565b820191906000526020600020905b81548152906001019060200180831161049b57829003601f168201915b505050505081565b60085460009060609060ff1615610538576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f73686f756c6452657665727443616c6c6261636b20697320747275650000000060448201526064015b60405180910390fd5b6000848460405160200161054d929190610c5d565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152919052600854610100900460ff1693509150505b9250929050565b6000606061059f61070c565b6105eb576000848481818080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525095975091955061058c945050505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561061a57504361068d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610666573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061068a9190610b38565b90505b604080516c6400000000000000000000000060208201528151601481830301815260348201928390527f7ddd933e0000000000000000000000000000000000000000000000000000000090925261052f91600691600591600791869190603801610dce565b6006805461043f90610c0a565b6007805461043f90610c0a565b600060035460000361071e5750600190565b60007f00000000000000000000000000000000000000000000000000000000000000001561074d5750436107c0565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610799573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107bd9190610b38565b90505b6000546003546107d09083610e91565b1080156107eb57506001546002546107e89083610e91565b10155b91505090565b6000806020838503121561080457600080fd5b823567ffffffffffffffff8082111561081c57600080fd5b818501915085601f83011261083057600080fd5b81358181111561083f57600080fd5b86602082850101111561085157600080fd5b60209290920196919550909350505050565b60006020828403121561087557600080fd5b5035919050565b6000815180845260005b818110156108a257602081850181015186830182015201610886565b818111156108b4576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006108fa602083018461087c565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561097757610977610901565b604052919050565b600082601f83011261099057600080fd5b813567ffffffffffffffff8111156109aa576109aa610901565b6109db60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610930565b8181528460208386010111156109f057600080fd5b816020850160208301376000918101602001919091529392505050565b60008060408385031215610a2057600080fd5b823567ffffffffffffffff80821115610a3857600080fd5b818501915085601f830112610a4c57600080fd5b8135602082821115610a6057610a60610901565b8160051b610a6f828201610930565b928352848101820192828101908a851115610a8957600080fd5b83870192505b84831015610ac557823586811115610aa75760008081fd5b610ab58c86838b010161097f565b8352509183019190830190610a8f565b9750505086013592505080821115610adc57600080fd5b50610ae98582860161097f565b9150509250929050565b8215158152604060208201526000610b0e604083018461087c565b949350505050565b600060208284031215610b2857600080fd5b813580151581146108fa57600080fd5b600060208284031215610b4a57600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60008219821115610b9357610b93610b51565b500190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b606081526000610bda606083018661087c565b8281036020840152610bec818661087c565b90508281036040840152610c00818561087c565b9695505050505050565b600181811c90821680610c1e57607f821691505b602082108103610c57577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610cd2577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610cc086835161087c565b95509382019390820190600101610c86565b505085840381870152505050610ce8818561087c565b95945050505050565b8054600090600181811c9080831680610d0b57607f831692505b60208084108203610d45577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b838852818015610d5c5760018114610d9457610dc2565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008616828a01528185151560051b8a01019650610dc2565b876000528160002060005b86811015610dba5781548b8201850152908501908301610d9f565b8a0183019750505b50505050505092915050565b60a081526000610de160a0830188610cf1565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610e53577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610e418383610cf1565b94860194925060019182019101610e08565b50508681036040880152610e67818b610cf1565b9450505050508460608401528281036080840152610e85818561087c565b98975050505050505050565b600082821015610ea357610ea3610b51565b50039056fea164736f6c634300080f000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001308380380620013088339810160408190526200003491620001f7565b60008381556001839055600281905560038190556004556040805180820190915260098152680cccacac8928890caf60bb1b60208201526006906200007a9082620002dc565b50604051806040016040528060405180608001604052806042815260200162001284604291398152602001604051806080016040528060428152602001620012c6604291399052620000d190600590600262000120565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152600790620001039082620002dc565b50151560805250506008805461ff001916610100179055620003a8565b8280548282559060005260206000209081019282156200016b579160200282015b828111156200016b57825182906200015a9082620002dc565b509160200191906001019062000141565b50620001799291506200017d565b5090565b80821115620001795760006200019482826200019e565b506001016200017d565b508054620001ac906200024d565b6000825580601f10620001bd575050565b601f016020900490600052602060002090810190620001dd9190620001e0565b50565b5b80821115620001795760008155600101620001e1565b6000806000606084860312156200020d57600080fd5b8351925060208401519150604084015180151581146200022c57600080fd5b809150509250925092565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200026257607f821691505b6020821081036200028357634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002d757600081815260208120601f850160051c81016020861015620002b25750805b601f850160051c820191505b81811015620002d357828155600101620002be565b5050505b505050565b81516001600160401b03811115620002f857620002f862000237565b62000310816200030984546200024d565b8462000289565b602080601f8311600181146200034857600084156200032f5750858301515b600019600386901b1c1916600185901b178555620002d3565b600085815260208120601f198616915b82811015620003795788860151825594840194600190910190840162000358565b5085821015620003985787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b608051610eab620003d960003960008181610170015281816102bf015281816105ef01526107220152610eab6000f3fe608060405234801561001057600080fd5b506004361061011b5760003560e01c80635b48391a116100b2578063917d895f11610081578063afb28d1f11610066578063afb28d1f146102a3578063c98f10b0146102ab578063d832d92f146102b357600080fd5b8063917d895f14610291578063947a36fb1461029a57600080fd5b80635b48391a1461022757806361bc221a1461026c5780636250a13a146102755780636e04ff0d1461027e57600080fd5b80634585e33b116100ee5780634585e33b146101925780634a5479f3146101a75780634b56a42e146101c75780634bdb3862146101e857600080fd5b806302be021f14610120578063102d538b146101425780632cb15864146101545780632d02b93b1461016b575b600080fd5b60085461012d9060ff1681565b60405190151581526020015b60405180910390f35b60085461012d90610100900460ff1681565b61015d60035481565b604051908152602001610139565b61012d7f000000000000000000000000000000000000000000000000000000000000000081565b6101a56101a03660046107f1565b6102bb565b005b6101ba6101b5366004610863565b610414565b60405161013991906108e0565b6101da6101d5366004610a06565b6104c0565b604051610139929190610aec565b6101a56101f6366004610b0f565b600880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b6101a5610235366004610b0f565b60088054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b61015d60045481565b61015d60005481565b6101da61028c3660046107f1565b610593565b61015d60025481565b61015d60015481565b6101ba6106f2565b6101ba6106ff565b61012d61070c565b60007f0000000000000000000000000000000000000000000000000000000000000000156102ea57504361035d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610336573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061035a9190610b31565b90505b60035460000361036d5760038190555b60008061037c84860186610a06565b60028590556004549193509150610394906001610b79565b60045581518390339032907fec3208363089f292bf230caa1cd39f9dc25d98a341b935d9ebd7a95e2ec82af19086906000906103d2576103d2610b92565b6020026020010151866001815181106103ed576103ed610b92565b60200260200101518660405161040593929190610bc1565b60405180910390a45050505050565b6005818154811061042457600080fd5b90600052602060002001600091509050805461043f90610c04565b80601f016020809104026020016040519081016040528092919081815260200182805461046b90610c04565b80156104b85780601f1061048d576101008083540402835291602001916104b8565b820191906000526020600020905b81548152906001019060200180831161049b57829003601f168201915b505050505081565b60085460009060609060ff1615610538576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f73686f756c6452657665727443616c6c6261636b20697320747275650000000060448201526064015b60405180910390fd5b6000848460405160200161054d929190610c57565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152919052600854610100900460ff1693509150505b9250929050565b6000606061059f61070c565b6105eb576000848481818080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525095975091955061058c945050505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561061a57504361068d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610666573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061068a9190610b31565b90505b604080516c6400000000000000000000000060208201528151601481830301815260348201928390527f7ddd933e0000000000000000000000000000000000000000000000000000000090925261052f91600691600591600791869190603801610dc8565b6006805461043f90610c04565b6007805461043f90610c04565b600060035460000361071e5750600190565b60007f00000000000000000000000000000000000000000000000000000000000000001561074d5750436107c0565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610799573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107bd9190610b31565b90505b6000546003546107d09083610e8b565b1080156107eb57506001546002546107e89083610e8b565b10155b91505090565b6000806020838503121561080457600080fd5b823567ffffffffffffffff8082111561081c57600080fd5b818501915085601f83011261083057600080fd5b81358181111561083f57600080fd5b86602082850101111561085157600080fd5b60209290920196919550909350505050565b60006020828403121561087557600080fd5b5035919050565b6000815180845260005b818110156108a257602081850181015186830182015201610886565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006108f3602083018461087c565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610970576109706108fa565b604052919050565b600082601f83011261098957600080fd5b813567ffffffffffffffff8111156109a3576109a36108fa565b6109d460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610929565b8181528460208386010111156109e957600080fd5b816020850160208301376000918101602001919091529392505050565b60008060408385031215610a1957600080fd5b823567ffffffffffffffff80821115610a3157600080fd5b818501915085601f830112610a4557600080fd5b8135602082821115610a5957610a596108fa565b8160051b610a68828201610929565b928352848101820192828101908a851115610a8257600080fd5b83870192505b84831015610abe57823586811115610aa05760008081fd5b610aae8c86838b0101610978565b8352509183019190830190610a88565b9750505086013592505080821115610ad557600080fd5b50610ae285828601610978565b9150509250929050565b8215158152604060208201526000610b07604083018461087c565b949350505050565b600060208284031215610b2157600080fd5b813580151581146108f357600080fd5b600060208284031215610b4357600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610b8c57610b8c610b4a565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b606081526000610bd4606083018661087c565b8281036020840152610be6818661087c565b90508281036040840152610bfa818561087c565b9695505050505050565b600181811c90821680610c1857607f821691505b602082108103610c51577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610ccc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610cba86835161087c565b95509382019390820190600101610c80565b505085840381870152505050610ce2818561087c565b95945050505050565b8054600090600181811c9080831680610d0557607f831692505b60208084108203610d3f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b838852818015610d565760018114610d8e57610dbc565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008616828a01528185151560051b8a01019650610dbc565b876000528160002060005b86811015610db45781548b8201850152908501908301610d99565b8a0183019750505b50505050505092915050565b60a081526000610ddb60a0830188610ceb565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610e4d577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610e3b8383610ceb565b94860194925060019182019101610e02565b50508681036040880152610e61818b610ceb565b9450505050508460608401528281036080840152610e7f818561087c565b98975050505050505050565b81810381811115610b8c57610b8c610b4a56fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var MercuryUpkeepABI = MercuryUpkeepMetaData.ABI diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 2289abb182a..7f86257ee45 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -15,11 +15,9 @@ consumer_wrapper: ../../contracts/solc/v0.7/Consumer.abi ../../contracts/solc/v0 cron_upkeep_factory_wrapper: ../../contracts/solc/v0.8.6/CronUpkeepFactory.abi - dacb0f8cdf54ae9d2781c5e720fc314b32ed5e58eddccff512c75d6067292cd7 cron_upkeep_wrapper: ../../contracts/solc/v0.8.6/CronUpkeep.abi - 362fcfcf30a6ab3acff83095ea4b2b9056dd5e9dcb94bc5411aae58995d22709 derived_price_feed_wrapper: ../../contracts/solc/v0.8.6/DerivedPriceFeed.abi ../../contracts/solc/v0.8.6/DerivedPriceFeed.bin c8542e6c850c2d0fffb79a7f7213dc927ec64e6ddd54e1224cb2fb4a13aabdd0 -feed_lookup_compatible_interface: ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.bin 2c5c2cb669a666ab6f14e7fdbd11ea019997e3860f56ccfaf112156e412f1b15 +feed_lookup_compatible_interface: ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.bin 2c5c2cb669a666ab6f14e7fdbd11ea019997e3860f56ccfaf112156e412f1b15 flags_wrapper: ../../contracts/solc/v0.6/Flags.abi ../../contracts/solc/v0.6/Flags.bin 2034d1b562ca37a63068851915e3703980276e8d5f7db6db8a3351a49d69fc4a flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../contracts/solc/v0.6/FluxAggregator.bin a3b0a6396c4aa3b5ee39b3c4bd45efc89789d4859379a8a92caca3a0496c5794 -functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 -functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin fb976990e21d6c454245bcd3247d71b2f045a7c5636adaebfe64b7449cb6042e i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc @@ -37,11 +35,11 @@ keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 -log_emitter: ../../contracts/solc/v0.8.6/LogEmitter.abi ../../contracts/solc/v0.8.6/LogEmitter.bin 375488d19b6ee1c180d42048be10abea9146e2a58347fd180358850d435cb854 +log_emitter: ../../contracts/solc/v0.8.19/LogEmitter.abi ../../contracts/solc/v0.8.19/LogEmitter.bin 244ba13730c036de0b02beef4e3d9c9a96946ce353c27f366baecc7f5be5a6fd log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin b16d9cafc51d85c4cd0b32fe0f53e37243b769585c5473c6f0e2c5db7dafc817 log_upkeep_counter_wrapper: ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin 13d6543329f89d06cbf3901d7f9ecdc42acc1a84d8c61db291fcbfdbe1138eb1 mercury_exposed_verifier: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 -mercury_upkeep_wrapper: ../../contracts/solc/v0.8.15/MercuryUpkeep.abi ../../contracts/solc/v0.8.15/MercuryUpkeep.bin c4627433ed9ebe7f8cf6594f577b4a1826ce6f2209271895a885fd4b3017320e +mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/MercuryUpkeep.abi ../../contracts/solc/v0.8.16/MercuryUpkeep.bin f19fbcaf789578996cf7d5dc3c2adbad33b661c2d8bb71daf1b87b57a0678564 mercury_verifier: ../../contracts/solc/v0.8.16/Verifier.abi ../../contracts/solc/v0.8.16/Verifier.bin 24b2db0d5db8e0198bb7eae2ecde65f2596df4bcc7b17d604d25300546c1694e mercury_verifier_proxy: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 mock_aggregator_proxy: ../../contracts/solc/v0.8.6/MockAggregatorProxy.abi ../../contracts/solc/v0.8.6/MockAggregatorProxy.bin b16c108f3dd384c342ddff5e94da7c0a8d39d1be5e3d8f2cf61ecc7f0e50ff42 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index b7e31a9281a..c08c0d3d11c 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -47,8 +47,8 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadUpkeep.bin VerifiableLoadUpkeep verifiable_load_upkeep_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadMercuryUpkeep.bin VerifiableLoadMercuryUpkeep verifiable_load_mercury_upkeep_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.abi ../../contracts/solc/v0.8.16/VerifiableLoadLogTriggerUpkeep.bin VerifiableLoadLogTriggerUpkeep verifiable_load_log_trigger_upkeep_wrapper -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.15/MercuryUpkeep.abi ../../contracts/solc/v0.8.15/MercuryUpkeep.bin MercuryUpkeep mercury_upkeep_wrapper -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.15/FeedLookupCompatibleInterface.bin FeedLookupCompatibleInterface feed_lookup_compatible_interface +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/MercuryUpkeep.abi ../../contracts/solc/v0.8.16/MercuryUpkeep.bin MercuryUpkeep mercury_upkeep_wrapper +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.bin FeedLookupCompatibleInterface feed_lookup_compatible_interface //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.abi ../../contracts/solc/v0.8.16/AutomationConsumerBenchmark.bin AutomationConsumerBenchmark automation_consumer_benchmark //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationRegistrar2_1.abi ../../contracts/solc/v0.8.16/AutomationRegistrar2_1.bin AutomationRegistrar automation_registrar_wrapper2_1 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin KeeperRegistry keeper_registry_wrapper_2_1 @@ -121,7 +121,7 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/MockAggregatorProxy.abi ../../contracts/solc/v0.8.6/MockAggregatorProxy.bin MockAggregatorProxy mock_aggregator_proxy // Log tester -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/LogEmitter.abi ../../contracts/solc/v0.8.6/LogEmitter.bin LogEmitter log_emitter +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.19/LogEmitter.abi ../../contracts/solc/v0.8.19/LogEmitter.bin LogEmitter log_emitter // Chainlink Functions //go:generate go generate ./functions @@ -134,9 +134,6 @@ package gethwrappers // Mocks that contain only events and functions to emit them //go:generate go run ./generation/generate_events_mock/create_events_mock_contract.go ../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracle.abi ../../contracts/src/v0.8/mocks/FunctionsOracleEventsMock.sol FunctionsOracleEventsMock //go:generate go run ./generation/generate_events_mock/create_events_mock_contract.go ../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistry.abi ../../contracts/src/v0.8/mocks/FunctionsBillingRegistryEventsMock.sol FunctionsBillingRegistryEventsMock -//go:generate ./generation/compile_event_mock_contract.sh -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin FunctionsOracleEventsMock functions_oracle_events_mock -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin FunctionsBillingRegistryEventsMock functions_billing_registry_events_mock // Transmission //go:generate go generate ./transmission diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 4089174e012..186ebe2080e 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -10,18 +10,17 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/rs/zerolog/log" - + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/libocr/gethwrappers/offchainaggregator" "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - + eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_billing_registry_events_mock" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flags_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper2_0" @@ -39,8 +38,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/oracle_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/test_api_consumer_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/upkeep_transcoder" - - eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" ) // ContractDeployer is an interface for abstracting the contract deployment methods across network implementations diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index 8e54a5b15bb..8d8dff3dab7 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -8,17 +8,15 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" - "github.com/smartcontractkit/libocr/gethwrappers/offchainaggregator" "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" ocrConfigHelper2 "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/operator_factory" - - "github.com/smartcontractkit/chainlink/integration-tests/client" ) type FluxAggregatorOptions struct { diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index 2f64122b299..dac0c3d3c0b 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -12,18 +12,19 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/rs/zerolog/log" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/libocr/gethwrappers/offchainaggregator" "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" ocrTypes "github.com/smartcontractkit/libocr/offchainreporting/types" + "github.com/smartcontractkit/chainlink/integration-tests/client" + eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_billing_registry_events_mock" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/authorized_forwarder" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flags_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_aggregator_proxy" @@ -33,9 +34,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/operator_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/oracle_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/test_api_consumer_wrapper" - - "github.com/smartcontractkit/chainlink/integration-tests/client" - eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" ) // EthereumOracle oracle for "directrequest" job tests From a7dbe9f5f6264822960ae04c308ea4ea76db38b4 Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Wed, 2 Aug 2023 17:49:45 +0300 Subject: [PATCH 062/270] fix test by comparing only upkeep ids and block numbers (#10041) NOTE: the block hash is inconsistent (was mocked) and we don't really want to test that here --- .../ocr2keeper/evm21/upkeep_provider_test.go | 22 ++++++++++++------- 1 file changed, 14 insertions(+), 8 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go index fd7df12cb64..664be1705cc 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go @@ -1,7 +1,9 @@ package evm import ( + "bytes" "math/big" + "sort" "sync" "testing" @@ -53,11 +55,13 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { coreTypes.Header{Number: big.NewInt(1)}, []ocr2keepers.UpkeepPayload{ { - ID: "edc5ec5f1d41b338a9ba6902caa8620a992fd086dcb978a6baa11a08e2e2795f", - Trigger: ocr2keepers.Trigger{BlockNumber: 1, BlockHash: "0xc3bd2d00745c03048a5616146a96f5ff78e54efb9e5b04af208cdaff6f3830ee"}, + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(big.NewInt(1).String()), + }, }, { - ID: "351362d44977dba636dd8b7429255db2e7b90a93ebddcb5f0f93cd81995ea887", - Trigger: ocr2keepers.Trigger{BlockNumber: 1, BlockHash: "0xc3bd2d00745c03048a5616146a96f5ff78e54efb9e5b04af208cdaff6f3830ee"}, + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(big.NewInt(2).String()), + }, }, }, false, @@ -76,12 +80,14 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { got, err := p.GetActiveUpkeeps(ctx, BlockKeyHelper[int64]{}.MakeBlockKey(b.Number().Int64())) require.NoError(t, err) require.Len(t, got, len(tc.want)) - + sort.Slice(got, func(i, j int) bool { + return bytes.Compare(got[i].Upkeep.ID, got[j].Upkeep.ID) < 0 + }) for i, payload := range got { expected := tc.want[i] - require.Equal(t, expected.ID, payload.ID) - require.Equal(t, expected.Trigger.BlockNumber, payload.Trigger.BlockNumber) - require.Equal(t, expected.Trigger.BlockHash, payload.Trigger.BlockHash) + // require.Equal(t, expected.ID, payload.ID) // TODO: uncomment once we change to workID + require.Equal(t, expected.Upkeep.ID, payload.Upkeep.ID) + require.Equal(t, b.Number().Int64(), payload.Trigger.BlockNumber) } }) } From 4e3b4ecc212ac37126179ab946975bc4140a2219 Mon Sep 17 00:00:00 2001 From: Makram Date: Wed, 2 Aug 2023 19:00:03 +0300 Subject: [PATCH 063/270] fix: stale comment (#10042) * fix: stale comment * fix: remove flaky check --- contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 3 +-- core/services/vrf/v2/integration_helpers_test.go | 6 ------ 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 816e6406445..92b403df34f 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -82,8 +82,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { // 2*2100 + 5000 - // cold read oracle address and oracle balance and first time oracle balance update, note first time will be 20k, but 5k subsequently // 4800 + // request delete refund (refunds happen after execution), note pre-london fork was 15k. See https://eips.ethereum.org/EIPS/eip-3529 // 6685 + // Positive static costs of argument encoding etc. note that it varies by +/- x*12 for every x bytes of non-zero data in the proof. - // 21000 // cost of a cold storage write to update the request payments mapping. - // Total: 58,815 gas. + // Total: 37,185 gas. uint32 gasAfterPaymentCalculation; } int256 public s_fallbackWeiPerUnitLink; diff --git a/core/services/vrf/v2/integration_helpers_test.go b/core/services/vrf/v2/integration_helpers_test.go index 3af45a61ae9..fd491367d27 100644 --- a/core/services/vrf/v2/integration_helpers_test.go +++ b/core/services/vrf/v2/integration_helpers_test.go @@ -296,12 +296,6 @@ func testMultipleConsumersNeedBHS( // Assert correct number of random words sent by coordinator. assertNumRandomWords(t, consumerContract, numWords) } - - for i := 0; i < len(bhsKeys); i++ { - n, err := uni.backend.PendingNonceAt(testutils.Context(t), bhsKeys[i].Address) - require.NoError(t, err) - require.EqualValues(t, 1, n) - } } func verifyBlockhashStored( From 800da83368ae03a8904228962e6935cc5988209e Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Wed, 2 Aug 2023 10:32:39 -0700 Subject: [PATCH 064/270] [Functions] New provider method stub (#10038) --- core/scripts/go.mod | 8 ++++---- core/scripts/go.sum | 16 ++++++++-------- core/services/relay/evm/evm.go | 6 ++++++ core/services/relay/evm/functions.go | 5 +++++ core/services/relay/evm/types/types.go | 4 ++-- core/services/relay/relay.go | 4 ++++ go.mod | 8 ++++---- go.sum | 16 ++++++++-------- integration-tests/go.mod | 2 +- integration-tests/go.sum | 10 +++++----- 10 files changed, 47 insertions(+), 32 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 502d024e7ca..2deb3f8c1c4 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -296,10 +296,10 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 // indirect - github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 // indirect - github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 // indirect + github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect + github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c // indirect github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 1a06e8fde7e..c7eda1a746d 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1429,14 +1429,14 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726/go.mod h1:TtLMvOtGV9hwNg59iJj+Sa0vL0Kq3o3eF+6uSIRixDc= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= -github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= -github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592/go.mod h1:km46XAo6xebV4Q+WyRFfo3E2t80YqTkegJM4FEfo5/Y= -github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d h1:4jSCp6i/p/EIaAkYQDxPK8nXDuv0fBXzKIcVYzetCoI= -github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d/go.mod h1:AW1rNDx4YN0VJzM1OrZtsOV9ORdcqcSFtsOQO3GeOQo= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= +github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= +github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= +github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= diff --git a/core/services/relay/evm/evm.go b/core/services/relay/evm/evm.go index 22d2cc1d362..1cd06fe7a83 100644 --- a/core/services/relay/evm/evm.go +++ b/core/services/relay/evm/evm.go @@ -33,6 +33,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc" @@ -128,6 +129,11 @@ func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytype return NewMercuryProvider(configWatcher, transmitter, reportCodec, r.lggr), nil } +func (r *Relayer) NewFunctionsProvider(rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs) (relaytypes.FunctionsProvider, error) { + // TODO(FUN-668): Not ready yet (doesn't implement FunctionsEvents() properly) + return NewFunctionsProvider(r.chainSet, rargs, pargs, r.lggr, r.ks.Eth(), functions.FunctionsPlugin) +} + func (r *Relayer) NewConfigProvider(args relaytypes.RelayArgs) (relaytypes.ConfigProvider, error) { configProvider, err := newConfigProvider(r.lggr, r.chainSet, args, r.eventBroadcaster) if err != nil { diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index 3e458e97a9c..84a4dbc8061 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -43,6 +43,11 @@ func (p *functionsProvider) LogPollerWrapper() evmRelayTypes.LogPollerWrapper { return p.logPollerWrapper } +func (p *functionsProvider) FunctionsEvents() relaytypes.FunctionsEvents { + // TODO (FUN-668): implement + return nil +} + func (p *functionsProvider) Start(ctx context.Context) error { return p.StartOnce("FunctionsProvider", func() error { if err := p.configWatcher.Start(ctx); err != nil { diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index 5fa8e0cf323..81651ca5688 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -35,9 +35,9 @@ type ConfigPoller interface { Replay(ctx context.Context, fromBlock int64) error } -// TODO(FUN-668): Move chain-agnostic types to Relayer +// TODO(FUN-668): Migrate this fully into relaytypes.FunctionsProvider type FunctionsProvider interface { - relaytypes.PluginProvider + relaytypes.FunctionsProvider LogPollerWrapper() LogPollerWrapper } diff --git a/core/services/relay/relay.go b/core/services/relay/relay.go index 3028f59fb28..d1e4077de9d 100644 --- a/core/services/relay/relay.go +++ b/core/services/relay/relay.go @@ -65,6 +65,10 @@ func (r *relayerAdapter) NewMercuryProvider(ctx context.Context, rargs types.Rel return r.Relayer.NewMercuryProvider(rargs, pargs) } +func (r *relayerAdapter) NewFunctionsProvider(ctx context.Context, rargs types.RelayArgs, pargs types.PluginArgs) (types.FunctionsProvider, error) { + return nil, errors.New("not implemented") +} + func (r *relayerAdapter) Start(ctx context.Context) error { var ms services.MultiStart return ms.Start(ctx, r.RelayerExt, r.Relayer) diff --git a/go.mod b/go.mod index 19bfd5df103..7547e37f396 100644 --- a/go.mod +++ b/go.mod @@ -66,10 +66,10 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 - github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 - github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 + github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 + github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac github.com/smartcontractkit/ocr2keepers v0.7.2 github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c diff --git a/go.sum b/go.sum index 1aca3fcc6d1..d2db7ecc5ac 100644 --- a/go.sum +++ b/go.sum @@ -1434,14 +1434,14 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726/go.mod h1:TtLMvOtGV9hwNg59iJj+Sa0vL0Kq3o3eF+6uSIRixDc= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= -github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= -github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592/go.mod h1:km46XAo6xebV4Q+WyRFfo3E2t80YqTkegJM4FEfo5/Y= -github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d h1:4jSCp6i/p/EIaAkYQDxPK8nXDuv0fBXzKIcVYzetCoI= -github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d/go.mod h1:AW1rNDx4YN0VJzM1OrZtsOV9ORdcqcSFtsOQO3GeOQo= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= +github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= +github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= +github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 95edc41bb7e..67cfbbadaed 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -360,7 +360,7 @@ require ( github.com/shopspring/decimal v1.3.1 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect github.com/smartcontractkit/wasp v0.2.7 // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index bd864cbb61d..762c34e5934 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2190,13 +2190,13 @@ github.com/slack-go/slack v0.12.2 h1:x3OppyMyGIbbiyFhsBmpf9pwkUzMhthJMRNmNlA4LaQ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQdlMQKOw= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230728170235-bd75c1424726 h1:cEFBM6iJoPXQr3imOodGoI/RIQmqiPmDN1wQT6YmDCI= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3 h1:rlNWHk15A2im/e9U95q4AkHZk5Wbc77lpx6ys4kUyCE= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230620171700-bbcb3a99b7d3/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= -github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230612131011-369bfb503592 h1:3Ul/LkULxrolCVguHUFnWJamgUDsSGISlm/DzclstmE= -github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230622060316-7ce48476dd7d h1:4jSCp6i/p/EIaAkYQDxPK8nXDuv0fBXzKIcVYzetCoI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= +github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87gFQ27MAv4Iat7aoCnM3K87/d0r4Aho= github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= From c8bb40be33930ce18221fd4b5b1c3dce74f32ed9 Mon Sep 17 00:00:00 2001 From: Patrick Date: Wed, 2 Aug 2023 16:55:21 -0400 Subject: [PATCH 065/270] fix/chains_keys_max_price: honoring key specific max gas price when set to 0 (#10043) --- .../evm/config/chain_scoped_gas_estimator.go | 2 +- core/chains/evm/config/config_test.go | 35 ++++++++++++------- 2 files changed, 24 insertions(+), 13 deletions(-) diff --git a/core/chains/evm/config/chain_scoped_gas_estimator.go b/core/chains/evm/config/chain_scoped_gas_estimator.go index ab637361e56..cc28ce75f03 100644 --- a/core/chains/evm/config/chain_scoped_gas_estimator.go +++ b/core/chains/evm/config/chain_scoped_gas_estimator.go @@ -25,7 +25,7 @@ func (g *gasEstimatorConfig) PriceMaxKey(addr gethcommon.Address) *assets.Wei { } chainSpecific := g.c.PriceMax - if keySpecific != nil && !keySpecific.IsZero() && keySpecific.Cmp(chainSpecific) < 0 { + if keySpecific != nil && keySpecific.Cmp(chainSpecific) < 0 { return keySpecific } diff --git a/core/chains/evm/config/config_test.go b/core/chains/evm/config/config_test.go index d3240cf81f7..10984d45d1e 100644 --- a/core/chains/evm/config/config_test.go +++ b/core/chains/evm/config/config_test.go @@ -110,19 +110,30 @@ func TestChainScopedConfig(t *testing.T) { assert.Equal(t, val.String(), cfg3.EVM().GasEstimator().PriceMaxKey(addr).String()) }) t.Run("uses key-specific override value when set", func(t *testing.T) { - val := assets.GWei(250) - gcfg3 := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { - c.EVM[0].KeySpecific = toml.KeySpecificConfig{ - {Key: ptr(ethkey.EIP55AddressFromAddress(addr)), - GasEstimator: toml.KeySpecificGasEstimator{ - PriceMax: val, - }, - }, - } - }) - cfg3 := evmtest.NewChainScopedConfig(t, gcfg3) + tests := []struct { + name string + val *assets.Wei + }{ + {"Test with 250 GWei", assets.GWei(250)}, + {"Test with 0 GWei", assets.GWei(0)}, + } - assert.Equal(t, val.String(), cfg3.EVM().GasEstimator().PriceMaxKey(addr).String()) + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + gcfg3 := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + c.EVM[0].KeySpecific = toml.KeySpecificConfig{ + {Key: ptr(ethkey.EIP55AddressFromAddress(addr)), + GasEstimator: toml.KeySpecificGasEstimator{ + PriceMax: tt.val, + }, + }, + } + }) + cfg3 := evmtest.NewChainScopedConfig(t, gcfg3) + + assert.Equal(t, tt.val.String(), cfg3.EVM().GasEstimator().PriceMaxKey(addr).String()) + }) + } }) t.Run("uses key-specific override value when set and lower than chain specific config", func(t *testing.T) { keySpecificPrice := assets.GWei(900) From d79796e614a1d78cb8017103263c7e6680ee98ca Mon Sep 17 00:00:00 2001 From: Tate Date: Wed, 2 Aug 2023 16:14:18 -0600 Subject: [PATCH 066/270] [TT-469] Output core tests in json format so we can use the results in other instrumentation (#9838) * Output more test data for tooling Limit packages ran to just ones that have tests * Mege conflict fixes * Only run filter on failure * Add a forced failure to compare with * Add panic failure for comparison * remove forced test failures and scrub skips * More cleanup * Fix shell_local_test race condition * Fix zap_test.go race conditions in tests * cleanup * Work on fixing flakey reruns * Based on review comments, fixing up race conditions by using a stderr writer instead of the pointer to stderr as the sink --- .github/workflows/ci-core.yml | 14 +++++++++++++- core/cmd/shell_local_test.go | 4 ++-- core/logger/logger.go | 16 +++++++++++++++- core/logger/logger_test.go | 13 +++++++++++++ tools/bin/go_core_race_tests | 12 ++++++++++-- tools/bin/go_core_tests | 12 ++++++++++-- tools/bin/scrub_logs | 18 +++++++++++++++--- 7 files changed, 78 insertions(+), 11 deletions(-) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index a710fbfb64c..2a4371dbf65 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -173,7 +173,17 @@ jobs: echo "TIMEOUT=10m" >> $GITHUB_ENV echo "COUNT=50" >> $GITHUB_ENV - name: Run tests + id: run-tests + env: + OUTPUT_FILE: ./output.txt + USE_TEE: false run: ./tools/bin/${{ matrix.cmd }} "${{ matrix.split.pkgs }}" + - name: Print Filtered Test Results + if: failure() + uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@2bb3869750e6e1c2d936fe7179784908981548a4 # v2.2.4 + with: + results-file: ./output.txt + output-file: ./output-short.txt - name: Store logs artifacts if: always() uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0 @@ -181,6 +191,7 @@ jobs: name: ${{ matrix.cmd }}_${{ matrix.split.idx }}_logs path: | ./output.txt + ./output-short.txt ./race.* ./coverage.txt - name: Print postgres logs @@ -195,6 +206,7 @@ jobs: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} this-job-name: Core Tests (${{ matrix.cmd }}) ${{ matrix.split.id }} + test-results-file: '{"testType":"go","filePath":"./output.txt"}' continue-on-error: true # Satisfy required check for core tests @@ -269,7 +281,7 @@ jobs: -gh_sha=$GITHUB_SHA \ -gh_event_path=$GITHUB_EVENT_PATH \ -command=./tools/bin/go_core_tests \ - `ls -R ./artifacts/go_core_tests*/output.txt` + `ls -R ./artifacts/go_core_tests*/output-short.txt` - name: Store logs artifacts if: always() uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0 diff --git a/core/cmd/shell_local_test.go b/core/cmd/shell_local_test.go index c2bc543f87a..ba0839c6e96 100644 --- a/core/cmd/shell_local_test.go +++ b/core/cmd/shell_local_test.go @@ -214,8 +214,8 @@ func TestShell_DiskMaxSizeBeforeRotateOptionDisablesAsExpected(t *testing.T) { } assert.NoError(t, os.MkdirAll(cfg.Dir, os.FileMode(0700))) - lggr, close := cfg.New() - t.Cleanup(func() { assert.NoError(t, close()) }) + lggr, closeFn := cfg.New() + t.Cleanup(func() { assert.NoError(t, closeFn()) }) // Tries to create a log file by logging. The log file won't be created if there's no logging happening. lggr.Debug("Trying to create a log file by logging.") diff --git a/core/logger/logger.go b/core/logger/logger.go index 20788ed4174..1d8feb139f7 100644 --- a/core/logger/logger.go +++ b/core/logger/logger.go @@ -21,8 +21,22 @@ import ( // logsFile describes the logs file name const logsFile = "chainlink_debug.log" +// Create a standard error writer to avoid test issues around os.Stderr being +// reassigned when verbose logging is enabled +type stderrWriter struct{} + +func (sw stderrWriter) Write(p []byte) (n int, err error) { + return os.Stderr.Write(p) +} +func (sw stderrWriter) Close() error { + return nil // never close stderr +} +func (sw stderrWriter) Sync() error { + return os.Stderr.Sync() +} + func init() { - err := zap.RegisterSink("pretty", prettyConsoleSink(os.Stderr)) + err := zap.RegisterSink("pretty", prettyConsoleSink(stderrWriter{})) if err != nil { log.Fatalf("failed to register pretty printer %+v", err) } diff --git a/core/logger/logger_test.go b/core/logger/logger_test.go index 186058de90c..dc7558a5156 100644 --- a/core/logger/logger_test.go +++ b/core/logger/logger_test.go @@ -15,3 +15,16 @@ func TestConfig(t *testing.T) { assert.False(t, newZapConfigBase().Development) assert.False(t, newZapConfigProd(false, false).Development) } + +func TestStderrWriter(t *testing.T) { + sw := stderrWriter{} + + // Test Write + n, err := sw.Write([]byte("Hello, World!")) + assert.NoError(t, err) + assert.Equal(t, 13, n, "Expected 13 bytes written") + + // Test Close + err = sw.Close() + assert.NoError(t, err) +} diff --git a/tools/bin/go_core_race_tests b/tools/bin/go_core_race_tests index edd57e5ab68..81571bfbbe3 100755 --- a/tools/bin/go_core_race_tests +++ b/tools/bin/go_core_race_tests @@ -1,10 +1,18 @@ #!/usr/bin/env bash set -ex - +OUTPUT_FILE=${OUTPUT_FILE:-"./output.txt"} +USE_TEE="${USE_TEE:-true}" TIMEOUT="${TIMEOUT:-30s}" COUNT="${COUNT:-10}" GO_LDFLAGS=$(bash tools/bin/ldflags) -GORACE="log_path=$PWD/race" go test -tags test -race -ldflags "$GO_LDFLAGS" -shuffle on -timeout "$TIMEOUT" -count "$COUNT" $1 | tee ./output.txt +use_tee() { + if [ "$USE_TEE" = "true" ]; then + tee "$@" + else + cat > "$@" + fi +} +GORACE="log_path=$PWD/race" go test -json -tags test -race -ldflags "$GO_LDFLAGS" -shuffle on -timeout "$TIMEOUT" -count "$COUNT" $1 | use_tee "$OUTPUT_FILE" EXITCODE=${PIPESTATUS[0]} # Fail if any race logs are present. if ls race.* &>/dev/null diff --git a/tools/bin/go_core_tests b/tools/bin/go_core_tests index e1510792f64..79f7a480cfb 100755 --- a/tools/bin/go_core_tests +++ b/tools/bin/go_core_tests @@ -3,12 +3,20 @@ set -o pipefail set +e SCRIPT_PATH=`dirname "$0"`; SCRIPT_PATH=`eval "cd \"$SCRIPT_PATH\" && pwd"` -OUTPUT_FILE="./output.txt" +OUTPUT_FILE=${OUTPUT_FILE:-"./output.txt"} +USE_TEE="${USE_TEE:-true}" echo "Failed tests and panics: ---------------------" echo "" GO_LDFLAGS=$(bash tools/bin/ldflags) -go test -ldflags "$GO_LDFLAGS" -tags test,integration $TEST_FLAGS -covermode=atomic -coverpkg=./... -coverprofile=coverage.txt $1 | tee $OUTPUT_FILE +use_tee() { + if [ "$USE_TEE" = "true" ]; then + tee "$@" + else + cat > "$@" + fi +} +go test -json -ldflags "$GO_LDFLAGS" -tags test,integration $TEST_FLAGS -covermode=atomic -coverpkg=./... -coverprofile=coverage.txt $1 | use_tee $OUTPUT_FILE EXITCODE=${PIPESTATUS[0]} # Assert no known sensitive strings present in test logger output diff --git a/tools/bin/scrub_logs b/tools/bin/scrub_logs index 8113f122348..03cfe93c992 100755 --- a/tools/bin/scrub_logs +++ b/tools/bin/scrub_logs @@ -42,12 +42,24 @@ declare -a arr=( "Ag%3D%3D" ) +declare -a testarr=( + "wss://foo.bar" + "wss://fake.com" + "wss://web.socket/test" +) + # For each potential secret above, check for presence of string and encoded version in log files MATCHED_LINES=() for substr in "${arr[@]}"; do - MATCHES="$(grep -i "$substr" $OUTPUT_FILE || true)" - if [ -n "$MATCHES" ]; then - MATCHED_LINES+=("$MATCHES") + MATCHES="$(grep -i "$substr" $OUTPUT_FILE || true)" + if [ -n "$MATCHES" ]; then + # check if the matched string is part of a known test case that is safe to pass + for safesubstr in "${testarr[@]}"; do + SAFE_MATCH="$(echo "${MATCHED_LINE}" | grep -i "$safesubstr" || true)" + if [ -n "$SAFE_MATCH" ]; then + MATCHED_LINES+=("$MATCHES") + fi + done fi done From 486c5e8503af7380c0109884b2f0f02f4124de15 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Wed, 2 Aug 2023 19:58:34 -0400 Subject: [PATCH 067/270] (fix): Use correct gethwrapper in LogPollerWrapper & update for newest contract changes (#10045) --- .../split-tests/src/handlers/golang.mts | 5 +- .../generated/functions/functions.go | 202 - .../functions_client/functions_client.go | 463 -- .../functions_client_example.go | 988 ----- .../functions_coordinator.go | 2612 ----------- .../functions_registry/functions_registry.go | 3350 -------------- .../functions_router/functions_router.go | 3839 ----------------- .../relay/evm/functions/logpoller_wrapper.go | 13 +- 8 files changed, 9 insertions(+), 11463 deletions(-) delete mode 100644 core/gethwrappers/generated/functions/functions.go delete mode 100644 core/gethwrappers/generated/functions_client/functions_client.go delete mode 100644 core/gethwrappers/generated/functions_client_example/functions_client_example.go delete mode 100644 core/gethwrappers/generated/functions_coordinator/functions_coordinator.go delete mode 100644 core/gethwrappers/generated/functions_registry/functions_registry.go delete mode 100644 core/gethwrappers/generated/functions_router/functions_router.go diff --git a/.github/actions/split-tests/src/handlers/golang.mts b/.github/actions/split-tests/src/handlers/golang.mts index e08d55303f5..b4e7b1a6317 100644 --- a/.github/actions/split-tests/src/handlers/golang.mts +++ b/.github/actions/split-tests/src/handlers/golang.mts @@ -23,10 +23,7 @@ export function getPackageList( { encoding: "utf8" } ); const packages: GoPackageData[] = JSON.parse(rawPackages.trimEnd()); - const filteredData = packages.filter( - (item) => item.TestGoFiles && item.TestGoFiles.length > 0 - ); - const packagePaths = filteredData.map((item) => item.ImportPath); + const packagePaths = packages.map((item) => item.ImportPath); return handleSplit(packagePaths, numOfSplits); } diff --git a/core/gethwrappers/generated/functions/functions.go b/core/gethwrappers/generated/functions/functions.go deleted file mode 100644 index c82878691b5..00000000000 --- a/core/gethwrappers/generated/functions/functions.go +++ /dev/null @@ -1,202 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package functions - -import ( - "errors" - "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" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -var FunctionsMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"REQUEST_DATA_VERSION\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6063610038600b82828239805160001a607314602b57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe730000000000000000000000000000000000000000301460806040526004361060335760003560e01c80635d641dfc146038575b600080fd5b603f600181565b60405161ffff909116815260200160405180910390f3fea164736f6c6343000806000a", -} - -var FunctionsABI = FunctionsMetaData.ABI - -var FunctionsBin = FunctionsMetaData.Bin - -func DeployFunctions(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *Functions, error) { - parsed, err := FunctionsMetaData.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(FunctionsBin), backend) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &Functions{FunctionsCaller: FunctionsCaller{contract: contract}, FunctionsTransactor: FunctionsTransactor{contract: contract}, FunctionsFilterer: FunctionsFilterer{contract: contract}}, nil -} - -type Functions struct { - address common.Address - abi abi.ABI - FunctionsCaller - FunctionsTransactor - FunctionsFilterer -} - -type FunctionsCaller struct { - contract *bind.BoundContract -} - -type FunctionsTransactor struct { - contract *bind.BoundContract -} - -type FunctionsFilterer struct { - contract *bind.BoundContract -} - -type FunctionsSession struct { - Contract *Functions - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type FunctionsCallerSession struct { - Contract *FunctionsCaller - CallOpts bind.CallOpts -} - -type FunctionsTransactorSession struct { - Contract *FunctionsTransactor - TransactOpts bind.TransactOpts -} - -type FunctionsRaw struct { - Contract *Functions -} - -type FunctionsCallerRaw struct { - Contract *FunctionsCaller -} - -type FunctionsTransactorRaw struct { - Contract *FunctionsTransactor -} - -func NewFunctions(address common.Address, backend bind.ContractBackend) (*Functions, error) { - abi, err := abi.JSON(strings.NewReader(FunctionsABI)) - if err != nil { - return nil, err - } - contract, err := bindFunctions(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &Functions{address: address, abi: abi, FunctionsCaller: FunctionsCaller{contract: contract}, FunctionsTransactor: FunctionsTransactor{contract: contract}, FunctionsFilterer: FunctionsFilterer{contract: contract}}, nil -} - -func NewFunctionsCaller(address common.Address, caller bind.ContractCaller) (*FunctionsCaller, error) { - contract, err := bindFunctions(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &FunctionsCaller{contract: contract}, nil -} - -func NewFunctionsTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsTransactor, error) { - contract, err := bindFunctions(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &FunctionsTransactor{contract: contract}, nil -} - -func NewFunctionsFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsFilterer, error) { - contract, err := bindFunctions(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &FunctionsFilterer{contract: contract}, nil -} - -func bindFunctions(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := FunctionsMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_Functions *FunctionsRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _Functions.Contract.FunctionsCaller.contract.Call(opts, result, method, params...) -} - -func (_Functions *FunctionsRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _Functions.Contract.FunctionsTransactor.contract.Transfer(opts) -} - -func (_Functions *FunctionsRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _Functions.Contract.FunctionsTransactor.contract.Transact(opts, method, params...) -} - -func (_Functions *FunctionsCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _Functions.Contract.contract.Call(opts, result, method, params...) -} - -func (_Functions *FunctionsTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _Functions.Contract.contract.Transfer(opts) -} - -func (_Functions *FunctionsTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _Functions.Contract.contract.Transact(opts, method, params...) -} - -func (_Functions *FunctionsCaller) REQUESTDATAVERSION(opts *bind.CallOpts) (uint16, error) { - var out []interface{} - err := _Functions.contract.Call(opts, &out, "REQUEST_DATA_VERSION") - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -func (_Functions *FunctionsSession) REQUESTDATAVERSION() (uint16, error) { - return _Functions.Contract.REQUESTDATAVERSION(&_Functions.CallOpts) -} - -func (_Functions *FunctionsCallerSession) REQUESTDATAVERSION() (uint16, error) { - return _Functions.Contract.REQUESTDATAVERSION(&_Functions.CallOpts) -} - -func (_Functions *Functions) Address() common.Address { - return _Functions.address -} - -type FunctionsInterface interface { - REQUESTDATAVERSION(opts *bind.CallOpts) (uint16, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/functions_client/functions_client.go b/core/gethwrappers/generated/functions_client/functions_client.go deleted file mode 100644 index 2bfb9bb981c..00000000000 --- a/core/gethwrappers/generated/functions_client/functions_client.go +++ /dev/null @@ -1,463 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package functions_client - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -var FunctionsClientMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", -} - -var FunctionsClientABI = FunctionsClientMetaData.ABI - -type FunctionsClient struct { - address common.Address - abi abi.ABI - FunctionsClientCaller - FunctionsClientTransactor - FunctionsClientFilterer -} - -type FunctionsClientCaller struct { - contract *bind.BoundContract -} - -type FunctionsClientTransactor struct { - contract *bind.BoundContract -} - -type FunctionsClientFilterer struct { - contract *bind.BoundContract -} - -type FunctionsClientSession struct { - Contract *FunctionsClient - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type FunctionsClientCallerSession struct { - Contract *FunctionsClientCaller - CallOpts bind.CallOpts -} - -type FunctionsClientTransactorSession struct { - Contract *FunctionsClientTransactor - TransactOpts bind.TransactOpts -} - -type FunctionsClientRaw struct { - Contract *FunctionsClient -} - -type FunctionsClientCallerRaw struct { - Contract *FunctionsClientCaller -} - -type FunctionsClientTransactorRaw struct { - Contract *FunctionsClientTransactor -} - -func NewFunctionsClient(address common.Address, backend bind.ContractBackend) (*FunctionsClient, error) { - abi, err := abi.JSON(strings.NewReader(FunctionsClientABI)) - if err != nil { - return nil, err - } - contract, err := bindFunctionsClient(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &FunctionsClient{address: address, abi: abi, FunctionsClientCaller: FunctionsClientCaller{contract: contract}, FunctionsClientTransactor: FunctionsClientTransactor{contract: contract}, FunctionsClientFilterer: FunctionsClientFilterer{contract: contract}}, nil -} - -func NewFunctionsClientCaller(address common.Address, caller bind.ContractCaller) (*FunctionsClientCaller, error) { - contract, err := bindFunctionsClient(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &FunctionsClientCaller{contract: contract}, nil -} - -func NewFunctionsClientTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsClientTransactor, error) { - contract, err := bindFunctionsClient(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &FunctionsClientTransactor{contract: contract}, nil -} - -func NewFunctionsClientFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsClientFilterer, error) { - contract, err := bindFunctionsClient(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &FunctionsClientFilterer{contract: contract}, nil -} - -func bindFunctionsClient(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := FunctionsClientMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_FunctionsClient *FunctionsClientRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsClient.Contract.FunctionsClientCaller.contract.Call(opts, result, method, params...) -} - -func (_FunctionsClient *FunctionsClientRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsClient.Contract.FunctionsClientTransactor.contract.Transfer(opts) -} - -func (_FunctionsClient *FunctionsClientRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsClient.Contract.FunctionsClientTransactor.contract.Transact(opts, method, params...) -} - -func (_FunctionsClient *FunctionsClientCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsClient.Contract.contract.Call(opts, result, method, params...) -} - -func (_FunctionsClient *FunctionsClientTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsClient.Contract.contract.Transfer(opts) -} - -func (_FunctionsClient *FunctionsClientTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsClient.Contract.contract.Transact(opts, method, params...) -} - -func (_FunctionsClient *FunctionsClientTransactor) HandleOracleFulfillment(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { - return _FunctionsClient.contract.Transact(opts, "handleOracleFulfillment", requestId, response, err) -} - -func (_FunctionsClient *FunctionsClientSession) HandleOracleFulfillment(requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { - return _FunctionsClient.Contract.HandleOracleFulfillment(&_FunctionsClient.TransactOpts, requestId, response, err) -} - -func (_FunctionsClient *FunctionsClientTransactorSession) HandleOracleFulfillment(requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { - return _FunctionsClient.Contract.HandleOracleFulfillment(&_FunctionsClient.TransactOpts, requestId, response, err) -} - -type FunctionsClientRequestFulfilledIterator struct { - Event *FunctionsClientRequestFulfilled - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsClientRequestFulfilledIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsClientRequestFulfilled) - 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(FunctionsClientRequestFulfilled) - 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 *FunctionsClientRequestFulfilledIterator) Error() error { - return it.fail -} - -func (it *FunctionsClientRequestFulfilledIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsClientRequestFulfilled struct { - Id [32]byte - Raw types.Log -} - -func (_FunctionsClient *FunctionsClientFilterer) FilterRequestFulfilled(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientRequestFulfilledIterator, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClient.contract.FilterLogs(opts, "RequestFulfilled", idRule) - if err != nil { - return nil, err - } - return &FunctionsClientRequestFulfilledIterator{contract: _FunctionsClient.contract, event: "RequestFulfilled", logs: logs, sub: sub}, nil -} - -func (_FunctionsClient *FunctionsClientFilterer) WatchRequestFulfilled(opts *bind.WatchOpts, sink chan<- *FunctionsClientRequestFulfilled, id [][32]byte) (event.Subscription, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClient.contract.WatchLogs(opts, "RequestFulfilled", idRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsClientRequestFulfilled) - if err := _FunctionsClient.contract.UnpackLog(event, "RequestFulfilled", 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 (_FunctionsClient *FunctionsClientFilterer) ParseRequestFulfilled(log types.Log) (*FunctionsClientRequestFulfilled, error) { - event := new(FunctionsClientRequestFulfilled) - if err := _FunctionsClient.contract.UnpackLog(event, "RequestFulfilled", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsClientRequestSentIterator struct { - Event *FunctionsClientRequestSent - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsClientRequestSentIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsClientRequestSent) - 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(FunctionsClientRequestSent) - 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 *FunctionsClientRequestSentIterator) Error() error { - return it.fail -} - -func (it *FunctionsClientRequestSentIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsClientRequestSent struct { - Id [32]byte - Raw types.Log -} - -func (_FunctionsClient *FunctionsClientFilterer) FilterRequestSent(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientRequestSentIterator, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClient.contract.FilterLogs(opts, "RequestSent", idRule) - if err != nil { - return nil, err - } - return &FunctionsClientRequestSentIterator{contract: _FunctionsClient.contract, event: "RequestSent", logs: logs, sub: sub}, nil -} - -func (_FunctionsClient *FunctionsClientFilterer) WatchRequestSent(opts *bind.WatchOpts, sink chan<- *FunctionsClientRequestSent, id [][32]byte) (event.Subscription, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClient.contract.WatchLogs(opts, "RequestSent", idRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsClientRequestSent) - if err := _FunctionsClient.contract.UnpackLog(event, "RequestSent", 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 (_FunctionsClient *FunctionsClientFilterer) ParseRequestSent(log types.Log) (*FunctionsClientRequestSent, error) { - event := new(FunctionsClientRequestSent) - if err := _FunctionsClient.contract.UnpackLog(event, "RequestSent", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -func (_FunctionsClient *FunctionsClient) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _FunctionsClient.abi.Events["RequestFulfilled"].ID: - return _FunctionsClient.ParseRequestFulfilled(log) - case _FunctionsClient.abi.Events["RequestSent"].ID: - return _FunctionsClient.ParseRequestSent(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (FunctionsClientRequestFulfilled) Topic() common.Hash { - return common.HexToHash("0x85e1543bf2f84fe80c6badbce3648c8539ad1df4d2b3d822938ca0538be727e6") -} - -func (FunctionsClientRequestSent) Topic() common.Hash { - return common.HexToHash("0x1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db8") -} - -func (_FunctionsClient *FunctionsClient) Address() common.Address { - return _FunctionsClient.address -} - -type FunctionsClientInterface interface { - HandleOracleFulfillment(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) - - FilterRequestFulfilled(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientRequestFulfilledIterator, error) - - WatchRequestFulfilled(opts *bind.WatchOpts, sink chan<- *FunctionsClientRequestFulfilled, id [][32]byte) (event.Subscription, error) - - ParseRequestFulfilled(log types.Log) (*FunctionsClientRequestFulfilled, error) - - FilterRequestSent(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientRequestSentIterator, error) - - WatchRequestSent(opts *bind.WatchOpts, sink chan<- *FunctionsClientRequestSent, id [][32]byte) (event.Subscription, error) - - ParseRequestSent(log types.Log) (*FunctionsClientRequestSent, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/generated/functions_client_example/functions_client_example.go deleted file mode 100644 index 90f7be78cbf..00000000000 --- a/core/gethwrappers/generated/functions_client_example/functions_client_example.go +++ /dev/null @@ -1,988 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package functions_client_example - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -var FunctionsClientExampleMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b5060405162001a3038038062001a30833981016040819052620000349162000199565b600080546001600160a01b0319166001600160a01b038316178155339081906001600160a01b038216620000af5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600180546001600160a01b0319166001600160a01b0384811691909117909155811615620000e257620000e281620000ec565b50505050620001cb565b6001600160a01b038116331415620001475760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a6565b600280546001600160a01b0319166001600160a01b03838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b600060208284031215620001ac57600080fd5b81516001600160a01b0381168114620001c457600080fd5b9392505050565b61185580620001db6000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b48cffea1161005b578063b48cffea14610182578063f2fde38b14610192578063fc2a88c3146101a557600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b80632c29166b116100b25780632c29166b146100ff5780635fa353e71461012c57806362747e421461013f57600080fd5b80630ca76175146100ce57806329f0de3f146100e3575b600080fd5b6100e16100dc36600461129e565b6101ae565b005b6100ec60055481565b6040519081526020015b60405180910390f35b60065461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100e161013a36600461130b565b61020f565b6100ec60045481565b6101176201117081565b6100e1610319565b60015460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6006546101179063ffffffff1681565b6100e16101a036600461124f565b61041f565b6100ec60035481565b60005473ffffffffffffffffffffffffffffffffffffffff1633146101ff576040517f5099014100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61020a838383610433565b505050565b610217610501565b6102586040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b61029a89898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105849050565b85156102e2576102e287878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105959050565b83156102fc576102fc6102f58587611679565b82906105dc565b61030b8184620111708561061c565b600355505050505050505050565b60025473ffffffffffffffffffffffffffffffffffffffff16331461039f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560028054909116905560405173ffffffffffffffffffffffffffffffffffffffff909116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b610427610501565b61043081610640565b50565b8260035414610471576040517fd068bf5b00000000000000000000000000000000000000000000000000000000815260048101849052602401610396565b61047a82610737565b6004558151600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104bc81610737565b600555516006805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610582576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610396565b565b61059182600080846107bf565b5050565b80516105cd576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051610614576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b60008061062886610853565b905061063681868686610bc5565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81163314156106c0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610396565b600280547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600154604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60008060006020905060208451101561074e575082515b60005b818110156107b657610764816008611625565b858281518110610776576107766117ea565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c9290921791806107ae81611718565b915050610751565b50909392505050565b80516107f7576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561080a5761080a6117bb565b9081600281111561081d5761081d6117bb565b90525060408401828015610833576108336117bb565b90818015610843576108436117bb565b9052506060909301929092525050565b606061085d61111e565b805161086b90610100610cad565b506108ab816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d27565b6108ca81846000015160028111156108c5576108c56117bb565b610d40565b610909816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d27565b61092381846040015160008111156108c5576108c56117bb565b610962816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d27565b610970818460600151610d27565b60a08301515115610a16576109ba816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d27565b6109c381610d79565b60005b8360a0015151811015610a0c576109fa828560a0015183815181106109ed576109ed6117ea565b6020026020010151610d27565b80610a0481611718565b9150506109c6565b50610a1681610d9d565b60808301515115610b1757600083602001516002811115610a3957610a396117bb565b1415610a71576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ab0816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d27565b610aca81846020015160028111156108c5576108c56117bb565b610b09816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d27565b610b17818460800151610dbb565b60c08301515115610bbd57610b61816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d27565b610b6a81610d79565b60005b8360c0015151811015610bb357610ba1828560c001518381518110610b9457610b946117ea565b6020026020010151610dbb565b80610bab81611718565b915050610b6d565b50610bbd81610d9d565b515192915050565b600080546040517f461d276200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091169063461d276290610c259087908990600190899089906004016113ef565b602060405180830381600087803b158015610c3f57600080fd5b505af1158015610c53573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c779190611285565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a2949350505050565b604080518082019091526060815260006020820152610ccd602083611751565b15610cf557610cdd602083611751565b610ce8906020611662565b610cf290836114e6565b91505b602080840183905260405180855260008152908184010181811015610d1957600080fd5b604052508290505b92915050565b610d348260038351610dc4565b815161020a9082610eeb565b8151610d4d9060c2610f13565b506105918282604051602001610d6591815260200190565b604051602081830303815290604052610dbb565b610d84816004610f7c565b600181602001818151610d9791906114e6565b90525050565b610da8816007610f7c565b600181602001818151610d979190611662565b610d3482600283515b60178167ffffffffffffffff1611610df1578251610deb9060e0600585901b168317610f13565b50505050565b60ff8167ffffffffffffffff1611610e33578251610e1a906018611fe0600586901b1617610f13565b508251610deb9067ffffffffffffffff83166001610f93565b61ffff8167ffffffffffffffff1611610e76578251610e5d906019611fe0600586901b1617610f13565b508251610deb9067ffffffffffffffff83166002610f93565b63ffffffff8167ffffffffffffffff1611610ebb578251610ea290601a611fe0600586901b1617610f13565b508251610deb9067ffffffffffffffff83166004610f93565b8251610ed290601b611fe0600586901b1617610f13565b508251610deb9067ffffffffffffffff83166008610f93565b604080518082019091526060815260006020820152610f0c83838451611018565b9392505050565b6040805180820190915260608152600060208201528251516000610f388260016114e6565b905084602001518210610f5957610f5985610f54836002611625565b611107565b8451602083820101858153508051821115610f72578181525b5093949350505050565b815161020a90601f611fe0600585901b1617610f13565b6040805180820190915260608152600060208201528351516000610fb782856114e6565b90508560200151811115610fd457610fd486610f54836002611625565b60006001610fe48661010061155f565b610fee9190611662565b9050865182810187831982511617815250805183111561100c578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561103b57600080fd5b835151600061104a84836114e6565b905085602001518111156110675761106786610f54836002611625565b855180518382016020019160009180851115611081578482525b505050602086015b602086106110c157805182526110a06020836114e6565b91506110ad6020826114e6565b90506110ba602087611662565b9550611089565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111138383610cad565b50610deb8382610eeb565b6040518060400160405280611146604051806040016040528060608152602001600081525090565b8152602001600081525090565b600067ffffffffffffffff83111561116d5761116d611819565b61119e60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f86011601611497565b90508281528383830111156111b257600080fd5b828260208301376000602084830101529392505050565b60008083601f8401126111db57600080fd5b50813567ffffffffffffffff8111156111f357600080fd5b60208301915083602082850101111561120b57600080fd5b9250929050565b600082601f83011261122357600080fd5b610f0c83833560208501611153565b803567ffffffffffffffff8116811461124a57600080fd5b919050565b60006020828403121561126157600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f0c57600080fd5b60006020828403121561129757600080fd5b5051919050565b6000806000606084860312156112b357600080fd5b83359250602084013567ffffffffffffffff808211156112d257600080fd5b6112de87838801611212565b935060408601359150808211156112f457600080fd5b5061130186828701611212565b9150509250925092565b60008060008060008060008060a0898b03121561132757600080fd5b883567ffffffffffffffff8082111561133f57600080fd5b61134b8c838d016111c9565b909a50985060208b013591508082111561136457600080fd5b6113708c838d016111c9565b909850965060408b013591508082111561138957600080fd5b818b0191508b601f83011261139d57600080fd5b8135818111156113ac57600080fd5b8c60208260051b85010111156113c157600080fd5b6020830196508095505050506113d960608a01611232565b9150608089013590509295985092959890939650565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b8181101561142d5788810183015185820160c001528201611411565b8181111561143f57600060c083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016830160c001915061147e9050604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156114de576114de611819565b604052919050565b600082198211156114f9576114f961178c565b500190565b600181815b8085111561155757817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561153d5761153d61178c565b8085161561154a57918102915b93841c9390800290611503565b509250929050565b6000610f0c838360008261157557506001610d21565b8161158257506000610d21565b816001811461159857600281146115a2576115be565b6001915050610d21565b60ff8411156115b3576115b361178c565b50506001821b610d21565b5060208310610133831016604e8410600b84101617156115e1575081810a610d21565b6115eb83836114fe565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561161d5761161d61178c565b029392505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561165d5761165d61178c565b500290565b6000828210156116745761167461178c565b500390565b600067ffffffffffffffff8084111561169457611694611819565b8360051b60206116a5818301611497565b86815281810190863685820111156116bc57600080fd5b600094505b8885101561170c578035868111156116d857600080fd5b880136601f8201126116e957600080fd5b6116f7368235878401611153565b845250600194909401939183019183016116c1565b50979650505050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561174a5761174a61178c565b5060010190565b600082611787577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", -} - -var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI - -var FunctionsClientExampleBin = FunctionsClientExampleMetaData.Bin - -func DeployFunctionsClientExample(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address) (common.Address, *types.Transaction, *FunctionsClientExample, error) { - parsed, err := FunctionsClientExampleMetaData.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(FunctionsClientExampleBin), backend, router) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &FunctionsClientExample{FunctionsClientExampleCaller: FunctionsClientExampleCaller{contract: contract}, FunctionsClientExampleTransactor: FunctionsClientExampleTransactor{contract: contract}, FunctionsClientExampleFilterer: FunctionsClientExampleFilterer{contract: contract}}, nil -} - -type FunctionsClientExample struct { - address common.Address - abi abi.ABI - FunctionsClientExampleCaller - FunctionsClientExampleTransactor - FunctionsClientExampleFilterer -} - -type FunctionsClientExampleCaller struct { - contract *bind.BoundContract -} - -type FunctionsClientExampleTransactor struct { - contract *bind.BoundContract -} - -type FunctionsClientExampleFilterer struct { - contract *bind.BoundContract -} - -type FunctionsClientExampleSession struct { - Contract *FunctionsClientExample - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type FunctionsClientExampleCallerSession struct { - Contract *FunctionsClientExampleCaller - CallOpts bind.CallOpts -} - -type FunctionsClientExampleTransactorSession struct { - Contract *FunctionsClientExampleTransactor - TransactOpts bind.TransactOpts -} - -type FunctionsClientExampleRaw struct { - Contract *FunctionsClientExample -} - -type FunctionsClientExampleCallerRaw struct { - Contract *FunctionsClientExampleCaller -} - -type FunctionsClientExampleTransactorRaw struct { - Contract *FunctionsClientExampleTransactor -} - -func NewFunctionsClientExample(address common.Address, backend bind.ContractBackend) (*FunctionsClientExample, error) { - abi, err := abi.JSON(strings.NewReader(FunctionsClientExampleABI)) - if err != nil { - return nil, err - } - contract, err := bindFunctionsClientExample(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &FunctionsClientExample{address: address, abi: abi, FunctionsClientExampleCaller: FunctionsClientExampleCaller{contract: contract}, FunctionsClientExampleTransactor: FunctionsClientExampleTransactor{contract: contract}, FunctionsClientExampleFilterer: FunctionsClientExampleFilterer{contract: contract}}, nil -} - -func NewFunctionsClientExampleCaller(address common.Address, caller bind.ContractCaller) (*FunctionsClientExampleCaller, error) { - contract, err := bindFunctionsClientExample(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &FunctionsClientExampleCaller{contract: contract}, nil -} - -func NewFunctionsClientExampleTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsClientExampleTransactor, error) { - contract, err := bindFunctionsClientExample(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &FunctionsClientExampleTransactor{contract: contract}, nil -} - -func NewFunctionsClientExampleFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsClientExampleFilterer, error) { - contract, err := bindFunctionsClientExample(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &FunctionsClientExampleFilterer{contract: contract}, nil -} - -func bindFunctionsClientExample(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := FunctionsClientExampleMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_FunctionsClientExample *FunctionsClientExampleRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsClientExample.Contract.FunctionsClientExampleCaller.contract.Call(opts, result, method, params...) -} - -func (_FunctionsClientExample *FunctionsClientExampleRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.FunctionsClientExampleTransactor.contract.Transfer(opts) -} - -func (_FunctionsClientExample *FunctionsClientExampleRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.FunctionsClientExampleTransactor.contract.Transact(opts, method, params...) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsClientExample.Contract.contract.Call(opts, result, method, params...) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.contract.Transfer(opts) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.contract.Transact(opts, method, params...) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) MAXCALLBACKGAS(opts *bind.CallOpts) (uint32, error) { - var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "MAX_CALLBACK_GAS") - - if err != nil { - return *new(uint32), err - } - - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) - - return out0, err - -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) MAXCALLBACKGAS() (uint32, error) { - return _FunctionsClientExample.Contract.MAXCALLBACKGAS(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) MAXCALLBACKGAS() (uint32, error) { - return _FunctionsClientExample.Contract.MAXCALLBACKGAS(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastError(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastError") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) LastError() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastError(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastError() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastError(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastErrorLength(opts *bind.CallOpts) (uint32, error) { - var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastErrorLength") - - if err != nil { - return *new(uint32), err - } - - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) - - return out0, err - -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) LastErrorLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastErrorLength(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastErrorLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastErrorLength(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastRequestId(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastRequestId") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) LastRequestId() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastRequestId(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastRequestId() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastRequestId(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastResponse(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastResponse") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) LastResponse() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastResponse(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastResponse() ([32]byte, error) { - return _FunctionsClientExample.Contract.LastResponse(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) LastResponseLength(opts *bind.CallOpts) (uint32, error) { - var out []interface{} - err := _FunctionsClientExample.contract.Call(opts, &out, "lastResponseLength") - - if err != nil { - return *new(uint32), err - } - - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) - - return out0, err - -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) LastResponseLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastResponseLength(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) LastResponseLength() (uint32, error) { - return _FunctionsClientExample.Contract.LastResponseLength(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _FunctionsClientExample.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 (_FunctionsClientExample *FunctionsClientExampleSession) Owner() (common.Address, error) { - return _FunctionsClientExample.Contract.Owner(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleCallerSession) Owner() (common.Address, error) { - return _FunctionsClientExample.Contract.Owner(&_FunctionsClientExample.CallOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsClientExample.contract.Transact(opts, "acceptOwnership") -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsClientExample.Contract.AcceptOwnership(&_FunctionsClientExample.TransactOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsClientExample.Contract.AcceptOwnership(&_FunctionsClientExample.TransactOpts) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactor) HandleOracleFulfillment(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { - return _FunctionsClientExample.contract.Transact(opts, "handleOracleFulfillment", requestId, response, err) -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) HandleOracleFulfillment(requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.HandleOracleFulfillment(&_FunctionsClientExample.TransactOpts, requestId, response, err) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactorSession) HandleOracleFulfillment(requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.HandleOracleFulfillment(&_FunctionsClientExample.TransactOpts, requestId, response, err) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactor) SendRequest(opts *bind.TransactOpts, source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) { - return _FunctionsClientExample.contract.Transact(opts, "sendRequest", source, encryptedSecretsReferences, args, subscriptionId, jobId) -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) SendRequest(source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.SendRequest(&_FunctionsClientExample.TransactOpts, source, encryptedSecretsReferences, args, subscriptionId, jobId) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactorSession) SendRequest(source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.SendRequest(&_FunctionsClientExample.TransactOpts, source, encryptedSecretsReferences, args, subscriptionId, jobId) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _FunctionsClientExample.contract.Transact(opts, "transferOwnership", to) -} - -func (_FunctionsClientExample *FunctionsClientExampleSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.TransferOwnership(&_FunctionsClientExample.TransactOpts, to) -} - -func (_FunctionsClientExample *FunctionsClientExampleTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsClientExample.Contract.TransferOwnership(&_FunctionsClientExample.TransactOpts, to) -} - -type FunctionsClientExampleOwnershipTransferRequestedIterator struct { - Event *FunctionsClientExampleOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsClientExampleOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsClientExampleOwnershipTransferRequested) - 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(FunctionsClientExampleOwnershipTransferRequested) - 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 *FunctionsClientExampleOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *FunctionsClientExampleOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsClientExampleOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsClientExampleOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsClientExample.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsClientExampleOwnershipTransferRequestedIterator{contract: _FunctionsClientExample.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsClientExample.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsClientExampleOwnershipTransferRequested) - if err := _FunctionsClientExample.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_FunctionsClientExample *FunctionsClientExampleFilterer) ParseOwnershipTransferRequested(log types.Log) (*FunctionsClientExampleOwnershipTransferRequested, error) { - event := new(FunctionsClientExampleOwnershipTransferRequested) - if err := _FunctionsClientExample.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsClientExampleOwnershipTransferredIterator struct { - Event *FunctionsClientExampleOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsClientExampleOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsClientExampleOwnershipTransferred) - 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(FunctionsClientExampleOwnershipTransferred) - 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 *FunctionsClientExampleOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *FunctionsClientExampleOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsClientExampleOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsClientExampleOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsClientExample.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsClientExampleOwnershipTransferredIterator{contract: _FunctionsClientExample.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsClientExample.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsClientExampleOwnershipTransferred) - if err := _FunctionsClientExample.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 (_FunctionsClientExample *FunctionsClientExampleFilterer) ParseOwnershipTransferred(log types.Log) (*FunctionsClientExampleOwnershipTransferred, error) { - event := new(FunctionsClientExampleOwnershipTransferred) - if err := _FunctionsClientExample.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsClientExampleRequestFulfilledIterator struct { - Event *FunctionsClientExampleRequestFulfilled - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsClientExampleRequestFulfilledIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsClientExampleRequestFulfilled) - 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(FunctionsClientExampleRequestFulfilled) - 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 *FunctionsClientExampleRequestFulfilledIterator) Error() error { - return it.fail -} - -func (it *FunctionsClientExampleRequestFulfilledIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsClientExampleRequestFulfilled struct { - Id [32]byte - Raw types.Log -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) FilterRequestFulfilled(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientExampleRequestFulfilledIterator, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClientExample.contract.FilterLogs(opts, "RequestFulfilled", idRule) - if err != nil { - return nil, err - } - return &FunctionsClientExampleRequestFulfilledIterator{contract: _FunctionsClientExample.contract, event: "RequestFulfilled", logs: logs, sub: sub}, nil -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) WatchRequestFulfilled(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleRequestFulfilled, id [][32]byte) (event.Subscription, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClientExample.contract.WatchLogs(opts, "RequestFulfilled", idRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsClientExampleRequestFulfilled) - if err := _FunctionsClientExample.contract.UnpackLog(event, "RequestFulfilled", 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 (_FunctionsClientExample *FunctionsClientExampleFilterer) ParseRequestFulfilled(log types.Log) (*FunctionsClientExampleRequestFulfilled, error) { - event := new(FunctionsClientExampleRequestFulfilled) - if err := _FunctionsClientExample.contract.UnpackLog(event, "RequestFulfilled", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsClientExampleRequestSentIterator struct { - Event *FunctionsClientExampleRequestSent - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsClientExampleRequestSentIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsClientExampleRequestSent) - 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(FunctionsClientExampleRequestSent) - 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 *FunctionsClientExampleRequestSentIterator) Error() error { - return it.fail -} - -func (it *FunctionsClientExampleRequestSentIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsClientExampleRequestSent struct { - Id [32]byte - Raw types.Log -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) FilterRequestSent(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientExampleRequestSentIterator, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClientExample.contract.FilterLogs(opts, "RequestSent", idRule) - if err != nil { - return nil, err - } - return &FunctionsClientExampleRequestSentIterator{contract: _FunctionsClientExample.contract, event: "RequestSent", logs: logs, sub: sub}, nil -} - -func (_FunctionsClientExample *FunctionsClientExampleFilterer) WatchRequestSent(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleRequestSent, id [][32]byte) (event.Subscription, error) { - - var idRule []interface{} - for _, idItem := range id { - idRule = append(idRule, idItem) - } - - logs, sub, err := _FunctionsClientExample.contract.WatchLogs(opts, "RequestSent", idRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsClientExampleRequestSent) - if err := _FunctionsClientExample.contract.UnpackLog(event, "RequestSent", 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 (_FunctionsClientExample *FunctionsClientExampleFilterer) ParseRequestSent(log types.Log) (*FunctionsClientExampleRequestSent, error) { - event := new(FunctionsClientExampleRequestSent) - if err := _FunctionsClientExample.contract.UnpackLog(event, "RequestSent", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -func (_FunctionsClientExample *FunctionsClientExample) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _FunctionsClientExample.abi.Events["OwnershipTransferRequested"].ID: - return _FunctionsClientExample.ParseOwnershipTransferRequested(log) - case _FunctionsClientExample.abi.Events["OwnershipTransferred"].ID: - return _FunctionsClientExample.ParseOwnershipTransferred(log) - case _FunctionsClientExample.abi.Events["RequestFulfilled"].ID: - return _FunctionsClientExample.ParseRequestFulfilled(log) - case _FunctionsClientExample.abi.Events["RequestSent"].ID: - return _FunctionsClientExample.ParseRequestSent(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (FunctionsClientExampleOwnershipTransferRequested) Topic() common.Hash { - return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") -} - -func (FunctionsClientExampleOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") -} - -func (FunctionsClientExampleRequestFulfilled) Topic() common.Hash { - return common.HexToHash("0x85e1543bf2f84fe80c6badbce3648c8539ad1df4d2b3d822938ca0538be727e6") -} - -func (FunctionsClientExampleRequestSent) Topic() common.Hash { - return common.HexToHash("0x1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db8") -} - -func (_FunctionsClientExample *FunctionsClientExample) Address() common.Address { - return _FunctionsClientExample.address -} - -type FunctionsClientExampleInterface interface { - MAXCALLBACKGAS(opts *bind.CallOpts) (uint32, error) - - LastError(opts *bind.CallOpts) ([32]byte, error) - - LastErrorLength(opts *bind.CallOpts) (uint32, error) - - LastRequestId(opts *bind.CallOpts) ([32]byte, error) - - LastResponse(opts *bind.CallOpts) ([32]byte, error) - - LastResponseLength(opts *bind.CallOpts) (uint32, error) - - Owner(opts *bind.CallOpts) (common.Address, error) - - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - - HandleOracleFulfillment(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) - - SendRequest(opts *bind.TransactOpts, source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) - - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsClientExampleOwnershipTransferRequestedIterator, error) - - WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferRequested(log types.Log) (*FunctionsClientExampleOwnershipTransferRequested, error) - - FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsClientExampleOwnershipTransferredIterator, error) - - WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferred(log types.Log) (*FunctionsClientExampleOwnershipTransferred, error) - - FilterRequestFulfilled(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientExampleRequestFulfilledIterator, error) - - WatchRequestFulfilled(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleRequestFulfilled, id [][32]byte) (event.Subscription, error) - - ParseRequestFulfilled(log types.Log) (*FunctionsClientExampleRequestFulfilled, error) - - FilterRequestSent(opts *bind.FilterOpts, id [][32]byte) (*FunctionsClientExampleRequestSentIterator, error) - - WatchRequestSent(opts *bind.WatchOpts, sink chan<- *FunctionsClientExampleRequestSent, id [][32]byte) (event.Subscription, error) - - ParseRequestSent(log types.Log) (*FunctionsClientExampleRequestSent, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/generated/functions_coordinator/functions_coordinator.go deleted file mode 100644 index b52268c6fb8..00000000000 --- a/core/gethwrappers/generated/functions_coordinator/functions_coordinator.go +++ /dev/null @@ -1,2612 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package functions_coordinator - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -type FunctionsBillingCommitment struct { - SubscriptionId uint64 - Client common.Address - CallbackGasLimit uint32 - ExpectedGasPrice *big.Int - Don common.Address - DonFee *big.Int - AdminFee *big.Int - EstimatedTotalCostJuels *big.Int - GasOverhead *big.Int - Timestamp *big.Int -} - -type IFunctionsBillingRequestBilling struct { - SubscriptionId uint64 - Client common.Address - CallbackGasLimit uint32 - ExpectedGasPrice *big.Int -} - -type IFunctionsCoordinatorRequest struct { - SubscriptionId uint64 - Data []byte - DataVersion uint16 - CallbackGasLimit uint32 - Caller common.Address - SubscriptionOwner common.Address -} - -var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"result\",\"type\":\"uint8\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"fee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CostExceedsCommitment\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InsufficientGasProvided\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"InvalidRequestID\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"OCRConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"caller\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620059403803806200594083398101604081905262000034916200042d565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c58162000156565b505050151560f81b6080526001600160a01b038216620000f857604051632530e88560e11b815260040160405180910390fd5b600980546001600160a01b0319166001600160a01b0384161790556200011e8162000202565b805160209091012060085550600a80546001600160a01b0319166001600160a01b039290921691909117905550620006009350505050565b6001600160a01b038116331415620001b15760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806000806000806000808880602001905181019062000224919062000532565b97509750975097509750975097509750600084136200025a576040516321ea67b360e11b81526004810185905260240162000089565b604080516101008101825263ffffffff808b168083528a8216602084018190528983168486018190528b841660608601819052938916608086018190526001600160601b03891660a0870181905260c087018c905261ffff891660e0909701879052600c8054600160a01b9092026001600160a01b03600160801b909402939093166001600160801b036c0100000000000000000000000090980263ffffffff60601b196801000000000000000090960295909516600160401b600160801b03196401000000009097026001600160401b0319909416909717929092179490941694909417919091179390931691909117919091179055600d869055600e805461ffff19169091179055517fd09395baf4d99e44ce1b8e96a4396a3f896d0fd5e4517993f28ce0a6fb42e22790620003e8908a908a9089908b908a908990899063ffffffff97881681529587166020870152938616604086015291909416606084015260808301939093526001600160601b039290921660a082015261ffff9190911660c082015260e00190565b60405180910390a1505050505050505050565b80516001600160a01b03811681146200041357600080fd5b919050565b805163ffffffff811681146200041357600080fd5b6000806000606084860312156200044357600080fd5b6200044e84620003fb565b602085810151919450906001600160401b03808211156200046e57600080fd5b818701915087601f8301126200048357600080fd5b815181811115620004985762000498620005ea565b604051601f8201601f19908116603f01168101908382118183101715620004c357620004c3620005ea565b816040528281528a86848701011115620004dc57600080fd5b600093505b82841015620005005784840186015181850187015292850192620004e1565b82841115620005125760008684830101525b8097505050505050506200052960408501620003fb565b90509250925092565b600080600080600080600080610100898b0312156200055057600080fd5b6200055b8962000418565b97506200056b60208a0162000418565b96506200057b60408a0162000418565b95506200058b60608a0162000418565b945060808901519350620005a260a08a0162000418565b60c08a01519093506001600160601b0381168114620005c057600080fd5b60e08a015190925061ffff81168114620005d957600080fd5b809150509295985092959890939650565b634e487b7160e01b600052604160045260246000fd5b60805160f81c6153216200061f600039600061156f01526153216000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146104aa578063de9dfa46146104b2578063e3d0e712146104c5578063f2fde38b146104d857600080fd5b8063b1dc65a4146103f7578063c3f909d41461040a578063d227d2451461049757600080fd5b80639883c10d116100c85780639883c10d146103bd578063af1296d3146103cf578063afcb95d7146103d757600080fd5b806381ff70481461034257806385b214cf146103725780638da5cb5b1461039557600080fd5b8063533989871161015b5780637f15e166116101355780637f15e166146102ff5780638075603114610312578063814118341461032557806381f1b9381461033a57600080fd5b806353398987146102ce57806366316d8d146102e457806379ba5097146102f757600080fd5b806326ceabac1161018c57806326ceabac1461024f578063354497aa14610262578063466557181461027557600080fd5b8063083a5466146101b35780630a33e0a5146101c8578063181f5a771461020d575b600080fd5b6101c66101c13660046144d4565b6104eb565b005b6101db6101d6366004614621565b61053b565b604080519485526bffffffffffffffffffffffff90931660208501529183015260608201526080015b60405180910390f35b60408051808201909152601881527f46756e6374696f6e7320436f6f7264696e61746f72207631000000000000000060208201525b6040516102049190614b81565b6101c661025d3660046140fc565b610760565b6101c6610270366004614516565b610893565b6102b161028336600461454b565b5050600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff9091168152602001610204565b6102d66108fa565b604051610204929190614a80565b6101c66102f236600461418b565b610b1a565b6101c6610c95565b6101c661030d3660046144d4565b610d97565b6101c6610320366004614136565b610ee0565b61032d611028565b6040516102049190614a6d565b610242611097565b6004546002546040805163ffffffff80851682526401000000009094049093166020840152820152606001610204565b6103856103803660046144bb565b611120565b6040519015158152602001610204565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610204565b6008545b604051908152602001610204565b6103c161130a565b604080516001815260006020820181905291810191909152606001610204565b6101c66104053660046142ce565b6113fc565b600c54600d54600a54600e546040805163ffffffff80871682526401000000008704811660208301526c010000000000000000000000008704811692820192909252606081019490945268010000000000000000909404909316608083015273ffffffffffffffffffffffffffffffffffffffff1660a082015261ffff90911660c082015260e001610204565b6102b16104a5366004614759565b611b2d565b610242611c1c565b6102b16104c036600461454b565b611c2b565b6101c66104d3366004614201565b611cd5565b6101c66104e63660046140fc565b6126b9565b6104f36126ca565b8061052a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61053660138383613d2a565b505050565b60095460009081908190819073ffffffffffffffffffffffffffffffffffffffff163314610595576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6105a26020860186614e2d565b151590506105db576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160808101909152600090806105f7602089018961473c565b67ffffffffffffffff16815260200161061660a0890160808a016140fc565b73ffffffffffffffffffffffffffffffffffffffff1681526020016106416080890160608a01614679565b63ffffffff1681523a6020918201529091506106ae9061066390880188614e2d565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506106a8925050506060890160408a0161465c565b8361274d565b929750909550935091506106c860a08701608088016140fc565b73ffffffffffffffffffffffffffffffffffffffff16857fb108b073fa485003d66284614f1c3b4feb3f47ffc88f7873bf3b2ec4bb8939bc3261070e60208b018b61473c565b61071e60c08c0160a08d016140fc565b61072b60208d018d614e2d565b8d604001602081019061073e919061465c565b604051610750969594939291906149d9565b60405180910390a3509193509193565b3073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b1580156107a657600080fd5b505afa1580156107ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107de9190614119565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16148061082c57503373ffffffffffffffffffffffffffffffffffffffff8216145b610862576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260126020526040812061089091613dcc565b50565b60095473ffffffffffffffffffffffffffffffffffffffff1633146108e4576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108ed81612dba565b8051602090910120600855565b60608060003073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b815260040160006040518083038186803b15801561094557600080fd5b505afa158015610959573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261099f91908101906141c4565b90506000815167ffffffffffffffff8111156109bd576109bd615262565b6040519080825280602002602001820160405280156109f057816020015b60608152602001906001900390816109db5790505b50905060005b8251811015610b105760126000848381518110610a1557610a15615233565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610a62906150ca565b80601f0160208091040260200160405190810160405280929190818152602001828054610a8e906150ca565b8015610adb5780601f10610ab057610100808354040283529160200191610adb565b820191906000526020600020905b815481529060010190602001808311610abe57829003601f168201915b5050505050828281518110610af257610af2615233565b60200260200101819052508080610b089061511e565b9150506109f6565b5090939092509050565b610b22613067565b6bffffffffffffffffffffffff8116610b555750336000908152600f60205260409020546bffffffffffffffffffffffff165b336000908152600f60205260409020546bffffffffffffffffffffffff80831691161015610baf576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600f602052604081208054839290610bdc9084906bffffffffffffffffffffffff1661509d565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915081906366316d8d90604401600060405180830381600087803b158015610c7857600080fd5b505af1158015610c8c573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610d1b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600960009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b8152600401602060405180830381600087803b158015610e0157600080fd5b505af1158015610e15573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e399190614119565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610e9d576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80610ed4576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61053660118383613d2a565b3073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b815260040160206040518083038186803b158015610f2657600080fd5b505afa158015610f3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f5e9190614119565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161480610fbc5750610f9b336131c7565b8015610fbc57503373ffffffffffffffffffffffffffffffffffffffff8416145b610ff2576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601260205260409020611022908383613d2a565b50505050565b6060600780548060200260200160405190810160405280929190818152602001828054801561108d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611062575b5050505050905090565b6060601380546110a6906150ca565b80601f01602080910402602001604051908101604052809291908181526020018280546110d2906150ca565b801561108d5780601f106110f45761010080835404028352916020019161108d565b820191906000526020600020905b81548152906001019060200180831161110257509395945050505050565b60095460009073ffffffffffffffffffffffffffffffffffffffff163314611174576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600b6020908152604091829020825161014081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e08401526004810154610100840152600501546101208301526112825750600092915050565b6000838152600b602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600481018390556005018290555184917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a260019150505b919050565b600c54600a54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a0929190829003018186803b15801561138f57600080fd5b505afa1580156113a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906113c791906147c9565b509350509250508280156113e957506113e08142615086565b8463ffffffff16105b156113f457600d5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161145291849163ffffffff851691908e908e90819084018382808284376000920191909152506132eb92505050565b611488576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461155d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610d12565b61156b8b8b8b8b8b8b6132f4565b60007f0000000000000000000000000000000000000000000000000000000000000000156115c8576002826020015183604001516115a99190614f68565b6115b39190614fc8565b6115be906001614f68565b60ff1690506115de565b60208201516115d8906001614f68565b60ff1690505b888114611647576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610d12565b8887146116b0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610d12565b3360009081526005602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156116f3576116f36151d5565b6002811115611704576117046151d5565b9052509050600281602001516002811115611721576117216151d5565b14801561176857506007816000015160ff168154811061174357611743615233565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6117ce576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610d12565b50505050506117db613e06565b6000808a8a6040516117ee9291906149c9565b604051908190038120611805918e906020016149ad565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b0f57600060018489846020811061186e5761186e615233565b61187b91901a601b614f68565b8e8e8681811061188d5761188d615233565b905060200201358d8d878181106118a6576118a6615233565b90506020020135604051600081526020016040526040516118e3949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611905573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526005602090815290849020838501909452835460ff80821685529296509294508401916101009004166002811115611985576119856151d5565b6002811115611996576119966151d5565b90525092506001836020015160028111156119b3576119b36151d5565b14611a1a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610d12565b8251600090879060ff16601f8110611a3457611a34615233565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611ab6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610d12565b8086846000015160ff16601f8110611ad057611ad0615233565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611afb600186614f68565b94505080611b089061511e565b905061184f565b505050611b20833383858e8e6133a2565b5050505050505050505050565b60008060405180608001604052808867ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018563ffffffff1681526020018481525090506000611bbc87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250869250610283915050565b90506000611c0188888080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250879250611c2b915050565b9050611c0f8686848461364a565b9998505050505050505050565b6060601180546110a6906150ca565b600954604080517f2a905ccc000000000000000000000000000000000000000000000000000000008152905160009273ffffffffffffffffffffffffffffffffffffffff1691632a905ccc916004808301926020929190829003018186803b158015611c9657600080fd5b505afa158015611caa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611cce9190614848565b9392505050565b855185518560ff16601f831115611d48576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610d12565b60008111611db2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610d12565b818314611e40576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610d12565b611e4b816003615015565b8311611eb3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610d12565b611ebb6126ca565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f029088613780565b600654156120b757600654600090611f1c90600190615086565b9050600060068281548110611f3357611f33615233565b60009182526020822001546007805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f6d57611f6d615233565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526005909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090811690915592909116808452922080549091169055600680549192509080611fed57611fed615204565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600780548061205657612056615204565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f02915050565b60005b81515181101561251c57600060056000846000015184815181106120e0576120e0615233565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561212a5761212a6151d5565b14612191576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610d12565b6040805180820190915260ff821681526001602082015282518051600591600091859081106121c2576121c2615233565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001617610100836002811115612263576122636151d5565b0217905550600091506122739050565b600560008460200151848151811061228d5761228d615233565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122d7576122d76151d5565b1461233e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610d12565b6040805180820190915260ff82168152602081016002815250600560008460200151848151811061237157612371615233565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001617610100836002811115612412576124126151d5565b02179055505082518051600692508390811061243057612430615233565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160079190839081106124ac576124ac615233565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556125158161511e565b90506120ba565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600480547fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff811664010000000063ffffffff4381168202928317855590830481169360019390926000926125ae928692908216911617614f1d565b92506101000a81548163ffffffff021916908363ffffffff16021790555061260d4630600460009054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a0015161378c565b6002819055825180516003805460ff909216610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff90921691909117905560045460208501516040808701516060880151608089015160a08a015193517f324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a09986126ac988b98919763ffffffff909216969095919491939192614d2b565b60405180910390a1611b20565b6126c16126ca565b61089081613837565b60005473ffffffffffffffffffffffffffffffffffffffff16331461274b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610d12565b565b600e5460009081908190819061ffff908116908716111561279a576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c54604086015163ffffffff918216911611156127fc57604085810151600c5491517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff918216600482015291166024820152604401610d12565b600061282d600c547401000000000000000000000000000000000000000090046bffffffffffffffffffffffff1690565b9050600061283b8988611c2b565b9050600061285388604001518960600151858561364a565b60095489516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015291925073ffffffffffffffffffffffffffffffffffffffff16906000908190839063a47c76969060240160006040518083038186803b1580156128d157600080fd5b505afa1580156128e5573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261292b9190810190614865565b50505060208d01518d516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529294509092506000919085169063674603d09060440160606040518083038186803b1580156129b757600080fd5b505afa1580156129cb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906129ef9190614469565b509150506bffffffffffffffffffffffff8516612a0c838561509d565b6bffffffffffffffffffffffff161015612a52576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612ad1308e602001518f60000151856001612a6f9190614f45565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060006040518061014001604052808f6000015167ffffffffffffffff1681526020018f6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018f6040015163ffffffff1681526020018f6060015181526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6bffffffffffffffffffffffff168152602001896bffffffffffffffffffffffff168152602001886bffffffffffffffffffffffff168152602001600c600001600c9054906101000a900463ffffffff16600c60000160089054906101000a900463ffffffff16612bbd9190614f1d565b63ffffffff9081168252426020928301526000858152600b835260409081902084518154948601518684015167ffffffffffffffff9092167fffffffff00000000000000000000000000000000000000000000000000000000909616959095176801000000000000000073ffffffffffffffffffffffffffffffffffffffff96871602177bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c0100000000000000000000000000000000000000000000000000000000919094160292909217825560608401516001830155608084015160a08501519316740100000000000000000000000000000000000000006bffffffffffffffffffffffff9485160217600283015560c084015160038301805460e08701519286167fffffffffffffffff000000000000000000000000000000000000000000000000909116176c0100000000000000000000000092909516919091029390931790925561010083015160048201556101208301516005909101555190915082907f9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee542290612d6a908490614b94565b60405180910390a250600c54909f959e5063ffffffff6c01000000000000000000000000820481169e50700100000000000000000000000000000000909104169b50939950505050505050505050565b60008060008060008060008088806020019051810190612dda9190614696565b9750975097509750975097509750975060008413612e27576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101859052602401610d12565b604080516101008101825263ffffffff808b168083528a8216602084018190528983168486018190528b841660608601819052938916608086018190526bffffffffffffffffffffffff891660a0870181905260c087018c905261ffff891660e0909701879052600c80547401000000000000000000000000000000000000000090920273ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909402939093166fffffffffffffffffffffffffffffffff6c010000000000000000000000009098027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909602959095167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009097027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909416909717929092179490941694909417919091179390931691909117919091179055600d869055600e80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000169091179055517fd09395baf4d99e44ce1b8e96a4396a3f896d0fd5e4517993f28ce0a6fb42e22790613054908a908a9089908b908a908990899063ffffffff97881681529587166020870152938616604086015291909416606084015260808301939093526bffffffffffffffffffffffff9290921660a082015261ffff9190911660c082015260e00190565b60405180910390a1505050505050505050565b6000613071611028565b805160105491925060009161309491906bffffffffffffffffffffffff16614fea565b905060005b82518160ff1610156131685781600f6000858460ff16815181106130bf576130bf615233565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166131279190614f8d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550808061316090615157565b915050613099565b5081516131759082615052565b601080546000906131959084906bffffffffffffffffffffffff1661509d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000803073ffffffffffffffffffffffffffffffffffffffff1663814118346040518163ffffffff1660e01b815260040160006040518083038186803b15801561321057600080fd5b505afa158015613224573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261326a91908101906141c4565b905060005b81518110156132e1578373ffffffffffffffffffffffffffffffffffffffff168282815181106132a1576132a1615233565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156132cf575060019392505050565b806132d98161511e565b91505061326f565b5060009392505050565b60019392505050565b6000613301826020615015565b61330c856020615015565b61331888610144614f05565b6133229190614f05565b61332c9190614f05565b613337906000614f05565b9050368114610c8c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610d12565b606080806133b284860186614385565b8251929550909350915015806133ca57508151835114155b806133d757508051835114155b1561340e576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b835181101561363e57600061347285838151811061343157613431615233565b602002602001015185848151811061344b5761344b615233565b602002602001015185858151811061346557613465615233565b602002602001015161392d565b90506000816006811115613488576134886151d5565b14806134a5575060018160068111156134a3576134a36151d5565b145b15613500578482815181106134bc576134bc615233565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a261362b565b6002816006811115613514576135146151d5565b14156135655784828151811061352c5761352c615233565b60200260200101517fa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be60405160405180910390a261362b565b6003816006811115613579576135796151d5565b14156135ca5784828151811061359157613591615233565b60200260200101517f357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e060405160405180910390a261362b565b60058160068111156135de576135de6151d5565b141561362b578482815181106135f6576135f6615233565b60200260200101517f689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc860405160405180910390a25b50806136368161511e565b915050613411565b50505050505050505050565b60008061365561130a565b905060008113613694576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d12565b600c5460009087906136ca9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614f1d565b6136d49190614f1d565b63ffffffff169050600082826136f289670de0b6b3a7640000615015565b6136fc9190615015565b6137069190614fb4565b905060006137256bffffffffffffffffffffffff808816908916614f05565b905061373d816b033b2e3c9fd0803ce8000000615086565b821115613776576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611c0f8183614f05565b613788613067565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016137b099989796959493929190614c96565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b73ffffffffffffffffffffffffffffffffffffffff81163314156138b7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610d12565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000838152600b60209081526040808320815161014081018352815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116958301959095527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169281019290925260018101546060830152600281015492831660808301819052740100000000000000000000000000000000000000009093046bffffffffffffffffffffffff90811660a0840152600382015480821660c08501526c0100000000000000000000000090041660e083015260048101546101008301526005015461012082015290613a3c576002915050611cce565b6000858152600b6020526040812081815560018101829055600281018290556003810180547fffffffffffffffff00000000000000000000000000000000000000000000000016905560048101829055600501819055613a9a61130a565b905060008113613ad9576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610d12565b600081613aee3a670de0b6b3a7640000615015565b613af89190614fb4565b9050600083610100015182613b0d9190615015565b905060008460a0015182613b219190614f8d565b6009546040517f3fd67e0500000000000000000000000000000000000000000000000000000000815291925073ffffffffffffffffffffffffffffffffffffffff169060009081908390633fd67e0590613b89908f908f908f908c908b903390600401614b10565b6040805180830381600087803b158015613ba257600080fd5b505af1158015613bb6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bda9190614819565b9092509050613be98186614f8d565b336000908152600f6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560a08a0151601080549193909291613c4991859116614f8d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508b7f30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff0353589600001518a60a001518489613caf9190614f8d565b60c08d015160a08e0151613cc3888d614f8d565b613ccd9190614f8d565b613cd79190614f8d565b8760ff166006811115613cec57613cec6151d5565b604051613cfd959493929190614db1565b60405180910390a28160ff166006811115613d1a57613d1a6151d5565b9c9b505050505050505050505050565b828054613d36906150ca565b90600052602060002090601f016020900481019282613d585760008555613dbc565b82601f10613d8f578280017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00823516178555613dbc565b82800160010185558215613dbc579182015b82811115613dbc578235825591602001919060010190613da1565b50613dc8929150613e25565b5090565b508054613dd8906150ca565b6000825580601f10613de8575050565b601f0160209004906000526020600020908101906108909190613e25565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613dc85760008155600101613e26565b600082601f830112613e4b57600080fd5b81356020613e60613e5b83614ee1565b614e92565b80838252828201915082860187848660051b8901011115613e8057600080fd5b60005b85811015613ea8578135613e9681615291565b84529284019290840190600101613e83565b5090979650505050505050565b600082601f830112613ec657600080fd5b81516020613ed6613e5b83614ee1565b80838252828201915082860187848660051b8901011115613ef657600080fd5b60005b85811015613ea8578151613f0c81615291565b84529284019290840190600101613ef9565b60008083601f840112613f3057600080fd5b50813567ffffffffffffffff811115613f4857600080fd5b6020830191508360208260051b8501011115613f6357600080fd5b9250929050565b600082601f830112613f7b57600080fd5b81356020613f8b613e5b83614ee1565b80838252828201915082860187848660051b8901011115613fab57600080fd5b6000805b86811015613fee57823567ffffffffffffffff811115613fcd578283fd5b613fdb8b88838d010161403e565b8652509385019391850191600101613faf565b509198975050505050505050565b60008083601f84011261400e57600080fd5b50813567ffffffffffffffff81111561402657600080fd5b602083019150836020828501011115613f6357600080fd5b600082601f83011261404f57600080fd5b813567ffffffffffffffff81111561406957614069615262565b61409a60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614e92565b8181528460208386010111156140af57600080fd5b816020850160208301376000918101602001919091529392505050565b8035611305816152d5565b8035611305816152eb565b805169ffffffffffffffffffff8116811461130557600080fd5b60006020828403121561410e57600080fd5b8135611cce81615291565b60006020828403121561412b57600080fd5b8151611cce81615291565b60008060006040848603121561414b57600080fd5b833561415681615291565b9250602084013567ffffffffffffffff81111561417257600080fd5b61417e86828701613ffc565b9497909650939450505050565b6000806040838503121561419e57600080fd5b82356141a981615291565b915060208301356141b9816152fa565b809150509250929050565b6000602082840312156141d657600080fd5b815167ffffffffffffffff8111156141ed57600080fd5b6141f984828501613eb5565b949350505050565b60008060008060008060c0878903121561421a57600080fd5b863567ffffffffffffffff8082111561423257600080fd5b61423e8a838b01613e3a565b9750602089013591508082111561425457600080fd5b6142608a838b01613e3a565b965061426e60408a016140d7565b9550606089013591508082111561428457600080fd5b6142908a838b0161403e565b945061429e60808a016140cc565b935060a08901359150808211156142b457600080fd5b506142c189828a0161403e565b9150509295509295509295565b60008060008060008060008060e0898b0312156142ea57600080fd5b606089018a8111156142fb57600080fd5b8998503567ffffffffffffffff8082111561431557600080fd5b6143218c838d01613ffc565b909950975060808b013591508082111561433a57600080fd5b6143468c838d01613f1e565b909750955060a08b013591508082111561435f57600080fd5b5061436c8b828c01613f1e565b999c989b50969995989497949560c00135949350505050565b60008060006060848603121561439a57600080fd5b833567ffffffffffffffff808211156143b257600080fd5b818601915086601f8301126143c657600080fd5b813560206143d6613e5b83614ee1565b8083825282820191508286018b848660051b89010111156143f657600080fd5b600096505b848710156144195780358352600196909601959183019183016143fb565b509750508701359250508082111561443057600080fd5b61443c87838801613f6a565b9350604086013591508082111561445257600080fd5b5061445f86828701613f6a565b9150509250925092565b60008060006060848603121561447e57600080fd5b8351801515811461448e57600080fd5b602085015190935061449f816152d5565b60408501519092506144b0816152d5565b809150509250925092565b6000602082840312156144cd57600080fd5b5035919050565b600080602083850312156144e757600080fd5b823567ffffffffffffffff8111156144fe57600080fd5b61450a85828601613ffc565b90969095509350505050565b60006020828403121561452857600080fd5b813567ffffffffffffffff81111561453f57600080fd5b6141f98482850161403e565b60008082840360a081121561455f57600080fd5b833567ffffffffffffffff8082111561457757600080fd5b6145838783880161403e565b945060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0840112156145b557600080fd5b604051925060808301915082821081831117156145d4576145d4615262565b5060405260208401356145e6816152d5565b815260408401356145f681615291565b60208201526060840135614609816152c3565b60408201526080939093013560608401525092909150565b60006020828403121561463357600080fd5b813567ffffffffffffffff81111561464a57600080fd5b820160c08185031215611cce57600080fd5b60006020828403121561466e57600080fd5b8135611cce816152b3565b60006020828403121561468b57600080fd5b8135611cce816152c3565b600080600080600080600080610100898b0312156146b357600080fd5b88516146be816152c3565b60208a01519098506146cf816152c3565b60408a01519097506146e0816152c3565b60608a01519096506146f1816152c3565b60808a015160a08b01519196509450614709816152c3565b60c08a015190935061471a816152fa565b60e08a015190925061472b816152b3565b809150509295985092959890939650565b60006020828403121561474e57600080fd5b8135611cce816152d5565b60008060008060006080868803121561477157600080fd5b853561477c816152d5565b9450602086013567ffffffffffffffff81111561479857600080fd5b6147a488828901613ffc565b90955093505060408601356147b8816152c3565b949793965091946060013592915050565b600080600080600060a086880312156147e157600080fd5b6147ea866140e2565b945060208601519350604086015192506060860151915061480d608087016140e2565b90509295509295909350565b6000806040838503121561482c57600080fd5b8251614837816152eb565b60208401519092506141b9816152fa565b60006020828403121561485a57600080fd5b8151611cce816152fa565b600080600080600060a0868803121561487d57600080fd5b8551614888816152fa565b6020870151909550614899816152fa565b60408701519094506148aa81615291565b60608701519093506148bb81615291565b608087015190925067ffffffffffffffff8111156148d857600080fd5b6148e488828901613eb5565b9150509295509295909350565b600081518084526020808501945080840160005b8381101561493757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614905565b509495945050505050565b6000815180845260005b818110156149685760208185018101518683018201520161494c565b8181111561497a576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b8281526060826020830137600060809190910190815292915050565b8183823760009101908152919050565b600073ffffffffffffffffffffffffffffffffffffffff808916835267ffffffffffffffff8816602084015280871660408401525060a060608301528360a0830152838560c0840137600060c0858401015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116830101905061ffff83166080830152979650505050505050565b602081526000611cce60208301846148f1565b604081526000614a9360408301856148f1565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614b01577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614aef838351614942565b94860194925090850190600101614ab5565b50909998505050505050505050565b86815260c060208201526000614b2960c0830188614942565b8281036040840152614b3b8188614942565b6bffffffffffffffffffffffff96871660608501529490951660808301525073ffffffffffffffffffffffffffffffffffffffff9190911660a090910152949350505050565b602081526000611cce6020830184614942565b815167ffffffffffffffff16815261014081016020830151614bce602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151614be6604084018263ffffffff169052565b50606083015160608301526080830151614c18608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a0830151614c3860a08401826bffffffffffffffffffffffff169052565b5060c0830151614c5860c08401826bffffffffffffffffffffffff169052565b5060e0830151614c7860e08401826bffffffffffffffffffffffff169052565b50610100838101519083015261012092830151929091019190915290565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614cdd8285018b6148f1565b91508382036080850152614cf1828a6148f1565b915060ff881660a085015283820360c0850152614d0e8288614942565b90861660e08501528381036101008501529050613d1a8185614942565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614d5b8184018a6148f1565b90508281036080840152614d6f81896148f1565b905060ff871660a084015282810360c0840152614d8c8187614942565b905067ffffffffffffffff851660e0840152828103610100840152613d1a8185614942565b67ffffffffffffffff861681526bffffffffffffffffffffffff858116602083015284811660408301528316606082015260a0810160078310614e1d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8260808301529695505050505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614e6257600080fd5b83018035915067ffffffffffffffff821115614e7d57600080fd5b602001915036819003821315613f6357600080fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614ed957614ed9615262565b604052919050565b600067ffffffffffffffff821115614efb57614efb615262565b5060051b60200190565b60008219821115614f1857614f18615177565b500190565b600063ffffffff808316818516808303821115614f3c57614f3c615177565b01949350505050565b600067ffffffffffffffff808316818516808303821115614f3c57614f3c615177565b600060ff821660ff84168060ff03821115614f8557614f85615177565b019392505050565b60006bffffffffffffffffffffffff808316818516808303821115614f3c57614f3c615177565b600082614fc357614fc36151a6565b500490565b600060ff831680614fdb57614fdb6151a6565b8060ff84160491505092915050565b60006bffffffffffffffffffffffff80841680615009576150096151a6565b92169190910492915050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561504d5761504d615177565b500290565b60006bffffffffffffffffffffffff8083168185168183048111821515161561507d5761507d615177565b02949350505050565b60008282101561509857615098615177565b500390565b60006bffffffffffffffffffffffff838116908316818110156150c2576150c2615177565b039392505050565b600181811c908216806150de57607f821691505b60208210811415615118577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82141561515057615150615177565b5060010190565b600060ff821660ff81141561516e5761516e615177565b60010192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8116811461089057600080fd5b61ffff8116811461089057600080fd5b63ffffffff8116811461089057600080fd5b67ffffffffffffffff8116811461089057600080fd5b60ff8116811461089057600080fd5b6bffffffffffffffffffffffff8116811461089057600080fdfea164736f6c6343000806000a", -} - -var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI - -var FunctionsCoordinatorBin = FunctionsCoordinatorMetaData.Bin - -func DeployFunctionsCoordinator(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address, config []byte, linkToNativeFeed common.Address) (common.Address, *types.Transaction, *FunctionsCoordinator, error) { - parsed, err := FunctionsCoordinatorMetaData.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(FunctionsCoordinatorBin), backend, router, config, linkToNativeFeed) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &FunctionsCoordinator{FunctionsCoordinatorCaller: FunctionsCoordinatorCaller{contract: contract}, FunctionsCoordinatorTransactor: FunctionsCoordinatorTransactor{contract: contract}, FunctionsCoordinatorFilterer: FunctionsCoordinatorFilterer{contract: contract}}, nil -} - -type FunctionsCoordinator struct { - address common.Address - abi abi.ABI - FunctionsCoordinatorCaller - FunctionsCoordinatorTransactor - FunctionsCoordinatorFilterer -} - -type FunctionsCoordinatorCaller struct { - contract *bind.BoundContract -} - -type FunctionsCoordinatorTransactor struct { - contract *bind.BoundContract -} - -type FunctionsCoordinatorFilterer struct { - contract *bind.BoundContract -} - -type FunctionsCoordinatorSession struct { - Contract *FunctionsCoordinator - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type FunctionsCoordinatorCallerSession struct { - Contract *FunctionsCoordinatorCaller - CallOpts bind.CallOpts -} - -type FunctionsCoordinatorTransactorSession struct { - Contract *FunctionsCoordinatorTransactor - TransactOpts bind.TransactOpts -} - -type FunctionsCoordinatorRaw struct { - Contract *FunctionsCoordinator -} - -type FunctionsCoordinatorCallerRaw struct { - Contract *FunctionsCoordinatorCaller -} - -type FunctionsCoordinatorTransactorRaw struct { - Contract *FunctionsCoordinatorTransactor -} - -func NewFunctionsCoordinator(address common.Address, backend bind.ContractBackend) (*FunctionsCoordinator, error) { - abi, err := abi.JSON(strings.NewReader(FunctionsCoordinatorABI)) - if err != nil { - return nil, err - } - contract, err := bindFunctionsCoordinator(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &FunctionsCoordinator{address: address, abi: abi, FunctionsCoordinatorCaller: FunctionsCoordinatorCaller{contract: contract}, FunctionsCoordinatorTransactor: FunctionsCoordinatorTransactor{contract: contract}, FunctionsCoordinatorFilterer: FunctionsCoordinatorFilterer{contract: contract}}, nil -} - -func NewFunctionsCoordinatorCaller(address common.Address, caller bind.ContractCaller) (*FunctionsCoordinatorCaller, error) { - contract, err := bindFunctionsCoordinator(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorCaller{contract: contract}, nil -} - -func NewFunctionsCoordinatorTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsCoordinatorTransactor, error) { - contract, err := bindFunctionsCoordinator(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorTransactor{contract: contract}, nil -} - -func NewFunctionsCoordinatorFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsCoordinatorFilterer, error) { - contract, err := bindFunctionsCoordinator(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorFilterer{contract: contract}, nil -} - -func bindFunctionsCoordinator(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := FunctionsCoordinatorMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsCoordinator.Contract.FunctionsCoordinatorCaller.contract.Call(opts, result, method, params...) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.FunctionsCoordinatorTransactor.contract.Transfer(opts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.FunctionsCoordinatorTransactor.contract.Transact(opts, method, params...) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsCoordinator.Contract.contract.Call(opts, result, method, params...) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.contract.Transfer(opts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.contract.Transact(opts, method, params...) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "estimateCost", subscriptionId, data, callbackGasLimit, gasPrice) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) EstimateCost(subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) { - return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPrice) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) EstimateCost(subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) { - return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPrice) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAdminFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getAdminFee", arg0, arg1) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetAdminFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetAdminFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetAdminFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetAdminFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAllNodePublicKeys(opts *bind.CallOpts) ([]common.Address, [][]byte, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getAllNodePublicKeys") - - if err != nil { - return *new([]common.Address), *new([][]byte), err - } - - out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) - out1 := *abi.ConvertType(out[1], new([][]byte)).(*[][]byte) - - return out0, out1, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetAllNodePublicKeys() ([]common.Address, [][]byte, error) { - return _FunctionsCoordinator.Contract.GetAllNodePublicKeys(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetAllNodePublicKeys() ([]common.Address, [][]byte, error) { - return _FunctionsCoordinator.Contract.GetAllNodePublicKeys(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.CallOpts) (GetConfig, - - error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getConfig") - - outstruct := new(GetConfig) - if err != nil { - return *outstruct, err - } - - outstruct.MaxCallbackGasLimit = *abi.ConvertType(out[0], new(uint32)).(*uint32) - outstruct.FeedStalenessSeconds = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.GasOverheadAfterCallback = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) - outstruct.FallbackNativePerUnitLink = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) - outstruct.GasOverheadBeforeCallback = *abi.ConvertType(out[4], new(uint32)).(*uint32) - outstruct.LinkPriceFeed = *abi.ConvertType(out[5], new(common.Address)).(*common.Address) - outstruct.MaxSupportedRequestDataVersion = *abi.ConvertType(out[6], new(uint16)).(*uint16) - - return *outstruct, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfig() (GetConfig, - - error) { - return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (GetConfig, - - error) { - return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getConfigHash") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfigHash() ([32]byte, error) { - return _FunctionsCoordinator.Contract.GetConfigHash(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfigHash() ([32]byte, error) { - return _FunctionsCoordinator.Contract.GetConfigHash(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getDONFee", arg0, arg1) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetDONFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetDONFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetDONFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetDONFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONPublicKey(opts *bind.CallOpts) ([]byte, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getDONPublicKey") - - if err != nil { - return *new([]byte), err - } - - out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetDONPublicKey() ([]byte, error) { - return _FunctionsCoordinator.Contract.GetDONPublicKey(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetDONPublicKey() ([]byte, error) { - return _FunctionsCoordinator.Contract.GetDONPublicKey(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetFeedData(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getFeedData") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetFeedData() (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetFeedData(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetFeedData() (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetFeedData(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetThresholdPublicKey(opts *bind.CallOpts) ([]byte, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getThresholdPublicKey") - - if err != nil { - return *new([]byte), err - } - - out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetThresholdPublicKey() ([]byte, error) { - return _FunctionsCoordinator.Contract.GetThresholdPublicKey(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetThresholdPublicKey() ([]byte, error) { - return _FunctionsCoordinator.Contract.GetThresholdPublicKey(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) LatestConfigDetails(opts *bind.CallOpts) (LatestConfigDetails, - - error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "latestConfigDetails") - - outstruct := new(LatestConfigDetails) - if err != nil { - return *outstruct, err - } - - outstruct.ConfigCount = *abi.ConvertType(out[0], new(uint32)).(*uint32) - outstruct.BlockNumber = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.ConfigDigest = *abi.ConvertType(out[2], new([32]byte)).(*[32]byte) - - return *outstruct, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) LatestConfigDetails() (LatestConfigDetails, - - error) { - return _FunctionsCoordinator.Contract.LatestConfigDetails(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) LatestConfigDetails() (LatestConfigDetails, - - error) { - return _FunctionsCoordinator.Contract.LatestConfigDetails(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) LatestConfigDigestAndEpoch(opts *bind.CallOpts) (LatestConfigDigestAndEpoch, - - error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "latestConfigDigestAndEpoch") - - outstruct := new(LatestConfigDigestAndEpoch) - if err != nil { - return *outstruct, err - } - - outstruct.ScanLogs = *abi.ConvertType(out[0], new(bool)).(*bool) - outstruct.ConfigDigest = *abi.ConvertType(out[1], new([32]byte)).(*[32]byte) - outstruct.Epoch = *abi.ConvertType(out[2], new(uint32)).(*uint32) - - return *outstruct, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) LatestConfigDigestAndEpoch() (LatestConfigDigestAndEpoch, - - error) { - return _FunctionsCoordinator.Contract.LatestConfigDigestAndEpoch(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) LatestConfigDigestAndEpoch() (LatestConfigDigestAndEpoch, - - error) { - return _FunctionsCoordinator.Contract.LatestConfigDigestAndEpoch(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _FunctionsCoordinator.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 (_FunctionsCoordinator *FunctionsCoordinatorSession) Owner() (common.Address, error) { - return _FunctionsCoordinator.Contract.Owner(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) Owner() (common.Address, error) { - return _FunctionsCoordinator.Contract.Owner(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) Transmitters(opts *bind.CallOpts) ([]common.Address, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "transmitters") - - if err != nil { - return *new([]common.Address), err - } - - out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) Transmitters() ([]common.Address, error) { - return _FunctionsCoordinator.Contract.Transmitters(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) Transmitters() ([]common.Address, error) { - return _FunctionsCoordinator.Contract.Transmitters(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { - var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "typeAndVersion") - - if err != nil { - return *new(string), err - } - - out0 := *abi.ConvertType(out[0], new(string)).(*string) - - return out0, err - -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) TypeAndVersion() (string, error) { - return _FunctionsCoordinator.Contract.TypeAndVersion(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) TypeAndVersion() (string, error) { - return _FunctionsCoordinator.Contract.TypeAndVersion(&_FunctionsCoordinator.CallOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "acceptOwnership") -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.AcceptOwnership(&_FunctionsCoordinator.TransactOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.AcceptOwnership(&_FunctionsCoordinator.TransactOpts) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) DeleteCommitment(opts *bind.TransactOpts, requestId [32]byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "deleteCommitment", requestId) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) DeleteCommitment(requestId [32]byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.DeleteCommitment(&_FunctionsCoordinator.TransactOpts, requestId) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) DeleteCommitment(requestId [32]byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.DeleteCommitment(&_FunctionsCoordinator.TransactOpts, requestId) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) DeleteNodePublicKey(opts *bind.TransactOpts, node common.Address) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "deleteNodePublicKey", node) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) DeleteNodePublicKey(node common.Address) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.DeleteNodePublicKey(&_FunctionsCoordinator.TransactOpts, node) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) DeleteNodePublicKey(node common.Address) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.DeleteNodePublicKey(&_FunctionsCoordinator.TransactOpts, node) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "oracleWithdraw", recipient, amount) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) OracleWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.OracleWithdraw(&_FunctionsCoordinator.TransactOpts, recipient, amount) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) OracleWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.OracleWithdraw(&_FunctionsCoordinator.TransactOpts, recipient, amount) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "sendRequest", request) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SendRequest(request IFunctionsCoordinatorRequest) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SendRequest(&_FunctionsCoordinator.TransactOpts, request) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SendRequest(request IFunctionsCoordinatorRequest) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SendRequest(&_FunctionsCoordinator.TransactOpts, request) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setConfig", config) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetConfig(config []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig(&_FunctionsCoordinator.TransactOpts, config) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetConfig(config []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig(&_FunctionsCoordinator.TransactOpts, config) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetConfig0(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setConfig0", _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetConfig0(_signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig0(&_FunctionsCoordinator.TransactOpts, _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetConfig0(_signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetConfig0(&_FunctionsCoordinator.TransactOpts, _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetDONPublicKey(opts *bind.TransactOpts, donPublicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setDONPublicKey", donPublicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetDONPublicKey(donPublicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetDONPublicKey(&_FunctionsCoordinator.TransactOpts, donPublicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetDONPublicKey(donPublicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetDONPublicKey(&_FunctionsCoordinator.TransactOpts, donPublicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetNodePublicKey(opts *bind.TransactOpts, node common.Address, publicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setNodePublicKey", node, publicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetNodePublicKey(node common.Address, publicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetNodePublicKey(&_FunctionsCoordinator.TransactOpts, node, publicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetNodePublicKey(node common.Address, publicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetNodePublicKey(&_FunctionsCoordinator.TransactOpts, node, publicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetThresholdPublicKey(opts *bind.TransactOpts, thresholdPublicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "setThresholdPublicKey", thresholdPublicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SetThresholdPublicKey(thresholdPublicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetThresholdPublicKey(&_FunctionsCoordinator.TransactOpts, thresholdPublicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetThresholdPublicKey(thresholdPublicKey []byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SetThresholdPublicKey(&_FunctionsCoordinator.TransactOpts, thresholdPublicKey) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "transferOwnership", to) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.TransferOwnership(&_FunctionsCoordinator.TransactOpts, to) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.TransferOwnership(&_FunctionsCoordinator.TransactOpts, to) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) Transmit(opts *bind.TransactOpts, reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "transmit", reportContext, report, rs, ss, rawVs) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) Transmit(reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.Transmit(&_FunctionsCoordinator.TransactOpts, reportContext, report, rs, ss, rawVs) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) Transmit(reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.Transmit(&_FunctionsCoordinator.TransactOpts, reportContext, report, rs, ss, rawVs) -} - -type FunctionsCoordinatorBillingEndIterator struct { - Event *FunctionsCoordinatorBillingEnd - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorBillingEndIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorBillingEnd) - 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(FunctionsCoordinatorBillingEnd) - 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 *FunctionsCoordinatorBillingEndIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorBillingEndIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorBillingEnd struct { - RequestId [32]byte - SubscriptionId uint64 - SignerPayment *big.Int - TransmitterPayment *big.Int - TotalCost *big.Int - Result uint8 - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingEndIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "BillingEnd", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorBillingEndIterator{contract: _FunctionsCoordinator.contract, event: "BillingEnd", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingEnd, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "BillingEnd", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorBillingEnd) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingEnd", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseBillingEnd(log types.Log) (*FunctionsCoordinatorBillingEnd, error) { - event := new(FunctionsCoordinatorBillingEnd) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingEnd", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorBillingStartIterator struct { - Event *FunctionsCoordinatorBillingStart - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorBillingStartIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorBillingStart) - 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(FunctionsCoordinatorBillingStart) - 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 *FunctionsCoordinatorBillingStartIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorBillingStartIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorBillingStart struct { - RequestId [32]byte - Commitment FunctionsBillingCommitment - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterBillingStart(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingStartIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "BillingStart", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorBillingStartIterator{contract: _FunctionsCoordinator.contract, event: "BillingStart", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchBillingStart(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingStart, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "BillingStart", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorBillingStart) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingStart", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseBillingStart(log types.Log) (*FunctionsCoordinatorBillingStart, error) { - event := new(FunctionsCoordinatorBillingStart) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "BillingStart", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorConfigSetIterator struct { - Event *FunctionsCoordinatorConfigSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigSet) - 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(FunctionsCoordinatorConfigSet) - 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 *FunctionsCoordinatorConfigSetIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorConfigSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorConfigSet struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadBeforeCallback uint32 - GasOverheadAfterCallback uint32 - FallbackNativePerUnitLink *big.Int - Fee *big.Int - MaxSupportedRequestDataVersion uint16 - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) { - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigSet") - if err != nil { - return nil, err - } - return &FunctionsCoordinatorConfigSetIterator{contract: _FunctionsCoordinator.contract, event: "ConfigSet", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigSet) (event.Subscription, error) { - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "ConfigSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigSet", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigSet(log types.Log) (*FunctionsCoordinatorConfigSet, error) { - event := new(FunctionsCoordinatorConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorCostExceedsCommitmentIterator struct { - Event *FunctionsCoordinatorCostExceedsCommitment - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorCostExceedsCommitmentIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorCostExceedsCommitment) - 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(FunctionsCoordinatorCostExceedsCommitment) - 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 *FunctionsCoordinatorCostExceedsCommitmentIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorCostExceedsCommitmentIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorCostExceedsCommitment struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterCostExceedsCommitment(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorCostExceedsCommitmentIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "CostExceedsCommitment", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorCostExceedsCommitmentIterator{contract: _FunctionsCoordinator.contract, event: "CostExceedsCommitment", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchCostExceedsCommitment(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCostExceedsCommitment, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "CostExceedsCommitment", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorCostExceedsCommitment) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "CostExceedsCommitment", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseCostExceedsCommitment(log types.Log) (*FunctionsCoordinatorCostExceedsCommitment, error) { - event := new(FunctionsCoordinatorCostExceedsCommitment) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "CostExceedsCommitment", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorInsufficientGasProvidedIterator struct { - Event *FunctionsCoordinatorInsufficientGasProvided - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorInsufficientGasProvidedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInsufficientGasProvided) - 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(FunctionsCoordinatorInsufficientGasProvided) - 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 *FunctionsCoordinatorInsufficientGasProvidedIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorInsufficientGasProvidedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorInsufficientGasProvided struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInsufficientGasProvided(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientGasProvidedIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InsufficientGasProvided", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorInsufficientGasProvidedIterator{contract: _FunctionsCoordinator.contract, event: "InsufficientGasProvided", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInsufficientGasProvided(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientGasProvided, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InsufficientGasProvided", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorInsufficientGasProvided) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientGasProvided", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInsufficientGasProvided(log types.Log) (*FunctionsCoordinatorInsufficientGasProvided, error) { - event := new(FunctionsCoordinatorInsufficientGasProvided) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InsufficientGasProvided", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorInvalidRequestIDIterator struct { - Event *FunctionsCoordinatorInvalidRequestID - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorInvalidRequestID) - 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(FunctionsCoordinatorInvalidRequestID) - 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 *FunctionsCoordinatorInvalidRequestIDIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorInvalidRequestIDIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorInvalidRequestID struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "InvalidRequestID", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorInvalidRequestIDIterator{contract: _FunctionsCoordinator.contract, event: "InvalidRequestID", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "InvalidRequestID", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorInvalidRequestID) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) { - event := new(FunctionsCoordinatorInvalidRequestID) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "InvalidRequestID", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorOCRConfigSetIterator struct { - Event *FunctionsCoordinatorOCRConfigSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorOCRConfigSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOCRConfigSet) - 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(FunctionsCoordinatorOCRConfigSet) - 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 *FunctionsCoordinatorOCRConfigSetIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorOCRConfigSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorOCRConfigSet struct { - PreviousConfigBlockNumber uint32 - ConfigDigest [32]byte - ConfigCount uint64 - Signers []common.Address - Transmitters []common.Address - F uint8 - OnchainConfig []byte - OffchainConfigVersion uint64 - OffchainConfig []byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterOCRConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorOCRConfigSetIterator, error) { - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "OCRConfigSet") - if err != nil { - return nil, err - } - return &FunctionsCoordinatorOCRConfigSetIterator{contract: _FunctionsCoordinator.contract, event: "OCRConfigSet", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOCRConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOCRConfigSet) (event.Subscription, error) { - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "OCRConfigSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorOCRConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OCRConfigSet", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOCRConfigSet(log types.Log) (*FunctionsCoordinatorOCRConfigSet, error) { - event := new(FunctionsCoordinatorOCRConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OCRConfigSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorOracleRequestIterator struct { - Event *FunctionsCoordinatorOracleRequest - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorOracleRequestIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOracleRequest) - 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(FunctionsCoordinatorOracleRequest) - 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 *FunctionsCoordinatorOracleRequestIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorOracleRequestIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorOracleRequest struct { - RequestId [32]byte - RequestingContract common.Address - RequestInitiator common.Address - SubscriptionId uint64 - SubscriptionOwner common.Address - Data []byte - DataVersion uint16 - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterOracleRequest(opts *bind.FilterOpts, requestId [][32]byte, requestingContract []common.Address) (*FunctionsCoordinatorOracleRequestIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - var requestingContractRule []interface{} - for _, requestingContractItem := range requestingContract { - requestingContractRule = append(requestingContractRule, requestingContractItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "OracleRequest", requestIdRule, requestingContractRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorOracleRequestIterator{contract: _FunctionsCoordinator.contract, event: "OracleRequest", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOracleRequest(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOracleRequest, requestId [][32]byte, requestingContract []common.Address) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - var requestingContractRule []interface{} - for _, requestingContractItem := range requestingContract { - requestingContractRule = append(requestingContractRule, requestingContractItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "OracleRequest", requestIdRule, requestingContractRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorOracleRequest) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OracleRequest", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOracleRequest(log types.Log) (*FunctionsCoordinatorOracleRequest, error) { - event := new(FunctionsCoordinatorOracleRequest) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OracleRequest", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorOracleResponseIterator struct { - Event *FunctionsCoordinatorOracleResponse - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorOracleResponseIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOracleResponse) - 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(FunctionsCoordinatorOracleResponse) - 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 *FunctionsCoordinatorOracleResponseIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorOracleResponseIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorOracleResponse struct { - RequestId [32]byte - Transmitter common.Address - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterOracleResponse(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorOracleResponseIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "OracleResponse", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorOracleResponseIterator{contract: _FunctionsCoordinator.contract, event: "OracleResponse", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOracleResponse(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOracleResponse, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "OracleResponse", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorOracleResponse) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OracleResponse", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOracleResponse(log types.Log) (*FunctionsCoordinatorOracleResponse, error) { - event := new(FunctionsCoordinatorOracleResponse) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OracleResponse", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorOwnershipTransferRequestedIterator struct { - Event *FunctionsCoordinatorOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOwnershipTransferRequested) - 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(FunctionsCoordinatorOwnershipTransferRequested) - 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 *FunctionsCoordinatorOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsCoordinatorOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorOwnershipTransferRequestedIterator{contract: _FunctionsCoordinator.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorOwnershipTransferRequested) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOwnershipTransferRequested(log types.Log) (*FunctionsCoordinatorOwnershipTransferRequested, error) { - event := new(FunctionsCoordinatorOwnershipTransferRequested) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorOwnershipTransferredIterator struct { - Event *FunctionsCoordinatorOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorOwnershipTransferred) - 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(FunctionsCoordinatorOwnershipTransferred) - 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 *FunctionsCoordinatorOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsCoordinatorOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorOwnershipTransferredIterator{contract: _FunctionsCoordinator.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorOwnershipTransferred) - if err := _FunctionsCoordinator.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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseOwnershipTransferred(log types.Log) (*FunctionsCoordinatorOwnershipTransferred, error) { - event := new(FunctionsCoordinatorOwnershipTransferred) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorRequestTimedOutIterator struct { - Event *FunctionsCoordinatorRequestTimedOut - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorRequestTimedOutIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorRequestTimedOut) - 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(FunctionsCoordinatorRequestTimedOut) - 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 *FunctionsCoordinatorRequestTimedOutIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorRequestTimedOutIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorRequestTimedOut struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorRequestTimedOutIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "RequestTimedOut", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsCoordinatorRequestTimedOutIterator{contract: _FunctionsCoordinator.contract, event: "RequestTimedOut", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorRequestTimedOut, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "RequestTimedOut", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorRequestTimedOut) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "RequestTimedOut", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseRequestTimedOut(log types.Log) (*FunctionsCoordinatorRequestTimedOut, error) { - event := new(FunctionsCoordinatorRequestTimedOut) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "RequestTimedOut", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsCoordinatorTransmittedIterator struct { - Event *FunctionsCoordinatorTransmitted - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsCoordinatorTransmittedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsCoordinatorTransmitted) - 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(FunctionsCoordinatorTransmitted) - 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 *FunctionsCoordinatorTransmittedIterator) Error() error { - return it.fail -} - -func (it *FunctionsCoordinatorTransmittedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsCoordinatorTransmitted struct { - ConfigDigest [32]byte - Epoch uint32 - Raw types.Log -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterTransmitted(opts *bind.FilterOpts) (*FunctionsCoordinatorTransmittedIterator, error) { - - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "Transmitted") - if err != nil { - return nil, err - } - return &FunctionsCoordinatorTransmittedIterator{contract: _FunctionsCoordinator.contract, event: "Transmitted", logs: logs, sub: sub}, nil -} - -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchTransmitted(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorTransmitted) (event.Subscription, error) { - - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "Transmitted") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsCoordinatorTransmitted) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "Transmitted", 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 (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseTransmitted(log types.Log) (*FunctionsCoordinatorTransmitted, error) { - event := new(FunctionsCoordinatorTransmitted) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "Transmitted", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type GetConfig struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadAfterCallback *big.Int - FallbackNativePerUnitLink *big.Int - GasOverheadBeforeCallback uint32 - LinkPriceFeed common.Address - MaxSupportedRequestDataVersion uint16 -} -type LatestConfigDetails struct { - ConfigCount uint32 - BlockNumber uint32 - ConfigDigest [32]byte -} -type LatestConfigDigestAndEpoch struct { - ScanLogs bool - ConfigDigest [32]byte - Epoch uint32 -} - -func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _FunctionsCoordinator.abi.Events["BillingEnd"].ID: - return _FunctionsCoordinator.ParseBillingEnd(log) - case _FunctionsCoordinator.abi.Events["BillingStart"].ID: - return _FunctionsCoordinator.ParseBillingStart(log) - case _FunctionsCoordinator.abi.Events["ConfigSet"].ID: - return _FunctionsCoordinator.ParseConfigSet(log) - case _FunctionsCoordinator.abi.Events["CostExceedsCommitment"].ID: - return _FunctionsCoordinator.ParseCostExceedsCommitment(log) - case _FunctionsCoordinator.abi.Events["InsufficientGasProvided"].ID: - return _FunctionsCoordinator.ParseInsufficientGasProvided(log) - case _FunctionsCoordinator.abi.Events["InvalidRequestID"].ID: - return _FunctionsCoordinator.ParseInvalidRequestID(log) - case _FunctionsCoordinator.abi.Events["OCRConfigSet"].ID: - return _FunctionsCoordinator.ParseOCRConfigSet(log) - case _FunctionsCoordinator.abi.Events["OracleRequest"].ID: - return _FunctionsCoordinator.ParseOracleRequest(log) - case _FunctionsCoordinator.abi.Events["OracleResponse"].ID: - return _FunctionsCoordinator.ParseOracleResponse(log) - case _FunctionsCoordinator.abi.Events["OwnershipTransferRequested"].ID: - return _FunctionsCoordinator.ParseOwnershipTransferRequested(log) - case _FunctionsCoordinator.abi.Events["OwnershipTransferred"].ID: - return _FunctionsCoordinator.ParseOwnershipTransferred(log) - case _FunctionsCoordinator.abi.Events["RequestTimedOut"].ID: - return _FunctionsCoordinator.ParseRequestTimedOut(log) - case _FunctionsCoordinator.abi.Events["Transmitted"].ID: - return _FunctionsCoordinator.ParseTransmitted(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (FunctionsCoordinatorBillingEnd) Topic() common.Hash { - return common.HexToHash("0x30e1e299f390e4f3fa75e4489fed477e86183937a4a21a0ae7b137a4dff03535") -} - -func (FunctionsCoordinatorBillingStart) Topic() common.Hash { - return common.HexToHash("0x9fadc54f9c9b79290fa97f2c9deb97ee080d1f8ae4f00deb1fb83cedd1ee5422") -} - -func (FunctionsCoordinatorConfigSet) Topic() common.Hash { - return common.HexToHash("0xd09395baf4d99e44ce1b8e96a4396a3f896d0fd5e4517993f28ce0a6fb42e227") -} - -func (FunctionsCoordinatorCostExceedsCommitment) Topic() common.Hash { - return common.HexToHash("0x689f49eacf6db85082542f4b7873f4a519744a4e093fd002310545bfb4354cc8") -} - -func (FunctionsCoordinatorInsufficientGasProvided) Topic() common.Hash { - return common.HexToHash("0x357a60574f143e144d62ddc89636fee45ba5e2f8c9a30b9f91e28f8dfe5a56e0") -} - -func (FunctionsCoordinatorInvalidRequestID) Topic() common.Hash { - return common.HexToHash("0xa1c120e327c9ad8b075793878c88d59b8934b97ae37117faa3bb21616237f7be") -} - -func (FunctionsCoordinatorOCRConfigSet) Topic() common.Hash { - return common.HexToHash("0x324b4d5fd31c5865202bc49f712eb9fcdf22bcc3b89f8c721f3134ae6c081a09") -} - -func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { - return common.HexToHash("0xb108b073fa485003d66284614f1c3b4feb3f47ffc88f7873bf3b2ec4bb8939bc") -} - -func (FunctionsCoordinatorOracleResponse) Topic() common.Hash { - return common.HexToHash("0xc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9") -} - -func (FunctionsCoordinatorOwnershipTransferRequested) Topic() common.Hash { - return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") -} - -func (FunctionsCoordinatorOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") -} - -func (FunctionsCoordinatorRequestTimedOut) Topic() common.Hash { - return common.HexToHash("0xf1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af414") -} - -func (FunctionsCoordinatorTransmitted) Topic() common.Hash { - return common.HexToHash("0xb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62") -} - -func (_FunctionsCoordinator *FunctionsCoordinator) Address() common.Address { - return _FunctionsCoordinator.address -} - -type FunctionsCoordinatorInterface interface { - EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) - - GetAdminFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) - - GetAllNodePublicKeys(opts *bind.CallOpts) ([]common.Address, [][]byte, error) - - GetConfig(opts *bind.CallOpts) (GetConfig, - - error) - - GetConfigHash(opts *bind.CallOpts) ([32]byte, error) - - GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) - - GetDONPublicKey(opts *bind.CallOpts) ([]byte, error) - - GetFeedData(opts *bind.CallOpts) (*big.Int, error) - - GetThresholdPublicKey(opts *bind.CallOpts) ([]byte, error) - - LatestConfigDetails(opts *bind.CallOpts) (LatestConfigDetails, - - error) - - LatestConfigDigestAndEpoch(opts *bind.CallOpts) (LatestConfigDigestAndEpoch, - - error) - - Owner(opts *bind.CallOpts) (common.Address, error) - - Transmitters(opts *bind.CallOpts) ([]common.Address, error) - - TypeAndVersion(opts *bind.CallOpts) (string, error) - - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - - DeleteCommitment(opts *bind.TransactOpts, requestId [32]byte) (*types.Transaction, error) - - DeleteNodePublicKey(opts *bind.TransactOpts, node common.Address) (*types.Transaction, error) - - OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) - - SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) - - SetConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) - - SetConfig0(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) - - SetDONPublicKey(opts *bind.TransactOpts, donPublicKey []byte) (*types.Transaction, error) - - SetNodePublicKey(opts *bind.TransactOpts, node common.Address, publicKey []byte) (*types.Transaction, error) - - SetThresholdPublicKey(opts *bind.TransactOpts, thresholdPublicKey []byte) (*types.Transaction, error) - - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - Transmit(opts *bind.TransactOpts, reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) - - FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingEndIterator, error) - - WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingEnd, requestId [][32]byte) (event.Subscription, error) - - ParseBillingEnd(log types.Log) (*FunctionsCoordinatorBillingEnd, error) - - FilterBillingStart(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorBillingStartIterator, error) - - WatchBillingStart(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorBillingStart, requestId [][32]byte) (event.Subscription, error) - - ParseBillingStart(log types.Log) (*FunctionsCoordinatorBillingStart, error) - - FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) - - WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigSet) (event.Subscription, error) - - ParseConfigSet(log types.Log) (*FunctionsCoordinatorConfigSet, error) - - FilterCostExceedsCommitment(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorCostExceedsCommitmentIterator, error) - - WatchCostExceedsCommitment(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorCostExceedsCommitment, requestId [][32]byte) (event.Subscription, error) - - ParseCostExceedsCommitment(log types.Log) (*FunctionsCoordinatorCostExceedsCommitment, error) - - FilterInsufficientGasProvided(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInsufficientGasProvidedIterator, error) - - WatchInsufficientGasProvided(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInsufficientGasProvided, requestId [][32]byte) (event.Subscription, error) - - ParseInsufficientGasProvided(log types.Log) (*FunctionsCoordinatorInsufficientGasProvided, error) - - FilterInvalidRequestID(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorInvalidRequestIDIterator, error) - - WatchInvalidRequestID(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorInvalidRequestID, requestId [][32]byte) (event.Subscription, error) - - ParseInvalidRequestID(log types.Log) (*FunctionsCoordinatorInvalidRequestID, error) - - FilterOCRConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorOCRConfigSetIterator, error) - - WatchOCRConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOCRConfigSet) (event.Subscription, error) - - ParseOCRConfigSet(log types.Log) (*FunctionsCoordinatorOCRConfigSet, error) - - FilterOracleRequest(opts *bind.FilterOpts, requestId [][32]byte, requestingContract []common.Address) (*FunctionsCoordinatorOracleRequestIterator, error) - - WatchOracleRequest(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOracleRequest, requestId [][32]byte, requestingContract []common.Address) (event.Subscription, error) - - ParseOracleRequest(log types.Log) (*FunctionsCoordinatorOracleRequest, error) - - FilterOracleResponse(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorOracleResponseIterator, error) - - WatchOracleResponse(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOracleResponse, requestId [][32]byte) (event.Subscription, error) - - ParseOracleResponse(log types.Log) (*FunctionsCoordinatorOracleResponse, error) - - FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsCoordinatorOwnershipTransferRequestedIterator, error) - - WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferRequested(log types.Log) (*FunctionsCoordinatorOwnershipTransferRequested, error) - - FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsCoordinatorOwnershipTransferredIterator, error) - - WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferred(log types.Log) (*FunctionsCoordinatorOwnershipTransferred, error) - - FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsCoordinatorRequestTimedOutIterator, error) - - WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorRequestTimedOut, requestId [][32]byte) (event.Subscription, error) - - ParseRequestTimedOut(log types.Log) (*FunctionsCoordinatorRequestTimedOut, error) - - FilterTransmitted(opts *bind.FilterOpts) (*FunctionsCoordinatorTransmittedIterator, error) - - WatchTransmitted(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorTransmitted) (event.Subscription, error) - - ParseTransmitted(log types.Log) (*FunctionsCoordinatorTransmitted, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/functions_registry/functions_registry.go b/core/gethwrappers/generated/functions_registry/functions_registry.go deleted file mode 100644 index cb8c5ce2ca5..00000000000 --- a/core/gethwrappers/generated/functions_registry/functions_registry.go +++ /dev/null @@ -1,3350 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package functions_registry - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -type FunctionsBillingRegistryCommitment struct { - SubscriptionId uint64 - Client common.Address - GasLimit uint32 - GasPrice *big.Int - Don common.Address - DonFee *big.Int - RegistryFee *big.Int - EstimatedCost *big.Int - Timestamp *big.Int -} - -type IFunctionsBillingRegistryRequestBilling struct { - SubscriptionId uint64 - Client common.Address - GasLimit uint32 - GasPrice *big.Int -} - -var FunctionsRegistryMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotSelfTransfer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySendersList\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAllowedToSetSenders\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OwnerMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"senders\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"changedBy\",\"type\":\"address\"}],\"name\":\"AuthorizedSendersChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"signerPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"transmitterPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCost\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"BillingEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"don\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"registryFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"estimatedCost\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"timestamp\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBillingRegistry.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"BillingStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverhead\",\"type\":\"uint32\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"name\":\"Initialized\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"donFee\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"registryFee\",\"type\":\"uint96\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address[31]\",\"name\":\"signers\",\"type\":\"address[31]\"},{\"internalType\":\"uint8\",\"name\":\"signerCount\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"reportValidationGas\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"initialGas\",\"type\":\"uint256\"}],\"name\":\"fulfillAndBill\",\"outputs\":[{\"internalType\":\"enumIFunctionsBillingRegistry.FulfillResult\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAuthorizedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverhead\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCurrentsubscriptionId\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBillingRegistry.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getRequiredFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscriptionOwner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"initialize\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isAuthorizedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"senders\",\"type\":\"address[]\"}],\"name\":\"setAuthorizedSenders\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"uint32\",\"name\":\"gasOverhead\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"internalType\":\"structIFunctionsBillingRegistry.RequestBilling\",\"name\":\"billing\",\"type\":\"tuple\"}],\"name\":\"startBilling\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60806040523480156200001157600080fd5b5060405162005d3838038062005d3883398101604081905262000034916200040c565b620000418383836200004a565b50505062000456565b600054610100900460ff16158080156200006b5750600054600160ff909116105b806200009b57506200008830620001c960201b62003bd41760201c565b1580156200009b575060005460ff166001145b620001045760405162461bcd60e51b815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201526d191e481a5b9a5d1a585b1a5e995960921b60648201526084015b60405180910390fd5b6000805460ff19166001179055801562000128576000805461ff0019166101001790555b62000132620001d8565b6200013f33600062000240565b606980546001600160a01b038087166001600160a01b031992831617909255606a8054868416908316179055606b8054928516929091169190911790558015620001c3576000805461ff0019169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb38474024989060200160405180910390a15b50505050565b6001600160a01b03163b151590565b600054610100900460ff16620002345760405162461bcd60e51b815260206004820152602b602482015260008051602062005d1883398151915260448201526a6e697469616c697a696e6760a81b6064820152608401620000fb565b6200023e62000304565b565b600054610100900460ff166200029c5760405162461bcd60e51b815260206004820152602b602482015260008051602062005d1883398151915260448201526a6e697469616c697a696e6760a81b6064820152608401620000fb565b6001600160a01b038216620002c457604051635b5a8afd60e11b815260040160405180910390fd5b600080546001600160a01b03808516620100000262010000600160b01b031990921691909117909155811615620003005762000300816200036c565b5050565b600054610100900460ff16620003605760405162461bcd60e51b815260206004820152602b602482015260008051602062005d1883398151915260448201526a6e697469616c697a696e6760a81b6064820152608401620000fb565b6034805460ff19169055565b6001600160a01b038116331415620003975760405163282010c360e01b815260040160405180910390fd5b600180546001600160a01b0319166001600160a01b038381169182179092556000805460405192936201000090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200040757600080fd5b919050565b6000806000606084860312156200042257600080fd5b6200042d84620003ef565b92506200043d60208501620003ef565b91506200044d60408501620003ef565b90509250925092565b6158b280620004666000396000f3fe608060405234801561001057600080fd5b50600436106102255760003560e01c80638da5cb5b1161012a578063c0c53b8b116100bd578063e82ad7d41161008c578063f1e14a2111610071578063f1e14a2114610561578063f2fde38b14610578578063fa00763a1461058b57600080fd5b8063e82ad7d41461053b578063ee56997b1461054e57600080fd5b8063c0c53b8b1461048d578063c3f909d4146104a0578063d7ae1d3014610515578063e72f6e301461052857600080fd5b8063a47c7696116100f9578063a47c769614610432578063a4c0ed3614610454578063a9d03c0514610467578063b2a489ff1461047a57600080fd5b80638da5cb5b146103a25780639f87fad7146103e7578063a1a6d041146103fa578063a21a23e41461042a57600080fd5b80633f4ba83a116101bd578063665871ec1161018c57806379ba50971161017157806379ba50971461037f57806382359740146103875780638456cb591461039a57600080fd5b8063665871ec146103595780637341c10c1461036c57600080fd5b80633f4ba83a1461030c5780635c975abb1461031457806364d51a2a1461032b57806366316d8d1461034657600080fd5b806312b58349116101f957806312b58349146102915780632408afaa146102bd57806327923e41146102d257806333652e3e146102e557600080fd5b80620122911461022a57806302bcc5b61461024957806304c357cb1461025e5780630739e4f114610271575b600080fd5b61023261059e565b6040516102409291906155a1565b60405180910390f35b61025c6102573660046151d9565b6105bd565b005b61025c61026c3660046151f4565b61063a565b61028461027f366004614edf565b610835565b6040516102409190615470565b606f546801000000000000000090046bffffffffffffffffffffffff165b604051908152602001610240565b6102c5610ef7565b60405161024091906153a6565b61025c6102e0366004615173565b610f66565b606f5467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610240565b61025c6110b9565b60345460ff165b6040519015158152602001610240565b610333606481565b60405161ffff9091168152602001610240565b61025c610354366004614e44565b6110cb565b61025c610367366004614e7b565b611331565b61025c61037a3660046151f4565b6115fd565b61025c611890565b61025c6103953660046151d9565b611983565b61025c611d04565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610240565b61025c6103f53660046151f4565b611d14565b61040d610408366004615122565b61219b565b6040516bffffffffffffffffffffffff9091168152602001610240565b6102f36122bf565b6104456104403660046151d9565b612657565b604051610240939291906155c8565b61025c610462366004614dea565b612788565b6102af610475366004615009565b6129e1565b6103c26104883660046151d9565b6131dc565b61025c61049b366004614da7565b613275565b607354607454607254607554606954606a546040805163ffffffff808916825265010000000000909804881660208201529081019590955260608501939093529316608083015273ffffffffffffffffffffffffffffffffffffffff92831660a08301529190911660c082015260e001610240565b61025c6105233660046151f4565b613477565b61025c610536366004614d8c565b6135de565b61031b6105493660046151d9565b6137fb565b61025c61055c366004614e7b565b613a3a565b61040d61056f366004615086565b60009392505050565b61025c610586366004614d8c565b613bad565b61031b610599366004614d8c565b613bc1565b60735460009060609063ffffffff166105b5610ef7565b915091509091565b6105c5613bf0565b67ffffffffffffffff81166000908152606d602052604090205473ffffffffffffffffffffffffffffffffffffffff168061062c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106368282613c47565b5050565b67ffffffffffffffff82166000908152606d6020526040902054829073ffffffffffffffffffffffffffffffffffffffff16806106a3576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461070f576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024015b60405180910390fd5b607354640100000000900460ff1615610754576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61075c61404e565b67ffffffffffffffff84166000908152606d602052604090206001015473ffffffffffffffffffffffffffffffffffffffff84811691161461082f5767ffffffffffffffff84166000818152606d602090815260409182902060010180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff88169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b50505050565b600061083f6140bb565b607354640100000000900460ff1615610884576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61088c61404e565b60008b815260716020908152604091829020825161012081018452815467ffffffffffffffff8116825268010000000000000000810473ffffffffffffffffffffffffffffffffffffffff908116948301949094527c0100000000000000000000000000000000000000000000000000000000900463ffffffff169381019390935260018101546060840152600281015491821660808401819052740100000000000000000000000000000000000000009092046bffffffffffffffffffffffff90811660a0850152600382015480821660c08601526c0100000000000000000000000090041660e084015260040154610100830152610990576002915050610ee9565b60008c81526071602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff000000000000000000000000000000000000000000000000169055600401829055517f0ca761750000000000000000000000000000000000000000000000000000000090610a19908f908f908f908f908f906024016153b9565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090951694909417909352607380547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff1664010000000017905584015191840151909250600091610ae69163ffffffff90911690846140fa565b607380547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00ffffffff16905560745460a085015160c0860151929350600092610b3292899290918c908c3a614146565b604080820151865167ffffffffffffffff166000908152606e60205291909120549192506bffffffffffffffffffffffff90811691161015610ba0576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604080820151855167ffffffffffffffff166000908152606e602052918220805491929091610bde9084906bffffffffffffffffffffffff16615712565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060005b8860ff16811015610cd8578151607060008c84601f8110610c3257610c3261582d565b602002015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16610c979190615658565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508080610cd09061573f565b915050610c0f565b508360c0015160706000610d0860005473ffffffffffffffffffffffffffffffffffffffff620100009091041690565b73ffffffffffffffffffffffffffffffffffffffff168152602081019190915260400160009081208054909190610d4e9084906bffffffffffffffffffffffff16615658565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560208381015173ffffffffffffffffffffffffffffffffffffffff8e166000908152607090925260408220805491945092610db091859116615658565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560e0860151865167ffffffffffffffff166000908152606e60205260409020805491935091600c91610e199185916c01000000000000000000000000900416615712565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508e7fc8dc973332de19a5f71b6026983110e9c2e04b0c98b87eb771ccb78607fd114f856000015183600001518460200151856040015187604051610ecb95949392919067ffffffffffffffff9590951685526bffffffffffffffffffffffff9384166020860152918316604085015290911660608301521515608082015260a00190565b60405180910390a281610edf576001610ee2565b60005b9450505050505b9a9950505050505050505050565b60606068805480602002602001604051908101604052809291908181526020018280548015610f5c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610f31575b5050505050905090565b610f6e613bf0565b60008313610fab576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101849052602401610706565b6040805160c08101825263ffffffff888116808352600060208085019190915289831684860181905260608086018b9052888516608080880182905295891660a0978801819052607380547fffffffffffffffffffffffffffffffffffffffffffffff00000000000000000016871765010000000000860217905560748d9055607580547fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000016831764010000000090920291909117905560728b9055875194855292840191909152948201899052938101879052908101929092527f24d3d934adfef9b9029d6ffa463c07d0139ed47d26ee23506f85ece2879d2bd4910160405180910390a1505050505050565b6110c1613bf0565b6110c96142c6565b565b607354640100000000900460ff1615611110576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61111861404e565b6bffffffffffffffffffffffff811661114b5750336000908152607060205260409020546bffffffffffffffffffffffff165b336000908152607060205260409020546bffffffffffffffffffffffff808316911610156111a5576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260706020526040812080548392906111d29084906bffffffffffffffffffffffff16615712565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080606f60088282829054906101000a90046bffffffffffffffffffffffff166112299190615712565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556069546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b1580156112c357600080fd5b505af11580156112d7573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112fb9190614ebd565b610636576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61133961404e565b60005b818110156115f85760008383838181106113585761135861582d565b602090810292909201356000818152607184526040808220815161012081018352815467ffffffffffffffff811680835268010000000000000000820473ffffffffffffffffffffffffffffffffffffffff908116848b01527c010000000000000000000000000000000000000000000000000000000090920463ffffffff168386015260018401546060840152600284015480831660808501527401000000000000000000000000000000000000000090046bffffffffffffffffffffffff90811660a0850152600385015480821660c08601526c0100000000000000000000000090041660e0840152600490930154610100830152918452606d90965291205491945016331490506114cd57805167ffffffffffffffff166000908152606d6020526040908190205490517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602401610706565b60755461010082015142916114f19164010000000090910463ffffffff1690615614565b11156115e35760e0810151815167ffffffffffffffff166000908152606e602052604090208054600c906115449084906c0100000000000000000000000090046bffffffffffffffffffffffff16615712565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060008281526071602052604080822082815560018101839055600281018390556003810180547fffffffffffffffff0000000000000000000000000000000000000000000000001690556004018290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25b505080806115f09061573f565b91505061133c565b505050565b67ffffffffffffffff82166000908152606d6020526040902054829073ffffffffffffffffffffffffffffffffffffffff1680611666576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff8216146116cd576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610706565b607354640100000000900460ff1615611712576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61171a61404e565b67ffffffffffffffff84166000908152606d602052604090206002015460641415611771576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152606c6020908152604080832067ffffffffffffffff808916855292529091205416156117b85761082f565b73ffffffffffffffffffffffffffffffffffffffff83166000818152606c6020908152604080832067ffffffffffffffff891680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000166001908117909155606d84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610826565b60015473ffffffffffffffffffffffffffffffffffffffff1633146118e1576040517f0f22ca5f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805433620100008181027fffffffffffffffffffff0000000000000000000000000000000000000000ffff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b607354640100000000900460ff16156119c8576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119d061404e565b606b60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634b4fa0c16040518163ffffffff1660e01b815260040160206040518083038186803b158015611a3857600080fd5b505afa158015611a4c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611a709190614ebd565b8015611b1a5750606b546040517ffa00763a00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff9091169063fa00763a9060240160206040518083038186803b158015611ae057600080fd5b505afa158015611af4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611b189190614ebd565b155b15611b51576040517f0809490800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152606d602052604090205473ffffffffffffffffffffffffffffffffffffffff16611bb7576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152606d602052604090206001015473ffffffffffffffffffffffffffffffffffffffff163314611c595767ffffffffffffffff81166000908152606d6020526040908190206001015490517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602401610706565b67ffffffffffffffff81166000818152606d60209081526040918290208054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560019093018054909316909255835173ffffffffffffffffffffffffffffffffffffffff909116808252928101919091529092917f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a25050565b611d0c613bf0565b6110c9614343565b67ffffffffffffffff82166000908152606d6020526040902054829073ffffffffffffffffffffffffffffffffffffffff1680611d7d576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611de4576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610706565b607354640100000000900460ff1615611e29576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611e3161404e565b73ffffffffffffffffffffffffffffffffffffffff83166000908152606c6020908152604080832067ffffffffffffffff808916855292529091205416611ecc576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8516600482015273ffffffffffffffffffffffffffffffffffffffff84166024820152604401610706565b67ffffffffffffffff84166000908152606d6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f4757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611f1c575b50505050509050600060018251611f5e91906156fb565b905060005b82518110156120fd578573ffffffffffffffffffffffffffffffffffffffff16838281518110611f9557611f9561582d565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156120eb576000838381518110611fcd57611fcd61582d565b6020026020010151905080606d60008a67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060020183815481106120135761201361582d565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff8a168152606d9091526040902060020180548061208d5761208d6157fe565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120fd565b806120f58161573f565b915050611f63565b5073ffffffffffffffffffffffffffffffffffffffff85166000818152606c6020908152604080832067ffffffffffffffff8b168085529083529281902080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a2505050505050565b6000806121a661439e565b9050600081136121e5576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610706565b60745460755460009163ffffffff808a1692612202929116615614565b61220c9190615614565b90506000828261222489670de0b6b3a76400006156be565b61222e91906156be565b612238919061567f565b905060006122576bffffffffffffffffffffffff808816908916615614565b905061226f816b033b2e3c9fd0803ce80000006156fb565b8211156122a8576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6122b28183615614565b9998505050505050505050565b607354600090640100000000900460ff1615612307576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61230f61404e565b606b60009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16634b4fa0c16040518163ffffffff1660e01b815260040160206040518083038186803b15801561237757600080fd5b505afa15801561238b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123af9190614ebd565b80156124595750606b546040517ffa00763a00000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff9091169063fa00763a9060240160206040518083038186803b15801561241f57600080fd5b505afa158015612433573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124579190614ebd565b155b15612490576040517f0809490800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606f805467ffffffffffffffff169060006124aa83615778565b82546101009290920a67ffffffffffffffff818102199093169183160217909155606f541690506000806040519080825280602002602001820160405280156124fd578160200160208202803683370190505b506040805180820182526000808252602080830182815267ffffffffffffffff8816808452606e83528584209451855492516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff000000000000000000000000000000000000000000000000909416911617919091179093558351606081018552338152808201838152818601878152948452606d8352949092208251815473ffffffffffffffffffffffffffffffffffffffff9182167fffffffffffffffffffffffff000000000000000000000000000000000000000091821617835595516001830180549190921696169590951790945591518051949550909361260f9260028501920190614ad8565b505060405133815267ffffffffffffffff841691507f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a250905090565b67ffffffffffffffff81166000908152606d6020526040812054819060609073ffffffffffffffffffffffffffffffffffffffff166126c2576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff84166000908152606e6020908152604080832054606d8352928190208054600290910180548351818602810186019094528084526bffffffffffffffffffffffff9095169473ffffffffffffffffffffffffffffffffffffffff90921693909291839183018282801561277457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612749575b505050505090509250925092509193909250565b607354640100000000900460ff16156127cd576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6127d561404e565b60695473ffffffffffffffffffffffffffffffffffffffff163314612826576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612860576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061286e828401846151d9565b67ffffffffffffffff81166000908152606d602052604090205490915073ffffffffffffffffffffffffffffffffffffffff166128d7576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152606e6020526040812080546bffffffffffffffffffffffff169186919061290e8385615658565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084606f60088282829054906101000a90046bffffffffffffffffffffffff166129659190615658565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846129cc9190615614565b6040805192835260208301919091520161218b565b60006129eb6140bb565b607354640100000000900460ff1615612a30576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612a3861404e565b6000606d81612a4a60208601866151d9565b67ffffffffffffffff16815260208101919091526040016000205473ffffffffffffffffffffffffffffffffffffffff161415612ab3576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000606c81612ac86040860160208701614d8c565b73ffffffffffffffffffffffffffffffffffffffff168152602080820192909252604001600090812091612afe908601866151d9565b67ffffffffffffffff908116825260208201929092526040016000205416905080612b9a57612b3060208401846151d9565b612b406040850160208601614d8c565b6040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909216600483015273ffffffffffffffffffffffffffffffffffffffff166024820152604401610706565b60735463ffffffff16612bb36060850160408601615107565b63ffffffff161115612c1457612bcf6060840160408501615107565b6073546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff928316600482015291166024820152604401610706565b6040517ff1e14a21000000000000000000000000000000000000000000000000000000008152600090339063f1e14a2190612c57908990899089906004016153f2565b60206040518083038186803b158015612c6f57600080fd5b505afa158015612c83573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ca79190615277565b90506000612cbf878761056f368990038901896150d2565b90506000612ce2612cd66060880160408901615107565b8760600135858561219b565b90506000606e81612cf660208a018a6151d9565b67ffffffffffffffff1681526020808201929092526040016000908120546c0100000000000000000000000090046bffffffffffffffffffffffff1691606e9190612d43908b018b6151d9565b67ffffffffffffffff168152602081019190915260400160002054612d7691906bffffffffffffffffffffffff16615712565b9050816bffffffffffffffffffffffff16816bffffffffffffffffffffffff161015612dce576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612ddb86600161562c565b90506000612e6333612df360408c0160208d01614d8c565b612e0060208d018d6151d9565b856040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b60408051610120810190915290915060009080612e8360208d018d6151d9565b67ffffffffffffffff1681526020018b6020016020810190612ea59190614d8c565b73ffffffffffffffffffffffffffffffffffffffff168152602001612ed060608d0160408e01615107565b63ffffffff90811682526060808e0135602080850191909152336040808601919091526bffffffffffffffffffffffff808e16848701528c81166080808801919091528c821660a0808901919091524260c09889015260008b8152607186528481208a5181548c890151978d0151909a167c0100000000000000000000000000000000000000000000000000000000027bffffffffffffffffffffffffffffffffffffffffffffffffffffffff73ffffffffffffffffffffffffffffffffffffffff98891668010000000000000000027fffffffff00000000000000000000000000000000000000000000000000000000909c1667ffffffffffffffff909316929092179a909a171698909817885595890151600188015590880151908801518216740100000000000000000000000000000000000000000292169190911760028501559385015160038401805460e088015187166c01000000000000000000000000027fffffffffffffffff0000000000000000000000000000000000000000000000009091169290961691909117949094179093556101008401516004909201919091559192508691606e9161308a908e018e6151d9565b67ffffffffffffffff16815260208101919091526040016000208054600c906130d29084906c0100000000000000000000000090046bffffffffffffffffffffffff16615658565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550817f99f7f4e65b4b9fbabd4e357c47ed3099b36e57ecd3a43e84662f34c207d0ebe48260405161313091906154b1565b60405180910390a282606c600061314d60408e0160208f01614d8c565b73ffffffffffffffffffffffffffffffffffffffff168152602080820192909252604001600090812091613183908e018e6151d9565b67ffffffffffffffff9081168252602082019290925260400160002080547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001692909116919091179055509a9950505050505050505050565b67ffffffffffffffff81166000908152606d602052604081205473ffffffffffffffffffffffffffffffffffffffff16613242576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5067ffffffffffffffff166000908152606d602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b600054610100900460ff16158080156132955750600054600160ff909116105b806132af5750303b1580156132af575060005460ff166001145b61333b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602e60248201527f496e697469616c697a61626c653a20636f6e747261637420697320616c72656160448201527f647920696e697469616c697a65640000000000000000000000000000000000006064820152608401610706565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055801561339957600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555b6133a1614491565b6133ac336000614530565b6069805473ffffffffffffffffffffffffffffffffffffffff8087167fffffffffffffffffffffffff000000000000000000000000000000000000000092831617909255606a8054868416908316179055606b805492851692909116919091179055801561082f57600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff169055604051600181527f7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498906020015b60405180910390a150505050565b67ffffffffffffffff82166000908152606d6020526040902054829073ffffffffffffffffffffffffffffffffffffffff16806134e0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614613547576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610706565b607354640100000000900460ff161561358c576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61359461404e565b61359d846137fb565b156135d4576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61082f8484613c47565b6135e6613bf0565b6069546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a082319060240160206040518083038186803b15801561365057600080fd5b505afa158015613664573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061368891906150ee565b606f549091506801000000000000000090046bffffffffffffffffffffffff16818111156136ec576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610706565b818110156115f857600061370082846156fb565b6069546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561377657600080fd5b505af115801561378a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137ae9190614ebd565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b4366009101613469565b67ffffffffffffffff81166000908152606d602090815260408083206002018054825181850281018501909352808352849383018282801561387357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613848575b505050505090506000613884610ef7565b905060005b8251811015613a2f5760005b8251811015613a1c5760006139cc8483815181106138b5576138b561582d565b60200260200101518685815181106138cf576138cf61582d565b602002602001015189606c60008a89815181106138ee576138ee61582d565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008c67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060009054906101000a900467ffffffffffffffff166040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b60008181526071602052604090206002015490915073ffffffffffffffffffffffffffffffffffffffff1615613a09575060019695505050505050565b5080613a148161573f565b915050613895565b5080613a278161573f565b915050613889565b506000949350505050565b613a42614670565b613a78576040517fad77f06100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80613aaf576040517f75158c3b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b606854811015613b0f57613afc60688281548110613ad257613ad261582d565b60009182526020909120015460669073ffffffffffffffffffffffffffffffffffffffff16614680565b5080613b078161573f565b915050613ab2565b5060005b81811015613b6057613b4d838383818110613b3057613b3061582d565b9050602002016020810190613b459190614d8c565b6066906146a9565b5080613b588161573f565b915050613b13565b50613b6d60688383614b5e565b507ff263cfb3e4298332e776194610cf9fdc09ccb3ada8b9aa39764d882e11fbf0a0828233604051613ba19392919061532e565b60405180910390a15050565b613bb5613bf0565b613bbe816146cb565b50565b6000613bce606683614798565b92915050565b73ffffffffffffffffffffffffffffffffffffffff163b151590565b60005462010000900473ffffffffffffffffffffffffffffffffffffffff1633146110c9576040517f2b5c74de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b607354640100000000900460ff1615613c8c576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152606d602090815260408083208151606081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301541681850152600282018054845181870281018701865281815292959394860193830182828015613d3757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613d0c575b5050509190925250505067ffffffffffffffff84166000908152606e60205260408120549192506bffffffffffffffffffffffff909116905b826040015151811015613e1657606c600084604001518381518110613d9757613d9761582d565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000016905580613e0e8161573f565b915050613d70565b5067ffffffffffffffff84166000908152606d6020526040812080547fffffffffffffffffffffffff00000000000000000000000000000000000000009081168255600182018054909116905590613e716002830182614bd6565b505067ffffffffffffffff84166000908152606e6020526040902080547fffffffffffffffff000000000000000000000000000000000000000000000000169055606f8054829190600890613ee19084906801000000000000000090046bffffffffffffffffffffffff16615712565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556069546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015613f7b57600080fd5b505af1158015613f8f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613fb39190614ebd565b613fe9576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101610826565b60345460ff16156110c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610706565b6140c433613bc1565b6110c9576040517f0809490800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005a61138881101561410c57600080fd5b61138881039050846040820482031161412457600080fd5b50823b61413057600080fd5b60008083516020850160008789f1949350505050565b604080516060810182526000808252602082018190529181018290529061416b61439e565b9050600081136141aa576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610706565b6000815a8b6141b98c89615614565b6141c39190615614565b6141cd91906156fb565b6141df86670de0b6b3a76400006156be565b6141e991906156be565b6141f3919061567f565b905060006142126bffffffffffffffffffffffff808916908b16615614565b905061422a816b033b2e3c9fd0803ce80000006156fb565b821115614263576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061427260ff8a168b615693565b90508260006142896142848584615614565b6147c7565b604080516060810182526bffffffffffffffffffffffff958616815293851660208501529316928201929092529c9b505050505050505050505050565b6142ce614869565b603480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b61434b61404e565b603480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586143193390565b607354606a54604080517ffeaf968c000000000000000000000000000000000000000000000000000000008152905160009365010000000000900463ffffffff1692831515928592839273ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a0929190829003018186803b15801561442457600080fd5b505afa158015614438573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061445c9190615227565b5093505092505082801561447e575061447581426156fb565b8463ffffffff16105b156144895760725491505b509392505050565b600054610100900460ff16614528576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610706565b6110c96148d5565b600054610100900460ff166145c7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610706565b73ffffffffffffffffffffffffffffffffffffffff8216614614576040517fb6b515fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805473ffffffffffffffffffffffffffffffffffffffff80851662010000027fffffffffffffffffffff0000000000000000000000000000000000000000ffff9092169190911790915581161561063657610636816146cb565b600061467a613bf0565b50600190565b60006146a28373ffffffffffffffffffffffffffffffffffffffff8416614996565b9392505050565b60006146a28373ffffffffffffffffffffffffffffffffffffffff8416614a89565b73ffffffffffffffffffffffffffffffffffffffff811633141561471b576040517f282010c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff8381169182179092556000805460405192936201000090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415156146a2565b60006bffffffffffffffffffffffff821115614865576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610706565b5090565b60345460ff166110c9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610706565b600054610100900460ff1661496c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602b60248201527f496e697469616c697a61626c653a20636f6e7472616374206973206e6f74206960448201527f6e697469616c697a696e670000000000000000000000000000000000000000006064820152608401610706565b603480547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60008181526001830160205260408120548015614a7f5760006149ba6001836156fb565b85549091506000906149ce906001906156fb565b9050818114614a335760008660000182815481106149ee576149ee61582d565b9060005260206000200154905080876000018481548110614a1157614a1161582d565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080614a4457614a446157fe565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050613bce565b6000915050613bce565b6000818152600183016020526040812054614ad057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155613bce565b506000613bce565b828054828255906000526020600020908101928215614b52579160200282015b82811115614b5257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614af8565b50614865929150614bf0565b828054828255906000526020600020908101928215614b52579160200282015b82811115614b525781547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff843516178255602090920191600190910190614b7e565b5080546000825590600052602060002090810190613bbe91905b5b808211156148655760008155600101614bf1565b803573ffffffffffffffffffffffffffffffffffffffff81168114614c2957600080fd5b919050565b60008083601f840112614c4057600080fd5b50813567ffffffffffffffff811115614c5857600080fd5b6020830191508360208260051b8501011115614c7357600080fd5b9250929050565b60008083601f840112614c8c57600080fd5b50813567ffffffffffffffff811115614ca457600080fd5b602083019150836020828501011115614c7357600080fd5b600060808284031215614cce57600080fd5b6040516080810181811067ffffffffffffffff82111715614cf157614cf161585c565b604052905080614d0083614d49565b8152614d0e60208401614c05565b6020820152614d1f60408401614d35565b6040820152606083013560608201525092915050565b803563ffffffff81168114614c2957600080fd5b803567ffffffffffffffff81168114614c2957600080fd5b803560ff81168114614c2957600080fd5b805169ffffffffffffffffffff81168114614c2957600080fd5b600060208284031215614d9e57600080fd5b6146a282614c05565b600080600060608486031215614dbc57600080fd5b614dc584614c05565b9250614dd360208501614c05565b9150614de160408501614c05565b90509250925092565b60008060008060608587031215614e0057600080fd5b614e0985614c05565b935060208501359250604085013567ffffffffffffffff811115614e2c57600080fd5b614e3887828801614c7a565b95989497509550505050565b60008060408385031215614e5757600080fd5b614e6083614c05565b91506020830135614e708161588b565b809150509250929050565b60008060208385031215614e8e57600080fd5b823567ffffffffffffffff811115614ea557600080fd5b614eb185828601614c2e565b90969095509350505050565b600060208284031215614ecf57600080fd5b815180151581146146a257600080fd5b6000806000806000806000806000806104c08b8d031215614eff57600080fd5b8a35995060208b013567ffffffffffffffff80821115614f1e57600080fd5b614f2a8e838f01614c7a565b909b50995060408d0135915080821115614f4357600080fd5b614f4f8e838f01614c7a565b9099509750879150614f6360608e01614c05565b96508d609f8e0112614f7457600080fd5b60405191506103e082018281108282111715614f9257614f9261585c565b604052508060808d016104608e018f811115614fad57600080fd5b60005b601f811015614fd757614fc283614c05565b84526020938401939290920191600101614fb0565b50839750614fe481614d61565b9650505050506104808b013591506104a08b013590509295989b9194979a5092959850565b600080600083850360a081121561501f57600080fd5b843567ffffffffffffffff81111561503657600080fd5b61504287828801614c7a565b90955093505060807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08201121561507857600080fd5b506020840190509250925092565b600080600060a0848603121561509b57600080fd5b833567ffffffffffffffff8111156150b257600080fd5b6150be86828701614c7a565b9094509250614de190508560208601614cbc565b6000608082840312156150e457600080fd5b6146a28383614cbc565b60006020828403121561510057600080fd5b5051919050565b60006020828403121561511957600080fd5b6146a282614d35565b6000806000806080858703121561513857600080fd5b61514185614d35565b93506020850135925060408501356151588161588b565b915060608501356151688161588b565b939692955090935050565b60008060008060008060c0878903121561518c57600080fd5b61519587614d35565b95506151a360208801614d35565b945060408701359350606087013592506151bf60808801614d35565b91506151cd60a08801614d35565b90509295509295509295565b6000602082840312156151eb57600080fd5b6146a282614d49565b6000806040838503121561520757600080fd5b61521083614d49565b915061521e60208401614c05565b90509250929050565b600080600080600060a0868803121561523f57600080fd5b61524886614d72565b945060208601519350604086015192506060860151915061526b60808701614d72565b90509295509295909350565b60006020828403121561528957600080fd5b81516146a28161588b565b600081518084526020808501945080840160005b838110156152da57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016152a8565b509495945050505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b6040808252810183905260008460608301825b8681101561537c5773ffffffffffffffffffffffffffffffffffffffff61536784614c05565b16825260209283019290910190600101615341565b50809250505073ffffffffffffffffffffffffffffffffffffffff83166020830152949350505050565b6020815260006146a26020830184615294565b8581526060602082015260006153d36060830186886152e5565b82810360408401526153e68185876152e5565b98975050505050505050565b60a08152600061540660a0830185876152e5565b905067ffffffffffffffff61541a84614d49565b16602083015273ffffffffffffffffffffffffffffffffffffffff61544160208501614c05565b16604083015263ffffffff61545860408501614d35565b16606083015260608301356080830152949350505050565b60208101600383106154ab577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b91905290565b60006101208201905067ffffffffffffffff835116825273ffffffffffffffffffffffffffffffffffffffff602084015116602083015260408301516154ff604084018263ffffffff169052565b50606083015160608301526080830151615531608084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060a083015161555160a08401826bffffffffffffffffffffffff169052565b5060c083015161557160c08401826bffffffffffffffffffffffff169052565b5060e083015161559160e08401826bffffffffffffffffffffffff169052565b5061010092830151919092015290565b63ffffffff831681526040602082015260006155c06040830184615294565b949350505050565b6bffffffffffffffffffffffff8416815273ffffffffffffffffffffffffffffffffffffffff8316602082015260606040820152600061560b6060830184615294565b95945050505050565b60008219821115615627576156276157a0565b500190565b600067ffffffffffffffff80831681851680830382111561564f5761564f6157a0565b01949350505050565b60006bffffffffffffffffffffffff80831681851680830382111561564f5761564f6157a0565b60008261568e5761568e6157cf565b500490565b60006bffffffffffffffffffffffff808416806156b2576156b26157cf565b92169190910492915050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156156f6576156f66157a0565b500290565b60008282101561570d5761570d6157a0565b500390565b60006bffffffffffffffffffffffff83811690831681811015615737576157376157a0565b039392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415615771576157716157a0565b5060010190565b600067ffffffffffffffff80831681811415615796576157966157a0565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6bffffffffffffffffffffffff81168114613bbe57600080fdfea164736f6c6343000806000a496e697469616c697a61626c653a20636f6e7472616374206973206e6f742069", -} - -var FunctionsRegistryABI = FunctionsRegistryMetaData.ABI - -var FunctionsRegistryBin = FunctionsRegistryMetaData.Bin - -func DeployFunctionsRegistry(auth *bind.TransactOpts, backend bind.ContractBackend, link common.Address, linkEthFeed common.Address, oracle common.Address) (common.Address, *types.Transaction, *FunctionsRegistry, error) { - parsed, err := FunctionsRegistryMetaData.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(FunctionsRegistryBin), backend, link, linkEthFeed, oracle) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &FunctionsRegistry{FunctionsRegistryCaller: FunctionsRegistryCaller{contract: contract}, FunctionsRegistryTransactor: FunctionsRegistryTransactor{contract: contract}, FunctionsRegistryFilterer: FunctionsRegistryFilterer{contract: contract}}, nil -} - -type FunctionsRegistry struct { - address common.Address - abi abi.ABI - FunctionsRegistryCaller - FunctionsRegistryTransactor - FunctionsRegistryFilterer -} - -type FunctionsRegistryCaller struct { - contract *bind.BoundContract -} - -type FunctionsRegistryTransactor struct { - contract *bind.BoundContract -} - -type FunctionsRegistryFilterer struct { - contract *bind.BoundContract -} - -type FunctionsRegistrySession struct { - Contract *FunctionsRegistry - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type FunctionsRegistryCallerSession struct { - Contract *FunctionsRegistryCaller - CallOpts bind.CallOpts -} - -type FunctionsRegistryTransactorSession struct { - Contract *FunctionsRegistryTransactor - TransactOpts bind.TransactOpts -} - -type FunctionsRegistryRaw struct { - Contract *FunctionsRegistry -} - -type FunctionsRegistryCallerRaw struct { - Contract *FunctionsRegistryCaller -} - -type FunctionsRegistryTransactorRaw struct { - Contract *FunctionsRegistryTransactor -} - -func NewFunctionsRegistry(address common.Address, backend bind.ContractBackend) (*FunctionsRegistry, error) { - abi, err := abi.JSON(strings.NewReader(FunctionsRegistryABI)) - if err != nil { - return nil, err - } - contract, err := bindFunctionsRegistry(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &FunctionsRegistry{address: address, abi: abi, FunctionsRegistryCaller: FunctionsRegistryCaller{contract: contract}, FunctionsRegistryTransactor: FunctionsRegistryTransactor{contract: contract}, FunctionsRegistryFilterer: FunctionsRegistryFilterer{contract: contract}}, nil -} - -func NewFunctionsRegistryCaller(address common.Address, caller bind.ContractCaller) (*FunctionsRegistryCaller, error) { - contract, err := bindFunctionsRegistry(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &FunctionsRegistryCaller{contract: contract}, nil -} - -func NewFunctionsRegistryTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsRegistryTransactor, error) { - contract, err := bindFunctionsRegistry(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &FunctionsRegistryTransactor{contract: contract}, nil -} - -func NewFunctionsRegistryFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsRegistryFilterer, error) { - contract, err := bindFunctionsRegistry(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &FunctionsRegistryFilterer{contract: contract}, nil -} - -func bindFunctionsRegistry(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := FunctionsRegistryMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_FunctionsRegistry *FunctionsRegistryRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsRegistry.Contract.FunctionsRegistryCaller.contract.Call(opts, result, method, params...) -} - -func (_FunctionsRegistry *FunctionsRegistryRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.FunctionsRegistryTransactor.contract.Transfer(opts) -} - -func (_FunctionsRegistry *FunctionsRegistryRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.FunctionsRegistryTransactor.contract.Transact(opts, method, params...) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsRegistry.Contract.contract.Call(opts, result, method, params...) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.contract.Transfer(opts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.contract.Transact(opts, method, params...) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) MAXCONSUMERS(opts *bind.CallOpts) (uint16, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "MAX_CONSUMERS") - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) MAXCONSUMERS() (uint16, error) { - return _FunctionsRegistry.Contract.MAXCONSUMERS(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) MAXCONSUMERS() (uint16, error) { - return _FunctionsRegistry.Contract.MAXCONSUMERS(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) EstimateCost(opts *bind.CallOpts, gasLimit uint32, gasPrice *big.Int, donFee *big.Int, registryFee *big.Int) (*big.Int, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "estimateCost", gasLimit, gasPrice, donFee, registryFee) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) EstimateCost(gasLimit uint32, gasPrice *big.Int, donFee *big.Int, registryFee *big.Int) (*big.Int, error) { - return _FunctionsRegistry.Contract.EstimateCost(&_FunctionsRegistry.CallOpts, gasLimit, gasPrice, donFee, registryFee) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) EstimateCost(gasLimit uint32, gasPrice *big.Int, donFee *big.Int, registryFee *big.Int) (*big.Int, error) { - return _FunctionsRegistry.Contract.EstimateCost(&_FunctionsRegistry.CallOpts, gasLimit, gasPrice, donFee, registryFee) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetAuthorizedSenders(opts *bind.CallOpts) ([]common.Address, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getAuthorizedSenders") - - if err != nil { - return *new([]common.Address), err - } - - out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetAuthorizedSenders() ([]common.Address, error) { - return _FunctionsRegistry.Contract.GetAuthorizedSenders(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetAuthorizedSenders() ([]common.Address, error) { - return _FunctionsRegistry.Contract.GetAuthorizedSenders(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetConfig(opts *bind.CallOpts) (GetConfig, - - error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getConfig") - - outstruct := new(GetConfig) - if err != nil { - return *outstruct, err - } - - outstruct.MaxGasLimit = *abi.ConvertType(out[0], new(uint32)).(*uint32) - outstruct.StalenessSeconds = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.GasAfterPaymentCalculation = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) - outstruct.FallbackWeiPerUnitLink = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) - outstruct.GasOverhead = *abi.ConvertType(out[4], new(uint32)).(*uint32) - outstruct.LinkAddress = *abi.ConvertType(out[5], new(common.Address)).(*common.Address) - outstruct.LinkPriceFeed = *abi.ConvertType(out[6], new(common.Address)).(*common.Address) - - return *outstruct, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetConfig() (GetConfig, - - error) { - return _FunctionsRegistry.Contract.GetConfig(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetConfig() (GetConfig, - - error) { - return _FunctionsRegistry.Contract.GetConfig(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetCurrentsubscriptionId(opts *bind.CallOpts) (uint64, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getCurrentsubscriptionId") - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetCurrentsubscriptionId() (uint64, error) { - return _FunctionsRegistry.Contract.GetCurrentsubscriptionId(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetCurrentsubscriptionId() (uint64, error) { - return _FunctionsRegistry.Contract.GetCurrentsubscriptionId(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetRequestConfig(opts *bind.CallOpts) (uint32, []common.Address, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getRequestConfig") - - if err != nil { - return *new(uint32), *new([]common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) - out1 := *abi.ConvertType(out[1], new([]common.Address)).(*[]common.Address) - - return out0, out1, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetRequestConfig() (uint32, []common.Address, error) { - return _FunctionsRegistry.Contract.GetRequestConfig(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetRequestConfig() (uint32, []common.Address, error) { - return _FunctionsRegistry.Contract.GetRequestConfig(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetRequiredFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRegistryRequestBilling) (*big.Int, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getRequiredFee", arg0, arg1) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetRequiredFee(arg0 []byte, arg1 IFunctionsBillingRegistryRequestBilling) (*big.Int, error) { - return _FunctionsRegistry.Contract.GetRequiredFee(&_FunctionsRegistry.CallOpts, arg0, arg1) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetRequiredFee(arg0 []byte, arg1 IFunctionsBillingRegistryRequestBilling) (*big.Int, error) { - return _FunctionsRegistry.Contract.GetRequiredFee(&_FunctionsRegistry.CallOpts, arg0, arg1) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getSubscription", subscriptionId) - - outstruct := new(GetSubscription) - if err != nil { - return *outstruct, err - } - - outstruct.Balance = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - outstruct.Owner = *abi.ConvertType(out[1], new(common.Address)).(*common.Address) - outstruct.Consumers = *abi.ConvertType(out[2], new([]common.Address)).(*[]common.Address) - - return *outstruct, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { - return _FunctionsRegistry.Contract.GetSubscription(&_FunctionsRegistry.CallOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { - return _FunctionsRegistry.Contract.GetSubscription(&_FunctionsRegistry.CallOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetSubscriptionOwner(opts *bind.CallOpts, subscriptionId uint64) (common.Address, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getSubscriptionOwner", subscriptionId) - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetSubscriptionOwner(subscriptionId uint64) (common.Address, error) { - return _FunctionsRegistry.Contract.GetSubscriptionOwner(&_FunctionsRegistry.CallOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetSubscriptionOwner(subscriptionId uint64) (common.Address, error) { - return _FunctionsRegistry.Contract.GetSubscriptionOwner(&_FunctionsRegistry.CallOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) GetTotalBalance(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "getTotalBalance") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) GetTotalBalance() (*big.Int, error) { - return _FunctionsRegistry.Contract.GetTotalBalance(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) GetTotalBalance() (*big.Int, error) { - return _FunctionsRegistry.Contract.GetTotalBalance(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) IsAuthorizedSender(opts *bind.CallOpts, sender common.Address) (bool, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "isAuthorizedSender", sender) - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) IsAuthorizedSender(sender common.Address) (bool, error) { - return _FunctionsRegistry.Contract.IsAuthorizedSender(&_FunctionsRegistry.CallOpts, sender) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) IsAuthorizedSender(sender common.Address) (bool, error) { - return _FunctionsRegistry.Contract.IsAuthorizedSender(&_FunctionsRegistry.CallOpts, sender) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _FunctionsRegistry.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 (_FunctionsRegistry *FunctionsRegistrySession) Owner() (common.Address, error) { - return _FunctionsRegistry.Contract.Owner(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) Owner() (common.Address, error) { - return _FunctionsRegistry.Contract.Owner(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) Paused(opts *bind.CallOpts) (bool, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "paused") - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) Paused() (bool, error) { - return _FunctionsRegistry.Contract.Paused(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) Paused() (bool, error) { - return _FunctionsRegistry.Contract.Paused(&_FunctionsRegistry.CallOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryCaller) PendingRequestExists(opts *bind.CallOpts, subscriptionId uint64) (bool, error) { - var out []interface{} - err := _FunctionsRegistry.contract.Call(opts, &out, "pendingRequestExists", subscriptionId) - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRegistry *FunctionsRegistrySession) PendingRequestExists(subscriptionId uint64) (bool, error) { - return _FunctionsRegistry.Contract.PendingRequestExists(&_FunctionsRegistry.CallOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryCallerSession) PendingRequestExists(subscriptionId uint64) (bool, error) { - return _FunctionsRegistry.Contract.PendingRequestExists(&_FunctionsRegistry.CallOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "acceptOwnership") -} - -func (_FunctionsRegistry *FunctionsRegistrySession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.AcceptOwnership(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.AcceptOwnership(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) AcceptSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "acceptSubscriptionOwnerTransfer", subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) AcceptSubscriptionOwnerTransfer(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.AcceptSubscriptionOwnerTransfer(&_FunctionsRegistry.TransactOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) AcceptSubscriptionOwnerTransfer(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.AcceptSubscriptionOwnerTransfer(&_FunctionsRegistry.TransactOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) AddConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "addConsumer", subscriptionId, consumer) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) AddConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.AddConsumer(&_FunctionsRegistry.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) AddConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.AddConsumer(&_FunctionsRegistry.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) CancelSubscription(opts *bind.TransactOpts, subscriptionId uint64, to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "cancelSubscription", subscriptionId, to) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) CancelSubscription(subscriptionId uint64, to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.CancelSubscription(&_FunctionsRegistry.TransactOpts, subscriptionId, to) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) CancelSubscription(subscriptionId uint64, to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.CancelSubscription(&_FunctionsRegistry.TransactOpts, subscriptionId, to) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "createSubscription") -} - -func (_FunctionsRegistry *FunctionsRegistrySession) CreateSubscription() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.CreateSubscription(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) CreateSubscription() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.CreateSubscription(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) FulfillAndBill(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte, transmitter common.Address, signers [31]common.Address, signerCount uint8, reportValidationGas *big.Int, initialGas *big.Int) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "fulfillAndBill", requestId, response, err, transmitter, signers, signerCount, reportValidationGas, initialGas) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) FulfillAndBill(requestId [32]byte, response []byte, err []byte, transmitter common.Address, signers [31]common.Address, signerCount uint8, reportValidationGas *big.Int, initialGas *big.Int) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.FulfillAndBill(&_FunctionsRegistry.TransactOpts, requestId, response, err, transmitter, signers, signerCount, reportValidationGas, initialGas) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) FulfillAndBill(requestId [32]byte, response []byte, err []byte, transmitter common.Address, signers [31]common.Address, signerCount uint8, reportValidationGas *big.Int, initialGas *big.Int) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.FulfillAndBill(&_FunctionsRegistry.TransactOpts, requestId, response, err, transmitter, signers, signerCount, reportValidationGas, initialGas) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) Initialize(opts *bind.TransactOpts, link common.Address, linkEthFeed common.Address, oracle common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "initialize", link, linkEthFeed, oracle) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) Initialize(link common.Address, linkEthFeed common.Address, oracle common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.Initialize(&_FunctionsRegistry.TransactOpts, link, linkEthFeed, oracle) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) Initialize(link common.Address, linkEthFeed common.Address, oracle common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.Initialize(&_FunctionsRegistry.TransactOpts, link, linkEthFeed, oracle) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "onTokenTransfer", arg0, amount, data) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) OnTokenTransfer(arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.OnTokenTransfer(&_FunctionsRegistry.TransactOpts, arg0, amount, data) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) OnTokenTransfer(arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.OnTokenTransfer(&_FunctionsRegistry.TransactOpts, arg0, amount, data) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "oracleWithdraw", recipient, amount) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) OracleWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.OracleWithdraw(&_FunctionsRegistry.TransactOpts, recipient, amount) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) OracleWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.OracleWithdraw(&_FunctionsRegistry.TransactOpts, recipient, amount) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) OwnerCancelSubscription(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "ownerCancelSubscription", subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) OwnerCancelSubscription(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.OwnerCancelSubscription(&_FunctionsRegistry.TransactOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) OwnerCancelSubscription(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.OwnerCancelSubscription(&_FunctionsRegistry.TransactOpts, subscriptionId) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) Pause(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "pause") -} - -func (_FunctionsRegistry *FunctionsRegistrySession) Pause() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.Pause(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) Pause() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.Pause(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "recoverFunds", to) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) RecoverFunds(to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.RecoverFunds(&_FunctionsRegistry.TransactOpts, to) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) RecoverFunds(to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.RecoverFunds(&_FunctionsRegistry.TransactOpts, to) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) RemoveConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "removeConsumer", subscriptionId, consumer) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) RemoveConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.RemoveConsumer(&_FunctionsRegistry.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) RemoveConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.RemoveConsumer(&_FunctionsRegistry.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) RequestSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "requestSubscriptionOwnerTransfer", subscriptionId, newOwner) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) RequestSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.RequestSubscriptionOwnerTransfer(&_FunctionsRegistry.TransactOpts, subscriptionId, newOwner) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) RequestSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.RequestSubscriptionOwnerTransfer(&_FunctionsRegistry.TransactOpts, subscriptionId, newOwner) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) SetAuthorizedSenders(opts *bind.TransactOpts, senders []common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "setAuthorizedSenders", senders) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) SetAuthorizedSenders(senders []common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.SetAuthorizedSenders(&_FunctionsRegistry.TransactOpts, senders) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) SetAuthorizedSenders(senders []common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.SetAuthorizedSenders(&_FunctionsRegistry.TransactOpts, senders) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) SetConfig(opts *bind.TransactOpts, maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation *big.Int, fallbackWeiPerUnitLink *big.Int, gasOverhead uint32, requestTimeoutSeconds uint32) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "setConfig", maxGasLimit, stalenessSeconds, gasAfterPaymentCalculation, fallbackWeiPerUnitLink, gasOverhead, requestTimeoutSeconds) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) SetConfig(maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation *big.Int, fallbackWeiPerUnitLink *big.Int, gasOverhead uint32, requestTimeoutSeconds uint32) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.SetConfig(&_FunctionsRegistry.TransactOpts, maxGasLimit, stalenessSeconds, gasAfterPaymentCalculation, fallbackWeiPerUnitLink, gasOverhead, requestTimeoutSeconds) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) SetConfig(maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation *big.Int, fallbackWeiPerUnitLink *big.Int, gasOverhead uint32, requestTimeoutSeconds uint32) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.SetConfig(&_FunctionsRegistry.TransactOpts, maxGasLimit, stalenessSeconds, gasAfterPaymentCalculation, fallbackWeiPerUnitLink, gasOverhead, requestTimeoutSeconds) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) StartBilling(opts *bind.TransactOpts, data []byte, billing IFunctionsBillingRegistryRequestBilling) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "startBilling", data, billing) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) StartBilling(data []byte, billing IFunctionsBillingRegistryRequestBilling) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.StartBilling(&_FunctionsRegistry.TransactOpts, data, billing) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) StartBilling(data []byte, billing IFunctionsBillingRegistryRequestBilling) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.StartBilling(&_FunctionsRegistry.TransactOpts, data, billing) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "timeoutRequests", requestIdsToTimeout) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) TimeoutRequests(requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.TimeoutRequests(&_FunctionsRegistry.TransactOpts, requestIdsToTimeout) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) TimeoutRequests(requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.TimeoutRequests(&_FunctionsRegistry.TransactOpts, requestIdsToTimeout) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "transferOwnership", to) -} - -func (_FunctionsRegistry *FunctionsRegistrySession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.TransferOwnership(&_FunctionsRegistry.TransactOpts, to) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsRegistry.Contract.TransferOwnership(&_FunctionsRegistry.TransactOpts, to) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactor) Unpause(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRegistry.contract.Transact(opts, "unpause") -} - -func (_FunctionsRegistry *FunctionsRegistrySession) Unpause() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.Unpause(&_FunctionsRegistry.TransactOpts) -} - -func (_FunctionsRegistry *FunctionsRegistryTransactorSession) Unpause() (*types.Transaction, error) { - return _FunctionsRegistry.Contract.Unpause(&_FunctionsRegistry.TransactOpts) -} - -type FunctionsRegistryAuthorizedSendersChangedIterator struct { - Event *FunctionsRegistryAuthorizedSendersChanged - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryAuthorizedSendersChangedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryAuthorizedSendersChanged) - 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(FunctionsRegistryAuthorizedSendersChanged) - 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 *FunctionsRegistryAuthorizedSendersChangedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryAuthorizedSendersChangedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryAuthorizedSendersChanged struct { - Senders []common.Address - ChangedBy common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterAuthorizedSendersChanged(opts *bind.FilterOpts) (*FunctionsRegistryAuthorizedSendersChangedIterator, error) { - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "AuthorizedSendersChanged") - if err != nil { - return nil, err - } - return &FunctionsRegistryAuthorizedSendersChangedIterator{contract: _FunctionsRegistry.contract, event: "AuthorizedSendersChanged", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchAuthorizedSendersChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryAuthorizedSendersChanged) (event.Subscription, error) { - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "AuthorizedSendersChanged") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryAuthorizedSendersChanged) - if err := _FunctionsRegistry.contract.UnpackLog(event, "AuthorizedSendersChanged", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseAuthorizedSendersChanged(log types.Log) (*FunctionsRegistryAuthorizedSendersChanged, error) { - event := new(FunctionsRegistryAuthorizedSendersChanged) - if err := _FunctionsRegistry.contract.UnpackLog(event, "AuthorizedSendersChanged", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryBillingEndIterator struct { - Event *FunctionsRegistryBillingEnd - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryBillingEndIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryBillingEnd) - 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(FunctionsRegistryBillingEnd) - 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 *FunctionsRegistryBillingEndIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryBillingEndIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryBillingEnd struct { - RequestId [32]byte - SubscriptionId uint64 - SignerPayment *big.Int - TransmitterPayment *big.Int - TotalCost *big.Int - Success bool - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRegistryBillingEndIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "BillingEnd", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistryBillingEndIterator{contract: _FunctionsRegistry.contract, event: "BillingEnd", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryBillingEnd, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "BillingEnd", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryBillingEnd) - if err := _FunctionsRegistry.contract.UnpackLog(event, "BillingEnd", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseBillingEnd(log types.Log) (*FunctionsRegistryBillingEnd, error) { - event := new(FunctionsRegistryBillingEnd) - if err := _FunctionsRegistry.contract.UnpackLog(event, "BillingEnd", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryBillingStartIterator struct { - Event *FunctionsRegistryBillingStart - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryBillingStartIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryBillingStart) - 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(FunctionsRegistryBillingStart) - 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 *FunctionsRegistryBillingStartIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryBillingStartIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryBillingStart struct { - RequestId [32]byte - Commitment FunctionsBillingRegistryCommitment - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterBillingStart(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRegistryBillingStartIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "BillingStart", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistryBillingStartIterator{contract: _FunctionsRegistry.contract, event: "BillingStart", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchBillingStart(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryBillingStart, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "BillingStart", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryBillingStart) - if err := _FunctionsRegistry.contract.UnpackLog(event, "BillingStart", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseBillingStart(log types.Log) (*FunctionsRegistryBillingStart, error) { - event := new(FunctionsRegistryBillingStart) - if err := _FunctionsRegistry.contract.UnpackLog(event, "BillingStart", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryConfigSetIterator struct { - Event *FunctionsRegistryConfigSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryConfigSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryConfigSet) - 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(FunctionsRegistryConfigSet) - 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 *FunctionsRegistryConfigSetIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryConfigSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryConfigSet struct { - MaxGasLimit uint32 - StalenessSeconds uint32 - GasAfterPaymentCalculation *big.Int - FallbackWeiPerUnitLink *big.Int - GasOverhead uint32 - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsRegistryConfigSetIterator, error) { - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "ConfigSet") - if err != nil { - return nil, err - } - return &FunctionsRegistryConfigSetIterator{contract: _FunctionsRegistry.contract, event: "ConfigSet", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryConfigSet) (event.Subscription, error) { - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "ConfigSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryConfigSet) - if err := _FunctionsRegistry.contract.UnpackLog(event, "ConfigSet", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseConfigSet(log types.Log) (*FunctionsRegistryConfigSet, error) { - event := new(FunctionsRegistryConfigSet) - if err := _FunctionsRegistry.contract.UnpackLog(event, "ConfigSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryFundsRecoveredIterator struct { - Event *FunctionsRegistryFundsRecovered - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryFundsRecoveredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryFundsRecovered) - 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(FunctionsRegistryFundsRecovered) - 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 *FunctionsRegistryFundsRecoveredIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryFundsRecoveredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryFundsRecovered struct { - To common.Address - Amount *big.Int - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterFundsRecovered(opts *bind.FilterOpts) (*FunctionsRegistryFundsRecoveredIterator, error) { - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "FundsRecovered") - if err != nil { - return nil, err - } - return &FunctionsRegistryFundsRecoveredIterator{contract: _FunctionsRegistry.contract, event: "FundsRecovered", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchFundsRecovered(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryFundsRecovered) (event.Subscription, error) { - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "FundsRecovered") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryFundsRecovered) - if err := _FunctionsRegistry.contract.UnpackLog(event, "FundsRecovered", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseFundsRecovered(log types.Log) (*FunctionsRegistryFundsRecovered, error) { - event := new(FunctionsRegistryFundsRecovered) - if err := _FunctionsRegistry.contract.UnpackLog(event, "FundsRecovered", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryInitializedIterator struct { - Event *FunctionsRegistryInitialized - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryInitializedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryInitialized) - 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(FunctionsRegistryInitialized) - 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 *FunctionsRegistryInitializedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryInitializedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryInitialized struct { - Version uint8 - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterInitialized(opts *bind.FilterOpts) (*FunctionsRegistryInitializedIterator, error) { - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "Initialized") - if err != nil { - return nil, err - } - return &FunctionsRegistryInitializedIterator{contract: _FunctionsRegistry.contract, event: "Initialized", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryInitialized) (event.Subscription, error) { - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "Initialized") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryInitialized) - if err := _FunctionsRegistry.contract.UnpackLog(event, "Initialized", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseInitialized(log types.Log) (*FunctionsRegistryInitialized, error) { - event := new(FunctionsRegistryInitialized) - if err := _FunctionsRegistry.contract.UnpackLog(event, "Initialized", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryOwnershipTransferRequestedIterator struct { - Event *FunctionsRegistryOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryOwnershipTransferRequested) - 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(FunctionsRegistryOwnershipTransferRequested) - 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 *FunctionsRegistryOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRegistryOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsRegistryOwnershipTransferRequestedIterator{contract: _FunctionsRegistry.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryOwnershipTransferRequested) - if err := _FunctionsRegistry.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseOwnershipTransferRequested(log types.Log) (*FunctionsRegistryOwnershipTransferRequested, error) { - event := new(FunctionsRegistryOwnershipTransferRequested) - if err := _FunctionsRegistry.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryOwnershipTransferredIterator struct { - Event *FunctionsRegistryOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryOwnershipTransferred) - 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(FunctionsRegistryOwnershipTransferred) - 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 *FunctionsRegistryOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRegistryOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsRegistryOwnershipTransferredIterator{contract: _FunctionsRegistry.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryOwnershipTransferred) - if err := _FunctionsRegistry.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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseOwnershipTransferred(log types.Log) (*FunctionsRegistryOwnershipTransferred, error) { - event := new(FunctionsRegistryOwnershipTransferred) - if err := _FunctionsRegistry.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryPausedIterator struct { - Event *FunctionsRegistryPaused - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryPausedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryPaused) - 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(FunctionsRegistryPaused) - 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 *FunctionsRegistryPausedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryPausedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryPaused struct { - Account common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterPaused(opts *bind.FilterOpts) (*FunctionsRegistryPausedIterator, error) { - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "Paused") - if err != nil { - return nil, err - } - return &FunctionsRegistryPausedIterator{contract: _FunctionsRegistry.contract, event: "Paused", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchPaused(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryPaused) (event.Subscription, error) { - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "Paused") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryPaused) - if err := _FunctionsRegistry.contract.UnpackLog(event, "Paused", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParsePaused(log types.Log) (*FunctionsRegistryPaused, error) { - event := new(FunctionsRegistryPaused) - if err := _FunctionsRegistry.contract.UnpackLog(event, "Paused", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryRequestTimedOutIterator struct { - Event *FunctionsRegistryRequestTimedOut - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryRequestTimedOutIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryRequestTimedOut) - 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(FunctionsRegistryRequestTimedOut) - 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 *FunctionsRegistryRequestTimedOutIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryRequestTimedOutIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryRequestTimedOut struct { - RequestId [32]byte - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRegistryRequestTimedOutIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "RequestTimedOut", requestIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistryRequestTimedOutIterator{contract: _FunctionsRegistry.contract, event: "RequestTimedOut", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryRequestTimedOut, requestId [][32]byte) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "RequestTimedOut", requestIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistryRequestTimedOut) - if err := _FunctionsRegistry.contract.UnpackLog(event, "RequestTimedOut", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseRequestTimedOut(log types.Log) (*FunctionsRegistryRequestTimedOut, error) { - event := new(FunctionsRegistryRequestTimedOut) - if err := _FunctionsRegistry.contract.UnpackLog(event, "RequestTimedOut", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionCanceledIterator struct { - Event *FunctionsRegistrySubscriptionCanceled - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionCanceledIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionCanceled) - 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(FunctionsRegistrySubscriptionCanceled) - 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 *FunctionsRegistrySubscriptionCanceledIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionCanceledIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionCanceled struct { - SubscriptionId uint64 - To common.Address - Amount *big.Int - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionCanceled(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionCanceledIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionCanceled", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionCanceledIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionCanceled", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionCanceled(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionCanceled, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionCanceled", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionCanceled) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionCanceled", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionCanceled(log types.Log) (*FunctionsRegistrySubscriptionCanceled, error) { - event := new(FunctionsRegistrySubscriptionCanceled) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionCanceled", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionConsumerAddedIterator struct { - Event *FunctionsRegistrySubscriptionConsumerAdded - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionConsumerAddedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionConsumerAdded) - 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(FunctionsRegistrySubscriptionConsumerAdded) - 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 *FunctionsRegistrySubscriptionConsumerAddedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionConsumerAddedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionConsumerAdded struct { - SubscriptionId uint64 - Consumer common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionConsumerAdded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionConsumerAddedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionConsumerAdded", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionConsumerAddedIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionConsumerAdded", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionConsumerAdded(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionConsumerAdded, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionConsumerAdded", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionConsumerAdded) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionConsumerAdded", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionConsumerAdded(log types.Log) (*FunctionsRegistrySubscriptionConsumerAdded, error) { - event := new(FunctionsRegistrySubscriptionConsumerAdded) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionConsumerAdded", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionConsumerRemovedIterator struct { - Event *FunctionsRegistrySubscriptionConsumerRemoved - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionConsumerRemovedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionConsumerRemoved) - 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(FunctionsRegistrySubscriptionConsumerRemoved) - 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 *FunctionsRegistrySubscriptionConsumerRemovedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionConsumerRemovedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionConsumerRemoved struct { - SubscriptionId uint64 - Consumer common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionConsumerRemoved(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionConsumerRemovedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionConsumerRemoved", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionConsumerRemovedIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionConsumerRemoved", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionConsumerRemoved(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionConsumerRemoved, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionConsumerRemoved", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionConsumerRemoved) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionConsumerRemoved", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionConsumerRemoved(log types.Log) (*FunctionsRegistrySubscriptionConsumerRemoved, error) { - event := new(FunctionsRegistrySubscriptionConsumerRemoved) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionConsumerRemoved", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionCreatedIterator struct { - Event *FunctionsRegistrySubscriptionCreated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionCreatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionCreated) - 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(FunctionsRegistrySubscriptionCreated) - 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 *FunctionsRegistrySubscriptionCreatedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionCreatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionCreated struct { - SubscriptionId uint64 - Owner common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionCreated(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionCreatedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionCreated", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionCreatedIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionCreated", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionCreated(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionCreated, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionCreated", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionCreated) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionCreated", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionCreated(log types.Log) (*FunctionsRegistrySubscriptionCreated, error) { - event := new(FunctionsRegistrySubscriptionCreated) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionCreated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionFundedIterator struct { - Event *FunctionsRegistrySubscriptionFunded - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionFundedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionFunded) - 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(FunctionsRegistrySubscriptionFunded) - 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 *FunctionsRegistrySubscriptionFundedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionFundedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionFunded struct { - SubscriptionId uint64 - OldBalance *big.Int - NewBalance *big.Int - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionFunded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionFundedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionFunded", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionFundedIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionFunded", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionFunded(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionFunded, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionFunded", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionFunded) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionFunded", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionFunded(log types.Log) (*FunctionsRegistrySubscriptionFunded, error) { - event := new(FunctionsRegistrySubscriptionFunded) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionFunded", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionOwnerTransferRequestedIterator struct { - Event *FunctionsRegistrySubscriptionOwnerTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionOwnerTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionOwnerTransferRequested) - 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(FunctionsRegistrySubscriptionOwnerTransferRequested) - 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 *FunctionsRegistrySubscriptionOwnerTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionOwnerTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionOwnerTransferRequested struct { - SubscriptionId uint64 - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionOwnerTransferRequested(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionOwnerTransferRequestedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionOwnerTransferRequested", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionOwnerTransferRequestedIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionOwnerTransferRequested", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionOwnerTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionOwnerTransferRequested, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionOwnerTransferRequested", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionOwnerTransferRequested) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionOwnerTransferRequested", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionOwnerTransferRequested(log types.Log) (*FunctionsRegistrySubscriptionOwnerTransferRequested, error) { - event := new(FunctionsRegistrySubscriptionOwnerTransferRequested) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionOwnerTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistrySubscriptionOwnerTransferredIterator struct { - Event *FunctionsRegistrySubscriptionOwnerTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistrySubscriptionOwnerTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistrySubscriptionOwnerTransferred) - 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(FunctionsRegistrySubscriptionOwnerTransferred) - 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 *FunctionsRegistrySubscriptionOwnerTransferredIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistrySubscriptionOwnerTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistrySubscriptionOwnerTransferred struct { - SubscriptionId uint64 - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterSubscriptionOwnerTransferred(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionOwnerTransferredIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "SubscriptionOwnerTransferred", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRegistrySubscriptionOwnerTransferredIterator{contract: _FunctionsRegistry.contract, event: "SubscriptionOwnerTransferred", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchSubscriptionOwnerTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionOwnerTransferred, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRegistry.contract.WatchLogs(opts, "SubscriptionOwnerTransferred", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRegistrySubscriptionOwnerTransferred) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionOwnerTransferred", 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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseSubscriptionOwnerTransferred(log types.Log) (*FunctionsRegistrySubscriptionOwnerTransferred, error) { - event := new(FunctionsRegistrySubscriptionOwnerTransferred) - if err := _FunctionsRegistry.contract.UnpackLog(event, "SubscriptionOwnerTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRegistryUnpausedIterator struct { - Event *FunctionsRegistryUnpaused - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRegistryUnpausedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRegistryUnpaused) - 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(FunctionsRegistryUnpaused) - 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 *FunctionsRegistryUnpausedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRegistryUnpausedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRegistryUnpaused struct { - Account common.Address - Raw types.Log -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) FilterUnpaused(opts *bind.FilterOpts) (*FunctionsRegistryUnpausedIterator, error) { - - logs, sub, err := _FunctionsRegistry.contract.FilterLogs(opts, "Unpaused") - if err != nil { - return nil, err - } - return &FunctionsRegistryUnpausedIterator{contract: _FunctionsRegistry.contract, event: "Unpaused", logs: logs, sub: sub}, nil -} - -func (_FunctionsRegistry *FunctionsRegistryFilterer) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryUnpaused) (event.Subscription, error) { - - logs, sub, err := _FunctionsRegistry.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(FunctionsRegistryUnpaused) - if err := _FunctionsRegistry.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 (_FunctionsRegistry *FunctionsRegistryFilterer) ParseUnpaused(log types.Log) (*FunctionsRegistryUnpaused, error) { - event := new(FunctionsRegistryUnpaused) - if err := _FunctionsRegistry.contract.UnpackLog(event, "Unpaused", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type GetConfig struct { - MaxGasLimit uint32 - StalenessSeconds uint32 - GasAfterPaymentCalculation *big.Int - FallbackWeiPerUnitLink *big.Int - GasOverhead uint32 - LinkAddress common.Address - LinkPriceFeed common.Address -} -type GetSubscription struct { - Balance *big.Int - Owner common.Address - Consumers []common.Address -} - -func (_FunctionsRegistry *FunctionsRegistry) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _FunctionsRegistry.abi.Events["AuthorizedSendersChanged"].ID: - return _FunctionsRegistry.ParseAuthorizedSendersChanged(log) - case _FunctionsRegistry.abi.Events["BillingEnd"].ID: - return _FunctionsRegistry.ParseBillingEnd(log) - case _FunctionsRegistry.abi.Events["BillingStart"].ID: - return _FunctionsRegistry.ParseBillingStart(log) - case _FunctionsRegistry.abi.Events["ConfigSet"].ID: - return _FunctionsRegistry.ParseConfigSet(log) - case _FunctionsRegistry.abi.Events["FundsRecovered"].ID: - return _FunctionsRegistry.ParseFundsRecovered(log) - case _FunctionsRegistry.abi.Events["Initialized"].ID: - return _FunctionsRegistry.ParseInitialized(log) - case _FunctionsRegistry.abi.Events["OwnershipTransferRequested"].ID: - return _FunctionsRegistry.ParseOwnershipTransferRequested(log) - case _FunctionsRegistry.abi.Events["OwnershipTransferred"].ID: - return _FunctionsRegistry.ParseOwnershipTransferred(log) - case _FunctionsRegistry.abi.Events["Paused"].ID: - return _FunctionsRegistry.ParsePaused(log) - case _FunctionsRegistry.abi.Events["RequestTimedOut"].ID: - return _FunctionsRegistry.ParseRequestTimedOut(log) - case _FunctionsRegistry.abi.Events["SubscriptionCanceled"].ID: - return _FunctionsRegistry.ParseSubscriptionCanceled(log) - case _FunctionsRegistry.abi.Events["SubscriptionConsumerAdded"].ID: - return _FunctionsRegistry.ParseSubscriptionConsumerAdded(log) - case _FunctionsRegistry.abi.Events["SubscriptionConsumerRemoved"].ID: - return _FunctionsRegistry.ParseSubscriptionConsumerRemoved(log) - case _FunctionsRegistry.abi.Events["SubscriptionCreated"].ID: - return _FunctionsRegistry.ParseSubscriptionCreated(log) - case _FunctionsRegistry.abi.Events["SubscriptionFunded"].ID: - return _FunctionsRegistry.ParseSubscriptionFunded(log) - case _FunctionsRegistry.abi.Events["SubscriptionOwnerTransferRequested"].ID: - return _FunctionsRegistry.ParseSubscriptionOwnerTransferRequested(log) - case _FunctionsRegistry.abi.Events["SubscriptionOwnerTransferred"].ID: - return _FunctionsRegistry.ParseSubscriptionOwnerTransferred(log) - case _FunctionsRegistry.abi.Events["Unpaused"].ID: - return _FunctionsRegistry.ParseUnpaused(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (FunctionsRegistryAuthorizedSendersChanged) Topic() common.Hash { - return common.HexToHash("0xf263cfb3e4298332e776194610cf9fdc09ccb3ada8b9aa39764d882e11fbf0a0") -} - -func (FunctionsRegistryBillingEnd) Topic() common.Hash { - return common.HexToHash("0xc8dc973332de19a5f71b6026983110e9c2e04b0c98b87eb771ccb78607fd114f") -} - -func (FunctionsRegistryBillingStart) Topic() common.Hash { - return common.HexToHash("0x99f7f4e65b4b9fbabd4e357c47ed3099b36e57ecd3a43e84662f34c207d0ebe4") -} - -func (FunctionsRegistryConfigSet) Topic() common.Hash { - return common.HexToHash("0x24d3d934adfef9b9029d6ffa463c07d0139ed47d26ee23506f85ece2879d2bd4") -} - -func (FunctionsRegistryFundsRecovered) Topic() common.Hash { - return common.HexToHash("0x59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600") -} - -func (FunctionsRegistryInitialized) Topic() common.Hash { - return common.HexToHash("0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498") -} - -func (FunctionsRegistryOwnershipTransferRequested) Topic() common.Hash { - return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") -} - -func (FunctionsRegistryOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") -} - -func (FunctionsRegistryPaused) Topic() common.Hash { - return common.HexToHash("0x62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258") -} - -func (FunctionsRegistryRequestTimedOut) Topic() common.Hash { - return common.HexToHash("0xf1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af414") -} - -func (FunctionsRegistrySubscriptionCanceled) Topic() common.Hash { - return common.HexToHash("0xe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815") -} - -func (FunctionsRegistrySubscriptionConsumerAdded) Topic() common.Hash { - return common.HexToHash("0x43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e0") -} - -func (FunctionsRegistrySubscriptionConsumerRemoved) Topic() common.Hash { - return common.HexToHash("0x182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b") -} - -func (FunctionsRegistrySubscriptionCreated) Topic() common.Hash { - return common.HexToHash("0x464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf") -} - -func (FunctionsRegistrySubscriptionFunded) Topic() common.Hash { - return common.HexToHash("0xd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8") -} - -func (FunctionsRegistrySubscriptionOwnerTransferRequested) Topic() common.Hash { - return common.HexToHash("0x69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be") -} - -func (FunctionsRegistrySubscriptionOwnerTransferred) Topic() common.Hash { - return common.HexToHash("0x6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0") -} - -func (FunctionsRegistryUnpaused) Topic() common.Hash { - return common.HexToHash("0x5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa") -} - -func (_FunctionsRegistry *FunctionsRegistry) Address() common.Address { - return _FunctionsRegistry.address -} - -type FunctionsRegistryInterface interface { - MAXCONSUMERS(opts *bind.CallOpts) (uint16, error) - - EstimateCost(opts *bind.CallOpts, gasLimit uint32, gasPrice *big.Int, donFee *big.Int, registryFee *big.Int) (*big.Int, error) - - GetAuthorizedSenders(opts *bind.CallOpts) ([]common.Address, error) - - GetConfig(opts *bind.CallOpts) (GetConfig, - - error) - - GetCurrentsubscriptionId(opts *bind.CallOpts) (uint64, error) - - GetRequestConfig(opts *bind.CallOpts) (uint32, []common.Address, error) - - GetRequiredFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRegistryRequestBilling) (*big.Int, error) - - GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) - - GetSubscriptionOwner(opts *bind.CallOpts, subscriptionId uint64) (common.Address, error) - - GetTotalBalance(opts *bind.CallOpts) (*big.Int, error) - - IsAuthorizedSender(opts *bind.CallOpts, sender common.Address) (bool, error) - - Owner(opts *bind.CallOpts) (common.Address, error) - - Paused(opts *bind.CallOpts) (bool, error) - - PendingRequestExists(opts *bind.CallOpts, subscriptionId uint64) (bool, error) - - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - - AcceptSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) - - AddConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) - - CancelSubscription(opts *bind.TransactOpts, subscriptionId uint64, to common.Address) (*types.Transaction, error) - - CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) - - FulfillAndBill(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte, transmitter common.Address, signers [31]common.Address, signerCount uint8, reportValidationGas *big.Int, initialGas *big.Int) (*types.Transaction, error) - - Initialize(opts *bind.TransactOpts, link common.Address, linkEthFeed common.Address, oracle common.Address) (*types.Transaction, error) - - OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) - - OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) - - OwnerCancelSubscription(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) - - Pause(opts *bind.TransactOpts) (*types.Transaction, error) - - RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - RemoveConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) - - RequestSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) - - SetAuthorizedSenders(opts *bind.TransactOpts, senders []common.Address) (*types.Transaction, error) - - SetConfig(opts *bind.TransactOpts, maxGasLimit uint32, stalenessSeconds uint32, gasAfterPaymentCalculation *big.Int, fallbackWeiPerUnitLink *big.Int, gasOverhead uint32, requestTimeoutSeconds uint32) (*types.Transaction, error) - - StartBilling(opts *bind.TransactOpts, data []byte, billing IFunctionsBillingRegistryRequestBilling) (*types.Transaction, error) - - TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) - - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - Unpause(opts *bind.TransactOpts) (*types.Transaction, error) - - FilterAuthorizedSendersChanged(opts *bind.FilterOpts) (*FunctionsRegistryAuthorizedSendersChangedIterator, error) - - WatchAuthorizedSendersChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryAuthorizedSendersChanged) (event.Subscription, error) - - ParseAuthorizedSendersChanged(log types.Log) (*FunctionsRegistryAuthorizedSendersChanged, error) - - FilterBillingEnd(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRegistryBillingEndIterator, error) - - WatchBillingEnd(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryBillingEnd, requestId [][32]byte) (event.Subscription, error) - - ParseBillingEnd(log types.Log) (*FunctionsRegistryBillingEnd, error) - - FilterBillingStart(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRegistryBillingStartIterator, error) - - WatchBillingStart(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryBillingStart, requestId [][32]byte) (event.Subscription, error) - - ParseBillingStart(log types.Log) (*FunctionsRegistryBillingStart, error) - - FilterConfigSet(opts *bind.FilterOpts) (*FunctionsRegistryConfigSetIterator, error) - - WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryConfigSet) (event.Subscription, error) - - ParseConfigSet(log types.Log) (*FunctionsRegistryConfigSet, error) - - FilterFundsRecovered(opts *bind.FilterOpts) (*FunctionsRegistryFundsRecoveredIterator, error) - - WatchFundsRecovered(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryFundsRecovered) (event.Subscription, error) - - ParseFundsRecovered(log types.Log) (*FunctionsRegistryFundsRecovered, error) - - FilterInitialized(opts *bind.FilterOpts) (*FunctionsRegistryInitializedIterator, error) - - WatchInitialized(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryInitialized) (event.Subscription, error) - - ParseInitialized(log types.Log) (*FunctionsRegistryInitialized, error) - - FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRegistryOwnershipTransferRequestedIterator, error) - - WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferRequested(log types.Log) (*FunctionsRegistryOwnershipTransferRequested, error) - - FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRegistryOwnershipTransferredIterator, error) - - WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferred(log types.Log) (*FunctionsRegistryOwnershipTransferred, error) - - FilterPaused(opts *bind.FilterOpts) (*FunctionsRegistryPausedIterator, error) - - WatchPaused(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryPaused) (event.Subscription, error) - - ParsePaused(log types.Log) (*FunctionsRegistryPaused, error) - - FilterRequestTimedOut(opts *bind.FilterOpts, requestId [][32]byte) (*FunctionsRegistryRequestTimedOutIterator, error) - - WatchRequestTimedOut(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryRequestTimedOut, requestId [][32]byte) (event.Subscription, error) - - ParseRequestTimedOut(log types.Log) (*FunctionsRegistryRequestTimedOut, error) - - FilterSubscriptionCanceled(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionCanceledIterator, error) - - WatchSubscriptionCanceled(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionCanceled, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionCanceled(log types.Log) (*FunctionsRegistrySubscriptionCanceled, error) - - FilterSubscriptionConsumerAdded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionConsumerAddedIterator, error) - - WatchSubscriptionConsumerAdded(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionConsumerAdded, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionConsumerAdded(log types.Log) (*FunctionsRegistrySubscriptionConsumerAdded, error) - - FilterSubscriptionConsumerRemoved(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionConsumerRemovedIterator, error) - - WatchSubscriptionConsumerRemoved(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionConsumerRemoved, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionConsumerRemoved(log types.Log) (*FunctionsRegistrySubscriptionConsumerRemoved, error) - - FilterSubscriptionCreated(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionCreatedIterator, error) - - WatchSubscriptionCreated(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionCreated, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionCreated(log types.Log) (*FunctionsRegistrySubscriptionCreated, error) - - FilterSubscriptionFunded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionFundedIterator, error) - - WatchSubscriptionFunded(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionFunded, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionFunded(log types.Log) (*FunctionsRegistrySubscriptionFunded, error) - - FilterSubscriptionOwnerTransferRequested(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionOwnerTransferRequestedIterator, error) - - WatchSubscriptionOwnerTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionOwnerTransferRequested, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionOwnerTransferRequested(log types.Log) (*FunctionsRegistrySubscriptionOwnerTransferRequested, error) - - FilterSubscriptionOwnerTransferred(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRegistrySubscriptionOwnerTransferredIterator, error) - - WatchSubscriptionOwnerTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRegistrySubscriptionOwnerTransferred, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionOwnerTransferred(log types.Log) (*FunctionsRegistrySubscriptionOwnerTransferred, error) - - FilterUnpaused(opts *bind.FilterOpts) (*FunctionsRegistryUnpausedIterator, error) - - WatchUnpaused(opts *bind.WatchOpts, sink chan<- *FunctionsRegistryUnpaused) (event.Subscription, error) - - ParseUnpaused(log types.Log) (*FunctionsRegistryUnpaused, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/functions_router/functions_router.go b/core/gethwrappers/generated/functions_router/functions_router.go deleted file mode 100644 index c90c1071106..00000000000 --- a/core/gethwrappers/generated/functions_router/functions_router.go +++ /dev/null @@ -1,3839 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package functions_router - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"ReservedLabel\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"fromHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"major\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minor\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"patch\",\"type\":\"uint16\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"name\":\"RequestEnd\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutFulfillment\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfigHash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"config\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bool\",\"name\":\"useProposed\",\"type\":\"bool\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"routeDestination\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetFromAddresses\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetToAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"requestIdsToTimeout\",\"type\":\"bytes32[]\"}],\"name\":\"timeoutRequests\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"togglePaused\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"validateProposedContracts\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"version\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60806040526001805463ffffffff60a01b191690553480156200002157600080fd5b50604051620063f0380380620063f083398101604081905262000044916200030d565b6000805460ff1916815582903390869086908590849081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000e757620000e78162000198565b50506008805461ffff84811661ffff1991871662010000029190911663ffffffff19909216919091171790556000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b0319163017905562000158816200024a565b8051602090910120600b555050600c80546001600160a01b0390931661010002610100600160a81b031990931692909217909155506200049c9350505050565b6001600160a01b038116331415620001f35760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808280602001905181019062000263919062000430565b6040805180820182526001600160601b0384168082526001600160e01b031984166020928301819052601280546001600160801b03191683176c0100000000000000000000000060e088901c021790558351918252918101919091529294509092507fb2b9bfb736b0bfef266985352cfca2a114226362209f5a6e5a2a2ed14383ba57910160405180910390a1505050565b805161ffff811681146200030857600080fd5b919050565b600080600080608085870312156200032457600080fd5b6200032f85620002f5565b9350602062000340818701620002f5565b60408701519094506001600160a01b03811681146200035e57600080fd5b60608701519093506001600160401b03808211156200037c57600080fd5b818801915088601f8301126200039157600080fd5b815181811115620003a657620003a662000486565b604051601f8201601f19908116603f01168101908382118183101715620003d157620003d162000486565b816040528281528b86848701011115620003ea57600080fd5b600093505b828410156200040e5784840186015181850187015292850192620003ef565b82841115620004205760008684830101525b989b979a50959850505050505050565b600080604083850312156200044457600080fd5b82516001600160601b03811681146200045c57600080fd5b60208401519092506001600160e01b0319811681146200047b57600080fd5b809150509250929050565b634e487b7160e01b600052604160045260246000fd5b615f4480620004ac6000396000f3fe608060405234801561001057600080fd5b50600436106102ad5760003560e01c806379ba50971161017b578063b187bd26116100d8578063d7ae1d301161008c578063e82ad7d411610071578063e82ad7d4146106e7578063eb523d6c146106fa578063f2fde38b1461070d57600080fd5b8063d7ae1d30146106c1578063e72f6e30146106d457600080fd5b8063b734c0f4116100bd578063b734c0f41461068e578063badc3eb614610696578063c4614d61146106ae57600080fd5b8063b187bd2614610670578063b56438581461067b57600080fd5b80639f87fad71161012f578063a47c769611610114578063a47c769614610626578063a4c0ed361461064a578063a9c9a9181461065d57600080fd5b80639f87fad71461060b578063a21a23e41461061e57600080fd5b80638da5cb5b116101605780638da5cb5b146105d85780638fde5317146105fb5780639883c10d1461060357600080fd5b806379ba5097146105bd57806382359740146105c557600080fd5b8063461d27621161022957806366419970116101dd578063674603d0116101c2578063674603d0146104dd5780636a6df79b146105725780637341c10c146105aa57600080fd5b8063664199701461048a578063665871ec146104ca57600080fd5b80635c975abb1161020e5780635c975abb1461044557806364d51a2a1461045c57806366316d8d1461047757600080fd5b8063461d2762146103cd57806354fd4d50146103ee57600080fd5b80631e9fb8cd1161028057806336566f061161026557806336566f0614610379578063385de9ae146103815780633fd67e051461039457600080fd5b80631e9fb8cd146103505780632a905ccc1461036357600080fd5b806302bcc5b6146102b257806304c357cb146102c757806312b58349146102da578063181f5a771461030e575b600080fd5b6102c56102c03660046155dc565b610720565b005b6102c56102d53660046155f7565b6107a0565b600d546bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f46756e6374696f6e7320526f757465722076310000000000000000000000000060208201525b6040516103059190615a35565b6102c561035e366004615339565b61098e565b6012546bffffffffffffffffffffffff166102ec565b6102c5610b1d565b6102c561038f366004615491565b610b42565b6103a76103a23660046154dd565b610d8e565b6040805160ff90931683526bffffffffffffffffffffffff909116602083015201610305565b6103e06103db366004615623565b61106f565b604051908152602001610305565b600180546040805192835261ffff7401000000000000000000000000000000000000000083048116602085015276010000000000000000000000000000000000000000000090920490911690820152606001610305565b60005460ff165b6040519015158152602001610305565b610464606481565b60405161ffff9091168152602001610305565b6102c561048536600461528b565b61110b565b600c547501000000000000000000000000000000000000000000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610305565b6102c56104d83660046152c4565b611378565b61054a6104eb366004615256565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600f6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610305565b61058561058036600461546c565b611861565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610305565b6102c56105b83660046155f7565b611874565b6102c5611b00565b6102c56105d33660046155dc565b611c22565b600054610100900473ffffffffffffffffffffffffffffffffffffffff16610585565b6102c5611e18565b600b546103e0565b6102c56106193660046155f7565b611e9c565b6104b16123a0565b6106396106343660046155dc565b6125d3565b604051610305959493929190615b94565b6102c56106583660046151fa565b6126c1565b61058561066b36600461543a565b61291d565b60005460ff1661044c565b6102c56106893660046155c1565b612930565b6102c5612a4a565b61069e612d3f565b6040516103059493929190615ad2565b6103436106bc366004615491565b612e8c565b6102c56106cf3660046155f7565b612ea1565b6102c56106e23660046151dd565b613083565b61044c6106f53660046155dc565b6132a9565b6102c561070836600461543a565b6133fa565b6102c561071b3660046151dd565b6136ae565b6107286136bf565b67ffffffffffffffff81166000908152600e602052604090206001015473ffffffffffffffffffffffffffffffffffffffff1680610792576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61079c8282613745565b5050565b67ffffffffffffffff82166000908152600e6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff168061080c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610878576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024015b60405180910390fd5b600c5460ff16156108b5576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff84166000908152600e602052604090206002015473ffffffffffffffffffffffffffffffffffffffff8481169116146109885767ffffffffffffffff84166000818152600e602090815260409182902060020180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff88169081179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b50505050565b6109966136bf565b6109a1838383613b60565b6008546000906109bb9062010000900461ffff1643615c82565b604080516080810182528681526020808201879052918101859052606081018390528651929350916003916109f4918391890190614ee5565b506020828101518051610a0d9260018501920190614f2c565b5060408201518051610a29916002840191602090910190614f2c565b506060820151816003015590505060005b84518160ff161015610b16577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858260ff1681518110610a7c57610a7c615e8f565b6020026020010151858360ff1681518110610a9957610a99615e8f565b6020026020010151858460ff1681518110610ab657610ab6615e8f565b602002602001015185604051610afc949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a180610b0e81615e11565b915050610a3a565b5050505050565b610b256136bf565b60005460ff1615610b3a57610b38613e4f565b565b610b38613ecc565b610b4a6136bf565b60008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff1680610ba9576040517f80833e330000000000000000000000000000000000000000000000000000000081526004810185905260240161086f565b600073ffffffffffffffffffffffffffffffffffffffff8216301415610bd25750600b54610c55565b8173ffffffffffffffffffffffffffffffffffffffff16639883c10d6040518163ffffffff1660e01b8152600401602060405180830381600087803b158015610c1a57600080fd5b505af1158015610c2e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c529190615453565b90505b8383604051610c65929190615913565b6040518091039020811415610ca6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b604051806060016040528082815260200185858080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250505090825250600854602090910190610d0d9062010000900461ffff1643615c82565b90526000868152600760209081526040909120825181558282015180519192610d3e92600185019290910190614fa6565b50604091820151600290910155517f0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf90610d7f908790849088908890615987565b60405180910390a15050505050565b600c54600090819060ff1615610dd0576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600088815260116020908152604091829020825161010081018452815473ffffffffffffffffffffffffffffffffffffffff9081168252600183015490811693820184905274010000000000000000000000000000000000000000810467ffffffffffffffff16948201949094527c010000000000000000000000000000000000000000000000000000000090930463ffffffff16606084015260028101546bffffffffffffffffffffffff9081166080850152600382015460a0850152600482015460c08501526005909101541660e0830152610eb2576002925050611064565b805173ffffffffffffffffffffffffffffffffffffffff163314610f02576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610f2081608001518260c001518360e0015184606001518a8a613f27565b60008a8152601160209081526040822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018390556002810180547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000090811690915560038201849055600482018490556005909101805490911690556060840151908401519295509091610fc1918c918c918c91613fad565b8051909150610fd1576001610fd4565b60005b93506000610ffb8360400151846080015185602001518660e001518c87602001518d61412b565b9050826040015167ffffffffffffffff168b7f526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b0520836020015189898760000151611044578e611046565b8f5b6040516110569493929190615b48565b60405180910390a351925050505b965096945050505050565b600c5460009060ff16156110af576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6110b761439a565b6110fe8260008989898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a91506144079050565b90505b9695505050505050565b600c5460ff1615611148576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6bffffffffffffffffffffffff811661118d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152601060205260409020546bffffffffffffffffffffffff808316911610156111e7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260106020526040812080548392906112149084906bffffffffffffffffffffffff16615d2f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600d60008282829054906101000a90046bffffffffffffffffffffffff1661126b9190615d2f565b82546bffffffffffffffffffffffff91821661010093840a9081029083021990911617909255600c546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301529386166024820152919004909116915063a9059cbb90604401602060405180830381600087803b15801561130a57600080fd5b505af115801561131e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611342919061541d565b61079c576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c5460ff16156113b5576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8181101561185c5760008383838181106113d4576113d4615e8f565b602090810292909201356000818152601184526040808220815161010081018352815473ffffffffffffffffffffffffffffffffffffffff908116825260018301549081169782019790975274010000000000000000000000000000000000000000870467ffffffffffffffff168184018190527c010000000000000000000000000000000000000000000000000000000090970463ffffffff16606082015260028201546bffffffffffffffffffffffff9081166080830152600383015460a083015260048084015460c08401526005909301541660e082015291517fa47c7696000000000000000000000000000000000000000000000000000000008152908101959095529194509092909150309063a47c76969060240160006040518083038186803b15801561150657600080fd5b505afa15801561151a573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526115609190810190615764565b5050925050508073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146115e3576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8216600482015260240161086f565b8160a00151421015611621576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810185905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf90602401602060405180830381600087803b15801561168b57600080fd5b505af115801561169f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116c3919061541d565b1561184557608083015160408085015167ffffffffffffffff166000908152600e602052208054600c906117169084906c0100000000000000000000000090046bffffffffffffffffffffffff16615d2f565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060208084015173ffffffffffffffffffffffffffffffffffffffff166000908152600f825260408082208187015167ffffffffffffffff908116845293529020805460019260099161179f9185916901000000000000000000900416615c9a565b825467ffffffffffffffff9182166101009390930a928302919092021990911617905550600084815260116020526040812080547fffffffffffffffffffffffff0000000000000000000000000000000000000000168155600181018290556002810180547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000908116909155600382018390556004820192909255600501805490911690555b50505050808061185490615db0565b9150506113b8565b505050565b600061186d8383614816565b9392505050565b67ffffffffffffffff82166000908152600e6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff16806118e0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611947576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8216600482015260240161086f565b600c5460ff1615611984576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff84166000908152600e6020526040902060030154606414156119db576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f6020908152604080832067ffffffffffffffff8816845290915290205460ff16151560011415611a2857610988565b73ffffffffffffffffffffffffffffffffffffffff83166000818152600f6020908152604080832067ffffffffffffffff891680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600e84528285206003018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e0910161097f565b60015473ffffffffffffffffffffffffffffffffffffffff163314611b81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161086f565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600c5460ff1615611c5f576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600e602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16611cc8576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600e602052604090206002015473ffffffffffffffffffffffffffffffffffffffff163314611d6a5767ffffffffffffffff81166000908152600e6020526040908190206002015490517fd084e97500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909116600482015260240161086f565b67ffffffffffffffff81166000818152600e60209081526040918290206001810180547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560029093018054909316909255835173ffffffffffffffffffffffffffffffffffffffff909216808352928201529092917f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a25050565b611e206136bf565b600a54431015611e5c576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600954600880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000ffff16620100009283900461ffff16909202919091179055565b67ffffffffffffffff82166000908152600e6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff1680611f08576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611f6f576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8216600482015260240161086f565b600c5460ff1615611fac576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600f6020908152604080832067ffffffffffffffff8089168552908352928190208151606081018352905460ff811615158083526101008204861694830194909452690100000000000000000090049093169083015261207c576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8616600482015273ffffffffffffffffffffffffffffffffffffffff8516602482015260440161086f565b806040015167ffffffffffffffff16816020015167ffffffffffffffff16146120d1576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff85166000908152600e602090815260408083206003018054825181850281018501909352808352919290919083018282801561214c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612121575b505050505090506000600182516121639190615d18565b905060005b8251811015612302578673ffffffffffffffffffffffffffffffffffffffff1683828151811061219a5761219a615e8f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1614156122f05760008383815181106121d2576121d2615e8f565b6020026020010151905080600e60008b67ffffffffffffffff1667ffffffffffffffff168152602001908152602001600020600301838154811061221857612218615e8f565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff8b168152600e9091526040902060030180548061229257612292615e60565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550612302565b806122fa81615db0565b915050612168565b5073ffffffffffffffffffffffffffffffffffffffff86166000818152600f6020908152604080832067ffffffffffffffff8c168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a250505050505050565b600c5460009060ff16156123e0576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c80547501000000000000000000000000000000000000000000900467ffffffffffffffff1690601561241383615de9565b82546101009290920a67ffffffffffffffff818102199093169183160217909155600c547501000000000000000000000000000000000000000000900416905060008060405190808252806020026020018201604052801561247f578160200160208202803683370190505b506040805160a0810182526000808252602080830182815233848601908152606085018481526080860188815267ffffffffffffffff8b168652600e8552969094208551815493516bffffffffffffffffffffffff9081166c01000000000000000000000000027fffffffffffffffff0000000000000000000000000000000000000000000000009095169116179290921782555160018201805473ffffffffffffffffffffffffffffffffffffffff9283167fffffffffffffffffffffffff000000000000000000000000000000000000000091821617909155935160028301805491909216941693909317909255925180519495509193909261258b926003850192910190614f2c565b505060405133815267ffffffffffffffff841691507f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a250905090565b60008060008060606125e486614946565b67ffffffffffffffff86166000908152600e6020908152604091829020805460018201546002830154600390930180548651818702810187019097528087526bffffffffffffffffffffffff8085169c506c01000000000000000000000000909404909316995073ffffffffffffffffffffffffffffffffffffffff91821698509216955090918301828280156126b157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612686575b5050505050905091939590929450565b600c5460ff16156126fe576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c54610100900473ffffffffffffffffffffffffffffffffffffffff163314612754576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461278e576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061279c828401846155dc565b67ffffffffffffffff81166000908152600e602052604090206001015490915073ffffffffffffffffffffffffffffffffffffffff16612808576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600e6020526040812080546bffffffffffffffffffffffff169186919061283f8385615cbd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600d60008282829054906101000a90046bffffffffffffffffffffffff166128969190615cbd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846128fd9190615c82565b6040805192835260208301919091520160405180910390a2505050505050565b600061292a826000614816565b92915050565b6129386136bf565b60085461ffff82811662010000909204161415612981576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60085461ffff90811690821611156129c5576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260085461ffff620100009091048116808352908416602083015290918201906129f89043615c82565b9052805160098054602084015161ffff90811662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000090921693169290921791909117905560400151600a5550565b612a526136bf565b600654431015612a8e576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160149054906101000a900461ffff166001612aab9190615c5c565b600180547fffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffff167401000000000000000000000000000000000000000061ffff93841602179081905576010000000000000000000000000000000000000000000090041615612b3c57600180547fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff1690555b60005b60035460ff82161015612d3c576005805460ff8316908110612b6357612b63615e8f565b60009182526020822001546003805473ffffffffffffffffffffffffffffffffffffffff9092169260029290919060ff8616908110612ba457612ba4615e8f565b9060005260206000200154815260200190815260200160002060006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff1602179055507ff17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e960036000018260ff1681548110612c3557612c35615e8f565b906000526020600020015460036001018360ff1681548110612c5957612c59615e8f565b6000918252602090912001546005805473ffffffffffffffffffffffffffffffffffffffff9092169160ff8616908110612c9557612c95615e8f565b60009182526020918290200154600180546040805196875273ffffffffffffffffffffffffffffffffffffffff958616948701949094529390911691840191909152606083015261ffff740100000000000000000000000000000000000000008204811660808401527601000000000000000000000000000000000000000000009091041660a082015260c00160405180910390a180612d3481615e11565b915050612b3f565b50565b60006060806060600380015460036000016003600101600360020182805480602002602001604051908101604052809291908181526020018280548015612da557602002820191906000526020600020905b815481526020019060010190808311612d91575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015612e0e57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612de3575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612e7757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e4c575b50505050509050935093509350935090919293565b6060612e998484846149af565b949350505050565b67ffffffffffffffff82166000908152600e6020526040902060010154829073ffffffffffffffffffffffffffffffffffffffff1680612f0d576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612f74576040517fd8a3fb5200000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8216600482015260240161086f565b600c5460ff1615612fb1576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517fe82ad7d400000000000000000000000000000000000000000000000000000000815267ffffffffffffffff85166004820152309063e82ad7d49060240160206040518083038186803b15801561300a57600080fd5b505afa15801561301e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613042919061541d565b15613079576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109888484613745565b61308b6136bf565b600c546040517f70a08231000000000000000000000000000000000000000000000000000000008152306004820152600091610100900473ffffffffffffffffffffffffffffffffffffffff16906370a082319060240160206040518083038186803b1580156130fa57600080fd5b505afa15801561310e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131329190615453565b600d549091506bffffffffffffffffffffffff168181111561318a576040517fa99da302000000000000000000000000000000000000000000000000000000008152600481018290526024810183905260440161086f565b8181101561185c57600061319e8284615d18565b600c546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8781166004830152602482018490529293506101009091049091169063a9059cbb90604401602060405180830381600087803b15801561321b57600080fd5b505af115801561322f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613253919061541d565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff81166000908152600e602090815260408083206003018054825181850281018501909352808352849383018282801561332157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116132f6575b5050505050905060005b81518110156133f0576000600f600084848151811061334c5761334c615e8f565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146133dd57506001949350505050565b50806133e881615db0565b91505061332b565b5060009392505050565b6134026136bf565b600081815260026020908152604080832054600783528184208251606081019093528054835260018101805473ffffffffffffffffffffffffffffffffffffffff909316959491929184019161345790615d5c565b80601f016020809104026020016040519081016040528092919081815260200182805461348390615d5c565b80156134d05780601f106134a5576101008083540402835291602001916134d0565b820191906000526020600020905b8154815290600101906020018083116134b357829003601f168201915b5050505050815260200160028201548152505090508060400151431015613523576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82613548576135358160200151614a7e565b6020808201518051910120600b556135ff565b60208101516040517f354497aa00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84169163354497aa9161359e9190600401615a35565b600060405180830381600087803b1580156135b857600080fd5b505af19250505080156135c9575060015b6135ff576040517ffe680b2600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600160169054906101000a900461ffff16600161361c9190615c5c565b6001805461ffff92909216760100000000000000000000000000000000000000000000027fffffffffffffffff0000ffffffffffffffffffffffffffffffffffffffffffff909216919091179055805160208201516040517fc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47926136a19287926159e2565b60405180910390a1505050565b6136b66136bf565b612d3c81614b54565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610b38576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161086f565b600c5460ff1615613782576040517fed3ba6a600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600e60209081526040808320815160a08101835281546bffffffffffffffffffffffff80821683526c010000000000000000000000009091041681850152600182015473ffffffffffffffffffffffffffffffffffffffff90811682850152600283015416606082015260038201805484518187028101870190955280855291949293608086019390929083018282801561386357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613838575b5050509190925250505067ffffffffffffffff84166000908152600e60205260408120549192506bffffffffffffffffffffffff909116905b82608001515181101561394257600f6000846080015183815181106138c3576138c3615e8f565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690558061393a81615db0565b91505061389c565b5067ffffffffffffffff84166000908152600e6020526040812080547fffffffffffffffff0000000000000000000000000000000000000000000000001681556001810180547fffffffffffffffffffffffff00000000000000000000000000000000000000009081169091556002820180549091169055906139c86003830182615019565b5050600d80548291906000906139ed9084906bffffffffffffffffffffffff16615d2f565b82546bffffffffffffffffffffffff91821661010093840a9081029083021990911617909255600c546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8881166004830152938616602482015291900491909116915063a9059cbb90604401602060405180830381600087803b158015613a8d57600080fd5b505af1158015613aa1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ac5919061541d565b613afb576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910161097f565b81518351141580613b7357508051835114155b15613baa576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b825160081015613be6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b83518160ff16101561098857600073ffffffffffffffffffffffffffffffffffffffff16828260ff1681518110613c2257613c22615e8f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff161415613c78576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160ff1681518110613c8d57613c8d615e8f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1660026000868460ff1681518110613cc457613cc4615e8f565b60209081029190910181015182528101919091526040016000205473ffffffffffffffffffffffffffffffffffffffff161415613d2d576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b828160ff1681518110613d4257613d42615e8f565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1660026000868460ff1681518110613d7957613d79615e8f565b60209081029190910181015182528101919091526040016000205473ffffffffffffffffffffffffffffffffffffffff1614613de1576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000801b848260ff1681518110613dfa57613dfa615e8f565b60200260200101511415613e3d576040517f7ee392220000000000000000000000000000000000000000000000000000000081526000600482015260240161086f565b80613e4781615e11565b915050613be9565b613e57614c50565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b613ed461439a565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613ea23390565b6000613f398663ffffffff8616615c82565b5a1015613f4857506003611101565b866bffffffffffffffffffffffff16613f668563ffffffff16614cbc565b613f709085615ce4565b613f7a8488615cbd565b613f849190615cbd565b6bffffffffffffffffffffffff161115613fa057506004611101565b5060009695505050505050565b60408051808201909152600080825260208201526012546040516000916c01000000000000000000000000900460e01b90613ff090899089908990602401615a0a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152600c80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590506000805a6113888110156140ad57600080fd5b6113888103905086604082048203116140c557600080fd5b853b6140d057600080fd5b60008085516020870160008a8cf192505a600c80547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556040805180820190915293151584529003602083015250979650505050505050565b6040805180820190915260008082526020820152600061414a84614cbc565b6141549086615ce4565b905060006141628482615cbd565b905061416e8782615cbd565b905061417a8282615cbd565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600e9091529283208054929750939450849392916141d191859116615d2f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550818461420b9190615cbd565b33600090815260106020526040812080549091906142389084906bffffffffffffffffffffffff16615cbd565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260106020526040812080548b9450909261427f91859116615cbd565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600e6020526040902080548c93509091600c916142e39185916c01000000000000000000000000900416615d2f565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600f6020908152604080832067ffffffffffffffff808f168552925290912080546001926009916143679185916901000000000000000000900416615c9a565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b60005460ff1615610b38576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015260640161086f565b600061441285614946565b61441c3386614d5e565b60006144288888614816565b6040805160c08101825267ffffffffffffffff891680825260208083018a905261ffff89168385015263ffffffff881660608401523360808401526000918252600e90528281206001015473ffffffffffffffffffffffffffffffffffffffff90811660a084015292517f0a33e0a5000000000000000000000000000000000000000000000000000000008152939450928392839290861691630a33e0a5916144d391600401615a48565b608060405180830381600087803b1580156144ed57600080fd5b505af1158015614501573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906145259190615583565b9297509094509250905061453a338a85614dfa565b6040518061010001604052808573ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018a67ffffffffffffffff1681526020018763ffffffff168152602001846bffffffffffffffffffffffff16815260200182426145ba9190615c82565b8152602001838152602001601260000160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152506011600087815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160010160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160146101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550606082015181600101601c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160020160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060a0820151816003015560c0820151816004015560e08201518160050160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055509050508867ffffffffffffffff168b867f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54600e60008e67ffffffffffffffff1667ffffffffffffffff16815260200190815260200160002060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1633328e8e8e60405161480096959493929190615923565b60405180910390a4505050509695505050505050565b6000816148835760008381526002602052604090205473ffffffffffffffffffffffffffffffffffffffff168061487c576040517f80833e330000000000000000000000000000000000000000000000000000000081526004810185905260240161086f565b905061292a565b60005b60035460ff82161015614910576003805460ff83169081106148aa576148aa615e8f565b90600052602060002001548414156148fe576005805460ff83169081106148d3576148d3615e8f565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16915061292a9050565b8061490881615e11565b915050614886565b506040517f80833e330000000000000000000000000000000000000000000000000000000081526004810184905260240161086f565b67ffffffffffffffff81166000908152600e602052604090206001015473ffffffffffffffffffffffffffffffffffffffff16612d3c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b606060008080806149c2868801886156a1565b935093509350935060006149db89600187878787614407565b60408051602080825281830190925291925060208201818036833701905050955060005b6020811015614a7157818160208110614a1a57614a1a615e8f565b1a60f81b878281518110614a3057614a30615e8f565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535080614a6981615db0565b9150506149ff565b5050505050509392505050565b60008082806020019051810190614a959190615710565b6040805180820182526bffffffffffffffffffffffff84168082527fffffffff0000000000000000000000000000000000000000000000000000000084166020928301819052601280547fffffffffffffffffffffffffffffffff000000000000000000000000000000001683176c0100000000000000000000000060e088901c021790558351918252918101919091529294509092507fb2b9bfb736b0bfef266985352cfca2a114226362209f5a6e5a2a2ed14383ba5791016136a1565b73ffffffffffffffffffffffffffffffffffffffff8116331415614bd4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161086f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610b38576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015260640161086f565b60006bffffffffffffffffffffffff821115614d5a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f3620626974730000000000000000000000000000000000000000000000000000606482015260840161086f565b5090565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600f6020908152604080832067ffffffffffffffff8516845290915290205460ff1661079c576040517ff0019fe600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8216600482015273ffffffffffffffffffffffffffffffffffffffff8316602482015260440161086f565b67ffffffffffffffff82166000908152600e602052604090208054829190600c90614e449084906c0100000000000000000000000090046bffffffffffffffffffffffff16615cbd565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600f6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614eba928492900416615c9a565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b828054828255906000526020600020908101928215614f20579160200282015b82811115614f20578251825591602001919060010190614f05565b50614d5a929150615033565b828054828255906000526020600020908101928215614f20579160200282015b82811115614f2057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614f4c565b828054614fb290615d5c565b90600052602060002090601f016020900481019282614fd45760008555614f20565b82601f10614fed57805160ff1916838001178555614f20565b82800160010185558215614f205791820182811115614f20578251825591602001919060010190614f05565b5080546000825590600052602060002090810190612d3c91905b5b80821115614d5a5760008155600101615034565b600082601f83011261505957600080fd5b8135602061506e61506983615c38565b615be9565b80838252828201915082860187848660051b890101111561508e57600080fd5b60005b858110156150b65781356150a481615eed565b84529284019290840190600101615091565b5090979650505050505050565b60008083601f8401126150d557600080fd5b50813567ffffffffffffffff8111156150ed57600080fd5b60208301915083602082850101111561510557600080fd5b9250929050565b600082601f83011261511d57600080fd5b813567ffffffffffffffff81111561513757615137615ebe565b61516860207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601615be9565b81815284602083860101111561517d57600080fd5b816020850160208301376000918101602001919091529392505050565b803561ffff811681146151ac57600080fd5b919050565b803563ffffffff811681146151ac57600080fd5b803567ffffffffffffffff811681146151ac57600080fd5b6000602082840312156151ef57600080fd5b813561186d81615eed565b6000806000806060858703121561521057600080fd5b843561521b81615eed565b935060208501359250604085013567ffffffffffffffff81111561523e57600080fd5b61524a878288016150c3565b95989497509550505050565b6000806040838503121561526957600080fd5b823561527481615eed565b9150615282602084016151c5565b90509250929050565b6000806040838503121561529e57600080fd5b82356152a981615eed565b915060208301356152b981615f1d565b809150509250929050565b600080602083850312156152d757600080fd5b823567ffffffffffffffff808211156152ef57600080fd5b818501915085601f83011261530357600080fd5b81358181111561531257600080fd5b8660208260051b850101111561532757600080fd5b60209290920196919550909350505050565b60008060006060848603121561534e57600080fd5b833567ffffffffffffffff8082111561536657600080fd5b818601915086601f83011261537a57600080fd5b8135602061538a61506983615c38565b8083825282820191508286018b848660051b89010111156153aa57600080fd5b600096505b848710156153cd5780358352600196909601959183019183016153af565b50975050870135925050808211156153e457600080fd5b6153f087838801615048565b9350604086013591508082111561540657600080fd5b5061541386828701615048565b9150509250925092565b60006020828403121561542f57600080fd5b815161186d81615f0f565b60006020828403121561544c57600080fd5b5035919050565b60006020828403121561546557600080fd5b5051919050565b6000806040838503121561547f57600080fd5b8235915060208301356152b981615f0f565b6000806000604084860312156154a657600080fd5b83359250602084013567ffffffffffffffff8111156154c457600080fd5b6154d0868287016150c3565b9497909650939450505050565b60008060008060008060c087890312156154f657600080fd5b86359550602087013567ffffffffffffffff8082111561551557600080fd5b6155218a838b0161510c565b9650604089013591508082111561553757600080fd5b5061554489828a0161510c565b945050606087013561555581615f1d565b9250608087013561556581615f1d565b915060a087013561557581615eed565b809150509295509295509295565b6000806000806080858703121561559957600080fd5b8451935060208501516155ab81615f1d565b6040860151606090960151949790965092505050565b6000602082840312156155d357600080fd5b61186d8261519a565b6000602082840312156155ee57600080fd5b61186d826151c5565b6000806040838503121561560a57600080fd5b615613836151c5565b915060208301356152b981615eed565b60008060008060008060a0878903121561563c57600080fd5b615645876151c5565b9550602087013567ffffffffffffffff81111561566157600080fd5b61566d89828a016150c3565b909650945061568090506040880161519a565b925061568e606088016151b1565b9150608087013590509295509295509295565b600080600080608085870312156156b757600080fd5b6156c0856151c5565b9350602085013567ffffffffffffffff8111156156dc57600080fd5b6156e88782880161510c565b9350506156f76040860161519a565b9150615705606086016151b1565b905092959194509250565b6000806040838503121561572357600080fd5b825161572e81615f1d565b60208401519092507fffffffff00000000000000000000000000000000000000000000000000000000811681146152b957600080fd5b600080600080600060a0868803121561577c57600080fd5b855161578781615f1d565b8095505060208087015161579a81615f1d565b60408801519095506157ab81615eed565b60608801519094506157bc81615eed565b608088015190935067ffffffffffffffff8111156157d957600080fd5b8701601f810189136157ea57600080fd5b80516157f861506982615c38565b8082825284820191508484018c868560051b870101111561581857600080fd5b600094505b8385101561584457805161583081615eed565b83526001949094019391850191850161581d565b5080955050505050509295509295909350565b600081518084526020808501945080840160005b8381101561589d57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161586b565b509495945050505050565b6000815180845260005b818110156158ce576020818501810151868301820152016158b2565b818111156158e0576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b8183823760009101908152919050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c0606083015261596460c08301866158a8565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b84815283602082015260606040820152816060820152818360808301376000818301608090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01601019392505050565b838152826020820152606060408201526000615a0160608301846158a8565b95945050505050565b838152606060208201526000615a2360608301856158a8565b828103604084015261110181856158a8565b60208152600061186d60208301846158a8565b6020815267ffffffffffffffff82511660208201526000602083015160c06040840152615a7860e08401826158a8565b905061ffff604085015116606084015263ffffffff6060850151166080840152608084015173ffffffffffffffffffffffffffffffffffffffff80821660a08601528060a08701511660c086015250508091505092915050565b600060808201868352602060808185015281875180845260a086019150828901935060005b81811015615b1357845183529383019391830191600101615af7565b50508481036040860152615b278188615857565b925050508281036060840152615b3d8185615857565b979650505050505050565b6bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff8416602082015260ff8316604082015260806060820152600061110160808301846158a8565b6bffffffffffffffffffffffff86811682528516602082015273ffffffffffffffffffffffffffffffffffffffff84811660408301528316606082015260a0608082018190526000906110fe90830184615857565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715615c3057615c30615ebe565b604052919050565b600067ffffffffffffffff821115615c5257615c52615ebe565b5060051b60200190565b600061ffff808316818516808303821115615c7957615c79615e31565b01949350505050565b60008219821115615c9557615c95615e31565b500190565b600067ffffffffffffffff808316818516808303821115615c7957615c79615e31565b60006bffffffffffffffffffffffff808316818516808303821115615c7957615c79615e31565b60006bffffffffffffffffffffffff80831681851681830481118215151615615d0f57615d0f615e31565b02949350505050565b600082821015615d2a57615d2a615e31565b500390565b60006bffffffffffffffffffffffff83811690831681811015615d5457615d54615e31565b039392505050565b600181811c90821680615d7057607f821691505b60208210811415615daa577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415615de257615de2615e31565b5060010190565b600067ffffffffffffffff80831681811415615e0757615e07615e31565b6001019392505050565b600060ff821660ff811415615e2857615e28615e31565b60010192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff81168114612d3c57600080fd5b8015158114612d3c57600080fd5b6bffffffffffffffffffffffff81168114612d3c57600080fdfea164736f6c6343000806000a", -} - -var FunctionsRouterABI = FunctionsRouterMetaData.ABI - -var FunctionsRouterBin = FunctionsRouterMetaData.Bin - -func DeployFunctionsRouter(auth *bind.TransactOpts, backend bind.ContractBackend, timelockBlocks uint16, maximumTimelockBlocks uint16, linkToken common.Address, config []byte) (common.Address, *types.Transaction, *FunctionsRouter, error) { - parsed, err := FunctionsRouterMetaData.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(FunctionsRouterBin), backend, timelockBlocks, maximumTimelockBlocks, linkToken, config) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &FunctionsRouter{FunctionsRouterCaller: FunctionsRouterCaller{contract: contract}, FunctionsRouterTransactor: FunctionsRouterTransactor{contract: contract}, FunctionsRouterFilterer: FunctionsRouterFilterer{contract: contract}}, nil -} - -type FunctionsRouter struct { - address common.Address - abi abi.ABI - FunctionsRouterCaller - FunctionsRouterTransactor - FunctionsRouterFilterer -} - -type FunctionsRouterCaller struct { - contract *bind.BoundContract -} - -type FunctionsRouterTransactor struct { - contract *bind.BoundContract -} - -type FunctionsRouterFilterer struct { - contract *bind.BoundContract -} - -type FunctionsRouterSession struct { - Contract *FunctionsRouter - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type FunctionsRouterCallerSession struct { - Contract *FunctionsRouterCaller - CallOpts bind.CallOpts -} - -type FunctionsRouterTransactorSession struct { - Contract *FunctionsRouterTransactor - TransactOpts bind.TransactOpts -} - -type FunctionsRouterRaw struct { - Contract *FunctionsRouter -} - -type FunctionsRouterCallerRaw struct { - Contract *FunctionsRouterCaller -} - -type FunctionsRouterTransactorRaw struct { - Contract *FunctionsRouterTransactor -} - -func NewFunctionsRouter(address common.Address, backend bind.ContractBackend) (*FunctionsRouter, error) { - abi, err := abi.JSON(strings.NewReader(FunctionsRouterABI)) - if err != nil { - return nil, err - } - contract, err := bindFunctionsRouter(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &FunctionsRouter{address: address, abi: abi, FunctionsRouterCaller: FunctionsRouterCaller{contract: contract}, FunctionsRouterTransactor: FunctionsRouterTransactor{contract: contract}, FunctionsRouterFilterer: FunctionsRouterFilterer{contract: contract}}, nil -} - -func NewFunctionsRouterCaller(address common.Address, caller bind.ContractCaller) (*FunctionsRouterCaller, error) { - contract, err := bindFunctionsRouter(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &FunctionsRouterCaller{contract: contract}, nil -} - -func NewFunctionsRouterTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsRouterTransactor, error) { - contract, err := bindFunctionsRouter(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &FunctionsRouterTransactor{contract: contract}, nil -} - -func NewFunctionsRouterFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsRouterFilterer, error) { - contract, err := bindFunctionsRouter(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &FunctionsRouterFilterer{contract: contract}, nil -} - -func bindFunctionsRouter(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := FunctionsRouterMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_FunctionsRouter *FunctionsRouterRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsRouter.Contract.FunctionsRouterCaller.contract.Call(opts, result, method, params...) -} - -func (_FunctionsRouter *FunctionsRouterRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.Contract.FunctionsRouterTransactor.contract.Transfer(opts) -} - -func (_FunctionsRouter *FunctionsRouterRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsRouter.Contract.FunctionsRouterTransactor.contract.Transact(opts, method, params...) -} - -func (_FunctionsRouter *FunctionsRouterCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _FunctionsRouter.Contract.contract.Call(opts, result, method, params...) -} - -func (_FunctionsRouter *FunctionsRouterTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.Contract.contract.Transfer(opts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _FunctionsRouter.Contract.contract.Transact(opts, method, params...) -} - -func (_FunctionsRouter *FunctionsRouterCaller) MAXCONSUMERS(opts *bind.CallOpts) (uint16, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "MAX_CONSUMERS") - - if err != nil { - return *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) MAXCONSUMERS() (uint16, error) { - return _FunctionsRouter.Contract.MAXCONSUMERS(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) MAXCONSUMERS() (uint16, error) { - return _FunctionsRouter.Contract.MAXCONSUMERS(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getAdminFee") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetAdminFee() (*big.Int, error) { - return _FunctionsRouter.Contract.GetAdminFee(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetAdminFee() (*big.Int, error) { - return _FunctionsRouter.Contract.GetAdminFee(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetConfigHash(opts *bind.CallOpts) ([32]byte, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getConfigHash") - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetConfigHash() ([32]byte, error) { - return _FunctionsRouter.Contract.GetConfigHash(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfigHash() ([32]byte, error) { - return _FunctionsRouter.Contract.GetConfigHash(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, - - error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getConsumer", client, subscriptionId) - - outstruct := new(GetConsumer) - if err != nil { - return *outstruct, err - } - - outstruct.Allowed = *abi.ConvertType(out[0], new(bool)).(*bool) - outstruct.InitiatedRequests = *abi.ConvertType(out[1], new(uint64)).(*uint64) - outstruct.CompletedRequests = *abi.ConvertType(out[2], new(uint64)).(*uint64) - - return *outstruct, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetConsumer(client common.Address, subscriptionId uint64) (GetConsumer, - - error) { - return _FunctionsRouter.Contract.GetConsumer(&_FunctionsRouter.CallOpts, client, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConsumer(client common.Address, subscriptionId uint64) (GetConsumer, - - error) { - return _FunctionsRouter.Contract.GetConsumer(&_FunctionsRouter.CallOpts, client, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetContractById(opts *bind.CallOpts, id [32]byte, useProposed bool) (common.Address, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getContractById", id, useProposed) - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetContractById(id [32]byte, useProposed bool) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById(&_FunctionsRouter.CallOpts, id, useProposed) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetContractById(id [32]byte, useProposed bool) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById(&_FunctionsRouter.CallOpts, id, useProposed) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetContractById0(opts *bind.CallOpts, id [32]byte) (common.Address, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getContractById0", id) - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetContractById0(id [32]byte) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById0(&_FunctionsRouter.CallOpts, id) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetContractById0(id [32]byte) (common.Address, error) { - return _FunctionsRouter.Contract.GetContractById0(&_FunctionsRouter.CallOpts, id) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, []common.Address, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getProposedContractSet") - - if err != nil { - return *new(*big.Int), *new([][32]byte), *new([]common.Address), *new([]common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new([][32]byte)).(*[][32]byte) - out2 := *abi.ConvertType(out[2], new([]common.Address)).(*[]common.Address) - out3 := *abi.ConvertType(out[3], new([]common.Address)).(*[]common.Address) - - return out0, out1, out2, out3, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetProposedContractSet() (*big.Int, [][32]byte, []common.Address, []common.Address, error) { - return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() (*big.Int, [][32]byte, []common.Address, []common.Address, error) { - return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getSubscription", subscriptionId) - - outstruct := new(GetSubscription) - if err != nil { - return *outstruct, err - } - - outstruct.Balance = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - outstruct.BlockedBalance = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - outstruct.Owner = *abi.ConvertType(out[2], new(common.Address)).(*common.Address) - outstruct.RequestedOwner = *abi.ConvertType(out[3], new(common.Address)).(*common.Address) - outstruct.Consumers = *abi.ConvertType(out[4], new([]common.Address)).(*[]common.Address) - - return *outstruct, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { - return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { - return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetSubscriptionCount(opts *bind.CallOpts) (uint64, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getSubscriptionCount") - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetSubscriptionCount() (uint64, error) { - return _FunctionsRouter.Contract.GetSubscriptionCount(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscriptionCount() (uint64, error) { - return _FunctionsRouter.Contract.GetSubscriptionCount(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) GetTotalBalance(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "getTotalBalance") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) GetTotalBalance() (*big.Int, error) { - return _FunctionsRouter.Contract.GetTotalBalance(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) GetTotalBalance() (*big.Int, error) { - return _FunctionsRouter.Contract.GetTotalBalance(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) IsPaused(opts *bind.CallOpts) (bool, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "isPaused") - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) IsPaused() (bool, error) { - return _FunctionsRouter.Contract.IsPaused(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) IsPaused() (bool, error) { - return _FunctionsRouter.Contract.IsPaused(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _FunctionsRouter.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 (_FunctionsRouter *FunctionsRouterSession) Owner() (common.Address, error) { - return _FunctionsRouter.Contract.Owner(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) Owner() (common.Address, error) { - return _FunctionsRouter.Contract.Owner(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) Paused(opts *bind.CallOpts) (bool, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "paused") - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) Paused() (bool, error) { - return _FunctionsRouter.Contract.Paused(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) Paused() (bool, error) { - return _FunctionsRouter.Contract.Paused(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) PendingRequestExists(opts *bind.CallOpts, subscriptionId uint64) (bool, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "pendingRequestExists", subscriptionId) - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) PendingRequestExists(subscriptionId uint64) (bool, error) { - return _FunctionsRouter.Contract.PendingRequestExists(&_FunctionsRouter.CallOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) PendingRequestExists(subscriptionId uint64) (bool, error) { - return _FunctionsRouter.Contract.PendingRequestExists(&_FunctionsRouter.CallOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "typeAndVersion") - - if err != nil { - return *new(string), err - } - - out0 := *abi.ConvertType(out[0], new(string)).(*string) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) TypeAndVersion() (string, error) { - return _FunctionsRouter.Contract.TypeAndVersion(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) TypeAndVersion() (string, error) { - return _FunctionsRouter.Contract.TypeAndVersion(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCaller) Version(opts *bind.CallOpts) (uint16, uint16, uint16, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "version") - - if err != nil { - return *new(uint16), *new(uint16), *new(uint16), err - } - - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - out1 := *abi.ConvertType(out[1], new(uint16)).(*uint16) - out2 := *abi.ConvertType(out[2], new(uint16)).(*uint16) - - return out0, out1, out2, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) Version() (uint16, uint16, uint16, error) { - return _FunctionsRouter.Contract.Version(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) Version() (uint16, uint16, uint16, error) { - return _FunctionsRouter.Contract.Version(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "acceptOwnership") -} - -func (_FunctionsRouter *FunctionsRouterSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsRouter.Contract.AcceptOwnership(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _FunctionsRouter.Contract.AcceptOwnership(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) AcceptSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "acceptSubscriptionOwnerTransfer", subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterSession) AcceptSubscriptionOwnerTransfer(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRouter.Contract.AcceptSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) AcceptSubscriptionOwnerTransfer(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRouter.Contract.AcceptSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) AddConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "addConsumer", subscriptionId, consumer) -} - -func (_FunctionsRouter *FunctionsRouterSession) AddConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.AddConsumer(&_FunctionsRouter.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) AddConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.AddConsumer(&_FunctionsRouter.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) CancelSubscription(opts *bind.TransactOpts, subscriptionId uint64, to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "cancelSubscription", subscriptionId, to) -} - -func (_FunctionsRouter *FunctionsRouterSession) CancelSubscription(subscriptionId uint64, to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.CancelSubscription(&_FunctionsRouter.TransactOpts, subscriptionId, to) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) CancelSubscription(subscriptionId uint64, to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.CancelSubscription(&_FunctionsRouter.TransactOpts, subscriptionId, to) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "createSubscription") -} - -func (_FunctionsRouter *FunctionsRouterSession) CreateSubscription() (*types.Transaction, error) { - return _FunctionsRouter.Contract.CreateSubscription(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) CreateSubscription() (*types.Transaction, error) { - return _FunctionsRouter.Contract.CreateSubscription(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "fulfill", requestId, response, err, juelsPerGas, costWithoutFulfillment, transmitter) -} - -func (_FunctionsRouter *FunctionsRouterSession) Fulfill(requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, requestId, response, err, juelsPerGas, costWithoutFulfillment, transmitter) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, requestId, response, err, juelsPerGas, costWithoutFulfillment, transmitter) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "onTokenTransfer", arg0, amount, data) -} - -func (_FunctionsRouter *FunctionsRouterSession) OnTokenTransfer(arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.OnTokenTransfer(&_FunctionsRouter.TransactOpts, arg0, amount, data) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) OnTokenTransfer(arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.OnTokenTransfer(&_FunctionsRouter.TransactOpts, arg0, amount, data) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "oracleWithdraw", recipient, amount) -} - -func (_FunctionsRouter *FunctionsRouterSession) OracleWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsRouter.Contract.OracleWithdraw(&_FunctionsRouter.TransactOpts, recipient, amount) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) OracleWithdraw(recipient common.Address, amount *big.Int) (*types.Transaction, error) { - return _FunctionsRouter.Contract.OracleWithdraw(&_FunctionsRouter.TransactOpts, recipient, amount) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) OwnerCancelSubscription(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "ownerCancelSubscription", subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterSession) OwnerCancelSubscription(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRouter.Contract.OwnerCancelSubscription(&_FunctionsRouter.TransactOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) OwnerCancelSubscription(subscriptionId uint64) (*types.Transaction, error) { - return _FunctionsRouter.Contract.OwnerCancelSubscription(&_FunctionsRouter.TransactOpts, subscriptionId) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "proposeConfigUpdate", id, config) -} - -func (_FunctionsRouter *FunctionsRouterSession) ProposeConfigUpdate(id [32]byte, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeConfigUpdate(&_FunctionsRouter.TransactOpts, id, config) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeConfigUpdate(id [32]byte, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeConfigUpdate(&_FunctionsRouter.TransactOpts, id, config) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetFromAddresses []common.Address, proposedContractSetToAddresses []common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "proposeContractsUpdate", proposedContractSetIds, proposedContractSetFromAddresses, proposedContractSetToAddresses) -} - -func (_FunctionsRouter *FunctionsRouterSession) ProposeContractsUpdate(proposedContractSetIds [][32]byte, proposedContractSetFromAddresses []common.Address, proposedContractSetToAddresses []common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeContractsUpdate(&_FunctionsRouter.TransactOpts, proposedContractSetIds, proposedContractSetFromAddresses, proposedContractSetToAddresses) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeContractsUpdate(proposedContractSetIds [][32]byte, proposedContractSetFromAddresses []common.Address, proposedContractSetToAddresses []common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeContractsUpdate(&_FunctionsRouter.TransactOpts, proposedContractSetIds, proposedContractSetFromAddresses, proposedContractSetToAddresses) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) ProposeTimelockBlocks(opts *bind.TransactOpts, blocks uint16) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "proposeTimelockBlocks", blocks) -} - -func (_FunctionsRouter *FunctionsRouterSession) ProposeTimelockBlocks(blocks uint16) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeTimelockBlocks(&_FunctionsRouter.TransactOpts, blocks) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeTimelockBlocks(blocks uint16) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeTimelockBlocks(&_FunctionsRouter.TransactOpts, blocks) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "recoverFunds", to) -} - -func (_FunctionsRouter *FunctionsRouterSession) RecoverFunds(to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RecoverFunds(&_FunctionsRouter.TransactOpts, to) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) RecoverFunds(to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RecoverFunds(&_FunctionsRouter.TransactOpts, to) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) RemoveConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "removeConsumer", subscriptionId, consumer) -} - -func (_FunctionsRouter *FunctionsRouterSession) RemoveConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RemoveConsumer(&_FunctionsRouter.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) RemoveConsumer(subscriptionId uint64, consumer common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RemoveConsumer(&_FunctionsRouter.TransactOpts, subscriptionId, consumer) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) RequestSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "requestSubscriptionOwnerTransfer", subscriptionId, newOwner) -} - -func (_FunctionsRouter *FunctionsRouterSession) RequestSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RequestSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) RequestSubscriptionOwnerTransfer(subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.RequestSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) SendRequest(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "sendRequest", subscriptionId, data, dataVersion, callbackGasLimit, donId) -} - -func (_FunctionsRouter *FunctionsRouterSession) SendRequest(subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.SendRequest(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) SendRequest(subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.SendRequest(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "timeoutRequests", requestIdsToTimeout) -} - -func (_FunctionsRouter *FunctionsRouterSession) TimeoutRequests(requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestIdsToTimeout) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) TimeoutRequests(requestIdsToTimeout [][32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestIdsToTimeout) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) TogglePaused(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "togglePaused") -} - -func (_FunctionsRouter *FunctionsRouterSession) TogglePaused() (*types.Transaction, error) { - return _FunctionsRouter.Contract.TogglePaused(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) TogglePaused() (*types.Transaction, error) { - return _FunctionsRouter.Contract.TogglePaused(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "transferOwnership", to) -} - -func (_FunctionsRouter *FunctionsRouterSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.TransferOwnership(&_FunctionsRouter.TransactOpts, to) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _FunctionsRouter.Contract.TransferOwnership(&_FunctionsRouter.TransactOpts, to) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "updateConfig", id) -} - -func (_FunctionsRouter *FunctionsRouterSession) UpdateConfig(id [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, id) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateConfig(id [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, id) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "updateContracts") -} - -func (_FunctionsRouter *FunctionsRouterSession) UpdateContracts() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateContracts(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateContracts() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateContracts(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) UpdateTimelockBlocks(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "updateTimelockBlocks") -} - -func (_FunctionsRouter *FunctionsRouterSession) UpdateTimelockBlocks() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateTimelockBlocks(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateTimelockBlocks() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateTimelockBlocks(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) ValidateProposedContracts(opts *bind.TransactOpts, id [32]byte, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "validateProposedContracts", id, data) -} - -func (_FunctionsRouter *FunctionsRouterSession) ValidateProposedContracts(id [32]byte, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ValidateProposedContracts(&_FunctionsRouter.TransactOpts, id, data) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ValidateProposedContracts(id [32]byte, data []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ValidateProposedContracts(&_FunctionsRouter.TransactOpts, id, data) -} - -type FunctionsRouterConfigProposedIterator struct { - Event *FunctionsRouterConfigProposed - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterConfigProposedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterConfigProposed) - 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(FunctionsRouterConfigProposed) - 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 *FunctionsRouterConfigProposedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterConfigProposedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterConfigProposed struct { - Id [32]byte - FromHash [32]byte - ToBytes []byte - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigProposed") - if err != nil { - return nil, err - } - return &FunctionsRouterConfigProposedIterator{contract: _FunctionsRouter.contract, event: "ConfigProposed", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigProposed") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterConfigProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) { - event := new(FunctionsRouterConfigProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterConfigSetIterator struct { - Event *FunctionsRouterConfigSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterConfigSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterConfigSet) - 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(FunctionsRouterConfigSet) - 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 *FunctionsRouterConfigSetIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterConfigSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterConfigSet struct { - AdminFee *big.Int - HandleOracleFulfillmentSelector [4]byte - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsRouterConfigSetIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigSet") - if err != nil { - return nil, err - } - return &FunctionsRouterConfigSetIterator{contract: _FunctionsRouter.contract, event: "ConfigSet", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigSet) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterConfigSet) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigSet", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigSet(log types.Log) (*FunctionsRouterConfigSet, error) { - event := new(FunctionsRouterConfigSet) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterConfigUpdatedIterator struct { - Event *FunctionsRouterConfigUpdated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterConfigUpdatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterConfigUpdated) - 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(FunctionsRouterConfigUpdated) - 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 *FunctionsRouterConfigUpdatedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterConfigUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterConfigUpdated struct { - Id [32]byte - FromHash [32]byte - ToBytes []byte - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsRouterConfigUpdatedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigUpdated") - if err != nil { - return nil, err - } - return &FunctionsRouterConfigUpdatedIterator{contract: _FunctionsRouter.contract, event: "ConfigUpdated", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigUpdated) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigUpdated") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterConfigUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigUpdated", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigUpdated(log types.Log) (*FunctionsRouterConfigUpdated, error) { - event := new(FunctionsRouterConfigUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterContractProposedIterator struct { - Event *FunctionsRouterContractProposed - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterContractProposedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterContractProposed) - 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(FunctionsRouterContractProposed) - 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 *FunctionsRouterContractProposedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterContractProposedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterContractProposed struct { - ProposedContractSetId [32]byte - ProposedContractSetFromAddress common.Address - ProposedContractSetToAddress common.Address - TimelockEndBlock *big.Int - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterContractProposed(opts *bind.FilterOpts) (*FunctionsRouterContractProposedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ContractProposed") - if err != nil { - return nil, err - } - return &FunctionsRouterContractProposedIterator{contract: _FunctionsRouter.contract, event: "ContractProposed", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchContractProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterContractProposed) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ContractProposed") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterContractProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ContractProposed", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseContractProposed(log types.Log) (*FunctionsRouterContractProposed, error) { - event := new(FunctionsRouterContractProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ContractProposed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterContractUpdatedIterator struct { - Event *FunctionsRouterContractUpdated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterContractUpdatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterContractUpdated) - 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(FunctionsRouterContractUpdated) - 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 *FunctionsRouterContractUpdatedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterContractUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterContractUpdated struct { - ProposedContractSetId [32]byte - ProposedContractSetFromAddress common.Address - ProposedContractSetToAddress common.Address - Major uint16 - Minor uint16 - Patch uint16 - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterContractUpdated(opts *bind.FilterOpts) (*FunctionsRouterContractUpdatedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ContractUpdated") - if err != nil { - return nil, err - } - return &FunctionsRouterContractUpdatedIterator{contract: _FunctionsRouter.contract, event: "ContractUpdated", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchContractUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterContractUpdated) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ContractUpdated") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterContractUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "ContractUpdated", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseContractUpdated(log types.Log) (*FunctionsRouterContractUpdated, error) { - event := new(FunctionsRouterContractUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "ContractUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterFundsRecoveredIterator struct { - Event *FunctionsRouterFundsRecovered - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterFundsRecoveredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterFundsRecovered) - 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(FunctionsRouterFundsRecovered) - 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 *FunctionsRouterFundsRecoveredIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterFundsRecoveredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterFundsRecovered struct { - To common.Address - Amount *big.Int - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterFundsRecovered(opts *bind.FilterOpts) (*FunctionsRouterFundsRecoveredIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "FundsRecovered") - if err != nil { - return nil, err - } - return &FunctionsRouterFundsRecoveredIterator{contract: _FunctionsRouter.contract, event: "FundsRecovered", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchFundsRecovered(opts *bind.WatchOpts, sink chan<- *FunctionsRouterFundsRecovered) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "FundsRecovered") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterFundsRecovered) - if err := _FunctionsRouter.contract.UnpackLog(event, "FundsRecovered", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseFundsRecovered(log types.Log) (*FunctionsRouterFundsRecovered, error) { - event := new(FunctionsRouterFundsRecovered) - if err := _FunctionsRouter.contract.UnpackLog(event, "FundsRecovered", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterOwnershipTransferRequestedIterator struct { - Event *FunctionsRouterOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterOwnershipTransferRequested) - 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(FunctionsRouterOwnershipTransferRequested) - 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 *FunctionsRouterOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRouterOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsRouterOwnershipTransferRequestedIterator{contract: _FunctionsRouter.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRouterOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterOwnershipTransferRequested) - if err := _FunctionsRouter.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseOwnershipTransferRequested(log types.Log) (*FunctionsRouterOwnershipTransferRequested, error) { - event := new(FunctionsRouterOwnershipTransferRequested) - if err := _FunctionsRouter.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterOwnershipTransferredIterator struct { - Event *FunctionsRouterOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterOwnershipTransferred) - 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(FunctionsRouterOwnershipTransferred) - 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 *FunctionsRouterOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRouterOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &FunctionsRouterOwnershipTransferredIterator{contract: _FunctionsRouter.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRouterOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterOwnershipTransferred) - if err := _FunctionsRouter.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 (_FunctionsRouter *FunctionsRouterFilterer) ParseOwnershipTransferred(log types.Log) (*FunctionsRouterOwnershipTransferred, error) { - event := new(FunctionsRouterOwnershipTransferred) - if err := _FunctionsRouter.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterPausedIterator struct { - Event *FunctionsRouterPaused - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterPausedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterPaused) - 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(FunctionsRouterPaused) - 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 *FunctionsRouterPausedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterPausedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterPaused struct { - Account common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterPaused(opts *bind.FilterOpts) (*FunctionsRouterPausedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "Paused") - if err != nil { - return nil, err - } - return &FunctionsRouterPausedIterator{contract: _FunctionsRouter.contract, event: "Paused", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchPaused(opts *bind.WatchOpts, sink chan<- *FunctionsRouterPaused) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "Paused") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterPaused) - if err := _FunctionsRouter.contract.UnpackLog(event, "Paused", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParsePaused(log types.Log) (*FunctionsRouterPaused, error) { - event := new(FunctionsRouterPaused) - if err := _FunctionsRouter.contract.UnpackLog(event, "Paused", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterRequestEndIterator struct { - Event *FunctionsRouterRequestEnd - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterRequestEndIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterRequestEnd) - 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(FunctionsRouterRequestEnd) - 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 *FunctionsRouterRequestEndIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterRequestEndIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterRequestEnd struct { - RequestId [32]byte - SubscriptionId uint64 - TotalCostJuels *big.Int - Transmitter common.Address - ResultCode uint8 - Response []byte - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestEnd(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestEndIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "RequestEnd", requestIdRule, subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterRequestEndIterator{contract: _FunctionsRouter.contract, event: "RequestEnd", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestEnd(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestEnd, requestId [][32]byte, subscriptionId []uint64) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "RequestEnd", requestIdRule, subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterRequestEnd) - if err := _FunctionsRouter.contract.UnpackLog(event, "RequestEnd", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestEnd(log types.Log) (*FunctionsRouterRequestEnd, error) { - event := new(FunctionsRouterRequestEnd) - if err := _FunctionsRouter.contract.UnpackLog(event, "RequestEnd", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterRequestStartIterator struct { - Event *FunctionsRouterRequestStart - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterRequestStartIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterRequestStart) - 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(FunctionsRouterRequestStart) - 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 *FunctionsRouterRequestStartIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterRequestStartIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterRequestStart struct { - RequestId [32]byte - DonId [32]byte - SubscriptionId uint64 - SubscriptionOwner common.Address - RequestingContract common.Address - RequestInitiator common.Address - Data []byte - DataVersion uint16 - CallbackGasLimit uint32 - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestStart(opts *bind.FilterOpts, requestId [][32]byte, donId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestStartIterator, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - var donIdRule []interface{} - for _, donIdItem := range donId { - donIdRule = append(donIdRule, donIdItem) - } - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "RequestStart", requestIdRule, donIdRule, subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterRequestStartIterator{contract: _FunctionsRouter.contract, event: "RequestStart", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchRequestStart(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestStart, requestId [][32]byte, donId [][32]byte, subscriptionId []uint64) (event.Subscription, error) { - - var requestIdRule []interface{} - for _, requestIdItem := range requestId { - requestIdRule = append(requestIdRule, requestIdItem) - } - var donIdRule []interface{} - for _, donIdItem := range donId { - donIdRule = append(donIdRule, donIdItem) - } - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "RequestStart", requestIdRule, donIdRule, subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterRequestStart) - if err := _FunctionsRouter.contract.UnpackLog(event, "RequestStart", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseRequestStart(log types.Log) (*FunctionsRouterRequestStart, error) { - event := new(FunctionsRouterRequestStart) - if err := _FunctionsRouter.contract.UnpackLog(event, "RequestStart", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionCanceledIterator struct { - Event *FunctionsRouterSubscriptionCanceled - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionCanceledIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionCanceled) - 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(FunctionsRouterSubscriptionCanceled) - 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 *FunctionsRouterSubscriptionCanceledIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionCanceledIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionCanceled struct { - SubscriptionId uint64 - FundsRecipient common.Address - FundsAmount *big.Int - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionCanceled(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionCanceledIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionCanceled", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionCanceledIterator{contract: _FunctionsRouter.contract, event: "SubscriptionCanceled", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionCanceled(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionCanceled, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionCanceled", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionCanceled) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionCanceled", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionCanceled(log types.Log) (*FunctionsRouterSubscriptionCanceled, error) { - event := new(FunctionsRouterSubscriptionCanceled) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionCanceled", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionConsumerAddedIterator struct { - Event *FunctionsRouterSubscriptionConsumerAdded - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionConsumerAddedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionConsumerAdded) - 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(FunctionsRouterSubscriptionConsumerAdded) - 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 *FunctionsRouterSubscriptionConsumerAddedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionConsumerAddedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionConsumerAdded struct { - SubscriptionId uint64 - Consumer common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionConsumerAdded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionConsumerAddedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionConsumerAdded", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionConsumerAddedIterator{contract: _FunctionsRouter.contract, event: "SubscriptionConsumerAdded", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionConsumerAdded(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionConsumerAdded, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionConsumerAdded", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionConsumerAdded) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionConsumerAdded", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionConsumerAdded(log types.Log) (*FunctionsRouterSubscriptionConsumerAdded, error) { - event := new(FunctionsRouterSubscriptionConsumerAdded) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionConsumerAdded", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionConsumerRemovedIterator struct { - Event *FunctionsRouterSubscriptionConsumerRemoved - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionConsumerRemovedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionConsumerRemoved) - 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(FunctionsRouterSubscriptionConsumerRemoved) - 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 *FunctionsRouterSubscriptionConsumerRemovedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionConsumerRemovedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionConsumerRemoved struct { - SubscriptionId uint64 - Consumer common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionConsumerRemoved(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionConsumerRemovedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionConsumerRemoved", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionConsumerRemovedIterator{contract: _FunctionsRouter.contract, event: "SubscriptionConsumerRemoved", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionConsumerRemoved(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionConsumerRemoved, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionConsumerRemoved", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionConsumerRemoved) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionConsumerRemoved", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionConsumerRemoved(log types.Log) (*FunctionsRouterSubscriptionConsumerRemoved, error) { - event := new(FunctionsRouterSubscriptionConsumerRemoved) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionConsumerRemoved", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionCreatedIterator struct { - Event *FunctionsRouterSubscriptionCreated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionCreatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionCreated) - 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(FunctionsRouterSubscriptionCreated) - 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 *FunctionsRouterSubscriptionCreatedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionCreatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionCreated struct { - SubscriptionId uint64 - Owner common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionCreated(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionCreatedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionCreated", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionCreatedIterator{contract: _FunctionsRouter.contract, event: "SubscriptionCreated", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionCreated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionCreated, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionCreated", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionCreated) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionCreated", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionCreated(log types.Log) (*FunctionsRouterSubscriptionCreated, error) { - event := new(FunctionsRouterSubscriptionCreated) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionCreated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionFundedIterator struct { - Event *FunctionsRouterSubscriptionFunded - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionFundedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionFunded) - 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(FunctionsRouterSubscriptionFunded) - 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 *FunctionsRouterSubscriptionFundedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionFundedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionFunded struct { - SubscriptionId uint64 - OldBalance *big.Int - NewBalance *big.Int - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionFunded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionFundedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionFunded", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionFundedIterator{contract: _FunctionsRouter.contract, event: "SubscriptionFunded", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionFunded(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionFunded, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionFunded", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionFunded) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionFunded", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionFunded(log types.Log) (*FunctionsRouterSubscriptionFunded, error) { - event := new(FunctionsRouterSubscriptionFunded) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionFunded", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionOwnerTransferRequestedIterator struct { - Event *FunctionsRouterSubscriptionOwnerTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionOwnerTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionOwnerTransferRequested) - 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(FunctionsRouterSubscriptionOwnerTransferRequested) - 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 *FunctionsRouterSubscriptionOwnerTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionOwnerTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionOwnerTransferRequested struct { - SubscriptionId uint64 - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionOwnerTransferRequested(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionOwnerTransferRequestedIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionOwnerTransferRequested", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionOwnerTransferRequestedIterator{contract: _FunctionsRouter.contract, event: "SubscriptionOwnerTransferRequested", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionOwnerTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionOwnerTransferRequested, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionOwnerTransferRequested", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionOwnerTransferRequested) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionOwnerTransferRequested", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionOwnerTransferRequested(log types.Log) (*FunctionsRouterSubscriptionOwnerTransferRequested, error) { - event := new(FunctionsRouterSubscriptionOwnerTransferRequested) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionOwnerTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterSubscriptionOwnerTransferredIterator struct { - Event *FunctionsRouterSubscriptionOwnerTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterSubscriptionOwnerTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterSubscriptionOwnerTransferred) - 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(FunctionsRouterSubscriptionOwnerTransferred) - 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 *FunctionsRouterSubscriptionOwnerTransferredIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterSubscriptionOwnerTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterSubscriptionOwnerTransferred struct { - SubscriptionId uint64 - From common.Address - To common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterSubscriptionOwnerTransferred(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionOwnerTransferredIterator, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "SubscriptionOwnerTransferred", subscriptionIdRule) - if err != nil { - return nil, err - } - return &FunctionsRouterSubscriptionOwnerTransferredIterator{contract: _FunctionsRouter.contract, event: "SubscriptionOwnerTransferred", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchSubscriptionOwnerTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionOwnerTransferred, subscriptionId []uint64) (event.Subscription, error) { - - var subscriptionIdRule []interface{} - for _, subscriptionIdItem := range subscriptionId { - subscriptionIdRule = append(subscriptionIdRule, subscriptionIdItem) - } - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "SubscriptionOwnerTransferred", subscriptionIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterSubscriptionOwnerTransferred) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionOwnerTransferred", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionOwnerTransferred(log types.Log) (*FunctionsRouterSubscriptionOwnerTransferred, error) { - event := new(FunctionsRouterSubscriptionOwnerTransferred) - if err := _FunctionsRouter.contract.UnpackLog(event, "SubscriptionOwnerTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterTimeLockProposedIterator struct { - Event *FunctionsRouterTimeLockProposed - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterTimeLockProposedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterTimeLockProposed) - 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(FunctionsRouterTimeLockProposed) - 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 *FunctionsRouterTimeLockProposedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterTimeLockProposedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterTimeLockProposed struct { - From uint16 - To uint16 - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterTimeLockProposed(opts *bind.FilterOpts) (*FunctionsRouterTimeLockProposedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "TimeLockProposed") - if err != nil { - return nil, err - } - return &FunctionsRouterTimeLockProposedIterator{contract: _FunctionsRouter.contract, event: "TimeLockProposed", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchTimeLockProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockProposed) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "TimeLockProposed") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterTimeLockProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockProposed", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseTimeLockProposed(log types.Log) (*FunctionsRouterTimeLockProposed, error) { - event := new(FunctionsRouterTimeLockProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockProposed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterTimeLockUpdatedIterator struct { - Event *FunctionsRouterTimeLockUpdated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterTimeLockUpdatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterTimeLockUpdated) - 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(FunctionsRouterTimeLockUpdated) - 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 *FunctionsRouterTimeLockUpdatedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterTimeLockUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterTimeLockUpdated struct { - From uint16 - To uint16 - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterTimeLockUpdated(opts *bind.FilterOpts) (*FunctionsRouterTimeLockUpdatedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "TimeLockUpdated") - if err != nil { - return nil, err - } - return &FunctionsRouterTimeLockUpdatedIterator{contract: _FunctionsRouter.contract, event: "TimeLockUpdated", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchTimeLockUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockUpdated) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "TimeLockUpdated") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterTimeLockUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockUpdated", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseTimeLockUpdated(log types.Log) (*FunctionsRouterTimeLockUpdated, error) { - event := new(FunctionsRouterTimeLockUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterUnpausedIterator struct { - Event *FunctionsRouterUnpaused - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterUnpausedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterUnpaused) - 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(FunctionsRouterUnpaused) - 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 *FunctionsRouterUnpausedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterUnpausedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterUnpaused struct { - Account common.Address - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterUnpaused(opts *bind.FilterOpts) (*FunctionsRouterUnpausedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "Unpaused") - if err != nil { - return nil, err - } - return &FunctionsRouterUnpausedIterator{contract: _FunctionsRouter.contract, event: "Unpaused", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *FunctionsRouterUnpaused) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.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(FunctionsRouterUnpaused) - if err := _FunctionsRouter.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 (_FunctionsRouter *FunctionsRouterFilterer) ParseUnpaused(log types.Log) (*FunctionsRouterUnpaused, error) { - event := new(FunctionsRouterUnpaused) - if err := _FunctionsRouter.contract.UnpackLog(event, "Unpaused", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type GetConsumer struct { - Allowed bool - InitiatedRequests uint64 - CompletedRequests uint64 -} -type GetSubscription struct { - Balance *big.Int - BlockedBalance *big.Int - Owner common.Address - RequestedOwner common.Address - Consumers []common.Address -} - -func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _FunctionsRouter.abi.Events["ConfigProposed"].ID: - return _FunctionsRouter.ParseConfigProposed(log) - case _FunctionsRouter.abi.Events["ConfigSet"].ID: - return _FunctionsRouter.ParseConfigSet(log) - case _FunctionsRouter.abi.Events["ConfigUpdated"].ID: - return _FunctionsRouter.ParseConfigUpdated(log) - case _FunctionsRouter.abi.Events["ContractProposed"].ID: - return _FunctionsRouter.ParseContractProposed(log) - case _FunctionsRouter.abi.Events["ContractUpdated"].ID: - return _FunctionsRouter.ParseContractUpdated(log) - case _FunctionsRouter.abi.Events["FundsRecovered"].ID: - return _FunctionsRouter.ParseFundsRecovered(log) - case _FunctionsRouter.abi.Events["OwnershipTransferRequested"].ID: - return _FunctionsRouter.ParseOwnershipTransferRequested(log) - case _FunctionsRouter.abi.Events["OwnershipTransferred"].ID: - return _FunctionsRouter.ParseOwnershipTransferred(log) - case _FunctionsRouter.abi.Events["Paused"].ID: - return _FunctionsRouter.ParsePaused(log) - case _FunctionsRouter.abi.Events["RequestEnd"].ID: - return _FunctionsRouter.ParseRequestEnd(log) - case _FunctionsRouter.abi.Events["RequestStart"].ID: - return _FunctionsRouter.ParseRequestStart(log) - case _FunctionsRouter.abi.Events["SubscriptionCanceled"].ID: - return _FunctionsRouter.ParseSubscriptionCanceled(log) - case _FunctionsRouter.abi.Events["SubscriptionConsumerAdded"].ID: - return _FunctionsRouter.ParseSubscriptionConsumerAdded(log) - case _FunctionsRouter.abi.Events["SubscriptionConsumerRemoved"].ID: - return _FunctionsRouter.ParseSubscriptionConsumerRemoved(log) - case _FunctionsRouter.abi.Events["SubscriptionCreated"].ID: - return _FunctionsRouter.ParseSubscriptionCreated(log) - case _FunctionsRouter.abi.Events["SubscriptionFunded"].ID: - return _FunctionsRouter.ParseSubscriptionFunded(log) - case _FunctionsRouter.abi.Events["SubscriptionOwnerTransferRequested"].ID: - return _FunctionsRouter.ParseSubscriptionOwnerTransferRequested(log) - case _FunctionsRouter.abi.Events["SubscriptionOwnerTransferred"].ID: - return _FunctionsRouter.ParseSubscriptionOwnerTransferred(log) - case _FunctionsRouter.abi.Events["TimeLockProposed"].ID: - return _FunctionsRouter.ParseTimeLockProposed(log) - case _FunctionsRouter.abi.Events["TimeLockUpdated"].ID: - return _FunctionsRouter.ParseTimeLockUpdated(log) - case _FunctionsRouter.abi.Events["Unpaused"].ID: - return _FunctionsRouter.ParseUnpaused(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (FunctionsRouterConfigProposed) Topic() common.Hash { - return common.HexToHash("0x0fcfd32a68209b42944376bc5f4bf72c41ba0f378cf60434f84390b82c9844cf") -} - -func (FunctionsRouterConfigSet) Topic() common.Hash { - return common.HexToHash("0xb2b9bfb736b0bfef266985352cfca2a114226362209f5a6e5a2a2ed14383ba57") -} - -func (FunctionsRouterConfigUpdated) Topic() common.Hash { - return common.HexToHash("0xc07626096b49b0462a576c9a7878cf0675e784bb4832584c1289c11664e55f47") -} - -func (FunctionsRouterContractProposed) Topic() common.Hash { - return common.HexToHash("0x72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd") -} - -func (FunctionsRouterContractUpdated) Topic() common.Hash { - return common.HexToHash("0xf17ce6b5bbeda6598ac50e505071ddbd27c188c5ecaf9126b42c951c9c4b61e9") -} - -func (FunctionsRouterFundsRecovered) Topic() common.Hash { - return common.HexToHash("0x59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600") -} - -func (FunctionsRouterOwnershipTransferRequested) Topic() common.Hash { - return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") -} - -func (FunctionsRouterOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") -} - -func (FunctionsRouterPaused) Topic() common.Hash { - return common.HexToHash("0x62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258") -} - -func (FunctionsRouterRequestEnd) Topic() common.Hash { - return common.HexToHash("0x526019d853b0b88e828dbdc124746afde5a47053256d2a0872a025ab145b0520") -} - -func (FunctionsRouterRequestStart) Topic() common.Hash { - return common.HexToHash("0x7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54") -} - -func (FunctionsRouterSubscriptionCanceled) Topic() common.Hash { - return common.HexToHash("0xe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815") -} - -func (FunctionsRouterSubscriptionConsumerAdded) Topic() common.Hash { - return common.HexToHash("0x43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e0") -} - -func (FunctionsRouterSubscriptionConsumerRemoved) Topic() common.Hash { - return common.HexToHash("0x182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b") -} - -func (FunctionsRouterSubscriptionCreated) Topic() common.Hash { - return common.HexToHash("0x464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf") -} - -func (FunctionsRouterSubscriptionFunded) Topic() common.Hash { - return common.HexToHash("0xd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8") -} - -func (FunctionsRouterSubscriptionOwnerTransferRequested) Topic() common.Hash { - return common.HexToHash("0x69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be") -} - -func (FunctionsRouterSubscriptionOwnerTransferred) Topic() common.Hash { - return common.HexToHash("0x6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0") -} - -func (FunctionsRouterTimeLockProposed) Topic() common.Hash { - return common.HexToHash("0x391ced87fc414ac6e67620b6432a8df0e27da63c8cc6782941fb535ac9e06c0a") -} - -func (FunctionsRouterTimeLockUpdated) Topic() common.Hash { - return common.HexToHash("0xbda3a518f5d5dbadc2e16a279c572f58eeddb114eb084747e012080e64c54d1d") -} - -func (FunctionsRouterUnpaused) Topic() common.Hash { - return common.HexToHash("0x5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa") -} - -func (_FunctionsRouter *FunctionsRouter) Address() common.Address { - return _FunctionsRouter.address -} - -type FunctionsRouterInterface interface { - MAXCONSUMERS(opts *bind.CallOpts) (uint16, error) - - GetAdminFee(opts *bind.CallOpts) (*big.Int, error) - - GetConfigHash(opts *bind.CallOpts) ([32]byte, error) - - GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, - - error) - - GetContractById(opts *bind.CallOpts, id [32]byte, useProposed bool) (common.Address, error) - - GetContractById0(opts *bind.CallOpts, id [32]byte) (common.Address, error) - - GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, []common.Address, error) - - GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) - - GetSubscriptionCount(opts *bind.CallOpts) (uint64, error) - - GetTotalBalance(opts *bind.CallOpts) (*big.Int, error) - - IsPaused(opts *bind.CallOpts) (bool, error) - - Owner(opts *bind.CallOpts) (common.Address, error) - - Paused(opts *bind.CallOpts) (bool, error) - - PendingRequestExists(opts *bind.CallOpts, subscriptionId uint64) (bool, error) - - TypeAndVersion(opts *bind.CallOpts) (string, error) - - Version(opts *bind.CallOpts) (uint16, uint16, uint16, error) - - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - - AcceptSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) - - AddConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) - - CancelSubscription(opts *bind.TransactOpts, subscriptionId uint64, to common.Address) (*types.Transaction, error) - - CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) - - Fulfill(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte, juelsPerGas *big.Int, costWithoutFulfillment *big.Int, transmitter common.Address) (*types.Transaction, error) - - OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) - - OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) - - OwnerCancelSubscription(opts *bind.TransactOpts, subscriptionId uint64) (*types.Transaction, error) - - ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) - - ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetFromAddresses []common.Address, proposedContractSetToAddresses []common.Address) (*types.Transaction, error) - - ProposeTimelockBlocks(opts *bind.TransactOpts, blocks uint16) (*types.Transaction, error) - - RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - RemoveConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) - - RequestSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) - - SendRequest(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) - - TimeoutRequests(opts *bind.TransactOpts, requestIdsToTimeout [][32]byte) (*types.Transaction, error) - - TogglePaused(opts *bind.TransactOpts) (*types.Transaction, error) - - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) - - UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) - - UpdateTimelockBlocks(opts *bind.TransactOpts) (*types.Transaction, error) - - ValidateProposedContracts(opts *bind.TransactOpts, id [32]byte, data []byte) (*types.Transaction, error) - - FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) - - WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) - - ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) - - FilterConfigSet(opts *bind.FilterOpts) (*FunctionsRouterConfigSetIterator, error) - - WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigSet) (event.Subscription, error) - - ParseConfigSet(log types.Log) (*FunctionsRouterConfigSet, error) - - FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsRouterConfigUpdatedIterator, error) - - WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigUpdated) (event.Subscription, error) - - ParseConfigUpdated(log types.Log) (*FunctionsRouterConfigUpdated, error) - - FilterContractProposed(opts *bind.FilterOpts) (*FunctionsRouterContractProposedIterator, error) - - WatchContractProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterContractProposed) (event.Subscription, error) - - ParseContractProposed(log types.Log) (*FunctionsRouterContractProposed, error) - - FilterContractUpdated(opts *bind.FilterOpts) (*FunctionsRouterContractUpdatedIterator, error) - - WatchContractUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterContractUpdated) (event.Subscription, error) - - ParseContractUpdated(log types.Log) (*FunctionsRouterContractUpdated, error) - - FilterFundsRecovered(opts *bind.FilterOpts) (*FunctionsRouterFundsRecoveredIterator, error) - - WatchFundsRecovered(opts *bind.WatchOpts, sink chan<- *FunctionsRouterFundsRecovered) (event.Subscription, error) - - ParseFundsRecovered(log types.Log) (*FunctionsRouterFundsRecovered, error) - - FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRouterOwnershipTransferRequestedIterator, error) - - WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRouterOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferRequested(log types.Log) (*FunctionsRouterOwnershipTransferRequested, error) - - FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsRouterOwnershipTransferredIterator, error) - - WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRouterOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferred(log types.Log) (*FunctionsRouterOwnershipTransferred, error) - - FilterPaused(opts *bind.FilterOpts) (*FunctionsRouterPausedIterator, error) - - WatchPaused(opts *bind.WatchOpts, sink chan<- *FunctionsRouterPaused) (event.Subscription, error) - - ParsePaused(log types.Log) (*FunctionsRouterPaused, error) - - FilterRequestEnd(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestEndIterator, error) - - WatchRequestEnd(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestEnd, requestId [][32]byte, subscriptionId []uint64) (event.Subscription, error) - - ParseRequestEnd(log types.Log) (*FunctionsRouterRequestEnd, error) - - FilterRequestStart(opts *bind.FilterOpts, requestId [][32]byte, donId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestStartIterator, error) - - WatchRequestStart(opts *bind.WatchOpts, sink chan<- *FunctionsRouterRequestStart, requestId [][32]byte, donId [][32]byte, subscriptionId []uint64) (event.Subscription, error) - - ParseRequestStart(log types.Log) (*FunctionsRouterRequestStart, error) - - FilterSubscriptionCanceled(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionCanceledIterator, error) - - WatchSubscriptionCanceled(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionCanceled, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionCanceled(log types.Log) (*FunctionsRouterSubscriptionCanceled, error) - - FilterSubscriptionConsumerAdded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionConsumerAddedIterator, error) - - WatchSubscriptionConsumerAdded(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionConsumerAdded, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionConsumerAdded(log types.Log) (*FunctionsRouterSubscriptionConsumerAdded, error) - - FilterSubscriptionConsumerRemoved(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionConsumerRemovedIterator, error) - - WatchSubscriptionConsumerRemoved(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionConsumerRemoved, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionConsumerRemoved(log types.Log) (*FunctionsRouterSubscriptionConsumerRemoved, error) - - FilterSubscriptionCreated(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionCreatedIterator, error) - - WatchSubscriptionCreated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionCreated, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionCreated(log types.Log) (*FunctionsRouterSubscriptionCreated, error) - - FilterSubscriptionFunded(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionFundedIterator, error) - - WatchSubscriptionFunded(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionFunded, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionFunded(log types.Log) (*FunctionsRouterSubscriptionFunded, error) - - FilterSubscriptionOwnerTransferRequested(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionOwnerTransferRequestedIterator, error) - - WatchSubscriptionOwnerTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionOwnerTransferRequested, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionOwnerTransferRequested(log types.Log) (*FunctionsRouterSubscriptionOwnerTransferRequested, error) - - FilterSubscriptionOwnerTransferred(opts *bind.FilterOpts, subscriptionId []uint64) (*FunctionsRouterSubscriptionOwnerTransferredIterator, error) - - WatchSubscriptionOwnerTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsRouterSubscriptionOwnerTransferred, subscriptionId []uint64) (event.Subscription, error) - - ParseSubscriptionOwnerTransferred(log types.Log) (*FunctionsRouterSubscriptionOwnerTransferred, error) - - FilterTimeLockProposed(opts *bind.FilterOpts) (*FunctionsRouterTimeLockProposedIterator, error) - - WatchTimeLockProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockProposed) (event.Subscription, error) - - ParseTimeLockProposed(log types.Log) (*FunctionsRouterTimeLockProposed, error) - - FilterTimeLockUpdated(opts *bind.FilterOpts) (*FunctionsRouterTimeLockUpdatedIterator, error) - - WatchTimeLockUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockUpdated) (event.Subscription, error) - - ParseTimeLockUpdated(log types.Log) (*FunctionsRouterTimeLockUpdated, error) - - FilterUnpaused(opts *bind.FilterOpts) (*FunctionsRouterUnpausedIterator, error) - - WatchUnpaused(opts *bind.WatchOpts, sink chan<- *FunctionsRouterUnpaused) (event.Subscription, error) - - ParseUnpaused(log types.Log) (*FunctionsRouterUnpaused, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 25f24f45118..7500f6f4ab4 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -11,7 +11,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_router" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_router" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" evmRelayTypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" @@ -237,17 +237,17 @@ func (l *logPollerWrapper) getCurrentCoordinators(ctx context.Context) (common.A activeCoordinator, err := l.routerContract.GetContractById(&bind.CallOpts{ Pending: false, Context: ctx, - }, donId, false) + }, donId) if err != nil { return common.Address{}, common.Address{}, err } - proposedCoordinator, err := l.routerContract.GetContractById(&bind.CallOpts{ + proposedCoordinator, err := l.routerContract.GetProposedContractById(&bind.CallOpts{ Pending: false, Context: ctx, - }, donId, true) + }, donId) if err != nil { - return common.Address{}, common.Address{}, err + return activeCoordinator, l.proposedCoordinator, nil } return activeCoordinator, proposedCoordinator, nil @@ -284,6 +284,9 @@ func filterName(addr common.Address) string { } func (l *logPollerWrapper) registerFilters(coordinatorAddress common.Address) error { + if (coordinatorAddress == common.Address{}) { + return nil + } return l.logPoller.RegisterFilter( logpoller.Filter{ Name: filterName(coordinatorAddress), From 605c090901ec4ed571795570b7490a2fccc4eedb Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Wed, 2 Aug 2023 20:22:08 -0700 Subject: [PATCH 068/270] [Functions] Minor logging fixed (#10052) --- .../v1/functions_integration_test.go | 2 +- .../services/relay/evm/functions/logpoller_wrapper.go | 11 ++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index 7d42a100be9..428794d91c5 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -19,7 +19,7 @@ var ( batchSize = 8 ) -func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { +func TestIntegration_Functions_MultipleV1Requests_Success(t *testing.T) { // simulated chain with all contracts owner, b, ticker, coordinatorContractAddress, coordinatorContract, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 7500f6f4ab4..497bc5fc3a7 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -56,7 +56,7 @@ func NewLogPollerWrapper(routerContractAddress common.Address, pluginConfig conf func (l *logPollerWrapper) Start(context.Context) error { return l.StartOnce("LogPollerWrapper", func() error { - l.lggr.Info("starting LogPollerWrapper") + l.lggr.Infow("starting LogPollerWrapper", "routerContract", l.routerContract.Address().Hex(), "contractVersion", l.pluginConfig.ContractVersion) l.mu.Lock() defer l.mu.Unlock() if l.pluginConfig.ContractVersion == 0 { @@ -66,7 +66,7 @@ func (l *logPollerWrapper) Start(context.Context) error { nextBlock, err := l.logPoller.LatestBlock() l.nextBlock = nextBlock if err != nil { - l.lggr.Error("LogPollerWrapper: LatestBlock() failed, starting from 0") + l.lggr.Errorw("LogPollerWrapper: LatestBlock() failed, starting from 0", "error", err) } else { l.lggr.Debugw("LogPollerWrapper: LatestBlock() got starting block", "block", nextBlock) } @@ -186,8 +186,9 @@ func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmR func (l *logPollerWrapper) SubscribeToUpdates(subscriberName string, subscriber evmRelayTypes.RouteUpdateSubscriber) { if l.pluginConfig.ContractVersion == 0 { // in V0, immediately set contract address to Oracle contract and never update again - err := subscriber.UpdateRoutes(l.routerContract.Address(), l.routerContract.Address()) - l.lggr.Errorw("LogPollerWrapper: Failed to update routes", "subscriberName", subscriberName, "error", err) + if err := subscriber.UpdateRoutes(l.routerContract.Address(), l.routerContract.Address()); err != nil { + l.lggr.Errorw("LogPollerWrapper: Failed to update routes", "subscriberName", subscriberName, "error", err) + } } else if l.pluginConfig.ContractVersion == 1 { l.mu.Lock() defer l.mu.Unlock() @@ -199,7 +200,7 @@ func (l *logPollerWrapper) checkForRouteUpdates() { defer l.closeWait.Done() freqSec := l.pluginConfig.ContractUpdateCheckFrequencySec if freqSec == 0 { - l.lggr.Errorw("ContractUpdateCheckFrequencySec is zero - route update checks disabled") + l.lggr.Errorw("LogPollerWrapper: ContractUpdateCheckFrequencySec is zero - route update checks disabled") return } From 114e0394bfffe62c27c09d5ee2de1af5e022e98f Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Thu, 3 Aug 2023 00:41:06 -0400 Subject: [PATCH 069/270] [Functions] (refactor): Various (#10051) * Reapply: s_router is private * Create libraries folder, move Functions->FunctionsRequest & FunctionsResponse types in * Revert HasRouter back to Routable, add natspec * Separate Functions library Buffer import from CBOR * Functions library, using before all * (doc): Add more comments to Functions Request library * Document and clean up FunctionsClient * Geth wrappers --- .../scripts/native_solc_compile_all_functions | 2 +- .../functions/dev/1_0_0/FunctionsBilling.sol | 31 ++++++---- .../functions/dev/1_0_0/FunctionsClient.sol | 62 +++++++++++-------- .../dev/1_0_0/FunctionsCoordinator.sol | 16 +++-- .../functions/dev/1_0_0/FunctionsRouter.sol | 33 +++++----- .../dev/1_0_0/FunctionsSubscriptions.sol | 7 ++- .../dev/1_0_0/{HasRouter.sol => Routable.sol} | 10 ++- .../accessControl/TermsOfServiceAllowList.sol | 6 +- .../1_0_0/example/FunctionsClientExample.sol | 6 +- .../1_0_0/interfaces/FulfillResultCodes.sol | 12 ---- .../interfaces/IFunctionsCoordinator.sol | 4 +- .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 7 +-- .../interfaces/IFunctionsSubscriptions.sol | 4 +- .../interfaces/IOwnableFunctionsRouter.sol | 2 +- .../FunctionsRequest.sol} | 31 +++++----- .../FunctionsResponse.sol} | 15 ++++- .../testhelpers/FunctionsClientTestHelper.sol | 23 +++---- .../1_0_0/testhelpers/FunctionsTestHelper.sol | 16 ++--- .../functions_client/functions_client.go | 2 +- .../functions_client_example.go | 4 +- .../functions_coordinator.go | 30 ++++----- .../functions_router/functions_router.go | 20 +++--- ...rapper-dependency-versions-do-not-edit.txt | 10 +-- core/gethwrappers/functions/go_generate.go | 2 +- 24 files changed, 192 insertions(+), 163 deletions(-) rename contracts/src/v0.8/functions/dev/1_0_0/{HasRouter.sol => Routable.sol} (79%) delete mode 100644 contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol rename contracts/src/v0.8/functions/dev/1_0_0/{Functions.sol => libraries/FunctionsRequest.sol} (78%) rename contracts/src/v0.8/functions/dev/1_0_0/{interfaces/IFunctionsRequest.sol => libraries/FunctionsResponse.sol} (56%) diff --git a/contracts/scripts/native_solc_compile_all_functions b/contracts/scripts/native_solc_compile_all_functions index a0d4f146314..eb061d2a9c8 100755 --- a/contracts/scripts/native_solc_compile_all_functions +++ b/contracts/scripts/native_solc_compile_all_functions @@ -55,7 +55,7 @@ solc-select install $SOLC_VERSION solc-select use $SOLC_VERSION export SOLC_VERSION=$SOLC_VERSION -compileContract 1_0_0 dev/1_0_0/Functions.sol +compileContract 1_0_0 dev/1_0_0/libraries/FunctionsRequest.sol compileContract 1_0_0 dev/1_0_0/FunctionsRouter.sol compileContract 1_0_0 dev/1_0_0/FunctionsCoordinator.sol compileContract 1_0_0 dev/1_0_0/accessControl/TermsOfServiceAllowList.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index da28d2d09d7..0fcc3313d1d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -1,21 +1,23 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {HasRouter} from "./HasRouter.sol"; +import {Routable} from "./Routable.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; -import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; -import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; +import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; + /** * @title Functions Billing contract * @notice Contract that calculates payment from users to the nodes of the Decentralized Oracle Network (DON). * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ -abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { +abstract contract FunctionsBilling is Routable, IFunctionsBilling { + using FunctionsResponse for FunctionsResponse.Commitment; + using FunctionsResponse for FunctionsResponse.FulfillResult; // ================================================================ // | Request Commitment state | // ================================================================ @@ -90,7 +92,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { // ================================================================ // | Initialization | // ================================================================ - constructor(address router, bytes memory config, address linkToNativeFeed) HasRouter(router, config) { + constructor(address router, bytes memory config, address linkToNativeFeed) Routable(router, config) { s_linkToNativeFeed = AggregatorV3Interface(linkToNativeFeed); } @@ -273,7 +275,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { bytes memory data, uint16 requestDataVersion, RequestBilling memory billing - ) internal returns (IFunctionsRequest.Commitment memory commitment) { + ) internal returns (FunctionsResponse.Commitment memory commitment) { // Nodes should support all past versions of the structure if (requestDataVersion > s_config.maxSupportedRequestDataVersion) { revert UnsupportedRequestDataVersion(); @@ -297,7 +299,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { bytes32 requestId = computeRequestId(address(this), billing.client, billing.subscriptionId, initiatedRequests + 1); - commitment = IFunctionsRequest.Commitment({ + commitment = FunctionsResponse.Commitment({ adminFee: billing.adminFee, coordinator: address(this), client: billing.client, @@ -341,14 +343,14 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { bytes memory err, bytes memory onchainMetadata, bytes memory /* offchainMetadata TODO: use in getDonFee() for dynamic billing */ - ) internal returns (FulfillResult) { - IFunctionsRequest.Commitment memory commitment = abi.decode(onchainMetadata, (IFunctionsRequest.Commitment)); + ) internal returns (FunctionsResponse.FulfillResult) { + FunctionsResponse.Commitment memory commitment = abi.decode(onchainMetadata, (FunctionsResponse.Commitment)); if (s_requestCommitments[requestId] == bytes32(0)) { - return FulfillResult.INVALID_REQUEST_ID; + return FunctionsResponse.FulfillResult.INVALID_REQUEST_ID; } if (s_requestCommitments[requestId] != keccak256(abi.encode(commitment))) { - return FulfillResult.INVALID_COMMITMENT; + return FunctionsResponse.FulfillResult.INVALID_COMMITMENT; } int256 weiPerUnitLink; @@ -364,7 +366,7 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { ); // The Functions Router will perform the callback to the client contract - (FulfillResult resultCode, uint96 callbackCostJuels) = _getRouter().fulfill( + (FunctionsResponse.FulfillResult resultCode, uint96 callbackCostJuels) = _getRouter().fulfill( response, err, uint96(juelsPerGas), @@ -373,7 +375,10 @@ abstract contract FunctionsBilling is HasRouter, IFunctionsBilling { commitment ); - if (resultCode == FulfillResult.USER_SUCCESS || resultCode == FulfillResult.USER_ERROR) { + if ( + resultCode == FunctionsResponse.FulfillResult.USER_SUCCESS || + resultCode == FunctionsResponse.FulfillResult.USER_ERROR + ) { delete s_requestCommitments[requestId]; // Reimburse the transmitter for the fulfillment gas cost s_withdrawableTokens[msg.sender] = gasOverheadJuels + callbackCostJuels; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol index cd9da840838..ef774f8aa66 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol @@ -1,66 +1,74 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {Functions} from "./Functions.sol"; +import {FunctionsRequest} from "./libraries/FunctionsRequest.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsClient} from "./interfaces/IFunctionsClient.sol"; /** * @title The Chainlink Functions client contract - * @notice Contract writers can inherit this contract in order to create Chainlink Functions requests + * @notice Contract developers can inherit this contract in order to make Chainlink Functions requests */ abstract contract FunctionsClient is IFunctionsClient { - IFunctionsRouter internal immutable s_router; + using FunctionsRequest for FunctionsRequest.Request; + + IFunctionsRouter internal immutable i_router; event RequestSent(bytes32 indexed id); event RequestFulfilled(bytes32 indexed id); - error OnlyRouterCanFufill(); + error OnlyRouterCanFulfill(); constructor(address router) { - s_router = IFunctionsRouter(router); + i_router = IFunctionsRouter(router); } /** - * @notice Sends a Chainlink Functions request to the stored oracle address - * @param req The initialized Functions.Request - * @param subscriptionId The subscription ID - * @param callbackGasLimit gas limit for the fulfillment callback - * @return requestId The generated request ID + * @notice Sends a Chainlink Functions request + * @param request The Functions.Request initialized in memory + * @param subscriptionId The subscription ID that will be charged to service the request + * @param callbackGasLimit the amount of gas that will be available for the fulfillment callback + * @return requestId The generated request ID for this request */ function _sendRequest( - Functions.Request memory req, + FunctionsRequest.Request memory request, uint64 subscriptionId, uint32 callbackGasLimit, bytes32 donId - ) internal returns (bytes32 requestId) { - bytes memory requestData = Functions.encodeCBOR(req); - requestId = _sendRequestBytes(requestData, subscriptionId, callbackGasLimit, donId); + ) internal returns (bytes32) { + return _sendRequestBytes(FunctionsRequest.encodeCBOR(request), subscriptionId, callbackGasLimit, donId); } /** - * @notice Sends a Chainlink Functions request to the stored oracle address - * @param data The initialized Functions request data - * @param subscriptionId The subscription ID - * @param callbackGasLimit gas limit for the fulfillment callback - * @return requestId The generated request ID + * @notice Sends a Chainlink Functions request + * @param data The CBOR encoded bytes data for a Functions request + * @param subscriptionId The subscription ID that will be charged to service the request + * @param callbackGasLimit the amount of gas that will be available for the fulfillment callback + * @return requestId The generated request ID for this request */ function _sendRequestBytes( bytes memory data, uint64 subscriptionId, uint32 callbackGasLimit, bytes32 donId - ) internal returns (bytes32 requestId) { - requestId = s_router.sendRequest(subscriptionId, data, Functions.REQUEST_DATA_VERSION, callbackGasLimit, donId); + ) internal returns (bytes32) { + bytes32 requestId = i_router.sendRequest( + subscriptionId, + data, + FunctionsRequest.REQUEST_DATA_VERSION, + callbackGasLimit, + donId + ); emit RequestSent(requestId); + return requestId; } /** - * @notice User defined function to handle a response + * @notice User defined function to handle a response from the DON * @param requestId The request ID, returned by sendRequest() - * @param response Aggregated response from the user code - * @param err Aggregated error from the user code or from the execution pipeline - * Either response or error parameter will be set, but never both + * @param response Aggregated response from the execution of the user's source code + * @param err Aggregated error from the execution of the user code or from the execution pipeline + * @dev Either response or error parameter will be set, but never both */ function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal virtual; @@ -68,8 +76,8 @@ abstract contract FunctionsClient is IFunctionsClient { * @inheritdoc IFunctionsClient */ function handleOracleFulfillment(bytes32 requestId, bytes memory response, bytes memory err) external override { - if (msg.sender != address(s_router)) { - revert OnlyRouterCanFufill(); + if (msg.sender != address(i_router)) { + revert OnlyRouterCanFulfill(); } fulfillRequest(requestId, response, err); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 3c0453b730a..3f74fc2a3bd 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -4,9 +4,8 @@ pragma solidity ^0.8.19; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {IFunctionsBilling, FunctionsBilling} from "./FunctionsBilling.sol"; import {OCR2Base} from "./ocr/OCR2Base.sol"; -import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; -import {ITypeAndVersion} from "./HasRouter.sol"; -import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; +import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; +import {ITypeAndVersion} from "./Routable.sol"; /** * @title Functions Coordinator contract @@ -14,6 +13,9 @@ import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilling { + using FunctionsResponse for FunctionsResponse.Commitment; + using FunctionsResponse for FunctionsResponse.FulfillResult; + event OracleRequest( bytes32 indexed requestId, address indexed requestingContract, @@ -145,7 +147,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli */ function sendRequest( Request calldata request - ) external override onlyRouter returns (IFunctionsRequest.Commitment memory commitment) { + ) external override onlyRouter returns (FunctionsResponse.Commitment memory commitment) { if (request.data.length == 0) { revert EmptyRequestData(); } @@ -223,11 +225,13 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli // Bounded by "MaxRequestBatchSize" on the Job's ReportingPluginConfig for (uint256 i = 0; i < requestIds.length; ++i) { - FulfillResult result = FulfillResult( + FunctionsResponse.FulfillResult result = FunctionsResponse.FulfillResult( _fulfillAndBill(requestIds[i], results[i], errors[i], onchainMetadata[i], offchainMetadata[i]) ); - if (result == FulfillResult.USER_SUCCESS || result == FulfillResult.USER_ERROR) { + if ( + result == FunctionsResponse.FulfillResult.USER_SUCCESS || result == FunctionsResponse.FulfillResult.USER_ERROR + ) { emit OracleResponse(requestIds[i], msg.sender); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 114b725878b..0569d7e8594 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -2,16 +2,17 @@ pragma solidity ^0.8.19; import {RouterBase, ITypeAndVersion} from "./RouterBase.sol"; -import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; -import {FulfillResult} from "./interfaces/FulfillResultCodes.sol"; +import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; -import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { + using FunctionsResponse for FunctionsResponse.Commitment; + using FunctionsResponse for FunctionsResponse.FulfillResult; + // We limit return data to a selector plus 4 words. This is to avoid // malicious contracts from returning large amounts of data and causing // repeated out-of-gas scenarios. @@ -34,7 +35,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint64 indexed subscriptionId, uint96 totalCostJuels, address transmitter, - FulfillResult resultCode, + FunctionsResponse.FulfillResult resultCode, bytes response, bytes returnData ); @@ -43,7 +44,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes32 indexed requestId, address coordinator, address transmitter, - FulfillResult resultCode + FunctionsResponse.FulfillResult resultCode ); error OnlyCallableFromCoordinator(); @@ -176,7 +177,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions isValidCallbackGasLimit(subscriptionId, callbackGasLimit); // Forward request to DON - IFunctionsRequest.Commitment memory commitment = coordinator.sendRequest( + FunctionsResponse.Commitment memory commitment = coordinator.sendRequest( IFunctionsCoordinator.Request({ requestingContract: msg.sender, subscriptionOwner: s_subscriptions[subscriptionId].owner, @@ -192,7 +193,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Store a commitment about the request s_requestCommitments[commitment.requestId] = keccak256( abi.encode( - IFunctionsRequest.Commitment({ + FunctionsResponse.Commitment({ adminFee: s_config.adminFee, coordinator: address(coordinator), client: msg.sender, @@ -234,8 +235,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 juelsPerGas, uint96 costWithoutCallback, address transmitter, - IFunctionsRequest.Commitment memory commitment - ) external override returns (FulfillResult resultCode, uint96 callbackGasCostJuels) { + FunctionsResponse.Commitment memory commitment + ) external override returns (FunctionsResponse.FulfillResult resultCode, uint96 callbackGasCostJuels) { _whenNotPaused(); if (msg.sender != commitment.coordinator) { @@ -243,20 +244,20 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions } if (s_requestCommitments[commitment.requestId] == bytes32(0)) { - resultCode = FulfillResult.INVALID_REQUEST_ID; + resultCode = FunctionsResponse.FulfillResult.INVALID_REQUEST_ID; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } if (keccak256(abi.encode(commitment)) != s_requestCommitments[commitment.requestId]) { - resultCode = FulfillResult.INVALID_COMMITMENT; + resultCode = FunctionsResponse.FulfillResult.INVALID_COMMITMENT; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } // Check that the transmitter has supplied enough gas for the callback to succeed if (gasleft() < commitment.callbackGasLimit + commitment.gasOverheadAfterCallback) { - resultCode = FulfillResult.INSUFFICIENT_GAS_PROVIDED; + resultCode = FunctionsResponse.FulfillResult.INSUFFICIENT_GAS_PROVIDED; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } @@ -267,14 +268,14 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Check that the subscription can still afford if (totalCostJuels > s_subscriptions[commitment.subscriptionId].balance) { - resultCode = FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION; + resultCode = FunctionsResponse.FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } // Check that the cost has not exceeded the quoted cost if (totalCostJuels > commitment.estimatedTotalCostJuels) { - resultCode = FulfillResult.COST_EXCEEDS_COMMITMENT; + resultCode = FunctionsResponse.FulfillResult.COST_EXCEEDS_COMMITMENT; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, callbackGasCostJuels); } @@ -289,7 +290,9 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions commitment.callbackGasLimit, commitment.client ); - resultCode = result.success ? FulfillResult.USER_SUCCESS : FulfillResult.USER_ERROR; + resultCode = result.success + ? FunctionsResponse.FulfillResult.USER_SUCCESS + : FunctionsResponse.FulfillResult.USER_ERROR; Receipt memory receipt = _pay( commitment.subscriptionId, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 9c1863aaa9f..79fde9a6ebf 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -5,7 +5,7 @@ import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol" import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; -import {IFunctionsRequest} from "./interfaces/IFunctionsRequest.sol"; +import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; @@ -15,6 +15,7 @@ import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/u * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677ReceiverInterface { + using FunctionsResponse for FunctionsResponse.Commitment; // ================================================================ // | Subscription state | // ================================================================ @@ -457,10 +458,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function timeoutRequests(IFunctionsRequest.Commitment[] calldata requestsToTimeoutByCommitment) external override { + function timeoutRequests(FunctionsResponse.Commitment[] calldata requestsToTimeoutByCommitment) external override { _whenNotPaused(); for (uint256 i = 0; i < requestsToTimeoutByCommitment.length; ++i) { - IFunctionsRequest.Commitment memory request = requestsToTimeoutByCommitment[i]; + FunctionsResponse.Commitment memory request = requestsToTimeoutByCommitment[i]; bytes32 requestId = request.requestId; // Check that request ID is valid diff --git a/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol similarity index 79% rename from contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol rename to contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index 4b5f4295421..efab161640c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/HasRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -6,8 +6,14 @@ import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IOwnableFunctionsRouter} from "./interfaces/IOwnableFunctionsRouter.sol"; -abstract contract HasRouter is ITypeAndVersion, IConfigurable { - IOwnableFunctionsRouter internal immutable s_router; +/** + * @title This abstract should be inherited by contracts that will be used + * as the destinations to a route (id=>contract) on the Router. + * It provides a Router getter and modifiers + * and enforces that the Router can update the configuration of this contract + */ +abstract contract Routable is ITypeAndVersion, IConfigurable { + IOwnableFunctionsRouter private immutable s_router; error RouterMustBeSet(); error OnlyCallableByRouter(); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index f5a5d1fadb2..3d656204dec 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.19; import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.sol"; -import {HasRouter} from "../HasRouter.sol"; +import {Routable} from "../Routable.sol"; import {IAccessController} from "../../../../shared/interfaces/IAccessController.sol"; import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol"; @@ -12,7 +12,7 @@ import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/con /** * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service */ -contract TermsOfServiceAllowList is HasRouter, ITermsOfServiceAllowList, IAccessController { +contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessController { using Address for address; using EnumerableSet for EnumerableSet.AddressSet; @@ -40,7 +40,7 @@ contract TermsOfServiceAllowList is HasRouter, ITermsOfServiceAllowList, IAccess // | Initialization | // ================================================================ - constructor(address router, bytes memory config) HasRouter(router, config) {} + constructor(address router, bytes memory config) Routable(router, config) {} // ================================================================ // | Configuration methods | diff --git a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol index fec5a2bfa49..766cdcac466 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol @@ -2,14 +2,14 @@ pragma solidity ^0.8.19; import {FunctionsClient} from "../FunctionsClient.sol"; -import {Functions} from "../Functions.sol"; +import {FunctionsRequest} from "../libraries/FunctionsRequest.sol"; import {ConfirmedOwner} from "../../../../ConfirmedOwner.sol"; /** * @title Chainlink Functions example client contract implementation */ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { - using Functions for Functions.Request; + using FunctionsRequest for FunctionsRequest.Request; uint32 public constant MAX_CALLBACK_GAS = 70_000; @@ -37,7 +37,7 @@ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { uint64 subscriptionId, bytes32 jobId ) external onlyOwner { - Functions.Request memory req; + FunctionsRequest.Request memory req; req.initializeRequestForInlineJavaScript(source); if (encryptedSecretsReferences.length > 0) req.addSecretsReference(encryptedSecretsReferences); if (args.length > 0) req.setArgs(args); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol deleted file mode 100644 index 86418cd2f3d..00000000000 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/FulfillResultCodes.sol +++ /dev/null @@ -1,12 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.19; - -enum FulfillResult { - USER_SUCCESS, // 0 - USER_ERROR, // 1 - INVALID_REQUEST_ID, // 2 - COST_EXCEEDS_COMMITMENT, // 3 - INSUFFICIENT_GAS_PROVIDED, // 4 - SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION, // 5 - INVALID_COMMITMENT // 6 -} diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 457d1acd87a..22fc505a8e7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IFunctionsRequest} from "./IFunctionsRequest.sol"; +import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; /** * @title Chainlink Functions oracle interface. @@ -75,5 +75,5 @@ interface IFunctionsCoordinator { * @param request The request information, @dev see the struct for field descriptions * @return commitment - The parameters of the request that must be held consistent at response time */ - function sendRequest(Request calldata request) external returns (IFunctionsRequest.Commitment memory commitment); + function sendRequest(Request calldata request) external returns (FunctionsResponse.Commitment memory commitment); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index aa7868ba56f..6a0e50452df 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -2,8 +2,7 @@ pragma solidity ^0.8.19; import {IRouterBase} from "./IRouterBase.sol"; -import {FulfillResult} from "./FulfillResultCodes.sol"; -import {IFunctionsRequest} from "./IFunctionsRequest.sol"; +import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; /** * @title Chainlink Functions Router interface. @@ -91,8 +90,8 @@ interface IFunctionsRouter is IRouterBase { uint96 juelsPerGas, uint96 costWithoutFulfillment, address transmitter, - IFunctionsRequest.Commitment memory commitment - ) external returns (FulfillResult, uint96); + FunctionsResponse.Commitment memory commitment + ) external returns (FunctionsResponse.FulfillResult, uint96); /** * @notice Validate requested gas limit is below the subscription max. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 93d16f70488..e4bdd659980 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IFunctionsRequest} from "./IFunctionsRequest.sol"; +import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; /** * @title Chainlink Functions Subscription interface. @@ -67,7 +67,7 @@ interface IFunctionsSubscriptions { * @param requestsToTimeoutByCommitment - A list of request commitments to time out * @dev The commitment can be found on the "OracleRequest" event created when sending the request. */ - function timeoutRequests(IFunctionsRequest.Commitment[] calldata requestsToTimeoutByCommitment) external; + function timeoutRequests(FunctionsResponse.Commitment[] calldata requestsToTimeoutByCommitment) external; /** * @notice Oracle withdraw LINK earned through fulfilling requests diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol index 8c2ba69ec98..e0c6be5aa9b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol @@ -5,7 +5,7 @@ import {IFunctionsRouter} from "./IFunctionsRouter.sol"; import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; /** - * @title Chainlink base Router interface with Ownable. + * @title Chainlink Functions Router interface with Ownable. */ interface IOwnableFunctionsRouter is IOwnable, IFunctionsRouter { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol similarity index 78% rename from contracts/src/v0.8/functions/dev/1_0_0/Functions.sol rename to contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol index 8a3dc336bc7..ef8b1791f00 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Functions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol @@ -1,21 +1,22 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {CBOR, Buffer} from "../../../vendor/solidity-cborutils/v2.0.0/CBOR.sol"; +import {Buffer} from "../../../../vendor/@ensdomains/buffer/0.1.0/Buffer.sol"; +import {CBOR} from "../../../../vendor/solidity-cborutils/v2.0.0/CBOR.sol"; /** - * @title Library for Chainlink Functions + * @title Library for encoding the input data of a Functions request into CBOR */ -library Functions { +library FunctionsRequest { + using CBOR for Buffer.buffer; + uint16 public constant REQUEST_DATA_VERSION = 1; uint256 internal constant DEFAULT_BUFFER_SIZE = 256; - using CBOR for Buffer.buffer; - enum Location { - Inline, - Remote, - DONHosted + Inline, // Provided within the Request + Remote, // Hosted through remote location that can be accessed through a provided URL + DONHosted // Hosted on the DON's storage } enum CodeLanguage { @@ -24,13 +25,13 @@ library Functions { } struct Request { - Location codeLocation; - Location secretsLocation; // Only Remote secrets are supported - CodeLanguage language; - string source; // Source code for Location.Inline, url for Location.Remote or slot decimal number for Location.DONHosted - bytes encryptedSecretsReference; // Encrypted urls for Location.Remote or CBOR encoded slotid+version for Location.DONHosted, use addDONHostedSecrets() - string[] args; - bytes[] bytesArgs; + Location codeLocation; // The location of the source code that will be executed on each node in the DON + Location secretsLocation; // The location of secrets that will be passed into the source code. *Only Remote secrets are supported + CodeLanguage language; // The coding language that the source code is written in + string source; // Raw source code for Request.codeLocation of Location.Inline, URL for Request.codeLocation of Location.Remote, or slot decimal number for Request.codeLocation of Location.DONHosted + bytes encryptedSecretsReference; // Encrypted URLs for Request.secretsLocation of Location.Remote (use addSecretsReference()), or CBOR encoded slotid+version for Request.secretsLocation of Location.DONHosted (use addDONHostedSecrets()) + string[] args; // String arguments that will be passed into the source code + bytes[] bytesArgs; // Bytes arguments that will be passed into the source code } error EmptySource(); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol similarity index 56% rename from contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol rename to contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol index fe53163d7da..6421ee6b44b 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRequest.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol @@ -1,7 +1,20 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -interface IFunctionsRequest { +/** + * @title Library of types that are used during fulfillment of a Functions request + */ +library FunctionsResponse { + enum FulfillResult { + USER_SUCCESS, // 0 + USER_ERROR, // 1 + INVALID_REQUEST_ID, // 2 + COST_EXCEEDS_COMMITMENT, // 3 + INSUFFICIENT_GAS_PROVIDED, // 4 + SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION, // 5 + INVALID_COMMITMENT // 6 + } + struct Commitment { uint96 adminFee; // -----------┐ address coordinator; // -------┘ diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index 50ee1a77840..175dac932a9 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -1,12 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {FunctionsClient, Functions} from "../../../dev/1_0_0/FunctionsClient.sol"; +import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; +import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; import {ITermsOfServiceAllowList} from "../../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; import {IFunctionsSubscriptions} from "../../../dev/1_0_0/interfaces/IFunctionsSubscriptions.sol"; contract FunctionsClientTestHelper is FunctionsClient { - using Functions for Functions.Request; + using FunctionsRequest for FunctionsRequest.Request; event SendRequestInvoked(bytes32 requestId, string sourceCode, uint64 subscriptionId); event FulfillRequestInvoked(bytes32 requestId, bytes response, bytes err); @@ -27,7 +28,7 @@ contract FunctionsClientTestHelper is FunctionsClient { bytes32 donId, uint32 callbackGasLimit ) public returns (bytes32 requestId) { - Functions.Request memory request; + FunctionsRequest.Request memory request; request.initializeRequestForInlineJavaScript(sourceCode); requestId = _sendRequest(request, subscriptionId, callbackGasLimit, donId); emit SendRequestInvoked(requestId, sourceCode, subscriptionId); @@ -38,14 +39,14 @@ contract FunctionsClientTestHelper is FunctionsClient { uint64 subscriptionId, bytes32 donId ) public returns (bytes32 requestId) { - Functions.Request memory request; + FunctionsRequest.Request memory request; uint32 callbackGasLimit = 20_000; request.initializeRequestForInlineJavaScript(sourceCode); - bytes memory requestData = Functions.encodeCBOR(request); - requestId = s_router.sendRequestToProposed( + bytes memory requestData = FunctionsRequest.encodeCBOR(request); + requestId = i_router.sendRequestToProposed( subscriptionId, requestData, - Functions.REQUEST_DATA_VERSION, + FunctionsRequest.REQUEST_DATA_VERSION, callbackGasLimit, donId ); @@ -54,13 +55,13 @@ contract FunctionsClientTestHelper is FunctionsClient { } function acceptTermsOfService(address acceptor, address recipient, bytes32 r, bytes32 s, uint8 v) external { - bytes32 allowListId = s_router.getAllowListId(); - ITermsOfServiceAllowList allowList = ITermsOfServiceAllowList(s_router.getContractById(allowListId)); + bytes32 allowListId = i_router.getAllowListId(); + ITermsOfServiceAllowList allowList = ITermsOfServiceAllowList(i_router.getContractById(allowListId)); allowList.acceptTermsOfService(acceptor, recipient, r, s, v); } function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external { - IFunctionsSubscriptions(address(s_router)).acceptSubscriptionOwnerTransfer(subscriptionId); + IFunctionsSubscriptions(address(i_router)).acceptSubscriptionOwnerTransfer(subscriptionId); } function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal override { @@ -76,7 +77,7 @@ contract FunctionsClientTestHelper is FunctionsClient { sendSimpleRequestWithJavaScript("somedata", s_subscriptionId, s_donId, 20_000); } if (s_doInvalidReentrantOperation) { - IFunctionsSubscriptions(address(s_router)).cancelSubscription(s_subscriptionId, msg.sender); + IFunctionsSubscriptions(address(i_router)).cancelSubscription(s_subscriptionId, msg.sender); } emit FulfillRequestInvoked(requestId, response, err); } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol index a4bd6d97472..73f10071dbc 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol @@ -1,12 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {Functions} from "../../../dev/1_0_0/Functions.sol"; +import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; contract FunctionsTestHelper { - using Functions for Functions.Request; + using FunctionsRequest for FunctionsRequest.Request; - Functions.Request private s_req; + FunctionsRequest.Request private s_req; event RequestData(bytes data); @@ -15,19 +15,19 @@ contract FunctionsTestHelper { } function initializeRequestForInlineJavaScript(string memory sourceCode) public { - Functions.Request memory r; + FunctionsRequest.Request memory r; r.initializeRequestForInlineJavaScript(sourceCode); storeRequest(r); } function addSecretsReference(bytes memory secrets) public { - Functions.Request memory r = s_req; + FunctionsRequest.Request memory r = s_req; r.addSecretsReference(secrets); storeRequest(r); } function addEmptyArgs() public pure { - Functions.Request memory r; + FunctionsRequest.Request memory r; string[] memory args; r.setArgs(args); } @@ -36,12 +36,12 @@ contract FunctionsTestHelper { string[] memory args = new string[](2); args[0] = arg1; args[1] = arg2; - Functions.Request memory r = s_req; + FunctionsRequest.Request memory r = s_req; r.setArgs(args); storeRequest(r); } - function storeRequest(Functions.Request memory r) private { + function storeRequest(FunctionsRequest.Request memory r) private { s_req.codeLocation = r.codeLocation; s_req.language = r.language; s_req.source = r.source; diff --git a/core/gethwrappers/functions/generated/functions_client/functions_client.go b/core/gethwrappers/functions/generated/functions_client/functions_client.go index 2bfb9bb981c..b6d8a383d16 100644 --- a/core/gethwrappers/functions/generated/functions_client/functions_client.go +++ b/core/gethwrappers/functions/generated/functions_client/functions_client.go @@ -31,7 +31,7 @@ var ( ) var FunctionsClientMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"OnlyRouterCanFulfill\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var FunctionsClientABI = FunctionsClientMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go index ab7b65b454d..ce45300d46d 100644 --- a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go +++ b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go @@ -31,8 +31,8 @@ var ( ) var FunctionsClientExampleMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFufill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162001a1538038062001a15833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b608051611840620001d5600039600081816101c60152610c1b01526118406000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc36600461128c565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e161014336600461135f565b61022d565b6101176201117081565b6100e1610337565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e1610199366004611443565b610439565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517f5099014100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361044d565b505050565b61023561051b565b6102766040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6102b889898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061059e9050565b85156103005761030087878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105af9050565b831561031a5761031a6103138587611479565b82906105f9565b6103298184620111708561063c565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61044161051b565b61044a81610660565b50565b826002541461048b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103b4565b61049482610755565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104d681610755565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461059c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103b4565b565b6105ab82600080846107d7565b5050565b80516000036105ea576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610634576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b6000806106488661086e565b905061065681868686610bdb565b9695505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103b4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806020905060208351101561076a575081515b60005b818110156107d05761078081600861156f565b84828151811061079257610792611586565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107c9816115b5565b905061076d565b5050919050565b8051600003610812576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561082557610825611511565b9081600281111561083857610838611511565b9052506040840182801561084e5761084e611511565b9081801561085e5761085e611511565b9052506060909301929092525050565b6060610878611143565b805161088690610100610cd2565b506108c6816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d4c565b6108e581846000015160028111156108e0576108e0611511565b610d65565b610924816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d4c565b61093e81846040015160008111156108e0576108e0611511565b61097d816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d4c565b61098b818460600151610d4c565b60a08301515115610a2f576109d5816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d4c565b6109de81610d9e565b60005b8360a0015151811015610a2557610a15828560a001518381518110610a0857610a08611586565b6020026020010151610d4c565b610a1e816115b5565b90506109e1565b50610a2f81610dc2565b60808301515115610b2f57600083602001516002811115610a5257610a52611511565b03610a89576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ac8816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d4c565b610ae281846020015160028111156108e0576108e0611511565b610b21816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d4c565b610b2f818460800151610de0565b60c08301515115610bd357610b79816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d4c565b610b8281610d9e565b60005b8360c0015151811015610bc957610bb9828560c001518381518110610bac57610bac611586565b6020026020010151610de0565b610bc2816115b5565b9050610b85565b50610bd381610dc2565b515192915050565b6040517f461d276200000000000000000000000000000000000000000000000000000000815260009073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063461d276290610c599087908990600190899089906004016115ed565b6020604051808303816000875af1158015610c78573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9c919061168d565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a2949350505050565b604080518082019091526060815260006020820152610cf26020836116a6565b15610d1a57610d026020836116a6565b610d0d9060206116e1565b610d1790836116f4565b91505b602080840183905260405180855260008152908184010181811015610d3e57600080fd5b604052508290505b92915050565b610d598260038351610de9565b81516102289082610f10565b8151610d729060c2610f38565b506105ab8282604051602001610d8a91815260200190565b604051602081830303815290604052610de0565b610da9816004610fa1565b600181602001818151610dbc91906116f4565b90525050565b610dcd816007610fa1565b600181602001818151610dbc91906116e1565b610d5982600283515b60178167ffffffffffffffff1611610e16578251610e109060e0600585901b168317610f38565b50505050565b60ff8167ffffffffffffffff1611610e58578251610e3f906018611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166001610fb8565b61ffff8167ffffffffffffffff1611610e9b578251610e82906019611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166002610fb8565b63ffffffff8167ffffffffffffffff1611610ee0578251610ec790601a611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166004610fb8565b8251610ef790601b611fe0600586901b1617610f38565b508251610e109067ffffffffffffffff83166008610fb8565b604080518082019091526060815260006020820152610f318383845161103d565b9392505050565b6040805180820190915260608152600060208201528251516000610f5d8260016116f4565b905084602001518210610f7e57610f7e85610f7983600261156f565b61112c565b8451602083820101858153508051821115610f97578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f38565b6040805180820190915260608152600060208201528351516000610fdc82856116f4565b90508560200151811115610ff957610ff986610f7983600261156f565b6000600161100986610100611827565b61101391906116e1565b90508651828101878319825116178152508051831115611031578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561106057600080fd5b835151600061106f84836116f4565b9050856020015181111561108c5761108c86610f7983600261156f565b8551805183820160200191600091808511156110a6578482525b505050602086015b602086106110e657805182526110c56020836116f4565b91506110d26020826116f4565b90506110df6020876116e1565b95506110ae565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111388383610cd2565b50610e108382610f10565b604051806040016040528061116b604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111ee576111ee611178565b604052919050565b600067ffffffffffffffff83111561121057611210611178565b61124160207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116016111a7565b905082815283838301111561125557600080fd5b828260208301376000602084830101529392505050565b600082601f83011261127d57600080fd5b610f31838335602085016111f6565b6000806000606084860312156112a157600080fd5b83359250602084013567ffffffffffffffff808211156112c057600080fd5b6112cc8783880161126c565b935060408601359150808211156112e257600080fd5b506112ef8682870161126c565b9150509250925092565b60008083601f84011261130b57600080fd5b50813567ffffffffffffffff81111561132357600080fd5b60208301915083602082850101111561133b57600080fd5b9250929050565b803567ffffffffffffffff8116811461135a57600080fd5b919050565b60008060008060008060008060a0898b03121561137b57600080fd5b883567ffffffffffffffff8082111561139357600080fd5b61139f8c838d016112f9565b909a50985060208b01359150808211156113b857600080fd5b6113c48c838d016112f9565b909850965060408b01359150808211156113dd57600080fd5b818b0191508b601f8301126113f157600080fd5b81358181111561140057600080fd5b8c60208260051b850101111561141557600080fd5b60208301965080955050505061142d60608a01611342565b9150608089013590509295985092959890939650565b60006020828403121561145557600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f3157600080fd5b600067ffffffffffffffff8084111561149457611494611178565b8360051b60206114a58183016111a7565b8681529185019181810190368411156114bd57600080fd5b865b84811015611505578035868111156114d75760008081fd5b880136601f8201126114e95760008081fd5b6114f73682358784016111f6565b8452509183019183016114bf565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d4657610d46611540565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115e6576115e6611540565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b8181101561162b5788810183015185820160c00152820161160f565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050611674604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561169f57600080fd5b5051919050565b6000826116dc577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d4657610d46611540565b80820180821115610d4657610d46611540565b600181815b8085111561176057817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561174657611746611540565b8085161561175357918102915b93841c939080029061170c565b509250929050565b60008261177757506001610d46565b8161178457506000610d46565b816001811461179a57600281146117a4576117c0565b6001915050610d46565b60ff8411156117b5576117b5611540565b50506001821b610d46565b5060208310610133831016604e8410600b84101617156117e3575081810a610d46565b6117ed8383611707565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561181f5761181f611540565b029392505050565b6000610f31838361176856fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFulfill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620019f8380380620019f8833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b608051611823620001d5600039600081816101c60152610bdb01526118236000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc36600461126f565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e1610143366004611342565b61022d565b6101176201117081565b6100e1610337565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e1610199366004611426565b610439565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361044d565b505050565b61023561051b565b6102766040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6102b889898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061059e9050565b85156103005761030087878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105af9050565b831561031a5761031a610313858761145c565b82906105f9565b6103298184620111708561063c565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61044161051b565b61044a8161065b565b50565b826002541461048b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103b4565b61049482610750565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104d681610750565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461059c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103b4565b565b6105ab82600080846107d2565b5050565b80516000036105ea576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610634576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b600061065261064a86610869565b858585610bd6565b95945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103b4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060209050602083511015610765575081515b60005b818110156107cb5761077b816008611552565b84828151811061078d5761078d611569565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107c481611598565b9050610768565b5050919050565b805160000361080d576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83836002811115610820576108206114f4565b90816002811115610833576108336114f4565b90525060408401828015610849576108496114f4565b90818015610859576108596114f4565b9052506060909301929092525050565b6060610873611126565b805161088190610100610cb5565b506108c1816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d2f565b6108e081846000015160028111156108db576108db6114f4565b610d48565b61091f816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d2f565b61093981846040015160008111156108db576108db6114f4565b610978816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d2f565b610986818460600151610d2f565b60a08301515115610a2a576109d0816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d2f565b6109d981610d81565b60005b8360a0015151811015610a2057610a10828560a001518381518110610a0357610a03611569565b6020026020010151610d2f565b610a1981611598565b90506109dc565b50610a2a81610da5565b60808301515115610b2a57600083602001516002811115610a4d57610a4d6114f4565b03610a84576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ac3816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d2f565b610add81846020015160028111156108db576108db6114f4565b610b1c816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d2f565b610b2a818460800151610dc3565b60c08301515115610bce57610b74816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d2f565b610b7d81610d81565b60005b8360c0015151811015610bc457610bb4828560c001518381518110610ba757610ba7611569565b6020026020010151610dc3565b610bbd81611598565b9050610b80565b50610bce81610da5565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610c3b9594939291906115d0565b6020604051808303816000875af1158015610c5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c7e9190611670565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b604080518082019091526060815260006020820152610cd5602083611689565b15610cfd57610ce5602083611689565b610cf09060206116c4565b610cfa90836116d7565b91505b602080840183905260405180855260008152908184010181811015610d2157600080fd5b604052508290505b92915050565b610d3c8260038351610dcc565b81516102289082610ef3565b8151610d559060c2610f1b565b506105ab8282604051602001610d6d91815260200190565b604051602081830303815290604052610dc3565b610d8c816004610f84565b600181602001818151610d9f91906116d7565b90525050565b610db0816007610f84565b600181602001818151610d9f91906116c4565b610d3c82600283515b60178167ffffffffffffffff1611610df9578251610df39060e0600585901b168317610f1b565b50505050565b60ff8167ffffffffffffffff1611610e3b578251610e22906018611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166001610f9b565b61ffff8167ffffffffffffffff1611610e7e578251610e65906019611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166002610f9b565b63ffffffff8167ffffffffffffffff1611610ec3578251610eaa90601a611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166004610f9b565b8251610eda90601b611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166008610f9b565b604080518082019091526060815260006020820152610f1483838451611020565b9392505050565b6040805180820190915260608152600060208201528251516000610f408260016116d7565b905084602001518210610f6157610f6185610f5c836002611552565b61110f565b8451602083820101858153508051821115610f7a578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f1b565b6040805180820190915260608152600060208201528351516000610fbf82856116d7565b90508560200151811115610fdc57610fdc86610f5c836002611552565b60006001610fec8661010061180a565b610ff691906116c4565b90508651828101878319825116178152508051831115611014578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561104357600080fd5b835151600061105284836116d7565b9050856020015181111561106f5761106f86610f5c836002611552565b855180518382016020019160009180851115611089578482525b505050602086015b602086106110c957805182526110a86020836116d7565b91506110b56020826116d7565b90506110c26020876116c4565b9550611091565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b815161111b8383610cb5565b50610df38382610ef3565b604051806040016040528061114e604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111d1576111d161115b565b604052919050565b600067ffffffffffffffff8311156111f3576111f361115b565b61122460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8601160161118a565b905082815283838301111561123857600080fd5b828260208301376000602084830101529392505050565b600082601f83011261126057600080fd5b610f14838335602085016111d9565b60008060006060848603121561128457600080fd5b83359250602084013567ffffffffffffffff808211156112a357600080fd5b6112af8783880161124f565b935060408601359150808211156112c557600080fd5b506112d28682870161124f565b9150509250925092565b60008083601f8401126112ee57600080fd5b50813567ffffffffffffffff81111561130657600080fd5b60208301915083602082850101111561131e57600080fd5b9250929050565b803567ffffffffffffffff8116811461133d57600080fd5b919050565b60008060008060008060008060a0898b03121561135e57600080fd5b883567ffffffffffffffff8082111561137657600080fd5b6113828c838d016112dc565b909a50985060208b013591508082111561139b57600080fd5b6113a78c838d016112dc565b909850965060408b01359150808211156113c057600080fd5b818b0191508b601f8301126113d457600080fd5b8135818111156113e357600080fd5b8c60208260051b85010111156113f857600080fd5b60208301965080955050505061141060608a01611325565b9150608089013590509295985092959890939650565b60006020828403121561143857600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f1457600080fd5b600067ffffffffffffffff808411156114775761147761115b565b8360051b602061148881830161118a565b8681529185019181810190368411156114a057600080fd5b865b848110156114e8578035868111156114ba5760008081fd5b880136601f8201126114cc5760008081fd5b6114da3682358784016111d9565b8452509183019183016114a2565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d2957610d29611523565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115c9576115c9611523565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b8181101561160e5788810183015185820160c0015282016115f2565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050611657604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561168257600080fd5b5051919050565b6000826116bf577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d2957610d29611523565b80820180821115610d2957610d29611523565b600181815b8085111561174357817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561172957611729611523565b8085161561173657918102915b93841c93908002906116ef565b509250929050565b60008261175a57506001610d29565b8161176757506000610d29565b816001811461177d5760028114611787576117a3565b6001915050610d29565b60ff84111561179857611798611523565b50506001821b610d29565b5060208310610133831016604e8410600b84101617156117c6575081810a610d29565b6117d083836116ea565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561180257611802611523565b029392505050565b6000610f14838361174b56fea164736f6c6343000813000a", } var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index c76a387bf8f..12ba18863c2 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -30,6 +30,20 @@ var ( _ = abi.ConvertType ) +type FunctionsResponseCommitment struct { + AdminFee *big.Int + Coordinator common.Address + Client common.Address + SubscriptionId uint64 + CallbackGasLimit uint32 + EstimatedTotalCostJuels *big.Int + TimeoutTimestamp *big.Int + RequestId [32]byte + DonFee *big.Int + GasOverheadBeforeCallback *big.Int + GasOverheadAfterCallback *big.Int +} + type IFunctionsBillingRequestBilling struct { SubscriptionId uint64 Client common.Address @@ -49,22 +63,8 @@ type IFunctionsCoordinatorRequest struct { AdminFee *big.Int } -type IFunctionsRequestCommitment struct { - AdminFee *big.Int - Coordinator common.Address - Client common.Address - SubscriptionId uint64 - CallbackGasLimit uint32 - EstimatedTotalCostJuels *big.Int - TimeoutTimestamp *big.Int - RequestId [32]byte - DonFee *big.Int - GasOverheadBeforeCallback *big.Int - GasOverheadAfterCallback *big.Int -} - var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", Bin: "0x60c06040523480156200001157600080fd5b5060405162005ab338038062005ab3833981016040819052620000349162000458565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b03909216919091179055506200062a9350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000219919062000568565b9850985098509850985098509850985098506000811362000251576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260088054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f9062000411908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043d57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046e57600080fd5b620004798462000425565b602085810151919450906001600160401b03808211156200049957600080fd5b818701915087601f830112620004ae57600080fd5b815181811115620004c357620004c362000442565b604051601f8201601f19908116603f01168101908382118183101715620004ee57620004ee62000442565b816040528281528a868487010111156200050757600080fd5b600093505b828410156200052b57848401860151818501870152928501926200050c565b60008684830101528097505050505050506200054a6040850162000425565b90509250925092565b805163ffffffff811681146200043d57600080fd5b60008060008060008060008060006101208a8c0312156200058857600080fd5b620005938a62000553565b9850620005a360208b0162000553565b9750620005b360408b0162000553565b9650620005c360608b0162000553565b9550620005d360808b0162000553565b60a08b01519095506001600160501b0381168114620005f157600080fd5b60c08b015190945061ffff811681146200060a57600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a051615432620006816000396000818161068201528181610ab901528181610edc01528181610fba015281816118af01528181611b4901528181613121015261397d0152600061128001526154326000f3fe608060405234801561001057600080fd5b50600436106101a35760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610517578063d328a91e1461052a578063e3d0e71214610532578063f2fde38b1461054557600080fd5b8063b1dc65a4146103e6578063bdd7e880146103f9578063c3f909d41461041957600080fd5b80638da5cb5b116100c85780638da5cb5b14610388578063af1296d3146103b0578063afcb95d7146103c657600080fd5b806381ff7048146102e557806385b214cf146103525780638cc6acce1461037557600080fd5b806366316d8d11610150578063807560311161012a57806380756031146102b557806381411834146102c857806381f1b938146102dd57600080fd5b806366316d8d1461028757806379ba50971461029a5780637f15e166146102a257600080fd5b806326ceabac1161018157806326ceabac146102395780632a905ccc1461024c578063533989871461027157600080fd5b8063083a5466146101a85780630e7ada39146101bd578063181f5a77146101f0575b600080fd5b6101bb6101b6366004613bf7565b610558565b005b6101d06101cb366004613e24565b6105ad565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b61022c6040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101e79190613f59565b6101bb610247366004613f73565b6105db565b61025461067d565b6040516bffffffffffffffffffffffff90911681526020016101e7565b61027961073b565b6040516101e7929190613fe1565b6101bb610295366004614071565b6109bf565b6101bb610b79565b6101bb6102b0366004613bf7565b610c7b565b6101bb6102c33660046140aa565b610ccb565b6102d0610d82565b6040516101e791906140ff565b61022c610df1565b61032f60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101e7565b610365610360366004614112565b610ec2565b60405190151581526020016101e7565b6101bb61038336600461412b565b610fa2565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101e7565b6103b861101a565b6040519081526020016101e7565b6040805160018152600060208201819052918101919091526060016101e7565b6101bb6103f43660046141ad565b61110d565b61040c610407366004614264565b61183e565b6040516101e791906143c6565b600854600954600a54600c546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101e7565b6102546105253660046143d5565b611b45565b61022c611d11565b6101bb6105403660046144ee565b611d68565b6101bb610553366004613f73565b61278c565b61056061279d565b600081900361059b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105a882848361465c565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061657503373ffffffffffffffffffffffffffffffffffffffff8216145b61064c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e6020526040812061067a91613b3c565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106eb573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052610731919081019061479d565b5090949350505050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107a357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610778575b505050505090506000815167ffffffffffffffff8111156107c6576107c6613c39565b6040519080825280602002602001820160405280156107f957816020015b60608152602001906001900390816107e45790505b50905060005b82518110156109b557600e600084838151811061081e5761081e614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086b906145bb565b90506000036108a6576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e60008483815181106108bc576108bc614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610909906145bb565b80601f0160208091040260200160405190810160405280929190818152602001828054610935906145bb565b80156109825780601f1061095757610100808354040283529160200191610982565b820191906000526020600020905b81548152906001019060200180831161096557829003601f168201915b505050505082828151811061099957610999614898565b6020026020010181905250806109ae906148f6565b90506107ff565b5090939092509050565b6109c7612820565b806bffffffffffffffffffffffff166000036109fd5750336000908152600b60205260409020546bffffffffffffffffffffffff165b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a57576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a849084906bffffffffffffffffffffffff1661492e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610adb7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b5c57600080fd5b505af1158015610b70573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610bff576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c8361279d565b6000819003610cbe576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105a882848361465c565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d165750610cf5336129b1565b8015610d1657503373ffffffffffffffffffffffffffffffffffffffff8416145b610d4c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610d7c82848361465c565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610de757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dbc575b5050505050905090565b6060600f8054610e00906145bb565b9050600003610e3b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610e48906145bb565b80601f0160208091040260200160405190810160405280929190818152602001828054610e74906145bb565b8015610de75780601f10610e9657610100808354040283529160200191610de7565b820191906000526020600020905b815481529060010190602001808311610ea457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f33576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260076020526040902054610f4e57506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610f919084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611011576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61067a81612a9a565b600854600c54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d89190614974565b509350509250508280156110fa57506110f181426149c4565b8463ffffffff16105b1561110557600a5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161116391849163ffffffff851691908e908e9081908401838280828437600092019190915250612da392505050565b611199576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461126e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610bf6565b61127c8b8b8b8b8b8b612dac565b60007f0000000000000000000000000000000000000000000000000000000000000000156112d9576002826020015183604001516112ba91906149d7565b6112c49190614a1f565b6112cf9060016149d7565b60ff1690506112ef565b60208201516112e99060016149d7565b60ff1690505b888114611358576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610bf6565b8887146113c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610bf6565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561140457611404614a41565b600281111561141557611415614a41565b905250905060028160200151600281111561143257611432614a41565b14801561147957506006816000015160ff168154811061145457611454614898565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610bf6565b50505050506114ec613b76565b6000808a8a6040516114ff929190614a70565b604051908190038120611516918e90602001614a80565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561182057600060018489846020811061157f5761157f614898565b61158c91901a601b6149d7565b8e8e8681811061159e5761159e614898565b905060200201358d8d878181106115b7576115b7614898565b90506020020135604051600081526020016040526040516115f4949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611616573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561169657611696614a41565b60028111156116a7576116a7614a41565b90525092506001836020015160028111156116c4576116c4614a41565b1461172b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610bf6565b8251600090879060ff16601f811061174557611745614898565b602002015173ffffffffffffffffffffffffffffffffffffffff16146117c7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610bf6565b8086846000015160ff16601f81106117e1576117e1614898565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261180c6001866149d7565b94505080611819906148f6565b9050611560565b505050611831833383858e8e612e5a565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611906576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119136040830183614a94565b905060000361194d576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a0016040528084606001602081019061196d9190614af9565b67ffffffffffffffff16815260209081019061198b90860186613f73565b73ffffffffffffffffffffffffffffffffffffffff1681526020016119b660e0860160c08701614b16565b63ffffffff1681523a60208201526040016119d8610100860160e08701614b33565b6bffffffffffffffffffffffff1690529050611a456119fa6040850185614a94565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a3f9250505060a0860160808701614b50565b83613028565b9150611a546020840184613f73565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611aa49190614af9565b611ab46040890160208a01613f73565b611ac160408a018a614a94565b611ad160a08c0160808d01614b50565b60a08c0135611ae660e08e0160c08f01614b16565b8c604051602001611af791906143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b37999897969594939291614b6d565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611be557600080fd5b505afa158015611bf9573d6000803e3d6000fd5b50505050620f4240821115611c3a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c4461067d565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611ce888888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105ad915050565b69ffffffffffffffffffff169050611d028686838661351c565b93505050505b95945050505050565b6060600d8054611d20906145bb565b9050600003611d5b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610e48906145bb565b855185518560ff16601f831115611ddb576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610bf6565b80600003611e45576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610bf6565b818314611ed3576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610bf6565b611ede816003614c31565b8311611f46576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610bf6565b611f4e61279d565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f95908861368c565b6005541561214a57600554600090611faf906001906149c4565b9050600060058281548110611fc657611fc6614898565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200057612000614898565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208057612080614c48565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120e9576120e9614c48565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f95915050565b60005b8151518110156125b1576000600460008460000151848151811061217357612173614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121bd576121bd614a41565b14612224576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610bf6565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225557612255614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122f6576122f6614a41565b0217905550600091506123069050565b600460008460200151848151811061232057612320614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561236a5761236a614a41565b146123d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610bf6565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240457612404614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124a5576124a5614a41565b0217905550508251805160059250839081106124c3576124c3614898565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061253f5761253f614898565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125a9816148f6565b91505061214d565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161266991849174010000000000000000000000000000000000000000900416614c77565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126c84630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516136a9565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861277f988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614c94565b60405180910390a1611831565b61279461279d565b61067a81613754565b60005473ffffffffffffffffffffffffffffffffffffffff16331461281e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bf6565b565b600061282a610d82565b90508051600003612867576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612886916bffffffffffffffffffffffff16614d2a565b905060005b82518110156129525781600b60008584815181106128ab576128ab614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129139190614d55565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061294b906148f6565b905061288b565b50815161295f9082614d7a565b600c805460009061297f9084906bffffffffffffffffffffffff1661492e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a1757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129ec575b5050505050905060005b8151811015612a90578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5357612a53614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a80575060019392505050565b612a89816148f6565b9050612a21565b5060009392505050565b600080600080600080600080600089806020019051810190612abc9190614daa565b98509850985098509850985098509850985060008113612b0b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600880547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d8f908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60019392505050565b6000612db9826020614c31565b612dc4856020614c31565b612dd088610144614e56565b612dda9190614e56565b612de49190614e56565b612def906000614e56565b9050368114610b70576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610bf6565b606080808080612e6c86880188614f44565b8451949950929750909550935091501580612e8957508351855114155b80612e9657508251855114155b80612ea357508151855114155b80612eb057508051855114155b15612ee7576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561301a576000612f7f878381518110612f0a57612f0a614898565b6020026020010151878481518110612f2457612f24614898565b6020026020010151878581518110612f3e57612f3e614898565b6020026020010151878681518110612f5857612f58614898565b6020026020010151878781518110612f7257612f72614898565b6020026020010151613849565b90506000816006811115612f9557612f95614a41565b1480612fb257506001816006811115612fb057612fb0614a41565b145b1561300957868281518110612fc957612fc9614898565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b50613013816148f6565b9050612eea565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260085461ffff7e01000000000000000000000000000000000000000000000000000000000000909104811690841611156130e7576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006130f385846105ad565b9050600061311b846040015185606001518469ffffffffffffffffffff16876080015161351c565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa1580156131bd573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526132039190810190615085565b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529192506000919084169063674603d090604401606060405180830381865afa15801561328e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132b29190615154565b50604084015184519193506bffffffffffffffffffffffff871692506132d79161492e565b6bffffffffffffffffffffffff16101561331d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061339c3089602001518a6000015185600161333a91906151a6565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060405180610160016040528089608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896020015173ffffffffffffffffffffffffffffffffffffffff168152602001896000015167ffffffffffffffff168152602001896040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001600860000160109054906101000a900463ffffffff1663ffffffff164261345d9190614e56565b64ffffffffff168152602080820184905269ffffffffffffffffffff891660408084019190915260085463ffffffff680100000000000000008204811660608601526c010000000000000000000000009091041660809093019290925290519198506134cb918991016143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555093979650505050505050565b60008061352761101a565b905060008113613566576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b600854600090879061359c9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c77565b6135a69190614c77565b63ffffffff1690506000612710600860010154886135c49190614c31565b6135ce91906151c7565b6135d89088614e56565b9050600083836135f084670de0b6b3a7640000614c31565b6135fa9190614c31565b61360491906151c7565b905060006136236bffffffffffffffffffffffff808916908a16614e56565b905061363b816b033b2e3c9fd0803ce80000006149c4565b821115613674576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61367e8183614e56565b9a9950505050505050505050565b6000613696610d82565b5111156136a5576136a5612820565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136cd999897969594939291906151db565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137d3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bf6565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906138609190615285565b600088815260076020526040902054909150613880576002915050611d08565b8060405160200161389191906143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526007909352912054146138e3576006915050611d08565b60006138ed61101a565b90506000811361392c576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b6000816139413a670de0b6b3a7640000614c31565b61394b91906151c7565b905060008361014001518461012001516139659190615358565b6139769064ffffffffff1683614c31565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139d79190614d55565b338c6040518763ffffffff1660e01b81526004016139fa96959493929190615376565b60408051808303816000875af1158015613a18573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3c91906153f2565b90925090506000826006811115613a5557613a55614a41565b1480613a7257506001826006811115613a7057613a70614a41565b145b15613b2d5760008c815260076020526040812055613a908184614d55565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100880151600c805469ffffffffffffffffffff90921693909291613afe91859116614d55565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509a9950505050505050505050565b508054613b48906145bb565b6000825580601f10613b58575050565b601f01602090049060005260206000209081019061067a9190613b95565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613baa5760008155600101613b96565b5090565b60008083601f840112613bc057600080fd5b50813567ffffffffffffffff811115613bd857600080fd5b602083019150836020828501011115613bf057600080fd5b9250929050565b60008060208385031215613c0a57600080fd5b823567ffffffffffffffff811115613c2157600080fd5b613c2d85828601613bae565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b60405290565b60405160c0810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b604051610160810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d1f57613d1f613c39565b604052919050565b600082601f830112613d3857600080fd5b813567ffffffffffffffff811115613d5257613d52613c39565b613d8360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613cd8565b818152846020838601011115613d9857600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067a57600080fd5b8035610f9d81613db5565b73ffffffffffffffffffffffffffffffffffffffff8116811461067a57600080fd5b63ffffffff8116811461067a57600080fd5b6bffffffffffffffffffffffff8116811461067a57600080fd5b60008082840360c0811215613e3857600080fd5b833567ffffffffffffffff811115613e4f57600080fd5b613e5b86828701613d27565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613e8e57600080fd5b50613e97613c68565b6020840135613ea581613db5565b81526040840135613eb581613dd6565b60208201526060840135613ec881613df8565b60408201526080840135606082015260a0840135613ee581613e0a565b6080820152919491935090915050565b6000815180845260005b81811015613f1b57602081850181015186830182015201613eff565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613f6c6020830184613ef5565b9392505050565b600060208284031215613f8557600080fd5b8135613f6c81613dd6565b600081518084526020808501945080840160005b83811015613fd657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613fa4565b509495945050505050565b604081526000613ff46040830185613f90565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614062577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614050838351613ef5565b94860194925090850190600101614016565b50909998505050505050505050565b6000806040838503121561408457600080fd5b823561408f81613dd6565b9150602083013561409f81613e0a565b809150509250929050565b6000806000604084860312156140bf57600080fd5b83356140ca81613dd6565b9250602084013567ffffffffffffffff8111156140e657600080fd5b6140f286828701613bae565b9497909650939450505050565b602081526000613f6c6020830184613f90565b60006020828403121561412457600080fd5b5035919050565b60006020828403121561413d57600080fd5b813567ffffffffffffffff81111561415457600080fd5b61416084828501613d27565b949350505050565b60008083601f84011261417a57600080fd5b50813567ffffffffffffffff81111561419257600080fd5b6020830191508360208260051b8501011115613bf057600080fd5b60008060008060008060008060e0898b0312156141c957600080fd5b606089018a8111156141da57600080fd5b8998503567ffffffffffffffff808211156141f457600080fd5b6142008c838d01613bae565b909950975060808b013591508082111561421957600080fd5b6142258c838d01614168565b909750955060a08b013591508082111561423e57600080fd5b5061424b8b828c01614168565b999c989b50969995989497949560c00135949350505050565b60006020828403121561427657600080fd5b813567ffffffffffffffff81111561428d57600080fd5b82016101008185031215613f6c57600080fd5b80516bffffffffffffffffffffffff16825260208101516142d9602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614301604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606081015161431d606084018267ffffffffffffffff169052565b506080810151614335608084018263ffffffff169052565b5060a081015161435560a08401826bffffffffffffffffffffffff169052565b5060c081015161436e60c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143978285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d7c565b61016081016105d582846142a0565b6000806000806000608086880312156143ed57600080fd5b85356143f881613db5565b9450602086013567ffffffffffffffff81111561441457600080fd5b61442088828901613bae565b909550935050604086013561443481613df8565b949793965091946060013592915050565b600067ffffffffffffffff82111561445f5761445f613c39565b5060051b60200190565b600082601f83011261447a57600080fd5b8135602061448f61448a83614445565b613cd8565b82815260059290921b840181019181810190868411156144ae57600080fd5b8286015b848110156144d25780356144c581613dd6565b83529183019183016144b2565b509695505050505050565b803560ff81168114610f9d57600080fd5b60008060008060008060c0878903121561450757600080fd5b863567ffffffffffffffff8082111561451f57600080fd5b61452b8a838b01614469565b9750602089013591508082111561454157600080fd5b61454d8a838b01614469565b965061455b60408a016144dd565b9550606089013591508082111561457157600080fd5b61457d8a838b01613d27565b945061458b60808a01613dcb565b935060a08901359150808211156145a157600080fd5b506145ae89828a01613d27565b9150509295509295509295565b600181811c908216806145cf57607f821691505b602082108103614608577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105a857600081815260208120601f850160051c810160208610156146355750805b601f850160051c820191505b8181101561465457828155600101614641565b505050505050565b67ffffffffffffffff83111561467457614674613c39565b6146888361468283546145bb565b8361460e565b6000601f8411600181146146da57600085156146a45750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614770565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147295786850135825560209485019460019092019101614709565b5086821015614764577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461067a57600080fd5b8051610f9d81613e0a565b8051610f9d81613df8565b600080600080608085870312156147b357600080fd5b84516147be81614777565b809450506020808601516147d181613e0a565b60408701519094507fffffffff000000000000000000000000000000000000000000000000000000008116811461480757600080fd5b606087015190935067ffffffffffffffff81111561482457600080fd5b8601601f8101881361483557600080fd5b805161484361448a82614445565b81815260059190911b8201830190838101908a83111561486257600080fd5b928401925b8284101561488957835161487a81613df8565b82529284019290840190614867565b979a9699509497505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614927576149276148c7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614953576149536148c7565b5092915050565b805169ffffffffffffffffffff81168114610f9d57600080fd5b600080600080600060a0868803121561498c57600080fd5b6149958661495a565b94506020860151935060408601519250606086015191506149b86080870161495a565b90509295509295909350565b818103818111156105d5576105d56148c7565b60ff81811683821601908111156105d5576105d56148c7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a3257614a326149f0565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614ac957600080fd5b83018035915067ffffffffffffffff821115614ae457600080fd5b602001915036819003821315613bf057600080fd5b600060208284031215614b0b57600080fd5b8135613f6c81613db5565b600060208284031215614b2857600080fd5b8135613f6c81613df8565b600060208284031215614b4557600080fd5b8135613f6c81613e0a565b600060208284031215614b6257600080fd5b8135613f6c81614777565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c0a60c085018763ffffffff169052565b818482030160e0850152614c2082820186613ef5565b9d9c50505050505050505050505050565b80820281158282048414176105d5576105d56148c7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614953576149536148c7565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cc48184018a613f90565b90508281036080840152614cd88189613f90565b905060ff871660a084015282810360c0840152614cf58187613ef5565b905067ffffffffffffffff851660e0840152828103610100840152614d1a8185613ef5565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614d4957614d496149f0565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614953576149536148c7565b6bffffffffffffffffffffffff818116838216028082169190828114614da257614da26148c7565b505092915050565b60008060008060008060008060006101208a8c031215614dc957600080fd5b8951614dd481613df8565b60208b0151909950614de581613df8565b60408b0151909850614df681613df8565b60608b0151909750614e0781613df8565b60808b0151909650614e1881613df8565b9450614e2660a08b0161495a565b935060c08a0151614e3681614777565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105d5576105d56148c7565b600082601f830112614e7a57600080fd5b81356020614e8a61448a83614445565b82815260059290921b84018101918181019086841115614ea957600080fd5b8286015b848110156144d25780358352918301918301614ead565b600082601f830112614ed557600080fd5b81356020614ee561448a83614445565b82815260059290921b84018101918181019086841115614f0457600080fd5b8286015b848110156144d257803567ffffffffffffffff811115614f285760008081fd5b614f368986838b0101613d27565b845250918301918301614f08565b600080600080600060a08688031215614f5c57600080fd5b853567ffffffffffffffff80821115614f7457600080fd5b614f8089838a01614e69565b96506020880135915080821115614f9657600080fd5b614fa289838a01614ec4565b95506040880135915080821115614fb857600080fd5b614fc489838a01614ec4565b94506060880135915080821115614fda57600080fd5b614fe689838a01614ec4565b93506080880135915080821115614ffc57600080fd5b5061500988828901614ec4565b9150509295509295909350565b8051610f9d81613dd6565b600082601f83011261503257600080fd5b8151602061504261448a83614445565b82815260059290921b8401810191818101908684111561506157600080fd5b8286015b848110156144d257805161507881613dd6565b8352918301918301615065565b60006020828403121561509757600080fd5b815167ffffffffffffffff808211156150af57600080fd5b9083019060c082860312156150c357600080fd5b6150cb613c91565b82516150d681613e0a565b815260208301516150e681613dd6565b602082015260408301516150f981613e0a565b604082015261510a60608401615016565b606082015260808301518281111561512157600080fd5b61512d87828601615021565b60808301525060a083015160a082015280935050505092915050565b8051610f9d81613db5565b60008060006060848603121561516957600080fd5b8351801515811461517957600080fd5b602085015190935061518a81613db5565b604085015190925061519b81613db5565b809150509250925092565b67ffffffffffffffff818116838216019080821115614953576149536148c7565b6000826151d6576151d66149f0565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526152228285018b613f90565b91508382036080850152615236828a613f90565b915060ff881660a085015283820360c08501526152538288613ef5565b90861660e08501528381036101008501529050614d1a8185613ef5565b805164ffffffffff81168114610f9d57600080fd5b6000610160828403121561529857600080fd5b6152a0613cb4565b6152a983614787565b81526152b760208401615016565b60208201526152c860408401615016565b60408201526152d960608401615149565b60608201526152ea60808401614792565b60808201526152fb60a08401614787565b60a082015261530c60c08401615270565b60c082015260e083015160e082015261010061532981850161495a565b9082015261012061533b848201615270565b9082015261014061534d848201615270565b908201529392505050565b64ffffffffff818116838216019080821115614953576149536148c7565b600061020080835261538a8184018a613ef5565b9050828103602084015261539e8189613ef5565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153e7905060a08301846142a0565b979650505050505050565b6000806040838503121561540557600080fd5b82516007811061541457600080fd5b602084015190925061409f81613e0a56fea164736f6c6343000813000a", } diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 1a4079979f0..be91cd95d2d 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -30,7 +30,7 @@ var ( _ = abi.ConvertType ) -type IFunctionsRequestCommitment struct { +type FunctionsResponseCommitment struct { AdminFee *big.Int Coordinator common.Address Client common.Address @@ -54,7 +54,7 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AlreadyApplied\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"\",\"type\":\"uint32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structIFunctionsRequest.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AlreadyApplied\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"\",\"type\":\"uint32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", Bin: "0x60a06040523480156200001157600080fd5b50604051620066d0380380620066d0833981016040819052620000349162000441565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d9816200016e565b50506008805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e816200021f565b5050600980546001600160a01b0319166001600160a01b03949094169390931790925550620006cd945050505050565b336001600160a01b03821603620001c85760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080600080848060200190518101906200023b91906200053e565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600e80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002cb91600f919086019062000313565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000304939291906200065c565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003b75791602002820160005b838211156200038357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200033d565b8015620003b55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000383565b505b50620003c5929150620003c9565b5090565b5b80821115620003c55760008155600101620003ca565b805161ffff81168114620003f357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004395762000439620003f8565b604052919050565b600080600080608085870312156200045857600080fd5b6200046385620003e0565b9350602062000474818701620003e0565b60408701519094506001600160a01b03811681146200049257600080fd5b60608701519093506001600160401b0380821115620004b057600080fd5b818801915088601f830112620004c557600080fd5b815181811115620004da57620004da620003f8565b620004ee601f8201601f191685016200040e565b915080825289848285010111156200050557600080fd5b60005b818110156200052557838101850151838201860152840162000508565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055557600080fd5b6200056085620003e0565b602086810151919550906001600160601b03811681146200058057600080fd5b60408701519094506001600160e01b0319811681146200059f57600080fd5b60608701519093506001600160401b0380821115620005bd57600080fd5b818801915088601f830112620005d257600080fd5b815181811115620005e757620005e7620003f8565b8060051b9150620005fa8483016200040e565b818152918301840191848101908b8411156200061557600080fd5b938501935b838510156200064c578451925063ffffffff831683146200063b5760008081fd5b82825293850193908501906200061a565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bf57845163ffffffff16835293830193918301916001016200069b565b509098975050505050505050565b608051615fe7620006e96000396000612af60152615fe76000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063aab396bd116100ee578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f1461076f578063eb523d6c14610782578063f2fde38b1461079557600080fd5b8063d7ae1d3014610736578063e72f6e3014610749578063e82ad7d41461075c57600080fd5b8063b734c0f4116100c8578063b734c0f4146106ff578063badc3eb614610707578063c3f909d41461071e57600080fd5b8063aab396bd146106bb578063b187bd26146106e1578063b5643858146106ec57600080fd5b80639f87fad711610150578063a47c76961161012a578063a47c769614610675578063a4c0ed3614610695578063a9c9a918146106a857600080fd5b80639f87fad714610639578063a1d4c8281461064c578063a21a23e41461066d57600080fd5b80638456cb59116101815780638456cb59146106065780638da5cb5b1461060e5780638fde53171461063157600080fd5b806379ba5097146105eb57806382359740146105f357600080fd5b8063461d27621161025557806366316d8d116102095780636a2215de116101e35780636a2215de1461058d5780636e3b3323146105c55780637341c10c146105d857600080fd5b806366316d8d146104b857806366419970146104cb578063674603d0146104f857600080fd5b806355fedefa1161023a57806355fedefa146104615780635c975abb1461048e5780635ed6dfba146104a557600080fd5b8063461d27621461043b5780634b8832d31461044e57600080fd5b80631c024539116102b75780633e871e4d116102915780633e871e4d146103ff5780633f4ba83a1461041257806341db4ca31461041a57600080fd5b80631c024539146103d15780631ded3b36146103d9578063385de9ae146103ec57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038857600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614ac3565b6107a8565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b610317610347366004614b04565b610807565b6008546a010000000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610330565b6103c46040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614ba1565b610317610931565b6103176103e7366004614bb4565b610a93565b6103176103fa366004614c29565b610ac4565b61031761040d366004614de2565b610b8d565b610317610e83565b61042d610428366004614eab565b610e95565b604051908152602001610330565b61042d610449366004614eab565b610ef5565b61031761045c366004614f30565b610f01565b61042d61046f366004614ac3565b67ffffffffffffffff166000908152600a602052604090206003015490565b60005460ff165b6040519015158152602001610330565b6103176104b3366004614f83565b610fff565b6103176104c6366004614f83565b6112d4565b60085462010000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b610565610506366004614fb1565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600b6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b6105a061059b366004614fdf565b6114fb565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105d3366004614ff8565b6115ba565b6103176105e6366004614f30565b611890565b610317611a26565b610317610601366004614ac3565b611b48565b610317611c7f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105a0565b610317611c8f565b610317610647366004614f30565b611d81565b61065f61065a366004615211565b612161565b6040516103309291906152f9565b6104df61254d565b610688610683366004614ac3565b6126e0565b6040516103309190615373565b6103176106a33660046153fb565b612815565b6105a06106b6366004614fdf565b612a44565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761042d565b60005460ff16610495565b6103176106fa366004615457565b612aaa565b610317612c0b565b61070f612d9f565b60405161033093929190615474565b610726612e7a565b60405161033094939291906154ff565b610317610744366004614f30565b612f45565b610317610757366004615562565b612fa8565b61049561076a366004614ac3565b6131b2565b61031761077d36600461557f565b6131c3565b610317610790366004614fdf565b6132aa565b6103176107a3366004615562565b613466565b6107b0613477565b6107b98161347f565b67ffffffffffffffff81166000908152600a60205260409020546108049082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166134f5565b50565b67ffffffffffffffff82166000908152600a6020526040812060030154600f54911a90811061086c576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600f805460ff8316908110610883576108836155c1565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561092c57600f805460ff83169081106108d3576108d36155c1565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610863565b505050565b610939613863565b60008080526006602052604080518082019091527f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f880548290829061097d906155f0565b80601f01602080910402602001604051908101604052809291908181526020018280546109a9906155f0565b80156109f65780601f106109cb576101008083540402835291602001916109f6565b820191906000526020600020905b8154815290600101906020018083116109d957829003601f168201915b5050505050815260200160018201548152505090508060200151431015610a49576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051610a54906138e9565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a889160009190615643565b60405180910390a150565b610a9b613477565b610aa48261347f565b67ffffffffffffffff9091166000908152600a6020526040902060030155565b610acc613863565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600854602090910190610b219061ffff1643615693565b9052600084815260066020526040902081518190610b3f90826156f4565b50602082015181600101559050507fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a838383604051610b809392919061580e565b60405180910390a1505050565b610b95613863565b8151815181141580610ba75750600881115b15610bde576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610d0a576000848281518110610bfd57610bfd6155c1565b602002602001015190506000848381518110610c1b57610c1b6155c1565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c86575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cbd576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cf7576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610863565b505080610d0390615862565b9050610be1565b50600854600090610d1f9061ffff1643615693565b604080516060810182528681526020808201879052918101839052865192935091600391610d51918391890190614903565b506020828101518051610d6a926001850192019061494a565b506040820151816002015590505060005b8451811015610e7c577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610db757610db76155c1565b602002602001015160026000888581518110610dd557610dd56155c1565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e1e57610e1e6155c1565b602002602001015185604051610e64949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e7581615862565b9050610d7b565b5050505050565b610e8b613863565b610e93613a2f565b565b600080610ea1836114fb565b9050610ee983828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613aac9050565b98975050505050505050565b600080610ea183612a44565b610f09613dfc565b610f1282613e04565b610f1a613eca565b67ffffffffffffffff82166000908152600a602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c010000000000000000000000009092041614610ffb5767ffffffffffffffff82166000818152600a602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b611007613477565b806bffffffffffffffffffffffff1660000361103d5750306000908152600c60205260409020546bffffffffffffffffffffffff165b306000908152600c60205260409020546bffffffffffffffffffffffff80831691161015611097576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600c6020526040812080548392906110c49084906bffffffffffffffffffffffff1661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806008600a8282829054906101000a90046bffffffffffffffffffffffff1661111b919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156111ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111de91906158c6565b610ffb576009546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611251573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061127591906158e8565b6008546040517fa99da3020000000000000000000000000000000000000000000000000000000081526a01000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610863565b6112dc613dfc565b806bffffffffffffffffffffffff16600003611324576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c60205260409020546bffffffffffffffffffffffff8083169116101561137e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906113ab9084906bffffffffffffffffffffffff1661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806008600a8282829054906101000a90046bffffffffffffffffffffffff16611402919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156114a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114c591906158c6565b610ffb576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b60035460ff82161015611584576003805460ff8316908110611523576115236155c1565b90600052602060002001548303611574576004805460ff831690811061154b5761154b6155c1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61157d81615901565b90506114ff565b506040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101839052602401610863565b6115c2613dfc565b60005b8181101561092c5760008383838181106115e1576115e16155c1565b905061016002018036038101906115f89190615920565b905060008160e001519050600d60008281526020019081526020016000205482604051602001611628919061593d565b6040516020818303038152906040528051906020012014611675576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156116ba576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561172c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061175091906158c6565b5060a0830151606084015167ffffffffffffffff166000908152600a6020526040812060010180549091906117949084906bffffffffffffffffffffffff1661589a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600b6020908152828220606087015167ffffffffffffffff9081168452915291902080546001926009916118209185916901000000000000000000900416615a6c565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600d60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061188990615862565b90506115c5565b611898613dfc565b6118a182613e04565b6118a9613eca565b600e5467ffffffffffffffff83166000908152600a602052604090206002015461ffff9091169003611907576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b6020908152604080832067ffffffffffffffff8616845290915290205460ff161561194e575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600b6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600a84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610ff2565b60015473ffffffffffffffffffffffffffffffffffffffff163314611aa7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610863565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b50613dfc565b611b58613eca565b67ffffffffffffffff81166000908152600a60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611be0576040517f02b543c600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000818152600a602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611c87613863565b610e93613fcf565b611c97613863565b60075464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611cf9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075460085461ffff620100009092048216911603611d43576040517ea8180600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600754600880546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611d89613dfc565b611d9282613e04565b611d9a613eca565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e42576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e97576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600a6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f1257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611ee7575b50505050509050600060018251611f299190615a8d565b905060005b82518110156120c5578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f6057611f606155c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120b5576000838381518110611f9757611f976155c1565b6020026020010151905080600a60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611fdd57611fdd6155c1565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600a9091526040902060020180548061205757612057615aa0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120c5565b6120be81615862565b9050611f2e565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600b6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60008061216c613dfc565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146121d5576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600d602052604090205461223a57600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b60405180910390a2612542565b600d60008460e0015181526020019081526020016000205483604051602001612263919061593d565b60405160208183030381529060405280519060200120146122be57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b826101400151836080015163ffffffff166122d99190615b01565b64ffffffffff165a101561232757600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b600061233c846080015163ffffffff1661402a565b6123469088615b1f565b905060008187866000015161235b9190615b47565b6123659190615b47565b606086015167ffffffffffffffff166000908152600a60205260409020549091506bffffffffffffffffffffffff90811690821611156123ee57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123df93929190615acf565b60405180910390a25050612542565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561245657600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123df93929190615acf565b5050600d60008460e00151815260200190815260200160002060009055600061248e8460e001518a8a876080015188604001516140cc565b805190915061249e5760016124a1565b60005b925060006124d085606001518660a00151876040015188600001518c6124ca886020015161402a565b8d614248565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b83602001518988876000015161251d578e61251f565b8f5b8860400151604051612535959493929190615b6c565b60405180910390a3519150505b965096945050505050565b6000612557613dfc565b61255f613eca565b6008805460029061257f9062010000900467ffffffffffffffff16615bce565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156125f5578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600a825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926126909260028501929091019061494a565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261271a8261347f565b67ffffffffffffffff82166000908152600a6020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156127fb57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116127d0575b505050505081526020016003820154815250509050919050565b61281d613dfc565b60095473ffffffffffffffffffffffffffffffffffffffff16331461286e576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146128a8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006128b682840184614ac3565b67ffffffffffffffff81166000908152600a60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661292f576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600a6020526040812080546bffffffffffffffffffffffff16918691906129668385615b47565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846008600a8282829054906101000a90046bffffffffffffffffffffffff166129bd9190615b47565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8828784612a249190615693565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff168015612a755792915050565b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610863565b612ab2613863565b60085461ffff808316911603612af4576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff161115612b56576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260085461ffff90811680835290841660208301529091820190612b839043615693565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516007805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612c13613863565b600554431015612c4f576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612d7657600060036000018281548110612c7457612c746155c1565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612cc057612cc06155c1565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612d6f90615862565b9050612c52565b5060036000612d8582826149c4565b612d936001830160006149c4565b60028201600090555050565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612dff57602002820191906000526020600020905b815481526020019060010190808311612deb575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612e6857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e3d575b50505050509050925092509250909192565b600e54600f8054604080516020808402820181019092528281526000948594859460609461ffff8416946bffffffffffffffffffffffff62010000860416946e010000000000000000000000000000900460e01b93929091839190830182828015612f3057602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ef35790505b50505050509050935093509350935090919293565b612f4d613dfc565b612f5682613e04565b612f5e613eca565b612f6782614491565b15612f9e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ffb82826134f5565b612fb0613477565b6009546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561301f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061304391906158e8565b6008549091506a010000000000000000000090046bffffffffffffffffffffffff16818111156130a9576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610863565b8181101561092c5760006130bd8284615a8d565b6009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015613138573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061315c91906158c6565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b60006131bd82614491565b92915050565b6131cb613863565b6040805160606020601f850181900402820181018352918101838152909182919085908590819085018382808284376000920191909152505050908252506008546020909101906132209061ffff1643615693565b905260008052600660205280517f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f890819061325b90826156f4565b50602091909101516001909101556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a9061329e906000908590859061580e565b60405180910390a15050565b6132b2613863565b60008181526006602052604080822081518083019092528054829082906132d8906155f0565b80601f0160208091040260200160405190810160405280929190818152602001828054613304906155f0565b80156133515780601f1061332657610100808354040283529160200191613351565b820191906000526020600020905b81548152906001019060200180831161333457829003601f168201915b50505050508152602001600182015481525050905080602001514310156133a4576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6133ad82612a44565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161340191600401614ba1565b600060405180830381600087803b15801561341b57600080fd5b505af115801561342f573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c7935061329e9250859190615643565b61346e613863565b610804816145e0565b610e93613863565b67ffffffffffffffff81166000908152600a60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600a60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156135d657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116135ab575b505050918352505060039190910154602090910152805190915060005b82608001515181101561369757600b60008460800151838151811061361a5761361a6155c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561369081615862565b90506135f3565b5067ffffffffffffffff84166000908152600a6020526040812081815560018101829055906136c960028301826149c4565b60038201600090555050806008600a8282829054906101000a90046bffffffffffffffffffffffff166136fc919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561379b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137bf91906158c6565b6137f5576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610863565b600080600080848060200190518101906139039190615c0b565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600e80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a5094985092965090945090926139e991600f91908601906149e2565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051613a2093929190615d06565b60405180910390a15050505050565b613a376146db565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613ab6613dfc565b613abf8561347f565b613ac93386614747565b613ad38583610807565b604080516101008101825233815267ffffffffffffffff87166000818152600a6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b1660808801529484529190526003015460a084015263ffffffff861660c0840152600e546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e88091613bb39190600401615d5e565b610160604051808303816000875af1158015613bd3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bf79190615e49565b9050604051806101600160405280600e60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613d06919061593d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600d90935291205560a0810151613d6090339088906147bb565b60e081015167ffffffffffffffff87166000818152600a60205260409081902054905191928b9290917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613de5916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908d908d908d90615f1c565b60405180910390a460e00151979650505050505050565b610e93614896565b67ffffffffffffffff81166000908152600a60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e7b576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610ffb576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ef37fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097612a44565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613f5690339060248101615f80565b602060405180830381865afa158015613f73573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f9791906158c6565b610e93576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610863565b613fd7614896565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a823390565b60006bffffffffffffffffffffffff8211156140c8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610863565b5090565b60408051606080820183526000808352602083015291810191909152600e546040516000916e010000000000000000000000000000900460e01b9061411990899089908990602401615faf565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b6141cb57600080fd5b5a6113888110156141db57600080fd5b6113888103905087604082048203116141f357600080fd5b60008086516020880160008b8df193505a900391503d6084811115614216575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006142688486615b1f565b90506000816142778886615b47565b6142819190615b47565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600a9091529283208054929750939450849392916142d89185911661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846143129190615b47565b336000908152600c60205260408120805490919061433f9084906bffffffffffffffffffffffff16615b47565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600c6020526040812080548b9450909261438691859116615b47565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600a6020526040812060010180548d945090926143da9185911661589a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600b6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161445e9185916901000000000000000000900416615a6c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b67ffffffffffffffff81166000908152600a602090815260408083206002018054825181850281018501909352808352849383018282801561450957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116144de575b5050505050905060005b81518110156145d6576000600b6000848481518110614534576145346155c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146145c557506001949350505050565b506145cf81615862565b9050614513565b5060009392505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361465f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610863565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610863565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600b6020908152604080832067ffffffffffffffff8516845290915290205460ff16610ffb576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600a6020526040812060010180548392906147f59084906bffffffffffffffffffffffff16615b47565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600b6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261486b928492900416615a6c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610863565b82805482825590600052602060002090810192821561493e579160200282015b8281111561493e578251825591602001919060010190614923565b506140c8929150614a88565b82805482825590600052602060002090810192821561493e579160200282015b8281111561493e57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061496a565b50805460008255906000526020600020908101906108049190614a88565b8280548282559060005260206000209060070160089004810192821561493e5791602002820160005b83821115614a4f57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a0b565b8015614a7f5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a4f565b50506140c89291505b5b808211156140c85760008155600101614a89565b67ffffffffffffffff8116811461080457600080fd5b8035614abe81614a9d565b919050565b600060208284031215614ad557600080fd5b8135614ae081614a9d565b9392505050565b63ffffffff8116811461080457600080fd5b8035614abe81614ae7565b60008060408385031215614b1757600080fd5b8235614b2281614a9d565b91506020830135614b3281614ae7565b809150509250929050565b6000815180845260005b81811015614b6357602081850181015186830182015201614b47565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614ae06020830184614b3d565b60008060408385031215614bc757600080fd5b8235614bd281614a9d565b946020939093013593505050565b60008083601f840112614bf257600080fd5b50813567ffffffffffffffff811115614c0a57600080fd5b602083019150836020828501011115614c2257600080fd5b9250929050565b600080600060408486031215614c3e57600080fd5b83359250602084013567ffffffffffffffff811115614c5c57600080fd5b614c6886828701614be0565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614cc857614cc8614c75565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d1557614d15614c75565b604052919050565b600067ffffffffffffffff821115614d3757614d37614c75565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461080457600080fd5b8035614abe81614d41565b600082601f830112614d7f57600080fd5b81356020614d94614d8f83614d1d565b614cce565b82815260059290921b84018101918181019086841115614db357600080fd5b8286015b84811015614dd7578035614dca81614d41565b8352918301918301614db7565b509695505050505050565b60008060408385031215614df557600080fd5b823567ffffffffffffffff80821115614e0d57600080fd5b818501915085601f830112614e2157600080fd5b81356020614e31614d8f83614d1d565b82815260059290921b84018101918181019089841115614e5057600080fd5b948201945b83861015614e6e57853582529482019490820190614e55565b96505086013592505080821115614e8457600080fd5b50614e9185828601614d6e565b9150509250929050565b61ffff8116811461080457600080fd5b60008060008060008060a08789031215614ec457600080fd5b8635614ecf81614a9d565b9550602087013567ffffffffffffffff811115614eeb57600080fd5b614ef789828a01614be0565b9096509450506040870135614f0b81614e9b565b92506060870135614f1b81614ae7565b80925050608087013590509295509295509295565b60008060408385031215614f4357600080fd5b8235614f4e81614a9d565b91506020830135614b3281614d41565b6bffffffffffffffffffffffff8116811461080457600080fd5b8035614abe81614f5e565b60008060408385031215614f9657600080fd5b8235614fa181614d41565b91506020830135614b3281614f5e565b60008060408385031215614fc457600080fd5b8235614fcf81614d41565b91506020830135614b3281614a9d565b600060208284031215614ff157600080fd5b5035919050565b6000806020838503121561500b57600080fd5b823567ffffffffffffffff8082111561502357600080fd5b818501915085601f83011261503757600080fd5b81358181111561504657600080fd5b8660206101608302850101111561505c57600080fd5b60209290920196919550909350505050565b600082601f83011261507f57600080fd5b813567ffffffffffffffff81111561509957615099614c75565b6150ca60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cce565b8181528460208386010111156150df57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461080457600080fd5b8035614abe816150fc565b69ffffffffffffffffffff8116811461080457600080fd5b8035614abe8161511a565b6000610160828403121561515057600080fd5b615158614ca4565b905061516382614f78565b815261517160208301614d63565b602082015261518260408301614d63565b604082015261519360608301614ab3565b60608201526151a460808301614af9565b60808201526151b560a08301614f78565b60a08201526151c660c0830161510f565b60c082015260e082013560e08201526101006151e3818401615132565b908201526101206151f583820161510f565b9082015261014061520783820161510f565b9082015292915050565b600080600080600080610200878903121561522b57600080fd5b863567ffffffffffffffff8082111561524357600080fd5b61524f8a838b0161506e565b9750602089013591508082111561526557600080fd5b5061527289828a0161506e565b955050604087013561528381614f5e565b9350606087013561529381614f5e565b925060808701356152a381614d41565b91506152b28860a0890161513d565b90509295509295509295565b600781106152f5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161530782856152be565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561536857815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615336565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526153e560e0840182615322565b905060a084015160c08401528091505092915050565b6000806000806060858703121561541157600080fd5b843561541c81614d41565b935060208501359250604085013567ffffffffffffffff81111561543f57600080fd5b61544b87828801614be0565b95989497509550505050565b60006020828403121561546957600080fd5b8135614ae081614e9b565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154b557845183529383019391830191600101615499565b50508481036040860152610ee98187615322565b600081518084526020808501945080840160005b8381101561536857815163ffffffff16875295820195908201906001016154dd565b61ffff851681526bffffffffffffffffffffffff841660208201527fffffffff000000000000000000000000000000000000000000000000000000008316604082015260806060820152600061555860808301846154c9565b9695505050505050565b60006020828403121561557457600080fd5b8135614ae081614d41565b6000806020838503121561559257600080fd5b823567ffffffffffffffff8111156155a957600080fd5b6155b585828601614be0565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c9082168061560457607f821691505b60208210810361563d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b82815260406020820152600061565c6040830184614b3d565b949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156131bd576131bd615664565b601f82111561092c57600081815260208120601f850160051c810160208610156156cd5750805b601f850160051c820191505b818110156156ec578281556001016156d9565b505050505050565b815167ffffffffffffffff81111561570e5761570e614c75565b6157228161571c84546155f0565b846156a6565b602080601f831160018114615775576000841561573f5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156ec565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157c2578886015182559484019460019091019084016157a3565b50858210156157fe57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361589357615893615664565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158bf576158bf615664565b5092915050565b6000602082840312156158d857600080fd5b81518015158114614ae057600080fd5b6000602082840312156158fa57600080fd5b5051919050565b600060ff821660ff810361591757615917615664565b60010192915050565b6000610160828403121561593357600080fd5b614ae0838361513d565b81516bffffffffffffffffffffffff1681526101608101602083015161597b602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516159a3604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159bf606084018267ffffffffffffffff169052565b5060808301516159d7608084018263ffffffff169052565b5060a08301516159f760a08401826bffffffffffffffffffffffff169052565b5060c0830151615a1060c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a398285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff8181168382160190808211156158bf576158bf615664565b818103818111156131bd576131bd615664565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161565c60408301846152be565b64ffffffffff8181168382160190808211156158bf576158bf615664565b6bffffffffffffffffffffffff818116838216028082169190828114615a6457615a64615664565b6bffffffffffffffffffffffff8181168382160190808211156158bf576158bf615664565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615ba660408201856152be565b60a060608201526000615bbc60a0830185614b3d565b8281036080840152610ee98185614b3d565b600067ffffffffffffffff808316818103615beb57615beb615664565b6001019392505050565b8051614abe81614f5e565b8051614abe81614ae7565b60008060008060808587031215615c2157600080fd5b8451615c2c81614e9b565b80945050602080860151615c3f81614f5e565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615c7557600080fd5b606087015190935067ffffffffffffffff811115615c9257600080fd5b8601601f81018813615ca357600080fd5b8051615cb1614d8f82614d1d565b81815260059190911b8201830190838101908a831115615cd057600080fd5b928401925b82841015615cf7578351615ce881614ae7565b82529284019290840190615cd5565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615d5560608301846154c9565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615dab610120850183614b3d565b91506060850151615dc8608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615dfa60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614abe81614d41565b8051614abe81614a9d565b8051614abe816150fc565b8051614abe8161511a565b60006101608284031215615e5c57600080fd5b615e64614ca4565b615e6d83615bf5565b8152615e7b60208401615e1d565b6020820152615e8c60408401615e1d565b6040820152615e9d60608401615e28565b6060820152615eae60808401615c00565b6080820152615ebf60a08401615bf5565b60a0820152615ed060c08401615e33565b60c082015260e083015160e0820152610100615eed818501615e3e565b90820152610120615eff848201615e33565b90820152610140615f11848201615e33565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615f5d60c0830186614b3d565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff8316815260406020820152600061565c6040830184614b3d565b838152606060208201526000615fc86060830185614b3d565b82810360408401526155588185614b3d56fea164736f6c6343000813000a", } @@ -640,15 +640,15 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) CreateSubscription() ( return _FunctionsRouter.Contract.CreateSubscription(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { +func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "fulfill", response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } -func (_FunctionsRouter *FunctionsRouterSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { +func (_FunctionsRouter *FunctionsRouterSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } -func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) { +func (_FunctionsRouter *FunctionsRouterTransactorSession) Fulfill(response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.Contract.Fulfill(&_FunctionsRouter.TransactOpts, response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } @@ -832,15 +832,15 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) SetFlags(subscriptionI return _FunctionsRouter.Contract.SetFlags(&_FunctionsRouter.TransactOpts, subscriptionId, flags) } -func (_FunctionsRouter *FunctionsRouterTransactor) TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) { +func (_FunctionsRouter *FunctionsRouterTransactor) TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "timeoutRequests", requestsToTimeoutByCommitment) } -func (_FunctionsRouter *FunctionsRouterSession) TimeoutRequests(requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) { +func (_FunctionsRouter *FunctionsRouterSession) TimeoutRequests(requestsToTimeoutByCommitment []FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestsToTimeoutByCommitment) } -func (_FunctionsRouter *FunctionsRouterTransactorSession) TimeoutRequests(requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) { +func (_FunctionsRouter *FunctionsRouterTransactorSession) TimeoutRequests(requestsToTimeoutByCommitment []FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.Contract.TimeoutRequests(&_FunctionsRouter.TransactOpts, requestsToTimeoutByCommitment) } @@ -4022,7 +4022,7 @@ type FunctionsRouterInterface interface { CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) - Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment IFunctionsRequestCommitment) (*types.Transaction, error) + Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment FunctionsResponseCommitment) (*types.Transaction, error) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) @@ -4054,7 +4054,7 @@ type FunctionsRouterInterface interface { SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) - TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []IFunctionsRequestCommitment) (*types.Transaction, error) + TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []FunctionsResponseCommitment) (*types.Transaction, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 51f2da2f2ab..e34cdc8ec89 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,12 +1,12 @@ GETH_VERSION: 1.12.0 -functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db +functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a6a0fae8fe9c6124f03bf66208fc74eac185be57919e9a3906f4020f0bde2074 functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 -functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin fcfdcd4c0916533f648e5290768a34382465944b2ffe9465add1d5e81175a415 -functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 6841ee6b3150ac5441218396b1fd54cce4ca0af72002489461dc7ba732c393b2 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 9f3279ec5b9d6e724c596b5e315a07d64dea43e26f33eacd38145790d0cb92d6 +functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca +functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 3abd1e91ec88cfc6068473d9532e1aadaa0861591b5fe209f8c32d9140433e40 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin bac5a8c114e65049ecc5c6f9d262bc0325a903d8554fbbe447f48341ffccd58a functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 2047f8424d3038672f347ef5e6b401f0347b42f64defd43033cc75e0ac537287 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 717e0028ba28088b0ae09bbb687a5e2720435cf6f93ee5b1202fb73a460d8a9d ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/gethwrappers/functions/go_generate.go b/core/gethwrappers/functions/go_generate.go index d46b233e98c..c163623c331 100644 --- a/core/gethwrappers/functions/go_generate.go +++ b/core/gethwrappers/functions/go_generate.go @@ -15,7 +15,7 @@ package gethwrappers //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin FunctionsBillingRegistryEventsMock functions_billing_registry_events_mock // Version 1 (Mainnet Preview) -//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/Functions.bin Functions functions +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin Functions functions //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin FunctionsClient functions_client //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin FunctionsClientExample functions_client_example //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin FunctionsCoordinator functions_coordinator From ee7cf37c5b4429ee4355f31c67aa329f2afa0593 Mon Sep 17 00:00:00 2001 From: Lukasz <120112546+lukaszcl@users.noreply.github.com> Date: Thu, 3 Aug 2023 16:41:30 +0200 Subject: [PATCH 070/270] Marshal struct to build node config in e2e tests (#10044) * Marshal struct to build node config Use functional options as decorators to create node config with P2Pv1 or P2Pv2. * Add ocr2 * Use config structures from core * Fix gomod * Fix setting p2p * fix tests --------- Co-authored-by: skudasov --- integration-tests/docker/test_env/cl_node.go | 19 +-- integration-tests/docker/test_env/test_env.go | 18 +-- .../docker/test_env/test_env_builder.go | 37 ++--- integration-tests/go.mod | 25 +++ integration-tests/go.sum | 67 +++++++- integration-tests/types/config/node/core.go | 145 ++++++++++++++++++ integration-tests/types/node/node_config.go | 79 ---------- 7 files changed, 262 insertions(+), 128 deletions(-) create mode 100644 integration-tests/types/config/node/core.go delete mode 100644 integration-tests/types/node/node_config.go diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index a59bb1781ee..74a2bdf7726 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -12,6 +12,7 @@ import ( "time" "github.com/google/uuid" + "github.com/pelletier/go-toml/v2" "github.com/pkg/errors" "math/big" @@ -22,9 +23,9 @@ import ( "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/types/node" "github.com/smartcontractkit/chainlink/integration-tests/utils" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" @@ -34,9 +35,9 @@ import ( type ClNode struct { EnvComponent - API *client.ChainlinkClient - NodeConfigOpts node.NodeConfigOpts - PostgresDb *PostgresDb + API *client.ChainlinkClient + NodeConfig *chainlink.Config + PostgresDb *PostgresDb } type ClNodeOption = func(c *ClNode) @@ -59,7 +60,7 @@ func WithDbContainerName(name string) ClNodeOption { } } -func NewClNode(networks []string, nodeConfOpts node.NodeConfigOpts, opts ...ClNodeOption) *ClNode { +func NewClNode(networks []string, nodeConfig chainlink.Config, opts ...ClNodeOption) *ClNode { nodeDefaultCName := fmt.Sprintf("%s-%s", "cl-node", uuid.NewString()[0:3]) pgDefaultCName := fmt.Sprintf("pg-%s", nodeDefaultCName) pgDb := NewPostgresDb(networks, WithPostgresDbContainerName(pgDefaultCName)) @@ -68,8 +69,8 @@ func NewClNode(networks []string, nodeConfOpts node.NodeConfigOpts, opts ...ClNo ContainerName: nodeDefaultCName, Networks: networks, }, - NodeConfigOpts: nodeConfOpts, - PostgresDb: pgDb, + NodeConfig: &nodeConfig, + PostgresDb: pgDb, } for _, opt := range opts { opt(n) @@ -233,11 +234,11 @@ func (n *ClNode) getContainerRequest(secrets string) ( if err != nil { return nil, err } - config, err := node.ExecuteNodeConfigTemplate(n.NodeConfigOpts) + data, err := toml.Marshal(n.NodeConfig) if err != nil { return nil, err } - _, err = configFile.WriteString(config) + _, err = configFile.WriteString(string(data)) if err != nil { return nil, err } diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index 088bf833bd9..67314298d3a 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -9,7 +9,7 @@ import ( "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/docker" - "github.com/smartcontractkit/chainlink/integration-tests/types/node" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" tc "github.com/testcontainers/testcontainers-go" "go.uber.org/multierr" ) @@ -60,7 +60,7 @@ func (m *CLClusterTestEnv) StartMockServer() error { } // StartClNodes start one bootstrap node and {count} OCR nodes -func (m *CLClusterTestEnv) StartClNodes(nodeConfigOpts node.NodeConfigOpts, count int) error { +func (m *CLClusterTestEnv) StartClNodes(nodeConfig chainlink.Config, count int) error { var wg sync.WaitGroup var errs = []error{} var mu sync.Mutex @@ -76,7 +76,7 @@ func (m *CLClusterTestEnv) StartClNodes(nodeConfigOpts node.NodeConfigOpts, coun nodeContainerName = m.cfg.Nodes[i].NodeContainerName dbContainerName = m.cfg.Nodes[i].DbContainerName } - n := NewClNode([]string{m.Network.Name}, nodeConfigOpts, + n := NewClNode([]string{m.Network.Name}, nodeConfig, WithNodeContainerName(nodeContainerName), WithDbContainerName(dbContainerName)) err := n.StartContainer(m.LogWatch) @@ -100,18 +100,6 @@ func (m *CLClusterTestEnv) StartClNodes(nodeConfigOpts node.NodeConfigOpts, coun return nil } -func (m *CLClusterTestEnv) GetDefaultNodeConfigOpts() node.NodeConfigOpts { - return node.NodeConfigOpts{ - EVM: struct { - HttpUrl string - WsUrl string - }{ - HttpUrl: m.Geth.InternalHttpUrl, - WsUrl: m.Geth.InternalWsUrl, - }, - } -} - // ChainlinkNodeAddresses will return all the on-chain wallet addresses for a set of Chainlink nodes func (m *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { addresses := make([]common.Address, 0) diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index 266a27388ff..1d034e9a07a 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -1,10 +1,11 @@ package test_env import ( + "os" + "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" - "github.com/smartcontractkit/chainlink/integration-tests/types/node" - "os" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" ) type CLTestEnvBuilder struct { @@ -103,16 +104,12 @@ func (m *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTes // Start Chainlink Nodes if m.clNodesCount > 0 { // Create nodes - nodeConfOpts := node.NodeConfigOpts{ - EVM: struct { - HttpUrl string - WsUrl string - }{ - HttpUrl: te.Geth.InternalHttpUrl, - WsUrl: te.Geth.InternalWsUrl, - }, - } - err = te.StartClNodes(nodeConfOpts, m.clNodesCount) + nodeConfig := node.NewConfig(node.BaseConf, + node.WithOCR1(), + node.WithP2Pv1(), + node.WithSimulatedEVM(te.Geth.InternalHttpUrl, te.Geth.InternalWsUrl), + ) + err = te.StartClNodes(nodeConfig, m.clNodesCount) if err != nil { return te, err } @@ -173,16 +170,12 @@ func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { // Start Chainlink Nodes if m.clNodesCount > 0 { // Create nodes - nodeConfOpts := node.NodeConfigOpts{ - EVM: struct { - HttpUrl string - WsUrl string - }{ - HttpUrl: te.Geth.InternalHttpUrl, - WsUrl: te.Geth.InternalWsUrl, - }, - } - err = te.StartClNodes(nodeConfOpts, m.clNodesCount) + nodeConfig := node.NewConfig(node.BaseConf, + node.WithOCR1(), + node.WithP2Pv1(), + node.WithSimulatedEVM(te.Geth.InternalHttpUrl, te.Geth.InternalWsUrl), + ) + err = te.StartClNodes(nodeConfig, m.clNodesCount) if err != nil { return te, err } diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 67cfbbadaed..d0fcf08c04e 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -44,6 +44,9 @@ replace ( require ( contrib.go.opencensus.io/exporter/stackdriver v0.13.5 // indirect + cosmossdk.io/api v0.3.1 // indirect + cosmossdk.io/core v0.5.1 // indirect + cosmossdk.io/depinject v1.0.0-alpha.3 // indirect cosmossdk.io/errors v1.0.0 // indirect cosmossdk.io/math v1.0.1 // indirect filippo.io/edwards25519 v1.0.0 // indirect @@ -51,6 +54,8 @@ require ( github.com/99designs/keyring v1.2.1 // indirect github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 // indirect github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d // indirect + github.com/CosmWasm/wasmd v0.40.1 // indirect + github.com/CosmWasm/wasmvm v1.2.4 // indirect github.com/DataDog/zstd v1.5.2 // indirect github.com/K-Phoen/grabana v0.21.17 // indirect github.com/K-Phoen/sdk v0.12.2 // indirect @@ -62,6 +67,7 @@ require ( github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129 // indirect github.com/armon/go-metrics v0.4.1 // indirect github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 // indirect + github.com/avast/retry-go/v4 v4.3.4 // indirect github.com/aws/aws-sdk-go v1.44.276 // indirect github.com/aws/constructs-go/constructs/v10 v10.1.255 // indirect github.com/aws/jsii-runtime-go v1.75.0 // indirect @@ -72,9 +78,11 @@ require ( github.com/blendle/zapdriver v1.3.1 // indirect github.com/btcsuite/btcd v0.23.4 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.2 // indirect + github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 // indirect github.com/bytedance/sonic v1.9.1 // indirect github.com/c2h5oh/datasize v0.0.0-20200112174442-28bbd4740fee // indirect github.com/cdk8s-team/cdk8s-core-go/cdk8s/v2 v2.7.5 // indirect + github.com/cenkalti/backoff v2.2.1+incompatible // indirect github.com/cenkalti/backoff/v4 v4.2.1 // indirect github.com/cespare/xxhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect @@ -98,6 +106,9 @@ require ( github.com/cosmos/cosmos-sdk v0.47.4 // indirect github.com/cosmos/go-bip39 v1.0.0 // indirect github.com/cosmos/gogoproto v1.4.10 // indirect + github.com/cosmos/iavl v0.20.0 // indirect + github.com/cosmos/ibc-go/v7 v7.0.1 // indirect + github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab // indirect github.com/cosmos/ledger-cosmos-go v0.12.1 // indirect github.com/cpuguy83/dockercfg v0.3.1 // indirect github.com/danieljoos/wincred v1.1.2 // indirect @@ -157,12 +168,15 @@ require ( github.com/go-playground/universal-translator v0.18.1 // indirect github.com/go-playground/validator/v10 v10.14.0 // indirect github.com/go-stack/stack v1.8.1 // indirect + github.com/go-webauthn/revoke v0.1.9 // indirect + github.com/go-webauthn/webauthn v0.8.2 // indirect github.com/goccy/go-json v0.10.2 // indirect github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 // indirect github.com/gofrs/flock v0.8.1 // indirect github.com/gogo/googleapis v1.4.1 // indirect github.com/gogo/protobuf v1.3.3 // indirect github.com/gogo/status v1.1.1 // indirect + github.com/golang-jwt/jwt/v4 v4.5.0 // indirect github.com/golang/glog v1.1.0 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/protobuf v1.5.3 // indirect @@ -171,6 +185,7 @@ require ( github.com/google/gnostic v0.6.9 // indirect github.com/google/go-cmp v0.5.9 // indirect github.com/google/go-querystring v1.1.0 // indirect + github.com/google/go-tpm v0.3.3 // indirect github.com/google/gofuzz v1.2.0 // indirect github.com/google/gopacket v1.1.19 // indirect github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 // indirect @@ -212,6 +227,7 @@ require ( github.com/hdevalence/ed25519consensus v0.1.0 // indirect github.com/holiman/bloomfilter/v2 v2.0.3 // indirect github.com/holiman/uint256 v1.2.2 // indirect + github.com/huandu/skiplist v1.2.0 // indirect github.com/huin/goupnp v1.0.3 // indirect github.com/imdario/mergo v0.3.15 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect @@ -332,6 +348,7 @@ require ( github.com/opentracing-contrib/go-grpc v0.0.0-20210225150812-73cb765af46e // indirect github.com/opentracing-contrib/go-stdlib v1.0.0 // indirect github.com/opentracing/opentracing-go v1.2.0 // indirect + github.com/patrickmn/go-cache v2.1.0+incompatible // indirect github.com/pelletier/go-toml v1.9.5 // indirect github.com/peterbourgon/diskv v2.0.1+incompatible // indirect github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect @@ -347,6 +364,7 @@ require ( github.com/prometheus/prometheus v0.45.0 // indirect github.com/pyroscope-io/client v0.7.1 // indirect github.com/pyroscope-io/godeltaprof v0.1.0 // indirect + github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/rivo/uniseg v0.4.4 // indirect github.com/robfig/cron/v3 v3.0.1 // indirect github.com/rogpeppe/go-internal v1.10.0 // indirect @@ -360,8 +378,13 @@ require ( github.com/shopspring/decimal v1.3.1 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 // indirect + github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect + github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c // indirect + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a // indirect github.com/smartcontractkit/wasp v0.2.7 // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect @@ -379,6 +402,7 @@ require ( github.com/tendermint/go-amino v0.16.0 // indirect github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 // indirect github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a // indirect + github.com/tidwall/btree v1.6.0 // indirect github.com/tidwall/gjson v1.14.4 // indirect github.com/tidwall/match v1.1.1 // indirect github.com/tidwall/pretty v1.2.0 // indirect @@ -438,6 +462,7 @@ require ( google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect google.golang.org/grpc v1.56.2 // indirect google.golang.org/protobuf v1.31.0 // indirect + gopkg.in/guregu/null.v2 v2.1.2 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/ini.v1 v1.67.0 // indirect gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 762c34e5934..3c81d688167 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -270,6 +270,7 @@ cloud.google.com/go/iam v0.7.0/go.mod h1:H5Br8wRaDGNc8XP3keLc4unfUUZeyH3Sfl9XpQE cloud.google.com/go/iam v0.8.0/go.mod h1:lga0/y3iH6CX7sYqypWJ33hf7kkfXJag67naqGESjkE= cloud.google.com/go/iam v0.11.0/go.mod h1:9PiLDanza5D+oWFZiH1uG+RnRCfEGKoyl6yo4cgWZGY= cloud.google.com/go/iam v0.12.0/go.mod h1:knyHGviacl11zrtZUoDuYpDgLjvr28sLQaG0YB2GYAY= +cloud.google.com/go/iam v1.1.0 h1:67gSqaPukx7O8WLLHMa0PNs3EBGd2eE4d+psbO/CO94= cloud.google.com/go/iap v1.4.0/go.mod h1:RGFwRJdihTINIe4wZ2iCP0zF/qu18ZwyKxrhMhygBEc= cloud.google.com/go/iap v1.5.0/go.mod h1:UH/CGgKd4KyohZL5Pt0jSKE4m3FR51qg6FKQ/z/Ix9A= cloud.google.com/go/iap v1.6.0/go.mod h1:NSuvI9C/j7UdjGjIde7t7HBz+QTwBcapPE07+sSRcLk= @@ -458,6 +459,7 @@ cloud.google.com/go/storage v1.22.1/go.mod h1:S8N1cAStu7BOeFfE8KAQzmyyLkK8p/vmRq cloud.google.com/go/storage v1.23.0/go.mod h1:vOEEDNFnciUMhBeT6hsJIn3ieU5cFRmzeLgDvXzfIXc= cloud.google.com/go/storage v1.27.0/go.mod h1:x9DOL8TK/ygDUMieqwfhdpQryTeEkhGKMi80i/iqR2s= cloud.google.com/go/storage v1.28.1/go.mod h1:Qnisd4CqDdo6BGs2AD5LLnEsmSQ80wQ5ogcBBKhU86Y= +cloud.google.com/go/storage v1.30.1 h1:uOdMxAs8HExqBlnLtnQyP0YkvbiDpdGShGKtx6U/oNM= cloud.google.com/go/storagetransfer v1.5.0/go.mod h1:dxNzUopWy7RQevYFHewchb29POFv3/AaBgnhqzqiK0w= cloud.google.com/go/storagetransfer v1.6.0/go.mod h1:y77xm4CQV/ZhFZH75PLEXY0ROiS7Gh6pSKrM8dJyg6I= cloud.google.com/go/storagetransfer v1.7.0/go.mod h1:8Giuj1QNb1kfLAiWM1bN6dHzfdlDAVC9rv9abHot2W4= @@ -518,12 +520,17 @@ contrib.go.opencensus.io/exporter/stackdriver v0.13.4/go.mod h1:aXENhDJ1Y4lIg4EU contrib.go.opencensus.io/exporter/stackdriver v0.13.5 h1:TNaexHK16gPUoc7uzELKOU7JULqccn1NDuqUxmxSqfo= contrib.go.opencensus.io/exporter/stackdriver v0.13.5/go.mod h1:aXENhDJ1Y4lIg4EUaVTwzvYETVNZk10Pu26tevFKLUc= cosmossdk.io/api v0.3.1 h1:NNiOclKRR0AOlO4KIqeaG6PS6kswOMhHD0ir0SscNXE= +cosmossdk.io/api v0.3.1/go.mod h1:DfHfMkiNA2Uhy8fj0JJlOCYOBp4eWUUJ1te5zBGNyIw= cosmossdk.io/core v0.5.1 h1:vQVtFrIYOQJDV3f7rw4pjjVqc1id4+mE0L9hHP66pyI= +cosmossdk.io/core v0.5.1/go.mod h1:KZtwHCLjcFuo0nmDc24Xy6CRNEL9Vl/MeimQ2aC7NLE= cosmossdk.io/depinject v1.0.0-alpha.3 h1:6evFIgj//Y3w09bqOUOzEpFj5tsxBqdc5CfkO7z+zfw= +cosmossdk.io/depinject v1.0.0-alpha.3/go.mod h1:eRbcdQ7MRpIPEM5YUJh8k97nxHpYbc3sMUnEtt8HPWU= cosmossdk.io/errors v1.0.0 h1:nxF07lmlBbB8NKQhtJ+sJm6ef5uV1XkvPXG2bUntb04= cosmossdk.io/errors v1.0.0/go.mod h1:+hJZLuhdDE0pYN8HkOrVNwrIOYvUGnn6+4fjnJs/oV0= +cosmossdk.io/log v1.1.1-0.20230704160919-88f2c830b0ca h1:msenprh2BLLRwNT7zN56TbBHOGk/7ARQckXHxXyvjoQ= cosmossdk.io/math v1.0.1 h1:Qx3ifyOPaMLNH/89WeZFH268yCvU4xEcnPLu3sJqPPg= cosmossdk.io/math v1.0.1/go.mod h1:Ygz4wBHrgc7g0N+8+MrnTfS9LLn9aaTGa9hKopuym5k= +cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= filippo.io/edwards25519 v1.0.0 h1:0wAIcmJUqRdI8IJ/3eGi5/HwXZWPujYXXlkrQogz0Ek= @@ -558,7 +565,9 @@ github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1: github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/CosmWasm/wasmd v0.40.1 h1:LxbO78t/6S8TkeQlUrJ0m5O87HtAwLx4RGHq3rdrOEU= +github.com/CosmWasm/wasmd v0.40.1/go.mod h1:6EOwnv7MpuFaEqxcUOdFV9i4yvrdOciaY6VQ1o7A3yg= github.com/CosmWasm/wasmvm v1.2.4 h1:6OfeZuEcEH/9iqwrg2pkeVtDCkMoj9U6PpKtcrCyVrQ= +github.com/CosmWasm/wasmvm v1.2.4/go.mod h1:vW/E3h8j9xBQs9bCoijDuawKo9kCtxOaS8N8J7KFtkc= github.com/DataDog/datadog-go v3.2.0+incompatible/go.mod h1:LButxg5PwREeZtORoXG3tL4fMGNddJ+vMq1mwgfaqoQ= github.com/DataDog/zstd v1.5.2 h1:vUG4lAyuPCXO0TLbXvPv7EB7cNK1QV/luu55UHLrrn8= github.com/DataDog/zstd v1.5.2/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= @@ -598,6 +607,7 @@ github.com/ajstarks/svgo v0.0.0-20180226025133-644b8db467af/go.mod h1:K08gAheRH3 github.com/ajstarks/svgo v0.0.0-20211024235047-1546f124cd8b/go.mod h1:1KcenG0jGWcpt8ov532z81sp/kMMUG485J2InIOyADM= github.com/akavel/rsrc v0.8.0/go.mod h1:uLoCtb9J+EyAqh+26kdrTgmzRBFPGOolLWKpdxkKq+c= github.com/alecthomas/kingpin/v2 v2.3.1/go.mod h1:oYL5vtsvEHZGHxU7DMp32Dvx+qL+ptGn6lWaot2vCNE= +github.com/alecthomas/participle/v2 v2.0.0-alpha7 h1:cK4vjj0VSgb3lN1nuKA5F7dw+1s1pWBe5bx7nNCnN+c= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= @@ -625,8 +635,8 @@ github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkY github.com/asaskevich/govalidator v0.0.0-20200907205600-7a23bdc65eef/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so= github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= -github.com/avast/retry-go v3.0.0+incompatible h1:4SOWQ7Qs+oroOTQOYnAHqelpCO0biHSxpiH9JdtuBj0= github.com/avast/retry-go/v4 v4.3.4 h1:pHLkL7jvCvP317I8Ge+Km2Yhntv3SdkJm7uekkqbKhM= +github.com/avast/retry-go/v4 v4.3.4/go.mod h1:rv+Nla6Vk3/ilU0H51VHddWHiwimzX66yZ0JT6T+UvE= github.com/aws/aws-sdk-go v1.22.1/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.23.20/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= @@ -647,6 +657,7 @@ github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24 github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= +github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1UJrqV3uuy861HCTo708pDMbjHHdCas= github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= @@ -733,6 +744,8 @@ github.com/cncf/xds/go v0.0.0-20230310173818-32f1caf87195/go.mod h1:eXthEFrGJvWH github.com/cncf/xds/go v0.0.0-20230607035331-e9ce68804cb4 h1:/inchEIKaYC1Akx+H+gqO04wryn5h75LSazbRlnya1k= github.com/cockroachdb/apd v1.1.0 h1:3LFP3629v+1aKXU5Q37mxmRxX/pIu1nijXydLShEq5I= github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= +github.com/cockroachdb/apd/v2 v2.0.2 h1:weh8u7Cneje73dDh+2tEVLUvyBc89iwepWCD8b8034E= +github.com/cockroachdb/apd/v3 v3.1.0 h1:MK3Ow7LH0W8zkd5GMKA1PvS9qG3bWFI95WaVNfyZJ/w= github.com/cockroachdb/datadriven v1.0.2 h1:H9MtNqVoVhvd9nCBwOyDjUEdZCREqbIdCJD93PBm/jA= github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= github.com/cockroachdb/errors v1.9.1 h1:yFVvsI0VxmRShfawbt/laCIDy/mtTqqnvoNgiy5bEV8= @@ -746,6 +759,7 @@ github.com/cockroachdb/redact v1.1.3 h1:AKZds10rFSIj7qADf0g46UixK8NNLwWTNdCIGS5w github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= +github.com/coinbase/rosetta-sdk-go/types v1.0.0 h1:jpVIwLcPoOeCR6o1tU+Xv7r5bMONNbHU7MuEHboiFuA= github.com/cometbft/cometbft v0.37.2 h1:XB0yyHGT0lwmJlFmM4+rsRnczPlHoAKFX6K8Zgc2/Jc= github.com/cometbft/cometbft v0.37.2/go.mod h1:Y2MMMN//O5K4YKd8ze4r9jmk4Y7h0ajqILXbH5JQFVs= github.com/cometbft/cometbft-db v0.7.0 h1:uBjbrBx4QzU0zOEnU8KxoDl18dMNgDh+zZRUE0ucsbo= @@ -781,10 +795,14 @@ github.com/cosmos/gogogateway v1.2.0 h1:Ae/OivNhp8DqBi/sh2A8a1D0y638GpL3tkmLQAiK github.com/cosmos/gogoproto v1.4.10 h1:QH/yT8X+c0F4ZDacDv3z+xE3WU1P1Z3wQoLMBRJoKuI= github.com/cosmos/gogoproto v1.4.10/go.mod h1:3aAZzeRWpAwr+SS/LLkICX2/kDFyaYVzckBDzygIxek= github.com/cosmos/iavl v0.20.0 h1:fTVznVlepH0KK8NyKq8w+U7c2L6jofa27aFX6YGlm38= +github.com/cosmos/iavl v0.20.0/go.mod h1:WO7FyvaZJoH65+HFOsDir7xU9FWk2w9cHXNW1XHcl7A= github.com/cosmos/ibc-go/v7 v7.0.1 h1:NIBNRWjlOoFvFQu1ZlgwkaSeHO5avf4C1YQiWegt8jw= +github.com/cosmos/ibc-go/v7 v7.0.1/go.mod h1:vEaapV6nuLPQlS+g8IKmxMo6auPi0i7HMv1PhViht/E= github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab h1:I9ialKTQo7248V827Bba4OuKPmk+FPzmTVHsLXaIJWw= +github.com/cosmos/ics23/go v0.9.1-0.20221207100636-b1abd8678aab/go.mod h1:2CwqasX5dSD7Hbp/9b6lhK6BwoBDCBldx7gPKRukR60= github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVNihy1Y984w= github.com/cosmos/ledger-cosmos-go v0.12.1/go.mod h1:dhO6kj+Y+AHIOgAe4L9HL/6NDdyyth4q238I9yFpD2g= +github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= github.com/cpuguy83/dockercfg v0.3.1 h1:/FpZ+JaygUR/lZP2NlFI2DVfrOEMAIKP5wWEJdoYe9E= github.com/cpuguy83/dockercfg v0.3.1/go.mod h1:sugsbF4//dDlL/i+S+rtpIWp+5h0BHJHfjj5/jFyUJc= github.com/cpuguy83/go-md2man v1.0.10 h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk= @@ -792,9 +810,12 @@ github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwc github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= +github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= +github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= github.com/daaku/go.zipexe v1.0.0/go.mod h1:z8IiR6TsVLEYKwXAoE/I+8ys/sDkgTzSL0CLnGVd57E= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= @@ -814,6 +835,7 @@ github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3 github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= github.com/dennwc/varint v1.0.0 h1:kGNFFSSw8ToIy3obO/kKr8U9GZYUAxQEVuix4zfDWzE= github.com/dennwc/varint v1.0.0/go.mod h1:hnItb35rvZvJrbTALZtY/iQfDs48JKRG1RPpgziApxA= +github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/dfuse-io/logging v0.0.0-20201110202154-26697de88c79/go.mod h1:V+ED4kT/t/lKtH99JQmKIb0v9WL3VaYkJ36CfHlVECI= github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70 h1:CuJS05R9jmNlUK8GOxrEELPbfXm0EuGh/30LjkjN5vo= github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70/go.mod h1:EoK/8RFbMEteaCaz89uessDTnCWjbbcr+DXcBh4el5o= @@ -918,6 +940,7 @@ github.com/gabriel-vasile/mimetype v1.4.2/go.mod h1:zApsH/mKG4w07erKIaJPFiX0Tsq9 github.com/gagliardetto/binary v0.6.1/go.mod h1:aOfYkc20U0deHaHn/LVZXiqlkDbFAX0FpTlDhsXa0S0= github.com/gagliardetto/binary v0.7.1 h1:6ggDQ26vR+4xEvl/S13NcdLK3MUCi4oSy73pS9aI1cI= github.com/gagliardetto/binary v0.7.1/go.mod h1:aOfYkc20U0deHaHn/LVZXiqlkDbFAX0FpTlDhsXa0S0= +github.com/gagliardetto/gofuzz v1.2.2 h1:XL/8qDMzcgvR4+CyRQW9UGdwPRPMHVJfqQ/uMvSUuQw= github.com/gagliardetto/gofuzz v1.2.2/go.mod h1:bkH/3hYLZrMLbfYWA0pWzXmi5TTRZnu4pMGZBkqMKvY= github.com/gagliardetto/solana-go v1.4.1-0.20220428092759-5250b4abbb27 h1:q2IztKyRQUxJ6abXRsawaBtvDFvM+szj4jDqV4od1gs= github.com/gagliardetto/solana-go v1.4.1-0.20220428092759-5250b4abbb27/go.mod h1:NFuoDwHPvw858ZMHUJr6bkhN8qHt4x6e+U3EYHxAwNY= @@ -1038,7 +1061,9 @@ github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEe github.com/go-test/deep v1.0.4 h1:u2CU3YKy9I2pmu9pX0eq50wCgjfGIt539SqR7FbHiho= github.com/go-test/deep v1.0.4/go.mod h1:wGDj63lr65AM2AQyKZd/NYHGb0R+1RLqB8NKt3aSFNA= github.com/go-webauthn/revoke v0.1.9 h1:gSJ1ckA9VaKA2GN4Ukp+kiGTk1/EXtaDb1YE8RknbS0= +github.com/go-webauthn/revoke v0.1.9/go.mod h1:j6WKPnv0HovtEs++paan9g3ar46gm1NarktkXBaPR+w= github.com/go-webauthn/webauthn v0.8.2 h1:8KLIbpldjz9KVGHfqEgJNbkhd7bbRXhNw4QWFJE15oA= +github.com/go-webauthn/webauthn v0.8.2/go.mod h1:d+ezx/jMCNDiqSMzOchuynKb9CVU1NM9BumOnokfcVQ= github.com/go-zookeeper/zk v1.0.3 h1:7M2kwOsc//9VeeFiPtf+uSJlVpU66x9Ba5+8XK7/TDg= github.com/gobuffalo/attrs v0.0.0-20190224210810-a9411de4debd/go.mod h1:4duuawTqi2wkkpB4ePgWMaai6/Kc6WEz83bhFwpHzj0= github.com/gobuffalo/depgen v0.0.0-20190329151759-d478694a28d3/go.mod h1:3STtPUQYuzV0gBVOY3vy6CfMm/ljR4pABfrTeHNLHUY= @@ -1088,9 +1113,9 @@ github.com/gogo/status v1.0.3/go.mod h1:SavQ51ycCLnc7dGyJxp8YAmudx8xqiVrRf+6IXRs github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= github.com/gogo/status v1.1.1 h1:DuHXlSFHNKqTQ+/ACf5Vs6r4X/dH2EgIzR9Vr+H65kg= github.com/gogo/status v1.1.1/go.mod h1:jpG3dM5QPcqu19Hg8lkUhBFBa3TcLs1DG7+2Jqci7oU= -github.com/golang-jwt/jwt v3.2.2+incompatible h1:IfV12K8xAKAnZqdXVzCZ+TOjboZ2keLg81eXfW3O+oY= github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= +github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/freetype v0.0.0-20170609003504-e2365dfdc4a0/go.mod h1:E/TSTwGwJL78qG/PmXZO1EjYhfJinVAhrmmHX6Z8B9k= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.0.0/go.mod h1:EWib/APOK0SL3dFbYqvxE3UYd8E6s1ouQ7iEp/0LWV4= @@ -1165,7 +1190,12 @@ github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeN github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/go-querystring v1.1.0 h1:AnCroh3fv4ZBgVIf1Iwtovgjaw/GiKJo8M8yD/fhyJ8= github.com/google/go-querystring v1.1.0/go.mod h1:Kcdr2DB4koayq7X8pmAG4sNG59So17icRSOU623lUBU= +github.com/google/go-tpm v0.1.2-0.20190725015402-ae6dd98980d4/go.mod h1:H9HbmUG2YgV/PHITkO7p6wxEEj/v5nlsVWIwumwH2NI= +github.com/google/go-tpm v0.3.0/go.mod h1:iVLWvrPp/bHeEkxTFi9WG6K9w0iy2yIszHwZGHPbzAw= github.com/google/go-tpm v0.3.3 h1:P/ZFNBZYXRxc+z7i5uyd8VP7MaDteuLZInzrH2idRGo= +github.com/google/go-tpm v0.3.3/go.mod h1:9Hyn3rgnzWF9XBWVk6ml6A6hNkbWjNFlDQL51BeghL4= +github.com/google/go-tpm-tools v0.0.0-20190906225433-1614c142f845/go.mod h1:AVfHadzbdzHo54inR2x1v640jdi1YSi3NauM2DUsxk0= +github.com/google/go-tpm-tools v0.2.0/go.mod h1:npUd03rQ60lxN7tzeBJreG38RvWwme2N1reF/eeiBk4= github.com/google/gofuzz v0.0.0-20170612174753-24818f796faf/go.mod h1:HP5RmnzzSNb993RKQDq4+1A4ia9nllfqcQFTQJedwGI= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= @@ -1179,6 +1209,7 @@ github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIG github.com/google/martian/v3 v3.1.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= github.com/google/martian/v3 v3.2.1/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= github.com/google/martian/v3 v3.3.2/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= +github.com/google/orderedcode v0.0.1 h1:UzfcAexk9Vhv8+9pNOgRu41f16lHq725vPwnSeiG/Us= github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= @@ -1198,6 +1229,7 @@ github.com/google/pprof v0.0.0-20210720184732-4bb14d4b1be1/go.mod h1:kpwsk12EmLe github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 h1:hR7/MlvK23p6+lIw9SN1TigNLn9ZnF3W4SYRKq2gAHs= github.com/google/pprof v0.0.0-20230602150820-91b7bce49751/go.mod h1:Jh3hGz2jkYak8qXPD19ryItVnUgpgeqzdkY/D0EaeuA= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= +github.com/google/s2a-go v0.1.4 h1:1kZ/sQM3srePvKs3tXAvQzo66XfcReoqFpIpIccE7Oc= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510 h1:El6M4kTTCOh6aBiKaUGG7oYTSPP8MxqL4YI3kZKwcP4= github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -1209,6 +1241,7 @@ github.com/googleapis/enterprise-certificate-proxy v0.0.0-20220520183353-fd19c99 github.com/googleapis/enterprise-certificate-proxy v0.1.0/go.mod h1:17drOmN3MwGY7t0e+Ei9b45FFGA3fBs3x36SsCg1hq8= github.com/googleapis/enterprise-certificate-proxy v0.2.0/go.mod h1:8C0jb7/mgJe/9KK8Lm7X9ctZC2t60YyIpYEI16jx0Qg= github.com/googleapis/enterprise-certificate-proxy v0.2.1/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= +github.com/googleapis/enterprise-certificate-proxy v0.2.3 h1:yk9/cqRKtT9wXZSsRH9aurXEpJX+U6FLtpYTdC3R06k= github.com/googleapis/enterprise-certificate-proxy v0.2.3/go.mod h1:AwSRAtLfXpU5Nm3pW+v7rGDHp09LsPtGY9MduiEsR9k= github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= @@ -1220,6 +1253,7 @@ github.com/googleapis/gax-go/v2 v2.4.0/go.mod h1:XOTVJ59hdnfJLIP/dh8n5CGryZR2LxK github.com/googleapis/gax-go/v2 v2.5.1/go.mod h1:h6B0KMMFNtI2ddbGJn3T3ZbwkeT6yqEF02fYlzkUCyo= github.com/googleapis/gax-go/v2 v2.6.0/go.mod h1:1mjbznJAPHFpesgE5ucqfYEscaz5kMdcIDwU/6+DDoY= github.com/googleapis/gax-go/v2 v2.7.0/go.mod h1:TEop28CZZQ2y+c0VxMUmu1lV+fQx57QpBWsYpwqHJx8= +github.com/googleapis/gax-go/v2 v2.11.0 h1:9V9PWXEsWnPpQhu/PeQIkS4eGzMlTLGgt80cUUI8Ki4= github.com/googleapis/go-type-adapters v1.0.0/go.mod h1:zHW75FOG2aur7gAO2B+MLby+cLsWGBF62rFAi7WjWO4= github.com/googleapis/google-cloud-go-testing v0.0.0-20200911160855-bcd43fbb19e8/go.mod h1:dvDLG8qkwmyD9a/MJJN3XJcT3xFxOKAvTZGvuZmac9g= github.com/gophercloud/gophercloud v1.2.0 h1:1oXyj4g54KBg/kFtCdMM6jtxSzeIyg8wv4z1HoGPp1E= @@ -1235,6 +1269,7 @@ github.com/gorilla/securecookie v1.1.1 h1:miw7JPhV+b/lAHSXz4qd/nN9jRiAFV5FwjeKyC github.com/gorilla/securecookie v1.1.1/go.mod h1:ra0sb63/xPlUeL+yeDciTfxMRAA+MP+HVt/4epWDjd4= github.com/gorilla/sessions v1.2.1 h1:DHd3rPN5lE3Ts3D8rKkQ8x/0kqfeNmBAaiSi+o7FsgI= github.com/gorilla/sessions v1.2.1/go.mod h1:dk2InVEVJ0sfLlnXv9EAgkf6ecYs/i80K/zI+bUmuGM= +github.com/gorilla/websocket v1.4.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= @@ -1293,6 +1328,7 @@ github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtng github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-cleanhttp v0.5.2 h1:035FKYIWjmULyFRBKPs8TBQoi0x6d9G4xc9neXJWAZQ= github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48= +github.com/hashicorp/go-getter v1.7.1 h1:SWiSWN/42qdpR0MdhaOc/bLR48PLuP1ZQtYLRlM69uY= github.com/hashicorp/go-hclog v1.5.0 h1:bI2ocEMgcVlz55Oj1xZNBsVi900c7II+fWDyV9o+13c= github.com/hashicorp/go-hclog v1.5.0/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= @@ -1310,6 +1346,7 @@ github.com/hashicorp/go-retryablehttp v0.7.2 h1:AcYqCvkpalPnPF2pn0KamgwamS42TqUD github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= github.com/hashicorp/go-rootcerts v1.0.2 h1:jzhAVGtqPKbwpyCPELlgNWhE1znq+qwJtW5Oi2viEzc= github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8= +github.com/hashicorp/go-safetemp v1.0.0 h1:2HR189eFNrjHQyENnQMMpCiBAsRxzbTMIgBhEyExpmo= github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= github.com/hashicorp/go-sockaddr v1.0.2 h1:ztczhD1jLxIRjVejw8gFomI1BQZOe2WoVOu0SyteCQc= github.com/hashicorp/go-sockaddr v1.0.2/go.mod h1:rB4wwRAUzs07qva3c5SdrY/NEtAUjGlgmH/UkBUC97A= @@ -1349,7 +1386,10 @@ github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iU github.com/holiman/uint256 v1.2.2 h1:TXKcSGc2WaxPD2+bmzAsVthL4+pEN0YwXcL5qED83vk= github.com/holiman/uint256 v1.2.2/go.mod h1:SC8Ryt4n+UBbPbIBKaG9zbbDlp4jOru9xFZmPzLUTxw= github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= +github.com/huandu/go-assert v1.1.5 h1:fjemmA7sSfYHJD7CUqs9qTwwfdNAx7/j2/ZlHXzNB3c= +github.com/huandu/go-assert v1.1.5/go.mod h1:yOLvuqZwmcHIC5rIzrBhT7D3Q9c3GFnd0JrPVhn/06U= github.com/huandu/skiplist v1.2.0 h1:gox56QD77HzSC0w+Ws3MH3iie755GBJU1OER3h5VsYw= +github.com/huandu/skiplist v1.2.0/go.mod h1:7v3iFjLcSAzO4fN5B8dvebvo/qsfumiLiDXMrPiHF9w= github.com/huin/goupnp v1.0.0/go.mod h1:n9v9KO1tAxYH82qOn+UTIFQDmx5n1Zxd/ClZDMX7Bnc= github.com/huin/goupnp v1.0.3 h1:N8No57ls+MnjlB+JPiCVSOyy/ot7MJTqlo7rn+NYSqQ= github.com/huin/goupnp v1.0.3/go.mod h1:ZxNlw5WqJj6wSsRK5+YfflQGXYfccj5VgQsMNixHM7Y= @@ -1361,6 +1401,7 @@ github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1: github.com/imdario/mergo v0.3.15 h1:M8XP7IuFNsqUx6VPK2P9OSmsYsI/YFaGil0uD21V3dM= github.com/imdario/mergo v0.3.15/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= +github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.0.1/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= @@ -1856,6 +1897,7 @@ github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8/go.mod h1:mC1jAcs github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1 h1:lYpkrQH5ajf0OXOcUbGjvZxxijuBwbbmlSxLiuofa+g= github.com/minio/blake2b-simd v0.0.0-20160723061019-3f5f724cb5b1/go.mod h1:pD8RvIylQ358TN4wwqatJ8rNavkEINozVn9DtGI3dfQ= github.com/minio/c2goasm v0.0.0-20190812172519-36a3d3bbc4f3/go.mod h1:RagcQ7I8IeTMnF8JTXieKnO4Z6JCsikNEzj0DwauVzE= +github.com/minio/highwayhash v1.0.2 h1:Aak5U0nElisjDCfPSG79Tgzkn2gl66NxOMspRrKnA/g= github.com/minio/sha256-simd v0.0.0-20190131020904-2d45a736cd16/go.mod h1:2FMWW+8GMoPweT6+pI63m9YE3Lmw4J71hV56Chs1E/U= github.com/minio/sha256-simd v0.0.0-20190328051042-05b4dd3047e5/go.mod h1:2FMWW+8GMoPweT6+pI63m9YE3Lmw4J71hV56Chs1E/U= github.com/minio/sha256-simd v0.1.0/go.mod h1:2FMWW+8GMoPweT6+pI63m9YE3Lmw4J71hV56Chs1E/U= @@ -2033,6 +2075,7 @@ github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FI github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/patrickmn/go-cache v2.1.0+incompatible h1:HRMgzkcYKYpi3C8ajMPV8OFXaaRUnok+kx1WdO15EQc= +github.com/patrickmn/go-cache v2.1.0+incompatible/go.mod h1:3Qf8kWWT7OJRJbdiICTKqZju1ZixQ/KpMGzzAfe6+WQ= github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/pelletier/go-toml v1.7.0/go.mod h1:vwGMzjaWMwyfHwgIBhI2YUM4fB6nL6lVAvS1LBMMhTE= github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= @@ -2121,7 +2164,10 @@ github.com/pyroscope-io/client v0.7.1 h1:yFRhj3vbgjBxehvxQmedmUWJQ4CAfCHhn+itPsu github.com/pyroscope-io/client v0.7.1/go.mod h1:4h21iOU4pUOq0prKyDlvYRL+SCKsBc5wKiEtV+rJGqU= github.com/pyroscope-io/godeltaprof v0.1.0 h1:UBqtjt0yZi4jTxqZmLAs34XG6ycS3vUTlhEUSq4NHLE= github.com/pyroscope-io/godeltaprof v0.1.0/go.mod h1:psMITXp90+8pFenXkKIpNhrfmI9saQnPbba27VIaiQE= +github.com/rakyll/statik v0.1.7 h1:OF3QCZUuyPxuGEP7B4ypUa7sB/iHtqOTDYZXGM8KOdQ= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= +github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= +github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGnWA97M= github.com/regen-network/protobuf v1.3.3-alpha.regen.1 h1:OHEc+q5iIAXpqiqFKeLpu5NwTIkVXUs48vFMwzqpqY4= github.com/regen-network/protobuf v1.3.3-alpha.regen.1/go.mod h1:2DjTFR1HhMQhiWC5sZ4OhQ3+NtdbZ6oBDKQwq5Ou+FI= github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= @@ -2140,7 +2186,7 @@ github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4 github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= -github.com/rs/cors v1.8.2 h1:KCooALfAYGs415Cwu5ABvv9n9509fSiG5SQJn/AQo4U= +github.com/rs/cors v1.8.3 h1:O+qNyWn7Z+F9M0ILBHgMVPuB1xTOucVd5gtaYyXBpRo= github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.13.0/go.mod h1:YbFCdg8HfsridGWAh22vktObvhZbQsZXe4/zB0OKkWU= @@ -2191,12 +2237,15 @@ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= +github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= +github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87gFQ27MAv4Iat7aoCnM3K87/d0r4Aho= github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= @@ -2208,7 +2257,9 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a h1:/ZJnNxcdJ75yDJHnKMjd3G9oZ6lcQRvFUdmiR2DPAgQ= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wasp v0.2.7 h1:9SZ1grPvoNDpxCcQgQi917ifXrjt5JhV/J978HkD0d4= github.com/smartcontractkit/wasp v0.2.7/go.mod h1:gS2oenc6VEGfewgeqDpVFOSrCZIZX10rVl1PAo+vsxc= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= @@ -2234,6 +2285,7 @@ github.com/spf13/cast v1.5.1 h1:R+kOtfhWQE6TVQzY+4D7wJLBgkdVasCEFxSUBYBYIlA= github.com/spf13/cast v1.5.1/go.mod h1:b9PdjNptOpzXr7Rq1q9gJML/2cdGQAo69NKzQ10KN48= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= +github.com/spf13/cobra v1.0.0/go.mod h1:/6GTrnGXV9HjY+aR4k0oJ5tcvakLuG6EuKReYlHNrgE= github.com/spf13/cobra v1.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI= github.com/spf13/cobra v1.6.1 h1:o94oiPyS4KD1mPy2fmcYYHHfCxLqYjJOhGsCHFZtEzA= github.com/spf13/cobra v1.6.1/go.mod h1:IOw/AERYS7UzyrGinqmz6HLUo219MORXGxhbaJUqzrY= @@ -2244,6 +2296,7 @@ github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= +github.com/spf13/viper v1.4.0/go.mod h1:PTJ7Z/lr49W6bUbkmS1V3by4uWynFiR9p7+dSq/yZzE= github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/spf13/viper v1.15.0 h1:js3yy885G8xwJa6iOISGFwd+qlUo5AvyXb7CiihdtiU= @@ -2292,6 +2345,7 @@ github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a h1:YuO+afVc3eqrj github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a/go.mod h1:/sfW47zCZp9FrtGcWyo1VjbgDaodxX9ovZvgLb/MxaA= github.com/thlib/go-timezone-local v0.0.0-20210907160436-ef149e42d28e h1:BuzhfgfWQbX0dWzYzT1zsORLnHRv3bcRcsaUk0VmXA8= github.com/tidwall/btree v1.6.0 h1:LDZfKfQIBHGHWSwckhXI0RPSXzlo+KYdjK7FWSqOzzg= +github.com/tidwall/btree v1.6.0/go.mod h1:twD9XRA5jj9VUQGELzDO4HPQTNJsoWWfYEL+EUQ2cKY= github.com/tidwall/gjson v1.9.3/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= github.com/tidwall/gjson v1.14.4 h1:uo0p8EbA09J7RQaflQ1aBRffTR7xedD2bcIVSYxLnkM= github.com/tidwall/gjson v1.14.4/go.mod h1:/wbyibRr2FHMks5tjHJ5F8dMZh3AcwJEMf5vlfC0lxk= @@ -2323,6 +2377,7 @@ github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljT github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/ugorji/go/codec v1.2.11 h1:BMaWp1Bb6fHwEtbplGBGJ498wD+LKlNSl25MjdZY4dU= github.com/ugorji/go/codec v1.2.11/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= +github.com/ulikunitz/xz v0.5.11 h1:kpFauv27b6ynzBNT/Xy+1k+fK4WswhN/6PN5WhFAGw8= github.com/ulule/limiter/v3 v3.11.2 h1:P4yOrxoEMJbOTfRJR2OzjL90oflzYPPmWg+dvwN2tHA= github.com/umbracle/ethgo v0.1.3 h1:s8D7Rmphnt71zuqrgsGTMS5gTNbueGO1zKLh7qsFzTM= github.com/umbracle/ethgo v0.1.3/go.mod h1:g9zclCLixH8liBI27Py82klDkW7Oo33AxUOr+M9lzrU= @@ -2598,6 +2653,7 @@ golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190522155817-f3200d17e092/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= golang.org/x/net v0.0.0-20190613194153-d28f0bde5980/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= @@ -2801,6 +2857,7 @@ golang.org/x/sys v0.0.0-20210603081109-ebe580a85c40/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210603125802-9665404d3644/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210629170331-7dc0b73dc9fb/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210816183151-1e6c022a8912/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -2975,6 +3032,7 @@ golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20220411194840-2f41105eb62f/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20220517211312-f3a8303e98df/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= golang.org/x/xerrors v0.0.0-20220609144429-65e65417b02f/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= +golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2 h1:H2TDz8ibqkAF6YGhCdN3jS9O0/s90v0rJh3X/OLHEUk= golang.org/x/xerrors v0.0.0-20220907171357-04be3eba64a2/go.mod h1:K8+ghG5WaK9qNqU5K3HdILfMLy1f3aNYFI/wnl100a8= gomodules.xyz/jsonpatch/v2 v2.2.0 h1:4pT439QV83L+G9FkcCriY6EkpcK6r6bK+A5FBUMI7qY= gomodules.xyz/jsonpatch/v2 v2.2.0/go.mod h1:WXp+iVDkoLQqPudfQ9GBlwB2eZ5DKOnjQZCYdOS8GPY= @@ -3044,6 +3102,7 @@ google.golang.org/api v0.106.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/ google.golang.org/api v0.107.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/O9MY= google.golang.org/api v0.108.0/go.mod h1:2Ts0XTHNVWxypznxWOYUeI4g3WdP9Pk2Qk58+a/O9MY= google.golang.org/api v0.110.0/go.mod h1:7FC4Vvx1Mooxh8C5HWjzZHcavuS2f6pmJpZx60ca7iI= +google.golang.org/api v0.126.0 h1:q4GJq+cAdMAC7XP7njvQ4tvohGLiSlytuL4BQxbIZ+o= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= @@ -3194,6 +3253,7 @@ google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98/go. google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= +google.golang.org/grpc v1.21.0/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.22.1/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= @@ -3270,6 +3330,7 @@ gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMy gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= gopkg.in/guregu/null.v2 v2.1.2 h1:YOuepWdYqGnrenzPyMi+ybCjeDzjdazynbwsXXOk4i8= +gopkg.in/guregu/null.v2 v2.1.2/go.mod h1:XORrx8tyS5ZDcyUboCIxQtta/Aujk/6pfWrn9Xe33mU= gopkg.in/guregu/null.v4 v4.0.0 h1:1Wm3S1WEA2I26Kq+6vcW+w0gcDo44YKYD7YIEJNHDjg= gopkg.in/guregu/null.v4 v4.0.0/go.mod h1:YoQhUrADuG3i9WqesrCmpNRwm1ypAgSHYqoOcTu/JrI= gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go new file mode 100644 index 00000000000..ad10fcd8ddf --- /dev/null +++ b/integration-tests/types/config/node/core.go @@ -0,0 +1,145 @@ +package node + +import ( + "math/big" + "net" + "time" + + "github.com/smartcontractkit/chainlink/v2/core/assets" + evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" + "github.com/smartcontractkit/chainlink/v2/core/config/toml" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "github.com/smartcontractkit/chainlink/v2/core/utils" + "go.uber.org/zap/zapcore" +) + +var BaseConf = chainlink.Config{ + Core: toml.Core{ + RootDir: ptr("/home/chainlink"), + Database: toml.Database{ + MaxIdleConns: ptr(int64(20)), + MaxOpenConns: ptr(int64(40)), + MigrateOnStartup: ptr(true), + }, + Log: toml.Log{ + Level: ptr(toml.LogLevel(zapcore.DebugLevel)), + JSONConsole: ptr(true), + }, + WebServer: toml.WebServer{ + AllowOrigins: ptr("*"), + HTTPPort: ptr[uint16](6688), + SecureCookies: ptr(false), + SessionTimeout: models.MustNewDuration(time.Hour * 999), + TLS: toml.WebServerTLS{ + HTTPSPort: ptr[uint16](0), + }, + RateLimit: toml.WebServerRateLimit{ + Authenticated: ptr(int64(2000)), + Unauthenticated: ptr(int64(100)), + }, + }, + Feature: toml.Feature{ + LogPoller: ptr(true), + FeedsManager: ptr(true), + UICSAKeys: ptr(true), + }, + P2P: toml.P2P{}, + }, +} + +type NodeConfigOpt = func(c *chainlink.Config) + +func NewConfig(baseConf chainlink.Config, opts ...NodeConfigOpt) chainlink.Config { + for _, opt := range opts { + opt(&baseConf) + } + return baseConf +} + +func WithOCR1() NodeConfigOpt { + return func(c *chainlink.Config) { + c.OCR = toml.OCR{ + Enabled: ptr(true), + } + } +} + +func WithOCR2() NodeConfigOpt { + return func(c *chainlink.Config) { + c.OCR2 = toml.OCR2{ + Enabled: ptr(true), + } + } +} + +func WithP2Pv1() NodeConfigOpt { + return func(c *chainlink.Config) { + c.P2P.V1 = toml.P2PV1{ + Enabled: ptr(true), + ListenIP: mustIP("0.0.0.0"), + ListenPort: ptr[uint16](6690), + } + } +} + +func WithP2Pv2() NodeConfigOpt { + return func(c *chainlink.Config) { + c.P2P.V2 = toml.P2PV2{ + Enabled: ptr(true), + ListenAddresses: &[]string{"0.0.0.0:6690"}, + } + } +} + +func WithSimulatedEVM(httpUrl, wsUrl string) NodeConfigOpt { + return func(c *chainlink.Config) { + c.EVM = evmcfg.EVMConfigs{ + { + ChainID: utils.NewBig(big.NewInt(1337)), + Chain: evmcfg.Chain{ + AutoCreateKey: ptr(true), + FinalityDepth: ptr[uint32](1), + MinContractPayment: assets.NewLinkFromJuels(0), + }, + Nodes: []*evmcfg.Node{ + { + Name: ptr("1337_primary_local_0"), + WSURL: mustURL(wsUrl), + HTTPURL: mustURL(httpUrl), + SendOnly: ptr(false), + }, + }, + }, + } + } +} + +func WithVRFv2EVMEstimator() NodeConfigOpt { + return func(c *chainlink.Config) { + c.EVM[0].Chain.GasEstimator = evmcfg.GasEstimator{ + LimitDefault: ptr[uint32](3500000), + } + c.EVM[0].Chain.Transactions = evmcfg.Transactions{ + MaxQueued: ptr[uint32](10000), + } + } +} + +func ptr[T any](t T) *T { return &t } + +func mustURL(s string) *models.URL { + var u models.URL + if err := u.UnmarshalText([]byte(s)); err != nil { + panic(err) + } + return &u +} + +func mustIP(s string) *net.IP { + var ip net.IP + if err := ip.UnmarshalText([]byte(s)); err != nil { + panic(err) + } + return &ip +} diff --git a/integration-tests/types/node/node_config.go b/integration-tests/types/node/node_config.go deleted file mode 100644 index 5cd3491598d..00000000000 --- a/integration-tests/types/node/node_config.go +++ /dev/null @@ -1,79 +0,0 @@ -package node - -import ( - "bytes" - "fmt" - "os" - "text/template" -) - -var NodeConfigTemplate = `RootDir = '/home/chainlink' - -[Database] -MaxIdleConns = 20 -MaxOpenConns = 40 -MigrateOnStartup = true - -[Log] -Level = 'debug' -JSONConsole = true - -[WebServer] -AllowOrigins = '*' -HTTPPort = 6688 -SecureCookies = false -SessionTimeout = '999h0m0s' - -[WebServer.TLS] -HTTPSPort = 0 - -[WebServer.RateLimit] -Authenticated = 2000 -Unauthenticated = 100 - -[[EVM]] -ChainID = "1337" -AutoCreateKey = true -finalityDepth = 1 -MinContractPayment = '0' - -[[EVM.Nodes]] -WSURL = "{{ .EVM.WsUrl }}" -HTTPURL = "{{ .EVM.HttpUrl }}" -Name = "1337_primary_local_0" -SendOnly = false - -[Feature] -LogPoller = true -FeedsManager = true -UICSAKeys = true - -[OCR] -Enabled = true - -[P2P] -[P2P.V1] -Enabled = true -ListenIP = '0.0.0.0' -ListenPort = 6690 -` - -type NodeConfigOpts struct { - EVM struct { - HttpUrl string - WsUrl string - } -} - -func ExecuteNodeConfigTemplate(opts NodeConfigOpts) (string, error) { - t, err := template.New("node-config").Parse(NodeConfigTemplate) - if err != nil { - fmt.Println("Error parsing template:", err) - os.Exit(1) - } - - var buf bytes.Buffer - err = t.Execute(&buf, opts) - - return buf.String(), err -} From ab9edbd8e6653c4716adb9629026e48d43bec95c Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Thu, 3 Aug 2023 18:44:10 +0300 Subject: [PATCH 071/270] skip flaky tests (#10002) --- .../plugins/ocr2keeper/evm21/logprovider/integration_test.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index 0ed221ad518..d9293682d91 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -119,6 +119,8 @@ func TestIntegration_LogEventProvider(t *testing.T) { } func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { + t.Skip() + ctx, cancel := context.WithCancel(testutils.Context(t)) defer cancel() @@ -184,6 +186,8 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { } func TestIntegration_LogEventProvider_Backfill(t *testing.T) { + t.Skip() + ctx, cancel := context.WithCancel(testutils.Context(t)) defer cancel() From 83a66fb73166f7e6e64a1153a05be91c1f453bb7 Mon Sep 17 00:00:00 2001 From: ferglor <19188060+ferglor@users.noreply.github.com> Date: Fri, 4 Aug 2023 00:00:42 +0100 Subject: [PATCH 072/270] Add an onchain keyring v3 wrapper (#10061) --- .../ocr2/plugins/ocr2keeper/evm21/keyring.go | 49 ++++++++ .../plugins/ocr2keeper/evm21/keyring_test.go | 108 ++++++++++++++++++ 2 files changed, 157 insertions(+) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/keyring.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/keyring_test.go diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/keyring.go b/core/services/ocr2/plugins/ocr2keeper/evm21/keyring.go new file mode 100644 index 00000000000..df4e3a86502 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/keyring.go @@ -0,0 +1,49 @@ +package evm + +import ( + "github.com/smartcontractkit/libocr/offchainreporting2/types" + "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" +) + +var _ ocr3types.OnchainKeyring[plugin.AutomationReportInfo] = &onchainKeyringV3Wrapper{} + +type onchainKeyringV3Wrapper struct { + core types.OnchainKeyring +} + +func NewOnchainKeyringV3Wrapper(keyring types.OnchainKeyring) *onchainKeyringV3Wrapper { + return &onchainKeyringV3Wrapper{ + core: keyring, + } +} + +func (w *onchainKeyringV3Wrapper) PublicKey() types.OnchainPublicKey { + return w.core.PublicKey() +} + +func (w *onchainKeyringV3Wrapper) MaxSignatureLength() int { + return w.core.MaxSignatureLength() +} + +func (w *onchainKeyringV3Wrapper) Sign(digest types.ConfigDigest, seqNr uint64, r ocr3types.ReportWithInfo[plugin.AutomationReportInfo]) (signature []byte, err error) { + rCtx := types.ReportContext{ + ReportTimestamp: types.ReportTimestamp{ + ConfigDigest: digest, + Epoch: uint32(seqNr), + }, + } + + return w.core.Sign(rCtx, r.Report) +} + +func (w *onchainKeyringV3Wrapper) Verify(key types.OnchainPublicKey, digest types.ConfigDigest, seqNr uint64, r ocr3types.ReportWithInfo[plugin.AutomationReportInfo], signature []byte) bool { + rCtx := types.ReportContext{ + ReportTimestamp: types.ReportTimestamp{ + ConfigDigest: digest, + Epoch: uint32(seqNr), + }, + } + + return w.core.Verify(key, rCtx, r.Report, signature) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/keyring_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/keyring_test.go new file mode 100644 index 00000000000..14c42a810c1 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/keyring_test.go @@ -0,0 +1,108 @@ +package evm + +import ( + "testing" + + "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" + "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" + "github.com/stretchr/testify/assert" +) + +func TestNewOnchainKeyringV3Wrapper(t *testing.T) { + t.Run("the on chain keyring wrapper gets the public key and max signature length from the wrapped keyring", func(t *testing.T) { + onchainKeyring := &mockOnchainKeyring{ + MaxSignatureLengthFn: func() int { + return 123 + }, + PublicKeyFn: func() types.OnchainPublicKey { + return types.OnchainPublicKey([]byte("abcdef")) + }, + } + keyring := NewOnchainKeyringV3Wrapper(onchainKeyring) + assert.Equal(t, 123, keyring.MaxSignatureLength()) + assert.Equal(t, types.OnchainPublicKey([]byte("abcdef")), keyring.PublicKey()) + }) + + t.Run("a report context is created and the wrapped keyring signs the report", func(t *testing.T) { + onchainKeyring := &mockOnchainKeyring{ + SignFn: func(context types.ReportContext, report types.Report) (signature []byte, err error) { + assert.Equal(t, types.ReportContext{ + ReportTimestamp: types.ReportTimestamp{ + ConfigDigest: types.ConfigDigest([32]byte{1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4}), + Epoch: 101, + Round: 0, + }, + ExtraHash: [32]byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + }, context) + assert.Equal(t, types.Report([]byte("a report to sign")), report) + return []byte("signature"), err + }, + } + keyring := NewOnchainKeyringV3Wrapper(onchainKeyring) + signed, err := keyring.Sign( + types.ConfigDigest([32]byte{1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4}), + 101, + ocr3types.ReportWithInfo[plugin.AutomationReportInfo]{ + Report: []byte("a report to sign"), + Info: plugin.AutomationReportInfo{}, + }, + ) + assert.NoError(t, err) + assert.Equal(t, []byte("signature"), signed) + }) + + t.Run("a report context is created and the wrapped keyring verifies the report", func(t *testing.T) { + onchainKeyring := &mockOnchainKeyring{ + VerifyFn: func(pk types.OnchainPublicKey, rc types.ReportContext, r types.Report, signature []byte) bool { + assert.Equal(t, types.OnchainPublicKey([]byte("key")), pk) + assert.Equal(t, types.ReportContext{ + ReportTimestamp: types.ReportTimestamp{ + ConfigDigest: types.ConfigDigest([32]byte{1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4}), + Epoch: 999, + Round: 0, + }, + ExtraHash: [32]byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + }, rc) + assert.Equal(t, types.Report([]byte("a report to sign")), r) + assert.Equal(t, []byte("signature"), signature) + return true + }, + } + keyring := NewOnchainKeyringV3Wrapper(onchainKeyring) + valid := keyring.Verify( + types.OnchainPublicKey([]byte("key")), + types.ConfigDigest([32]byte{1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4, 1, 2, 3, 4}), + 999, + ocr3types.ReportWithInfo[plugin.AutomationReportInfo]{ + Report: []byte("a report to sign"), + Info: plugin.AutomationReportInfo{}, + }, + []byte("signature"), + ) + assert.True(t, valid) + }) +} + +type mockOnchainKeyring struct { + PublicKeyFn func() types.OnchainPublicKey + SignFn func(types.ReportContext, types.Report) (signature []byte, err error) + VerifyFn func(_ types.OnchainPublicKey, _ types.ReportContext, _ types.Report, signature []byte) bool + MaxSignatureLengthFn func() int +} + +func (k *mockOnchainKeyring) PublicKey() types.OnchainPublicKey { + return k.PublicKeyFn() +} + +func (k *mockOnchainKeyring) Sign(c types.ReportContext, r types.Report) (signature []byte, err error) { + return k.SignFn(c, r) +} + +func (k *mockOnchainKeyring) Verify(pk types.OnchainPublicKey, c types.ReportContext, r types.Report, signature []byte) bool { + return k.VerifyFn(pk, c, r, signature) +} + +func (k *mockOnchainKeyring) MaxSignatureLength() int { + return k.MaxSignatureLengthFn() +} From f041eec492bfa9c59991ef2c90431da05ca14567 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Thu, 3 Aug 2023 16:46:48 -0700 Subject: [PATCH 073/270] [Functions] Temporarily disable flaky integration test (#10072) --- .../integration_tests/v0/functions_integration_test.go | 2 ++ .../integration_tests/v1/functions_integration_test.go | 1 + 2 files changed, 3 insertions(+) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go index faefefa1723..c0c0d1ff72a 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go @@ -18,6 +18,7 @@ var ( ) func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { + t.Skip() // simulated chain with all contracts owner, b, ticker, oracleContractAddress, oracleContract, clientContracts, registryAddress, registryContract, linkToken := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() @@ -45,6 +46,7 @@ func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { } func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *testing.T) { + t.Skip() // simulated chain with all contracts owner, b, ticker, oracleContractAddress, oracleContract, clientContracts, registryAddress, registryContract, linkToken := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index 428794d91c5..cf3a4c6c4de 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -20,6 +20,7 @@ var ( ) func TestIntegration_Functions_MultipleV1Requests_Success(t *testing.T) { + t.Skip() // simulated chain with all contracts owner, b, ticker, coordinatorContractAddress, coordinatorContract, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() From 08ba7621c69567ab15a0eb3e44c8cb97ff19f82b Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Thu, 3 Aug 2023 17:33:23 -0700 Subject: [PATCH 074/270] [Functions] Support router contracts in bootstrap jobs (#10054) Co-authored-by: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- .../ocr2/plugins/functions/config/config.go | 2 +- .../v1/internal/testutils.go | 11 +++-- core/services/ocrbootstrap/delegate.go | 48 ++++++++++++++++--- core/services/relay/evm/evm.go | 3 +- core/services/relay/evm/functions.go | 11 +++-- .../relay/evm/functions/logpoller_wrapper.go | 2 +- core/services/relay/relay.go | 2 +- go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 13 files changed, 70 insertions(+), 27 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 2deb3f8c1c4..dc50e937e31 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -297,7 +297,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index c7eda1a746d..7d116893fb7 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1431,8 +1431,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 h1:zCw6s6tbuk/m6oCrMXobvcEz2a/pl9Z3pj20gfPG7wE= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index 42feaeb8d6d..6e9a1071833 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -19,7 +19,7 @@ import ( // This config is part of the job spec and is loaded only once on node boot/job creation. type PluginConfig struct { - DONId string `json:"donId"` + DONID string `json:"donID"` ContractVersion uint32 `json:"contractVersion"` MinIncomingConfirmations uint32 `json:"minIncomingConfirmations"` RequestTimeoutSec uint32 `json:"requestTimeoutSec"` diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 7dc23007bb3..5d73912aa55 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -428,7 +428,11 @@ func AddBootstrapJob(t *testing.T, app *cltest.TestApplication, contractAddress [relayConfig] chainID = 1337 fromBlock = 1 - `, contractAddress)) + donID = "%s" + contractVersion = 1 + contractUpdateCheckFrequencySec = 1 + + `, contractAddress, DefaultDONId)) require.NoError(t, err) err = app.AddJobV2(testutils.Context(t), &job) require.NoError(t, err) @@ -463,7 +467,7 @@ func AddOCR2Job(t *testing.T, app *cltest.TestApplication, contractAddress commo fromBlock = 1 [pluginConfig] - donId = "%s" + donID = "%s" contractVersion = 1 minIncomingConfirmations = 3 requestTimeoutSec = 300 @@ -573,8 +577,7 @@ func CreateFunctionsNodes( } bootstrapNode = StartNewNode(t, owner, startingPort, "bootstrap", b, uint32(maxGas), nil, nil, "") - // TODO(FUN-696): refactor bootstrap job to support Functions relayers - AddBootstrapJob(t, bootstrapNode.App, coordinatorAddress) + AddBootstrapJob(t, bootstrapNode.App, routerAddress) // oracle nodes with jobs, bridges and mock EAs for i := 0; i < nOracleNodes; i++ { diff --git a/core/services/ocrbootstrap/delegate.go b/core/services/ocrbootstrap/delegate.go index 22f432e1b77..f01e01a25dc 100644 --- a/core/services/ocrbootstrap/delegate.go +++ b/core/services/ocrbootstrap/delegate.go @@ -2,6 +2,7 @@ package ocrbootstrap import ( "context" + "encoding/json" "github.com/pkg/errors" @@ -32,6 +33,13 @@ type Delegate struct { isNewlyCreatedJob bool } +// Extra fields to enable router proxy contract support. Must match field names of functions' PluginConfig. +type relayConfigRouterContractFields struct { + DONID string `json:"donID"` + ContractVersion uint32 `json:"contractVersion"` + ContractUpdateCheckFrequencySec uint32 `json:"contractUpdateCheckFrequencySec"` +} + // NewDelegateBootstrap creates a new Delegate func NewDelegateBootstrap( db *sqlx.DB, @@ -89,13 +97,39 @@ func (d *Delegate) ServicesForSpec(jobSpec job.Job) (services []job.ServiceCtx, } ctx := ctxVals.ContextWithValues(context.Background()) - configProvider, err := relayer.NewConfigProvider(ctx, types.RelayArgs{ - ExternalJobID: jobSpec.ExternalJobID, - JobID: spec.ID, - ContractID: spec.ContractID, - New: d.isNewlyCreatedJob, - RelayConfig: spec.RelayConfig.Bytes(), - }) + var routerFields relayConfigRouterContractFields + if err = json.Unmarshal(spec.RelayConfig.Bytes(), &routerFields); err != nil { + return nil, err + } + + var configProvider types.ConfigProvider + if routerFields.DONID != "" { + if routerFields.ContractVersion != 1 || routerFields.ContractUpdateCheckFrequencySec == 0 { + return nil, errors.New("invalid router contract config") + } + configProvider, err = relayer.NewFunctionsProvider( + ctx, + types.RelayArgs{ + ExternalJobID: jobSpec.ExternalJobID, + JobID: spec.ID, + ContractID: spec.ContractID, + RelayConfig: spec.RelayConfig.Bytes(), + New: d.isNewlyCreatedJob, + }, + types.PluginArgs{ + PluginConfig: spec.RelayConfig.Bytes(), // contains all necessary fields for config provider + }, + ) + } else { + configProvider, err = relayer.NewConfigProvider(ctx, types.RelayArgs{ + ExternalJobID: jobSpec.ExternalJobID, + JobID: spec.ID, + ContractID: spec.ContractID, + New: d.isNewlyCreatedJob, + RelayConfig: spec.RelayConfig.Bytes(), + }) + } + if err != nil { return nil, errors.Wrap(err, "error calling 'relayer.NewConfigWatcher'") } diff --git a/core/services/relay/evm/evm.go b/core/services/relay/evm/evm.go index 1cd06fe7a83..8f81fe780e8 100644 --- a/core/services/relay/evm/evm.go +++ b/core/services/relay/evm/evm.go @@ -130,7 +130,8 @@ func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytype } func (r *Relayer) NewFunctionsProvider(rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs) (relaytypes.FunctionsProvider, error) { - // TODO(FUN-668): Not ready yet (doesn't implement FunctionsEvents() properly) + // TODO(FUN-668): Not ready yet (doesn't implement FunctionsEvents() properly). + // Currently only used by the bootstrap job. return NewFunctionsProvider(r.chainSet, rargs, pargs, r.lggr, r.ks.Eth(), functions.FunctionsPlugin) } diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index 84a4dbc8061..ad0588e01e6 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -108,9 +108,14 @@ func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, par if err != nil { return nil, err } - contractTransmitter, err := newFunctionsContractTransmitter(pluginConfig.ContractVersion, rargs, pargs.TransmitterID, configWatcher, ethKeystore, logPollerWrapper, lggr) - if err != nil { - return nil, err + var contractTransmitter ContractTransmitter + if relayConfig.SendingKeys != nil { + contractTransmitter, err = newFunctionsContractTransmitter(pluginConfig.ContractVersion, rargs, pargs.TransmitterID, configWatcher, ethKeystore, logPollerWrapper, lggr) + if err != nil { + return nil, err + } + } else { + lggr.Warn("no sending keys configured for functions plugin, not starting contract transmitter") } return &functionsProvider{ configWatcher: configWatcher, diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 497bc5fc3a7..1ebd6aac6b6 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -233,7 +233,7 @@ func (l *logPollerWrapper) getCurrentCoordinators(ctx context.Context) (common.A return l.routerContract.Address(), l.routerContract.Address(), nil } var donId [32]byte - copy(donId[:], []byte(l.pluginConfig.DONId)) + copy(donId[:], []byte(l.pluginConfig.DONID)) activeCoordinator, err := l.routerContract.GetContractById(&bind.CallOpts{ Pending: false, diff --git a/core/services/relay/relay.go b/core/services/relay/relay.go index d1e4077de9d..2a2cf0d6867 100644 --- a/core/services/relay/relay.go +++ b/core/services/relay/relay.go @@ -66,7 +66,7 @@ func (r *relayerAdapter) NewMercuryProvider(ctx context.Context, rargs types.Rel } func (r *relayerAdapter) NewFunctionsProvider(ctx context.Context, rargs types.RelayArgs, pargs types.PluginArgs) (types.FunctionsProvider, error) { - return nil, errors.New("not implemented") + return r.Relayer.NewFunctionsProvider(rargs, pargs) } func (r *relayerAdapter) Start(ctx context.Context) error { diff --git a/go.mod b/go.mod index 7547e37f396..83fe3f0435f 100644 --- a/go.mod +++ b/go.mod @@ -67,7 +67,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac diff --git a/go.sum b/go.sum index d2db7ecc5ac..3102f793c9b 100644 --- a/go.sum +++ b/go.sum @@ -1436,8 +1436,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 h1:zCw6s6tbuk/m6oCrMXobvcEz2a/pl9Z3pj20gfPG7wE= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index d0fcf08c04e..912b318593e 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -379,7 +379,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 3c81d688167..77c73df2652 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2240,8 +2240,8 @@ github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb2 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815 h1:X8RMerGDjQKoEv7/jfh27egjye6yKmXBIf3iqwBLxsI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230801204930-f46c3ccc7815/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 h1:zCw6s6tbuk/m6oCrMXobvcEz2a/pl9Z3pj20gfPG7wE= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= From 727f5fc0b88146580874c08ca94ece0de52635d8 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Thu, 3 Aug 2023 20:41:54 -0400 Subject: [PATCH 075/270] [Functions] (refactor): Various changes from review #2 (#10055) * Reapply: s_router is private * Create libraries folder, move Functions->FunctionsRequest & FunctionsResponse types in * Revert HasRouter back to Routable, add natspec * Separate Functions library Buffer import from CBOR * Functions library, using before all * (doc): Add more comments to Functions Request library * Document and clean up FunctionsClient * Geth wrappers * Add more ToS allowlist events * s_router -> i_router * RouterBase: timelock to uint64, remove doubled Paused getter, if statement revert style * Remove unused OCR hooks * make flags index var name more clear & add comment about internal function modifiers * Regenerate geth wrappers * Various size reducing measures * (test): Amend RouterBase pausable test for new getter --- .../functions/dev/1_0_0/FunctionsBilling.sol | 6 +- .../functions/dev/1_0_0/FunctionsClient.sol | 3 +- .../dev/1_0_0/FunctionsCoordinator.sol | 29 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 104 ++--- .../dev/1_0_0/FunctionsSubscriptions.sol | 76 ++-- .../src/v0.8/functions/dev/1_0_0/Routable.sol | 11 +- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 129 +++--- .../accessControl/TermsOfServiceAllowList.sol | 22 +- .../interfaces/IFunctionsSubscriptions.sol | 25 +- .../dev/1_0_0/interfaces/IRouterBase.sol | 5 - .../v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol | 20 - .../tests/1_0_0/FunctionsRouter.t.sol | 3 +- .../testhelpers/FunctionsClientTestHelper.sol | 3 + .../FunctionsCoordinatorTestHelper.sol | 6 - .../test/v0.8/functions/v1/RouterBase.test.ts | 2 +- .../functions_allow_list.go | 398 +++++++++++++++++- .../functions_coordinator.go | 2 +- .../functions_router/functions_router.go | 144 ++++--- ...rapper-dependency-versions-do-not-edit.txt | 6 +- 19 files changed, 694 insertions(+), 300 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 0fcc3313d1d..4d79a24e1bd 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -1,13 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {Routable} from "./Routable.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; +import {Routable} from "./Routable.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; /** @@ -290,10 +290,10 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { billing.adminFee ); IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(_getRouter())); - IFunctionsSubscriptions.Subscription memory subscription = subscriptions.getSubscription(billing.subscriptionId); + (uint96 balance, , uint96 blockedBalance, , , ) = subscriptions.getSubscription(billing.subscriptionId); (, uint64 initiatedRequests, ) = subscriptions.getConsumer(billing.client, billing.subscriptionId); - if (subscription.balance - subscription.blockedBalance < estimatedCost) { + if (balance - blockedBalance < estimatedCost) { revert InsufficientBalance(); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol index ef774f8aa66..11d81499133 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol @@ -1,10 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {FunctionsRequest} from "./libraries/FunctionsRequest.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsClient} from "./interfaces/IFunctionsClient.sol"; +import {FunctionsRequest} from "./libraries/FunctionsRequest.sol"; + /** * @title The Chainlink Functions client contract * @notice Contract developers can inherit this contract in order to make Chainlink Functions requests diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 3f74fc2a3bd..179437ebb4d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -2,10 +2,12 @@ pragma solidity ^0.8.19; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; -import {IFunctionsBilling, FunctionsBilling} from "./FunctionsBilling.sol"; +import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; +import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; + +import {FunctionsBilling} from "./FunctionsBilling.sol"; import {OCR2Base} from "./ocr/OCR2Base.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; -import {ITypeAndVersion} from "./Routable.sol"; /** * @title Functions Coordinator contract @@ -16,6 +18,9 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; + // @inheritdoc ITypeAndVersion + string public constant override typeAndVersion = "Functions Coordinator v1.0.0"; + event OracleRequest( bytes32 indexed requestId, address indexed requestingContract, @@ -45,11 +50,6 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli address linkToNativeFeed ) OCR2Base(true) FunctionsBilling(router, config, linkToNativeFeed) {} - /** - * @inheritdoc ITypeAndVersion - */ - string public constant override typeAndVersion = "Functions Coordinator v1.0.0"; - /** * @inheritdoc IFunctionsCoordinator */ @@ -120,7 +120,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli */ function deleteNodePublicKey(address node) external override { // Owner can delete anything. Others can delete only their own key. - if (!(msg.sender == owner() || msg.sender == node)) { + if (msg.sender != owner() && msg.sender != node) { revert UnauthorizedPublicKeyChange(); } delete s_nodePublicKeys[node]; @@ -176,23 +176,14 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli ); } + // DON fees are pooled together. If the OCR configuration is going to change, these need to be distributed. function _beforeSetConfig(uint8 /* _f */, bytes memory /* _onchainConfig */) internal override { if (_getTransmitters().length > 0) { _disperseFeePool(); } } - function _afterSetConfig(uint8 /* _f */, bytes memory /* _onchainConfig */) internal override {} - - function _validateReport( - bytes32 /* configDigest */, - uint40 /* epochAndRound */, - bytes memory /* report */ - ) internal pure override returns (bool) { - // validate within _report to save gas - return true; - } - + // Used by FunctionsBilling.sol function _getTransmitters() internal view override returns (address[] memory) { return s_transmitters; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 0569d7e8594..eb0dd1d84f9 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -1,18 +1,24 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {RouterBase, ITypeAndVersion} from "./RouterBase.sol"; +import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; +import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; + +import {RouterBase} from "./RouterBase.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; -import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; + import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; + // @inheritdoc ITypeAndVersion + string public constant override typeAndVersion = "Functions Router v1.0.0"; + // We limit return data to a selector plus 4 words. This is to avoid // malicious contracts from returning large amounts of data and causing // repeated out-of-gas scenarios. @@ -66,6 +72,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // | Configuration state | // ================================================================ Config private s_config; + event ConfigChanged(uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] maxCallbackGasLimits); error OnlyCallableByRoute(); @@ -83,38 +90,39 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // ================================================================ // | Getters | // ================================================================ - /** - * @inheritdoc ITypeAndVersion - */ - string public constant override typeAndVersion = "Functions Router v1.0.0"; - /** - * @inheritdoc IFunctionsRouter - */ + // @inheritdoc IFunctionsRouter function getAllowListId() external pure override returns (bytes32) { return ALLOW_LIST_ID; } - /** - * @inheritdoc IFunctionsRouter - */ - function getConfig() external view override returns (uint16, uint96, bytes4, uint32[] memory) { - return ( - s_config.maxConsumersPerSubscription, - s_config.adminFee, - s_config.handleOracleFulfillmentSelector, - s_config.maxCallbackGasLimits - ); + // @inheritdoc IFunctionsRouter + function getConfig() + external + view + override + returns ( + uint16 maxConsumersPerSubscription, + uint96 adminFee, + bytes4 handleOracleFulfillmentSelector, + uint32[] memory maxCallbackGasLimits + ) + { + maxConsumersPerSubscription = s_config.maxConsumersPerSubscription; + adminFee = s_config.adminFee; + handleOracleFulfillmentSelector = s_config.handleOracleFulfillmentSelector; + maxCallbackGasLimits = s_config.maxCallbackGasLimits; + + return (maxConsumersPerSubscription, adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits); } // ================================================================ // | Configuration methods | // ================================================================ - /** - * @notice Sets the configuration for FunctionsRouter specific state - * @param config bytes of config data to set the following: - * - adminFee: fee that will be paid to the Router owner for operating the network - */ + + // @notice Sets the configuration for FunctionsRouter specific state + // @param config bytes of config data to set the following: + // - adminFee: fee that will be paid to the Router owner for operating the network function _updateConfig(bytes memory config) internal override { ( uint16 maxConsumersPerSubscription, @@ -135,9 +143,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // | Request methods | // ================================================================ - /** - * @inheritdoc IFunctionsRouter - */ + // @inheritdoc IFunctionsRouter function sendRequest( uint64 subscriptionId, bytes calldata data, @@ -149,9 +155,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions return _sendRequest(donId, coordinator, subscriptionId, data, dataVersion, callbackGasLimit); } - /** - * @inheritdoc IFunctionsRouter - */ + // @inheritdoc IFunctionsRouter function sendRequestToProposed( uint64 subscriptionId, bytes calldata data, @@ -226,9 +230,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions return commitment.requestId; } - /** - * @inheritdoc IFunctionsRouter - */ + // @inheritdoc IFunctionsRouter function fulfill( bytes memory response, bytes memory err, @@ -236,7 +238,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions uint96 costWithoutCallback, address transmitter, FunctionsResponse.Commitment memory commitment - ) external override returns (FunctionsResponse.FulfillResult resultCode, uint96 callbackGasCostJuels) { + ) external override returns (FunctionsResponse.FulfillResult resultCode, uint96) { _whenNotPaused(); if (msg.sender != commitment.coordinator) { @@ -246,20 +248,20 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions if (s_requestCommitments[commitment.requestId] == bytes32(0)) { resultCode = FunctionsResponse.FulfillResult.INVALID_REQUEST_ID; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); + return (resultCode, 0); } if (keccak256(abi.encode(commitment)) != s_requestCommitments[commitment.requestId]) { resultCode = FunctionsResponse.FulfillResult.INVALID_COMMITMENT; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); + return (resultCode, 0); } // Check that the transmitter has supplied enough gas for the callback to succeed if (gasleft() < commitment.callbackGasLimit + commitment.gasOverheadAfterCallback) { resultCode = FunctionsResponse.FulfillResult.INSUFFICIENT_GAS_PROVIDED; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); + return (resultCode, 0); } { @@ -270,14 +272,14 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions if (totalCostJuels > s_subscriptions[commitment.subscriptionId].balance) { resultCode = FunctionsResponse.FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); + return (resultCode, 0); } // Check that the cost has not exceeded the quoted cost if (totalCostJuels > commitment.estimatedTotalCostJuels) { resultCode = FunctionsResponse.FulfillResult.COST_EXCEEDS_COMMITMENT; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); - return (resultCode, callbackGasCostJuels); + return (resultCode, 0); } } @@ -290,6 +292,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions commitment.callbackGasLimit, commitment.client ); + resultCode = result.success ? FunctionsResponse.FulfillResult.USER_SUCCESS : FunctionsResponse.FulfillResult.USER_ERROR; @@ -323,7 +326,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions bytes memory err, uint32 callbackGasLimit, address client - ) private returns (CallbackResult memory result) { + ) private returns (CallbackResult memory) { bytes memory encodedCallback = abi.encodeWithSelector( s_config.handleOracleFulfillmentSelector, requestId, @@ -383,19 +386,18 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions returndatacopy(add(returnData, 0x20), 0, toCopy) } - result = CallbackResult(success, gasUsed, returnData); + return CallbackResult({success: success, gasUsed: gasUsed, returnData: returnData}); } - /** - * @inheritdoc IFunctionsRouter - */ + // @inheritdoc IFunctionsRouter function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) public view { - uint8 index = uint8(getFlags(subscriptionId)[MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX]); - if (index >= s_config.maxCallbackGasLimits.length) { - revert InvalidGasFlagValue(index); + uint8 callbackGasLimitsIndexSelector = uint8(getFlags(subscriptionId)[MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX]); + if (callbackGasLimitsIndexSelector >= s_config.maxCallbackGasLimits.length) { + revert InvalidGasFlagValue(callbackGasLimitsIndexSelector); } - if (callbackGasLimit > s_config.maxCallbackGasLimits[index]) { - revert GasLimitTooBig(s_config.maxCallbackGasLimits[index]); + uint32 maxCallbackGasLimit = s_config.maxCallbackGasLimits[callbackGasLimitsIndexSelector]; + if (callbackGasLimit > maxCallbackGasLimit) { + revert GasLimitTooBig(maxCallbackGasLimit); } } @@ -406,15 +408,19 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // ================================================================ // | Modifiers | // ================================================================ + // Favoring internal functions over actual modifiers to reduce contract size + // Used within FunctionsSubscriptions.sol function _whenNotPaused() internal view override { _requireNotPaused(); } + // Used within FunctionsSubscriptions.sol function _onlyRouterOwner() internal view override { _validateOwnership(); } + // Used within FunctionsSubscriptions.sol function _onlySenderThatAcceptedToS() internal view override { if (!IAccessController(getContractById(ALLOW_LIST_ID)).hasAccess(msg.sender, new bytes(0))) { revert SenderMustAcceptTermsOfService(msg.sender); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 79fde9a6ebf..edfa91f2c36 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -5,8 +5,10 @@ import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol" import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; -import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; + +import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; + import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; /** @@ -100,10 +102,31 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function getSubscription(uint64 subscriptionId) external view override returns (Subscription memory) { + function getSubscription( + uint64 subscriptionId + ) + external + view + override + returns ( + uint96 balance, + address owner, + uint96 blockedBalance, + address requestedOwner, + address[] memory consumers, + bytes32 flags + ) + { _isValidSubscription(subscriptionId); - return s_subscriptions[subscriptionId]; + balance = s_subscriptions[subscriptionId].balance; + owner = s_subscriptions[subscriptionId].owner; + blockedBalance = s_subscriptions[subscriptionId].blockedBalance; + requestedOwner = s_subscriptions[subscriptionId].requestedOwner; + consumers = s_subscriptions[subscriptionId].consumers; + flags = s_subscriptions[subscriptionId].flags; + + return (balance, owner, blockedBalance, requestedOwner, consumers, flags); } /** @@ -119,7 +142,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } // ================================================================ - // | Internal checks | + // | Internal validity checks | // ================================================================ function _isValidSubscription(uint64 subscriptionId) internal view { @@ -165,7 +188,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei uint96 callbackGasCostJuels = juelsPerGas * gasUsed; uint96 totalCostJuels = costWithoutCallbackJuels + adminFee + callbackGasCostJuels; - receipt = Receipt(callbackGasCostJuels, totalCostJuels); + receipt = Receipt({callbackGasCostJuels: callbackGasCostJuels, totalCostJuels: totalCostJuels}); // Charge the subscription s_subscriptions[subscriptionId].balance -= totalCostJuels; @@ -180,6 +203,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei s_subscriptions[subscriptionId].blockedBalance -= estimatedTotalCostJuels; // Increment finished requests s_consumers[client][subscriptionId].completedRequests += 1; + + return receipt; } // ================================================================ @@ -243,6 +268,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function oracleWithdraw(address recipient, uint96 amount) external override { _whenNotPaused(); + if (amount == 0) { revert InvalidCalldata(); } @@ -288,6 +314,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function createSubscription() external override returns (uint64 subscriptionId) { _whenNotPaused(); _onlySenderThatAcceptedToS(); + subscriptionId = ++s_currentSubscriptionId; s_subscriptions[subscriptionId] = Subscription({ balance: 0, @@ -299,6 +326,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei }); emit SubscriptionCreated(subscriptionId, msg.sender); + + return subscriptionId; } /** @@ -323,9 +352,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external override { _whenNotPaused(); _onlySenderThatAcceptedToS(); + address previousOwner = s_subscriptions[subscriptionId].owner; - address nextOwner = s_subscriptions[subscriptionId].requestedOwner; - if (nextOwner != msg.sender) { + if (s_subscriptions[subscriptionId].requestedOwner != msg.sender) { revert MustBeProposedOwner(); } s_subscriptions[subscriptionId].owner = msg.sender; @@ -340,6 +369,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _onlySenderThatAcceptedToS(); + Consumer memory consumerData = s_consumers[consumer][subscriptionId]; if (!consumerData.allowed) { revert InvalidConsumer(); @@ -349,12 +379,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } // Note bounded by config.maxConsumers address[] memory consumers = s_subscriptions[subscriptionId].consumers; - uint256 lastConsumerIndex = consumers.length - 1; for (uint256 i = 0; i < consumers.length; ++i) { if (consumers[i] == consumer) { - address last = consumers[lastConsumerIndex]; // Storage write to preserve last element - s_subscriptions[subscriptionId].consumers[i] = last; + s_subscriptions[subscriptionId].consumers[i] = consumers[consumers.length - 1]; // Storage remove last element s_subscriptions[subscriptionId].consumers.pop(); break; @@ -371,6 +399,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _onlySenderThatAcceptedToS(); + // Already maxed, cannot add any more consumers. if (s_subscriptions[subscriptionId].consumers.length == _getMaxConsumers()) { revert TooManyConsumers(); @@ -393,19 +422,21 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _onlySenderThatAcceptedToS(); - if (_pendingRequestExists(subscriptionId)) { + + if (pendingRequestExists(subscriptionId)) { revert PendingRequestExists(); } + _cancelSubscriptionHelper(subscriptionId, to); } function _cancelSubscriptionHelper(uint64 subscriptionId, address to) private { - Subscription memory sub = s_subscriptions[subscriptionId]; - uint96 balance = sub.balance; + Subscription memory subscription = s_subscriptions[subscriptionId]; + uint96 balance = subscription.balance; // Note bounded by config.maxConsumers // If no consumers, does nothing. - for (uint256 i = 0; i < sub.consumers.length; ++i) { - delete s_consumers[sub.consumers[i]][subscriptionId]; + for (uint256 i = 0; i < subscription.consumers.length; ++i) { + delete s_consumers[subscription.consumers[i]][subscriptionId]; } delete s_subscriptions[subscriptionId]; s_totalBalance -= balance; @@ -418,11 +449,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei /** * @inheritdoc IFunctionsSubscriptions */ - function pendingRequestExists(uint64 subscriptionId) external view override returns (bool) { - return _pendingRequestExists(subscriptionId); - } - - function _pendingRequestExists(uint64 subscriptionId) internal view returns (bool) { + function pendingRequestExists(uint64 subscriptionId) public view override returns (bool) { address[] memory consumers = s_subscriptions[subscriptionId].consumers; // Iterations will not exceed config.maxConsumers for (uint256 i = 0; i < consumers.length; ++i) { @@ -460,9 +487,11 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei */ function timeoutRequests(FunctionsResponse.Commitment[] calldata requestsToTimeoutByCommitment) external override { _whenNotPaused(); + for (uint256 i = 0; i < requestsToTimeoutByCommitment.length; ++i) { FunctionsResponse.Commitment memory request = requestsToTimeoutByCommitment[i]; bytes32 requestId = request.requestId; + uint64 subscriptionId = request.subscriptionId; // Check that request ID is valid if (keccak256(abi.encode(request)) != s_requestCommitments[requestId]) { @@ -474,11 +503,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei revert ConsumerRequestsInFlight(); } - IFunctionsBilling coordinator = IFunctionsBilling(request.coordinator); - coordinator.deleteCommitment(requestId); + IFunctionsBilling(request.coordinator).deleteCommitment(requestId); // Release blocked balance - s_subscriptions[request.subscriptionId].blockedBalance -= request.estimatedTotalCostJuels; - s_consumers[request.client][request.subscriptionId].completedRequests += 1; + s_subscriptions[subscriptionId].blockedBalance -= request.estimatedTotalCostJuels; + s_consumers[request.client][subscriptionId].completedRequests += 1; // Delete commitment delete s_requestCommitments[requestId]; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index efab161640c..cc057732b76 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -1,5 +1,4 @@ // SPDX-License-Identifier: MIT - pragma solidity ^0.8.19; import {IConfigurable} from "./interfaces/IConfigurable.sol"; @@ -13,7 +12,7 @@ import {IOwnableFunctionsRouter} from "./interfaces/IOwnableFunctionsRouter.sol" * and enforces that the Router can update the configuration of this contract */ abstract contract Routable is ITypeAndVersion, IConfigurable { - IOwnableFunctionsRouter private immutable s_router; + IOwnableFunctionsRouter private immutable i_router; error RouterMustBeSet(); error OnlyCallableByRouter(); @@ -26,12 +25,12 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { if (router == address(0)) { revert RouterMustBeSet(); } - s_router = IOwnableFunctionsRouter(router); + i_router = IOwnableFunctionsRouter(router); _updateConfig(config); } function _getRouter() internal view returns (IOwnableFunctionsRouter router) { - return s_router; + return i_router; } /** @@ -52,7 +51,7 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { * @notice Reverts if called by anyone other than the router. */ modifier onlyRouter() { - if (msg.sender != address(s_router)) { + if (msg.sender != address(i_router)) { revert OnlyCallableByRouter(); } _; @@ -62,7 +61,7 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { * @notice Reverts if called by anyone other than the router owner. */ modifier onlyRouterOwner() { - if (msg.sender != s_router.owner()) { + if (msg.sender != i_router.owner()) { revert OnlyCallableByRouterOwner(); } _; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol index a5c0a9f9842..2f665f14a90 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol @@ -13,8 +13,10 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // ================================================================ // | Route state | // ================================================================ - mapping(bytes32 id => address routableContract) internal s_route; + mapping(bytes32 id => address routableContract) private s_route; + error RouteNotFound(bytes32 id); + // Use empty bytes to self-identify, since it does not have an id bytes32 private constant ROUTER_ID = bytes32(0); @@ -27,51 +29,43 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme struct ContractProposalSet { bytes32[] ids; address[] to; - uint256 timelockEndBlock; + uint64 timelockEndBlock; } - ContractProposalSet internal s_proposedContractSet; + ContractProposalSet private s_proposedContractSet; event ContractProposed( bytes32 proposedContractSetId, address proposedContractSetFromAddress, address proposedContractSetToAddress, - uint256 timelockEndBlock + uint64 timelockEndBlock ); event ContractUpdated(bytes32 id, address from, address to); struct ConfigProposal { bytes to; - uint256 timelockEndBlock; + uint64 timelockEndBlock; } mapping(bytes32 id => ConfigProposal) private s_proposedConfig; event ConfigProposed(bytes32 id, bytes toBytes); event ConfigUpdated(bytes32 id, bytes toBytes); error InvalidProposal(); error IdentifierIsReserved(bytes32 id); - error AlreadyApplied(); - - // ================================================================ - // | Config state | - // ================================================================ - - error InvalidConfigData(); - - TimeLockProposal internal s_timelockProposal; // ================================================================ // | Timelock state | // ================================================================ - uint16 private immutable s_maximumTimelockBlocks; - uint16 internal s_timelockBlocks; + uint16 private s_timelockBlocks; struct TimeLockProposal { uint16 from; uint16 to; - uint224 timelockEndBlock; + uint64 timelockEndBlock; } + TimeLockProposal private s_timelockProposal; + event TimeLockProposed(uint16 from, uint16 to); event TimeLockUpdated(uint16 from, uint16 to); error ProposedTimelockAboveMaximum(); @@ -100,20 +94,16 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // | Route methods | // ================================================================ - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function getContractById(bytes32 id) public view override returns (address) { address currentImplementation = s_route[id]; - if (currentImplementation != address(0)) { - return currentImplementation; + if (currentImplementation == address(0)) { + revert RouteNotFound(id); } - revert RouteNotFound(id); + return currentImplementation; } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function getProposedContractById(bytes32 id) public view override returns (address) { // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { @@ -127,16 +117,21 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // ================================================================ // | Contract Proposal methods | // ================================================================ - /** - * @inheritdoc IRouterBase - */ - function getProposedContractSet() external view override returns (uint256, bytes32[] memory, address[] memory) { - return (s_proposedContractSet.timelockEndBlock, s_proposedContractSet.ids, s_proposedContractSet.to); + + // @inheritdoc IRouterBase + function getProposedContractSet() + external + view + override + returns (uint256 timelockEndBlock, bytes32[] memory ids, address[] memory to) + { + timelockEndBlock = s_proposedContractSet.timelockEndBlock; + ids = s_proposedContractSet.ids; + to = s_proposedContractSet.to; + return (timelockEndBlock, ids, to); } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function proposeContractsUpdate( bytes32[] memory proposedContractSetIds, address[] memory proposedContractSetAddresses @@ -162,7 +157,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme } } - uint256 timelockEndBlock = block.number + s_timelockBlocks; + uint64 timelockEndBlock = uint64(block.number + s_timelockBlocks); s_proposedContractSet = ContractProposalSet({ ids: proposedContractSetIds, @@ -181,9 +176,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme } } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function updateContracts() external override onlyOwner { if (block.number < s_proposedContractSet.timelockEndBlock) { revert TimelockInEffect(); @@ -191,10 +184,9 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { bytes32 id = s_proposedContractSet.ids[i]; - address from = s_route[id]; address to = s_proposedContractSet.to[i]; + emit ContractUpdated({id: id, from: s_route[id], to: to}); s_route[id] = to; - emit ContractUpdated({id: id, from: from, to: to}); } delete s_proposedContractSet; @@ -204,23 +196,20 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // | Config Proposal methods | // ================================================================ - /** - * @dev Must be implemented by inheriting contract - * Use to set configuration state of the Router - */ + // @dev Must be implemented by inheriting contract + // Use to set configuration state of the Router function _updateConfig(bytes memory config) internal virtual; - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function proposeConfigUpdateSelf(bytes calldata config) external override onlyOwner { - s_proposedConfig[ROUTER_ID] = ConfigProposal({to: config, timelockEndBlock: block.number + s_timelockBlocks}); + s_proposedConfig[ROUTER_ID] = ConfigProposal({ + to: config, + timelockEndBlock: uint64(block.number + s_timelockBlocks) + }); emit ConfigProposed({id: ROUTER_ID, toBytes: config}); } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function updateConfigSelf() external override onlyOwner { ConfigProposal memory proposal = s_proposedConfig[ROUTER_ID]; if (block.number < proposal.timelockEndBlock) { @@ -230,17 +219,13 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme emit ConfigUpdated({id: ROUTER_ID, toBytes: proposal.to}); } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function proposeConfigUpdate(bytes32 id, bytes calldata config) external override onlyOwner { - s_proposedConfig[id] = ConfigProposal({to: config, timelockEndBlock: block.number + s_timelockBlocks}); + s_proposedConfig[id] = ConfigProposal({to: config, timelockEndBlock: uint64(block.number + s_timelockBlocks)}); emit ConfigProposed({id: id, toBytes: config}); } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function updateConfig(bytes32 id) external override onlyOwner { ConfigProposal memory proposal = s_proposedConfig[id]; @@ -257,9 +242,7 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // | Timelock methods | // ================================================================ - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function proposeTimelockBlocks(uint16 blocks) external override onlyOwner { if (s_timelockBlocks == blocks) { revert InvalidProposal(); @@ -270,20 +253,15 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme s_timelockProposal = TimeLockProposal({ from: s_timelockBlocks, to: blocks, - timelockEndBlock: uint224(block.number + s_timelockBlocks) + timelockEndBlock: uint64(block.number + s_timelockBlocks) }); } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function updateTimelockBlocks() external override onlyOwner { if (block.number < s_timelockProposal.timelockEndBlock) { revert TimelockInEffect(); } - if (s_timelockBlocks == s_timelockProposal.to) { - revert AlreadyApplied(); - } s_timelockBlocks = s_timelockProposal.to; } @@ -291,23 +269,12 @@ abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, Confirme // | Pausable methods | // ================================================================ - /** - * @inheritdoc IRouterBase - */ - function isPaused() external view override returns (bool) { - return Pausable.paused(); - } - - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function pause() external override onlyOwner { _pause(); } - /** - * @inheritdoc IRouterBase - */ + // @inheritdoc IRouterBase function unpause() external override onlyOwner { _unpause(); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index 3d656204dec..e259a0d164d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -2,10 +2,11 @@ pragma solidity ^0.8.19; import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.sol"; -import {Routable} from "../Routable.sol"; import {IAccessController} from "../../../../shared/interfaces/IAccessController.sol"; import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol"; +import {Routable} from "../Routable.sol"; + import {Address} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol"; import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; @@ -16,9 +17,16 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC using Address for address; using EnumerableSet for EnumerableSet.AddressSet; + // @inheritdoc ITypeAndVersion + string public constant override typeAndVersion = "Functions Terms of Service Allow List v1.0.0"; + EnumerableSet.AddressSet private s_allowedSenders; mapping(address => bool) private s_blockedSenders; + event AddedAccess(address user); + event BlockedAccess(address user); + event UnblockedAccess(address user); + error InvalidSignature(); error InvalidUsage(); error RecipientIsBlocked(); @@ -34,7 +42,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC Config private s_config; - event ConfigSet(bool enabled); + event ConfigSet(bool enabled, address signerPublicKey); // ================================================================ // | Initialization | @@ -55,14 +63,9 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC function _updateConfig(bytes memory config) internal override { (bool enabled, address signerPublicKey) = abi.decode(config, (bool, address)); s_config = Config({enabled: enabled, signerPublicKey: signerPublicKey}); - emit ConfigSet(enabled); + emit ConfigSet(enabled, signerPublicKey); } - /** - * @inheritdoc ITypeAndVersion - */ - string public constant override typeAndVersion = "Functions Terms of Service Allow List v1.0.0"; - // ================================================================ // | Terms of Service methods | // ================================================================ @@ -100,6 +103,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC // Add recipient to the allow list s_allowedSenders.add(recipient); + emit AddedAccess(recipient); } /** @@ -139,6 +143,7 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC function blockSender(address sender) external override onlyRouterOwner { s_allowedSenders.remove(sender); s_blockedSenders[sender] = true; + emit BlockedAccess(sender); } /** @@ -146,5 +151,6 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC */ function unblockSender(address sender) external override onlyRouterOwner { s_blockedSenders[sender] = false; + emit UnblockedAccess(sender); } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index e4bdd659980..7ee877eaa46 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -19,7 +19,7 @@ interface IFunctionsSubscriptions { // 2. To be able to return the list of all consumers in getSubscription. // Note that we need the s_consumers map to be able to directly check if a // consumer is valid without reading all the consumers from storage. - address[] consumers; + address[] consumers; // Client contracts that can use the subscription bytes32 flags; // Per-subscription flags. } @@ -32,9 +32,26 @@ interface IFunctionsSubscriptions { /** * @notice Get details about a subscription. * @param subscriptionId - ID of the subscription - * @return subscription - list of consumer address which are able to use this subscription. - */ - function getSubscription(uint64 subscriptionId) external view returns (Subscription memory); + * @return balance - Common LINK balance that is controlled by the Registry to be used for all consumer requests. + * @return owner - Owner can fund/withdraw/cancel the sub. + * @return blockedBalance - LINK balance that is reserved to pay for pending consumer requests. + * @return requestedOwner - For safely transferring sub ownership. + * @return consumers - Client contracts that can use the subscription + * @return flags - Per-subscription flags. + */ + function getSubscription( + uint64 subscriptionId + ) + external + view + returns ( + uint96 balance, + address owner, + uint96 blockedBalance, + address requestedOwner, + address[] memory consumers, + bytes32 flags + ); /** * @notice Get details about a consumer of a subscription. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol index aaae944264b..48167e2b1c0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol @@ -81,11 +81,6 @@ interface IRouterBase { */ function updateTimelockBlocks() external; - /** - * @dev Returns true if the contract is paused, and false otherwise. - */ - function isPaused() external view returns (bool); - /** * @dev Puts the system into an emergency stopped state. * @dev Only callable by owner diff --git a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol index b1a5ecbc7c5..564c3968a32 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol @@ -186,8 +186,6 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { args.offchainConfigVersion, args.offchainConfig ); - - _afterSetConfig(args.f, args.onchainConfig); } function configDigestFromConfigData( @@ -246,20 +244,6 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { function _beforeSetConfig(uint8 _f, bytes memory _onchainConfig) internal virtual; - function _afterSetConfig(uint8 _f, bytes memory _onchainConfig) internal virtual; - - /** - * @dev hook to allow additional validation of the report by the extending contract - * @param configDigest separation tag for current config (see configDigestFromConfigData) - * @param epochAndRound 27 byte padding, 4-byte epoch and 1-byte round - * @param report serialized report - */ - function _validateReport( - bytes32 configDigest, - uint40 epochAndRound, - bytes memory report - ) internal virtual returns (bool); - /** * @dev hook called after the report has been fully validated * for the extending contract to handle additional logic, such as oracle payment @@ -334,10 +318,6 @@ abstract contract OCR2Base is ConfirmedOwner, OCR2Abstract { bytes32 configDigest = reportContext[0]; uint32 epochAndRound = uint32(uint256(reportContext[1])); - if (!_validateReport(configDigest, epochAndRound, report)) { - revert ReportInvalid(); - } - emit Transmitted(configDigest, uint32(epochAndRound >> 8)); ConfigInfo memory configInfo = s_configInfo; diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index fe9fd46930f..10a27ae78ba 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -1,9 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; +import {IFunctionsRouter} from "../../dev/1_0_0/interfaces/IFunctionsRouter.sol"; + import {BaseTest} from "./BaseTest.t.sol"; import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; -import {IFunctionsRouter} from "../../dev/1_0_0/interfaces/IFunctionsRouter.sol"; import {FunctionsCoordinator} from "../../dev/1_0_0/FunctionsCoordinator.sol"; import {FunctionsBilling} from "../../dev/1_0_0/FunctionsBilling.sol"; import {MockV3Aggregator} from "../../../tests/MockV3Aggregator.sol"; diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index 175dac932a9..61073b23450 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -6,6 +6,9 @@ import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; import {ITermsOfServiceAllowList} from "../../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; import {IFunctionsSubscriptions} from "../../../dev/1_0_0/interfaces/IFunctionsSubscriptions.sol"; +import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; +import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; + contract FunctionsClientTestHelper is FunctionsClient { using FunctionsRequest for FunctionsRequest.Request; diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol index e2bcd12bfa6..42ed2a9493d 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol @@ -10,12 +10,6 @@ contract FunctionsCoordinatorTestHelper is FunctionsCoordinator { address linkToNativeFeed ) FunctionsCoordinator(router, config, linkToNativeFeed) {} - function callValidateReport(bytes calldata report) external pure returns (bool isValid) { - bytes32 configDigest; - uint40 epochAndRound; - isValid = _validateReport(configDigest, epochAndRound, report); - } - function callReport(bytes calldata report) external { address[MAX_NUM_ORACLES] memory signers; signers[0] = msg.sender; diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 4797dd61af4..712894742be 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -335,7 +335,7 @@ describe('FunctionsRouter - Base', () => { describe('Emergency Pause', () => { it('has paused state visible', async () => { - const paused = await contracts.router.isPaused() + const paused = await contracts.router.paused() expect(paused).to.equal(false) }) it('can pause the system', async () => { diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index 02f71ba6926..b7c3a0fc85c 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -31,8 +31,8 @@ var ( ) var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200118e3803806200118e83398101604081905262000034916200014b565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b038216608052620000768162000080565b5050505062000279565b6000808280602001905181019062000099919062000236565b6040805180820182528315158082526001600160a01b0384166020928301819052600380546001600160a81b031916610100600160a81b031984161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b6001600160a01b03811681146200013257600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200015f57600080fd5b82516200016c816200011c565b602084810151919350906001600160401b03808211156200018c57600080fd5b818601915086601f830112620001a157600080fd5b815181811115620001b657620001b662000135565b604051601f8201601f19908116603f01168101908382118183101715620001e157620001e162000135565b816040528281528986848701011115620001fa57600080fd5b600093505b828410156200021e5784840186015181850187015292850192620001ff565b60008684830101528096505050505050509250929050565b600080604083850312156200024a57600080fd5b825180151581146200025b57600080fd5b60208401519092506200026e816200011c565b809150509250929050565b608051610eeb620002a3600039600081816103cb0152818161054701526106ad0152610eeb6000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c8063817ef62e116100765780638cc6acce1161005b5780638cc6acce14610139578063a39b06e31461014c578063a5e1d61d1461016d57600080fd5b8063817ef62e1461011157806382184c7b1461012657600080fd5b8063181f5a77146100a85780633908c4d4146100c657806347663acb146100db5780636b14daf8146100ee575b600080fd5b6100b0610180565b6040516100bd9190610aa3565b60405180910390f35b6100d96100d4366004610b31565b61019c565b005b6100d96100e9366004610b96565b6103c9565b6101016100fc366004610bb3565b61050a565b60405190151581526020016100bd565b610119610534565b6040516100bd9190610c38565b6100d9610134366004610b96565b610545565b6100d9610147366004610cc1565b610695565b61015f61015a366004610d90565b610710565b6040519081526020016100bd565b61010161017b366004610b96565b61076e565b6040518060600160405280602c8152602001610eb3602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526002602052604090205460ff16156101fc576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006102088686610710565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206003546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156102e2573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610339576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061037e57503373ffffffffffffffffffffffffffffffffffffffff87161480159061037e5750333b155b156103b5576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103c06000866107af565b50505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610436573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061045a9190610dc9565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146104be576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169055565b60035460009060ff1661051f5750600161052d565b61052a6000856107d1565b90505b9392505050565b60606105406000610800565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af11580156105b2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105d69190610dc9565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461063a576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61064560008261080d565b5073ffffffffffffffffffffffffffffffffffffffff16600090815260026020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610704576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61070d8161082f565b50565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60035460009060ff1661078357506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b600061052d8373ffffffffffffffffffffffffffffffffffffffff8416610905565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561052d565b6060600061052d83610954565b600061052d8373ffffffffffffffffffffffffffffffffffffffff84166109b0565b600080828060200190518101906108469190610de6565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600380547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010090920291909117905591519182529294509092507f22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f910160405180910390a1505050565b600081815260018301602052604081205461094c57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610768565b506000610768565b6060816000018054806020026020016040519081016040528092919081815260200182805480156109a457602002820191906000526020600020905b815481526020019060010190808311610990575b50505050509050919050565b60008181526001830160205260408120548015610a995760006109d4600183610e1a565b85549091506000906109e890600190610e1a565b9050818114610a4d576000866000018281548110610a0857610a08610e54565b9060005260206000200154905080876000018481548110610a2b57610a2b610e54565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610a5e57610a5e610e83565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610768565b6000915050610768565b600060208083528351808285015260005b81811015610ad057858101830151858201604001528201610ab4565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff8116811461070d57600080fd5b600080600080600060a08688031215610b4957600080fd5b8535610b5481610b0f565b94506020860135610b6481610b0f565b93506040860135925060608601359150608086013560ff81168114610b8857600080fd5b809150509295509295909350565b600060208284031215610ba857600080fd5b813561052d81610b0f565b600080600060408486031215610bc857600080fd5b8335610bd381610b0f565b9250602084013567ffffffffffffffff80821115610bf057600080fd5b818601915086601f830112610c0457600080fd5b813581811115610c1357600080fd5b876020828501011115610c2557600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b81811015610c8657835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610c54565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610cd357600080fd5b813567ffffffffffffffff80821115610ceb57600080fd5b818401915084601f830112610cff57600080fd5b813581811115610d1157610d11610c92565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610d5757610d57610c92565b81604052828152876020848701011115610d7057600080fd5b826020860160208301376000928101602001929092525095945050505050565b60008060408385031215610da357600080fd5b8235610dae81610b0f565b91506020830135610dbe81610b0f565b809150509250929050565b600060208284031215610ddb57600080fd5b815161052d81610b0f565b60008060408385031215610df957600080fd5b82518015158114610e0957600080fd5b6020840151909250610dbe81610b0f565b81810381811115610768577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"AddedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"BlockedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"UnblockedAccess\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620012443803806200124483398101604081905262000034916200014e565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b038216608052620000768162000080565b505050506200027c565b6000808280602001905181019062000099919062000239565b6040805180820182528315158082526001600160a01b0384166020928301819052600380546001600160a81b031916610100600160a81b031984161761010083021790558351918252918101919091529294509092507f232bb132911bf7acb3a5ab4dd8e603080819db6a26b68da198599a7c83e2494c910160405180910390a1505050565b6001600160a01b03811681146200013557600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016257600080fd5b82516200016f816200011f565b602084810151919350906001600160401b03808211156200018f57600080fd5b818601915086601f830112620001a457600080fd5b815181811115620001b957620001b962000138565b604051601f8201601f19908116603f01168101908382118183101715620001e457620001e462000138565b816040528281528986848701011115620001fd57600080fd5b600093505b8284101562000221578484018601518185018701529285019262000202565b60008684830101528096505050505050509250929050565b600080604083850312156200024d57600080fd5b825180151581146200025e57600080fd5b602084015190925062000271816200011f565b809150509250929050565b608051610f9e620002a660003960008181610414015281816105c7015261075d0152610f9e6000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c8063817ef62e116100765780638cc6acce1161005b5780638cc6acce14610139578063a39b06e31461014c578063a5e1d61d1461016d57600080fd5b8063817ef62e1461011157806382184c7b1461012657600080fd5b8063181f5a77146100a85780633908c4d4146100c657806347663acb146100db5780636b14daf8146100ee575b600080fd5b6100b0610180565b6040516100bd9190610b56565b60405180910390f35b6100d96100d4366004610be4565b61019c565b005b6100d96100e9366004610c49565b610412565b6101016100fc366004610c66565b61058a565b60405190151581526020016100bd565b6101196105b4565b6040516100bd9190610ceb565b6100d9610134366004610c49565b6105c5565b6100d9610147366004610d74565b610745565b61015f61015a366004610e43565b6107c0565b6040519081526020016100bd565b61010161017b366004610c49565b61081e565b6040518060600160405280602c8152602001610f66602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526002602052604090205460ff16156101fc576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061020886866107c0565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206003546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156102e2573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610339576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061037e57503373ffffffffffffffffffffffffffffffffffffffff87161480159061037e5750333b155b156103b5576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103c060008661085f565b5060405173ffffffffffffffffffffffffffffffffffffffff861681527f87286ad1f399c8e82bf0c4ef4fcdc570ea2e1e92176e5c848b6413545b885db49060200160405180910390a1505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561047f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104a39190610e7c565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610507576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905590519182527f28bbd0761309a99e8fb5e5d02ada0b7b2db2e5357531ff5dbfc205c3f5b6592b91015b60405180910390a150565b60035460009060ff1661059f575060016105ad565b6105aa600085610881565b90505b9392505050565b60606105c060006108b0565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610632573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106569190610e7c565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106ba576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c56000826108bd565b5073ffffffffffffffffffffffffffffffffffffffff811660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e1910161057f565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146107b4576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107bd816108df565b50565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60035460009060ff1661083357506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b60006105ad8373ffffffffffffffffffffffffffffffffffffffff84166109b8565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415156105ad565b606060006105ad83610a07565b60006105ad8373ffffffffffffffffffffffffffffffffffffffff8416610a63565b600080828060200190518101906108f69190610e99565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600380547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010083021790558351918252918101919091529294509092507f232bb132911bf7acb3a5ab4dd8e603080819db6a26b68da198599a7c83e2494c910160405180910390a1505050565b60008181526001830160205260408120546109ff57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610818565b506000610818565b606081600001805480602002602001604051908101604052809291908181526020018280548015610a5757602002820191906000526020600020905b815481526020019060010190808311610a43575b50505050509050919050565b60008181526001830160205260408120548015610b4c576000610a87600183610ecd565b8554909150600090610a9b90600190610ecd565b9050818114610b00576000866000018281548110610abb57610abb610f07565b9060005260206000200154905080876000018481548110610ade57610ade610f07565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610b1157610b11610f36565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610818565b6000915050610818565b600060208083528351808285015260005b81811015610b8357858101830151858201604001528201610b67565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff811681146107bd57600080fd5b600080600080600060a08688031215610bfc57600080fd5b8535610c0781610bc2565b94506020860135610c1781610bc2565b93506040860135925060608601359150608086013560ff81168114610c3b57600080fd5b809150509295509295909350565b600060208284031215610c5b57600080fd5b81356105ad81610bc2565b600080600060408486031215610c7b57600080fd5b8335610c8681610bc2565b9250602084013567ffffffffffffffff80821115610ca357600080fd5b818601915086601f830112610cb757600080fd5b813581811115610cc657600080fd5b876020828501011115610cd857600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b81811015610d3957835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610d07565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610d8657600080fd5b813567ffffffffffffffff80821115610d9e57600080fd5b818401915084601f830112610db257600080fd5b813581811115610dc457610dc4610d45565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610e0a57610e0a610d45565b81604052828152876020848701011115610e2357600080fd5b826020860160208301376000928101602001929092525095945050505050565b60008060408385031215610e5657600080fd5b8235610e6181610bc2565b91506020830135610e7181610bc2565b809150509250929050565b600060208284031215610e8e57600080fd5b81516105ad81610bc2565b60008060408385031215610eac57600080fd5b82518015158114610ebc57600080fd5b6020840151909250610e7181610bc2565b81810381811115610818577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI @@ -329,6 +329,240 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) Update return _TermsOfServiceAllowList.Contract.UpdateConfig(&_TermsOfServiceAllowList.TransactOpts, config) } +type TermsOfServiceAllowListAddedAccessIterator struct { + Event *TermsOfServiceAllowListAddedAccess + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *TermsOfServiceAllowListAddedAccessIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TermsOfServiceAllowListAddedAccess) + 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(TermsOfServiceAllowListAddedAccess) + 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 *TermsOfServiceAllowListAddedAccessIterator) Error() error { + return it.fail +} + +func (it *TermsOfServiceAllowListAddedAccessIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TermsOfServiceAllowListAddedAccess struct { + User common.Address + Raw types.Log +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterAddedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListAddedAccessIterator, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "AddedAccess") + if err != nil { + return nil, err + } + return &TermsOfServiceAllowListAddedAccessIterator{contract: _TermsOfServiceAllowList.contract, event: "AddedAccess", logs: logs, sub: sub}, nil +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchAddedAccess(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListAddedAccess) (event.Subscription, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "AddedAccess") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TermsOfServiceAllowListAddedAccess) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "AddedAccess", 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 (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseAddedAccess(log types.Log) (*TermsOfServiceAllowListAddedAccess, error) { + event := new(TermsOfServiceAllowListAddedAccess) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "AddedAccess", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type TermsOfServiceAllowListBlockedAccessIterator struct { + Event *TermsOfServiceAllowListBlockedAccess + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *TermsOfServiceAllowListBlockedAccessIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TermsOfServiceAllowListBlockedAccess) + 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(TermsOfServiceAllowListBlockedAccess) + 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 *TermsOfServiceAllowListBlockedAccessIterator) Error() error { + return it.fail +} + +func (it *TermsOfServiceAllowListBlockedAccessIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TermsOfServiceAllowListBlockedAccess struct { + User common.Address + Raw types.Log +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterBlockedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListBlockedAccessIterator, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "BlockedAccess") + if err != nil { + return nil, err + } + return &TermsOfServiceAllowListBlockedAccessIterator{contract: _TermsOfServiceAllowList.contract, event: "BlockedAccess", logs: logs, sub: sub}, nil +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchBlockedAccess(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListBlockedAccess) (event.Subscription, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "BlockedAccess") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TermsOfServiceAllowListBlockedAccess) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "BlockedAccess", 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 (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseBlockedAccess(log types.Log) (*TermsOfServiceAllowListBlockedAccess, error) { + event := new(TermsOfServiceAllowListBlockedAccess) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "BlockedAccess", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type TermsOfServiceAllowListConfigSetIterator struct { Event *TermsOfServiceAllowListConfigSet @@ -390,8 +624,9 @@ func (it *TermsOfServiceAllowListConfigSetIterator) Close() error { } type TermsOfServiceAllowListConfigSet struct { - Enabled bool - Raw types.Log + Enabled bool + SignerPublicKey common.Address + Raw types.Log } func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterConfigSet(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigSetIterator, error) { @@ -446,18 +681,153 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseConfigSet( return event, nil } +type TermsOfServiceAllowListUnblockedAccessIterator struct { + Event *TermsOfServiceAllowListUnblockedAccess + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *TermsOfServiceAllowListUnblockedAccessIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TermsOfServiceAllowListUnblockedAccess) + 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(TermsOfServiceAllowListUnblockedAccess) + 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 *TermsOfServiceAllowListUnblockedAccessIterator) Error() error { + return it.fail +} + +func (it *TermsOfServiceAllowListUnblockedAccessIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TermsOfServiceAllowListUnblockedAccess struct { + User common.Address + Raw types.Log +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterUnblockedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListUnblockedAccessIterator, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "UnblockedAccess") + if err != nil { + return nil, err + } + return &TermsOfServiceAllowListUnblockedAccessIterator{contract: _TermsOfServiceAllowList.contract, event: "UnblockedAccess", logs: logs, sub: sub}, nil +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchUnblockedAccess(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListUnblockedAccess) (event.Subscription, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "UnblockedAccess") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TermsOfServiceAllowListUnblockedAccess) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "UnblockedAccess", 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 (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseUnblockedAccess(log types.Log) (*TermsOfServiceAllowListUnblockedAccess, error) { + event := new(TermsOfServiceAllowListUnblockedAccess) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "UnblockedAccess", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + func (_TermsOfServiceAllowList *TermsOfServiceAllowList) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { + case _TermsOfServiceAllowList.abi.Events["AddedAccess"].ID: + return _TermsOfServiceAllowList.ParseAddedAccess(log) + case _TermsOfServiceAllowList.abi.Events["BlockedAccess"].ID: + return _TermsOfServiceAllowList.ParseBlockedAccess(log) case _TermsOfServiceAllowList.abi.Events["ConfigSet"].ID: return _TermsOfServiceAllowList.ParseConfigSet(log) + case _TermsOfServiceAllowList.abi.Events["UnblockedAccess"].ID: + return _TermsOfServiceAllowList.ParseUnblockedAccess(log) default: return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) } } +func (TermsOfServiceAllowListAddedAccess) Topic() common.Hash { + return common.HexToHash("0x87286ad1f399c8e82bf0c4ef4fcdc570ea2e1e92176e5c848b6413545b885db4") +} + +func (TermsOfServiceAllowListBlockedAccess) Topic() common.Hash { + return common.HexToHash("0x337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e1") +} + func (TermsOfServiceAllowListConfigSet) Topic() common.Hash { - return common.HexToHash("0x22aa8545955b447cb49ea37e67de742e750839c633ded8c9b5b09614843b229f") + return common.HexToHash("0x232bb132911bf7acb3a5ab4dd8e603080819db6a26b68da198599a7c83e2494c") +} + +func (TermsOfServiceAllowListUnblockedAccess) Topic() common.Hash { + return common.HexToHash("0x28bbd0761309a99e8fb5e5d02ada0b7b2db2e5357531ff5dbfc205c3f5b6592b") } func (_TermsOfServiceAllowList *TermsOfServiceAllowList) Address() common.Address { @@ -483,12 +853,30 @@ type TermsOfServiceAllowListInterface interface { UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) + FilterAddedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListAddedAccessIterator, error) + + WatchAddedAccess(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListAddedAccess) (event.Subscription, error) + + ParseAddedAccess(log types.Log) (*TermsOfServiceAllowListAddedAccess, error) + + FilterBlockedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListBlockedAccessIterator, error) + + WatchBlockedAccess(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListBlockedAccess) (event.Subscription, error) + + ParseBlockedAccess(log types.Log) (*TermsOfServiceAllowListBlockedAccess, error) + FilterConfigSet(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigSetIterator, error) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListConfigSet) (event.Subscription, error) ParseConfigSet(log types.Log) (*TermsOfServiceAllowListConfigSet, error) + FilterUnblockedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListUnblockedAccessIterator, error) + + WatchUnblockedAccess(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListUnblockedAccess) (event.Subscription, error) + + ParseUnblockedAccess(log types.Log) (*TermsOfServiceAllowListUnblockedAccess, error) + ParseLog(log types.Log) (generated.AbigenLog, error) Address() common.Address diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 12ba18863c2..0cff7b99918 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -65,7 +65,7 @@ type IFunctionsCoordinatorRequest struct { var FunctionsCoordinatorMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005ab338038062005ab3833981016040819052620000349162000458565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b03909216919091179055506200062a9350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000219919062000568565b9850985098509850985098509850985098506000811362000251576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260088054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f9062000411908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043d57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046e57600080fd5b620004798462000425565b602085810151919450906001600160401b03808211156200049957600080fd5b818701915087601f830112620004ae57600080fd5b815181811115620004c357620004c362000442565b604051601f8201601f19908116603f01168101908382118183101715620004ee57620004ee62000442565b816040528281528a868487010111156200050757600080fd5b600093505b828410156200052b57848401860151818501870152928501926200050c565b60008684830101528097505050505050506200054a6040850162000425565b90509250925092565b805163ffffffff811681146200043d57600080fd5b60008060008060008060008060006101208a8c0312156200058857600080fd5b620005938a62000553565b9850620005a360208b0162000553565b9750620005b360408b0162000553565b9650620005c360608b0162000553565b9550620005d360808b0162000553565b60a08b01519095506001600160501b0381168114620005f157600080fd5b60c08b015190945061ffff811681146200060a57600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a051615432620006816000396000818161068201528181610ab901528181610edc01528181610fba015281816118af01528181611b4901528181613121015261397d0152600061128001526154326000f3fe608060405234801561001057600080fd5b50600436106101a35760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610517578063d328a91e1461052a578063e3d0e71214610532578063f2fde38b1461054557600080fd5b8063b1dc65a4146103e6578063bdd7e880146103f9578063c3f909d41461041957600080fd5b80638da5cb5b116100c85780638da5cb5b14610388578063af1296d3146103b0578063afcb95d7146103c657600080fd5b806381ff7048146102e557806385b214cf146103525780638cc6acce1461037557600080fd5b806366316d8d11610150578063807560311161012a57806380756031146102b557806381411834146102c857806381f1b938146102dd57600080fd5b806366316d8d1461028757806379ba50971461029a5780637f15e166146102a257600080fd5b806326ceabac1161018157806326ceabac146102395780632a905ccc1461024c578063533989871461027157600080fd5b8063083a5466146101a85780630e7ada39146101bd578063181f5a77146101f0575b600080fd5b6101bb6101b6366004613bf7565b610558565b005b6101d06101cb366004613e24565b6105ad565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b61022c6040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101e79190613f59565b6101bb610247366004613f73565b6105db565b61025461067d565b6040516bffffffffffffffffffffffff90911681526020016101e7565b61027961073b565b6040516101e7929190613fe1565b6101bb610295366004614071565b6109bf565b6101bb610b79565b6101bb6102b0366004613bf7565b610c7b565b6101bb6102c33660046140aa565b610ccb565b6102d0610d82565b6040516101e791906140ff565b61022c610df1565b61032f60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101e7565b610365610360366004614112565b610ec2565b60405190151581526020016101e7565b6101bb61038336600461412b565b610fa2565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101e7565b6103b861101a565b6040519081526020016101e7565b6040805160018152600060208201819052918101919091526060016101e7565b6101bb6103f43660046141ad565b61110d565b61040c610407366004614264565b61183e565b6040516101e791906143c6565b600854600954600a54600c546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101e7565b6102546105253660046143d5565b611b45565b61022c611d11565b6101bb6105403660046144ee565b611d68565b6101bb610553366004613f73565b61278c565b61056061279d565b600081900361059b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105a882848361465c565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061061657503373ffffffffffffffffffffffffffffffffffffffff8216145b61064c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e6020526040812061067a91613b3c565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106eb573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052610731919081019061479d565b5090949350505050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107a357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610778575b505050505090506000815167ffffffffffffffff8111156107c6576107c6613c39565b6040519080825280602002602001820160405280156107f957816020015b60608152602001906001900390816107e45790505b50905060005b82518110156109b557600e600084838151811061081e5761081e614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086b906145bb565b90506000036108a6576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e60008483815181106108bc576108bc614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610909906145bb565b80601f0160208091040260200160405190810160405280929190818152602001828054610935906145bb565b80156109825780601f1061095757610100808354040283529160200191610982565b820191906000526020600020905b81548152906001019060200180831161096557829003601f168201915b505050505082828151811061099957610999614898565b6020026020010181905250806109ae906148f6565b90506107ff565b5090939092509050565b6109c7612820565b806bffffffffffffffffffffffff166000036109fd5750336000908152600b60205260409020546bffffffffffffffffffffffff165b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a57576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a849084906bffffffffffffffffffffffff1661492e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610adb7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b5c57600080fd5b505af1158015610b70573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610bff576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c8361279d565b6000819003610cbe576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105a882848361465c565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d165750610cf5336129b1565b8015610d1657503373ffffffffffffffffffffffffffffffffffffffff8416145b610d4c576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610d7c82848361465c565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610de757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dbc575b5050505050905090565b6060600f8054610e00906145bb565b9050600003610e3b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610e48906145bb565b80601f0160208091040260200160405190810160405280929190818152602001828054610e74906145bb565b8015610de75780601f10610e9657610100808354040283529160200191610de7565b820191906000526020600020905b815481529060010190602001808311610ea457509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f33576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260076020526040902054610f4e57506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610f919084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611011576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61067a81612a9a565b600854600c54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d89190614974565b509350509250508280156110fa57506110f181426149c4565b8463ffffffff16105b1561110557600a5491505b509392505050565b60005a604080516020601f8b018190048102820181019092528981529192508a3591818c01359161116391849163ffffffff851691908e908e9081908401838280828437600092019190915250612da392505050565b611199576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805183815262ffffff600884901c1660208201527fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461126e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610bf6565b61127c8b8b8b8b8b8b612dac565b60007f0000000000000000000000000000000000000000000000000000000000000000156112d9576002826020015183604001516112ba91906149d7565b6112c49190614a1f565b6112cf9060016149d7565b60ff1690506112ef565b60208201516112e99060016149d7565b60ff1690505b888114611358576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610bf6565b8887146113c1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610bf6565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561140457611404614a41565b600281111561141557611415614a41565b905250905060028160200151600281111561143257611432614a41565b14801561147957506006816000015160ff168154811061145457611454614898565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610bf6565b50505050506114ec613b76565b6000808a8a6040516114ff929190614a70565b604051908190038120611516918e90602001614a80565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561182057600060018489846020811061157f5761157f614898565b61158c91901a601b6149d7565b8e8e8681811061159e5761159e614898565b905060200201358d8d878181106115b7576115b7614898565b90506020020135604051600081526020016040526040516115f4949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611616573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561169657611696614a41565b60028111156116a7576116a7614a41565b90525092506001836020015160028111156116c4576116c4614a41565b1461172b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610bf6565b8251600090879060ff16601f811061174557611745614898565b602002015173ffffffffffffffffffffffffffffffffffffffff16146117c7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610bf6565b8086846000015160ff16601f81106117e1576117e1614898565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261180c6001866149d7565b94505080611819906148f6565b9050611560565b505050611831833383858e8e612e5a565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611906576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6119136040830183614a94565b905060000361194d576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a0016040528084606001602081019061196d9190614af9565b67ffffffffffffffff16815260209081019061198b90860186613f73565b73ffffffffffffffffffffffffffffffffffffffff1681526020016119b660e0860160c08701614b16565b63ffffffff1681523a60208201526040016119d8610100860160e08701614b33565b6bffffffffffffffffffffffff1690529050611a456119fa6040850185614a94565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a3f9250505060a0860160808701614b50565b83613028565b9150611a546020840184613f73565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611aa49190614af9565b611ab46040890160208a01613f73565b611ac160408a018a614a94565b611ad160a08c0160808d01614b50565b60a08c0135611ae660e08e0160c08f01614b16565b8c604051602001611af791906143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b37999897969594939291614b6d565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611be557600080fd5b505afa158015611bf9573d6000803e3d6000fd5b50505050620f4240821115611c3a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c4461067d565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611ce888888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105ad915050565b69ffffffffffffffffffff169050611d028686838661351c565b93505050505b95945050505050565b6060600d8054611d20906145bb565b9050600003611d5b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610e48906145bb565b855185518560ff16601f831115611ddb576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610bf6565b80600003611e45576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610bf6565b818314611ed3576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610bf6565b611ede816003614c31565b8311611f46576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610bf6565b611f4e61279d565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f95908861368c565b6005541561214a57600554600090611faf906001906149c4565b9050600060058281548110611fc657611fc6614898565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061200057612000614898565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061208057612080614c48565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120e9576120e9614c48565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f95915050565b60005b8151518110156125b1576000600460008460000151848151811061217357612173614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156121bd576121bd614a41565b14612224576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610bf6565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061225557612255614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122f6576122f6614a41565b0217905550600091506123069050565b600460008460200151848151811061232057612320614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561236a5761236a614a41565b146123d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610bf6565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061240457612404614898565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156124a5576124a5614a41565b0217905550508251805160059250839081106124c3576124c3614898565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909316929092179091558201518051600691908390811061253f5761253f614898565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125a9816148f6565b91505061214d565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161266991849174010000000000000000000000000000000000000000900416614c77565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126c84630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516136a9565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861277f988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614c94565b60405180910390a1611831565b61279461279d565b61067a81613754565b60005473ffffffffffffffffffffffffffffffffffffffff16331461281e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bf6565b565b600061282a610d82565b90508051600003612867576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612886916bffffffffffffffffffffffff16614d2a565b905060005b82518110156129525781600b60008584815181106128ab576128ab614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166129139190614d55565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508061294b906148f6565b905061288b565b50815161295f9082614d7a565b600c805460009061297f9084906bffffffffffffffffffffffff1661492e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612a1757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129ec575b5050505050905060005b8151811015612a90578373ffffffffffffffffffffffffffffffffffffffff16828281518110612a5357612a53614898565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a80575060019392505050565b612a89816148f6565b9050612a21565b5060009392505050565b600080600080600080600080600089806020019051810190612abc9190614daa565b98509850985098509850985098509850985060008113612b0b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600880547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d8f908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b60019392505050565b6000612db9826020614c31565b612dc4856020614c31565b612dd088610144614e56565b612dda9190614e56565b612de49190614e56565b612def906000614e56565b9050368114610b70576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610bf6565b606080808080612e6c86880188614f44565b8451949950929750909550935091501580612e8957508351855114155b80612e9657508251855114155b80612ea357508151855114155b80612eb057508051855114155b15612ee7576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561301a576000612f7f878381518110612f0a57612f0a614898565b6020026020010151878481518110612f2457612f24614898565b6020026020010151878581518110612f3e57612f3e614898565b6020026020010151878681518110612f5857612f58614898565b6020026020010151878781518110612f7257612f72614898565b6020026020010151613849565b90506000816006811115612f9557612f95614a41565b1480612fb257506001816006811115612fb057612fb0614a41565b145b1561300957868281518110612fc957612fc9614898565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b50613013816148f6565b9050612eea565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260085461ffff7e01000000000000000000000000000000000000000000000000000000000000909104811690841611156130e7576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006130f385846105ad565b9050600061311b846040015185606001518469ffffffffffffffffffff16876080015161351c565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa1580156131bd573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526132039190810190615085565b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff90911660248201529192506000919084169063674603d090604401606060405180830381865afa15801561328e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132b29190615154565b50604084015184519193506bffffffffffffffffffffffff871692506132d79161492e565b6bffffffffffffffffffffffff16101561331d576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061339c3089602001518a6000015185600161333a91906151a6565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b905060405180610160016040528089608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001896020015173ffffffffffffffffffffffffffffffffffffffff168152602001896000015167ffffffffffffffff168152602001896040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001600860000160109054906101000a900463ffffffff1663ffffffff164261345d9190614e56565b64ffffffffff168152602080820184905269ffffffffffffffffffff891660408084019190915260085463ffffffff680100000000000000008204811660608601526c010000000000000000000000009091041660809093019290925290519198506134cb918991016143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555093979650505050505050565b60008061352761101a565b905060008113613566576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b600854600090879061359c9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c77565b6135a69190614c77565b63ffffffff1690506000612710600860010154886135c49190614c31565b6135ce91906151c7565b6135d89088614e56565b9050600083836135f084670de0b6b3a7640000614c31565b6135fa9190614c31565b61360491906151c7565b905060006136236bffffffffffffffffffffffff808916908a16614e56565b905061363b816b033b2e3c9fd0803ce80000006149c4565b821115613674576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61367e8183614e56565b9a9950505050505050505050565b6000613696610d82565b5111156136a5576136a5612820565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136cd999897969594939291906151db565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036137d3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bf6565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906138609190615285565b600088815260076020526040902054909150613880576002915050611d08565b8060405160200161389191906143c6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526007909352912054146138e3576006915050611d08565b60006138ed61101a565b90506000811361392c576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bf6565b6000816139413a670de0b6b3a7640000614c31565b61394b91906151c7565b905060008361014001518461012001516139659190615358565b6139769064ffffffffff1683614c31565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139d79190614d55565b338c6040518763ffffffff1660e01b81526004016139fa96959493929190615376565b60408051808303816000875af1158015613a18573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3c91906153f2565b90925090506000826006811115613a5557613a55614a41565b1480613a7257506001826006811115613a7057613a70614a41565b145b15613b2d5760008c815260076020526040812055613a908184614d55565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100880151600c805469ffffffffffffffffffff90921693909291613afe91859116614d55565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509a9950505050505050505050565b508054613b48906145bb565b6000825580601f10613b58575050565b601f01602090049060005260206000209081019061067a9190613b95565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613baa5760008155600101613b96565b5090565b60008083601f840112613bc057600080fd5b50813567ffffffffffffffff811115613bd857600080fd5b602083019150836020828501011115613bf057600080fd5b9250929050565b60008060208385031215613c0a57600080fd5b823567ffffffffffffffff811115613c2157600080fd5b613c2d85828601613bae565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b60405290565b60405160c0810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b604051610160810167ffffffffffffffff81118282101715613c8b57613c8b613c39565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d1f57613d1f613c39565b604052919050565b600082601f830112613d3857600080fd5b813567ffffffffffffffff811115613d5257613d52613c39565b613d8360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613cd8565b818152846020838601011115613d9857600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067a57600080fd5b8035610f9d81613db5565b73ffffffffffffffffffffffffffffffffffffffff8116811461067a57600080fd5b63ffffffff8116811461067a57600080fd5b6bffffffffffffffffffffffff8116811461067a57600080fd5b60008082840360c0811215613e3857600080fd5b833567ffffffffffffffff811115613e4f57600080fd5b613e5b86828701613d27565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613e8e57600080fd5b50613e97613c68565b6020840135613ea581613db5565b81526040840135613eb581613dd6565b60208201526060840135613ec881613df8565b60408201526080840135606082015260a0840135613ee581613e0a565b6080820152919491935090915050565b6000815180845260005b81811015613f1b57602081850181015186830182015201613eff565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613f6c6020830184613ef5565b9392505050565b600060208284031215613f8557600080fd5b8135613f6c81613dd6565b600081518084526020808501945080840160005b83811015613fd657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613fa4565b509495945050505050565b604081526000613ff46040830185613f90565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614062577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614050838351613ef5565b94860194925090850190600101614016565b50909998505050505050505050565b6000806040838503121561408457600080fd5b823561408f81613dd6565b9150602083013561409f81613e0a565b809150509250929050565b6000806000604084860312156140bf57600080fd5b83356140ca81613dd6565b9250602084013567ffffffffffffffff8111156140e657600080fd5b6140f286828701613bae565b9497909650939450505050565b602081526000613f6c6020830184613f90565b60006020828403121561412457600080fd5b5035919050565b60006020828403121561413d57600080fd5b813567ffffffffffffffff81111561415457600080fd5b61416084828501613d27565b949350505050565b60008083601f84011261417a57600080fd5b50813567ffffffffffffffff81111561419257600080fd5b6020830191508360208260051b8501011115613bf057600080fd5b60008060008060008060008060e0898b0312156141c957600080fd5b606089018a8111156141da57600080fd5b8998503567ffffffffffffffff808211156141f457600080fd5b6142008c838d01613bae565b909950975060808b013591508082111561421957600080fd5b6142258c838d01614168565b909750955060a08b013591508082111561423e57600080fd5b5061424b8b828c01614168565b999c989b50969995989497949560c00135949350505050565b60006020828403121561427657600080fd5b813567ffffffffffffffff81111561428d57600080fd5b82016101008185031215613f6c57600080fd5b80516bffffffffffffffffffffffff16825260208101516142d9602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614301604084018273ffffffffffffffffffffffffffffffffffffffff169052565b50606081015161431d606084018267ffffffffffffffff169052565b506080810151614335608084018263ffffffff169052565b5060a081015161435560a08401826bffffffffffffffffffffffff169052565b5060c081015161436e60c084018264ffffffffff169052565b5060e081015160e0830152610100808201516143978285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d7c565b61016081016105d582846142a0565b6000806000806000608086880312156143ed57600080fd5b85356143f881613db5565b9450602086013567ffffffffffffffff81111561441457600080fd5b61442088828901613bae565b909550935050604086013561443481613df8565b949793965091946060013592915050565b600067ffffffffffffffff82111561445f5761445f613c39565b5060051b60200190565b600082601f83011261447a57600080fd5b8135602061448f61448a83614445565b613cd8565b82815260059290921b840181019181810190868411156144ae57600080fd5b8286015b848110156144d25780356144c581613dd6565b83529183019183016144b2565b509695505050505050565b803560ff81168114610f9d57600080fd5b60008060008060008060c0878903121561450757600080fd5b863567ffffffffffffffff8082111561451f57600080fd5b61452b8a838b01614469565b9750602089013591508082111561454157600080fd5b61454d8a838b01614469565b965061455b60408a016144dd565b9550606089013591508082111561457157600080fd5b61457d8a838b01613d27565b945061458b60808a01613dcb565b935060a08901359150808211156145a157600080fd5b506145ae89828a01613d27565b9150509295509295509295565b600181811c908216806145cf57607f821691505b602082108103614608577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105a857600081815260208120601f850160051c810160208610156146355750805b601f850160051c820191505b8181101561465457828155600101614641565b505050505050565b67ffffffffffffffff83111561467457614674613c39565b6146888361468283546145bb565b8361460e565b6000601f8411600181146146da57600085156146a45750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614770565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156147295786850135825560209485019460019092019101614709565b5086821015614764577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461067a57600080fd5b8051610f9d81613e0a565b8051610f9d81613df8565b600080600080608085870312156147b357600080fd5b84516147be81614777565b809450506020808601516147d181613e0a565b60408701519094507fffffffff000000000000000000000000000000000000000000000000000000008116811461480757600080fd5b606087015190935067ffffffffffffffff81111561482457600080fd5b8601601f8101881361483557600080fd5b805161484361448a82614445565b81815260059190911b8201830190838101908a83111561486257600080fd5b928401925b8284101561488957835161487a81613df8565b82529284019290840190614867565b979a9699509497505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614927576149276148c7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614953576149536148c7565b5092915050565b805169ffffffffffffffffffff81168114610f9d57600080fd5b600080600080600060a0868803121561498c57600080fd5b6149958661495a565b94506020860151935060408601519250606086015191506149b86080870161495a565b90509295509295909350565b818103818111156105d5576105d56148c7565b60ff81811683821601908111156105d5576105d56148c7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a3257614a326149f0565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614ac957600080fd5b83018035915067ffffffffffffffff821115614ae457600080fd5b602001915036819003821315613bf057600080fd5b600060208284031215614b0b57600080fd5b8135613f6c81613db5565b600060208284031215614b2857600080fd5b8135613f6c81613df8565b600060208284031215614b4557600080fd5b8135613f6c81613e0a565b600060208284031215614b6257600080fd5b8135613f6c81614777565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c0a60c085018763ffffffff169052565b818482030160e0850152614c2082820186613ef5565b9d9c50505050505050505050505050565b80820281158282048414176105d5576105d56148c7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115614953576149536148c7565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cc48184018a613f90565b90508281036080840152614cd88189613f90565b905060ff871660a084015282810360c0840152614cf58187613ef5565b905067ffffffffffffffff851660e0840152828103610100840152614d1a8185613ef5565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614d4957614d496149f0565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115614953576149536148c7565b6bffffffffffffffffffffffff818116838216028082169190828114614da257614da26148c7565b505092915050565b60008060008060008060008060006101208a8c031215614dc957600080fd5b8951614dd481613df8565b60208b0151909950614de581613df8565b60408b0151909850614df681613df8565b60608b0151909750614e0781613df8565b60808b0151909650614e1881613df8565b9450614e2660a08b0161495a565b935060c08a0151614e3681614777565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105d5576105d56148c7565b600082601f830112614e7a57600080fd5b81356020614e8a61448a83614445565b82815260059290921b84018101918181019086841115614ea957600080fd5b8286015b848110156144d25780358352918301918301614ead565b600082601f830112614ed557600080fd5b81356020614ee561448a83614445565b82815260059290921b84018101918181019086841115614f0457600080fd5b8286015b848110156144d257803567ffffffffffffffff811115614f285760008081fd5b614f368986838b0101613d27565b845250918301918301614f08565b600080600080600060a08688031215614f5c57600080fd5b853567ffffffffffffffff80821115614f7457600080fd5b614f8089838a01614e69565b96506020880135915080821115614f9657600080fd5b614fa289838a01614ec4565b95506040880135915080821115614fb857600080fd5b614fc489838a01614ec4565b94506060880135915080821115614fda57600080fd5b614fe689838a01614ec4565b93506080880135915080821115614ffc57600080fd5b5061500988828901614ec4565b9150509295509295909350565b8051610f9d81613dd6565b600082601f83011261503257600080fd5b8151602061504261448a83614445565b82815260059290921b8401810191818101908684111561506157600080fd5b8286015b848110156144d257805161507881613dd6565b8352918301918301615065565b60006020828403121561509757600080fd5b815167ffffffffffffffff808211156150af57600080fd5b9083019060c082860312156150c357600080fd5b6150cb613c91565b82516150d681613e0a565b815260208301516150e681613dd6565b602082015260408301516150f981613e0a565b604082015261510a60608401615016565b606082015260808301518281111561512157600080fd5b61512d87828601615021565b60808301525060a083015160a082015280935050505092915050565b8051610f9d81613db5565b60008060006060848603121561516957600080fd5b8351801515811461517957600080fd5b602085015190935061518a81613db5565b604085015190925061519b81613db5565b809150509250925092565b67ffffffffffffffff818116838216019080821115614953576149536148c7565b6000826151d6576151d66149f0565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526152228285018b613f90565b91508382036080850152615236828a613f90565b915060ff881660a085015283820360c08501526152538288613ef5565b90861660e08501528381036101008501529050614d1a8185613ef5565b805164ffffffffff81168114610f9d57600080fd5b6000610160828403121561529857600080fd5b6152a0613cb4565b6152a983614787565b81526152b760208401615016565b60208201526152c860408401615016565b60408201526152d960608401615149565b60608201526152ea60808401614792565b60808201526152fb60a08401614787565b60a082015261530c60c08401615270565b60c082015260e083015160e082015261010061532981850161495a565b9082015261012061533b848201615270565b9082015261014061534d848201615270565b908201529392505050565b64ffffffffff818116838216019080821115614953576149536148c7565b600061020080835261538a8184018a613ef5565b9050828103602084015261539e8189613ef5565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153e7905060a08301846142a0565b979650505050505050565b6000806040838503121561540557600080fd5b82516007811061541457600080fd5b602084015190925061409f81613e0a56fea164736f6c6343000813000a", + Bin: "0x60c06040523480156200001157600080fd5b50604051620059e7380380620059e7833981016040819052620000349162000458565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b03909216919091179055506200062a9350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000219919062000568565b9850985098509850985098509850985098506000811362000251576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260088054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f9062000411908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043d57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046e57600080fd5b620004798462000425565b602085810151919450906001600160401b03808211156200049957600080fd5b818701915087601f830112620004ae57600080fd5b815181811115620004c357620004c362000442565b604051601f8201601f19908116603f01168101908382118183101715620004ee57620004ee62000442565b816040528281528a868487010111156200050757600080fd5b600093505b828410156200052b57848401860151818501870152928501926200050c565b60008684830101528097505050505050506200054a6040850162000425565b90509250925092565b805163ffffffff811681146200043d57600080fd5b60008060008060008060008060006101208a8c0312156200058857600080fd5b620005938a62000553565b9850620005a360208b0162000553565b9750620005b360408b0162000553565b9650620005c360608b0162000553565b9550620005d360808b0162000553565b60a08b01519095506001600160501b0381168114620005f157600080fd5b60c08b015190945061ffff811681146200060a57600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a051615366620006816000396000818161068601528181610abd01528181610ee001528181610fbe0152818161183901528181611ad3015281816130aa01526139080152600061120a01526153666000f3fe608060405234801561001057600080fd5b50600436106101a35760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610517578063d328a91e1461052a578063e3d0e71214610532578063f2fde38b1461054557600080fd5b8063b1dc65a4146103e6578063bdd7e880146103f9578063c3f909d41461041957600080fd5b80638da5cb5b116100c85780638da5cb5b14610388578063af1296d3146103b0578063afcb95d7146103c657600080fd5b806381ff7048146102e557806385b214cf146103525780638cc6acce1461037557600080fd5b806366316d8d11610150578063807560311161012a57806380756031146102b557806381411834146102c857806381f1b938146102dd57600080fd5b806366316d8d1461028757806379ba50971461029a5780637f15e166146102a257600080fd5b806326ceabac1161018157806326ceabac146102395780632a905ccc1461024c578063533989871461027157600080fd5b8063083a5466146101a85780630e7ada39146101bd578063181f5a77146101f0575b600080fd5b6101bb6101b6366004613b82565b610558565b005b6101d06101cb366004613d8c565b6105ad565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b61022c6040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101e79190613ec1565b6101bb610247366004613edb565b6105db565b610254610681565b6040516bffffffffffffffffffffffff90911681526020016101e7565b61027961073f565b6040516101e7929190613f49565b6101bb610295366004613fd9565b6109c3565b6101bb610b7d565b6101bb6102b0366004613b82565b610c7f565b6101bb6102c3366004614012565b610ccf565b6102d0610d86565b6040516101e79190614067565b61022c610df5565b61032f60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101e7565b61036561036036600461407a565b610ec6565b60405190151581526020016101e7565b6101bb610383366004614093565b610fa6565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101e7565b6103b861101e565b6040519081526020016101e7565b6040805160018152600060208201819052918101919091526060016101e7565b6101bb6103f4366004614115565b611111565b61040c6104073660046141cc565b6117c8565b6040516101e7919061432e565b600854600954600a54600c546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101e7565b61025461052536600461433d565b611acf565b61022c611c9b565b6101bb610540366004614456565b611cf2565b6101bb610553366004613edb565b61271e565b61056061272f565b600081900361059b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105a88284836145c4565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061061957503373ffffffffffffffffffffffffffffffffffffffff821614155b15610650576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e6020526040812061067e91613ac7565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106ef573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526107359190810190614705565b5090949350505050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107a757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161077c575b505050505090506000815167ffffffffffffffff8111156107ca576107ca613bc4565b6040519080825280602002602001820160405280156107fd57816020015b60608152602001906001900390816107e85790505b50905060005b82518110156109b957600e600084838151811061082257610822614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086f90614523565b90506000036108aa576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e60008483815181106108c0576108c0614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461090d90614523565b80601f016020809104026020016040519081016040528092919081815260200182805461093990614523565b80156109865780601f1061095b57610100808354040283529160200191610986565b820191906000526020600020905b81548152906001019060200180831161096957829003601f168201915b505050505082828151811061099d5761099d614800565b6020026020010181905250806109b29061485e565b9050610803565b5090939092509050565b6109cb6127b2565b806bffffffffffffffffffffffff16600003610a015750336000908152600b60205260409020546bffffffffffffffffffffffff165b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a5b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a889084906bffffffffffffffffffffffff16614896565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610adf7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b6057600080fd5b505af1158015610b74573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610c03576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c8761272f565b6000819003610cc2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105a88284836145c4565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d1a5750610cf933612943565b8015610d1a57503373ffffffffffffffffffffffffffffffffffffffff8416145b610d50576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610d808284836145c4565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610deb57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dc0575b5050505050905090565b6060600f8054610e0490614523565b9050600003610e3f576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610e4c90614523565b80601f0160208091040260200160405190810160405280929190818152602001828054610e7890614523565b8015610deb5780601f10610e9a57610100808354040283529160200191610deb565b820191906000526020600020905b815481529060010190602001808311610ea857509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f37576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260076020526040902054610f5257506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610f959084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611015576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61067e81612a2c565b600854600c54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110dc91906148dc565b509350509250508280156110fe57506110f5814261492c565b8463ffffffff16105b1561110957600a5491505b509392505050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146111f8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610bfa565b6112068b8b8b8b8b8b612d35565b60007f00000000000000000000000000000000000000000000000000000000000000001561126357600282602001518360400151611244919061493f565b61124e9190614987565b61125990600161493f565b60ff169050611279565b602082015161127390600161493f565b60ff1690505b8881146112e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610bfa565b88871461134b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610bfa565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561138e5761138e6149a9565b600281111561139f5761139f6149a9565b90525090506002816020015160028111156113bc576113bc6149a9565b14801561140357506006816000015160ff16815481106113de576113de614800565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611469576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610bfa565b5050505050611476613b01565b6000808a8a6040516114899291906149d8565b6040519081900381206114a0918e906020016149e8565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117aa57600060018489846020811061150957611509614800565b61151691901a601b61493f565b8e8e8681811061152857611528614800565b905060200201358d8d8781811061154157611541614800565b905060200201356040516000815260200160405260405161157e949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115a0573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff80821685529296509294508401916101009004166002811115611620576116206149a9565b6002811115611631576116316149a9565b905250925060018360200151600281111561164e5761164e6149a9565b146116b5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610bfa565b8251600090879060ff16601f81106116cf576116cf614800565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611751576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610bfa565b8086846000015160ff16601f811061176b5761176b614800565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261179660018661493f565b945050806117a39061485e565b90506114ea565b5050506117bb833383858e8e612de3565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611890576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61189d60408301836149fc565b90506000036118d7576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a001604052808460600160208101906118f79190614a61565b67ffffffffffffffff16815260209081019061191590860186613edb565b73ffffffffffffffffffffffffffffffffffffffff16815260200161194060e0860160c08701614a7e565b63ffffffff1681523a6020820152604001611962610100860160e08701614a9b565b6bffffffffffffffffffffffff16905290506119cf61198460408501856149fc565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506119c99250505060a0860160808701614ab8565b83612fb1565b91506119de6020840184613edb565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611a2e9190614a61565b611a3e6040890160208a01613edb565b611a4b60408a018a6149fc565b611a5b60a08c0160808d01614ab8565b60a08c0135611a7060e08e0160c08f01614a7e565b8c604051602001611a81919061432e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611ac1999897969594939291614ad5565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611b6f57600080fd5b505afa158015611b83573d6000803e3d6000fd5b50505050620f4240821115611bc4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611bce610681565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611c7288888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105ad915050565b69ffffffffffffffffffff169050611c8c868683866134a7565b93505050505b95945050505050565b6060600d8054611caa90614523565b9050600003611ce5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610e4c90614523565b855185518560ff16601f831115611d65576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610bfa565b80600003611dcf576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610bfa565b818314611e5d576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610bfa565b611e68816003614b99565b8311611ed0576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610bfa565b611ed861272f565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f1f9088613617565b600554156120d457600554600090611f399060019061492c565b9050600060058281548110611f5057611f50614800565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f8a57611f8a614800565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061200a5761200a614bb0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061207357612073614bb0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f1f915050565b60005b81515181101561253b57600060046000846000015184815181106120fd576120fd614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff166002811115612147576121476149a9565b146121ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610bfa565b6040805180820190915260ff821681526001602082015282518051600491600091859081106121df576121df614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001617610100836002811115612280576122806149a9565b0217905550600091506122909050565b60046000846020015184815181106122aa576122aa614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122f4576122f46149a9565b1461235b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610bfa565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061238e5761238e614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561242f5761242f6149a9565b02179055505082518051600592508390811061244d5761244d614800565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124c9576124c9614800565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125338161485e565b9150506120d7565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff43811682029290921780855592048116929182916014916125f391849174010000000000000000000000000000000000000000900416614bdf565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126524630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613634565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612709988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614bfc565b60405180910390a15050505050505050505050565b61272661272f565b61067e816136df565b60005473ffffffffffffffffffffffffffffffffffffffff1633146127b0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bfa565b565b60006127bc610d86565b905080516000036127f9576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612818916bffffffffffffffffffffffff16614c92565b905060005b82518110156128e45781600b600085848151811061283d5761283d614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166128a59190614cbd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806128dd9061485e565b905061281d565b5081516128f19082614ce2565b600c80546000906129119084906bffffffffffffffffffffffff16614896565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b60008060068054806020026020016040519081016040528092919081815260200182805480156129a957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161297e575b5050505050905060005b8151811015612a22578373ffffffffffffffffffffffffffffffffffffffff168282815181106129e5576129e5614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a12575060019392505050565b612a1b8161485e565b90506129b3565b5060009392505050565b600080600080600080600080600089806020019051810190612a4e9190614d12565b98509850985098509850985098509850985060008113612a9d576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bfa565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600880547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d21908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b6000612d42826020614b99565b612d4d856020614b99565b612d5988610144614dbe565b612d639190614dbe565b612d6d9190614dbe565b612d78906000614dbe565b9050368114610b74576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610bfa565b606080808080612df586880188614eac565b8451949950929750909550935091501580612e1257508351855114155b80612e1f57508251855114155b80612e2c57508151855114155b80612e3957508051855114155b15612e70576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8551811015612fa3576000612f08878381518110612e9357612e93614800565b6020026020010151878481518110612ead57612ead614800565b6020026020010151878581518110612ec757612ec7614800565b6020026020010151878681518110612ee157612ee1614800565b6020026020010151878781518110612efb57612efb614800565b60200260200101516137d4565b90506000816006811115612f1e57612f1e6149a9565b1480612f3b57506001816006811115612f3957612f396149a9565b145b15612f9257868281518110612f5257612f52614800565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b50612f9c8161485e565b9050612e73565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260085461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115613070576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061307c85846105ad565b905060006130a4846040015185606001518469ffffffffffffffffffff1687608001516134a7565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015613148573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261318e9190810190614f89565b50505060208a01518a516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff9091166024820152939550909350600092908616915063674603d090604401606060405180830381865afa158015613220573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132449190615088565b509150506bffffffffffffffffffffffff85166132618385614896565b6bffffffffffffffffffffffff1610156132a7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613326308a602001518b600001518560016132c491906150da565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001876bffffffffffffffffffffffff168152602001600860000160109054906101000a900463ffffffff1663ffffffff16426133e79190614dbe565b64ffffffffff168152602080820184905269ffffffffffffffffffff8a1660408084019190915260085463ffffffff680100000000000000008204811660608601526c01000000000000000000000000909104166080909301929092529051919950613455918a910161432e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815281516020928301206000938452600790925290912055509498975050505050505050565b6000806134b261101e565b9050600081136134f1576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bfa565b60085460009087906135279063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614bdf565b6135319190614bdf565b63ffffffff16905060006127106008600101548861354f9190614b99565b61355991906150fb565b6135639088614dbe565b90506000838361357b84670de0b6b3a7640000614b99565b6135859190614b99565b61358f91906150fb565b905060006135ae6bffffffffffffffffffffffff808916908a16614dbe565b90506135c6816b033b2e3c9fd0803ce800000061492c565b8211156135ff576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6136098183614dbe565b9a9950505050505050505050565b6000613621610d86565b511115613630576136306127b2565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136589998979695949392919061510f565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361375e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bfa565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906137eb91906151b9565b60008881526007602052604090205490915061380b576002915050611c92565b8060405160200161381c919061432e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a815260079093529120541461386e576006915050611c92565b600061387861101e565b9050600081136138b7576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bfa565b6000816138cc3a670de0b6b3a7640000614b99565b6138d691906150fb565b905060008361014001518461012001516138f0919061528c565b6139019064ffffffffff1683614b99565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139629190614cbd565b338c6040518763ffffffff1660e01b8152600401613985969594939291906152aa565b60408051808303816000875af11580156139a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139c79190615326565b909250905060008260068111156139e0576139e06149a9565b14806139fd575060018260068111156139fb576139fb6149a9565b145b15613ab85760008c815260076020526040812055613a1b8184614cbd565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100880151600c805469ffffffffffffffffffff90921693909291613a8991859116614cbd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509a9950505050505050505050565b508054613ad390614523565b6000825580601f10613ae3575050565b601f01602090049060005260206000209081019061067e9190613b20565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613b355760008155600101613b21565b5090565b60008083601f840112613b4b57600080fd5b50813567ffffffffffffffff811115613b6357600080fd5b602083019150836020828501011115613b7b57600080fd5b9250929050565b60008060208385031215613b9557600080fd5b823567ffffffffffffffff811115613bac57600080fd5b613bb885828601613b39565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613c1657613c16613bc4565b60405290565b604051610160810167ffffffffffffffff81118282101715613c1657613c16613bc4565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613c8757613c87613bc4565b604052919050565b600082601f830112613ca057600080fd5b813567ffffffffffffffff811115613cba57613cba613bc4565b613ceb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613c40565b818152846020838601011115613d0057600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067e57600080fd5b8035610fa181613d1d565b73ffffffffffffffffffffffffffffffffffffffff8116811461067e57600080fd5b63ffffffff8116811461067e57600080fd5b6bffffffffffffffffffffffff8116811461067e57600080fd5b60008082840360c0811215613da057600080fd5b833567ffffffffffffffff811115613db757600080fd5b613dc386828701613c8f565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613df657600080fd5b50613dff613bf3565b6020840135613e0d81613d1d565b81526040840135613e1d81613d3e565b60208201526060840135613e3081613d60565b60408201526080840135606082015260a0840135613e4d81613d72565b6080820152919491935090915050565b6000815180845260005b81811015613e8357602081850181015186830182015201613e67565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613ed46020830184613e5d565b9392505050565b600060208284031215613eed57600080fd5b8135613ed481613d3e565b600081518084526020808501945080840160005b83811015613f3e57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613f0c565b509495945050505050565b604081526000613f5c6040830185613ef8565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613fca577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613fb8838351613e5d565b94860194925090850190600101613f7e565b50909998505050505050505050565b60008060408385031215613fec57600080fd5b8235613ff781613d3e565b9150602083013561400781613d72565b809150509250929050565b60008060006040848603121561402757600080fd5b833561403281613d3e565b9250602084013567ffffffffffffffff81111561404e57600080fd5b61405a86828701613b39565b9497909650939450505050565b602081526000613ed46020830184613ef8565b60006020828403121561408c57600080fd5b5035919050565b6000602082840312156140a557600080fd5b813567ffffffffffffffff8111156140bc57600080fd5b6140c884828501613c8f565b949350505050565b60008083601f8401126140e257600080fd5b50813567ffffffffffffffff8111156140fa57600080fd5b6020830191508360208260051b8501011115613b7b57600080fd5b60008060008060008060008060e0898b03121561413157600080fd5b606089018a81111561414257600080fd5b8998503567ffffffffffffffff8082111561415c57600080fd5b6141688c838d01613b39565b909950975060808b013591508082111561418157600080fd5b61418d8c838d016140d0565b909750955060a08b01359150808211156141a657600080fd5b506141b38b828c016140d0565b999c989b50969995989497949560c00135949350505050565b6000602082840312156141de57600080fd5b813567ffffffffffffffff8111156141f557600080fd5b82016101008185031215613ed457600080fd5b80516bffffffffffffffffffffffff1682526020810151614241602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614269604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614285606084018267ffffffffffffffff169052565b50608081015161429d608084018263ffffffff169052565b5060a08101516142bd60a08401826bffffffffffffffffffffffff169052565b5060c08101516142d660c084018264ffffffffff169052565b5060e081015160e0830152610100808201516142ff8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d80565b61016081016105d58284614208565b60008060008060006080868803121561435557600080fd5b853561436081613d1d565b9450602086013567ffffffffffffffff81111561437c57600080fd5b61438888828901613b39565b909550935050604086013561439c81613d60565b949793965091946060013592915050565b600067ffffffffffffffff8211156143c7576143c7613bc4565b5060051b60200190565b600082601f8301126143e257600080fd5b813560206143f76143f2836143ad565b613c40565b82815260059290921b8401810191818101908684111561441657600080fd5b8286015b8481101561443a57803561442d81613d3e565b835291830191830161441a565b509695505050505050565b803560ff81168114610fa157600080fd5b60008060008060008060c0878903121561446f57600080fd5b863567ffffffffffffffff8082111561448757600080fd5b6144938a838b016143d1565b975060208901359150808211156144a957600080fd5b6144b58a838b016143d1565b96506144c360408a01614445565b955060608901359150808211156144d957600080fd5b6144e58a838b01613c8f565b94506144f360808a01613d33565b935060a089013591508082111561450957600080fd5b5061451689828a01613c8f565b9150509295509295509295565b600181811c9082168061453757607f821691505b602082108103614570577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105a857600081815260208120601f850160051c8101602086101561459d5750805b601f850160051c820191505b818110156145bc578281556001016145a9565b505050505050565b67ffffffffffffffff8311156145dc576145dc613bc4565b6145f0836145ea8354614523565b83614576565b6000601f841160018114614642576000851561460c5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556146d8565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156146915786850135825560209485019460019092019101614671565b50868210156146cc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461067e57600080fd5b8051610fa181613d72565b8051610fa181613d60565b6000806000806080858703121561471b57600080fd5b8451614726816146df565b8094505060208086015161473981613d72565b60408701519094507fffffffff000000000000000000000000000000000000000000000000000000008116811461476f57600080fd5b606087015190935067ffffffffffffffff81111561478c57600080fd5b8601601f8101881361479d57600080fd5b80516147ab6143f2826143ad565b81815260059190911b8201830190838101908a8311156147ca57600080fd5b928401925b828410156147f15783516147e281613d60565b825292840192908401906147cf565b979a9699509497505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361488f5761488f61482f565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156148bb576148bb61482f565b5092915050565b805169ffffffffffffffffffff81168114610fa157600080fd5b600080600080600060a086880312156148f457600080fd5b6148fd866148c2565b9450602086015193506040860151925060608601519150614920608087016148c2565b90509295509295909350565b818103818111156105d5576105d561482f565b60ff81811683821601908111156105d5576105d561482f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff83168061499a5761499a614958565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614a3157600080fd5b83018035915067ffffffffffffffff821115614a4c57600080fd5b602001915036819003821315613b7b57600080fd5b600060208284031215614a7357600080fd5b8135613ed481613d1d565b600060208284031215614a9057600080fd5b8135613ed481613d60565b600060208284031215614aad57600080fd5b8135613ed481613d72565b600060208284031215614aca57600080fd5b8135613ed4816146df565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614b7260c085018763ffffffff169052565b818482030160e0850152614b8882820186613e5d565b9d9c50505050505050505050505050565b80820281158282048414176105d5576105d561482f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156148bb576148bb61482f565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614c2c8184018a613ef8565b90508281036080840152614c408189613ef8565b905060ff871660a084015282810360c0840152614c5d8187613e5d565b905067ffffffffffffffff851660e0840152828103610100840152614c828185613e5d565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614cb157614cb1614958565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156148bb576148bb61482f565b6bffffffffffffffffffffffff818116838216028082169190828114614d0a57614d0a61482f565b505092915050565b60008060008060008060008060006101208a8c031215614d3157600080fd5b8951614d3c81613d60565b60208b0151909950614d4d81613d60565b60408b0151909850614d5e81613d60565b60608b0151909750614d6f81613d60565b60808b0151909650614d8081613d60565b9450614d8e60a08b016148c2565b935060c08a0151614d9e816146df565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105d5576105d561482f565b600082601f830112614de257600080fd5b81356020614df26143f2836143ad565b82815260059290921b84018101918181019086841115614e1157600080fd5b8286015b8481101561443a5780358352918301918301614e15565b600082601f830112614e3d57600080fd5b81356020614e4d6143f2836143ad565b82815260059290921b84018101918181019086841115614e6c57600080fd5b8286015b8481101561443a57803567ffffffffffffffff811115614e905760008081fd5b614e9e8986838b0101613c8f565b845250918301918301614e70565b600080600080600060a08688031215614ec457600080fd5b853567ffffffffffffffff80821115614edc57600080fd5b614ee889838a01614dd1565b96506020880135915080821115614efe57600080fd5b614f0a89838a01614e2c565b95506040880135915080821115614f2057600080fd5b614f2c89838a01614e2c565b94506060880135915080821115614f4257600080fd5b614f4e89838a01614e2c565b93506080880135915080821115614f6457600080fd5b50614f7188828901614e2c565b9150509295509295909350565b8051610fa181613d3e565b60008060008060008060c08789031215614fa257600080fd5b8651614fad81613d72565b80965050602080880151614fc081613d3e565b6040890151909650614fd181613d72565b6060890151909550614fe281613d3e565b608089015190945067ffffffffffffffff811115614fff57600080fd5b8801601f81018a1361501057600080fd5b805161501e6143f2826143ad565b81815260059190911b8201830190838101908c83111561503d57600080fd5b928401925b8284101561506457835161505581613d3e565b82529284019290840190615042565b809650505050505060a087015190509295509295509295565b8051610fa181613d1d565b60008060006060848603121561509d57600080fd5b835180151581146150ad57600080fd5b60208501519093506150be81613d1d565b60408501519092506150cf81613d1d565b809150509250925092565b67ffffffffffffffff8181168382160190808211156148bb576148bb61482f565b60008261510a5761510a614958565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151568285018b613ef8565b9150838203608085015261516a828a613ef8565b915060ff881660a085015283820360c08501526151878288613e5d565b90861660e08501528381036101008501529050614c828185613e5d565b805164ffffffffff81168114610fa157600080fd5b600061016082840312156151cc57600080fd5b6151d4613c1c565b6151dd836146ef565b81526151eb60208401614f7e565b60208201526151fc60408401614f7e565b604082015261520d6060840161507d565b606082015261521e608084016146fa565b608082015261522f60a084016146ef565b60a082015261524060c084016151a4565b60c082015260e083015160e082015261010061525d8185016148c2565b9082015261012061526f8482016151a4565b908201526101406152818482016151a4565b908201529392505050565b64ffffffffff8181168382160190808211156148bb576148bb61482f565b60006102008083526152be8184018a613e5d565b905082810360208401526152d28189613e5d565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff86166080850152915061531b905060a0830184614208565b979650505050505050565b6000806040838503121561533957600080fd5b82516007811061534857600080fd5b602084015190925061400781613d7256fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index be91cd95d2d..d8fdda01af4 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -44,18 +44,9 @@ type FunctionsResponseCommitment struct { GasOverheadAfterCallback *big.Int } -type IFunctionsSubscriptionsSubscription struct { - Balance *big.Int - Owner common.Address - BlockedBalance *big.Int - RequestedOwner common.Address - Consumers []common.Address - Flags [32]byte -} - var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AlreadyApplied\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConfigData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"callbackGasCostJuels\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"\",\"type\":\"uint32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"isPaused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620066d0380380620066d0833981016040819052620000349162000441565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d9816200016e565b50506008805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e816200021f565b5050600980546001600160a01b0319166001600160a01b03949094169390931790925550620006cd945050505050565b336001600160a01b03821603620001c85760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080600080848060200190518101906200023b91906200053e565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600e80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002cb91600f919086019062000313565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000304939291906200065c565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003b75791602002820160005b838211156200038357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200033d565b8015620003b55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000383565b505b50620003c5929150620003c9565b5090565b5b80821115620003c55760008155600101620003ca565b805161ffff81168114620003f357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004395762000439620003f8565b604052919050565b600080600080608085870312156200045857600080fd5b6200046385620003e0565b9350602062000474818701620003e0565b60408701519094506001600160a01b03811681146200049257600080fd5b60608701519093506001600160401b0380821115620004b057600080fd5b818801915088601f830112620004c557600080fd5b815181811115620004da57620004da620003f8565b620004ee601f8201601f191685016200040e565b915080825289848285010111156200050557600080fd5b60005b818110156200052557838101850151838201860152840162000508565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055557600080fd5b6200056085620003e0565b602086810151919550906001600160601b03811681146200058057600080fd5b60408701519094506001600160e01b0319811681146200059f57600080fd5b60608701519093506001600160401b0380821115620005bd57600080fd5b818801915088601f830112620005d257600080fd5b815181811115620005e757620005e7620003f8565b8060051b9150620005fa8483016200040e565b818152918301840191848101908b8411156200061557600080fd5b938501935b838510156200064c578451925063ffffffff831683146200063b5760008081fd5b82825293850193908501906200061a565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bf57845163ffffffff16835293830193918301916001016200069b565b509098975050505050505050565b608051615fe7620006e96000396000612af60152615fe76000f3fe608060405234801561001057600080fd5b50600436106102ff5760003560e01c806379ba50971161019c578063aab396bd116100ee578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f1461076f578063eb523d6c14610782578063f2fde38b1461079557600080fd5b8063d7ae1d3014610736578063e72f6e3014610749578063e82ad7d41461075c57600080fd5b8063b734c0f4116100c8578063b734c0f4146106ff578063badc3eb614610707578063c3f909d41461071e57600080fd5b8063aab396bd146106bb578063b187bd26146106e1578063b5643858146106ec57600080fd5b80639f87fad711610150578063a47c76961161012a578063a47c769614610675578063a4c0ed3614610695578063a9c9a918146106a857600080fd5b80639f87fad714610639578063a1d4c8281461064c578063a21a23e41461066d57600080fd5b80638456cb59116101815780638456cb59146106065780638da5cb5b1461060e5780638fde53171461063157600080fd5b806379ba5097146105eb57806382359740146105f357600080fd5b8063461d27621161025557806366316d8d116102095780636a2215de116101e35780636a2215de1461058d5780636e3b3323146105c55780637341c10c146105d857600080fd5b806366316d8d146104b857806366419970146104cb578063674603d0146104f857600080fd5b806355fedefa1161023a57806355fedefa146104615780635c975abb1461048e5780635ed6dfba146104a557600080fd5b8063461d27621461043b5780634b8832d31461044e57600080fd5b80631c024539116102b75780633e871e4d116102915780633e871e4d146103ff5780633f4ba83a1461041257806341db4ca31461041a57600080fd5b80631c024539146103d15780631ded3b36146103d9578063385de9ae146103ec57600080fd5b806310fc49c1116102e857806310fc49c11461033957806312b583491461034c578063181f5a771461038857600080fd5b806302bcc5b6146103045780630c5d49cb14610319575b600080fd5b610317610312366004614ac3565b6107a8565b005b610321608481565b60405161ffff90911681526020015b60405180910390f35b610317610347366004614b04565b610807565b6008546a010000000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610330565b6103c46040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103309190614ba1565b610317610931565b6103176103e7366004614bb4565b610a93565b6103176103fa366004614c29565b610ac4565b61031761040d366004614de2565b610b8d565b610317610e83565b61042d610428366004614eab565b610e95565b604051908152602001610330565b61042d610449366004614eab565b610ef5565b61031761045c366004614f30565b610f01565b61042d61046f366004614ac3565b67ffffffffffffffff166000908152600a602052604090206003015490565b60005460ff165b6040519015158152602001610330565b6103176104b3366004614f83565b610fff565b6103176104c6366004614f83565b6112d4565b60085462010000900467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610330565b610565610506366004614fb1565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600b6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610330565b6105a061059b366004614fdf565b6114fb565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610330565b6103176105d3366004614ff8565b6115ba565b6103176105e6366004614f30565b611890565b610317611a26565b610317610601366004614ac3565b611b48565b610317611c7f565b600054610100900473ffffffffffffffffffffffffffffffffffffffff166105a0565b610317611c8f565b610317610647366004614f30565b611d81565b61065f61065a366004615211565b612161565b6040516103309291906152f9565b6104df61254d565b610688610683366004614ac3565b6126e0565b6040516103309190615373565b6103176106a33660046153fb565b612815565b6105a06106b6366004614fdf565b612a44565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09761042d565b60005460ff16610495565b6103176106fa366004615457565b612aaa565b610317612c0b565b61070f612d9f565b60405161033093929190615474565b610726612e7a565b60405161033094939291906154ff565b610317610744366004614f30565b612f45565b610317610757366004615562565b612fa8565b61049561076a366004614ac3565b6131b2565b61031761077d36600461557f565b6131c3565b610317610790366004614fdf565b6132aa565b6103176107a3366004615562565b613466565b6107b0613477565b6107b98161347f565b67ffffffffffffffff81166000908152600a60205260409020546108049082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166134f5565b50565b67ffffffffffffffff82166000908152600a6020526040812060030154600f54911a90811061086c576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600f805460ff8316908110610883576108836155c1565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1663ffffffff168263ffffffff16111561092c57600f805460ff83169081106108d3576108d36155c1565b600091825260209091206008820401546040517f1d70f87a000000000000000000000000000000000000000000000000000000008152600790921660049081026101000a90910463ffffffff1690820152602401610863565b505050565b610939613863565b60008080526006602052604080518082019091527f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f880548290829061097d906155f0565b80601f01602080910402602001604051908101604052809291908181526020018280546109a9906155f0565b80156109f65780601f106109cb576101008083540402835291602001916109f6565b820191906000526020600020905b8154815290600101906020018083116109d957829003601f168201915b5050505050815260200160018201548152505090508060200151431015610a49576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051610a54906138e9565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a889160009190615643565b60405180910390a150565b610a9b613477565b610aa48261347f565b67ffffffffffffffff9091166000908152600a6020526040902060030155565b610acc613863565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600854602090910190610b219061ffff1643615693565b9052600084815260066020526040902081518190610b3f90826156f4565b50602082015181600101559050507fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a838383604051610b809392919061580e565b60405180910390a1505050565b610b95613863565b8151815181141580610ba75750600881115b15610bde576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610d0a576000848281518110610bfd57610bfd6155c1565b602002602001015190506000848381518110610c1b57610c1b6155c1565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c86575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cbd576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cf7576040517f4855c28800000000000000000000000000000000000000000000000000000000815260048101839052602401610863565b505080610d0390615862565b9050610be1565b50600854600090610d1f9061ffff1643615693565b604080516060810182528681526020808201879052918101839052865192935091600391610d51918391890190614903565b506020828101518051610d6a926001850192019061494a565b506040820151816002015590505060005b8451811015610e7c577f72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd858281518110610db757610db76155c1565b602002602001015160026000888581518110610dd557610dd56155c1565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e1e57610e1e6155c1565b602002602001015185604051610e64949392919093845273ffffffffffffffffffffffffffffffffffffffff928316602085015291166040830152606082015260800190565b60405180910390a1610e7581615862565b9050610d7b565b5050505050565b610e8b613863565b610e93613a2f565b565b600080610ea1836114fb565b9050610ee983828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613aac9050565b98975050505050505050565b600080610ea183612a44565b610f09613dfc565b610f1282613e04565b610f1a613eca565b67ffffffffffffffff82166000908152600a602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c010000000000000000000000009092041614610ffb5767ffffffffffffffff82166000818152600a602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b611007613477565b806bffffffffffffffffffffffff1660000361103d5750306000908152600c60205260409020546bffffffffffffffffffffffff165b306000908152600c60205260409020546bffffffffffffffffffffffff80831691161015611097576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600c6020526040812080548392906110c49084906bffffffffffffffffffffffff1661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806008600a8282829054906101000a90046bffffffffffffffffffffffff1661111b919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156111ba573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111de91906158c6565b610ffb576009546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015611251573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061127591906158e8565b6008546040517fa99da3020000000000000000000000000000000000000000000000000000000081526a01000000000000000000009091046bffffffffffffffffffffffff166004820181905260248201839052919250604401610863565b6112dc613dfc565b806bffffffffffffffffffffffff16600003611324576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c60205260409020546bffffffffffffffffffffffff8083169116101561137e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600c6020526040812080548392906113ab9084906bffffffffffffffffffffffff1661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806008600a8282829054906101000a90046bffffffffffffffffffffffff16611402919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156114a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114c591906158c6565b610ffb576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b60035460ff82161015611584576003805460ff8316908110611523576115236155c1565b90600052602060002001548303611574576004805460ff831690811061154b5761154b6155c1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61157d81615901565b90506114ff565b506040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101839052602401610863565b6115c2613dfc565b60005b8181101561092c5760008383838181106115e1576115e16155c1565b905061016002018036038101906115f89190615920565b905060008160e001519050600d60008281526020019081526020016000205482604051602001611628919061593d565b6040516020818303038152906040528051906020012014611675576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8160c0015164ffffffffff164210156116ba576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208201516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8216906385b214cf906024016020604051808303816000875af115801561172c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061175091906158c6565b5060a0830151606084015167ffffffffffffffff166000908152600a6020526040812060010180549091906117949084906bffffffffffffffffffffffff1661589a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600b6020908152828220606087015167ffffffffffffffff9081168452915291902080546001926009916118209185916901000000000000000000900416615a6c565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600d60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061188990615862565b90506115c5565b611898613dfc565b6118a182613e04565b6118a9613eca565b600e5467ffffffffffffffff83166000908152600a602052604090206002015461ffff9091169003611907576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b6020908152604080832067ffffffffffffffff8616845290915290205460ff161561194e575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600b6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600a84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610ff2565b60015473ffffffffffffffffffffffffffffffffffffffff163314611aa7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610863565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611b50613dfc565b611b58613eca565b67ffffffffffffffff81166000908152600a60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611be0576040517f02b543c600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000818152600a602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611c87613863565b610e93613fcf565b611c97613863565b60075464010000000090047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16431015611cf9576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60075460085461ffff620100009092048216911603611d43576040517ea8180600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600754600880546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611d89613dfc565b611d9282613e04565b611d9a613eca565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e42576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e97576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600a6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f1257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611ee7575b50505050509050600060018251611f299190615a8d565b905060005b82518110156120c5578473ffffffffffffffffffffffffffffffffffffffff16838281518110611f6057611f606155c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036120b5576000838381518110611f9757611f976155c1565b6020026020010151905080600a60008967ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018381548110611fdd57611fdd6155c1565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff89168152600a9091526040902060020180548061205757612057615aa0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120c5565b6120be81615862565b9050611f2e565b5073ffffffffffffffffffffffffffffffffffffffff84166000818152600b6020908152604080832067ffffffffffffffff8a168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b910160405180910390a25050505050565b60008061216c613dfc565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146121d5576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600d602052604090205461223a57600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b60405180910390a2612542565b600d60008460e0015181526020019081526020016000205483604051602001612263919061593d565b60405160208183030381529060405280519060200120146122be57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b826101400151836080015163ffffffff166122d99190615b01565b64ffffffffff165a101561232757600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161222d93929190615acf565b600061233c846080015163ffffffff1661402a565b6123469088615b1f565b905060008187866000015161235b9190615b47565b6123659190615b47565b606086015167ffffffffffffffff166000908152600a60205260409020549091506bffffffffffffffffffffffff90811690821611156123ee57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123df93929190615acf565b60405180910390a25050612542565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561245657600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123df93929190615acf565b5050600d60008460e00151815260200190815260200160002060009055600061248e8460e001518a8a876080015188604001516140cc565b805190915061249e5760016124a1565b60005b925060006124d085606001518660a00151876040015188600001518c6124ca886020015161402a565b8d614248565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b83602001518988876000015161251d578e61251f565b8f5b8860400151604051612535959493929190615b6c565b60405180910390a3519150505b965096945050505050565b6000612557613dfc565b61255f613eca565b6008805460029061257f9062010000900467ffffffffffffffff16615bce565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156125f5578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600a825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926126909260028501929091019061494a565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261271a8261347f565b67ffffffffffffffff82166000908152600a6020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156127fb57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116127d0575b505050505081526020016003820154815250509050919050565b61281d613dfc565b60095473ffffffffffffffffffffffffffffffffffffffff16331461286e576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146128a8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006128b682840184614ac3565b67ffffffffffffffff81166000908152600a60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661292f576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600a6020526040812080546bffffffffffffffffffffffff16918691906129668385615b47565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846008600a8282829054906101000a90046bffffffffffffffffffffffff166129bd9190615b47565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f8828784612a249190615693565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff168015612a755792915050565b6040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610863565b612ab2613863565b60085461ffff808316911603612af4576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff161115612b56576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260085461ffff90811680835290841660208301529091820190612b839043615693565b7bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90811690915281516007805460208501516040909501519093166401000000000263ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612c13613863565b600554431015612c4f576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612d7657600060036000018281548110612c7457612c746155c1565b6000918252602080832090910154808352600290915260408220546004805492945073ffffffffffffffffffffffffffffffffffffffff909116929185908110612cc057612cc06155c1565b6000918252602080832091909101548583526002825260409283902080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff92831690811790915583518781529186169282019290925291820181905291507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a150505080612d6f90615862565b9050612c52565b5060036000612d8582826149c4565b612d936001830160006149c4565b60028201600090555050565b60006060806003600201546003600001600360010181805480602002602001604051908101604052809291908181526020018280548015612dff57602002820191906000526020600020905b815481526020019060010190808311612deb575b5050505050915080805480602002602001604051908101604052809291908181526020018280548015612e6857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e3d575b50505050509050925092509250909192565b600e54600f8054604080516020808402820181019092528281526000948594859460609461ffff8416946bffffffffffffffffffffffff62010000860416946e010000000000000000000000000000900460e01b93929091839190830182828015612f3057602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ef35790505b50505050509050935093509350935090919293565b612f4d613dfc565b612f5682613e04565b612f5e613eca565b612f6782614491565b15612f9e576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ffb82826134f5565b612fb0613477565b6009546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561301f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061304391906158e8565b6008549091506a010000000000000000000090046bffffffffffffffffffffffff16818111156130a9576040517fa99da3020000000000000000000000000000000000000000000000000000000081526004810182905260248101839052604401610863565b8181101561092c5760006130bd8284615a8d565b6009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af1158015613138573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061315c91906158c6565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b60006131bd82614491565b92915050565b6131cb613863565b6040805160606020601f850181900402820181018352918101838152909182919085908590819085018382808284376000920191909152505050908252506008546020909101906132209061ffff1643615693565b905260008052600660205280517f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f890819061325b90826156f4565b50602091909101516001909101556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a9061329e906000908590859061580e565b60405180910390a15050565b6132b2613863565b60008181526006602052604080822081518083019092528054829082906132d8906155f0565b80601f0160208091040260200160405190810160405280929190818152602001828054613304906155f0565b80156133515780601f1061332657610100808354040283529160200191613351565b820191906000526020600020905b81548152906001019060200180831161333457829003601f168201915b50505050508152602001600182015481525050905080602001514310156133a4576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6133ad82612a44565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161340191600401614ba1565b600060405180830381600087803b15801561341b57600080fd5b505af115801561342f573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c7935061329e9250859190615643565b61346e613863565b610804816145e0565b610e93613863565b67ffffffffffffffff81166000908152600a60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610804576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600a60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156135d657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116135ab575b505050918352505060039190910154602090910152805190915060005b82608001515181101561369757600b60008460800151838151811061361a5761361a6155c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff000000000000000000000000000000000016905561369081615862565b90506135f3565b5067ffffffffffffffff84166000908152600a6020526040812081815560018101829055906136c960028301826149c4565b60038201600090555050806008600a8282829054906101000a90046bffffffffffffffffffffffff166136fc919061589a565b82546101009290920a6bffffffffffffffffffffffff8181021990931691831602179091556009546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561379b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137bf91906158c6565b6137f5576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd49815910160405180910390a250505050565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610863565b600080600080848060200190518101906139039190615c0b565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600e80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a5094985092965090945090926139e991600f91908601906149e2565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051613a2093929190615d06565b60405180910390a15050505050565b613a376146db565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613ab6613dfc565b613abf8561347f565b613ac93386614747565b613ad38583610807565b604080516101008101825233815267ffffffffffffffff87166000818152600a6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b1660808801529484529190526003015460a084015263ffffffff861660c0840152600e546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e88091613bb39190600401615d5e565b610160604051808303816000875af1158015613bd3573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613bf79190615e49565b9050604051806101600160405280600e60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613d06919061593d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600d90935291205560a0810151613d6090339088906147bb565b60e081015167ffffffffffffffff87166000818152600a60205260409081902054905191928b9290917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613de5916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908d908d908d90615f1c565b60405180910390a460e00151979650505050505050565b610e93614896565b67ffffffffffffffff81166000908152600a60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e7b576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610ffb576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613ef37fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097612a44565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf890613f5690339060248101615f80565b602060405180830381865afa158015613f73573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f9791906158c6565b610e93576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610863565b613fd7614896565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a823390565b60006bffffffffffffffffffffffff8211156140c8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610863565b5090565b60408051606080820183526000808352602083015291810191909152600e546040516000916e010000000000000000000000000000900460e01b9061411990899089908990602401615faf565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b6141cb57600080fd5b5a6113888110156141db57600080fd5b6113888103905087604082048203116141f357600080fd5b60008086516020880160008b8df193505a900391503d6084811115614216575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006142688486615b1f565b90506000816142778886615b47565b6142819190615b47565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600a9091529283208054929750939450849392916142d89185911661589a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846143129190615b47565b336000908152600c60205260408120805490919061433f9084906bffffffffffffffffffffffff16615b47565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600c6020526040812080548b9450909261438691859116615b47565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600a6020526040812060010180548d945090926143da9185911661589a565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600b6020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161445e9185916901000000000000000000900416615a6c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b67ffffffffffffffff81166000908152600a602090815260408083206002018054825181850281018501909352808352849383018282801561450957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116144de575b5050505050905060005b81518110156145d6576000600b6000848481518110614534576145346155c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146145c557506001949350505050565b506145cf81615862565b9050614513565b5060009392505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361465f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610863565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610863565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600b6020908152604080832067ffffffffffffffff8516845290915290205460ff16610ffb576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600a6020526040812060010180548392906147f59084906bffffffffffffffffffffffff16615b47565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600b6020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261486b928492900416615a6c565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610e93576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610863565b82805482825590600052602060002090810192821561493e579160200282015b8281111561493e578251825591602001919060010190614923565b506140c8929150614a88565b82805482825590600052602060002090810192821561493e579160200282015b8281111561493e57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90911617825560209092019160019091019061496a565b50805460008255906000526020600020908101906108049190614a88565b8280548282559060005260206000209060070160089004810192821561493e5791602002820160005b83821115614a4f57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a0b565b8015614a7f5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a4f565b50506140c89291505b5b808211156140c85760008155600101614a89565b67ffffffffffffffff8116811461080457600080fd5b8035614abe81614a9d565b919050565b600060208284031215614ad557600080fd5b8135614ae081614a9d565b9392505050565b63ffffffff8116811461080457600080fd5b8035614abe81614ae7565b60008060408385031215614b1757600080fd5b8235614b2281614a9d565b91506020830135614b3281614ae7565b809150509250929050565b6000815180845260005b81811015614b6357602081850181015186830182015201614b47565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614ae06020830184614b3d565b60008060408385031215614bc757600080fd5b8235614bd281614a9d565b946020939093013593505050565b60008083601f840112614bf257600080fd5b50813567ffffffffffffffff811115614c0a57600080fd5b602083019150836020828501011115614c2257600080fd5b9250929050565b600080600060408486031215614c3e57600080fd5b83359250602084013567ffffffffffffffff811115614c5c57600080fd5b614c6886828701614be0565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614cc857614cc8614c75565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d1557614d15614c75565b604052919050565b600067ffffffffffffffff821115614d3757614d37614c75565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461080457600080fd5b8035614abe81614d41565b600082601f830112614d7f57600080fd5b81356020614d94614d8f83614d1d565b614cce565b82815260059290921b84018101918181019086841115614db357600080fd5b8286015b84811015614dd7578035614dca81614d41565b8352918301918301614db7565b509695505050505050565b60008060408385031215614df557600080fd5b823567ffffffffffffffff80821115614e0d57600080fd5b818501915085601f830112614e2157600080fd5b81356020614e31614d8f83614d1d565b82815260059290921b84018101918181019089841115614e5057600080fd5b948201945b83861015614e6e57853582529482019490820190614e55565b96505086013592505080821115614e8457600080fd5b50614e9185828601614d6e565b9150509250929050565b61ffff8116811461080457600080fd5b60008060008060008060a08789031215614ec457600080fd5b8635614ecf81614a9d565b9550602087013567ffffffffffffffff811115614eeb57600080fd5b614ef789828a01614be0565b9096509450506040870135614f0b81614e9b565b92506060870135614f1b81614ae7565b80925050608087013590509295509295509295565b60008060408385031215614f4357600080fd5b8235614f4e81614a9d565b91506020830135614b3281614d41565b6bffffffffffffffffffffffff8116811461080457600080fd5b8035614abe81614f5e565b60008060408385031215614f9657600080fd5b8235614fa181614d41565b91506020830135614b3281614f5e565b60008060408385031215614fc457600080fd5b8235614fcf81614d41565b91506020830135614b3281614a9d565b600060208284031215614ff157600080fd5b5035919050565b6000806020838503121561500b57600080fd5b823567ffffffffffffffff8082111561502357600080fd5b818501915085601f83011261503757600080fd5b81358181111561504657600080fd5b8660206101608302850101111561505c57600080fd5b60209290920196919550909350505050565b600082601f83011261507f57600080fd5b813567ffffffffffffffff81111561509957615099614c75565b6150ca60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cce565b8181528460208386010111156150df57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461080457600080fd5b8035614abe816150fc565b69ffffffffffffffffffff8116811461080457600080fd5b8035614abe8161511a565b6000610160828403121561515057600080fd5b615158614ca4565b905061516382614f78565b815261517160208301614d63565b602082015261518260408301614d63565b604082015261519360608301614ab3565b60608201526151a460808301614af9565b60808201526151b560a08301614f78565b60a08201526151c660c0830161510f565b60c082015260e082013560e08201526101006151e3818401615132565b908201526101206151f583820161510f565b9082015261014061520783820161510f565b9082015292915050565b600080600080600080610200878903121561522b57600080fd5b863567ffffffffffffffff8082111561524357600080fd5b61524f8a838b0161506e565b9750602089013591508082111561526557600080fd5b5061527289828a0161506e565b955050604087013561528381614f5e565b9350606087013561529381614f5e565b925060808701356152a381614d41565b91506152b28860a0890161513d565b90509295509295509295565b600781106152f5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161530782856152be565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561536857815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615336565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526153e560e0840182615322565b905060a084015160c08401528091505092915050565b6000806000806060858703121561541157600080fd5b843561541c81614d41565b935060208501359250604085013567ffffffffffffffff81111561543f57600080fd5b61544b87828801614be0565b95989497509550505050565b60006020828403121561546957600080fd5b8135614ae081614e9b565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154b557845183529383019391830191600101615499565b50508481036040860152610ee98187615322565b600081518084526020808501945080840160005b8381101561536857815163ffffffff16875295820195908201906001016154dd565b61ffff851681526bffffffffffffffffffffffff841660208201527fffffffff000000000000000000000000000000000000000000000000000000008316604082015260806060820152600061555860808301846154c9565b9695505050505050565b60006020828403121561557457600080fd5b8135614ae081614d41565b6000806020838503121561559257600080fd5b823567ffffffffffffffff8111156155a957600080fd5b6155b585828601614be0565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c9082168061560457607f821691505b60208210810361563d577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b82815260406020820152600061565c6040830184614b3d565b949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156131bd576131bd615664565b601f82111561092c57600081815260208120601f850160051c810160208610156156cd5750805b601f850160051c820191505b818110156156ec578281556001016156d9565b505050505050565b815167ffffffffffffffff81111561570e5761570e614c75565b6157228161571c84546155f0565b846156a6565b602080601f831160018114615775576000841561573f5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156ec565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157c2578886015182559484019460019091019084016157a3565b50858210156157fe57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361589357615893615664565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158bf576158bf615664565b5092915050565b6000602082840312156158d857600080fd5b81518015158114614ae057600080fd5b6000602082840312156158fa57600080fd5b5051919050565b600060ff821660ff810361591757615917615664565b60010192915050565b6000610160828403121561593357600080fd5b614ae0838361513d565b81516bffffffffffffffffffffffff1681526101608101602083015161597b602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516159a3604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159bf606084018267ffffffffffffffff169052565b5060808301516159d7608084018263ffffffff169052565b5060a08301516159f760a08401826bffffffffffffffffffffffff169052565b5060c0830151615a1060c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a398285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff8181168382160190808211156158bf576158bf615664565b818103818111156131bd576131bd615664565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161565c60408301846152be565b64ffffffffff8181168382160190808211156158bf576158bf615664565b6bffffffffffffffffffffffff818116838216028082169190828114615a6457615a64615664565b6bffffffffffffffffffffffff8181168382160190808211156158bf576158bf615664565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615ba660408201856152be565b60a060608201526000615bbc60a0830185614b3d565b8281036080840152610ee98185614b3d565b600067ffffffffffffffff808316818103615beb57615beb615664565b6001019392505050565b8051614abe81614f5e565b8051614abe81614ae7565b60008060008060808587031215615c2157600080fd5b8451615c2c81614e9b565b80945050602080860151615c3f81614f5e565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615c7557600080fd5b606087015190935067ffffffffffffffff811115615c9257600080fd5b8601601f81018813615ca357600080fd5b8051615cb1614d8f82614d1d565b81815260059190911b8201830190838101908a831115615cd057600080fd5b928401925b82841015615cf7578351615ce881614ae7565b82529284019290840190615cd5565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615d5560608301846154c9565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615dab610120850183614b3d565b91506060850151615dc8608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615dfa60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614abe81614d41565b8051614abe81614a9d565b8051614abe816150fc565b8051614abe8161511a565b60006101608284031215615e5c57600080fd5b615e64614ca4565b615e6d83615bf5565b8152615e7b60208401615e1d565b6020820152615e8c60408401615e1d565b6040820152615e9d60608401615e28565b6060820152615eae60808401615c00565b6080820152615ebf60a08401615bf5565b60a0820152615ed060c08401615e33565b60c082015260e083015160e0820152610100615eed818501615e3e565b90820152610120615eff848201615e33565b90820152610140615f11848201615e33565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615f5d60c0830186614b3d565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff8316815260406020820152600061565c6040830184614b3d565b838152606060208201526000615fc86060830185614b3d565b82810360408401526155588185614b3d56fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"timelockEndBlock\",\"type\":\"uint64\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620066bd380380620066bd833981016040819052620000349162000441565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d9816200016e565b50506007805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e816200021f565b5050600a80546001600160a01b0319166001600160a01b03949094169390931790925550620006cd945050505050565b336001600160a01b03821603620001c85760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080600080848060200190518101906200023b91906200053e565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600f80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002cb916010919086019062000313565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000304939291906200065c565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003b75791602002820160005b838211156200038357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200033d565b8015620003b55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000383565b505b50620003c5929150620003c9565b5090565b5b80821115620003c55760008155600101620003ca565b805161ffff81168114620003f357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004395762000439620003f8565b604052919050565b600080600080608085870312156200045857600080fd5b6200046385620003e0565b9350602062000474818701620003e0565b60408701519094506001600160a01b03811681146200049257600080fd5b60608701519093506001600160401b0380821115620004b057600080fd5b818801915088601f830112620004c557600080fd5b815181811115620004da57620004da620003f8565b620004ee601f8201601f191685016200040e565b915080825289848285010111156200050557600080fd5b60005b818110156200052557838101850151838201860152840162000508565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055557600080fd5b6200056085620003e0565b602086810151919550906001600160601b03811681146200058057600080fd5b60408701519094506001600160e01b0319811681146200059f57600080fd5b60608701519093506001600160401b0380821115620005bd57600080fd5b818801915088601f830112620005d257600080fd5b815181811115620005e757620005e7620003f8565b8060051b9150620005fa8483016200040e565b818152918301840191848101908b8411156200061557600080fd5b938501935b838510156200064c578451925063ffffffff831683146200063b5760008081fd5b82825293850193908501906200061a565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bf57845163ffffffff16835293830193918301916001016200069b565b509098975050505050505050565b608051615fd4620006e96000396000612ab70152615fd46000f3fe608060405234801561001057600080fd5b50600436106102f45760003560e01c806379ba509711610191578063aab396bd116100e3578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f14610756578063eb523d6c14610769578063f2fde38b1461077c57600080fd5b8063d7ae1d301461071d578063e72f6e3014610730578063e82ad7d41461074357600080fd5b8063b734c0f4116100c8578063b734c0f4146106e6578063badc3eb6146106ee578063c3f909d41461070557600080fd5b8063aab396bd146106ad578063b5643858146106d357600080fd5b80639f87fad711610145578063a47c76961161011f578063a47c769614610662578063a4c0ed3614610687578063a9c9a9181461069a57600080fd5b80639f87fad714610626578063a1d4c82814610639578063a21a23e41461065a57600080fd5b80638456cb59116101765780638456cb59146105f35780638da5cb5b146105fb5780638fde53171461061e57600080fd5b806379ba5097146105d857806382359740146105e057600080fd5b8063461d27621161024a57806366316d8d116101fe5780636a2215de116101d85780636a2215de1461057a5780636e3b3323146105b25780637341c10c146105c557600080fd5b806366316d8d146104ab57806366419970146104be578063674603d0146104e557600080fd5b806355fedefa1161022f57806355fedefa146104545780635c975abb146104815780635ed6dfba1461049857600080fd5b8063461d27621461042e5780634b8832d31461044157600080fd5b80631c024539116102ac5780633e871e4d116102865780633e871e4d146103f25780633f4ba83a1461040557806341db4ca31461040d57600080fd5b80631c024539146103c45780631ded3b36146103cc578063385de9ae146103df57600080fd5b806310fc49c1116102dd57806310fc49c11461032e57806312b5834914610341578063181f5a771461037b57600080fd5b806302bcc5b6146102f95780630c5d49cb1461030e575b600080fd5b61030c610307366004614ace565b61078f565b005b610316608481565b60405161ffff90911681526020015b60405180910390f35b61030c61033c366004614b0f565b6107ee565b6009546801000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610325565b6103b76040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103259190614bac565b61030c6108ea565b61030c6103da366004614bbf565b610a5b565b61030c6103ed366004614c34565b610a8c565b61030c610400366004614ded565b610b95565b61030c610ed6565b61042061041b366004614eb6565b610ee8565b604051908152602001610325565b61042061043c366004614eb6565b610f48565b61030c61044f366004614f3b565b610f54565b610420610462366004614ace565b67ffffffffffffffff166000908152600b602052604090206003015490565b60005460ff165b6040519015158152602001610325565b61030c6104a6366004614f8e565b611052565b61030c6104b9366004614f8e565b611325565b60095467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610325565b6105526104f3366004614fbc565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610325565b61058d610588366004614fea565b61154c565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610325565b61030c6105c0366004615003565b61160b565b61030c6105d3366004614f3b565b6118e7565b61030c611a7d565b61030c6105ee366004614ace565b611b9f565b61030c611ccd565b600054610100900473ffffffffffffffffffffffffffffffffffffffff1661058d565b61030c611cdd565b61030c610634366004614f3b565b611d71565b61064c61064736600461521c565b612146565b604051610325929190615304565b6104cc61253a565b610675610670366004614ace565b6126c7565b6040516103259695949392919061537e565b61030c6106953660046153e8565b6127d7565b61058d6106a8366004614fea565b612a06565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610420565b61030c6106e1366004615444565b612a6b565b61030c612bd4565b6106f6612d8e565b60405161032593929190615461565b61070d612e67565b60405161032594939291906154ec565b61030c61072b366004614f3b565b612f1e565b61030c61073e36600461554f565b612f81565b610488610751366004614ace565b613189565b61030c61076436600461556c565b6132d8565b61030c610777366004614fea565b6133fe565b61030c61078a36600461554f565b6135c9565b6107976135da565b6107a0816135e2565b67ffffffffffffffff81166000908152600b60205260409020546107eb9082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16613658565b50565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110610853576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600f6001018260ff168154811061086e5761086e6155ae565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff1611156108e4576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff8216600482015260240161084a565b50505050565b6108f26139bd565b60008080526006602052604080518082019091527f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f8805482908290610936906155dd565b80601f0160208091040260200160405190810160405280929190818152602001828054610962906155dd565b80156109af5780601f10610984576101008083540402835291602001916109af565b820191906000526020600020905b81548152906001019060200180831161099257829003601f168201915b50505091835250506001919091015467ffffffffffffffff9081166020928301529082015191925016431015610a11576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051610a1c90613a43565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a509160009190615630565b60405180910390a150565b610a636135da565b610a6c826135e2565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b610a946139bd565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600754602090910190610ae99061ffff1643615680565b67ffffffffffffffff169052600084815260066020526040902081518190610b1190826156e1565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90610b88908590859085906157fb565b60405180910390a1505050565b610b9d6139bd565b8151815181141580610baf5750600881115b15610be6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610d12576000848281518110610c0557610c056155ae565b602002602001015190506000848381518110610c2357610c236155ae565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c8e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cc5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cff576040517f4855c2880000000000000000000000000000000000000000000000000000000081526004810183905260240161084a565b505080610d0b9061584f565b9050610be9565b50600754600090610d279061ffff1643615680565b60408051606081018252868152602080820187905267ffffffffffffffff841692820192909252865192935091600391610d6591839189019061490e565b506020828101518051610d7e9260018501920190614955565b5060409190910151600290910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff90921691909117905560005b8451811015610ecf577fbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e858281518110610e0057610e006155ae565b602002602001015160026000888581518110610e1e57610e1e6155ae565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e6757610e676155ae565b602002602001015185604051610eb7949392919093845273ffffffffffffffffffffffffffffffffffffffff92831660208501529116604083015267ffffffffffffffff16606082015260800190565b60405180910390a1610ec88161584f565b9050610dc4565b5050505050565b610ede6139bd565b610ee6613b89565b565b600080610ef48361154c565b9050610f3c83828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613c069050565b98975050505050505050565b600080610ef483612a06565b610f5c613f56565b610f6582613f5e565b610f6d614024565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c01000000000000000000000000909204161461104e5767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b61105a6135da565b806bffffffffffffffffffffffff166000036110905750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff808316911610156110ea576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906111179084906bffffffffffffffffffffffff16615887565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960088282829054906101000a90046bffffffffffffffffffffffff1661116e9190615887565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561120d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061123191906158b3565b61104e57600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa1580156112a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112c891906158d5565b6009546040517fa99da302000000000000000000000000000000000000000000000000000000008152680100000000000000009091046bffffffffffffffffffffffff16600482018190526024820183905291925060440161084a565b61132d613f56565b806bffffffffffffffffffffffff16600003611375576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff808316911610156113cf576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906113fc9084906bffffffffffffffffffffffff16615887565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960088282829054906101000a90046bffffffffffffffffffffffff166114539190615887565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156114f2573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061151691906158b3565b61104e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b60035460ff821610156115d5576003805460ff8316908110611574576115746155ae565b906000526020600020015483036115c5576004805460ff831690811061159c5761159c6155ae565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b6115ce816158ee565b9050611550565b506040517f80833e330000000000000000000000000000000000000000000000000000000081526004810183905260240161084a565b611613613f56565b60005b818110156118e2576000838383818110611632576116326155ae565b90506101600201803603810190611649919061590d565b905060008160e001519050600082606001519050600e60008381526020019081526020016000205483604051602001611682919061592a565b60405160208183030381529060405280519060200120146116cf576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611714576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015611787573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117ab91906158b3565b5060a083015167ffffffffffffffff82166000908152600b6020526040812060010180549091906117eb9084906bffffffffffffffffffffffff16615887565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff8086168452915291902080546001926009916118729185916901000000000000000000900416615a59565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806118db9061584f565b9050611616565b505050565b6118ef613f56565b6118f882613f5e565b611900614024565b600f5467ffffffffffffffff83166000908152600b602052604090206002015461ffff909116900361195e576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff16156119a5575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611045565b60015473ffffffffffffffffffffffffffffffffffffffff163314611afe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161084a565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611ba7613f56565b611baf614024565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811692909104163314611c36576040517f02b543c600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff86168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611045565b611cd56139bd565b610ee6614129565b611ce56139bd565b600854640100000000900467ffffffffffffffff16431015611d33576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611d79613f56565b611d8282613f5e565b611d8a614024565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e32576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e87576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f0257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611ed7575b5050505050905060005b81518110156120aa578373ffffffffffffffffffffffffffffffffffffffff16828281518110611f3e57611f3e6155ae565b602002602001015173ffffffffffffffffffffffffffffffffffffffff160361209a578160018351611f709190615a7a565b81518110611f8057611f806155ae565b6020026020010151600b60008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611fc357611fc36155ae565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600b9091526040902060020180548061203d5761203d615a8d565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190556120aa565b6120a38161584f565b9050611f0c565b5073ffffffffffffffffffffffffffffffffffffffff83166000818152600c6020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080612151613f56565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146121ba576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e602052604090205461222257600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161221293929190615abc565b60405180910390a250600061252f565b600e60008460e001518152602001908152602001600020548360405160200161224b919061592a565b60405160208183030381529060405280519060200120146122a657600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161221293929190615abc565b826101400151836080015163ffffffff166122c19190615aee565b64ffffffffff165a101561230f57600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161221293929190615abc565b6000612324846080015163ffffffff16614184565b61232e9088615b0c565b90506000818786600001516123439190615b34565b61234d9190615b34565b606086015167ffffffffffffffff166000908152600b60205260409020549091506bffffffffffffffffffffffff90811690821611156123db57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123c793929190615abc565b60405180910390a2506000915061252f9050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561244357600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123c793929190615abc565b5050600e60008460e00151815260200190815260200160002060009055600061247b8460e001518a8a87608001518860400151614226565b805190915061248b57600161248e565b60005b925060006124bd85606001518660a00151876040015188600001518c6124b78860200151614184565b8d6143a2565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b83602001518988876000015161250a578e61250c565b8f5b8860400151604051612522959493929190615b59565b60405180910390a3519150505b965096945050505050565b6000612544613f56565b61254c614024565b600980546000906125669067ffffffffffffffff16615bbb565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156125dc578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261267792600285019290910190614955565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606060006126da876135e2565b67ffffffffffffffff87166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169c5073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009485900481169c509085169a50929093049091169650918301828280156127a657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161277b575b50505067ffffffffffffffff8a166000908152600b6020526040902060030154929450919250505091939550919395565b6127df613f56565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612830576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461286a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061287882840184614ace565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166128f1576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906129288385615b34565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960088282829054906101000a90046bffffffffffffffffffffffff1661297f9190615b34565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846129e69190615680565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff1680612a65576040517f80833e330000000000000000000000000000000000000000000000000000000081526004810184905260240161084a565b92915050565b612a736139bd565b60075461ffff808316911603612ab5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff161115612b17576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff90811680835290841660208301529091820190612b449043615680565b67ffffffffffffffff9081169091528151600880546020850151604090950151909316640100000000027fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612bdc6139bd565b60055467ffffffffffffffff16431015612c22576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612d4557600060036000018281548110612c4757612c476155ae565b90600052602060002001549050600060036001018381548110612c6c57612c6c6155ae565b6000918252602080832091909101548483526002825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526002602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612d3e8161584f565b9050612c25565b5060036000612d5482826149cf565b612d626001830160006149cf565b5060020180547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000169055565b600554600380546040805160208084028201810190925282815267ffffffffffffffff9094169360609384939192909190830182828015612dee57602002820191906000526020600020905b815481526020019060010190808311612dda575b505050505091506003600101805480602002602001604051908101604052809291908181526020018280548015612e5b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e30575b50505050509050909192565b600f54601080546040805160208084028201810190925282815261ffff8516946bffffffffffffffffffffffff62010000820416946e01000000000000000000000000000090910460e01b93606093830182828015612f1157602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ed45790505b5050505050905090919293565b612f26613f56565b612f2f82613f5e565b612f37614024565b612f4082613189565b15612f77576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61104e8282613658565b612f896135da565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ff8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061301c91906158d5565b6009549091506801000000000000000090046bffffffffffffffffffffffff1681811115613080576040517fa99da302000000000000000000000000000000000000000000000000000000008152600481018290526024810183905260440161084a565b818110156118e25760006130948284615a7a565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af115801561310f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061313391906158b3565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561320157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116131d6575b5050505050905060005b81518110156132ce576000600c600084848151811061322c5761322c6155ae565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146132bd57506001949350505050565b506132c78161584f565b905061320b565b5060009392505050565b6132e06139bd565b6040805160606020601f850181900402820181018352918101838152909182919085908590819085018382808284376000920191909152505050908252506007546020909101906133359061ffff1643615680565b67ffffffffffffffff16905260008052600660205280517f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f890819061337a90826156e1565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a906133f290600090859085906157fb565b60405180910390a15050565b6134066139bd565b600081815260066020526040808220815180830190925280548290829061342c906155dd565b80601f0160208091040260200160405190810160405280929190818152602001828054613458906155dd565b80156134a55780601f1061347a576101008083540402835291602001916134a5565b820191906000526020600020905b81548152906001019060200180831161348857829003601f168201915b50505091835250506001919091015467ffffffffffffffff9081166020928301529082015191925016431015613507576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61351082612a06565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161356491600401614bac565b600060405180830381600087803b15801561357e57600080fd5b505af1158015613592573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c793506133f29250859190615630565b6135d16139bd565b6107eb816145eb565b610ee66139bd565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166107eb576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561373957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161370e575b505050918352505060039190910154602090910152805190915060005b8260800151518110156137fa57600c60008460800151838151811061377d5761377d6155ae565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556137f38161584f565b9050613756565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061382c60028301826149cf565b6003820160009055505080600960088282829054906101000a90046bffffffffffffffffffffffff1661385f9190615887565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156138fe573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061392291906158b3565b613958576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101612138565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610ee6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161084a565b60008060008084806020019051810190613a5d9190615bf8565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600f80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a509498509296509094509092613b4391601091908601906149ed565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051613b7a93929190615cf3565b60405180910390a15050505050565b613b916146e6565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613c10613f56565b613c19856135e2565b613c233386614752565b613c2d85836107ee565b604080516101008101825233815267ffffffffffffffff87166000818152600b6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b1660808801529484529190526003015460a084015263ffffffff861660c0840152600f546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e88091613d0d9190600401615d4b565b610160604051808303816000875af1158015613d2d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d519190615e36565b9050604051806101600160405280600f60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613e60919061592a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600e90935291205560a0810151613eba90339088906147c6565b60e081015167ffffffffffffffff87166000818152600b60205260409081902054905191928b9290917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613f3f916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908d908d908d90615f09565b60405180910390a460e00151979650505050505050565b610ee66148a1565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613fd5576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461104e576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61404d7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097612a06565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf8906140b090339060248101615f6d565b602060405180830381865afa1580156140cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140f191906158b3565b610ee6576040517f2290626300000000000000000000000000000000000000000000000000000000815233600482015260240161084a565b6141316148a1565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613bdc3390565b60006bffffffffffffffffffffffff821115614222576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f3620626974730000000000000000000000000000000000000000000000000000606482015260840161084a565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916e010000000000000000000000000000900460e01b9061427390899089908990602401615f9c565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b61432557600080fd5b5a61138881101561433557600080fd5b61138881039050876040820482031161434d57600080fd5b60008086516020880160008b8df193505a900391503d6084811115614370575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006143c28486615b0c565b90506000816143d18886615b34565b6143db9190615b34565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b90915292832080549297509394508493929161443291859116615887565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550818461446c9190615b34565b336000908152600d6020526040812080549091906144999084906bffffffffffffffffffffffff16615b34565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b945090926144e091859116615b34565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d9450909261453491859116615887565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f168552925290912080546001926009916145b89185916901000000000000000000900416615a59565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361466a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161084a565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610ee6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015260640161084a565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff1661104e576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600b6020526040812060010180548392906148009084906bffffffffffffffffffffffff16615b34565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614876928492900416615a59565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610ee6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015260640161084a565b828054828255906000526020600020908101928215614949579160200282015b8281111561494957825182559160200191906001019061492e565b50614222929150614a93565b828054828255906000526020600020908101928215614949579160200282015b8281111561494957825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614975565b50805460008255906000526020600020908101906107eb9190614a93565b828054828255906000526020600020906007016008900481019282156149495791602002820160005b83821115614a5a57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a16565b8015614a8a5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a5a565b50506142229291505b5b808211156142225760008155600101614a94565b67ffffffffffffffff811681146107eb57600080fd5b8035614ac981614aa8565b919050565b600060208284031215614ae057600080fd5b8135614aeb81614aa8565b9392505050565b63ffffffff811681146107eb57600080fd5b8035614ac981614af2565b60008060408385031215614b2257600080fd5b8235614b2d81614aa8565b91506020830135614b3d81614af2565b809150509250929050565b6000815180845260005b81811015614b6e57602081850181015186830182015201614b52565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614aeb6020830184614b48565b60008060408385031215614bd257600080fd5b8235614bdd81614aa8565b946020939093013593505050565b60008083601f840112614bfd57600080fd5b50813567ffffffffffffffff811115614c1557600080fd5b602083019150836020828501011115614c2d57600080fd5b9250929050565b600080600060408486031215614c4957600080fd5b83359250602084013567ffffffffffffffff811115614c6757600080fd5b614c7386828701614beb565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614cd357614cd3614c80565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d2057614d20614c80565b604052919050565b600067ffffffffffffffff821115614d4257614d42614c80565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff811681146107eb57600080fd5b8035614ac981614d4c565b600082601f830112614d8a57600080fd5b81356020614d9f614d9a83614d28565b614cd9565b82815260059290921b84018101918181019086841115614dbe57600080fd5b8286015b84811015614de2578035614dd581614d4c565b8352918301918301614dc2565b509695505050505050565b60008060408385031215614e0057600080fd5b823567ffffffffffffffff80821115614e1857600080fd5b818501915085601f830112614e2c57600080fd5b81356020614e3c614d9a83614d28565b82815260059290921b84018101918181019089841115614e5b57600080fd5b948201945b83861015614e7957853582529482019490820190614e60565b96505086013592505080821115614e8f57600080fd5b50614e9c85828601614d79565b9150509250929050565b61ffff811681146107eb57600080fd5b60008060008060008060a08789031215614ecf57600080fd5b8635614eda81614aa8565b9550602087013567ffffffffffffffff811115614ef657600080fd5b614f0289828a01614beb565b9096509450506040870135614f1681614ea6565b92506060870135614f2681614af2565b80925050608087013590509295509295509295565b60008060408385031215614f4e57600080fd5b8235614f5981614aa8565b91506020830135614b3d81614d4c565b6bffffffffffffffffffffffff811681146107eb57600080fd5b8035614ac981614f69565b60008060408385031215614fa157600080fd5b8235614fac81614d4c565b91506020830135614b3d81614f69565b60008060408385031215614fcf57600080fd5b8235614fda81614d4c565b91506020830135614b3d81614aa8565b600060208284031215614ffc57600080fd5b5035919050565b6000806020838503121561501657600080fd5b823567ffffffffffffffff8082111561502e57600080fd5b818501915085601f83011261504257600080fd5b81358181111561505157600080fd5b8660206101608302850101111561506757600080fd5b60209290920196919550909350505050565b600082601f83011261508a57600080fd5b813567ffffffffffffffff8111156150a4576150a4614c80565b6150d560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cd9565b8181528460208386010111156150ea57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff811681146107eb57600080fd5b8035614ac981615107565b69ffffffffffffffffffff811681146107eb57600080fd5b8035614ac981615125565b6000610160828403121561515b57600080fd5b615163614caf565b905061516e82614f83565b815261517c60208301614d6e565b602082015261518d60408301614d6e565b604082015261519e60608301614abe565b60608201526151af60808301614b04565b60808201526151c060a08301614f83565b60a08201526151d160c0830161511a565b60c082015260e082013560e08201526101006151ee81840161513d565b9082015261012061520083820161511a565b9082015261014061521283820161511a565b9082015292915050565b600080600080600080610200878903121561523657600080fd5b863567ffffffffffffffff8082111561524e57600080fd5b61525a8a838b01615079565b9750602089013591508082111561527057600080fd5b5061527d89828a01615079565b955050604087013561528e81614f69565b9350606087013561529e81614f69565b925060808701356152ae81614d4c565b91506152bd8860a08901615148565b90509295509295509295565b60078110615300577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161531282856152c9565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561537357815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615341565b509495945050505050565b60006bffffffffffffffffffffffff808916835273ffffffffffffffffffffffffffffffffffffffff808916602085015281881660408501528087166060850152505060c060808301526153d560c083018561532d565b90508260a0830152979650505050505050565b600080600080606085870312156153fe57600080fd5b843561540981614d4c565b935060208501359250604085013567ffffffffffffffff81111561542c57600080fd5b61543887828801614beb565b95989497509550505050565b60006020828403121561545657600080fd5b8135614aeb81614ea6565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154a257845183529383019391830191600101615486565b50508481036040860152610f3c818761532d565b600081518084526020808501945080840160005b8381101561537357815163ffffffff16875295820195908201906001016154ca565b61ffff851681526bffffffffffffffffffffffff841660208201527fffffffff000000000000000000000000000000000000000000000000000000008316604082015260806060820152600061554560808301846154b6565b9695505050505050565b60006020828403121561556157600080fd5b8135614aeb81614d4c565b6000806020838503121561557f57600080fd5b823567ffffffffffffffff81111561559657600080fd5b6155a285828601614beb565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c908216806155f157607f821691505b60208210810361562a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b8281526040602082015260006156496040830184614b48565b949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115612a6557612a65615651565b601f8211156118e257600081815260208120601f850160051c810160208610156156ba5750805b601f850160051c820191505b818110156156d9578281556001016156c6565b505050505050565b815167ffffffffffffffff8111156156fb576156fb614c80565b61570f8161570984546155dd565b84615693565b602080601f831160018114615762576000841561572c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156d9565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157af57888601518255948401946001909101908401615790565b50858210156157eb57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361588057615880615651565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158ac576158ac615651565b5092915050565b6000602082840312156158c557600080fd5b81518015158114614aeb57600080fd5b6000602082840312156158e757600080fd5b5051919050565b600060ff821660ff810361590457615904615651565b60010192915050565b6000610160828403121561592057600080fd5b614aeb8383615148565b81516bffffffffffffffffffffffff16815261016081016020830151615968602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615990604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159ac606084018267ffffffffffffffff169052565b5060808301516159c4608084018263ffffffff169052565b5060a08301516159e460a08401826bffffffffffffffffffffffff169052565b5060c08301516159fd60c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a268285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff8181168382160190808211156158ac576158ac615651565b81810381811115612a6557612a65615651565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161564960408301846152c9565b64ffffffffff8181168382160190808211156158ac576158ac615651565b6bffffffffffffffffffffffff818116838216028082169190828114615a5157615a51615651565b6bffffffffffffffffffffffff8181168382160190808211156158ac576158ac615651565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615b9360408201856152c9565b60a060608201526000615ba960a0830185614b48565b8281036080840152610f3c8185614b48565b600067ffffffffffffffff808316818103615bd857615bd8615651565b6001019392505050565b8051614ac981614f69565b8051614ac981614af2565b60008060008060808587031215615c0e57600080fd5b8451615c1981614ea6565b80945050602080860151615c2c81614f69565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615c6257600080fd5b606087015190935067ffffffffffffffff811115615c7f57600080fd5b8601601f81018813615c9057600080fd5b8051615c9e614d9a82614d28565b81815260059190911b8201830190838101908a831115615cbd57600080fd5b928401925b82841015615ce4578351615cd581614af2565b82529284019290840190615cc2565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615d4260608301846154b6565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615d98610120850183614b48565b91506060850151615db5608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615de760e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614ac981614d4c565b8051614ac981614aa8565b8051614ac981615107565b8051614ac981615125565b60006101608284031215615e4957600080fd5b615e51614caf565b615e5a83615be2565b8152615e6860208401615e0a565b6020820152615e7960408401615e0a565b6040820152615e8a60608401615e15565b6060820152615e9b60808401615bed565b6080820152615eac60a08401615be2565b60a0820152615ebd60c08401615e20565b60c082015260e083015160e0820152610100615eda818501615e2b565b90820152610120615eec848201615e20565b90820152610140615efe848201615e20565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615f4a60c0830186614b48565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006156496040830184614b48565b838152606060208201526000615fb56060830185614b48565b82810360408401526155458185614b4856fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -238,28 +229,35 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetAllowListId() ([32]byte return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (uint16, *big.Int, [4]byte, []uint32, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (GetConfig, + + error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getConfig") + outstruct := new(GetConfig) if err != nil { - return *new(uint16), *new(*big.Int), *new([4]byte), *new([]uint32), err + return *outstruct, err } - out0 := *abi.ConvertType(out[0], new(uint16)).(*uint16) - out1 := *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - out2 := *abi.ConvertType(out[2], new([4]byte)).(*[4]byte) - out3 := *abi.ConvertType(out[3], new([]uint32)).(*[]uint32) + outstruct.MaxConsumersPerSubscription = *abi.ConvertType(out[0], new(uint16)).(*uint16) + outstruct.AdminFee = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + outstruct.HandleOracleFulfillmentSelector = *abi.ConvertType(out[2], new([4]byte)).(*[4]byte) + outstruct.MaxCallbackGasLimits = *abi.ConvertType(out[3], new([]uint32)).(*[]uint32) - return out0, out1, out2, out3, err + return *outstruct, err } -func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (uint16, *big.Int, [4]byte, []uint32, error) { +func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (GetConfig, + + error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (uint16, *big.Int, [4]byte, []uint32, error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (GetConfig, + + error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } @@ -360,49 +358,68 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractById(id return _FunctionsRouter.Contract.GetProposedContractById(&_FunctionsRouter.CallOpts, id) } -func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) (GetProposedContractSet, + + error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getProposedContractSet") + outstruct := new(GetProposedContractSet) if err != nil { - return *new(*big.Int), *new([][32]byte), *new([]common.Address), err + return *outstruct, err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - out1 := *abi.ConvertType(out[1], new([][32]byte)).(*[][32]byte) - out2 := *abi.ConvertType(out[2], new([]common.Address)).(*[]common.Address) + outstruct.TimelockEndBlock = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + outstruct.Ids = *abi.ConvertType(out[1], new([][32]byte)).(*[][32]byte) + outstruct.To = *abi.ConvertType(out[2], new([]common.Address)).(*[]common.Address) - return out0, out1, out2, err + return *outstruct, err } -func (_FunctionsRouter *FunctionsRouterSession) GetProposedContractSet() (*big.Int, [][32]byte, []common.Address, error) { +func (_FunctionsRouter *FunctionsRouterSession) GetProposedContractSet() (GetProposedContractSet, + + error) { return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() (*big.Int, [][32]byte, []common.Address, error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() (GetProposedContractSet, + + error) { return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, + + error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getSubscription", subscriptionId) + outstruct := new(GetSubscription) if err != nil { - return *new(IFunctionsSubscriptionsSubscription), err + return *outstruct, err } - out0 := *abi.ConvertType(out[0], new(IFunctionsSubscriptionsSubscription)).(*IFunctionsSubscriptionsSubscription) + outstruct.Balance = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + outstruct.Owner = *abi.ConvertType(out[1], new(common.Address)).(*common.Address) + outstruct.BlockedBalance = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) + outstruct.RequestedOwner = *abi.ConvertType(out[3], new(common.Address)).(*common.Address) + outstruct.Consumers = *abi.ConvertType(out[4], new([]common.Address)).(*[]common.Address) + outstruct.Flags = *abi.ConvertType(out[5], new([32]byte)).(*[32]byte) - return out0, err + return *outstruct, err } -func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { +func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (GetSubscription, + + error) { return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (GetSubscription, + + error) { return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) } @@ -450,28 +467,6 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetTotalBalance() (*big.In return _FunctionsRouter.Contract.GetTotalBalance(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) IsPaused(opts *bind.CallOpts) (bool, error) { - var out []interface{} - err := _FunctionsRouter.contract.Call(opts, &out, "isPaused") - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -func (_FunctionsRouter *FunctionsRouterSession) IsPaused() (bool, error) { - return _FunctionsRouter.Contract.IsPaused(&_FunctionsRouter.CallOpts) -} - -func (_FunctionsRouter *FunctionsRouterCallerSession) IsPaused() (bool, error) { - return _FunctionsRouter.Contract.IsPaused(&_FunctionsRouter.CallOpts) -} - func (_FunctionsRouter *FunctionsRouterCaller) IsValidCallbackGasLimit(opts *bind.CallOpts, subscriptionId uint64, callbackGasLimit uint32) error { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "isValidCallbackGasLimit", subscriptionId, callbackGasLimit) @@ -1335,7 +1330,7 @@ type FunctionsRouterContractProposed struct { ProposedContractSetId [32]byte ProposedContractSetFromAddress common.Address ProposedContractSetToAddress common.Address - TimelockEndBlock *big.Int + TimelockEndBlock uint64 Raw types.Log } @@ -3819,11 +3814,30 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParseUnpaused(log types.Log) (* return event, nil } +type GetConfig struct { + MaxConsumersPerSubscription uint16 + AdminFee *big.Int + HandleOracleFulfillmentSelector [4]byte + MaxCallbackGasLimits []uint32 +} type GetConsumer struct { Allowed bool InitiatedRequests uint64 CompletedRequests uint64 } +type GetProposedContractSet struct { + TimelockEndBlock *big.Int + Ids [][32]byte + To []common.Address +} +type GetSubscription struct { + Balance *big.Int + Owner common.Address + BlockedBalance *big.Int + RequestedOwner common.Address + Consumers []common.Address + Flags [32]byte +} func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { @@ -3892,7 +3906,7 @@ func (FunctionsRouterConfigUpdated) Topic() common.Hash { } func (FunctionsRouterContractProposed) Topic() common.Hash { - return common.HexToHash("0x72a33d2f293a0a70fad221bb610d3d6b52aed2d840adae1fa721071fbd290cfd") + return common.HexToHash("0xbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e") } func (FunctionsRouterContractUpdated) Topic() common.Hash { @@ -3980,7 +3994,9 @@ type FunctionsRouterInterface interface { GetAllowListId(opts *bind.CallOpts) ([32]byte, error) - GetConfig(opts *bind.CallOpts) (uint16, *big.Int, [4]byte, []uint32, error) + GetConfig(opts *bind.CallOpts) (GetConfig, + + error) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, @@ -3992,16 +4008,18 @@ type FunctionsRouterInterface interface { GetProposedContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) - GetProposedContractSet(opts *bind.CallOpts) (*big.Int, [][32]byte, []common.Address, error) + GetProposedContractSet(opts *bind.CallOpts) (GetProposedContractSet, + + error) + + GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) + error) GetSubscriptionCount(opts *bind.CallOpts) (uint64, error) GetTotalBalance(opts *bind.CallOpts) (*big.Int, error) - IsPaused(opts *bind.CallOpts) (bool, error) - IsValidCallbackGasLimit(opts *bind.CallOpts, subscriptionId uint64, callbackGasLimit uint32) error Owner(opts *bind.CallOpts) (common.Address, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e34cdc8ec89..2687f90a4ca 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,12 +1,12 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin a6a0fae8fe9c6124f03bf66208fc74eac185be57919e9a3906f4020f0bde2074 +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 86afaf81f6a4d775dd207d49681741e891e8409e4db4f6ad7164ac439919cc66 functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 3abd1e91ec88cfc6068473d9532e1aadaa0861591b5fe209f8c32d9140433e40 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin bac5a8c114e65049ecc5c6f9d262bc0325a903d8554fbbe447f48341ffccd58a +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 078a41c5c56dae19be70bf19d15d61cd7dba5a306a58ac8b7b6ccdfe3baf4bd3 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 717e0028ba28088b0ae09bbb687a5e2720435cf6f93ee5b1202fb73a460d8a9d +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin f14117bbc3f9f50b7098d44c83b3270cb382b7b3cc4047bc645baf7224420f32 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From 45e0a72e0dc8c7bdfb1880f5eec906aad03bdcfd Mon Sep 17 00:00:00 2001 From: Steve Ellis Date: Thu, 3 Aug 2023 22:34:57 -0400 Subject: [PATCH 076/270] cleanup CBOR dependencies (#10076) * cleanup CBOR dependencies * fix other usage of CBOR * Regenerate geth wrappers --------- Co-authored-by: Justin Kaseman --- .../dev/1_0_0/libraries/FunctionsRequest.sol | 53 +++++++++---------- .../functions_client_example.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 3 files changed, 27 insertions(+), 30 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol index ef8b1791f00..7cb330a3606 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol @@ -1,14 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {Buffer} from "../../../../vendor/@ensdomains/buffer/0.1.0/Buffer.sol"; import {CBOR} from "../../../../vendor/solidity-cborutils/v2.0.0/CBOR.sol"; /** * @title Library for encoding the input data of a Functions request into CBOR */ library FunctionsRequest { - using CBOR for Buffer.buffer; + using CBOR for CBOR.CBORBuffer; uint16 public constant REQUEST_DATA_VERSION = 1; uint256 internal constant DEFAULT_BUFFER_SIZE = 256; @@ -45,44 +44,43 @@ library FunctionsRequest { * @return CBOR encoded bytes */ function encodeCBOR(Request memory self) internal pure returns (bytes memory) { - CBOR.CBORBuffer memory buffer; - Buffer.init(buffer.buf, DEFAULT_BUFFER_SIZE); + CBOR.CBORBuffer memory buffer = CBOR.create(DEFAULT_BUFFER_SIZE); - CBOR.writeString(buffer, "codeLocation"); - CBOR.writeUInt256(buffer, uint256(self.codeLocation)); + buffer.writeString("codeLocation"); + buffer.writeUInt256(uint256(self.codeLocation)); - CBOR.writeString(buffer, "language"); - CBOR.writeUInt256(buffer, uint256(self.language)); + buffer.writeString("language"); + buffer.writeUInt256(uint256(self.language)); - CBOR.writeString(buffer, "source"); - CBOR.writeString(buffer, self.source); + buffer.writeString("source"); + buffer.writeString(self.source); if (self.args.length > 0) { - CBOR.writeString(buffer, "args"); - CBOR.startArray(buffer); + buffer.writeString("args"); + buffer.startArray(); for (uint256 i = 0; i < self.args.length; ++i) { - CBOR.writeString(buffer, self.args[i]); + buffer.writeString(self.args[i]); } - CBOR.endSequence(buffer); + buffer.endSequence(); } if (self.encryptedSecretsReference.length > 0) { if (self.secretsLocation == Location.Inline) { revert NoInlineSecrets(); } - CBOR.writeString(buffer, "secretsLocation"); - CBOR.writeUInt256(buffer, uint256(self.secretsLocation)); - CBOR.writeString(buffer, "secrets"); - CBOR.writeBytes(buffer, self.encryptedSecretsReference); + buffer.writeString("secretsLocation"); + buffer.writeUInt256(uint256(self.secretsLocation)); + buffer.writeString("secrets"); + buffer.writeBytes(self.encryptedSecretsReference); } if (self.bytesArgs.length > 0) { - CBOR.writeString(buffer, "bytesArgs"); - CBOR.startArray(buffer); + buffer.writeString("bytesArgs"); + buffer.startArray(); for (uint256 i = 0; i < self.bytesArgs.length; ++i) { - CBOR.writeBytes(buffer, self.bytesArgs[i]); + buffer.writeBytes(self.bytesArgs[i]); } - CBOR.endSequence(buffer); + buffer.endSequence(); } return buffer.buf.buf; @@ -138,13 +136,12 @@ library FunctionsRequest { * @param version User data version (for the slotID) */ function addDONHostedSecrets(Request memory self, uint8 slotID, uint64 version) internal pure { - CBOR.CBORBuffer memory buffer; - Buffer.init(buffer.buf, DEFAULT_BUFFER_SIZE); + CBOR.CBORBuffer memory buffer = CBOR.create(DEFAULT_BUFFER_SIZE); - CBOR.writeString(buffer, "slotID"); - CBOR.writeUInt64(buffer, slotID); - CBOR.writeString(buffer, "version"); - CBOR.writeUInt64(buffer, version); + buffer.writeString("slotID"); + buffer.writeUInt64(slotID); + buffer.writeString("version"); + buffer.writeUInt64(version); self.secretsLocation = Location.DONHosted; self.encryptedSecretsReference = buffer.buf.buf; diff --git a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go index ce45300d46d..4be80adae02 100644 --- a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go +++ b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go @@ -32,7 +32,7 @@ var ( var FunctionsClientExampleMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFulfill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620019f8380380620019f8833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b608051611823620001d5600039600081816101c60152610bdb01526118236000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc36600461126f565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e1610143366004611342565b61022d565b6101176201117081565b6100e1610337565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e1610199366004611426565b610439565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361044d565b505050565b61023561051b565b6102766040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6102b889898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061059e9050565b85156103005761030087878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105af9050565b831561031a5761031a610313858761145c565b82906105f9565b6103298184620111708561063c565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61044161051b565b61044a8161065b565b50565b826002541461048b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103b4565b61049482610750565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104d681610750565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461059c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103b4565b565b6105ab82600080846107d2565b5050565b80516000036105ea576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610634576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b600061065261064a86610869565b858585610bd6565b95945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103b4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060209050602083511015610765575081515b60005b818110156107cb5761077b816008611552565b84828151811061078d5761078d611569565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107c481611598565b9050610768565b5050919050565b805160000361080d576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83836002811115610820576108206114f4565b90816002811115610833576108336114f4565b90525060408401828015610849576108496114f4565b90818015610859576108596114f4565b9052506060909301929092525050565b6060610873611126565b805161088190610100610cb5565b506108c1816040518060400160405280600c81526020017f636f64654c6f636174696f6e0000000000000000000000000000000000000000815250610d2f565b6108e081846000015160028111156108db576108db6114f4565b610d48565b61091f816040518060400160405280600881526020017f6c616e6775616765000000000000000000000000000000000000000000000000815250610d2f565b61093981846040015160008111156108db576108db6114f4565b610978816040518060400160405280600681526020017f736f757263650000000000000000000000000000000000000000000000000000815250610d2f565b610986818460600151610d2f565b60a08301515115610a2a576109d0816040518060400160405280600481526020017f6172677300000000000000000000000000000000000000000000000000000000815250610d2f565b6109d981610d81565b60005b8360a0015151811015610a2057610a10828560a001518381518110610a0357610a03611569565b6020026020010151610d2f565b610a1981611598565b90506109dc565b50610a2a81610da5565b60808301515115610b2a57600083602001516002811115610a4d57610a4d6114f4565b03610a84576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ac3816040518060400160405280600f81526020017f736563726574734c6f636174696f6e0000000000000000000000000000000000815250610d2f565b610add81846020015160028111156108db576108db6114f4565b610b1c816040518060400160405280600781526020017f7365637265747300000000000000000000000000000000000000000000000000815250610d2f565b610b2a818460800151610dc3565b60c08301515115610bce57610b74816040518060400160405280600981526020017f6279746573417267730000000000000000000000000000000000000000000000815250610d2f565b610b7d81610d81565b60005b8360c0015151811015610bc457610bb4828560c001518381518110610ba757610ba7611569565b6020026020010151610dc3565b610bbd81611598565b9050610b80565b50610bce81610da5565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610c3b9594939291906115d0565b6020604051808303816000875af1158015610c5a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c7e9190611670565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b604080518082019091526060815260006020820152610cd5602083611689565b15610cfd57610ce5602083611689565b610cf09060206116c4565b610cfa90836116d7565b91505b602080840183905260405180855260008152908184010181811015610d2157600080fd5b604052508290505b92915050565b610d3c8260038351610dcc565b81516102289082610ef3565b8151610d559060c2610f1b565b506105ab8282604051602001610d6d91815260200190565b604051602081830303815290604052610dc3565b610d8c816004610f84565b600181602001818151610d9f91906116d7565b90525050565b610db0816007610f84565b600181602001818151610d9f91906116c4565b610d3c82600283515b60178167ffffffffffffffff1611610df9578251610df39060e0600585901b168317610f1b565b50505050565b60ff8167ffffffffffffffff1611610e3b578251610e22906018611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166001610f9b565b61ffff8167ffffffffffffffff1611610e7e578251610e65906019611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166002610f9b565b63ffffffff8167ffffffffffffffff1611610ec3578251610eaa90601a611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166004610f9b565b8251610eda90601b611fe0600586901b1617610f1b565b508251610df39067ffffffffffffffff83166008610f9b565b604080518082019091526060815260006020820152610f1483838451611020565b9392505050565b6040805180820190915260608152600060208201528251516000610f408260016116d7565b905084602001518210610f6157610f6185610f5c836002611552565b61110f565b8451602083820101858153508051821115610f7a578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f1b565b6040805180820190915260608152600060208201528351516000610fbf82856116d7565b90508560200151811115610fdc57610fdc86610f5c836002611552565b60006001610fec8661010061180a565b610ff691906116c4565b90508651828101878319825116178152508051831115611014578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561104357600080fd5b835151600061105284836116d7565b9050856020015181111561106f5761106f86610f5c836002611552565b855180518382016020019160009180851115611089578482525b505050602086015b602086106110c957805182526110a86020836116d7565b91506110b56020826116d7565b90506110c26020876116c4565b9550611091565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b815161111b8383610cb5565b50610df38382610ef3565b604051806040016040528061114e604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156111d1576111d161115b565b604052919050565b600067ffffffffffffffff8311156111f3576111f361115b565b61122460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8601160161118a565b905082815283838301111561123857600080fd5b828260208301376000602084830101529392505050565b600082601f83011261126057600080fd5b610f14838335602085016111d9565b60008060006060848603121561128457600080fd5b83359250602084013567ffffffffffffffff808211156112a357600080fd5b6112af8783880161124f565b935060408601359150808211156112c557600080fd5b506112d28682870161124f565b9150509250925092565b60008083601f8401126112ee57600080fd5b50813567ffffffffffffffff81111561130657600080fd5b60208301915083602082850101111561131e57600080fd5b9250929050565b803567ffffffffffffffff8116811461133d57600080fd5b919050565b60008060008060008060008060a0898b03121561135e57600080fd5b883567ffffffffffffffff8082111561137657600080fd5b6113828c838d016112dc565b909a50985060208b013591508082111561139b57600080fd5b6113a78c838d016112dc565b909850965060408b01359150808211156113c057600080fd5b818b0191508b601f8301126113d457600080fd5b8135818111156113e357600080fd5b8c60208260051b85010111156113f857600080fd5b60208301965080955050505061141060608a01611325565b9150608089013590509295985092959890939650565b60006020828403121561143857600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f1457600080fd5b600067ffffffffffffffff808411156114775761147761115b565b8360051b602061148881830161118a565b8681529185019181810190368411156114a057600080fd5b865b848110156114e8578035868111156114ba5760008081fd5b880136601f8201126114cc5760008081fd5b6114da3682358784016111d9565b8452509183019183016114a2565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610d2957610d29611523565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115c9576115c9611523565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b8181101561160e5788810183015185820160c0015282016115f2565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050611657604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561168257600080fd5b5051919050565b6000826116bf577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b81810381811115610d2957610d29611523565b80820180821115610d2957610d29611523565b600181815b8085111561174357817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561172957611729611523565b8085161561173657918102915b93841c93908002906116ef565b509250929050565b60008261175a57506001610d29565b8161176757506000610d29565b816001811461177d5760028114611787576117a3565b6001915050610d29565b60ff84111561179857611798611523565b50506001821b610d29565b5060208310610133831016604e8410600b84101617156117c6575081810a610d29565b6117d083836116ea565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561180257611802611523565b029392505050565b6000610f14838361174b56fea164736f6c6343000813000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001a2f38038062001a2f833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b60805161185a620001d5600039600081816101c60152610bed015261185a6000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc3660046112a6565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e1610143366004611379565b61022d565b6101176201117081565b6100e1610337565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e161019936600461145d565b610439565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361044d565b505050565b61023561051b565b6102766040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6102b889898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061059e9050565b85156103005761030087878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105af9050565b831561031a5761031a6103138587611493565b82906105f9565b6103298184620111708561063c565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61044161051b565b61044a8161065b565b50565b826002541461048b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103b4565b61049482610750565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104d681610750565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461059c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103b4565b565b6105ab82600080846107d2565b5050565b80516000036105ea576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610634576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b600061065261064a86610869565b858585610be8565b95945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103b4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060209050602083511015610765575081515b60005b818110156107cb5761077b816008611589565b84828151811061078d5761078d6115a0565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107c4816115cf565b9050610768565b5050919050565b805160000361080d576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b838360028111156108205761082061152b565b908160028111156108335761083361152b565b905250604084018280156108495761084961152b565b908180156108595761085961152b565b9052506060909301929092525050565b60606000610878610100610cc7565b90506108c26040518060400160405280600c81526020017f636f64654c6f636174696f6e000000000000000000000000000000000000000081525082610ce890919063ffffffff16565b82516108e09060028111156108d9576108d961152b565b8290610d01565b60408051808201909152600881527f6c616e6775616765000000000000000000000000000000000000000000000000602082015261091f908290610ce8565b60408301516109369080156108d9576108d961152b565b60408051808201909152600681527f736f7572636500000000000000000000000000000000000000000000000000006020820152610975908290610ce8565b6060830151610985908290610ce8565b60a08301515115610a325760408051808201909152600481527f617267730000000000000000000000000000000000000000000000000000000060208201526109cf908290610ce8565b6109d881610d3a565b60005b8360a0015151811015610a2857610a188460a001518281518110610a0157610a016115a0565b602002602001015183610ce890919063ffffffff16565b610a21816115cf565b90506109db565b50610a3281610d5e565b60808301515115610b3357600083602001516002811115610a5557610a5561152b565b03610a8c576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051808201909152600f81527f736563726574734c6f636174696f6e00000000000000000000000000000000006020820152610acb908290610ce8565b610ae4836020015160028111156108d9576108d961152b565b60408051808201909152600781527f73656372657473000000000000000000000000000000000000000000000000006020820152610b23908290610ce8565b6080830151610b33908290610d7c565b60c08301515115610be05760408051808201909152600981527f62797465734172677300000000000000000000000000000000000000000000006020820152610b7d908290610ce8565b610b8681610d3a565b60005b8360c0015151811015610bd657610bc68460c001518281518110610baf57610baf6115a0565b602002602001015183610d7c90919063ffffffff16565b610bcf816115cf565b9050610b89565b50610be081610d5e565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610c4d959493929190611607565b6020604051808303816000875af1158015610c6c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9091906116a7565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b610ccf61115d565b8051610cdb9083610d89565b5060006020820152919050565b610cf58260038351610e03565b81516102289082610f2a565b8151610d0e9060c2610f52565b506105ab8282604051602001610d2691815260200190565b604051602081830303815290604052610d7c565b610d45816004610fbb565b600181602001818151610d5891906116c0565b90525050565b610d69816007610fbb565b600181602001818151610d5891906116d3565b610cf58260028351610e03565b604080518082019091526060815260006020820152610da96020836116e6565b15610dd157610db96020836116e6565b610dc49060206116d3565b610dce90836116c0565b91505b602080840183905260405180855260008152908184010181811015610df557600080fd5b604052508290505b92915050565b60178167ffffffffffffffff1611610e30578251610e2a9060e0600585901b168317610f52565b50505050565b60ff8167ffffffffffffffff1611610e72578251610e59906018611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166001610fd2565b61ffff8167ffffffffffffffff1611610eb5578251610e9c906019611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166002610fd2565b63ffffffff8167ffffffffffffffff1611610efa578251610ee190601a611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166004610fd2565b8251610f1190601b611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166008610fd2565b604080518082019091526060815260006020820152610f4b83838451611057565b9392505050565b6040805180820190915260608152600060208201528251516000610f778260016116c0565b905084602001518210610f9857610f9885610f93836002611589565b611146565b8451602083820101858153508051821115610fb1578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f52565b6040805180820190915260608152600060208201528351516000610ff682856116c0565b905085602001518111156110135761101386610f93836002611589565b6000600161102386610100611841565b61102d91906116d3565b9050865182810187831982511617815250805183111561104b578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561107a57600080fd5b835151600061108984836116c0565b905085602001518111156110a6576110a686610f93836002611589565b8551805183820160200191600091808511156110c0578482525b505050602086015b6020861061110057805182526110df6020836116c0565b91506110ec6020826116c0565b90506110f96020876116d3565b95506110c8565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111528383610d89565b50610e2a8382610f2a565b6040518060400160405280611185604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561120857611208611192565b604052919050565b600067ffffffffffffffff83111561122a5761122a611192565b61125b60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116016111c1565b905082815283838301111561126f57600080fd5b828260208301376000602084830101529392505050565b600082601f83011261129757600080fd5b610f4b83833560208501611210565b6000806000606084860312156112bb57600080fd5b83359250602084013567ffffffffffffffff808211156112da57600080fd5b6112e687838801611286565b935060408601359150808211156112fc57600080fd5b5061130986828701611286565b9150509250925092565b60008083601f84011261132557600080fd5b50813567ffffffffffffffff81111561133d57600080fd5b60208301915083602082850101111561135557600080fd5b9250929050565b803567ffffffffffffffff8116811461137457600080fd5b919050565b60008060008060008060008060a0898b03121561139557600080fd5b883567ffffffffffffffff808211156113ad57600080fd5b6113b98c838d01611313565b909a50985060208b01359150808211156113d257600080fd5b6113de8c838d01611313565b909850965060408b01359150808211156113f757600080fd5b818b0191508b601f83011261140b57600080fd5b81358181111561141a57600080fd5b8c60208260051b850101111561142f57600080fd5b60208301965080955050505061144760608a0161135c565b9150608089013590509295985092959890939650565b60006020828403121561146f57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f4b57600080fd5b600067ffffffffffffffff808411156114ae576114ae611192565b8360051b60206114bf8183016111c1565b8681529185019181810190368411156114d757600080fd5b865b8481101561151f578035868111156114f15760008081fd5b880136601f8201126115035760008081fd5b611511368235878401611210565b8452509183019183016114d9565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610dfd57610dfd61155a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036116005761160061155a565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156116455788810183015185820160c001528201611629565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505061168e604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b6000602082840312156116b957600080fd5b5051919050565b80820180821115610dfd57610dfd61155a565b81810381811115610dfd57610dfd61155a565b60008261171c577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b600181815b8085111561177a57817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117605761176061155a565b8085161561176d57918102915b93841c9390800290611726565b509250929050565b60008261179157506001610dfd565b8161179e57506000610dfd565b81600181146117b457600281146117be576117da565b6001915050610dfd565b60ff8411156117cf576117cf61155a565b50506001821b610dfd565b5060208310610133831016604e8410600b84101617156117fd575081810a610dfd565b6118078383611721565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156118395761183961155a565b029392505050565b6000610f4b838361178256fea164736f6c6343000813000a", } var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 2687f90a4ca..05a51012855 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 86afaf81f6a4d775dd207d49681741e891e8409e4db4f6ad7164ac439919cc66 functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca -functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 3abd1e91ec88cfc6068473d9532e1aadaa0861591b5fe209f8c32d9140433e40 +functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 525316bc1fab9f1d6d262ac9fc1087f66a8314de4dcc9684ba78a29e8014328f functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 078a41c5c56dae19be70bf19d15d61cd7dba5a306a58ac8b7b6ccdfe3baf4bd3 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin f14117bbc3f9f50b7098d44c83b3270cb382b7b3cc4047bc645baf7224420f32 From 0f239478a0bef799ea81b7d1e2ac7666cd632b90 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Fri, 4 Aug 2023 03:17:55 -0400 Subject: [PATCH 077/270] [Functions] (refactor): Various changes from review #3 (#10056) * Reapply: s_router is private * Create libraries folder, move Functions->FunctionsRequest & FunctionsResponse types in * Revert HasRouter back to Routable, add natspec * Separate Functions library Buffer import from CBOR * Functions library, using before all * (doc): Add more comments to Functions Request library * Document and clean up FunctionsClient * Geth wrappers * Add more ToS allowlist events * s_router -> i_router * RouterBase: timelock to uint64, remove doubled Paused getter, if statement revert style * Remove unused OCR hooks * make flags index var name more clear & add comment about internal function modifiers * Regenerate geth wrappers * Various size reducing measures * Save * Use ^v0.8.0 in openzeppelin-solidity/v4.8.0 * merge function base and router * Router config as typed struct * (test): Update tests * Use structs as getter return * Pull juelsPerGas into helper function * Add OracleWithdrawAll * Change multiline comments to single * Disable timelock propose and set in anticipation of MCM change * Regenerate geth wrappers * Add estimated cost to RequestStart * Fix foundry test * (test): Amend go integration test for Router constructor --------- Co-authored-by: Rens Rooimans --- .../functions/dev/1_0_0/FunctionsBilling.sol | 353 ++++++--------- .../dev/1_0_0/FunctionsCoordinator.sol | 59 ++- .../functions/dev/1_0_0/FunctionsRouter.sol | 344 ++++++++++++--- .../dev/1_0_0/FunctionsSubscriptions.sol | 324 ++++++-------- .../src/v0.8/functions/dev/1_0_0/Routable.sol | 34 +- .../v0.8/functions/dev/1_0_0/RouterBase.sol | 281 ------------ .../dev/1_0_0/interfaces/IConfigurable.sol | 10 +- .../1_0_0/interfaces/IFunctionsBilling.sol | 113 ++--- .../dev/1_0_0/interfaces/IFunctionsClient.sol | 16 +- .../interfaces/IFunctionsCoordinator.sol | 75 ++-- .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 144 +++--- .../interfaces/IFunctionsSubscriptions.sol | 196 +++------ .../interfaces/IOwnableFunctionsRouter.sol | 4 +- .../dev/1_0_0/interfaces/IRouterBase.sol | 95 ---- .../dev/1_0_0/libraries/FunctionsRequest.sol | 70 ++- .../dev/1_0_0/libraries/FunctionsResponse.sol | 4 +- .../tests/1_0_0/FunctionsRouter.t.sol | 25 +- .../testhelpers/FunctionsClientTestHelper.sol | 2 - .../v4.8.0/contracts/interfaces/IERC5267.sol | 28 ++ .../contracts/interfaces/draft-IERC6093.sol | 160 +++++++ .../v4.8.0/contracts/token/ERC20/ERC20.sol | 370 ++++++++++++++++ .../v4.8.0/contracts/token/ERC20/IERC20.sol | 79 ++++ .../token/ERC20/extensions/ERC20Permit.sol | 84 ++++ .../token/ERC20/extensions/IERC20Metadata.sol | 26 ++ .../token/ERC20/extensions/IERC20Permit.sol | 60 +++ .../contracts/token/ERC20/utils/SafeERC20.sol | 140 ++++++ .../v4.8.0/contracts/utils/Nonces.sol | 46 ++ .../v4.8.0/contracts/utils/ShortStrings.sol | 122 ++++++ .../v4.8.0/contracts/utils/StorageSlot.sol | 135 ++++++ .../v4.8.0/contracts/utils/Strings.sol | 93 ++++ .../contracts/utils/cryptography/ECDSA.sol | 171 ++++++++ .../contracts/utils/cryptography/EIP712.sol | 160 +++++++ .../utils/cryptography/MessageHashUtils.sol | 87 ++++ .../v4.8.0/contracts/utils/math/Math.sol | 414 ++++++++++++++++++ .../contracts/utils/math/SignedMath.sol | 43 ++ .../v0.8/functions/v1/FunctionsRouter.test.ts | 10 +- .../test/v0.8/functions/v1/RouterBase.test.ts | 130 +++--- contracts/test/v0.8/functions/v1/utils.ts | 14 +- .../functions_coordinator.go | 138 +++--- .../functions_router/functions_router.go | 149 ++----- ...rapper-dependency-versions-do-not-edit.txt | 4 +- .../v1/internal/testutils.go | 14 +- 42 files changed, 3309 insertions(+), 1517 deletions(-) delete mode 100644 contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol delete mode 100644 contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC6093.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SignedMath.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 4d79a24e1bd..4a814d09e94 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -18,6 +18,8 @@ import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; abstract contract FunctionsBilling is Routable, IFunctionsBilling { using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; + + uint32 private constant REASONABLE_GAS_PRICE_CEILING = 1_000_000; // ================================================================ // | Request Commitment state | // ================================================================ @@ -30,44 +32,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // | Configuration state | // ================================================================ - struct Config { - // Maximum amount of gas that can be given to a request's client callback - uint32 maxCallbackGasLimit; - // feedStalenessSeconds is how long before we consider the feed price to be stale - // and fallback to fallbackNativePerUnitLink. - uint32 feedStalenessSeconds; - // Represents the average gas execution cost. Used in estimating cost beforehand. - uint32 gasOverheadBeforeCallback; - // Gas to cover transmitter oracle payment after we calculate the payment. - // We make it configurable in case those operations are repriced. - uint32 gasOverheadAfterCallback; - // how many seconds it takes before we consider a request to be timed out - uint32 requestTimeoutSeconds; - // additional flat fee (in Juels of LINK) that will be split between Node Operators - // Max value is 2^80 - 1 == 1.2m LINK. - uint80 donFee; - // The highest support request data version supported by the node - // All lower versions should also be supported - uint16 maxSupportedRequestDataVersion; - // Percentage of gas price overestimation to account for changes in gas price between request and response - // Held as basis points (one hundredth of 1 percentage point) - uint256 fulfillmentGasPriceOverEstimationBP; - // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale - int256 fallbackNativePerUnitLink; - } - Config private s_config; - event ConfigChanged( - uint32 maxCallbackGasLimit, - uint32 feedStalenessSeconds, - uint32 gasOverheadBeforeCallback, - uint32 gasOverheadAfterCallback, - uint32 requestTimeoutSeconds, - uint80 donFee, - uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP, - int256 fallbackNativePerUnitLink - ); + event ConfigChanged(Config config); error UnsupportedRequestDataVersion(); error InsufficientBalance(); @@ -97,93 +63,31 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } // ================================================================ - // | Configuration Methods | + // | Configuration | // ================================================================ - /** - * @notice Sets the configuration of the Chainlink Functions billing registry - * @param config bytes of abi.encoded config data to set the following: - * See the content of the Config struct above - */ + + // @notice Sets the configuration of the Chainlink Functions billing registry + // @param config bytes of abi.encoded config data to set the following: + // See the content of the Config struct above function _updateConfig(bytes memory config) internal override { - ( - uint32 maxCallbackGasLimit, - uint32 feedStalenessSeconds, - uint32 gasOverheadBeforeCallback, - uint32 gasOverheadAfterCallback, - uint32 requestTimeoutSeconds, - uint80 donFee, - uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP, - int256 fallbackNativePerUnitLink - ) = abi.decode(config, (uint32, uint32, uint32, uint32, uint32, uint80, uint16, uint256, int256)); - - if (fallbackNativePerUnitLink <= 0) { - revert InvalidLinkWeiPrice(fallbackNativePerUnitLink); + Config memory _config = abi.decode(config, (Config)); + if (_config.fallbackNativePerUnitLink <= 0) { + revert InvalidLinkWeiPrice(_config.fallbackNativePerUnitLink); } - s_config = Config({ - maxCallbackGasLimit: maxCallbackGasLimit, - feedStalenessSeconds: feedStalenessSeconds, - gasOverheadBeforeCallback: gasOverheadBeforeCallback, - gasOverheadAfterCallback: gasOverheadAfterCallback, - requestTimeoutSeconds: requestTimeoutSeconds, - donFee: donFee, - maxSupportedRequestDataVersion: maxSupportedRequestDataVersion, - fulfillmentGasPriceOverEstimationBP: fulfillmentGasPriceOverEstimationBP, - fallbackNativePerUnitLink: fallbackNativePerUnitLink - }); - emit ConfigChanged( - maxCallbackGasLimit, - feedStalenessSeconds, - gasOverheadBeforeCallback, - gasOverheadAfterCallback, - requestTimeoutSeconds, - donFee, - maxSupportedRequestDataVersion, - fulfillmentGasPriceOverEstimationBP, - fallbackNativePerUnitLink - ); + s_config = _config; + emit ConfigChanged(_config); } - /** - * @inheritdoc IFunctionsBilling - */ - function getConfig() - external - view - override - returns ( - uint32 maxCallbackGasLimit, - uint32 feedStalenessSeconds, - uint32 gasOverheadBeforeCallback, - uint32 gasOverheadAfterCallback, - uint32 requestTimeoutSeconds, - uint80 donFee, - uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP, - int256 fallbackNativePerUnitLink, - address linkPriceFeed - ) - { - return ( - s_config.maxCallbackGasLimit, - s_config.feedStalenessSeconds, - s_config.gasOverheadBeforeCallback, - s_config.gasOverheadAfterCallback, - s_config.requestTimeoutSeconds, - s_config.donFee, - s_config.maxSupportedRequestDataVersion, - s_config.fulfillmentGasPriceOverEstimationBP, - s_config.fallbackNativePerUnitLink, - address(s_linkToNativeFeed) - ); + // @inheritdoc IFunctionsBilling + function getConfig() external view override returns (Config memory) { + return s_config; } // ================================================================ - // | Cost Calculation Methods | + // | Fee Calculation | // ================================================================ - /** - * @inheritdoc IFunctionsBilling - */ + + // @inheritdoc IFunctionsBilling function getDONFee( bytes memory /* requestData */, RequestBilling memory /* billing */ @@ -192,92 +96,101 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { return s_config.donFee; } - /** - * @inheritdoc IFunctionsBilling - */ + // @inheritdoc IFunctionsBilling function getAdminFee() public view override returns (uint96) { - (, uint96 adminFee, , ) = _getRouter().getConfig(); - return adminFee; + return _getRouter().getConfig().adminFee; } - function getFeedData() public view returns (int256) { - uint32 feedStalenessSeconds = s_config.feedStalenessSeconds; - bool staleFallback = feedStalenessSeconds > 0; + // @inheritdoc IFunctionsBilling + function getWeiPerUnitLink() public view returns (uint256) { + Config memory config = s_config; (, int256 weiPerUnitLink, , uint256 timestamp, ) = s_linkToNativeFeed.latestRoundData(); // solhint-disable-next-line not-rely-on-time - if (staleFallback && feedStalenessSeconds < block.timestamp - timestamp) { - weiPerUnitLink = s_config.fallbackNativePerUnitLink; + if (config.feedStalenessSeconds < block.timestamp - timestamp && config.feedStalenessSeconds > 0) { + return uint256(config.fallbackNativePerUnitLink); } - return weiPerUnitLink; + if (weiPerUnitLink <= 0) { + revert InvalidLinkWeiPrice(weiPerUnitLink); + } + return uint256(weiPerUnitLink); + } + + function _getJuelsPerGas(uint256 gasPriceGwei) private view returns (uint256) { + // (1e18 juels/link) * (wei/gas) / (wei/link) = juels per gas + return (1e18 * gasPriceGwei) / getWeiPerUnitLink(); } // ================================================================ - // | Cost Estimation Methods | + // | Cost Estimation | // ================================================================ - /** - * @inheritdoc IFunctionsBilling - */ + + // @inheritdoc IFunctionsBilling function estimateCost( uint64 subscriptionId, bytes calldata data, uint32 callbackGasLimit, - uint256 gasPrice + uint256 gasPriceGwei ) external view override returns (uint96) { - // Reasonable ceilings to prevent integer overflows _getRouter().isValidCallbackGasLimit(subscriptionId, callbackGasLimit); - if (gasPrice > 1_000_000) { + // Reasonable ceilings to prevent integer overflows + if (gasPriceGwei > REASONABLE_GAS_PRICE_CEILING) { revert InvalidCalldata(); } uint96 adminFee = getAdminFee(); - RequestBilling memory billing = RequestBilling(subscriptionId, msg.sender, callbackGasLimit, gasPrice, adminFee); - uint96 donFee = getDONFee(data, billing); - return _calculateCostEstimate(callbackGasLimit, gasPrice, donFee, adminFee); + uint96 donFee = getDONFee( + data, + RequestBilling({ + subscriptionId: subscriptionId, + client: msg.sender, + callbackGasLimit: callbackGasLimit, + expectedGasPrice: gasPriceGwei, + adminFee: adminFee + }) + ); + return _calculateCostEstimate(callbackGasLimit, gasPriceGwei, donFee, adminFee); } - /** - * @notice Uses current price feed data to estimate a cost - */ + // @notice Estimate the cost in Juels of LINK + // that will be charged to a subscription to fulfill a Functions request + // Gas Price can be overestimated to account for flucuations between request and response time function _calculateCostEstimate( uint32 callbackGasLimit, - uint256 gasPrice, + uint256 gasPriceGwei, uint96 donFee, uint96 adminFee ) internal view returns (uint96) { - int256 weiPerUnitLink; - weiPerUnitLink = getFeedData(); - if (weiPerUnitLink <= 0) { - revert InvalidLinkWeiPrice(weiPerUnitLink); - } uint256 executionGas = s_config.gasOverheadBeforeCallback + s_config.gasOverheadAfterCallback + callbackGasLimit; - uint256 gasPriceWithOverestimation = gasPrice + - ((gasPrice * s_config.fulfillmentGasPriceOverEstimationBP) / 10_000); - // (1e18 juels/link) (wei/gas * gas) / (wei/link) = juels - uint256 paymentNoFee = (1e18 * gasPriceWithOverestimation * executionGas) / uint256(weiPerUnitLink); - uint256 fee = uint256(donFee) + uint256(adminFee); - if (paymentNoFee > (1e27 - fee)) { - revert PaymentTooLarge(); // Payment + fee cannot be more than all of the link in existence. - } - return uint96(paymentNoFee + fee); + + uint256 gasPriceWithOverestimation = gasPriceGwei + + ((gasPriceGwei * s_config.fulfillmentGasPriceOverEstimationBP) / 10_000); + // @NOTE: Basis Points are 1/100th of 1%, divide by 10_000 to bring back to original units + + uint256 juelsPerGas = _getJuelsPerGas(gasPriceWithOverestimation); + uint256 estimatedGasReimbursement = juelsPerGas * executionGas; + uint256 fees = uint256(donFee) + uint256(adminFee); + + return uint96(estimatedGasReimbursement + fees); } // ================================================================ - // | Billing Methods | + // | Billing | // ================================================================ - /** - * @notice Initiate the billing process for an Functions request - * @dev Only callable by the Functions Router - * @param data - Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - * @param requestDataVersion - Version number of the structure of the request data - * @param billing - Billing configuration for the request - * @return commitment - The parameters of the request that must be held consistent at response time - */ + + // @notice Initiate the billing process for an Functions request + // @dev Only callable by the Functions Router + // @param data - Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param requestDataVersion - Version number of the structure of the request data + // @param billing - Billing configuration for the request + // @return commitment - The parameters of the request that must be held consistent at response time function _startBilling( bytes memory data, uint16 requestDataVersion, RequestBilling memory billing ) internal returns (FunctionsResponse.Commitment memory commitment) { + Config memory config = s_config; + // Nodes should support all past versions of the structure - if (requestDataVersion > s_config.maxSupportedRequestDataVersion) { + if (requestDataVersion > config.maxSupportedRequestDataVersion) { revert UnsupportedRequestDataVersion(); } @@ -289,15 +202,17 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { donFee, billing.adminFee ); - IFunctionsSubscriptions subscriptions = IFunctionsSubscriptions(address(_getRouter())); - (uint96 balance, , uint96 blockedBalance, , , ) = subscriptions.getSubscription(billing.subscriptionId); - (, uint64 initiatedRequests, ) = subscriptions.getConsumer(billing.client, billing.subscriptionId); - - if (balance - blockedBalance < estimatedCost) { + IFunctionsSubscriptions routerWithSubscriptions = IFunctionsSubscriptions(address(_getRouter())); + IFunctionsSubscriptions.Subscription memory subscription = routerWithSubscriptions.getSubscription( + billing.subscriptionId + ); + if ((subscription.balance - subscription.blockedBalance) < estimatedCost) { revert InsufficientBalance(); } - bytes32 requestId = computeRequestId(address(this), billing.client, billing.subscriptionId, initiatedRequests + 1); + (, uint64 initiatedRequests, ) = routerWithSubscriptions.getConsumer(billing.client, billing.subscriptionId); + + bytes32 requestId = _computeRequestId(address(this), billing.client, billing.subscriptionId, initiatedRequests + 1); commitment = FunctionsResponse.Commitment({ adminFee: billing.adminFee, @@ -306,20 +221,20 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { subscriptionId: billing.subscriptionId, callbackGasLimit: billing.callbackGasLimit, estimatedTotalCostJuels: estimatedCost, - timeoutTimestamp: uint40(block.timestamp + s_config.requestTimeoutSeconds), + timeoutTimestamp: uint40(block.timestamp + config.requestTimeoutSeconds), requestId: requestId, donFee: donFee, - gasOverheadBeforeCallback: s_config.gasOverheadBeforeCallback, - gasOverheadAfterCallback: s_config.gasOverheadAfterCallback + gasOverheadBeforeCallback: config.gasOverheadBeforeCallback, + gasOverheadAfterCallback: config.gasOverheadAfterCallback }); s_requestCommitments[requestId] = keccak256(abi.encode(commitment)); + + return commitment; } - /** - * @notice Generate a keccak hash request ID - */ - function computeRequestId( + // @notice Generate a keccak hash request ID + function _computeRequestId( address don, address client, uint64 subscriptionId, @@ -328,15 +243,13 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { return keccak256(abi.encode(don, client, subscriptionId, nonce)); } - /** - * @notice Finalize billing process for an Functions request by sending a callback to the Client contract and then charging the subscription - * @param requestId identifier for the request that was generated by the Registry in the beginBilling commitment - * @param response response data from DON consensus - * @param err error from DON consensus - * @return result fulfillment result - * @dev Only callable by a node that has been approved on the Coordinator - * @dev simulated offchain to determine if sufficient balance is present to fulfill the request - */ + // @notice Finalize billing process for an Functions request by sending a callback to the Client contract and then charging the subscription + // @param requestId identifier for the request that was generated by the Registry in the beginBilling commitment + // @param response response data from DON consensus + // @param err error from DON consensus + // @return result fulfillment result + // @dev Only callable by a node that has been approved on the Coordinator + // @dev simulated offchain to determine if sufficient balance is present to fulfill the request function _fulfillAndBill( bytes32 requestId, bytes memory response, @@ -345,21 +258,16 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { bytes memory /* offchainMetadata TODO: use in getDonFee() for dynamic billing */ ) internal returns (FunctionsResponse.FulfillResult) { FunctionsResponse.Commitment memory commitment = abi.decode(onchainMetadata, (FunctionsResponse.Commitment)); - if (s_requestCommitments[requestId] == bytes32(0)) { - return FunctionsResponse.FulfillResult.INVALID_REQUEST_ID; - } if (s_requestCommitments[requestId] != keccak256(abi.encode(commitment))) { return FunctionsResponse.FulfillResult.INVALID_COMMITMENT; } - int256 weiPerUnitLink; - weiPerUnitLink = getFeedData(); - if (weiPerUnitLink <= 0) { - revert InvalidLinkWeiPrice(weiPerUnitLink); + if (s_requestCommitments[requestId] == bytes32(0)) { + return FunctionsResponse.FulfillResult.INVALID_REQUEST_ID; } - // (1e18 juels/link) * (wei/gas) / (wei/link) = juels per gas - uint256 juelsPerGas = (1e18 * tx.gasprice) / uint256(weiPerUnitLink); + + uint256 juelsPerGas = _getJuelsPerGas(tx.gasprice); // Gas overhead without callback uint96 gasOverheadJuels = uint96( juelsPerGas * (commitment.gasOverheadBeforeCallback + commitment.gasOverheadAfterCallback) @@ -375,6 +283,9 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { commitment ); + // The router will only pay the DON on successfully processing the fulfillment + // In these two fulfillment results the user has been charged + // Otherwise, the Coordinator should hold on to the request commitment if ( resultCode == FunctionsResponse.FulfillResult.USER_SUCCESS || resultCode == FunctionsResponse.FulfillResult.USER_ERROR @@ -391,11 +302,11 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } // ================================================================ - // | Request Timeout Methods | + // | Request Timeout | // ================================================================ - /** - * @inheritdoc IFunctionsBilling - */ + + // @inheritdoc IFunctionsBilling + // @dev used by FunctionsRouter.sol during timeout of a request function deleteCommitment(bytes32 requestId) external override onlyRouter returns (bool) { // Ensure that commitment exists if (s_requestCommitments[requestId] == bytes32(0)) { @@ -408,30 +319,47 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } // ================================================================ - // | Node Operator methods | + // | Fund withdrawal | // ================================================================ - /* - * @notice Oracle withdraw LINK earned through fulfilling requests - * @notice If amount is 0 the full balance will be withdrawn - * @notice Both signing and transmitting wallets will have a balance to withdraw - * @param recipient where to send the funds - * @param amount amount to withdraw - */ + + // @inheritdoc IFunctionsBilling function oracleWithdraw(address recipient, uint96 amount) external { _disperseFeePool(); if (amount == 0) { amount = s_withdrawableTokens[msg.sender]; - } - if (s_withdrawableTokens[msg.sender] < amount) { + } else if (s_withdrawableTokens[msg.sender] < amount) { revert InsufficientBalance(); } s_withdrawableTokens[msg.sender] -= amount; - IFunctionsSubscriptions router = IFunctionsSubscriptions(address(_getRouter())); - router.oracleWithdraw(recipient, amount); + IFunctionsSubscriptions(address(_getRouter())).oracleWithdraw(recipient, amount); + } + + // @inheritdoc IFunctionsBilling + // @dev Only callable by the Coordinator owner + function oracleWithdrawAll() external { + _onlyOwner(); + _disperseFeePool(); + + address[] memory transmitters = _getTransmitters(); + + // Bounded by "maxNumOracles" on OCR2Abstract.sol + for (uint256 i = 0; i < transmitters.length; ++i) { + uint96 balance = s_withdrawableTokens[msg.sender]; + s_withdrawableTokens[msg.sender] = 0; + IFunctionsSubscriptions(address(_getRouter())).oracleWithdraw(transmitters[i], balance); + } } + // Overriden in FunctionsCoordinator, which has visibility into transmitters + function _getTransmitters() internal view virtual returns (address[] memory); + + // DON fees are collected into a pool s_feePool + // When OCR configuration changes, or any oracle withdraws, this must be dispersed function _disperseFeePool() internal { + if (s_feePool == 0) { + return; + } // All transmitters are assumed to also be observers // Pay out the DON fee to all transmitters address[] memory transmitters = _getTransmitters(); @@ -446,5 +374,6 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { s_feePool -= feePoolShare * uint96(transmitters.length); } - function _getTransmitters() internal view virtual returns (address[] memory); + // Overriden in FunctionsCoordinator.sol + function _onlyOwner() internal view virtual; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 179437ebb4d..34cd8d2aac2 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -9,11 +9,9 @@ import {FunctionsBilling} from "./FunctionsBilling.sol"; import {OCR2Base} from "./ocr/OCR2Base.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; -/** - * @title Functions Coordinator contract - * @notice Contract that nodes of a Decentralized Oracle Network (DON) interact with - * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. - */ +// @title Functions Coordinator contract +// @notice Contract that nodes of a Decentralized Oracle Network (DON) interact with +// @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilling { using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; @@ -50,9 +48,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli address linkToNativeFeed ) OCR2Base(true) FunctionsBilling(router, config, linkToNativeFeed) {} - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function getThresholdPublicKey() external view override returns (bytes memory) { if (s_thresholdPublicKey.length == 0) { revert EmptyPublicKey(); @@ -60,9 +56,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli return s_thresholdPublicKey; } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function setThresholdPublicKey(bytes calldata thresholdPublicKey) external override onlyOwner { if (thresholdPublicKey.length == 0) { revert EmptyPublicKey(); @@ -70,9 +64,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli s_thresholdPublicKey = thresholdPublicKey; } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function getDONPublicKey() external view override returns (bytes memory) { if (s_donPublicKey.length == 0) { revert EmptyPublicKey(); @@ -80,9 +72,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli return s_donPublicKey; } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function setDONPublicKey(bytes calldata donPublicKey) external override onlyOwner { if (donPublicKey.length == 0) { revert EmptyPublicKey(); @@ -90,9 +80,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli s_donPublicKey = donPublicKey; } - /** - * @dev check if node is in current transmitter list - */ + // @dev check if node is in current transmitter list function _isTransmitter(address node) internal view returns (bool) { address[] memory nodes = s_transmitters; // Bounded by "maxNumOracles" on OCR2Abstract.sol @@ -104,9 +92,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli return false; } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function setNodePublicKey(address node, bytes calldata publicKey) external override { // Owner can set anything. Transmitters can set only their own key. if (!(msg.sender == owner() || (_isTransmitter(msg.sender) && msg.sender == node))) { @@ -115,9 +101,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli s_nodePublicKeys[node] = publicKey; } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function deleteNodePublicKey(address node) external override { // Owner can delete anything. Others can delete only their own key. if (msg.sender != owner() && msg.sender != node) { @@ -126,25 +110,22 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli delete s_nodePublicKeys[node]; } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function getAllNodePublicKeys() external view override returns (address[] memory, bytes[] memory) { address[] memory nodes = s_transmitters; bytes[] memory keys = new bytes[](nodes.length); // Bounded by "maxNumOracles" on OCR2Abstract.sol for (uint256 i = 0; i < nodes.length; ++i) { - if (s_nodePublicKeys[nodes[i]].length == 0) { + bytes memory nodePublicKey = s_nodePublicKeys[nodes[i]]; + if (nodePublicKey.length == 0) { revert EmptyPublicKey(); } - keys[i] = s_nodePublicKeys[nodes[i]]; + keys[i] = nodePublicKey; } return (nodes, keys); } - /** - * @inheritdoc IFunctionsCoordinator - */ + // @inheritdoc IFunctionsCoordinator function sendRequest( Request calldata request ) external override onlyRouter returns (FunctionsResponse.Commitment memory commitment) { @@ -188,6 +169,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli return s_transmitters; } + // Report hook called within OCR2Base.sol function _report( uint256 /*initialGas*/, address /*transmitter*/, @@ -204,6 +186,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli report, (bytes32[], bytes[], bytes[], bytes[], bytes[]) ); + if ( requestIds.length == 0 || requestIds.length != results.length || @@ -220,6 +203,9 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli _fulfillAndBill(requestIds[i], results[i], errors[i], onchainMetadata[i], offchainMetadata[i]) ); + // Emit on successfully processing the fulfillment + // In these two fulfillment results the user has been charged + // Otherwise, the DON will re-try if ( result == FunctionsResponse.FulfillResult.USER_SUCCESS || result == FunctionsResponse.FulfillResult.USER_ERROR ) { @@ -227,4 +213,9 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli } } } + + // Used in FunctionsBilling.sol + function _onlyOwner() internal view override { + _validateOwnership(); + } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index eb0dd1d84f9..be626f70b97 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -5,18 +5,19 @@ import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; +import {IConfigurable} from "./interfaces/IConfigurable.sol"; -import {RouterBase} from "./RouterBase.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; +import {ConfirmedOwner} from "../../../ConfirmedOwner.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; -contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions { +contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, ITypeAndVersion, ConfirmedOwner { using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; - // @inheritdoc ITypeAndVersion string public constant override typeAndVersion = "Functions Router v1.0.0"; // We limit return data to a selector plus 4 words. This is to avoid @@ -24,6 +25,13 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // repeated out-of-gas scenarios. uint16 public constant MAX_CALLBACK_RETURN_BYTES = 4 + 4 * 32; + mapping(bytes32 id => address routableContract) private s_route; + + error RouteNotFound(bytes32 id); + + // Use empty bytes to self-identify, since it does not have an id + bytes32 private constant ROUTER_ID = bytes32(0); + event RequestStart( bytes32 indexed requestId, bytes32 indexed donId, @@ -33,7 +41,8 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions address requestInitiator, bytes data, uint16 dataVersion, - uint32 callbackGasLimit + uint32 callbackGasLimit, + uint96 estimatedTotalCostJuels ); event RequestProcessed( @@ -73,74 +82,155 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // ================================================================ Config private s_config; - event ConfigChanged(uint96 adminFee, bytes4 handleOracleFulfillmentSelector, uint32[] maxCallbackGasLimits); + event ConfigChanged(Config); error OnlyCallableByRoute(); // ================================================================ - // | Initialization | + // | Timelock state | // ================================================================ + uint16 private immutable s_maximumTimelockBlocks; + uint16 private s_timelockBlocks; + + struct TimeLockProposal { + uint16 from; + uint16 to; + uint64 timelockEndBlock; + } + + TimeLockProposal private s_timelockProposal; + + event TimeLockProposed(uint16 from, uint16 to); + event TimeLockUpdated(uint16 from, uint16 to); + error ProposedTimelockAboveMaximum(); + error TimelockInEffect(); + + // ================================================================ + // | Proposal state | + // ================================================================ + + uint8 private constant MAX_PROPOSAL_SET_LENGTH = 8; + + struct ContractProposalSet { + bytes32[] ids; + address[] to; + uint64 timelockEndBlock; + } + ContractProposalSet private s_proposedContractSet; + + event ContractProposed( + bytes32 proposedContractSetId, + address proposedContractSetFromAddress, + address proposedContractSetToAddress, + uint64 timelockEndBlock + ); + + event ContractUpdated(bytes32 id, address from, address to); + + struct ConfigProposal { + bytes to; + uint64 timelockEndBlock; + } + mapping(bytes32 id => ConfigProposal) private s_proposedConfig; + event ConfigProposed(bytes32 id, bytes toBytes); + event ConfigUpdated(bytes32 id, bytes toBytes); + error InvalidProposal(); + error IdentifierIsReserved(bytes32 id); + constructor( uint16 timelockBlocks, uint16 maximumTimelockBlocks, address linkToken, - bytes memory config - ) RouterBase(msg.sender, timelockBlocks, maximumTimelockBlocks, config) FunctionsSubscriptions(linkToken) {} - - // ================================================================ - // | Getters | - // ================================================================ + Config memory config + ) FunctionsSubscriptions(linkToken) ConfirmedOwner(msg.sender) Pausable() { + // Set initial value for the number of blocks of the timelock + s_timelockBlocks = timelockBlocks; + // Set maximum number of blocks that the timelock can be + s_maximumTimelockBlocks = maximumTimelockBlocks; + // Set the initial configuration for the Router + s_route[ROUTER_ID] = address(this); + _updateConfig(config); + } // @inheritdoc IFunctionsRouter function getAllowListId() external pure override returns (bytes32) { return ALLOW_LIST_ID; } + // ================================================================ + // | Configuration | + // ================================================================ + // @inheritdoc IFunctionsRouter - function getConfig() - external - view - override - returns ( - uint16 maxConsumersPerSubscription, - uint96 adminFee, - bytes4 handleOracleFulfillmentSelector, - uint32[] memory maxCallbackGasLimits - ) - { - maxConsumersPerSubscription = s_config.maxConsumersPerSubscription; - adminFee = s_config.adminFee; - handleOracleFulfillmentSelector = s_config.handleOracleFulfillmentSelector; - maxCallbackGasLimits = s_config.maxCallbackGasLimits; + function getConfig() external view override returns (Config memory) { + return s_config; + } - return (maxConsumersPerSubscription, adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits); + // @inheritdoc IRouterBase + function proposeConfigUpdateSelf(bytes calldata config) external override onlyOwner { + s_proposedConfig[ROUTER_ID] = ConfigProposal({ + to: config, + timelockEndBlock: uint64(block.number + s_timelockBlocks) + }); + emit ConfigProposed({id: ROUTER_ID, toBytes: config}); } - // ================================================================ - // | Configuration methods | - // ================================================================ + // @inheritdoc IRouterBase + function updateConfigSelf() external override onlyOwner { + ConfigProposal memory proposal = s_proposedConfig[ROUTER_ID]; + if (block.number < proposal.timelockEndBlock) { + revert TimelockInEffect(); + } + _updateConfig(abi.decode(proposal.to, (Config))); + emit ConfigUpdated({id: ROUTER_ID, toBytes: proposal.to}); + } + + // @inheritdoc IRouterBase + function proposeConfigUpdate(bytes32 id, bytes calldata config) external override onlyOwner { + s_proposedConfig[id] = ConfigProposal({to: config, timelockEndBlock: uint64(block.number + s_timelockBlocks)}); + emit ConfigProposed({id: id, toBytes: config}); + } + + // @inheritdoc IRouterBase + function updateConfig(bytes32 id) external override onlyOwner { + ConfigProposal memory proposal = s_proposedConfig[id]; + + if (block.number < proposal.timelockEndBlock) { + revert TimelockInEffect(); + } + + IConfigurable(getContractById(id)).updateConfig(proposal.to); + + emit ConfigUpdated({id: id, toBytes: proposal.to}); + } // @notice Sets the configuration for FunctionsRouter specific state // @param config bytes of config data to set the following: // - adminFee: fee that will be paid to the Router owner for operating the network - function _updateConfig(bytes memory config) internal override { - ( - uint16 maxConsumersPerSubscription, - uint96 adminFee, - bytes4 handleOracleFulfillmentSelector, - uint32[] memory maxCallbackGasLimits - ) = abi.decode(config, (uint16, uint96, bytes4, uint32[])); - s_config = Config({ - maxConsumersPerSubscription: maxConsumersPerSubscription, - adminFee: adminFee, - handleOracleFulfillmentSelector: handleOracleFulfillmentSelector, - maxCallbackGasLimits: maxCallbackGasLimits - }); - emit ConfigChanged(adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits); + function _updateConfig(Config memory config) internal { + s_config = config; + emit ConfigChanged(config); + } + + // @inheritdoc IFunctionsRouter + function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) public view { + uint8 callbackGasLimitsIndexSelector = uint8(getFlags(subscriptionId)[MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX]); + if (callbackGasLimitsIndexSelector >= s_config.maxCallbackGasLimits.length) { + revert InvalidGasFlagValue(callbackGasLimitsIndexSelector); + } + uint32 maxCallbackGasLimit = s_config.maxCallbackGasLimits[callbackGasLimitsIndexSelector]; + if (callbackGasLimit > maxCallbackGasLimit) { + revert GasLimitTooBig(maxCallbackGasLimit); + } + } + + // Used within FunctionsSubscriptions.sol + function _getMaxConsumers() internal view override returns (uint16) { + return s_config.maxConsumersPerSubscription; } // ================================================================ - // | Request methods | + // | Requests | // ================================================================ // @inheritdoc IFunctionsRouter @@ -224,12 +314,17 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions requestInitiator: tx.origin, data: data, dataVersion: dataVersion, - callbackGasLimit: callbackGasLimit + callbackGasLimit: callbackGasLimit, + estimatedTotalCostJuels: commitment.estimatedTotalCostJuels }); return commitment.requestId; } + // ================================================================ + // | Responses | + // ================================================================ + // @inheritdoc IFunctionsRouter function fulfill( bytes memory response, @@ -370,7 +465,7 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions if iszero(gt(sub(g, div(g, 64)), callbackGasLimit)) { revert(0, 0) } - // call and whether we succeeded + // call and report whether we succeeded // call(gas,addr,value,argsOffset,argsLength,retOffset,retLength) success := call(callbackGasLimit, client, 0, add(encodedCallback, 0x20), mload(encodedCallback), 0, 0) gasUsed := sub(g, gas()) @@ -389,20 +484,136 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions return CallbackResult({success: success, gasUsed: gasUsed, returnData: returnData}); } - // @inheritdoc IFunctionsRouter - function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) public view { - uint8 callbackGasLimitsIndexSelector = uint8(getFlags(subscriptionId)[MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX]); - if (callbackGasLimitsIndexSelector >= s_config.maxCallbackGasLimits.length) { - revert InvalidGasFlagValue(callbackGasLimitsIndexSelector); + // ================================================================ + // | Route methods | + // ================================================================ + + // @inheritdoc IRouterBase + function getContractById(bytes32 id) public view override returns (address) { + address currentImplementation = s_route[id]; + if (currentImplementation == address(0)) { + revert RouteNotFound(id); } - uint32 maxCallbackGasLimit = s_config.maxCallbackGasLimits[callbackGasLimitsIndexSelector]; - if (callbackGasLimit > maxCallbackGasLimit) { - revert GasLimitTooBig(maxCallbackGasLimit); + return currentImplementation; + } + + // @inheritdoc IRouterBase + function getProposedContractById(bytes32 id) public view override returns (address) { + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { + if (id == s_proposedContractSet.ids[i]) { + return s_proposedContractSet.to[i]; + } } + revert RouteNotFound(id); } - function _getMaxConsumers() internal view override returns (uint16) { - return s_config.maxConsumersPerSubscription; + // ================================================================ + // | Timelock | + // ================================================================ + + // removed in anticipation of using MCM + // TODO: fully remove + + // @inheritdoc IRouterBase + // function proposeTimelockBlocks(uint16 blocks) external override onlyOwner { + // if (s_timelockBlocks == blocks) { + // revert InvalidProposal(); + // } + // if (blocks > s_maximumTimelockBlocks) { + // revert ProposedTimelockAboveMaximum(); + // } + // s_timelockProposal = TimeLockProposal({ + // from: s_timelockBlocks, + // to: blocks, + // timelockEndBlock: uint64(block.number + s_timelockBlocks) + // }); + // } + + // @inheritdoc IRouterBase + // function updateTimelockBlocks() external override onlyOwner { + // if (block.number < s_timelockProposal.timelockEndBlock) { + // revert TimelockInEffect(); + // } + // s_timelockBlocks = s_timelockProposal.to; + // } + + // ================================================================ + // | Contract Proposal methods | + // ================================================================ + + // @inheritdoc IRouterBase + function getProposedContractSet() + external + view + override + returns (uint256 timelockEndBlock, bytes32[] memory ids, address[] memory to) + { + timelockEndBlock = s_proposedContractSet.timelockEndBlock; + ids = s_proposedContractSet.ids; + to = s_proposedContractSet.to; + return (timelockEndBlock, ids, to); + } + + // @inheritdoc IRouterBase + function proposeContractsUpdate( + bytes32[] memory proposedContractSetIds, + address[] memory proposedContractSetAddresses + ) external override onlyOwner { + // All arrays must be of equal length and not must not exceed the max length + uint256 idsArrayLength = proposedContractSetIds.length; + if (idsArrayLength != proposedContractSetAddresses.length || idsArrayLength > MAX_PROPOSAL_SET_LENGTH) { + revert InvalidProposal(); + } + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint256 i = 0; i < idsArrayLength; ++i) { + bytes32 id = proposedContractSetIds[i]; + address proposedContract = proposedContractSetAddresses[i]; + if ( + proposedContract == address(0) || // The Proposed address must be a valid address + s_route[id] == proposedContract // The Proposed address must point to a different address than what is currently set + ) { + revert InvalidProposal(); + } + // Reserved ids cannot be set + if (id == ROUTER_ID) { + revert IdentifierIsReserved(id); + } + } + + uint64 timelockEndBlock = uint64(block.number + s_timelockBlocks); + + s_proposedContractSet = ContractProposalSet({ + ids: proposedContractSetIds, + to: proposedContractSetAddresses, + timelockEndBlock: timelockEndBlock + }); + + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint256 i = 0; i < proposedContractSetIds.length; ++i) { + emit ContractProposed({ + proposedContractSetId: proposedContractSetIds[i], + proposedContractSetFromAddress: s_route[proposedContractSetIds[i]], + proposedContractSetToAddress: proposedContractSetAddresses[i], + timelockEndBlock: timelockEndBlock + }); + } + } + + // @inheritdoc IRouterBase + function updateContracts() external override onlyOwner { + if (block.number < s_proposedContractSet.timelockEndBlock) { + revert TimelockInEffect(); + } + // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { + bytes32 id = s_proposedContractSet.ids[i]; + address to = s_proposedContractSet.to[i]; + emit ContractUpdated({id: id, from: s_route[id], to: to}); + s_route[id] = to; + } + + delete s_proposedContractSet; } // ================================================================ @@ -422,8 +633,23 @@ contract FunctionsRouter is RouterBase, IFunctionsRouter, FunctionsSubscriptions // Used within FunctionsSubscriptions.sol function _onlySenderThatAcceptedToS() internal view override { - if (!IAccessController(getContractById(ALLOW_LIST_ID)).hasAccess(msg.sender, new bytes(0))) { + address currentImplementation = s_route[ALLOW_LIST_ID]; + if (currentImplementation == address(0)) { + // If not set, ignore this check + return; + } + if (!IAccessController(currentImplementation).hasAccess(msg.sender, new bytes(0))) { revert SenderMustAcceptTermsOfService(msg.sender); } } + + // @inheritdoc IRouterBase + function pause() external override onlyOwner { + _pause(); + } + + // @inheritdoc IRouterBase + function unpause() external override onlyOwner { + _unpause(); + } } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index edfa91f2c36..2782dc7f99c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -3,37 +3,43 @@ pragma solidity ^0.8.19; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; -import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; +import {IERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol"; +import {SafeERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; -/** - * @title Functions Subscriptions contract - * @notice Contract that coordinates payment from users to the nodes of the Decentralized Oracle Network (DON). - * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. - */ +// @title Functions Subscriptions contract +// @notice Contract that coordinates payment from users to the nodes of the Decentralized Oracle Network (DON). +// @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677ReceiverInterface { + using SafeERC20 for IERC20; using FunctionsResponse for FunctionsResponse.Commitment; + // ================================================================ - // | Subscription state | + // | Balance state | // ================================================================ + // link token address + address internal immutable i_linkToken; - // We make the sub count public so that its possible to - // get all the current subscriptions via getSubscription. - uint64 private s_currentSubscriptionId; - - // s_totalBalance tracks the total LINK sent to/from + // s_totalLinkBalance tracks the total LINK sent to/from // this contract through onTokenTransfer, cancelSubscription and oracleWithdraw. // A discrepancy with this contract's LINK balance indicates that someone // sent tokens using transfer and so we may need to use recoverFunds. - uint96 private s_totalBalance; + uint96 private s_totalLinkBalance; - // link token address - LinkTokenInterface private s_linkToken; + // @dev NOP balances are held as a single amount. The breakdown is held by the Coordinator. + mapping(address coordinator => uint96 balanceJuelsLink) private s_withdrawableTokens; + + // ================================================================ + // | Subscription state | + // ================================================================ + // Keep a count of the number of subscriptions so that its possible to + // loop through all the current subscriptions via .getSubscription(). + uint64 private s_currentSubscriptionId; mapping(uint64 subscriptionId => IFunctionsSubscriptions.Subscription) internal s_subscriptions; mapping(address consumer => mapping(uint64 subscriptionId => IFunctionsSubscriptions.Consumer)) internal s_consumers; @@ -55,13 +61,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei error InvalidCalldata(); error MustBeSubscriptionOwner(); error PendingRequestExists(); - error MustBeProposedOwner(); + error MustBeProposedOwner(address proposedOwner); error BalanceInvariantViolated(uint256 internalBalance, uint256 externalBalance); // Should never happen event FundsRecovered(address to, uint256 amount); - // @dev NOP balances are held as a single amount. The breakdown is held by the Coordinator. - mapping(address coordinator => uint96 balanceJuelsLink) private s_withdrawableTokens; - // ================================================================ // | Request state | // ================================================================ @@ -79,91 +82,15 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // | Initialization | // ================================================================ constructor(address link) { - s_linkToken = LinkTokenInterface(link); + i_linkToken = link; } // ================================================================ - // | Getter methods | + // | Request/Response | // ================================================================ - /** - * @inheritdoc IFunctionsSubscriptions - */ - function getTotalBalance() external view override returns (uint96) { - return s_totalBalance; - } - - /** - * @inheritdoc IFunctionsSubscriptions - */ - function getSubscriptionCount() external view override returns (uint64) { - return s_currentSubscriptionId; - } - - /** - * @inheritdoc IFunctionsSubscriptions - */ - function getSubscription( - uint64 subscriptionId - ) - external - view - override - returns ( - uint96 balance, - address owner, - uint96 blockedBalance, - address requestedOwner, - address[] memory consumers, - bytes32 flags - ) - { - _isValidSubscription(subscriptionId); - - balance = s_subscriptions[subscriptionId].balance; - owner = s_subscriptions[subscriptionId].owner; - blockedBalance = s_subscriptions[subscriptionId].blockedBalance; - requestedOwner = s_subscriptions[subscriptionId].requestedOwner; - consumers = s_subscriptions[subscriptionId].consumers; - flags = s_subscriptions[subscriptionId].flags; - - return (balance, owner, blockedBalance, requestedOwner, consumers, flags); - } - /** - * @inheritdoc IFunctionsSubscriptions - */ - function getConsumer( - address client, - uint64 subscriptionId - ) external view override returns (bool allowed, uint64 initiatedRequests, uint64 completedRequests) { - allowed = s_consumers[client][subscriptionId].allowed; - initiatedRequests = s_consumers[client][subscriptionId].initiatedRequests; - completedRequests = s_consumers[client][subscriptionId].completedRequests; - } - - // ================================================================ - // | Internal validity checks | - // ================================================================ - - function _isValidSubscription(uint64 subscriptionId) internal view { - if (s_subscriptions[subscriptionId].owner == address(0)) { - revert InvalidSubscription(); - } - } - - function _isValidConsumer(address client, uint64 subscriptionId) internal view { - if (!s_consumers[client][subscriptionId].allowed) { - revert InvalidConsumer(); - } - } - - // ================================================================ - // | Internal Payment methods | - // ================================================================ - /** - * @notice Sets a request as in-flight - * @dev Only callable within the Router - */ + // @notice Sets a request as in-flight + // @dev Only callable within the Router function _markRequestInFlight(address client, uint64 subscriptionId, uint96 estimatedTotalCostJuels) internal { // Earmark subscription funds s_subscriptions[subscriptionId].blockedBalance += estimatedTotalCostJuels; @@ -172,10 +99,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei s_consumers[client][subscriptionId].initiatedRequests += 1; } - /** - * @notice Moves funds from one subscription account to another. - * @dev Only callable by the Coordinator contract that is saved in the request commitment - */ + // @notice Moves funds from one subscription account to another. + // @dev Only callable by the Coordinator contract that is saved in the request commitment function _pay( uint64 subscriptionId, uint96 estimatedTotalCostJuels, @@ -193,14 +118,15 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // Charge the subscription s_subscriptions[subscriptionId].balance -= totalCostJuels; + // Unblock earmarked funds + s_subscriptions[subscriptionId].blockedBalance -= estimatedTotalCostJuels; + // Pay the DON's fees and gas reimbursement s_withdrawableTokens[msg.sender] += costWithoutCallbackJuels + callbackGasCostJuels; // Pay out the administration fee s_withdrawableTokens[address(this)] += adminFee; - // Unblock earmarked funds - s_subscriptions[subscriptionId].blockedBalance -= estimatedTotalCostJuels; // Increment finished requests s_consumers[client][subscriptionId].completedRequests += 1; @@ -210,62 +136,35 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // ================================================================ // | Owner methods | // ================================================================ - /** - * @inheritdoc IFunctionsSubscriptions - */ + + // @inheritdoc IFunctionsSubscriptions function ownerCancelSubscription(uint64 subscriptionId) external override { _onlyRouterOwner(); _isValidSubscription(subscriptionId); _cancelSubscriptionHelper(subscriptionId, s_subscriptions[subscriptionId].owner); } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function recoverFunds(address to) external override { _onlyRouterOwner(); - uint256 externalBalance = s_linkToken.balanceOf(address(this)); - uint256 internalBalance = uint256(s_totalBalance); + uint256 externalBalance = IERC20(i_linkToken).balanceOf(address(this)); + uint256 internalBalance = uint256(s_totalLinkBalance); if (internalBalance > externalBalance) { revert BalanceInvariantViolated(internalBalance, externalBalance); } if (internalBalance < externalBalance) { uint256 amount = externalBalance - internalBalance; - s_linkToken.transfer(to, amount); + IERC20(i_linkToken).safeTransfer(to, amount); emit FundsRecovered(to, amount); } // If the balances are equal, nothing to be done. } - /** - * @notice Owner withdraw LINK earned through admin fees - * @notice If amount is 0 the full balance will be withdrawn - * @param recipient where to send the funds - * @param amount amount to withdraw - */ - function ownerWithdraw(address recipient, uint96 amount) external { - _onlyRouterOwner(); - if (amount == 0) { - amount = s_withdrawableTokens[address(this)]; - } - if (s_withdrawableTokens[address(this)] < amount) { - revert InsufficientBalance(); - } - s_withdrawableTokens[address(this)] -= amount; - s_totalBalance -= amount; - if (!s_linkToken.transfer(recipient, amount)) { - uint256 externalBalance = s_linkToken.balanceOf(address(this)); - uint256 internalBalance = uint256(s_totalBalance); - revert BalanceInvariantViolated(internalBalance, externalBalance); - } - } - // ================================================================ - // | Coordinator methods | + // | Fund withdrawal | // ================================================================ - /** - * @inheritdoc IFunctionsSubscriptions - */ + + // @inheritdoc IFunctionsSubscriptions function oracleWithdraw(address recipient, uint96 amount) external override { _whenNotPaused(); @@ -276,18 +175,36 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei revert InsufficientBalance(); } s_withdrawableTokens[msg.sender] -= amount; - s_totalBalance -= amount; - if (!s_linkToken.transfer(recipient, amount)) { + s_totalLinkBalance -= amount; + IERC20(i_linkToken).safeTransfer(recipient, amount); + } + + // @notice Owner withdraw LINK earned through admin fees + // @notice If amount is 0 the full balance will be withdrawn + // @param recipient where to send the funds + // @param amount amount to withdraw + function ownerWithdraw(address recipient, uint96 amount) external { + _onlyRouterOwner(); + if (amount == 0) { + amount = s_withdrawableTokens[address(this)]; + } + if (s_withdrawableTokens[address(this)] < amount) { revert InsufficientBalance(); } + s_withdrawableTokens[address(this)] -= amount; + s_totalLinkBalance -= amount; + + IERC20(i_linkToken).safeTransfer(recipient, amount); } // ================================================================ - // | Deposit helper method | + // | TransferAndCall Deposit helper | // ================================================================ + + // This function is to be invoked when using LINK.transferAndCall function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override { _whenNotPaused(); - if (msg.sender != address(s_linkToken)) { + if (msg.sender != address(i_linkToken)) { revert OnlyCallableFromLink(); } if (data.length != 32) { @@ -301,16 +218,55 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // anyone can fund a subscription. uint256 oldBalance = s_subscriptions[subscriptionId].balance; s_subscriptions[subscriptionId].balance += uint96(amount); - s_totalBalance += uint96(amount); + s_totalLinkBalance += uint96(amount); emit SubscriptionFunded(subscriptionId, oldBalance, oldBalance + amount); } // ================================================================ - // | Subscription methods | + // | Subscriptions management | // ================================================================ - /** - * @inheritdoc IFunctionsSubscriptions - */ + + // @inheritdoc IFunctionsSubscriptions + function getTotalBalance() external view override returns (uint96) { + return s_totalLinkBalance; + } + + // @inheritdoc IFunctionsSubscriptions + function getSubscriptionCount() external view override returns (uint64) { + return s_currentSubscriptionId; + } + + // @inheritdoc IFunctionsSubscriptions + function getSubscription(uint64 subscriptionId) external view override returns (Subscription memory) { + _isValidSubscription(subscriptionId); + return s_subscriptions[subscriptionId]; + } + + // @inheritdoc IFunctionsSubscriptions + function getConsumer( + address client, + uint64 subscriptionId + ) external view override returns (bool allowed, uint64 initiatedRequests, uint64 completedRequests) { + allowed = s_consumers[client][subscriptionId].allowed; + initiatedRequests = s_consumers[client][subscriptionId].initiatedRequests; + completedRequests = s_consumers[client][subscriptionId].completedRequests; + } + + // Used within this file & FunctionsRouter.sol + function _isValidSubscription(uint64 subscriptionId) internal view { + if (s_subscriptions[subscriptionId].owner == address(0)) { + revert InvalidSubscription(); + } + } + + // Used within FunctionsRouter.sol + function _isValidConsumer(address client, uint64 subscriptionId) internal view { + if (!s_consumers[client][subscriptionId].allowed) { + revert InvalidConsumer(); + } + } + + // @inheritdoc IFunctionsSubscriptions function createSubscription() external override returns (uint64 subscriptionId) { _whenNotPaused(); _onlySenderThatAcceptedToS(); @@ -320,7 +276,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei balance: 0, blockedBalance: 0, owner: msg.sender, - requestedOwner: address(0), + proposedOwner: address(0), consumers: new address[](0), flags: bytes32(0) }); @@ -330,9 +286,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei return subscriptionId; } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function proposeSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); @@ -340,31 +294,28 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei // Proposing to address(0) would never be claimable, so don't need to check. - if (s_subscriptions[subscriptionId].requestedOwner != newOwner) { - s_subscriptions[subscriptionId].requestedOwner = newOwner; + if (s_subscriptions[subscriptionId].proposedOwner != newOwner) { + s_subscriptions[subscriptionId].proposedOwner = newOwner; emit SubscriptionOwnerTransferRequested(subscriptionId, msg.sender, newOwner); } } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external override { _whenNotPaused(); _onlySenderThatAcceptedToS(); address previousOwner = s_subscriptions[subscriptionId].owner; - if (s_subscriptions[subscriptionId].requestedOwner != msg.sender) { - revert MustBeProposedOwner(); + address proposedOwner = s_subscriptions[subscriptionId].proposedOwner; + if (proposedOwner != msg.sender) { + revert MustBeProposedOwner(proposedOwner); } s_subscriptions[subscriptionId].owner = msg.sender; - s_subscriptions[subscriptionId].requestedOwner = address(0); + s_subscriptions[subscriptionId].proposedOwner = address(0); emit SubscriptionOwnerTransferred(subscriptionId, previousOwner, msg.sender); } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function removeConsumer(uint64 subscriptionId, address consumer) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); @@ -392,9 +343,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei emit SubscriptionConsumerRemoved(subscriptionId, consumer); } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // overriden in FunctionsRouter.sol + function _getMaxConsumers() internal view virtual returns (uint16); + + // @inheritdoc IFunctionsSubscriptions function addConsumer(uint64 subscriptionId, address consumer) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); @@ -415,9 +367,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei emit SubscriptionConsumerAdded(subscriptionId, consumer); } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function cancelSubscription(uint64 subscriptionId, address to) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); @@ -439,16 +389,14 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei delete s_consumers[subscription.consumers[i]][subscriptionId]; } delete s_subscriptions[subscriptionId]; - s_totalBalance -= balance; - if (!s_linkToken.transfer(to, uint256(balance))) { - revert InsufficientBalance(); - } + s_totalLinkBalance -= balance; + + IERC20(i_linkToken).safeTransfer(to, uint256(balance)); + emit SubscriptionCanceled(subscriptionId, to, balance); } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function pendingRequestExists(uint64 subscriptionId) public view override returns (bool) { address[] memory consumers = s_subscriptions[subscriptionId].consumers; // Iterations will not exceed config.maxConsumers @@ -461,30 +409,23 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei return false; } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function setFlags(uint64 subscriptionId, bytes32 flags) external override { _onlyRouterOwner(); _isValidSubscription(subscriptionId); s_subscriptions[subscriptionId].flags = flags; } - /** - * @inheritdoc IFunctionsSubscriptions - */ + // @inheritdoc IFunctionsSubscriptions function getFlags(uint64 subscriptionId) public view returns (bytes32) { return s_subscriptions[subscriptionId].flags; } - function _getMaxConsumers() internal view virtual returns (uint16); - // ================================================================ - // | Request Timeout Methods | + // | Request Timeout | // ================================================================ - /** - * @inheritdoc IFunctionsSubscriptions - */ + + // @inheritdoc IFunctionsSubscriptions function timeoutRequests(FunctionsResponse.Commitment[] calldata requestsToTimeoutByCommitment) external override { _whenNotPaused(); @@ -528,9 +469,12 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677Recei } } + // Overriden in FunctionsRouter.sol function _onlySenderThatAcceptedToS() internal virtual; + // Overriden in FunctionsRouter.sol function _onlyRouterOwner() internal virtual; + // Overriden in FunctionsRouter.sol function _whenNotPaused() internal virtual; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index cc057732b76..57b875bb52d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -5,12 +5,10 @@ import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IOwnableFunctionsRouter} from "./interfaces/IOwnableFunctionsRouter.sol"; -/** - * @title This abstract should be inherited by contracts that will be used - * as the destinations to a route (id=>contract) on the Router. - * It provides a Router getter and modifiers - * and enforces that the Router can update the configuration of this contract - */ +// @title This abstract should be inherited by contracts that will be used +// as the destinations to a route (id=>contract) on the Router. +// It provides a Router getter and modifiers +// and enforces that the Router can update the configuration of this contract abstract contract Routable is ITypeAndVersion, IConfigurable { IOwnableFunctionsRouter private immutable i_router; @@ -18,9 +16,7 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { error OnlyCallableByRouter(); error OnlyCallableByRouterOwner(); - /** - * @dev Initializes the contract. - */ + // @dev Initializes the contract. constructor(address router, bytes memory config) { if (router == address(0)) { revert RouterMustBeSet(); @@ -33,23 +29,17 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { return i_router; } - /** - * @dev Must be implemented by inheriting contract - * Use to set configuration state - */ + // @dev Must be implemented by inheriting contract + // Use to set configuration state function _updateConfig(bytes memory config) internal virtual; - /** - * @inheritdoc IConfigurable - * @dev Only callable by the Router - */ + // @inheritdoc IConfigurable + // @dev Only callable by the Router function updateConfig(bytes memory config) public override onlyRouter { _updateConfig(config); } - /** - * @notice Reverts if called by anyone other than the router. - */ + // @notice Reverts if called by anyone other than the router. modifier onlyRouter() { if (msg.sender != address(i_router)) { revert OnlyCallableByRouter(); @@ -57,9 +47,7 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { _; } - /** - * @notice Reverts if called by anyone other than the router owner. - */ + // @notice Reverts if called by anyone other than the router owner. modifier onlyRouterOwner() { if (msg.sender != i_router.owner()) { revert OnlyCallableByRouterOwner(); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol deleted file mode 100644 index 2f665f14a90..00000000000 --- a/contracts/src/v0.8/functions/dev/1_0_0/RouterBase.sol +++ /dev/null @@ -1,281 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.19; - -import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; -import {IRouterBase} from "./interfaces/IRouterBase.sol"; -import {IConfigurable} from "./interfaces/IConfigurable.sol"; - -import {ConfirmedOwner} from "../../../ConfirmedOwner.sol"; - -import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; - -abstract contract RouterBase is IRouterBase, Pausable, ITypeAndVersion, ConfirmedOwner { - // ================================================================ - // | Route state | - // ================================================================ - mapping(bytes32 id => address routableContract) private s_route; - - error RouteNotFound(bytes32 id); - - // Use empty bytes to self-identify, since it does not have an id - bytes32 private constant ROUTER_ID = bytes32(0); - - // ================================================================ - // | Proposal state | - // ================================================================ - - uint8 private constant MAX_PROPOSAL_SET_LENGTH = 8; - - struct ContractProposalSet { - bytes32[] ids; - address[] to; - uint64 timelockEndBlock; - } - ContractProposalSet private s_proposedContractSet; - - event ContractProposed( - bytes32 proposedContractSetId, - address proposedContractSetFromAddress, - address proposedContractSetToAddress, - uint64 timelockEndBlock - ); - - event ContractUpdated(bytes32 id, address from, address to); - - struct ConfigProposal { - bytes to; - uint64 timelockEndBlock; - } - mapping(bytes32 id => ConfigProposal) private s_proposedConfig; - event ConfigProposed(bytes32 id, bytes toBytes); - event ConfigUpdated(bytes32 id, bytes toBytes); - error InvalidProposal(); - error IdentifierIsReserved(bytes32 id); - - // ================================================================ - // | Timelock state | - // ================================================================ - uint16 private immutable s_maximumTimelockBlocks; - uint16 private s_timelockBlocks; - - struct TimeLockProposal { - uint16 from; - uint16 to; - uint64 timelockEndBlock; - } - - TimeLockProposal private s_timelockProposal; - - event TimeLockProposed(uint16 from, uint16 to); - event TimeLockUpdated(uint16 from, uint16 to); - error ProposedTimelockAboveMaximum(); - error TimelockInEffect(); - - // ================================================================ - // | Initialization | - // ================================================================ - - constructor( - address newOwner, - uint16 timelockBlocks, - uint16 maximumTimelockBlocks, - bytes memory selfConfig - ) ConfirmedOwner(newOwner) Pausable() { - // Set initial value for the number of blocks of the timelock - s_timelockBlocks = timelockBlocks; - // Set maximum number of blocks that the timelock can be - s_maximumTimelockBlocks = maximumTimelockBlocks; - // Set the initial configuration for the Router - s_route[ROUTER_ID] = address(this); - _updateConfig(selfConfig); - } - - // ================================================================ - // | Route methods | - // ================================================================ - - // @inheritdoc IRouterBase - function getContractById(bytes32 id) public view override returns (address) { - address currentImplementation = s_route[id]; - if (currentImplementation == address(0)) { - revert RouteNotFound(id); - } - return currentImplementation; - } - - // @inheritdoc IRouterBase - function getProposedContractById(bytes32 id) public view override returns (address) { - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint8 i = 0; i < s_proposedContractSet.ids.length; ++i) { - if (id == s_proposedContractSet.ids[i]) { - return s_proposedContractSet.to[i]; - } - } - revert RouteNotFound(id); - } - - // ================================================================ - // | Contract Proposal methods | - // ================================================================ - - // @inheritdoc IRouterBase - function getProposedContractSet() - external - view - override - returns (uint256 timelockEndBlock, bytes32[] memory ids, address[] memory to) - { - timelockEndBlock = s_proposedContractSet.timelockEndBlock; - ids = s_proposedContractSet.ids; - to = s_proposedContractSet.to; - return (timelockEndBlock, ids, to); - } - - // @inheritdoc IRouterBase - function proposeContractsUpdate( - bytes32[] memory proposedContractSetIds, - address[] memory proposedContractSetAddresses - ) external override onlyOwner { - // All arrays must be of equal length and not must not exceed the max length - uint256 idsArrayLength = proposedContractSetIds.length; - if (idsArrayLength != proposedContractSetAddresses.length || idsArrayLength > MAX_PROPOSAL_SET_LENGTH) { - revert InvalidProposal(); - } - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint256 i = 0; i < idsArrayLength; ++i) { - bytes32 id = proposedContractSetIds[i]; - address proposedContract = proposedContractSetAddresses[i]; - if ( - proposedContract == address(0) || // The Proposed address must be a valid address - s_route[id] == proposedContract // The Proposed address must point to a different address than what is currently set - ) { - revert InvalidProposal(); - } - // Reserved ids cannot be set - if (id == ROUTER_ID) { - revert IdentifierIsReserved(id); - } - } - - uint64 timelockEndBlock = uint64(block.number + s_timelockBlocks); - - s_proposedContractSet = ContractProposalSet({ - ids: proposedContractSetIds, - to: proposedContractSetAddresses, - timelockEndBlock: timelockEndBlock - }); - - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint256 i = 0; i < proposedContractSetIds.length; ++i) { - emit ContractProposed({ - proposedContractSetId: proposedContractSetIds[i], - proposedContractSetFromAddress: s_route[proposedContractSetIds[i]], - proposedContractSetToAddress: proposedContractSetAddresses[i], - timelockEndBlock: timelockEndBlock - }); - } - } - - // @inheritdoc IRouterBase - function updateContracts() external override onlyOwner { - if (block.number < s_proposedContractSet.timelockEndBlock) { - revert TimelockInEffect(); - } - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH - for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { - bytes32 id = s_proposedContractSet.ids[i]; - address to = s_proposedContractSet.to[i]; - emit ContractUpdated({id: id, from: s_route[id], to: to}); - s_route[id] = to; - } - - delete s_proposedContractSet; - } - - // ================================================================ - // | Config Proposal methods | - // ================================================================ - - // @dev Must be implemented by inheriting contract - // Use to set configuration state of the Router - function _updateConfig(bytes memory config) internal virtual; - - // @inheritdoc IRouterBase - function proposeConfigUpdateSelf(bytes calldata config) external override onlyOwner { - s_proposedConfig[ROUTER_ID] = ConfigProposal({ - to: config, - timelockEndBlock: uint64(block.number + s_timelockBlocks) - }); - emit ConfigProposed({id: ROUTER_ID, toBytes: config}); - } - - // @inheritdoc IRouterBase - function updateConfigSelf() external override onlyOwner { - ConfigProposal memory proposal = s_proposedConfig[ROUTER_ID]; - if (block.number < proposal.timelockEndBlock) { - revert TimelockInEffect(); - } - _updateConfig(proposal.to); - emit ConfigUpdated({id: ROUTER_ID, toBytes: proposal.to}); - } - - // @inheritdoc IRouterBase - function proposeConfigUpdate(bytes32 id, bytes calldata config) external override onlyOwner { - s_proposedConfig[id] = ConfigProposal({to: config, timelockEndBlock: uint64(block.number + s_timelockBlocks)}); - emit ConfigProposed({id: id, toBytes: config}); - } - - // @inheritdoc IRouterBase - function updateConfig(bytes32 id) external override onlyOwner { - ConfigProposal memory proposal = s_proposedConfig[id]; - - if (block.number < proposal.timelockEndBlock) { - revert TimelockInEffect(); - } - - IConfigurable(getContractById(id)).updateConfig(proposal.to); - - emit ConfigUpdated({id: id, toBytes: proposal.to}); - } - - // ================================================================ - // | Timelock methods | - // ================================================================ - - // @inheritdoc IRouterBase - function proposeTimelockBlocks(uint16 blocks) external override onlyOwner { - if (s_timelockBlocks == blocks) { - revert InvalidProposal(); - } - if (blocks > s_maximumTimelockBlocks) { - revert ProposedTimelockAboveMaximum(); - } - s_timelockProposal = TimeLockProposal({ - from: s_timelockBlocks, - to: blocks, - timelockEndBlock: uint64(block.number + s_timelockBlocks) - }); - } - - // @inheritdoc IRouterBase - function updateTimelockBlocks() external override onlyOwner { - if (block.number < s_timelockProposal.timelockEndBlock) { - revert TimelockInEffect(); - } - s_timelockBlocks = s_timelockProposal.to; - } - - // ================================================================ - // | Pausable methods | - // ================================================================ - - // @inheritdoc IRouterBase - function pause() external override onlyOwner { - _pause(); - } - - // @inheritdoc IRouterBase - function unpause() external override onlyOwner { - _unpause(); - } -} diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol index 6953bf37b09..4023aa282dd 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol @@ -1,13 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -/** - * @title Configurable contract interface. - */ +// @title Configurable contract interface. interface IConfigurable { - /** - * @notice Set the contract's configuration - * @param config bytes containing config data - */ + // @notice Set the contract's configuration + // @param config bytes containing config data function updateConfig(bytes calldata config) external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index f727bb192e1..3c401d0233e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -1,9 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -/** - * @title Chainlink Functions billing subscription registry interface. - */ +// @title Chainlink Functions billing subscription registry interface. interface IFunctionsBilling { struct RequestBilling { // a unique subscription ID allocated by billing system, @@ -19,57 +17,56 @@ interface IFunctionsBilling { uint96 adminFee; } - /** - * @notice Gets the configuration of the Chainlink Functions billing registry - * @return maxCallbackGasLimit global max for request gas limit - * @return feedStalenessSeconds if the eth/link feed is more stale then this, use the fallback price - * @return gasOverheadBeforeCallback gas used in doing accounting before completing the gas measurement - * @return gasOverheadAfterCallback gas used in doing accounting after completing the gas measurement - * @return requestTimeoutSeconds e2e timeout for a request - * @return donFee extra fee added to every request - * @return maxSupportedRequestDataVersion The highest support request data version supported by the node - * @return fulfillmentGasPriceOverEstimationBP Percentage of gas price overestimation to account for changes in gas price between request and response. Held as basis points (one hundredth of 1 percentage point) - * @return fallbackNativePerUnitLink fallback native/link price in the case of a stale feed - * @return linkPriceFeed address of contract for a conversion price between LINK token and native token - */ - function getConfig() - external - view - returns ( - uint32 maxCallbackGasLimit, - uint32 feedStalenessSeconds, - uint32 gasOverheadBeforeCallback, - uint32 gasOverheadAfterCallback, - uint32 requestTimeoutSeconds, - uint80 donFee, - uint16 maxSupportedRequestDataVersion, - uint256 fulfillmentGasPriceOverEstimationBP, - int256 fallbackNativePerUnitLink, - address linkPriceFeed - ); + struct Config { + // Maximum amount of gas that can be given to a request's client callback + uint32 maxCallbackGasLimit; + // feedStalenessSeconds is how long before we consider the feed price to be stale + // and fallback to fallbackNativePerUnitLink. + uint32 feedStalenessSeconds; + // Represents the average gas execution cost. Used in estimating cost beforehand. + uint32 gasOverheadBeforeCallback; + // Gas to cover transmitter oracle payment after we calculate the payment. + // We make it configurable in case those operations are repriced. + uint32 gasOverheadAfterCallback; + // how many seconds it takes before we consider a request to be timed out + uint32 requestTimeoutSeconds; + // additional flat fee (in Juels of LINK) that will be split between Node Operators + // Max value is 2^80 - 1 == 1.2m LINK. + uint80 donFee; + // The highest support request data version supported by the node + // All lower versions should also be supported + uint16 maxSupportedRequestDataVersion; + // Percentage of gas price overestimation to account for changes in gas price between request and response + // Held as basis points (one hundredth of 1 percentage point) + uint256 fulfillmentGasPriceOverEstimationBP; + // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale + int256 fallbackNativePerUnitLink; + } + + // @notice Gets the configuration of the Chainlink Functions billing registry + // @return config + function getConfig() external view returns (Config memory); + + // @notice Return the current conversion from WEI of ETH to LINK from the configured Chainlink data feed + // @return weiPerUnitLink - The amount of WEI in one LINK + function getWeiPerUnitLink() external view returns (uint256); - /** - * @notice Determine the fee that will be split between Node Operators for servicing a request - * @param requestData Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - * @param billing The request's billing configuration - * @return fee Cost in Juels (1e18) of LINK - */ + // @notice Determine the fee that will be split between Node Operators for servicing a request + // @param requestData Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param billing The request's billing configuration + // @return fee Cost in Juels (1e18) of LINK function getDONFee(bytes memory requestData, RequestBilling memory billing) external view returns (uint80); - /** - * @notice Determine the fee that will be paid to the Router owner for operating the network - * @return fee Cost in Juels (1e18) of LINK - */ + // @notice Determine the fee that will be paid to the Router owner for operating the network + // @return fee Cost in Juels (1e18) of LINK function getAdminFee() external view returns (uint96); - /** - * @notice Estimate the total cost that will be charged to a subscription to make a request: gas re-reimbursement, plus DON fee, plus Registry fee - * @param subscriptionId An identifier of the billing account - * @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - * @param callbackGasLimit Gas limit for the fulfillment callback - * @param gasPrice The blockchain's gas price to estimate with - * @return billedCost Cost in Juels (1e18) of LINK - */ + // @notice Estimate the total cost that will be charged to a subscription to make a request: gas re-reimbursement, plus DON fee, plus Registry fee + // @param subscriptionId An identifier of the billing account + // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param callbackGasLimit Gas limit for the fulfillment callback + // @param gasPrice The blockchain's gas price to estimate with + // @return billedCost Cost in Juels (1e18) of LINK function estimateCost( uint64 subscriptionId, bytes calldata data, @@ -77,10 +74,18 @@ interface IFunctionsBilling { uint256 gasPrice ) external view returns (uint96); - /** - * @notice Remove a request commitment that the Router has determined to be stale - * @dev Only callable by the Router - * @param requestId - The request ID to remove - */ + // @notice Remove a request commitment that the Router has determined to be stale + // @dev Only callable by the Router + // @param requestId - The request ID to remove function deleteCommitment(bytes32 requestId) external returns (bool); + + // @notice Oracle withdraw LINK earned through fulfilling requests + // @notice If amount is 0 the full balance will be withdrawn + // @notice Both signing and transmitting wallets will have a balance to withdraw + // @param recipient where to send the funds + // @param amount amount to withdraw + function oracleWithdraw(address recipient, uint96 amount) external; + + // @notice Oracle withdraw all LINK earned through fulfilling requests to all Node Operators + function oracleWithdrawAll() external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol index 4423ec6dcca..0a66c259cab 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol @@ -1,16 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -/** - * @title Chainlink Functions client interface. - */ +// @title Chainlink Functions client interface. interface IFunctionsClient { - /** - * @notice Chainlink Functions response handler called by the designated transmitter node in an OCR round. - * @param requestId The requestId returned by FunctionsClient.sendRequest(). - * @param response Aggregated response from the user code. - * @param err Aggregated error either from the user code or from the execution pipeline. - * Either response or error parameter will be set, but never both. - */ + // @notice Chainlink Functions response handler called by the designated transmitter node in an OCR round. + // @param requestId The requestId returned by FunctionsClient.sendRequest(). + // @param response Aggregated response from the user code. + // @param err Aggregated error either from the user code or from the execution pipeline. + // Either response or error parameter will be set, but never both. function handleOracleFulfillment(bytes32 requestId, bytes memory response, bytes memory err) external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 22fc505a8e7..5bd915b9ef0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -3,9 +3,8 @@ pragma solidity ^0.8.19; import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; -/** - * @title Chainlink Functions oracle interface. - */ +// @title Chainlink Functions oracle interface. + interface IFunctionsCoordinator { struct Request { address requestingContract; // The client contract that is sending the request @@ -18,62 +17,46 @@ interface IFunctionsCoordinator { uint96 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network } - /** - * @notice Returns the DON's threshold encryption public key used to encrypt secrets - * @dev All nodes on the DON have separate key shares of the threshold decryption key - * and nodes must participate in a threshold decryption OCR round to decrypt secrets - * @return thresholdPublicKey the DON's threshold encryption public key - */ + // @notice Returns the DON's threshold encryption public key used to encrypt secrets + // @dev All nodes on the DON have separate key shares of the threshold decryption key + // and nodes must participate in a threshold decryption OCR round to decrypt secrets + // @return thresholdPublicKey the DON's threshold encryption public key function getThresholdPublicKey() external view returns (bytes memory); - /** - * @notice Sets the DON's threshold encryption public key used to encrypt secrets - * @dev Used to rotate the key - * @param thresholdPublicKey The new public key - */ + // @notice Sets the DON's threshold encryption public key used to encrypt secrets + // @dev Used to rotate the key + // @param thresholdPublicKey The new public key function setThresholdPublicKey(bytes calldata thresholdPublicKey) external; - /** - * @notice Returns the DON's secp256k1 public key that is used to encrypt secrets - * @dev All nodes on the DON have the corresponding private key - * needed to decrypt the secrets encrypted with the public key - * @return publicKey the DON's public key - */ + // @notice Returns the DON's secp256k1 public key that is used to encrypt secrets + // @dev All nodes on the DON have the corresponding private key + // needed to decrypt the secrets encrypted with the public key + // @return publicKey the DON's public key function getDONPublicKey() external view returns (bytes memory); - /** - * @notice Sets DON's secp256k1 public key used to encrypt secrets - * @dev Used to rotate the key - * @param donPublicKey The new public key - */ + // @notice Sets DON's secp256k1 public key used to encrypt secrets + // @dev Used to rotate the key + // @param donPublicKey The new public key function setDONPublicKey(bytes calldata donPublicKey) external; - /** - * @notice Sets a per-node secp256k1 public key used to encrypt secrets for that node - * @dev Callable only by contract owner and DON members - * @param node node's address - * @param publicKey node's public key - */ + // @notice Sets a per-node secp256k1 public key used to encrypt secrets for that node + // @dev Callable only by contract owner and DON members + // @param node node's address + // @param publicKey node's public key function setNodePublicKey(address node, bytes calldata publicKey) external; - /** - * @notice Deletes node's public key - * @dev Callable only by contract owner or the node itself - * @param node node's address - */ + // @notice Deletes node's public key + // @dev Callable only by contract owner or the node itself + // @param node node's address function deleteNodePublicKey(address node) external; - /** - * @notice Return two arrays of equal size containing DON members' addresses and their corresponding - * public keys (or empty byte arrays if per-node key is not defined) - */ + // @notice Return two arrays of equal size containing DON members' addresses and their corresponding + // public keys (or empty byte arrays if per-node key is not defined) function getAllNodePublicKeys() external view returns (address[] memory, bytes[] memory); - /** - * @notice Sends a request (encoded as data) using the provided subscriptionId - * @dev Callable only by the Router - * @param request The request information, @dev see the struct for field descriptions - * @return commitment - The parameters of the request that must be held consistent at response time - */ + // @notice Sends a request (encoded as data) using the provided subscriptionId + // @dev Callable only by the Router + // @param request The request information, @dev see the struct for field descriptions + // @return commitment - The parameters of the request that must be held consistent at response time function sendRequest(Request calldata request) external returns (FunctionsResponse.Commitment memory commitment); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index 6a0e50452df..c88dcd7e079 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -1,13 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IRouterBase} from "./IRouterBase.sol"; import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; -/** - * @title Chainlink Functions Router interface. - */ -interface IFunctionsRouter is IRouterBase { +// @title Chainlink Functions Router interface. +interface IFunctionsRouter { struct Config { // Maximum number of consumers which can be added to a single subscription // This bound ensures we are able to loop over all subscription consumers as needed, @@ -22,28 +19,22 @@ interface IFunctionsRouter is IRouterBase { uint32[] maxCallbackGasLimits; } - /** - * @notice The identifier of the route to retrieve the address of the access control contract - * The access control contract controls which accounts can manage subscriptions - * @return id - bytes32 id that can be passed to the "getContractById" of the Router - */ + // @notice The identifier of the route to retrieve the address of the access control contract + // The access control contract controls which accounts can manage subscriptions + // @return id - bytes32 id that can be passed to the "getContractById" of the Router function getAllowListId() external pure returns (bytes32); - /** - * @notice The router configuration - */ - function getConfig() external view returns (uint16, uint96, bytes4, uint32[] memory); - - /** - * @notice Sends a request (encoded as data) using the provided subscriptionId - * @param subscriptionId A unique subscription ID allocated by billing system, - * a client can make requests from different contracts referencing the same subscription - * @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - * @param dataVersion Gas limit for the fulfillment callback - * @param callbackGasLimit Gas limit for the fulfillment callback - * @param donId An identifier used to determine which route to send the request along - * @return requestId A unique request identifier - */ + // @notice The router configuration + function getConfig() external view returns (Config memory); + + // @notice Sends a request (encoded as data) using the provided subscriptionId + // @param subscriptionId A unique subscription ID allocated by billing system, + // a client can make requests from different contracts referencing the same subscription + // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param dataVersion Gas limit for the fulfillment callback + // @param callbackGasLimit Gas limit for the fulfillment callback + // @param donId An identifier used to determine which route to send the request along + // @return requestId A unique request identifier function sendRequest( uint64 subscriptionId, bytes calldata data, @@ -52,16 +43,14 @@ interface IFunctionsRouter is IRouterBase { bytes32 donId ) external returns (bytes32); - /** - * @notice Sends a request (encoded as data) to the proposed contracts - * @param subscriptionId A unique subscription ID allocated by billing system, - * a client can make requests from different contracts referencing the same subscription - * @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - * @param dataVersion Gas limit for the fulfillment callback - * @param callbackGasLimit Gas limit for the fulfillment callback - * @param donId An identifier used to determine which route to send the request along - * @return requestId A unique request identifier - */ + // @notice Sends a request (encoded as data) to the proposed contracts + // @param subscriptionId A unique subscription ID allocated by billing system, + // a client can make requests from different contracts referencing the same subscription + // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param dataVersion Gas limit for the fulfillment callback + // @param callbackGasLimit Gas limit for the fulfillment callback + // @param donId An identifier used to determine which route to send the request along + // @return requestId A unique request identifier function sendRequestToProposed( uint64 subscriptionId, bytes calldata data, @@ -70,20 +59,18 @@ interface IFunctionsRouter is IRouterBase { bytes32 donId ) external returns (bytes32); - /** - * @notice Fulfill the request by: - * - calling back the data that the Oracle returned to the client contract - * - pay the DON for processing the request - * @dev Only callable by the Coordinator contract that is saved in the commitment - * @param response response data from DON consensus - * @param err error from DON consensus - * @param juelsPerGas - current rate of juels/gas - * @param costWithoutFulfillment - The cost of processing the request (in Juels of LINK ), without fulfillment - * @param transmitter - The Node that transmitted the OCR report - * @param commitment - The parameters of the request that must be held consistent between request and response time - * @return fulfillResult - - * @return callbackGasCostJuels - - */ + // @notice Fulfill the request by: + // - calling back the data that the Oracle returned to the client contract + // - pay the DON for processing the request + // @dev Only callable by the Coordinator contract that is saved in the commitment + // @param response response data from DON consensus + // @param err error from DON consensus + // @param juelsPerGas - current rate of juels/gas + // @param costWithoutFulfillment - The cost of processing the request (in Juels of LINK ), without fulfillment + // @param transmitter - The Node that transmitted the OCR report + // @param commitment - The parameters of the request that must be held consistent between request and response time + // @return fulfillResult - + // @return callbackGasCostJuels - function fulfill( bytes memory response, bytes memory err, @@ -93,10 +80,59 @@ interface IFunctionsRouter is IRouterBase { FunctionsResponse.Commitment memory commitment ) external returns (FunctionsResponse.FulfillResult, uint96); - /** - * @notice Validate requested gas limit is below the subscription max. - * @param subscriptionId subscription ID - * @param callbackGasLimit desired callback gas limit - */ + // @notice Validate requested gas limit is below the subscription max. + // @param subscriptionId subscription ID + // @param callbackGasLimit desired callback gas limit function isValidCallbackGasLimit(uint64 subscriptionId, uint32 callbackGasLimit) external view; + + // @notice Get the current contract given an ID + // @param id A bytes32 identifier for the route + // @return contract The current contract address + function getContractById(bytes32 id) external view returns (address); + + // @notice Get the proposed next contract given an ID + // @param id A bytes32 identifier for the route + // @return contract The current or proposed contract address + function getProposedContractById(bytes32 id) external view returns (address); + + // @notice Return the latest proprosal set + // @return timelockEndBlock The block number that the proposal is able to be merged at + // @return ids The identifiers of the contracts to update + // @return to The addresses of the contracts that will be updated to + function getProposedContractSet() external view returns (uint, bytes32[] memory, address[] memory); + + // @notice Proposes one or more updates to the contract routes + // @dev Only callable by owner + function proposeContractsUpdate(bytes32[] memory proposalSetIds, address[] memory proposalSetAddresses) external; + + // @notice Updates the current contract routes to the proposed contracts + // @dev Only callable once timelock has passed + // @dev Only callable by owner + function updateContracts() external; + + // @notice Proposes new configuration data for the Router contract itself + // @dev Only callable by owner + function proposeConfigUpdateSelf(bytes calldata config) external; + + // @notice Updates configuration data for the Router contract itself + // @dev Only callable once timelock has passed + // @dev Only callable by owner + function updateConfigSelf() external; + + // @notice Proposes new configuration data for the current (not proposed) contract + // @dev Only callable by owner + function proposeConfigUpdate(bytes32 id, bytes calldata config) external; + + // @notice Sends new configuration data to the contract along a route route + // @dev Only callable once timelock has passed + // @dev Only callable by owner + function updateConfig(bytes32 id) external; + + // @dev Puts the system into an emergency stopped state. + // @dev Only callable by owner + function pause() external; + + // @dev Takes the system out of an emergency stopped state. + // @dev Only callable by owner + function unpause() external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 7ee877eaa46..698930a6e2a 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -12,7 +12,7 @@ interface IFunctionsSubscriptions { uint96 balance; // Common LINK balance that is controlled by the Registry to be used for all consumer requests. address owner; // Owner can fund/withdraw/cancel the sub. uint96 blockedBalance; // LINK balance that is reserved to pay for pending consumer requests. - address requestedOwner; // For safely transferring sub ownership. + address proposedOwner; // For safely transferring sub ownership. // Maintains the list of keys in s_consumers. // We do this for 2 reasons: // 1. To be able to clean up all keys from s_consumers when canceling a subscription. @@ -29,161 +29,109 @@ interface IFunctionsSubscriptions { uint64 completedRequests; // The number of requests that have successfully completed or timed out } - /** - * @notice Get details about a subscription. - * @param subscriptionId - ID of the subscription - * @return balance - Common LINK balance that is controlled by the Registry to be used for all consumer requests. - * @return owner - Owner can fund/withdraw/cancel the sub. - * @return blockedBalance - LINK balance that is reserved to pay for pending consumer requests. - * @return requestedOwner - For safely transferring sub ownership. - * @return consumers - Client contracts that can use the subscription - * @return flags - Per-subscription flags. - */ - function getSubscription( - uint64 subscriptionId - ) - external - view - returns ( - uint96 balance, - address owner, - uint96 blockedBalance, - address requestedOwner, - address[] memory consumers, - bytes32 flags - ); - - /** - * @notice Get details about a consumer of a subscription. - * @dev Only callable by a route - * @param client - the consumer contract that initiated the request - * @param subscriptionId - ID of the subscription - * @return allowed - amount of LINK balance of the subscription in juels that is blocked for an in flight request. - * @return initiatedRequests - owner of the subscription. - * @return completedRequests - list of consumer address which are able to use this subscription. - */ + // @notice Get details about a subscription. + // @param subscriptionId - ID of the subscription + function getSubscription(uint64 subscriptionId) external view returns (Subscription memory); + + // @notice Get details about a consumer of a subscription. + // @dev Only callable by a route + // @param client - the consumer contract that initiated the request + // @param subscriptionId - ID of the subscription + // @return allowed - amount of LINK balance of the subscription in juels that is blocked for an in flight request. + // @return initiatedRequests - owner of the subscription. + // @return completedRequests - list of consumer address which are able to use this subscription. function getConsumer( address client, uint64 subscriptionId ) external view returns (bool allowed, uint64 initiatedRequests, uint64 completedRequests); - /** - * @notice Get details about the total amount of LINK within the system - * @return totalBalance - total Juels of LINK held by the contract - */ + // @notice Get details about the total amount of LINK within the system + // @return totalBalance - total Juels of LINK held by the contract function getTotalBalance() external view returns (uint96); - /** - * @notice Get details about the total number of subscription accounts - * @return count - total number of subscriptions in the system - */ + // @notice Get details about the total number of subscription accounts + // @return count - total number of subscriptions in the system function getSubscriptionCount() external view returns (uint64); - /** - * @notice Time out all expired requests: unlocks funds and removes the ability for the request to be fulfilled - * @param requestsToTimeoutByCommitment - A list of request commitments to time out - * @dev The commitment can be found on the "OracleRequest" event created when sending the request. - */ + // @notice Time out all expired requests: unlocks funds and removes the ability for the request to be fulfilled + // @param requestsToTimeoutByCommitment - A list of request commitments to time out + // @dev The commitment can be found on the "OracleRequest" event created when sending the request. function timeoutRequests(FunctionsResponse.Commitment[] calldata requestsToTimeoutByCommitment) external; - /** - * @notice Oracle withdraw LINK earned through fulfilling requests - * @dev Must be called by the Coordinator contract - * @notice If amount is 0 the full balance will be withdrawn - * @notice Both signing and transmitting wallets will have a balance to withdraw - * @param recipient where to send the funds - * @param amount amount to withdraw - */ + // @notice Oracle withdraw LINK earned through fulfilling requests + // @dev Must be called by the Coordinator contract + // @notice If amount is 0 the full balance will be withdrawn + // @notice Both signing and transmitting wallets will have a balance to withdraw + // @param recipient where to send the funds + // @param amount amount to withdraw function oracleWithdraw(address recipient, uint96 amount) external; - /** - * @notice Owner cancel subscription, sends remaining link directly to the subscription owner. - * @dev Only callable by the Router Owner - * @param subscriptionId subscription id - * @dev notably can be called even if there are pending requests, outstanding ones may fail onchain - */ + // @notice Owner cancel subscription, sends remaining link directly to the subscription owner. + // @dev Only callable by the Router Owner + // @param subscriptionId subscription id + // @dev notably can be called even if there are pending requests, outstanding ones may fail onchain function ownerCancelSubscription(uint64 subscriptionId) external; - /** - * @notice Recover link sent with transfer instead of transferAndCall. - * @dev Only callable by the Router Owner - * @param to address to send link to - */ + // @notice Recover link sent with transfer instead of transferAndCall. + // @dev Only callable by the Router Owner + // @param to address to send link to function recoverFunds(address to) external; - /** - * @notice Create a new subscription. - * @return subscriptionId - A unique subscription id. - * @dev You can manage the consumer set dynamically with addConsumer/removeConsumer. - * @dev Note to fund the subscription, use transferAndCall. For example - * @dev LINKTOKEN.transferAndCall( - * @dev address(REGISTRY), - * @dev amount, - * @dev abi.encode(subscriptionId)); - */ + // @notice Create a new subscription. + // @return subscriptionId - A unique subscription id. + // @dev You can manage the consumer set dynamically with addConsumer/removeConsumer. + // @dev Note to fund the subscription, use transferAndCall. For example + // @dev LINKTOKEN.transferAndCall( + // @dev address(REGISTRY), + // @dev amount, + // @dev abi.encode(subscriptionId)); function createSubscription() external returns (uint64); - /** - * @notice Propose a new owner for a subscription. - * @dev Only callable by the Subscription's owner - * @param subscriptionId - ID of the subscription - * @param newOwner - proposed new owner of the subscription - */ + // @notice Propose a new owner for a subscription. + // @dev Only callable by the Subscription's owner + // @param subscriptionId - ID of the subscription + // @param newOwner - proposed new owner of the subscription function proposeSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external; - /** - * @notice Accept an ownership transfer. - * @param subscriptionId - ID of the subscription - * @dev will revert if original owner of subscriptionId has - * not requested that msg.sender become the new owner. - */ + // @notice Accept an ownership transfer. + // @param subscriptionId - ID of the subscription + // @dev will revert if original owner of subscriptionId has + // not requested that msg.sender become the new owner. function acceptSubscriptionOwnerTransfer(uint64 subscriptionId) external; - /** - * @notice Remove a consumer from a Chainlink Functions subscription. - * @dev Only callable by the Subscription's owner - * @param subscriptionId - ID of the subscription - * @param consumer - Consumer to remove from the subscription - */ + // @notice Remove a consumer from a Chainlink Functions subscription. + // @dev Only callable by the Subscription's owner + // @param subscriptionId - ID of the subscription + // @param consumer - Consumer to remove from the subscription function removeConsumer(uint64 subscriptionId, address consumer) external; - /** - * @notice Add a consumer to a Chainlink Functions subscription. - * @dev Only callable by the Subscription's owner - * @param subscriptionId - ID of the subscription - * @param consumer - New consumer which can use the subscription - */ + // @notice Add a consumer to a Chainlink Functions subscription. + // @dev Only callable by the Subscription's owner + // @param subscriptionId - ID of the subscription + // @param consumer - New consumer which can use the subscription function addConsumer(uint64 subscriptionId, address consumer) external; - /** - * @notice Cancel a subscription - * @dev Only callable by the Subscription's owner - * @param subscriptionId - ID of the subscription - * @param to - Where to send the remaining LINK to - */ + // @notice Cancel a subscription + // @dev Only callable by the Subscription's owner + // @param subscriptionId - ID of the subscription + // @param to - Where to send the remaining LINK to function cancelSubscription(uint64 subscriptionId, address to) external; - /** - * @notice Check to see if there exists a request commitment for all consumers for a given sub. - * @param subscriptionId - ID of the subscription - * @return true if there exists at least one unfulfilled request for the subscription, false - * otherwise. - * @dev Looping is bounded to MAX_CONSUMERS*(number of DONs). - * @dev Used to disable subscription canceling while outstanding request are present. - */ + // @notice Check to see if there exists a request commitment for all consumers for a given sub. + // @param subscriptionId - ID of the subscription + // @return true if there exists at least one unfulfilled request for the subscription, false + // otherwise. + // @dev Looping is bounded to MAX_CONSUMERS*(number of DONs). + // @dev Used to disable subscription canceling while outstanding request are present. function pendingRequestExists(uint64 subscriptionId) external view returns (bool); - /** - * @notice Set flags for a given subscription. - * @param subscriptionId - ID of the subscription - * @param flags - desired flag values - */ + // @notice Set flags for a given subscription. + // @param subscriptionId - ID of the subscription + // @param flags - desired flag values function setFlags(uint64 subscriptionId, bytes32 flags) external; - /** - * @notice Get flags for a given subscription. - * @param subscriptionId - ID of the subscription - * @return flags - current flag values - */ + // @notice Get flags for a given subscription. + // @param subscriptionId - ID of the subscription + // @return flags - current flag values function getFlags(uint64 subscriptionId) external view returns (bytes32); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol index e0c6be5aa9b..8fdd5fb68c2 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol @@ -4,9 +4,7 @@ pragma solidity ^0.8.19; import {IFunctionsRouter} from "./IFunctionsRouter.sol"; import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; -/** - * @title Chainlink Functions Router interface with Ownable. - */ +// @title Chainlink Functions Router interface with Ownable. interface IOwnableFunctionsRouter is IOwnable, IFunctionsRouter { } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol deleted file mode 100644 index 48167e2b1c0..00000000000 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IRouterBase.sol +++ /dev/null @@ -1,95 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.19; - -/** - * @title Chainlink base Router interface. - */ -interface IRouterBase { - /** - * @notice Get the current contract given an ID - * @param id A bytes32 identifier for the route - * @return contract The current contract address - */ - function getContractById(bytes32 id) external view returns (address); - - /** - * @notice Get the proposed next contract given an ID - * @param id A bytes32 identifier for the route - * @return contract The current or proposed contract address - */ - function getProposedContractById(bytes32 id) external view returns (address); - - /** - * @notice Return the latest proprosal set - * @return timelockEndBlock The block number that the proposal is able to be merged at - * @return ids The identifiers of the contracts to update - * @return to The addresses of the contracts that will be updated to - */ - function getProposedContractSet() external view returns (uint, bytes32[] memory, address[] memory); - - /** - * @notice Proposes one or more updates to the contract routes - * @dev Only callable by owner - */ - function proposeContractsUpdate(bytes32[] memory proposalSetIds, address[] memory proposalSetAddresses) external; - - /** - * @notice Updates the current contract routes to the proposed contracts - * @dev Only callable once timelock has passed - * @dev Only callable by owner - */ - function updateContracts() external; - - /** - * @notice Proposes new configuration data for the Router contract itself - * @dev Only callable by owner - */ - function proposeConfigUpdateSelf(bytes calldata config) external; - - /** - * @notice Updates configuration data for the Router contract itself - * @dev Only callable once timelock has passed - * @dev Only callable by owner - */ - function updateConfigSelf() external; - - /** - * @notice Proposes new configuration data for the current (not proposed) contract - * @dev Only callable by owner - */ - function proposeConfigUpdate(bytes32 id, bytes calldata config) external; - - /** - * @notice Sends new configuration data to the contract along a route route - * @dev Only callable once timelock has passed - * @dev Only callable by owner - */ - function updateConfig(bytes32 id) external; - - /** - * @notice Propose a change to the amount of blocks of the timelock - * (the amount of blocks that are required to pass before a change can be applied) - * @dev Only callable by owner - */ - function proposeTimelockBlocks(uint16 blocks) external; - - /** - * @notice Apply a proposed change to the amount of blocks required for the timelock - * (the amount of blocks that are required to pass before a change can be applied) - * @dev Only callable after the timelock blocks proposal has gone through the timelock itself - * @dev Only callable by owner - */ - function updateTimelockBlocks() external; - - /** - * @dev Puts the system into an emergency stopped state. - * @dev Only callable by owner - */ - function pause() external; - - /** - * @dev Takes the system out of an emergency stopped state. - * @dev Only callable by owner - */ - function unpause() external; -} diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol index 7cb330a3606..59e9fe9ba59 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol @@ -3,9 +3,7 @@ pragma solidity ^0.8.19; import {CBOR} from "../../../../vendor/solidity-cborutils/v2.0.0/CBOR.sol"; -/** - * @title Library for encoding the input data of a Functions request into CBOR - */ +// @title Library for encoding the input data of a Functions request into CBOR library FunctionsRequest { using CBOR for CBOR.CBORBuffer; @@ -38,11 +36,9 @@ library FunctionsRequest { error EmptyArgs(); error NoInlineSecrets(); - /** - * @notice Encodes a Request to CBOR encoded bytes - * @param self The request to encode - * @return CBOR encoded bytes - */ + // @notice Encodes a Request to CBOR encoded bytes + // @param self The request to encode + // @return CBOR encoded bytes function encodeCBOR(Request memory self) internal pure returns (bytes memory) { CBOR.CBORBuffer memory buffer = CBOR.create(DEFAULT_BUFFER_SIZE); @@ -86,14 +82,12 @@ library FunctionsRequest { return buffer.buf.buf; } - /** - * @notice Initializes a Chainlink Functions Request - * @dev Sets the codeLocation and code on the request - * @param self The uninitialized request - * @param codeLocation The user provided source code location - * @param language The programming language of the user code - * @param source The user provided source code or a url - */ + // @notice Initializes a Chainlink Functions Request + // @dev Sets the codeLocation and code on the request + // @param self The uninitialized request + // @param codeLocation The user provided source code location + // @param language The programming language of the user code + // @param source The user provided source code or a url function initializeRequest( Request memory self, Location codeLocation, @@ -107,21 +101,17 @@ library FunctionsRequest { self.source = source; } - /** - * @notice Initializes a Chainlink Functions Request - * @dev Simplified version of initializeRequest for PoC - * @param self The uninitialized request - * @param javaScriptSource The user provided JS code (must not be empty) - */ + // @notice Initializes a Chainlink Functions Request + // @dev Simplified version of initializeRequest for PoC + // @param self The uninitialized request + // @param javaScriptSource The user provided JS code (must not be empty) function initializeRequestForInlineJavaScript(Request memory self, string memory javaScriptSource) internal pure { initializeRequest(self, Location.Inline, CodeLanguage.JavaScript, javaScriptSource); } - /** - * @notice Adds Remote user encrypted secrets to a Request - * @param self The initialized request - * @param encryptedSecretsReference Encrypted comma-separated string of URLs pointing to off-chain secrets - */ + // @notice Adds Remote user encrypted secrets to a Request + // @param self The initialized request + // @param encryptedSecretsReference Encrypted comma-separated string of URLs pointing to off-chain secrets function addSecretsReference(Request memory self, bytes memory encryptedSecretsReference) internal pure { if (encryptedSecretsReference.length == 0) revert EmptySecrets(); @@ -129,12 +119,10 @@ library FunctionsRequest { self.encryptedSecretsReference = encryptedSecretsReference; } - /** - * @notice Adds DON-hosted secrets reference to a Request - * @param self The initialized request - * @param slotID Slot ID of the user's secrets hosted on DON - * @param version User data version (for the slotID) - */ + // @notice Adds DON-hosted secrets reference to a Request + // @param self The initialized request + // @param slotID Slot ID of the user's secrets hosted on DON + // @param version User data version (for the slotID) function addDONHostedSecrets(Request memory self, uint8 slotID, uint64 version) internal pure { CBOR.CBORBuffer memory buffer = CBOR.create(DEFAULT_BUFFER_SIZE); @@ -147,22 +135,18 @@ library FunctionsRequest { self.encryptedSecretsReference = buffer.buf.buf; } - /** - * @notice Sets args for the user run function - * @param self The initialized request - * @param args The array of string args (must not be empty) - */ + // @notice Sets args for the user run function + // @param self The initialized request + // @param args The array of string args (must not be empty) function setArgs(Request memory self, string[] memory args) internal pure { if (args.length == 0) revert EmptyArgs(); self.args = args; } - /** - * @notice Sets bytes args for the user run function - * @param self The initialized request - * @param args The array of bytes args (must not be empty) - */ + // @notice Sets bytes args for the user run function + // @param self The initialized request + // @param args The array of bytes args (must not be empty) function setBytesArgs(Request memory self, bytes[] memory args) internal pure { if (args.length == 0) revert EmptyArgs(); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol index 6421ee6b44b..d0d8512af17 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol @@ -1,9 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -/** - * @title Library of types that are used during fulfillment of a Functions request - */ +// @title Library of types that are used during fulfillment of a Functions request library FunctionsResponse { enum FulfillResult { USER_SUCCESS, // 0 diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index 10a27ae78ba..edc29477caa 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -2,6 +2,7 @@ pragma solidity ^0.8.0; import {IFunctionsRouter} from "../../dev/1_0_0/interfaces/IFunctionsRouter.sol"; +import {IFunctionsBilling} from "../../dev/1_0_0/interfaces/IFunctionsBilling.sol"; import {BaseTest} from "./BaseTest.t.sol"; import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; @@ -34,29 +35,21 @@ contract FunctionsRouterSetup is BaseTest { s_termsOfServiceAllowList = new TermsOfServiceAllowList(address(s_functionsRouter), getTermsOfServiceConfig()); } - function getRouterConfig() public view returns (bytes memory) { + function getRouterConfig() public view returns (IFunctionsRouter.Config memory) { uint32[] memory maxCallbackGasLimits = new uint32[](1); maxCallbackGasLimits[0] = type(uint32).max; - // First create the struct to get some type safety - IFunctionsRouter.Config memory routerConfig = IFunctionsRouter.Config({ - maxConsumersPerSubscription: s_maxConsumersPerSubscription, - adminFee: s_adminFee, - handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, - maxCallbackGasLimits: maxCallbackGasLimits - }); - return - abi.encode( - routerConfig.maxConsumersPerSubscription, - routerConfig.adminFee, - routerConfig.handleOracleFulfillmentSelector, - routerConfig.maxCallbackGasLimits - ); + IFunctionsRouter.Config({ + maxConsumersPerSubscription: s_maxConsumersPerSubscription, + adminFee: s_adminFee, + handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, + maxCallbackGasLimits: maxCallbackGasLimits + }); } function getCoordinatorConfig() public pure returns (bytes memory) { - FunctionsBilling.Config memory billingConfig = FunctionsBilling.Config({ + IFunctionsBilling.Config memory billingConfig = IFunctionsBilling.Config({ maxCallbackGasLimit: 5, feedStalenessSeconds: 5, gasOverheadAfterCallback: 5, diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index 61073b23450..68057af47b6 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -1,8 +1,6 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; -import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; import {ITermsOfServiceAllowList} from "../../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; import {IFunctionsSubscriptions} from "../../../dev/1_0_0/interfaces/IFunctionsSubscriptions.sol"; diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol new file mode 100644 index 00000000000..4a3282f1f20 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol @@ -0,0 +1,28 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (interfaces/IERC5267.sol) + +pragma solidity ^0.8.0; + +interface IERC5267 { + /** + * @dev MAY be emitted to signal that the domain could have changed. + */ + event EIP712DomainChanged(); + + /** + * @dev returns the fields and values that describe the domain separator used by this contract for EIP-712 + * signature. + */ + function eip712Domain() + external + view + returns ( + bytes1 fields, + string memory name, + string memory version, + uint256 chainId, + address verifyingContract, + bytes32 salt, + uint256[] memory extensions + ); +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC6093.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC6093.sol new file mode 100644 index 00000000000..84ac72c7f73 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC6093.sol @@ -0,0 +1,160 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +/** + * @dev Standard ERC20 Errors + * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC20 tokens. + */ +interface IERC20Errors { + /** + * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers. + * @param sender Address whose tokens are being transferred. + * @param balance Current balance for the interacting account. + * @param needed Minimum amount required to perform a transfer. + */ + error ERC20InsufficientBalance(address sender, uint256 balance, uint256 needed); + + /** + * @dev Indicates a failure with the token `sender`. Used in transfers. + * @param sender Address whose tokens are being transferred. + */ + error ERC20InvalidSender(address sender); + + /** + * @dev Indicates a failure with the token `receiver`. Used in transfers. + * @param receiver Address to which tokens are being transferred. + */ + error ERC20InvalidReceiver(address receiver); + + /** + * @dev Indicates a failure with the `spender`’s `allowance`. Used in transfers. + * @param spender Address that may be allowed to operate on tokens without being their owner. + * @param allowance Amount of tokens a `spender` is allowed to operate with. + * @param needed Minimum amount required to perform a transfer. + */ + error ERC20InsufficientAllowance(address spender, uint256 allowance, uint256 needed); + + /** + * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. + * @param approver Address initiating an approval operation. + */ + error ERC20InvalidApprover(address approver); + + /** + * @dev Indicates a failure with the `spender` to be approved. Used in approvals. + * @param spender Address that may be allowed to operate on tokens without being their owner. + */ + error ERC20InvalidSpender(address spender); +} + +/** + * @dev Standard ERC721 Errors + * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC721 tokens. + */ +interface IERC721Errors { + /** + * @dev Indicates that an address can't be an owner. For example, `address(0)` is a forbidden owner in EIP-20. + * Used in balance queries. + * @param owner Address of the current owner of a token. + */ + error ERC721InvalidOwner(address owner); + + /** + * @dev Indicates a `tokenId` whose `owner` is the zero address. + * @param tokenId Identifier number of a token. + */ + error ERC721NonexistentToken(uint256 tokenId); + + /** + * @dev Indicates an error related to the ownership over a particular token. Used in transfers. + * @param sender Address whose tokens are being transferred. + * @param tokenId Identifier number of a token. + * @param owner Address of the current owner of a token. + */ + error ERC721IncorrectOwner(address sender, uint256 tokenId, address owner); + + /** + * @dev Indicates a failure with the token `sender`. Used in transfers. + * @param sender Address whose tokens are being transferred. + */ + error ERC721InvalidSender(address sender); + + /** + * @dev Indicates a failure with the token `receiver`. Used in transfers. + * @param receiver Address to which tokens are being transferred. + */ + error ERC721InvalidReceiver(address receiver); + + /** + * @dev Indicates a failure with the `operator`’s approval. Used in transfers. + * @param operator Address that may be allowed to operate on tokens without being their owner. + * @param tokenId Identifier number of a token. + */ + error ERC721InsufficientApproval(address operator, uint256 tokenId); + + /** + * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. + * @param approver Address initiating an approval operation. + */ + error ERC721InvalidApprover(address approver); + + /** + * @dev Indicates a failure with the `operator` to be approved. Used in approvals. + * @param operator Address that may be allowed to operate on tokens without being their owner. + */ + error ERC721InvalidOperator(address operator); +} + +/** + * @dev Standard ERC1155 Errors + * Interface of the https://eips.ethereum.org/EIPS/eip-6093[ERC-6093] custom errors for ERC1155 tokens. + */ +interface IERC1155Errors { + /** + * @dev Indicates an error related to the current `balance` of a `sender`. Used in transfers. + * @param sender Address whose tokens are being transferred. + * @param balance Current balance for the interacting account. + * @param needed Minimum amount required to perform a transfer. + * @param tokenId Identifier number of a token. + */ + error ERC1155InsufficientBalance(address sender, uint256 balance, uint256 needed, uint256 tokenId); + + /** + * @dev Indicates a failure with the token `sender`. Used in transfers. + * @param sender Address whose tokens are being transferred. + */ + error ERC1155InvalidSender(address sender); + + /** + * @dev Indicates a failure with the token `receiver`. Used in transfers. + * @param receiver Address to which tokens are being transferred. + */ + error ERC1155InvalidReceiver(address receiver); + + /** + * @dev Indicates a failure with the `operator`’s approval. Used in transfers. + * @param operator Address that may be allowed to operate on tokens without being their owner. + * @param owner Address of the current owner of a token. + */ + error ERC1155MissingApprovalForAll(address operator, address owner); + + /** + * @dev Indicates a failure with the `approver` of a token to be approved. Used in approvals. + * @param approver Address initiating an approval operation. + */ + error ERC1155InvalidApprover(address approver); + + /** + * @dev Indicates a failure with the `operator` to be approved. Used in approvals. + * @param operator Address that may be allowed to operate on tokens without being their owner. + */ + error ERC1155InvalidOperator(address operator); + + /** + * @dev Indicates an array length mismatch between ids and values in a safeBatchTransferFrom operation. + * Used in batch transfers. + * @param idsLength Length of the array of token identifiers + * @param valuesLength Length of the array of token amounts + */ + error ERC1155InvalidArrayLength(uint256 idsLength, uint256 valuesLength); +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol new file mode 100644 index 00000000000..89ec2152080 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol @@ -0,0 +1,370 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/ERC20.sol) + +pragma solidity ^0.8.0; + +import {IERC20} from "./IERC20.sol"; +import {IERC20Metadata} from "./extensions/IERC20Metadata.sol"; +import {Context} from "../../utils/Context.sol"; +import {IERC20Errors} from "../../interfaces/draft-IERC6093.sol"; + +/** + * @dev Implementation of the {IERC20} interface. + * + * This implementation is agnostic to the way tokens are created. This means + * that a supply mechanism has to be added in a derived contract using {_mint}. + * + * TIP: For a detailed writeup see our guide + * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How + * to implement supply mechanisms]. + * + * The default value of {decimals} is 18. To change this, you should override + * this function so it returns a different value. + * + * We have followed general OpenZeppelin Contracts guidelines: functions revert + * instead returning `false` on failure. This behavior is nonetheless + * conventional and does not conflict with the expectations of ERC20 + * applications. + * + * Additionally, an {Approval} event is emitted on calls to {transferFrom}. + * This allows applications to reconstruct the allowance for all accounts just + * by listening to said events. Other implementations of the EIP may not emit + * these events, as it isn't required by the specification. + * + * Finally, the non-standard {decreaseAllowance} and {increaseAllowance} + * functions have been added to mitigate the well-known issues around setting + * allowances. See {IERC20-approve}. + */ +abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { + mapping(address => uint256) private _balances; + + mapping(address => mapping(address => uint256)) private _allowances; + + uint256 private _totalSupply; + + string private _name; + string private _symbol; + + /** + * @dev Indicates a failed `decreaseAllowance` request. + */ + error ERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease); + + /** + * @dev Sets the values for {name} and {symbol}. + * + * All two of these values are immutable: they can only be set once during + * construction. + */ + constructor(string memory name_, string memory symbol_) { + _name = name_; + _symbol = symbol_; + } + + /** + * @dev Returns the name of the token. + */ + function name() public view virtual returns (string memory) { + return _name; + } + + /** + * @dev Returns the symbol of the token, usually a shorter version of the + * name. + */ + function symbol() public view virtual returns (string memory) { + return _symbol; + } + + /** + * @dev Returns the number of decimals used to get its user representation. + * For example, if `decimals` equals `2`, a balance of `505` tokens should + * be displayed to a user as `5.05` (`505 / 10 ** 2`). + * + * Tokens usually opt for a value of 18, imitating the relationship between + * Ether and Wei. This is the default value returned by this function, unless + * it's overridden. + * + * NOTE: This information is only used for _display_ purposes: it in + * no way affects any of the arithmetic of the contract, including + * {IERC20-balanceOf} and {IERC20-transfer}. + */ + function decimals() public view virtual returns (uint8) { + return 18; + } + + /** + * @dev See {IERC20-totalSupply}. + */ + function totalSupply() public view virtual returns (uint256) { + return _totalSupply; + } + + /** + * @dev See {IERC20-balanceOf}. + */ + function balanceOf(address account) public view virtual returns (uint256) { + return _balances[account]; + } + + /** + * @dev See {IERC20-transfer}. + * + * Requirements: + * + * - `to` cannot be the zero address. + * - the caller must have a balance of at least `value`. + */ + function transfer(address to, uint256 value) public virtual returns (bool) { + address owner = _msgSender(); + _transfer(owner, to, value); + return true; + } + + /** + * @dev See {IERC20-allowance}. + */ + function allowance(address owner, address spender) public view virtual returns (uint256) { + return _allowances[owner][spender]; + } + + /** + * @dev See {IERC20-approve}. + * + * NOTE: If `value` is the maximum `uint256`, the allowance is not updated on + * `transferFrom`. This is semantically equivalent to an infinite approval. + * + * Requirements: + * + * - `spender` cannot be the zero address. + */ + function approve(address spender, uint256 value) public virtual returns (bool) { + address owner = _msgSender(); + _approve(owner, spender, value); + return true; + } + + /** + * @dev See {IERC20-transferFrom}. + * + * Emits an {Approval} event indicating the updated allowance. This is not + * required by the EIP. See the note at the beginning of {ERC20}. + * + * NOTE: Does not update the allowance if the current allowance + * is the maximum `uint256`. + * + * Requirements: + * + * - `from` and `to` cannot be the zero address. + * - `from` must have a balance of at least `value`. + * - the caller must have allowance for ``from``'s tokens of at least + * `value`. + */ + function transferFrom(address from, address to, uint256 value) public virtual returns (bool) { + address spender = _msgSender(); + _spendAllowance(from, spender, value); + _transfer(from, to, value); + return true; + } + + /** + * @dev Atomically increases the allowance granted to `spender` by the caller. + * + * This is an alternative to {approve} that can be used as a mitigation for + * problems described in {IERC20-approve}. + * + * Emits an {Approval} event indicating the updated allowance. + * + * Requirements: + * + * - `spender` cannot be the zero address. + */ + function increaseAllowance(address spender, uint256 addedValue) public virtual returns (bool) { + address owner = _msgSender(); + _approve(owner, spender, allowance(owner, spender) + addedValue); + return true; + } + + /** + * @dev Atomically decreases the allowance granted to `spender` by the caller. + * + * This is an alternative to {approve} that can be used as a mitigation for + * problems described in {IERC20-approve}. + * + * Emits an {Approval} event indicating the updated allowance. + * + * Requirements: + * + * - `spender` cannot be the zero address. + * - `spender` must have allowance for the caller of at least + * `requestedDecrease`. + * + * NOTE: Although this function is designed to avoid double spending with {approval}, + * it can still be frontrunned, preventing any attempt of allowance reduction. + */ + function decreaseAllowance(address spender, uint256 requestedDecrease) public virtual returns (bool) { + address owner = _msgSender(); + uint256 currentAllowance = allowance(owner, spender); + if (currentAllowance < requestedDecrease) { + revert ERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease); + } + unchecked { + _approve(owner, spender, currentAllowance - requestedDecrease); + } + + return true; + } + + /** + * @dev Moves a `value` amount of tokens from `from` to `to`. + * + * This internal function is equivalent to {transfer}, and can be used to + * e.g. implement automatic token fees, slashing mechanisms, etc. + * + * Emits a {Transfer} event. + * + * NOTE: This function is not virtual, {_update} should be overridden instead. + */ + function _transfer(address from, address to, uint256 value) internal { + if (from == address(0)) { + revert ERC20InvalidSender(address(0)); + } + if (to == address(0)) { + revert ERC20InvalidReceiver(address(0)); + } + _update(from, to, value); + } + + /** + * @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from` (or `to`) is + * the zero address. All customizations to transfers, mints, and burns should be done by overriding this function. + * + * Emits a {Transfer} event. + */ + function _update(address from, address to, uint256 value) internal virtual { + if (from == address(0)) { + // Overflow check required: The rest of the code assumes that totalSupply never overflows + _totalSupply += value; + } else { + uint256 fromBalance = _balances[from]; + if (fromBalance < value) { + revert ERC20InsufficientBalance(from, fromBalance, value); + } + unchecked { + // Overflow not possible: value <= fromBalance <= totalSupply. + _balances[from] = fromBalance - value; + } + } + + if (to == address(0)) { + unchecked { + // Overflow not possible: value <= totalSupply or value <= fromBalance <= totalSupply. + _totalSupply -= value; + } + } else { + unchecked { + // Overflow not possible: balance + value is at most totalSupply, which we know fits into a uint256. + _balances[to] += value; + } + } + + emit Transfer(from, to, value); + } + + /** + * @dev Creates a `value` amount of tokens and assigns them to `account`, by transferring it from address(0). + * Relies on the `_update` mechanism + * + * Emits a {Transfer} event with `from` set to the zero address. + * + * NOTE: This function is not virtual, {_update} should be overridden instead. + */ + function _mint(address account, uint256 value) internal { + if (account == address(0)) { + revert ERC20InvalidReceiver(address(0)); + } + _update(address(0), account, value); + } + + /** + * @dev Destroys a `value` amount of tokens from `account`, by transferring it to address(0). + * Relies on the `_update` mechanism. + * + * Emits a {Transfer} event with `to` set to the zero address. + * + * NOTE: This function is not virtual, {_update} should be overridden instead + */ + function _burn(address account, uint256 value) internal { + if (account == address(0)) { + revert ERC20InvalidSender(address(0)); + } + _update(account, address(0), value); + } + + /** + * @dev Sets `value` as the allowance of `spender` over the `owner` s tokens. + * + * This internal function is equivalent to `approve`, and can be used to + * e.g. set automatic allowances for certain subsystems, etc. + * + * Emits an {Approval} event. + * + * Requirements: + * + * - `owner` cannot be the zero address. + * - `spender` cannot be the zero address. + */ + function _approve(address owner, address spender, uint256 value) internal virtual { + _approve(owner, spender, value, true); + } + + /** + * @dev Alternative version of {_approve} with an optional flag that can enable or disable the Approval event. + * + * By default (when calling {_approve}) the flag is set to true. On the other hand, approval changes made by + * `_spendAllowance` during the `transferFrom` operation set the flag to false. This saves gas by not emitting any + * `Approval` event during `transferFrom` operations. + * + * Anyone who wishes to continue emitting `Approval` events on the`transferFrom` operation can force the flag to true + * using the following override: + * ``` + * function _approve(address owner, address spender, uint256 value, bool) internal virtual override { + * super._approve(owner, spender, value, true); + * } + * ``` + * + * Requirements are the same as {_approve}. + */ + function _approve(address owner, address spender, uint256 value, bool emitEvent) internal virtual { + if (owner == address(0)) { + revert ERC20InvalidApprover(address(0)); + } + if (spender == address(0)) { + revert ERC20InvalidSpender(address(0)); + } + _allowances[owner][spender] = value; + if (emitEvent) { + emit Approval(owner, spender, value); + } + } + + /** + * @dev Updates `owner` s allowance for `spender` based on spent `value`. + * + * Does not update the allowance value in case of infinite allowance. + * Revert if not enough allowance is available. + * + * Might emit an {Approval} event. + */ + function _spendAllowance(address owner, address spender, uint256 value) internal virtual { + uint256 currentAllowance = allowance(owner, spender); + if (currentAllowance != type(uint256).max) { + if (currentAllowance < value) { + revert ERC20InsufficientAllowance(spender, currentAllowance, value); + } + unchecked { + _approve(owner, spender, currentAllowance - value, false); + } + } + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol new file mode 100644 index 00000000000..d5ce96680c6 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol @@ -0,0 +1,79 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/IERC20.sol) + +pragma solidity ^0.8.0; + +/** + * @dev Interface of the ERC20 standard as defined in the EIP. + */ +interface IERC20 { + /** + * @dev Emitted when `value` tokens are moved from one account (`from`) to + * another (`to`). + * + * Note that `value` may be zero. + */ + event Transfer(address indexed from, address indexed to, uint256 value); + + /** + * @dev Emitted when the allowance of a `spender` for an `owner` is set by + * a call to {approve}. `value` is the new allowance. + */ + event Approval(address indexed owner, address indexed spender, uint256 value); + + /** + * @dev Returns the value of tokens in existence. + */ + function totalSupply() external view returns (uint256); + + /** + * @dev Returns the value of tokens owned by `account`. + */ + function balanceOf(address account) external view returns (uint256); + + /** + * @dev Moves a `value` amount of tokens from the caller's account to `to`. + * + * Returns a boolean value indicating whether the operation succeeded. + * + * Emits a {Transfer} event. + */ + function transfer(address to, uint256 value) external returns (bool); + + /** + * @dev Returns the remaining number of tokens that `spender` will be + * allowed to spend on behalf of `owner` through {transferFrom}. This is + * zero by default. + * + * This value changes when {approve} or {transferFrom} are called. + */ + function allowance(address owner, address spender) external view returns (uint256); + + /** + * @dev Sets a `value` amount of tokens as the allowance of `spender` over the + * caller's tokens. + * + * Returns a boolean value indicating whether the operation succeeded. + * + * IMPORTANT: Beware that changing an allowance with this method brings the risk + * that someone may use both the old and the new allowance by unfortunate + * transaction ordering. One possible solution to mitigate this race + * condition is to first reduce the spender's allowance to 0 and set the + * desired value afterwards: + * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729 + * + * Emits an {Approval} event. + */ + function approve(address spender, uint256 value) external returns (bool); + + /** + * @dev Moves a `value` amount of tokens from `from` to `to` using the + * allowance mechanism. `value` is then deducted from the caller's + * allowance. + * + * Returns a boolean value indicating whether the operation succeeded. + * + * Emits a {Transfer} event. + */ + function transferFrom(address from, address to, uint256 value) external returns (bool); +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol new file mode 100644 index 00000000000..bdd86286f51 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol @@ -0,0 +1,84 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/extensions/ERC20Permit.sol) + +pragma solidity ^0.8.0; + +import {IERC20Permit} from "./IERC20Permit.sol"; +import {ERC20} from "../ERC20.sol"; +import {ECDSA} from "../../../utils/cryptography/ECDSA.sol"; +import {EIP712} from "../../../utils/cryptography/EIP712.sol"; +import {Nonces} from "../../../utils/Nonces.sol"; + +/** + * @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in + * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. + * + * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by + * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't + * need to send a transaction, and thus is not required to hold Ether at all. + */ +abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712, Nonces { + // solhint-disable-next-line var-name-mixedcase + bytes32 private constant _PERMIT_TYPEHASH = + keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"); + + /** + * @dev Permit deadline has expired. + */ + error ERC2612ExpiredSignature(uint256 deadline); + + /** + * @dev Mismatched signature. + */ + error ERC2612InvalidSigner(address signer, address owner); + + /** + * @dev Initializes the {EIP712} domain separator using the `name` parameter, and setting `version` to `"1"`. + * + * It's a good idea to use the same `name` that is defined as the ERC20 token name. + */ + constructor(string memory name) EIP712(name, "1") {} + + /** + * @dev See {IERC20Permit-permit}. + */ + function permit( + address owner, + address spender, + uint256 value, + uint256 deadline, + uint8 v, + bytes32 r, + bytes32 s + ) public virtual { + if (block.timestamp > deadline) { + revert ERC2612ExpiredSignature(deadline); + } + + bytes32 structHash = keccak256(abi.encode(_PERMIT_TYPEHASH, owner, spender, value, _useNonce(owner), deadline)); + + bytes32 hash = _hashTypedDataV4(structHash); + + address signer = ECDSA.recover(hash, v, r, s); + if (signer != owner) { + revert ERC2612InvalidSigner(signer, owner); + } + + _approve(owner, spender, value); + } + + /** + * @dev See {IERC20Permit-nonces}. + */ + function nonces(address owner) public view virtual override(IERC20Permit, Nonces) returns (uint256) { + return super.nonces(owner); + } + + /** + * @dev See {IERC20Permit-DOMAIN_SEPARATOR}. + */ + // solhint-disable-next-line func-name-mixedcase + function DOMAIN_SEPARATOR() external view virtual returns (bytes32) { + return _domainSeparatorV4(); + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol new file mode 100644 index 00000000000..4db4ba20264 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol @@ -0,0 +1,26 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/IERC20Metadata.sol) + +pragma solidity ^0.8.0; + +import {IERC20} from "../IERC20.sol"; + +/** + * @dev Interface for the optional metadata functions from the ERC20 standard. + */ +interface IERC20Metadata is IERC20 { + /** + * @dev Returns the name of the token. + */ + function name() external view returns (string memory); + + /** + * @dev Returns the symbol of the token. + */ + function symbol() external view returns (string memory); + + /** + * @dev Returns the decimals places of the token. + */ + function decimals() external view returns (uint8); +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol new file mode 100644 index 00000000000..89416499151 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol @@ -0,0 +1,60 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/extensions/IERC20Permit.sol) + +pragma solidity ^0.8.0; + +/** + * @dev Interface of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in + * https://eips.ethereum.org/EIPS/eip-2612[EIP-2612]. + * + * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by + * presenting a message signed by the account. By not relying on {IERC20-approve}, the token holder account doesn't + * need to send a transaction, and thus is not required to hold Ether at all. + */ +interface IERC20Permit { + /** + * @dev Sets `value` as the allowance of `spender` over ``owner``'s tokens, + * given ``owner``'s signed approval. + * + * IMPORTANT: The same issues {IERC20-approve} has related to transaction + * ordering also apply here. + * + * Emits an {Approval} event. + * + * Requirements: + * + * - `spender` cannot be the zero address. + * - `deadline` must be a timestamp in the future. + * - `v`, `r` and `s` must be a valid `secp256k1` signature from `owner` + * over the EIP712-formatted function arguments. + * - the signature must use ``owner``'s current nonce (see {nonces}). + * + * For more information on the signature format, see the + * https://eips.ethereum.org/EIPS/eip-2612#specification[relevant EIP + * section]. + */ + function permit( + address owner, + address spender, + uint256 value, + uint256 deadline, + uint8 v, + bytes32 r, + bytes32 s + ) external; + + /** + * @dev Returns the current nonce for `owner`. This value must be + * included whenever a signature is generated for {permit}. + * + * Every successful call to {permit} increases ``owner``'s nonce by one. This + * prevents a signature from being used multiple times. + */ + function nonces(address owner) external view returns (uint256); + + /** + * @dev Returns the domain separator used in the encoding of the signature for {permit}, as defined by {EIP712}. + */ + // solhint-disable-next-line func-name-mixedcase + function DOMAIN_SEPARATOR() external view returns (bytes32); +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol new file mode 100644 index 00000000000..b5556d921aa --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol @@ -0,0 +1,140 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/utils/SafeERC20.sol) + +pragma solidity ^0.8.0; + +import {IERC20} from "../IERC20.sol"; +import {IERC20Permit} from "../extensions/IERC20Permit.sol"; +import {Address} from "../../../utils/Address.sol"; + +/** + * @title SafeERC20 + * @dev Wrappers around ERC20 operations that throw on failure (when the token + * contract returns false). Tokens that return no value (and instead revert or + * throw on failure) are also supported, non-reverting calls are assumed to be + * successful. + * To use this library you can add a `using SafeERC20 for IERC20;` statement to your contract, + * which allows you to call the safe operations as `token.safeTransfer(...)`, etc. + */ +library SafeERC20 { + using Address for address; + + /** + * @dev An operation with an ERC20 token failed. + */ + error SafeERC20FailedOperation(address token); + + /** + * @dev Indicates a failed `decreaseAllowance` request. + */ + error SafeERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease); + + /** + * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value, + * non-reverting calls are assumed to be successful. + */ + function safeTransfer(IERC20 token, address to, uint256 value) internal { + _callOptionalReturn(token, abi.encodeCall(token.transfer, (to, value))); + } + + /** + * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the + * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful. + */ + function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { + _callOptionalReturn(token, abi.encodeCall(token.transferFrom, (from, to, value))); + } + + /** + * @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value, + * non-reverting calls are assumed to be successful. + */ + function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { + uint256 oldAllowance = token.allowance(address(this), spender); + forceApprove(token, spender, oldAllowance + value); + } + + /** + * @dev Decrease the calling contract's allowance toward `spender` by `requestedDecrease`. If `token` returns no value, + * non-reverting calls are assumed to be successful. + */ + function safeDecreaseAllowance(IERC20 token, address spender, uint256 requestedDecrease) internal { + unchecked { + uint256 currentAllowance = token.allowance(address(this), spender); + if (currentAllowance < requestedDecrease) { + revert SafeERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease); + } + forceApprove(token, spender, currentAllowance - requestedDecrease); + } + } + + /** + * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value, + * non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval + * to be set to zero before setting it to a non-zero value, such as USDT. + */ + function forceApprove(IERC20 token, address spender, uint256 value) internal { + bytes memory approvalCall = abi.encodeCall(token.approve, (spender, value)); + + if (!_callOptionalReturnBool(token, approvalCall)) { + _callOptionalReturn(token, abi.encodeCall(token.approve, (spender, 0))); + _callOptionalReturn(token, approvalCall); + } + } + + /** + * @dev Use a ERC-2612 signature to set the `owner` approval toward `spender` on `token`. + * Revert on invalid signature. + */ + function safePermit( + IERC20Permit token, + address owner, + address spender, + uint256 value, + uint256 deadline, + uint8 v, + bytes32 r, + bytes32 s + ) internal { + uint256 nonceBefore = token.nonces(owner); + token.permit(owner, spender, value, deadline, v, r, s); + uint256 nonceAfter = token.nonces(owner); + if (nonceAfter != nonceBefore + 1) { + revert SafeERC20FailedOperation(address(token)); + } + } + + /** + * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement + * on the return value: the return value is optional (but if data is returned, it must not be false). + * @param token The token targeted by the call. + * @param data The call data (encoded using abi.encode or one of its variants). + */ + function _callOptionalReturn(IERC20 token, bytes memory data) private { + // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since + // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that + // the target address contains contract code and also asserts for success in the low-level call. + + bytes memory returndata = address(token).functionCall(data); + if (returndata.length != 0 && !abi.decode(returndata, (bool))) { + revert SafeERC20FailedOperation(address(token)); + } + } + + /** + * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement + * on the return value: the return value is optional (but if data is returned, it must not be false). + * @param token The token targeted by the call. + * @param data The call data (encoded using abi.encode or one of its variants). + * + * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead. + */ + function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) { + // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since + // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false + // and not revert is the subcall reverts. + + (bool success, bytes memory returndata) = address(token).call(data); + return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0; + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol new file mode 100644 index 00000000000..0f017e3edbc --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol @@ -0,0 +1,46 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +/** + * @dev Provides tracking nonces for addresses. Nonces will only increment. + */ +abstract contract Nonces { + /** + * @dev The nonce used for an `account` is not the expected current nonce. + */ + error InvalidAccountNonce(address account, uint256 currentNonce); + + mapping(address => uint256) private _nonces; + + /** + * @dev Returns an the next unused nonce for an address. + */ + function nonces(address owner) public view virtual returns (uint256) { + return _nonces[owner]; + } + + /** + * @dev Consumes a nonce. + * + * Returns the current value and increments nonce. + */ + function _useNonce(address owner) internal virtual returns (uint256) { + // For each account, the nonce has an initial value of 0, can only be incremented by one, and cannot be + // decremented or reset. This guarantees that the nonce never overflows. + unchecked { + // It is important to do x++ and not ++x here. + return _nonces[owner]++; + } + } + + /** + * @dev Same as {_useNonce} but checking that `nonce` is the next valid for `owner`. + */ + function _useCheckedNonce(address owner, uint256 nonce) internal virtual returns (uint256) { + uint256 current = _useNonce(owner); + if (nonce != current) { + revert InvalidAccountNonce(owner, current); + } + return current; + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol new file mode 100644 index 00000000000..fc6224c8e38 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol @@ -0,0 +1,122 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (utils/ShortStrings.sol) + +pragma solidity ^0.8.0; + +import {StorageSlot} from "./StorageSlot.sol"; + +// | string | 0xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA | +// | length | 0x BB | +type ShortString is bytes32; + +/** + * @dev This library provides functions to convert short memory strings + * into a `ShortString` type that can be used as an immutable variable. + * + * Strings of arbitrary length can be optimized using this library if + * they are short enough (up to 31 bytes) by packing them with their + * length (1 byte) in a single EVM word (32 bytes). Additionally, a + * fallback mechanism can be used for every other case. + * + * Usage example: + * + * ```solidity + * contract Named { + * using ShortStrings for *; + * + * ShortString private immutable _name; + * string private _nameFallback; + * + * constructor(string memory contractName) { + * _name = contractName.toShortStringWithFallback(_nameFallback); + * } + * + * function name() external view returns (string memory) { + * return _name.toStringWithFallback(_nameFallback); + * } + * } + * ``` + */ +library ShortStrings { + // Used as an identifier for strings longer than 31 bytes. + bytes32 private constant _FALLBACK_SENTINEL = 0x00000000000000000000000000000000000000000000000000000000000000FF; + + error StringTooLong(string str); + error InvalidShortString(); + + /** + * @dev Encode a string of at most 31 chars into a `ShortString`. + * + * This will trigger a `StringTooLong` error is the input string is too long. + */ + function toShortString(string memory str) internal pure returns (ShortString) { + bytes memory bstr = bytes(str); + if (bstr.length > 31) { + revert StringTooLong(str); + } + return ShortString.wrap(bytes32(uint256(bytes32(bstr)) | bstr.length)); + } + + /** + * @dev Decode a `ShortString` back to a "normal" string. + */ + function toString(ShortString sstr) internal pure returns (string memory) { + uint256 len = byteLength(sstr); + // using `new string(len)` would work locally but is not memory safe. + string memory str = new string(32); + /// @solidity memory-safe-assembly + assembly { + mstore(str, len) + mstore(add(str, 0x20), sstr) + } + return str; + } + + /** + * @dev Return the length of a `ShortString`. + */ + function byteLength(ShortString sstr) internal pure returns (uint256) { + uint256 result = uint256(ShortString.unwrap(sstr)) & 0xFF; + if (result > 31) { + revert InvalidShortString(); + } + return result; + } + + /** + * @dev Encode a string into a `ShortString`, or write it to storage if it is too long. + */ + function toShortStringWithFallback(string memory value, string storage store) internal returns (ShortString) { + if (bytes(value).length < 32) { + return toShortString(value); + } else { + StorageSlot.getStringSlot(store).value = value; + return ShortString.wrap(_FALLBACK_SENTINEL); + } + } + + /** + * @dev Decode a string that was encoded to `ShortString` or written to storage using {setWithFallback}. + */ + function toStringWithFallback(ShortString value, string storage store) internal pure returns (string memory) { + if (ShortString.unwrap(value) != _FALLBACK_SENTINEL) { + return toString(value); + } else { + return store; + } + } + + /** + * @dev Return the length of a string that was encoded to `ShortString` or written to storage using {setWithFallback}. + * + * WARNING: This will return the "byte length" of the string. This may not reflect the actual length in terms of + * actual characters as the UTF-8 encoding of a single character can span over multiple bytes. + */ + function byteLengthWithFallback(ShortString value, string storage store) internal view returns (uint256) { + if (ShortString.unwrap(value) != _FALLBACK_SENTINEL) { + return byteLength(value); + } else { + return bytes(store).length; + } + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol new file mode 100644 index 00000000000..599f466e315 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol @@ -0,0 +1,135 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (utils/StorageSlot.sol) +// This file was procedurally generated from scripts/generate/templates/StorageSlot.js. + +pragma solidity ^0.8.0; + +/** + * @dev Library for reading and writing primitive types to specific storage slots. + * + * Storage slots are often used to avoid storage conflict when dealing with upgradeable contracts. + * This library helps with reading and writing to such slots without the need for inline assembly. + * + * The functions in this library return Slot structs that contain a `value` member that can be used to read or write. + * + * Example usage to set ERC1967 implementation slot: + * ```solidity + * contract ERC1967 { + * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; + * + * function _getImplementation() internal view returns (address) { + * return StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value; + * } + * + * function _setImplementation(address newImplementation) internal { + * require(newImplementation.code.length > 0); + * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; + * } + * } + * ``` + */ +library StorageSlot { + struct AddressSlot { + address value; + } + + struct BooleanSlot { + bool value; + } + + struct Bytes32Slot { + bytes32 value; + } + + struct Uint256Slot { + uint256 value; + } + + struct StringSlot { + string value; + } + + struct BytesSlot { + bytes value; + } + + /** + * @dev Returns an `AddressSlot` with member `value` located at `slot`. + */ + function getAddressSlot(bytes32 slot) internal pure returns (AddressSlot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := slot + } + } + + /** + * @dev Returns an `BooleanSlot` with member `value` located at `slot`. + */ + function getBooleanSlot(bytes32 slot) internal pure returns (BooleanSlot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := slot + } + } + + /** + * @dev Returns an `Bytes32Slot` with member `value` located at `slot`. + */ + function getBytes32Slot(bytes32 slot) internal pure returns (Bytes32Slot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := slot + } + } + + /** + * @dev Returns an `Uint256Slot` with member `value` located at `slot`. + */ + function getUint256Slot(bytes32 slot) internal pure returns (Uint256Slot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := slot + } + } + + /** + * @dev Returns an `StringSlot` with member `value` located at `slot`. + */ + function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := slot + } + } + + /** + * @dev Returns an `StringSlot` representation of the string storage pointer `store`. + */ + function getStringSlot(string storage store) internal pure returns (StringSlot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := store.slot + } + } + + /** + * @dev Returns an `BytesSlot` with member `value` located at `slot`. + */ + function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := slot + } + } + + /** + * @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`. + */ + function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) { + /// @solidity memory-safe-assembly + assembly { + r.slot := store.slot + } + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol new file mode 100644 index 00000000000..e16d66d9477 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol @@ -0,0 +1,93 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (utils/Strings.sol) + +pragma solidity ^0.8.0; + +import {Math} from "./math/Math.sol"; +import {SignedMath} from "./math/SignedMath.sol"; + +/** + * @dev String operations. + */ +library Strings { + bytes16 private constant _SYMBOLS = "0123456789abcdef"; + uint8 private constant _ADDRESS_LENGTH = 20; + + /** + * @dev The `value` string doesn't fit in the specified `length`. + */ + error StringsInsufficientHexLength(uint256 value, uint256 length); + + /** + * @dev Converts a `uint256` to its ASCII `string` decimal representation. + */ + function toString(uint256 value) internal pure returns (string memory) { + unchecked { + uint256 length = Math.log10(value) + 1; + string memory buffer = new string(length); + uint256 ptr; + /// @solidity memory-safe-assembly + assembly { + ptr := add(buffer, add(32, length)) + } + while (true) { + ptr--; + /// @solidity memory-safe-assembly + assembly { + mstore8(ptr, byte(mod(value, 10), _SYMBOLS)) + } + value /= 10; + if (value == 0) break; + } + return buffer; + } + } + + /** + * @dev Converts a `int256` to its ASCII `string` decimal representation. + */ + function toStringSigned(int256 value) internal pure returns (string memory) { + return string.concat(value < 0 ? "-" : "", toString(SignedMath.abs(value))); + } + + /** + * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. + */ + function toHexString(uint256 value) internal pure returns (string memory) { + unchecked { + return toHexString(value, Math.log256(value) + 1); + } + } + + /** + * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. + */ + function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { + uint256 localValue = value; + bytes memory buffer = new bytes(2 * length + 2); + buffer[0] = "0"; + buffer[1] = "x"; + for (uint256 i = 2 * length + 1; i > 1; --i) { + buffer[i] = _SYMBOLS[localValue & 0xf]; + localValue >>= 4; + } + if (localValue != 0) { + revert StringsInsufficientHexLength(value, length); + } + return string(buffer); + } + + /** + * @dev Converts an `address` with fixed length of 20 bytes to its not checksummed ASCII `string` hexadecimal representation. + */ + function toHexString(address addr) internal pure returns (string memory) { + return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); + } + + /** + * @dev Returns true if the two strings are equal. + */ + function equal(string memory a, string memory b) internal pure returns (bool) { + return bytes(a).length == bytes(b).length && keccak256(bytes(a)) == keccak256(bytes(b)); + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol new file mode 100644 index 00000000000..ea3bf4833f0 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol @@ -0,0 +1,171 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (utils/cryptography/ECDSA.sol) + +pragma solidity ^0.8.0; + +/** + * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. + * + * These functions can be used to verify that a message was signed by the holder + * of the private keys of a given address. + */ +library ECDSA { + enum RecoverError { + NoError, + InvalidSignature, + InvalidSignatureLength, + InvalidSignatureS + } + + /** + * @dev The signature derives the `address(0)`. + */ + error ECDSAInvalidSignature(); + + /** + * @dev The signature has an invalid length. + */ + error ECDSAInvalidSignatureLength(uint256 length); + + /** + * @dev The signature has an S value that is in the upper half order. + */ + error ECDSAInvalidSignatureS(bytes32 s); + + /** + * @dev Returns the address that signed a hashed message (`hash`) with + * `signature` or error string. This address can then be used for verification purposes. + * + * The `ecrecover` EVM precompile allows for malleable (non-unique) signatures: + * this function rejects them by requiring the `s` value to be in the lower + * half order, and the `v` value to be either 27 or 28. + * + * IMPORTANT: `hash` _must_ be the result of a hash operation for the + * verification to be secure: it is possible to craft signatures that + * recover to arbitrary addresses for non-hashed data. A safe way to ensure + * this is by receiving a hash of the original message (which may otherwise + * be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it. + * + * Documentation for signature generation: + * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] + * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] + */ + function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError, bytes32) { + if (signature.length == 65) { + bytes32 r; + bytes32 s; + uint8 v; + // ecrecover takes the signature parameters, and the only way to get them + // currently is to use assembly. + /// @solidity memory-safe-assembly + assembly { + r := mload(add(signature, 0x20)) + s := mload(add(signature, 0x40)) + v := byte(0, mload(add(signature, 0x60))) + } + return tryRecover(hash, v, r, s); + } else { + return (address(0), RecoverError.InvalidSignatureLength, bytes32(signature.length)); + } + } + + /** + * @dev Returns the address that signed a hashed message (`hash`) with + * `signature`. This address can then be used for verification purposes. + * + * The `ecrecover` EVM precompile allows for malleable (non-unique) signatures: + * this function rejects them by requiring the `s` value to be in the lower + * half order, and the `v` value to be either 27 or 28. + * + * IMPORTANT: `hash` _must_ be the result of a hash operation for the + * verification to be secure: it is possible to craft signatures that + * recover to arbitrary addresses for non-hashed data. A safe way to ensure + * this is by receiving a hash of the original message (which may otherwise + * be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it. + */ + function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { + (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, signature); + _throwError(error, errorArg); + return recovered; + } + + /** + * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. + * + * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] + */ + function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError, bytes32) { + unchecked { + bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); + // We do not check for an overflow here since the shift operation results in 0 or 1. + uint8 v = uint8((uint256(vs) >> 255) + 27); + return tryRecover(hash, v, r, s); + } + } + + /** + * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. + */ + function recover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address) { + (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, r, vs); + _throwError(error, errorArg); + return recovered; + } + + /** + * @dev Overload of {ECDSA-tryRecover} that receives the `v`, + * `r` and `s` signature fields separately. + */ + function tryRecover( + bytes32 hash, + uint8 v, + bytes32 r, + bytes32 s + ) internal pure returns (address, RecoverError, bytes32) { + // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature + // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines + // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most + // signatures from current libraries generate a unique signature with an s-value in the lower half order. + // + // If your library generates malleable signatures, such as s-values in the upper range, calculate a new s-value + // with 0xFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFEBAAEDCE6AF48A03BBFD25E8CD0364141 - s1 and flip v from 27 to 28 or + // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept + // these malleable signatures as well. + if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { + return (address(0), RecoverError.InvalidSignatureS, s); + } + + // If the signature is valid (and not malleable), return the signer address + address signer = ecrecover(hash, v, r, s); + if (signer == address(0)) { + return (address(0), RecoverError.InvalidSignature, bytes32(0)); + } + + return (signer, RecoverError.NoError, bytes32(0)); + } + + /** + * @dev Overload of {ECDSA-recover} that receives the `v`, + * `r` and `s` signature fields separately. + */ + function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) { + (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, v, r, s); + _throwError(error, errorArg); + return recovered; + } + + /** + * @dev Optionally reverts with the corresponding custom error according to the `error` argument provided. + */ + function _throwError(RecoverError error, bytes32 errorArg) private pure { + if (error == RecoverError.NoError) { + return; // no error: do nothing + } else if (error == RecoverError.InvalidSignature) { + revert ECDSAInvalidSignature(); + } else if (error == RecoverError.InvalidSignatureLength) { + revert ECDSAInvalidSignatureLength(uint256(errorArg)); + } else if (error == RecoverError.InvalidSignatureS) { + revert ECDSAInvalidSignatureS(errorArg); + } + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol new file mode 100644 index 00000000000..bfaf8bd6576 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol @@ -0,0 +1,160 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (utils/cryptography/EIP712.sol) + +pragma solidity ^0.8.0; + +import {MessageHashUtils} from "./MessageHashUtils.sol"; +import {ShortStrings, ShortString} from "../ShortStrings.sol"; +import {IERC5267} from "../../interfaces/IERC5267.sol"; + +/** + * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. + * + * The encoding scheme specified in the EIP requires a domain separator and a hash of the typed structured data, whose + * encoding is very generic and therefore its implementation in Solidity is not feasible, thus this contract + * does not implement the encoding itself. Protocols need to implement the type-specific encoding they need in order to + * produce the hash of their typed data using a combination of `abi.encode` and `keccak256`. + * + * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding + * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA + * ({_hashTypedDataV4}). + * + * The implementation of the domain separator was designed to be as efficient as possible while still properly updating + * the chain id to protect against replay attacks on an eventual fork of the chain. + * + * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method + * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. + * + * NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain + * separator of the implementation contract. This will cause the {_domainSeparatorV4} function to always rebuild the + * separator from the immutable values, which is cheaper than accessing a cached version in cold storage. + * + * @custom:oz-upgrades-unsafe-allow state-variable-immutable + */ +abstract contract EIP712 is IERC5267 { + using ShortStrings for *; + + bytes32 private constant _TYPE_HASH = + keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); + + // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to + // invalidate the cached domain separator if the chain id changes. + bytes32 private immutable _cachedDomainSeparator; + uint256 private immutable _cachedChainId; + address private immutable _cachedThis; + + bytes32 private immutable _hashedName; + bytes32 private immutable _hashedVersion; + + ShortString private immutable _name; + ShortString private immutable _version; + string private _nameFallback; + string private _versionFallback; + + /** + * @dev Initializes the domain separator and parameter caches. + * + * The meaning of `name` and `version` is specified in + * https://eips.ethereum.org/EIPS/eip-712#definition-of-domainseparator[EIP 712]: + * + * - `name`: the user readable name of the signing domain, i.e. the name of the DApp or the protocol. + * - `version`: the current major version of the signing domain. + * + * NOTE: These parameters cannot be changed except through a xref:learn::upgrading-smart-contracts.adoc[smart + * contract upgrade]. + */ + constructor(string memory name, string memory version) { + _name = name.toShortStringWithFallback(_nameFallback); + _version = version.toShortStringWithFallback(_versionFallback); + _hashedName = keccak256(bytes(name)); + _hashedVersion = keccak256(bytes(version)); + + _cachedChainId = block.chainid; + _cachedDomainSeparator = _buildDomainSeparator(); + _cachedThis = address(this); + } + + /** + * @dev Returns the domain separator for the current chain. + */ + function _domainSeparatorV4() internal view returns (bytes32) { + if (address(this) == _cachedThis && block.chainid == _cachedChainId) { + return _cachedDomainSeparator; + } else { + return _buildDomainSeparator(); + } + } + + function _buildDomainSeparator() private view returns (bytes32) { + return keccak256(abi.encode(_TYPE_HASH, _hashedName, _hashedVersion, block.chainid, address(this))); + } + + /** + * @dev Given an already https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct[hashed struct], this + * function returns the hash of the fully encoded EIP712 message for this domain. + * + * This hash can be used together with {ECDSA-recover} to obtain the signer of a message. For example: + * + * ```solidity + * bytes32 digest = _hashTypedDataV4(keccak256(abi.encode( + * keccak256("Mail(address to,string contents)"), + * mailTo, + * keccak256(bytes(mailContents)) + * ))); + * address signer = ECDSA.recover(digest, signature); + * ``` + */ + function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { + return MessageHashUtils.toTypedDataHash(_domainSeparatorV4(), structHash); + } + + /** + * @dev See {IERC-5267}. + */ + function eip712Domain() + public + view + virtual + returns ( + bytes1 fields, + string memory name, + string memory version, + uint256 chainId, + address verifyingContract, + bytes32 salt, + uint256[] memory extensions + ) + { + return ( + hex"0f", // 01111 + _EIP712Name(), + _EIP712Version(), + block.chainid, + address(this), + bytes32(0), + new uint256[](0) + ); + } + + /** + * @dev The name parameter for the EIP712 domain. + * + * NOTE: By default this function reads _name which is an immutable value. + * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). + */ + // solhint-disable-next-line func-name-mixedcase + function _EIP712Name() internal view returns (string memory) { + return _name.toStringWithFallback(_nameFallback); + } + + /** + * @dev The version parameter for the EIP712 domain. + * + * NOTE: By default this function reads _version which is an immutable value. + * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). + */ + // solhint-disable-next-line func-name-mixedcase + function _EIP712Version() internal view returns (string memory) { + return _version.toStringWithFallback(_versionFallback); + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol new file mode 100644 index 00000000000..fa0730e35bd --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol @@ -0,0 +1,87 @@ +// SPDX-License-Identifier: MIT + +pragma solidity ^0.8.0; + +import {Strings} from "../Strings.sol"; + +/** + * @dev Signature message hash utilities for producing digests to be consumed by {ECDSA} recovery or signing. + * + * The library provides methods for generating a hash of a message that conforms to the + * https://eips.ethereum.org/EIPS/eip-191[EIP 191] and https://eips.ethereum.org/EIPS/eip-712[EIP 712] + * specifications. + */ +library MessageHashUtils { + /** + * @dev Returns the keccak256 digest of an EIP-191 signed data with version + * `0x45` (`personal_sign` messages). + * + * The digest is calculated by prefixing a bytes32 `messageHash` with + * `"\x19Ethereum Signed Message:\n32"` and hashing the result. It corresponds with the + * hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method. + * + * NOTE: The `hash` parameter is intended to be the result of hashing a raw message with + * keccak256, although any bytes32 value can be safely used because the final digest will + * be re-hashed. + * + * See {ECDSA-recover}. + */ + function toEthSignedMessageHash(bytes32 messageHash) internal pure returns (bytes32 digest) { + /// @solidity memory-safe-assembly + assembly { + mstore(0x00, "\x19Ethereum Signed Message:\n32") // 32 is the bytes-length of messageHash + mstore(0x1c, messageHash) // 0x1c (28) is the length of the prefix + digest := keccak256(0x00, 0x3c) // 0x3c is the length of the prefix (0x1c) + messageHash (0x20) + } + } + + /** + * @dev Returns the keccak256 digest of an EIP-191 signed data with version + * `0x45` (`personal_sign` messages). + * + * The digest is calculated by prefixing an arbitrary `message` with + * `"\x19Ethereum Signed Message:\n" + len(message)` and hashing the result. It corresponds with the + * hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method. + * + * See {ECDSA-recover}. + */ + function toEthSignedMessageHash(bytes memory message) internal pure returns (bytes32 digest) { + return keccak256(bytes.concat("\x19Ethereum Signed Message:\n", bytes(Strings.toString(message.length)), message)); + } + + /** + * @dev Returns the keccak256 digest of an EIP-191 signed data with version + * `0x00` (data with intended validator). + * + * The digest is calculated by prefixing an arbitrary `data` with `"\x19\x00"` and the intended + * `validator` address. Then hashing the result. + * + * See {ECDSA-recover}. + */ + function toDataWithIntendedValidatorHash( + address validator, + bytes memory data + ) internal pure returns (bytes32 digest) { + return keccak256(abi.encodePacked(hex"19_00", validator, data)); + } + + /** + * @dev Returns the keccak256 digest of an EIP-712 typed data (EIP-191 version `0x01`). + * + * The digest is calculated from a `domainSeparator` and a `structHash`, by prefixing them with + * `\x19\x01` and hashing the result. It corresponds to the hash signed by the + * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] JSON-RPC method as part of EIP-712. + * + * See {ECDSA-recover}. + */ + function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32 digest) { + /// @solidity memory-safe-assembly + assembly { + let ptr := mload(0x40) + mstore(ptr, hex"19_01") + mstore(add(ptr, 0x02), domainSeparator) + mstore(add(ptr, 0x22), structHash) + digest := keccak256(ptr, 0x42) + } + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol new file mode 100644 index 00000000000..e429e5db781 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol @@ -0,0 +1,414 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.9.0) (utils/math/Math.sol) + +pragma solidity ^0.8.0; + +/** + * @dev Standard math utilities missing in the Solidity language. + */ +library Math { + /** + * @dev Muldiv operation overflow. + */ + error MathOverflowedMulDiv(); + + enum Rounding { + Floor, // Toward negative infinity + Ceil, // Toward positive infinity + Trunc, // Toward zero + Expand // Away from zero + } + + /** + * @dev Returns the addition of two unsigned integers, with an overflow flag. + */ + function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { + unchecked { + uint256 c = a + b; + if (c < a) return (false, 0); + return (true, c); + } + } + + /** + * @dev Returns the subtraction of two unsigned integers, with an overflow flag. + */ + function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { + unchecked { + if (b > a) return (false, 0); + return (true, a - b); + } + } + + /** + * @dev Returns the multiplication of two unsigned integers, with an overflow flag. + */ + function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { + unchecked { + // Gas optimization: this is cheaper than requiring 'a' not being zero, but the + // benefit is lost if 'b' is also tested. + // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 + if (a == 0) return (true, 0); + uint256 c = a * b; + if (c / a != b) return (false, 0); + return (true, c); + } + } + + /** + * @dev Returns the division of two unsigned integers, with a division by zero flag. + */ + function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { + unchecked { + if (b == 0) return (false, 0); + return (true, a / b); + } + } + + /** + * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. + */ + function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { + unchecked { + if (b == 0) return (false, 0); + return (true, a % b); + } + } + + /** + * @dev Returns the largest of two numbers. + */ + function max(uint256 a, uint256 b) internal pure returns (uint256) { + return a > b ? a : b; + } + + /** + * @dev Returns the smallest of two numbers. + */ + function min(uint256 a, uint256 b) internal pure returns (uint256) { + return a < b ? a : b; + } + + /** + * @dev Returns the average of two numbers. The result is rounded towards + * zero. + */ + function average(uint256 a, uint256 b) internal pure returns (uint256) { + // (a + b) / 2 can overflow. + return (a & b) + (a ^ b) / 2; + } + + /** + * @dev Returns the ceiling of the division of two numbers. + * + * This differs from standard division with `/` in that it rounds towards infinity instead + * of rounding towards zero. + */ + function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) { + if (b == 0) { + // Guarantee the same behavior as in a regular Solidity division. + return a / b; + } + + // (a + b - 1) / b can overflow on addition, so we distribute. + return a == 0 ? 0 : (a - 1) / b + 1; + } + + /** + * @notice Calculates floor(x * y / denominator) with full precision. Throws if result overflows a uint256 or denominator == 0 + * @dev Original credit to Remco Bloemen under MIT license (https://xn--2-umb.com/21/muldiv) + * with further edits by Uniswap Labs also under MIT license. + */ + function mulDiv(uint256 x, uint256 y, uint256 denominator) internal pure returns (uint256 result) { + unchecked { + // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use + // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256 + // variables such that product = prod1 * 2^256 + prod0. + uint256 prod0 = x * y; // Least significant 256 bits of the product + uint256 prod1; // Most significant 256 bits of the product + assembly { + let mm := mulmod(x, y, not(0)) + prod1 := sub(sub(mm, prod0), lt(mm, prod0)) + } + + // Handle non-overflow cases, 256 by 256 division. + if (prod1 == 0) { + // Solidity will revert if denominator == 0, unlike the div opcode on its own. + // The surrounding unchecked block does not change this fact. + // See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic. + return prod0 / denominator; + } + + // Make sure the result is less than 2^256. Also prevents denominator == 0. + if (denominator <= prod1) { + revert MathOverflowedMulDiv(); + } + + /////////////////////////////////////////////// + // 512 by 256 division. + /////////////////////////////////////////////// + + // Make division exact by subtracting the remainder from [prod1 prod0]. + uint256 remainder; + assembly { + // Compute remainder using mulmod. + remainder := mulmod(x, y, denominator) + + // Subtract 256 bit number from 512 bit number. + prod1 := sub(prod1, gt(remainder, prod0)) + prod0 := sub(prod0, remainder) + } + + // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1. + // See https://cs.stackexchange.com/q/138556/92363. + + uint256 twos = denominator & (0 - denominator); + assembly { + // Divide denominator by twos. + denominator := div(denominator, twos) + + // Divide [prod1 prod0] by twos. + prod0 := div(prod0, twos) + + // Flip twos such that it is 2^256 / twos. If twos is zero, then it becomes one. + twos := add(div(sub(0, twos), twos), 1) + } + + // Shift in bits from prod1 into prod0. + prod0 |= prod1 * twos; + + // Invert denominator mod 2^256. Now that denominator is an odd number, it has an inverse modulo 2^256 such + // that denominator * inv = 1 mod 2^256. Compute the inverse by starting with a seed that is correct for + // four bits. That is, denominator * inv = 1 mod 2^4. + uint256 inverse = (3 * denominator) ^ 2; + + // Use the Newton-Raphson iteration to improve the precision. Thanks to Hensel's lifting lemma, this also works + // in modular arithmetic, doubling the correct bits in each step. + inverse *= 2 - denominator * inverse; // inverse mod 2^8 + inverse *= 2 - denominator * inverse; // inverse mod 2^16 + inverse *= 2 - denominator * inverse; // inverse mod 2^32 + inverse *= 2 - denominator * inverse; // inverse mod 2^64 + inverse *= 2 - denominator * inverse; // inverse mod 2^128 + inverse *= 2 - denominator * inverse; // inverse mod 2^256 + + // Because the division is now exact we can divide by multiplying with the modular inverse of denominator. + // This will give us the correct result modulo 2^256. Since the preconditions guarantee that the outcome is + // less than 2^256, this is the final result. We don't need to compute the high bits of the result and prod1 + // is no longer required. + result = prod0 * inverse; + return result; + } + } + + /** + * @notice Calculates x * y / denominator with full precision, following the selected rounding direction. + */ + function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) { + uint256 result = mulDiv(x, y, denominator); + if (unsignedRoundsUp(rounding) && mulmod(x, y, denominator) > 0) { + result += 1; + } + return result; + } + + /** + * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded + * towards zero. + * + * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11). + */ + function sqrt(uint256 a) internal pure returns (uint256) { + if (a == 0) { + return 0; + } + + // For our first guess, we get the biggest power of 2 which is smaller than the square root of the target. + // + // We know that the "msb" (most significant bit) of our target number `a` is a power of 2 such that we have + // `msb(a) <= a < 2*msb(a)`. This value can be written `msb(a)=2**k` with `k=log2(a)`. + // + // This can be rewritten `2**log2(a) <= a < 2**(log2(a) + 1)` + // → `sqrt(2**k) <= sqrt(a) < sqrt(2**(k+1))` + // → `2**(k/2) <= sqrt(a) < 2**((k+1)/2) <= 2**(k/2 + 1)` + // + // Consequently, `2**(log2(a) / 2)` is a good first approximation of `sqrt(a)` with at least 1 correct bit. + uint256 result = 1 << (log2(a) >> 1); + + // At this point `result` is an estimation with one bit of precision. We know the true value is a uint128, + // since it is the square root of a uint256. Newton's method converges quadratically (precision doubles at + // every iteration). We thus need at most 7 iteration to turn our partial result with one bit of precision + // into the expected uint128 result. + unchecked { + result = (result + a / result) >> 1; + result = (result + a / result) >> 1; + result = (result + a / result) >> 1; + result = (result + a / result) >> 1; + result = (result + a / result) >> 1; + result = (result + a / result) >> 1; + result = (result + a / result) >> 1; + return min(result, a / result); + } + } + + /** + * @notice Calculates sqrt(a), following the selected rounding direction. + */ + function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) { + unchecked { + uint256 result = sqrt(a); + return result + (unsignedRoundsUp(rounding) && result * result < a ? 1 : 0); + } + } + + /** + * @dev Return the log in base 2 of a positive value rounded towards zero. + * Returns 0 if given 0. + */ + function log2(uint256 value) internal pure returns (uint256) { + uint256 result = 0; + unchecked { + if (value >> 128 > 0) { + value >>= 128; + result += 128; + } + if (value >> 64 > 0) { + value >>= 64; + result += 64; + } + if (value >> 32 > 0) { + value >>= 32; + result += 32; + } + if (value >> 16 > 0) { + value >>= 16; + result += 16; + } + if (value >> 8 > 0) { + value >>= 8; + result += 8; + } + if (value >> 4 > 0) { + value >>= 4; + result += 4; + } + if (value >> 2 > 0) { + value >>= 2; + result += 2; + } + if (value >> 1 > 0) { + result += 1; + } + } + return result; + } + + /** + * @dev Return the log in base 2, following the selected rounding direction, of a positive value. + * Returns 0 if given 0. + */ + function log2(uint256 value, Rounding rounding) internal pure returns (uint256) { + unchecked { + uint256 result = log2(value); + return result + (unsignedRoundsUp(rounding) && 1 << result < value ? 1 : 0); + } + } + + /** + * @dev Return the log in base 10 of a positive value rounded towards zero. + * Returns 0 if given 0. + */ + function log10(uint256 value) internal pure returns (uint256) { + uint256 result = 0; + unchecked { + if (value >= 10 ** 64) { + value /= 10 ** 64; + result += 64; + } + if (value >= 10 ** 32) { + value /= 10 ** 32; + result += 32; + } + if (value >= 10 ** 16) { + value /= 10 ** 16; + result += 16; + } + if (value >= 10 ** 8) { + value /= 10 ** 8; + result += 8; + } + if (value >= 10 ** 4) { + value /= 10 ** 4; + result += 4; + } + if (value >= 10 ** 2) { + value /= 10 ** 2; + result += 2; + } + if (value >= 10 ** 1) { + result += 1; + } + } + return result; + } + + /** + * @dev Return the log in base 10, following the selected rounding direction, of a positive value. + * Returns 0 if given 0. + */ + function log10(uint256 value, Rounding rounding) internal pure returns (uint256) { + unchecked { + uint256 result = log10(value); + return result + (unsignedRoundsUp(rounding) && 10 ** result < value ? 1 : 0); + } + } + + /** + * @dev Return the log in base 256 of a positive value rounded towards zero. + * Returns 0 if given 0. + * + * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string. + */ + function log256(uint256 value) internal pure returns (uint256) { + uint256 result = 0; + unchecked { + if (value >> 128 > 0) { + value >>= 128; + result += 16; + } + if (value >> 64 > 0) { + value >>= 64; + result += 8; + } + if (value >> 32 > 0) { + value >>= 32; + result += 4; + } + if (value >> 16 > 0) { + value >>= 16; + result += 2; + } + if (value >> 8 > 0) { + result += 1; + } + } + return result; + } + + /** + * @dev Return the log in base 256, following the selected rounding direction, of a positive value. + * Returns 0 if given 0. + */ + function log256(uint256 value, Rounding rounding) internal pure returns (uint256) { + unchecked { + uint256 result = log256(value); + return result + (unsignedRoundsUp(rounding) && 1 << (result << 3) < value ? 1 : 0); + } + } + + /** + * @dev Returns whether a provided rounding mode is considered rounding up for unsigned integers. + */ + function unsignedRoundsUp(Rounding rounding) internal pure returns (bool) { + return uint8(rounding) % 2 == 1; + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SignedMath.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SignedMath.sol new file mode 100644 index 00000000000..93524bb79c0 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SignedMath.sol @@ -0,0 +1,43 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/SignedMath.sol) + +pragma solidity ^0.8.0; + +/** + * @dev Standard signed math utilities missing in the Solidity language. + */ +library SignedMath { + /** + * @dev Returns the largest of two signed numbers. + */ + function max(int256 a, int256 b) internal pure returns (int256) { + return a > b ? a : b; + } + + /** + * @dev Returns the smallest of two signed numbers. + */ + function min(int256 a, int256 b) internal pure returns (int256) { + return a < b ? a : b; + } + + /** + * @dev Returns the average of two signed numbers without overflow. + * The result is rounded towards zero. + */ + function average(int256 a, int256 b) internal pure returns (int256) { + // Formula from the book "Hacker's Delight" + int256 x = (a & b) + ((a ^ b) >> 1); + return x + (int256(uint256(x) >> 255) & (a ^ b)); + } + + /** + * @dev Returns the absolute unsigned value of a signed value. + */ + function abs(int256 n) internal pure returns (uint256) { + unchecked { + // must be unchecked in order to support `n = type(int256).min` + return uint256(n >= 0 ? n : -n); + } + } +} diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index 4f1031ee7d8..bba8d8f7dd7 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -21,12 +21,14 @@ describe('Functions Router - Request lifecycle', () => { }) it('#config', async () => { const config = await contracts.router.getConfig() - expect(config[0]).to.be.equal(functionsRouterConfig.maxConsumers) - expect(config[1]).to.be.equal(functionsRouterConfig.adminFee) - expect(config[2]).to.be.equal( + expect(config.maxConsumersPerSubscription).to.be.equal( + functionsRouterConfig.maxConsumersPerSubscription, + ) + expect(config.adminFee).to.be.equal(functionsRouterConfig.adminFee) + expect(config.handleOracleFulfillmentSelector).to.be.equal( functionsRouterConfig.handleOracleFulfillmentSelector, ) - expect(config[3].toString()).to.be.equal( + expect(config.maxCallbackGasLimits.toString()).to.be.equal( functionsRouterConfig.maxCallbackGasLimits.toString(), ) }) diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 712894742be..2a094d1148f 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -61,12 +61,20 @@ describe('FunctionsRouter - Base', () => { it('Owner can update config of the Router', async () => { const beforeConfig = await contracts.router.getConfig() - await expect( contracts.router.proposeConfigUpdateSelf( ethers.utils.defaultAbiCoder.encode( - ['uint16', 'uint96', 'bytes4', 'uint32[]'], - [2000, 1, 0x0ca76175, [300_000, 500_000]], + contracts.router.interface.events[ + 'ConfigChanged((uint16,uint96,bytes4,uint32[]))' + ].inputs, + [ + { + maxConsumersPerSubscription: 2000, + adminFee: 1, + handleOracleFulfillmentSelector: 0x0ca76175, + maxCallbackGasLimits: [300_000, 500_000], + }, + ], ), ), ).to.emit(contracts.router, 'ConfigProposed') @@ -117,7 +125,9 @@ describe('FunctionsRouter - Base', () => { it('returns the config set on the Router', async () => { const config = await contracts.router.connect(roles.stranger).getConfig() - expect(config[0]).to.equal(functionsRouterConfig.maxConsumers) + expect(config[0]).to.equal( + functionsRouterConfig.maxConsumersPerSubscription, + ) expect(config[1]).to.equal(functionsRouterConfig.adminFee) expect(config[2]).to.equal( functionsRouterConfig.handleOracleFulfillmentSelector, @@ -271,67 +281,69 @@ describe('FunctionsRouter - Base', () => { }) }) - describe('Timelock', () => { - it('prevents applying timelock updates', async () => { - await contracts.router.proposeTimelockBlocks(5) - await contracts.router.updateTimelockBlocks() - await contracts.router.proposeTimelockBlocks(6) - await expect(contracts.router.updateTimelockBlocks()).to.be.revertedWith( - 'TimelockInEffect', - ) - }) + // TODO: disabled in anticipation of MCM - it('prevents applying config updates', async () => { - await contracts.router.proposeTimelockBlocks(5) - await contracts.router.updateTimelockBlocks() + // describe('Timelock', () => { + // it('prevents applying timelock updates', async () => { + // await contracts.router.proposeTimelockBlocks(5) + // await contracts.router.updateTimelockBlocks() + // await contracts.router.proposeTimelockBlocks(6) + // await expect(contracts.router.updateTimelockBlocks()).to.be.revertedWith( + // 'TimelockInEffect', + // ) + // }) - await contracts.router.proposeConfigUpdate( - ids.routerId, - ethers.utils.defaultAbiCoder.encode( - ['uint16', 'uint96', 'bytes4', 'uint32[]'], - [2000, 1, 0x0ca76175, [300_000, 500_000]], - ), - ) - await expect( - contracts.router.updateConfig(ids.routerId), - ).to.be.revertedWith('TimelockInEffect') - }) + // it('prevents applying config updates', async () => { + // await contracts.router.proposeTimelockBlocks(5) + // await contracts.router.updateTimelockBlocks() - it('prevents applying contract updates', async () => { - await contracts.router.proposeTimelockBlocks(5) - await contracts.router.updateTimelockBlocks() + // await contracts.router.proposeConfigUpdate( + // ids.routerId, + // ethers.utils.defaultAbiCoder.encode( + // ['uint16', 'uint96', 'bytes4', 'uint32[]'], + // [2000, 1, 0x0ca76175, [300_000, 500_000]], + // ), + // ) + // await expect( + // contracts.router.updateConfig(ids.routerId), + // ).to.be.revertedWith('TimelockInEffect') + // }) - const coordinator2 = await factories.functionsCoordinatorFactory - .connect(roles.defaultAccount) - .deploy( - contracts.router.address, - ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'int256', - 'uint32', - 'uint96', - 'uint16', - 'uint256', - ], - [...Object.values(coordinatorConfig)], - ), - contracts.mockLinkEth.address, - ) + // it('prevents applying contract updates', async () => { + // await contracts.router.proposeTimelockBlocks(5) + // await contracts.router.updateTimelockBlocks() - await contracts.router.proposeContractsUpdate( - [ids.donId2], - [coordinator2.address], - ) + // const coordinator2 = await factories.functionsCoordinatorFactory + // .connect(roles.defaultAccount) + // .deploy( + // contracts.router.address, + // ethers.utils.defaultAbiCoder.encode( + // [ + // 'uint32', + // 'uint32', + // 'uint32', + // 'uint32', + // 'int256', + // 'uint32', + // 'uint96', + // 'uint16', + // 'uint256', + // ], + // [...Object.values(coordinatorConfig)], + // ), + // contracts.mockLinkEth.address, + // ) - await expect(contracts.router.updateContracts()).to.be.revertedWith( - 'TimelockInEffect', - ) - }) - }) + // await contracts.router.proposeContractsUpdate( + // [ids.donId2], + // [coordinator2.address], + // ) + + // await expect(contracts.router.updateContracts()).to.be.revertedWith( + // 'TimelockInEffect', + // ) + // }) + // }) describe('Emergency Pause', () => { it('has paused state visible', async () => { diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index 8eddd04029a..e945d96c49f 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -58,13 +58,13 @@ export const encodeReport = ( } export type FunctionsRouterConfig = { - maxConsumers: number + maxConsumersPerSubscription: number adminFee: number handleOracleFulfillmentSelector: string maxCallbackGasLimits: number[] } export const functionsRouterConfig: FunctionsRouterConfig = { - maxConsumers: 100, + maxConsumersPerSubscription: 100, adminFee: 0, handleOracleFulfillmentSelector: '0x0ca76175', maxCallbackGasLimits: [300_000, 500_000, 1_000_000], @@ -226,10 +226,10 @@ export function getSetupFactory(): () => { 0, linkEthRate, ) - const routerConfigBytes = ethers.utils.defaultAbiCoder.encode( - ['uint16', 'uint96', 'bytes4', 'uint32[]'], - [...Object.values(functionsRouterConfig)], - ) + // const routerConfigBytes = ethers.utils.defaultAbiCoder.encode( + // ['uint16', 'uint96', 'bytes4', 'uint32[]'], + // [...Object.values(functionsRouterConfig)], + // ) const startingTimelockBlocks = 0 const maxTimelockBlocks = 20 const router = await factories.functionsRouterFactory @@ -238,7 +238,7 @@ export function getSetupFactory(): () => { startingTimelockBlocks, maxTimelockBlocks, linkToken.address, - routerConfigBytes, + functionsRouterConfig, ) const coordinatorConfigBytes = ethers.utils.defaultAbiCoder.encode( [ diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 0cff7b99918..ffb047edd01 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -44,6 +44,18 @@ type FunctionsResponseCommitment struct { GasOverheadAfterCallback *big.Int } +type IFunctionsBillingConfig struct { + MaxCallbackGasLimit uint32 + FeedStalenessSeconds uint32 + GasOverheadBeforeCallback uint32 + GasOverheadAfterCallback uint32 + RequestTimeoutSeconds uint32 + DonFee *big.Int + MaxSupportedRequestDataVersion uint16 + FulfillmentGasPriceOverEstimationBP *big.Int + FallbackNativePerUnitLink *big.Int +} + type IFunctionsBillingRequestBilling struct { SubscriptionId uint64 Client common.Address @@ -64,8 +76,8 @@ type IFunctionsCoordinatorRequest struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPrice\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"},{\"internalType\":\"address\",\"name\":\"linkPriceFeed\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFeedData\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b50604051620059e7380380620059e7833981016040819052620000349162000458565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b03909216919091179055506200062a9350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060008060008060008060008980602001905181019062000219919062000568565b9850985098509850985098509850985098506000811362000251576040516321ea67b360e11b81526004810182905260240162000089565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b16608086018190526001600160501b038b1660a0870181905261ffff8b1660c0880181905260e088018b905261010090970189905260088054600160f01b9098026001600160f01b03600160a01b909302600160a01b600160f01b0319600160801b90950294909416600160801b600160f01b03196c0100000000000000000000000090990263ffffffff60601b196801000000000000000090970296909616600160401b600160801b03196401000000009098026001600160401b0319909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f9062000411908b908b908b908b908b908b908b908b908b9063ffffffff998a1681529789166020890152958816604088015293871660608701529190951660808501526001600160501b039490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b80516001600160a01b03811681146200043d57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b6000806000606084860312156200046e57600080fd5b620004798462000425565b602085810151919450906001600160401b03808211156200049957600080fd5b818701915087601f830112620004ae57600080fd5b815181811115620004c357620004c362000442565b604051601f8201601f19908116603f01168101908382118183101715620004ee57620004ee62000442565b816040528281528a868487010111156200050757600080fd5b600093505b828410156200052b57848401860151818501870152928501926200050c565b60008684830101528097505050505050506200054a6040850162000425565b90509250925092565b805163ffffffff811681146200043d57600080fd5b60008060008060008060008060006101208a8c0312156200058857600080fd5b620005938a62000553565b9850620005a360208b0162000553565b9750620005b360408b0162000553565b9650620005c360608b0162000553565b9550620005d360808b0162000553565b60a08b01519095506001600160501b0381168114620005f157600080fd5b60c08b015190945061ffff811681146200060a57600080fd5b8093505060e08a015191506101008a015190509295985092959850929598565b60805160a051615366620006816000396000818161068601528181610abd01528181610ee001528181610fbe0152818161183901528181611ad3015281816130aa01526139080152600061120a01526153666000f3fe608060405234801561001057600080fd5b50600436106101a35760003560e01c806381ff7048116100ee578063b1dc65a411610097578063d227d24511610071578063d227d24514610517578063d328a91e1461052a578063e3d0e71214610532578063f2fde38b1461054557600080fd5b8063b1dc65a4146103e6578063bdd7e880146103f9578063c3f909d41461041957600080fd5b80638da5cb5b116100c85780638da5cb5b14610388578063af1296d3146103b0578063afcb95d7146103c657600080fd5b806381ff7048146102e557806385b214cf146103525780638cc6acce1461037557600080fd5b806366316d8d11610150578063807560311161012a57806380756031146102b557806381411834146102c857806381f1b938146102dd57600080fd5b806366316d8d1461028757806379ba50971461029a5780637f15e166146102a257600080fd5b806326ceabac1161018157806326ceabac146102395780632a905ccc1461024c578063533989871461027157600080fd5b8063083a5466146101a85780630e7ada39146101bd578063181f5a77146101f0575b600080fd5b6101bb6101b6366004613b82565b610558565b005b6101d06101cb366004613d8c565b6105ad565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b61022c6040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101e79190613ec1565b6101bb610247366004613edb565b6105db565b610254610681565b6040516bffffffffffffffffffffffff90911681526020016101e7565b61027961073f565b6040516101e7929190613f49565b6101bb610295366004613fd9565b6109c3565b6101bb610b7d565b6101bb6102b0366004613b82565b610c7f565b6101bb6102c3366004614012565b610ccf565b6102d0610d86565b6040516101e79190614067565b61022c610df5565b61032f60015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101e7565b61036561036036600461407a565b610ec6565b60405190151581526020016101e7565b6101bb610383366004614093565b610fa6565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101e7565b6103b861101e565b6040519081526020016101e7565b6040805160018152600060208201819052918101919091526060016101e7565b6101bb6103f4366004614115565b611111565b61040c6104073660046141cc565b6117c8565b6040516101e7919061432e565b600854600954600a54600c546040805163ffffffff80871682526401000000008704811660208301526801000000000000000087048116928201929092526c01000000000000000000000000808704831660608301527001000000000000000000000000000000008704909216608082015274010000000000000000000000000000000000000000860469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090950461ffff1660c086015260e08501939093526101008401919091520473ffffffffffffffffffffffffffffffffffffffff16610120820152610140016101e7565b61025461052536600461433d565b611acf565b61022c611c9b565b6101bb610540366004614456565b611cf2565b6101bb610553366004613edb565b61271e565b61056061272f565b600081900361059b576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105a88284836145c4565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061061957503373ffffffffffffffffffffffffffffffffffffffff821614155b15610650576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e6020526040812061067e91613ac7565b50565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa1580156106ef573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526107359190810190614705565b5090949350505050565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107a757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161077c575b505050505090506000815167ffffffffffffffff8111156107ca576107ca613bc4565b6040519080825280602002602001820160405280156107fd57816020015b60608152602001906001900390816107e85790505b50905060005b82518110156109b957600e600084838151811061082257610822614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461086f90614523565b90506000036108aa576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e60008483815181106108c0576108c0614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001908152602001600020805461090d90614523565b80601f016020809104026020016040519081016040528092919081815260200182805461093990614523565b80156109865780601f1061095b57610100808354040283529160200191610986565b820191906000526020600020905b81548152906001019060200180831161096957829003601f168201915b505050505082828151811061099d5761099d614800565b6020026020010181905250806109b29061485e565b9050610803565b5090939092509050565b6109cb6127b2565b806bffffffffffffffffffffffff16600003610a015750336000908152600b60205260409020546bffffffffffffffffffffffff165b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a5b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a889084906bffffffffffffffffffffffff16614896565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506000610adf7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85811660048301526bffffffffffffffffffffffff85166024830152919250908216906366316d8d90604401600060405180830381600087803b158015610b6057600080fd5b505af1158015610b74573d6000803e3d6000fd5b50505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610c03576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c8761272f565b6000819003610cc2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105a88284836145c4565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610d1a5750610cf933612943565b8015610d1a57503373ffffffffffffffffffffffffffffffffffffffff8416145b610d50576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610d808284836145c4565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610deb57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dc0575b5050505050905090565b6060600f8054610e0490614523565b9050600003610e3f576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610e4c90614523565b80601f0160208091040260200160405190810160405280929190818152602001828054610e7890614523565b8015610deb5780601f10610e9a57610100808354040283529160200191610deb565b820191906000526020600020905b815481529060010190602001808311610ea857509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610f37576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260076020526040902054610f5257506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f41690610f959084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611015576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61067e81612a2c565b600854600c54604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093640100000000900463ffffffff169283151592859283926c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169163feaf968c9160048083019260a09291908290030181865afa1580156110b8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110dc91906148dc565b509350509250508280156110fe57506110f5814261492c565b8463ffffffff16105b1561110957600a5491505b509392505050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146111f8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610bfa565b6112068b8b8b8b8b8b612d35565b60007f00000000000000000000000000000000000000000000000000000000000000001561126357600282602001518360400151611244919061493f565b61124e9190614987565b61125990600161493f565b60ff169050611279565b602082015161127390600161493f565b60ff1690505b8881146112e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610bfa565b88871461134b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610bfa565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561138e5761138e6149a9565b600281111561139f5761139f6149a9565b90525090506002816020015160028111156113bc576113bc6149a9565b14801561140357506006816000015160ff16815481106113de576113de614800565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611469576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610bfa565b5050505050611476613b01565b6000808a8a6040516114899291906149d8565b6040519081900381206114a0918e906020016149e8565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117aa57600060018489846020811061150957611509614800565b61151691901a601b61493f565b8e8e8681811061152857611528614800565b905060200201358d8d8781811061154157611541614800565b905060200201356040516000815260200160405260405161157e949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115a0573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff80821685529296509294508401916101009004166002811115611620576116206149a9565b6002811115611631576116316149a9565b905250925060018360200151600281111561164e5761164e6149a9565b146116b5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610bfa565b8251600090879060ff16601f81106116cf576116cf614800565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611751576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610bfa565b8086846000015160ff16601f811061176b5761176b614800565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261179660018661493f565b945050806117a39061485e565b90506114ea565b5050506117bb833383858e8e612de3565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611890576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61189d60408301836149fc565b90506000036118d7576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a001604052808460600160208101906118f79190614a61565b67ffffffffffffffff16815260209081019061191590860186613edb565b73ffffffffffffffffffffffffffffffffffffffff16815260200161194060e0860160c08701614a7e565b63ffffffff1681523a6020820152604001611962610100860160e08701614a9b565b6bffffffffffffffffffffffff16905290506119cf61198460408501856149fc565b8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506119c99250505060a0860160808701614ab8565b83612fb1565b91506119de6020840184613edb565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611a2e9190614a61565b611a3e6040890160208a01613edb565b611a4b60408a018a6149fc565b611a5b60a08c0160808d01614ab8565b60a08c0135611a7060e08e0160c08f01614a7e565b8c604051602001611a81919061432e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611ac1999897969594939291614ad5565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611b6f57600080fd5b505afa158015611b83573d6000803e3d6000fd5b50505050620f4240821115611bc4576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611bce610681565b905060006040518060a001604052808967ffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018663ffffffff168152602001858152602001836bffffffffffffffffffffffff1681525090506000611c7288888080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508692506105ad915050565b69ffffffffffffffffffff169050611c8c868683866134a7565b93505050505b95945050505050565b6060600d8054611caa90614523565b9050600003611ce5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610e4c90614523565b855185518560ff16601f831115611d65576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610bfa565b80600003611dcf576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610bfa565b818314611e5d576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610bfa565b611e68816003614b99565b8311611ed0576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610bfa565b611ed861272f565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f1f9088613617565b600554156120d457600554600090611f399060019061492c565b9050600060058281548110611f5057611f50614800565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611f8a57611f8a614800565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061200a5761200a614bb0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061207357612073614bb0565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f1f915050565b60005b81515181101561253b57600060046000846000015184815181106120fd576120fd614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff166002811115612147576121476149a9565b146121ae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610bfa565b6040805180820190915260ff821681526001602082015282518051600491600091859081106121df576121df614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001617610100836002811115612280576122806149a9565b0217905550600091506122909050565b60046000846020015184815181106122aa576122aa614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156122f4576122f46149a9565b1461235b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610bfa565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061238e5761238e614800565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561242f5761242f6149a9565b02179055505082518051600592508390811061244d5761244d614800565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124c9576124c9614800565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055806125338161485e565b9150506120d7565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff43811682029290921780855592048116929182916014916125f391849174010000000000000000000000000000000000000000900416614bdf565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126524630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613634565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612709988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614bfc565b60405180910390a15050505050505050505050565b61272661272f565b61067e816136df565b60005473ffffffffffffffffffffffffffffffffffffffff1633146127b0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bfa565b565b60006127bc610d86565b905080516000036127f9576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612818916bffffffffffffffffffffffff16614c92565b905060005b82518110156128e45781600b600085848151811061283d5761283d614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff166128a59190614cbd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806128dd9061485e565b905061281d565b5081516128f19082614ce2565b600c80546000906129119084906bffffffffffffffffffffffff16614896565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b60008060068054806020026020016040519081016040528092919081815260200182805480156129a957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161297e575b5050505050905060005b8151811015612a22578373ffffffffffffffffffffffffffffffffffffffff168282815181106129e5576129e5614800565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612a12575060019392505050565b612a1b8161485e565b90506129b3565b5060009392505050565b600080600080600080600080600089806020019051810190612a4e9190614d12565b98509850985098509850985098509850985060008113612a9d576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bfa565b604080516101208101825263ffffffff808c168083528b8216602084018190528b83168486018190528b841660608601819052938b166080860181905269ffffffffffffffffffff8b1660a0870181905261ffff8b1660c0880181905260e088018b9052610100909701899052600880547e010000000000000000000000000000000000000000000000000000000000009098027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff740100000000000000000000000000000000000000009093027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff700100000000000000000000000000000000909502949094167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff6c010000000000000000000000009099027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff68010000000000000000909702969096167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff6401000000009098027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1690981799909917959095169590951792909217949094169490941792909217929092161790556009839055600a829055517f3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f90612d21908b908b908b908b908b908b908b908b908b9063ffffffff998a16815297891660208901529588166040880152938716606087015291909516608085015269ffffffffffffffffffff9490941660a084015261ffff9390931660c083015260e08201929092526101008101919091526101200190565b60405180910390a150505050505050505050565b6000612d42826020614b99565b612d4d856020614b99565b612d5988610144614dbe565b612d639190614dbe565b612d6d9190614dbe565b612d78906000614dbe565b9050368114610b74576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610bfa565b606080808080612df586880188614eac565b8451949950929750909550935091501580612e1257508351855114155b80612e1f57508251855114155b80612e2c57508151855114155b80612e3957508051855114155b15612e70576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8551811015612fa3576000612f08878381518110612e9357612e93614800565b6020026020010151878481518110612ead57612ead614800565b6020026020010151878581518110612ec757612ec7614800565b6020026020010151878681518110612ee157612ee1614800565b6020026020010151878781518110612efb57612efb614800565b60200260200101516137d4565b90506000816006811115612f1e57612f1e6149a9565b1480612f3b57506001816006811115612f3957612f396149a9565b145b15612f9257868281518110612f5257612f52614800565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b50612f9c8161485e565b9050612e73565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810182905261014081019190915260085461ffff7e0100000000000000000000000000000000000000000000000000000000000090910481169084161115613070576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061307c85846105ad565b905060006130a4846040015185606001518469ffffffffffffffffffff1687608001516134a7565b905060007f000000000000000000000000000000000000000000000000000000000000000085516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152909150600090819073ffffffffffffffffffffffffffffffffffffffff84169063a47c769690602401600060405180830381865afa158015613148573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261318e9190810190614f89565b50505060208a01518a516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff9091166024820152939550909350600092908616915063674603d090604401606060405180830381865afa158015613220573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132449190615088565b509150506bffffffffffffffffffffffff85166132618385614896565b6bffffffffffffffffffffffff1610156132a7576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613326308a602001518b600001518560016132c491906150da565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001876bffffffffffffffffffffffff168152602001600860000160109054906101000a900463ffffffff1663ffffffff16426133e79190614dbe565b64ffffffffff168152602080820184905269ffffffffffffffffffff8a1660408084019190915260085463ffffffff680100000000000000008204811660608601526c01000000000000000000000000909104166080909301929092529051919950613455918a910161432e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291815281516020928301206000938452600790925290912055509498975050505050505050565b6000806134b261101e565b9050600081136134f1576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bfa565b60085460009087906135279063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614bdf565b6135319190614bdf565b63ffffffff16905060006127106008600101548861354f9190614b99565b61355991906150fb565b6135639088614dbe565b90506000838361357b84670de0b6b3a7640000614b99565b6135859190614b99565b61358f91906150fb565b905060006135ae6bffffffffffffffffffffffff808916908a16614dbe565b90506135c6816b033b2e3c9fd0803ce800000061492c565b8211156135ff576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6136098183614dbe565b9a9950505050505050505050565b6000613621610d86565b511115613630576136306127b2565b5050565b6000808a8a8a8a8a8a8a8a8a6040516020016136589998979695949392919061510f565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361375e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bfa565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906137eb91906151b9565b60008881526007602052604090205490915061380b576002915050611c92565b8060405160200161381c919061432e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a815260079093529120541461386e576006915050611c92565b600061387861101e565b9050600081136138b7576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101829052602401610bfa565b6000816138cc3a670de0b6b3a7640000614b99565b6138d691906150fb565b905060008361014001518461012001516138f0919061528c565b6139019064ffffffffff1683614b99565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288c8c878a610100015169ffffffffffffffffffff16886139629190614cbd565b338c6040518763ffffffff1660e01b8152600401613985969594939291906152aa565b60408051808303816000875af11580156139a3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139c79190615326565b909250905060008260068111156139e0576139e06149a9565b14806139fd575060018260068111156139fb576139fb6149a9565b145b15613ab85760008c815260076020526040812055613a1b8184614cbd565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100880151600c805469ffffffffffffffffffff90921693909291613a8991859116614cbd565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509a9950505050505050505050565b508054613ad390614523565b6000825580601f10613ae3575050565b601f01602090049060005260206000209081019061067e9190613b20565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613b355760008155600101613b21565b5090565b60008083601f840112613b4b57600080fd5b50813567ffffffffffffffff811115613b6357600080fd5b602083019150836020828501011115613b7b57600080fd5b9250929050565b60008060208385031215613b9557600080fd5b823567ffffffffffffffff811115613bac57600080fd5b613bb885828601613b39565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613c1657613c16613bc4565b60405290565b604051610160810167ffffffffffffffff81118282101715613c1657613c16613bc4565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613c8757613c87613bc4565b604052919050565b600082601f830112613ca057600080fd5b813567ffffffffffffffff811115613cba57613cba613bc4565b613ceb60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613c40565b818152846020838601011115613d0057600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff8116811461067e57600080fd5b8035610fa181613d1d565b73ffffffffffffffffffffffffffffffffffffffff8116811461067e57600080fd5b63ffffffff8116811461067e57600080fd5b6bffffffffffffffffffffffff8116811461067e57600080fd5b60008082840360c0811215613da057600080fd5b833567ffffffffffffffff811115613db757600080fd5b613dc386828701613c8f565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613df657600080fd5b50613dff613bf3565b6020840135613e0d81613d1d565b81526040840135613e1d81613d3e565b60208201526060840135613e3081613d60565b60408201526080840135606082015260a0840135613e4d81613d72565b6080820152919491935090915050565b6000815180845260005b81811015613e8357602081850181015186830182015201613e67565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613ed46020830184613e5d565b9392505050565b600060208284031215613eed57600080fd5b8135613ed481613d3e565b600081518084526020808501945080840160005b83811015613f3e57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613f0c565b509495945050505050565b604081526000613f5c6040830185613ef8565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613fca577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613fb8838351613e5d565b94860194925090850190600101613f7e565b50909998505050505050505050565b60008060408385031215613fec57600080fd5b8235613ff781613d3e565b9150602083013561400781613d72565b809150509250929050565b60008060006040848603121561402757600080fd5b833561403281613d3e565b9250602084013567ffffffffffffffff81111561404e57600080fd5b61405a86828701613b39565b9497909650939450505050565b602081526000613ed46020830184613ef8565b60006020828403121561408c57600080fd5b5035919050565b6000602082840312156140a557600080fd5b813567ffffffffffffffff8111156140bc57600080fd5b6140c884828501613c8f565b949350505050565b60008083601f8401126140e257600080fd5b50813567ffffffffffffffff8111156140fa57600080fd5b6020830191508360208260051b8501011115613b7b57600080fd5b60008060008060008060008060e0898b03121561413157600080fd5b606089018a81111561414257600080fd5b8998503567ffffffffffffffff8082111561415c57600080fd5b6141688c838d01613b39565b909950975060808b013591508082111561418157600080fd5b61418d8c838d016140d0565b909750955060a08b01359150808211156141a657600080fd5b506141b38b828c016140d0565b999c989b50969995989497949560c00135949350505050565b6000602082840312156141de57600080fd5b813567ffffffffffffffff8111156141f557600080fd5b82016101008185031215613ed457600080fd5b80516bffffffffffffffffffffffff1682526020810151614241602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151614269604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614285606084018267ffffffffffffffff169052565b50608081015161429d608084018263ffffffff169052565b5060a08101516142bd60a08401826bffffffffffffffffffffffff169052565b5060c08101516142d660c084018264ffffffffff169052565b5060e081015160e0830152610100808201516142ff8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610d80565b61016081016105d58284614208565b60008060008060006080868803121561435557600080fd5b853561436081613d1d565b9450602086013567ffffffffffffffff81111561437c57600080fd5b61438888828901613b39565b909550935050604086013561439c81613d60565b949793965091946060013592915050565b600067ffffffffffffffff8211156143c7576143c7613bc4565b5060051b60200190565b600082601f8301126143e257600080fd5b813560206143f76143f2836143ad565b613c40565b82815260059290921b8401810191818101908684111561441657600080fd5b8286015b8481101561443a57803561442d81613d3e565b835291830191830161441a565b509695505050505050565b803560ff81168114610fa157600080fd5b60008060008060008060c0878903121561446f57600080fd5b863567ffffffffffffffff8082111561448757600080fd5b6144938a838b016143d1565b975060208901359150808211156144a957600080fd5b6144b58a838b016143d1565b96506144c360408a01614445565b955060608901359150808211156144d957600080fd5b6144e58a838b01613c8f565b94506144f360808a01613d33565b935060a089013591508082111561450957600080fd5b5061451689828a01613c8f565b9150509295509295509295565b600181811c9082168061453757607f821691505b602082108103614570577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105a857600081815260208120601f850160051c8101602086101561459d5750805b601f850160051c820191505b818110156145bc578281556001016145a9565b505050505050565b67ffffffffffffffff8311156145dc576145dc613bc4565b6145f0836145ea8354614523565b83614576565b6000601f841160018114614642576000851561460c5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556146d8565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156146915786850135825560209485019460019092019101614671565b50868210156146cc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff8116811461067e57600080fd5b8051610fa181613d72565b8051610fa181613d60565b6000806000806080858703121561471b57600080fd5b8451614726816146df565b8094505060208086015161473981613d72565b60408701519094507fffffffff000000000000000000000000000000000000000000000000000000008116811461476f57600080fd5b606087015190935067ffffffffffffffff81111561478c57600080fd5b8601601f8101881361479d57600080fd5b80516147ab6143f2826143ad565b81815260059190911b8201830190838101908a8311156147ca57600080fd5b928401925b828410156147f15783516147e281613d60565b825292840192908401906147cf565b979a9699509497505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361488f5761488f61482f565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156148bb576148bb61482f565b5092915050565b805169ffffffffffffffffffff81168114610fa157600080fd5b600080600080600060a086880312156148f457600080fd5b6148fd866148c2565b9450602086015193506040860151925060608601519150614920608087016148c2565b90509295509295909350565b818103818111156105d5576105d561482f565b60ff81811683821601908111156105d5576105d561482f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff83168061499a5761499a614958565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614a3157600080fd5b83018035915067ffffffffffffffff821115614a4c57600080fd5b602001915036819003821315613b7b57600080fd5b600060208284031215614a7357600080fd5b8135613ed481613d1d565b600060208284031215614a9057600080fd5b8135613ed481613d60565b600060208284031215614aad57600080fd5b8135613ed481613d72565b600060208284031215614aca57600080fd5b8135613ed4816146df565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614b7260c085018763ffffffff169052565b818482030160e0850152614b8882820186613e5d565b9d9c50505050505050505050505050565b80820281158282048414176105d5576105d561482f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff8181168382160190808211156148bb576148bb61482f565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614c2c8184018a613ef8565b90508281036080840152614c408189613ef8565b905060ff871660a084015282810360c0840152614c5d8187613e5d565b905067ffffffffffffffff851660e0840152828103610100840152614c828185613e5d565b9c9b505050505050505050505050565b60006bffffffffffffffffffffffff80841680614cb157614cb1614958565b92169190910492915050565b6bffffffffffffffffffffffff8181168382160190808211156148bb576148bb61482f565b6bffffffffffffffffffffffff818116838216028082169190828114614d0a57614d0a61482f565b505092915050565b60008060008060008060008060006101208a8c031215614d3157600080fd5b8951614d3c81613d60565b60208b0151909950614d4d81613d60565b60408b0151909850614d5e81613d60565b60608b0151909750614d6f81613d60565b60808b0151909650614d8081613d60565b9450614d8e60a08b016148c2565b935060c08a0151614d9e816146df565b8093505060e08a015191506101008a015190509295985092959850929598565b808201808211156105d5576105d561482f565b600082601f830112614de257600080fd5b81356020614df26143f2836143ad565b82815260059290921b84018101918181019086841115614e1157600080fd5b8286015b8481101561443a5780358352918301918301614e15565b600082601f830112614e3d57600080fd5b81356020614e4d6143f2836143ad565b82815260059290921b84018101918181019086841115614e6c57600080fd5b8286015b8481101561443a57803567ffffffffffffffff811115614e905760008081fd5b614e9e8986838b0101613c8f565b845250918301918301614e70565b600080600080600060a08688031215614ec457600080fd5b853567ffffffffffffffff80821115614edc57600080fd5b614ee889838a01614dd1565b96506020880135915080821115614efe57600080fd5b614f0a89838a01614e2c565b95506040880135915080821115614f2057600080fd5b614f2c89838a01614e2c565b94506060880135915080821115614f4257600080fd5b614f4e89838a01614e2c565b93506080880135915080821115614f6457600080fd5b50614f7188828901614e2c565b9150509295509295909350565b8051610fa181613d3e565b60008060008060008060c08789031215614fa257600080fd5b8651614fad81613d72565b80965050602080880151614fc081613d3e565b6040890151909650614fd181613d72565b6060890151909550614fe281613d3e565b608089015190945067ffffffffffffffff811115614fff57600080fd5b8801601f81018a1361501057600080fd5b805161501e6143f2826143ad565b81815260059190911b8201830190838101908c83111561503d57600080fd5b928401925b8284101561506457835161505581613d3e565b82529284019290840190615042565b809650505050505060a087015190509295509295509295565b8051610fa181613d1d565b60008060006060848603121561509d57600080fd5b835180151581146150ad57600080fd5b60208501519093506150be81613d1d565b60408501519092506150cf81613d1d565b809150509250925092565b67ffffffffffffffff8181168382160190808211156148bb576148bb61482f565b60008261510a5761510a614958565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151568285018b613ef8565b9150838203608085015261516a828a613ef8565b915060ff881660a085015283820360c08501526151878288613e5d565b90861660e08501528381036101008501529050614c828185613e5d565b805164ffffffffff81168114610fa157600080fd5b600061016082840312156151cc57600080fd5b6151d4613c1c565b6151dd836146ef565b81526151eb60208401614f7e565b60208201526151fc60408401614f7e565b604082015261520d6060840161507d565b606082015261521e608084016146fa565b608082015261522f60a084016146ef565b60a082015261524060c084016151a4565b60c082015260e083015160e082015261010061525d8185016148c2565b9082015261012061526f8482016151a4565b908201526101406152818482016151a4565b908201529392505050565b64ffffffffff8181168382160190808211156148bb576148bb61482f565b60006102008083526152be8184018a613e5d565b905082810360208401526152d28189613e5d565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff86166080850152915061531b905060a0830184614208565b979650505050505050565b6000806040838503121561533957600080fd5b82516007811061534857600080fd5b602084015190925061400781613d7256fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"indexed\":false,\"internalType\":\"structIFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structIFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005cd638038062005cd6833981016040819052620000349162000405565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006709350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000818060200190518101906200020d919062000522565b905060008161010001511362000240578061010001516040516321ea67b360e11b81526004016200008991815260200190565b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff16600160f01b026001600160f01b036001600160501b03909216600160a01b02600160a01b600160f01b031963ffffffff948516600160801b0216600160801b600160f01b03199585166c010000000000000000000000000263ffffffff60601b19978616680100000000000000000297909716600160401b600160801b0319998616640100000000026001600160401b0319909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517ffc10ed3768699b4370d710cd8ffbc7efdc5a691e42af93f2fe3d0ba7c33556589062000367908390620005dd565b60405180910390a15050565b80516001600160a01b03811681146200038b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60405161012081016001600160401b0381118282101715620003cc57620003cc62000390565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620003fd57620003fd62000390565b604052919050565b6000806000606084860312156200041b57600080fd5b620004268462000373565b602085810151919450906001600160401b03808211156200044657600080fd5b818701915087601f8301126200045b57600080fd5b81518181111562000470576200047062000390565b62000484601f8201601f19168501620003d2565b915080825288848285010111156200049b57600080fd5b60005b81811015620004bb5783810185015183820186015284016200049e565b50600084828401015250809450505050620004d96040850162000373565b90509250925092565b805163ffffffff811681146200038b57600080fd5b80516001600160501b03811681146200038b57600080fd5b805161ffff811681146200038b57600080fd5b600061012082840312156200053657600080fd5b62000540620003a6565b6200054b83620004e2565b81526200055b60208401620004e2565b60208201526200056e60408401620004e2565b60408201526200058160608401620004e2565b60608201526200059460808401620004e2565b6080820152620005a760a08401620004f7565b60a0820152620005ba60c084016200050f565b60c082015260e08381015190820152610100928301519281019290925250919050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a08301516200063c60a08401826001600160501b03169052565b5060c08301516200065360c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60805160a051615608620006ce600039600081816106cc01528181610aa701528181610cd50152818161101f015281816110fd0152818161188501528181611b1f015281816132f40152613a2a0152600061125601526156086000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381ff7048116100ee578063bdd7e88011610097578063d328a91e11610071578063d328a91e1461055b578063e3d0e71214610563578063e4ddcea614610576578063f2fde38b1461058c57600080fd5b8063bdd7e880146103f6578063c3f909d414610416578063d227d2451461054857600080fd5b80638da5cb5b116100c85780638da5cb5b1461039b578063afcb95d7146103c3578063b1dc65a4146103e357600080fd5b806381ff7048146102f857806385b214cf146103655780638cc6acce1461038857600080fd5b806366316d8d1161015b5780637f15e166116101355780637f15e166146102b557806380756031146102c857806381411834146102db57806381f1b938146102f057600080fd5b806366316d8d1461029257806379ba5097146102a55780637d480787146102ad57600080fd5b806326ceabac1161018c57806326ceabac146102445780632a905ccc14610257578063533989871461027c57600080fd5b8063083a5466146101b35780630e7ada39146101c8578063181f5a77146101fb575b600080fd5b6101c66101c1366004613cc9565b61059f565b005b6101db6101d6366004613f3d565b6105f4565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b6102376040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101f29190614072565b6101c661025236600461408c565b610622565b61025f6106c8565b6040516bffffffffffffffffffffffff90911681526020016101f2565b610284610784565b6040516101f29291906140fa565b6101c66102a036600461418a565b6109ab565b6101c6610b64565b6101c6610c66565b6101c66102c3366004613cc9565b610dbe565b6101c66102d63660046141c3565b610e0e565b6102e3610ec5565b6040516101f29190614218565b610237610f34565b61034260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101f2565b61037861037336600461422b565b611005565b60405190151581526020016101f2565b6101c6610396366004614244565b6110e5565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101f2565b6040805160018152600060208201819052918101919091526060016101f2565b6101c66103f13660046142c6565b61115d565b61040961040436600461437d565b611814565b6040516101f291906144df565b61053b6040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090910461ffff1660c082015260095460e0820152600a5461010082015290565b6040516101f291906144ee565b61025f610556366004614582565b611b1b565b610237611ccd565b6101c661057136600461469b565b611d24565b61057e612750565b6040519081526020016101f2565b6101c661059a36600461408c565b612945565b6105a7612956565b60008190036105e2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105ef828483614801565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061066057503373ffffffffffffffffffffffffffffffffffffffff821614155b15610697576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e602052604081206106c591613c0e565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa158015610735573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261077b919081019061494d565b60200151905090565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107ec57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116107c1575b505050505090506000815167ffffffffffffffff81111561080f5761080f613d0b565b60405190808252806020026020018201604052801561084257816020015b606081526020019060019003908161082d5790505b50905060005b82518110156109a1576000600e600085848151811061086957610869614a77565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546108b690614768565b80601f01602080910402602001604051908101604052809291908181526020018280546108e290614768565b801561092f5780601f106109045761010080835404028352916020019161092f565b820191906000526020600020905b81548152906001019060200180831161091257829003601f168201915b505050505090508051600003610971576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8083838151811061098457610984614a77565b6020026020010181905250508061099a90614ad5565b9050610848565b5090939092509050565b6109b36129d9565b806bffffffffffffffffffffffff166000036109ed5750336000908152600b60205260409020546bffffffffffffffffffffffff16610a47565b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a47576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a749084906bffffffffffffffffffffffff16614b0d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ac97f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610b4857600080fd5b505af1158015610b5c573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610bea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c6e612b84565b610c766129d9565b6000610c80610ec5565b905060005b8151811015610dba57336000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610d2157610d21614a77565b6020026020010151836040518363ffffffff1660e01b8152600401610d7692919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610d9057600080fd5b505af1158015610da4573d6000803e3d6000fd5b505050505080610db390614ad5565b9050610c85565b5050565b610dc6612956565b6000819003610e01576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105ef828483614801565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610e595750610e3833612b8c565b8015610e5957503373ffffffffffffffffffffffffffffffffffffffff8416145b610e8f576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610ebf828483614801565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610eff575b5050505050905090565b6060600f8054610f4390614768565b9050600003610f7e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610f8b90614768565b80601f0160208091040260200160405190810160405280929190818152602001828054610fb790614768565b8015610f2a5780601f10610fd957610100808354040283529160200191610f2a565b820191906000526020600020905b815481529060010190602001808311610fe757509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611076576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526007602052604090205461109157506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906110d49084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611154576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c581612c75565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611244576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610be1565b6112528b8b8b8b8b8b612ec8565b60007f0000000000000000000000000000000000000000000000000000000000000000156112af576002826020015183604001516112909190614b32565b61129a9190614b7a565b6112a5906001614b32565b60ff1690506112c5565b60208201516112bf906001614b32565b60ff1690505b88811461132e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610be1565b888714611397576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610be1565b3360009081526004602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156113da576113da614b9c565b60028111156113eb576113eb614b9c565b905250905060028160200151600281111561140857611408614b9c565b14801561144f57506006816000015160ff168154811061142a5761142a614a77565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114b5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610be1565b50505050506114c2613c48565b6000808a8a6040516114d5929190614bcb565b6040519081900381206114ec918e90602001614bdb565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117f657600060018489846020811061155557611555614a77565b61156291901a601b614b32565b8e8e8681811061157457611574614a77565b905060200201358d8d8781811061158d5761158d614a77565b90506020020135604051600081526020016040526040516115ca949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115ec573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561166c5761166c614b9c565b600281111561167d5761167d614b9c565b905250925060018360200151600281111561169a5761169a614b9c565b14611701576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610be1565b8251600090879060ff16601f811061171b5761171b614a77565b602002015173ffffffffffffffffffffffffffffffffffffffff161461179d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610be1565b8086846000015160ff16601f81106117b7576117b7614a77565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526117e2600186614b32565b945050806117ef90614ad5565b9050611536565b505050611807833383858e8e612f7f565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146118dc576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6118e96040830183614bef565b9050600003611923576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a001604052808460600160208101906119439190614c54565b67ffffffffffffffff1681526020908101906119619086018661408c565b73ffffffffffffffffffffffffffffffffffffffff16815260200161198c60e0860160c08701614c71565b63ffffffff1681523a60208201526040016119ae610100860160e08701614c8e565b6bffffffffffffffffffffffff1690529050611a1b6119d06040850185614bef565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a159250505060a0860160808701614cab565b8361314d565b9150611a2a602084018461408c565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611a7a9190614c54565b611a8a6040890160208a0161408c565b611a9760408a018a614bef565b611aa760a08c0160808d01614cab565b60a08c0135611abc60e08e0160c08f01614c71565b8c604051602001611acd91906144df565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b0d999897969594939291614cc8565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bbb57600080fd5b505afa158015611bcf573d6000803e3d6000fd5b505050620f42408311159050611c11576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c1b6106c8565b90506000611ca587878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805160a08101825267ffffffffffffffff8e16815233602082015263ffffffff8b1691810191909152606081018990526bffffffffffffffffffffffff8716608082015291506105f49050565b69ffffffffffffffffffff169050611cbf858583856136d3565b925050505b95945050505050565b6060600d8054611cdc90614768565b9050600003611d17576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610f8b90614768565b855185518560ff16601f831115611d97576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610be1565b80600003611e01576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610be1565b818314611e8f576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610be1565b611e9a816003614d8c565b8311611f02576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610be1565b611f0a612956565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f51908861379b565b6005541561210657600554600090611f6b90600190614da3565b9050600060058281548110611f8257611f82614a77565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fbc57611fbc614a77565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061203c5761203c614db6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120a5576120a5614db6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f51915050565b60005b81515181101561256d576000600460008460000151848151811061212f5761212f614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561217957612179614b9c565b146121e0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610be1565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061221157612211614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122b2576122b2614b9c565b0217905550600091506122c29050565b60046000846020015184815181106122dc576122dc614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561232657612326614b9c565b1461238d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610be1565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123c0576123c0614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561246157612461614b9c565b02179055505082518051600592508390811061247f5761247f614a77565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124fb576124fb614a77565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061256581614ad5565b915050612109565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161262591849174010000000000000000000000000000000000000000900416614de5565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126844630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516137b4565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861273b988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614e02565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116838501526c01000000000000000000000000808304821660608501527001000000000000000000000000000000008304909116608084015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a0808501919091527e0100000000000000000000000000000000000000000000000000000000000090920461ffff1660c084015260095460e0840152600a54610100840152600c5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa158015612897573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128bb9190614eb2565b5093505092505080426128ce9190614da3565b836020015163ffffffff161080156128f057506000836020015163ffffffff16115b156129015750506101000151919050565b6000821361293e576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610be1565b5092915050565b61294d612956565b6106c58161385f565b60005473ffffffffffffffffffffffffffffffffffffffff1633146129d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610be1565b565b600c546bffffffffffffffffffffffff166000036129f357565b60006129fd610ec5565b90508051600003612a3a576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612a59916bffffffffffffffffffffffff16614f02565b905060005b8251811015612b255781600b6000858481518110612a7e57612a7e614a77565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612ae69190614f2d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612b1e90614ad5565b9050612a5e565b508151612b329082614f52565b600c8054600090612b529084906bffffffffffffffffffffffff16614b0d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6129d7612956565b6000806006805480602002602001604051908101604052809291908181526020018280548015612bf257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612bc7575b5050505050905060005b8151811015612c6b578373ffffffffffffffffffffffffffffffffffffffff16828281518110612c2e57612c2e614a77565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612c5b575060019392505050565b612c6481614ad5565b9050612bfc565b5060009392505050565b600081806020019051810190612c8b9190614f82565b9050600081610100015113612cd5578061010001516040517f43d4cf66000000000000000000000000000000000000000000000000000000008152600401610be191815260200190565b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff167e01000000000000000000000000000000000000000000000000000000000000027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff69ffffffffffffffffffff90921674010000000000000000000000000000000000000000027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff63ffffffff94851670010000000000000000000000000000000002167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff9585166c01000000000000000000000000027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff9786166801000000000000000002979097167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff998616640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517ffc10ed3768699b4370d710cd8ffbc7efdc5a691e42af93f2fe3d0ba7c335565890612ebc9083906144ee565b60405180910390a15050565b6000612ed5826020614d8c565b612ee0856020614d8c565b612eec8861014461502c565b612ef6919061502c565b612f00919061502c565b612f0b90600061502c565b9050368114612f76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610be1565b50505050505050565b606080808080612f918688018861511a565b8451949950929750909550935091501580612fae57508351855114155b80612fbb57508251855114155b80612fc857508151855114155b80612fd557508051855114155b1561300c576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561313f5760006130a487838151811061302f5761302f614a77565b602002602001015187848151811061304957613049614a77565b602002602001015187858151811061306357613063614a77565b602002602001015187868151811061307d5761307d614a77565b602002602001015187878151811061309757613097614a77565b6020026020010151613954565b905060008160068111156130ba576130ba614b9c565b14806130d7575060018160068111156130d5576130d5614b9c565b145b1561312e578682815181106130ee576130ee614a77565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061313881614ad5565b905061300f565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015269ffffffffffffffffffff7401000000000000000000000000000000000000000083041660a082015261ffff7e01000000000000000000000000000000000000000000000000000000000000909204821660c0820181905260095460e0830152600a546101008301529091851611156132ba576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006132c686856105f4565b905060006132ee856040015186606001518469ffffffffffffffffffff1688608001516136d3565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa158015613390573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526133d6919081019061525b565b9050826bffffffffffffffffffffffff16816040015182600001516133fb9190614b0d565b6bffffffffffffffffffffffff161015613441576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff909116602482015260009184169063674603d090604401606060405180830381865afa1580156134c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134ec919061532a565b50915050600061356f308a602001518b6000015185600161350d919061537c565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001886080015163ffffffff164261361f919061502c565b64ffffffffff1681526020018281526020018769ffffffffffffffffffff168152602001886040015163ffffffff1664ffffffffff168152602001886060015163ffffffff1664ffffffffff1681525097508760405160200161368291906144df565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555050505050509392505050565b6008546000908190869061370b9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614de5565b6137159190614de5565b63ffffffff1690506000612710600860010154876137339190614d8c565b61373d919061539d565b613747908761502c565b9050600061375482613be8565b905060006137628483614d8c565b905060006137816bffffffffffffffffffffffff808916908a1661502c565b905061378d818361502c565b9a9950505050505050505050565b60006137a5610ec5565b511115610dba57610dba6129d9565b6000808a8a8a8a8a8a8a8a8a6040516020016137d8999897969594939291906153b1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036138de576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610be1565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808380602001905181019061396b919061545b565b90508060405160200161397e91906144df565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526007909352912054146139d0576006915050611cc4565b6000878152600760205260409020546139ed576002915050611cc4565b60006139f83a613be8565b90506000826101400151836101200151613a12919061552e565b613a239064ffffffffff1683614d8c565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288b8b8789610100015169ffffffffffffffffffff1688613a849190614f2d565b338b6040518763ffffffff1660e01b8152600401613aa79695949392919061554c565b60408051808303816000875af1158015613ac5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ae991906155c8565b90925090506000826006811115613b0257613b02614b9c565b1480613b1f57506001826006811115613b1d57613b1d614b9c565b145b15613bda5760008b815260076020526040812055613b3d8184614f2d565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100870151600c805469ffffffffffffffffffff90921693909291613bab91859116614f2d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613bf2612750565b613c0483670de0b6b3a7640000614d8c565b61061c919061539d565b508054613c1a90614768565b6000825580601f10613c2a575050565b601f0160209004906000526020600020908101906106c59190613c67565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613c7c5760008155600101613c68565b5090565b60008083601f840112613c9257600080fd5b50813567ffffffffffffffff811115613caa57600080fd5b602083019150836020828501011115613cc257600080fd5b9250929050565b60008060208385031215613cdc57600080fd5b823567ffffffffffffffff811115613cf357600080fd5b613cff85828601613c80565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b60405290565b6040516080810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b604051610120810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b60405160c0810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b604051610160810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e3857613e38613d0b565b604052919050565b600082601f830112613e5157600080fd5b813567ffffffffffffffff811115613e6b57613e6b613d0b565b613e9c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613df1565b818152846020838601011115613eb157600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff811681146106c557600080fd5b80356110e081613ece565b73ffffffffffffffffffffffffffffffffffffffff811681146106c557600080fd5b63ffffffff811681146106c557600080fd5b6bffffffffffffffffffffffff811681146106c557600080fd5b60008082840360c0811215613f5157600080fd5b833567ffffffffffffffff811115613f6857600080fd5b613f7486828701613e40565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613fa757600080fd5b50613fb0613d3a565b6020840135613fbe81613ece565b81526040840135613fce81613eef565b60208201526060840135613fe181613f11565b60408201526080840135606082015260a0840135613ffe81613f23565b6080820152919491935090915050565b6000815180845260005b8181101561403457602081850181015186830182015201614018565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614085602083018461400e565b9392505050565b60006020828403121561409e57600080fd5b813561408581613eef565b600081518084526020808501945080840160005b838110156140ef57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140bd565b509495945050505050565b60408152600061410d60408301856140a9565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561417b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261416983835161400e565b9486019492509085019060010161412f565b50909998505050505050505050565b6000806040838503121561419d57600080fd5b82356141a881613eef565b915060208301356141b881613f23565b809150509250929050565b6000806000604084860312156141d857600080fd5b83356141e381613eef565b9250602084013567ffffffffffffffff8111156141ff57600080fd5b61420b86828701613c80565b9497909650939450505050565b60208152600061408560208301846140a9565b60006020828403121561423d57600080fd5b5035919050565b60006020828403121561425657600080fd5b813567ffffffffffffffff81111561426d57600080fd5b61427984828501613e40565b949350505050565b60008083601f84011261429357600080fd5b50813567ffffffffffffffff8111156142ab57600080fd5b6020830191508360208260051b8501011115613cc257600080fd5b60008060008060008060008060e0898b0312156142e257600080fd5b606089018a8111156142f357600080fd5b8998503567ffffffffffffffff8082111561430d57600080fd5b6143198c838d01613c80565b909950975060808b013591508082111561433257600080fd5b61433e8c838d01614281565b909750955060a08b013591508082111561435757600080fd5b506143648b828c01614281565b999c989b50969995989497949560c00135949350505050565b60006020828403121561438f57600080fd5b813567ffffffffffffffff8111156143a657600080fd5b8201610100818503121561408557600080fd5b80516bffffffffffffffffffffffff16825260208101516143f2602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604081015161441a604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614436606084018267ffffffffffffffff169052565b50608081015161444e608084018263ffffffff169052565b5060a081015161446e60a08401826bffffffffffffffffffffffff169052565b5060c081015161448760c084018264ffffffffff169052565b5060e081015160e0830152610100808201516144b08285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610ebf565b610160810161061c82846143b9565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161454f60a084018269ffffffffffffffffffff169052565b5060c083015161456560c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60008060008060006080868803121561459a57600080fd5b85356145a581613ece565b9450602086013567ffffffffffffffff8111156145c157600080fd5b6145cd88828901613c80565b90955093505060408601356145e181613f11565b949793965091946060013592915050565b600067ffffffffffffffff82111561460c5761460c613d0b565b5060051b60200190565b600082601f83011261462757600080fd5b8135602061463c614637836145f2565b613df1565b82815260059290921b8401810191818101908684111561465b57600080fd5b8286015b8481101561467f57803561467281613eef565b835291830191830161465f565b509695505050505050565b803560ff811681146110e057600080fd5b60008060008060008060c087890312156146b457600080fd5b863567ffffffffffffffff808211156146cc57600080fd5b6146d88a838b01614616565b975060208901359150808211156146ee57600080fd5b6146fa8a838b01614616565b965061470860408a0161468a565b9550606089013591508082111561471e57600080fd5b61472a8a838b01613e40565b945061473860808a01613ee4565b935060a089013591508082111561474e57600080fd5b5061475b89828a01613e40565b9150509295509295509295565b600181811c9082168061477c57607f821691505b6020821081036147b5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105ef57600081815260208120601f850160051c810160208610156147e25750805b601f850160051c820191505b81811015610b5c578281556001016147ee565b67ffffffffffffffff83111561481957614819613d0b565b61482d836148278354614768565b836147bb565b6000601f84116001811461487f57600085156148495750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614915565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156148ce57868501358255602094850194600190920191016148ae565b5086821015614909577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff811681146106c557600080fd5b80516110e08161491c565b80516110e081613f23565b80516110e081613f11565b6000602080838503121561496057600080fd5b825167ffffffffffffffff8082111561497857600080fd5b908401906080828703121561498c57600080fd5b614994613d63565b825161499f8161491c565b8152828401516149ae81613f23565b8185015260408301517fffffffff00000000000000000000000000000000000000000000000000000000811681146149e557600080fd5b60408201526060830151828111156149fc57600080fd5b80840193505086601f840112614a1157600080fd5b82519150614a21614637836145f2565b82815260059290921b83018401918481019088841115614a4057600080fd5b938501935b83851015614a67578451614a5881613f11565b82529385019390850190614a45565b6060830152509695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614b0657614b06614aa6565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561293e5761293e614aa6565b60ff818116838216019081111561061c5761061c614aa6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614b8d57614b8d614b4b565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614c2457600080fd5b83018035915067ffffffffffffffff821115614c3f57600080fd5b602001915036819003821315613cc257600080fd5b600060208284031215614c6657600080fd5b813561408581613ece565b600060208284031215614c8357600080fd5b813561408581613f11565b600060208284031215614ca057600080fd5b813561408581613f23565b600060208284031215614cbd57600080fd5b81356140858161491c565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614d6560c085018763ffffffff169052565b818482030160e0850152614d7b8282018661400e565b9d9c50505050505050505050505050565b808202811582820484141761061c5761061c614aa6565b8181038181111561061c5761061c614aa6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561293e5761293e614aa6565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614e328184018a6140a9565b90508281036080840152614e4681896140a9565b905060ff871660a084015282810360c0840152614e63818761400e565b905067ffffffffffffffff851660e0840152828103610100840152614e88818561400e565b9c9b505050505050505050505050565b805169ffffffffffffffffffff811681146110e057600080fd5b600080600080600060a08688031215614eca57600080fd5b614ed386614e98565b9450602086015193506040860151925060608601519150614ef660808701614e98565b90509295509295909350565b60006bffffffffffffffffffffffff80841680614f2157614f21614b4b565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561293e5761293e614aa6565b6bffffffffffffffffffffffff818116838216028082169190828114614f7a57614f7a614aa6565b505092915050565b60006101208284031215614f9557600080fd5b614f9d613d86565b614fa683614942565b8152614fb460208401614942565b6020820152614fc560408401614942565b6040820152614fd660608401614942565b6060820152614fe760808401614942565b6080820152614ff860a08401614e98565b60a082015261500960c0840161492c565b60c082015260e08381015190820152610100928301519281019290925250919050565b8082018082111561061c5761061c614aa6565b600082601f83011261505057600080fd5b81356020615060614637836145f2565b82815260059290921b8401810191818101908684111561507f57600080fd5b8286015b8481101561467f5780358352918301918301615083565b600082601f8301126150ab57600080fd5b813560206150bb614637836145f2565b82815260059290921b840181019181810190868411156150da57600080fd5b8286015b8481101561467f57803567ffffffffffffffff8111156150fe5760008081fd5b61510c8986838b0101613e40565b8452509183019183016150de565b600080600080600060a0868803121561513257600080fd5b853567ffffffffffffffff8082111561514a57600080fd5b61515689838a0161503f565b9650602088013591508082111561516c57600080fd5b61517889838a0161509a565b9550604088013591508082111561518e57600080fd5b61519a89838a0161509a565b945060608801359150808211156151b057600080fd5b6151bc89838a0161509a565b935060808801359150808211156151d257600080fd5b506151df8882890161509a565b9150509295509295909350565b80516110e081613eef565b600082601f83011261520857600080fd5b81516020615218614637836145f2565b82815260059290921b8401810191818101908684111561523757600080fd5b8286015b8481101561467f57805161524e81613eef565b835291830191830161523b565b60006020828403121561526d57600080fd5b815167ffffffffffffffff8082111561528557600080fd5b9083019060c0828603121561529957600080fd5b6152a1613daa565b82516152ac81613f23565b815260208301516152bc81613eef565b602082015260408301516152cf81613f23565b60408201526152e0606084016151ec565b60608201526080830151828111156152f757600080fd5b615303878286016151f7565b60808301525060a083015160a082015280935050505092915050565b80516110e081613ece565b60008060006060848603121561533f57600080fd5b8351801515811461534f57600080fd5b602085015190935061536081613ece565b604085015190925061537181613ece565b809150509250925092565b67ffffffffffffffff81811683821601908082111561293e5761293e614aa6565b6000826153ac576153ac614b4b565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526153f88285018b6140a9565b9150838203608085015261540c828a6140a9565b915060ff881660a085015283820360c0850152615429828861400e565b90861660e08501528381036101008501529050614e88818561400e565b805164ffffffffff811681146110e057600080fd5b6000610160828403121561546e57600080fd5b615476613dcd565b61547f83614937565b815261548d602084016151ec565b602082015261549e604084016151ec565b60408201526154af6060840161531f565b60608201526154c060808401614942565b60808201526154d160a08401614937565b60a08201526154e260c08401615446565b60c082015260e083015160e08201526101006154ff818501614e98565b90820152610120615511848201615446565b90820152610140615523848201615446565b908201529392505050565b64ffffffffff81811683821601908082111561293e5761293e614aa6565b60006102008083526155608184018a61400e565b90508281036020840152615574818961400e565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506155bd905060a08301846143b9565b979650505050505050565b600080604083850312156155db57600080fd5b8251600781106155ea57600080fd5b60208401519092506141b881613f2356fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -204,9 +216,9 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorRaw) Transact(opts *b return _FunctionsCoordinator.Contract.contract.Transact(opts, method, params...) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPriceGwei *big.Int) (*big.Int, error) { var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "estimateCost", subscriptionId, data, callbackGasLimit, gasPrice) + err := _FunctionsCoordinator.contract.Call(opts, &out, "estimateCost", subscriptionId, data, callbackGasLimit, gasPriceGwei) if err != nil { return *new(*big.Int), err @@ -218,12 +230,12 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCaller) EstimateCost(opts *bind } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) EstimateCost(subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) { - return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPrice) +func (_FunctionsCoordinator *FunctionsCoordinatorSession) EstimateCost(subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPriceGwei *big.Int) (*big.Int, error) { + return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPriceGwei) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) EstimateCost(subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) { - return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPrice) +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) EstimateCost(subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPriceGwei *big.Int) (*big.Int, error) { + return _FunctionsCoordinator.Contract.EstimateCost(&_FunctionsCoordinator.CallOpts, subscriptionId, data, callbackGasLimit, gasPriceGwei) } func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) { @@ -271,41 +283,25 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetAllNodePublic return _FunctionsCoordinator.Contract.GetAllNodePublicKeys(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.CallOpts) (GetConfig, - - error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.CallOpts) (IFunctionsBillingConfig, error) { var out []interface{} err := _FunctionsCoordinator.contract.Call(opts, &out, "getConfig") - outstruct := new(GetConfig) if err != nil { - return *outstruct, err + return *new(IFunctionsBillingConfig), err } - outstruct.MaxCallbackGasLimit = *abi.ConvertType(out[0], new(uint32)).(*uint32) - outstruct.FeedStalenessSeconds = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.GasOverheadBeforeCallback = *abi.ConvertType(out[2], new(uint32)).(*uint32) - outstruct.GasOverheadAfterCallback = *abi.ConvertType(out[3], new(uint32)).(*uint32) - outstruct.RequestTimeoutSeconds = *abi.ConvertType(out[4], new(uint32)).(*uint32) - outstruct.DonFee = *abi.ConvertType(out[5], new(*big.Int)).(**big.Int) - outstruct.MaxSupportedRequestDataVersion = *abi.ConvertType(out[6], new(uint16)).(*uint16) - outstruct.FulfillmentGasPriceOverEstimationBP = *abi.ConvertType(out[7], new(*big.Int)).(**big.Int) - outstruct.FallbackNativePerUnitLink = *abi.ConvertType(out[8], new(*big.Int)).(**big.Int) - outstruct.LinkPriceFeed = *abi.ConvertType(out[9], new(common.Address)).(*common.Address) + out0 := *abi.ConvertType(out[0], new(IFunctionsBillingConfig)).(*IFunctionsBillingConfig) - return *outstruct, err + return out0, err } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfig() (GetConfig, - - error) { +func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfig() (IFunctionsBillingConfig, error) { return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (GetConfig, - - error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (IFunctionsBillingConfig, error) { return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) } @@ -353,48 +349,48 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetDONPublicKey( return _FunctionsCoordinator.Contract.GetDONPublicKey(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetFeedData(opts *bind.CallOpts) (*big.Int, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetThresholdPublicKey(opts *bind.CallOpts) ([]byte, error) { var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getFeedData") + err := _FunctionsCoordinator.contract.Call(opts, &out, "getThresholdPublicKey") if err != nil { - return *new(*big.Int), err + return *new([]byte), err } - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) return out0, err } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetFeedData() (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetFeedData(&_FunctionsCoordinator.CallOpts) +func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetThresholdPublicKey() ([]byte, error) { + return _FunctionsCoordinator.Contract.GetThresholdPublicKey(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetFeedData() (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetFeedData(&_FunctionsCoordinator.CallOpts) +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetThresholdPublicKey() ([]byte, error) { + return _FunctionsCoordinator.Contract.GetThresholdPublicKey(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetThresholdPublicKey(opts *bind.CallOpts) ([]byte, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetWeiPerUnitLink(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getThresholdPublicKey") + err := _FunctionsCoordinator.contract.Call(opts, &out, "getWeiPerUnitLink") if err != nil { - return *new([]byte), err + return *new(*big.Int), err } - out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) return out0, err } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetThresholdPublicKey() ([]byte, error) { - return _FunctionsCoordinator.Contract.GetThresholdPublicKey(&_FunctionsCoordinator.CallOpts) +func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetWeiPerUnitLink() (*big.Int, error) { + return _FunctionsCoordinator.Contract.GetWeiPerUnitLink(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetThresholdPublicKey() ([]byte, error) { - return _FunctionsCoordinator.Contract.GetThresholdPublicKey(&_FunctionsCoordinator.CallOpts) +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetWeiPerUnitLink() (*big.Int, error) { + return _FunctionsCoordinator.Contract.GetWeiPerUnitLink(&_FunctionsCoordinator.CallOpts) } func (_FunctionsCoordinator *FunctionsCoordinatorCaller) LatestConfigDetails(opts *bind.CallOpts) (LatestConfigDetails, @@ -573,6 +569,18 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) OracleWithdr return _FunctionsCoordinator.Contract.OracleWithdraw(&_FunctionsCoordinator.TransactOpts, recipient, amount) } +func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) OracleWithdrawAll(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsCoordinator.contract.Transact(opts, "oracleWithdrawAll") +} + +func (_FunctionsCoordinator *FunctionsCoordinatorSession) OracleWithdrawAll() (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.OracleWithdrawAll(&_FunctionsCoordinator.TransactOpts) +} + +func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) OracleWithdrawAll() (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.OracleWithdrawAll(&_FunctionsCoordinator.TransactOpts) +} + func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) { return _FunctionsCoordinator.contract.Transact(opts, "sendRequest", request) } @@ -847,16 +855,8 @@ func (it *FunctionsCoordinatorConfigChangedIterator) Close() error { } type FunctionsCoordinatorConfigChanged struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadBeforeCallback uint32 - GasOverheadAfterCallback uint32 - RequestTimeoutSeconds uint32 - DonFee *big.Int - MaxSupportedRequestDataVersion uint16 - FulfillmentGasPriceOverEstimationBP *big.Int - FallbackNativePerUnitLink *big.Int - Raw types.Log + Config IFunctionsBillingConfig + Raw types.Log } func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigChangedIterator, error) { @@ -1698,18 +1698,6 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseTransmitted(log return event, nil } -type GetConfig struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadBeforeCallback uint32 - GasOverheadAfterCallback uint32 - RequestTimeoutSeconds uint32 - DonFee *big.Int - MaxSupportedRequestDataVersion uint16 - FulfillmentGasPriceOverEstimationBP *big.Int - FallbackNativePerUnitLink *big.Int - LinkPriceFeed common.Address -} type LatestConfigDetails struct { ConfigCount uint32 BlockNumber uint32 @@ -1750,7 +1738,7 @@ func (FunctionsCoordinatorCommitmentDeleted) Topic() common.Hash { } func (FunctionsCoordinatorConfigChanged) Topic() common.Hash { - return common.HexToHash("0x3332571032ee658b30d567e63b2443e9d921162625e0f3fe86968a586c1a090f") + return common.HexToHash("0xfc10ed3768699b4370d710cd8ffbc7efdc5a691e42af93f2fe3d0ba7c3355658") } func (FunctionsCoordinatorConfigSet) Topic() common.Hash { @@ -1782,24 +1770,22 @@ func (_FunctionsCoordinator *FunctionsCoordinator) Address() common.Address { } type FunctionsCoordinatorInterface interface { - EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPrice *big.Int) (*big.Int, error) + EstimateCost(opts *bind.CallOpts, subscriptionId uint64, data []byte, callbackGasLimit uint32, gasPriceGwei *big.Int) (*big.Int, error) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) GetAllNodePublicKeys(opts *bind.CallOpts) ([]common.Address, [][]byte, error) - GetConfig(opts *bind.CallOpts) (GetConfig, - - error) + GetConfig(opts *bind.CallOpts) (IFunctionsBillingConfig, error) GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) GetDONPublicKey(opts *bind.CallOpts) ([]byte, error) - GetFeedData(opts *bind.CallOpts) (*big.Int, error) - GetThresholdPublicKey(opts *bind.CallOpts) ([]byte, error) + GetWeiPerUnitLink(opts *bind.CallOpts) (*big.Int, error) + LatestConfigDetails(opts *bind.CallOpts) (LatestConfigDetails, error) @@ -1822,6 +1808,8 @@ type FunctionsCoordinatorInterface interface { OracleWithdraw(opts *bind.TransactOpts, recipient common.Address, amount *big.Int) (*types.Transaction, error) + OracleWithdrawAll(opts *bind.TransactOpts) (*types.Transaction, error) + SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) SetConfig(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index d8fdda01af4..3b27060d6cb 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -44,16 +44,32 @@ type FunctionsResponseCommitment struct { GasOverheadAfterCallback *big.Int } +type IFunctionsRouterConfig struct { + MaxConsumersPerSubscription uint16 + AdminFee *big.Int + HandleOracleFulfillmentSelector [4]byte + MaxCallbackGasLimits []uint32 +} + +type IFunctionsSubscriptionsSubscription struct { + Balance *big.Int + Owner common.Address + BlockedBalance *big.Int + ProposedOwner common.Address + Consumers []common.Address + Flags [32]byte +} + var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"indexed\":false,\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"timelockEndBlock\",\"type\":\"uint64\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"requestedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"blocks\",\"type\":\"uint16\"}],\"name\":\"proposeTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateTimelockBlocks\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620066bd380380620066bd833981016040819052620000349162000441565b6000805460ff191681558290339086908690859084908190816200009f5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000d957620000d9816200016e565b50506007805461ffff80871661ffff19909216919091179091558316608052506000805260026020527fac33ff75c19e70fe83507db0d683fd3465c996598dc972688b7ace676c89077b80546001600160a01b031916301790556200013e816200021f565b5050600a80546001600160a01b0319166001600160a01b03949094169390931790925550620006cd945050505050565b336001600160a01b03821603620001c85760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000096565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080600080848060200190518101906200023b91906200053e565b6040805160808101825261ffff86168082526001600160601b03861660208084018290526001600160e01b031987169484019490945260608301859052600f80546001600160701b031916909217620100009091021763ffffffff60701b1916600160701b60e087901c021781558351969a509498509296509094509092620002cb916010919086019062000313565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca83838360405162000304939291906200065c565b60405180910390a15050505050565b82805482825590600052602060002090600701600890048101928215620003b75791602002820160005b838211156200038357835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026200033d565b8015620003b55782816101000a81549063ffffffff021916905560040160208160030104928301926001030262000383565b505b50620003c5929150620003c9565b5090565b5b80821115620003c55760008155600101620003ca565b805161ffff81168114620003f357600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051601f8201601f191681016001600160401b0381118282101715620004395762000439620003f8565b604052919050565b600080600080608085870312156200045857600080fd5b6200046385620003e0565b9350602062000474818701620003e0565b60408701519094506001600160a01b03811681146200049257600080fd5b60608701519093506001600160401b0380821115620004b057600080fd5b818801915088601f830112620004c557600080fd5b815181811115620004da57620004da620003f8565b620004ee601f8201601f191685016200040e565b915080825289848285010111156200050557600080fd5b60005b818110156200052557838101850151838201860152840162000508565b5060008482840101525080935050505092959194509250565b600080600080608085870312156200055557600080fd5b6200056085620003e0565b602086810151919550906001600160601b03811681146200058057600080fd5b60408701519094506001600160e01b0319811681146200059f57600080fd5b60608701519093506001600160401b0380821115620005bd57600080fd5b818801915088601f830112620005d257600080fd5b815181811115620005e757620005e7620003f8565b8060051b9150620005fa8483016200040e565b818152918301840191848101908b8411156200061557600080fd5b938501935b838510156200064c578451925063ffffffff831683146200063b5760008081fd5b82825293850193908501906200061a565b989b979a50959850505050505050565b6001600160601b03841681526001600160e01b031983166020808301919091526060604083018190528351908301819052600091848101916080850190845b81811015620006bf57845163ffffffff16835293830193918301916001016200069b565b509098975050505050505050565b608051615fd4620006e96000396000612ab70152615fd46000f3fe608060405234801561001057600080fd5b50600436106102f45760003560e01c806379ba509711610191578063aab396bd116100e3578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f14610756578063eb523d6c14610769578063f2fde38b1461077c57600080fd5b8063d7ae1d301461071d578063e72f6e3014610730578063e82ad7d41461074357600080fd5b8063b734c0f4116100c8578063b734c0f4146106e6578063badc3eb6146106ee578063c3f909d41461070557600080fd5b8063aab396bd146106ad578063b5643858146106d357600080fd5b80639f87fad711610145578063a47c76961161011f578063a47c769614610662578063a4c0ed3614610687578063a9c9a9181461069a57600080fd5b80639f87fad714610626578063a1d4c82814610639578063a21a23e41461065a57600080fd5b80638456cb59116101765780638456cb59146105f35780638da5cb5b146105fb5780638fde53171461061e57600080fd5b806379ba5097146105d857806382359740146105e057600080fd5b8063461d27621161024a57806366316d8d116101fe5780636a2215de116101d85780636a2215de1461057a5780636e3b3323146105b25780637341c10c146105c557600080fd5b806366316d8d146104ab57806366419970146104be578063674603d0146104e557600080fd5b806355fedefa1161022f57806355fedefa146104545780635c975abb146104815780635ed6dfba1461049857600080fd5b8063461d27621461042e5780634b8832d31461044157600080fd5b80631c024539116102ac5780633e871e4d116102865780633e871e4d146103f25780633f4ba83a1461040557806341db4ca31461040d57600080fd5b80631c024539146103c45780631ded3b36146103cc578063385de9ae146103df57600080fd5b806310fc49c1116102dd57806310fc49c11461032e57806312b5834914610341578063181f5a771461037b57600080fd5b806302bcc5b6146102f95780630c5d49cb1461030e575b600080fd5b61030c610307366004614ace565b61078f565b005b610316608481565b60405161ffff90911681526020015b60405180910390f35b61030c61033c366004614b0f565b6107ee565b6009546801000000000000000090046bffffffffffffffffffffffff166040516bffffffffffffffffffffffff9091168152602001610325565b6103b76040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516103259190614bac565b61030c6108ea565b61030c6103da366004614bbf565b610a5b565b61030c6103ed366004614c34565b610a8c565b61030c610400366004614ded565b610b95565b61030c610ed6565b61042061041b366004614eb6565b610ee8565b604051908152602001610325565b61042061043c366004614eb6565b610f48565b61030c61044f366004614f3b565b610f54565b610420610462366004614ace565b67ffffffffffffffff166000908152600b602052604090206003015490565b60005460ff165b6040519015158152602001610325565b61030c6104a6366004614f8e565b611052565b61030c6104b9366004614f8e565b611325565b60095467ffffffffffffffff165b60405167ffffffffffffffff9091168152602001610325565b6105526104f3366004614fbc565b73ffffffffffffffffffffffffffffffffffffffff919091166000908152600c6020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff9283166020850152911690820152606001610325565b61058d610588366004614fea565b61154c565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610325565b61030c6105c0366004615003565b61160b565b61030c6105d3366004614f3b565b6118e7565b61030c611a7d565b61030c6105ee366004614ace565b611b9f565b61030c611ccd565b600054610100900473ffffffffffffffffffffffffffffffffffffffff1661058d565b61030c611cdd565b61030c610634366004614f3b565b611d71565b61064c61064736600461521c565b612146565b604051610325929190615304565b6104cc61253a565b610675610670366004614ace565b6126c7565b6040516103259695949392919061537e565b61030c6106953660046153e8565b6127d7565b61058d6106a8366004614fea565b612a06565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097610420565b61030c6106e1366004615444565b612a6b565b61030c612bd4565b6106f6612d8e565b60405161032593929190615461565b61070d612e67565b60405161032594939291906154ec565b61030c61072b366004614f3b565b612f1e565b61030c61073e36600461554f565b612f81565b610488610751366004614ace565b613189565b61030c61076436600461556c565b6132d8565b61030c610777366004614fea565b6133fe565b61030c61078a36600461554f565b6135c9565b6107976135da565b6107a0816135e2565b67ffffffffffffffff81166000908152600b60205260409020546107eb9082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16613658565b50565b67ffffffffffffffff82166000908152600b6020526040812060030154601054911a908110610853576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600f6001018260ff168154811061086e5761086e6155ae565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff1611156108e4576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff8216600482015260240161084a565b50505050565b6108f26139bd565b60008080526006602052604080518082019091527f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f8805482908290610936906155dd565b80601f0160208091040260200160405190810160405280929190818152602001828054610962906155dd565b80156109af5780601f10610984576101008083540402835291602001916109af565b820191906000526020600020905b81548152906001019060200180831161099257829003601f168201915b50505091835250506001919091015467ffffffffffffffff9081166020928301529082015191925016431015610a11576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051610a1c90613a43565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a509160009190615630565b60405180910390a150565b610a636135da565b610a6c826135e2565b67ffffffffffffffff9091166000908152600b6020526040902060030155565b610a946139bd565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600754602090910190610ae99061ffff1643615680565b67ffffffffffffffff169052600084815260066020526040902081518190610b1190826156e1565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90610b88908590859085906157fb565b60405180910390a1505050565b610b9d6139bd565b8151815181141580610baf5750600881115b15610be6576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610d12576000848281518110610c0557610c056155ae565b602002602001015190506000848381518110610c2357610c236155ae565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c8e575060008281526002602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610cc5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cff576040517f4855c2880000000000000000000000000000000000000000000000000000000081526004810183905260240161084a565b505080610d0b9061584f565b9050610be9565b50600754600090610d279061ffff1643615680565b60408051606081018252868152602080820187905267ffffffffffffffff841692820192909252865192935091600391610d6591839189019061490e565b506020828101518051610d7e9260018501920190614955565b5060409190910151600290910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff90921691909117905560005b8451811015610ecf577fbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e858281518110610e0057610e006155ae565b602002602001015160026000888581518110610e1e57610e1e6155ae565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e6757610e676155ae565b602002602001015185604051610eb7949392919093845273ffffffffffffffffffffffffffffffffffffffff92831660208501529116604083015267ffffffffffffffff16606082015260800190565b60405180910390a1610ec88161584f565b9050610dc4565b5050505050565b610ede6139bd565b610ee6613b89565b565b600080610ef48361154c565b9050610f3c83828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613c069050565b98975050505050505050565b600080610ef483612a06565b610f5c613f56565b610f6582613f5e565b610f6d614024565b67ffffffffffffffff82166000908152600b602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c01000000000000000000000000909204161461104e5767ffffffffffffffff82166000818152600b602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b61105a6135da565b806bffffffffffffffffffffffff166000036110905750306000908152600d60205260409020546bffffffffffffffffffffffff165b306000908152600d60205260409020546bffffffffffffffffffffffff808316911610156110ea576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b306000908152600d6020526040812080548392906111179084906bffffffffffffffffffffffff16615887565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960088282829054906101000a90046bffffffffffffffffffffffff1661116e9190615887565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af115801561120d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061123191906158b3565b61104e57600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa1580156112a4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112c891906158d5565b6009546040517fa99da302000000000000000000000000000000000000000000000000000000008152680100000000000000009091046bffffffffffffffffffffffff16600482018190526024820183905291925060440161084a565b61132d613f56565b806bffffffffffffffffffffffff16600003611375576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d60205260409020546bffffffffffffffffffffffff808316911610156113cf576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600d6020526040812080548392906113fc9084906bffffffffffffffffffffffff16615887565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080600960088282829054906101000a90046bffffffffffffffffffffffff166114539190615887565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff868116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156114f2573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061151691906158b3565b61104e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b60035460ff821610156115d5576003805460ff8316908110611574576115746155ae565b906000526020600020015483036115c5576004805460ff831690811061159c5761159c6155ae565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b6115ce816158ee565b9050611550565b506040517f80833e330000000000000000000000000000000000000000000000000000000081526004810183905260240161084a565b611613613f56565b60005b818110156118e2576000838383818110611632576116326155ae565b90506101600201803603810190611649919061590d565b905060008160e001519050600082606001519050600e60008381526020019081526020016000205483604051602001611682919061592a565b60405160208183030381529060405280519060200120146116cf576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611714576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015611787573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906117ab91906158b3565b5060a083015167ffffffffffffffff82166000908152600b6020526040812060010180549091906117eb9084906bffffffffffffffffffffffff16615887565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815282822067ffffffffffffffff8086168452915291902080546001926009916118729185916901000000000000000000900416615a59565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600e60205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806118db9061584f565b9050611616565b505050565b6118ef613f56565b6118f882613f5e565b611900614024565b600f5467ffffffffffffffff83166000908152600b602052604090206002015461ffff909116900361195e576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8616845290915290205460ff16156119a5575050565b73ffffffffffffffffffffffffffffffffffffffff81166000818152600c6020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600b84528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611045565b60015473ffffffffffffffffffffffffffffffffffffffff163314611afe576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161084a565b60008054336101008181027fffffffffffffffffffffff0000000000000000000000000000000000000000ff8416178455600180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905560405173ffffffffffffffffffffffffffffffffffffffff919093041692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611ba7613f56565b611baf614024565b67ffffffffffffffff81166000908152600b60205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811692909104163314611c36576040517f02b543c600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000818152600b602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff86168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611045565b611cd56139bd565b610ee6614129565b611ce56139bd565b600854640100000000900467ffffffffffffffff16431015611d33576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600854600780546201000090920461ffff167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216919091179055565b611d79613f56565b611d8282613f5e565b611d8a614024565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600c6020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611e32576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611e87576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600b6020908152604080832060020180548251818502810185019093528083529192909190830182828015611f0257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611ed7575b5050505050905060005b81518110156120aa578373ffffffffffffffffffffffffffffffffffffffff16828281518110611f3e57611f3e6155ae565b602002602001015173ffffffffffffffffffffffffffffffffffffffff160361209a578160018351611f709190615a7a565b81518110611f8057611f806155ae565b6020026020010151600b60008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611fc357611fc36155ae565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600b9091526040902060020180548061203d5761203d615a8d565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff00000000000000000000000000000000000000001690550190556120aa565b6120a38161584f565b9050611f0c565b5073ffffffffffffffffffffffffffffffffffffffff83166000818152600c6020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080612151613f56565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146121ba576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e08301516000908152600e602052604090205461222257600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161221293929190615abc565b60405180910390a250600061252f565b600e60008460e001518152602001908152602001600020548360405160200161224b919061592a565b60405160208183030381529060405280519060200120146122a657600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161221293929190615abc565b826101400151836080015163ffffffff166122c19190615aee565b64ffffffffff165a101561230f57600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18460200151868560405161221293929190615abc565b6000612324846080015163ffffffff16614184565b61232e9088615b0c565b90506000818786600001516123439190615b34565b61234d9190615b34565b606086015167ffffffffffffffff166000908152600b60205260409020549091506bffffffffffffffffffffffff90811690821611156123db57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123c793929190615abc565b60405180910390a2506000915061252f9050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561244357600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516123c793929190615abc565b5050600e60008460e00151815260200190815260200160002060009055600061247b8460e001518a8a87608001518860400151614226565b805190915061248b57600161248e565b60005b925060006124bd85606001518660a00151876040015188600001518c6124b78860200151614184565b8d6143a2565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b83602001518988876000015161250a578e61250c565b8f5b8860400151604051612522959493929190615b59565b60405180910390a3519150505b965096945050505050565b6000612544613f56565b61254c614024565b600980546000906125669067ffffffffffffffff16615bbb565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156125dc578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff84168152600b825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261267792600285019290910190614955565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b600080600080606060006126da876135e2565b67ffffffffffffffff87166000908152600b602090815260409182902080546001820154600290920180548551818602810186019096528086526bffffffffffffffffffffffff8084169c5073ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009485900481169c509085169a50929093049091169650918301828280156127a657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161277b575b50505067ffffffffffffffff8a166000908152600b6020526040902060030154929450919250505091939550919395565b6127df613f56565b600a5473ffffffffffffffffffffffffffffffffffffffff163314612830576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461286a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061287882840184614ace565b67ffffffffffffffff81166000908152600b60205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166128f1576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff81166000908152600b6020526040812080546bffffffffffffffffffffffff16918691906129288385615b34565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555084600960088282829054906101000a90046bffffffffffffffffffffffff1661297f9190615b34565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846129e69190615680565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526002602052604081205473ffffffffffffffffffffffffffffffffffffffff1680612a65576040517f80833e330000000000000000000000000000000000000000000000000000000081526004810184905260240161084a565b92915050565b612a736139bd565b60075461ffff808316911603612ab5576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000061ffff168161ffff161115612b17576040517fe9a3062200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160608101825260075461ffff90811680835290841660208301529091820190612b449043615680565b67ffffffffffffffff9081169091528151600880546020850151604090950151909316640100000000027fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff61ffff95861662010000027fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000009095169590931694909417929092171691909117905550565b612bdc6139bd565b60055467ffffffffffffffff16431015612c22576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600354811015612d4557600060036000018281548110612c4757612c476155ae565b90600052602060002001549050600060036001018381548110612c6c57612c6c6155ae565b6000918252602080832091909101548483526002825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526002602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612d3e8161584f565b9050612c25565b5060036000612d5482826149cf565b612d626001830160006149cf565b5060020180547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000169055565b600554600380546040805160208084028201810190925282815267ffffffffffffffff9094169360609384939192909190830182828015612dee57602002820191906000526020600020905b815481526020019060010190808311612dda575b505050505091506003600101805480602002602001604051908101604052809291908181526020018280548015612e5b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e30575b50505050509050909192565b600f54601080546040805160208084028201810190925282815261ffff8516946bffffffffffffffffffffffff62010000820416946e01000000000000000000000000000090910460e01b93606093830182828015612f1157602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ed45790505b5050505050905090919293565b612f26613f56565b612f2f82613f5e565b612f37614024565b612f4082613189565b15612f77576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61104e8282613658565b612f896135da565b600a546040517f70a0823100000000000000000000000000000000000000000000000000000000815230600482015260009173ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ff8573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061301c91906158d5565b6009549091506801000000000000000090046bffffffffffffffffffffffff1681811115613080576040517fa99da302000000000000000000000000000000000000000000000000000000008152600481018290526024810183905260440161084a565b818110156118e25760006130948284615a7a565b600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff87811660048301526024820184905292935091169063a9059cbb906044016020604051808303816000875af115801561310f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061313391906158b3565b506040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff81166000908152600b602090815260408083206002018054825181850281018501909352808352849383018282801561320157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116131d6575b5050505050905060005b81518110156132ce576000600c600084848151811061322c5761322c6155ae565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff81161515825261010081048316948201859052690100000000000000000090049091169181018290529250146132bd57506001949350505050565b506132c78161584f565b905061320b565b5060009392505050565b6132e06139bd565b6040805160606020601f850181900402820181018352918101838152909182919085908590819085018382808284376000920191909152505050908252506007546020909101906133359061ffff1643615680565b67ffffffffffffffff16905260008052600660205280517f54cdd369e4e8a8515e52ca72ec816c2101831ad1f18bf44102ed171459c9b4f890819061337a90826156e1565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a906133f290600090859085906157fb565b60405180910390a15050565b6134066139bd565b600081815260066020526040808220815180830190925280548290829061342c906155dd565b80601f0160208091040260200160405190810160405280929190818152602001828054613458906155dd565b80156134a55780601f1061347a576101008083540402835291602001916134a5565b820191906000526020600020905b81548152906001019060200180831161348857829003601f168201915b50505091835250506001919091015467ffffffffffffffff9081166020928301529082015191925016431015613507576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61351082612a06565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161356491600401614bac565b600060405180830381600087803b15801561357e57600080fd5b505af1158015613592573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c793506133f29250859190615630565b6135d16139bd565b6107eb816145eb565b610ee66139bd565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166107eb576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600b60209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561373957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161370e575b505050918352505060039190910154602090910152805190915060005b8260800151518110156137fa57600c60008460800151838151811061377d5761377d6155ae565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556137f38161584f565b9050613756565b5067ffffffffffffffff84166000908152600b60205260408120818155600181018290559061382c60028301826149cf565b6003820160009055505080600960088282829054906101000a90046bffffffffffffffffffffffff1661385f9190615887565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155600a546040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff878116600483015292851660248201529116915063a9059cbb906044016020604051808303816000875af11580156138fe573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061392291906158b3565b613958576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101612138565b600054610100900473ffffffffffffffffffffffffffffffffffffffff163314610ee6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161084a565b60008060008084806020019051810190613a5d9190615bf8565b6040805160808101825261ffff86168082526bffffffffffffffffffffffff861660208084018290527fffffffff0000000000000000000000000000000000000000000000000000000087169484019490945260608301859052600f80547fffffffffffffffffffffffffffffffffffff00000000000000000000000000001690921762010000909102177fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff166e01000000000000000000000000000060e087901c021781558351969a509498509296509094509092613b4391601091908601906149ed565b509050507fe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca838383604051613b7a93929190615cf3565b60405180910390a15050505050565b613b916146e6565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613c10613f56565b613c19856135e2565b613c233386614752565b613c2d85836107ee565b604080516101008101825233815267ffffffffffffffff87166000818152600b6020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b1660808801529484529190526003015460a084015263ffffffff861660c0840152600f546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e88091613d0d9190600401615d4b565b610160604051808303816000875af1158015613d2d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d519190615e36565b9050604051806101600160405280600f60000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613e60919061592a565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600e90935291205560a0810151613eba90339088906147c6565b60e081015167ffffffffffffffff87166000818152600b60205260409081902054905191928b9290917f7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f5491613f3f916c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690339032908d908d908d90615f09565b60405180910390a460e00151979650505050505050565b610ee66148a1565b67ffffffffffffffff81166000908152600b60205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613fd5576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461104e576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61404d7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb097612a06565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff9190911690636b14daf8906140b090339060248101615f6d565b602060405180830381865afa1580156140cd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140f191906158b3565b610ee6576040517f2290626300000000000000000000000000000000000000000000000000000000815233600482015260240161084a565b6141316148a1565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613bdc3390565b60006bffffffffffffffffffffffff821115614222576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f3620626974730000000000000000000000000000000000000000000000000000606482015260840161084a565b5090565b60408051606080820183526000808352602083015291810191909152600f546040516000916e010000000000000000000000000000900460e01b9061427390899089908990602401615f9c565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b61432557600080fd5b5a61138881101561433557600080fd5b61138881039050876040820482031161434d57600080fd5b60008086516020880160008b8df193505a900391503d6084811115614370575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006143c28486615b0c565b90506000816143d18886615b34565b6143db9190615b34565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600b90915292832080549297509394508493929161443291859116615887565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550818461446c9190615b34565b336000908152600d6020526040812080549091906144999084906bffffffffffffffffffffffff16615b34565b82546101009290920a6bffffffffffffffffffffffff818102199093169183160217909155306000908152600d6020526040812080548b945090926144e091859116615b34565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600b6020526040812060010180548d9450909261453491859116615887565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff88166000908152600c6020908152604080832067ffffffffffffffff808f168552925290912080546001926009916145b89185916901000000000000000000900416615a59565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361466a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161084a565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929361010090910416917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005460ff16610ee6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f7420706175736564000000000000000000000000604482015260640161084a565b73ffffffffffffffffffffffffffffffffffffffff82166000908152600c6020908152604080832067ffffffffffffffff8516845290915290205460ff1661104e576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600b6020526040812060010180548392906148009084906bffffffffffffffffffffffff16615b34565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff85166000908152600c6020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614876928492900416615a59565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60005460ff1615610ee6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a2070617573656400000000000000000000000000000000604482015260640161084a565b828054828255906000526020600020908101928215614949579160200282015b8281111561494957825182559160200191906001019061492e565b50614222929150614a93565b828054828255906000526020600020908101928215614949579160200282015b8281111561494957825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614975565b50805460008255906000526020600020908101906107eb9190614a93565b828054828255906000526020600020906007016008900481019282156149495791602002820160005b83821115614a5a57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614a16565b8015614a8a5782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614a5a565b50506142229291505b5b808211156142225760008155600101614a94565b67ffffffffffffffff811681146107eb57600080fd5b8035614ac981614aa8565b919050565b600060208284031215614ae057600080fd5b8135614aeb81614aa8565b9392505050565b63ffffffff811681146107eb57600080fd5b8035614ac981614af2565b60008060408385031215614b2257600080fd5b8235614b2d81614aa8565b91506020830135614b3d81614af2565b809150509250929050565b6000815180845260005b81811015614b6e57602081850181015186830182015201614b52565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614aeb6020830184614b48565b60008060408385031215614bd257600080fd5b8235614bdd81614aa8565b946020939093013593505050565b60008083601f840112614bfd57600080fd5b50813567ffffffffffffffff811115614c1557600080fd5b602083019150836020828501011115614c2d57600080fd5b9250929050565b600080600060408486031215614c4957600080fd5b83359250602084013567ffffffffffffffff811115614c6757600080fd5b614c7386828701614beb565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614cd357614cd3614c80565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614d2057614d20614c80565b604052919050565b600067ffffffffffffffff821115614d4257614d42614c80565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff811681146107eb57600080fd5b8035614ac981614d4c565b600082601f830112614d8a57600080fd5b81356020614d9f614d9a83614d28565b614cd9565b82815260059290921b84018101918181019086841115614dbe57600080fd5b8286015b84811015614de2578035614dd581614d4c565b8352918301918301614dc2565b509695505050505050565b60008060408385031215614e0057600080fd5b823567ffffffffffffffff80821115614e1857600080fd5b818501915085601f830112614e2c57600080fd5b81356020614e3c614d9a83614d28565b82815260059290921b84018101918181019089841115614e5b57600080fd5b948201945b83861015614e7957853582529482019490820190614e60565b96505086013592505080821115614e8f57600080fd5b50614e9c85828601614d79565b9150509250929050565b61ffff811681146107eb57600080fd5b60008060008060008060a08789031215614ecf57600080fd5b8635614eda81614aa8565b9550602087013567ffffffffffffffff811115614ef657600080fd5b614f0289828a01614beb565b9096509450506040870135614f1681614ea6565b92506060870135614f2681614af2565b80925050608087013590509295509295509295565b60008060408385031215614f4e57600080fd5b8235614f5981614aa8565b91506020830135614b3d81614d4c565b6bffffffffffffffffffffffff811681146107eb57600080fd5b8035614ac981614f69565b60008060408385031215614fa157600080fd5b8235614fac81614d4c565b91506020830135614b3d81614f69565b60008060408385031215614fcf57600080fd5b8235614fda81614d4c565b91506020830135614b3d81614aa8565b600060208284031215614ffc57600080fd5b5035919050565b6000806020838503121561501657600080fd5b823567ffffffffffffffff8082111561502e57600080fd5b818501915085601f83011261504257600080fd5b81358181111561505157600080fd5b8660206101608302850101111561506757600080fd5b60209290920196919550909350505050565b600082601f83011261508a57600080fd5b813567ffffffffffffffff8111156150a4576150a4614c80565b6150d560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614cd9565b8181528460208386010111156150ea57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff811681146107eb57600080fd5b8035614ac981615107565b69ffffffffffffffffffff811681146107eb57600080fd5b8035614ac981615125565b6000610160828403121561515b57600080fd5b615163614caf565b905061516e82614f83565b815261517c60208301614d6e565b602082015261518d60408301614d6e565b604082015261519e60608301614abe565b60608201526151af60808301614b04565b60808201526151c060a08301614f83565b60a08201526151d160c0830161511a565b60c082015260e082013560e08201526101006151ee81840161513d565b9082015261012061520083820161511a565b9082015261014061521283820161511a565b9082015292915050565b600080600080600080610200878903121561523657600080fd5b863567ffffffffffffffff8082111561524e57600080fd5b61525a8a838b01615079565b9750602089013591508082111561527057600080fd5b5061527d89828a01615079565b955050604087013561528e81614f69565b9350606087013561529e81614f69565b925060808701356152ae81614d4c565b91506152bd8860a08901615148565b90509295509295509295565b60078110615300577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161531282856152c9565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561537357815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615341565b509495945050505050565b60006bffffffffffffffffffffffff808916835273ffffffffffffffffffffffffffffffffffffffff808916602085015281881660408501528087166060850152505060c060808301526153d560c083018561532d565b90508260a0830152979650505050505050565b600080600080606085870312156153fe57600080fd5b843561540981614d4c565b935060208501359250604085013567ffffffffffffffff81111561542c57600080fd5b61543887828801614beb565b95989497509550505050565b60006020828403121561545657600080fd5b8135614aeb81614ea6565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156154a257845183529383019391830191600101615486565b50508481036040860152610f3c818761532d565b600081518084526020808501945080840160005b8381101561537357815163ffffffff16875295820195908201906001016154ca565b61ffff851681526bffffffffffffffffffffffff841660208201527fffffffff000000000000000000000000000000000000000000000000000000008316604082015260806060820152600061554560808301846154b6565b9695505050505050565b60006020828403121561556157600080fd5b8135614aeb81614d4c565b6000806020838503121561557f57600080fd5b823567ffffffffffffffff81111561559657600080fd5b6155a285828601614beb565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c908216806155f157607f821691505b60208210810361562a577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b8281526040602082015260006156496040830184614b48565b949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115612a6557612a65615651565b601f8211156118e257600081815260208120601f850160051c810160208610156156ba5750805b601f850160051c820191505b818110156156d9578281556001016156c6565b505050505050565b815167ffffffffffffffff8111156156fb576156fb614c80565b61570f8161570984546155dd565b84615693565b602080601f831160018114615762576000841561572c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156d9565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157af57888601518255948401946001909101908401615790565b50858210156157eb57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361588057615880615651565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158ac576158ac615651565b5092915050565b6000602082840312156158c557600080fd5b81518015158114614aeb57600080fd5b6000602082840312156158e757600080fd5b5051919050565b600060ff821660ff810361590457615904615651565b60010192915050565b6000610160828403121561592057600080fd5b614aeb8383615148565b81516bffffffffffffffffffffffff16815261016081016020830151615968602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615990604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159ac606084018267ffffffffffffffff169052565b5060808301516159c4608084018263ffffffff169052565b5060a08301516159e460a08401826bffffffffffffffffffffffff169052565b5060c08301516159fd60c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a268285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b67ffffffffffffffff8181168382160190808211156158ac576158ac615651565b81810381811115612a6557612a65615651565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161564960408301846152c9565b64ffffffffff8181168382160190808211156158ac576158ac615651565b6bffffffffffffffffffffffff818116838216028082169190828114615a5157615a51615651565b6bffffffffffffffffffffffff8181168382160190808211156158ac576158ac615651565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615b9360408201856152c9565b60a060608201526000615ba960a0830185614b48565b8281036080840152610f3c8185614b48565b600067ffffffffffffffff808316818103615bd857615bd8615651565b6001019392505050565b8051614ac981614f69565b8051614ac981614af2565b60008060008060808587031215615c0e57600080fd5b8451615c1981614ea6565b80945050602080860151615c2c81614f69565b60408701519094507fffffffff0000000000000000000000000000000000000000000000000000000081168114615c6257600080fd5b606087015190935067ffffffffffffffff811115615c7f57600080fd5b8601601f81018813615c9057600080fd5b8051615c9e614d9a82614d28565b81815260059190911b8201830190838101908a831115615cbd57600080fd5b928401925b82841015615ce4578351615cd581614af2565b82529284019290840190615cc2565b979a9699509497505050505050565b6bffffffffffffffffffffffff841681527fffffffff0000000000000000000000000000000000000000000000000000000083166020820152606060408201526000615d4260608301846154b6565b95945050505050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615d98610120850183614b48565b91506060850151615db5608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615de760e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b8051614ac981614d4c565b8051614ac981614aa8565b8051614ac981615107565b8051614ac981615125565b60006101608284031215615e4957600080fd5b615e51614caf565b615e5a83615be2565b8152615e6860208401615e0a565b6020820152615e7960408401615e0a565b6040820152615e8a60608401615e15565b6060820152615e9b60808401615bed565b6080820152615eac60a08401615be2565b60a0820152615ebd60c08401615e20565b60c082015260e083015160e0820152610100615eda818501615e2b565b90820152610120615eec848201615e20565b90820152610140615efe848201615e20565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff8089168352808816602084015280871660408401525060c06060830152615f4a60c0830186614b48565b905061ffff8416608083015263ffffffff831660a0830152979650505050505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006156496040830184614b48565b838152606060208201526000615fb56060830185614b48565b82810360408401526155458185614b4856fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"}],\"name\":\"SafeERC20FailedOperation\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"timelockEndBlock\",\"type\":\"uint64\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b506040516200651c3803806200651c8339810160408190526200003491620004a3565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc816200014b565b5050600b805461ffff80881661ffff1990921691909117909155841660a052506000805260086020527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c780546001600160a01b031916301790556200014181620001fd565b5050505062000641565b336001600160a01b03821603620001a55760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b805160098054602080850151604086015160e01c600160701b0263ffffffff60701b196001600160601b0390921662010000026001600160701b031990941661ffff9096169590951792909217919091169290921781556060830151805184936200026e92600a92910190620002ae565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051620002a39190620005b2565b60405180910390a150565b82805482825590600052602060002090600701600890048101928215620003525791602002820160005b838211156200031e57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302620002d8565b8015620003505782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200031e565b505b506200036092915062000364565b5090565b5b8082111562000360576000815560010162000365565b805161ffff811681146200038e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051608081016001600160401b0381118282101715620003ce57620003ce62000393565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620003ff57620003ff62000393565b604052919050565b600082601f8301126200041957600080fd5b815160206001600160401b0382111562000437576200043762000393565b8160051b62000448828201620003d4565b92835284810182019282810190878511156200046357600080fd5b83870192505b848310156200049857825163ffffffff81168114620004885760008081fd5b8252918301919083019062000469565b979650505050505050565b60008060008060808587031215620004ba57600080fd5b620004c5856200037b565b9350620004d5602086016200037b565b60408601519093506001600160a01b0381168114620004f357600080fd5b60608601519092506001600160401b03808211156200051157600080fd5b90860190608082890312156200052657600080fd5b62000530620003a9565b6200053b836200037b565b815260208301516001600160601b03811681146200055857600080fd5b602082015260408301516001600160e01b0319811681146200057957600080fd5b60408201526060830151828111156200059157600080fd5b6200059f8a82860162000407565b6060830152509598949750929550505050565b6020808252825161ffff1682820152828101516001600160601b03166040808401919091528301516001600160e01b031916606080840191909152830151608080840152805160a0840181905260009291820190839060c08601905b808310156200063657835163ffffffff1682529284019260019290920191908401906200060e565b509695505050505050565b60805160a051615e9c620006806000396000505060008181611174015281816124f101528181612bc801528181612cd0015261345e0152615e9c6000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063a9c9a918116100e3578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f14610704578063eb523d6c14610717578063f2fde38b1461072a57600080fd5b8063d7ae1d30146106cb578063e72f6e30146106de578063e82ad7d4146106f157600080fd5b8063b734c0f4116100c8578063b734c0f414610697578063badc3eb61461069f578063c3f909d4146106b657600080fd5b8063a9c9a9181461065e578063aab396bd1461067157600080fd5b80639f87fad71161013a578063a21a23e41161011f578063a21a23e414610623578063a47c76961461062b578063a4c0ed361461064b57600080fd5b80639f87fad7146105ef578063a1d4c8281461060257600080fd5b8063823597401161016b57806382359740146105b15780638456cb59146105c45780638da5cb5b146105cc57600080fd5b80637341c10c1461059657806379ba5097146105a957600080fd5b806341db4ca31161023f5780635ed6dfba116101f3578063674603d0116101cd578063674603d0146104b65780636a2215de1461054b5780636e3b33231461058357600080fd5b80635ed6dfba1461046957806366316d8d1461047c578063664199701461048f57600080fd5b80634b8832d3116102245780634b8832d31461041157806355fedefa146104245780635c975abb1461045257600080fd5b806341db4ca3146103dd578063461d2762146103fe57600080fd5b80631c02453911610296578063385de9ae1161027b578063385de9ae146103af5780633e871e4d146103c25780633f4ba83a146103d557600080fd5b80631c024539146103945780631ded3b361461039c57600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614960565b61073d565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f661032636600461499a565b61079c565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614a41565b6102f6610898565b6102f66103aa366004614a54565b610a1e565b6102f66103bd366004614ac9565b610a50565b6102f66103d0366004614ca5565b610b59565b6102f6610e9a565b6103f06103eb366004614d6e565b610eac565b60405190815260200161030f565b6103f061040c366004614d6e565b610f0c565b6102f661041f366004614df3565b610f18565b6103f0610432366004614960565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f6610477366004614e46565b611016565b6102f661048a366004614e46565b6111b8565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b6105236104c4366004614e74565b73ffffffffffffffffffffffffffffffffffffffff91909116600090815260046020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff928316602085015291169082015260600161030f565b61055e610559366004614ea2565b61128f565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f6610591366004614ebb565b61134e565b6102f66105a4366004614df3565b61162a565b6102f66117c0565b6102f66105bf366004614960565b6118e7565b6102f6611a36565b600654610100900473ffffffffffffffffffffffffffffffffffffffff1661055e565b6102f66105fd366004614df3565b611a46565b6106156106103660046150d4565b611e1b565b60405161030f9291906151bc565b61049d61220f565b61063e610639366004614960565b61239c565b60405161030f9190615236565b6102f66106593660046152be565b6124d1565b61055e61066c366004614ea2565b61271d565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976103f0565b6102f6612782565b6106a761293c565b60405161030f9392919061531a565b6106be612a15565b60405161030f919061536f565b6102f66106d9366004614df3565b612b2c565b6102f66106ec36600461540e565b612b8f565b6104596106ff366004614960565b612d4c565b6102f661071236600461542b565b612e9b565b6102f6610725366004614ea2565b612fc1565b6102f661073836600461540e565b61318c565b61074561319d565b61074e816131a5565b67ffffffffffffffff81166000908152600360205260409020546107999082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661321b565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600a54911a908110610801576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600060096001018260ff168154811061081c5761081c61546d565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610892576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107f8565b50505050565b6108a0613507565b60008080526010602052604080518082019091527f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb018054829082906108e49061549c565b80601f01602080910402602001604051908101604052809291908181526020018280546109109061549c565b801561095d5780601f106109325761010080835404028352916020019161095d565b820191906000526020600020905b81548152906001019060200180831161094057829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156109bf576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109df81600001518060200190518101906109da9190615505565b61358d565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a13916000919061562f565b60405180910390a150565b610a2661319d565b610a2f826131a5565b67ffffffffffffffff90911660009081526003602081905260409091200155565b610a58613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190610aad9061ffff1643615677565b67ffffffffffffffff169052600084815260106020526040902081518190610ad590826156d8565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90610b4c908590859085906157f2565b60405180910390a1505050565b610b61613507565b8151815181141580610b735750600881115b15610baa576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610cd6576000848281518110610bc957610bc961546d565b602002602001015190506000848381518110610be757610be761546d565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c52575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c89576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cc3576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b505080610ccf90615846565b9050610bad565b50600b54600090610ceb9061ffff1643615677565b60408051606081018252868152602080820187905267ffffffffffffffff841692820192909252865192935091600d91610d299183918901906147a0565b506020828101518051610d4292600185019201906147e7565b5060409190910151600290910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff90921691909117905560005b8451811015610e93577fbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e858281518110610dc457610dc461546d565b602002602001015160086000888581518110610de257610de261546d565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e2b57610e2b61546d565b602002602001015185604051610e7b949392919093845273ffffffffffffffffffffffffffffffffffffffff92831660208501529116604083015267ffffffffffffffff16606082015260800190565b60405180910390a1610e8c81615846565b9050610d88565b5050505050565b610ea2613507565b610eaa61366f565b565b600080610eb88361128f565b9050610f0083828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b91506136ec9050565b98975050505050505050565b600080610eb88361271d565b610f20613a41565b610f2982613a49565b610f31613b0f565b67ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146110125767ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b61101e61319d565b806bffffffffffffffffffffffff166000036110545750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff808316911610156110ae576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b30600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff1661587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806000808282829054906101000a90046bffffffffffffffffffffffff16611131919061587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061101282826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6111c0613a41565b806bffffffffffffffffffffffff16600003611208576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff80831691161015611262576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff1661587e565b6000805b600d5460ff8216101561131857600d805460ff83169081106112b7576112b761546d565b9060005260206000200154830361130857600e805460ff83169081106112df576112df61546d565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b611311816158aa565b9050611293565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b611356613a41565b60005b818110156116255760008383838181106113755761137561546d565b9050610160020180360381019061138c91906158c9565b905060008160e0015190506000826060015190506005600083815260200190815260200160002054836040516020016113c591906158e6565b6040516020818303038152906040528051906020012014611412576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611457576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af11580156114ca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114ee9190615a15565b5060a083015167ffffffffffffffff82166000908152600360205260408120600101805490919061152e9084906bffffffffffffffffffffffff1661587e565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff8086168452915291902080546001926009916115b59185916901000000000000000000900416615a37565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061161e90615846565b9050611359565b505050565b611632613a41565b61163b82613a49565b611643613b0f565b60095467ffffffffffffffff831660009081526003602052604090206002015461ffff90911690036116a1576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8616845290915290205460ff16156116e8575050565b73ffffffffffffffffffffffffffffffffffffffff8116600081815260046020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611009565b60075473ffffffffffffffffffffffffffffffffffffffff163314611841576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107f8565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118ef613a41565b6118f7613b0f565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611997576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107f8565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611a3e613507565b610eaa613cdf565b611a4e613a41565b611a5782613a49565b611a5f613b0f565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b07576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611b5c576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611bd757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611bac575b5050505050905060005b8151811015611d7f578373ffffffffffffffffffffffffffffffffffffffff16828281518110611c1357611c1361546d565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611d6f578160018351611c459190615a58565b81518110611c5557611c5561546d565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611c9857611c9861546d565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611d1257611d12615a6b565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611d7f565b611d7881615846565b9050611be1565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080611e26613a41565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611e8f576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e0830151600090815260056020526040902054611ef757600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615a9a565b60405180910390a2506000612204565b600560008460e0015181526020019081526020016000205483604051602001611f2091906158e6565b6040516020818303038152906040528051906020012014611f7b57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615a9a565b826101400151836080015163ffffffff16611f969190615acc565b64ffffffffff165a1015611fe457600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615a9a565b6000611ff9846080015163ffffffff16613d3a565b6120039088615aea565b90506000818786600001516120189190615b12565b6120229190615b12565b606086015167ffffffffffffffff166000908152600360205260409020549091506bffffffffffffffffffffffff90811690821611156120b057600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615a9a565b60405180910390a250600091506122049050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561211857600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615a9a565b5050600560008460e0015181526020019081526020016000206000905560006121508460e001518a8a87608001518860400151613ddc565b8051909150612160576001612163565b60005b9250600061219285606001518660a00151876040015188600001518c61218c8860200151613d3a565b8d613f58565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b8360200151898887600001516121df578e6121e1565b8f5b88604001516040516121f7959493929190615b37565b60405180910390a3519150505b965096945050505050565b6000612219613a41565b612221613b0f565b6002805460009061223b9067ffffffffffffffff16615b99565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156122b1578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261234c926002850192909101906147e7565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a08101919091526123d6826131a5565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156124b757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161248c575b505050505081526020016003820154815250509050919050565b6124d9613a41565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614612548576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612582576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061259082840184614960565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612609576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906126408385615b12565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff166126969190615b12565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126fd9190615677565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff168061277c576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107f8565b92915050565b61278a613507565b600f5467ffffffffffffffff164310156127d0576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600d548110156128f3576000600d60000182815481106127f5576127f561546d565b906000526020600020015490506000600d600101838154811061281a5761281a61546d565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556128ec81615846565b90506127d3565b50600d60006129028282614861565b612910600183016000614861565b5060020180547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000169055565b600f54600d80546040805160208084028201810190925282815267ffffffffffffffff909416936060938493919290919083018282801561299c57602002820191906000526020600020905b815481526020019060010190808311612988575b50505050509150600d600101805480602002602001604051908101604052809291908181526020018280548015612a0957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129de575b50505050509050909192565b6040805160808101825260008082526020820181905291810191909152606080820152604080516080810182526009805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff000000000000000000000000000000000000000000000000000000001683850152600a805485518184028101840190965280865293949293606086019392830182828015612b1e57602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ae15790505b505050505081525050905090565b612b34613a41565b612b3d82613a49565b612b45613b0f565b612b4e82612d4c565b15612b85576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611012828261321b565b612b9761319d565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612c24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c489190615bc0565b6000549091506bffffffffffffffffffffffff1681811115612ca0576040517fa99da30200000000000000000000000000000000000000000000000000000000815260048101829052602481018390526044016107f8565b81811015611625576000612cb48284615a58565b9050612cf773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613c52565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612dc457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d99575b5050505050905060005b8151811015612e9157600060046000848481518110612def57612def61546d565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612e8057506001949350505050565b50612e8a81615846565b9050612dce565b5060009392505050565b612ea3613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190612ef89061ffff1643615677565b67ffffffffffffffff16905260008052601060205280517f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb01908190612f3d90826156d8565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90612fb590600090859085906157f2565b60405180910390a15050565b612fc9613507565b6000818152601060205260408082208151808301909252805482908290612fef9061549c565b80601f016020809104026020016040519081016040528092919081815260200182805461301b9061549c565b80156130685780601f1061303d57610100808354040283529160200191613068565b820191906000526020600020905b81548152906001019060200180831161304b57829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156130ca576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6130d38261271d565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161312791600401614a41565b600060405180830381600087803b15801561314157600080fd5b505af1158015613155573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c79350612fb5925085919061562f565b613194613507565b610799816141a1565b610eaa613507565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610799576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156132fc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116132d1575b505050918352505060039190910154602090910152805190915060005b8260800151518110156133bd5760046000846080015183815181106133405761334061546d565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556133b681615846565b9050613319565b5067ffffffffffffffff8416600090815260036020526040812081815560018101829055906133ef6002830182614861565b5060006003919091018190558054829190819061341b9084906bffffffffffffffffffffffff1661587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506134a283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611e0d565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107f8565b805160098054602080850151604086015160e01c6e010000000000000000000000000000027fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff6bffffffffffffffffffffffff90921662010000027fffffffffffffffffffffffffffffffffffff000000000000000000000000000090941661ffff90961695909517929092179190911692909217815560608301518051849361363c92600a9291019061487f565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051610a13919061536f565b61367761429d565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b60006136f6613a41565b6136ff856131a5565b6137093386614309565b613713858361079c565b604080516101008101825233815267ffffffffffffffff8716600081815260036020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b16608088015294845290829052015460a084015263ffffffff861660c08401526009546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e880916137f29190600401615bd9565b610160604051808303816000875af1158015613812573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138369190615cc4565b9050604051806101600160405280600960000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff1681525060405160200161394591906158e6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a081015161399f903390889061437d565b60e081015167ffffffffffffffff8716600081815260036020526040908190205460a0850151915192938c9390927ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec992613a2a926c0100000000000000000000000090910473ffffffffffffffffffffffffffffffffffffffff1691339132918e918e918e91615d97565b60405180910390a460e00151979650505050505050565b610eaa614458565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613ac0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611012576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760005260086020527f29d6d16866b6e23fcc7ae534ca080a7a6eca5e1882ac6bf4569628fa2ee46ea45473ffffffffffffffffffffffffffffffffffffffff1680613b785750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613bd990339060248101615e0f565b602060405180830381865afa158015613bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c1a9190615a15565b610799576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107f8565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526116259084906144c5565b613ce7614458565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586136c23390565b60006bffffffffffffffffffffffff821115613dd8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107f8565b5090565b604080516060808201835260008083526020830152918101919091526009546040516000916e010000000000000000000000000000900460e01b90613e2990899089908990602401615e3e565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613edb57600080fd5b5a611388811015613eeb57600080fd5b611388810390508760408204820311613f0357600080fd5b60008086516020880160008b8df193505a900391503d6084811115613f26575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613f788486615aea565b9050600081613f878886615b12565b613f919190615b12565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f1660009081526003909152928320805492975093945084939291613fe89185911661587e565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d9450909261403c9185911661587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846140769190615b12565b33600090815260016020526040812080549091906140a39084906bffffffffffffffffffffffff16615b12565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926140ea91859116615b12565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161416e9185916901000000000000000000900416615a37565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603614220576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107f8565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff16610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107f8565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16611012576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143b79084906bffffffffffffffffffffffff16615b12565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261442d928492900416615a37565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60065460ff1615610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107f8565b60006144e773ffffffffffffffffffffffffffffffffffffffff84168361455b565b9050805160001415801561450c57508080602001905181019061450a9190615a15565b155b15611625576040517f5274afe700000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201526024016107f8565b606061459f838360006040518060400160405280601e81526020017f416464726573733a206c6f772d6c6576656c2063616c6c206661696c656400008152506145a6565b9392505050565b606082471015614638576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107f8565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516146619190615e73565b60006040518083038185875af1925050503d806000811461469e576040519150601f19603f3d011682016040523d82523d6000602084013e6146a3565b606091505b50915091506146b4878383876146c1565b925050505b949350505050565b606083156147575782516000036147505773ffffffffffffffffffffffffffffffffffffffff85163b614750576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107f8565b50816146b9565b6146b9838381511561476c5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107f89190614a41565b8280548282559060005260206000209081019282156147db579160200282015b828111156147db5782518255916020019190600101906147c0565b50613dd8929150614925565b8280548282559060005260206000209081019282156147db579160200282015b828111156147db57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614807565b50805460008255906000526020600020908101906107999190614925565b828054828255906000526020600020906007016008900481019282156147db5791602002820160005b838211156148ec57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026148a8565b801561491c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026148ec565b5050613dd89291505b5b80821115613dd85760008155600101614926565b67ffffffffffffffff8116811461079957600080fd5b803561495b8161493a565b919050565b60006020828403121561497257600080fd5b813561459f8161493a565b63ffffffff8116811461079957600080fd5b803561495b8161497d565b600080604083850312156149ad57600080fd5b82356149b88161493a565b915060208301356149c88161497d565b809150509250929050565b60005b838110156149ee5781810151838201526020016149d6565b50506000910152565b60008151808452614a0f8160208601602086016149d3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061459f60208301846149f7565b60008060408385031215614a6757600080fd5b8235614a728161493a565b946020939093013593505050565b60008083601f840112614a9257600080fd5b50813567ffffffffffffffff811115614aaa57600080fd5b602083019150836020828501011115614ac257600080fd5b9250929050565b600080600060408486031215614ade57600080fd5b83359250602084013567ffffffffffffffff811115614afc57600080fd5b614b0886828701614a80565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614b6857614b68614b15565b60405290565b6040516080810167ffffffffffffffff81118282101715614b6857614b68614b15565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614bd857614bd8614b15565b604052919050565b600067ffffffffffffffff821115614bfa57614bfa614b15565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461079957600080fd5b803561495b81614c04565b600082601f830112614c4257600080fd5b81356020614c57614c5283614be0565b614b91565b82815260059290921b84018101918181019086841115614c7657600080fd5b8286015b84811015614c9a578035614c8d81614c04565b8352918301918301614c7a565b509695505050505050565b60008060408385031215614cb857600080fd5b823567ffffffffffffffff80821115614cd057600080fd5b818501915085601f830112614ce457600080fd5b81356020614cf4614c5283614be0565b82815260059290921b84018101918181019089841115614d1357600080fd5b948201945b83861015614d3157853582529482019490820190614d18565b96505086013592505080821115614d4757600080fd5b50614d5485828601614c31565b9150509250929050565b61ffff8116811461079957600080fd5b60008060008060008060a08789031215614d8757600080fd5b8635614d928161493a565b9550602087013567ffffffffffffffff811115614dae57600080fd5b614dba89828a01614a80565b9096509450506040870135614dce81614d5e565b92506060870135614dde8161497d565b80925050608087013590509295509295509295565b60008060408385031215614e0657600080fd5b8235614e118161493a565b915060208301356149c881614c04565b6bffffffffffffffffffffffff8116811461079957600080fd5b803561495b81614e21565b60008060408385031215614e5957600080fd5b8235614e6481614c04565b915060208301356149c881614e21565b60008060408385031215614e8757600080fd5b8235614e9281614c04565b915060208301356149c88161493a565b600060208284031215614eb457600080fd5b5035919050565b60008060208385031215614ece57600080fd5b823567ffffffffffffffff80821115614ee657600080fd5b818501915085601f830112614efa57600080fd5b813581811115614f0957600080fd5b86602061016083028501011115614f1f57600080fd5b60209290920196919550909350505050565b600082601f830112614f4257600080fd5b813567ffffffffffffffff811115614f5c57614f5c614b15565b614f8d60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614b91565b818152846020838601011115614fa257600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461079957600080fd5b803561495b81614fbf565b69ffffffffffffffffffff8116811461079957600080fd5b803561495b81614fdd565b6000610160828403121561501357600080fd5b61501b614b44565b905061502682614e3b565b815261503460208301614c26565b602082015261504560408301614c26565b604082015261505660608301614950565b60608201526150676080830161498f565b608082015261507860a08301614e3b565b60a082015261508960c08301614fd2565b60c082015260e082013560e08201526101006150a6818401614ff5565b908201526101206150b8838201614fd2565b908201526101406150ca838201614fd2565b9082015292915050565b60008060008060008061020087890312156150ee57600080fd5b863567ffffffffffffffff8082111561510657600080fd5b6151128a838b01614f31565b9750602089013591508082111561512857600080fd5b5061513589828a01614f31565b955050604087013561514681614e21565b9350606087013561515681614e21565b9250608087013561516681614c04565b91506151758860a08901615000565b90509295509295509295565b600781106151b8577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b604081016151ca8285615181565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561522b57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016151f9565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526152a860e08401826151e5565b905060a084015160c08401528091505092915050565b600080600080606085870312156152d457600080fd5b84356152df81614c04565b935060208501359250604085013567ffffffffffffffff81111561530257600080fd5b61530e87828801614a80565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561535b5784518352938301939183019160010161533f565b50508481036040860152610f0081876151e5565b6000602080835260a0830161ffff855116828501526bffffffffffffffffffffffff828601511660408501527fffffffff000000000000000000000000000000000000000000000000000000006040860151166060850152606085015160808086015281815180845260c0870191508483019350600092505b80831015614c9a57835163ffffffff1682529284019260019290920191908401906153e8565b60006020828403121561542057600080fd5b813561459f81614c04565b6000806020838503121561543e57600080fd5b823567ffffffffffffffff81111561545557600080fd5b61546185828601614a80565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c908216806154b057607f821691505b6020821081036154e9577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b805161495b81614e21565b805161495b8161497d565b6000602080838503121561551857600080fd5b825167ffffffffffffffff8082111561553057600080fd5b908401906080828703121561554457600080fd5b61554c614b6e565b825161555781614d5e565b81528284015161556681614e21565b8185015260408301517fffffffff000000000000000000000000000000000000000000000000000000008116811461559d57600080fd5b60408201526060830151828111156155b457600080fd5b80840193505086601f8401126155c957600080fd5b825191506155d9614c5283614be0565b82815260059290921b830184019184810190888411156155f857600080fd5b938501935b8385101561561f5784516156108161497d565b825293850193908501906155fd565b6060830152509695505050505050565b8281526040602082015260006146b960408301846149f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561277c5761277c615648565b601f82111561162557600081815260208120601f850160051c810160208610156156b15750805b601f850160051c820191505b818110156156d0578281556001016156bd565b505050505050565b815167ffffffffffffffff8111156156f2576156f2614b15565b61570681615700845461549c565b8461568a565b602080601f83116001811461575957600084156157235750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156d0565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157a657888601518255948401946001909101908401615787565b50858210156157e257878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361587757615877615648565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158a3576158a3615648565b5092915050565b600060ff821660ff81036158c0576158c0615648565b60010192915050565b600061016082840312156158dc57600080fd5b61459f8383615000565b81516bffffffffffffffffffffffff16815261016081016020830151615924602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161594c604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060830151615968606084018267ffffffffffffffff169052565b506080830151615980608084018263ffffffff169052565b5060a08301516159a060a08401826bffffffffffffffffffffffff169052565b5060c08301516159b960c084018264ffffffffff169052565b5060e083015160e0830152610100808401516159e28285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b600060208284031215615a2757600080fd5b8151801515811461459f57600080fd5b67ffffffffffffffff8181168382160190808211156158a3576158a3615648565b8181038181111561277c5761277c615648565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016146b96040830184615181565b64ffffffffff8181168382160190808211156158a3576158a3615648565b6bffffffffffffffffffffffff818116838216028082169190828114615a0d57615a0d615648565b6bffffffffffffffffffffffff8181168382160190808211156158a3576158a3615648565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615b716040820185615181565b60a060608201526000615b8760a08301856149f7565b8281036080840152610f0081856149f7565b600067ffffffffffffffff808316818103615bb657615bb6615648565b6001019392505050565b600060208284031215615bd257600080fd5b5051919050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615c266101208501836149f7565b91506060850151615c43608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615c7560e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b805161495b81614c04565b805161495b8161493a565b805161495b81614fbf565b805161495b81614fdd565b60006101608284031215615cd757600080fd5b615cdf614b44565b615ce8836154ef565b8152615cf660208401615c98565b6020820152615d0760408401615c98565b6040820152615d1860608401615ca3565b6060820152615d29608084016154fa565b6080820152615d3a60a084016154ef565b60a0820152615d4b60c08401615cae565b60c082015260e083015160e0820152610100615d68818501615cb9565b90820152610120615d7a848201615cae565b90820152610140615d8c848201615cae565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615dd860e08301876149f7565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006146b960408301846149f7565b838152606060208201526000615e5760608301856149f7565b8281036040840152615e6981856149f7565b9695505050505050565b60008251615e858184602087016149d3565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI var FunctionsRouterBin = FunctionsRouterMetaData.Bin -func DeployFunctionsRouter(auth *bind.TransactOpts, backend bind.ContractBackend, timelockBlocks uint16, maximumTimelockBlocks uint16, linkToken common.Address, config []byte) (common.Address, *types.Transaction, *FunctionsRouter, error) { +func DeployFunctionsRouter(auth *bind.TransactOpts, backend bind.ContractBackend, timelockBlocks uint16, maximumTimelockBlocks uint16, linkToken common.Address, config IFunctionsRouterConfig) (common.Address, *types.Transaction, *FunctionsRouter, error) { parsed, err := FunctionsRouterMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -229,35 +245,25 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetAllowListId() ([32]byte return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (GetConfig, - - error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getConfig") - outstruct := new(GetConfig) if err != nil { - return *outstruct, err + return *new(IFunctionsRouterConfig), err } - outstruct.MaxConsumersPerSubscription = *abi.ConvertType(out[0], new(uint16)).(*uint16) - outstruct.AdminFee = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) - outstruct.HandleOracleFulfillmentSelector = *abi.ConvertType(out[2], new([4]byte)).(*[4]byte) - outstruct.MaxCallbackGasLimits = *abi.ConvertType(out[3], new([]uint32)).(*[]uint32) + out0 := *abi.ConvertType(out[0], new(IFunctionsRouterConfig)).(*IFunctionsRouterConfig) - return *outstruct, err + return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (GetConfig, - - error) { +func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (IFunctionsRouterConfig, error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (GetConfig, - - error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (IFunctionsRouterConfig, error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } @@ -389,37 +395,25 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() ( return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getSubscription", subscriptionId) - outstruct := new(GetSubscription) if err != nil { - return *outstruct, err + return *new(IFunctionsSubscriptionsSubscription), err } - outstruct.Balance = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - outstruct.Owner = *abi.ConvertType(out[1], new(common.Address)).(*common.Address) - outstruct.BlockedBalance = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) - outstruct.RequestedOwner = *abi.ConvertType(out[3], new(common.Address)).(*common.Address) - outstruct.Consumers = *abi.ConvertType(out[4], new([]common.Address)).(*[]common.Address) - outstruct.Flags = *abi.ConvertType(out[5], new([32]byte)).(*[32]byte) + out0 := *abi.ConvertType(out[0], new(IFunctionsSubscriptionsSubscription)).(*IFunctionsSubscriptionsSubscription) - return *outstruct, err + return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { +func (_FunctionsRouter *FunctionsRouterSession) GetSubscription(subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (GetSubscription, - - error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetSubscription(subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) { return _FunctionsRouter.Contract.GetSubscription(&_FunctionsRouter.CallOpts, subscriptionId) } @@ -755,18 +749,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeSubscriptionOwn return _FunctionsRouter.Contract.ProposeSubscriptionOwnerTransfer(&_FunctionsRouter.TransactOpts, subscriptionId, newOwner) } -func (_FunctionsRouter *FunctionsRouterTransactor) ProposeTimelockBlocks(opts *bind.TransactOpts, blocks uint16) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "proposeTimelockBlocks", blocks) -} - -func (_FunctionsRouter *FunctionsRouterSession) ProposeTimelockBlocks(blocks uint16) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeTimelockBlocks(&_FunctionsRouter.TransactOpts, blocks) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeTimelockBlocks(blocks uint16) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeTimelockBlocks(&_FunctionsRouter.TransactOpts, blocks) -} - func (_FunctionsRouter *FunctionsRouterTransactor) RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "recoverFunds", to) } @@ -899,18 +881,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateContracts() (*ty return _FunctionsRouter.Contract.UpdateContracts(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) UpdateTimelockBlocks(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "updateTimelockBlocks") -} - -func (_FunctionsRouter *FunctionsRouterSession) UpdateTimelockBlocks() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateTimelockBlocks(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateTimelockBlocks() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateTimelockBlocks(&_FunctionsRouter.TransactOpts) -} - type FunctionsRouterConfigChangedIterator struct { Event *FunctionsRouterConfigChanged @@ -972,10 +942,8 @@ func (it *FunctionsRouterConfigChangedIterator) Close() error { } type FunctionsRouterConfigChanged struct { - AdminFee *big.Int - HandleOracleFulfillmentSelector [4]byte - MaxCallbackGasLimits []uint32 - Raw types.Log + Arg0 IFunctionsRouterConfig + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) { @@ -2344,16 +2312,17 @@ func (it *FunctionsRouterRequestStartIterator) Close() error { } type FunctionsRouterRequestStart struct { - RequestId [32]byte - DonId [32]byte - SubscriptionId uint64 - SubscriptionOwner common.Address - RequestingContract common.Address - RequestInitiator common.Address - Data []byte - DataVersion uint16 - CallbackGasLimit uint32 - Raw types.Log + RequestId [32]byte + DonId [32]byte + SubscriptionId uint64 + SubscriptionOwner common.Address + RequestingContract common.Address + RequestInitiator common.Address + Data []byte + DataVersion uint16 + CallbackGasLimit uint32 + EstimatedTotalCostJuels *big.Int + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestStart(opts *bind.FilterOpts, requestId [][32]byte, donId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestStartIterator, error) { @@ -3814,12 +3783,6 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParseUnpaused(log types.Log) (* return event, nil } -type GetConfig struct { - MaxConsumersPerSubscription uint16 - AdminFee *big.Int - HandleOracleFulfillmentSelector [4]byte - MaxCallbackGasLimits []uint32 -} type GetConsumer struct { Allowed bool InitiatedRequests uint64 @@ -3830,14 +3793,6 @@ type GetProposedContractSet struct { Ids [][32]byte To []common.Address } -type GetSubscription struct { - Balance *big.Int - Owner common.Address - BlockedBalance *big.Int - RequestedOwner common.Address - Consumers []common.Address - Flags [32]byte -} func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { @@ -3894,7 +3849,7 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig } func (FunctionsRouterConfigChanged) Topic() common.Hash { - return common.HexToHash("0xe6a1eda76d42a6d1d813f26765716562044db1e8bd8be7d088705e64afd301ca") + return common.HexToHash("0x9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf417860") } func (FunctionsRouterConfigProposed) Topic() common.Hash { @@ -3938,7 +3893,7 @@ func (FunctionsRouterRequestProcessed) Topic() common.Hash { } func (FunctionsRouterRequestStart) Topic() common.Hash { - return common.HexToHash("0x7c720ccd20069b8311a6be4ba1cf3294d09eb247aa5d73a8502054b6e68a2f54") + return common.HexToHash("0xf67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9") } func (FunctionsRouterRequestTimedOut) Topic() common.Hash { @@ -3994,9 +3949,7 @@ type FunctionsRouterInterface interface { GetAllowListId(opts *bind.CallOpts) ([32]byte, error) - GetConfig(opts *bind.CallOpts) (GetConfig, - - error) + GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, @@ -4012,9 +3965,7 @@ type FunctionsRouterInterface interface { error) - GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (GetSubscription, - - error) + GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) GetSubscriptionCount(opts *bind.CallOpts) (uint64, error) @@ -4060,8 +4011,6 @@ type FunctionsRouterInterface interface { ProposeSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) - ProposeTimelockBlocks(opts *bind.TransactOpts, blocks uint16) (*types.Transaction, error) - RecoverFunds(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) RemoveConsumer(opts *bind.TransactOpts, subscriptionId uint64, consumer common.Address) (*types.Transaction, error) @@ -4084,8 +4033,6 @@ type FunctionsRouterInterface interface { UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) - UpdateTimelockBlocks(opts *bind.TransactOpts) (*types.Transaction, error) - FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigChanged) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 05a51012855..afbdedfabb7 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -4,9 +4,9 @@ functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfSer functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 525316bc1fab9f1d6d262ac9fc1087f66a8314de4dcc9684ba78a29e8014328f -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 078a41c5c56dae19be70bf19d15d61cd7dba5a306a58ac8b7b6ccdfe3baf4bd3 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin d9eeb059cd99938094bfa15f86d33399c5e0a58d196294bc0ab5148463cc0391 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin f14117bbc3f9f50b7098d44c83b3270cb382b7b3cc4047bc645baf7224420f32 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin c9de640eefd95cca557cc482a35f4bad477455665996c944d05fcbdd9207813b ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 5d73912aa55..abed26e1996 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -179,20 +179,15 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, require.NoError(t, err) uint80Type, err := abi.NewType("uint80", "uint80", nil) require.NoError(t, err) - uint96Type, err := abi.NewType("uint96", "uint96", nil) - require.NoError(t, err) uint256Type, err := abi.NewType("uint256", "uint256", nil) require.NoError(t, err) int256Type, err := abi.NewType("int256", "int256", nil) require.NoError(t, err) - bytes4Type, err := abi.NewType("bytes4", "bytes4", nil) require.NoError(t, err) boolType, err := abi.NewType("bool", "bool", nil) require.NoError(t, err) addressType, err := abi.NewType("address", "address", nil) require.NoError(t, err) - uint32ArrType, err := abi.NewType("uint32[]", "uint32[]", nil) - require.NoError(t, err) // Deploy LINK token linkAddr, _, linkToken, err := link_token_interface.DeployLinkToken(owner, b) @@ -203,12 +198,6 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, require.NoError(t, err) // Deploy Router contract - routerConfigABI := abi.Arguments{ - {Type: uint16Type}, // maxConsumers - {Type: uint96Type}, // adminFee - {Type: bytes4Type}, // handleOracleFulfillmentSelector - {Type: uint32ArrType}, // maxCallbackGasLimits - } var maxConsumers = uint16(100) var adminFee = big.NewInt(0) handleOracleFulfillmentSelectorSlice, err := hex.DecodeString("0ca76175") @@ -216,11 +205,10 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, var handleOracleFulfillmentSelector [4]byte copy(handleOracleFulfillmentSelector[:], handleOracleFulfillmentSelectorSlice[:4]) maxCallbackGasLimits := []uint32{300_000, 500_000, 1_000_000} - routerConfig, err := routerConfigABI.Pack(maxConsumers, adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits) require.NoError(t, err) var timelockBlocks = uint16(0) var maximumTimelockBlocks = uint16(10) - routerAddress, _, routerContract, err := functions_router.DeployFunctionsRouter(owner, b, timelockBlocks, maximumTimelockBlocks, linkAddr, routerConfig) + routerAddress, _, routerContract, err := functions_router.DeployFunctionsRouter(owner, b, timelockBlocks, maximumTimelockBlocks, linkAddr, functions_router.IFunctionsRouterConfig{maxConsumers, adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits}) require.NoError(t, err) // Deploy Allow List contract From 8edf2758101fbf9083ddf1b6a25b36240d1de189 Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Fri, 4 Aug 2023 10:55:07 +0200 Subject: [PATCH 078/270] Clean up v0.8 folder (#10017) * move ConfirmedOwner to shared * move ocr2 and AuthorizedReceiver * rm duplicate ITypeAndVersion * mv LinkTokenInterface and ERC677ReceiverInterface to shared * move automation interfaces to automation folder * rm utils.sol * move CRON lib to automation * ERC677ReceiverInterface -> IERC677Receiver --- contracts/src/v0.8/ChainlinkClient.sol | 2 +- contracts/src/v0.8/PermissionedForwardProxy.sol | 2 +- .../src/v0.8/SimpleWriteAccessController.sol | 2 +- contracts/src/v0.8/ValidatorProxy.sol | 2 +- .../v0.8/automation/1_2/KeeperRegistrar1_2.sol | 10 +++++----- .../v0.8/automation/1_2/KeeperRegistry1_2.sol | 16 ++++++++-------- ...eperRegistryCheckUpkeepGasUsageWrapper1_2.sol | 4 ++-- .../v0.8/automation/1_3/KeeperRegistry1_3.sol | 8 ++++---- .../automation/1_3/KeeperRegistryBase1_3.sol | 10 +++++----- .../automation/1_3/KeeperRegistryLogic1_3.sol | 4 ++-- .../v0.8/automation/2_0/KeeperRegistrar2_0.sol | 10 +++++----- .../v0.8/automation/2_0/KeeperRegistry2_0.sol | 12 ++++++------ .../automation/2_0/KeeperRegistryBase2_0.sol | 10 +++++----- .../automation/2_0/KeeperRegistryLogic2_0.sol | 4 ++-- .../src/v0.8/automation/AutomationCompatible.sol | 2 +- .../src/v0.8/automation/HeartbeatRequester.sol | 2 +- .../src/v0.8/automation/KeeperCompatible.sol | 2 +- .../src/v0.8/automation/UpkeepTranscoder.sol | 2 +- .../1_2/AutomationRegistryInterface1_2.sol | 0 .../1_2/KeeperRegistryInterface1_2.sol | 0 .../1_3/AutomationRegistryInterface1_3.sol | 0 .../2_0/AutomationRegistryInterface2_0.sol | 0 .../AutomationCompatibleInterface.sol | 0 .../interfaces}/KeeperCompatibleInterface.sol | 0 .../MigratableKeeperRegistryInterface.sol | 2 +- .../MigratableKeeperRegistryInterfaceV2.sol | 2 +- .../interfaces}/UpkeepTranscoderInterface.sol | 2 +- .../interfaces}/UpkeepTranscoderInterfaceV2.sol | 0 .../{ => automation}/libraries/external/Cron.sol | 0 .../{ => automation}/libraries/internal/Cron.sol | 4 ++-- .../testhelpers}/CronTestHelper.sol | 0 .../testhelpers}/CronUpkeepTestHelper.sol | 2 +- .../src/v0.8/automation/upkeeps/CronUpkeep.sol | 8 ++++---- .../automation/upkeeps/CronUpkeepDelegate.sol | 2 +- .../automation/upkeeps/CronUpkeepFactory.sol | 4 ++-- .../automation/upkeeps/ERC20BalanceMonitor.sol | 4 ++-- .../automation/upkeeps/EthBalanceMonitor.sol | 4 ++-- .../src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol | 2 +- contracts/src/v0.8/dev/CrossDomainOwnable.sol | 2 +- .../src/v0.8/dev/OptimismSequencerUptimeFeed.sol | 2 +- .../v0.8/dev/VRFSubscriptionBalanceMonitor.sol | 6 +++--- .../automation/2_1/AutomationForwarderLogic.sol | 2 +- .../automation/2_1/AutomationRegistrar2_1.sol | 8 ++++---- .../dev/automation/2_1/KeeperRegistry2_1.sol | 6 +++--- .../dev/automation/2_1/KeeperRegistryBase2_1.sol | 8 ++++---- .../automation/2_1/KeeperRegistryLogicA2_1.sol | 4 ++-- .../dev/automation/2_1/UpkeepTranscoder4_0.sol | 4 ++-- .../2_1/interfaces/IAutomationForwarder.sol | 2 +- .../src/v0.8/dev/automation/CanaryUpkeep1_2.sol | 6 +++--- .../v0.8/dev/automation/UpkeepTranscoder3_0.sol | 2 +- .../upkeeps/LinkAvailableBalanceMonitor.sol | 4 ++-- contracts/src/v0.8/dev/ocr2/OCR2Base.sol | 2 +- .../src/v0.8/dev/transmission/4337/Paymaster.sol | 4 ++-- contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol | 8 ++++---- .../src/v0.8/dev/vrf/VRFConsumerBaseV2Plus.sol | 2 +- .../src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 2 +- contracts/src/v0.8/dev/vrf/VRFV2PlusWrapper.sol | 4 ++-- .../dev/vrf/VRFV2PlusWrapperConsumerBase.sol | 2 +- .../VRFConsumerV2PlusUpgradeableExample.sol | 2 +- .../VRFCoordinatorV2Plus_V2Example.sol | 2 +- .../testhelpers/VRFMaliciousConsumerV2Plus.sol | 2 +- .../vrf/testhelpers/VRFV2PlusConsumerExample.sol | 4 ++-- .../VRFV2PlusExternalSubOwnerExample.sol | 2 +- .../testhelpers/VRFV2PlusRevertingExample.sol | 2 +- .../VRFV2PlusSingleConsumerExample.sol | 2 +- .../VRFV2PlusWrapperConsumerExample.sol | 2 +- .../dev/0_0_0/FunctionsBillingRegistry.sol | 6 +++--- .../accessControl/ConfirmedOwnerUpgradeable.sol | 4 ++-- .../dev/0_0_0/example/FunctionsClientExample.sol | 2 +- .../v0.8/functions/dev/0_0_0/ocr/OCR2Base.sol | 2 +- .../v0.8/functions/dev/1_0_0/FunctionsRouter.sol | 2 +- .../dev/1_0_0/FunctionsSubscriptions.sol | 5 +++-- .../dev/1_0_0/example/FunctionsClientExample.sol | 2 +- .../v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol | 2 +- .../mocks/ConfirmedOwnerUpgradeable.sol | 4 ++-- .../mocks/FunctionsBillingRegistryMigration.sol | 6 +++--- .../mocks/FunctionsBillingRegistryOriginal.sol | 6 +++--- .../src/v0.8/interfaces/ITypeAndVersion.sol | 6 ------ .../src/v0.8/interfaces/OwnableInterface.sol | 10 ---------- contracts/src/v0.8/llo-feeds/Verifier.sol | 2 +- contracts/src/v0.8/llo-feeds/VerifierProxy.sol | 2 +- contracts/src/v0.8/mocks/MockLinkToken.sol | 4 ++-- contracts/src/v0.8/mocks/VRFCoordinatorMock.sol | 2 +- .../src/v0.8/mocks/VRFCoordinatorV2Mock.sol | 2 +- .../v0.8/{ => shared/access}/ConfirmedOwner.sol | 0 .../access}/ConfirmedOwnerWithProposal.sol | 4 ++-- .../interfaces/IERC677Receiver.sol} | 2 +- .../v0.8/shared/interfaces/ITypeAndVersion.sol | 2 +- .../interfaces/LinkTokenInterface.sol | 0 .../src/v0.8/{ => shared/ocr2}/OCR2Abstract.sol | 4 ++-- contracts/src/v0.8/tests/Greeter.sol | 2 +- contracts/src/v0.8/tests/MercuryUpkeep.sol | 2 +- contracts/src/v0.8/utils/utils.sol | 14 -------------- .../src/v0.8/{ => vrf}/AuthorizedReceiver.sol | 0 contracts/src/v0.8/vrf/VRFConsumerBase.sol | 2 +- contracts/src/v0.8/vrf/VRFCoordinatorV2.sol | 14 ++++---------- contracts/src/v0.8/vrf/VRFOwner.sol | 4 ++-- contracts/src/v0.8/vrf/VRFV2Wrapper.sol | 4 ++-- .../src/v0.8/vrf/VRFV2WrapperConsumerBase.sol | 2 +- .../{ => vrf}/interfaces/IAuthorizedReceiver.sol | 0 .../src/v0.8/vrf/testhelpers/VRFConsumer.sol | 2 +- .../src/v0.8/vrf/testhelpers/VRFConsumerV2.sol | 2 +- .../VRFConsumerV2UpgradeableExample.sol | 2 +- .../testhelpers/VRFExternalSubOwnerExample.sol | 2 +- .../testhelpers/VRFLoadTestExternalSubOwner.sol | 4 ++-- .../testhelpers/VRFLoadTestOwnerlessConsumer.sol | 4 ++-- .../vrf/testhelpers/VRFMaliciousConsumerV2.sol | 2 +- .../testhelpers/VRFOwnerlessConsumerExample.sol | 4 ++-- .../vrf/testhelpers/VRFSingleConsumerExample.sol | 2 +- .../vrf/testhelpers/VRFV2LoadTestWithMetrics.sol | 2 +- .../vrf/testhelpers/VRFV2RevertingExample.sol | 2 +- .../testhelpers/VRFV2WrapperConsumerExample.sol | 2 +- .../VRFV2WrapperOutOfGasConsumerExample.sol | 2 +- .../VRFV2WrapperRevertingConsumerExample.sol | 2 +- .../VRFV2WrapperUnderFundingConsumer.sol | 4 ++-- contracts/test/v0.8/Cron.test.ts | 4 ++-- .../test/v0.8/automation/CronUpkeep.test.ts | 4 ++-- .../v0.8/automation/CronUpkeepFactory.test.ts | 4 ++-- .../foundry/transmission/EIP_712_1014_4337.t.sol | 2 +- .../contracts/ethereum/src/VRFv2Consumer.sol | 2 +- 120 files changed, 191 insertions(+), 226 deletions(-) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/1_2/AutomationRegistryInterface1_2.sol (100%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/1_2/KeeperRegistryInterface1_2.sol (100%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/1_3/AutomationRegistryInterface1_3.sol (100%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/2_0/AutomationRegistryInterface2_0.sol (100%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/AutomationCompatibleInterface.sol (100%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/KeeperCompatibleInterface.sol (100%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/MigratableKeeperRegistryInterface.sol (95%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/MigratableKeeperRegistryInterfaceV2.sol (95%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/UpkeepTranscoderInterface.sol (85%) rename contracts/src/v0.8/{interfaces/automation => automation/interfaces}/UpkeepTranscoderInterfaceV2.sol (100%) rename contracts/src/v0.8/{ => automation}/libraries/external/Cron.sol (100%) rename contracts/src/v0.8/{ => automation}/libraries/internal/Cron.sol (99%) rename contracts/src/v0.8/{tests => automation/testhelpers}/CronTestHelper.sol (100%) rename contracts/src/v0.8/{tests => automation/testhelpers}/CronUpkeepTestHelper.sol (96%) delete mode 100644 contracts/src/v0.8/interfaces/ITypeAndVersion.sol delete mode 100644 contracts/src/v0.8/interfaces/OwnableInterface.sol rename contracts/src/v0.8/{ => shared/access}/ConfirmedOwner.sol (100%) rename contracts/src/v0.8/{ => shared/access}/ConfirmedOwnerWithProposal.sol (94%) rename contracts/src/v0.8/{interfaces/ERC677ReceiverInterface.sol => shared/interfaces/IERC677Receiver.sol} (80%) rename contracts/src/v0.8/{ => shared}/interfaces/LinkTokenInterface.sol (100%) rename contracts/src/v0.8/{ => shared/ocr2}/OCR2Abstract.sol (97%) delete mode 100644 contracts/src/v0.8/utils/utils.sol rename contracts/src/v0.8/{ => vrf}/AuthorizedReceiver.sol (100%) rename contracts/src/v0.8/{ => vrf}/interfaces/IAuthorizedReceiver.sol (100%) diff --git a/contracts/src/v0.8/ChainlinkClient.sol b/contracts/src/v0.8/ChainlinkClient.sol index 00231ca5e97..fda69143f45 100644 --- a/contracts/src/v0.8/ChainlinkClient.sol +++ b/contracts/src/v0.8/ChainlinkClient.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.0; import "./Chainlink.sol"; import "./interfaces/ENSInterface.sol"; -import "./interfaces/LinkTokenInterface.sol"; +import "./shared/interfaces/LinkTokenInterface.sol"; import "./interfaces/ChainlinkRequestInterface.sol"; import "./interfaces/OperatorInterface.sol"; import "./interfaces/PointerInterface.sol"; diff --git a/contracts/src/v0.8/PermissionedForwardProxy.sol b/contracts/src/v0.8/PermissionedForwardProxy.sol index 9e3cf736636..6206bd5420c 100644 --- a/contracts/src/v0.8/PermissionedForwardProxy.sol +++ b/contracts/src/v0.8/PermissionedForwardProxy.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.6; import "@openzeppelin/contracts/utils/Address.sol"; -import "./ConfirmedOwner.sol"; +import "./shared/access/ConfirmedOwner.sol"; /** * @title PermissionedForwardProxy diff --git a/contracts/src/v0.8/SimpleWriteAccessController.sol b/contracts/src/v0.8/SimpleWriteAccessController.sol index 7c770bca3b2..75459173989 100644 --- a/contracts/src/v0.8/SimpleWriteAccessController.sol +++ b/contracts/src/v0.8/SimpleWriteAccessController.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "./ConfirmedOwner.sol"; +import "./shared/access/ConfirmedOwner.sol"; import "./interfaces/AccessControllerInterface.sol"; /** diff --git a/contracts/src/v0.8/ValidatorProxy.sol b/contracts/src/v0.8/ValidatorProxy.sol index ac83a162f05..ea81719270b 100644 --- a/contracts/src/v0.8/ValidatorProxy.sol +++ b/contracts/src/v0.8/ValidatorProxy.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "./ConfirmedOwner.sol"; +import "./shared/access/ConfirmedOwner.sol"; import "./interfaces/AggregatorValidatorInterface.sol"; import "./interfaces/TypeAndVersionInterface.sol"; diff --git a/contracts/src/v0.8/automation/1_2/KeeperRegistrar1_2.sol b/contracts/src/v0.8/automation/1_2/KeeperRegistrar1_2.sol index dd9f9206d0b..e3e10de131d 100644 --- a/contracts/src/v0.8/automation/1_2/KeeperRegistrar1_2.sol +++ b/contracts/src/v0.8/automation/1_2/KeeperRegistrar1_2.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.6; -import "../../interfaces/LinkTokenInterface.sol"; -import "../../interfaces/automation/1_2/KeeperRegistryInterface1_2.sol"; +import "../interfaces/1_2/KeeperRegistryInterface1_2.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; -import "../../ConfirmedOwner.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; /** * @notice Contract to accept requests for upkeep registrations @@ -17,7 +17,7 @@ import "../../interfaces/ERC677ReceiverInterface.sol"; * The idea is to have same interface(functions,events) for UI or anyone using this contract irrespective of auto approve being enabled or not. * they can just listen to `RegistrationRequested` & `RegistrationApproved` events and know the status on registrations. */ -contract KeeperRegistrar is TypeAndVersionInterface, ConfirmedOwner, ERC677ReceiverInterface { +contract KeeperRegistrar is TypeAndVersionInterface, ConfirmedOwner, IERC677Receiver { /** * DISABLED: No auto approvals, all new upkeeps should be approved manually. * ENABLED_SENDER_ALLOWLIST: Auto approvals for allowed senders subject to max allowed. Manual for rest. diff --git a/contracts/src/v0.8/automation/1_2/KeeperRegistry1_2.sol b/contracts/src/v0.8/automation/1_2/KeeperRegistry1_2.sol index ed86ffcc159..70bd176f82e 100644 --- a/contracts/src/v0.8/automation/1_2/KeeperRegistry1_2.sol +++ b/contracts/src/v0.8/automation/1_2/KeeperRegistry1_2.sol @@ -6,15 +6,15 @@ import "@openzeppelin/contracts/utils/Address.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "../KeeperBase.sol"; -import "../../ConfirmedOwner.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; import "../../interfaces/AggregatorV3Interface.sol"; -import "../../interfaces/LinkTokenInterface.sol"; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; -import "../../interfaces/automation/1_2/KeeperRegistryInterface1_2.sol"; -import "../../interfaces/automation/MigratableKeeperRegistryInterface.sol"; -import "../../interfaces/automation/UpkeepTranscoderInterface.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../interfaces/KeeperCompatibleInterface.sol"; +import "../interfaces/1_2/KeeperRegistryInterface1_2.sol"; +import "../interfaces/MigratableKeeperRegistryInterface.sol"; +import "../interfaces/UpkeepTranscoderInterface.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; struct Upkeep { uint96 balance; @@ -38,7 +38,7 @@ contract KeeperRegistry1_2 is Pausable, KeeperRegistryExecutableInterface, MigratableKeeperRegistryInterface, - ERC677ReceiverInterface + IERC677Receiver { using Address for address; using EnumerableSet for EnumerableSet.UintSet; diff --git a/contracts/src/v0.8/automation/1_2/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.sol b/contracts/src/v0.8/automation/1_2/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.sol index a2f84d3e063..dd6c83565bb 100644 --- a/contracts/src/v0.8/automation/1_2/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.sol +++ b/contracts/src/v0.8/automation/1_2/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.6; -import {AutomationRegistryExecutableInterface} from "../../interfaces/automation/1_2/AutomationRegistryInterface1_2.sol"; -import {ConfirmedOwner} from "../../ConfirmedOwner.sol"; +import {AutomationRegistryExecutableInterface} from "../interfaces/1_2/AutomationRegistryInterface1_2.sol"; +import {ConfirmedOwner} from "../../shared/access/ConfirmedOwner.sol"; /** * @notice This contract serves as a wrapper around a keeper registry's checkUpkeep function. diff --git a/contracts/src/v0.8/automation/1_3/KeeperRegistry1_3.sol b/contracts/src/v0.8/automation/1_3/KeeperRegistry1_3.sol index e97ad4adcb4..7f75ae87af2 100644 --- a/contracts/src/v0.8/automation/1_3/KeeperRegistry1_3.sol +++ b/contracts/src/v0.8/automation/1_3/KeeperRegistry1_3.sol @@ -6,10 +6,10 @@ import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "./KeeperRegistryBase1_3.sol"; import "./KeeperRegistryLogic1_3.sol"; -import {AutomationRegistryExecutableInterface} from "../../interfaces/automation/1_3/AutomationRegistryInterface1_3.sol"; -import "../../interfaces/automation/MigratableKeeperRegistryInterface.sol"; +import {AutomationRegistryExecutableInterface} from "../interfaces/1_3/AutomationRegistryInterface1_3.sol"; +import "../interfaces/MigratableKeeperRegistryInterface.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; /** * @notice Registry for adding work for Chainlink Keepers to perform on client @@ -21,7 +21,7 @@ contract KeeperRegistry1_3 is TypeAndVersionInterface, AutomationRegistryExecutableInterface, MigratableKeeperRegistryInterface, - ERC677ReceiverInterface + IERC677Receiver { using Address for address; using EnumerableSet for EnumerableSet.UintSet; diff --git a/contracts/src/v0.8/automation/1_3/KeeperRegistryBase1_3.sol b/contracts/src/v0.8/automation/1_3/KeeperRegistryBase1_3.sol index f3ba3ea24be..2f5156ee081 100644 --- a/contracts/src/v0.8/automation/1_3/KeeperRegistryBase1_3.sol +++ b/contracts/src/v0.8/automation/1_3/KeeperRegistryBase1_3.sol @@ -6,12 +6,12 @@ import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol"; import "../../vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol"; import "../ExecutionPrevention.sol"; -import {Config, State, Upkeep} from "../../interfaces/automation/1_3/AutomationRegistryInterface1_3.sol"; -import "../../ConfirmedOwner.sol"; +import {Config, State, Upkeep} from "../interfaces/1_3/AutomationRegistryInterface1_3.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "../../interfaces/AggregatorV3Interface.sol"; -import "../../interfaces/LinkTokenInterface.sol"; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; -import "../../interfaces/automation/UpkeepTranscoderInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; +import "../interfaces/KeeperCompatibleInterface.sol"; +import "../interfaces/UpkeepTranscoderInterface.sol"; /** * @notice Base Keeper Registry contract, contains shared logic between diff --git a/contracts/src/v0.8/automation/1_3/KeeperRegistryLogic1_3.sol b/contracts/src/v0.8/automation/1_3/KeeperRegistryLogic1_3.sol index 2a9cd08302a..fd7c3afdc1c 100644 --- a/contracts/src/v0.8/automation/1_3/KeeperRegistryLogic1_3.sol +++ b/contracts/src/v0.8/automation/1_3/KeeperRegistryLogic1_3.sol @@ -4,8 +4,8 @@ pragma solidity 0.8.6; import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import "@openzeppelin/contracts/utils/Address.sol"; import "./KeeperRegistryBase1_3.sol"; -import "../../interfaces/automation/MigratableKeeperRegistryInterface.sol"; -import "../../interfaces/automation/UpkeepTranscoderInterface.sol"; +import "../interfaces/MigratableKeeperRegistryInterface.sol"; +import "../interfaces/UpkeepTranscoderInterface.sol"; /** * @notice Logic contract, works in tandem with KeeperRegistry as a proxy diff --git a/contracts/src/v0.8/automation/2_0/KeeperRegistrar2_0.sol b/contracts/src/v0.8/automation/2_0/KeeperRegistrar2_0.sol index 0b449184ac5..15cba57e7bb 100644 --- a/contracts/src/v0.8/automation/2_0/KeeperRegistrar2_0.sol +++ b/contracts/src/v0.8/automation/2_0/KeeperRegistrar2_0.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.6; -import "../../interfaces/LinkTokenInterface.sol"; -import "../../interfaces/automation/2_0/AutomationRegistryInterface2_0.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; +import "../interfaces/2_0/AutomationRegistryInterface2_0.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; -import "../../ConfirmedOwner.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; /** * @notice Contract to accept requests for upkeep registrations @@ -17,7 +17,7 @@ import "../../interfaces/ERC677ReceiverInterface.sol"; * The idea is to have same interface(functions,events) for UI or anyone using this contract irrespective of auto approve being enabled or not. * they can just listen to `RegistrationRequested` & `RegistrationApproved` events and know the status on registrations. */ -contract KeeperRegistrar2_0 is TypeAndVersionInterface, ConfirmedOwner, ERC677ReceiverInterface { +contract KeeperRegistrar2_0 is TypeAndVersionInterface, ConfirmedOwner, IERC677Receiver { /** * DISABLED: No auto approvals, all new upkeeps should be approved manually. * ENABLED_SENDER_ALLOWLIST: Auto approvals for allowed senders subject to max allowed. Manual for rest. diff --git a/contracts/src/v0.8/automation/2_0/KeeperRegistry2_0.sol b/contracts/src/v0.8/automation/2_0/KeeperRegistry2_0.sol index 477e19b9b3c..bc928bd4292 100644 --- a/contracts/src/v0.8/automation/2_0/KeeperRegistry2_0.sol +++ b/contracts/src/v0.8/automation/2_0/KeeperRegistry2_0.sol @@ -5,11 +5,11 @@ import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/proxy/Proxy.sol"; import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; import "./KeeperRegistryBase2_0.sol"; -import {AutomationRegistryExecutableInterface, UpkeepInfo} from "../../interfaces/automation/2_0/AutomationRegistryInterface2_0.sol"; -import "../../interfaces/automation/MigratableKeeperRegistryInterface.sol"; -import "../../interfaces/automation/MigratableKeeperRegistryInterfaceV2.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; -import "../../OCR2Abstract.sol"; +import {AutomationRegistryExecutableInterface, UpkeepInfo} from "../interfaces/2_0/AutomationRegistryInterface2_0.sol"; +import "../interfaces/MigratableKeeperRegistryInterface.sol"; +import "../interfaces/MigratableKeeperRegistryInterfaceV2.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; +import {OCR2Abstract} from "../../shared/ocr2/OCR2Abstract.sol"; /** _. _|_ _ ._ _ _._|_o _ ._ o _ _ ._ _| _ __|_o._ @@ -27,7 +27,7 @@ contract KeeperRegistry2_0 is AutomationRegistryExecutableInterface, MigratableKeeperRegistryInterface, MigratableKeeperRegistryInterfaceV2, - ERC677ReceiverInterface + IERC677Receiver { using Address for address; using EnumerableSet for EnumerableSet.UintSet; diff --git a/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol b/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol index cda4ad0b0be..74a13d71100 100644 --- a/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol +++ b/contracts/src/v0.8/automation/2_0/KeeperRegistryBase2_0.sol @@ -6,12 +6,12 @@ import "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbGasInfo.sol"; import "../../vendor/@eth-optimism/contracts/0.8.6/contracts/L2/predeploys/OVM_GasPriceOracle.sol"; import {ArbSys} from "../../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; import "../ExecutionPrevention.sol"; -import {OnchainConfig, State, UpkeepFailureReason} from "../../interfaces/automation/2_0/AutomationRegistryInterface2_0.sol"; -import "../../ConfirmedOwner.sol"; +import {OnchainConfig, State, UpkeepFailureReason} from "../interfaces/2_0/AutomationRegistryInterface2_0.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "../../interfaces/AggregatorV3Interface.sol"; -import "../../interfaces/LinkTokenInterface.sol"; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; -import "../../interfaces/automation/UpkeepTranscoderInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; +import "../interfaces/KeeperCompatibleInterface.sol"; +import "../interfaces/UpkeepTranscoderInterface.sol"; /** * @notice relevant state of an upkeep which is used in transmit function diff --git a/contracts/src/v0.8/automation/2_0/KeeperRegistryLogic2_0.sol b/contracts/src/v0.8/automation/2_0/KeeperRegistryLogic2_0.sol index 2787fca87c1..7e6134a178f 100644 --- a/contracts/src/v0.8/automation/2_0/KeeperRegistryLogic2_0.sol +++ b/contracts/src/v0.8/automation/2_0/KeeperRegistryLogic2_0.sol @@ -4,8 +4,8 @@ pragma solidity 0.8.6; import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/Address.sol"; import "./KeeperRegistryBase2_0.sol"; -import "../../interfaces/automation/MigratableKeeperRegistryInterfaceV2.sol"; -import "../../interfaces/automation/UpkeepTranscoderInterfaceV2.sol"; +import "../interfaces/MigratableKeeperRegistryInterfaceV2.sol"; +import "../interfaces/UpkeepTranscoderInterfaceV2.sol"; /** * @notice Logic contract, works in tandem with KeeperRegistry as a proxy diff --git a/contracts/src/v0.8/automation/AutomationCompatible.sol b/contracts/src/v0.8/automation/AutomationCompatible.sol index b0abd44b05f..5634956ea70 100644 --- a/contracts/src/v0.8/automation/AutomationCompatible.sol +++ b/contracts/src/v0.8/automation/AutomationCompatible.sol @@ -2,6 +2,6 @@ pragma solidity ^0.8.0; import "./AutomationBase.sol"; -import "../interfaces/automation/AutomationCompatibleInterface.sol"; +import "./interfaces/AutomationCompatibleInterface.sol"; abstract contract AutomationCompatible is AutomationBase, AutomationCompatibleInterface {} diff --git a/contracts/src/v0.8/automation/HeartbeatRequester.sol b/contracts/src/v0.8/automation/HeartbeatRequester.sol index def7a67bbd0..d5802a79580 100644 --- a/contracts/src/v0.8/automation/HeartbeatRequester.sol +++ b/contracts/src/v0.8/automation/HeartbeatRequester.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.6; import "./../interfaces/TypeAndVersionInterface.sol"; -import "./../ConfirmedOwner.sol"; +import "../shared/access/ConfirmedOwner.sol"; // defines some interfaces for type safety and reduces encoding/decoding // does not use the full interfaces intentionally because the requester only uses a fraction of them diff --git a/contracts/src/v0.8/automation/KeeperCompatible.sol b/contracts/src/v0.8/automation/KeeperCompatible.sol index b3cf2820ecc..f5263eda7b9 100644 --- a/contracts/src/v0.8/automation/KeeperCompatible.sol +++ b/contracts/src/v0.8/automation/KeeperCompatible.sol @@ -5,4 +5,4 @@ pragma solidity ^0.8.0; import {AutomationCompatible as KeeperCompatible} from "./AutomationCompatible.sol"; import {AutomationBase as KeeperBase} from "./AutomationBase.sol"; -import {AutomationCompatibleInterface as KeeperCompatibleInterface} from "../interfaces/automation/AutomationCompatibleInterface.sol"; +import {AutomationCompatibleInterface as KeeperCompatibleInterface} from "./interfaces/AutomationCompatibleInterface.sol"; diff --git a/contracts/src/v0.8/automation/UpkeepTranscoder.sol b/contracts/src/v0.8/automation/UpkeepTranscoder.sol index 5271c520758..450da8c14a1 100644 --- a/contracts/src/v0.8/automation/UpkeepTranscoder.sol +++ b/contracts/src/v0.8/automation/UpkeepTranscoder.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.0; -import "../interfaces/automation/UpkeepTranscoderInterface.sol"; +import "./interfaces/UpkeepTranscoderInterface.sol"; import "../interfaces/TypeAndVersionInterface.sol"; /** diff --git a/contracts/src/v0.8/interfaces/automation/1_2/AutomationRegistryInterface1_2.sol b/contracts/src/v0.8/automation/interfaces/1_2/AutomationRegistryInterface1_2.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/1_2/AutomationRegistryInterface1_2.sol rename to contracts/src/v0.8/automation/interfaces/1_2/AutomationRegistryInterface1_2.sol diff --git a/contracts/src/v0.8/interfaces/automation/1_2/KeeperRegistryInterface1_2.sol b/contracts/src/v0.8/automation/interfaces/1_2/KeeperRegistryInterface1_2.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/1_2/KeeperRegistryInterface1_2.sol rename to contracts/src/v0.8/automation/interfaces/1_2/KeeperRegistryInterface1_2.sol diff --git a/contracts/src/v0.8/interfaces/automation/1_3/AutomationRegistryInterface1_3.sol b/contracts/src/v0.8/automation/interfaces/1_3/AutomationRegistryInterface1_3.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/1_3/AutomationRegistryInterface1_3.sol rename to contracts/src/v0.8/automation/interfaces/1_3/AutomationRegistryInterface1_3.sol diff --git a/contracts/src/v0.8/interfaces/automation/2_0/AutomationRegistryInterface2_0.sol b/contracts/src/v0.8/automation/interfaces/2_0/AutomationRegistryInterface2_0.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/2_0/AutomationRegistryInterface2_0.sol rename to contracts/src/v0.8/automation/interfaces/2_0/AutomationRegistryInterface2_0.sol diff --git a/contracts/src/v0.8/interfaces/automation/AutomationCompatibleInterface.sol b/contracts/src/v0.8/automation/interfaces/AutomationCompatibleInterface.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/AutomationCompatibleInterface.sol rename to contracts/src/v0.8/automation/interfaces/AutomationCompatibleInterface.sol diff --git a/contracts/src/v0.8/interfaces/automation/KeeperCompatibleInterface.sol b/contracts/src/v0.8/automation/interfaces/KeeperCompatibleInterface.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/KeeperCompatibleInterface.sol rename to contracts/src/v0.8/automation/interfaces/KeeperCompatibleInterface.sol diff --git a/contracts/src/v0.8/interfaces/automation/MigratableKeeperRegistryInterface.sol b/contracts/src/v0.8/automation/interfaces/MigratableKeeperRegistryInterface.sol similarity index 95% rename from contracts/src/v0.8/interfaces/automation/MigratableKeeperRegistryInterface.sol rename to contracts/src/v0.8/automation/interfaces/MigratableKeeperRegistryInterface.sol index b9a47269061..d279d93984e 100644 --- a/contracts/src/v0.8/interfaces/automation/MigratableKeeperRegistryInterface.sol +++ b/contracts/src/v0.8/automation/interfaces/MigratableKeeperRegistryInterface.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.0; -import "../../automation/UpkeepFormat.sol"; +import "../UpkeepFormat.sol"; interface MigratableKeeperRegistryInterface { /** diff --git a/contracts/src/v0.8/interfaces/automation/MigratableKeeperRegistryInterfaceV2.sol b/contracts/src/v0.8/automation/interfaces/MigratableKeeperRegistryInterfaceV2.sol similarity index 95% rename from contracts/src/v0.8/interfaces/automation/MigratableKeeperRegistryInterfaceV2.sol rename to contracts/src/v0.8/automation/interfaces/MigratableKeeperRegistryInterfaceV2.sol index d13ee4c1670..17ca3673dc2 100644 --- a/contracts/src/v0.8/interfaces/automation/MigratableKeeperRegistryInterfaceV2.sol +++ b/contracts/src/v0.8/automation/interfaces/MigratableKeeperRegistryInterfaceV2.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.0; -import "../../automation/UpkeepFormat.sol"; +import "../UpkeepFormat.sol"; interface MigratableKeeperRegistryInterfaceV2 { /** diff --git a/contracts/src/v0.8/interfaces/automation/UpkeepTranscoderInterface.sol b/contracts/src/v0.8/automation/interfaces/UpkeepTranscoderInterface.sol similarity index 85% rename from contracts/src/v0.8/interfaces/automation/UpkeepTranscoderInterface.sol rename to contracts/src/v0.8/automation/interfaces/UpkeepTranscoderInterface.sol index 555a1600294..aa0c3c6a7f0 100644 --- a/contracts/src/v0.8/interfaces/automation/UpkeepTranscoderInterface.sol +++ b/contracts/src/v0.8/automation/interfaces/UpkeepTranscoderInterface.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: MIT -import "../../automation/UpkeepFormat.sol"; +import "../UpkeepFormat.sol"; pragma solidity ^0.8.0; diff --git a/contracts/src/v0.8/interfaces/automation/UpkeepTranscoderInterfaceV2.sol b/contracts/src/v0.8/automation/interfaces/UpkeepTranscoderInterfaceV2.sol similarity index 100% rename from contracts/src/v0.8/interfaces/automation/UpkeepTranscoderInterfaceV2.sol rename to contracts/src/v0.8/automation/interfaces/UpkeepTranscoderInterfaceV2.sol diff --git a/contracts/src/v0.8/libraries/external/Cron.sol b/contracts/src/v0.8/automation/libraries/external/Cron.sol similarity index 100% rename from contracts/src/v0.8/libraries/external/Cron.sol rename to contracts/src/v0.8/automation/libraries/external/Cron.sol diff --git a/contracts/src/v0.8/libraries/internal/Cron.sol b/contracts/src/v0.8/automation/libraries/internal/Cron.sol similarity index 99% rename from contracts/src/v0.8/libraries/internal/Cron.sol rename to contracts/src/v0.8/automation/libraries/internal/Cron.sol index 2cc50945b0d..fe72c412b60 100644 --- a/contracts/src/v0.8/libraries/internal/Cron.sol +++ b/contracts/src/v0.8/automation/libraries/internal/Cron.sol @@ -33,8 +33,8 @@ pragma solidity 0.8.6; -import "../../vendor/Strings.sol"; -import "../../vendor/DateTime.sol"; +import "../../../vendor/Strings.sol"; +import "../../../vendor/DateTime.sol"; // The fields of a cron spec, by name string constant MINUTE = "minute"; diff --git a/contracts/src/v0.8/tests/CronTestHelper.sol b/contracts/src/v0.8/automation/testhelpers/CronTestHelper.sol similarity index 100% rename from contracts/src/v0.8/tests/CronTestHelper.sol rename to contracts/src/v0.8/automation/testhelpers/CronTestHelper.sol diff --git a/contracts/src/v0.8/tests/CronUpkeepTestHelper.sol b/contracts/src/v0.8/automation/testhelpers/CronUpkeepTestHelper.sol similarity index 96% rename from contracts/src/v0.8/tests/CronUpkeepTestHelper.sol rename to contracts/src/v0.8/automation/testhelpers/CronUpkeepTestHelper.sol index 4f6a6419620..8ede4ea3933 100644 --- a/contracts/src/v0.8/tests/CronUpkeepTestHelper.sol +++ b/contracts/src/v0.8/automation/testhelpers/CronUpkeepTestHelper.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.6; -import "../automation/upkeeps/CronUpkeep.sol"; +import "../upkeeps/CronUpkeep.sol"; import {Cron, Spec} from "../libraries/internal/Cron.sol"; /** diff --git a/contracts/src/v0.8/automation/upkeeps/CronUpkeep.sol b/contracts/src/v0.8/automation/upkeeps/CronUpkeep.sol index 5ae7d2f8aee..614b84635ab 100644 --- a/contracts/src/v0.8/automation/upkeeps/CronUpkeep.sol +++ b/contracts/src/v0.8/automation/upkeeps/CronUpkeep.sol @@ -21,11 +21,11 @@ pragma solidity 0.8.6; import "@openzeppelin/contracts/security/Pausable.sol"; import "@openzeppelin/contracts/proxy/Proxy.sol"; import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "../KeeperBase.sol"; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; -import {Cron as CronInternal, Spec} from "../../libraries/internal/Cron.sol"; -import {Cron as CronExternal} from "../../libraries/external/Cron.sol"; +import "../interfaces/KeeperCompatibleInterface.sol"; +import {Cron as CronInternal, Spec} from "../libraries/internal/Cron.sol"; +import {Cron as CronExternal} from "../libraries/external/Cron.sol"; /** * @title The CronUpkeep contract diff --git a/contracts/src/v0.8/automation/upkeeps/CronUpkeepDelegate.sol b/contracts/src/v0.8/automation/upkeeps/CronUpkeepDelegate.sol index 9a446b6715e..ec2c2a0fd91 100644 --- a/contracts/src/v0.8/automation/upkeeps/CronUpkeepDelegate.sol +++ b/contracts/src/v0.8/automation/upkeeps/CronUpkeepDelegate.sol @@ -3,7 +3,7 @@ pragma solidity 0.8.6; import "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; -import {Cron, Spec} from "../../libraries/internal/Cron.sol"; +import {Cron, Spec} from "../libraries/internal/Cron.sol"; /** * @title The CronUpkeepDelegate contract diff --git a/contracts/src/v0.8/automation/upkeeps/CronUpkeepFactory.sol b/contracts/src/v0.8/automation/upkeeps/CronUpkeepFactory.sol index f88945e9c91..cd9ae5d7a92 100644 --- a/contracts/src/v0.8/automation/upkeeps/CronUpkeepFactory.sol +++ b/contracts/src/v0.8/automation/upkeeps/CronUpkeepFactory.sol @@ -4,8 +4,8 @@ pragma solidity 0.8.6; import "./CronUpkeep.sol"; import "./CronUpkeepDelegate.sol"; -import "../../ConfirmedOwner.sol"; -import {Spec, Cron as CronExternal} from "../../libraries/external/Cron.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import {Spec, Cron as CronExternal} from "../libraries/external/Cron.sol"; /** * @title The CronUpkeepFactory contract diff --git a/contracts/src/v0.8/automation/upkeeps/ERC20BalanceMonitor.sol b/contracts/src/v0.8/automation/upkeeps/ERC20BalanceMonitor.sol index 3f16d6a1200..69f36f92cc6 100644 --- a/contracts/src/v0.8/automation/upkeeps/ERC20BalanceMonitor.sol +++ b/contracts/src/v0.8/automation/upkeeps/ERC20BalanceMonitor.sol @@ -2,8 +2,8 @@ pragma solidity ^0.8.4; -import "../../ConfirmedOwner.sol"; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "../interfaces/KeeperCompatibleInterface.sol"; import "../../vendor/openzeppelin-solidity/v4.7.0/contracts/security/Pausable.sol"; import "../../vendor/openzeppelin-solidity/v4.7.0/contracts/token/ERC20/utils/SafeERC20.sol"; diff --git a/contracts/src/v0.8/automation/upkeeps/EthBalanceMonitor.sol b/contracts/src/v0.8/automation/upkeeps/EthBalanceMonitor.sol index fc4107a0ac6..c7d8a306e58 100644 --- a/contracts/src/v0.8/automation/upkeeps/EthBalanceMonitor.sol +++ b/contracts/src/v0.8/automation/upkeeps/EthBalanceMonitor.sol @@ -2,8 +2,8 @@ pragma solidity 0.8.6; -import "../../ConfirmedOwner.sol"; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "../interfaces/KeeperCompatibleInterface.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; /** diff --git a/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol b/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol index cb8ab9f0976..0191bbd88a3 100644 --- a/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol +++ b/contracts/src/v0.8/dev/ArbitrumSequencerUptimeFeed.sol @@ -10,7 +10,7 @@ import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol import {FlagsInterface} from "./interfaces/FlagsInterface.sol"; import {ArbitrumSequencerUptimeFeedInterface} from "./interfaces/ArbitrumSequencerUptimeFeedInterface.sol"; import {SimpleReadAccessController} from "../SimpleReadAccessController.sol"; -import {ConfirmedOwner} from "../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../shared/access/ConfirmedOwner.sol"; /** * @title ArbitrumSequencerUptimeFeed - L2 sequencer uptime status aggregator diff --git a/contracts/src/v0.8/dev/CrossDomainOwnable.sol b/contracts/src/v0.8/dev/CrossDomainOwnable.sol index cd5f309dff2..7a055ddad9e 100644 --- a/contracts/src/v0.8/dev/CrossDomainOwnable.sol +++ b/contracts/src/v0.8/dev/CrossDomainOwnable.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../ConfirmedOwner.sol"; +import "../shared/access/ConfirmedOwner.sol"; import "./interfaces/CrossDomainOwnableInterface.sol"; /** diff --git a/contracts/src/v0.8/dev/OptimismSequencerUptimeFeed.sol b/contracts/src/v0.8/dev/OptimismSequencerUptimeFeed.sol index f51d29b42e3..86215f87237 100644 --- a/contracts/src/v0.8/dev/OptimismSequencerUptimeFeed.sol +++ b/contracts/src/v0.8/dev/OptimismSequencerUptimeFeed.sol @@ -7,7 +7,7 @@ import {AggregatorV2V3Interface} from "../interfaces/AggregatorV2V3Interface.sol import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; import {OptimismSequencerUptimeFeedInterface} from "./interfaces/OptimismSequencerUptimeFeedInterface.sol"; import {SimpleReadAccessController} from "../SimpleReadAccessController.sol"; -import {ConfirmedOwner} from "../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../shared/access/ConfirmedOwner.sol"; import {IL2CrossDomainMessenger} from "@eth-optimism/contracts/L2/messaging/IL2CrossDomainMessenger.sol"; /** diff --git a/contracts/src/v0.8/dev/VRFSubscriptionBalanceMonitor.sol b/contracts/src/v0.8/dev/VRFSubscriptionBalanceMonitor.sol index bd04de6a4b6..91124709742 100644 --- a/contracts/src/v0.8/dev/VRFSubscriptionBalanceMonitor.sol +++ b/contracts/src/v0.8/dev/VRFSubscriptionBalanceMonitor.sol @@ -2,10 +2,10 @@ pragma solidity 0.8.6; -import "../ConfirmedOwner.sol"; -import "../interfaces/automation/KeeperCompatibleInterface.sol"; +import "../shared/access/ConfirmedOwner.sol"; +import "../automation/interfaces/KeeperCompatibleInterface.sol"; import "../interfaces/VRFCoordinatorV2Interface.sol"; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "@openzeppelin/contracts/security/Pausable.sol"; /** diff --git a/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol b/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol index 655c6131fd3..0a5535ce061 100644 --- a/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol +++ b/contracts/src/v0.8/dev/automation/2_1/AutomationForwarderLogic.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.16; import {IAutomationRegistryConsumer} from "./interfaces/IAutomationRegistryConsumer.sol"; -import "../../../interfaces/ITypeAndVersion.sol"; +import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; contract AutomationForwarderLogic is ITypeAndVersion { IAutomationRegistryConsumer private s_registry; diff --git a/contracts/src/v0.8/dev/automation/2_1/AutomationRegistrar2_1.sol b/contracts/src/v0.8/dev/automation/2_1/AutomationRegistrar2_1.sol index c37a1b1d079..0f60426cfa2 100644 --- a/contracts/src/v0.8/dev/automation/2_1/AutomationRegistrar2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/AutomationRegistrar2_1.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.16; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "./interfaces/IKeeperRegistryMaster.sol"; import "../../../interfaces/TypeAndVersionInterface.sol"; -import "../../../ConfirmedOwner.sol"; -import "../../../interfaces/ERC677ReceiverInterface.sol"; +import "../../../shared/access/ConfirmedOwner.sol"; +import "../../../shared/interfaces/IERC677Receiver.sol"; /** * @notice Contract to accept requests for upkeep registrations @@ -17,7 +17,7 @@ import "../../../interfaces/ERC677ReceiverInterface.sol"; * The idea is to have same interface(functions,events) for UI or anyone using this contract irrespective of auto approve being enabled or not. * they can just listen to `RegistrationRequested` & `RegistrationApproved` events and know the status on registrations. */ -contract AutomationRegistrar2_1 is TypeAndVersionInterface, ConfirmedOwner, ERC677ReceiverInterface { +contract AutomationRegistrar2_1 is TypeAndVersionInterface, ConfirmedOwner, IERC677Receiver { /** * DISABLED: No auto approvals, all new upkeeps should be approved manually. * ENABLED_SENDER_ALLOWLIST: Auto approvals for allowed senders subject to max allowed. Manual for rest. diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol index 1f18dc3914d..f03cd734d65 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol @@ -5,14 +5,14 @@ import "../../../vendor/openzeppelin-solidity/v4.7.3/contracts/proxy/Proxy.sol"; import "./KeeperRegistryBase2_1.sol"; import "./KeeperRegistryLogicB2_1.sol"; import "./Chainable.sol"; -import "../../../interfaces/ERC677ReceiverInterface.sol"; -import "../../../OCR2Abstract.sol"; +import "../../../shared/interfaces/IERC677Receiver.sol"; +import "../../../shared/ocr2/OCR2Abstract.sol"; /** * @notice Registry for adding work for Chainlink Keepers to perform on client * contracts. Clients must support the Upkeep interface. */ -contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, ERC677ReceiverInterface { +contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, IERC677Receiver { using Address for address; using EnumerableSet for EnumerableSet.UintSet; using EnumerableSet for EnumerableSet.AddressSet; diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index 3d4251e7d5f..03c0422edec 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -10,11 +10,11 @@ import {ArbSys} from "../../../vendor/@arbitrum/nitro-contracts/src/precompiles/ import "./interfaces/FeedLookupCompatibleInterface.sol"; import "./interfaces/ILogAutomation.sol"; import {IAutomationForwarder} from "./interfaces/IAutomationForwarder.sol"; -import "../../../ConfirmedOwner.sol"; +import "../../../shared/access/ConfirmedOwner.sol"; import "../../../interfaces/AggregatorV3Interface.sol"; -import "../../../interfaces/LinkTokenInterface.sol"; -import "../../../interfaces/automation/KeeperCompatibleInterface.sol"; -import "../../../interfaces/automation/UpkeepTranscoderInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; +import "../../../automation/interfaces/KeeperCompatibleInterface.sol"; +import "../../../automation/interfaces/UpkeepTranscoderInterface.sol"; /** * @notice Base Keeper Registry contract, contains shared logic between diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol index e4c38fa951c..1535b62f12f 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol @@ -5,8 +5,8 @@ import "./KeeperRegistryBase2_1.sol"; import "./KeeperRegistryLogicB2_1.sol"; import "./Chainable.sol"; import {AutomationForwarder} from "./AutomationForwarder.sol"; -import "../../../interfaces/automation/UpkeepTranscoderInterfaceV2.sol"; -import "../../../interfaces/automation/MigratableKeeperRegistryInterfaceV2.sol"; +import "../../../automation/interfaces/UpkeepTranscoderInterfaceV2.sol"; +import "../../../automation/interfaces/MigratableKeeperRegistryInterfaceV2.sol"; /** * @notice Logic contract, works in tandem with KeeperRegistry as a proxy diff --git a/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol b/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol index e8bd6c3e1c2..43979bd05bf 100644 --- a/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol +++ b/contracts/src/v0.8/dev/automation/2_1/UpkeepTranscoder4_0.sol @@ -2,11 +2,11 @@ pragma solidity 0.8.16; -import "../../../interfaces/automation/UpkeepTranscoderInterfaceV2.sol"; +import "../../../automation/interfaces/UpkeepTranscoderInterfaceV2.sol"; import "../../../interfaces/TypeAndVersionInterface.sol"; import {KeeperRegistryBase2_1 as R21} from "./KeeperRegistryBase2_1.sol"; import {IAutomationForwarder} from "./interfaces/IAutomationForwarder.sol"; -import {AutomationRegistryBaseInterface, UpkeepInfo} from "../../../interfaces/automation/2_0/AutomationRegistryInterface2_0.sol"; +import {AutomationRegistryBaseInterface, UpkeepInfo} from "../../../automation/interfaces/2_0/AutomationRegistryInterface2_0.sol"; enum RegistryVersion { V12, diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol index d7ae7f573a0..fbf9743d0ca 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IAutomationForwarder.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../../../interfaces/ITypeAndVersion.sol"; +import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol"; import {IAutomationRegistryConsumer} from "./IAutomationRegistryConsumer.sol"; interface IAutomationForwarder is ITypeAndVersion { diff --git a/contracts/src/v0.8/dev/automation/CanaryUpkeep1_2.sol b/contracts/src/v0.8/dev/automation/CanaryUpkeep1_2.sol index 6e24fa9e2ca..bf711eb565f 100644 --- a/contracts/src/v0.8/dev/automation/CanaryUpkeep1_2.sol +++ b/contracts/src/v0.8/dev/automation/CanaryUpkeep1_2.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.6; -import "../../interfaces/automation/KeeperCompatibleInterface.sol"; -import "../../interfaces/automation/1_2/KeeperRegistryInterface1_2.sol"; -import "../../ConfirmedOwner.sol"; +import "../../automation/interfaces/KeeperCompatibleInterface.sol"; +import "../../automation/interfaces/1_2/KeeperRegistryInterface1_2.sol"; +import "../../shared/access/ConfirmedOwner.sol"; error NoKeeperNodes(); error InsufficientInterval(); diff --git a/contracts/src/v0.8/dev/automation/UpkeepTranscoder3_0.sol b/contracts/src/v0.8/dev/automation/UpkeepTranscoder3_0.sol index 0cb54ce09bd..618f97db8fd 100644 --- a/contracts/src/v0.8/dev/automation/UpkeepTranscoder3_0.sol +++ b/contracts/src/v0.8/dev/automation/UpkeepTranscoder3_0.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.6; -import "../../interfaces/automation/UpkeepTranscoderInterface.sol"; +import "../../automation/interfaces/UpkeepTranscoderInterface.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; import {Upkeep as UpkeepV1} from "../../automation/1_2/KeeperRegistry1_2.sol"; import {Upkeep as UpkeepV2} from "../../automation/1_3/KeeperRegistryBase1_3.sol"; diff --git a/contracts/src/v0.8/dev/automation/upkeeps/LinkAvailableBalanceMonitor.sol b/contracts/src/v0.8/dev/automation/upkeeps/LinkAvailableBalanceMonitor.sol index 45e5e971f6a..1ed1237f615 100644 --- a/contracts/src/v0.8/dev/automation/upkeeps/LinkAvailableBalanceMonitor.sol +++ b/contracts/src/v0.8/dev/automation/upkeeps/LinkAvailableBalanceMonitor.sol @@ -2,8 +2,8 @@ pragma solidity 0.8.6; -import "../../../ConfirmedOwner.sol"; -import "../../../interfaces/automation/KeeperCompatibleInterface.sol"; +import "../../../shared/access/ConfirmedOwner.sol"; +import "../../../automation/interfaces/KeeperCompatibleInterface.sol"; import "../../../vendor/openzeppelin-solidity/v4.7.0/contracts/security/Pausable.sol"; import "../../../vendor/openzeppelin-solidity/v4.7.0/contracts/token/ERC20/IERC20.sol"; import "../../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableMap.sol"; diff --git a/contracts/src/v0.8/dev/ocr2/OCR2Base.sol b/contracts/src/v0.8/dev/ocr2/OCR2Base.sol index 17bb2bfe84e..5e50d99f213 100644 --- a/contracts/src/v0.8/dev/ocr2/OCR2Base.sol +++ b/contracts/src/v0.8/dev/ocr2/OCR2Base.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "./OCR2Abstract.sol"; /** diff --git a/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol b/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol index a61b4cfbee2..52d50d2e2c7 100644 --- a/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol +++ b/contracts/src/v0.8/dev/transmission/4337/Paymaster.sol @@ -4,10 +4,10 @@ pragma solidity ^0.8.15; import "../../../vendor/entrypoint/interfaces/IPaymaster.sol"; import "./SCALibrary.sol"; import "../../../vendor/entrypoint/core/Helpers.sol"; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../../interfaces/AggregatorV3Interface.sol"; import "./SCALibrary.sol"; -import "../../../ConfirmedOwner.sol"; +import "../../../shared/access/ConfirmedOwner.sol"; /// @dev LINK token paymaster implementation. /// TODO: more documentation. diff --git a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol index dae882f6723..82711bb403f 100644 --- a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol +++ b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol @@ -1,14 +1,14 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "../../interfaces/AggregatorV3Interface.sol"; import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; import "../interfaces/IVRFSubscriptionV2Plus.sol"; -abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, ERC677ReceiverInterface, IVRFSubscriptionV2Plus { +abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, IERC677Receiver, IVRFSubscriptionV2Plus { /// @dev may not be provided upon construction on some chains due to lack of availability LinkTokenInterface public LINK; /// @dev may not be provided upon construction on some chains due to lack of availability diff --git a/contracts/src/v0.8/dev/vrf/VRFConsumerBaseV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFConsumerBaseV2Plus.sol index 2909312e548..ed1f918212c 100644 --- a/contracts/src/v0.8/dev/vrf/VRFConsumerBaseV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFConsumerBaseV2Plus.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.4; import "../interfaces/IVRFMigratableCoordinatorV2Plus.sol"; import "../interfaces/IVRFMigratableConsumerV2Plus.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; /** **************************************************************************** * @notice Interface for contracts using VRF randomness diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 92b403df34f..5a0d5825f6f 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.4; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/BlockhashStoreInterface.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; import "../../vrf/VRF.sol"; diff --git a/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapper.sol b/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapper.sol index b2453ec05e5..c8cba34ec5a 100644 --- a/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapper.sol +++ b/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapper.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "../../interfaces/TypeAndVersionInterface.sol"; import "./VRFConsumerBaseV2Plus.sol"; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/AggregatorV3Interface.sol"; import "../interfaces/IVRFCoordinatorV2Plus.sol"; import "../interfaces/VRFV2PlusWrapperInterface.sol"; diff --git a/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapperConsumerBase.sol b/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapperConsumerBase.sol index 47c86dadc71..c9ddad2f778 100644 --- a/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapperConsumerBase.sol +++ b/contracts/src/v0.8/dev/vrf/VRFV2PlusWrapperConsumerBase.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../interfaces/VRFV2PlusWrapperInterface.sol"; /** diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol index 77e290ca80c..7b34f96e376 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../../VRFConsumerBaseV2Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable-4.7.3/proxy/utils/Initializable.sol"; diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol index c8029eb575f..b44a3e3190d 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.4; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2PlusMigration.sol"; import "../../interfaces/IVRFMigratableCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFMaliciousConsumerV2Plus.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFMaliciousConsumerV2Plus.sol index 93f8186f168..11e899ae659 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFMaliciousConsumerV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFMaliciousConsumerV2Plus.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol index 598375420fd..ff9245b688e 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; -import "../../../ConfirmedOwner.sol"; +import "../../../shared/access/ConfirmedOwner.sol"; /// @notice This contract is used for testing only and should not be used for production. contract VRFV2PlusConsumerExample is ConfirmedOwner, VRFConsumerBaseV2Plus { diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusExternalSubOwnerExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusExternalSubOwnerExample.sol index f83d256bc68..2b9ac5713cc 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusExternalSubOwnerExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusExternalSubOwnerExample.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol index ae78b3aa8d1..36063533586 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusSingleConsumerExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusSingleConsumerExample.sol index 68992b6f522..e4cd9ae29ad 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusSingleConsumerExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusSingleConsumerExample.sol @@ -2,7 +2,7 @@ // Example of a single consumer contract which owns the subscription. pragma solidity ^0.8.0; -import "../../../interfaces/LinkTokenInterface.sol"; +import "../../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/IVRFCoordinatorV2Plus.sol"; import "../VRFConsumerBaseV2Plus.sol"; diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusWrapperConsumerExample.sol b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusWrapperConsumerExample.sol index 51fecb8430d..5851d2c5df7 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusWrapperConsumerExample.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/VRFV2PlusWrapperConsumerExample.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.6; import "../VRFV2PlusWrapperConsumerBase.sol"; -import "../../../ConfirmedOwner.sol"; +import "../../../shared/access/ConfirmedOwner.sol"; contract VRFV2PlusWrapperConsumerExample is VRFV2PlusWrapperConsumerBase, ConfirmedOwner { event WrappedRequestFulfilled(uint256 requestId, uint256[] randomWords, uint256 payment); diff --git a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol index 69145509680..a43f045b016 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol @@ -1,12 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {LinkTokenInterface} from "../../../interfaces/LinkTokenInterface.sol"; +import {LinkTokenInterface} from "../../../shared/interfaces/LinkTokenInterface.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBillingRegistry} from "./interfaces/IFunctionsBillingRegistry.sol"; import {IFunctionsOracle} from "./interfaces/IFunctionsOracle.sol"; import {IFunctionsClient} from "./interfaces/IFunctionsClient.sol"; -import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; +import {IERC677Receiver} from "../../../shared/interfaces/IERC677Receiver.sol"; import {IAuthorizedOriginReceiver} from "./accessControl/interfaces/IAuthorizedOriginReceiver.sol"; import {ConfirmedOwnerUpgradeable} from "./accessControl/ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./accessControl/AuthorizedReceiver.sol"; @@ -24,7 +24,7 @@ contract FunctionsBillingRegistry is ConfirmedOwnerUpgradeable, PausableUpgradeable, IFunctionsBillingRegistry, - ERC677ReceiverInterface, + IERC677Receiver, AuthorizedReceiver { LinkTokenInterface private LINK; diff --git a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol index 8bba0bb78b0..284c5637167 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/accessControl/ConfirmedOwnerUpgradeable.sol @@ -1,14 +1,14 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {OwnableInterface} from "../../../../interfaces/OwnableInterface.sol"; +import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; import {Initializable} from "../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title The ConfirmedOwnerUpgradeable contract * @notice An upgrade compatible contract with helpers for basic contract ownership. */ -contract ConfirmedOwnerUpgradeable is Initializable, OwnableInterface { +contract ConfirmedOwnerUpgradeable is Initializable, IOwnable { address private s_owner; address private s_pendingOwner; diff --git a/contracts/src/v0.8/functions/dev/0_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/0_0_0/example/FunctionsClientExample.sol index b95504c0e6e..2d118c6961a 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/example/FunctionsClientExample.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.6; import {FunctionsClient} from "../FunctionsClient.sol"; import {Functions} from "../Functions.sol"; -import {ConfirmedOwner} from "../../../../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; /** * @title Chainlink Functions example client contract implementation diff --git a/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2Base.sol b/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2Base.sol index f2b2e49e359..0814311248c 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2Base.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/ocr/OCR2Base.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import {ConfirmedOwner} from "../../../../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; import {OCR2Abstract} from "./OCR2Abstract.sol"; /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index be626f70b97..db970880ec4 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -9,7 +9,7 @@ import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; -import {ConfirmedOwner} from "../../../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../../../shared/access/ConfirmedOwner.sol"; import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 2782dc7f99c..6a4a2f4a564 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -2,7 +2,8 @@ pragma solidity ^0.8.19; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; -import {ERC677ReceiverInterface} from "../../../interfaces/ERC677ReceiverInterface.sol"; +import {IERC677Receiver} from "../../../shared/interfaces/IERC677Receiver.sol"; +import {LinkTokenInterface} from "../../../shared/interfaces/LinkTokenInterface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; @@ -15,7 +16,7 @@ import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/u // @title Functions Subscriptions contract // @notice Contract that coordinates payment from users to the nodes of the Decentralized Oracle Network (DON). // @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. -abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, ERC677ReceiverInterface { +abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Receiver { using SafeERC20 for IERC20; using FunctionsResponse for FunctionsResponse.Commitment; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol index 766cdcac466..e5a9a6e64f7 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol @@ -2,8 +2,8 @@ pragma solidity ^0.8.19; import {FunctionsClient} from "../FunctionsClient.sol"; +import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; import {FunctionsRequest} from "../libraries/FunctionsRequest.sol"; -import {ConfirmedOwner} from "../../../../ConfirmedOwner.sol"; /** * @title Chainlink Functions example client contract implementation diff --git a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol index 564c3968a32..013cefe82b9 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/ocr/OCR2Base.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import {ConfirmedOwner} from "../../../../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; import {OCR2Abstract} from "./OCR2Abstract.sol"; /** diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol index a6e7ae0760c..ebe2e4c14f7 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/ConfirmedOwnerUpgradeable.sol @@ -1,14 +1,14 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {OwnableInterface} from "../../../../../interfaces/OwnableInterface.sol"; +import {IOwnable} from "../../../../../shared/interfaces/IOwnable.sol"; import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; /** * @title The ConfirmedOwnerUpgradeable contract * @notice An upgrade compatible contract with helpers for basic contract ownership. */ -contract ConfirmedOwnerUpgradeable is Initializable, OwnableInterface { +contract ConfirmedOwnerUpgradeable is Initializable, IOwnable { address private s_owner; address private s_pendingOwner; diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol index 5c1a033535c..1bf13818f73 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol @@ -1,13 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {LinkTokenInterface} from "../../../../../interfaces/LinkTokenInterface.sol"; +import {LinkTokenInterface} from "../../../../../shared/interfaces/LinkTokenInterface.sol"; import {AggregatorV3Interface} from "../../../../../interfaces/AggregatorV3Interface.sol"; import {FunctionsBillingRegistryInterface} from "./FunctionsBillingRegistryInterface.sol"; import {FunctionsOracleInterface} from "./FunctionsOracleInterface.sol"; import {FunctionsClientInterface} from "./FunctionsClientInterface.sol"; import {TypeAndVersionInterface} from "../../../../../interfaces/TypeAndVersionInterface.sol"; -import {ERC677ReceiverInterface} from "../../../../../interfaces/ERC677ReceiverInterface.sol"; +import {IERC677Receiver} from "../../../../../shared/interfaces/IERC677Receiver.sol"; import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; @@ -25,7 +25,7 @@ contract FunctionsBillingRegistryMigration is ConfirmedOwnerUpgradeable, PausableUpgradeable, FunctionsBillingRegistryInterface, - ERC677ReceiverInterface, + IERC677Receiver, AuthorizedReceiver { LinkTokenInterface public LINK; diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol index 2ae9684c924..07652f53f8b 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol @@ -1,13 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {LinkTokenInterface} from "../../../../../interfaces/LinkTokenInterface.sol"; +import {LinkTokenInterface} from "../../../../../shared/interfaces/LinkTokenInterface.sol"; import {AggregatorV3Interface} from "../../../../../interfaces/AggregatorV3Interface.sol"; import {FunctionsOracleInterface} from "./FunctionsOracleInterface.sol"; import {FunctionsBillingRegistryInterface} from "./FunctionsBillingRegistryInterface.sol"; import {FunctionsClientInterface} from "./FunctionsClientInterface.sol"; import {TypeAndVersionInterface} from "../../../../../interfaces/TypeAndVersionInterface.sol"; -import {ERC677ReceiverInterface} from "../../../../../interfaces/ERC677ReceiverInterface.sol"; +import {IERC677Receiver} from "../../../../../shared/interfaces/IERC677Receiver.sol"; import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; @@ -25,7 +25,7 @@ contract FunctionsBillingRegistryOriginal is ConfirmedOwnerUpgradeable, PausableUpgradeable, FunctionsBillingRegistryInterface, - ERC677ReceiverInterface, + IERC677Receiver, AuthorizedReceiver { LinkTokenInterface public LINK; diff --git a/contracts/src/v0.8/interfaces/ITypeAndVersion.sol b/contracts/src/v0.8/interfaces/ITypeAndVersion.sol deleted file mode 100644 index 135f6d0aebf..00000000000 --- a/contracts/src/v0.8/interfaces/ITypeAndVersion.sol +++ /dev/null @@ -1,6 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -interface ITypeAndVersion { - function typeAndVersion() external pure returns (string memory); -} diff --git a/contracts/src/v0.8/interfaces/OwnableInterface.sol b/contracts/src/v0.8/interfaces/OwnableInterface.sol deleted file mode 100644 index a24cbee504c..00000000000 --- a/contracts/src/v0.8/interfaces/OwnableInterface.sol +++ /dev/null @@ -1,10 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -interface OwnableInterface { - function owner() external returns (address); - - function transferOwnership(address recipient) external; - - function acceptOwnership() external; -} diff --git a/contracts/src/v0.8/llo-feeds/Verifier.sol b/contracts/src/v0.8/llo-feeds/Verifier.sol index 2cba744d0cc..34ec915b160 100644 --- a/contracts/src/v0.8/llo-feeds/Verifier.sol +++ b/contracts/src/v0.8/llo-feeds/Verifier.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.16; -import {ConfirmedOwner} from "../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../shared/access/ConfirmedOwner.sol"; import {IVerifier} from "./interfaces/IVerifier.sol"; import {IVerifierProxy} from "./interfaces/IVerifierProxy.sol"; import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; diff --git a/contracts/src/v0.8/llo-feeds/VerifierProxy.sol b/contracts/src/v0.8/llo-feeds/VerifierProxy.sol index 0f071a06cd2..1701c011688 100644 --- a/contracts/src/v0.8/llo-feeds/VerifierProxy.sol +++ b/contracts/src/v0.8/llo-feeds/VerifierProxy.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.16; -import {ConfirmedOwner} from "../ConfirmedOwner.sol"; +import {ConfirmedOwner} from "../shared/access/ConfirmedOwner.sol"; import {IVerifierProxy} from "./interfaces/IVerifierProxy.sol"; import {IVerifier} from "./interfaces/IVerifier.sol"; import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; diff --git a/contracts/src/v0.8/mocks/MockLinkToken.sol b/contracts/src/v0.8/mocks/MockLinkToken.sol index f69c2cfefb5..a68f1b1d341 100644 --- a/contracts/src/v0.8/mocks/MockLinkToken.sol +++ b/contracts/src/v0.8/mocks/MockLinkToken.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import {ERC677ReceiverInterface} from "../interfaces/ERC677ReceiverInterface.sol"; +import {IERC677Receiver} from "../shared/interfaces/IERC677Receiver.sol"; contract MockLinkToken { uint256 private constant TOTAL_SUPPLY = 1_000_000_000 * 1e18; @@ -48,7 +48,7 @@ contract MockLinkToken { } function contractFallback(address _to, uint256 _value, bytes calldata _data) private { - ERC677ReceiverInterface receiver = ERC677ReceiverInterface(_to); + IERC677Receiver receiver = IERC677Receiver(_to); receiver.onTokenTransfer(msg.sender, _value, _data); } } diff --git a/contracts/src/v0.8/mocks/VRFCoordinatorMock.sol b/contracts/src/v0.8/mocks/VRFCoordinatorMock.sol index 1d2f4a2c73b..7e179d5a445 100644 --- a/contracts/src/v0.8/mocks/VRFCoordinatorMock.sol +++ b/contracts/src/v0.8/mocks/VRFCoordinatorMock.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "../vrf/VRFConsumerBase.sol"; contract VRFCoordinatorMock { diff --git a/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol b/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol index eb4f8141956..8dfb0dca7c5 100644 --- a/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol +++ b/contracts/src/v0.8/mocks/VRFCoordinatorV2Mock.sol @@ -2,7 +2,7 @@ // A mock for testing code that relies on VRFCoordinatorV2. pragma solidity ^0.8.4; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "../interfaces/VRFCoordinatorV2Interface.sol"; import "../vrf/VRFConsumerBaseV2.sol"; diff --git a/contracts/src/v0.8/ConfirmedOwner.sol b/contracts/src/v0.8/shared/access/ConfirmedOwner.sol similarity index 100% rename from contracts/src/v0.8/ConfirmedOwner.sol rename to contracts/src/v0.8/shared/access/ConfirmedOwner.sol diff --git a/contracts/src/v0.8/ConfirmedOwnerWithProposal.sol b/contracts/src/v0.8/shared/access/ConfirmedOwnerWithProposal.sol similarity index 94% rename from contracts/src/v0.8/ConfirmedOwnerWithProposal.sol rename to contracts/src/v0.8/shared/access/ConfirmedOwnerWithProposal.sol index 65071d16df7..c2a01cfca18 100644 --- a/contracts/src/v0.8/ConfirmedOwnerWithProposal.sol +++ b/contracts/src/v0.8/shared/access/ConfirmedOwnerWithProposal.sol @@ -1,13 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "./interfaces/OwnableInterface.sol"; +import "../interfaces/IOwnable.sol"; /** * @title The ConfirmedOwner contract * @notice A contract with helpers for basic contract ownership. */ -contract ConfirmedOwnerWithProposal is OwnableInterface { +contract ConfirmedOwnerWithProposal is IOwnable { address private s_owner; address private s_pendingOwner; diff --git a/contracts/src/v0.8/interfaces/ERC677ReceiverInterface.sol b/contracts/src/v0.8/shared/interfaces/IERC677Receiver.sol similarity index 80% rename from contracts/src/v0.8/interfaces/ERC677ReceiverInterface.sol rename to contracts/src/v0.8/shared/interfaces/IERC677Receiver.sol index f6f0d44ee0c..5cb8cfcc082 100644 --- a/contracts/src/v0.8/interfaces/ERC677ReceiverInterface.sol +++ b/contracts/src/v0.8/shared/interfaces/IERC677Receiver.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -interface ERC677ReceiverInterface { +interface IERC677Receiver { function onTokenTransfer(address sender, uint256 amount, bytes calldata data) external; } diff --git a/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol b/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol index b2b61eeb587..8c006a35b95 100644 --- a/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol +++ b/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -abstract contract ITypeAndVersion { +interface ITypeAndVersion { function typeAndVersion() external pure virtual returns (string memory); } diff --git a/contracts/src/v0.8/interfaces/LinkTokenInterface.sol b/contracts/src/v0.8/shared/interfaces/LinkTokenInterface.sol similarity index 100% rename from contracts/src/v0.8/interfaces/LinkTokenInterface.sol rename to contracts/src/v0.8/shared/interfaces/LinkTokenInterface.sol diff --git a/contracts/src/v0.8/OCR2Abstract.sol b/contracts/src/v0.8/shared/ocr2/OCR2Abstract.sol similarity index 97% rename from contracts/src/v0.8/OCR2Abstract.sol rename to contracts/src/v0.8/shared/ocr2/OCR2Abstract.sol index 1a4f13729a3..5031a528b3d 100644 --- a/contracts/src/v0.8/OCR2Abstract.sol +++ b/contracts/src/v0.8/shared/ocr2/OCR2Abstract.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "./interfaces/TypeAndVersionInterface.sol"; +import {ITypeAndVersion} from "../interfaces/ITypeAndVersion.sol"; -abstract contract OCR2Abstract is TypeAndVersionInterface { +abstract contract OCR2Abstract is ITypeAndVersion { // Maximum number of oracles the offchain reporting protocol is designed for uint256 internal constant maxNumOracles = 31; uint256 private constant prefixMask = type(uint256).max << (256 - 16); // 0xFFFF00..00 diff --git a/contracts/src/v0.8/tests/Greeter.sol b/contracts/src/v0.8/tests/Greeter.sol index cb10fa1b193..88ccca560de 100644 --- a/contracts/src/v0.8/tests/Greeter.sol +++ b/contracts/src/v0.8/tests/Greeter.sol @@ -1,6 +1,6 @@ pragma solidity ^0.8.0; -import "../ConfirmedOwner.sol"; +import "../shared/access/ConfirmedOwner.sol"; contract Greeter is ConfirmedOwner { string public greeting; diff --git a/contracts/src/v0.8/tests/MercuryUpkeep.sol b/contracts/src/v0.8/tests/MercuryUpkeep.sol index 941670b338a..53a9411568f 100644 --- a/contracts/src/v0.8/tests/MercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/MercuryUpkeep.sol @@ -1,6 +1,6 @@ pragma solidity 0.8.16; -import "../interfaces/automation/AutomationCompatibleInterface.sol"; +import "../automation/interfaces/AutomationCompatibleInterface.sol"; import "../dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol"; import {ArbSys} from "../vendor/@arbitrum/nitro-contracts/src/precompiles/ArbSys.sol"; diff --git a/contracts/src/v0.8/utils/utils.sol b/contracts/src/v0.8/utils/utils.sol deleted file mode 100644 index 8ad933eabec..00000000000 --- a/contracts/src/v0.8/utils/utils.sol +++ /dev/null @@ -1,14 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.0; - -/** - * @notice getRevertMsg extracts a revert reason from a failed contract call - */ -function getRevertMsg(bytes memory payload) pure returns (string memory) { - if (payload.length < 68) return "transaction reverted silently"; - assembly { - payload := add(payload, 0x04) - } - return abi.decode(payload, (string)); -} diff --git a/contracts/src/v0.8/AuthorizedReceiver.sol b/contracts/src/v0.8/vrf/AuthorizedReceiver.sol similarity index 100% rename from contracts/src/v0.8/AuthorizedReceiver.sol rename to contracts/src/v0.8/vrf/AuthorizedReceiver.sol diff --git a/contracts/src/v0.8/vrf/VRFConsumerBase.sol b/contracts/src/v0.8/vrf/VRFConsumerBase.sol index ed4e09ea93f..983a5b23cb7 100644 --- a/contracts/src/v0.8/vrf/VRFConsumerBase.sol +++ b/contracts/src/v0.8/vrf/VRFConsumerBase.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "./VRFRequestIDBase.sol"; diff --git a/contracts/src/v0.8/vrf/VRFCoordinatorV2.sol b/contracts/src/v0.8/vrf/VRFCoordinatorV2.sol index 79365175bbe..52b7ab295e2 100644 --- a/contracts/src/v0.8/vrf/VRFCoordinatorV2.sol +++ b/contracts/src/v0.8/vrf/VRFCoordinatorV2.sol @@ -1,24 +1,18 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.4; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "../interfaces/BlockhashStoreInterface.sol"; import "../interfaces/AggregatorV3Interface.sol"; import "../interfaces/VRFCoordinatorV2Interface.sol"; import "../interfaces/TypeAndVersionInterface.sol"; -import "../interfaces/ERC677ReceiverInterface.sol"; +import "../shared/interfaces/IERC677Receiver.sol"; import "./VRF.sol"; -import "../ConfirmedOwner.sol"; +import "../shared/access/ConfirmedOwner.sol"; import "./VRFConsumerBaseV2.sol"; import "../ChainSpecificUtil.sol"; -contract VRFCoordinatorV2 is - VRF, - ConfirmedOwner, - TypeAndVersionInterface, - VRFCoordinatorV2Interface, - ERC677ReceiverInterface -{ +contract VRFCoordinatorV2 is VRF, ConfirmedOwner, TypeAndVersionInterface, VRFCoordinatorV2Interface, IERC677Receiver { LinkTokenInterface public immutable LINK; AggregatorV3Interface public immutable LINK_ETH_FEED; BlockhashStoreInterface public immutable BLOCKHASH_STORE; diff --git a/contracts/src/v0.8/vrf/VRFOwner.sol b/contracts/src/v0.8/vrf/VRFOwner.sol index f0db4f1ef38..2c4adf36e8c 100644 --- a/contracts/src/v0.8/vrf/VRFOwner.sol +++ b/contracts/src/v0.8/vrf/VRFOwner.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {ConfirmedOwner} from "../ConfirmedOwner.sol"; -import {AuthorizedReceiver} from "../AuthorizedReceiver.sol"; +import {ConfirmedOwner} from "../shared/access/ConfirmedOwner.sol"; +import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; import "./VRFTypes.sol"; // Taken from VRFCoordinatorV2.sol diff --git a/contracts/src/v0.8/vrf/VRFV2Wrapper.sol b/contracts/src/v0.8/vrf/VRFV2Wrapper.sol index 585c0bdda67..101e1bdfe20 100644 --- a/contracts/src/v0.8/vrf/VRFV2Wrapper.sol +++ b/contracts/src/v0.8/vrf/VRFV2Wrapper.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import "../ConfirmedOwner.sol"; +import "../shared/access/ConfirmedOwner.sol"; import "../interfaces/TypeAndVersionInterface.sol"; import "./VRFConsumerBaseV2.sol"; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "../interfaces/AggregatorV3Interface.sol"; import "../interfaces/VRFCoordinatorV2Interface.sol"; import "../interfaces/VRFV2WrapperInterface.sol"; diff --git a/contracts/src/v0.8/vrf/VRFV2WrapperConsumerBase.sol b/contracts/src/v0.8/vrf/VRFV2WrapperConsumerBase.sol index 7e67d438e84..4c7918e8b7a 100644 --- a/contracts/src/v0.8/vrf/VRFV2WrapperConsumerBase.sol +++ b/contracts/src/v0.8/vrf/VRFV2WrapperConsumerBase.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../interfaces/LinkTokenInterface.sol"; +import "../shared/interfaces/LinkTokenInterface.sol"; import "../interfaces/VRFV2WrapperInterface.sol"; /** ******************************************************************************* diff --git a/contracts/src/v0.8/interfaces/IAuthorizedReceiver.sol b/contracts/src/v0.8/vrf/interfaces/IAuthorizedReceiver.sol similarity index 100% rename from contracts/src/v0.8/interfaces/IAuthorizedReceiver.sol rename to contracts/src/v0.8/vrf/interfaces/IAuthorizedReceiver.sol diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFConsumer.sol b/contracts/src/v0.8/vrf/testhelpers/VRFConsumer.sol index f8347ef6e2a..2f063e67267 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFConsumer.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFConsumer.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../VRFConsumerBase.sol"; contract VRFConsumer is VRFConsumerBase { diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2.sol b/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2.sol index 3b00d382524..466451c7b6a 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2UpgradeableExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2UpgradeableExample.sol index e9f53e5f7b2..b99abedf3c7 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2UpgradeableExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFConsumerV2UpgradeableExample.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../../dev/VRFConsumerBaseV2Upgradeable.sol"; import "@openzeppelin/contracts-upgradeable-4.7.3/proxy/utils/Initializable.sol"; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFExternalSubOwnerExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFExternalSubOwnerExample.sol index 049a976f119..f6b171cb508 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFExternalSubOwnerExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFExternalSubOwnerExample.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestExternalSubOwner.sol b/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestExternalSubOwner.sol index 643a212e250..b4bf37990d7 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestExternalSubOwner.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestExternalSubOwner.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; /** * @title The VRFLoadTestExternalSubOwner contract. diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol b/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol index 5d7691c6817..93c75298d9e 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol @@ -2,13 +2,13 @@ pragma solidity ^0.8.0; import "../VRFConsumerBase.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; /** * @title The VRFLoadTestOwnerlessConsumer contract. * @notice Allows making many VRF V1 randomness requests in a single transaction for load testing. */ -contract VRFLoadTestOwnerlessConsumer is VRFConsumerBase, ERC677ReceiverInterface { +contract VRFLoadTestOwnerlessConsumer is VRFConsumerBase, IERC677Receiver { // The price of each VRF request in Juels. 1 LINK = 1e18 Juels. uint256 public immutable PRICE; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFMaliciousConsumerV2.sol b/contracts/src/v0.8/vrf/testhelpers/VRFMaliciousConsumerV2.sol index 5ed79ae2e86..f11fcc0b7d0 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFMaliciousConsumerV2.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFMaliciousConsumerV2.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFOwnerlessConsumerExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFOwnerlessConsumerExample.sol index 5d2d4ae282a..0eeb5ebc8f1 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFOwnerlessConsumerExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFOwnerlessConsumerExample.sol @@ -4,9 +4,9 @@ pragma solidity ^0.8.4; import "../VRFConsumerBase.sol"; -import "../../interfaces/ERC677ReceiverInterface.sol"; +import "../../shared/interfaces/IERC677Receiver.sol"; -contract VRFOwnerlessConsumerExample is VRFConsumerBase, ERC677ReceiverInterface { +contract VRFOwnerlessConsumerExample is VRFConsumerBase, IERC677Receiver { uint256 public s_randomnessOutput; bytes32 public s_requestId; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFSingleConsumerExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFSingleConsumerExample.sol index 12b29599fd1..d4dd7b9087a 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFSingleConsumerExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFSingleConsumerExample.sol @@ -2,7 +2,7 @@ // Example of a single consumer contract which owns the subscription. pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2LoadTestWithMetrics.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2LoadTestWithMetrics.sol index ed6c8026388..3fd3f4e4038 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFV2LoadTestWithMetrics.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2LoadTestWithMetrics.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.0; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; import "../../ChainSpecificUtil.sol"; /** diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2RevertingExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2RevertingExample.sol index 738e42219f4..72be535a000 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFV2RevertingExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2RevertingExample.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFCoordinatorV2Interface.sol"; import "../VRFConsumerBaseV2.sol"; diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperConsumerExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperConsumerExample.sol index a4fb040a6d0..7ab54ee9fa3 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperConsumerExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperConsumerExample.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.6; import "../VRFV2WrapperConsumerBase.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; contract VRFV2WrapperConsumerExample is VRFV2WrapperConsumerBase, ConfirmedOwner { event WrappedRequestFulfilled(uint256 requestId, uint256[] randomWords, uint256 payment); diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperOutOfGasConsumerExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperOutOfGasConsumerExample.sol index f89229dfe7c..e6747820fdb 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperOutOfGasConsumerExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperOutOfGasConsumerExample.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.6; import "../VRFV2WrapperConsumerBase.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; contract VRFV2WrapperOutOfGasConsumerExample is VRFV2WrapperConsumerBase, ConfirmedOwner { constructor( diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperRevertingConsumerExample.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperRevertingConsumerExample.sol index 89f3c752225..c3699a1d74b 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperRevertingConsumerExample.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperRevertingConsumerExample.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.6; import "../VRFV2WrapperConsumerBase.sol"; -import "../../ConfirmedOwner.sol"; +import "../../shared/access/ConfirmedOwner.sol"; contract VRFV2WrapperRevertingConsumerExample is VRFV2WrapperConsumerBase, ConfirmedOwner { constructor( diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperUnderFundingConsumer.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperUnderFundingConsumer.sol index 09ec603a1f2..ae0f9eac83c 100644 --- a/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperUnderFundingConsumer.sol +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2WrapperUnderFundingConsumer.sol @@ -1,8 +1,8 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; -import "../../ConfirmedOwner.sol"; -import "../../interfaces/LinkTokenInterface.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../interfaces/VRFV2WrapperInterface.sol"; contract VRFV2WrapperUnderFundingConsumer is ConfirmedOwner { diff --git a/contracts/test/v0.8/Cron.test.ts b/contracts/test/v0.8/Cron.test.ts index 0b7bbd2f5db..2cdc7c247f9 100644 --- a/contracts/test/v0.8/Cron.test.ts +++ b/contracts/test/v0.8/Cron.test.ts @@ -3,7 +3,7 @@ import { ethers } from 'hardhat' import { assert, expect } from 'chai' import { CronInternalTestHelper } from '../../typechain/CronInternalTestHelper' import { CronExternalTestHelper } from '../../typechain/CronExternalTestHelper' -import { validCrons, invalidCrons } from '../test-helpers/fixtures' +import { invalidCrons, validCrons } from '../test-helpers/fixtures' import { reset, setTimestamp } from '../test-helpers/helpers' let cron: CronInternalTestHelper | CronExternalTestHelper @@ -21,7 +21,7 @@ describe('Cron', () => { ) cronInternal = await cronInternalTestHelperFactory.deploy() const cronExternalFactory = await ethers.getContractFactory( - 'src/v0.8/libraries/external/Cron.sol:Cron', + 'src/v0.8/automation/libraries/external/Cron.sol:Cron', admin, ) const cronExternalLib = await cronExternalFactory.deploy() diff --git a/contracts/test/v0.8/automation/CronUpkeep.test.ts b/contracts/test/v0.8/automation/CronUpkeep.test.ts index 2291fd21d91..755b4494c81 100644 --- a/contracts/test/v0.8/automation/CronUpkeep.test.ts +++ b/contracts/test/v0.8/automation/CronUpkeep.test.ts @@ -81,7 +81,7 @@ describe('CronUpkeep', () => { ) cronDelegate = await cronDelegateFactory.deploy() const cronExternalFactory = await ethers.getContractFactory( - 'src/v0.8/libraries/external/Cron.sol:Cron', + 'src/v0.8/automation/libraries/external/Cron.sol:Cron', admin, ) const cronExternalLib = await cronExternalFactory.deploy() @@ -521,7 +521,7 @@ describe.skip('Cron Gas Usage', () => { ) const cronDelegate = await cronDelegateFactory.deploy() const cronExternalFactory = await ethers.getContractFactory( - 'src/v0.8/libraries/external/Cron.sol:Cron', + 'src/v0.8/automation/libraries/external/Cron.sol:Cron', admin, ) const cronExternalLib = await cronExternalFactory.deploy() diff --git a/contracts/test/v0.8/automation/CronUpkeepFactory.test.ts b/contracts/test/v0.8/automation/CronUpkeepFactory.test.ts index aaa1753de10..e9a7de837b7 100644 --- a/contracts/test/v0.8/automation/CronUpkeepFactory.test.ts +++ b/contracts/test/v0.8/automation/CronUpkeepFactory.test.ts @@ -3,8 +3,8 @@ import { Contract } from 'ethers' import { assert, expect } from 'chai' import { CronUpkeepFactory } from '../../../typechain/CronUpkeepFactory' import type { SignerWithAddress } from '@nomiclabs/hardhat-ethers/signers' -import { reset } from '../../test-helpers/helpers' import * as h from '../../test-helpers/helpers' +import { reset } from '../../test-helpers/helpers' const OWNABLE_ERR = 'Only callable by owner' @@ -22,7 +22,7 @@ describe('CronUpkeepFactory', () => { owner = accounts[1] stranger = accounts[2] const cronExternalFactory = await ethers.getContractFactory( - 'src/v0.8/libraries/external/Cron.sol:Cron', + 'src/v0.8/automation/libraries/external/Cron.sol:Cron', admin, ) cronExternalLib = await cronExternalFactory.deploy() diff --git a/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol b/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol index 9bf97d69693..3040fda97de 100644 --- a/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol +++ b/contracts/test/v0.8/foundry/transmission/EIP_712_1014_4337.t.sol @@ -11,7 +11,7 @@ import "../../../../src/v0.8/vendor/entrypoint/core/EntryPoint.sol"; import "../../../../src/v0.8/vendor/entrypoint/interfaces/IEntryPoint.sol"; import "../../../../src/v0.8/dev/transmission/4337/SCALibrary.sol"; import "../../../../src/v0.8/mocks/MockLinkToken.sol"; -import "../../../../src/v0.8/interfaces/LinkTokenInterface.sol"; +import "../../../../src/v0.8/shared/interfaces/LinkTokenInterface.sol"; import "../../../../src/v0.8/mocks/VRFCoordinatorMock.sol"; import "../../../../src/v0.8/tests/MockV3Aggregator.sol"; import "../../../../src/v0.8/vrf/testhelpers/VRFConsumer.sol"; diff --git a/integration-tests/contracts/ethereum/src/VRFv2Consumer.sol b/integration-tests/contracts/ethereum/src/VRFv2Consumer.sol index 390937b563c..333318f4990 100644 --- a/integration-tests/contracts/ethereum/src/VRFv2Consumer.sol +++ b/integration-tests/contracts/ethereum/src/VRFv2Consumer.sol @@ -4,7 +4,7 @@ pragma solidity ^0.8.7; import "../../../../../contracts/src/v0.8/interfaces/VRFCoordinatorV2Interface.sol"; import "../../../../../contracts/src/v0.8/VRFConsumerBaseV2.sol"; -import "../../../../../contracts/src/v0.8/ConfirmedOwner.sol"; +import "../../../../contracts/src/v0.8/shared/access/ConfirmedOwner.sol"; /** * THIS IS AN EXAMPLE CONTRACT THAT USES HARDCODED VALUES FOR CLARITY. From d53f5b87fee96bdaccb3ab2f5f4c44ec582aead3 Mon Sep 17 00:00:00 2001 From: ferglor <19188060+ferglor@users.noreply.github.com> Date: Fri, 4 Aug 2023 10:29:02 +0100 Subject: [PATCH 079/270] Read the fast gas and link native from the highest check block (#10062) * Read the fast gas and link native from the highest check block * Use the block number from the trigger * Clean up debug log --- .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 8 +- .../plugins/ocr2keeper/evm21/encoder_test.go | 143 ++++++++++++++++-- 2 files changed, 133 insertions(+), 18 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index 559b51c3f7c..be518a2917d 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -58,15 +58,17 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] PerformDatas: make([][]byte, len(results)), } + highestCheckBlock := big.NewInt(0) for i, result := range results { ext, ok := result.Extension.(EVMAutomationResultExtension21) if !ok { return nil, fmt.Errorf("unexpected check result extension struct") } - // only take these values from the first result - // TODO: find a new way to get these values - if i == 0 { + checkBlock := big.NewInt(result.Payload.Trigger.BlockNumber) + + if checkBlock.Cmp(highestCheckBlock) == 1 { + highestCheckBlock = checkBlock report.FastGasWei = ext.FastGasWei report.LinkNative = ext.LinkNative } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go index 23d9ea8545f..26b0d2efaf8 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go @@ -28,33 +28,53 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { } tests := []struct { - name string - results []ocr2keepers.CheckResult - reportSize int - expectedErr error + name string + results []ocr2keepers.CheckResult + reportSize int + expectedFastGasWei int64 + expectedLinkNative int64 + expectedErr error }{ { "happy flow single", []ocr2keepers.CheckResult{ - newResult(1, ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String())), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String()), 1, 1), }, 640, + 1, + 1, nil, }, { "happy flow multiple", []ocr2keepers.CheckResult{ - newResult(1, ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String())), - newResult(2, ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String())), - newResult(3, ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String())), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String()), 1, 1), + newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 2, 2), + newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 3, 3), }, 1280, + 3, + 3, + nil, + }, + { + "happy flow highest block number first", + []ocr2keepers.CheckResult{ + newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1000, 2000), + newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 2, 2), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String()), 1, 1), + }, + 1280, + 1000, + 2000, nil, }, { "empty results", []ocr2keepers.CheckResult{}, 0, + 0, + 0, ErrEmptyResults, }, } @@ -66,6 +86,7 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { assert.Equal(t, tc.expectedErr, err) return } + assert.Nil(t, err) assert.Len(t, b, tc.reportSize) @@ -83,11 +104,72 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { assert.Equal(t, upkeep.PerformData, tc.results[i].PerformData) assert.Equal(t, upkeep.CheckBlockNumber, uint32(tc.results[i].Payload.Trigger.BlockNumber)) assert.Equal(t, common.BytesToHash(upkeep.CheckBlockHash[:]), common.HexToHash(tc.results[i].Payload.Trigger.BlockHash)) + assert.Equal(t, upkeep.FastGasWei, big.NewInt(tc.expectedFastGasWei)) + assert.Equal(t, upkeep.LinkNative, big.NewInt(tc.expectedLinkNative)) } }) } } +func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { + keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) + assert.Nil(t, err) + utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + assert.Nil(t, err) + encoder := EVMAutomationEncoder21{ + packer: NewEvmRegistryPackerV2_1(keepersABI, utilsABI), + } + + t.Run("a non-EVMAutomationResultExtension21 extension causes an error", func(t *testing.T) { + result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1, 1) + result.Extension = "invalid" + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unexpected check result extension struct") + }) + + t.Run("an invalid upkeep ID causes an error", func(t *testing.T) { + result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1, 1) + result.Payload.Upkeep.ID = []byte("invalid") + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "failed to parse big int from upkeep id: invalid") + }) + + t.Run("a non-LogTriggerExtension extension causes an error", func(t *testing.T) { + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) + result.Payload.Trigger.Extension = "invalid" + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unrecognized trigger extension data") + }) + + t.Run("a non hex tx (empty) hash causes an error", func(t *testing.T) { + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) + result.Payload.Trigger.Extension = logprovider.LogTriggerExtension{ + TxHash: "", + } + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "tx hash parse error: empty hex string") + }) + + t.Run("an invalid upkeep type causes an error", func(t *testing.T) { + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(5, "20").String()), 1, 1) + result.Payload.Trigger.Extension = logprovider.LogTriggerExtension{ + TxHash: "", + } + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unknown trigger type: 5: failed to pack trigger") + }) +} + func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) assert.Nil(t, err) @@ -105,16 +187,16 @@ func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { { "happy flow single", []ocr2keepers.CheckResult{ - newResult(1, ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "10").String())), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "10").String()), 1, 1), }, nil, }, { "happy flow multiple", []ocr2keepers.CheckResult{ - newResult(1, ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "10").String())), - newResult(2, ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "20").String())), - newResult(3, ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "30").String())), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "10").String()), 1, 1), + newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "20").String()), 1, 1), + newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "30").String()), 1, 1), }, nil, }, @@ -146,7 +228,37 @@ func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { } } -func newResult(block int64, id ocr2keepers.UpkeepIdentifier) ocr2keepers.CheckResult { +func TestEVMAutomationEncoder21_EncodeExtract_errors(t *testing.T) { + keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) + assert.Nil(t, err) + utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + assert.Nil(t, err) + encoder := EVMAutomationEncoder21{ + packer: NewEvmRegistryPackerV2_1(keepersABI, utilsABI), + } + + t.Run("attempting to decode a report with an invalid trigger type returns an error", func(t *testing.T) { + encodedConditionTrigger := []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 49, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 100, 97, 116, 97, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} + reportedUpkeeps, err := encoder.Extract(encodedConditionTrigger) + assert.Nil(t, reportedUpkeeps) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unknown trigger type: 9: failed to unpack trigger") + }) +} + +func TestBlockKeyHelper_MakeBlockKey(t *testing.T) { + helper := BlockKeyHelper[int64]{} + blockKey := helper.MakeBlockKey(1234) + assert.Equal(t, blockKey, ocr2keepers.BlockKey("1234")) +} + +func TestUpkeepKeyHelper_MakeBlockKey(t *testing.T) { + helper := UpkeepKeyHelper[int64]{} + blockKey := helper.MakeUpkeepKey(1234, big.NewInt(5678)) + assert.Equal(t, blockKey, ocr2keepers.UpkeepKey("1234|5678")) +} + +func newResult(block int64, checkBlock ocr2keepers.BlockKey, id ocr2keepers.UpkeepIdentifier, fastGasWei, linkNative int64) ocr2keepers.CheckResult { logExt := logprovider.LogTriggerExtension{} tp := getUpkeepType(id) if tp == logTrigger { @@ -163,6 +275,7 @@ func newResult(block int64, id ocr2keepers.UpkeepIdentifier) ocr2keepers.CheckRe BlockHash: hexutil.Encode([]byte{1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8}), Extension: logExt, }, + CheckBlock: checkBlock, } payload.ID = payload.GenerateID() return ocr2keepers.CheckResult{ @@ -171,8 +284,8 @@ func newResult(block int64, id ocr2keepers.UpkeepIdentifier) ocr2keepers.CheckRe GasAllocated: 100, PerformData: []byte("data0"), Extension: EVMAutomationResultExtension21{ - FastGasWei: big.NewInt(100), - LinkNative: big.NewInt(100), + FastGasWei: big.NewInt(fastGasWei), + LinkNative: big.NewInt(linkNative), }, } } From 476a742dcc85c5b8d7760862953539aff4bedd0b Mon Sep 17 00:00:00 2001 From: Gheorghe Strimtu Date: Fri, 4 Aug 2023 13:32:41 +0300 Subject: [PATCH 080/270] revert scripts generation for mock events contracts (#10058) * revert scripts generation for mock events contracts * add comments * revert some changes * remove from do not edit file * make go-solidity-wrappers * update file * versions (#10077) * add events_mock compilation to all compile script * redo set -euo pipefail --------- Co-authored-by: Justin Kaseman Co-authored-by: Bolek <1416262+bolekk@users.noreply.github.com> Co-authored-by: Rens Rooimans --- contracts/scripts/native_solc_compile_all | 2 +- .../native_solc_compile_all_events_mock | 30 +++++++++++++++++++ .../scripts/native_solc_compile_all_functions | 5 ---- core/gethwrappers/functions/go_generate.go | 3 -- .../functions_billing_registry_events_mock.go | 0 .../functions_oracle_events_mock.go | 0 .../generation/compile_event_mock_contract.sh | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 2 ++ core/gethwrappers/go_generate.go | 9 ++++++ .../contracts/contract_deployer.go | 4 +-- .../contracts/contract_models.go | 2 +- .../contracts/ethereum_contracts.go | 4 +-- 12 files changed, 48 insertions(+), 15 deletions(-) create mode 100755 contracts/scripts/native_solc_compile_all_events_mock rename core/gethwrappers/{functions => }/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go (100%) rename core/gethwrappers/{functions => }/generated/functions_oracle_events_mock/functions_oracle_events_mock.go (100%) diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 18a00372917..1612bc29976 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -12,7 +12,7 @@ python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt # 6 and 7 are legacy contracts, for each other 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 6 7 feeds functions llo transmission vrf automation logpoller +for product in 6 7 feeds functions llo transmission vrf automation logpoller events_mock do $SCRIPTPATH/native_solc_compile_all_$product done diff --git a/contracts/scripts/native_solc_compile_all_events_mock b/contracts/scripts/native_solc_compile_all_events_mock new file mode 100755 index 00000000000..993530e2fa1 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_events_mock @@ -0,0 +1,30 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling Events Mock contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.6" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt + +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8\ + $ROOT/contracts/src/v0.8/$1 +} + +# This script is used to compile the contracts for the Events Mocks used in the tests. +compileContract mocks/FunctionsOracleEventsMock.sol +compileContract mocks/FunctionsBillingRegistryEventsMock.sol \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_functions b/contracts/scripts/native_solc_compile_all_functions index eb061d2a9c8..8b342445fb1 100755 --- a/contracts/scripts/native_solc_compile_all_functions +++ b/contracts/scripts/native_solc_compile_all_functions @@ -41,11 +41,6 @@ compileContract 0_0_0 dev/0_0_0/example/FunctionsClientExample.sol compileContract 0_0_0 tests/0_0_0/testhelpers/FunctionsBillingRegistryWithInit.sol compileContract 0_0_0 tests/0_0_0/testhelpers/FunctionsOracleWithInit.sol -# Mocks -compileContract 0_0_0 ../mocks/FunctionsOracleEventsMock.sol -compileContract 0_0_0 ../mocks/FunctionsBillingRegistryEventsMock.sol - - ############################ # Version 1 (Mainnet Preview) ############################ diff --git a/core/gethwrappers/functions/go_generate.go b/core/gethwrappers/functions/go_generate.go index c163623c331..04ea0bff283 100644 --- a/core/gethwrappers/functions/go_generate.go +++ b/core/gethwrappers/functions/go_generate.go @@ -11,9 +11,6 @@ package gethwrappers //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleWithInit.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleWithInit.bin OCR2DROracle ocr2dr_oracle //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryWithInit.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryWithInit.bin OCR2DRRegistry ocr2dr_registry -//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin FunctionsOracleEventsMock functions_oracle_events_mock -//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin FunctionsBillingRegistryEventsMock functions_billing_registry_events_mock - // Version 1 (Mainnet Preview) //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin Functions functions //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin FunctionsClient functions_client diff --git a/core/gethwrappers/functions/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go b/core/gethwrappers/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go similarity index 100% rename from core/gethwrappers/functions/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go rename to core/gethwrappers/generated/functions_billing_registry_events_mock/functions_billing_registry_events_mock.go diff --git a/core/gethwrappers/functions/generated/functions_oracle_events_mock/functions_oracle_events_mock.go b/core/gethwrappers/generated/functions_oracle_events_mock/functions_oracle_events_mock.go similarity index 100% rename from core/gethwrappers/functions/generated/functions_oracle_events_mock/functions_oracle_events_mock.go rename to core/gethwrappers/generated/functions_oracle_events_mock/functions_oracle_events_mock.go diff --git a/core/gethwrappers/generation/compile_event_mock_contract.sh b/core/gethwrappers/generation/compile_event_mock_contract.sh index addbc1f178f..a576a16adf6 100755 --- a/core/gethwrappers/generation/compile_event_mock_contract.sh +++ b/core/gethwrappers/generation/compile_event_mock_contract.sh @@ -5,7 +5,7 @@ set -euo pipefail echo "compiling contracts" CDIR="$(dirname "$0")" -COMPILE_COMMAND="$CDIR/../../../contracts/scripts/native_solc_compile_events_mock" +COMPILE_COMMAND="$CDIR/../../../contracts/scripts/native_solc_compile_all_events_mock" # Only print compilation output on failure. diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 7f86257ee45..9751065b0d9 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -18,6 +18,8 @@ derived_price_feed_wrapper: ../../contracts/solc/v0.8.6/DerivedPriceFeed.abi ../ feed_lookup_compatible_interface: ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.bin 2c5c2cb669a666ab6f14e7fdbd11ea019997e3860f56ccfaf112156e412f1b15 flags_wrapper: ../../contracts/solc/v0.6/Flags.abi ../../contracts/solc/v0.6/Flags.bin 2034d1b562ca37a63068851915e3703980276e8d5f7db6db8a3351a49d69fc4a flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../contracts/solc/v0.6/FluxAggregator.bin a3b0a6396c4aa3b5ee39b3c4bd45efc89789d4859379a8a92caca3a0496c5794 +functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 +functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin fb976990e21d6c454245bcd3247d71b2f045a7c5636adaebfe64b7449cb6042e i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index c08c0d3d11c..02f627f4ab4 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -132,8 +132,17 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin MercuryExposedVerifier mercury_exposed_verifier // Mocks that contain only events and functions to emit them +// These contracts are used in testing Atlas flows. The contracts contain no logic, only events, structures, and functions to emit them. +// The flow is as follows: +// 1. Compile all non events mock contracts. +// 2. Generate events mock .sol files based on ABI of compiled contracts. +// 3. Compile events mock contracts. ./generation/compile_event_mock_contract.sh calls contracts/scripts/native_solc_compile_all_events_mock to compile events mock contracts. +// 4. Generate wrappers for events mock contracts. //go:generate go run ./generation/generate_events_mock/create_events_mock_contract.go ../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracle.abi ../../contracts/src/v0.8/mocks/FunctionsOracleEventsMock.sol FunctionsOracleEventsMock //go:generate go run ./generation/generate_events_mock/create_events_mock_contract.go ../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistry.abi ../../contracts/src/v0.8/mocks/FunctionsBillingRegistryEventsMock.sol FunctionsBillingRegistryEventsMock +//go:generate ./generation/compile_event_mock_contract.sh +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin FunctionsOracleEventsMock functions_oracle_events_mock +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin FunctionsBillingRegistryEventsMock functions_billing_registry_events_mock // Transmission //go:generate go generate ./transmission diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 186ebe2080e..b0ce801732e 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -16,11 +16,11 @@ import ( ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_billing_registry_events_mock" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flags_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper2_0" diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index 8d8dff3dab7..ba63d72e9f9 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -14,8 +14,8 @@ import ( ocrConfigHelper2 "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/operator_factory" ) diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index dac0c3d3c0b..794a5680f2d 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -20,11 +20,11 @@ import ( "github.com/smartcontractkit/chainlink/integration-tests/client" eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_billing_registry_events_mock" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/authorized_forwarder" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flags_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_aggregator_proxy" From 604a40775bd30e8b8665f8dbeffd6c4597593588 Mon Sep 17 00:00:00 2001 From: ferglor <19188060+ferglor@users.noreply.github.com> Date: Fri, 4 Aug 2023 11:50:39 +0100 Subject: [PATCH 081/270] Add a decode extensions function (#10070) * Add a decodeExtensions function * Add coverage for decoding extensions * Reassign loop var --- .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 84 +++++++++ .../plugins/ocr2keeper/evm21/encoder_test.go | 164 +++++++++++++++++- 2 files changed, 247 insertions(+), 1 deletion(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index be518a2917d..1e0d7bed993 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -1,6 +1,7 @@ package evm import ( + "encoding/json" "fmt" "math/big" @@ -58,10 +59,18 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] PerformDatas: make([][]byte, len(results)), } + encoded := 0 highestCheckBlock := big.NewInt(0) + for i, result := range results { + result := result + if err := decodeExtensions(&result); err != nil { + return nil, err + } + ext, ok := result.Extension.(EVMAutomationResultExtension21) if !ok { + // decodeExtensions should catch this, but in the case it doesn't ... return nil, fmt.Errorf("unexpected check result extension struct") } @@ -84,28 +93,39 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] BlockNum: uint32(result.Payload.Trigger.BlockNumber), BlockHash: common.HexToHash(result.Payload.Trigger.BlockHash), } + switch getUpkeepType(id.Bytes()) { case logTrigger: trExt, ok := result.Payload.Trigger.Extension.(logprovider.LogTriggerExtension) if !ok { + // decodeExtensions should catch this, but in the case it doesn't ... return nil, fmt.Errorf("unrecognized trigger extension data") } + hex, err := common.ParseHexOrString(trExt.TxHash) if err != nil { return nil, fmt.Errorf("tx hash parse error: %w", err) } + triggerW.TxHash = common.BytesToHash(hex[:]) triggerW.LogIndex = uint32(trExt.LogIndex) default: + // no special handling here for conditional triggers } + trigger, err := enc.packer.PackTrigger(id, triggerW) if err != nil { return nil, fmt.Errorf("%w: failed to pack trigger", err) } + report.Triggers[i] = trigger report.PerformDatas[i] = result.PerformData + + encoded++ } + fmt.Printf("[automation-ocr3|EvmRegistry|Encoder] encoded %d out of %d results\n", encoded, len(results)) + return enc.packer.PackReport(report) } @@ -160,3 +180,67 @@ type UpkeepKeyHelper[T uint32 | int64] struct { func (kh UpkeepKeyHelper[T]) MakeUpkeepKey(b T, id *big.Int) ocr2keepers.UpkeepKey { return ocr2keepers.UpkeepKey(fmt.Sprintf("%d%s%s", b, separator, id)) } + +func decodeExtensions(result *ocr2keepers.CheckResult) error { + if result == nil { + return fmt.Errorf("non-nil value expected in decoding") + } + + rC := *result + + // decode the trigger extension data if not decoded + switch typedExt := rC.Payload.Trigger.Extension.(type) { + case logprovider.LogTriggerExtension: + // no decoding required + break + case []byte: + switch getUpkeepType(result.Payload.Upkeep.ID) { + case logTrigger: + var ext logprovider.LogTriggerExtension + + // in the case of a string, the value is probably still json + // encoded and coming from a plugin outcome + if err := json.Unmarshal(typedExt, &ext); err != nil { + return fmt.Errorf("%w: json encoded values do not match LogTriggerExtension struct: %s", err, string(typedExt)) + } + + result.Payload.Trigger.Extension = ext + case conditionTrigger: + // no special handling for conditional triggers + break + default: + return fmt.Errorf("unknown upkeep type") + } + case struct{}, nil: + // empty fallback + break + default: + return fmt.Errorf("unrecognized trigger extension data") + } + + // decode the result extension data if not decoded + switch typedExt := result.Extension.(type) { + case EVMAutomationResultExtension21: + // no decoding required + break + case []byte: + var ext EVMAutomationResultExtension21 + + // in the case of a string, the value is probably still json + // encoded and coming from a plugin outcome + if err := json.Unmarshal(typedExt, &ext); err != nil { + return fmt.Errorf("%w: json encoded values do not match EVMAutomationResultExtension21 struct", err) + } + + result.Extension = ext + case struct{}, nil: + // empty fallback + break + default: + return fmt.Errorf("unrecognized CheckResult extension data") + } + + // TODO: decode upkeep config data if not decoded + + return nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go index 26b0d2efaf8..435a44c431a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go @@ -126,7 +126,7 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { b, err := encoder.Encode(result) assert.Nil(t, b) assert.Error(t, err) - assert.Equal(t, err.Error(), "unexpected check result extension struct") + assert.Equal(t, err.Error(), "unrecognized CheckResult extension data") }) t.Run("an invalid upkeep ID causes an error", func(t *testing.T) { @@ -168,6 +168,24 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { assert.Error(t, err) assert.Equal(t, err.Error(), "unknown trigger type: 5: failed to pack trigger") }) + + t.Run("an invalid result extension causes an error", func(t *testing.T) { + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(5, "20").String()), 1, 1) + result.Extension = struct{}{} + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unexpected check result extension struct") + }) + + t.Run("invalid trigger extension causes an error", func(t *testing.T) { + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) + result.Payload.Trigger.Extension = struct{}{} + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unrecognized trigger extension data") + }) } func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { @@ -318,3 +336,147 @@ func decode(packer *evmRegistryPackerV2_1, raw []byte) ([]ocr2keepers.UpkeepResu return res, nil } + +func Test_decodeExtensions(t *testing.T) { + t.Run("a nil result returns an error", func(t *testing.T) { + err := decodeExtensions(nil) + assert.Error(t, err) + assert.Equal(t, err.Error(), "non-nil value expected in decoding") + }) + + t.Run("two types of extension do not require decoding", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Trigger: ocr2keepers.Trigger{ + Extension: logprovider.LogTriggerExtension{}, + }, + }, + Extension: EVMAutomationResultExtension21{}, + }) + assert.NoError(t, err) + }) + + t.Run("empty structs do not require decoding", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Trigger: ocr2keepers.Trigger{ + Extension: struct{}{}, + }, + }, + Extension: struct{}{}, + }) + assert.NoError(t, err) + }) + + t.Run("CheckResult extension as json gets decoded", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Trigger: ocr2keepers.Trigger{ + Extension: struct{}{}, + }, + }, + Extension: []byte(`{"FastGasWei":1,"LinkNative":2,"FailureReason":3}`), + }) + assert.NoError(t, err) + }) + + t.Run("trigger extension as json for logTrigger gets decoded", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "111").Bytes()), + }, + Trigger: ocr2keepers.Trigger{ + Extension: []byte(`{"TxHash": "abc", "LogIndex": 123}`), + }, + }, + Extension: struct{}{}, + }) + assert.NoError(t, err) + }) + + t.Run("trigger extension as invalid json returns an error for logTrigger", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "111").Bytes()), + }, + Trigger: ocr2keepers.Trigger{ + Extension: []byte(`invalid`), + }, + }, + Extension: struct{}{}, + }) + assert.Error(t, err) + assert.Equal(t, err.Error(), "invalid character 'i' looking for beginning of value: json encoded values do not match LogTriggerExtension struct: invalid") + }) + + t.Run("trigger extension for conditionTrigger requires no decoding", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "111").Bytes()), + }, + Trigger: ocr2keepers.Trigger{ + Extension: []byte(""), + }, + }, + Extension: struct{}{}, + }) + assert.NoError(t, err) + }) + + t.Run("trigger extension for an unknown upkeep type returns an error", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(99, "111").Bytes()), + }, + Trigger: ocr2keepers.Trigger{ + Extension: []byte(""), + }, + }, + Extension: struct{}{}, + }) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unknown upkeep type") + }) + + t.Run("CheckResult extension as invalid json returns an error", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Trigger: ocr2keepers.Trigger{ + Extension: struct{}{}, + }, + }, + Extension: []byte(`invalid`), + }) + assert.Error(t, err) + assert.Equal(t, err.Error(), "invalid character 'i' looking for beginning of value: json encoded values do not match EVMAutomationResultExtension21 struct") + }) + + t.Run("unrecognized trigger extension returns an error", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Trigger: ocr2keepers.Trigger{ + Extension: "invalid", + }, + }, + }) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unrecognized trigger extension data") + }) + + t.Run("unrecognized CheckResult extension returns an error", func(t *testing.T) { + err := decodeExtensions(&ocr2keepers.CheckResult{ + Payload: ocr2keepers.UpkeepPayload{ + Trigger: ocr2keepers.Trigger{ + Extension: logprovider.LogTriggerExtension{}, + }, + }, + Extension: "invalid", + }) + assert.Error(t, err) + assert.Equal(t, err.Error(), "unrecognized CheckResult extension data") + }) +} From 0008416968a0febb4880022bd167c56defd8adee Mon Sep 17 00:00:00 2001 From: Sam Date: Fri, 4 Aug 2023 09:21:35 -0400 Subject: [PATCH 082/270] Clarify logging slightly (#10023) --- core/services/relay/evm/mercury/wsrpc/client.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/services/relay/evm/mercury/wsrpc/client.go b/core/services/relay/evm/mercury/wsrpc/client.go index 5f3d05d0c0d..fb9a57d9a2d 100644 --- a/core/services/relay/evm/mercury/wsrpc/client.go +++ b/core/services/relay/evm/mercury/wsrpc/client.go @@ -238,7 +238,7 @@ func (w *client) Transmit(ctx context.Context, req *pb.TransmitRequest) (resp *p w.logger.Trace("Transmit") start := time.Now() if err = w.waitForReady(ctx); err != nil { - return nil, errors.Wrap(err, "Transmit failed") + return nil, errors.Wrap(err, "Transmit call failed") } resp, err = w.client.Transmit(ctx, req) if errors.Is(err, context.DeadlineExceeded) { @@ -272,10 +272,10 @@ func (w *client) Transmit(ctx context.Context, req *pb.TransmitRequest) (resp *p w.consecutiveTimeoutCnt.Store(0) } if err != nil { - w.logger.Warnw("Transmit failed", "err", err, "resp", resp) + w.logger.Warnw("Transmit call failed due to networking error", "err", err, "resp", resp) incRequestStatusMetric(statusFailed) } else { - w.logger.Debugw("Transmit succeeded", "resp", resp) + w.logger.Tracew("Transmit call succeeded", "resp", resp) incRequestStatusMetric(statusSuccess) setRequestLatencyMetric(float64(time.Since(start).Milliseconds())) } From f413f9cb22ff1ef14f366958d7e5fae90e7573c9 Mon Sep 17 00:00:00 2001 From: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Date: Fri, 4 Aug 2023 09:11:31 -0500 Subject: [PATCH 083/270] Functions tooling improvements (#10033) * Functions tooling improvements * added log message --- core/scripts/functions/USAGE.md | 5 +++-- core/scripts/functions/src/files.go | 1 + .../scripts/functions/src/generate_ocr2_config_cmd.go | 11 +++++++++++ core/scripts/functions/src/nodes.go | 3 --- 4 files changed, 15 insertions(+), 5 deletions(-) diff --git a/core/scripts/functions/USAGE.md b/core/scripts/functions/USAGE.md index b3102b4bb36..59883946f2b 100644 --- a/core/scripts/functions/USAGE.md +++ b/core/scripts/functions/USAGE.md @@ -28,6 +28,7 @@ Initial set of commands: - `generate-ocr2config` generates `FunctionsOracleConfig.json` that is consumed by contracts tooling. - If manual configuration is preferred instead of automatically fetching the required parameters from the nodes, create a file that follows the same format as `src/sample_keys.json` and enter the required parameters which can be found on each node's Key Management page in the UI. Note that the bootstrap node is not included in this file. The path to this file should be entered for the `-keys` parameter instead of using the `-nodes` parameter. + - When using the `-nodes` parameter, a `DONPublicKeys.json` file will be generated. This can be used to simplify the creation of the `keyGenConfig.json` file when generating threshold keys with the [Functions admin tooling](https://github.com/smartcontractkit/functions-admin-tooling/blob/main/threshold_key_manager/README.md). - Use `src/sample_config.json` as a template for the `-config` file. - `generate-jobspecs` generates Job Specs (toml) for each node based on its role. - Jobspecs can also be created manually by swapping the relevant values in the `toml` files. @@ -41,13 +42,13 @@ Each command has its own parameters. Simply run a command without parameters to - The current implementation expects a single bootstrap node and a few oracle nodes. Bootstrap node must come first in the nodes list file. -- You may or may not specify `https://` prefix for hosts, the tool will handle this. +- You must provide the `http://` or `https://` prefix for hosts - Any command would terminate immediately with the first issue detected. - `deploy-jobspecs` command does NOT check for the existing jobs, be careful. - `deploy-jobspecs` command does not deploy bridges, they should exist prior to execution. - The tooling does not interact with chains/contracts. -5. Future enhancements +1. Future enhancements - Add `deploy-bridges` command. - For NOPs: make commands to run against a single node with terminal authorization. diff --git a/core/scripts/functions/src/files.go b/core/scripts/functions/src/files.go index c9de82a31a7..a388413ef5f 100644 --- a/core/scripts/functions/src/files.go +++ b/core/scripts/functions/src/files.go @@ -13,6 +13,7 @@ const ( templatesDir = "templates" artefactsDir = "artefacts" ocr2ConfigJson = "FunctionsOracleConfig.json" + ocr2PublicKeysJSON = "OCR2PublicKeys.json" bootstrapSpecTemplate = "bootstrap.toml" oracleSpecTemplate = "oracle.toml" ) diff --git a/core/scripts/functions/src/generate_ocr2_config_cmd.go b/core/scripts/functions/src/generate_ocr2_config_cmd.go index 1fca78368dc..2681adfcd6b 100644 --- a/core/scripts/functions/src/generate_ocr2_config_cmd.go +++ b/core/scripts/functions/src/generate_ocr2_config_cmd.go @@ -155,6 +155,17 @@ func (g *generateOCR2Config) Run(args []string) { } else { nodes := mustReadNodesList(*nodesFile) nca = mustFetchNodesKeys(*chainID, nodes)[1:] // ignore boot node + + nodePublicKeys, err := json.MarshalIndent(nca, "", " ") + if err != nil { + panic(err) + } + filepath := filepath.Join(artefactsDir, ocr2PublicKeysJSON) + err = os.WriteFile(filepath, nodePublicKeys, 0600) + if err != nil { + panic(err) + } + fmt.Println("Functions OCR2 public keys have been saved to:", filepath) } onchainPubKeys := []common.Address{} diff --git a/core/scripts/functions/src/nodes.go b/core/scripts/functions/src/nodes.go index dd69c94a3a2..20f392f8086 100644 --- a/core/scripts/functions/src/nodes.go +++ b/core/scripts/functions/src/nodes.go @@ -45,9 +45,6 @@ func mustReadNodesList(path string) []*node { if len(s) != 3 { helpers.PanicErr(errors.New("wrong nodes list format")) } - if !strings.HasPrefix(s[0], "https://") { - s[0] = "https://" + s[0] - } if strings.Contains(s[0], "boot") && hasBoot { helpers.PanicErr(errors.New("the single boot node must come first")) } From a6c2ba1a9d56658bedfc38e5829622a3dac5112c Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Fri, 4 Aug 2023 18:24:42 +0300 Subject: [PATCH 084/270] Log filter store (#10065) * upkeep filter store * integrate upkeep filter store and provider * fix lint * review fixes * review fixes --- .../evm21/logprovider/filter_store.go | 163 ++++++++++++++++++ .../evm21/logprovider/filter_store_test.go | 83 +++++++++ .../evm21/logprovider/integration_test.go | 8 +- .../ocr2keeper/evm21/logprovider/provider.go | 160 ++++++++--------- .../evm21/logprovider/provider_life_cycle.go | 33 ++-- .../logprovider/provider_life_cycle_test.go | 4 +- .../evm21/logprovider/provider_test.go | 120 +++++++------ .../ocr2/plugins/ocr2keeper/evm21/registry.go | 10 +- 8 files changed, 404 insertions(+), 177 deletions(-) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go new file mode 100644 index 00000000000..fe6f6ffeead --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go @@ -0,0 +1,163 @@ +package logprovider + +import ( + "math/big" + "sync" + + "github.com/ethereum/go-ethereum/common" + "golang.org/x/time/rate" +) + +type UpkeepFilterStore interface { + GetIDs(selector func(upkeepFilter) bool) []*big.Int + UpdateFilters(updater func(upkeepFilter, upkeepFilter) upkeepFilter, filters ...upkeepFilter) + Has(id *big.Int) bool + RangeFiltersByIDs(iterator func(int, upkeepFilter), ids ...*big.Int) + GetFilters(selector func(upkeepFilter) bool) []upkeepFilter + AddActiveUpkeeps(filters ...upkeepFilter) + RemoveActiveUpkeeps(filters ...upkeepFilter) + Size() int +} + +var _ UpkeepFilterStore = &upkeepFilterStore{} + +type upkeepFilter struct { + addr []byte + topics []common.Hash + upkeepID *big.Int + // lastPollBlock is the last block number the logs were fetched for this upkeep + // used by log event provider. + lastPollBlock int64 + // blockLimiter is used to limit the number of blocks to fetch logs for an upkeep. + // used by log event provider. + blockLimiter *rate.Limiter + // lastRePollBlock is the last block number the logs were recovered for this upkeep + // used by log recoverer. + lastRePollBlock int64 +} + +type upkeepFilterStore struct { + lock *sync.RWMutex + // filters is a map of upkeepID to upkeepFilter + filters map[string]upkeepFilter +} + +func NewUpkeepFilterStore() *upkeepFilterStore { + return &upkeepFilterStore{ + lock: &sync.RWMutex{}, + filters: make(map[string]upkeepFilter), + } +} + +func (s *upkeepFilterStore) GetIDs(selector func(upkeepFilter) bool) []*big.Int { + s.lock.RLock() + defer s.lock.RUnlock() + + if selector == nil { + // noop selector returns true for all filters + selector = func(upkeepFilter) bool { return true } + } + + var ids []*big.Int + for _, f := range s.filters { + if selector(f) { + ids = append(ids, f.upkeepID) + } + } + + return ids +} + +func (s *upkeepFilterStore) UpdateFilters(resolveUpdated func(upkeepFilter, upkeepFilter) upkeepFilter, filters ...upkeepFilter) { + s.lock.Lock() + defer s.lock.Unlock() + + if resolveUpdated == nil { + // noop resolveUpdated will use the newer filter + resolveUpdated = func(_ upkeepFilter, f upkeepFilter) upkeepFilter { return f } + } + + for _, f := range filters { + uid := f.upkeepID.String() + orig, ok := s.filters[uid] + if !ok { + // not found, turned inactive probably + continue + } + updated := resolveUpdated(orig, f) + s.filters[uid] = updated + } +} + +func (s *upkeepFilterStore) Has(id *big.Int) bool { + s.lock.RLock() + defer s.lock.RUnlock() + + _, ok := s.filters[id.String()] + return ok +} + +func (s *upkeepFilterStore) RangeFiltersByIDs(iterator func(int, upkeepFilter), ids ...*big.Int) { + s.lock.RLock() + defer s.lock.RUnlock() + + if iterator == nil { + // noop iterator does nothing + iterator = func(int, upkeepFilter) {} + } + + for i, id := range ids { + f, ok := s.filters[id.String()] + if !ok { + // in case the filter is not found, we still want to call the iterator + // with an empty filter, so + iterator(i, upkeepFilter{upkeepID: id}) + } else { + iterator(i, f) + } + } +} + +func (s *upkeepFilterStore) GetFilters(selector func(upkeepFilter) bool) []upkeepFilter { + s.lock.RLock() + defer s.lock.RUnlock() + + if selector == nil { + // noop selector returns true for all filters + selector = func(upkeepFilter) bool { return true } + } + + var filters []upkeepFilter + for _, f := range s.filters { + if selector(f) { + filters = append(filters, f) + } + } + return filters +} + +func (s *upkeepFilterStore) AddActiveUpkeeps(filters ...upkeepFilter) { + s.lock.Lock() + defer s.lock.Unlock() + + for _, f := range filters { + s.filters[f.upkeepID.String()] = f + } +} + +func (s *upkeepFilterStore) RemoveActiveUpkeeps(filters ...upkeepFilter) { + s.lock.Lock() + defer s.lock.Unlock() + + for _, f := range filters { + uid := f.upkeepID.String() + delete(s.filters, uid) + } +} + +func (s *upkeepFilterStore) Size() int { + s.lock.RLock() + defer s.lock.RUnlock() + + return len(s.filters) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go new file mode 100644 index 00000000000..91c32409b80 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go @@ -0,0 +1,83 @@ +package logprovider + +import ( + "math/big" + "sync" + "testing" + + "github.com/stretchr/testify/require" +) + +func TestFilterStore_CRUD(t *testing.T) { + tests := []struct { + name string + initial []upkeepFilter + toAdd []upkeepFilter + expectedPostAdd []upkeepFilter + toRemove []upkeepFilter + expectedPostRemove []upkeepFilter + }{ + { + "empty", + []upkeepFilter{}, + []upkeepFilter{}, + []upkeepFilter{}, + []upkeepFilter{}, + []upkeepFilter{}, + }, + { + "add rm one", + []upkeepFilter{}, + []upkeepFilter{{upkeepID: big.NewInt(1)}}, + []upkeepFilter{{upkeepID: big.NewInt(1)}}, + []upkeepFilter{{upkeepID: big.NewInt(1)}}, + []upkeepFilter{}, + }, + { + "add rm multiple", + []upkeepFilter{}, + []upkeepFilter{{upkeepID: big.NewInt(1)}, {upkeepID: big.NewInt(2)}}, + []upkeepFilter{{upkeepID: big.NewInt(1)}, {upkeepID: big.NewInt(2)}}, + []upkeepFilter{{upkeepID: big.NewInt(1)}}, + []upkeepFilter{{upkeepID: big.NewInt(2)}}, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + s := NewUpkeepFilterStore() + s.AddActiveUpkeeps(tc.initial...) + require.Equal(t, len(tc.initial), len(s.GetIDs(nil))) + s.AddActiveUpkeeps(tc.toAdd...) + require.Equal(t, len(tc.expectedPostAdd), s.Size()) + require.Equal(t, len(tc.expectedPostAdd), len(s.GetFilters(func(f upkeepFilter) bool { return true }))) + s.RemoveActiveUpkeeps(tc.toRemove...) + require.Equal(t, len(tc.expectedPostRemove), len(s.GetIDs(func(upkeepFilter) bool { return true }))) + }) + } +} + +func TestFilterStore_Concurrency(t *testing.T) { + s := NewUpkeepFilterStore() + var wg sync.WaitGroup + + wg.Add(1) + go func() { + defer wg.Done() + s.AddActiveUpkeeps(upkeepFilter{upkeepID: big.NewInt(1)}) + s.AddActiveUpkeeps(upkeepFilter{upkeepID: big.NewInt(2)}) + }() + wg.Add(1) + go func() { + defer wg.Done() + s.AddActiveUpkeeps(upkeepFilter{upkeepID: big.NewInt(2)}) + }() + + go func() { + _ = s.GetIDs(nil) + }() + + wg.Wait() + + require.Equal(t, 2, s.Size()) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index d9293682d91..c486ae02559 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -56,7 +56,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { n := 10 - ids, addrs, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) + _, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) lp.PollAndSaveLogs(ctx, int64(n)) go func() { @@ -97,10 +97,6 @@ func TestIntegration_LogEventProvider(t *testing.T) { }() defer logProvider.Close() - for i, addr := range addrs { - id := ids[i] - require.NoError(t, logProvider.RegisterFilter(id, newPlainLogTriggerConfig(addr))) - } logsAfterRestart, _ := logProvider.GetLogs(ctx) require.GreaterOrEqual(t, len(logsAfterRestart), 0, "logs should have been marked visited") @@ -328,7 +324,7 @@ func setupLogProvider(t *testing.T, db *sqlx.DB, backend *backends.SimulatedBack lggr := logger.TestLogger(t) logDataABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) require.NoError(t, err) - logProvider := logprovider.New(lggr, lp, logprovider.NewLogEventsPacker(logDataABI), opts) + logProvider := logprovider.New(lggr, lp, logprovider.NewLogEventsPacker(logDataABI), logprovider.NewUpkeepFilterStore(), opts) return logProvider, lp, ethClient } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index c924a666f14..9f101e4baeb 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -8,12 +8,14 @@ import ( "math/big" "runtime" "sync" + "sync/atomic" "time" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" "go.uber.org/multierr" - "golang.org/x/time/rate" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -33,17 +35,6 @@ var ( // LogTriggerConfig is an alias for log trigger config. type LogTriggerConfig automation_utils_2_1.LogTriggerConfig -// upkeepFilterEntry holds the upkeep filter, rate limiter and last polled block. -type upkeepFilterEntry struct { - id *big.Int - filter logpoller.Filter - cfg LogTriggerConfig - // lastPollBlock is the last block number the logs were fetched for this upkeep - lastPollBlock int64 - // blockLimiter is used to limit the number of blocks to fetch logs for an upkeep - blockLimiter *rate.Limiter -} - type LogEventProvider interface { // Start starts the log event provider. Start(ctx context.Context) error @@ -60,6 +51,7 @@ type LogEventProvider interface { type LogEventProviderTest interface { LogEventProvider ReadLogs(ctx context.Context, force bool, ids ...*big.Int) error + CurrentPartitionIdx() uint64 } var _ keepersflows.PayloadBuilder = &logEventProvider{} @@ -75,27 +67,29 @@ type logEventProvider struct { packer LogDataPacker - lock sync.RWMutex - active map[string]upkeepFilterEntry + lock sync.RWMutex - buffer *logEventBuffer + filterStore UpkeepFilterStore + buffer *logEventBuffer opts *LogEventProviderOptions + + currentPartitionIdx uint64 } -func New(lggr logger.Logger, poller logpoller.LogPoller, packer LogDataPacker, opts *LogEventProviderOptions) *logEventProvider { +func New(lggr logger.Logger, poller logpoller.LogPoller, packer LogDataPacker, filterStore UpkeepFilterStore, opts *LogEventProviderOptions) *logEventProvider { if opts == nil { opts = new(LogEventProviderOptions) } opts.Defaults() return &logEventProvider{ - packer: packer, - lggr: lggr.Named("KeepersRegistry.LogEventProvider"), - buffer: newLogEventBuffer(lggr, opts.LogBufferSize, opts.BufferMaxBlockSize, opts.AllowedLogsPerBlock), - poller: poller, - lock: sync.RWMutex{}, - active: make(map[string]upkeepFilterEntry), - opts: opts, + packer: packer, + lggr: lggr.Named("KeepersRegistry.LogEventProvider"), + buffer: newLogEventBuffer(lggr, opts.LogBufferSize, opts.BufferMaxBlockSize, opts.AllowedLogsPerBlock), + poller: poller, + lock: sync.RWMutex{}, + opts: opts, + filterStore: filterStore, } } @@ -127,7 +121,6 @@ func (p *logEventProvider) Close() error { p.lock.Lock() defer p.lock.Unlock() - p.active = make(map[string]upkeepFilterEntry) if p.cancel != nil { p.cancel() } @@ -178,7 +171,7 @@ func (p *logEventProvider) ReadLogs(ctx context.Context, force bool, ids ...*big } entries := p.getEntries(latest, force, ids...) - err = p.readLogs(ctx, latest, entries...) + err = p.readLogs(ctx, latest, entries) p.updateEntriesLastPoll(entries) // p.lggr.Debugw("read logs for entries", "latestBlock", latest, "entries", len(entries), "err", err) if err != nil { @@ -188,6 +181,10 @@ func (p *logEventProvider) ReadLogs(ctx context.Context, force bool, ids ...*big return nil } +func (p *logEventProvider) CurrentPartitionIdx() uint64 { + return atomic.LoadUint64(&p.currentPartitionIdx) +} + // scheduleReadJobs starts a scheduler that pushed ids to readQ for reading logs in the background. func (p *logEventProvider) scheduleReadJobs(pctx context.Context, execute func([]*big.Int)) error { ctx, cancel := context.WithCancel(pctx) @@ -197,12 +194,13 @@ func (p *logEventProvider) scheduleReadJobs(pctx context.Context, execute func([ defer ticker.Stop() h := sha256.New() - partitionIdx := 0 + + partitionIdx := p.CurrentPartitionIdx() for { select { case <-ticker.C: - ids := p.getPartitionIds(h, partitionIdx) + ids := p.getPartitionIds(h, int(partitionIdx)) if len(ids) > 0 { maxBatchSize := p.opts.ReadMaxBatchSize for len(ids) > maxBatchSize { @@ -214,6 +212,7 @@ func (p *logEventProvider) scheduleReadJobs(pctx context.Context, execute func([ execute(ids) } partitionIdx++ + atomic.StoreUint64(&p.currentPartitionIdx, partitionIdx) case <-ctx.Done(): return nil } @@ -242,82 +241,69 @@ func (p *logEventProvider) startReader(pctx context.Context, readQ <-chan []*big // getPartitionIds returns the upkeepIDs for the given partition and the number of partitions. // Partitioning is done by hashing the upkeepID and taking the modulus of the number of partitions. func (p *logEventProvider) getPartitionIds(hashFn hash.Hash, partition int) []*big.Int { - p.lock.RLock() - defer p.lock.RUnlock() - - numOfPartitions := len(p.active) / p.opts.ReadMaxBatchSize + numOfPartitions := p.filterStore.Size() / p.opts.ReadMaxBatchSize if numOfPartitions < 1 { numOfPartitions = 1 } partition = partition % numOfPartitions - var ids []*big.Int - for _, entry := range p.active { - if len(entry.filter.Addresses) == 0 { - continue + ids := p.filterStore.GetIDs(func(f upkeepFilter) bool { + if len(f.addr) == 0 { + return false } - n, err := hashFn.Write(entry.filter.Addresses[0].Bytes()) + n, err := hashFn.Write(f.addr) if err != nil || n == 0 { - p.lggr.Warnw("failed to hash upkeep address", "err", err, "addr", entry.filter.Addresses[0]) - continue + p.lggr.Warnw("failed to hash upkeep address", "err", err, "addr", hexutil.Encode(f.addr)) + return false } h := hashFn.Sum(nil) + defer hashFn.Reset() // taking only 6 bytes to avoid working with big numbers i := big.NewInt(0).SetBytes(h[len(h)-6:]) - if int(i.Int64())%numOfPartitions == partition { - ids = append(ids, entry.id) - } - hashFn.Reset() - } + return int(i.Int64())%numOfPartitions == partition + }) return ids } -func (p *logEventProvider) updateEntriesLastPoll(entries []*upkeepFilterEntry) { - p.lock.Lock() - defer p.lock.Unlock() - - for _, entry := range entries { - // for successful queries, the last poll block was updated - orig, ok := p.active[entry.id.String()] - if !ok { - continue // entry was removed - } - if entry.lastPollBlock == orig.lastPollBlock { - continue +func (p *logEventProvider) updateEntriesLastPoll(entries []upkeepFilter) { + p.filterStore.UpdateFilters(func(orig, f upkeepFilter) upkeepFilter { + if f.lastPollBlock > orig.lastPollBlock { + orig.lastPollBlock = f.lastPollBlock } - orig.lastPollBlock = entry.lastPollBlock - p.active[entry.id.String()] = orig - } + return orig + }, entries...) } // getEntries returns the filters for the given upkeepIDs, // returns empty filter for inactive upkeeps. -func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big.Int) []*upkeepFilterEntry { - p.lock.RLock() - defer p.lock.RUnlock() - - var filters []*upkeepFilterEntry - for _, id := range ids { - entry, ok := p.active[id.String()] - if !ok { // entry not found, could be inactive upkeep - p.lggr.Debugw("upkeep filter not found", "upkeep", id.String()) - filters = append(filters, &upkeepFilterEntry{id: id}) - continue +func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big.Int) []upkeepFilter { + var filters []upkeepFilter + p.filterStore.RangeFiltersByIDs(func(i int, f upkeepFilter) { + if len(f.addr) == 0 { // not found + p.lggr.Debugw("upkeep filter not found", "upkeep", f.upkeepID.String()) + filters = append(filters, f) + return } - if !force && entry.lastPollBlock > latestBlock { - p.lggr.Debugw("already polled latest block", "entry.lastPollBlock", entry.lastPollBlock, "latestBlock", latestBlock, "upkeep", id.String()) - filters = append(filters, &upkeepFilterEntry{id: id, lastPollBlock: entry.lastPollBlock}) - continue + if !force && f.lastPollBlock > latestBlock { + p.lggr.Debugw("already polled latest block", "entry.lastPollBlock", f.lastPollBlock, "latestBlock", latestBlock, "upkeep", f.upkeepID.String()) + filters = append(filters, upkeepFilter{upkeepID: f.upkeepID}) + return } - // recreating the struct to be thread safe - filters = append(filters, &upkeepFilterEntry{ - id: id, - filter: p.newLogFilter(id, entry.cfg), - lastPollBlock: entry.lastPollBlock, - blockLimiter: entry.blockLimiter, + // cloning struct to be thread safe + topics := make([]common.Hash, len(f.topics)) + copy(topics, f.topics) + addr := make([]byte, len(f.addr)) + copy(addr, f.addr) + filters = append(filters, upkeepFilter{ + upkeepID: f.upkeepID, + topics: topics, + addr: addr, + lastPollBlock: f.lastPollBlock, + lastRePollBlock: f.lastRePollBlock, + blockLimiter: f.blockLimiter, }) - } + }, ids...) return filters } @@ -327,16 +313,16 @@ func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big // // TODO: batch entries by contract address and call log poller once per contract address // NOTE: the entries are already grouped by contract address -func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries ...*upkeepFilterEntry) (merr error) { +func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries []upkeepFilter) (merr error) { // mainLggr := p.lggr.With("latestBlock", latest) logBlocksLookback := p.opts.LogBlocksLookback maxBurst := int(logBlocksLookback*2 + 1) for _, entry := range entries { - if len(entry.filter.Addresses) == 0 { + if len(entry.addr) == 0 { continue } - // lggr := mainLggr.With("upkeep", entry.id.String(), "addrs", entry.filter.Addresses, "sigs", entry.filter.EventSigs) + // lggr := mainLggr.With("upkeep", entry.upkeepID.String(), "addrs", entry.addr, "sigs", entry.topics) start := entry.lastPollBlock if start == 0 || start < latest-logBlocksLookback { // long range or first time polling, @@ -346,7 +332,7 @@ func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries . } resv := entry.blockLimiter.ReserveN(time.Now(), int(latest-start)) if !resv.OK() { - merr = multierr.Append(merr, fmt.Errorf("%s: %s", BlockLimitExceeded, entry.id.String())) + merr = multierr.Append(merr, fmt.Errorf("%s: %s", BlockLimitExceeded, entry.upkeepID.String())) continue } start = start - p.opts.LookbackBuffer // adding a buffer to check for reorgs @@ -354,13 +340,13 @@ func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries . start = 0 } // lggr = lggr.With("startBlock", start) - logs, err := p.poller.LogsWithSigs(start, latest, entry.filter.EventSigs, entry.filter.Addresses[0], pg.WithParentCtx(ctx)) + logs, err := p.poller.LogsWithSigs(start, latest, entry.topics, common.BytesToAddress(entry.addr), pg.WithParentCtx(ctx)) if err != nil { resv.Cancel() // cancels limit reservation as we failed to get logs if ctx.Err() != nil { return multierr.Append(merr, ctx.Err()) } - merr = multierr.Append(merr, fmt.Errorf("failed to get logs for upkeep %s: %w", entry.id.String(), err)) + merr = multierr.Append(merr, fmt.Errorf("failed to get logs for upkeep %s: %w", entry.upkeepID.String(), err)) continue } // if this limiter's burst was set to the max, @@ -369,7 +355,7 @@ func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries . resv.Cancel() // cancel the reservation as we are resetting the burst entry.blockLimiter.SetBurst(p.opts.BlockLimitBurst) } - added := p.buffer.enqueue(entry.id, logs...) + added := p.buffer.enqueue(entry.upkeepID, logs...) // if we added logs or couldn't find, update the last poll block if added > 0 || len(logs) == 0 { entry.lastPollBlock = latest diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go index e8d65ee9e31..f9ac19207c0 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go @@ -17,24 +17,21 @@ func (p *logEventProvider) RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfi } filter := p.newLogFilter(upkeepID, cfg) - // TODO: optimize locking, currently we lock the whole map while registering the filter - p.lock.Lock() - defer p.lock.Unlock() - - uid := upkeepID.String() - if _, ok := p.active[uid]; ok { + if p.filterStore.Has(upkeepID) { // TODO: check for updates - return errors.Errorf("filter for upkeep with id %s already registered", uid) + return errors.Errorf("filter for upkeep with id %s already registered", upkeepID.String()) } if err := p.poller.RegisterFilter(filter); err != nil { return errors.Wrap(err, "failed to register upkeep filter") } - p.active[uid] = upkeepFilterEntry{ - id: upkeepID, - filter: filter, - cfg: cfg, + topics := make([]common.Hash, len(filter.EventSigs)) + copy(topics, filter.EventSigs) + p.filterStore.AddActiveUpkeeps(upkeepFilter{ + upkeepID: upkeepID, + addr: filter.Addresses[0].Bytes(), + topics: topics, blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), - } + }) return nil } @@ -42,20 +39,20 @@ func (p *logEventProvider) RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfi func (p *logEventProvider) UnregisterFilter(upkeepID *big.Int) error { err := p.poller.UnregisterFilter(p.filterName(upkeepID), nil) if err == nil { - p.lock.Lock() - delete(p.active, upkeepID.String()) - p.lock.Unlock() + p.filterStore.RemoveActiveUpkeeps(upkeepFilter{ + upkeepID: upkeepID, + }) } return errors.Wrap(err, "failed to unregister upkeep filter") } // newLogFilter creates logpoller.Filter from the given upkeep config func (p *logEventProvider) newLogFilter(upkeepID *big.Int, cfg LogTriggerConfig) logpoller.Filter { - sigs := p.getFiltersBySelector(cfg.FilterSelector, cfg.Topic1[:], cfg.Topic2[:], cfg.Topic3[:]) - sigs = append([]common.Hash{common.BytesToHash(cfg.Topic0[:])}, sigs...) + topics := p.getFiltersBySelector(cfg.FilterSelector, cfg.Topic1[:], cfg.Topic2[:], cfg.Topic3[:]) + topics = append([]common.Hash{common.BytesToHash(cfg.Topic0[:])}, topics...) return logpoller.Filter{ Name: p.filterName(upkeepID), - EventSigs: sigs, + EventSigs: topics, Addresses: []common.Address{cfg.ContractAddress}, Retention: p.opts.LogRetention, } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go index 356df382e3b..e300f375e98 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go @@ -56,7 +56,7 @@ func TestLogEventProvider_LifeCycle(t *testing.T) { mp.On("RegisterFilter", mock.Anything).Return(nil) mp.On("UnregisterFilter", mock.Anything, mock.Anything).Return(nil) } - p := New(logger.TestLogger(t), mp, &mockedPacker{}, nil) + p := New(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) err := p.RegisterFilter(tc.upkeepID, tc.upkeepCfg) if tc.errored { require.Error(t, err) @@ -183,7 +183,7 @@ func TestLogEventProvider_GetFiltersBySelector(t *testing.T) { }, } - p := New(logger.TestLogger(t), nil, &mockedPacker{}, nil) + p := New(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go index 2e7c10caab1..7368dea5621 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go @@ -4,6 +4,7 @@ import ( "context" "fmt" "math/big" + "runtime" "testing" "time" @@ -21,67 +22,59 @@ import ( ) func TestLogEventProvider_GetEntries(t *testing.T) { - p := New(logger.TestLogger(t), nil, &mockedPacker{}, nil) + p := New(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) _, f := newEntry(p, 1) - p.lock.Lock() - p.active[f.id.String()] = f - p.lock.Unlock() + p.filterStore.AddActiveUpkeeps(f) t.Run("no entries", func(t *testing.T) { entries := p.getEntries(0, false, big.NewInt(0)) require.Len(t, entries, 1) - require.Equal(t, len(entries[0].filter.Addresses), 0) + require.Equal(t, len(entries[0].addr), 0) }) t.Run("has entry with lower lastPollBlock", func(t *testing.T) { - entries := p.getEntries(0, false, f.id) + entries := p.getEntries(0, false, f.upkeepID) require.Len(t, entries, 1) - require.Greater(t, len(entries[0].filter.Addresses), 0) - entries = p.getEntries(10, false, f.id) + require.Greater(t, len(entries[0].addr), 0) + entries = p.getEntries(10, false, f.upkeepID) require.Len(t, entries, 1) - require.Greater(t, len(entries[0].filter.Addresses), 0) + require.Greater(t, len(entries[0].addr), 0) }) t.Run("has entry with higher lastPollBlock", func(t *testing.T) { _, f := newEntry(p, 2) f.lastPollBlock = 3 - p.lock.Lock() - p.active[f.id.String()] = f - p.lock.Unlock() + p.filterStore.AddActiveUpkeeps(f) - entries := p.getEntries(1, false, f.id) + entries := p.getEntries(1, false, f.upkeepID) require.Len(t, entries, 1) - require.Equal(t, len(entries[0].filter.Addresses), 0) + require.Equal(t, len(entries[0].addr), 0) - entries = p.getEntries(1, true, f.id) + entries = p.getEntries(1, true, f.upkeepID) require.Len(t, entries, 1) - require.Greater(t, len(entries[0].filter.Addresses), 0) + require.Greater(t, len(entries[0].addr), 0) }) } func TestLogEventProvider_UpdateEntriesLastPoll(t *testing.T) { - p := New(logger.TestLogger(t), nil, &mockedPacker{}, nil) + p := New(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) n := 10 - entries := map[string]upkeepFilterEntry{} + // entries := map[string]upkeepFilter{} for i := 0; i < n; i++ { _, f := newEntry(p, i+1) - entries[f.id.String()] = f + p.filterStore.AddActiveUpkeeps(f) } - p.lock.Lock() - p.active = entries - p.lock.Unlock() t.Run("no entries", func(t *testing.T) { _, f := newEntry(p, n*2) f.lastPollBlock = 10 - p.updateEntriesLastPoll([]*upkeepFilterEntry{&f}) + p.updateEntriesLastPoll([]upkeepFilter{f}) - p.lock.RLock() - defer p.lock.RUnlock() - for _, f := range p.active { + filters := p.filterStore.GetFilters(nil) + for _, f := range filters { require.Equal(t, int64(0), f.lastPollBlock) } }) @@ -91,22 +84,20 @@ func TestLogEventProvider_UpdateEntriesLastPoll(t *testing.T) { f2.lastPollBlock = 10 _, f1 := newEntry(p, n-1) f1.lastPollBlock = 10 - p.updateEntriesLastPoll([]*upkeepFilterEntry{&f1, &f2}) - - p.lock.RLock() - e := p.active[f1.id.String()] - require.Equal(t, int64(10), e.lastPollBlock) - e = p.active[f2.id.String()] - require.Equal(t, int64(10), e.lastPollBlock) - p.lock.RUnlock() + p.updateEntriesLastPoll([]upkeepFilter{f1, f2}) + + p.filterStore.RangeFiltersByIDs(func(_ int, f upkeepFilter) { + require.Equal(t, int64(10), f.lastPollBlock) + }, f1.upkeepID, f2.upkeepID) + // update with same block - p.updateEntriesLastPoll([]*upkeepFilterEntry{&f1}) + p.updateEntriesLastPoll([]upkeepFilter{f1}) + // checking other entries are not updated _, f := newEntry(p, 1) - p.lock.RLock() - defer p.lock.RUnlock() - e = p.active[f.id.String()] - require.Equal(t, int64(0), e.lastPollBlock) + p.filterStore.RangeFiltersByIDs(func(_ int, f upkeepFilter) { + require.Equal(t, int64(0), f.lastPollBlock) + }, f.upkeepID) }) } @@ -180,20 +171,18 @@ func TestLogEventProvider_ScheduleReadJobs(t *testing.T) { ctx, cancel := context.WithCancel(context.Background()) defer cancel() - tick := 10 * time.Millisecond - p := New(logger.TestLogger(t), mp, &mockedPacker{}, &LogEventProviderOptions{ + readInterval := 10 * time.Millisecond + p := New(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), &LogEventProviderOptions{ ReadMaxBatchSize: tc.maxBatchSize, - ReadInterval: tick, + ReadInterval: readInterval, }) var ids []*big.Int - p.lock.Lock() for i, id := range tc.ids { _, f := newEntry(p, id, tc.addrs[i]) - p.active[f.id.String()] = f - ids = append(ids, f.id) + p.filterStore.AddActiveUpkeeps(f) + ids = append(ids, f.upkeepID) } - p.lock.Unlock() reads := make(chan []*big.Int, 100) @@ -207,9 +196,9 @@ func TestLogEventProvider_ScheduleReadJobs(t *testing.T) { }) }(ctx) - timeout := tick*time.Duration((1+len(tc.ids)/tc.maxBatchSize))*4 + 1 - <-time.After(timeout) - timeoutTicker := time.NewTicker(timeout) + batches := (len(tc.ids) / tc.maxBatchSize) + 1 + + timeoutTicker := time.NewTicker(readInterval * time.Duration(batches*10)) defer timeoutTicker.Stop() got := map[string]int{} @@ -225,12 +214,19 @@ func TestLogEventProvider_ScheduleReadJobs(t *testing.T) { } case <-ctx.Done(): break readLoop + default: + if p.CurrentPartitionIdx() > uint64(batches+1) { + break readLoop + } } + runtime.Gosched() } - require.Len(t, got, len(ids)) + require.Equal(t, len(ids), len(got)) for _, id := range ids { - require.GreaterOrEqual(t, got[id.String()], 1, "id %s", id.String()) + _, ok := got[id.String()] + require.True(t, ok, "id not found %s", id.String()) + require.GreaterOrEqual(t, got[id.String()], 1, "id don't have schdueled job %s", id.String()) } }) } @@ -252,13 +248,13 @@ func TestLogEventProvider_ReadLogs(t *testing.T) { }, }, nil) - p := New(logger.TestLogger(t), mp, &mockedPacker{}, nil) + p := New(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) var ids []*big.Int for i := 0; i < 10; i++ { cfg, f := newEntry(p, i+1) - ids = append(ids, f.id) - require.NoError(t, p.RegisterFilter(f.id, cfg)) + ids = append(ids, f.upkeepID) + require.NoError(t, p.RegisterFilter(f.upkeepID, cfg)) } t.Run("no entries", func(t *testing.T) { @@ -277,7 +273,7 @@ func TestLogEventProvider_ReadLogs(t *testing.T) { } -func newEntry(p *logEventProvider, i int, args ...string) (LogTriggerConfig, upkeepFilterEntry) { +func newEntry(p *logEventProvider, i int, args ...string) (LogTriggerConfig, upkeepFilter) { id := ocr2keepers.UpkeepIdentifier(append(common.LeftPadBytes([]byte{1}, 16), []byte(fmt.Sprintf("%d", i))...)) uid := big.NewInt(0).SetBytes(id) for len(args) < 2 { @@ -289,12 +285,14 @@ func newEntry(p *logEventProvider, i int, args ...string) (LogTriggerConfig, upk FilterSelector: 0, Topic0: common.HexToHash(topic0), } - f := upkeepFilterEntry{ - id: uid, - filter: p.newLogFilter(uid, cfg), - cfg: cfg, - blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), - lastPollBlock: 0, + filter := p.newLogFilter(uid, cfg) + eventSigs := make([]common.Hash, len(filter.EventSigs)) + copy(eventSigs, filter.EventSigs) + f := upkeepFilter{ + upkeepID: uid, + addr: filter.Addresses[0].Bytes(), + topics: eventSigs, + blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), } return cfg, f } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 5082a1793dd..06366bde654 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -100,6 +100,9 @@ func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.Mer return nil, fmt.Errorf("%w: failed to create caller for address and backend", ErrInitializationFailure) } + filterStore := logprovider.NewUpkeepFilterStore() + logEventProvider := logprovider.New(lggr, client.LogPoller(), logPacker, filterStore, nil) + r := &EvmRegistry{ ht: client.HeadTracker(), lggr: lggr.Named("EvmRegistry"), @@ -119,8 +122,8 @@ func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.Mer allowListCache: cache.New(DefaultAllowListExpiration, CleanupInterval), }, hc: http.DefaultClient, - enc: EVMAutomationEncoder21{}, - logEventProvider: logprovider.New(lggr, client.LogPoller(), logPacker, nil), // TODO: pass opts + enc: EVMAutomationEncoder21{packer: packer}, + logEventProvider: logEventProvider, } if err := r.registerEvents(client.ID().Uint64(), addr); err != nil { @@ -908,7 +911,8 @@ func (r *EvmRegistry) fetchTriggerConfig(id *big.Int) ([]byte, error) { func (r *EvmRegistry) getBlockHash(blockNumber *big.Int) (common.Hash, error) { block, err := r.client.BlockByNumber(r.ctx, blockNumber) if err != nil { - return [32]byte{}, fmt.Errorf("%w: failed to get latest block", ErrHeadNotAvailable) + return [32]byte{}, err } + return block.Hash(), nil } From 179f1fd1c9db7b1bbfccfb62c1d8b1e4c4ed13fe Mon Sep 17 00:00:00 2001 From: Tate Date: Fri, 4 Aug 2023 10:52:25 -0600 Subject: [PATCH 085/270] updated error logging for failures that didn't have test failures (#10071) --- .github/workflows/ci-core.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 2a4371dbf65..af87a65abfc 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -180,7 +180,7 @@ jobs: run: ./tools/bin/${{ matrix.cmd }} "${{ matrix.split.pkgs }}" - name: Print Filtered Test Results if: failure() - uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@2bb3869750e6e1c2d936fe7179784908981548a4 # v2.2.4 + uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@9a48ff0869aa6cb2753125301f744d5372d669f6 # v2.2.5 with: results-file: ./output.txt output-file: ./output-short.txt From b1c9ce22b2ac0599f4662030b314f778d7debe2e Mon Sep 17 00:00:00 2001 From: Cedric Date: Fri, 4 Aug 2023 19:08:13 +0100 Subject: [PATCH 086/270] Skip TestUpkeepProvider_GetActiveUpkeeps (#10081) --- .../ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go index 664be1705cc..6bb537ae96d 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go @@ -17,6 +17,7 @@ import ( ) func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { + t.Skip() ctx := testutils.Context(t) c := new(clientmocks.Client) From efbe0f655c4e6d2f75e9a4cb2516c28c37d045f4 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Fri, 4 Aug 2023 14:09:08 -0400 Subject: [PATCH 087/270] add trigger to UpkeepPerformed logs (#10073) * add trigger to UpkeepPerformed logs * add dedup key event * update core node to use new UpkeepPerformed event --- .../dev/automation/2_1/KeeperRegistry2_1.sol | 3 +- .../automation/2_1/KeeperRegistryBase2_1.sol | 38 ++-- .../2_1/KeeperRegistryLogicB2_1.sol | 7 + .../2_1/interfaces/IKeeperRegistryMaster.sol | 17 +- .../v0.8/automation/KeeperRegistry2_1.test.ts | 43 ++-- .../i_keeper_registry_master_wrapper_2_1.go | 213 +++++++++++++++-- .../keeper_registry_logic_a_wrapper_2_1.go | 189 +++++++++++++-- .../keeper_registry_logic_b_wrapper_2_1.go | 215 +++++++++++++++--- .../keeper_registry_wrapper_2_1.go | 191 +++++++++++++--- ...rapper-dependency-versions-do-not-edit.txt | 8 +- .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 2 +- .../evm21/transmit_event_provider.go | 15 +- .../evm21/transmit_event_provider_test.go | 28 +-- .../plugins/ocr2keeper/evm21/upkeep_info.go | 4 +- .../ocr2keeper/evm21/upkeep_info_test.go | 5 +- 15 files changed, 785 insertions(+), 193 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol index f03cd734d65..90e50beb02d 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol @@ -96,7 +96,6 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, IE report.linkNative, true ); - upkeepTransmitInfo[i].upkeepTriggerID = _upkeepTriggerID(report.upkeepIds[i], report.triggers[i]); (upkeepTransmitInfo[i].earlyChecksPassed, upkeepTransmitInfo[i].dedupID) = _prePerformChecks( report.upkeepIds[i], report.triggers[i], @@ -167,7 +166,7 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, IE reimbursement + premium, upkeepTransmitInfo[i].gasUsed, upkeepTransmitInfo[i].gasOverhead, - upkeepTransmitInfo[i].upkeepTriggerID + report.triggers[i] ); } } diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index 03c0422edec..54c4aa81f54 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -356,7 +356,6 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { * @member triggerType the type of trigger * @member gasUsed gasUsed by this upkeep in perform * @member gasOverhead gasOverhead for this upkeep - * @member upkeepTriggerID unique ID used to identify an upkeep/trigger combo * @member dedupID unique ID used to dedup an upkeep/trigger combo */ struct UpkeepTransmitInfo { @@ -367,7 +366,6 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { Trigger triggerType; uint256 gasUsed; uint256 gasOverhead; - bytes32 upkeepTriggerID; bytes32 dedupID; } @@ -405,18 +403,19 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { } event AdminPrivilegeConfigSet(address indexed admin, bytes privilegeConfig); - event CancelledUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event CancelledUpkeepReport(uint256 indexed id, bytes trigger); + event DedupKeyAdded(bytes32 indexed dedupKey); event FundsAdded(uint256 indexed id, address indexed from, uint96 amount); event FundsWithdrawn(uint256 indexed id, uint256 amount, address to); - event InsufficientFundsUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event InsufficientFundsUpkeepReport(uint256 indexed id, bytes trigger); event OwnerFundsWithdrawn(uint96 amount); event Paused(address account); event PayeesUpdated(address[] transmitters, address[] payees); event PayeeshipTransferRequested(address indexed transmitter, address indexed from, address indexed to); event PayeeshipTransferred(address indexed transmitter, address indexed from, address indexed to); event PaymentWithdrawn(address indexed transmitter, uint256 indexed amount, address indexed to, address payee); - event ReorgedUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); - event StaleUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event ReorgedUpkeepReport(uint256 indexed id, bytes trigger); + event StaleUpkeepReport(uint256 indexed id, bytes trigger); event UpkeepAdminTransferred(uint256 indexed id, address indexed from, address indexed to); event UpkeepAdminTransferRequested(uint256 indexed id, address indexed from, address indexed to); event UpkeepCanceled(uint256 indexed id, uint64 indexed atBlockHeight); @@ -431,7 +430,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { uint96 totalPayment, uint256 gasUsed, uint256 gasOverhead, - bytes32 upkeepTriggerID + bytes trigger ); event UpkeepPrivilegeConfigSet(uint256 indexed id, bytes privilegeConfig); event UpkeepReceived(uint256 indexed id, uint256 startingBalance, address importedFrom); @@ -746,16 +745,14 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { if (transmitInfo.upkeep.maxValidBlocknumber <= _blockNum()) { // Can happen when an upkeep got cancelled after report was generated. // However we have a CANCELLATION_DELAY of 50 blocks so shouldn't happen in practice - emit CancelledUpkeepReport(upkeepId, transmitInfo.upkeepTriggerID); + emit CancelledUpkeepReport(upkeepId, rawTrigger); return (false, dedupID); } - if (transmitInfo.upkeep.balance < transmitInfo.maxLinkPayment) { // Can happen due to flucutations in gas / link prices - emit InsufficientFundsUpkeepReport(upkeepId, transmitInfo.upkeepTriggerID); + emit InsufficientFundsUpkeepReport(upkeepId, rawTrigger); return (false, dedupID); } - return (true, dedupID); } @@ -770,7 +767,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { ConditionalTrigger memory trigger = abi.decode(rawTrigger, (ConditionalTrigger)); if (trigger.blockNum < transmitInfo.upkeep.lastPerformedBlockNumber) { // Can happen when another report performed this upkeep after this report was generated - emit StaleUpkeepReport(upkeepId, transmitInfo.upkeepTriggerID); + emit StaleUpkeepReport(upkeepId, rawTrigger); return false; } if ( @@ -783,7 +780,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { // 2. blockHash at trigger block number was same as trigger time. This is an optional check which is // applied if DON sends non empty trigger.blockHash. Note: It only works for last 256 blocks on chain // when it is sent - emit ReorgedUpkeepReport(upkeepId, transmitInfo.upkeepTriggerID); + emit ReorgedUpkeepReport(upkeepId, rawTrigger); return false; } return true; @@ -801,11 +798,11 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { trigger.blockNum >= _blockNum() ) { // Reorg protection is same as conditional trigger upkeeps - emit ReorgedUpkeepReport(upkeepId, transmitInfo.upkeepTriggerID); + emit ReorgedUpkeepReport(upkeepId, rawTrigger); return (false, dedupID); } if (s_dedupKeys[dedupID]) { - emit StaleUpkeepReport(upkeepId, transmitInfo.upkeepTriggerID); + emit StaleUpkeepReport(upkeepId, rawTrigger); return (false, dedupID); } return (true, dedupID); @@ -848,6 +845,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { s_upkeep[upkeepID].lastPerformedBlockNumber = uint32(_blockNum()); } else if (upkeepTransmitInfo.triggerType == Trigger.LOG) { s_dedupKeys[upkeepTransmitInfo.dedupID] = true; + emit DedupKeyAdded(upkeepTransmitInfo.dedupID); } } @@ -946,16 +944,6 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { } } - /** - * @dev returns a unique identifier for an upkeep/trigger combo - * @param upkeepID the upkeep id - * @param trigger the raw trigger bytes - * @return upkeepTriggerID the unique identifier for the upkeep/trigger combo - */ - function _upkeepTriggerID(uint256 upkeepID, bytes memory trigger) internal pure returns (bytes32 upkeepTriggerID) { - return keccak256(abi.encodePacked(upkeepID, trigger)); - } - /** * @dev replicates Open Zeppelin's ReentrancyGuard but optimized to fit our storage */ diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol index 18ec3264dba..bc93e0cdb10 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol @@ -502,4 +502,11 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { function getForwarder(uint256 upkeepID) external view returns (IAutomationForwarder) { return s_upkeep[upkeepID].forwarder; } + + /** + * @notice returns the upkeep's forwarder contract + */ + function hasDedupKey(bytes32 dedupKey) external view returns (bool) { + return s_dedupKeys[dedupKey]; + } } diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol index 9d545b116b8..9df7d8da14d 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol @@ -1,4 +1,4 @@ -// abi-checksum: 0xd9f033314bb5bd344295bf9d6a633daaf42f2768b27d4595db0918489938fa58 +// abi-checksum: 0x0199025a18d5956b044baa2131c1d61dd2eef5eb6335edc00633d829045edb7c // SPDX-License-Identifier: MIT // !! THIS FILE WAS AUTOGENERATED BY abi-to-sol v0.6.6. SEE SOURCE BELOW. !! pragma solidity ^0.8.4; @@ -55,7 +55,7 @@ interface IKeeperRegistryMaster { error UpkeepNotNeeded(); error ValueNotChanged(); event AdminPrivilegeConfigSet(address indexed admin, bytes privilegeConfig); - event CancelledUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event CancelledUpkeepReport(uint256 indexed id, bytes trigger); event ConfigSet( uint32 previousConfigBlockNumber, bytes32 configDigest, @@ -67,9 +67,10 @@ interface IKeeperRegistryMaster { uint64 offchainConfigVersion, bytes offchainConfig ); + event DedupKeyAdded(bytes32 indexed dedupKey); event FundsAdded(uint256 indexed id, address indexed from, uint96 amount); event FundsWithdrawn(uint256 indexed id, uint256 amount, address to); - event InsufficientFundsUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event InsufficientFundsUpkeepReport(uint256 indexed id, bytes trigger); event OwnerFundsWithdrawn(uint96 amount); event OwnershipTransferRequested(address indexed from, address indexed to); event OwnershipTransferred(address indexed from, address indexed to); @@ -78,8 +79,8 @@ interface IKeeperRegistryMaster { event PayeeshipTransferRequested(address indexed transmitter, address indexed from, address indexed to); event PayeeshipTransferred(address indexed transmitter, address indexed from, address indexed to); event PaymentWithdrawn(address indexed transmitter, uint256 indexed amount, address indexed to, address payee); - event ReorgedUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); - event StaleUpkeepReport(uint256 indexed id, bytes32 upkeepTriggerID); + event ReorgedUpkeepReport(uint256 indexed id, bytes trigger); + event StaleUpkeepReport(uint256 indexed id, bytes trigger); event Transmitted(bytes32 configDigest, uint32 epoch); event Unpaused(address account); event UpkeepAdminTransferRequested(uint256 indexed id, address indexed from, address indexed to); @@ -96,7 +97,7 @@ interface IKeeperRegistryMaster { uint96 totalPayment, uint256 gasUsed, uint256 gasOverhead, - bytes32 upkeepTriggerID + bytes trigger ); event UpkeepPrivilegeConfigSet(uint256 indexed id, bytes privilegeConfig); event UpkeepReceived(uint256 indexed id, uint256 startingBalance, address importedFrom); @@ -283,6 +284,8 @@ interface IKeeperRegistryMaster { function getUpkeepTriggerConfig(uint256 upkeepId) external view returns (bytes memory); + function hasDedupKey(bytes32 dedupKey) external view returns (bool); + function pause() external; function pauseUpkeep(uint256 id) external; @@ -370,5 +373,5 @@ interface KeeperRegistryBase2_1 { // THIS FILE WAS AUTOGENERATED FROM THE FOLLOWING ABI JSON: /* -[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes32","name":"upkeepTriggerID","type":"bytes32"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfigTypeSafe","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dedupKey","type":"bytes32"}],"name":"DedupKeyAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfigTypeSafe","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"dedupKey","type":"bytes32"}],"name":"hasDedupKey","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] */ diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index f200c042817..a0d370919d7 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -302,7 +302,7 @@ const parseUpkeepPerformedLogs = (receipt: ContractReceipt) => { if ( log.name == registry.interface.events[ - 'UpkeepPerformed(uint256,bool,uint96,uint256,uint256,bytes32)' + 'UpkeepPerformed(uint256,bool,uint96,uint256,uint256,bytes)' ].name ) { parsedLogs.push(log as unknown as UpkeepPerformedEvent) @@ -321,7 +321,7 @@ const parseReorgedUpkeepReportLogs = (receipt: ContractReceipt) => { const log = registry.interface.parseLog(rawLog) if ( log.name == - registry.interface.events['ReorgedUpkeepReport(uint256,bytes32)'].name + registry.interface.events['ReorgedUpkeepReport(uint256,bytes)'].name ) { parsedLogs.push(log as unknown as ReorgedUpkeepReportEvent) } @@ -339,7 +339,7 @@ const parseStaleUpkeepReportLogs = (receipt: ContractReceipt) => { const log = registry.interface.parseLog(rawLog) if ( log.name == - registry.interface.events['StaleUpkeepReport(uint256,bytes32)'].name + registry.interface.events['StaleUpkeepReport(uint256,bytes)'].name ) { parsedLogs.push(log as unknown as StaleUpkeepReportEvent) } @@ -358,7 +358,7 @@ const parseInsufficientFundsUpkeepReportLogs = (receipt: ContractReceipt) => { if ( log.name == registry.interface.events[ - 'InsufficientFundsUpkeepReport(uint256,bytes32)' + 'InsufficientFundsUpkeepReport(uint256,bytes)' ].name ) { parsedLogs.push(log as unknown as InsufficientFundsUpkeepReportEvent) @@ -377,7 +377,7 @@ const parseCancelledUpkeepReportLogs = (receipt: ContractReceipt) => { const log = registry.interface.parseLog(rawLog) if ( log.name == - registry.interface.events['CancelledUpkeepReport(uint256,bytes32)'].name + registry.interface.events['CancelledUpkeepReport(uint256,bytes)'].name ) { parsedLogs.push(log as unknown as CancelledUpkeepReportEvent) } @@ -1192,18 +1192,29 @@ describe('KeeperRegistry2_1', () => { } }) - it('handles duplicate logTriggerIDs', async () => { + it('handles duplicate log triggers', async () => { + const txHash = ethers.utils.randomBytes(32) + const logIndex = 0 + const expectedDedupKey = ethers.utils.solidityKeccak256( + ['uint256', 'bytes32', 'uint32'], + [logUpkeepId, txHash, logIndex], + ) + assert.isFalse(await registry.hasDedupKey(expectedDedupKey)) const tx = await getTransmitTx( registry, keeper1, [logUpkeepId, logUpkeepId], - { txHash: ethers.utils.randomBytes(32), logIndex: 0 }, // will result in the same logTriggerID + { txHash, logIndex }, // will result in the same dedup key ) const receipt = await tx.wait() const staleUpkeepReport = parseStaleUpkeepReportLogs(receipt) const upkeepPerformedLogs = parseUpkeepPerformedLogs(receipt) assert.equal(staleUpkeepReport.length, 1) assert.equal(upkeepPerformedLogs.length, 1) + assert.isTrue(await registry.hasDedupKey(expectedDedupKey)) + await expect(tx) + .to.emit(registry, 'DedupKeyAdded') + .withArgs(expectedDedupKey) }) it('returns early when check block number is less than last perform (block)', async () => { @@ -1788,24 +1799,18 @@ describe('KeeperRegistry2_1', () => { const id = upkeepPerformedLog.args.id const success = upkeepPerformedLog.args.success - const triggerID = upkeepPerformedLog.args.upkeepTriggerID + const trigger = upkeepPerformedLog.args.trigger const gasUsed = upkeepPerformedLog.args.gasUsed const gasOverhead = upkeepPerformedLog.args.gasOverhead const totalPayment = upkeepPerformedLog.args.totalPayment assert.equal(id.toString(), upkeepId.toString()) assert.equal(success, true) assert.equal( - triggerID, - ethers.utils.keccak256( - ethers.utils.concat([ - ethers.utils.defaultAbiCoder.encode(['uint256'], [upkeepId]), - encodeBlockTrigger({ - blockNum: checkBlock.number, - blockHash: checkBlock.hash, - }), - ]), - ), - 'incorrect calculation of triggerID', + trigger, + encodeBlockTrigger({ + blockNum: checkBlock.number, + blockHash: checkBlock.hash, + }), ) assert.isTrue(gasUsed.gt(BigNumber.from('0'))) assert.isTrue(gasOverhead.gt(BigNumber.from('0'))) diff --git a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go index b4d37a53708..67de7e61208 100644 --- a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go +++ b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var IKeeperRegistryMasterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"hasDedupKey\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var IKeeperRegistryMasterABI = IKeeperRegistryMasterMetaData.ABI @@ -798,6 +798,28 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) GetUpkeepTrigg return _IKeeperRegistryMaster.Contract.GetUpkeepTriggerConfig(&_IKeeperRegistryMaster.CallOpts, upkeepId) } +func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) HasDedupKey(opts *bind.CallOpts, dedupKey [32]byte) (bool, error) { + var out []interface{} + err := _IKeeperRegistryMaster.contract.Call(opts, &out, "hasDedupKey", dedupKey) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_IKeeperRegistryMaster *IKeeperRegistryMasterSession) HasDedupKey(dedupKey [32]byte) (bool, error) { + return _IKeeperRegistryMaster.Contract.HasDedupKey(&_IKeeperRegistryMaster.CallOpts, dedupKey) +} + +func (_IKeeperRegistryMaster *IKeeperRegistryMasterCallerSession) HasDedupKey(dedupKey [32]byte) (bool, error) { + return _IKeeperRegistryMaster.Contract.HasDedupKey(&_IKeeperRegistryMaster.CallOpts, dedupKey) +} + func (_IKeeperRegistryMaster *IKeeperRegistryMasterCaller) LatestConfigDetails(opts *bind.CallOpts) (LatestConfigDetails, error) { @@ -1593,9 +1615,9 @@ func (it *IKeeperRegistryMasterCancelledUpkeepReportIterator) Close() error { } type IKeeperRegistryMasterCancelledUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) FilterCancelledUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*IKeeperRegistryMasterCancelledUpkeepReportIterator, error) { @@ -1785,6 +1807,133 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) ParseConfigSet(log return event, nil } +type IKeeperRegistryMasterDedupKeyAddedIterator struct { + Event *IKeeperRegistryMasterDedupKeyAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *IKeeperRegistryMasterDedupKeyAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(IKeeperRegistryMasterDedupKeyAdded) + 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(IKeeperRegistryMasterDedupKeyAdded) + 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 *IKeeperRegistryMasterDedupKeyAddedIterator) Error() error { + return it.fail +} + +func (it *IKeeperRegistryMasterDedupKeyAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type IKeeperRegistryMasterDedupKeyAdded struct { + DedupKey [32]byte + Raw types.Log +} + +func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*IKeeperRegistryMasterDedupKeyAddedIterator, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _IKeeperRegistryMaster.contract.FilterLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return &IKeeperRegistryMasterDedupKeyAddedIterator{contract: _IKeeperRegistryMaster.contract, event: "DedupKeyAdded", logs: logs, sub: sub}, nil +} + +func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *IKeeperRegistryMasterDedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _IKeeperRegistryMaster.contract.WatchLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(IKeeperRegistryMasterDedupKeyAdded) + if err := _IKeeperRegistryMaster.contract.UnpackLog(event, "DedupKeyAdded", 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 (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) ParseDedupKeyAdded(log types.Log) (*IKeeperRegistryMasterDedupKeyAdded, error) { + event := new(IKeeperRegistryMasterDedupKeyAdded) + if err := _IKeeperRegistryMaster.contract.UnpackLog(event, "DedupKeyAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type IKeeperRegistryMasterFundsAddedIterator struct { Event *IKeeperRegistryMasterFundsAdded @@ -2112,9 +2261,9 @@ func (it *IKeeperRegistryMasterInsufficientFundsUpkeepReportIterator) Close() er } type IKeeperRegistryMasterInsufficientFundsUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) FilterInsufficientFundsUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*IKeeperRegistryMasterInsufficientFundsUpkeepReportIterator, error) { @@ -3300,9 +3449,9 @@ func (it *IKeeperRegistryMasterReorgedUpkeepReportIterator) Close() error { } type IKeeperRegistryMasterReorgedUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) FilterReorgedUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*IKeeperRegistryMasterReorgedUpkeepReportIterator, error) { @@ -3428,9 +3577,9 @@ func (it *IKeeperRegistryMasterStaleUpkeepReportIterator) Close() error { } type IKeeperRegistryMasterStaleUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) FilterStaleUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*IKeeperRegistryMasterStaleUpkeepReportIterator, error) { @@ -4857,13 +5006,13 @@ func (it *IKeeperRegistryMasterUpkeepPerformedIterator) Close() error { } type IKeeperRegistryMasterUpkeepPerformed struct { - Id *big.Int - Success bool - TotalPayment *big.Int - GasUsed *big.Int - GasOverhead *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Success bool + TotalPayment *big.Int + GasUsed *big.Int + GasOverhead *big.Int + Trigger []byte + Raw types.Log } func (_IKeeperRegistryMaster *IKeeperRegistryMasterFilterer) FilterUpkeepPerformed(opts *bind.FilterOpts, id []*big.Int, success []bool) (*IKeeperRegistryMasterUpkeepPerformedIterator, error) { @@ -5614,6 +5763,8 @@ func (_IKeeperRegistryMaster *IKeeperRegistryMaster) ParseLog(log types.Log) (ge return _IKeeperRegistryMaster.ParseCancelledUpkeepReport(log) case _IKeeperRegistryMaster.abi.Events["ConfigSet"].ID: return _IKeeperRegistryMaster.ParseConfigSet(log) + case _IKeeperRegistryMaster.abi.Events["DedupKeyAdded"].ID: + return _IKeeperRegistryMaster.ParseDedupKeyAdded(log) case _IKeeperRegistryMaster.abi.Events["FundsAdded"].ID: return _IKeeperRegistryMaster.ParseFundsAdded(log) case _IKeeperRegistryMaster.abi.Events["FundsWithdrawn"].ID: @@ -5683,13 +5834,17 @@ func (IKeeperRegistryMasterAdminPrivilegeConfigSet) Topic() common.Hash { } func (IKeeperRegistryMasterCancelledUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d") + return common.HexToHash("0xc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd5636") } func (IKeeperRegistryMasterConfigSet) Topic() common.Hash { return common.HexToHash("0x1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05") } +func (IKeeperRegistryMasterDedupKeyAdded) Topic() common.Hash { + return common.HexToHash("0xa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f2") +} + func (IKeeperRegistryMasterFundsAdded) Topic() common.Hash { return common.HexToHash("0xafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa734891506203") } @@ -5699,7 +5854,7 @@ func (IKeeperRegistryMasterFundsWithdrawn) Topic() common.Hash { } func (IKeeperRegistryMasterInsufficientFundsUpkeepReport) Topic() common.Hash { - return common.HexToHash("0xfcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e") + return common.HexToHash("0x377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e02") } func (IKeeperRegistryMasterOwnerFundsWithdrawn) Topic() common.Hash { @@ -5735,11 +5890,11 @@ func (IKeeperRegistryMasterPaymentWithdrawn) Topic() common.Hash { } func (IKeeperRegistryMasterReorgedUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d38868") + return common.HexToHash("0x6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301") } func (IKeeperRegistryMasterStaleUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b11") + return common.HexToHash("0x405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8") } func (IKeeperRegistryMasterTransmitted) Topic() common.Hash { @@ -5783,7 +5938,7 @@ func (IKeeperRegistryMasterUpkeepPaused) Topic() common.Hash { } func (IKeeperRegistryMasterUpkeepPerformed) Topic() common.Hash { - return common.HexToHash("0xdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c6") + return common.HexToHash("0xad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b") } func (IKeeperRegistryMasterUpkeepPrivilegeConfigSet) Topic() common.Hash { @@ -5869,6 +6024,8 @@ type IKeeperRegistryMasterInterface interface { GetUpkeepTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) + HasDedupKey(opts *bind.CallOpts, dedupKey [32]byte) (bool, error) + LatestConfigDetails(opts *bind.CallOpts) (LatestConfigDetails, error) @@ -5979,6 +6136,12 @@ type IKeeperRegistryMasterInterface interface { ParseConfigSet(log types.Log) (*IKeeperRegistryMasterConfigSet, error) + FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*IKeeperRegistryMasterDedupKeyAddedIterator, error) + + WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *IKeeperRegistryMasterDedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) + + ParseDedupKeyAdded(log types.Log) (*IKeeperRegistryMasterDedupKeyAdded, error) + FilterFundsAdded(opts *bind.FilterOpts, id []*big.Int, from []common.Address) (*IKeeperRegistryMasterFundsAddedIterator, error) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *IKeeperRegistryMasterFundsAdded, id []*big.Int, from []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go index edd51a155ff..96b2442aa4a 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go @@ -31,7 +31,7 @@ var ( ) var KeeperRegistryLogicAMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", Bin: "0x6101406040523480156200001257600080fd5b50604051620061d1380380620061d18339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051615d18620004b96000396000818161010e01526101a90152600081816103e10152611fa10152600081816135370152818161376d015281816139b50152613b5d015260006130e1015260006131c5015260008181611de301526123af0152615d186000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806385c1b0ba11620000a5578063c8048022116200006f578063c804802214620002b7578063ce7dc5b414620002ce578063f2fde38b14620002e5578063f7d334ba14620002fc576200010c565b806385c1b0ba14620002535780638da5cb5b146200026a5780638e86139b1462000289578063948108f714620002a0576200010c565b80634ee88d3511620000e75780634ee88d3514620001ef5780636ded9eae146200020657806371791aa0146200021d57806379ba50971462000249576200010c565b806328f32f38146200015457806329c5efad146200017e578063349e8cca14620001a7575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e8080156200014d573d6000f35b3d6000fd5b005b6200016b62000165366004620041ea565b62000313565b6040519081526020015b60405180910390f35b620001956200018f366004620042d0565b6200068c565b604051620001759493929190620043f8565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000175565b620001526200020036600462004435565b62000930565b6200016b6200021736600462004485565b62000998565b620002346200022e366004620042d0565b620009fe565b60405162000175979695949392919062004538565b62000152620010f0565b62000152620002643660046200458a565b620011f3565b60005473ffffffffffffffffffffffffffffffffffffffff16620001c9565b620001526200029a36600462004617565b62001e64565b62000152620002b13660046200467a565b620021ec565b62000152620002c8366004620046a9565b6200247f565b62000195620002df3660046200477f565b62002846565b62000152620002f6366004620047f6565b62002916565b620002346200030d366004620046a9565b6200292e565b6000805473ffffffffffffffffffffffffffffffffffffffff163314801590620003475750620003456009336200296c565b155b156200037f576040517fd48b678b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff89163b620003ce576040517f09ee12d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b620003d986620029a0565b9050600089307f00000000000000000000000000000000000000000000000000000000000000006040516200040e9062003f7b565b73ffffffffffffffffffffffffffffffffffffffff938416815291831660208301529091166040820152606001604051809103906000f08015801562000458573d6000803e3d6000fd5b5090506200051f826040518060e001604052806000151581526020018c63ffffffff16815260200163ffffffff801681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff168152602001600063ffffffff168152508a89898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915062002b449050565b6014805474010000000000000000000000000000000000000000900463ffffffff1690806200054e8362004845565b91906101000a81548163ffffffff021916908363ffffffff16021790555050817fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d0128a8a604051620005c792919063ffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2817fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d878760405162000603929190620048b4565b60405180910390a2817f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d5664856040516200063d9190620048ca565b60405180910390a2817f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf485084604051620006779190620048ca565b60405180910390a25098975050505050505050565b600060606000806200069d62002f1f565b600086815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff90811694830194909452650100000000008104841694820194909452690100000000000000000090930473ffffffffffffffffffffffffffffffffffffffff166060840152600101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a0840152780100000000000000000000000000000000000000000000000090041660c08201525a9150600080826060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620007b7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620007dd9190620048ec565b73ffffffffffffffffffffffffffffffffffffffff166013600101600c9054906101000a900463ffffffff1663ffffffff16896040516200081f91906200490c565b60006040518083038160008787f1925050503d80600081146200085f576040519150601f19603f3d011682016040523d82523d6000602084013e62000864565b606091505b50915091505a6200087690856200492a565b935081620008a157600060405180602001604052806000815250600796509650965050505062000927565b80806020019051810190620008b791906200499b565b909750955086620008e557600060405180602001604052806000815250600496509650965050505062000927565b601554865164010000000090910463ffffffff1610156200092357600060405180602001604052806000815250600596509650965050505062000927565b5050505b92959194509250565b6200093b8362002f5a565b6000838152601a602052604090206200095682848362004a90565b50827f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d566483836040516200098b929190620048b4565b60405180910390a2505050565b6000620009f288888860008989604051806020016040528060008152508a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506200031392505050565b98975050505050505050565b60006060600080600080600062000a1462002f1f565b600062000a218a62003010565b905060006012604051806101200160405290816000820160009054906101000a900460ff1660ff1660ff1681526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900462ffffff1662ffffff1662ffffff16815260200160008201600c9054906101000a900461ffff1661ffff1661ffff16815260200160008201600e9054906101000a900460ff1615151515815260200160008201600f9054906101000a900460ff161515151581526020016000820160109054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090506000600460008d81526020019081526020016000206040518060e00160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160018201600c9054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020016001820160189054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090508160a001511562000d45576000604051806020016040528060008152506009600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b604081015163ffffffff9081161462000d96576000604051806020016040528060008152506001600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b80511562000ddc576000604051806020016040528060008152506002600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b62000de782620030be565b602083015160155492975090955060009162000e19918591879190640100000000900463ffffffff168a8a87620032b0565b9050806bffffffffffffffffffffffff168260a001516bffffffffffffffffffffffff16101562000e83576000604051806020016040528060008152506006600085602001516000808263ffffffff1692509a509a509a509a509a509a509a5050505050620010e4565b600062000e928e868f62003301565b90505a9850600080846060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000eea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000f109190620048ec565b73ffffffffffffffffffffffffffffffffffffffff166013600101600c9054906101000a900463ffffffff1663ffffffff168460405162000f5291906200490c565b60006040518083038160008787f1925050503d806000811462000f92576040519150601f19603f3d011682016040523d82523d6000602084013e62000f97565b606091505b50915091505a62000fa9908c6200492a565b9a5081620010295760155481516801000000000000000090910463ffffffff1610156200100657505060408051602080820190925260008082529490910151939c509a50600899505063ffffffff9091169550620010e492505050565b602090940151939b5060039a505063ffffffff9092169650620010e49350505050565b808060200190518101906200103f91906200499b565b909e509c508d6200108057505060408051602080820190925260008082529490910151939c509a50600499505063ffffffff9091169550620010e492505050565b6015548d5164010000000090910463ffffffff161015620010d157505060408051602080820190925260008082529490910151939c509a50600599505063ffffffff9091169550620010e492505050565b505050506020015163ffffffff16945050505b92959891949750929550565b60015473ffffffffffffffffffffffffffffffffffffffff16331462001177576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600173ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff1660038111156200123257620012326200438d565b141580156200127e5750600373ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff1660038111156200127b576200127b6200438d565b14155b15620012b6576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1662001316576040517fd12d7d8d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082900362001352576040517f2c2fc94100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c081018290526000808567ffffffffffffffff811115620013a957620013a962004071565b604051908082528060200260200182016040528015620013d3578160200160208202803683370190505b50905060008667ffffffffffffffff811115620013f457620013f462004071565b6040519080825280602002602001820160405280156200147b57816020015b6040805160e08101825260008082526020808301829052928201819052606082018190526080820181905260a0820181905260c082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181620014135790505b50905060008767ffffffffffffffff8111156200149c576200149c62004071565b604051908082528060200260200182016040528015620014d157816020015b6060815260200190600190039081620014bb5790505b50905060008867ffffffffffffffff811115620014f257620014f262004071565b6040519080825280602002602001820160405280156200152757816020015b6060815260200190600190039081620015115790505b50905060008967ffffffffffffffff81111562001548576200154862004071565b6040519080825280602002602001820160405280156200157d57816020015b6060815260200190600190039081620015675790505b50905060005b8a81101562001b61578b8b82818110620015a157620015a162004bb8565b60209081029290920135600081815260048452604090819020815160e081018352815460ff811615158252610100810463ffffffff90811697830197909752650100000000008104871693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490931660c08401529a509098506200168090508962002f5a565b60608801516040517f1a5da6c800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c8116600483015290911690631a5da6c890602401600060405180830381600087803b158015620016f057600080fd5b505af115801562001705573d6000803e3d6000fd5b50505050878582815181106200171f576200171f62004bb8565b6020026020010181905250600560008a815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1686828151811062001773576200177362004bb8565b73ffffffffffffffffffffffffffffffffffffffff90921660209283029190910182015260008a81526007909152604090208054620017b290620049e8565b80601f0160208091040260200160405190810160405280929190818152602001828054620017e090620049e8565b8015620018315780601f10620018055761010080835404028352916020019162001831565b820191906000526020600020905b8154815290600101906020018083116200181357829003601f168201915b50505050508482815181106200184b576200184b62004bb8565b6020026020010181905250601a60008a815260200190815260200160002080546200187690620049e8565b80601f0160208091040260200160405190810160405280929190818152602001828054620018a490620049e8565b8015620018f55780601f10620018c957610100808354040283529160200191620018f5565b820191906000526020600020905b815481529060010190602001808311620018d757829003601f168201915b50505050508382815181106200190f576200190f62004bb8565b6020026020010181905250601b60008a815260200190815260200160002080546200193a90620049e8565b80601f01602080910402602001604051908101604052809291908181526020018280546200196890620049e8565b8015620019b95780601f106200198d57610100808354040283529160200191620019b9565b820191906000526020600020905b8154815290600101906020018083116200199b57829003601f168201915b5050505050828281518110620019d357620019d362004bb8565b60200260200101819052508760a001516bffffffffffffffffffffffff1687620019fe919062004be7565b60008a815260046020908152604080832080547fffffff000000000000000000000000000000000000000000000000000000000016815560010180547fffffffff000000000000000000000000000000000000000000000000000000001690556007909152812091985062001a74919062003f89565b6000898152601a6020526040812062001a8d9162003f89565b6000898152601b6020526040812062001aa69162003f89565b600089815260066020526040902080547fffffffffffffffffffffffff000000000000000000000000000000000000000016905562001ae760028a62003523565b5060a0880151604080516bffffffffffffffffffffffff909216825273ffffffffffffffffffffffffffffffffffffffff8c1660208301528a917fb38647142fbb1ea4c000fc4569b37a4e9a9f6313317b84ee3e5326c1a6cd06ff910160405180910390a28062001b588162004bfd565b91505062001583565b508560185462001b7291906200492a565b60185560008b8b868167ffffffffffffffff81111562001b965762001b9662004071565b60405190808252806020026020018201604052801562001bc0578160200160208202803683370190505b508988888860405160200162001bde98979695949392919062004da3565b60405160208183030381529060405290508973ffffffffffffffffffffffffffffffffffffffff16638e86139b6013600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c71249ab60038e73ffffffffffffffffffffffffffffffffffffffff1663aab9edd66040518163ffffffff1660e01b8152600401602060405180830381865afa15801562001c9a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001cc0919062004e73565b866040518463ffffffff1660e01b815260040162001ce19392919062004e98565b600060405180830381865afa15801562001cff573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405262001d47919081019062004ebf565b6040518263ffffffff1660e01b815260040162001d659190620048ca565b600060405180830381600087803b15801562001d8057600080fd5b505af115801562001d95573d6000803e3d6000fd5b50506040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d81166004830152602482018b90527f000000000000000000000000000000000000000000000000000000000000000016925063a9059cbb91506044016020604051808303816000875af115801562001e2f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001e55919062004ef8565b50505050505050505050505050565b60023360009081526019602052604090205460ff16600381111562001e8d5762001e8d6200438d565b1415801562001ec3575060033360009081526019602052604090205460ff16600381111562001ec05762001ec06200438d565b14155b1562001efb576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080808062001f11888a018a620050f0565b965096509650965096509650965060005b8751811015620021e057600073ffffffffffffffffffffffffffffffffffffffff1687828151811062001f595762001f5962004bb8565b60200260200101516060015173ffffffffffffffffffffffffffffffffffffffff16036200206d5785818151811062001f965762001f9662004bb8565b6020026020010151307f000000000000000000000000000000000000000000000000000000000000000060405162001fce9062003f7b565b73ffffffffffffffffffffffffffffffffffffffff938416815291831660208301529091166040820152606001604051809103906000f08015801562002018573d6000803e3d6000fd5b508782815181106200202e576200202e62004bb8565b60200260200101516060019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505b6200212588828151811062002086576200208662004bb8565b6020026020010151888381518110620020a357620020a362004bb8565b6020026020010151878481518110620020c057620020c062004bb8565b6020026020010151878581518110620020dd57620020dd62004bb8565b6020026020010151878681518110620020fa57620020fa62004bb8565b602002602001015187878151811062002117576200211762004bb8565b602002602001015162002b44565b8781815181106200213a576200213a62004bb8565b60200260200101517f74931a144e43a50694897f241d973aecb5024c0e910f9bb80a163ea3c1cf5a7188838151811062002178576200217862004bb8565b602002602001015160a0015133604051620021c39291906bffffffffffffffffffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a280620021d78162004bfd565b91505062001f22565b50505050505050505050565b600082815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c08201529114620022ea576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160a00151620022fc919062005221565b600084815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601854620023649184169062004be7565b6018556040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526bffffffffffffffffffffffff831660448201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906323b872dd906064016020604051808303816000875af11580156200240e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062002434919062004ef8565b506040516bffffffffffffffffffffffff83168152339084907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a3505050565b6000818152600460209081526040808320815160e081018352815460ff81161515825263ffffffff6101008204811695830195909552650100000000008104851693820184905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004831660c082015292911415906200256860005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16149050818015620025c35750808015620025c15750620025b462003531565b836040015163ffffffff16115b155b15620025fb576040517ffbc0357800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b801580156200262e575060008481526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314155b1562002666576040517ffbdb8e5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006200267262003531565b9050816200268a576200268760328262004be7565b90505b6000858152600460205260409020805463ffffffff80841665010000000000027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff90921691909117909155620026e69060029087906200352316565b5060135460808501516bffffffffffffffffffffffff91821691600091168211156200274f5760808601516200271d908362005249565b90508560a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff1611156200274f575060a08501515b808660a0015162002761919062005249565b600088815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601454620027c99183911662005221565b601480547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9290921691909117905560405167ffffffffffffffff84169088907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a350505050505050565b600060606000806200285762002f1f565b6000634b56a42e60e01b888888604051602401620028789392919062005271565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290506200290389826200068c565b929c919b50995090975095505050505050565b62002920620035ed565b6200292b8162003670565b50565b600060606000806000806000620029558860405180602001604052806000815250620009fe565b959e949d50929b5090995097509550909350915050565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b90505b92915050565b6000806000620029c76001620029b562003531565b620029c191906200492a565b62003767565b601454604080516020810193909352309083015274010000000000000000000000000000000000000000900463ffffffff166060820152608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201209083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060045b600f81101562002ad3578282828151811062002a8f5762002a8f62004bb8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508062002aca8162004bfd565b91505062002a6f565b5083600181111562002ae95762002ae96200438d565b60f81b81600f8151811062002b025762002b0262004bb8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535062002b3c81620052a5565b949350505050565b6012546e010000000000000000000000000000900460ff161562002b94576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601554835163ffffffff909116101562002bda576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108fc856020015163ffffffff16108062002c185750601454602086015163ffffffff70010000000000000000000000000000000090920482169116115b1562002c50576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000868152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff161562002cba576040517f6e3b930b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000868152600460209081526040808320885181548a8501518b85015160608d01517fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009093169315157fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff169390931761010063ffffffff92831602177fffffff000000000000000000000000000000000000000000000000ffffffffff1665010000000000938216939093027fffffff0000000000000000000000000000000000000000ffffffffffffffffff1692909217690100000000000000000073ffffffffffffffffffffffffffffffffffffffff9283160217835560808b01516001909301805460a08d015160c08e01516bffffffffffffffffffffffff9687167fffffffffffffffff000000000000000000000000000000000000000000000000909316929092176c010000000000000000000000009690911695909502949094177fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff1678010000000000000000000000000000000000000000000000009490931693909302919091179091556005835281842080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169189169190911790556007909152902062002ead8482620052e8565b508460a001516bffffffffffffffffffffffff1660185462002ed0919062004be7565b6018556000868152601a6020526040902062002eed8382620052e8565b506000868152601b6020526040902062002f088282620052e8565b5062002f16600287620038cf565b50505050505050565b321562002f58576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff16331462002fb8576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff908116146200292b576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f811015620030a5577fff00000000000000000000000000000000000000000000000000000000000000821683826020811062003059576200305962004bb8565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146200309057506000949350505050565b806200309c8162004bfd565b91505062003017565b5081600f1a600181111562002b3c5762002b3c6200438d565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156200314b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200317191906200542a565b50945090925050506000811315806200318957508142105b80620031ae5750828015620031ae5750620031a582426200492a565b8463ffffffff16105b15620031bf576016549550620031c3565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156200322f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200325591906200542a565b50945090925050506000811315806200326d57508142105b806200329257508280156200329257506200328982426200492a565b8463ffffffff16105b15620032a3576017549450620032a7565b8094505b50505050915091565b600080620032c488878b60000151620038dd565b9050600080620032e18b8a63ffffffff16858a8a60018b6200397c565b9092509050620032f2818362005221565b9b9a5050505050505050505050565b606060008360018111156200331a576200331a6200438d565b03620033e7576000848152600760205260409081902090517f6e04ff0d0000000000000000000000000000000000000000000000000000000091620033629160240162005522565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290506200351c565b6001836001811115620033fe57620033fe6200438d565b03620034ea576000828060200190518101906200341c919062005599565b6000868152600760205260409081902090519192507f40691db4000000000000000000000000000000000000000000000000000000009162003463918491602401620056ad565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915291506200351c9050565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b600062002997838362003e1e565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156200356a576200356a6200438d565b03620035e857606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620035bd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620035e3919062005775565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331462002f58576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016200116e565b3373ffffffffffffffffffffffffffffffffffffffff821603620036f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200116e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115620037a057620037a06200438d565b03620038c5576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620037f5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200381b919062005775565b905080831015806200383957506101006200383784836200492a565b115b15620038485750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa1580156200389f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200351c919062005775565b504090565b919050565b600062002997838362003f29565b60008080856001811115620038f657620038f66200438d565b0362003907575062015f906200392a565b60018560018111156200391e576200391e6200438d565b03620034ea57506201adb05b6200393d63ffffffff851660146200578f565b6200394a846001620057cf565b6200395b9060ff16611d4c6200578f565b62003967908362004be7565b62003973919062004be7565b95945050505050565b6000806000896080015161ffff16876200399791906200578f565b9050838015620039a65750803a105b15620039af57503a5b600060027f00000000000000000000000000000000000000000000000000000000000000006002811115620039e857620039e86200438d565b0362003b5957604080516000815260208101909152851562003a4c5760003660405180608001604052806048815260200162005cc46048913960405160200162003a3593929190620057eb565b604051602081830303815290604052905062003aba565b60155462003a6a90640100000000900463ffffffff16600462005814565b63ffffffff1667ffffffffffffffff81111562003a8b5762003a8b62004071565b6040519080825280601f01601f19166020018201604052801562003ab6576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9062003b0c908490600401620048ca565b602060405180830381865afa15801562003b2a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003b50919062005775565b91505062003cc3565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111562003b905762003b906200438d565b0362003cc357841562003c1857606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003bea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c10919062005775565b905062003cc3565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801562003c67573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c8d919062005843565b505060155492945062003cb293505050640100000000900463ffffffff16826200578f565b62003cbf9060106200578f565b9150505b8462003ce257808b6080015161ffff1662003cdf91906200578f565b90505b62003cf261ffff8716826200588e565b90506000878262003d048c8e62004be7565b62003d1090866200578f565b62003d1c919062004be7565b62003d3090670de0b6b3a76400006200578f565b62003d3c91906200588e565b905060008c6040015163ffffffff1664e8d4a5100062003d5d91906200578f565b898e6020015163ffffffff16858f8862003d7891906200578f565b62003d84919062004be7565b62003d9490633b9aca006200578f565b62003da091906200578f565b62003dac91906200588e565b62003db8919062004be7565b90506b033b2e3c9fd0803ce800000062003dd3828462004be7565b111562003e0c576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000818152600183016020526040812054801562003f1757600062003e456001836200492a565b855490915060009062003e5b906001906200492a565b905081811462003ec757600086600001828154811062003e7f5762003e7f62004bb8565b906000526020600020015490508087600001848154811062003ea55762003ea562004bb8565b6000918252602080832090910192909255918252600188019052604090208390555b855486908062003edb5762003edb620058ca565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506200299a565b60009150506200299a565b5092915050565b600081815260018301602052604081205462003f72575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556200299a565b5060006200299a565b6103ca80620058fa83390190565b50805462003f9790620049e8565b6000825580601f1062003fa8575050565b601f0160209004906000526020600020908101906200292b91905b8082111562003fd9576000815560010162003fc3565b5090565b73ffffffffffffffffffffffffffffffffffffffff811681146200292b57600080fd5b803563ffffffff81168114620038ca57600080fd5b803560028110620038ca57600080fd5b60008083601f8401126200403857600080fd5b50813567ffffffffffffffff8111156200405157600080fd5b6020830191508360208285010111156200406a57600080fd5b9250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160e0810167ffffffffffffffff81118282101715620040c657620040c662004071565b60405290565b604051610100810167ffffffffffffffff81118282101715620040c657620040c662004071565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156200413d576200413d62004071565b604052919050565b600067ffffffffffffffff82111562004162576200416262004071565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f830112620041a057600080fd5b8135620041b7620041b18262004145565b620040f3565b818152846020838601011115620041cd57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060e0898b0312156200420757600080fd5b8835620042148162003fdd565b97506200422460208a0162004000565b96506040890135620042368162003fdd565b95506200424660608a0162004015565b9450608089013567ffffffffffffffff808211156200426457600080fd5b620042728c838d0162004025565b909650945060a08b01359150808211156200428c57600080fd5b6200429a8c838d016200418e565b935060c08b0135915080821115620042b157600080fd5b50620042c08b828c016200418e565b9150509295985092959890939650565b60008060408385031215620042e457600080fd5b82359150602083013567ffffffffffffffff8111156200430357600080fd5b62004311858286016200418e565b9150509250929050565b60005b83811015620043385781810151838201526020016200431e565b50506000910152565b600081518084526200435b8160208601602086016200431b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600a8110620043f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b841515815260806020820152600062004415608083018662004341565b9050620044266040830185620043bc565b82606083015295945050505050565b6000806000604084860312156200444b57600080fd5b83359250602084013567ffffffffffffffff8111156200446a57600080fd5b620044788682870162004025565b9497909650939450505050565b600080600080600080600060a0888a031215620044a157600080fd5b8735620044ae8162003fdd565b9650620044be6020890162004000565b95506040880135620044d08162003fdd565b9450606088013567ffffffffffffffff80821115620044ee57600080fd5b620044fc8b838c0162004025565b909650945060808a01359150808211156200451657600080fd5b50620045258a828b0162004025565b989b979a50959850939692959293505050565b871515815260e0602082015260006200455560e083018962004341565b9050620045666040830188620043bc565b8560608301528460808301528360a08301528260c083015298975050505050505050565b600080600060408486031215620045a057600080fd5b833567ffffffffffffffff80821115620045b957600080fd5b818601915086601f830112620045ce57600080fd5b813581811115620045de57600080fd5b8760208260051b8501011115620045f457600080fd5b602092830195509350508401356200460c8162003fdd565b809150509250925092565b600080602083850312156200462b57600080fd5b823567ffffffffffffffff8111156200464357600080fd5b620046518582860162004025565b90969095509350505050565b80356bffffffffffffffffffffffff81168114620038ca57600080fd5b600080604083850312156200468e57600080fd5b82359150620046a0602084016200465d565b90509250929050565b600060208284031215620046bc57600080fd5b5035919050565b600067ffffffffffffffff821115620046e057620046e062004071565b5060051b60200190565b600082601f830112620046fc57600080fd5b813560206200470f620041b183620046c3565b82815260059290921b840181019181810190868411156200472f57600080fd5b8286015b848110156200477457803567ffffffffffffffff811115620047555760008081fd5b620047658986838b01016200418e565b84525091830191830162004733565b509695505050505050565b600080600080606085870312156200479657600080fd5b84359350602085013567ffffffffffffffff80821115620047b657600080fd5b620047c488838901620046ea565b94506040870135915080821115620047db57600080fd5b50620047ea8782880162004025565b95989497509550505050565b6000602082840312156200480957600080fd5b81356200351c8162003fdd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff80831681810362004861576200486162004816565b6001019392505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60208152600062002b3c6020830184866200486b565b60208152600062002997602083018462004341565b8051620038ca8162003fdd565b600060208284031215620048ff57600080fd5b81516200351c8162003fdd565b60008251620049208184602087016200431b565b9190910192915050565b818103818111156200299a576200299a62004816565b80151581146200292b57600080fd5b600082601f8301126200496157600080fd5b815162004972620041b18262004145565b8181528460208386010111156200498857600080fd5b62002b3c8260208301602087016200431b565b60008060408385031215620049af57600080fd5b8251620049bc8162004940565b602084015190925067ffffffffffffffff811115620049da57600080fd5b62004311858286016200494f565b600181811c90821680620049fd57607f821691505b60208210810362004a37577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111562004a8b57600081815260208120601f850160051c8101602086101562004a665750805b601f850160051c820191505b8181101562004a875782815560010162004a72565b5050505b505050565b67ffffffffffffffff83111562004aab5762004aab62004071565b62004ac38362004abc8354620049e8565b8362004a3d565b6000601f84116001811462004b18576000851562004ae15750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835562004bb1565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101562004b69578685013582556020948501946001909201910162004b47565b508682101562004ba5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b808201808211156200299a576200299a62004816565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362004c315762004c3162004816565b5060010190565b600081518084526020808501945080840160005b8381101562004cf75781518051151588528381015163ffffffff908116858a01526040808301519091169089015260608082015173ffffffffffffffffffffffffffffffffffffffff16908901526080808201516bffffffffffffffffffffffff169089015260a08082015162004cd2828b01826bffffffffffffffffffffffff169052565b505060c09081015163ffffffff169088015260e0909601959082019060010162004c4c565b509495945050505050565b600081518084526020808501945080840160005b8381101562004cf757815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010162004d16565b600081518084526020808501808196508360051b8101915082860160005b8581101562004d9657828403895262004d8384835162004341565b9885019893509084019060010162004d68565b5091979650505050505050565b60e081528760e082015260006101007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8a111562004de057600080fd5b8960051b808c8386013783018381038201602085015262004e048282018b62004c38565b915050828103604084015262004e1b818962004d02565b9050828103606084015262004e31818862004d02565b9050828103608084015262004e47818762004d4a565b905082810360a084015262004e5d818662004d4a565b905082810360c0840152620032f2818562004d4a565b60006020828403121562004e8657600080fd5b815160ff811681146200351c57600080fd5b60ff8416815260ff8316602082015260606040820152600062003973606083018462004341565b60006020828403121562004ed257600080fd5b815167ffffffffffffffff81111562004eea57600080fd5b62002b3c848285016200494f565b60006020828403121562004f0b57600080fd5b81516200351c8162004940565b600082601f83011262004f2a57600080fd5b8135602062004f3d620041b183620046c3565b82815260059290921b8401810191818101908684111562004f5d57600080fd5b8286015b8481101562004774578035835291830191830162004f61565b600082601f83011262004f8c57600080fd5b8135602062004f9f620041b183620046c3565b82815260e0928302850182019282820191908785111562004fbf57600080fd5b8387015b85811015620050765781818a03121562004fdd5760008081fd5b62004fe7620040a0565b813562004ff48162004940565b81526200500382870162004000565b8682015260406200501681840162004000565b908201526060828101356200502b8162003fdd565b9082015260806200503e8382016200465d565b9082015260a0620050518382016200465d565b9082015260c06200506483820162004000565b90820152845292840192810162004fc3565b5090979650505050505050565b600082601f8301126200509557600080fd5b81356020620050a8620041b183620046c3565b82815260059290921b84018101918181019086841115620050c857600080fd5b8286015b8481101562004774578035620050e28162003fdd565b8352918301918301620050cc565b600080600080600080600060e0888a0312156200510c57600080fd5b873567ffffffffffffffff808211156200512557600080fd5b620051338b838c0162004f18565b985060208a01359150808211156200514a57600080fd5b620051588b838c0162004f7a565b975060408a01359150808211156200516f57600080fd5b6200517d8b838c0162005083565b965060608a01359150808211156200519457600080fd5b620051a28b838c0162005083565b955060808a0135915080821115620051b957600080fd5b620051c78b838c01620046ea565b945060a08a0135915080821115620051de57600080fd5b620051ec8b838c01620046ea565b935060c08a01359150808211156200520357600080fd5b50620052128a828b01620046ea565b91505092959891949750929550565b6bffffffffffffffffffffffff81811683821601908082111562003f225762003f2262004816565b6bffffffffffffffffffffffff82811682821603908082111562003f225762003f2262004816565b60408152600062005286604083018662004d4a565b82810360208401526200529b8185876200486b565b9695505050505050565b8051602080830151919081101562004a37577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60209190910360031b1b16919050565b815167ffffffffffffffff81111562005305576200530562004071565b6200531d81620053168454620049e8565b8462004a3d565b602080601f8311600181146200537357600084156200533c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855562004a87565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015620053c257888601518255948401946001909101908401620053a1565b5085821015620053ff57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b805169ffffffffffffffffffff81168114620038ca57600080fd5b600080600080600060a086880312156200544357600080fd5b6200544e866200540f565b945060208601519350604086015192506060860151915062005473608087016200540f565b90509295509295909350565b600081546200548e81620049e8565b808552602060018381168015620054ae5760018114620054e75762005517565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b890101955062005517565b866000528260002060005b858110156200550f5781548a8201860152908301908401620054f2565b890184019650505b505050505092915050565b6020815260006200299760208301846200547f565b600082601f8301126200554957600080fd5b815160206200555c620041b183620046c3565b82815260059290921b840181019181810190868411156200557c57600080fd5b8286015b8481101562004774578051835291830191830162005580565b600060208284031215620055ac57600080fd5b815167ffffffffffffffff80821115620055c557600080fd5b908301906101008286031215620055db57600080fd5b620055e5620040cc565b82518152602083015160208201526040830151604082015260608301516060820152608083015160808201526200561f60a08401620048df565b60a082015260c0830151828111156200563757600080fd5b620056458782860162005537565b60c08301525060e0830151828111156200565e57600080fd5b6200566c878286016200494f565b60e08301525095945050505050565b600081518084526020808501945080840160005b8381101562004cf7578151875295820195908201906001016200568f565b60408152825160408201526020830151606082015260408301516080820152606083015160a0820152608083015160c082015273ffffffffffffffffffffffffffffffffffffffff60a08401511660e0820152600060c0840151610100808185015250620057206101408401826200567b565b905060e08501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0848303016101208501526200575e828262004341565b91505082810360208401526200397381856200547f565b6000602082840312156200578857600080fd5b5051919050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615620057ca57620057ca62004816565b500290565b60ff81811683821601908111156200299a576200299a62004816565b8284823760008382016000815283516200580a8183602088016200431b565b0195945050505050565b600063ffffffff808316818516818304811182151516156200583a576200583a62004816565b02949350505050565b60008060008060008060c087890312156200585d57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082620058c5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe60c060405234801561001057600080fd5b506040516103ca3803806103ca83398101604081905261002f91610076565b600080546001600160a01b0319166001600160a01b039384161790559181166080521660a0526100b9565b80516001600160a01b038116811461007157600080fd5b919050565b60008060006060848603121561008b57600080fd5b6100948461005a565b92506100a26020850161005a565b91506100b06040850161005a565b90509250925092565b60805160a0516102e76100e36000396000603801526000818160c4015261011701526102e76000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c806379188d161461007b578063f00e6a2a146100aa575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610076573d6000f35b3d6000fd5b61008e6100893660046101c1565b6100ee565b6040805192151583526020830191909152015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001681526020016100a1565b60008054819073ffffffffffffffffffffffffffffffffffffffff16331461011557600080fd5b7f00000000000000000000000000000000000000000000000000000000000000005a91505a61138881101561014957600080fd5b61138881039050856040820482031161016157600080fd5b50803b61016d57600080fd5b6000808551602087016000858af192505a610188908361029a565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080604083850312156101d457600080fd5b82359150602083013567ffffffffffffffff808211156101f357600080fd5b818501915085601f83011261020757600080fd5b81358181111561021957610219610192565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561025f5761025f610192565b8160405282815288602084870101111561027857600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b818103818111156102d4577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea164736f6c6343000810000a307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } @@ -572,9 +572,9 @@ func (it *KeeperRegistryLogicACancelledUpkeepReportIterator) Close() error { } type KeeperRegistryLogicACancelledUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) FilterCancelledUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicACancelledUpkeepReportIterator, error) { @@ -639,6 +639,133 @@ func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) ParseCancelledUpkeepR return event, nil } +type KeeperRegistryLogicADedupKeyAddedIterator struct { + Event *KeeperRegistryLogicADedupKeyAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryLogicADedupKeyAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryLogicADedupKeyAdded) + 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(KeeperRegistryLogicADedupKeyAdded) + 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 *KeeperRegistryLogicADedupKeyAddedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryLogicADedupKeyAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryLogicADedupKeyAdded struct { + DedupKey [32]byte + Raw types.Log +} + +func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*KeeperRegistryLogicADedupKeyAddedIterator, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _KeeperRegistryLogicA.contract.FilterLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return &KeeperRegistryLogicADedupKeyAddedIterator{contract: _KeeperRegistryLogicA.contract, event: "DedupKeyAdded", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryLogicADedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _KeeperRegistryLogicA.contract.WatchLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryLogicADedupKeyAdded) + if err := _KeeperRegistryLogicA.contract.UnpackLog(event, "DedupKeyAdded", 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 (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) ParseDedupKeyAdded(log types.Log) (*KeeperRegistryLogicADedupKeyAdded, error) { + event := new(KeeperRegistryLogicADedupKeyAdded) + if err := _KeeperRegistryLogicA.contract.UnpackLog(event, "DedupKeyAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type KeeperRegistryLogicAFundsAddedIterator struct { Event *KeeperRegistryLogicAFundsAdded @@ -966,9 +1093,9 @@ func (it *KeeperRegistryLogicAInsufficientFundsUpkeepReportIterator) Close() err } type KeeperRegistryLogicAInsufficientFundsUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) FilterInsufficientFundsUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicAInsufficientFundsUpkeepReportIterator, error) { @@ -2154,9 +2281,9 @@ func (it *KeeperRegistryLogicAReorgedUpkeepReportIterator) Close() error { } type KeeperRegistryLogicAReorgedUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) FilterReorgedUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicAReorgedUpkeepReportIterator, error) { @@ -2282,9 +2409,9 @@ func (it *KeeperRegistryLogicAStaleUpkeepReportIterator) Close() error { } type KeeperRegistryLogicAStaleUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) FilterStaleUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicAStaleUpkeepReportIterator, error) { @@ -3593,13 +3720,13 @@ func (it *KeeperRegistryLogicAUpkeepPerformedIterator) Close() error { } type KeeperRegistryLogicAUpkeepPerformed struct { - Id *big.Int - Success bool - TotalPayment *big.Int - GasUsed *big.Int - GasOverhead *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Success bool + TotalPayment *big.Int + GasUsed *big.Int + GasOverhead *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicA *KeeperRegistryLogicAFilterer) FilterUpkeepPerformed(opts *bind.FilterOpts, id []*big.Int, success []bool) (*KeeperRegistryLogicAUpkeepPerformedIterator, error) { @@ -4319,6 +4446,8 @@ func (_KeeperRegistryLogicA *KeeperRegistryLogicA) ParseLog(log types.Log) (gene return _KeeperRegistryLogicA.ParseAdminPrivilegeConfigSet(log) case _KeeperRegistryLogicA.abi.Events["CancelledUpkeepReport"].ID: return _KeeperRegistryLogicA.ParseCancelledUpkeepReport(log) + case _KeeperRegistryLogicA.abi.Events["DedupKeyAdded"].ID: + return _KeeperRegistryLogicA.ParseDedupKeyAdded(log) case _KeeperRegistryLogicA.abi.Events["FundsAdded"].ID: return _KeeperRegistryLogicA.ParseFundsAdded(log) case _KeeperRegistryLogicA.abi.Events["FundsWithdrawn"].ID: @@ -4386,7 +4515,11 @@ func (KeeperRegistryLogicAAdminPrivilegeConfigSet) Topic() common.Hash { } func (KeeperRegistryLogicACancelledUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d") + return common.HexToHash("0xc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd5636") +} + +func (KeeperRegistryLogicADedupKeyAdded) Topic() common.Hash { + return common.HexToHash("0xa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f2") } func (KeeperRegistryLogicAFundsAdded) Topic() common.Hash { @@ -4398,7 +4531,7 @@ func (KeeperRegistryLogicAFundsWithdrawn) Topic() common.Hash { } func (KeeperRegistryLogicAInsufficientFundsUpkeepReport) Topic() common.Hash { - return common.HexToHash("0xfcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e") + return common.HexToHash("0x377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e02") } func (KeeperRegistryLogicAOwnerFundsWithdrawn) Topic() common.Hash { @@ -4434,11 +4567,11 @@ func (KeeperRegistryLogicAPaymentWithdrawn) Topic() common.Hash { } func (KeeperRegistryLogicAReorgedUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d38868") + return common.HexToHash("0x6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301") } func (KeeperRegistryLogicAStaleUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b11") + return common.HexToHash("0x405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8") } func (KeeperRegistryLogicAUnpaused) Topic() common.Hash { @@ -4478,7 +4611,7 @@ func (KeeperRegistryLogicAUpkeepPaused) Topic() common.Hash { } func (KeeperRegistryLogicAUpkeepPerformed) Topic() common.Hash { - return common.HexToHash("0xdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c6") + return common.HexToHash("0xad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b") } func (KeeperRegistryLogicAUpkeepPrivilegeConfigSet) Topic() common.Hash { @@ -4550,6 +4683,12 @@ type KeeperRegistryLogicAInterface interface { ParseCancelledUpkeepReport(log types.Log) (*KeeperRegistryLogicACancelledUpkeepReport, error) + FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*KeeperRegistryLogicADedupKeyAddedIterator, error) + + WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryLogicADedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) + + ParseDedupKeyAdded(log types.Log) (*KeeperRegistryLogicADedupKeyAdded, error) + FilterFundsAdded(opts *bind.FilterOpts, id []*big.Int, from []common.Address) (*KeeperRegistryLogicAFundsAddedIterator, error) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryLogicAFundsAdded, id []*big.Int, from []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go index 7428bd2424e..a4738d74ef3 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go @@ -75,8 +75,8 @@ type KeeperRegistryBase21UpkeepInfo struct { } var KeeperRegistryLogicBMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101206040523480156200001257600080fd5b5060405162004f7e38038062004f7e8339810160408190526200003591620001e9565b84848484843380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000121565b505050846002811115620000dc57620000dc6200025e565b60e0816002811115620000f357620000f36200025e565b9052506001600160a01b0393841660805291831660a052821660c05216610100525062000274945050505050565b336001600160a01b038216036200017b5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001e457600080fd5b919050565b600080600080600060a086880312156200020257600080fd5b8551600381106200021257600080fd5b94506200022260208701620001cc565b93506200023260408701620001cc565b92506200024260608701620001cc565b91506200025260808701620001cc565b90509295509295909350565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051614c7f620002ff60003960006105490152600081816104e701528181613314015281816138970152613a2a0152600081816105b601526131080152600081816106de01526131e201526000818161076c01528181611b6d01528181611e43015281816122b0015281816127c301526128470152614c7f6000f3fe608060405234801561001057600080fd5b506004361061032b5760003560e01c806379ba5097116101b2578063b121e147116100f9578063ca30e603116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107b6578063ed56b3e1146107c9578063f2fde38b1461083c578063faa3e9961461084f57600080fd5b8063ca30e6031461076a578063cd7f71b514610790578063d7632648146107a357600080fd5b8063b657bc9c116100d3578063b657bc9c1461072f578063b79550be14610742578063c7c3a19a1461074a57600080fd5b8063b121e14714610702578063b148ab6b14610715578063b6511a2a1461072857600080fd5b80638dcf0fe71161015b578063aab9edd611610135578063aab9edd6146106c5578063abc76ae0146106d4578063b10b673c146106dc57600080fd5b80638dcf0fe71461068c578063a710b2211461069f578063a72aa27e146106b257600080fd5b80638456cb591161018c5780638456cb59146106535780638765ecbe1461065b5780638da5cb5b1461066e57600080fd5b806379ba50971461060057806379ea9943146106085780637d9b97e01461064b57600080fd5b8063421d183b116102765780635425d8ac1161021f5780636709d0e5116101f95780636709d0e5146105b4578063671d36ed146105da578063744bfe61146105ed57600080fd5b80635425d8ac146105475780635b6aa71c1461058e5780636209e1e9146105a157600080fd5b80634ca16c52116102505780634ca16c521461050b5780635147cd59146105145780635165f2f51461053457600080fd5b8063421d183b1461046f57806348013d7b146104d55780634b4fd03b146104e557600080fd5b80631a2af011116102d8578063232c1cc5116102b2578063232c1cc51461044d5780633b9cce59146104545780633f4ba83a1461046757600080fd5b80631a2af011146103c95780631e010439146103dc578063207b65161461043a57600080fd5b80631865c57d116103095780631865c57d1461037d578063187256e81461039657806319d97a94146103a957600080fd5b8063050ee65d1461033057806306e3b632146103485780630b7d33e614610368575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b61035b610356366004613db5565b610895565b60405161033f9190613dd7565b61037b610376366004613e64565b6109b2565b005b610385610a6c565b60405161033f959493929190614067565b61037b6103a436600461419e565b610e85565b6103bc6103b73660046141db565b610ef6565b60405161033f9190614262565b61037b6103d7366004614275565b610f98565b61041d6103ea3660046141db565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff909116815260200161033f565b6103bc6104483660046141db565b61109e565b6014610335565b61037b61046236600461429a565b6110bb565b61037b611311565b61048261047d36600461430f565b611377565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a00161033f565b60005b60405161033f919061436b565b7f00000000000000000000000000000000000000000000000000000000000000006104d8565b62015f90610335565b6105276105223660046141db565b6114aa565b60405161033f919061437e565b61037b6105423660046141db565b6114b5565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161033f565b61041d61059c3660046143ab565b61162c565b6103bc6105af36600461430f565b61175e565b7f0000000000000000000000000000000000000000000000000000000000000000610569565b61037b6105e83660046143e4565b611792565b61037b6105fb366004614275565b61186c565b61037b611c69565b6105696106163660046141db565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b61037b611d6b565b61037b611ec6565b61037b6106693660046141db565b611f37565b60005473ffffffffffffffffffffffffffffffffffffffff16610569565b61037b61069a366004613e64565b6120b1565b61037b6106ad366004614420565b612106565b61037b6106c036600461444e565b612382565b6040516003815260200161033f565b611d4c610335565b7f0000000000000000000000000000000000000000000000000000000000000000610569565b61037b61071036600461430f565b612477565b61037b6107233660046141db565b61256f565b6032610335565b61041d61073d3660046141db565b61275d565b61037b61278a565b61075d6107583660046141db565b6128e6565b60405161033f9190614471565b7f0000000000000000000000000000000000000000000000000000000000000000610569565b61037b61079e366004613e64565b612cb9565b61041d6107b13660046141db565b612d50565b61037b6107c4366004614420565b612d5b565b6108236107d736600461430f565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff90911660208301520161033f565b61037b61084a36600461430f565b612eb9565b61088861085d36600461430f565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161033f91906145a8565b606060006108a36002612ecd565b90508084106108de576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006108ea84866145eb565b9050818111806108f8575083155b6109025780610904565b815b9050600061091286836145fe565b67ffffffffffffffff81111561092a5761092a614611565b604051908082528060200260200182016040528015610953578160200160208202803683370190505b50905060005b81518110156109a65761097761096f88836145eb565b600290612ed7565b82828151811061098957610989614640565b60209081029190910101528061099e8161466f565b915050610959565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a13576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a2c828483614749565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a5f929190614864565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610bb96002612ecd565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d616009612eea565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610e0457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610dd9575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610e6d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e42575b50505050509150945094509450945094509091929394565b610e8d612ef7565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610eed57610eed61432c565b02179055505050565b6000818152601c60205260409020805460609190610f13906146a7565b80601f0160208091040260200160405190810160405280929190818152602001828054610f3f906146a7565b8015610f8c5780601f10610f6157610100808354040283529160200191610f8c565b820191906000526020600020905b815481529060010190602001808311610f6f57829003601f168201915b50505050509050919050565b610fa182612f7a565b3373ffffffffffffffffffffffffffffffffffffffff821603610ff0576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff82811691161461109a5760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f13906146a7565b6110c3612ef7565b600e5481146110fe576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e548110156112d0576000600e828154811061112057611120614640565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f9092526040832054919350169085858581811061116a5761116a614640565b905060200201602081019061117f919061430f565b905073ffffffffffffffffffffffffffffffffffffffff81161580611212575073ffffffffffffffffffffffffffffffffffffffff8216158015906111f057508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b8015611212575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611249576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112ba5773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b50505080806112c89061466f565b915050611101565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e8383604051611305939291906148b1565b60405180910390a15050565b611319612ef7565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152829182918291829190829061145157606082015160125460009161143d9170010000000000000000000000000000000090046bffffffffffffffffffffffff16614963565b600e5490915061144d90826149b7565b9150505b8151602083015160408401516114689084906149e2565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109ac8261302e565b6114be81612f7a565b600081815260046020908152604091829020825160e081018452815460ff8116151580835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c0820152906115bd576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690556115fc6002836130d9565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c01000000000000000000000000000000000000000000000000000000009091041691810191909152600090818061172b836130e5565b91509150611754838787601360020160049054906101000a900463ffffffff16868660006132c3565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f13906146a7565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1633146117f3576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d60205260409020611823828483614749565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a5f929190614864565b6012546f01000000000000000000000000000000900460ff16156118bc576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff8116611943576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600460209081526040808320815160e081018352815460ff81161515825263ffffffff610100820481168387015265010000000000820481168386015273ffffffffffffffffffffffffffffffffffffffff6901000000000000000000909204821660608401526001909301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c082015286855260059093529220549091163314611a4a576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a5261330e565b816040015163ffffffff161115611a95576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611ad59082906145fe565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611bb8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611bdc9190614a07565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611cef576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611d73612ef7565b6014546018546bffffffffffffffffffffffff90911690611d959082906145fe565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611ea2573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061109a9190614a07565b611ece612ef7565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589060200161136d565b611f4081612f7a565b600081815260046020908152604091829020825160e081018452815460ff8116158015835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201529061203f576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556120816002836133c3565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120ba83612f7a565b6000838152601b602052604090206120d3828483614749565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a5f929190614864565b73ffffffffffffffffffffffffffffffffffffffff8116612153576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121b3576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e546000916121ea91859170010000000000000000000000000000000090046bffffffffffffffffffffffff16906133cf565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff169055601854909150612254906bffffffffffffffffffffffff8316906145fe565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af11580156122f9573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061231d9190614a07565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123b7575060145463ffffffff7001000000000000000000000000000000009091048116908216115b156123ee576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6123f782612f7a565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff8181166000908152601060205260409020541633146124d7576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b600081815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c0820152911461266c576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff1633146126c9576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109ac61276b8361302e565b600084815260046020526040902054610100900463ffffffff1661162c565b612792612ef7565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561281f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128439190614a29565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb336018548461289091906145fe565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611e83565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e082018190526101008201526101208101919091526000828152600460209081526040808320815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606083018190526001909101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c0820152919015612a7e57816060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612a55573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a799190614a42565b612a81565b60005b90506040518061014001604052808273ffffffffffffffffffffffffffffffffffffffff168152602001836020015163ffffffff168152602001600760008781526020019081526020016000208054612ad9906146a7565b80601f0160208091040260200160405190810160405280929190818152602001828054612b05906146a7565b8015612b525780601f10612b2757610100808354040283529160200191612b52565b820191906000526020600020905b815481529060010190602001808311612b3557829003601f168201915b505050505081526020018360a001516bffffffffffffffffffffffff1681526020016005600087815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001836040015163ffffffff1667ffffffffffffffff1681526020018360c0015163ffffffff16815260200183608001516bffffffffffffffffffffffff168152602001836000015115158152602001601b60008781526020019081526020016000208054612c2f906146a7565b80601f0160208091040260200160405190810160405280929190818152602001828054612c5b906146a7565b8015612ca85780601f10612c7d57610100808354040283529160200191612ca8565b820191906000526020600020905b815481529060010190602001808311612c8b57829003601f168201915b505050505081525092505050919050565b612cc283612f7a565b60155463ffffffff16811115612d04576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612d1d828483614749565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a5f929190614864565b60006109ac8261275d565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612dbb576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612e0a576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff82811660009081526010602052604090205481169082161461109a5773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612ec1612ef7565b612eca816135d7565b50565b60006109ac825490565b6000612ee383836136cc565b9392505050565b60606000612ee3836136f6565b60005473ffffffffffffffffffffffffffffffffffffffff163314612f78576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611ce6565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612fd7576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612eca576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f8110156130bb577fff00000000000000000000000000000000000000000000000000000000000000821683826020811061307357613073614640565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146130a957506000949350505050565b806130b38161466f565b915050613035565b5081600f1a60018111156130d1576130d161432c565b949350505050565b6000612ee38383613751565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613171573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131959190614a79565b50945090925050506000811315806131ac57508142105b806131cd57508280156131cd57506131c482426145fe565b8463ffffffff16105b156131dc5760165495506131e0565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa15801561324b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061326f9190614a79565b509450909250505060008113158061328657508142105b806132a757508280156132a7575061329e82426145fe565b8463ffffffff16105b156132b65760175494506132ba565b8094505b50505050915091565b6000806132d588878b600001516137a0565b90506000806132f08b8a63ffffffff16858a8a60018b613862565b90925090506132ff81836149e2565b9b9a5050505050505050505050565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156133445761334461432c565b036133be57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613395573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133b99190614a29565b905090565b504390565b6000612ee38383613cbb565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906135cb5760008160600151856134679190614963565b9050600061347585836149b7565b9050808360400181815161348991906149e2565b6bffffffffffffffffffffffff169052506134a48582614ac9565b836060018181516134b591906149e2565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613656576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611ce6565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008260000182815481106136e3576136e3614640565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610f8c57602002820191906000526020600020905b8154815260200190600101908083116137325750505050509050919050565b6000818152600183016020526040812054613798575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109ac565b5060006109ac565b600080808560018111156137b6576137b661432c565b036137c5575062015f9061381a565b60018560018111156137d9576137d961432c565b036137e857506201adb061381a565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61382b63ffffffff85166014614afd565b613836846001614b3a565b6138459060ff16611d4c614afd565b61384f90836145eb565b61385991906145eb565b95945050505050565b6000806000896080015161ffff168761387b9190614afd565b90508380156138895750803a105b1561389157503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156138c7576138c761432c565b03613a2657604080516000815260208101909152851561392557600036604051806080016040528060488152602001614c2b6048913960405160200161390f93929190614b53565b604051602081830303815290604052905061398d565b60155461394190640100000000900463ffffffff166004614b7a565b63ffffffff1667ffffffffffffffff81111561395f5761395f614611565b6040519080825280601f01601f191660200182016040528015613989576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e906139dd908490600401614262565b602060405180830381865afa1580156139fa573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a1e9190614a29565b915050613b80565b60017f00000000000000000000000000000000000000000000000000000000000000006002811115613a5a57613a5a61432c565b03613b80578415613adc57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613ab1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ad59190614a29565b9050613b80565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613b2a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b4e9190614b9d565b5050601554929450613b7193505050640100000000900463ffffffff1682614afd565b613b7c906010614afd565b9150505b84613b9c57808b6080015161ffff16613b999190614afd565b90505b613baa61ffff871682614be7565b905060008782613bba8c8e6145eb565b613bc49086614afd565b613bce91906145eb565b613be090670de0b6b3a7640000614afd565b613bea9190614be7565b905060008c6040015163ffffffff1664e8d4a51000613c099190614afd565b898e6020015163ffffffff16858f88613c229190614afd565b613c2c91906145eb565b613c3a90633b9aca00614afd565b613c449190614afd565b613c4e9190614be7565b613c5891906145eb565b90506b033b2e3c9fd0803ce8000000613c7182846145eb565b1115613ca9576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613da4576000613cdf6001836145fe565b8554909150600090613cf3906001906145fe565b9050818114613d58576000866000018281548110613d1357613d13614640565b9060005260206000200154905080876000018481548110613d3657613d36614640565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613d6957613d69614bfb565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109ac565b60009150506109ac565b5092915050565b60008060408385031215613dc857600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613e0f57835183529284019291840191600101613df3565b50909695505050505050565b60008083601f840112613e2d57600080fd5b50813567ffffffffffffffff811115613e4557600080fd5b602083019150836020828501011115613e5d57600080fd5b9250929050565b600080600060408486031215613e7957600080fd5b83359250602084013567ffffffffffffffff811115613e9757600080fd5b613ea386828701613e1b565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613ef657815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613ec4565b509495945050505050565b805163ffffffff16825260006101e06020830151613f27602086018263ffffffff169052565b506040830151613f3f604086018263ffffffff169052565b506060830151613f56606086018262ffffff169052565b506080830151613f6c608086018261ffff169052565b5060a0830151613f8c60a08601826bffffffffffffffffffffffff169052565b5060c0830151613fa460c086018263ffffffff169052565b5060e0830151613fbc60e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a08084015181860183905261403183870182613eb0565b925050506101c08084015161405d8287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c0602088015161409560208501826bffffffffffffffffffffffff169052565b506040880151604084015260608801516140bf60608501826bffffffffffffffffffffffff169052565b506080880151608084015260a08801516140e160a085018263ffffffff169052565b5060c08801516140f960c085018263ffffffff169052565b5060e088015160e08401526101008089015161411c8286018263ffffffff169052565b505061012088810151151590840152610140830181905261413f81840188613f01565b90508281036101608401526141548187613eb0565b90508281036101808401526141698186613eb0565b9150506117546101a083018460ff169052565b73ffffffffffffffffffffffffffffffffffffffff81168114612eca57600080fd5b600080604083850312156141b157600080fd5b82356141bc8161417c565b91506020830135600481106141d057600080fd5b809150509250929050565b6000602082840312156141ed57600080fd5b5035919050565b60005b8381101561420f5781810151838201526020016141f7565b50506000910152565b600081518084526142308160208601602086016141f4565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612ee36020830184614218565b6000806040838503121561428857600080fd5b8235915060208301356141d08161417c565b600080602083850312156142ad57600080fd5b823567ffffffffffffffff808211156142c557600080fd5b818501915085601f8301126142d957600080fd5b8135818111156142e857600080fd5b8660208260051b85010111156142fd57600080fd5b60209290920196919550909350505050565b60006020828403121561432157600080fd5b8135612ee38161417c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612eca57612eca61432c565b602081016143788361435b565b91905290565b60208101600283106143785761437861432c565b803563ffffffff811681146143a657600080fd5b919050565b600080604083850312156143be57600080fd5b8235600281106143cd57600080fd5b91506143db60208401614392565b90509250929050565b6000806000604084860312156143f957600080fd5b83356144048161417c565b9250602084013567ffffffffffffffff811115613e9757600080fd5b6000806040838503121561443357600080fd5b823561443e8161417c565b915060208301356141d08161417c565b6000806040838503121561446157600080fd5b823591506143db60208401614392565b6020815261449860208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516144b1604084018263ffffffff169052565b5060408301516101408060608501526144ce610160850183614218565b915060608501516144ef60808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e085015161010061455b818701836bffffffffffffffffffffffff169052565b86015190506101206145708682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018387015290506117548382614218565b60208101600483106143785761437861432c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109ac576109ac6145bc565b818103818111156109ac576109ac6145bc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036146a0576146a06145bc565b5060010190565b600181811c908216806146bb57607f821691505b6020821081036146f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561474457600081815260208120601f850160051c810160208610156147215750805b601f850160051c820191505b818110156147405782815560010161472d565b5050505b505050565b67ffffffffffffffff83111561476157614761614611565b6147758361476f83546146a7565b836146fa565b6000601f8411600181146147c757600085156147915750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561485d565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561481657868501358255602094850194600190920191016147f6565b5086821015614851577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561490857815473ffffffffffffffffffffffffffffffffffffffff16845292840192600191820191016148d6565b505050838103828501528481528590820160005b8681101561495757823561492f8161417c565b73ffffffffffffffffffffffffffffffffffffffff168252918301919083019060010161491c565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613dae57613dae6145bc565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff808416806149d6576149d6614988565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613dae57613dae6145bc565b600060208284031215614a1957600080fd5b81518015158114612ee357600080fd5b600060208284031215614a3b57600080fd5b5051919050565b600060208284031215614a5457600080fd5b8151612ee38161417c565b805169ffffffffffffffffffff811681146143a657600080fd5b600080600080600060a08688031215614a9157600080fd5b614a9a86614a5f565b9450602086015193506040860151925060608601519150614abd60808701614a5f565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614af457614af46145bc565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b3557614b356145bc565b500290565b60ff81811683821601908111156109ac576109ac6145bc565b828482376000838201600081528351614b708183602088016141f4565b0195945050505050565b600063ffffffff80831681851681830481118215151615614af457614af46145bc565b60008060008060008060c08789031215614bb657600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614bf657614bf6614988565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"hasDedupKey\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101206040523480156200001257600080fd5b5060405162004fbc38038062004fbc8339810160408190526200003591620001e9565b84848484843380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000121565b505050846002811115620000dc57620000dc6200025e565b60e0816002811115620000f357620000f36200025e565b9052506001600160a01b0393841660805291831660a052821660c05216610100525062000274945050505050565b336001600160a01b038216036200017b5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001e457600080fd5b919050565b600080600080600060a086880312156200020257600080fd5b8551600381106200021257600080fd5b94506200022260208701620001cc565b93506200023260408701620001cc565b92506200024260608701620001cc565b91506200025260808701620001cc565b90509295509295909350565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051614cbd620002ff600039600061058701526000818161052501528181613352015281816138d50152613a680152600081816105f4015261314601526000818161071c01526132200152600081816107aa01528181611bab01528181611e81015281816122ee0152818161280101526128850152614cbd6000f3fe608060405234801561001057600080fd5b50600436106103365760003560e01c806379ba5097116101b2578063b121e147116100f9578063ca30e603116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107f4578063ed56b3e114610807578063f2fde38b1461087a578063faa3e9961461088d57600080fd5b8063ca30e603146107a8578063cd7f71b5146107ce578063d7632648146107e157600080fd5b8063b657bc9c116100d3578063b657bc9c1461076d578063b79550be14610780578063c7c3a19a1461078857600080fd5b8063b121e14714610740578063b148ab6b14610753578063b6511a2a1461076657600080fd5b80638dcf0fe71161015b578063aab9edd611610135578063aab9edd614610703578063abc76ae014610712578063b10b673c1461071a57600080fd5b80638dcf0fe7146106ca578063a710b221146106dd578063a72aa27e146106f057600080fd5b80638456cb591161018c5780638456cb59146106915780638765ecbe146106995780638da5cb5b146106ac57600080fd5b806379ba50971461063e57806379ea9943146106465780637d9b97e01461068957600080fd5b8063421d183b116102815780635165f2f51161022a5780636209e1e9116102045780636209e1e9146105df5780636709d0e5146105f2578063671d36ed14610618578063744bfe611461062b57600080fd5b80635165f2f5146105725780635425d8ac146105855780635b6aa71c146105cc57600080fd5b80634b4fd03b1161025b5780634b4fd03b146105235780634ca16c52146105495780635147cd591461055257600080fd5b8063421d183b1461047a57806344cb70b8146104e057806348013d7b1461051357600080fd5b80631a2af011116102e3578063232c1cc5116102bd578063232c1cc5146104585780633b9cce591461045f5780633f4ba83a1461047257600080fd5b80631a2af011146103d45780631e010439146103e7578063207b65161461044557600080fd5b80631865c57d116103145780631865c57d14610388578063187256e8146103a157806319d97a94146103b457600080fd5b8063050ee65d1461033b57806306e3b632146103535780630b7d33e614610373575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b610366610361366004613df3565b6108d3565b60405161034a9190613e15565b610386610381366004613ea2565b6109f0565b005b610390610aaa565b60405161034a9594939291906140a5565b6103866103af3660046141dc565b610ec3565b6103c76103c2366004614219565b610f34565b60405161034a91906142a0565b6103866103e23660046142b3565b610fd6565b6104286103f5366004614219565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff909116815260200161034a565b6103c7610453366004614219565b6110dc565b6014610340565b61038661046d3660046142d8565b6110f9565b61038661134f565b61048d61048836600461434d565b6113b5565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a00161034a565b6105036104ee366004614219565b60009081526008602052604090205460ff1690565b604051901515815260200161034a565b60005b60405161034a91906143a9565b7f0000000000000000000000000000000000000000000000000000000000000000610516565b62015f90610340565b610565610560366004614219565b6114e8565b60405161034a91906143bc565b610386610580366004614219565b6114f3565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161034a565b6104286105da3660046143e9565b61166a565b6103c76105ed36600461434d565b61179c565b7f00000000000000000000000000000000000000000000000000000000000000006105a7565b610386610626366004614422565b6117d0565b6103866106393660046142b3565b6118aa565b610386611ca7565b6105a7610654366004614219565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b610386611da9565b610386611f04565b6103866106a7366004614219565b611f75565b60005473ffffffffffffffffffffffffffffffffffffffff166105a7565b6103866106d8366004613ea2565b6120ef565b6103866106eb36600461445e565b612144565b6103866106fe36600461448c565b6123c0565b6040516003815260200161034a565b611d4c610340565b7f00000000000000000000000000000000000000000000000000000000000000006105a7565b61038661074e36600461434d565b6124b5565b610386610761366004614219565b6125ad565b6032610340565b61042861077b366004614219565b61279b565b6103866127c8565b61079b610796366004614219565b612924565b60405161034a91906144af565b7f00000000000000000000000000000000000000000000000000000000000000006105a7565b6103866107dc366004613ea2565b612cf7565b6104286107ef366004614219565b612d8e565b61038661080236600461445e565b612d99565b61086161081536600461434d565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff90911660208301520161034a565b61038661088836600461434d565b612ef7565b6108c661089b36600461434d565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161034a91906145e6565b606060006108e16002612f0b565b905080841061091c576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006109288486614629565b905081811180610936575083155b6109405780610942565b815b90506000610950868361463c565b67ffffffffffffffff8111156109685761096861464f565b604051908082528060200260200182016040528015610991578160200160208202803683370190505b50905060005b81518110156109e4576109b56109ad8883614629565b600290612f15565b8282815181106109c7576109c761467e565b6020908102919091010152806109dc816146ad565b915050610997565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a51576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a6a828483614787565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a9d9291906148a2565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610bf76002612f0b565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d9f6009612f28565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610e4257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e17575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610eab57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e80575b50505050509150945094509450945094509091929394565b610ecb612f35565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610f2b57610f2b61436a565b02179055505050565b6000818152601c60205260409020805460609190610f51906146e5565b80601f0160208091040260200160405190810160405280929190818152602001828054610f7d906146e5565b8015610fca5780601f10610f9f57610100808354040283529160200191610fca565b820191906000526020600020905b815481529060010190602001808311610fad57829003601f168201915b50505050509050919050565b610fdf82612fb8565b3373ffffffffffffffffffffffffffffffffffffffff82160361102e576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116146110d85760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f51906146e5565b611101612f35565b600e54811461113c576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e5481101561130e576000600e828154811061115e5761115e61467e565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f909252604083205491935016908585858181106111a8576111a861467e565b90506020020160208101906111bd919061434d565b905073ffffffffffffffffffffffffffffffffffffffff81161580611250575073ffffffffffffffffffffffffffffffffffffffff82161580159061122e57508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b8015611250575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611287576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112f85773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b5050508080611306906146ad565b91505061113f565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e8383604051611343939291906148ef565b60405180910390a15050565b611357612f35565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152829182918291829190829061148f57606082015160125460009161147b9170010000000000000000000000000000000090046bffffffffffffffffffffffff166149a1565b600e5490915061148b90826149f5565b9150505b8151602083015160408401516114a6908490614a20565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109ea8261306c565b6114fc81612fb8565b600081815260046020908152604091829020825160e081018452815460ff8116151580835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c0820152906115fb576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905561163a600283613117565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c01000000000000000000000000000000000000000000000000000000009091041691810191909152600090818061176983613123565b91509150611792838787601360020160049054906101000a900463ffffffff1686866000613301565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f51906146e5565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314611831576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d60205260409020611861828483614787565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a9d9291906148a2565b6012546f01000000000000000000000000000000900460ff16156118fa576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff8116611981576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600460209081526040808320815160e081018352815460ff81161515825263ffffffff610100820481168387015265010000000000820481168386015273ffffffffffffffffffffffffffffffffffffffff6901000000000000000000909204821660608401526001909301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c082015286855260059093529220549091163314611a88576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a9061334c565b816040015163ffffffff161115611ad3576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611b1390829061463c565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c1a9190614a45565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611d2d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611db1612f35565b6014546018546bffffffffffffffffffffffff90911690611dd390829061463c565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611ee0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d89190614a45565b611f0c612f35565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258906020016113ab565b611f7e81612fb8565b600081815260046020908152604091829020825160e081018452815460ff8116158015835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201529061207d576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556120bf600283613401565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120f883612fb8565b6000838152601b60205260409020612111828483614787565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a9d9291906148a2565b73ffffffffffffffffffffffffffffffffffffffff8116612191576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121f1576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e5460009161222891859170010000000000000000000000000000000090046bffffffffffffffffffffffff169061340d565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff169055601854909150612292906bffffffffffffffffffffffff83169061463c565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015612337573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061235b9190614a45565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123f5575060145463ffffffff7001000000000000000000000000000000009091048116908216115b1561242c576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61243582612fb8565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff818116600090815260106020526040902054163314612515576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b600081815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c082015291146126aa576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612707576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109ea6127a98361306c565b600084815260046020526040902054610100900463ffffffff1661166a565b6127d0612f35565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561285d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128819190614a67565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33601854846128ce919061463c565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611ec1565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e082018190526101008201526101208101919091526000828152600460209081526040808320815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606083018190526001909101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c0820152919015612abc57816060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612a93573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ab79190614a80565b612abf565b60005b90506040518061014001604052808273ffffffffffffffffffffffffffffffffffffffff168152602001836020015163ffffffff168152602001600760008781526020019081526020016000208054612b17906146e5565b80601f0160208091040260200160405190810160405280929190818152602001828054612b43906146e5565b8015612b905780601f10612b6557610100808354040283529160200191612b90565b820191906000526020600020905b815481529060010190602001808311612b7357829003601f168201915b505050505081526020018360a001516bffffffffffffffffffffffff1681526020016005600087815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001836040015163ffffffff1667ffffffffffffffff1681526020018360c0015163ffffffff16815260200183608001516bffffffffffffffffffffffff168152602001836000015115158152602001601b60008781526020019081526020016000208054612c6d906146e5565b80601f0160208091040260200160405190810160405280929190818152602001828054612c99906146e5565b8015612ce65780601f10612cbb57610100808354040283529160200191612ce6565b820191906000526020600020905b815481529060010190602001808311612cc957829003601f168201915b505050505081525092505050919050565b612d0083612fb8565b60155463ffffffff16811115612d42576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612d5b828483614787565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a9d9291906148a2565b60006109ea8261279b565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612df9576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612e48576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152601060205260409020548116908216146110d85773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612eff612f35565b612f0881613615565b50565b60006109ea825490565b6000612f21838361370a565b9392505050565b60606000612f2183613734565b60005473ffffffffffffffffffffffffffffffffffffffff163314612fb6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611d24565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314613015576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612f08576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f8110156130f9577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106130b1576130b161467e565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146130e757506000949350505050565b806130f1816146ad565b915050613073565b5081600f1a600181111561310f5761310f61436a565b949350505050565b6000612f21838361378f565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156131af573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131d39190614ab7565b50945090925050506000811315806131ea57508142105b8061320b575082801561320b5750613202824261463c565b8463ffffffff16105b1561321a57601654955061321e565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613289573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132ad9190614ab7565b50945090925050506000811315806132c457508142105b806132e557508280156132e557506132dc824261463c565b8463ffffffff16105b156132f45760175494506132f8565b8094505b50505050915091565b60008061331388878b600001516137de565b905060008061332e8b8a63ffffffff16858a8a60018b6138a0565b909250905061333d8183614a20565b9b9a5050505050505050505050565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156133825761338261436a565b036133fc57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156133d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133f79190614a67565b905090565b504390565b6000612f218383613cf9565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906136095760008160600151856134a591906149a1565b905060006134b385836149f5565b905080836040018181516134c79190614a20565b6bffffffffffffffffffffffff169052506134e28582614b07565b836060018181516134f39190614a20565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613694576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611d24565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008260000182815481106137215761372161467e565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610fca57602002820191906000526020600020905b8154815260200190600101908083116137705750505050509050919050565b60008181526001830160205260408120546137d6575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109ea565b5060006109ea565b600080808560018111156137f4576137f461436a565b03613803575062015f90613858565b60018560018111156138175761381761436a565b0361382657506201adb0613858565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61386963ffffffff85166014614b3b565b613874846001614b78565b6138839060ff16611d4c614b3b565b61388d9083614629565b6138979190614629565b95945050505050565b6000806000896080015161ffff16876138b99190614b3b565b90508380156138c75750803a105b156138cf57503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156139055761390561436a565b03613a6457604080516000815260208101909152851561396357600036604051806080016040528060488152602001614c696048913960405160200161394d93929190614b91565b60405160208183030381529060405290506139cb565b60155461397f90640100000000900463ffffffff166004614bb8565b63ffffffff1667ffffffffffffffff81111561399d5761399d61464f565b6040519080825280601f01601f1916602001820160405280156139c7576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613a1b9084906004016142a0565b602060405180830381865afa158015613a38573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a5c9190614a67565b915050613bbe565b60017f00000000000000000000000000000000000000000000000000000000000000006002811115613a9857613a9861436a565b03613bbe578415613b1a57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613aef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b139190614a67565b9050613bbe565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613b68573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b8c9190614bdb565b5050601554929450613baf93505050640100000000900463ffffffff1682614b3b565b613bba906010614b3b565b9150505b84613bda57808b6080015161ffff16613bd79190614b3b565b90505b613be861ffff871682614c25565b905060008782613bf88c8e614629565b613c029086614b3b565b613c0c9190614629565b613c1e90670de0b6b3a7640000614b3b565b613c289190614c25565b905060008c6040015163ffffffff1664e8d4a51000613c479190614b3b565b898e6020015163ffffffff16858f88613c609190614b3b565b613c6a9190614629565b613c7890633b9aca00614b3b565b613c829190614b3b565b613c8c9190614c25565b613c969190614629565b90506b033b2e3c9fd0803ce8000000613caf8284614629565b1115613ce7576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613de2576000613d1d60018361463c565b8554909150600090613d319060019061463c565b9050818114613d96576000866000018281548110613d5157613d5161467e565b9060005260206000200154905080876000018481548110613d7457613d7461467e565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613da757613da7614c39565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109ea565b60009150506109ea565b5092915050565b60008060408385031215613e0657600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613e4d57835183529284019291840191600101613e31565b50909695505050505050565b60008083601f840112613e6b57600080fd5b50813567ffffffffffffffff811115613e8357600080fd5b602083019150836020828501011115613e9b57600080fd5b9250929050565b600080600060408486031215613eb757600080fd5b83359250602084013567ffffffffffffffff811115613ed557600080fd5b613ee186828701613e59565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613f3457815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613f02565b509495945050505050565b805163ffffffff16825260006101e06020830151613f65602086018263ffffffff169052565b506040830151613f7d604086018263ffffffff169052565b506060830151613f94606086018262ffffff169052565b506080830151613faa608086018261ffff169052565b5060a0830151613fca60a08601826bffffffffffffffffffffffff169052565b5060c0830151613fe260c086018263ffffffff169052565b5060e0830151613ffa60e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a08084015181860183905261406f83870182613eee565b925050506101c08084015161409b8287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c060208801516140d360208501826bffffffffffffffffffffffff169052565b506040880151604084015260608801516140fd60608501826bffffffffffffffffffffffff169052565b506080880151608084015260a088015161411f60a085018263ffffffff169052565b5060c088015161413760c085018263ffffffff169052565b5060e088015160e08401526101008089015161415a8286018263ffffffff169052565b505061012088810151151590840152610140830181905261417d81840188613f3f565b90508281036101608401526141928187613eee565b90508281036101808401526141a78186613eee565b9150506117926101a083018460ff169052565b73ffffffffffffffffffffffffffffffffffffffff81168114612f0857600080fd5b600080604083850312156141ef57600080fd5b82356141fa816141ba565b915060208301356004811061420e57600080fd5b809150509250929050565b60006020828403121561422b57600080fd5b5035919050565b60005b8381101561424d578181015183820152602001614235565b50506000910152565b6000815180845261426e816020860160208601614232565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612f216020830184614256565b600080604083850312156142c657600080fd5b82359150602083013561420e816141ba565b600080602083850312156142eb57600080fd5b823567ffffffffffffffff8082111561430357600080fd5b818501915085601f83011261431757600080fd5b81358181111561432657600080fd5b8660208260051b850101111561433b57600080fd5b60209290920196919550909350505050565b60006020828403121561435f57600080fd5b8135612f21816141ba565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612f0857612f0861436a565b602081016143b683614399565b91905290565b60208101600283106143b6576143b661436a565b803563ffffffff811681146143e457600080fd5b919050565b600080604083850312156143fc57600080fd5b82356002811061440b57600080fd5b9150614419602084016143d0565b90509250929050565b60008060006040848603121561443757600080fd5b8335614442816141ba565b9250602084013567ffffffffffffffff811115613ed557600080fd5b6000806040838503121561447157600080fd5b823561447c816141ba565b9150602083013561420e816141ba565b6000806040838503121561449f57600080fd5b82359150614419602084016143d0565b602081526144d660208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516144ef604084018263ffffffff169052565b50604083015161014080606085015261450c610160850183614256565b9150606085015161452d60808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e0850151610100614599818701836bffffffffffffffffffffffff169052565b86015190506101206145ae8682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018387015290506117928382614256565b60208101600483106143b6576143b661436a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109ea576109ea6145fa565b818103818111156109ea576109ea6145fa565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036146de576146de6145fa565b5060010190565b600181811c908216806146f957607f821691505b602082108103614732577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561478257600081815260208120601f850160051c8101602086101561475f5750805b601f850160051c820191505b8181101561477e5782815560010161476b565b5050505b505050565b67ffffffffffffffff83111561479f5761479f61464f565b6147b3836147ad83546146e5565b83614738565b6000601f84116001811461480557600085156147cf5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561489b565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156148545786850135825560209485019460019092019101614834565b508682101561488f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561494657815473ffffffffffffffffffffffffffffffffffffffff1684529284019260019182019101614914565b505050838103828501528481528590820160005b8681101561499557823561496d816141ba565b73ffffffffffffffffffffffffffffffffffffffff168252918301919083019060010161495a565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613dec57613dec6145fa565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff80841680614a1457614a146149c6565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613dec57613dec6145fa565b600060208284031215614a5757600080fd5b81518015158114612f2157600080fd5b600060208284031215614a7957600080fd5b5051919050565b600060208284031215614a9257600080fd5b8151612f21816141ba565b805169ffffffffffffffffffff811681146143e457600080fd5b600080600080600060a08688031215614acf57600080fd5b614ad886614a9d565b9450602086015193506040860151925060608601519150614afb60808701614a9d565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614b3257614b326145fa565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b7357614b736145fa565b500290565b60ff81811683821601908111156109ea576109ea6145fa565b828482376000838201600081528351614bae818360208801614232565b0195945050505050565b600063ffffffff80831681851681830481118215151615614b3257614b326145fa565b60008060008060008060c08789031215614bf457600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614c3457614c346149c6565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryLogicBABI = KeeperRegistryLogicBMetaData.ABI @@ -795,6 +795,28 @@ func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) GetUpkeepTrigger return _KeeperRegistryLogicB.Contract.GetUpkeepTriggerConfig(&_KeeperRegistryLogicB.CallOpts, upkeepId) } +func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) HasDedupKey(opts *bind.CallOpts, dedupKey [32]byte) (bool, error) { + var out []interface{} + err := _KeeperRegistryLogicB.contract.Call(opts, &out, "hasDedupKey", dedupKey) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_KeeperRegistryLogicB *KeeperRegistryLogicBSession) HasDedupKey(dedupKey [32]byte) (bool, error) { + return _KeeperRegistryLogicB.Contract.HasDedupKey(&_KeeperRegistryLogicB.CallOpts, dedupKey) +} + +func (_KeeperRegistryLogicB *KeeperRegistryLogicBCallerSession) HasDedupKey(dedupKey [32]byte) (bool, error) { + return _KeeperRegistryLogicB.Contract.HasDedupKey(&_KeeperRegistryLogicB.CallOpts, dedupKey) +} + func (_KeeperRegistryLogicB *KeeperRegistryLogicBCaller) Owner(opts *bind.CallOpts) (common.Address, error) { var out []interface{} err := _KeeperRegistryLogicB.contract.Call(opts, &out, "owner") @@ -1302,9 +1324,9 @@ func (it *KeeperRegistryLogicBCancelledUpkeepReportIterator) Close() error { } type KeeperRegistryLogicBCancelledUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) FilterCancelledUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicBCancelledUpkeepReportIterator, error) { @@ -1369,6 +1391,133 @@ func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) ParseCancelledUpkeepR return event, nil } +type KeeperRegistryLogicBDedupKeyAddedIterator struct { + Event *KeeperRegistryLogicBDedupKeyAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryLogicBDedupKeyAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryLogicBDedupKeyAdded) + 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(KeeperRegistryLogicBDedupKeyAdded) + 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 *KeeperRegistryLogicBDedupKeyAddedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryLogicBDedupKeyAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryLogicBDedupKeyAdded struct { + DedupKey [32]byte + Raw types.Log +} + +func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*KeeperRegistryLogicBDedupKeyAddedIterator, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _KeeperRegistryLogicB.contract.FilterLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return &KeeperRegistryLogicBDedupKeyAddedIterator{contract: _KeeperRegistryLogicB.contract, event: "DedupKeyAdded", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryLogicBDedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _KeeperRegistryLogicB.contract.WatchLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryLogicBDedupKeyAdded) + if err := _KeeperRegistryLogicB.contract.UnpackLog(event, "DedupKeyAdded", 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 (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) ParseDedupKeyAdded(log types.Log) (*KeeperRegistryLogicBDedupKeyAdded, error) { + event := new(KeeperRegistryLogicBDedupKeyAdded) + if err := _KeeperRegistryLogicB.contract.UnpackLog(event, "DedupKeyAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type KeeperRegistryLogicBFundsAddedIterator struct { Event *KeeperRegistryLogicBFundsAdded @@ -1696,9 +1845,9 @@ func (it *KeeperRegistryLogicBInsufficientFundsUpkeepReportIterator) Close() err } type KeeperRegistryLogicBInsufficientFundsUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) FilterInsufficientFundsUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicBInsufficientFundsUpkeepReportIterator, error) { @@ -2884,9 +3033,9 @@ func (it *KeeperRegistryLogicBReorgedUpkeepReportIterator) Close() error { } type KeeperRegistryLogicBReorgedUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) FilterReorgedUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicBReorgedUpkeepReportIterator, error) { @@ -3012,9 +3161,9 @@ func (it *KeeperRegistryLogicBStaleUpkeepReportIterator) Close() error { } type KeeperRegistryLogicBStaleUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) FilterStaleUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryLogicBStaleUpkeepReportIterator, error) { @@ -4323,13 +4472,13 @@ func (it *KeeperRegistryLogicBUpkeepPerformedIterator) Close() error { } type KeeperRegistryLogicBUpkeepPerformed struct { - Id *big.Int - Success bool - TotalPayment *big.Int - GasUsed *big.Int - GasOverhead *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Success bool + TotalPayment *big.Int + GasUsed *big.Int + GasOverhead *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistryLogicB *KeeperRegistryLogicBFilterer) FilterUpkeepPerformed(opts *bind.FilterOpts, id []*big.Int, success []bool) (*KeeperRegistryLogicBUpkeepPerformedIterator, error) { @@ -5068,6 +5217,8 @@ func (_KeeperRegistryLogicB *KeeperRegistryLogicB) ParseLog(log types.Log) (gene return _KeeperRegistryLogicB.ParseAdminPrivilegeConfigSet(log) case _KeeperRegistryLogicB.abi.Events["CancelledUpkeepReport"].ID: return _KeeperRegistryLogicB.ParseCancelledUpkeepReport(log) + case _KeeperRegistryLogicB.abi.Events["DedupKeyAdded"].ID: + return _KeeperRegistryLogicB.ParseDedupKeyAdded(log) case _KeeperRegistryLogicB.abi.Events["FundsAdded"].ID: return _KeeperRegistryLogicB.ParseFundsAdded(log) case _KeeperRegistryLogicB.abi.Events["FundsWithdrawn"].ID: @@ -5135,7 +5286,11 @@ func (KeeperRegistryLogicBAdminPrivilegeConfigSet) Topic() common.Hash { } func (KeeperRegistryLogicBCancelledUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d") + return common.HexToHash("0xc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd5636") +} + +func (KeeperRegistryLogicBDedupKeyAdded) Topic() common.Hash { + return common.HexToHash("0xa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f2") } func (KeeperRegistryLogicBFundsAdded) Topic() common.Hash { @@ -5147,7 +5302,7 @@ func (KeeperRegistryLogicBFundsWithdrawn) Topic() common.Hash { } func (KeeperRegistryLogicBInsufficientFundsUpkeepReport) Topic() common.Hash { - return common.HexToHash("0xfcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e") + return common.HexToHash("0x377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e02") } func (KeeperRegistryLogicBOwnerFundsWithdrawn) Topic() common.Hash { @@ -5183,11 +5338,11 @@ func (KeeperRegistryLogicBPaymentWithdrawn) Topic() common.Hash { } func (KeeperRegistryLogicBReorgedUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d38868") + return common.HexToHash("0x6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301") } func (KeeperRegistryLogicBStaleUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b11") + return common.HexToHash("0x405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8") } func (KeeperRegistryLogicBUnpaused) Topic() common.Hash { @@ -5227,7 +5382,7 @@ func (KeeperRegistryLogicBUpkeepPaused) Topic() common.Hash { } func (KeeperRegistryLogicBUpkeepPerformed) Topic() common.Hash { - return common.HexToHash("0xdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c6") + return common.HexToHash("0xad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b") } func (KeeperRegistryLogicBUpkeepPrivilegeConfigSet) Topic() common.Hash { @@ -5311,6 +5466,8 @@ type KeeperRegistryLogicBInterface interface { GetUpkeepTriggerConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) + HasDedupKey(opts *bind.CallOpts, dedupKey [32]byte) (bool, error) + Owner(opts *bind.CallOpts) (common.Address, error) UpkeepTranscoderVersion(opts *bind.CallOpts) (uint8, error) @@ -5371,6 +5528,12 @@ type KeeperRegistryLogicBInterface interface { ParseCancelledUpkeepReport(log types.Log) (*KeeperRegistryLogicBCancelledUpkeepReport, error) + FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*KeeperRegistryLogicBDedupKeyAddedIterator, error) + + WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryLogicBDedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) + + ParseDedupKeyAdded(log types.Log) (*KeeperRegistryLogicBDedupKeyAdded, error) + FilterFundsAdded(opts *bind.FilterOpts, id []*big.Int, from []common.Address) (*KeeperRegistryLogicBFundsAddedIterator, error) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryLogicBFundsAdded, id []*big.Int, from []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go index 6d6bdbede9e..1e1b8449aa6 100644 --- a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go @@ -49,8 +49,8 @@ type KeeperRegistryBase21OnchainConfig struct { } var KeeperRegistryMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"upkeepTriggerID\",\"type\":\"bytes32\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101406040523480156200001257600080fd5b5060405162005476380380620054768339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614fd5620004a16000396000818160d6015261016f01526000505060008181612e73015281816131dc0152818161336f0152613a1201526000505060005050600061043b0152614fd56000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063aed2e92911610081578063e29b753c1161005b578063e29b753c146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063aed2e92914610262578063afcb95d71461028c578063b1dc65a4146102d5576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613c91565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d1a565b610423565b610275610270366004613d76565b61063f565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102e3366004613e07565b6107a7565b6101196102f6366004614282565b611375565b61011961030936600461434f565b61218c565b61011961031c3660046143de565b6121b5565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da828401846143fb565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff16614443565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da908590614468565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b60008061064a6121c9565b6012546e010000000000000000000000000000900460ff1615610699576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f8901859004850281018501909552878552909361079893899089908190840183828082843760009201919091525061220392505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506108d5576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff1661091e576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a351461095a576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516109679060016144aa565b60ff16861415806109785750858414155b156109af576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109bf8a8a8a8a8a8a8a8a61240e565b60006109cb8a8a612677565b9050600081604001515167ffffffffffffffff8111156109ed576109ed613ebe565b604051908082528060200260200182016040528015610ab957816020015b6040805161020081018252600061012082018181526101408301829052610160830182905261018083018290526101a083018290526101c083018290526101e0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e0820181905261010082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181610a0b5790505b5090506000805b836040015151811015610f69576004600085604001518381518110610ae757610ae761447b565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201528351849083908110610bcc57610bcc61447b565b602002602001015160000181905250610c0184604001518281518110610bf457610bf461447b565b6020026020010151612732565b838281518110610c1357610c1361447b565b6020026020010151608001906001811115610c3057610c306144c3565b90816001811115610c4357610c436144c3565b81525050610cb785848381518110610c5d57610c5d61447b565b60200260200101516080015186606001518481518110610c7f57610c7f61447b565b60200260200101518760a001518581518110610c9d57610c9d61447b565b6020026020010151518860000151896020015160016127dd565b838281518110610cc957610cc961447b565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050610d3b84604001518281518110610d1057610d1061447b565b602002602001015185608001518381518110610d2e57610d2e61447b565b6020026020010151612828565b838281518110610d4d57610d4d61447b565b602002602001015160e0018181525050610dbb84604001518281518110610d7657610d7661447b565b602002602001015185608001518381518110610d9457610d9461447b565b6020026020010151858481518110610dae57610dae61447b565b602002602001015161285b565b848381518110610dcd57610dcd61447b565b6020026020010151602001858481518110610dea57610dea61447b565b6020026020010151610100018281525082151515158152505050828181518110610e1657610e1661447b565b60200260200101516020015115610e3957610e326001836144f2565b9150610e3e565b610f57565b610ea4838281518110610e5357610e5361447b565b6020026020010151600001516060015185606001518381518110610e7957610e7961447b565b60200260200101518660a001518481518110610e9757610e9761447b565b6020026020010151612203565b848381518110610eb657610eb661447b565b6020026020010151606001858481518110610ed357610ed361447b565b602002602001015160a0018281525082151515158152505050828181518110610efe57610efe61447b565b602002602001015160a0015186610f15919061450d565b9550610f5784604001518281518110610f3057610f3061447b565b6020026020010151848381518110610f4a57610f4a61447b565b60200260200101516129e6565b80610f6181614520565b915050610ac0565b508061ffff16600003610f8057505050505061136b565b8351610f8d9060016144aa565b610f9c9060ff1661044c614558565b616b6c610faa8d6010614558565b5a610fb5908961450d565b610fbf9190614468565b610fc99190614468565b610fd39190614468565b9450611b58610fe661ffff8316876145c4565b610ff09190614468565b945060008060008060005b87604001515181101561120d5786818151811061101a5761101a61447b565b602002602001015160200151156111fb576110768a8883815181106110415761104161447b565b6020026020010151608001518a60a0015184815181106110635761106361447b565b6020026020010151518c60000151612acf565b8782815181106110885761108861447b565b602002602001015160c00181815250506110e489896040015183815181106110b2576110b261447b565b60200260200101518984815181106110cc576110cc61447b565b60200260200101518b600001518c602001518b612aef565b90935091506110f38285614443565b93506110ff8386614443565b94508681815181106111135761111361447b565b6020026020010151606001511515886040015182815181106111375761113761447b565b60200260200101517fdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c6848661116c9190614443565b8a858151811061117e5761117e61447b565b602002602001015160a001518b868151811061119c5761119c61447b565b602002602001015160c001518c87815181106111ba576111ba61447b565b60209081029190910181015160e00151604080516bffffffffffffffffffffffff909616865291850193909352830152606082015260800160405180910390a35b8061120581614520565b915050610ffb565b5050336000908152600b6020526040902080548492506002906112459084906201000090046bffffffffffffffffffffffff16614443565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff1661129f9190614443565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f6001600381106112e2576112e261447b565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff16111561136157601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b61137d612be2565b601f865111156113b9576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff166000036113f6576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b84518651141580611415575061140d8460036145d8565b60ff16865111155b1561144c576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff168110156114e1576114ce600e82815481106114a5576114a561447b565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612c63565b50806114d981614520565b915050611479565b5060008060005b836bffffffffffffffffffffffff168110156115ea57600d81815481106115115761151161447b565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff9092169450908290811061154c5761154c61447b565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806115e281614520565b9150506114e8565b506115f7600d6000613b66565b611603600e6000613b66565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c5181101561198757600c60008e83815181106116485761164861447b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff16156116b3576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106116e4576116e461447b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c908290811061178c5761178c61447b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015294509250611851576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909516949094171791909116929092179190911790558061197f81614520565b915050611629565b50508a5161199d9150600d9060208d0190613b84565b5088516119b190600e9060208c0190613b84565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff169050611f73612e6d565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff9384160217808255600192601891611fee9185917801000000000000000000000000000000000000000000000000900416614601565b92506101000a81548163ffffffff021916908363ffffffff16021790555060008860405160200161201f919061466f565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905260145490915061208890469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f612f22565b60115560005b6120986009612fcc565b8110156120c8576120b56120ad600983612fd6565b600990612fe2565b50806120c081614520565b91505061208e565b5060005b896101a001515181101561211f5761210c8a6101a0015182815181106120f4576120f461447b565b6020026020010151600961300490919063ffffffff16565b508061211781614520565b9150506120cc565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f604051612176999897969594939291906147d3565b60405180910390a1505050505050505050505050565b6121ad868686868060200190518101906121a69190614904565b8686611375565b505050505050565b6121bd612be2565b6121c681613026565b50565b3215612201576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60125460009081906f01000000000000000000000000000000900460ff1615612258576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b00000000000000000000000000000000000000000000000000000000906122c5908590602401613c91565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906123989087908790600401614a5e565b60408051808303816000875af11580156123b6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906123da9190614a77565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b60008787604051612420929190614aaa565b604051908190038120612437918b90602001614aba565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b8881101561260e576001858783602081106124a3576124a361447b565b6124b091901a601b6144aa565b8c8c858181106124c2576124c261447b565b905060200201358b8b868181106124db576124db61447b565b9050602002013560405160008152602001604052604051612518949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561253a573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff80821615158085526101009092041693830193909352909550935090506125e8576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b84019350808061260690614520565b915050612486565b50827e01010101010101010101010101010101010101010101010101010101010101841614612669576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b6126b06040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b60006126be83850185614bab565b60408101515160608201515191925090811415806126e157508082608001515114155b806126f15750808260a001515114155b15612728576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5090505b92915050565b6000818160045b600f8110156127bf577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106127775761277761447b565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146127ad57506000949350505050565b806127b781614520565b915050612739565b5081600f1a60018111156127d5576127d56144c3565b949350505050565b6000806127ef88878b6000015161311b565b905060008061280a8b8a63ffffffff16858a8a60018b6131a7565b90925090506128198183614443565b9b9a5050505050505050505050565b6000828260405160200161283d929190614c98565b60405160208183030381529060405280519060200120905092915050565b600080808084608001516001811115612876576128766144c3565b0361289a57612886868686613600565b6128955760009250905061079f565b612911565b6001846080015160018111156128b2576128b26144c3565b036128df5760006128c4878787613700565b92509050806128d9575060009250905061079f565b50612911565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612919612e6d565b84516040015163ffffffff161161297357857f846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d8560e0015160405161296091815260200190565b60405180910390a260009250905061079f565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff1610156129d957857ffcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e8560e0015160405161296091815260200190565b6001969095509350505050565b6000816080015160018111156129fe576129fe6144c3565b03612a7057612a0b612e6d565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612a8857612a886144c3565b03612acb57610100810151600090815260086020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790555b5050565b6000612adc84848461311b565b9050808510156127d55750929392505050565b600080612b0a888760a001518860c0015188888860016131a7565b90925090506000612b1b8284614443565b600089815260046020526040902060010180549192508291600c90612b5f9084906c0100000000000000000000000090046bffffffffffffffffffffffff16614cbe565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612ba891859116614443565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314612201576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015290612e5f576000816060015185612cfb9190614cbe565b90506000612d098583614ce3565b90508083604001818151612d1d9190614443565b6bffffffffffffffffffffffff16905250612d388582614d0e565b83606001818151612d499190614443565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115612ea357612ea36144c3565b03612f1d57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612ef4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f189190614d42565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a604051602001612f4699989796959493929190614d5b565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b600061272c825490565b6000612e668383613899565b6000612e668373ffffffffffffffffffffffffffffffffffffffff84166138c3565b6000612e668373ffffffffffffffffffffffffffffffffffffffff84166139bd565b3373ffffffffffffffffffffffffffffffffffffffff8216036130a5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008080856001811115613131576131316144c3565b03613140575062015f9061315f565b6001856001811115613154576131546144c3565b036128df57506201adb05b61317063ffffffff85166014614558565b61317b8460016144aa565b61318a9060ff16611d4c614558565b6131949083614468565b61319e9190614468565b95945050505050565b6000806000896080015161ffff16876131c09190614558565b90508380156131ce5750803a105b156131d657503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561320c5761320c6144c3565b0361336b57604080516000815260208101909152851561326a57600036604051806080016040528060488152602001614f816048913960405160200161325493929190614df0565b60405160208183030381529060405290506132d2565b60155461328690640100000000900463ffffffff166004614e17565b63ffffffff1667ffffffffffffffff8111156132a4576132a4613ebe565b6040519080825280601f01601f1916602001820160405280156132ce576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613322908490600401613c91565b602060405180830381865afa15801561333f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133639190614d42565b9150506134c5565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111561339f5761339f6144c3565b036134c557841561342157606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156133f6573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061341a9190614d42565b90506134c5565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801561346f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134939190614e3a565b50506015549294506134b693505050640100000000900463ffffffff1682614558565b6134c1906010614558565b9150505b846134e157808b6080015161ffff166134de9190614558565b90505b6134ef61ffff8716826145c4565b9050600087826134ff8c8e614468565b6135099086614558565b6135139190614468565b61352590670de0b6b3a7640000614558565b61352f91906145c4565b905060008c6040015163ffffffff1664e8d4a5100061354e9190614558565b898e6020015163ffffffff16858f886135679190614558565b6135719190614468565b61357f90633b9aca00614558565b6135899190614558565b61359391906145c4565b61359d9190614468565b90506b033b2e3c9fd0803ce80000006135b68284614468565b11156135ee576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906136179190614e84565b835160c00151815191925063ffffffff9081169116101561367a57847f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118460e0015160405161366891815260200190565b60405180910390a26000915050612e66565b6020810151158015906136a157506020810151815161369e9063ffffffff16613a0c565b14155b806136ba57506136af612e6d565b815163ffffffff1610155b156136f557847f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688460e0015160405161366891815260200190565b506001949350505050565b6000806000848060200190518101906137199190614edc565b90506000868260000151836020015160405160200161377093929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101206060830151909150158015906137d2575081606001516137cf836040015163ffffffff16613a0c565b14155b806137ee57506137e0612e6d565b826040015163ffffffff1610155b1561383e57867f07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d388688660e0015160405161382991815260200190565b60405180910390a260009350915061079f9050565b60008181526008602052604090205460ff161561388b57867f909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b118660e0015160405161382991815260200190565b600197909650945050505050565b60008260000182815481106138b0576138b061447b565b9060005260206000200154905092915050565b600081815260018301602052604081205480156139ac5760006138e760018361450d565b85549091506000906138fb9060019061450d565b905081811461396057600086600001828154811061391b5761391b61447b565b906000526020600020015490508087600001848154811061393e5761393e61447b565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061397157613971614f51565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061272c565b600091505061272c565b5092915050565b6000818152600183016020526040812054613a045750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561272c565b50600061272c565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a4257613a426144c3565b03613b5c576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613a95573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ab99190614d42565b90508083101580613ad45750610100613ad2848361450d565b115b15613ae25750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b38573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e669190614d42565b504090565b919050565b50805460008255906000526020600020908101906121c69190613c0e565b828054828255906000526020600020908101928215613bfe579160200282015b82811115613bfe57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613ba4565b50613c0a929150613c0e565b5090565b5b80821115613c0a5760008155600101613c0f565b60005b83811015613c3e578181015183820152602001613c26565b50506000910152565b60008151808452613c5f816020860160208601613c23565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612e666020830184613c47565b73ffffffffffffffffffffffffffffffffffffffff811681146121c657600080fd5b8035613b6181613ca4565b60008083601f840112613ce357600080fd5b50813567ffffffffffffffff811115613cfb57600080fd5b602083019150836020828501011115613d1357600080fd5b9250929050565b60008060008060608587031215613d3057600080fd5b8435613d3b81613ca4565b935060208501359250604085013567ffffffffffffffff811115613d5e57600080fd5b613d6a87828801613cd1565b95989497509550505050565b600080600060408486031215613d8b57600080fd5b83359250602084013567ffffffffffffffff811115613da957600080fd5b613db586828701613cd1565b9497909650939450505050565b60008083601f840112613dd457600080fd5b50813567ffffffffffffffff811115613dec57600080fd5b6020830191508360208260051b8501011115613d1357600080fd5b60008060008060008060008060e0898b031215613e2357600080fd5b606089018a811115613e3457600080fd5b8998503567ffffffffffffffff80821115613e4e57600080fd5b613e5a8c838d01613cd1565b909950975060808b0135915080821115613e7357600080fd5b613e7f8c838d01613dc2565b909750955060a08b0135915080821115613e9857600080fd5b50613ea58b828c01613dc2565b999c989b50969995989497949560c00135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613f1157613f11613ebe565b60405290565b60405160c0810167ffffffffffffffff81118282101715613f1157613f11613ebe565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613f8157613f81613ebe565b604052919050565b600067ffffffffffffffff821115613fa357613fa3613ebe565b5060051b60200190565b600082601f830112613fbe57600080fd5b81356020613fd3613fce83613f89565b613f3a565b82815260059290921b84018101918181019086841115613ff257600080fd5b8286015b8481101561401657803561400981613ca4565b8352918301918301613ff6565b509695505050505050565b803560ff81168114613b6157600080fd5b63ffffffff811681146121c657600080fd5b8035613b6181614032565b62ffffff811681146121c657600080fd5b8035613b618161404f565b61ffff811681146121c657600080fd5b8035613b618161406b565b6bffffffffffffffffffffffff811681146121c657600080fd5b8035613b6181614086565b60006101e082840312156140be57600080fd5b6140c6613eed565b90506140d182614044565b81526140df60208301614044565b60208201526140f060408301614044565b604082015261410160608301614060565b60608201526141126080830161407b565b608082015261412360a083016140a0565b60a082015261413460c08301614044565b60c082015261414560e08301614044565b60e0820152610100614158818401614044565b9082015261012061416a838201614044565b9082015261014082810135908201526101608083013590820152610180614192818401613cc6565b908201526101a08281013567ffffffffffffffff8111156141b257600080fd5b6141be85828601613fad565b8284015250506101c06141d2818401613cc6565b9082015292915050565b803567ffffffffffffffff81168114613b6157600080fd5b600082601f83011261420557600080fd5b813567ffffffffffffffff81111561421f5761421f613ebe565b61425060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f3a565b81815284602083860101111561426557600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c0878903121561429b57600080fd5b863567ffffffffffffffff808211156142b357600080fd5b6142bf8a838b01613fad565b975060208901359150808211156142d557600080fd5b6142e18a838b01613fad565b96506142ef60408a01614021565b9550606089013591508082111561430557600080fd5b6143118a838b016140ab565b945061431f60808a016141dc565b935060a089013591508082111561433557600080fd5b5061434289828a016141f4565b9150509295509295509295565b60008060008060008060c0878903121561436857600080fd5b863567ffffffffffffffff8082111561438057600080fd5b61438c8a838b01613fad565b975060208901359150808211156143a257600080fd5b6143ae8a838b01613fad565b96506143bc60408a01614021565b955060608901359150808211156143d257600080fd5b6143118a838b016141f4565b6000602082840312156143f057600080fd5b8135612e6681613ca4565b60006020828403121561440d57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156139b6576139b6614414565b8082018082111561272c5761272c614414565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60ff818116838216019081111561272c5761272c614414565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156139b6576139b6614414565b8181038181111561272c5761272c614414565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361455157614551614414565b5060010190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048311821515161561459057614590614414565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826145d3576145d3614595565b500490565b600060ff821660ff84168160ff04811182151516156145f9576145f9614414565b029392505050565b63ffffffff8181168382160190808211156139b6576139b6614414565b600081518084526020808501945080840160005b8381101561466457815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614632565b509495945050505050565b6020815261468660208201835163ffffffff169052565b6000602083015161469f604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e08301516101006147188185018363ffffffff169052565b84015190506101206147318482018363ffffffff169052565b840151905061014061474a8482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a061478d8185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526147ad61020086018461461e565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526148038184018a61461e565b90508281036080840152614817818961461e565b905060ff871660a084015282810360c08401526148348187613c47565b905067ffffffffffffffff851660e08401528281036101008401526148598185613c47565b9c9b505050505050505050505050565b8051613b6181614032565b8051613b618161404f565b8051613b618161406b565b8051613b6181614086565b8051613b6181613ca4565b600082601f8301126148b157600080fd5b815160206148c1613fce83613f89565b82815260059290921b840181019181810190868411156148e057600080fd5b8286015b848110156140165780516148f781613ca4565b83529183019183016148e4565b60006020828403121561491657600080fd5b815167ffffffffffffffff8082111561492e57600080fd5b908301906101e0828603121561494357600080fd5b61494b613eed565b61495483614869565b815261496260208401614869565b602082015261497360408401614869565b604082015261498460608401614874565b60608201526149956080840161487f565b60808201526149a660a0840161488a565b60a08201526149b760c08401614869565b60c08201526149c860e08401614869565b60e08201526101006149db818501614869565b908201526101206149ed848201614869565b9082015261014083810151908201526101608084015190820152610180614a15818501614895565b908201526101a08381015183811115614a2d57600080fd5b614a39888287016148a0565b8284015250506101c09150614a4f828401614895565b91810191909152949350505050565b8281526040602082015260006127d56040830184613c47565b60008060408385031215614a8a57600080fd5b82518015158114614a9a57600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614ae157600080fd5b81356020614af1613fce83613f89565b82815260059290921b84018101918181019086841115614b1057600080fd5b8286015b848110156140165780358352918301918301614b14565b600082601f830112614b3c57600080fd5b81356020614b4c613fce83613f89565b82815260059290921b84018101918181019086841115614b6b57600080fd5b8286015b8481101561401657803567ffffffffffffffff811115614b8f5760008081fd5b614b9d8986838b01016141f4565b845250918301918301614b6f565b600060208284031215614bbd57600080fd5b813567ffffffffffffffff80821115614bd557600080fd5b9083019060c08286031215614be957600080fd5b614bf1613f17565b8235815260208301356020820152604083013582811115614c1157600080fd5b614c1d87828601614ad0565b604083015250606083013582811115614c3557600080fd5b614c4187828601614ad0565b606083015250608083013582811115614c5957600080fd5b614c6587828601614b2b565b60808301525060a083013582811115614c7d57600080fd5b614c8987828601614b2b565b60a08301525095945050505050565b82815260008251614cb0816020850160208701613c23565b919091016020019392505050565b6bffffffffffffffffffffffff8281168282160390808211156139b6576139b6614414565b60006bffffffffffffffffffffffff80841680614d0257614d02614595565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614d3957614d39614414565b02949350505050565b600060208284031215614d5457600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614da28285018b61461e565b91508382036080850152614db6828a61461e565b915060ff881660a085015283820360c0850152614dd38288613c47565b90861660e085015283810361010085015290506148598185613c47565b828482376000838201600081528351614e0d818360208801613c23565b0195945050505050565b600063ffffffff80831681851681830481118215151615614d3957614d39614414565b60008060008060008060c08789031215614e5357600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614e9657600080fd5b6040516040810181811067ffffffffffffffff82111715614eb957614eb9613ebe565b6040528251614ec781614032565b81526020928301519281019290925250919050565b600060808284031215614eee57600080fd5b6040516080810181811067ffffffffffffffff82111715614f1157614f11613ebe565b604052825181526020830151614f2681614032565b60208201526040830151614f3981614032565b60408201526060928301519281019290925250919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x6101406040523480156200001257600080fd5b50604051620053d4380380620053d48339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614f33620004a16000396000818160d6015261016f01526000505060008181612dd20152818161313b015281816132ce015261395901526000505060005050600061043b0152614f336000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063aed2e92911610081578063e29b753c1161005b578063e29b753c146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063aed2e92914610262578063afcb95d71461028c578063b1dc65a4146102d5576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613bd8565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613c61565b610423565b610275610270366004613cbd565b61063f565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102e3366004613d4e565b6107a7565b6101196102f63660046141c9565b6112ea565b610119610309366004614296565b612101565b61011961031c366004614325565b61212a565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da82840184614342565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff1661438a565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da9085906143af565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b60008061064a61213e565b6012546e010000000000000000000000000000900460ff1615610699576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f8901859004850281018501909552878552909361079893899089908190840183828082843760009201919091525061217892505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506108d5576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff1661091e576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a351461095a576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516109679060016143f1565b60ff16861415806109785750858414155b156109af576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109bf8a8a8a8a8a8a8a8a612383565b60006109cb8a8a6125ec565b9050600081604001515167ffffffffffffffff8111156109ed576109ed613e05565b604051908082528060200260200182016040528015610ab157816020015b604080516101e0810182526000610100820181815261012083018290526101408301829052610160830182905261018083018290526101a083018290526101c0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181610a0b5790505b5090506000805b836040015151811015610efa576004600085604001518381518110610adf57610adf6143c2565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201528351849083908110610bc457610bc46143c2565b602002602001015160000181905250610bf984604001518281518110610bec57610bec6143c2565b60200260200101516126a7565b838281518110610c0b57610c0b6143c2565b6020026020010151608001906001811115610c2857610c2861440a565b90816001811115610c3b57610c3b61440a565b81525050610caf85848381518110610c5557610c556143c2565b60200260200101516080015186606001518481518110610c7757610c776143c2565b60200260200101518760a001518581518110610c9557610c956143c2565b602002602001015151886000015189602001516001612752565b838281518110610cc157610cc16143c2565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050610d4d84604001518281518110610d0857610d086143c2565b602002602001015185608001518381518110610d2657610d266143c2565b6020026020010151858481518110610d4057610d406143c2565b602002602001015161279d565b848381518110610d5f57610d5f6143c2565b6020026020010151602001858481518110610d7c57610d7c6143c2565b602002602001015160e0018281525082151515158152505050828181518110610da757610da76143c2565b60200260200101516020015115610dca57610dc3600183614439565b9150610dcf565b610ee8565b610e35838281518110610de457610de46143c2565b6020026020010151600001516060015185606001518381518110610e0a57610e0a6143c2565b60200260200101518660a001518481518110610e2857610e286143c2565b6020026020010151612178565b848381518110610e4757610e476143c2565b6020026020010151606001858481518110610e6457610e646143c2565b602002602001015160a0018281525082151515158152505050828181518110610e8f57610e8f6143c2565b602002602001015160a0015186610ea69190614454565b9550610ee884604001518281518110610ec157610ec16143c2565b6020026020010151848381518110610edb57610edb6143c2565b602002602001015161291c565b80610ef281614467565b915050610ab8565b508061ffff16600003610f115750505050506112e0565b8351610f1e9060016143f1565b610f2d9060ff1661044c61449f565b616b6c610f3b8d601061449f565b5a610f469089614454565b610f5091906143af565b610f5a91906143af565b610f6491906143af565b9450611b58610f7761ffff83168761450b565b610f8191906143af565b945060008060008060005b87604001515181101561118257868181518110610fab57610fab6143c2565b60200260200101516020015115611170576110078a888381518110610fd257610fd26143c2565b6020026020010151608001518a60a001518481518110610ff457610ff46143c2565b6020026020010151518c60000151612a2e565b878281518110611019576110196143c2565b602002602001015160c00181815250506110758989604001518381518110611043576110436143c2565b602002602001015189848151811061105d5761105d6143c2565b60200260200101518b600001518c602001518b612a4e565b9093509150611084828561438a565b9350611090838661438a565b94508681815181106110a4576110a46143c2565b6020026020010151606001511515886040015182815181106110c8576110c86143c2565b60200260200101517fad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b84866110fd919061438a565b8a858151811061110f5761110f6143c2565b602002602001015160a001518b868151811061112d5761112d6143c2565b602002602001015160c001518d60800151878151811061114f5761114f6143c2565b6020026020010151604051611167949392919061451f565b60405180910390a35b8061117a81614467565b915050610f8c565b5050336000908152600b6020526040902080548492506002906111ba9084906201000090046bffffffffffffffffffffffff1661438a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff16611214919061438a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f600160038110611257576112576143c2565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff1611156112d657601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6112f2612b41565b601f8651111561132e576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff1660000361136b576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8451865114158061138a575061138284600361455c565b60ff16865111155b156113c1576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff1681101561145657611443600e828154811061141a5761141a6143c2565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612bc2565b508061144e81614467565b9150506113ee565b5060008060005b836bffffffffffffffffffffffff1681101561155f57600d8181548110611486576114866143c2565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff909216945090829081106114c1576114c16143c2565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905591508061155781614467565b91505061145d565b5061156c600d6000613aad565b611578600e6000613aad565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c518110156118fc57600c60008e83815181106115bd576115bd6143c2565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff1615611628576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f8481518110611659576116596143c2565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110611701576117016143c2565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152945092506117c6576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090951694909417179190911692909217919091179055806118f481614467565b91505061159e565b50508a516119129150600d9060208d0190613acb565b50885161192690600e9060208c0190613acb565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff169050611ee8612dcc565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff9384160217808255600192601891611f639185917801000000000000000000000000000000000000000000000000900416614585565b92506101000a81548163ffffffff021916908363ffffffff160217905550600088604051602001611f9491906145f3565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152919052601454909150611ffd90469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f612e81565b60115560005b61200d6009612f2b565b81101561203d5761202a612022600983612f35565b600990612f41565b508061203581614467565b915050612003565b5060005b896101a0015151811015612094576120818a6101a001518281518110612069576120696143c2565b60200260200101516009612f6390919063ffffffff16565b508061208c81614467565b915050612041565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f6040516120eb99989796959493929190614757565b60405180910390a1505050505050505050505050565b6121228686868680602001905181019061211b9190614888565b86866112ea565b505050505050565b612132612b41565b61213b81612f85565b50565b3215612176576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60125460009081906f01000000000000000000000000000000900460ff16156121cd576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b000000000000000000000000000000000000000000000000000000009061223a908590602401613bd8565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d169061230d90879087906004016149e2565b60408051808303816000875af115801561232b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061234f91906149fb565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b60008787604051612395929190614a2e565b6040519081900381206123ac918b90602001614a3e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b8881101561258357600185878360208110612418576124186143c2565b61242591901a601b6143f1565b8c8c85818110612437576124376143c2565b905060200201358b8b86818110612450576124506143c2565b905060200201356040516000815260200160405260405161248d949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156124af573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff808216151580855261010090920416938301939093529095509350905061255d576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b84019350808061257b90614467565b9150506123fb565b50827e010101010101010101010101010101010101010101010101010101010101018416146125de576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b6126256040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b600061263383850185614b2f565b604081015151606082015151919250908114158061265657508082608001515114155b806126665750808260a001515114155b1561269d576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5090505b92915050565b6000818160045b600f811015612734577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106126ec576126ec6143c2565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161461272257506000949350505050565b8061272c81614467565b9150506126ae565b5081600f1a600181111561274a5761274a61440a565b949350505050565b60008061276488878b6000015161307a565b905060008061277f8b8a63ffffffff16858a8a60018b613106565b909250905061278e818361438a565b9b9a5050505050505050505050565b6000808080846080015160018111156127b8576127b861440a565b036127dc576127c886868661355f565b6127d75760009250905061079f565b612853565b6001846080015160018111156127f4576127f461440a565b03612821576000612806878787613653565b925090508061281b575060009250905061079f565b50612853565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61285b612dcc565b84516040015163ffffffff16116128af57857fc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd56368660405161289c9190613bd8565b60405180910390a260009250905061079f565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff16101561290f57857f377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e028660405161289c9190613bd8565b6001969095509350505050565b6000816080015160018111156129345761293461440a565b036129a657612941612dcc565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b6001816080015160018111156129be576129be61440a565b03612a2a5760e08101805160009081526008602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055915191517fa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f29190a25b5050565b6000612a3b84848461307a565b90508085101561274a5750929392505050565b600080612a69888760a001518860c001518888886001613106565b90925090506000612a7a828461438a565b600089815260046020526040902060010180549192508291600c90612abe9084906c0100000000000000000000000090046bffffffffffffffffffffffff16614c1c565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612b079185911661438a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314612176576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015290612dbe576000816060015185612c5a9190614c1c565b90506000612c688583614c41565b90508083604001818151612c7c919061438a565b6bffffffffffffffffffffffff16905250612c978582614c6c565b83606001818151612ca8919061438a565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115612e0257612e0261440a565b03612e7c57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612e53573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e779190614ca0565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a604051602001612ea599989796959493929190614cb9565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006126a1825490565b6000612dc583836137e0565b6000612dc58373ffffffffffffffffffffffffffffffffffffffff841661380a565b6000612dc58373ffffffffffffffffffffffffffffffffffffffff8416613904565b3373ffffffffffffffffffffffffffffffffffffffff821603613004576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080808560018111156130905761309061440a565b0361309f575062015f906130be565b60018560018111156130b3576130b361440a565b0361282157506201adb05b6130cf63ffffffff8516601461449f565b6130da8460016143f1565b6130e99060ff16611d4c61449f565b6130f390836143af565b6130fd91906143af565b95945050505050565b6000806000896080015161ffff168761311f919061449f565b905083801561312d5750803a105b1561313557503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561316b5761316b61440a565b036132ca5760408051600081526020810190915285156131c957600036604051806080016040528060488152602001614edf604891396040516020016131b393929190614d4e565b6040516020818303038152906040529050613231565b6015546131e590640100000000900463ffffffff166004614d75565b63ffffffff1667ffffffffffffffff81111561320357613203613e05565b6040519080825280601f01601f19166020018201604052801561322d576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613281908490600401613bd8565b602060405180830381865afa15801561329e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132c29190614ca0565b915050613424565b60017f000000000000000000000000000000000000000000000000000000000000000060028111156132fe576132fe61440a565b0361342457841561338057606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613355573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133799190614ca0565b9050613424565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156133ce573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133f29190614d98565b505060155492945061341593505050640100000000900463ffffffff168261449f565b61342090601061449f565b9150505b8461344057808b6080015161ffff1661343d919061449f565b90505b61344e61ffff87168261450b565b90506000878261345e8c8e6143af565b613468908661449f565b61347291906143af565b61348490670de0b6b3a764000061449f565b61348e919061450b565b905060008c6040015163ffffffff1664e8d4a510006134ad919061449f565b898e6020015163ffffffff16858f886134c6919061449f565b6134d091906143af565b6134de90633b9aca0061449f565b6134e8919061449f565b6134f2919061450b565b6134fc91906143af565b90506b033b2e3c9fd0803ce800000061351582846143af565b111561354d576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906135769190614de2565b835160c00151815191925063ffffffff908116911610156135d357847f405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8856040516135c19190613bd8565b60405180910390a26000915050612dc5565b6020810151158015906135fa5750602081015181516135f79063ffffffff16613953565b14155b806136135750613608612dcc565b815163ffffffff1610155b1561364857847f6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301856040516135c19190613bd8565b506001949350505050565b60008060008480602001905181019061366c9190614e3a565b9050600086826000015183602001516040516020016136c393929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061372557508160600151613722836040015163ffffffff16613953565b14155b806137415750613733612dcc565b826040015163ffffffff1610155b1561378b57867f6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301876040516137769190613bd8565b60405180910390a260009350915061079f9050565b60008181526008602052604090205460ff16156137d257867f405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8876040516137769190613bd8565b600197909650945050505050565b60008260000182815481106137f7576137f76143c2565b9060005260206000200154905092915050565b600081815260018301602052604081205480156138f357600061382e600183614454565b855490915060009061384290600190614454565b90508181146138a7576000866000018281548110613862576138626143c2565b9060005260206000200154905080876000018481548110613885576138856143c2565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806138b8576138b8614eaf565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506126a1565b60009150506126a1565b5092915050565b600081815260018301602052604081205461394b575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556126a1565b5060006126a1565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156139895761398961440a565b03613aa3576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156139dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a009190614ca0565b90508083101580613a1b5750610100613a198483614454565b115b15613a295750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613a7f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612dc59190614ca0565b504090565b919050565b508054600082559060005260206000209081019061213b9190613b55565b828054828255906000526020600020908101928215613b45579160200282015b82811115613b4557825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613aeb565b50613b51929150613b55565b5090565b5b80821115613b515760008155600101613b56565b60005b83811015613b85578181015183820152602001613b6d565b50506000910152565b60008151808452613ba6816020860160208601613b6a565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612dc56020830184613b8e565b73ffffffffffffffffffffffffffffffffffffffff8116811461213b57600080fd5b8035613aa881613beb565b60008083601f840112613c2a57600080fd5b50813567ffffffffffffffff811115613c4257600080fd5b602083019150836020828501011115613c5a57600080fd5b9250929050565b60008060008060608587031215613c7757600080fd5b8435613c8281613beb565b935060208501359250604085013567ffffffffffffffff811115613ca557600080fd5b613cb187828801613c18565b95989497509550505050565b600080600060408486031215613cd257600080fd5b83359250602084013567ffffffffffffffff811115613cf057600080fd5b613cfc86828701613c18565b9497909650939450505050565b60008083601f840112613d1b57600080fd5b50813567ffffffffffffffff811115613d3357600080fd5b6020830191508360208260051b8501011115613c5a57600080fd5b60008060008060008060008060e0898b031215613d6a57600080fd5b606089018a811115613d7b57600080fd5b8998503567ffffffffffffffff80821115613d9557600080fd5b613da18c838d01613c18565b909950975060808b0135915080821115613dba57600080fd5b613dc68c838d01613d09565b909750955060a08b0135915080821115613ddf57600080fd5b50613dec8b828c01613d09565b999c989b50969995989497949560c00135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613e5857613e58613e05565b60405290565b60405160c0810167ffffffffffffffff81118282101715613e5857613e58613e05565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613ec857613ec8613e05565b604052919050565b600067ffffffffffffffff821115613eea57613eea613e05565b5060051b60200190565b600082601f830112613f0557600080fd5b81356020613f1a613f1583613ed0565b613e81565b82815260059290921b84018101918181019086841115613f3957600080fd5b8286015b84811015613f5d578035613f5081613beb565b8352918301918301613f3d565b509695505050505050565b803560ff81168114613aa857600080fd5b63ffffffff8116811461213b57600080fd5b8035613aa881613f79565b62ffffff8116811461213b57600080fd5b8035613aa881613f96565b61ffff8116811461213b57600080fd5b8035613aa881613fb2565b6bffffffffffffffffffffffff8116811461213b57600080fd5b8035613aa881613fcd565b60006101e0828403121561400557600080fd5b61400d613e34565b905061401882613f8b565b815261402660208301613f8b565b602082015261403760408301613f8b565b604082015261404860608301613fa7565b606082015261405960808301613fc2565b608082015261406a60a08301613fe7565b60a082015261407b60c08301613f8b565b60c082015261408c60e08301613f8b565b60e082015261010061409f818401613f8b565b908201526101206140b1838201613f8b565b90820152610140828101359082015261016080830135908201526101806140d9818401613c0d565b908201526101a08281013567ffffffffffffffff8111156140f957600080fd5b61410585828601613ef4565b8284015250506101c0614119818401613c0d565b9082015292915050565b803567ffffffffffffffff81168114613aa857600080fd5b600082601f83011261414c57600080fd5b813567ffffffffffffffff81111561416657614166613e05565b61419760207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613e81565b8181528460208386010111156141ac57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c087890312156141e257600080fd5b863567ffffffffffffffff808211156141fa57600080fd5b6142068a838b01613ef4565b9750602089013591508082111561421c57600080fd5b6142288a838b01613ef4565b965061423660408a01613f68565b9550606089013591508082111561424c57600080fd5b6142588a838b01613ff2565b945061426660808a01614123565b935060a089013591508082111561427c57600080fd5b5061428989828a0161413b565b9150509295509295509295565b60008060008060008060c087890312156142af57600080fd5b863567ffffffffffffffff808211156142c757600080fd5b6142d38a838b01613ef4565b975060208901359150808211156142e957600080fd5b6142f58a838b01613ef4565b965061430360408a01613f68565b9550606089013591508082111561431957600080fd5b6142588a838b0161413b565b60006020828403121561433757600080fd5b8135612dc581613beb565b60006020828403121561435457600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156138fd576138fd61435b565b808201808211156126a1576126a161435b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60ff81811683821601908111156126a1576126a161435b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156138fd576138fd61435b565b818103818111156126a1576126a161435b565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036144985761449861435b565b5060010190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156144d7576144d761435b565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261451a5761451a6144dc565b500490565b6bffffffffffffffffffffffff851681528360208201528260408201526080606082015260006145526080830184613b8e565b9695505050505050565b600060ff821660ff84168160ff048111821515161561457d5761457d61435b565b029392505050565b63ffffffff8181168382160190808211156138fd576138fd61435b565b600081518084526020808501945080840160005b838110156145e857815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016145b6565b509495945050505050565b6020815261460a60208201835163ffffffff169052565b60006020830151614623604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e083015161010061469c8185018363ffffffff169052565b84015190506101206146b58482018363ffffffff169052565b84015190506101406146ce8482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a06147118185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526147316102008601846145a2565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526147878184018a6145a2565b9050828103608084015261479b81896145a2565b905060ff871660a084015282810360c08401526147b88187613b8e565b905067ffffffffffffffff851660e08401528281036101008401526147dd8185613b8e565b9c9b505050505050505050505050565b8051613aa881613f79565b8051613aa881613f96565b8051613aa881613fb2565b8051613aa881613fcd565b8051613aa881613beb565b600082601f83011261483557600080fd5b81516020614845613f1583613ed0565b82815260059290921b8401810191818101908684111561486457600080fd5b8286015b84811015613f5d57805161487b81613beb565b8352918301918301614868565b60006020828403121561489a57600080fd5b815167ffffffffffffffff808211156148b257600080fd5b908301906101e082860312156148c757600080fd5b6148cf613e34565b6148d8836147ed565b81526148e6602084016147ed565b60208201526148f7604084016147ed565b6040820152614908606084016147f8565b606082015261491960808401614803565b608082015261492a60a0840161480e565b60a082015261493b60c084016147ed565b60c082015261494c60e084016147ed565b60e082015261010061495f8185016147ed565b908201526101206149718482016147ed565b9082015261014083810151908201526101608084015190820152610180614999818501614819565b908201526101a083810151838111156149b157600080fd5b6149bd88828701614824565b8284015250506101c091506149d3828401614819565b91810191909152949350505050565b82815260406020820152600061274a6040830184613b8e565b60008060408385031215614a0e57600080fd5b82518015158114614a1e57600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614a6557600080fd5b81356020614a75613f1583613ed0565b82815260059290921b84018101918181019086841115614a9457600080fd5b8286015b84811015613f5d5780358352918301918301614a98565b600082601f830112614ac057600080fd5b81356020614ad0613f1583613ed0565b82815260059290921b84018101918181019086841115614aef57600080fd5b8286015b84811015613f5d57803567ffffffffffffffff811115614b135760008081fd5b614b218986838b010161413b565b845250918301918301614af3565b600060208284031215614b4157600080fd5b813567ffffffffffffffff80821115614b5957600080fd5b9083019060c08286031215614b6d57600080fd5b614b75613e5e565b8235815260208301356020820152604083013582811115614b9557600080fd5b614ba187828601614a54565b604083015250606083013582811115614bb957600080fd5b614bc587828601614a54565b606083015250608083013582811115614bdd57600080fd5b614be987828601614aaf565b60808301525060a083013582811115614c0157600080fd5b614c0d87828601614aaf565b60a08301525095945050505050565b6bffffffffffffffffffffffff8281168282160390808211156138fd576138fd61435b565b60006bffffffffffffffffffffffff80841680614c6057614c606144dc565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614c9757614c9761435b565b02949350505050565b600060208284031215614cb257600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614d008285018b6145a2565b91508382036080850152614d14828a6145a2565b915060ff881660a085015283820360c0850152614d318288613b8e565b90861660e085015283810361010085015290506147dd8185613b8e565b828482376000838201600081528351614d6b818360208801613b6a565b0195945050505050565b600063ffffffff80831681851681830481118215151615614c9757614c9761435b565b60008060008060008060c08789031215614db157600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614df457600080fd5b6040516040810181811067ffffffffffffffff82111715614e1757614e17613e05565b6040528251614e2581613f79565b81526020928301519281019290925250919050565b600060808284031215614e4c57600080fd5b6040516080810181811067ffffffffffffffff82111715614e6f57614e6f613e05565b604052825181526020830151614e8481613f79565b60208201526040830151614e9781613f79565b60408201526060928301519281019290925250919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryABI = KeeperRegistryMetaData.ABI @@ -602,9 +602,9 @@ func (it *KeeperRegistryCancelledUpkeepReportIterator) Close() error { } type KeeperRegistryCancelledUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistry *KeeperRegistryFilterer) FilterCancelledUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryCancelledUpkeepReportIterator, error) { @@ -794,6 +794,133 @@ func (_KeeperRegistry *KeeperRegistryFilterer) ParseConfigSet(log types.Log) (*K return event, nil } +type KeeperRegistryDedupKeyAddedIterator struct { + Event *KeeperRegistryDedupKeyAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryDedupKeyAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryDedupKeyAdded) + 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(KeeperRegistryDedupKeyAdded) + 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 *KeeperRegistryDedupKeyAddedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryDedupKeyAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryDedupKeyAdded struct { + DedupKey [32]byte + Raw types.Log +} + +func (_KeeperRegistry *KeeperRegistryFilterer) FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*KeeperRegistryDedupKeyAddedIterator, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _KeeperRegistry.contract.FilterLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return &KeeperRegistryDedupKeyAddedIterator{contract: _KeeperRegistry.contract, event: "DedupKeyAdded", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistry *KeeperRegistryFilterer) WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryDedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) { + + var dedupKeyRule []interface{} + for _, dedupKeyItem := range dedupKey { + dedupKeyRule = append(dedupKeyRule, dedupKeyItem) + } + + logs, sub, err := _KeeperRegistry.contract.WatchLogs(opts, "DedupKeyAdded", dedupKeyRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryDedupKeyAdded) + if err := _KeeperRegistry.contract.UnpackLog(event, "DedupKeyAdded", 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 (_KeeperRegistry *KeeperRegistryFilterer) ParseDedupKeyAdded(log types.Log) (*KeeperRegistryDedupKeyAdded, error) { + event := new(KeeperRegistryDedupKeyAdded) + if err := _KeeperRegistry.contract.UnpackLog(event, "DedupKeyAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type KeeperRegistryFundsAddedIterator struct { Event *KeeperRegistryFundsAdded @@ -1121,9 +1248,9 @@ func (it *KeeperRegistryInsufficientFundsUpkeepReportIterator) Close() error { } type KeeperRegistryInsufficientFundsUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistry *KeeperRegistryFilterer) FilterInsufficientFundsUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryInsufficientFundsUpkeepReportIterator, error) { @@ -2309,9 +2436,9 @@ func (it *KeeperRegistryReorgedUpkeepReportIterator) Close() error { } type KeeperRegistryReorgedUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistry *KeeperRegistryFilterer) FilterReorgedUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryReorgedUpkeepReportIterator, error) { @@ -2437,9 +2564,9 @@ func (it *KeeperRegistryStaleUpkeepReportIterator) Close() error { } type KeeperRegistryStaleUpkeepReport struct { - Id *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistry *KeeperRegistryFilterer) FilterStaleUpkeepReport(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryStaleUpkeepReportIterator, error) { @@ -3866,13 +3993,13 @@ func (it *KeeperRegistryUpkeepPerformedIterator) Close() error { } type KeeperRegistryUpkeepPerformed struct { - Id *big.Int - Success bool - TotalPayment *big.Int - GasUsed *big.Int - GasOverhead *big.Int - UpkeepTriggerID [32]byte - Raw types.Log + Id *big.Int + Success bool + TotalPayment *big.Int + GasUsed *big.Int + GasOverhead *big.Int + Trigger []byte + Raw types.Log } func (_KeeperRegistry *KeeperRegistryFilterer) FilterUpkeepPerformed(opts *bind.FilterOpts, id []*big.Int, success []bool) (*KeeperRegistryUpkeepPerformedIterator, error) { @@ -4605,6 +4732,8 @@ func (_KeeperRegistry *KeeperRegistry) ParseLog(log types.Log) (generated.Abigen return _KeeperRegistry.ParseCancelledUpkeepReport(log) case _KeeperRegistry.abi.Events["ConfigSet"].ID: return _KeeperRegistry.ParseConfigSet(log) + case _KeeperRegistry.abi.Events["DedupKeyAdded"].ID: + return _KeeperRegistry.ParseDedupKeyAdded(log) case _KeeperRegistry.abi.Events["FundsAdded"].ID: return _KeeperRegistry.ParseFundsAdded(log) case _KeeperRegistry.abi.Events["FundsWithdrawn"].ID: @@ -4674,13 +4803,17 @@ func (KeeperRegistryAdminPrivilegeConfigSet) Topic() common.Hash { } func (KeeperRegistryCancelledUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x846af3fdde418e2757c00c4cf8c6827e65ac4179753128c454922ccd7963886d") + return common.HexToHash("0xc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd5636") } func (KeeperRegistryConfigSet) Topic() common.Hash { return common.HexToHash("0x1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05") } +func (KeeperRegistryDedupKeyAdded) Topic() common.Hash { + return common.HexToHash("0xa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f2") +} + func (KeeperRegistryFundsAdded) Topic() common.Hash { return common.HexToHash("0xafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa734891506203") } @@ -4690,7 +4823,7 @@ func (KeeperRegistryFundsWithdrawn) Topic() common.Hash { } func (KeeperRegistryInsufficientFundsUpkeepReport) Topic() common.Hash { - return common.HexToHash("0xfcb5fa059ae0ddeeac53240ccaa0a8ad80993b33e18e8821f1e1cbc53481240e") + return common.HexToHash("0x377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e02") } func (KeeperRegistryOwnerFundsWithdrawn) Topic() common.Hash { @@ -4726,11 +4859,11 @@ func (KeeperRegistryPaymentWithdrawn) Topic() common.Hash { } func (KeeperRegistryReorgedUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x07c4f19521a82d67071422fca888431cac8267935db8abe73e354791a3d38868") + return common.HexToHash("0x6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301") } func (KeeperRegistryStaleUpkeepReport) Topic() common.Hash { - return common.HexToHash("0x909d8c7e883c6d2d53a5fb2dbb9ec57875a53c3769c099230027312ffb2a6b11") + return common.HexToHash("0x405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8") } func (KeeperRegistryTransmitted) Topic() common.Hash { @@ -4774,7 +4907,7 @@ func (KeeperRegistryUpkeepPaused) Topic() common.Hash { } func (KeeperRegistryUpkeepPerformed) Topic() common.Hash { - return common.HexToHash("0xdacc0b3d36199a5f78afb27c76cd01bf100f605edf5ee0c0e23055b0553b68c6") + return common.HexToHash("0xad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b") } func (KeeperRegistryUpkeepPrivilegeConfigSet) Topic() common.Hash { @@ -4850,6 +4983,12 @@ type KeeperRegistryInterface interface { ParseConfigSet(log types.Log) (*KeeperRegistryConfigSet, error) + FilterDedupKeyAdded(opts *bind.FilterOpts, dedupKey [][32]byte) (*KeeperRegistryDedupKeyAddedIterator, error) + + WatchDedupKeyAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryDedupKeyAdded, dedupKey [][32]byte) (event.Subscription, error) + + ParseDedupKeyAdded(log types.Log) (*KeeperRegistryDedupKeyAdded, error) + FilterFundsAdded(opts *bind.FilterOpts, id []*big.Int, from []common.Address) (*KeeperRegistryFundsAddedIterator, error) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryFundsAdded, id []*big.Int, from []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 9751065b0d9..a475c97cfc5 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -21,19 +21,19 @@ flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../cont functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 -i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin fb976990e21d6c454245bcd3247d71b2f045a7c5636adaebfe64b7449cb6042e +i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 0ae09bdeddc850a53471ddf47b89d1b32c17e97f531570177738605dfb4d0d10 i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 keeper_registry_logic1_3: ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin 0176d7abdb01b370c5bf4f670d9abf85ca10aff53b1f7bdad41f85fabe666020 keeper_registry_logic2_0: ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin d69d2bc8e4844293dbc2d45abcddc50b84c88554ecccfa4fa77c0ca45ec80871 -keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 56b35d4ec381125da58ce6ab7166553df18c0367e4b92402e3436212b8e732c1 -keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 14ba22d33b0a9047d28abdcb128edb909ff09b593ef86bfb44863341226ce7e7 +keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin dca600c9eb8a3de11d974722dc4de7f3a995c646c4f4b38b358580f2a0ca4612 +keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 1f22c3bdf1544cd258d085f1f52bd55024ff2c549288860ba1ce9aaebfa9122b keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin 6ce079f2738f015f7374673a2816e8e9787143d00b780ea7652c8aa9ad9e1e20 keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 -keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 307482ad11b5025b59b3373bf2032280d215334addd158d3f876d439ad834398 +keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 3423537dd5b4c8b42d693a7720053e7dc3ad64fbfab56fb4996c300d2bc26fa0 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index 1e0d7bed993..e347d815782 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -155,7 +155,7 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk common.BytesToHash(triggerW.BlockHash[:]).Hex(), logExt, ) - triggerID, _ := UpkeepTriggerID(upkeepId, report.Triggers[i]) + triggerID := UpkeepTriggerID(upkeepId, report.Triggers[i]) reportedUpkeeps[i] = ocr2keepers.ReportedUpkeep{ ID: triggerID, UpkeepID: ocr2keepers.UpkeepIdentifier(upkeepId.String()), diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go index 85ee1f3b089..3571d208868 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go @@ -2,7 +2,6 @@ package evm import ( "context" - "encoding/hex" "fmt" "math/big" "sync" @@ -216,7 +215,7 @@ func (c *TransmitEventProvider) convertToTransmitEvents(logs []transmitEventLog, TransmitBlock: BlockKeyHelper[int64]{}.MakeBlockKey(l.BlockNumber), Confirmations: latestBlock - l.BlockNumber, TransactionHash: l.TxHash.Hex(), - ID: hex.EncodeToString(triggerID[:]), + ID: triggerID, UpkeepID: upkeepId, }) } @@ -248,18 +247,18 @@ func (l transmitEventLog) Id() *big.Int { } } -func (l transmitEventLog) TriggerID() [32]byte { +func (l transmitEventLog) TriggerID() string { switch { case l.Performed != nil: - return l.Performed.UpkeepTriggerID + return UpkeepTriggerID(l.Performed.Id, l.Performed.Trigger) case l.Stale != nil: - return l.Stale.UpkeepTriggerID + return UpkeepTriggerID(l.Stale.Id, l.Stale.Trigger) case l.Reorged != nil: - return l.Reorged.UpkeepTriggerID + return UpkeepTriggerID(l.Reorged.Id, l.Reorged.Trigger) case l.InsufficientFunds != nil: - return l.InsufficientFunds.UpkeepTriggerID + return UpkeepTriggerID(l.InsufficientFunds.Id, l.InsufficientFunds.Trigger) default: - return [32]byte{} + return "" } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go index 048e2612bdf..4f44e47526d 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go @@ -169,10 +169,8 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, Performed: &iregistry21.IKeeperRegistryMasterUpkeepPerformed{ - Id: uid, - UpkeepTriggerID: [32]byte{ - 1, 2, 3, 4, 5, 6, 7, 8, - }, + Id: uid, + Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, ocr2keepers.PerformEvent, @@ -185,10 +183,8 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, Stale: &iregistry21.IKeeperRegistryMasterStaleUpkeepReport{ - Id: uid, - UpkeepTriggerID: [32]byte{ - 1, 2, 3, 4, 5, 6, 7, 8, - }, + Id: uid, + Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, ocr2keepers.StaleReportEvent, @@ -201,10 +197,8 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, InsufficientFunds: &iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{ - Id: uid, - UpkeepTriggerID: [32]byte{ - 1, 2, 3, 4, 5, 6, 7, 8, - }, + Id: uid, + Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, ocr2keepers.TransmitEventType(3), @@ -217,10 +211,8 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, Reorged: &iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{ - Id: uid, - UpkeepTriggerID: [32]byte{ - 1, 2, 3, 4, 5, 6, 7, 8, - }, + Id: uid, + Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, ocr2keepers.TransmitEventType(2), @@ -241,9 +233,7 @@ func TestTransmitEventLog(t *testing.T) { t.Run(tc.name, func(t *testing.T) { if tc.log.Id() != nil { require.Equal(t, uid.Int64(), tc.log.Id().Int64()) - require.Equal(t, [32]byte{ - 1, 2, 3, 4, 5, 6, 7, 8, - }, tc.log.TriggerID()) + require.Equal(t, "069d79304de8a5f4505a921893750ab549ec93837c5a99df2fb6fc827834fae7", tc.log.TriggerID()) } require.Equal(t, tc.etype, tc.log.TransmitEventType()) }) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go index b90d5540f8e..0d6a2c6f32b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go @@ -49,7 +49,7 @@ func getUpkeepType(id ocr2keepers.UpkeepIdentifier) upkeepType { // UpkeepTriggerID returns the identifier using the given upkeepID and trigger. // It follows the same logic as the contract, but performs it locally. -func UpkeepTriggerID(id *big.Int, trigger []byte) (string, error) { +func UpkeepTriggerID(id *big.Int, trigger []byte) string { idBytes := id.Bytes() combined := append(idBytes, trigger...) @@ -57,5 +57,5 @@ func UpkeepTriggerID(id *big.Int, trigger []byte) (string, error) { triggerIDBytes := crypto.Keccak256(combined) triggerID := hex.EncodeToString(triggerIDBytes) - return triggerID, nil + return triggerID } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go index 7e709f95da2..766c4eb87bc 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go @@ -26,10 +26,7 @@ func TestTriggerID(t *testing.T) { t.Fatalf("Error decoding hex string: %s", err) } - res, err := UpkeepTriggerID(&upkeepID, triggerBytes) - if err != nil { - t.Fatalf("Error calculating UpkeepTriggerID: %s", err) - } + res := UpkeepTriggerID(&upkeepID, triggerBytes) expectedResult := "fe466794c97e8b54ca25b696ff3ee448a7d03e4a82a2e45d9d84de62ef4cc260" assert.Equal(t, res, expectedResult, "UpkeepTriggerID mismatch") From c1e0d4d7c94af8b6310a62655018eba74c0777a0 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Fri, 4 Aug 2023 14:55:25 -0400 Subject: [PATCH 088/270] provide a comment for head trackable interface (#10069) * provide a comment for head trackable interface * update comment * update comment to be chain-agnostic --- common/types/head_tracker.go | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/common/types/head_tracker.go b/common/types/head_tracker.go index 0d69a2ccaa5..811298f8956 100644 --- a/common/types/head_tracker.go +++ b/common/types/head_tracker.go @@ -24,6 +24,10 @@ type HeadTracker[H Head[BLOCK_HASH], BLOCK_HASH Hashable] interface { // //go:generate mockery --quiet --name HeadTrackable --output ./mocks/ --case=underscore type HeadTrackable[H Head[BLOCK_HASH], BLOCK_HASH Hashable] interface { + // OnNewLongestChain sends a new head when it becomes available. Subscribers can recursively trace the parent + // of the head to the finality depth back. If this is not possible (e.g. due to recent boot, backfill not complete + // etc), users may get a shorter linked list. If there is a re-org, older blocks won't be sent to this function again. + // But the new blocks from the re-org will be available in later blocks' parent linked list. OnNewLongestChain(ctx context.Context, head H) } From f0217cd6e50c01a390d541c009e1c1403fb2efb7 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Fri, 4 Aug 2023 15:18:42 -0400 Subject: [PATCH 089/270] Revert openzeppelin-solidity v4.9.0 -> openzeppelin-solidity v4.8.0 (#10082) --- .../dev/0_0_0/FunctionsBillingRegistry.sol | 2 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 2 +- .../dev/1_0_0/FunctionsSubscriptions.sol | 2 +- .../FunctionsBillingRegistryMigration.sol | 2 +- .../FunctionsBillingRegistryOriginal.sol | 2 +- .../v4.8.0/contracts/interfaces/IERC5267.sol | 28 - ...ft-IERC6093.sol => draft-IERC20Permit.sol} | 0 .../v4.8.0/contracts/token/ERC20/ERC20.sol | 271 ++-- .../v4.8.0/contracts/token/ERC20/IERC20.sol | 21 +- .../token/ERC20/extensions/IERC20Metadata.sol | 4 +- ...{ERC20Permit.sol => draft-ERC20Permit.sol} | 61 +- ...ERC20Permit.sol => draft-IERC20Permit.sol} | 2 +- .../contracts/token/ERC20/utils/SafeERC20.sol | 113 +- .../v4.8.0/contracts/utils/Address.sol | 14 +- .../v4.8.0/contracts/utils/Counters.sol | 43 + .../v4.8.0/contracts/utils/Nonces.sol | 46 - .../v4.8.0/contracts/utils/SafeCast.sol | 1136 ----------------- .../v4.8.0/contracts/utils/ShortStrings.sol | 122 -- .../v4.8.0/contracts/utils/StorageSlot.sol | 57 +- .../v4.8.0/contracts/utils/Strings.sol | 33 +- .../contracts/utils/cryptography/ECDSA.sol | 134 +- .../contracts/utils/cryptography/EIP712.sol | 126 +- .../utils/cryptography/MessageHashUtils.sol | 87 -- .../v4.8.0/contracts/utils/math/Math.sol | 120 +- .../v4.8.0/contracts/utils/math/SafeCast.sol | 1136 +++++++++++++++++ .../functions_router/functions_router.go | 4 +- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 27 files changed, 1551 insertions(+), 2019 deletions(-) delete mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol rename contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/{draft-IERC6093.sol => draft-IERC20Permit.sol} (100%) rename contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/{ERC20Permit.sol => draft-ERC20Permit.sol} (53%) rename contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/{IERC20Permit.sol => draft-IERC20Permit.sol} (95%) create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Counters.sol delete mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol delete mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol delete mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol delete mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol diff --git a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol index a43f045b016..3488af55cca 100644 --- a/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol +++ b/contracts/src/v0.8/functions/dev/0_0_0/FunctionsBillingRegistry.sol @@ -10,7 +10,7 @@ import {IERC677Receiver} from "../../../shared/interfaces/IERC677Receiver.sol"; import {IAuthorizedOriginReceiver} from "./accessControl/interfaces/IAuthorizedOriginReceiver.sol"; import {ConfirmedOwnerUpgradeable} from "./accessControl/ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./accessControl/AuthorizedReceiver.sol"; -import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol"; import {PausableUpgradeable} from "../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; import {Initializable} from "../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index db970880ec4..ca2c8402c02 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -11,7 +11,7 @@ import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; import {ConfirmedOwner} from "../../../shared/access/ConfirmedOwner.sol"; -import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol"; import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, ITypeAndVersion, ConfirmedOwner { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 6a4a2f4a564..3252cb28117 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -11,7 +11,7 @@ import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; import {IERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol"; import {SafeERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol"; -import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol"; // @title Functions Subscriptions contract // @notice Contract that coordinates payment from users to the nodes of the Decentralized Oracle Network (DON). diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol index 1bf13818f73..f9e6649d026 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryMigration.sol @@ -11,7 +11,7 @@ import {IERC677Receiver} from "../../../../../shared/interfaces/IERC677Receiver. import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; -import {SafeCast} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol"; import {PausableUpgradeable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; diff --git a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol index 07652f53f8b..39bff270401 100644 --- a/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol +++ b/contracts/src/v0.8/functions/tests/0_0_0/testhelpers/mocks/FunctionsBillingRegistryOriginal.sol @@ -11,7 +11,7 @@ import {IERC677Receiver} from "../../../../../shared/interfaces/IERC677Receiver. import {AuthorizedOriginReceiverInterface} from "./AuthorizedOriginReceiverInterface.sol"; import {ConfirmedOwnerUpgradeable} from "./ConfirmedOwnerUpgradeable.sol"; import {AuthorizedReceiver} from "./AuthorizedReceiver.sol"; -import {SafeCast} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol"; +import {SafeCast} from "../../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol"; import {PausableUpgradeable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/security/PausableUpgradeable.sol"; import {Initializable} from "../../../../../vendor/openzeppelin-contracts-upgradeable/v4.8.1/proxy/utils/Initializable.sol"; diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol deleted file mode 100644 index 4a3282f1f20..00000000000 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC5267.sol +++ /dev/null @@ -1,28 +0,0 @@ -// SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (interfaces/IERC5267.sol) - -pragma solidity ^0.8.0; - -interface IERC5267 { - /** - * @dev MAY be emitted to signal that the domain could have changed. - */ - event EIP712DomainChanged(); - - /** - * @dev returns the fields and values that describe the domain separator used by this contract for EIP-712 - * signature. - */ - function eip712Domain() - external - view - returns ( - bytes1 fields, - string memory name, - string memory version, - uint256 chainId, - address verifyingContract, - bytes32 salt, - uint256[] memory extensions - ); -} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC6093.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC20Permit.sol similarity index 100% rename from contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC6093.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/draft-IERC20Permit.sol diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol index 89ec2152080..0e9b0776df5 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol @@ -1,26 +1,23 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/ERC20.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/ERC20.sol) pragma solidity ^0.8.0; -import {IERC20} from "./IERC20.sol"; -import {IERC20Metadata} from "./extensions/IERC20Metadata.sol"; -import {Context} from "../../utils/Context.sol"; -import {IERC20Errors} from "../../interfaces/draft-IERC6093.sol"; +import "./IERC20.sol"; +import "./extensions/IERC20Metadata.sol"; +import "../../utils/Context.sol"; /** * @dev Implementation of the {IERC20} interface. * * This implementation is agnostic to the way tokens are created. This means * that a supply mechanism has to be added in a derived contract using {_mint}. + * For a generic mechanism see {ERC20PresetMinterPauser}. * * TIP: For a detailed writeup see our guide * https://forum.openzeppelin.com/t/how-to-implement-erc20-supply-mechanisms/226[How * to implement supply mechanisms]. * - * The default value of {decimals} is 18. To change this, you should override - * this function so it returns a different value. - * * We have followed general OpenZeppelin Contracts guidelines: functions revert * instead returning `false` on failure. This behavior is nonetheless * conventional and does not conflict with the expectations of ERC20 @@ -35,7 +32,7 @@ import {IERC20Errors} from "../../interfaces/draft-IERC6093.sol"; * functions have been added to mitigate the well-known issues around setting * allowances. See {IERC20-approve}. */ -abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { +contract ERC20 is Context, IERC20, IERC20Metadata { mapping(address => uint256) private _balances; mapping(address => mapping(address => uint256)) private _allowances; @@ -45,14 +42,12 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { string private _name; string private _symbol; - /** - * @dev Indicates a failed `decreaseAllowance` request. - */ - error ERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease); - /** * @dev Sets the values for {name} and {symbol}. * + * The default value of {decimals} is 18. To select a different value for + * {decimals} you should overload it. + * * All two of these values are immutable: they can only be set once during * construction. */ @@ -64,7 +59,7 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { /** * @dev Returns the name of the token. */ - function name() public view virtual returns (string memory) { + function name() public view virtual override returns (string memory) { return _name; } @@ -72,7 +67,7 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { * @dev Returns the symbol of the token, usually a shorter version of the * name. */ - function symbol() public view virtual returns (string memory) { + function symbol() public view virtual override returns (string memory) { return _symbol; } @@ -82,28 +77,28 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { * be displayed to a user as `5.05` (`505 / 10 ** 2`). * * Tokens usually opt for a value of 18, imitating the relationship between - * Ether and Wei. This is the default value returned by this function, unless - * it's overridden. + * Ether and Wei. This is the value {ERC20} uses, unless this function is + * overridden; * * NOTE: This information is only used for _display_ purposes: it in * no way affects any of the arithmetic of the contract, including * {IERC20-balanceOf} and {IERC20-transfer}. */ - function decimals() public view virtual returns (uint8) { + function decimals() public view virtual override returns (uint8) { return 18; } /** * @dev See {IERC20-totalSupply}. */ - function totalSupply() public view virtual returns (uint256) { + function totalSupply() public view virtual override returns (uint256) { return _totalSupply; } /** * @dev See {IERC20-balanceOf}. */ - function balanceOf(address account) public view virtual returns (uint256) { + function balanceOf(address account) public view virtual override returns (uint256) { return _balances[account]; } @@ -113,34 +108,34 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { * Requirements: * * - `to` cannot be the zero address. - * - the caller must have a balance of at least `value`. + * - the caller must have a balance of at least `amount`. */ - function transfer(address to, uint256 value) public virtual returns (bool) { + function transfer(address to, uint256 amount) public virtual override returns (bool) { address owner = _msgSender(); - _transfer(owner, to, value); + _transfer(owner, to, amount); return true; } /** * @dev See {IERC20-allowance}. */ - function allowance(address owner, address spender) public view virtual returns (uint256) { + function allowance(address owner, address spender) public view virtual override returns (uint256) { return _allowances[owner][spender]; } /** * @dev See {IERC20-approve}. * - * NOTE: If `value` is the maximum `uint256`, the allowance is not updated on + * NOTE: If `amount` is the maximum `uint256`, the allowance is not updated on * `transferFrom`. This is semantically equivalent to an infinite approval. * * Requirements: * * - `spender` cannot be the zero address. */ - function approve(address spender, uint256 value) public virtual returns (bool) { + function approve(address spender, uint256 amount) public virtual override returns (bool) { address owner = _msgSender(); - _approve(owner, spender, value); + _approve(owner, spender, amount); return true; } @@ -156,14 +151,14 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { * Requirements: * * - `from` and `to` cannot be the zero address. - * - `from` must have a balance of at least `value`. + * - `from` must have a balance of at least `amount`. * - the caller must have allowance for ``from``'s tokens of at least - * `value`. + * `amount`. */ - function transferFrom(address from, address to, uint256 value) public virtual returns (bool) { + function transferFrom(address from, address to, uint256 amount) public virtual override returns (bool) { address spender = _msgSender(); - _spendAllowance(from, spender, value); - _transfer(from, to, value); + _spendAllowance(from, spender, amount); + _transfer(from, to, amount); return true; } @@ -197,112 +192,108 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { * * - `spender` cannot be the zero address. * - `spender` must have allowance for the caller of at least - * `requestedDecrease`. - * - * NOTE: Although this function is designed to avoid double spending with {approval}, - * it can still be frontrunned, preventing any attempt of allowance reduction. + * `subtractedValue`. */ - function decreaseAllowance(address spender, uint256 requestedDecrease) public virtual returns (bool) { + function decreaseAllowance(address spender, uint256 subtractedValue) public virtual returns (bool) { address owner = _msgSender(); uint256 currentAllowance = allowance(owner, spender); - if (currentAllowance < requestedDecrease) { - revert ERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease); - } + require(currentAllowance >= subtractedValue, "ERC20: decreased allowance below zero"); unchecked { - _approve(owner, spender, currentAllowance - requestedDecrease); + _approve(owner, spender, currentAllowance - subtractedValue); } return true; } /** - * @dev Moves a `value` amount of tokens from `from` to `to`. + * @dev Moves `amount` of tokens from `from` to `to`. * * This internal function is equivalent to {transfer}, and can be used to * e.g. implement automatic token fees, slashing mechanisms, etc. * * Emits a {Transfer} event. * - * NOTE: This function is not virtual, {_update} should be overridden instead. - */ - function _transfer(address from, address to, uint256 value) internal { - if (from == address(0)) { - revert ERC20InvalidSender(address(0)); - } - if (to == address(0)) { - revert ERC20InvalidReceiver(address(0)); - } - _update(from, to, value); - } - - /** - * @dev Transfers a `value` amount of tokens from `from` to `to`, or alternatively mints (or burns) if `from` (or `to`) is - * the zero address. All customizations to transfers, mints, and burns should be done by overriding this function. + * Requirements: * - * Emits a {Transfer} event. + * - `from` cannot be the zero address. + * - `to` cannot be the zero address. + * - `from` must have a balance of at least `amount`. */ - function _update(address from, address to, uint256 value) internal virtual { - if (from == address(0)) { - // Overflow check required: The rest of the code assumes that totalSupply never overflows - _totalSupply += value; - } else { - uint256 fromBalance = _balances[from]; - if (fromBalance < value) { - revert ERC20InsufficientBalance(from, fromBalance, value); - } - unchecked { - // Overflow not possible: value <= fromBalance <= totalSupply. - _balances[from] = fromBalance - value; - } - } + function _transfer(address from, address to, uint256 amount) internal virtual { + require(from != address(0), "ERC20: transfer from the zero address"); + require(to != address(0), "ERC20: transfer to the zero address"); - if (to == address(0)) { - unchecked { - // Overflow not possible: value <= totalSupply or value <= fromBalance <= totalSupply. - _totalSupply -= value; - } - } else { - unchecked { - // Overflow not possible: balance + value is at most totalSupply, which we know fits into a uint256. - _balances[to] += value; - } + _beforeTokenTransfer(from, to, amount); + + uint256 fromBalance = _balances[from]; + require(fromBalance >= amount, "ERC20: transfer amount exceeds balance"); + unchecked { + _balances[from] = fromBalance - amount; + // Overflow not possible: the sum of all balances is capped by totalSupply, and the sum is preserved by + // decrementing then incrementing. + _balances[to] += amount; } - emit Transfer(from, to, value); + emit Transfer(from, to, amount); + + _afterTokenTransfer(from, to, amount); } - /** - * @dev Creates a `value` amount of tokens and assigns them to `account`, by transferring it from address(0). - * Relies on the `_update` mechanism + /** @dev Creates `amount` tokens and assigns them to `account`, increasing + * the total supply. * * Emits a {Transfer} event with `from` set to the zero address. * - * NOTE: This function is not virtual, {_update} should be overridden instead. + * Requirements: + * + * - `account` cannot be the zero address. */ - function _mint(address account, uint256 value) internal { - if (account == address(0)) { - revert ERC20InvalidReceiver(address(0)); + function _mint(address account, uint256 amount) internal virtual { + require(account != address(0), "ERC20: mint to the zero address"); + + _beforeTokenTransfer(address(0), account, amount); + + _totalSupply += amount; + unchecked { + // Overflow not possible: balance + amount is at most totalSupply + amount, which is checked above. + _balances[account] += amount; } - _update(address(0), account, value); + emit Transfer(address(0), account, amount); + + _afterTokenTransfer(address(0), account, amount); } /** - * @dev Destroys a `value` amount of tokens from `account`, by transferring it to address(0). - * Relies on the `_update` mechanism. + * @dev Destroys `amount` tokens from `account`, reducing the + * total supply. * * Emits a {Transfer} event with `to` set to the zero address. * - * NOTE: This function is not virtual, {_update} should be overridden instead + * Requirements: + * + * - `account` cannot be the zero address. + * - `account` must have at least `amount` tokens. */ - function _burn(address account, uint256 value) internal { - if (account == address(0)) { - revert ERC20InvalidSender(address(0)); + function _burn(address account, uint256 amount) internal virtual { + require(account != address(0), "ERC20: burn from the zero address"); + + _beforeTokenTransfer(account, address(0), amount); + + uint256 accountBalance = _balances[account]; + require(accountBalance >= amount, "ERC20: burn amount exceeds balance"); + unchecked { + _balances[account] = accountBalance - amount; + // Overflow not possible: amount <= accountBalance <= totalSupply. + _totalSupply -= amount; } - _update(account, address(0), value); + + emit Transfer(account, address(0), amount); + + _afterTokenTransfer(account, address(0), amount); } /** - * @dev Sets `value` as the allowance of `spender` over the `owner` s tokens. + * @dev Sets `amount` as the allowance of `spender` over the `owner` s tokens. * * This internal function is equivalent to `approve`, and can be used to * e.g. set automatic allowances for certain subsystems, etc. @@ -314,57 +305,61 @@ abstract contract ERC20 is Context, IERC20, IERC20Metadata, IERC20Errors { * - `owner` cannot be the zero address. * - `spender` cannot be the zero address. */ - function _approve(address owner, address spender, uint256 value) internal virtual { - _approve(owner, spender, value, true); - } + function _approve(address owner, address spender, uint256 amount) internal virtual { + require(owner != address(0), "ERC20: approve from the zero address"); + require(spender != address(0), "ERC20: approve to the zero address"); - /** - * @dev Alternative version of {_approve} with an optional flag that can enable or disable the Approval event. - * - * By default (when calling {_approve}) the flag is set to true. On the other hand, approval changes made by - * `_spendAllowance` during the `transferFrom` operation set the flag to false. This saves gas by not emitting any - * `Approval` event during `transferFrom` operations. - * - * Anyone who wishes to continue emitting `Approval` events on the`transferFrom` operation can force the flag to true - * using the following override: - * ``` - * function _approve(address owner, address spender, uint256 value, bool) internal virtual override { - * super._approve(owner, spender, value, true); - * } - * ``` - * - * Requirements are the same as {_approve}. - */ - function _approve(address owner, address spender, uint256 value, bool emitEvent) internal virtual { - if (owner == address(0)) { - revert ERC20InvalidApprover(address(0)); - } - if (spender == address(0)) { - revert ERC20InvalidSpender(address(0)); - } - _allowances[owner][spender] = value; - if (emitEvent) { - emit Approval(owner, spender, value); - } + _allowances[owner][spender] = amount; + emit Approval(owner, spender, amount); } /** - * @dev Updates `owner` s allowance for `spender` based on spent `value`. + * @dev Updates `owner` s allowance for `spender` based on spent `amount`. * - * Does not update the allowance value in case of infinite allowance. + * Does not update the allowance amount in case of infinite allowance. * Revert if not enough allowance is available. * * Might emit an {Approval} event. */ - function _spendAllowance(address owner, address spender, uint256 value) internal virtual { + function _spendAllowance(address owner, address spender, uint256 amount) internal virtual { uint256 currentAllowance = allowance(owner, spender); if (currentAllowance != type(uint256).max) { - if (currentAllowance < value) { - revert ERC20InsufficientAllowance(spender, currentAllowance, value); - } + require(currentAllowance >= amount, "ERC20: insufficient allowance"); unchecked { - _approve(owner, spender, currentAllowance - value, false); + _approve(owner, spender, currentAllowance - amount); } } } + + /** + * @dev Hook that is called before any transfer of tokens. This includes + * minting and burning. + * + * Calling conditions: + * + * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens + * will be transferred to `to`. + * - when `from` is zero, `amount` tokens will be minted for `to`. + * - when `to` is zero, `amount` of ``from``'s tokens will be burned. + * - `from` and `to` are never both zero. + * + * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. + */ + function _beforeTokenTransfer(address from, address to, uint256 amount) internal virtual {} + + /** + * @dev Hook that is called after any transfer of tokens. This includes + * minting and burning. + * + * Calling conditions: + * + * - when `from` and `to` are both non-zero, `amount` of ``from``'s tokens + * has been transferred to `to`. + * - when `from` is zero, `amount` tokens have been minted for `to`. + * - when `to` is zero, `amount` of ``from``'s tokens have been burned. + * - `from` and `to` are never both zero. + * + * To learn more about hooks, head to xref:ROOT:extending-contracts.adoc#using-hooks[Using Hooks]. + */ + function _afterTokenTransfer(address from, address to, uint256 amount) internal virtual {} } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol index d5ce96680c6..536ba0b96cd 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/IERC20.sol) +// OpenZeppelin Contracts (last updated v4.6.0) (token/ERC20/IERC20.sol) pragma solidity ^0.8.0; @@ -22,23 +22,23 @@ interface IERC20 { event Approval(address indexed owner, address indexed spender, uint256 value); /** - * @dev Returns the value of tokens in existence. + * @dev Returns the amount of tokens in existence. */ function totalSupply() external view returns (uint256); /** - * @dev Returns the value of tokens owned by `account`. + * @dev Returns the amount of tokens owned by `account`. */ function balanceOf(address account) external view returns (uint256); /** - * @dev Moves a `value` amount of tokens from the caller's account to `to`. + * @dev Moves `amount` tokens from the caller's account to `to`. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ - function transfer(address to, uint256 value) external returns (bool); + function transfer(address to, uint256 amount) external returns (bool); /** * @dev Returns the remaining number of tokens that `spender` will be @@ -50,8 +50,7 @@ interface IERC20 { function allowance(address owner, address spender) external view returns (uint256); /** - * @dev Sets a `value` amount of tokens as the allowance of `spender` over the - * caller's tokens. + * @dev Sets `amount` as the allowance of `spender` over the caller's tokens. * * Returns a boolean value indicating whether the operation succeeded. * @@ -64,16 +63,16 @@ interface IERC20 { * * Emits an {Approval} event. */ - function approve(address spender, uint256 value) external returns (bool); + function approve(address spender, uint256 amount) external returns (bool); /** - * @dev Moves a `value` amount of tokens from `from` to `to` using the - * allowance mechanism. `value` is then deducted from the caller's + * @dev Moves `amount` tokens from `from` to `to` using the + * allowance mechanism. `amount` is then deducted from the caller's * allowance. * * Returns a boolean value indicating whether the operation succeeded. * * Emits a {Transfer} event. */ - function transferFrom(address from, address to, uint256 value) external returns (bool); + function transferFrom(address from, address to, uint256 amount) external returns (bool); } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol index 4db4ba20264..6e29892a1c2 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Metadata.sol @@ -3,10 +3,12 @@ pragma solidity ^0.8.0; -import {IERC20} from "../IERC20.sol"; +import "../IERC20.sol"; /** * @dev Interface for the optional metadata functions from the ERC20 standard. + * + * _Available since v4.1._ */ interface IERC20Metadata is IERC20 { /** diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/draft-ERC20Permit.sol similarity index 53% rename from contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/draft-ERC20Permit.sol index bdd86286f51..3c29ed05668 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Permit.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/draft-ERC20Permit.sol @@ -1,13 +1,13 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/extensions/ERC20Permit.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/extensions/draft-ERC20Permit.sol) pragma solidity ^0.8.0; -import {IERC20Permit} from "./IERC20Permit.sol"; -import {ERC20} from "../ERC20.sol"; -import {ECDSA} from "../../../utils/cryptography/ECDSA.sol"; -import {EIP712} from "../../../utils/cryptography/EIP712.sol"; -import {Nonces} from "../../../utils/Nonces.sol"; +import "./draft-IERC20Permit.sol"; +import "../ERC20.sol"; +import "../../../utils/cryptography/ECDSA.sol"; +import "../../../utils/cryptography/EIP712.sol"; +import "../../../utils/Counters.sol"; /** * @dev Implementation of the ERC20 Permit extension allowing approvals to be made via signatures, as defined in @@ -16,21 +16,25 @@ import {Nonces} from "../../../utils/Nonces.sol"; * Adds the {permit} method, which can be used to change an account's ERC20 allowance (see {IERC20-allowance}) by * presenting a message signed by the account. By not relying on `{IERC20-approve}`, the token holder account doesn't * need to send a transaction, and thus is not required to hold Ether at all. + * + * _Available since v3.4._ */ -abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712, Nonces { +abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712 { + using Counters for Counters.Counter; + + mapping(address => Counters.Counter) private _nonces; + // solhint-disable-next-line var-name-mixedcase bytes32 private constant _PERMIT_TYPEHASH = keccak256("Permit(address owner,address spender,uint256 value,uint256 nonce,uint256 deadline)"); - - /** - * @dev Permit deadline has expired. - */ - error ERC2612ExpiredSignature(uint256 deadline); - /** - * @dev Mismatched signature. + * @dev In previous versions `_PERMIT_TYPEHASH` was declared as `immutable`. + * However, to ensure consistency with the upgradeable transpiler, we will continue + * to reserve a slot. + * @custom:oz-renamed-from _PERMIT_TYPEHASH */ - error ERC2612InvalidSigner(address signer, address owner); + // solhint-disable-next-line var-name-mixedcase + bytes32 private _PERMIT_TYPEHASH_DEPRECATED_SLOT; /** * @dev Initializes the {EIP712} domain separator using the `name` parameter, and setting `version` to `"1"`. @@ -50,19 +54,15 @@ abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712, Nonces { uint8 v, bytes32 r, bytes32 s - ) public virtual { - if (block.timestamp > deadline) { - revert ERC2612ExpiredSignature(deadline); - } + ) public virtual override { + require(block.timestamp <= deadline, "ERC20Permit: expired deadline"); bytes32 structHash = keccak256(abi.encode(_PERMIT_TYPEHASH, owner, spender, value, _useNonce(owner), deadline)); bytes32 hash = _hashTypedDataV4(structHash); address signer = ECDSA.recover(hash, v, r, s); - if (signer != owner) { - revert ERC2612InvalidSigner(signer, owner); - } + require(signer == owner, "ERC20Permit: invalid signature"); _approve(owner, spender, value); } @@ -70,15 +70,26 @@ abstract contract ERC20Permit is ERC20, IERC20Permit, EIP712, Nonces { /** * @dev See {IERC20Permit-nonces}. */ - function nonces(address owner) public view virtual override(IERC20Permit, Nonces) returns (uint256) { - return super.nonces(owner); + function nonces(address owner) public view virtual override returns (uint256) { + return _nonces[owner].current(); } /** * @dev See {IERC20Permit-DOMAIN_SEPARATOR}. */ // solhint-disable-next-line func-name-mixedcase - function DOMAIN_SEPARATOR() external view virtual returns (bytes32) { + function DOMAIN_SEPARATOR() external view override returns (bytes32) { return _domainSeparatorV4(); } + + /** + * @dev "Consume a nonce": return the current value and increment. + * + * _Available since v4.1._ + */ + function _useNonce(address owner) internal virtual returns (uint256 current) { + Counters.Counter storage nonce = _nonces[owner]; + current = nonce.current(); + nonce.increment(); + } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/draft-IERC20Permit.sol similarity index 95% rename from contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol rename to contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/draft-IERC20Permit.sol index 89416499151..b14bbfe20a0 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/IERC20Permit.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/draft-IERC20Permit.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/extensions/IERC20Permit.sol) +// OpenZeppelin Contracts v4.4.1 (token/ERC20/extensions/draft-IERC20Permit.sol) pragma solidity ^0.8.0; diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol index b5556d921aa..2a6939eda04 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (token/ERC20/utils/SafeERC20.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (token/ERC20/utils/SafeERC20.sol) pragma solidity ^0.8.0; -import {IERC20} from "../IERC20.sol"; -import {IERC20Permit} from "../extensions/IERC20Permit.sol"; -import {Address} from "../../../utils/Address.sol"; +import "../IERC20.sol"; +import "../extensions/draft-IERC20Permit.sol"; +import "../../../utils/Address.sol"; /** * @title SafeERC20 @@ -19,73 +19,46 @@ import {Address} from "../../../utils/Address.sol"; library SafeERC20 { using Address for address; - /** - * @dev An operation with an ERC20 token failed. - */ - error SafeERC20FailedOperation(address token); - - /** - * @dev Indicates a failed `decreaseAllowance` request. - */ - error SafeERC20FailedDecreaseAllowance(address spender, uint256 currentAllowance, uint256 requestedDecrease); - - /** - * @dev Transfer `value` amount of `token` from the calling contract to `to`. If `token` returns no value, - * non-reverting calls are assumed to be successful. - */ function safeTransfer(IERC20 token, address to, uint256 value) internal { - _callOptionalReturn(token, abi.encodeCall(token.transfer, (to, value))); + _callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value)); } - /** - * @dev Transfer `value` amount of `token` from `from` to `to`, spending the approval given by `from` to the - * calling contract. If `token` returns no value, non-reverting calls are assumed to be successful. - */ function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal { - _callOptionalReturn(token, abi.encodeCall(token.transferFrom, (from, to, value))); + _callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value)); } /** - * @dev Increase the calling contract's allowance toward `spender` by `value`. If `token` returns no value, - * non-reverting calls are assumed to be successful. + * @dev Deprecated. This function has issues similar to the ones found in + * {IERC20-approve}, and its usage is discouraged. + * + * Whenever possible, use {safeIncreaseAllowance} and + * {safeDecreaseAllowance} instead. */ - function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { - uint256 oldAllowance = token.allowance(address(this), spender); - forceApprove(token, spender, oldAllowance + value); + function safeApprove(IERC20 token, address spender, uint256 value) internal { + // safeApprove should only be called when setting an initial allowance, + // or when resetting it to zero. To increase and decrease it, use + // 'safeIncreaseAllowance' and 'safeDecreaseAllowance' + require( + (value == 0) || (token.allowance(address(this), spender) == 0), + "SafeERC20: approve from non-zero to non-zero allowance" + ); + _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value)); } - /** - * @dev Decrease the calling contract's allowance toward `spender` by `requestedDecrease`. If `token` returns no value, - * non-reverting calls are assumed to be successful. - */ - function safeDecreaseAllowance(IERC20 token, address spender, uint256 requestedDecrease) internal { - unchecked { - uint256 currentAllowance = token.allowance(address(this), spender); - if (currentAllowance < requestedDecrease) { - revert SafeERC20FailedDecreaseAllowance(spender, currentAllowance, requestedDecrease); - } - forceApprove(token, spender, currentAllowance - requestedDecrease); - } + function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal { + uint256 newAllowance = token.allowance(address(this), spender) + value; + _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } - /** - * @dev Set the calling contract's allowance toward `spender` to `value`. If `token` returns no value, - * non-reverting calls are assumed to be successful. Meant to be used with tokens that require the approval - * to be set to zero before setting it to a non-zero value, such as USDT. - */ - function forceApprove(IERC20 token, address spender, uint256 value) internal { - bytes memory approvalCall = abi.encodeCall(token.approve, (spender, value)); - - if (!_callOptionalReturnBool(token, approvalCall)) { - _callOptionalReturn(token, abi.encodeCall(token.approve, (spender, 0))); - _callOptionalReturn(token, approvalCall); + function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal { + unchecked { + uint256 oldAllowance = token.allowance(address(this), spender); + require(oldAllowance >= value, "SafeERC20: decreased allowance below zero"); + uint256 newAllowance = oldAllowance - value; + _callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance)); } } - /** - * @dev Use a ERC-2612 signature to set the `owner` approval toward `spender` on `token`. - * Revert on invalid signature. - */ function safePermit( IERC20Permit token, address owner, @@ -99,9 +72,7 @@ library SafeERC20 { uint256 nonceBefore = token.nonces(owner); token.permit(owner, spender, value, deadline, v, r, s); uint256 nonceAfter = token.nonces(owner); - if (nonceAfter != nonceBefore + 1) { - revert SafeERC20FailedOperation(address(token)); - } + require(nonceAfter == nonceBefore + 1, "SafeERC20: permit did not succeed"); } /** @@ -115,26 +86,10 @@ library SafeERC20 { // we're implementing it ourselves. We use {Address-functionCall} to perform this call, which verifies that // the target address contains contract code and also asserts for success in the low-level call. - bytes memory returndata = address(token).functionCall(data); - if (returndata.length != 0 && !abi.decode(returndata, (bool))) { - revert SafeERC20FailedOperation(address(token)); + bytes memory returndata = address(token).functionCall(data, "SafeERC20: low-level call failed"); + if (returndata.length > 0) { + // Return data is optional + require(abi.decode(returndata, (bool)), "SafeERC20: ERC20 operation did not succeed"); } } - - /** - * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement - * on the return value: the return value is optional (but if data is returned, it must not be false). - * @param token The token targeted by the call. - * @param data The call data (encoded using abi.encode or one of its variants). - * - * This is a variant of {_callOptionalReturn} that silents catches all reverts and returns a bool instead. - */ - function _callOptionalReturnBool(IERC20 token, bytes memory data) private returns (bool) { - // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since - // we're implementing it ourselves. We cannot use {Address-functionCall} here since this should return false - // and not revert is the subcall reverts. - - (bool success, bytes memory returndata) = address(token).call(data); - return success && (returndata.length == 0 || abi.decode(returndata, (bool))) && address(token).code.length > 0; - } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol index f71f7f93e7f..d966c06d995 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol @@ -92,11 +92,7 @@ library Address { * * _Available since v3.1._ */ - function functionCall( - address target, - bytes memory data, - string memory errorMessage - ) internal returns (bytes memory) { + function functionCall(address target, bytes memory data, string memory errorMessage) internal returns (bytes memory) { return functionCallWithValue(target, data, 0, errorMessage); } @@ -111,11 +107,7 @@ library Address { * * _Available since v3.1._ */ - function functionCallWithValue( - address target, - bytes memory data, - uint256 value - ) internal returns (bytes memory) { + function functionCallWithValue(address target, bytes memory data, uint256 value) internal returns (bytes memory) { return functionCallWithValue(target, data, value, "Address: low-level call with value failed"); } @@ -241,4 +233,4 @@ library Address { revert(errorMessage); } } -} \ No newline at end of file +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Counters.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Counters.sol new file mode 100644 index 00000000000..ea330e9d2d7 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Counters.sol @@ -0,0 +1,43 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts v4.4.1 (utils/Counters.sol) + +pragma solidity ^0.8.0; + +/** + * @title Counters + * @author Matt Condon (@shrugs) + * @dev Provides counters that can only be incremented, decremented or reset. This can be used e.g. to track the number + * of elements in a mapping, issuing ERC721 ids, or counting request ids. + * + * Include with `using Counters for Counters.Counter;` + */ +library Counters { + struct Counter { + // This variable should never be directly accessed by users of the library: interactions must be restricted to + // the library's function. As of Solidity v0.5.2, this cannot be enforced, though there is a proposal to add + // this feature: see https://github.com/ethereum/solidity/issues/4637 + uint256 _value; // default: 0 + } + + function current(Counter storage counter) internal view returns (uint256) { + return counter._value; + } + + function increment(Counter storage counter) internal { + unchecked { + counter._value += 1; + } + } + + function decrement(Counter storage counter) internal { + uint256 value = counter._value; + require(value > 0, "Counter: decrement overflow"); + unchecked { + counter._value = value - 1; + } + } + + function reset(Counter storage counter) internal { + counter._value = 0; + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol deleted file mode 100644 index 0f017e3edbc..00000000000 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Nonces.sol +++ /dev/null @@ -1,46 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; - -/** - * @dev Provides tracking nonces for addresses. Nonces will only increment. - */ -abstract contract Nonces { - /** - * @dev The nonce used for an `account` is not the expected current nonce. - */ - error InvalidAccountNonce(address account, uint256 currentNonce); - - mapping(address => uint256) private _nonces; - - /** - * @dev Returns an the next unused nonce for an address. - */ - function nonces(address owner) public view virtual returns (uint256) { - return _nonces[owner]; - } - - /** - * @dev Consumes a nonce. - * - * Returns the current value and increments nonce. - */ - function _useNonce(address owner) internal virtual returns (uint256) { - // For each account, the nonce has an initial value of 0, can only be incremented by one, and cannot be - // decremented or reset. This guarantees that the nonce never overflows. - unchecked { - // It is important to do x++ and not ++x here. - return _nonces[owner]++; - } - } - - /** - * @dev Same as {_useNonce} but checking that `nonce` is the next valid for `owner`. - */ - function _useCheckedNonce(address owner, uint256 nonce) internal virtual returns (uint256) { - uint256 current = _useNonce(owner); - if (nonce != current) { - revert InvalidAccountNonce(owner, current); - } - return current; - } -} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol deleted file mode 100644 index e49292d0661..00000000000 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/SafeCast.sol +++ /dev/null @@ -1,1136 +0,0 @@ -// SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/SafeCast.sol) -// This file was procedurally generated from scripts/generate/templates/SafeCast.js. - -pragma solidity ^0.8.0; - -/** - * @dev Wrappers over Solidity's uintXX/intXX casting operators with added overflow - * checks. - * - * Downcasting from uint256/int256 in Solidity does not revert on overflow. This can - * easily result in undesired exploitation or bugs, since developers usually - * assume that overflows raise errors. `SafeCast` restores this intuition by - * reverting the transaction when such an operation overflows. - * - * Using this library instead of the unchecked operations eliminates an entire - * class of bugs, so it's recommended to use it always. - * - * Can be combined with {SafeMath} and {SignedSafeMath} to extend it to smaller types, by performing - * all math on `uint256` and `int256` and then downcasting. - */ -library SafeCast { - /** - * @dev Returns the downcasted uint248 from uint256, reverting on - * overflow (when the input is greater than largest uint248). - * - * Counterpart to Solidity's `uint248` operator. - * - * Requirements: - * - * - input must fit into 248 bits - * - * _Available since v4.7._ - */ - function toUint248(uint256 value) internal pure returns (uint248) { - require(value <= type(uint248).max, "SafeCast: value doesn't fit in 248 bits"); - return uint248(value); - } - - /** - * @dev Returns the downcasted uint240 from uint256, reverting on - * overflow (when the input is greater than largest uint240). - * - * Counterpart to Solidity's `uint240` operator. - * - * Requirements: - * - * - input must fit into 240 bits - * - * _Available since v4.7._ - */ - function toUint240(uint256 value) internal pure returns (uint240) { - require(value <= type(uint240).max, "SafeCast: value doesn't fit in 240 bits"); - return uint240(value); - } - - /** - * @dev Returns the downcasted uint232 from uint256, reverting on - * overflow (when the input is greater than largest uint232). - * - * Counterpart to Solidity's `uint232` operator. - * - * Requirements: - * - * - input must fit into 232 bits - * - * _Available since v4.7._ - */ - function toUint232(uint256 value) internal pure returns (uint232) { - require(value <= type(uint232).max, "SafeCast: value doesn't fit in 232 bits"); - return uint232(value); - } - - /** - * @dev Returns the downcasted uint224 from uint256, reverting on - * overflow (when the input is greater than largest uint224). - * - * Counterpart to Solidity's `uint224` operator. - * - * Requirements: - * - * - input must fit into 224 bits - * - * _Available since v4.2._ - */ - function toUint224(uint256 value) internal pure returns (uint224) { - require(value <= type(uint224).max, "SafeCast: value doesn't fit in 224 bits"); - return uint224(value); - } - - /** - * @dev Returns the downcasted uint216 from uint256, reverting on - * overflow (when the input is greater than largest uint216). - * - * Counterpart to Solidity's `uint216` operator. - * - * Requirements: - * - * - input must fit into 216 bits - * - * _Available since v4.7._ - */ - function toUint216(uint256 value) internal pure returns (uint216) { - require(value <= type(uint216).max, "SafeCast: value doesn't fit in 216 bits"); - return uint216(value); - } - - /** - * @dev Returns the downcasted uint208 from uint256, reverting on - * overflow (when the input is greater than largest uint208). - * - * Counterpart to Solidity's `uint208` operator. - * - * Requirements: - * - * - input must fit into 208 bits - * - * _Available since v4.7._ - */ - function toUint208(uint256 value) internal pure returns (uint208) { - require(value <= type(uint208).max, "SafeCast: value doesn't fit in 208 bits"); - return uint208(value); - } - - /** - * @dev Returns the downcasted uint200 from uint256, reverting on - * overflow (when the input is greater than largest uint200). - * - * Counterpart to Solidity's `uint200` operator. - * - * Requirements: - * - * - input must fit into 200 bits - * - * _Available since v4.7._ - */ - function toUint200(uint256 value) internal pure returns (uint200) { - require(value <= type(uint200).max, "SafeCast: value doesn't fit in 200 bits"); - return uint200(value); - } - - /** - * @dev Returns the downcasted uint192 from uint256, reverting on - * overflow (when the input is greater than largest uint192). - * - * Counterpart to Solidity's `uint192` operator. - * - * Requirements: - * - * - input must fit into 192 bits - * - * _Available since v4.7._ - */ - function toUint192(uint256 value) internal pure returns (uint192) { - require(value <= type(uint192).max, "SafeCast: value doesn't fit in 192 bits"); - return uint192(value); - } - - /** - * @dev Returns the downcasted uint184 from uint256, reverting on - * overflow (when the input is greater than largest uint184). - * - * Counterpart to Solidity's `uint184` operator. - * - * Requirements: - * - * - input must fit into 184 bits - * - * _Available since v4.7._ - */ - function toUint184(uint256 value) internal pure returns (uint184) { - require(value <= type(uint184).max, "SafeCast: value doesn't fit in 184 bits"); - return uint184(value); - } - - /** - * @dev Returns the downcasted uint176 from uint256, reverting on - * overflow (when the input is greater than largest uint176). - * - * Counterpart to Solidity's `uint176` operator. - * - * Requirements: - * - * - input must fit into 176 bits - * - * _Available since v4.7._ - */ - function toUint176(uint256 value) internal pure returns (uint176) { - require(value <= type(uint176).max, "SafeCast: value doesn't fit in 176 bits"); - return uint176(value); - } - - /** - * @dev Returns the downcasted uint168 from uint256, reverting on - * overflow (when the input is greater than largest uint168). - * - * Counterpart to Solidity's `uint168` operator. - * - * Requirements: - * - * - input must fit into 168 bits - * - * _Available since v4.7._ - */ - function toUint168(uint256 value) internal pure returns (uint168) { - require(value <= type(uint168).max, "SafeCast: value doesn't fit in 168 bits"); - return uint168(value); - } - - /** - * @dev Returns the downcasted uint160 from uint256, reverting on - * overflow (when the input is greater than largest uint160). - * - * Counterpart to Solidity's `uint160` operator. - * - * Requirements: - * - * - input must fit into 160 bits - * - * _Available since v4.7._ - */ - function toUint160(uint256 value) internal pure returns (uint160) { - require(value <= type(uint160).max, "SafeCast: value doesn't fit in 160 bits"); - return uint160(value); - } - - /** - * @dev Returns the downcasted uint152 from uint256, reverting on - * overflow (when the input is greater than largest uint152). - * - * Counterpart to Solidity's `uint152` operator. - * - * Requirements: - * - * - input must fit into 152 bits - * - * _Available since v4.7._ - */ - function toUint152(uint256 value) internal pure returns (uint152) { - require(value <= type(uint152).max, "SafeCast: value doesn't fit in 152 bits"); - return uint152(value); - } - - /** - * @dev Returns the downcasted uint144 from uint256, reverting on - * overflow (when the input is greater than largest uint144). - * - * Counterpart to Solidity's `uint144` operator. - * - * Requirements: - * - * - input must fit into 144 bits - * - * _Available since v4.7._ - */ - function toUint144(uint256 value) internal pure returns (uint144) { - require(value <= type(uint144).max, "SafeCast: value doesn't fit in 144 bits"); - return uint144(value); - } - - /** - * @dev Returns the downcasted uint136 from uint256, reverting on - * overflow (when the input is greater than largest uint136). - * - * Counterpart to Solidity's `uint136` operator. - * - * Requirements: - * - * - input must fit into 136 bits - * - * _Available since v4.7._ - */ - function toUint136(uint256 value) internal pure returns (uint136) { - require(value <= type(uint136).max, "SafeCast: value doesn't fit in 136 bits"); - return uint136(value); - } - - /** - * @dev Returns the downcasted uint128 from uint256, reverting on - * overflow (when the input is greater than largest uint128). - * - * Counterpart to Solidity's `uint128` operator. - * - * Requirements: - * - * - input must fit into 128 bits - * - * _Available since v2.5._ - */ - function toUint128(uint256 value) internal pure returns (uint128) { - require(value <= type(uint128).max, "SafeCast: value doesn't fit in 128 bits"); - return uint128(value); - } - - /** - * @dev Returns the downcasted uint120 from uint256, reverting on - * overflow (when the input is greater than largest uint120). - * - * Counterpart to Solidity's `uint120` operator. - * - * Requirements: - * - * - input must fit into 120 bits - * - * _Available since v4.7._ - */ - function toUint120(uint256 value) internal pure returns (uint120) { - require(value <= type(uint120).max, "SafeCast: value doesn't fit in 120 bits"); - return uint120(value); - } - - /** - * @dev Returns the downcasted uint112 from uint256, reverting on - * overflow (when the input is greater than largest uint112). - * - * Counterpart to Solidity's `uint112` operator. - * - * Requirements: - * - * - input must fit into 112 bits - * - * _Available since v4.7._ - */ - function toUint112(uint256 value) internal pure returns (uint112) { - require(value <= type(uint112).max, "SafeCast: value doesn't fit in 112 bits"); - return uint112(value); - } - - /** - * @dev Returns the downcasted uint104 from uint256, reverting on - * overflow (when the input is greater than largest uint104). - * - * Counterpart to Solidity's `uint104` operator. - * - * Requirements: - * - * - input must fit into 104 bits - * - * _Available since v4.7._ - */ - function toUint104(uint256 value) internal pure returns (uint104) { - require(value <= type(uint104).max, "SafeCast: value doesn't fit in 104 bits"); - return uint104(value); - } - - /** - * @dev Returns the downcasted uint96 from uint256, reverting on - * overflow (when the input is greater than largest uint96). - * - * Counterpart to Solidity's `uint96` operator. - * - * Requirements: - * - * - input must fit into 96 bits - * - * _Available since v4.2._ - */ - function toUint96(uint256 value) internal pure returns (uint96) { - require(value <= type(uint96).max, "SafeCast: value doesn't fit in 96 bits"); - return uint96(value); - } - - /** - * @dev Returns the downcasted uint88 from uint256, reverting on - * overflow (when the input is greater than largest uint88). - * - * Counterpart to Solidity's `uint88` operator. - * - * Requirements: - * - * - input must fit into 88 bits - * - * _Available since v4.7._ - */ - function toUint88(uint256 value) internal pure returns (uint88) { - require(value <= type(uint88).max, "SafeCast: value doesn't fit in 88 bits"); - return uint88(value); - } - - /** - * @dev Returns the downcasted uint80 from uint256, reverting on - * overflow (when the input is greater than largest uint80). - * - * Counterpart to Solidity's `uint80` operator. - * - * Requirements: - * - * - input must fit into 80 bits - * - * _Available since v4.7._ - */ - function toUint80(uint256 value) internal pure returns (uint80) { - require(value <= type(uint80).max, "SafeCast: value doesn't fit in 80 bits"); - return uint80(value); - } - - /** - * @dev Returns the downcasted uint72 from uint256, reverting on - * overflow (when the input is greater than largest uint72). - * - * Counterpart to Solidity's `uint72` operator. - * - * Requirements: - * - * - input must fit into 72 bits - * - * _Available since v4.7._ - */ - function toUint72(uint256 value) internal pure returns (uint72) { - require(value <= type(uint72).max, "SafeCast: value doesn't fit in 72 bits"); - return uint72(value); - } - - /** - * @dev Returns the downcasted uint64 from uint256, reverting on - * overflow (when the input is greater than largest uint64). - * - * Counterpart to Solidity's `uint64` operator. - * - * Requirements: - * - * - input must fit into 64 bits - * - * _Available since v2.5._ - */ - function toUint64(uint256 value) internal pure returns (uint64) { - require(value <= type(uint64).max, "SafeCast: value doesn't fit in 64 bits"); - return uint64(value); - } - - /** - * @dev Returns the downcasted uint56 from uint256, reverting on - * overflow (when the input is greater than largest uint56). - * - * Counterpart to Solidity's `uint56` operator. - * - * Requirements: - * - * - input must fit into 56 bits - * - * _Available since v4.7._ - */ - function toUint56(uint256 value) internal pure returns (uint56) { - require(value <= type(uint56).max, "SafeCast: value doesn't fit in 56 bits"); - return uint56(value); - } - - /** - * @dev Returns the downcasted uint48 from uint256, reverting on - * overflow (when the input is greater than largest uint48). - * - * Counterpart to Solidity's `uint48` operator. - * - * Requirements: - * - * - input must fit into 48 bits - * - * _Available since v4.7._ - */ - function toUint48(uint256 value) internal pure returns (uint48) { - require(value <= type(uint48).max, "SafeCast: value doesn't fit in 48 bits"); - return uint48(value); - } - - /** - * @dev Returns the downcasted uint40 from uint256, reverting on - * overflow (when the input is greater than largest uint40). - * - * Counterpart to Solidity's `uint40` operator. - * - * Requirements: - * - * - input must fit into 40 bits - * - * _Available since v4.7._ - */ - function toUint40(uint256 value) internal pure returns (uint40) { - require(value <= type(uint40).max, "SafeCast: value doesn't fit in 40 bits"); - return uint40(value); - } - - /** - * @dev Returns the downcasted uint32 from uint256, reverting on - * overflow (when the input is greater than largest uint32). - * - * Counterpart to Solidity's `uint32` operator. - * - * Requirements: - * - * - input must fit into 32 bits - * - * _Available since v2.5._ - */ - function toUint32(uint256 value) internal pure returns (uint32) { - require(value <= type(uint32).max, "SafeCast: value doesn't fit in 32 bits"); - return uint32(value); - } - - /** - * @dev Returns the downcasted uint24 from uint256, reverting on - * overflow (when the input is greater than largest uint24). - * - * Counterpart to Solidity's `uint24` operator. - * - * Requirements: - * - * - input must fit into 24 bits - * - * _Available since v4.7._ - */ - function toUint24(uint256 value) internal pure returns (uint24) { - require(value <= type(uint24).max, "SafeCast: value doesn't fit in 24 bits"); - return uint24(value); - } - - /** - * @dev Returns the downcasted uint16 from uint256, reverting on - * overflow (when the input is greater than largest uint16). - * - * Counterpart to Solidity's `uint16` operator. - * - * Requirements: - * - * - input must fit into 16 bits - * - * _Available since v2.5._ - */ - function toUint16(uint256 value) internal pure returns (uint16) { - require(value <= type(uint16).max, "SafeCast: value doesn't fit in 16 bits"); - return uint16(value); - } - - /** - * @dev Returns the downcasted uint8 from uint256, reverting on - * overflow (when the input is greater than largest uint8). - * - * Counterpart to Solidity's `uint8` operator. - * - * Requirements: - * - * - input must fit into 8 bits - * - * _Available since v2.5._ - */ - function toUint8(uint256 value) internal pure returns (uint8) { - require(value <= type(uint8).max, "SafeCast: value doesn't fit in 8 bits"); - return uint8(value); - } - - /** - * @dev Converts a signed int256 into an unsigned uint256. - * - * Requirements: - * - * - input must be greater than or equal to 0. - * - * _Available since v3.0._ - */ - function toUint256(int256 value) internal pure returns (uint256) { - require(value >= 0, "SafeCast: value must be positive"); - return uint256(value); - } - - /** - * @dev Returns the downcasted int248 from int256, reverting on - * overflow (when the input is less than smallest int248 or - * greater than largest int248). - * - * Counterpart to Solidity's `int248` operator. - * - * Requirements: - * - * - input must fit into 248 bits - * - * _Available since v4.7._ - */ - function toInt248(int256 value) internal pure returns (int248 downcasted) { - downcasted = int248(value); - require(downcasted == value, "SafeCast: value doesn't fit in 248 bits"); - } - - /** - * @dev Returns the downcasted int240 from int256, reverting on - * overflow (when the input is less than smallest int240 or - * greater than largest int240). - * - * Counterpart to Solidity's `int240` operator. - * - * Requirements: - * - * - input must fit into 240 bits - * - * _Available since v4.7._ - */ - function toInt240(int256 value) internal pure returns (int240 downcasted) { - downcasted = int240(value); - require(downcasted == value, "SafeCast: value doesn't fit in 240 bits"); - } - - /** - * @dev Returns the downcasted int232 from int256, reverting on - * overflow (when the input is less than smallest int232 or - * greater than largest int232). - * - * Counterpart to Solidity's `int232` operator. - * - * Requirements: - * - * - input must fit into 232 bits - * - * _Available since v4.7._ - */ - function toInt232(int256 value) internal pure returns (int232 downcasted) { - downcasted = int232(value); - require(downcasted == value, "SafeCast: value doesn't fit in 232 bits"); - } - - /** - * @dev Returns the downcasted int224 from int256, reverting on - * overflow (when the input is less than smallest int224 or - * greater than largest int224). - * - * Counterpart to Solidity's `int224` operator. - * - * Requirements: - * - * - input must fit into 224 bits - * - * _Available since v4.7._ - */ - function toInt224(int256 value) internal pure returns (int224 downcasted) { - downcasted = int224(value); - require(downcasted == value, "SafeCast: value doesn't fit in 224 bits"); - } - - /** - * @dev Returns the downcasted int216 from int256, reverting on - * overflow (when the input is less than smallest int216 or - * greater than largest int216). - * - * Counterpart to Solidity's `int216` operator. - * - * Requirements: - * - * - input must fit into 216 bits - * - * _Available since v4.7._ - */ - function toInt216(int256 value) internal pure returns (int216 downcasted) { - downcasted = int216(value); - require(downcasted == value, "SafeCast: value doesn't fit in 216 bits"); - } - - /** - * @dev Returns the downcasted int208 from int256, reverting on - * overflow (when the input is less than smallest int208 or - * greater than largest int208). - * - * Counterpart to Solidity's `int208` operator. - * - * Requirements: - * - * - input must fit into 208 bits - * - * _Available since v4.7._ - */ - function toInt208(int256 value) internal pure returns (int208 downcasted) { - downcasted = int208(value); - require(downcasted == value, "SafeCast: value doesn't fit in 208 bits"); - } - - /** - * @dev Returns the downcasted int200 from int256, reverting on - * overflow (when the input is less than smallest int200 or - * greater than largest int200). - * - * Counterpart to Solidity's `int200` operator. - * - * Requirements: - * - * - input must fit into 200 bits - * - * _Available since v4.7._ - */ - function toInt200(int256 value) internal pure returns (int200 downcasted) { - downcasted = int200(value); - require(downcasted == value, "SafeCast: value doesn't fit in 200 bits"); - } - - /** - * @dev Returns the downcasted int192 from int256, reverting on - * overflow (when the input is less than smallest int192 or - * greater than largest int192). - * - * Counterpart to Solidity's `int192` operator. - * - * Requirements: - * - * - input must fit into 192 bits - * - * _Available since v4.7._ - */ - function toInt192(int256 value) internal pure returns (int192 downcasted) { - downcasted = int192(value); - require(downcasted == value, "SafeCast: value doesn't fit in 192 bits"); - } - - /** - * @dev Returns the downcasted int184 from int256, reverting on - * overflow (when the input is less than smallest int184 or - * greater than largest int184). - * - * Counterpart to Solidity's `int184` operator. - * - * Requirements: - * - * - input must fit into 184 bits - * - * _Available since v4.7._ - */ - function toInt184(int256 value) internal pure returns (int184 downcasted) { - downcasted = int184(value); - require(downcasted == value, "SafeCast: value doesn't fit in 184 bits"); - } - - /** - * @dev Returns the downcasted int176 from int256, reverting on - * overflow (when the input is less than smallest int176 or - * greater than largest int176). - * - * Counterpart to Solidity's `int176` operator. - * - * Requirements: - * - * - input must fit into 176 bits - * - * _Available since v4.7._ - */ - function toInt176(int256 value) internal pure returns (int176 downcasted) { - downcasted = int176(value); - require(downcasted == value, "SafeCast: value doesn't fit in 176 bits"); - } - - /** - * @dev Returns the downcasted int168 from int256, reverting on - * overflow (when the input is less than smallest int168 or - * greater than largest int168). - * - * Counterpart to Solidity's `int168` operator. - * - * Requirements: - * - * - input must fit into 168 bits - * - * _Available since v4.7._ - */ - function toInt168(int256 value) internal pure returns (int168 downcasted) { - downcasted = int168(value); - require(downcasted == value, "SafeCast: value doesn't fit in 168 bits"); - } - - /** - * @dev Returns the downcasted int160 from int256, reverting on - * overflow (when the input is less than smallest int160 or - * greater than largest int160). - * - * Counterpart to Solidity's `int160` operator. - * - * Requirements: - * - * - input must fit into 160 bits - * - * _Available since v4.7._ - */ - function toInt160(int256 value) internal pure returns (int160 downcasted) { - downcasted = int160(value); - require(downcasted == value, "SafeCast: value doesn't fit in 160 bits"); - } - - /** - * @dev Returns the downcasted int152 from int256, reverting on - * overflow (when the input is less than smallest int152 or - * greater than largest int152). - * - * Counterpart to Solidity's `int152` operator. - * - * Requirements: - * - * - input must fit into 152 bits - * - * _Available since v4.7._ - */ - function toInt152(int256 value) internal pure returns (int152 downcasted) { - downcasted = int152(value); - require(downcasted == value, "SafeCast: value doesn't fit in 152 bits"); - } - - /** - * @dev Returns the downcasted int144 from int256, reverting on - * overflow (when the input is less than smallest int144 or - * greater than largest int144). - * - * Counterpart to Solidity's `int144` operator. - * - * Requirements: - * - * - input must fit into 144 bits - * - * _Available since v4.7._ - */ - function toInt144(int256 value) internal pure returns (int144 downcasted) { - downcasted = int144(value); - require(downcasted == value, "SafeCast: value doesn't fit in 144 bits"); - } - - /** - * @dev Returns the downcasted int136 from int256, reverting on - * overflow (when the input is less than smallest int136 or - * greater than largest int136). - * - * Counterpart to Solidity's `int136` operator. - * - * Requirements: - * - * - input must fit into 136 bits - * - * _Available since v4.7._ - */ - function toInt136(int256 value) internal pure returns (int136 downcasted) { - downcasted = int136(value); - require(downcasted == value, "SafeCast: value doesn't fit in 136 bits"); - } - - /** - * @dev Returns the downcasted int128 from int256, reverting on - * overflow (when the input is less than smallest int128 or - * greater than largest int128). - * - * Counterpart to Solidity's `int128` operator. - * - * Requirements: - * - * - input must fit into 128 bits - * - * _Available since v3.1._ - */ - function toInt128(int256 value) internal pure returns (int128 downcasted) { - downcasted = int128(value); - require(downcasted == value, "SafeCast: value doesn't fit in 128 bits"); - } - - /** - * @dev Returns the downcasted int120 from int256, reverting on - * overflow (when the input is less than smallest int120 or - * greater than largest int120). - * - * Counterpart to Solidity's `int120` operator. - * - * Requirements: - * - * - input must fit into 120 bits - * - * _Available since v4.7._ - */ - function toInt120(int256 value) internal pure returns (int120 downcasted) { - downcasted = int120(value); - require(downcasted == value, "SafeCast: value doesn't fit in 120 bits"); - } - - /** - * @dev Returns the downcasted int112 from int256, reverting on - * overflow (when the input is less than smallest int112 or - * greater than largest int112). - * - * Counterpart to Solidity's `int112` operator. - * - * Requirements: - * - * - input must fit into 112 bits - * - * _Available since v4.7._ - */ - function toInt112(int256 value) internal pure returns (int112 downcasted) { - downcasted = int112(value); - require(downcasted == value, "SafeCast: value doesn't fit in 112 bits"); - } - - /** - * @dev Returns the downcasted int104 from int256, reverting on - * overflow (when the input is less than smallest int104 or - * greater than largest int104). - * - * Counterpart to Solidity's `int104` operator. - * - * Requirements: - * - * - input must fit into 104 bits - * - * _Available since v4.7._ - */ - function toInt104(int256 value) internal pure returns (int104 downcasted) { - downcasted = int104(value); - require(downcasted == value, "SafeCast: value doesn't fit in 104 bits"); - } - - /** - * @dev Returns the downcasted int96 from int256, reverting on - * overflow (when the input is less than smallest int96 or - * greater than largest int96). - * - * Counterpart to Solidity's `int96` operator. - * - * Requirements: - * - * - input must fit into 96 bits - * - * _Available since v4.7._ - */ - function toInt96(int256 value) internal pure returns (int96 downcasted) { - downcasted = int96(value); - require(downcasted == value, "SafeCast: value doesn't fit in 96 bits"); - } - - /** - * @dev Returns the downcasted int88 from int256, reverting on - * overflow (when the input is less than smallest int88 or - * greater than largest int88). - * - * Counterpart to Solidity's `int88` operator. - * - * Requirements: - * - * - input must fit into 88 bits - * - * _Available since v4.7._ - */ - function toInt88(int256 value) internal pure returns (int88 downcasted) { - downcasted = int88(value); - require(downcasted == value, "SafeCast: value doesn't fit in 88 bits"); - } - - /** - * @dev Returns the downcasted int80 from int256, reverting on - * overflow (when the input is less than smallest int80 or - * greater than largest int80). - * - * Counterpart to Solidity's `int80` operator. - * - * Requirements: - * - * - input must fit into 80 bits - * - * _Available since v4.7._ - */ - function toInt80(int256 value) internal pure returns (int80 downcasted) { - downcasted = int80(value); - require(downcasted == value, "SafeCast: value doesn't fit in 80 bits"); - } - - /** - * @dev Returns the downcasted int72 from int256, reverting on - * overflow (when the input is less than smallest int72 or - * greater than largest int72). - * - * Counterpart to Solidity's `int72` operator. - * - * Requirements: - * - * - input must fit into 72 bits - * - * _Available since v4.7._ - */ - function toInt72(int256 value) internal pure returns (int72 downcasted) { - downcasted = int72(value); - require(downcasted == value, "SafeCast: value doesn't fit in 72 bits"); - } - - /** - * @dev Returns the downcasted int64 from int256, reverting on - * overflow (when the input is less than smallest int64 or - * greater than largest int64). - * - * Counterpart to Solidity's `int64` operator. - * - * Requirements: - * - * - input must fit into 64 bits - * - * _Available since v3.1._ - */ - function toInt64(int256 value) internal pure returns (int64 downcasted) { - downcasted = int64(value); - require(downcasted == value, "SafeCast: value doesn't fit in 64 bits"); - } - - /** - * @dev Returns the downcasted int56 from int256, reverting on - * overflow (when the input is less than smallest int56 or - * greater than largest int56). - * - * Counterpart to Solidity's `int56` operator. - * - * Requirements: - * - * - input must fit into 56 bits - * - * _Available since v4.7._ - */ - function toInt56(int256 value) internal pure returns (int56 downcasted) { - downcasted = int56(value); - require(downcasted == value, "SafeCast: value doesn't fit in 56 bits"); - } - - /** - * @dev Returns the downcasted int48 from int256, reverting on - * overflow (when the input is less than smallest int48 or - * greater than largest int48). - * - * Counterpart to Solidity's `int48` operator. - * - * Requirements: - * - * - input must fit into 48 bits - * - * _Available since v4.7._ - */ - function toInt48(int256 value) internal pure returns (int48 downcasted) { - downcasted = int48(value); - require(downcasted == value, "SafeCast: value doesn't fit in 48 bits"); - } - - /** - * @dev Returns the downcasted int40 from int256, reverting on - * overflow (when the input is less than smallest int40 or - * greater than largest int40). - * - * Counterpart to Solidity's `int40` operator. - * - * Requirements: - * - * - input must fit into 40 bits - * - * _Available since v4.7._ - */ - function toInt40(int256 value) internal pure returns (int40 downcasted) { - downcasted = int40(value); - require(downcasted == value, "SafeCast: value doesn't fit in 40 bits"); - } - - /** - * @dev Returns the downcasted int32 from int256, reverting on - * overflow (when the input is less than smallest int32 or - * greater than largest int32). - * - * Counterpart to Solidity's `int32` operator. - * - * Requirements: - * - * - input must fit into 32 bits - * - * _Available since v3.1._ - */ - function toInt32(int256 value) internal pure returns (int32 downcasted) { - downcasted = int32(value); - require(downcasted == value, "SafeCast: value doesn't fit in 32 bits"); - } - - /** - * @dev Returns the downcasted int24 from int256, reverting on - * overflow (when the input is less than smallest int24 or - * greater than largest int24). - * - * Counterpart to Solidity's `int24` operator. - * - * Requirements: - * - * - input must fit into 24 bits - * - * _Available since v4.7._ - */ - function toInt24(int256 value) internal pure returns (int24 downcasted) { - downcasted = int24(value); - require(downcasted == value, "SafeCast: value doesn't fit in 24 bits"); - } - - /** - * @dev Returns the downcasted int16 from int256, reverting on - * overflow (when the input is less than smallest int16 or - * greater than largest int16). - * - * Counterpart to Solidity's `int16` operator. - * - * Requirements: - * - * - input must fit into 16 bits - * - * _Available since v3.1._ - */ - function toInt16(int256 value) internal pure returns (int16 downcasted) { - downcasted = int16(value); - require(downcasted == value, "SafeCast: value doesn't fit in 16 bits"); - } - - /** - * @dev Returns the downcasted int8 from int256, reverting on - * overflow (when the input is less than smallest int8 or - * greater than largest int8). - * - * Counterpart to Solidity's `int8` operator. - * - * Requirements: - * - * - input must fit into 8 bits - * - * _Available since v3.1._ - */ - function toInt8(int256 value) internal pure returns (int8 downcasted) { - downcasted = int8(value); - require(downcasted == value, "SafeCast: value doesn't fit in 8 bits"); - } - - /** - * @dev Converts an unsigned uint256 into a signed int256. - * - * Requirements: - * - * - input must be less than or equal to maxInt256. - * - * _Available since v3.0._ - */ - function toInt256(uint256 value) internal pure returns (int256) { - // Note: Unsafe cast below is okay because `type(int256).max` is guaranteed to be positive - require(value <= uint256(type(int256).max), "SafeCast: value doesn't fit in an int256"); - return int256(value); - } -} \ No newline at end of file diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol deleted file mode 100644 index fc6224c8e38..00000000000 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ShortStrings.sol +++ /dev/null @@ -1,122 +0,0 @@ -// SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (utils/ShortStrings.sol) - -pragma solidity ^0.8.0; - -import {StorageSlot} from "./StorageSlot.sol"; - -// | string | 0xAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA | -// | length | 0x BB | -type ShortString is bytes32; - -/** - * @dev This library provides functions to convert short memory strings - * into a `ShortString` type that can be used as an immutable variable. - * - * Strings of arbitrary length can be optimized using this library if - * they are short enough (up to 31 bytes) by packing them with their - * length (1 byte) in a single EVM word (32 bytes). Additionally, a - * fallback mechanism can be used for every other case. - * - * Usage example: - * - * ```solidity - * contract Named { - * using ShortStrings for *; - * - * ShortString private immutable _name; - * string private _nameFallback; - * - * constructor(string memory contractName) { - * _name = contractName.toShortStringWithFallback(_nameFallback); - * } - * - * function name() external view returns (string memory) { - * return _name.toStringWithFallback(_nameFallback); - * } - * } - * ``` - */ -library ShortStrings { - // Used as an identifier for strings longer than 31 bytes. - bytes32 private constant _FALLBACK_SENTINEL = 0x00000000000000000000000000000000000000000000000000000000000000FF; - - error StringTooLong(string str); - error InvalidShortString(); - - /** - * @dev Encode a string of at most 31 chars into a `ShortString`. - * - * This will trigger a `StringTooLong` error is the input string is too long. - */ - function toShortString(string memory str) internal pure returns (ShortString) { - bytes memory bstr = bytes(str); - if (bstr.length > 31) { - revert StringTooLong(str); - } - return ShortString.wrap(bytes32(uint256(bytes32(bstr)) | bstr.length)); - } - - /** - * @dev Decode a `ShortString` back to a "normal" string. - */ - function toString(ShortString sstr) internal pure returns (string memory) { - uint256 len = byteLength(sstr); - // using `new string(len)` would work locally but is not memory safe. - string memory str = new string(32); - /// @solidity memory-safe-assembly - assembly { - mstore(str, len) - mstore(add(str, 0x20), sstr) - } - return str; - } - - /** - * @dev Return the length of a `ShortString`. - */ - function byteLength(ShortString sstr) internal pure returns (uint256) { - uint256 result = uint256(ShortString.unwrap(sstr)) & 0xFF; - if (result > 31) { - revert InvalidShortString(); - } - return result; - } - - /** - * @dev Encode a string into a `ShortString`, or write it to storage if it is too long. - */ - function toShortStringWithFallback(string memory value, string storage store) internal returns (ShortString) { - if (bytes(value).length < 32) { - return toShortString(value); - } else { - StorageSlot.getStringSlot(store).value = value; - return ShortString.wrap(_FALLBACK_SENTINEL); - } - } - - /** - * @dev Decode a string that was encoded to `ShortString` or written to storage using {setWithFallback}. - */ - function toStringWithFallback(ShortString value, string storage store) internal pure returns (string memory) { - if (ShortString.unwrap(value) != _FALLBACK_SENTINEL) { - return toString(value); - } else { - return store; - } - } - - /** - * @dev Return the length of a string that was encoded to `ShortString` or written to storage using {setWithFallback}. - * - * WARNING: This will return the "byte length" of the string. This may not reflect the actual length in terms of - * actual characters as the UTF-8 encoding of a single character can span over multiple bytes. - */ - function byteLengthWithFallback(ShortString value, string storage store) internal view returns (uint256) { - if (ShortString.unwrap(value) != _FALLBACK_SENTINEL) { - return byteLength(value); - } else { - return bytes(store).length; - } - } -} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol index 599f466e315..7e91bc6298c 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/StorageSlot.sol @@ -1,6 +1,5 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (utils/StorageSlot.sol) -// This file was procedurally generated from scripts/generate/templates/StorageSlot.js. +// OpenZeppelin Contracts (last updated v4.7.0) (utils/StorageSlot.sol) pragma solidity ^0.8.0; @@ -13,7 +12,7 @@ pragma solidity ^0.8.0; * The functions in this library return Slot structs that contain a `value` member that can be used to read or write. * * Example usage to set ERC1967 implementation slot: - * ```solidity + * ``` * contract ERC1967 { * bytes32 internal constant _IMPLEMENTATION_SLOT = 0x360894a13ba1a3210667c828492db98dca3e2076cc3735a920a3ca505d382bbc; * @@ -22,11 +21,13 @@ pragma solidity ^0.8.0; * } * * function _setImplementation(address newImplementation) internal { - * require(newImplementation.code.length > 0); + * require(Address.isContract(newImplementation), "ERC1967: new implementation is not a contract"); * StorageSlot.getAddressSlot(_IMPLEMENTATION_SLOT).value = newImplementation; * } * } * ``` + * + * _Available since v4.1 for `address`, `bool`, `bytes32`, and `uint256`._ */ library StorageSlot { struct AddressSlot { @@ -45,14 +46,6 @@ library StorageSlot { uint256 value; } - struct StringSlot { - string value; - } - - struct BytesSlot { - bytes value; - } - /** * @dev Returns an `AddressSlot` with member `value` located at `slot`. */ @@ -92,44 +85,4 @@ library StorageSlot { r.slot := slot } } - - /** - * @dev Returns an `StringSlot` with member `value` located at `slot`. - */ - function getStringSlot(bytes32 slot) internal pure returns (StringSlot storage r) { - /// @solidity memory-safe-assembly - assembly { - r.slot := slot - } - } - - /** - * @dev Returns an `StringSlot` representation of the string storage pointer `store`. - */ - function getStringSlot(string storage store) internal pure returns (StringSlot storage r) { - /// @solidity memory-safe-assembly - assembly { - r.slot := store.slot - } - } - - /** - * @dev Returns an `BytesSlot` with member `value` located at `slot`. - */ - function getBytesSlot(bytes32 slot) internal pure returns (BytesSlot storage r) { - /// @solidity memory-safe-assembly - assembly { - r.slot := slot - } - } - - /** - * @dev Returns an `BytesSlot` representation of the bytes storage pointer `store`. - */ - function getBytesSlot(bytes storage store) internal pure returns (BytesSlot storage r) { - /// @solidity memory-safe-assembly - assembly { - r.slot := store.slot - } - } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol index e16d66d9477..377ba46ad3b 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol @@ -1,10 +1,9 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (utils/Strings.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (utils/Strings.sol) pragma solidity ^0.8.0; -import {Math} from "./math/Math.sol"; -import {SignedMath} from "./math/SignedMath.sol"; +import "./math/Math.sol"; /** * @dev String operations. @@ -13,11 +12,6 @@ library Strings { bytes16 private constant _SYMBOLS = "0123456789abcdef"; uint8 private constant _ADDRESS_LENGTH = 20; - /** - * @dev The `value` string doesn't fit in the specified `length`. - */ - error StringsInsufficientHexLength(uint256 value, uint256 length); - /** * @dev Converts a `uint256` to its ASCII `string` decimal representation. */ @@ -43,13 +37,6 @@ library Strings { } } - /** - * @dev Converts a `int256` to its ASCII `string` decimal representation. - */ - function toStringSigned(int256 value) internal pure returns (string memory) { - return string.concat(value < 0 ? "-" : "", toString(SignedMath.abs(value))); - } - /** * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation. */ @@ -63,17 +50,14 @@ library Strings { * @dev Converts a `uint256` to its ASCII `string` hexadecimal representation with fixed length. */ function toHexString(uint256 value, uint256 length) internal pure returns (string memory) { - uint256 localValue = value; bytes memory buffer = new bytes(2 * length + 2); buffer[0] = "0"; buffer[1] = "x"; for (uint256 i = 2 * length + 1; i > 1; --i) { - buffer[i] = _SYMBOLS[localValue & 0xf]; - localValue >>= 4; - } - if (localValue != 0) { - revert StringsInsufficientHexLength(value, length); + buffer[i] = _SYMBOLS[value & 0xf]; + value >>= 4; } + require(value == 0, "Strings: hex length insufficient"); return string(buffer); } @@ -83,11 +67,4 @@ library Strings { function toHexString(address addr) internal pure returns (string memory) { return toHexString(uint256(uint160(addr)), _ADDRESS_LENGTH); } - - /** - * @dev Returns true if the two strings are equal. - */ - function equal(string memory a, string memory b) internal pure returns (bool) { - return bytes(a).length == bytes(b).length && keccak256(bytes(a)) == keccak256(bytes(b)); - } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol index ea3bf4833f0..65d4b81b7fd 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/ECDSA.sol @@ -1,8 +1,10 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (utils/cryptography/ECDSA.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/ECDSA.sol) pragma solidity ^0.8.0; +import "../Strings.sol"; + /** * @dev Elliptic Curve Digital Signature Algorithm (ECDSA) operations. * @@ -14,29 +16,27 @@ library ECDSA { NoError, InvalidSignature, InvalidSignatureLength, - InvalidSignatureS + InvalidSignatureS, + InvalidSignatureV // Deprecated in v4.8 } - /** - * @dev The signature derives the `address(0)`. - */ - error ECDSAInvalidSignature(); - - /** - * @dev The signature has an invalid length. - */ - error ECDSAInvalidSignatureLength(uint256 length); - - /** - * @dev The signature has an S value that is in the upper half order. - */ - error ECDSAInvalidSignatureS(bytes32 s); + function _throwError(RecoverError error) private pure { + if (error == RecoverError.NoError) { + return; // no error: do nothing + } else if (error == RecoverError.InvalidSignature) { + revert("ECDSA: invalid signature"); + } else if (error == RecoverError.InvalidSignatureLength) { + revert("ECDSA: invalid signature length"); + } else if (error == RecoverError.InvalidSignatureS) { + revert("ECDSA: invalid signature 's' value"); + } + } /** * @dev Returns the address that signed a hashed message (`hash`) with * `signature` or error string. This address can then be used for verification purposes. * - * The `ecrecover` EVM precompile allows for malleable (non-unique) signatures: + * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * @@ -44,13 +44,15 @@ library ECDSA { * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise - * be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it. + * be too long), and then calling {toEthSignedMessageHash} on it. * * Documentation for signature generation: * - with https://web3js.readthedocs.io/en/v1.3.4/web3-eth-accounts.html#sign[Web3.js] * - with https://docs.ethers.io/v5/api/signer/#Signer-signMessage[ethers] + * + * _Available since v4.3._ */ - function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError, bytes32) { + function tryRecover(bytes32 hash, bytes memory signature) internal pure returns (address, RecoverError) { if (signature.length == 65) { bytes32 r; bytes32 s; @@ -65,7 +67,7 @@ library ECDSA { } return tryRecover(hash, v, r, s); } else { - return (address(0), RecoverError.InvalidSignatureLength, bytes32(signature.length)); + return (address(0), RecoverError.InvalidSignatureLength); } } @@ -73,7 +75,7 @@ library ECDSA { * @dev Returns the address that signed a hashed message (`hash`) with * `signature`. This address can then be used for verification purposes. * - * The `ecrecover` EVM precompile allows for malleable (non-unique) signatures: + * The `ecrecover` EVM opcode allows for malleable (non-unique) signatures: * this function rejects them by requiring the `s` value to be in the lower * half order, and the `v` value to be either 27 or 28. * @@ -81,11 +83,11 @@ library ECDSA { * verification to be secure: it is possible to craft signatures that * recover to arbitrary addresses for non-hashed data. A safe way to ensure * this is by receiving a hash of the original message (which may otherwise - * be too long), and then calling {MessageHashUtils-toEthSignedMessageHash} on it. + * be too long), and then calling {toEthSignedMessageHash} on it. */ function recover(bytes32 hash, bytes memory signature) internal pure returns (address) { - (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, signature); - _throwError(error, errorArg); + (address recovered, RecoverError error) = tryRecover(hash, signature); + _throwError(error); return recovered; } @@ -93,35 +95,33 @@ library ECDSA { * @dev Overload of {ECDSA-tryRecover} that receives the `r` and `vs` short-signature fields separately. * * See https://eips.ethereum.org/EIPS/eip-2098[EIP-2098 short signatures] + * + * _Available since v4.3._ */ - function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError, bytes32) { - unchecked { - bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); - // We do not check for an overflow here since the shift operation results in 0 or 1. - uint8 v = uint8((uint256(vs) >> 255) + 27); - return tryRecover(hash, v, r, s); - } + function tryRecover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address, RecoverError) { + bytes32 s = vs & bytes32(0x7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff); + uint8 v = uint8((uint256(vs) >> 255) + 27); + return tryRecover(hash, v, r, s); } /** * @dev Overload of {ECDSA-recover} that receives the `r and `vs` short-signature fields separately. + * + * _Available since v4.2._ */ function recover(bytes32 hash, bytes32 r, bytes32 vs) internal pure returns (address) { - (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, r, vs); - _throwError(error, errorArg); + (address recovered, RecoverError error) = tryRecover(hash, r, vs); + _throwError(error); return recovered; } /** * @dev Overload of {ECDSA-tryRecover} that receives the `v`, * `r` and `s` signature fields separately. + * + * _Available since v4.3._ */ - function tryRecover( - bytes32 hash, - uint8 v, - bytes32 r, - bytes32 s - ) internal pure returns (address, RecoverError, bytes32) { + function tryRecover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address, RecoverError) { // EIP-2 still allows signature malleability for ecrecover(). Remove this possibility and make the signature // unique. Appendix F in the Ethereum Yellow paper (https://ethereum.github.io/yellowpaper/paper.pdf), defines // the valid range for s in (301): 0 < s < secp256k1n ÷ 2 + 1, and for v in (302): v ∈ {27, 28}. Most @@ -132,16 +132,16 @@ library ECDSA { // vice versa. If your library also generates signatures with 0/1 for v instead 27/28, add 27 to v to accept // these malleable signatures as well. if (uint256(s) > 0x7FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF5D576E7357A4501DDFE92F46681B20A0) { - return (address(0), RecoverError.InvalidSignatureS, s); + return (address(0), RecoverError.InvalidSignatureS); } // If the signature is valid (and not malleable), return the signer address address signer = ecrecover(hash, v, r, s); if (signer == address(0)) { - return (address(0), RecoverError.InvalidSignature, bytes32(0)); + return (address(0), RecoverError.InvalidSignature); } - return (signer, RecoverError.NoError, bytes32(0)); + return (signer, RecoverError.NoError); } /** @@ -149,23 +149,47 @@ library ECDSA { * `r` and `s` signature fields separately. */ function recover(bytes32 hash, uint8 v, bytes32 r, bytes32 s) internal pure returns (address) { - (address recovered, RecoverError error, bytes32 errorArg) = tryRecover(hash, v, r, s); - _throwError(error, errorArg); + (address recovered, RecoverError error) = tryRecover(hash, v, r, s); + _throwError(error); return recovered; } /** - * @dev Optionally reverts with the corresponding custom error according to the `error` argument provided. + * @dev Returns an Ethereum Signed Message, created from a `hash`. This + * produces hash corresponding to the one signed with the + * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] + * JSON-RPC method as part of EIP-191. + * + * See {recover}. */ - function _throwError(RecoverError error, bytes32 errorArg) private pure { - if (error == RecoverError.NoError) { - return; // no error: do nothing - } else if (error == RecoverError.InvalidSignature) { - revert ECDSAInvalidSignature(); - } else if (error == RecoverError.InvalidSignatureLength) { - revert ECDSAInvalidSignatureLength(uint256(errorArg)); - } else if (error == RecoverError.InvalidSignatureS) { - revert ECDSAInvalidSignatureS(errorArg); - } + function toEthSignedMessageHash(bytes32 hash) internal pure returns (bytes32) { + // 32 is the length in bytes of hash, + // enforced by the type signature above + return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", hash)); + } + + /** + * @dev Returns an Ethereum Signed Message, created from `s`. This + * produces hash corresponding to the one signed with the + * https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] + * JSON-RPC method as part of EIP-191. + * + * See {recover}. + */ + function toEthSignedMessageHash(bytes memory s) internal pure returns (bytes32) { + return keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n", Strings.toString(s.length), s)); + } + + /** + * @dev Returns an Ethereum Signed Typed Data, created from a + * `domainSeparator` and a `structHash`. This produces hash corresponding + * to the one signed with the + * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] + * JSON-RPC method as part of EIP-712. + * + * See {recover}. + */ + function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32) { + return keccak256(abi.encodePacked("\x19\x01", domainSeparator, structHash)); } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol index bfaf8bd6576..6924570ec04 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/EIP712.sol @@ -1,19 +1,16 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (utils/cryptography/EIP712.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (utils/cryptography/EIP712.sol) pragma solidity ^0.8.0; -import {MessageHashUtils} from "./MessageHashUtils.sol"; -import {ShortStrings, ShortString} from "../ShortStrings.sol"; -import {IERC5267} from "../../interfaces/IERC5267.sol"; +import "./ECDSA.sol"; /** * @dev https://eips.ethereum.org/EIPS/eip-712[EIP 712] is a standard for hashing and signing of typed structured data. * - * The encoding scheme specified in the EIP requires a domain separator and a hash of the typed structured data, whose - * encoding is very generic and therefore its implementation in Solidity is not feasible, thus this contract - * does not implement the encoding itself. Protocols need to implement the type-specific encoding they need in order to - * produce the hash of their typed data using a combination of `abi.encode` and `keccak256`. + * The encoding specified in the EIP is very generic, and such a generic implementation in Solidity is not feasible, + * thus this contract does not implement the encoding itself. Protocols need to implement the type-specific encoding + * they need in their contracts using a combination of `abi.encode` and `keccak256`. * * This contract implements the EIP 712 domain separator ({_domainSeparatorV4}) that is used as part of the encoding * scheme, and the final step of the encoding to obtain the message digest that is then signed via ECDSA @@ -25,31 +22,21 @@ import {IERC5267} from "../../interfaces/IERC5267.sol"; * NOTE: This contract implements the version of the encoding known as "v4", as implemented by the JSON RPC method * https://docs.metamask.io/guide/signing-data.html[`eth_signTypedDataV4` in MetaMask]. * - * NOTE: In the upgradeable version of this contract, the cached values will correspond to the address, and the domain - * separator of the implementation contract. This will cause the {_domainSeparatorV4} function to always rebuild the - * separator from the immutable values, which is cheaper than accessing a cached version in cold storage. - * - * @custom:oz-upgrades-unsafe-allow state-variable-immutable + * _Available since v3.4._ */ -abstract contract EIP712 is IERC5267 { - using ShortStrings for *; - - bytes32 private constant _TYPE_HASH = - keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); - +abstract contract EIP712 { + /* solhint-disable var-name-mixedcase */ // Cache the domain separator as an immutable value, but also store the chain id that it corresponds to, in order to // invalidate the cached domain separator if the chain id changes. - bytes32 private immutable _cachedDomainSeparator; - uint256 private immutable _cachedChainId; - address private immutable _cachedThis; + bytes32 private immutable _CACHED_DOMAIN_SEPARATOR; + uint256 private immutable _CACHED_CHAIN_ID; + address private immutable _CACHED_THIS; - bytes32 private immutable _hashedName; - bytes32 private immutable _hashedVersion; + bytes32 private immutable _HASHED_NAME; + bytes32 private immutable _HASHED_VERSION; + bytes32 private immutable _TYPE_HASH; - ShortString private immutable _name; - ShortString private immutable _version; - string private _nameFallback; - string private _versionFallback; + /* solhint-enable var-name-mixedcase */ /** * @dev Initializes the domain separator and parameter caches. @@ -64,29 +51,34 @@ abstract contract EIP712 is IERC5267 { * contract upgrade]. */ constructor(string memory name, string memory version) { - _name = name.toShortStringWithFallback(_nameFallback); - _version = version.toShortStringWithFallback(_versionFallback); - _hashedName = keccak256(bytes(name)); - _hashedVersion = keccak256(bytes(version)); - - _cachedChainId = block.chainid; - _cachedDomainSeparator = _buildDomainSeparator(); - _cachedThis = address(this); + bytes32 hashedName = keccak256(bytes(name)); + bytes32 hashedVersion = keccak256(bytes(version)); + bytes32 typeHash = keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); + _HASHED_NAME = hashedName; + _HASHED_VERSION = hashedVersion; + _CACHED_CHAIN_ID = block.chainid; + _CACHED_DOMAIN_SEPARATOR = _buildDomainSeparator(typeHash, hashedName, hashedVersion); + _CACHED_THIS = address(this); + _TYPE_HASH = typeHash; } /** * @dev Returns the domain separator for the current chain. */ function _domainSeparatorV4() internal view returns (bytes32) { - if (address(this) == _cachedThis && block.chainid == _cachedChainId) { - return _cachedDomainSeparator; + if (address(this) == _CACHED_THIS && block.chainid == _CACHED_CHAIN_ID) { + return _CACHED_DOMAIN_SEPARATOR; } else { - return _buildDomainSeparator(); + return _buildDomainSeparator(_TYPE_HASH, _HASHED_NAME, _HASHED_VERSION); } } - function _buildDomainSeparator() private view returns (bytes32) { - return keccak256(abi.encode(_TYPE_HASH, _hashedName, _hashedVersion, block.chainid, address(this))); + function _buildDomainSeparator( + bytes32 typeHash, + bytes32 nameHash, + bytes32 versionHash + ) private view returns (bytes32) { + return keccak256(abi.encode(typeHash, nameHash, versionHash, block.chainid, address(this))); } /** @@ -105,56 +97,6 @@ abstract contract EIP712 is IERC5267 { * ``` */ function _hashTypedDataV4(bytes32 structHash) internal view virtual returns (bytes32) { - return MessageHashUtils.toTypedDataHash(_domainSeparatorV4(), structHash); - } - - /** - * @dev See {IERC-5267}. - */ - function eip712Domain() - public - view - virtual - returns ( - bytes1 fields, - string memory name, - string memory version, - uint256 chainId, - address verifyingContract, - bytes32 salt, - uint256[] memory extensions - ) - { - return ( - hex"0f", // 01111 - _EIP712Name(), - _EIP712Version(), - block.chainid, - address(this), - bytes32(0), - new uint256[](0) - ); - } - - /** - * @dev The name parameter for the EIP712 domain. - * - * NOTE: By default this function reads _name which is an immutable value. - * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). - */ - // solhint-disable-next-line func-name-mixedcase - function _EIP712Name() internal view returns (string memory) { - return _name.toStringWithFallback(_nameFallback); - } - - /** - * @dev The version parameter for the EIP712 domain. - * - * NOTE: By default this function reads _version which is an immutable value. - * It only reads from storage if necessary (in case the value is too large to fit in a ShortString). - */ - // solhint-disable-next-line func-name-mixedcase - function _EIP712Version() internal view returns (string memory) { - return _version.toStringWithFallback(_versionFallback); + return ECDSA.toTypedDataHash(_domainSeparatorV4(), structHash); } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol deleted file mode 100644 index fa0730e35bd..00000000000 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/cryptography/MessageHashUtils.sol +++ /dev/null @@ -1,87 +0,0 @@ -// SPDX-License-Identifier: MIT - -pragma solidity ^0.8.0; - -import {Strings} from "../Strings.sol"; - -/** - * @dev Signature message hash utilities for producing digests to be consumed by {ECDSA} recovery or signing. - * - * The library provides methods for generating a hash of a message that conforms to the - * https://eips.ethereum.org/EIPS/eip-191[EIP 191] and https://eips.ethereum.org/EIPS/eip-712[EIP 712] - * specifications. - */ -library MessageHashUtils { - /** - * @dev Returns the keccak256 digest of an EIP-191 signed data with version - * `0x45` (`personal_sign` messages). - * - * The digest is calculated by prefixing a bytes32 `messageHash` with - * `"\x19Ethereum Signed Message:\n32"` and hashing the result. It corresponds with the - * hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method. - * - * NOTE: The `hash` parameter is intended to be the result of hashing a raw message with - * keccak256, although any bytes32 value can be safely used because the final digest will - * be re-hashed. - * - * See {ECDSA-recover}. - */ - function toEthSignedMessageHash(bytes32 messageHash) internal pure returns (bytes32 digest) { - /// @solidity memory-safe-assembly - assembly { - mstore(0x00, "\x19Ethereum Signed Message:\n32") // 32 is the bytes-length of messageHash - mstore(0x1c, messageHash) // 0x1c (28) is the length of the prefix - digest := keccak256(0x00, 0x3c) // 0x3c is the length of the prefix (0x1c) + messageHash (0x20) - } - } - - /** - * @dev Returns the keccak256 digest of an EIP-191 signed data with version - * `0x45` (`personal_sign` messages). - * - * The digest is calculated by prefixing an arbitrary `message` with - * `"\x19Ethereum Signed Message:\n" + len(message)` and hashing the result. It corresponds with the - * hash signed when using the https://eth.wiki/json-rpc/API#eth_sign[`eth_sign`] JSON-RPC method. - * - * See {ECDSA-recover}. - */ - function toEthSignedMessageHash(bytes memory message) internal pure returns (bytes32 digest) { - return keccak256(bytes.concat("\x19Ethereum Signed Message:\n", bytes(Strings.toString(message.length)), message)); - } - - /** - * @dev Returns the keccak256 digest of an EIP-191 signed data with version - * `0x00` (data with intended validator). - * - * The digest is calculated by prefixing an arbitrary `data` with `"\x19\x00"` and the intended - * `validator` address. Then hashing the result. - * - * See {ECDSA-recover}. - */ - function toDataWithIntendedValidatorHash( - address validator, - bytes memory data - ) internal pure returns (bytes32 digest) { - return keccak256(abi.encodePacked(hex"19_00", validator, data)); - } - - /** - * @dev Returns the keccak256 digest of an EIP-712 typed data (EIP-191 version `0x01`). - * - * The digest is calculated from a `domainSeparator` and a `structHash`, by prefixing them with - * `\x19\x01` and hashing the result. It corresponds to the hash signed by the - * https://eips.ethereum.org/EIPS/eip-712[`eth_signTypedData`] JSON-RPC method as part of EIP-712. - * - * See {ECDSA-recover}. - */ - function toTypedDataHash(bytes32 domainSeparator, bytes32 structHash) internal pure returns (bytes32 digest) { - /// @solidity memory-safe-assembly - assembly { - let ptr := mload(0x40) - mstore(ptr, hex"19_01") - mstore(add(ptr, 0x02), domainSeparator) - mstore(add(ptr, 0x22), structHash) - digest := keccak256(ptr, 0x42) - } - } -} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol index e429e5db781..7a793295ae1 100644 --- a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol @@ -1,5 +1,5 @@ // SPDX-License-Identifier: MIT -// OpenZeppelin Contracts (last updated v4.9.0) (utils/math/Math.sol) +// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/Math.sol) pragma solidity ^0.8.0; @@ -7,72 +7,10 @@ pragma solidity ^0.8.0; * @dev Standard math utilities missing in the Solidity language. */ library Math { - /** - * @dev Muldiv operation overflow. - */ - error MathOverflowedMulDiv(); - enum Rounding { - Floor, // Toward negative infinity - Ceil, // Toward positive infinity - Trunc, // Toward zero - Expand // Away from zero - } - - /** - * @dev Returns the addition of two unsigned integers, with an overflow flag. - */ - function tryAdd(uint256 a, uint256 b) internal pure returns (bool, uint256) { - unchecked { - uint256 c = a + b; - if (c < a) return (false, 0); - return (true, c); - } - } - - /** - * @dev Returns the subtraction of two unsigned integers, with an overflow flag. - */ - function trySub(uint256 a, uint256 b) internal pure returns (bool, uint256) { - unchecked { - if (b > a) return (false, 0); - return (true, a - b); - } - } - - /** - * @dev Returns the multiplication of two unsigned integers, with an overflow flag. - */ - function tryMul(uint256 a, uint256 b) internal pure returns (bool, uint256) { - unchecked { - // Gas optimization: this is cheaper than requiring 'a' not being zero, but the - // benefit is lost if 'b' is also tested. - // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522 - if (a == 0) return (true, 0); - uint256 c = a * b; - if (c / a != b) return (false, 0); - return (true, c); - } - } - - /** - * @dev Returns the division of two unsigned integers, with a division by zero flag. - */ - function tryDiv(uint256 a, uint256 b) internal pure returns (bool, uint256) { - unchecked { - if (b == 0) return (false, 0); - return (true, a / b); - } - } - - /** - * @dev Returns the remainder of dividing two unsigned integers, with a division by zero flag. - */ - function tryMod(uint256 a, uint256 b) internal pure returns (bool, uint256) { - unchecked { - if (b == 0) return (false, 0); - return (true, a % b); - } + Down, // Toward negative infinity + Up, // Toward infinity + Zero // Toward zero } /** @@ -101,15 +39,10 @@ library Math { /** * @dev Returns the ceiling of the division of two numbers. * - * This differs from standard division with `/` in that it rounds towards infinity instead - * of rounding towards zero. + * This differs from standard division with `/` in that it rounds up instead + * of rounding down. */ function ceilDiv(uint256 a, uint256 b) internal pure returns (uint256) { - if (b == 0) { - // Guarantee the same behavior as in a regular Solidity division. - return a / b; - } - // (a + b - 1) / b can overflow on addition, so we distribute. return a == 0 ? 0 : (a - 1) / b + 1; } @@ -124,25 +57,21 @@ library Math { // 512-bit multiply [prod1 prod0] = x * y. Compute the product mod 2^256 and mod 2^256 - 1, then use // use the Chinese Remainder Theorem to reconstruct the 512 bit result. The result is stored in two 256 // variables such that product = prod1 * 2^256 + prod0. - uint256 prod0 = x * y; // Least significant 256 bits of the product + uint256 prod0; // Least significant 256 bits of the product uint256 prod1; // Most significant 256 bits of the product assembly { let mm := mulmod(x, y, not(0)) + prod0 := mul(x, y) prod1 := sub(sub(mm, prod0), lt(mm, prod0)) } // Handle non-overflow cases, 256 by 256 division. if (prod1 == 0) { - // Solidity will revert if denominator == 0, unlike the div opcode on its own. - // The surrounding unchecked block does not change this fact. - // See https://docs.soliditylang.org/en/latest/control-structures.html#checked-or-unchecked-arithmetic. return prod0 / denominator; } // Make sure the result is less than 2^256. Also prevents denominator == 0. - if (denominator <= prod1) { - revert MathOverflowedMulDiv(); - } + require(denominator > prod1); /////////////////////////////////////////////// // 512 by 256 division. @@ -162,7 +91,8 @@ library Math { // Factor powers of two out of denominator and compute largest power of two divisor of denominator. Always >= 1. // See https://cs.stackexchange.com/q/138556/92363. - uint256 twos = denominator & (0 - denominator); + // Does not overflow because the denominator cannot be zero at this stage in the function. + uint256 twos = denominator & (~denominator + 1); assembly { // Divide denominator by twos. denominator := div(denominator, twos) @@ -205,15 +135,14 @@ library Math { */ function mulDiv(uint256 x, uint256 y, uint256 denominator, Rounding rounding) internal pure returns (uint256) { uint256 result = mulDiv(x, y, denominator); - if (unsignedRoundsUp(rounding) && mulmod(x, y, denominator) > 0) { + if (rounding == Rounding.Up && mulmod(x, y, denominator) > 0) { result += 1; } return result; } /** - * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded - * towards zero. + * @dev Returns the square root of a number. If the number is not a perfect square, the value is rounded down. * * Inspired by Henry S. Warren, Jr.'s "Hacker's Delight" (Chapter 11). */ @@ -256,12 +185,12 @@ library Math { function sqrt(uint256 a, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = sqrt(a); - return result + (unsignedRoundsUp(rounding) && result * result < a ? 1 : 0); + return result + (rounding == Rounding.Up && result * result < a ? 1 : 0); } } /** - * @dev Return the log in base 2 of a positive value rounded towards zero. + * @dev Return the log in base 2, rounded down, of a positive value. * Returns 0 if given 0. */ function log2(uint256 value) internal pure returns (uint256) { @@ -309,12 +238,12 @@ library Math { function log2(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log2(value); - return result + (unsignedRoundsUp(rounding) && 1 << result < value ? 1 : 0); + return result + (rounding == Rounding.Up && 1 << result < value ? 1 : 0); } } /** - * @dev Return the log in base 10 of a positive value rounded towards zero. + * @dev Return the log in base 10, rounded down, of a positive value. * Returns 0 if given 0. */ function log10(uint256 value) internal pure returns (uint256) { @@ -358,12 +287,12 @@ library Math { function log10(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log10(value); - return result + (unsignedRoundsUp(rounding) && 10 ** result < value ? 1 : 0); + return result + (rounding == Rounding.Up && 10 ** result < value ? 1 : 0); } } /** - * @dev Return the log in base 256 of a positive value rounded towards zero. + * @dev Return the log in base 256, rounded down, of a positive value. * Returns 0 if given 0. * * Adding one to the result gives the number of pairs of hex symbols needed to represent `value` as a hex string. @@ -395,20 +324,13 @@ library Math { } /** - * @dev Return the log in base 256, following the selected rounding direction, of a positive value. + * @dev Return the log in base 10, following the selected rounding direction, of a positive value. * Returns 0 if given 0. */ function log256(uint256 value, Rounding rounding) internal pure returns (uint256) { unchecked { uint256 result = log256(value); - return result + (unsignedRoundsUp(rounding) && 1 << (result << 3) < value ? 1 : 0); + return result + (rounding == Rounding.Up && 1 << (result * 8) < value ? 1 : 0); } } - - /** - * @dev Returns whether a provided rounding mode is considered rounding up for unsigned integers. - */ - function unsignedRoundsUp(Rounding rounding) internal pure returns (bool) { - return uint8(rounding) % 2 == 1; - } } diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol new file mode 100644 index 00000000000..28c11118317 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol @@ -0,0 +1,1136 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.8.0) (utils/math/SafeCast.sol) +// This file was procedurally generated from scripts/generate/templates/SafeCast.js. + +pragma solidity ^0.8.0; + +/** + * @dev Wrappers over Solidity's uintXX/intXX casting operators with added overflow + * checks. + * + * Downcasting from uint256/int256 in Solidity does not revert on overflow. This can + * easily result in undesired exploitation or bugs, since developers usually + * assume that overflows raise errors. `SafeCast` restores this intuition by + * reverting the transaction when such an operation overflows. + * + * Using this library instead of the unchecked operations eliminates an entire + * class of bugs, so it's recommended to use it always. + * + * Can be combined with {SafeMath} and {SignedSafeMath} to extend it to smaller types, by performing + * all math on `uint256` and `int256` and then downcasting. + */ +library SafeCast { + /** + * @dev Returns the downcasted uint248 from uint256, reverting on + * overflow (when the input is greater than largest uint248). + * + * Counterpart to Solidity's `uint248` operator. + * + * Requirements: + * + * - input must fit into 248 bits + * + * _Available since v4.7._ + */ + function toUint248(uint256 value) internal pure returns (uint248) { + require(value <= type(uint248).max, "SafeCast: value doesn't fit in 248 bits"); + return uint248(value); + } + + /** + * @dev Returns the downcasted uint240 from uint256, reverting on + * overflow (when the input is greater than largest uint240). + * + * Counterpart to Solidity's `uint240` operator. + * + * Requirements: + * + * - input must fit into 240 bits + * + * _Available since v4.7._ + */ + function toUint240(uint256 value) internal pure returns (uint240) { + require(value <= type(uint240).max, "SafeCast: value doesn't fit in 240 bits"); + return uint240(value); + } + + /** + * @dev Returns the downcasted uint232 from uint256, reverting on + * overflow (when the input is greater than largest uint232). + * + * Counterpart to Solidity's `uint232` operator. + * + * Requirements: + * + * - input must fit into 232 bits + * + * _Available since v4.7._ + */ + function toUint232(uint256 value) internal pure returns (uint232) { + require(value <= type(uint232).max, "SafeCast: value doesn't fit in 232 bits"); + return uint232(value); + } + + /** + * @dev Returns the downcasted uint224 from uint256, reverting on + * overflow (when the input is greater than largest uint224). + * + * Counterpart to Solidity's `uint224` operator. + * + * Requirements: + * + * - input must fit into 224 bits + * + * _Available since v4.2._ + */ + function toUint224(uint256 value) internal pure returns (uint224) { + require(value <= type(uint224).max, "SafeCast: value doesn't fit in 224 bits"); + return uint224(value); + } + + /** + * @dev Returns the downcasted uint216 from uint256, reverting on + * overflow (when the input is greater than largest uint216). + * + * Counterpart to Solidity's `uint216` operator. + * + * Requirements: + * + * - input must fit into 216 bits + * + * _Available since v4.7._ + */ + function toUint216(uint256 value) internal pure returns (uint216) { + require(value <= type(uint216).max, "SafeCast: value doesn't fit in 216 bits"); + return uint216(value); + } + + /** + * @dev Returns the downcasted uint208 from uint256, reverting on + * overflow (when the input is greater than largest uint208). + * + * Counterpart to Solidity's `uint208` operator. + * + * Requirements: + * + * - input must fit into 208 bits + * + * _Available since v4.7._ + */ + function toUint208(uint256 value) internal pure returns (uint208) { + require(value <= type(uint208).max, "SafeCast: value doesn't fit in 208 bits"); + return uint208(value); + } + + /** + * @dev Returns the downcasted uint200 from uint256, reverting on + * overflow (when the input is greater than largest uint200). + * + * Counterpart to Solidity's `uint200` operator. + * + * Requirements: + * + * - input must fit into 200 bits + * + * _Available since v4.7._ + */ + function toUint200(uint256 value) internal pure returns (uint200) { + require(value <= type(uint200).max, "SafeCast: value doesn't fit in 200 bits"); + return uint200(value); + } + + /** + * @dev Returns the downcasted uint192 from uint256, reverting on + * overflow (when the input is greater than largest uint192). + * + * Counterpart to Solidity's `uint192` operator. + * + * Requirements: + * + * - input must fit into 192 bits + * + * _Available since v4.7._ + */ + function toUint192(uint256 value) internal pure returns (uint192) { + require(value <= type(uint192).max, "SafeCast: value doesn't fit in 192 bits"); + return uint192(value); + } + + /** + * @dev Returns the downcasted uint184 from uint256, reverting on + * overflow (when the input is greater than largest uint184). + * + * Counterpart to Solidity's `uint184` operator. + * + * Requirements: + * + * - input must fit into 184 bits + * + * _Available since v4.7._ + */ + function toUint184(uint256 value) internal pure returns (uint184) { + require(value <= type(uint184).max, "SafeCast: value doesn't fit in 184 bits"); + return uint184(value); + } + + /** + * @dev Returns the downcasted uint176 from uint256, reverting on + * overflow (when the input is greater than largest uint176). + * + * Counterpart to Solidity's `uint176` operator. + * + * Requirements: + * + * - input must fit into 176 bits + * + * _Available since v4.7._ + */ + function toUint176(uint256 value) internal pure returns (uint176) { + require(value <= type(uint176).max, "SafeCast: value doesn't fit in 176 bits"); + return uint176(value); + } + + /** + * @dev Returns the downcasted uint168 from uint256, reverting on + * overflow (when the input is greater than largest uint168). + * + * Counterpart to Solidity's `uint168` operator. + * + * Requirements: + * + * - input must fit into 168 bits + * + * _Available since v4.7._ + */ + function toUint168(uint256 value) internal pure returns (uint168) { + require(value <= type(uint168).max, "SafeCast: value doesn't fit in 168 bits"); + return uint168(value); + } + + /** + * @dev Returns the downcasted uint160 from uint256, reverting on + * overflow (when the input is greater than largest uint160). + * + * Counterpart to Solidity's `uint160` operator. + * + * Requirements: + * + * - input must fit into 160 bits + * + * _Available since v4.7._ + */ + function toUint160(uint256 value) internal pure returns (uint160) { + require(value <= type(uint160).max, "SafeCast: value doesn't fit in 160 bits"); + return uint160(value); + } + + /** + * @dev Returns the downcasted uint152 from uint256, reverting on + * overflow (when the input is greater than largest uint152). + * + * Counterpart to Solidity's `uint152` operator. + * + * Requirements: + * + * - input must fit into 152 bits + * + * _Available since v4.7._ + */ + function toUint152(uint256 value) internal pure returns (uint152) { + require(value <= type(uint152).max, "SafeCast: value doesn't fit in 152 bits"); + return uint152(value); + } + + /** + * @dev Returns the downcasted uint144 from uint256, reverting on + * overflow (when the input is greater than largest uint144). + * + * Counterpart to Solidity's `uint144` operator. + * + * Requirements: + * + * - input must fit into 144 bits + * + * _Available since v4.7._ + */ + function toUint144(uint256 value) internal pure returns (uint144) { + require(value <= type(uint144).max, "SafeCast: value doesn't fit in 144 bits"); + return uint144(value); + } + + /** + * @dev Returns the downcasted uint136 from uint256, reverting on + * overflow (when the input is greater than largest uint136). + * + * Counterpart to Solidity's `uint136` operator. + * + * Requirements: + * + * - input must fit into 136 bits + * + * _Available since v4.7._ + */ + function toUint136(uint256 value) internal pure returns (uint136) { + require(value <= type(uint136).max, "SafeCast: value doesn't fit in 136 bits"); + return uint136(value); + } + + /** + * @dev Returns the downcasted uint128 from uint256, reverting on + * overflow (when the input is greater than largest uint128). + * + * Counterpart to Solidity's `uint128` operator. + * + * Requirements: + * + * - input must fit into 128 bits + * + * _Available since v2.5._ + */ + function toUint128(uint256 value) internal pure returns (uint128) { + require(value <= type(uint128).max, "SafeCast: value doesn't fit in 128 bits"); + return uint128(value); + } + + /** + * @dev Returns the downcasted uint120 from uint256, reverting on + * overflow (when the input is greater than largest uint120). + * + * Counterpart to Solidity's `uint120` operator. + * + * Requirements: + * + * - input must fit into 120 bits + * + * _Available since v4.7._ + */ + function toUint120(uint256 value) internal pure returns (uint120) { + require(value <= type(uint120).max, "SafeCast: value doesn't fit in 120 bits"); + return uint120(value); + } + + /** + * @dev Returns the downcasted uint112 from uint256, reverting on + * overflow (when the input is greater than largest uint112). + * + * Counterpart to Solidity's `uint112` operator. + * + * Requirements: + * + * - input must fit into 112 bits + * + * _Available since v4.7._ + */ + function toUint112(uint256 value) internal pure returns (uint112) { + require(value <= type(uint112).max, "SafeCast: value doesn't fit in 112 bits"); + return uint112(value); + } + + /** + * @dev Returns the downcasted uint104 from uint256, reverting on + * overflow (when the input is greater than largest uint104). + * + * Counterpart to Solidity's `uint104` operator. + * + * Requirements: + * + * - input must fit into 104 bits + * + * _Available since v4.7._ + */ + function toUint104(uint256 value) internal pure returns (uint104) { + require(value <= type(uint104).max, "SafeCast: value doesn't fit in 104 bits"); + return uint104(value); + } + + /** + * @dev Returns the downcasted uint96 from uint256, reverting on + * overflow (when the input is greater than largest uint96). + * + * Counterpart to Solidity's `uint96` operator. + * + * Requirements: + * + * - input must fit into 96 bits + * + * _Available since v4.2._ + */ + function toUint96(uint256 value) internal pure returns (uint96) { + require(value <= type(uint96).max, "SafeCast: value doesn't fit in 96 bits"); + return uint96(value); + } + + /** + * @dev Returns the downcasted uint88 from uint256, reverting on + * overflow (when the input is greater than largest uint88). + * + * Counterpart to Solidity's `uint88` operator. + * + * Requirements: + * + * - input must fit into 88 bits + * + * _Available since v4.7._ + */ + function toUint88(uint256 value) internal pure returns (uint88) { + require(value <= type(uint88).max, "SafeCast: value doesn't fit in 88 bits"); + return uint88(value); + } + + /** + * @dev Returns the downcasted uint80 from uint256, reverting on + * overflow (when the input is greater than largest uint80). + * + * Counterpart to Solidity's `uint80` operator. + * + * Requirements: + * + * - input must fit into 80 bits + * + * _Available since v4.7._ + */ + function toUint80(uint256 value) internal pure returns (uint80) { + require(value <= type(uint80).max, "SafeCast: value doesn't fit in 80 bits"); + return uint80(value); + } + + /** + * @dev Returns the downcasted uint72 from uint256, reverting on + * overflow (when the input is greater than largest uint72). + * + * Counterpart to Solidity's `uint72` operator. + * + * Requirements: + * + * - input must fit into 72 bits + * + * _Available since v4.7._ + */ + function toUint72(uint256 value) internal pure returns (uint72) { + require(value <= type(uint72).max, "SafeCast: value doesn't fit in 72 bits"); + return uint72(value); + } + + /** + * @dev Returns the downcasted uint64 from uint256, reverting on + * overflow (when the input is greater than largest uint64). + * + * Counterpart to Solidity's `uint64` operator. + * + * Requirements: + * + * - input must fit into 64 bits + * + * _Available since v2.5._ + */ + function toUint64(uint256 value) internal pure returns (uint64) { + require(value <= type(uint64).max, "SafeCast: value doesn't fit in 64 bits"); + return uint64(value); + } + + /** + * @dev Returns the downcasted uint56 from uint256, reverting on + * overflow (when the input is greater than largest uint56). + * + * Counterpart to Solidity's `uint56` operator. + * + * Requirements: + * + * - input must fit into 56 bits + * + * _Available since v4.7._ + */ + function toUint56(uint256 value) internal pure returns (uint56) { + require(value <= type(uint56).max, "SafeCast: value doesn't fit in 56 bits"); + return uint56(value); + } + + /** + * @dev Returns the downcasted uint48 from uint256, reverting on + * overflow (when the input is greater than largest uint48). + * + * Counterpart to Solidity's `uint48` operator. + * + * Requirements: + * + * - input must fit into 48 bits + * + * _Available since v4.7._ + */ + function toUint48(uint256 value) internal pure returns (uint48) { + require(value <= type(uint48).max, "SafeCast: value doesn't fit in 48 bits"); + return uint48(value); + } + + /** + * @dev Returns the downcasted uint40 from uint256, reverting on + * overflow (when the input is greater than largest uint40). + * + * Counterpart to Solidity's `uint40` operator. + * + * Requirements: + * + * - input must fit into 40 bits + * + * _Available since v4.7._ + */ + function toUint40(uint256 value) internal pure returns (uint40) { + require(value <= type(uint40).max, "SafeCast: value doesn't fit in 40 bits"); + return uint40(value); + } + + /** + * @dev Returns the downcasted uint32 from uint256, reverting on + * overflow (when the input is greater than largest uint32). + * + * Counterpart to Solidity's `uint32` operator. + * + * Requirements: + * + * - input must fit into 32 bits + * + * _Available since v2.5._ + */ + function toUint32(uint256 value) internal pure returns (uint32) { + require(value <= type(uint32).max, "SafeCast: value doesn't fit in 32 bits"); + return uint32(value); + } + + /** + * @dev Returns the downcasted uint24 from uint256, reverting on + * overflow (when the input is greater than largest uint24). + * + * Counterpart to Solidity's `uint24` operator. + * + * Requirements: + * + * - input must fit into 24 bits + * + * _Available since v4.7._ + */ + function toUint24(uint256 value) internal pure returns (uint24) { + require(value <= type(uint24).max, "SafeCast: value doesn't fit in 24 bits"); + return uint24(value); + } + + /** + * @dev Returns the downcasted uint16 from uint256, reverting on + * overflow (when the input is greater than largest uint16). + * + * Counterpart to Solidity's `uint16` operator. + * + * Requirements: + * + * - input must fit into 16 bits + * + * _Available since v2.5._ + */ + function toUint16(uint256 value) internal pure returns (uint16) { + require(value <= type(uint16).max, "SafeCast: value doesn't fit in 16 bits"); + return uint16(value); + } + + /** + * @dev Returns the downcasted uint8 from uint256, reverting on + * overflow (when the input is greater than largest uint8). + * + * Counterpart to Solidity's `uint8` operator. + * + * Requirements: + * + * - input must fit into 8 bits + * + * _Available since v2.5._ + */ + function toUint8(uint256 value) internal pure returns (uint8) { + require(value <= type(uint8).max, "SafeCast: value doesn't fit in 8 bits"); + return uint8(value); + } + + /** + * @dev Converts a signed int256 into an unsigned uint256. + * + * Requirements: + * + * - input must be greater than or equal to 0. + * + * _Available since v3.0._ + */ + function toUint256(int256 value) internal pure returns (uint256) { + require(value >= 0, "SafeCast: value must be positive"); + return uint256(value); + } + + /** + * @dev Returns the downcasted int248 from int256, reverting on + * overflow (when the input is less than smallest int248 or + * greater than largest int248). + * + * Counterpart to Solidity's `int248` operator. + * + * Requirements: + * + * - input must fit into 248 bits + * + * _Available since v4.7._ + */ + function toInt248(int256 value) internal pure returns (int248 downcasted) { + downcasted = int248(value); + require(downcasted == value, "SafeCast: value doesn't fit in 248 bits"); + } + + /** + * @dev Returns the downcasted int240 from int256, reverting on + * overflow (when the input is less than smallest int240 or + * greater than largest int240). + * + * Counterpart to Solidity's `int240` operator. + * + * Requirements: + * + * - input must fit into 240 bits + * + * _Available since v4.7._ + */ + function toInt240(int256 value) internal pure returns (int240 downcasted) { + downcasted = int240(value); + require(downcasted == value, "SafeCast: value doesn't fit in 240 bits"); + } + + /** + * @dev Returns the downcasted int232 from int256, reverting on + * overflow (when the input is less than smallest int232 or + * greater than largest int232). + * + * Counterpart to Solidity's `int232` operator. + * + * Requirements: + * + * - input must fit into 232 bits + * + * _Available since v4.7._ + */ + function toInt232(int256 value) internal pure returns (int232 downcasted) { + downcasted = int232(value); + require(downcasted == value, "SafeCast: value doesn't fit in 232 bits"); + } + + /** + * @dev Returns the downcasted int224 from int256, reverting on + * overflow (when the input is less than smallest int224 or + * greater than largest int224). + * + * Counterpart to Solidity's `int224` operator. + * + * Requirements: + * + * - input must fit into 224 bits + * + * _Available since v4.7._ + */ + function toInt224(int256 value) internal pure returns (int224 downcasted) { + downcasted = int224(value); + require(downcasted == value, "SafeCast: value doesn't fit in 224 bits"); + } + + /** + * @dev Returns the downcasted int216 from int256, reverting on + * overflow (when the input is less than smallest int216 or + * greater than largest int216). + * + * Counterpart to Solidity's `int216` operator. + * + * Requirements: + * + * - input must fit into 216 bits + * + * _Available since v4.7._ + */ + function toInt216(int256 value) internal pure returns (int216 downcasted) { + downcasted = int216(value); + require(downcasted == value, "SafeCast: value doesn't fit in 216 bits"); + } + + /** + * @dev Returns the downcasted int208 from int256, reverting on + * overflow (when the input is less than smallest int208 or + * greater than largest int208). + * + * Counterpart to Solidity's `int208` operator. + * + * Requirements: + * + * - input must fit into 208 bits + * + * _Available since v4.7._ + */ + function toInt208(int256 value) internal pure returns (int208 downcasted) { + downcasted = int208(value); + require(downcasted == value, "SafeCast: value doesn't fit in 208 bits"); + } + + /** + * @dev Returns the downcasted int200 from int256, reverting on + * overflow (when the input is less than smallest int200 or + * greater than largest int200). + * + * Counterpart to Solidity's `int200` operator. + * + * Requirements: + * + * - input must fit into 200 bits + * + * _Available since v4.7._ + */ + function toInt200(int256 value) internal pure returns (int200 downcasted) { + downcasted = int200(value); + require(downcasted == value, "SafeCast: value doesn't fit in 200 bits"); + } + + /** + * @dev Returns the downcasted int192 from int256, reverting on + * overflow (when the input is less than smallest int192 or + * greater than largest int192). + * + * Counterpart to Solidity's `int192` operator. + * + * Requirements: + * + * - input must fit into 192 bits + * + * _Available since v4.7._ + */ + function toInt192(int256 value) internal pure returns (int192 downcasted) { + downcasted = int192(value); + require(downcasted == value, "SafeCast: value doesn't fit in 192 bits"); + } + + /** + * @dev Returns the downcasted int184 from int256, reverting on + * overflow (when the input is less than smallest int184 or + * greater than largest int184). + * + * Counterpart to Solidity's `int184` operator. + * + * Requirements: + * + * - input must fit into 184 bits + * + * _Available since v4.7._ + */ + function toInt184(int256 value) internal pure returns (int184 downcasted) { + downcasted = int184(value); + require(downcasted == value, "SafeCast: value doesn't fit in 184 bits"); + } + + /** + * @dev Returns the downcasted int176 from int256, reverting on + * overflow (when the input is less than smallest int176 or + * greater than largest int176). + * + * Counterpart to Solidity's `int176` operator. + * + * Requirements: + * + * - input must fit into 176 bits + * + * _Available since v4.7._ + */ + function toInt176(int256 value) internal pure returns (int176 downcasted) { + downcasted = int176(value); + require(downcasted == value, "SafeCast: value doesn't fit in 176 bits"); + } + + /** + * @dev Returns the downcasted int168 from int256, reverting on + * overflow (when the input is less than smallest int168 or + * greater than largest int168). + * + * Counterpart to Solidity's `int168` operator. + * + * Requirements: + * + * - input must fit into 168 bits + * + * _Available since v4.7._ + */ + function toInt168(int256 value) internal pure returns (int168 downcasted) { + downcasted = int168(value); + require(downcasted == value, "SafeCast: value doesn't fit in 168 bits"); + } + + /** + * @dev Returns the downcasted int160 from int256, reverting on + * overflow (when the input is less than smallest int160 or + * greater than largest int160). + * + * Counterpart to Solidity's `int160` operator. + * + * Requirements: + * + * - input must fit into 160 bits + * + * _Available since v4.7._ + */ + function toInt160(int256 value) internal pure returns (int160 downcasted) { + downcasted = int160(value); + require(downcasted == value, "SafeCast: value doesn't fit in 160 bits"); + } + + /** + * @dev Returns the downcasted int152 from int256, reverting on + * overflow (when the input is less than smallest int152 or + * greater than largest int152). + * + * Counterpart to Solidity's `int152` operator. + * + * Requirements: + * + * - input must fit into 152 bits + * + * _Available since v4.7._ + */ + function toInt152(int256 value) internal pure returns (int152 downcasted) { + downcasted = int152(value); + require(downcasted == value, "SafeCast: value doesn't fit in 152 bits"); + } + + /** + * @dev Returns the downcasted int144 from int256, reverting on + * overflow (when the input is less than smallest int144 or + * greater than largest int144). + * + * Counterpart to Solidity's `int144` operator. + * + * Requirements: + * + * - input must fit into 144 bits + * + * _Available since v4.7._ + */ + function toInt144(int256 value) internal pure returns (int144 downcasted) { + downcasted = int144(value); + require(downcasted == value, "SafeCast: value doesn't fit in 144 bits"); + } + + /** + * @dev Returns the downcasted int136 from int256, reverting on + * overflow (when the input is less than smallest int136 or + * greater than largest int136). + * + * Counterpart to Solidity's `int136` operator. + * + * Requirements: + * + * - input must fit into 136 bits + * + * _Available since v4.7._ + */ + function toInt136(int256 value) internal pure returns (int136 downcasted) { + downcasted = int136(value); + require(downcasted == value, "SafeCast: value doesn't fit in 136 bits"); + } + + /** + * @dev Returns the downcasted int128 from int256, reverting on + * overflow (when the input is less than smallest int128 or + * greater than largest int128). + * + * Counterpart to Solidity's `int128` operator. + * + * Requirements: + * + * - input must fit into 128 bits + * + * _Available since v3.1._ + */ + function toInt128(int256 value) internal pure returns (int128 downcasted) { + downcasted = int128(value); + require(downcasted == value, "SafeCast: value doesn't fit in 128 bits"); + } + + /** + * @dev Returns the downcasted int120 from int256, reverting on + * overflow (when the input is less than smallest int120 or + * greater than largest int120). + * + * Counterpart to Solidity's `int120` operator. + * + * Requirements: + * + * - input must fit into 120 bits + * + * _Available since v4.7._ + */ + function toInt120(int256 value) internal pure returns (int120 downcasted) { + downcasted = int120(value); + require(downcasted == value, "SafeCast: value doesn't fit in 120 bits"); + } + + /** + * @dev Returns the downcasted int112 from int256, reverting on + * overflow (when the input is less than smallest int112 or + * greater than largest int112). + * + * Counterpart to Solidity's `int112` operator. + * + * Requirements: + * + * - input must fit into 112 bits + * + * _Available since v4.7._ + */ + function toInt112(int256 value) internal pure returns (int112 downcasted) { + downcasted = int112(value); + require(downcasted == value, "SafeCast: value doesn't fit in 112 bits"); + } + + /** + * @dev Returns the downcasted int104 from int256, reverting on + * overflow (when the input is less than smallest int104 or + * greater than largest int104). + * + * Counterpart to Solidity's `int104` operator. + * + * Requirements: + * + * - input must fit into 104 bits + * + * _Available since v4.7._ + */ + function toInt104(int256 value) internal pure returns (int104 downcasted) { + downcasted = int104(value); + require(downcasted == value, "SafeCast: value doesn't fit in 104 bits"); + } + + /** + * @dev Returns the downcasted int96 from int256, reverting on + * overflow (when the input is less than smallest int96 or + * greater than largest int96). + * + * Counterpart to Solidity's `int96` operator. + * + * Requirements: + * + * - input must fit into 96 bits + * + * _Available since v4.7._ + */ + function toInt96(int256 value) internal pure returns (int96 downcasted) { + downcasted = int96(value); + require(downcasted == value, "SafeCast: value doesn't fit in 96 bits"); + } + + /** + * @dev Returns the downcasted int88 from int256, reverting on + * overflow (when the input is less than smallest int88 or + * greater than largest int88). + * + * Counterpart to Solidity's `int88` operator. + * + * Requirements: + * + * - input must fit into 88 bits + * + * _Available since v4.7._ + */ + function toInt88(int256 value) internal pure returns (int88 downcasted) { + downcasted = int88(value); + require(downcasted == value, "SafeCast: value doesn't fit in 88 bits"); + } + + /** + * @dev Returns the downcasted int80 from int256, reverting on + * overflow (when the input is less than smallest int80 or + * greater than largest int80). + * + * Counterpart to Solidity's `int80` operator. + * + * Requirements: + * + * - input must fit into 80 bits + * + * _Available since v4.7._ + */ + function toInt80(int256 value) internal pure returns (int80 downcasted) { + downcasted = int80(value); + require(downcasted == value, "SafeCast: value doesn't fit in 80 bits"); + } + + /** + * @dev Returns the downcasted int72 from int256, reverting on + * overflow (when the input is less than smallest int72 or + * greater than largest int72). + * + * Counterpart to Solidity's `int72` operator. + * + * Requirements: + * + * - input must fit into 72 bits + * + * _Available since v4.7._ + */ + function toInt72(int256 value) internal pure returns (int72 downcasted) { + downcasted = int72(value); + require(downcasted == value, "SafeCast: value doesn't fit in 72 bits"); + } + + /** + * @dev Returns the downcasted int64 from int256, reverting on + * overflow (when the input is less than smallest int64 or + * greater than largest int64). + * + * Counterpart to Solidity's `int64` operator. + * + * Requirements: + * + * - input must fit into 64 bits + * + * _Available since v3.1._ + */ + function toInt64(int256 value) internal pure returns (int64 downcasted) { + downcasted = int64(value); + require(downcasted == value, "SafeCast: value doesn't fit in 64 bits"); + } + + /** + * @dev Returns the downcasted int56 from int256, reverting on + * overflow (when the input is less than smallest int56 or + * greater than largest int56). + * + * Counterpart to Solidity's `int56` operator. + * + * Requirements: + * + * - input must fit into 56 bits + * + * _Available since v4.7._ + */ + function toInt56(int256 value) internal pure returns (int56 downcasted) { + downcasted = int56(value); + require(downcasted == value, "SafeCast: value doesn't fit in 56 bits"); + } + + /** + * @dev Returns the downcasted int48 from int256, reverting on + * overflow (when the input is less than smallest int48 or + * greater than largest int48). + * + * Counterpart to Solidity's `int48` operator. + * + * Requirements: + * + * - input must fit into 48 bits + * + * _Available since v4.7._ + */ + function toInt48(int256 value) internal pure returns (int48 downcasted) { + downcasted = int48(value); + require(downcasted == value, "SafeCast: value doesn't fit in 48 bits"); + } + + /** + * @dev Returns the downcasted int40 from int256, reverting on + * overflow (when the input is less than smallest int40 or + * greater than largest int40). + * + * Counterpart to Solidity's `int40` operator. + * + * Requirements: + * + * - input must fit into 40 bits + * + * _Available since v4.7._ + */ + function toInt40(int256 value) internal pure returns (int40 downcasted) { + downcasted = int40(value); + require(downcasted == value, "SafeCast: value doesn't fit in 40 bits"); + } + + /** + * @dev Returns the downcasted int32 from int256, reverting on + * overflow (when the input is less than smallest int32 or + * greater than largest int32). + * + * Counterpart to Solidity's `int32` operator. + * + * Requirements: + * + * - input must fit into 32 bits + * + * _Available since v3.1._ + */ + function toInt32(int256 value) internal pure returns (int32 downcasted) { + downcasted = int32(value); + require(downcasted == value, "SafeCast: value doesn't fit in 32 bits"); + } + + /** + * @dev Returns the downcasted int24 from int256, reverting on + * overflow (when the input is less than smallest int24 or + * greater than largest int24). + * + * Counterpart to Solidity's `int24` operator. + * + * Requirements: + * + * - input must fit into 24 bits + * + * _Available since v4.7._ + */ + function toInt24(int256 value) internal pure returns (int24 downcasted) { + downcasted = int24(value); + require(downcasted == value, "SafeCast: value doesn't fit in 24 bits"); + } + + /** + * @dev Returns the downcasted int16 from int256, reverting on + * overflow (when the input is less than smallest int16 or + * greater than largest int16). + * + * Counterpart to Solidity's `int16` operator. + * + * Requirements: + * + * - input must fit into 16 bits + * + * _Available since v3.1._ + */ + function toInt16(int256 value) internal pure returns (int16 downcasted) { + downcasted = int16(value); + require(downcasted == value, "SafeCast: value doesn't fit in 16 bits"); + } + + /** + * @dev Returns the downcasted int8 from int256, reverting on + * overflow (when the input is less than smallest int8 or + * greater than largest int8). + * + * Counterpart to Solidity's `int8` operator. + * + * Requirements: + * + * - input must fit into 8 bits + * + * _Available since v3.1._ + */ + function toInt8(int256 value) internal pure returns (int8 downcasted) { + downcasted = int8(value); + require(downcasted == value, "SafeCast: value doesn't fit in 8 bits"); + } + + /** + * @dev Converts an unsigned uint256 into a signed int256. + * + * Requirements: + * + * - input must be less than or equal to maxInt256. + * + * _Available since v3.0._ + */ + function toInt256(uint256 value) internal pure returns (int256) { + // Note: Unsafe cast below is okay because `type(int256).max` is guaranteed to be positive + require(value <= uint256(type(int256).max), "SafeCast: value doesn't fit in an int256"); + return int256(value); + } +} diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 3b27060d6cb..83b41edc908 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -61,8 +61,8 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"}],\"name\":\"SafeERC20FailedOperation\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"timelockEndBlock\",\"type\":\"uint64\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b506040516200651c3803806200651c8339810160408190526200003491620004a3565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc816200014b565b5050600b805461ffff80881661ffff1990921691909117909155841660a052506000805260086020527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c780546001600160a01b031916301790556200014181620001fd565b5050505062000641565b336001600160a01b03821603620001a55760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b805160098054602080850151604086015160e01c600160701b0263ffffffff60701b196001600160601b0390921662010000026001600160701b031990941661ffff9096169590951792909217919091169290921781556060830151805184936200026e92600a92910190620002ae565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051620002a39190620005b2565b60405180910390a150565b82805482825590600052602060002090600701600890048101928215620003525791602002820160005b838211156200031e57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302620002d8565b8015620003505782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200031e565b505b506200036092915062000364565b5090565b5b8082111562000360576000815560010162000365565b805161ffff811681146200038e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051608081016001600160401b0381118282101715620003ce57620003ce62000393565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620003ff57620003ff62000393565b604052919050565b600082601f8301126200041957600080fd5b815160206001600160401b0382111562000437576200043762000393565b8160051b62000448828201620003d4565b92835284810182019282810190878511156200046357600080fd5b83870192505b848310156200049857825163ffffffff81168114620004885760008081fd5b8252918301919083019062000469565b979650505050505050565b60008060008060808587031215620004ba57600080fd5b620004c5856200037b565b9350620004d5602086016200037b565b60408601519093506001600160a01b0381168114620004f357600080fd5b60608601519092506001600160401b03808211156200051157600080fd5b90860190608082890312156200052657600080fd5b62000530620003a9565b6200053b836200037b565b815260208301516001600160601b03811681146200055857600080fd5b602082015260408301516001600160e01b0319811681146200057957600080fd5b60408201526060830151828111156200059157600080fd5b6200059f8a82860162000407565b6060830152509598949750929550505050565b6020808252825161ffff1682820152828101516001600160601b03166040808401919091528301516001600160e01b031916606080840191909152830151608080840152805160a0840181905260009291820190839060c08601905b808310156200063657835163ffffffff1682529284019260019290920191908401906200060e565b509695505050505050565b60805160a051615e9c620006806000396000505060008181611174015281816124f101528181612bc801528181612cd0015261345e0152615e9c6000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063a9c9a918116100e3578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f14610704578063eb523d6c14610717578063f2fde38b1461072a57600080fd5b8063d7ae1d30146106cb578063e72f6e30146106de578063e82ad7d4146106f157600080fd5b8063b734c0f4116100c8578063b734c0f414610697578063badc3eb61461069f578063c3f909d4146106b657600080fd5b8063a9c9a9181461065e578063aab396bd1461067157600080fd5b80639f87fad71161013a578063a21a23e41161011f578063a21a23e414610623578063a47c76961461062b578063a4c0ed361461064b57600080fd5b80639f87fad7146105ef578063a1d4c8281461060257600080fd5b8063823597401161016b57806382359740146105b15780638456cb59146105c45780638da5cb5b146105cc57600080fd5b80637341c10c1461059657806379ba5097146105a957600080fd5b806341db4ca31161023f5780635ed6dfba116101f3578063674603d0116101cd578063674603d0146104b65780636a2215de1461054b5780636e3b33231461058357600080fd5b80635ed6dfba1461046957806366316d8d1461047c578063664199701461048f57600080fd5b80634b8832d3116102245780634b8832d31461041157806355fedefa146104245780635c975abb1461045257600080fd5b806341db4ca3146103dd578063461d2762146103fe57600080fd5b80631c02453911610296578063385de9ae1161027b578063385de9ae146103af5780633e871e4d146103c25780633f4ba83a146103d557600080fd5b80631c024539146103945780631ded3b361461039c57600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614960565b61073d565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f661032636600461499a565b61079c565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614a41565b6102f6610898565b6102f66103aa366004614a54565b610a1e565b6102f66103bd366004614ac9565b610a50565b6102f66103d0366004614ca5565b610b59565b6102f6610e9a565b6103f06103eb366004614d6e565b610eac565b60405190815260200161030f565b6103f061040c366004614d6e565b610f0c565b6102f661041f366004614df3565b610f18565b6103f0610432366004614960565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f6610477366004614e46565b611016565b6102f661048a366004614e46565b6111b8565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b6105236104c4366004614e74565b73ffffffffffffffffffffffffffffffffffffffff91909116600090815260046020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff928316602085015291169082015260600161030f565b61055e610559366004614ea2565b61128f565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f6610591366004614ebb565b61134e565b6102f66105a4366004614df3565b61162a565b6102f66117c0565b6102f66105bf366004614960565b6118e7565b6102f6611a36565b600654610100900473ffffffffffffffffffffffffffffffffffffffff1661055e565b6102f66105fd366004614df3565b611a46565b6106156106103660046150d4565b611e1b565b60405161030f9291906151bc565b61049d61220f565b61063e610639366004614960565b61239c565b60405161030f9190615236565b6102f66106593660046152be565b6124d1565b61055e61066c366004614ea2565b61271d565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976103f0565b6102f6612782565b6106a761293c565b60405161030f9392919061531a565b6106be612a15565b60405161030f919061536f565b6102f66106d9366004614df3565b612b2c565b6102f66106ec36600461540e565b612b8f565b6104596106ff366004614960565b612d4c565b6102f661071236600461542b565b612e9b565b6102f6610725366004614ea2565b612fc1565b6102f661073836600461540e565b61318c565b61074561319d565b61074e816131a5565b67ffffffffffffffff81166000908152600360205260409020546107999082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661321b565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600a54911a908110610801576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600060096001018260ff168154811061081c5761081c61546d565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610892576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107f8565b50505050565b6108a0613507565b60008080526010602052604080518082019091527f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb018054829082906108e49061549c565b80601f01602080910402602001604051908101604052809291908181526020018280546109109061549c565b801561095d5780601f106109325761010080835404028352916020019161095d565b820191906000526020600020905b81548152906001019060200180831161094057829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156109bf576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109df81600001518060200190518101906109da9190615505565b61358d565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a13916000919061562f565b60405180910390a150565b610a2661319d565b610a2f826131a5565b67ffffffffffffffff90911660009081526003602081905260409091200155565b610a58613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190610aad9061ffff1643615677565b67ffffffffffffffff169052600084815260106020526040902081518190610ad590826156d8565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90610b4c908590859085906157f2565b60405180910390a1505050565b610b61613507565b8151815181141580610b735750600881115b15610baa576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610cd6576000848281518110610bc957610bc961546d565b602002602001015190506000848381518110610be757610be761546d565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c52575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c89576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cc3576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b505080610ccf90615846565b9050610bad565b50600b54600090610ceb9061ffff1643615677565b60408051606081018252868152602080820187905267ffffffffffffffff841692820192909252865192935091600d91610d299183918901906147a0565b506020828101518051610d4292600185019201906147e7565b5060409190910151600290910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff90921691909117905560005b8451811015610e93577fbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e858281518110610dc457610dc461546d565b602002602001015160086000888581518110610de257610de261546d565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e2b57610e2b61546d565b602002602001015185604051610e7b949392919093845273ffffffffffffffffffffffffffffffffffffffff92831660208501529116604083015267ffffffffffffffff16606082015260800190565b60405180910390a1610e8c81615846565b9050610d88565b5050505050565b610ea2613507565b610eaa61366f565b565b600080610eb88361128f565b9050610f0083828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b91506136ec9050565b98975050505050505050565b600080610eb88361271d565b610f20613a41565b610f2982613a49565b610f31613b0f565b67ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146110125767ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b61101e61319d565b806bffffffffffffffffffffffff166000036110545750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff808316911610156110ae576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b30600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff1661587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806000808282829054906101000a90046bffffffffffffffffffffffff16611131919061587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061101282826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6111c0613a41565b806bffffffffffffffffffffffff16600003611208576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff80831691161015611262576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff1661587e565b6000805b600d5460ff8216101561131857600d805460ff83169081106112b7576112b761546d565b9060005260206000200154830361130857600e805460ff83169081106112df576112df61546d565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b611311816158aa565b9050611293565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b611356613a41565b60005b818110156116255760008383838181106113755761137561546d565b9050610160020180360381019061138c91906158c9565b905060008160e0015190506000826060015190506005600083815260200190815260200160002054836040516020016113c591906158e6565b6040516020818303038152906040528051906020012014611412576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611457576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af11580156114ca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114ee9190615a15565b5060a083015167ffffffffffffffff82166000908152600360205260408120600101805490919061152e9084906bffffffffffffffffffffffff1661587e565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff8086168452915291902080546001926009916115b59185916901000000000000000000900416615a37565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061161e90615846565b9050611359565b505050565b611632613a41565b61163b82613a49565b611643613b0f565b60095467ffffffffffffffff831660009081526003602052604090206002015461ffff90911690036116a1576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8616845290915290205460ff16156116e8575050565b73ffffffffffffffffffffffffffffffffffffffff8116600081815260046020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611009565b60075473ffffffffffffffffffffffffffffffffffffffff163314611841576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107f8565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118ef613a41565b6118f7613b0f565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611997576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107f8565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611a3e613507565b610eaa613cdf565b611a4e613a41565b611a5782613a49565b611a5f613b0f565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b07576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611b5c576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611bd757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611bac575b5050505050905060005b8151811015611d7f578373ffffffffffffffffffffffffffffffffffffffff16828281518110611c1357611c1361546d565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611d6f578160018351611c459190615a58565b81518110611c5557611c5561546d565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611c9857611c9861546d565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611d1257611d12615a6b565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611d7f565b611d7881615846565b9050611be1565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080611e26613a41565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611e8f576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e0830151600090815260056020526040902054611ef757600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615a9a565b60405180910390a2506000612204565b600560008460e0015181526020019081526020016000205483604051602001611f2091906158e6565b6040516020818303038152906040528051906020012014611f7b57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615a9a565b826101400151836080015163ffffffff16611f969190615acc565b64ffffffffff165a1015611fe457600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615a9a565b6000611ff9846080015163ffffffff16613d3a565b6120039088615aea565b90506000818786600001516120189190615b12565b6120229190615b12565b606086015167ffffffffffffffff166000908152600360205260409020549091506bffffffffffffffffffffffff90811690821611156120b057600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615a9a565b60405180910390a250600091506122049050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561211857600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615a9a565b5050600560008460e0015181526020019081526020016000206000905560006121508460e001518a8a87608001518860400151613ddc565b8051909150612160576001612163565b60005b9250600061219285606001518660a00151876040015188600001518c61218c8860200151613d3a565b8d613f58565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b8360200151898887600001516121df578e6121e1565b8f5b88604001516040516121f7959493929190615b37565b60405180910390a3519150505b965096945050505050565b6000612219613a41565b612221613b0f565b6002805460009061223b9067ffffffffffffffff16615b99565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156122b1578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261234c926002850192909101906147e7565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a08101919091526123d6826131a5565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156124b757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161248c575b505050505081526020016003820154815250509050919050565b6124d9613a41565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614612548576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612582576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061259082840184614960565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612609576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906126408385615b12565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff166126969190615b12565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126fd9190615677565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff168061277c576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107f8565b92915050565b61278a613507565b600f5467ffffffffffffffff164310156127d0576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600d548110156128f3576000600d60000182815481106127f5576127f561546d565b906000526020600020015490506000600d600101838154811061281a5761281a61546d565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556128ec81615846565b90506127d3565b50600d60006129028282614861565b612910600183016000614861565b5060020180547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000169055565b600f54600d80546040805160208084028201810190925282815267ffffffffffffffff909416936060938493919290919083018282801561299c57602002820191906000526020600020905b815481526020019060010190808311612988575b50505050509150600d600101805480602002602001604051908101604052809291908181526020018280548015612a0957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129de575b50505050509050909192565b6040805160808101825260008082526020820181905291810191909152606080820152604080516080810182526009805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff000000000000000000000000000000000000000000000000000000001683850152600a805485518184028101840190965280865293949293606086019392830182828015612b1e57602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ae15790505b505050505081525050905090565b612b34613a41565b612b3d82613a49565b612b45613b0f565b612b4e82612d4c565b15612b85576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611012828261321b565b612b9761319d565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612c24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c489190615bc0565b6000549091506bffffffffffffffffffffffff1681811115612ca0576040517fa99da30200000000000000000000000000000000000000000000000000000000815260048101829052602481018390526044016107f8565b81811015611625576000612cb48284615a58565b9050612cf773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613c52565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612dc457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d99575b5050505050905060005b8151811015612e9157600060046000848481518110612def57612def61546d565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612e8057506001949350505050565b50612e8a81615846565b9050612dce565b5060009392505050565b612ea3613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190612ef89061ffff1643615677565b67ffffffffffffffff16905260008052601060205280517f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb01908190612f3d90826156d8565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90612fb590600090859085906157f2565b60405180910390a15050565b612fc9613507565b6000818152601060205260408082208151808301909252805482908290612fef9061549c565b80601f016020809104026020016040519081016040528092919081815260200182805461301b9061549c565b80156130685780601f1061303d57610100808354040283529160200191613068565b820191906000526020600020905b81548152906001019060200180831161304b57829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156130ca576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6130d38261271d565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161312791600401614a41565b600060405180830381600087803b15801561314157600080fd5b505af1158015613155573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c79350612fb5925085919061562f565b613194613507565b610799816141a1565b610eaa613507565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610799576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156132fc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116132d1575b505050918352505060039190910154602090910152805190915060005b8260800151518110156133bd5760046000846080015183815181106133405761334061546d565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556133b681615846565b9050613319565b5067ffffffffffffffff8416600090815260036020526040812081815560018101829055906133ef6002830182614861565b5060006003919091018190558054829190819061341b9084906bffffffffffffffffffffffff1661587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506134a283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611e0d565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107f8565b805160098054602080850151604086015160e01c6e010000000000000000000000000000027fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff6bffffffffffffffffffffffff90921662010000027fffffffffffffffffffffffffffffffffffff000000000000000000000000000090941661ffff90961695909517929092179190911692909217815560608301518051849361363c92600a9291019061487f565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051610a13919061536f565b61367761429d565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b60006136f6613a41565b6136ff856131a5565b6137093386614309565b613713858361079c565b604080516101008101825233815267ffffffffffffffff8716600081815260036020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b16608088015294845290829052015460a084015263ffffffff861660c08401526009546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e880916137f29190600401615bd9565b610160604051808303816000875af1158015613812573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138369190615cc4565b9050604051806101600160405280600960000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff1681525060405160200161394591906158e6565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a081015161399f903390889061437d565b60e081015167ffffffffffffffff8716600081815260036020526040908190205460a0850151915192938c9390927ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec992613a2a926c0100000000000000000000000090910473ffffffffffffffffffffffffffffffffffffffff1691339132918e918e918e91615d97565b60405180910390a460e00151979650505050505050565b610eaa614458565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613ac0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611012576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760005260086020527f29d6d16866b6e23fcc7ae534ca080a7a6eca5e1882ac6bf4569628fa2ee46ea45473ffffffffffffffffffffffffffffffffffffffff1680613b785750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613bd990339060248101615e0f565b602060405180830381865afa158015613bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c1a9190615a15565b610799576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107f8565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526116259084906144c5565b613ce7614458565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586136c23390565b60006bffffffffffffffffffffffff821115613dd8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107f8565b5090565b604080516060808201835260008083526020830152918101919091526009546040516000916e010000000000000000000000000000900460e01b90613e2990899089908990602401615e3e565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613edb57600080fd5b5a611388811015613eeb57600080fd5b611388810390508760408204820311613f0357600080fd5b60008086516020880160008b8df193505a900391503d6084811115613f26575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613f788486615aea565b9050600081613f878886615b12565b613f919190615b12565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f1660009081526003909152928320805492975093945084939291613fe89185911661587e565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d9450909261403c9185911661587e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846140769190615b12565b33600090815260016020526040812080549091906140a39084906bffffffffffffffffffffffff16615b12565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926140ea91859116615b12565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161416e9185916901000000000000000000900416615a37565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603614220576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107f8565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff16610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107f8565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16611012576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143b79084906bffffffffffffffffffffffff16615b12565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261442d928492900416615a37565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60065460ff1615610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107f8565b60006144e773ffffffffffffffffffffffffffffffffffffffff84168361455b565b9050805160001415801561450c57508080602001905181019061450a9190615a15565b155b15611625576040517f5274afe700000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff841660048201526024016107f8565b606061459f838360006040518060400160405280601e81526020017f416464726573733a206c6f772d6c6576656c2063616c6c206661696c656400008152506145a6565b9392505050565b606082471015614638576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107f8565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516146619190615e73565b60006040518083038185875af1925050503d806000811461469e576040519150601f19603f3d011682016040523d82523d6000602084013e6146a3565b606091505b50915091506146b4878383876146c1565b925050505b949350505050565b606083156147575782516000036147505773ffffffffffffffffffffffffffffffffffffffff85163b614750576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107f8565b50816146b9565b6146b9838381511561476c5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107f89190614a41565b8280548282559060005260206000209081019282156147db579160200282015b828111156147db5782518255916020019190600101906147c0565b50613dd8929150614925565b8280548282559060005260206000209081019282156147db579160200282015b828111156147db57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614807565b50805460008255906000526020600020908101906107999190614925565b828054828255906000526020600020906007016008900481019282156147db5791602002820160005b838211156148ec57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026148a8565b801561491c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026148ec565b5050613dd89291505b5b80821115613dd85760008155600101614926565b67ffffffffffffffff8116811461079957600080fd5b803561495b8161493a565b919050565b60006020828403121561497257600080fd5b813561459f8161493a565b63ffffffff8116811461079957600080fd5b803561495b8161497d565b600080604083850312156149ad57600080fd5b82356149b88161493a565b915060208301356149c88161497d565b809150509250929050565b60005b838110156149ee5781810151838201526020016149d6565b50506000910152565b60008151808452614a0f8160208601602086016149d3565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061459f60208301846149f7565b60008060408385031215614a6757600080fd5b8235614a728161493a565b946020939093013593505050565b60008083601f840112614a9257600080fd5b50813567ffffffffffffffff811115614aaa57600080fd5b602083019150836020828501011115614ac257600080fd5b9250929050565b600080600060408486031215614ade57600080fd5b83359250602084013567ffffffffffffffff811115614afc57600080fd5b614b0886828701614a80565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614b6857614b68614b15565b60405290565b6040516080810167ffffffffffffffff81118282101715614b6857614b68614b15565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614bd857614bd8614b15565b604052919050565b600067ffffffffffffffff821115614bfa57614bfa614b15565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461079957600080fd5b803561495b81614c04565b600082601f830112614c4257600080fd5b81356020614c57614c5283614be0565b614b91565b82815260059290921b84018101918181019086841115614c7657600080fd5b8286015b84811015614c9a578035614c8d81614c04565b8352918301918301614c7a565b509695505050505050565b60008060408385031215614cb857600080fd5b823567ffffffffffffffff80821115614cd057600080fd5b818501915085601f830112614ce457600080fd5b81356020614cf4614c5283614be0565b82815260059290921b84018101918181019089841115614d1357600080fd5b948201945b83861015614d3157853582529482019490820190614d18565b96505086013592505080821115614d4757600080fd5b50614d5485828601614c31565b9150509250929050565b61ffff8116811461079957600080fd5b60008060008060008060a08789031215614d8757600080fd5b8635614d928161493a565b9550602087013567ffffffffffffffff811115614dae57600080fd5b614dba89828a01614a80565b9096509450506040870135614dce81614d5e565b92506060870135614dde8161497d565b80925050608087013590509295509295509295565b60008060408385031215614e0657600080fd5b8235614e118161493a565b915060208301356149c881614c04565b6bffffffffffffffffffffffff8116811461079957600080fd5b803561495b81614e21565b60008060408385031215614e5957600080fd5b8235614e6481614c04565b915060208301356149c881614e21565b60008060408385031215614e8757600080fd5b8235614e9281614c04565b915060208301356149c88161493a565b600060208284031215614eb457600080fd5b5035919050565b60008060208385031215614ece57600080fd5b823567ffffffffffffffff80821115614ee657600080fd5b818501915085601f830112614efa57600080fd5b813581811115614f0957600080fd5b86602061016083028501011115614f1f57600080fd5b60209290920196919550909350505050565b600082601f830112614f4257600080fd5b813567ffffffffffffffff811115614f5c57614f5c614b15565b614f8d60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614b91565b818152846020838601011115614fa257600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461079957600080fd5b803561495b81614fbf565b69ffffffffffffffffffff8116811461079957600080fd5b803561495b81614fdd565b6000610160828403121561501357600080fd5b61501b614b44565b905061502682614e3b565b815261503460208301614c26565b602082015261504560408301614c26565b604082015261505660608301614950565b60608201526150676080830161498f565b608082015261507860a08301614e3b565b60a082015261508960c08301614fd2565b60c082015260e082013560e08201526101006150a6818401614ff5565b908201526101206150b8838201614fd2565b908201526101406150ca838201614fd2565b9082015292915050565b60008060008060008061020087890312156150ee57600080fd5b863567ffffffffffffffff8082111561510657600080fd5b6151128a838b01614f31565b9750602089013591508082111561512857600080fd5b5061513589828a01614f31565b955050604087013561514681614e21565b9350606087013561515681614e21565b9250608087013561516681614c04565b91506151758860a08901615000565b90509295509295509295565b600781106151b8577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b604081016151ca8285615181565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561522b57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016151f9565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526152a860e08401826151e5565b905060a084015160c08401528091505092915050565b600080600080606085870312156152d457600080fd5b84356152df81614c04565b935060208501359250604085013567ffffffffffffffff81111561530257600080fd5b61530e87828801614a80565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561535b5784518352938301939183019160010161533f565b50508481036040860152610f0081876151e5565b6000602080835260a0830161ffff855116828501526bffffffffffffffffffffffff828601511660408501527fffffffff000000000000000000000000000000000000000000000000000000006040860151166060850152606085015160808086015281815180845260c0870191508483019350600092505b80831015614c9a57835163ffffffff1682529284019260019290920191908401906153e8565b60006020828403121561542057600080fd5b813561459f81614c04565b6000806020838503121561543e57600080fd5b823567ffffffffffffffff81111561545557600080fd5b61546185828601614a80565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c908216806154b057607f821691505b6020821081036154e9577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b805161495b81614e21565b805161495b8161497d565b6000602080838503121561551857600080fd5b825167ffffffffffffffff8082111561553057600080fd5b908401906080828703121561554457600080fd5b61554c614b6e565b825161555781614d5e565b81528284015161556681614e21565b8185015260408301517fffffffff000000000000000000000000000000000000000000000000000000008116811461559d57600080fd5b60408201526060830151828111156155b457600080fd5b80840193505086601f8401126155c957600080fd5b825191506155d9614c5283614be0565b82815260059290921b830184019184810190888411156155f857600080fd5b938501935b8385101561561f5784516156108161497d565b825293850193908501906155fd565b6060830152509695505050505050565b8281526040602082015260006146b960408301846149f7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561277c5761277c615648565b601f82111561162557600081815260208120601f850160051c810160208610156156b15750805b601f850160051c820191505b818110156156d0578281556001016156bd565b505050505050565b815167ffffffffffffffff8111156156f2576156f2614b15565b61570681615700845461549c565b8461568a565b602080601f83116001811461575957600084156157235750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b1785556156d0565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157a657888601518255948401946001909101908401615787565b50858210156157e257878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361587757615877615648565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158a3576158a3615648565b5092915050565b600060ff821660ff81036158c0576158c0615648565b60010192915050565b600061016082840312156158dc57600080fd5b61459f8383615000565b81516bffffffffffffffffffffffff16815261016081016020830151615924602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161594c604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060830151615968606084018267ffffffffffffffff169052565b506080830151615980608084018263ffffffff169052565b5060a08301516159a060a08401826bffffffffffffffffffffffff169052565b5060c08301516159b960c084018264ffffffffff169052565b5060e083015160e0830152610100808401516159e28285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b600060208284031215615a2757600080fd5b8151801515811461459f57600080fd5b67ffffffffffffffff8181168382160190808211156158a3576158a3615648565b8181038181111561277c5761277c615648565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016146b96040830184615181565b64ffffffffff8181168382160190808211156158a3576158a3615648565b6bffffffffffffffffffffffff818116838216028082169190828114615a0d57615a0d615648565b6bffffffffffffffffffffffff8181168382160190808211156158a3576158a3615648565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615b716040820185615181565b60a060608201526000615b8760a08301856149f7565b8281036080840152610f0081856149f7565b600067ffffffffffffffff808316818103615bb657615bb6615648565b6001019392505050565b600060208284031215615bd257600080fd5b5051919050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615c266101208501836149f7565b91506060850151615c43608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615c7560e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b805161495b81614c04565b805161495b8161493a565b805161495b81614fbf565b805161495b81614fdd565b60006101608284031215615cd757600080fd5b615cdf614b44565b615ce8836154ef565b8152615cf660208401615c98565b6020820152615d0760408401615c98565b6040820152615d1860608401615ca3565b6060820152615d29608084016154fa565b6080820152615d3a60a084016154ef565b60a0820152615d4b60c08401615cae565b60c082015260e083015160e0820152610100615d68818501615cb9565b90820152610120615d7a848201615cae565b90820152610140615d8c848201615cae565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615dd860e08301876149f7565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006146b960408301846149f7565b838152606060208201526000615e5760608301856149f7565b8281036040840152615e6981856149f7565b9695505050505050565b60008251615e858184602087016149d3565b919091019291505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"timelockEndBlock\",\"type\":\"uint64\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162006563380380620065638339810160408190526200003491620004a3565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc816200014b565b5050600b805461ffff80881661ffff1990921691909117909155841660a052506000805260086020527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c780546001600160a01b031916301790556200014181620001fd565b5050505062000641565b336001600160a01b03821603620001a55760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b805160098054602080850151604086015160e01c600160701b0263ffffffff60701b196001600160601b0390921662010000026001600160701b031990941661ffff9096169590951792909217919091169290921781556060830151805184936200026e92600a92910190620002ae565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051620002a39190620005b2565b60405180910390a150565b82805482825590600052602060002090600701600890048101928215620003525791602002820160005b838211156200031e57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302620002d8565b8015620003505782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200031e565b505b506200036092915062000364565b5090565b5b8082111562000360576000815560010162000365565b805161ffff811681146200038e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051608081016001600160401b0381118282101715620003ce57620003ce62000393565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620003ff57620003ff62000393565b604052919050565b600082601f8301126200041957600080fd5b815160206001600160401b0382111562000437576200043762000393565b8160051b62000448828201620003d4565b92835284810182019282810190878511156200046357600080fd5b83870192505b848310156200049857825163ffffffff81168114620004885760008081fd5b8252918301919083019062000469565b979650505050505050565b60008060008060808587031215620004ba57600080fd5b620004c5856200037b565b9350620004d5602086016200037b565b60408601519093506001600160a01b0381168114620004f357600080fd5b60608601519092506001600160401b03808211156200051157600080fd5b90860190608082890312156200052657600080fd5b62000530620003a9565b6200053b836200037b565b815260208301516001600160601b03811681146200055857600080fd5b602082015260408301516001600160e01b0319811681146200057957600080fd5b60408201526060830151828111156200059157600080fd5b6200059f8a82860162000407565b6060830152509598949750929550505050565b6020808252825161ffff1682820152828101516001600160601b03166040808401919091528301516001600160e01b031916606080840191909152830151608080840152805160a0840181905260009291820190839060c08601905b808310156200063657835163ffffffff1682529284019260019290920191908401906200060e565b509695505050505050565b60805160a051615ee3620006806000396000505060008181611174015281816124f101528181612bc801528181612cd0015261345e0152615ee36000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063a9c9a918116100e3578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f14610704578063eb523d6c14610717578063f2fde38b1461072a57600080fd5b8063d7ae1d30146106cb578063e72f6e30146106de578063e82ad7d4146106f157600080fd5b8063b734c0f4116100c8578063b734c0f414610697578063badc3eb61461069f578063c3f909d4146106b657600080fd5b8063a9c9a9181461065e578063aab396bd1461067157600080fd5b80639f87fad71161013a578063a21a23e41161011f578063a21a23e414610623578063a47c76961461062b578063a4c0ed361461064b57600080fd5b80639f87fad7146105ef578063a1d4c8281461060257600080fd5b8063823597401161016b57806382359740146105b15780638456cb59146105c45780638da5cb5b146105cc57600080fd5b80637341c10c1461059657806379ba5097146105a957600080fd5b806341db4ca31161023f5780635ed6dfba116101f3578063674603d0116101cd578063674603d0146104b65780636a2215de1461054b5780636e3b33231461058357600080fd5b80635ed6dfba1461046957806366316d8d1461047c578063664199701461048f57600080fd5b80634b8832d3116102245780634b8832d31461041157806355fedefa146104245780635c975abb1461045257600080fd5b806341db4ca3146103dd578063461d2762146103fe57600080fd5b80631c02453911610296578063385de9ae1161027b578063385de9ae146103af5780633e871e4d146103c25780633f4ba83a146103d557600080fd5b80631c024539146103945780631ded3b361461039c57600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f13660046149a0565b61073d565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046149e1565b61079c565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614a88565b6102f6610898565b6102f66103aa366004614a9b565b610a1e565b6102f66103bd366004614b10565b610a50565b6102f66103d0366004614cec565b610b59565b6102f6610e9a565b6103f06103eb366004614db5565b610eac565b60405190815260200161030f565b6103f061040c366004614db5565b610f0c565b6102f661041f366004614e3a565b610f18565b6103f06104323660046149a0565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f6610477366004614e8d565b611016565b6102f661048a366004614e8d565b6111b8565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b6105236104c4366004614ebb565b73ffffffffffffffffffffffffffffffffffffffff91909116600090815260046020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff928316602085015291169082015260600161030f565b61055e610559366004614ee9565b61128f565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f6610591366004614f02565b61134e565b6102f66105a4366004614e3a565b61162a565b6102f66117c0565b6102f66105bf3660046149a0565b6118e7565b6102f6611a36565b600654610100900473ffffffffffffffffffffffffffffffffffffffff1661055e565b6102f66105fd366004614e3a565b611a46565b61061561061036600461511b565b611e1b565b60405161030f929190615203565b61049d61220f565b61063e6106393660046149a0565b61239c565b60405161030f919061527d565b6102f6610659366004615305565b6124d1565b61055e61066c366004614ee9565b61271d565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976103f0565b6102f6612782565b6106a761293c565b60405161030f93929190615361565b6106be612a15565b60405161030f91906153b6565b6102f66106d9366004614e3a565b612b2c565b6102f66106ec366004615455565b612b8f565b6104596106ff3660046149a0565b612d4c565b6102f6610712366004615472565b612e9b565b6102f6610725366004614ee9565b612fc1565b6102f6610738366004615455565b61318c565b61074561319d565b61074e816131a5565b67ffffffffffffffff81166000908152600360205260409020546107999082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661321b565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600a54911a908110610801576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600060096001018260ff168154811061081c5761081c6154b4565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610892576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107f8565b50505050565b6108a0613507565b60008080526010602052604080518082019091527f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb018054829082906108e4906154e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610910906154e3565b801561095d5780601f106109325761010080835404028352916020019161095d565b820191906000526020600020905b81548152906001019060200180831161094057829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156109bf576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109df81600001518060200190518101906109da919061554c565b61358d565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a139160009190615676565b60405180910390a150565b610a2661319d565b610a2f826131a5565b67ffffffffffffffff90911660009081526003602081905260409091200155565b610a58613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190610aad9061ffff16436156be565b67ffffffffffffffff169052600084815260106020526040902081518190610ad5908261571f565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90610b4c90859085908590615839565b60405180910390a1505050565b610b61613507565b8151815181141580610b735750600881115b15610baa576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610cd6576000848281518110610bc957610bc96154b4565b602002602001015190506000848381518110610be757610be76154b4565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c52575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c89576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cc3576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b505080610ccf9061588d565b9050610bad565b50600b54600090610ceb9061ffff16436156be565b60408051606081018252868152602080820187905267ffffffffffffffff841692820192909252865192935091600d91610d299183918901906147e0565b506020828101518051610d429260018501920190614827565b5060409190910151600290910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff90921691909117905560005b8451811015610e93577fbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e858281518110610dc457610dc46154b4565b602002602001015160086000888581518110610de257610de26154b4565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e2b57610e2b6154b4565b602002602001015185604051610e7b949392919093845273ffffffffffffffffffffffffffffffffffffffff92831660208501529116604083015267ffffffffffffffff16606082015260800190565b60405180910390a1610e8c8161588d565b9050610d88565b5050505050565b610ea2613507565b610eaa61366f565b565b600080610eb88361128f565b9050610f0083828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b91506136ec9050565b98975050505050505050565b600080610eb88361271d565b610f20613a41565b610f2982613a49565b610f31613b0f565b67ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146110125767ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b61101e61319d565b806bffffffffffffffffffffffff166000036110545750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff808316911610156110ae576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b30600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff166158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806000808282829054906101000a90046bffffffffffffffffffffffff1661113191906158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061101282826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6111c0613a41565b806bffffffffffffffffffffffff16600003611208576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff80831691161015611262576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff166158c5565b6000805b600d5460ff8216101561131857600d805460ff83169081106112b7576112b76154b4565b9060005260206000200154830361130857600e805460ff83169081106112df576112df6154b4565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b611311816158f1565b9050611293565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b611356613a41565b60005b81811015611625576000838383818110611375576113756154b4565b9050610160020180360381019061138c9190615910565b905060008160e0015190506000826060015190506005600083815260200190815260200160002054836040516020016113c5919061592d565b6040516020818303038152906040528051906020012014611412576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611457576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af11580156114ca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114ee9190615a5c565b5060a083015167ffffffffffffffff82166000908152600360205260408120600101805490919061152e9084906bffffffffffffffffffffffff166158c5565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff8086168452915291902080546001926009916115b59185916901000000000000000000900416615a7e565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061161e9061588d565b9050611359565b505050565b611632613a41565b61163b82613a49565b611643613b0f565b60095467ffffffffffffffff831660009081526003602052604090206002015461ffff90911690036116a1576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8616845290915290205460ff16156116e8575050565b73ffffffffffffffffffffffffffffffffffffffff8116600081815260046020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611009565b60075473ffffffffffffffffffffffffffffffffffffffff163314611841576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107f8565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118ef613a41565b6118f7613b0f565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611997576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107f8565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611a3e613507565b610eaa613cdf565b611a4e613a41565b611a5782613a49565b611a5f613b0f565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b07576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611b5c576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611bd757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611bac575b5050505050905060005b8151811015611d7f578373ffffffffffffffffffffffffffffffffffffffff16828281518110611c1357611c136154b4565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611d6f578160018351611c459190615a9f565b81518110611c5557611c556154b4565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611c9857611c986154b4565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611d1257611d12615ab2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611d7f565b611d788161588d565b9050611be1565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080611e26613a41565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611e8f576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e0830151600090815260056020526040902054611ef757600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615ae1565b60405180910390a2506000612204565b600560008460e0015181526020019081526020016000205483604051602001611f20919061592d565b6040516020818303038152906040528051906020012014611f7b57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615ae1565b826101400151836080015163ffffffff16611f969190615b13565b64ffffffffff165a1015611fe457600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615ae1565b6000611ff9846080015163ffffffff16613d3a565b6120039088615b31565b90506000818786600001516120189190615b59565b6120229190615b59565b606086015167ffffffffffffffff166000908152600360205260409020549091506bffffffffffffffffffffffff90811690821611156120b057600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615ae1565b60405180910390a250600091506122049050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561211857600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615ae1565b5050600560008460e0015181526020019081526020016000206000905560006121508460e001518a8a87608001518860400151613ddc565b8051909150612160576001612163565b60005b9250600061219285606001518660a00151876040015188600001518c61218c8860200151613d3a565b8d613f58565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b8360200151898887600001516121df578e6121e1565b8f5b88604001516040516121f7959493929190615b7e565b60405180910390a3519150505b965096945050505050565b6000612219613a41565b612221613b0f565b6002805460009061223b9067ffffffffffffffff16615be0565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156122b1578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261234c92600285019290910190614827565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a08101919091526123d6826131a5565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156124b757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161248c575b505050505081526020016003820154815250509050919050565b6124d9613a41565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614612548576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612582576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612590828401846149a0565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612609576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906126408385615b59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff166126969190615b59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126fd91906156be565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff168061277c576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107f8565b92915050565b61278a613507565b600f5467ffffffffffffffff164310156127d0576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600d548110156128f3576000600d60000182815481106127f5576127f56154b4565b906000526020600020015490506000600d600101838154811061281a5761281a6154b4565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556128ec8161588d565b90506127d3565b50600d600061290282826148a1565b6129106001830160006148a1565b5060020180547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000169055565b600f54600d80546040805160208084028201810190925282815267ffffffffffffffff909416936060938493919290919083018282801561299c57602002820191906000526020600020905b815481526020019060010190808311612988575b50505050509150600d600101805480602002602001604051908101604052809291908181526020018280548015612a0957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129de575b50505050509050909192565b6040805160808101825260008082526020820181905291810191909152606080820152604080516080810182526009805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff000000000000000000000000000000000000000000000000000000001683850152600a805485518184028101840190965280865293949293606086019392830182828015612b1e57602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ae15790505b505050505081525050905090565b612b34613a41565b612b3d82613a49565b612b45613b0f565b612b4e82612d4c565b15612b85576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611012828261321b565b612b9761319d565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612c24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c489190615c07565b6000549091506bffffffffffffffffffffffff1681811115612ca0576040517fa99da30200000000000000000000000000000000000000000000000000000000815260048101829052602481018390526044016107f8565b81811015611625576000612cb48284615a9f565b9050612cf773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613c52565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612dc457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d99575b5050505050905060005b8151811015612e9157600060046000848481518110612def57612def6154b4565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612e8057506001949350505050565b50612e8a8161588d565b9050612dce565b5060009392505050565b612ea3613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190612ef89061ffff16436156be565b67ffffffffffffffff16905260008052601060205280517f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb01908190612f3d908261571f565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90612fb59060009085908590615839565b60405180910390a15050565b612fc9613507565b6000818152601060205260408082208151808301909252805482908290612fef906154e3565b80601f016020809104026020016040519081016040528092919081815260200182805461301b906154e3565b80156130685780601f1061303d57610100808354040283529160200191613068565b820191906000526020600020905b81548152906001019060200180831161304b57829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156130ca576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6130d38261271d565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161312791600401614a88565b600060405180830381600087803b15801561314157600080fd5b505af1158015613155573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c79350612fb59250859190615676565b613194613507565b610799816141a1565b610eaa613507565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610799576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156132fc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116132d1575b505050918352505060039190910154602090910152805190915060005b8260800151518110156133bd576004600084608001518381518110613340576133406154b4565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556133b68161588d565b9050613319565b5067ffffffffffffffff8416600090815260036020526040812081815560018101829055906133ef60028301826148a1565b5060006003919091018190558054829190819061341b9084906bffffffffffffffffffffffff166158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506134a283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611e0d565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107f8565b805160098054602080850151604086015160e01c6e010000000000000000000000000000027fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff6bffffffffffffffffffffffff90921662010000027fffffffffffffffffffffffffffffffffffff000000000000000000000000000090941661ffff90961695909517929092179190911692909217815560608301518051849361363c92600a929101906148bf565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051610a1391906153b6565b61367761429d565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b60006136f6613a41565b6136ff856131a5565b6137093386614309565b613713858361079c565b604080516101008101825233815267ffffffffffffffff8716600081815260036020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b16608088015294845290829052015460a084015263ffffffff861660c08401526009546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e880916137f29190600401615c20565b610160604051808303816000875af1158015613812573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138369190615d0b565b9050604051806101600160405280600960000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613945919061592d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a081015161399f903390889061437d565b60e081015167ffffffffffffffff8716600081815260036020526040908190205460a0850151915192938c9390927ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec992613a2a926c0100000000000000000000000090910473ffffffffffffffffffffffffffffffffffffffff1691339132918e918e918e91615dde565b60405180910390a460e00151979650505050505050565b610eaa614458565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613ac0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611012576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760005260086020527f29d6d16866b6e23fcc7ae534ca080a7a6eca5e1882ac6bf4569628fa2ee46ea45473ffffffffffffffffffffffffffffffffffffffff1680613b785750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613bd990339060248101615e56565b602060405180830381865afa158015613bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c1a9190615a5c565b610799576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107f8565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526116259084906144c5565b613ce7614458565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586136c23390565b60006bffffffffffffffffffffffff821115613dd8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107f8565b5090565b604080516060808201835260008083526020830152918101919091526009546040516000916e010000000000000000000000000000900460e01b90613e2990899089908990602401615e85565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613edb57600080fd5b5a611388811015613eeb57600080fd5b611388810390508760408204820311613f0357600080fd5b60008086516020880160008b8df193505a900391503d6084811115613f26575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613f788486615b31565b9050600081613f878886615b59565b613f919190615b59565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f1660009081526003909152928320805492975093945084939291613fe8918591166158c5565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d9450909261403c918591166158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846140769190615b59565b33600090815260016020526040812080549091906140a39084906bffffffffffffffffffffffff16615b59565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926140ea91859116615b59565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161416e9185916901000000000000000000900416615a7e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603614220576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107f8565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff16610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107f8565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16611012576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143b79084906bffffffffffffffffffffffff16615b59565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261442d928492900416615a7e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60065460ff1615610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107f8565b6000614527826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166145d19092919063ffffffff16565b80519091501561162557808060200190518101906145459190615a5c565b611625576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107f8565b60606145e084846000856145e8565b949350505050565b60608247101561467a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107f8565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516146a39190615eba565b60006040518083038185875af1925050503d80600081146146e0576040519150601f19603f3d011682016040523d82523d6000602084013e6146e5565b606091505b50915091506146f687838387614701565b979650505050505050565b606083156147975782516000036147905773ffffffffffffffffffffffffffffffffffffffff85163b614790576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107f8565b50816145e0565b6145e083838151156147ac5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107f89190614a88565b82805482825590600052602060002090810192821561481b579160200282015b8281111561481b578251825591602001919060010190614800565b50613dd8929150614965565b82805482825590600052602060002090810192821561481b579160200282015b8281111561481b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614847565b50805460008255906000526020600020908101906107999190614965565b8280548282559060005260206000209060070160089004810192821561481b5791602002820160005b8382111561492c57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026148e8565b801561495c5782816101000a81549063ffffffff021916905560040160208160030104928301926001030261492c565b5050613dd89291505b5b80821115613dd85760008155600101614966565b67ffffffffffffffff8116811461079957600080fd5b803561499b8161497a565b919050565b6000602082840312156149b257600080fd5b81356149bd8161497a565b9392505050565b63ffffffff8116811461079957600080fd5b803561499b816149c4565b600080604083850312156149f457600080fd5b82356149ff8161497a565b91506020830135614a0f816149c4565b809150509250929050565b60005b83811015614a35578181015183820152602001614a1d565b50506000910152565b60008151808452614a56816020860160208601614a1a565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006149bd6020830184614a3e565b60008060408385031215614aae57600080fd5b8235614ab98161497a565b946020939093013593505050565b60008083601f840112614ad957600080fd5b50813567ffffffffffffffff811115614af157600080fd5b602083019150836020828501011115614b0957600080fd5b9250929050565b600080600060408486031215614b2557600080fd5b83359250602084013567ffffffffffffffff811115614b4357600080fd5b614b4f86828701614ac7565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614baf57614baf614b5c565b60405290565b6040516080810167ffffffffffffffff81118282101715614baf57614baf614b5c565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614c1f57614c1f614b5c565b604052919050565b600067ffffffffffffffff821115614c4157614c41614b5c565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461079957600080fd5b803561499b81614c4b565b600082601f830112614c8957600080fd5b81356020614c9e614c9983614c27565b614bd8565b82815260059290921b84018101918181019086841115614cbd57600080fd5b8286015b84811015614ce1578035614cd481614c4b565b8352918301918301614cc1565b509695505050505050565b60008060408385031215614cff57600080fd5b823567ffffffffffffffff80821115614d1757600080fd5b818501915085601f830112614d2b57600080fd5b81356020614d3b614c9983614c27565b82815260059290921b84018101918181019089841115614d5a57600080fd5b948201945b83861015614d7857853582529482019490820190614d5f565b96505086013592505080821115614d8e57600080fd5b50614d9b85828601614c78565b9150509250929050565b61ffff8116811461079957600080fd5b60008060008060008060a08789031215614dce57600080fd5b8635614dd98161497a565b9550602087013567ffffffffffffffff811115614df557600080fd5b614e0189828a01614ac7565b9096509450506040870135614e1581614da5565b92506060870135614e25816149c4565b80925050608087013590509295509295509295565b60008060408385031215614e4d57600080fd5b8235614e588161497a565b91506020830135614a0f81614c4b565b6bffffffffffffffffffffffff8116811461079957600080fd5b803561499b81614e68565b60008060408385031215614ea057600080fd5b8235614eab81614c4b565b91506020830135614a0f81614e68565b60008060408385031215614ece57600080fd5b8235614ed981614c4b565b91506020830135614a0f8161497a565b600060208284031215614efb57600080fd5b5035919050565b60008060208385031215614f1557600080fd5b823567ffffffffffffffff80821115614f2d57600080fd5b818501915085601f830112614f4157600080fd5b813581811115614f5057600080fd5b86602061016083028501011115614f6657600080fd5b60209290920196919550909350505050565b600082601f830112614f8957600080fd5b813567ffffffffffffffff811115614fa357614fa3614b5c565b614fd460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614bd8565b818152846020838601011115614fe957600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461079957600080fd5b803561499b81615006565b69ffffffffffffffffffff8116811461079957600080fd5b803561499b81615024565b6000610160828403121561505a57600080fd5b615062614b8b565b905061506d82614e82565b815261507b60208301614c6d565b602082015261508c60408301614c6d565b604082015261509d60608301614990565b60608201526150ae608083016149d6565b60808201526150bf60a08301614e82565b60a08201526150d060c08301615019565b60c082015260e082013560e08201526101006150ed81840161503c565b908201526101206150ff838201615019565b90820152610140615111838201615019565b9082015292915050565b600080600080600080610200878903121561513557600080fd5b863567ffffffffffffffff8082111561514d57600080fd5b6151598a838b01614f78565b9750602089013591508082111561516f57600080fd5b5061517c89828a01614f78565b955050604087013561518d81614e68565b9350606087013561519d81614e68565b925060808701356151ad81614c4b565b91506151bc8860a08901615047565b90509295509295509295565b600781106151ff577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161521182856151c8565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561527257815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615240565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526152ef60e084018261522c565b905060a084015160c08401528091505092915050565b6000806000806060858703121561531b57600080fd5b843561532681614c4b565b935060208501359250604085013567ffffffffffffffff81111561534957600080fd5b61535587828801614ac7565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156153a257845183529383019391830191600101615386565b50508481036040860152610f00818761522c565b6000602080835260a0830161ffff855116828501526bffffffffffffffffffffffff828601511660408501527fffffffff000000000000000000000000000000000000000000000000000000006040860151166060850152606085015160808086015281815180845260c0870191508483019350600092505b80831015614ce157835163ffffffff16825292840192600192909201919084019061542f565b60006020828403121561546757600080fd5b81356149bd81614c4b565b6000806020838503121561548557600080fd5b823567ffffffffffffffff81111561549c57600080fd5b6154a885828601614ac7565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c908216806154f757607f821691505b602082108103615530577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b805161499b81614e68565b805161499b816149c4565b6000602080838503121561555f57600080fd5b825167ffffffffffffffff8082111561557757600080fd5b908401906080828703121561558b57600080fd5b615593614bb5565b825161559e81614da5565b8152828401516155ad81614e68565b8185015260408301517fffffffff00000000000000000000000000000000000000000000000000000000811681146155e457600080fd5b60408201526060830151828111156155fb57600080fd5b80840193505086601f84011261561057600080fd5b82519150615620614c9983614c27565b82815260059290921b8301840191848101908884111561563f57600080fd5b938501935b83851015615666578451615657816149c4565b82529385019390850190615644565b6060830152509695505050505050565b8281526040602082015260006145e06040830184614a3e565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561277c5761277c61568f565b601f82111561162557600081815260208120601f850160051c810160208610156156f85750805b601f850160051c820191505b8181101561571757828155600101615704565b505050505050565b815167ffffffffffffffff81111561573957615739614b5c565b61574d8161574784546154e3565b846156d1565b602080601f8311600181146157a0576000841561576a5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615717565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157ed578886015182559484019460019091019084016157ce565b508582101561582957878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036158be576158be61568f565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158ea576158ea61568f565b5092915050565b600060ff821660ff81036159075761590761568f565b60010192915050565b6000610160828403121561592357600080fd5b6149bd8383615047565b81516bffffffffffffffffffffffff1681526101608101602083015161596b602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615993604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159af606084018267ffffffffffffffff169052565b5060808301516159c7608084018263ffffffff169052565b5060a08301516159e760a08401826bffffffffffffffffffffffff169052565b5060c0830151615a0060c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a298285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b600060208284031215615a6e57600080fd5b815180151581146149bd57600080fd5b67ffffffffffffffff8181168382160190808211156158ea576158ea61568f565b8181038181111561277c5761277c61568f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016145e060408301846151c8565b64ffffffffff8181168382160190808211156158ea576158ea61568f565b6bffffffffffffffffffffffff818116838216028082169190828114615a5457615a5461568f565b6bffffffffffffffffffffffff8181168382160190808211156158ea576158ea61568f565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615bb860408201856151c8565b60a060608201526000615bce60a0830185614a3e565b8281036080840152610f008185614a3e565b600067ffffffffffffffff808316818103615bfd57615bfd61568f565b6001019392505050565b600060208284031215615c1957600080fd5b5051919050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615c6d610120850183614a3e565b91506060850151615c8a608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615cbc60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b805161499b81614c4b565b805161499b8161497a565b805161499b81615006565b805161499b81615024565b60006101608284031215615d1e57600080fd5b615d26614b8b565b615d2f83615536565b8152615d3d60208401615cdf565b6020820152615d4e60408401615cdf565b6040820152615d5f60608401615cea565b6060820152615d7060808401615541565b6080820152615d8160a08401615536565b60a0820152615d9260c08401615cf5565b60c082015260e083015160e0820152610100615daf818501615d00565b90820152610120615dc1848201615cf5565b90820152610140615dd3848201615cf5565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615e1f60e0830187614a3e565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006145e06040830184614a3e565b838152606060208201526000615e9e6060830185614a3e565b8281036040840152615eb08185614a3e565b9695505050505050565b60008251615ecc818460208701614a1a565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index afbdedfabb7..00878a14bbe 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -6,7 +6,7 @@ functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClien functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 525316bc1fab9f1d6d262ac9fc1087f66a8314de4dcc9684ba78a29e8014328f functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin d9eeb059cd99938094bfa15f86d33399c5e0a58d196294bc0ab5148463cc0391 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin c9de640eefd95cca557cc482a35f4bad477455665996c944d05fcbdd9207813b +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 7a0dcd5f5b9669fe462afe599438bc211119596aca0fb001b1b46b1aa218f5fa ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From a967b16cd83593a16d5b6b346cf37bb9031b15c9 Mon Sep 17 00:00:00 2001 From: Tate Date: Fri, 4 Aug 2023 15:40:55 -0600 Subject: [PATCH 090/270] [TT-498][TT-484] Update push-gha-metrics action (#10087) --- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 +++--- .github/workflows/build-publish-develop.yml | 2 +- .github/workflows/build-publish.yml | 2 +- .github/workflows/build.yml | 2 +- .github/workflows/changelog.yml | 2 +- .github/workflows/ci-core.yml | 12 +++++------ .github/workflows/codeql-analysis.yml | 2 +- .github/workflows/dependency-check.yml | 2 +- .../goreleaser-build-publish-develop.yml | 2 +- .github/workflows/integration-chaos-tests.yml | 6 +++--- .../workflows/integration-tests-publish.yml | 2 +- .github/workflows/integration-tests.yml | 20 +++++++++---------- .github/workflows/lint-gh-workflows.yml | 2 +- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/operator-ui.yml | 2 +- .github/workflows/performance-tests.yml | 4 ++-- .github/workflows/readme.yml | 2 +- .github/workflows/sigscanner.yml | 2 +- .github/workflows/solidity-foundry.yml | 2 +- .github/workflows/solidity.yml | 16 +++++++-------- ...evelop-from-smartcontractkit-chainlink.yml | 2 +- 22 files changed, 48 insertions(+), 48 deletions(-) diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index ca0cc67f19d..befb5f510c2 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -128,7 +128,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index 07243d93e3b..2e0099e3da7 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -36,7 +36,7 @@ jobs: - name: Collect Metrics if: inputs.chainlinkImage == '' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -81,7 +81,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -192,7 +192,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish-develop.yml b/.github/workflows/build-publish-develop.yml index e8def971629..11e33ae4320 100644 --- a/.github/workflows/build-publish-develop.yml +++ b/.github/workflows/build-publish-develop.yml @@ -40,7 +40,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish.yml b/.github/workflows/build-publish.yml index ddc2bb55449..bd4f4d89097 100644 --- a/.github/workflows/build-publish.yml +++ b/.github/workflows/build-publish.yml @@ -50,7 +50,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 29c474c764f..ac62f874a9f 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,7 +22,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index f3b0c507340..c2f1d00eb31 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index af87a65abfc..c7808900cc3 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -95,7 +95,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -124,7 +124,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -201,7 +201,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -228,7 +228,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -321,7 +321,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -353,7 +353,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 09a9b3235cb..1e8afb01553 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -48,7 +48,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/dependency-check.yml b/.github/workflows/dependency-check.yml index 4a88007fa6a..4236ad812f4 100644 --- a/.github/workflows/dependency-check.yml +++ b/.github/workflows/dependency-check.yml @@ -47,7 +47,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/goreleaser-build-publish-develop.yml b/.github/workflows/goreleaser-build-publish-develop.yml index 80f360afd5b..092b83cd80a 100644 --- a/.github/workflows/goreleaser-build-publish-develop.yml +++ b/.github/workflows/goreleaser-build-publish-develop.yml @@ -39,7 +39,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index 5b84bbd28f0..6787c18175a 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -53,7 +53,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -99,7 +99,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests-publish.yml b/.github/workflows/integration-tests-publish.yml index d38ffa6f5fa..59bb167e0d6 100644 --- a/.github/workflows/integration-tests-publish.yml +++ b/.github/workflows/integration-tests-publish.yml @@ -20,7 +20,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index de5f97c0681..5657955c620 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -72,7 +72,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -119,7 +119,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -251,7 +251,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -272,7 +272,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -340,7 +340,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -446,7 +446,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -485,7 +485,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -539,7 +539,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -684,7 +684,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/lint-gh-workflows.yml b/.github/workflows/lint-gh-workflows.yml index 02530227eb2..08bf24d7e4f 100644 --- a/.github/workflows/lint-gh-workflows.yml +++ b/.github/workflows/lint-gh-workflows.yml @@ -13,7 +13,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 30810faca04..368d7071284 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -77,7 +77,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/operator-ui.yml b/.github/workflows/operator-ui.yml index 0ba6dc3cb79..c56c9351717 100644 --- a/.github/workflows/operator-ui.yml +++ b/.github/workflows/operator-ui.yml @@ -33,7 +33,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 0cd5f7cfc08..37d3dc7de87 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/readme.yml b/.github/workflows/readme.yml index 06877afd308..ff452de278e 100644 --- a/.github/workflows/readme.yml +++ b/.github/workflows/readme.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sigscanner.yml b/.github/workflows/sigscanner.yml index 9e07d71acd1..d912d1cae56 100644 --- a/.github/workflows/sigscanner.yml +++ b/.github/workflows/sigscanner.yml @@ -26,7 +26,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index 5f9022a7f94..a18e7d2c2c6 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -70,7 +70,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity.yml b/.github/workflows/solidity.yml index 4f93b933401..56785df1193 100644 --- a/.github/workflows/solidity.yml +++ b/.github/workflows/solidity.yml @@ -43,7 +43,7 @@ jobs: config: ./contracts/ci.json - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -91,7 +91,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -153,7 +153,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -178,7 +178,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -202,7 +202,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -249,7 +249,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -275,7 +275,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -301,7 +301,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml index 37b2b4c6986..264f473ea0a 100644 --- a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml +++ b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml @@ -30,7 +30,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@9d03d67aca5cab68f3c8565ee9fde236593bef3f + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} From 85858e5a147a44576ab40fe9b5e0e5af093e10eb Mon Sep 17 00:00:00 2001 From: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Date: Fri, 4 Aug 2023 16:41:44 -0500 Subject: [PATCH 091/270] S4 uses prefixed signed Eth messages (#10088) --- core/services/s4/envelope.go | 12 ++----- core/utils/eth_signatures.go | 47 +++++++++++++++++++++++++++ core/utils/eth_signatures_test.go | 53 +++++++++++++++++++++++++++++++ 3 files changed, 103 insertions(+), 9 deletions(-) create mode 100644 core/utils/eth_signatures.go create mode 100644 core/utils/eth_signatures_test.go diff --git a/core/services/s4/envelope.go b/core/services/s4/envelope.go index 12435ecd8c5..07e4201341c 100644 --- a/core/services/s4/envelope.go +++ b/core/services/s4/envelope.go @@ -6,7 +6,7 @@ import ( "fmt" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/crypto" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) // Envelope represents a JSON object that is signed for address verification. @@ -42,8 +42,7 @@ func (e Envelope) Sign(privateKey *ecdsa.PrivateKey) (signature []byte, err erro if err != nil { return nil, err } - hash := crypto.Keccak256Hash(js) - return crypto.Sign(hash[:], privateKey) + return utils.GenerateEthSignature(privateKey, js) } // GetSignerAddress verifies the signature and returns the signing address. @@ -55,12 +54,7 @@ func (e Envelope) GetSignerAddress(signature []byte) (address common.Address, er if err != nil { return common.Address{}, err } - hash := crypto.Keccak256Hash(js) - sigPublicKey, err := crypto.SigToPub(hash[:], signature) - if err != nil { - return common.Address{}, err - } - return crypto.PubkeyToAddress(*sigPublicKey), nil + return utils.GetSignersEthAddress(js, signature) } func (e Envelope) ToJson() ([]byte, error) { diff --git a/core/utils/eth_signatures.go b/core/utils/eth_signatures.go new file mode 100644 index 00000000000..688d67108a6 --- /dev/null +++ b/core/utils/eth_signatures.go @@ -0,0 +1,47 @@ +package utils + +import ( + "crypto/ecdsa" + "fmt" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" + "github.com/pkg/errors" +) + +const EthSignedMessagePrefix = "\x19Ethereum Signed Message:\n" + +func GetSignersEthAddress(msg []byte, sig []byte) (recoveredAddr common.Address, err error) { + if len(sig) != 65 { + return recoveredAddr, errors.New("invalid signature: signature length must be 65 bytes") + } + + // Adjust the V component of the signature in case it uses 27 or 28 instead of 0 or 1 + if sig[64] == 27 || sig[64] == 28 { + sig[64] -= 27 + } + if sig[64] != 0 && sig[64] != 1 { + return recoveredAddr, errors.New("invalid signature: invalid V component") + } + + prefixedMsg := fmt.Sprintf("%s%d%s", EthSignedMessagePrefix, len(msg), msg) + hash := crypto.Keccak256Hash([]byte(prefixedMsg)) + + sigPublicKey, err := crypto.SigToPub(hash[:], sig) + if err != nil { + return recoveredAddr, err + } + + recoveredAddr = crypto.PubkeyToAddress(*sigPublicKey) + return recoveredAddr, nil +} + +func GenerateEthPrefixedMsgHash(msg []byte) (hash common.Hash) { + prefixedMsg := fmt.Sprintf("%s%d%s", EthSignedMessagePrefix, len(msg), msg) + return crypto.Keccak256Hash([]byte(prefixedMsg)) +} + +func GenerateEthSignature(privateKey *ecdsa.PrivateKey, msg []byte) (signature []byte, err error) { + hash := GenerateEthPrefixedMsgHash(msg) + return crypto.Sign(hash[:], privateKey) +} diff --git a/core/utils/eth_signatures_test.go b/core/utils/eth_signatures_test.go new file mode 100644 index 00000000000..85b94500d68 --- /dev/null +++ b/core/utils/eth_signatures_test.go @@ -0,0 +1,53 @@ +package utils + +import ( + "testing" + + "github.com/ethereum/go-ethereum/crypto" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" +) + +func TestGetSignersEthAddress_Success(t *testing.T) { + privateKey, err := crypto.GenerateKey() + require.NoError(t, err) + address := crypto.PubkeyToAddress(privateKey.PublicKey) + + msg := []byte("test message") + sig, err := GenerateEthSignature(privateKey, msg) + assert.NoError(t, err) + + recoveredAddress, err := GetSignersEthAddress(msg, sig) + assert.NoError(t, err) + assert.Equal(t, address, recoveredAddress) +} + +func TestGetSignersEthAddress_InvalidSignatureLength(t *testing.T) { + msg := []byte("test message") + sig := []byte("invalid signature length") + _, err := GetSignersEthAddress(msg, sig) + assert.EqualError(t, err, "invalid signature: signature length must be 65 bytes") +} + +func TestGenerateEthPrefixedMsgHash(t *testing.T) { + msg := []byte("test message") + expectedPrefix := "\x19Ethereum Signed Message:\n" + expectedHash := crypto.Keccak256Hash([]byte(expectedPrefix + "12" + string(msg))) + + hash := GenerateEthPrefixedMsgHash(msg) + assert.Equal(t, expectedHash, hash) +} + +func TestGenerateEthSignature(t *testing.T) { + privateKey, err := crypto.GenerateKey() + assert.NoError(t, err) + + msg := []byte("test message") + signature, err := GenerateEthSignature(privateKey, msg) + assert.NoError(t, err) + assert.Len(t, signature, 65) + + recoveredPub, err := crypto.SigToPub(GenerateEthPrefixedMsgHash(msg).Bytes(), signature) + assert.NoError(t, err) + assert.Equal(t, privateKey.PublicKey, *recoveredPub) +} From 2e1daa841f49302e40a77e23082e018bd4952e47 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Fri, 4 Aug 2023 20:03:24 -0400 Subject: [PATCH 092/270] (refactor): Remove Router's timelock in favor of external timelock (#10089) * (refactor): Remove Router's timelock in favor of external timelock * (test): Amend test variable name * Remove Config, getter, & setter from interfaces * (test): Fix test for Config moving out of interfaces * Go lint --- .../functions/dev/1_0_0/FunctionsBilling.sol | 74 +- .../dev/1_0_0/FunctionsCoordinator.sol | 6 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 181 ++--- .../src/v0.8/functions/dev/1_0_0/Routable.sol | 17 +- .../accessControl/TermsOfServiceAllowList.sol | 33 +- .../1_0_0/example/FunctionsClientExample.sol | 2 +- .../dev/1_0_0/interfaces/IConfigurable.sol | 9 - .../1_0_0/interfaces/IFunctionsBilling.sol | 42 +- .../dev/1_0_0/interfaces/IFunctionsClient.sol | 9 +- .../interfaces/IFunctionsCoordinator.sol | 17 +- .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 65 +- .../tests/1_0_0/FunctionsRouter.t.sol | 51 +- .../FunctionsCoordinatorTestHelper.sol | 3 +- .../shared/interfaces/ITypeAndVersion.sol | 2 +- .../functions/v1/FunctionsCoordinator.test.ts | 66 +- .../v0.8/functions/v1/FunctionsRouter.test.ts | 45 +- .../test/v0.8/functions/v1/GasGolf.test.ts | 2 +- .../test/v0.8/functions/v1/RouterBase.test.ts | 241 +------ .../v1/TermsOfServiceAllowList.test.ts | 35 + contracts/test/v0.8/functions/v1/utils.ts | 49 +- .../functions_allow_list.go | 446 ++++++++++++- .../functions_coordinator.go | 180 ++--- .../functions_router/functions_router.go | 631 ++---------------- ...rapper-dependency-versions-do-not-edit.txt | 6 +- .../v1/internal/testutils.go | 85 +-- 25 files changed, 884 insertions(+), 1413 deletions(-) delete mode 100644 contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 4a814d09e94..7058d470d12 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -32,8 +32,36 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // | Configuration state | // ================================================================ + struct Config { + // Maximum amount of gas that can be given to a request's client callback + uint32 maxCallbackGasLimit; + // How long before we consider the feed price to be stale + // and fallback to fallbackNativePerUnitLink. + uint32 feedStalenessSeconds; + // Represents the average gas execution cost before the fulfillment callback. + // This amount is always billed for every request + uint32 gasOverheadBeforeCallback; + // Represents the average gas execution cost after the fulfillment callback. + // This amount is always billed for every request + uint32 gasOverheadAfterCallback; + // How many seconds it takes before we consider a request to be timed out + uint32 requestTimeoutSeconds; + // Additional flat fee (in Juels of LINK) that will be split between Node Operators + // Max value is 2^80 - 1 == 1.2m LINK. + uint80 donFee; + // The highest support request data version supported by the node + // All lower versions should also be supported + uint16 maxSupportedRequestDataVersion; + // Percentage of gas price overestimation to account for changes in gas price between request and response + // Held as basis points (one hundredth of 1 percentage point) + uint256 fulfillmentGasPriceOverEstimationBP; + // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale + int256 fallbackNativePerUnitLink; + } + Config private s_config; - event ConfigChanged(Config config); + + event ConfigUpdated(Config config); error UnsupportedRequestDataVersion(); error InsufficientBalance(); @@ -50,7 +78,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ mapping(address transmitter => uint96 balanceJuelsLink) private s_withdrawableTokens; - // Pool together DON fees and disperse them on withdrawal + // Pool together collected DON fees + // Disperse them on withdrawal or change in OCR configuration uint96 internal s_feePool; AggregatorV3Interface private s_linkToNativeFeed; @@ -58,29 +87,33 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ // | Initialization | // ================================================================ - constructor(address router, bytes memory config, address linkToNativeFeed) Routable(router, config) { + constructor(address router, Config memory config, address linkToNativeFeed) Routable(router) { s_linkToNativeFeed = AggregatorV3Interface(linkToNativeFeed); + + updateConfig(config); } // ================================================================ // | Configuration | // ================================================================ - // @notice Sets the configuration of the Chainlink Functions billing registry - // @param config bytes of abi.encoded config data to set the following: - // See the content of the Config struct above - function _updateConfig(bytes memory config) internal override { - Config memory _config = abi.decode(config, (Config)); - if (_config.fallbackNativePerUnitLink <= 0) { - revert InvalidLinkWeiPrice(_config.fallbackNativePerUnitLink); - } - s_config = _config; - emit ConfigChanged(_config); + // @notice Gets the Chainlink Coordinator's billing configuration + // @return config + function getConfig() external view returns (Config memory) { + return s_config; } - // @inheritdoc IFunctionsBilling - function getConfig() external view override returns (Config memory) { - return s_config; + // @notice Sets the Chainlink Coordinator's billing configuration + // @param config - See the contents of the Config struct in IFunctionsBilling.Config for more information + function updateConfig(Config memory config) public { + _onlyOwner(); + + if (config.fallbackNativePerUnitLink <= 0) { + revert InvalidLinkWeiPrice(config.fallbackNativePerUnitLink); + } + + s_config = config; + emit ConfigUpdated(config); } // ================================================================ @@ -98,7 +131,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // @inheritdoc IFunctionsBilling function getAdminFee() public view override returns (uint96) { - return _getRouter().getConfig().adminFee; + return _getRouter().getAdminFee(); } // @inheritdoc IFunctionsBilling @@ -143,7 +176,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { subscriptionId: subscriptionId, client: msg.sender, callbackGasLimit: callbackGasLimit, - expectedGasPrice: gasPriceGwei, + expectedGasPriceGwei: gasPriceGwei, adminFee: adminFee }) ); @@ -198,7 +231,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint80 donFee = getDONFee(data, billing); uint96 estimatedCost = _calculateCostEstimate( billing.callbackGasLimit, - billing.expectedGasPrice, + billing.expectedGasPriceGwei, donFee, billing.adminFee ); @@ -306,7 +339,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ // @inheritdoc IFunctionsBilling - // @dev used by FunctionsRouter.sol during timeout of a request + // @dev Only callable by the Router + // @dev Used by FunctionsRouter.sol during timeout of a request function deleteCommitment(bytes32 requestId) external override onlyRouter returns (bool) { // Ensure that commitment exists if (s_requestCommitments[requestId] == bytes32(0)) { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 34cd8d2aac2..8096f0fc980 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -44,7 +44,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli constructor( address router, - bytes memory config, + Config memory config, address linkToNativeFeed ) OCR2Base(true) FunctionsBilling(router, config, linkToNativeFeed) {} @@ -133,11 +133,11 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli revert EmptyRequestData(); } - RequestBilling memory billing = IFunctionsBilling.RequestBilling({ + RequestBilling memory billing = RequestBilling({ subscriptionId: request.subscriptionId, client: request.requestingContract, callbackGasLimit: request.callbackGasLimit, - expectedGasPrice: tx.gasprice, + expectedGasPriceGwei: tx.gasprice, adminFee: request.adminFee }); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index ca2c8402c02..c1f0db466d8 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -5,7 +5,6 @@ import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsCoordinator} from "./interfaces/IFunctionsCoordinator.sol"; import {IAccessController} from "../../../shared/interfaces/IAccessController.sol"; -import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {FunctionsSubscriptions} from "./FunctionsSubscriptions.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; @@ -80,30 +79,23 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, // ================================================================ // | Configuration state | // ================================================================ - Config private s_config; - - event ConfigChanged(Config); - - error OnlyCallableByRoute(); - - // ================================================================ - // | Timelock state | - // ================================================================ - uint16 private immutable s_maximumTimelockBlocks; - uint16 private s_timelockBlocks; - - struct TimeLockProposal { - uint16 from; - uint16 to; - uint64 timelockEndBlock; + struct Config { + // Maximum number of consumers which can be added to a single subscription + // This bound ensures we are able to loop over all subscription consumers as needed, + // without exceeding gas limits. + // Should a user require more consumers, they can use multiple subscriptions. + uint16 maxConsumersPerSubscription; + // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network + uint96 adminFee; + // The function selector that is used when calling back to the Client contract + bytes4 handleOracleFulfillmentSelector; + // List of max callback gas limits used by flag with GAS_FLAG_INDEX + uint32[] maxCallbackGasLimits; } - TimeLockProposal private s_timelockProposal; + Config private s_config; - event TimeLockProposed(uint16 from, uint16 to); - event TimeLockUpdated(uint16 from, uint16 to); - error ProposedTimelockAboveMaximum(); - error TimelockInEffect(); + event ConfigUpdated(Config); // ================================================================ // | Proposal state | @@ -114,102 +106,49 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, struct ContractProposalSet { bytes32[] ids; address[] to; - uint64 timelockEndBlock; } ContractProposalSet private s_proposedContractSet; event ContractProposed( bytes32 proposedContractSetId, address proposedContractSetFromAddress, - address proposedContractSetToAddress, - uint64 timelockEndBlock + address proposedContractSetToAddress ); event ContractUpdated(bytes32 id, address from, address to); - struct ConfigProposal { - bytes to; - uint64 timelockEndBlock; - } - mapping(bytes32 id => ConfigProposal) private s_proposedConfig; - event ConfigProposed(bytes32 id, bytes toBytes); - event ConfigUpdated(bytes32 id, bytes toBytes); error InvalidProposal(); error IdentifierIsReserved(bytes32 id); + // ================================================================ + // | Initialization | + // ================================================================ + constructor( - uint16 timelockBlocks, - uint16 maximumTimelockBlocks, address linkToken, Config memory config ) FunctionsSubscriptions(linkToken) ConfirmedOwner(msg.sender) Pausable() { - // Set initial value for the number of blocks of the timelock - s_timelockBlocks = timelockBlocks; - // Set maximum number of blocks that the timelock can be - s_maximumTimelockBlocks = maximumTimelockBlocks; // Set the initial configuration for the Router s_route[ROUTER_ID] = address(this); - _updateConfig(config); - } - - // @inheritdoc IFunctionsRouter - function getAllowListId() external pure override returns (bytes32) { - return ALLOW_LIST_ID; + // Set the intial configuration + updateConfig(config); } // ================================================================ // | Configuration | // ================================================================ - // @inheritdoc IFunctionsRouter - function getConfig() external view override returns (Config memory) { + // @notice The identifier of the route to retrieve the address of the access control contract + // The access control contract controls which accounts can manage subscriptions + // @return id - bytes32 id that can be passed to the "getContractById" of the Router + function getConfig() external view returns (Config memory) { return s_config; } - // @inheritdoc IRouterBase - function proposeConfigUpdateSelf(bytes calldata config) external override onlyOwner { - s_proposedConfig[ROUTER_ID] = ConfigProposal({ - to: config, - timelockEndBlock: uint64(block.number + s_timelockBlocks) - }); - emit ConfigProposed({id: ROUTER_ID, toBytes: config}); - } - - // @inheritdoc IRouterBase - function updateConfigSelf() external override onlyOwner { - ConfigProposal memory proposal = s_proposedConfig[ROUTER_ID]; - if (block.number < proposal.timelockEndBlock) { - revert TimelockInEffect(); - } - _updateConfig(abi.decode(proposal.to, (Config))); - emit ConfigUpdated({id: ROUTER_ID, toBytes: proposal.to}); - } - - // @inheritdoc IRouterBase - function proposeConfigUpdate(bytes32 id, bytes calldata config) external override onlyOwner { - s_proposedConfig[id] = ConfigProposal({to: config, timelockEndBlock: uint64(block.number + s_timelockBlocks)}); - emit ConfigProposed({id: id, toBytes: config}); - } - - // @inheritdoc IRouterBase - function updateConfig(bytes32 id) external override onlyOwner { - ConfigProposal memory proposal = s_proposedConfig[id]; - - if (block.number < proposal.timelockEndBlock) { - revert TimelockInEffect(); - } - - IConfigurable(getContractById(id)).updateConfig(proposal.to); - - emit ConfigUpdated({id: id, toBytes: proposal.to}); - } - - // @notice Sets the configuration for FunctionsRouter specific state - // @param config bytes of config data to set the following: - // - adminFee: fee that will be paid to the Router owner for operating the network - function _updateConfig(Config memory config) internal { + // @notice The router configuration + function updateConfig(Config memory config) public onlyOwner { s_config = config; - emit ConfigChanged(config); + emit ConfigUpdated(config); } // @inheritdoc IFunctionsRouter @@ -224,6 +163,16 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, } } + // @inheritdoc IFunctionsRouter + function getAdminFee() external view override returns (uint96 adminFee) { + return s_config.adminFee; + } + + // @inheritdoc IFunctionsRouter + function getAllowListId() external pure override returns (bytes32) { + return ALLOW_LIST_ID; + } + // Used within FunctionsSubscriptions.sol function _getMaxConsumers() internal view override returns (uint16) { return s_config.maxConsumersPerSubscription; @@ -508,36 +457,6 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, revert RouteNotFound(id); } - // ================================================================ - // | Timelock | - // ================================================================ - - // removed in anticipation of using MCM - // TODO: fully remove - - // @inheritdoc IRouterBase - // function proposeTimelockBlocks(uint16 blocks) external override onlyOwner { - // if (s_timelockBlocks == blocks) { - // revert InvalidProposal(); - // } - // if (blocks > s_maximumTimelockBlocks) { - // revert ProposedTimelockAboveMaximum(); - // } - // s_timelockProposal = TimeLockProposal({ - // from: s_timelockBlocks, - // to: blocks, - // timelockEndBlock: uint64(block.number + s_timelockBlocks) - // }); - // } - - // @inheritdoc IRouterBase - // function updateTimelockBlocks() external override onlyOwner { - // if (block.number < s_timelockProposal.timelockEndBlock) { - // revert TimelockInEffect(); - // } - // s_timelockBlocks = s_timelockProposal.to; - // } - // ================================================================ // | Contract Proposal methods | // ================================================================ @@ -549,7 +468,6 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, override returns (uint256 timelockEndBlock, bytes32[] memory ids, address[] memory to) { - timelockEndBlock = s_proposedContractSet.timelockEndBlock; ids = s_proposedContractSet.ids; to = s_proposedContractSet.to; return (timelockEndBlock, ids, to); @@ -560,12 +478,13 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, bytes32[] memory proposedContractSetIds, address[] memory proposedContractSetAddresses ) external override onlyOwner { - // All arrays must be of equal length and not must not exceed the max length + // IDs and addresses arrays must be of equal length and must not exceed the max proposal length uint256 idsArrayLength = proposedContractSetIds.length; if (idsArrayLength != proposedContractSetAddresses.length || idsArrayLength > MAX_PROPOSAL_SET_LENGTH) { revert InvalidProposal(); } - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + + // NOTE: iterations of this loop will not exceed MAX_PROPOSAL_SET_LENGTH for (uint256 i = 0; i < idsArrayLength; ++i) { bytes32 id = proposedContractSetIds[i]; address proposedContract = proposedContractSetAddresses[i]; @@ -575,36 +494,26 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, ) { revert InvalidProposal(); } - // Reserved ids cannot be set + // Reserved IDs cannot be set if (id == ROUTER_ID) { revert IdentifierIsReserved(id); } } - uint64 timelockEndBlock = uint64(block.number + s_timelockBlocks); + s_proposedContractSet = ContractProposalSet({ids: proposedContractSetIds, to: proposedContractSetAddresses}); - s_proposedContractSet = ContractProposalSet({ - ids: proposedContractSetIds, - to: proposedContractSetAddresses, - timelockEndBlock: timelockEndBlock - }); - - // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH + // NOTE: iterations of this loop will not exceed MAX_PROPOSAL_SET_LENGTH for (uint256 i = 0; i < proposedContractSetIds.length; ++i) { emit ContractProposed({ proposedContractSetId: proposedContractSetIds[i], proposedContractSetFromAddress: s_route[proposedContractSetIds[i]], - proposedContractSetToAddress: proposedContractSetAddresses[i], - timelockEndBlock: timelockEndBlock + proposedContractSetToAddress: proposedContractSetAddresses[i] }); } } // @inheritdoc IRouterBase function updateContracts() external override onlyOwner { - if (block.number < s_proposedContractSet.timelockEndBlock) { - revert TimelockInEffect(); - } // Iterations will not exceed MAX_PROPOSAL_SET_LENGTH for (uint256 i = 0; i < s_proposedContractSet.ids.length; ++i) { bytes32 id = s_proposedContractSet.ids[i]; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index 57b875bb52d..61f96b247a6 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -1,15 +1,13 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IConfigurable} from "./interfaces/IConfigurable.sol"; import {ITypeAndVersion} from "../../../shared/interfaces/ITypeAndVersion.sol"; import {IOwnableFunctionsRouter} from "./interfaces/IOwnableFunctionsRouter.sol"; // @title This abstract should be inherited by contracts that will be used // as the destinations to a route (id=>contract) on the Router. // It provides a Router getter and modifiers -// and enforces that the Router can update the configuration of this contract -abstract contract Routable is ITypeAndVersion, IConfigurable { +abstract contract Routable is ITypeAndVersion { IOwnableFunctionsRouter private immutable i_router; error RouterMustBeSet(); @@ -17,28 +15,17 @@ abstract contract Routable is ITypeAndVersion, IConfigurable { error OnlyCallableByRouterOwner(); // @dev Initializes the contract. - constructor(address router, bytes memory config) { + constructor(address router) { if (router == address(0)) { revert RouterMustBeSet(); } i_router = IOwnableFunctionsRouter(router); - _updateConfig(config); } function _getRouter() internal view returns (IOwnableFunctionsRouter router) { return i_router; } - // @dev Must be implemented by inheriting contract - // Use to set configuration state - function _updateConfig(bytes memory config) internal virtual; - - // @inheritdoc IConfigurable - // @dev Only callable by the Router - function updateConfig(bytes memory config) public override onlyRouter { - _updateConfig(config); - } - // @notice Reverts if called by anyone other than the router. modifier onlyRouter() { if (msg.sender != address(i_router)) { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index e259a0d164d..0cd8b952212 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -6,6 +6,7 @@ import {IAccessController} from "../../../../shared/interfaces/IAccessController import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol"; import {Routable} from "../Routable.sol"; +import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; import {Address} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol"; import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; @@ -13,7 +14,7 @@ import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/con /** * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service */ -contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessController { +contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, Routable, ConfirmedOwner { using Address for address; using EnumerableSet for EnumerableSet.AddressSet; @@ -34,7 +35,6 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC // ================================================================ // | Configuration state | // ================================================================ - struct Config { bool enabled; address signerPublicKey; @@ -42,28 +42,31 @@ contract TermsOfServiceAllowList is Routable, ITermsOfServiceAllowList, IAccessC Config private s_config; - event ConfigSet(bool enabled, address signerPublicKey); + event ConfigUpdated(Config config); // ================================================================ // | Initialization | // ================================================================ - constructor(address router, bytes memory config) Routable(router, config) {} + constructor(address router, Config memory config) Routable(router) ConfirmedOwner(msg.sender) { + updateConfig(config); + } // ================================================================ - // | Configuration methods | + // | Configuration | // ================================================================ - /** - * @notice Sets the configuration - * @param config bytes of config data to set the following: - * - enabled: boolean representing if the allow list is active, when disabled all usage will be allowed - * - signerPublicKey: public key of the signer of the proof - */ - function _updateConfig(bytes memory config) internal override { - (bool enabled, address signerPublicKey) = abi.decode(config, (bool, address)); - s_config = Config({enabled: enabled, signerPublicKey: signerPublicKey}); - emit ConfigSet(enabled, signerPublicKey); + // @notice Gets the contracts's configuration + // @return config + function getConfig() external view returns (Config memory) { + return s_config; + } + + // @notice Sets the contracts's configuration + // @param config - See the contents of the TermsOfServiceAllowList.Config struct for more information + function updateConfig(Config memory config) public onlyOwner { + s_config = config; + emit ConfigUpdated(config); } // ================================================================ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol index e5a9a6e64f7..1eb50e9d31e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol @@ -6,7 +6,7 @@ import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; import {FunctionsRequest} from "../libraries/FunctionsRequest.sol"; /** - * @title Chainlink Functions example client contract implementation + * @title Chainlink Functions example Client contract implementation */ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { using FunctionsRequest for FunctionsRequest.Request; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol deleted file mode 100644 index 4023aa282dd..00000000000 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IConfigurable.sol +++ /dev/null @@ -1,9 +0,0 @@ -// SPDX-License-Identifier: MIT -pragma solidity ^0.8.19; - -// @title Configurable contract interface. -interface IConfigurable { - // @notice Set the contract's configuration - // @param config bytes containing config data - function updateConfig(bytes calldata config) external; -} diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index 3c401d0233e..a7aa7891193 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -12,41 +12,11 @@ interface IFunctionsBilling { // customer specified gas limit for the fulfillment callback uint32 callbackGasLimit; // the expected gas price used to execute the transaction - uint256 expectedGasPrice; + uint256 expectedGasPriceGwei; // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network uint96 adminFee; } - struct Config { - // Maximum amount of gas that can be given to a request's client callback - uint32 maxCallbackGasLimit; - // feedStalenessSeconds is how long before we consider the feed price to be stale - // and fallback to fallbackNativePerUnitLink. - uint32 feedStalenessSeconds; - // Represents the average gas execution cost. Used in estimating cost beforehand. - uint32 gasOverheadBeforeCallback; - // Gas to cover transmitter oracle payment after we calculate the payment. - // We make it configurable in case those operations are repriced. - uint32 gasOverheadAfterCallback; - // how many seconds it takes before we consider a request to be timed out - uint32 requestTimeoutSeconds; - // additional flat fee (in Juels of LINK) that will be split between Node Operators - // Max value is 2^80 - 1 == 1.2m LINK. - uint80 donFee; - // The highest support request data version supported by the node - // All lower versions should also be supported - uint16 maxSupportedRequestDataVersion; - // Percentage of gas price overestimation to account for changes in gas price between request and response - // Held as basis points (one hundredth of 1 percentage point) - uint256 fulfillmentGasPriceOverEstimationBP; - // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale - int256 fallbackNativePerUnitLink; - } - - // @notice Gets the configuration of the Chainlink Functions billing registry - // @return config - function getConfig() external view returns (Config memory); - // @notice Return the current conversion from WEI of ETH to LINK from the configured Chainlink data feed // @return weiPerUnitLink - The amount of WEI in one LINK function getWeiPerUnitLink() external view returns (uint256); @@ -61,31 +31,29 @@ interface IFunctionsBilling { // @return fee Cost in Juels (1e18) of LINK function getAdminFee() external view returns (uint96); - // @notice Estimate the total cost that will be charged to a subscription to make a request: gas re-reimbursement, plus DON fee, plus Registry fee + // @notice Estimate the total cost that will be charged to a subscription to make a request: transmitter gas re-reimbursement, plus DON fee, plus Registry fee // @param subscriptionId An identifier of the billing account // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request // @param callbackGasLimit Gas limit for the fulfillment callback - // @param gasPrice The blockchain's gas price to estimate with + // @param gasPriceGwei The blockchain's gas price to estimate with // @return billedCost Cost in Juels (1e18) of LINK function estimateCost( uint64 subscriptionId, bytes calldata data, uint32 callbackGasLimit, - uint256 gasPrice + uint256 gasPriceGwei ) external view returns (uint96); // @notice Remove a request commitment that the Router has determined to be stale - // @dev Only callable by the Router // @param requestId - The request ID to remove function deleteCommitment(bytes32 requestId) external returns (bool); // @notice Oracle withdraw LINK earned through fulfilling requests // @notice If amount is 0 the full balance will be withdrawn - // @notice Both signing and transmitting wallets will have a balance to withdraw // @param recipient where to send the funds // @param amount amount to withdraw function oracleWithdraw(address recipient, uint96 amount) external; - // @notice Oracle withdraw all LINK earned through fulfilling requests to all Node Operators + // @notice Withdraw all LINK earned by Oracles through fulfilling requests function oracleWithdrawAll() external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol index 0a66c259cab..5fbee58274e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsClient.sol @@ -3,10 +3,11 @@ pragma solidity ^0.8.19; // @title Chainlink Functions client interface. interface IFunctionsClient { - // @notice Chainlink Functions response handler called by the designated transmitter node in an OCR round. + // @notice Chainlink Functions response handler called by the Functions Router + // during fullilment from the designated transmitter node in an OCR round. // @param requestId The requestId returned by FunctionsClient.sendRequest(). - // @param response Aggregated response from the user code. - // @param err Aggregated error either from the user code or from the execution pipeline. - // Either response or error parameter will be set, but never both. + // @param response Aggregated response from the request's source code. + // @param err Aggregated error either from the request's source code or from the execution pipeline. + // @dev Either response or error parameter will be set, but never both. function handleOracleFulfillment(bytes32 requestId, bytes memory response, bytes memory err) external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 5bd915b9ef0..05a616e8b24 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -3,18 +3,17 @@ pragma solidity ^0.8.19; import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; -// @title Chainlink Functions oracle interface. - +// @title Chainlink Functions Coordinator interface. interface IFunctionsCoordinator { struct Request { address requestingContract; // The client contract that is sending the request - address subscriptionOwner; // The owner of the subscription - bytes data; // Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - uint64 subscriptionId; // Identifier of the subscription that will be charged for the request - uint16 dataVersion; // The version of the structure of the encoded data - bytes32 flags; // Per-subscription flags - uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract can utilize - uint96 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network + address subscriptionOwner; // The owner of the billing subscription + bytes data; // Encoded Chainlink Functions request data, use FunctionsRequest library to encode a request + uint64 subscriptionId; // Identifier of the billing subscription that will be charged for the request + uint16 dataVersion; // The version of the structure of the CBOR encoded request data + bytes32 flags; // Per-subscription account flags + uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract will be given + uint96 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router Owner for operation of the network } // @notice Returns the DON's threshold encryption public key used to encrypt secrets diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index c88dcd7e079..450f584b2d4 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -5,36 +5,23 @@ import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; // @title Chainlink Functions Router interface. interface IFunctionsRouter { - struct Config { - // Maximum number of consumers which can be added to a single subscription - // This bound ensures we are able to loop over all subscription consumers as needed, - // without exceeding gas limits. - // Should a user require more consumers, they can use multiple subscriptions. - uint16 maxConsumersPerSubscription; - // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network - uint96 adminFee; - // The function selector that is used when calling back to the Client contract - bytes4 handleOracleFulfillmentSelector; - // List of max callback gas limits used by flag with GAS_FLAG_INDEX - uint32[] maxCallbackGasLimits; - } - // @notice The identifier of the route to retrieve the address of the access control contract // The access control contract controls which accounts can manage subscriptions // @return id - bytes32 id that can be passed to the "getContractById" of the Router function getAllowListId() external pure returns (bytes32); - // @notice The router configuration - function getConfig() external view returns (Config memory); + // @notice Get the flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network + // @return adminFee + function getAdminFee() external view returns (uint96 adminFee); - // @notice Sends a request (encoded as data) using the provided subscriptionId - // @param subscriptionId A unique subscription ID allocated by billing system, + // @notice Sends a request using the provided subscriptionId + // @param subscriptionId - A unique subscription ID allocated by billing system, // a client can make requests from different contracts referencing the same subscription - // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - // @param dataVersion Gas limit for the fulfillment callback - // @param callbackGasLimit Gas limit for the fulfillment callback - // @param donId An identifier used to determine which route to send the request along - // @return requestId A unique request identifier + // @param data - CBOR encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param dataVersion - Gas limit for the fulfillment callback + // @param callbackGasLimit - Gas limit for the fulfillment callback + // @param donId - An identifier used to determine which route to send the request along + // @return requestId - A unique request identifier function sendRequest( uint64 subscriptionId, bytes calldata data, @@ -43,14 +30,14 @@ interface IFunctionsRouter { bytes32 donId ) external returns (bytes32); - // @notice Sends a request (encoded as data) to the proposed contracts - // @param subscriptionId A unique subscription ID allocated by billing system, + // @notice Sends a request to the proposed contracts + // @param subscriptionId - A unique subscription ID allocated by billing system, // a client can make requests from different contracts referencing the same subscription - // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - // @param dataVersion Gas limit for the fulfillment callback - // @param callbackGasLimit Gas limit for the fulfillment callback - // @param donId An identifier used to determine which route to send the request along - // @return requestId A unique request identifier + // @param data - CBOR encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param dataVersion - Gas limit for the fulfillment callback + // @param callbackGasLimit - Gas limit for the fulfillment callback + // @param donId - An identifier used to determine which route to send the request along + // @return requestId - A unique request identifier function sendRequestToProposed( uint64 subscriptionId, bytes calldata data, @@ -110,24 +97,6 @@ interface IFunctionsRouter { // @dev Only callable by owner function updateContracts() external; - // @notice Proposes new configuration data for the Router contract itself - // @dev Only callable by owner - function proposeConfigUpdateSelf(bytes calldata config) external; - - // @notice Updates configuration data for the Router contract itself - // @dev Only callable once timelock has passed - // @dev Only callable by owner - function updateConfigSelf() external; - - // @notice Proposes new configuration data for the current (not proposed) contract - // @dev Only callable by owner - function proposeConfigUpdate(bytes32 id, bytes calldata config) external; - - // @notice Sends new configuration data to the contract along a route route - // @dev Only callable once timelock has passed - // @dev Only callable by owner - function updateConfig(bytes32 id) external; - // @dev Puts the system into an emergency stopped state. // @dev Only callable by owner function pause() external; diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index edc29477caa..c6d2a46a3e9 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -3,6 +3,7 @@ pragma solidity ^0.8.0; import {IFunctionsRouter} from "../../dev/1_0_0/interfaces/IFunctionsRouter.sol"; import {IFunctionsBilling} from "../../dev/1_0_0/interfaces/IFunctionsBilling.sol"; +import {ITermsOfServiceAllowList} from "../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; import {BaseTest} from "./BaseTest.t.sol"; import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; @@ -17,8 +18,6 @@ contract FunctionsRouterSetup is BaseTest { MockV3Aggregator internal s_linkEthFeed; TermsOfServiceAllowList internal s_termsOfServiceAllowList; - uint16 internal s_timelockBlocks = 0; - uint16 internal s_maximumTimelockBlocks = 20; uint16 internal s_maxConsumersPerSubscription = 100; uint96 internal s_adminFee = 561724823; bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; @@ -29,18 +28,18 @@ contract FunctionsRouterSetup is BaseTest { function setUp() public virtual override { BaseTest.setUp(); - s_functionsRouter = new FunctionsRouter(s_timelockBlocks, s_maximumTimelockBlocks, s_linkToken, getRouterConfig()); + s_functionsRouter = new FunctionsRouter(s_linkToken, getRouterConfig()); s_linkEthFeed = new MockV3Aggregator(0, LINK_ETH_RATE); s_termsOfServiceAllowList = new TermsOfServiceAllowList(address(s_functionsRouter), getTermsOfServiceConfig()); } - function getRouterConfig() public view returns (IFunctionsRouter.Config memory) { + function getRouterConfig() public view returns (FunctionsRouter.Config memory) { uint32[] memory maxCallbackGasLimits = new uint32[](1); maxCallbackGasLimits[0] = type(uint32).max; return - IFunctionsRouter.Config({ + FunctionsRouter.Config({ maxConsumersPerSubscription: s_maxConsumersPerSubscription, adminFee: s_adminFee, handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, @@ -48,37 +47,23 @@ contract FunctionsRouterSetup is BaseTest { }); } - function getCoordinatorConfig() public pure returns (bytes memory) { - IFunctionsBilling.Config memory billingConfig = IFunctionsBilling.Config({ - maxCallbackGasLimit: 5, - feedStalenessSeconds: 5, - gasOverheadAfterCallback: 5, - gasOverheadBeforeCallback: 5, - requestTimeoutSeconds: 1, - donFee: 5, - maxSupportedRequestDataVersion: 5, - fulfillmentGasPriceOverEstimationBP: 5, - fallbackNativePerUnitLink: 2874 - }); - + function getCoordinatorConfig() public pure returns (FunctionsBilling.Config memory) { return - abi.encode( - billingConfig.maxCallbackGasLimit, - billingConfig.feedStalenessSeconds, - billingConfig.gasOverheadBeforeCallback, - billingConfig.gasOverheadAfterCallback, - billingConfig.requestTimeoutSeconds, - billingConfig.donFee, - billingConfig.maxSupportedRequestDataVersion, - billingConfig.fulfillmentGasPriceOverEstimationBP, - billingConfig.fallbackNativePerUnitLink - ); + FunctionsBilling.Config({ + maxCallbackGasLimit: 5, + feedStalenessSeconds: 5, + gasOverheadAfterCallback: 5, + gasOverheadBeforeCallback: 5, + requestTimeoutSeconds: 1, + donFee: 5, + maxSupportedRequestDataVersion: 5, + fulfillmentGasPriceOverEstimationBP: 5, + fallbackNativePerUnitLink: 2874 + }); } - function getTermsOfServiceConfig() public pure returns (bytes memory) { - bool enabled = false; - address proofSignerPublicKey = address(132); - return abi.encode(enabled, proofSignerPublicKey); + function getTermsOfServiceConfig() public pure returns (TermsOfServiceAllowList.Config memory) { + return TermsOfServiceAllowList.Config({enabled: false, signerPublicKey: address(132)}); } } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol index 42ed2a9493d..0bf7adb7a25 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol @@ -2,11 +2,12 @@ pragma solidity ^0.8.6; import {FunctionsCoordinator} from "../../../dev/1_0_0/FunctionsCoordinator.sol"; +import {FunctionsBilling} from "../../../dev/1_0_0/FunctionsBilling.sol"; contract FunctionsCoordinatorTestHelper is FunctionsCoordinator { constructor( address router, - bytes memory config, + FunctionsBilling.Config memory config, address linkToNativeFeed ) FunctionsCoordinator(router, config, linkToNativeFeed) {} diff --git a/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol b/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol index 8c006a35b95..135f6d0aebf 100644 --- a/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol +++ b/contracts/src/v0.8/shared/interfaces/ITypeAndVersion.sol @@ -2,5 +2,5 @@ pragma solidity ^0.8.0; interface ITypeAndVersion { - function typeAndVersion() external pure virtual returns (string memory); + function typeAndVersion() external pure returns (string memory); } diff --git a/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts b/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts index ae20fa7588d..5aece579b66 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsCoordinator.test.ts @@ -1,48 +1,62 @@ -import { ethers } from 'hardhat' import { expect } from 'chai' import { getSetupFactory, FunctionsContracts, coordinatorConfig, - ids, + FunctionsRoles, } from './utils' const setup = getSetupFactory() let contracts: FunctionsContracts +let roles: FunctionsRoles beforeEach(async () => { - ;({ contracts } = setup()) + ;({ contracts, roles } = setup()) }) describe('Functions Coordinator', () => { describe('Config', () => { + it('non-owner is unable to update config', async () => { + await expect( + contracts.coordinator + .connect(roles.stranger) + .updateConfig(coordinatorConfig), + ).to.be.revertedWith('Only callable by owner') + }) + + it('Owner can update config', async () => { + const beforeConfig = await contracts.coordinator.getConfig() + await expect( + contracts.coordinator.updateConfig({ + ...coordinatorConfig, + donFee: 10, + }), + ).to.emit(contracts.coordinator, 'ConfigUpdated') + const afterConfig = await contracts.coordinator.getConfig() + expect(beforeConfig).to.not.equal(afterConfig) + }) + + it('returns the config set', async () => { + const config = await contracts.coordinator + .connect(roles.stranger) + .getConfig() + await Promise.all( + Object.keys(coordinatorConfig).map((key) => + expect(config[key]).to.equal( + coordinatorConfig[key as keyof typeof coordinatorConfig], + ), + ), + ) + }) + it('#fulfillmentGasPriceOverEstimationBP overestimates gas cost', async () => { const estimateWithNoOverestimaton = await contracts.coordinator.estimateCost(1, 0x0, 100_000, 20) - await contracts.router.proposeConfigUpdate( - ids.donId, - ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'uint80', - 'uint16', - 'uint256', - 'int256', - ], - [ - ...Object.values({ - ...coordinatorConfig, - fulfillmentGasPriceOverEstimationBP: 10_000, - }), - ], - ), - ) - await contracts.router.updateConfig(ids.donId) + await contracts.coordinator.updateConfig({ + ...coordinatorConfig, + fulfillmentGasPriceOverEstimationBP: 10_000, + }) // Halve the gas price, which should be the same estimate because of fulfillmentGasPriceOverEstimationBP doubling the gas price const estimateWithOverestimaton = diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index bba8d8f7dd7..687ef65f6b8 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -3,33 +3,52 @@ import { getSetupFactory, FunctionsContracts, functionsRouterConfig, + FunctionsRoles, } from './utils' const setup = getSetupFactory() let contracts: FunctionsContracts +let roles: FunctionsRoles beforeEach(async () => { - ;({ contracts } = setup()) + ;({ contracts, roles } = setup()) }) describe('Functions Router - Request lifecycle', () => { - describe('Getters', () => { + describe('Config', () => { it('#typeAndVersion', async () => { expect(await contracts.router.typeAndVersion()).to.be.equal( 'Functions Router v1.0.0', ) }) - it('#config', async () => { - const config = await contracts.router.getConfig() - expect(config.maxConsumersPerSubscription).to.be.equal( - functionsRouterConfig.maxConsumersPerSubscription, - ) - expect(config.adminFee).to.be.equal(functionsRouterConfig.adminFee) - expect(config.handleOracleFulfillmentSelector).to.be.equal( - functionsRouterConfig.handleOracleFulfillmentSelector, - ) - expect(config.maxCallbackGasLimits.toString()).to.be.equal( - functionsRouterConfig.maxCallbackGasLimits.toString(), + it('non-owner is unable to update config', async () => { + await expect( + contracts.router + .connect(roles.stranger) + .updateConfig(functionsRouterConfig), + ).to.be.revertedWith('Only callable by owner') + }) + + it('owner can update config', async () => { + const beforeConfig = await contracts.router.getConfig() + await expect( + contracts.router.updateConfig({ + ...functionsRouterConfig, + adminFee: 10, + }), + ).to.emit(contracts.router, 'ConfigUpdated') + const afterConfig = await contracts.router.getConfig() + expect(beforeConfig).to.not.equal(afterConfig) + }) + + it('returns the config set', async () => { + const config = await contracts.router.connect(roles.stranger).getConfig() + await Promise.all( + Object.keys(functionsRouterConfig).map((key) => + expect(config[key]).to.deep.equal( + functionsRouterConfig[key as keyof typeof functionsRouterConfig], + ), + ), ) }) }) diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index 0a89562db9a..3e52f8cf8e9 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -14,7 +14,7 @@ const setup = getSetupFactory() let contracts: FunctionsContracts let roles: FunctionsRoles -const baselineGasUsed = 793891 +const baselineGasUsed = 721271 let currentGasUsed = 0 beforeEach(async () => { diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 2a094d1148f..350113904c7 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -11,7 +11,6 @@ import { encodeReport, stringToHex, getEventArg, - functionsRouterConfig, } from './utils' const setup = getSetupFactory() @@ -24,187 +23,27 @@ beforeEach(async () => { }) describe('FunctionsRouter - Base', () => { - describe('Config', () => { - it('non-owner is unable to set config', async () => { - await expect( - contracts.router - .connect(roles.stranger) - .proposeContractsUpdate([ids.donId], [contracts.coordinator.address]), - ).to.be.revertedWith('Only callable by owner') - }) - - it('non-owner is unable to apply config', async () => { - await expect( - contracts.router.proposeConfigUpdate( - ids.routerId, - ethers.utils.defaultAbiCoder.encode( - ['uint16', 'uint96', 'bytes4', 'uint32[]'], - [2000, 1, 0x0ca76175, [300_000, 500_000]], - ), - ), - ).to.emit(contracts.router, 'ConfigProposed') - await expect( - contracts.router.connect(roles.stranger).updateConfig(ids.routerId), - ).to.be.revertedWith('Only callable by owner') - }) - - it('incorrect config cannot be applied', async () => { - await contracts.router.proposeConfigUpdate( - ids.routerId, - ethers.utils.defaultAbiCoder.encode( - ['int256', 'bytes4'], - [-100000, 0x0ca76175], - ), - ) - await expect(contracts.router.updateConfig(ids.routerId)).to.be.reverted - }) - - it('Owner can update config of the Router', async () => { - const beforeConfig = await contracts.router.getConfig() - await expect( - contracts.router.proposeConfigUpdateSelf( - ethers.utils.defaultAbiCoder.encode( - contracts.router.interface.events[ - 'ConfigChanged((uint16,uint96,bytes4,uint32[]))' - ].inputs, - [ - { - maxConsumersPerSubscription: 2000, - adminFee: 1, - handleOracleFulfillmentSelector: 0x0ca76175, - maxCallbackGasLimits: [300_000, 500_000], - }, - ], - ), - ), - ).to.emit(contracts.router, 'ConfigProposed') - await expect(contracts.router.updateConfigSelf()).to.emit( - contracts.router, - 'ConfigUpdated', - ) - - const afterConfig = await contracts.router.getConfig() - expect(beforeConfig).to.not.equal(afterConfig) - }) - - it('Config of a contract on a route can be updated', async () => { - const beforeConfig = await contracts.coordinator.getConfig() - - await expect( - contracts.router.proposeConfigUpdate( - ids.donId, - ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'int256', - 'uint32', - 'uint96', - 'uint16', - 'uint256', - ], - [ - ...Object.values({ - ...coordinatorConfig, - maxSupportedRequestDataVersion: 2, - }), - ], - ), - ), - ).to.emit(contracts.router, 'ConfigProposed') - await expect(contracts.router.updateConfig(ids.donId)).to.emit( - contracts.router, - 'ConfigUpdated', - ) - - const afterConfig = await contracts.router.getConfig() - expect(beforeConfig).to.not.equal(afterConfig) - }) - - it('returns the config set on the Router', async () => { - const config = await contracts.router.connect(roles.stranger).getConfig() - expect(config[0]).to.equal( - functionsRouterConfig.maxConsumersPerSubscription, - ) - expect(config[1]).to.equal(functionsRouterConfig.adminFee) - expect(config[2]).to.equal( - functionsRouterConfig.handleOracleFulfillmentSelector, - ) - expect(config[3].toString()).to.equal( - functionsRouterConfig.maxCallbackGasLimits.toString(), - ) - }) - }) - describe('Updates', () => { - it('One or more contracts on a route can be updated', async () => { - const subscriptionId = await createSubscription( - roles.subOwner, - [contracts.client.address], - contracts.router, - contracts.accessControl, - contracts.linkToken, - ) + it('One or more contracts on a route can be updated by the owner', async () => { const coordinator2 = await factories.functionsCoordinatorFactory .connect(roles.defaultAccount) .deploy( contracts.router.address, - ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'int256', - 'uint32', - 'uint96', - 'uint16', - 'uint256', - ], - [...Object.values(coordinatorConfig)], - ), + coordinatorConfig, contracts.mockLinkEth.address, ) const coordinator3 = await factories.functionsCoordinatorFactory .connect(roles.defaultAccount) .deploy( contracts.router.address, - ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'int256', - 'uint32', - 'uint96', - 'uint16', - 'uint256', - ], - [...Object.values(coordinatorConfig)], - ), + coordinatorConfig, contracts.mockLinkEth.address, ) const coordinator4 = await factories.functionsCoordinatorFactory .connect(roles.defaultAccount) .deploy( contracts.router.address, - ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'int256', - 'uint32', - 'uint96', - 'uint16', - 'uint256', - ], - [...Object.values(coordinatorConfig)], - ), + coordinatorConfig, contracts.mockLinkEth.address, ) @@ -224,6 +63,14 @@ describe('FunctionsRouter - Base', () => { ), ).to.emit(contracts.router, `ContractProposed`) + const subscriptionId = await createSubscription( + roles.subOwner, + [contracts.client.address], + contracts.router, + contracts.accessControl, + contracts.linkToken, + ) + const requestProposedTx = await contracts.client.sendRequestProposed( `return 'hello world'`, subscriptionId, @@ -281,70 +128,6 @@ describe('FunctionsRouter - Base', () => { }) }) - // TODO: disabled in anticipation of MCM - - // describe('Timelock', () => { - // it('prevents applying timelock updates', async () => { - // await contracts.router.proposeTimelockBlocks(5) - // await contracts.router.updateTimelockBlocks() - // await contracts.router.proposeTimelockBlocks(6) - // await expect(contracts.router.updateTimelockBlocks()).to.be.revertedWith( - // 'TimelockInEffect', - // ) - // }) - - // it('prevents applying config updates', async () => { - // await contracts.router.proposeTimelockBlocks(5) - // await contracts.router.updateTimelockBlocks() - - // await contracts.router.proposeConfigUpdate( - // ids.routerId, - // ethers.utils.defaultAbiCoder.encode( - // ['uint16', 'uint96', 'bytes4', 'uint32[]'], - // [2000, 1, 0x0ca76175, [300_000, 500_000]], - // ), - // ) - // await expect( - // contracts.router.updateConfig(ids.routerId), - // ).to.be.revertedWith('TimelockInEffect') - // }) - - // it('prevents applying contract updates', async () => { - // await contracts.router.proposeTimelockBlocks(5) - // await contracts.router.updateTimelockBlocks() - - // const coordinator2 = await factories.functionsCoordinatorFactory - // .connect(roles.defaultAccount) - // .deploy( - // contracts.router.address, - // ethers.utils.defaultAbiCoder.encode( - // [ - // 'uint32', - // 'uint32', - // 'uint32', - // 'uint32', - // 'int256', - // 'uint32', - // 'uint96', - // 'uint16', - // 'uint256', - // ], - // [...Object.values(coordinatorConfig)], - // ), - // contracts.mockLinkEth.address, - // ) - - // await contracts.router.proposeContractsUpdate( - // [ids.donId2], - // [coordinator2.address], - // ) - - // await expect(contracts.router.updateContracts()).to.be.revertedWith( - // 'TimelockInEffect', - // ) - // }) - // }) - describe('Emergency Pause', () => { it('has paused state visible', async () => { const paused = await contracts.router.paused() diff --git a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts index 261196d1b36..3405e4582db 100644 --- a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts +++ b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts @@ -6,6 +6,7 @@ import { FunctionsRoles, acceptTermsOfService, accessControlMockPrivateKey, + accessControlConfig, } from './utils' const setup = getSetupFactory() @@ -17,6 +18,40 @@ beforeEach(async () => { }) describe('ToS Access Control', () => { + describe('Config', () => { + it('non-owner is unable to update config', async () => { + await expect( + contracts.accessControl + .connect(roles.stranger) + .updateConfig(accessControlConfig), + ).to.be.revertedWith('Only callable by owner') + }) + + it('Owner can update config', async () => { + const beforeConfig = await contracts.accessControl.getConfig() + await expect( + contracts.accessControl.updateConfig({ + ...accessControlConfig, + enabled: false, + }), + ).to.emit(contracts.accessControl, 'ConfigUpdated') + const afterConfig = await contracts.accessControl.getConfig() + expect(beforeConfig).to.not.equal(afterConfig) + }) + it('returns the config set', async () => { + const config = await contracts.accessControl + .connect(roles.stranger) + .getConfig() + await Promise.all( + Object.keys(accessControlConfig).map((key) => { + expect(config[key]).to.equal( + accessControlConfig[key as keyof typeof accessControlConfig], + ) + }), + ) + }) + }) + describe('Accepting', () => { it('can only be done with a valid signature', async () => { const message = await contracts.accessControl.getMessage( diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index e945d96c49f..6672a18f5cc 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -92,17 +92,18 @@ export const coordinatorConfig: CoordinatorConfig = { fulfillmentGasPriceOverEstimationBP: 0, fallbackNativePerUnitLink: BigNumber.from(fallbackNativePerUnitLink), } -export const accessControlMockPublicKey = - '0x32237412cC0321f56422d206e505dB4B3871AF5c' +export const accessControlMockPublicKey = ethers.utils.getAddress( + '0x32237412cC0321f56422d206e505dB4B3871AF5c', +) export const accessControlMockPrivateKey = '2e8c8eaff4159e59711b42424c1555af1b78409e12c6f9c69a6a986d75442b20' export type AccessControlConfig = { enabled: boolean - proofSignerPublicKey: string // address + signerPublicKey: string // address } export const accessControlConfig: AccessControlConfig = { enabled: true, - proofSignerPublicKey: accessControlMockPublicKey, + signerPublicKey: accessControlMockPublicKey, } export async function setupRolesAndFactories(): Promise<{ @@ -222,48 +223,24 @@ export function getSetupFactory(): () => { const linkToken = await factories.linkTokenFactory .connect(roles.defaultAccount) .deploy() + const mockLinkEth = await factories.mockAggregatorV3Factory.deploy( 0, linkEthRate, ) - // const routerConfigBytes = ethers.utils.defaultAbiCoder.encode( - // ['uint16', 'uint96', 'bytes4', 'uint32[]'], - // [...Object.values(functionsRouterConfig)], - // ) - const startingTimelockBlocks = 0 - const maxTimelockBlocks = 20 + const router = await factories.functionsRouterFactory .connect(roles.defaultAccount) - .deploy( - startingTimelockBlocks, - maxTimelockBlocks, - linkToken.address, - functionsRouterConfig, - ) - const coordinatorConfigBytes = ethers.utils.defaultAbiCoder.encode( - [ - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'uint32', - 'uint80', - 'uint16', - 'uint256', - 'int256', - ], - [...Object.values(coordinatorConfig)], - ) + .deploy(linkToken.address, functionsRouterConfig) + const coordinator = await factories.functionsCoordinatorFactory .connect(roles.defaultAccount) - .deploy(router.address, coordinatorConfigBytes, mockLinkEth.address) - const accessControlConfigBytes = ethers.utils.defaultAbiCoder.encode( - ['bool', 'address'], - [...Object.values(accessControlConfig)], - ) + .deploy(router.address, coordinatorConfig, mockLinkEth.address) + const accessControl = await factories.accessControlFactory .connect(roles.defaultAccount) - .deploy(router.address, accessControlConfigBytes) + .deploy(router.address, accessControlConfig) + const client = await factories.clientTestHelperFactory .connect(roles.consumer) .deploy(router.address) diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index b7c3a0fc85c..068ae3a2c6d 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -30,16 +30,21 @@ var ( _ = abi.ConvertType ) +type TermsOfServiceAllowListConfig struct { + Enabled bool + SignerPublicKey common.Address +} + var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"AddedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"BlockedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"UnblockedAccess\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620012443803806200124483398101604081905262000034916200014e565b81816001600160a01b0382166200005e57604051632530e88560e11b815260040160405180910390fd5b6001600160a01b038216608052620000768162000080565b505050506200027c565b6000808280602001905181019062000099919062000239565b6040805180820182528315158082526001600160a01b0384166020928301819052600380546001600160a81b031916610100600160a81b031984161761010083021790558351918252918101919091529294509092507f232bb132911bf7acb3a5ab4dd8e603080819db6a26b68da198599a7c83e2494c910160405180910390a1505050565b6001600160a01b03811681146200013557600080fd5b50565b634e487b7160e01b600052604160045260246000fd5b600080604083850312156200016257600080fd5b82516200016f816200011f565b602084810151919350906001600160401b03808211156200018f57600080fd5b818601915086601f830112620001a457600080fd5b815181811115620001b957620001b962000138565b604051601f8201601f19908116603f01168101908382118183101715620001e457620001e462000138565b816040528281528986848701011115620001fd57600080fd5b600093505b8284101562000221578484018601518185018701529285019262000202565b60008684830101528096505050505050509250929050565b600080604083850312156200024d57600080fd5b825180151581146200025e57600080fd5b602084015190925062000271816200011f565b809150509250929050565b608051610f9e620002a660003960008181610414015281816105c7015261075d0152610f9e6000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c8063817ef62e116100765780638cc6acce1161005b5780638cc6acce14610139578063a39b06e31461014c578063a5e1d61d1461016d57600080fd5b8063817ef62e1461011157806382184c7b1461012657600080fd5b8063181f5a77146100a85780633908c4d4146100c657806347663acb146100db5780636b14daf8146100ee575b600080fd5b6100b0610180565b6040516100bd9190610b56565b60405180910390f35b6100d96100d4366004610be4565b61019c565b005b6100d96100e9366004610c49565b610412565b6101016100fc366004610c66565b61058a565b60405190151581526020016100bd565b6101196105b4565b6040516100bd9190610ceb565b6100d9610134366004610c49565b6105c5565b6100d9610147366004610d74565b610745565b61015f61015a366004610e43565b6107c0565b6040519081526020016100bd565b61010161017b366004610c49565b61081e565b6040518060600160405280602c8152602001610f66602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526002602052604090205460ff16156101fc576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061020886866107c0565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206003546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156102e2573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610339576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061037e57503373ffffffffffffffffffffffffffffffffffffffff87161480159061037e5750333b155b156103b5576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6103c060008661085f565b5060405173ffffffffffffffffffffffffffffffffffffffff861681527f87286ad1f399c8e82bf0c4ef4fcdc570ea2e1e92176e5c848b6413545b885db49060200160405180910390a1505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561047f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906104a39190610e7c565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610507576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905590519182527f28bbd0761309a99e8fb5e5d02ada0b7b2db2e5357531ff5dbfc205c3f5b6592b91015b60405180910390a150565b60035460009060ff1661059f575060016105ad565b6105aa600085610881565b90505b9392505050565b60606105c060006108b0565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610632573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106569190610e7c565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146106ba576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c56000826108bd565b5073ffffffffffffffffffffffffffffffffffffffff811660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e1910161057f565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146107b4576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6107bd816108df565b50565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60035460009060ff1661083357506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526002602052604090205460ff1690565b60006105ad8373ffffffffffffffffffffffffffffffffffffffff84166109b8565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415156105ad565b606060006105ad83610a07565b60006105ad8373ffffffffffffffffffffffffffffffffffffffff8416610a63565b600080828060200190518101906108f69190610e99565b60408051808201825283151580825273ffffffffffffffffffffffffffffffffffffffff84166020928301819052600380547fffffffffffffffffffffff000000000000000000000000000000000000000000167fffffffffffffffffffffff0000000000000000000000000000000000000000ff84161761010083021790558351918252918101919091529294509092507f232bb132911bf7acb3a5ab4dd8e603080819db6a26b68da198599a7c83e2494c910160405180910390a1505050565b60008181526001830160205260408120546109ff57508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610818565b506000610818565b606081600001805480602002602001604051908101604052809291908181526020018280548015610a5757602002820191906000526020600020905b815481526020019060010190808311610a43575b50505050509050919050565b60008181526001830160205260408120548015610b4c576000610a87600183610ecd565b8554909150600090610a9b90600190610ecd565b9050818114610b00576000866000018281548110610abb57610abb610f07565b9060005260206000200154905080876000018481548110610ade57610ade610f07565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610b1157610b11610f36565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610818565b6000915050610818565b600060208083528351808285015260005b81811015610b8357858101830151858201604001528201610b67565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff811681146107bd57600080fd5b600080600080600060a08688031215610bfc57600080fd5b8535610c0781610bc2565b94506020860135610c1781610bc2565b93506040860135925060608601359150608086013560ff81168114610c3b57600080fd5b809150509295509295909350565b600060208284031215610c5b57600080fd5b81356105ad81610bc2565b600080600060408486031215610c7b57600080fd5b8335610c8681610bc2565b9250602084013567ffffffffffffffff80821115610ca357600080fd5b818601915086601f830112610cb757600080fd5b813581811115610cc657600080fd5b876020828501011115610cd857600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b81811015610d3957835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610d07565b50909695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610d8657600080fd5b813567ffffffffffffffff80821115610d9e57600080fd5b818401915084601f830112610db257600080fd5b813581811115610dc457610dc4610d45565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610e0a57610e0a610d45565b81604052828152876020848701011115610e2357600080fd5b826020860160208301376000928101602001929092525095945050505050565b60008060408385031215610e5657600080fd5b8235610e6181610bc2565b91506020830135610e7181610bc2565b809150509250929050565b600060208284031215610e8e57600080fd5b81516105ad81610bc2565b60008060408385031215610eac57600080fd5b82518015158114610ebc57600080fd5b6020840151909250610e7181610bc2565b81810381811115610818577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"AddedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"BlockedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"indexed\":false,\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"UnblockedAccess\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200154a3803806200154a8339810160408190526200003491620002bf565b33806000846001600160a01b0381166200006157604051632530e88560e11b815260040160405180910390fd5b6001600160a01b039081166080528216620000c35760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000f657620000f68162000112565b5050506200010a81620001bd60201b60201c565b50506200035d565b336001600160a01b038216036200016c5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000ba565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001c762000244565b805160058054602080850180516001600160a81b0319909316941515610100600160a81b03198116959095176101006001600160a01b039485160217909355604080519485529251909116908301527f0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a910160405180910390a150565b6000546001600160a01b03163314620002a05760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401620000ba565b565b80516001600160a01b0381168114620002ba57600080fd5b919050565b6000808284036060811215620002d457600080fd5b620002df84620002a2565b92506040601f1982011215620002f457600080fd5b50604080519081016001600160401b03811182821017156200032657634e487b7160e01b600052604160045260246000fd5b604052602084015180151581146200033d57600080fd5b81526200034d60408501620002a2565b6020820152809150509250929050565b6080516111ca62000380600039600081816104f201526107a701526111ca6000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806382184c7b1161008c578063a39b06e311610066578063a39b06e3146101b8578063a5e1d61d146101d9578063c3f909d4146101ec578063f2fde38b1461024b57600080fd5b806382184c7b1461016a57806389f9a2c41461017d5780638da5cb5b1461019057600080fd5b80636b14daf8116100bd5780636b14daf81461012a57806379ba50971461014d578063817ef62e1461015557600080fd5b8063181f5a77146100e45780633908c4d41461010257806347663acb14610117575b600080fd5b6100ec61025e565b6040516100f99190610e29565b60405180910390f35b610115610110366004610eb7565b61027a565b005b610115610125366004610f1c565b6104f0565b61013d610138366004610f39565b610668565b60405190151581526020016100f9565b610115610692565b61015d610794565b6040516100f99190610fbe565b610115610178366004610f1c565b6107a5565b61011561018b366004611018565b610925565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f9565b6101cb6101c63660046110a3565b6109e0565b6040519081526020016100f9565b61013d6101e7366004610f1c565b610a3e565b60408051808201825260008082526020918201528151808301835260055460ff8116151580835273ffffffffffffffffffffffffffffffffffffffff6101009092048216928401928352845190815291511691810191909152016100f9565b610115610259366004610f1c565b610a7f565b6040518060600160405280602c8152602001611192602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526004602052604090205460ff16156102da576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006102e686866109e0565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206005546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156103c0573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610417576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061045c57503373ffffffffffffffffffffffffffffffffffffffff87161480159061045c5750333b155b15610493576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61049e600286610a93565b5060405173ffffffffffffffffffffffffffffffffffffffff861681527f87286ad1f399c8e82bf0c4ef4fcdc570ea2e1e92176e5c848b6413545b885db49060200160405180910390a1505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561055d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061058191906110dc565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146105e5576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660008181526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905590519182527f28bbd0761309a99e8fb5e5d02ada0b7b2db2e5357531ff5dbfc205c3f5b6592b91015b60405180910390a150565b60055460009060ff1661067d5750600161068b565b610688600285610ab5565b90505b9392505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610718576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60606107a06002610ae4565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610812573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061083691906110dc565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461089a576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108a5600282610af1565b5073ffffffffffffffffffffffffffffffffffffffff811660008181526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e1910161065d565b61092d610b13565b805160058054602080850180517fffffffffffffffffffffff0000000000000000000000000000000000000000009093169415157fffffffffffffffffffffff0000000000000000000000000000000000000000ff81169590951761010073ffffffffffffffffffffffffffffffffffffffff9485160217909355604080519485529251909116908301527f0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a910161065d565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60055460009060ff16610a5357506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526004602052604090205460ff1690565b610a87610b13565b610a9081610b96565b50565b600061068b8373ffffffffffffffffffffffffffffffffffffffff8416610c8b565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561068b565b6060600061068b83610cda565b600061068b8373ffffffffffffffffffffffffffffffffffffffff8416610d36565b60005473ffffffffffffffffffffffffffffffffffffffff163314610b94576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161070f565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610c15576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161070f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000818152600183016020526040812054610cd257508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610a38565b506000610a38565b606081600001805480602002602001604051908101604052809291908181526020018280548015610d2a57602002820191906000526020600020905b815481526020019060010190808311610d16575b50505050509050919050565b60008181526001830160205260408120548015610e1f576000610d5a6001836110f9565b8554909150600090610d6e906001906110f9565b9050818114610dd3576000866000018281548110610d8e57610d8e611133565b9060005260206000200154905080876000018481548110610db157610db1611133565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610de457610de4611162565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610a38565b6000915050610a38565b600060208083528351808285015260005b81811015610e5657858101830151858201604001528201610e3a565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a9057600080fd5b600080600080600060a08688031215610ecf57600080fd5b8535610eda81610e95565b94506020860135610eea81610e95565b93506040860135925060608601359150608086013560ff81168114610f0e57600080fd5b809150509295509295909350565b600060208284031215610f2e57600080fd5b813561068b81610e95565b600080600060408486031215610f4e57600080fd5b8335610f5981610e95565b9250602084013567ffffffffffffffff80821115610f7657600080fd5b818601915086601f830112610f8a57600080fd5b813581811115610f9957600080fd5b876020828501011115610fab57600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b8181101561100c57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610fda565b50909695505050505050565b60006040828403121561102a57600080fd5b6040516040810181811067ffffffffffffffff82111715611074577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040528235801515811461108757600080fd5b8152602083013561109781610e95565b60208201529392505050565b600080604083850312156110b657600080fd5b82356110c181610e95565b915060208301356110d181610e95565b809150509250929050565b6000602082840312156110ee57600080fd5b815161068b81610e95565b81810381811115610a38577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI var TermsOfServiceAllowListBin = TermsOfServiceAllowListMetaData.Bin -func DeployTermsOfServiceAllowList(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address, config []byte) (common.Address, *types.Transaction, *TermsOfServiceAllowList, error) { +func DeployTermsOfServiceAllowList(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address, config TermsOfServiceAllowListConfig) (common.Address, *types.Transaction, *TermsOfServiceAllowList, error) { parsed, err := TermsOfServiceAllowListMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -193,6 +198,28 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetAllAllo return _TermsOfServiceAllowList.Contract.GetAllAllowedSenders(&_TermsOfServiceAllowList.CallOpts) } +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetConfig(opts *bind.CallOpts) (TermsOfServiceAllowListConfig, error) { + var out []interface{} + err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getConfig") + + if err != nil { + return *new(TermsOfServiceAllowListConfig), err + } + + out0 := *abi.ConvertType(out[0], new(TermsOfServiceAllowListConfig)).(*TermsOfServiceAllowListConfig) + + return out0, err + +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) GetConfig() (TermsOfServiceAllowListConfig, error) { + return _TermsOfServiceAllowList.Contract.GetConfig(&_TermsOfServiceAllowList.CallOpts) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) GetConfig() (TermsOfServiceAllowListConfig, error) { + return _TermsOfServiceAllowList.Contract.GetConfig(&_TermsOfServiceAllowList.CallOpts) +} + func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) GetMessage(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) { var out []interface{} err := _TermsOfServiceAllowList.contract.Call(opts, &out, "getMessage", acceptor, recipient) @@ -259,6 +286,28 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) IsBlockedS return _TermsOfServiceAllowList.Contract.IsBlockedSender(&_TermsOfServiceAllowList.CallOpts, sender) } +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _TermsOfServiceAllowList.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 (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) Owner() (common.Address, error) { + return _TermsOfServiceAllowList.Contract.Owner(&_TermsOfServiceAllowList.CallOpts) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) Owner() (common.Address, error) { + return _TermsOfServiceAllowList.Contract.Owner(&_TermsOfServiceAllowList.CallOpts) +} + func (_TermsOfServiceAllowList *TermsOfServiceAllowListCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { var out []interface{} err := _TermsOfServiceAllowList.contract.Call(opts, &out, "typeAndVersion") @@ -281,6 +330,18 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListCallerSession) TypeAndVer return _TermsOfServiceAllowList.Contract.TypeAndVersion(&_TermsOfServiceAllowList.CallOpts) } +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _TermsOfServiceAllowList.contract.Transact(opts, "acceptOwnership") +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) AcceptOwnership() (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.AcceptOwnership(&_TermsOfServiceAllowList.TransactOpts) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.AcceptOwnership(&_TermsOfServiceAllowList.TransactOpts) +} + func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) AcceptTermsOfService(opts *bind.TransactOpts, acceptor common.Address, recipient common.Address, r [32]byte, s [32]byte, v uint8) (*types.Transaction, error) { return _TermsOfServiceAllowList.contract.Transact(opts, "acceptTermsOfService", acceptor, recipient, r, s, v) } @@ -305,6 +366,18 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) BlockS return _TermsOfServiceAllowList.Contract.BlockSender(&_TermsOfServiceAllowList.TransactOpts, sender) } +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _TermsOfServiceAllowList.contract.Transact(opts, "transferOwnership", to) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.TransferOwnership(&_TermsOfServiceAllowList.TransactOpts, to) +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _TermsOfServiceAllowList.Contract.TransferOwnership(&_TermsOfServiceAllowList.TransactOpts, to) +} + func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) UnblockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) { return _TermsOfServiceAllowList.contract.Transact(opts, "unblockSender", sender) } @@ -317,15 +390,15 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) Unbloc return _TermsOfServiceAllowList.Contract.UnblockSender(&_TermsOfServiceAllowList.TransactOpts, sender) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactor) UpdateConfig(opts *bind.TransactOpts, config TermsOfServiceAllowListConfig) (*types.Transaction, error) { return _TermsOfServiceAllowList.contract.Transact(opts, "updateConfig", config) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) UpdateConfig(config []byte) (*types.Transaction, error) { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListSession) UpdateConfig(config TermsOfServiceAllowListConfig) (*types.Transaction, error) { return _TermsOfServiceAllowList.Contract.UpdateConfig(&_TermsOfServiceAllowList.TransactOpts, config) } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) UpdateConfig(config []byte) (*types.Transaction, error) { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListTransactorSession) UpdateConfig(config TermsOfServiceAllowListConfig) (*types.Transaction, error) { return _TermsOfServiceAllowList.Contract.UpdateConfig(&_TermsOfServiceAllowList.TransactOpts, config) } @@ -563,8 +636,8 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseBlockedAcc return event, nil } -type TermsOfServiceAllowListConfigSetIterator struct { - Event *TermsOfServiceAllowListConfigSet +type TermsOfServiceAllowListConfigUpdatedIterator struct { + Event *TermsOfServiceAllowListConfigUpdated contract *bind.BoundContract event string @@ -575,7 +648,7 @@ type TermsOfServiceAllowListConfigSetIterator struct { fail error } -func (it *TermsOfServiceAllowListConfigSetIterator) Next() bool { +func (it *TermsOfServiceAllowListConfigUpdatedIterator) Next() bool { if it.fail != nil { return false @@ -584,7 +657,7 @@ func (it *TermsOfServiceAllowListConfigSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(TermsOfServiceAllowListConfigSet) + it.Event = new(TermsOfServiceAllowListConfigUpdated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -599,7 +672,7 @@ func (it *TermsOfServiceAllowListConfigSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(TermsOfServiceAllowListConfigSet) + it.Event = new(TermsOfServiceAllowListConfigUpdated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -614,33 +687,304 @@ func (it *TermsOfServiceAllowListConfigSetIterator) Next() bool { } } -func (it *TermsOfServiceAllowListConfigSetIterator) Error() error { +func (it *TermsOfServiceAllowListConfigUpdatedIterator) Error() error { return it.fail } -func (it *TermsOfServiceAllowListConfigSetIterator) Close() error { +func (it *TermsOfServiceAllowListConfigUpdatedIterator) Close() error { it.sub.Unsubscribe() return nil } -type TermsOfServiceAllowListConfigSet struct { - Enabled bool - SignerPublicKey common.Address - Raw types.Log +type TermsOfServiceAllowListConfigUpdated struct { + Config TermsOfServiceAllowListConfig + Raw types.Log +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterConfigUpdated(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigUpdatedIterator, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "ConfigUpdated") + if err != nil { + return nil, err + } + return &TermsOfServiceAllowListConfigUpdatedIterator{contract: _TermsOfServiceAllowList.contract, event: "ConfigUpdated", logs: logs, sub: sub}, nil +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListConfigUpdated) (event.Subscription, error) { + + logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "ConfigUpdated") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TermsOfServiceAllowListConfigUpdated) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "ConfigUpdated", 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 (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseConfigUpdated(log types.Log) (*TermsOfServiceAllowListConfigUpdated, error) { + event := new(TermsOfServiceAllowListConfigUpdated) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "ConfigUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type TermsOfServiceAllowListOwnershipTransferRequestedIterator struct { + Event *TermsOfServiceAllowListOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *TermsOfServiceAllowListOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TermsOfServiceAllowListOwnershipTransferRequested) + 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(TermsOfServiceAllowListOwnershipTransferRequested) + 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 (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterConfigSet(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigSetIterator, error) { +func (it *TermsOfServiceAllowListOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *TermsOfServiceAllowListOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TermsOfServiceAllowListOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TermsOfServiceAllowListOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &TermsOfServiceAllowListOwnershipTransferRequestedIterator{contract: _TermsOfServiceAllowList.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TermsOfServiceAllowListOwnershipTransferRequested) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseOwnershipTransferRequested(log types.Log) (*TermsOfServiceAllowListOwnershipTransferRequested, error) { + event := new(TermsOfServiceAllowListOwnershipTransferRequested) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type TermsOfServiceAllowListOwnershipTransferredIterator struct { + Event *TermsOfServiceAllowListOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} - logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "ConfigSet") +func (it *TermsOfServiceAllowListOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TermsOfServiceAllowListOwnershipTransferred) + 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(TermsOfServiceAllowListOwnershipTransferred) + 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 *TermsOfServiceAllowListOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *TermsOfServiceAllowListOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TermsOfServiceAllowListOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TermsOfServiceAllowListOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TermsOfServiceAllowList.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) if err != nil { return nil, err } - return &TermsOfServiceAllowListConfigSetIterator{contract: _TermsOfServiceAllowList.contract, event: "ConfigSet", logs: logs, sub: sub}, nil + return &TermsOfServiceAllowListOwnershipTransferredIterator{contract: _TermsOfServiceAllowList.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListConfigSet) (event.Subscription, error) { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "ConfigSet") + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TermsOfServiceAllowList.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) if err != nil { return nil, err } @@ -650,8 +994,8 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchConfigSet( select { case log := <-logs: - event := new(TermsOfServiceAllowListConfigSet) - if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "ConfigSet", log); err != nil { + event := new(TermsOfServiceAllowListOwnershipTransferred) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return err } event.Raw = log @@ -672,9 +1016,9 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) WatchConfigSet( }), nil } -func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseConfigSet(log types.Log) (*TermsOfServiceAllowListConfigSet, error) { - event := new(TermsOfServiceAllowListConfigSet) - if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "ConfigSet", log); err != nil { +func (_TermsOfServiceAllowList *TermsOfServiceAllowListFilterer) ParseOwnershipTransferred(log types.Log) (*TermsOfServiceAllowListOwnershipTransferred, error) { + event := new(TermsOfServiceAllowListOwnershipTransferred) + if err := _TermsOfServiceAllowList.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { return nil, err } event.Raw = log @@ -804,8 +1148,12 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowList) ParseLog(log types.Log) return _TermsOfServiceAllowList.ParseAddedAccess(log) case _TermsOfServiceAllowList.abi.Events["BlockedAccess"].ID: return _TermsOfServiceAllowList.ParseBlockedAccess(log) - case _TermsOfServiceAllowList.abi.Events["ConfigSet"].ID: - return _TermsOfServiceAllowList.ParseConfigSet(log) + case _TermsOfServiceAllowList.abi.Events["ConfigUpdated"].ID: + return _TermsOfServiceAllowList.ParseConfigUpdated(log) + case _TermsOfServiceAllowList.abi.Events["OwnershipTransferRequested"].ID: + return _TermsOfServiceAllowList.ParseOwnershipTransferRequested(log) + case _TermsOfServiceAllowList.abi.Events["OwnershipTransferred"].ID: + return _TermsOfServiceAllowList.ParseOwnershipTransferred(log) case _TermsOfServiceAllowList.abi.Events["UnblockedAccess"].ID: return _TermsOfServiceAllowList.ParseUnblockedAccess(log) @@ -822,8 +1170,16 @@ func (TermsOfServiceAllowListBlockedAccess) Topic() common.Hash { return common.HexToHash("0x337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e1") } -func (TermsOfServiceAllowListConfigSet) Topic() common.Hash { - return common.HexToHash("0x232bb132911bf7acb3a5ab4dd8e603080819db6a26b68da198599a7c83e2494c") +func (TermsOfServiceAllowListConfigUpdated) Topic() common.Hash { + return common.HexToHash("0x0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a") +} + +func (TermsOfServiceAllowListOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (TermsOfServiceAllowListOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") } func (TermsOfServiceAllowListUnblockedAccess) Topic() common.Hash { @@ -837,21 +1193,29 @@ func (_TermsOfServiceAllowList *TermsOfServiceAllowList) Address() common.Addres type TermsOfServiceAllowListInterface interface { GetAllAllowedSenders(opts *bind.CallOpts) ([]common.Address, error) + GetConfig(opts *bind.CallOpts) (TermsOfServiceAllowListConfig, error) + GetMessage(opts *bind.CallOpts, acceptor common.Address, recipient common.Address) ([32]byte, error) HasAccess(opts *bind.CallOpts, user common.Address, arg1 []byte) (bool, error) IsBlockedSender(opts *bind.CallOpts, sender common.Address) (bool, error) + Owner(opts *bind.CallOpts) (common.Address, error) + TypeAndVersion(opts *bind.CallOpts) (string, error) + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + AcceptTermsOfService(opts *bind.TransactOpts, acceptor common.Address, recipient common.Address, r [32]byte, s [32]byte, v uint8) (*types.Transaction, error) BlockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + UnblockSender(opts *bind.TransactOpts, sender common.Address) (*types.Transaction, error) - UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) + UpdateConfig(opts *bind.TransactOpts, config TermsOfServiceAllowListConfig) (*types.Transaction, error) FilterAddedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListAddedAccessIterator, error) @@ -865,11 +1229,23 @@ type TermsOfServiceAllowListInterface interface { ParseBlockedAccess(log types.Log) (*TermsOfServiceAllowListBlockedAccess, error) - FilterConfigSet(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigSetIterator, error) + FilterConfigUpdated(opts *bind.FilterOpts) (*TermsOfServiceAllowListConfigUpdatedIterator, error) + + WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListConfigUpdated) (event.Subscription, error) + + ParseConfigUpdated(log types.Log) (*TermsOfServiceAllowListConfigUpdated, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TermsOfServiceAllowListOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*TermsOfServiceAllowListOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TermsOfServiceAllowListOwnershipTransferredIterator, error) - WatchConfigSet(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListConfigSet) (event.Subscription, error) + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *TermsOfServiceAllowListOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - ParseConfigSet(log types.Log) (*TermsOfServiceAllowListConfigSet, error) + ParseOwnershipTransferred(log types.Log) (*TermsOfServiceAllowListOwnershipTransferred, error) FilterUnblockedAccess(opts *bind.FilterOpts) (*TermsOfServiceAllowListUnblockedAccessIterator, error) diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index ffb047edd01..8e2f772b231 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -30,6 +30,18 @@ var ( _ = abi.ConvertType ) +type FunctionsBillingConfig struct { + MaxCallbackGasLimit uint32 + FeedStalenessSeconds uint32 + GasOverheadBeforeCallback uint32 + GasOverheadAfterCallback uint32 + RequestTimeoutSeconds uint32 + DonFee *big.Int + MaxSupportedRequestDataVersion uint16 + FulfillmentGasPriceOverEstimationBP *big.Int + FallbackNativePerUnitLink *big.Int +} + type FunctionsResponseCommitment struct { AdminFee *big.Int Coordinator common.Address @@ -44,24 +56,12 @@ type FunctionsResponseCommitment struct { GasOverheadAfterCallback *big.Int } -type IFunctionsBillingConfig struct { - MaxCallbackGasLimit uint32 - FeedStalenessSeconds uint32 - GasOverheadBeforeCallback uint32 - GasOverheadAfterCallback uint32 - RequestTimeoutSeconds uint32 - DonFee *big.Int - MaxSupportedRequestDataVersion uint16 - FulfillmentGasPriceOverEstimationBP *big.Int - FallbackNativePerUnitLink *big.Int -} - type IFunctionsBillingRequestBilling struct { - SubscriptionId uint64 - Client common.Address - CallbackGasLimit uint32 - ExpectedGasPrice *big.Int - AdminFee *big.Int + SubscriptionId uint64 + Client common.Address + CallbackGasLimit uint32 + ExpectedGasPriceGwei *big.Int + AdminFee *big.Int } type IFunctionsCoordinatorRequest struct { @@ -76,15 +76,15 @@ type IFunctionsCoordinatorRequest struct { } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"indexed\":false,\"internalType\":\"structIFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structIFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005cd638038062005cd6833981016040819052620000349162000405565b828282828260013380600081620000925760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c557620000c5816200014a565b50505015156080526001600160a01b038216620000f557604051632530e88560e11b815260040160405180910390fd5b6001600160a01b03821660a0526200010d81620001f5565b5050600c80546001600160a01b039092166c01000000000000000000000000026001600160601b0390921691909117905550620006709350505050565b336001600160a01b03821603620001a45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000089565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000818060200190518101906200020d919062000522565b905060008161010001511362000240578061010001516040516321ea67b360e11b81526004016200008991815260200190565b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff16600160f01b026001600160f01b036001600160501b03909216600160a01b02600160a01b600160f01b031963ffffffff948516600160801b0216600160801b600160f01b03199585166c010000000000000000000000000263ffffffff60601b19978616680100000000000000000297909716600160401b600160801b0319998616640100000000026001600160401b0319909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517ffc10ed3768699b4370d710cd8ffbc7efdc5a691e42af93f2fe3d0ba7c33556589062000367908390620005dd565b60405180910390a15050565b80516001600160a01b03811681146200038b57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b60405161012081016001600160401b0381118282101715620003cc57620003cc62000390565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620003fd57620003fd62000390565b604052919050565b6000806000606084860312156200041b57600080fd5b620004268462000373565b602085810151919450906001600160401b03808211156200044657600080fd5b818701915087601f8301126200045b57600080fd5b81518181111562000470576200047062000390565b62000484601f8201601f19168501620003d2565b915080825288848285010111156200049b57600080fd5b60005b81811015620004bb5783810185015183820186015284016200049e565b50600084828401015250809450505050620004d96040850162000373565b90509250925092565b805163ffffffff811681146200038b57600080fd5b80516001600160501b03811681146200038b57600080fd5b805161ffff811681146200038b57600080fd5b600061012082840312156200053657600080fd5b62000540620003a6565b6200054b83620004e2565b81526200055b60208401620004e2565b60208201526200056e60408401620004e2565b60408201526200058160608401620004e2565b60608201526200059460808401620004e2565b6080820152620005a760a08401620004f7565b60a0820152620005ba60c084016200050f565b60c082015260e08381015190820152610100928301519281019290925250919050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a08301516200063c60a08401826001600160501b03169052565b5060c08301516200065360c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60805160a051615608620006ce600039600081816106cc01528181610aa701528181610cd50152818161101f015281816110fd0152818161188501528181611b1f015281816132f40152613a2a0152600061125601526156086000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381ff7048116100ee578063bdd7e88011610097578063d328a91e11610071578063d328a91e1461055b578063e3d0e71214610563578063e4ddcea614610576578063f2fde38b1461058c57600080fd5b8063bdd7e880146103f6578063c3f909d414610416578063d227d2451461054857600080fd5b80638da5cb5b116100c85780638da5cb5b1461039b578063afcb95d7146103c3578063b1dc65a4146103e357600080fd5b806381ff7048146102f857806385b214cf146103655780638cc6acce1461038857600080fd5b806366316d8d1161015b5780637f15e166116101355780637f15e166146102b557806380756031146102c857806381411834146102db57806381f1b938146102f057600080fd5b806366316d8d1461029257806379ba5097146102a55780637d480787146102ad57600080fd5b806326ceabac1161018c57806326ceabac146102445780632a905ccc14610257578063533989871461027c57600080fd5b8063083a5466146101b35780630e7ada39146101c8578063181f5a77146101fb575b600080fd5b6101c66101c1366004613cc9565b61059f565b005b6101db6101d6366004613f3d565b6105f4565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b6102376040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101f29190614072565b6101c661025236600461408c565b610622565b61025f6106c8565b6040516bffffffffffffffffffffffff90911681526020016101f2565b610284610784565b6040516101f29291906140fa565b6101c66102a036600461418a565b6109ab565b6101c6610b64565b6101c6610c66565b6101c66102c3366004613cc9565b610dbe565b6101c66102d63660046141c3565b610e0e565b6102e3610ec5565b6040516101f29190614218565b610237610f34565b61034260015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101f2565b61037861037336600461422b565b611005565b60405190151581526020016101f2565b6101c6610396366004614244565b6110e5565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101f2565b6040805160018152600060208201819052918101919091526060016101f2565b6101c66103f13660046142c6565b61115d565b61040961040436600461437d565b611814565b6040516101f291906144df565b61053b6040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090910461ffff1660c082015260095460e0820152600a5461010082015290565b6040516101f291906144ee565b61025f610556366004614582565b611b1b565b610237611ccd565b6101c661057136600461469b565b611d24565b61057e612750565b6040519081526020016101f2565b6101c661059a36600461408c565b612945565b6105a7612956565b60008190036105e2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105ef828483614801565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061066057503373ffffffffffffffffffffffffffffffffffffffff821614155b15610697576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e602052604081206106c591613c0e565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663c3f909d46040518163ffffffff1660e01b8152600401600060405180830381865afa158015610735573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261077b919081019061494d565b60200151905090565b606080600060068054806020026020016040519081016040528092919081815260200182805480156107ec57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116107c1575b505050505090506000815167ffffffffffffffff81111561080f5761080f613d0b565b60405190808252806020026020018201604052801561084257816020015b606081526020019060019003908161082d5790505b50905060005b82518110156109a1576000600e600085848151811061086957610869614a77565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002080546108b690614768565b80601f01602080910402602001604051908101604052809291908181526020018280546108e290614768565b801561092f5780601f106109045761010080835404028352916020019161092f565b820191906000526020600020905b81548152906001019060200180831161091257829003601f168201915b505050505090508051600003610971576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8083838151811061098457610984614a77565b6020026020010181905250508061099a90614ad5565b9050610848565b5090939092509050565b6109b36129d9565b806bffffffffffffffffffffffff166000036109ed5750336000908152600b60205260409020546bffffffffffffffffffffffff16610a47565b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610a47576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610a749084906bffffffffffffffffffffffff16614b0d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ac97f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610b4857600080fd5b505af1158015610b5c573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610bea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c6e612b84565b610c766129d9565b6000610c80610ec5565b905060005b8151811015610dba57336000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610d2157610d21614a77565b6020026020010151836040518363ffffffff1660e01b8152600401610d7692919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610d9057600080fd5b505af1158015610da4573d6000803e3d6000fd5b505050505080610db390614ad5565b9050610c85565b5050565b610dc6612956565b6000819003610e01576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105ef828483614801565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610e595750610e3833612b8c565b8015610e5957503373ffffffffffffffffffffffffffffffffffffffff8416145b610e8f576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e60205260409020610ebf828483614801565b50505050565b60606006805480602002602001604051908101604052809291908181526020018280548015610f2a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610eff575b5050505050905090565b6060600f8054610f4390614768565b9050600003610f7e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f8054610f8b90614768565b80601f0160208091040260200160405190810160405280929190818152602001828054610fb790614768565b8015610f2a5780601f10610fd957610100808354040283529160200191610f2a565b820191906000526020600020905b815481529060010190602001808311610fe757509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611076576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526007602052604090205461109157506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906110d49084815260200190565b60405180910390a15060015b919050565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611154576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6106c581612c75565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611244576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610be1565b6112528b8b8b8b8b8b612ec8565b60007f0000000000000000000000000000000000000000000000000000000000000000156112af576002826020015183604001516112909190614b32565b61129a9190614b7a565b6112a5906001614b32565b60ff1690506112c5565b60208201516112bf906001614b32565b60ff1690505b88811461132e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610be1565b888714611397576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610be1565b3360009081526004602090815260408083208151808301909252805460ff808216845292939192918401916101009091041660028111156113da576113da614b9c565b60028111156113eb576113eb614b9c565b905250905060028160200151600281111561140857611408614b9c565b14801561144f57506006816000015160ff168154811061142a5761142a614a77565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6114b5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610be1565b50505050506114c2613c48565b6000808a8a6040516114d5929190614bcb565b6040519081900381206114ec918e90602001614bdb565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b898110156117f657600060018489846020811061155557611555614a77565b61156291901a601b614b32565b8e8e8681811061157457611574614a77565b905060200201358d8d8781811061158d5761158d614a77565b90506020020135604051600081526020016040526040516115ca949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156115ec573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561166c5761166c614b9c565b600281111561167d5761167d614b9c565b905250925060018360200151600281111561169a5761169a614b9c565b14611701576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610be1565b8251600090879060ff16601f811061171b5761171b614a77565b602002015173ffffffffffffffffffffffffffffffffffffffff161461179d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610be1565b8086846000015160ff16601f81106117b7576117b7614a77565b73ffffffffffffffffffffffffffffffffffffffff90921660209290920201526117e2600186614b32565b945050806117ef90614ad5565b9050611536565b505050611807833383858e8e612f7f565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146118dc576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6118e96040830183614bef565b9050600003611923576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a001604052808460600160208101906119439190614c54565b67ffffffffffffffff1681526020908101906119619086018661408c565b73ffffffffffffffffffffffffffffffffffffffff16815260200161198c60e0860160c08701614c71565b63ffffffff1681523a60208201526040016119ae610100860160e08701614c8e565b6bffffffffffffffffffffffff1690529050611a1b6119d06040850185614bef565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611a159250505060a0860160808701614cab565b8361314d565b9150611a2a602084018461408c565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611a7a9190614c54565b611a8a6040890160208a0161408c565b611a9760408a018a614bef565b611aa760a08c0160808d01614cab565b60a08c0135611abc60e08e0160c08f01614c71565b8c604051602001611acd91906144df565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611b0d999897969594939291614cc8565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bbb57600080fd5b505afa158015611bcf573d6000803e3d6000fd5b505050620f42408311159050611c11576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c1b6106c8565b90506000611ca587878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805160a08101825267ffffffffffffffff8e16815233602082015263ffffffff8b1691810191909152606081018990526bffffffffffffffffffffffff8716608082015291506105f49050565b69ffffffffffffffffffff169050611cbf858583856136d3565b925050505b95945050505050565b6060600d8054611cdc90614768565b9050600003611d17576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d8054610f8b90614768565b855185518560ff16601f831115611d97576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610be1565b80600003611e01576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610be1565b818314611e8f576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610be1565b611e9a816003614d8c565b8311611f02576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610be1565b611f0a612956565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f51908861379b565b6005541561210657600554600090611f6b90600190614da3565b9050600060058281548110611f8257611f82614a77565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fbc57611fbc614a77565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061203c5761203c614db6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905560068054806120a5576120a5614db6565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f51915050565b60005b81515181101561256d576000600460008460000151848151811061212f5761212f614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561217957612179614b9c565b146121e0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610be1565b6040805180820190915260ff8216815260016020820152825180516004916000918590811061221157612211614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122b2576122b2614b9c565b0217905550600091506122c29050565b60046000846020015184815181106122dc576122dc614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561232657612326614b9c565b1461238d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610be1565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123c0576123c0614a77565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561246157612461614b9c565b02179055505082518051600592508390811061247f5761247f614a77565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124fb576124fb614a77565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061256581614ad5565b915050612109565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161262591849174010000000000000000000000000000000000000000900416614de5565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126844630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a001516137b4565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861273b988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614e02565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116838501526c01000000000000000000000000808304821660608501527001000000000000000000000000000000008304909116608084015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a0808501919091527e0100000000000000000000000000000000000000000000000000000000000090920461ffff1660c084015260095460e0840152600a54610100840152600c5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa158015612897573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128bb9190614eb2565b5093505092505080426128ce9190614da3565b836020015163ffffffff161080156128f057506000836020015163ffffffff16115b156129015750506101000151919050565b6000821361293e576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610be1565b5092915050565b61294d612956565b6106c58161385f565b60005473ffffffffffffffffffffffffffffffffffffffff1633146129d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610be1565b565b600c546bffffffffffffffffffffffff166000036129f357565b60006129fd610ec5565b90508051600003612a3a576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612a59916bffffffffffffffffffffffff16614f02565b905060005b8251811015612b255781600b6000858481518110612a7e57612a7e614a77565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612ae69190614f2d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612b1e90614ad5565b9050612a5e565b508151612b329082614f52565b600c8054600090612b529084906bffffffffffffffffffffffff16614b0d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6129d7612956565b6000806006805480602002602001604051908101604052809291908181526020018280548015612bf257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612bc7575b5050505050905060005b8151811015612c6b578373ffffffffffffffffffffffffffffffffffffffff16828281518110612c2e57612c2e614a77565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612c5b575060019392505050565b612c6481614ad5565b9050612bfc565b5060009392505050565b600081806020019051810190612c8b9190614f82565b9050600081610100015113612cd5578061010001516040517f43d4cf66000000000000000000000000000000000000000000000000000000008152600401610be191815260200190565b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff167e01000000000000000000000000000000000000000000000000000000000000027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff69ffffffffffffffffffff90921674010000000000000000000000000000000000000000027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff63ffffffff94851670010000000000000000000000000000000002167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff9585166c01000000000000000000000000027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff9786166801000000000000000002979097167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff998616640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517ffc10ed3768699b4370d710cd8ffbc7efdc5a691e42af93f2fe3d0ba7c335565890612ebc9083906144ee565b60405180910390a15050565b6000612ed5826020614d8c565b612ee0856020614d8c565b612eec8861014461502c565b612ef6919061502c565b612f00919061502c565b612f0b90600061502c565b9050368114612f76576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610be1565b50505050505050565b606080808080612f918688018861511a565b8451949950929750909550935091501580612fae57508351855114155b80612fbb57508251855114155b80612fc857508151855114155b80612fd557508051855114155b1561300c576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561313f5760006130a487838151811061302f5761302f614a77565b602002602001015187848151811061304957613049614a77565b602002602001015187858151811061306357613063614a77565b602002602001015187868151811061307d5761307d614a77565b602002602001015187878151811061309757613097614a77565b6020026020010151613954565b905060008160068111156130ba576130ba614b9c565b14806130d7575060018160068111156130d5576130d5614b9c565b145b1561312e578682815181106130ee576130ee614a77565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061313881614ad5565b905061300f565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015269ffffffffffffffffffff7401000000000000000000000000000000000000000083041660a082015261ffff7e01000000000000000000000000000000000000000000000000000000000000909204821660c0820181905260095460e0830152600a546101008301529091851611156132ba576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006132c686856105f4565b905060006132ee856040015186606001518469ffffffffffffffffffff1688608001516136d3565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa158015613390573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526133d6919081019061525b565b9050826bffffffffffffffffffffffff16816040015182600001516133fb9190614b0d565b6bffffffffffffffffffffffff161015613441576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff909116602482015260009184169063674603d090604401606060405180830381865afa1580156134c8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134ec919061532a565b50915050600061356f308a602001518b6000015185600161350d919061537c565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001886080015163ffffffff164261361f919061502c565b64ffffffffff1681526020018281526020018769ffffffffffffffffffff168152602001886040015163ffffffff1664ffffffffff168152602001886060015163ffffffff1664ffffffffff1681525097508760405160200161368291906144df565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555050505050509392505050565b6008546000908190869061370b9063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614de5565b6137159190614de5565b63ffffffff1690506000612710600860010154876137339190614d8c565b61373d919061539d565b613747908761502c565b9050600061375482613be8565b905060006137628483614d8c565b905060006137816bffffffffffffffffffffffff808916908a1661502c565b905061378d818361502c565b9a9950505050505050505050565b60006137a5610ec5565b511115610dba57610dba6129d9565b6000808a8a8a8a8a8a8a8a8a6040516020016137d8999897969594939291906153b1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036138de576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610be1565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808380602001905181019061396b919061545b565b90508060405160200161397e91906144df565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a81526007909352912054146139d0576006915050611cc4565b6000878152600760205260409020546139ed576002915050611cc4565b60006139f83a613be8565b90506000826101400151836101200151613a12919061552e565b613a239064ffffffffff1683614d8c565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288b8b8789610100015169ffffffffffffffffffff1688613a849190614f2d565b338b6040518763ffffffff1660e01b8152600401613aa79695949392919061554c565b60408051808303816000875af1158015613ac5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ae991906155c8565b90925090506000826006811115613b0257613b02614b9c565b1480613b1f57506001826006811115613b1d57613b1d614b9c565b145b15613bda5760008b815260076020526040812055613b3d8184614f2d565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100870151600c805469ffffffffffffffffffff90921693909291613bab91859116614f2d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613bf2612750565b613c0483670de0b6b3a7640000614d8c565b61061c919061539d565b508054613c1a90614768565b6000825580601f10613c2a575050565b601f0160209004906000526020600020908101906106c59190613c67565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613c7c5760008155600101613c68565b5090565b60008083601f840112613c9257600080fd5b50813567ffffffffffffffff811115613caa57600080fd5b602083019150836020828501011115613cc257600080fd5b9250929050565b60008060208385031215613cdc57600080fd5b823567ffffffffffffffff811115613cf357600080fd5b613cff85828601613c80565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b60405290565b6040516080810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b604051610120810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b60405160c0810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b604051610160810167ffffffffffffffff81118282101715613d5d57613d5d613d0b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613e3857613e38613d0b565b604052919050565b600082601f830112613e5157600080fd5b813567ffffffffffffffff811115613e6b57613e6b613d0b565b613e9c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613df1565b818152846020838601011115613eb157600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff811681146106c557600080fd5b80356110e081613ece565b73ffffffffffffffffffffffffffffffffffffffff811681146106c557600080fd5b63ffffffff811681146106c557600080fd5b6bffffffffffffffffffffffff811681146106c557600080fd5b60008082840360c0811215613f5157600080fd5b833567ffffffffffffffff811115613f6857600080fd5b613f7486828701613e40565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613fa757600080fd5b50613fb0613d3a565b6020840135613fbe81613ece565b81526040840135613fce81613eef565b60208201526060840135613fe181613f11565b60408201526080840135606082015260a0840135613ffe81613f23565b6080820152919491935090915050565b6000815180845260005b8181101561403457602081850181015186830182015201614018565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000614085602083018461400e565b9392505050565b60006020828403121561409e57600080fd5b813561408581613eef565b600081518084526020808501945080840160005b838110156140ef57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140bd565b509495945050505050565b60408152600061410d60408301856140a9565b6020838203818501528185518084528284019150828160051b85010183880160005b8381101561417b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe087840301855261416983835161400e565b9486019492509085019060010161412f565b50909998505050505050505050565b6000806040838503121561419d57600080fd5b82356141a881613eef565b915060208301356141b881613f23565b809150509250929050565b6000806000604084860312156141d857600080fd5b83356141e381613eef565b9250602084013567ffffffffffffffff8111156141ff57600080fd5b61420b86828701613c80565b9497909650939450505050565b60208152600061408560208301846140a9565b60006020828403121561423d57600080fd5b5035919050565b60006020828403121561425657600080fd5b813567ffffffffffffffff81111561426d57600080fd5b61427984828501613e40565b949350505050565b60008083601f84011261429357600080fd5b50813567ffffffffffffffff8111156142ab57600080fd5b6020830191508360208260051b8501011115613cc257600080fd5b60008060008060008060008060e0898b0312156142e257600080fd5b606089018a8111156142f357600080fd5b8998503567ffffffffffffffff8082111561430d57600080fd5b6143198c838d01613c80565b909950975060808b013591508082111561433257600080fd5b61433e8c838d01614281565b909750955060a08b013591508082111561435757600080fd5b506143648b828c01614281565b999c989b50969995989497949560c00135949350505050565b60006020828403121561438f57600080fd5b813567ffffffffffffffff8111156143a657600080fd5b8201610100818503121561408557600080fd5b80516bffffffffffffffffffffffff16825260208101516143f2602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604081015161441a604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614436606084018267ffffffffffffffff169052565b50608081015161444e608084018263ffffffff169052565b5060a081015161446e60a08401826bffffffffffffffffffffffff169052565b5060c081015161448760c084018264ffffffffff169052565b5060e081015160e0830152610100808201516144b08285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152610ebf565b610160810161061c82846143b9565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161454f60a084018269ffffffffffffffffffff169052565b5060c083015161456560c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60008060008060006080868803121561459a57600080fd5b85356145a581613ece565b9450602086013567ffffffffffffffff8111156145c157600080fd5b6145cd88828901613c80565b90955093505060408601356145e181613f11565b949793965091946060013592915050565b600067ffffffffffffffff82111561460c5761460c613d0b565b5060051b60200190565b600082601f83011261462757600080fd5b8135602061463c614637836145f2565b613df1565b82815260059290921b8401810191818101908684111561465b57600080fd5b8286015b8481101561467f57803561467281613eef565b835291830191830161465f565b509695505050505050565b803560ff811681146110e057600080fd5b60008060008060008060c087890312156146b457600080fd5b863567ffffffffffffffff808211156146cc57600080fd5b6146d88a838b01614616565b975060208901359150808211156146ee57600080fd5b6146fa8a838b01614616565b965061470860408a0161468a565b9550606089013591508082111561471e57600080fd5b61472a8a838b01613e40565b945061473860808a01613ee4565b935060a089013591508082111561474e57600080fd5b5061475b89828a01613e40565b9150509295509295509295565b600181811c9082168061477c57607f821691505b6020821081036147b5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105ef57600081815260208120601f850160051c810160208610156147e25750805b601f850160051c820191505b81811015610b5c578281556001016147ee565b67ffffffffffffffff83111561481957614819613d0b565b61482d836148278354614768565b836147bb565b6000601f84116001811461487f57600085156148495750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614915565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156148ce57868501358255602094850194600190920191016148ae565b5086821015614909577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b61ffff811681146106c557600080fd5b80516110e08161491c565b80516110e081613f23565b80516110e081613f11565b6000602080838503121561496057600080fd5b825167ffffffffffffffff8082111561497857600080fd5b908401906080828703121561498c57600080fd5b614994613d63565b825161499f8161491c565b8152828401516149ae81613f23565b8185015260408301517fffffffff00000000000000000000000000000000000000000000000000000000811681146149e557600080fd5b60408201526060830151828111156149fc57600080fd5b80840193505086601f840112614a1157600080fd5b82519150614a21614637836145f2565b82815260059290921b83018401918481019088841115614a4057600080fd5b938501935b83851015614a67578451614a5881613f11565b82529385019390850190614a45565b6060830152509695505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614b0657614b06614aa6565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561293e5761293e614aa6565b60ff818116838216019081111561061c5761061c614aa6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614b8d57614b8d614b4b565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614c2457600080fd5b83018035915067ffffffffffffffff821115614c3f57600080fd5b602001915036819003821315613cc257600080fd5b600060208284031215614c6657600080fd5b813561408581613ece565b600060208284031215614c8357600080fd5b813561408581613f11565b600060208284031215614ca057600080fd5b813561408581613f23565b600060208284031215614cbd57600080fd5b81356140858161491c565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614d6560c085018763ffffffff169052565b818482030160e0850152614d7b8282018661400e565b9d9c50505050505050505050505050565b808202811582820484141761061c5761061c614aa6565b8181038181111561061c5761061c614aa6565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561293e5761293e614aa6565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614e328184018a6140a9565b90508281036080840152614e4681896140a9565b905060ff871660a084015282810360c0840152614e63818761400e565b905067ffffffffffffffff851660e0840152828103610100840152614e88818561400e565b9c9b505050505050505050505050565b805169ffffffffffffffffffff811681146110e057600080fd5b600080600080600060a08688031215614eca57600080fd5b614ed386614e98565b9450602086015193506040860151925060608601519150614ef660808701614e98565b90509295509295909350565b60006bffffffffffffffffffffffff80841680614f2157614f21614b4b565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561293e5761293e614aa6565b6bffffffffffffffffffffffff818116838216028082169190828114614f7a57614f7a614aa6565b505092915050565b60006101208284031215614f9557600080fd5b614f9d613d86565b614fa683614942565b8152614fb460208401614942565b6020820152614fc560408401614942565b6040820152614fd660608401614942565b6060820152614fe760808401614942565b6080820152614ff860a08401614e98565b60a082015261500960c0840161492c565b60c082015260e08381015190820152610100928301519281019290925250919050565b8082018082111561061c5761061c614aa6565b600082601f83011261505057600080fd5b81356020615060614637836145f2565b82815260059290921b8401810191818101908684111561507f57600080fd5b8286015b8481101561467f5780358352918301918301615083565b600082601f8301126150ab57600080fd5b813560206150bb614637836145f2565b82815260059290921b840181019181810190868411156150da57600080fd5b8286015b8481101561467f57803567ffffffffffffffff8111156150fe5760008081fd5b61510c8986838b0101613e40565b8452509183019183016150de565b600080600080600060a0868803121561513257600080fd5b853567ffffffffffffffff8082111561514a57600080fd5b61515689838a0161503f565b9650602088013591508082111561516c57600080fd5b61517889838a0161509a565b9550604088013591508082111561518e57600080fd5b61519a89838a0161509a565b945060608801359150808211156151b057600080fd5b6151bc89838a0161509a565b935060808801359150808211156151d257600080fd5b506151df8882890161509a565b9150509295509295909350565b80516110e081613eef565b600082601f83011261520857600080fd5b81516020615218614637836145f2565b82815260059290921b8401810191818101908684111561523757600080fd5b8286015b8481101561467f57805161524e81613eef565b835291830191830161523b565b60006020828403121561526d57600080fd5b815167ffffffffffffffff8082111561528557600080fd5b9083019060c0828603121561529957600080fd5b6152a1613daa565b82516152ac81613f23565b815260208301516152bc81613eef565b602082015260408301516152cf81613f23565b60408201526152e0606084016151ec565b60608201526080830151828111156152f757600080fd5b615303878286016151f7565b60808301525060a083015160a082015280935050505092915050565b80516110e081613ece565b60008060006060848603121561533f57600080fd5b8351801515811461534f57600080fd5b602085015190935061536081613ece565b604085015190925061537181613ece565b809150509250925092565b67ffffffffffffffff81811683821601908082111561293e5761293e614aa6565b6000826153ac576153ac614b4b565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526153f88285018b6140a9565b9150838203608085015261540c828a6140a9565b915060ff881660a085015283820360c0850152615429828861400e565b90861660e08501528381036101008501529050614e88818561400e565b805164ffffffffff811681146110e057600080fd5b6000610160828403121561546e57600080fd5b615476613dcd565b61547f83614937565b815261548d602084016151ec565b602082015261549e604084016151ec565b60408201526154af6060840161531f565b60608201526154c060808401614942565b60808201526154d160a08401614937565b60a08201526154e260c08401615446565b60c082015260e083015160e08201526101006154ff818501614e98565b90820152610120615511848201615446565b90820152610140615523848201615446565b908201529392505050565b64ffffffffff81811683821601908082111561293e5761293e614aa6565b60006102008083526155608184018a61400e565b90508281036020840152615574818961400e565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506155bd905060a08301846143b9565b979650505050505050565b600080604083850312156155db57600080fd5b8251600781106155ea57600080fd5b60208401519092506141b881613f2356fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPriceGwei\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b5060405162005a4138038062005a41833981016040819052620000349162000455565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600c80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b505050505050620005de565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f562000358565b60008161010001511362000226578061010001516040516321ea67b360e11b81526004016200008891815260200190565b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff16600160f01b026001600160f01b036001600160501b03909216600160a01b02600160a01b600160f01b031963ffffffff948516600160801b0216600160801b600160f01b03199585166c010000000000000000000000000263ffffffff60601b19978616680100000000000000000297909716600160401b600160801b0319998616640100000000026001600160401b0319909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517f65e5bc7ff6133456adf04bcd6ececcf049fc4117102e1ac9064d3b6570398403906200034d9083906200054b565b60405180910390a150565b6200036262000364565b565b6000546001600160a01b03163314620003625760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003d857600080fd5b919050565b60405161012081016001600160401b03811182821017156200040f57634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003d857600080fd5b80516001600160501b0381168114620003d857600080fd5b805161ffff81168114620003d857600080fd5b60008060008385036101608112156200046d57600080fd5b6200047885620003c0565b935061012080601f19830112156200048f57600080fd5b62000499620003dd565b9150620004a96020870162000415565b8252620004b96040870162000415565b6020830152620004cc6060870162000415565b6040830152620004df6080870162000415565b6060830152620004f260a0870162000415565b60808301526200050560c087016200042a565b60a08301526200051860e0870162000442565b60c08301526101008681015160e084015290860151908201529150620005426101408501620003c0565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005aa60a08401826001600160501b03169052565b5060c0830151620005c160c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60805160a05161540c62000635600039600081816106cc01528181610ccc01528181610ef50152818161123f01528181611a2d01528181611cc701528181613249015261397f015260006113fe015261540c6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381f1b938116100ee578063bdd7e88011610097578063d328a91e11610071578063d328a91e1461055b578063e3d0e71214610563578063e4ddcea614610576578063f2fde38b1461058c57600080fd5b8063bdd7e880146103f6578063c3f909d414610416578063d227d2451461054857600080fd5b80638da5cb5b116100c85780638da5cb5b1461039b578063afcb95d7146103c3578063b1dc65a4146103e357600080fd5b806381f1b9381461030357806381ff70481461030b57806385b214cf1461037857600080fd5b8063533989871161015b5780637d480787116101355780637d480787146102c05780637f15e166146102c857806380756031146102db57806381411834146102ee57600080fd5b8063533989871461028f57806366316d8d146102a557806379ba5097146102b857600080fd5b806326ceabac1161018c57806326ceabac146102445780632a905ccc1461025757806345ff86b51461027c57600080fd5b8063083a5466146101b35780630e7ada39146101c8578063181f5a77146101fb575b600080fd5b6101c66101c1366004613c1e565b61059f565b005b6101db6101d6366004613e7a565b6105f4565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b6102376040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101f29190613faf565b6101c6610252366004613fc9565b610622565b61025f6106c8565b6040516bffffffffffffffffffffffff90911681526020016101f2565b6101c661028a36600461401b565b61075e565b6102976109a9565b6040516101f2929190614116565b6101c66102b33660046141a6565b610bd0565b6101c6610d89565b6101c6610e86565b6101c66102d6366004613c1e565b610fde565b6101c66102e93660046141df565b61102e565b6102f66110e5565b6040516101f29190614234565b610237611154565b61035560015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101f2565b61038b610386366004614247565b611225565b60405190151581526020016101f2565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101f2565b6040805160018152600060208201819052918101919091526060016101f2565b6101c66103f13660046142a5565b611305565b61040961040436600461435c565b6119bc565b6040516101f291906144be565b61053b6040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090910461ffff1660c082015260095460e0820152600a5461010082015290565b6040516101f291906144cd565b61025f610556366004614561565b611cc3565b610237611e75565b6101c661057136600461467a565b611ecc565b61057e6128f8565b6040519081526020016101f2565b6101c661059a366004613fc9565b612aed565b6105a7612afe565b60008190036105e2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105ef8284836147e0565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061066057503373ffffffffffffffffffffffffffffffffffffffff821614155b15610697576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e602052604081206106c591613b63565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610735573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107599190614906565b905090565b610766612b81565b6000816101000151136107b7578061010001516040517f43d4cf660000000000000000000000000000000000000000000000000000000081526004016107ae91815260200190565b60405180910390fd5b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff167e01000000000000000000000000000000000000000000000000000000000000027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff69ffffffffffffffffffff90921674010000000000000000000000000000000000000000027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff63ffffffff94851670010000000000000000000000000000000002167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff9585166c01000000000000000000000000027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff9786166801000000000000000002979097167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff998616640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517f65e5bc7ff6133456adf04bcd6ececcf049fc4117102e1ac9064d3b65703984039061099e9083906144cd565b60405180910390a150565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a1157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109e6575b505050505090506000815167ffffffffffffffff811115610a3457610a34613c60565b604051908082528060200260200182016040528015610a6757816020015b6060815260200190600190039081610a525790505b50905060005b8251811015610bc6576000600e6000858481518110610a8e57610a8e614923565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610adb90614747565b80601f0160208091040260200160405190810160405280929190818152602001828054610b0790614747565b8015610b545780601f10610b2957610100808354040283529160200191610b54565b820191906000526020600020905b815481529060010190602001808311610b3757829003601f168201915b505050505090508051600003610b96576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610ba957610ba9614923565b60200260200101819052505080610bbf90614981565b9050610a6d565b5090939092509050565b610bd8612b89565b806bffffffffffffffffffffffff16600003610c125750336000908152600b60205260409020546bffffffffffffffffffffffff16610c6c565b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610c6c576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610c999084906bffffffffffffffffffffffff166149b9565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610cee7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610d6d57600080fd5b505af1158015610d81573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610e0a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107ae565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610e8e612b81565b610e96612b89565b6000610ea06110e5565b905060005b8151811015610fda57336000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610f4157610f41614923565b6020026020010151836040518363ffffffff1660e01b8152600401610f9692919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610fb057600080fd5b505af1158015610fc4573d6000803e3d6000fd5b505050505080610fd390614981565b9050610ea5565b5050565b610fe6612afe565b6000819003611021576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105ef8284836147e0565b60005473ffffffffffffffffffffffffffffffffffffffff16331480611079575061105833612d34565b801561107957503373ffffffffffffffffffffffffffffffffffffffff8416145b6110af576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e602052604090206110df8284836147e0565b50505050565b6060600680548060200260200160405190810160405280929190818152602001828054801561114a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161111f575b5050505050905090565b6060600f805461116390614747565b905060000361119e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f80546111ab90614747565b80601f01602080910402602001604051908101604052809291908181526020018280546111d790614747565b801561114a5780601f106111f95761010080835404028352916020019161114a565b820191906000526020600020905b81548152906001019060200180831161120757509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611296576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600760205260409020546112b157506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906112f49084815260200190565b60405180910390a15060015b919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146113ec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d61746368000000000000000000000060448201526064016107ae565b6113fa8b8b8b8b8b8b612e1d565b60007f0000000000000000000000000000000000000000000000000000000000000000156114575760028260200151836040015161143891906149de565b6114429190614a26565b61144d9060016149de565b60ff16905061146d565b60208201516114679060016149de565b60ff1690505b8881146114d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e61747572657300000000000060448201526064016107ae565b88871461153f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e000060448201526064016107ae565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561158257611582614a48565b600281111561159357611593614a48565b90525090506002816020015160028111156115b0576115b0614a48565b1480156115f757506006816000015160ff16815481106115d2576115d2614923565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b61165d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d6974746572000000000000000060448201526064016107ae565b505050505061166a613b9d565b6000808a8a60405161167d929190614a77565b604051908190038120611694918e90602001614a87565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561199e5760006001848984602081106116fd576116fd614923565b61170a91901a601b6149de565b8e8e8681811061171c5761171c614923565b905060200201358d8d8781811061173557611735614923565b9050602002013560405160008152602001604052604051611772949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611794573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561181457611814614a48565b600281111561182557611825614a48565b905250925060018360200151600281111561184257611842614a48565b146118a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e000060448201526064016107ae565b8251600090879060ff16601f81106118c3576118c3614923565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611945576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e617475726500000000000000000000000060448201526064016107ae565b8086846000015160ff16601f811061195f5761195f614923565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261198a6001866149de565b9450508061199790614981565b90506116de565b5050506119af833383858e8e612ed4565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611a84576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a916040830183614a9b565b9050600003611acb576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a00160405280846060016020810190611aeb9190614b00565b67ffffffffffffffff168152602090810190611b0990860186613fc9565b73ffffffffffffffffffffffffffffffffffffffff168152602001611b3460e0860160c08701614b1d565b63ffffffff1681523a6020820152604001611b56610100860160e08701614b3a565b6bffffffffffffffffffffffff1690529050611bc3611b786040850185614a9b565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bbd9250505060a0860160808701614b57565b836130a2565b9150611bd26020840184613fc9565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611c229190614b00565b611c326040890160208a01613fc9565b611c3f60408a018a614a9b565b611c4f60a08c0160808d01614b57565b60a08c0135611c6460e08e0160c08f01614b1d565b8c604051602001611c7591906144be565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611cb5999897969594939291614b72565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611d6357600080fd5b505afa158015611d77573d6000803e3d6000fd5b505050620f42408311159050611db9576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611dc36106c8565b90506000611e4d87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805160a08101825267ffffffffffffffff8e16815233602082015263ffffffff8b1691810191909152606081018990526bffffffffffffffffffffffff8716608082015291506105f49050565b69ffffffffffffffffffff169050611e6785858385613628565b925050505b95945050505050565b6060600d8054611e8490614747565b9050600003611ebf576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d80546111ab90614747565b855185518560ff16601f831115611f3f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e6572730000000000000000000000000000000060448201526064016107ae565b80600003611fa9576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f736974697665000000000000000000000000000060448201526064016107ae565b818314612037576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e0000000000000000000000000000000000000000000000000000000060648201526084016107ae565b612042816003614c36565b83116120aa576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f2068696768000000000000000060448201526064016107ae565b6120b2612afe565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a08101869052906120f990886136f0565b600554156122ae5760055460009061211390600190614c4d565b905060006005828154811061212a5761212a614923565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061216457612164614923565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000908116909155929091168084529220805490911690556005805491925090806121e4576121e4614c60565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061224d5761224d614c60565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120f9915050565b60005b81515181101561271557600060046000846000015184815181106122d7576122d7614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561232157612321614a48565b14612388576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e6572206164647265737300000000000000000060448201526064016107ae565b6040805180820190915260ff821681526001602082015282518051600491600091859081106123b9576123b9614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561245a5761245a614a48565b02179055506000915061246a9050565b600460008460200151848151811061248457612484614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156124ce576124ce614a48565b14612535576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d697474657220616464726573730000000060448201526064016107ae565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061256857612568614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561260957612609614a48565b02179055505082518051600592508390811061262757612627614923565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106126a3576126a3614923565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061270d81614981565b9150506122b1565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff43811682029290921780855592048116929182916014916127cd91849174010000000000000000000000000000000000000000900416614c8f565b92506101000a81548163ffffffff021916908363ffffffff16021790555061282c4630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613709565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05986128e3988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614cac565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116838501526c01000000000000000000000000808304821660608501527001000000000000000000000000000000008304909116608084015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a0808501919091527e0100000000000000000000000000000000000000000000000000000000000090920461ffff1660c084015260095460e0840152600a54610100840152600c5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa158015612a3f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a639190614d4d565b509350509250508042612a769190614c4d565b836020015163ffffffff16108015612a9857506000836020015163ffffffff16115b15612aa95750506101000151919050565b60008213612ae6576040517f43d4cf66000000000000000000000000000000000000000000000000000000008152600481018390526024016107ae565b5092915050565b612af5612afe565b6106c5816137b4565b60005473ffffffffffffffffffffffffffffffffffffffff163314612b7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107ae565b565b612b7f612afe565b600c546bffffffffffffffffffffffff16600003612ba357565b6000612bad6110e5565b90508051600003612bea576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612c09916bffffffffffffffffffffffff16614da5565b905060005b8251811015612cd55781600b6000858481518110612c2e57612c2e614923565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612c969190614dd0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612cce90614981565b9050612c0e565b508151612ce29082614df5565b600c8054600090612d029084906bffffffffffffffffffffffff166149b9565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612d9a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d6f575b5050505050905060005b8151811015612e13578373ffffffffffffffffffffffffffffffffffffffff16828281518110612dd657612dd6614923565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612e03575060019392505050565b612e0c81614981565b9050612da4565b5060009392505050565b6000612e2a826020614c36565b612e35856020614c36565b612e4188610144614e25565b612e4b9190614e25565b612e559190614e25565b612e60906000614e25565b9050368114612ecb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d61746368000000000000000060448201526064016107ae565b50505050505050565b606080808080612ee686880188614f13565b8451949950929750909550935091501580612f0357508351855114155b80612f1057508251855114155b80612f1d57508151855114155b80612f2a57508051855114155b15612f61576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8551811015613094576000612ff9878381518110612f8457612f84614923565b6020026020010151878481518110612f9e57612f9e614923565b6020026020010151878581518110612fb857612fb8614923565b6020026020010151878681518110612fd257612fd2614923565b6020026020010151878781518110612fec57612fec614923565b60200260200101516138a9565b9050600081600681111561300f5761300f614a48565b148061302c5750600181600681111561302a5761302a614a48565b145b156130835786828151811061304357613043614923565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061308d81614981565b9050612f64565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015269ffffffffffffffffffff7401000000000000000000000000000000000000000083041660a082015261ffff7e01000000000000000000000000000000000000000000000000000000000000909204821660c0820181905260095460e0830152600a5461010083015290918516111561320f576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061321b86856105f4565b90506000613243856040015186606001518469ffffffffffffffffffff168860800151613628565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa1580156132e5573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261332b9190810190615054565b9050826bffffffffffffffffffffffff168160400151826000015161335091906149b9565b6bffffffffffffffffffffffff161015613396576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff909116602482015260009184169063674603d090604401606060405180830381865afa15801561341d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134419190615123565b5091505060006134c4308a602001518b600001518560016134629190615175565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001886080015163ffffffff16426135749190614e25565b64ffffffffff1681526020018281526020018769ffffffffffffffffffff168152602001886040015163ffffffff1664ffffffffff168152602001886060015163ffffffff1664ffffffffff168152509750876040516020016135d791906144be565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555050505050509392505050565b600854600090819086906136609063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c8f565b61366a9190614c8f565b63ffffffff1690506000612710600860010154876136889190614c36565b6136929190615196565b61369c9087614e25565b905060006136a982613b3d565b905060006136b78483614c36565b905060006136d66bffffffffffffffffffffffff808916908a16614e25565b90506136e28183614e25565b9a9950505050505050505050565b60006136fa6110e5565b511115610fda57610fda612b89565b6000808a8a8a8a8a8a8a8a8a60405160200161372d999897969594939291906151aa565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613833576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107ae565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906138c0919061525f565b9050806040516020016138d391906144be565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600790935291205414613925576006915050611e6c565b600087815260076020526040902054613942576002915050611e6c565b600061394d3a613b3d565b905060008261014001518361012001516139679190615332565b6139789064ffffffffff1683614c36565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288b8b8789610100015169ffffffffffffffffffff16886139d99190614dd0565b338b6040518763ffffffff1660e01b81526004016139fc96959493929190615350565b60408051808303816000875af1158015613a1a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3e91906153cc565b90925090506000826006811115613a5757613a57614a48565b1480613a7457506001826006811115613a7257613a72614a48565b145b15613b2f5760008b815260076020526040812055613a928184614dd0565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100870151600c805469ffffffffffffffffffff90921693909291613b0091859116614dd0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613b476128f8565b613b5983670de0b6b3a7640000614c36565b61061c9190615196565b508054613b6f90614747565b6000825580601f10613b7f575050565b601f0160209004906000526020600020908101906106c59190613bbc565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613bd15760008155600101613bbd565b5090565b60008083601f840112613be757600080fd5b50813567ffffffffffffffff811115613bff57600080fd5b602083019150836020828501011115613c1757600080fd5b9250929050565b60008060208385031215613c3157600080fd5b823567ffffffffffffffff811115613c4857600080fd5b613c5485828601613bd5565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613cb257613cb2613c60565b60405290565b604051610120810167ffffffffffffffff81118282101715613cb257613cb2613c60565b60405160c0810167ffffffffffffffff81118282101715613cb257613cb2613c60565b604051610160810167ffffffffffffffff81118282101715613cb257613cb2613c60565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d6a57613d6a613c60565b604052919050565b600082601f830112613d8357600080fd5b813567ffffffffffffffff811115613d9d57613d9d613c60565b613dce60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613d23565b818152846020838601011115613de357600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff811681146106c557600080fd5b803561130081613e00565b73ffffffffffffffffffffffffffffffffffffffff811681146106c557600080fd5b63ffffffff811681146106c557600080fd5b803561130081613e43565b6bffffffffffffffffffffffff811681146106c557600080fd5b60008082840360c0811215613e8e57600080fd5b833567ffffffffffffffff811115613ea557600080fd5b613eb186828701613d72565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613ee457600080fd5b50613eed613c8f565b6020840135613efb81613e00565b81526040840135613f0b81613e21565b60208201526060840135613f1e81613e43565b60408201526080840135606082015260a0840135613f3b81613e60565b6080820152919491935090915050565b6000815180845260005b81811015613f7157602081850181015186830182015201613f55565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613fc26020830184613f4b565b9392505050565b600060208284031215613fdb57600080fd5b8135613fc281613e21565b69ffffffffffffffffffff811681146106c557600080fd5b803561130081613fe6565b803561ffff8116811461130057600080fd5b6000610120828403121561402e57600080fd5b614036613cb8565b61403f83613e55565b815261404d60208401613e55565b602082015261405e60408401613e55565b604082015261406f60608401613e55565b606082015261408060808401613e55565b608082015261409160a08401613ffe565b60a08201526140a260c08401614009565b60c082015260e08381013590820152610100928301359281019290925250919050565b600081518084526020808501945080840160005b8381101561410b57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140d9565b509495945050505050565b60408152600061412960408301856140c5565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614197577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614185838351613f4b565b9486019492509085019060010161414b565b50909998505050505050505050565b600080604083850312156141b957600080fd5b82356141c481613e21565b915060208301356141d481613e60565b809150509250929050565b6000806000604084860312156141f457600080fd5b83356141ff81613e21565b9250602084013567ffffffffffffffff81111561421b57600080fd5b61422786828701613bd5565b9497909650939450505050565b602081526000613fc260208301846140c5565b60006020828403121561425957600080fd5b5035919050565b60008083601f84011261427257600080fd5b50813567ffffffffffffffff81111561428a57600080fd5b6020830191508360208260051b8501011115613c1757600080fd5b60008060008060008060008060e0898b0312156142c157600080fd5b606089018a8111156142d257600080fd5b8998503567ffffffffffffffff808211156142ec57600080fd5b6142f88c838d01613bd5565b909950975060808b013591508082111561431157600080fd5b61431d8c838d01614260565b909750955060a08b013591508082111561433657600080fd5b506143438b828c01614260565b999c989b50969995989497949560c00135949350505050565b60006020828403121561436e57600080fd5b813567ffffffffffffffff81111561438557600080fd5b82016101008185031215613fc257600080fd5b80516bffffffffffffffffffffffff16825260208101516143d1602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408101516143f9604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614415606084018267ffffffffffffffff169052565b50608081015161442d608084018263ffffffff169052565b5060a081015161444d60a08401826bffffffffffffffffffffffff169052565b5060c081015161446660c084018264ffffffffff169052565b5060e081015160e08301526101008082015161448f8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff8116848301526110df565b610160810161061c8284614398565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161452e60a084018269ffffffffffffffffffff169052565b5060c083015161454460c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60008060008060006080868803121561457957600080fd5b853561458481613e00565b9450602086013567ffffffffffffffff8111156145a057600080fd5b6145ac88828901613bd5565b90955093505060408601356145c081613e43565b949793965091946060013592915050565b600067ffffffffffffffff8211156145eb576145eb613c60565b5060051b60200190565b600082601f83011261460657600080fd5b8135602061461b614616836145d1565b613d23565b82815260059290921b8401810191818101908684111561463a57600080fd5b8286015b8481101561465e57803561465181613e21565b835291830191830161463e565b509695505050505050565b803560ff8116811461130057600080fd5b60008060008060008060c0878903121561469357600080fd5b863567ffffffffffffffff808211156146ab57600080fd5b6146b78a838b016145f5565b975060208901359150808211156146cd57600080fd5b6146d98a838b016145f5565b96506146e760408a01614669565b955060608901359150808211156146fd57600080fd5b6147098a838b01613d72565b945061471760808a01613e16565b935060a089013591508082111561472d57600080fd5b5061473a89828a01613d72565b9150509295509295509295565b600181811c9082168061475b57607f821691505b602082108103614794577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105ef57600081815260208120601f850160051c810160208610156147c15750805b601f850160051c820191505b81811015610d81578281556001016147cd565b67ffffffffffffffff8311156147f8576147f8613c60565b61480c836148068354614747565b8361479a565b6000601f84116001811461485e57600085156148285750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556148f4565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156148ad578685013582556020948501946001909201910161488d565b50868210156148e8577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b805161130081613e60565b60006020828403121561491857600080fd5b8151613fc281613e60565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036149b2576149b2614952565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115612ae657612ae6614952565b60ff818116838216019081111561061c5761061c614952565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a3957614a396149f7565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614ad057600080fd5b83018035915067ffffffffffffffff821115614aeb57600080fd5b602001915036819003821315613c1757600080fd5b600060208284031215614b1257600080fd5b8135613fc281613e00565b600060208284031215614b2f57600080fd5b8135613fc281613e43565b600060208284031215614b4c57600080fd5b8135613fc281613e60565b600060208284031215614b6957600080fd5b613fc282614009565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c0f60c085018763ffffffff169052565b818482030160e0850152614c2582820186613f4b565b9d9c50505050505050505050505050565b808202811582820484141761061c5761061c614952565b8181038181111561061c5761061c614952565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115612ae657612ae6614952565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cdc8184018a6140c5565b90508281036080840152614cf081896140c5565b905060ff871660a084015282810360c0840152614d0d8187613f4b565b905067ffffffffffffffff851660e0840152828103610100840152614d328185613f4b565b9c9b505050505050505050505050565b805161130081613fe6565b600080600080600060a08688031215614d6557600080fd5b8551614d7081613fe6565b809550506020860151935060408601519250606086015191506080860151614d9781613fe6565b809150509295509295909350565b60006bffffffffffffffffffffffff80841680614dc457614dc46149f7565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115612ae657612ae6614952565b6bffffffffffffffffffffffff818116838216028082169190828114614e1d57614e1d614952565b505092915050565b8082018082111561061c5761061c614952565b600082601f830112614e4957600080fd5b81356020614e59614616836145d1565b82815260059290921b84018101918181019086841115614e7857600080fd5b8286015b8481101561465e5780358352918301918301614e7c565b600082601f830112614ea457600080fd5b81356020614eb4614616836145d1565b82815260059290921b84018101918181019086841115614ed357600080fd5b8286015b8481101561465e57803567ffffffffffffffff811115614ef75760008081fd5b614f058986838b0101613d72565b845250918301918301614ed7565b600080600080600060a08688031215614f2b57600080fd5b853567ffffffffffffffff80821115614f4357600080fd5b614f4f89838a01614e38565b96506020880135915080821115614f6557600080fd5b614f7189838a01614e93565b95506040880135915080821115614f8757600080fd5b614f9389838a01614e93565b94506060880135915080821115614fa957600080fd5b614fb589838a01614e93565b93506080880135915080821115614fcb57600080fd5b50614fd888828901614e93565b9150509295509295909350565b805161130081613e21565b600082601f83011261500157600080fd5b81516020615011614616836145d1565b82815260059290921b8401810191818101908684111561503057600080fd5b8286015b8481101561465e57805161504781613e21565b8352918301918301615034565b60006020828403121561506657600080fd5b815167ffffffffffffffff8082111561507e57600080fd5b9083019060c0828603121561509257600080fd5b61509a613cdc565b82516150a581613e60565b815260208301516150b581613e21565b602082015260408301516150c881613e60565b60408201526150d960608401614fe5565b60608201526080830151828111156150f057600080fd5b6150fc87828601614ff0565b60808301525060a083015160a082015280935050505092915050565b805161130081613e00565b60008060006060848603121561513857600080fd5b8351801515811461514857600080fd5b602085015190935061515981613e00565b604085015190925061516a81613e00565b809150509250925092565b67ffffffffffffffff818116838216019080821115612ae657612ae6614952565b6000826151a5576151a56149f7565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151f18285018b6140c5565b91508382036080850152615205828a6140c5565b915060ff881660a085015283820360c08501526152228288613f4b565b90861660e08501528381036101008501529050614d328185613f4b565b805161130081613e43565b805164ffffffffff8116811461130057600080fd5b6000610160828403121561527257600080fd5b61527a613cff565b615283836148fb565b815261529160208401614fe5565b60208201526152a260408401614fe5565b60408201526152b360608401615118565b60608201526152c46080840161523f565b60808201526152d560a084016148fb565b60a08201526152e660c0840161524a565b60c082015260e083015160e0820152610100615303818501614d42565b9082015261012061531584820161524a565b9082015261014061532784820161524a565b908201529392505050565b64ffffffffff818116838216019080821115612ae657612ae6614952565b60006102008083526153648184018a613f4b565b905082810360208401526153788189613f4b565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153c1905060a0830184614398565b979650505050505050565b600080604083850312156153df57600080fd5b8251600781106153ee57600080fd5b60208401519092506141d481613e6056fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI var FunctionsCoordinatorBin = FunctionsCoordinatorMetaData.Bin -func DeployFunctionsCoordinator(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address, config []byte, linkToNativeFeed common.Address) (common.Address, *types.Transaction, *FunctionsCoordinator, error) { +func DeployFunctionsCoordinator(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address, config FunctionsBillingConfig, linkToNativeFeed common.Address) (common.Address, *types.Transaction, *FunctionsCoordinator, error) { parsed, err := FunctionsCoordinatorMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -283,25 +283,25 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetAllNodePublic return _FunctionsCoordinator.Contract.GetAllNodePublicKeys(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.CallOpts) (IFunctionsBillingConfig, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetConfig(opts *bind.CallOpts) (FunctionsBillingConfig, error) { var out []interface{} err := _FunctionsCoordinator.contract.Call(opts, &out, "getConfig") if err != nil { - return *new(IFunctionsBillingConfig), err + return *new(FunctionsBillingConfig), err } - out0 := *abi.ConvertType(out[0], new(IFunctionsBillingConfig)).(*IFunctionsBillingConfig) + out0 := *abi.ConvertType(out[0], new(FunctionsBillingConfig)).(*FunctionsBillingConfig) return out0, err } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfig() (IFunctionsBillingConfig, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetConfig() (FunctionsBillingConfig, error) { return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (IFunctionsBillingConfig, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (FunctionsBillingConfig, error) { return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) } @@ -665,15 +665,15 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) Transmit(rep return _FunctionsCoordinator.Contract.Transmit(&_FunctionsCoordinator.TransactOpts, reportContext, report, rs, ss, rawVs) } -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) UpdateConfig(opts *bind.TransactOpts, config FunctionsBillingConfig) (*types.Transaction, error) { return _FunctionsCoordinator.contract.Transact(opts, "updateConfig", config) } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) UpdateConfig(config []byte) (*types.Transaction, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorSession) UpdateConfig(config FunctionsBillingConfig) (*types.Transaction, error) { return _FunctionsCoordinator.Contract.UpdateConfig(&_FunctionsCoordinator.TransactOpts, config) } -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) UpdateConfig(config []byte) (*types.Transaction, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) UpdateConfig(config FunctionsBillingConfig) (*types.Transaction, error) { return _FunctionsCoordinator.Contract.UpdateConfig(&_FunctionsCoordinator.TransactOpts, config) } @@ -794,8 +794,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseCommitmentDelete return event, nil } -type FunctionsCoordinatorConfigChangedIterator struct { - Event *FunctionsCoordinatorConfigChanged +type FunctionsCoordinatorConfigSetIterator struct { + Event *FunctionsCoordinatorConfigSet contract *bind.BoundContract event string @@ -806,7 +806,7 @@ type FunctionsCoordinatorConfigChangedIterator struct { fail error } -func (it *FunctionsCoordinatorConfigChangedIterator) Next() bool { +func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { if it.fail != nil { return false @@ -815,7 +815,7 @@ func (it *FunctionsCoordinatorConfigChangedIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigChanged) + it.Event = new(FunctionsCoordinatorConfigSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -830,7 +830,7 @@ func (it *FunctionsCoordinatorConfigChangedIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigChanged) + it.Event = new(FunctionsCoordinatorConfigSet) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -845,32 +845,40 @@ func (it *FunctionsCoordinatorConfigChangedIterator) Next() bool { } } -func (it *FunctionsCoordinatorConfigChangedIterator) Error() error { +func (it *FunctionsCoordinatorConfigSetIterator) Error() error { return it.fail } -func (it *FunctionsCoordinatorConfigChangedIterator) Close() error { +func (it *FunctionsCoordinatorConfigSetIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsCoordinatorConfigChanged struct { - Config IFunctionsBillingConfig - Raw types.Log +type FunctionsCoordinatorConfigSet struct { + PreviousConfigBlockNumber uint32 + ConfigDigest [32]byte + ConfigCount uint64 + Signers []common.Address + Transmitters []common.Address + F uint8 + OnchainConfig []byte + OffchainConfigVersion uint64 + OffchainConfig []byte + Raw types.Log } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigChangedIterator, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) { - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigChanged") + logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigSet") if err != nil { return nil, err } - return &FunctionsCoordinatorConfigChangedIterator{contract: _FunctionsCoordinator.contract, event: "ConfigChanged", logs: logs, sub: sub}, nil + return &FunctionsCoordinatorConfigSetIterator{contract: _FunctionsCoordinator.contract, event: "ConfigSet", logs: logs, sub: sub}, nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigChanged) (event.Subscription, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigSet) (event.Subscription, error) { - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "ConfigChanged") + logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "ConfigSet") if err != nil { return nil, err } @@ -880,8 +888,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigChanged(op select { case log := <-logs: - event := new(FunctionsCoordinatorConfigChanged) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigChanged", log); err != nil { + event := new(FunctionsCoordinatorConfigSet) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigSet", log); err != nil { return err } event.Raw = log @@ -902,17 +910,17 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigChanged(op }), nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigChanged(log types.Log) (*FunctionsCoordinatorConfigChanged, error) { - event := new(FunctionsCoordinatorConfigChanged) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigChanged", log); err != nil { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigSet(log types.Log) (*FunctionsCoordinatorConfigSet, error) { + event := new(FunctionsCoordinatorConfigSet) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigSet", log); err != nil { return nil, err } event.Raw = log return event, nil } -type FunctionsCoordinatorConfigSetIterator struct { - Event *FunctionsCoordinatorConfigSet +type FunctionsCoordinatorConfigUpdatedIterator struct { + Event *FunctionsCoordinatorConfigUpdated contract *bind.BoundContract event string @@ -923,7 +931,7 @@ type FunctionsCoordinatorConfigSetIterator struct { fail error } -func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { +func (it *FunctionsCoordinatorConfigUpdatedIterator) Next() bool { if it.fail != nil { return false @@ -932,7 +940,7 @@ func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { if it.done { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigSet) + it.Event = new(FunctionsCoordinatorConfigUpdated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -947,7 +955,7 @@ func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { select { case log := <-it.logs: - it.Event = new(FunctionsCoordinatorConfigSet) + it.Event = new(FunctionsCoordinatorConfigUpdated) if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { it.fail = err return false @@ -962,40 +970,32 @@ func (it *FunctionsCoordinatorConfigSetIterator) Next() bool { } } -func (it *FunctionsCoordinatorConfigSetIterator) Error() error { +func (it *FunctionsCoordinatorConfigUpdatedIterator) Error() error { return it.fail } -func (it *FunctionsCoordinatorConfigSetIterator) Close() error { +func (it *FunctionsCoordinatorConfigUpdatedIterator) Close() error { it.sub.Unsubscribe() return nil } -type FunctionsCoordinatorConfigSet struct { - PreviousConfigBlockNumber uint32 - ConfigDigest [32]byte - ConfigCount uint64 - Signers []common.Address - Transmitters []common.Address - F uint8 - OnchainConfig []byte - OffchainConfigVersion uint64 - OffchainConfig []byte - Raw types.Log +type FunctionsCoordinatorConfigUpdated struct { + Config FunctionsBillingConfig + Raw types.Log } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigUpdatedIterator, error) { - logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigSet") + logs, sub, err := _FunctionsCoordinator.contract.FilterLogs(opts, "ConfigUpdated") if err != nil { return nil, err } - return &FunctionsCoordinatorConfigSetIterator{contract: _FunctionsCoordinator.contract, event: "ConfigSet", logs: logs, sub: sub}, nil + return &FunctionsCoordinatorConfigUpdatedIterator{contract: _FunctionsCoordinator.contract, event: "ConfigUpdated", logs: logs, sub: sub}, nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigSet) (event.Subscription, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigUpdated) (event.Subscription, error) { - logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "ConfigSet") + logs, sub, err := _FunctionsCoordinator.contract.WatchLogs(opts, "ConfigUpdated") if err != nil { return nil, err } @@ -1005,8 +1005,8 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigSet(opts * select { case log := <-logs: - event := new(FunctionsCoordinatorConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigSet", log); err != nil { + event := new(FunctionsCoordinatorConfigUpdated) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigUpdated", log); err != nil { return err } event.Raw = log @@ -1027,9 +1027,9 @@ func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) WatchConfigSet(opts * }), nil } -func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigSet(log types.Log) (*FunctionsCoordinatorConfigSet, error) { - event := new(FunctionsCoordinatorConfigSet) - if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigSet", log); err != nil { +func (_FunctionsCoordinator *FunctionsCoordinatorFilterer) ParseConfigUpdated(log types.Log) (*FunctionsCoordinatorConfigUpdated, error) { + event := new(FunctionsCoordinatorConfigUpdated) + if err := _FunctionsCoordinator.contract.UnpackLog(event, "ConfigUpdated", log); err != nil { return nil, err } event.Raw = log @@ -1713,10 +1713,10 @@ func (_FunctionsCoordinator *FunctionsCoordinator) ParseLog(log types.Log) (gene switch log.Topics[0] { case _FunctionsCoordinator.abi.Events["CommitmentDeleted"].ID: return _FunctionsCoordinator.ParseCommitmentDeleted(log) - case _FunctionsCoordinator.abi.Events["ConfigChanged"].ID: - return _FunctionsCoordinator.ParseConfigChanged(log) case _FunctionsCoordinator.abi.Events["ConfigSet"].ID: return _FunctionsCoordinator.ParseConfigSet(log) + case _FunctionsCoordinator.abi.Events["ConfigUpdated"].ID: + return _FunctionsCoordinator.ParseConfigUpdated(log) case _FunctionsCoordinator.abi.Events["OracleRequest"].ID: return _FunctionsCoordinator.ParseOracleRequest(log) case _FunctionsCoordinator.abi.Events["OracleResponse"].ID: @@ -1737,14 +1737,14 @@ func (FunctionsCoordinatorCommitmentDeleted) Topic() common.Hash { return common.HexToHash("0x8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416") } -func (FunctionsCoordinatorConfigChanged) Topic() common.Hash { - return common.HexToHash("0xfc10ed3768699b4370d710cd8ffbc7efdc5a691e42af93f2fe3d0ba7c3355658") -} - func (FunctionsCoordinatorConfigSet) Topic() common.Hash { return common.HexToHash("0x1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05") } +func (FunctionsCoordinatorConfigUpdated) Topic() common.Hash { + return common.HexToHash("0x65e5bc7ff6133456adf04bcd6ececcf049fc4117102e1ac9064d3b6570398403") +} + func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { return common.HexToHash("0xd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3") } @@ -1776,7 +1776,7 @@ type FunctionsCoordinatorInterface interface { GetAllNodePublicKeys(opts *bind.CallOpts) ([]common.Address, [][]byte, error) - GetConfig(opts *bind.CallOpts) (IFunctionsBillingConfig, error) + GetConfig(opts *bind.CallOpts) (FunctionsBillingConfig, error) GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) @@ -1824,7 +1824,7 @@ type FunctionsCoordinatorInterface interface { Transmit(opts *bind.TransactOpts, reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) - UpdateConfig(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) + UpdateConfig(opts *bind.TransactOpts, config FunctionsBillingConfig) (*types.Transaction, error) FilterCommitmentDeleted(opts *bind.FilterOpts) (*FunctionsCoordinatorCommitmentDeletedIterator, error) @@ -1832,18 +1832,18 @@ type FunctionsCoordinatorInterface interface { ParseCommitmentDeleted(log types.Log) (*FunctionsCoordinatorCommitmentDeleted, error) - FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigChangedIterator, error) - - WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigChanged) (event.Subscription, error) - - ParseConfigChanged(log types.Log) (*FunctionsCoordinatorConfigChanged, error) - FilterConfigSet(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigSetIterator, error) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigSet) (event.Subscription, error) ParseConfigSet(log types.Log) (*FunctionsCoordinatorConfigSet, error) + FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsCoordinatorConfigUpdatedIterator, error) + + WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorConfigUpdated) (event.Subscription, error) + + ParseConfigUpdated(log types.Log) (*FunctionsCoordinatorConfigUpdated, error) + FilterOracleRequest(opts *bind.FilterOpts, requestId [][32]byte, requestingContract []common.Address) (*FunctionsCoordinatorOracleRequestIterator, error) WatchOracleRequest(opts *bind.WatchOpts, sink chan<- *FunctionsCoordinatorOracleRequest, requestId [][32]byte, requestingContract []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 83b41edc908..89f706295fd 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -44,7 +44,7 @@ type FunctionsResponseCommitment struct { GasOverheadAfterCallback *big.Int } -type IFunctionsRouterConfig struct { +type FunctionsRouterConfig struct { MaxConsumersPerSubscription uint16 AdminFee *big.Int HandleOracleFulfillmentSelector [4]byte @@ -61,15 +61,15 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"timelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"maximumTimelockBlocks\",\"type\":\"uint16\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRoute\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ProposedTimelockAboveMaximum\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimelockInEffect\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"toBytes\",\"type\":\"bytes\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"timelockEndBlock\",\"type\":\"uint64\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"from\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"to\",\"type\":\"uint16\"}],\"name\":\"TimeLockUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structIFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"proposeConfigUpdateSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateConfigSelf\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162006563380380620065638339810160408190526200003491620004a3565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc816200014b565b5050600b805461ffff80881661ffff1990921691909117909155841660a052506000805260086020527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c780546001600160a01b031916301790556200014181620001fd565b5050505062000641565b336001600160a01b03821603620001a55760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b805160098054602080850151604086015160e01c600160701b0263ffffffff60701b196001600160601b0390921662010000026001600160701b031990941661ffff9096169590951792909217919091169290921781556060830151805184936200026e92600a92910190620002ae565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051620002a39190620005b2565b60405180910390a150565b82805482825590600052602060002090600701600890048101928215620003525791602002820160005b838211156200031e57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302620002d8565b8015620003505782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200031e565b505b506200036092915062000364565b5090565b5b8082111562000360576000815560010162000365565b805161ffff811681146200038e57600080fd5b919050565b634e487b7160e01b600052604160045260246000fd5b604051608081016001600160401b0381118282101715620003ce57620003ce62000393565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620003ff57620003ff62000393565b604052919050565b600082601f8301126200041957600080fd5b815160206001600160401b0382111562000437576200043762000393565b8160051b62000448828201620003d4565b92835284810182019282810190878511156200046357600080fd5b83870192505b848310156200049857825163ffffffff81168114620004885760008081fd5b8252918301919083019062000469565b979650505050505050565b60008060008060808587031215620004ba57600080fd5b620004c5856200037b565b9350620004d5602086016200037b565b60408601519093506001600160a01b0381168114620004f357600080fd5b60608601519092506001600160401b03808211156200051157600080fd5b90860190608082890312156200052657600080fd5b62000530620003a9565b6200053b836200037b565b815260208301516001600160601b03811681146200055857600080fd5b602082015260408301516001600160e01b0319811681146200057957600080fd5b60408201526060830151828111156200059157600080fd5b6200059f8a82860162000407565b6060830152509598949750929550505050565b6020808252825161ffff1682820152828101516001600160601b03166040808401919091528301516001600160e01b031916606080840191909152830151608080840152805160a0840181905260009291820190839060c08601905b808310156200063657835163ffffffff1682529284019260019290920191908401906200060e565b509695505050505050565b60805160a051615ee3620006806000396000505060008181611174015281816124f101528181612bc801528181612cd0015261345e0152615ee36000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063a9c9a918116100e3578063d7ae1d3011610097578063ea5d840f11610071578063ea5d840f14610704578063eb523d6c14610717578063f2fde38b1461072a57600080fd5b8063d7ae1d30146106cb578063e72f6e30146106de578063e82ad7d4146106f157600080fd5b8063b734c0f4116100c8578063b734c0f414610697578063badc3eb61461069f578063c3f909d4146106b657600080fd5b8063a9c9a9181461065e578063aab396bd1461067157600080fd5b80639f87fad71161013a578063a21a23e41161011f578063a21a23e414610623578063a47c76961461062b578063a4c0ed361461064b57600080fd5b80639f87fad7146105ef578063a1d4c8281461060257600080fd5b8063823597401161016b57806382359740146105b15780638456cb59146105c45780638da5cb5b146105cc57600080fd5b80637341c10c1461059657806379ba5097146105a957600080fd5b806341db4ca31161023f5780635ed6dfba116101f3578063674603d0116101cd578063674603d0146104b65780636a2215de1461054b5780636e3b33231461058357600080fd5b80635ed6dfba1461046957806366316d8d1461047c578063664199701461048f57600080fd5b80634b8832d3116102245780634b8832d31461041157806355fedefa146104245780635c975abb1461045257600080fd5b806341db4ca3146103dd578063461d2762146103fe57600080fd5b80631c02453911610296578063385de9ae1161027b578063385de9ae146103af5780633e871e4d146103c25780633f4ba83a146103d557600080fd5b80631c024539146103945780631ded3b361461039c57600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f13660046149a0565b61073d565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046149e1565b61079c565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614a88565b6102f6610898565b6102f66103aa366004614a9b565b610a1e565b6102f66103bd366004614b10565b610a50565b6102f66103d0366004614cec565b610b59565b6102f6610e9a565b6103f06103eb366004614db5565b610eac565b60405190815260200161030f565b6103f061040c366004614db5565b610f0c565b6102f661041f366004614e3a565b610f18565b6103f06104323660046149a0565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f6610477366004614e8d565b611016565b6102f661048a366004614e8d565b6111b8565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b6105236104c4366004614ebb565b73ffffffffffffffffffffffffffffffffffffffff91909116600090815260046020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff928316602085015291169082015260600161030f565b61055e610559366004614ee9565b61128f565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f6610591366004614f02565b61134e565b6102f66105a4366004614e3a565b61162a565b6102f66117c0565b6102f66105bf3660046149a0565b6118e7565b6102f6611a36565b600654610100900473ffffffffffffffffffffffffffffffffffffffff1661055e565b6102f66105fd366004614e3a565b611a46565b61061561061036600461511b565b611e1b565b60405161030f929190615203565b61049d61220f565b61063e6106393660046149a0565b61239c565b60405161030f919061527d565b6102f6610659366004615305565b6124d1565b61055e61066c366004614ee9565b61271d565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976103f0565b6102f6612782565b6106a761293c565b60405161030f93929190615361565b6106be612a15565b60405161030f91906153b6565b6102f66106d9366004614e3a565b612b2c565b6102f66106ec366004615455565b612b8f565b6104596106ff3660046149a0565b612d4c565b6102f6610712366004615472565b612e9b565b6102f6610725366004614ee9565b612fc1565b6102f6610738366004615455565b61318c565b61074561319d565b61074e816131a5565b67ffffffffffffffff81166000908152600360205260409020546107999082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661321b565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600a54911a908110610801576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600060096001018260ff168154811061081c5761081c6154b4565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610892576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107f8565b50505050565b6108a0613507565b60008080526010602052604080518082019091527f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb018054829082906108e4906154e3565b80601f0160208091040260200160405190810160405280929190818152602001828054610910906154e3565b801561095d5780601f106109325761010080835404028352916020019161095d565b820191906000526020600020905b81548152906001019060200180831161094057829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156109bf576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109df81600001518060200190518101906109da919061554c565b61358d565b80516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c791610a139160009190615676565b60405180910390a150565b610a2661319d565b610a2f826131a5565b67ffffffffffffffff90911660009081526003602081905260409091200155565b610a58613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190610aad9061ffff16436156be565b67ffffffffffffffff169052600084815260106020526040902081518190610ad5908261571f565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90610b4c90859085908590615839565b60405180910390a1505050565b610b61613507565b8151815181141580610b735750600881115b15610baa576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610cd6576000848281518110610bc957610bc96154b4565b602002602001015190506000848381518110610be757610be76154b4565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610c52575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610c89576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610cc3576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b505080610ccf9061588d565b9050610bad565b50600b54600090610ceb9061ffff16436156be565b60408051606081018252868152602080820187905267ffffffffffffffff841692820192909252865192935091600d91610d299183918901906147e0565b506020828101518051610d429260018501920190614827565b5060409190910151600290910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff90921691909117905560005b8451811015610e93577fbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e858281518110610dc457610dc46154b4565b602002602001015160086000888581518110610de257610de26154b4565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16868481518110610e2b57610e2b6154b4565b602002602001015185604051610e7b949392919093845273ffffffffffffffffffffffffffffffffffffffff92831660208501529116604083015267ffffffffffffffff16606082015260800190565b60405180910390a1610e8c8161588d565b9050610d88565b5050505050565b610ea2613507565b610eaa61366f565b565b600080610eb88361128f565b9050610f0083828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b91506136ec9050565b98975050505050505050565b600080610eb88361271d565b610f20613a41565b610f2982613a49565b610f31613b0f565b67ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416146110125767ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b61101e61319d565b806bffffffffffffffffffffffff166000036110545750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff808316911610156110ae576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b30600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff166158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806000808282829054906101000a90046bffffffffffffffffffffffff1661113191906158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061101282826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6111c0613a41565b806bffffffffffffffffffffffff16600003611208576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff80831691161015611262576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b33600090815260016020526040812080548392906110db9084906bffffffffffffffffffffffff166158c5565b6000805b600d5460ff8216101561131857600d805460ff83169081106112b7576112b76154b4565b9060005260206000200154830361130857600e805460ff83169081106112df576112df6154b4565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b611311816158f1565b9050611293565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107f8565b611356613a41565b60005b81811015611625576000838383818110611375576113756154b4565b9050610160020180360381019061138c9190615910565b905060008160e0015190506000826060015190506005600083815260200190815260200160002054836040516020016113c5919061592d565b6040516020818303038152906040528051906020012014611412576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff16421015611457576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af11580156114ca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114ee9190615a5c565b5060a083015167ffffffffffffffff82166000908152600360205260408120600101805490919061152e9084906bffffffffffffffffffffffff166158c5565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff8086168452915291902080546001926009916115b59185916901000000000000000000900416615a7e565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a25050508061161e9061588d565b9050611359565b505050565b611632613a41565b61163b82613a49565b611643613b0f565b60095467ffffffffffffffff831660009081526003602052604090206002015461ffff90911690036116a1576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8616845290915290205460ff16156116e8575050565b73ffffffffffffffffffffffffffffffffffffffff8116600081815260046020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101611009565b60075473ffffffffffffffffffffffffffffffffffffffff163314611841576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107f8565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118ef613a41565b6118f7613b0f565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611997576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107f8565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611a3e613507565b610eaa613cdf565b611a4e613a41565b611a5782613a49565b611a5f613b0f565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b07576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611b5c576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611bd757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611bac575b5050505050905060005b8151811015611d7f578373ffffffffffffffffffffffffffffffffffffffff16828281518110611c1357611c136154b4565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611d6f578160018351611c459190615a9f565b81518110611c5557611c556154b4565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611c9857611c986154b4565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611d1257611d12615ab2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611d7f565b611d788161588d565b9050611be1565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080611e26613a41565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611e8f576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e0830151600090815260056020526040902054611ef757600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615ae1565b60405180910390a2506000612204565b600560008460e0015181526020019081526020016000205483604051602001611f20919061592d565b6040516020818303038152906040528051906020012014611f7b57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615ae1565b826101400151836080015163ffffffff16611f969190615b13565b64ffffffffff165a1015611fe457600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611ee793929190615ae1565b6000611ff9846080015163ffffffff16613d3a565b6120039088615b31565b90506000818786600001516120189190615b59565b6120229190615b59565b606086015167ffffffffffffffff166000908152600360205260409020549091506bffffffffffffffffffffffff90811690821611156120b057600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615ae1565b60405180910390a250600091506122049050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff16111561211857600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee18660200151888760405161209c93929190615ae1565b5050600560008460e0015181526020019081526020016000206000905560006121508460e001518a8a87608001518860400151613ddc565b8051909150612160576001612163565b60005b9250600061219285606001518660a00151876040015188600001518c61218c8860200151613d3a565b8d613f58565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b8360200151898887600001516121df578e6121e1565b8f5b88604001516040516121f7959493929190615b7e565b60405180910390a3519150505b965096945050505050565b6000612219613a41565b612221613b0f565b6002805460009061223b9067ffffffffffffffff16615be0565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c08101825260008082523360208301529181018290526060810182905291925060808201906040519080825280602002602001820160405280156122b1578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff938416178455938601516060870151909116909302921691909117600182015560808301518051919261234c92600285019290910190614827565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a08101919091526123d6826131a5565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168487015260018501549182168488015291900416606082015260028201805485518186028101860190965280865291949293608086019392908301828280156124b757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161248c575b505050505081526020016003820154815250509050919050565b6124d9613a41565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614612548576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612582576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612590828401846149a0565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612609576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906126408385615b59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff166126969190615b59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846126fd91906156be565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff168061277c576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107f8565b92915050565b61278a613507565b600f5467ffffffffffffffff164310156127d0576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600d548110156128f3576000600d60000182815481106127f5576127f56154b4565b906000526020600020015490506000600d600101838154811061281a5761281a6154b4565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790556128ec8161588d565b90506127d3565b50600d600061290282826148a1565b6129106001830160006148a1565b5060020180547fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000169055565b600f54600d80546040805160208084028201810190925282815267ffffffffffffffff909416936060938493919290919083018282801561299c57602002820191906000526020600020905b815481526020019060010190808311612988575b50505050509150600d600101805480602002602001604051908101604052809291908181526020018280548015612a0957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116129de575b50505050509050909192565b6040805160808101825260008082526020820181905291810191909152606080820152604080516080810182526009805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff000000000000000000000000000000000000000000000000000000001683850152600a805485518184028101840190965280865293949293606086019392830182828015612b1e57602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff1681526020019060040190602082600301049283019260010382029150808411612ae15790505b505050505081525050905090565b612b34613a41565b612b3d82613a49565b612b45613b0f565b612b4e82612d4c565b15612b85576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611012828261321b565b612b9761319d565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612c24573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c489190615c07565b6000549091506bffffffffffffffffffffffff1681811115612ca0576040517fa99da30200000000000000000000000000000000000000000000000000000000815260048101829052602481018390526044016107f8565b81811015611625576000612cb48284615a9f565b9050612cf773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613c52565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612dc457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d99575b5050505050905060005b8151811015612e9157600060046000848481518110612def57612def6154b4565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612e8057506001949350505050565b50612e8a8161588d565b9050612dce565b5060009392505050565b612ea3613507565b6040805160606020601f85018190040282018101835291810183815290918291908590859081908501838280828437600092019190915250505090825250600b54602090910190612ef89061ffff16436156be565b67ffffffffffffffff16905260008052601060205280517f6e0956cda88cad152e89927e53611735b61a5c762d1428573c6931b0a5efcb01908190612f3d908261571f565b5060209190910151600190910180547fffffffffffffffffffffffffffffffffffffffffffffffff00000000000000001667ffffffffffffffff9092169190911790556040517fdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a90612fb59060009085908590615839565b60405180910390a15050565b612fc9613507565b6000818152601060205260408082208151808301909252805482908290612fef906154e3565b80601f016020809104026020016040519081016040528092919081815260200182805461301b906154e3565b80156130685780601f1061303d57610100808354040283529160200191613068565b820191906000526020600020905b81548152906001019060200180831161304b57829003601f168201915b50505091835250506001919091015467ffffffffffffffff90811660209283015290820151919250164310156130ca576040517fa93d035c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6130d38261271d565b81516040517f8cc6acce00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff9290921691638cc6acce9161312791600401614a88565b600060405180830381600087803b15801561314157600080fd5b505af1158015613155573d6000803e3d6000fd5b505082516040517fd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c79350612fb59250859190615676565b613194613507565b610799816141a1565b610eaa613507565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610799576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116848801526001850154918216848701529190041660608201526002820180548451818702810187019095528085529194929360808601939092908301828280156132fc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116132d1575b505050918352505060039190910154602090910152805190915060005b8260800151518110156133bd576004600084608001518381518110613340576133406154b4565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690556133b68161588d565b9050613319565b5067ffffffffffffffff8416600090815260036020526040812081815560018101829055906133ef60028301826148a1565b5060006003919091018190558054829190819061341b9084906bffffffffffffffffffffffff166158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506134a283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613c529092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611e0d565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107f8565b805160098054602080850151604086015160e01c6e010000000000000000000000000000027fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff6bffffffffffffffffffffffff90921662010000027fffffffffffffffffffffffffffffffffffff000000000000000000000000000090941661ffff90961695909517929092179190911692909217815560608301518051849361363c92600a929101906148bf565b509050507f9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf41786081604051610a1391906153b6565b61367761429d565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b60006136f6613a41565b6136ff856131a5565b6137093386614309565b613713858361079c565b604080516101008101825233815267ffffffffffffffff8716600081815260036020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b16608088015294845290829052015460a084015263ffffffff861660c08401526009546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e880916137f29190600401615c20565b610160604051808303816000875af1158015613812573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138369190615d0b565b9050604051806101600160405280600960000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613945919061592d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a081015161399f903390889061437d565b60e081015167ffffffffffffffff8716600081815260036020526040908190205460a0850151915192938c9390927ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec992613a2a926c0100000000000000000000000090910473ffffffffffffffffffffffffffffffffffffffff1691339132918e918e918e91615dde565b60405180910390a460e00151979650505050505050565b610eaa614458565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613ac0576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614611012576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760005260086020527f29d6d16866b6e23fcc7ae534ca080a7a6eca5e1882ac6bf4569628fa2ee46ea45473ffffffffffffffffffffffffffffffffffffffff1680613b785750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613bd990339060248101615e56565b602060405180830381865afa158015613bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c1a9190615a5c565b610799576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107f8565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526116259084906144c5565b613ce7614458565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586136c23390565b60006bffffffffffffffffffffffff821115613dd8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107f8565b5090565b604080516060808201835260008083526020830152918101919091526009546040516000916e010000000000000000000000000000900460e01b90613e2990899089908990602401615e85565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b613edb57600080fd5b5a611388811015613eeb57600080fd5b611388810390508760408204820311613f0357600080fd5b60008086516020880160008b8df193505a900391503d6084811115613f26575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b60408051808201909152600080825260208201526000613f788486615b31565b9050600081613f878886615b59565b613f919190615b59565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f1660009081526003909152928320805492975093945084939291613fe8918591166158c5565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d9450909261403c918591166158c5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846140769190615b59565b33600090815260016020526040812080549091906140a39084906bffffffffffffffffffffffff16615b59565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926140ea91859116615b59565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161416e9185916901000000000000000000900416615a7e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603614220576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107f8565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff16610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107f8565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16611012576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143b79084906bffffffffffffffffffffffff16615b59565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261442d928492900416615a7e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60065460ff1615610eaa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107f8565b6000614527826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166145d19092919063ffffffff16565b80519091501561162557808060200190518101906145459190615a5c565b611625576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107f8565b60606145e084846000856145e8565b949350505050565b60608247101561467a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107f8565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516146a39190615eba565b60006040518083038185875af1925050503d80600081146146e0576040519150601f19603f3d011682016040523d82523d6000602084013e6146e5565b606091505b50915091506146f687838387614701565b979650505050505050565b606083156147975782516000036147905773ffffffffffffffffffffffffffffffffffffffff85163b614790576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107f8565b50816145e0565b6145e083838151156147ac5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107f89190614a88565b82805482825590600052602060002090810192821561481b579160200282015b8281111561481b578251825591602001919060010190614800565b50613dd8929150614965565b82805482825590600052602060002090810192821561481b579160200282015b8281111561481b57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614847565b50805460008255906000526020600020908101906107999190614965565b8280548282559060005260206000209060070160089004810192821561481b5791602002820160005b8382111561492c57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026148e8565b801561495c5782816101000a81549063ffffffff021916905560040160208160030104928301926001030261492c565b5050613dd89291505b5b80821115613dd85760008155600101614966565b67ffffffffffffffff8116811461079957600080fd5b803561499b8161497a565b919050565b6000602082840312156149b257600080fd5b81356149bd8161497a565b9392505050565b63ffffffff8116811461079957600080fd5b803561499b816149c4565b600080604083850312156149f457600080fd5b82356149ff8161497a565b91506020830135614a0f816149c4565b809150509250929050565b60005b83811015614a35578181015183820152602001614a1d565b50506000910152565b60008151808452614a56816020860160208601614a1a565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006149bd6020830184614a3e565b60008060408385031215614aae57600080fd5b8235614ab98161497a565b946020939093013593505050565b60008083601f840112614ad957600080fd5b50813567ffffffffffffffff811115614af157600080fd5b602083019150836020828501011115614b0957600080fd5b9250929050565b600080600060408486031215614b2557600080fd5b83359250602084013567ffffffffffffffff811115614b4357600080fd5b614b4f86828701614ac7565b9497909650939450505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff81118282101715614baf57614baf614b5c565b60405290565b6040516080810167ffffffffffffffff81118282101715614baf57614baf614b5c565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614c1f57614c1f614b5c565b604052919050565b600067ffffffffffffffff821115614c4157614c41614b5c565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461079957600080fd5b803561499b81614c4b565b600082601f830112614c8957600080fd5b81356020614c9e614c9983614c27565b614bd8565b82815260059290921b84018101918181019086841115614cbd57600080fd5b8286015b84811015614ce1578035614cd481614c4b565b8352918301918301614cc1565b509695505050505050565b60008060408385031215614cff57600080fd5b823567ffffffffffffffff80821115614d1757600080fd5b818501915085601f830112614d2b57600080fd5b81356020614d3b614c9983614c27565b82815260059290921b84018101918181019089841115614d5a57600080fd5b948201945b83861015614d7857853582529482019490820190614d5f565b96505086013592505080821115614d8e57600080fd5b50614d9b85828601614c78565b9150509250929050565b61ffff8116811461079957600080fd5b60008060008060008060a08789031215614dce57600080fd5b8635614dd98161497a565b9550602087013567ffffffffffffffff811115614df557600080fd5b614e0189828a01614ac7565b9096509450506040870135614e1581614da5565b92506060870135614e25816149c4565b80925050608087013590509295509295509295565b60008060408385031215614e4d57600080fd5b8235614e588161497a565b91506020830135614a0f81614c4b565b6bffffffffffffffffffffffff8116811461079957600080fd5b803561499b81614e68565b60008060408385031215614ea057600080fd5b8235614eab81614c4b565b91506020830135614a0f81614e68565b60008060408385031215614ece57600080fd5b8235614ed981614c4b565b91506020830135614a0f8161497a565b600060208284031215614efb57600080fd5b5035919050565b60008060208385031215614f1557600080fd5b823567ffffffffffffffff80821115614f2d57600080fd5b818501915085601f830112614f4157600080fd5b813581811115614f5057600080fd5b86602061016083028501011115614f6657600080fd5b60209290920196919550909350505050565b600082601f830112614f8957600080fd5b813567ffffffffffffffff811115614fa357614fa3614b5c565b614fd460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614bd8565b818152846020838601011115614fe957600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461079957600080fd5b803561499b81615006565b69ffffffffffffffffffff8116811461079957600080fd5b803561499b81615024565b6000610160828403121561505a57600080fd5b615062614b8b565b905061506d82614e82565b815261507b60208301614c6d565b602082015261508c60408301614c6d565b604082015261509d60608301614990565b60608201526150ae608083016149d6565b60808201526150bf60a08301614e82565b60a08201526150d060c08301615019565b60c082015260e082013560e08201526101006150ed81840161503c565b908201526101206150ff838201615019565b90820152610140615111838201615019565b9082015292915050565b600080600080600080610200878903121561513557600080fd5b863567ffffffffffffffff8082111561514d57600080fd5b6151598a838b01614f78565b9750602089013591508082111561516f57600080fd5b5061517c89828a01614f78565b955050604087013561518d81614e68565b9350606087013561519d81614e68565b925060808701356151ad81614c4b565b91506151bc8860a08901615047565b90509295509295509295565b600781106151ff577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b6040810161521182856151c8565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b8381101561527257815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615240565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a08401526152ef60e084018261522c565b905060a084015160c08401528091505092915050565b6000806000806060858703121561531b57600080fd5b843561532681614c4b565b935060208501359250604085013567ffffffffffffffff81111561534957600080fd5b61535587828801614ac7565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b818110156153a257845183529383019391830191600101615386565b50508481036040860152610f00818761522c565b6000602080835260a0830161ffff855116828501526bffffffffffffffffffffffff828601511660408501527fffffffff000000000000000000000000000000000000000000000000000000006040860151166060850152606085015160808086015281815180845260c0870191508483019350600092505b80831015614ce157835163ffffffff16825292840192600192909201919084019061542f565b60006020828403121561546757600080fd5b81356149bd81614c4b565b6000806020838503121561548557600080fd5b823567ffffffffffffffff81111561549c57600080fd5b6154a885828601614ac7565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600181811c908216806154f757607f821691505b602082108103615530577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b805161499b81614e68565b805161499b816149c4565b6000602080838503121561555f57600080fd5b825167ffffffffffffffff8082111561557757600080fd5b908401906080828703121561558b57600080fd5b615593614bb5565b825161559e81614da5565b8152828401516155ad81614e68565b8185015260408301517fffffffff00000000000000000000000000000000000000000000000000000000811681146155e457600080fd5b60408201526060830151828111156155fb57600080fd5b80840193505086601f84011261561057600080fd5b82519150615620614c9983614c27565b82815260059290921b8301840191848101908884111561563f57600080fd5b938501935b83851015615666578451615657816149c4565b82529385019390850190615644565b6060830152509695505050505050565b8281526040602082015260006145e06040830184614a3e565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561277c5761277c61568f565b601f82111561162557600081815260208120601f850160051c810160208610156156f85750805b601f850160051c820191505b8181101561571757828155600101615704565b505050505050565b815167ffffffffffffffff81111561573957615739614b5c565b61574d8161574784546154e3565b846156d1565b602080601f8311600181146157a0576000841561576a5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555615717565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b828110156157ed578886015182559484019460019091019084016157ce565b508582101561582957878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b83815260406020820152816040820152818360608301376000818301606090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016010192915050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036158be576158be61568f565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156158ea576158ea61568f565b5092915050565b600060ff821660ff81036159075761590761568f565b60010192915050565b6000610160828403121561592357600080fd5b6149bd8383615047565b81516bffffffffffffffffffffffff1681526101608101602083015161596b602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615993604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516159af606084018267ffffffffffffffff169052565b5060808301516159c7608084018263ffffffff169052565b5060a08301516159e760a08401826bffffffffffffffffffffffff169052565b5060c0830151615a0060c084018264ffffffffff169052565b5060e083015160e083015261010080840151615a298285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b600060208284031215615a6e57600080fd5b815180151581146149bd57600080fd5b67ffffffffffffffff8181168382160190808211156158ea576158ea61568f565b8181038181111561277c5761277c61568f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016145e060408301846151c8565b64ffffffffff8181168382160190808211156158ea576158ea61568f565b6bffffffffffffffffffffffff818116838216028082169190828114615a5457615a5461568f565b6bffffffffffffffffffffffff8181168382160190808211156158ea576158ea61568f565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff85166020820152615bb860408201856151c8565b60a060608201526000615bce60a0830185614a3e565b8281036080840152610f008185614a3e565b600067ffffffffffffffff808316818103615bfd57615bfd61568f565b6001019392505050565b600060208284031215615c1957600080fd5b5051919050565b60208152600073ffffffffffffffffffffffffffffffffffffffff808451166020840152806020850151166040840152506040830151610100806060850152615c6d610120850183614a3e565b91506060850151615c8a608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c0850151615cbc60e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b805161499b81614c4b565b805161499b8161497a565b805161499b81615006565b805161499b81615024565b60006101608284031215615d1e57600080fd5b615d26614b8b565b615d2f83615536565b8152615d3d60208401615cdf565b6020820152615d4e60408401615cdf565b6040820152615d5f60608401615cea565b6060820152615d7060808401615541565b6080820152615d8160a08401615536565b60a0820152615d9260c08401615cf5565b60c082015260e083015160e0820152610100615daf818501615d00565b90820152610120615dc1848201615cf5565b90820152610140615dd3848201615cf5565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615e1f60e0830187614a3e565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006145e06040830184614a3e565b838152606060208201526000615e9e6060830185614a3e565b8281036040840152615eb08185614a3e565b9695505050505050565b60008251615ecc818460208701614a1a565b919091019291505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162005c4338038062005c438339810160408190526200003491620004f7565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc816200012c565b5050600080525060086020527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c780546001600160a01b031916301790556200012481620001de565b50506200066b565b336001600160a01b03821603620001865760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001e862000299565b805160098054602080850151604086015160e01c600160701b0263ffffffff60701b196001600160601b0390921662010000026001600160701b031990941661ffff9096169590951792909217919091169290921781556060830151805184936200025992600a92910190620002fc565b509050507f2eae8eac25da213074499a484cf9752294a27cb959de22f276f9003167b1611f816040516200028e9190620005dc565b60405180910390a150565b60065461010090046001600160a01b03163314620002fa5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b82805482825590600052602060002090600701600890048101928215620003a05791602002820160005b838211156200036c57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000326565b80156200039e5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200036c565b505b50620003ae929150620003b2565b5090565b5b80821115620003ae5760008155600101620003b3565b634e487b7160e01b600052604160045260246000fd5b604051608081016001600160401b0381118282101715620004045762000404620003c9565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004355762000435620003c9565b604052919050565b80516001600160e01b0319811681146200045657600080fd5b919050565b600082601f8301126200046d57600080fd5b815160206001600160401b038211156200048b576200048b620003c9565b8160051b6200049c8282016200040a565b9283528481018201928281019087851115620004b757600080fd5b83870192505b84831015620004ec57825163ffffffff81168114620004dc5760008081fd5b82529183019190830190620004bd565b979650505050505050565b600080604083850312156200050b57600080fd5b82516001600160a01b03811681146200052357600080fd5b60208401519092506001600160401b03808211156200054157600080fd5b90840190608082870312156200055657600080fd5b62000560620003df565b825161ffff811681146200057357600080fd5b815260208301516001600160601b03811681146200059057600080fd5b6020820152620005a3604084016200043d565b6040820152606083015182811115620005bb57600080fd5b620005c9888286016200045b565b6060830152508093505050509250929050565b6020808252825161ffff1682820152828101516001600160601b03166040808401919091528301516001600160e01b031916606080840191909152830151608080840152805160a0840181905260009291820190839060c08601905b808310156200066057835163ffffffff16825292840192600192909201919084019062000638565b509695505050505050565b6080516155a0620006a360003960008181610e4a015281816122bc0152818161290f01528181612a170152612eb401526155a06000f3fe608060405234801561001057600080fd5b50600436106102c85760003560e01c80637341c10c1161017b578063a4c0ed36116100d8578063c3f909d41161008c578063e72f6e3011610071578063e72f6e30146106eb578063e82ad7d4146106fe578063f2fde38b1461071157600080fd5b8063c3f909d4146106c3578063d7ae1d30146106d857600080fd5b8063aab396bd116100bd578063aab396bd1461067e578063b734c0f4146106a4578063badc3eb6146106ac57600080fd5b8063a4c0ed3614610658578063a9c9a9181461066b57600080fd5b806391e1ff721161012f578063a1d4c82811610114578063a1d4c8281461060f578063a21a23e414610630578063a47c76961461063857600080fd5b806391e1ff72146105e95780639f87fad7146105fc57600080fd5b8063823597401161016057806382359740146105ab5780638456cb59146105be5780638da5cb5b146105c657600080fd5b80637341c10c1461059057806379ba5097146105a357600080fd5b8063461d27621161022957806366316d8d116101dd578063674603d0116101c2578063674603d0146104b05780636a2215de146105455780636e3b33231461057d57600080fd5b806366316d8d14610476578063664199701461048957600080fd5b806355fedefa1161020e57806355fedefa1461041e5780635c975abb1461044c5780635ed6dfba1461046357600080fd5b8063461d2762146103f85780634b8832d31461040b57600080fd5b80631ded3b36116102805780633e871e4d116102655780633e871e4d146103bc5780633f4ba83a146103cf57806341db4ca3146103d757600080fd5b80631ded3b361461038d5780632a905ccc146103a057600080fd5b806310fc49c1116102b157806310fc49c11461030257806312b5834914610315578063181f5a771461034457600080fd5b806302bcc5b6146102cd5780630c5d49cb146102e2575b600080fd5b6102e06102db366004614314565b610724565b005b6102ea608481565b60405161ffff90911681526020015b60405180910390f35b6102e0610310366004614355565b610783565b6000546bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020016102f9565b6103806040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516102f991906143fc565b6102e061039b36600461440f565b61087f565b6009546201000090046bffffffffffffffffffffffff16610327565b6102e06103ca3660046145cb565b6108b1565b6102e0610b70565b6103ea6103e53660046146df565b610b82565b6040519081526020016102f9565b6103ea6104063660046146df565b610be2565b6102e0610419366004614763565b610bee565b6103ea61042c366004614314565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b60405190151581526020016102f9565b6102e06104713660046147b6565b610cec565b6102e06104843660046147b6565b610e8e565b60025467ffffffffffffffff165b60405167ffffffffffffffff90911681526020016102f9565b61051d6104be3660046147e4565b73ffffffffffffffffffffffffffffffffffffffff91909116600090815260046020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff92831660208501529116908201526060016102f9565b610558610553366004614812565b610f65565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016102f9565b6102e061058b36600461482b565b611024565b6102e061059e366004614763565b611300565b6102e0611496565b6102e06105b9366004614314565b6115bd565b6102e061170c565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610558565b6102e06105f73660046148a1565b61171c565b6102e061060a366004614763565b611811565b61062261061d366004614b6c565b611be6565b6040516102f9929190614c54565b610497611fda565b61064b610646366004614314565b612167565b6040516102f99190614cce565b6102e0610666366004614d56565b61229c565b610558610679366004614812565b6124e8565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976103ea565b6102e061254d565b6106b4612695565b6040516102f993929190614db2565b6106cb61275c565b6040516102f99190614e07565b6102e06106e6366004614763565b612873565b6102e06106f9366004614ea6565b6128d6565b61045361070c366004614314565b612a93565b6102e061071f366004614ea6565b612be2565b61072c612bf3565b61073581612bfb565b67ffffffffffffffff81166000908152600360205260409020546107809082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612c71565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600a54911a9081106107e8576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600060096001018260ff168154811061080357610803614ec3565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610879576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107df565b50505050565b610887612bf3565b61089082612bfb565b67ffffffffffffffff90911660009081526003602081905260409091200155565b6108b9612f5d565b81518151811415806108cb5750600881115b15610902576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610a2e57600084828151811061092157610921614ec3565b60200260200101519050600084838151811061093f5761093f614ec3565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614806109aa575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b156109e1576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610a1b576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024016107df565b505080610a2790614f21565b9050610905565b506040805180820190915283815260208082018490528451600b91610a57918391880190614154565b506020828101518051610a70926001850192019061419b565b5090505060005b8351811015610879577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610ab357610ab3614ec3565b602002602001015160086000878581518110610ad157610ad1614ec3565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610b1a57610b1a614ec3565b6020026020010151604051610b589392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1610b6981614f21565b9050610a77565b610b78612f5d565b610b80612fe3565b565b600080610b8e83610f65565b9050610bd683828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b91506130609050565b98975050505050505050565b600080610b8e836124e8565b610bf66133b5565b610bff826133bd565b610c07613483565b67ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c010000000000000000000000009092041614610ce85767ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b610cf4612bf3565b806bffffffffffffffffffffffff16600003610d2a5750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff80831691161015610d84576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3060009081526001602052604081208054839290610db19084906bffffffffffffffffffffffff16614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806000808282829054906101000a90046bffffffffffffffffffffffff16610e079190614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ce882826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166135c69092919063ffffffff16565b610e966133b5565b806bffffffffffffffffffffffff16600003610ede576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff80831691161015610f38576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526001602052604081208054839290610db19084906bffffffffffffffffffffffff16614f59565b6000805b600b5460ff82161015610fee57600b805460ff8316908110610f8d57610f8d614ec3565b90600052602060002001548303610fde57600c805460ff8316908110610fb557610fb5614ec3565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b610fe781614f85565b9050610f69565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107df565b61102c6133b5565b60005b818110156112fb57600083838381811061104b5761104b614ec3565b905061016002018036038101906110629190614fa4565b905060008160e00151905060008260600151905060056000838152602001908152602001600020548360405160200161109b9190614fc1565b60405160208183030381529060405280519060200120146110e8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff1642101561112d576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af11580156111a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c491906150f0565b5060a083015167ffffffffffffffff8216600090815260036020526040812060010180549091906112049084906bffffffffffffffffffffffff16614f59565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff80861684529152919020805460019260099161128b9185916901000000000000000000900416615112565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806112f490614f21565b905061102f565b505050565b6113086133b5565b611311826133bd565b611319613483565b60095467ffffffffffffffff831660009081526003602052604090206002015461ffff9091169003611377576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8616845290915290205460ff16156113be575050565b73ffffffffffffffffffffffffffffffffffffffff8116600081815260046020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610cdf565b60075473ffffffffffffffffffffffffffffffffffffffff163314611517576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107df565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6115c56133b5565b6115cd613483565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116929091041633811461166d576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107df565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611714612f5d565b610b80613653565b611724612f5d565b805160098054602080850151604086015160e01c6e010000000000000000000000000000027fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff6bffffffffffffffffffffffff90921662010000027fffffffffffffffffffffffffffffffffffff000000000000000000000000000090941661ffff9096169590951792909217919091169290921781556060830151805184936117d392600a92910190614215565b509050507f2eae8eac25da213074499a484cf9752294a27cb959de22f276f9003167b1611f816040516118069190614e07565b60405180910390a150565b6118196133b5565b611822826133bd565b61182a613483565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff81161515808352610100820486169483019490945269010000000000000000009004909316908301526118d2576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611927576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600360209081526040808320600201805482518185028101850190935280835291929091908301828280156119a257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611977575b5050505050905060005b8151811015611b4a578373ffffffffffffffffffffffffffffffffffffffff168282815181106119de576119de614ec3565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611b3a578160018351611a109190615133565b81518110611a2057611a20614ec3565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611a6357611a63614ec3565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611add57611add615146565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611b4a565b611b4381614f21565b90506119ac565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080611bf16133b5565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611c5a576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e0830151600090815260056020526040902054611cc257600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611cb293929190615175565b60405180910390a2506000611fcf565b600560008460e0015181526020019081526020016000205483604051602001611ceb9190614fc1565b6040516020818303038152906040528051906020012014611d4657600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611cb293929190615175565b826101400151836080015163ffffffff16611d6191906151a7565b64ffffffffff165a1015611daf57600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611cb293929190615175565b6000611dc4846080015163ffffffff166136ae565b611dce90886151c5565b9050600081878660000151611de391906151ed565b611ded91906151ed565b606086015167ffffffffffffffff166000908152600360205260409020549091506bffffffffffffffffffffffff9081169082161115611e7b57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee186602001518887604051611e6793929190615175565b60405180910390a25060009150611fcf9050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115611ee357600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee186602001518887604051611e6793929190615175565b5050600560008460e001518152602001908152602001600020600090556000611f1b8460e001518a8a87608001518860400151613750565b8051909150611f2b576001611f2e565b60005b92506000611f5d85606001518660a00151876040015188600001518c611f5788602001516136ae565b8d6138cc565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151611faa578e611fac565b8f5b8860400151604051611fc2959493929190615212565b60405180910390a3519150505b965096945050505050565b6000611fe46133b5565b611fec613483565b600280546000906120069067ffffffffffffffff16615274565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c081018252600080825233602083015291810182905260608101829052919250608082019060405190808252806020026020018201604052801561207c578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926121179260028501929091019061419b565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a08101919091526121a182612bfb565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561228257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612257575b505050505081526020016003820154815250509050919050565b6122a46133b5565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614612313576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461234d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061235b82840184614314565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166123d4576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff169186919061240b83856151ed565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661246191906151ed565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846124c8919061529b565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff1680612547576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107df565b92915050565b612555612f5d565b60005b600b54811015612678576000600b600001828154811061257a5761257a614ec3565b906000526020600020015490506000600b600101838154811061259f5761259f614ec3565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90921691909117905561267181614f21565b9050612558565b50600b600061268782826142bf565b610ce86001830160006142bf565b600b80546040805160208084028201810190925282815260009360609384938301828280156126e357602002820191906000526020600020905b8154815260200190600101908083116126cf575b50505050509150600b60010180548060200260200160405190810160405280929190818152602001828054801561275057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612725575b50505050509050909192565b6040805160808101825260008082526020820181905291810191909152606080820152604080516080810182526009805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff000000000000000000000000000000000000000000000000000000001683850152600a80548551818402810184019096528086529394929360608601939283018282801561286557602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116128285790505b505050505081525050905090565b61287b6133b5565b612884826133bd565b61288c613483565b61289582612a93565b156128cc576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ce88282612c71565b6128de612bf3565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561296b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061298f91906152ae565b6000549091506bffffffffffffffffffffffff16818111156129e7576040517fa99da30200000000000000000000000000000000000000000000000000000000815260048101829052602481018390526044016107df565b818110156112fb5760006129fb8284615133565b9050612a3e73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001685836135c6565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612b0b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612ae0575b5050505050905060005b8151811015612bd857600060046000848481518110612b3657612b36614ec3565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612bc757506001949350505050565b50612bd181614f21565b9050612b15565b5060009392505050565b612bea612f5d565b61078081613b15565b610b80612f5d565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610780576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684880152600185015491821684870152919004166060820152600282018054845181870281018701909552808552919492936080860193909290830182828015612d5257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d27575b505050918352505060039190910154602090910152805190915060005b826080015151811015612e13576004600084608001518381518110612d9657612d96614ec3565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055612e0c81614f21565b9050612d6f565b5067ffffffffffffffff841660009081526003602052604081208181556001810182905590612e4560028301826142bf565b50600060039190910181905580548291908190612e719084906bffffffffffffffffffffffff16614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550612ef883826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166135c69092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611bd8565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314610b80576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107df565b612feb613c11565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b600061306a6133b5565b61307385612bfb565b61307d3386613c7d565b6130878583610783565b604080516101008101825233815267ffffffffffffffff8716600081815260036020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b16608088015294845290829052015460a084015263ffffffff861660c08401526009546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e8809161316691906004016152c7565b610160604051808303816000875af1158015613186573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131aa91906153c8565b9050604051806101600160405280600960000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff168152506040516020016132b99190614fc1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a08101516133139033908890613cf1565b60e081015167ffffffffffffffff8716600081815260036020526040908190205460a0850151915192938c9390927ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec99261339e926c0100000000000000000000000090910473ffffffffffffffffffffffffffffffffffffffff1691339132918e918e918e9161549b565b60405180910390a460e00151979650505050505050565b610b80613dcc565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613434576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610ce8576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760005260086020527f29d6d16866b6e23fcc7ae534ca080a7a6eca5e1882ac6bf4569628fa2ee46ea45473ffffffffffffffffffffffffffffffffffffffff16806134ec5750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf89061354d90339060248101615513565b602060405180830381865afa15801561356a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061358e91906150f0565b610780576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107df565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526112fb908490613e39565b61365b613dcc565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586130363390565b60006bffffffffffffffffffffffff82111561374c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107df565b5090565b604080516060808201835260008083526020830152918101919091526009546040516000916e010000000000000000000000000000900460e01b9061379d90899089908990602401615542565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b61384f57600080fd5b5a61138881101561385f57600080fd5b61138881039050876040820482031161387757600080fd5b60008086516020880160008b8df193505a900391503d608481111561389a575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006138ec84866151c5565b90506000816138fb88866151ed565b61390591906151ed565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600390915292832080549297509394508493929161395c91859116614f59565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d945090926139b091859116614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846139ea91906151ed565b3360009081526001602052604081208054909190613a179084906bffffffffffffffffffffffff166151ed565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b94509092613a5e918591166151ed565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613ae29185916901000000000000000000900416615112565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613b94576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107df565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff16610b80576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107df565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16610ce8576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660009081526003602052604081206001018054839290613d2b9084906bffffffffffffffffffffffff166151ed565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492613da1928492900416615112565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60065460ff1615610b80576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107df565b6000613e9b826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16613f459092919063ffffffff16565b8051909150156112fb5780806020019051810190613eb991906150f0565b6112fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107df565b6060613f548484600085613f5c565b949350505050565b606082471015613fee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107df565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516140179190615577565b60006040518083038185875af1925050503d8060008114614054576040519150601f19603f3d011682016040523d82523d6000602084013e614059565b606091505b509150915061406a87838387614075565b979650505050505050565b6060831561410b5782516000036141045773ffffffffffffffffffffffffffffffffffffffff85163b614104576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107df565b5081613f54565b613f5483838151156141205781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107df91906143fc565b82805482825590600052602060002090810192821561418f579160200282015b8281111561418f578251825591602001919060010190614174565b5061374c9291506142d9565b82805482825590600052602060002090810192821561418f579160200282015b8281111561418f57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906141bb565b8280548282559060005260206000209060070160089004810192821561418f5791602002820160005b8382111561428257835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261423e565b80156142b25782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614282565b505061374c9291506142d9565b508054600082559060005260206000209081019061078091905b5b8082111561374c57600081556001016142da565b67ffffffffffffffff8116811461078057600080fd5b803561430f816142ee565b919050565b60006020828403121561432657600080fd5b8135614331816142ee565b9392505050565b63ffffffff8116811461078057600080fd5b803561430f81614338565b6000806040838503121561436857600080fd5b8235614373816142ee565b9150602083013561438381614338565b809150509250929050565b60005b838110156143a9578181015183820152602001614391565b50506000910152565b600081518084526143ca81602086016020860161438e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061433160208301846143b2565b6000806040838503121561442257600080fd5b823561442d816142ee565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516080810167ffffffffffffffff8111828210171561448d5761448d61443b565b60405290565b604051610160810167ffffffffffffffff8111828210171561448d5761448d61443b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156144fe576144fe61443b565b604052919050565b600067ffffffffffffffff8211156145205761452061443b565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461078057600080fd5b803561430f8161452a565b600082601f83011261456857600080fd5b8135602061457d61457883614506565b6144b7565b82815260059290921b8401810191818101908684111561459c57600080fd5b8286015b848110156145c05780356145b38161452a565b83529183019183016145a0565b509695505050505050565b600080604083850312156145de57600080fd5b823567ffffffffffffffff808211156145f657600080fd5b818501915085601f83011261460a57600080fd5b8135602061461a61457883614506565b82815260059290921b8401810191818101908984111561463957600080fd5b948201945b838610156146575785358252948201949082019061463e565b9650508601359250508082111561466d57600080fd5b5061467a85828601614557565b9150509250929050565b60008083601f84011261469657600080fd5b50813567ffffffffffffffff8111156146ae57600080fd5b6020830191508360208285010111156146c657600080fd5b9250929050565b803561ffff8116811461430f57600080fd5b60008060008060008060a087890312156146f857600080fd5b8635614703816142ee565b9550602087013567ffffffffffffffff81111561471f57600080fd5b61472b89828a01614684565b909650945061473e9050604088016146cd565b9250606087013561474e81614338565b80925050608087013590509295509295509295565b6000806040838503121561477657600080fd5b8235614781816142ee565b915060208301356143838161452a565b6bffffffffffffffffffffffff8116811461078057600080fd5b803561430f81614791565b600080604083850312156147c957600080fd5b82356147d48161452a565b9150602083013561438381614791565b600080604083850312156147f757600080fd5b82356148028161452a565b91506020830135614383816142ee565b60006020828403121561482457600080fd5b5035919050565b6000806020838503121561483e57600080fd5b823567ffffffffffffffff8082111561485657600080fd5b818501915085601f83011261486a57600080fd5b81358181111561487957600080fd5b8660206101608302850101111561488f57600080fd5b60209290920196919550909350505050565b600060208083850312156148b457600080fd5b823567ffffffffffffffff808211156148cc57600080fd5b90840190608082870312156148e057600080fd5b6148e861446a565b6148f1836146cd565b81528383013561490081614791565b8185015260408301357fffffffff000000000000000000000000000000000000000000000000000000008116811461493757600080fd5b604082015260608301358281111561494e57600080fd5b80840193505086601f84011261496357600080fd5b8235915061497361457883614506565b82815260059290921b8301840191848101908884111561499257600080fd5b938501935b838510156149b95784356149aa81614338565b82529385019390850190614997565b6060830152509695505050505050565b600082601f8301126149da57600080fd5b813567ffffffffffffffff8111156149f4576149f461443b565b614a2560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016144b7565b818152846020838601011115614a3a57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461078057600080fd5b803561430f81614a57565b69ffffffffffffffffffff8116811461078057600080fd5b803561430f81614a75565b60006101608284031215614aab57600080fd5b614ab3614493565b9050614abe826147ab565b8152614acc6020830161454c565b6020820152614add6040830161454c565b6040820152614aee60608301614304565b6060820152614aff6080830161434a565b6080820152614b1060a083016147ab565b60a0820152614b2160c08301614a6a565b60c082015260e082013560e0820152610100614b3e818401614a8d565b90820152610120614b50838201614a6a565b90820152610140614b62838201614a6a565b9082015292915050565b6000806000806000806102008789031215614b8657600080fd5b863567ffffffffffffffff80821115614b9e57600080fd5b614baa8a838b016149c9565b97506020890135915080821115614bc057600080fd5b50614bcd89828a016149c9565b9550506040870135614bde81614791565b93506060870135614bee81614791565b92506080870135614bfe8161452a565b9150614c0d8860a08901614a98565b90509295509295509295565b60078110614c50577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614c628285614c19565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b83811015614cc357815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614c91565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a0840152614d4060e0840182614c7d565b905060a084015160c08401528091505092915050565b60008060008060608587031215614d6c57600080fd5b8435614d778161452a565b935060208501359250604085013567ffffffffffffffff811115614d9a57600080fd5b614da687828801614684565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b81811015614df357845183529383019391830191600101614dd7565b50508481036040860152610bd68187614c7d565b6000602080835260a0830161ffff855116828501526bffffffffffffffffffffffff828601511660408501527fffffffff000000000000000000000000000000000000000000000000000000006040860151166060850152606085015160808086015281815180845260c0870191508483019350600092505b808310156145c057835163ffffffff168252928401926001929092019190840190614e80565b600060208284031215614eb857600080fd5b81356143318161452a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614f5257614f52614ef2565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614f7e57614f7e614ef2565b5092915050565b600060ff821660ff8103614f9b57614f9b614ef2565b60010192915050565b60006101608284031215614fb757600080fd5b6143318383614a98565b81516bffffffffffffffffffffffff16815261016081016020830151614fff602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615027604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060830151615043606084018267ffffffffffffffff169052565b50608083015161505b608084018263ffffffff169052565b5060a083015161507b60a08401826bffffffffffffffffffffffff169052565b5060c083015161509460c084018264ffffffffff169052565b5060e083015160e0830152610100808401516150bd8285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b60006020828403121561510257600080fd5b8151801515811461433157600080fd5b67ffffffffffffffff818116838216019080821115614f7e57614f7e614ef2565b8181038181111561254757612547614ef2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff84811682528316602082015260608101613f546040830184614c19565b64ffffffffff818116838216019080821115614f7e57614f7e614ef2565b6bffffffffffffffffffffffff8181168382160280821691908281146150e8576150e8614ef2565b6bffffffffffffffffffffffff818116838216019080821115614f7e57614f7e614ef2565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015261524c6040820185614c19565b60a06060820152600061526260a08301856143b2565b8281036080840152610bd681856143b2565b600067ffffffffffffffff80831681810361529157615291614ef2565b6001019392505050565b8082018082111561254757612547614ef2565b6000602082840312156152c057600080fd5b5051919050565b60208152600073ffffffffffffffffffffffffffffffffffffffff8084511660208401528060208501511660408401525060408301516101008060608501526153146101208501836143b2565b91506060850151615331608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c085015161536360e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b805161430f81614791565b805161430f8161452a565b805161430f816142ee565b805161430f81614338565b805161430f81614a57565b805161430f81614a75565b600061016082840312156153db57600080fd5b6153e3614493565b6153ec83615386565b81526153fa60208401615391565b602082015261540b60408401615391565b604082015261541c6060840161539c565b606082015261542d608084016153a7565b608082015261543e60a08401615386565b60a082015261544f60c084016153b2565b60c082015260e083015160e082015261010061546c8185016153bd565b9082015261012061547e8482016153b2565b908201526101406154908482016153b2565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e060608301526154dc60e08301876143b2565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000613f5460408301846143b2565b83815260606020820152600061555b60608301856143b2565b828103604084015261556d81856143b2565b9695505050505050565b6000825161558981846020870161438e565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI var FunctionsRouterBin = FunctionsRouterMetaData.Bin -func DeployFunctionsRouter(auth *bind.TransactOpts, backend bind.ContractBackend, timelockBlocks uint16, maximumTimelockBlocks uint16, linkToken common.Address, config IFunctionsRouterConfig) (common.Address, *types.Transaction, *FunctionsRouter, error) { +func DeployFunctionsRouter(auth *bind.TransactOpts, backend bind.ContractBackend, linkToken common.Address, config FunctionsRouterConfig) (common.Address, *types.Transaction, *FunctionsRouter, error) { parsed, err := FunctionsRouterMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -78,7 +78,7 @@ func DeployFunctionsRouter(auth *bind.TransactOpts, backend bind.ContractBackend return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(FunctionsRouterBin), backend, timelockBlocks, maximumTimelockBlocks, linkToken, config) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(FunctionsRouterBin), backend, linkToken, config) if err != nil { return common.Address{}, nil, nil, err } @@ -223,6 +223,28 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) MAXCALLBACKRETURNBYTES() ( return _FunctionsRouter.Contract.MAXCALLBACKRETURNBYTES(&_FunctionsRouter.CallOpts) } +func (_FunctionsRouter *FunctionsRouterCaller) GetAdminFee(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _FunctionsRouter.contract.Call(opts, &out, "getAdminFee") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_FunctionsRouter *FunctionsRouterSession) GetAdminFee() (*big.Int, error) { + return _FunctionsRouter.Contract.GetAdminFee(&_FunctionsRouter.CallOpts) +} + +func (_FunctionsRouter *FunctionsRouterCallerSession) GetAdminFee() (*big.Int, error) { + return _FunctionsRouter.Contract.GetAdminFee(&_FunctionsRouter.CallOpts) +} + func (_FunctionsRouter *FunctionsRouterCaller) GetAllowListId(opts *bind.CallOpts) ([32]byte, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getAllowListId") @@ -245,25 +267,25 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetAllowListId() ([32]byte return _FunctionsRouter.Contract.GetAllowListId(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetConfig(opts *bind.CallOpts) (FunctionsRouterConfig, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getConfig") if err != nil { - return *new(IFunctionsRouterConfig), err + return *new(FunctionsRouterConfig), err } - out0 := *abi.ConvertType(out[0], new(IFunctionsRouterConfig)).(*IFunctionsRouterConfig) + out0 := *abi.ConvertType(out[0], new(FunctionsRouterConfig)).(*FunctionsRouterConfig) return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (IFunctionsRouterConfig, error) { +func (_FunctionsRouter *FunctionsRouterSession) GetConfig() (FunctionsRouterConfig, error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (IFunctionsRouterConfig, error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (FunctionsRouterConfig, error) { return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } @@ -701,30 +723,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) Pause() (*types.Transa return _FunctionsRouter.Contract.Pause(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "proposeConfigUpdate", id, config) -} - -func (_FunctionsRouter *FunctionsRouterSession) ProposeConfigUpdate(id [32]byte, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeConfigUpdate(&_FunctionsRouter.TransactOpts, id, config) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeConfigUpdate(id [32]byte, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeConfigUpdate(&_FunctionsRouter.TransactOpts, id, config) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) ProposeConfigUpdateSelf(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "proposeConfigUpdateSelf", config) -} - -func (_FunctionsRouter *FunctionsRouterSession) ProposeConfigUpdateSelf(config []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeConfigUpdateSelf(&_FunctionsRouter.TransactOpts, config) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) ProposeConfigUpdateSelf(config []byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.ProposeConfigUpdateSelf(&_FunctionsRouter.TransactOpts, config) -} - func (_FunctionsRouter *FunctionsRouterTransactor) ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetAddresses []common.Address) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "proposeContractsUpdate", proposedContractSetIds, proposedContractSetAddresses) } @@ -845,28 +843,16 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) Unpause() (*types.Tran return _FunctionsRouter.Contract.Unpause(&_FunctionsRouter.TransactOpts) } -func (_FunctionsRouter *FunctionsRouterTransactor) UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "updateConfig", id) +func (_FunctionsRouter *FunctionsRouterTransactor) UpdateConfig(opts *bind.TransactOpts, config FunctionsRouterConfig) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "updateConfig", config) } -func (_FunctionsRouter *FunctionsRouterSession) UpdateConfig(id [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, id) +func (_FunctionsRouter *FunctionsRouterSession) UpdateConfig(config FunctionsRouterConfig) (*types.Transaction, error) { + return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, config) } -func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateConfig(id [32]byte) (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, id) -} - -func (_FunctionsRouter *FunctionsRouterTransactor) UpdateConfigSelf(opts *bind.TransactOpts) (*types.Transaction, error) { - return _FunctionsRouter.contract.Transact(opts, "updateConfigSelf") -} - -func (_FunctionsRouter *FunctionsRouterSession) UpdateConfigSelf() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateConfigSelf(&_FunctionsRouter.TransactOpts) -} - -func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateConfigSelf() (*types.Transaction, error) { - return _FunctionsRouter.Contract.UpdateConfigSelf(&_FunctionsRouter.TransactOpts) +func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateConfig(config FunctionsRouterConfig) (*types.Transaction, error) { + return _FunctionsRouter.Contract.UpdateConfig(&_FunctionsRouter.TransactOpts, config) } func (_FunctionsRouter *FunctionsRouterTransactor) UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) { @@ -881,241 +867,6 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) UpdateContracts() (*ty return _FunctionsRouter.Contract.UpdateContracts(&_FunctionsRouter.TransactOpts) } -type FunctionsRouterConfigChangedIterator struct { - Event *FunctionsRouterConfigChanged - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterConfigChangedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterConfigChanged) - 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(FunctionsRouterConfigChanged) - 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 *FunctionsRouterConfigChangedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterConfigChangedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterConfigChanged struct { - Arg0 IFunctionsRouterConfig - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigChanged") - if err != nil { - return nil, err - } - return &FunctionsRouterConfigChangedIterator{contract: _FunctionsRouter.contract, event: "ConfigChanged", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigChanged) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigChanged") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterConfigChanged) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigChanged", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigChanged(log types.Log) (*FunctionsRouterConfigChanged, error) { - event := new(FunctionsRouterConfigChanged) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigChanged", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterConfigProposedIterator struct { - Event *FunctionsRouterConfigProposed - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterConfigProposedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterConfigProposed) - 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(FunctionsRouterConfigProposed) - 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 *FunctionsRouterConfigProposedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterConfigProposedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterConfigProposed struct { - Id [32]byte - ToBytes []byte - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "ConfigProposed") - if err != nil { - return nil, err - } - return &FunctionsRouterConfigProposedIterator{contract: _FunctionsRouter.contract, event: "ConfigProposed", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "ConfigProposed") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterConfigProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) { - event := new(FunctionsRouterConfigProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "ConfigProposed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - type FunctionsRouterConfigUpdatedIterator struct { Event *FunctionsRouterConfigUpdated @@ -1177,9 +928,8 @@ func (it *FunctionsRouterConfigUpdatedIterator) Close() error { } type FunctionsRouterConfigUpdated struct { - Id [32]byte - ToBytes []byte - Raw types.Log + Arg0 FunctionsRouterConfig + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsRouterConfigUpdatedIterator, error) { @@ -1298,7 +1048,6 @@ type FunctionsRouterContractProposed struct { ProposedContractSetId [32]byte ProposedContractSetFromAddress common.Address ProposedContractSetToAddress common.Address - TimelockEndBlock uint64 Raw types.Log } @@ -3430,242 +3179,6 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParseSubscriptionOwnerTransferr return event, nil } -type FunctionsRouterTimeLockProposedIterator struct { - Event *FunctionsRouterTimeLockProposed - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterTimeLockProposedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterTimeLockProposed) - 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(FunctionsRouterTimeLockProposed) - 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 *FunctionsRouterTimeLockProposedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterTimeLockProposedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterTimeLockProposed struct { - From uint16 - To uint16 - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterTimeLockProposed(opts *bind.FilterOpts) (*FunctionsRouterTimeLockProposedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "TimeLockProposed") - if err != nil { - return nil, err - } - return &FunctionsRouterTimeLockProposedIterator{contract: _FunctionsRouter.contract, event: "TimeLockProposed", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchTimeLockProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockProposed) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "TimeLockProposed") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterTimeLockProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockProposed", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseTimeLockProposed(log types.Log) (*FunctionsRouterTimeLockProposed, error) { - event := new(FunctionsRouterTimeLockProposed) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockProposed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type FunctionsRouterTimeLockUpdatedIterator struct { - Event *FunctionsRouterTimeLockUpdated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *FunctionsRouterTimeLockUpdatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(FunctionsRouterTimeLockUpdated) - 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(FunctionsRouterTimeLockUpdated) - 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 *FunctionsRouterTimeLockUpdatedIterator) Error() error { - return it.fail -} - -func (it *FunctionsRouterTimeLockUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type FunctionsRouterTimeLockUpdated struct { - From uint16 - To uint16 - Raw types.Log -} - -func (_FunctionsRouter *FunctionsRouterFilterer) FilterTimeLockUpdated(opts *bind.FilterOpts) (*FunctionsRouterTimeLockUpdatedIterator, error) { - - logs, sub, err := _FunctionsRouter.contract.FilterLogs(opts, "TimeLockUpdated") - if err != nil { - return nil, err - } - return &FunctionsRouterTimeLockUpdatedIterator{contract: _FunctionsRouter.contract, event: "TimeLockUpdated", logs: logs, sub: sub}, nil -} - -func (_FunctionsRouter *FunctionsRouterFilterer) WatchTimeLockUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockUpdated) (event.Subscription, error) { - - logs, sub, err := _FunctionsRouter.contract.WatchLogs(opts, "TimeLockUpdated") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(FunctionsRouterTimeLockUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockUpdated", 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 (_FunctionsRouter *FunctionsRouterFilterer) ParseTimeLockUpdated(log types.Log) (*FunctionsRouterTimeLockUpdated, error) { - event := new(FunctionsRouterTimeLockUpdated) - if err := _FunctionsRouter.contract.UnpackLog(event, "TimeLockUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - type FunctionsRouterUnpausedIterator struct { Event *FunctionsRouterUnpaused @@ -3796,10 +3309,6 @@ type GetProposedContractSet struct { func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { - case _FunctionsRouter.abi.Events["ConfigChanged"].ID: - return _FunctionsRouter.ParseConfigChanged(log) - case _FunctionsRouter.abi.Events["ConfigProposed"].ID: - return _FunctionsRouter.ParseConfigProposed(log) case _FunctionsRouter.abi.Events["ConfigUpdated"].ID: return _FunctionsRouter.ParseConfigUpdated(log) case _FunctionsRouter.abi.Events["ContractProposed"].ID: @@ -3836,10 +3345,6 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig return _FunctionsRouter.ParseSubscriptionOwnerTransferRequested(log) case _FunctionsRouter.abi.Events["SubscriptionOwnerTransferred"].ID: return _FunctionsRouter.ParseSubscriptionOwnerTransferred(log) - case _FunctionsRouter.abi.Events["TimeLockProposed"].ID: - return _FunctionsRouter.ParseTimeLockProposed(log) - case _FunctionsRouter.abi.Events["TimeLockUpdated"].ID: - return _FunctionsRouter.ParseTimeLockUpdated(log) case _FunctionsRouter.abi.Events["Unpaused"].ID: return _FunctionsRouter.ParseUnpaused(log) @@ -3848,20 +3353,12 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig } } -func (FunctionsRouterConfigChanged) Topic() common.Hash { - return common.HexToHash("0x9988860843c5f26e38bf5b1c43b17689b36487e4beb67dbc84264cc5bf417860") -} - -func (FunctionsRouterConfigProposed) Topic() common.Hash { - return common.HexToHash("0xdf3b58e133a3ba6c2ac90fe2b70fef7f7d69dd675fe9c542a6f0fe2f3a8a6f3a") -} - func (FunctionsRouterConfigUpdated) Topic() common.Hash { - return common.HexToHash("0xd97d1d65f3cae3537cf4c61e688583d89aae53d8b32accdfe7cb189e65ef34c7") + return common.HexToHash("0x2eae8eac25da213074499a484cf9752294a27cb959de22f276f9003167b1611f") } func (FunctionsRouterContractProposed) Topic() common.Hash { - return common.HexToHash("0xbb4a5564503edfa78c35ff85fcc767ab37e97bd74f243e78b582b292671c004e") + return common.HexToHash("0x8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481") } func (FunctionsRouterContractUpdated) Topic() common.Hash { @@ -3928,14 +3425,6 @@ func (FunctionsRouterSubscriptionOwnerTransferred) Topic() common.Hash { return common.HexToHash("0x6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0") } -func (FunctionsRouterTimeLockProposed) Topic() common.Hash { - return common.HexToHash("0x391ced87fc414ac6e67620b6432a8df0e27da63c8cc6782941fb535ac9e06c0a") -} - -func (FunctionsRouterTimeLockUpdated) Topic() common.Hash { - return common.HexToHash("0xbda3a518f5d5dbadc2e16a279c572f58eeddb114eb084747e012080e64c54d1d") -} - func (FunctionsRouterUnpaused) Topic() common.Hash { return common.HexToHash("0x5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa") } @@ -3947,9 +3436,11 @@ func (_FunctionsRouter *FunctionsRouter) Address() common.Address { type FunctionsRouterInterface interface { MAXCALLBACKRETURNBYTES(opts *bind.CallOpts) (uint16, error) + GetAdminFee(opts *bind.CallOpts) (*big.Int, error) + GetAllowListId(opts *bind.CallOpts) ([32]byte, error) - GetConfig(opts *bind.CallOpts) (IFunctionsRouterConfig, error) + GetConfig(opts *bind.CallOpts) (FunctionsRouterConfig, error) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, @@ -4003,10 +3494,6 @@ type FunctionsRouterInterface interface { Pause(opts *bind.TransactOpts) (*types.Transaction, error) - ProposeConfigUpdate(opts *bind.TransactOpts, id [32]byte, config []byte) (*types.Transaction, error) - - ProposeConfigUpdateSelf(opts *bind.TransactOpts, config []byte) (*types.Transaction, error) - ProposeContractsUpdate(opts *bind.TransactOpts, proposedContractSetIds [][32]byte, proposedContractSetAddresses []common.Address) (*types.Transaction, error) ProposeSubscriptionOwnerTransfer(opts *bind.TransactOpts, subscriptionId uint64, newOwner common.Address) (*types.Transaction, error) @@ -4027,24 +3514,10 @@ type FunctionsRouterInterface interface { Unpause(opts *bind.TransactOpts) (*types.Transaction, error) - UpdateConfig(opts *bind.TransactOpts, id [32]byte) (*types.Transaction, error) - - UpdateConfigSelf(opts *bind.TransactOpts) (*types.Transaction, error) + UpdateConfig(opts *bind.TransactOpts, config FunctionsRouterConfig) (*types.Transaction, error) UpdateContracts(opts *bind.TransactOpts) (*types.Transaction, error) - FilterConfigChanged(opts *bind.FilterOpts) (*FunctionsRouterConfigChangedIterator, error) - - WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigChanged) (event.Subscription, error) - - ParseConfigChanged(log types.Log) (*FunctionsRouterConfigChanged, error) - - FilterConfigProposed(opts *bind.FilterOpts) (*FunctionsRouterConfigProposedIterator, error) - - WatchConfigProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigProposed) (event.Subscription, error) - - ParseConfigProposed(log types.Log) (*FunctionsRouterConfigProposed, error) - FilterConfigUpdated(opts *bind.FilterOpts) (*FunctionsRouterConfigUpdatedIterator, error) WatchConfigUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterConfigUpdated) (event.Subscription, error) @@ -4153,18 +3626,6 @@ type FunctionsRouterInterface interface { ParseSubscriptionOwnerTransferred(log types.Log) (*FunctionsRouterSubscriptionOwnerTransferred, error) - FilterTimeLockProposed(opts *bind.FilterOpts) (*FunctionsRouterTimeLockProposedIterator, error) - - WatchTimeLockProposed(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockProposed) (event.Subscription, error) - - ParseTimeLockProposed(log types.Log) (*FunctionsRouterTimeLockProposed, error) - - FilterTimeLockUpdated(opts *bind.FilterOpts) (*FunctionsRouterTimeLockUpdatedIterator, error) - - WatchTimeLockUpdated(opts *bind.WatchOpts, sink chan<- *FunctionsRouterTimeLockUpdated) (event.Subscription, error) - - ParseTimeLockUpdated(log types.Log) (*FunctionsRouterTimeLockUpdated, error) - FilterUnpaused(opts *bind.FilterOpts) (*FunctionsRouterUnpausedIterator, error) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *FunctionsRouterUnpaused) (event.Subscription, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 00878a14bbe..33250ce33e2 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,12 +1,12 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 86afaf81f6a4d775dd207d49681741e891e8409e4db4f6ad7164ac439919cc66 +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 0011ffbcd7208382a0b21e89ebe16c276650895212691980321993acc939e0e8 functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 525316bc1fab9f1d6d262ac9fc1087f66a8314de4dcc9684ba78a29e8014328f -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin d9eeb059cd99938094bfa15f86d33399c5e0a58d196294bc0ab5148463cc0391 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 31741a85040804f62d010e4f22ac8437bcf06583c00f35f9c6d67fb1fca55a46 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 7a0dcd5f5b9669fe462afe599438bc211119596aca0fb001b1b46b1aa218f5fa +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin d5b38087c403062708cd1822551316f1602a93f599d694b6e522047313185e93 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index abed26e1996..d1a33eb5812 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -14,7 +14,6 @@ import ( "testing" "time" - "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/common" @@ -172,23 +171,6 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, b := backends.NewSimulatedBackend(genesisData, gasLimit) b.Commit() - // Initialize types - uint16Type, err := abi.NewType("uint16", "uint16", nil) - require.NoError(t, err) - uint32Type, err := abi.NewType("uint32", "uint32", nil) - require.NoError(t, err) - uint80Type, err := abi.NewType("uint80", "uint80", nil) - require.NoError(t, err) - uint256Type, err := abi.NewType("uint256", "uint256", nil) - require.NoError(t, err) - int256Type, err := abi.NewType("int256", "int256", nil) - require.NoError(t, err) - require.NoError(t, err) - boolType, err := abi.NewType("bool", "bool", nil) - require.NoError(t, err) - addressType, err := abi.NewType("address", "address", nil) - require.NoError(t, err) - // Deploy LINK token linkAddr, _, linkToken, err := link_token_interface.DeployLinkToken(owner, b) require.NoError(t, err) @@ -198,65 +180,42 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, require.NoError(t, err) // Deploy Router contract - var maxConsumers = uint16(100) - var adminFee = big.NewInt(0) handleOracleFulfillmentSelectorSlice, err := hex.DecodeString("0ca76175") require.NoError(t, err) var handleOracleFulfillmentSelector [4]byte copy(handleOracleFulfillmentSelector[:], handleOracleFulfillmentSelectorSlice[:4]) - maxCallbackGasLimits := []uint32{300_000, 500_000, 1_000_000} - require.NoError(t, err) - var timelockBlocks = uint16(0) - var maximumTimelockBlocks = uint16(10) - routerAddress, _, routerContract, err := functions_router.DeployFunctionsRouter(owner, b, timelockBlocks, maximumTimelockBlocks, linkAddr, functions_router.IFunctionsRouterConfig{maxConsumers, adminFee, handleOracleFulfillmentSelector, maxCallbackGasLimits}) + functionsRouterConfig := functions_router.FunctionsRouterConfig{ + MaxConsumersPerSubscription: uint16(100), + AdminFee: big.NewInt(0), + HandleOracleFulfillmentSelector: handleOracleFulfillmentSelector, + MaxCallbackGasLimits: []uint32{300_000, 500_000, 1_000_000}, + } + routerAddress, _, routerContract, err := functions_router.DeployFunctionsRouter(owner, b, linkAddr, functionsRouterConfig) require.NoError(t, err) // Deploy Allow List contract - allowListConfigABI := abi.Arguments{ - {Type: boolType}, // enabled - {Type: addressType}, // proofSignerPublicKey - } - var enabled = false // TODO: true privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) proofSignerPublicKey := crypto.PubkeyToAddress(privateKey.PublicKey) require.NoError(t, err) - allowListConfig, err := allowListConfigABI.Pack(enabled, proofSignerPublicKey) - require.NoError(t, err) + allowListConfig := functions_allow_list.TermsOfServiceAllowListConfig{ + Enabled: false, // TODO: true + SignerPublicKey: proofSignerPublicKey, + } allowListAddress, _, allowListContract, err := functions_allow_list.DeployTermsOfServiceAllowList(owner, b, routerAddress, allowListConfig) require.NoError(t, err) - // Deploy Coordinator contract (matches _updateConfig() in FunctionsBilling.sol) - coordinatorConfigABI := abi.Arguments{ - {Type: uint32Type}, // maxCallbackGasLimit - {Type: uint32Type}, // feedStalenessSeconds - {Type: uint32Type}, // gasOverheadBeforeCallback - {Type: uint32Type}, // gasOverheadAfterCallback - {Type: uint32Type}, // requestTimeoutSeconds - {Type: uint80Type}, // donFee - {Type: uint16Type}, // maxSupportedRequestDataVersion - {Type: uint256Type}, // fulfillmentGasPriceOverEstimationBP - {Type: int256Type}, // fallbackNativePerUnitLink + // Deploy Coordinator contract (matches updateConfig() in FunctionsBilling.sol) + coordinatorConfig := functions_coordinator.FunctionsBillingConfig{ + MaxCallbackGasLimit: uint32(450_000), + FeedStalenessSeconds: uint32(86_400), + GasOverheadBeforeCallback: uint32(325_000), + GasOverheadAfterCallback: uint32(50_000), + RequestTimeoutSeconds: uint32(300), + DonFee: big.NewInt(0), + MaxSupportedRequestDataVersion: uint16(1), + FulfillmentGasPriceOverEstimationBP: big.NewInt(6_600), + FallbackNativePerUnitLink: big.NewInt(5_000_000_000_000_000), } - var maxCallbackGasLimit = uint32(450_000) - var feedStalenessSeconds = uint32(86_400) - var gasOverheadBeforeCallback = uint32(325_000) - var gasOverheadAfterCallback = uint32(50_000) - var requestTimeoutSeconds = uint32(300) - var donFee = big.NewInt(0) - var maxSupportedRequestDataVersion = uint16(1) - var fulfillmentGasPriceOverEstimationBP = big.NewInt(6_600) - var fallbackNativePerUnitLink = big.NewInt(5_000_000_000_000_000) - coordinatorConfig, err := coordinatorConfigABI.Pack( - maxCallbackGasLimit, - feedStalenessSeconds, - gasOverheadBeforeCallback, - gasOverheadAfterCallback, - requestTimeoutSeconds, - donFee, - maxSupportedRequestDataVersion, - fulfillmentGasPriceOverEstimationBP, - fallbackNativePerUnitLink, - ) require.NoError(t, err) coordinatorAddress, _, coordinatorContract, err := functions_coordinator.DeployFunctionsCoordinator(owner, b, routerAddress, coordinatorConfig, linkEthFeedAddr) require.NoError(t, err) From 97666e976449af99b304414a4597cf8e9bf41553 Mon Sep 17 00:00:00 2001 From: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Date: Sat, 5 Aug 2023 08:48:26 -0500 Subject: [PATCH 093/270] Add requestSignature (#10090) * Add requestSignature Currently optional (this is an iterative PR), but request signatures will be made a requirement for added security. * Add Solidity tests. --------- Co-authored-by: Bolek <1416262+bolekk@users.noreply.github.com> --- .../dev/1_0_0/libraries/FunctionsRequest.sol | 6 ++ .../1_0_0/testhelpers/FunctionsTestHelper.sol | 7 ++ .../test/v0.8/functions/v1/Functions.test.ts | 26 +++++++ .../functions_client_example.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 2 +- core/services/functions/listener.go | 10 ++- core/services/functions/listener_test.go | 35 ++++++++++ core/services/functions/request.go | 69 +++++++++++++++++-- .../ocr2/plugins/functions/config/config.go | 1 + 9 files changed, 149 insertions(+), 9 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol index 59e9fe9ba59..86d95cef656 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol @@ -27,6 +27,7 @@ library FunctionsRequest { CodeLanguage language; // The coding language that the source code is written in string source; // Raw source code for Request.codeLocation of Location.Inline, URL for Request.codeLocation of Location.Remote, or slot decimal number for Request.codeLocation of Location.DONHosted bytes encryptedSecretsReference; // Encrypted URLs for Request.secretsLocation of Location.Remote (use addSecretsReference()), or CBOR encoded slotid+version for Request.secretsLocation of Location.DONHosted (use addDONHostedSecrets()) + bytes requestSignature; // Signature generated by the subscription owner's EOA string[] args; // String arguments that will be passed into the source code bytes[] bytesArgs; // Bytes arguments that will be passed into the source code } @@ -51,6 +52,11 @@ library FunctionsRequest { buffer.writeString("source"); buffer.writeString(self.source); + if (self.requestSignature.length > 0) { + buffer.writeString("requestSignature"); + buffer.writeBytes(self.requestSignature); + } + if (self.args.length > 0) { buffer.writeString("args"); buffer.startArray(); diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol index 73f10071dbc..57ae6e0bbad 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsTestHelper.sol @@ -41,6 +41,12 @@ contract FunctionsTestHelper { storeRequest(r); } + function addSignature(bytes memory signature) public { + FunctionsRequest.Request memory r = s_req; + r.requestSignature = signature; + storeRequest(r); + } + function storeRequest(FunctionsRequest.Request memory r) private { s_req.codeLocation = r.codeLocation; s_req.language = r.language; @@ -48,5 +54,6 @@ contract FunctionsTestHelper { s_req.args = r.args; s_req.secretsLocation = r.secretsLocation; s_req.encryptedSecretsReference = r.encryptedSecretsReference; + s_req.requestSignature = r.requestSignature; } } diff --git a/contracts/test/v0.8/functions/v1/Functions.test.ts b/contracts/test/v0.8/functions/v1/Functions.test.ts index 981b3227073..b0128b90204 100644 --- a/contracts/test/v0.8/functions/v1/Functions.test.ts +++ b/contracts/test/v0.8/functions/v1/Functions.test.ts @@ -41,6 +41,7 @@ describe('FunctionsTestHelper', () => { 'addSecretsReference', 'addTwoArgs', 'addEmptyArgs', + 'addSignature', ]), ).to.equal(true) }) @@ -169,4 +170,29 @@ describe('FunctionsTestHelper', () => { await expect(ctr.addEmptyArgs()).to.be.revertedWith('EmptyArgs()') }) }) + + describe('#addSignature', () => { + it('emits CBOR encoded request with js source and signature', async () => { + const signatureHex = 'aabbccddeeff' + const js = 'function run(args, responses) {}' + await ctr.initializeRequestForInlineJavaScript(js) + await ctr.addSignature('0x' + signatureHex) + const tx = await ctr.closeEvent() + const [payload] = await parseRequestDataEvent(tx) + const decoded = await decodeDietCBOR(payload) + assert.deepEqual( + { + ...decoded, + language: decoded.language.toNumber(), + codeLocation: decoded.codeLocation.toNumber(), + }, + { + language: 0, + codeLocation: 0, + source: js, + requestSignature: Buffer.from(signatureHex, 'hex'), + }, + ) + }) + }) }) diff --git a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go index 4be80adae02..de90bc5ac5f 100644 --- a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go +++ b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go @@ -32,7 +32,7 @@ var ( var FunctionsClientExampleMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFulfill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162001a2f38038062001a2f833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b60805161185a620001d5600039600081816101c60152610bed015261185a6000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc3660046112a6565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e1610143366004611379565b61022d565b6101176201117081565b6100e1610337565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e161019936600461145d565b610439565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361044d565b505050565b61023561051b565b6102766040805160e0810190915280600081526020016000815260200160008152602001606081526020016060815260200160608152602001606081525090565b6102b889898080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250859392505061059e9050565b85156103005761030087878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105af9050565b831561031a5761031a6103138587611493565b82906105f9565b6103298184620111708561063c565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61044161051b565b61044a8161065b565b50565b826002541461048b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103b4565b61049482610750565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104d681610750565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461059c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103b4565b565b6105ab82600080846107d2565b5050565b80516000036105ea576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610634576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60a090910152565b600061065261064a86610869565b858585610be8565b95945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106da576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103b4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060209050602083511015610765575081515b60005b818110156107cb5761077b816008611589565b84828151811061078d5761078d6115a0565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107c4816115cf565b9050610768565b5050919050565b805160000361080d576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b838360028111156108205761082061152b565b908160028111156108335761083361152b565b905250604084018280156108495761084961152b565b908180156108595761085961152b565b9052506060909301929092525050565b60606000610878610100610cc7565b90506108c26040518060400160405280600c81526020017f636f64654c6f636174696f6e000000000000000000000000000000000000000081525082610ce890919063ffffffff16565b82516108e09060028111156108d9576108d961152b565b8290610d01565b60408051808201909152600881527f6c616e6775616765000000000000000000000000000000000000000000000000602082015261091f908290610ce8565b60408301516109369080156108d9576108d961152b565b60408051808201909152600681527f736f7572636500000000000000000000000000000000000000000000000000006020820152610975908290610ce8565b6060830151610985908290610ce8565b60a08301515115610a325760408051808201909152600481527f617267730000000000000000000000000000000000000000000000000000000060208201526109cf908290610ce8565b6109d881610d3a565b60005b8360a0015151811015610a2857610a188460a001518281518110610a0157610a016115a0565b602002602001015183610ce890919063ffffffff16565b610a21816115cf565b90506109db565b50610a3281610d5e565b60808301515115610b3357600083602001516002811115610a5557610a5561152b565b03610a8c576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051808201909152600f81527f736563726574734c6f636174696f6e00000000000000000000000000000000006020820152610acb908290610ce8565b610ae4836020015160028111156108d9576108d961152b565b60408051808201909152600781527f73656372657473000000000000000000000000000000000000000000000000006020820152610b23908290610ce8565b6080830151610b33908290610d7c565b60c08301515115610be05760408051808201909152600981527f62797465734172677300000000000000000000000000000000000000000000006020820152610b7d908290610ce8565b610b8681610d3a565b60005b8360c0015151811015610bd657610bc68460c001518281518110610baf57610baf6115a0565b602002602001015183610d7c90919063ffffffff16565b610bcf816115cf565b9050610b89565b50610be081610d5e565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610c4d959493929190611607565b6020604051808303816000875af1158015610c6c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610c9091906116a7565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b610ccf61115d565b8051610cdb9083610d89565b5060006020820152919050565b610cf58260038351610e03565b81516102289082610f2a565b8151610d0e9060c2610f52565b506105ab8282604051602001610d2691815260200190565b604051602081830303815290604052610d7c565b610d45816004610fbb565b600181602001818151610d5891906116c0565b90525050565b610d69816007610fbb565b600181602001818151610d5891906116d3565b610cf58260028351610e03565b604080518082019091526060815260006020820152610da96020836116e6565b15610dd157610db96020836116e6565b610dc49060206116d3565b610dce90836116c0565b91505b602080840183905260405180855260008152908184010181811015610df557600080fd5b604052508290505b92915050565b60178167ffffffffffffffff1611610e30578251610e2a9060e0600585901b168317610f52565b50505050565b60ff8167ffffffffffffffff1611610e72578251610e59906018611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166001610fd2565b61ffff8167ffffffffffffffff1611610eb5578251610e9c906019611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166002610fd2565b63ffffffff8167ffffffffffffffff1611610efa578251610ee190601a611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166004610fd2565b8251610f1190601b611fe0600586901b1617610f52565b508251610e2a9067ffffffffffffffff83166008610fd2565b604080518082019091526060815260006020820152610f4b83838451611057565b9392505050565b6040805180820190915260608152600060208201528251516000610f778260016116c0565b905084602001518210610f9857610f9885610f93836002611589565b611146565b8451602083820101858153508051821115610fb1578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f52565b6040805180820190915260608152600060208201528351516000610ff682856116c0565b905085602001518111156110135761101386610f93836002611589565b6000600161102386610100611841565b61102d91906116d3565b9050865182810187831982511617815250805183111561104b578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561107a57600080fd5b835151600061108984836116c0565b905085602001518111156110a6576110a686610f93836002611589565b8551805183820160200191600091808511156110c0578482525b505050602086015b6020861061110057805182526110df6020836116c0565b91506110ec6020826116c0565b90506110f96020876116d3565b95506110c8565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111528383610d89565b50610e2a8382610f2a565b6040518060400160405280611185604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561120857611208611192565b604052919050565b600067ffffffffffffffff83111561122a5761122a611192565b61125b60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116016111c1565b905082815283838301111561126f57600080fd5b828260208301376000602084830101529392505050565b600082601f83011261129757600080fd5b610f4b83833560208501611210565b6000806000606084860312156112bb57600080fd5b83359250602084013567ffffffffffffffff808211156112da57600080fd5b6112e687838801611286565b935060408601359150808211156112fc57600080fd5b5061130986828701611286565b9150509250925092565b60008083601f84011261132557600080fd5b50813567ffffffffffffffff81111561133d57600080fd5b60208301915083602082850101111561135557600080fd5b9250929050565b803567ffffffffffffffff8116811461137457600080fd5b919050565b60008060008060008060008060a0898b03121561139557600080fd5b883567ffffffffffffffff808211156113ad57600080fd5b6113b98c838d01611313565b909a50985060208b01359150808211156113d257600080fd5b6113de8c838d01611313565b909850965060408b01359150808211156113f757600080fd5b818b0191508b601f83011261140b57600080fd5b81358181111561141a57600080fd5b8c60208260051b850101111561142f57600080fd5b60208301965080955050505061144760608a0161135c565b9150608089013590509295985092959890939650565b60006020828403121561146f57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f4b57600080fd5b600067ffffffffffffffff808411156114ae576114ae611192565b8360051b60206114bf8183016111c1565b8681529185019181810190368411156114d757600080fd5b865b8481101561151f578035868111156114f15760008081fd5b880136601f8201126115035760008081fd5b611511368235878401611210565b8452509183019183016114d9565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610dfd57610dfd61155a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036116005761160061155a565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156116455788810183015185820160c001528201611629565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505061168e604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b6000602082840312156116b957600080fd5b5051919050565b80820180821115610dfd57610dfd61155a565b81810381811115610dfd57610dfd61155a565b60008261171c577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b600181815b8085111561177a57817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117605761176061155a565b8085161561176d57918102915b93841c9390800290611726565b509250929050565b60008261179157506001610dfd565b8161179e57506000610dfd565b81600181146117b457600281146117be576117da565b6001915050610dfd565b60ff8411156117cf576117cf61155a565b50506001821b610dfd565b5060208310610133831016604e8410600b84101617156117fd575081810a610dfd565b6118078383611721565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156118395761183961155a565b029392505050565b6000610f4b838361178256fea164736f6c6343000813000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001a8d38038062001a8d833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b6080516118b8620001d5600039600081816101c60152610c4f01526118b86000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc366004611304565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e16101433660046113d7565b61022d565b6101176201117081565b6100e161033f565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e16101993660046114bb565b610441565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610228838383610455565b505050565b610235610523565b61027e6040805161010081019091528060008152602001600081526020016000815260200160608152602001606081526020016060815260200160608152602001606081525090565b6102c089898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105a69050565b85156103085761030887878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105b79050565b83156103225761032261031b85876114f1565b8290610601565b61033181846201117085610644565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610449610523565b61045281610663565b50565b8260025414610493576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103bc565b61049c82610758565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104de81610758565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146105a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103bc565b565b6105b382600080846107da565b5050565b80516000036105f2576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b805160000361063c576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60c090910152565b600061065a61065286610871565b858585610c4a565b95945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103bc565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806020905060208351101561076d575081515b60005b818110156107d3576107838160086115e7565b848281518110610795576107956115fe565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107cc8161162d565b9050610770565b5050919050565b8051600003610815576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561082857610828611589565b9081600281111561083b5761083b611589565b9052506040840182801561085157610851611589565b9081801561086157610861611589565b9052506060909301929092525050565b60606000610880610100610d29565b90506108ca6040518060400160405280600c81526020017f636f64654c6f636174696f6e000000000000000000000000000000000000000081525082610d4a90919063ffffffff16565b82516108e89060028111156108e1576108e1611589565b8290610d63565b60408051808201909152600881527f6c616e67756167650000000000000000000000000000000000000000000000006020820152610927908290610d4a565b604083015161093e9080156108e1576108e1611589565b60408051808201909152600681527f736f757263650000000000000000000000000000000000000000000000000000602082015261097d908290610d4a565b606083015161098d908290610d4a565b60a083015151156109e75760408051808201909152601081527f726571756573745369676e61747572650000000000000000000000000000000060208201526109d7908290610d4a565b60a08301516109e7908290610d98565b60c08301515115610a945760408051808201909152600481527f61726773000000000000000000000000000000000000000000000000000000006020820152610a31908290610d4a565b610a3a81610da5565b60005b8360c0015151811015610a8a57610a7a8460c001518281518110610a6357610a636115fe565b602002602001015183610d4a90919063ffffffff16565b610a838161162d565b9050610a3d565b50610a9481610dc9565b60808301515115610b9557600083602001516002811115610ab757610ab7611589565b03610aee576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051808201909152600f81527f736563726574734c6f636174696f6e00000000000000000000000000000000006020820152610b2d908290610d4a565b610b46836020015160028111156108e1576108e1611589565b60408051808201909152600781527f73656372657473000000000000000000000000000000000000000000000000006020820152610b85908290610d4a565b6080830151610b95908290610d98565b60e08301515115610c425760408051808201909152600981527f62797465734172677300000000000000000000000000000000000000000000006020820152610bdf908290610d4a565b610be881610da5565b60005b8360e0015151811015610c3857610c288460e001518281518110610c1157610c116115fe565b602002602001015183610d9890919063ffffffff16565b610c318161162d565b9050610beb565b50610c4281610dc9565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610caf959493929190611665565b6020604051808303816000875af1158015610cce573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cf29190611705565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b610d316111bb565b8051610d3d9083610de7565b5060006020820152919050565b610d578260038351610e61565b81516102289082610f88565b8151610d709060c2610fb0565b506105b38282604051602001610d8891815260200190565b6040516020818303038152906040525b610d578260028351610e61565b610db0816004611019565b600181602001818151610dc3919061171e565b90525050565b610dd4816007611019565b600181602001818151610dc39190611731565b604080518082019091526060815260006020820152610e07602083611744565b15610e2f57610e17602083611744565b610e22906020611731565b610e2c908361171e565b91505b602080840183905260405180855260008152908184010181811015610e5357600080fd5b604052508290505b92915050565b60178167ffffffffffffffff1611610e8e578251610e889060e0600585901b168317610fb0565b50505050565b60ff8167ffffffffffffffff1611610ed0578251610eb7906018611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166001611030565b61ffff8167ffffffffffffffff1611610f13578251610efa906019611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166002611030565b63ffffffff8167ffffffffffffffff1611610f58578251610f3f90601a611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166004611030565b8251610f6f90601b611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166008611030565b604080518082019091526060815260006020820152610fa9838384516110b5565b9392505050565b6040805180820190915260608152600060208201528251516000610fd582600161171e565b905084602001518210610ff657610ff685610ff18360026115e7565b6111a4565b845160208382010185815350805182111561100f578181525b5093949350505050565b815161022890601f611fe0600585901b1617610fb0565b6040805180820190915260608152600060208201528351516000611054828561171e565b905085602001518111156110715761107186610ff18360026115e7565b600060016110818661010061189f565b61108b9190611731565b905086518281018783198251161781525080518311156110a9578281525b50959695505050505050565b60408051808201909152606081526000602082015282518211156110d857600080fd5b83515160006110e7848361171e565b905085602001518111156111045761110486610ff18360026115e7565b85518051838201602001916000918085111561111e578482525b505050602086015b6020861061115e578051825261113d60208361171e565b915061114a60208261171e565b9050611157602087611731565b9550611126565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111b08383610de7565b50610e888382610f88565b60405180604001604052806111e3604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611266576112666111f0565b604052919050565b600067ffffffffffffffff831115611288576112886111f0565b6112b960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8601160161121f565b90508281528383830111156112cd57600080fd5b828260208301376000602084830101529392505050565b600082601f8301126112f557600080fd5b610fa98383356020850161126e565b60008060006060848603121561131957600080fd5b83359250602084013567ffffffffffffffff8082111561133857600080fd5b611344878388016112e4565b9350604086013591508082111561135a57600080fd5b50611367868287016112e4565b9150509250925092565b60008083601f84011261138357600080fd5b50813567ffffffffffffffff81111561139b57600080fd5b6020830191508360208285010111156113b357600080fd5b9250929050565b803567ffffffffffffffff811681146113d257600080fd5b919050565b60008060008060008060008060a0898b0312156113f357600080fd5b883567ffffffffffffffff8082111561140b57600080fd5b6114178c838d01611371565b909a50985060208b013591508082111561143057600080fd5b61143c8c838d01611371565b909850965060408b013591508082111561145557600080fd5b818b0191508b601f83011261146957600080fd5b81358181111561147857600080fd5b8c60208260051b850101111561148d57600080fd5b6020830196508095505050506114a560608a016113ba565b9150608089013590509295985092959890939650565b6000602082840312156114cd57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610fa957600080fd5b600067ffffffffffffffff8084111561150c5761150c6111f0565b8360051b602061151d81830161121f565b86815291850191818101903684111561153557600080fd5b865b8481101561157d5780358681111561154f5760008081fd5b880136601f8201126115615760008081fd5b61156f36823587840161126e565b845250918301918301611537565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610e5b57610e5b6115b8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361165e5761165e6115b8565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156116a35788810183015185820160c001528201611687565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116850101925050506116ec604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561171757600080fd5b5051919050565b80820180821115610e5b57610e5b6115b8565b81810381811115610e5b57610e5b6115b8565b60008261177a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b600181815b808511156117d857817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117be576117be6115b8565b808516156117cb57918102915b93841c9390800290611784565b509250929050565b6000826117ef57506001610e5b565b816117fc57506000610e5b565b8160018114611812576002811461181c57611838565b6001915050610e5b565b60ff84111561182d5761182d6115b8565b50506001821b610e5b565b5060208310610133831016604e8410600b841016171561185b575081810a610e5b565b611865838361177f565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04821115611897576118976115b8565b029392505050565b6000610fa983836117e056fea164736f6c6343000813000a", } var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 33250ce33e2..7260ef0c6e1 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -3,7 +3,7 @@ functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 0011ffbcd7208382a0b21e89ebe16c276650895212691980321993acc939e0e8 functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca -functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 525316bc1fab9f1d6d262ac9fc1087f66a8314de4dcc9684ba78a29e8014328f +functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 67dbd571188a909b4057940a760ea46eb0b276b09afd61456f4ba75a3cb5b4f9 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 31741a85040804f62d010e4f22ac8437bcf06583c00f35f9c6d67fb1fca55a46 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin d5b38087c403062708cd1822551316f1602a93f599d694b6e522047313185e93 diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index 8380241cc4f..6d7e69f830c 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -484,6 +484,15 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID Request requestIDStr := formatRequestId(requestID) l.logger.Infow("processing request", "requestID", requestIDStr) + if l.pluginConfig.ContractVersion == 1 && l.pluginConfig.EnableRequestSignatureCheck { + err := VerifyRequestSignature(subscriptionOwner, requestData) + if err != nil { + l.logger.Errorw("invalid request signature", "requestID", requestIDStr, "err", err) + l.setError(ctx, requestID, USER_ERROR, []byte(err.Error())) + return + } + } + eaClient, err := l.bridgeAccessor.NewExternalAdapterClient() if err != nil { l.logger.Errorw("failed to create ExternalAdapterClient", "requestID", requestIDStr, "err", err) @@ -499,7 +508,6 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID Request } if userErr != nil { l.logger.Debugw("user error during getSecrets", "requestID", requestIDStr, "err", userErr) - fmt.Println("userError", userErr.Error()) l.setError(ctx, requestID, USER_ERROR, []byte(userErr.Error())) return } diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index b7204a7a1f1..3059798f09e 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -1,6 +1,7 @@ package functions_test import ( + "encoding/hex" "encoding/json" "fmt" "math/big" @@ -16,6 +17,7 @@ import ( "github.com/stretchr/testify/require" "google.golang.org/protobuf/proto" + cl_cbor "github.com/smartcontractkit/chainlink/v2/core/cbor" log_mocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log/mocks" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" @@ -66,6 +68,9 @@ var ( EncryptedSecretsUrls []byte = []byte{0x11, 0x22} EncryptedSecrets []byte = []byte(`{"TDH2Ctxt":"eyJHcm","SymCtxt":"+yHR","Nonce":"kgjHyT3Jar0M155E"}`) DecryptedSecrets []byte = []byte(`{"0x0":"lhcK"}`) + SignedCBORRequestHex = "a666736f75726365782172657475726e2046756e6374696f6e732e656e636f646555696e743235362831296773656372657473421234686c616e6775616765006c636f64654c6f636174696f6e006f736563726574734c6f636174696f6e0170726571756573745369676e617475726558416fb6d10871aa3865b6620dc5f4594d2a9ad9166ba6b1dbc3f508362fd27aa0461babada48979092a11ecadec9c663a2ea99da4e368408b36a3fb414acfefdd2a1c" + SubOwnerAddr common.Address = common.HexToAddress("0x2334dE553AB93c69b0ccbe278B6f5E8350Db6204") + NonSubOwnerAddr common.Address = common.HexToAddress("0x60C9CF55b9de9A956d921A97575108149b758131") ) func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySec int, setTiers bool) *FunctionsListenerUniverse { @@ -468,6 +473,36 @@ func TestFunctionsListener_PruneRequests(t *testing.T) { uni.service.Close() } +func TestFunctionsListener_RequestSignatureVerification(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + cborBytes, err := hex.DecodeString(SignedCBORRequestHex) + require.NoError(t, err) + + var requestData functions_service.RequestData + err = cl_cbor.ParseDietCBORToStruct(cborBytes, &requestData) + require.NoError(t, err) + + err = functions_service.VerifyRequestSignature(SubOwnerAddr, &requestData) + assert.NoError(t, err) +} + +func TestFunctionsListener_RequestSignatureVerificationFailure(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + cborBytes, err := hex.DecodeString(SignedCBORRequestHex) + require.NoError(t, err) + + var requestData functions_service.RequestData + err = cl_cbor.ParseDietCBORToStruct(cborBytes, &requestData) + require.NoError(t, err) + + err = functions_service.VerifyRequestSignature(NonSubOwnerAddr, &requestData) + assert.EqualError(t, err, "invalid request signature: signer's address does not match subscription owner") +} + // func TestFunctionsListener_HandleOracleRequestV1_Success(t *testing.T) { // testutils.SkipShortDB(t) // t.Parallel() diff --git a/core/services/functions/request.go b/core/services/functions/request.go index 53ed91a3991..a6715e0a87f 100644 --- a/core/services/functions/request.go +++ b/core/services/functions/request.go @@ -1,5 +1,14 @@ package functions +import ( + "encoding/json" + + "github.com/ethereum/go-ethereum/common" + "github.com/pkg/errors" + + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + const ( LocationInline = 0 LocationRemote = 1 @@ -10,15 +19,63 @@ const ( type RequestFlags [32]byte type RequestData struct { - Source string `json:"source" cbor:"source"` - Language int `json:"language" cbor:"language"` - CodeLocation int `json:"codeLocation" cbor:"codeLocation"` - Secrets []byte `json:"secrets" cbor:"secrets"` - SecretsLocation int `json:"secretsLocation" cbor:"secretsLocation"` - Args []string `json:"args" cbor:"args"` + Source string `json:"source" cbor:"source"` + Language int `json:"language" cbor:"language"` + CodeLocation int `json:"codeLocation" cbor:"codeLocation"` + Secrets []byte `json:"secrets" cbor:"secrets"` + SecretsLocation int `json:"secretsLocation" cbor:"secretsLocation"` + RequestSignature []byte `json:"requestSignature,omitempty" cbor:"requestSignature"` + Args []string `json:"args,omitempty" cbor:"args"` + BytesArgs [][]byte `json:"bytesArgs,omitempty" cbor:"bytesArgs"` } type DONHostedSecrets struct { SlotID uint `json:"slotId" cbor:"slotId"` Version uint64 `json:"version" cbor:"version"` } + +type SignedRequestData struct { + CodeLocation int `json:"codeLocation" cbor:"codeLocation"` + Language int `json:"language" cbor:"language"` + Secrets []byte `json:"secrets" cbor:"secrets"` + SecretsLocation int `json:"secretsLocation" cbor:"secretsLocation"` + Source string `json:"source" cbor:"source"` +} + +// The request signature should sign the keccak256 hash of the following JSON string (without extra whitespace) +// with the corresponding Request fields in the order that they appear below: +// { +// "codeLocation": number, (0 for Location.Inline) +// "language": number, (0 for CodeLanguage.JavaScript) +// "secrets": string, (encryptedSecretsReference as base64 string, must be `null` if there are no secrets) +// "secretsLocation": number, (must be `null` if there are no secrets) (1 for Location.Remote, 2 for Location.DONHosted) +// "source": string, +// } + +func VerifyRequestSignature(subscriptionOwner common.Address, requestData *RequestData) error { + if requestData.RequestSignature == nil { + return errors.New("missing signature") + } + signedRequestData := SignedRequestData{ + CodeLocation: requestData.CodeLocation, + Language: requestData.Language, + Secrets: requestData.Secrets, + SecretsLocation: requestData.SecretsLocation, + Source: requestData.Source, + } + js, err := json.Marshal(signedRequestData) + if err != nil { + return errors.New("unable to marshal request data") + } + + signerAddr, err := utils.GetSignersEthAddress(js, requestData.RequestSignature) + if err != nil { + return errors.New("invalid request signature: unable to recover signer's address") + } + + if signerAddr != subscriptionOwner { + return errors.New("invalid request signature: signer's address does not match subscription owner") + } + + return nil +} diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index 6e9a1071833..a14a3f2d815 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -19,6 +19,7 @@ import ( // This config is part of the job spec and is loaded only once on node boot/job creation. type PluginConfig struct { + EnableRequestSignatureCheck bool `json:"enableRequestSignatureCheck"` DONID string `json:"donID"` ContractVersion uint32 `json:"contractVersion"` MinIncomingConfirmations uint32 `json:"minIncomingConfirmations"` From 37338dd5906120606b5032ef57c5712218087278 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Sat, 5 Aug 2023 17:34:06 -0400 Subject: [PATCH 094/270] [Functions] (refactor): Various from review #4 (#10093) * Remove ROUTER_ID & change ALLOW_LIST_ID to use storage * Change remaining multiline comments to single line * Remove Client _sendRequest in favor of _sendRequestBytes * Add createSubscriptionWithConsumer method * Add 'gasForCallExactCheck' to router config * Lower size of various config integers * (refactor): Use struct for RequestMeta to pass data from Router to Coordinator * Remove not very helpful BalanceInvariant error * (test): Amend tests for changes * Missed usings * (test): Fix foundry test data type * Regenerate geth wrappers * Prettyify * onlyOwner to setAllowListId * Additonal changes from review --- .../functions/dev/1_0_0/FunctionsBilling.sol | 89 ++++++-------- .../functions/dev/1_0_0/FunctionsClient.sol | 50 +++----- .../dev/1_0_0/FunctionsCoordinator.sol | 28 ++--- .../functions/dev/1_0_0/FunctionsRouter.sol | 78 +++++++------ .../dev/1_0_0/FunctionsSubscriptions.sol | 109 +++++++++++------- .../src/v0.8/functions/dev/1_0_0/Routable.sol | 1 + .../accessControl/TermsOfServiceAllowList.sol | 51 +++----- .../interfaces/ITermsOfServiceAllowList.sol | 63 ++++------ .../1_0_0/example/FunctionsClientExample.sol | 2 +- .../1_0_0/interfaces/IFunctionsBilling.sol | 37 ++---- .../interfaces/IFunctionsCoordinator.sol | 23 ++-- .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 8 +- .../interfaces/IFunctionsSubscriptions.sol | 39 ++++--- .../interfaces/IOwnableFunctionsRouter.sol | 2 +- .../dev/1_0_0/libraries/FunctionsResponse.sol | 25 +++- .../tests/1_0_0/FunctionsRouter.t.sol | 24 ++-- .../testhelpers/FunctionsClientTestHelper.sol | 3 +- .../v0.8/functions/v1/FunctionsClient.test.ts | 19 ++- .../v0.8/functions/v1/FunctionsRouter.test.ts | 11 ++ .../v1/FunctionsSubscriptions.test.ts | 61 ++++------ .../test/v0.8/functions/v1/GasGolf.test.ts | 16 ++- .../test/v0.8/functions/v1/RouterBase.test.ts | 2 +- .../v1/TermsOfServiceAllowList.test.ts | 2 +- contracts/test/v0.8/functions/v1/utils.ts | 38 +++++- .../functions_allow_list.go | 8 +- .../functions_client_example.go | 2 +- .../functions_coordinator.go | 84 ++++++++------ .../functions_router/functions_router.go | 73 +++++++----- ...rapper-dependency-versions-do-not-edit.txt | 8 +- .../v1/internal/testutils.go | 5 +- .../relay/evm/functions/logpoller_wrapper.go | 48 +++++++- 31 files changed, 534 insertions(+), 475 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 7058d470d12..c31e1b1b7b6 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -1,11 +1,9 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {IFunctionsSubscriptions} from "./interfaces/IFunctionsSubscriptions.sol"; import {AggregatorV3Interface} from "../../../interfaces/AggregatorV3Interface.sol"; import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; -import {IFunctionsRouter} from "./interfaces/IFunctionsRouter.sol"; import {Routable} from "./Routable.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; @@ -16,6 +14,7 @@ import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; * @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. */ abstract contract FunctionsBilling is Routable, IFunctionsBilling { + using FunctionsResponse for FunctionsResponse.RequestMeta; using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; @@ -48,15 +47,15 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint32 requestTimeoutSeconds; // Additional flat fee (in Juels of LINK) that will be split between Node Operators // Max value is 2^80 - 1 == 1.2m LINK. - uint80 donFee; + uint72 donFee; // The highest support request data version supported by the node // All lower versions should also be supported uint16 maxSupportedRequestDataVersion; // Percentage of gas price overestimation to account for changes in gas price between request and response // Held as basis points (one hundredth of 1 percentage point) - uint256 fulfillmentGasPriceOverEstimationBP; + uint32 fulfillmentGasPriceOverEstimationBP; // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale - int256 fallbackNativePerUnitLink; + uint224 fallbackNativePerUnitLink; } Config private s_config; @@ -108,10 +107,6 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { function updateConfig(Config memory config) public { _onlyOwner(); - if (config.fallbackNativePerUnitLink <= 0) { - revert InvalidLinkWeiPrice(config.fallbackNativePerUnitLink); - } - s_config = config; emit ConfigUpdated(config); } @@ -121,16 +116,12 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ // @inheritdoc IFunctionsBilling - function getDONFee( - bytes memory /* requestData */, - RequestBilling memory /* billing */ - ) public view override returns (uint80) { - // NOTE: Optionally, compute additional fee here + function getDONFee(bytes memory /* requestData */) public view override returns (uint72) { return s_config.donFee; } // @inheritdoc IFunctionsBilling - function getAdminFee() public view override returns (uint96) { + function getAdminFee() public view override returns (uint72) { return _getRouter().getAdminFee(); } @@ -140,7 +131,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { (, int256 weiPerUnitLink, , uint256 timestamp, ) = s_linkToNativeFeed.latestRoundData(); // solhint-disable-next-line not-rely-on-time if (config.feedStalenessSeconds < block.timestamp - timestamp && config.feedStalenessSeconds > 0) { - return uint256(config.fallbackNativePerUnitLink); + return config.fallbackNativePerUnitLink; } if (weiPerUnitLink <= 0) { revert InvalidLinkWeiPrice(weiPerUnitLink); @@ -169,17 +160,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { if (gasPriceGwei > REASONABLE_GAS_PRICE_CEILING) { revert InvalidCalldata(); } - uint96 adminFee = getAdminFee(); - uint96 donFee = getDONFee( - data, - RequestBilling({ - subscriptionId: subscriptionId, - client: msg.sender, - callbackGasLimit: callbackGasLimit, - expectedGasPriceGwei: gasPriceGwei, - adminFee: adminFee - }) - ); + uint72 adminFee = getAdminFee(); + uint72 donFee = getDONFee(data); return _calculateCostEstimate(callbackGasLimit, gasPriceGwei, donFee, adminFee); } @@ -189,8 +171,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { function _calculateCostEstimate( uint32 callbackGasLimit, uint256 gasPriceGwei, - uint96 donFee, - uint96 adminFee + uint72 donFee, + uint72 adminFee ) internal view returns (uint96) { uint256 executionGas = s_config.gasOverheadBeforeCallback + s_config.gasOverheadAfterCallback + callbackGasLimit; @@ -200,7 +182,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { uint256 juelsPerGas = _getJuelsPerGas(gasPriceWithOverestimation); uint256 estimatedGasReimbursement = juelsPerGas * executionGas; - uint256 fees = uint256(donFee) + uint256(adminFee); + uint96 fees = donFee + adminFee; return uint96(estimatedGasReimbursement + fees); } @@ -216,45 +198,43 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // @param billing - Billing configuration for the request // @return commitment - The parameters of the request that must be held consistent at response time function _startBilling( - bytes memory data, - uint16 requestDataVersion, - RequestBilling memory billing + FunctionsResponse.RequestMeta memory request ) internal returns (FunctionsResponse.Commitment memory commitment) { Config memory config = s_config; // Nodes should support all past versions of the structure - if (requestDataVersion > config.maxSupportedRequestDataVersion) { + if (request.dataVersion > config.maxSupportedRequestDataVersion) { revert UnsupportedRequestDataVersion(); } - // Check that subscription can afford the estimated cost - uint80 donFee = getDONFee(data, billing); - uint96 estimatedCost = _calculateCostEstimate( - billing.callbackGasLimit, - billing.expectedGasPriceGwei, + uint72 donFee = getDONFee(request.data); + uint96 estimatedTotalCostJuels = _calculateCostEstimate( + request.callbackGasLimit, + tx.gasprice, donFee, - billing.adminFee - ); - IFunctionsSubscriptions routerWithSubscriptions = IFunctionsSubscriptions(address(_getRouter())); - IFunctionsSubscriptions.Subscription memory subscription = routerWithSubscriptions.getSubscription( - billing.subscriptionId + request.adminFee ); - if ((subscription.balance - subscription.blockedBalance) < estimatedCost) { + + // Check that subscription can afford the estimated cost + if ((request.subscription.balance - request.subscription.blockedBalance) < estimatedTotalCostJuels) { revert InsufficientBalance(); } - (, uint64 initiatedRequests, ) = routerWithSubscriptions.getConsumer(billing.client, billing.subscriptionId); - - bytes32 requestId = _computeRequestId(address(this), billing.client, billing.subscriptionId, initiatedRequests + 1); + bytes32 requestId = _computeRequestId( + address(this), + request.requestingContract, + request.subscriptionId, + request.consumer.initiatedRequests + 1 + ); commitment = FunctionsResponse.Commitment({ - adminFee: billing.adminFee, + adminFee: request.adminFee, coordinator: address(this), - client: billing.client, - subscriptionId: billing.subscriptionId, - callbackGasLimit: billing.callbackGasLimit, - estimatedTotalCostJuels: estimatedCost, - timeoutTimestamp: uint40(block.timestamp + config.requestTimeoutSeconds), + client: request.requestingContract, + subscriptionId: request.subscriptionId, + callbackGasLimit: request.callbackGasLimit, + estimatedTotalCostJuels: estimatedTotalCostJuels, + timeoutTimestamp: uint32(block.timestamp + config.requestTimeoutSeconds), requestId: requestId, donFee: donFee, gasOverheadBeforeCallback: config.gasOverheadBeforeCallback, @@ -267,6 +247,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { } // @notice Generate a keccak hash request ID + // @dev uses the number of requests that the consumer of a subscription has sent as a nonce function _computeRequestId( address don, address client, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol index 11d81499133..b7f676c2327 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsClient.sol @@ -6,10 +6,8 @@ import {IFunctionsClient} from "./interfaces/IFunctionsClient.sol"; import {FunctionsRequest} from "./libraries/FunctionsRequest.sol"; -/** - * @title The Chainlink Functions client contract - * @notice Contract developers can inherit this contract in order to make Chainlink Functions requests - */ +// @title The Chainlink Functions client contract +// @notice Contract developers can inherit this contract in order to make Chainlink Functions requests abstract contract FunctionsClient is IFunctionsClient { using FunctionsRequest for FunctionsRequest.Request; @@ -24,30 +22,12 @@ abstract contract FunctionsClient is IFunctionsClient { i_router = IFunctionsRouter(router); } - /** - * @notice Sends a Chainlink Functions request - * @param request The Functions.Request initialized in memory - * @param subscriptionId The subscription ID that will be charged to service the request - * @param callbackGasLimit the amount of gas that will be available for the fulfillment callback - * @return requestId The generated request ID for this request - */ + // @notice Sends a Chainlink Functions request + // @param data The CBOR encoded bytes data for a Functions request + // @param subscriptionId The subscription ID that will be charged to service the request + // @param callbackGasLimit the amount of gas that will be available for the fulfillment callback + // @return requestId The generated request ID for this request function _sendRequest( - FunctionsRequest.Request memory request, - uint64 subscriptionId, - uint32 callbackGasLimit, - bytes32 donId - ) internal returns (bytes32) { - return _sendRequestBytes(FunctionsRequest.encodeCBOR(request), subscriptionId, callbackGasLimit, donId); - } - - /** - * @notice Sends a Chainlink Functions request - * @param data The CBOR encoded bytes data for a Functions request - * @param subscriptionId The subscription ID that will be charged to service the request - * @param callbackGasLimit the amount of gas that will be available for the fulfillment callback - * @return requestId The generated request ID for this request - */ - function _sendRequestBytes( bytes memory data, uint64 subscriptionId, uint32 callbackGasLimit, @@ -64,18 +44,14 @@ abstract contract FunctionsClient is IFunctionsClient { return requestId; } - /** - * @notice User defined function to handle a response from the DON - * @param requestId The request ID, returned by sendRequest() - * @param response Aggregated response from the execution of the user's source code - * @param err Aggregated error from the execution of the user code or from the execution pipeline - * @dev Either response or error parameter will be set, but never both - */ + // @notice User defined function to handle a response from the DON + // @param requestId The request ID, returned by sendRequest() + // @param response Aggregated response from the execution of the user's source code + // @param err Aggregated error from the execution of the user code or from the execution pipeline + // @dev Either response or error parameter will be set, but never both function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal virtual; - /** - * @inheritdoc IFunctionsClient - */ + // @inheritdoc IFunctionsClient function handleOracleFulfillment(bytes32 requestId, bytes memory response, bytes memory err) external override { if (msg.sender != address(i_router)) { revert OnlyRouterCanFulfill(); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 8096f0fc980..fb8c6ad3745 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -13,6 +13,7 @@ import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; // @notice Contract that nodes of a Decentralized Oracle Network (DON) interact with // @dev THIS CONTRACT HAS NOT GONE THROUGH ANY SECURITY REVIEW. DO NOT USE IN PROD. contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilling { + using FunctionsResponse for FunctionsResponse.RequestMeta; using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; @@ -29,11 +30,10 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli uint16 dataVersion, bytes32 flags, uint64 callbackGasLimit, - bytes commitment + FunctionsResponse.Commitment commitment ); event OracleResponse(bytes32 indexed requestId, address transmitter); - error EmptyRequestData(); error InconsistentReportData(); error EmptyPublicKey(); error UnauthorizedPublicKeyChange(); @@ -126,35 +126,25 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli } // @inheritdoc IFunctionsCoordinator - function sendRequest( - Request calldata request + function startRequest( + FunctionsResponse.RequestMeta calldata request ) external override onlyRouter returns (FunctionsResponse.Commitment memory commitment) { - if (request.data.length == 0) { - revert EmptyRequestData(); - } - - RequestBilling memory billing = RequestBilling({ - subscriptionId: request.subscriptionId, - client: request.requestingContract, - callbackGasLimit: request.callbackGasLimit, - expectedGasPriceGwei: tx.gasprice, - adminFee: request.adminFee - }); - - commitment = _startBilling(request.data, request.dataVersion, billing); + commitment = _startBilling(request); emit OracleRequest( commitment.requestId, request.requestingContract, tx.origin, request.subscriptionId, - request.subscriptionOwner, + request.subscription.owner, request.data, request.dataVersion, request.flags, request.callbackGasLimit, - abi.encode(commitment) + commitment ); + + return commitment; } // DON fees are pooled together. If the OCR configuration is going to change, these need to be distributed. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index c1f0db466d8..646833ad5ac 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -14,6 +14,7 @@ import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/u import {Pausable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/security/Pausable.sol"; contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, ITypeAndVersion, ConfirmedOwner { + using FunctionsResponse for FunctionsResponse.RequestMeta; using FunctionsResponse for FunctionsResponse.Commitment; using FunctionsResponse for FunctionsResponse.FulfillResult; @@ -23,13 +24,7 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, // malicious contracts from returning large amounts of data and causing // repeated out-of-gas scenarios. uint16 public constant MAX_CALLBACK_RETURN_BYTES = 4 + 4 * 32; - - mapping(bytes32 id => address routableContract) private s_route; - - error RouteNotFound(bytes32 id); - - // Use empty bytes to self-identify, since it does not have an id - bytes32 private constant ROUTER_ID = bytes32(0); + uint8 private constant MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX = 0; event RequestStart( bytes32 indexed requestId, @@ -61,6 +56,7 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, FunctionsResponse.FulfillResult resultCode ); + error EmptyRequestData(); error OnlyCallableFromCoordinator(); error SenderMustAcceptTermsOfService(address sender); error InvalidGasFlagValue(uint8 value); @@ -72,9 +68,16 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, bytes returnData; } + // ================================================================ + // | Route state | + // ================================================================ + + mapping(bytes32 id => address routableContract) private s_route; + + error RouteNotFound(bytes32 id); + // Identifier for the route to the Terms of Service Allow List - bytes32 private constant ALLOW_LIST_ID = keccak256("Functions Terms of Service Allow List"); - uint8 private constant MAX_CALLBACK_GAS_LIMIT_FLAGS_INDEX = 0; + bytes32 private s_allowListId; // ================================================================ // | Configuration state | @@ -86,9 +89,11 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, // Should a user require more consumers, they can use multiple subscriptions. uint16 maxConsumersPerSubscription; // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network - uint96 adminFee; + uint72 adminFee; // The function selector that is used when calling back to the Client contract bytes4 handleOracleFulfillmentSelector; + // Used during calling back to the client. Ensures we have at least enough gas to be able to revert if gasAmount > 63//64*gas available. + uint16 gasForCallExactCheck; // List of max callback gas limits used by flag with GAS_FLAG_INDEX uint32[] maxCallbackGasLimits; } @@ -128,8 +133,6 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, address linkToken, Config memory config ) FunctionsSubscriptions(linkToken) ConfirmedOwner(msg.sender) Pausable() { - // Set the initial configuration for the Router - s_route[ROUTER_ID] = address(this); // Set the intial configuration updateConfig(config); } @@ -164,13 +167,18 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, } // @inheritdoc IFunctionsRouter - function getAdminFee() external view override returns (uint96 adminFee) { + function getAdminFee() external view override returns (uint72 adminFee) { return s_config.adminFee; } // @inheritdoc IFunctionsRouter - function getAllowListId() external pure override returns (bytes32) { - return ALLOW_LIST_ID; + function getAllowListId() external view override returns (bytes32) { + return s_allowListId; + } + + // @inheritdoc IFunctionsRouter + function setAllowListId(bytes32 allowListId) external override onlyOwner { + s_allowListId = allowListId; } // Used within FunctionsSubscriptions.sol @@ -215,21 +223,28 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, uint32 callbackGasLimit ) private returns (bytes32) { _whenNotPaused(); - _isValidSubscription(subscriptionId); - _isValidConsumer(msg.sender, subscriptionId); + _isExistingSubscription(subscriptionId); + _isAllowedConsumer(msg.sender, subscriptionId); isValidCallbackGasLimit(subscriptionId, callbackGasLimit); + if (data.length == 0) { + revert EmptyRequestData(); + } + + Subscription memory subscription = getSubscription(subscriptionId); + // Forward request to DON - FunctionsResponse.Commitment memory commitment = coordinator.sendRequest( - IFunctionsCoordinator.Request({ + FunctionsResponse.Commitment memory commitment = coordinator.startRequest( + FunctionsResponse.RequestMeta({ requestingContract: msg.sender, - subscriptionOwner: s_subscriptions[subscriptionId].owner, data: data, subscriptionId: subscriptionId, dataVersion: dataVersion, flags: getFlags(subscriptionId), callbackGasLimit: callbackGasLimit, - adminFee: s_config.adminFee + adminFee: s_config.adminFee, + consumer: getConsumer(msg.sender, subscriptionId), + subscription: subscription }) ); @@ -258,7 +273,7 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, requestId: commitment.requestId, donId: donId, subscriptionId: subscriptionId, - subscriptionOwner: s_subscriptions[subscriptionId].owner, + subscriptionOwner: subscription.owner, requestingContract: msg.sender, requestInitiator: tx.origin, data: data, @@ -312,8 +327,8 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, uint96 callbackCost = juelsPerGas * SafeCast.toUint96(commitment.callbackGasLimit); uint96 totalCostJuels = commitment.adminFee + costWithoutCallback + callbackCost; - // Check that the subscription can still afford - if (totalCostJuels > s_subscriptions[commitment.subscriptionId].balance) { + // Check that the subscription can still afford to fulfill the request + if (totalCostJuels > getSubscription(commitment.subscriptionId).balance) { resultCode = FunctionsResponse.FulfillResult.SUBSCRIPTION_BALANCE_INVARIANT_VIOLATION; emit RequestNotProcessed(commitment.requestId, commitment.coordinator, transmitter, resultCode); return (resultCode, 0); @@ -378,6 +393,8 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, err ); + uint16 gasForCallExactCheck = s_config.gasForCallExactCheck; + // Call with explicitly the amount of callback gas requested // Important to not let them exhaust the gas budget and avoid payment. // NOTE: that callWithExactGas will revert if we do not have sufficient gas @@ -398,17 +415,16 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, } let g := gas() - // GASFORCALLEXACTCHECK = 5000 // Compute g -= gasForCallExactCheck and check for underflow // The gas actually passed to the callee is _min(gasAmount, 63//64*gas available). // We want to ensure that we revert if gasAmount > 63//64*gas available // as we do not want to provide them with less, however that check itself costs // gas. gasForCallExactCheck ensures we have at least enough gas to be able // to revert if gasAmount > 63//64*gas available. - if lt(g, 5000) { + if lt(g, gasForCallExactCheck) { revert(0, 0) } - g := sub(g, 5000) + g := sub(g, gasForCallExactCheck) // if g - g//64 <= gasAmount, revert // (we subtract g//64 because of EIP-150) if iszero(gt(sub(g, div(g, 64)), callbackGasLimit)) { @@ -494,10 +510,6 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, ) { revert InvalidProposal(); } - // Reserved IDs cannot be set - if (id == ROUTER_ID) { - revert IdentifierIsReserved(id); - } } s_proposedContractSet = ContractProposalSet({ids: proposedContractSetIds, to: proposedContractSetAddresses}); @@ -542,9 +554,9 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, // Used within FunctionsSubscriptions.sol function _onlySenderThatAcceptedToS() internal view override { - address currentImplementation = s_route[ALLOW_LIST_ID]; + address currentImplementation = s_route[s_allowListId]; if (currentImplementation == address(0)) { - // If not set, ignore this check + // If not set, ignore this check, allow all access return; } if (!IAccessController(currentImplementation).hasAccess(msg.sender, new bytes(0))) { diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 3252cb28117..cb43cab82fe 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -42,8 +42,8 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // loop through all the current subscriptions via .getSubscription(). uint64 private s_currentSubscriptionId; - mapping(uint64 subscriptionId => IFunctionsSubscriptions.Subscription) internal s_subscriptions; - mapping(address consumer => mapping(uint64 subscriptionId => IFunctionsSubscriptions.Consumer)) internal s_consumers; + mapping(uint64 subscriptionId => IFunctionsSubscriptions.Subscription) private s_subscriptions; + mapping(address consumer => mapping(uint64 subscriptionId => IFunctionsSubscriptions.Consumer)) private s_consumers; event SubscriptionCreated(uint64 indexed subscriptionId, address owner); event SubscriptionFunded(uint64 indexed subscriptionId, uint256 oldBalance, uint256 newBalance); @@ -53,17 +53,16 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece event SubscriptionOwnerTransferRequested(uint64 indexed subscriptionId, address from, address to); event SubscriptionOwnerTransferred(uint64 indexed subscriptionId, address from, address to); - error TooManyConsumers(); - error InsufficientBalance(); + error TooManyConsumers(uint16 maximumConsumers); + error InsufficientBalance(uint96 currentBalanceJuels); error InvalidConsumer(); - error ConsumerRequestsInFlight(); + error CannotRemoveWithPendingRequests(); error InvalidSubscription(); error OnlyCallableFromLink(); error InvalidCalldata(); error MustBeSubscriptionOwner(); - error PendingRequestExists(); + error TimeoutNotExceeded(); error MustBeProposedOwner(address proposedOwner); - error BalanceInvariantViolated(uint256 internalBalance, uint256 externalBalance); // Should never happen event FundsRecovered(address to, uint256 amount); // ================================================================ @@ -141,7 +140,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // @inheritdoc IFunctionsSubscriptions function ownerCancelSubscription(uint64 subscriptionId) external override { _onlyRouterOwner(); - _isValidSubscription(subscriptionId); + _isExistingSubscription(subscriptionId); _cancelSubscriptionHelper(subscriptionId, s_subscriptions[subscriptionId].owner); } @@ -150,9 +149,6 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece _onlyRouterOwner(); uint256 externalBalance = IERC20(i_linkToken).balanceOf(address(this)); uint256 internalBalance = uint256(s_totalLinkBalance); - if (internalBalance > externalBalance) { - revert BalanceInvariantViolated(internalBalance, externalBalance); - } if (internalBalance < externalBalance) { uint256 amount = externalBalance - internalBalance; IERC20(i_linkToken).safeTransfer(to, amount); @@ -172,8 +168,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece if (amount == 0) { revert InvalidCalldata(); } - if (s_withdrawableTokens[msg.sender] < amount) { - revert InsufficientBalance(); + uint96 currentBalance = s_withdrawableTokens[msg.sender]; + if (currentBalance < amount) { + revert InsufficientBalance(currentBalance); } s_withdrawableTokens[msg.sender] -= amount; s_totalLinkBalance -= amount; @@ -189,8 +186,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece if (amount == 0) { amount = s_withdrawableTokens[address(this)]; } - if (s_withdrawableTokens[address(this)] < amount) { - revert InsufficientBalance(); + uint96 currentBalance = s_withdrawableTokens[address(this)]; + if (currentBalance < amount) { + revert InsufficientBalance(currentBalance); } s_withdrawableTokens[address(this)] -= amount; s_totalLinkBalance -= amount; @@ -203,6 +201,11 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // ================================================================ // This function is to be invoked when using LINK.transferAndCall + // @dev Note to fund the subscription, use transferAndCall. For example + // @dev LINKTOKEN.transferAndCall( + // @dev address(ROUTER), + // @dev amount, + // @dev abi.encode(subscriptionId)); function onTokenTransfer(address /* sender */, uint256 amount, bytes calldata data) external override { _whenNotPaused(); if (msg.sender != address(i_linkToken)) { @@ -224,7 +227,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece } // ================================================================ - // | Subscriptions management | + // | Subscription management | // ================================================================ // @inheritdoc IFunctionsSubscriptions @@ -238,30 +241,25 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece } // @inheritdoc IFunctionsSubscriptions - function getSubscription(uint64 subscriptionId) external view override returns (Subscription memory) { - _isValidSubscription(subscriptionId); + function getSubscription(uint64 subscriptionId) public view override returns (Subscription memory) { + _isExistingSubscription(subscriptionId); return s_subscriptions[subscriptionId]; } // @inheritdoc IFunctionsSubscriptions - function getConsumer( - address client, - uint64 subscriptionId - ) external view override returns (bool allowed, uint64 initiatedRequests, uint64 completedRequests) { - allowed = s_consumers[client][subscriptionId].allowed; - initiatedRequests = s_consumers[client][subscriptionId].initiatedRequests; - completedRequests = s_consumers[client][subscriptionId].completedRequests; + function getConsumer(address client, uint64 subscriptionId) public view override returns (Consumer memory) { + return s_consumers[client][subscriptionId]; } // Used within this file & FunctionsRouter.sol - function _isValidSubscription(uint64 subscriptionId) internal view { + function _isExistingSubscription(uint64 subscriptionId) internal view { if (s_subscriptions[subscriptionId].owner == address(0)) { revert InvalidSubscription(); } } // Used within FunctionsRouter.sol - function _isValidConsumer(address client, uint64 subscriptionId) internal view { + function _isAllowedConsumer(address client, uint64 subscriptionId) internal view { if (!s_consumers[client][subscriptionId].allowed) { revert InvalidConsumer(); } @@ -287,18 +285,42 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece return subscriptionId; } + // @inheritdoc IFunctionsSubscriptions + function createSubscriptionWithConsumer(address consumer) external override returns (uint64 subscriptionId) { + _whenNotPaused(); + _onlySenderThatAcceptedToS(); + + subscriptionId = ++s_currentSubscriptionId; + s_subscriptions[subscriptionId] = Subscription({ + balance: 0, + blockedBalance: 0, + owner: msg.sender, + proposedOwner: address(0), + consumers: new address[](0), + flags: bytes32(0) + }); + + s_subscriptions[subscriptionId].consumers.push(consumer); + s_consumers[consumer][subscriptionId].allowed = true; + + emit SubscriptionCreated(subscriptionId, msg.sender); + emit SubscriptionConsumerAdded(subscriptionId, consumer); + + return subscriptionId; + } + // @inheritdoc IFunctionsSubscriptions function proposeSubscriptionOwnerTransfer(uint64 subscriptionId, address newOwner) external override { _whenNotPaused(); _onlySubscriptionOwner(subscriptionId); _onlySenderThatAcceptedToS(); - // Proposing to address(0) would never be claimable, so don't need to check. - - if (s_subscriptions[subscriptionId].proposedOwner != newOwner) { - s_subscriptions[subscriptionId].proposedOwner = newOwner; - emit SubscriptionOwnerTransferRequested(subscriptionId, msg.sender, newOwner); + if (newOwner == address(0) || s_subscriptions[subscriptionId].proposedOwner == newOwner) { + revert InvalidCalldata(); } + + s_subscriptions[subscriptionId].proposedOwner = newOwner; + emit SubscriptionOwnerTransferRequested(subscriptionId, msg.sender, newOwner); } // @inheritdoc IFunctionsSubscriptions @@ -327,7 +349,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece revert InvalidConsumer(); } if (consumerData.initiatedRequests != consumerData.completedRequests) { - revert ConsumerRequestsInFlight(); + revert CannotRemoveWithPendingRequests(); } // Note bounded by config.maxConsumers address[] memory consumers = s_subscriptions[subscriptionId].consumers; @@ -354,14 +376,16 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece _onlySenderThatAcceptedToS(); // Already maxed, cannot add any more consumers. - if (s_subscriptions[subscriptionId].consumers.length == _getMaxConsumers()) { - revert TooManyConsumers(); + uint16 maximumConsumers = _getMaxConsumers(); + if (s_subscriptions[subscriptionId].consumers.length == maximumConsumers) { + revert TooManyConsumers(maximumConsumers); } if (s_consumers[consumer][subscriptionId].allowed) { // Idempotence - do nothing if already added. // Ensures uniqueness in s_subscriptions[subscriptionId].consumers. return; } + s_consumers[consumer][subscriptionId].allowed = true; s_subscriptions[subscriptionId].consumers.push(consumer); @@ -375,7 +399,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece _onlySenderThatAcceptedToS(); if (pendingRequestExists(subscriptionId)) { - revert PendingRequestExists(); + revert CannotRemoveWithPendingRequests(); } _cancelSubscriptionHelper(subscriptionId, to); @@ -384,7 +408,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece function _cancelSubscriptionHelper(uint64 subscriptionId, address to) private { Subscription memory subscription = s_subscriptions[subscriptionId]; uint96 balance = subscription.balance; - // Note bounded by config.maxConsumers + // NOTE: loop iterations are bounded by config.maxConsumers // If no consumers, does nothing. for (uint256 i = 0; i < subscription.consumers.length; ++i) { delete s_consumers[subscription.consumers[i]][subscriptionId]; @@ -400,7 +424,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // @inheritdoc IFunctionsSubscriptions function pendingRequestExists(uint64 subscriptionId) public view override returns (bool) { address[] memory consumers = s_subscriptions[subscriptionId].consumers; - // Iterations will not exceed config.maxConsumers + // NOTE: loop iterations are bounded by config.maxConsumers for (uint256 i = 0; i < consumers.length; ++i) { Consumer memory consumer = s_consumers[consumers[i]][subscriptionId]; if (consumer.initiatedRequests != consumer.completedRequests) { @@ -413,7 +437,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // @inheritdoc IFunctionsSubscriptions function setFlags(uint64 subscriptionId, bytes32 flags) external override { _onlyRouterOwner(); - _isValidSubscription(subscriptionId); + _isExistingSubscription(subscriptionId); s_subscriptions[subscriptionId].flags = flags; } @@ -442,14 +466,15 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // Check that request has exceeded allowed request time if (block.timestamp < request.timeoutTimestamp) { - revert ConsumerRequestsInFlight(); + revert TimeoutNotExceeded(); } + // Notify the Coordinator that the request should no longer be fulfilled IFunctionsBilling(request.coordinator).deleteCommitment(requestId); - // Release blocked balance + // Release the subscription's balance that had been earmarked for the request s_subscriptions[subscriptionId].blockedBalance -= request.estimatedTotalCostJuels; s_consumers[request.client][subscriptionId].completedRequests += 1; - // Delete commitment + // Delete commitment within Router state delete s_requestCommitments[requestId]; emit RequestTimedOut(requestId); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol index 61f96b247a6..8c09eba5d79 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/Routable.sol @@ -22,6 +22,7 @@ abstract contract Routable is ITypeAndVersion { i_router = IOwnableFunctionsRouter(router); } + // @notice Return the Router function _getRouter() internal view returns (IOwnableFunctionsRouter router) { return i_router; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index 0cd8b952212..fc8cca9edf3 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -5,16 +5,13 @@ import {ITermsOfServiceAllowList} from "./interfaces/ITermsOfServiceAllowList.so import {IAccessController} from "../../../../shared/interfaces/IAccessController.sol"; import {ITypeAndVersion} from "../../../../shared/interfaces/ITypeAndVersion.sol"; -import {Routable} from "../Routable.sol"; import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; import {Address} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol"; import {EnumerableSet} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; -/** - * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service - */ -contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, Routable, ConfirmedOwner { +// @notice A contract to handle access control of subscription management dependent on signing a Terms of Service +contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, ITypeAndVersion, ConfirmedOwner { using Address for address; using EnumerableSet for EnumerableSet.AddressSet; @@ -48,7 +45,7 @@ contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, // | Initialization | // ================================================================ - constructor(address router, Config memory config) Routable(router) ConfirmedOwner(msg.sender) { + constructor(Config memory config) ConfirmedOwner(msg.sender) { updateConfig(config); } @@ -70,19 +67,15 @@ contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, } // ================================================================ - // | Terms of Service methods | + // | Allow methods | // ================================================================ - /** - * @inheritdoc ITermsOfServiceAllowList - */ + // @inheritdoc ITermsOfServiceAllowList function getMessage(address acceptor, address recipient) public pure override returns (bytes32) { return keccak256(abi.encodePacked(acceptor, recipient)); } - /** - * @inheritdoc ITermsOfServiceAllowList - */ + // @inheritdoc ITermsOfServiceAllowList function acceptTermsOfService(address acceptor, address recipient, bytes32 r, bytes32 s, uint8 v) external override { if (s_blockedSenders[recipient]) { revert RecipientIsBlocked(); @@ -109,16 +102,12 @@ contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, emit AddedAccess(recipient); } - /** - * @inheritdoc ITermsOfServiceAllowList - */ + // @inheritdoc ITermsOfServiceAllowList function getAllAllowedSenders() external view override returns (address[] memory) { return s_allowedSenders.values(); } - /** - * @inheritdoc IAccessController - */ + // @inheritdoc IAccessController function hasAccess(address user, bytes calldata /* data */) external view override returns (bool) { if (!s_config.enabled) { return true; @@ -126,9 +115,11 @@ contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, return s_allowedSenders.contains(user); } - /** - * @inheritdoc ITermsOfServiceAllowList - */ + // ================================================================ + // | Block methods | + // ================================================================ + + // @inheritdoc ITermsOfServiceAllowList function isBlockedSender(address sender) external view override returns (bool) { if (!s_config.enabled) { return false; @@ -136,23 +127,15 @@ contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, return s_blockedSenders[sender]; } - // ================================================================ - // | Owner methods | - // ================================================================ - - /** - * @inheritdoc ITermsOfServiceAllowList - */ - function blockSender(address sender) external override onlyRouterOwner { + // @inheritdoc ITermsOfServiceAllowList + function blockSender(address sender) external override onlyOwner { s_allowedSenders.remove(sender); s_blockedSenders[sender] = true; emit BlockedAccess(sender); } - /** - * @inheritdoc ITermsOfServiceAllowList - */ - function unblockSender(address sender) external override onlyRouterOwner { + // @inheritdoc ITermsOfServiceAllowList + function unblockSender(address sender) external override onlyOwner { s_blockedSenders[sender] = false; emit UnblockedAccess(sender); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol index dd662f02b56..b83375ee01f 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol @@ -1,55 +1,40 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -/** - * @notice A contract to handle access control of subscription management dependent on signing a Terms of Service - */ - +// @notice A contract to handle access control of subscription management dependent on signing a Terms of Service interface ITermsOfServiceAllowList { - /** - * @notice Return the message data for the proof given to accept the Terms of Service - * @param acceptor - The wallet address that has accepted the Terms of Service on the UI - * @param recipient - The recipient address that the acceptor is taking responsibility for - * @return Hash of the message data - */ + // @notice Return the message data for the proof given to accept the Terms of Service + // @param acceptor - The wallet address that has accepted the Terms of Service on the UI + // @param recipient - The recipient address that the acceptor is taking responsibility for + // @return Hash of the message data function getMessage(address acceptor, address recipient) external pure returns (bytes32); - /** - * @notice Check if the address is blocked for usage - * @param sender The transaction sender's address - * @return True or false - */ + // @notice Check if the address is blocked for usage + // @param sender The transaction sender's address + // @return True or false function isBlockedSender(address sender) external returns (bool); - /** - * @notice Get a list of all allowed senders - * @dev WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed - * to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that - * this function has an unbounded cost, and using it as part of a state-changing function may render the function - * uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. - * @return addresses - all allowed addresses - */ + // @notice Get a list of all allowed senders + // @dev WARNING: This operation will copy the entire storage to memory, which can be quite expensive. This is designed + // to mostly be used by view accessors that are queried without any gas fees. Developers should keep in mind that + // this function has an unbounded cost, and using it as part of a state-changing function may render the function + // uncallable if the set grows to a point where copying to memory consumes too much gas to fit in a block. + // @return addresses - all allowed addresses function getAllAllowedSenders() external view returns (address[] memory); - /** - * @notice Allows access to the sender based on acceptance of the Terms of Service - * @param acceptor - The wallet address that has accepted the Terms of Service on the UI - * @param recipient - The recipient address that the acceptor is taking responsibility for - * @param r - ECDSA signature r data produced by the Chainlink Functions Subscription UI - * @param s - ECDSA signature s produced by the Chainlink Functions Subscription UI - * @param v - ECDSA signature v produced by the Chainlink Functions Subscription UI - */ + // @notice Allows access to the sender based on acceptance of the Terms of Service + // @param acceptor - The wallet address that has accepted the Terms of Service on the UI + // @param recipient - The recipient address that the acceptor is taking responsibility for + // @param r - ECDSA signature r data produced by the Chainlink Functions Subscription UI + // @param s - ECDSA signature s produced by the Chainlink Functions Subscription UI + // @param v - ECDSA signature v produced by the Chainlink Functions Subscription UI function acceptTermsOfService(address acceptor, address recipient, bytes32 r, bytes32 s, uint8 v) external; - /** - * @notice Removes a sender's access if already authorized, and disallows re-accepting the Terms of Service - * @param sender - Address of the sender to block - */ + // @notice Removes a sender's access if already authorized, and disallows re-accepting the Terms of Service + // @param sender - Address of the sender to block function blockSender(address sender) external; - /** - * @notice Re-allows a previously blocked sender to accept the Terms of Service - * @param sender - Address of the sender to unblock - */ + // @notice Re-allows a previously blocked sender to accept the Terms of Service + // @param sender - Address of the sender to unblock function unblockSender(address sender) external; } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol index 1eb50e9d31e..5feee704ef5 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/example/FunctionsClientExample.sol @@ -41,7 +41,7 @@ contract FunctionsClientExample is FunctionsClient, ConfirmedOwner { req.initializeRequestForInlineJavaScript(source); if (encryptedSecretsReferences.length > 0) req.addSecretsReference(encryptedSecretsReferences); if (args.length > 0) req.setArgs(args); - s_lastRequestId = _sendRequest(req, subscriptionId, MAX_CALLBACK_GAS, jobId); + s_lastRequestId = _sendRequest(req.encodeCBOR(), subscriptionId, MAX_CALLBACK_GAS, jobId); } /** diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol index a7aa7891193..00ff17ee14d 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsBilling.sol @@ -1,42 +1,27 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -// @title Chainlink Functions billing subscription registry interface. +// @title Chainlink Functions DON billing interface. interface IFunctionsBilling { - struct RequestBilling { - // a unique subscription ID allocated by billing system, - uint64 subscriptionId; - // the client contract that initiated the request to the DON - // to use the subscription it must be added as a consumer on the subscription - address client; - // customer specified gas limit for the fulfillment callback - uint32 callbackGasLimit; - // the expected gas price used to execute the transaction - uint256 expectedGasPriceGwei; - // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network - uint96 adminFee; - } - // @notice Return the current conversion from WEI of ETH to LINK from the configured Chainlink data feed // @return weiPerUnitLink - The amount of WEI in one LINK function getWeiPerUnitLink() external view returns (uint256); // @notice Determine the fee that will be split between Node Operators for servicing a request - // @param requestData Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - // @param billing The request's billing configuration - // @return fee Cost in Juels (1e18) of LINK - function getDONFee(bytes memory requestData, RequestBilling memory billing) external view returns (uint80); + // @param requestCBOR - CBOR encoded Chainlink Functions request data, use FunctionsRequest library to encode a request + // @return fee - Cost in Juels (1e18) of LINK + function getDONFee(bytes memory requestCBOR) external view returns (uint72); // @notice Determine the fee that will be paid to the Router owner for operating the network - // @return fee Cost in Juels (1e18) of LINK - function getAdminFee() external view returns (uint96); + // @return fee - Cost in Juels (1e18) of LINK + function getAdminFee() external view returns (uint72); // @notice Estimate the total cost that will be charged to a subscription to make a request: transmitter gas re-reimbursement, plus DON fee, plus Registry fee - // @param subscriptionId An identifier of the billing account - // @param data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request - // @param callbackGasLimit Gas limit for the fulfillment callback - // @param gasPriceGwei The blockchain's gas price to estimate with - // @return billedCost Cost in Juels (1e18) of LINK + // @param - subscriptionId An identifier of the billing account + // @param - data Encoded Chainlink Functions request data, use FunctionsClient API to encode a request + // @param - callbackGasLimit Gas limit for the fulfillment callback + // @param - gasPriceGwei The blockchain's gas price to estimate with + // @return - billedCost Cost in Juels (1e18) of LINK function estimateCost( uint64 subscriptionId, bytes calldata data, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol index 05a616e8b24..63571786eb8 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsCoordinator.sol @@ -3,19 +3,8 @@ pragma solidity ^0.8.19; import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; -// @title Chainlink Functions Coordinator interface. +// @title Chainlink Functions DON Coordinator interface. interface IFunctionsCoordinator { - struct Request { - address requestingContract; // The client contract that is sending the request - address subscriptionOwner; // The owner of the billing subscription - bytes data; // Encoded Chainlink Functions request data, use FunctionsRequest library to encode a request - uint64 subscriptionId; // Identifier of the billing subscription that will be charged for the request - uint16 dataVersion; // The version of the structure of the CBOR encoded request data - bytes32 flags; // Per-subscription account flags - uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract will be given - uint96 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router Owner for operation of the network - } - // @notice Returns the DON's threshold encryption public key used to encrypt secrets // @dev All nodes on the DON have separate key shares of the threshold decryption key // and nodes must participate in a threshold decryption OCR round to decrypt secrets @@ -53,9 +42,11 @@ interface IFunctionsCoordinator { // public keys (or empty byte arrays if per-node key is not defined) function getAllNodePublicKeys() external view returns (address[] memory, bytes[] memory); - // @notice Sends a request (encoded as data) using the provided subscriptionId - // @dev Callable only by the Router - // @param request The request information, @dev see the struct for field descriptions + // @notice Receives a request to be emitted to the DON for processing + // @param request The request metadata + // @dev see the struct for field descriptions // @return commitment - The parameters of the request that must be held consistent at response time - function sendRequest(Request calldata request) external returns (FunctionsResponse.Commitment memory commitment); + function startRequest( + FunctionsResponse.RequestMeta calldata request + ) external returns (FunctionsResponse.Commitment memory commitment); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index 450f584b2d4..3eb13574e49 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -8,11 +8,15 @@ interface IFunctionsRouter { // @notice The identifier of the route to retrieve the address of the access control contract // The access control contract controls which accounts can manage subscriptions // @return id - bytes32 id that can be passed to the "getContractById" of the Router - function getAllowListId() external pure returns (bytes32); + function getAllowListId() external view returns (bytes32); + + // @notice Set the identifier of the route to retrieve the address of the access control contract + // The access control contract controls which accounts can manage subscriptions + function setAllowListId(bytes32 allowListId) external; // @notice Get the flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network // @return adminFee - function getAdminFee() external view returns (uint96 adminFee); + function getAdminFee() external view returns (uint72 adminFee); // @notice Sends a request using the provided subscriptionId // @param subscriptionId - A unique subscription ID allocated by billing system, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 698930a6e2a..117ae61fdbc 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -3,13 +3,11 @@ pragma solidity ^0.8.19; import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; -/** - * @title Chainlink Functions Subscription interface. - */ +// @title Chainlink Functions Subscription interface. interface IFunctionsSubscriptions { struct Subscription { // There are only 1e9*1e18 = 1e27 juels in existence, so the balance can fit in uint96 (2^96 ~ 7e28) - uint96 balance; // Common LINK balance that is controlled by the Registry to be used for all consumer requests. + uint96 balance; // Common LINK balance that is controlled by the Router to be used for all consumer requests. address owner; // Owner can fund/withdraw/cancel the sub. uint96 blockedBalance; // LINK balance that is reserved to pay for pending consumer requests. address proposedOwner; // For safely transferring sub ownership. @@ -30,20 +28,15 @@ interface IFunctionsSubscriptions { } // @notice Get details about a subscription. - // @param subscriptionId - ID of the subscription + // @param subscriptionId - the ID of the subscription + // @return subscription - see IFunctionsSubscriptions.Subscription for more information on the structure function getSubscription(uint64 subscriptionId) external view returns (Subscription memory); // @notice Get details about a consumer of a subscription. - // @dev Only callable by a route - // @param client - the consumer contract that initiated the request - // @param subscriptionId - ID of the subscription - // @return allowed - amount of LINK balance of the subscription in juels that is blocked for an in flight request. - // @return initiatedRequests - owner of the subscription. - // @return completedRequests - list of consumer address which are able to use this subscription. - function getConsumer( - address client, - uint64 subscriptionId - ) external view returns (bool allowed, uint64 initiatedRequests, uint64 completedRequests); + // @param client - the consumer contract address + // @param subscriptionId - the ID of the subscription + // @return consumer - see IFunctionsSubscriptions.Consumer for more information on the structure + function getConsumer(address client, uint64 subscriptionId) external view returns (Consumer memory); // @notice Get details about the total amount of LINK within the system // @return totalBalance - total Juels of LINK held by the contract @@ -59,7 +52,6 @@ interface IFunctionsSubscriptions { function timeoutRequests(FunctionsResponse.Commitment[] calldata requestsToTimeoutByCommitment) external; // @notice Oracle withdraw LINK earned through fulfilling requests - // @dev Must be called by the Coordinator contract // @notice If amount is 0 the full balance will be withdrawn // @notice Both signing and transmitting wallets will have a balance to withdraw // @param recipient where to send the funds @@ -82,11 +74,21 @@ interface IFunctionsSubscriptions { // @dev You can manage the consumer set dynamically with addConsumer/removeConsumer. // @dev Note to fund the subscription, use transferAndCall. For example // @dev LINKTOKEN.transferAndCall( - // @dev address(REGISTRY), + // @dev address(ROUTER), // @dev amount, // @dev abi.encode(subscriptionId)); function createSubscription() external returns (uint64); + // @notice Create a new subscription and add a consumer. + // @return subscriptionId - A unique subscription id. + // @dev You can manage the consumer set dynamically with addConsumer/removeConsumer. + // @dev Note to fund the subscription, use transferAndCall. For example + // @dev LINKTOKEN.transferAndCall( + // @dev address(ROUTER), + // @dev amount, + // @dev abi.encode(subscriptionId)); + function createSubscriptionWithConsumer(address consumer) external returns (uint64 subscriptionId); + // @notice Propose a new owner for a subscription. // @dev Only callable by the Subscription's owner // @param subscriptionId - ID of the subscription @@ -125,7 +127,8 @@ interface IFunctionsSubscriptions { // @dev Used to disable subscription canceling while outstanding request are present. function pendingRequestExists(uint64 subscriptionId) external view returns (bool); - // @notice Set flags for a given subscription. + // @notice Set subscription specific flags for a subscription. + // Each byte of the flag is used to represent a resource tier that the subscription can utilize. // @param subscriptionId - ID of the subscription // @param flags - desired flag values function setFlags(uint64 subscriptionId, bytes32 flags) external; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol index 8fdd5fb68c2..5a2f85fd32e 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IOwnableFunctionsRouter.sol @@ -4,7 +4,7 @@ pragma solidity ^0.8.19; import {IFunctionsRouter} from "./IFunctionsRouter.sol"; import {IOwnable} from "../../../../shared/interfaces/IOwnable.sol"; -// @title Chainlink Functions Router interface with Ownable. +// @title Chainlink Functions Router interface with Ownability. interface IOwnableFunctionsRouter is IOwnable, IFunctionsRouter { } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol index d0d8512af17..54baf35b0cc 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol @@ -1,8 +1,23 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.19; -// @title Library of types that are used during fulfillment of a Functions request +import {IFunctionsSubscriptions} from "../interfaces/IFunctionsSubscriptions.sol"; + +// @title Library of types that are used for fulfillment of a Functions request library FunctionsResponse { + // Used to send request information from the Router to the Coordinator + struct RequestMeta { + address requestingContract; // The client contract that is sending the request + bytes data; // CBOR encoded Chainlink Functions request data, use FunctionsRequest library to encode a request + uint64 subscriptionId; // Identifier of the billing subscription that will be charged for the request + uint16 dataVersion; // The version of the structure of the CBOR encoded request data + bytes32 flags; // Per-subscription account flags + uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract will be given + uint72 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router Owner for operation of the network + IFunctionsSubscriptions.Consumer consumer; // Details about the consumer making the request + IFunctionsSubscriptions.Subscription subscription; // Details about the subscription that will be charged for the request + } + enum FulfillResult { USER_SUCCESS, // 0 USER_ERROR, // 1 @@ -14,15 +29,15 @@ library FunctionsResponse { } struct Commitment { - uint96 adminFee; // -----------┐ + uint72 adminFee; // -----------┐ address coordinator; // -------┘ address client; // ------------┐ uint64 subscriptionId; // | uint32 callbackGasLimit; // ---┘ - uint96 estimatedTotalCostJuels; // TODO pack the following - uint40 timeoutTimestamp; + uint96 estimatedTotalCostJuels; + uint32 timeoutTimestamp; bytes32 requestId; - uint80 donFee; + uint72 donFee; uint40 gasOverheadBeforeCallback; uint40 gasOverheadAfterCallback; } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index c6d2a46a3e9..e6cd87b0aa4 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -19,7 +19,7 @@ contract FunctionsRouterSetup is BaseTest { TermsOfServiceAllowList internal s_termsOfServiceAllowList; uint16 internal s_maxConsumersPerSubscription = 100; - uint96 internal s_adminFee = 561724823; + uint72 internal s_adminFee = 561724823; bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; address internal s_linkToken = 0x01BE23585060835E02B77ef475b0Cc51aA1e0709; @@ -31,7 +31,7 @@ contract FunctionsRouterSetup is BaseTest { s_functionsRouter = new FunctionsRouter(s_linkToken, getRouterConfig()); s_linkEthFeed = new MockV3Aggregator(0, LINK_ETH_RATE); - s_termsOfServiceAllowList = new TermsOfServiceAllowList(address(s_functionsRouter), getTermsOfServiceConfig()); + s_termsOfServiceAllowList = new TermsOfServiceAllowList(getTermsOfServiceConfig()); } function getRouterConfig() public view returns (FunctionsRouter.Config memory) { @@ -43,7 +43,8 @@ contract FunctionsRouterSetup is BaseTest { maxConsumersPerSubscription: s_maxConsumersPerSubscription, adminFee: s_adminFee, handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, - maxCallbackGasLimits: maxCallbackGasLimits + maxCallbackGasLimits: maxCallbackGasLimits, + gasForCallExactCheck: 5000 }); } @@ -67,10 +68,9 @@ contract FunctionsRouterSetup is BaseTest { } } -contract FunctionsRouter_createSubscription is FunctionsRouterSetup { - event SubscriptionCreated(uint64 indexed subscriptionId, address owner); - - function testCreateSubscriptionSuccess() public { +contract FunctionsSetRoutes is FunctionsRouterSetup { + function setUp() public virtual override { + FunctionsRouterSetup.setUp(); s_functionsCoordinator = new FunctionsCoordinator( address(s_functionsRouter), getCoordinatorConfig(), @@ -87,7 +87,17 @@ contract FunctionsRouter_createSubscription is FunctionsRouterSetup { s_functionsRouter.proposeContractsUpdate(proposedContractSetIds, proposedContractSetAddresses); s_functionsRouter.updateContracts(); + } +} +contract FunctionsRouter_createSubscription is FunctionsSetRoutes { + function setUp() public virtual override { + FunctionsSetRoutes.setUp(); + } + + event SubscriptionCreated(uint64 indexed subscriptionId, address owner); + + function testCreateSubscriptionSuccess() public { vm.expectEmit(); emit SubscriptionCreated(1, OWNER); diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol index 68057af47b6..92255e0b572 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientTestHelper.sol @@ -31,7 +31,8 @@ contract FunctionsClientTestHelper is FunctionsClient { ) public returns (bytes32 requestId) { FunctionsRequest.Request memory request; request.initializeRequestForInlineJavaScript(sourceCode); - requestId = _sendRequest(request, subscriptionId, callbackGasLimit, donId); + bytes memory requestData = FunctionsRequest.encodeCBOR(request); + requestId = _sendRequest(requestData, subscriptionId, callbackGasLimit, donId); emit SendRequestInvoked(requestId, sourceCode, subscriptionId); } diff --git a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts index ba1ff5959e3..0fb02d00ee5 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts @@ -10,6 +10,7 @@ import { createSubscription, getEventArg, parseOracleRequestEventArgs, + encodeReport, } from './utils' const setup = getSetupFactory() @@ -153,23 +154,17 @@ describe('Functions Client', () => { const response = stringToBytes('response') const error = stringToBytes('') - const abi = ethers.utils.defaultAbiCoder const oracleRequestEvent = await contracts.coordinator.queryFilter( contracts.coordinator.filters.OracleRequest(), ) const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] - const offchainMetadata = stringToBytes('') - const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], - [ - [ethers.utils.hexZeroPad(requestId, 32)], - [response], - [error], - [onchainMetadata], - [offchainMetadata], - ], + const report = await encodeReport( + ethers.utils.hexZeroPad(requestId, 32), + response, + error, + onchainMetadata, + stringToBytes(''), ) - await expect(contracts.coordinator.callReport(report)) .to.emit(contracts.coordinator, 'OracleResponse') .withArgs(requestId, await roles.defaultAccount.getAddress()) diff --git a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts index 687ef65f6b8..aecad5466bb 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsRouter.test.ts @@ -1,4 +1,6 @@ import { expect } from 'chai' +import { ethers } from 'hardhat' +import { stringToBytes } from '../../../test-helpers/helpers' import { getSetupFactory, FunctionsContracts, @@ -52,4 +54,13 @@ describe('Functions Router - Request lifecycle', () => { ) }) }) + describe('Allow List path', () => { + it('non-owner is unable to set Allow List ID', async () => { + await expect( + contracts.router + .connect(roles.stranger) + .setAllowListId(ethers.utils.hexZeroPad(stringToBytes(''), 32)), + ).to.be.revertedWith('Only callable by owner') + }) + }) }) diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 8cf513297e6..29db885cce9 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -11,6 +11,7 @@ import { ids, getEventArg, accessControlMockPrivateKey, + encodeReport, } from './utils' import { stringToBytes } from '../../../test-helpers/helpers' @@ -75,7 +76,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.subOwner) .addConsumer(subId, randomAddressString()), - ).to.be.revertedWith(`TooManyConsumers()`) + ).to.be.revertedWith(`TooManyConsumers`) }) }) @@ -104,12 +105,12 @@ describe('Functions Router - Subscriptions', () => { ) .to.emit(contracts.router, 'SubscriptionOwnerTransferRequested') .withArgs(subId, roles.subOwnerAddress, roles.strangerAddress) - // Same request is a noop + // Same request reverts await expect( contracts.router .connect(roles.subOwner) .proposeSubscriptionOwnerTransfer(subId, roles.strangerAddress), - ).to.not.emit(contracts.router, 'SubscriptionOwnerTransferRequested') + ).to.be.revertedWith('InvalidCalldata') }) }) @@ -213,7 +214,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.subOwner) .addConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`TooManyConsumers()`) + ).to.be.revertedWith(`TooManyConsumers`) // Same is true if we first create with the maximum const consumers: string[] = [] for (let i = 0; i < 100; i++) { @@ -229,7 +230,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.subOwner) .addConsumer(subId, roles.strangerAddress), - ).to.be.revertedWith(`TooManyConsumers()`) + ).to.be.revertedWith(`TooManyConsumers`) }) it('owner can update', async function () { await expect( @@ -442,7 +443,7 @@ describe('Functions Router - Subscriptions', () => { contracts.router .connect(roles.subOwner) .cancelSubscription(subId, roles.strangerAddress), - ).to.be.revertedWith('PendingRequestExists()') + ).to.be.revertedWith('CannotRemoveWithPendingRequests()') // However the owner is able to cancel // funds go to the sub owner. await expect( @@ -618,21 +619,17 @@ describe('Functions Router - Subscriptions', () => { const response = stringToBytes('response') const error = stringToBytes('') - const abi = ethers.utils.defaultAbiCoder const oracleRequestEvent = await contracts.coordinator.queryFilter( contracts.coordinator.filters.OracleRequest(), ) const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] const offchainMetadata = stringToBytes('') - const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], - [ - [ethers.utils.hexZeroPad(requestId, 32)], - [response], - [error], - [onchainMetadata], - [offchainMetadata], - ], + const report = await encodeReport( + ethers.utils.hexZeroPad(requestId, 32), + response, + error, + onchainMetadata, + offchainMetadata, ) await expect(contracts.coordinator.callReport(report, { gasPrice })) @@ -706,21 +703,17 @@ describe('Functions Router - Subscriptions', () => { const response = stringToBytes('response') const error = stringToBytes('') - const abi = ethers.utils.defaultAbiCoder const oracleRequestEvent = await contracts.coordinator.queryFilter( contracts.coordinator.filters.OracleRequest(), ) const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] const offchainMetadata = stringToBytes('') - const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], - [ - [ethers.utils.hexZeroPad(requestId, 32)], - [response], - [error], - [onchainMetadata], - [offchainMetadata], - ], + const report = await encodeReport( + ethers.utils.hexZeroPad(requestId, 32), + response, + error, + onchainMetadata, + offchainMetadata, ) await expect(contracts.coordinator.callReport(report, { gasPrice })) @@ -817,21 +810,17 @@ describe('Functions Router - Subscriptions', () => { const response = stringToBytes('response') const error = stringToBytes('') - const abi = ethers.utils.defaultAbiCoder const oracleRequestEvent = await contracts.coordinator.queryFilter( contracts.coordinator.filters.OracleRequest(), ) const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] const offchainMetadata = stringToBytes('') - const report = abi.encode( - ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], - [ - [ethers.utils.hexZeroPad(requestId, 32)], - [response], - [error], - [onchainMetadata], - [offchainMetadata], - ], + const report = await encodeReport( + ethers.utils.hexZeroPad(requestId, 32), + response, + error, + onchainMetadata, + offchainMetadata, ) await expect(contracts.coordinator.callReport(report, { gasPrice })) diff --git a/contracts/test/v0.8/functions/v1/GasGolf.test.ts b/contracts/test/v0.8/functions/v1/GasGolf.test.ts index 3e52f8cf8e9..32cc660beda 100644 --- a/contracts/test/v0.8/functions/v1/GasGolf.test.ts +++ b/contracts/test/v0.8/functions/v1/GasGolf.test.ts @@ -2,6 +2,7 @@ import { ethers } from 'hardhat' import { BigNumber } from 'ethers' import { accessControlMockPrivateKey, + encodeReport, FunctionsContracts, FunctionsRoles, getEventArg, @@ -94,15 +95,12 @@ describe('Gas Golf', () => { const error = stringToBytes('') const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] const offchainMetadata = stringToBytes('') - const report = ethers.utils.defaultAbiCoder.encode( - ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], - [ - [ethers.utils.hexZeroPad(requestId, 32)], - [response], - [error], - [onchainMetadata], - [offchainMetadata], - ], + const report = await encodeReport( + ethers.utils.hexZeroPad(requestId, 32), + response, + error, + onchainMetadata, + offchainMetadata, ) const fulfillmentTx = await contracts.coordinator.callReport(report) const { gasUsed: fulfillmentTxGasUsed } = await fulfillmentTx.wait() diff --git a/contracts/test/v0.8/functions/v1/RouterBase.test.ts b/contracts/test/v0.8/functions/v1/RouterBase.test.ts index 350113904c7..3a3b58b8f6b 100644 --- a/contracts/test/v0.8/functions/v1/RouterBase.test.ts +++ b/contracts/test/v0.8/functions/v1/RouterBase.test.ts @@ -84,7 +84,7 @@ describe('FunctionsRouter - Base', () => { contracts.coordinator.filters.OracleRequest(), ) const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] - const report = encodeReport( + const report = await encodeReport( ethers.utils.hexZeroPad(requestId, 32), stringToHex('hello world'), stringToHex(''), diff --git a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts index 3405e4582db..1e1ad18a7d6 100644 --- a/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts +++ b/contracts/test/v0.8/functions/v1/TermsOfServiceAllowList.test.ts @@ -139,7 +139,7 @@ describe('ToS Access Control', () => { contracts.accessControl .connect(roles.stranger) .blockSender(roles.subOwnerAddress), - ).to.be.revertedWith('OnlyCallableByRouterOwner') + ).to.be.revertedWith('Only callable by owner') }) it('removes the ability to re-accept the terms of service', async () => { await contracts.accessControl.blockSender(roles.subOwnerAddress) diff --git a/contracts/test/v0.8/functions/v1/utils.ts b/contracts/test/v0.8/functions/v1/utils.ts index 6672a18f5cc..a7a89871f32 100644 --- a/contracts/test/v0.8/functions/v1/utils.ts +++ b/contracts/test/v0.8/functions/v1/utils.ts @@ -1,6 +1,7 @@ import { ethers } from 'hardhat' import { BigNumber, ContractFactory, Signer, Contract, providers } from 'ethers' import { Roles, getUsers } from '../../../test-helpers/setup' +import { EventFragment } from 'ethers/lib/utils' export type FunctionsRoles = Roles & { subOwner: Signer @@ -43,17 +44,30 @@ export const stringToHex = (s: string) => { return ethers.utils.hexlify(ethers.utils.toUtf8Bytes(s)) } -export const encodeReport = ( +export const encodeReport = async ( requestId: string, result: string, err: string, - onchainMetadata: string, + onchainMetadata: any, offchainMetadata: string, ) => { + const functionsResponse = await ethers.getContractFactory( + 'src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol:FunctionsCoordinator', + ) + const onchainMetadataBytes = functionsResponse.interface._abiCoder.encode( + [ + getEventInputs( + Object.values(functionsResponse.interface.events), + 'OracleRequest', + 9, + ), + ], + [[...onchainMetadata]], + ) const abi = ethers.utils.defaultAbiCoder return abi.encode( ['bytes32[]', 'bytes[]', 'bytes[]', 'bytes[]', 'bytes[]'], - [[requestId], [result], [err], [onchainMetadata], [offchainMetadata]], + [[requestId], [result], [err], [onchainMetadataBytes], [offchainMetadata]], ) } @@ -62,12 +76,14 @@ export type FunctionsRouterConfig = { adminFee: number handleOracleFulfillmentSelector: string maxCallbackGasLimits: number[] + gasForCallExactCheck: number } export const functionsRouterConfig: FunctionsRouterConfig = { maxConsumersPerSubscription: 100, adminFee: 0, handleOracleFulfillmentSelector: '0x0ca76175', maxCallbackGasLimits: [300_000, 500_000, 1_000_000], + gasForCallExactCheck: 5000, } export type CoordinatorConfig = { maxCallbackGasLimit: number @@ -239,7 +255,7 @@ export function getSetupFactory(): () => { const accessControl = await factories.accessControlFactory .connect(roles.defaultAccount) - .deploy(router.address, accessControlConfig) + .deploy(accessControlConfig) const client = await factories.clientTestHelperFactory .connect(roles.consumer) @@ -287,6 +303,20 @@ export function getEventArg(events: any, eventName: string, argIndex: number) { return undefined } +export function getEventInputs( + events: EventFragment[], + eventName: string, + argIndex: number, +) { + if (Array.isArray(events)) { + const event = events.find((e) => e.name.includes(eventName)) + if (event && Array.isArray(event.inputs) && event.inputs.length > 0) { + return event.inputs[argIndex] + } + } + throw 'Not found' +} + export async function parseOracleRequestEventArgs( tx: providers.TransactionResponse, ) { diff --git a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go index 068ae3a2c6d..d86c07f1705 100644 --- a/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go +++ b/core/gethwrappers/functions/generated/functions_allow_list/functions_allow_list.go @@ -36,15 +36,15 @@ type TermsOfServiceAllowListConfig struct { } var TermsOfServiceAllowListMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"AddedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"BlockedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"indexed\":false,\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"UnblockedAccess\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200154a3803806200154a8339810160408190526200003491620002bf565b33806000846001600160a01b0381166200006157604051632530e88560e11b815260040160405180910390fd5b6001600160a01b039081166080528216620000c35760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000f657620000f68162000112565b5050506200010a81620001bd60201b60201c565b50506200035d565b336001600160a01b038216036200016c5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000ba565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001c762000244565b805160058054602080850180516001600160a81b0319909316941515610100600160a81b03198116959095176101006001600160a01b039485160217909355604080519485529251909116908301527f0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a910160405180910390a150565b6000546001600160a01b03163314620002a05760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401620000ba565b565b80516001600160a01b0381168114620002ba57600080fd5b919050565b6000808284036060811215620002d457600080fd5b620002df84620002a2565b92506040601f1982011215620002f457600080fd5b50604080519081016001600160401b03811182821017156200032657634e487b7160e01b600052604160045260246000fd5b604052602084015180151581146200033d57600080fd5b81526200034d60408501620002a2565b6020820152809150509250929050565b6080516111ca62000380600039600081816104f201526107a701526111ca6000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806382184c7b1161008c578063a39b06e311610066578063a39b06e3146101b8578063a5e1d61d146101d9578063c3f909d4146101ec578063f2fde38b1461024b57600080fd5b806382184c7b1461016a57806389f9a2c41461017d5780638da5cb5b1461019057600080fd5b80636b14daf8116100bd5780636b14daf81461012a57806379ba50971461014d578063817ef62e1461015557600080fd5b8063181f5a77146100e45780633908c4d41461010257806347663acb14610117575b600080fd5b6100ec61025e565b6040516100f99190610e29565b60405180910390f35b610115610110366004610eb7565b61027a565b005b610115610125366004610f1c565b6104f0565b61013d610138366004610f39565b610668565b60405190151581526020016100f9565b610115610692565b61015d610794565b6040516100f99190610fbe565b610115610178366004610f1c565b6107a5565b61011561018b366004611018565b610925565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f9565b6101cb6101c63660046110a3565b6109e0565b6040519081526020016100f9565b61013d6101e7366004610f1c565b610a3e565b60408051808201825260008082526020918201528151808301835260055460ff8116151580835273ffffffffffffffffffffffffffffffffffffffff6101009092048216928401928352845190815291511691810191909152016100f9565b610115610259366004610f1c565b610a7f565b6040518060600160405280602c8152602001611192602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526004602052604090205460ff16156102da576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006102e686866109e0565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206005546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156103c0573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610417576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061045c57503373ffffffffffffffffffffffffffffffffffffffff87161480159061045c5750333b155b15610493576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61049e600286610a93565b5060405173ffffffffffffffffffffffffffffffffffffffff861681527f87286ad1f399c8e82bf0c4ef4fcdc570ea2e1e92176e5c848b6413545b885db49060200160405180910390a1505050505050565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af115801561055d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061058191906110dc565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146105e5576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff811660008181526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905590519182527f28bbd0761309a99e8fb5e5d02ada0b7b2db2e5357531ff5dbfc205c3f5b6592b91015b60405180910390a150565b60055460009060ff1661067d5750600161068b565b610688600285610ab5565b90505b9392505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610718576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60606107a06002610ae4565b905090565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16638da5cb5b6040518163ffffffff1660e01b81526004016020604051808303816000875af1158015610812573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061083691906110dc565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461089a576040517fa0f0a44600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108a5600282610af1565b5073ffffffffffffffffffffffffffffffffffffffff811660008181526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e1910161065d565b61092d610b13565b805160058054602080850180517fffffffffffffffffffffff0000000000000000000000000000000000000000009093169415157fffffffffffffffffffffff0000000000000000000000000000000000000000ff81169590951761010073ffffffffffffffffffffffffffffffffffffffff9485160217909355604080519485529251909116908301527f0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a910161065d565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60055460009060ff16610a5357506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526004602052604090205460ff1690565b610a87610b13565b610a9081610b96565b50565b600061068b8373ffffffffffffffffffffffffffffffffffffffff8416610c8b565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561068b565b6060600061068b83610cda565b600061068b8373ffffffffffffffffffffffffffffffffffffffff8416610d36565b60005473ffffffffffffffffffffffffffffffffffffffff163314610b94576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161070f565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610c15576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161070f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000818152600183016020526040812054610cd257508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610a38565b506000610a38565b606081600001805480602002602001604051908101604052809291908181526020018280548015610d2a57602002820191906000526020600020905b815481526020019060010190808311610d16575b50505050509050919050565b60008181526001830160205260408120548015610e1f576000610d5a6001836110f9565b8554909150600090610d6e906001906110f9565b9050818114610dd3576000866000018281548110610d8e57610d8e611133565b9060005260206000200154905080876000018481548110610db157610db1611133565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610de457610de4611162565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610a38565b6000915050610a38565b600060208083528351808285015260005b81811015610e5657858101830151858201604001528201610e3a565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a9057600080fd5b600080600080600060a08688031215610ecf57600080fd5b8535610eda81610e95565b94506020860135610eea81610e95565b93506040860135925060608601359150608086013560ff81168114610f0e57600080fd5b809150509295509295909350565b600060208284031215610f2e57600080fd5b813561068b81610e95565b600080600060408486031215610f4e57600080fd5b8335610f5981610e95565b9250602084013567ffffffffffffffff80821115610f7657600080fd5b818601915086601f830112610f8a57600080fd5b813581811115610f9957600080fd5b876020828501011115610fab57600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b8181101561100c57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610fda565b50909695505050505050565b60006040828403121561102a57600080fd5b6040516040810181811067ffffffffffffffff82111715611074577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040528235801515811461108757600080fd5b8152602083013561109781610e95565b60208201529392505050565b600080604083850312156110b657600080fd5b82356110c181610e95565b915060208301356110d181610e95565b809150509250929050565b6000602082840312156110ee57600080fd5b815161068b81610e95565b81810381811115610a38577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidSignature\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidUsage\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RecipientIsBlocked\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"AddedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"BlockedAccess\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"indexed\":false,\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"}],\"name\":\"UnblockedAccess\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"r\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"s\",\"type\":\"bytes32\"},{\"internalType\":\"uint8\",\"name\":\"v\",\"type\":\"uint8\"}],\"name\":\"acceptTermsOfService\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"blockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllAllowedSenders\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"acceptor\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getMessage\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"user\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"hasAccess\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"isBlockedSender\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"unblockSender\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"enabled\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"signerPublicKey\",\"type\":\"address\"}],\"internalType\":\"structTermsOfServiceAllowList.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60806040523480156200001157600080fd5b50604051620012c4380380620012c4833981016040819052620000349162000269565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d9565b505050620000d2816200018460201b60201c565b50620002ea565b336001600160a01b03821603620001335760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6200018e6200020b565b805160058054602080850180516001600160a81b0319909316941515610100600160a81b03198116959095176101006001600160a01b039485160217909355604080519485529251909116908301527f0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a910160405180910390a150565b6000546001600160a01b03163314620002675760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000082565b565b6000604082840312156200027c57600080fd5b604080519081016001600160401b0381118282101715620002ad57634e487b7160e01b600052604160045260246000fd5b60405282518015158114620002c157600080fd5b815260208301516001600160a01b0381168114620002de57600080fd5b60208201529392505050565b610fca80620002fa6000396000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806382184c7b1161008c578063a39b06e311610066578063a39b06e3146101b8578063a5e1d61d146101d9578063c3f909d4146101ec578063f2fde38b1461024b57600080fd5b806382184c7b1461016a57806389f9a2c41461017d5780638da5cb5b1461019057600080fd5b80636b14daf8116100bd5780636b14daf81461012a57806379ba50971461014d578063817ef62e1461015557600080fd5b8063181f5a77146100e45780633908c4d41461010257806347663acb14610117575b600080fd5b6100ec61025e565b6040516100f99190610c4f565b60405180910390f35b610115610110366004610ce4565b61027a565b005b610115610125366004610d45565b6104f0565b61013d610138366004610d60565b61057b565b60405190151581526020016100f9565b6101156105a5565b61015d6106a7565b6040516100f99190610de3565b610115610178366004610d45565b6106b8565b61011561018b366004610e3d565b61074b565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f9565b6101cb6101c6366004610ec6565b610806565b6040519081526020016100f9565b61013d6101e7366004610d45565b610864565b60408051808201825260008082526020918201528151808301835260055460ff8116151580835273ffffffffffffffffffffffffffffffffffffffff6101009092048216928401928352845190815291511691810191909152016100f9565b610115610259366004610d45565b6108a5565b6040518060600160405280602c8152602001610f92602c913981565b73ffffffffffffffffffffffffffffffffffffffff841660009081526004602052604090205460ff16156102da576040517f62b7a34d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006102e68686610806565b6040517f19457468657265756d205369676e6564204d6573736167653a0a3332000000006020820152603c810191909152605c01604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815282825280516020918201206005546000855291840180845281905260ff8616928401929092526060830187905260808301869052909250610100900473ffffffffffffffffffffffffffffffffffffffff169060019060a0016020604051602081039080840390855afa1580156103c0573d6000803e3d6000fd5b5050506020604051035173ffffffffffffffffffffffffffffffffffffffff1614610417576040517f8baa579f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff861614158061045c57503373ffffffffffffffffffffffffffffffffffffffff87161480159061045c5750333b155b15610493576040517f381cfcbd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61049e6002866108b9565b5060405173ffffffffffffffffffffffffffffffffffffffff861681527f87286ad1f399c8e82bf0c4ef4fcdc570ea2e1e92176e5c848b6413545b885db49060200160405180910390a1505050505050565b6104f86108db565b73ffffffffffffffffffffffffffffffffffffffff811660008181526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905590519182527f28bbd0761309a99e8fb5e5d02ada0b7b2db2e5357531ff5dbfc205c3f5b6592b91015b60405180910390a150565b60055460009060ff166105905750600161059e565b61059b60028561095e565b90505b9392505050565b60015473ffffffffffffffffffffffffffffffffffffffff16331461062b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60606106b3600261098d565b905090565b6106c06108db565b6106cb60028261099a565b5073ffffffffffffffffffffffffffffffffffffffff811660008181526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f337cd0f3f594112b6d830afb510072d3b08556b446514f73b8109162fd1151e19101610570565b6107536108db565b805160058054602080850180517fffffffffffffffffffffff0000000000000000000000000000000000000000009093169415157fffffffffffffffffffffff0000000000000000000000000000000000000000ff81169590951761010073ffffffffffffffffffffffffffffffffffffffff9485160217909355604080519485529251909116908301527f0d22b8a99f411b3dd338c961284f608489ca0dab9cdad17366a343c361bcf80a9101610570565b6040517fffffffffffffffffffffffffffffffffffffffff000000000000000000000000606084811b8216602084015283901b1660348201526000906048016040516020818303038152906040528051906020012090505b92915050565b60055460009060ff1661087957506000919050565b5073ffffffffffffffffffffffffffffffffffffffff1660009081526004602052604090205460ff1690565b6108ad6108db565b6108b6816109bc565b50565b600061059e8373ffffffffffffffffffffffffffffffffffffffff8416610ab1565b60005473ffffffffffffffffffffffffffffffffffffffff16331461095c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610622565b565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600183016020526040812054151561059e565b6060600061059e83610b00565b600061059e8373ffffffffffffffffffffffffffffffffffffffff8416610b5c565b3373ffffffffffffffffffffffffffffffffffffffff821603610a3b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610622565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000818152600183016020526040812054610af85750815460018181018455600084815260208082209093018490558454848252828601909352604090209190915561085e565b50600061085e565b606081600001805480602002602001604051908101604052809291908181526020018280548015610b5057602002820191906000526020600020905b815481526020019060010190808311610b3c575b50505050509050919050565b60008181526001830160205260408120548015610c45576000610b80600183610ef9565b8554909150600090610b9490600190610ef9565b9050818114610bf9576000866000018281548110610bb457610bb4610f33565b9060005260206000200154905080876000018481548110610bd757610bd7610f33565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080610c0a57610c0a610f62565b60019003818190600052602060002001600090559055856001016000868152602001908152602001600020600090556001935050505061085e565b600091505061085e565b600060208083528351808285015260005b81811015610c7c57858101830151858201604001528201610c60565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff81168114610cdf57600080fd5b919050565b600080600080600060a08688031215610cfc57600080fd5b610d0586610cbb565b9450610d1360208701610cbb565b93506040860135925060608601359150608086013560ff81168114610d3757600080fd5b809150509295509295909350565b600060208284031215610d5757600080fd5b61059e82610cbb565b600080600060408486031215610d7557600080fd5b610d7e84610cbb565b9250602084013567ffffffffffffffff80821115610d9b57600080fd5b818601915086601f830112610daf57600080fd5b813581811115610dbe57600080fd5b876020828501011115610dd057600080fd5b6020830194508093505050509250925092565b6020808252825182820181905260009190848201906040850190845b81811015610e3157835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101610dff565b50909695505050505050565b600060408284031215610e4f57600080fd5b6040516040810181811067ffffffffffffffff82111715610e99577f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405282358015158114610eac57600080fd5b8152610eba60208401610cbb565b60208201529392505050565b60008060408385031215610ed957600080fd5b610ee283610cbb565b9150610ef060208401610cbb565b90509250929050565b8181038181111561085e577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe46756e6374696f6e73205465726d73206f66205365727669636520416c6c6f77204c6973742076312e302e30a164736f6c6343000813000a", } var TermsOfServiceAllowListABI = TermsOfServiceAllowListMetaData.ABI var TermsOfServiceAllowListBin = TermsOfServiceAllowListMetaData.Bin -func DeployTermsOfServiceAllowList(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address, config TermsOfServiceAllowListConfig) (common.Address, *types.Transaction, *TermsOfServiceAllowList, error) { +func DeployTermsOfServiceAllowList(auth *bind.TransactOpts, backend bind.ContractBackend, config TermsOfServiceAllowListConfig) (common.Address, *types.Transaction, *TermsOfServiceAllowList, error) { parsed, err := TermsOfServiceAllowListMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -53,7 +53,7 @@ func DeployTermsOfServiceAllowList(auth *bind.TransactOpts, backend bind.Contrac return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(TermsOfServiceAllowListBin), backend, router, config) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(TermsOfServiceAllowListBin), backend, config) if err != nil { return common.Address{}, nil, nil, err } diff --git a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go index de90bc5ac5f..6dc02520146 100644 --- a/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go +++ b/core/gethwrappers/functions/generated/functions_client_example/functions_client_example.go @@ -32,7 +32,7 @@ var ( var FunctionsClientExampleMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFulfill\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"UnexpectedRequestID\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162001a8d38038062001a8d833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b6080516118b8620001d5600039600081816101c60152610c4f01526118b86000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc366004611304565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e16101433660046113d7565b61022d565b6101176201117081565b6100e161033f565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e16101993660046114bb565b610441565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610228838383610455565b505050565b610235610523565b61027e6040805161010081019091528060008152602001600081526020016000815260200160608152602001606081526020016060815260200160608152602001606081525090565b6102c089898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105a69050565b85156103085761030887878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105b79050565b83156103225761032261031b85876114f1565b8290610601565b61033181846201117085610644565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610449610523565b61045281610663565b50565b8260025414610493576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103bc565b61049c82610758565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104de81610758565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146105a4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103bc565b565b6105b382600080846107da565b5050565b80516000036105f2576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b805160000361063c576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60c090910152565b600061065a61065286610871565b858585610c4a565b95945050505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036106e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103bc565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000806020905060208351101561076d575081515b60005b818110156107d3576107838160086115e7565b848281518110610795576107956115fe565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c92909217916107cc8161162d565b9050610770565b5050919050565b8051600003610815576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8383600281111561082857610828611589565b9081600281111561083b5761083b611589565b9052506040840182801561085157610851611589565b9081801561086157610861611589565b9052506060909301929092525050565b60606000610880610100610d29565b90506108ca6040518060400160405280600c81526020017f636f64654c6f636174696f6e000000000000000000000000000000000000000081525082610d4a90919063ffffffff16565b82516108e89060028111156108e1576108e1611589565b8290610d63565b60408051808201909152600881527f6c616e67756167650000000000000000000000000000000000000000000000006020820152610927908290610d4a565b604083015161093e9080156108e1576108e1611589565b60408051808201909152600681527f736f757263650000000000000000000000000000000000000000000000000000602082015261097d908290610d4a565b606083015161098d908290610d4a565b60a083015151156109e75760408051808201909152601081527f726571756573745369676e61747572650000000000000000000000000000000060208201526109d7908290610d4a565b60a08301516109e7908290610d98565b60c08301515115610a945760408051808201909152600481527f61726773000000000000000000000000000000000000000000000000000000006020820152610a31908290610d4a565b610a3a81610da5565b60005b8360c0015151811015610a8a57610a7a8460c001518281518110610a6357610a636115fe565b602002602001015183610d4a90919063ffffffff16565b610a838161162d565b9050610a3d565b50610a9481610dc9565b60808301515115610b9557600083602001516002811115610ab757610ab7611589565b03610aee576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051808201909152600f81527f736563726574734c6f636174696f6e00000000000000000000000000000000006020820152610b2d908290610d4a565b610b46836020015160028111156108e1576108e1611589565b60408051808201909152600781527f73656372657473000000000000000000000000000000000000000000000000006020820152610b85908290610d4a565b6080830151610b95908290610d98565b60e08301515115610c425760408051808201909152600981527f62797465734172677300000000000000000000000000000000000000000000006020820152610bdf908290610d4a565b610be881610da5565b60005b8360e0015151811015610c3857610c288460e001518281518110610c1157610c116115fe565b602002602001015183610d9890919063ffffffff16565b610c318161162d565b9050610beb565b50610c4281610dc9565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610caf959493929190611665565b6020604051808303816000875af1158015610cce573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610cf29190611705565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b610d316111bb565b8051610d3d9083610de7565b5060006020820152919050565b610d578260038351610e61565b81516102289082610f88565b8151610d709060c2610fb0565b506105b38282604051602001610d8891815260200190565b6040516020818303038152906040525b610d578260028351610e61565b610db0816004611019565b600181602001818151610dc3919061171e565b90525050565b610dd4816007611019565b600181602001818151610dc39190611731565b604080518082019091526060815260006020820152610e07602083611744565b15610e2f57610e17602083611744565b610e22906020611731565b610e2c908361171e565b91505b602080840183905260405180855260008152908184010181811015610e5357600080fd5b604052508290505b92915050565b60178167ffffffffffffffff1611610e8e578251610e889060e0600585901b168317610fb0565b50505050565b60ff8167ffffffffffffffff1611610ed0578251610eb7906018611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166001611030565b61ffff8167ffffffffffffffff1611610f13578251610efa906019611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166002611030565b63ffffffff8167ffffffffffffffff1611610f58578251610f3f90601a611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166004611030565b8251610f6f90601b611fe0600586901b1617610fb0565b508251610e889067ffffffffffffffff83166008611030565b604080518082019091526060815260006020820152610fa9838384516110b5565b9392505050565b6040805180820190915260608152600060208201528251516000610fd582600161171e565b905084602001518210610ff657610ff685610ff18360026115e7565b6111a4565b845160208382010185815350805182111561100f578181525b5093949350505050565b815161022890601f611fe0600585901b1617610fb0565b6040805180820190915260608152600060208201528351516000611054828561171e565b905085602001518111156110715761107186610ff18360026115e7565b600060016110818661010061189f565b61108b9190611731565b905086518281018783198251161781525080518311156110a9578281525b50959695505050505050565b60408051808201909152606081526000602082015282518211156110d857600080fd5b83515160006110e7848361171e565b905085602001518111156111045761110486610ff18360026115e7565b85518051838201602001916000918085111561111e578482525b505050602086015b6020861061115e578051825261113d60208361171e565b915061114a60208261171e565b9050611157602087611731565b9550611126565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111b08383610de7565b50610e888382610f88565b60405180604001604052806111e3604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611266576112666111f0565b604052919050565b600067ffffffffffffffff831115611288576112886111f0565b6112b960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8601160161121f565b90508281528383830111156112cd57600080fd5b828260208301376000602084830101529392505050565b600082601f8301126112f557600080fd5b610fa98383356020850161126e565b60008060006060848603121561131957600080fd5b83359250602084013567ffffffffffffffff8082111561133857600080fd5b611344878388016112e4565b9350604086013591508082111561135a57600080fd5b50611367868287016112e4565b9150509250925092565b60008083601f84011261138357600080fd5b50813567ffffffffffffffff81111561139b57600080fd5b6020830191508360208285010111156113b357600080fd5b9250929050565b803567ffffffffffffffff811681146113d257600080fd5b919050565b60008060008060008060008060a0898b0312156113f357600080fd5b883567ffffffffffffffff8082111561140b57600080fd5b6114178c838d01611371565b909a50985060208b013591508082111561143057600080fd5b61143c8c838d01611371565b909850965060408b013591508082111561145557600080fd5b818b0191508b601f83011261146957600080fd5b81358181111561147857600080fd5b8c60208260051b850101111561148d57600080fd5b6020830196508095505050506114a560608a016113ba565b9150608089013590509295985092959890939650565b6000602082840312156114cd57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610fa957600080fd5b600067ffffffffffffffff8084111561150c5761150c6111f0565b8360051b602061151d81830161121f565b86815291850191818101903684111561153557600080fd5b865b8481101561157d5780358681111561154f5760008081fd5b880136601f8201126115615760008081fd5b61156f36823587840161126e565b845250918301918301611537565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082028115828204841417610e5b57610e5b6115b8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361165e5761165e6115b8565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156116a35788810183015185820160c001528201611687565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116850101925050506116ec604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b60006020828403121561171757600080fd5b5051919050565b80820180821115610e5b57610e5b6115b8565b81810381811115610e5b57610e5b6115b8565b60008261177a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b600181815b808511156117d857817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117be576117be6115b8565b808516156117cb57918102915b93841c9390800290611784565b509250929050565b6000826117ef57506001610e5b565b816117fc57506000610e5b565b8160018114611812576002811461181c57611838565b6001915050610e5b565b60ff84111561182d5761182d6115b8565b50506001821b610e5b565b5060208310610133831016604e8410600b841016171561185b575081810a610e5b565b611865838361177f565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04821115611897576118976115b8565b029392505050565b6000610fa983836117e056fea164736f6c6343000813000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001a7638038062001a76833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b6080516118a1620001d5600039600081816101c60152610a2a01526118a16000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc3660046112ed565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e16101433660046113c0565b61022d565b6101176201117081565b6100e1610347565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e16101993660046114a4565b610449565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361045d565b505050565b61023561052b565b61027e6040805161010081019091528060008152602001600081526020016000815260200160608152602001606081526020016060815260200160608152602001606081525090565b6102c089898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105ae9050565b85156103085761030887878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105bf9050565b83156103225761032261031b85876114da565b8290610609565b61033961032e8261064c565b846201117085610a25565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103cd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61045161052b565b61045a81610b04565b50565b826002541461049b576040517fd068bf5b000000000000000000000000000000000000000000000000000000008152600481018490526024016103c4565b6104a482610bf9565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104e681610bf9565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146105ac576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103c4565b565b6105bb8260008084610c7b565b5050565b80516000036105fa576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b8051600003610644576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60c090910152565b6060600061065b610100610d12565b90506106a56040518060400160405280600c81526020017f636f64654c6f636174696f6e000000000000000000000000000000000000000081525082610d3390919063ffffffff16565b82516106c39060028111156106bc576106bc611572565b8290610d4c565b60408051808201909152600881527f6c616e67756167650000000000000000000000000000000000000000000000006020820152610702908290610d33565b60408301516107199080156106bc576106bc611572565b60408051808201909152600681527f736f7572636500000000000000000000000000000000000000000000000000006020820152610758908290610d33565b6060830151610768908290610d33565b60a083015151156107c25760408051808201909152601081527f726571756573745369676e61747572650000000000000000000000000000000060208201526107b2908290610d33565b60a08301516107c2908290610d81565b60c0830151511561086f5760408051808201909152600481527f6172677300000000000000000000000000000000000000000000000000000000602082015261080c908290610d33565b61081581610d8e565b60005b8360c0015151811015610865576108558460c00151828151811061083e5761083e6115a1565b602002602001015183610d3390919063ffffffff16565b61085e816115ff565b9050610818565b5061086f81610db2565b608083015151156109705760008360200151600281111561089257610892611572565b036108c9576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051808201909152600f81527f736563726574734c6f636174696f6e00000000000000000000000000000000006020820152610908908290610d33565b610921836020015160028111156106bc576106bc611572565b60408051808201909152600781527f73656372657473000000000000000000000000000000000000000000000000006020820152610960908290610d33565b6080830151610970908290610d81565b60e08301515115610a1d5760408051808201909152600981527f627974657341726773000000000000000000000000000000000000000000000060208201526109ba908290610d33565b6109c381610d8e565b60005b8360e0015151811015610a1357610a038460e0015182815181106109ec576109ec6115a1565b602002602001015183610d8190919063ffffffff16565b610a0c816115ff565b90506109c6565b50610a1d81610db2565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610a8a959493929190611637565b6020604051808303816000875af1158015610aa9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610acd91906116d7565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603610b83576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103c4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060209050602083511015610c0e575081515b60005b81811015610c7457610c248160086116f0565b848281518110610c3657610c366115a1565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c9290921791610c6d816115ff565b9050610c11565b5050919050565b8051600003610cb6576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83836002811115610cc957610cc9611572565b90816002811115610cdc57610cdc611572565b90525060408401828015610cf257610cf2611572565b90818015610d0257610d02611572565b9052506060909301929092525050565b610d1a6111a4565b8051610d269083610dd0565b5060006020820152919050565b610d408260038351610e4a565b81516102289082610f71565b8151610d599060c2610f99565b506105bb8282604051602001610d7191815260200190565b6040516020818303038152906040525b610d408260028351610e4a565b610d99816004611002565b600181602001818151610dac9190611707565b90525050565b610dbd816007611002565b600181602001818151610dac919061171a565b604080518082019091526060815260006020820152610df060208361172d565b15610e1857610e0060208361172d565b610e0b90602061171a565b610e159083611707565b91505b602080840183905260405180855260008152908184010181811015610e3c57600080fd5b604052508290505b92915050565b60178167ffffffffffffffff1611610e77578251610e719060e0600585901b168317610f99565b50505050565b60ff8167ffffffffffffffff1611610eb9578251610ea0906018611fe0600586901b1617610f99565b508251610e719067ffffffffffffffff83166001611019565b61ffff8167ffffffffffffffff1611610efc578251610ee3906019611fe0600586901b1617610f99565b508251610e719067ffffffffffffffff83166002611019565b63ffffffff8167ffffffffffffffff1611610f41578251610f2890601a611fe0600586901b1617610f99565b508251610e719067ffffffffffffffff83166004611019565b8251610f5890601b611fe0600586901b1617610f99565b508251610e719067ffffffffffffffff83166008611019565b604080518082019091526060815260006020820152610f928383845161109e565b9392505050565b6040805180820190915260608152600060208201528251516000610fbe826001611707565b905084602001518210610fdf57610fdf85610fda8360026116f0565b61118d565b8451602083820101858153508051821115610ff8578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f99565b604080518082019091526060815260006020820152835151600061103d8285611707565b9050856020015181111561105a5761105a86610fda8360026116f0565b6000600161106a86610100611888565b611074919061171a565b90508651828101878319825116178152508051831115611092578281525b50959695505050505050565b60408051808201909152606081526000602082015282518211156110c157600080fd5b83515160006110d08483611707565b905085602001518111156110ed576110ed86610fda8360026116f0565b855180518382016020019160009180851115611107578482525b505050602086015b602086106111475780518252611126602083611707565b9150611133602082611707565b905061114060208761171a565b955061110f565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111998383610dd0565b50610e718382610f71565b60405180604001604052806111cc604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561124f5761124f6111d9565b604052919050565b600067ffffffffffffffff831115611271576112716111d9565b6112a260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f86011601611208565b90508281528383830111156112b657600080fd5b828260208301376000602084830101529392505050565b600082601f8301126112de57600080fd5b610f9283833560208501611257565b60008060006060848603121561130257600080fd5b83359250602084013567ffffffffffffffff8082111561132157600080fd5b61132d878388016112cd565b9350604086013591508082111561134357600080fd5b50611350868287016112cd565b9150509250925092565b60008083601f84011261136c57600080fd5b50813567ffffffffffffffff81111561138457600080fd5b60208301915083602082850101111561139c57600080fd5b9250929050565b803567ffffffffffffffff811681146113bb57600080fd5b919050565b60008060008060008060008060a0898b0312156113dc57600080fd5b883567ffffffffffffffff808211156113f457600080fd5b6114008c838d0161135a565b909a50985060208b013591508082111561141957600080fd5b6114258c838d0161135a565b909850965060408b013591508082111561143e57600080fd5b818b0191508b601f83011261145257600080fd5b81358181111561146157600080fd5b8c60208260051b850101111561147657600080fd5b60208301965080955050505061148e60608a016113a3565b9150608089013590509295985092959890939650565b6000602082840312156114b657600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f9257600080fd5b600067ffffffffffffffff808411156114f5576114f56111d9565b8360051b6020611506818301611208565b86815291850191818101903684111561151e57600080fd5b865b84811015611566578035868111156115385760008081fd5b880136601f82011261154a5760008081fd5b611558368235878401611257565b845250918301918301611520565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611630576116306115d0565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b818110156116755788810183015185820160c001528201611659565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f830116850101925050506116be604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b6000602082840312156116e957600080fd5b5051919050565b8082028115828204841417610e4457610e446115d0565b80820180821115610e4457610e446115d0565b81810381811115610e4457610e446115d0565b600082611763577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b600181815b808511156117c157817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff048211156117a7576117a76115d0565b808516156117b457918102915b93841c939080029061176d565b509250929050565b6000826117d857506001610e44565b816117e557506000610e44565b81600181146117fb576002811461180557611821565b6001915050610e44565b60ff841115611816576118166115d0565b50506001821b610e44565b5060208310610133831016604e8410600b8410161715611844575081810a610e44565b61184e8383611768565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04821115611880576118806115d0565b029392505050565b6000610f9283836117c956fea164736f6c6343000813000a", } var FunctionsClientExampleABI = FunctionsClientExampleMetaData.ABI diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 8e2f772b231..78553a2dafb 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -38,7 +38,7 @@ type FunctionsBillingConfig struct { RequestTimeoutSeconds uint32 DonFee *big.Int MaxSupportedRequestDataVersion uint16 - FulfillmentGasPriceOverEstimationBP *big.Int + FulfillmentGasPriceOverEstimationBP uint32 FallbackNativePerUnitLink *big.Int } @@ -49,35 +49,43 @@ type FunctionsResponseCommitment struct { SubscriptionId uint64 CallbackGasLimit uint32 EstimatedTotalCostJuels *big.Int - TimeoutTimestamp *big.Int + TimeoutTimestamp uint32 RequestId [32]byte DonFee *big.Int GasOverheadBeforeCallback *big.Int GasOverheadAfterCallback *big.Int } -type IFunctionsBillingRequestBilling struct { - SubscriptionId uint64 - Client common.Address - CallbackGasLimit uint32 - ExpectedGasPriceGwei *big.Int - AdminFee *big.Int -} - -type IFunctionsCoordinatorRequest struct { +type FunctionsResponseRequestMeta struct { RequestingContract common.Address - SubscriptionOwner common.Address Data []byte SubscriptionId uint64 DataVersion uint16 Flags [32]byte CallbackGasLimit uint32 AdminFee *big.Int + Consumer IFunctionsSubscriptionsConsumer + Subscription IFunctionsSubscriptionsSubscription +} + +type IFunctionsSubscriptionsConsumer struct { + Allowed bool + InitiatedRequests uint64 + CompletedRequests uint64 +} + +type IFunctionsSubscriptionsSubscription struct { + Balance *big.Int + Owner common.Address + BlockedBalance *big.Int + ProposedOwner common.Address + Consumers []common.Address + Flags [32]byte } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"commitment\",\"type\":\"bytes\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"expectedGasPriceGwei\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsBilling.RequestBilling\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint80\",\"name\":\"\",\"type\":\"uint80\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"internalType\":\"structIFunctionsCoordinator.Request\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"sendRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint256\"},{\"internalType\":\"int256\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"int256\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b5060405162005a4138038062005a41833981016040819052620000349162000455565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600c80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b505050505050620005de565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f562000358565b60008161010001511362000226578061010001516040516321ea67b360e11b81526004016200008891815260200190565b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff16600160f01b026001600160f01b036001600160501b03909216600160a01b02600160a01b600160f01b031963ffffffff948516600160801b0216600160801b600160f01b03199585166c010000000000000000000000000263ffffffff60601b19978616680100000000000000000297909716600160401b600160801b0319998616640100000000026001600160401b0319909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517f65e5bc7ff6133456adf04bcd6ececcf049fc4117102e1ac9064d3b6570398403906200034d9083906200054b565b60405180910390a150565b6200036262000364565b565b6000546001600160a01b03163314620003625760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003d857600080fd5b919050565b60405161012081016001600160401b03811182821017156200040f57634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003d857600080fd5b80516001600160501b0381168114620003d857600080fd5b805161ffff81168114620003d857600080fd5b60008060008385036101608112156200046d57600080fd5b6200047885620003c0565b935061012080601f19830112156200048f57600080fd5b62000499620003dd565b9150620004a96020870162000415565b8252620004b96040870162000415565b6020830152620004cc6060870162000415565b6040830152620004df6080870162000415565b6060830152620004f260a0870162000415565b60808301526200050560c087016200042a565b60a08301526200051860e0870162000442565b60c08301526101008681015160e084015290860151908201529150620005426101408501620003c0565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005aa60a08401826001600160501b03169052565b5060c0830151620005c160c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60805160a05161540c62000635600039600081816106cc01528181610ccc01528181610ef50152818161123f01528181611a2d01528181611cc701528181613249015261397f015260006113fe015261540c6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381f1b938116100ee578063bdd7e88011610097578063d328a91e11610071578063d328a91e1461055b578063e3d0e71214610563578063e4ddcea614610576578063f2fde38b1461058c57600080fd5b8063bdd7e880146103f6578063c3f909d414610416578063d227d2451461054857600080fd5b80638da5cb5b116100c85780638da5cb5b1461039b578063afcb95d7146103c3578063b1dc65a4146103e357600080fd5b806381f1b9381461030357806381ff70481461030b57806385b214cf1461037857600080fd5b8063533989871161015b5780637d480787116101355780637d480787146102c05780637f15e166146102c857806380756031146102db57806381411834146102ee57600080fd5b8063533989871461028f57806366316d8d146102a557806379ba5097146102b857600080fd5b806326ceabac1161018c57806326ceabac146102445780632a905ccc1461025757806345ff86b51461027c57600080fd5b8063083a5466146101b35780630e7ada39146101c8578063181f5a77146101fb575b600080fd5b6101c66101c1366004613c1e565b61059f565b005b6101db6101d6366004613e7a565b6105f4565b60405169ffffffffffffffffffff90911681526020015b60405180910390f35b6102376040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516101f29190613faf565b6101c6610252366004613fc9565b610622565b61025f6106c8565b6040516bffffffffffffffffffffffff90911681526020016101f2565b6101c661028a36600461401b565b61075e565b6102976109a9565b6040516101f2929190614116565b6101c66102b33660046141a6565b610bd0565b6101c6610d89565b6101c6610e86565b6101c66102d6366004613c1e565b610fde565b6101c66102e93660046141df565b61102e565b6102f66110e5565b6040516101f29190614234565b610237611154565b61035560015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff9485168152939092166020840152908201526060016101f2565b61038b610386366004614247565b611225565b60405190151581526020016101f2565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016101f2565b6040805160018152600060208201819052918101919091526060016101f2565b6101c66103f13660046142a5565b611305565b61040961040436600461435c565b6119bc565b6040516101f291906144be565b61053b6040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a08201527e0100000000000000000000000000000000000000000000000000000000000090910461ffff1660c082015260095460e0820152600a5461010082015290565b6040516101f291906144cd565b61025f610556366004614561565b611cc3565b610237611e75565b6101c661057136600461467a565b611ecc565b61057e6128f8565b6040519081526020016101f2565b6101c661059a366004613fc9565b612aed565b6105a7612afe565b60008190036105e2576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f6105ef8284836147e0565b505050565b60085474010000000000000000000000000000000000000000900469ffffffffffffffffffff165b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061066057503373ffffffffffffffffffffffffffffffffffffffff821614155b15610697576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600e602052604081206106c591613b63565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610735573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107599190614906565b905090565b610766612b81565b6000816101000151136107b7578061010001516040517f43d4cf660000000000000000000000000000000000000000000000000000000081526004016107ae91815260200190565b60405180910390fd5b80516008805460208401516040808601516060870151608088015160a089015160c08a015161ffff167e01000000000000000000000000000000000000000000000000000000000000027dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff69ffffffffffffffffffff90921674010000000000000000000000000000000000000000027fffff00000000000000000000ffffffffffffffffffffffffffffffffffffffff63ffffffff94851670010000000000000000000000000000000002167fffff0000000000000000000000000000ffffffffffffffffffffffffffffffff9585166c01000000000000000000000000027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff9786166801000000000000000002979097167fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff998616640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000909b1695909c1694909417989098179690961698909817929092171617929092179390931692909217905560e0820151600955610100820151600a55517f65e5bc7ff6133456adf04bcd6ececcf049fc4117102e1ac9064d3b65703984039061099e9083906144cd565b60405180910390a150565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a1157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109e6575b505050505090506000815167ffffffffffffffff811115610a3457610a34613c60565b604051908082528060200260200182016040528015610a6757816020015b6060815260200190600190039081610a525790505b50905060005b8251811015610bc6576000600e6000858481518110610a8e57610a8e614923565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610adb90614747565b80601f0160208091040260200160405190810160405280929190818152602001828054610b0790614747565b8015610b545780601f10610b2957610100808354040283529160200191610b54565b820191906000526020600020905b815481529060010190602001808311610b3757829003601f168201915b505050505090508051600003610b96576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610ba957610ba9614923565b60200260200101819052505080610bbf90614981565b9050610a6d565b5090939092509050565b610bd8612b89565b806bffffffffffffffffffffffff16600003610c125750336000908152600b60205260409020546bffffffffffffffffffffffff16610c6c565b336000908152600b60205260409020546bffffffffffffffffffffffff80831691161015610c6c576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604081208054839290610c999084906bffffffffffffffffffffffff166149b9565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610cee7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610d6d57600080fd5b505af1158015610d81573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610e0a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107ae565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610e8e612b81565b610e96612b89565b6000610ea06110e5565b905060005b8151811015610fda57336000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610f4157610f41614923565b6020026020010151836040518363ffffffff1660e01b8152600401610f9692919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610fb057600080fd5b505af1158015610fc4573d6000803e3d6000fd5b505050505080610fd390614981565b9050610ea5565b5050565b610fe6612afe565b6000819003611021576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d6105ef8284836147e0565b60005473ffffffffffffffffffffffffffffffffffffffff16331480611079575061105833612d34565b801561107957503373ffffffffffffffffffffffffffffffffffffffff8416145b6110af576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600e602052604090206110df8284836147e0565b50505050565b6060600680548060200260200160405190810160405280929190818152602001828054801561114a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161111f575b5050505050905090565b6060600f805461116390614747565b905060000361119e576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600f80546111ab90614747565b80601f01602080910402602001604051908101604052809291908181526020018280546111d790614747565b801561114a5780601f106111f95761010080835404028352916020019161114a565b820191906000526020600020905b81548152906001019060200180831161120757509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611296576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600760205260409020546112b157506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906112f49084815260200190565b60405180910390a15060015b919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff808216602085015261010090910416928201929092529083146113ec576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d61746368000000000000000000000060448201526064016107ae565b6113fa8b8b8b8b8b8b612e1d565b60007f0000000000000000000000000000000000000000000000000000000000000000156114575760028260200151836040015161143891906149de565b6114429190614a26565b61144d9060016149de565b60ff16905061146d565b60208201516114679060016149de565b60ff1690505b8881146114d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e61747572657300000000000060448201526064016107ae565b88871461153f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e000060448201526064016107ae565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561158257611582614a48565b600281111561159357611593614a48565b90525090506002816020015160028111156115b0576115b0614a48565b1480156115f757506006816000015160ff16815481106115d2576115d2614923565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b61165d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d6974746572000000000000000060448201526064016107ae565b505050505061166a613b9d565b6000808a8a60405161167d929190614a77565b604051908190038120611694918e90602001614a87565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b8981101561199e5760006001848984602081106116fd576116fd614923565b61170a91901a601b6149de565b8e8e8681811061171c5761171c614923565b905060200201358d8d8781811061173557611735614923565b9050602002013560405160008152602001604052604051611772949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611794573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff8082168552929650929450840191610100900416600281111561181457611814614a48565b600281111561182557611825614a48565b905250925060018360200151600281111561184257611842614a48565b146118a9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e000060448201526064016107ae565b8251600090879060ff16601f81106118c3576118c3614923565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611945576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e617475726500000000000000000000000060448201526064016107ae565b8086846000015160ff16601f811061195f5761195f614923565b73ffffffffffffffffffffffffffffffffffffffff909216602092909202015261198a6001866149de565b9450508061199790614981565b90506116de565b5050506119af833383858e8e612ed4565b5050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614611a84576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a916040830183614a9b565b9050600003611acb576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006040518060a00160405280846060016020810190611aeb9190614b00565b67ffffffffffffffff168152602090810190611b0990860186613fc9565b73ffffffffffffffffffffffffffffffffffffffff168152602001611b3460e0860160c08701614b1d565b63ffffffff1681523a6020820152604001611b56610100860160e08701614b3a565b6bffffffffffffffffffffffff1690529050611bc3611b786040850185614a9b565b8080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250611bbd9250505060a0860160808701614b57565b836130a2565b9150611bd26020840184613fc9565b73ffffffffffffffffffffffffffffffffffffffff168260e001517fd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e332866060016020810190611c229190614b00565b611c326040890160208a01613fc9565b611c3f60408a018a614a9b565b611c4f60a08c0160808d01614b57565b60a08c0135611c6460e08e0160c08f01614b1d565b8c604051602001611c7591906144be565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815290829052611cb5999897969594939291614b72565b60405180910390a350919050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611d6357600080fd5b505afa158015611d77573d6000803e3d6000fd5b505050620f42408311159050611db9576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611dc36106c8565b90506000611e4d87878080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250506040805160a08101825267ffffffffffffffff8e16815233602082015263ffffffff8b1691810191909152606081018990526bffffffffffffffffffffffff8716608082015291506105f49050565b69ffffffffffffffffffff169050611e6785858385613628565b925050505b95945050505050565b6060600d8054611e8490614747565b9050600003611ebf576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600d80546111ab90614747565b855185518560ff16601f831115611f3f576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e6572730000000000000000000000000000000060448201526064016107ae565b80600003611fa9576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f736974697665000000000000000000000000000060448201526064016107ae565b818314612037576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e0000000000000000000000000000000000000000000000000000000060648201526084016107ae565b612042816003614c36565b83116120aa576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f2068696768000000000000000060448201526064016107ae565b6120b2612afe565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a08101869052906120f990886136f0565b600554156122ae5760055460009061211390600190614c4d565b905060006005828154811061212a5761212a614923565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff9092169350908490811061216457612164614923565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000908116909155929091168084529220805490911690556005805491925090806121e4576121e4614c60565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061224d5761224d614c60565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055506120f9915050565b60005b81515181101561271557600060046000846000015184815181106122d7576122d7614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561232157612321614a48565b14612388576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e6572206164647265737300000000000000000060448201526064016107ae565b6040805180820190915260ff821681526001602082015282518051600491600091859081106123b9576123b9614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561245a5761245a614a48565b02179055506000915061246a9050565b600460008460200151848151811061248457612484614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff1660028111156124ce576124ce614a48565b14612535576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d697474657220616464726573730000000060448201526064016107ae565b6040805180820190915260ff82168152602081016002815250600460008460200151848151811061256857612568614923565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561260957612609614a48565b02179055505082518051600592508390811061262757612627614923565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106126a3576126a3614923565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061270d81614981565b9150506122b1565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff43811682029290921780855592048116929182916014916127cd91849174010000000000000000000000000000000000000000900416614c8f565b92506101000a81548163ffffffff021916908363ffffffff16021790555061282c4630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613709565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e05986128e3988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614cac565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116838501526c01000000000000000000000000808304821660608501527001000000000000000000000000000000008304909116608084015274010000000000000000000000000000000000000000820469ffffffffffffffffffff1660a0808501919091527e0100000000000000000000000000000000000000000000000000000000000090920461ffff1660c084015260095460e0840152600a54610100840152600c5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa158015612a3f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a639190614d4d565b509350509250508042612a769190614c4d565b836020015163ffffffff16108015612a9857506000836020015163ffffffff16115b15612aa95750506101000151919050565b60008213612ae6576040517f43d4cf66000000000000000000000000000000000000000000000000000000008152600481018390526024016107ae565b5092915050565b612af5612afe565b6106c5816137b4565b60005473ffffffffffffffffffffffffffffffffffffffff163314612b7f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107ae565b565b612b7f612afe565b600c546bffffffffffffffffffffffff16600003612ba357565b6000612bad6110e5565b90508051600003612bea576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600c54600091612c09916bffffffffffffffffffffffff16614da5565b905060005b8251811015612cd55781600b6000858481518110612c2e57612c2e614923565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612c969190614dd0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612cce90614981565b9050612c0e565b508151612ce29082614df5565b600c8054600090612d029084906bffffffffffffffffffffffff166149b9565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612d9a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d6f575b5050505050905060005b8151811015612e13578373ffffffffffffffffffffffffffffffffffffffff16828281518110612dd657612dd6614923565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612e03575060019392505050565b612e0c81614981565b9050612da4565b5060009392505050565b6000612e2a826020614c36565b612e35856020614c36565b612e4188610144614e25565b612e4b9190614e25565b612e559190614e25565b612e60906000614e25565b9050368114612ecb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d61746368000000000000000060448201526064016107ae565b50505050505050565b606080808080612ee686880188614f13565b8451949950929750909550935091501580612f0357508351855114155b80612f1057508251855114155b80612f1d57508151855114155b80612f2a57508051855114155b15612f61576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8551811015613094576000612ff9878381518110612f8457612f84614923565b6020026020010151878481518110612f9e57612f9e614923565b6020026020010151878581518110612fb857612fb8614923565b6020026020010151878681518110612fd257612fd2614923565b6020026020010151878781518110612fec57612fec614923565b60200260200101516138a9565b9050600081600681111561300f5761300f614a48565b148061302c5750600181600681111561302a5761302a614a48565b145b156130835786828151811061304357613043614923565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061308d81614981565b9050612f64565b505050505050505050505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff80821683526401000000008204811660208401526801000000000000000082048116938301939093526c010000000000000000000000008104831660608301527001000000000000000000000000000000008104909216608082015269ffffffffffffffffffff7401000000000000000000000000000000000000000083041660a082015261ffff7e01000000000000000000000000000000000000000000000000000000000000909204821660c0820181905260095460e0830152600a5461010083015290918516111561320f576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061321b86856105f4565b90506000613243856040015186606001518469ffffffffffffffffffff168860800151613628565b905060007f000000000000000000000000000000000000000000000000000000000000000086516040517fa47c769600000000000000000000000000000000000000000000000000000000815267ffffffffffffffff909116600482015290915060009073ffffffffffffffffffffffffffffffffffffffff83169063a47c769690602401600060405180830381865afa1580156132e5573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261332b9190810190615054565b9050826bffffffffffffffffffffffff168160400151826000015161335091906149b9565b6bffffffffffffffffffffffff161015613396576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602087015187516040517f674603d000000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff928316600482015267ffffffffffffffff909116602482015260009184169063674603d090604401606060405180830381865afa15801561341d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134419190615123565b5091505060006134c4308a602001518b600001518560016134629190615175565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808a608001516bffffffffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff1681526020018a6020015173ffffffffffffffffffffffffffffffffffffffff1681526020018a6000015167ffffffffffffffff1681526020018a6040015163ffffffff168152602001866bffffffffffffffffffffffff168152602001886080015163ffffffff16426135749190614e25565b64ffffffffff1681526020018281526020018769ffffffffffffffffffff168152602001886040015163ffffffff1664ffffffffff168152602001886060015163ffffffff1664ffffffffff168152509750876040516020016135d791906144be565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060009384526007909252909120555050505050509392505050565b600854600090819086906136609063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614c8f565b61366a9190614c8f565b63ffffffff1690506000612710600860010154876136889190614c36565b6136929190615196565b61369c9087614e25565b905060006136a982613b3d565b905060006136b78483614c36565b905060006136d66bffffffffffffffffffffffff808916908a16614e25565b90506136e28183614e25565b9a9950505050505050505050565b60006136fa6110e5565b511115610fda57610fda612b89565b6000808a8a8a8a8a8a8a8a8a60405160200161372d999897969594939291906151aa565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613833576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107ae565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906138c0919061525f565b9050806040516020016138d391906144be565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600790935291205414613925576006915050611e6c565b600087815260076020526040902054613942576002915050611e6c565b600061394d3a613b3d565b905060008261014001518361012001516139679190615332565b6139789064ffffffffff1683614c36565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a1d4c8288b8b8789610100015169ffffffffffffffffffff16886139d99190614dd0565b338b6040518763ffffffff1660e01b81526004016139fc96959493929190615350565b60408051808303816000875af1158015613a1a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3e91906153cc565b90925090506000826006811115613a5757613a57614a48565b1480613a7457506001826006811115613a7257613a72614a48565b145b15613b2f5760008b815260076020526040812055613a928184614dd0565b336000908152600b6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100870151600c805469ffffffffffffffffffff90921693909291613b0091859116614dd0565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613b476128f8565b613b5983670de0b6b3a7640000614c36565b61061c9190615196565b508054613b6f90614747565b6000825580601f10613b7f575050565b601f0160209004906000526020600020908101906106c59190613bbc565b604051806103e00160405280601f906020820280368337509192915050565b5b80821115613bd15760008155600101613bbd565b5090565b60008083601f840112613be757600080fd5b50813567ffffffffffffffff811115613bff57600080fd5b602083019150836020828501011115613c1757600080fd5b9250929050565b60008060208385031215613c3157600080fd5b823567ffffffffffffffff811115613c4857600080fd5b613c5485828601613bd5565b90969095509350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715613cb257613cb2613c60565b60405290565b604051610120810167ffffffffffffffff81118282101715613cb257613cb2613c60565b60405160c0810167ffffffffffffffff81118282101715613cb257613cb2613c60565b604051610160810167ffffffffffffffff81118282101715613cb257613cb2613c60565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613d6a57613d6a613c60565b604052919050565b600082601f830112613d8357600080fd5b813567ffffffffffffffff811115613d9d57613d9d613c60565b613dce60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613d23565b818152846020838601011115613de357600080fd5b816020850160208301376000918101602001919091529392505050565b67ffffffffffffffff811681146106c557600080fd5b803561130081613e00565b73ffffffffffffffffffffffffffffffffffffffff811681146106c557600080fd5b63ffffffff811681146106c557600080fd5b803561130081613e43565b6bffffffffffffffffffffffff811681146106c557600080fd5b60008082840360c0811215613e8e57600080fd5b833567ffffffffffffffff811115613ea557600080fd5b613eb186828701613d72565b93505060a07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe082011215613ee457600080fd5b50613eed613c8f565b6020840135613efb81613e00565b81526040840135613f0b81613e21565b60208201526060840135613f1e81613e43565b60408201526080840135606082015260a0840135613f3b81613e60565b6080820152919491935090915050565b6000815180845260005b81811015613f7157602081850181015186830182015201613f55565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613fc26020830184613f4b565b9392505050565b600060208284031215613fdb57600080fd5b8135613fc281613e21565b69ffffffffffffffffffff811681146106c557600080fd5b803561130081613fe6565b803561ffff8116811461130057600080fd5b6000610120828403121561402e57600080fd5b614036613cb8565b61403f83613e55565b815261404d60208401613e55565b602082015261405e60408401613e55565b604082015261406f60608401613e55565b606082015261408060808401613e55565b608082015261409160a08401613ffe565b60a08201526140a260c08401614009565b60c082015260e08381013590820152610100928301359281019290925250919050565b600081518084526020808501945080840160005b8381101561410b57815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016140d9565b509495945050505050565b60408152600061412960408301856140c5565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015614197577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552614185838351613f4b565b9486019492509085019060010161414b565b50909998505050505050505050565b600080604083850312156141b957600080fd5b82356141c481613e21565b915060208301356141d481613e60565b809150509250929050565b6000806000604084860312156141f457600080fd5b83356141ff81613e21565b9250602084013567ffffffffffffffff81111561421b57600080fd5b61422786828701613bd5565b9497909650939450505050565b602081526000613fc260208301846140c5565b60006020828403121561425957600080fd5b5035919050565b60008083601f84011261427257600080fd5b50813567ffffffffffffffff81111561428a57600080fd5b6020830191508360208260051b8501011115613c1757600080fd5b60008060008060008060008060e0898b0312156142c157600080fd5b606089018a8111156142d257600080fd5b8998503567ffffffffffffffff808211156142ec57600080fd5b6142f88c838d01613bd5565b909950975060808b013591508082111561431157600080fd5b61431d8c838d01614260565b909750955060a08b013591508082111561433657600080fd5b506143438b828c01614260565b999c989b50969995989497949560c00135949350505050565b60006020828403121561436e57600080fd5b813567ffffffffffffffff81111561438557600080fd5b82016101008185031215613fc257600080fd5b80516bffffffffffffffffffffffff16825260208101516143d1602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408101516143f9604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151614415606084018267ffffffffffffffff169052565b50608081015161442d608084018263ffffffff169052565b5060a081015161444d60a08401826bffffffffffffffffffffffff169052565b5060c081015161446660c084018264ffffffffff169052565b5060e081015160e08301526101008082015161448f8285018269ffffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff8116848301526110df565b610160810161061c8284614398565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161452e60a084018269ffffffffffffffffffff169052565b5060c083015161454460c084018261ffff169052565b5060e083015160e083015261010080840151818401525092915050565b60008060008060006080868803121561457957600080fd5b853561458481613e00565b9450602086013567ffffffffffffffff8111156145a057600080fd5b6145ac88828901613bd5565b90955093505060408601356145c081613e43565b949793965091946060013592915050565b600067ffffffffffffffff8211156145eb576145eb613c60565b5060051b60200190565b600082601f83011261460657600080fd5b8135602061461b614616836145d1565b613d23565b82815260059290921b8401810191818101908684111561463a57600080fd5b8286015b8481101561465e57803561465181613e21565b835291830191830161463e565b509695505050505050565b803560ff8116811461130057600080fd5b60008060008060008060c0878903121561469357600080fd5b863567ffffffffffffffff808211156146ab57600080fd5b6146b78a838b016145f5565b975060208901359150808211156146cd57600080fd5b6146d98a838b016145f5565b96506146e760408a01614669565b955060608901359150808211156146fd57600080fd5b6147098a838b01613d72565b945061471760808a01613e16565b935060a089013591508082111561472d57600080fd5b5061473a89828a01613d72565b9150509295509295509295565b600181811c9082168061475b57607f821691505b602082108103614794577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f8211156105ef57600081815260208120601f850160051c810160208610156147c15750805b601f850160051c820191505b81811015610d81578281556001016147cd565b67ffffffffffffffff8311156147f8576147f8613c60565b61480c836148068354614747565b8361479a565b6000601f84116001811461485e57600085156148285750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556148f4565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156148ad578685013582556020948501946001909201910161488d565b50868210156148e8577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b805161130081613e60565b60006020828403121561491857600080fd5b8151613fc281613e60565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036149b2576149b2614952565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115612ae657612ae6614952565b60ff818116838216019081111561061c5761061c614952565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614a3957614a396149f7565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112614ad057600080fd5b83018035915067ffffffffffffffff821115614aeb57600080fd5b602001915036819003821315613c1757600080fd5b600060208284031215614b1257600080fd5b8135613fc281613e00565b600060208284031215614b2f57600080fd5b8135613fc281613e43565b600060208284031215614b4c57600080fd5b8135613fc281613e60565b600060208284031215614b6957600080fd5b613fc282614009565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a16602083015288166040820152610100606082018190528101869052600061012087898285013760008189850101527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f890116830161ffff881660808501528660a0850152614c0f60c085018763ffffffff169052565b818482030160e0850152614c2582820186613f4b565b9d9c50505050505050505050505050565b808202811582820484141761061c5761061c614952565b8181038181111561061c5761061c614952565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff818116838216019080821115612ae657612ae6614952565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614cdc8184018a6140c5565b90508281036080840152614cf081896140c5565b905060ff871660a084015282810360c0840152614d0d8187613f4b565b905067ffffffffffffffff851660e0840152828103610100840152614d328185613f4b565b9c9b505050505050505050505050565b805161130081613fe6565b600080600080600060a08688031215614d6557600080fd5b8551614d7081613fe6565b809550506020860151935060408601519250606086015191506080860151614d9781613fe6565b809150509295509295909350565b60006bffffffffffffffffffffffff80841680614dc457614dc46149f7565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115612ae657612ae6614952565b6bffffffffffffffffffffffff818116838216028082169190828114614e1d57614e1d614952565b505092915050565b8082018082111561061c5761061c614952565b600082601f830112614e4957600080fd5b81356020614e59614616836145d1565b82815260059290921b84018101918181019086841115614e7857600080fd5b8286015b8481101561465e5780358352918301918301614e7c565b600082601f830112614ea457600080fd5b81356020614eb4614616836145d1565b82815260059290921b84018101918181019086841115614ed357600080fd5b8286015b8481101561465e57803567ffffffffffffffff811115614ef75760008081fd5b614f058986838b0101613d72565b845250918301918301614ed7565b600080600080600060a08688031215614f2b57600080fd5b853567ffffffffffffffff80821115614f4357600080fd5b614f4f89838a01614e38565b96506020880135915080821115614f6557600080fd5b614f7189838a01614e93565b95506040880135915080821115614f8757600080fd5b614f9389838a01614e93565b94506060880135915080821115614fa957600080fd5b614fb589838a01614e93565b93506080880135915080821115614fcb57600080fd5b50614fd888828901614e93565b9150509295509295909350565b805161130081613e21565b600082601f83011261500157600080fd5b81516020615011614616836145d1565b82815260059290921b8401810191818101908684111561503057600080fd5b8286015b8481101561465e57805161504781613e21565b8352918301918301615034565b60006020828403121561506657600080fd5b815167ffffffffffffffff8082111561507e57600080fd5b9083019060c0828603121561509257600080fd5b61509a613cdc565b82516150a581613e60565b815260208301516150b581613e21565b602082015260408301516150c881613e60565b60408201526150d960608401614fe5565b60608201526080830151828111156150f057600080fd5b6150fc87828601614ff0565b60808301525060a083015160a082015280935050505092915050565b805161130081613e00565b60008060006060848603121561513857600080fd5b8351801515811461514857600080fd5b602085015190935061515981613e00565b604085015190925061516a81613e00565b809150509250925092565b67ffffffffffffffff818116838216019080821115612ae657612ae6614952565b6000826151a5576151a56149f7565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b1660408501528160608501526151f18285018b6140c5565b91508382036080850152615205828a6140c5565b915060ff881660a085015283820360c08501526152228288613f4b565b90861660e08501528381036101008501529050614d328185613f4b565b805161130081613e43565b805164ffffffffff8116811461130057600080fd5b6000610160828403121561527257600080fd5b61527a613cff565b615283836148fb565b815261529160208401614fe5565b60208201526152a260408401614fe5565b60408201526152b360608401615118565b60608201526152c46080840161523f565b60808201526152d560a084016148fb565b60a08201526152e660c0840161524a565b60c082015260e083015160e0820152610100615303818501614d42565b9082015261012061531584820161524a565b9082015261014061532784820161524a565b908201529392505050565b64ffffffffff818116838216019080821115612ae657612ae6614952565b60006102008083526153648184018a613f4b565b905082810360208401526153788189613f4b565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff8616608085015291506153c1905060a0830184614398565b979650505050505050565b600080604083850312156153df57600080fd5b8251600781106153ee57600080fd5b60208401519092506141d481613e6056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"indexed\":false,\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"consumer\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"subscription\",\"type\":\"tuple\"}],\"internalType\":\"structFunctionsResponse.RequestMeta\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"startRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b50604051620057dd380380620057dd83398101604081905262000034916200044f565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600b80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b50505050505062000600565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f56200033a565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a166001600160401b031990981697909717640100000000968a16870217600160401b600160801b03191668010000000000000000948a169490940263ffffffff60601b1916939093176c010000000000000000000000009289169290920291909117600160801b600160e81b031916600160801b91881691909102600160a01b600160e81b03191617600160a01b6001600160481b03909216919091021761ffff60e81b1916600160e81b61ffff909416939093029290921790925560e084015161010085015193166001600160e01b0390931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c906200032f90839062000558565b60405180910390a150565b6200034462000346565b565b6000546001600160a01b03163314620003445760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003ba57600080fd5b919050565b60405161012081016001600160401b0381118282101715620003f157634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003ba57600080fd5b80516001600160481b0381168114620003ba57600080fd5b805161ffff81168114620003ba57600080fd5b80516001600160e01b0381168114620003ba57600080fd5b60008060008385036101608112156200046757600080fd5b6200047285620003a2565b935061012080601f19830112156200048957600080fd5b62000493620003bf565b9150620004a360208701620003f7565b8252620004b360408701620003f7565b6020830152620004c660608701620003f7565b6040830152620004d960808701620003f7565b6060830152620004ec60a08701620003f7565b6080830152620004ff60c087016200040c565b60a08301526200051260e0870162000424565b60c083015261010062000527818801620003f7565b60e08401526200053982880162000437565b908301525091506200054f6101408501620003a2565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005b760a08401826001600160481b03169052565b5060c0830151620005ce60c084018261ffff169052565b5060e0830151620005e760e084018263ffffffff169052565b50610100928301516001600160e01b0316919092015290565b60805160a05161518d620006506000396000818161090901528181610c3301528181610e6b01528181611099015281816113e301528181611b6301526136a2015260006115a1015261518d6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381411834116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146105a3578063e3d0e712146105ab578063e4ddcea6146105be578063f2fde38b146105d457600080fd5b8063b1dc65a41461040e578063c3f909d414610421578063d227d2451461057357600080fd5b806385b214cf116100c857806385b214cf146103a35780638da5cb5b146103c6578063afcb95d7146103ee57600080fd5b8063814118341461031957806381f1b9381461032e57806381ff70481461033657600080fd5b806359b5b7ac1161015b57806379ba50971161013557806379ba5097146102e35780637d480787146102eb5780637f15e166146102f3578063807560311461030657600080fd5b806359b5b7ac1461027857806362fdb991146102b057806366316d8d146102d057600080fd5b806326ceabac1161018c57806326ceabac1461022d5780632a905ccc14610240578063533989871461026257600080fd5b8063083a5466146101b3578063181f5a77146101c85780631bdf7f1b1461021a575b600080fd5b6101c66101c1366004613945565b6105e7565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b60405161021191906139eb565b60405180910390f35b6101c6610228366004613b4e565b61063c565b6101c661023b366004613c31565b61085f565b610248610905565b60405168ffffffffffffffffff9091168152602001610211565b61026a61099b565b604051610211929190613c9f565b610248610286366004613dbd565b5060085474010000000000000000000000000000000000000000900468ffffffffffffffffff1690565b6102c36102be366004613dfa565b610bc2565b6040516102119190613f57565b6101c66102de366004613f80565b610d6f565b6101c6610f28565b6101c661102a565b6101c6610301366004613945565b611182565b6101c6610314366004613fb9565b6111d2565b610321611289565b604051610211919061400e565b6102046112f8565b61038060015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b6103b66103b1366004614021565b6113c9565b6040519015158152602001610211565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b604080516001815260006020820181905291810191909152606001610211565b6101c661041c36600461407f565b6114a8565b6105666040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff1660c083015260095490811660e0830152919091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010082015290565b6040516102119190614136565b610586610581366004614219565b611b5f565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611cbe565b6101c66105b9366004614332565b611d15565b6105c6612741565b604051908152602001610211565b6101c66105e2366004613c31565b612972565b6105ef612983565b600081900361062a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e610637828483614498565b505050565b610644612a06565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a167fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000090981697909717640100000000968a168702177fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff1668010000000000000000948a16949094027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff16939093176c0100000000000000000000000092891692909202919091177fffffff00000000000000000000000000ffffffffffffffffffffffffffffffff16700100000000000000000000000000000000918816919091027fffffff000000000000000000ffffffffffffffffffffffffffffffffffffffff16177401000000000000000000000000000000000000000068ffffffffffffffffff90921691909102177fff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167d01000000000000000000000000000000000000000000000000000000000061ffff909416939093029290921790925560e084015161010085015193167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c90610854908390614136565b60405180910390a150565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061089d57503373ffffffffffffffffffffffffffffffffffffffff821614155b156108d4576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d602052604081206109029161388a565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610972573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061099691906145be565b905090565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a0357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109d8575b505050505090506000815167ffffffffffffffff811115610a2657610a26613a05565b604051908082528060200260200182016040528015610a5957816020015b6060815260200190600190039081610a445790505b50905060005b8251811015610bb8576000600d6000858481518110610a8057610a806145db565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610acd906143ff565b80601f0160208091040260200160405190810160405280929190818152602001828054610af9906143ff565b8015610b465780601f10610b1b57610100808354040283529160200191610b46565b820191906000526020600020905b815481529060010190602001808311610b2957829003601f168201915b505050505090508051600003610b88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610b9b57610b9b6145db565b60200260200101819052505080610bb190614639565b9050610a5f565b5090939092509050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610c8a576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610c9b610c96836147ad565b612a0e565b9050610caa6020830183613c31565b73ffffffffffffffffffffffffffffffffffffffff168160e001517f0d37aa165b7e8c3b3c70cce43049e46de14d9ea8eabe99c920ba4ab3f9afd99e32856040016020810190610cfa919061488e565b610d086101408801886148ab565b610d19906040810190602001613c31565b610d2660208901896148e9565b610d3660808b0160608c0161494e565b60808b0135610d4b60c08d0160a08e01614969565b8b604051610d6199989796959493929190614986565b60405180910390a35b919050565b610d77612e37565b806bffffffffffffffffffffffff16600003610db15750336000908152600a60205260409020546bffffffffffffffffffffffff16610e0b565b336000908152600a60205260409020546bffffffffffffffffffffffff80831691161015610e0b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600a602052604081208054839290610e389084906bffffffffffffffffffffffff16614a2e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610e8d7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610f0c57600080fd5b505af1158015610f20573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610fae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611032612a06565b61103a612e37565b6000611044611289565b905060005b815181101561117e57336000908152600a6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d8484815181106110e5576110e56145db565b6020026020010151836040518363ffffffff1660e01b815260040161113a92919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b15801561115457600080fd5b505af1158015611168573d6000803e3d6000fd5b50505050508061117790614639565b9050611049565b5050565b61118a612983565b60008190036111c5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c610637828483614498565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061121d57506111fc33612fe2565b801561121d57503373ffffffffffffffffffffffffffffffffffffffff8416145b611253576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d60205260409020611283828483614498565b50505050565b606060068054806020026020016040519081016040528092919081815260200182805480156112ee57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116112c3575b5050505050905090565b6060600e8054611307906143ff565b9050600003611342576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e805461134f906143ff565b80601f016020809104026020016040519081016040528092919081815260200182805461137b906143ff565b80156112ee5780601f1061139d576101008083540402835291602001916112ee565b820191906000526020600020905b8154815290600101906020018083116113ab57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461143a576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526007602052604090205461145557506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906114989084815260200190565b60405180910390a1506001919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461158f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610fa5565b61159d8b8b8b8b8b8b6130cb565b60007f0000000000000000000000000000000000000000000000000000000000000000156115fa576002826020015183604001516115db9190614a53565b6115e59190614a9b565b6115f0906001614a53565b60ff169050611610565b602082015161160a906001614a53565b60ff1690505b888114611679576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610fa5565b8887146116e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610fa5565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561172557611725614abd565b600281111561173657611736614abd565b905250905060028160200151600281111561175357611753614abd565b14801561179a57506006816000015160ff1681548110611775576117756145db565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611800576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610fa5565b505050505061180d6138c4565b6000808a8a604051611820929190614aec565b604051908190038120611837918e90602001614afc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b415760006001848984602081106118a0576118a06145db565b6118ad91901a601b614a53565b8e8e868181106118bf576118bf6145db565b905060200201358d8d878181106118d8576118d86145db565b9050602002013560405160008152602001604052604051611915949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611937573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119b7576119b7614abd565b60028111156119c8576119c8614abd565b90525092506001836020015160028111156119e5576119e5614abd565b14611a4c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610fa5565b8251600090879060ff16601f8110611a6657611a666145db565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611ae8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610fa5565b8086846000015160ff16601f8110611b0257611b026145db565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b2d600186614a53565b94505080611b3a90614639565b9050611881565b505050611b52833383858e8e613182565b5050505050505050505050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bff57600080fd5b505afa158015611c13573d6000803e3d6000fd5b505050620f42408311159050611c55576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c5f610905565b90506000611ca287878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061028692505050565b9050611cb085858385613350565b925050505b95945050505050565b6060600c8054611ccd906143ff565b9050600003611d08576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c805461134f906143ff565b855185518560ff16601f831115611d88576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610fa5565b80600003611df2576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610fa5565b818314611e80576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610fa5565b611e8b816003614b10565b8311611ef3576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610fa5565b611efb612983565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f429088613413565b600554156120f757600554600090611f5c90600190614b27565b9050600060058281548110611f7357611f736145db565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fad57611fad6145db565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061202d5761202d614b3a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061209657612096614b3a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f42915050565b60005b81515181101561255e5760006004600084600001518481518110612120576121206145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561216a5761216a614abd565b146121d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610fa5565b6040805180820190915260ff82168152600160208201528251805160049160009185908110612202576122026145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122a3576122a3614abd565b0217905550600091506122b39050565b60046000846020015184815181106122cd576122cd6145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561231757612317614abd565b1461237e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610fa5565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123b1576123b16145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561245257612452614abd565b021790555050825180516005925083908110612470576124706145db565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124ec576124ec6145db565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061255681614639565b9150506120fa565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161261691849174010000000000000000000000000000000000000000900416614b69565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126754630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a0015161342c565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861272c988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614b86565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216848601526c010000000000000000000000008084048316606086015270010000000000000000000000000000000084048316608086015274010000000000000000000000000000000000000000840468ffffffffffffffffff1660a0808701919091527d01000000000000000000000000000000000000000000000000000000000090940461ffff1660c086015260095492831660e086015291047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16610100840152600b5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa1580156128a6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128ca9190614c36565b5093505092505080426128dd9190614b27565b836020015163ffffffff161080156128ff57506000836020015163ffffffff16115b1561292e57505061010001517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16919050565b6000821361296b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610fa5565b5092915050565b61297a612983565b610902816134d7565b60005473ffffffffffffffffffffffffffffffffffffffff163314612a04576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610fa5565b565b612a04612983565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c010000000000000000000000008204811660608085019190915270010000000000000000000000000000000083048216608085015274010000000000000000000000000000000000000000830468ffffffffffffffffff1660a08501527d01000000000000000000000000000000000000000000000000000000000090920461ffff90811660c0850181905260095492831660e0860152949091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010084015290850151919291161115612ba4576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60085460009074010000000000000000000000000000000000000000900468ffffffffffffffffff1690506000612be58560a001513a848860c00151613350565b610100860151604081015190519192506bffffffffffffffffffffffff831691612c0f9190614a2e565b6bffffffffffffffffffffffff161015612c55576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612cdc30876000015188604001518960e00151602001516001612c7a9190614c86565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808760c0015168ffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001876000015173ffffffffffffffffffffffffffffffffffffffff168152602001876040015167ffffffffffffffff1681526020018760a0015163ffffffff168152602001836bffffffffffffffffffffffff168152602001856080015163ffffffff1642612d899190614ca7565b63ffffffff1681526020018281526020018468ffffffffffffffffff168152602001856040015163ffffffff1664ffffffffff168152602001856060015163ffffffff1664ffffffffff16815250945084604051602001612dea9190613f57565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260079092529091205550919392505050565b600b546bffffffffffffffffffffffff16600003612e5157565b6000612e5b611289565b90508051600003612e98576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600b54600091612eb7916bffffffffffffffffffffffff16614cba565b905060005b8251811015612f835781600a6000858481518110612edc57612edc6145db565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612f449190614ce5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612f7c90614639565b9050612ebc565b508151612f909082614d0a565b600b8054600090612fb09084906bffffffffffffffffffffffff16614a2e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b600080600680548060200260200160405190810160405280929190818152602001828054801561304857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161301d575b5050505050905060005b81518110156130c1578373ffffffffffffffffffffffffffffffffffffffff16828281518110613084576130846145db565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036130b1575060019392505050565b6130ba81614639565b9050613052565b5060009392505050565b60006130d8826020614b10565b6130e3856020614b10565b6130ef88610144614ca7565b6130f99190614ca7565b6131039190614ca7565b61310e906000614ca7565b9050368114613179576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610fa5565b50505050505050565b60608080808061319486880188614e0d565b84519499509297509095509350915015806131b157508351855114155b806131be57508251855114155b806131cb57508151855114155b806131d857508051855114155b1561320f576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b85518110156133425760006132a7878381518110613232576132326145db565b602002602001015187848151811061324c5761324c6145db565b6020026020010151878581518110613266576132666145db565b6020026020010151878681518110613280576132806145db565b602002602001015187878151811061329a5761329a6145db565b60200260200101516135cc565b905060008160068111156132bd576132bd614abd565b14806132da575060018160068111156132d8576132d8614abd565b145b15613331578682815181106132f1576132f16145db565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061333b81614639565b9050613212565b505050505050505050505050565b600854600090819086906133889063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614b69565b6133929190614b69565b60095463ffffffff9182169250600091612710916133b1911688614b10565b6133bb9190614edf565b6133c59087614ca7565b905060006133d28261385e565b905060006133e08483614b10565b905060006133ee8789614ef3565b68ffffffffffffffffff1690506134058183614ca7565b9a9950505050505050505050565b600061341d611289565b51111561117e5761117e612e37565b6000808a8a8a8a8a8a8a8a8a60405160200161345099989796959493929190614f15565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613556576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610fa5565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906135e39190614feb565b9050806040516020016135f69190613f57565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600790935291205414613648576006915050611cb5565b600087815260076020526040902054613665576002915050611cb5565b60006136703a61385e565b9050600082610140015183610120015161368a91906150b3565b61369b9064ffffffffff1683614b10565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16630fb258538b8b8789610100015168ffffffffffffffffff16886136fb9190614ce5565b338b6040518763ffffffff1660e01b815260040161371e969594939291906150d1565b60408051808303816000875af115801561373c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613760919061514d565b9092509050600082600681111561377957613779614abd565b14806137965750600182600681111561379457613794614abd565b145b156138505760008b8152600760205260408120556137b48184614ce5565b336000908152600a6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100870151600b805468ffffffffffffffffff9092169390929161382191859116614ce5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613868612741565b61387a83670de0b6b3a7640000614b10565b6138849190614edf565b92915050565b508054613896906143ff565b6000825580601f106138a6575050565b601f01602090049060005260206000209081019061090291906138e3565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156138f857600081556001016138e4565b5090565b60008083601f84011261390e57600080fd5b50813567ffffffffffffffff81111561392657600080fd5b60208301915083602082850101111561393e57600080fd5b9250929050565b6000806020838503121561395857600080fd5b823567ffffffffffffffff81111561396f57600080fd5b61397b858286016138fc565b90969095509350505050565b6000815180845260005b818110156139ad57602081850181015186830182015201613991565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006139fe6020830184613987565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610120810167ffffffffffffffff81118282101715613a5857613a58613a05565b60405290565b604051610160810167ffffffffffffffff81118282101715613a5857613a58613a05565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613ac957613ac9613a05565b604052919050565b63ffffffff8116811461090257600080fd5b8035610d6a81613ad1565b68ffffffffffffffffff8116811461090257600080fd5b8035610d6a81613aee565b803561ffff81168114610d6a57600080fd5b80357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff81168114610d6a57600080fd5b60006101208284031215613b6157600080fd5b613b69613a34565b613b7283613ae3565b8152613b8060208401613ae3565b6020820152613b9160408401613ae3565b6040820152613ba260608401613ae3565b6060820152613bb360808401613ae3565b6080820152613bc460a08401613b05565b60a0820152613bd560c08401613b10565b60c0820152613be660e08401613ae3565b60e0820152610100613bf9818501613b22565b908201529392505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461090257600080fd5b8035610d6a81613c04565b600060208284031215613c4357600080fd5b81356139fe81613c04565b600081518084526020808501945080840160005b83811015613c9457815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613c62565b509495945050505050565b604081526000613cb26040830185613c4e565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613d20577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613d0e838351613987565b94860194925090850190600101613cd4565b50909998505050505050505050565b600082601f830112613d4057600080fd5b813567ffffffffffffffff811115613d5a57613d5a613a05565b613d8b60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613a82565b818152846020838601011115613da057600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613dcf57600080fd5b813567ffffffffffffffff811115613de657600080fd5b613df284828501613d2f565b949350505050565b600060208284031215613e0c57600080fd5b813567ffffffffffffffff811115613e2357600080fd5b820161016081850312156139fe57600080fd5b805168ffffffffffffffffff1682526020810151613e6c602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151613e94604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151613eb0606084018267ffffffffffffffff169052565b506080810151613ec8608084018263ffffffff169052565b5060a0810151613ee860a08401826bffffffffffffffffffffffff169052565b5060c0810151613f0060c084018263ffffffff169052565b5060e081015160e083015261010080820151613f288285018268ffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152611283565b61016081016138848284613e36565b6bffffffffffffffffffffffff8116811461090257600080fd5b60008060408385031215613f9357600080fd5b8235613f9e81613c04565b91506020830135613fae81613f66565b809150509250929050565b600080600060408486031215613fce57600080fd5b8335613fd981613c04565b9250602084013567ffffffffffffffff811115613ff557600080fd5b614001868287016138fc565b9497909650939450505050565b6020815260006139fe6020830184613c4e565b60006020828403121561403357600080fd5b5035919050565b60008083601f84011261404c57600080fd5b50813567ffffffffffffffff81111561406457600080fd5b6020830191508360208260051b850101111561393e57600080fd5b60008060008060008060008060e0898b03121561409b57600080fd5b606089018a8111156140ac57600080fd5b8998503567ffffffffffffffff808211156140c657600080fd5b6140d28c838d016138fc565b909950975060808b01359150808211156140eb57600080fd5b6140f78c838d0161403a565b909750955060a08b013591508082111561411057600080fd5b5061411d8b828c0161403a565b999c989b50969995989497949560c00135949350505050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161419660a084018268ffffffffffffffffff169052565b5060c08301516141ac60c084018261ffff169052565b5060e08301516141c460e084018263ffffffff169052565b50610100838101517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8116848301525b505092915050565b67ffffffffffffffff8116811461090257600080fd5b8035610d6a816141f8565b60008060008060006080868803121561423157600080fd5b853561423c816141f8565b9450602086013567ffffffffffffffff81111561425857600080fd5b614264888289016138fc565b909550935050604086013561427881613ad1565b949793965091946060013592915050565b600067ffffffffffffffff8211156142a3576142a3613a05565b5060051b60200190565b600082601f8301126142be57600080fd5b813560206142d36142ce83614289565b613a82565b82815260059290921b840181019181810190868411156142f257600080fd5b8286015b8481101561431657803561430981613c04565b83529183019183016142f6565b509695505050505050565b803560ff81168114610d6a57600080fd5b60008060008060008060c0878903121561434b57600080fd5b863567ffffffffffffffff8082111561436357600080fd5b61436f8a838b016142ad565b9750602089013591508082111561438557600080fd5b6143918a838b016142ad565b965061439f60408a01614321565b955060608901359150808211156143b557600080fd5b6143c18a838b01613d2f565b94506143cf60808a0161420e565b935060a08901359150808211156143e557600080fd5b506143f289828a01613d2f565b9150509295509295509295565b600181811c9082168061441357607f821691505b60208210810361444c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561063757600081815260208120601f850160051c810160208610156144795750805b601f850160051c820191505b81811015610f2057828155600101614485565b67ffffffffffffffff8311156144b0576144b0613a05565b6144c4836144be83546143ff565b83614452565b6000601f84116001811461451657600085156144e05750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556145ac565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156145655786850135825560209485019460019092019101614545565b50868210156145a0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b8051610d6a81613aee565b6000602082840312156145d057600080fd5b81516139fe81613aee565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361466a5761466a61460a565b5060010190565b60006060828403121561468357600080fd5b6040516060810181811067ffffffffffffffff821117156146a6576146a6613a05565b604052905080823580151581146146bc57600080fd5b815260208301356146cc816141f8565b602082015260408301356146df816141f8565b6040919091015292915050565b600060c082840312156146fe57600080fd5b60405160c0810167ffffffffffffffff828210818311171561472257614722613a05565b816040528293508435915061473682613f66565b90825260208401359061474882613c04565b8160208401526040850135915061475e82613f66565b81604084015261477060608601613c26565b6060840152608085013591508082111561478957600080fd5b50614796858286016142ad565b60808301525060a083013560a08201525092915050565b600061016082360312156147c057600080fd5b6147c8613a34565b6147d183613c26565b8152602083013567ffffffffffffffff808211156147ee57600080fd5b6147fa36838701613d2f565b602084015261480b6040860161420e565b604084015261481c60608601613b10565b60608401526080850135608084015261483760a08601613ae3565b60a084015261484860c08601613b05565b60c084015261485a3660e08701614671565b60e084015261014085013591508082111561487457600080fd5b50614881368286016146ec565b6101008301525092915050565b6000602082840312156148a057600080fd5b81356139fe816141f8565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff418336030181126148df57600080fd5b9190910192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261491e57600080fd5b83018035915067ffffffffffffffff82111561493957600080fd5b60200191503681900382131561393e57600080fd5b60006020828403121561496057600080fd5b6139fe82613b10565b60006020828403121561497b57600080fd5b81356139fe81613ad1565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a166020830152881660408201526102406060820181905281018690526000610260878982850137600083890182015261ffff8716608084015260a0830186905263ffffffff851660c0840152601f88017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016830101905061340560e0830184613e36565b6bffffffffffffffffffffffff82811682821603908082111561296b5761296b61460a565b60ff81811683821601908111156138845761388461460a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614aae57614aae614a6c565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b80820281158282048414176138845761388461460a565b818103818111156138845761388461460a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561296b5761296b61460a565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614bb68184018a613c4e565b90508281036080840152614bca8189613c4e565b905060ff871660a084015282810360c0840152614be78187613987565b905067ffffffffffffffff851660e0840152828103610100840152614c0c8185613987565b9c9b505050505050505050505050565b805169ffffffffffffffffffff81168114610d6a57600080fd5b600080600080600060a08688031215614c4e57600080fd5b614c5786614c1c565b9450602086015193506040860151925060608601519150614c7a60808701614c1c565b90509295509295909350565b67ffffffffffffffff81811683821601908082111561296b5761296b61460a565b808201808211156138845761388461460a565b60006bffffffffffffffffffffffff80841680614cd957614cd9614a6c565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561296b5761296b61460a565b6bffffffffffffffffffffffff8181168382160280821691908281146141f0576141f061460a565b600082601f830112614d4357600080fd5b81356020614d536142ce83614289565b82815260059290921b84018101918181019086841115614d7257600080fd5b8286015b848110156143165780358352918301918301614d76565b600082601f830112614d9e57600080fd5b81356020614dae6142ce83614289565b82815260059290921b84018101918181019086841115614dcd57600080fd5b8286015b8481101561431657803567ffffffffffffffff811115614df15760008081fd5b614dff8986838b0101613d2f565b845250918301918301614dd1565b600080600080600060a08688031215614e2557600080fd5b853567ffffffffffffffff80821115614e3d57600080fd5b614e4989838a01614d32565b96506020880135915080821115614e5f57600080fd5b614e6b89838a01614d8d565b95506040880135915080821115614e8157600080fd5b614e8d89838a01614d8d565b94506060880135915080821115614ea357600080fd5b614eaf89838a01614d8d565b93506080880135915080821115614ec557600080fd5b50614ed288828901614d8d565b9150509295509295909350565b600082614eee57614eee614a6c565b500490565b68ffffffffffffffffff81811683821601908082111561296b5761296b61460a565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614f5c8285018b613c4e565b91508382036080850152614f70828a613c4e565b915060ff881660a085015283820360c0850152614f8d8288613987565b90861660e08501528381036101008501529050614c0c8185613987565b8051610d6a81613c04565b8051610d6a816141f8565b8051610d6a81613ad1565b8051610d6a81613f66565b805164ffffffffff81168114610d6a57600080fd5b60006101608284031215614ffe57600080fd5b615006613a5e565b61500f836145b3565b815261501d60208401614faa565b602082015261502e60408401614faa565b604082015261503f60608401614fb5565b606082015261505060808401614fc0565b608082015261506160a08401614fcb565b60a082015261507260c08401614fc0565b60c082015260e083015160e082015261010061508f8185016145b3565b908201526101206150a1848201614fd6565b90820152610140613bf9848201614fd6565b64ffffffffff81811683821601908082111561296b5761296b61460a565b60006102008083526150e58184018a613987565b905082810360208401526150f98189613987565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150615142905060a0830184613e36565b979650505050505050565b6000806040838503121561516057600080fd5b82516007811061516f57600080fd5b6020840151909250613fae81613f6656fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -305,9 +313,9 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetConfig() (Fun return _FunctionsCoordinator.Contract.GetConfig(&_FunctionsCoordinator.CallOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { +func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONFee(opts *bind.CallOpts, arg0 []byte) (*big.Int, error) { var out []interface{} - err := _FunctionsCoordinator.contract.Call(opts, &out, "getDONFee", arg0, arg1) + err := _FunctionsCoordinator.contract.Call(opts, &out, "getDONFee", arg0) if err != nil { return *new(*big.Int), err @@ -319,12 +327,12 @@ func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONFee(opts *bind.Ca } -func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetDONFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetDONFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) +func (_FunctionsCoordinator *FunctionsCoordinatorSession) GetDONFee(arg0 []byte) (*big.Int, error) { + return _FunctionsCoordinator.Contract.GetDONFee(&_FunctionsCoordinator.CallOpts, arg0) } -func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetDONFee(arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) { - return _FunctionsCoordinator.Contract.GetDONFee(&_FunctionsCoordinator.CallOpts, arg0, arg1) +func (_FunctionsCoordinator *FunctionsCoordinatorCallerSession) GetDONFee(arg0 []byte) (*big.Int, error) { + return _FunctionsCoordinator.Contract.GetDONFee(&_FunctionsCoordinator.CallOpts, arg0) } func (_FunctionsCoordinator *FunctionsCoordinatorCaller) GetDONPublicKey(opts *bind.CallOpts) ([]byte, error) { @@ -581,18 +589,6 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) OracleWithdr return _FunctionsCoordinator.Contract.OracleWithdrawAll(&_FunctionsCoordinator.TransactOpts) } -func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) { - return _FunctionsCoordinator.contract.Transact(opts, "sendRequest", request) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorSession) SendRequest(request IFunctionsCoordinatorRequest) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SendRequest(&_FunctionsCoordinator.TransactOpts, request) -} - -func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SendRequest(request IFunctionsCoordinatorRequest) (*types.Transaction, error) { - return _FunctionsCoordinator.Contract.SendRequest(&_FunctionsCoordinator.TransactOpts, request) -} - func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) SetConfig(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) { return _FunctionsCoordinator.contract.Transact(opts, "setConfig", _signers, _transmitters, _f, _onchainConfig, _offchainConfigVersion, _offchainConfig) } @@ -641,6 +637,18 @@ func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) SetThreshold return _FunctionsCoordinator.Contract.SetThresholdPublicKey(&_FunctionsCoordinator.TransactOpts, thresholdPublicKey) } +func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) StartRequest(opts *bind.TransactOpts, request FunctionsResponseRequestMeta) (*types.Transaction, error) { + return _FunctionsCoordinator.contract.Transact(opts, "startRequest", request) +} + +func (_FunctionsCoordinator *FunctionsCoordinatorSession) StartRequest(request FunctionsResponseRequestMeta) (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.StartRequest(&_FunctionsCoordinator.TransactOpts, request) +} + +func (_FunctionsCoordinator *FunctionsCoordinatorTransactorSession) StartRequest(request FunctionsResponseRequestMeta) (*types.Transaction, error) { + return _FunctionsCoordinator.Contract.StartRequest(&_FunctionsCoordinator.TransactOpts, request) +} + func (_FunctionsCoordinator *FunctionsCoordinatorTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _FunctionsCoordinator.contract.Transact(opts, "transferOwnership", to) } @@ -1106,7 +1114,7 @@ type FunctionsCoordinatorOracleRequest struct { DataVersion uint16 Flags [32]byte CallbackGasLimit uint64 - Commitment []byte + Commitment FunctionsResponseCommitment Raw types.Log } @@ -1742,11 +1750,11 @@ func (FunctionsCoordinatorConfigSet) Topic() common.Hash { } func (FunctionsCoordinatorConfigUpdated) Topic() common.Hash { - return common.HexToHash("0x65e5bc7ff6133456adf04bcd6ececcf049fc4117102e1ac9064d3b6570398403") + return common.HexToHash("0x5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c") } func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { - return common.HexToHash("0xd88ef982f3624222a23ef83ed2192cbdfba8e1e474a6cb1d315736d08479d2e3") + return common.HexToHash("0x0d37aa165b7e8c3b3c70cce43049e46de14d9ea8eabe99c920ba4ab3f9afd99e") } func (FunctionsCoordinatorOracleResponse) Topic() common.Hash { @@ -1778,7 +1786,7 @@ type FunctionsCoordinatorInterface interface { GetConfig(opts *bind.CallOpts) (FunctionsBillingConfig, error) - GetDONFee(opts *bind.CallOpts, arg0 []byte, arg1 IFunctionsBillingRequestBilling) (*big.Int, error) + GetDONFee(opts *bind.CallOpts, arg0 []byte) (*big.Int, error) GetDONPublicKey(opts *bind.CallOpts) ([]byte, error) @@ -1810,8 +1818,6 @@ type FunctionsCoordinatorInterface interface { OracleWithdrawAll(opts *bind.TransactOpts) (*types.Transaction, error) - SendRequest(opts *bind.TransactOpts, request IFunctionsCoordinatorRequest) (*types.Transaction, error) - SetConfig(opts *bind.TransactOpts, _signers []common.Address, _transmitters []common.Address, _f uint8, _onchainConfig []byte, _offchainConfigVersion uint64, _offchainConfig []byte) (*types.Transaction, error) SetDONPublicKey(opts *bind.TransactOpts, donPublicKey []byte) (*types.Transaction, error) @@ -1820,6 +1826,8 @@ type FunctionsCoordinatorInterface interface { SetThresholdPublicKey(opts *bind.TransactOpts, thresholdPublicKey []byte) (*types.Transaction, error) + StartRequest(opts *bind.TransactOpts, request FunctionsResponseRequestMeta) (*types.Transaction, error) + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) Transmit(opts *bind.TransactOpts, reportContext [3][32]byte, report []byte, rs [][32]byte, ss [][32]byte, rawVs [32]byte) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 89f706295fd..995c2afcb8f 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -37,7 +37,7 @@ type FunctionsResponseCommitment struct { SubscriptionId uint64 CallbackGasLimit uint32 EstimatedTotalCostJuels *big.Int - TimeoutTimestamp *big.Int + TimeoutTimestamp uint32 RequestId [32]byte DonFee *big.Int GasOverheadBeforeCallback *big.Int @@ -48,9 +48,16 @@ type FunctionsRouterConfig struct { MaxConsumersPerSubscription uint16 AdminFee *big.Int HandleOracleFulfillmentSelector [4]byte + GasForCallExactCheck uint16 MaxCallbackGasLimits []uint32 } +type IFunctionsSubscriptionsConsumer struct { + Allowed bool + InitiatedRequests uint64 + CompletedRequests uint64 +} + type IFunctionsSubscriptionsSubscription struct { Balance *big.Int Owner common.Address @@ -61,8 +68,8 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConsumerRequestsInFlight\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint40\",\"name\":\"timeoutTimestamp\",\"type\":\"uint40\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint80\",\"name\":\"donFee\",\"type\":\"uint80\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"adminFee\",\"type\":\"uint96\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162005c4338038062005c438339810160408190526200003491620004f7565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc816200012c565b5050600080525060086020527f5eff886ea0ce6ca488a3d6e336d6c0f75f46d19b42c06ce5ee98e42c96d256c780546001600160a01b031916301790556200012481620001de565b50506200066b565b336001600160a01b03821603620001865760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001e862000299565b805160098054602080850151604086015160e01c600160701b0263ffffffff60701b196001600160601b0390921662010000026001600160701b031990941661ffff9096169590951792909217919091169290921781556060830151805184936200025992600a92910190620002fc565b509050507f2eae8eac25da213074499a484cf9752294a27cb959de22f276f9003167b1611f816040516200028e9190620005dc565b60405180910390a150565b60065461010090046001600160a01b03163314620002fa5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b82805482825590600052602060002090600701600890048101928215620003a05791602002820160005b838211156200036c57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000326565b80156200039e5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200036c565b505b50620003ae929150620003b2565b5090565b5b80821115620003ae5760008155600101620003b3565b634e487b7160e01b600052604160045260246000fd5b604051608081016001600160401b0381118282101715620004045762000404620003c9565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004355762000435620003c9565b604052919050565b80516001600160e01b0319811681146200045657600080fd5b919050565b600082601f8301126200046d57600080fd5b815160206001600160401b038211156200048b576200048b620003c9565b8160051b6200049c8282016200040a565b9283528481018201928281019087851115620004b757600080fd5b83870192505b84831015620004ec57825163ffffffff81168114620004dc5760008081fd5b82529183019190830190620004bd565b979650505050505050565b600080604083850312156200050b57600080fd5b82516001600160a01b03811681146200052357600080fd5b60208401519092506001600160401b03808211156200054157600080fd5b90840190608082870312156200055657600080fd5b62000560620003df565b825161ffff811681146200057357600080fd5b815260208301516001600160601b03811681146200059057600080fd5b6020820152620005a3604084016200043d565b6040820152606083015182811115620005bb57600080fd5b620005c9888286016200045b565b6060830152508093505050509250929050565b6020808252825161ffff1682820152828101516001600160601b03166040808401919091528301516001600160e01b031916606080840191909152830151608080840152805160a0840181905260009291820190839060c08601905b808310156200066057835163ffffffff16825292840192600192909201919084019062000638565b509695505050505050565b6080516155a0620006a360003960008181610e4a015281816122bc0152818161290f01528181612a170152612eb401526155a06000f3fe608060405234801561001057600080fd5b50600436106102c85760003560e01c80637341c10c1161017b578063a4c0ed36116100d8578063c3f909d41161008c578063e72f6e3011610071578063e72f6e30146106eb578063e82ad7d4146106fe578063f2fde38b1461071157600080fd5b8063c3f909d4146106c3578063d7ae1d30146106d857600080fd5b8063aab396bd116100bd578063aab396bd1461067e578063b734c0f4146106a4578063badc3eb6146106ac57600080fd5b8063a4c0ed3614610658578063a9c9a9181461066b57600080fd5b806391e1ff721161012f578063a1d4c82811610114578063a1d4c8281461060f578063a21a23e414610630578063a47c76961461063857600080fd5b806391e1ff72146105e95780639f87fad7146105fc57600080fd5b8063823597401161016057806382359740146105ab5780638456cb59146105be5780638da5cb5b146105c657600080fd5b80637341c10c1461059057806379ba5097146105a357600080fd5b8063461d27621161022957806366316d8d116101dd578063674603d0116101c2578063674603d0146104b05780636a2215de146105455780636e3b33231461057d57600080fd5b806366316d8d14610476578063664199701461048957600080fd5b806355fedefa1161020e57806355fedefa1461041e5780635c975abb1461044c5780635ed6dfba1461046357600080fd5b8063461d2762146103f85780634b8832d31461040b57600080fd5b80631ded3b36116102805780633e871e4d116102655780633e871e4d146103bc5780633f4ba83a146103cf57806341db4ca3146103d757600080fd5b80631ded3b361461038d5780632a905ccc146103a057600080fd5b806310fc49c1116102b157806310fc49c11461030257806312b5834914610315578063181f5a771461034457600080fd5b806302bcc5b6146102cd5780630c5d49cb146102e2575b600080fd5b6102e06102db366004614314565b610724565b005b6102ea608481565b60405161ffff90911681526020015b60405180910390f35b6102e0610310366004614355565b610783565b6000546bffffffffffffffffffffffff165b6040516bffffffffffffffffffffffff90911681526020016102f9565b6103806040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b6040516102f991906143fc565b6102e061039b36600461440f565b61087f565b6009546201000090046bffffffffffffffffffffffff16610327565b6102e06103ca3660046145cb565b6108b1565b6102e0610b70565b6103ea6103e53660046146df565b610b82565b6040519081526020016102f9565b6103ea6104063660046146df565b610be2565b6102e0610419366004614763565b610bee565b6103ea61042c366004614314565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b60405190151581526020016102f9565b6102e06104713660046147b6565b610cec565b6102e06104843660046147b6565b610e8e565b60025467ffffffffffffffff165b60405167ffffffffffffffff90911681526020016102f9565b61051d6104be3660046147e4565b73ffffffffffffffffffffffffffffffffffffffff91909116600090815260046020908152604080832067ffffffffffffffff948516845290915290205460ff8116926101008204831692690100000000000000000090920490911690565b60408051931515845267ffffffffffffffff92831660208501529116908201526060016102f9565b610558610553366004614812565b610f65565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020016102f9565b6102e061058b36600461482b565b611024565b6102e061059e366004614763565b611300565b6102e0611496565b6102e06105b9366004614314565b6115bd565b6102e061170c565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610558565b6102e06105f73660046148a1565b61171c565b6102e061060a366004614763565b611811565b61062261061d366004614b6c565b611be6565b6040516102f9929190614c54565b610497611fda565b61064b610646366004614314565b612167565b6040516102f99190614cce565b6102e0610666366004614d56565b61229c565b610558610679366004614812565b6124e8565b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb0976103ea565b6102e061254d565b6106b4612695565b6040516102f993929190614db2565b6106cb61275c565b6040516102f99190614e07565b6102e06106e6366004614763565b612873565b6102e06106f9366004614ea6565b6128d6565b61045361070c366004614314565b612a93565b6102e061071f366004614ea6565b612be2565b61072c612bf3565b61073581612bfb565b67ffffffffffffffff81166000908152600360205260409020546107809082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612c71565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600a54911a9081106107e8576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b600060096001018260ff168154811061080357610803614ec3565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610879576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107df565b50505050565b610887612bf3565b61089082612bfb565b67ffffffffffffffff90911660009081526003602081905260409091200155565b6108b9612f5d565b81518151811415806108cb5750600881115b15610902576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610a2e57600084828151811061092157610921614ec3565b60200260200101519050600084838151811061093f5761093f614ec3565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1614806109aa575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b156109e1576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81610a1b576040517f4855c288000000000000000000000000000000000000000000000000000000008152600481018390526024016107df565b505080610a2790614f21565b9050610905565b506040805180820190915283815260208082018490528451600b91610a57918391880190614154565b506020828101518051610a70926001850192019061419b565b5090505060005b8351811015610879577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610ab357610ab3614ec3565b602002602001015160086000878581518110610ad157610ad1614ec3565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610b1a57610b1a614ec3565b6020026020010151604051610b589392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1610b6981614f21565b9050610a77565b610b78612f5d565b610b80612fe3565b565b600080610b8e83610f65565b9050610bd683828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b91506130609050565b98975050505050505050565b600080610b8e836124e8565b610bf66133b5565b610bff826133bd565b610c07613483565b67ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c010000000000000000000000009092041614610ce85767ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be91015b60405180910390a25b5050565b610cf4612bf3565b806bffffffffffffffffffffffff16600003610d2a5750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff80831691161015610d84576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3060009081526001602052604081208054839290610db19084906bffffffffffffffffffffffff16614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550806000808282829054906101000a90046bffffffffffffffffffffffff16610e079190614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ce882826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166135c69092919063ffffffff16565b610e966133b5565b806bffffffffffffffffffffffff16600003610ede576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff80831691161015610f38576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526001602052604081208054839290610db19084906bffffffffffffffffffffffff16614f59565b6000805b600b5460ff82161015610fee57600b805460ff8316908110610f8d57610f8d614ec3565b90600052602060002001548303610fde57600c805460ff8316908110610fb557610fb5614ec3565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b610fe781614f85565b9050610f69565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107df565b61102c6133b5565b60005b818110156112fb57600083838381811061104b5761104b614ec3565b905061016002018036038101906110629190614fa4565b905060008160e00151905060008260600151905060056000838152602001908152602001600020548360405160200161109b9190614fc1565b60405160208183030381529060405280519060200120146110e8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015164ffffffffff1642101561112d576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af11580156111a0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111c491906150f0565b5060a083015167ffffffffffffffff8216600090815260036020526040812060010180549091906112049084906bffffffffffffffffffffffff16614f59565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff80861684529152919020805460019260099161128b9185916901000000000000000000900416615112565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a2505050806112f490614f21565b905061102f565b505050565b6113086133b5565b611311826133bd565b611319613483565b60095467ffffffffffffffff831660009081526003602052604090206002015461ffff9091169003611377576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8616845290915290205460ff16156113be575050565b73ffffffffffffffffffffffffffffffffffffffff8116600081815260046020908152604080832067ffffffffffffffff871680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09101610cdf565b60075473ffffffffffffffffffffffffffffffffffffffff163314611517576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107df565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6115c56133b5565b6115cd613483565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116929091041633811461166d576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107df565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f0910160405180910390a2505050565b611714612f5d565b610b80613653565b611724612f5d565b805160098054602080850151604086015160e01c6e010000000000000000000000000000027fffffffffffffffffffffffffffff00000000ffffffffffffffffffffffffffff6bffffffffffffffffffffffff90921662010000027fffffffffffffffffffffffffffffffffffff000000000000000000000000000090941661ffff9096169590951792909217919091169290921781556060830151805184936117d392600a92910190614215565b509050507f2eae8eac25da213074499a484cf9752294a27cb959de22f276f9003167b1611f816040516118069190614e07565b60405180910390a150565b6118196133b5565b611822826133bd565b61182a613483565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff81161515808352610100820486169483019490945269010000000000000000009004909316908301526118d2576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611927576040517fbcc4005500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff83166000908152600360209081526040808320600201805482518185028101850190935280835291929091908301828280156119a257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611977575b5050505050905060005b8151811015611b4a578373ffffffffffffffffffffffffffffffffffffffff168282815181106119de576119de614ec3565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611b3a578160018351611a109190615133565b81518110611a2057611a20614ec3565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611a6357611a63614ec3565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611add57611add615146565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611b4a565b611b4381614f21565b90506119ac565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b600080611bf16133b5565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614611c5a576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e0830151600090815260056020526040902054611cc257600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611cb293929190615175565b60405180910390a2506000611fcf565b600560008460e0015181526020019081526020016000205483604051602001611ceb9190614fc1565b6040516020818303038152906040528051906020012014611d4657600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611cb293929190615175565b826101400151836080015163ffffffff16611d6191906151a7565b64ffffffffff165a1015611daf57600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee184602001518685604051611cb293929190615175565b6000611dc4846080015163ffffffff166136ae565b611dce90886151c5565b9050600081878660000151611de391906151ed565b611ded91906151ed565b606086015167ffffffffffffffff166000908152600360205260409020549091506bffffffffffffffffffffffff9081169082161115611e7b57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee186602001518887604051611e6793929190615175565b60405180910390a25060009150611fcf9050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115611ee357600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee186602001518887604051611e6793929190615175565b5050600560008460e001518152602001908152602001600020600090556000611f1b8460e001518a8a87608001518860400151613750565b8051909150611f2b576001611f2e565b60005b92506000611f5d85606001518660a00151876040015188600001518c611f5788602001516136ae565b8d6138cc565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151611faa578e611fac565b8f5b8860400151604051611fc2959493929190615212565b60405180910390a3519150505b965096945050505050565b6000611fe46133b5565b611fec613483565b600280546000906120069067ffffffffffffffff16615274565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c081018252600080825233602083015291810182905260608101829052919250608082019060405190808252806020026020018201604052801561207c578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926121179260028501929091019061419b565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a08101919091526121a182612bfb565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561228257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612257575b505050505081526020016003820154815250509050919050565b6122a46133b5565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614612313576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461234d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061235b82840184614314565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166123d4576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff169186919061240b83856151ed565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661246191906151ed565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846124c8919061529b565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff1680612547576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107df565b92915050565b612555612f5d565b60005b600b54811015612678576000600b600001828154811061257a5761257a614ec3565b906000526020600020015490506000600b600101838154811061259f5761259f614ec3565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90921691909117905561267181614f21565b9050612558565b50600b600061268782826142bf565b610ce86001830160006142bf565b600b80546040805160208084028201810190925282815260009360609384938301828280156126e357602002820191906000526020600020905b8154815260200190600101908083116126cf575b50505050509150600b60010180548060200260200160405190810160405280929190818152602001828054801561275057602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612725575b50505050509050909192565b6040805160808101825260008082526020820181905291810191909152606080820152604080516080810182526009805461ffff811683526201000081046bffffffffffffffffffffffff166020808501919091526e01000000000000000000000000000090910460e01b7fffffffff000000000000000000000000000000000000000000000000000000001683850152600a80548551818402810184019096528086529394929360608601939283018282801561286557602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116128285790505b505050505081525050905090565b61287b6133b5565b612884826133bd565b61288c613483565b61289582612a93565b156128cc576040517fb42f66e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610ce88282612c71565b6128de612bf3565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561296b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061298f91906152ae565b6000549091506bffffffffffffffffffffffff16818111156129e7576040517fa99da30200000000000000000000000000000000000000000000000000000000815260048101829052602481018390526044016107df565b818110156112fb5760006129fb8284615133565b9050612a3e73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001685836135c6565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612b0b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612ae0575b5050505050905060005b8151811015612bd857600060046000848481518110612b3657612b36614ec3565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612bc757506001949350505050565b50612bd181614f21565b9050612b15565b5060009392505050565b612bea612f5d565b61078081613b15565b610b80612f5d565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610780576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684880152600185015491821684870152919004166060820152600282018054845181870281018701909552808552919492936080860193909290830182828015612d5257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612d27575b505050918352505060039190910154602090910152805190915060005b826080015151811015612e13576004600084608001518381518110612d9657612d96614ec3565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055612e0c81614f21565b9050612d6f565b5067ffffffffffffffff841660009081526003602052604081208181556001810182905590612e4560028301826142bf565b50600060039190910181905580548291908190612e719084906bffffffffffffffffffffffff16614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550612ef883826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166135c69092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611bd8565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314610b80576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107df565b612feb613c11565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b600061306a6133b5565b61307385612bfb565b61307d3386613c7d565b6130878583610783565b604080516101008101825233815267ffffffffffffffff8716600081815260036020818152858320805473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009091048116838801528688018c90526060870186905261ffff8b16608088015294845290829052015460a084015263ffffffff861660c08401526009546201000090046bffffffffffffffffffffffff1660e084015292517fbdd7e8800000000000000000000000000000000000000000000000000000000081529089169163bdd7e8809161316691906004016152c7565b610160604051808303816000875af1158015613186573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131aa91906153c8565b9050604051806101600160405280600960000160029054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020018873ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018767ffffffffffffffff1681526020018463ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015164ffffffffff1681526020018260e00151815260200182610100015169ffffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff168152506040516020016132b99190614fc1565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a08101516133139033908890613cf1565b60e081015167ffffffffffffffff8716600081815260036020526040908190205460a0850151915192938c9390927ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec99261339e926c0100000000000000000000000090910473ffffffffffffffffffffffffffffffffffffffff1691339132918e918e918e9161549b565b60405180910390a460e00151979650505050505050565b610b80613dcc565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613434576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614610ce8576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7fd8e0666292c202b1ce6a8ff0dd638652e662402ac53fbf9bd9d3bcc39d5eb09760005260086020527f29d6d16866b6e23fcc7ae534ca080a7a6eca5e1882ac6bf4569628fa2ee46ea45473ffffffffffffffffffffffffffffffffffffffff16806134ec5750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf89061354d90339060248101615513565b602060405180830381865afa15801561356a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061358e91906150f0565b610780576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107df565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526112fb908490613e39565b61365b613dcc565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586130363390565b60006bffffffffffffffffffffffff82111561374c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107df565b5090565b604080516060808201835260008083526020830152918101919091526009546040516000916e010000000000000000000000000000900460e01b9061379d90899089908990602401615542565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529181526020820180517fffffffff00000000000000000000000000000000000000000000000000000000949094167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff909416939093179092528151608480825260c0820190935290925060009182918291602082018180368337019050509050853b61384f57600080fd5b5a61138881101561385f57600080fd5b61138881039050876040820482031161387757600080fd5b60008086516020880160008b8df193505a900391503d608481111561389a575060845b808252806000602084013e50604080516060810182529315158452602084019290925290820152979650505050505050565b604080518082019091526000808252602082015260006138ec84866151c5565b90506000816138fb88866151ed565b61390591906151ed565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600390915292832080549297509394508493929161395c91859116614f59565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d945090926139b091859116614f59565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846139ea91906151ed565b3360009081526001602052604081208054909190613a179084906bffffffffffffffffffffffff166151ed565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b94509092613a5e918591166151ed565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613ae29185916901000000000000000000900416615112565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613b94576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107df565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff16610b80576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107df565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16610ce8576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660009081526003602052604081206001018054839290613d2b9084906bffffffffffffffffffffffff166151ed565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492613da1928492900416615112565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60065460ff1615610b80576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107df565b6000613e9b826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff16613f459092919063ffffffff16565b8051909150156112fb5780806020019051810190613eb991906150f0565b6112fb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107df565b6060613f548484600085613f5c565b949350505050565b606082471015613fee576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107df565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516140179190615577565b60006040518083038185875af1925050503d8060008114614054576040519150601f19603f3d011682016040523d82523d6000602084013e614059565b606091505b509150915061406a87838387614075565b979650505050505050565b6060831561410b5782516000036141045773ffffffffffffffffffffffffffffffffffffffff85163b614104576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107df565b5081613f54565b613f5483838151156141205781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107df91906143fc565b82805482825590600052602060002090810192821561418f579160200282015b8281111561418f578251825591602001919060010190614174565b5061374c9291506142d9565b82805482825590600052602060002090810192821561418f579160200282015b8281111561418f57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906141bb565b8280548282559060005260206000209060070160089004810192821561418f5791602002820160005b8382111561428257835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261423e565b80156142b25782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614282565b505061374c9291506142d9565b508054600082559060005260206000209081019061078091905b5b8082111561374c57600081556001016142da565b67ffffffffffffffff8116811461078057600080fd5b803561430f816142ee565b919050565b60006020828403121561432657600080fd5b8135614331816142ee565b9392505050565b63ffffffff8116811461078057600080fd5b803561430f81614338565b6000806040838503121561436857600080fd5b8235614373816142ee565b9150602083013561438381614338565b809150509250929050565b60005b838110156143a9578181015183820152602001614391565b50506000910152565b600081518084526143ca81602086016020860161438e565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60208152600061433160208301846143b2565b6000806040838503121561442257600080fd5b823561442d816142ee565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516080810167ffffffffffffffff8111828210171561448d5761448d61443b565b60405290565b604051610160810167ffffffffffffffff8111828210171561448d5761448d61443b565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156144fe576144fe61443b565b604052919050565b600067ffffffffffffffff8211156145205761452061443b565b5060051b60200190565b73ffffffffffffffffffffffffffffffffffffffff8116811461078057600080fd5b803561430f8161452a565b600082601f83011261456857600080fd5b8135602061457d61457883614506565b6144b7565b82815260059290921b8401810191818101908684111561459c57600080fd5b8286015b848110156145c05780356145b38161452a565b83529183019183016145a0565b509695505050505050565b600080604083850312156145de57600080fd5b823567ffffffffffffffff808211156145f657600080fd5b818501915085601f83011261460a57600080fd5b8135602061461a61457883614506565b82815260059290921b8401810191818101908984111561463957600080fd5b948201945b838610156146575785358252948201949082019061463e565b9650508601359250508082111561466d57600080fd5b5061467a85828601614557565b9150509250929050565b60008083601f84011261469657600080fd5b50813567ffffffffffffffff8111156146ae57600080fd5b6020830191508360208285010111156146c657600080fd5b9250929050565b803561ffff8116811461430f57600080fd5b60008060008060008060a087890312156146f857600080fd5b8635614703816142ee565b9550602087013567ffffffffffffffff81111561471f57600080fd5b61472b89828a01614684565b909650945061473e9050604088016146cd565b9250606087013561474e81614338565b80925050608087013590509295509295509295565b6000806040838503121561477657600080fd5b8235614781816142ee565b915060208301356143838161452a565b6bffffffffffffffffffffffff8116811461078057600080fd5b803561430f81614791565b600080604083850312156147c957600080fd5b82356147d48161452a565b9150602083013561438381614791565b600080604083850312156147f757600080fd5b82356148028161452a565b91506020830135614383816142ee565b60006020828403121561482457600080fd5b5035919050565b6000806020838503121561483e57600080fd5b823567ffffffffffffffff8082111561485657600080fd5b818501915085601f83011261486a57600080fd5b81358181111561487957600080fd5b8660206101608302850101111561488f57600080fd5b60209290920196919550909350505050565b600060208083850312156148b457600080fd5b823567ffffffffffffffff808211156148cc57600080fd5b90840190608082870312156148e057600080fd5b6148e861446a565b6148f1836146cd565b81528383013561490081614791565b8185015260408301357fffffffff000000000000000000000000000000000000000000000000000000008116811461493757600080fd5b604082015260608301358281111561494e57600080fd5b80840193505086601f84011261496357600080fd5b8235915061497361457883614506565b82815260059290921b8301840191848101908884111561499257600080fd5b938501935b838510156149b95784356149aa81614338565b82529385019390850190614997565b6060830152509695505050505050565b600082601f8301126149da57600080fd5b813567ffffffffffffffff8111156149f4576149f461443b565b614a2560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016144b7565b818152846020838601011115614a3a57600080fd5b816020850160208301376000918101602001919091529392505050565b64ffffffffff8116811461078057600080fd5b803561430f81614a57565b69ffffffffffffffffffff8116811461078057600080fd5b803561430f81614a75565b60006101608284031215614aab57600080fd5b614ab3614493565b9050614abe826147ab565b8152614acc6020830161454c565b6020820152614add6040830161454c565b6040820152614aee60608301614304565b6060820152614aff6080830161434a565b6080820152614b1060a083016147ab565b60a0820152614b2160c08301614a6a565b60c082015260e082013560e0820152610100614b3e818401614a8d565b90820152610120614b50838201614a6a565b90820152610140614b62838201614a6a565b9082015292915050565b6000806000806000806102008789031215614b8657600080fd5b863567ffffffffffffffff80821115614b9e57600080fd5b614baa8a838b016149c9565b97506020890135915080821115614bc057600080fd5b50614bcd89828a016149c9565b9550506040870135614bde81614791565b93506060870135614bee81614791565b92506080870135614bfe8161452a565b9150614c0d8860a08901614a98565b90509295509295509295565b60078110614c50577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614c628285614c19565b6bffffffffffffffffffffffff831660208301529392505050565b600081518084526020808501945080840160005b83811015614cc357815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614c91565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a0840152614d4060e0840182614c7d565b905060a084015160c08401528091505092915050565b60008060008060608587031215614d6c57600080fd5b8435614d778161452a565b935060208501359250604085013567ffffffffffffffff811115614d9a57600080fd5b614da687828801614684565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b81811015614df357845183529383019391830191600101614dd7565b50508481036040860152610bd68187614c7d565b6000602080835260a0830161ffff855116828501526bffffffffffffffffffffffff828601511660408501527fffffffff000000000000000000000000000000000000000000000000000000006040860151166060850152606085015160808086015281815180845260c0870191508483019350600092505b808310156145c057835163ffffffff168252928401926001929092019190840190614e80565b600060208284031215614eb857600080fd5b81356143318161452a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614f5257614f52614ef2565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115614f7e57614f7e614ef2565b5092915050565b600060ff821660ff8103614f9b57614f9b614ef2565b60010192915050565b60006101608284031215614fb757600080fd5b6143318383614a98565b81516bffffffffffffffffffffffff16815261016081016020830151614fff602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040830151615027604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060830151615043606084018267ffffffffffffffff169052565b50608083015161505b608084018263ffffffff169052565b5060a083015161507b60a08401826bffffffffffffffffffffffff169052565b5060c083015161509460c084018264ffffffffff169052565b5060e083015160e0830152610100808401516150bd8285018269ffffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b60006020828403121561510257600080fd5b8151801515811461433157600080fd5b67ffffffffffffffff818116838216019080821115614f7e57614f7e614ef2565b8181038181111561254757612547614ef2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff84811682528316602082015260608101613f546040830184614c19565b64ffffffffff818116838216019080821115614f7e57614f7e614ef2565b6bffffffffffffffffffffffff8181168382160280821691908281146150e8576150e8614ef2565b6bffffffffffffffffffffffff818116838216019080821115614f7e57614f7e614ef2565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015261524c6040820185614c19565b60a06060820152600061526260a08301856143b2565b8281036080840152610bd681856143b2565b600067ffffffffffffffff80831681810361529157615291614ef2565b6001019392505050565b8082018082111561254757612547614ef2565b6000602082840312156152c057600080fd5b5051919050565b60208152600073ffffffffffffffffffffffffffffffffffffffff8084511660208401528060208501511660408401525060408301516101008060608501526153146101208501836143b2565b91506060850151615331608086018267ffffffffffffffff169052565b50608085015161ffff811660a08601525060a085015160c085015260c085015161536360e086018263ffffffff169052565b5060e08501516bffffffffffffffffffffffff8116858301525090949350505050565b805161430f81614791565b805161430f8161452a565b805161430f816142ee565b805161430f81614338565b805161430f81614a57565b805161430f81614a75565b600061016082840312156153db57600080fd5b6153e3614493565b6153ec83615386565b81526153fa60208401615391565b602082015261540b60408401615391565b604082015261541c6060840161539c565b606082015261542d608084016153a7565b608082015261543e60a08401615386565b60a082015261544f60c084016153b2565b60c082015260e083015160e082015261010061546c8185016153bd565b9082015261012061547e8482016153b2565b908201526101406154908482016153b2565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e060608301526154dc60e08301876143b2565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff83168152604060208201526000613f5460408301846143b2565b83815260606020820152600061555b60608301856143b2565b828103604084015261556d81856143b2565b9695505050505050565b6000825161558981846020870161438e565b919091019291505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200601b3803806200601b8339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615968620006b3600039600081816113510152818161239101528181612c8001528181612d4401526131ee01526159686000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063a9c9a918116100e3578063cc77470a11610097578063e82ad7d411610071578063e82ad7d414610697578063ea320e0b146106aa578063f2fde38b146106bd57600080fd5b8063cc77470a1461065e578063d7ae1d3014610671578063e72f6e301461068457600080fd5b8063b734c0f4116100c8578063b734c0f41461062a578063badc3eb614610632578063c3f909d41461064957600080fd5b8063a9c9a9181461060f578063aab396bd1461062257600080fd5b806398e5cf721161013a578063a21a23e41161011f578063a21a23e4146105d4578063a47c7696146105dc578063a4c0ed36146105fc57600080fd5b806398e5cf72146105ae5780639f87fad7146105c157600080fd5b8063823597401161016b57806382359740146105705780638456cb59146105835780638da5cb5b1461058b57600080fd5b80637341c10c1461055557806379ba50971461056857600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461051d57600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b8063181f5a771161029657806321b60e7f1161027b57806321b60e7f146103c85780632a905ccc146103db5780633e871e4d1461040957600080fd5b8063181f5a771461036c5780631ded3b36146103b557600080fd5b80630fb25853116102c75780630fb258531461031857806310fc49c11461033957806312b583491461034c57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614628565b6106d0565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b61032b610326366004614928565b61072f565b60405161030f929190614a10565b6102f6610347366004614a39565b610b35565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103a86040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614ae0565b6102f66103c3366004614af3565b610c31565b6102f66103d6366004614bc9565b610c63565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6102f6610417366004614d07565b610d90565b6102f6611015565b610437610432366004614e09565b611027565b60405190815260200161030f565b610437610453366004614e09565b611087565b6102f6610466366004614e8d565b611093565b610437610479366004614628565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be366004614ebb565b6111e1565b6102f66104d1366004614ebb565b61139a565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004614ee9565b611483565b60405161030f9190614f17565b61053061052b366004614f4b565b611513565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f6610563366004614e8d565b6115d2565b6102f6611786565b6102f661057e366004614628565b6118ad565b6102f66119f4565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610530565b6102f66105bc366004614f64565b611a04565b6102f66105cf366004614e8d565b611cda565b6104e46120af565b6105ef6105ea366004614628565b61223c565b60405161030f91906150aa565b6102f661060a3660046150bd565b612371565b61053061061d366004614f4b565b6125bd565b600954610437565b6102f661261c565b61063a612768565b60405161030f93929190615119565b61065161282f565b60405161030f919061516e565b6104e461066c366004615218565b612964565b6102f661067f366004614e8d565b612be4565b6102f6610692366004615218565b612c47565b6104a06106a5366004614628565b612dc0565b6102f66106b8366004614f4b565b612f0f565b6102f66106cb366004615218565b612f1c565b6106d8612f2d565b6106e181612f35565b67ffffffffffffffff811660009081526003602052604090205461072c9082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612fab565b50565b60008061073a613297565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146107a3576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e083015160009081526005602052604090205461080b57600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516107fb93929190615235565b60405180910390a2506000610b2a565b600560008460e00151815260200190815260200160002054836040516020016108349190615267565b604051602081830303815290604052805190602001201461088f57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516107fb93929190615235565b826101400151836080015163ffffffff166108aa91906153c0565b64ffffffffff165a10156108f857600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516107fb93929190615235565b600061090d846080015163ffffffff1661329f565b61091790886153e5565b905060008187866000015168ffffffffffffffffff16610937919061540d565b610941919061540d565b9050610950856060015161223c565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff1611156109cb57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516109b793929190615235565b60405180910390a25060009150610b2a9050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610a3357600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516109b793929190615235565b5050600560008460e001518152602001908152602001600020600090556000610a6b8460e001518a8a87608001518860400151613341565b8051909150610a7b576001610a7e565b60005b92506000610ab885606001518660a001518760400151886000015168ffffffffffffffffff168c610ab2886020015161329f565b8d6134ce565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610b05578e610b07565b8f5b8860400151604051610b1d959493929190615432565b60405180910390a3519150505b965096945050505050565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a908110610b9a576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff1681548110610bb557610bb5615494565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610c2b576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff82166004820152602401610b91565b50505050565b610c39612f2d565b610c4282612f35565b67ffffffffffffffff90911660009081526003602081905260409091200155565b610c6b613717565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff00000000000000000000009096169190971617939093171693909317178155608083015180518493610d5292600b92910190614473565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c81604051610d85919061516e565b60405180910390a150565b610d98613717565b8151815181141580610daa5750600881115b15610de1576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ed3576000848281518110610e0057610e00615494565b602002602001015190506000848381518110610e1e57610e1e615494565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e89575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec0576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ecc906154c3565b9050610de4565b506040805180820190915283815260208082018490528451600c91610efc91839188019061451e565b506020828101518051610f159260018501920190614559565b5090505060005b8351811015610c2b577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f5857610f58615494565b602002602001015160086000878581518110610f7657610f76615494565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fbf57610fbf615494565b6020026020010151604051610ffd9392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a161100e816154c3565b9050610f1c565b61101d613717565b61102561379d565b565b60008061103383611513565b905061107b83828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b915061381a9050565b98975050505050505050565b600080611033836125bd565b61109b613297565b6110a482613b7c565b6110ac613c42565b73ffffffffffffffffffffffffffffffffffffffff81161580611113575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b1561114a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111e9612f2d565b806bffffffffffffffffffffffff1660000361121f5750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff90811690821681101561128b576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff82166004820152602401610b91565b30600090815260016020526040812080548492906112b89084906bffffffffffffffffffffffff166154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff1661130e91906154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061139583836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613d4c9092919063ffffffff16565b505050565b6113a2613297565b806bffffffffffffffffffffffff166000036113ea576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611456576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff82166004820152602401610b91565b33600090815260016020526040812080548492906112b89084906bffffffffffffffffffffffff166154fb565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561159c57600c805460ff831690811061153b5761153b615494565b9060005260206000200154830361158c57600d805460ff831690811061156357611563615494565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61159581615520565b9050611517565b506040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101839052602401610b91565b6115da613297565b6115e382613b7c565b6115eb613c42565b60006115fa600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff8216900361165d576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff82166004820152602401610b91565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff16156116a557505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff163314611807576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610b91565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118b5613297565b6118bd613c42565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116929091041633811461195d576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610b91565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611779565b6119fc613717565b611025613dd9565b611a0c613297565b60005b81811015611395576000838383818110611a2b57611a2b615494565b90506101600201803603810190611a42919061553f565b905060008160e001519050600082606001519050600560008381526020019081526020016000205483604051602001611a7b9190615267565b6040516020818303038152906040528051906020012014611ac8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015163ffffffff16421015611b0c576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015611b7f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ba3919061555c565b5060a083015167ffffffffffffffff821660009081526003602052604081206001018054909190611be39084906bffffffffffffffffffffffff166154fb565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff808616845291529190208054600192600991611c6a918591690100000000000000000090041661557e565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080611cd3906154c3565b9050611a0f565b611ce2613297565b611ceb82613b7c565b611cf3613c42565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d9b576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611df0576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611e6b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e40575b5050505050905060005b8151811015612013578373ffffffffffffffffffffffffffffffffffffffff16828281518110611ea757611ea7615494565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612003578160018351611ed9919061559f565b81518110611ee957611ee9615494565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611f2c57611f2c615494565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611fa657611fa66155b2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055612013565b61200c816154c3565b9050611e75565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b60006120b9613297565b6120c1613c42565b600280546000906120db9067ffffffffffffffff166155e1565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612151578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926121ec92600285019290910190614559565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261227682612f35565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561235757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161232c575b505050505081526020016003820154815250509050919050565b612379613297565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146123e8576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612422576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061243082840184614628565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166124a9576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906124e0838561540d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff16612536919061540d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461259d9190615608565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff168061150d576040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610b91565b612624613717565b60005b600c54811015612747576000600c600001828154811061264957612649615494565b906000526020600020015490506000600c600101838154811061266e5761266e615494565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612740816154c3565b9050612627565b50600c600061275682826145d3565b6127646001830160006145d3565b5050565b600c80546040805160208084028201810190925282815260009360609384938301828280156127b657602002820191906000526020600020905b8154815260200190600101908083116127a2575b50505050509150600c60010180548060200260200160405190810160405280929190818152602001828054801561282357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116127f8575b50505050509050909192565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561295657602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116129195790505b505050505081525050905090565b600061296e613297565b612976613c42565b600280546000906129909067ffffffffffffffff166155e1565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612a06578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192612aa192600285019290910190614559565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b612bec613297565b612bf582613b7c565b612bfd613c42565b612c0682612dc0565b15612c3d576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6127648282612fab565b612c4f612f2d565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612cdc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d00919061561b565b6000549091506bffffffffffffffffffffffff1681811015611395576000612d28828461559f565b9050612d6b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613d4c565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612e3857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e0d575b5050505050905060005b8151811015612f0557600060046000848481518110612e6357612e63615494565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612ef457506001949350505050565b50612efe816154c3565b9050612e42565b5060009392505050565b612f17613717565b600955565b612f24613717565b61072c81613e34565b611025613717565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661072c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561308c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613061575b505050918352505060039190910154602090910152805190915060005b82608001515181101561314d5760046000846080015183815181106130d0576130d0615494565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613146816154c3565b90506130a9565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061317f60028301826145d3565b506000600391909101819055805482919081906131ab9084906bffffffffffffffffffffffff166154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061323283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613d4c9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd4981591016120a1565b611025613f30565b60006bffffffffffffffffffffffff82111561333d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610b91565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b9061338b90899089908990602401615634565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b61345657600080fd5b5a8481101561346457600080fd5b849003604081048103891061347857600080fd5b60008087516020890160008c8ef193505a900391503d608481111561349b575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b604080518082019091526000808252602082015260006134ee84866153e5565b90506000816134fd888661540d565b613507919061540d565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600390915292832080549297509394508493929161355e918591166154fb565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d945090926135b2918591166154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846135ec919061540d565b33600090815260016020526040812080549091906136199084906bffffffffffffffffffffffff1661540d565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926136609185911661540d565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f168552925290912080546001926009916136e4918591690100000000000000000090041661557e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314611025576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b91565b6137a5613f9d565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613824613297565b61382d85612f35565b6138373386614009565b6138418583610b35565b835160000361387b576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006138868661223c565b905060008773ffffffffffffffffffffffffffffffffffffffff166362fdb9916040518061012001604052803373ffffffffffffffffffffffffffffffffffffffff1681526020018981526020018a67ffffffffffffffff1681526020018861ffff1681526020016139128b67ffffffffffffffff166000908152600360208190526040909120015490565b815263ffffffff88166020820152600a5462010000900468ffffffffffffffffff166040820152606001613946338c611483565b8152602001858152506040518263ffffffff1660e01b815260040161396b9190615669565b610160604051808303816000875af115801561398b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139af91906157c5565b9050604051806101600160405280600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018973ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015163ffffffff1681526020018260e00151815260200182610100015168ffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613ab69190615267565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a0810151613b10903390899061407d565b8667ffffffffffffffff16898260e001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9856020015133328c8c8c8a60a00151604051613b649796959493929190615898565b60405180910390a460e0015198975050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613bf3576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612764576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613c725750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613cd390339060248101615910565b602060405180830381865afa158015613cf0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d14919061555c565b61072c576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610b91565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb00000000000000000000000000000000000000000000000000000000179052611395908490614158565b613de1613f30565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137f03390565b3373ffffffffffffffffffffffffffffffffffffffff821603613eb3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b91565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff1615611025576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610b91565b60065460ff16611025576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610b91565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612764576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906140b79084906bffffffffffffffffffffffff1661540d565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261412d92849290041661557e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60006141ba826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166142649092919063ffffffff16565b80519091501561139557808060200190518101906141d8919061555c565b611395576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152608401610b91565b6060614273848460008561427b565b949350505050565b60608247101561430d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610b91565b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051614336919061593f565b60006040518083038185875af1925050503d8060008114614373576040519150601f19603f3d011682016040523d82523d6000602084013e614378565b606091505b509150915061438987838387614394565b979650505050505050565b6060831561442a5782516000036144235773ffffffffffffffffffffffffffffffffffffffff85163b614423576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610b91565b5081614273565b614273838381511561443f5781518083602001fd5b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b919190614ae0565b828054828255906000526020600020906007016008900481019282156145125791602002820160005b838211156144e057835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261449c565b80156145105782816101000a81549063ffffffff02191690556004016020816003010492830192600103026144e0565b505b5061333d9291506145ed565b828054828255906000526020600020908101928215614512579160200282015b8281111561451257825182559160200191906001019061453e565b828054828255906000526020600020908101928215614512579160200282015b8281111561451257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614579565b508054600082559060005260206000209081019061072c91905b5b8082111561333d57600081556001016145ee565b67ffffffffffffffff8116811461072c57600080fd5b803561462381614602565b919050565b60006020828403121561463a57600080fd5b813561464581614602565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff8111828210171561469f5761469f61464c565b60405290565b60405160a0810167ffffffffffffffff8111828210171561469f5761469f61464c565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561470f5761470f61464c565b604052919050565b600082601f83011261472857600080fd5b813567ffffffffffffffff8111156147425761474261464c565b61477360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016146c8565b81815284602083860101111561478857600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461072c57600080fd5b8035614623816147a5565b73ffffffffffffffffffffffffffffffffffffffff8116811461072c57600080fd5b8035614623816147ca565b68ffffffffffffffffff8116811461072c57600080fd5b8035614623816147f7565b63ffffffff8116811461072c57600080fd5b803561462381614819565b64ffffffffff8116811461072c57600080fd5b803561462381614836565b6000610160828403121561486757600080fd5b61486f61467b565b905061487a8261480e565b8152614888602083016147ec565b6020820152614899604083016147ec565b60408201526148aa60608301614618565b60608201526148bb6080830161482b565b60808201526148cc60a083016147bf565b60a08201526148dd60c0830161482b565b60c082015260e082013560e08201526101006148fa81840161480e565b9082015261012061490c838201614849565b9082015261014061491e838201614849565b9082015292915050565b600080600080600080610200878903121561494257600080fd5b863567ffffffffffffffff8082111561495a57600080fd5b6149668a838b01614717565b9750602089013591508082111561497c57600080fd5b5061498989828a01614717565b955050604087013561499a816147a5565b935060608701356149aa816147a5565b925060808701356149ba816147ca565b91506149c98860a08901614854565b90509295509295509295565b60078110614a0c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614a1e82856149d5565b6bffffffffffffffffffffffff831660208301529392505050565b60008060408385031215614a4c57600080fd5b8235614a5781614602565b91506020830135614a6781614819565b809150509250929050565b60005b83811015614a8d578181015183820152602001614a75565b50506000910152565b60008151808452614aae816020860160208601614a72565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006146456020830184614a96565b60008060408385031215614b0657600080fd5b8235614b1181614602565b946020939093013593505050565b803561ffff8116811461462357600080fd5b600067ffffffffffffffff821115614b4b57614b4b61464c565b5060051b60200190565b600082601f830112614b6657600080fd5b81356020614b7b614b7683614b31565b6146c8565b82815260059290921b84018101918181019086841115614b9a57600080fd5b8286015b84811015614bbe578035614bb181614819565b8352918301918301614b9e565b509695505050505050565b600060208284031215614bdb57600080fd5b813567ffffffffffffffff80821115614bf357600080fd5b9083019060a08286031215614c0757600080fd5b614c0f6146a5565b614c1883614b1f565b81526020830135614c28816147f7565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614c6057600080fd5b6040820152614c7160608401614b1f565b6060820152608083013582811115614c8857600080fd5b614c9487828601614b55565b60808301525095945050505050565b600082601f830112614cb457600080fd5b81356020614cc4614b7683614b31565b82815260059290921b84018101918181019086841115614ce357600080fd5b8286015b84811015614bbe578035614cfa816147ca565b8352918301918301614ce7565b60008060408385031215614d1a57600080fd5b823567ffffffffffffffff80821115614d3257600080fd5b818501915085601f830112614d4657600080fd5b81356020614d56614b7683614b31565b82815260059290921b84018101918181019089841115614d7557600080fd5b948201945b83861015614d9357853582529482019490820190614d7a565b96505086013592505080821115614da957600080fd5b50614db685828601614ca3565b9150509250929050565b60008083601f840112614dd257600080fd5b50813567ffffffffffffffff811115614dea57600080fd5b602083019150836020828501011115614e0257600080fd5b9250929050565b60008060008060008060a08789031215614e2257600080fd5b8635614e2d81614602565b9550602087013567ffffffffffffffff811115614e4957600080fd5b614e5589828a01614dc0565b9096509450614e68905060408801614b1f565b92506060870135614e7881614819565b80925050608087013590509295509295509295565b60008060408385031215614ea057600080fd5b8235614eab81614602565b91506020830135614a67816147ca565b60008060408385031215614ece57600080fd5b8235614ed9816147ca565b91506020830135614a67816147a5565b60008060408385031215614efc57600080fd5b8235614f07816147ca565b91506020830135614a6781614602565b6060810161150d828480511515825260208082015167ffffffffffffffff9081169184019190915260409182015116910152565b600060208284031215614f5d57600080fd5b5035919050565b60008060208385031215614f7757600080fd5b823567ffffffffffffffff80821115614f8f57600080fd5b818501915085601f830112614fa357600080fd5b813581811115614fb257600080fd5b86602061016083028501011115614fc857600080fd5b60209290920196919550909350505050565b600081518084526020808501945080840160005b8381101561502057815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614fee565b509495945050505050565b60006bffffffffffffffffffffffff808351168452602083015173ffffffffffffffffffffffffffffffffffffffff8082166020870152826040860151166040870152806060860151166060870152505050608082015160c0608085015261509660c0850182614fda565b60a093840151949093019390935250919050565b602081526000614645602083018461502b565b600080600080606085870312156150d357600080fd5b84356150de816147ca565b935060208501359250604085013567ffffffffffffffff81111561510157600080fd5b61510d87828801614dc0565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561515a5784518352938301939183019160010161513e565b5050848103604086015261107b8187614fda565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614bbe57835163ffffffff1682529284019260019290920191908401906151f2565b60006020828403121561522a57600080fd5b8135614645816147ca565b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161427360408301846149d5565b815168ffffffffffffffffff168152610160810160208301516152a2602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516152ca604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516152e6606084018267ffffffffffffffff169052565b5060808301516152fe608084018263ffffffff169052565b5060a083015161531e60a08401826bffffffffffffffffffffffff169052565b5060c083015161533660c084018263ffffffff169052565b5060e083015160e08301526101008084015161535e8285018268ffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff8181168382160190808211156153de576153de615391565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461538957615389615391565b6bffffffffffffffffffffffff8181168382160190808211156153de576153de615391565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015261546c60408201856149d5565b60a06060820152600061548260a0830185614a96565b828103608084015261107b8185614a96565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036154f4576154f4615391565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156153de576153de615391565b600060ff821660ff810361553657615536615391565b60010192915050565b6000610160828403121561555257600080fd5b6146458383614854565b60006020828403121561556e57600080fd5b8151801515811461464557600080fd5b67ffffffffffffffff8181168382160190808211156153de576153de615391565b8181038181111561150d5761150d615391565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036155fe576155fe615391565b6001019392505050565b8082018082111561150d5761150d615391565b60006020828403121561562d57600080fd5b5051919050565b83815260606020820152600061564d6060830185614a96565b828103604084015261565f8185614a96565b9695505050505050565b6020815261569060208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516101608060408501526156ae610180850183614a96565b915060408501516156cb606086018267ffffffffffffffff169052565b50606085015161ffff8116608086015250608085015160a085015260a08501516156fd60c086018263ffffffff169052565b5060c085015168ffffffffffffffffff811660e08601525060e08501518051151561010086810191909152602082015167ffffffffffffffff9081166101208801526040830151166101408701528601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00183870152905061565f838261502b565b8051614623816147f7565b8051614623816147ca565b805161462381614602565b805161462381614819565b8051614623816147a5565b805161462381614836565b600061016082840312156157d857600080fd5b6157e061467b565b6157e983615783565b81526157f76020840161578e565b60208201526158086040840161578e565b604082015261581960608401615799565b606082015261582a608084016157a4565b608082015261583b60a084016157af565b60a082015261584c60c084016157a4565b60c082015260e083015160e0820152610100615869818501615783565b9082015261012061587b8482016157ba565b9082015261014061588d8482016157ba565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e060608301526158d960e0830187614a96565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006142736040830184614a96565b60008251615951818460208701614a72565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -289,34 +296,25 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetConfig() (FunctionsRout return _FunctionsRouter.Contract.GetConfig(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCaller) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, - - error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (IFunctionsSubscriptionsConsumer, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getConsumer", client, subscriptionId) - outstruct := new(GetConsumer) if err != nil { - return *outstruct, err + return *new(IFunctionsSubscriptionsConsumer), err } - outstruct.Allowed = *abi.ConvertType(out[0], new(bool)).(*bool) - outstruct.InitiatedRequests = *abi.ConvertType(out[1], new(uint64)).(*uint64) - outstruct.CompletedRequests = *abi.ConvertType(out[2], new(uint64)).(*uint64) + out0 := *abi.ConvertType(out[0], new(IFunctionsSubscriptionsConsumer)).(*IFunctionsSubscriptionsConsumer) - return *outstruct, err + return out0, err } -func (_FunctionsRouter *FunctionsRouterSession) GetConsumer(client common.Address, subscriptionId uint64) (GetConsumer, - - error) { +func (_FunctionsRouter *FunctionsRouterSession) GetConsumer(client common.Address, subscriptionId uint64) (IFunctionsSubscriptionsConsumer, error) { return _FunctionsRouter.Contract.GetConsumer(&_FunctionsRouter.CallOpts, client, subscriptionId) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetConsumer(client common.Address, subscriptionId uint64) (GetConsumer, - - error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetConsumer(client common.Address, subscriptionId uint64) (IFunctionsSubscriptionsConsumer, error) { return _FunctionsRouter.Contract.GetConsumer(&_FunctionsRouter.CallOpts, client, subscriptionId) } @@ -651,6 +649,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) CreateSubscription() ( return _FunctionsRouter.Contract.CreateSubscription(&_FunctionsRouter.TransactOpts) } +func (_FunctionsRouter *FunctionsRouterTransactor) CreateSubscriptionWithConsumer(opts *bind.TransactOpts, consumer common.Address) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "createSubscriptionWithConsumer", consumer) +} + +func (_FunctionsRouter *FunctionsRouterSession) CreateSubscriptionWithConsumer(consumer common.Address) (*types.Transaction, error) { + return _FunctionsRouter.Contract.CreateSubscriptionWithConsumer(&_FunctionsRouter.TransactOpts, consumer) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) CreateSubscriptionWithConsumer(consumer common.Address) (*types.Transaction, error) { + return _FunctionsRouter.Contract.CreateSubscriptionWithConsumer(&_FunctionsRouter.TransactOpts, consumer) +} + func (_FunctionsRouter *FunctionsRouterTransactor) Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment FunctionsResponseCommitment) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "fulfill", response, err, juelsPerGas, costWithoutCallback, transmitter, commitment) } @@ -795,6 +805,18 @@ func (_FunctionsRouter *FunctionsRouterTransactorSession) SendRequestToProposed( return _FunctionsRouter.Contract.SendRequestToProposed(&_FunctionsRouter.TransactOpts, subscriptionId, data, dataVersion, callbackGasLimit, donId) } +func (_FunctionsRouter *FunctionsRouterTransactor) SetAllowListId(opts *bind.TransactOpts, allowListId [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.contract.Transact(opts, "setAllowListId", allowListId) +} + +func (_FunctionsRouter *FunctionsRouterSession) SetAllowListId(allowListId [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.SetAllowListId(&_FunctionsRouter.TransactOpts, allowListId) +} + +func (_FunctionsRouter *FunctionsRouterTransactorSession) SetAllowListId(allowListId [32]byte) (*types.Transaction, error) { + return _FunctionsRouter.Contract.SetAllowListId(&_FunctionsRouter.TransactOpts, allowListId) +} + func (_FunctionsRouter *FunctionsRouterTransactor) SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) { return _FunctionsRouter.contract.Transact(opts, "setFlags", subscriptionId, flags) } @@ -3296,11 +3318,6 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParseUnpaused(log types.Log) (* return event, nil } -type GetConsumer struct { - Allowed bool - InitiatedRequests uint64 - CompletedRequests uint64 -} type GetProposedContractSet struct { TimelockEndBlock *big.Int Ids [][32]byte @@ -3354,7 +3371,7 @@ func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.Abig } func (FunctionsRouterConfigUpdated) Topic() common.Hash { - return common.HexToHash("0x2eae8eac25da213074499a484cf9752294a27cb959de22f276f9003167b1611f") + return common.HexToHash("0x049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c") } func (FunctionsRouterContractProposed) Topic() common.Hash { @@ -3442,9 +3459,7 @@ type FunctionsRouterInterface interface { GetConfig(opts *bind.CallOpts) (FunctionsRouterConfig, error) - GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (GetConsumer, - - error) + GetConsumer(opts *bind.CallOpts, client common.Address, subscriptionId uint64) (IFunctionsSubscriptionsConsumer, error) GetContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) @@ -3482,6 +3497,8 @@ type FunctionsRouterInterface interface { CreateSubscription(opts *bind.TransactOpts) (*types.Transaction, error) + CreateSubscriptionWithConsumer(opts *bind.TransactOpts, consumer common.Address) (*types.Transaction, error) + Fulfill(opts *bind.TransactOpts, response []byte, err []byte, juelsPerGas *big.Int, costWithoutCallback *big.Int, transmitter common.Address, commitment FunctionsResponseCommitment) (*types.Transaction, error) OnTokenTransfer(opts *bind.TransactOpts, arg0 common.Address, amount *big.Int, data []byte) (*types.Transaction, error) @@ -3506,6 +3523,8 @@ type FunctionsRouterInterface interface { SendRequestToProposed(opts *bind.TransactOpts, subscriptionId uint64, data []byte, dataVersion uint16, callbackGasLimit uint32, donId [32]byte) (*types.Transaction, error) + SetAllowListId(opts *bind.TransactOpts, allowListId [32]byte) (*types.Transaction, error) + SetFlags(opts *bind.TransactOpts, subscriptionId uint64, flags [32]byte) (*types.Transaction, error) TimeoutRequests(opts *bind.TransactOpts, requestsToTimeoutByCommitment []FunctionsResponseCommitment) (*types.Transaction, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 7260ef0c6e1..0dded72ec46 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,12 +1,12 @@ GETH_VERSION: 1.12.0 functions: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin 3c972870b0afeb6d73a29ebb182f24956a2cebb127b21c4f867d1ecf19a762db -functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin 0011ffbcd7208382a0b21e89ebe16c276650895212691980321993acc939e0e8 +functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin b2697ad4dfece903a1d34028826a017fa445eb3cd984006f1734fa9d47836ca0 functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca -functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 67dbd571188a909b4057940a760ea46eb0b276b09afd61456f4ba75a3cb5b4f9 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 31741a85040804f62d010e4f22ac8437bcf06583c00f35f9c6d67fb1fca55a46 +functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b80ce6eac78baa63dde3eab4b3c4ada0d1ae6980e9b736d1857b5474b84320a5 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin d5b38087c403062708cd1822551316f1602a93f599d694b6e522047313185e93 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin af1d9a3febc12048b71a9626b58541fa3b37d32aab18db0755d4bbdf94257610 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index d1a33eb5812..da13243fb67 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -189,6 +189,7 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, AdminFee: big.NewInt(0), HandleOracleFulfillmentSelector: handleOracleFulfillmentSelector, MaxCallbackGasLimits: []uint32{300_000, 500_000, 1_000_000}, + GasForCallExactCheck: 5000, } routerAddress, _, routerContract, err := functions_router.DeployFunctionsRouter(owner, b, linkAddr, functionsRouterConfig) require.NoError(t, err) @@ -201,7 +202,7 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, Enabled: false, // TODO: true SignerPublicKey: proofSignerPublicKey, } - allowListAddress, _, allowListContract, err := functions_allow_list.DeployTermsOfServiceAllowList(owner, b, routerAddress, allowListConfig) + allowListAddress, _, allowListContract, err := functions_allow_list.DeployTermsOfServiceAllowList(owner, b, allowListConfig) require.NoError(t, err) // Deploy Coordinator contract (matches updateConfig() in FunctionsBilling.sol) @@ -213,7 +214,7 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, RequestTimeoutSeconds: uint32(300), DonFee: big.NewInt(0), MaxSupportedRequestDataVersion: uint16(1), - FulfillmentGasPriceOverEstimationBP: big.NewInt(6_600), + FulfillmentGasPriceOverEstimationBP: uint32(6_600), FallbackNativePerUnitLink: big.NewInt(5_000_000_000_000_000), } require.NoError(t, err) diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 1ebd6aac6b6..fe9c460f27b 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -5,6 +5,7 @@ import ( "sync" "time" + "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" @@ -150,6 +151,51 @@ func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmR l.lggr.Errorw("LatestEvents: failed to parse a request log, skipping") continue } + + uint32Type, errType1 := abi.NewType("uint32", "uint32", nil) + uint40Type, errType2 := abi.NewType("uint40", "uint40", nil) + uint64Type, errType3 := abi.NewType("uint64", "uint64", nil) + uint72Type, errType4 := abi.NewType("uint72", "uint72", nil) + uint96Type, errType5 := abi.NewType("uint96", "uint96", nil) + addressType, errType6 := abi.NewType("address", "address", nil) + bytes32Type, errType7 := abi.NewType("bytes32", "bytes32", nil) + + if errType1 != nil || errType2 != nil || errType3 != nil || errType4 != nil || errType5 != nil || errType6 != nil || errType7 != nil { + l.lggr.Errorw("LatestEvents: failed to initialize types", "errType1", errType1, + "errType2", errType2, "errType3", errType3, "errType4", errType4, "errType5", errType5, "errType6", errType6, "errType7", errType7, + ) + continue + } + commitmentABI := abi.Arguments{ + {Type: uint72Type}, // AdminFee + {Type: addressType}, // Coordinator + {Type: addressType}, // Client + {Type: uint64Type}, // SubscriptionId + {Type: uint32Type}, // CallbackGasLimit + {Type: uint96Type}, // EstimatedTotalCostJuels + {Type: uint32Type}, // TimeoutTimestamp + {Type: bytes32Type}, // RequestId + {Type: uint72Type}, // DonFee + {Type: uint40Type}, // GasOverheadBeforeCallback + {Type: uint40Type}, // GasOverheadAfterCallback + } + commitmentBytes, err := commitmentABI.Pack( + oracleRequest.Commitment.AdminFee, + oracleRequest.Commitment.Coordinator, + oracleRequest.Commitment.Client, + oracleRequest.Commitment.SubscriptionId, + oracleRequest.Commitment.CallbackGasLimit, + oracleRequest.Commitment.EstimatedTotalCostJuels, + oracleRequest.Commitment.TimeoutTimestamp, + oracleRequest.Commitment.RequestId, + oracleRequest.Commitment.DonFee, + oracleRequest.Commitment.GasOverheadBeforeCallback, + oracleRequest.Commitment.GasOverheadAfterCallback, + ) + if err != nil { + l.lggr.Errorw("LatestEvents: failed to pack commitment bytes, skipping", err) + } + resultsReq = append(resultsReq, evmRelayTypes.OracleRequest{ RequestId: oracleRequest.RequestId, RequestingContract: oracleRequest.RequestingContract, @@ -161,7 +207,7 @@ func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmR Flags: oracleRequest.Flags, CallbackGasLimit: oracleRequest.CallbackGasLimit, TxHash: oracleRequest.Raw.TxHash, - OnchainMetadata: oracleRequest.Commitment, + OnchainMetadata: commitmentBytes, CoordinatorContract: coordinator, }) } From 45664c02d18b2babb727a23899591e93e96175b1 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sun, 6 Aug 2023 07:03:31 -0700 Subject: [PATCH 095/270] [Functions] Integration test for router upgrade (#10084) Contains several fixes that could cause failures earlier. --- .../v0/functions_integration_test.go | 6 +-- .../v0/internal/testconstants.go | 1 + .../v0/internal/testutils.go | 3 ++ .../v1/functions_integration_test.go | 52 ++++++++++++++---- .../v1/internal/testconstants.go | 1 + .../v1/internal/testutils.go | 54 +++++++++++++------ 6 files changed, 87 insertions(+), 30 deletions(-) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go index c0c0d1ff72a..e97d3189c65 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go @@ -18,12 +18,11 @@ var ( ) func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { - t.Skip() // simulated chain with all contracts owner, b, ticker, oracleContractAddress, oracleContract, clientContracts, registryAddress, registryContract, linkToken := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, 39999, nOracleNodes, maxGas, nil, nil) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, 39879, nOracleNodes, maxGas, nil, nil) // config for registry contract utils.SetRegistryConfig(t, owner, registryContract, oracleContractAddress) @@ -46,12 +45,11 @@ func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { } func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *testing.T) { - t.Skip() // simulated chain with all contracts owner, b, ticker, oracleContractAddress, oracleContract, clientContracts, registryAddress, registryContract, linkToken := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, 49999, nOracleNodes, maxGas, utils.ExportedOcr2Keystores, utils.MockThresholdKeyShares) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, 39889, nOracleNodes, maxGas, utils.ExportedOcr2Keystores, utils.MockThresholdKeyShares) // config for registry contract utils.SetRegistryConfig(t, owner, registryContract, oracleContractAddress) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testconstants.go b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testconstants.go index 2c53ca1eba6..62de14febfc 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testconstants.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testconstants.go @@ -7,6 +7,7 @@ var ( DefaultSecretsUrlsBase64 = "AQID" DefaultArg1 = "arg1" DefaultArg2 = "arg2" + DefaultGasPrice = 1_000_000_000 // Below are the corresponding values for the encrypted threshold keys used in the test // mockThresholdPubKey := `{"Group":"P256","G_bar":"BAnzIguQNKnA37Zh0b3Z3K5CcvxHjzfTIytt37ZgNQLaTeuiq9rrVhz+yaZcvNQ9EYw978KmmYOq6qd0NA/ERh8=","H":"BOyfKc8aowVjOK2qYf0kdeuLkPeqbjDnjDFGIj/2n7O+qHIvqKx3A07Oa92tP5DkcS5AL/tipXDIBJvVWvcvudk=","HArray":["BBhLQicdsIUgigmIW4l6Xi1jBkFFXEtm2wuvydoZCjZZdlDZt82pXtOI+vPQbd5iawQPX6u4HUrhEisqwhx5P0A=","BLTOIUViwoVJTAzCKIo2FgliIfK7w3jG6wjwf3LVkdsMYJ2ZiEJDA7YC1GwsVgutYdxrwOkAY+wnoh9j+AYF/rQ=","BH2vi5G9ftykpOJARMlziZuZKXSx5YiP131HpwWwsgFAquSpsNTRWHsjk4nc0lcQKf6x9E+7UUQpAPwDpyrh7Xc=","BHQBZMqVRvxQHtnC4tqfh9Qc632IfSCPCBDsePyLzD1nXOf/qJWrCpfsZ3T3PaRm/U30LSgnb1nsuXI9nDuTFsM="]}` diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go index 960e1ad0a46..691e14729c6 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go @@ -169,6 +169,7 @@ type deployedClientContract struct { func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, *backends.SimulatedBackend, *time.Ticker, common.Address, *ocr2dr_oracle.OCR2DROracle, []deployedClientContract, common.Address, *ocr2dr_registry.OCR2DRRegistry, *link_token_interface.LinkToken) { owner := testutils.MustNewSimTransactor(t) + owner.GasPrice = big.NewInt(int64(DefaultGasPrice)) sb := new(big.Int) sb, _ = sb.SetString("100000000000000000000", 10) // 1 eth genesisData := core.GenesisAlloc{owner.From: {Balance: sb}} @@ -257,6 +258,8 @@ func StartNewNode( c.EVM[0].LogPollInterval = models.MustNewDuration(1 * time.Second) c.EVM[0].Transactions.ForwardersEnabled = ptr(false) c.EVM[0].GasEstimator.LimitDefault = ptr(maxGas) + c.EVM[0].GasEstimator.Mode = ptr("FixedPrice") + c.EVM[0].GasEstimator.PriceDefault = assets.NewWei(big.NewInt(int64(DefaultGasPrice))) if len(thresholdKeyShare) > 0 { s.Threshold.ThresholdKeyShare = models.NewSecret(thresholdKeyShare) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index cf3a4c6c4de..e401964b18a 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -4,13 +4,14 @@ import ( "testing" "time" + "github.com/stretchr/testify/require" + functionsConfig "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" utils "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/integration_tests/v1/internal" ) var ( // a batch of 8 max-length results uses around 2M gas (assuming 70k gas per client callback - see FunctionsClientExample.sol) - // TODO: revisit gas limit vs batch sizing once necessary contract changes are made nOracleNodes = 4 nClients = 50 requestLenBytes = 1_000 @@ -20,15 +21,13 @@ var ( ) func TestIntegration_Functions_MultipleV1Requests_Success(t *testing.T) { - t.Skip() // simulated chain with all contracts - owner, b, ticker, coordinatorContractAddress, coordinatorContract, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) + owner, b, ticker, active, proposed, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() - utils.SetupRouterRoutes(t, owner, routerContract, coordinatorContractAddress, allowListContractAddress) - b.Commit() + utils.SetupRouterRoutes(t, b, owner, routerContract, active.Address, proposed.Address, allowListContractAddress) - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, coordinatorContractAddress, 39989, nOracleNodes, maxGas, nil, nil) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, 39979, nOracleNodes, maxGas, nil, nil) pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, @@ -41,9 +40,42 @@ func TestIntegration_Functions_MultipleV1Requests_Success(t *testing.T) { } // config for oracle contract - utils.SetOracleConfig(t, owner, coordinatorContract, oracleIdentities, batchSize, &pluginConfig) - utils.CommitWithFinality(b) + utils.SetOracleConfig(t, b, owner, active.Contract, oracleIdentities, batchSize, &pluginConfig) + + subscriptionId := utils.CreateAndFundSubscriptions(t, b, owner, linkToken, routerAddress, routerContract, clientContracts, allowListContract) + b.Commit() + utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsBytes, subscriptionId, 1*time.Minute) +} + +func TestIntegration_Functions_MultipleV1Requests_WithUpgrade(t *testing.T) { + // simulated chain with all contracts + owner, b, ticker, active, proposed, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) + defer ticker.Stop() + + utils.SetupRouterRoutes(t, b, owner, routerContract, active.Address, proposed.Address, allowListContractAddress) - // validate that all client contracts got correct responses to their requests - utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsBytes, 1*time.Minute) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, 39989, nOracleNodes, maxGas, nil, nil) + + pluginConfig := functionsConfig.ReportingPluginConfig{ + MaxQueryLengthBytes: 10_000, + MaxObservationLengthBytes: 15_000, + MaxReportLengthBytes: 15_000, + MaxRequestBatchSize: uint32(batchSize), + MaxReportTotalCallbackGas: uint32(maxTotalReportGas), + DefaultAggregationMethod: functionsConfig.AggregationMethod_AGGREGATION_MODE, + UniqueReports: true, + } + + // set config for both coordinators + utils.SetOracleConfig(t, b, owner, active.Contract, oracleIdentities, batchSize, &pluginConfig) + utils.SetOracleConfig(t, b, owner, proposed.Contract, oracleIdentities, batchSize, &pluginConfig) + + subscriptionId := utils.CreateAndFundSubscriptions(t, b, owner, linkToken, routerAddress, routerContract, clientContracts, allowListContract) + utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsBytes, subscriptionId, 1*time.Minute) + + // upgrade and send requests again + _, err := routerContract.UpdateContracts(owner) + require.NoError(t, err) + b.Commit() + utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsBytes, subscriptionId, 1*time.Minute) } diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go index 3a5cad74003..146414e4ebf 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go @@ -8,6 +8,7 @@ var ( DefaultArg1 = "arg1" DefaultArg2 = "arg2" DefaultDONId = "1" + DefaultGasPrice = 1_000_000_000 // This has been generated using the Functions Toolkit (https://github.com/smartcontractkit/functions-toolkit/blob/main/src/SecretsManager.ts) and decrypts to the JSON string `{"0x0":"qrvM"}` DefaultThresholdSecretsHex = "0x7b225444483243747874223a2265794a48636d393163434936496c41794e5459694c434a44496a6f69533035305a5559325448593056553168543341766148637955584a4b65545a68626b3177527939794f464e78576a59356158646d636a6c4f535430694c434a4d59574a6c62434936496b464251554642515546425155464251554642515546425155464251554642515546425155464251554642515546425155464251554642515545394969776956534936496b4a45536c6c7a51334e7a623055334d6e6444574846474e557056634770585a573157596e565265544d796431526d4d32786c636c705a647a4671536e6c47627a5256615735744e6d773355456855546e6b7962324e746155686f626c51354d564a6a4e6e5230656c70766147644255326372545430694c434a5658324a6863694936496b4a4961544e69627a5a45536d396a4d324d344d6c46614d5852724c325645536b4a484d336c5a556d783555306834576d684954697472623264575a306f33546e4e456232314b5931646853544979616d63305657644f556c526e57465272655570325458706952306c4a617a466e534851314f4430694c434a46496a6f694d7a524956466c354d544e474b307836596e5a584e7a6c314d6d356c655574514e6b397a656e467859335253513239705a315534534652704e4430694c434a47496a6f69557a5132596d6c6952545a584b314176546d744252445677575459796148426862316c6c6330684853556869556c56614e303155556c6f345554306966513d3d222c2253796d43747874223a2253764237652f4a556a552b433358757873384e5378316967454e517759755051623730306a4a6144222c224e6f6e6365223a224d31714b557a6b306b77374767593538227d" diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index da13243fb67..7d1f24090bb 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -57,7 +57,7 @@ func ptr[T any](v T) *T { return &v } var allowListPrivateKey = "0xae78c8b502571dba876742437f8bc78b689cf8518356c0921393d89caaf284ce" -func SetOracleConfig(t *testing.T, owner *bind.TransactOpts, coordinatorContract *functions_coordinator.FunctionsCoordinator, oracles []confighelper2.OracleIdentityExtra, batchSize int, functionsPluginConfig *functionsConfig.ReportingPluginConfig) { +func SetOracleConfig(t *testing.T, b *backends.SimulatedBackend, owner *bind.TransactOpts, coordinatorContract *functions_coordinator.FunctionsCoordinator, oracles []confighelper2.OracleIdentityExtra, batchSize int, functionsPluginConfig *functionsConfig.ReportingPluginConfig) { S := make([]int, len(oracles)) for i := 0; i < len(S); i++ { S[i] = 1 @@ -105,11 +105,10 @@ func SetOracleConfig(t *testing.T, owner *bind.TransactOpts, coordinatorContract offchainConfig, ) require.NoError(t, err) - - time.Sleep(1000 * time.Millisecond) + CommitWithFinality(b) } -func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToken *link_token_interface.LinkToken, routerContractAddress common.Address, routerContract *functions_router.FunctionsRouter, clientContracts []deployedClientContract, allowListContract *functions_allow_list.TermsOfServiceAllowList) (subscriptionId uint64) { +func CreateAndFundSubscriptions(t *testing.T, b *backends.SimulatedBackend, owner *bind.TransactOpts, linkToken *link_token_interface.LinkToken, routerContractAddress common.Address, routerContract *functions_router.FunctionsRouter, clientContracts []deployedClientContract, allowListContract *functions_allow_list.TermsOfServiceAllowList) (subscriptionId uint64) { allowed, err := allowListContract.HasAccess(nilOpts, owner.From, []byte{}) require.NoError(t, err) if !allowed { @@ -143,8 +142,7 @@ func CreateAndFundSubscriptions(t *testing.T, owner *bind.TransactOpts, linkToke amount := big.NewInt(0).Mul(big.NewInt(int64(numContracts)), big.NewInt(2e18)) // 2 LINK per client _, err = linkToken.TransferAndCall(owner, routerContractAddress, amount, data) require.NoError(t, err) - - time.Sleep(1000 * time.Millisecond) + b.Commit() return subscriptionID } @@ -162,12 +160,18 @@ type deployedClientContract struct { Contract *functions_client_example.FunctionsClientExample } -func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, *backends.SimulatedBackend, *time.Ticker, common.Address, *functions_coordinator.FunctionsCoordinator, []deployedClientContract, common.Address, *functions_router.FunctionsRouter, *link_token_interface.LinkToken, common.Address, *functions_allow_list.TermsOfServiceAllowList) { +type Coordinator struct { + Address common.Address + Contract *functions_coordinator.FunctionsCoordinator +} + +func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, *backends.SimulatedBackend, *time.Ticker, Coordinator, Coordinator, []deployedClientContract, common.Address, *functions_router.FunctionsRouter, *link_token_interface.LinkToken, common.Address, *functions_allow_list.TermsOfServiceAllowList) { owner := testutils.MustNewSimTransactor(t) + owner.GasPrice = big.NewInt(int64(DefaultGasPrice)) sb := new(big.Int) sb, _ = sb.SetString("100000000000000000000", 10) // 1 eth genesisData := core.GenesisAlloc{owner.From: {Balance: sb}} - gasLimit := ethconfig.Defaults.Miner.GasCeil * 2 + gasLimit := ethconfig.Defaults.Miner.GasCeil * 2 // 60 M blocks b := backends.NewSimulatedBackend(genesisData, gasLimit) b.Commit() @@ -176,7 +180,7 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, require.NoError(t, err) // Deploy mock LINK/ETH price feed - linkEthFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(owner, b, 0, big.NewInt(5021530000000000)) + linkEthFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(owner, b, 18, big.NewInt(5_000_000_000_000_000)) require.NoError(t, err) // Deploy Router contract @@ -214,12 +218,14 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, RequestTimeoutSeconds: uint32(300), DonFee: big.NewInt(0), MaxSupportedRequestDataVersion: uint16(1), - FulfillmentGasPriceOverEstimationBP: uint32(6_600), + FulfillmentGasPriceOverEstimationBP: uint32(1_000), FallbackNativePerUnitLink: big.NewInt(5_000_000_000_000_000), } require.NoError(t, err) coordinatorAddress, _, coordinatorContract, err := functions_coordinator.DeployFunctionsCoordinator(owner, b, routerAddress, coordinatorConfig, linkEthFeedAddr) require.NoError(t, err) + proposalAddress, _, proposalContract, err := functions_coordinator.DeployFunctionsCoordinator(owner, b, routerAddress, coordinatorConfig, linkEthFeedAddr) + require.NoError(t, err) // Deploy Client contracts clientContracts := []deployedClientContract{} @@ -243,10 +249,19 @@ func StartNewChainWithContracts(t *testing.T, nClients int) (*bind.TransactOpts, b.Commit() } }() - return owner, b, ticker, coordinatorAddress, coordinatorContract, clientContracts, routerAddress, routerContract, linkToken, allowListAddress, allowListContract + + active := Coordinator{ + Contract: coordinatorContract, + Address: coordinatorAddress, + } + proposed := Coordinator{ + Contract: proposalContract, + Address: proposalAddress, + } + return owner, b, ticker, active, proposed, clientContracts, routerAddress, routerContract, linkToken, allowListAddress, allowListContract } -func SetupRouterRoutes(t *testing.T, owner *bind.TransactOpts, routerContract *functions_router.FunctionsRouter, coordinatorAddress common.Address, allowListAddress common.Address) { +func SetupRouterRoutes(t *testing.T, b *backends.SimulatedBackend, owner *bind.TransactOpts, routerContract *functions_router.FunctionsRouter, coordinatorAddress common.Address, proposedCoordinatorAddress common.Address, allowListAddress common.Address) { allowListId, err := routerContract.GetAllowListId(nilOpts) require.NoError(t, err) var donId [32]byte @@ -256,10 +271,18 @@ func SetupRouterRoutes(t *testing.T, owner *bind.TransactOpts, routerContract *f _, err = routerContract.ProposeContractsUpdate(owner, proposedContractSetIds, proposedContractSetAddresses) require.NoError(t, err) - time.Sleep(1000 * time.Millisecond) + b.Commit() _, err = routerContract.UpdateContracts(owner) require.NoError(t, err) + b.Commit() + + // prepare next coordinator + proposedContractSetIds = []([32]byte){donId} + proposedContractSetAddresses = []common.Address{proposedCoordinatorAddress} + _, err = routerContract.ProposeContractsUpdate(owner, proposedContractSetIds, proposedContractSetAddresses) + require.NoError(t, err) + b.Commit() } type Node struct { @@ -305,7 +328,7 @@ func StartNewNode( c.EVM[0].Transactions.ForwardersEnabled = ptr(false) c.EVM[0].GasEstimator.LimitDefault = ptr(maxGas) c.EVM[0].GasEstimator.Mode = ptr("FixedPrice") - c.EVM[0].GasEstimator.PriceDefault = assets.NewWei(big.NewInt(60112956)) + c.EVM[0].GasEstimator.PriceDefault = assets.NewWei(big.NewInt(int64(DefaultGasPrice))) if len(thresholdKeyShare) > 0 { s.Threshold.ThresholdKeyShare = models.NewSecret(thresholdKeyShare) @@ -505,7 +528,6 @@ func CreateFunctionsNodes( owner *bind.TransactOpts, b *backends.SimulatedBackend, routerAddress common.Address, - coordinatorAddress common.Address, startingPort uint16, nOracleNodes int, maxGas int, @@ -567,12 +589,12 @@ func ClientTestRequests( clientContracts []deployedClientContract, requestLenBytes int, expectedSecrets []byte, + subscriptionId uint64, timeout time.Duration, ) { t.Helper() var donId [32]byte copy(donId[:], []byte(DefaultDONId)) - subscriptionId := CreateAndFundSubscriptions(t, owner, linkToken, routerAddress, routerContract, clientContracts, allowListContract) // send requests requestSources := make([][]byte, len(clientContracts)) rnd := rand.New(rand.NewSource(666)) From cae1a91a6e1fa57e94099e7c02317dfd7b748099 Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Sun, 6 Aug 2023 12:17:43 -0400 Subject: [PATCH 096/270] Optimize struct packing (#10094) --- .../functions/dev/1_0_0/FunctionsBilling.sol | 37 +++++--------- .../dev/1_0_0/FunctionsCoordinator.sol | 2 +- .../functions/dev/1_0_0/FunctionsRouter.sol | 48 +++++++------------ .../dev/1_0_0/FunctionsSubscriptions.sol | 13 +++-- .../accessControl/TermsOfServiceAllowList.sol | 4 +- .../dev/1_0_0/interfaces/IFunctionsRouter.sol | 4 +- .../interfaces/IFunctionsSubscriptions.sol | 25 ++++------ .../dev/1_0_0/libraries/FunctionsRequest.sol | 16 +++---- .../dev/1_0_0/libraries/FunctionsResponse.sol | 42 ++++++++-------- .../functions_coordinator.go | 43 ++++++----------- .../functions_router/functions_router.go | 44 ++++++----------- ...rapper-dependency-versions-do-not-edit.txt | 4 +- .../relay/evm/functions/logpoller_wrapper.go | 16 +++---- 13 files changed, 120 insertions(+), 178 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index c31e1b1b7b6..1892932202c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -32,30 +32,15 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // ================================================================ struct Config { - // Maximum amount of gas that can be given to a request's client callback - uint32 maxCallbackGasLimit; - // How long before we consider the feed price to be stale - // and fallback to fallbackNativePerUnitLink. - uint32 feedStalenessSeconds; - // Represents the average gas execution cost before the fulfillment callback. - // This amount is always billed for every request - uint32 gasOverheadBeforeCallback; - // Represents the average gas execution cost after the fulfillment callback. - // This amount is always billed for every request - uint32 gasOverheadAfterCallback; - // How many seconds it takes before we consider a request to be timed out - uint32 requestTimeoutSeconds; - // Additional flat fee (in Juels of LINK) that will be split between Node Operators - // Max value is 2^80 - 1 == 1.2m LINK. - uint72 donFee; - // The highest support request data version supported by the node - // All lower versions should also be supported - uint16 maxSupportedRequestDataVersion; - // Percentage of gas price overestimation to account for changes in gas price between request and response - // Held as basis points (one hundredth of 1 percentage point) - uint32 fulfillmentGasPriceOverEstimationBP; - // fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale - uint224 fallbackNativePerUnitLink; + uint32 maxCallbackGasLimit; // ══════════════════╗ Maximum amount of gas that can be given to a request's client callback + uint32 feedStalenessSeconds; // ║ How long before we consider the feed price to be stale and fallback to fallbackNativePerUnitLink. + uint32 gasOverheadBeforeCallback; // ║ Represents the average gas execution cost before the fulfillment callback. This amount is always billed for every request. + uint32 gasOverheadAfterCallback; // ║ Represents the average gas execution cost after the fulfillment callback. This amount is always billed for every request. + uint32 requestTimeoutSeconds; // ║ How many seconds it takes before we consider a request to be timed out + uint72 donFee; // ║ Additional flat fee (in Juels of LINK) that will be split between Node Operators. Max value is 2^80 - 1 == 1.2m LINK. + uint16 maxSupportedRequestDataVersion; // ═══════╝ The highest support request data version supported by the node. All lower versions should also be supported. + uint32 fulfillmentGasPriceOverEstimationBP; // ══╗ Percentage of gas price overestimation to account for changes in gas price between request and response. Held as basis points (one hundredth of 1 percentage point) + uint224 fallbackNativePerUnitLink; // ═══════════╝ fallback NATIVE CURRENCY / LINK conversion rate if the data feed is stale } Config private s_config; @@ -216,7 +201,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { ); // Check that subscription can afford the estimated cost - if ((request.subscription.balance - request.subscription.blockedBalance) < estimatedTotalCostJuels) { + if ((request.availableBalance) < estimatedTotalCostJuels) { revert InsufficientBalance(); } @@ -224,7 +209,7 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { address(this), request.requestingContract, request.subscriptionId, - request.consumer.initiatedRequests + 1 + request.initiatedRequests + 1 ); commitment = FunctionsResponse.Commitment({ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index fb8c6ad3745..7733e20d98c 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -136,7 +136,7 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli request.requestingContract, tx.origin, request.subscriptionId, - request.subscription.owner, + request.subscriptionOwner, request.data, request.dataVersion, request.flags, diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 646833ad5ac..224033f5d94 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -63,9 +63,9 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, error GasLimitTooBig(uint32 limit); struct CallbackResult { - bool success; - uint256 gasUsed; - bytes returnData; + bool success; // ══════╸ Whether the callback succeeded or not + uint256 gasUsed; // ═══╸ The amount of gas consumed during the callback + bytes returnData; // ══╸ The return of the callback function } // ================================================================ @@ -83,19 +83,11 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, // | Configuration state | // ================================================================ struct Config { - // Maximum number of consumers which can be added to a single subscription - // This bound ensures we are able to loop over all subscription consumers as needed, - // without exceeding gas limits. - // Should a user require more consumers, they can use multiple subscriptions. - uint16 maxConsumersPerSubscription; - // Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network - uint72 adminFee; - // The function selector that is used when calling back to the Client contract - bytes4 handleOracleFulfillmentSelector; - // Used during calling back to the client. Ensures we have at least enough gas to be able to revert if gasAmount > 63//64*gas available. - uint16 gasForCallExactCheck; - // List of max callback gas limits used by flag with GAS_FLAG_INDEX - uint32[] maxCallbackGasLimits; + uint16 maxConsumersPerSubscription; // ══════╗ Maximum number of consumers which can be added to a single subscription. This bound ensures we are able to loop over all subscription consumers as needed, without exceeding gas limits. Should a user require more consumers, they can use multiple subscriptions. + uint72 adminFee; // ║ Flat fee (in Juels of LINK) that will be paid to the Router owner for operation of the network + bytes4 handleOracleFulfillmentSelector; // ║ The function selector that is used when calling back to the Client contract + uint16 gasForCallExactCheck; // ═════════════╝ Used during calling back to the client. Ensures we have at least enough gas to be able to revert if gasAmount > 63//64*gas available. + uint32[] maxCallbackGasLimits; // ═══════════╸ List of max callback gas limits used by flag with GAS_FLAG_INDEX } Config private s_config; @@ -109,8 +101,8 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, uint8 private constant MAX_PROPOSAL_SET_LENGTH = 8; struct ContractProposalSet { - bytes32[] ids; - address[] to; + bytes32[] ids; // ══╸ The IDs that key into the routes that will be modified if the update is applied + address[] to; // ═══╸ The address of the contracts that the route will point to if the updated is applied } ContractProposalSet private s_proposedContractSet; @@ -167,7 +159,7 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, } // @inheritdoc IFunctionsRouter - function getAdminFee() external view override returns (uint72 adminFee) { + function getAdminFee() external view override returns (uint72) { return s_config.adminFee; } @@ -232,6 +224,7 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, } Subscription memory subscription = getSubscription(subscriptionId); + Consumer memory consumer = getConsumer(msg.sender, subscriptionId); // Forward request to DON FunctionsResponse.Commitment memory commitment = coordinator.startRequest( @@ -243,8 +236,10 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, flags: getFlags(subscriptionId), callbackGasLimit: callbackGasLimit, adminFee: s_config.adminFee, - consumer: getConsumer(msg.sender, subscriptionId), - subscription: subscription + initiatedRequests: consumer.initiatedRequests, + completedRequests: consumer.completedRequests, + availableBalance: subscription.balance - subscription.blockedBalance, + subscriptionOwner: subscription.owner }) ); @@ -478,15 +473,8 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, // ================================================================ // @inheritdoc IRouterBase - function getProposedContractSet() - external - view - override - returns (uint256 timelockEndBlock, bytes32[] memory ids, address[] memory to) - { - ids = s_proposedContractSet.ids; - to = s_proposedContractSet.to; - return (timelockEndBlock, ids, to); + function getProposedContractSet() external view override returns (bytes32[] memory, address[] memory) { + return (s_proposedContractSet.ids, s_proposedContractSet.to); } // @inheritdoc IRouterBase diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index cb43cab82fe..5ceb97a1e73 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -43,6 +43,13 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece uint64 private s_currentSubscriptionId; mapping(uint64 subscriptionId => IFunctionsSubscriptions.Subscription) private s_subscriptions; + + // Maintains the list of keys in s_consumers. + // We do this for 2 reasons: + // 1. To be able to clean up all keys from s_consumers when canceling a subscription. + // 2. To be able to return the list of all consumers in getSubscription. + // Note that we need the s_consumers map to be able to directly check if a + // consumer is valid without reading all the consumers from storage. mapping(address consumer => mapping(uint64 subscriptionId => IFunctionsSubscriptions.Consumer)) private s_consumers; event SubscriptionCreated(uint64 indexed subscriptionId, address owner); @@ -109,12 +116,10 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece uint96 juelsPerGas, uint96 gasUsed, uint96 costWithoutCallbackJuels - ) internal returns (Receipt memory receipt) { + ) internal returns (Receipt memory) { uint96 callbackGasCostJuels = juelsPerGas * gasUsed; uint96 totalCostJuels = costWithoutCallbackJuels + adminFee + callbackGasCostJuels; - receipt = Receipt({callbackGasCostJuels: callbackGasCostJuels, totalCostJuels: totalCostJuels}); - // Charge the subscription s_subscriptions[subscriptionId].balance -= totalCostJuels; @@ -130,7 +135,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece // Increment finished requests s_consumers[client][subscriptionId].completedRequests += 1; - return receipt; + return Receipt({callbackGasCostJuels: callbackGasCostJuels, totalCostJuels: totalCostJuels}); } // ================================================================ diff --git a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol index fc8cca9edf3..2ce107c9861 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/accessControl/TermsOfServiceAllowList.sol @@ -33,8 +33,8 @@ contract TermsOfServiceAllowList is ITermsOfServiceAllowList, IAccessController, // | Configuration state | // ================================================================ struct Config { - bool enabled; - address signerPublicKey; + bool enabled; // ═════════════╗ When enabled, access will be checked against s_allowedSenders. When disabled, all access will be allowed. + address signerPublicKey; // ══╝ The key pair that needs to sign the acceptance data } Config private s_config; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol index 3eb13574e49..ebc1dbd4538 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsRouter.sol @@ -87,17 +87,15 @@ interface IFunctionsRouter { function getProposedContractById(bytes32 id) external view returns (address); // @notice Return the latest proprosal set - // @return timelockEndBlock The block number that the proposal is able to be merged at // @return ids The identifiers of the contracts to update // @return to The addresses of the contracts that will be updated to - function getProposedContractSet() external view returns (uint, bytes32[] memory, address[] memory); + function getProposedContractSet() external view returns (bytes32[] memory, address[] memory); // @notice Proposes one or more updates to the contract routes // @dev Only callable by owner function proposeContractsUpdate(bytes32[] memory proposalSetIds, address[] memory proposalSetAddresses) external; // @notice Updates the current contract routes to the proposed contracts - // @dev Only callable once timelock has passed // @dev Only callable by owner function updateContracts() external; diff --git a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol index 117ae61fdbc..4072307edb8 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/interfaces/IFunctionsSubscriptions.sol @@ -6,25 +6,18 @@ import {FunctionsResponse} from "../libraries/FunctionsResponse.sol"; // @title Chainlink Functions Subscription interface. interface IFunctionsSubscriptions { struct Subscription { - // There are only 1e9*1e18 = 1e27 juels in existence, so the balance can fit in uint96 (2^96 ~ 7e28) - uint96 balance; // Common LINK balance that is controlled by the Router to be used for all consumer requests. - address owner; // Owner can fund/withdraw/cancel the sub. - uint96 blockedBalance; // LINK balance that is reserved to pay for pending consumer requests. - address proposedOwner; // For safely transferring sub ownership. - // Maintains the list of keys in s_consumers. - // We do this for 2 reasons: - // 1. To be able to clean up all keys from s_consumers when canceling a subscription. - // 2. To be able to return the list of all consumers in getSubscription. - // Note that we need the s_consumers map to be able to directly check if a - // consumer is valid without reading all the consumers from storage. - address[] consumers; // Client contracts that can use the subscription - bytes32 flags; // Per-subscription flags. + uint96 balance; // ═════════╗ Common LINK balance that is controlled by the Router to be used for all consumer requests. + address owner; // ══════════╝ The owner can fund/withdraw/cancel the subscription. + uint96 blockedBalance; // ══╗ LINK balance that is reserved to pay for pending consumer requests. + address proposedOwner; // ══╝ For safely transferring sub ownership. + address[] consumers; // ════╸ Client contracts that can use the subscription + bytes32 flags; // ══════════╸ Per-subscription flags } struct Consumer { - bool allowed; // Owner can fund/withdraw/cancel the sub. - uint64 initiatedRequests; // The number of requests that have been started - uint64 completedRequests; // The number of requests that have successfully completed or timed out + bool allowed; // ══════════════╗ Owner can fund/withdraw/cancel the sub. + uint64 initiatedRequests; // ║ The number of requests that have been started + uint64 completedRequests; // ══╝ The number of requests that have successfully completed or timed out } // @notice Get details about a subscription. diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol index 86d95cef656..0a669588ed0 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsRequest.sol @@ -22,14 +22,14 @@ library FunctionsRequest { } struct Request { - Location codeLocation; // The location of the source code that will be executed on each node in the DON - Location secretsLocation; // The location of secrets that will be passed into the source code. *Only Remote secrets are supported - CodeLanguage language; // The coding language that the source code is written in - string source; // Raw source code for Request.codeLocation of Location.Inline, URL for Request.codeLocation of Location.Remote, or slot decimal number for Request.codeLocation of Location.DONHosted - bytes encryptedSecretsReference; // Encrypted URLs for Request.secretsLocation of Location.Remote (use addSecretsReference()), or CBOR encoded slotid+version for Request.secretsLocation of Location.DONHosted (use addDONHostedSecrets()) - bytes requestSignature; // Signature generated by the subscription owner's EOA - string[] args; // String arguments that will be passed into the source code - bytes[] bytesArgs; // Bytes arguments that will be passed into the source code + Location codeLocation; // ════════════╸ The location of the source code that will be executed on each node in the DON + Location secretsLocation; // ═════════╸ The location of secrets that will be passed into the source code. *Only Remote secrets are supported + CodeLanguage language; // ════════════╸ The coding language that the source code is written in + string source; // ════════════════════╸ Raw source code for Request.codeLocation of Location.Inline, URL for Request.codeLocation of Location.Remote, or slot decimal number for Request.codeLocation of Location.DONHosted + bytes encryptedSecretsReference; // ══╸ Encrypted URLs for Request.secretsLocation of Location.Remote (use addSecretsReference()), or CBOR encoded slotid+version for Request.secretsLocation of Location.DONHosted (use addDONHostedSecrets()) + bytes requestSignature; // ═══════════╸ Signature generated by the subscription owner's EOA + string[] args; // ════════════════════╸ String arguments that will be passed into the source code + bytes[] bytesArgs; // ════════════════╸ Bytes arguments that will be passed into the source code } error EmptySource(); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol index 54baf35b0cc..178f22820e5 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol @@ -7,15 +7,17 @@ import {IFunctionsSubscriptions} from "../interfaces/IFunctionsSubscriptions.sol library FunctionsResponse { // Used to send request information from the Router to the Coordinator struct RequestMeta { - address requestingContract; // The client contract that is sending the request - bytes data; // CBOR encoded Chainlink Functions request data, use FunctionsRequest library to encode a request - uint64 subscriptionId; // Identifier of the billing subscription that will be charged for the request - uint16 dataVersion; // The version of the structure of the CBOR encoded request data - bytes32 flags; // Per-subscription account flags - uint32 callbackGasLimit; // The amount of gas that the callback to the consuming contract will be given - uint72 adminFee; // Flat fee (in Juels of LINK) that will be paid to the Router Owner for operation of the network - IFunctionsSubscriptions.Consumer consumer; // Details about the consumer making the request - IFunctionsSubscriptions.Subscription subscription; // Details about the subscription that will be charged for the request + bytes data; // ══════════════════╸ CBOR encoded Chainlink Functions request data, use FunctionsRequest library to encode a request + bytes32 flags; // ═══════════════╸ Per-subscription flags + address requestingContract; // ══╗ The client contract that is sending the request + uint96 availableBalance; // ═════╝ Common LINK balance of the subscription that is controlled by the Router to be used for all consumer requests. + uint72 adminFee; // ═════════════╗ Flat fee (in Juels of LINK) that will be paid to the Router Owner for operation of the network + uint64 subscriptionId; // ║ Identifier of the billing subscription that will be charged for the request + uint64 initiatedRequests; // ║ The number of requests that have been started + uint32 callbackGasLimit; // ║ The amount of gas that the callback to the consuming contract will be given + uint16 dataVersion; // ══════════╝ The version of the structure of the CBOR encoded request data + uint64 completedRequests; // ════╗ The number of requests that have successfully completed or timed out + address subscriptionOwner; // ═══╝ The owner of the billing subscription } enum FulfillResult { @@ -29,16 +31,16 @@ library FunctionsResponse { } struct Commitment { - uint72 adminFee; // -----------┐ - address coordinator; // -------┘ - address client; // ------------┐ - uint64 subscriptionId; // | - uint32 callbackGasLimit; // ---┘ - uint96 estimatedTotalCostJuels; - uint32 timeoutTimestamp; - bytes32 requestId; - uint72 donFee; - uint40 gasOverheadBeforeCallback; - uint40 gasOverheadAfterCallback; + bytes32 requestId; // ═════════════════╸ A unique identifier for a Chainlink Functions request + address coordinator; // ═══════════════╗ The Coordinator contract that manages the DON that is servicing a request + uint96 estimatedTotalCostJuels; // ════╝ The maximum cost in Juels (1e18) of LINK that will be charged to fulfill a request + address client; // ════════════════════╗ The client contract that sent the request + uint64 subscriptionId; // ║ Identifier of the billing subscription that will be charged for the request + uint32 callbackGasLimit; // ═══════════╝ The amount of gas that the callback to the consuming contract will be given + uint72 adminFee; // ═══════════════════╗ Flat fee (in Juels of LINK) that will be paid to the Router Owner for operation of the network + uint72 donFee; // ║ Fee (in Juels of LINK) that will be split between Node Operators for servicing a request + uint40 gasOverheadBeforeCallback; // ║ Represents the average gas execution cost before the fulfillment callback. + uint40 gasOverheadAfterCallback; // ║ Represents the average gas execution cost after the fulfillment callback. + uint32 timeoutTimestamp; // ═══════════╝ The timestamp at which a request will be eligible to be timed out } } diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index 78553a2dafb..a0bb7ef2420 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -43,49 +43,36 @@ type FunctionsBillingConfig struct { } type FunctionsResponseCommitment struct { - AdminFee *big.Int + RequestId [32]byte Coordinator common.Address + EstimatedTotalCostJuels *big.Int Client common.Address SubscriptionId uint64 CallbackGasLimit uint32 - EstimatedTotalCostJuels *big.Int - TimeoutTimestamp uint32 - RequestId [32]byte + AdminFee *big.Int DonFee *big.Int GasOverheadBeforeCallback *big.Int GasOverheadAfterCallback *big.Int + TimeoutTimestamp uint32 } type FunctionsResponseRequestMeta struct { - RequestingContract common.Address Data []byte - SubscriptionId uint64 - DataVersion uint16 Flags [32]byte - CallbackGasLimit uint32 + RequestingContract common.Address + AvailableBalance *big.Int AdminFee *big.Int - Consumer IFunctionsSubscriptionsConsumer - Subscription IFunctionsSubscriptionsSubscription -} - -type IFunctionsSubscriptionsConsumer struct { - Allowed bool - InitiatedRequests uint64 - CompletedRequests uint64 -} - -type IFunctionsSubscriptionsSubscription struct { - Balance *big.Int - Owner common.Address - BlockedBalance *big.Int - ProposedOwner common.Address - Consumers []common.Address - Flags [32]byte + SubscriptionId uint64 + InitiatedRequests uint64 + CallbackGasLimit uint32 + DataVersion uint16 + CompletedRequests uint64 + SubscriptionOwner common.Address } var FunctionsCoordinatorMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"indexed\":false,\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"consumer\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"subscription\",\"type\":\"tuple\"}],\"internalType\":\"structFunctionsResponse.RequestMeta\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"startRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b50604051620057dd380380620057dd83398101604081905262000034916200044f565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600b80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b50505050505062000600565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f56200033a565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a166001600160401b031990981697909717640100000000968a16870217600160401b600160801b03191668010000000000000000948a169490940263ffffffff60601b1916939093176c010000000000000000000000009289169290920291909117600160801b600160e81b031916600160801b91881691909102600160a01b600160e81b03191617600160a01b6001600160481b03909216919091021761ffff60e81b1916600160e81b61ffff909416939093029290921790925560e084015161010085015193166001600160e01b0390931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c906200032f90839062000558565b60405180910390a150565b6200034462000346565b565b6000546001600160a01b03163314620003445760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003ba57600080fd5b919050565b60405161012081016001600160401b0381118282101715620003f157634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003ba57600080fd5b80516001600160481b0381168114620003ba57600080fd5b805161ffff81168114620003ba57600080fd5b80516001600160e01b0381168114620003ba57600080fd5b60008060008385036101608112156200046757600080fd5b6200047285620003a2565b935061012080601f19830112156200048957600080fd5b62000493620003bf565b9150620004a360208701620003f7565b8252620004b360408701620003f7565b6020830152620004c660608701620003f7565b6040830152620004d960808701620003f7565b6060830152620004ec60a08701620003f7565b6080830152620004ff60c087016200040c565b60a08301526200051260e0870162000424565b60c083015261010062000527818801620003f7565b60e08401526200053982880162000437565b908301525091506200054f6101408501620003a2565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005b760a08401826001600160481b03169052565b5060c0830151620005ce60c084018261ffff169052565b5060e0830151620005e760e084018263ffffffff169052565b50610100928301516001600160e01b0316919092015290565b60805160a05161518d620006506000396000818161090901528181610c3301528181610e6b01528181611099015281816113e301528181611b6301526136a2015260006115a1015261518d6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381411834116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146105a3578063e3d0e712146105ab578063e4ddcea6146105be578063f2fde38b146105d457600080fd5b8063b1dc65a41461040e578063c3f909d414610421578063d227d2451461057357600080fd5b806385b214cf116100c857806385b214cf146103a35780638da5cb5b146103c6578063afcb95d7146103ee57600080fd5b8063814118341461031957806381f1b9381461032e57806381ff70481461033657600080fd5b806359b5b7ac1161015b57806379ba50971161013557806379ba5097146102e35780637d480787146102eb5780637f15e166146102f3578063807560311461030657600080fd5b806359b5b7ac1461027857806362fdb991146102b057806366316d8d146102d057600080fd5b806326ceabac1161018c57806326ceabac1461022d5780632a905ccc14610240578063533989871461026257600080fd5b8063083a5466146101b3578063181f5a77146101c85780631bdf7f1b1461021a575b600080fd5b6101c66101c1366004613945565b6105e7565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b60405161021191906139eb565b60405180910390f35b6101c6610228366004613b4e565b61063c565b6101c661023b366004613c31565b61085f565b610248610905565b60405168ffffffffffffffffff9091168152602001610211565b61026a61099b565b604051610211929190613c9f565b610248610286366004613dbd565b5060085474010000000000000000000000000000000000000000900468ffffffffffffffffff1690565b6102c36102be366004613dfa565b610bc2565b6040516102119190613f57565b6101c66102de366004613f80565b610d6f565b6101c6610f28565b6101c661102a565b6101c6610301366004613945565b611182565b6101c6610314366004613fb9565b6111d2565b610321611289565b604051610211919061400e565b6102046112f8565b61038060015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b6103b66103b1366004614021565b6113c9565b6040519015158152602001610211565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b604080516001815260006020820181905291810191909152606001610211565b6101c661041c36600461407f565b6114a8565b6105666040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff1660c083015260095490811660e0830152919091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010082015290565b6040516102119190614136565b610586610581366004614219565b611b5f565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611cbe565b6101c66105b9366004614332565b611d15565b6105c6612741565b604051908152602001610211565b6101c66105e2366004613c31565b612972565b6105ef612983565b600081900361062a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e610637828483614498565b505050565b610644612a06565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a167fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000090981697909717640100000000968a168702177fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff1668010000000000000000948a16949094027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff16939093176c0100000000000000000000000092891692909202919091177fffffff00000000000000000000000000ffffffffffffffffffffffffffffffff16700100000000000000000000000000000000918816919091027fffffff000000000000000000ffffffffffffffffffffffffffffffffffffffff16177401000000000000000000000000000000000000000068ffffffffffffffffff90921691909102177fff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167d01000000000000000000000000000000000000000000000000000000000061ffff909416939093029290921790925560e084015161010085015193167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c90610854908390614136565b60405180910390a150565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061089d57503373ffffffffffffffffffffffffffffffffffffffff821614155b156108d4576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d602052604081206109029161388a565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610972573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061099691906145be565b905090565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a0357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109d8575b505050505090506000815167ffffffffffffffff811115610a2657610a26613a05565b604051908082528060200260200182016040528015610a5957816020015b6060815260200190600190039081610a445790505b50905060005b8251811015610bb8576000600d6000858481518110610a8057610a806145db565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610acd906143ff565b80601f0160208091040260200160405190810160405280929190818152602001828054610af9906143ff565b8015610b465780601f10610b1b57610100808354040283529160200191610b46565b820191906000526020600020905b815481529060010190602001808311610b2957829003601f168201915b505050505090508051600003610b88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610b9b57610b9b6145db565b60200260200101819052505080610bb190614639565b9050610a5f565b5090939092509050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610c8a576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610c9b610c96836147ad565b612a0e565b9050610caa6020830183613c31565b73ffffffffffffffffffffffffffffffffffffffff168160e001517f0d37aa165b7e8c3b3c70cce43049e46de14d9ea8eabe99c920ba4ab3f9afd99e32856040016020810190610cfa919061488e565b610d086101408801886148ab565b610d19906040810190602001613c31565b610d2660208901896148e9565b610d3660808b0160608c0161494e565b60808b0135610d4b60c08d0160a08e01614969565b8b604051610d6199989796959493929190614986565b60405180910390a35b919050565b610d77612e37565b806bffffffffffffffffffffffff16600003610db15750336000908152600a60205260409020546bffffffffffffffffffffffff16610e0b565b336000908152600a60205260409020546bffffffffffffffffffffffff80831691161015610e0b576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600a602052604081208054839290610e389084906bffffffffffffffffffffffff16614a2e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610e8d7f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610f0c57600080fd5b505af1158015610f20573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610fae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611032612a06565b61103a612e37565b6000611044611289565b905060005b815181101561117e57336000908152600a6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d8484815181106110e5576110e56145db565b6020026020010151836040518363ffffffff1660e01b815260040161113a92919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b15801561115457600080fd5b505af1158015611168573d6000803e3d6000fd5b50505050508061117790614639565b9050611049565b5050565b61118a612983565b60008190036111c5576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c610637828483614498565b60005473ffffffffffffffffffffffffffffffffffffffff1633148061121d57506111fc33612fe2565b801561121d57503373ffffffffffffffffffffffffffffffffffffffff8416145b611253576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d60205260409020611283828483614498565b50505050565b606060068054806020026020016040519081016040528092919081815260200182805480156112ee57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116112c3575b5050505050905090565b6060600e8054611307906143ff565b9050600003611342576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e805461134f906143ff565b80601f016020809104026020016040519081016040528092919081815260200182805461137b906143ff565b80156112ee5780601f1061139d576101008083540402835291602001916112ee565b820191906000526020600020905b8154815290600101906020018083116113ab57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461143a576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526007602052604090205461145557506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906114989084815260200190565b60405180910390a1506001919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff8082166020850152610100909104169282019290925290831461158f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610fa5565b61159d8b8b8b8b8b8b6130cb565b60007f0000000000000000000000000000000000000000000000000000000000000000156115fa576002826020015183604001516115db9190614a53565b6115e59190614a9b565b6115f0906001614a53565b60ff169050611610565b602082015161160a906001614a53565b60ff1690505b888114611679576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610fa5565b8887146116e2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610fa5565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561172557611725614abd565b600281111561173657611736614abd565b905250905060028160200151600281111561175357611753614abd565b14801561179a57506006816000015160ff1681548110611775576117756145db565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b611800576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610fa5565b505050505061180d6138c4565b6000808a8a604051611820929190614aec565b604051908190038120611837918e90602001614afc565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b415760006001848984602081106118a0576118a06145db565b6118ad91901a601b614a53565b8e8e868181106118bf576118bf6145db565b905060200201358d8d878181106118d8576118d86145db565b9050602002013560405160008152602001604052604051611915949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015611937573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119b7576119b7614abd565b60028111156119c8576119c8614abd565b90525092506001836020015160028111156119e5576119e5614abd565b14611a4c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610fa5565b8251600090879060ff16601f8110611a6657611a666145db565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611ae8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610fa5565b8086846000015160ff16601f8110611b0257611b026145db565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b2d600186614a53565b94505080611b3a90614639565b9050611881565b505050611b52833383858e8e613182565b5050505050505050505050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bff57600080fd5b505afa158015611c13573d6000803e3d6000fd5b505050620f42408311159050611c55576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c5f610905565b90506000611ca287878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061028692505050565b9050611cb085858385613350565b925050505b95945050505050565b6060600c8054611ccd906143ff565b9050600003611d08576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c805461134f906143ff565b855185518560ff16601f831115611d88576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610fa5565b80600003611df2576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610fa5565b818314611e80576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610fa5565b611e8b816003614b10565b8311611ef3576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610fa5565b611efb612983565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f429088613413565b600554156120f757600554600090611f5c90600190614b27565b9050600060058281548110611f7357611f736145db565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fad57611fad6145db565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061202d5761202d614b3a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061209657612096614b3a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f42915050565b60005b81515181101561255e5760006004600084600001518481518110612120576121206145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561216a5761216a614abd565b146121d1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610fa5565b6040805180820190915260ff82168152600160208201528251805160049160009185908110612202576122026145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000016176101008360028111156122a3576122a3614abd565b0217905550600091506122b39050565b60046000846020015184815181106122cd576122cd6145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561231757612317614abd565b1461237e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610fa5565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123b1576123b16145db565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561245257612452614abd565b021790555050825180516005925083908110612470576124706145db565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124ec576124ec6145db565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061255681614639565b9150506120fa565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161261691849174010000000000000000000000000000000000000000900416614b69565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126754630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a0015161342c565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e059861272c988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614b86565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216848601526c010000000000000000000000008084048316606086015270010000000000000000000000000000000084048316608086015274010000000000000000000000000000000000000000840468ffffffffffffffffff1660a0808701919091527d01000000000000000000000000000000000000000000000000000000000090940461ffff1660c086015260095492831660e086015291047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16610100840152600b5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa1580156128a6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128ca9190614c36565b5093505092505080426128dd9190614b27565b836020015163ffffffff161080156128ff57506000836020015163ffffffff16115b1561292e57505061010001517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16919050565b6000821361296b576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610fa5565b5092915050565b61297a612983565b610902816134d7565b60005473ffffffffffffffffffffffffffffffffffffffff163314612a04576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610fa5565b565b612a04612983565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c010000000000000000000000008204811660608085019190915270010000000000000000000000000000000083048216608085015274010000000000000000000000000000000000000000830468ffffffffffffffffff1660a08501527d01000000000000000000000000000000000000000000000000000000000090920461ffff90811660c0850181905260095492831660e0860152949091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010084015290850151919291161115612ba4576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60085460009074010000000000000000000000000000000000000000900468ffffffffffffffffff1690506000612be58560a001513a848860c00151613350565b610100860151604081015190519192506bffffffffffffffffffffffff831691612c0f9190614a2e565b6bffffffffffffffffffffffff161015612c55576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612cdc30876000015188604001518960e00151602001516001612c7a9190614c86565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808760c0015168ffffffffffffffffff1681526020013073ffffffffffffffffffffffffffffffffffffffff168152602001876000015173ffffffffffffffffffffffffffffffffffffffff168152602001876040015167ffffffffffffffff1681526020018760a0015163ffffffff168152602001836bffffffffffffffffffffffff168152602001856080015163ffffffff1642612d899190614ca7565b63ffffffff1681526020018281526020018468ffffffffffffffffff168152602001856040015163ffffffff1664ffffffffff168152602001856060015163ffffffff1664ffffffffff16815250945084604051602001612dea9190613f57565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260079092529091205550919392505050565b600b546bffffffffffffffffffffffff16600003612e5157565b6000612e5b611289565b90508051600003612e98576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600b54600091612eb7916bffffffffffffffffffffffff16614cba565b905060005b8251811015612f835781600a6000858481518110612edc57612edc6145db565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612f449190614ce5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612f7c90614639565b9050612ebc565b508151612f909082614d0a565b600b8054600090612fb09084906bffffffffffffffffffffffff16614a2e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b600080600680548060200260200160405190810160405280929190818152602001828054801561304857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161301d575b5050505050905060005b81518110156130c1578373ffffffffffffffffffffffffffffffffffffffff16828281518110613084576130846145db565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036130b1575060019392505050565b6130ba81614639565b9050613052565b5060009392505050565b60006130d8826020614b10565b6130e3856020614b10565b6130ef88610144614ca7565b6130f99190614ca7565b6131039190614ca7565b61310e906000614ca7565b9050368114613179576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610fa5565b50505050505050565b60608080808061319486880188614e0d565b84519499509297509095509350915015806131b157508351855114155b806131be57508251855114155b806131cb57508151855114155b806131d857508051855114155b1561320f576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b85518110156133425760006132a7878381518110613232576132326145db565b602002602001015187848151811061324c5761324c6145db565b6020026020010151878581518110613266576132666145db565b6020026020010151878681518110613280576132806145db565b602002602001015187878151811061329a5761329a6145db565b60200260200101516135cc565b905060008160068111156132bd576132bd614abd565b14806132da575060018160068111156132d8576132d8614abd565b145b15613331578682815181106132f1576132f16145db565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b5061333b81614639565b9050613212565b505050505050505050505050565b600854600090819086906133889063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614b69565b6133929190614b69565b60095463ffffffff9182169250600091612710916133b1911688614b10565b6133bb9190614edf565b6133c59087614ca7565b905060006133d28261385e565b905060006133e08483614b10565b905060006133ee8789614ef3565b68ffffffffffffffffff1690506134058183614ca7565b9a9950505050505050505050565b600061341d611289565b51111561117e5761117e612e37565b6000808a8a8a8a8a8a8a8a8a60405160200161345099989796959493929190614f15565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613556576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610fa5565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906135e39190614feb565b9050806040516020016135f69190613f57565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600790935291205414613648576006915050611cb5565b600087815260076020526040902054613665576002915050611cb5565b60006136703a61385e565b9050600082610140015183610120015161368a91906150b3565b61369b9064ffffffffff1683614b10565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16630fb258538b8b8789610100015168ffffffffffffffffff16886136fb9190614ce5565b338b6040518763ffffffff1660e01b815260040161371e969594939291906150d1565b60408051808303816000875af115801561373c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613760919061514d565b9092509050600082600681111561377957613779614abd565b14806137965750600182600681111561379457613794614abd565b145b156138505760008b8152600760205260408120556137b48184614ce5565b336000908152600a6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff938416179055610100870151600b805468ffffffffffffffffff9092169390929161382191859116614ce5565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613868612741565b61387a83670de0b6b3a7640000614b10565b6138849190614edf565b92915050565b508054613896906143ff565b6000825580601f106138a6575050565b601f01602090049060005260206000209081019061090291906138e3565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156138f857600081556001016138e4565b5090565b60008083601f84011261390e57600080fd5b50813567ffffffffffffffff81111561392657600080fd5b60208301915083602082850101111561393e57600080fd5b9250929050565b6000806020838503121561395857600080fd5b823567ffffffffffffffff81111561396f57600080fd5b61397b858286016138fc565b90969095509350505050565b6000815180845260005b818110156139ad57602081850181015186830182015201613991565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006139fe6020830184613987565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610120810167ffffffffffffffff81118282101715613a5857613a58613a05565b60405290565b604051610160810167ffffffffffffffff81118282101715613a5857613a58613a05565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613ac957613ac9613a05565b604052919050565b63ffffffff8116811461090257600080fd5b8035610d6a81613ad1565b68ffffffffffffffffff8116811461090257600080fd5b8035610d6a81613aee565b803561ffff81168114610d6a57600080fd5b80357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff81168114610d6a57600080fd5b60006101208284031215613b6157600080fd5b613b69613a34565b613b7283613ae3565b8152613b8060208401613ae3565b6020820152613b9160408401613ae3565b6040820152613ba260608401613ae3565b6060820152613bb360808401613ae3565b6080820152613bc460a08401613b05565b60a0820152613bd560c08401613b10565b60c0820152613be660e08401613ae3565b60e0820152610100613bf9818501613b22565b908201529392505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461090257600080fd5b8035610d6a81613c04565b600060208284031215613c4357600080fd5b81356139fe81613c04565b600081518084526020808501945080840160005b83811015613c9457815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613c62565b509495945050505050565b604081526000613cb26040830185613c4e565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613d20577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613d0e838351613987565b94860194925090850190600101613cd4565b50909998505050505050505050565b600082601f830112613d4057600080fd5b813567ffffffffffffffff811115613d5a57613d5a613a05565b613d8b60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613a82565b818152846020838601011115613da057600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613dcf57600080fd5b813567ffffffffffffffff811115613de657600080fd5b613df284828501613d2f565b949350505050565b600060208284031215613e0c57600080fd5b813567ffffffffffffffff811115613e2357600080fd5b820161016081850312156139fe57600080fd5b805168ffffffffffffffffff1682526020810151613e6c602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151613e94604084018273ffffffffffffffffffffffffffffffffffffffff169052565b506060810151613eb0606084018267ffffffffffffffff169052565b506080810151613ec8608084018263ffffffff169052565b5060a0810151613ee860a08401826bffffffffffffffffffffffff169052565b5060c0810151613f0060c084018263ffffffff169052565b5060e081015160e083015261010080820151613f288285018268ffffffffffffffffff169052565b50506101208181015164ffffffffff81168483015250506101408181015164ffffffffff811684830152611283565b61016081016138848284613e36565b6bffffffffffffffffffffffff8116811461090257600080fd5b60008060408385031215613f9357600080fd5b8235613f9e81613c04565b91506020830135613fae81613f66565b809150509250929050565b600080600060408486031215613fce57600080fd5b8335613fd981613c04565b9250602084013567ffffffffffffffff811115613ff557600080fd5b614001868287016138fc565b9497909650939450505050565b6020815260006139fe6020830184613c4e565b60006020828403121561403357600080fd5b5035919050565b60008083601f84011261404c57600080fd5b50813567ffffffffffffffff81111561406457600080fd5b6020830191508360208260051b850101111561393e57600080fd5b60008060008060008060008060e0898b03121561409b57600080fd5b606089018a8111156140ac57600080fd5b8998503567ffffffffffffffff808211156140c657600080fd5b6140d28c838d016138fc565b909950975060808b01359150808211156140eb57600080fd5b6140f78c838d0161403a565b909750955060a08b013591508082111561411057600080fd5b5061411d8b828c0161403a565b999c989b50969995989497949560c00135949350505050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161419660a084018268ffffffffffffffffff169052565b5060c08301516141ac60c084018261ffff169052565b5060e08301516141c460e084018263ffffffff169052565b50610100838101517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8116848301525b505092915050565b67ffffffffffffffff8116811461090257600080fd5b8035610d6a816141f8565b60008060008060006080868803121561423157600080fd5b853561423c816141f8565b9450602086013567ffffffffffffffff81111561425857600080fd5b614264888289016138fc565b909550935050604086013561427881613ad1565b949793965091946060013592915050565b600067ffffffffffffffff8211156142a3576142a3613a05565b5060051b60200190565b600082601f8301126142be57600080fd5b813560206142d36142ce83614289565b613a82565b82815260059290921b840181019181810190868411156142f257600080fd5b8286015b8481101561431657803561430981613c04565b83529183019183016142f6565b509695505050505050565b803560ff81168114610d6a57600080fd5b60008060008060008060c0878903121561434b57600080fd5b863567ffffffffffffffff8082111561436357600080fd5b61436f8a838b016142ad565b9750602089013591508082111561438557600080fd5b6143918a838b016142ad565b965061439f60408a01614321565b955060608901359150808211156143b557600080fd5b6143c18a838b01613d2f565b94506143cf60808a0161420e565b935060a08901359150808211156143e557600080fd5b506143f289828a01613d2f565b9150509295509295509295565b600181811c9082168061441357607f821691505b60208210810361444c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561063757600081815260208120601f850160051c810160208610156144795750805b601f850160051c820191505b81811015610f2057828155600101614485565b67ffffffffffffffff8311156144b0576144b0613a05565b6144c4836144be83546143ff565b83614452565b6000601f84116001811461451657600085156144e05750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b1783556145ac565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156145655786850135825560209485019460019092019101614545565b50868210156145a0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b8051610d6a81613aee565b6000602082840312156145d057600080fd5b81516139fe81613aee565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361466a5761466a61460a565b5060010190565b60006060828403121561468357600080fd5b6040516060810181811067ffffffffffffffff821117156146a6576146a6613a05565b604052905080823580151581146146bc57600080fd5b815260208301356146cc816141f8565b602082015260408301356146df816141f8565b6040919091015292915050565b600060c082840312156146fe57600080fd5b60405160c0810167ffffffffffffffff828210818311171561472257614722613a05565b816040528293508435915061473682613f66565b90825260208401359061474882613c04565b8160208401526040850135915061475e82613f66565b81604084015261477060608601613c26565b6060840152608085013591508082111561478957600080fd5b50614796858286016142ad565b60808301525060a083013560a08201525092915050565b600061016082360312156147c057600080fd5b6147c8613a34565b6147d183613c26565b8152602083013567ffffffffffffffff808211156147ee57600080fd5b6147fa36838701613d2f565b602084015261480b6040860161420e565b604084015261481c60608601613b10565b60608401526080850135608084015261483760a08601613ae3565b60a084015261484860c08601613b05565b60c084015261485a3660e08701614671565b60e084015261014085013591508082111561487457600080fd5b50614881368286016146ec565b6101008301525092915050565b6000602082840312156148a057600080fd5b81356139fe816141f8565b600082357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff418336030181126148df57600080fd5b9190910192915050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261491e57600080fd5b83018035915067ffffffffffffffff82111561493957600080fd5b60200191503681900382131561393e57600080fd5b60006020828403121561496057600080fd5b6139fe82613b10565b60006020828403121561497b57600080fd5b81356139fe81613ad1565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a166020830152881660408201526102406060820181905281018690526000610260878982850137600083890182015261ffff8716608084015260a0830186905263ffffffff851660c0840152601f88017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016830101905061340560e0830184613e36565b6bffffffffffffffffffffffff82811682821603908082111561296b5761296b61460a565b60ff81811683821601908111156138845761388461460a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614aae57614aae614a6c565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b80820281158282048414176138845761388461460a565b818103818111156138845761388461460a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561296b5761296b61460a565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614bb68184018a613c4e565b90508281036080840152614bca8189613c4e565b905060ff871660a084015282810360c0840152614be78187613987565b905067ffffffffffffffff851660e0840152828103610100840152614c0c8185613987565b9c9b505050505050505050505050565b805169ffffffffffffffffffff81168114610d6a57600080fd5b600080600080600060a08688031215614c4e57600080fd5b614c5786614c1c565b9450602086015193506040860151925060608601519150614c7a60808701614c1c565b90509295509295909350565b67ffffffffffffffff81811683821601908082111561296b5761296b61460a565b808201808211156138845761388461460a565b60006bffffffffffffffffffffffff80841680614cd957614cd9614a6c565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561296b5761296b61460a565b6bffffffffffffffffffffffff8181168382160280821691908281146141f0576141f061460a565b600082601f830112614d4357600080fd5b81356020614d536142ce83614289565b82815260059290921b84018101918181019086841115614d7257600080fd5b8286015b848110156143165780358352918301918301614d76565b600082601f830112614d9e57600080fd5b81356020614dae6142ce83614289565b82815260059290921b84018101918181019086841115614dcd57600080fd5b8286015b8481101561431657803567ffffffffffffffff811115614df15760008081fd5b614dff8986838b0101613d2f565b845250918301918301614dd1565b600080600080600060a08688031215614e2557600080fd5b853567ffffffffffffffff80821115614e3d57600080fd5b614e4989838a01614d32565b96506020880135915080821115614e5f57600080fd5b614e6b89838a01614d8d565b95506040880135915080821115614e8157600080fd5b614e8d89838a01614d8d565b94506060880135915080821115614ea357600080fd5b614eaf89838a01614d8d565b93506080880135915080821115614ec557600080fd5b50614ed288828901614d8d565b9150509295509295909350565b600082614eee57614eee614a6c565b500490565b68ffffffffffffffffff81811683821601908082111561296b5761296b61460a565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614f5c8285018b613c4e565b91508382036080850152614f70828a613c4e565b915060ff881660a085015283820360c0850152614f8d8288613987565b90861660e08501528381036101008501529050614c0c8185613987565b8051610d6a81613c04565b8051610d6a816141f8565b8051610d6a81613ad1565b8051610d6a81613f66565b805164ffffffffff81168114610d6a57600080fd5b60006101608284031215614ffe57600080fd5b615006613a5e565b61500f836145b3565b815261501d60208401614faa565b602082015261502e60408401614faa565b604082015261503f60608401614fb5565b606082015261505060808401614fc0565b608082015261506160a08401614fcb565b60a082015261507260c08401614fc0565b60c082015260e083015160e082015261010061508f8185016145b3565b908201526101206150a1848201614fd6565b90820152610140613bf9848201614fd6565b64ffffffffff81811683821601908082111561296b5761296b61460a565b60006102008083526150e58184018a613987565b905082810360208401526150f98189613987565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150615142905060a0830184613e36565b979650505050505050565b6000806040838503121561516057600080fd5b82516007811061516f57600080fd5b6020840151909250613fae81613f6656fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"availableBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"}],\"internalType\":\"structFunctionsResponse.RequestMeta\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"startRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b50604051620056553803806200565583398101604081905262000034916200044f565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600b80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b50505050505062000600565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f56200033a565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a166001600160401b031990981697909717640100000000968a16870217600160401b600160801b03191668010000000000000000948a169490940263ffffffff60601b1916939093176c010000000000000000000000009289169290920291909117600160801b600160e81b031916600160801b91881691909102600160a01b600160e81b03191617600160a01b6001600160481b03909216919091021761ffff60e81b1916600160e81b61ffff909416939093029290921790925560e084015161010085015193166001600160e01b0390931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c906200032f90839062000558565b60405180910390a150565b6200034462000346565b565b6000546001600160a01b03163314620003445760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003ba57600080fd5b919050565b60405161012081016001600160401b0381118282101715620003f157634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003ba57600080fd5b80516001600160481b0381168114620003ba57600080fd5b805161ffff81168114620003ba57600080fd5b80516001600160e01b0381168114620003ba57600080fd5b60008060008385036101608112156200046757600080fd5b6200047285620003a2565b935061012080601f19830112156200048957600080fd5b62000493620003bf565b9150620004a360208701620003f7565b8252620004b360408701620003f7565b6020830152620004c660608701620003f7565b6040830152620004d960808701620003f7565b6060830152620004ec60a08701620003f7565b6080830152620004ff60c087016200040c565b60a08301526200051260e0870162000424565b60c083015261010062000527818801620003f7565b60e08401526200053982880162000437565b908301525091506200054f6101408501620003a2565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005b760a08401826001600160481b03169052565b5060c0830151620005ce60c084018261ffff169052565b5060e0830151620005e760e084018263ffffffff169052565b50610100928301516001600160e01b0316919092015290565b60805160a051615005620006506000396000818161090901528181610cbe01528181610eec015281816112360152818161136d01528181611b57015261367d0152600061159501526150056000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381f1b938116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146105a3578063e3d0e712146105ab578063e4ddcea6146105be578063f2fde38b146105d457600080fd5b8063b1dc65a41461040e578063c3f909d414610421578063d227d2451461057357600080fd5b80638da5cb5b116100c85780638da5cb5b146103a6578063a631571e146103ce578063afcb95d7146103ee57600080fd5b806381f1b9381461030e57806381ff70481461031657806385b214cf1461038357600080fd5b806359b5b7ac1161015b5780637d480787116101355780637d480787146102cb5780637f15e166146102d357806380756031146102e657806381411834146102f957600080fd5b806359b5b7ac1461027857806366316d8d146102b057806379ba5097146102c357600080fd5b806326ceabac1161018c57806326ceabac1461022d5780632a905ccc14610240578063533989871461026257600080fd5b8063083a5466146101b3578063181f5a77146101c85780631bdf7f1b1461021a575b600080fd5b6101c66101c136600461391e565b6105e7565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b60405161021191906139c4565b60405180910390f35b6101c6610228366004613b27565b61063c565b6101c661023b366004613c0a565b61085f565b610248610905565b60405168ffffffffffffffffff9091168152602001610211565b61026a61099b565b604051610211929190613c78565b610248610286366004613d96565b5060085474010000000000000000000000000000000000000000900468ffffffffffffffffff1690565b6101c66102be366004613df8565b610bc2565b6101c6610d7b565b6101c6610e7d565b6101c66102e136600461391e565b610fd5565b6101c66102f4366004613e31565b611025565b6103016110dc565b6040516102119190613e86565b61020461114b565b61036060015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b610396610391366004613e99565b61121c565b6040519015158152602001610211565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6103e16103dc366004613eb2565b6112fc565b6040516102119190614011565b604080516001815260006020820181905291810191909152606001610211565b6101c661041c366004614065565b61149c565b6105666040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff1660c083015260095490811660e0830152919091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010082015290565b604051610211919061411c565b6105866105813660046141ff565b611b53565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611cb2565b6101c66105b9366004614318565b611d09565b6105c6612735565b604051908152602001610211565b6101c66105e2366004613c0a565b612966565b6105ef612977565b600081900361062a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e61063782848361447e565b505050565b6106446129fa565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a167fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000090981697909717640100000000968a168702177fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff1668010000000000000000948a16949094027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff16939093176c0100000000000000000000000092891692909202919091177fffffff00000000000000000000000000ffffffffffffffffffffffffffffffff16700100000000000000000000000000000000918816919091027fffffff000000000000000000ffffffffffffffffffffffffffffffffffffffff16177401000000000000000000000000000000000000000068ffffffffffffffffff90921691909102177fff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167d01000000000000000000000000000000000000000000000000000000000061ffff909416939093029290921790925560e084015161010085015193167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c9061085490839061411c565b60405180910390a150565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061089d57503373ffffffffffffffffffffffffffffffffffffffff821614155b156108d4576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020526040812061090291613863565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610972573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061099691906145a4565b905090565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a0357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109d8575b505050505090506000815167ffffffffffffffff811115610a2657610a266139de565b604051908082528060200260200182016040528015610a5957816020015b6060815260200190600190039081610a445790505b50905060005b8251811015610bb8576000600d6000858481518110610a8057610a806145c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610acd906143e5565b80601f0160208091040260200160405190810160405280929190818152602001828054610af9906143e5565b8015610b465780601f10610b1b57610100808354040283529160200191610b46565b820191906000526020600020905b815481529060010190602001808311610b2957829003601f168201915b505050505090508051600003610b88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610b9b57610b9b6145c1565b60200260200101819052505080610bb19061461f565b9050610a5f565b5090939092509050565b610bca612a02565b806bffffffffffffffffffffffff16600003610c045750336000908152600a60205260409020546bffffffffffffffffffffffff16610c5e565b336000908152600a60205260409020546bffffffffffffffffffffffff80831691161015610c5e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600a602052604081208054839290610c8b9084906bffffffffffffffffffffffff16614657565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ce07f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610d5f57600080fd5b505af1158015610d73573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610e01576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610e856129fa565b610e8d612a02565b6000610e976110dc565b905060005b8151811015610fd157336000908152600a6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610f3857610f386145c1565b6020026020010151836040518363ffffffff1660e01b8152600401610f8d92919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610fa757600080fd5b505af1158015610fbb573d6000803e3d6000fd5b505050505080610fca9061461f565b9050610e9c565b5050565b610fdd612977565b6000819003611018576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c61063782848361447e565b60005473ffffffffffffffffffffffffffffffffffffffff16331480611070575061104f33612bad565b801561107057503373ffffffffffffffffffffffffffffffffffffffff8416145b6110a6576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d602052604090206110d682848361447e565b50505050565b6060600680548060200260200160405190810160405280929190818152602001828054801561114157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611116575b5050505050905090565b6060600e805461115a906143e5565b9050600003611195576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e80546111a2906143e5565b80601f01602080910402602001604051908101604052809291908181526020018280546111ce906143e5565b80156111415780601f106111f057610100808354040283529160200191611141565b820191906000526020600020905b8154815290600101906020018083116111fe57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461128d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600760205260409020546112a857506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906112eb9084815260200190565b60405180910390a15060015b919050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146113c4576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6113d56113d08361467c565b612c96565b90506113e76060830160408401613c0a565b815173ffffffffffffffffffffffffffffffffffffffff91909116907fbf50768ccf13bd0110ca6d53a9c4f1f3271abdd4c24a56878863ed25b20598ff3261143560c0870160a08801614769565b61144761016088016101408901613c0a565b6114518880614786565b6114636101208b016101008c016147eb565b60208b01356114796101008d0160e08e01614806565b8b60405161148f99989796959493929190614823565b60405180910390a3919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611583576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610df8565b6115918b8b8b8b8b8b6130a6565b60007f0000000000000000000000000000000000000000000000000000000000000000156115ee576002826020015183604001516115cf91906148cb565b6115d99190614913565b6115e49060016148cb565b60ff169050611604565b60208201516115fe9060016148cb565b60ff1690505b88811461166d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610df8565b8887146116d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610df8565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561171957611719614935565b600281111561172a5761172a614935565b905250905060028160200151600281111561174757611747614935565b14801561178e57506006816000015160ff1681548110611769576117696145c1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6117f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610df8565b505050505061180161389d565b6000808a8a604051611814929190614964565b60405190819003812061182b918e90602001614974565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b35576000600184898460208110611894576118946145c1565b6118a191901a601b6148cb565b8e8e868181106118b3576118b36145c1565b905060200201358d8d878181106118cc576118cc6145c1565b9050602002013560405160008152602001604052604051611909949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561192b573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119ab576119ab614935565b60028111156119bc576119bc614935565b90525092506001836020015160028111156119d9576119d9614935565b14611a40576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610df8565b8251600090879060ff16601f8110611a5a57611a5a6145c1565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611adc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610df8565b8086846000015160ff16601f8110611af657611af66145c1565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b216001866148cb565b94505080611b2e9061461f565b9050611875565b505050611b46833383858e8e61315d565b5050505050505050505050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bf357600080fd5b505afa158015611c07573d6000803e3d6000fd5b505050620f42408311159050611c49576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c53610905565b90506000611c9687878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061028692505050565b9050611ca48585838561332b565b925050505b95945050505050565b6060600c8054611cc1906143e5565b9050600003611cfc576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c80546111a2906143e5565b855185518560ff16601f831115611d7c576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610df8565b80600003611de6576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610df8565b818314611e74576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610df8565b611e7f816003614988565b8311611ee7576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610df8565b611eef612977565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f3690886133ee565b600554156120eb57600554600090611f509060019061499f565b9050600060058281548110611f6757611f676145c1565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fa157611fa16145c1565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090811690915592909116808452922080549091169055600580549192509080612021576120216149b2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061208a5761208a6149b2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f36915050565b60005b8151518110156125525760006004600084600001518481518110612114576121146145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215e5761215e614935565b146121c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610df8565b6040805180820190915260ff821681526001602082015282518051600491600091859081106121f6576121f66145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561229757612297614935565b0217905550600091506122a79050565b60046000846020015184815181106122c1576122c16145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230b5761230b614935565b14612372576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610df8565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123a5576123a56145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561244657612446614935565b021790555050825180516005925083908110612464576124646145c1565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124e0576124e06145c1565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061254a8161461f565b9150506120ee565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161260a918491740100000000000000000000000000000000000000009004166149e1565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126694630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613407565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612720988b9891977401000000000000000000000000000000000000000090920463ffffffff169690959194919391926149fe565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216848601526c010000000000000000000000008084048316606086015270010000000000000000000000000000000084048316608086015274010000000000000000000000000000000000000000840468ffffffffffffffffff1660a0808701919091527d01000000000000000000000000000000000000000000000000000000000090940461ffff1660c086015260095492831660e086015291047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16610100840152600b5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa15801561289a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128be9190614aae565b5093505092505080426128d1919061499f565b836020015163ffffffff161080156128f357506000836020015163ffffffff16115b1561292257505061010001517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16919050565b6000821361295f576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610df8565b5092915050565b61296e612977565b610902816134b2565b60005473ffffffffffffffffffffffffffffffffffffffff1633146129f8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610df8565b565b6129f8612977565b600b546bffffffffffffffffffffffff16600003612a1c57565b6000612a266110dc565b90508051600003612a63576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600b54600091612a82916bffffffffffffffffffffffff16614afe565b905060005b8251811015612b4e5781600a6000858481518110612aa757612aa76145c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612b0f9190614b29565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612b479061461f565b9050612a87565b508151612b5b9082614b4e565b600b8054600090612b7b9084906bffffffffffffffffffffffff16614657565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612c1357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612be8575b5050505050905060005b8151811015612c8c578373ffffffffffffffffffffffffffffffffffffffff16828281518110612c4f57612c4f6145c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612c7c575060019392505050565b612c858161461f565b9050612c1d565b5060009392505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff90811660c0840181905260095492831660e0850152939091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010080840191909152850151919291161115612e2b576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60085460009074010000000000000000000000000000000000000000900468ffffffffffffffffff1690506000612e6c8560e001513a84886080015161332b565b9050806bffffffffffffffffffffffff1685606001516bffffffffffffffffffffffff161015612ec8576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612f4b3087604001518860a001518960c001516001612ee99190614b76565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808281526020013073ffffffffffffffffffffffffffffffffffffffff168152602001836bffffffffffffffffffffffff168152602001876040015173ffffffffffffffffffffffffffffffffffffffff1681526020018760a0015167ffffffffffffffff1681526020018760e0015163ffffffff168152602001876080015168ffffffffffffffffff1681526020018468ffffffffffffffffff168152602001856040015163ffffffff1664ffffffffff168152602001856060015163ffffffff1664ffffffffff168152602001856080015163ffffffff164261303d9190614b97565b63ffffffff168152509450846040516020016130599190614011565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260079092529091205550919392505050565b60006130b3826020614988565b6130be856020614988565b6130ca88610144614b97565b6130d49190614b97565b6130de9190614b97565b6130e9906000614b97565b9050368114613154576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610df8565b50505050505050565b60608080808061316f86880188614c85565b845194995092975090955093509150158061318c57508351855114155b8061319957508251855114155b806131a657508151855114155b806131b357508051855114155b156131ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561331d57600061328287838151811061320d5761320d6145c1565b6020026020010151878481518110613227576132276145c1565b6020026020010151878581518110613241576132416145c1565b602002602001015187868151811061325b5761325b6145c1565b6020026020010151878781518110613275576132756145c1565b60200260200101516135a7565b9050600081600681111561329857613298614935565b14806132b5575060018160068111156132b3576132b3614935565b145b1561330c578682815181106132cc576132cc6145c1565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b506133168161461f565b90506131ed565b505050505050505050505050565b600854600090819086906133639063ffffffff6c010000000000000000000000008204811691680100000000000000009004166149e1565b61336d91906149e1565b60095463ffffffff91821692506000916127109161338c911688614988565b6133969190614d57565b6133a09087614b97565b905060006133ad82613837565b905060006133bb8483614988565b905060006133c98789614d6b565b68ffffffffffffffffff1690506133e08183614b97565b9a9950505050505050505050565b60006133f86110dc565b511115610fd157610fd1612a02565b6000808a8a8a8a8a8a8a8a8a60405160200161342b99989796959493929190614d8d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613531576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610df8565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906135be9190614e63565b9050806040516020016135d19190614011565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600790935291205414613623576006915050611ca9565b600087815260076020526040902054613640576002915050611ca9565b600061364b3a613837565b905060008261012001518361010001516136659190614f2b565b6136769064ffffffffff1683614988565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663330605298b8b878960e0015168ffffffffffffffffff16886136d59190614b29565b338b6040518763ffffffff1660e01b81526004016136f896959493929190614f49565b60408051808303816000875af1158015613716573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061373a9190614fc5565b9092509050600082600681111561375357613753614935565b14806137705750600182600681111561376e5761376e614935565b145b156138295760008b81526007602052604081205561378e8184614b29565b336000908152600a6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560e0870151600b805468ffffffffffffffffff909216939092916137fa91859116614b29565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613841612735565b61385383670de0b6b3a7640000614988565b61385d9190614d57565b92915050565b50805461386f906143e5565b6000825580601f1061387f575050565b601f01602090049060005260206000209081019061090291906138bc565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156138d157600081556001016138bd565b5090565b60008083601f8401126138e757600080fd5b50813567ffffffffffffffff8111156138ff57600080fd5b60208301915083602082850101111561391757600080fd5b9250929050565b6000806020838503121561393157600080fd5b823567ffffffffffffffff81111561394857600080fd5b613954858286016138d5565b90969095509350505050565b6000815180845260005b818110156139865760208185018101518683018201520161396a565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006139d76020830184613960565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610120810167ffffffffffffffff81118282101715613a3157613a316139de565b60405290565b604051610160810167ffffffffffffffff81118282101715613a3157613a316139de565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613aa257613aa26139de565b604052919050565b63ffffffff8116811461090257600080fd5b80356112f781613aaa565b68ffffffffffffffffff8116811461090257600080fd5b80356112f781613ac7565b803561ffff811681146112f757600080fd5b80357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff811681146112f757600080fd5b60006101208284031215613b3a57600080fd5b613b42613a0d565b613b4b83613abc565b8152613b5960208401613abc565b6020820152613b6a60408401613abc565b6040820152613b7b60608401613abc565b6060820152613b8c60808401613abc565b6080820152613b9d60a08401613ade565b60a0820152613bae60c08401613ae9565b60c0820152613bbf60e08401613abc565b60e0820152610100613bd2818501613afb565b908201529392505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461090257600080fd5b80356112f781613bdd565b600060208284031215613c1c57600080fd5b81356139d781613bdd565b600081518084526020808501945080840160005b83811015613c6d57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613c3b565b509495945050505050565b604081526000613c8b6040830185613c27565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613cf9577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613ce7838351613960565b94860194925090850190600101613cad565b50909998505050505050505050565b600082601f830112613d1957600080fd5b813567ffffffffffffffff811115613d3357613d336139de565b613d6460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613a5b565b818152846020838601011115613d7957600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613da857600080fd5b813567ffffffffffffffff811115613dbf57600080fd5b613dcb84828501613d08565b949350505050565b6bffffffffffffffffffffffff8116811461090257600080fd5b80356112f781613dd3565b60008060408385031215613e0b57600080fd5b8235613e1681613bdd565b91506020830135613e2681613dd3565b809150509250929050565b600080600060408486031215613e4657600080fd5b8335613e5181613bdd565b9250602084013567ffffffffffffffff811115613e6d57600080fd5b613e79868287016138d5565b9497909650939450505050565b6020815260006139d76020830184613c27565b600060208284031215613eab57600080fd5b5035919050565b600060208284031215613ec457600080fd5b813567ffffffffffffffff811115613edb57600080fd5b820161016081850312156139d757600080fd5b805182526020810151613f19602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151613f3960408401826bffffffffffffffffffffffff169052565b506060810151613f61606084018273ffffffffffffffffffffffffffffffffffffffff169052565b506080810151613f7d608084018267ffffffffffffffff169052565b5060a0810151613f9560a084018263ffffffff169052565b5060c0810151613fb260c084018268ffffffffffffffffff169052565b5060e0810151613fcf60e084018268ffffffffffffffffff169052565b506101008181015164ffffffffff81168483015250506101208181015164ffffffffff81168483015250506101408181015163ffffffff8116848301526110d6565b610160810161385d8284613eee565b60008083601f84011261403257600080fd5b50813567ffffffffffffffff81111561404a57600080fd5b6020830191508360208260051b850101111561391757600080fd5b60008060008060008060008060e0898b03121561408157600080fd5b606089018a81111561409257600080fd5b8998503567ffffffffffffffff808211156140ac57600080fd5b6140b88c838d016138d5565b909950975060808b01359150808211156140d157600080fd5b6140dd8c838d01614020565b909750955060a08b01359150808211156140f657600080fd5b506141038b828c01614020565b999c989b50969995989497949560c00135949350505050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161417c60a084018268ffffffffffffffffff169052565b5060c083015161419260c084018261ffff169052565b5060e08301516141aa60e084018263ffffffff169052565b50610100838101517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8116848301525b505092915050565b67ffffffffffffffff8116811461090257600080fd5b80356112f7816141de565b60008060008060006080868803121561421757600080fd5b8535614222816141de565b9450602086013567ffffffffffffffff81111561423e57600080fd5b61424a888289016138d5565b909550935050604086013561425e81613aaa565b949793965091946060013592915050565b600067ffffffffffffffff821115614289576142896139de565b5060051b60200190565b600082601f8301126142a457600080fd5b813560206142b96142b48361426f565b613a5b565b82815260059290921b840181019181810190868411156142d857600080fd5b8286015b848110156142fc5780356142ef81613bdd565b83529183019183016142dc565b509695505050505050565b803560ff811681146112f757600080fd5b60008060008060008060c0878903121561433157600080fd5b863567ffffffffffffffff8082111561434957600080fd5b6143558a838b01614293565b9750602089013591508082111561436b57600080fd5b6143778a838b01614293565b965061438560408a01614307565b9550606089013591508082111561439b57600080fd5b6143a78a838b01613d08565b94506143b560808a016141f4565b935060a08901359150808211156143cb57600080fd5b506143d889828a01613d08565b9150509295509295509295565b600181811c908216806143f957607f821691505b602082108103614432577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561063757600081815260208120601f850160051c8101602086101561445f5750805b601f850160051c820191505b81811015610d735782815560010161446b565b67ffffffffffffffff831115614496576144966139de565b6144aa836144a483546143e5565b83614438565b6000601f8411600181146144fc57600085156144c65750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614592565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561454b578685013582556020948501946001909201910161452b565b5086821015614586577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b80516112f781613ac7565b6000602082840312156145b657600080fd5b81516139d781613ac7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614650576146506145f0565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561295f5761295f6145f0565b6000610160823603121561468f57600080fd5b614697613a37565b823567ffffffffffffffff8111156146ae57600080fd5b6146ba36828601613d08565b825250602083013560208201526146d360408401613bff565b60408201526146e460608401613ded565b60608201526146f560808401613ade565b608082015261470660a084016141f4565b60a082015261471760c084016141f4565b60c082015261472860e08401613abc565b60e082015261010061473b818501613ae9565b9082015261012061474d8482016141f4565b9082015261014061475f848201613bff565b9082015292915050565b60006020828403121561477b57600080fd5b81356139d7816141de565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126147bb57600080fd5b83018035915067ffffffffffffffff8211156147d657600080fd5b60200191503681900382131561391757600080fd5b6000602082840312156147fd57600080fd5b6139d782613ae9565b60006020828403121561481857600080fd5b81356139d781613aaa565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a166020830152881660408201526102406060820181905281018690526000610260878982850137600083890182015261ffff8716608084015260a0830186905263ffffffff851660c0840152601f88017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01683010190506133e060e0830184613eee565b60ff818116838216019081111561385d5761385d6145f0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614926576149266148e4565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b808202811582820484141761385d5761385d6145f0565b8181038181111561385d5761385d6145f0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561295f5761295f6145f0565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614a2e8184018a613c27565b90508281036080840152614a428189613c27565b905060ff871660a084015282810360c0840152614a5f8187613960565b905067ffffffffffffffff851660e0840152828103610100840152614a848185613960565b9c9b505050505050505050505050565b805169ffffffffffffffffffff811681146112f757600080fd5b600080600080600060a08688031215614ac657600080fd5b614acf86614a94565b9450602086015193506040860151925060608601519150614af260808701614a94565b90509295509295909350565b60006bffffffffffffffffffffffff80841680614b1d57614b1d6148e4565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561295f5761295f6145f0565b6bffffffffffffffffffffffff8181168382160280821691908281146141d6576141d66145f0565b67ffffffffffffffff81811683821601908082111561295f5761295f6145f0565b8082018082111561385d5761385d6145f0565b600082601f830112614bbb57600080fd5b81356020614bcb6142b48361426f565b82815260059290921b84018101918181019086841115614bea57600080fd5b8286015b848110156142fc5780358352918301918301614bee565b600082601f830112614c1657600080fd5b81356020614c266142b48361426f565b82815260059290921b84018101918181019086841115614c4557600080fd5b8286015b848110156142fc57803567ffffffffffffffff811115614c695760008081fd5b614c778986838b0101613d08565b845250918301918301614c49565b600080600080600060a08688031215614c9d57600080fd5b853567ffffffffffffffff80821115614cb557600080fd5b614cc189838a01614baa565b96506020880135915080821115614cd757600080fd5b614ce389838a01614c05565b95506040880135915080821115614cf957600080fd5b614d0589838a01614c05565b94506060880135915080821115614d1b57600080fd5b614d2789838a01614c05565b93506080880135915080821115614d3d57600080fd5b50614d4a88828901614c05565b9150509295509295909350565b600082614d6657614d666148e4565b500490565b68ffffffffffffffffff81811683821601908082111561295f5761295f6145f0565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614dd48285018b613c27565b91508382036080850152614de8828a613c27565b915060ff881660a085015283820360c0850152614e058288613960565b90861660e08501528381036101008501529050614a848185613960565b80516112f781613bdd565b80516112f781613dd3565b80516112f7816141de565b80516112f781613aaa565b805164ffffffffff811681146112f757600080fd5b60006101608284031215614e7657600080fd5b614e7e613a37565b82518152614e8e60208401614e22565b6020820152614e9f60408401614e2d565b6040820152614eb060608401614e22565b6060820152614ec160808401614e38565b6080820152614ed260a08401614e43565b60a0820152614ee360c08401614599565b60c0820152614ef460e08401614599565b60e0820152610100614f07818501614e4e565b90820152610120614f19848201614e4e565b90820152610140613bd2848201614e43565b64ffffffffff81811683821601908082111561295f5761295f6145f0565b6000610200808352614f5d8184018a613960565b90508281036020840152614f718189613960565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150614fba905060a0830184613eee565b979650505050505050565b60008060408385031215614fd857600080fd5b825160078110614fe757600080fd5b6020840151909250613e2681613dd356fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI @@ -1754,7 +1741,7 @@ func (FunctionsCoordinatorConfigUpdated) Topic() common.Hash { } func (FunctionsCoordinatorOracleRequest) Topic() common.Hash { - return common.HexToHash("0x0d37aa165b7e8c3b3c70cce43049e46de14d9ea8eabe99c920ba4ab3f9afd99e") + return common.HexToHash("0xbf50768ccf13bd0110ca6d53a9c4f1f3271abdd4c24a56878863ed25b20598ff") } func (FunctionsCoordinatorOracleResponse) Topic() common.Hash { diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 995c2afcb8f..c92bbdfea57 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -31,17 +31,17 @@ var ( ) type FunctionsResponseCommitment struct { - AdminFee *big.Int + RequestId [32]byte Coordinator common.Address + EstimatedTotalCostJuels *big.Int Client common.Address SubscriptionId uint64 CallbackGasLimit uint32 - EstimatedTotalCostJuels *big.Int - TimeoutTimestamp uint32 - RequestId [32]byte + AdminFee *big.Int DonFee *big.Int GasOverheadBeforeCallback *big.Int GasOverheadAfterCallback *big.Int + TimeoutTimestamp uint32 } type FunctionsRouterConfig struct { @@ -68,8 +68,8 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"timelockEndBlock\",\"type\":\"uint256\"},{\"internalType\":\"bytes32[]\",\"name\":\"ids\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"to\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200601b3803806200601b8339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615968620006b3600039600081816113510152818161239101528181612c8001528181612d4401526131ee01526159686000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063a9c9a918116100e3578063cc77470a11610097578063e82ad7d411610071578063e82ad7d414610697578063ea320e0b146106aa578063f2fde38b146106bd57600080fd5b8063cc77470a1461065e578063d7ae1d3014610671578063e72f6e301461068457600080fd5b8063b734c0f4116100c8578063b734c0f41461062a578063badc3eb614610632578063c3f909d41461064957600080fd5b8063a9c9a9181461060f578063aab396bd1461062257600080fd5b806398e5cf721161013a578063a21a23e41161011f578063a21a23e4146105d4578063a47c7696146105dc578063a4c0ed36146105fc57600080fd5b806398e5cf72146105ae5780639f87fad7146105c157600080fd5b8063823597401161016b57806382359740146105705780638456cb59146105835780638da5cb5b1461058b57600080fd5b80637341c10c1461055557806379ba50971461056857600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461051d57600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b8063181f5a771161029657806321b60e7f1161027b57806321b60e7f146103c85780632a905ccc146103db5780633e871e4d1461040957600080fd5b8063181f5a771461036c5780631ded3b36146103b557600080fd5b80630fb25853116102c75780630fb258531461031857806310fc49c11461033957806312b583491461034c57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614628565b6106d0565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b61032b610326366004614928565b61072f565b60405161030f929190614a10565b6102f6610347366004614a39565b610b35565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103a86040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614ae0565b6102f66103c3366004614af3565b610c31565b6102f66103d6366004614bc9565b610c63565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6102f6610417366004614d07565b610d90565b6102f6611015565b610437610432366004614e09565b611027565b60405190815260200161030f565b610437610453366004614e09565b611087565b6102f6610466366004614e8d565b611093565b610437610479366004614628565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be366004614ebb565b6111e1565b6102f66104d1366004614ebb565b61139a565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004614ee9565b611483565b60405161030f9190614f17565b61053061052b366004614f4b565b611513565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f6610563366004614e8d565b6115d2565b6102f6611786565b6102f661057e366004614628565b6118ad565b6102f66119f4565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610530565b6102f66105bc366004614f64565b611a04565b6102f66105cf366004614e8d565b611cda565b6104e46120af565b6105ef6105ea366004614628565b61223c565b60405161030f91906150aa565b6102f661060a3660046150bd565b612371565b61053061061d366004614f4b565b6125bd565b600954610437565b6102f661261c565b61063a612768565b60405161030f93929190615119565b61065161282f565b60405161030f919061516e565b6104e461066c366004615218565b612964565b6102f661067f366004614e8d565b612be4565b6102f6610692366004615218565b612c47565b6104a06106a5366004614628565b612dc0565b6102f66106b8366004614f4b565b612f0f565b6102f66106cb366004615218565b612f1c565b6106d8612f2d565b6106e181612f35565b67ffffffffffffffff811660009081526003602052604090205461072c9082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612fab565b50565b60008061073a613297565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146107a3576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60e083015160009081526005602052604090205461080b57600291508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516107fb93929190615235565b60405180910390a2506000610b2a565b600560008460e00151815260200190815260200160002054836040516020016108349190615267565b604051602081830303815290604052805190602001201461088f57600691508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516107fb93929190615235565b826101400151836080015163ffffffff166108aa91906153c0565b64ffffffffff165a10156108f857600491508260e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1846020015186856040516107fb93929190615235565b600061090d846080015163ffffffff1661329f565b61091790886153e5565b905060008187866000015168ffffffffffffffffff16610937919061540d565b610941919061540d565b9050610950856060015161223c565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff1611156109cb57600593508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516109b793929190615235565b60405180910390a25060009150610b2a9050565b8460a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610a3357600393508460e001517f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee1866020015188876040516109b793929190615235565b5050600560008460e001518152602001908152602001600020600090556000610a6b8460e001518a8a87608001518860400151613341565b8051909150610a7b576001610a7e565b60005b92506000610ab885606001518660a001518760400151886000015168ffffffffffffffffff168c610ab2886020015161329f565b8d6134ce565b9050846060015167ffffffffffffffff168560e001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610b05578e610b07565b8f5b8860400151604051610b1d959493929190615432565b60405180910390a3519150505b965096945050505050565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a908110610b9a576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff1681548110610bb557610bb5615494565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff161115610c2b576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff82166004820152602401610b91565b50505050565b610c39612f2d565b610c4282612f35565b67ffffffffffffffff90911660009081526003602081905260409091200155565b610c6b613717565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff00000000000000000000009096169190971617939093171693909317178155608083015180518493610d5292600b92910190614473565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c81604051610d85919061516e565b60405180910390a150565b610d98613717565b8151815181141580610daa5750600881115b15610de1576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ed3576000848281518110610e0057610e00615494565b602002602001015190506000848381518110610e1e57610e1e615494565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e89575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec0576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ecc906154c3565b9050610de4565b506040805180820190915283815260208082018490528451600c91610efc91839188019061451e565b506020828101518051610f159260018501920190614559565b5090505060005b8351811015610c2b577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f5857610f58615494565b602002602001015160086000878581518110610f7657610f76615494565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fbf57610fbf615494565b6020026020010151604051610ffd9392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a161100e816154c3565b9050610f1c565b61101d613717565b61102561379d565b565b60008061103383611513565b905061107b83828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b915061381a9050565b98975050505050505050565b600080611033836125bd565b61109b613297565b6110a482613b7c565b6110ac613c42565b73ffffffffffffffffffffffffffffffffffffffff81161580611113575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b1561114a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111e9612f2d565b806bffffffffffffffffffffffff1660000361121f5750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff90811690821681101561128b576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff82166004820152602401610b91565b30600090815260016020526040812080548492906112b89084906bffffffffffffffffffffffff166154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff1661130e91906154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061139583836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613d4c9092919063ffffffff16565b505050565b6113a2613297565b806bffffffffffffffffffffffff166000036113ea576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611456576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff82166004820152602401610b91565b33600090815260016020526040812080548492906112b89084906bffffffffffffffffffffffff166154fb565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561159c57600c805460ff831690811061153b5761153b615494565b9060005260206000200154830361158c57600d805460ff831690811061156357611563615494565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61159581615520565b9050611517565b506040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101839052602401610b91565b6115da613297565b6115e382613b7c565b6115eb613c42565b60006115fa600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff8216900361165d576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff82166004820152602401610b91565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff16156116a557505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff163314611807576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610b91565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118b5613297565b6118bd613c42565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c01000000000000000000000000928390048116929091041633811461195d576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82166004820152602401610b91565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611779565b6119fc613717565b611025613dd9565b611a0c613297565b60005b81811015611395576000838383818110611a2b57611a2b615494565b90506101600201803603810190611a42919061553f565b905060008160e001519050600082606001519050600560008381526020019081526020016000205483604051602001611a7b9190615267565b6040516020818303038152906040528051906020012014611ac8576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8260c0015163ffffffff16421015611b0c576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015611b7f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611ba3919061555c565b5060a083015167ffffffffffffffff821660009081526003602052604081206001018054909190611be39084906bffffffffffffffffffffffff166154fb565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555060408084015173ffffffffffffffffffffffffffffffffffffffff1660009081526004602090815282822067ffffffffffffffff808616845291529190208054600192600991611c6a918591690100000000000000000090041661557e565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080611cd3906154c3565b9050611a0f565b611ce2613297565b611ceb82613b7c565b611cf3613c42565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611d9b576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611df0576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611e6b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611e40575b5050505050905060005b8151811015612013578373ffffffffffffffffffffffffffffffffffffffff16828281518110611ea757611ea7615494565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612003578160018351611ed9919061559f565b81518110611ee957611ee9615494565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611f2c57611f2c615494565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611fa657611fa66155b2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055612013565b61200c816154c3565b9050611e75565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b60006120b9613297565b6120c1613c42565b600280546000906120db9067ffffffffffffffff166155e1565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612151578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926121ec92600285019290910190614559565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261227682612f35565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561235757602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161232c575b505050505081526020016003820154815250509050919050565b612379613297565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146123e8576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612422576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061243082840184614628565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166124a9576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906124e0838561540d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff16612536919061540d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461259d9190615608565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff168061150d576040517f80833e3300000000000000000000000000000000000000000000000000000000815260048101849052602401610b91565b612624613717565b60005b600c54811015612747576000600c600001828154811061264957612649615494565b906000526020600020015490506000600c600101838154811061266e5761266e615494565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612740816154c3565b9050612627565b50600c600061275682826145d3565b6127646001830160006145d3565b5050565b600c80546040805160208084028201810190925282815260009360609384938301828280156127b657602002820191906000526020600020905b8154815260200190600101908083116127a2575b50505050509150600c60010180548060200260200160405190810160405280929190818152602001828054801561282357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116127f8575b50505050509050909192565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561295657602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116129195790505b505050505081525050905090565b600061296e613297565b612976613c42565b600280546000906129909067ffffffffffffffff166155e1565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612a06578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192612aa192600285019290910190614559565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b612bec613297565b612bf582613b7c565b612bfd613c42565b612c0682612dc0565b15612c3d576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6127648282612fab565b612c4f612f2d565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612cdc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d00919061561b565b6000549091506bffffffffffffffffffffffff1681811015611395576000612d28828461559f565b9050612d6b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613d4c565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612e3857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e0d575b5050505050905060005b8151811015612f0557600060046000848481518110612e6357612e63615494565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612ef457506001949350505050565b50612efe816154c3565b9050612e42565b5060009392505050565b612f17613717565b600955565b612f24613717565b61072c81613e34565b611025613717565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661072c576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561308c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613061575b505050918352505060039190910154602090910152805190915060005b82608001515181101561314d5760046000846080015183815181106130d0576130d0615494565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613146816154c3565b90506130a9565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061317f60028301826145d3565b506000600391909101819055805482919081906131ab9084906bffffffffffffffffffffffff166154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061323283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613d4c9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd4981591016120a1565b611025613f30565b60006bffffffffffffffffffffffff82111561333d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610b91565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b9061338b90899089908990602401615634565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b61345657600080fd5b5a8481101561346457600080fd5b849003604081048103891061347857600080fd5b60008087516020890160008c8ef193505a900391503d608481111561349b575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b604080518082019091526000808252602082015260006134ee84866153e5565b90506000816134fd888661540d565b613507919061540d565b6040805180820182526bffffffffffffffffffffffff808616825280841660208084019190915267ffffffffffffffff8f166000908152600390915292832080549297509394508493929161355e918591166154fb565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d945090926135b2918591166154fb565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846135ec919061540d565b33600090815260016020526040812080549091906136199084906bffffffffffffffffffffffff1661540d565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926136609185911661540d565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f168552925290912080546001926009916136e4918591690100000000000000000090041661557e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505050979650505050505050565b600654610100900473ffffffffffffffffffffffffffffffffffffffff163314611025576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610b91565b6137a5613f9d565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613824613297565b61382d85612f35565b6138373386614009565b6138418583610b35565b835160000361387b576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006138868661223c565b905060008773ffffffffffffffffffffffffffffffffffffffff166362fdb9916040518061012001604052803373ffffffffffffffffffffffffffffffffffffffff1681526020018981526020018a67ffffffffffffffff1681526020018861ffff1681526020016139128b67ffffffffffffffff166000908152600360208190526040909120015490565b815263ffffffff88166020820152600a5462010000900468ffffffffffffffffff166040820152606001613946338c611483565b8152602001858152506040518263ffffffff1660e01b815260040161396b9190615669565b610160604051808303816000875af115801561398b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139af91906157c5565b9050604051806101600160405280600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018973ffffffffffffffffffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018867ffffffffffffffff1681526020018563ffffffff1681526020018260a001516bffffffffffffffffffffffff1681526020018260c0015163ffffffff1681526020018260e00151815260200182610100015168ffffffffffffffffff16815260200182610120015164ffffffffff16815260200182610140015164ffffffffff16815250604051602001613ab69190615267565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060e08401516000908152600590935291205560a0810151613b10903390899061407d565b8667ffffffffffffffff16898260e001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9856020015133328c8c8c8a60a00151604051613b649796959493929190615898565b60405180910390a460e0015198975050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613bf3576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612764576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613c725750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613cd390339060248101615910565b602060405180830381865afa158015613cf0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d14919061555c565b61072c576040517f22906263000000000000000000000000000000000000000000000000000000008152336004820152602401610b91565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb00000000000000000000000000000000000000000000000000000000179052611395908490614158565b613de1613f30565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586137f03390565b3373ffffffffffffffffffffffffffffffffffffffff821603613eb3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610b91565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff1615611025576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a20706175736564000000000000000000000000000000006044820152606401610b91565b60065460ff16611025576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f74207061757365640000000000000000000000006044820152606401610b91565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612764576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906140b79084906bffffffffffffffffffffffff1661540d565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261412d92849290041661557e565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b60006141ba826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166142649092919063ffffffff16565b80519091501561139557808060200190518101906141d8919061555c565b611395576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f742073756363656564000000000000000000000000000000000000000000006064820152608401610b91565b6060614273848460008561427b565b949350505050565b60608247101561430d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c00000000000000000000000000000000000000000000000000006064820152608401610b91565b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051614336919061593f565b60006040518083038185875af1925050503d8060008114614373576040519150601f19603f3d011682016040523d82523d6000602084013e614378565b606091505b509150915061438987838387614394565b979650505050505050565b6060831561442a5782516000036144235773ffffffffffffffffffffffffffffffffffffffff85163b614423576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e74726163740000006044820152606401610b91565b5081614273565b614273838381511561443f5781518083602001fd5b806040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610b919190614ae0565b828054828255906000526020600020906007016008900481019282156145125791602002820160005b838211156144e057835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030261449c565b80156145105782816101000a81549063ffffffff02191690556004016020816003010492830192600103026144e0565b505b5061333d9291506145ed565b828054828255906000526020600020908101928215614512579160200282015b8281111561451257825182559160200191906001019061453e565b828054828255906000526020600020908101928215614512579160200282015b8281111561451257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190614579565b508054600082559060005260206000209081019061072c91905b5b8082111561333d57600081556001016145ee565b67ffffffffffffffff8116811461072c57600080fd5b803561462381614602565b919050565b60006020828403121561463a57600080fd5b813561464581614602565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610160810167ffffffffffffffff8111828210171561469f5761469f61464c565b60405290565b60405160a0810167ffffffffffffffff8111828210171561469f5761469f61464c565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561470f5761470f61464c565b604052919050565b600082601f83011261472857600080fd5b813567ffffffffffffffff8111156147425761474261464c565b61477360207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016146c8565b81815284602083860101111561478857600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461072c57600080fd5b8035614623816147a5565b73ffffffffffffffffffffffffffffffffffffffff8116811461072c57600080fd5b8035614623816147ca565b68ffffffffffffffffff8116811461072c57600080fd5b8035614623816147f7565b63ffffffff8116811461072c57600080fd5b803561462381614819565b64ffffffffff8116811461072c57600080fd5b803561462381614836565b6000610160828403121561486757600080fd5b61486f61467b565b905061487a8261480e565b8152614888602083016147ec565b6020820152614899604083016147ec565b60408201526148aa60608301614618565b60608201526148bb6080830161482b565b60808201526148cc60a083016147bf565b60a08201526148dd60c0830161482b565b60c082015260e082013560e08201526101006148fa81840161480e565b9082015261012061490c838201614849565b9082015261014061491e838201614849565b9082015292915050565b600080600080600080610200878903121561494257600080fd5b863567ffffffffffffffff8082111561495a57600080fd5b6149668a838b01614717565b9750602089013591508082111561497c57600080fd5b5061498989828a01614717565b955050604087013561499a816147a5565b935060608701356149aa816147a5565b925060808701356149ba816147ca565b91506149c98860a08901614854565b90509295509295509295565b60078110614a0c577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614a1e82856149d5565b6bffffffffffffffffffffffff831660208301529392505050565b60008060408385031215614a4c57600080fd5b8235614a5781614602565b91506020830135614a6781614819565b809150509250929050565b60005b83811015614a8d578181015183820152602001614a75565b50506000910152565b60008151808452614aae816020860160208601614a72565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006146456020830184614a96565b60008060408385031215614b0657600080fd5b8235614b1181614602565b946020939093013593505050565b803561ffff8116811461462357600080fd5b600067ffffffffffffffff821115614b4b57614b4b61464c565b5060051b60200190565b600082601f830112614b6657600080fd5b81356020614b7b614b7683614b31565b6146c8565b82815260059290921b84018101918181019086841115614b9a57600080fd5b8286015b84811015614bbe578035614bb181614819565b8352918301918301614b9e565b509695505050505050565b600060208284031215614bdb57600080fd5b813567ffffffffffffffff80821115614bf357600080fd5b9083019060a08286031215614c0757600080fd5b614c0f6146a5565b614c1883614b1f565b81526020830135614c28816147f7565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614c6057600080fd5b6040820152614c7160608401614b1f565b6060820152608083013582811115614c8857600080fd5b614c9487828601614b55565b60808301525095945050505050565b600082601f830112614cb457600080fd5b81356020614cc4614b7683614b31565b82815260059290921b84018101918181019086841115614ce357600080fd5b8286015b84811015614bbe578035614cfa816147ca565b8352918301918301614ce7565b60008060408385031215614d1a57600080fd5b823567ffffffffffffffff80821115614d3257600080fd5b818501915085601f830112614d4657600080fd5b81356020614d56614b7683614b31565b82815260059290921b84018101918181019089841115614d7557600080fd5b948201945b83861015614d9357853582529482019490820190614d7a565b96505086013592505080821115614da957600080fd5b50614db685828601614ca3565b9150509250929050565b60008083601f840112614dd257600080fd5b50813567ffffffffffffffff811115614dea57600080fd5b602083019150836020828501011115614e0257600080fd5b9250929050565b60008060008060008060a08789031215614e2257600080fd5b8635614e2d81614602565b9550602087013567ffffffffffffffff811115614e4957600080fd5b614e5589828a01614dc0565b9096509450614e68905060408801614b1f565b92506060870135614e7881614819565b80925050608087013590509295509295509295565b60008060408385031215614ea057600080fd5b8235614eab81614602565b91506020830135614a67816147ca565b60008060408385031215614ece57600080fd5b8235614ed9816147ca565b91506020830135614a67816147a5565b60008060408385031215614efc57600080fd5b8235614f07816147ca565b91506020830135614a6781614602565b6060810161150d828480511515825260208082015167ffffffffffffffff9081169184019190915260409182015116910152565b600060208284031215614f5d57600080fd5b5035919050565b60008060208385031215614f7757600080fd5b823567ffffffffffffffff80821115614f8f57600080fd5b818501915085601f830112614fa357600080fd5b813581811115614fb257600080fd5b86602061016083028501011115614fc857600080fd5b60209290920196919550909350505050565b600081518084526020808501945080840160005b8381101561502057815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614fee565b509495945050505050565b60006bffffffffffffffffffffffff808351168452602083015173ffffffffffffffffffffffffffffffffffffffff8082166020870152826040860151166040870152806060860151166060870152505050608082015160c0608085015261509660c0850182614fda565b60a093840151949093019390935250919050565b602081526000614645602083018461502b565b600080600080606085870312156150d357600080fd5b84356150de816147ca565b935060208501359250604085013567ffffffffffffffff81111561510157600080fd5b61510d87828801614dc0565b95989497509550505050565b6000606082018583526020606081850152818651808452608086019150828801935060005b8181101561515a5784518352938301939183019160010161513e565b5050848103604086015261107b8187614fda565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614bbe57835163ffffffff1682529284019260019290920191908401906151f2565b60006020828403121561522a57600080fd5b8135614645816147ca565b73ffffffffffffffffffffffffffffffffffffffff8481168252831660208201526060810161427360408301846149d5565b815168ffffffffffffffffff168152610160810160208301516152a2602084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516152ca604084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608301516152e6606084018267ffffffffffffffff169052565b5060808301516152fe608084018263ffffffff169052565b5060a083015161531e60a08401826bffffffffffffffffffffffff169052565b5060c083015161533660c084018263ffffffff169052565b5060e083015160e08301526101008084015161535e8285018268ffffffffffffffffff169052565b50506101208381015164ffffffffff81168483015250506101408381015164ffffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff8181168382160190808211156153de576153de615391565b5092915050565b6bffffffffffffffffffffffff81811683821602808216919082811461538957615389615391565b6bffffffffffffffffffffffff8181168382160190808211156153de576153de615391565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff8516602082015261546c60408201856149d5565b60a06060820152600061548260a0830185614a96565b828103608084015261107b8185614a96565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036154f4576154f4615391565b5060010190565b6bffffffffffffffffffffffff8281168282160390808211156153de576153de615391565b600060ff821660ff810361553657615536615391565b60010192915050565b6000610160828403121561555257600080fd5b6146458383614854565b60006020828403121561556e57600080fd5b8151801515811461464557600080fd5b67ffffffffffffffff8181168382160190808211156153de576153de615391565b8181038181111561150d5761150d615391565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036155fe576155fe615391565b6001019392505050565b8082018082111561150d5761150d615391565b60006020828403121561562d57600080fd5b5051919050565b83815260606020820152600061564d6060830185614a96565b828103604084015261565f8185614a96565b9695505050505050565b6020815261569060208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516101608060408501526156ae610180850183614a96565b915060408501516156cb606086018267ffffffffffffffff169052565b50606085015161ffff8116608086015250608085015160a085015260a08501516156fd60c086018263ffffffff169052565b5060c085015168ffffffffffffffffff811660e08601525060e08501518051151561010086810191909152602082015167ffffffffffffffff9081166101208801526040830151166101408701528601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00183870152905061565f838261502b565b8051614623816147f7565b8051614623816147ca565b805161462381614602565b805161462381614819565b8051614623816147a5565b805161462381614836565b600061016082840312156157d857600080fd5b6157e061467b565b6157e983615783565b81526157f76020840161578e565b60208201526158086040840161578e565b604082015261581960608401615799565b606082015261582a608084016157a4565b608082015261583b60a084016157af565b60a082015261584c60c084016157a4565b60c082015260e083015160e0820152610100615869818501615783565b9082015261012061587b8482016157ba565b9082015261014061588d8482016157ba565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e060608301526158d960e0830187614a96565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006142736040830184614a96565b60008251615951818460208701614a72565b919091019291505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200604c3803806200604c8339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615999620006b360003960008181611359015281816120c3015281816129bb01528181612a7f01526131fa01526159996000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614693565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046146d4565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f919061477b565b6102f66103a236600461478e565b610853565b6102f66103b5366004614951565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614bfd565b6109b2565b60405161030f929190614ce5565b6102f6610417366004614d72565b610d98565b6102f661101d565b610437610432366004614e74565b61102f565b60405190815260200161030f565b610437610453366004614e74565b61108f565b6102f6610466366004614ef8565b61109b565b610437610479366004614693565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be366004614f26565b6111e9565b6102f66104d1366004614f26565b6113a2565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004614f54565b61148b565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004614f82565b61151b565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c366004614ef8565b6115da565b6102f661178e565b6102f66105a7366004614693565b6118b5565b6102f66119fc565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e5366004614ef8565b611a0c565b6104e4611de1565b610605610600366004614693565b611f6e565b60405161030f9190614fec565b6102f6610620366004615074565b6120a3565b610559610633366004614f82565b6122ef565b600954610437565b6102f661234e565b61065061249a565b60405161030f9291906150d0565b61066661256a565b60405161030f9190615127565b6104e46106813660046151d1565b61269f565b6102f6610694366004614ef8565b61291f565b6102f66106a73660046151d1565b612982565b6102f66106ba3660046151ee565b612afb565b6104a06106cd366004614693565b612dcc565b6102f66106e0366004614f82565b612f1b565b6102f66106f33660046151d1565b612f28565b610700612f39565b61070981612f41565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612fb7565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d7615264565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b612f39565b61086482612f41565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d6132a3565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906144de565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a79190615127565b60405180910390a150565b6000806109bd613329565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615293565b60405180910390a2506000610d8d565b8251600090815260056020908152604091829020549151610aab918691016152c5565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615293565b8261012001518360a0015163ffffffff16610b1e9190615421565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615293565b6000610b7e8460a0015163ffffffff16613331565b610b889088615446565b9050600081878660c0015168ffffffffffffffffff16610ba8919061546e565b610bb2919061546e565b9050610bc18560800151611f6e565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615293565b60405180910390a25060009150610d8d9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615293565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c91906133d3565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d158860200151613331565b8d613560565b9050846080015167ffffffffffffffff1685600001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610d68578e610d6a565b8f5b8860400151604051610d80959493929190615493565b60405180910390a3519150505b965096945050505050565b610da06132a3565b8151815181141580610db25750600881115b15610de9576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610edb576000848281518110610e0857610e08615264565b602002602001015190506000848381518110610e2657610e26615264565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e91575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec8576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ed4906154f5565b9050610dec565b506040805180820190915283815260208082018490528451600c91610f04918391880190614589565b506020828101518051610f1d92600185019201906145c4565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f6057610f60615264565b602002602001015160086000878581518110610f7e57610f7e615264565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fc757610fc7615264565b60200260200101516040516110059392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611016816154f5565b9050610f24565b6110256132a3565b61102d6137c1565b565b60008061103b8361151b565b905061108383828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b915061383e9050565b98975050505050505050565b60008061103b836122ef565b6110a3613329565b6110ac82613be7565b6110b4613cad565b73ffffffffffffffffffffffffffffffffffffffff8116158061111b575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611152576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111f1612f39565b806bffffffffffffffffffffffff166000036112275750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611293576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b30600090815260016020526040812080548492906112c09084906bffffffffffffffffffffffff1661552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff16611316919061552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061139d83836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613db79092919063ffffffff16565b505050565b6113aa613329565b806bffffffffffffffffffffffff166000036113f2576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff90811690821681101561145e576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b33600090815260016020526040812080548492906112c09084906bffffffffffffffffffffffff1661552d565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff821610156115a457600c805460ff831690811061154357611543615264565b9060005260206000200154830361159457600d805460ff831690811061156b5761156b615264565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61159d81615552565b905061151f565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6115e2613329565b6115eb82613be7565b6115f3613cad565b6000611602600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611665576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff16156116ad57505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff16331461180f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118bd613329565b6118c5613cad565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611965576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611781565b611a046132a3565b61102d613e44565b611a14613329565b611a1d82613be7565b611a25613cad565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611acd576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611b22576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611b9d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611b72575b5050505050905060005b8151811015611d45578373ffffffffffffffffffffffffffffffffffffffff16828281518110611bd957611bd9615264565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611d35578160018351611c0b9190615571565b81518110611c1b57611c1b615264565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611c5e57611c5e615264565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611cd857611cd8615584565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611d45565b611d3e816154f5565b9050611ba7565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611deb613329565b611df3613cad565b60028054600090611e0d9067ffffffffffffffff166155b3565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611e83578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611f1e926002850192909101906145c4565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a0810191909152611fa882612f41565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561208957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161205e575b505050505081526020016003820154815250509050919050565b6120ab613329565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461211a576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612154576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061216282840184614693565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166121db576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff1691869190612212838561546e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff16612268919061546e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846122cf91906155da565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff1680611515576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b6123566132a3565b60005b600c54811015612479576000600c600001828154811061237b5761237b615264565b906000526020600020015490506000600c60010183815481106123a0576123a0615264565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612472816154f5565b9050612359565b50600c6000612488828261463e565b61249660018301600061463e565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156124f257602002820191906000526020600020905b8154815260200190600101908083116124de575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561255b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612530575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561269157602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116126545790505b505050505081525050905090565b60006126a9613329565b6126b1613cad565b600280546000906126cb9067ffffffffffffffff166155b3565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612741578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926127dc926002850192909101906145c4565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b612927613329565b61293082613be7565b612938613cad565b61294182612dcc565b15612978576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6124968282612fb7565b61298a612f39565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612a17573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a3b91906155ed565b6000549091506bffffffffffffffffffffffff168181101561139d576000612a638284615571565b9050612aa673ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613db7565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612b03613329565b60005b8181101561139d576000838383818110612b2257612b22615264565b90506101600201803603810190612b399190615606565b80516080820151600082815260056020908152604091829020549151949550929391929091612b6a918691016152c5565b6040516020818303038152906040528051906020012014612bb7576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612bfc576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612c6f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c939190615623565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612cd49084906bffffffffffffffffffffffff1661552d565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612d5c9185916901000000000000000000900416615645565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612dc5906154f5565b9050612b06565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612e4457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e19575b5050505050905060005b8151811015612f1157600060046000848481518110612e6f57612e6f615264565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612f0057506001949350505050565b50612f0a816154f5565b9050612e4e565b5060009392505050565b612f236132a3565b600955565b612f306132a3565b61075481613e9f565b61102d6132a3565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561309857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161306d575b505050918352505060039190910154602090910152805190915060005b8260800151518110156131595760046000846080015183815181106130dc576130dc615264565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613152816154f5565b90506130b5565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061318b600283018261463e565b506000600391909101819055805482919081906131b79084906bffffffffffffffffffffffff1661552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061323e83826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613db79092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611dd3565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61102d613f9b565b60006bffffffffffffffffffffffff8211156133cf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b9061341d90899089908990602401615666565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6134e857600080fd5b5a848110156134f657600080fd5b849003604081048103891061350a57600080fd5b60008087516020890160008c8ef193505a900391503d608481111561352d575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b604080518082019091526000808252602082015260006135808486615446565b905060008161358f888661546e565b613599919061546e565b67ffffffffffffffff8b166000908152600360205260408120805492935083929091906135d59084906bffffffffffffffffffffffff1661552d565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d945090926136299185911661552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613663919061546e565b33600090815260016020526040812080549091906136909084906bffffffffffffffffffffffff1661546e565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926136d79185911661546e565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161375b9185916901000000000000000000900416615645565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6137c9614008565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613848613329565b61385185612f41565b61385b3386614074565b6138658583610757565b835160000361389f576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006138aa86611f6e565b905060006138b8338861148b565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a815260200161390e8c67ffffffffffffffff166000908152600360208190526040909120015490565b81523360208201526040878101518851919092019161392c9161552d565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b81526004016139f29190615691565b610160604051808303816000875af1158015613a12573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3691906157f6565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613b3d91906152c5565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613b7d338983604001516140e8565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613bd197969594939291906158c9565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613c5e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612496576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613cdd5750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613d3e90339060248101615941565b602060405180830381865afa158015613d5b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d7f9190615623565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb0000000000000000000000000000000000000000000000000000000017905261139d9084906141c3565b613e4c613f9b565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138143390565b3373ffffffffffffffffffffffffffffffffffffffff821603613f1e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612496576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906141229084906bffffffffffffffffffffffff1661546e565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614198928492900416615645565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b6000614225826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166142cf9092919063ffffffff16565b80519091501561139d57808060200190518101906142439190615623565b61139d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606142de84846000856142e6565b949350505050565b606082471015614378576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516143a19190615970565b60006040518083038185875af1925050503d80600081146143de576040519150601f19603f3d011682016040523d82523d6000602084013e6143e3565b606091505b50915091506143f4878383876143ff565b979650505050505050565b6060831561449557825160000361448e5773ffffffffffffffffffffffffffffffffffffffff85163b61448e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816142de565b6142de83838151156144aa5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b3919061477b565b8280548282559060005260206000209060070160089004810192821561457d5791602002820160005b8382111561454b57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614507565b801561457b5782816101000a81549063ffffffff021916905560040160208160030104928301926001030261454b565b505b506133cf929150614658565b82805482825590600052602060002090810192821561457d579160200282015b8281111561457d5782518255916020019190600101906145a9565b82805482825590600052602060002090810192821561457d579160200282015b8281111561457d57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906145e4565b508054600082559060005260206000209081019061075491905b5b808211156133cf5760008155600101614659565b67ffffffffffffffff8116811461075457600080fd5b803561468e8161466d565b919050565b6000602082840312156146a557600080fd5b81356146b08161466d565b9392505050565b63ffffffff8116811461075457600080fd5b803561468e816146b7565b600080604083850312156146e757600080fd5b82356146f28161466d565b91506020830135614702816146b7565b809150509250929050565b60005b83811015614728578181015183820152602001614710565b50506000910152565b6000815180845261474981602086016020860161470d565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006146b06020830184614731565b600080604083850312156147a157600080fd5b82356147ac8161466d565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff8111828210171561480c5761480c6147ba565b60405290565b604051610160810167ffffffffffffffff8111828210171561480c5761480c6147ba565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561487d5761487d6147ba565b604052919050565b803561ffff8116811461468e57600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561468e81614897565b600067ffffffffffffffff8211156148d3576148d36147ba565b5060051b60200190565b600082601f8301126148ee57600080fd5b813560206149036148fe836148b9565b614836565b82815260059290921b8401810191818101908684111561492257600080fd5b8286015b84811015614946578035614939816146b7565b8352918301918301614926565b509695505050505050565b60006020828403121561496357600080fd5b813567ffffffffffffffff8082111561497b57600080fd5b9083019060a0828603121561498f57600080fd5b6149976147e9565b6149a083614885565b815260208301356149b081614897565b602082015260408301357fffffffff00000000000000000000000000000000000000000000000000000000811681146149e857600080fd5b60408201526149f960608401614885565b6060820152608083013582811115614a1057600080fd5b614a1c878286016148dd565b60808301525095945050505050565b600082601f830112614a3c57600080fd5b813567ffffffffffffffff811115614a5657614a566147ba565b614a8760207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614836565b818152846020838601011115614a9c57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561468e81614ab9565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561468e81614ade565b64ffffffffff8116811461075457600080fd5b803561468e81614b0b565b60006101608284031215614b3c57600080fd5b614b44614812565b905081358152614b5660208301614b00565b6020820152614b6760408301614ad3565b6040820152614b7860608301614b00565b6060820152614b8960808301614683565b6080820152614b9a60a083016146c9565b60a0820152614bab60c083016148ae565b60c0820152614bbc60e083016148ae565b60e0820152610100614bcf818401614b1e565b90820152610120614be1838201614b1e565b90820152610140614bf38382016146c9565b9082015292915050565b6000806000806000806102008789031215614c1757600080fd5b863567ffffffffffffffff80821115614c2f57600080fd5b614c3b8a838b01614a2b565b97506020890135915080821115614c5157600080fd5b50614c5e89828a01614a2b565b9550506040870135614c6f81614ab9565b93506060870135614c7f81614ab9565b92506080870135614c8f81614ade565b9150614c9e8860a08901614b29565b90509295509295509295565b60078110614ce1577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614cf38285614caa565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614d1f57600080fd5b81356020614d2f6148fe836148b9565b82815260059290921b84018101918181019086841115614d4e57600080fd5b8286015b84811015614946578035614d6581614ade565b8352918301918301614d52565b60008060408385031215614d8557600080fd5b823567ffffffffffffffff80821115614d9d57600080fd5b818501915085601f830112614db157600080fd5b81356020614dc16148fe836148b9565b82815260059290921b84018101918181019089841115614de057600080fd5b948201945b83861015614dfe57853582529482019490820190614de5565b96505086013592505080821115614e1457600080fd5b50614e2185828601614d0e565b9150509250929050565b60008083601f840112614e3d57600080fd5b50813567ffffffffffffffff811115614e5557600080fd5b602083019150836020828501011115614e6d57600080fd5b9250929050565b60008060008060008060a08789031215614e8d57600080fd5b8635614e988161466d565b9550602087013567ffffffffffffffff811115614eb457600080fd5b614ec089828a01614e2b565b9096509450614ed3905060408801614885565b92506060870135614ee3816146b7565b80925050608087013590509295509295509295565b60008060408385031215614f0b57600080fd5b8235614f168161466d565b9150602083013561470281614ade565b60008060408385031215614f3957600080fd5b8235614f4481614ade565b9150602083013561470281614ab9565b60008060408385031215614f6757600080fd5b8235614f7281614ade565b915060208301356147028161466d565b600060208284031215614f9457600080fd5b5035919050565b600081518084526020808501945080840160005b83811015614fe157815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614faf565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261505e60e0840182614f9b565b905060a084015160c08401528091505092915050565b6000806000806060858703121561508a57600080fd5b843561509581614ade565b935060208501359250604085013567ffffffffffffffff8111156150b857600080fd5b6150c487828801614e2b565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b82811015615109578151845292840192908401906001016150ed565b5050508381038285015261511d8186614f9b565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b8083101561494657835163ffffffff1682529284019260019290920191908401906151ab565b6000602082840312156151e357600080fd5b81356146b081614ade565b6000806020838503121561520157600080fd5b823567ffffffffffffffff8082111561521957600080fd5b818501915085601f83011261522d57600080fd5b81358181111561523c57600080fd5b8660206101608302850101111561525257600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016142de6040830184614caa565b815181526020808301516101608301916152f69084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161531660408401826bffffffffffffffffffffffff169052565b50606083015161533e606084018273ffffffffffffffffffffffffffffffffffffffff169052565b50608083015161535a608084018267ffffffffffffffff169052565b5060a083015161537260a084018263ffffffff169052565b5060c083015161538f60c084018268ffffffffffffffffff169052565b5060e08301516153ac60e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff81811683821601908082111561543f5761543f6153f2565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146153ea576153ea6153f2565b6bffffffffffffffffffffffff81811683821601908082111561543f5761543f6153f2565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff851660208201526154cd6040820185614caa565b60a0606082015260006154e360a0830185614731565b82810360808401526110838185614731565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203615526576155266153f2565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561543f5761543f6153f2565b600060ff821660ff8103615568576155686153f2565b60010192915050565b81810381811115611515576115156153f2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036155d0576155d06153f2565b6001019392505050565b80820180821115611515576115156153f2565b6000602082840312156155ff57600080fd5b5051919050565b6000610160828403121561561957600080fd5b6146b08383614b29565b60006020828403121561563557600080fd5b815180151581146146b057600080fd5b67ffffffffffffffff81811683821601908082111561543f5761543f6153f2565b83815260606020820152600061567f6060830185614731565b828103604084015261511d8185614731565b60208152600082516101608060208501526156b0610180850183614731565b91506020850151604085015260408501516156e3606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e085015161010061575a8187018363ffffffff169052565b86015190506101206157718682018361ffff169052565b860151905061014061578e8682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161468e81614ade565b805161468e81614ab9565b805161468e8161466d565b805161468e816146b7565b805161468e81614897565b805161468e81614b0b565b6000610160828403121561580957600080fd5b615811614812565b82518152615821602084016157b4565b6020820152615832604084016157bf565b6040820152615843606084016157b4565b6060820152615854608084016157ca565b608082015261586560a084016157d5565b60a082015261587660c084016157e0565b60c082015261588760e084016157e0565b60e082015261010061589a8185016157eb565b908201526101206158ac8482016157eb565b908201526101406158be8482016157d5565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e0606083015261590a60e0830187614731565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006142de6040830184614731565b6000825161598281846020870161470d565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -384,34 +384,26 @@ func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractById(id return _FunctionsRouter.Contract.GetProposedContractById(&_FunctionsRouter.CallOpts, id) } -func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) (GetProposedContractSet, - - error) { +func (_FunctionsRouter *FunctionsRouterCaller) GetProposedContractSet(opts *bind.CallOpts) ([][32]byte, []common.Address, error) { var out []interface{} err := _FunctionsRouter.contract.Call(opts, &out, "getProposedContractSet") - outstruct := new(GetProposedContractSet) if err != nil { - return *outstruct, err + return *new([][32]byte), *new([]common.Address), err } - outstruct.TimelockEndBlock = *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - outstruct.Ids = *abi.ConvertType(out[1], new([][32]byte)).(*[][32]byte) - outstruct.To = *abi.ConvertType(out[2], new([]common.Address)).(*[]common.Address) + out0 := *abi.ConvertType(out[0], new([][32]byte)).(*[][32]byte) + out1 := *abi.ConvertType(out[1], new([]common.Address)).(*[]common.Address) - return *outstruct, err + return out0, out1, err } -func (_FunctionsRouter *FunctionsRouterSession) GetProposedContractSet() (GetProposedContractSet, - - error) { +func (_FunctionsRouter *FunctionsRouterSession) GetProposedContractSet() ([][32]byte, []common.Address, error) { return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) } -func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() (GetProposedContractSet, - - error) { +func (_FunctionsRouter *FunctionsRouterCallerSession) GetProposedContractSet() ([][32]byte, []common.Address, error) { return _FunctionsRouter.Contract.GetProposedContractSet(&_FunctionsRouter.CallOpts) } @@ -3318,12 +3310,6 @@ func (_FunctionsRouter *FunctionsRouterFilterer) ParseUnpaused(log types.Log) (* return event, nil } -type GetProposedContractSet struct { - TimelockEndBlock *big.Int - Ids [][32]byte - To []common.Address -} - func (_FunctionsRouter *FunctionsRouter) ParseLog(log types.Log) (generated.AbigenLog, error) { switch log.Topics[0] { case _FunctionsRouter.abi.Events["ConfigUpdated"].ID: @@ -3467,9 +3453,7 @@ type FunctionsRouterInterface interface { GetProposedContractById(opts *bind.CallOpts, id [32]byte) (common.Address, error) - GetProposedContractSet(opts *bind.CallOpts) (GetProposedContractSet, - - error) + GetProposedContractSet(opts *bind.CallOpts) ([][32]byte, []common.Address, error) GetSubscription(opts *bind.CallOpts, subscriptionId uint64) (IFunctionsSubscriptionsSubscription, error) diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 0dded72ec46..bd9d0a4c0db 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -4,9 +4,9 @@ functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfSer functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin b80ce6eac78baa63dde3eab4b3c4ada0d1ae6980e9b736d1857b5474b84320a5 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 8c83f78cf96b47a52e51506b6176ac1860f37396e11e5ea6fa695bae43c58ba9 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin af1d9a3febc12048b71a9626b58541fa3b37d32aab18db0755d4bbdf94257610 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 07345caa92457c3deb2483d120e3c26324e05a79c730870fa4ecf1834b00e67d ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index fe9c460f27b..1f712ddba32 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -167,30 +167,30 @@ func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmR continue } commitmentABI := abi.Arguments{ - {Type: uint72Type}, // AdminFee + {Type: bytes32Type}, // RequestId {Type: addressType}, // Coordinator + {Type: uint96Type}, // EstimatedTotalCostJuels {Type: addressType}, // Client {Type: uint64Type}, // SubscriptionId {Type: uint32Type}, // CallbackGasLimit - {Type: uint96Type}, // EstimatedTotalCostJuels - {Type: uint32Type}, // TimeoutTimestamp - {Type: bytes32Type}, // RequestId + {Type: uint72Type}, // AdminFee {Type: uint72Type}, // DonFee {Type: uint40Type}, // GasOverheadBeforeCallback {Type: uint40Type}, // GasOverheadAfterCallback + {Type: uint32Type}, // TimeoutTimestamp } commitmentBytes, err := commitmentABI.Pack( - oracleRequest.Commitment.AdminFee, + oracleRequest.Commitment.RequestId, oracleRequest.Commitment.Coordinator, + oracleRequest.Commitment.EstimatedTotalCostJuels, oracleRequest.Commitment.Client, oracleRequest.Commitment.SubscriptionId, oracleRequest.Commitment.CallbackGasLimit, - oracleRequest.Commitment.EstimatedTotalCostJuels, - oracleRequest.Commitment.TimeoutTimestamp, - oracleRequest.Commitment.RequestId, + oracleRequest.Commitment.AdminFee, oracleRequest.Commitment.DonFee, oracleRequest.Commitment.GasOverheadBeforeCallback, oracleRequest.Commitment.GasOverheadAfterCallback, + oracleRequest.Commitment.TimeoutTimestamp, ) if err != nil { l.lggr.Errorw("LatestEvents: failed to pack commitment bytes, skipping", err) From 5a78c129e3c4ce58bec31163013a09144ef9ba22 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Sun, 6 Aug 2023 17:54:43 -0700 Subject: [PATCH 097/270] [Functions] Additional balance invariant checks in Subscriptions contract (#10091) --- .../functions/dev/1_0_0/FunctionsSubscriptions.sol | 13 +++++++++++++ .../functions/v1/FunctionsSubscriptions.test.ts | 11 +++++++++++ .../generated/functions_router/functions_router.go | 4 ++-- ...ated-wrapper-dependency-versions-do-not-edit.txt | 2 +- 4 files changed, 27 insertions(+), 3 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol index 5ceb97a1e73..cabe8b0d284 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsSubscriptions.sol @@ -70,6 +70,7 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece error MustBeSubscriptionOwner(); error TimeoutNotExceeded(); error MustBeProposedOwner(address proposedOwner); + error TotalBalanceInvariantViolated(uint256 totalBalance, uint256 deductionAttempt); // Should never happen event FundsRecovered(address to, uint256 amount); // ================================================================ @@ -121,9 +122,15 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece uint96 totalCostJuels = costWithoutCallbackJuels + adminFee + callbackGasCostJuels; // Charge the subscription + if (s_subscriptions[subscriptionId].balance < totalCostJuels) { + revert InsufficientBalance(s_subscriptions[subscriptionId].balance); + } s_subscriptions[subscriptionId].balance -= totalCostJuels; // Unblock earmarked funds + if (s_subscriptions[subscriptionId].blockedBalance < estimatedTotalCostJuels) { + revert InsufficientBalance(s_subscriptions[subscriptionId].balance); + } s_subscriptions[subscriptionId].blockedBalance -= estimatedTotalCostJuels; // Pay the DON's fees and gas reimbursement @@ -177,6 +184,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece if (currentBalance < amount) { revert InsufficientBalance(currentBalance); } + if (s_totalLinkBalance < amount) { + revert TotalBalanceInvariantViolated(s_totalLinkBalance, amount); + } s_withdrawableTokens[msg.sender] -= amount; s_totalLinkBalance -= amount; IERC20(i_linkToken).safeTransfer(recipient, amount); @@ -195,6 +205,9 @@ abstract contract FunctionsSubscriptions is IFunctionsSubscriptions, IERC677Rece if (currentBalance < amount) { revert InsufficientBalance(currentBalance); } + if (s_totalLinkBalance < amount) { + revert TotalBalanceInvariantViolated(s_totalLinkBalance, amount); + } s_withdrawableTokens[address(this)] -= amount; s_totalLinkBalance -= amount; diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 29db885cce9..7768138801a 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -558,6 +558,17 @@ describe('Functions Router - Subscriptions', () => { }) }) + describe('#ownerWithdraw', async function () { + it('cannot withdraw more than balance', async function () { + await expect( + contracts.router.oracleWithdraw( + randomAddressString(), + BigNumber.from('100'), + ), + ).to.be.revertedWith(`InsufficientBalance`) + }) + }) + describe('#flagsSet', async function () { it('get flags that were previously set', async function () { const flags = ethers.utils.formatBytes32String('arbitrary_byte_values') diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index c92bbdfea57..34366799f0b 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -68,8 +68,8 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200604c3803806200604c8339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615999620006b360003960008181611359015281816120c3015281816129bb01528181612a7f01526131fa01526159996000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614693565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046146d4565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f919061477b565b6102f66103a236600461478e565b610853565b6102f66103b5366004614951565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614bfd565b6109b2565b60405161030f929190614ce5565b6102f6610417366004614d72565b610d98565b6102f661101d565b610437610432366004614e74565b61102f565b60405190815260200161030f565b610437610453366004614e74565b61108f565b6102f6610466366004614ef8565b61109b565b610437610479366004614693565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be366004614f26565b6111e9565b6102f66104d1366004614f26565b6113a2565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004614f54565b61148b565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004614f82565b61151b565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c366004614ef8565b6115da565b6102f661178e565b6102f66105a7366004614693565b6118b5565b6102f66119fc565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e5366004614ef8565b611a0c565b6104e4611de1565b610605610600366004614693565b611f6e565b60405161030f9190614fec565b6102f6610620366004615074565b6120a3565b610559610633366004614f82565b6122ef565b600954610437565b6102f661234e565b61065061249a565b60405161030f9291906150d0565b61066661256a565b60405161030f9190615127565b6104e46106813660046151d1565b61269f565b6102f6610694366004614ef8565b61291f565b6102f66106a73660046151d1565b612982565b6102f66106ba3660046151ee565b612afb565b6104a06106cd366004614693565b612dcc565b6102f66106e0366004614f82565b612f1b565b6102f66106f33660046151d1565b612f28565b610700612f39565b61070981612f41565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16612fb7565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d7615264565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b612f39565b61086482612f41565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d6132a3565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906144de565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a79190615127565b60405180910390a150565b6000806109bd613329565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615293565b60405180910390a2506000610d8d565b8251600090815260056020908152604091829020549151610aab918691016152c5565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615293565b8261012001518360a0015163ffffffff16610b1e9190615421565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615293565b6000610b7e8460a0015163ffffffff16613331565b610b889088615446565b9050600081878660c0015168ffffffffffffffffff16610ba8919061546e565b610bb2919061546e565b9050610bc18560800151611f6e565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615293565b60405180910390a25060009150610d8d9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615293565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c91906133d3565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d158860200151613331565b8d613560565b9050846080015167ffffffffffffffff1685600001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610d68578e610d6a565b8f5b8860400151604051610d80959493929190615493565b60405180910390a3519150505b965096945050505050565b610da06132a3565b8151815181141580610db25750600881115b15610de9576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610edb576000848281518110610e0857610e08615264565b602002602001015190506000848381518110610e2657610e26615264565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e91575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec8576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ed4906154f5565b9050610dec565b506040805180820190915283815260208082018490528451600c91610f04918391880190614589565b506020828101518051610f1d92600185019201906145c4565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f6057610f60615264565b602002602001015160086000878581518110610f7e57610f7e615264565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fc757610fc7615264565b60200260200101516040516110059392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611016816154f5565b9050610f24565b6110256132a3565b61102d6137c1565b565b60008061103b8361151b565b905061108383828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b915061383e9050565b98975050505050505050565b60008061103b836122ef565b6110a3613329565b6110ac82613be7565b6110b4613cad565b73ffffffffffffffffffffffffffffffffffffffff8116158061111b575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611152576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111f1612f39565b806bffffffffffffffffffffffff166000036112275750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611293576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b30600090815260016020526040812080548492906112c09084906bffffffffffffffffffffffff1661552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff16611316919061552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061139d83836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613db79092919063ffffffff16565b505050565b6113aa613329565b806bffffffffffffffffffffffff166000036113f2576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff90811690821681101561145e576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b33600090815260016020526040812080548492906112c09084906bffffffffffffffffffffffff1661552d565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff821610156115a457600c805460ff831690811061154357611543615264565b9060005260206000200154830361159457600d805460ff831690811061156b5761156b615264565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61159d81615552565b905061151f565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6115e2613329565b6115eb82613be7565b6115f3613cad565b6000611602600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611665576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff16156116ad57505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff16331461180f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6118bd613329565b6118c5613cad565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611965576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611781565b611a046132a3565b61102d613e44565b611a14613329565b611a1d82613be7565b611a25613cad565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611acd576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611b22576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611b9d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611b72575b5050505050905060005b8151811015611d45578373ffffffffffffffffffffffffffffffffffffffff16828281518110611bd957611bd9615264565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611d35578160018351611c0b9190615571565b81518110611c1b57611c1b615264565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611c5e57611c5e615264565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611cd857611cd8615584565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611d45565b611d3e816154f5565b9050611ba7565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611deb613329565b611df3613cad565b60028054600090611e0d9067ffffffffffffffff166155b3565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611e83578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611f1e926002850192909101906145c4565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a0810191909152611fa882612f41565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561208957602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161205e575b505050505081526020016003820154815250509050919050565b6120ab613329565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461211a576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612154576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061216282840184614693565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166121db576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff1691869190612212838561546e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff16612268919061546e565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846122cf91906155da565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff1680611515576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b6123566132a3565b60005b600c54811015612479576000600c600001828154811061237b5761237b615264565b906000526020600020015490506000600c60010183815481106123a0576123a0615264565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612472816154f5565b9050612359565b50600c6000612488828261463e565b61249660018301600061463e565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156124f257602002820191906000526020600020905b8154815260200190600101908083116124de575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561255b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612530575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561269157602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116126545790505b505050505081525050905090565b60006126a9613329565b6126b1613cad565b600280546000906126cb9067ffffffffffffffff166155b3565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612741578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926127dc926002850192909101906145c4565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b612927613329565b61293082613be7565b612938613cad565b61294182612dcc565b15612978576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6124968282612fb7565b61298a612f39565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612a17573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612a3b91906155ed565b6000549091506bffffffffffffffffffffffff168181101561139d576000612a638284615571565b9050612aa673ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613db7565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612b03613329565b60005b8181101561139d576000838383818110612b2257612b22615264565b90506101600201803603810190612b399190615606565b80516080820151600082815260056020908152604091829020549151949550929391929091612b6a918691016152c5565b6040516020818303038152906040528051906020012014612bb7576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612bfc576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612c6f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612c939190615623565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612cd49084906bffffffffffffffffffffffff1661552d565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612d5c9185916901000000000000000000900416615645565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612dc5906154f5565b9050612b06565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612e4457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612e19575b5050505050905060005b8151811015612f1157600060046000848481518110612e6f57612e6f615264565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612f0057506001949350505050565b50612f0a816154f5565b9050612e4e565b5060009392505050565b612f236132a3565b600955565b612f306132a3565b61075481613e9f565b61102d6132a3565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561309857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161306d575b505050918352505060039190910154602090910152805190915060005b8260800151518110156131595760046000846080015183815181106130dc576130dc615264565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613152816154f5565b90506130b5565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061318b600283018261463e565b506000600391909101819055805482919081906131b79084906bffffffffffffffffffffffff1661552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061323e83826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613db79092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611dd3565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61102d613f9b565b60006bffffffffffffffffffffffff8211156133cf576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b9061341d90899089908990602401615666565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6134e857600080fd5b5a848110156134f657600080fd5b849003604081048103891061350a57600080fd5b60008087516020890160008c8ef193505a900391503d608481111561352d575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b604080518082019091526000808252602082015260006135808486615446565b905060008161358f888661546e565b613599919061546e565b67ffffffffffffffff8b166000908152600360205260408120805492935083929091906135d59084906bffffffffffffffffffffffff1661552d565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c16600090815260036020526040812060010180548d945090926136299185911661552d565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508184613663919061546e565b33600090815260016020526040812080549091906136909084906bffffffffffffffffffffffff1661546e565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926136d79185911661546e565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161375b9185916901000000000000000000900416615645565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6137c9614008565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613848613329565b61385185612f41565b61385b3386614074565b6138658583610757565b835160000361389f576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006138aa86611f6e565b905060006138b8338861148b565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a815260200161390e8c67ffffffffffffffff166000908152600360208190526040909120015490565b81523360208201526040878101518851919092019161392c9161552d565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b81526004016139f29190615691565b610160604051808303816000875af1158015613a12573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a3691906157f6565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613b3d91906152c5565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613b7d338983604001516140e8565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613bd197969594939291906158c9565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613c5e576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612496576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613cdd5750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613d3e90339060248101615941565b602060405180830381865afa158015613d5b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d7f9190615623565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb0000000000000000000000000000000000000000000000000000000017905261139d9084906141c3565b613e4c613f9b565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586138143390565b3373ffffffffffffffffffffffffffffffffffffffff821603613f1e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612496576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906141229084906bffffffffffffffffffffffff1661546e565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff8089168552925290912080546001945090928492614198928492900416615645565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b6000614225826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166142cf9092919063ffffffff16565b80519091501561139d57808060200190518101906142439190615623565b61139d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606142de84846000856142e6565b949350505050565b606082471015614378576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516143a19190615970565b60006040518083038185875af1925050503d80600081146143de576040519150601f19603f3d011682016040523d82523d6000602084013e6143e3565b606091505b50915091506143f4878383876143ff565b979650505050505050565b6060831561449557825160000361448e5773ffffffffffffffffffffffffffffffffffffffff85163b61448e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816142de565b6142de83838151156144aa5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b3919061477b565b8280548282559060005260206000209060070160089004810192821561457d5791602002820160005b8382111561454b57835183826101000a81548163ffffffff021916908363ffffffff1602179055509260200192600401602081600301049283019260010302614507565b801561457b5782816101000a81549063ffffffff021916905560040160208160030104928301926001030261454b565b505b506133cf929150614658565b82805482825590600052602060002090810192821561457d579160200282015b8281111561457d5782518255916020019190600101906145a9565b82805482825590600052602060002090810192821561457d579160200282015b8281111561457d57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906145e4565b508054600082559060005260206000209081019061075491905b5b808211156133cf5760008155600101614659565b67ffffffffffffffff8116811461075457600080fd5b803561468e8161466d565b919050565b6000602082840312156146a557600080fd5b81356146b08161466d565b9392505050565b63ffffffff8116811461075457600080fd5b803561468e816146b7565b600080604083850312156146e757600080fd5b82356146f28161466d565b91506020830135614702816146b7565b809150509250929050565b60005b83811015614728578181015183820152602001614710565b50506000910152565b6000815180845261474981602086016020860161470d565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006146b06020830184614731565b600080604083850312156147a157600080fd5b82356147ac8161466d565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff8111828210171561480c5761480c6147ba565b60405290565b604051610160810167ffffffffffffffff8111828210171561480c5761480c6147ba565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff8111828210171561487d5761487d6147ba565b604052919050565b803561ffff8116811461468e57600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561468e81614897565b600067ffffffffffffffff8211156148d3576148d36147ba565b5060051b60200190565b600082601f8301126148ee57600080fd5b813560206149036148fe836148b9565b614836565b82815260059290921b8401810191818101908684111561492257600080fd5b8286015b84811015614946578035614939816146b7565b8352918301918301614926565b509695505050505050565b60006020828403121561496357600080fd5b813567ffffffffffffffff8082111561497b57600080fd5b9083019060a0828603121561498f57600080fd5b6149976147e9565b6149a083614885565b815260208301356149b081614897565b602082015260408301357fffffffff00000000000000000000000000000000000000000000000000000000811681146149e857600080fd5b60408201526149f960608401614885565b6060820152608083013582811115614a1057600080fd5b614a1c878286016148dd565b60808301525095945050505050565b600082601f830112614a3c57600080fd5b813567ffffffffffffffff811115614a5657614a566147ba565b614a8760207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614836565b818152846020838601011115614a9c57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561468e81614ab9565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561468e81614ade565b64ffffffffff8116811461075457600080fd5b803561468e81614b0b565b60006101608284031215614b3c57600080fd5b614b44614812565b905081358152614b5660208301614b00565b6020820152614b6760408301614ad3565b6040820152614b7860608301614b00565b6060820152614b8960808301614683565b6080820152614b9a60a083016146c9565b60a0820152614bab60c083016148ae565b60c0820152614bbc60e083016148ae565b60e0820152610100614bcf818401614b1e565b90820152610120614be1838201614b1e565b90820152610140614bf38382016146c9565b9082015292915050565b6000806000806000806102008789031215614c1757600080fd5b863567ffffffffffffffff80821115614c2f57600080fd5b614c3b8a838b01614a2b565b97506020890135915080821115614c5157600080fd5b50614c5e89828a01614a2b565b9550506040870135614c6f81614ab9565b93506060870135614c7f81614ab9565b92506080870135614c8f81614ade565b9150614c9e8860a08901614b29565b90509295509295509295565b60078110614ce1577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614cf38285614caa565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614d1f57600080fd5b81356020614d2f6148fe836148b9565b82815260059290921b84018101918181019086841115614d4e57600080fd5b8286015b84811015614946578035614d6581614ade565b8352918301918301614d52565b60008060408385031215614d8557600080fd5b823567ffffffffffffffff80821115614d9d57600080fd5b818501915085601f830112614db157600080fd5b81356020614dc16148fe836148b9565b82815260059290921b84018101918181019089841115614de057600080fd5b948201945b83861015614dfe57853582529482019490820190614de5565b96505086013592505080821115614e1457600080fd5b50614e2185828601614d0e565b9150509250929050565b60008083601f840112614e3d57600080fd5b50813567ffffffffffffffff811115614e5557600080fd5b602083019150836020828501011115614e6d57600080fd5b9250929050565b60008060008060008060a08789031215614e8d57600080fd5b8635614e988161466d565b9550602087013567ffffffffffffffff811115614eb457600080fd5b614ec089828a01614e2b565b9096509450614ed3905060408801614885565b92506060870135614ee3816146b7565b80925050608087013590509295509295509295565b60008060408385031215614f0b57600080fd5b8235614f168161466d565b9150602083013561470281614ade565b60008060408385031215614f3957600080fd5b8235614f4481614ade565b9150602083013561470281614ab9565b60008060408385031215614f6757600080fd5b8235614f7281614ade565b915060208301356147028161466d565b600060208284031215614f9457600080fd5b5035919050565b600081518084526020808501945080840160005b83811015614fe157815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101614faf565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261505e60e0840182614f9b565b905060a084015160c08401528091505092915050565b6000806000806060858703121561508a57600080fd5b843561509581614ade565b935060208501359250604085013567ffffffffffffffff8111156150b857600080fd5b6150c487828801614e2b565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b82811015615109578151845292840192908401906001016150ed565b5050508381038285015261511d8186614f9b565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b8083101561494657835163ffffffff1682529284019260019290920191908401906151ab565b6000602082840312156151e357600080fd5b81356146b081614ade565b6000806020838503121561520157600080fd5b823567ffffffffffffffff8082111561521957600080fd5b818501915085601f83011261522d57600080fd5b81358181111561523c57600080fd5b8660206101608302850101111561525257600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016142de6040830184614caa565b815181526020808301516101608301916152f69084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161531660408401826bffffffffffffffffffffffff169052565b50606083015161533e606084018273ffffffffffffffffffffffffffffffffffffffff169052565b50608083015161535a608084018267ffffffffffffffff169052565b5060a083015161537260a084018263ffffffff169052565b5060c083015161538f60c084018268ffffffffffffffffff169052565b5060e08301516153ac60e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff81811683821601908082111561543f5761543f6153f2565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146153ea576153ea6153f2565b6bffffffffffffffffffffffff81811683821601908082111561543f5761543f6153f2565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff851660208201526154cd6040820185614caa565b60a0606082015260006154e360a0830185614731565b82810360808401526110838185614731565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203615526576155266153f2565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561543f5761543f6153f2565b600060ff821660ff8103615568576155686153f2565b60010192915050565b81810381811115611515576115156153f2565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036155d0576155d06153f2565b6001019392505050565b80820180821115611515576115156153f2565b6000602082840312156155ff57600080fd5b5051919050565b6000610160828403121561561957600080fd5b6146b08383614b29565b60006020828403121561563557600080fd5b815180151581146146b057600080fd5b67ffffffffffffffff81811683821601908082111561543f5761543f6153f2565b83815260606020820152600061567f6060830185614731565b828103604084015261511d8185614731565b60208152600082516101608060208501526156b0610180850183614731565b91506020850151604085015260408501516156e3606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e085015161010061575a8187018363ffffffff169052565b86015190506101206157718682018361ffff169052565b860151905061014061578e8682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161468e81614ade565b805161468e81614ab9565b805161468e8161466d565b805161468e816146b7565b805161468e81614897565b805161468e81614b0b565b6000610160828403121561580957600080fd5b615811614812565b82518152615821602084016157b4565b6020820152615832604084016157bf565b6040820152615843606084016157b4565b6060820152615854608084016157ca565b608082015261586560a084016157d5565b60a082015261587660c084016157e0565b60c082015261588760e084016157e0565b60e082015261010061589a8185016157eb565b908201526101206158ac8482016157eb565b908201526101406158be8482016157d5565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e0606083015261590a60e0830187614731565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006142de6040830184614731565b6000825161598281846020870161470d565b919091019291505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"totalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"deductionAttempt\",\"type\":\"uint256\"}],\"name\":\"TotalBalanceInvariantViolated\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200623f3803806200623f8339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615b8c620006b3600039600081816113c20152818161219501528181612a8d01528181612b5101526132cc0152615b8c6000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614886565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046148c7565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f919061496e565b6102f66103a2366004614981565b610853565b6102f66103b5366004614b44565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614df0565b6109b2565b60405161030f929190614ed8565b6102f6610417366004614f65565b610d98565b6102f661101d565b610437610432366004615067565b61102f565b60405190815260200161030f565b610437610453366004615067565b61108f565b6102f66104663660046150eb565b61109b565b610437610479366004614886565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be366004615119565b6111e9565b6102f66104d1366004615119565b61140b565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004615147565b61155d565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004615175565b6115ed565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c3660046150eb565b6116ac565b6102f6611860565b6102f66105a7366004614886565b611987565b6102f6611ace565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e53660046150eb565b611ade565b6104e4611eb3565b610605610600366004614886565b612040565b60405161030f91906151df565b6102f6610620366004615267565b612175565b610559610633366004615175565b6123c1565b600954610437565b6102f6612420565b61065061256c565b60405161030f9291906152c3565b61066661263c565b60405161030f919061531a565b6104e46106813660046153c4565b612771565b6102f66106943660046150eb565b6129f1565b6102f66106a73660046153c4565b612a54565b6102f66106ba3660046153e1565b612bcd565b6104a06106cd366004614886565b612e9e565b6102f66106e0366004615175565b612fed565b6102f66106f33660046153c4565b612ffa565b61070061300b565b61070981613013565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16613089565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d7615457565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b61300b565b61086482613013565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d613375565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906146d1565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a7919061531a565b60405180910390a150565b6000806109bd6133fb565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615486565b60405180910390a2506000610d8d565b8251600090815260056020908152604091829020549151610aab918691016154b8565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615486565b8261012001518360a0015163ffffffff16610b1e9190615614565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615486565b6000610b7e8460a0015163ffffffff16613403565b610b889088615639565b9050600081878660c0015168ffffffffffffffffff16610ba89190615661565b610bb29190615661565b9050610bc18560800151612040565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615486565b60405180910390a25060009150610d8d9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615486565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c91906134a5565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d158860200151613403565b8d613632565b9050846080015167ffffffffffffffff1685600001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610d68578e610d6a565b8f5b8860400151604051610d80959493929190615686565b60405180910390a3519150505b965096945050505050565b610da0613375565b8151815181141580610db25750600881115b15610de9576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610edb576000848281518110610e0857610e08615457565b602002602001015190506000848381518110610e2657610e26615457565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e91575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec8576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ed4906156e8565b9050610dec565b506040805180820190915283815260208082018490528451600c91610f0491839188019061477c565b506020828101518051610f1d92600185019201906147b7565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f6057610f60615457565b602002602001015160086000878581518110610f7e57610f7e615457565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fc757610fc7615457565b60200260200101516040516110059392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611016816156e8565b9050610f24565b611025613375565b61102d6139b4565b565b60008061103b836115ed565b905061108383828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613a319050565b98975050505050505050565b60008061103b836123c1565b6110a36133fb565b6110ac82613dda565b6110b4613ea0565b73ffffffffffffffffffffffffffffffffffffffff8116158061111b575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611152576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111f161300b565b806bffffffffffffffffffffffff166000036112275750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611293576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff808416911610156112fc576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b30600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff1661137f9190615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061140683836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613faa9092919063ffffffff16565b505050565b6114136133fb565b806bffffffffffffffffffffffff1660000361145b576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff9081169082168110156114c7576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff80841691161015611530576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b33600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615720565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561167657600c805460ff831690811061161557611615615457565b9060005260206000200154830361166657600d805460ff831690811061163d5761163d615457565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61166f81615745565b90506115f1565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6116b46133fb565b6116bd82613dda565b6116c5613ea0565b60006116d4600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611737576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff161561177f57505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff1633146118e1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b61198f6133fb565b611997613ea0565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611a37576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611853565b611ad6613375565b61102d614037565b611ae66133fb565b611aef82613dda565b611af7613ea0565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b9f576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611bf4576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611c6f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611c44575b5050505050905060005b8151811015611e17578373ffffffffffffffffffffffffffffffffffffffff16828281518110611cab57611cab615457565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611e07578160018351611cdd9190615764565b81518110611ced57611ced615457565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611d3057611d30615457565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611daa57611daa615777565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611e17565b611e10816156e8565b9050611c79565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611ebd6133fb565b611ec5613ea0565b60028054600090611edf9067ffffffffffffffff166157a6565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611f55578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611ff0926002850192909101906147b7565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261207a82613013565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561215b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612130575b505050505081526020016003820154815250509050919050565b61217d6133fb565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146121ec576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612226576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061223482840184614886565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166122ad576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906122e48385615661565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661233a9190615661565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846123a191906157cd565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff16806115e7576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b612428613375565b60005b600c5481101561254b576000600c600001828154811061244d5761244d615457565b906000526020600020015490506000600c600101838154811061247257612472615457565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612544816156e8565b905061242b565b50600c600061255a8282614831565b612568600183016000614831565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156125c457602002820191906000526020600020905b8154815260200190600101908083116125b0575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561262d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612602575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561276357602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116127265790505b505050505081525050905090565b600061277b6133fb565b612783613ea0565b6002805460009061279d9067ffffffffffffffff166157a6565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612813578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926128ae926002850192909101906147b7565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b6129f96133fb565b612a0282613dda565b612a0a613ea0565b612a1382612e9e565b15612a4a576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6125688282613089565b612a5c61300b565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ae9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b0d91906157e0565b6000549091506bffffffffffffffffffffffff1681811015611406576000612b358284615764565b9050612b7873ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613faa565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612bd56133fb565b60005b81811015611406576000838383818110612bf457612bf4615457565b90506101600201803603810190612c0b91906157f9565b80516080820151600082815260056020908152604091829020549151949550929391929091612c3c918691016154b8565b6040516020818303038152906040528051906020012014612c89576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612cce576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612d41573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d659190615816565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612da69084906bffffffffffffffffffffffff16615720565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612e2e9185916901000000000000000000900416615838565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612e97906156e8565b9050612bd8565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612f1657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612eeb575b5050505050905060005b8151811015612fe357600060046000848481518110612f4157612f41615457565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612fd257506001949350505050565b50612fdc816156e8565b9050612f20565b5060009392505050565b612ff5613375565b600955565b613002613375565b61075481614092565b61102d613375565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561316a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161313f575b505050918352505060039190910154602090910152805190915060005b82608001515181101561322b5760046000846080015183815181106131ae576131ae615457565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613224816156e8565b9050613187565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061325d6002830182614831565b506000600391909101819055805482919081906132899084906bffffffffffffffffffffffff16615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061331083826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613faa9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611ea5565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61102d61418e565b60006bffffffffffffffffffffffff8211156134a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b906134ef90899089908990602401615859565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6135ba57600080fd5b5a848110156135c857600080fd5b84900360408104810389106135dc57600080fd5b60008087516020890160008c8ef193505a900391503d60848111156135ff575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b604080518082019091526000808252602082015260006136528486615639565b90506000816136618886615661565b61366b9190615661565b67ffffffffffffffff8b166000908152600360205260409020549091506bffffffffffffffffffffffff808316911610156136fe5767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812080548392906137359084906bffffffffffffffffffffffff16615720565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600360205260409020600101548b82169116101590506137e25767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812060010180548b929061381c9084906bffffffffffffffffffffffff16615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846138569190615661565b33600090815260016020526040812080549091906138839084906bffffffffffffffffffffffff16615661565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926138ca91859116615661565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161394e9185916901000000000000000000900416615838565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6139bc6141fb565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613a3b6133fb565b613a4485613013565b613a4e3386614267565b613a588583610757565b8351600003613a92576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a9d86612040565b90506000613aab338861155d565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a8152602001613b018c67ffffffffffffffff166000908152600360208190526040909120015490565b815233602082015260408781015188519190920191613b1f91615720565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b8152600401613be59190615884565b610160604051808303816000875af1158015613c05573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c2991906159e9565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613d3091906154b8565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613d70338983604001516142db565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613dc49796959493929190615abc565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e51576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612568576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613ed05750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613f3190339060248101615b34565b602060405180830381865afa158015613f4e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f729190615816565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526114069084906143b6565b61403f61418e565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a073390565b3373ffffffffffffffffffffffffffffffffffffffff821603614111576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612568576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143159084906bffffffffffffffffffffffff16615661565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261438b928492900416615838565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b6000614418826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166144c29092919063ffffffff16565b80519091501561140657808060200190518101906144369190615816565b611406576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606144d184846000856144d9565b949350505050565b60608247101561456b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516145949190615b63565b60006040518083038185875af1925050503d80600081146145d1576040519150601f19603f3d011682016040523d82523d6000602084013e6145d6565b606091505b50915091506145e7878383876145f2565b979650505050505050565b606083156146885782516000036146815773ffffffffffffffffffffffffffffffffffffffff85163b614681576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816144d1565b6144d1838381511561469d5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b3919061496e565b828054828255906000526020600020906007016008900481019282156147705791602002820160005b8382111561473e57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026146fa565b801561476e5782816101000a81549063ffffffff021916905560040160208160030104928301926001030261473e565b505b506134a192915061484b565b828054828255906000526020600020908101928215614770579160200282015b8281111561477057825182559160200191906001019061479c565b828054828255906000526020600020908101928215614770579160200282015b8281111561477057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906147d7565b508054600082559060005260206000209081019061075491905b5b808211156134a1576000815560010161484c565b67ffffffffffffffff8116811461075457600080fd5b803561488181614860565b919050565b60006020828403121561489857600080fd5b81356148a381614860565b9392505050565b63ffffffff8116811461075457600080fd5b8035614881816148aa565b600080604083850312156148da57600080fd5b82356148e581614860565b915060208301356148f5816148aa565b809150509250929050565b60005b8381101561491b578181015183820152602001614903565b50506000910152565b6000815180845261493c816020860160208601614900565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006148a36020830184614924565b6000806040838503121561499457600080fd5b823561499f81614860565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff811182821017156149ff576149ff6149ad565b60405290565b604051610160810167ffffffffffffffff811182821017156149ff576149ff6149ad565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614a7057614a706149ad565b604052919050565b803561ffff8116811461488157600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561488181614a8a565b600067ffffffffffffffff821115614ac657614ac66149ad565b5060051b60200190565b600082601f830112614ae157600080fd5b81356020614af6614af183614aac565b614a29565b82815260059290921b84018101918181019086841115614b1557600080fd5b8286015b84811015614b39578035614b2c816148aa565b8352918301918301614b19565b509695505050505050565b600060208284031215614b5657600080fd5b813567ffffffffffffffff80821115614b6e57600080fd5b9083019060a08286031215614b8257600080fd5b614b8a6149dc565b614b9383614a78565b81526020830135614ba381614a8a565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614bdb57600080fd5b6040820152614bec60608401614a78565b6060820152608083013582811115614c0357600080fd5b614c0f87828601614ad0565b60808301525095945050505050565b600082601f830112614c2f57600080fd5b813567ffffffffffffffff811115614c4957614c496149ad565b614c7a60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a29565b818152846020838601011115614c8f57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561488181614cac565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561488181614cd1565b64ffffffffff8116811461075457600080fd5b803561488181614cfe565b60006101608284031215614d2f57600080fd5b614d37614a05565b905081358152614d4960208301614cf3565b6020820152614d5a60408301614cc6565b6040820152614d6b60608301614cf3565b6060820152614d7c60808301614876565b6080820152614d8d60a083016148bc565b60a0820152614d9e60c08301614aa1565b60c0820152614daf60e08301614aa1565b60e0820152610100614dc2818401614d11565b90820152610120614dd4838201614d11565b90820152610140614de68382016148bc565b9082015292915050565b6000806000806000806102008789031215614e0a57600080fd5b863567ffffffffffffffff80821115614e2257600080fd5b614e2e8a838b01614c1e565b97506020890135915080821115614e4457600080fd5b50614e5189828a01614c1e565b9550506040870135614e6281614cac565b93506060870135614e7281614cac565b92506080870135614e8281614cd1565b9150614e918860a08901614d1c565b90509295509295509295565b60078110614ed4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614ee68285614e9d565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614f1257600080fd5b81356020614f22614af183614aac565b82815260059290921b84018101918181019086841115614f4157600080fd5b8286015b84811015614b39578035614f5881614cd1565b8352918301918301614f45565b60008060408385031215614f7857600080fd5b823567ffffffffffffffff80821115614f9057600080fd5b818501915085601f830112614fa457600080fd5b81356020614fb4614af183614aac565b82815260059290921b84018101918181019089841115614fd357600080fd5b948201945b83861015614ff157853582529482019490820190614fd8565b9650508601359250508082111561500757600080fd5b5061501485828601614f01565b9150509250929050565b60008083601f84011261503057600080fd5b50813567ffffffffffffffff81111561504857600080fd5b60208301915083602082850101111561506057600080fd5b9250929050565b60008060008060008060a0878903121561508057600080fd5b863561508b81614860565b9550602087013567ffffffffffffffff8111156150a757600080fd5b6150b389828a0161501e565b90965094506150c6905060408801614a78565b925060608701356150d6816148aa565b80925050608087013590509295509295509295565b600080604083850312156150fe57600080fd5b823561510981614860565b915060208301356148f581614cd1565b6000806040838503121561512c57600080fd5b823561513781614cd1565b915060208301356148f581614cac565b6000806040838503121561515a57600080fd5b823561516581614cd1565b915060208301356148f581614860565b60006020828403121561518757600080fd5b5035919050565b600081518084526020808501945080840160005b838110156151d457815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016151a2565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261525160e084018261518e565b905060a084015160c08401528091505092915050565b6000806000806060858703121561527d57600080fd5b843561528881614cd1565b935060208501359250604085013567ffffffffffffffff8111156152ab57600080fd5b6152b78782880161501e565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b828110156152fc578151845292840192908401906001016152e0565b50505083810382850152615310818661518e565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614b3957835163ffffffff16825292840192600192909201919084019061539e565b6000602082840312156153d657600080fd5b81356148a381614cd1565b600080602083850312156153f457600080fd5b823567ffffffffffffffff8082111561540c57600080fd5b818501915085601f83011261542057600080fd5b81358181111561542f57600080fd5b8660206101608302850101111561544557600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016144d16040830184614e9d565b815181526020808301516101608301916154e99084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161550960408401826bffffffffffffffffffffffff169052565b506060830151615531606084018273ffffffffffffffffffffffffffffffffffffffff169052565b50608083015161554d608084018267ffffffffffffffff169052565b5060a083015161556560a084018263ffffffff169052565b5060c083015161558260c084018268ffffffffffffffffff169052565b5060e083015161559f60e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff818116838216019080821115615632576156326155e5565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155dd576155dd6155e5565b6bffffffffffffffffffffffff818116838216019080821115615632576156326155e5565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff851660208201526156c06040820185614e9d565b60a0606082015260006156d660a0830185614924565b82810360808401526110838185614924565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203615719576157196155e5565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615632576156326155e5565b600060ff821660ff810361575b5761575b6155e5565b60010192915050565b818103818111156115e7576115e76155e5565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157c3576157c36155e5565b6001019392505050565b808201808211156115e7576115e76155e5565b6000602082840312156157f257600080fd5b5051919050565b6000610160828403121561580c57600080fd5b6148a38383614d1c565b60006020828403121561582857600080fd5b815180151581146148a357600080fd5b67ffffffffffffffff818116838216019080821115615632576156326155e5565b8381526060602082015260006158726060830185614924565b82810360408401526153108185614924565b60208152600082516101608060208501526158a3610180850183614924565b91506020850151604085015260408501516158d6606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e085015161010061594d8187018363ffffffff169052565b86015190506101206159648682018361ffff169052565b86015190506101406159818682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161488181614cd1565b805161488181614cac565b805161488181614860565b8051614881816148aa565b805161488181614a8a565b805161488181614cfe565b600061016082840312156159fc57600080fd5b615a04614a05565b82518152615a14602084016159a7565b6020820152615a25604084016159b2565b6040820152615a36606084016159a7565b6060820152615a47608084016159bd565b6080820152615a5860a084016159c8565b60a0820152615a6960c084016159d3565b60c0820152615a7a60e084016159d3565b60e0820152610100615a8d8185016159de565b90820152610120615a9f8482016159de565b90820152610140615ab18482016159c8565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615afd60e0830187614924565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006144d16040830184614924565b60008251615b75818460208701614900565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index bd9d0a4c0db..b17a4c2f911 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -6,7 +6,7 @@ functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClien functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 8c83f78cf96b47a52e51506b6176ac1860f37396e11e5ea6fa695bae43c58ba9 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 07345caa92457c3deb2483d120e3c26324e05a79c730870fa4ecf1834b00e67d +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 75df8bb3546c6a9aaa29f505e3ea6a1685afd2469e9ac24d1f88eadf33d8b2a0 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From ddd5c1720ef914508daeb57a92b6abf9ca3e5cca Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Mon, 7 Aug 2023 01:35:07 -0400 Subject: [PATCH 098/270] [Functions] (fix): cast fees to uint96 in _calculateCostEstimate (#10096) * (fix): cast fees to uint96 in _calculateCostEstimate * Regenerate gethwrappers * Use SafeCast to convert to uint96 --- .../functions/dev/1_0_0/FunctionsBilling.sol | 22 ++++++++++--------- .../functions_coordinator.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 3 files changed, 14 insertions(+), 12 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index 1892932202c..f9347317721 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -8,6 +8,8 @@ import {IFunctionsBilling} from "./interfaces/IFunctionsBilling.sol"; import {Routable} from "./Routable.sol"; import {FunctionsResponse} from "./libraries/FunctionsResponse.sol"; +import {SafeCast} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/SafeCast.sol"; + /** * @title Functions Billing contract * @notice Contract that calculates payment from users to the nodes of the Decentralized Oracle Network (DON). @@ -124,9 +126,10 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { return uint256(weiPerUnitLink); } - function _getJuelsPerGas(uint256 gasPriceGwei) private view returns (uint256) { + function _getJuelsPerGas(uint256 gasPriceGwei) private view returns (uint96) { // (1e18 juels/link) * (wei/gas) / (wei/link) = juels per gas - return (1e18 * gasPriceGwei) / getWeiPerUnitLink(); + // There are only 1e9*1e18 = 1e27 juels in existence, should not exceed uint96 (2^96 ~ 7e28) + return SafeCast.toUint96((1e18 * gasPriceGwei) / getWeiPerUnitLink()); } // ================================================================ @@ -165,11 +168,11 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { ((gasPriceGwei * s_config.fulfillmentGasPriceOverEstimationBP) / 10_000); // @NOTE: Basis Points are 1/100th of 1%, divide by 10_000 to bring back to original units - uint256 juelsPerGas = _getJuelsPerGas(gasPriceWithOverestimation); + uint96 juelsPerGas = _getJuelsPerGas(gasPriceWithOverestimation); uint256 estimatedGasReimbursement = juelsPerGas * executionGas; - uint96 fees = donFee + adminFee; + uint96 fees = uint96(donFee) + uint96(adminFee); - return uint96(estimatedGasReimbursement + fees); + return SafeCast.toUint96(estimatedGasReimbursement + fees); } // ================================================================ @@ -266,17 +269,16 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { return FunctionsResponse.FulfillResult.INVALID_REQUEST_ID; } - uint256 juelsPerGas = _getJuelsPerGas(tx.gasprice); + uint96 juelsPerGas = _getJuelsPerGas(tx.gasprice); // Gas overhead without callback - uint96 gasOverheadJuels = uint96( - juelsPerGas * (commitment.gasOverheadBeforeCallback + commitment.gasOverheadAfterCallback) - ); + uint96 gasOverheadJuels = juelsPerGas * + (commitment.gasOverheadBeforeCallback + commitment.gasOverheadAfterCallback); // The Functions Router will perform the callback to the client contract (FunctionsResponse.FulfillResult resultCode, uint96 callbackCostJuels) = _getRouter().fulfill( response, err, - uint96(juelsPerGas), + juelsPerGas, gasOverheadJuels + commitment.donFee, // costWithoutFulfillment msg.sender, commitment diff --git a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go index a0bb7ef2420..3de584ddb22 100644 --- a/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go +++ b/core/gethwrappers/functions/generated/functions_coordinator/functions_coordinator.go @@ -72,7 +72,7 @@ type FunctionsResponseRequestMeta struct { var FunctionsCoordinatorMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address\",\"name\":\"linkToNativeFeed\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyPublicKey\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InconsistentReportData\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"message\",\"type\":\"string\"}],\"name\":\"InvalidConfig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoTransmittersSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByRouterOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReportInvalid\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RouterMustBeSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedPublicKeyChange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnauthorizedSender\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UnsupportedRequestDataVersion\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"CommitmentDeleted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"indexed\":false,\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"callbackGasLimit\",\"type\":\"uint64\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"OracleRequest\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"OracleResponse\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"deleteCommitment\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"}],\"name\":\"deleteNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"gasPriceGwei\",\"type\":\"uint256\"}],\"name\":\"estimateCost\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllNodePublicKeys\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes[]\",\"name\":\"\",\"type\":\"bytes[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"getDONFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getDONPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getThresholdPublicKey\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"oracleWithdrawAll\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"_transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"donPublicKey\",\"type\":\"bytes\"}],\"name\":\"setDONPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"node\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"publicKey\",\"type\":\"bytes\"}],\"name\":\"setNodePublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"thresholdPublicKey\",\"type\":\"bytes\"}],\"name\":\"setThresholdPublicKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"availableBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"}],\"internalType\":\"structFunctionsResponse.RequestMeta\",\"name\":\"request\",\"type\":\"tuple\"}],\"name\":\"startRequest\",\"outputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"transmitters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"maxCallbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"feedStalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"requestTimeoutSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint16\",\"name\":\"maxSupportedRequestDataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentGasPriceOverEstimationBP\",\"type\":\"uint32\"},{\"internalType\":\"uint224\",\"name\":\"fallbackNativePerUnitLink\",\"type\":\"uint224\"}],\"internalType\":\"structFunctionsBilling.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60c06040523480156200001157600080fd5b50604051620056553803806200565583398101604081905262000034916200044f565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600b80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b50505050505062000600565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f56200033a565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a166001600160401b031990981697909717640100000000968a16870217600160401b600160801b03191668010000000000000000948a169490940263ffffffff60601b1916939093176c010000000000000000000000009289169290920291909117600160801b600160e81b031916600160801b91881691909102600160a01b600160e81b03191617600160a01b6001600160481b03909216919091021761ffff60e81b1916600160e81b61ffff909416939093029290921790925560e084015161010085015193166001600160e01b0390931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c906200032f90839062000558565b60405180910390a150565b6200034462000346565b565b6000546001600160a01b03163314620003445760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003ba57600080fd5b919050565b60405161012081016001600160401b0381118282101715620003f157634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003ba57600080fd5b80516001600160481b0381168114620003ba57600080fd5b805161ffff81168114620003ba57600080fd5b80516001600160e01b0381168114620003ba57600080fd5b60008060008385036101608112156200046757600080fd5b6200047285620003a2565b935061012080601f19830112156200048957600080fd5b62000493620003bf565b9150620004a360208701620003f7565b8252620004b360408701620003f7565b6020830152620004c660608701620003f7565b6040830152620004d960808701620003f7565b6060830152620004ec60a08701620003f7565b6080830152620004ff60c087016200040c565b60a08301526200051260e0870162000424565b60c083015261010062000527818801620003f7565b60e08401526200053982880162000437565b908301525091506200054f6101408501620003a2565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005b760a08401826001600160481b03169052565b5060c0830151620005ce60c084018261ffff169052565b5060e0830151620005e760e084018263ffffffff169052565b50610100928301516001600160e01b0316919092015290565b60805160a051615005620006506000396000818161090901528181610cbe01528181610eec015281816112360152818161136d01528181611b57015261367d0152600061159501526150056000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381f1b938116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146105a3578063e3d0e712146105ab578063e4ddcea6146105be578063f2fde38b146105d457600080fd5b8063b1dc65a41461040e578063c3f909d414610421578063d227d2451461057357600080fd5b80638da5cb5b116100c85780638da5cb5b146103a6578063a631571e146103ce578063afcb95d7146103ee57600080fd5b806381f1b9381461030e57806381ff70481461031657806385b214cf1461038357600080fd5b806359b5b7ac1161015b5780637d480787116101355780637d480787146102cb5780637f15e166146102d357806380756031146102e657806381411834146102f957600080fd5b806359b5b7ac1461027857806366316d8d146102b057806379ba5097146102c357600080fd5b806326ceabac1161018c57806326ceabac1461022d5780632a905ccc14610240578063533989871461026257600080fd5b8063083a5466146101b3578063181f5a77146101c85780631bdf7f1b1461021a575b600080fd5b6101c66101c136600461391e565b6105e7565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b60405161021191906139c4565b60405180910390f35b6101c6610228366004613b27565b61063c565b6101c661023b366004613c0a565b61085f565b610248610905565b60405168ffffffffffffffffff9091168152602001610211565b61026a61099b565b604051610211929190613c78565b610248610286366004613d96565b5060085474010000000000000000000000000000000000000000900468ffffffffffffffffff1690565b6101c66102be366004613df8565b610bc2565b6101c6610d7b565b6101c6610e7d565b6101c66102e136600461391e565b610fd5565b6101c66102f4366004613e31565b611025565b6103016110dc565b6040516102119190613e86565b61020461114b565b61036060015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b610396610391366004613e99565b61121c565b6040519015158152602001610211565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6103e16103dc366004613eb2565b6112fc565b6040516102119190614011565b604080516001815260006020820181905291810191909152606001610211565b6101c661041c366004614065565b61149c565b6105666040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff1660c083015260095490811660e0830152919091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010082015290565b604051610211919061411c565b6105866105813660046141ff565b611b53565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611cb2565b6101c66105b9366004614318565b611d09565b6105c6612735565b604051908152602001610211565b6101c66105e2366004613c0a565b612966565b6105ef612977565b600081900361062a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e61063782848361447e565b505050565b6106446129fa565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a167fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000090981697909717640100000000968a168702177fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff1668010000000000000000948a16949094027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff16939093176c0100000000000000000000000092891692909202919091177fffffff00000000000000000000000000ffffffffffffffffffffffffffffffff16700100000000000000000000000000000000918816919091027fffffff000000000000000000ffffffffffffffffffffffffffffffffffffffff16177401000000000000000000000000000000000000000068ffffffffffffffffff90921691909102177fff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167d01000000000000000000000000000000000000000000000000000000000061ffff909416939093029290921790925560e084015161010085015193167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c9061085490839061411c565b60405180910390a150565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061089d57503373ffffffffffffffffffffffffffffffffffffffff821614155b156108d4576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d6020526040812061090291613863565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610972573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061099691906145a4565b905090565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a0357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109d8575b505050505090506000815167ffffffffffffffff811115610a2657610a266139de565b604051908082528060200260200182016040528015610a5957816020015b6060815260200190600190039081610a445790505b50905060005b8251811015610bb8576000600d6000858481518110610a8057610a806145c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610acd906143e5565b80601f0160208091040260200160405190810160405280929190818152602001828054610af9906143e5565b8015610b465780601f10610b1b57610100808354040283529160200191610b46565b820191906000526020600020905b815481529060010190602001808311610b2957829003601f168201915b505050505090508051600003610b88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610b9b57610b9b6145c1565b60200260200101819052505080610bb19061461f565b9050610a5f565b5090939092509050565b610bca612a02565b806bffffffffffffffffffffffff16600003610c045750336000908152600a60205260409020546bffffffffffffffffffffffff16610c5e565b336000908152600a60205260409020546bffffffffffffffffffffffff80831691161015610c5e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600a602052604081208054839290610c8b9084906bffffffffffffffffffffffff16614657565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ce07f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610d5f57600080fd5b505af1158015610d73573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610e01576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610e856129fa565b610e8d612a02565b6000610e976110dc565b905060005b8151811015610fd157336000908152600a6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610f3857610f386145c1565b6020026020010151836040518363ffffffff1660e01b8152600401610f8d92919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610fa757600080fd5b505af1158015610fbb573d6000803e3d6000fd5b505050505080610fca9061461f565b9050610e9c565b5050565b610fdd612977565b6000819003611018576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c61063782848361447e565b60005473ffffffffffffffffffffffffffffffffffffffff16331480611070575061104f33612bad565b801561107057503373ffffffffffffffffffffffffffffffffffffffff8416145b6110a6576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d602052604090206110d682848361447e565b50505050565b6060600680548060200260200160405190810160405280929190818152602001828054801561114157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611116575b5050505050905090565b6060600e805461115a906143e5565b9050600003611195576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e80546111a2906143e5565b80601f01602080910402602001604051908101604052809291908181526020018280546111ce906143e5565b80156111415780601f106111f057610100808354040283529160200191611141565b820191906000526020600020905b8154815290600101906020018083116111fe57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461128d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600760205260409020546112a857506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906112eb9084815260200190565b60405180910390a15060015b919050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146113c4576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6113d56113d08361467c565b612c96565b90506113e76060830160408401613c0a565b815173ffffffffffffffffffffffffffffffffffffffff91909116907fbf50768ccf13bd0110ca6d53a9c4f1f3271abdd4c24a56878863ed25b20598ff3261143560c0870160a08801614769565b61144761016088016101408901613c0a565b6114518880614786565b6114636101208b016101008c016147eb565b60208b01356114796101008d0160e08e01614806565b8b60405161148f99989796959493929190614823565b60405180910390a3919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611583576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610df8565b6115918b8b8b8b8b8b6130a6565b60007f0000000000000000000000000000000000000000000000000000000000000000156115ee576002826020015183604001516115cf91906148cb565b6115d99190614913565b6115e49060016148cb565b60ff169050611604565b60208201516115fe9060016148cb565b60ff1690505b88811461166d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610df8565b8887146116d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610df8565b3360009081526004602090815260408083208151808301909252805460ff8082168452929391929184019161010090910416600281111561171957611719614935565b600281111561172a5761172a614935565b905250905060028160200151600281111561174757611747614935565b14801561178e57506006816000015160ff1681548110611769576117696145c1565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6117f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610df8565b505050505061180161389d565b6000808a8a604051611814929190614964565b60405190819003812061182b918e90602001614974565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b35576000600184898460208110611894576118946145c1565b6118a191901a601b6148cb565b8e8e868181106118b3576118b36145c1565b905060200201358d8d878181106118cc576118cc6145c1565b9050602002013560405160008152602001604052604051611909949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561192b573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119ab576119ab614935565b60028111156119bc576119bc614935565b90525092506001836020015160028111156119d9576119d9614935565b14611a40576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610df8565b8251600090879060ff16601f8110611a5a57611a5a6145c1565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611adc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610df8565b8086846000015160ff16601f8110611af657611af66145c1565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b216001866148cb565b94505080611b2e9061461f565b9050611875565b505050611b46833383858e8e61315d565b5050505050505050505050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bf357600080fd5b505afa158015611c07573d6000803e3d6000fd5b505050620f42408311159050611c49576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c53610905565b90506000611c9687878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061028692505050565b9050611ca48585838561332b565b925050505b95945050505050565b6060600c8054611cc1906143e5565b9050600003611cfc576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c80546111a2906143e5565b855185518560ff16601f831115611d7c576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610df8565b80600003611de6576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610df8565b818314611e74576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610df8565b611e7f816003614988565b8311611ee7576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610df8565b611eef612977565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f3690886133ee565b600554156120eb57600554600090611f509060019061499f565b9050600060058281548110611f6757611f676145c1565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fa157611fa16145c1565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090811690915592909116808452922080549091169055600580549192509080612021576120216149b2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061208a5761208a6149b2565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f36915050565b60005b8151518110156125525760006004600084600001518481518110612114576121146145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215e5761215e614935565b146121c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610df8565b6040805180820190915260ff821681526001602082015282518051600491600091859081106121f6576121f66145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561229757612297614935565b0217905550600091506122a79050565b60046000846020015184815181106122c1576122c16145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230b5761230b614935565b14612372576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610df8565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123a5576123a56145c1565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000161761010083600281111561244657612446614935565b021790555050825180516005925083908110612464576124646145c1565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124e0576124e06145c1565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061254a8161461f565b9150506120ee565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161260a918491740100000000000000000000000000000000000000009004166149e1565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126694630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a00151613407565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612720988b9891977401000000000000000000000000000000000000000090920463ffffffff169690959194919391926149fe565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216848601526c010000000000000000000000008084048316606086015270010000000000000000000000000000000084048316608086015274010000000000000000000000000000000000000000840468ffffffffffffffffff1660a0808701919091527d01000000000000000000000000000000000000000000000000000000000090940461ffff1660c086015260095492831660e086015291047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16610100840152600b5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa15801561289a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128be9190614aae565b5093505092505080426128d1919061499f565b836020015163ffffffff161080156128f357506000836020015163ffffffff16115b1561292257505061010001517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16919050565b6000821361295f576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610df8565b5092915050565b61296e612977565b610902816134b2565b60005473ffffffffffffffffffffffffffffffffffffffff1633146129f8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610df8565b565b6129f8612977565b600b546bffffffffffffffffffffffff16600003612a1c57565b6000612a266110dc565b90508051600003612a63576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600b54600091612a82916bffffffffffffffffffffffff16614afe565b905060005b8251811015612b4e5781600a6000858481518110612aa757612aa76145c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612b0f9190614b29565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612b479061461f565b9050612a87565b508151612b5b9082614b4e565b600b8054600090612b7b9084906bffffffffffffffffffffffff16614657565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612c1357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612be8575b5050505050905060005b8151811015612c8c578373ffffffffffffffffffffffffffffffffffffffff16828281518110612c4f57612c4f6145c1565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612c7c575060019392505050565b612c858161461f565b9050612c1d565b5060009392505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff90811660c0840181905260095492831660e0850152939091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010080840191909152850151919291161115612e2b576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60085460009074010000000000000000000000000000000000000000900468ffffffffffffffffff1690506000612e6c8560e001513a84886080015161332b565b9050806bffffffffffffffffffffffff1685606001516bffffffffffffffffffffffff161015612ec8576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612f4b3087604001518860a001518960c001516001612ee99190614b76565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808281526020013073ffffffffffffffffffffffffffffffffffffffff168152602001836bffffffffffffffffffffffff168152602001876040015173ffffffffffffffffffffffffffffffffffffffff1681526020018760a0015167ffffffffffffffff1681526020018760e0015163ffffffff168152602001876080015168ffffffffffffffffff1681526020018468ffffffffffffffffff168152602001856040015163ffffffff1664ffffffffff168152602001856060015163ffffffff1664ffffffffff168152602001856080015163ffffffff164261303d9190614b97565b63ffffffff168152509450846040516020016130599190614011565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260079092529091205550919392505050565b60006130b3826020614988565b6130be856020614988565b6130ca88610144614b97565b6130d49190614b97565b6130de9190614b97565b6130e9906000614b97565b9050368114613154576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610df8565b50505050505050565b60608080808061316f86880188614c85565b845194995092975090955093509150158061318c57508351855114155b8061319957508251855114155b806131a657508151855114155b806131b357508051855114155b156131ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561331d57600061328287838151811061320d5761320d6145c1565b6020026020010151878481518110613227576132276145c1565b6020026020010151878581518110613241576132416145c1565b602002602001015187868151811061325b5761325b6145c1565b6020026020010151878781518110613275576132756145c1565b60200260200101516135a7565b9050600081600681111561329857613298614935565b14806132b5575060018160068111156132b3576132b3614935565b145b1561330c578682815181106132cc576132cc6145c1565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b506133168161461f565b90506131ed565b505050505050505050505050565b600854600090819086906133639063ffffffff6c010000000000000000000000008204811691680100000000000000009004166149e1565b61336d91906149e1565b60095463ffffffff91821692506000916127109161338c911688614988565b6133969190614d57565b6133a09087614b97565b905060006133ad82613837565b905060006133bb8483614988565b905060006133c98789614d6b565b68ffffffffffffffffff1690506133e08183614b97565b9a9950505050505050505050565b60006133f86110dc565b511115610fd157610fd1612a02565b6000808a8a8a8a8a8a8a8a8a60405160200161342b99989796959493929190614d8d565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613531576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610df8565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906135be9190614e63565b9050806040516020016135d19190614011565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a8152600790935291205414613623576006915050611ca9565b600087815260076020526040902054613640576002915050611ca9565b600061364b3a613837565b905060008261012001518361010001516136659190614f2b565b6136769064ffffffffff1683614988565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663330605298b8b878960e0015168ffffffffffffffffff16886136d59190614b29565b338b6040518763ffffffff1660e01b81526004016136f896959493929190614f49565b60408051808303816000875af1158015613716573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061373a9190614fc5565b9092509050600082600681111561375357613753614935565b14806137705750600182600681111561376e5761376e614935565b145b156138295760008b81526007602052604081205561378e8184614b29565b336000908152600a6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560e0870151600b805468ffffffffffffffffff909216939092916137fa91859116614b29565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b6000613841612735565b61385383670de0b6b3a7640000614988565b61385d9190614d57565b92915050565b50805461386f906143e5565b6000825580601f1061387f575050565b601f01602090049060005260206000209081019061090291906138bc565b604051806103e00160405280601f906020820280368337509192915050565b5b808211156138d157600081556001016138bd565b5090565b60008083601f8401126138e757600080fd5b50813567ffffffffffffffff8111156138ff57600080fd5b60208301915083602082850101111561391757600080fd5b9250929050565b6000806020838503121561393157600080fd5b823567ffffffffffffffff81111561394857600080fd5b613954858286016138d5565b90969095509350505050565b6000815180845260005b818110156139865760208185018101518683018201520161396a565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006139d76020830184613960565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610120810167ffffffffffffffff81118282101715613a3157613a316139de565b60405290565b604051610160810167ffffffffffffffff81118282101715613a3157613a316139de565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613aa257613aa26139de565b604052919050565b63ffffffff8116811461090257600080fd5b80356112f781613aaa565b68ffffffffffffffffff8116811461090257600080fd5b80356112f781613ac7565b803561ffff811681146112f757600080fd5b80357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff811681146112f757600080fd5b60006101208284031215613b3a57600080fd5b613b42613a0d565b613b4b83613abc565b8152613b5960208401613abc565b6020820152613b6a60408401613abc565b6040820152613b7b60608401613abc565b6060820152613b8c60808401613abc565b6080820152613b9d60a08401613ade565b60a0820152613bae60c08401613ae9565b60c0820152613bbf60e08401613abc565b60e0820152610100613bd2818501613afb565b908201529392505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461090257600080fd5b80356112f781613bdd565b600060208284031215613c1c57600080fd5b81356139d781613bdd565b600081518084526020808501945080840160005b83811015613c6d57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613c3b565b509495945050505050565b604081526000613c8b6040830185613c27565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613cf9577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613ce7838351613960565b94860194925090850190600101613cad565b50909998505050505050505050565b600082601f830112613d1957600080fd5b813567ffffffffffffffff811115613d3357613d336139de565b613d6460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613a5b565b818152846020838601011115613d7957600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613da857600080fd5b813567ffffffffffffffff811115613dbf57600080fd5b613dcb84828501613d08565b949350505050565b6bffffffffffffffffffffffff8116811461090257600080fd5b80356112f781613dd3565b60008060408385031215613e0b57600080fd5b8235613e1681613bdd565b91506020830135613e2681613dd3565b809150509250929050565b600080600060408486031215613e4657600080fd5b8335613e5181613bdd565b9250602084013567ffffffffffffffff811115613e6d57600080fd5b613e79868287016138d5565b9497909650939450505050565b6020815260006139d76020830184613c27565b600060208284031215613eab57600080fd5b5035919050565b600060208284031215613ec457600080fd5b813567ffffffffffffffff811115613edb57600080fd5b820161016081850312156139d757600080fd5b805182526020810151613f19602084018273ffffffffffffffffffffffffffffffffffffffff169052565b506040810151613f3960408401826bffffffffffffffffffffffff169052565b506060810151613f61606084018273ffffffffffffffffffffffffffffffffffffffff169052565b506080810151613f7d608084018267ffffffffffffffff169052565b5060a0810151613f9560a084018263ffffffff169052565b5060c0810151613fb260c084018268ffffffffffffffffff169052565b5060e0810151613fcf60e084018268ffffffffffffffffff169052565b506101008181015164ffffffffff81168483015250506101208181015164ffffffffff81168483015250506101408181015163ffffffff8116848301526110d6565b610160810161385d8284613eee565b60008083601f84011261403257600080fd5b50813567ffffffffffffffff81111561404a57600080fd5b6020830191508360208260051b850101111561391757600080fd5b60008060008060008060008060e0898b03121561408157600080fd5b606089018a81111561409257600080fd5b8998503567ffffffffffffffff808211156140ac57600080fd5b6140b88c838d016138d5565b909950975060808b01359150808211156140d157600080fd5b6140dd8c838d01614020565b909750955060a08b01359150808211156140f657600080fd5b506141038b828c01614020565b999c989b50969995989497949560c00135949350505050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161417c60a084018268ffffffffffffffffff169052565b5060c083015161419260c084018261ffff169052565b5060e08301516141aa60e084018263ffffffff169052565b50610100838101517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8116848301525b505092915050565b67ffffffffffffffff8116811461090257600080fd5b80356112f7816141de565b60008060008060006080868803121561421757600080fd5b8535614222816141de565b9450602086013567ffffffffffffffff81111561423e57600080fd5b61424a888289016138d5565b909550935050604086013561425e81613aaa565b949793965091946060013592915050565b600067ffffffffffffffff821115614289576142896139de565b5060051b60200190565b600082601f8301126142a457600080fd5b813560206142b96142b48361426f565b613a5b565b82815260059290921b840181019181810190868411156142d857600080fd5b8286015b848110156142fc5780356142ef81613bdd565b83529183019183016142dc565b509695505050505050565b803560ff811681146112f757600080fd5b60008060008060008060c0878903121561433157600080fd5b863567ffffffffffffffff8082111561434957600080fd5b6143558a838b01614293565b9750602089013591508082111561436b57600080fd5b6143778a838b01614293565b965061438560408a01614307565b9550606089013591508082111561439b57600080fd5b6143a78a838b01613d08565b94506143b560808a016141f4565b935060a08901359150808211156143cb57600080fd5b506143d889828a01613d08565b9150509295509295509295565b600181811c908216806143f957607f821691505b602082108103614432577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561063757600081815260208120601f850160051c8101602086101561445f5750805b601f850160051c820191505b81811015610d735782815560010161446b565b67ffffffffffffffff831115614496576144966139de565b6144aa836144a483546143e5565b83614438565b6000601f8411600181146144fc57600085156144c65750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b178355614592565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561454b578685013582556020948501946001909201910161452b565b5086821015614586577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b80516112f781613ac7565b6000602082840312156145b657600080fd5b81516139d781613ac7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614650576146506145f0565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561295f5761295f6145f0565b6000610160823603121561468f57600080fd5b614697613a37565b823567ffffffffffffffff8111156146ae57600080fd5b6146ba36828601613d08565b825250602083013560208201526146d360408401613bff565b60408201526146e460608401613ded565b60608201526146f560808401613ade565b608082015261470660a084016141f4565b60a082015261471760c084016141f4565b60c082015261472860e08401613abc565b60e082015261010061473b818501613ae9565b9082015261012061474d8482016141f4565b9082015261014061475f848201613bff565b9082015292915050565b60006020828403121561477b57600080fd5b81356139d7816141de565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe18436030181126147bb57600080fd5b83018035915067ffffffffffffffff8211156147d657600080fd5b60200191503681900382131561391757600080fd5b6000602082840312156147fd57600080fd5b6139d782613ae9565b60006020828403121561481857600080fd5b81356139d781613aaa565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a166020830152881660408201526102406060820181905281018690526000610260878982850137600083890182015261ffff8716608084015260a0830186905263ffffffff851660c0840152601f88017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01683010190506133e060e0830184613eee565b60ff818116838216019081111561385d5761385d6145f0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff831680614926576149266148e4565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b808202811582820484141761385d5761385d6145f0565b8181038181111561385d5761385d6145f0565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561295f5761295f6145f0565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614a2e8184018a613c27565b90508281036080840152614a428189613c27565b905060ff871660a084015282810360c0840152614a5f8187613960565b905067ffffffffffffffff851660e0840152828103610100840152614a848185613960565b9c9b505050505050505050505050565b805169ffffffffffffffffffff811681146112f757600080fd5b600080600080600060a08688031215614ac657600080fd5b614acf86614a94565b9450602086015193506040860151925060608601519150614af260808701614a94565b90509295509295909350565b60006bffffffffffffffffffffffff80841680614b1d57614b1d6148e4565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561295f5761295f6145f0565b6bffffffffffffffffffffffff8181168382160280821691908281146141d6576141d66145f0565b67ffffffffffffffff81811683821601908082111561295f5761295f6145f0565b8082018082111561385d5761385d6145f0565b600082601f830112614bbb57600080fd5b81356020614bcb6142b48361426f565b82815260059290921b84018101918181019086841115614bea57600080fd5b8286015b848110156142fc5780358352918301918301614bee565b600082601f830112614c1657600080fd5b81356020614c266142b48361426f565b82815260059290921b84018101918181019086841115614c4557600080fd5b8286015b848110156142fc57803567ffffffffffffffff811115614c695760008081fd5b614c778986838b0101613d08565b845250918301918301614c49565b600080600080600060a08688031215614c9d57600080fd5b853567ffffffffffffffff80821115614cb557600080fd5b614cc189838a01614baa565b96506020880135915080821115614cd757600080fd5b614ce389838a01614c05565b95506040880135915080821115614cf957600080fd5b614d0589838a01614c05565b94506060880135915080821115614d1b57600080fd5b614d2789838a01614c05565b93506080880135915080821115614d3d57600080fd5b50614d4a88828901614c05565b9150509295509295909350565b600082614d6657614d666148e4565b500490565b68ffffffffffffffffff81811683821601908082111561295f5761295f6145f0565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614dd48285018b613c27565b91508382036080850152614de8828a613c27565b915060ff881660a085015283820360c0850152614e058288613960565b90861660e08501528381036101008501529050614a848185613960565b80516112f781613bdd565b80516112f781613dd3565b80516112f7816141de565b80516112f781613aaa565b805164ffffffffff811681146112f757600080fd5b60006101608284031215614e7657600080fd5b614e7e613a37565b82518152614e8e60208401614e22565b6020820152614e9f60408401614e2d565b6040820152614eb060608401614e22565b6060820152614ec160808401614e38565b6080820152614ed260a08401614e43565b60a0820152614ee360c08401614599565b60c0820152614ef460e08401614599565b60e0820152610100614f07818501614e4e565b90820152610120614f19848201614e4e565b90820152610140613bd2848201614e43565b64ffffffffff81811683821601908082111561295f5761295f6145f0565b6000610200808352614f5d8184018a613960565b90508281036020840152614f718189613960565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150614fba905060a0830184613eee565b979650505050505050565b60008060408385031215614fd857600080fd5b825160078110614fe757600080fd5b6020840151909250613e2681613dd356fea164736f6c6343000813000a", + Bin: "0x60c06040523480156200001157600080fd5b50604051620056fb380380620056fb83398101604081905262000034916200044f565b8282828260013380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000140565b50505015156080526001600160a01b038116620000f457604051632530e88560e11b815260040160405180910390fd5b6001600160a01b0390811660a052600b80549183166c01000000000000000000000000026001600160601b039092169190911790556200013482620001eb565b50505050505062000600565b336001600160a01b038216036200019a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b620001f56200033a565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a166001600160401b031990981697909717640100000000968a16870217600160401b600160801b03191668010000000000000000948a169490940263ffffffff60601b1916939093176c010000000000000000000000009289169290920291909117600160801b600160e81b031916600160801b91881691909102600160a01b600160e81b03191617600160a01b6001600160481b03909216919091021761ffff60e81b1916600160e81b61ffff909416939093029290921790925560e084015161010085015193166001600160e01b0390931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c906200032f90839062000558565b60405180910390a150565b6200034462000346565b565b6000546001600160a01b03163314620003445760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000088565b80516001600160a01b0381168114620003ba57600080fd5b919050565b60405161012081016001600160401b0381118282101715620003f157634e487b7160e01b600052604160045260246000fd5b60405290565b805163ffffffff81168114620003ba57600080fd5b80516001600160481b0381168114620003ba57600080fd5b805161ffff81168114620003ba57600080fd5b80516001600160e01b0381168114620003ba57600080fd5b60008060008385036101608112156200046757600080fd5b6200047285620003a2565b935061012080601f19830112156200048957600080fd5b62000493620003bf565b9150620004a360208701620003f7565b8252620004b360408701620003f7565b6020830152620004c660608701620003f7565b6040830152620004d960808701620003f7565b6060830152620004ec60a08701620003f7565b6080830152620004ff60c087016200040c565b60a08301526200051260e0870162000424565b60c083015261010062000527818801620003f7565b60e08401526200053982880162000437565b908301525091506200054f6101408501620003a2565b90509250925092565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a0830151620005b760a08401826001600160481b03169052565b5060c0830151620005ce60c084018261ffff169052565b5060e0830151620005e760e084018263ffffffff169052565b50610100928301516001600160e01b0316919092015290565b60805160a0516150ab620006506000396000818161090901528181610cbe01528181610eec015281816112360152818161136d01528181611b5701526136a40152600061159501526150ab6000f3fe608060405234801561001057600080fd5b50600436106101ae5760003560e01c806381f1b938116100ee578063b1dc65a411610097578063d328a91e11610071578063d328a91e146105a3578063e3d0e712146105ab578063e4ddcea6146105be578063f2fde38b146105d457600080fd5b8063b1dc65a41461040e578063c3f909d414610421578063d227d2451461057357600080fd5b80638da5cb5b116100c85780638da5cb5b146103a6578063a631571e146103ce578063afcb95d7146103ee57600080fd5b806381f1b9381461030e57806381ff70481461031657806385b214cf1461038357600080fd5b806359b5b7ac1161015b5780637d480787116101355780637d480787146102cb5780637f15e166146102d357806380756031146102e657806381411834146102f957600080fd5b806359b5b7ac1461027857806366316d8d146102b057806379ba5097146102c357600080fd5b806326ceabac1161018c57806326ceabac1461022d5780632a905ccc14610240578063533989871461026257600080fd5b8063083a5466146101b3578063181f5a77146101c85780631bdf7f1b1461021a575b600080fd5b6101c66101c13660046139e6565b6105e7565b005b6102046040518060400160405280601c81526020017f46756e6374696f6e7320436f6f7264696e61746f722076312e302e300000000081525081565b6040516102119190613a8c565b60405180910390f35b6101c6610228366004613bef565b61063c565b6101c661023b366004613cd2565b61085f565b610248610905565b60405168ffffffffffffffffff9091168152602001610211565b61026a61099b565b604051610211929190613d40565b610248610286366004613e5e565b5060085474010000000000000000000000000000000000000000900468ffffffffffffffffff1690565b6101c66102be366004613ec0565b610bc2565b6101c6610d7b565b6101c6610e7d565b6101c66102e13660046139e6565b610fd5565b6101c66102f4366004613ef9565b611025565b6103016110dc565b6040516102119190613f4e565b61020461114b565b61036060015460025463ffffffff74010000000000000000000000000000000000000000830481169378010000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610211565b610396610391366004613f61565b61121c565b6040519015158152602001610211565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610211565b6103e16103dc366004613f7a565b6112fc565b60405161021191906140d9565b604080516001815260006020820181905291810191909152606001610211565b6101c661041c36600461412d565b61149c565b6105666040805161012081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081019190915250604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff1660c083015260095490811660e0830152919091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010082015290565b60405161021191906141e4565b6105866105813660046142c7565b611b53565b6040516bffffffffffffffffffffffff9091168152602001610211565b610204611cb2565b6101c66105b93660046143e0565b611d09565b6105c6612735565b604051908152602001610211565b6101c66105e2366004613cd2565b612966565b6105ef612977565b600081900361062a576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e610637828483614546565b505050565b6106446129fa565b80516008805460208401516040808601516060870151608088015160a089015160c08a015163ffffffff998a167fffffffffffffffffffffffffffffffffffffffffffffffff000000000000000090981697909717640100000000968a168702177fffffffffffffffffffffffffffffffff0000000000000000ffffffffffffffff1668010000000000000000948a16949094027fffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffffff16939093176c0100000000000000000000000092891692909202919091177fffffff00000000000000000000000000ffffffffffffffffffffffffffffffff16700100000000000000000000000000000000918816919091027fffffff000000000000000000ffffffffffffffffffffffffffffffffffffffff16177401000000000000000000000000000000000000000068ffffffffffffffffff90921691909102177fff0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167d01000000000000000000000000000000000000000000000000000000000061ffff909416939093029290921790925560e084015161010085015193167bffffffffffffffffffffffffffffffffffffffffffffffffffffffff90931690910291909117600955517f5b6e2e1a03ea742ce04ca36d0175411a0772f99ef4ee84aeb9868a1ef6ddc82c906108549083906141e4565b60405180910390a150565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061089d57503373ffffffffffffffffffffffffffffffffffffffff821614155b156108d4576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff81166000908152600d602052604081206109029161392f565b50565b60007f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16632a905ccc6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610972573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610996919061466c565b905090565b60608060006006805480602002602001604051908101604052809291908181526020018280548015610a0357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116109d8575b505050505090506000815167ffffffffffffffff811115610a2657610a26613aa6565b604051908082528060200260200182016040528015610a5957816020015b6060815260200190600190039081610a445790505b50905060005b8251811015610bb8576000600d6000858481518110610a8057610a80614689565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020019081526020016000208054610acd906144ad565b80601f0160208091040260200160405190810160405280929190818152602001828054610af9906144ad565b8015610b465780601f10610b1b57610100808354040283529160200191610b46565b820191906000526020600020905b815481529060010190602001808311610b2957829003601f168201915b505050505090508051600003610b88576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80838381518110610b9b57610b9b614689565b60200260200101819052505080610bb1906146e7565b9050610a5f565b5090939092509050565b610bca612a02565b806bffffffffffffffffffffffff16600003610c045750336000908152600a60205260409020546bffffffffffffffffffffffff16610c5e565b336000908152600a60205260409020546bffffffffffffffffffffffff80831691161015610c5e576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600a602052604081208054839290610c8b9084906bffffffffffffffffffffffff1661471f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550610ce07f000000000000000000000000000000000000000000000000000000000000000090565b6040517f66316d8d00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff84811660048301526bffffffffffffffffffffffff8416602483015291909116906366316d8d90604401600060405180830381600087803b158015610d5f57600080fd5b505af1158015610d73573d6000803e3d6000fd5b505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610e01576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610e856129fa565b610e8d612a02565b6000610e976110dc565b905060005b8151811015610fd157336000908152600a6020526040902080547fffffffffffffffffffffffffffffffffffffffff00000000000000000000000081169091556bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff166366316d8d848481518110610f3857610f38614689565b6020026020010151836040518363ffffffff1660e01b8152600401610f8d92919073ffffffffffffffffffffffffffffffffffffffff9290921682526bffffffffffffffffffffffff16602082015260400190565b600060405180830381600087803b158015610fa757600080fd5b505af1158015610fbb573d6000803e3d6000fd5b505050505080610fca906146e7565b9050610e9c565b5050565b610fdd612977565b6000819003611018576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c610637828483614546565b60005473ffffffffffffffffffffffffffffffffffffffff16331480611070575061104f33612bad565b801561107057503373ffffffffffffffffffffffffffffffffffffffff8416145b6110a6576040517fed6dd19b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152600d602052604090206110d6828483614546565b50505050565b6060600680548060200260200160405190810160405280929190818152602001828054801561114157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611116575b5050505050905090565b6060600e805461115a906144ad565b9050600003611195576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600e80546111a2906144ad565b80601f01602080910402602001604051908101604052809291908181526020018280546111ce906144ad565b80156111415780601f106111f057610100808354040283529160200191611141565b820191906000526020600020905b8154815290600101906020018083116111fe57509395945050505050565b60003373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461128d576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600760205260409020546112a857506000919050565b60008281526007602052604080822091909155517f8a4b97add3359bd6bcf5e82874363670eb5ad0f7615abddbd0ed0a3a98f0f416906112eb9084815260200190565b60405180910390a15060015b919050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e08101829052610100810182905261012081018290526101408101919091523373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146113c4576040517fc41a5b0900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6113d56113d083614744565b612c96565b90506113e76060830160408401613cd2565b815173ffffffffffffffffffffffffffffffffffffffff91909116907fbf50768ccf13bd0110ca6d53a9c4f1f3271abdd4c24a56878863ed25b20598ff3261143560c0870160a08801614831565b61144761016088016101408901613cd2565b611451888061484e565b6114636101208b016101008c016148b3565b60208b01356114796101008d0160e08e016148ce565b8b60405161148f999897969594939291906148eb565b60405180910390a3919050565b60005a604080518b3580825262ffffff6020808f0135600881901c929092169084015293945092917fb04e63db38c49950639fa09d29872f21f5d49d614f3a969d8adf3d4b52e41a62910160405180910390a16040805160608101825260025480825260035460ff80821660208501526101009091041692820192909252908314611583576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601560248201527f636f6e666967446967657374206d69736d6174636800000000000000000000006044820152606401610df8565b6115918b8b8b8b8b8b6130a6565b60007f0000000000000000000000000000000000000000000000000000000000000000156115ee576002826020015183604001516115cf9190614993565b6115d991906149db565b6115e4906001614993565b60ff169050611604565b60208201516115fe906001614993565b60ff1690505b88811461166d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601a60248201527f77726f6e67206e756d626572206f66207369676e6174757265730000000000006044820152606401610df8565b8887146116d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f7369676e617475726573206f7574206f6620726567697374726174696f6e00006044820152606401610df8565b3360009081526004602090815260408083208151808301909252805460ff80821684529293919291840191610100909104166002811115611719576117196149fd565b600281111561172a5761172a6149fd565b9052509050600281602001516002811115611747576117476149fd565b14801561178e57506006816000015160ff168154811061176957611769614689565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff1633145b6117f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f756e617574686f72697a6564207472616e736d697474657200000000000000006044820152606401610df8565b5050505050611801613969565b6000808a8a604051611814929190614a2c565b60405190819003812061182b918e90602001614a3c565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181528282528051602091820120838301909252600080845290830152915060005b89811015611b3557600060018489846020811061189457611894614689565b6118a191901a601b614993565b8e8e868181106118b3576118b3614689565b905060200201358d8d878181106118cc576118cc614689565b9050602002013560405160008152602001604052604051611909949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa15801561192b573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526004602090815290849020838501909452835460ff808216855292965092945084019161010090041660028111156119ab576119ab6149fd565b60028111156119bc576119bc6149fd565b90525092506001836020015160028111156119d9576119d96149fd565b14611a40576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601e60248201527f61646472657373206e6f7420617574686f72697a656420746f207369676e00006044820152606401610df8565b8251600090879060ff16601f8110611a5a57611a5a614689565b602002015173ffffffffffffffffffffffffffffffffffffffff1614611adc576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f6e6f6e2d756e69717565207369676e61747572650000000000000000000000006044820152606401610df8565b8086846000015160ff16601f8110611af657611af6614689565b73ffffffffffffffffffffffffffffffffffffffff9092166020929092020152611b21600186614993565b94505080611b2e906146e7565b9050611875565b505050611b46833383858e8e61315d565b5050505050505050505050565b60007f00000000000000000000000000000000000000000000000000000000000000006040517f10fc49c100000000000000000000000000000000000000000000000000000000815267ffffffffffffffff8816600482015263ffffffff8516602482015273ffffffffffffffffffffffffffffffffffffffff91909116906310fc49c19060440160006040518083038186803b158015611bf357600080fd5b505afa158015611c07573d6000803e3d6000fd5b505050620f42408311159050611c49576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000611c53610905565b90506000611c9687878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525061028692505050565b9050611ca48585838561332b565b925050505b95945050505050565b6060600c8054611cc1906144ad565b9050600003611cfc576040517f4f42be3d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600c80546111a2906144ad565b855185518560ff16601f831115611d7c576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f746f6f206d616e79207369676e657273000000000000000000000000000000006044820152606401610df8565b80600003611de6576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601260248201527f66206d75737420626520706f73697469766500000000000000000000000000006044820152606401610df8565b818314611e74576040517f89a61989000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f6f7261636c6520616464726573736573206f7574206f6620726567697374726160448201527f74696f6e000000000000000000000000000000000000000000000000000000006064820152608401610df8565b611e7f816003614a50565b8311611ee7576040517f89a6198900000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f6661756c74792d6f7261636c65206620746f6f206869676800000000000000006044820152606401610df8565b611eef612977565b6040805160c0810182528a8152602081018a905260ff89169181018290526060810188905267ffffffffffffffff8716608082015260a0810186905290611f369088613415565b600554156120eb57600554600090611f5090600190614a67565b9050600060058281548110611f6757611f67614689565b60009182526020822001546006805473ffffffffffffffffffffffffffffffffffffffff90921693509084908110611fa157611fa1614689565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff85811684526004909252604080842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00009081169091559290911680845292208054909116905560058054919250908061202157612021614a7a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055600680548061208a5761208a614a7a565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff000000000000000000000000000000000000000016905501905550611f36915050565b60005b815151811015612552576000600460008460000151848151811061211457612114614689565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561215e5761215e6149fd565b146121c5576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f7265706561746564207369676e657220616464726573730000000000000000006044820152606401610df8565b6040805180820190915260ff821681526001602082015282518051600491600091859081106121f6576121f6614689565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001617610100836002811115612297576122976149fd565b0217905550600091506122a79050565b60046000846020015184815181106122c1576122c1614689565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002054610100900460ff16600281111561230b5761230b6149fd565b14612372576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f7265706561746564207472616e736d69747465722061646472657373000000006044820152606401610df8565b6040805180820190915260ff8216815260208101600281525060046000846020015184815181106123a5576123a5614689565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040016000208251815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0082168117835592840151919283917fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001617610100836002811115612446576124466149fd565b02179055505082518051600592508390811061246457612464614689565b602090810291909101810151825460018101845560009384529282902090920180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff90931692909217909155820151805160069190839081106124e0576124e0614689565b60209081029190910181015182546001810184556000938452919092200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9092169190911790558061254a816146e7565b9150506120ee565b506040810151600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660ff909216919091179055600180547fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff8116780100000000000000000000000000000000000000000000000063ffffffff438116820292909217808555920481169291829160149161260a91849174010000000000000000000000000000000000000000900416614aa9565b92506101000a81548163ffffffff021916908363ffffffff1602179055506126694630600160149054906101000a900463ffffffff1663ffffffff16856000015186602001518760400151886060015189608001518a60a0015161342e565b600281905582518051600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1661010060ff9093169290920291909117905560015460208501516040808701516060880151608089015160a08a015193517f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0598612720988b9891977401000000000000000000000000000000000000000090920463ffffffff16969095919491939192614ac6565b60405180910390a15050505050505050505050565b604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216848601526c010000000000000000000000008084048316606086015270010000000000000000000000000000000084048316608086015274010000000000000000000000000000000000000000840468ffffffffffffffffff1660a0808701919091527d01000000000000000000000000000000000000000000000000000000000090940461ffff1660c086015260095492831660e086015291047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16610100840152600b5484517ffeaf968c00000000000000000000000000000000000000000000000000000000815294516000958694859490930473ffffffffffffffffffffffffffffffffffffffff169263feaf968c926004808401938290030181865afa15801561289a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128be9190614b76565b5093505092505080426128d19190614a67565b836020015163ffffffff161080156128f357506000836020015163ffffffff16115b1561292257505061010001517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff16919050565b6000821361295f576040517f43d4cf6600000000000000000000000000000000000000000000000000000000815260048101839052602401610df8565b5092915050565b61296e612977565b610902816134d9565b60005473ffffffffffffffffffffffffffffffffffffffff1633146129f8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610df8565b565b6129f8612977565b600b546bffffffffffffffffffffffff16600003612a1c57565b6000612a266110dc565b90508051600003612a63576040517f30274b3a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8051600b54600091612a82916bffffffffffffffffffffffff16614bc6565b905060005b8251811015612b4e5781600a6000858481518110612aa757612aa7614689565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff16815260200190815260200160002060008282829054906101000a90046bffffffffffffffffffffffff16612b0f9190614bf1565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080612b47906146e7565b9050612a87565b508151612b5b9082614c16565b600b8054600090612b7b9084906bffffffffffffffffffffffff1661471f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505050565b6000806006805480602002602001604051908101604052809291908181526020018280548015612c1357602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612be8575b5050505050905060005b8151811015612c8c578373ffffffffffffffffffffffffffffffffffffffff16828281518110612c4f57612c4f614689565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603612c7c575060019392505050565b612c85816146e7565b9050612c1d565b5060009392505050565b6040805161016081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e0810182905261010081018290526101208101829052610140810191909152604080516101208101825260085463ffffffff8082168352640100000000808304821660208501526801000000000000000083048216948401949094526c0100000000000000000000000082048116606084015270010000000000000000000000000000000082048116608084015274010000000000000000000000000000000000000000820468ffffffffffffffffff1660a08401527d01000000000000000000000000000000000000000000000000000000000090910461ffff90811660c0840181905260095492831660e0850152939091047bffffffffffffffffffffffffffffffffffffffffffffffffffffffff1661010080840191909152850151919291161115612e2b576040517fdada758700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60085460009074010000000000000000000000000000000000000000900468ffffffffffffffffff1690506000612e6c8560e001513a84886080015161332b565b9050806bffffffffffffffffffffffff1685606001516bffffffffffffffffffffffff161015612ec8576040517ff4d678b800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612f4b3087604001518860a001518960c001516001612ee99190614c3e565b6040805173ffffffffffffffffffffffffffffffffffffffff958616602080830191909152949095168582015267ffffffffffffffff928316606086015291166080808501919091528151808503909101815260a09093019052815191012090565b90506040518061016001604052808281526020013073ffffffffffffffffffffffffffffffffffffffff168152602001836bffffffffffffffffffffffff168152602001876040015173ffffffffffffffffffffffffffffffffffffffff1681526020018760a0015167ffffffffffffffff1681526020018760e0015163ffffffff168152602001876080015168ffffffffffffffffff1681526020018468ffffffffffffffffff168152602001856040015163ffffffff1664ffffffffff168152602001856060015163ffffffff1664ffffffffff168152602001856080015163ffffffff164261303d9190614c5f565b63ffffffff1681525094508460405160200161305991906140d9565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181528151602092830120600093845260079092529091205550919392505050565b60006130b3826020614a50565b6130be856020614a50565b6130ca88610144614c5f565b6130d49190614c5f565b6130de9190614c5f565b6130e9906000614c5f565b9050368114613154576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601860248201527f63616c6c64617461206c656e677468206d69736d6174636800000000000000006044820152606401610df8565b50505050505050565b60608080808061316f86880188614d4d565b845194995092975090955093509150158061318c57508351855114155b8061319957508251855114155b806131a657508151855114155b806131b357508051855114155b156131ea576040517f0be3632800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b855181101561331d57600061328287838151811061320d5761320d614689565b602002602001015187848151811061322757613227614689565b602002602001015187858151811061324157613241614689565b602002602001015187868151811061325b5761325b614689565b602002602001015187878151811061327557613275614689565b60200260200101516135ce565b90506000816006811115613298576132986149fd565b14806132b5575060018160068111156132b3576132b36149fd565b145b1561330c578682815181106132cc576132cc614689565b60209081029190910181015160405133815290917fc708e0440951fd63499c0f7a73819b469ee5dd3ecc356c0ab4eb7f18389009d9910160405180910390a25b50613316816146e7565b90506131ed565b505050505050505050505050565b600854600090819086906133639063ffffffff6c01000000000000000000000000820481169168010000000000000000900416614aa9565b61336d9190614aa9565b60095463ffffffff91821692506000916127109161338c911688614a50565b6133969190614e1f565b6133a09087614c5f565b905060006133ad8261385e565b905060006133c9846bffffffffffffffffffffffff8416614a50565b905060006133e568ffffffffffffffffff808916908a16614bf1565b90506134076134026bffffffffffffffffffffffff831684614c5f565b61388d565b9a9950505050505050505050565b600061341f6110dc565b511115610fd157610fd1612a02565b6000808a8a8a8a8a8a8a8a8a60405160200161345299989796959493929190614e33565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179150509998505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613558576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610df8565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080838060200190518101906135e59190614f09565b9050806040516020016135f891906140d9565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152815160209283012060008a815260079093529120541461364a576006915050611ca9565b600087815260076020526040902054613667576002915050611ca9565b60006136723a61385e565b9050600082610120015183610100015161368c9190614fd1565b61369d9064ffffffffff1683614c16565b90506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663330605298b8b878960e0015168ffffffffffffffffff16886136fc9190614bf1565b338b6040518763ffffffff1660e01b815260040161371f96959493929190614fef565b60408051808303816000875af115801561373d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613761919061506b565b9092509050600082600681111561377a5761377a6149fd565b148061379757506001826006811115613795576137956149fd565b145b156138505760008b8152600760205260408120556137b58184614bf1565b336000908152600a6020526040812080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff93841617905560e0870151600b805468ffffffffffffffffff9092169390929161382191859116614bf1565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055505b509998505050505050505050565b600061388761386b612735565b61387d84670de0b6b3a7640000614a50565b6134029190614e1f565b92915050565b60006bffffffffffffffffffffffff82111561392b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f36206269747300000000000000000000000000000000000000000000000000006064820152608401610df8565b5090565b50805461393b906144ad565b6000825580601f1061394b575050565b601f0160209004906000526020600020908101906109029190613988565b604051806103e00160405280601f906020820280368337509192915050565b5b8082111561392b5760008155600101613989565b60008083601f8401126139af57600080fd5b50813567ffffffffffffffff8111156139c757600080fd5b6020830191508360208285010111156139df57600080fd5b9250929050565b600080602083850312156139f957600080fd5b823567ffffffffffffffff811115613a1057600080fd5b613a1c8582860161399d565b90969095509350505050565b6000815180845260005b81811015613a4e57602081850181015186830182015201613a32565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000613a9f6020830184613a28565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051610120810167ffffffffffffffff81118282101715613af957613af9613aa6565b60405290565b604051610160810167ffffffffffffffff81118282101715613af957613af9613aa6565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613b6a57613b6a613aa6565b604052919050565b63ffffffff8116811461090257600080fd5b80356112f781613b72565b68ffffffffffffffffff8116811461090257600080fd5b80356112f781613b8f565b803561ffff811681146112f757600080fd5b80357bffffffffffffffffffffffffffffffffffffffffffffffffffffffff811681146112f757600080fd5b60006101208284031215613c0257600080fd5b613c0a613ad5565b613c1383613b84565b8152613c2160208401613b84565b6020820152613c3260408401613b84565b6040820152613c4360608401613b84565b6060820152613c5460808401613b84565b6080820152613c6560a08401613ba6565b60a0820152613c7660c08401613bb1565b60c0820152613c8760e08401613b84565b60e0820152610100613c9a818501613bc3565b908201529392505050565b73ffffffffffffffffffffffffffffffffffffffff8116811461090257600080fd5b80356112f781613ca5565b600060208284031215613ce457600080fd5b8135613a9f81613ca5565b600081518084526020808501945080840160005b83811015613d3557815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613d03565b509495945050505050565b604081526000613d536040830185613cef565b6020838203818501528185518084528284019150828160051b85010183880160005b83811015613dc1577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552613daf838351613a28565b94860194925090850190600101613d75565b50909998505050505050505050565b600082601f830112613de157600080fd5b813567ffffffffffffffff811115613dfb57613dfb613aa6565b613e2c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613b23565b818152846020838601011115613e4157600080fd5b816020850160208301376000918101602001919091529392505050565b600060208284031215613e7057600080fd5b813567ffffffffffffffff811115613e8757600080fd5b613e9384828501613dd0565b949350505050565b6bffffffffffffffffffffffff8116811461090257600080fd5b80356112f781613e9b565b60008060408385031215613ed357600080fd5b8235613ede81613ca5565b91506020830135613eee81613e9b565b809150509250929050565b600080600060408486031215613f0e57600080fd5b8335613f1981613ca5565b9250602084013567ffffffffffffffff811115613f3557600080fd5b613f418682870161399d565b9497909650939450505050565b602081526000613a9f6020830184613cef565b600060208284031215613f7357600080fd5b5035919050565b600060208284031215613f8c57600080fd5b813567ffffffffffffffff811115613fa357600080fd5b82016101608185031215613a9f57600080fd5b805182526020810151613fe1602084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604081015161400160408401826bffffffffffffffffffffffff169052565b506060810151614029606084018273ffffffffffffffffffffffffffffffffffffffff169052565b506080810151614045608084018267ffffffffffffffff169052565b5060a081015161405d60a084018263ffffffff169052565b5060c081015161407a60c084018268ffffffffffffffffff169052565b5060e081015161409760e084018268ffffffffffffffffff169052565b506101008181015164ffffffffff81168483015250506101208181015164ffffffffff81168483015250506101408181015163ffffffff8116848301526110d6565b61016081016138878284613fb6565b60008083601f8401126140fa57600080fd5b50813567ffffffffffffffff81111561411257600080fd5b6020830191508360208260051b85010111156139df57600080fd5b60008060008060008060008060e0898b03121561414957600080fd5b606089018a81111561415a57600080fd5b8998503567ffffffffffffffff8082111561417457600080fd5b6141808c838d0161399d565b909950975060808b013591508082111561419957600080fd5b6141a58c838d016140e8565b909750955060a08b01359150808211156141be57600080fd5b506141cb8b828c016140e8565b999c989b50969995989497949560c00135949350505050565b815163ffffffff9081168252602080840151821690830152604080840151821690830152606080840151821690830152608080840151918216908301526101208201905060a083015161424460a084018268ffffffffffffffffff169052565b5060c083015161425a60c084018261ffff169052565b5060e083015161427260e084018263ffffffff169052565b50610100838101517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff8116848301525b505092915050565b67ffffffffffffffff8116811461090257600080fd5b80356112f7816142a6565b6000806000806000608086880312156142df57600080fd5b85356142ea816142a6565b9450602086013567ffffffffffffffff81111561430657600080fd5b6143128882890161399d565b909550935050604086013561432681613b72565b949793965091946060013592915050565b600067ffffffffffffffff82111561435157614351613aa6565b5060051b60200190565b600082601f83011261436c57600080fd5b8135602061438161437c83614337565b613b23565b82815260059290921b840181019181810190868411156143a057600080fd5b8286015b848110156143c45780356143b781613ca5565b83529183019183016143a4565b509695505050505050565b803560ff811681146112f757600080fd5b60008060008060008060c087890312156143f957600080fd5b863567ffffffffffffffff8082111561441157600080fd5b61441d8a838b0161435b565b9750602089013591508082111561443357600080fd5b61443f8a838b0161435b565b965061444d60408a016143cf565b9550606089013591508082111561446357600080fd5b61446f8a838b01613dd0565b945061447d60808a016142bc565b935060a089013591508082111561449357600080fd5b506144a089828a01613dd0565b9150509295509295509295565b600181811c908216806144c157607f821691505b6020821081036144fa577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561063757600081815260208120601f850160051c810160208610156145275750805b601f850160051c820191505b81811015610d7357828155600101614533565b67ffffffffffffffff83111561455e5761455e613aa6565b6145728361456c83546144ad565b83614500565b6000601f8411600181146145c4576000851561458e5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561465a565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101561461357868501358255602094850194600190920191016145f3565b508682101561464e577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b80516112f781613b8f565b60006020828403121561467e57600080fd5b8151613a9f81613b8f565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203614718576147186146b8565b5060010190565b6bffffffffffffffffffffffff82811682821603908082111561295f5761295f6146b8565b6000610160823603121561475757600080fd5b61475f613aff565b823567ffffffffffffffff81111561477657600080fd5b61478236828601613dd0565b8252506020830135602082015261479b60408401613cc7565b60408201526147ac60608401613eb5565b60608201526147bd60808401613ba6565b60808201526147ce60a084016142bc565b60a08201526147df60c084016142bc565b60c08201526147f060e08401613b84565b60e0820152610100614803818501613bb1565b908201526101206148158482016142bc565b90820152610140614827848201613cc7565b9082015292915050565b60006020828403121561484357600080fd5b8135613a9f816142a6565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe184360301811261488357600080fd5b83018035915067ffffffffffffffff82111561489e57600080fd5b6020019150368190038213156139df57600080fd5b6000602082840312156148c557600080fd5b613a9f82613bb1565b6000602082840312156148e057600080fd5b8135613a9f81613b72565b73ffffffffffffffffffffffffffffffffffffffff8a8116825267ffffffffffffffff8a166020830152881660408201526102406060820181905281018690526000610260878982850137600083890182015261ffff8716608084015260a0830186905263ffffffff851660c0840152601f88017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016830101905061340760e0830184613fb6565b60ff8181168382160190811115613887576138876146b8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b600060ff8316806149ee576149ee6149ac565b8060ff84160491505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b8183823760009101908152919050565b828152606082602083013760800192915050565b8082028115828204841417613887576138876146b8565b81810381811115613887576138876146b8565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b63ffffffff81811683821601908082111561295f5761295f6146b8565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152614af68184018a613cef565b90508281036080840152614b0a8189613cef565b905060ff871660a084015282810360c0840152614b278187613a28565b905067ffffffffffffffff851660e0840152828103610100840152614b4c8185613a28565b9c9b505050505050505050505050565b805169ffffffffffffffffffff811681146112f757600080fd5b600080600080600060a08688031215614b8e57600080fd5b614b9786614b5c565b9450602086015193506040860151925060608601519150614bba60808701614b5c565b90509295509295909350565b60006bffffffffffffffffffffffff80841680614be557614be56149ac565b92169190910492915050565b6bffffffffffffffffffffffff81811683821601908082111561295f5761295f6146b8565b6bffffffffffffffffffffffff81811683821602808216919082811461429e5761429e6146b8565b67ffffffffffffffff81811683821601908082111561295f5761295f6146b8565b80820180821115613887576138876146b8565b600082601f830112614c8357600080fd5b81356020614c9361437c83614337565b82815260059290921b84018101918181019086841115614cb257600080fd5b8286015b848110156143c45780358352918301918301614cb6565b600082601f830112614cde57600080fd5b81356020614cee61437c83614337565b82815260059290921b84018101918181019086841115614d0d57600080fd5b8286015b848110156143c457803567ffffffffffffffff811115614d315760008081fd5b614d3f8986838b0101613dd0565b845250918301918301614d11565b600080600080600060a08688031215614d6557600080fd5b853567ffffffffffffffff80821115614d7d57600080fd5b614d8989838a01614c72565b96506020880135915080821115614d9f57600080fd5b614dab89838a01614ccd565b95506040880135915080821115614dc157600080fd5b614dcd89838a01614ccd565b94506060880135915080821115614de357600080fd5b614def89838a01614ccd565b93506080880135915080821115614e0557600080fd5b50614e1288828901614ccd565b9150509295509295909350565b600082614e2e57614e2e6149ac565b500490565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614e7a8285018b613cef565b91508382036080850152614e8e828a613cef565b915060ff881660a085015283820360c0850152614eab8288613a28565b90861660e08501528381036101008501529050614b4c8185613a28565b80516112f781613ca5565b80516112f781613e9b565b80516112f7816142a6565b80516112f781613b72565b805164ffffffffff811681146112f757600080fd5b60006101608284031215614f1c57600080fd5b614f24613aff565b82518152614f3460208401614ec8565b6020820152614f4560408401614ed3565b6040820152614f5660608401614ec8565b6060820152614f6760808401614ede565b6080820152614f7860a08401614ee9565b60a0820152614f8960c08401614661565b60c0820152614f9a60e08401614661565b60e0820152610100614fad818501614ef4565b90820152610120614fbf848201614ef4565b90820152610140613c9a848201614ee9565b64ffffffffff81811683821601908082111561295f5761295f6146b8565b60006102008083526150038184018a613a28565b905082810360208401526150178189613a28565b6bffffffffffffffffffffffff88811660408601528716606085015273ffffffffffffffffffffffffffffffffffffffff861660808501529150615060905060a0830184613fb6565b979650505050505050565b6000806040838503121561507e57600080fd5b82516007811061508d57600080fd5b6020840151909250613eee81613e9b56fea164736f6c6343000813000a", } var FunctionsCoordinatorABI = FunctionsCoordinatorMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index b17a4c2f911..8b1abf59a13 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -4,7 +4,7 @@ functions_allow_list: ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfSer functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 -functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 8c83f78cf96b47a52e51506b6176ac1860f37396e11e5ea6fa695bae43c58ba9 +functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 7b2fb23e2f49121dfe4b096de5e60fe57be0a196c2423a4693293c23c96f9af4 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 75df8bb3546c6a9aaa29f505e3ea6a1685afd2469e9ac24d1f88eadf33d8b2a0 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d From b0d58f15592c9ac95b57eeb14b645b75aa7abd7d Mon Sep 17 00:00:00 2001 From: Damjan Smickovski <32773226+smickovskid@users.noreply.github.com> Date: Mon, 7 Aug 2023 09:59:57 +0200 Subject: [PATCH 099/270] Minor update to readme for integration-tests (#10097) * Minor update to readme * Updated readme --- integration-tests/README.md | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) diff --git a/integration-tests/README.md b/integration-tests/README.md index ddd07f8fb7b..86c4d0bde90 100644 --- a/integration-tests/README.md +++ b/integration-tests/README.md @@ -129,9 +129,25 @@ make test_soak_keeper Soak tests will pull all their network information from the env vars that you can set in the `.env` file. *Reminder to run `source .env` for changes to take effect.* -To configure specific parameters of how the soak tests run (e.g. test length, number of contracts), see the [./soak/tests](./soak/tests/) test specifications. +To configure specific parameters of how the soak tests run (e.g. test length, number of contracts), adjust the values in your `.env` file, you can use `example.env` as reference -See the [soak_runner](./soak/soak_runner_test.go) for more info on how the tests are run and configured. + +#### Running with custom image +On each PR navigate to the `integration-tests` job, here you will find the images for both chainlink-tests and core. In your env file you need to replace: + +`ENV_JOB_IMAGE="image-location/chainlink-tests:"` + +`CHAINLINK_IMAGE="public.ecr.aws/chainlink/chainlink"` + +`export CHAINLINK_VERSION=""` + +After all the env vars are exported, run the tests. This will kick off a remote runner that will be in charge of running the tests. Locally the test should pass quickly and a namespace will be displayed in the output e.g +`INF Creating new namespace Namespace=soak-ocr-goerli-testnet-957b2` + +#### Logs and monitoring +- Pod logs: `kubectl logs -n soak-ocr-goerli-testnet-957b2 -c node -f chainlink-0-1` +- Remote runner logs: `kubectl logs -n soak-ocr-goerli-testnet-957b2 -f remote-runner-cs2as` +- Navigate to Grafana chainlink testing insights for all logs ### Performance @@ -143,7 +159,9 @@ make test_perf ## Common Issues -When upgrading to a new version, it's possible the helm charts have changed. There are a myriad of errors that can result from this, so it's best to just try running `helm repo update` when encountering an error you're unsure of. +- When upgrading to a new version, it's possible the helm charts have changed. There are a myriad of errors that can result from this, so it's best to just try running `helm repo update` when encountering an error you're unsure of. +- Docker failing to pull image, make sure you are referencing the correct ECR repo in AWS since develop images are not pushed to the public one. + - If tests hang for some time this is usually the case, so make sure to check the logs each time tests are failing to start From 2c598b3f4116f2cb0ccc06c52fb4028e8f86f96f Mon Sep 17 00:00:00 2001 From: Sam Date: Mon, 7 Aug 2023 09:45:49 -0400 Subject: [PATCH 100/270] Bump to libocr master 2271752fa829 (#10080) --- core/scripts/go.mod | 8 ++++---- core/scripts/go.sum | 16 ++++++++-------- core/services/ocr2/plugins/median/services.go | 2 +- .../ocr2/plugins/mercury/integration_test.go | 2 ++ go.mod | 8 ++++---- go.sum | 16 ++++++++-------- integration-tests/go.mod | 8 ++++---- integration-tests/go.sum | 16 ++++++++-------- 8 files changed, 39 insertions(+), 37 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index dc50e937e31..727f46913e4 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -18,9 +18,9 @@ require ( github.com/pelletier/go-toml/v2 v2.0.8 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 - github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v0.7.2 - github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c + github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 + github.com/smartcontractkit/ocr2keepers v0.7.3 + github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 github.com/spf13/viper v1.15.0 @@ -297,7 +297,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 7d116893fb7..18c77d10c2c 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1431,18 +1431,18 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 h1:zCw6s6tbuk/m6oCrMXobvcEz2a/pl9Z3pj20gfPG7wE= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea h1:k2o+ta3tJgyiDKvkeI6yKA2ZMPG6kCrNc+NdSgU00BI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea/go.mod h1:9w55r3WyiwZSsPfn7xyJj3F0N3IWiI9czehsn4o4xGQ= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= -github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= -github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= -github.com/smartcontractkit/ocr2keepers v0.7.2/go.mod h1:2cQpoTO4SL0JYKabW2bSzbN5i86ZH9G1O/75EsXlj3o= -github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= -github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= +github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= +github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= +github.com/smartcontractkit/ocr2keepers v0.7.3 h1:A2ZoIJklyY5avOsA8EBKXQ4wc7Ao2kOSm9MpmrK4Fho= +github.com/smartcontractkit/ocr2keepers v0.7.3/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= +github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= diff --git a/core/services/ocr2/plugins/median/services.go b/core/services/ocr2/plugins/median/services.go index 6f5f1417152..8ff97c2cc56 100644 --- a/core/services/ocr2/plugins/median/services.go +++ b/core/services/ocr2/plugins/median/services.go @@ -125,7 +125,7 @@ func NewMedianServices(ctx context.Context, } } - var oracle *libocr.Oracle + var oracle libocr.Oracle oracle, err = libocr.NewOracle(argsNoPlugin) if err != nil { abort() diff --git a/core/services/ocr2/plugins/mercury/integration_test.go b/core/services/ocr2/plugins/mercury/integration_test.go index 5671b25be78..cb5b98a5216 100644 --- a/core/services/ocr2/plugins/mercury/integration_test.go +++ b/core/services/ocr2/plugins/mercury/integration_test.go @@ -256,8 +256,10 @@ func TestIntegration_Mercury(t *testing.T) { signers, _, _, onchainConfig, offchainConfigVersion, offchainConfig, err := confighelper.ContractSetConfigArgsForTestsMercuryV02( 2*time.Second, // DeltaProgress 20*time.Second, // DeltaResend + 400*time.Millisecond, // DeltaInitial 100*time.Millisecond, // DeltaRound 0, // DeltaGrace + 300*time.Millisecond, // DeltaCertifiedCommitRequest 1*time.Minute, // DeltaStage 100, // rMax []int{len(nodes)}, // S diff --git a/go.mod b/go.mod index 83fe3f0435f..72d333f3d4a 100644 --- a/go.mod +++ b/go.mod @@ -67,12 +67,12 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a - github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v0.7.2 - github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c + github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 + github.com/smartcontractkit/ocr2keepers v0.7.3 + github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a diff --git a/go.sum b/go.sum index 3102f793c9b..c98f8ec7402 100644 --- a/go.sum +++ b/go.sum @@ -1436,18 +1436,18 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 h1:zCw6s6tbuk/m6oCrMXobvcEz2a/pl9Z3pj20gfPG7wE= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea h1:k2o+ta3tJgyiDKvkeI6yKA2ZMPG6kCrNc+NdSgU00BI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea/go.mod h1:9w55r3WyiwZSsPfn7xyJj3F0N3IWiI9czehsn4o4xGQ= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= -github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= -github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= -github.com/smartcontractkit/ocr2keepers v0.7.2/go.mod h1:2cQpoTO4SL0JYKabW2bSzbN5i86ZH9G1O/75EsXlj3o= -github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= -github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= +github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= +github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= +github.com/smartcontractkit/ocr2keepers v0.7.3 h1:A2ZoIJklyY5avOsA8EBKXQ4wc7Ao2kOSm9MpmrK4Fho= +github.com/smartcontractkit/ocr2keepers v0.7.3/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= +github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 912b318593e..104d76bca97 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -21,9 +21,9 @@ require ( github.com/smartcontractkit/chainlink-env v0.36.0 github.com/smartcontractkit/chainlink-testing-framework v1.15.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 - github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac - github.com/smartcontractkit/ocr2keepers v0.7.2 - github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c + github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 + github.com/smartcontractkit/ocr2keepers v0.7.3 + github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/spf13/cobra v1.6.1 github.com/stretchr/testify v1.8.4 github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a @@ -379,7 +379,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 77c73df2652..e47a9e160db 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2240,20 +2240,20 @@ github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb2 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256 h1:zCw6s6tbuk/m6oCrMXobvcEz2a/pl9Z3pj20gfPG7wE= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230802190005-10db9909d256/go.mod h1:MfZBUifutkv3aK7abyw5YmTJbqt8iFwcQDFikrxC/uI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea h1:k2o+ta3tJgyiDKvkeI6yKA2ZMPG6kCrNc+NdSgU00BI= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea/go.mod h1:9w55r3WyiwZSsPfn7xyJj3F0N3IWiI9czehsn4o4xGQ= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87gFQ27MAv4Iat7aoCnM3K87/d0r4Aho= github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= -github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac h1:ugouvLyN5D2AeztWrByENx08cx0phkxxvfP+AkBv3NI= -github.com/smartcontractkit/libocr v0.0.0-20230724105022-c5e49b4195ac/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.2 h1:ls8KsVImEEFFVAneFbhS7HXJ9nUlyX+tKoxSQNeirHs= -github.com/smartcontractkit/ocr2keepers v0.7.2/go.mod h1:2cQpoTO4SL0JYKabW2bSzbN5i86ZH9G1O/75EsXlj3o= -github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c h1:BX1ibMdGE2QdD8rJEI5nxE4jA6v2bf7LULrSbDrNM+A= -github.com/smartcontractkit/ocr2vrf v0.0.0-20230616201444-d8b4222aff3c/go.mod h1:AT1OrDDOCd8vzmMsCnA70N+tZdq9AbdZAiAw+gQq260= +github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= +github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= +github.com/smartcontractkit/ocr2keepers v0.7.3 h1:A2ZoIJklyY5avOsA8EBKXQ4wc7Ao2kOSm9MpmrK4Fho= +github.com/smartcontractkit/ocr2keepers v0.7.3/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= +github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= From 565275096901bc5432b2890d06ad1e5de6eaa5fb Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Mon, 7 Aug 2023 08:04:06 -0700 Subject: [PATCH 101/270] [Functions] Improve port selection in integration tests (#10102) --- .../v0/functions_integration_test.go | 4 ++-- .../v0/internal/testutils.go | 22 +++++++++++++++---- .../v1/functions_integration_test.go | 4 ++-- .../v1/internal/testutils.go | 22 +++++++++++++++---- 4 files changed, 40 insertions(+), 12 deletions(-) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go index e97d3189c65..b708058be35 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go @@ -22,7 +22,7 @@ func TestIntegration_Functions_MultipleRequests_Success(t *testing.T) { owner, b, ticker, oracleContractAddress, oracleContract, clientContracts, registryAddress, registryContract, linkToken := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, 39879, nOracleNodes, maxGas, nil, nil) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, nOracleNodes, maxGas, nil, nil) // config for registry contract utils.SetRegistryConfig(t, owner, registryContract, oracleContractAddress) @@ -49,7 +49,7 @@ func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *te owner, b, ticker, oracleContractAddress, oracleContract, clientContracts, registryAddress, registryContract, linkToken := utils.StartNewChainWithContracts(t, nClients) defer ticker.Stop() - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, 39889, nOracleNodes, maxGas, utils.ExportedOcr2Keystores, utils.MockThresholdKeyShares) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, oracleContractAddress, nOracleNodes, maxGas, utils.ExportedOcr2Keystores, utils.MockThresholdKeyShares) // config for registry contract utils.SetRegistryConfig(t, owner, registryContract, oracleContractAddress) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go index 691e14729c6..9013620e1e6 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/internal/testutils.go @@ -7,6 +7,7 @@ import ( "io" "math/big" "math/rand" + "net" "net/http" "net/http/httptest" "net/url" @@ -451,7 +452,6 @@ func CreateFunctionsNodes( owner *bind.TransactOpts, b *backends.SimulatedBackend, oracleContractAddress common.Address, - startingPort uint16, nOracleNodes int, maxGas int, ocr2Keystores [][]byte, @@ -469,7 +469,8 @@ func CreateFunctionsNodes( require.Fail(t, "ocr2Keystores and thresholdKeyShares must have the same length") } - bootstrapNode = StartNewNode(t, owner, startingPort, "bootstrap", b, uint32(maxGas), nil, nil, "") + bootstrapPort := getFreePort(t) + bootstrapNode = StartNewNode(t, owner, bootstrapPort, "bootstrap", b, uint32(maxGas), nil, nil, "") AddBootstrapJob(t, bootstrapNode.App, oracleContractAddress) // oracle nodes with jobs, bridges and mock EAs @@ -486,8 +487,9 @@ func CreateFunctionsNodes( } else { ocr2Keystore = ocr2Keystores[i] } - oracleNode := StartNewNode(t, owner, startingPort+1+uint16(i), fmt.Sprintf("oracle%d", i), b, uint32(maxGas), []commontypes.BootstrapperLocator{ - {PeerID: bootstrapNode.PeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", startingPort)}}, + nodePort := getFreePort(t) + oracleNode := StartNewNode(t, owner, nodePort, fmt.Sprintf("oracle%d", i), b, uint32(maxGas), []commontypes.BootstrapperLocator{ + {PeerID: bootstrapNode.PeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", bootstrapPort)}}, }, ocr2Keystore, thresholdKeyShare) oracleNodes = append(oracleNodes, oracleNode.App) oracleIdentites = append(oracleIdentites, oracleNode.OracleIdentity) @@ -501,6 +503,18 @@ func CreateFunctionsNodes( return bootstrapNode, oracleNodes, oracleIdentites } +// NOTE: This approach is technically incorrect because the returned port +// can still be taken by the time the caller attempts to bind to it. +// Unfortunately, we can't specify zero port in P2P.V2.ListenAddresses at the moment. +func getFreePort(t *testing.T) uint16 { + addr, err := net.ResolveTCPAddr("tcp", "localhost:0") + require.NoError(t, err) + listener, err := net.ListenTCP("tcp", addr) + require.NoError(t, err) + require.NoError(t, listener.Close()) + return uint16(listener.Addr().(*net.TCPAddr).Port) +} + func ClientTestRequests( t *testing.T, owner *bind.TransactOpts, diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index e401964b18a..a98d4dffca8 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -27,7 +27,7 @@ func TestIntegration_Functions_MultipleV1Requests_Success(t *testing.T) { utils.SetupRouterRoutes(t, b, owner, routerContract, active.Address, proposed.Address, allowListContractAddress) - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, 39979, nOracleNodes, maxGas, nil, nil) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, nOracleNodes, maxGas, nil, nil) pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, @@ -54,7 +54,7 @@ func TestIntegration_Functions_MultipleV1Requests_WithUpgrade(t *testing.T) { utils.SetupRouterRoutes(t, b, owner, routerContract, active.Address, proposed.Address, allowListContractAddress) - _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, 39989, nOracleNodes, maxGas, nil, nil) + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, nOracleNodes, maxGas, nil, nil) pluginConfig := functionsConfig.ReportingPluginConfig{ MaxQueryLengthBytes: 10_000, diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 7d1f24090bb..827323c2d22 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -7,6 +7,7 @@ import ( "io" "math/big" "math/rand" + "net" "net/http" "net/http/httptest" "net/url" @@ -528,7 +529,6 @@ func CreateFunctionsNodes( owner *bind.TransactOpts, b *backends.SimulatedBackend, routerAddress common.Address, - startingPort uint16, nOracleNodes int, maxGas int, ocr2Keystores [][]byte, @@ -546,7 +546,8 @@ func CreateFunctionsNodes( require.Fail(t, "ocr2Keystores and thresholdKeyShares must have the same length") } - bootstrapNode = StartNewNode(t, owner, startingPort, "bootstrap", b, uint32(maxGas), nil, nil, "") + bootstrapPort := getFreePort(t) + bootstrapNode = StartNewNode(t, owner, bootstrapPort, "bootstrap", b, uint32(maxGas), nil, nil, "") AddBootstrapJob(t, bootstrapNode.App, routerAddress) // oracle nodes with jobs, bridges and mock EAs @@ -563,8 +564,9 @@ func CreateFunctionsNodes( } else { ocr2Keystore = ocr2Keystores[i] } - oracleNode := StartNewNode(t, owner, startingPort+1+uint16(i), fmt.Sprintf("oracle%d", i), b, uint32(maxGas), []commontypes.BootstrapperLocator{ - {PeerID: bootstrapNode.PeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", startingPort)}}, + nodePort := getFreePort(t) + oracleNode := StartNewNode(t, owner, nodePort, fmt.Sprintf("oracle%d", i), b, uint32(maxGas), []commontypes.BootstrapperLocator{ + {PeerID: bootstrapNode.PeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", bootstrapPort)}}, }, ocr2Keystore, thresholdKeyShare) oracleNodes = append(oracleNodes, oracleNode.App) oracleIdentites = append(oracleIdentites, oracleNode.OracleIdentity) @@ -578,6 +580,18 @@ func CreateFunctionsNodes( return bootstrapNode, oracleNodes, oracleIdentites } +// NOTE: This approach is technically incorrect because the returned port +// can still be taken by the time the caller attempts to bind to it. +// Unfortunately, we can't specify zero port in P2P.V2.ListenAddresses at the moment. +func getFreePort(t *testing.T) uint16 { + addr, err := net.ResolveTCPAddr("tcp", "localhost:0") + require.NoError(t, err) + listener, err := net.ListenTCP("tcp", addr) + require.NoError(t, err) + require.NoError(t, listener.Close()) + return uint16(listener.Addr().(*net.TCPAddr).Port) +} + func ClientTestRequests( t *testing.T, owner *bind.TransactOpts, From 2a177c5ec52f656b2085c91693d78b76d2269822 Mon Sep 17 00:00:00 2001 From: Anirudh Warrier Date: Mon, 7 Aug 2023 21:13:17 +0530 Subject: [PATCH 102/270] [QA-1223] Update Smoke Test local run doc (#10019) * add k3d steps to test docs * remove mockserver from automation test setup --- integration-tests/Makefile | 5 ++++ integration-tests/README.md | 29 ++++++++++++++++++++++ integration-tests/smoke/automation_test.go | 4 --- 3 files changed, 34 insertions(+), 4 deletions(-) diff --git a/integration-tests/Makefile b/integration-tests/Makefile index 99bf68c912d..f558d598498 100644 --- a/integration-tests/Makefile +++ b/integration-tests/Makefile @@ -65,6 +65,11 @@ install_gotestfmt: build_test_image: ./scripts/buildTestImage $(tag) $(base_tag) "$(suite)" $(push) +#Build a chainlink docker image for local testing and push to k3d registry +.PHONY: build_push_docker_image +build_push_docker_image: + docker build -f ../core/chainlink.Dockerfile --build-arg COMMIT_SHA=$(git rev-parse HEAD) --build-arg CHAINLINK_USER=chainlink -t localhost:5000/chainlink:develop ../ ; docker push localhost:5000/chainlink:develop + ## Test Runner .PHONY: run run: # Need to set network first in case it's unset. Doesn't matter for the runner diff --git a/integration-tests/README.md b/integration-tests/README.md index 86c4d0bde90..3a2a59e0fbf 100644 --- a/integration-tests/README.md +++ b/integration-tests/README.md @@ -52,6 +52,35 @@ increase minikube's resources significantly, or get a more substantial cluster. This is necessary to deploy ephemeral testing environments, which include external adapters, chainlink nodes and their DBs, as well as some simulated blockchains, all depending on the types of tests and networks being used. +### Setup Kubernetes Cluster using k3d + +[k3d](https://k3d.io/) is a lightweight wrapper to run k3s (a lightweight kubernetes distribution) in docker. It's a great way to run a local kubernetes cluster for testing. +To create a new cluster you can run: + +```sh +k3d cluster create test-k8s --registry-create test-k8s-registry:0.0.0.0:5000 +``` + +This will create a cluster with a local registry running on port 5000. You can then use the registry to push images to and pull images from. + +To build and push chainlink image to the registry you can run: + +```sh +make build_push_docker_image +```` + +To stop the cluster you can run: + +```sh +k3d cluster stop test-k8s +``` + +To start an existing cluster you can run: + +```sh +k3d cluster start test-k8s +``` + ## Configure Environment See the [example.env](./example.env) file and use it as a template for your own `.env` file. This allows you to configure general settings like what name to associate with your tests, and which Chainlink version to use when running them. diff --git a/integration-tests/smoke/automation_test.go b/integration-tests/smoke/automation_test.go index 8b1f4b50580..9e2df3d8c0d 100644 --- a/integration-tests/smoke/automation_test.go +++ b/integration-tests/smoke/automation_test.go @@ -18,8 +18,6 @@ import ( "github.com/smartcontractkit/chainlink-env/logging" "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" eth "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" @@ -816,8 +814,6 @@ func setupAutomationTest( NamespacePrefix: fmt.Sprintf("smoke-automation-%s-%s", testName, strings.ReplaceAll(strings.ToLower(network.Name), " ", "-")), Test: t, }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). AddHelm(evmConfig). AddHelmCharts(cd) err = testEnvironment.Run() From 206df85a3d32c3a986e91638e01939d171c7259c Mon Sep 17 00:00:00 2001 From: Patrick Date: Mon, 7 Aug 2023 12:11:47 -0400 Subject: [PATCH 103/270] bug/2326-simple-passwords: re-enabling simple passwords restriction for prod (#10021) * bug/2326-simple-passwords: re-enabling simple passwords restriction for prod * strong password for tests --------- Co-authored-by: skudasov --- core/config/toml/types.go | 2 + core/config/toml/types_test.go | 77 +++++++++++++++++++ docs/CHANGELOG.md | 3 +- integration-tests/docker/test_env/cl_node.go | 2 +- integration-tests/docker/test_env/postgres.go | 2 +- .../utils/templates/node_secrets.go | 21 ++--- 6 files changed, 94 insertions(+), 13 deletions(-) diff --git a/core/config/toml/types.go b/core/config/toml/types.go index 9ae77def085..5aedcf4deb6 100644 --- a/core/config/toml/types.go +++ b/core/config/toml/types.go @@ -148,6 +148,8 @@ func validateDBURL(dbURI url.URL) error { func (d *DatabaseSecrets) ValidateConfig() (err error) { if d.URL == nil || (*url.URL)(d.URL).String() == "" { err = multierr.Append(err, configutils.ErrEmpty{Name: "URL", Msg: "must be provided and non-empty"}) + } else if *d.AllowSimplePasswords && build.IsProd() { + err = multierr.Append(err, configutils.ErrInvalid{Name: "AllowSimplePasswords", Value: true, Msg: "insecure configs are not allowed on secure builds"}) } else if !*d.AllowSimplePasswords { if verr := validateDBURL((url.URL)(*d.URL)); verr != nil { err = multierr.Append(err, configutils.ErrInvalid{Name: "URL", Value: "*****", Msg: dbURLPasswordComplexity(verr)}) diff --git a/core/config/toml/types_test.go b/core/config/toml/types_test.go index a85138c91b3..e2eb5eed815 100644 --- a/core/config/toml/types_test.go +++ b/core/config/toml/types_test.go @@ -2,10 +2,13 @@ package toml import ( "fmt" + "net/url" + "strings" "testing" "github.com/stretchr/testify/assert" + "github.com/smartcontractkit/chainlink/v2/core/build" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -97,3 +100,77 @@ func Test_validateDBURL(t *testing.T) { }) } } + +func TestValidateConfig(t *testing.T) { + validUrl := models.URL(url.URL{Scheme: "https", Host: "localhost"}) + validSecretURL := *models.NewSecretURL(&validUrl) + + invalidEmptyUrl := models.URL(url.URL{}) + invalidEmptySecretURL := *models.NewSecretURL(&invalidEmptyUrl) + + invalidBackupURL := models.URL(url.URL{Scheme: "http", Host: "localhost"}) + invalidBackupSecretURL := *models.NewSecretURL(&invalidBackupURL) + + tests := []struct { + name string + input *DatabaseSecrets + skip bool + expectedErrContains []string + }{ + { + name: "Nil URL", + input: &DatabaseSecrets{ + URL: nil, + }, + expectedErrContains: []string{"URL: empty: must be provided and non-empty"}, + }, + { + name: "Empty URL", + input: &DatabaseSecrets{ + URL: &invalidEmptySecretURL, + }, + expectedErrContains: []string{"URL: empty: must be provided and non-empty"}, + }, + { + name: "Insecure Password in Production", + input: &DatabaseSecrets{ + URL: &validSecretURL, + AllowSimplePasswords: &[]bool{true}[0], + }, + skip: !build.IsProd(), + expectedErrContains: []string{"insecure configs are not allowed on secure builds"}, + }, + { + name: "Invalid Backup URL with Simple Passwords Not Allowed", + input: &DatabaseSecrets{ + URL: &validSecretURL, + BackupURL: &invalidBackupSecretURL, + AllowSimplePasswords: &[]bool{false}[0], + }, + expectedErrContains: []string{"missing or insufficiently complex password"}, + }, + } + + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + // needed while -tags test is supported + if tt.skip { + t.SkipNow() + } + err := tt.input.ValidateConfig() + if err == nil && len(tt.expectedErrContains) > 0 { + t.Errorf("expected errors but got none") + return + } + + if err != nil { + errStr := err.Error() + for _, expectedErrSubStr := range tt.expectedErrContains { + if !strings.Contains(errStr, expectedErrSubStr) { + t.Errorf("expected error to contain substring %q but got %v", expectedErrSubStr, errStr) + } + } + } + }) + } +} diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index bd0ff534a6a..b586518787d 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,7 +9,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] -... +### Changed +- Simple passwords are no longer allowed for production builds ## 2.4.0 - UNRELEASED ### Fixed diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 74a2bdf7726..626f7367084 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -183,7 +183,7 @@ func (n *ClNode) StartContainer(lw *logwatch.LogWatch) error { return err } nodeSecrets, err := templates.ExecuteNodeSecretsTemplate( - n.PostgresDb.DbName, n.PostgresDb.ContainerName, n.PostgresDb.Port) + n.PostgresDb.Password, n.PostgresDb.DbName, n.PostgresDb.ContainerName, n.PostgresDb.Port) if err != nil { return err } diff --git a/integration-tests/docker/test_env/postgres.go b/integration-tests/docker/test_env/postgres.go index 7c2782f14a2..4b886a8b9f9 100644 --- a/integration-tests/docker/test_env/postgres.go +++ b/integration-tests/docker/test_env/postgres.go @@ -38,7 +38,7 @@ func NewPostgresDb(networks []string, opts ...PostgresDbOption) *PostgresDb { Networks: networks, }, User: "postgres", - Password: "test", + Password: "mysecretpassword", DbName: "testdb", Port: "5432", } diff --git a/integration-tests/utils/templates/node_secrets.go b/integration-tests/utils/templates/node_secrets.go index a40c553df85..56d63d1d480 100644 --- a/integration-tests/utils/templates/node_secrets.go +++ b/integration-tests/utils/templates/node_secrets.go @@ -9,11 +9,10 @@ import ( var NodeSecretsTemplate = ` [Database] -URL = 'postgresql://postgres:test@{{ .PgHost }}:{{ .PgPort }}/{{ .PgDbName }}?sslmode=disable' # Required -AllowSimplePasswords = true +URL = 'postgresql://postgres:{{ .PgPassword }}@{{ .PgHost }}:{{ .PgPort }}/{{ .PgDbName }}?sslmode=disable' # Required [Password] -Keystore = '................' # Required +Keystore = 'mysecretpassword' # Required [Mercury.Credentials.cred1] # URL = 'http://host.docker.internal:3000/reports' @@ -22,15 +21,17 @@ Username = 'node' Password = 'nodepass' ` -func ExecuteNodeSecretsTemplate(pgDbName, pgHost, pgPort string) (string, error) { +func ExecuteNodeSecretsTemplate(pgPassowrd, pgDbName, pgHost, pgPort string) (string, error) { data := struct { - PgDbName string - PgHost string - PgPort string + PgDbName string + PgHost string + PgPort string + PgPassword string }{ - PgDbName: pgDbName, - PgHost: pgHost, - PgPort: pgPort, + PgDbName: pgDbName, + PgHost: pgHost, + PgPort: pgPort, + PgPassword: pgPassowrd, } t, err := template.New("node-secrets").Parse(NodeSecretsTemplate) From 72435f00fa25dbd53ddc75492a4c3338664229c3 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Mon, 7 Aug 2023 12:15:03 -0400 Subject: [PATCH 104/270] [TT-445] Re-enable and Monitor Regular Live Testnet Runs (#10036) * Set debugging flow up * Remove if gate * Remove some env vars * Fix version * Testing slack * Actually fix slack * Try attachment * Fix json * Add arbitrum * JSON MASTER * Probably won't work * Fix thread_ts * Faster dev time * Check matrix results * Coallesce * GitHub sad face * Select proper name * Fix debug * Fix jq * jq doesn't like backslashes * Fix echo * Missing quote * Bad quote * Debug * Add slack ID * strip quotes * Fix color * Remove text * Debug matrix result * Fix comma * Remove debug * Fix frequency * Fix comment --- .github/workflows/integration-tests.yml | 180 +++++++++++++++++------- 1 file changed, 127 insertions(+), 53 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 5657955c620..04a3a6d7b9b 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -577,7 +577,7 @@ jobs: ### Start Live Testnet Section - testnet-smoke-tests-matrix: + testnet-smoke-tests-matrix: if: ${{ github.event_name == 'schedule' || (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')) }} ## Only run live tests on new tags and nightly environment: integration permissions: @@ -594,24 +594,18 @@ jobs: EVM_KEYS: ${{ secrets.QA_EVM_KEYS }} TEST_EVM_KEYS: ${{ secrets.QA_EVM_KEYS }} - GOERLI_URLS: ${{ secrets.QA_GOERLI_URLS }} - TEST_GOERLI_URLS: ${{ secrets.QA_GOERLI_URLS }} - GOERLI_HTTP_URLS: ${{ secrets.QA_GOERLI_HTTP_URLS }} - TEST_GOERLI_HTTP_URLS: ${{ secrets.QA_GOERLI_HTTP_URLS }} - - OPTIMISM_GOERLI_URLS: ${{ secrets.QA_OPTIMISM_GOERLI_URLS }} TEST_OPTIMISM_GOERLI_URLS: ${{ secrets.QA_OPTIMISM_GOERLI_URLS }} - OPTIMISM_GOERLI_HTTP_URLS: ${{ secrets.QA_OPTIMISM_GOERLI_HTTP_URLS }} TEST_OPTIMISM_GOERLI_HTTP_URLS: ${{ secrets.QA_OPTIMISM_GOERLI_HTTP_URLS }} - ARBITRUM_GOERLI_URLS: ${{ secrets.QA_ARBITRUM_GOERLI_URLS }} TEST_ARBITRUM_GOERLI_URLS: ${{ secrets.QA_ARBITRUM_GOERLI_URLS }} - ARBITRUM_GOERLI_HTTP_URLS: ${{ secrets.QA_ARBITRUM_GOERLI_HTTP_URLS }} TEST_ARBITRUM_GOERLI_HTTP_URLS: ${{ secrets.QA_ARBITRUM_GOERLI_HTTP_URLS }} strategy: fail-fast: false matrix: - testnet: [GOERLI, OPTIMISM_GOERLI, ARBITRUM_GOERLI] + # NOTE: If changing this matrix, make sure to update the matrix in the testnet-smoke-tests-notify job to be the same + # otherwise reporting will be broken. Getting a single matrix for multiple jobs is a pain + # https://github.com/orgs/community/discussions/26284#discussioncomment-3251198 + testnet: [OPTIMISM_GOERLI, ARBITRUM_GOERLI] name: Live Testnet Smoke Tests ${{ matrix.testnet }} runs-on: ubuntu-latest steps: @@ -638,58 +632,138 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} - - name: Notify Slack - if: false ## TODO: This is currently noisy and needs to be more compact. - id: slack + continue-on-error: true + + - name: Collect Metrics + if: always() + id: collect-gha-metrics + uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + with: + basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} + hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} + this-job-name: Live Testnet Smoke Tests ${{ matrix.testnet }} + test-results-file: '{"testType":"go","filePath":"/tmp/gotest.log"}' + continue-on-error: true + + testnet-smoke-tests-notify: + name: Live Testnet Start Slack Thread + environment: integration + outputs: + thread_ts: ${{ steps.slack.outputs.thread_ts }} + permissions: + checks: write + pull-requests: write + id-token: write + contents: read + runs-on: ubuntu-latest + needs: testnet-smoke-tests-matrix + steps: + - name: Debug Result + run: echo ${{needs.testnet-smoke-tests-matrix.result}} + - name: Main Slack Notification uses: slackapi/slack-github-action@e28cf165c92ffef168d23c5c9000cffc8a25e117 # v1.24.0 + id: slack with: - channel-id: ${{ secrets.QA_RELEASE_SLACK_CHANNEL }} + channel-id: ${{ secrets.QA_SLACK_CHANNEL }} payload: | { - "text": "", - "blocks": [ - { - "type": "header", - "text": { - "type": "plain_text", - "text": "Live Smoke Test Results for ${{ matrix.testnet }} ${{ job.status == 'success' && ':white_check_mark:' || ':x:'}}", - "emoji": true - } - }, - { - "type": "divider" - }, - { - "type": "section", - "text": { - "type": "mrkdwn", - "text": "Tag: <${{ github.server_url }}/${{ github.repository }}/releases/tag/${{ github.ref_name }}|${{ github.ref_name }}>\nCommit: <${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}>\n<${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|Run>" - } - }, + "attachments": [ { - "type": "divider" - }, - { - "type": "section", - "text": { - "type": "mrkdwn", - "text": "OCR ${{ job.status == 'success' && ':white_check_mark:' || ':x:'}}" - } + "color": "${{ needs.testnet-smoke-tests-matrix.result == 'success' && '#2E7D32' || '#C62828' }}", + "blocks": [ + { + "type": "header", + "text": { + "type": "plain_text", + "text": "Live Smoke Test Results ${{ needs.testnet-smoke-tests-matrix.result == 'success' && ':white_check_mark:' || ':x:'}}", + "emoji": true + } + }, + { + "type": "divider" + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "<${{ github.server_url }}/${{ github.repository }}/releases/tag/${{ github.ref_name }}|${{ github.ref_name }}> | <${{ github.server_url }}/${{ github.repository }}/commit/${{ github.sha }}|${{ github.sha }}> | <${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}|Run>" + } + } + ] } ] } env: SLACK_BOT_TOKEN: ${{ secrets.QA_SLACK_API_KEY }} - - name: Collect Metrics - if: always() - id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + testnet-smoke-tests-results: + name: Post Live Testnet Smoke Test Results + environment: integration + permissions: + checks: write + pull-requests: write + id-token: write + contents: read + runs-on: ubuntu-latest + needs: testnet-smoke-tests-notify + strategy: + fail-fast: false + matrix: + # NOTE: If changing this matrix, make sure to update the matrix in the testnet-smoke-tests-matrix job to be the same + # otherwise reporting will be broken. Getting a single matrix for multiple jobs is a pain + # https://github.com/orgs/community/discussions/26284#discussioncomment-3251198 + testnet: [OPTIMISM_GOERLI, ARBITRUM_GOERLI] + steps: + - name: Get Results + id: test-results + run: | + echo "Querying test results" + + echo "status=$(curl \ + -H "Authorization: Bearer ${{ github.token }}" \ + 'https://api.github.com/repos/${{github.repository}}/actions/runs/${{ github.run_id }}/jobs' \ + | jq -r '.jobs[] | select(.name == "Live Testnet Smoke Tests ${{ matrix.testnet}}").steps[] | select(.name == "Run Tests").conclusion')" >> $GITHUB_OUTPUT + + echo "status=$(curl \ + -H "Authorization: Bearer ${{ github.token }}" \ + 'https://api.github.com/repos/${{github.repository}}/actions/runs/${{ github.run_id }}/jobs' \ + | jq -r '.jobs[] | select(.name == "Live Testnet Smoke Tests ${{ matrix.testnet}}").steps[] | select(.name == "Run Tests").conclusion')" + echo "thread_ts=${{ needs.testnet-smoke-tests-notify.outputs.thread_ts }}" + + - name: Test Details + uses: slackapi/slack-github-action@e28cf165c92ffef168d23c5c9000cffc8a25e117 # v1.24.0 with: - basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} - hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} - this-job-name: Live Testnet Smoke Tests ${{ matrix.testnet }} - test-results-file: '{"testType":"go","filePath":"/tmp/gotest.log"}' - continue-on-error: true + channel-id: ${{ secrets.QA_SLACK_CHANNEL }} + payload: | + { + "thread_ts": "${{ needs.testnet-smoke-tests-notify.outputs.thread_ts }}", + "attachments": [ + { + "color": "${{ steps.test-results.outputs.status == 'success' && '#2E7D32' || '#C62828' }}", + "blocks": [ + { + "type": "header", + "text": { + "type": "plain_text", + "text": "${{ matrix.testnet }} Smoke Test Results ${{ steps.test-results.outputs.status == 'success' && ':white_check_mark:' || ':x:'}}", + "emoji": true + } + }, + { + "type": "divider" + }, + { + "type": "section", + "text": { + "type": "mrkdwn", + "text": "OCR ${{ steps.test-results.outputs.status == 'success' && ':white_check_mark:' || ':x:'}}" + } + } + ] + } + ] + } + env: + SLACK_BOT_TOKEN: ${{ secrets.QA_SLACK_API_KEY }} - ### End Live Testnet Section + ### End Live Testnet Section \ No newline at end of file From c57dd76f53ca2fd7ff8b5c725b369ce27d775463 Mon Sep 17 00:00:00 2001 From: ferglor <19188060+ferglor@users.noreply.github.com> Date: Mon, 7 Aug 2023 21:14:34 +0100 Subject: [PATCH 105/270] keepers 2.1 alpha e2e integration (#10060) * This time exclude evm21 from the rebase * Fix imports * Use contract version to determine if we should create v2.0 or v2.1 dependencies * Undo general evm changes * More undo * Rework delegate with minimal changes * added integration tests (wip) - log upkeep - conditional upkeep * revert mercury provider changes * remove empty line * skip log upkeep test in CI * update dependencies * build mercury integration test * fix ContractSetConfigArgsForTestsOCR3 * fix forwarder logic dependency * Add a nil check for the keeper spec * Move ContractVersion into the PluginConfig * fix job spec in 2.1 integration test * Encoding hack for upkeepID * fix dependencies and integration test * fix test * Tidy go mod * Fix diff --------- Co-authored-by: amirylm Co-authored-by: Akshay Aggarwal Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Co-authored-by: Amir Y <83904651+amirylm@users.noreply.github.com> --- core/services/ocr2/delegate.go | 148 +++++- .../ocr2/plugins/ocr2keeper/config.go | 2 + .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 3 +- .../plugins/ocr2keeper/evm21/encoder_test.go | 18 +- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 14 +- .../plugins/ocr2keeper/integration_21_test.go | 494 +++++++++++++++++- core/services/ocr2/plugins/ocr2keeper/util.go | 34 +- core/services/relay/evm/ocr2keeper.go | 37 ++ 8 files changed, 713 insertions(+), 37 deletions(-) diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index d80aeab6c82..107fe31494c 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -9,19 +9,20 @@ import ( "math/big" "time" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" "gopkg.in/guregu/null.v4" "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" + "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" + "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" + "github.com/smartcontractkit/ocr2keepers/pkg/runner" "github.com/smartcontractkit/libocr/commontypes" libocr2 "github.com/smartcontractkit/libocr/offchainreporting2plus" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" "github.com/smartcontractkit/ocr2keepers/pkg/config" - "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" - "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" - "github.com/smartcontractkit/ocr2keepers/pkg/runner" "github.com/smartcontractkit/ocr2vrf/altbn_128" dkgpkg "github.com/smartcontractkit/ocr2vrf/dkg" "github.com/smartcontractkit/ocr2vrf/ocr2vrf" @@ -827,21 +828,139 @@ func (d *Delegate) newServicesOCR2Keepers( lc ocrtypes.LocalConfig, ocrLogger commontypes.Logger, ) ([]job.ServiceCtx, error) { - keeperProvider, rgstry, encoder, logProvider, err2 := ocr2keeper.EVMDependencies20(jb, d.db, lggr, d.chainSet, d.pipelineRunner) + spec := jb.OCR2OracleSpec + var cfg ocr2keeper.PluginConfig + if err := json.Unmarshal(spec.PluginConfig.Bytes(), &cfg); err != nil { + return nil, errors.Wrap(err, "unmarshal ocr2keepers plugin config") + } + + if err := ocr2keeper.ValidatePluginConfig(cfg); err != nil { + return nil, errors.Wrap(err, "ocr2keepers plugin config validation failure") + } + + switch cfg.ContractVersion { + case "v2.1": + return d.newServicesOCR2Keepers21(lggr, jb, runResults, bootstrapPeers, kb, ocrDB, lc, ocrLogger, cfg, spec) + case "v2.0": + return d.newServicesOCR2Keepers20(lggr, jb, runResults, bootstrapPeers, kb, ocrDB, lc, ocrLogger, cfg, spec) + default: + return d.newServicesOCR2Keepers20(lggr, jb, runResults, bootstrapPeers, kb, ocrDB, lc, ocrLogger, cfg, spec) + } +} + +func (d *Delegate) newServicesOCR2Keepers21( + lggr logger.SugaredLogger, + jb job.Job, + runResults chan pipeline.Run, + bootstrapPeers []commontypes.BootstrapperLocator, + kb ocr2key.KeyBundle, + ocrDB *db, + lc ocrtypes.LocalConfig, + ocrLogger commontypes.Logger, + cfg ocr2keeper.PluginConfig, + spec *job.OCR2OracleSpec, +) ([]job.ServiceCtx, error) { + credName, err2 := jb.OCR2OracleSpec.PluginConfig.MercuryCredentialName() if err2 != nil { - return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") + return nil, errors.Wrap(err2, "failed to get mercury credential name") } - spec := jb.OCR2OracleSpec - var cfg ocr2keeper.PluginConfig - err2 = json.Unmarshal(spec.PluginConfig.Bytes(), &cfg) + mc := d.cfg.Mercury().Credentials(credName) + + keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, d.chainSet, d.pipelineRunner, mc, kb) if err2 != nil { - return nil, errors.Wrap(err2, "unmarshal ocr2keepers plugin config") + return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") + } + + // set some defaults + conf := config.ReportingFactoryConfig{ + CacheExpiration: config.DefaultCacheExpiration, + CacheEvictionInterval: config.DefaultCacheClearInterval, + MaxServiceWorkers: config.DefaultMaxServiceWorkers, + ServiceQueueLength: config.DefaultServiceQueueLength, } - err2 = ocr2keeper.ValidatePluginConfig(cfg) + // override if set in config + if cfg.CacheExpiration.Value() != 0 { + conf.CacheExpiration = cfg.CacheExpiration.Value() + } + + if cfg.CacheEvictionInterval.Value() != 0 { + conf.CacheEvictionInterval = cfg.CacheEvictionInterval.Value() + } + + if cfg.MaxServiceWorkers != 0 { + conf.MaxServiceWorkers = cfg.MaxServiceWorkers + } + + if cfg.ServiceQueueLength != 0 { + conf.ServiceQueueLength = cfg.ServiceQueueLength + } + + dConf := plugin.DelegateConfig{ + BinaryNetworkEndpointFactory: d.peerWrapper.Peer2, + V2Bootstrappers: bootstrapPeers, + ContractTransmitter: evmrelay.NewKeepersOCR3ContractTransmitter(keeperProvider.ContractTransmitter()), + ContractConfigTracker: keeperProvider.ContractConfigTracker(), + KeepersDatabase: ocrDB, + LocalConfig: lc, + Logger: ocrLogger, + MonitoringEndpoint: d.monitoringEndpointGen.GenMonitoringEndpoint(spec.ContractID, synchronization.OCR2Automation), + OffchainConfigDigester: keeperProvider.OffchainConfigDigester(), + OffchainKeyring: kb, + OnchainKeyring: wrappedKey, + EventProvider: transmitEventProvider, + Encoder: encoder, + Runnable: rgstry, + LogProvider: logProvider, + CacheExpiration: cfg.CacheExpiration.Value(), + CacheEvictionInterval: cfg.CacheEvictionInterval.Value(), + MaxServiceWorkers: cfg.MaxServiceWorkers, + ServiceQueueLength: cfg.ServiceQueueLength, + BlockSubscriber: blockSub, + RecoverableProvider: new(mockRecoverableProvider), + } + + pluginService, err := plugin.NewDelegate(dConf) + if err != nil { + return nil, errors.Wrap(err, "could not create new keepers ocr2 delegate") + } + + // RunResultSaver needs to be started first, so it's available + // to read odb writes. It is stopped last after the OraclePlugin is shut down + // so no further runs are enqueued, and we can drain the queue. + runResultSaver := ocrcommon.NewResultRunSaver( + runResults, + d.pipelineRunner, + make(chan struct{}), + lggr, + d.cfg.JobPipeline().MaxSuccessfulRuns(), + ) + + return []job.ServiceCtx{ + runResultSaver, + keeperProvider, + rgstry, + transmitEventProvider, + pluginService, + }, nil +} + +func (d *Delegate) newServicesOCR2Keepers20( + lggr logger.SugaredLogger, + jb job.Job, + runResults chan pipeline.Run, + bootstrapPeers []commontypes.BootstrapperLocator, + kb ocr2key.KeyBundle, + ocrDB *db, + lc ocrtypes.LocalConfig, + ocrLogger commontypes.Logger, + cfg ocr2keeper.PluginConfig, + spec *job.OCR2OracleSpec, +) ([]job.ServiceCtx, error) { + keeperProvider, rgstry, encoder, logProvider, err2 := ocr2keeper.EVMDependencies20(jb, d.db, lggr, d.chainSet, d.pipelineRunner) if err2 != nil { - return nil, errors.Wrap(err2, "ocr2keepers plugin config validation failure") + return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") } w := &logWriter{log: lggr.Named("Automation Dependencies")} @@ -1122,3 +1241,10 @@ func (l *logWriter) Write(p []byte) (n int, err error) { n = len(p) return } + +type mockRecoverableProvider struct { +} + +func (_m *mockRecoverableProvider) GetRecoverables() ([]ocr2keepers.UpkeepPayload, error) { + return nil, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/config.go b/core/services/ocr2/plugins/ocr2keeper/config.go index 99555c1f9c7..63751dabc27 100644 --- a/core/services/ocr2/plugins/ocr2keeper/config.go +++ b/core/services/ocr2/plugins/ocr2keeper/config.go @@ -52,6 +52,8 @@ type PluginConfig struct { // workers or slower RPC responses will cause this queue to build up. // Adding new items to the queue will block if the queue becomes full. ServiceQueueLength int `json:"serviceQueueLength"` + // ContractVersion is the contract version + ContractVersion string `json:"contractVersion"` } func ValidatePluginConfig(cfg PluginConfig) error { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index e347d815782..46ed1c56218 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -84,7 +84,8 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] id, ok := big.NewInt(0).SetString(string(result.Payload.Upkeep.ID), 10) if !ok { - return nil, fmt.Errorf("failed to parse big int from upkeep id: %s", string(result.Payload.Upkeep.ID)) + // TODO auto 4204: handle properly, this is just for happy path + id = big.NewInt(0).SetBytes(result.Payload.Upkeep.ID) } report.UpkeepIds[i] = id report.GasLimits[i] = big.NewInt(0).SetUint64(result.GasAllocated) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go index 435a44c431a..d2bce136372 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go @@ -129,14 +129,16 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { assert.Equal(t, err.Error(), "unrecognized CheckResult extension data") }) - t.Run("an invalid upkeep ID causes an error", func(t *testing.T) { - result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1, 1) - result.Payload.Upkeep.ID = []byte("invalid") - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "failed to parse big int from upkeep id: invalid") - }) + // TODO auto 4204: handle upkeep ID decoding properly + /* + t.Run("an invalid upkeep ID causes an error", func(t *testing.T) { + result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1, 1) + result.Payload.Upkeep.ID = []byte("invalid") + b, err := encoder.Encode(result) + assert.Nil(t, b) + assert.Error(t, err) + assert.Equal(t, err.Error(), "failed to parse big int from upkeep id: invalid") + })*/ t.Run("a non-LogTriggerExtension extension causes an error", func(t *testing.T) { result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 06366bde654..2514fc0ffb6 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -79,25 +79,25 @@ type LatestBlockGetter interface { LatestBlock() int64 } -func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.MercuryCredentials, lggr logger.Logger) (*EvmRegistry, error) { +func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.MercuryCredentials, lggr logger.Logger) (*EvmRegistry, *EVMAutomationEncoder21, error) { feedLookupCompatibleABI, err := abi.JSON(strings.NewReader(feed_lookup_compatible_interface.FeedLookupCompatibleInterfaceABI)) if err != nil { - return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) } keeperRegistryABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) if err != nil { - return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) } utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) if err != nil { - return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) } packer := NewEvmRegistryPackerV2_1(keeperRegistryABI, utilsABI) logPacker := logprovider.NewLogEventsPacker(utilsABI) registry, err := iregistry21.NewIKeeperRegistryMaster(addr, client.Client()) if err != nil { - return nil, fmt.Errorf("%w: failed to create caller for address and backend", ErrInitializationFailure) + return nil, nil, fmt.Errorf("%w: failed to create caller for address and backend", ErrInitializationFailure) } filterStore := logprovider.NewUpkeepFilterStore() @@ -127,10 +127,10 @@ func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.Mer } if err := r.registerEvents(client.ID().Uint64(), addr); err != nil { - return nil, fmt.Errorf("logPoller error while registering automation events: %w", err) + return nil, nil, fmt.Errorf("logPoller error while registering automation events: %w", err) } - return r, nil + return r, &r.enc, nil } var upkeepStateEvents = []common.Hash{ diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go index f207f4e209a..2fd21d400c7 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go @@ -1,18 +1,52 @@ package ocr2keeper_test import ( + "context" "crypto/rand" + "encoding/hex" + "encoding/json" + "fmt" + "math/big" + "strings" + "sync" "testing" + "time" + "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" - + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/eth/ethconfig" + "github.com/onsi/gomega" + "github.com/smartcontractkit/libocr/commontypes" + "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + ocrTypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/smartcontractkit/ocr2keepers/pkg/config" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" + "github.com/umbracle/ethgo/abi" + "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + automationForwarderLogic "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_forwarder_logic" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/basic_upkeep_contract" + iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" + registrylogica21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1" + registrylogicb21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1" + registry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/log_upkeep_counter_wrapper" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_v3_aggregator_contract" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper" + "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) func TestFilterNamesFromSpec21(t *testing.T) { @@ -40,3 +74,461 @@ func TestFilterNamesFromSpec21(t *testing.T) { _, err = ocr2keeper.FilterNamesFromSpec21(spec) require.ErrorContains(t, err, "not a valid EIP55 formatted address") } + +func TestIntegration_KeeperPluginConditionalUpkeep(t *testing.T) { + t.Skip() // TODO: unskip when conditional flow is ready + + g := gomega.NewWithT(t) + lggr := logger.TestLogger(t) + + // setup blockchain + sergey := testutils.MustNewSimTransactor(t) // owns all the link + steve := testutils.MustNewSimTransactor(t) // registry owner + carrol := testutils.MustNewSimTransactor(t) // upkeep owner + genesisData := core.GenesisAlloc{ + sergey.From: {Balance: assets.Ether(10000).ToInt()}, + steve.From: {Balance: assets.Ether(10000).ToInt()}, + carrol.From: {Balance: assets.Ether(10000).ToInt()}, + } + // Generate 5 keys for nodes (1 bootstrap + 4 ocr nodes) and fund them with ether + var nodeKeys [5]ethkey.KeyV2 + for i := int64(0); i < 5; i++ { + nodeKeys[i] = cltest.MustGenerateRandomKey(t) + genesisData[nodeKeys[i].Address] = core.GenesisAccount{Balance: assets.Ether(1000).ToInt()} + } + + backend := cltest.NewSimulatedBackend(t, genesisData, uint32(ethconfig.Defaults.Miner.GasCeil)) + stopMining := cltest.Mine(backend, 3*time.Second) // Should be greater than deltaRound since we cannot access old blocks on simulated blockchain + defer stopMining() + + // Deploy registry + linkAddr, _, linkToken, err := link_token_interface.DeployLinkToken(sergey, backend) + require.NoError(t, err) + gasFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(steve, backend, 18, big.NewInt(60000000000)) + require.NoError(t, err) + linkFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(steve, backend, 18, big.NewInt(2000000000000000000)) + require.NoError(t, err) + registry := deployKeeper21Registry(t, steve, backend, linkAddr, linkFeedAddr, gasFeedAddr) + + nodes := setupNodes(t, nodeKeys, registry, backend, steve) + + <-time.After(time.Second * 5) + + upkeeps := 1 + + _, err = linkToken.Transfer(sergey, carrol.From, big.NewInt(0).Mul(oneHunEth, big.NewInt(int64(upkeeps+1)))) + require.NoError(t, err) + + // Register new upkeep + upkeepAddr, _, upkeepContract, err := basic_upkeep_contract.DeployBasicUpkeepContract(carrol, backend) + require.NoError(t, err) + registrationTx, err := registry.RegisterUpkeep(steve, upkeepAddr, 2_500_000, carrol.From, 0, []byte{}, []byte{}, []byte{}) + require.NoError(t, err) + backend.Commit() + upkeepID := getUpkeepIdFromTx21(t, registry, registrationTx, backend) + + // Fund the upkeep + _, err = linkToken.Transfer(sergey, carrol.From, oneHunEth) + require.NoError(t, err) + _, err = linkToken.Approve(carrol, registry.Address(), oneHunEth) + require.NoError(t, err) + _, err = registry.AddFunds(carrol, upkeepID, oneHunEth) + require.NoError(t, err) + backend.Commit() + + // Set upkeep to be performed + _, err = upkeepContract.SetBytesToSend(carrol, payload1) + require.NoError(t, err) + _, err = upkeepContract.SetShouldPerformUpkeep(carrol, true) + require.NoError(t, err) + backend.Commit() + + lggr.Infow("Upkeep registered and funded", "upkeepID", upkeepID.String()) + + // keeper job is triggered and payload is received + receivedBytes := func() []byte { + received, err2 := upkeepContract.ReceivedBytes(nil) + require.NoError(t, err2) + return received + } + g.Eventually(receivedBytes, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.Equal(payload1)) + + // check pipeline runs + var allRuns []pipeline.Run + for _, node := range nodes { + runs, err2 := node.App.PipelineORM().GetAllRuns() + require.NoError(t, err2) + allRuns = append(allRuns, runs...) + } + require.GreaterOrEqual(t, len(allRuns), 1) + + // change payload + _, err = upkeepContract.SetBytesToSend(carrol, payload2) + require.NoError(t, err) + _, err = upkeepContract.SetShouldPerformUpkeep(carrol, true) + require.NoError(t, err) + + // observe 2nd job run and received payload changes + g.Eventually(receivedBytes, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.Equal(payload2)) +} + +func TestIntegration_KeeperPluginLogUpkeep(t *testing.T) { + t.Skip() // TODO: Auto-4282, Run this in CI once the tests properly waits instead of timers + g := gomega.NewWithT(t) + + // setup blockchain + sergey := testutils.MustNewSimTransactor(t) // owns all the link + steve := testutils.MustNewSimTransactor(t) // registry owner + carrol := testutils.MustNewSimTransactor(t) // upkeep owner + genesisData := core.GenesisAlloc{ + sergey.From: {Balance: assets.Ether(10000).ToInt()}, + steve.From: {Balance: assets.Ether(10000).ToInt()}, + carrol.From: {Balance: assets.Ether(10000).ToInt()}, + } + // Generate 5 keys for nodes (1 bootstrap + 4 ocr nodes) and fund them with ether + var nodeKeys [5]ethkey.KeyV2 + for i := int64(0); i < 5; i++ { + nodeKeys[i] = cltest.MustGenerateRandomKey(t) + genesisData[nodeKeys[i].Address] = core.GenesisAccount{Balance: assets.Ether(1000).ToInt()} + } + + backend := cltest.NewSimulatedBackend(t, genesisData, uint32(ethconfig.Defaults.Miner.GasCeil)) + stopMining := cltest.Mine(backend, 3*time.Second) // Should be greater than deltaRound since we cannot access old blocks on simulated blockchain + defer stopMining() + + // Deploy registry + linkAddr, _, linkToken, err := link_token_interface.DeployLinkToken(sergey, backend) + require.NoError(t, err) + gasFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(steve, backend, 18, big.NewInt(60000000000)) + require.NoError(t, err) + linkFeedAddr, _, _, err := mock_v3_aggregator_contract.DeployMockV3AggregatorContract(steve, backend, 18, big.NewInt(2000000000000000000)) + require.NoError(t, err) + registry := deployKeeper21Registry(t, steve, backend, linkAddr, linkFeedAddr, gasFeedAddr) + + nodes := setupNodes(t, nodeKeys, registry, backend, steve) + + <-time.After(time.Second * 5) + + upkeeps := 1 + + _, err = linkToken.Transfer(sergey, carrol.From, big.NewInt(0).Mul(oneHunEth, big.NewInt(int64(upkeeps+1)))) + require.NoError(t, err) + ids, _, contracts := deployUpkeeps(t, backend, carrol, steve, linkToken, registry, upkeeps) + require.Equal(t, upkeeps, len(ids)) + require.Equal(t, len(contracts), len(ids)) + backend.Commit() + + go func(contracts []*log_upkeep_counter_wrapper.LogUpkeepCounter) { + <-time.After(time.Second * 5) + ctx := testutils.Context(t) + emits := 10 + for i := 0; i < emits || ctx.Err() != nil; i++ { + <-time.After(time.Second) + t.Logf("EvmRegistry: calling upkeep contracts to emit events. run: %d", i+1) + for _, contract := range contracts { + _, err = contract.Start(carrol) + require.NoError(t, err) + backend.Commit() + } + } + }(contracts) + + performed := listenPerformed(t, backend, registry, ids) + + receivedPerformedEvents := func() bool { + count := 0 + performed.Range(func(key, value interface{}) bool { + count++ + return true + }) + return count > 0 + } + g.Eventually(receivedPerformedEvents, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.BeTrue()) + + // check pipeline runs + var allRuns []pipeline.Run + for _, node := range nodes { + runs, err2 := node.App.PipelineORM().GetAllRuns() + require.NoError(t, err2) + allRuns = append(allRuns, runs...) + } + + require.GreaterOrEqual(t, len(allRuns), 1) +} + +func listenPerformed(t *testing.T, backend *backends.SimulatedBackend, registry *iregistry21.IKeeperRegistryMaster, ids []*big.Int) *sync.Map { + performed := &sync.Map{} + + go func() { + ctx, cancel := context.WithCancel(testutils.Context(t)) + defer cancel() + + for ctx.Err() == nil { + bl := backend.Blockchain().CurrentBlock().Number.Uint64() + sc := make([]bool, len(ids)) + for i := range sc { + sc[i] = true + } + iter, err := registry.FilterUpkeepPerformed(&bind.FilterOpts{ + Start: 0, + End: &bl, + Context: testutils.Context(t), + }, ids, sc) + require.NoError(t, err) + for iter.Next() { + if iter.Event != nil { + t.Log("EvmRegistry: upkeep performed event emitted") + performed.Store(iter.Event.Id, true) + } + } + time.Sleep(time.Second) + } + }() + return performed +} + +func setupNodes(t *testing.T, nodeKeys [5]ethkey.KeyV2, registry *iregistry21.IKeeperRegistryMaster, backend *backends.SimulatedBackend, usr *bind.TransactOpts) []Node { + lggr := logger.TestLogger(t) + // Setup bootstrap + oracle nodes + bootstrapNodePort := int64(19599) + appBootstrap, bootstrapPeerID, bootstrapTransmitter, bootstrapKb := setupNode(t, bootstrapNodePort, "bootstrap_keeper_ocr", nodeKeys[0], backend, nil) + bootstrapNode := Node{ + appBootstrap, bootstrapTransmitter, bootstrapKb, + } + var ( + oracles []confighelper.OracleIdentityExtra + nodes []Node + ) + // Set up the minimum 4 oracles all funded + for i := int64(0); i < 4; i++ { + app, peerID, transmitter, kb := setupNode(t, bootstrapNodePort+i+1, fmt.Sprintf("oracle_keeper%d", i), nodeKeys[i+1], backend, []commontypes.BootstrapperLocator{ + // Supply the bootstrap IP and port as a V2 peer address + {PeerID: bootstrapPeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", bootstrapNodePort)}}, + }) + + nodes = append(nodes, Node{ + app, transmitter, kb, + }) + offchainPublicKey, _ := hex.DecodeString(strings.TrimPrefix(kb.OnChainPublicKey(), "0x")) + oracles = append(oracles, confighelper.OracleIdentityExtra{ + OracleIdentity: confighelper.OracleIdentity{ + OnchainPublicKey: offchainPublicKey, + TransmitAccount: ocrTypes.Account(transmitter.String()), + OffchainPublicKey: kb.OffchainPublicKey(), + PeerID: peerID, + }, + ConfigEncryptionPublicKey: kb.ConfigEncryptionPublicKey(), + }) + } + // Add the bootstrap job + bootstrapNode.AddBootstrapJob(t, fmt.Sprintf(` + type = "bootstrap" + relay = "evm" + schemaVersion = 1 + name = "boot" + contractID = "%s" + contractConfigTrackerPollInterval = "15s" + + [relayConfig] + chainID = 1337 + `, registry.Address())) + + // Add OCR jobs + for i, node := range nodes { + node.AddJob(t, fmt.Sprintf(` + type = "offchainreporting2" + pluginType = "ocr2automation" + relay = "evm" + name = "ocr2keepers-%d" + schemaVersion = 1 + contractID = "%s" + contractConfigTrackerPollInterval = "15s" + ocrKeyBundleID = "%s" + transmitterID = "%s" + p2pv2Bootstrappers = [ + "%s" + ] + + [relayConfig] + chainID = 1337 + + [pluginConfig] + maxServiceWorkers = 100 + cacheEvictionInterval = "1s" + mercuryCredentialName = "%s" + contractVersion = "v2.1" + `, i, registry.Address(), node.KeyBundle.ID(), node.Transmitter, fmt.Sprintf("%s@127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), MercuryCredName)) + } + + // Setup config on contract + configType := abi.MustNewType("tuple(uint32 paymentPremiumPPB,uint32 flatFeeMicroLink,uint32 checkGasLimit,uint24 stalenessSeconds,uint16 gasCeilingMultiplier,uint96 minUpkeepSpend,uint32 maxPerformGas,uint32 maxCheckDataSize,uint32 maxPerformDataSize,uint32 maxRevertDataSize, uint256 fallbackGasPrice,uint256 fallbackLinkPrice,address transcoder,address[] registrars, address upkeepPrivilegeManager)") + onchainConfig, err := abi.Encode(map[string]interface{}{ + "paymentPremiumPPB": uint32(0), + "flatFeeMicroLink": uint32(0), + "checkGasLimit": uint32(6500000), + "stalenessSeconds": uint32(90000), + "gasCeilingMultiplier": uint16(2), + "minUpkeepSpend": uint32(0), + "maxPerformGas": uint32(5000000), + "maxCheckDataSize": uint32(5000), + "maxPerformDataSize": uint32(5000), + "maxRevertDataSize": uint32(5000), + "fallbackGasPrice": big.NewInt(60000000000), + "fallbackLinkPrice": big.NewInt(2000000000000000000), + "transcoder": testutils.NewAddress(), + "registrars": []common.Address{testutils.NewAddress()}, + "upkeepPrivilegeManager": testutils.NewAddress(), + }, configType) + require.NoError(t, err) + rawCfg, err := json.Marshal(config.OffchainConfig{ + PerformLockoutWindow: 100 * 12 * 1000, // ~100 block lockout (on goerli) + MinConfirmations: 1, + }) + if err != nil { + t.Logf("error creating off-chain config: %s", err) + t.FailNow() + } + + // TODO: Use ocr3confighelper instead + signers, transmitters, threshold, onchainConfig, offchainConfigVersion, offchainConfig, err := confighelper.ContractSetConfigArgsForTestsOCR3( + 5*time.Second, // deltaProgress time.Duration, + 10*time.Second, // deltaResend time.Duration, + 100*time.Millisecond, // deltaInitial time.Duration, + 2500*time.Millisecond, // deltaRound time.Duration, + 40*time.Millisecond, // deltaGrace time.Duration, + 200*time.Millisecond, // deltaRequestCertifiedCommit time.Duration, + 30*time.Second, // deltaStage time.Duration, + uint64(50), // rMax uint8, + []int{1, 1, 1, 1}, // s []int, + oracles, // oracles []OracleIdentityExtra, + rawCfg, // reportingPluginConfig []byte, + 20*time.Millisecond, // maxDurationQuery time.Duration, + 1600*time.Millisecond, // maxDurationObservation time.Duration, + 20*time.Millisecond, // maxDurationShouldAcceptFinalizedReport time.Duration, + 20*time.Millisecond, // maxDurationShouldTransmitAcceptedReport time.Duration, + 1, // f int, + onchainConfig, // onchainConfig []byte, + ) + + require.NoError(t, err) + signerAddresses, err := evm.OnchainPublicKeyToAddress(signers) + require.NoError(t, err) + transmitterAddresses, err := accountsToAddress(transmitters) + require.NoError(t, err) + + lggr.Infow("Setting Config on Oracle Contract", + "signerAddresses", signerAddresses, + "transmitterAddresses", transmitterAddresses, + "threshold", threshold, + "onchainConfig", onchainConfig, + "encodedConfigVersion", offchainConfigVersion, + "offchainConfig", offchainConfig, + ) + _, err = registry.SetConfig( + usr, + signerAddresses, + transmitterAddresses, + threshold, + onchainConfig, + offchainConfigVersion, + offchainConfig, + ) + require.NoError(t, err) + backend.Commit() + + return nodes +} + +func deployUpkeeps(t *testing.T, backend *backends.SimulatedBackend, carrol, steve *bind.TransactOpts, linkToken *link_token_interface.LinkToken, registry *iregistry21.IKeeperRegistryMaster, n int) ([]*big.Int, []common.Address, []*log_upkeep_counter_wrapper.LogUpkeepCounter) { + ids := make([]*big.Int, n) + addrs := make([]common.Address, n) + contracts := make([]*log_upkeep_counter_wrapper.LogUpkeepCounter, n) + for i := 0; i < n; i++ { + backend.Commit() + time.Sleep(1 * time.Second) + upkeepAddr, _, upkeepContract, err := log_upkeep_counter_wrapper.DeployLogUpkeepCounter( + carrol, backend, + big.NewInt(100000), + ) + require.NoError(t, err) + logTriggerConfigType := abi.MustNewType("tuple(address contractAddress, uint8 filterSelector, bytes32 topic0, bytes32 topic1, bytes32 topic2, bytes32 topic3)") + logTriggerConfig, err := abi.Encode(map[string]interface{}{ + "contractAddress": upkeepAddr, + "filterSelector": 0, // no indexed topics filtered + "topic0": "0x3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d", // event sig for Trigger() + "topic1": "0x", + "topic2": "0x", + "topic3": "0x", + }, logTriggerConfigType) + require.NoError(t, err) + + registrationTx, err := registry.RegisterUpkeep(steve, upkeepAddr, 2_500_000, carrol.From, 1, []byte{}, logTriggerConfig, []byte{}) + require.NoError(t, err) + backend.Commit() + upkeepID := getUpkeepIdFromTx21(t, registry, registrationTx, backend) + + // Fund the upkeep + _, err = linkToken.Approve(carrol, registry.Address(), oneHunEth) + require.NoError(t, err) + _, err = registry.AddFunds(carrol, upkeepID, oneHunEth) + require.NoError(t, err) + backend.Commit() + + ids[i] = upkeepID + contracts[i] = upkeepContract + addrs[i] = upkeepAddr + } + return ids, addrs, contracts +} + +func deployKeeper21Registry( + t *testing.T, + auth *bind.TransactOpts, + backend *backends.SimulatedBackend, + linkAddr, linkFeedAddr, + gasFeedAddr common.Address, +) *iregistry21.IKeeperRegistryMaster { + automationForwarderLogicAddr, _, _, err := automationForwarderLogic.DeployAutomationForwarderLogic(auth, backend) + require.NoError(t, err) + backend.Commit() + registryLogicBAddr, _, _, err := registrylogicb21.DeployKeeperRegistryLogicB( + auth, + backend, + 0, // Payment model + linkAddr, + linkFeedAddr, + gasFeedAddr, + automationForwarderLogicAddr, + ) + require.NoError(t, err) + backend.Commit() + + registryLogicAAddr, _, _, err := registrylogica21.DeployKeeperRegistryLogicA( + auth, + backend, + registryLogicBAddr, + ) + require.NoError(t, err) + backend.Commit() + + registryAddr, _, _, err := registry21.DeployKeeperRegistry( + auth, + backend, + registryLogicAAddr, + ) + require.NoError(t, err) + backend.Commit() + + registryMaster, err := iregistry21.NewIKeeperRegistryMaster(registryAddr, backend) + require.NoError(t, err) + + return registryMaster +} + +func getUpkeepIdFromTx21(t *testing.T, registry *iregistry21.IKeeperRegistryMaster, registrationTx *types.Transaction, backend *backends.SimulatedBackend) *big.Int { + receipt, err := backend.TransactionReceipt(testutils.Context(t), registrationTx.Hash()) + require.NoError(t, err) + parsedLog, err := registry.ParseUpkeepRegistered(*receipt.Logs[0]) + require.NoError(t, err) + return parsedLog.Id +} diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index ed699cfaabe..bc938ed6a80 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -4,6 +4,8 @@ import ( "fmt" "math/big" + "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" @@ -64,7 +66,13 @@ func EVMProvider(db *sqlx.DB, chain evm.Chain, lggr logger.Logger, spec job.Job, return keeperProvider, nil } -func EVMDependencies20(spec job.Job, db *sqlx.DB, lggr logger.Logger, set evm.ChainSet, pr pipeline.Runner) (evmrelay.OCR2KeeperProvider, *kevm20.EvmRegistry, Encoder, *kevm20.LogProvider, error) { +func EVMDependencies20( + spec job.Job, + db *sqlx.DB, + lggr logger.Logger, + set evm.ChainSet, + pr pipeline.Runner, +) (evmrelay.OCR2KeeperProvider, *kevm20.EvmRegistry, Encoder, *kevm20.LogProvider, error) { var err error var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider @@ -111,34 +119,42 @@ func FilterNamesFromSpec20(spec *job.OCR2OracleSpec) (names []string, err error) return []string{kevm20.LogProviderFilterName(addr.Address()), kevm20.UpkeepFilterName(addr.Address())}, err } -func EVMDependencies21(spec job.Job, db *sqlx.DB, lggr logger.Logger, set evm.ChainSet, pr pipeline.Runner, mc *models.MercuryCredentials) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, logprovider.LogEventProvider, *kevm21.BlockSubscriber, error) { +func EVMDependencies21( + spec job.Job, + db *sqlx.DB, + lggr logger.Logger, + set evm.ChainSet, + pr pipeline.Runner, + mc *models.MercuryCredentials, + keyring ocrtypes.OnchainKeyring, +) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, logprovider.LogEventProvider, ocr3types.OnchainKeyring[plugin.AutomationReportInfo], *kevm21.BlockSubscriber, error) { var err error var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider var registry *kevm21.EvmRegistry + var encoder *kevm21.EVMAutomationEncoder21 oSpec := spec.OCR2OracleSpec // get the chain from the config chainID, err2 := spec.OCR2OracleSpec.RelayConfig.EVMChainID() if err2 != nil { - return nil, nil, nil, nil, nil, nil, err2 + return nil, nil, nil, nil, nil, nil, nil, err2 } chain, err2 = set.Get(big.NewInt(chainID)) if err2 != nil { - return nil, nil, nil, nil, nil, nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err2) + return nil, nil, nil, nil, nil, nil, nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err2) } // the provider will be returned as a dependency if keeperProvider, err = EVMProvider(db, chain, lggr, spec, pr); err != nil { - return nil, nil, nil, nil, nil, nil, err + return nil, nil, nil, nil, nil, nil, nil, err } rAddr := ethkey.MustEIP55Address(oSpec.ContractID).Address() - if registry, err = kevm21.NewEVMRegistryService(rAddr, chain, mc, lggr); err != nil { - return nil, nil, nil, nil, nil, nil, err + if registry, encoder, err = kevm21.NewEVMRegistryService(rAddr, chain, mc, lggr); err != nil { + return nil, nil, nil, nil, nil, nil, nil, err } - encoder := kevm21.EVMAutomationEncoder21{} hp := kevm21.NewBlockSubscriber(chain.HeadBroadcaster(), chain.LogPoller(), 128, lggr) @@ -148,7 +164,7 @@ func EVMDependencies21(spec job.Job, db *sqlx.DB, lggr logger.Logger, set evm.Ch // TODO: accept a version of the registry contract and use the correct interfaces logTransmitter, err := kevm21.NewTransmitEventProvider(lggr, chain.LogPoller(), rAddr, chain.Client(), lookbackBlocks) - return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), hp, err + return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), kevm21.NewOnchainKeyringV3Wrapper(keyring), hp, err } func FilterNamesFromSpec21(spec *job.OCR2OracleSpec) (names []string, err error) { diff --git a/core/services/relay/evm/ocr2keeper.go b/core/services/relay/evm/ocr2keeper.go index 3c6fee4f9af..c6f4f1ad395 100644 --- a/core/services/relay/evm/ocr2keeper.go +++ b/core/services/relay/evm/ocr2keeper.go @@ -1,6 +1,7 @@ package evm import ( + "context" "encoding/json" "fmt" "strings" @@ -10,6 +11,8 @@ import ( "github.com/pkg/errors" "github.com/smartcontractkit/libocr/gethwrappers2/ocr2aggregator" "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" + "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" "github.com/smartcontractkit/sqlx" relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" @@ -83,6 +86,40 @@ func (r *ocr2keeperRelayer) NewOCR2KeeperProvider(rargs relaytypes.RelayArgs, pa }, nil } +type ocr3keeperProviderContractTransmitter struct { + contractTransmitter ocrtypes.ContractTransmitter +} + +var _ ocr3types.ContractTransmitter[plugin.AutomationReportInfo] = &ocr3keeperProviderContractTransmitter{} + +func NewKeepersOCR3ContractTransmitter(ocr2ContractTransmitter ocrtypes.ContractTransmitter) *ocr3keeperProviderContractTransmitter { + return &ocr3keeperProviderContractTransmitter{ocr2ContractTransmitter} +} + +func (t *ocr3keeperProviderContractTransmitter) Transmit( + ctx context.Context, + digest ocrtypes.ConfigDigest, + seqNr uint64, + reportWithInfo ocr3types.ReportWithInfo[plugin.AutomationReportInfo], + aoss []ocrtypes.AttributedOnchainSignature, +) error { + return t.contractTransmitter.Transmit( + ctx, + ocrtypes.ReportContext{ + ReportTimestamp: ocrtypes.ReportTimestamp{ + ConfigDigest: digest, + Epoch: uint32(seqNr), + }, + }, + reportWithInfo.Report, + aoss, + ) +} + +func (t *ocr3keeperProviderContractTransmitter) FromAccount() (ocrtypes.Account, error) { + return t.contractTransmitter.FromAccount() +} + type ocr2keeperProvider struct { *configWatcher contractTransmitter ContractTransmitter From bccc244fb587037e7a7a5c5d3b00e83bbef6e178 Mon Sep 17 00:00:00 2001 From: Tate Date: Mon, 7 Aug 2023 14:47:35 -0600 Subject: [PATCH 106/270] [TT-486] Split packages attempt 2 to only run packages that have tests (#10105) This time includes packages that are test only packages and not associated to another package. --- .github/actions/split-tests/src/handlers/golang.mts | 7 +++++-- .github/actions/split-tests/src/types.mts | 5 +++++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/actions/split-tests/src/handlers/golang.mts b/.github/actions/split-tests/src/handlers/golang.mts index b4e7b1a6317..c017d56db6b 100644 --- a/.github/actions/split-tests/src/handlers/golang.mts +++ b/.github/actions/split-tests/src/handlers/golang.mts @@ -19,11 +19,14 @@ export function getPackageList( ): GetGoPackagesReturn { const { numOfSplits } = config; const rawPackages = execSync( - "go list -json ./... | jq -s '[.[] | {ImportPath, TestGoFiles}]'", + "go list -json ./... | jq -s '[.[] | {ImportPath, TestGoFiles, XTestGoFiles}]'", { encoding: "utf8" } ); const packages: GoPackageData[] = JSON.parse(rawPackages.trimEnd()); - const packagePaths = packages.map((item) => item.ImportPath); + const filteredData = packages.filter( + (item) => (item.TestGoFiles && item.TestGoFiles.length > 0) || (item.XTestGoFiles && item.XTestGoFiles.length > 0) + ); + const packagePaths = filteredData.map((item) => item.ImportPath); return handleSplit(packagePaths, numOfSplits); } diff --git a/.github/actions/split-tests/src/types.mts b/.github/actions/split-tests/src/types.mts index 157680cafb2..1b978ef2e94 100644 --- a/.github/actions/split-tests/src/types.mts +++ b/.github/actions/split-tests/src/types.mts @@ -103,5 +103,10 @@ export interface GoPackageData { * The list of go files asociated with the package */ TestGoFiles: string[] | undefined; + /** + * The list of go files not associated with a specific package + * Things like integration tests + */ + XTestGoFiles: string[] | undefined; // there are many other variables in the data but they are not needed yet } From 017653393e8d47da343b60a2e770d1152601ea6f Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Tue, 8 Aug 2023 12:59:55 +0100 Subject: [PATCH 107/270] Add workID to payload, upkeep payload refactor (#10095) * add workID, add NewUpkeepPayload, and refactor packages * This time exclude evm21 from the rebase * Fix imports * Use contract version to determine if we should create v2.0 or v2.1 dependencies * Undo general evm changes * More undo * Rework delegate with minimal changes * added integration tests (wip) - log upkeep - conditional upkeep * revert mercury provider changes * remove empty line * skip log upkeep test in CI * update dependencies * build mercury integration test * fix ContractSetConfigArgsForTestsOCR3 * fix forwarder logic dependency * Add a nil check for the keeper spec * Move ContractVersion into the PluginConfig * fix job spec in 2.1 integration test * Encoding hack for upkeepID * fix dependencies and integration test * fix test * update ocr2keepers * remove upkeep_info test * fix encoder test errors * fix encoder tests * fix encoder * fix upkeep trigger ID function * remove logTriggerExtension from provider package * refactor trigger pack/unpack * fix go mod * remove obsolete test * improve workID * use ocr2keepers upkeep type * pass upkeep getter in delegate * polish UpkeepTriggerID * handle wid error * add todo * update to ocr2keepers tag * fix workID test * fix go import * fix lint * merge leftovers * clarify import in delegate --------- Co-authored-by: lei shi Co-authored-by: Fergal Gribben Co-authored-by: amirylm --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/services/ocr2/delegate.go | 2 + .../ocr2/plugins/ocr2keeper/evm21/abi.go | 69 ------------ .../ocr2/plugins/ocr2keeper/evm21/abi_test.go | 95 +--------------- .../plugins/ocr2keeper/evm21/core/payload.go | 84 ++++++++++++++ .../ocr2keeper/evm21/core/payload_test.go | 74 +++++++++++++ .../plugins/ocr2keeper/evm21/core/trigger.go | 104 ++++++++++++++++++ .../ocr2keeper/evm21/core/trigger_test.go | 93 ++++++++++++++++ .../evm21/{upkeep_info.go => core/type.go} | 38 ++----- .../ocr2keeper/evm21/core/type_test.go | 65 +++++++++++ .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 35 +++--- .../plugins/ocr2keeper/evm21/encoder_test.go | 86 +++++++-------- .../ocr2keeper/evm21/feed_lookup_test.go | 18 +-- .../ocr2keeper/evm21/logprovider/abi.go | 5 - .../ocr2keeper/evm21/logprovider/provider.go | 11 +- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 23 ++-- .../plugins/ocr2keeper/evm21/registry_test.go | 6 +- .../evm21/transmit_event_provider.go | 9 +- .../evm21/transmit_event_provider_test.go | 4 +- .../ocr2keeper/evm21/upkeep_info_test.go | 97 ---------------- .../ocr2keeper/evm21/upkeep_provider.go | 17 ++- .../ocr2keeper/evm21/upkeep_state_store.go | 14 +-- .../evm21/upkeep_state_store_test.go | 54 +++------ go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 28 files changed, 568 insertions(+), 453 deletions(-) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go rename core/services/ocr2/plugins/ocr2keeper/evm21/{upkeep_info.go => core/type.go} (51%) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go delete mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 727f46913e4..d4c1e87632c 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.3 + github.com/smartcontractkit/ocr2keepers v0.7.5 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 18c77d10c2c..b190b30678a 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1439,8 +1439,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.3 h1:A2ZoIJklyY5avOsA8EBKXQ4wc7Ao2kOSm9MpmrK4Fho= -github.com/smartcontractkit/ocr2keepers v0.7.3/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= +github.com/smartcontractkit/ocr2keepers v0.7.5/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 107fe31494c..7ebb064ae8b 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -46,6 +46,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/median" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/mercury" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper" + ocr2keeper21core "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ocr2vrfconfig "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2vrf/config" ocr2coordinator "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2vrf/coordinator" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2vrf/juelsfeecoin" @@ -919,6 +920,7 @@ func (d *Delegate) newServicesOCR2Keepers21( ServiceQueueLength: cfg.ServiceQueueLength, BlockSubscriber: blockSub, RecoverableProvider: new(mockRecoverableProvider), + UpkeepTypeGetter: ocr2keeper21core.GetUpkeepType, } pluginService, err := plugin.NewDelegate(dConf) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go index dfac65daf97..c427bd4d5f9 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go @@ -143,75 +143,6 @@ func (rp *evmRegistryPackerV2_1) UnpackLogTriggerConfig(raw []byte) (automation_ return *converted, nil } -// PackTrigger packs the trigger into the format expected by the contract, -// according to the upkeep type of the given id. -func (rp *evmRegistryPackerV2_1) PackTrigger(id *big.Int, trig triggerWrapper) ([]byte, error) { - var trigger []byte - var err error - upkeepType := getUpkeepType(id.Bytes()) - switch upkeepType { - case conditionTrigger: - trig := automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger{ - BlockNum: trig.BlockNum, - BlockHash: trig.BlockHash, - } - trigger, err = rp.utilsAbi.Pack("_conditionalTrigger", &trig) - case logTrigger: - logTrig := automation_utils_2_1.KeeperRegistryBase21LogTrigger{ - BlockNum: trig.BlockNum, - BlockHash: trig.BlockHash, - LogIndex: trig.LogIndex, - TxHash: trig.TxHash, - } - trigger, err = rp.utilsAbi.Pack("_logTrigger", &logTrig) - default: - err = fmt.Errorf("unknown trigger type: %d", upkeepType) - } - if err != nil { - return nil, err - } - return trigger[4:], nil -} - -// UnpackTrigger unpacks the trigger from the given raw data, according to the upkeep type of the given id. -func (rp *evmRegistryPackerV2_1) UnpackTrigger(id *big.Int, raw []byte) (triggerWrapper, error) { - upkeepType := getUpkeepType(id.Bytes()) - switch upkeepType { - case conditionTrigger: - unpacked, err := rp.utilsAbi.Methods["_conditionalTrigger"].Inputs.Unpack(raw) - if err != nil { - return triggerWrapper{}, fmt.Errorf("%w: failed to unpack conditional trigger", err) - } - converted, ok := abi.ConvertType(unpacked[0], new(automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger)).(*automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger) - if !ok { - return triggerWrapper{}, fmt.Errorf("failed to convert type") - } - triggerW := triggerWrapper{ - BlockNum: converted.BlockNum, - } - copy(triggerW.BlockHash[:], converted.BlockHash[:]) - return triggerW, nil - case logTrigger: - unpacked, err := rp.utilsAbi.Methods["_logTrigger"].Inputs.Unpack(raw) - if err != nil { - return triggerWrapper{}, fmt.Errorf("%w: failed to unpack log trigger", err) - } - converted, ok := abi.ConvertType(unpacked[0], new(automation_utils_2_1.KeeperRegistryBase21LogTrigger)).(*automation_utils_2_1.KeeperRegistryBase21LogTrigger) - if !ok { - return triggerWrapper{}, fmt.Errorf("failed to convert type") - } - triggerW := triggerWrapper{ - BlockNum: converted.BlockNum, - LogIndex: converted.LogIndex, - } - copy(triggerW.BlockHash[:], converted.BlockHash[:]) - copy(triggerW.TxHash[:], converted.TxHash[:]) - return triggerW, nil - default: - return triggerWrapper{}, fmt.Errorf("unknown trigger type: %d", upkeepType) - } -} - // PackReport packs the report with abi definitions from the contract. func (rp *evmRegistryPackerV2_1) PackReport(report automation_utils_2_1.KeeperRegistryBase21Report) ([]byte, error) { bts, err := rp.utilsAbi.Pack("_report", &report) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go index aa9d8247f5d..7461b05b953 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go @@ -1,7 +1,6 @@ package evm import ( - "fmt" "math/big" "strings" "testing" @@ -14,10 +13,13 @@ import ( automation21Utils "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) func TestUnpackCheckResults(t *testing.T) { upkeepId, _ := new(big.Int).SetString("1843548457736589226156809205796175506139185429616502850435279853710366065936", 10) + payload1, _ := core.NewUpkeepPayload(upkeepId, 0, ocr2keepers.NewTrigger(19447615, "0x0", struct{}{}), []byte{}) + payload2, _ := core.NewUpkeepPayload(upkeepId, 0, ocr2keepers.NewTrigger(19448272, "0x0", struct{}{}), []byte{}) tests := []struct { Name string @@ -27,7 +29,7 @@ func TestUnpackCheckResults(t *testing.T) { }{ { Name: "upkeep not needed", - Payload: ocr2keepers.NewUpkeepPayload(upkeepId, 0, "19447615", ocr2keepers.NewTrigger(19447615, "0x0", struct{}{}), []byte{}), + Payload: payload1, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000421c000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000000", ExpectedResult: EVMAutomationUpkeepResult21{ Block: 19447615, @@ -45,7 +47,7 @@ func TestUnpackCheckResults(t *testing.T) { }, { Name: "target check reverted", - Payload: ocr2keepers.NewUpkeepPayload(upkeepId, 0, "19448272", ocr2keepers.NewTrigger(19448272, "0x0", struct{}{}), []byte{}), + Payload: payload2, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000007531000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000008914039bf676e20aad43a5642485e666575ed0d927a4b5679745e947e7d125ee2687c10000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000024462e8a50d00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000128c1d000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000009666565644944537472000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000184554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000000000184254432d5553442d415242495452554d2d544553544e45540000000000000000000000000000000000000000000000000000000000000000000000000000000b626c6f636b4e756d6265720000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000006400000000000000000000000000000000000000000000000000000000000000000000000000000000", ExpectedResult: EVMAutomationUpkeepResult21{ Block: 19448272, @@ -198,93 +200,6 @@ func TestPacker_UnpackLogTriggerConfig(t *testing.T) { } } -func TestPacker_PackingTrigger(t *testing.T) { - tests := []struct { - name string - id ocr2keepers.UpkeepIdentifier - trigger triggerWrapper - encoded []byte - err error - }{ - { - "happy flow log trigger", - append([]byte{1}, common.LeftPadBytes([]byte{1}, 15)...), - triggerWrapper{ - BlockNum: 1, - BlockHash: common.HexToHash("0x01111111"), - LogIndex: 1, - TxHash: common.HexToHash("0x01111111"), - }, - func() []byte { - b, _ := hexutil.Decode("0x0000000000000000000000000000000000000000000000000000000001111111000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") - return b - }(), - nil, - }, - { - "happy flow conditional trigger", - append([]byte{1}, common.LeftPadBytes([]byte{0}, 15)...), - triggerWrapper{ - BlockNum: 1, - BlockHash: common.HexToHash("0x01111111"), - }, - func() []byte { - b, _ := hexutil.Decode("0x00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") - return b - }(), - nil, - }, - { - "invalid type", - append([]byte{1}, common.LeftPadBytes([]byte{8}, 15)...), - triggerWrapper{ - BlockNum: 1, - BlockHash: common.HexToHash("0x01111111"), - }, - []byte{}, - fmt.Errorf("unknown trigger type: %d", 8), - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - packer, err := newPacker() - assert.NoError(t, err) - id, ok := big.NewInt(0).SetString(hexutil.Encode(tc.id)[2:], 16) - assert.True(t, ok) - - encoded, err := packer.PackTrigger(id, tc.trigger) - if tc.err != nil { - assert.EqualError(t, err, tc.err.Error()) - } else { - assert.NoError(t, err) - assert.Equal(t, tc.encoded, encoded) - decoded, err := packer.UnpackTrigger(id, encoded) - assert.NoError(t, err) - assert.Equal(t, tc.trigger.BlockNum, decoded.BlockNum) - } - }) - } - - t.Run("unpacking invalid trigger", func(t *testing.T) { - packer, err := newPacker() - assert.NoError(t, err) - _, err = packer.UnpackTrigger(big.NewInt(0), []byte{1, 2, 3}) - assert.Error(t, err) - }) - - t.Run("unpacking unknown type", func(t *testing.T) { - packer, err := newPacker() - assert.NoError(t, err) - uid := append([]byte{1}, common.LeftPadBytes([]byte{8}, 15)...) - id, ok := big.NewInt(0).SetString(hexutil.Encode(uid)[2:], 16) - assert.True(t, ok) - decoded, _ := hexutil.Decode("0x00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") - _, err = packer.UnpackTrigger(id, decoded) - assert.EqualError(t, err, "unknown trigger type: 8") - }) -} - func newPacker() (*evmRegistryPackerV2_1, error) { keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) if err != nil { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go new file mode 100644 index 00000000000..bc4e9ebe3c8 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go @@ -0,0 +1,84 @@ +package core + +import ( + "encoding/hex" + "encoding/json" + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" +) + +// UpkeepTriggerID returns the identifier using the given upkeepID and trigger. +// It follows the same logic as the contract, but performs it locally. +func UpkeepTriggerID(id *big.Int, trigger []byte) string { + idBytes := append(id.Bytes(), trigger...) + triggerIDBytes := crypto.Keccak256(idBytes) + return hex.EncodeToString(triggerIDBytes) +} + +// UpkeepWorkID returns the identifier using the given upkeepID and trigger extension(tx hash and log index). +func UpkeepWorkID(id *big.Int, trigger ocr2keepers.Trigger) (string, error) { + extensionBytes, err := json.Marshal(trigger.Extension) + if err != nil { + return "", err + } + + // TODO (auto-4314): Ensure it works with conditionals and add unit tests + combined := fmt.Sprintf("%s%s", id, extensionBytes) + hash := crypto.Keccak256([]byte(combined)) + return hex.EncodeToString(hash[:]), nil +} + +func NewUpkeepPayload(uid *big.Int, tp int, trigger ocr2keepers.Trigger, checkData []byte) (ocr2keepers.UpkeepPayload, error) { + // construct payload + p := ocr2keepers.UpkeepPayload{ + Upkeep: ocr2keepers.ConfiguredUpkeep{ + ID: ocr2keepers.UpkeepIdentifier(uid.Bytes()), + Type: tp, + Config: struct{}{}, // empty struct by default + }, + Trigger: trigger, + CheckData: checkData, + } + // set work id based on upkeep id and trigger + wid, err := UpkeepWorkID(uid, trigger) + if err != nil { + return ocr2keepers.UpkeepPayload{}, fmt.Errorf("error while generating workID: %w", err) + } + p.WorkID = wid + // manually convert trigger to triggerWrapper + triggerW := triggerWrapper{ + BlockNum: uint32(trigger.BlockNumber), + BlockHash: common.HexToHash(trigger.BlockHash), + } + + switch ocr2keepers.UpkeepType(tp) { + case ocr2keepers.LogTrigger: + trExt, ok := trigger.Extension.(LogTriggerExtension) + if !ok { + return ocr2keepers.UpkeepPayload{}, fmt.Errorf("unrecognized trigger extension data") + } + hex, parseErr := common.ParseHexOrString(trExt.TxHash) + if parseErr != nil { + return ocr2keepers.UpkeepPayload{}, fmt.Errorf("tx hash parse error: %w", err) + } + triggerW.TxHash = common.BytesToHash(hex[:]) + triggerW.LogIndex = uint32(trExt.LogIndex) + default: + } + + // get trigger in bytes + triggerBytes, err := PackTrigger(uid, triggerW) + if err != nil { + return ocr2keepers.UpkeepPayload{}, fmt.Errorf("%w: failed to pack trigger", err) + } + + // set trigger id based on upkeep id and trigger + p.ID = UpkeepTriggerID(uid, triggerBytes) + + // end + return p, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go new file mode 100644 index 00000000000..61805d3d61a --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go @@ -0,0 +1,74 @@ +package core + +import ( + "encoding/hex" + "math/big" + "testing" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + + "github.com/stretchr/testify/assert" +) + +func TestTriggerID(t *testing.T) { + upkeepIDStr := "82566255084862886500628610724995377215109748679571001950554849251333329872882" + // Convert the string to a big.Int + var upkeepID big.Int + _, success := upkeepID.SetString(upkeepIDStr, 10) + if !success { + t.Fatal("Invalid big integer value") + } + + triggerStr := "deadbeef" + triggerBytes, err := hex.DecodeString(triggerStr) + if err != nil { + t.Fatalf("Error decoding hex string: %s", err) + } + + res := UpkeepTriggerID(&upkeepID, triggerBytes) + + expectedResult := "fe466794c97e8b54ca25b696ff3ee448a7d03e4a82a2e45d9d84de62ef4cc260" + assert.Equal(t, res, expectedResult, "UpkeepTriggerID mismatch") +} + +func TestWorkID(t *testing.T) { + id := big.NewInt(12345) + trigger := ocr2keepers.Trigger{ + BlockNumber: 123, + BlockHash: "0xabcdef", + Extension: map[string]interface{}{ + "txHash": "0xdeadbeef", + "logIndex": "123", + }, + } + + res, err := UpkeepWorkID(id, trigger) + if err != nil { + t.Fatalf("Error computing UpkeepWorkID: %s", err) + } + + expectedResult := "182244f3e4fa6e9556a17b84718b7ffe19f0d67a811d771bd5479fe16e02bf82" + assert.Equal(t, res, expectedResult, "UpkeepWorkID mismatch") +} + +func TestNewUpkeepPayload(t *testing.T) { + logExt := LogTriggerExtension{ + LogIndex: 1, + TxHash: "0x1234567890123456789012345678901234567890123456789012345678901234", + } + + payload, err := NewUpkeepPayload( + big.NewInt(111), + 1, + ocr2keepers.Trigger{ + BlockNumber: 11, + BlockHash: "0x11111", + Extension: logExt, + }, + []byte("check-data-111"), + ) + if err != nil { + t.Fatal(err) + } + assert.Equal(t, "151b4fd0c9f8d97307938fb7d64d6efbc821891a0eb9ae2708ccfe98e1706b40", payload.ID) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go new file mode 100644 index 00000000000..c7a5295fd14 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go @@ -0,0 +1,104 @@ +package core + +import ( + "fmt" + "math/big" + "strings" + + "github.com/ethereum/go-ethereum/accounts/abi" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" +) + +type triggerWrapper = automation_utils_2_1.KeeperRegistryBase21LogTrigger + +var ErrABINotParsable = fmt.Errorf("error parsing abi") + +type LogTriggerExtension struct { + TxHash string + LogIndex int64 +} + +// according to the upkeep type of the given id. +func PackTrigger(id *big.Int, trig triggerWrapper) ([]byte, error) { + var trigger []byte + var err error + + // construct utils abi + utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + if err != nil { + return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + } + + // pack trigger based on upkeep type + upkeepType := GetUpkeepType(id.Bytes()) + switch upkeepType { + case ocr2keepers.ConditionTrigger: + trig := automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger{ + BlockNum: trig.BlockNum, + BlockHash: trig.BlockHash, + } + trigger, err = utilsABI.Pack("_conditionalTrigger", &trig) + case ocr2keepers.LogTrigger: + logTrig := automation_utils_2_1.KeeperRegistryBase21LogTrigger{ + BlockNum: trig.BlockNum, + BlockHash: trig.BlockHash, + LogIndex: trig.LogIndex, + TxHash: trig.TxHash, + } + trigger, err = utilsABI.Pack("_logTrigger", &logTrig) + default: + err = fmt.Errorf("unknown trigger type: %d", upkeepType) + } + if err != nil { + return nil, err + } + return trigger[4:], nil +} + +// UnpackTrigger unpacks the trigger from the given raw data, according to the upkeep type of the given id. +func UnpackTrigger(id *big.Int, raw []byte) (triggerWrapper, error) { + // construct utils abi + utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + if err != nil { + return triggerWrapper{}, fmt.Errorf("%w: %s", ErrABINotParsable, err) + } + + upkeepType := GetUpkeepType(id.Bytes()) + switch upkeepType { + case ocr2keepers.ConditionTrigger: + unpacked, err := utilsABI.Methods["_conditionalTrigger"].Inputs.Unpack(raw) + if err != nil { + return triggerWrapper{}, fmt.Errorf("%w: failed to unpack conditional trigger", err) + } + converted, ok := abi.ConvertType(unpacked[0], new(automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger)).(*automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger) + if !ok { + return triggerWrapper{}, fmt.Errorf("failed to convert type") + } + triggerW := triggerWrapper{ + BlockNum: converted.BlockNum, + } + copy(triggerW.BlockHash[:], converted.BlockHash[:]) + return triggerW, nil + case ocr2keepers.LogTrigger: + unpacked, err := utilsABI.Methods["_logTrigger"].Inputs.Unpack(raw) + if err != nil { + return triggerWrapper{}, fmt.Errorf("%w: failed to unpack log trigger", err) + } + converted, ok := abi.ConvertType(unpacked[0], new(automation_utils_2_1.KeeperRegistryBase21LogTrigger)).(*automation_utils_2_1.KeeperRegistryBase21LogTrigger) + if !ok { + return triggerWrapper{}, fmt.Errorf("failed to convert type") + } + triggerW := triggerWrapper{ + BlockNum: converted.BlockNum, + LogIndex: converted.LogIndex, + } + copy(triggerW.BlockHash[:], converted.BlockHash[:]) + copy(triggerW.TxHash[:], converted.TxHash[:]) + return triggerW, nil + default: + return triggerWrapper{}, fmt.Errorf("unknown trigger type: %d", upkeepType) + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go new file mode 100644 index 00000000000..4f682c4fb69 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go @@ -0,0 +1,93 @@ +package core + +import ( + "fmt" + "math/big" + "testing" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + "github.com/stretchr/testify/assert" +) + +func TestPackUnpackTrigger(t *testing.T) { + tests := []struct { + name string + id ocr2keepers.UpkeepIdentifier + trigger triggerWrapper + encoded []byte + err error + }{ + { + "happy flow log trigger", + append([]byte{1}, common.LeftPadBytes([]byte{1}, 15)...), + triggerWrapper{ + BlockNum: 1, + BlockHash: common.HexToHash("0x01111111"), + LogIndex: 1, + TxHash: common.HexToHash("0x01111111"), + }, + func() []byte { + b, _ := hexutil.Decode("0x0000000000000000000000000000000000000000000000000000000001111111000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") + return b + }(), + nil, + }, + { + "happy flow conditional trigger", + append([]byte{1}, common.LeftPadBytes([]byte{0}, 15)...), + triggerWrapper{ + BlockNum: 1, + BlockHash: common.HexToHash("0x01111111"), + }, + func() []byte { + b, _ := hexutil.Decode("0x00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") + return b + }(), + nil, + }, + { + "invalid type", + append([]byte{1}, common.LeftPadBytes([]byte{8}, 15)...), + triggerWrapper{ + BlockNum: 1, + BlockHash: common.HexToHash("0x01111111"), + }, + []byte{}, + fmt.Errorf("unknown trigger type: %d", 8), + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + id, ok := big.NewInt(0).SetString(hexutil.Encode(tc.id)[2:], 16) + assert.True(t, ok) + + encoded, err := PackTrigger(id, tc.trigger) + if tc.err != nil { + assert.EqualError(t, err, tc.err.Error()) + } else { + assert.NoError(t, err) + assert.Equal(t, tc.encoded, encoded) + decoded, err := UnpackTrigger(id, encoded) + assert.NoError(t, err) + assert.Equal(t, tc.trigger.BlockNum, decoded.BlockNum) + } + }) + } + + t.Run("unpacking invalid trigger", func(t *testing.T) { + _, err := UnpackTrigger(big.NewInt(0), []byte{1, 2, 3}) + assert.Error(t, err) + }) + + t.Run("unpacking unknown type", func(t *testing.T) { + uid := append([]byte{1}, common.LeftPadBytes([]byte{8}, 15)...) + id, ok := big.NewInt(0).SetString(hexutil.Encode(uid)[2:], 16) + assert.True(t, ok) + decoded, _ := hexutil.Decode("0x00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") + _, err := UnpackTrigger(id, decoded) + assert.EqualError(t, err, "unknown trigger type: 8") + }) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go similarity index 51% rename from core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go index 0d6a2c6f32b..c850f60d6e7 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go @@ -1,22 +1,11 @@ -package evm +package core import ( - "encoding/hex" "math/big" - "github.com/ethereum/go-ethereum/crypto" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" ) -type upkeepType uint8 - -const ( - conditionTrigger upkeepType = iota - logTrigger - cronTrigger - readyTrigger -) - const ( // upkeepTypeStartIndex is the index where the upkeep type bytes start. // for 2.1 we use 11 zeros (reserved bytes for future use) @@ -26,13 +15,15 @@ const ( upkeepTypeByteIndex = 15 ) -// getUpkeepType returns the upkeep type from the given ID. +// GetUpkeepType returns the upkeep type from the given ID. // it follows the same logic as the contract, but performs it locally. // // TODO: check endianness -func getUpkeepType(id ocr2keepers.UpkeepIdentifier) upkeepType { +func GetUpkeepType(id ocr2keepers.UpkeepIdentifier) ocr2keepers.UpkeepType { + // TODO: auto-4319: Ensure consistent definition of string vs bytes for UpkeepID + // and ensure bytes are zero padded for small integers if len(id) < upkeepTypeByteIndex+1 { - return conditionTrigger + return ocr2keepers.ConditionTrigger } idx, ok := big.NewInt(0).SetString(string(id), 10) if ok { @@ -40,22 +31,9 @@ func getUpkeepType(id ocr2keepers.UpkeepIdentifier) upkeepType { } for i := upkeepTypeStartIndex; i < upkeepTypeByteIndex; i++ { if id[i] != 0 { // old id - return conditionTrigger + return ocr2keepers.ConditionTrigger } } typeByte := id[upkeepTypeByteIndex] - return upkeepType(typeByte) -} - -// UpkeepTriggerID returns the identifier using the given upkeepID and trigger. -// It follows the same logic as the contract, but performs it locally. -func UpkeepTriggerID(id *big.Int, trigger []byte) string { - idBytes := id.Bytes() - - combined := append(idBytes, trigger...) - - triggerIDBytes := crypto.Keccak256(combined) - triggerID := hex.EncodeToString(triggerIDBytes) - - return triggerID + return ocr2keepers.UpkeepType(typeByte) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go new file mode 100644 index 00000000000..0c4219e6505 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go @@ -0,0 +1,65 @@ +package core + +import ( + "math/big" + "testing" + + "github.com/ethereum/go-ethereum/common" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + + "github.com/stretchr/testify/assert" +) + +func TestGetUpkeepType(t *testing.T) { + tests := []struct { + name string + upkeepID ocr2keepers.UpkeepIdentifier + upkeepType ocr2keepers.UpkeepType + }{ + { + "zeroed id", + big.NewInt(0).Bytes(), + ocr2keepers.ConditionTrigger, + }, + { + "old id", + []byte("5820911532554020907796191562093071158274499580927271776163559390280294438608"), + ocr2keepers.ConditionTrigger, + }, + { + "condition trigger", + genUpkeepID(ocr2keepers.ConditionTrigger, "").Bytes(), + ocr2keepers.ConditionTrigger, + }, + { + "log trigger string", + []byte(genUpkeepID(ocr2keepers.LogTrigger, "111").String()), + ocr2keepers.LogTrigger, + }, + { + "log trigger", + genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes(), + ocr2keepers.LogTrigger, + }, + { + "log trigger id", + func() ocr2keepers.UpkeepIdentifier { + id, _ := big.NewInt(0).SetString("32329108151019397958065800113404894502874153543356521479058624064899121404671", 10) + return id.Bytes() + }(), + ocr2keepers.LogTrigger, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + assert.Equal(t, tc.upkeepType, GetUpkeepType(tc.upkeepID)) + }) + } +} + +func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) *big.Int { + b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) + b = append(b, []byte(rand)...) + return big.NewInt(0).SetBytes(b) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index 46ed1c56218..a6be18e8699 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -10,7 +10,7 @@ import ( "github.com/smartcontractkit/ocr2keepers/pkg/encoding" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" - "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) var ( @@ -94,10 +94,9 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] BlockNum: uint32(result.Payload.Trigger.BlockNumber), BlockHash: common.HexToHash(result.Payload.Trigger.BlockHash), } - - switch getUpkeepType(id.Bytes()) { - case logTrigger: - trExt, ok := result.Payload.Trigger.Extension.(logprovider.LogTriggerExtension) + switch core.GetUpkeepType(id.Bytes()) { + case ocr2keepers.LogTrigger: + trExt, ok := result.Payload.Trigger.Extension.(core.LogTriggerExtension) if !ok { // decodeExtensions should catch this, but in the case it doesn't ... return nil, fmt.Errorf("unrecognized trigger extension data") @@ -114,7 +113,7 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] // no special handling here for conditional triggers } - trigger, err := enc.packer.PackTrigger(id, triggerW) + trigger, err := core.PackTrigger(id, triggerW) if err != nil { return nil, fmt.Errorf("%w: failed to pack trigger", err) } @@ -138,15 +137,15 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk } reportedUpkeeps := make([]ocr2keepers.ReportedUpkeep, len(report.UpkeepIds)) for i, upkeepId := range report.UpkeepIds { - triggerW, err := enc.packer.UnpackTrigger(upkeepId, report.Triggers[i]) + triggerW, err := core.UnpackTrigger(upkeepId, report.Triggers[i]) if err != nil { // TODO: log error and continue instead? return nil, fmt.Errorf("%w: failed to unpack trigger", err) } - logExt := logprovider.LogTriggerExtension{} + logExt := core.LogTriggerExtension{} - switch getUpkeepType(upkeepId.Bytes()) { - case logTrigger: + switch core.GetUpkeepType(upkeepId.Bytes()) { + case ocr2keepers.LogTrigger: logExt.TxHash = common.BytesToHash(triggerW.TxHash[:]).Hex() logExt.LogIndex = int64(triggerW.LogIndex) default: @@ -156,9 +155,11 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk common.BytesToHash(triggerW.BlockHash[:]).Hex(), logExt, ) - triggerID := UpkeepTriggerID(upkeepId, report.Triggers[i]) + id := core.UpkeepTriggerID(upkeepId, report.Triggers[i]) + workID, _ := core.UpkeepWorkID(upkeepId, trigger) reportedUpkeeps[i] = ocr2keepers.ReportedUpkeep{ - ID: triggerID, + ID: id, + WorkID: workID, UpkeepID: ocr2keepers.UpkeepIdentifier(upkeepId.String()), Trigger: trigger, PerformData: report.PerformDatas[i], @@ -191,13 +192,13 @@ func decodeExtensions(result *ocr2keepers.CheckResult) error { // decode the trigger extension data if not decoded switch typedExt := rC.Payload.Trigger.Extension.(type) { - case logprovider.LogTriggerExtension: + case core.LogTriggerExtension: // no decoding required break case []byte: - switch getUpkeepType(result.Payload.Upkeep.ID) { - case logTrigger: - var ext logprovider.LogTriggerExtension + switch core.GetUpkeepType(result.Payload.Upkeep.ID) { + case ocr2keepers.LogTrigger: + var ext core.LogTriggerExtension // in the case of a string, the value is probably still json // encoded and coming from a plugin outcome @@ -206,7 +207,7 @@ func decodeExtensions(result *ocr2keepers.CheckResult) error { } result.Payload.Trigger.Extension = ext - case conditionTrigger: + case ocr2keepers.ConditionTrigger: // no special handling for conditional triggers break default: diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go index d2bce136372..77c11ff7fce 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go @@ -15,7 +15,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" - "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) func TestEVMAutomationEncoder21_Encode(t *testing.T) { @@ -38,7 +38,7 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { { "happy flow single", []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String()), 1, 1), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "10").String()), 1, 1), }, 640, 1, @@ -48,9 +48,9 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { { "happy flow multiple", []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String()), 1, 1), - newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 2, 2), - newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 3, 3), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "10").String()), 1, 1), + newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 2, 2), + newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "30").String()), 3, 3), }, 1280, 3, @@ -60,9 +60,9 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { { "happy flow highest block number first", []ocr2keepers.CheckResult{ - newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1000, 2000), - newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 2, 2), - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "10").String()), 1, 1), + newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "30").String()), 1000, 2000), + newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 2, 2), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "10").String()), 1, 1), }, 1280, 1000, @@ -121,7 +121,7 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { } t.Run("a non-EVMAutomationResultExtension21 extension causes an error", func(t *testing.T) { - result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1, 1) + result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "30").String()), 1, 1) result.Extension = "invalid" b, err := encoder.Encode(result) assert.Nil(t, b) @@ -141,7 +141,7 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { })*/ t.Run("a non-LogTriggerExtension extension causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 1, 1) result.Payload.Trigger.Extension = "invalid" b, err := encoder.Encode(result) assert.Nil(t, b) @@ -150,8 +150,8 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { }) t.Run("a non hex tx (empty) hash causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) - result.Payload.Trigger.Extension = logprovider.LogTriggerExtension{ + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 1, 1) + result.Payload.Trigger.Extension = core.LogTriggerExtension{ TxHash: "", } b, err := encoder.Encode(result) @@ -160,17 +160,6 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { assert.Equal(t, err.Error(), "tx hash parse error: empty hex string") }) - t.Run("an invalid upkeep type causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(5, "20").String()), 1, 1) - result.Payload.Trigger.Extension = logprovider.LogTriggerExtension{ - TxHash: "", - } - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unknown trigger type: 5: failed to pack trigger") - }) - t.Run("an invalid result extension causes an error", func(t *testing.T) { result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(5, "20").String()), 1, 1) result.Extension = struct{}{} @@ -181,7 +170,7 @@ func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { }) t.Run("invalid trigger extension causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "20").String()), 1, 1) + result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 1, 1) result.Payload.Trigger.Extension = struct{}{} b, err := encoder.Encode(result) assert.Nil(t, b) @@ -207,16 +196,16 @@ func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { { "happy flow single", []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "10").String()), 1, 1), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "10").String()), 1, 1), }, nil, }, { "happy flow multiple", []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "10").String()), 1, 1), - newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "20").String()), 1, 1), - newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "30").String()), 1, 1), + newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "10").String()), 1, 1), + newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "20").String()), 1, 1), + newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "30").String()), 1, 1), }, nil, }, @@ -279,25 +268,24 @@ func TestUpkeepKeyHelper_MakeBlockKey(t *testing.T) { } func newResult(block int64, checkBlock ocr2keepers.BlockKey, id ocr2keepers.UpkeepIdentifier, fastGasWei, linkNative int64) ocr2keepers.CheckResult { - logExt := logprovider.LogTriggerExtension{} - tp := getUpkeepType(id) - if tp == logTrigger { + logExt := core.LogTriggerExtension{} + tp := core.GetUpkeepType(id) + if tp == ocr2keepers.LogTrigger { logExt.LogIndex = 1 logExt.TxHash = "0x1234567890123456789012345678901234567890123456789012345678901234" } - payload := ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: id, - Type: int(tp), - }, - Trigger: ocr2keepers.Trigger{ + + payload, _ := core.NewUpkeepPayload( + new(big.Int).SetBytes(id), + int(tp), + ocr2keepers.Trigger{ BlockNumber: block, BlockHash: hexutil.Encode([]byte{1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8}), Extension: logExt, }, - CheckBlock: checkBlock, - } - payload.ID = payload.GenerateID() + []byte{}, + ) + return ocr2keepers.CheckResult{ Payload: payload, Eligible: true, @@ -319,7 +307,7 @@ func decode(packer *evmRegistryPackerV2_1, raw []byte) ([]ocr2keepers.UpkeepResu res := make([]ocr2keepers.UpkeepResult, len(report.UpkeepIds)) for i := 0; i < len(report.UpkeepIds); i++ { - trigger, err := packer.UnpackTrigger(report.UpkeepIds[i], report.Triggers[i]) + trigger, err := core.UnpackTrigger(report.UpkeepIds[i], report.Triggers[i]) if err != nil { return nil, fmt.Errorf("%w: failed to unpack trigger", err) } @@ -339,6 +327,12 @@ func decode(packer *evmRegistryPackerV2_1, raw []byte) ([]ocr2keepers.UpkeepResu return res, nil } +func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) *big.Int { + b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) + b = append(b, []byte(rand)...) + return big.NewInt(0).SetBytes(b) +} + func Test_decodeExtensions(t *testing.T) { t.Run("a nil result returns an error", func(t *testing.T) { err := decodeExtensions(nil) @@ -350,7 +344,7 @@ func Test_decodeExtensions(t *testing.T) { err := decodeExtensions(&ocr2keepers.CheckResult{ Payload: ocr2keepers.UpkeepPayload{ Trigger: ocr2keepers.Trigger{ - Extension: logprovider.LogTriggerExtension{}, + Extension: core.LogTriggerExtension{}, }, }, Extension: EVMAutomationResultExtension21{}, @@ -386,7 +380,7 @@ func Test_decodeExtensions(t *testing.T) { err := decodeExtensions(&ocr2keepers.CheckResult{ Payload: ocr2keepers.UpkeepPayload{ Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "111").Bytes()), + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes()), }, Trigger: ocr2keepers.Trigger{ Extension: []byte(`{"TxHash": "abc", "LogIndex": 123}`), @@ -401,7 +395,7 @@ func Test_decodeExtensions(t *testing.T) { err := decodeExtensions(&ocr2keepers.CheckResult{ Payload: ocr2keepers.UpkeepPayload{ Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(logTrigger, "111").Bytes()), + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes()), }, Trigger: ocr2keepers.Trigger{ Extension: []byte(`invalid`), @@ -417,7 +411,7 @@ func Test_decodeExtensions(t *testing.T) { err := decodeExtensions(&ocr2keepers.CheckResult{ Payload: ocr2keepers.UpkeepPayload{ Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "111").Bytes()), + ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "111").Bytes()), }, Trigger: ocr2keepers.Trigger{ Extension: []byte(""), @@ -473,7 +467,7 @@ func Test_decodeExtensions(t *testing.T) { err := decodeExtensions(&ocr2keepers.CheckResult{ Payload: ocr2keepers.UpkeepPayload{ Trigger: ocr2keepers.Trigger{ - Extension: logprovider.LogTriggerExtension{}, + Extension: core.LogTriggerExtension{}, }, }, Extension: "invalid", diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index da671e57836..fea36036066 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -103,8 +103,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Type: 0, Config: nil, }, - CheckBlock: "26046145", - CheckData: nil, + CheckData: nil, Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, @@ -128,8 +127,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Type: 0, Config: nil, }, - CheckBlock: "26046145", - CheckData: nil, + CheckData: nil, Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, @@ -151,8 +149,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Type: 0, Config: nil, }, - CheckBlock: "26046145", - CheckData: nil, + CheckData: nil, Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, @@ -170,8 +167,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Type: 0, Config: nil, }, - CheckBlock: "26046145", - CheckData: nil, + CheckData: nil, Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, @@ -192,8 +188,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Type: 0, Config: nil, }, - CheckBlock: "26046145", - CheckData: nil, + CheckData: nil, Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, @@ -211,8 +206,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Type: 0, Config: nil, }, - CheckBlock: "26046145", - CheckData: nil, + CheckData: nil, Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go index c5660e1be1e..86caebd9bc7 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go @@ -9,11 +9,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" ) -type LogTriggerExtension struct { - TxHash string - LogIndex int64 -} - type LogDataPacker interface { PackLogData(log logpoller.Log) ([]byte, error) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 9f101e4baeb..c6112a74223 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -20,6 +20,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) @@ -146,7 +147,7 @@ func (p *logEventProvider) GetLogs(context.Context) ([]ocr2keepers.UpkeepPayload trig := ocr2keepers.NewTrigger( log.BlockNumber, log.BlockHash.Hex(), - LogTriggerExtension{ + core.LogTriggerExtension{ TxHash: log.TxHash.Hex(), LogIndex: log.LogIndex, }, @@ -156,7 +157,13 @@ func (p *logEventProvider) GetLogs(context.Context) ([]ocr2keepers.UpkeepPayload p.lggr.Warnw("failed to pack log data", "err", err, "log", log) continue } - payload := ocr2keepers.NewUpkeepPayload(l.id, logTriggerType, ocr2keepers.BlockKey(fmt.Sprintf("%d", log.BlockNumber)), trig, checkData) + + payload, err := core.NewUpkeepPayload(l.id, logTriggerType, trig, checkData) + if err != nil { + // skip invalid payloads + continue + } + payloads = append(payloads, payload) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 2514fc0ffb6..a99283cf3d8 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -31,6 +31,7 @@ import ( iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/models" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -214,9 +215,9 @@ func (r *EvmRegistry) GetActiveUpkeepIDsByType(ctx context.Context, triggers ... keys = append(keys, ocr2keepers.UpkeepIdentifier(value.ID.String())) continue } - trigger := getUpkeepType(value.ID.Bytes()) + trigger := core.GetUpkeepType(value.ID.Bytes()) for _, t := range triggers { - if trigger == upkeepType(t) { + if trigger == ocr2keepers.UpkeepType(t) { keys = append(keys, ocr2keepers.UpkeepIdentifier(value.ID.String())) break } @@ -407,8 +408,8 @@ func (r *EvmRegistry) initialize() error { // register upkeep ids for log triggers for _, id := range ids { - switch getUpkeepType(id.Bytes()) { - case logTrigger: + switch core.GetUpkeepType(id.Bytes()) { + case ocr2keepers.LogTrigger: if err := r.updateTriggerConfig(id, nil); err != nil { r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", id.String(), err) } @@ -501,7 +502,7 @@ func (r *EvmRegistry) processUpkeepStateLog(l logpoller.Log) error { r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", l.Id.String(), err) } case *iregistry21.IKeeperRegistryMasterUpkeepRegistered: - trigger := getUpkeepType(l.Id.Bytes()) + trigger := core.GetUpkeepType(l.Id.Bytes()) r.lggr.Debugf("KeeperRegistryUpkeepRegistered log detected for upkeep ID %s (trigger=%d) in transaction %s", l.Id.String(), trigger, hash) r.addToActive(l.Id, false) if err := r.updateTriggerConfig(l.Id, nil); err != nil { @@ -531,9 +532,9 @@ func (r *EvmRegistry) removeFromActive(id *big.Int) { delete(r.active, id.String()) r.mu.Unlock() - trigger := getUpkeepType(id.Bytes()) + trigger := core.GetUpkeepType(id.Bytes()) switch trigger { - case logTrigger: + case ocr2keepers.LogTrigger: if err := r.logEventProvider.UnregisterFilter(id); err != nil { r.lggr.Warnw("failed to unregister log filter", "upkeepID", id.String()) } @@ -678,8 +679,8 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, keys []ocr2keepers.Upkee return nil, err } var payload []byte - switch getUpkeepType(upkeepId.Bytes()) { - case logTrigger: + switch core.GetUpkeepType(upkeepId.Bytes()) { + case ocr2keepers.LogTrigger: // check data will include the log trigger config payload, err = r.abi.Pack("checkUpkeep", upkeepId, key.CheckData) if err != nil { @@ -871,8 +872,8 @@ func (r *EvmRegistry) getUpkeepConfigs(ctx context.Context, ids []*big.Int) ([]a func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { uid := id.String() - switch getUpkeepType(id.Bytes()) { - case logTrigger: + switch core.GetUpkeepType(id.Bytes()) { + case ocr2keepers.LogTrigger: if len(cfg) == 0 { fetched, err := r.fetchTriggerConfig(id) if err != nil { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go index ccd52e46ce3..75132f832f1 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go @@ -83,7 +83,7 @@ func TestGetActiveUpkeepIDsByType(t *testing.T) { ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ ocr2keepers.UpkeepIdentifier("32329108151019397958065800113404894502874153543356521479058624064899121404671"), }, - Triggers: []uint8{uint8(logTrigger)}, + Triggers: []uint8{uint8(ocr2keepers.LogTrigger)}, }, { Name: "get conditional upkeeps", @@ -92,7 +92,7 @@ func TestGetActiveUpkeepIDsByType(t *testing.T) { ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ ocr2keepers.UpkeepIdentifier("8"), }, - Triggers: []uint8{uint8(conditionTrigger)}, + Triggers: []uint8{uint8(ocr2keepers.ConditionTrigger)}, }, { Name: "get multiple types of upkeeps", @@ -102,7 +102,7 @@ func TestGetActiveUpkeepIDsByType(t *testing.T) { ocr2keepers.UpkeepIdentifier("8"), ocr2keepers.UpkeepIdentifier("32329108151019397958065800113404894502874153543356521479058624064899121404671"), }, - Triggers: []uint8{uint8(logTrigger), uint8(conditionTrigger)}, + Triggers: []uint8{uint8(ocr2keepers.LogTrigger), uint8(ocr2keepers.ConditionTrigger)}, }, } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go index 3571d208868..e9bfbfabb23 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go @@ -13,6 +13,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -250,13 +251,13 @@ func (l transmitEventLog) Id() *big.Int { func (l transmitEventLog) TriggerID() string { switch { case l.Performed != nil: - return UpkeepTriggerID(l.Performed.Id, l.Performed.Trigger) + return core.UpkeepTriggerID(l.Performed.Id, l.Performed.Trigger) case l.Stale != nil: - return UpkeepTriggerID(l.Stale.Id, l.Stale.Trigger) + return core.UpkeepTriggerID(l.Stale.Id, l.Stale.Trigger) case l.Reorged != nil: - return UpkeepTriggerID(l.Reorged.Id, l.Reorged.Trigger) + return core.UpkeepTriggerID(l.Reorged.Id, l.Reorged.Trigger) case l.InsufficientFunds != nil: - return UpkeepTriggerID(l.InsufficientFunds.Id, l.InsufficientFunds.Trigger) + return core.UpkeepTriggerID(l.InsufficientFunds.Id, l.InsufficientFunds.Trigger) default: return "" } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go index 4f44e47526d..f59bb2e7175 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go @@ -99,7 +99,7 @@ func TestTransmitEventProvider(t *testing.T) { func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { provider := &TransmitEventProvider{} - id := genUpkeepID(logTrigger, "111") + id := genUpkeepID(ocr2keepers.LogTrigger, "111") tests := []struct { name string performed []transmitEventLog @@ -154,7 +154,7 @@ func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { } func TestTransmitEventLog(t *testing.T) { - uid := genUpkeepID(conditionTrigger, "111") + uid := genUpkeepID(ocr2keepers.ConditionTrigger, "111") tests := []struct { name string diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go deleted file mode 100644 index 766c4eb87bc..00000000000 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_info_test.go +++ /dev/null @@ -1,97 +0,0 @@ -package evm - -import ( - "encoding/hex" - "math/big" - "testing" - - "github.com/ethereum/go-ethereum/common" - "github.com/stretchr/testify/assert" - - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" -) - -func TestTriggerID(t *testing.T) { - upkeepIDStr := "82566255084862886500628610724995377215109748679571001950554849251333329872882" - // Convert the string to a big.Int - var upkeepID big.Int - _, success := upkeepID.SetString(upkeepIDStr, 10) - if !success { - t.Fatal("Invalid big integer value") - } - - triggerStr := "deadbeef" - triggerBytes, err := hex.DecodeString(triggerStr) - if err != nil { - t.Fatalf("Error decoding hex string: %s", err) - } - - res := UpkeepTriggerID(&upkeepID, triggerBytes) - - expectedResult := "fe466794c97e8b54ca25b696ff3ee448a7d03e4a82a2e45d9d84de62ef4cc260" - assert.Equal(t, res, expectedResult, "UpkeepTriggerID mismatch") -} - -func TestGetUpkeepType(t *testing.T) { - tests := []struct { - name string - upkeepID ocr2keepers.UpkeepIdentifier - upkeepType upkeepType - }{ - { - "zeroed id", - big.NewInt(0).Bytes(), - conditionTrigger, - }, - { - "old id", - []byte("5820911532554020907796191562093071158274499580927271776163559390280294438608"), - conditionTrigger, - }, - { - "condition trigger", - genUpkeepID(conditionTrigger, "").Bytes(), - conditionTrigger, - }, - { - "log trigger string", - []byte(genUpkeepID(logTrigger, "111").String()), - logTrigger, - }, - { - "log trigger", - genUpkeepID(logTrigger, "111").Bytes(), - logTrigger, - }, - { - "cron trigger", - genUpkeepID(cronTrigger, "222").Bytes(), - cronTrigger, - }, - { - "ready trigger", - genUpkeepID(readyTrigger, "333").Bytes(), - readyTrigger, - }, - { - "log trigger id", - func() ocr2keepers.UpkeepIdentifier { - id, _ := big.NewInt(0).SetString("32329108151019397958065800113404894502874153543356521479058624064899121404671", 10) - return id.Bytes() - }(), - logTrigger, - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - assert.Equal(t, tc.upkeepType, getUpkeepType(tc.upkeepID)) - }) - } -} - -func genUpkeepID(uType upkeepType, rand string) *big.Int { - b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) - b = append(b, []byte(rand)...) - return big.NewInt(0).SetBytes(b) -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go index fb1917b0989..1fc44fd97ae 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go @@ -6,6 +6,8 @@ import ( ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" + + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) var _ keepersflows.UpkeepProvider = &upkeepProvider{} @@ -21,7 +23,7 @@ func NewUpkeepProvider(reg *EvmRegistry) *upkeepProvider { } func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context, blockKey ocr2keepers.BlockKey) ([]ocr2keepers.UpkeepPayload, error) { - ids, err := p.reg.GetActiveUpkeepIDsByType(ctx, uint8(conditionTrigger)) + ids, err := p.reg.GetActiveUpkeepIDsByType(ctx, uint8(ocr2keepers.ConditionTrigger)) if err != nil { return nil, err } @@ -36,13 +38,18 @@ func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context, blockKey ocr2keep var payloads []ocr2keepers.UpkeepPayload for _, uid := range ids { - payloads = append(payloads, ocr2keepers.NewUpkeepPayload( + payload, err := core.NewUpkeepPayload( big.NewInt(0).SetBytes(uid), - int(conditionTrigger), - blockKey, + int(ocr2keepers.ConditionTrigger), ocr2keepers.NewTrigger(block.Int64(), blockHash.Hex(), struct{}{}), nil, - )) + ) + if err != nil { + // skip invalid payloads + continue + } + + payloads = append(payloads, payload) } return payloads, nil diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go index 009cb26c5fd..1ca18e28e72 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go @@ -1,10 +1,7 @@ package evm import ( - "fmt" "math/big" - "strconv" - "strings" "sync" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" @@ -63,6 +60,7 @@ func (u *UpkeepStateStore) SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, if s.block < start || s.block >= end || !uids.Contains(s.upkeepId) { continue } + pl = append(pl, s.payload) us = append(us, s.state) } @@ -74,18 +72,10 @@ func (u *UpkeepStateStore) SetUpkeepState(pl ocr2keepers.UpkeepPayload, us ocr2k defer u.mu.Unlock() upkeepId := big.NewInt(0).SetBytes(pl.Upkeep.ID) - arrs := strings.Split(string(pl.CheckBlock), BlockKeySeparator) - if len(arrs) != 2 { - return fmt.Errorf("check block %s is invalid for upkeep %s", pl.CheckBlock, upkeepId) - } - block, err := strconv.ParseInt(arrs[0], 10, 64) - if err != nil { - return err - } state := &upkeepState{ payload: &pl, state: &us, - block: block, + block: pl.Trigger.BlockNumber, upkeepId: upkeepId.String(), } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go index 1c04dc35db5..022cd03bb8e 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go @@ -1,7 +1,6 @@ package evm import ( - "fmt" "math/big" "testing" @@ -9,23 +8,32 @@ import ( "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) var ( upkeepId1 = big.NewInt(100) upkeepId2 = big.NewInt(200) trigger1 = ocr2keepers.Trigger{ - BlockNumber: 95, + BlockNumber: block1, BlockHash: "0x1231eqwe12eqwd", + Extension: core.LogTriggerExtension{ + LogIndex: 1, + TxHash: "0x1234567890123456789012345678901234567890123456789012345678901234", + }, } trigger2 = ocr2keepers.Trigger{ - BlockNumber: 125, + BlockNumber: block3, BlockHash: "0x1231eqwe12eqwd", + Extension: core.LogTriggerExtension{ + LogIndex: 1, + TxHash: "0x1234567890123456789012345678901234567890123456789012345678901234", + }, } - payload2 = ocr2keepers.NewUpkeepPayload(upkeepId1, conditionalType, blockKey2, trigger1, []byte{}) - payload3 = ocr2keepers.NewUpkeepPayload(upkeepId2, logTriggerType, blockKey2, trigger1, []byte{}) - payload4 = ocr2keepers.NewUpkeepPayload(upkeepId1, logTriggerType, blockKey1, trigger2, []byte{}) - payload5 = ocr2keepers.NewUpkeepPayload(upkeepId1, logTriggerType, blockKey3, trigger1, []byte{}) + payload2, _ = core.NewUpkeepPayload(upkeepId1, conditionalType, trigger1, []byte{}) + payload3, _ = core.NewUpkeepPayload(upkeepId2, logTriggerType, trigger1, []byte{}) + payload4, _ = core.NewUpkeepPayload(upkeepId1, logTriggerType, trigger2, []byte{}) + payload5, _ = core.NewUpkeepPayload(upkeepId1, logTriggerType, trigger1, []byte{}) ) const ( @@ -33,40 +41,8 @@ const ( logTriggerType = 1 block1 = 111 block3 = 113 - blockKey1 = "111|0x123123132132" - blockKey2 = "112|0x565456465465" - blockKey3 = "113|0x111423246546" - invalidBlockKey = "2220x565456465465" ) -func TestUpkeepStateStore_InvalidBlockKey(t *testing.T) { - tests := []struct { - name string - payloads []ocr2keepers.UpkeepPayload - states []ocr2keepers.UpkeepState - expectedError error - }{ - { - name: "failed to split invalid block key", - payloads: []ocr2keepers.UpkeepPayload{ - ocr2keepers.NewUpkeepPayload(upkeepId2, logTriggerType, invalidBlockKey, trigger1, []byte{}), - }, - states: []ocr2keepers.UpkeepState{ocr2keepers.Performed}, - expectedError: fmt.Errorf("check block %s is invalid for upkeep %s", invalidBlockKey, upkeepId2), - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - store := NewUpkeepStateStore(logger.TestLogger(t)) - for i, p := range tc.payloads { - err := store.SetUpkeepState(p, tc.states[i]) - require.Equal(t, err, tc.expectedError) - } - }) - } -} - func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { p := ocr2keepers.Performed e := ocr2keepers.Eligible diff --git a/go.mod b/go.mod index 72d333f3d4a..41134ed574a 100644 --- a/go.mod +++ b/go.mod @@ -71,7 +71,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.3 + github.com/smartcontractkit/ocr2keepers v0.7.5 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c diff --git a/go.sum b/go.sum index c98f8ec7402..a193d5a6bd7 100644 --- a/go.sum +++ b/go.sum @@ -1444,8 +1444,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.3 h1:A2ZoIJklyY5avOsA8EBKXQ4wc7Ao2kOSm9MpmrK4Fho= -github.com/smartcontractkit/ocr2keepers v0.7.3/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= +github.com/smartcontractkit/ocr2keepers v0.7.5/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 104d76bca97..7cd38836ebb 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -22,7 +22,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.3 + github.com/smartcontractkit/ocr2keepers v0.7.5 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/spf13/cobra v1.6.1 github.com/stretchr/testify v1.8.4 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index e47a9e160db..47500474e61 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2250,8 +2250,8 @@ github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87 github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.3 h1:A2ZoIJklyY5avOsA8EBKXQ4wc7Ao2kOSm9MpmrK4Fho= -github.com/smartcontractkit/ocr2keepers v0.7.3/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= +github.com/smartcontractkit/ocr2keepers v0.7.5/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From 96c5f4bd022be72d1fde7171b872d57068d7f935 Mon Sep 17 00:00:00 2001 From: Dimitris Grigoriou Date: Tue, 8 Aug 2023 15:48:43 +0300 Subject: [PATCH 108/270] Use headbyhash to backfill heads on the Head Tracker (#10078) * Use headbyhash to backfill heads on the Head Tracker * Fix test cases --- common/headtracker/head_tracker.go | 9 +- common/headtracker/types/client.go | 1 + .../evm/headtracker/head_broadcaster_test.go | 3 +- .../evm/headtracker/head_tracker_test.go | 99 +++++++++++-------- core/internal/cltest/cltest.go | 20 +++- core/internal/features/features_test.go | 13 ++- 6 files changed, 90 insertions(+), 55 deletions(-) diff --git a/common/headtracker/head_tracker.go b/common/headtracker/head_tracker.go index 4de7d93134e..91813d89a2d 100644 --- a/common/headtracker/head_tracker.go +++ b/common/headtracker/head_tracker.go @@ -3,7 +3,6 @@ package headtracker import ( "context" "fmt" - "math/big" "sync" "time" @@ -334,7 +333,7 @@ func (ht *HeadTracker[HTH, S, ID, BLOCK_HASH]) backfill(ctx context.Context, hea head = existingHead continue } - head, err = ht.fetchAndSaveHead(ctx, i) + head, err = ht.fetchAndSaveHead(ctx, i, head.GetParentHash()) fetched++ if ctx.Err() != nil { ht.log.Debugw("context canceled, aborting backfill", "err", err, "ctx.Err", ctx.Err()) @@ -346,9 +345,9 @@ func (ht *HeadTracker[HTH, S, ID, BLOCK_HASH]) backfill(ctx context.Context, hea return } -func (ht *HeadTracker[HTH, S, ID, BLOCK_HASH]) fetchAndSaveHead(ctx context.Context, n int64) (HTH, error) { - ht.log.Debugw("Fetching head", "blockHeight", n) - head, err := ht.client.HeadByNumber(ctx, big.NewInt(n)) +func (ht *HeadTracker[HTH, S, ID, BLOCK_HASH]) fetchAndSaveHead(ctx context.Context, n int64, hash BLOCK_HASH) (HTH, error) { + ht.log.Debugw("Fetching head", "blockHeight", n, "blockHash", hash) + head, err := ht.client.HeadByHash(ctx, hash) if err != nil { return ht.getNilHead(), err } else if !head.IsValid() { diff --git a/common/headtracker/types/client.go b/common/headtracker/types/client.go index 53962954377..906f95bbe54 100644 --- a/common/headtracker/types/client.go +++ b/common/headtracker/types/client.go @@ -9,6 +9,7 @@ import ( type Client[H types.Head[BLOCK_HASH], S types.Subscription, ID types.ID, BLOCK_HASH types.Hashable] interface { HeadByNumber(ctx context.Context, number *big.Int) (head H, err error) + HeadByHash(ctx context.Context, hash BLOCK_HASH) (head H, err error) // ConfiguredChainID returns the chain ID that the node is configured to connect to ConfiguredChainID() (id ID) // SubscribeNewHead is the method in which the client receives new Head. diff --git a/core/chains/evm/headtracker/head_broadcaster_test.go b/core/chains/evm/headtracker/head_broadcaster_test.go index aba9335b14b..c478920e00e 100644 --- a/core/chains/evm/headtracker/head_broadcaster_test.go +++ b/core/chains/evm/headtracker/head_broadcaster_test.go @@ -59,7 +59,8 @@ func TestHeadBroadcaster_Subscribe(t *testing.T) { chchHeaders <- args.Get(1).(chan<- *evmtypes.Head) }). Return(sub, nil) - ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(cltest.Head(1), nil) + ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(cltest.Head(1), nil).Once() + ethClient.On("HeadByHash", mock.Anything, mock.Anything).Return(cltest.Head(1), nil) sub.On("Unsubscribe").Return() sub.On("Err").Return(nil) diff --git a/core/chains/evm/headtracker/head_tracker_test.go b/core/chains/evm/headtracker/head_tracker_test.go index 7ae328ffbde..6a9a0dfc8aa 100644 --- a/core/chains/evm/headtracker/head_tracker_test.go +++ b/core/chains/evm/headtracker/head_tracker_test.go @@ -247,6 +247,7 @@ func TestHeadTracker_CallsHeadTrackableCallbacks(t *testing.T) { func(ctx context.Context, ch chan<- *evmtypes.Head) error { return nil }, ) ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(cltest.Head(0), nil) + ethClient.On("HeadByHash", mock.Anything, mock.Anything).Return(cltest.Head(0), nil).Maybe() checker := &cltest.MockHeadTrackable{} ht := createHeadTrackerWithChecker(t, ethClient, config.EVM(), config.EVM().HeadTracker(), orm, checker) @@ -320,7 +321,8 @@ func TestHeadTracker_ResubscribeOnSubscriptionError(t *testing.T) { }, func(ctx context.Context, ch chan<- *evmtypes.Head) error { return nil }, ) - ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(cltest.Head(0), nil) + ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(cltest.Head(0), nil).Once() + ethClient.On("HeadByHash", mock.Anything, mock.Anything).Return(cltest.Head(0), nil).Once() checker := &cltest.MockHeadTrackable{} ht := createHeadTrackerWithChecker(t, ethClient, config.EVM(), config.EVM().HeadTracker(), orm, checker) @@ -367,9 +369,9 @@ func TestHeadTracker_Start_LoadsLatestChain(t *testing.T) { parentHash = heads[i].Hash } ethClient.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(heads[3], nil).Maybe() - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(2)).Return(heads[2], nil).Maybe() - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(1)).Return(heads[1], nil).Maybe() - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(0)).Return(heads[0], nil).Maybe() + ethClient.On("HeadByHash", mock.Anything, heads[2].Hash).Return(heads[2], nil).Maybe() + ethClient.On("HeadByHash", mock.Anything, heads[1].Hash).Return(heads[1], nil).Maybe() + ethClient.On("HeadByHash", mock.Anything, heads[0].Hash).Return(heads[0], nil).Maybe() chchHeaders := make(chan evmtest.RawSub[*evmtypes.Head], 1) mockEth := &evmtest.MockEth{EthClient: ethClient} @@ -505,26 +507,22 @@ func TestHeadTracker_SwitchesToLongestChainWithHeadSamplingEnabled(t *testing.T) // This grotesque construction is the only way to do dynamic return values using // the mock package. We need dynamic returns because we're simulating reorgs. - latestHeadByNumber := make(map[int64]*evmtypes.Head) - latestHeadByNumberMu := new(sync.Mutex) + latestHeadByHash := make(map[gethCommon.Hash]*evmtypes.Head) + latestHeadByHashMu := new(sync.Mutex) - fnCall := ethClient.On("HeadByNumber", mock.Anything, mock.Anything) + fnCall := ethClient.On("HeadByHash", mock.Anything, mock.Anything) fnCall.RunFn = func(args mock.Arguments) { - latestHeadByNumberMu.Lock() - defer latestHeadByNumberMu.Unlock() - num := args.Get(1).(*big.Int) - head, exists := latestHeadByNumber[num.Int64()] - if !exists { - head = cltest.Head(num.Int64()) - latestHeadByNumber[num.Int64()] = head - } + latestHeadByHashMu.Lock() + defer latestHeadByHashMu.Unlock() + hash := args.Get(1).(gethCommon.Hash) + head := latestHeadByHash[hash] fnCall.ReturnArguments = mock.Arguments{head, nil} } for _, h := range headSeq.Heads { - latestHeadByNumberMu.Lock() - latestHeadByNumber[h.Number] = h - latestHeadByNumberMu.Unlock() + latestHeadByHashMu.Lock() + latestHeadByHash[h.Hash] = h + latestHeadByHashMu.Unlock() headers.TrySend(h) } @@ -665,26 +663,22 @@ func TestHeadTracker_SwitchesToLongestChainWithHeadSamplingDisabled(t *testing.T // This grotesque construction is the only way to do dynamic return values using // the mock package. We need dynamic returns because we're simulating reorgs. - latestHeadByNumber := make(map[int64]*evmtypes.Head) - latestHeadByNumberMu := new(sync.Mutex) + latestHeadByHash := make(map[gethCommon.Hash]*evmtypes.Head) + latestHeadByHashMu := new(sync.Mutex) - fnCall := ethClient.On("HeadByNumber", mock.Anything, mock.Anything) + fnCall := ethClient.On("HeadByHash", mock.Anything, mock.Anything) fnCall.RunFn = func(args mock.Arguments) { - latestHeadByNumberMu.Lock() - defer latestHeadByNumberMu.Unlock() - num := args.Get(1).(*big.Int) - head, exists := latestHeadByNumber[num.Int64()] - if !exists { - head = cltest.Head(num.Int64()) - latestHeadByNumber[num.Int64()] = head - } + latestHeadByHashMu.Lock() + defer latestHeadByHashMu.Unlock() + hash := args.Get(1).(gethCommon.Hash) + head := latestHeadByHash[hash] fnCall.ReturnArguments = mock.Arguments{head, nil} } for _, h := range headSeq.Heads { - latestHeadByNumberMu.Lock() - latestHeadByNumber[h.Number] = h - latestHeadByNumberMu.Unlock() + latestHeadByHashMu.Lock() + latestHeadByHash[h.Hash] = h + latestHeadByHashMu.Unlock() headers.TrySend(h) time.Sleep(testutils.TestInterval) } @@ -803,7 +797,7 @@ func TestHeadTracker_Backfill(t *testing.T) { ethClient := evmtest.NewEthClientMock(t) ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(10)). + ethClient.On("HeadByHash", mock.Anything, head10.Hash). Return(&head10, nil) ht := createHeadTrackerWithNeverSleeper(t, ethClient, cfg, orm) @@ -842,9 +836,9 @@ func TestHeadTracker_Backfill(t *testing.T) { ht := createHeadTrackerWithNeverSleeper(t, ethClient, cfg, orm) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(10)). + ethClient.On("HeadByHash", mock.Anything, head10.Hash). Return(&head10, nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(8)). + ethClient.On("HeadByHash", mock.Anything, head8.Hash). Return(&head8, nil) // Needs to be 8 because there are 8 heads in chain (15,14,13,12,11,10,9,8) @@ -890,7 +884,7 @@ func TestHeadTracker_Backfill(t *testing.T) { ethClient := evmtest.NewEthClientMock(t) ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(0)). + ethClient.On("HeadByHash", mock.Anything, head0.Hash). Return(&head0, nil) require.NoError(t, orm.IdempotentInsertHead(testutils.Context(t), &h1)) @@ -918,10 +912,10 @@ func TestHeadTracker_Backfill(t *testing.T) { ethClient := evmtest.NewEthClientMock(t) ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(10)). + ethClient.On("HeadByHash", mock.Anything, head10.Hash). Return(&head10, nil). Once() - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(8)). + ethClient.On("HeadByHash", mock.Anything, head8.Hash). Return(nil, ethereum.NotFound). Once() @@ -949,9 +943,9 @@ func TestHeadTracker_Backfill(t *testing.T) { ethClient := evmtest.NewEthClientMock(t) ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(10)). + ethClient.On("HeadByHash", mock.Anything, head10.Hash). Return(&head10, nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(8)). + ethClient.On("HeadByHash", mock.Anything, head8.Hash). Return(nil, context.DeadlineExceeded) ht := createHeadTrackerWithNeverSleeper(t, ethClient, cfg, orm) @@ -966,6 +960,31 @@ func TestHeadTracker_Backfill(t *testing.T) { assert.Equal(t, 4, int(h.ChainLength())) assert.Equal(t, int64(9), h.EarliestInChain().BlockNumber()) }) + + t.Run("abandons backfill and returns error when fetching a block by hash fails, indicating a reorg", func(t *testing.T) { + db := pgtest.NewSqlxDB(t) + cfg := configtest.NewGeneralConfig(t, nil) + logger := logger.TestLogger(t) + orm := headtracker.NewORM(db, logger, cfg.Database(), cltest.FixtureChainID) + ethClient := evmtest.NewEthClientMock(t) + ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) + ethClient.On("HeadByHash", mock.Anything, h14.Hash).Return(&h14, nil).Once() + ethClient.On("HeadByHash", mock.Anything, h13.Hash).Return(&h13, nil).Once() + ethClient.On("HeadByHash", mock.Anything, h12.Hash).Return(nil, errors.New("not found")).Once() + + ht := createHeadTrackerWithNeverSleeper(t, ethClient, cfg, orm) + + err := ht.Backfill(ctx, &h15, 400) + + require.Error(t, err) + require.EqualError(t, err, "fetchAndSaveHead failed: not found") + + h := ht.headSaver.Chain(h14.Hash) + + // Should contain 14, 13 (15 was never added). When trying to get the parent of h13 by hash, a reorg happened and backfill exited. + assert.Equal(t, 2, int(h.ChainLength())) + assert.Equal(t, int64(13), h.EarliestInChain().BlockNumber()) + }) } func createHeadTracker(t *testing.T, ethClient evmclient.Client, config headtracker.Config, htConfig headtracker.HeadTrackerConfig, orm headtracker.ORM) *headTrackerUniverse { diff --git a/core/internal/cltest/cltest.go b/core/internal/cltest/cltest.go index f67b80c224f..4531ddf1586 100644 --- a/core/internal/cltest/cltest.go +++ b/core/internal/cltest/cltest.go @@ -555,9 +555,13 @@ func NewEthMocksWithTransactionsOnBlocksAssertions(t testing.TB) *evmclimocks.Cl c.On("SubscribeNewHead", mock.Anything, mock.Anything).Maybe().Return(EmptyMockSubscription(t), nil) c.On("SendTransaction", mock.Anything, mock.Anything).Maybe().Return(nil) c.On("SendTransactionReturnCode", mock.Anything, mock.Anything, mock.Anything).Maybe().Return(clienttypes.Successful, nil) - c.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Maybe().Return(Head(2), nil) - c.On("HeadByNumber", mock.Anything, big.NewInt(1)).Maybe().Return(Head(1), nil) - c.On("HeadByNumber", mock.Anything, big.NewInt(0)).Maybe().Return(Head(0), nil) + // Construct chain + h2 := Head(2) + h1 := HeadWithHash(1, h2.ParentHash) + h0 := HeadWithHash(0, h1.ParentHash) + c.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Maybe().Return(h2, nil) + c.On("HeadByHash", mock.Anything, h1.Hash).Maybe().Return(h1, nil) + c.On("HeadByHash", mock.Anything, h0.Hash).Maybe().Return(h0, nil) c.On("BatchCallContext", mock.Anything, mock.Anything).Maybe().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &evmtypes.Block{ @@ -577,7 +581,7 @@ func NewEthMocksWithTransactionsOnBlocksAssertions(t testing.TB) *evmclimocks.Cl block := &types.Header{ Number: big.NewInt(100), } - c.On("HeaderByNumber", mock.Anything, mock.Anything).Maybe().Return(block, nil) + c.On("HeaderByHash", mock.Anything, mock.Anything).Maybe().Return(block, nil) return c } @@ -1039,6 +1043,14 @@ func Head(val interface{}) *evmtypes.Head { return &h } +func HeadWithHash(n int64, hash common.Hash) *evmtypes.Head { + var h evmtypes.Head + time := uint64(0) + h = evmtypes.NewHead(big.NewInt(n), hash, utils.NewHash(), time, utils.NewBig(&FixtureChainID)) + return &h + +} + // LegacyTransactionsFromGasPrices returns transactions matching the given gas prices func LegacyTransactionsFromGasPrices(gasPrices ...int64) []evmtypes.Transaction { return LegacyTransactionsFromGasPricesTxType(0x0, gasPrices...) diff --git a/core/internal/features/features_test.go b/core/internal/features/features_test.go index 58cb744ace0..b434fec0905 100644 --- a/core/internal/features/features_test.go +++ b/core/internal/features/features_test.go @@ -1374,6 +1374,11 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) ethClient.On("BalanceAt", mock.Anything, mock.Anything, mock.Anything).Maybe().Return(oneETH.ToInt(), nil) + // HeadTracker backfill + ethClient.On("HeadByHash", mock.Anything, h40.Hash).Return(&h40, nil).Maybe() + ethClient.On("HeadByHash", mock.Anything, h41.Hash).Return(&h41, nil).Maybe() + ethClient.On("HeadByHash", mock.Anything, h42.Hash).Return(&h42, nil).Maybe() + require.NoError(t, cc.Start(testutils.Context(t))) var newHeads evmtest.RawSub[*evmtypes.Head] select { @@ -1398,12 +1403,10 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { elems[0].Result = &b43 }) - // HeadTracker backfill - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(42)).Return(&h42, nil) - ethClient.On("HeadByNumber", mock.Anything, big.NewInt(41)).Return(&h41, nil) - // Simulate one new head and check the gas price got updated - newHeads.TrySend(cltest.Head(43)) + h43 := cltest.Head(43) + h43.ParentHash = h42.Hash + newHeads.TrySend(h43) gomega.NewWithT(t).Eventually(func() string { gasPrice, _, err := estimator.GetFee(testutils.Context(t), nil, 500000, maxGasPrice) From a8c377a2fa0f98eebeeec60fdb940521c1ec4b66 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Tue, 8 Aug 2023 16:36:05 +0300 Subject: [PATCH 109/270] TT-467 migrate VRFv2 smoke test (#10067) * Marshal struct to build node config Use functional options as decorators to create node config with P2Pv1 or P2Pv2. * Add ocr2 * Use config structures from core * Fix gomod * Fix setting p2p * fix tests * TT-467 migrate VRFv2, align VRFv1 * TT-467 update to new config * update receivers * remove NodeConfigOpts * TT-467 refactor vrf1/vrf2 smoke tests * TT-467 clean up error messages * TT-467 plaintext secret fields for testing * Revert "TT-467 plaintext secret fields for testing" This reverts commit fcf3dd16522bb73efcc0d5e1bcf3b6bbfc9752cf. * Revert "Revert "TT-467 plaintext secret fields for testing"" This reverts commit 26db785e156f32d5aedd48181523d267527595db. * TT-467 use flag to skip redacting * update secrets * use old secrets text template * remove k8s tests code --------- Co-authored-by: lukaszcl <120112546+lukaszcl@users.noreply.github.com> --- integration-tests/actions/actions.go | 16 ++ integration-tests/actions/vrfv1/actions.go | 38 +++ .../{vrfv2_constants.go => constants.go} | 0 .../actions/vrfv2_actions/vrfv2_steps.go | 271 +++++------------- integration-tests/client/chainlink_models.go | 6 +- integration-tests/docker/cmd/test_env.go | 2 +- integration-tests/docker/test_env/cl_node.go | 68 +++-- integration-tests/docker/test_env/geth.go | 15 +- .../docker/test_env/mockserver.go | 36 +-- integration-tests/docker/test_env/postgres.go | 3 +- integration-tests/docker/test_env/test_env.go | 79 +++-- .../docker/test_env/test_env_builder.go | 106 ++++--- integration-tests/smoke/flux_test.go | 11 +- integration-tests/smoke/runlog_test.go | 4 +- integration-tests/smoke/vrf_test.go | 33 +-- integration-tests/smoke/vrfv2_test.go | 129 ++++----- integration-tests/soak/vrfv2_test.go | 151 ---------- integration-tests/types/config/node/core.go | 18 +- integration-tests/utils/log.go | 4 +- integration-tests/utils/templates/geth.go | 53 ++-- .../utils/templates/node_secrets.go | 47 --- integration-tests/utils/templates/secrets.go | 29 ++ integration-tests/utils/templates/template.go | 25 ++ 23 files changed, 481 insertions(+), 663 deletions(-) create mode 100644 integration-tests/actions/vrfv1/actions.go rename integration-tests/actions/vrfv2_actions/vrfv2_constants/{vrfv2_constants.go => constants.go} (100%) delete mode 100644 integration-tests/soak/vrfv2_test.go delete mode 100644 integration-tests/utils/templates/node_secrets.go create mode 100644 integration-tests/utils/templates/secrets.go create mode 100644 integration-tests/utils/templates/template.go diff --git a/integration-tests/actions/actions.go b/integration-tests/actions/actions.go index aa454aca257..0565de64c97 100644 --- a/integration-tests/actions/actions.go +++ b/integration-tests/actions/actions.go @@ -410,3 +410,19 @@ func UpgradeChainlinkNodeVersions( } return client.ReconnectChainlinkNodes(testEnvironment, nodes) } + +func DeployLINKToken(cd contracts.ContractDeployer) (contracts.LinkToken, error) { + linkToken, err := cd.DeployLinkTokenContract() + if err != nil { + return nil, err + } + return linkToken, err +} + +func DeployMockETHLinkFeed(cd contracts.ContractDeployer, answer *big.Int) (contracts.MockETHLINKFeed, error) { + mockETHLINKFeed, err := cd.DeployMockETHLINKFeed(answer) + if err != nil { + return nil, err + } + return mockETHLINKFeed, err +} diff --git a/integration-tests/actions/vrfv1/actions.go b/integration-tests/actions/vrfv1/actions.go new file mode 100644 index 00000000000..68d3e584cee --- /dev/null +++ b/integration-tests/actions/vrfv1/actions.go @@ -0,0 +1,38 @@ +package vrfv1 + +import ( + "github.com/pkg/errors" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" +) + +var ( + ErrDeployBHSV1 = "error deploying BlockHashStoreV1 contract" + ErrDeployVRFCootrinatorV1 = "error deploying VRFv1 Coordinator contract" + ErrDeployVRFConsumerV1 = "error deploying VRFv1 Consumer contract" +) + +type Contracts struct { + BHS contracts.BlockHashStore + Coordinator contracts.VRFCoordinator + Consumer contracts.VRFConsumer +} + +func DeployVRFContracts(cd contracts.ContractDeployer, bc blockchain.EVMClient, lt contracts.LinkToken) (*Contracts, error) { + bhs, err := cd.DeployBlockhashStore() + if err != nil { + return nil, errors.Wrap(err, ErrDeployBHSV1) + } + coordinator, err := cd.DeployVRFCoordinator(lt.Address(), bhs.Address()) + if err != nil { + return nil, errors.Wrap(err, ErrDeployVRFCootrinatorV1) + } + consumer, err := cd.DeployVRFConsumer(lt.Address(), coordinator.Address()) + if err != nil { + return nil, errors.Wrap(err, ErrDeployVRFConsumerV1) + } + if err := bc.WaitForEvents(); err != nil { + return nil, err + } + return &Contracts{bhs, coordinator, consumer}, nil +} diff --git a/integration-tests/actions/vrfv2_actions/vrfv2_constants/vrfv2_constants.go b/integration-tests/actions/vrfv2_actions/vrfv2_constants/constants.go similarity index 100% rename from integration-tests/actions/vrfv2_actions/vrfv2_constants/vrfv2_constants.go rename to integration-tests/actions/vrfv2_actions/vrfv2_constants/constants.go diff --git a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go index 153a8fae6fa..0b3eaabf2cb 100644 --- a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go +++ b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go @@ -3,71 +3,83 @@ package vrfv2_actions import ( "context" "fmt" - "math/big" - "strings" - "testing" - "time" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - eth "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" - "github.com/smartcontractkit/chainlink/integration-tests/config" chainlinkutils "github.com/smartcontractkit/chainlink/v2/core/utils" + "math/big" "github.com/google/uuid" - "github.com/stretchr/testify/require" - + "github.com/pkg/errors" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" ) +var ( + ErrNodePrimaryKey = "error getting node's primary ETH key" + ErrCreatingProvingKeyHash = "error creating a keyHash from the proving key" + ErrCreatingProvingKey = "error creating a keyHash from the proving key" + ErrRegisterProvingKey = "error registering proving keys" + ErrEncodingProvingKey = "error encoding proving key" + ErrCreatingVRFv2Key = "error creating VRFv2 key" + ErrDeployBlockHashStore = "error deploying blockhash store" + ErrDeployCoordinator = "error deploying VRFv2 CoordinatorV2" + ErrAdvancedConsumer = "error deploying VRFv2 Advanced Consumer" + ErrABIEncodingFunding = "error Abi encoding subscriptionID" + ErrSendingLinkToken = "error sending Link token" + ErrCreatingVRFv2Job = "error creating VRFv2 job" + ErrParseJob = "error parsing job definition" +) + func DeployVRFV2Contracts( - t *testing.T, contractDeployer contracts.ContractDeployer, chainClient blockchain.EVMClient, linkTokenContract contracts.LinkToken, linkEthFeedContract contracts.MockETHLINKFeed, -) VRFV2Contracts { +) (*VRFV2Contracts, error) { bhs, err := contractDeployer.DeployBlockhashStore() - require.NoError(t, err, "Error deploying blockhash store") + if err != nil { + return nil, errors.Wrap(err, ErrDeployBlockHashStore) + } coordinator, err := contractDeployer.DeployVRFCoordinatorV2(linkTokenContract.Address(), bhs.Address(), linkEthFeedContract.Address()) - require.NoError(t, err, "Error deploying VRFv2 Coordinator") + if err != nil { + return nil, errors.Wrap(err, ErrDeployCoordinator) + } loadTestConsumer, err := contractDeployer.DeployVRFv2LoadTestConsumer(coordinator.Address()) - require.NoError(t, err, "Error deploying VRFv2 Advanced Consumer") + if err != nil { + return nil, errors.Wrap(err, ErrAdvancedConsumer) + } err = chainClient.WaitForEvents() - require.NoError(t, err, "Error waiting for events") - - return VRFV2Contracts{coordinator, bhs, loadTestConsumer} + if err != nil { + return nil, err + } + return &VRFV2Contracts{coordinator, bhs, loadTestConsumer}, nil } func CreateVRFV2Jobs( - t *testing.T, - chainlinkNodes []*client.ChainlinkK8sClient, + chainlinkNodes []*client.ChainlinkClient, coordinator contracts.VRFCoordinatorV2, c blockchain.EVMClient, minIncomingConfirmations uint16, -) []VRFV2JobInfo { - l := utils.GetTestLogger(t) +) ([]VRFV2JobInfo, error) { jobInfo := make([]VRFV2JobInfo, 0) for _, chainlinkNode := range chainlinkNodes { vrfKey, err := chainlinkNode.MustCreateVRFKey() - require.NoError(t, err, "Error creating VRF key") - l.Debug().Interface("Key JSON", vrfKey).Msg("Created proving key") + if err != nil { + return nil, errors.Wrap(err, ErrCreatingVRFv2Key) + } pubKeyCompressed := vrfKey.Data.ID jobUUID := uuid.New() os := &client.VRFV2TxPipelineSpec{ Address: coordinator.Address(), } ost, err := os.String() - require.NoError(t, err, "Error getting job string") + if err != nil { + return nil, errors.Wrap(err, ErrParseJob) + } nativeTokenPrimaryKeyAddress, err := chainlinkNode.PrimaryEthAddress() - require.NoError(t, err, "Error getting node's primary ETH key") + if err != nil { + return nil, errors.Wrap(err, ErrNodePrimaryKey) + } job, err := chainlinkNode.MustCreateJob(&client.VRFV2JobSpec{ Name: fmt.Sprintf("vrf-%s", jobUUID), CoordinatorAddress: coordinator.Address(), @@ -79,10 +91,17 @@ func CreateVRFV2Jobs( ObservationSource: ost, BatchFulfillmentEnabled: false, }) - require.NoError(t, err, "Error creating VRFv2 job") - provingKey := VRFV2RegisterProvingKey(t, vrfKey, nativeTokenPrimaryKeyAddress, coordinator) + if err != nil { + return nil, errors.Wrap(err, ErrCreatingVRFv2Job) + } + provingKey, err := VRFV2RegisterProvingKey(vrfKey, nativeTokenPrimaryKeyAddress, coordinator) + if err != nil { + return nil, errors.Wrap(err, ErrCreatingProvingKey) + } keyHash, err := coordinator.HashOfKey(context.Background(), provingKey) - require.NoError(t, err, "Error creating a keyHash from the proving key") + if err != nil { + return nil, errors.Wrap(err, ErrCreatingProvingKeyHash) + } ji := VRFV2JobInfo{ Job: job, VRFKey: vrfKey, @@ -91,188 +110,36 @@ func CreateVRFV2Jobs( } jobInfo = append(jobInfo, ji) } - return jobInfo + return jobInfo, nil } func VRFV2RegisterProvingKey( - t *testing.T, vrfKey *client.VRFKey, oracleAddress string, coordinator contracts.VRFCoordinatorV2, -) VRFV2EncodedProvingKey { +) (VRFV2EncodedProvingKey, error) { provingKey, err := actions.EncodeOnChainVRFProvingKey(*vrfKey) - require.NoError(t, err, "Error encoding proving key") + if err != nil { + return VRFV2EncodedProvingKey{}, errors.Wrap(err, ErrEncodingProvingKey) + } err = coordinator.RegisterProvingKey( oracleAddress, provingKey, ) - require.NoError(t, err, "Error registering proving keys") - return provingKey + if err != nil { + return VRFV2EncodedProvingKey{}, errors.Wrap(err, ErrRegisterProvingKey) + } + return provingKey, nil } -func FundVRFCoordinatorV2Subscription(t *testing.T, linkToken contracts.LinkToken, coordinator contracts.VRFCoordinatorV2, chainClient blockchain.EVMClient, subscriptionID uint64, linkFundingAmount *big.Int) { +func FundVRFCoordinatorV2Subscription(linkToken contracts.LinkToken, coordinator contracts.VRFCoordinatorV2, chainClient blockchain.EVMClient, subscriptionID uint64, linkFundingAmount *big.Int) error { encodedSubId, err := chainlinkutils.ABIEncode(`[{"type":"uint64"}]`, subscriptionID) - require.NoError(t, err, "Error Abi encoding subscriptionID") - _, err = linkToken.TransferAndCall(coordinator.Address(), big.NewInt(0).Mul(linkFundingAmount, big.NewInt(1e18)), encodedSubId) - require.NoError(t, err, "Error sending Link token") - err = chainClient.WaitForEvents() - require.NoError(t, err, "Error waiting for TXs to complete") -} - -func SetupVRFV2Universe( - t *testing.T, - linkToken contracts.LinkToken, - mockETHLinkFeed contracts.MockETHLINKFeed, - contractDeployer contracts.ContractDeployer, - chainClient blockchain.EVMClient, - chainlinkNodes []*client.ChainlinkK8sClient, - testNetwork blockchain.EVMNetwork, - existingTestEnvironment *environment.Environment, - chainlinkNodeFundingAmountEth *big.Float, - vrfSubscriptionFundingAmountInLink *big.Int, - newEnvNamespacePrefix string, - newEnvTTL time.Duration, -) (VRFV2Contracts, []*client.ChainlinkK8sClient, []VRFV2JobInfo, *environment.Environment) { - - vrfV2Contracts := DeployVRFV2Contracts( - t, - contractDeployer, - chainClient, - linkToken, - mockETHLinkFeed, - ) - - err := actions.FundChainlinkNodes(chainlinkNodes, chainClient, chainlinkNodeFundingAmountEth) - require.NoError(t, err) - err = chainClient.WaitForEvents() - require.NoError(t, err) - - err = vrfV2Contracts.Coordinator.SetConfig( - uint16(vrfv2_constants.MinimumConfirmations), - vrfv2_constants.MaxGasLimitVRFCoordinatorConfig, - vrfv2_constants.StalenessSeconds, - vrfv2_constants.GasAfterPaymentCalculation, - vrfv2_constants.LinkEthFeedResponse, - vrfv2_constants.VRFCoordinatorV2FeeConfig, - ) - require.NoError(t, err) - err = chainClient.WaitForEvents() - require.NoError(t, err) - - err = vrfV2Contracts.Coordinator.CreateSubscription() - require.NoError(t, err) - err = chainClient.WaitForEvents() - require.NoError(t, err) - - err = vrfV2Contracts.Coordinator.AddConsumer(vrfv2_constants.SubID, vrfV2Contracts.LoadTestConsumer.Address()) - require.NoError(t, err, "Error adding a Load Test Consumer to a subscription in VRFCoordinator contract") - - FundVRFCoordinatorV2Subscription( - t, - linkToken, - vrfV2Contracts.Coordinator, - chainClient, - vrfv2_constants.SubID, - vrfSubscriptionFundingAmountInLink, - ) - - vrfV2jobs := CreateVRFV2Jobs( - t, - chainlinkNodes, - vrfV2Contracts.Coordinator, - chainClient, - vrfv2_constants.MinimumConfirmations, - ) - - nativeTokenPrimaryKeyAddress, err := chainlinkNodes[0].PrimaryEthAddress() - require.NoError(t, err, "Error getting node's primary ETH key") - - evmKeySpecificConfigTemplate := ` -[[EVM.KeySpecific]] -Key = '%s' - -[EVM.KeySpecific.GasEstimator] -PriceMax = '%d gwei' -` - //todo - make evmKeySpecificConfigTemplate for multiple eth keys - evmKeySpecificConfig := fmt.Sprintf(evmKeySpecificConfigTemplate, nativeTokenPrimaryKeyAddress, vrfv2_constants.MaxGasPriceGWei) - tomlConfigWithUpdates := fmt.Sprintf("%s\n%s", config.BaseVRFV2NetworkDetailTomlConfig, evmKeySpecificConfig) - - //todo - this does not show up?? - newEnvLabel := "updatedWithRollout=true" - testEnvironmentAfterRedeployment := SetupVRFV2Environment( - t, - testNetwork, - tomlConfigWithUpdates, - existingTestEnvironment.Cfg.Namespace, - newEnvNamespacePrefix, - newEnvLabel, - newEnvTTL, - ) - - err = testEnvironmentAfterRedeployment.RolloutStatefulSets() - require.NoError(t, err, "Error performing rollout restart for test environment") - - err = testEnvironmentAfterRedeployment.Run() - require.NoError(t, err, "Error running test environment") - - //need to get node's urls again since port changed after redeployment - chainlinkNodesAfterRedeployment, err := client.ConnectChainlinkNodes(testEnvironmentAfterRedeployment) - require.NoError(t, err) - - return vrfV2Contracts, chainlinkNodesAfterRedeployment, vrfV2jobs, testEnvironmentAfterRedeployment -} - -func SetupVRFV2Environment( - t *testing.T, - testNetwork blockchain.EVMNetwork, - networkDetailTomlConfig string, - existingNamespace string, - namespacePrefix string, - newEnvLabel string, - ttl time.Duration, -) (testEnvironment *environment.Environment) { - gethChartConfig := getGethChartConfig(testNetwork) - - if existingNamespace != "" { - testEnvironment = environment.New(&environment.Config{ - Namespace: existingNamespace, - Test: t, - TTL: ttl, - Labels: []string{newEnvLabel}, - }) - } else { - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("%s-%s", namespacePrefix, strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - TTL: ttl, - }) + if err != nil { + return errors.Wrap(err, ErrABIEncodingFunding) } - - cd, err := chainlink.NewDeployment(1, map[string]any{ - "toml": client.AddNetworkDetailedConfig("", networkDetailTomlConfig, testNetwork), - //need to restart the node with updated eth key config - "db": map[string]interface{}{ - "stateful": "true", - }, - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment = testEnvironment. - AddHelm(gethChartConfig). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error running test environment") - return testEnvironment -} - -func getGethChartConfig(testNetwork blockchain.EVMNetwork) environment.ConnectedChart { - evmConfig := eth.New(nil) - if !testNetwork.Simulated { - evmConfig = eth.New(ð.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) + _, err = linkToken.TransferAndCall(coordinator.Address(), big.NewInt(0).Mul(linkFundingAmount, big.NewInt(1e18)), encodedSubId) + if err != nil { + return errors.Wrap(err, ErrSendingLinkToken) } - return evmConfig + return chainClient.WaitForEvents() } diff --git a/integration-tests/client/chainlink_models.go b/integration-tests/client/chainlink_models.go index bb6698ba95c..122f2d1e720 100644 --- a/integration-tests/client/chainlink_models.go +++ b/integration-tests/client/chainlink_models.go @@ -1068,7 +1068,7 @@ observationSource = """ // VRFV2JobSpec represents a VRFV2 job type VRFV2JobSpec struct { Name string `toml:"name"` - CoordinatorAddress string `toml:"coordinatorAddress"` // Address of the VRF Coordinator contract + CoordinatorAddress string `toml:"coordinatorAddress"` // Address of the VRF CoordinatorV2 contract PublicKey string `toml:"publicKey"` // Public key of the proving key ExternalJobID string `toml:"externalJobID"` ObservationSource string `toml:"observationSource"` // List of commands for the Chainlink node @@ -1108,7 +1108,7 @@ observationSource = """ // VRFJobSpec represents a VRF job type VRFJobSpec struct { Name string `toml:"name"` - CoordinatorAddress string `toml:"coordinatorAddress"` // Address of the VRF Coordinator contract + CoordinatorAddress string `toml:"coordinatorAddress"` // Address of the VRF CoordinatorV2 contract PublicKey string `toml:"publicKey"` // Public key of the proving key ExternalJobID string `toml:"externalJobID"` ObservationSource string `toml:"observationSource"` // List of commands for the Chainlink node @@ -1138,7 +1138,7 @@ observationSource = """ // BlockhashStoreJobSpec represents a blockhashstore job type BlockhashStoreJobSpec struct { Name string `toml:"name"` - CoordinatorV2Address string `toml:"coordinatorV2Address"` // Address of the VRF Coordinator contract + CoordinatorV2Address string `toml:"coordinatorV2Address"` // Address of the VRF CoordinatorV2 contract WaitBlocks int `toml:"waitBlocks"` LookbackBlocks int `toml:"lookbackBlocks"` BlockhashStoreAddress string `toml:"blockhashStoreAddress"` diff --git a/integration-tests/docker/cmd/test_env.go b/integration-tests/docker/cmd/test_env.go index 059df5a3b62..1acf5947505 100644 --- a/integration-tests/docker/cmd/test_env.go +++ b/integration-tests/docker/cmd/test_env.go @@ -31,7 +31,7 @@ func main() { Use: "cl-cluster", Short: "Basic CL cluster", RunE: func(cmd *cobra.Command, args []string) error { - utils.SetupGlobalLogger() + utils.SetupCoreDockerEnvLogger() log.Info().Msg("Starting CL cluster test environment..") _, err := test_env.NewCLTestEnvBuilder(). diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 626f7367084..5c1545dd748 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -33,11 +33,18 @@ import ( tcwait "github.com/testcontainers/testcontainers-go/wait" ) +var ( + ErrConnectNodeClient = "could not connect Node HTTP Client" + ErrStartCLNodeContainer = "failed to start CL node container" +) + type ClNode struct { EnvComponent - API *client.ChainlinkClient - NodeConfig *chainlink.Config - PostgresDb *PostgresDb + API *client.ChainlinkClient + NodeConfig *chainlink.Config + NodeSecretsConfigTOML string + PostgresDb *PostgresDb + lw *logwatch.LogWatch } type ClNodeOption = func(c *ClNode) @@ -60,7 +67,13 @@ func WithDbContainerName(name string) ClNodeOption { } } -func NewClNode(networks []string, nodeConfig chainlink.Config, opts ...ClNodeOption) *ClNode { +func WithLogWatch(lw *logwatch.LogWatch) ClNodeOption { + return func(c *ClNode) { + c.lw = lw + } +} + +func NewClNode(networks []string, nodeConfig *chainlink.Config, opts ...ClNodeOption) *ClNode { nodeDefaultCName := fmt.Sprintf("%s-%s", "cl-node", uuid.NewString()[0:3]) pgDefaultCName := fmt.Sprintf("pg-%s", nodeDefaultCName) pgDb := NewPostgresDb(networks, WithPostgresDbContainerName(pgDefaultCName)) @@ -69,7 +82,7 @@ func NewClNode(networks []string, nodeConfig chainlink.Config, opts ...ClNodeOpt ContainerName: nodeDefaultCName, Networks: networks, }, - NodeConfig: &nodeConfig, + NodeConfig: nodeConfig, PostgresDb: pgDb, } for _, opt := range opts { @@ -78,6 +91,19 @@ func NewClNode(networks []string, nodeConfig chainlink.Config, opts ...ClNodeOpt return n } +// Restart restarts only CL node, DB container is reused +func (n *ClNode) Restart(cfg *chainlink.Config) error { + if err := n.Container.Terminate(context.Background()); err != nil { + return err + } + n.NodeConfig = cfg + return n.StartContainer() +} + +func (n *ClNode) PrimaryETHAddress() (string, error) { + return n.API.PrimaryEthAddress() +} + func (n *ClNode) AddBootstrapJob(verifierAddr common.Address, fromBlock uint64, chainId int64, feedId [32]byte) (*client.Job, error) { spec := utils.BuildBootstrapSpec(verifierAddr, chainId, fromBlock, feedId) @@ -132,7 +158,7 @@ func (n *ClNode) AddMercuryOCRJob(verifierAddr common.Address, fromBlock uint64, } func (n *ClNode) GetContainerName() string { - name, err := n.EnvComponent.Container.Name(context.Background()) + name, err := n.Container.Name(context.Background()) if err != nil { return "" } @@ -177,17 +203,22 @@ func (n *ClNode) Fund(evmClient blockchain.EVMClient, amount *big.Float) error { return evmClient.Fund(toAddress, amount, gasEstimates) } -func (n *ClNode) StartContainer(lw *logwatch.LogWatch) error { - err := n.PostgresDb.StartContainer(lw) +func (n *ClNode) StartContainer() error { + err := n.PostgresDb.StartContainer() if err != nil { return err } - nodeSecrets, err := templates.ExecuteNodeSecretsTemplate( - n.PostgresDb.Password, n.PostgresDb.DbName, n.PostgresDb.ContainerName, n.PostgresDb.Port) + nodeSecretsToml, err := templates.NodeSecretsTemplate{ + PgDbName: n.PostgresDb.DbName, + PgHost: n.PostgresDb.ContainerName, + PgPort: n.PostgresDb.Port, + PgPassword: n.PostgresDb.Password, + }.String() if err != nil { return err } - cReq, err := n.getContainerRequest(nodeSecrets) + n.NodeSecretsConfigTOML = nodeSecretsToml + cReq, err := n.getContainerRequest() if err != nil { return err } @@ -197,10 +228,10 @@ func (n *ClNode) StartContainer(lw *logwatch.LogWatch) error { Reuse: true, }) if err != nil { - return errors.Wrapf(err, "could not start Chainlink Node container") + return errors.Wrap(err, ErrStartCLNodeContainer) } - if lw != nil { - if err := lw.ConnectContainer(context.Background(), container, "chainlink", true); err != nil { + if n.lw != nil { + if err := n.lw.ConnectContainer(context.Background(), container, "cl-node", true); err != nil { return err } } @@ -219,7 +250,7 @@ func (n *ClNode) StartContainer(lw *logwatch.LogWatch) error { Password: "localdevpassword", }) if err != nil { - return errors.Wrapf(err, "could not connect Node HTTP Client") + return errors.Wrap(err, ErrConnectNodeClient) } n.Container = container @@ -228,7 +259,7 @@ func (n *ClNode) StartContainer(lw *logwatch.LogWatch) error { return nil } -func (n *ClNode) getContainerRequest(secrets string) ( +func (n *ClNode) getContainerRequest() ( *tc.ContainerRequest, error) { configFile, err := os.CreateTemp("", "node_config") if err != nil { @@ -242,12 +273,11 @@ func (n *ClNode) getContainerRequest(secrets string) ( if err != nil { return nil, err } - secretsFile, err := os.CreateTemp("", "node_secrets") if err != nil { return nil, err } - _, err = secretsFile.WriteString(secrets) + _, err = secretsFile.WriteString(n.NodeSecretsConfigTOML) if err != nil { return nil, err } @@ -287,7 +317,7 @@ func (n *ClNode) getContainerRequest(secrets string) ( } return &tc.ContainerRequest{ - Name: n.EnvComponent.ContainerName, + Name: n.ContainerName, Image: fmt.Sprintf("%s:%s", image, tag), ExposedPorts: []string{"6688/tcp"}, Entrypoint: []string{"chainlink", diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index 77bceed1797..8104e665987 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -11,7 +11,6 @@ import ( "github.com/pkg/errors" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" tc "github.com/testcontainers/testcontainers-go" @@ -50,7 +49,7 @@ func NewGeth(networks []string, opts ...EnvComponentOption) *Geth { return g } -func (g *Geth) StartContainer(lw *logwatch.LogWatch) error { +func (g *Geth) StartContainer() error { r, _, _, err := g.getGethContainerRequest(g.Networks) if err != nil { return err @@ -64,11 +63,6 @@ func (g *Geth) StartContainer(lw *logwatch.LogWatch) error { if err != nil { return errors.Wrapf(err, "cannot start geth container") } - if lw != nil { - if err := lw.ConnectContainer(context.Background(), ct, "geth", true); err != nil { - return err - } - } host, err := ct.Host(context.Background()) if err != nil { return err @@ -82,7 +76,7 @@ func (g *Geth) StartContainer(lw *logwatch.LogWatch) error { return err } - g.EnvComponent.Container = ct + g.Container = ct g.ExternalHttpUrl = fmt.Sprintf("http://%s:%s", host, httpPort.Port()) g.InternalHttpUrl = fmt.Sprintf("http://%s:8544", g.ContainerName) g.ExternalWsUrl = fmt.Sprintf("ws://%s:%s", host, wsPort.Port()) @@ -147,7 +141,10 @@ func (g *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, if err != nil { return nil, ks, &account, err } - genesisJsonStr, err := templates.BuildGenesisJson(chainId, account.Address.Hex()) + genesisJsonStr, err := templates.GenesisJsonTemplate{ + ChainId: chainId, + AccountAddr: account.Address.Hex(), + }.String() if err != nil { return nil, ks, &account, err } diff --git a/integration-tests/docker/test_env/mockserver.go b/integration-tests/docker/test_env/mockserver.go index 102c04b08cf..1149bd9632d 100644 --- a/integration-tests/docker/test_env/mockserver.go +++ b/integration-tests/docker/test_env/mockserver.go @@ -11,7 +11,6 @@ import ( "github.com/pkg/errors" "github.com/rs/zerolog/log" ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" - "github.com/smartcontractkit/chainlink-testing-framework/logwatch" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" ) @@ -37,14 +36,14 @@ func NewMockServer(networks []string, opts ...EnvComponentOption) *MockServer { return ms } -func (m *MockServer) SetExternalAdapterMocks(count int) error { +func (ms *MockServer) SetExternalAdapterMocks(count int) error { for i := 0; i < count; i++ { path := fmt.Sprintf("/ea-%d", i) - err := m.Client.SetRandomValuePath(path) + err := ms.Client.SetRandomValuePath(path) if err != nil { return err } - cName, err := m.EnvComponent.Container.Name(context.Background()) + cName, err := ms.Container.Name(context.Background()) if err != nil { return err } @@ -54,56 +53,51 @@ func (m *MockServer) SetExternalAdapterMocks(count int) error { if err != nil { return err } - m.EAMockUrls = append(m.EAMockUrls, eaUrl) + ms.EAMockUrls = append(ms.EAMockUrls, eaUrl) } return nil } -func (m *MockServer) StartContainer(lw *logwatch.LogWatch) error { +func (ms *MockServer) StartContainer() error { c, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ - ContainerRequest: m.getContainerRequest(), + ContainerRequest: ms.getContainerRequest(), Started: true, Reuse: true, }) if err != nil { return errors.Wrapf(err, "cannot start MockServer container") } - m.Container = c - if lw != nil { - if err := lw.ConnectContainer(context.Background(), c, m.ContainerName, true); err != nil { - return err - } - } + ms.Container = c endpoint, err := c.Endpoint(context.Background(), "http") if err != nil { return err } - log.Info().Any("endpoint", endpoint).Str("containerName", m.ContainerName). + log.Info().Any("endpoint", endpoint).Str("containerName", ms.ContainerName). Msgf("Started MockServer container") - m.Endpoint = endpoint - m.InternalEndpoint = fmt.Sprintf("http://%s:%s", m.ContainerName, "1080") + ms.Endpoint = endpoint + ms.InternalEndpoint = fmt.Sprintf("http://%s:%s", ms.ContainerName, "1080") client := ctfClient.NewMockserverClient(&ctfClient.MockserverConfig{ LocalURL: endpoint, - ClusterURL: m.InternalEndpoint, + ClusterURL: ms.InternalEndpoint, }) if err != nil { return errors.Wrapf(err, "cannot connect to MockServer client") } - m.Client = client + ms.Client = client return nil } -func (m *MockServer) getContainerRequest() tc.ContainerRequest { +func (ms *MockServer) getContainerRequest() tc.ContainerRequest { return tc.ContainerRequest{ - Name: m.ContainerName, + Name: ms.ContainerName, Image: "mockserver/mockserver:5.11.2", ExposedPorts: []string{"1080/tcp"}, Env: map[string]string{ "SERVER_PORT": "1080", }, - Networks: m.Networks, + Networks: ms.Networks, WaitingFor: tcwait.ForLog("INFO 1080 started on port: 1080"). WithStartupTimeout(30 * time.Second). WithPollInterval(100 * time.Millisecond), diff --git a/integration-tests/docker/test_env/postgres.go b/integration-tests/docker/test_env/postgres.go index 4b886a8b9f9..9455303c683 100644 --- a/integration-tests/docker/test_env/postgres.go +++ b/integration-tests/docker/test_env/postgres.go @@ -7,7 +7,6 @@ import ( "github.com/google/uuid" "github.com/rs/zerolog/log" - "github.com/smartcontractkit/chainlink-testing-framework/logwatch" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" ) @@ -48,7 +47,7 @@ func NewPostgresDb(networks []string, opts ...PostgresDbOption) *PostgresDb { return pg } -func (pg *PostgresDb) StartContainer(lw *logwatch.LogWatch) error { +func (pg *PostgresDb) StartContainer() error { req := pg.getContainerRequest() c, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ ContainerRequest: *req, diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index 67314298d3a..895f08782c9 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -6,24 +6,35 @@ import ( "math/big" "github.com/ethereum/go-ethereum/common" + "github.com/pkg/errors" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/docker" + "github.com/smartcontractkit/chainlink/integration-tests/utils" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" tc "github.com/testcontainers/testcontainers-go" "go.uber.org/multierr" ) +var ( + ErrFundCLNode = "failed to fund CL node" + ErrGetNodeCSAKeys = "failed get CL node CSA keys" +) + type CLClusterTestEnv struct { - cfg *TestEnvConfig - Network *tc.DockerNetwork - LogWatch *logwatch.LogWatch + Cfg *TestEnvConfig + Network *tc.DockerNetwork + LogWatch *logwatch.LogWatch + + /* components */ CLNodes []*ClNode Geth *Geth MockServer *MockServer } func NewTestEnv() (*CLClusterTestEnv, error) { + utils.SetupCoreDockerEnvLogger() network, err := docker.CreateNetwork() if err != nil { return nil, err @@ -37,6 +48,7 @@ func NewTestEnv() (*CLClusterTestEnv, error) { } func NewTestEnvFromCfg(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { + utils.SetupCoreDockerEnvLogger() network, err := docker.CreateNetwork() if err != nil { return nil, err @@ -44,23 +56,35 @@ func NewTestEnvFromCfg(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { networks := []string{network.Name} log.Info().Interface("Cfg", cfg).Send() return &CLClusterTestEnv{ - cfg: cfg, + Cfg: cfg, Network: network, Geth: NewGeth(networks, WithContainerName(cfg.Geth.ContainerName)), MockServer: NewMockServer(networks, WithContainerName(cfg.MockServer.ContainerName)), }, nil } -func (m *CLClusterTestEnv) StartGeth() error { - return m.Geth.StartContainer(m.LogWatch) +func (te *CLClusterTestEnv) ParallelTransactions(enabled bool) { + te.Geth.EthClient.ParallelTransactions(enabled) +} + +func (te *CLClusterTestEnv) StartGeth() error { + return te.Geth.StartContainer() } -func (m *CLClusterTestEnv) StartMockServer() error { - return m.MockServer.StartContainer(m.LogWatch) +func (te *CLClusterTestEnv) StartMockServer() error { + return te.MockServer.StartContainer() +} + +func (te *CLClusterTestEnv) GetAPIs() []*client.ChainlinkClient { + clients := make([]*client.ChainlinkClient, 0) + for _, c := range te.CLNodes { + clients = append(clients, c.API) + } + return clients } // StartClNodes start one bootstrap node and {count} OCR nodes -func (m *CLClusterTestEnv) StartClNodes(nodeConfig chainlink.Config, count int) error { +func (te *CLClusterTestEnv) StartClNodes(nodeConfig *chainlink.Config, count int) error { var wg sync.WaitGroup var errs = []error{} var mu sync.Mutex @@ -72,21 +96,22 @@ func (m *CLClusterTestEnv) StartClNodes(nodeConfig chainlink.Config, count int) go func() { defer wg.Done() var nodeContainerName, dbContainerName string - if m.cfg != nil { - nodeContainerName = m.cfg.Nodes[i].NodeContainerName - dbContainerName = m.cfg.Nodes[i].DbContainerName + if te.Cfg != nil { + nodeContainerName = te.Cfg.Nodes[i].NodeContainerName + dbContainerName = te.Cfg.Nodes[i].DbContainerName } - n := NewClNode([]string{m.Network.Name}, nodeConfig, + n := NewClNode([]string{te.Network.Name}, nodeConfig, WithNodeContainerName(nodeContainerName), - WithDbContainerName(dbContainerName)) - err := n.StartContainer(m.LogWatch) + WithDbContainerName(dbContainerName), + WithLogWatch(te.LogWatch)) + err := n.StartContainer() if err != nil { mu.Lock() errs = append(errs, err) mu.Unlock() } else { mu.Lock() - m.CLNodes = append(m.CLNodes, n) + te.CLNodes = append(te.CLNodes, n) mu.Unlock() } }() @@ -101,9 +126,9 @@ func (m *CLClusterTestEnv) StartClNodes(nodeConfig chainlink.Config, count int) } // ChainlinkNodeAddresses will return all the on-chain wallet addresses for a set of Chainlink nodes -func (m *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { +func (te *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { addresses := make([]common.Address, 0) - for _, n := range m.CLNodes { + for _, n := range te.CLNodes { primaryAddress, err := n.ChainlinkNodeAddress() if err != nil { return nil, err @@ -114,28 +139,28 @@ func (m *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { } // FundChainlinkNodes will fund all the provided Chainlink nodes with a set amount of native currency -func (m *CLClusterTestEnv) FundChainlinkNodes(amount *big.Float) error { - for _, cl := range m.CLNodes { - if err := cl.Fund(m.Geth.EthClient, amount); err != nil { - return err +func (te *CLClusterTestEnv) FundChainlinkNodes(amount *big.Float) error { + for _, cl := range te.CLNodes { + if err := cl.Fund(te.Geth.EthClient, amount); err != nil { + return errors.Wrap(err, ErrFundCLNode) } } - return m.Geth.EthClient.WaitForEvents() + return te.Geth.EthClient.WaitForEvents() } -func (m *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { +func (te *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { var keys []string - for _, n := range m.CLNodes { + for _, n := range te.CLNodes { csaKeys, err := n.GetNodeCSAKeys() if err != nil { - return nil, err + return nil, errors.Wrap(err, ErrGetNodeCSAKeys) } keys = append(keys, csaKeys.Data[0].ID) } return keys, nil } -func (m *CLClusterTestEnv) Terminate() error { +func (te *CLClusterTestEnv) Terminate() error { // TESTCONTAINERS_RYUK_DISABLED=false by defualt so ryuk will remove all // the containers and the network return nil diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index 1d034e9a07a..43eb3a48aa2 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -6,6 +6,7 @@ import ( "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" + "math/big" ) type CLTestEnvBuilder struct { @@ -16,6 +17,9 @@ type CLTestEnvBuilder struct { externalAdapterCount int customNodeCsaKeys []string defaultNodeCsaKeys []string + + /* funding */ + ETHFunds *big.Float } func NewCLTestEnvBuilder() *CLTestEnvBuilder { @@ -24,28 +28,33 @@ func NewCLTestEnvBuilder() *CLTestEnvBuilder { } } -func (m *CLTestEnvBuilder) WithLogWatcher() *CLTestEnvBuilder { - m.hasLogWatch = true - return m +func (b *CLTestEnvBuilder) WithLogWatcher() *CLTestEnvBuilder { + b.hasLogWatch = true + return b +} + +func (b *CLTestEnvBuilder) WithCLNodes(clNodesCount int) *CLTestEnvBuilder { + b.clNodesCount = clNodesCount + return b } -func (m *CLTestEnvBuilder) WithCLNodes(clNodesCount int) *CLTestEnvBuilder { - m.clNodesCount = clNodesCount - return m +func (b *CLTestEnvBuilder) WithFunding(eth *big.Float) *CLTestEnvBuilder { + b.ETHFunds = eth + return b } -func (m *CLTestEnvBuilder) WithGeth() *CLTestEnvBuilder { - m.hasGeth = true - return m +func (b *CLTestEnvBuilder) WithGeth() *CLTestEnvBuilder { + b.hasGeth = true + return b } -func (m *CLTestEnvBuilder) WithMockServer(externalAdapterCount int) *CLTestEnvBuilder { - m.hasMockServer = true - m.externalAdapterCount = externalAdapterCount - return m +func (b *CLTestEnvBuilder) WithMockServer(externalAdapterCount int) *CLTestEnvBuilder { + b.hasMockServer = true + b.externalAdapterCount = externalAdapterCount + return b } -func (m *CLTestEnvBuilder) Build() (*CLClusterTestEnv, error) { +func (b *CLTestEnvBuilder) Build() (*CLClusterTestEnv, error) { envConfigPath, isSet := os.LookupEnv("TEST_ENV_CONFIG_PATH") if isSet { cfg, err := NewTestEnvConfigFromFile(envConfigPath) @@ -53,27 +62,26 @@ func (m *CLTestEnvBuilder) Build() (*CLClusterTestEnv, error) { return nil, err } _ = os.Setenv("TESTCONTAINERS_RYUK_DISABLED", "true") - return m.connectExistingEnv(cfg) - } else { - return m.buildNewEnv() + return b.connectExistingEnv(cfg) } + return b.buildNewEnv() } -func (m *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { +func (b *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { log.Info(). - Bool("hasGeth", m.hasGeth). - Bool("hasMockServer", m.hasMockServer). - Int("externalAdapterCount", m.externalAdapterCount). - Int("clNodesCount", m.clNodesCount). - Strs("customNodeCsaKeys", m.customNodeCsaKeys). - Strs("defaultNodeCsaKeys", m.defaultNodeCsaKeys). + Bool("hasGeth", b.hasGeth). + Bool("hasMockServer", b.hasMockServer). + Int("externalAdapterCount", b.externalAdapterCount). + Int("clNodesCount", b.clNodesCount). + Strs("customNodeCsaKeys", b.customNodeCsaKeys). + Strs("defaultNodeCsaKeys", b.defaultNodeCsaKeys). Msg("Building CL cluster test environment..") te, err := NewTestEnvFromCfg(cfg) if err != nil { return te, err } - if m.hasLogWatch { + if b.hasLogWatch { lw, err := logwatch.NewLogWatch(nil, nil) if err != nil { return te, err @@ -81,18 +89,18 @@ func (m *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTes te.LogWatch = lw } - if m.hasMockServer { + if b.hasMockServer { err := te.StartMockServer() if err != nil { return te, err } - err = te.MockServer.SetExternalAdapterMocks(m.externalAdapterCount) + err = te.MockServer.SetExternalAdapterMocks(b.externalAdapterCount) if err != nil { return te, err } } - if m.hasGeth { + if b.hasGeth { err := te.StartGeth() if err != nil { return te, err @@ -102,14 +110,14 @@ func (m *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTes var nodeCsaKeys []string // Start Chainlink Nodes - if m.clNodesCount > 0 { + if b.clNodesCount > 0 { // Create nodes nodeConfig := node.NewConfig(node.BaseConf, node.WithOCR1(), node.WithP2Pv1(), node.WithSimulatedEVM(te.Geth.InternalHttpUrl, te.Geth.InternalWsUrl), ) - err = te.StartClNodes(nodeConfig, m.clNodesCount) + err = te.StartClNodes(nodeConfig, b.clNodesCount) if err != nil { return te, err } @@ -118,20 +126,20 @@ func (m *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTes if err != nil { return te, err } - m.defaultNodeCsaKeys = nodeCsaKeys + b.defaultNodeCsaKeys = nodeCsaKeys } return te, nil } -func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { +func (b *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { log.Info(). - Bool("hasGeth", m.hasGeth). - Bool("hasMockServer", m.hasMockServer). - Int("externalAdapterCount", m.externalAdapterCount). - Int("clNodesCount", m.clNodesCount). - Strs("customNodeCsaKeys", m.customNodeCsaKeys). - Strs("defaultNodeCsaKeys", m.defaultNodeCsaKeys). + Bool("hasGeth", b.hasGeth). + Bool("hasMockServer", b.hasMockServer). + Int("externalAdapterCount", b.externalAdapterCount). + Int("clNodesCount", b.clNodesCount). + Strs("customNodeCsaKeys", b.customNodeCsaKeys). + Strs("defaultNodeCsaKeys", b.defaultNodeCsaKeys). Msg("Building CL cluster test environment..") te, err := NewTestEnv() @@ -139,7 +147,7 @@ func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { return te, err } - if m.hasLogWatch { + if b.hasLogWatch { lw, err := logwatch.NewLogWatch(nil, nil) if err != nil { return te, err @@ -147,18 +155,18 @@ func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { te.LogWatch = lw } - if m.hasMockServer { + if b.hasMockServer { err := te.StartMockServer() if err != nil { return te, err } - err = te.MockServer.SetExternalAdapterMocks(m.externalAdapterCount) + err = te.MockServer.SetExternalAdapterMocks(b.externalAdapterCount) if err != nil { return te, err } } - if m.hasGeth { + if b.hasGeth { err := te.StartGeth() if err != nil { return te, err @@ -168,14 +176,14 @@ func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { var nodeCsaKeys []string // Start Chainlink Nodes - if m.clNodesCount > 0 { + if b.clNodesCount > 0 { // Create nodes nodeConfig := node.NewConfig(node.BaseConf, node.WithOCR1(), node.WithP2Pv1(), node.WithSimulatedEVM(te.Geth.InternalHttpUrl, te.Geth.InternalWsUrl), ) - err = te.StartClNodes(nodeConfig, m.clNodesCount) + err = te.StartClNodes(nodeConfig, b.clNodesCount) if err != nil { return te, err } @@ -184,7 +192,15 @@ func (m *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { if err != nil { return te, err } - m.defaultNodeCsaKeys = nodeCsaKeys + b.defaultNodeCsaKeys = nodeCsaKeys + } + + if b.hasGeth && b.clNodesCount > 0 && b.ETHFunds != nil { + te.ParallelTransactions(true) + defer te.ParallelTransactions(false) + if err = te.FundChainlinkNodes(b.ETHFunds); err != nil { + return te, err + } } return te, nil diff --git a/integration-tests/smoke/flux_test.go b/integration-tests/smoke/flux_test.go index b76721ac3b3..fa3342c6a6e 100644 --- a/integration-tests/smoke/flux_test.go +++ b/integration-tests/smoke/flux_test.go @@ -6,6 +6,7 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/google/uuid" "github.com/smartcontractkit/chainlink-testing-framework/utils" + "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" @@ -35,14 +36,14 @@ func TestFluxBasic(t *testing.T) { err = env.MockServer.Client.SetValuePath(adapterPath, 1e5) require.NoError(t, err, "Setting mockserver value path shouldn't fail") - linkToken, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - fluxInstance, err := env.Geth.ContractDeployer.DeployFluxAggregatorContract(linkToken.Address(), contracts.DefaultFluxAggregatorOptions()) + fluxInstance, err := env.Geth.ContractDeployer.DeployFluxAggregatorContract(lt.Address(), contracts.DefaultFluxAggregatorOptions()) require.NoError(t, err, "Deploying Flux Aggregator Contract shouldn't fail") err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Failed waiting for deployment of flux aggregator contract") - err = linkToken.Transfer(fluxInstance.Address(), big.NewInt(1e18)) + err = lt.Transfer(fluxInstance.Address(), big.NewInt(1e18)) require.NoError(t, err, "Funding Flux Aggregator Contract shouldn't fail") err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Failed waiting for funding of flux aggregator contract") @@ -50,8 +51,8 @@ func TestFluxBasic(t *testing.T) { err = fluxInstance.UpdateAvailableFunds() require.NoError(t, err, "Updating the available funds on the Flux Aggregator Contract shouldn't fail") - err = env.FundChainlinkNodes(big.NewFloat(.02)) - require.NoError(t, err, "Funding chainlink nodes with ETH shouldn't fail") + err = env.FundChainlinkNodes(big.NewFloat(1)) + require.NoError(t, err, "Failed to fund the nodes") err = fluxInstance.SetOracles( contracts.FluxAggregatorSetOraclesOptions{ diff --git a/integration-tests/smoke/runlog_test.go b/integration-tests/smoke/runlog_test.go index aa90062a2bc..98e1a08af05 100644 --- a/integration-tests/smoke/runlog_test.go +++ b/integration-tests/smoke/runlog_test.go @@ -21,12 +21,10 @@ func TestRunLogBasic(t *testing.T) { WithGeth(). WithMockServer(1). WithCLNodes(1). + WithFunding(big.NewFloat(1)). Build() require.NoError(t, err) - err = env.FundChainlinkNodes(big.NewFloat(.01)) - require.NoError(t, err, "Funding chainlink nodes with ETH shouldn't fail") - lt, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") oracle, err := env.Geth.ContractDeployer.DeployOracle(lt.Address()) diff --git a/integration-tests/smoke/vrf_test.go b/integration-tests/smoke/vrf_test.go index f3201fe95ad..728e279a46f 100644 --- a/integration-tests/smoke/vrf_test.go +++ b/integration-tests/smoke/vrf_test.go @@ -7,6 +7,7 @@ import ( "github.com/onsi/gomega" "github.com/smartcontractkit/chainlink-testing-framework/utils" "github.com/smartcontractkit/chainlink/integration-tests/actions" + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv1" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" "github.com/stretchr/testify/require" @@ -22,25 +23,17 @@ func TestVRFBasic(t *testing.T) { WithGeth(). WithMockServer(1). WithCLNodes(1). + WithFunding(big.NewFloat(1)). Build() require.NoError(t, err) - env.Geth.EthClient.ParallelTransactions(true) + env.ParallelTransactions(true) - err = env.FundChainlinkNodes(big.NewFloat(.01)) - require.NoError(t, err, "Funding chainlink nodes with ETH shouldn't fail") - - lt, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - bhs, err := env.Geth.ContractDeployer.DeployBlockhashStore() - require.NoError(t, err, "Deploying Blockhash store shouldn't fail") - coordinator, err := env.Geth.ContractDeployer.DeployVRFCoordinator(lt.Address(), bhs.Address()) - require.NoError(t, err, "Deploying VRF coordinator shouldn't fail") - consumer, err := env.Geth.ContractDeployer.DeployVRFConsumer(lt.Address(), coordinator.Address()) - require.NoError(t, err, "Deploying VRF consumer contract shouldn't fail") - err = env.Geth.EthClient.WaitForEvents() - require.NoError(t, err, "Failed to wait for VRF setup contracts to deploy") + contracts, err := vrfv1.DeployVRFContracts(env.Geth.ContractDeployer, env.Geth.EthClient, lt) + require.NoError(t, err, "Deploying VRF Contracts shouldn't fail") - err = lt.Transfer(consumer.Address(), big.NewInt(2e18)) + err = lt.Transfer(contracts.Consumer.Address(), big.NewInt(2e18)) require.NoError(t, err, "Funding consumer contract shouldn't fail") _, err = env.Geth.ContractDeployer.DeployVRFContract() require.NoError(t, err, "Deploying VRF contract shouldn't fail") @@ -54,13 +47,13 @@ func TestVRFBasic(t *testing.T) { pubKeyCompressed := nodeKey.Data.ID jobUUID := uuid.New() os := &client.VRFTxPipelineSpec{ - Address: coordinator.Address(), + Address: contracts.Coordinator.Address(), } ost, err := os.String() require.NoError(t, err, "Building observation source spec shouldn't fail") job, err := n.API.MustCreateJob(&client.VRFJobSpec{ Name: fmt.Sprintf("vrf-%s", jobUUID), - CoordinatorAddress: coordinator.Address(), + CoordinatorAddress: contracts.Coordinator.Address(), MinIncomingConfirmations: 1, PublicKey: pubKeyCompressed, ExternalJobID: jobUUID.String(), @@ -72,7 +65,7 @@ func TestVRFBasic(t *testing.T) { require.NoError(t, err, "Getting primary ETH address of chainlink node shouldn't fail") provingKey, err := actions.EncodeOnChainVRFProvingKey(*nodeKey) require.NoError(t, err, "Encoding on-chain VRF Proving key shouldn't fail") - err = coordinator.RegisterProvingKey( + err = contracts.Coordinator.RegisterProvingKey( big.NewInt(1), oracleAddr, provingKey, @@ -82,9 +75,9 @@ func TestVRFBasic(t *testing.T) { encodedProvingKeys := make([][2]*big.Int, 0) encodedProvingKeys = append(encodedProvingKeys, provingKey) - requestHash, err := coordinator.HashOfKey(context.Background(), encodedProvingKeys[0]) + requestHash, err := contracts.Coordinator.HashOfKey(context.Background(), encodedProvingKeys[0]) require.NoError(t, err, "Getting Hash of encoded proving keys shouldn't fail") - err = consumer.RequestRandomness(requestHash, big.NewInt(1)) + err = contracts.Consumer.RequestRandomness(requestHash, big.NewInt(1)) require.NoError(t, err, "Requesting randomness shouldn't fail") gom := gomega.NewGomegaWithT(t) @@ -93,7 +86,7 @@ func TestVRFBasic(t *testing.T) { jobRuns, err := env.CLNodes[0].API.MustReadRunsByJob(job.Data.ID) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Job execution shouldn't fail") - out, err := consumer.RandomnessOutput(context.Background()) + out, err := contracts.Consumer.RandomnessOutput(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Getting the randomness output of the consumer shouldn't fail") // Checks that the job has actually run g.Expect(len(jobRuns.Data)).Should(gomega.BeNumerically(">=", 1), diff --git a/integration-tests/smoke/vrfv2_test.go b/integration-tests/smoke/vrfv2_test.go index db1255aebeb..bb54425dc0a 100644 --- a/integration-tests/smoke/vrfv2_test.go +++ b/integration-tests/smoke/vrfv2_test.go @@ -7,113 +7,106 @@ import ( "time" "github.com/onsi/gomega" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" + "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions" - "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/config" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + vrfConst "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" ) func TestVRFv2Basic(t *testing.T) { - t.Parallel() l := utils.GetTestLogger(t) - testNetwork := networks.SelectedNetwork - testEnvironment := vrfv2_actions.SetupVRFV2Environment( - t, - testNetwork, - config.BaseVRFV2NetworkDetailTomlConfig, - "", - "smoke-vrfv2", - "", - time.Minute*20, - ) - if testEnvironment.WillUseRemoteRunner() { - return - } + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(1). + WithFunding(vrfConst.ChainlinkNodeFundingAmountEth). + Build() + require.NoError(t, err) + env.ParallelTransactions(true) - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) + mockFeed, err := actions.DeployMockETHLinkFeed(env.Geth.ContractDeployer, vrfConst.LinkEthFeedResponse) require.NoError(t, err) - contractDeployer, err := contracts.NewContractDeployer(chainClient) + lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) require.NoError(t, err) - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) + vrfv2Contracts, err := vrfv2_actions.DeployVRFV2Contracts(env.Geth.ContractDeployer, env.Geth.EthClient, lt, mockFeed) require.NoError(t, err) - chainClient.ParallelTransactions(true) + err = env.Geth.EthClient.WaitForEvents() + require.NoError(t, err) - mockETHLINKFeed, err := contractDeployer.DeployMockETHLINKFeed(vrfv2_constants.LinkEthFeedResponse) + err = vrfv2Contracts.Coordinator.SetConfig( + vrfConst.MinimumConfirmations, + vrfConst.MaxGasLimitVRFCoordinatorConfig, + vrfConst.StalenessSeconds, + vrfConst.GasAfterPaymentCalculation, + vrfConst.LinkEthFeedResponse, + vrfConst.VRFCoordinatorV2FeeConfig, + ) require.NoError(t, err) - linkToken, err := contractDeployer.DeployLinkTokenContract() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err) - vrfV2Contracts, chainlinkNodesAfterRedeployment, vrfV2jobs, testEnvironmentAfterRedeployment := vrfv2_actions.SetupVRFV2Universe( - t, - linkToken, - mockETHLINKFeed, - contractDeployer, - chainClient, - chainlinkNodes, - testNetwork, - testEnvironment, - vrfv2_constants.ChainlinkNodeFundingAmountEth, - vrfv2_constants.VRFSubscriptionFundingAmountLink, - "smoke-vrfv2", - time.Minute*20, + err = vrfv2Contracts.Coordinator.CreateSubscription() + require.NoError(t, err) + err = env.Geth.EthClient.WaitForEvents() + require.NoError(t, err) + + err = vrfv2Contracts.Coordinator.AddConsumer(vrfConst.SubID, vrfv2Contracts.LoadTestConsumer.Address()) + require.NoError(t, err) + + err = vrfv2_actions.FundVRFCoordinatorV2Subscription(lt, vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.SubID, vrfConst.VRFSubscriptionFundingAmountLink) + require.NoError(t, err) + + vrfV2jobs, err := vrfv2_actions.CreateVRFV2Jobs(env.GetAPIs(), vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.MinimumConfirmations) + require.NoError(t, err) + + // this part is here because VRFv2 can work with only a specific key + // [[EVM.KeySpecific]] + // Key = '...' + addr, err := env.CLNodes[0].API.PrimaryEthAddress() + require.NoError(t, err) + nodeConfig := node.NewConfig(env.CLNodes[0].NodeConfig, + node.WithVRFv2EVMEstimator(addr), ) + err = env.CLNodes[0].Restart(nodeConfig) + require.NoError(t, err) - consumerContract := vrfV2Contracts.LoadTestConsumer - - t.Cleanup(func() { - err := actions.TeardownSuite( - t, - testEnvironmentAfterRedeployment, - utils.ProjectRoot, - chainlinkNodesAfterRedeployment, - nil, - zapcore.ErrorLevel, - chainClient, - ) - require.NoError(t, err, "Error tearing down environment") - }) - - err = consumerContract.RequestRandomness( + // test and assert + err = vrfv2Contracts.LoadTestConsumer.RequestRandomness( vrfV2jobs[0].KeyHash, - vrfv2_constants.SubID, - vrfv2_constants.MinimumConfirmations, - vrfv2_constants.CallbackGasLimit, - vrfv2_constants.NumberOfWords, - vrfv2_constants.RandomnessRequestCountPerRequest, + vrfConst.SubID, + vrfConst.MinimumConfirmations, + vrfConst.CallbackGasLimit, + vrfConst.NumberOfWords, + vrfConst.RandomnessRequestCountPerRequest, ) require.NoError(t, err) gom := gomega.NewGomegaWithT(t) - timeout := time.Minute * 2 + timeout := time.Minute * 1 var lastRequestID *big.Int gom.Eventually(func(g gomega.Gomega) { - jobRuns, err := chainlinkNodesAfterRedeployment[0].MustReadRunsByJob(vrfV2jobs[0].Job.Data.ID) + jobRuns, err := env.CLNodes[0].API.MustReadRunsByJob(vrfV2jobs[0].Job.Data.ID) g.Expect(err).ShouldNot(gomega.HaveOccurred()) g.Expect(len(jobRuns.Data)).Should(gomega.BeNumerically("==", 1)) - lastRequestID, err = consumerContract.GetLastRequestId(context.Background()) + lastRequestID, err = vrfv2Contracts.LoadTestConsumer.GetLastRequestId(context.Background()) l.Debug().Interface("Last Request ID", lastRequestID).Msg("Last Request ID Received") g.Expect(err).ShouldNot(gomega.HaveOccurred()) - status, err := consumerContract.GetRequestStatus(context.Background(), lastRequestID) + status, err := vrfv2Contracts.LoadTestConsumer.GetRequestStatus(context.Background(), lastRequestID) g.Expect(err).ShouldNot(gomega.HaveOccurred()) g.Expect(status.Fulfilled).Should(gomega.BeTrue()) l.Debug().Interface("Fulfilment Status", status.Fulfilled).Msg("Random Words Request Fulfilment Status") g.Expect(err).ShouldNot(gomega.HaveOccurred()) for _, w := range status.RandomWords { - l.Debug().Uint64("Output", w.Uint64()).Msg("Randomness fulfilled") + l.Info().Uint64("Output", w.Uint64()).Msg("Randomness fulfilled") g.Expect(w.Uint64()).Should(gomega.BeNumerically(">", 0), "Expected the VRF job give an answer bigger than 0") } }, timeout, "1s").Should(gomega.Succeed()) diff --git a/integration-tests/soak/vrfv2_test.go b/integration-tests/soak/vrfv2_test.go deleted file mode 100644 index f6e9ba99b25..00000000000 --- a/integration-tests/soak/vrfv2_test.go +++ /dev/null @@ -1,151 +0,0 @@ -package soak - -import ( - "fmt" - "math/big" - "testing" - "time" - - "github.com/kelseyhightower/envconfig" - "github.com/rs/zerolog" - "github.com/stretchr/testify/require" - - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - - "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions" - "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/config" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" - "github.com/smartcontractkit/chainlink/integration-tests/testsetups" -) - -func TestVRFV2Soak(t *testing.T) { - var testInputs testsetups.VRFV2SoakTestInputs - err := envconfig.Process("VRFV2", &testInputs) - require.NoError(t, err, "Error reading VRFV2 soak test inputs") - vrfSubscriptionFundingAmountInLink := testInputs.SubscriptionFunding - chainlinkNodeFundingAmountEth := testInputs.ChainlinkNodeFunding - randomnessRequestCountPerRequest := testInputs.RandomnessRequestCountPerRequest - - l := utils.GetTestLogger(t) - - testInputs.SetForRemoteRunner() - testNetwork := networks.SelectedNetwork // Environment currently being used to soak test on - - testEnvironment := vrfv2_actions.SetupVRFV2Environment( - t, - testNetwork, - config.BaseVRFV2NetworkDetailTomlConfig, - "", - "soak-vrfv2", - "", - //todo - what should be TTL for soak test? - time.Minute*60, - ) - if testEnvironment.WillUseRemoteRunner() { - return - } - - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err) - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err) - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err) - chainClient.ParallelTransactions(true) - - mockETHLINKFeed, err := contractDeployer.DeployMockETHLINKFeed(vrfv2_constants.LinkEthFeedResponse) - require.NoError(t, err) - linkToken, err := contractDeployer.DeployLinkTokenContract() - require.NoError(t, err) - - vrfV2Contracts, chainlinkNodesAfterRedeployment, vrfV2jobs, _ := vrfv2_actions.SetupVRFV2Universe( - t, - linkToken, - mockETHLINKFeed, - contractDeployer, - chainClient, - chainlinkNodes, - testNetwork, - testEnvironment, - chainlinkNodeFundingAmountEth, - vrfSubscriptionFundingAmountInLink, - "soak-vrfv2", - time.Hour*1, - ) - - consumerContract := vrfV2Contracts.LoadTestConsumer - - vrfV2SoakTest := testsetups.NewVRFV2SoakTest(&testsetups.VRFV2SoakTestInputs{ - BlockchainClient: chainClient, - TestDuration: testInputs.TestDuration, - ChainlinkNodeFunding: chainlinkNodeFundingAmountEth, - SubscriptionFunding: vrfSubscriptionFundingAmountInLink, - StopTestOnError: testInputs.StopTestOnError, - RequestsPerMinute: testInputs.RequestsPerMinute, - ConsumerContract: consumerContract, - TestFunc: func(t *testsetups.VRFV2SoakTest, requestNumber int) error { - // request randomness - err = consumerContract.RequestRandomness( - vrfV2jobs[0].KeyHash, - vrfv2_constants.SubID, - vrfv2_constants.MinimumConfirmations, - vrfv2_constants.CallbackGasLimit, - vrfv2_constants.NumberOfWords, - uint16(randomnessRequestCountPerRequest), - ) - if err != nil { - return fmt.Errorf("error occurred Requesting Randomness, error: %w", err) - } - - l.Info(). - Int("Request Number", requestNumber). - Int("Randomness Request Count Per Request", randomnessRequestCountPerRequest). - Msg("Randomness requested") - - printDebugData(l, vrfV2Contracts, chainlinkNodesAfterRedeployment) - - return nil - }, - }, - chainlinkNodesAfterRedeployment) - - t.Cleanup(func() { - if err := actions.TeardownRemoteSuite(vrfV2SoakTest.TearDownVals(t)); err != nil { - l.Error().Err(err).Msg("Error tearing down environment") - } - }) - vrfV2SoakTest.Setup(t, testEnvironment) - l.Info().Msg("Set up soak test") - vrfV2SoakTest.Run(t) -} - -func printDebugData(l zerolog.Logger, vrfV2Contracts vrfv2_actions.VRFV2Contracts, chainlinkNodesAfterRedeployment []*client.ChainlinkK8sClient) { - subscription, err := vrfV2Contracts.Coordinator.GetSubscription(nil, vrfv2_constants.SubID) - if err != nil { - l.Error().Err(err). - Uint64("Subscription ID", vrfv2_constants.SubID). - Interface("Coordinator Address", vrfV2Contracts.Coordinator.Address()). - Msg("error occurred Getting Subscription Data from a Coordinator Contract") - } - l.Debug().Interface("Data", subscription).Uint64("Subscription ID", vrfv2_constants.SubID).Msg("Subscription Data") - remainingSubBalanceInLink := new(big.Float).Quo(new(big.Float).SetInt(subscription.Balance), big.NewFloat(1e18)) - l.Debug().Interface("Balance", remainingSubBalanceInLink).Msg("Remaining Balance in Link for a subscription") - nativeTokenPrimaryKey, err := chainlinkNodesAfterRedeployment[0].ReadPrimaryETHKey() - if err != nil { - l.Error().Err(err).Msg("error occurred reading Native Token Primary Key from Chainlink Node") - } - ethBalance, ok := new(big.Int).SetString(nativeTokenPrimaryKey.Attributes.ETHBalance, 10) - if !ok { - l.Error().Interface("Balance", nativeTokenPrimaryKey.Attributes.ETHBalance).Msg("error occurred converting Native Token Primary Key from Chainlink Node") - } - remainingNativeTokenPrimaryKeyBalanceInETH := new(big.Float).Quo(new(big.Float).SetInt(ethBalance), big.NewFloat(1e18)) - l.Debug(). - Interface("Balance", remainingNativeTokenPrimaryKeyBalanceInETH). - Interface("Key Address", nativeTokenPrimaryKey.Attributes.Address). - Msg("Remaining Balance for a Native Token Primary Key of Chainlink Node") -} diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go index ad10fcd8ddf..43b8ff84ab8 100644 --- a/integration-tests/types/config/node/core.go +++ b/integration-tests/types/config/node/core.go @@ -9,12 +9,13 @@ import ( evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" "github.com/smartcontractkit/chainlink/v2/core/config/toml" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" "go.uber.org/zap/zapcore" ) -var BaseConf = chainlink.Config{ +var BaseConf = &chainlink.Config{ Core: toml.Core{ RootDir: ptr("/home/chainlink"), Database: toml.Database{ @@ -50,9 +51,9 @@ var BaseConf = chainlink.Config{ type NodeConfigOpt = func(c *chainlink.Config) -func NewConfig(baseConf chainlink.Config, opts ...NodeConfigOpt) chainlink.Config { +func NewConfig(baseConf *chainlink.Config, opts ...NodeConfigOpt) *chainlink.Config { for _, opt := range opts { - opt(&baseConf) + opt(baseConf) } return baseConf } @@ -115,8 +116,17 @@ func WithSimulatedEVM(httpUrl, wsUrl string) NodeConfigOpt { } } -func WithVRFv2EVMEstimator() NodeConfigOpt { +func WithVRFv2EVMEstimator(addr string) NodeConfigOpt { + est := assets.Wei(*big.NewInt(350000)) return func(c *chainlink.Config) { + c.EVM[0].KeySpecific = evmcfg.KeySpecificConfig{ + { + Key: ptr(ethkey.EIP55Address(addr)), + GasEstimator: evmcfg.KeySpecificGasEstimator{ + PriceMax: ptr(est), + }, + }, + } c.EVM[0].Chain.GasEstimator = evmcfg.GasEstimator{ LimitDefault: ptr[uint32](3500000), } diff --git a/integration-tests/utils/log.go b/integration-tests/utils/log.go index a86333cc882..499be8002d4 100644 --- a/integration-tests/utils/log.go +++ b/integration-tests/utils/log.go @@ -6,8 +6,8 @@ import ( "os" ) -func SetupGlobalLogger() { - lvlStr := os.Getenv("GLOBAL_LOG_LEVEL") +func SetupCoreDockerEnvLogger() { + lvlStr := os.Getenv("CORE_DOCKER_ENV_LOG_LEVEL") if lvlStr == "" { lvlStr = "info" } diff --git a/integration-tests/utils/templates/geth.go b/integration-tests/utils/templates/geth.go index db4eee1c1d6..11ccc8dd4ba 100644 --- a/integration-tests/utils/templates/geth.go +++ b/integration-tests/utils/templates/geth.go @@ -1,24 +1,17 @@ package templates import ( - "bytes" - "fmt" - "os" - "text/template" + "github.com/google/uuid" ) -var InitGethScript = ` -#!/bin/bash -if [ ! -d /root/.ethereum/keystore ]; then - echo "/root/.ethereum/keystore not found, running 'geth init'..." - geth init /root/genesis.json - echo "...done!" -fi - -geth "$@" -` +type GenesisJsonTemplate struct { + AccountAddr string + ChainId string +} -var GenesisJson = ` +// String representation of the job +func (c GenesisJsonTemplate) String() (string, error) { + tpl := ` { "config": { "chainId": {{ .ChainId }}, @@ -48,24 +41,16 @@ var GenesisJson = ` } } }` + return MarshalTemplate(c, uuid.NewString(), tpl) +} -func BuildGenesisJson(chainId, accountAddr string) (string, error) { - data := struct { - AccountAddr string - ChainId string - }{ - AccountAddr: accountAddr, - ChainId: chainId, - } - - t, err := template.New("genesis-json").Parse(GenesisJson) - if err != nil { - fmt.Println("Error parsing template:", err) - os.Exit(1) - } - - var buf bytes.Buffer - err = t.Execute(&buf, data) +var InitGethScript = ` +#!/bin/bash +if [ ! -d /root/.ethereum/keystore ]; then + echo "/root/.ethereum/keystore not found, running 'geth init'..." + geth init /root/genesis.json + echo "...done!" +fi - return buf.String(), err -} +geth "$@" +` diff --git a/integration-tests/utils/templates/node_secrets.go b/integration-tests/utils/templates/node_secrets.go deleted file mode 100644 index 56d63d1d480..00000000000 --- a/integration-tests/utils/templates/node_secrets.go +++ /dev/null @@ -1,47 +0,0 @@ -package templates - -import ( - "bytes" - "fmt" - "os" - "text/template" -) - -var NodeSecretsTemplate = ` -[Database] -URL = 'postgresql://postgres:{{ .PgPassword }}@{{ .PgHost }}:{{ .PgPort }}/{{ .PgDbName }}?sslmode=disable' # Required - -[Password] -Keystore = 'mysecretpassword' # Required - -[Mercury.Credentials.cred1] -# URL = 'http://host.docker.internal:3000/reports' -URL = 'localhost:1338' -Username = 'node' -Password = 'nodepass' -` - -func ExecuteNodeSecretsTemplate(pgPassowrd, pgDbName, pgHost, pgPort string) (string, error) { - data := struct { - PgDbName string - PgHost string - PgPort string - PgPassword string - }{ - PgDbName: pgDbName, - PgHost: pgHost, - PgPort: pgPort, - PgPassword: pgPassowrd, - } - - t, err := template.New("node-secrets").Parse(NodeSecretsTemplate) - if err != nil { - fmt.Println("Error parsing template:", err) - os.Exit(1) - } - - var buf bytes.Buffer - err = t.Execute(&buf, data) - - return buf.String(), err -} diff --git a/integration-tests/utils/templates/secrets.go b/integration-tests/utils/templates/secrets.go new file mode 100644 index 00000000000..09d45f15cca --- /dev/null +++ b/integration-tests/utils/templates/secrets.go @@ -0,0 +1,29 @@ +package templates + +import "github.com/google/uuid" + +// NodeSecretsTemplate are used as text templates because of secret redacted fields of chainlink.Secrets +// secret fields can't be marshalled as a plain text +type NodeSecretsTemplate struct { + PgDbName string + PgHost string + PgPort string + PgPassword string +} + +func (c NodeSecretsTemplate) String() (string, error) { + tpl := ` +[Database] +URL = 'postgresql://postgres:{{ .PgPassword }}@{{ .PgHost }}:{{ .PgPort }}/{{ .PgDbName }}?sslmode=disable' # Required + +[Password] +Keystore = '................' # Required + +[Mercury.Credentials.cred1] +# URL = 'http://host.docker.internal:3000/reports' +URL = 'localhost:1338' +Username = 'node' +Password = 'nodepass' +` + return MarshalTemplate(c, uuid.NewString(), tpl) +} diff --git a/integration-tests/utils/templates/template.go b/integration-tests/utils/templates/template.go new file mode 100644 index 00000000000..515c9968e1f --- /dev/null +++ b/integration-tests/utils/templates/template.go @@ -0,0 +1,25 @@ +package templates + +import ( + "bytes" + "errors" + "text/template" +) + +var ( + ErrParsingTemplate = errors.New("failed to parse Go text template") +) + +// MarshalTemplate Helper to marshal templates +func MarshalTemplate(jobSpec interface{}, name, templateString string) (string, error) { + var buf bytes.Buffer + tmpl, err := template.New(name).Parse(templateString) + if err != nil { + return "", errors.Join(err, ErrParsingTemplate) + } + err = tmpl.Execute(&buf, jobSpec) + if err != nil { + return "", err + } + return buf.String(), err +} From 58f4a5289d0d1c6ff206faf74b66c6e1e6ee1681 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Tue, 8 Aug 2023 06:37:16 -0700 Subject: [PATCH 110/270] [Functions] Unit tests for Listener v1 (#10109) Previously disabled during multi-stage refactoring. --- core/services/functions/listener_test.go | 244 ++++++++++-------- .../evm/types/mocks/log_poller_wrapper.go | 142 ++++++++++ core/services/relay/evm/types/types.go | 2 + 3 files changed, 284 insertions(+), 104 deletions(-) create mode 100644 core/services/relay/evm/types/mocks/log_poller_wrapper.go diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index 3059798f09e..9085cc0b04c 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -19,7 +19,6 @@ import ( cl_cbor "github.com/smartcontractkit/chainlink/v2/core/cbor" log_mocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log/mocks" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" @@ -35,6 +34,8 @@ import ( threshold_mocks "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/threshold/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" + evmrelay_mocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types/mocks" s4_mocks "github.com/smartcontractkit/chainlink/v2/core/services/s4/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization" @@ -45,14 +46,15 @@ import ( ) type FunctionsListenerUniverse struct { - service *functions_service.FunctionsListener - bridgeAccessor *functions_mocks.BridgeAccessor - eaClient *functions_mocks.ExternalAdapterClient - pluginORM *functions_mocks.ORM - logBroadcaster *log_mocks.Broadcaster - ingressClient *sync_mocks.TelemetryIngressClient - decryptor *threshold_mocks.Decryptor - contractVersion uint32 + service *functions_service.FunctionsListener + bridgeAccessor *functions_mocks.BridgeAccessor + eaClient *functions_mocks.ExternalAdapterClient + pluginORM *functions_mocks.ORM + logBroadcaster *log_mocks.Broadcaster + ingressClient *sync_mocks.TelemetryIngressClient + decryptor *threshold_mocks.Decryptor + logPollerWrapper *evmrelay_mocks.LogPollerWrapper + contractVersion uint32 } func ptr[T any](t T) *T { return &t } @@ -73,7 +75,7 @@ var ( NonSubOwnerAddr common.Address = common.HexToAddress("0x60C9CF55b9de9A956d921A97575108149b758131") ) -func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySec int, setTiers bool) *FunctionsListenerUniverse { +func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySec int, setTiers bool, version uint32) *FunctionsListenerUniverse { cfg := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { c.EVM[0].MinIncomingConfirmations = ptr[uint32](1) }) @@ -98,6 +100,8 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe "decryptionQueueConfig": map[string]interface{}{ "decryptRequestTimeoutSec": 100, }, + "contractVersion": version, + "listenerEventsCheckFrequencyMillis": 100, // only applicable to v1 } if setTiers { jsonConfig["maxRequestSizesList"] = []uint32{10, 100, 1_000} @@ -128,22 +132,24 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe s4Storage := s4_mocks.NewStorage(t) client := chain.Client() - functionsListener := functions_service.NewFunctionsListener(jb, client, contractAddress, bridgeAccessor, pluginORM, pluginConfig, s4Storage, broadcaster, lggr, mailMon, monEndpoint, decryptor, nil) + logPollerWrapper := evmrelay_mocks.NewLogPollerWrapper(t) + functionsListener := functions_service.NewFunctionsListener(jb, client, contractAddress, bridgeAccessor, pluginORM, pluginConfig, s4Storage, broadcaster, lggr, mailMon, monEndpoint, decryptor, logPollerWrapper) return &FunctionsListenerUniverse{ - service: functionsListener, - bridgeAccessor: bridgeAccessor, - eaClient: eaClient, - pluginORM: pluginORM, - logBroadcaster: broadcaster, - ingressClient: ingressClient, - decryptor: decryptor, - contractVersion: pluginConfig.ContractVersion, + service: functionsListener, + bridgeAccessor: bridgeAccessor, + eaClient: eaClient, + pluginORM: pluginORM, + logBroadcaster: broadcaster, + ingressClient: ingressClient, + decryptor: decryptor, + logPollerWrapper: logPollerWrapper, + contractVersion: pluginConfig.ContractVersion, } } func PrepareAndStartFunctionsListener(t *testing.T, cbor []byte) (*FunctionsListenerUniverse, *log_mocks.Broadcast, chan struct{}) { - uni := NewFunctionsListenerUniverse(t, 0, 1_000_000, false) + uni := NewFunctionsListenerUniverse(t, 0, 1_000_000, false, 0) uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) err := uni.service.Start(testutils.Context(t)) @@ -151,29 +157,15 @@ func PrepareAndStartFunctionsListener(t *testing.T, cbor []byte) (*FunctionsList log := log_mocks.NewBroadcast(t) uni.logBroadcaster.On("WasAlreadyConsumed", mock.Anything, mock.Anything).Return(false, nil) - switch uni.contractVersion { - case 0: - logOracleRequest := ocr2dr_oracle.OCR2DROracleOracleRequest{ - RequestId: RequestID, - RequestingContract: common.Address{}, - RequestInitiator: common.Address{}, - SubscriptionId: uint64(SubscriptionID), - SubscriptionOwner: SubscriptionOwner, - Data: cbor, - } - log.On("DecodedLog").Return(&logOracleRequest) - case 1: - logOracleRequest := functions_coordinator.FunctionsCoordinatorOracleRequest{ - RequestId: RequestID, - RequestingContract: common.Address{}, - RequestInitiator: common.Address{}, - SubscriptionId: uint64(SubscriptionID), - SubscriptionOwner: SubscriptionOwner, - Data: cbor, - } - log.On("DecodedLog").Return(&logOracleRequest) + logOracleRequest := ocr2dr_oracle.OCR2DROracleOracleRequest{ + RequestId: RequestID, + RequestingContract: common.Address{}, + RequestInitiator: common.Address{}, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Data: cbor, } - + log.On("DecodedLog").Return(&logOracleRequest) log.On("String").Return("") return uni, log, make(chan struct{}) } @@ -424,7 +416,7 @@ func TestFunctionsListener_RequestTimeout(t *testing.T) { reqId := newRequestID() doneCh := make(chan bool) - uni := NewFunctionsListenerUniverse(t, 1, 1_000_000, false) + uni := NewFunctionsListenerUniverse(t, 1, 1_000_000, false, 0) uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) uni.pluginORM.On("TimeoutExpiredResults", mock.Anything, uint32(1), mock.Anything).Return([]functions_service.RequestID{reqId}, nil).Run(func(args mock.Arguments) { doneCh <- true @@ -461,7 +453,7 @@ func TestFunctionsListener_PruneRequests(t *testing.T) { t.Parallel() doneCh := make(chan bool) - uni := NewFunctionsListenerUniverse(t, 0, 1, false) + uni := NewFunctionsListenerUniverse(t, 0, 1, false, 0) uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) uni.pluginORM.On("PruneOldestRequests", functions_service.DefaultPruneMaxStoredRequests, functions_service.DefaultPruneBatchSize, mock.Anything).Return(uint32(0), uint32(0), nil).Run(func(args mock.Arguments) { doneCh <- true @@ -503,63 +495,107 @@ func TestFunctionsListener_RequestSignatureVerificationFailure(t *testing.T) { assert.EqualError(t, err, "invalid request signature: signer's address does not match subscription owner") } -// func TestFunctionsListener_HandleOracleRequestV1_Success(t *testing.T) { -// testutils.SkipShortDB(t) -// t.Parallel() - -// uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) - -// flags := [32]byte{} -// flags[1] = 1 // tier no 1 of request size -// request := functions_coordinator.FunctionsCoordinatorOracleRequest{ -// RequestId: RequestID, -// SubscriptionId: uint64(SubscriptionID), -// SubscriptionOwner: SubscriptionOwner, -// Flags: flags, -// Data: make([]byte, 12), // tier 1 should allow for up to 100 bytes -// } - -// uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) -// uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) -// log := log_mocks.NewBroadcast(t) -// uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) -// log.On("String").Return("") -// uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) -// uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) -// uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Return(nil) -// err := uni.service.Start(testutils.Context(t)) -// require.NoError(t, err) - -// uni.service.HandleOracleRequestV1(&request, log) -// uni.service.Close() -// } - -// TODO -// func TestFunctionsListener_HandleOracleRequestV1_CBORTooBig(t *testing.T) { -// testutils.SkipShortDB(t) -// t.Parallel() - -// uni := NewFunctionsListenerUniverse(t, 1_000, 1_000_000, true) - -// flags := [32]byte{} -// flags[1] = 1 // tier no 1 of request size -// request := functions_coordinator.FunctionsCoordinatorOracleRequest{ -// RequestId: RequestID, -// SubscriptionId: uint64(SubscriptionID), -// SubscriptionOwner: SubscriptionOwner, -// Flags: flags, -// Data: make([]byte, 120), // tier 1 only allows for up to 100 bytes -// } - -// uni.logBroadcaster.On("Register", mock.Anything, mock.Anything).Return(func() {}) -// uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) -// log := log_mocks.NewBroadcast(t) -// uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) -// log.On("String").Return("") -// uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, []byte("request too big (max 100 bytes)"), mock.Anything, mock.Anything, mock.Anything).Return(nil) -// err := uni.service.Start(testutils.Context(t)) -// require.NoError(t, err) - -// uni.service.HandleOracleRequestV1(&request, log) -// uni.service.Close() -// } +func getFlags(requestSizeTier int, secretSizeTier int) [32]byte { + var flags [32]byte + flags[1] = byte(requestSizeTier) + flags[2] = byte(secretSizeTier) + return flags +} + +func TestFunctionsListener_HandleOracleRequestV1_Success(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + uni := NewFunctionsListenerUniverse(t, 0, 1_000_000, true, 1) + require.NoError(t, uni.service.Start(testutils.Context(t))) + doneCh := make(chan struct{}) + + request := types.OracleRequest{ + RequestId: RequestID, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Flags: getFlags(1, 0), // tier no 1 of request size, allows up to 100 bytes + Data: make([]byte, 12), + } + + uni.logPollerWrapper.On("LatestEvents").Return([]types.OracleRequest{request}, nil, nil).Once() + uni.logPollerWrapper.On("LatestEvents").Return(nil, nil, nil) + uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) + uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) + uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { + close(doneCh) + }).Return(nil) + + <-doneCh + uni.service.Close() +} + +func TestFunctionsListener_HandleOracleRequestV1_ThresholdDecryptedSecrets(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + reqData := &struct { + SecretsLocation int `cbor:"secretsLocation"` + Secrets []byte `cbor:"secrets"` + }{ + SecretsLocation: 1, + Secrets: EncryptedSecretsUrls, + } + cborBytes, err := cbor.Marshal(reqData) + require.NoError(t, err) + // Remove first byte (map header) to make it "diet" CBOR + cborBytes = cborBytes[1:] + request := types.OracleRequest{ + RequestId: RequestID, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Flags: getFlags(1, 1), // tiers no 1 of request size and secrets size, allow up to 100 bytes + Data: cborBytes, + } + + uni := NewFunctionsListenerUniverse(t, 0, 1_000_000, true, 1) + require.NoError(t, uni.service.Start(testutils.Context(t))) + doneCh := make(chan struct{}) + + uni.logPollerWrapper.On("LatestEvents").Return([]types.OracleRequest{request}, nil, nil).Once() + uni.logPollerWrapper.On("LatestEvents").Return(nil, nil, nil) + uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) + uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) + uni.eaClient.On("FetchEncryptedSecrets", mock.Anything, mock.Anything, RequestIDStr, mock.Anything, mock.Anything).Return(EncryptedSecrets, nil, nil) + uni.decryptor.On("Decrypt", mock.Anything, []byte(RequestIDStr), EncryptedSecrets).Return(DecryptedSecrets, nil) + uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) + uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { + close(doneCh) + }).Return(nil) + + <-doneCh + uni.service.Close() +} + +func TestFunctionsListener_HandleOracleRequestV1_CBORTooBig(t *testing.T) { + testutils.SkipShortDB(t) + t.Parallel() + + uni := NewFunctionsListenerUniverse(t, 0, 1_000_000, true, 1) + require.NoError(t, uni.service.Start(testutils.Context(t))) + doneCh := make(chan struct{}) + + request := types.OracleRequest{ + RequestId: RequestID, + SubscriptionId: uint64(SubscriptionID), + SubscriptionOwner: SubscriptionOwner, + Flags: getFlags(0, 0), // tier no 0 of request size, allows only for max 10 bytes + Data: make([]byte, 20), + } + + uni.logPollerWrapper.On("LatestEvents").Return([]types.OracleRequest{request}, nil, nil).Once() + uni.logPollerWrapper.On("LatestEvents").Return(nil, nil, nil) + uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) + uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, []byte("request too big (max 10 bytes)"), mock.Anything, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { + close(doneCh) + }).Return(nil) + + <-doneCh + uni.service.Close() +} diff --git a/core/services/relay/evm/types/mocks/log_poller_wrapper.go b/core/services/relay/evm/types/mocks/log_poller_wrapper.go new file mode 100644 index 00000000000..a32df6500f3 --- /dev/null +++ b/core/services/relay/evm/types/mocks/log_poller_wrapper.go @@ -0,0 +1,142 @@ +// Code generated by mockery v2.28.1. DO NOT EDIT. + +package mocks + +import ( + context "context" + + types "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" + mock "github.com/stretchr/testify/mock" +) + +// LogPollerWrapper is an autogenerated mock type for the LogPollerWrapper type +type LogPollerWrapper struct { + mock.Mock +} + +// Close provides a mock function with given fields: +func (_m *LogPollerWrapper) Close() error { + ret := _m.Called() + + var r0 error + if rf, ok := ret.Get(0).(func() error); ok { + r0 = rf() + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// HealthReport provides a mock function with given fields: +func (_m *LogPollerWrapper) HealthReport() map[string]error { + ret := _m.Called() + + var r0 map[string]error + if rf, ok := ret.Get(0).(func() map[string]error); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(map[string]error) + } + } + + return r0 +} + +// LatestEvents provides a mock function with given fields: +func (_m *LogPollerWrapper) LatestEvents() ([]types.OracleRequest, []types.OracleResponse, error) { + ret := _m.Called() + + var r0 []types.OracleRequest + var r1 []types.OracleResponse + var r2 error + if rf, ok := ret.Get(0).(func() ([]types.OracleRequest, []types.OracleResponse, error)); ok { + return rf() + } + if rf, ok := ret.Get(0).(func() []types.OracleRequest); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]types.OracleRequest) + } + } + + if rf, ok := ret.Get(1).(func() []types.OracleResponse); ok { + r1 = rf() + } else { + if ret.Get(1) != nil { + r1 = ret.Get(1).([]types.OracleResponse) + } + } + + if rf, ok := ret.Get(2).(func() error); ok { + r2 = rf() + } else { + r2 = ret.Error(2) + } + + return r0, r1, r2 +} + +// Name provides a mock function with given fields: +func (_m *LogPollerWrapper) Name() string { + ret := _m.Called() + + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// Ready provides a mock function with given fields: +func (_m *LogPollerWrapper) Ready() error { + ret := _m.Called() + + var r0 error + if rf, ok := ret.Get(0).(func() error); ok { + r0 = rf() + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// Start provides a mock function with given fields: _a0 +func (_m *LogPollerWrapper) Start(_a0 context.Context) error { + ret := _m.Called(_a0) + + var r0 error + if rf, ok := ret.Get(0).(func(context.Context) error); ok { + r0 = rf(_a0) + } else { + r0 = ret.Error(0) + } + + return r0 +} + +// SubscribeToUpdates provides a mock function with given fields: name, subscriber +func (_m *LogPollerWrapper) SubscribeToUpdates(name string, subscriber types.RouteUpdateSubscriber) { + _m.Called(name, subscriber) +} + +type mockConstructorTestingTNewLogPollerWrapper interface { + mock.TestingT + Cleanup(func()) +} + +// NewLogPollerWrapper creates a new instance of LogPollerWrapper. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +func NewLogPollerWrapper(t mockConstructorTestingTNewLogPollerWrapper) *LogPollerWrapper { + mock := &LogPollerWrapper{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index 81651ca5688..7a2c274f5aa 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -65,6 +65,8 @@ type RouteUpdateSubscriber interface { } // A LogPoller wrapper that understands router proxy contracts +// +//go:generate mockery --quiet --name LogPollerWrapper --output ./mocks/ --case=underscore type LogPollerWrapper interface { relaytypes.Service LatestEvents() ([]OracleRequest, []OracleResponse, error) From 78d61135bb0cdddfa30e7e7e619053f4ab1566ed Mon Sep 17 00:00:00 2001 From: Chia Yong Kang Date: Tue, 8 Aug 2023 06:53:22 -0700 Subject: [PATCH 111/270] [BCI-1616] Generalised fixed fee static gas estimator (#10003) * generalised fee methods * updated config * Added config * Finished initial generalisation * cleanup of wrapper config * Removed wrapped bump config * improved naming for function * added changes for test due to WrappedFixedGasEstimatorConfig change * test fixes * fixed test * refactored folders * refactored 'gas' to 'fee' * refactored function names for private visibility * test fixes * fixed test due to error logs * Added Chain agnostic labels * cleanup * Cleanup indentation Co-authored-by: Jordan Krage * reformat bump fee by percentage Co-authored-by: Jordan Krage * refactored using bumpFeePriceByPercentage * removed getMaxFeePrice * Removed config from GetLegacyGas * removed generic dynamic, removed generalised wrapper config * removed config * removed config gas file for evm * small cleanup * Test fixes * fixed test * FeeUnitToChainUnit from string to func type * decoupled chainSpecificGasLimit from GetFee functions * cleanup func names * test fixes * removed redundant util functions * Added Comments for clarity * cleanup, simpified CalculateFee * added TODO comment * slight refactor * small cosmetic input change to match original input * added fixes * fixes * used only 1 enum for errors * updated labels from gas to fee * added error handling for integer overflow * changed error formatting type * changed error formatting type * Naming change for FormatWei * fixed test --------- Co-authored-by: Jordan Krage --- common/chains/label/label.go | 8 ++ common/fee/models.go | 85 +++++++++++++++++++ common/fee/utils.go | 28 +++--- common/txmgr/confirmer.go | 6 +- core/assets/wei.go | 5 ++ .../chains/evm/gas/block_history_estimator.go | 16 ++-- .../evm/gas/block_history_estimator_test.go | 17 ++-- core/chains/evm/gas/fixed_price_estimator.go | 83 ++++++++++++++---- core/chains/evm/gas/models.go | 46 +++------- core/chains/evm/txmgr/broadcaster_test.go | 2 +- core/chains/evm/txmgr/confirmer_test.go | 5 +- 11 files changed, 222 insertions(+), 79 deletions(-) create mode 100644 common/chains/label/label.go create mode 100644 common/fee/models.go diff --git a/common/chains/label/label.go b/common/chains/label/label.go new file mode 100644 index 00000000000..2498fde0ee9 --- /dev/null +++ b/common/chains/label/label.go @@ -0,0 +1,8 @@ +package label + +const ( + MaxInFlightTransactionsWarning = `WARNING: If this happens a lot, you may need to increase Transactions.MaxInFlight to boost your node's transaction throughput, however you do this at your own risk. You MUST first ensure your node is configured not to ever evict local transactions that exceed this number otherwise the node can get permanently stuck. See the performance guide for more details: https://docs.chain.link/docs/evm-performance-configuration/` + MaxQueuedTransactionsWarning = `WARNING: Hitting Transactions.MaxQueued is a sanity limit and should never happen under normal operation. Unless you are operating with very high throughput, this error is unlikely to be a problem with your Chainlink node configuration, and instead more likely to be caused by a problem with your node's connectivity. Check your node: it may not be broadcasting transactions to the network, or it might be overloaded and evicting Chainlink's transactions from its mempool. It is recommended to run Chainlink with multiple primary and sendonly nodes for redundancy and to ensure fast and reliable transaction propagation. Increasing Transactions.MaxQueued will allow Chainlink to buffer more unsent transactions, but you should only do this if you need very high burst transmission rates. If you don't need very high burst throughput, increasing this limit is not the correct action to take here and will probably make things worse. See the performance guide for more details: https://docs.chain.link/docs/evm-performance-configuration/` + NodeConnectivityProblemWarning = `WARNING: If this happens a lot, it may be a sign that your node has a connectivity problem, and your transactions are not making it to any miners. It is recommended to run Chainlink with multiple primary and sendonly nodes for redundancy and to ensure fast and reliable transaction propagation. See the performance guide for more details: https://docs.chain.link/docs/evm-performance-configuration/` + RPCTxFeeCapConfiguredIncorrectlyWarning = `WARNING: Gas price was rejected by the node for being too high. By default, go-ethereum (and clones) have a built-in upper limit for gas price. It is preferable to disable this and rely Chainlink's internal gas limits instead. Your RPC node's RPCTxFeeCap needs to be disabled or increased (recommended configuration: --rpc.gascap=0 --rpc.txfeecap=0). If you want to limit Chainlink's max gas price, you may do so by setting GasEstimator.PriceMax on the Chainlink node. Chainlink will never send a transaction with a total cost higher than GasEstimator.PriceMax. See the performance guide for more details: https://docs.chain.link/docs/evm-performance-configuration/` +) diff --git a/common/fee/models.go b/common/fee/models.go new file mode 100644 index 00000000000..f980c73fc1b --- /dev/null +++ b/common/fee/models.go @@ -0,0 +1,85 @@ +package fee + +import ( + "math/big" + + "github.com/pkg/errors" + + "github.com/smartcontractkit/chainlink/v2/common/chains/label" + "github.com/smartcontractkit/chainlink/v2/core/logger" + bigmath "github.com/smartcontractkit/chainlink/v2/core/utils/big_math" +) + +var ( + ErrBumpFeeExceedsLimit = errors.New("fee bump exceeds limit") + ErrBump = errors.New("fee bump failed") + ErrConnectivity = errors.New("transaction propagation issue: transactions are not being mined") +) + +func IsBumpErr(err error) bool { + return err != nil && (errors.Is(err, ErrBumpFeeExceedsLimit) || errors.Is(err, ErrBump) || errors.Is(err, ErrConnectivity)) +} + +// CalculateFee computes the fee price for a transaction. +// The fee price is the minimum of: +// - max fee price specified, default fee price and max fee price for the node. +func CalculateFee( + maxFeePrice, defaultPrice, maxFeePriceConfigured *big.Int, +) *big.Int { + maxFeePriceAllowed := bigmath.Min(maxFeePrice, maxFeePriceConfigured) + return bigmath.Min(defaultPrice, maxFeePriceAllowed) +} + +// CalculateBumpedFee computes the next fee price to attempt as the largest of: +// - A configured percentage bump (bumpPercent) on top of the baseline price. +// - A configured fixed amount of Unit (bumpMin) on top of the baseline price. +// The baseline price is the maximum of the previous fee price attempt and the node's current fee price. +func CalculateBumpedFee( + lggr logger.SugaredLogger, + currentfeePrice, originalfeePrice, maxFeePriceInput, maxBumpPrice, bumpMin *big.Int, + bumpPercent uint16, + toChainUnit feeUnitToChainUnit, +) (*big.Int, error) { + maxFeePrice := bigmath.Min(maxFeePriceInput, maxBumpPrice) + bumpedFeePrice := maxBumpedFee(originalfeePrice, bumpPercent, bumpMin) + + // Update bumpedFeePrice if currentfeePrice is higher than bumpedFeePrice and within maxFeePrice + bumpedFeePrice = maxFee(lggr, currentfeePrice, bumpedFeePrice, maxFeePrice, "fee price", toChainUnit) + + if bumpedFeePrice.Cmp(maxFeePrice) > 0 { + return maxFeePrice, errors.Wrapf(ErrBumpFeeExceedsLimit, "bumped fee price of %s would exceed configured max fee price of %s (original price was %s). %s", + toChainUnit(bumpedFeePrice), toChainUnit(maxFeePrice), toChainUnit(originalfeePrice), label.NodeConnectivityProblemWarning) + } else if bumpedFeePrice.Cmp(originalfeePrice) == 0 { + // NOTE: This really shouldn't happen since we enforce minimums for + // FeeEstimator.BumpPercent and FeeEstimator.BumpMin in the config validation, + // but it's here anyway for a "belts and braces" approach + return bumpedFeePrice, errors.Wrapf(ErrBump, "bumped fee price of %s is equal to original fee price of %s."+ + " ACTION REQUIRED: This is a configuration error, you must increase either "+ + "FeeEstimator.BumpPercent or FeeEstimator.BumpMin", toChainUnit(bumpedFeePrice), toChainUnit(bumpedFeePrice)) + } + return bumpedFeePrice, nil +} + +// Returns highest bumped fee price of originalFeePrice bumped by fixed units or percentage. +func maxBumpedFee(originalFeePrice *big.Int, feeBumpPercent uint16, feeBumpUnits *big.Int) *big.Int { + return bigmath.Max( + addPercentage(originalFeePrice, feeBumpPercent), + new(big.Int).Add(originalFeePrice, feeBumpUnits), + ) +} + +// Returns the max of currentFeePrice, bumpedFeePrice, and maxFeePrice +func maxFee(lggr logger.SugaredLogger, currentFeePrice, bumpedFeePrice, maxFeePrice *big.Int, feeType string, toChainUnit feeUnitToChainUnit) *big.Int { + if currentFeePrice == nil { + return bumpedFeePrice + } + if currentFeePrice.Cmp(maxFeePrice) > 0 { + // Shouldn't happen because the estimator should not be allowed to + // estimate a higher fee than the maximum allowed + lggr.AssumptionViolationf("Ignoring current %s of %s that would exceed max %s of %s", feeType, toChainUnit(currentFeePrice), feeType, toChainUnit(maxFeePrice)) + } else if bumpedFeePrice.Cmp(currentFeePrice) < 0 { + // If the current fee price is higher than the old price bumped, use that instead + return currentFeePrice + } + return bumpedFeePrice +} diff --git a/common/fee/utils.go b/common/fee/utils.go index 838ee23daa9..71ababddbe3 100644 --- a/common/fee/utils.go +++ b/common/fee/utils.go @@ -1,23 +1,29 @@ package fee import ( + "math" "math/big" - bigmath "github.com/smartcontractkit/chainlink/v2/core/utils/big_math" - + "github.com/pkg/errors" "github.com/shopspring/decimal" ) -func GetMaxFeePrice(userSpecifiedMax, maxFee *big.Int) *big.Int { - return bigmath.Min(userSpecifiedMax, maxFee) -} +func ApplyMultiplier(feeLimit uint32, multiplier float32) (uint32, error) { + result := decimal.NewFromBigInt(big.NewInt(0).SetUint64(uint64(feeLimit)), 0).Mul(decimal.NewFromFloat32(multiplier)).IntPart() -func CapFeePrice(calculatedFeePrice, userSpecifiedMax, maxFeePriceWei *big.Int, feeLimit uint32, multiplier float32) (maxFeePrice *big.Int, chainSpecificFeeLimit uint32) { - chainSpecificFeeLimit = ApplyMultiplier(feeLimit, multiplier) - maxFeePrice = GetMaxFeePrice(userSpecifiedMax, maxFeePriceWei) - return bigmath.Min(calculatedFeePrice, maxFeePrice), chainSpecificFeeLimit + if result > math.MaxUint32 { + return 0, errors.Errorf("integer overflow when applying multiplier of %f to fee limit of %d", multiplier, feeLimit) + } + return uint32(result), nil } -func ApplyMultiplier(feeLimit uint32, multiplier float32) uint32 { - return uint32(decimal.NewFromBigInt(big.NewInt(0).SetUint64(uint64(feeLimit)), 0).Mul(decimal.NewFromFloat32(multiplier)).IntPart()) +// Returns the input value increased by the given percentage. +func addPercentage(value *big.Int, percentage uint16) *big.Int { + bumped := new(big.Int) + bumped.Mul(value, big.NewInt(int64(100+percentage))) + bumped.Div(bumped, big.NewInt(100)) + return bumped } + +// Returns the fee in its chain specific unit. +type feeUnitToChainUnit func(fee *big.Int) string diff --git a/common/txmgr/confirmer.go b/common/txmgr/confirmer.go index 4d3fd2fdc37..07ed2d29f02 100644 --- a/common/txmgr/confirmer.go +++ b/common/txmgr/confirmer.go @@ -15,10 +15,10 @@ import ( "go.uber.org/multierr" clienttypes "github.com/smartcontractkit/chainlink/v2/common/chains/client" + commonfee "github.com/smartcontractkit/chainlink/v2/common/fee" feetypes "github.com/smartcontractkit/chainlink/v2/common/fee/types" txmgrtypes "github.com/smartcontractkit/chainlink/v2/common/txmgr/types" "github.com/smartcontractkit/chainlink/v2/common/types" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/label" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" @@ -758,7 +758,7 @@ func (ec *Confirmer[CHAIN_ID, HEAD, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) att } attempt, err = ec.bumpGas(ctx, etx, etx.TxAttempts) - if gas.IsBumpErr(err) { + if commonfee.IsBumpErr(err) { lggr.Errorw("Failed to bump gas", append(logFields, "err", err)...) // Do not create a new attempt if bumping gas would put us over the limit or cause some other problem // Instead try to resubmit the previous attempt, and keep resubmitting until its accepted @@ -801,7 +801,7 @@ func (ec *Confirmer[CHAIN_ID, HEAD, ADDR, TX_HASH, BLOCK_HASH, R, SEQ, FEE]) bum return bumpedAttempt, err } - if errors.Is(errors.Cause(err), gas.ErrBumpGasExceedsLimit) { + if errors.Is(errors.Cause(err), commonfee.ErrBumpFeeExceedsLimit) { promGasBumpExceedsLimit.WithLabelValues(ec.chainID.String()).Inc() } diff --git a/core/assets/wei.go b/core/assets/wei.go index f88fb60e618..7d1240d384c 100644 --- a/core/assets/wei.go +++ b/core/assets/wei.go @@ -76,6 +76,11 @@ func NewWeiI[T constraints.Signed](i T) *Wei { return NewWei(big.NewInt(int64(i))) } +// Returns input big.Int in Wei string format. +func FormatWei(i *big.Int) string { + return NewWei(i).String() +} + func (w *Wei) Text(suffix string) string { switch suffix { default: // empty or unknown diff --git a/core/chains/evm/gas/block_history_estimator.go b/core/chains/evm/gas/block_history_estimator.go index 205c208e702..556c0b1715c 100644 --- a/core/chains/evm/gas/block_history_estimator.go +++ b/core/chains/evm/gas/block_history_estimator.go @@ -261,7 +261,8 @@ func (b *BlockHistoryEstimator) GetLegacyGas(_ context.Context, _ []byte, gasLim "Using Evm.GasEstimator.PriceDefault as fallback.", "blocks", b.getBlockHistoryNumbers()) gasPrice = b.eConfig.PriceDefault() } - gasPrice, chainSpecificGasLimit = capGasPrice(gasPrice, maxGasPriceWei, b.eConfig.PriceMax(), gasLimit, b.eConfig.LimitMultiplier()) + gasPrice = capGasPrice(gasPrice, maxGasPriceWei, b.eConfig.PriceMax()) + chainSpecificGasLimit, err = commonfee.ApplyMultiplier(gasLimit, b.eConfig.LimitMultiplier()) return } @@ -287,7 +288,7 @@ func (b *BlockHistoryEstimator) getTipCap() *assets.Wei { func (b *BlockHistoryEstimator) BumpLegacyGas(_ context.Context, originalGasPrice *assets.Wei, gasLimit uint32, maxGasPriceWei *assets.Wei, attempts []EvmPriorAttempt) (bumpedGasPrice *assets.Wei, chainSpecificGasLimit uint32, err error) { if b.bhConfig.CheckInclusionBlocks() > 0 { if err = b.checkConnectivity(attempts); err != nil { - if errors.Is(err, ErrConnectivity) { + if errors.Is(err, commonfee.ErrConnectivity) { b.logger.Criticalw(BumpingHaltedLabel, "err", err) b.SvcErrBuffer.Append(err) promBlockHistoryEstimatorConnectivityFailureCount.WithLabelValues(b.chainID.String(), "legacy").Inc() @@ -375,11 +376,11 @@ func (b *BlockHistoryEstimator) checkConnectivity(attempts []EvmPriorAttempt) er } } if sufficientFeeCap && attempt.DynamicFee.TipCap.Cmp(tipCap) > 0 { - return errors.Wrapf(ErrConnectivity, "transaction %s has tip cap of %s, which is above percentile=%d%% (percentile tip cap: %s) for blocks %d thru %d (checking %d blocks)", attempt.TxHash, attempt.DynamicFee.TipCap, percentile, tipCap, blockHistory[l-1].Number, blockHistory[0].Number, expectInclusionWithinBlocks) + return errors.Wrapf(commonfee.ErrConnectivity, "transaction %s has tip cap of %s, which is above percentile=%d%% (percentile tip cap: %s) for blocks %d thru %d (checking %d blocks)", attempt.TxHash, attempt.DynamicFee.TipCap, percentile, tipCap, blockHistory[l-1].Number, blockHistory[0].Number, expectInclusionWithinBlocks) } } else { if attempt.GasPrice.Cmp(gasPrice) > 0 { - return errors.Wrapf(ErrConnectivity, "transaction %s has gas price of %s, which is above percentile=%d%% (percentile price: %s) for blocks %d thru %d (checking %d blocks)", attempt.TxHash, attempt.GasPrice, percentile, gasPrice, blockHistory[l-1].Number, blockHistory[0].Number, expectInclusionWithinBlocks) + return errors.Wrapf(commonfee.ErrConnectivity, "transaction %s has gas price of %s, which is above percentile=%d%% (percentile price: %s) for blocks %d thru %d (checking %d blocks)", attempt.TxHash, attempt.GasPrice, percentile, gasPrice, blockHistory[l-1].Number, blockHistory[0].Number, expectInclusionWithinBlocks) } } @@ -395,7 +396,10 @@ func (b *BlockHistoryEstimator) GetDynamicFee(_ context.Context, gasLimit uint32 var feeCap *assets.Wei var tipCap *assets.Wei ok := b.IfStarted(func() { - chainSpecificGasLimit = commonfee.ApplyMultiplier(gasLimit, b.eConfig.LimitMultiplier()) + chainSpecificGasLimit, err = commonfee.ApplyMultiplier(gasLimit, b.eConfig.LimitMultiplier()) + if err != nil { + return + } b.priceMu.RLock() defer b.priceMu.RUnlock() tipCap = b.tipCap @@ -460,7 +464,7 @@ func calcFeeCap(latestAvailableBaseFeePerGas *assets.Wei, bufferBlocks int, tipC func (b *BlockHistoryEstimator) BumpDynamicFee(_ context.Context, originalFee DynamicFee, originalGasLimit uint32, maxGasPriceWei *assets.Wei, attempts []EvmPriorAttempt) (bumped DynamicFee, chainSpecificGasLimit uint32, err error) { if b.bhConfig.CheckInclusionBlocks() > 0 { if err = b.checkConnectivity(attempts); err != nil { - if errors.Is(err, ErrConnectivity) { + if errors.Is(err, commonfee.ErrConnectivity) { b.logger.Criticalw(BumpingHaltedLabel, "err", err) b.SvcErrBuffer.Append(err) promBlockHistoryEstimatorConnectivityFailureCount.WithLabelValues(b.chainID.String(), "eip1559").Inc() diff --git a/core/chains/evm/gas/block_history_estimator_test.go b/core/chains/evm/gas/block_history_estimator_test.go index 47d9cfa83ea..3e7d201f7ec 100644 --- a/core/chains/evm/gas/block_history_estimator_test.go +++ b/core/chains/evm/gas/block_history_estimator_test.go @@ -18,6 +18,7 @@ import ( "github.com/stretchr/testify/require" "go.uber.org/zap/zapcore" + commonfee "github.com/smartcontractkit/chainlink/v2/common/fee" "github.com/smartcontractkit/chainlink/v2/core/assets" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" @@ -2154,7 +2155,7 @@ func TestBlockHistoryEstimator_CheckConnectivity(t *testing.T) { err := bhe.CheckConnectivity(attempts) require.Error(t, err) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has gas price of 7 wei, which is above percentile=40%% (percentile price: 5 wei) for blocks 2 thru 0 (checking 3 blocks)", attempts[3].TxHash)) - require.ErrorIs(t, err, gas.ErrConnectivity) + require.ErrorIs(t, err, commonfee.ErrConnectivity) }) t.Run("fails check if one or more blocks has percentile price higher than any transaction gas price", func(t *testing.T) { @@ -2171,7 +2172,7 @@ func TestBlockHistoryEstimator_CheckConnectivity(t *testing.T) { err = bhe.CheckConnectivity(attempts) require.Error(t, err) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has gas price of 3 wei, which is above percentile=5%% (percentile price: 2 wei) for blocks 2 thru 0 (checking 3 blocks)", attempts[1].TxHash)) - require.ErrorIs(t, err, gas.ErrConnectivity) + require.ErrorIs(t, err, commonfee.ErrConnectivity) }) }) @@ -2203,7 +2204,7 @@ func TestBlockHistoryEstimator_CheckConnectivity(t *testing.T) { err := bhe.CheckConnectivity(attempts) require.Error(t, err) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has gas price of 10 wei, which is above percentile=60%% (percentile price: 7 wei) for blocks 3 thru 3 (checking 1 blocks)", attempts[1].TxHash)) - require.ErrorIs(t, err, gas.ErrConnectivity) + require.ErrorIs(t, err, commonfee.ErrConnectivity) }) attempts = []gas.EvmPriorAttempt{ @@ -2219,7 +2220,7 @@ func TestBlockHistoryEstimator_CheckConnectivity(t *testing.T) { err := bhe.CheckConnectivity(attempts) require.Error(t, err) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has tip cap of 10 wei, which is above percentile=60%% (percentile tip cap: 6 wei) for blocks 3 thru 3 (checking 1 blocks)", attempts[0].TxHash)) - require.ErrorIs(t, err, gas.ErrConnectivity) + require.ErrorIs(t, err, commonfee.ErrConnectivity) }) }) @@ -2277,7 +2278,7 @@ func TestBlockHistoryEstimator_CheckConnectivity(t *testing.T) { err := bhe.CheckConnectivity(attempts) require.Error(t, err) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has tip cap of 5 wei, which is above percentile=20%% (percentile tip cap: 4 wei) for blocks 2 thru 0 (checking 3 blocks)", attempts[2].TxHash)) - require.ErrorIs(t, err, gas.ErrConnectivity) + require.ErrorIs(t, err, commonfee.ErrConnectivity) bhCfg.CheckInclusionBlocksF = 3 bhCfg.CheckInclusionPercentileF = 5 @@ -2285,7 +2286,7 @@ func TestBlockHistoryEstimator_CheckConnectivity(t *testing.T) { err = bhe.CheckConnectivity(attempts) require.Error(t, err) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has tip cap of 3 wei, which is above percentile=5%% (percentile tip cap: 2 wei) for blocks 2 thru 0 (checking 3 blocks)", attempts[1].TxHash)) - require.ErrorIs(t, err, gas.ErrConnectivity) + require.ErrorIs(t, err, commonfee.ErrConnectivity) }) t.Run("passes check if, for at least one block, feecap < tipcap+basefee, even if percentile is not reached", func(t *testing.T) { @@ -2335,7 +2336,7 @@ func TestBlockHistoryEstimator_Bumps(t *testing.T) { _, _, err := bhe.BumpLegacyGas(testutils.Context(t), assets.NewWeiI(42), 100000, maxGasPrice, attempts) require.Error(t, err) - assert.True(t, errors.Is(err, gas.ErrConnectivity)) + assert.True(t, errors.Is(err, commonfee.ErrConnectivity)) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has gas price of 1 kwei, which is above percentile=10%% (percentile price: 1 wei) for blocks 1 thru 1 (checking 1 blocks)", attempts[0].TxHash)) }) @@ -2448,7 +2449,7 @@ func TestBlockHistoryEstimator_Bumps(t *testing.T) { _, _, err := bhe.BumpDynamicFee(testutils.Context(t), originalFee, 100000, maxGasPrice, attempts) require.Error(t, err) - assert.True(t, errors.Is(err, gas.ErrConnectivity)) + assert.True(t, errors.Is(err, commonfee.ErrConnectivity)) assert.Contains(t, err.Error(), fmt.Sprintf("transaction %s has tip cap of 25 wei, which is above percentile=10%% (percentile tip cap: 1 wei) for blocks 1 thru 1 (checking 1 blocks)", attempts[0].TxHash)) }) diff --git a/core/chains/evm/gas/fixed_price_estimator.go b/core/chains/evm/gas/fixed_price_estimator.go index b96a2e8b8cd..733dd179fec 100644 --- a/core/chains/evm/gas/fixed_price_estimator.go +++ b/core/chains/evm/gas/fixed_price_estimator.go @@ -4,7 +4,6 @@ import ( "context" "github.com/pkg/errors" - commonfee "github.com/smartcontractkit/chainlink/v2/common/fee" feetypes "github.com/smartcontractkit/chainlink/v2/common/fee/types" "github.com/smartcontractkit/chainlink/v2/core/assets" @@ -19,6 +18,13 @@ type fixedPriceEstimator struct { bhConfig fixedPriceEstimatorBlockHistoryConfig lggr logger.SugaredLogger } +type bumpConfig interface { + LimitMultiplier() float32 + PriceMax() *assets.Wei + BumpPercent() uint16 + BumpMin() *assets.Wei + TipCapDefault() *assets.Wei +} type fixedPriceEstimatorConfig interface { BumpThreshold() uint64 @@ -50,20 +56,42 @@ func (f *fixedPriceEstimator) Start(context.Context) error { } return nil } -func (f *fixedPriceEstimator) Name() string { return f.lggr.Name() } -func (f *fixedPriceEstimator) Ready() error { return nil } -func (f *fixedPriceEstimator) HealthReport() map[string]error { return map[string]error{} } -func (f *fixedPriceEstimator) Close() error { return nil } -func (f *fixedPriceEstimator) OnNewLongestChain(_ context.Context, _ *evmtypes.Head) {} -func (f *fixedPriceEstimator) GetLegacyGas(_ context.Context, _ []byte, gasLimit uint32, maxGasPriceWei *assets.Wei, _ ...feetypes.Opt) (gasPrice *assets.Wei, chainSpecificGasLimit uint32, err error) { - gasPrice = f.config.PriceDefault() - gasPrice, chainSpecificGasLimit = capGasPrice(gasPrice, maxGasPriceWei, f.config.PriceMax(), gasLimit, f.config.LimitMultiplier()) - return +func (f *fixedPriceEstimator) GetLegacyGas(_ context.Context, _ []byte, gasLimit uint32, maxGasPriceWei *assets.Wei, _ ...feetypes.Opt) (*assets.Wei, uint32, error) { + gasPrice := commonfee.CalculateFee(f.config.PriceDefault().ToInt(), maxGasPriceWei.ToInt(), f.config.PriceMax().ToInt()) + chainSpecificGasLimit, err := commonfee.ApplyMultiplier(gasLimit, f.config.LimitMultiplier()) + if err != nil { + return nil, 0, err + } + return assets.NewWei(gasPrice), chainSpecificGasLimit, nil } -func (f *fixedPriceEstimator) BumpLegacyGas(_ context.Context, originalGasPrice *assets.Wei, originalGasLimit uint32, maxGasPriceWei *assets.Wei, _ []EvmPriorAttempt) (gasPrice *assets.Wei, gasLimit uint32, err error) { - return BumpLegacyGasPriceOnly(f.config, f.lggr, f.config.PriceDefault(), originalGasPrice, originalGasLimit, maxGasPriceWei) +func (f *fixedPriceEstimator) BumpLegacyGas( + _ context.Context, + originalGasPrice *assets.Wei, + originalGasLimit uint32, + maxGasPriceWei *assets.Wei, + _ []EvmPriorAttempt, +) (*assets.Wei, uint32, error) { + gasPrice, err := commonfee.CalculateBumpedFee( + f.lggr, + f.config.PriceDefault().ToInt(), + originalGasPrice.ToInt(), + maxGasPriceWei.ToInt(), + f.config.PriceMax().ToInt(), + f.config.BumpMin().ToInt(), + f.config.BumpPercent(), + assets.FormatWei, + ) + if err != nil { + return nil, 0, err + } + + chainSpecificGasLimit, err := commonfee.ApplyMultiplier(originalGasLimit, f.config.LimitMultiplier()) + if err != nil { + return nil, 0, err + } + return assets.NewWei(gasPrice), chainSpecificGasLimit, err } func (f *fixedPriceEstimator) GetDynamicFee(_ context.Context, originalGasLimit uint32, maxGasPriceWei *assets.Wei) (d DynamicFee, chainSpecificGasLimit uint32, err error) { @@ -72,7 +100,10 @@ func (f *fixedPriceEstimator) GetDynamicFee(_ context.Context, originalGasLimit if gasTipCap == nil { return d, 0, errors.New("cannot calculate dynamic fee: EthGasTipCapDefault was not set") } - chainSpecificGasLimit = commonfee.ApplyMultiplier(originalGasLimit, f.config.LimitMultiplier()) + chainSpecificGasLimit, err = commonfee.ApplyMultiplier(originalGasLimit, f.config.LimitMultiplier()) + if err != nil { + return d, 0, err + } var feeCap *assets.Wei if f.config.BumpThreshold() == 0 { @@ -89,6 +120,28 @@ func (f *fixedPriceEstimator) GetDynamicFee(_ context.Context, originalGasLimit }, chainSpecificGasLimit, nil } -func (f *fixedPriceEstimator) BumpDynamicFee(_ context.Context, originalFee DynamicFee, originalGasLimit uint32, maxGasPriceWei *assets.Wei, _ []EvmPriorAttempt) (bumped DynamicFee, chainSpecificGasLimit uint32, err error) { - return BumpDynamicFeeOnly(f.config, f.bhConfig.EIP1559FeeCapBufferBlocks(), f.lggr, f.config.TipCapDefault(), nil, originalFee, originalGasLimit, maxGasPriceWei) +func (f *fixedPriceEstimator) BumpDynamicFee( + _ context.Context, + originalFee DynamicFee, + originalGasLimit uint32, + maxGasPriceWei *assets.Wei, + _ []EvmPriorAttempt, +) (bumped DynamicFee, chainSpecificGasLimit uint32, err error) { + + return BumpDynamicFeeOnly( + f.config, + f.bhConfig.EIP1559FeeCapBufferBlocks(), + f.lggr, + f.config.TipCapDefault(), + nil, + originalFee, + originalGasLimit, + maxGasPriceWei, + ) } + +func (f *fixedPriceEstimator) Name() string { return f.lggr.Name() } +func (f *fixedPriceEstimator) Ready() error { return nil } +func (f *fixedPriceEstimator) HealthReport() map[string]error { return map[string]error{} } +func (f *fixedPriceEstimator) Close() error { return nil } +func (f *fixedPriceEstimator) OnNewLongestChain(_ context.Context, _ *evmtypes.Head) {} diff --git a/core/chains/evm/gas/models.go b/core/chains/evm/gas/models.go index 7c0571c897d..5e9378812c1 100644 --- a/core/chains/evm/gas/models.go +++ b/core/chains/evm/gas/models.go @@ -20,18 +20,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/config" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services" + bigmath "github.com/smartcontractkit/chainlink/v2/core/utils/big_math" ) -var ( - ErrBumpGasExceedsLimit = errors.New("gas bump exceeds limit") - ErrBump = errors.New("gas bump failed") - ErrConnectivity = errors.New("transaction propagation issue: transactions are not being mined") -) - -func IsBumpErr(err error) bool { - return err != nil && (errors.Is(err, ErrBumpGasExceedsLimit) || errors.Is(err, ErrBump) || errors.Is(err, ErrConnectivity)) -} - // EvmFeeEstimator provides a unified interface that wraps EvmEstimator and can determine if legacy or dynamic fee estimation should be used // //go:generate mockery --quiet --name EvmFeeEstimator --output ./mocks/ --case=underscore @@ -254,21 +245,13 @@ func HexToInt64(input interface{}) int64 { } } -type bumpConfig interface { - LimitMultiplier() float32 - PriceMax() *assets.Wei - BumpPercent() uint16 - BumpMin() *assets.Wei - TipCapDefault() *assets.Wei -} - // BumpLegacyGasPriceOnly will increase the price and apply multiplier to the gas limit func BumpLegacyGasPriceOnly(cfg bumpConfig, lggr logger.SugaredLogger, currentGasPrice, originalGasPrice *assets.Wei, originalGasLimit uint32, maxGasPriceWei *assets.Wei) (gasPrice *assets.Wei, chainSpecificGasLimit uint32, err error) { gasPrice, err = bumpGasPrice(cfg, lggr, currentGasPrice, originalGasPrice, maxGasPriceWei) if err != nil { return nil, 0, err } - chainSpecificGasLimit = commonfee.ApplyMultiplier(originalGasLimit, cfg.LimitMultiplier()) + chainSpecificGasLimit, err = commonfee.ApplyMultiplier(originalGasLimit, cfg.LimitMultiplier()) return } @@ -284,13 +267,13 @@ func bumpGasPrice(cfg bumpConfig, lggr logger.SugaredLogger, currentGasPrice, or bumpedGasPrice = maxBumpedFee(lggr, currentGasPrice, bumpedGasPrice, maxGasPrice, "gas price") if bumpedGasPrice.Cmp(maxGasPrice) > 0 { - return maxGasPrice, errors.Wrapf(ErrBumpGasExceedsLimit, "bumped gas price of %s would exceed configured max gas price of %s (original price was %s). %s", + return maxGasPrice, errors.Wrapf(commonfee.ErrBumpFeeExceedsLimit, "bumped gas price of %s would exceed configured max gas price of %s (original price was %s). %s", bumpedGasPrice.String(), maxGasPrice, originalGasPrice.String(), label.NodeConnectivityProblemWarning) } else if bumpedGasPrice.Cmp(originalGasPrice) == 0 { // NOTE: This really shouldn't happen since we enforce minimums for // EVM.GasEstimator.BumpPercent and EVM.GasEstimator.BumpMin in the config validation, // but it's here anyway for a "belts and braces" approach - return bumpedGasPrice, errors.Wrapf(ErrBump, "bumped gas price of %s is equal to original gas price of %s."+ + return bumpedGasPrice, errors.Wrapf(commonfee.ErrBump, "bumped gas price of %s is equal to original gas price of %s."+ " ACTION REQUIRED: This is a configuration error, you must increase either "+ "EVM.GasEstimator.BumpPercent or EVM.GasEstimator.BumpMin", bumpedGasPrice.String(), originalGasPrice.String()) } @@ -303,7 +286,7 @@ func BumpDynamicFeeOnly(config bumpConfig, feeCapBufferBlocks uint16, lggr logge if err != nil { return bumped, 0, err } - chainSpecificGasLimit = commonfee.ApplyMultiplier(originalGasLimit, config.LimitMultiplier()) + chainSpecificGasLimit, err = commonfee.ApplyMultiplier(originalGasLimit, config.LimitMultiplier()) return } @@ -326,13 +309,13 @@ func bumpDynamicFee(cfg bumpConfig, feeCapBufferBlocks uint16, lggr logger.Sugar bumpedTipCap = maxBumpedFee(lggr, currentTipCap, bumpedTipCap, maxGasPrice, "tip cap") if bumpedTipCap.Cmp(maxGasPrice) > 0 { - return bumpedFee, errors.Wrapf(ErrBumpGasExceedsLimit, "bumped tip cap of %s would exceed configured max gas price of %s (original fee: tip cap %s, fee cap %s). %s", + return bumpedFee, errors.Wrapf(commonfee.ErrBumpFeeExceedsLimit, "bumped tip cap of %s would exceed configured max gas price of %s (original fee: tip cap %s, fee cap %s). %s", bumpedTipCap.String(), maxGasPrice, originalFee.TipCap.String(), originalFee.FeeCap.String(), label.NodeConnectivityProblemWarning) } else if bumpedTipCap.Cmp(originalFee.TipCap) <= 0 { // NOTE: This really shouldn't happen since we enforce minimums for // EVM.GasEstimator.BumpPercent and EVM.GasEstimator.BumpMin in the config validation, // but it's here anyway for a "belts and braces" approach - return bumpedFee, errors.Wrapf(ErrBump, "bumped gas tip cap of %s is less than or equal to original gas tip cap of %s."+ + return bumpedFee, errors.Wrapf(commonfee.ErrBump, "bumped gas tip cap of %s is less than or equal to original gas tip cap of %s."+ " ACTION REQUIRED: This is a configuration error, you must increase either "+ "EVM.GasEstimator.BumpPercent or EVM.GasEstimator.BumpMin", bumpedTipCap.String(), originalFee.TipCap.String()) } @@ -340,10 +323,7 @@ func bumpDynamicFee(cfg bumpConfig, feeCapBufferBlocks uint16, lggr logger.Sugar // Always bump the FeeCap by at least the bump percentage (should be greater than or // equal to than geth's configured bump minimum which is 10%) // See: https://github.com/ethereum/go-ethereum/blob/bff330335b94af3643ac2fb809793f77de3069d4/core/tx_list.go#L298 - bumpedFeeCap := assets.MaxWei( - originalFee.FeeCap.AddPercentage(cfg.BumpPercent()), - originalFee.FeeCap.Add(cfg.BumpMin()), - ) + bumpedFeeCap := bumpFeePrice(originalFee.FeeCap, cfg.BumpPercent(), cfg.BumpMin()) if currentBaseFee != nil { if currentBaseFee.Cmp(maxGasPrice) > 0 { @@ -355,7 +335,7 @@ func bumpDynamicFee(cfg bumpConfig, feeCapBufferBlocks uint16, lggr logger.Sugar } if bumpedFeeCap.Cmp(maxGasPrice) > 0 { - return bumpedFee, errors.Wrapf(ErrBumpGasExceedsLimit, "bumped fee cap of %s would exceed configured max gas price of %s (original fee: tip cap %s, fee cap %s). %s", + return bumpedFee, errors.Wrapf(commonfee.ErrBumpFeeExceedsLimit, "bumped fee cap of %s would exceed configured max gas price of %s (original fee: tip cap %s, fee cap %s). %s", bumpedFeeCap.String(), maxGasPrice, originalFee.TipCap.String(), originalFee.FeeCap.String(), label.NodeConnectivityProblemWarning) } @@ -385,10 +365,10 @@ func maxBumpedFee(lggr logger.SugaredLogger, currentFeePrice, bumpedFeePrice, ma } func getMaxGasPrice(userSpecifiedMax, maxGasPriceWei *assets.Wei) *assets.Wei { - return assets.NewWei(commonfee.GetMaxFeePrice(userSpecifiedMax.ToInt(), maxGasPriceWei.ToInt())) + return assets.NewWei(bigmath.Min(userSpecifiedMax.ToInt(), maxGasPriceWei.ToInt())) } -func capGasPrice(calculatedGasPrice, userSpecifiedMax, maxGasPriceWei *assets.Wei, gasLimit uint32, multiplier float32) (*assets.Wei, uint32) { - maxGasPrice, chainSpecificGasLimit := commonfee.CapFeePrice(calculatedGasPrice.ToInt(), userSpecifiedMax.ToInt(), maxGasPriceWei.ToInt(), gasLimit, multiplier) - return assets.NewWei(maxGasPrice), chainSpecificGasLimit +func capGasPrice(calculatedGasPrice, userSpecifiedMax, maxGasPriceWei *assets.Wei) *assets.Wei { + maxGasPrice := commonfee.CalculateFee(calculatedGasPrice.ToInt(), userSpecifiedMax.ToInt(), maxGasPriceWei.ToInt()) + return assets.NewWei(maxGasPrice) } diff --git a/core/chains/evm/txmgr/broadcaster_test.go b/core/chains/evm/txmgr/broadcaster_test.go index b36d2e486e0..6d16a697bbd 100644 --- a/core/chains/evm/txmgr/broadcaster_test.go +++ b/core/chains/evm/txmgr/broadcaster_test.go @@ -1486,7 +1486,7 @@ func TestEthBroadcaster_ProcessUnstartedEthTxs_Errors(t *testing.T) { // Do the thing retryable, err := eb2.ProcessUnstartedTxs(testutils.Context(t), fromAddress) require.Error(t, err) - require.Contains(t, err.Error(), "bumped gas price of 20 gwei is equal to original gas price of 20 gwei. ACTION REQUIRED: This is a configuration error, you must increase either EVM.GasEstimator.BumpPercent or EVM.GasEstimator.BumpMin") + require.Contains(t, err.Error(), "bumped fee price of 20 gwei is equal to original fee price of 20 gwei. ACTION REQUIRED: This is a configuration error, you must increase either FeeEstimator.BumpPercent or FeeEstimator.BumpMin") assert.True(t, retryable) // TEARDOWN: Clear out the unsent tx before the next test diff --git a/core/chains/evm/txmgr/confirmer_test.go b/core/chains/evm/txmgr/confirmer_test.go index 3bdaf7e206e..3de0c1079bf 100644 --- a/core/chains/evm/txmgr/confirmer_test.go +++ b/core/chains/evm/txmgr/confirmer_test.go @@ -21,6 +21,7 @@ import ( "github.com/stretchr/testify/require" clienttypes "github.com/smartcontractkit/chainlink/v2/common/chains/client" + commonfee "github.com/smartcontractkit/chainlink/v2/common/fee" txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" txmgrtypes "github.com/smartcontractkit/chainlink/v2/common/txmgr/types" "github.com/smartcontractkit/chainlink/v2/core/assets" @@ -1642,7 +1643,7 @@ func TestEthConfirmer_RebroadcastWhereNecessary_WithConnectivityCheck(t *testing kst := ksmocks.NewEth(t) estimator := gasmocks.NewEvmEstimator(t) - estimator.On("BumpLegacyGas", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(nil, uint32(0), pkgerrors.Wrapf(gas.ErrConnectivity, "transaction...")) + estimator.On("BumpLegacyGas", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(nil, uint32(0), pkgerrors.Wrapf(commonfee.ErrConnectivity, "transaction...")) ge := ccfg.EVM().GasEstimator() feeEstimator := gas.NewWrappedEvmEstimator(estimator, ge.EIP1559DynamicFees()) txBuilder := txmgr.NewEvmTxAttemptBuilder(*ethClient.ConfiguredChainID(), ge, kst, feeEstimator) @@ -1686,7 +1687,7 @@ func TestEthConfirmer_RebroadcastWhereNecessary_WithConnectivityCheck(t *testing kst := ksmocks.NewEth(t) estimator := gasmocks.NewEvmEstimator(t) - estimator.On("BumpDynamicFee", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(gas.DynamicFee{}, uint32(0), pkgerrors.Wrapf(gas.ErrConnectivity, "transaction...")) + estimator.On("BumpDynamicFee", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(gas.DynamicFee{}, uint32(0), pkgerrors.Wrapf(commonfee.ErrConnectivity, "transaction...")) // Create confirmer with necessary state ge := ccfg.EVM().GasEstimator() feeEstimator := gas.NewWrappedEvmEstimator(estimator, ge.EIP1559DynamicFees()) From fa811afde04df24f29636d378ced04c6367a2c1c Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Tue, 8 Aug 2023 11:32:20 -0400 Subject: [PATCH 112/270] (fix): callback gasUsed should not count gasForCallExactCheck (#10104) * (fix): callback gasUsed should not count gasForCallExactCheck * (test): Add FaultyClient test * rename testhelper to FunctionsClientWithEmptyCallback --- .../functions/dev/1_0_0/FunctionsRouter.sol | 3 +- .../FunctionsClientWithEmptyCallback.sol | 32 ++++++++++++ .../v0.8/functions/v1/FunctionsClient.test.ts | 52 +++++++++++++++++++ .../functions_router/functions_router.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 5 files changed, 88 insertions(+), 3 deletions(-) create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index 224033f5d94..c946e041429 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -427,8 +427,9 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, } // call and report whether we succeeded // call(gas,addr,value,argsOffset,argsLength,retOffset,retLength) + let gasBeforeCall := gas() success := call(callbackGasLimit, client, 0, add(encodedCallback, 0x20), mload(encodedCallback), 0, 0) - gasUsed := sub(g, gas()) + gasUsed := sub(gasBeforeCall, gas()) // limit our copy to MAX_CALLBACK_RETURN_BYTES bytes let toCopy := returndatasize() diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol new file mode 100644 index 00000000000..7f9050b1e2f --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.6; + +import {ITermsOfServiceAllowList} from "../../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; +import {IFunctionsSubscriptions} from "../../../dev/1_0_0/interfaces/IFunctionsSubscriptions.sol"; + +import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; +import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; + +contract FunctionsClientWithEmptyCallback is FunctionsClient { + using FunctionsRequest for FunctionsRequest.Request; + + event SendRequestInvoked(bytes32 requestId, string sourceCode, uint64 subscriptionId); + event FulfillRequestInvoked(bytes32 requestId, bytes response, bytes err); + + constructor(address router) FunctionsClient(router) {} + + function sendSimpleRequestWithJavaScript( + string memory sourceCode, + uint64 subscriptionId, + bytes32 donId, + uint32 callbackGasLimit + ) public returns (bytes32 requestId) { + FunctionsRequest.Request memory request; + request.initializeRequestForInlineJavaScript(sourceCode); + bytes memory requestData = FunctionsRequest.encodeCBOR(request); + requestId = _sendRequest(requestData, subscriptionId, callbackGasLimit, donId); + emit SendRequestInvoked(requestId, sourceCode, subscriptionId); + } + + function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal override {} +} diff --git a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts index 0fb02d00ee5..ccb059a5a3f 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsClient.test.ts @@ -173,3 +173,55 @@ describe('Functions Client', () => { }) }) }) + +describe('Faulty Functions Client', () => { + it('can complete requests with an empty callback', async () => { + const clientWithEmptyCallbackTestHelperFactory = + await ethers.getContractFactory( + 'src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol:FunctionsClientWithEmptyCallback', + roles.consumer, + ) + + const clientWithEmptyCallback = + await clientWithEmptyCallbackTestHelperFactory + .connect(roles.consumer) + .deploy(contracts.router.address) + + const subscriptionId = await createSubscription( + roles.subOwner, + [clientWithEmptyCallback.address], + contracts.router, + contracts.accessControl, + contracts.linkToken, + ) + const tx = await clientWithEmptyCallback.sendSimpleRequestWithJavaScript( + 'function run(){return response}', + subscriptionId, + ids.donId, + 20_000, + ) + const { events } = await tx.wait() + const requestId = getEventArg(events, 'RequestSent', 0) + await expect(tx) + .to.emit(clientWithEmptyCallback, 'RequestSent') + .withArgs(requestId) + + const response = stringToBytes('response') + const error = stringToBytes('') + const oracleRequestEvent = await contracts.coordinator.queryFilter( + contracts.coordinator.filters.OracleRequest(), + ) + const onchainMetadata = oracleRequestEvent[0].args?.['commitment'] + const report = await encodeReport( + ethers.utils.hexZeroPad(requestId, 32), + response, + error, + onchainMetadata, + stringToBytes(''), + ) + await expect(contracts.coordinator.callReport(report)) + .to.emit(contracts.coordinator, 'OracleResponse') + .withArgs(requestId, await roles.defaultAccount.getAddress()) + .to.emit(contracts.router, 'RequestProcessed') + }) +}) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index 34366799f0b..eb6342a9607 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -69,7 +69,7 @@ type IFunctionsSubscriptionsSubscription struct { var FunctionsRouterMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"totalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"deductionAttempt\",\"type\":\"uint256\"}],\"name\":\"TotalBalanceInvariantViolated\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200623f3803806200623f8339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615b8c620006b3600039600081816113c20152818161219501528181612a8d01528181612b5101526132cc0152615b8c6000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614886565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046148c7565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f919061496e565b6102f66103a2366004614981565b610853565b6102f66103b5366004614b44565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614df0565b6109b2565b60405161030f929190614ed8565b6102f6610417366004614f65565b610d98565b6102f661101d565b610437610432366004615067565b61102f565b60405190815260200161030f565b610437610453366004615067565b61108f565b6102f66104663660046150eb565b61109b565b610437610479366004614886565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be366004615119565b6111e9565b6102f66104d1366004615119565b61140b565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004615147565b61155d565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004615175565b6115ed565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c3660046150eb565b6116ac565b6102f6611860565b6102f66105a7366004614886565b611987565b6102f6611ace565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e53660046150eb565b611ade565b6104e4611eb3565b610605610600366004614886565b612040565b60405161030f91906151df565b6102f6610620366004615267565b612175565b610559610633366004615175565b6123c1565b600954610437565b6102f6612420565b61065061256c565b60405161030f9291906152c3565b61066661263c565b60405161030f919061531a565b6104e46106813660046153c4565b612771565b6102f66106943660046150eb565b6129f1565b6102f66106a73660046153c4565b612a54565b6102f66106ba3660046153e1565b612bcd565b6104a06106cd366004614886565b612e9e565b6102f66106e0366004615175565b612fed565b6102f66106f33660046153c4565b612ffa565b61070061300b565b61070981613013565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16613089565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d7615457565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b61300b565b61086482613013565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d613375565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906146d1565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a7919061531a565b60405180910390a150565b6000806109bd6133fb565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615486565b60405180910390a2506000610d8d565b8251600090815260056020908152604091829020549151610aab918691016154b8565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615486565b8261012001518360a0015163ffffffff16610b1e9190615614565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615486565b6000610b7e8460a0015163ffffffff16613403565b610b889088615639565b9050600081878660c0015168ffffffffffffffffff16610ba89190615661565b610bb29190615661565b9050610bc18560800151612040565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615486565b60405180910390a25060009150610d8d9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615486565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c91906134a5565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d158860200151613403565b8d613632565b9050846080015167ffffffffffffffff1685600001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610d68578e610d6a565b8f5b8860400151604051610d80959493929190615686565b60405180910390a3519150505b965096945050505050565b610da0613375565b8151815181141580610db25750600881115b15610de9576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610edb576000848281518110610e0857610e08615457565b602002602001015190506000848381518110610e2657610e26615457565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e91575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec8576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ed4906156e8565b9050610dec565b506040805180820190915283815260208082018490528451600c91610f0491839188019061477c565b506020828101518051610f1d92600185019201906147b7565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f6057610f60615457565b602002602001015160086000878581518110610f7e57610f7e615457565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fc757610fc7615457565b60200260200101516040516110059392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611016816156e8565b9050610f24565b611025613375565b61102d6139b4565b565b60008061103b836115ed565b905061108383828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613a319050565b98975050505050505050565b60008061103b836123c1565b6110a36133fb565b6110ac82613dda565b6110b4613ea0565b73ffffffffffffffffffffffffffffffffffffffff8116158061111b575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611152576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111f161300b565b806bffffffffffffffffffffffff166000036112275750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611293576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff808416911610156112fc576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b30600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff1661137f9190615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061140683836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613faa9092919063ffffffff16565b505050565b6114136133fb565b806bffffffffffffffffffffffff1660000361145b576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff9081169082168110156114c7576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff80841691161015611530576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b33600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615720565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561167657600c805460ff831690811061161557611615615457565b9060005260206000200154830361166657600d805460ff831690811061163d5761163d615457565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61166f81615745565b90506115f1565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6116b46133fb565b6116bd82613dda565b6116c5613ea0565b60006116d4600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611737576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff161561177f57505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff1633146118e1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b61198f6133fb565b611997613ea0565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611a37576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611853565b611ad6613375565b61102d614037565b611ae66133fb565b611aef82613dda565b611af7613ea0565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b9f576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611bf4576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611c6f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611c44575b5050505050905060005b8151811015611e17578373ffffffffffffffffffffffffffffffffffffffff16828281518110611cab57611cab615457565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611e07578160018351611cdd9190615764565b81518110611ced57611ced615457565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611d3057611d30615457565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611daa57611daa615777565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611e17565b611e10816156e8565b9050611c79565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611ebd6133fb565b611ec5613ea0565b60028054600090611edf9067ffffffffffffffff166157a6565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611f55578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611ff0926002850192909101906147b7565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261207a82613013565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561215b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612130575b505050505081526020016003820154815250509050919050565b61217d6133fb565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146121ec576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612226576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061223482840184614886565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166122ad576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906122e48385615661565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661233a9190615661565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846123a191906157cd565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff16806115e7576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b612428613375565b60005b600c5481101561254b576000600c600001828154811061244d5761244d615457565b906000526020600020015490506000600c600101838154811061247257612472615457565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612544816156e8565b905061242b565b50600c600061255a8282614831565b612568600183016000614831565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156125c457602002820191906000526020600020905b8154815260200190600101908083116125b0575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561262d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612602575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561276357602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116127265790505b505050505081525050905090565b600061277b6133fb565b612783613ea0565b6002805460009061279d9067ffffffffffffffff166157a6565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612813578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926128ae926002850192909101906147b7565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b6129f96133fb565b612a0282613dda565b612a0a613ea0565b612a1382612e9e565b15612a4a576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6125688282613089565b612a5c61300b565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ae9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b0d91906157e0565b6000549091506bffffffffffffffffffffffff1681811015611406576000612b358284615764565b9050612b7873ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613faa565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612bd56133fb565b60005b81811015611406576000838383818110612bf457612bf4615457565b90506101600201803603810190612c0b91906157f9565b80516080820151600082815260056020908152604091829020549151949550929391929091612c3c918691016154b8565b6040516020818303038152906040528051906020012014612c89576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612cce576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612d41573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d659190615816565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612da69084906bffffffffffffffffffffffff16615720565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612e2e9185916901000000000000000000900416615838565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612e97906156e8565b9050612bd8565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612f1657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612eeb575b5050505050905060005b8151811015612fe357600060046000848481518110612f4157612f41615457565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612fd257506001949350505050565b50612fdc816156e8565b9050612f20565b5060009392505050565b612ff5613375565b600955565b613002613375565b61075481614092565b61102d613375565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561316a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161313f575b505050918352505060039190910154602090910152805190915060005b82608001515181101561322b5760046000846080015183815181106131ae576131ae615457565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613224816156e8565b9050613187565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061325d6002830182614831565b506000600391909101819055805482919081906132899084906bffffffffffffffffffffffff16615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061331083826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613faa9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611ea5565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61102d61418e565b60006bffffffffffffffffffffffff8211156134a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b906134ef90899089908990602401615859565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6135ba57600080fd5b5a848110156135c857600080fd5b84900360408104810389106135dc57600080fd5b60008087516020890160008c8ef193505a900391503d60848111156135ff575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b604080518082019091526000808252602082015260006136528486615639565b90506000816136618886615661565b61366b9190615661565b67ffffffffffffffff8b166000908152600360205260409020549091506bffffffffffffffffffffffff808316911610156136fe5767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812080548392906137359084906bffffffffffffffffffffffff16615720565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600360205260409020600101548b82169116101590506137e25767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812060010180548b929061381c9084906bffffffffffffffffffffffff16615720565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846138569190615661565b33600090815260016020526040812080549091906138839084906bffffffffffffffffffffffff16615661565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926138ca91859116615661565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f1685529252909120805460019260099161394e9185916901000000000000000000900416615838565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6139bc6141fb565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613a3b6133fb565b613a4485613013565b613a4e3386614267565b613a588583610757565b8351600003613a92576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a9d86612040565b90506000613aab338861155d565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a8152602001613b018c67ffffffffffffffff166000908152600360208190526040909120015490565b815233602082015260408781015188519190920191613b1f91615720565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b8152600401613be59190615884565b610160604051808303816000875af1158015613c05573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c2991906159e9565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613d3091906154b8565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613d70338983604001516142db565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613dc49796959493929190615abc565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e51576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612568576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613ed05750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613f3190339060248101615b34565b602060405180830381865afa158015613f4e573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f729190615816565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526114069084906143b6565b61403f61418e565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a073390565b3373ffffffffffffffffffffffffffffffffffffffff821603614111576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612568576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143159084906bffffffffffffffffffffffff16615661565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261438b928492900416615838565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b6000614418826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166144c29092919063ffffffff16565b80519091501561140657808060200190518101906144369190615816565b611406576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606144d184846000856144d9565b949350505050565b60608247101561456b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516145949190615b63565b60006040518083038185875af1925050503d80600081146145d1576040519150601f19603f3d011682016040523d82523d6000602084013e6145d6565b606091505b50915091506145e7878383876145f2565b979650505050505050565b606083156146885782516000036146815773ffffffffffffffffffffffffffffffffffffffff85163b614681576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816144d1565b6144d1838381511561469d5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b3919061496e565b828054828255906000526020600020906007016008900481019282156147705791602002820160005b8382111561473e57835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026146fa565b801561476e5782816101000a81549063ffffffff021916905560040160208160030104928301926001030261473e565b505b506134a192915061484b565b828054828255906000526020600020908101928215614770579160200282015b8281111561477057825182559160200191906001019061479c565b828054828255906000526020600020908101928215614770579160200282015b8281111561477057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906147d7565b508054600082559060005260206000209081019061075491905b5b808211156134a1576000815560010161484c565b67ffffffffffffffff8116811461075457600080fd5b803561488181614860565b919050565b60006020828403121561489857600080fd5b81356148a381614860565b9392505050565b63ffffffff8116811461075457600080fd5b8035614881816148aa565b600080604083850312156148da57600080fd5b82356148e581614860565b915060208301356148f5816148aa565b809150509250929050565b60005b8381101561491b578181015183820152602001614903565b50506000910152565b6000815180845261493c816020860160208601614900565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006148a36020830184614924565b6000806040838503121561499457600080fd5b823561499f81614860565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff811182821017156149ff576149ff6149ad565b60405290565b604051610160810167ffffffffffffffff811182821017156149ff576149ff6149ad565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614a7057614a706149ad565b604052919050565b803561ffff8116811461488157600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561488181614a8a565b600067ffffffffffffffff821115614ac657614ac66149ad565b5060051b60200190565b600082601f830112614ae157600080fd5b81356020614af6614af183614aac565b614a29565b82815260059290921b84018101918181019086841115614b1557600080fd5b8286015b84811015614b39578035614b2c816148aa565b8352918301918301614b19565b509695505050505050565b600060208284031215614b5657600080fd5b813567ffffffffffffffff80821115614b6e57600080fd5b9083019060a08286031215614b8257600080fd5b614b8a6149dc565b614b9383614a78565b81526020830135614ba381614a8a565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614bdb57600080fd5b6040820152614bec60608401614a78565b6060820152608083013582811115614c0357600080fd5b614c0f87828601614ad0565b60808301525095945050505050565b600082601f830112614c2f57600080fd5b813567ffffffffffffffff811115614c4957614c496149ad565b614c7a60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a29565b818152846020838601011115614c8f57600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561488181614cac565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561488181614cd1565b64ffffffffff8116811461075457600080fd5b803561488181614cfe565b60006101608284031215614d2f57600080fd5b614d37614a05565b905081358152614d4960208301614cf3565b6020820152614d5a60408301614cc6565b6040820152614d6b60608301614cf3565b6060820152614d7c60808301614876565b6080820152614d8d60a083016148bc565b60a0820152614d9e60c08301614aa1565b60c0820152614daf60e08301614aa1565b60e0820152610100614dc2818401614d11565b90820152610120614dd4838201614d11565b90820152610140614de68382016148bc565b9082015292915050565b6000806000806000806102008789031215614e0a57600080fd5b863567ffffffffffffffff80821115614e2257600080fd5b614e2e8a838b01614c1e565b97506020890135915080821115614e4457600080fd5b50614e5189828a01614c1e565b9550506040870135614e6281614cac565b93506060870135614e7281614cac565b92506080870135614e8281614cd1565b9150614e918860a08901614d1c565b90509295509295509295565b60078110614ed4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614ee68285614e9d565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614f1257600080fd5b81356020614f22614af183614aac565b82815260059290921b84018101918181019086841115614f4157600080fd5b8286015b84811015614b39578035614f5881614cd1565b8352918301918301614f45565b60008060408385031215614f7857600080fd5b823567ffffffffffffffff80821115614f9057600080fd5b818501915085601f830112614fa457600080fd5b81356020614fb4614af183614aac565b82815260059290921b84018101918181019089841115614fd357600080fd5b948201945b83861015614ff157853582529482019490820190614fd8565b9650508601359250508082111561500757600080fd5b5061501485828601614f01565b9150509250929050565b60008083601f84011261503057600080fd5b50813567ffffffffffffffff81111561504857600080fd5b60208301915083602082850101111561506057600080fd5b9250929050565b60008060008060008060a0878903121561508057600080fd5b863561508b81614860565b9550602087013567ffffffffffffffff8111156150a757600080fd5b6150b389828a0161501e565b90965094506150c6905060408801614a78565b925060608701356150d6816148aa565b80925050608087013590509295509295509295565b600080604083850312156150fe57600080fd5b823561510981614860565b915060208301356148f581614cd1565b6000806040838503121561512c57600080fd5b823561513781614cd1565b915060208301356148f581614cac565b6000806040838503121561515a57600080fd5b823561516581614cd1565b915060208301356148f581614860565b60006020828403121561518757600080fd5b5035919050565b600081518084526020808501945080840160005b838110156151d457815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016151a2565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261525160e084018261518e565b905060a084015160c08401528091505092915050565b6000806000806060858703121561527d57600080fd5b843561528881614cd1565b935060208501359250604085013567ffffffffffffffff8111156152ab57600080fd5b6152b78782880161501e565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b828110156152fc578151845292840192908401906001016152e0565b50505083810382850152615310818661518e565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614b3957835163ffffffff16825292840192600192909201919084019061539e565b6000602082840312156153d657600080fd5b81356148a381614cd1565b600080602083850312156153f457600080fd5b823567ffffffffffffffff8082111561540c57600080fd5b818501915085601f83011261542057600080fd5b81358181111561542f57600080fd5b8660206101608302850101111561544557600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016144d16040830184614e9d565b815181526020808301516101608301916154e99084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161550960408401826bffffffffffffffffffffffff169052565b506060830151615531606084018273ffffffffffffffffffffffffffffffffffffffff169052565b50608083015161554d608084018267ffffffffffffffff169052565b5060a083015161556560a084018263ffffffff169052565b5060c083015161558260c084018268ffffffffffffffffff169052565b5060e083015161559f60e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff818116838216019080821115615632576156326155e5565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155dd576155dd6155e5565b6bffffffffffffffffffffffff818116838216019080821115615632576156326155e5565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff851660208201526156c06040820185614e9d565b60a0606082015260006156d660a0830185614924565b82810360808401526110838185614924565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203615719576157196155e5565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615632576156326155e5565b600060ff821660ff810361575b5761575b6155e5565b60010192915050565b818103818111156115e7576115e76155e5565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157c3576157c36155e5565b6001019392505050565b808201808211156115e7576115e76155e5565b6000602082840312156157f257600080fd5b5051919050565b6000610160828403121561580c57600080fd5b6148a38383614d1c565b60006020828403121561582857600080fd5b815180151581146148a357600080fd5b67ffffffffffffffff818116838216019080821115615632576156326155e5565b8381526060602082015260006158726060830185614924565b82810360408401526153108185614924565b60208152600082516101608060208501526158a3610180850183614924565b91506020850151604085015260408501516158d6606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e085015161010061594d8187018363ffffffff169052565b86015190506101206159648682018361ffff169052565b86015190506101406159818682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161488181614cd1565b805161488181614cac565b805161488181614860565b8051614881816148aa565b805161488181614a8a565b805161488181614cfe565b600061016082840312156159fc57600080fd5b615a04614a05565b82518152615a14602084016159a7565b6020820152615a25604084016159b2565b6040820152615a36606084016159a7565b6060820152615a47608084016159bd565b6080820152615a5860a084016159c8565b60a0820152615a6960c084016159d3565b60c0820152615a7a60e084016159d3565b60e0820152610100615a8d8185016159de565b90820152610120615a9f8482016159de565b90820152610140615ab18482016159c8565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615afd60e0830187614924565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006144d16040830184614924565b60008251615b75818460208701614900565b919091019291505056fea164736f6c6343000813000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162006241380380620062418339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615b8e620006b3600039600081816113c20152818161219501528181612a8d01528181612b5101526132cc0152615b8e6000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614888565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046148c9565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614970565b6102f66103a2366004614983565b610853565b6102f66103b5366004614b46565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614df2565b6109b2565b60405161030f929190614eda565b6102f6610417366004614f67565b610d98565b6102f661101d565b610437610432366004615069565b61102f565b60405190815260200161030f565b610437610453366004615069565b61108f565b6102f66104663660046150ed565b61109b565b610437610479366004614888565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be36600461511b565b6111e9565b6102f66104d136600461511b565b61140b565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004615149565b61155d565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004615177565b6115ed565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c3660046150ed565b6116ac565b6102f6611860565b6102f66105a7366004614888565b611987565b6102f6611ace565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e53660046150ed565b611ade565b6104e4611eb3565b610605610600366004614888565b612040565b60405161030f91906151e1565b6102f6610620366004615269565b612175565b610559610633366004615177565b6123c1565b600954610437565b6102f6612420565b61065061256c565b60405161030f9291906152c5565b61066661263c565b60405161030f919061531c565b6104e46106813660046153c6565b612771565b6102f66106943660046150ed565b6129f1565b6102f66106a73660046153c6565b612a54565b6102f66106ba3660046153e3565b612bcd565b6104a06106cd366004614888565b612e9e565b6102f66106e0366004615177565b612fed565b6102f66106f33660046153c6565b612ffa565b61070061300b565b61070981613013565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16613089565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d7615459565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b61300b565b61086482613013565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d613375565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906146d3565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a7919061531c565b60405180910390a150565b6000806109bd6133fb565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615488565b60405180910390a2506000610d8d565b8251600090815260056020908152604091829020549151610aab918691016154ba565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615488565b8261012001518360a0015163ffffffff16610b1e9190615616565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615488565b6000610b7e8460a0015163ffffffff16613403565b610b88908861563b565b9050600081878660c0015168ffffffffffffffffff16610ba89190615663565b610bb29190615663565b9050610bc18560800151612040565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615488565b60405180910390a25060009150610d8d9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615488565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c91906134a5565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d158860200151613403565b8d613634565b9050846080015167ffffffffffffffff1685600001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610d68578e610d6a565b8f5b8860400151604051610d80959493929190615688565b60405180910390a3519150505b965096945050505050565b610da0613375565b8151815181141580610db25750600881115b15610de9576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610edb576000848281518110610e0857610e08615459565b602002602001015190506000848381518110610e2657610e26615459565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e91575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec8576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ed4906156ea565b9050610dec565b506040805180820190915283815260208082018490528451600c91610f0491839188019061477e565b506020828101518051610f1d92600185019201906147b9565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f6057610f60615459565b602002602001015160086000878581518110610f7e57610f7e615459565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fc757610fc7615459565b60200260200101516040516110059392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611016816156ea565b9050610f24565b611025613375565b61102d6139b6565b565b60008061103b836115ed565b905061108383828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613a339050565b98975050505050505050565b60008061103b836123c1565b6110a36133fb565b6110ac82613ddc565b6110b4613ea2565b73ffffffffffffffffffffffffffffffffffffffff8116158061111b575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611152576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111f161300b565b806bffffffffffffffffffffffff166000036112275750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611293576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff808416911610156112fc576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b30600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff1661137f9190615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061140683836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613fac9092919063ffffffff16565b505050565b6114136133fb565b806bffffffffffffffffffffffff1660000361145b576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff9081169082168110156114c7576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff80841691161015611530576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b33600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615722565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561167657600c805460ff831690811061161557611615615459565b9060005260206000200154830361166657600d805460ff831690811061163d5761163d615459565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61166f81615747565b90506115f1565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6116b46133fb565b6116bd82613ddc565b6116c5613ea2565b60006116d4600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611737576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff161561177f57505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff1633146118e1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b61198f6133fb565b611997613ea2565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611a37576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611853565b611ad6613375565b61102d614039565b611ae66133fb565b611aef82613ddc565b611af7613ea2565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b9f576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611bf4576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611c6f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611c44575b5050505050905060005b8151811015611e17578373ffffffffffffffffffffffffffffffffffffffff16828281518110611cab57611cab615459565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611e07578160018351611cdd9190615766565b81518110611ced57611ced615459565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611d3057611d30615459565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611daa57611daa615779565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611e17565b611e10816156ea565b9050611c79565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611ebd6133fb565b611ec5613ea2565b60028054600090611edf9067ffffffffffffffff166157a8565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611f55578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611ff0926002850192909101906147b9565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261207a82613013565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561215b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612130575b505050505081526020016003820154815250509050919050565b61217d6133fb565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146121ec576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612226576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061223482840184614888565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166122ad576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906122e48385615663565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661233a9190615663565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846123a191906157cf565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff16806115e7576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b612428613375565b60005b600c5481101561254b576000600c600001828154811061244d5761244d615459565b906000526020600020015490506000600c600101838154811061247257612472615459565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612544816156ea565b905061242b565b50600c600061255a8282614833565b612568600183016000614833565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156125c457602002820191906000526020600020905b8154815260200190600101908083116125b0575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561262d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612602575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561276357602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116127265790505b505050505081525050905090565b600061277b6133fb565b612783613ea2565b6002805460009061279d9067ffffffffffffffff166157a8565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612813578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926128ae926002850192909101906147b9565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b6129f96133fb565b612a0282613ddc565b612a0a613ea2565b612a1382612e9e565b15612a4a576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6125688282613089565b612a5c61300b565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ae9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b0d91906157e2565b6000549091506bffffffffffffffffffffffff1681811015611406576000612b358284615766565b9050612b7873ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613fac565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612bd56133fb565b60005b81811015611406576000838383818110612bf457612bf4615459565b90506101600201803603810190612c0b91906157fb565b80516080820151600082815260056020908152604091829020549151949550929391929091612c3c918691016154ba565b6040516020818303038152906040528051906020012014612c89576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612cce576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612d41573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d659190615818565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612da69084906bffffffffffffffffffffffff16615722565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612e2e918591690100000000000000000090041661583a565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612e97906156ea565b9050612bd8565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612f1657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612eeb575b5050505050905060005b8151811015612fe357600060046000848481518110612f4157612f41615459565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612fd257506001949350505050565b50612fdc816156ea565b9050612f20565b5060009392505050565b612ff5613375565b600955565b613002613375565b61075481614094565b61102d613375565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561316a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161313f575b505050918352505060039190910154602090910152805190915060005b82608001515181101561322b5760046000846080015183815181106131ae576131ae615459565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613224816156ea565b9050613187565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061325d6002830182614833565b506000600391909101819055805482919081906132899084906bffffffffffffffffffffffff16615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061331083826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613fac9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611ea5565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61102d614190565b60006bffffffffffffffffffffffff8211156134a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b906134ef9089908990899060240161585b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6135ba57600080fd5b5a848110156135c857600080fd5b84900360408104810389106135dc57600080fd5b505a60008087516020890160008c8ef193505a900391503d6084811115613601575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b60408051808201909152600080825260208201526000613654848661563b565b90506000816136638886615663565b61366d9190615663565b67ffffffffffffffff8b166000908152600360205260409020549091506bffffffffffffffffffffffff808316911610156137005767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812080548392906137379084906bffffffffffffffffffffffff16615722565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600360205260409020600101548b82169116101590506137e45767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812060010180548b929061381e9084906bffffffffffffffffffffffff16615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846138589190615663565b33600090815260016020526040812080549091906138859084906bffffffffffffffffffffffff16615663565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926138cc91859116615663565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613950918591690100000000000000000090041661583a565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6139be6141fd565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613a3d6133fb565b613a4685613013565b613a503386614269565b613a5a8583610757565b8351600003613a94576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a9f86612040565b90506000613aad338861155d565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a8152602001613b038c67ffffffffffffffff166000908152600360208190526040909120015490565b815233602082015260408781015188519190920191613b2191615722565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b8152600401613be79190615886565b610160604051808303816000875af1158015613c07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c2b91906159eb565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613d3291906154ba565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613d72338983604001516142dd565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613dc69796959493929190615abe565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e53576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612568576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613ed25750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613f3390339060248101615b36565b602060405180830381865afa158015613f50573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f749190615818565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526114069084906143b8565b614041614190565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a093390565b3373ffffffffffffffffffffffffffffffffffffffff821603614113576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612568576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143179084906bffffffffffffffffffffffff16615663565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261438d92849290041661583a565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b600061441a826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166144c49092919063ffffffff16565b80519091501561140657808060200190518101906144389190615818565b611406576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606144d384846000856144db565b949350505050565b60608247101561456d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516145969190615b65565b60006040518083038185875af1925050503d80600081146145d3576040519150601f19603f3d011682016040523d82523d6000602084013e6145d8565b606091505b50915091506145e9878383876145f4565b979650505050505050565b6060831561468a5782516000036146835773ffffffffffffffffffffffffffffffffffffffff85163b614683576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816144d3565b6144d3838381511561469f5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b39190614970565b828054828255906000526020600020906007016008900481019282156147725791602002820160005b8382111561474057835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026146fc565b80156147705782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614740565b505b506134a192915061484d565b828054828255906000526020600020908101928215614772579160200282015b8281111561477257825182559160200191906001019061479e565b828054828255906000526020600020908101928215614772579160200282015b8281111561477257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906147d9565b508054600082559060005260206000209081019061075491905b5b808211156134a1576000815560010161484e565b67ffffffffffffffff8116811461075457600080fd5b803561488381614862565b919050565b60006020828403121561489a57600080fd5b81356148a581614862565b9392505050565b63ffffffff8116811461075457600080fd5b8035614883816148ac565b600080604083850312156148dc57600080fd5b82356148e781614862565b915060208301356148f7816148ac565b809150509250929050565b60005b8381101561491d578181015183820152602001614905565b50506000910152565b6000815180845261493e816020860160208601614902565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006148a56020830184614926565b6000806040838503121561499657600080fd5b82356149a181614862565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715614a0157614a016149af565b60405290565b604051610160810167ffffffffffffffff81118282101715614a0157614a016149af565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614a7257614a726149af565b604052919050565b803561ffff8116811461488357600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561488381614a8c565b600067ffffffffffffffff821115614ac857614ac86149af565b5060051b60200190565b600082601f830112614ae357600080fd5b81356020614af8614af383614aae565b614a2b565b82815260059290921b84018101918181019086841115614b1757600080fd5b8286015b84811015614b3b578035614b2e816148ac565b8352918301918301614b1b565b509695505050505050565b600060208284031215614b5857600080fd5b813567ffffffffffffffff80821115614b7057600080fd5b9083019060a08286031215614b8457600080fd5b614b8c6149de565b614b9583614a7a565b81526020830135614ba581614a8c565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614bdd57600080fd5b6040820152614bee60608401614a7a565b6060820152608083013582811115614c0557600080fd5b614c1187828601614ad2565b60808301525095945050505050565b600082601f830112614c3157600080fd5b813567ffffffffffffffff811115614c4b57614c4b6149af565b614c7c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a2b565b818152846020838601011115614c9157600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561488381614cae565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561488381614cd3565b64ffffffffff8116811461075457600080fd5b803561488381614d00565b60006101608284031215614d3157600080fd5b614d39614a07565b905081358152614d4b60208301614cf5565b6020820152614d5c60408301614cc8565b6040820152614d6d60608301614cf5565b6060820152614d7e60808301614878565b6080820152614d8f60a083016148be565b60a0820152614da060c08301614aa3565b60c0820152614db160e08301614aa3565b60e0820152610100614dc4818401614d13565b90820152610120614dd6838201614d13565b90820152610140614de88382016148be565b9082015292915050565b6000806000806000806102008789031215614e0c57600080fd5b863567ffffffffffffffff80821115614e2457600080fd5b614e308a838b01614c20565b97506020890135915080821115614e4657600080fd5b50614e5389828a01614c20565b9550506040870135614e6481614cae565b93506060870135614e7481614cae565b92506080870135614e8481614cd3565b9150614e938860a08901614d1e565b90509295509295509295565b60078110614ed6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614ee88285614e9f565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614f1457600080fd5b81356020614f24614af383614aae565b82815260059290921b84018101918181019086841115614f4357600080fd5b8286015b84811015614b3b578035614f5a81614cd3565b8352918301918301614f47565b60008060408385031215614f7a57600080fd5b823567ffffffffffffffff80821115614f9257600080fd5b818501915085601f830112614fa657600080fd5b81356020614fb6614af383614aae565b82815260059290921b84018101918181019089841115614fd557600080fd5b948201945b83861015614ff357853582529482019490820190614fda565b9650508601359250508082111561500957600080fd5b5061501685828601614f03565b9150509250929050565b60008083601f84011261503257600080fd5b50813567ffffffffffffffff81111561504a57600080fd5b60208301915083602082850101111561506257600080fd5b9250929050565b60008060008060008060a0878903121561508257600080fd5b863561508d81614862565b9550602087013567ffffffffffffffff8111156150a957600080fd5b6150b589828a01615020565b90965094506150c8905060408801614a7a565b925060608701356150d8816148ac565b80925050608087013590509295509295509295565b6000806040838503121561510057600080fd5b823561510b81614862565b915060208301356148f781614cd3565b6000806040838503121561512e57600080fd5b823561513981614cd3565b915060208301356148f781614cae565b6000806040838503121561515c57600080fd5b823561516781614cd3565b915060208301356148f781614862565b60006020828403121561518957600080fd5b5035919050565b600081518084526020808501945080840160005b838110156151d657815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016151a4565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261525360e0840182615190565b905060a084015160c08401528091505092915050565b6000806000806060858703121561527f57600080fd5b843561528a81614cd3565b935060208501359250604085013567ffffffffffffffff8111156152ad57600080fd5b6152b987828801615020565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b828110156152fe578151845292840192908401906001016152e2565b505050838103828501526153128186615190565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614b3b57835163ffffffff1682529284019260019290920191908401906153a0565b6000602082840312156153d857600080fd5b81356148a581614cd3565b600080602083850312156153f657600080fd5b823567ffffffffffffffff8082111561540e57600080fd5b818501915085601f83011261542257600080fd5b81358181111561543157600080fd5b8660206101608302850101111561544757600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016144d36040830184614e9f565b815181526020808301516101608301916154eb9084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161550b60408401826bffffffffffffffffffffffff169052565b506060830151615533606084018273ffffffffffffffffffffffffffffffffffffffff169052565b50608083015161554f608084018267ffffffffffffffff169052565b5060a083015161556760a084018263ffffffff169052565b5060c083015161558460c084018268ffffffffffffffffff169052565b5060e08301516155a160e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff818116838216019080821115615634576156346155e7565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155df576155df6155e7565b6bffffffffffffffffffffffff818116838216019080821115615634576156346155e7565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff851660208201526156c26040820185614e9f565b60a0606082015260006156d860a0830185614926565b82810360808401526110838185614926565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361571b5761571b6155e7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615634576156346155e7565b600060ff821660ff810361575d5761575d6155e7565b60010192915050565b818103818111156115e7576115e76155e7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157c5576157c56155e7565b6001019392505050565b808201808211156115e7576115e76155e7565b6000602082840312156157f457600080fd5b5051919050565b6000610160828403121561580e57600080fd5b6148a58383614d1e565b60006020828403121561582a57600080fd5b815180151581146148a557600080fd5b67ffffffffffffffff818116838216019080821115615634576156346155e7565b8381526060602082015260006158746060830185614926565b82810360408401526153128185614926565b60208152600082516101608060208501526158a5610180850183614926565b91506020850151604085015260408501516158d8606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e085015161010061594f8187018363ffffffff169052565b86015190506101206159668682018361ffff169052565b86015190506101406159838682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161488381614cd3565b805161488381614cae565b805161488381614862565b8051614883816148ac565b805161488381614a8c565b805161488381614d00565b600061016082840312156159fe57600080fd5b615a06614a07565b82518152615a16602084016159a9565b6020820152615a27604084016159b4565b6040820152615a38606084016159a9565b6060820152615a49608084016159bf565b6080820152615a5a60a084016159ca565b60a0820152615a6b60c084016159d5565b60c0820152615a7c60e084016159d5565b60e0820152610100615a8f8185016159e0565b90820152610120615aa18482016159e0565b90820152610140615ab38482016159ca565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615aff60e0830187614926565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006144d36040830184614926565b60008251615b77818460208701614902565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 8b1abf59a13..39517dd0e83 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -6,7 +6,7 @@ functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClien functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 7b2fb23e2f49121dfe4b096de5e60fe57be0a196c2423a4693293c23c96f9af4 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin 75df8bb3546c6a9aaa29f505e3ea6a1685afd2469e9ac24d1f88eadf33d8b2a0 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin ad1af30b1fdd2818e3ba75f7bf2e058d7bf134cf7d243dc7e5d4108975a1af64 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From c697a950b388bd67f1d6569b644693783d89ea1a Mon Sep 17 00:00:00 2001 From: Tate Date: Tue, 8 Aug 2023 10:51:28 -0600 Subject: [PATCH 113/270] [TT-484] Update Metric Collect to add jobRun_statusInt for pass/fail unification with test (#10114) --- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 +++--- .github/workflows/build-publish-develop.yml | 2 +- .github/workflows/build-publish.yml | 2 +- .github/workflows/build.yml | 2 +- .github/workflows/changelog.yml | 2 +- .github/workflows/ci-core.yml | 12 +++++------ .github/workflows/codeql-analysis.yml | 2 +- .github/workflows/dependency-check.yml | 2 +- .../goreleaser-build-publish-develop.yml | 2 +- .github/workflows/integration-chaos-tests.yml | 6 +++--- .../workflows/integration-tests-publish.yml | 2 +- .github/workflows/integration-tests.yml | 20 +++++++++---------- .github/workflows/lint-gh-workflows.yml | 2 +- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/operator-ui.yml | 2 +- .github/workflows/performance-tests.yml | 4 ++-- .github/workflows/readme.yml | 2 +- .github/workflows/sigscanner.yml | 2 +- .github/workflows/solidity-foundry.yml | 2 +- .github/workflows/solidity.yml | 16 +++++++-------- ...evelop-from-smartcontractkit-chainlink.yml | 2 +- 22 files changed, 48 insertions(+), 48 deletions(-) diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index befb5f510c2..2e136a2f561 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -128,7 +128,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index 2e0099e3da7..dcd22f46f06 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -36,7 +36,7 @@ jobs: - name: Collect Metrics if: inputs.chainlinkImage == '' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -81,7 +81,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -192,7 +192,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish-develop.yml b/.github/workflows/build-publish-develop.yml index 11e33ae4320..75c870e1f1b 100644 --- a/.github/workflows/build-publish-develop.yml +++ b/.github/workflows/build-publish-develop.yml @@ -40,7 +40,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish.yml b/.github/workflows/build-publish.yml index bd4f4d89097..34af77f17f4 100644 --- a/.github/workflows/build-publish.yml +++ b/.github/workflows/build-publish.yml @@ -50,7 +50,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index ac62f874a9f..d38f9eb7f16 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,7 +22,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index c2f1d00eb31..c39e9d38dc2 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index c7808900cc3..7f20f62390e 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -95,7 +95,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -124,7 +124,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -201,7 +201,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -228,7 +228,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -321,7 +321,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -353,7 +353,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index 1e8afb01553..ceef57d5fe7 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -48,7 +48,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/dependency-check.yml b/.github/workflows/dependency-check.yml index 4236ad812f4..7464869a100 100644 --- a/.github/workflows/dependency-check.yml +++ b/.github/workflows/dependency-check.yml @@ -47,7 +47,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/goreleaser-build-publish-develop.yml b/.github/workflows/goreleaser-build-publish-develop.yml index 092b83cd80a..70b6b8f5d64 100644 --- a/.github/workflows/goreleaser-build-publish-develop.yml +++ b/.github/workflows/goreleaser-build-publish-develop.yml @@ -39,7 +39,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index 6787c18175a..37aefd8f082 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -53,7 +53,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -99,7 +99,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests-publish.yml b/.github/workflows/integration-tests-publish.yml index 59bb167e0d6..5fa164ef4ff 100644 --- a/.github/workflows/integration-tests-publish.yml +++ b/.github/workflows/integration-tests-publish.yml @@ -20,7 +20,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 04a3a6d7b9b..fc2412a39ba 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -72,7 +72,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -119,7 +119,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -251,7 +251,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -272,7 +272,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -340,7 +340,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -446,7 +446,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -485,7 +485,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -539,7 +539,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -637,7 +637,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/lint-gh-workflows.yml b/.github/workflows/lint-gh-workflows.yml index 08bf24d7e4f..cadbb3b8e63 100644 --- a/.github/workflows/lint-gh-workflows.yml +++ b/.github/workflows/lint-gh-workflows.yml @@ -13,7 +13,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 368d7071284..36812b94baa 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -77,7 +77,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/operator-ui.yml b/.github/workflows/operator-ui.yml index c56c9351717..d9c2d9827e3 100644 --- a/.github/workflows/operator-ui.yml +++ b/.github/workflows/operator-ui.yml @@ -33,7 +33,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 37d3dc7de87..032b35b84d5 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/readme.yml b/.github/workflows/readme.yml index ff452de278e..22172dd9dc3 100644 --- a/.github/workflows/readme.yml +++ b/.github/workflows/readme.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sigscanner.yml b/.github/workflows/sigscanner.yml index d912d1cae56..d84891711d8 100644 --- a/.github/workflows/sigscanner.yml +++ b/.github/workflows/sigscanner.yml @@ -26,7 +26,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index a18e7d2c2c6..bac136ec164 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -70,7 +70,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity.yml b/.github/workflows/solidity.yml index 56785df1193..a8cd4107b32 100644 --- a/.github/workflows/solidity.yml +++ b/.github/workflows/solidity.yml @@ -43,7 +43,7 @@ jobs: config: ./contracts/ci.json - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -91,7 +91,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -153,7 +153,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -178,7 +178,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -202,7 +202,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -249,7 +249,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -275,7 +275,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -301,7 +301,7 @@ jobs: - name: Collect Metrics if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml index 264f473ea0a..2718e3865b4 100644 --- a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml +++ b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml @@ -30,7 +30,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@2dcc6578752a8949bdabf8d7fb4f0c70b83703cd + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} From aa2d1627720b409ccceafd32e34a64e6221a7dd9 Mon Sep 17 00:00:00 2001 From: Dimitris Grigoriou Date: Tue, 8 Aug 2023 22:04:08 +0300 Subject: [PATCH 114/270] Fix HeadTracker flakey test (#10113) --- core/chains/evm/headtracker/head_tracker_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/chains/evm/headtracker/head_tracker_test.go b/core/chains/evm/headtracker/head_tracker_test.go index 6a9a0dfc8aa..cf8399ceeda 100644 --- a/core/chains/evm/headtracker/head_tracker_test.go +++ b/core/chains/evm/headtracker/head_tracker_test.go @@ -322,7 +322,7 @@ func TestHeadTracker_ResubscribeOnSubscriptionError(t *testing.T) { func(ctx context.Context, ch chan<- *evmtypes.Head) error { return nil }, ) ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(cltest.Head(0), nil).Once() - ethClient.On("HeadByHash", mock.Anything, mock.Anything).Return(cltest.Head(0), nil).Once() + ethClient.On("HeadByHash", mock.Anything, mock.Anything).Return(cltest.Head(0), nil).Maybe() checker := &cltest.MockHeadTrackable{} ht := createHeadTrackerWithChecker(t, ethClient, config.EVM(), config.EVM().HeadTracker(), orm, checker) @@ -510,7 +510,7 @@ func TestHeadTracker_SwitchesToLongestChainWithHeadSamplingEnabled(t *testing.T) latestHeadByHash := make(map[gethCommon.Hash]*evmtypes.Head) latestHeadByHashMu := new(sync.Mutex) - fnCall := ethClient.On("HeadByHash", mock.Anything, mock.Anything) + fnCall := ethClient.On("HeadByHash", mock.Anything, mock.Anything).Maybe() fnCall.RunFn = func(args mock.Arguments) { latestHeadByHashMu.Lock() defer latestHeadByHashMu.Unlock() @@ -666,7 +666,7 @@ func TestHeadTracker_SwitchesToLongestChainWithHeadSamplingDisabled(t *testing.T latestHeadByHash := make(map[gethCommon.Hash]*evmtypes.Head) latestHeadByHashMu := new(sync.Mutex) - fnCall := ethClient.On("HeadByHash", mock.Anything, mock.Anything) + fnCall := ethClient.On("HeadByHash", mock.Anything, mock.Anything).Maybe() fnCall.RunFn = func(args mock.Arguments) { latestHeadByHashMu.Lock() defer latestHeadByHashMu.Unlock() From d39e06c1b90522d522268471a9e575c625255809 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Tue, 8 Aug 2023 13:16:41 -0700 Subject: [PATCH 115/270] [Functions] Enable request batching in threshold integration test. (#10115) Co-authored-by: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> --- core/scripts/go.mod | 4 +-- core/scripts/go.sum | 8 ++--- .../v0/functions_integration_test.go | 13 +++---- .../v1/functions_integration_test.go | 36 +++++++++++++++++++ .../v1/internal/testconstants.go | 23 ++++++++++++ .../plugins/threshold/decryption_queue.go | 4 +-- .../threshold/decryption_queue_test.go | 10 +++--- go.mod | 4 +-- go.sum | 8 ++--- integration-tests/go.mod | 4 +-- integration-tests/go.sum | 8 ++--- 11 files changed, 91 insertions(+), 31 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index d4c1e87632c..123337d46ff 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -300,8 +300,8 @@ require ( github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect - github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c // indirect - github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a // indirect + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect github.com/spaolacci/murmur3 v1.1.0 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index b190b30678a..5a4331002f2 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1445,10 +1445,10 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SO github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a h1:/ZJnNxcdJ75yDJHnKMjd3G9oZ6lcQRvFUdmiR2DPAgQ= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 h1:AQsTWhkwF/a9Dbv2Y4U4Xi5Go1sflttB0rHL6+8TD6c= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go index b708058be35..1f943dcbf48 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go @@ -62,11 +62,12 @@ func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *te DefaultAggregationMethod: functionsConfig.AggregationMethod_AGGREGATION_MODE, UniqueReports: true, ThresholdPluginConfig: &functionsConfig.ThresholdReportingPluginConfig{ - MaxQueryLengthBytes: 10_000, - MaxObservationLengthBytes: 10_000, - MaxReportLengthBytes: 15_000, - RequestCountLimit: 100, - RequestTotalBytesLimit: 1_000, + // approximately 750 bytes per test ciphertext + overhead + MaxQueryLengthBytes: 70_000, + MaxObservationLengthBytes: 70_000, + MaxReportLengthBytes: 70_000, + RequestCountLimit: 50, + RequestTotalBytesLimit: 50_000, RequireLocalRequestCheck: true, }, } @@ -76,5 +77,5 @@ func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *te utils.CommitWithFinality(b) // validate that all client contracts got correct responses to their requests - utils.ClientTestRequests(t, owner, b, linkToken, registryAddress, registryContract, clientContracts, requestLenBytes, utils.DefaultSecretsUrlsBytes, 3*time.Minute) + utils.ClientTestRequests(t, owner, b, linkToken, registryAddress, registryContract, clientContracts, requestLenBytes, utils.DefaultSecretsUrlsBytes, 1*time.Minute) } diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index a98d4dffca8..522f38e5421 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -47,6 +47,42 @@ func TestIntegration_Functions_MultipleV1Requests_Success(t *testing.T) { utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsBytes, subscriptionId, 1*time.Minute) } +func TestIntegration_Functions_MultipleV1Requests_ThresholdDecryptionSuccess(t *testing.T) { + // simulated chain with all contracts + owner, b, ticker, active, proposed, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) + defer ticker.Stop() + + utils.SetupRouterRoutes(t, b, owner, routerContract, active.Address, proposed.Address, allowListContractAddress) + + _, _, oracleIdentities := utils.CreateFunctionsNodes(t, owner, b, routerAddress, nOracleNodes, maxGas, utils.ExportedOcr2Keystores, utils.MockThresholdKeyShares) + + pluginConfig := functionsConfig.ReportingPluginConfig{ + MaxQueryLengthBytes: 10_000, + MaxObservationLengthBytes: 15_000, + MaxReportLengthBytes: 15_000, + MaxRequestBatchSize: uint32(batchSize), + MaxReportTotalCallbackGas: uint32(maxTotalReportGas), + DefaultAggregationMethod: functionsConfig.AggregationMethod_AGGREGATION_MODE, + UniqueReports: true, + ThresholdPluginConfig: &functionsConfig.ThresholdReportingPluginConfig{ + // approximately 750 bytes per test ciphertext + overhead + MaxQueryLengthBytes: 70_000, + MaxObservationLengthBytes: 70_000, + MaxReportLengthBytes: 70_000, + RequestCountLimit: 50, + RequestTotalBytesLimit: 50_000, + RequireLocalRequestCheck: true, + }, + } + + // config for oracle contract + utils.SetOracleConfig(t, b, owner, active.Contract, oracleIdentities, batchSize, &pluginConfig) + + subscriptionId := utils.CreateAndFundSubscriptions(t, b, owner, linkToken, routerAddress, routerContract, clientContracts, allowListContract) + b.Commit() + utils.ClientTestRequests(t, owner, b, linkToken, routerAddress, routerContract, allowListContract, clientContracts, requestLenBytes, utils.DefaultSecretsUrlsBytes, subscriptionId, 1*time.Minute) +} + func TestIntegration_Functions_MultipleV1Requests_WithUpgrade(t *testing.T) { // simulated chain with all contracts owner, b, ticker, active, proposed, clientContracts, routerAddress, routerContract, linkToken, allowListContractAddress, allowListContract := utils.StartNewChainWithContracts(t, nClients) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go index 146414e4ebf..638adf99871 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testconstants.go @@ -10,6 +10,29 @@ var ( DefaultDONId = "1" DefaultGasPrice = 1_000_000_000 + // Below are the corresponding values for the encrypted threshold keys used in the test + // mockThresholdPubKey := `{"Group":"P256","G_bar":"BAnzIguQNKnA37Zh0b3Z3K5CcvxHjzfTIytt37ZgNQLaTeuiq9rrVhz+yaZcvNQ9EYw978KmmYOq6qd0NA/ERh8=","H":"BOyfKc8aowVjOK2qYf0kdeuLkPeqbjDnjDFGIj/2n7O+qHIvqKx3A07Oa92tP5DkcS5AL/tipXDIBJvVWvcvudk=","HArray":["BBhLQicdsIUgigmIW4l6Xi1jBkFFXEtm2wuvydoZCjZZdlDZt82pXtOI+vPQbd5iawQPX6u4HUrhEisqwhx5P0A=","BLTOIUViwoVJTAzCKIo2FgliIfK7w3jG6wjwf3LVkdsMYJ2ZiEJDA7YC1GwsVgutYdxrwOkAY+wnoh9j+AYF/rQ=","BH2vi5G9ftykpOJARMlziZuZKXSx5YiP131HpwWwsgFAquSpsNTRWHsjk4nc0lcQKf6x9E+7UUQpAPwDpyrh7Xc=","BHQBZMqVRvxQHtnC4tqfh9Qc632IfSCPCBDsePyLzD1nXOf/qJWrCpfsZ3T3PaRm/U30LSgnb1nsuXI9nDuTFsM="]}` + // mockPlaintextThresholdMasterKey := `{"Group":"P256","S":"MTpFRrh8F5mih+92W0l51ZVZIiGJgpHNUXb4vzkzv8A="}` + // mockPlaintextThresholdKeyShares := [][]byte{ + // []byte(`{"PublicKey":{"Group":"P256","G_bar":"BAnzIguQNKnA37Zh0b3Z3K5CcvxHjzfTIytt37ZgNQLaTeuiq9rrVhz+yaZcvNQ9EYw978KmmYOq6qd0NA/ERh8=","H":"BOyfKc8aowVjOK2qYf0kdeuLkPeqbjDnjDFGIj/2n7O+qHIvqKx3A07Oa92tP5DkcS5AL/tipXDIBJvVWvcvudk=","HArray":["BBhLQicdsIUgigmIW4l6Xi1jBkFFXEtm2wuvydoZCjZZdlDZt82pXtOI+vPQbd5iawQPX6u4HUrhEisqwhx5P0A=","BLTOIUViwoVJTAzCKIo2FgliIfK7w3jG6wjwf3LVkdsMYJ2ZiEJDA7YC1GwsVgutYdxrwOkAY+wnoh9j+AYF/rQ=","BH2vi5G9ftykpOJARMlziZuZKXSx5YiP131HpwWwsgFAquSpsNTRWHsjk4nc0lcQKf6x9E+7UUQpAPwDpyrh7Xc=","BHQBZMqVRvxQHtnC4tqfh9Qc632IfSCPCBDsePyLzD1nXOf/qJWrCpfsZ3T3PaRm/U30LSgnb1nsuXI9nDuTFsM="]},"PrivateKeyShare":{"Group":"P256","Index":0,"V":"Jzuh+h/jgm0HIp6iKVJxc/vCUOz7Ea+Y0twvRzJDheg="}}`), + // []byte(`{"PublicKey":{"Group":"P256","G_bar":"BAnzIguQNKnA37Zh0b3Z3K5CcvxHjzfTIytt37ZgNQLaTeuiq9rrVhz+yaZcvNQ9EYw978KmmYOq6qd0NA/ERh8=","H":"BOyfKc8aowVjOK2qYf0kdeuLkPeqbjDnjDFGIj/2n7O+qHIvqKx3A07Oa92tP5DkcS5AL/tipXDIBJvVWvcvudk=","HArray":["BBhLQicdsIUgigmIW4l6Xi1jBkFFXEtm2wuvydoZCjZZdlDZt82pXtOI+vPQbd5iawQPX6u4HUrhEisqwhx5P0A=","BLTOIUViwoVJTAzCKIo2FgliIfK7w3jG6wjwf3LVkdsMYJ2ZiEJDA7YC1GwsVgutYdxrwOkAY+wnoh9j+AYF/rQ=","BH2vi5G9ftykpOJARMlziZuZKXSx5YiP131HpwWwsgFAquSpsNTRWHsjk4nc0lcQKf6x9E+7UUQpAPwDpyrh7Xc=","BHQBZMqVRvxQHtnC4tqfh9Qc632IfSCPCBDsePyLzD1nXOf/qJWrCpfsZ3T3PaRm/U30LSgnb1nsuXI9nDuTFsM="]},"PrivateKeyShare":{"Group":"P256","Index":1,"V":"HTz+rYdK7UBrvU3N91tpEmIrf7hsoM1kVEFlzytTTBA="}}`), + // []byte(`{"PublicKey":{"Group":"P256","G_bar":"BAnzIguQNKnA37Zh0b3Z3K5CcvxHjzfTIytt37ZgNQLaTeuiq9rrVhz+yaZcvNQ9EYw978KmmYOq6qd0NA/ERh8=","H":"BOyfKc8aowVjOK2qYf0kdeuLkPeqbjDnjDFGIj/2n7O+qHIvqKx3A07Oa92tP5DkcS5AL/tipXDIBJvVWvcvudk=","HArray":["BBhLQicdsIUgigmIW4l6Xi1jBkFFXEtm2wuvydoZCjZZdlDZt82pXtOI+vPQbd5iawQPX6u4HUrhEisqwhx5P0A=","BLTOIUViwoVJTAzCKIo2FgliIfK7w3jG6wjwf3LVkdsMYJ2ZiEJDA7YC1GwsVgutYdxrwOkAY+wnoh9j+AYF/rQ=","BH2vi5G9ftykpOJARMlziZuZKXSx5YiP131HpwWwsgFAquSpsNTRWHsjk4nc0lcQKf6x9E+7UUQpAPwDpyrh7Xc=","BHQBZMqVRvxQHtnC4tqfh9Qc632IfSCPCBDsePyLzD1nXOf/qJWrCpfsZ3T3PaRm/U30LSgnb1nsuXI9nDuTFsM="]},"PrivateKeyShare":{"Group":"P256","Index":2,"V":"Ez5bYO6yWBPQV/z5xWRgsMiUroPeL+sv1aacVyRjEjg="}}`), + // []byte(`{"PublicKey":{"Group":"P256","G_bar":"BAnzIguQNKnA37Zh0b3Z3K5CcvxHjzfTIytt37ZgNQLaTeuiq9rrVhz+yaZcvNQ9EYw978KmmYOq6qd0NA/ERh8=","H":"BOyfKc8aowVjOK2qYf0kdeuLkPeqbjDnjDFGIj/2n7O+qHIvqKx3A07Oa92tP5DkcS5AL/tipXDIBJvVWvcvudk=","HArray":["BBhLQicdsIUgigmIW4l6Xi1jBkFFXEtm2wuvydoZCjZZdlDZt82pXtOI+vPQbd5iawQPX6u4HUrhEisqwhx5P0A=","BLTOIUViwoVJTAzCKIo2FgliIfK7w3jG6wjwf3LVkdsMYJ2ZiEJDA7YC1GwsVgutYdxrwOkAY+wnoh9j+AYF/rQ=","BH2vi5G9ftykpOJARMlziZuZKXSx5YiP131HpwWwsgFAquSpsNTRWHsjk4nc0lcQKf6x9E+7UUQpAPwDpyrh7Xc=","BHQBZMqVRvxQHtnC4tqfh9Qc632IfSCPCBDsePyLzD1nXOf/qJWrCpfsZ3T3PaRm/U30LSgnb1nsuXI9nDuTFsM="]},"PrivateKeyShare":{"Group":"P256","Index":3,"V":"CT+4FFYZwuc08qwlk21YTy793U9Pvwj7VwvS3x1y2GA="}}`), + // } + // Since the threshold public keys are encrypted with each node's public OCR2 offchain config key, the OCR2 offchain config key must be known in advance instead of regenerated every time. + ExportedOcr2Keystores = [][]byte{ + []byte(`{"keyType":"OCR2","chainType":"evm","id":"d8d0363c218526d809b8570257e7822bfde559ed532fa976118fc2d994155e55","onchainPublicKey":"e1deb8516367e7715da19134d58528778d6aff04","offchainPublicKey":"91c021d592ae5949eafaf4b74d622b13ac5784db7de9591755c3d3d2ed7a19b4","configPublicKey":"677c7ba4487eabea0f3341a095b94b6f56a1df97a165e49b8b0a7864c0f66077","crypto":{"cipher":"aes-128-ctr","ciphertext":"6d111479822c5b6e5a2b5ebde4f7ab6e6f7809e07bf6451d416f5e3082833a3b34e9aa820658c03487a3bdde5cbbfff3198a951f36a5ef91d1274211273f7af2e3e17e258530c25aebb1099395ecc1d96e567adefa727f06fcb61d0df2829737998bdd959759c62342fbd74a3f231535bb413d9c4479e33ff294d66bfc90d2b6db9d12250ef8daab309bb914373a76da24e82dce5b0da428a19efc1cdda48719f898a91f21b4fc89458d126d1023ffc0efcc8cf3e0ee249bfa0b1b55fa151d5c2630be21be2ea27964b82816ee72885f7bc59d7d4157d5333ab8324cc65a78581437a8600e8c044fabe80ae76cbe39ae332c5c0f85ac1090b13a1525caca40459082e9ca762714e50543e6aa907b7286eafc93a51c2d67265393d86ad83d431bf068aa006c36f63356","cipherparams":{"iv":"11b7b2f3c33dfff2a3125fdb10048601"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":2,"p":1,"r":8,"salt":"a3c5952aa41720097a50fea6957c994a9c39cb1dbe7bd59cff5b9354633836c1"},"mac":"df6d0d0b5f2cc95f1e1d4c9894f8487c56b814ca55d10e520d0c44e91d699012"}}`), + []byte(`{"keyType":"OCR2","chainType":"evm","id":"03a0713ffb5b506cbf12bd59fd7023c9dc3f1f56d4d2f9ed564f0361c3aa1119","onchainPublicKey":"3203c6923adc7ecff671e00632eb350fa354e957","offchainPublicKey":"c9aea40c0e5f13d9704d3051faa01718f1d4aa1419d3e6199f7deacee56a596e","configPublicKey":"23ccc8500fa3af447c7a8b3aa4e41ad7b34f6585bdc3e8c847c7ff12a8caa818","crypto":{"cipher":"aes-128-ctr","ciphertext":"5aa58bfd17209a4c9da966a1b175c74137536531ada19507434d6dbf146d71516c0ed2b52b5e664e69c4286a56f38be322206a33eacfaa854be313bade3b5876e5b40aec5be4dca761749b535ad9cd1575897d6736eb96fb9e118eb696c44d111b81757bd73a6d33c170febaf57705590f279625ec536d1656eac96a953de915693a9cd040a5d5948f3b288ebdbb178c955b5f0faa432d68e744f39dc621cbc4c5853627addc3dd2ed5e1ba4a514278d56d0cdef2e57688ad0752f3077656f16fa3144c33f3ed96ebdeb3009139f327d6c12d344a047147e71a95d5b08582bd8ee86c86e308d81f16357c79b50a48041994d98490a4b9d965525187901a2862d41bcc6822046f99ad481ae104aa75b816c5abac876bce0b07b2b73bb459830a5bc70f20c34b87ed6fc","cipherparams":{"iv":"d8fcf50fff54dfa082d40c0de90b6ab4"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":2,"p":1,"r":8,"salt":"64ba7faf39b49c46d5360109ef23e3f4198a3f402cbb975686fe4b52cc7c0b1f"},"mac":"09520656cc08b5743f95d386a5b7c3d164ecaa2002a0b83f2cd8d44c97d99b8a"}}`), + []byte(`{"keyType":"OCR2","chainType":"evm","id":"ace8972c126601fdc5f9ed42c909a57d2a19dff2be7ce341913c01a4921c829f","onchainPublicKey":"d8699a99d2a3ab4ccfc61bc7df72b30605a05b7c","offchainPublicKey":"9c1fa3ce9d355a73ce2dcdece70e7314af8da13f5ca30ee251dbed201dc904ed","configPublicKey":"9a2b9087af305c187d1292842072e50d2c4e98cb4e26c6328021fdd992e78926","crypto":{"cipher":"aes-128-ctr","ciphertext":"c7d2da9c60779ad33dce870b1f8af94082dfdfe51d4f04f27cf505bba21b17e287c685880614e22df92ce7549230e8b1a327de0686d892f5c4dda546132b044bde2a58d60bf335931b78e42342e2578e54111592cad4301d22c192c87809e3cef6e6dd1a30a7a208c78461154d856213466c1afad4023001c1b45fdf7804c6a9a4eb64ac1ea59775a1e694c79fc492b4d7422cd777778549c817e735e8e5e5f45aea9c9e9a5a7ff1c71b7879af120a4aa467a3ac0cdb1ba04f893283cad533c4ac9723969a64bbfd69bb7ef88d88d8d96c5293fee35c14a00a8e6c0cb2e7cfa918d05ec9e092e4fdad2a41edf7a1cb9e1a1a12ec6fbb594eb1e07d5dbb79eda390b826aa7ca8ccfda1cee9c125eb8a1d07d9e899cf6e9c1ec0fd40d83a50656674cc5c9d0a88710c65","cipherparams":{"iv":"5b6fca38ff8c03e38fb6f56f9d90fe8d"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":2,"p":1,"r":8,"salt":"6bfc5f03e8bd10efea3808d025c5769a49ade8bee6c608d713a6bf3f940a37ba"},"mac":"e1e4bcbe67a80d73ee12c8080ddd99bba9ca8774349a9cb5c5b9821983e460ca"}}`), + []byte(`{"keyType":"OCR2","chainType":"evm","id":"5b09af3b5a5a420436fa206eb266b6a4d796406030d022d4beaf6609e9da9274","onchainPublicKey":"c27e7957c243e061cc17d8f30e8f894280235499","offchainPublicKey":"f6c2fd84bb73252d49852b50420f5983b488609d9f73ef601e7641df24794dec","configPublicKey":"45a96a32b7339cd22da1a1c42c2ee71e698dd7dfbe7fd997949f1cdb3f2ba518","crypto":{"cipher":"aes-128-ctr","ciphertext":"f842a872d8a0033fc9b91673a1c2f095eda18c4716b53c743d04b82710f2bfa2c950356e50ea085b05975c36176a3dd2b10901508f297e3ff966cde02cf6ba077eebdb8708117c4c9f4498358e74fdc98bc1130a32bfa6bf8f46d9ea77d4e56952cc1ccbbf2bde05a48acf13fbb238675d640b6a74af70dfbaa63cad57108480238ce946a5af5f60b09794ff5b40bde982f32d7b48f5e9a51830a46cce1cf2f9a0c0ec220c062eb90602b2abbaf2a6a2da2d8b3dbc211db17d599789654a2a26f1fad52e22d7eed91365ce7d964731936307c39e66bd9a9ffc999f3174317786077ab83224d06e025b7de5974293b96eabcb3b9ffb17d2d0b49743cd7b4f1b222e32be3f32b9d2177b1c20cb7d56c10ae0789f8586ee99ccd9ac8b626df058b454686b2d8a663635b8","cipherparams":{"iv":"21a5417a99f37507bc2fbdda83c5856f"},"kdf":"scrypt","kdfparams":{"dklen":32,"n":2,"p":1,"r":8,"salt":"c98ac207e897658d7c42029c2858ba29f03abe9298745b0b909377085806895a"},"mac":"dc1ef1c284e1d001b63f1d545e308c4ef194757605a4b57b8c565c5c40e64146"}}`), + } + // Threshold key shares have been generated with the Functions admin tooling (https://github.com/smartcontractkit/functions-admin-tooling/tree/main/threshold_key_manager) + MockThresholdKeyShares = []string{ + "40e99151aaa2002631cfdac741a0f206b9ebc492a2c5bd56deac64118148df6e3829a6f81b6df54694ca241f5bc12fd2b58bce9106767f4adbf7250e0a033386b56eb93159c3cf14748b6a0d1996a51039ce9ff98acaba758913fa2d671e86b909edbe27bdf441b68be2c2debbe8a29d814a04accd996b4df0fa8e0cea65ef47922c4aca8132fe4f2d6def9c4683b031267f60ccf896b6bf6b1957786deafebb5bc1663778ee893511306dda7833d01efe0d63224d0da0cea6d728953793e6b3e97f81cb64f80ed4ff4f3c349b90f11290adb0eff07f8ccb9b97d098903ce194f33f284d38832e12902354c3cda72189b3ac31b8206575391c1618dee6530b99fc60d667052e0065365842176b6b5d9b779be0be4f7fa27115d65e08d01f13db695581c1be4a1f96b980cba45bd528aaee23809fa9a601a229c7018eb6755f43a0d38125a872fcf8e109ca92abc55348cccc4f83beae8412425570b8aa9b6526a9ddd05a41e5c6d6865cf91ff1912490d67e6a99c3a91db433120b13768affef6b0cdeb33d085078fa27b90ef2663c69fcf9f3dad9a1fb67b9605f035b2cebf7808801e9ccd3eb83015aaefecf1fa97674923219c543accdc23d5f624cdbd673eba5f29cc66c647e1fe454e0c73efe8ff6605f78243e01aa42c14241f890388d6d35e3071ee89130f62317b8d624fc2b7c270769cf8e5c054cf3ed4163917f0af7372ab0eafdc4dd4faaf3cc30d406041404eae2ba942c800e4d9726e8e0d27e1488c5aaf47d977665c86d8574c17b69c8b31783ec479929e6b858ef57b072bcfaa3a747362235e142e9b73f19192d8878b832ff25b8cf29f0b5c130cb1d505ec1830a0901c0ac1f9b5542db33a9c39afc6ffa68d32a91dbb525cec9536647020cd22925baf63d173cd9b377fbcb509efcbf7830df459e080f5794186d628be938e9a53d3ea3182eb328d9956905dc6c22061c76118b208cdd7f063522d81ab4e404ef6d4a53b2099d2c94b8c05526b8367cfff6f08340bbe53cf2fbe6e7fae3b7062d27722085", + "9956a87c447eb15b82906742ef84980ca1dc6846b2234468ed7399af5392243b14226ab2a6ff6220776d1b5a591cacfde0bd583f48683d4f38186300f919681aa0a886e7eddc556e1bb434c18994df214a5b6fe4bfcb09ae9fc5dba4cb7e027ce01121dbad0621fe35311e1015c7d4d006ababd5c7377a0f70aecafaf3f709c0571ca2dd89b6cd83867bd299e8ce01e04ecafc1230ab0aeb2812a693fadcba7b479a00da357e75876d0cd2a3d85774e056d63436623ff400c9fd76446f5b7fd90902bf4d4268fb5775e326a887bd59136692bb5b0400790dd7908f9d5c7e422c76831ac3876e67a8b6d66ceb49c9c0835660bbd90a1e18ab8486dc464b6fd4044c580d3082842ab655169cf46abe25ad4de04d0bdefc74fee9c2009b43eea48f976a449ceb805993383b06ddfaf5a3df112a1c5e72ea121b9fbeafe8b7666500abeb52f2bad6035295b66994c0d239ced38f32af4df161b7bd66886703c050531173ae6ace942a311a0077b601c025bb59a78b43558c09ae55a6ce70d408b7e0ae439542971b33fdf14a7c5a36fed8d310e8cd08fe7c6b45d1bffd351bad2fd1cfc8d964f8ec39db82a7fd4095771f6d5e84516598364bd0532d3b8ccd660fa73bc1e5840087eeac18c7fd52611deac5aa50a6a033d2aecd79ec8bba8045615ff4d7b77e0d087110b888426d138107236ed4a6a6b6a5b51e54149e2272896d0180a46cde8955a8adeb969c35c5b58a0958ce955f2634723d8bf38c2d1c3efe0ce2494b00947d3958ec3b5b9f5445acad30296a34060bd688c7b91e818f49ddfa560541682ce0ff6d245b9df5adee989ea6b9eedcf58b3d47fdc64e8c046efaad51e169a81fc22419be8666897f18d7c913d806764714c9a735cce3698da8ecb3b16c1a88f6ef2b4a52686d4d1b5cfc5859422a1b39f7fe46691ccd28050a8edf040f438b407bfa4cc48641155e3c7531301d5192148ab2ccba064afeed1ae8723702ea9793317a1989a2601a958fda5bb23222a983842a31553930c4364b661e03376fff2471ae", + "4c19996b1ed254aba3f5d36a24a3a24a008cc864562610e15523087c2c05e63c57bc6c386d4f1b3cb53eb10ae26ab594a6693fa8ee5783ab4b4b040a0e4f27beda68405b72cbcbeee762114b23d1fe69aaf72bc81f70e76251df20b83fe6b82240fbe64be3b1a238bf3c5a8b7c8bac945fd25348b5618ff2409940f64bd86afb64695706c57340e72741af4e0d2d47407b041c57aac7ba9d35ce2316d6bff28ee5c22b007ec2c9b5914cb5baaa9e2ce6aafeb976c681dc08e1eb28514a7b7adfa0536ced06e3e23e9a14bad3f68b836442a952c39bfcaabdae0d3226dde590f3ba927b49a0c6f011b02abd14e5db8bf355432e3d3286c9aa5fcf2b6620cda13d56753a420555d0300de04c008d6cb9b62e4c7c44ea563445cccfc8266b06192c2981ce5b1157b6c16ca38e6b7036dd2e21e75646bbffc0be2f6c23257666a5679b8e35ac4382e31c05e4ef1170293617e6f77bd32b57f5ac617a7cbafa345c2137d8a7b70bf4a3b5c4010d73e7f064a9e5e51eaecf600bb837e0a648359aa4857b0875f14a62c648e7a7a13fac7e466bdd9ac89cf7f1f46081f5d107a6fffa5a0d8c70aa5aeaed3df35e9a5b33cabb98b22bf62d84cf4e57d7683457dbff3542a9299f9acd291225e4e8fc1255b305ca0e1404707053e50d55f69d8b709d9350db4f6f36ecf63037c6e00073df67b610c322e79ae4616314dc47d296b4570b659c21d659375fd1006af4d42838eb20f1682ffd19cf88b603790005b8c5ae4ab9c0415bcb0c8ce4a04d1f7d18fef5e16e9061aa56bc596bcdeae74ccdd1c95ab1607280602f75ddbb3a25cbe9af99197b0dab671a2e1069340cefcefef75e24e222c9e3d1563634eb3f3a8319bfd6f95b3a995d9dcad5a9aa2aea6bf46e6253080d8e4ec3b918d0012fe500edfba67e49d0520be57e7414629bb40e64312fb1d3e26bdef31cc8ec2426f71f91cfee0d3cd9390dceafe615106fd56703b85b377b812b8a6c24c9fc5d0c68464565d9b421a4cd296f00ddd7a062ea16c56232a4d2a69c2817bfa882", + "ba1edea16bd7223b3a413af6b392662b9b01eb18f67d41defe1cc4190160cf12c462414df90299b0ca5fbe7e2cf11f902a23de8340d9a190f32de0199ce150f15c6ed658638fe33701e3cee11574865efe768ecefd53ba20833e1300d4cc84bf0291852031fe5ce6b7dbd1bfe46d6887e39b6466b6ef76cd5743349c4109176bd0e60074bb7d8ba1cf47609b628045ed64743be510d90a21b7022f88a08dcabd7bc600c26b228b94ee175268f8206df72f7a708c014d162231e9009af0acacfb115674eb6fbb873e0c47b7b66820c7999143da38a871610614c8fe45a0c0d83020ed7c1e3eb5ee14e3e3bf70917a7d7a96e356e52c3bb33607448f61f592142de315fd29a172ce686b028c47cfb936780e1beebbbd2fca706534060e8d7f2de973005229183cd5ceaef3ceb944ca98562f22deec110ff6993ff9512f9b8e1aac17c08fa0295315229596a87eb0935e9b28ff1aff4d71889fed76fa7021e3494155b3b34f28cf5e717b46351bd9b11b0ddceac9ff3bd0c962ac003f5062acdb50058d50546d71fbb50e21221addd61a36f9ef98611f77d1c3c3ecc344fcdd9008d37ebe15944375ab767b1f937cb647dea26d7c6c8f9832b4f8632febba8abb107c39ba85ce09719eb7d7607ca6d0cc491419f6d3863e5d6f446a3c291da01c16e58e65b4428f8e0c024df391e6864e879bfc749d9175654c04413cbe4a65a35cea5596d6dc2d81800b2458fc75bfec6fedbbba857c24a19a0e747dc1d089b9eebb9b5098b2bcd2720f52d28055611ceb7b26d0c4b2a20c3b3aa9da50872bd95ef8154d6fd28669ffb48792e234a6f8eba3e53b57d994b8efd594045e0b6afb764013c28a23934a1502d0a90fe853e0a95738f1cdff79c7ee4e91d57824cd5cea56e8a45d95ee0cb1fa8911ccbd1e14883873817109f9ca4d21be60e3966541d1e1aaa7de0a57a3437f8a24e41a941d20f03055cd74f4b3048d2d9da7406da46ea82b65fd7b18e9004474583ecc9a2759b12fdd770f47222ef2c02d42ed0d18837a3e259f009d1e", + } // This has been generated using the Functions Toolkit (https://github.com/smartcontractkit/functions-toolkit/blob/main/src/SecretsManager.ts) and decrypts to the JSON string `{"0x0":"qrvM"}` DefaultThresholdSecretsHex = "0x7b225444483243747874223a2265794a48636d393163434936496c41794e5459694c434a44496a6f69533035305a5559325448593056553168543341766148637955584a4b65545a68626b3177527939794f464e78576a59356158646d636a6c4f535430694c434a4d59574a6c62434936496b464251554642515546425155464251554642515546425155464251554642515546425155464251554642515546425155464251554642515545394969776956534936496b4a45536c6c7a51334e7a623055334d6e6444574846474e557056634770585a573157596e565265544d796431526d4d32786c636c705a647a4671536e6c47627a5256615735744e6d773355456855546e6b7962324e746155686f626c51354d564a6a4e6e5230656c70766147644255326372545430694c434a5658324a6863694936496b4a4961544e69627a5a45536d396a4d324d344d6c46614d5852724c325645536b4a484d336c5a556d783555306834576d684954697472623264575a306f33546e4e456232314b5931646853544979616d63305657644f556c526e57465272655570325458706952306c4a617a466e534851314f4430694c434a46496a6f694d7a524956466c354d544e474b307836596e5a584e7a6c314d6d356c655574514e6b397a656e467859335253513239705a315534534652704e4430694c434a47496a6f69557a5132596d6c6952545a584b314176546d744252445677575459796148426862316c6c6330684853556869556c56614e303155556c6f345554306966513d3d222c2253796d43747874223a2253764237652f4a556a552b433358757873384e5378316967454e517759755051623730306a4a6144222c224e6f6e6365223a224d31714b557a6b306b77374767593538227d" ) diff --git a/core/services/ocr2/plugins/threshold/decryption_queue.go b/core/services/ocr2/plugins/threshold/decryption_queue.go index 415079a8cb8..957db4b9caf 100644 --- a/core/services/ocr2/plugins/threshold/decryption_queue.go +++ b/core/services/ocr2/plugins/threshold/decryption_queue.go @@ -171,7 +171,7 @@ func (dq *decryptionQueue) GetRequests(requestCountLimit int, totalBytesLimit in dq.pendingRequestQueue = removeMultipleIndices(dq.pendingRequestQueue, indicesToRemove) - dq.lggr.Debugf("returning first %d of %d total requests awaiting decryption", requestCountLimit, len(dq.pendingRequestQueue)) + dq.lggr.Debugf("returning first %d of %d total requests awaiting decryption", len(requests), len(dq.pendingRequestQueue)) return requests } @@ -200,7 +200,7 @@ func (dq *decryptionQueue) GetCiphertext(ciphertextId decryptionPlugin.Ciphertex return req.ciphertext, nil } -func (dq *decryptionQueue) SetResult(ciphertextId decryptionPlugin.CiphertextId, plaintext []byte) { +func (dq *decryptionQueue) SetResult(ciphertextId decryptionPlugin.CiphertextId, plaintext []byte, err error) { dq.mu.Lock() defer dq.mu.Unlock() diff --git a/core/services/ocr2/plugins/threshold/decryption_queue_test.go b/core/services/ocr2/plugins/threshold/decryption_queue_test.go index a81b5a9b075..573682649e2 100644 --- a/core/services/ocr2/plugins/threshold/decryption_queue_test.go +++ b/core/services/ocr2/plugins/threshold/decryption_queue_test.go @@ -32,7 +32,7 @@ func Test_decryptionQueue_Decrypt_ReturnResultAfterCallingDecrypt(t *testing.T) go func() { waitForPendingRequestToBeAdded(t, dq, []byte("1")) - dq.SetResult([]byte("1"), []byte("decrypted")) + dq.SetResult([]byte("1"), []byte("decrypted"), nil) }() ctx, cancel := context.WithCancel(testutils.Context(t)) @@ -207,7 +207,7 @@ func Test_decryptionQueue_Decrypt_DecryptCalledAfterReadyResult(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(2, 1000, 64, testutils.WaitTimeout(t), lggr) - dq.SetResult([]byte("9"), []byte("decrypted")) + dq.SetResult([]byte("9"), []byte("decrypted"), nil) ctx, cancel := context.WithCancel(testutils.Context(t)) defer cancel() @@ -223,7 +223,7 @@ func Test_decryptionQueue_ReadyResult_ExpireRequest(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(2, 1000, 64, 100, lggr) - dq.SetResult([]byte("9"), []byte("decrypted")) + dq.SetResult([]byte("9"), []byte("decrypted"), nil) waitForCompletedRequestToBeAdded(t, dq, []byte("9")) @@ -238,7 +238,7 @@ func Test_decryptionQueue_Decrypt_CleanupSuccessfulRequest(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(2, 1000, 64, testutils.WaitTimeout(t), lggr) - dq.SetResult([]byte("10"), []byte("decrypted")) + dq.SetResult([]byte("10"), []byte("decrypted"), nil) ctx1, cancel1 := context.WithCancel(testutils.Context(t)) defer cancel1() @@ -418,7 +418,7 @@ func Test_decryptionQueue_Close(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(4, 1000, 64, testutils.WaitTimeout(t), lggr) - dq.SetResult([]byte("14"), []byte("decrypted")) + dq.SetResult([]byte("14"), []byte("decrypted"), nil) err := dq.Close() diff --git a/go.mod b/go.mod index 41134ed574a..338c20ad0ad 100644 --- a/go.mod +++ b/go.mod @@ -74,8 +74,8 @@ require ( github.com/smartcontractkit/ocr2keepers v0.7.5 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb - github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c - github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 github.com/smartcontractkit/wsrpc v0.7.2 github.com/spf13/cast v1.5.1 github.com/stretchr/testify v1.8.4 diff --git a/go.sum b/go.sum index a193d5a6bd7..5dc46c5fdd8 100644 --- a/go.sum +++ b/go.sum @@ -1450,10 +1450,10 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SO github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a h1:/ZJnNxcdJ75yDJHnKMjd3G9oZ6lcQRvFUdmiR2DPAgQ= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 h1:AQsTWhkwF/a9Dbv2Y4U4Xi5Go1sflttB0rHL6+8TD6c= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 7cd38836ebb..0a0008a7174 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -383,8 +383,8 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect - github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c // indirect - github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a // indirect + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 // indirect github.com/smartcontractkit/wasp v0.2.7 // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 47500474e61..03300e2fae4 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2256,10 +2256,10 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SO github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c h1:B7jWegIHCHXY32qWGwlNalrJYSz4uZh5zAgd2rQ3Iyc= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230616141813-ca0ecf03ca5c/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a h1:/ZJnNxcdJ75yDJHnKMjd3G9oZ6lcQRvFUdmiR2DPAgQ= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230625174811-4934857d1c4a/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 h1:AQsTWhkwF/a9Dbv2Y4U4Xi5Go1sflttB0rHL6+8TD6c= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wasp v0.2.7 h1:9SZ1grPvoNDpxCcQgQi917ifXrjt5JhV/J978HkD0d4= github.com/smartcontractkit/wasp v0.2.7/go.mod h1:gS2oenc6VEGfewgeqDpVFOSrCZIZX10rVl1PAo+vsxc= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= From 33f4e1a852da99f3a58f2b834533c495d095f874 Mon Sep 17 00:00:00 2001 From: Patrick Date: Tue, 8 Aug 2023 16:23:16 -0400 Subject: [PATCH 116/270] fix/changelog-simple-passwords: adding notification for upcoming breaking change wrt simple passwords in 2.5 (#10110) --- docs/CHANGELOG.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index b586518787d..a34a7ae34cd 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -19,6 +19,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Added - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. +### Upcoming Breaking Change +- Starting in 2.5.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: +``` +AllowSimplePasswords=true +``` +- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to RFC 3986 for special character escape rules. + ## 2.3.0 - 2023-07-28 From 5aeb3ab6fdbf723231c2e572c6f441c41e17a959 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Tue, 8 Aug 2023 16:51:18 -0500 Subject: [PATCH 117/270] bump chainlink-relay for grpc proxy (#9996) --- core/scripts/go.mod | 7 ++++++- core/scripts/go.sum | 15 +++++++++++++-- go.mod | 7 ++++++- go.sum | 15 +++++++++++++-- integration-tests/go.mod | 6 +++++- integration-tests/go.sum | 9 +++++++-- 6 files changed, 50 insertions(+), 9 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 123337d46ff..ef34d7c9432 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -266,6 +266,7 @@ require ( github.com/multiformats/go-multihash v0.0.14 // indirect github.com/multiformats/go-multistream v0.2.0 // indirect github.com/multiformats/go-varint v0.0.6 // indirect + github.com/mwitkow/grpc-proxy v0.0.0-20230212185441-f345521cb9c9 // indirect github.com/oklog/run v1.1.0 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/opencontainers/image-spec v1.1.0-rc3 // indirect @@ -297,7 +298,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect @@ -384,4 +385,8 @@ replace ( // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + + // until merged upstream: https://github.com/mwitkow/grpc-proxy/pull/69 + github.com/mwitkow/grpc-proxy => github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 + ) diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 5a4331002f2..3fc15fa2680 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -512,6 +512,7 @@ github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QD github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= @@ -811,6 +812,8 @@ github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJS github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= +github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 h1:CAa5/6QLk2AAgTlqMPfPRkf0ebjtPYoJFhTqe7zJaXs= +github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= @@ -1431,8 +1434,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea h1:k2o+ta3tJgyiDKvkeI6yKA2ZMPG6kCrNc+NdSgU00BI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea/go.mod h1:9w55r3WyiwZSsPfn7xyJj3F0N3IWiI9czehsn4o4xGQ= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a h1:8lHQYdub7q3LgD5ebQOA+usDyUqqiHvKEJPGQ8+FxMA= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a/go.mod h1:Nt4mQh6z6q26jrM4FyQLq/2vBp1Sg3l5md3tBRdRLxg= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= @@ -1806,6 +1809,8 @@ golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwY golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= +golang.org/x/net v0.0.0-20210331212208-0fccb6fa2b5c/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210423184538-5f58ad60dda6/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= @@ -1914,7 +1919,10 @@ golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210331175145-43e1dd70ce54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -2131,6 +2139,7 @@ google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210401141331-865547bb08e2/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130 h1:Au6te5hbKUV8pIYWHqOUZ1pva5qK/rwbIhoXEUB9Lu8= google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130/go.mod h1:O9kGHb51iE/nOGvQaDUuadVYqovW56s5emA88lQnj6Y= @@ -2160,6 +2169,7 @@ google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTp google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.56.2 h1:fVRFRnXvU+x6C4IlHZewvJOVHoOv1TUuQyoRsYnB4bI= @@ -2237,6 +2247,7 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= +honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= lukechampine.com/uint128 v1.1.1/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= lukechampine.com/uint128 v1.2.0 h1:mBi/5l91vocEN8otkC5bDLhi2KdCticRiwbdB0O+rjI= lukechampine.com/uint128 v1.2.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= diff --git a/go.mod b/go.mod index 338c20ad0ad..4aa072e0ff6 100644 --- a/go.mod +++ b/go.mod @@ -67,7 +67,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 @@ -302,6 +302,7 @@ require ( github.com/multiformats/go-multihash v0.0.14 // indirect github.com/multiformats/go-multistream v0.2.0 // indirect github.com/multiformats/go-varint v0.0.6 // indirect + github.com/mwitkow/grpc-proxy v0.0.0-20230212185441-f345521cb9c9 // indirect github.com/oklog/run v1.1.0 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/opencontainers/image-spec v1.1.0-rc3 // indirect @@ -381,4 +382,8 @@ replace ( // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + + // until merged upstream: https://github.com/mwitkow/grpc-proxy/pull/69 + github.com/mwitkow/grpc-proxy => github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 + ) diff --git a/go.sum b/go.sum index 5dc46c5fdd8..e778078b31a 100644 --- a/go.sum +++ b/go.sum @@ -510,6 +510,7 @@ github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QD github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.4.3/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= +github.com/golang/protobuf v1.5.1/go.mod h1:DopwsBzvsk0Fs44TXzsVbJyPhcCPeIwnvohx4u74HPM= github.com/golang/protobuf v1.5.2/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= @@ -813,6 +814,8 @@ github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJS github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= +github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 h1:CAa5/6QLk2AAgTlqMPfPRkf0ebjtPYoJFhTqe7zJaXs= +github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= @@ -1436,8 +1439,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea h1:k2o+ta3tJgyiDKvkeI6yKA2ZMPG6kCrNc+NdSgU00BI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea/go.mod h1:9w55r3WyiwZSsPfn7xyJj3F0N3IWiI9czehsn4o4xGQ= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a h1:8lHQYdub7q3LgD5ebQOA+usDyUqqiHvKEJPGQ8+FxMA= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a/go.mod h1:Nt4mQh6z6q26jrM4FyQLq/2vBp1Sg3l5md3tBRdRLxg= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= @@ -1812,6 +1815,8 @@ golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwY golang.org/x/net v0.0.0-20201209123823-ac852fbbde11/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= +golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= +golang.org/x/net v0.0.0-20210331212208-0fccb6fa2b5c/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210423184538-5f58ad60dda6/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= @@ -1920,7 +1925,10 @@ golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210331175145-43e1dd70ce54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -2138,6 +2146,7 @@ google.golang.org/genproto v0.0.0-20201210142538-e3217bee35cc/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20201214200347-8c77b98c765d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210108203827-ffc7fda8c3d7/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210226172003-ab064af71705/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= +google.golang.org/genproto v0.0.0-20210401141331-865547bb08e2/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130 h1:Au6te5hbKUV8pIYWHqOUZ1pva5qK/rwbIhoXEUB9Lu8= google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130/go.mod h1:O9kGHb51iE/nOGvQaDUuadVYqovW56s5emA88lQnj6Y= @@ -2167,6 +2176,7 @@ google.golang.org/grpc v1.33.1/go.mod h1:fr5YgcSWrqhRRxogOsw7RzIpsmvOZ6IcH4kBYTp google.golang.org/grpc v1.33.2/go.mod h1:JMHMWHQWaTccqQQlmk3MJZS+GWXOdAesneDmEnv2fbc= google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA51WJ8= google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= +google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.37.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.56.2 h1:fVRFRnXvU+x6C4IlHZewvJOVHoOv1TUuQyoRsYnB4bI= @@ -2243,6 +2253,7 @@ honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWh honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= +honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= lukechampine.com/uint128 v1.1.1/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= lukechampine.com/uint128 v1.2.0 h1:mBi/5l91vocEN8otkC5bDLhi2KdCticRiwbdB0O+rjI= lukechampine.com/uint128 v1.2.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 0a0008a7174..0be03fbf238 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -339,6 +339,7 @@ require ( github.com/multiformats/go-varint v0.0.6 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect + github.com/mwitkow/grpc-proxy v0.0.0-20230212185441-f345521cb9c9 // indirect github.com/oklog/run v1.1.0 // indirect github.com/oklog/ulid v1.3.1 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect @@ -379,7 +380,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect @@ -502,6 +503,9 @@ replace ( // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + // until merged upstream: https://github.com/mwitkow/grpc-proxy/pull/69 + github.com/mwitkow/grpc-proxy => github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 + github.com/prometheus/prometheus => github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2 github.com/sercand/kuberesolver v2.4.0+incompatible => github.com/sercand/kuberesolver/v5 v5.1.0 ) diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 03300e2fae4..094980fff81 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1521,6 +1521,8 @@ github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJS github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= +github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 h1:CAa5/6QLk2AAgTlqMPfPRkf0ebjtPYoJFhTqe7zJaXs= +github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= @@ -2240,8 +2242,8 @@ github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb2 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea h1:k2o+ta3tJgyiDKvkeI6yKA2ZMPG6kCrNc+NdSgU00BI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230803135212-d96fd6cc63ea/go.mod h1:9w55r3WyiwZSsPfn7xyJj3F0N3IWiI9czehsn4o4xGQ= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a h1:8lHQYdub7q3LgD5ebQOA+usDyUqqiHvKEJPGQ8+FxMA= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a/go.mod h1:Nt4mQh6z6q26jrM4FyQLq/2vBp1Sg3l5md3tBRdRLxg= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= @@ -2687,6 +2689,7 @@ golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210119194325-5f4716e94777/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= +golang.org/x/net v0.0.0-20210331212208-0fccb6fa2b5c/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210410081132-afb366fc7cd1/go.mod h1:9tjilg8BloeKEkVJvy7fQ90B1CfIiPueXVOjqfkSzI8= golang.org/x/net v0.0.0-20210421230115-4e50805a0758/go.mod h1:72T/g9IO56b78aLF+1Kcs5dz7/ng1VjMUvfKvpfy+jM= @@ -2847,6 +2850,7 @@ golang.org/x/sys v0.0.0-20210305230114-8fe3ee5dd75b/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210330210617-4fbd30eecc44/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210331175145-43e1dd70ce54/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210420072515-93ed5bcd2bfe/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -3160,6 +3164,7 @@ google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210329143202-679c6ae281ee/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= +google.golang.org/genproto v0.0.0-20210401141331-865547bb08e2/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= google.golang.org/genproto v0.0.0-20210513213006-bf773b8c8384/go.mod h1:P3QM42oQyzQSnHPnZ/vqoCdDmzH28fzWByN9asMeM8A= google.golang.org/genproto v0.0.0-20210602131652-f16073e35f0c/go.mod h1:UODoCrxHCcBojKKwX1terBiRUaqAsFqJiF615XL43r0= From e2df35865f48dfdeabb0e8328006fda7517645fd Mon Sep 17 00:00:00 2001 From: Damjan Smickovski <32773226+smickovskid@users.noreply.github.com> Date: Wed, 9 Aug 2023 11:05:55 +0200 Subject: [PATCH 118/270] Fixed typo for starknet and solana (#10112) * Fixed typo for starknet and solana * Rebasing * Removed newline --- integration-tests/client/chainlink.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/integration-tests/client/chainlink.go b/integration-tests/client/chainlink.go index ffda44c3148..28c060f1ef3 100644 --- a/integration-tests/client/chainlink.go +++ b/integration-tests/client/chainlink.go @@ -27,8 +27,8 @@ var ( OneLINK = big.NewFloat(1e18) mapKeyTypeToChain = map[string]string{ "evm": "eTHKeys", - "solana": "encryptedStarkNetKeys", - "starknet": "encryptedSolanaKeys", + "solana": "encryptedSolanaKeys", + "starknet": "encryptedStarkNetKeys", } ) From 82e81bd81d4f74b7d0261088782aa3db4711b538 Mon Sep 17 00:00:00 2001 From: David Cauchi <13139524+davidcauchi@users.noreply.github.com> Date: Wed, 9 Aug 2023 11:16:26 +0200 Subject: [PATCH 119/270] BSC enable soak testing (#10099) * Initial config * Adjust config * go mod tidy * Add contract deployer * Add BSC mainnet soak support * Enable BSC on demand soak tests * bump ctf version * Initial config * bump ctf version * Update config docs * Update Link contract address * Updated docs --- .github/workflows/on-demand-ocr-soak-test.yml | 2 + .../evm/config/toml/defaults/BSC_Testnet.toml | 37 +++++++++ docs/CONFIG.md | 78 +++++++++++++++++++ .../contracts/contract_deployer.go | 6 ++ integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- integration-tests/networks/known_networks.go | 26 +++++++ 7 files changed, 152 insertions(+), 3 deletions(-) create mode 100644 core/chains/evm/config/toml/defaults/BSC_Testnet.toml diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 36812b94baa..5d5c2017c31 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -14,6 +14,8 @@ on: - "CELO_MAINNET" - "BASE_GOERLI" - "BASE_MAINNET" + - "BSC_MAINNET" + - "BSC_TESTNET" fundingPrivateKey: description: Private funding key (Skip for Simulated) required: false diff --git a/core/chains/evm/config/toml/defaults/BSC_Testnet.toml b/core/chains/evm/config/toml/defaults/BSC_Testnet.toml new file mode 100644 index 00000000000..f97dafa0648 --- /dev/null +++ b/core/chains/evm/config/toml/defaults/BSC_Testnet.toml @@ -0,0 +1,37 @@ +# BSC uses Clique consensus with ~3s block times +# Clique offers finality within (N/2)+1 blocks where N is number of signers +# There are 21 BSC validators so theoretically finality should occur after 21/2+1 = 11 blocks +ChainID = '97' +# Keeping this >> 11 because it's not expensive and gives us a safety margin +FinalityDepth = 50 +LinkContractAddress = '0x84b9B910527Ad5C03A9Ca831909E21e236EA7b06' +LogPollInterval = '3s' +MinIncomingConfirmations = 3 +NoNewHeadsThreshold = '30s' +RPCBlockQueryDelay = 2 +Transactions.ResendAfterThreshold = '1m' + +[BalanceMonitor] +Enabled = true + +[GasEstimator] +PriceDefault = '5 gwei' +PriceMin = '1 gwei' +BumpMin = '5 gwei' +# 15s delay since feeds update every minute in volatile situations +BumpThreshold = 5 + +[GasEstimator.BlockHistory] +BlockHistorySize = 24 + +[HeadTracker] +HistoryDepth = 100 +SamplingInterval = '1s' + +[OCR] +DatabaseTimeout = '2s' +ContractTransmitterTransmitTimeout = '2s' +ObservationGracePeriod = '500ms' + +[NodePool] +SyncThreshold = 10 diff --git a/docs/CONFIG.md b/docs/CONFIG.md index b7ca09bd3b3..703c383568c 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -2291,6 +2291,84 @@ GasLimit = 5300000

+
BSC Testnet (97)

+ +```toml +AutoCreateKey = true +BlockBackfillDepth = 10 +BlockBackfillSkip = false +FinalityDepth = 50 +FinalityTagEnabled = false +LinkContractAddress = '0x84b9B910527Ad5C03A9Ca831909E21e236EA7b06' +LogBackfillBatchSize = 1000 +LogPollInterval = '3s' +LogKeepBlocksDepth = 100000 +MinIncomingConfirmations = 3 +MinContractPayment = '0.00001 link' +NonceAutoSync = true +NoNewHeadsThreshold = '30s' +RPCDefaultBatchSize = 250 +RPCBlockQueryDelay = 2 + +[Transactions] +ForwardersEnabled = false +MaxInFlight = 16 +MaxQueued = 250 +ReaperInterval = '1h0m0s' +ReaperThreshold = '168h0m0s' +ResendAfterThreshold = '1m0s' + +[BalanceMonitor] +Enabled = true + +[GasEstimator] +Mode = 'BlockHistory' +PriceDefault = '5 gwei' +PriceMax = '115792089237316195423570985008687907853269984665.640564039457584007913129639935 tether' +PriceMin = '1 gwei' +LimitDefault = 500000 +LimitMax = 500000 +LimitMultiplier = '1' +LimitTransfer = 21000 +BumpMin = '5 gwei' +BumpPercent = 20 +BumpThreshold = 5 +EIP1559DynamicFees = false +FeeCapDefault = '100 gwei' +TipCapDefault = '1 wei' +TipCapMin = '1 wei' + +[GasEstimator.BlockHistory] +BatchSize = 25 +BlockHistorySize = 24 +CheckInclusionBlocks = 12 +CheckInclusionPercentile = 90 +TransactionPercentile = 60 + +[HeadTracker] +HistoryDepth = 100 +MaxBufferSize = 3 +SamplingInterval = '1s' + +[NodePool] +PollFailureThreshold = 5 +PollInterval = '10s' +SelectionMode = 'HighestHead' +SyncThreshold = 10 + +[OCR] +ContractConfirmations = 4 +ContractTransmitterTransmitTimeout = '2s' +DatabaseTimeout = '2s' +ObservationGracePeriod = '500ms' + +[OCR2] +[OCR2.Automation] +GasLimit = 5300000 +``` + +

+
xDai Mainnet (100)

```toml diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index b0ce801732e..70ab55eff9e 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -114,6 +114,8 @@ func NewContractDeployer(bcClient blockchain.EVMClient) (ContractDeployer, error return &CeloContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil case *blockchain.QuorumClient: return &QuorumContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil + case *blockchain.BSCClient: + return &BSCContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil } return nil, errors.New("unknown blockchain client implementation for contract deployer, register blockchain client in NewContractDeployer") } @@ -160,6 +162,10 @@ type QuorumContractDeployer struct { *EthereumContractDeployer } +type BSCContractDeployer struct { + *EthereumContractDeployer +} + // NewEthereumContractDeployer returns an instantiated instance of the ETH contract deployer func NewEthereumContractDeployer(ethClient blockchain.EVMClient) *EthereumContractDeployer { return &EthereumContractDeployer{ diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 0be03fbf238..9ae2f6d6a16 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -19,7 +19,7 @@ require ( github.com/rs/zerolog v1.29.1 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-env v0.36.0 - github.com/smartcontractkit/chainlink-testing-framework v1.15.0 + github.com/smartcontractkit/chainlink-testing-framework v1.15.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 github.com/smartcontractkit/ocr2keepers v0.7.5 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 094980fff81..f359caeafa7 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2248,8 +2248,8 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= -github.com/smartcontractkit/chainlink-testing-framework v1.15.0 h1:1ARN70Httew87gFQ27MAv4Iat7aoCnM3K87/d0r4Aho= -github.com/smartcontractkit/chainlink-testing-framework v1.15.0/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= +github.com/smartcontractkit/chainlink-testing-framework v1.15.1 h1:/i+JuVgStYoiKaLXisgRd96gyMd8NVwwYe/G+Tzy3+8= +github.com/smartcontractkit/chainlink-testing-framework v1.15.1/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= diff --git a/integration-tests/networks/known_networks.go b/integration-tests/networks/known_networks.go index 524bd421d2d..b24a2583039 100644 --- a/integration-tests/networks/known_networks.go +++ b/integration-tests/networks/known_networks.go @@ -368,6 +368,30 @@ var ( GasEstimationBuffer: 0, } + BSCTestnet blockchain.EVMNetwork = blockchain.EVMNetwork{ + Name: "BSC Testnet", + SupportsEIP1559: true, + ClientImplementation: blockchain.BSCClientImplementation, + ChainID: 97, + Simulated: false, + ChainlinkTransactionLimit: 5000, + Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, + MinimumConfirmations: 3, + GasEstimationBuffer: 0, + } + + BSCMainnet blockchain.EVMNetwork = blockchain.EVMNetwork{ + Name: "BSC Mainnet", + SupportsEIP1559: true, + ClientImplementation: blockchain.BSCClientImplementation, + ChainID: 56, + Simulated: false, + ChainlinkTransactionLimit: 5000, + Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, + MinimumConfirmations: 3, + GasEstimationBuffer: 0, + } + MappedNetworks = map[string]blockchain.EVMNetwork{ "SIMULATED": SimulatedEVM, "SIMULATED_1": SimulatedEVMNonDev1, @@ -395,6 +419,8 @@ var ( "AVALANCHE_MAINNET": AvalancheMainnet, "QUORUM": Quorum, "BASE_MAINNET": BaseMainnet, + "BSC_TESTNET": BSCTestnet, + "BSC_MAINNET": BSCMainnet, } ) From de074d401519fdace33771360e310867fb39d3e1 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Wed, 9 Aug 2023 13:07:00 +0300 Subject: [PATCH 120/270] TT-501 VRFv2 performance tests (#10100) * Marshal struct to build node config Use functional options as decorators to create node config with P2Pv1 or P2Pv2. * Add ocr2 * Use config structures from core * Fix gomod * Fix setting p2p * fix tests * TT-467 migrate VRFv2, align VRFv1 * TT-467 update to new config * update receivers * remove NodeConfigOpts * TT-467 refactor vrf1/vrf2 smoke tests * TT-467 clean up error messages * TT-467 plaintext secret fields for testing * Revert "TT-467 plaintext secret fields for testing" This reverts commit fcf3dd16522bb73efcc0d5e1bcf3b6bbfc9752cf. * Revert "Revert "TT-467 plaintext secret fields for testing"" This reverts commit 26db785e156f32d5aedd48181523d267527595db. * TT-467 use flag to skip redacting * update secrets * use old secrets text template * TT-501 VRFv2 performance tests * remove k8s tests code * keepers 2.1 alpha e2e integration (#10060) * This time exclude evm21 from the rebase * Fix imports * Use contract version to determine if we should create v2.0 or v2.1 dependencies * Undo general evm changes * More undo * Rework delegate with minimal changes * added integration tests (wip) - log upkeep - conditional upkeep * revert mercury provider changes * remove empty line * skip log upkeep test in CI * update dependencies * build mercury integration test * fix ContractSetConfigArgsForTestsOCR3 * fix forwarder logic dependency * Add a nil check for the keeper spec * Move ContractVersion into the PluginConfig * fix job spec in 2.1 integration test * Encoding hack for upkeepID * fix dependencies and integration test * fix test * Tidy go mod * Fix diff --------- Co-authored-by: amirylm Co-authored-by: Akshay Aggarwal Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Co-authored-by: Amir Y <83904651+amirylm@users.noreply.github.com> * [TT-486] Split packages attempt 2 to only run packages that have tests (#10105) This time includes packages that are test only packages and not associated to another package. * TT-501 VRFv2 performance tests * toml config * rename jobs to products * switch to latest go and testcontainers * docs * fix go mod --------- Co-authored-by: lukaszcl <120112546+lukaszcl@users.noreply.github.com> Co-authored-by: ferglor <19188060+ferglor@users.noreply.github.com> Co-authored-by: amirylm Co-authored-by: Akshay Aggarwal Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Co-authored-by: Amir Y <83904651+amirylm@users.noreply.github.com> Co-authored-by: Tate --- .github/workflows/integration-tests.yml | 1 - .../actions/vrfv2_actions/vrfv2_steps.go | 86 ++++++++++++++++ integration-tests/go.mod | 17 ++-- integration-tests/go.sum | 33 ++++--- integration-tests/load/README.md | 63 ++++++++++++ integration-tests/load/vrfv2/cmd/dashboard.go | 98 +++++++++++++++++++ integration-tests/load/vrfv2/config.go | 72 ++++++++++++++ integration-tests/load/vrfv2/config.toml | 25 +++++ integration-tests/load/vrfv2/gun.go | 37 +++++++ .../load/vrfv2/onchain_monitoring.go | 46 +++++++++ integration-tests/load/vrfv2/vrfv2_test.go | 76 ++++++++++++++ integration-tests/load/vrfv2/vu.go | 91 +++++++++++++++++ integration-tests/smoke/README.md | 52 ++++++++++ 13 files changed, 673 insertions(+), 24 deletions(-) create mode 100644 integration-tests/load/README.md create mode 100644 integration-tests/load/vrfv2/cmd/dashboard.go create mode 100644 integration-tests/load/vrfv2/config.go create mode 100644 integration-tests/load/vrfv2/config.toml create mode 100644 integration-tests/load/vrfv2/gun.go create mode 100644 integration-tests/load/vrfv2/onchain_monitoring.go create mode 100644 integration-tests/load/vrfv2/vrfv2_test.go create mode 100644 integration-tests/load/vrfv2/vu.go create mode 100644 integration-tests/smoke/README.md diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index fc2412a39ba..481028387ce 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -219,7 +219,6 @@ jobs: test_download_vendor_packages_command: cd ./integration-tests && go mod download cl_repo: ${{ env.CHAINLINK_IMAGE }} cl_image_tag: ${{ github.sha }} - go_version: '1.20.5' aws_registries: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} artifacts_location: ./integration-tests/smoke/logs publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} diff --git a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go index 0b3eaabf2cb..a428ecb369e 100644 --- a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go +++ b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go @@ -10,8 +10,11 @@ import ( "github.com/google/uuid" "github.com/pkg/errors" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + vrfConst "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" ) var ( @@ -143,3 +146,86 @@ func FundVRFCoordinatorV2Subscription(linkToken contracts.LinkToken, coordinator } return chainClient.WaitForEvents() } + +/* setup for load tests */ + +func SetupLocalLoadTestEnv(nodesFunding *big.Float, subFundingLINK *big.Int) (*test_env.CLClusterTestEnv, *VRFV2Contracts, [32]byte, error) { + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithLogWatcher(). + WithMockServer(1). + WithCLNodes(1). + WithFunding(nodesFunding). + Build() + if err != nil { + return nil, nil, [32]byte{}, err + } + env.ParallelTransactions(true) + + mockFeed, err := actions.DeployMockETHLinkFeed(env.Geth.ContractDeployer, vrfConst.LinkEthFeedResponse) + if err != nil { + return nil, nil, [32]byte{}, err + } + lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) + if err != nil { + return nil, nil, [32]byte{}, err + } + vrfv2Contracts, err := DeployVRFV2Contracts(env.Geth.ContractDeployer, env.Geth.EthClient, lt, mockFeed) + if err != nil { + return nil, nil, [32]byte{}, err + } + err = env.Geth.EthClient.WaitForEvents() + if err != nil { + return nil, nil, [32]byte{}, err + } + err = vrfv2Contracts.Coordinator.SetConfig( + vrfConst.MinimumConfirmations, + vrfConst.MaxGasLimitVRFCoordinatorConfig, + vrfConst.StalenessSeconds, + vrfConst.GasAfterPaymentCalculation, + vrfConst.LinkEthFeedResponse, + vrfConst.VRFCoordinatorV2FeeConfig, + ) + if err != nil { + return nil, nil, [32]byte{}, err + } + err = env.Geth.EthClient.WaitForEvents() + if err != nil { + return nil, nil, [32]byte{}, err + } + err = vrfv2Contracts.Coordinator.CreateSubscription() + if err != nil { + return nil, nil, [32]byte{}, err + } + err = env.Geth.EthClient.WaitForEvents() + if err != nil { + return nil, nil, [32]byte{}, err + } + err = vrfv2Contracts.Coordinator.AddConsumer(vrfConst.SubID, vrfv2Contracts.LoadTestConsumer.Address()) + if err != nil { + return nil, nil, [32]byte{}, err + } + err = FundVRFCoordinatorV2Subscription(lt, vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.SubID, subFundingLINK) + if err != nil { + return nil, nil, [32]byte{}, err + } + jobs, err := CreateVRFV2Jobs(env.GetAPIs(), vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.MinimumConfirmations) + if err != nil { + return nil, nil, [32]byte{}, err + } + // this part is here because VRFv2 can work with only a specific key + // [[EVM.KeySpecific]] + // Key = '...' + addr, err := env.CLNodes[0].API.PrimaryEthAddress() + if err != nil { + return nil, nil, [32]byte{}, err + } + nodeConfig := node.NewConfig(env.CLNodes[0].NodeConfig, + node.WithVRFv2EVMEstimator(addr), + ) + err = env.CLNodes[0].Restart(nodeConfig) + if err != nil { + return nil, nil, [32]byte{}, err + } + return env, vrfv2Contracts, jobs[0].KeyHash, nil +} diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 9ae2f6d6a16..7cd0c1bfae8 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -6,6 +6,7 @@ go 1.20 replace github.com/smartcontractkit/chainlink/v2 => ../ require ( + github.com/K-Phoen/grabana v0.21.17 github.com/cli/go-gh/v2 v2.0.0 github.com/ethereum/go-ethereum v1.12.0 github.com/go-resty/resty/v2 v2.7.0 @@ -24,9 +25,10 @@ require ( github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 github.com/smartcontractkit/ocr2keepers v0.7.5 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 + github.com/smartcontractkit/wasp v0.2.7 github.com/spf13/cobra v1.6.1 github.com/stretchr/testify v1.8.4 - github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a + github.com/testcontainers/testcontainers-go v0.22.0 github.com/umbracle/ethgo v0.1.3 go.dedis.ch/kyber/v3 v3.1.0 go.uber.org/multierr v1.11.0 @@ -49,6 +51,7 @@ require ( cosmossdk.io/depinject v1.0.0-alpha.3 // indirect cosmossdk.io/errors v1.0.0 // indirect cosmossdk.io/math v1.0.1 // indirect + dario.cat/mergo v1.0.0 // indirect filippo.io/edwards25519 v1.0.0 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/99designs/keyring v1.2.1 // indirect @@ -57,7 +60,6 @@ require ( github.com/CosmWasm/wasmd v0.40.1 // indirect github.com/CosmWasm/wasmvm v1.2.4 // indirect github.com/DataDog/zstd v1.5.2 // indirect - github.com/K-Phoen/grabana v0.21.17 // indirect github.com/K-Phoen/sdk v0.12.2 // indirect github.com/MakeNowJust/heredoc v1.0.0 // indirect github.com/Masterminds/semver/v3 v3.2.1 // indirect @@ -98,7 +100,7 @@ require ( github.com/cometbft/cometbft v0.37.2 // indirect github.com/cometbft/cometbft-db v0.7.0 // indirect github.com/confio/ics23/go v0.9.0 // indirect - github.com/containerd/containerd v1.6.19 // indirect + github.com/containerd/containerd v1.7.3 // indirect github.com/coreos/go-semver v0.3.0 // indirect github.com/coreos/go-systemd/v22 v22.5.0 // indirect github.com/cosmos/btcutil v1.0.5 // indirect @@ -122,7 +124,7 @@ require ( github.com/dgraph-io/ristretto v0.1.1 // indirect github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 // indirect github.com/docker/distribution v2.8.2+incompatible // indirect - github.com/docker/docker v24.0.2+incompatible // indirect + github.com/docker/docker v24.0.5+incompatible // indirect github.com/docker/go-connections v0.4.0 // indirect github.com/docker/go-units v0.5.0 // indirect github.com/dustin/go-humanize v1.0.1 // indirect @@ -344,7 +346,7 @@ require ( github.com/oklog/ulid v1.3.1 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect - github.com/opencontainers/image-spec v1.1.0-rc3 // indirect + github.com/opencontainers/image-spec v1.1.0-rc4 // indirect github.com/opencontainers/runc v1.1.7 // indirect github.com/opentracing-contrib/go-grpc v0.0.0-20210225150812-73cb765af46e // indirect github.com/opentracing-contrib/go-stdlib v1.0.0 // indirect @@ -386,7 +388,6 @@ require ( github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 // indirect - github.com/smartcontractkit/wasp v0.2.7 // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect github.com/spaolacci/murmur3 v1.1.0 // indirect @@ -461,7 +462,7 @@ require ( google.golang.org/genproto v0.0.0-20230706204954-ccb25ca9f130 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20230629202037-9506855d4529 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20230711160842-782d3b101e98 // indirect - google.golang.org/grpc v1.56.2 // indirect + google.golang.org/grpc v1.57.0 // indirect google.golang.org/protobuf v1.31.0 // indirect gopkg.in/guregu/null.v2 v2.1.2 // indirect gopkg.in/inf.v0 v0.9.1 // indirect @@ -475,7 +476,7 @@ require ( k8s.io/apimachinery v0.26.2 // indirect k8s.io/cli-runtime v0.25.11 // indirect k8s.io/client-go v0.26.2 // indirect - k8s.io/component-base v0.25.11 // indirect + k8s.io/component-base v0.26.2 // indirect k8s.io/klog/v2 v2.90.1 // indirect k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d // indirect k8s.io/kubectl v0.25.11 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index f359caeafa7..38448c2cdd2 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -531,6 +531,8 @@ cosmossdk.io/log v1.1.1-0.20230704160919-88f2c830b0ca h1:msenprh2BLLRwNT7zN56TbB cosmossdk.io/math v1.0.1 h1:Qx3ifyOPaMLNH/89WeZFH268yCvU4xEcnPLu3sJqPPg= cosmossdk.io/math v1.0.1/go.mod h1:Ygz4wBHrgc7g0N+8+MrnTfS9LLn9aaTGa9hKopuym5k= cosmossdk.io/tools/rosetta v0.2.1 h1:ddOMatOH+pbxWbrGJKRAawdBkPYLfKXutK9IETnjYxw= +dario.cat/mergo v1.0.0 h1:AGCNq9Evsj31mOgNPcLyXc+4PNABt905YmuqPYYpBWk= +dario.cat/mergo v1.0.0/go.mod h1:uNxQE+84aUszobStD9th8a29P2fMDhsBdgRYvZOxGmk= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns= filippo.io/edwards25519 v1.0.0 h1:0wAIcmJUqRdI8IJ/3eGi5/HwXZWPujYXXlkrQogz0Ek= @@ -541,7 +543,7 @@ github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 h1:/vQbFIOMb github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4/go.mod h1:hN7oaIRCjzsZ2dE+yG5k+rsdt3qcwykqK6HVGcKwsw4= github.com/99designs/keyring v1.2.1 h1:tYLp1ULvO7i3fI5vE21ReQuj99QFSs7lGm0xWyJo87o= github.com/99designs/keyring v1.2.1/go.mod h1:fc+wB5KTk9wQ9sDx0kFXB3A0MaeGHM9AwRStKOQ5vOA= -github.com/AdaLogics/go-fuzz-headers v0.0.0-20210715213245-6c3934b029d8 h1:V8krnnfGj4pV65YLUm3C0/8bl7V5Nry2Pwvy3ru/wLc= +github.com/AdaLogics/go-fuzz-headers v0.0.0-20230106234847-43070de90fa1 h1:EKPd1INOIyr5hWOWhvpmQpY6tKjeG0hT1s3AMC/9fic= github.com/AlekSi/pointer v1.1.0 h1:SSDMPcXD9jSl8FPy9cRzoRaMJtm9g9ggGTxecRUbQoI= github.com/AlekSi/pointer v1.1.0/go.mod h1:y7BvfRI3wXPWKXEBhU71nbnIEEZX0QTSB2Bj48UJIZE= github.com/AndreasBriese/bbloom v0.0.0-20180913140656-343706a395b7/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= @@ -589,7 +591,7 @@ github.com/Masterminds/semver/v3 v3.2.1 h1:RN9w6+7QoMeJVGyfmbcgs28Br8cvmnucEXnY0 github.com/Masterminds/semver/v3 v3.2.1/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= -github.com/Microsoft/hcsshim v0.9.7 h1:mKNHW/Xvv1aFH87Jb6ERDzXTJTLPlmzfZ28VBFD/bfg= +github.com/Microsoft/hcsshim v0.10.0-rc.8 h1:YSZVvlIIDD1UxQpJp0h+dnpLUw+TrY0cx8obKsp3bek= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OneOfOne/xxhash v1.2.6 h1:U68crOE3y3MPttCMQGywZOLrTeF5HHJ3/vDBCJn9/bA= @@ -766,9 +768,9 @@ github.com/cometbft/cometbft-db v0.7.0 h1:uBjbrBx4QzU0zOEnU8KxoDl18dMNgDh+zZRUE0 github.com/cometbft/cometbft-db v0.7.0/go.mod h1:yiKJIm2WKrt6x8Cyxtq9YTEcIMPcEe4XPxhgX59Fzf0= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= -github.com/containerd/containerd v1.6.19 h1:F0qgQPrG0P2JPgwpxWxYavrVeXAG0ezUIB9Z/4FTUAU= -github.com/containerd/containerd v1.6.19/go.mod h1:HZCDMn4v/Xl2579/MvtOC2M206i+JJ6VxFWU/NetrGY= -github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= +github.com/containerd/containerd v1.7.3 h1:cKwYKkP1eTj54bP3wCdXXBymmKRQMrWjkLSWZZJDa8o= +github.com/containerd/containerd v1.7.3/go.mod h1:32FOM4/O0RkNg7AjQj3hDzN9cUGtu+HMvaKUNiqCZB8= +github.com/containerd/continuity v0.4.1 h1:wQnVrjIyQ8vhU2sgOiL5T07jo+ouqc2bnKsv5/EqGhU= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -816,6 +818,7 @@ github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ3 github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= +github.com/cyphar/filepath-securejoin v0.2.3 h1:YX6ebbZCZP7VkM3scTTokDgBL2TY741X51MTk3ycuNI= github.com/daaku/go.zipexe v1.0.0/go.mod h1:z8IiR6TsVLEYKwXAoE/I+8ys/sDkgTzSL0CLnGVd57E= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= @@ -858,8 +861,8 @@ github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8 github.com/digitalocean/godo v1.97.0 h1:p9w1yCcWMZcxFSLPToNGXA96WfUVLXqoHti6GzVomL4= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v24.0.2+incompatible h1:eATx+oLz9WdNVkQrr0qjQ8HvRJ4bOOxfzEo8R+dA3cg= -github.com/docker/docker v24.0.2+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= +github.com/docker/docker v24.0.5+incompatible h1:WmgcE4fxyI6EEXxBRxsHnZXrO1pQ3smi0k/jho4HLeY= +github.com/docker/docker v24.0.5+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= @@ -2057,8 +2060,8 @@ github.com/onsi/gomega v1.27.8 h1:gegWiwZjBsf2DgiSbf5hpokZ98JVDMcWkUiigk6/KXc= github.com/onsi/gomega v1.27.8/go.mod h1:2J8vzI/s+2shY9XHRApDkdgPo1TKT7P2u6fXeJKFnNQ= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= -github.com/opencontainers/image-spec v1.1.0-rc3 h1:fzg1mXZFj8YdPeNkRXMg+zb88BFV0Ys52cJydRwBkb8= -github.com/opencontainers/image-spec v1.1.0-rc3/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= +github.com/opencontainers/image-spec v1.1.0-rc4 h1:oOxKUJWnFC4YGHCCMNql1x4YaDfYBTS5Y4x/Cgeo1E0= +github.com/opencontainers/image-spec v1.1.0-rc4/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= github.com/opencontainers/runc v1.1.7 h1:y2EZDS8sNng4Ksf0GUYNhKbTShZJPJg1FiXJNH/uoCk= github.com/opencontainers/runc v1.1.7/go.mod h1:CbUumNnWCuTGFukNXahoo/RFBZvDAgRh/smNYNOhA50= github.com/opentracing-contrib/go-grpc v0.0.0-20180928155321-4b5a12d3ff02/go.mod h1:JNdpVEzCpXBgIiv4ds+TzhN1hrtxq6ClLrTlT9OQRSc= @@ -2341,8 +2344,8 @@ github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 h1:3SNcvBmEPE1YlB github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125/go.mod h1:M8agBzgqHIhgj7wEn9/0hJUZcrvt9VY+Ln+S1I5Mha0= github.com/test-go/testify v1.1.4 h1:Tf9lntrKUMHiXQ07qBScBTSA0dhYQlu83hswqelv1iE= github.com/test-go/testify v1.1.4/go.mod h1:rH7cfJo/47vWGdi4GPj16x3/t1xGOj2YxzmNQzk2ghU= -github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a h1:ssL/ZDrMCIu+MRv3+3zlPKnETExI52cngtbBHv4VQ70= -github.com/testcontainers/testcontainers-go v0.21.1-0.20230623154539-f5a4a541f71a/go.mod h1:IgGARdvGrTYx/tWIwda1GEaV8ivfm3iHqYaTnlHkh1U= +github.com/testcontainers/testcontainers-go v0.22.0 h1:hOK4NzNu82VZcKEB1aP9LO1xYssVFMvlfeuDW9JMmV0= +github.com/testcontainers/testcontainers-go v0.22.0/go.mod h1:k0YiPa26xJCRUbUkYqy5rY6NGvSbVCeUBXCvucscBR4= github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a h1:YuO+afVc3eqrjiCUizNCxI53bl/BnPiVwXqLzqYTqgU= github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a/go.mod h1:/sfW47zCZp9FrtGcWyo1VjbgDaodxX9ovZvgLb/MxaA= github.com/thlib/go-timezone-local v0.0.0-20210907160436-ef149e42d28e h1:BuzhfgfWQbX0dWzYzT1zsORLnHRv3bcRcsaUk0VmXA8= @@ -3300,8 +3303,8 @@ google.golang.org/grpc v1.51.0/go.mod h1:wgNDFcnuBGmxLKI/qn4T+m5BtEBYXJPvibbUPsA google.golang.org/grpc v1.52.0/go.mod h1:pu6fVzoFb+NBYNAvQL08ic+lvB2IojljRYuun5vorUY= google.golang.org/grpc v1.53.0/go.mod h1:OnIrk0ipVdj4N5d9IUoFUx72/VlD7+jUsHwZgwSMQpw= google.golang.org/grpc v1.55.0/go.mod h1:iYEXKGkEBhg1PjZQvoYEVPTDkHo1/bjTnfwTeGONTY8= -google.golang.org/grpc v1.56.2 h1:fVRFRnXvU+x6C4IlHZewvJOVHoOv1TUuQyoRsYnB4bI= -google.golang.org/grpc v1.56.2/go.mod h1:I9bI3vqKfayGqPUAwGdOSu7kt6oIJLixfffKrpXqQ9s= +google.golang.org/grpc v1.57.0 h1:kfzNeI/klCGD2YPMUlaGNT3pxvYfga7smW3Vth8Zsiw= +google.golang.org/grpc v1.57.0/go.mod h1:Sd+9RMTACXwmub0zcNY2c4arhtrbBYD1AUHI/dt16Mo= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.1.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= google.golang.org/grpc/examples v0.0.0-20210424002626-9572fd6faeae/go.mod h1:Ly7ZA/ARzg8fnPU9TyZIxoz33sEUuWX7txiqs8lPTgE= google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= @@ -3392,8 +3395,8 @@ k8s.io/cli-runtime v0.25.11 h1:GE2yNZm1tN+MJtw1SGMOLesLF7Kp7NVAVqRSTbXfu4o= k8s.io/cli-runtime v0.25.11/go.mod h1:r/nEINuHVEpgGhcd2WamU7hD1t/lMnSz8XM44Autltc= k8s.io/client-go v0.25.11 h1:DJQ141UsbNRI6wYSlcYLP5J5BW5Wq7Bgm42Ztq2SW70= k8s.io/client-go v0.25.11/go.mod h1:41Xs7p1SfhoReUnmjjYCfCNWFiq4xSkexwJfbxF2F7A= -k8s.io/component-base v0.25.11 h1:3QmISCE9n9CJkVpTA4spQO1IZCrLlOwbKdzSN9dqZZA= -k8s.io/component-base v0.25.11/go.mod h1:wFR4pfB+xTc6FBak+RoWRNeTmelGE4XWJP/xVOvn3vM= +k8s.io/component-base v0.26.2 h1:IfWgCGUDzrD6wLLgXEstJKYZKAFS2kO+rBRi0p3LqcI= +k8s.io/component-base v0.26.2/go.mod h1:DxbuIe9M3IZPRxPIzhch2m1eT7uFrSBJUBuVCQEBivs= k8s.io/klog/v2 v2.90.1 h1:m4bYOKall2MmOiRaR1J+We67Do7vm9KiQVlT96lnHUw= k8s.io/klog/v2 v2.90.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0= k8s.io/kube-openapi v0.0.0-20230303024457-afdc3dddf62d h1:VcFq5n7wCJB2FQMCIHfC+f+jNcGgNMar1uKd6rVlifU= diff --git a/integration-tests/load/README.md b/integration-tests/load/README.md new file mode 100644 index 00000000000..1ed1ee8b94e --- /dev/null +++ b/integration-tests/load/README.md @@ -0,0 +1,63 @@ +## Performance tests for CL jobs + +This folder container performance e2e tests for different job types, currently implemented: +- VRFv2 + +All the tests have 4 groups: +- one product soak +- one product load +- multiple product instances soak +- multiple product instances load + +When you develop an e2e performance suite for a new product you can implement the tests one by one to answer the questions: + +What are performance characteristics of a one instance of a product (jobs + contracts): +- is our product stable at all, no memory leaks, no flaking performance under some RPS? (test #1) +- what are the limits for one product instance, figuring out the max/optimal performance params by increasing RPS and varying configuration (test #2) +- update test #1 with optimal params and workload to constantly run in CI + +What are performance and capacity characteristics of Chainlink node(s) that run multiple products of the same type simultaneously: +- how many products of the same type we can run at once at a stable load with optimal configuration? (test #3) +- what are the limits if we add more and more products of the same type, each product have a stable RPS, we vary only amount of products +- update test #3 with optimal params and workload to constantly run in CI + +Implementing test #1 is **mandatory** for each product. +Tests #2,#3,#4 are optional if you need to figure out your product scaling or node/cluster capacity. + + +## Usage +``` +export LOKI_TOKEN=... +export LOKI_URL=... + +go test -v -run TestVRFV2Load/vrfv2_soak_test +``` + +### Dashboards +Each product has its own generated dashboard in `cmd/dashboard.go` + +Deploying dashboard: +``` +export GRAFANA_URL=... +export GRAFANA_TOKEN=... +export DATA_SOURCE_NAME=grafanacloud-logs +export DASHBOARD_FOLDER=LoadTests +export DASHBOARD_NAME=${JobTypeName, for example WaspVRFv2} + +go run dashboard.go +``` + +### Assertions + +You can implement your product requirements assertions in `onchain_monitoring.go`. For Chainlink products (VRF/OCR/Keepers/Automation) it's easier to assert on-chain part + +If you need to assert some metrics in `Prometheus/Loki`, here is an [example](https://github.com/smartcontractkit/wasp/blob/master/examples/alerts/main_test.go#L88) + +Do not mix workload logic with assertions, separate them. + +### Implementation +To implement a standard e2e performance suite for a new product please look at `gun.go` and `vu.go`. + +Gun should be working with one instance of your product. + +VU(Virtual user) creates a new instance of your product and works with it in `Call()` \ No newline at end of file diff --git a/integration-tests/load/vrfv2/cmd/dashboard.go b/integration-tests/load/vrfv2/cmd/dashboard.go new file mode 100644 index 00000000000..f7e29bd7d75 --- /dev/null +++ b/integration-tests/load/vrfv2/cmd/dashboard.go @@ -0,0 +1,98 @@ +package main + +import ( + "github.com/K-Phoen/grabana/dashboard" + "github.com/K-Phoen/grabana/logs" + "github.com/K-Phoen/grabana/row" + "github.com/K-Phoen/grabana/target/prometheus" + "github.com/K-Phoen/grabana/timeseries" + "github.com/K-Phoen/grabana/timeseries/axis" + "github.com/smartcontractkit/wasp" +) + +func main() { + lokiDS := "grafanacloud-logs" + d, err := wasp.NewDashboard(nil, + []dashboard.Option{ + dashboard.Row("LoadContractMetrics", + row.WithTimeSeries( + "RequestCount + FulfilmentCount", + timeseries.Span(12), + timeseries.Height("300px"), + timeseries.DataSource(lokiDS), + timeseries.Axis( + axis.Unit("Requests"), + ), + timeseries.WithPrometheusTarget( + ` + last_over_time({type="vrfv2_contracts_load_summary", go_test_name=~"${go_test_name:pipe}", branch=~"${branch:pipe}", commit=~"${commit:pipe}", gen_name=~"${gen_name:pipe}"} + | json + | unwrap RequestCount [$__interval]) by (node_id, go_test_name, gen_name) + `, prometheus.Legend("{{go_test_name}} requests"), + ), + timeseries.WithPrometheusTarget( + ` + last_over_time({type="vrfv2_contracts_load_summary", go_test_name=~"${go_test_name:pipe}", branch=~"${branch:pipe}", commit=~"${commit:pipe}", gen_name=~"${gen_name:pipe}"} + | json + | unwrap FulfilmentCount [$__interval]) by (node_id, go_test_name, gen_name) + `, prometheus.Legend("{{go_test_name}} fulfillments"), + ), + ), + row.WithTimeSeries( + "Fulfillment time (blocks)", + timeseries.Span(12), + timeseries.Height("300px"), + timeseries.DataSource(lokiDS), + timeseries.Axis( + axis.Unit("Blocks"), + ), + timeseries.WithPrometheusTarget( + ` + last_over_time({type="vrfv2_contracts_load_summary", go_test_name=~"${go_test_name:pipe}", branch=~"${branch:pipe}", commit=~"${commit:pipe}", gen_name=~"${gen_name:pipe}"} + | json + | unwrap AverageFulfillmentInMillions [$__interval]) by (node_id, go_test_name, gen_name) / 1e6 + `, prometheus.Legend("{{go_test_name}} avg"), + ), + timeseries.WithPrometheusTarget( + ` + last_over_time({type="vrfv2_contracts_load_summary", go_test_name=~"${go_test_name:pipe}", branch=~"${branch:pipe}", commit=~"${commit:pipe}", gen_name=~"${gen_name:pipe}"} + | json + | unwrap SlowestFulfillment [$__interval]) by (node_id, go_test_name, gen_name) + `, prometheus.Legend("{{go_test_name}} slowest"), + ), + timeseries.WithPrometheusTarget( + ` + last_over_time({type="vrfv2_contracts_load_summary", go_test_name=~"${go_test_name:pipe}", branch=~"${branch:pipe}", commit=~"${commit:pipe}", gen_name=~"${gen_name:pipe}"} + | json + | unwrap FastestFulfillment [$__interval]) by (node_id, go_test_name, gen_name) + `, prometheus.Legend("{{go_test_name}} fastest"), + ), + ), + ), + dashboard.Row("CL nodes logs", + row.Collapse(), + row.WithLogs( + "CL nodes logs", + logs.DataSource(lokiDS), + logs.Span(12), + logs.Height("300px"), + logs.Transparent(), + logs.WithLokiTarget(` + {type="log_watch"} + `), + )), + }, + ) + if err != nil { + panic(err) + } + // set env vars + //export GRAFANA_URL=... + //export GRAFANA_TOKEN=... + //export DATA_SOURCE_NAME=Loki + //export DASHBOARD_FOLDER=LoadTests + //export DASHBOARD_NAME=WaspVRFv2 + if _, err := d.Deploy(); err != nil { + panic(err) + } +} diff --git a/integration-tests/load/vrfv2/config.go b/integration-tests/load/vrfv2/config.go new file mode 100644 index 00000000000..53188f3a0e8 --- /dev/null +++ b/integration-tests/load/vrfv2/config.go @@ -0,0 +1,72 @@ +package loadvrfv2 + +import ( + "github.com/pelletier/go-toml/v2" + "github.com/pkg/errors" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "math/big" + "os" +) + +const ( + DefaultConfigFilename = "config.toml" + + ErrReadPerfConfig = "failed to read TOML config for performance tests" + ErrUnmarshalPerfConfig = "failed to unmarshal TOML config for performance tests" +) + +type PerformanceConfig struct { + Soak *Soak `toml:"Soak"` + Load *Load `toml:"Load"` + SoakVolume *SoakVolume `toml:"SoakVolume"` + LoadVolume *LoadVolume `toml:"LoadVolume"` + Common *Common `toml:"Common"` +} + +type Common struct { + Funding +} + +type Funding struct { + NodeFunds *big.Float `toml:"node_funds"` + SubFunds *big.Int `toml:"sub_funds"` +} + +type Soak struct { + RPS int64 `toml:"rps"` + Duration *models.Duration `toml:"duration"` +} + +type SoakVolume struct { + Products int64 `toml:"products"` + Pace *models.Duration `toml:"pace"` + Duration *models.Duration `toml:"duration"` +} + +type Load struct { + RPSFrom int64 `toml:"rps_from"` + RPSTo int64 `toml:"rps_to"` + Duration *models.Duration `toml:"duration"` +} + +type LoadVolume struct { + ProductsFrom int64 `toml:"products_from"` + ProductsTo int64 `toml:"products_to"` + Pace *models.Duration `toml:"pace"` + Duration *models.Duration `toml:"duration"` +} + +func ReadConfig() (*PerformanceConfig, error) { + var cfg *PerformanceConfig + d, err := os.ReadFile(DefaultConfigFilename) + if err != nil { + return nil, errors.Wrap(err, ErrReadPerfConfig) + } + err = toml.Unmarshal(d, &cfg) + if err != nil { + return nil, errors.Wrap(err, ErrUnmarshalPerfConfig) + } + log.Debug().Interface("PerformanceConfig", cfg).Msg("Parsed performance config") + return cfg, nil +} diff --git a/integration-tests/load/vrfv2/config.toml b/integration-tests/load/vrfv2/config.toml new file mode 100644 index 00000000000..51a0e95d35a --- /dev/null +++ b/integration-tests/load/vrfv2/config.toml @@ -0,0 +1,25 @@ +# testing one product (jobs + contracts) by varying RPS +[Soak] +rps = 1 +duration = "10m" + +[Load] +rps_from = 1 +rps_to = 5 +duration = "10m" + +# testing multiple products (jobs + contracts) by varying instances, deploying more of the same type with stable RPS for each product +[SoakVolume] +products = 5 +pace = "1s" +duration = "10m" + +[LoadVolume] +products_from = 1 +products_to = 5 +pace = "1s" +duration = "10m" + +[Common] +node_funds = 10 +sub_funds = 100 \ No newline at end of file diff --git a/integration-tests/load/vrfv2/gun.go b/integration-tests/load/vrfv2/gun.go new file mode 100644 index 00000000000..d6a8977738b --- /dev/null +++ b/integration-tests/load/vrfv2/gun.go @@ -0,0 +1,37 @@ +package loadvrfv2 + +import ( + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions" + vrfConst "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" + "github.com/smartcontractkit/wasp" +) + +/* SingleHashGun is a gun that constantly requests randomness for one feed */ + +type SingleHashGun struct { + contracts *vrfv2_actions.VRFV2Contracts + keyHash [32]byte +} + +func SingleFeedGun(contracts *vrfv2_actions.VRFV2Contracts, keyHash [32]byte) *SingleHashGun { + return &SingleHashGun{ + contracts: contracts, + keyHash: keyHash, + } +} + +// Call implements example gun call, assertions on response bodies should be done here +func (m *SingleHashGun) Call(l *wasp.Generator) *wasp.CallResult { + err := m.contracts.LoadTestConsumer.RequestRandomness( + m.keyHash, + vrfConst.SubID, + vrfConst.MinimumConfirmations, + vrfConst.CallbackGasLimit, + vrfConst.NumberOfWords, + vrfConst.RandomnessRequestCountPerRequest, + ) + if err != nil { + return &wasp.CallResult{Error: err.Error(), Failed: true} + } + return &wasp.CallResult{} +} diff --git a/integration-tests/load/vrfv2/onchain_monitoring.go b/integration-tests/load/vrfv2/onchain_monitoring.go new file mode 100644 index 00000000000..b4503d27fad --- /dev/null +++ b/integration-tests/load/vrfv2/onchain_monitoring.go @@ -0,0 +1,46 @@ +package loadvrfv2 + +import ( + "context" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions" + "github.com/smartcontractkit/wasp" + "testing" + "time" +) + +/* Monitors on-chain stats of LoadConsumer and pushes them to Loki every second */ + +const ( + LokiTypeLabel = "vrfv2_contracts_load_summary" + ErrMetrics = "failed to get VRFv2 load test metrics" + ErrLokiClient = "failed to create Loki client for monitoring" + ErrLokiPush = "failed to push monitoring metrics to Loki" +) + +func MonitorLoadStats(t *testing.T, vrfv2Contracts *vrfv2_actions.VRFV2Contracts, labels map[string]string) { + go func() { + updatedLabels := make(map[string]string) + for k, v := range labels { + updatedLabels[k] = v + } + updatedLabels["type"] = LokiTypeLabel + updatedLabels["go_test_name"] = t.Name() + updatedLabels["gen_name"] = "performance" + lc, err := wasp.NewLokiClient(wasp.NewEnvLokiConfig()) + if err != nil { + log.Error().Err(err).Msg(ErrLokiClient) + return + } + for { + time.Sleep(1 * time.Second) + metrics, err := vrfv2Contracts.LoadTestConsumer.GetLoadTestMetrics(context.Background()) + if err != nil { + log.Error().Err(err).Msg(ErrMetrics) + } + if err := lc.HandleStruct(wasp.LabelsMapToModel(updatedLabels), time.Now(), metrics); err != nil { + log.Error().Err(err).Msg(ErrLokiPush) + } + } + }() +} diff --git a/integration-tests/load/vrfv2/vrfv2_test.go b/integration-tests/load/vrfv2/vrfv2_test.go new file mode 100644 index 00000000000..1a79fce9c39 --- /dev/null +++ b/integration-tests/load/vrfv2/vrfv2_test.go @@ -0,0 +1,76 @@ +package loadvrfv2 + +import ( + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions" + "github.com/smartcontractkit/wasp" + "github.com/stretchr/testify/require" + "testing" +) + +func TestVRFV2Load(t *testing.T) { + cfg, err := ReadConfig() + require.NoError(t, err) + env, vrfv2Contracts, key, err := vrfv2_actions.SetupLocalLoadTestEnv(cfg.Common.NodeFunds, cfg.Common.SubFunds) + require.NoError(t, err) + + labels := map[string]string{ + "branch": "vrfv2_healthcheck", + "commit": "vrfv2_healthcheck", + } + + singleFeedConfig := &wasp.Config{ + T: t, + LoadType: wasp.RPS, + GenName: "gun", + Gun: SingleFeedGun(vrfv2Contracts, key), + Labels: labels, + LokiConfig: wasp.NewEnvLokiConfig(), + } + + multiFeedConfig := &wasp.Config{ + T: t, + LoadType: wasp.VU, + GenName: "vu", + VU: NewJobVolumeVU(cfg.SoakVolume.Pace.Duration(), 1, env.GetAPIs(), env.Geth.EthClient, vrfv2Contracts), + Labels: labels, + LokiConfig: wasp.NewEnvLokiConfig(), + } + + MonitorLoadStats(t, vrfv2Contracts, labels) + + // is our "job" stable at all, no memory leaks, no flaking performance under some RPS? + t.Run("vrfv2 soak test", func(t *testing.T) { + singleFeedConfig.Schedule = wasp.Plain(cfg.Soak.RPS, cfg.Soak.Duration.Duration()) + _, err := wasp.NewProfile(). + Add(wasp.NewGenerator(singleFeedConfig)). + Run(true) + require.NoError(t, err) + }) + + // what are the limits for one "job", figuring out the max/optimal performance params by increasing RPS and varying configuration + t.Run("vrfv2 load test", func(t *testing.T) { + singleFeedConfig.Schedule = wasp.Line(cfg.Load.RPSFrom, cfg.Load.RPSTo, cfg.Load.Duration.Duration()) + _, err = wasp.NewProfile(). + Add(wasp.NewGenerator(singleFeedConfig)). + Run(true) + require.NoError(t, err) + }) + + // how many "jobs" of the same type we can run at once at a stable load with optimal configuration? + t.Run("vrfv2 volume soak test", func(t *testing.T) { + multiFeedConfig.Schedule = wasp.Plain(cfg.SoakVolume.Products, cfg.SoakVolume.Duration.Duration()) + _, err = wasp.NewProfile(). + Add(wasp.NewGenerator(multiFeedConfig)). + Run(true) + require.NoError(t, err) + }) + + // what are the limits if we add more and more "jobs/products" of the same type, each "job" have a stable RPS we vary only amount of jobs + t.Run("vrfv2 volume load test", func(t *testing.T) { + multiFeedConfig.Schedule = wasp.Line(cfg.LoadVolume.ProductsFrom, cfg.LoadVolume.ProductsTo, cfg.LoadVolume.Duration.Duration()) + _, err = wasp.NewProfile(). + Add(wasp.NewGenerator(multiFeedConfig)). + Run(true) + require.NoError(t, err) + }) +} diff --git a/integration-tests/load/vrfv2/vu.go b/integration-tests/load/vrfv2/vu.go new file mode 100644 index 00000000000..d8e0702dd50 --- /dev/null +++ b/integration-tests/load/vrfv2/vu.go @@ -0,0 +1,91 @@ +package loadvrfv2 + +import ( + "github.com/pkg/errors" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions" + vrfConst "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" + "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/wasp" + "time" +) + +/* JobVolumeVU is a "virtual user" that creates a VRFv2 job and constantly requesting new randomness only for this job instance */ + +type JobVolumeVU struct { + pace time.Duration + minIncomingConfirmations uint16 + nodes []*client.ChainlinkClient + bc blockchain.EVMClient + contracts *vrfv2_actions.VRFV2Contracts + jobs []vrfv2_actions.VRFV2JobInfo + keyHash [32]byte + stop chan struct{} +} + +func NewJobVolumeVU( + pace time.Duration, + confirmations uint16, + nodes []*client.ChainlinkClient, + bc blockchain.EVMClient, + contracts *vrfv2_actions.VRFV2Contracts, +) *JobVolumeVU { + return &JobVolumeVU{ + pace: pace, + minIncomingConfirmations: confirmations, + nodes: nodes, + bc: bc, + contracts: contracts, + stop: make(chan struct{}, 1), + } +} + +func (m *JobVolumeVU) Clone(_ *wasp.Generator) wasp.VirtualUser { + return &JobVolumeVU{ + pace: m.pace, + minIncomingConfirmations: m.minIncomingConfirmations, + nodes: m.nodes, + bc: m.bc, + contracts: m.contracts, + stop: make(chan struct{}, 1), + } +} + +func (m *JobVolumeVU) Setup(_ *wasp.Generator) error { + jobs, err := vrfv2_actions.CreateVRFV2Jobs(m.nodes, m.contracts.Coordinator, m.bc, m.minIncomingConfirmations) + if err != nil { + return errors.Wrap(err, "failed to create VRFv2 jobs in setup") + } + m.jobs = jobs + m.keyHash = jobs[0].KeyHash + return nil +} + +func (m *JobVolumeVU) Teardown(_ *wasp.Generator) error { + return nil +} + +func (m *JobVolumeVU) Call(l *wasp.Generator) { + time.Sleep(m.pace) + err := m.contracts.LoadTestConsumer.RequestRandomness( + m.keyHash, + vrfConst.SubID, + vrfConst.MinimumConfirmations, + vrfConst.CallbackGasLimit, + vrfConst.NumberOfWords, + vrfConst.RandomnessRequestCountPerRequest, + ) + if err != nil { + l.ResponsesChan <- &wasp.CallResult{Error: err.Error(), Failed: true} + return + } + l.ResponsesChan <- &wasp.CallResult{} +} + +func (m *JobVolumeVU) Stop(_ *wasp.Generator) { + m.stop <- struct{}{} +} + +func (m *JobVolumeVU) StopChan() chan struct{} { + return m.stop +} diff --git a/integration-tests/smoke/README.md b/integration-tests/smoke/README.md new file mode 100644 index 00000000000..f8a9e94211b --- /dev/null +++ b/integration-tests/smoke/README.md @@ -0,0 +1,52 @@ +## Smoke tests (local environments) + +These products are using local `testcontainers-go` environments: +- RunLog (Direct request) +- Cron +- Flux +- VRFv1 +- VRFv2 + +### Usage +``` +go test -v -run ${TestName} +``` +### Re-using environments +Configuration is still WIP, but you can make your environment re-usable by providing JSON config. + +Create `test_env.json` in the same dir +``` +export TEST_ENV_CONFIG_PATH=test_env.json +``` + +Here is an example for 3 nodes cluster +``` +{ + "networks": [ + "epic" + ], + "mockserver": { + "container_name": "mockserver", + "external_adapters_mock_urls": [ + "/epico1" + ] + }, + "geth": { + "container_name": "geth" + }, + "nodes": [ + { + "container_name": "cl-node-0", + "db_container_name": "cl-db-0" + }, + { + "container_name": "cl-node-1", + "db_container_name": "cl-db-1" + }, + { + "container_name": "cl-node-2", + "db_container_name": "cl-db-2" + } + ] +} +``` \ No newline at end of file From b529e0ac3ebc9c40a58dc5e9304b19591893b856 Mon Sep 17 00:00:00 2001 From: Ilja Pavlovs Date: Wed, 9 Aug 2023 14:00:25 +0300 Subject: [PATCH 121/270] Chore/vrf 538 setup scripts for vrfv (#10005) * fix VRF V3 setup script * adding issue with creating eth keys * fixing lint issues * adding missing sh script * delete * fix: setup envs script (#10016) * fix: setup envs script * feat: check for vrf keys * adding job creation * refactoring * adding export/import vrf key; final changes * small fix * PR comments * small fix * PR comments --------- Co-authored-by: Makram --- core/scripts/ocr2vrf/setup_ocr2vrf.go | 2 +- .../vrfv2/testnet/constants/constants.go | 28 ++ .../docker/db/create-multiple-databases.sh | 20 + .../vrfv2/testnet/docker/docker-compose.yml | 140 ++++++ core/scripts/vrfv2/testnet/docker/sample.env | 5 + .../testnet/docker/secrets/apicredentials | 2 + .../vrfv2/testnet/docker/secrets/password.txt | 1 + .../testnet/docker/toml-config/base.toml | 31 ++ .../vrfv2/testnet/docker/toml-config/bhf.toml | 7 + .../vrfv2/testnet/docker/toml-config/bhs.toml | 7 + .../testnet/docker/toml-config/rpc-nodes.toml | 8 + .../testnet/docker/toml-config/secrets.toml | 4 + .../toml-config/vrf-backup-other-chains.toml | 20 + .../docker/toml-config/vrf-backup.toml | 3 + .../docker/toml-config/vrf-primary.toml | 15 + .../wait-for-others/docker-wait-for-it.sh | 178 +++++++ .../wait-for-others/docker-wait-for-others.sh | 9 + core/scripts/vrfv2/testnet/jobs/jobs.go | 69 +++ core/scripts/vrfv2/testnet/main.go | 39 +- .../vrfv2/testnet/scripts/super_scripts.go | 416 ++++++++++++++++ .../vrfv2/testnet/{ => scripts}/util.go | 39 +- .../vrfv2/testnet/setup-envs/README.md | 44 ++ core/scripts/vrfv2/testnet/setup-envs/main.go | 447 ++++++++++++++++++ core/scripts/vrfv2/testnet/super_scripts.go | 297 ------------ 24 files changed, 1497 insertions(+), 334 deletions(-) create mode 100644 core/scripts/vrfv2/testnet/constants/constants.go create mode 100755 core/scripts/vrfv2/testnet/docker/db/create-multiple-databases.sh create mode 100644 core/scripts/vrfv2/testnet/docker/docker-compose.yml create mode 100644 core/scripts/vrfv2/testnet/docker/sample.env create mode 100644 core/scripts/vrfv2/testnet/docker/secrets/apicredentials create mode 100644 core/scripts/vrfv2/testnet/docker/secrets/password.txt create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/base.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/bhf.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/bhs.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/rpc-nodes.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/secrets.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup-other-chains.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup.toml create mode 100644 core/scripts/vrfv2/testnet/docker/toml-config/vrf-primary.toml create mode 100755 core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-it.sh create mode 100755 core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-others.sh create mode 100644 core/scripts/vrfv2/testnet/jobs/jobs.go create mode 100644 core/scripts/vrfv2/testnet/scripts/super_scripts.go rename core/scripts/vrfv2/testnet/{ => scripts}/util.go (85%) create mode 100644 core/scripts/vrfv2/testnet/setup-envs/README.md create mode 100644 core/scripts/vrfv2/testnet/setup-envs/main.go delete mode 100644 core/scripts/vrfv2/testnet/super_scripts.go diff --git a/core/scripts/ocr2vrf/setup_ocr2vrf.go b/core/scripts/ocr2vrf/setup_ocr2vrf.go index b3643746577..ab43dc0180f 100644 --- a/core/scripts/ocr2vrf/setup_ocr2vrf.go +++ b/core/scripts/ocr2vrf/setup_ocr2vrf.go @@ -434,7 +434,7 @@ func setupOCR2VRFNodesForInfraWithForwarder(e helpers.Environment) { true, // forwardingAllowed "", // P2P Bootstrapper e.ChainID, - sendingKeys[i], + sendingKeys[adjustedIndex], dkgEncrypters[adjustedIndex], dkgSigners[adjustedIndex], *keyID, diff --git a/core/scripts/vrfv2/testnet/constants/constants.go b/core/scripts/vrfv2/testnet/constants/constants.go new file mode 100644 index 00000000000..5d2d67e7b34 --- /dev/null +++ b/core/scripts/vrfv2/testnet/constants/constants.go @@ -0,0 +1,28 @@ +package constants + +import ( + "github.com/smartcontractkit/chainlink/v2/core/assets" + "math/big" +) + +var ( + SubscriptionBalanceJuels = assets.Ether(10).ToInt() + + // optional flags + FallbackWeiPerUnitLink = big.NewInt(6e16) + + MinConfs = 3 + NodeSendingKeyFundingAmountGwei = assets.GWei(0).Int64() //100000000 = 0.1 ETH + MaxGasLimit = int64(2.5e6) + StalenessSeconds = int64(86400) + GasAfterPayment = int64(33285) + FlatFeeTier1 = int64(500) + FlatFeeTier2 = int64(500) + FlatFeeTier3 = int64(500) + FlatFeeTier4 = int64(500) + FlatFeeTier5 = int64(500) + ReqsForTier2 = int64(0) + ReqsForTier3 = int64(0) + ReqsForTier4 = int64(0) + ReqsForTier5 = int64(0) +) diff --git a/core/scripts/vrfv2/testnet/docker/db/create-multiple-databases.sh b/core/scripts/vrfv2/testnet/docker/db/create-multiple-databases.sh new file mode 100755 index 00000000000..9b0c7b0d68b --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/db/create-multiple-databases.sh @@ -0,0 +1,20 @@ +#!/bin/bash + +set -e +set -u + +function create_user_and_database() { + local database=$1 + echo " Creating user and database '$database'" + psql -v ON_ERROR_STOP=1 --username postgres <<-EOSQL + CREATE DATABASE $database; +EOSQL +} + +if [ -n "$POSTGRES_MULTIPLE_DATABASES" ]; then + echo "Multiple database creation requested: $POSTGRES_MULTIPLE_DATABASES" + for db in $(echo $POSTGRES_MULTIPLE_DATABASES | tr ',' ' '); do + create_user_and_database $db + done + echo "Multiple databases created" +fi diff --git a/core/scripts/vrfv2/testnet/docker/docker-compose.yml b/core/scripts/vrfv2/testnet/docker/docker-compose.yml new file mode 100644 index 00000000000..d31c50f3463 --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/docker-compose.yml @@ -0,0 +1,140 @@ +version: '3.5' +services: + chainlink-node-0: + container_name: vrf-primary-node + image: ${NODE_IMAGE_VERSION} + entrypoint: + - /opt/docker-wait-for-others.sh + - database:5432 + - -- + command: chainlink -config /opt/config/base.toml -config /opt/config/rpc-nodes.toml -config /opt/config/vrf-primary.toml node start -p /run/secrets/node_password -a /run/secrets/apicredentials + environment: + - CL_DATABASE_URL=postgresql://postgres:$CHAINLINK_PGPASSWORD@database:5432/chainlink_0_test?sslmode=disable + platform: "linux/x86_64" + volumes: + - ./wait-for-others/docker-wait-for-it.sh:/opt/docker-wait-for-it.sh:ro + - ./wait-for-others/docker-wait-for-others.sh:/opt/docker-wait-for-others.sh:ro + - ./toml-config:/opt/config:ro + ports: + - "6610:6688" + - "6059:6060" + secrets: + - apicredentials + - node_password + depends_on: + - database + + chainlink-node-1: + container_name: vrf-backup-node + image: ${NODE_IMAGE_VERSION} + entrypoint: + - /opt/docker-wait-for-others.sh + - database:5432 + - -- + command: chainlink node -config /opt/config/base.toml -config /opt/config/rpc-nodes.toml -config /opt/config/vrf-primary.toml -config /opt/config/vrf-backup.toml start -p /run/secrets/node_password -a /run/secrets/apicredentials + environment: + - CL_DATABASE_URL=postgresql://postgres:$CHAINLINK_PGPASSWORD@database:5432/chainlink_1_test?sslmode=disable + platform: "linux/x86_64" + volumes: + - ./wait-for-others/docker-wait-for-it.sh:/opt/docker-wait-for-it.sh:ro + - ./wait-for-others/docker-wait-for-others.sh:/opt/docker-wait-for-others.sh:ro + - ./toml-config:/opt/config:ro + ports: + - "6611:6688" + - "6060:6060" + secrets: + - apicredentials + - node_password + depends_on: + - database + + chainlink-node-2: + container_name: bhs-node + image: ${NODE_IMAGE_VERSION} + entrypoint: + - /opt/docker-wait-for-others.sh + - database:5432 + - -- + command: chainlink node -config /opt/config/base.toml -config /opt/config/rpc-nodes.toml -config /opt/config/bhs.toml start -p /run/secrets/node_password -a /run/secrets/apicredentials + volumes: + - ./wait-for-others/docker-wait-for-it.sh:/opt/docker-wait-for-it.sh:ro + - ./wait-for-others/docker-wait-for-others.sh:/opt/docker-wait-for-others.sh:ro + - ./toml-config:/opt/config:ro + environment: + - CL_DATABASE_URL=postgresql://postgres:$CHAINLINK_PGPASSWORD@database:5432/chainlink_2_test?sslmode=disable + platform: "linux/x86_64" + ports: + - "6612:6688" + - "6062:6060" + secrets: + - apicredentials + - node_password + depends_on: + - database + + chainlink-node-3: + container_name: bhs-backup-node + image: ${NODE_IMAGE_VERSION} + entrypoint: + - /opt/docker-wait-for-others.sh + - database:5432 + - -- + command: chainlink node -config /opt/config/base.toml -config /opt/config/rpc-nodes.toml -config /opt/config/bhs.toml start -p /run/secrets/node_password -a /run/secrets/apicredentials + volumes: + - ./wait-for-others/docker-wait-for-it.sh:/opt/docker-wait-for-it.sh:ro + - ./wait-for-others/docker-wait-for-others.sh:/opt/docker-wait-for-others.sh:ro + - ./toml-config:/opt/config:ro + environment: + - CL_DATABASE_URL=postgresql://postgres:$CHAINLINK_PGPASSWORD@database:5432/chainlink_3_test?sslmode=disable + platform: "linux/x86_64" + ports: + - "6613:6688" + - "6063:6060" + secrets: + - apicredentials + - node_password + depends_on: + - database + + chainlink-node-4: + container_name: bhf-node + image: ${NODE_IMAGE_VERSION} + entrypoint: + - /opt/docker-wait-for-others.sh + - database:5432 + - -- + command: chainlink node -config /opt/config/base.toml -config /opt/config/rpc-nodes.toml -config /opt/config/bhf.toml start -p /run/secrets/node_password -a /run/secrets/apicredentials + volumes: + - ./wait-for-others/docker-wait-for-it.sh:/opt/docker-wait-for-it.sh:ro + - ./wait-for-others/docker-wait-for-others.sh:/opt/docker-wait-for-others.sh:ro + - ./toml-config:/opt/config:ro + environment: + - CL_DATABASE_URL=postgresql://postgres:$CHAINLINK_PGPASSWORD@database:5432/chainlink_4_test?sslmode=disable + platform: "linux/x86_64" + ports: + - "6614:6688" + - "6064:6060" + secrets: + - apicredentials + - node_password + depends_on: + - database + + database: + image: postgres:11.6 + volumes: + - ./db/create-multiple-databases.sh:/docker-entrypoint-initdb.d/create-multiple-databases.sh + environment: + POSTGRES_PASSWORD: chainlink + POSTGRES_MULTIPLE_DATABASES: chainlink_0_test,chainlink_1_test,chainlink_2_test,chainlink_3_test,chainlink_4_test + ports: + - "5432:5432" + +secrets: + node_password: + file: ./secrets/password.txt + apicredentials: + file: ./secrets/apicredentials + +volumes: + docker-compose-db: diff --git a/core/scripts/vrfv2/testnet/docker/sample.env b/core/scripts/vrfv2/testnet/docker/sample.env new file mode 100644 index 00000000000..4fb63b40b6c --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/sample.env @@ -0,0 +1,5 @@ +#used for docker compose variable only +NODE_IMAGE_VERSION=public.ecr.aws/chainlink/chainlink:2.3.0 + +CHAINLINK_DB_NAME=chainlink +CHAINLINK_PGPASSWORD=chainlink diff --git a/core/scripts/vrfv2/testnet/docker/secrets/apicredentials b/core/scripts/vrfv2/testnet/docker/secrets/apicredentials new file mode 100644 index 00000000000..fa32a892a2c --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/secrets/apicredentials @@ -0,0 +1,2 @@ +test@test.com +1234567890password diff --git a/core/scripts/vrfv2/testnet/docker/secrets/password.txt b/core/scripts/vrfv2/testnet/docker/secrets/password.txt new file mode 100644 index 00000000000..54714ef7730 --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/secrets/password.txt @@ -0,0 +1 @@ +1234567890password diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/base.toml b/core/scripts/vrfv2/testnet/docker/toml-config/base.toml new file mode 100644 index 00000000000..0bb83beb94a --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/base.toml @@ -0,0 +1,31 @@ +RootDir = '/home/chainlink' + +[Database] +MaxIdleConns = 20 +MaxOpenConns = 40 +MigrateOnStartup = true + +[Log] +Level = 'debug' +JSONConsole = true + +[Log.File] +MaxSize = '0b' + +[WebServer] +AllowOrigins = '*' +HTTPPort = 6688 +SecureCookies = false + +[WebServer.RateLimit] +Authenticated = 2000 +Unauthenticated = 100 + +[WebServer.TLS] +HTTPSPort = 0 + +[P2P] +[P2P.V2] +Enabled = true +AnnounceAddresses = ['0.0.0.0:6690'] +ListenAddresses = ['0.0.0.0:6690'] diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/bhf.toml b/core/scripts/vrfv2/testnet/docker/toml-config/bhf.toml new file mode 100644 index 00000000000..9de5eb4328e --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/bhf.toml @@ -0,0 +1,7 @@ + +[Feature] +LogPoller = true + +[[EVM]] +ChainID = '11155111' +FinalityDepth = 10 diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/bhs.toml b/core/scripts/vrfv2/testnet/docker/toml-config/bhs.toml new file mode 100644 index 00000000000..9de5eb4328e --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/bhs.toml @@ -0,0 +1,7 @@ + +[Feature] +LogPoller = true + +[[EVM]] +ChainID = '11155111' +FinalityDepth = 10 diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/rpc-nodes.toml b/core/scripts/vrfv2/testnet/docker/toml-config/rpc-nodes.toml new file mode 100644 index 00000000000..c977ee4a9ca --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/rpc-nodes.toml @@ -0,0 +1,8 @@ +[[EVM]] +ChainID = "11155111" + +[[EVM.Nodes]] +HTTPURL = "" +Name = "RPC Node" +SendOnly = false +WSURL = "" diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/secrets.toml b/core/scripts/vrfv2/testnet/docker/toml-config/secrets.toml new file mode 100644 index 00000000000..00d12b0660a --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/secrets.toml @@ -0,0 +1,4 @@ +[Password] +Keystore = 'mysecretkeystorepassword' +[Database] +URL = 'postgresql://postgres:mysecretpassword@host.docker.internal:5432/postgres?sslmode=disable' diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup-other-chains.toml b/core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup-other-chains.toml new file mode 100644 index 00000000000..a39c6b15c57 --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup-other-chains.toml @@ -0,0 +1,20 @@ +[Feature] +LogPoller = false #VRF V2 uses Log Broadcast3er instead of Log poller + +[[EVM]] +ChainID = '11155111' +BlockBackfillDepth = 500 +LogBackfillBatchSize = 1000 +MinIncomingConfirmations = 100 +RPCDefaultBatchSize = 25 + +[EVM.Transactions] +MaxInFlight = 128 +MaxQueued = 0 + +[EVM.GasEstimator] +LimitDefault = 3500000 +PriceMax = '30 gwei' + +[EVM.GasEstimator.BlockHistory] +BatchSize = 100 diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup.toml b/core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup.toml new file mode 100644 index 00000000000..92b9e717b2f --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/vrf-backup.toml @@ -0,0 +1,3 @@ +[[EVM]] +ChainID = '11155111' +MinIncomingConfirmations = 100 diff --git a/core/scripts/vrfv2/testnet/docker/toml-config/vrf-primary.toml b/core/scripts/vrfv2/testnet/docker/toml-config/vrf-primary.toml new file mode 100644 index 00000000000..67cd33659fb --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/toml-config/vrf-primary.toml @@ -0,0 +1,15 @@ +[Feature] +LogPoller = false #VRF V2 uses Log Broadcast3er instead of Log poller + +[[EVM]] +ChainID = '11155111' +BlockBackfillDepth = 500 +MinIncomingConfirmations = 3 + +[EVM.Transactions] +MaxQueued = 10000 + +[EVM.GasEstimator] +LimitDefault = 3500000 +PriceMax = '30 gwei' +FeeCapDefault = '20 gwei' diff --git a/core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-it.sh b/core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-it.sh new file mode 100755 index 00000000000..7f9943c9890 --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-it.sh @@ -0,0 +1,178 @@ +#!/usr/bin/env bash +# From https://github.com/vishnubob/wait-for-it +# Use this script to test if a given TCP host/port are available + +cmdname=$(basename $0) + +echoerr() { if [[ $QUIET -ne 1 ]]; then echo "$@" 1>&2; fi } + +usage() +{ + cat << USAGE >&2 +Usage: + $cmdname host:port [-s] [-t timeout] [-- command args] + -h HOST | --host=HOST Host or IP under test + -p PORT | --port=PORT TCP port under test + Alternatively, you specify the host and port as host:port + -s | --strict Only execute subcommand if the test succeeds + -q | --quiet Don't output any status messages + -t TIMEOUT | --timeout=TIMEOUT + Timeout in seconds, zero for no timeout + -- COMMAND ARGS Execute command with args after the test finishes +USAGE + exit 1 +} + +wait_for() +{ + if [[ $TIMEOUT -gt 0 ]]; then + echoerr "$cmdname: waiting $TIMEOUT seconds for $HOST:$PORT" + else + echoerr "$cmdname: waiting for $HOST:$PORT without a timeout" + fi + start_ts=$(date +%s) + while : + do + if [[ $ISBUSY -eq 1 ]]; then + nc -z $HOST $PORT + result=$? + else + (echo > /dev/tcp/$HOST/$PORT) >/dev/null 2>&1 + result=$? + fi + if [[ $result -eq 0 ]]; then + end_ts=$(date +%s) + echoerr "$cmdname: $HOST:$PORT is available after $((end_ts - start_ts)) seconds" + break + fi + sleep 1 + done + return $result +} + +wait_for_wrapper() +{ + # In order to support SIGINT during timeout: http://unix.stackexchange.com/a/57692 + if [[ $QUIET -eq 1 ]]; then + timeout $BUSYTIMEFLAG $TIMEOUT $0 --quiet --child --host=$HOST --port=$PORT --timeout=$TIMEOUT & + else + timeout $BUSYTIMEFLAG $TIMEOUT $0 --child --host=$HOST --port=$PORT --timeout=$TIMEOUT & + fi + PID=$! + trap "kill -INT -$PID" INT + wait $PID + RESULT=$? + if [[ $RESULT -ne 0 ]]; then + echoerr "$cmdname: timeout occurred after waiting $TIMEOUT seconds for $HOST:$PORT" + fi + return $RESULT +} + +# process arguments +while [[ $# -gt 0 ]] +do + case "$1" in + *:* ) + hostport=(${1//:/ }) + HOST=${hostport[0]} + PORT=${hostport[1]} + shift 1 + ;; + --child) + CHILD=1 + shift 1 + ;; + -q | --quiet) + QUIET=1 + shift 1 + ;; + -s | --strict) + STRICT=1 + shift 1 + ;; + -h) + HOST="$2" + if [[ $HOST == "" ]]; then break; fi + shift 2 + ;; + --host=*) + HOST="${1#*=}" + shift 1 + ;; + -p) + PORT="$2" + if [[ $PORT == "" ]]; then break; fi + shift 2 + ;; + --port=*) + PORT="${1#*=}" + shift 1 + ;; + -t) + TIMEOUT="$2" + if [[ $TIMEOUT == "" ]]; then break; fi + shift 2 + ;; + --timeout=*) + TIMEOUT="${1#*=}" + shift 1 + ;; + --) + shift + CLI=("$@") + break + ;; + --help) + usage + ;; + *) + echoerr "Unknown argument: $1" + usage + ;; + esac +done + +if [[ "$HOST" == "" || "$PORT" == "" ]]; then + echoerr "Error: you need to provide a host and port to test." + usage +fi + +TIMEOUT=${TIMEOUT:-15} +STRICT=${STRICT:-0} +CHILD=${CHILD:-0} +QUIET=${QUIET:-0} + +# check to see if timeout is from busybox? +# check to see if timeout is from busybox? +TIMEOUT_PATH=$(realpath $(which timeout)) +if [[ $TIMEOUT_PATH =~ "busybox" ]]; then + ISBUSY=1 + BUSYTIMEFLAG="-t" +else + ISBUSY=0 + BUSYTIMEFLAG="" +fi + +if [[ $CHILD -gt 0 ]]; then + wait_for + RESULT=$? + exit $RESULT +else + if [[ $TIMEOUT -gt 0 ]]; then + wait_for_wrapper + RESULT=$? + else + wait_for + RESULT=$? + fi +fi + +if [[ $CLI != "" ]]; then + if [[ $RESULT -ne 0 && $STRICT -eq 1 ]]; then + echoerr "$cmdname: strict mode, refusing to execute subprocess" + exit $RESULT + fi + exec "${CLI[@]}" +else + exit $RESULT +fi diff --git a/core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-others.sh b/core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-others.sh new file mode 100755 index 00000000000..88684e5d18f --- /dev/null +++ b/core/scripts/vrfv2/testnet/docker/wait-for-others/docker-wait-for-others.sh @@ -0,0 +1,9 @@ +#!/usr/bin/env bash + +while [ "$#" -gt 1 ] && [ "$1" != "--" ]; do + /opt/docker-wait-for-it.sh $1 + shift +done + +# Hand off to the CMD +exec "$@" diff --git a/core/scripts/vrfv2/testnet/jobs/jobs.go b/core/scripts/vrfv2/testnet/jobs/jobs.go new file mode 100644 index 00000000000..335a264b27c --- /dev/null +++ b/core/scripts/vrfv2/testnet/jobs/jobs.go @@ -0,0 +1,69 @@ +package jobs + +var ( + VRFJobFormatted = `type = "vrf" +name = "vrf_v2" +schemaVersion = 1 +coordinatorAddress = "%s" +batchCoordinatorAddress = "%s" +batchFulfillmentEnabled = %t +batchFulfillmentGasMultiplier = 1.1 +publicKey = "%s" +minIncomingConfirmations = %d +evmChainID = "%d" +fromAddresses = ["%s"] +pollPeriod = "300ms" +requestTimeout = "30m0s" +observationSource = """decode_log [type=ethabidecodelog + abi="RandomWordsRequested(bytes32 indexed keyHash,uint256 requestId,uint256 preSeed,uint64 indexed subId,uint16 minimumRequestConfirmations,uint32 callbackGasLimit,uint32 numWords,address indexed sender)" + data="$(jobRun.logData)" + topics="$(jobRun.logTopics)"] +vrf [type=vrfv2 + publicKey="$(jobSpec.publicKey)" + requestBlockHash="$(jobRun.logBlockHash)" + requestBlockNumber="$(jobRun.logBlockNumber)" + topics="$(jobRun.logTopics)"] +estimate_gas [type=estimategaslimit + to="%s" + multiplier="1.1" + data="$(vrf.output)"] +simulate [type=ethcall + to="%s" + gas="$(estimate_gas)" + gasPrice="$(jobSpec.maxGasPrice)" + extractRevertReason=true + contract="%s" + data="$(vrf.output)"] +decode_log->vrf->estimate_gas->simulate +"""` + + BHSJobFormatted = `type = "blockhashstore" +schemaVersion = 1 +name = "blockhashstore" +forwardingAllowed = false +coordinatorV2Address = "%s" +waitBlocks = %d +lookbackBlocks = %d +blockhashStoreAddress = "%s" +pollPeriod = "30s" +runTimeout = "1m0s" +evmChainID = "%d" +fromAddresses = ["%s"] +` + BHFJobFormatted = `type = "blockheaderfeeder" +schemaVersion = 1 +name = "blockheaderfeeder" +forwardingAllowed = false +coordinatorV2Address = "%s" +waitBlocks = 256 +lookbackBlocks = 1_000 +blockhashStoreAddress = "%s" +batchBlockhashStoreAddress = "%s" +pollPeriod = "10s" +runTimeout = "30s" +evmChainID = "%d" +fromAddresses = ["%s"] +getBlockhashesBatchSize = 50 +storeBlockhashesBatchSize = 10 +` +) diff --git a/core/scripts/vrfv2/testnet/main.go b/core/scripts/vrfv2/testnet/main.go index ffaa1929fb3..0a80fc0b37d 100644 --- a/core/scripts/vrfv2/testnet/main.go +++ b/core/scripts/vrfv2/testnet/main.go @@ -6,6 +6,7 @@ import ( "encoding/hex" "flag" "fmt" + "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/scripts" "log" "math/big" "os" @@ -347,7 +348,7 @@ func main() { cmd := flag.NewFlagSet("batch-bhs-deploy", flag.ExitOnError) bhsAddr := cmd.String("bhs-address", "", "address of the blockhash store contract") helpers.ParseArgs(cmd, os.Args[2:], "bhs-address") - deployBatchBHS(e, common.HexToAddress(*bhsAddr)) + scripts.DeployBatchBHS(e, common.HexToAddress(*bhsAddr)) case "batch-bhs-store": cmd := flag.NewFlagSet("batch-bhs-store", flag.ExitOnError) batchAddr := cmd.String("batch-bhs-address", "", "address of the batch bhs contract") @@ -480,14 +481,14 @@ func main() { helpers.PanicErr(err) fmt.Println("latest head number:", h.Number.String()) case "bhs-deploy": - deployBHS(e) + scripts.DeployBHS(e) case "coordinator-deploy": coordinatorDeployCmd := flag.NewFlagSet("coordinator-deploy", flag.ExitOnError) coordinatorDeployLinkAddress := coordinatorDeployCmd.String("link-address", "", "address of link token") coordinatorDeployBHSAddress := coordinatorDeployCmd.String("bhs-address", "", "address of bhs") coordinatorDeployLinkEthFeedAddress := coordinatorDeployCmd.String("link-eth-feed", "", "address of link-eth-feed") helpers.ParseArgs(coordinatorDeployCmd, os.Args[2:], "link-address", "bhs-address", "link-eth-feed") - deployCoordinator(e, *coordinatorDeployLinkAddress, *coordinatorDeployBHSAddress, *coordinatorDeployLinkEthFeedAddress) + scripts.DeployCoordinator(e, *coordinatorDeployLinkAddress, *coordinatorDeployBHSAddress, *coordinatorDeployLinkEthFeedAddress) case "coordinator-get-config": cmd := flag.NewFlagSet("coordinator-get-config", flag.ExitOnError) coordinatorAddress := cmd.String("coordinator-address", "", "coordinator address") @@ -496,7 +497,7 @@ func main() { coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*coordinatorAddress), e.Ec) helpers.PanicErr(err) - printCoordinatorConfig(coordinator) + scripts.PrintCoordinatorConfig(coordinator) case "coordinator-set-config": cmd := flag.NewFlagSet("coordinator-set-config", flag.ExitOnError) setConfigAddress := cmd.String("coordinator-address", "", "coordinator address") @@ -519,7 +520,7 @@ func main() { coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*setConfigAddress), e.Ec) helpers.PanicErr(err) - setCoordinatorConfig( + scripts.SetCoordinatorConfig( e, *coordinator, uint16(*minConfs), @@ -553,7 +554,7 @@ func main() { *registerKeyUncompressedPubKey = strings.Replace(*registerKeyUncompressedPubKey, "0x", "04", 1) } - registerCoordinatorProvingKey(e, *coordinator, *registerKeyUncompressedPubKey, *registerKeyOracleAddress) + scripts.RegisterCoordinatorProvingKey(e, *coordinator, *registerKeyUncompressedPubKey, *registerKeyOracleAddress) case "coordinator-deregister-key": coordinatorDeregisterKey := flag.NewFlagSet("coordinator-deregister-key", flag.ExitOnError) deregisterKeyAddress := coordinatorDeregisterKey.String("address", "", "coordinator address") @@ -681,14 +682,14 @@ func main() { helpers.PanicErr(err) fmt.Printf("Request config %+v Rw %+v Rid %+v\n", rc, rw, rid) case "deploy-universe": - deployUniverse(e) + scripts.DeployUniverseViaCLI(e) case "eoa-consumer-deploy": consumerDeployCmd := flag.NewFlagSet("eoa-consumer-deploy", flag.ExitOnError) consumerCoordinator := consumerDeployCmd.String("coordinator-address", "", "coordinator address") consumerLinkAddress := consumerDeployCmd.String("link-address", "", "link-address") helpers.ParseArgs(consumerDeployCmd, os.Args[2:], "coordinator-address", "link-address") - eoaDeployConsumer(e, *consumerCoordinator, *consumerLinkAddress) + scripts.EoaDeployConsumer(e, *consumerCoordinator, *consumerLinkAddress) case "eoa-load-test-consumer-deploy": loadTestConsumerDeployCmd := flag.NewFlagSet("eoa-load-test-consumer-deploy", flag.ExitOnError) consumerCoordinator := loadTestConsumerDeployCmd.String("coordinator-address", "", "coordinator address") @@ -705,20 +706,14 @@ func main() { loadTestConsumerDeployCmd := flag.NewFlagSet("eoa-load-test-consumer-with-metrics-deploy", flag.ExitOnError) consumerCoordinator := loadTestConsumerDeployCmd.String("coordinator-address", "", "coordinator address") helpers.ParseArgs(loadTestConsumerDeployCmd, os.Args[2:], "coordinator-address") - _, tx, _, err := vrf_load_test_with_metrics.DeployVRFV2LoadTestWithMetrics( - e.Owner, - e.Ec, - common.HexToAddress(*consumerCoordinator), - ) - helpers.PanicErr(err) - helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) + scripts.EoaLoadTestConsumerWithMetricsDeploy(e, *consumerCoordinator) case "eoa-create-sub": createSubCmd := flag.NewFlagSet("eoa-create-sub", flag.ExitOnError) coordinatorAddress := createSubCmd.String("coordinator-address", "", "coordinator address") helpers.ParseArgs(createSubCmd, os.Args[2:], "coordinator-address") coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*coordinatorAddress), e.Ec) helpers.PanicErr(err) - eoaCreateSub(e, *coordinator) + scripts.EoaCreateSub(e, *coordinator) case "eoa-add-sub-consumer": addSubConsCmd := flag.NewFlagSet("eoa-add-sub-consumer", flag.ExitOnError) coordinatorAddress := addSubConsCmd.String("coordinator-address", "", "coordinator address") @@ -727,7 +722,7 @@ func main() { helpers.ParseArgs(addSubConsCmd, os.Args[2:], "coordinator-address", "sub-id", "consumer-address") coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*coordinatorAddress), e.Ec) helpers.PanicErr(err) - eoaAddConsumerToSub(e, *coordinator, uint64(*subID), *consumerAddress) + scripts.EoaAddConsumerToSub(e, *coordinator, uint64(*subID), *consumerAddress) case "eoa-create-fund-authorize-sub": // Lets just treat the owner key as the EOA controlling the sub cfaSubCmd := flag.NewFlagSet("eoa-create-fund-authorize-sub", flag.ExitOnError) @@ -944,7 +939,7 @@ func main() { coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*coordinatorAddress), e.Ec) helpers.PanicErr(err) - eoaFundSubscription(e, *coordinator, *consumerLinkAddress, amount, uint64(*subID)) + scripts.EoaFundSubscription(e, *coordinator, *consumerLinkAddress, amount, uint64(*subID)) case "eoa-read": cmd := flag.NewFlagSet("eoa-read", flag.ExitOnError) consumerAddress := cmd.String("consumer", "", "consumer address") @@ -1112,7 +1107,7 @@ func main() { linkETHFeedAddress := cmd.String("link-eth-feed", "", "address of link-eth-feed") coordinatorAddress := cmd.String("coordinator-address", "", "address of the vrf coordinator v2 contract") helpers.ParseArgs(cmd, os.Args[2:], "link-address", "link-eth-feed", "coordinator-address") - wrapperDeploy(e, + scripts.WrapperDeploy(e, common.HexToAddress(*linkAddress), common.HexToAddress(*linkETHFeedAddress), common.HexToAddress(*coordinatorAddress)) @@ -1150,7 +1145,7 @@ func main() { maxNumWords := cmd.Uint("max-num-words", 10, "the keyhash that wrapper requests should use") helpers.ParseArgs(cmd, os.Args[2:], "wrapper-address", "key-hash") - wrapperConfigure(e, + scripts.WrapperConfigure(e, common.HexToAddress(*wrapperAddress), *wrapperGasOverhead, *coordinatorGasOverhead, @@ -1182,7 +1177,7 @@ func main() { wrapperAddress := cmd.String("wrapper-address", "", "address of the VRFV2Wrapper contract") helpers.ParseArgs(cmd, os.Args[2:], "link-address", "wrapper-address") - wrapperConsumerDeploy(e, + scripts.WrapperConsumerDeploy(e, common.HexToAddress(*linkAddress), common.HexToAddress(*wrapperAddress)) case "wrapper-consumer-request": @@ -1254,7 +1249,7 @@ func main() { helpers.ParseArgs(cmd, os.Args[2:]) _ = helpers.CalculateLatestBlockHeader(e, *blockNumber) case "wrapper-universe-deploy": - deployWrapperUniverse(e) + scripts.DeployWrapperUniverse(e) default: panic("unrecognized subcommand: " + os.Args[1]) } diff --git a/core/scripts/vrfv2/testnet/scripts/super_scripts.go b/core/scripts/vrfv2/testnet/scripts/super_scripts.go new file mode 100644 index 00000000000..ea6c9e46eab --- /dev/null +++ b/core/scripts/vrfv2/testnet/scripts/super_scripts.go @@ -0,0 +1,416 @@ +package scripts + +import ( + "context" + "encoding/hex" + "flag" + "fmt" + "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/constants" + "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/jobs" + "math/big" + "os" + "strings" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/crypto" + "github.com/shopspring/decimal" + + helpers "github.com/smartcontractkit/chainlink/core/scripts/common" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" + "github.com/smartcontractkit/chainlink/v2/core/services/signatures/secp256k1" +) + +var ( + VRFPrimaryNodeName = "vrf-primary-node" + VRFBackupNodeName = "vrf-backup-node" + BHSNodeName = "bhs-node" + BHSBackupNodeName = "bhs-backup-node" + BHFNodeName = "bhf-node" +) + +type Node struct { + URL string + CredsFile string + SendingKeys []string + NumberOfSendingKeysToCreate int + SendingKeyFundingAmount int64 + VrfKeys []string + jobSpec string +} + +type JobSpecs struct { + VRFPrimaryNode string + VRFBackupyNode string + BHSNode string + BHSBackupNode string + BHFNode string +} + +func DeployUniverseViaCLI(e helpers.Environment) { + deployCmd := flag.NewFlagSet("deploy-universe", flag.ExitOnError) + + // required flags + linkAddress := *deployCmd.String("link-address", "", "address of link token") + linkEthAddress := *deployCmd.String("link-eth-feed", "", "address of link eth feed") + bhsContractAddressString := *deployCmd.String("bhs-address", "", "address of BHS contract") + batchBHSAddressString := *deployCmd.String("batch-bhs-address", "", "address of Batch BHS contract") + coordinatorAddressString := *deployCmd.String("coordinator-address", "", "address of VRF Coordinator contract") + batchCoordinatorAddressString := *deployCmd.String("batch-coordinator-address", "", "address Batch VRF Coordinator contract") + + subscriptionBalanceString := deployCmd.String("subscription-balance", constants.SubscriptionBalanceJuels.String(), "amount to fund subscription") + + // optional flags + fallbackWeiPerUnitLinkString := deployCmd.String("fallback-wei-per-unit-link", constants.FallbackWeiPerUnitLink.String(), "fallback wei/link ratio") + registerKeyUncompressedPubKey := deployCmd.String("uncompressed-pub-key", "", "uncompressed public key") + vrfPrimaryNodeSendingKeysString := deployCmd.String("vrf-primary-node-sending-keys", "", "VRF Primary Node sending keys") + vrfBackupNodeSendingKeysString := deployCmd.String("vrf-backup-node-sending-keys", "", "VRF Backup Node sending keys") + bhsNodeSendingKeysString := deployCmd.String("bhs-node-sending-keys", "", "BHS Node sending keys") + bhfNodeSendingKeysString := deployCmd.String("bhf-node-sending-keys", "", "BHF Node sending keys") + minConfs := deployCmd.Int("min-confs", constants.MinConfs, "min confs") + maxGasLimit := deployCmd.Int64("max-gas-limit", constants.MaxGasLimit, "max gas limit") + stalenessSeconds := deployCmd.Int64("staleness-seconds", constants.StalenessSeconds, "staleness in seconds") + gasAfterPayment := deployCmd.Int64("gas-after-payment", constants.GasAfterPayment, "gas after payment calculation") + flatFeeTier1 := deployCmd.Int64("flat-fee-tier-1", constants.FlatFeeTier1, "flat fee tier 1") + flatFeeTier2 := deployCmd.Int64("flat-fee-tier-2", constants.FlatFeeTier2, "flat fee tier 2") + flatFeeTier3 := deployCmd.Int64("flat-fee-tier-3", constants.FlatFeeTier3, "flat fee tier 3") + flatFeeTier4 := deployCmd.Int64("flat-fee-tier-4", constants.FlatFeeTier4, "flat fee tier 4") + flatFeeTier5 := deployCmd.Int64("flat-fee-tier-5", constants.FlatFeeTier5, "flat fee tier 5") + reqsForTier2 := deployCmd.Int64("reqs-for-tier-2", constants.ReqsForTier2, "requests for tier 2") + reqsForTier3 := deployCmd.Int64("reqs-for-tier-3", constants.ReqsForTier3, "requests for tier 3") + reqsForTier4 := deployCmd.Int64("reqs-for-tier-4", constants.ReqsForTier4, "requests for tier 4") + reqsForTier5 := deployCmd.Int64("reqs-for-tier-5", constants.ReqsForTier5, "requests for tier 5") + + helpers.ParseArgs( + deployCmd, os.Args[2:], + ) + + fallbackWeiPerUnitLink := decimal.RequireFromString(*fallbackWeiPerUnitLinkString).BigInt() + subscriptionBalance := decimal.RequireFromString(*subscriptionBalanceString).BigInt() + + feeConfig := vrf_coordinator_v2.VRFCoordinatorV2FeeConfig{ + FulfillmentFlatFeeLinkPPMTier1: uint32(*flatFeeTier1), + FulfillmentFlatFeeLinkPPMTier2: uint32(*flatFeeTier2), + FulfillmentFlatFeeLinkPPMTier3: uint32(*flatFeeTier3), + FulfillmentFlatFeeLinkPPMTier4: uint32(*flatFeeTier4), + FulfillmentFlatFeeLinkPPMTier5: uint32(*flatFeeTier5), + ReqsForTier2: big.NewInt(*reqsForTier2), + ReqsForTier3: big.NewInt(*reqsForTier3), + ReqsForTier4: big.NewInt(*reqsForTier4), + ReqsForTier5: big.NewInt(*reqsForTier5), + } + + vrfPrimaryNodeSendingKeys := strings.Split(*vrfPrimaryNodeSendingKeysString, ",") + vrfBackupNodeSendingKeys := strings.Split(*vrfBackupNodeSendingKeysString, ",") + bhsNodeSendingKeys := strings.Split(*bhsNodeSendingKeysString, ",") + bhfNodeSendingKeys := strings.Split(*bhfNodeSendingKeysString, ",") + + nodes := make(map[string]Node) + + nodes[VRFPrimaryNodeName] = Node{ + SendingKeys: vrfPrimaryNodeSendingKeys, + } + nodes[VRFBackupNodeName] = Node{ + SendingKeys: vrfBackupNodeSendingKeys, + } + nodes[BHSNodeName] = Node{ + SendingKeys: bhsNodeSendingKeys, + } + nodes[BHFNodeName] = Node{ + SendingKeys: bhfNodeSendingKeys, + } + + bhsContractAddress := common.HexToAddress(bhsContractAddressString) + batchBHSAddress := common.HexToAddress(batchBHSAddressString) + coordinatorAddress := common.HexToAddress(coordinatorAddressString) + batchCoordinatorAddress := common.HexToAddress(batchCoordinatorAddressString) + + VRFV2DeployUniverse( + e, + fallbackWeiPerUnitLink, + subscriptionBalance, + registerKeyUncompressedPubKey, + linkAddress, + linkEthAddress, + bhsContractAddress, + batchBHSAddress, + coordinatorAddress, + batchCoordinatorAddress, + minConfs, + maxGasLimit, + stalenessSeconds, + gasAfterPayment, + feeConfig, + nodes, + ) +} + +func VRFV2DeployUniverse( + e helpers.Environment, + fallbackWeiPerUnitLink *big.Int, + subscriptionBalance *big.Int, + registerKeyUncompressedPubKey *string, + linkAddress string, + linkEthAddress string, + bhsContractAddress common.Address, + batchBHSAddress common.Address, + coordinatorAddress common.Address, + batchCoordinatorAddress common.Address, + minConfs *int, + maxGasLimit *int64, + stalenessSeconds *int64, + gasAfterPayment *int64, + feeConfig vrf_coordinator_v2.VRFCoordinatorV2FeeConfig, + nodesMap map[string]Node, //todo - is possible to pass a pointer to the node, so that we read data and also update the data and we dont need to return "nodes" +) JobSpecs { + + // Put key in ECDSA format + if strings.HasPrefix(*registerKeyUncompressedPubKey, "0x") { + *registerKeyUncompressedPubKey = strings.Replace(*registerKeyUncompressedPubKey, "0x", "04", 1) + } + + // Generate compressed public key and key hash + pubBytes, err := hex.DecodeString(*registerKeyUncompressedPubKey) + helpers.PanicErr(err) + pk, err := crypto.UnmarshalPubkey(pubBytes) + helpers.PanicErr(err) + var pkBytes []byte + if big.NewInt(0).Mod(pk.Y, big.NewInt(2)).Uint64() != 0 { + pkBytes = append(pk.X.Bytes(), 1) + } else { + pkBytes = append(pk.X.Bytes(), 0) + } + var newPK secp256k1.PublicKey + copy(newPK[:], pkBytes) + + compressedPkHex := hexutil.Encode(pkBytes) + keyHash, err := newPK.Hash() + helpers.PanicErr(err) + + if len(linkAddress) == 0 { + fmt.Println("\nDeploying LINK Token...") + linkAddress = helpers.DeployLinkToken(e).String() + } + + if len(linkEthAddress) == 0 { + fmt.Println("\nDeploying LINK/ETH Feed...") + linkEthAddress = helpers.DeployLinkEthFeed(e, linkAddress, fallbackWeiPerUnitLink).String() + } + + if bhsContractAddress.String() == "0x0000000000000000000000000000000000000000" { + fmt.Println("\nDeploying BHS...") + bhsContractAddress = DeployBHS(e) + } + + if batchBHSAddress.String() == "0x0000000000000000000000000000000000000000" { + fmt.Println("\nDeploying Batch BHS...") + batchBHSAddress = DeployBatchBHS(e, bhsContractAddress) + } + + if coordinatorAddress.String() == "0x0000000000000000000000000000000000000000" { + fmt.Println("\nDeploying Coordinator...") + coordinatorAddress = DeployCoordinator(e, linkAddress, bhsContractAddress.String(), linkEthAddress) + } + + coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(coordinatorAddress, e.Ec) + helpers.PanicErr(err) + + if batchCoordinatorAddress.String() == "0x0000000000000000000000000000000000000000" { + fmt.Println("\nDeploying Batch Coordinator...") + batchCoordinatorAddress = deployBatchCoordinatorV2(e, coordinatorAddress) + } + + fmt.Println("\nSetting Coordinator Config...") + SetCoordinatorConfig( + e, + *coordinator, + uint16(*minConfs), + uint32(*maxGasLimit), + uint32(*stalenessSeconds), + uint32(*gasAfterPayment), + fallbackWeiPerUnitLink, + feeConfig, + ) + + fmt.Println("\nConfig set, getting current config from deployed contract...") + PrintCoordinatorConfig(coordinator) + + if len(*registerKeyUncompressedPubKey) > 0 { + fmt.Println("\nRegistering proving key...") + + //NOTE - register proving key against EOA account, and not against Oracle's sending address in other to be able + // easily withdraw funds from Coordinator contract back to EOA account + RegisterCoordinatorProvingKey(e, *coordinator, *registerKeyUncompressedPubKey, e.Owner.From.String()) + + fmt.Println("\nProving key registered, getting proving key hashes from deployed contract...") + _, _, provingKeyHashes, configErr := coordinator.GetRequestConfig(nil) + helpers.PanicErr(configErr) + fmt.Println("Key hash registered:", hex.EncodeToString(provingKeyHashes[0][:])) + } else { + fmt.Println("NOT registering proving key - you must do this eventually in order to fully deploy VRF!") + } + + fmt.Println("\nDeploying consumer...") + consumerAddress := EoaLoadTestConsumerWithMetricsDeploy(e, coordinatorAddress.String()) + + fmt.Println("\nAdding subscription...") + EoaCreateSub(e, *coordinator) + subID := uint64(1) + + fmt.Println("\nAdding consumer to subscription...") + EoaAddConsumerToSub(e, *coordinator, subID, consumerAddress.String()) + + if subscriptionBalance.Cmp(big.NewInt(0)) > 0 { + fmt.Println("\nFunding subscription with", subscriptionBalance, "juels...") + EoaFundSubscription(e, *coordinator, linkAddress, subscriptionBalance, subID) + } else { + fmt.Println("Subscription", subID, "NOT getting funded. You must fund the subscription in order to use it!") + } + + fmt.Println("\nSubscribed and (possibly) funded, retrieving subscription from deployed contract...") + s, err := coordinator.GetSubscription(nil, subID) + helpers.PanicErr(err) + fmt.Printf("Subscription %+v\n", s) + + formattedVrfPrimaryJobSpec := fmt.Sprintf( + jobs.VRFJobFormatted, + coordinatorAddress, //coordinatorAddress + batchCoordinatorAddress, //batchCoordinatorAddress + false, //batchFulfillmentEnabled + compressedPkHex, //publicKey + *minConfs, //minIncomingConfirmations + e.ChainID, //evmChainID + strings.Join(nodesMap[VRFPrimaryNodeName].SendingKeys, "\",\""), //fromAddresses + coordinatorAddress, + coordinatorAddress, + coordinatorAddress, + ) + + formattedVrfBackupJobSpec := fmt.Sprintf( + jobs.VRFJobFormatted, + coordinatorAddress, //coordinatorAddress + batchCoordinatorAddress, //batchCoordinatorAddress + false, //batchFulfillmentEnabled + compressedPkHex, //publicKey + 100, //minIncomingConfirmations + e.ChainID, //evmChainID + strings.Join(nodesMap[VRFBackupNodeName].SendingKeys, "\",\""), //fromAddresses + coordinatorAddress, + coordinatorAddress, + coordinatorAddress, + ) + + formattedBHSJobSpec := fmt.Sprintf( + jobs.BHSJobFormatted, + coordinatorAddress, //coordinatorAddress + 30, //waitBlocks + 200, //lookbackBlocks + bhsContractAddress, //bhs address + e.ChainID, //chain id + strings.Join(nodesMap[BHSNodeName].SendingKeys, "\",\""), //sending addresses + ) + + formattedBHSBackupJobSpec := fmt.Sprintf( + jobs.BHSJobFormatted, + coordinatorAddress, //coordinatorAddress + 100, //waitBlocks + 200, //lookbackBlocks + bhsContractAddress, //bhs adreess + e.ChainID, //chain id + strings.Join(nodesMap[BHSBackupNodeName].SendingKeys, "\",\""), //sending addresses + ) + + formattedBHFJobSpec := fmt.Sprintf( + jobs.BHFJobFormatted, + coordinatorAddress, //coordinatorAddress + bhsContractAddress, //bhs adreess + batchBHSAddress, //batchBHS + e.ChainID, //chain id + strings.Join(nodesMap[BHFNodeName].SendingKeys, "\",\""), //sending addresses + ) + + fmt.Println( + "\nDeployment complete.", + "\nLINK Token contract address:", linkAddress, + "\nLINK/ETH Feed contract address:", linkEthAddress, + "\nBlockhash Store contract address:", bhsContractAddress, + "\nBatch Blockhash Store contract address:", batchBHSAddress, + "\nVRF Coordinator Address:", coordinatorAddress, + "\nBatch VRF Coordinator Address:", batchCoordinatorAddress, + "\nVRF Consumer Address:", consumerAddress, + "\nVRF Subscription Id:", subID, + "\nVRF Subscription Balance:", *subscriptionBalance, + "\nPossible VRF Request command: ", + fmt.Sprintf("go run . eoa-load-test-request-with-metrics --consumer-address=%s --sub-id=%d --key-hash=%s --request-confirmations %d --requests 1 --runs 1 --cb-gas-limit 1_000_000", consumerAddress, subID, keyHash, *minConfs), + "\nRetrieve Request Status: ", + fmt.Sprintf("go run . eoa-load-test-read-metrics --consumer-address=%s", consumerAddress), + "\nA node can now be configured to run a VRF job with the below job spec :\n", + formattedVrfPrimaryJobSpec, + ) + + return JobSpecs{ + VRFPrimaryNode: formattedVrfPrimaryJobSpec, + VRFBackupyNode: formattedVrfBackupJobSpec, + BHSNode: formattedBHSJobSpec, + BHSBackupNode: formattedBHSBackupJobSpec, + BHFNode: formattedBHFJobSpec, + } +} + +func DeployWrapperUniverse(e helpers.Environment) { + cmd := flag.NewFlagSet("wrapper-universe-deploy", flag.ExitOnError) + linkAddress := cmd.String("link-address", "", "address of link token") + linkETHFeedAddress := cmd.String("link-eth-feed", "", "address of link-eth-feed") + coordinatorAddress := cmd.String("coordinator-address", "", "address of the vrf coordinator v2 contract") + wrapperGasOverhead := cmd.Uint("wrapper-gas-overhead", 50_000, "amount of gas overhead in wrapper fulfillment") + coordinatorGasOverhead := cmd.Uint("coordinator-gas-overhead", 52_000, "amount of gas overhead in coordinator fulfillment") + wrapperPremiumPercentage := cmd.Uint("wrapper-premium-percentage", 25, "gas premium charged by wrapper") + keyHash := cmd.String("key-hash", "", "the keyhash that wrapper requests should use") + maxNumWords := cmd.Uint("max-num-words", 10, "the keyhash that wrapper requests should use") + subFunding := cmd.String("sub-funding", "10000000000000000000", "amount to fund the subscription with") + consumerFunding := cmd.String("consumer-funding", "10000000000000000000", "amount to fund the consumer with") + helpers.ParseArgs(cmd, os.Args[2:], "link-address", "link-eth-feed", "coordinator-address", "key-hash") + + amount, s := big.NewInt(0).SetString(*subFunding, 10) + if !s { + panic(fmt.Sprintf("failed to parse top up amount '%s'", *subFunding)) + } + + wrapper, subID := WrapperDeploy(e, + common.HexToAddress(*linkAddress), + common.HexToAddress(*linkETHFeedAddress), + common.HexToAddress(*coordinatorAddress)) + + WrapperConfigure(e, + wrapper, + *wrapperGasOverhead, + *coordinatorGasOverhead, + *wrapperPremiumPercentage, + *keyHash, + *maxNumWords) + + consumer := WrapperConsumerDeploy(e, + common.HexToAddress(*linkAddress), + wrapper) + + coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*coordinatorAddress), e.Ec) + helpers.PanicErr(err) + + EoaFundSubscription(e, *coordinator, *linkAddress, amount, subID) + + link, err := link_token_interface.NewLinkToken(common.HexToAddress(*linkAddress), e.Ec) + helpers.PanicErr(err) + consumerAmount, s := big.NewInt(0).SetString(*consumerFunding, 10) + if !s { + panic(fmt.Sprintf("failed to parse top up amount '%s'", *consumerFunding)) + } + + tx, err := link.Transfer(e.Owner, consumer, consumerAmount) + helpers.PanicErr(err) + helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID, "link transfer to consumer") + + fmt.Println("wrapper universe deployment complete") + fmt.Println("wrapper address:", wrapper.String()) + fmt.Println("wrapper consumer address:", consumer.String()) +} diff --git a/core/scripts/vrfv2/testnet/util.go b/core/scripts/vrfv2/testnet/scripts/util.go similarity index 85% rename from core/scripts/vrfv2/testnet/util.go rename to core/scripts/vrfv2/testnet/scripts/util.go index a72eaf8d5a2..3b429837c93 100644 --- a/core/scripts/vrfv2/testnet/util.go +++ b/core/scripts/vrfv2/testnet/scripts/util.go @@ -1,9 +1,10 @@ -package main +package scripts import ( "context" "encoding/hex" "fmt" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_load_test_with_metrics" "math/big" "github.com/ethereum/go-ethereum/common" @@ -21,19 +22,19 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/utils" ) -func deployBHS(e helpers.Environment) (blockhashStoreAddress common.Address) { +func DeployBHS(e helpers.Environment) (blockhashStoreAddress common.Address) { _, tx, _, err := blockhash_store.DeployBlockhashStore(e.Owner, e.Ec) helpers.PanicErr(err) return helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) } -func deployBatchBHS(e helpers.Environment, bhsAddress common.Address) (batchBHSAddress common.Address) { +func DeployBatchBHS(e helpers.Environment, bhsAddress common.Address) (batchBHSAddress common.Address) { _, tx, _, err := batch_blockhash_store.DeployBatchBlockhashStore(e.Owner, e.Ec, bhsAddress) helpers.PanicErr(err) return helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) } -func deployCoordinator( +func DeployCoordinator( e helpers.Environment, linkAddress string, bhsAddress string, @@ -55,19 +56,19 @@ func deployBatchCoordinatorV2(e helpers.Environment, coordinatorAddress common.A return helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) } -func eoaAddConsumerToSub(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, subID uint64, consumerAddress string) { +func EoaAddConsumerToSub(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, subID uint64, consumerAddress string) { txadd, err := coordinator.AddConsumer(e.Owner, subID, common.HexToAddress(consumerAddress)) helpers.PanicErr(err) helpers.ConfirmTXMined(context.Background(), e.Ec, txadd, e.ChainID) } -func eoaCreateSub(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2) { +func EoaCreateSub(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2) { tx, err := coordinator.CreateSubscription(e.Owner) helpers.PanicErr(err) helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID) } -func eoaDeployConsumer(e helpers.Environment, coordinatorAddress string, linkAddress string) (consumerAddress common.Address) { +func EoaDeployConsumer(e helpers.Environment, coordinatorAddress string, linkAddress string) (consumerAddress common.Address) { _, tx, _, err := vrf_external_sub_owner_example.DeployVRFExternalSubOwnerExample( e.Owner, e.Ec, @@ -77,7 +78,7 @@ func eoaDeployConsumer(e helpers.Environment, coordinatorAddress string, linkAdd return helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) } -func eoaFundSubscription(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, linkAddress string, amount *big.Int, subID uint64) { +func EoaFundSubscription(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, linkAddress string, amount *big.Int, subID uint64) { linkToken, err := link_token_interface.NewLinkToken(common.HexToAddress(linkAddress), e.Ec) helpers.PanicErr(err) bal, err := linkToken.BalanceOf(nil, e.Owner.From) @@ -91,7 +92,7 @@ func eoaFundSubscription(e helpers.Environment, coordinator vrf_coordinator_v2.V helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID, fmt.Sprintf("sub ID: %d", subID)) } -func printCoordinatorConfig(coordinator *vrf_coordinator_v2.VRFCoordinatorV2) { +func PrintCoordinatorConfig(coordinator *vrf_coordinator_v2.VRFCoordinatorV2) { cfg, err := coordinator.GetConfig(nil) helpers.PanicErr(err) @@ -102,7 +103,7 @@ func printCoordinatorConfig(coordinator *vrf_coordinator_v2.VRFCoordinatorV2) { fmt.Printf("Coordinator fee config: %+v\n", feeConfig) } -func setCoordinatorConfig( +func SetCoordinatorConfig( e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, minConfs uint16, @@ -125,7 +126,7 @@ func setCoordinatorConfig( helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID) } -func registerCoordinatorProvingKey(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, uncompressed string, oracleAddress string) { +func RegisterCoordinatorProvingKey(e helpers.Environment, coordinator vrf_coordinator_v2.VRFCoordinatorV2, uncompressed string, oracleAddress string) { pubBytes, err := hex.DecodeString(uncompressed) helpers.PanicErr(err) pk, err := crypto.UnmarshalPubkey(pubBytes) @@ -144,7 +145,7 @@ func registerCoordinatorProvingKey(e helpers.Environment, coordinator vrf_coordi ) } -func wrapperDeploy( +func WrapperDeploy( e helpers.Environment, link, linkEthFeed, coordinator common.Address, ) (common.Address, uint64) { @@ -167,7 +168,7 @@ func wrapperDeploy( return address, subID } -func wrapperConfigure( +func WrapperConfigure( e helpers.Environment, wrapperAddress common.Address, wrapperGasOverhead, coordinatorGasOverhead, premiumPercentage uint, @@ -188,7 +189,7 @@ func wrapperConfigure( helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID) } -func wrapperConsumerDeploy( +func WrapperConsumerDeploy( e helpers.Environment, link, wrapper common.Address, ) common.Address { @@ -201,3 +202,13 @@ func wrapperConsumerDeploy( fmt.Printf("VRFV2WrapperConsumerExample address: %s\n", address) return address } + +func EoaLoadTestConsumerWithMetricsDeploy(e helpers.Environment, consumerCoordinator string) (consumerAddress common.Address) { + _, tx, _, err := vrf_load_test_with_metrics.DeployVRFV2LoadTestWithMetrics( + e.Owner, + e.Ec, + common.HexToAddress(consumerCoordinator), + ) + helpers.PanicErr(err) + return helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) +} diff --git a/core/scripts/vrfv2/testnet/setup-envs/README.md b/core/scripts/vrfv2/testnet/setup-envs/README.md new file mode 100644 index 00000000000..c158cd6f541 --- /dev/null +++ b/core/scripts/vrfv2/testnet/setup-envs/README.md @@ -0,0 +1,44 @@ +## NOTE: +* Script will delete all existing jobs on the node! +* Currently works only with 0 or 1 VRF Keys on the node! Otherwise, will stop execution! +* Currently possible to fund all nodes with one amount of native tokens +## Commands: +1. If using Docker Compose + 1. create `.env` file in `core/scripts/vrfv2/testnet/docker` (can use `sample.env` file as an example) + 2. go to `core/scripts/vrfv2/testnet/docker` folder and start containers - `docker compose up` +2. Update [rpc-nodes.toml](..%2Fdocker%2Ftoml-config%2Frpc-nodes.toml) with relevant RPC nodes +3. Create files with credentials desirably outside `chainlink` repo (just not to push creds accidentally). Populate the files with relevant credentials for the nodes +4. Ensure that following env variables are set +``` +export ETH_URL= +export ETH_CHAIN_ID= +export ACCOUNT_KEY= +``` +5. execute from `core/scripts/vrfv2/testnet/setup-envs` folder +``` +go run . \ +--vrf-primary-node-url=http://localhost:6610 \ +--vrf-primary-creds-file \ +--vrf-backup-node-url=http://localhost:6611 \ +--vrf-bk-creds-file \ +--bhs-node-url=http://localhost:6612 \ +--bhs-creds-file \ +--bhs-backup-node-url=http://localhost:6613 \ +--bhs-bk-creds-file \ +--bhf-node-url=http://localhost:6614 \ +--bhf-creds-file \ +--num-eth-keys 5 \ +--num-vrf-keys 1 \ +--sending-key-funding-amount 100000000000000000 + +``` + +Optional parameters - will not be deployed if specified (NOT WORKING YET) +``` + --link-address

\ + --link-eth-feed
\ + --bhs-address
\ + --batch-bhs-address
\ + --coordinator-address
\ + --batch-coordinator-address
+``` \ No newline at end of file diff --git a/core/scripts/vrfv2/testnet/setup-envs/main.go b/core/scripts/vrfv2/testnet/setup-envs/main.go new file mode 100644 index 00000000000..eb692031f9c --- /dev/null +++ b/core/scripts/vrfv2/testnet/setup-envs/main.go @@ -0,0 +1,447 @@ +package main + +import ( + "bytes" + "encoding/json" + "flag" + "fmt" + "github.com/ethereum/go-ethereum/common" + helpers "github.com/smartcontractkit/chainlink/core/scripts/common" + "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/constants" + "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/scripts" + clcmd "github.com/smartcontractkit/chainlink/v2/core/cmd" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" + "github.com/smartcontractkit/chainlink/v2/core/web/presenters" + "github.com/urfave/cli" + "io" + "math/big" + "os" + "strings" +) + +func newApp(remoteNodeURL string, writer io.Writer) (*clcmd.Shell, *cli.App) { + prompter := clcmd.NewTerminalPrompter() + client := &clcmd.Shell{ + Renderer: clcmd.RendererJSON{Writer: writer}, + AppFactory: clcmd.ChainlinkAppFactory{}, + KeyStoreAuthenticator: clcmd.TerminalKeyStoreAuthenticator{Prompter: prompter}, + FallbackAPIInitializer: clcmd.NewPromptingAPIInitializer(prompter), + Runner: clcmd.ChainlinkRunner{}, + PromptingSessionRequestBuilder: clcmd.NewPromptingSessionRequestBuilder(prompter), + ChangePasswordPrompter: clcmd.NewChangePasswordPrompter(), + PasswordPrompter: clcmd.NewPasswordPrompter(), + } + app := clcmd.NewApp(client) + fs := flag.NewFlagSet("blah", flag.ContinueOnError) + fs.Bool("json", true, "") + fs.String("remote-node-url", remoteNodeURL, "") + helpers.PanicErr(app.Before(cli.NewContext(nil, fs, nil))) + // overwrite renderer since it's set to stdout after Before() is called + client.Renderer = clcmd.RendererJSON{Writer: writer} + return client, app +} + +var ( + checkMarkEmoji = "✅" + xEmoji = "❌" + infoEmoji = "ℹ️" +) + +func main() { + + vrfPrimaryNodeURL := flag.String("vrf-primary-node-url", "", "remote node URL") + vrfBackupNodeURL := flag.String("vrf-backup-node-url", "", "remote node URL") + bhsNodeURL := flag.String("bhs-node-url", "", "remote node URL") + bhsBackupNodeURL := flag.String("bhs-backup-node-url", "", "remote node URL") + bhfNodeURL := flag.String("bhf-node-url", "", "remote node URL") + nodeSendingKeyFundingAmount := flag.Int64("sending-key-funding-amount", constants.NodeSendingKeyFundingAmountGwei, "remote node URL") + + vrfPrimaryCredsFile := flag.String("vrf-primary-creds-file", "", "Creds to authenticate to the node") + vrfBackupCredsFile := flag.String("vrf-bk-creds-file", "", "Creds to authenticate to the node") + bhsCredsFile := flag.String("bhs-creds-file", "", "Creds to authenticate to the node") + bhsBackupCredsFile := flag.String("bhs-bk-creds-file", "", "Creds to authenticate to the node") + bhfCredsFile := flag.String("bhf-creds-file", "", "Creds to authenticate to the node") + + numEthKeys := flag.Int("num-eth-keys", 5, "Number of eth keys to create") + maxGasPriceGwei := flag.Int("max-gas-price-gwei", -1, "Max gas price gwei of the eth keys") + numVRFKeys := flag.Int("num-vrf-keys", 1, "Number of vrf keys to create") + + linkAddress := flag.String("link-address", "", "address of link token") + linkEthAddress := flag.String("link-eth-feed", "", "address of link eth feed") + bhsContractAddressString := flag.String("bhs-address", "", "address of BHS contract") + batchBHSAddressString := flag.String("batch-bhs-address", "", "address of Batch BHS contract") + coordinatorAddressString := flag.String("coordinator-address", "", "address of VRF Coordinator contract") + batchCoordinatorAddressString := flag.String("batch-coordinator-address", "", "address Batch VRF Coordinator contract") + + e := helpers.SetupEnv(false) + flag.Parse() + nodes := make(map[string]scripts.Node) + + if *vrfPrimaryNodeURL != "" { + nodes[scripts.VRFPrimaryNodeName] = scripts.Node{ + URL: *vrfPrimaryNodeURL, + SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + CredsFile: *vrfPrimaryCredsFile, + } + } + if *vrfBackupNodeURL != "" { + nodes[scripts.VRFBackupNodeName] = scripts.Node{ + URL: *vrfBackupNodeURL, + SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + CredsFile: *vrfBackupCredsFile, + } + } + if *bhsNodeURL != "" { + nodes[scripts.BHSNodeName] = scripts.Node{ + URL: *bhsNodeURL, + SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + CredsFile: *bhsCredsFile, + } + } + if *bhsBackupNodeURL != "" { + nodes[scripts.BHSBackupNodeName] = scripts.Node{ + URL: *bhsBackupNodeURL, + SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + CredsFile: *bhsBackupCredsFile, + } + } + + if *bhfNodeURL != "" { + nodes[scripts.BHFNodeName] = scripts.Node{ + URL: *bhfNodeURL, + SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + CredsFile: *bhfCredsFile, + } + } + + output := &bytes.Buffer{} + for key, node := range nodes { + + client, app := connectToNode(&node.URL, output, node.CredsFile) + ethKeys := createETHKeysIfNeeded(client, app, output, numEthKeys, &node.URL, maxGasPriceGwei) + if key == scripts.VRFPrimaryNodeName { + vrfKeys := createVRFKeyIfNeeded(client, app, output, numVRFKeys, &node.URL) + node.VrfKeys = mapVrfKeysToStringArr(vrfKeys) + printVRFKeyData(vrfKeys) + exportVRFKey(client, app, vrfKeys[0], output) + } + + if key == scripts.VRFBackupNodeName { + vrfKeys := getVRFKeys(client, app, output) + node.VrfKeys = mapVrfKeysToStringArr(vrfKeys) + } + + node.SendingKeys = mapEthKeysToStringArr(ethKeys) + nodes[key] = node + printETHKeyData(ethKeys) + + if node.SendingKeyFundingAmount > 0 { + fmt.Println("\nFunding ", key, " Node's Sending Keys...") + helpers.FundNodes(e, node.SendingKeys, big.NewInt(node.SendingKeyFundingAmount)) + } + } + importVRFKeyToNodeIfSet(vrfBackupNodeURL, nodes, output, nodes[scripts.VRFBackupNodeName].CredsFile) + fmt.Println() + feeConfig := vrf_coordinator_v2.VRFCoordinatorV2FeeConfig{ + FulfillmentFlatFeeLinkPPMTier1: uint32(constants.FlatFeeTier1), + FulfillmentFlatFeeLinkPPMTier2: uint32(constants.FlatFeeTier2), + FulfillmentFlatFeeLinkPPMTier3: uint32(constants.FlatFeeTier3), + FulfillmentFlatFeeLinkPPMTier4: uint32(constants.FlatFeeTier4), + FulfillmentFlatFeeLinkPPMTier5: uint32(constants.FlatFeeTier5), + ReqsForTier2: big.NewInt(constants.ReqsForTier2), + ReqsForTier3: big.NewInt(constants.ReqsForTier3), + ReqsForTier4: big.NewInt(constants.ReqsForTier4), + ReqsForTier5: big.NewInt(constants.ReqsForTier5), + } + + jobSpecs := scripts.VRFV2DeployUniverse( + e, + constants.FallbackWeiPerUnitLink, + constants.SubscriptionBalanceJuels, + &nodes[scripts.VRFPrimaryNodeName].VrfKeys[0], + *linkAddress, + *linkEthAddress, + common.HexToAddress(*bhsContractAddressString), + common.HexToAddress(*batchBHSAddressString), + common.HexToAddress(*coordinatorAddressString), + common.HexToAddress(*batchCoordinatorAddressString), + &constants.MinConfs, + &constants.MaxGasLimit, + &constants.StalenessSeconds, + &constants.GasAfterPayment, + feeConfig, + nodes, + ) + + for key, node := range nodes { + client, app := connectToNode(&node.URL, output, node.CredsFile) + + //GET ALL JOBS + jobIDs := getAllJobIDs(client, app, output) + + //DELETE ALL EXISTING JOBS + for _, jobID := range jobIDs { + deleteJob(jobID, client, app, output) + } + //CREATE JOBS + switch key { + case scripts.VRFPrimaryNodeName: + createJob(jobSpecs.VRFPrimaryNode, client, app, output) + case scripts.VRFBackupNodeName: + createJob(jobSpecs.VRFBackupyNode, client, app, output) + case scripts.BHSNodeName: + createJob(jobSpecs.BHSNode, client, app, output) + case scripts.BHSBackupNodeName: + createJob(jobSpecs.BHSBackupNode, client, app, output) + case scripts.BHFNodeName: + createJob(jobSpecs.BHFNode, client, app, output) + } + } +} + +func importVRFKeyToNodeIfSet(vrfBackupNodeURL *string, nodes map[string]scripts.Node, output *bytes.Buffer, file string) { + if *vrfBackupNodeURL != "" { + vrfBackupNode := nodes[scripts.VRFBackupNodeName] + vrfPrimaryNode := nodes[scripts.VRFBackupNodeName] + + if len(vrfBackupNode.VrfKeys) == 0 || vrfPrimaryNode.VrfKeys[0] != vrfBackupNode.VrfKeys[0] { + client, app := connectToNode(&vrfBackupNode.URL, output, file) + importVRFKey(client, app, output) + + vrfKeys := getVRFKeys(client, app, output) + + vrfBackupNode.VrfKeys = mapVrfKeysToStringArr(vrfKeys) + if len(vrfBackupNode.VrfKeys) == 0 { + panic("VRF Key was not imported to VRF Backup Node") + } + printVRFKeyData(vrfKeys) + } + } +} + +func getVRFKeys(client *clcmd.Shell, app *cli.App, output *bytes.Buffer) []presenters.VRFKeyResource { + var vrfKeys []presenters.VRFKeyResource + + err := client.ListVRFKeys(&cli.Context{ + App: app, + }) + helpers.PanicErr(err) + helpers.PanicErr(json.Unmarshal(output.Bytes(), &vrfKeys)) + output.Reset() + return vrfKeys +} + +func createJob(jobSpec string, client *clcmd.Shell, app *cli.App, output *bytes.Buffer) { + if err := os.WriteFile("job-spec.toml", []byte(jobSpec), 0666); err != nil { + helpers.PanicErr(err) + } + job := presenters.JobResource{} + flagSet := flag.NewFlagSet("blah", flag.ExitOnError) + err := flagSet.Parse([]string{"./job-spec.toml"}) + helpers.PanicErr(err) + err = client.CreateJob(cli.NewContext(app, flagSet, nil)) + helpers.PanicErr(err) + helpers.PanicErr(json.Unmarshal(output.Bytes(), &job)) + output.Reset() +} + +func exportVRFKey(client *clcmd.Shell, app *cli.App, vrfKey presenters.VRFKeyResource, output *bytes.Buffer) { + if err := os.WriteFile("vrf-key-password.txt", []byte("twochains"), 0666); err != nil { + helpers.PanicErr(err) + } + flagSet := flag.NewFlagSet("blah", flag.ExitOnError) + flagSet.String("new-password", "./vrf-key-password.txt", "") + flagSet.String("output", "exportedvrf.json", "") + err := flagSet.Parse([]string{vrfKey.Compressed}) + helpers.PanicErr(err) + err = client.ExportVRFKey(cli.NewContext(app, flagSet, nil)) + helpers.PanicErr(err) + output.Reset() +} + +func importVRFKey(client *clcmd.Shell, app *cli.App, output *bytes.Buffer) { + if err := os.WriteFile("vrf-key-password.txt", []byte("twochains"), 0666); err != nil { + helpers.PanicErr(err) + } + flagSet := flag.NewFlagSet("blah", flag.ExitOnError) + flagSet.String("old-password", "./vrf-key-password.txt", "") + err := flagSet.Parse([]string{"exportedvrf.json"}) + helpers.PanicErr(err) + err = client.ImportVRFKey(cli.NewContext(app, flagSet, nil)) + helpers.PanicErr(err) + output.Reset() +} + +func deleteJob(jobID string, client *clcmd.Shell, app *cli.App, output *bytes.Buffer) { + flagSet := flag.NewFlagSet("blah", flag.ExitOnError) + err := flagSet.Parse([]string{jobID}) + helpers.PanicErr(err) + err = client.DeleteJob(cli.NewContext(app, flagSet, nil)) + helpers.PanicErr(err) + output.Reset() +} + +func getAllJobIDs(client *clcmd.Shell, app *cli.App, output *bytes.Buffer) []string { + flagSet := flag.NewFlagSet("blah", flag.ExitOnError) + err := client.ListJobs(cli.NewContext(app, flagSet, nil)) + helpers.PanicErr(err) + jobs := clcmd.JobPresenters{} + helpers.PanicErr(json.Unmarshal(output.Bytes(), &jobs)) + var jobIDs []string + for _, job := range jobs { + jobIDs = append(jobIDs, job.ID) + } + output.Reset() + return jobIDs +} + +func printETHKeyData(ethKeys []presenters.ETHKeyResource) { + fmt.Println("------------- NODE INFORMATION -------------") + for _, ethKey := range ethKeys { + fmt.Println("-----------ETH Key-----------") + fmt.Println("Address: ", ethKey.Address) + fmt.Println("MaxGasPriceWei: ", ethKey.MaxGasPriceWei) + fmt.Println("EthBalance: ", ethKey.EthBalance) + fmt.Println("NextNonce: ", ethKey.NextNonce) + fmt.Println("-----------------------------") + } +} + +func mapEthKeysToStringArr(ethKeys []presenters.ETHKeyResource) []string { + var ethKeysString []string + for _, ethKey := range ethKeys { + ethKeysString = append(ethKeysString, ethKey.Address) + } + return ethKeysString +} + +func mapVrfKeysToStringArr(vrfKeys []presenters.VRFKeyResource) []string { + var vrfKeysString []string + for _, vrfKey := range vrfKeys { + vrfKeysString = append(vrfKeysString, vrfKey.Uncompressed) + } + return vrfKeysString +} + +func printVRFKeyData(vrfKeys []presenters.VRFKeyResource) { + fmt.Println("Number of VRF Keys on the node: ", len(vrfKeys)) + fmt.Println("------------- NODE INFORMATION -------------") + for _, vrfKey := range vrfKeys { + fmt.Println("-----------VRF Key-----------") + fmt.Println("Compressed: ", vrfKey.Compressed) + fmt.Println("Uncompressed: ", vrfKey.Uncompressed) + fmt.Println("Hash: ", vrfKey.Hash) + fmt.Println("-----------------------------") + } +} + +func connectToNode(nodeURL *string, output *bytes.Buffer, credFile string) (*clcmd.Shell, *cli.App) { + client, app := newApp(*nodeURL, output) + // login first to establish the session + fmt.Println("logging in to:", *nodeURL) + loginFs := flag.NewFlagSet("test", flag.ContinueOnError) + loginFs.String("file", credFile, "") + loginFs.Bool("bypass-version-check", true, "") + loginCtx := cli.NewContext(app, loginFs, nil) + err := client.RemoteLogin(loginCtx) + helpers.PanicErr(err) + output.Reset() + fmt.Println() + return client, app +} + +func createVRFKeyIfNeeded(client *clcmd.Shell, app *cli.App, output *bytes.Buffer, numVRFKeys *int, nodeURL *string) []presenters.VRFKeyResource { + var allVRFKeys []presenters.VRFKeyResource + var newKeys []presenters.VRFKeyResource + + vrfKeys := getVRFKeys(client, app, output) + + switch { + case len(vrfKeys) == *numVRFKeys: + fmt.Println(checkMarkEmoji, "found", len(vrfKeys), "vrf keys on", nodeURL) + case len(vrfKeys) > *numVRFKeys: + fmt.Println(xEmoji, "found", len(vrfKeys), "vrf keys on", nodeURL, " which is more than expected") + os.Exit(1) + default: + fmt.Println(xEmoji, "found only", len(vrfKeys), "vrf keys on", nodeURL, ", creating", + *numVRFKeys-len(vrfKeys), "more") + toCreate := *numVRFKeys - len(vrfKeys) + for i := 0; i < toCreate; i++ { + output.Reset() + newKey := createVRFKey(client, app, output) + newKeys = append(newKeys, newKey) + } + fmt.Println("NEW VRF KEYS:", strings.Join(func() (r []string) { + for _, k := range newKeys { + r = append(r, k.Uncompressed) + } + return + }(), ", ")) + } + fmt.Println() + for _, vrfKey := range vrfKeys { + allVRFKeys = append(allVRFKeys, vrfKey) + } + for _, nk := range newKeys { + allVRFKeys = append(allVRFKeys, nk) + } + return allVRFKeys +} + +func createVRFKey(client *clcmd.Shell, app *cli.App, output *bytes.Buffer) presenters.VRFKeyResource { + var newKey presenters.VRFKeyResource + err := client.CreateVRFKey( + cli.NewContext(app, flag.NewFlagSet("blah", flag.ExitOnError), nil)) + helpers.PanicErr(err) + helpers.PanicErr(json.Unmarshal(output.Bytes(), &newKey)) + output.Reset() + return newKey +} + +func createETHKeysIfNeeded(client *clcmd.Shell, app *cli.App, output *bytes.Buffer, numEthKeys *int, nodeURL *string, maxGasPriceGwei *int) []presenters.ETHKeyResource { + var allETHKeysNode []presenters.ETHKeyResource + var ethKeys []presenters.ETHKeyResource + var newKeys []presenters.ETHKeyResource + // check for ETH keys + err := client.ListETHKeys(&cli.Context{ + App: app, + }) + helpers.PanicErr(err) + helpers.PanicErr(json.Unmarshal(output.Bytes(), ðKeys)) + switch { + case len(ethKeys) >= *numEthKeys: + fmt.Println(checkMarkEmoji, "found", len(ethKeys), "eth keys on", nodeURL) + case len(ethKeys) < *numEthKeys: + fmt.Println(xEmoji, "found only", len(ethKeys), "eth keys on", nodeURL, + "; creating", *numEthKeys-len(ethKeys), "more") + toCreate := *numEthKeys - len(ethKeys) + for i := 0; i < toCreate; i++ { + output.Reset() + var newKey presenters.ETHKeyResource + + flagSet := flag.NewFlagSet("blah", flag.ExitOnError) + if *maxGasPriceGwei > 0 { + helpers.PanicErr(flagSet.Set("max-gas-price-gwei", fmt.Sprintf("%d", *maxGasPriceGwei))) + } + err = client.CreateETHKey(cli.NewContext(app, flagSet, nil)) + helpers.PanicErr(err) + helpers.PanicErr(json.Unmarshal(output.Bytes(), &newKey)) + newKeys = append(newKeys, newKey) + } + fmt.Println("NEW ETH KEYS:", strings.Join(func() (r []string) { + for _, k := range newKeys { + r = append(r, k.Address) + } + return + }(), ", ")) + } + output.Reset() + fmt.Println() + for _, ethKey := range ethKeys { + allETHKeysNode = append(allETHKeysNode, ethKey) + } + for _, nk := range newKeys { + allETHKeysNode = append(allETHKeysNode, nk) + } + return allETHKeysNode +} diff --git a/core/scripts/vrfv2/testnet/super_scripts.go b/core/scripts/vrfv2/testnet/super_scripts.go deleted file mode 100644 index 977be9380d3..00000000000 --- a/core/scripts/vrfv2/testnet/super_scripts.go +++ /dev/null @@ -1,297 +0,0 @@ -package main - -import ( - "context" - "encoding/hex" - "flag" - "fmt" - "math/big" - "os" - "strings" - - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/common/hexutil" - "github.com/ethereum/go-ethereum/crypto" - "github.com/shopspring/decimal" - - helpers "github.com/smartcontractkit/chainlink/core/scripts/common" - "github.com/smartcontractkit/chainlink/v2/core/assets" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" - "github.com/smartcontractkit/chainlink/v2/core/services/signatures/secp256k1" -) - -const formattedVRFJob = ` -type = "vrf" -name = "vrf_v2" -schemaVersion = 1 -coordinatorAddress = "%s" -batchCoordinatorAddress = "%s" -batchFulfillmentEnabled = %t -batchFulfillmentGasMultiplier = 1.1 -publicKey = "%s" -minIncomingConfirmations = 3 -evmChainID = "%d" -fromAddresses = ["%s"] -pollPeriod = "5s" -requestTimeout = "24h" -observationSource = """decode_log [type=ethabidecodelog - abi="RandomWordsRequested(bytes32 indexed keyHash,uint256 requestId,uint256 preSeed,uint64 indexed subId,uint16 minimumRequestConfirmations,uint32 callbackGasLimit,uint32 numWords,address indexed sender)" - data="$(jobRun.logData)" - topics="$(jobRun.logTopics)"] -vrf [type=vrfv2 - publicKey="$(jobSpec.publicKey)" - requestBlockHash="$(jobRun.logBlockHash)" - requestBlockNumber="$(jobRun.logBlockNumber)" - topics="$(jobRun.logTopics)"] -estimate_gas [type=estimategaslimit - to="%s" - multiplier="1.1" - data="$(vrf.output)"] -simulate [type=ethcall - to="%s" - gas="$(estimate_gas)" - gasPrice="$(jobSpec.maxGasPrice)" - extractRevertReason=true - contract="%s" - data="$(vrf.output)"] -decode_log->vrf->estimate_gas->simulate -""" -` - -func deployUniverse(e helpers.Environment) { - deployCmd := flag.NewFlagSet("deploy-universe", flag.ExitOnError) - - // required flags - linkAddress := deployCmd.String("link-address", "", "address of link token") - linkEthAddress := deployCmd.String("link-eth-feed", "", "address of link eth feed") - subscriptionBalanceString := deployCmd.String("subscription-balance", "1e19", "amount to fund subscription") - - // optional flags - fallbackWeiPerUnitLinkString := deployCmd.String("fallback-wei-per-unit-link", "6e16", "fallback wei/link ratio") - registerKeyUncompressedPubKey := deployCmd.String("uncompressed-pub-key", "", "uncompressed public key") - registerKeyOracleAddress := deployCmd.String("oracle-address", "", "oracle sender address") - minConfs := deployCmd.Int("min-confs", 3, "min confs") - oracleFundingAmount := deployCmd.Int64("oracle-funding-amount", assets.GWei(100_000_000).Int64(), "amount to fund sending oracle") - maxGasLimit := deployCmd.Int64("max-gas-limit", 2.5e6, "max gas limit") - stalenessSeconds := deployCmd.Int64("staleness-seconds", 86400, "staleness in seconds") - gasAfterPayment := deployCmd.Int64("gas-after-payment", 33285, "gas after payment calculation") - flatFeeTier1 := deployCmd.Int64("flat-fee-tier-1", 500, "flat fee tier 1") - flatFeeTier2 := deployCmd.Int64("flat-fee-tier-2", 500, "flat fee tier 2") - flatFeeTier3 := deployCmd.Int64("flat-fee-tier-3", 500, "flat fee tier 3") - flatFeeTier4 := deployCmd.Int64("flat-fee-tier-4", 500, "flat fee tier 4") - flatFeeTier5 := deployCmd.Int64("flat-fee-tier-5", 500, "flat fee tier 5") - reqsForTier2 := deployCmd.Int64("reqs-for-tier-2", 0, "requests for tier 2") - reqsForTier3 := deployCmd.Int64("reqs-for-tier-3", 0, "requests for tier 3") - reqsForTier4 := deployCmd.Int64("reqs-for-tier-4", 0, "requests for tier 4") - reqsForTier5 := deployCmd.Int64("reqs-for-tier-5", 0, "requests for tier 5") - - helpers.ParseArgs( - deployCmd, os.Args[2:], - ) - - fallbackWeiPerUnitLink := decimal.RequireFromString(*fallbackWeiPerUnitLinkString).BigInt() - subscriptionBalance := decimal.RequireFromString(*subscriptionBalanceString).BigInt() - - // Put key in ECDSA format - if strings.HasPrefix(*registerKeyUncompressedPubKey, "0x") { - *registerKeyUncompressedPubKey = strings.Replace(*registerKeyUncompressedPubKey, "0x", "04", 1) - } - - // Generate compressed public key and key hash - pubBytes, err := hex.DecodeString(*registerKeyUncompressedPubKey) - helpers.PanicErr(err) - pk, err := crypto.UnmarshalPubkey(pubBytes) - helpers.PanicErr(err) - var pkBytes []byte - if big.NewInt(0).Mod(pk.Y, big.NewInt(2)).Uint64() != 0 { - pkBytes = append(pk.X.Bytes(), 1) - } else { - pkBytes = append(pk.X.Bytes(), 0) - } - var newPK secp256k1.PublicKey - copy(newPK[:], pkBytes) - - compressedPkHex := hexutil.Encode(pkBytes) - keyHash, err := newPK.Hash() - helpers.PanicErr(err) - - if len(*linkAddress) == 0 { - fmt.Println("\nDeploying LINK Token...") - address := helpers.DeployLinkToken(e).String() - linkAddress = &address - } - - if len(*linkEthAddress) == 0 { - fmt.Println("\nDeploying LINK/ETH Feed...") - address := helpers.DeployLinkEthFeed(e, *linkAddress, fallbackWeiPerUnitLink).String() - linkEthAddress = &address - } - - fmt.Println("\nDeploying BHS...") - bhsContractAddress := deployBHS(e) - - fmt.Println("\nDeploying Batch BHS...") - batchBHSAddress := deployBatchBHS(e, bhsContractAddress) - - var coordinatorAddress common.Address - fmt.Println("\nDeploying Coordinator...") - coordinatorAddress = deployCoordinator(e, *linkAddress, bhsContractAddress.String(), *linkEthAddress) - - coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(coordinatorAddress, e.Ec) - helpers.PanicErr(err) - - fmt.Println("\nDeploying Batch Coordinator...") - batchCoordinatorAddress := deployBatchCoordinatorV2(e, coordinatorAddress) - - fmt.Println("\nSetting Coordinator Config...") - setCoordinatorConfig( - e, - *coordinator, - uint16(*minConfs), - uint32(*maxGasLimit), - uint32(*stalenessSeconds), - uint32(*gasAfterPayment), - fallbackWeiPerUnitLink, - vrf_coordinator_v2.VRFCoordinatorV2FeeConfig{ - FulfillmentFlatFeeLinkPPMTier1: uint32(*flatFeeTier1), - FulfillmentFlatFeeLinkPPMTier2: uint32(*flatFeeTier2), - FulfillmentFlatFeeLinkPPMTier3: uint32(*flatFeeTier3), - FulfillmentFlatFeeLinkPPMTier4: uint32(*flatFeeTier4), - FulfillmentFlatFeeLinkPPMTier5: uint32(*flatFeeTier5), - ReqsForTier2: big.NewInt(*reqsForTier2), - ReqsForTier3: big.NewInt(*reqsForTier3), - ReqsForTier4: big.NewInt(*reqsForTier4), - ReqsForTier5: big.NewInt(*reqsForTier5), - }, - ) - - fmt.Println("\nConfig set, getting current config from deployed contract...") - printCoordinatorConfig(coordinator) - - if len(*registerKeyUncompressedPubKey) > 0 && len(*registerKeyOracleAddress) > 0 { - fmt.Println("\nRegistering proving key...") - registerCoordinatorProvingKey(e, *coordinator, *registerKeyUncompressedPubKey, *registerKeyOracleAddress) - - fmt.Println("\nProving key registered, getting proving key hashes from deployed contract...") - _, _, provingKeyHashes, configErr := coordinator.GetRequestConfig(nil) - helpers.PanicErr(configErr) - fmt.Println("Key hash registered:", hex.EncodeToString(provingKeyHashes[0][:])) - } else { - fmt.Println("NOT registering proving key - you must do this eventually in order to fully deploy VRF!") - } - - fmt.Println("\nDeploying consumer...") - consumerAddress := eoaDeployConsumer(e, coordinatorAddress.String(), *linkAddress) - - fmt.Println("\nAdding subscription...") - eoaCreateSub(e, *coordinator) - subID := uint64(1) - - fmt.Println("\nAdding consumer to subscription...") - eoaAddConsumerToSub(e, *coordinator, subID, consumerAddress.String()) - - if subscriptionBalance.Cmp(big.NewInt(0)) > 0 { - fmt.Println("\nFunding subscription with", subscriptionBalance, "juels...") - eoaFundSubscription(e, *coordinator, *linkAddress, subscriptionBalance, subID) - } else { - fmt.Println("Subscription", subID, "NOT getting funded. You must fund the subscription in order to use it!") - } - - fmt.Println("\nSubscribed and (possibly) funded, retrieving subscription from deployed contract...") - s, err := coordinator.GetSubscription(nil, subID) - helpers.PanicErr(err) - fmt.Printf("Subscription %+v\n", s) - - if len(*registerKeyOracleAddress) > 0 && *oracleFundingAmount > 0 { - fmt.Println("\nFunding oracle...") - helpers.FundNodes(e, []string{*registerKeyOracleAddress}, big.NewInt(*oracleFundingAmount)) - } - - formattedJobSpec := fmt.Sprintf( - formattedVRFJob, - coordinatorAddress, - batchCoordinatorAddress, - false, - compressedPkHex, - e.ChainID, - *registerKeyOracleAddress, - coordinatorAddress, - coordinatorAddress, - coordinatorAddress, - ) - - fmt.Println( - "\nDeployment complete.", - "\nLINK Token contract address:", *linkAddress, - "\nLINK/ETH Feed contract address:", *linkEthAddress, - "\nBlockhash Store contract address:", bhsContractAddress, - "\nBatch Blockhash Store contract address:", batchBHSAddress, - "\nVRF Coordinator Address:", coordinatorAddress, - "\nBatch VRF Coordinator Address:", batchCoordinatorAddress, - "\nVRF Consumer Address:", consumerAddress, - "\nVRF Subscription Id:", subID, - "\nVRF Subscription Balance:", *subscriptionBalanceString, - "\nPossible VRF Request command: ", - fmt.Sprintf("go run . eoa-request --consumer-address %s --sub-id %d --key-hash %s", consumerAddress, subID, keyHash), - "\nA node can now be configured to run a VRF job with the below job spec :\n", - formattedJobSpec, - ) -} - -func deployWrapperUniverse(e helpers.Environment) { - cmd := flag.NewFlagSet("wrapper-universe-deploy", flag.ExitOnError) - linkAddress := cmd.String("link-address", "", "address of link token") - linkETHFeedAddress := cmd.String("link-eth-feed", "", "address of link-eth-feed") - coordinatorAddress := cmd.String("coordinator-address", "", "address of the vrf coordinator v2 contract") - wrapperGasOverhead := cmd.Uint("wrapper-gas-overhead", 50_000, "amount of gas overhead in wrapper fulfillment") - coordinatorGasOverhead := cmd.Uint("coordinator-gas-overhead", 52_000, "amount of gas overhead in coordinator fulfillment") - wrapperPremiumPercentage := cmd.Uint("wrapper-premium-percentage", 25, "gas premium charged by wrapper") - keyHash := cmd.String("key-hash", "", "the keyhash that wrapper requests should use") - maxNumWords := cmd.Uint("max-num-words", 10, "the keyhash that wrapper requests should use") - subFunding := cmd.String("sub-funding", "10000000000000000000", "amount to fund the subscription with") - consumerFunding := cmd.String("consumer-funding", "10000000000000000000", "amount to fund the consumer with") - helpers.ParseArgs(cmd, os.Args[2:], "link-address", "link-eth-feed", "coordinator-address", "key-hash") - - amount, s := big.NewInt(0).SetString(*subFunding, 10) - if !s { - panic(fmt.Sprintf("failed to parse top up amount '%s'", *subFunding)) - } - - wrapper, subID := wrapperDeploy(e, - common.HexToAddress(*linkAddress), - common.HexToAddress(*linkETHFeedAddress), - common.HexToAddress(*coordinatorAddress)) - - wrapperConfigure(e, - wrapper, - *wrapperGasOverhead, - *coordinatorGasOverhead, - *wrapperPremiumPercentage, - *keyHash, - *maxNumWords) - - consumer := wrapperConsumerDeploy(e, - common.HexToAddress(*linkAddress), - wrapper) - - coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(common.HexToAddress(*coordinatorAddress), e.Ec) - helpers.PanicErr(err) - - eoaFundSubscription(e, *coordinator, *linkAddress, amount, subID) - - link, err := link_token_interface.NewLinkToken(common.HexToAddress(*linkAddress), e.Ec) - helpers.PanicErr(err) - consumerAmount, s := big.NewInt(0).SetString(*consumerFunding, 10) - if !s { - panic(fmt.Sprintf("failed to parse top up amount '%s'", *consumerFunding)) - } - - tx, err := link.Transfer(e.Owner, consumer, consumerAmount) - helpers.PanicErr(err) - helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID, "link transfer to consumer") - - fmt.Println("wrapper universe deployment complete") - fmt.Println("wrapper address:", wrapper.String()) - fmt.Println("wrapper consumer address:", consumer.String()) -} From ff482232cf7855f759c44a50bc1cc41a00bfbcd3 Mon Sep 17 00:00:00 2001 From: Sam Date: Wed, 9 Aug 2023 11:00:53 -0400 Subject: [PATCH 122/270] Carry latest report over on config changes (#10101) * Carry latest report over on config changes * Rename table; instatiate ORM only once * Fix broken logic (include round/epoch) * Add final test * Fix linter * Fix test --- contracts/pnpm-lock.yaml | 3538 +++++++++-------- core/services/chainlink/application.go | 3 + core/services/job/spawner_test.go | 2 +- core/services/ocr2/delegate.go | 7 +- core/services/ocr2/plugins/mercury/plugin.go | 4 + .../services/relay/evm/mercury/data_source.go | 22 +- .../relay/evm/mercury/data_source_test.go | 106 +- .../relay/evm/mercury/helpers_test.go | 17 +- core/services/relay/evm/mercury/orm.go | 73 +- core/services/relay/evm/mercury/orm_test.go | 164 +- .../relay/evm/mercury/persistence_manager.go | 4 +- .../evm/mercury/persistence_manager_test.go | 48 +- .../evm/mercury/reportcodec/report_codec.go | 7 + .../mercury/reportcodec/report_codec_test.go | 30 +- .../0186_create_feed_latest_reports.sql | 13 + 15 files changed, 2168 insertions(+), 1870 deletions(-) create mode 100644 core/store/migrate/migrations/0186_create_feed_latest_reports.sql diff --git a/contracts/pnpm-lock.yaml b/contracts/pnpm-lock.yaml index 2d3185ed893..08064578c6d 100644 --- a/contracts/pnpm-lock.yaml +++ b/contracts/pnpm-lock.yaml @@ -1,133 +1,187 @@ -lockfileVersion: 5.4 +lockfileVersion: '6.0' + +settings: + autoInstallPeers: true + excludeLinksFromLockfile: false overrides: '@ethersproject/logger': 5.0.6 -specifiers: - '@eth-optimism/contracts': ^0.5.21 - '@ethereum-waffle/mock-contract': ^3.3.0 - '@ethersproject/abi': ~5.6.0 - '@ethersproject/bignumber': ~5.6.0 - '@ethersproject/contracts': ~5.6.0 - '@ethersproject/providers': ~5.6.1 - '@ethersproject/random': ~5.6.0 - '@nomicfoundation/hardhat-network-helpers': ^1.0.8 - '@nomiclabs/hardhat-ethers': ^2.0.2 - '@nomiclabs/hardhat-etherscan': ^3.1.0 - '@nomiclabs/hardhat-waffle': ^2.0.1 - '@openzeppelin/contracts': ~4.3.3 - '@openzeppelin/contracts-upgradeable-4.7.3': npm:@openzeppelin/contracts-upgradeable@v4.7.3 - '@openzeppelin/contracts-v0.7': npm:@openzeppelin/contracts@v3.4.2 - '@openzeppelin/hardhat-upgrades': 1.22.1 - '@openzeppelin/test-helpers': ^0.5.11 - '@typechain/ethers-v5': ^7.0.1 - '@typechain/hardhat': ^3.0.0 - '@types/cbor': 5.0.1 - '@types/chai': ^4.2.18 - '@types/debug': ^4.1.7 - '@types/deep-equal-in-any-order': ^1.0.1 - '@types/mocha': ^8.2.2 - '@types/node': ^15.12.2 - '@typescript-eslint/eslint-plugin': ^5.59.5 - '@typescript-eslint/parser': ^5.59.5 - abi-to-sol: ^0.6.6 - chai: ^4.3.4 - debug: ^4.3.2 - deep-equal-in-any-order: ^2.0.6 - eslint: ^8.40.0 - eslint-config-prettier: ^8.8.0 - eslint-plugin-prettier: ^4.2.1 - ethereum-waffle: ^3.3.0 - ethers: ~5.6.0 - hardhat: ~2.12.7 - hardhat-abi-exporter: ^2.2.1 - hardhat-contract-sizer: ^2.5.1 - hardhat-gas-reporter: ^1.0.9 - hardhat-ignore-warnings: ^0.2.6 - istanbul: ^0.4.5 - moment: ^2.29.4 - prettier: ^2.8.8 - prettier-plugin-solidity: 1.1.3 - rlp: ^2.0.0 - solhint: ^3.4.1 - solhint-plugin-prettier: ^0.0.5 - solidity-coverage: ^0.8.4 - ts-node: ^10.0.0 - tslib: ^2.4.0 - typechain: ^8.0.0 - typescript: ^4.3.2 - dependencies: - '@eth-optimism/contracts': 0.5.37_ethers@5.6.1 - '@openzeppelin/contracts': 4.3.3 - '@openzeppelin/contracts-upgradeable-4.7.3': /@openzeppelin/contracts-upgradeable/4.7.3 - '@openzeppelin/contracts-v0.7': /@openzeppelin/contracts/3.4.2 + '@eth-optimism/contracts': + specifier: ^0.5.21 + version: 0.5.37(ethers@5.6.1) + '@openzeppelin/contracts': + specifier: ~4.3.3 + version: 4.3.3 + '@openzeppelin/contracts-upgradeable-4.7.3': + specifier: npm:@openzeppelin/contracts-upgradeable@v4.7.3 + version: /@openzeppelin/contracts-upgradeable@4.7.3 + '@openzeppelin/contracts-v0.7': + specifier: npm:@openzeppelin/contracts@v3.4.2 + version: /@openzeppelin/contracts@3.4.2 devDependencies: - '@ethereum-waffle/mock-contract': 3.4.4 - '@ethersproject/abi': 5.6.1 - '@ethersproject/bignumber': 5.6.1 - '@ethersproject/contracts': 5.6.1 - '@ethersproject/providers': 5.6.1 - '@ethersproject/random': 5.6.1 - '@nomicfoundation/hardhat-network-helpers': 1.0.8_hardhat@2.12.7 - '@nomiclabs/hardhat-ethers': 2.0.2_z6fcyyhc2nf3iwqkyspxr4tlaq - '@nomiclabs/hardhat-etherscan': 3.1.0_hardhat@2.12.7 - '@nomiclabs/hardhat-waffle': 2.0.1_d7ejcwiim3eoh3awwn3s5bqjfe - '@openzeppelin/hardhat-upgrades': 1.22.1_t427xxny5pzfvmqb7mxuxbqor4 - '@openzeppelin/test-helpers': 0.5.11_bn.js@4.12.0 - '@typechain/ethers-v5': 7.2.0_pwtfr6mt5pw2hiixtkqheirqmq - '@typechain/hardhat': 3.1.0_gx5th54lc6trgzrpj7pwublyoa - '@types/cbor': 5.0.1 - '@types/chai': 4.3.3 - '@types/debug': 4.1.7 - '@types/deep-equal-in-any-order': 1.0.1 - '@types/mocha': 8.2.2 - '@types/node': 15.14.9 - '@typescript-eslint/eslint-plugin': 5.59.8_loqfnwogukjtmydbmg57mzzpb4 - '@typescript-eslint/parser': 5.59.8_kigkzfftsmftz3xok324pyvzui - abi-to-sol: 0.6.6 - chai: 4.3.6 - debug: 4.3.4 - deep-equal-in-any-order: 2.0.6 - eslint: 8.42.0 - eslint-config-prettier: 8.8.0_eslint@8.42.0 - eslint-plugin-prettier: 4.2.1_vnriwwub2rhvoyn4ckagrc4lpi - ethereum-waffle: 3.3.0_typescript@4.9.5 - ethers: 5.6.1 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i - hardhat-abi-exporter: 2.2.1_hardhat@2.12.7 - hardhat-contract-sizer: 2.5.1_hardhat@2.12.7 - hardhat-gas-reporter: 1.0.9_hardhat@2.12.7 - hardhat-ignore-warnings: 0.2.9 - istanbul: 0.4.5 - moment: 2.29.4 - prettier: 2.8.8 - prettier-plugin-solidity: 1.1.3_prettier@2.8.8 - rlp: 2.2.7 - solhint: 3.4.1 - solhint-plugin-prettier: 0.0.5_x46sgpbsioqs6smmgnper2ntba - solidity-coverage: 0.8.4_hardhat@2.12.7 - ts-node: 10.0.0_zlol4fzmmjgb3bdeviopae4asm - tslib: 2.4.0 - typechain: 8.2.0_typescript@4.9.5 - typescript: 4.9.5 + '@ethereum-waffle/mock-contract': + specifier: ^3.3.0 + version: 3.4.4 + '@ethersproject/abi': + specifier: ~5.6.0 + version: 5.6.1 + '@ethersproject/bignumber': + specifier: ~5.6.0 + version: 5.6.1 + '@ethersproject/contracts': + specifier: ~5.6.0 + version: 5.6.1 + '@ethersproject/providers': + specifier: ~5.6.1 + version: 5.6.1 + '@ethersproject/random': + specifier: ~5.6.0 + version: 5.6.1 + '@nomicfoundation/hardhat-network-helpers': + specifier: ^1.0.8 + version: 1.0.8(hardhat@2.12.7) + '@nomiclabs/hardhat-ethers': + specifier: ^2.0.2 + version: 2.0.2(ethers@5.6.1)(hardhat@2.12.7) + '@nomiclabs/hardhat-etherscan': + specifier: ^3.1.0 + version: 3.1.0(hardhat@2.12.7) + '@nomiclabs/hardhat-waffle': + specifier: ^2.0.1 + version: 2.0.1(@nomiclabs/hardhat-ethers@2.0.2)(ethereum-waffle@3.3.0)(ethers@5.6.1)(hardhat@2.12.7) + '@openzeppelin/hardhat-upgrades': + specifier: 1.22.1 + version: 1.22.1(@nomiclabs/hardhat-ethers@2.0.2)(@nomiclabs/hardhat-etherscan@3.1.0)(ethers@5.6.1)(hardhat@2.12.7) + '@openzeppelin/test-helpers': + specifier: ^0.5.11 + version: 0.5.11(bn.js@4.12.0) + '@typechain/ethers-v5': + specifier: ^7.0.1 + version: 7.2.0(@ethersproject/abi@5.6.1)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.6.1)(ethers@5.6.1)(typechain@8.2.0)(typescript@4.9.5) + '@typechain/hardhat': + specifier: ^3.0.0 + version: 3.1.0(hardhat@2.12.7)(lodash@4.17.21)(typechain@8.2.0) + '@types/cbor': + specifier: 5.0.1 + version: 5.0.1 + '@types/chai': + specifier: ^4.2.18 + version: 4.3.3 + '@types/debug': + specifier: ^4.1.7 + version: 4.1.7 + '@types/deep-equal-in-any-order': + specifier: ^1.0.1 + version: 1.0.1 + '@types/mocha': + specifier: ^8.2.2 + version: 8.2.2 + '@types/node': + specifier: ^15.12.2 + version: 15.14.9 + '@typescript-eslint/eslint-plugin': + specifier: ^5.59.5 + version: 5.59.8(@typescript-eslint/parser@5.59.8)(eslint@8.42.0)(typescript@4.9.5) + '@typescript-eslint/parser': + specifier: ^5.59.5 + version: 5.59.8(eslint@8.42.0)(typescript@4.9.5) + abi-to-sol: + specifier: ^0.6.6 + version: 0.6.6 + chai: + specifier: ^4.3.4 + version: 4.3.6 + debug: + specifier: ^4.3.2 + version: 4.3.4(supports-color@8.1.1) + deep-equal-in-any-order: + specifier: ^2.0.6 + version: 2.0.6 + eslint: + specifier: ^8.40.0 + version: 8.42.0 + eslint-config-prettier: + specifier: ^8.8.0 + version: 8.8.0(eslint@8.42.0) + eslint-plugin-prettier: + specifier: ^4.2.1 + version: 4.2.1(eslint-config-prettier@8.8.0)(eslint@8.42.0)(prettier@2.8.8) + ethereum-waffle: + specifier: ^3.3.0 + version: 3.3.0(typescript@4.9.5) + ethers: + specifier: ~5.6.0 + version: 5.6.1 + hardhat: + specifier: ~2.12.7 + version: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) + hardhat-abi-exporter: + specifier: ^2.2.1 + version: 2.2.1(hardhat@2.12.7) + hardhat-contract-sizer: + specifier: ^2.5.1 + version: 2.5.1(hardhat@2.12.7) + hardhat-gas-reporter: + specifier: ^1.0.9 + version: 1.0.9(hardhat@2.12.7) + hardhat-ignore-warnings: + specifier: ^0.2.6 + version: 0.2.9 + istanbul: + specifier: ^0.4.5 + version: 0.4.5 + moment: + specifier: ^2.29.4 + version: 2.29.4 + prettier: + specifier: ^2.8.8 + version: 2.8.8 + prettier-plugin-solidity: + specifier: 1.1.3 + version: 1.1.3(prettier@2.8.8) + rlp: + specifier: ^2.0.0 + version: 2.2.7 + solhint: + specifier: ^3.4.1 + version: 3.4.1 + solhint-plugin-prettier: + specifier: ^0.0.5 + version: 0.0.5(prettier-plugin-solidity@1.1.3)(prettier@2.8.8) + solidity-coverage: + specifier: ^0.8.4 + version: 0.8.4(hardhat@2.12.7) + ts-node: + specifier: ^10.0.0 + version: 10.0.0(@types/node@15.14.9)(typescript@4.9.5) + tslib: + specifier: ^2.4.0 + version: 2.4.0 + typechain: + specifier: ^8.0.0 + version: 8.2.0(typescript@4.9.5) + typescript: + specifier: ^4.3.2 + version: 4.9.5 packages: - /@babel/code-frame/7.18.6: + /@babel/code-frame@7.18.6: resolution: {integrity: sha512-TDCmlK5eOvH+eH7cdAFlNXeVJqWIQ7gW9tY1GJIpUtFb6CmjVyq2VM3u71bOyR8CRihcCgMUYoDNyLXao3+70Q==} engines: {node: '>=6.9.0'} dependencies: '@babel/highlight': 7.18.6 dev: true - /@babel/helper-validator-identifier/7.19.1: + /@babel/helper-validator-identifier@7.19.1: resolution: {integrity: sha512-awrNfaMtnHUr653GgGEs++LlAvW6w+DcPrOliSMXWCKo597CwL5Acf/wWdNkf/tfEQE3mjkeD1YOVZOUV/od1w==} engines: {node: '>=6.9.0'} dev: true - /@babel/highlight/7.18.6: + /@babel/highlight@7.18.6: resolution: {integrity: sha512-u7stbOuYjaPezCuLj29hNW1v64M2Md2qupEKP1fHc7WdOA3DgLh37suiSrZYY7haUB7iBeQZ9P1uiRF359do3g==} engines: {node: '>=6.9.0'} dependencies: @@ -136,21 +190,21 @@ packages: js-tokens: 4.0.0 dev: true - /@babel/runtime/7.19.0: + /@babel/runtime@7.19.0: resolution: {integrity: sha512-eR8Lo9hnDS7tqkO7NsV+mKvCmv5boaXFSZ70DnfhcgiEne8hv9oCEd36Klw74EtizEqLsy4YnW8UWwpBVolHZA==} engines: {node: '>=6.9.0'} dependencies: regenerator-runtime: 0.13.9 dev: true - /@colors/colors/1.5.0: + /@colors/colors@1.5.0: resolution: {integrity: sha512-ooWCrlZP11i8GImSjTHYHLkvFDP48nS4+204nGb1RiX/WXYHmJA2III9/e2DWVabCESdW7hBAEzHRqUn9OUVvQ==} engines: {node: '>=0.1.90'} requiresBuild: true dev: true optional: true - /@ensdomains/address-encoder/0.1.9: + /@ensdomains/address-encoder@0.1.9: resolution: {integrity: sha512-E2d2gP4uxJQnDu2Kfg1tHNspefzbLT8Tyjrm5sEuim32UkU2sm5xL4VXtgc2X33fmPEw9+jUMpGs4veMbf+PYg==} dependencies: bech32: 1.1.4 @@ -162,7 +216,7 @@ packages: ripemd160: 2.0.2 dev: true - /@ensdomains/ens/0.4.5: + /@ensdomains/ens@0.4.5: resolution: {integrity: sha512-JSvpj1iNMFjK6K+uVl4unqMoa9rf5jopb8cya5UGBWz23Nw8hSNT7efgUx4BTlAPAgpNlEioUfeTyQ6J9ZvTVw==} deprecated: Please use @ensdomains/ens-contracts dependencies: @@ -173,7 +227,7 @@ packages: web3-utils: 1.8.0 dev: true - /@ensdomains/ensjs/2.1.0: + /@ensdomains/ensjs@2.1.0: resolution: {integrity: sha512-GRbGPT8Z/OJMDuxs75U/jUNEC0tbL0aj7/L/QQznGYKm/tiasp+ndLOaoULy9kKJFC0TBByqfFliEHDgoLhyog==} dependencies: '@babel/runtime': 7.19.0 @@ -189,12 +243,12 @@ packages: - utf-8-validate dev: true - /@ensdomains/resolver/0.2.4: + /@ensdomains/resolver@0.2.4: resolution: {integrity: sha512-bvaTH34PMCbv6anRa9I/0zjLJgY4EuznbEMgbV77JBCQ9KNC46rzi0avuxpOfu+xDjPEtSFGqVEOr5GlUSGudA==} deprecated: Please use @ensdomains/ens-contracts dev: true - /@eslint-community/eslint-utils/4.4.0_eslint@8.42.0: + /@eslint-community/eslint-utils@4.4.0(eslint@8.42.0): resolution: {integrity: sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -204,17 +258,17 @@ packages: eslint-visitor-keys: 3.4.1 dev: true - /@eslint-community/regexpp/4.5.1: + /@eslint-community/regexpp@4.5.1: resolution: {integrity: sha512-Z5ba73P98O1KUYCCJTUeVpja9RcGoMdncZ6T49FCUl2lN38JtCJ+3WgIDBv0AuY4WChU5PmtJmOCTlN6FZTFKQ==} engines: {node: ^12.0.0 || ^14.0.0 || >=16.0.0} dev: true - /@eslint/eslintrc/2.0.3: + /@eslint/eslintrc@2.0.3: resolution: {integrity: sha512-+5gy6OQfk+xx3q0d6jGZZC3f3KzAkXc/IanVxd1is/VIIziRqqt3ongQz0FiTUXqTk0c7aDB3OaFuKnuSoJicQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: ajv: 6.12.6 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) espree: 9.5.2 globals: 13.20.0 ignore: 5.2.4 @@ -226,12 +280,12 @@ packages: - supports-color dev: true - /@eslint/js/8.42.0: + /@eslint/js@8.42.0: resolution: {integrity: sha512-6SWlXpWU5AvId8Ac7zjzmIOqMOba/JWY8XZ4A7q7Gn1Vlfg/SFFIlrtHXt9nPn4op9ZPAkl91Jao+QQv3r/ukw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /@eth-optimism/contracts/0.5.37_ethers@5.6.1: + /@eth-optimism/contracts@0.5.37(ethers@5.6.1): resolution: {integrity: sha512-HbNUUDIM1dUAM0hWPfGp3l9/Zte40zi8QhVbUSIwdYRA7jG7cZgbteqavrjW8wwFqxkWX9IrtA0KAR7pNlSAIQ==} peerDependencies: ethers: ^5 @@ -245,7 +299,7 @@ packages: - utf-8-validate dev: false - /@eth-optimism/core-utils/0.10.1: + /@eth-optimism/core-utils@0.10.1: resolution: {integrity: sha512-IJvG5UtYvyz6An9QdohlCLoeB3NBFxx2lRJKlPzvYYlfugUNNCHsajRIWIwJTcPRRma0WPd46JUsKACLJDdNrA==} dependencies: '@ethersproject/abi': 5.7.0 @@ -269,7 +323,7 @@ packages: - utf-8-validate dev: false - /@ethereum-waffle/chai/3.4.4: + /@ethereum-waffle/chai@3.4.4: resolution: {integrity: sha512-/K8czydBtXXkcM9X6q29EqEkc5dN3oYenyH2a9hF7rGAApAJUpH8QBtojxOY/xQ2up5W332jqgxwp0yPiYug1g==} engines: {node: '>=10.0'} dependencies: @@ -282,13 +336,13 @@ packages: - utf-8-validate dev: true - /@ethereum-waffle/compiler/3.4.4_typescript@4.9.5: + /@ethereum-waffle/compiler@3.4.4(typescript@4.9.5): resolution: {integrity: sha512-RUK3axJ8IkD5xpWjWoJgyHclOeEzDLQFga6gKpeGxiS/zBu+HB0W2FvsrrLalTFIaPw/CGYACRBSIxqiCqwqTQ==} engines: {node: '>=10.0'} dependencies: '@resolver-engine/imports': 0.3.3 '@resolver-engine/imports-fs': 0.3.3 - '@typechain/ethers-v5': 2.0.0_mwhxf3vrorrl5yk6tbvkb5vxk4 + '@typechain/ethers-v5': 2.0.0(ethers@5.6.1)(typechain@3.0.0) '@types/mkdirp': 0.5.2 '@types/node-fetch': 2.6.2 ethers: 5.6.1 @@ -296,7 +350,7 @@ packages: node-fetch: 2.6.7 solc: 0.6.12 ts-generator: 0.1.1 - typechain: 3.0.0_typescript@4.9.5 + typechain: 3.0.0(typescript@4.9.5) transitivePeerDependencies: - bufferutil - encoding @@ -305,7 +359,7 @@ packages: - utf-8-validate dev: true - /@ethereum-waffle/ens/3.4.4: + /@ethereum-waffle/ens@3.4.4: resolution: {integrity: sha512-0m4NdwWxliy3heBYva1Wr4WbJKLnwXizmy5FfSSr5PMbjI7SIGCdCB59U7/ZzY773/hY3bLnzLwvG5mggVjJWg==} engines: {node: '>=10.0'} dependencies: @@ -317,7 +371,7 @@ packages: - utf-8-validate dev: true - /@ethereum-waffle/mock-contract/3.4.4: + /@ethereum-waffle/mock-contract@3.4.4: resolution: {integrity: sha512-Mp0iB2YNWYGUV+VMl5tjPsaXKbKo8MDH9wSJ702l9EBjdxFf/vBvnMBAC1Fub1lLtmD0JHtp1pq+mWzg/xlLnA==} engines: {node: '>=10.0'} dependencies: @@ -328,7 +382,7 @@ packages: - utf-8-validate dev: true - /@ethereum-waffle/provider/3.4.4: + /@ethereum-waffle/provider@3.4.4: resolution: {integrity: sha512-GK8oKJAM8+PKy2nK08yDgl4A80mFuI8zBkE0C9GqTRYQqvuxIyXoLmJ5NZU9lIwyWVv5/KsoA11BgAv2jXE82g==} engines: {node: '>=10.0'} dependencies: @@ -344,21 +398,21 @@ packages: - utf-8-validate dev: true - /@ethereumjs/common/2.6.5: + /@ethereumjs/common@2.6.5: resolution: {integrity: sha512-lRyVQOeCDaIVtgfbowla32pzeDv2Obr8oR8Put5RdUBNRGr1VGPGQNGP6elWIpgK3YdpzqTOh4GyUGOureVeeA==} dependencies: crc-32: 1.2.2 ethereumjs-util: 7.1.5 dev: true - /@ethereumjs/tx/3.5.2: + /@ethereumjs/tx@3.5.2: resolution: {integrity: sha512-gQDNJWKrSDGu2w7w0PzVXVBNMzb7wwdDOmOqczmhNjqFxFuIbhVJDwiGEnxFNC2/b8ifcZzY7MLcluizohRzNw==} dependencies: '@ethereumjs/common': 2.6.5 ethereumjs-util: 7.1.5 dev: true - /@ethersproject/abi/5.0.0-beta.153: + /@ethersproject/abi@5.0.0-beta.153: resolution: {integrity: sha512-aXweZ1Z7vMNzJdLpR1CZUAIgnwjrZeUSvN9syCwlBaEBUFJmFY+HHnfuTI5vIhVs/mRkfJVrbEyl51JZQqyjAg==} dependencies: '@ethersproject/address': 5.7.0 @@ -373,7 +427,7 @@ packages: dev: true optional: true - /@ethersproject/abi/5.6.0: + /@ethersproject/abi@5.6.0: resolution: {integrity: sha512-AhVByTwdXCc2YQ20v300w6KVHle9g2OFc28ZAFCPnJyEpkv1xKXjZcSTgWOlv1i+0dqlgF8RCF2Rn2KC1t+1Vg==} dependencies: '@ethersproject/address': 5.7.0 @@ -386,7 +440,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/abi/5.6.1: + /@ethersproject/abi@5.6.1: resolution: {integrity: sha512-0cqssYh6FXjlwKWBmLm3+zH2BNARoS5u/hxbz+LpQmcDB3w0W553h2btWui1/uZp2GBM/SI3KniTuMcYyHpA5w==} dependencies: '@ethersproject/address': 5.7.0 @@ -400,7 +454,7 @@ packages: '@ethersproject/strings': 5.7.0 dev: true - /@ethersproject/abi/5.7.0: + /@ethersproject/abi@5.7.0: resolution: {integrity: sha512-351ktp42TiRcYB3H1OP8yajPeAQstMW/yCFokj/AthP9bLHzQFPlOrxOcwYEDkUAICmOHljvN4K39OMTMUa9RA==} dependencies: '@ethersproject/address': 5.7.0 @@ -413,7 +467,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/abstract-provider/5.6.0: + /@ethersproject/abstract-provider@5.6.0: resolution: {integrity: sha512-oPMFlKLN+g+y7a79cLK3WiLcjWFnZQtXWgnLAbHZcN3s7L4v90UHpTOrLk+m3yr0gt+/h9STTM6zrr7PM8uoRw==} dependencies: '@ethersproject/bignumber': 5.6.1 @@ -424,7 +478,7 @@ packages: '@ethersproject/transactions': 5.7.0 '@ethersproject/web': 5.7.1 - /@ethersproject/abstract-provider/5.7.0: + /@ethersproject/abstract-provider@5.7.0: resolution: {integrity: sha512-R41c9UkchKCpAqStMYUpdunjo3pkEvZC3FAwZn5S5MGbXoMQOHIdHItezTETxAO5bevtMApSyEhn9+CHcDsWBw==} dependencies: '@ethersproject/bignumber': 5.7.0 @@ -435,7 +489,7 @@ packages: '@ethersproject/transactions': 5.7.0 '@ethersproject/web': 5.7.1 - /@ethersproject/abstract-signer/5.6.0: + /@ethersproject/abstract-signer@5.6.0: resolution: {integrity: sha512-WOqnG0NJKtI8n0wWZPReHtaLkDByPL67tn4nBaDAhmVq8sjHTPbCdz4DRhVu/cfTOvfy9w3iq5QZ7BX7zw56BQ==} dependencies: '@ethersproject/abstract-provider': 5.7.0 @@ -444,7 +498,7 @@ packages: '@ethersproject/logger': 5.0.6 '@ethersproject/properties': 5.7.0 - /@ethersproject/abstract-signer/5.7.0: + /@ethersproject/abstract-signer@5.7.0: resolution: {integrity: sha512-a16V8bq1/Cz+TGCkE2OPMTOUDLS3grCpdjoJCYNnVBbdYEMSgKrU0+B90s8b6H+ByYTBZN7a3g76jdIJi7UfKQ==} dependencies: '@ethersproject/abstract-provider': 5.7.0 @@ -453,7 +507,7 @@ packages: '@ethersproject/logger': 5.0.6 '@ethersproject/properties': 5.7.0 - /@ethersproject/address/5.6.0: + /@ethersproject/address@5.6.0: resolution: {integrity: sha512-6nvhYXjbXsHPS+30sHZ+U4VMagFC/9zAk6Gd/h3S21YW4+yfb0WfRtaAIZ4kfM4rrVwqiy284LP0GtL5HXGLxQ==} dependencies: '@ethersproject/bignumber': 5.6.1 @@ -462,7 +516,7 @@ packages: '@ethersproject/logger': 5.0.6 '@ethersproject/rlp': 5.7.0 - /@ethersproject/address/5.7.0: + /@ethersproject/address@5.7.0: resolution: {integrity: sha512-9wYhYt7aghVGo758POM5nqcOMaE168Q6aRLJZwUmiqSrAungkG74gSSeKEIR7ukixesdRZGPgVqme6vmxs1fkA==} dependencies: '@ethersproject/bignumber': 5.7.0 @@ -471,70 +525,70 @@ packages: '@ethersproject/logger': 5.0.6 '@ethersproject/rlp': 5.7.0 - /@ethersproject/base64/5.6.0: + /@ethersproject/base64@5.6.0: resolution: {integrity: sha512-2Neq8wxJ9xHxCF9TUgmKeSh9BXJ6OAxWfeGWvbauPh8FuHEjamgHilllx8KkSd5ErxyHIX7Xv3Fkcud2kY9ezw==} dependencies: '@ethersproject/bytes': 5.7.0 - /@ethersproject/base64/5.7.0: + /@ethersproject/base64@5.7.0: resolution: {integrity: sha512-Dr8tcHt2mEbsZr/mwTPIQAf3Ai0Bks/7gTw9dSqk1mQvhW3XvRlmDJr/4n+wg1JmCl16NZue17CDh8xb/vZ0sQ==} dependencies: '@ethersproject/bytes': 5.7.0 - /@ethersproject/basex/5.6.0: + /@ethersproject/basex@5.6.0: resolution: {integrity: sha512-qN4T+hQd/Md32MoJpc69rOwLYRUXwjTlhHDIeUkUmiN/JyWkkLLMoG0TqvSQKNqZOMgN5stbUYN6ILC+eD7MEQ==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/properties': 5.7.0 - /@ethersproject/basex/5.7.0: + /@ethersproject/basex@5.7.0: resolution: {integrity: sha512-ywlh43GwZLv2Voc2gQVTKBoVQ1mti3d8HK5aMxsfu/nRDnMmNqaSJ3r3n85HBByT8OpoY96SXM1FogC533T4zw==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/properties': 5.7.0 - /@ethersproject/bignumber/5.6.0: + /@ethersproject/bignumber@5.6.0: resolution: {integrity: sha512-VziMaXIUHQlHJmkv1dlcd6GY2PmT0khtAqaMctCIDogxkrarMzA9L94KN1NeXqqOfFD6r0sJT3vCTOFSmZ07DA==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 bn.js: 4.12.0 - /@ethersproject/bignumber/5.6.1: + /@ethersproject/bignumber@5.6.1: resolution: {integrity: sha512-UtMeZ3GaUuF9sx2u9nPZiPP3ULcAFmXyvynR7oHl/tPrM+vldZh7ocMsoa1PqKYGnQnqUZJoqxZnGN6J0qdipA==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 bn.js: 4.12.0 - /@ethersproject/bignumber/5.7.0: + /@ethersproject/bignumber@5.7.0: resolution: {integrity: sha512-n1CAdIHRWjSucQO3MC1zPSVgV/6dy/fjL9pMrPP9peL+QxEg9wOsVqwD4+818B6LUEtaXzVHQiuivzRoxPxUGw==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 bn.js: 5.2.1 - /@ethersproject/bytes/5.6.0: + /@ethersproject/bytes@5.6.0: resolution: {integrity: sha512-3hJPlYemb9V4VLfJF5BfN0+55vltPZSHU3QKUyP9M3Y2TcajbiRrz65UG+xVHOzBereB1b9mn7r12o177xgN7w==} dependencies: '@ethersproject/logger': 5.0.6 - /@ethersproject/bytes/5.7.0: + /@ethersproject/bytes@5.7.0: resolution: {integrity: sha512-nsbxwgFXWh9NyYWo+U8atvmMsSdKJprTcICAkvbBffT75qDocbuggBU0SJiVK2MuTrp0q+xvLkTnGMPK1+uA9A==} dependencies: '@ethersproject/logger': 5.0.6 - /@ethersproject/constants/5.6.0: + /@ethersproject/constants@5.6.0: resolution: {integrity: sha512-SrdaJx2bK0WQl23nSpV/b1aq293Lh0sUaZT/yYKPDKn4tlAbkH96SPJwIhwSwTsoQQZxuh1jnqsKwyymoiBdWA==} dependencies: '@ethersproject/bignumber': 5.6.1 - /@ethersproject/constants/5.7.0: + /@ethersproject/constants@5.7.0: resolution: {integrity: sha512-DHI+y5dBNvkpYUMiRQyxRBYBefZkJfo70VUkUAsRjcPs47muV9evftfZ0PJVCXYbAiCgght0DtcF9srFQmIgWA==} dependencies: '@ethersproject/bignumber': 5.7.0 - /@ethersproject/contracts/5.6.0: + /@ethersproject/contracts@5.6.0: resolution: {integrity: sha512-74Ge7iqTDom0NX+mux8KbRUeJgu1eHZ3iv6utv++sLJG80FVuU9HnHeKVPfjd9s3woFhaFoQGf3B3iH/FrQmgw==} dependencies: '@ethersproject/abi': 5.7.0 @@ -548,7 +602,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/transactions': 5.7.0 - /@ethersproject/contracts/5.6.1: + /@ethersproject/contracts@5.6.1: resolution: {integrity: sha512-0fpBBDoPqJMsutE6sNjg6pvCJaIcl7tliMQTMRcoUWDACfjO68CpKOJBlsEhEhmzdnu/41KbrfAeg+sB3y35MQ==} dependencies: '@ethersproject/abi': 5.6.1 @@ -563,7 +617,7 @@ packages: '@ethersproject/transactions': 5.7.0 dev: true - /@ethersproject/contracts/5.7.0: + /@ethersproject/contracts@5.7.0: resolution: {integrity: sha512-5GJbzEU3X+d33CdfPhcyS+z8MzsTrBGk/sc+G+59+tPa9yFkl6HQ9D6L0QMgNTA9q8dT0XKxxkyp883XsQvbbg==} dependencies: '@ethersproject/abi': 5.7.0 @@ -578,7 +632,7 @@ packages: '@ethersproject/transactions': 5.7.0 dev: false - /@ethersproject/hash/5.6.0: + /@ethersproject/hash@5.6.0: resolution: {integrity: sha512-fFd+k9gtczqlr0/BruWLAu7UAOas1uRRJvOR84uDf4lNZ+bTkGl366qvniUZHKtlqxBRU65MkOobkmvmpHU+jA==} dependencies: '@ethersproject/abstract-signer': 5.7.0 @@ -590,7 +644,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/hash/5.7.0: + /@ethersproject/hash@5.7.0: resolution: {integrity: sha512-qX5WrQfnah1EFnO5zJv1v46a8HW0+E5xuBBDTwMFZLuVTx0tbU2kkx15NqdjxecrLGatQN9FGQKpb1FKdHCt+g==} dependencies: '@ethersproject/abstract-signer': 5.7.0 @@ -603,7 +657,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/hdnode/5.6.0: + /@ethersproject/hdnode@5.6.0: resolution: {integrity: sha512-61g3Jp3nwDqJcL/p4nugSyLrpl/+ChXIOtCEM8UDmWeB3JCAt5FoLdOMXQc3WWkc0oM2C0aAn6GFqqMcS/mHTw==} dependencies: '@ethersproject/abstract-signer': 5.7.0 @@ -619,7 +673,7 @@ packages: '@ethersproject/transactions': 5.7.0 '@ethersproject/wordlists': 5.7.0 - /@ethersproject/hdnode/5.7.0: + /@ethersproject/hdnode@5.7.0: resolution: {integrity: sha512-OmyYo9EENBPPf4ERhR7oj6uAtUAhYGqOnIS+jE5pTXvdKBS99ikzq1E7Iv0ZQZ5V36Lqx1qZLeak0Ra16qpeOg==} dependencies: '@ethersproject/abstract-signer': 5.7.0 @@ -635,7 +689,7 @@ packages: '@ethersproject/transactions': 5.7.0 '@ethersproject/wordlists': 5.7.0 - /@ethersproject/json-wallets/5.6.0: + /@ethersproject/json-wallets@5.6.0: resolution: {integrity: sha512-fmh86jViB9r0ibWXTQipxpAGMiuxoqUf78oqJDlCAJXgnJF024hOOX7qVgqsjtbeoxmcLwpPsXNU0WEe/16qPQ==} dependencies: '@ethersproject/abstract-signer': 5.7.0 @@ -652,7 +706,7 @@ packages: aes-js: 3.0.0 scrypt-js: 3.0.1 - /@ethersproject/json-wallets/5.7.0: + /@ethersproject/json-wallets@5.7.0: resolution: {integrity: sha512-8oee5Xgu6+RKgJTkvEMl2wDgSPSAQ9MB/3JYjFV9jlKvcYHUXZC+cQp0njgmxdHkYWn8s6/IqIZYm0YWCjO/0g==} dependencies: '@ethersproject/abstract-signer': 5.7.0 @@ -669,54 +723,54 @@ packages: aes-js: 3.0.0 scrypt-js: 3.0.1 - /@ethersproject/keccak256/5.6.0: + /@ethersproject/keccak256@5.6.0: resolution: {integrity: sha512-tk56BJ96mdj/ksi7HWZVWGjCq0WVl/QvfhFQNeL8fxhBlGoP+L80uDCiQcpJPd+2XxkivS3lwRm3E0CXTfol0w==} dependencies: '@ethersproject/bytes': 5.7.0 js-sha3: 0.8.0 - /@ethersproject/keccak256/5.7.0: + /@ethersproject/keccak256@5.7.0: resolution: {integrity: sha512-2UcPboeL/iW+pSg6vZ6ydF8tCnv3Iu/8tUmLLzWWGzxWKFFqOBQFLo6uLUv6BDrLgCDfN28RJ/wtByx+jZ4KBg==} dependencies: '@ethersproject/bytes': 5.7.0 js-sha3: 0.8.0 - /@ethersproject/logger/5.0.6: + /@ethersproject/logger@5.0.6: resolution: {integrity: sha512-FrX0Vnb3JZ1md/7GIZfmJ06XOAA8r3q9Uqt9O5orr4ZiksnbpXKlyDzQtlZ5Yv18RS8CAUbiKH9vwidJg1BPmQ==} - /@ethersproject/networks/5.6.0: + /@ethersproject/networks@5.6.0: resolution: {integrity: sha512-DaVzgyThzHgSDLuURhvkp4oviGoGe9iTZW4jMEORHDRCgSZ9K9THGFKqL+qGXqPAYLEgZTf5z2w56mRrPR1MjQ==} dependencies: '@ethersproject/logger': 5.0.6 - /@ethersproject/networks/5.7.1: + /@ethersproject/networks@5.7.1: resolution: {integrity: sha512-n/MufjFYv3yFcUyfhnXotyDlNdFb7onmkSy8aQERi2PjNcnWQ66xXxa3XlS8nCcA8aJKJjIIMNJTC7tu80GwpQ==} dependencies: '@ethersproject/logger': 5.0.6 - /@ethersproject/pbkdf2/5.6.0: + /@ethersproject/pbkdf2@5.6.0: resolution: {integrity: sha512-Wu1AxTgJo3T3H6MIu/eejLFok9TYoSdgwRr5oGY1LTLfmGesDoSx05pemsbrPT2gG4cQME+baTSCp5sEo2erZQ==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/sha2': 5.7.0 - /@ethersproject/pbkdf2/5.7.0: + /@ethersproject/pbkdf2@5.7.0: resolution: {integrity: sha512-oR/dBRZR6GTyaofd86DehG72hY6NpAjhabkhxgr3X2FpJtJuodEl2auADWBZfhDHgVCbu3/H/Ocq2uC6dpNjjw==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/sha2': 5.7.0 - /@ethersproject/properties/5.6.0: + /@ethersproject/properties@5.6.0: resolution: {integrity: sha512-szoOkHskajKePTJSZ46uHUWWkbv7TzP2ypdEK6jGMqJaEt2sb0jCgfBo0gH0m2HBpRixMuJ6TBRaQCF7a9DoCg==} dependencies: '@ethersproject/logger': 5.0.6 - /@ethersproject/properties/5.7.0: + /@ethersproject/properties@5.7.0: resolution: {integrity: sha512-J87jy8suntrAkIZtecpxEPxY//szqr1mlBaYlQ0r4RCaiD2hjheqF9s1LVE8vVuJCXisjIP+JgtK/Do54ej4Sw==} dependencies: '@ethersproject/logger': 5.0.6 - /@ethersproject/providers/5.6.1: + /@ethersproject/providers@5.6.1: resolution: {integrity: sha512-w8Wx15nH+aVDvnoKCyI1f3x0B5idmk/bDJXMEUqCfdO8Eadd0QpDx9lDMTMmenhOmf9vufLJXjpSm24D3ZnVpg==} dependencies: '@ethersproject/abstract-provider': 5.7.0 @@ -742,7 +796,7 @@ packages: - bufferutil - utf-8-validate - /@ethersproject/providers/5.7.1: + /@ethersproject/providers@5.7.1: resolution: {integrity: sha512-vZveG/DLyo+wk4Ga1yx6jSEHrLPgmTt+dFv0dv8URpVCRf0jVhalps1jq/emN/oXnMRsC7cQgAF32DcXLL7BPQ==} dependencies: '@ethersproject/abstract-provider': 5.7.0 @@ -770,51 +824,51 @@ packages: - utf-8-validate dev: false - /@ethersproject/random/5.6.0: + /@ethersproject/random@5.6.0: resolution: {integrity: sha512-si0PLcLjq+NG/XHSZz90asNf+YfKEqJGVdxoEkSukzbnBgC8rydbgbUgBbBGLeHN4kAJwUFEKsu3sCXT93YMsw==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/random/5.6.1: + /@ethersproject/random@5.6.1: resolution: {integrity: sha512-/wtPNHwbmng+5yi3fkipA8YBT59DdkGRoC2vWk09Dci/q5DlgnMkhIycjHlavrvrjJBkFjO/ueLyT+aUDfc4lA==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/random/5.7.0: + /@ethersproject/random@5.7.0: resolution: {integrity: sha512-19WjScqRA8IIeWclFme75VMXSBvi4e6InrUNuaR4s5pTF2qNhcGdCUwdxUVGtDDqC00sDLCO93jPQoDUH4HVmQ==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/rlp/5.6.0: + /@ethersproject/rlp@5.6.0: resolution: {integrity: sha512-dz9WR1xpcTL+9DtOT/aDO+YyxSSdO8YIS0jyZwHHSlAmnxA6cKU3TrTd4Xc/bHayctxTgGLYNuVVoiXE4tTq1g==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/rlp/5.7.0: + /@ethersproject/rlp@5.7.0: resolution: {integrity: sha512-rBxzX2vK8mVF7b0Tol44t5Tb8gomOHkj5guL+HhzQ1yBh/ydjGnpw6at+X6Iw0Kp3OzzzkcKp8N9r0W4kYSs9w==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/sha2/5.6.0: + /@ethersproject/sha2@5.6.0: resolution: {integrity: sha512-1tNWCPFLu1n3JM9t4/kytz35DkuF9MxqkGGEHNauEbaARdm2fafnOyw1s0tIQDPKF/7bkP1u3dbrmjpn5CelyA==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 hash.js: 1.1.7 - /@ethersproject/sha2/5.7.0: + /@ethersproject/sha2@5.7.0: resolution: {integrity: sha512-gKlH42riwb3KYp0reLsFTokByAKoJdgFCwI+CCiX/k+Jm2mbNs6oOaCjYQSlI1+XBVejwH2KrmCbMAT/GnRDQw==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/logger': 5.0.6 hash.js: 1.1.7 - /@ethersproject/signing-key/5.6.0: + /@ethersproject/signing-key@5.6.0: resolution: {integrity: sha512-S+njkhowmLeUu/r7ir8n78OUKx63kBdMCPssePS89So1TH4hZqnWFsThEd/GiXYp9qMxVrydf7KdM9MTGPFukA==} dependencies: '@ethersproject/bytes': 5.7.0 @@ -824,7 +878,7 @@ packages: elliptic: 6.5.4 hash.js: 1.1.7 - /@ethersproject/signing-key/5.7.0: + /@ethersproject/signing-key@5.7.0: resolution: {integrity: sha512-MZdy2nL3wO0u7gkB4nA/pEf8lu1TlFswPNmy8AiYkfKTdO6eXBJyUdmHO/ehm/htHw9K/qF8ujnTyUAD+Ry54Q==} dependencies: '@ethersproject/bytes': 5.7.0 @@ -834,7 +888,7 @@ packages: elliptic: 6.5.4 hash.js: 1.1.7 - /@ethersproject/solidity/5.6.0: + /@ethersproject/solidity@5.6.0: resolution: {integrity: sha512-YwF52vTNd50kjDzqKaoNNbC/r9kMDPq3YzDWmsjFTRBcIF1y4JCQJ8gB30wsTfHbaxgxelI5BfxQSxD/PbJOww==} dependencies: '@ethersproject/bignumber': 5.7.0 @@ -844,21 +898,21 @@ packages: '@ethersproject/sha2': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/strings/5.6.0: + /@ethersproject/strings@5.6.0: resolution: {integrity: sha512-uv10vTtLTZqrJuqBZR862ZQjTIa724wGPWQqZrofaPI/kUsf53TBG0I0D+hQ1qyNtllbNzaW+PDPHHUI6/65Mg==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/constants': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/strings/5.7.0: + /@ethersproject/strings@5.7.0: resolution: {integrity: sha512-/9nu+lj0YswRNSH0NXYqrh8775XNyEdUQAuf3f+SmOrnVewcJ5SBNAjF7lpgehKi4abvNNXyf+HX86czCdJ8Mg==} dependencies: '@ethersproject/bytes': 5.7.0 '@ethersproject/constants': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/transactions/5.6.0: + /@ethersproject/transactions@5.6.0: resolution: {integrity: sha512-4HX+VOhNjXHZyGzER6E/LVI2i6lf9ejYeWD6l4g50AdmimyuStKc39kvKf1bXWQMg7QNVh+uC7dYwtaZ02IXeg==} dependencies: '@ethersproject/address': 5.7.0 @@ -871,7 +925,7 @@ packages: '@ethersproject/rlp': 5.7.0 '@ethersproject/signing-key': 5.7.0 - /@ethersproject/transactions/5.7.0: + /@ethersproject/transactions@5.7.0: resolution: {integrity: sha512-kmcNicCp1lp8qanMTC3RIikGgoJ80ztTyvtsFvCYpSCfkjhD0jZ2LOrnbcuxuToLIUYYf+4XwD1rP+B/erDIhQ==} dependencies: '@ethersproject/address': 5.7.0 @@ -884,14 +938,14 @@ packages: '@ethersproject/rlp': 5.7.0 '@ethersproject/signing-key': 5.7.0 - /@ethersproject/units/5.6.0: + /@ethersproject/units@5.6.0: resolution: {integrity: sha512-tig9x0Qmh8qbo1w8/6tmtyrm/QQRviBh389EQ+d8fP4wDsBrJBf08oZfoiz1/uenKK9M78yAP4PoR7SsVoTjsw==} dependencies: '@ethersproject/bignumber': 5.7.0 '@ethersproject/constants': 5.7.0 '@ethersproject/logger': 5.0.6 - /@ethersproject/wallet/5.6.0: + /@ethersproject/wallet@5.6.0: resolution: {integrity: sha512-qMlSdOSTyp0MBeE+r7SUhr1jjDlC1zAXB8VD84hCnpijPQiSNbxr6GdiLXxpUs8UKzkDiNYYC5DRI3MZr+n+tg==} dependencies: '@ethersproject/abstract-provider': 5.7.0 @@ -910,7 +964,7 @@ packages: '@ethersproject/transactions': 5.7.0 '@ethersproject/wordlists': 5.7.0 - /@ethersproject/web/5.6.0: + /@ethersproject/web@5.6.0: resolution: {integrity: sha512-G/XHj0hV1FxI2teHRfCGvfBUHFmU+YOSbCxlAMqJklxSa7QMiHFQfAxvwY2PFqgvdkxEKwRNr/eCjfAPEm2Ctg==} dependencies: '@ethersproject/base64': 5.7.0 @@ -919,7 +973,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/web/5.7.1: + /@ethersproject/web@5.7.1: resolution: {integrity: sha512-Gueu8lSvyjBWL4cYsWsjh6MtMwM0+H4HvqFPZfB6dV8ctbP9zFAO73VG1cMWae0FLPCtz0peKPpZY8/ugJJX2w==} dependencies: '@ethersproject/base64': 5.7.0 @@ -928,7 +982,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/wordlists/5.6.0: + /@ethersproject/wordlists@5.6.0: resolution: {integrity: sha512-q0bxNBfIX3fUuAo9OmjlEYxP40IB8ABgb7HjEZCL5IKubzV3j30CWi2rqQbjTS2HfoyQbfINoKcTVWP4ejwR7Q==} dependencies: '@ethersproject/bytes': 5.7.0 @@ -937,7 +991,7 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@ethersproject/wordlists/5.7.0: + /@ethersproject/wordlists@5.7.0: resolution: {integrity: sha512-S2TFNJNfHWVHNE6cNDjbVlZ6MgE17MIxMbMg2zv3wn+3XSJGosL1m9ZVv3GXCf/2ymSsQ+hRI5IzoMJTG6aoVA==} dependencies: '@ethersproject/bytes': 5.7.0 @@ -946,27 +1000,27 @@ packages: '@ethersproject/properties': 5.7.0 '@ethersproject/strings': 5.7.0 - /@humanwhocodes/config-array/0.11.10: + /@humanwhocodes/config-array@0.11.10: resolution: {integrity: sha512-KVVjQmNUepDVGXNuoRRdmmEjruj0KfiGSbS8LVc12LMsWDQzRXJ0qdhN8L8uUigKpfEHRhlaQFY0ib1tnUbNeQ==} engines: {node: '>=10.10.0'} dependencies: '@humanwhocodes/object-schema': 1.2.1 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) minimatch: 3.1.2 transitivePeerDependencies: - supports-color dev: true - /@humanwhocodes/module-importer/1.0.1: + /@humanwhocodes/module-importer@1.0.1: resolution: {integrity: sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==} engines: {node: '>=12.22'} dev: true - /@humanwhocodes/object-schema/1.2.1: + /@humanwhocodes/object-schema@1.2.1: resolution: {integrity: sha512-ZnQMnLV4e7hDlUvw8H+U8ASL02SS2Gn6+9Ac3wGGLIe7+je2AeAOxPY+izIPJDfFDb7eDjev0Us8MO1iFRN8hA==} dev: true - /@metamask/eth-sig-util/4.0.1: + /@metamask/eth-sig-util@4.0.1: resolution: {integrity: sha512-tghyZKLHZjcdlDqCA3gNZmLeR0XvOE9U1qoQO9ohyAZT6Pya+H9vkBPcsyXytmYLNgVoin7CKCmweo/R43V+tQ==} engines: {node: '>=12.0.0'} dependencies: @@ -977,15 +1031,15 @@ packages: tweetnacl-util: 0.15.1 dev: true - /@noble/hashes/1.1.2: + /@noble/hashes@1.1.2: resolution: {integrity: sha512-KYRCASVTv6aeUi1tsF8/vpyR7zpfs3FUzy2Jqm+MU+LmUKhQ0y2FpfwqkCcxSg2ua4GALJd8k2R76WxwZGbQpA==} dev: true - /@noble/secp256k1/1.6.3: + /@noble/secp256k1@1.6.3: resolution: {integrity: sha512-T04e4iTurVy7I8Sw4+c5OSN9/RkPlo1uKxAomtxQNLq8j1uPAqnsqG1bqvY3Jv7c13gyr6dui0zmh/I3+f/JaQ==} dev: true - /@nodelib/fs.scandir/2.1.5: + /@nodelib/fs.scandir@2.1.5: resolution: {integrity: sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==} engines: {node: '>= 8'} dependencies: @@ -993,12 +1047,12 @@ packages: run-parallel: 1.1.9 dev: true - /@nodelib/fs.stat/2.0.5: + /@nodelib/fs.stat@2.0.5: resolution: {integrity: sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==} engines: {node: '>= 8'} dev: true - /@nodelib/fs.walk/1.2.8: + /@nodelib/fs.walk@1.2.8: resolution: {integrity: sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==} engines: {node: '>= 8'} dependencies: @@ -1006,7 +1060,7 @@ packages: fastq: 1.6.0 dev: true - /@nomicfoundation/ethereumjs-block/4.0.0: + /@nomicfoundation/ethereumjs-block@4.0.0: resolution: {integrity: sha512-bk8uP8VuexLgyIZAHExH1QEovqx0Lzhc9Ntm63nCRKLHXIZkobaFaeCVwTESV7YkPKUk7NiK11s8ryed4CS9yA==} engines: {node: '>=14'} dependencies: @@ -1018,7 +1072,7 @@ packages: ethereum-cryptography: 0.1.3 dev: true - /@nomicfoundation/ethereumjs-blockchain/6.0.0: + /@nomicfoundation/ethereumjs-blockchain@6.0.0: resolution: {integrity: sha512-pLFEoea6MWd81QQYSReLlLfH7N9v7lH66JC/NMPN848ySPPQA5renWnE7wPByfQFzNrPBuDDRFFULMDmj1C0xw==} engines: {node: '>=14'} dependencies: @@ -1029,7 +1083,7 @@ packages: '@nomicfoundation/ethereumjs-trie': 5.0.0 '@nomicfoundation/ethereumjs-util': 8.0.0 abstract-level: 1.0.3 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethereum-cryptography: 0.1.3 level: 8.0.0 lru-cache: 5.1.1 @@ -1038,14 +1092,14 @@ packages: - supports-color dev: true - /@nomicfoundation/ethereumjs-common/3.0.0: + /@nomicfoundation/ethereumjs-common@3.0.0: resolution: {integrity: sha512-WS7qSshQfxoZOpHG/XqlHEGRG1zmyjYrvmATvc4c62+gZXgre1ymYP8ZNgx/3FyZY0TWe9OjFlKOfLqmgOeYwA==} dependencies: '@nomicfoundation/ethereumjs-util': 8.0.0 crc-32: 1.2.2 dev: true - /@nomicfoundation/ethereumjs-ethash/2.0.0: + /@nomicfoundation/ethereumjs-ethash@2.0.0: resolution: {integrity: sha512-WpDvnRncfDUuXdsAXlI4lXbqUDOA+adYRQaEezIkxqDkc+LDyYDbd/xairmY98GnQzo1zIqsIL6GB5MoMSJDew==} engines: {node: '>=14'} dependencies: @@ -1057,7 +1111,7 @@ packages: ethereum-cryptography: 0.1.3 dev: true - /@nomicfoundation/ethereumjs-evm/1.0.0: + /@nomicfoundation/ethereumjs-evm@1.0.0: resolution: {integrity: sha512-hVS6qRo3V1PLKCO210UfcEQHvlG7GqR8iFzp0yyjTg2TmJQizcChKgWo8KFsdMw6AyoLgLhHGHw4HdlP8a4i+Q==} engines: {node: '>=14'} dependencies: @@ -1065,7 +1119,7 @@ packages: '@nomicfoundation/ethereumjs-util': 8.0.0 '@types/async-eventemitter': 0.2.1 async-eventemitter: 0.2.4 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethereum-cryptography: 0.1.3 mcl-wasm: 0.7.9 rustbn.js: 0.2.0 @@ -1073,27 +1127,27 @@ packages: - supports-color dev: true - /@nomicfoundation/ethereumjs-rlp/4.0.0: + /@nomicfoundation/ethereumjs-rlp@4.0.0: resolution: {integrity: sha512-GaSOGk5QbUk4eBP5qFbpXoZoZUj/NrW7MRa0tKY4Ew4c2HAS0GXArEMAamtFrkazp0BO4K5p2ZCG3b2FmbShmw==} engines: {node: '>=14'} hasBin: true dev: true - /@nomicfoundation/ethereumjs-statemanager/1.0.0: + /@nomicfoundation/ethereumjs-statemanager@1.0.0: resolution: {integrity: sha512-jCtqFjcd2QejtuAMjQzbil/4NHf5aAWxUc+CvS0JclQpl+7M0bxMofR2AJdtz+P3u0ke2euhYREDiE7iSO31vQ==} dependencies: '@nomicfoundation/ethereumjs-common': 3.0.0 '@nomicfoundation/ethereumjs-rlp': 4.0.0 '@nomicfoundation/ethereumjs-trie': 5.0.0 '@nomicfoundation/ethereumjs-util': 8.0.0 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethereum-cryptography: 0.1.3 functional-red-black-tree: 1.0.1 transitivePeerDependencies: - supports-color dev: true - /@nomicfoundation/ethereumjs-trie/5.0.0: + /@nomicfoundation/ethereumjs-trie@5.0.0: resolution: {integrity: sha512-LIj5XdE+s+t6WSuq/ttegJzZ1vliwg6wlb+Y9f4RlBpuK35B9K02bO7xU+E6Rgg9RGptkWd6TVLdedTI4eNc2A==} engines: {node: '>=14'} dependencies: @@ -1103,7 +1157,7 @@ packages: readable-stream: 3.6.0 dev: true - /@nomicfoundation/ethereumjs-tx/4.0.0: + /@nomicfoundation/ethereumjs-tx@4.0.0: resolution: {integrity: sha512-Gg3Lir2lNUck43Kp/3x6TfBNwcWC9Z1wYue9Nz3v4xjdcv6oDW9QSMJxqsKw9QEGoBBZ+gqwpW7+F05/rs/g1w==} engines: {node: '>=14'} dependencies: @@ -1113,7 +1167,7 @@ packages: ethereum-cryptography: 0.1.3 dev: true - /@nomicfoundation/ethereumjs-util/8.0.0: + /@nomicfoundation/ethereumjs-util@8.0.0: resolution: {integrity: sha512-2emi0NJ/HmTG+CGY58fa+DQuAoroFeSH9gKu9O6JnwTtlzJtgfTixuoOqLEgyyzZVvwfIpRueuePb8TonL1y+A==} engines: {node: '>=14'} dependencies: @@ -1121,7 +1175,7 @@ packages: ethereum-cryptography: 0.1.3 dev: true - /@nomicfoundation/ethereumjs-vm/6.0.0: + /@nomicfoundation/ethereumjs-vm@6.0.0: resolution: {integrity: sha512-JMPxvPQ3fzD063Sg3Tp+UdwUkVxMoo1uML6KSzFhMH3hoQi/LMuXBoEHAoW83/vyNS9BxEe6jm6LmT5xdeEJ6w==} engines: {node: '>=14'} dependencies: @@ -1136,7 +1190,7 @@ packages: '@nomicfoundation/ethereumjs-util': 8.0.0 '@types/async-eventemitter': 0.2.1 async-eventemitter: 0.2.4 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethereum-cryptography: 0.1.3 functional-red-black-tree: 1.0.1 mcl-wasm: 0.7.9 @@ -1145,16 +1199,16 @@ packages: - supports-color dev: true - /@nomicfoundation/hardhat-network-helpers/1.0.8_hardhat@2.12.7: + /@nomicfoundation/hardhat-network-helpers@1.0.8(hardhat@2.12.7): resolution: {integrity: sha512-MNqQbzUJZnCMIYvlniC3U+kcavz/PhhQSsY90tbEtUyMj/IQqsLwIRZa4ctjABh3Bz0KCh9OXUZ7Yk/d9hr45Q==} peerDependencies: hardhat: ^2.9.5 dependencies: ethereumjs-util: 7.1.5 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) dev: true - /@nomicfoundation/solidity-analyzer-darwin-arm64/0.1.0: + /@nomicfoundation/solidity-analyzer-darwin-arm64@0.1.0: resolution: {integrity: sha512-vEF3yKuuzfMHsZecHQcnkUrqm8mnTWfJeEVFHpg+cO+le96xQA4lAJYdUan8pXZohQxv1fSReQsn4QGNuBNuCw==} engines: {node: '>= 10'} cpu: [arm64] @@ -1163,7 +1217,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-darwin-x64/0.1.0: + /@nomicfoundation/solidity-analyzer-darwin-x64@0.1.0: resolution: {integrity: sha512-dlHeIg0pTL4dB1l9JDwbi/JG6dHQaU1xpDK+ugYO8eJ1kxx9Dh2isEUtA4d02cQAl22cjOHTvifAk96A+ItEHA==} engines: {node: '>= 10'} cpu: [x64] @@ -1172,7 +1226,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-freebsd-x64/0.1.0: + /@nomicfoundation/solidity-analyzer-freebsd-x64@0.1.0: resolution: {integrity: sha512-WFCZYMv86WowDA4GiJKnebMQRt3kCcFqHeIomW6NMyqiKqhK1kIZCxSLDYsxqlx396kKLPN1713Q1S8tu68GKg==} engines: {node: '>= 10'} cpu: [x64] @@ -1181,7 +1235,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-linux-arm64-gnu/0.1.0: + /@nomicfoundation/solidity-analyzer-linux-arm64-gnu@0.1.0: resolution: {integrity: sha512-DTw6MNQWWlCgc71Pq7CEhEqkb7fZnS7oly13pujs4cMH1sR0JzNk90Mp1zpSCsCs4oKan2ClhMlLKtNat/XRKQ==} engines: {node: '>= 10'} cpu: [arm64] @@ -1190,7 +1244,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-linux-arm64-musl/0.1.0: + /@nomicfoundation/solidity-analyzer-linux-arm64-musl@0.1.0: resolution: {integrity: sha512-wUpUnR/3GV5Da88MhrxXh/lhb9kxh9V3Jya2NpBEhKDIRCDmtXMSqPMXHZmOR9DfCwCvG6vLFPr/+YrPCnUN0w==} engines: {node: '>= 10'} cpu: [arm64] @@ -1199,7 +1253,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-linux-x64-gnu/0.1.0: + /@nomicfoundation/solidity-analyzer-linux-x64-gnu@0.1.0: resolution: {integrity: sha512-lR0AxK1x/MeKQ/3Pt923kPvwigmGX3OxeU5qNtQ9pj9iucgk4PzhbS3ruUeSpYhUxG50jN4RkIGwUMoev5lguw==} engines: {node: '>= 10'} cpu: [x64] @@ -1208,7 +1262,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-linux-x64-musl/0.1.0: + /@nomicfoundation/solidity-analyzer-linux-x64-musl@0.1.0: resolution: {integrity: sha512-A1he/8gy/JeBD3FKvmI6WUJrGrI5uWJNr5Xb9WdV+DK0F8msuOqpEByLlnTdLkXMwW7nSl3awvLezOs9xBHJEg==} engines: {node: '>= 10'} cpu: [x64] @@ -1217,7 +1271,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-win32-arm64-msvc/0.1.0: + /@nomicfoundation/solidity-analyzer-win32-arm64-msvc@0.1.0: resolution: {integrity: sha512-7x5SXZ9R9H4SluJZZP8XPN+ju7Mx+XeUMWZw7ZAqkdhP5mK19I4vz3x0zIWygmfE8RT7uQ5xMap0/9NPsO+ykw==} engines: {node: '>= 10'} cpu: [arm64] @@ -1226,7 +1280,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-win32-ia32-msvc/0.1.0: + /@nomicfoundation/solidity-analyzer-win32-ia32-msvc@0.1.0: resolution: {integrity: sha512-m7w3xf+hnE774YRXu+2mGV7RiF3QJtUoiYU61FascCkQhX3QMQavh7saH/vzb2jN5D24nT/jwvaHYX/MAM9zUw==} engines: {node: '>= 10'} cpu: [ia32] @@ -1235,7 +1289,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer-win32-x64-msvc/0.1.0: + /@nomicfoundation/solidity-analyzer-win32-x64-msvc@0.1.0: resolution: {integrity: sha512-xCuybjY0sLJQnJhupiFAXaek2EqF0AP0eBjgzaalPXSNvCEN6ZYHvUzdA50ENDVeSYFXcUsYf3+FsD3XKaeptA==} engines: {node: '>= 10'} cpu: [x64] @@ -1244,7 +1298,7 @@ packages: dev: true optional: true - /@nomicfoundation/solidity-analyzer/0.1.0: + /@nomicfoundation/solidity-analyzer@0.1.0: resolution: {integrity: sha512-xGWAiVCGOycvGiP/qrlf9f9eOn7fpNbyJygcB0P21a1MDuVPlKt0Srp7rvtBEutYQ48ouYnRXm33zlRnlTOPHg==} engines: {node: '>= 12'} optionalDependencies: @@ -1260,17 +1314,17 @@ packages: '@nomicfoundation/solidity-analyzer-win32-x64-msvc': 0.1.0 dev: true - /@nomiclabs/hardhat-ethers/2.0.2_z6fcyyhc2nf3iwqkyspxr4tlaq: + /@nomiclabs/hardhat-ethers@2.0.2(ethers@5.6.1)(hardhat@2.12.7): resolution: {integrity: sha512-6quxWe8wwS4X5v3Au8q1jOvXYEPkS1Fh+cME5u6AwNdnI4uERvPlVjlgRWzpnb+Rrt1l/cEqiNRH9GlsBMSDQg==} peerDependencies: ethers: ^5.0.0 hardhat: ^2.0.0 dependencies: ethers: 5.6.1 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) dev: true - /@nomiclabs/hardhat-etherscan/3.1.0_hardhat@2.12.7: + /@nomiclabs/hardhat-etherscan@3.1.0(hardhat@2.12.7): resolution: {integrity: sha512-JroYgfN1AlYFkQTQ3nRwFi4o8NtZF7K/qFR2dxDUgHbCtIagkUseca9L4E/D2ScUm4XT40+8PbCdqZi+XmHyQA==} peerDependencies: hardhat: ^2.0.4 @@ -1279,9 +1333,9 @@ packages: '@ethersproject/address': 5.7.0 cbor: 5.2.0 chalk: 2.4.2 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) fs-extra: 7.0.1 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) lodash: 4.17.21 semver: 6.3.0 table: 6.8.0 @@ -1290,7 +1344,7 @@ packages: - supports-color dev: true - /@nomiclabs/hardhat-waffle/2.0.1_d7ejcwiim3eoh3awwn3s5bqjfe: + /@nomiclabs/hardhat-waffle@2.0.1(@nomiclabs/hardhat-ethers@2.0.2)(ethereum-waffle@3.3.0)(ethers@5.6.1)(hardhat@2.12.7): resolution: {integrity: sha512-2YR2V5zTiztSH9n8BYWgtv3Q+EL0N5Ltm1PAr5z20uAY4SkkfylJ98CIqt18XFvxTD5x4K2wKBzddjV9ViDAZQ==} peerDependencies: '@nomiclabs/hardhat-ethers': ^2.0.0 @@ -1298,34 +1352,34 @@ packages: ethers: ^5.0.0 hardhat: ^2.0.0 dependencies: - '@nomiclabs/hardhat-ethers': 2.0.2_z6fcyyhc2nf3iwqkyspxr4tlaq + '@nomiclabs/hardhat-ethers': 2.0.2(ethers@5.6.1)(hardhat@2.12.7) '@types/sinon-chai': 3.2.8 '@types/web3': 1.0.19 - ethereum-waffle: 3.3.0_typescript@4.9.5 + ethereum-waffle: 3.3.0(typescript@4.9.5) ethers: 5.6.1 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) dev: true - /@openzeppelin/contract-loader/0.6.3: + /@openzeppelin/contract-loader@0.6.3: resolution: {integrity: sha512-cOFIjBjwbGgZhDZsitNgJl0Ye1rd5yu/Yx5LMgeq3u0ZYzldm4uObzHDFq4gjDdoypvyORjjJa3BlFA7eAnVIg==} dependencies: find-up: 4.1.0 fs-extra: 8.1.0 dev: true - /@openzeppelin/contracts-upgradeable/4.7.3: + /@openzeppelin/contracts-upgradeable@4.7.3: resolution: {integrity: sha512-+wuegAMaLcZnLCJIvrVUDzA9z/Wp93f0Dla/4jJvIhijRrPabjQbZe6fWiECLaJyfn5ci9fqf9vTw3xpQOad2A==} dev: false - /@openzeppelin/contracts/3.4.2: + /@openzeppelin/contracts@3.4.2: resolution: {integrity: sha512-z0zMCjyhhp4y7XKAcDAi3Vgms4T2PstwBdahiO0+9NaGICQKjynK3wduSRplTgk4LXmoO1yfDGO5RbjKYxtuxA==} dev: false - /@openzeppelin/contracts/4.3.3: + /@openzeppelin/contracts@4.3.3: resolution: {integrity: sha512-tDBopO1c98Yk7Cv/PZlHqrvtVjlgK5R4J6jxLwoO7qxK4xqOiZG+zSkIvGFpPZ0ikc3QOED3plgdqjgNTnBc7g==} dev: false - /@openzeppelin/hardhat-upgrades/1.22.1_t427xxny5pzfvmqb7mxuxbqor4: + /@openzeppelin/hardhat-upgrades@1.22.1(@nomiclabs/hardhat-ethers@2.0.2)(@nomiclabs/hardhat-etherscan@3.1.0)(ethers@5.6.1)(hardhat@2.12.7): resolution: {integrity: sha512-MdoitCTLl4zwMU8MeE/bCj+7JMWBEvd38XqJkw36PkJrXlbv6FedDVCPoumMAhpmtymm0nTwTYYklYG+L6WiiQ==} hasBin: true peerDependencies: @@ -1338,26 +1392,26 @@ packages: '@nomiclabs/harhdat-etherscan': optional: true dependencies: - '@nomiclabs/hardhat-ethers': 2.0.2_z6fcyyhc2nf3iwqkyspxr4tlaq - '@nomiclabs/hardhat-etherscan': 3.1.0_hardhat@2.12.7 + '@nomiclabs/hardhat-ethers': 2.0.2(ethers@5.6.1)(hardhat@2.12.7) + '@nomiclabs/hardhat-etherscan': 3.1.0(hardhat@2.12.7) '@openzeppelin/upgrades-core': 1.22.0 chalk: 4.1.2 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethers: 5.6.1 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) proper-lockfile: 4.1.2 transitivePeerDependencies: - supports-color dev: true - /@openzeppelin/test-helpers/0.5.11_bn.js@4.12.0: + /@openzeppelin/test-helpers@0.5.11(bn.js@4.12.0): resolution: {integrity: sha512-HkFpCjtTD8dk+wdYhsT07YbMGCE+Z4Wp5sBKXvPDF3Lynoc0H2KqZgCWV+qr2YZ0WW1oX/sXkKFrrKJ0caBTjw==} dependencies: '@openzeppelin/contract-loader': 0.6.3 '@truffle/contract': 4.6.2 ansi-colors: 3.2.4 chai: 4.3.6 - chai-bn: 0.2.2_bn.js@4.12.0+chai@4.3.6 + chai-bn: 0.2.2(bn.js@4.12.0)(chai@4.3.6) ethjs-abi: 0.2.1 lodash.flatten: 4.4.0 semver: 5.7.1 @@ -1371,13 +1425,13 @@ packages: - utf-8-validate dev: true - /@openzeppelin/upgrades-core/1.22.0: + /@openzeppelin/upgrades-core@1.22.0: resolution: {integrity: sha512-TcTabzRbYOzWJnwiToj0LRzje25d9QbDPe2dOT9eHlLDRhOMiep39FDibJjkYd5IdF3s8M9IcK+YSnf49renEg==} dependencies: cbor: 8.1.0 chalk: 4.1.2 compare-versions: 5.0.3 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethereumjs-util: 7.1.5 proper-lockfile: 4.1.2 solidity-ast: 0.4.45 @@ -1385,7 +1439,7 @@ packages: - supports-color dev: true - /@resolver-engine/core/0.3.3: + /@resolver-engine/core@0.3.3: resolution: {integrity: sha512-eB8nEbKDJJBi5p5SrvrvILn4a0h42bKtbCTri3ZxCGt6UvoQyp7HnGOfki944bUjBSHKK3RvgfViHn+kqdXtnQ==} dependencies: debug: 3.2.7 @@ -1395,7 +1449,7 @@ packages: - supports-color dev: true - /@resolver-engine/fs/0.3.3: + /@resolver-engine/fs@0.3.3: resolution: {integrity: sha512-wQ9RhPUcny02Wm0IuJwYMyAG8fXVeKdmhm8xizNByD4ryZlx6PP6kRen+t/haF43cMfmaV7T3Cx6ChOdHEhFUQ==} dependencies: '@resolver-engine/core': 0.3.3 @@ -1404,7 +1458,7 @@ packages: - supports-color dev: true - /@resolver-engine/imports-fs/0.3.3: + /@resolver-engine/imports-fs@0.3.3: resolution: {integrity: sha512-7Pjg/ZAZtxpeyCFlZR5zqYkz+Wdo84ugB5LApwriT8XFeQoLwGUj4tZFFvvCuxaNCcqZzCYbonJgmGObYBzyCA==} dependencies: '@resolver-engine/fs': 0.3.3 @@ -1414,7 +1468,7 @@ packages: - supports-color dev: true - /@resolver-engine/imports/0.3.3: + /@resolver-engine/imports@0.3.3: resolution: {integrity: sha512-anHpS4wN4sRMwsAbMXhMfOD/y4a4Oo0Cw/5+rue7hSwGWsDOQaAU1ClK1OxjUC35/peazxEl8JaSRRS+Xb8t3Q==} dependencies: '@resolver-engine/core': 0.3.3 @@ -1426,11 +1480,11 @@ packages: - supports-color dev: true - /@scure/base/1.1.1: + /@scure/base@1.1.1: resolution: {integrity: sha512-ZxOhsSyxYwLJj3pLZCefNitxsj093tb2vq90mp2txoYeBqbcjDjqFhyM8eUjq/uFm6zJ+mUuqxlS2FkuSY1MTA==} dev: true - /@scure/bip32/1.1.0: + /@scure/bip32@1.1.0: resolution: {integrity: sha512-ftTW3kKX54YXLCxH6BB7oEEoJfoE2pIgw7MINKAs5PsS6nqKPuKk1haTF/EuHmYqG330t5GSrdmtRuHaY1a62Q==} dependencies: '@noble/hashes': 1.1.2 @@ -1438,14 +1492,14 @@ packages: '@scure/base': 1.1.1 dev: true - /@scure/bip39/1.1.0: + /@scure/bip39@1.1.0: resolution: {integrity: sha512-pwrPOS16VeTKg98dYXQyIjJEcWfz7/1YJIwxUEPFfQPtc86Ym/1sVgQ2RLoD43AazMk2l/unK4ITySSpW2+82w==} dependencies: '@noble/hashes': 1.1.2 '@scure/base': 1.1.1 dev: true - /@sentry/core/5.30.0: + /@sentry/core@5.30.0: resolution: {integrity: sha512-TmfrII8w1PQZSZgPpUESqjB+jC6MvZJZdLtE/0hZ+SrnKhW3x5WlYLvTXZpcWePYBku7rl2wn1RZu6uT0qCTeg==} engines: {node: '>=6'} dependencies: @@ -1456,7 +1510,7 @@ packages: tslib: 1.14.1 dev: true - /@sentry/hub/5.30.0: + /@sentry/hub@5.30.0: resolution: {integrity: sha512-2tYrGnzb1gKz2EkMDQcfLrDTvmGcQPuWxLnJKXJvYTQDGLlEvi2tWz1VIHjunmOvJrB5aIQLhm+dcMRwFZDCqQ==} engines: {node: '>=6'} dependencies: @@ -1465,7 +1519,7 @@ packages: tslib: 1.14.1 dev: true - /@sentry/minimal/5.30.0: + /@sentry/minimal@5.30.0: resolution: {integrity: sha512-BwWb/owZKtkDX+Sc4zCSTNcvZUq7YcH3uAVlmh/gtR9rmUvbzAA3ewLuB3myi4wWRAMEtny6+J/FN/x+2wn9Xw==} engines: {node: '>=6'} dependencies: @@ -1474,7 +1528,7 @@ packages: tslib: 1.14.1 dev: true - /@sentry/node/5.30.0: + /@sentry/node@5.30.0: resolution: {integrity: sha512-Br5oyVBF0fZo6ZS9bxbJZG4ApAjRqAnqFFurMVJJdunNb80brh7a5Qva2kjhm+U6r9NJAB5OmDyPkA1Qnt+QVg==} engines: {node: '>=6'} dependencies: @@ -1491,7 +1545,7 @@ packages: - supports-color dev: true - /@sentry/tracing/5.30.0: + /@sentry/tracing@5.30.0: resolution: {integrity: sha512-dUFowCr0AIMwiLD7Fs314Mdzcug+gBVo/+NCMyDw8tFxJkwWAKl7Qa2OZxLQ0ZHjakcj1hNKfCQJ9rhyfOl4Aw==} engines: {node: '>=6'} dependencies: @@ -1502,12 +1556,12 @@ packages: tslib: 1.14.1 dev: true - /@sentry/types/5.30.0: + /@sentry/types@5.30.0: resolution: {integrity: sha512-R8xOqlSTZ+htqrfteCWU5Nk0CDN5ApUTvrlvBuiH1DyP6czDZ4ktbZB0hAgBlVcK0U+qpD3ag3Tqqpa5Q67rPw==} engines: {node: '>=6'} dev: true - /@sentry/utils/5.30.0: + /@sentry/utils@5.30.0: resolution: {integrity: sha512-zaYmoH0NWWtvnJjC9/CBseXMtKHm/tm40sz3YfJRxeQjyzRqNQPgivpd9R/oDJCYj999mzdW382p/qi2ypjLww==} engines: {node: '>=6'} dependencies: @@ -1515,43 +1569,43 @@ packages: tslib: 1.14.1 dev: true - /@sindresorhus/is/0.14.0: + /@sindresorhus/is@0.14.0: resolution: {integrity: sha512-9NET910DNaIPngYnLLPeg+Ogzqsi9uM4mSboU5y6p8S5DzMTVEsJZrawi+BoDNUVBa2DhJqQYUFvMDfgU062LQ==} engines: {node: '>=6'} dev: true - /@sindresorhus/is/4.6.0: + /@sindresorhus/is@4.6.0: resolution: {integrity: sha512-t09vSN3MdfsyCHoFcTRCH/iUtG7OJ0CsjzB8cjAmKc/va/kIgeDI/TxsigdncE/4be734m0cvIYwNaV4i2XqAw==} engines: {node: '>=10'} dev: true - /@solidity-parser/parser/0.14.3: + /@solidity-parser/parser@0.14.3: resolution: {integrity: sha512-29g2SZ29HtsqA58pLCtopI1P/cPy5/UAzlcAXO6T/CNJimG6yA8kx4NaseMyJULiC+TEs02Y9/yeHzClqoA0hw==} dependencies: antlr4ts: 0.5.0-alpha.4 dev: true - /@solidity-parser/parser/0.16.0: + /@solidity-parser/parser@0.16.0: resolution: {integrity: sha512-ESipEcHyRHg4Np4SqBCfcXwyxxna1DgFVz69bgpLV8vzl/NP1DtcKsJ4dJZXWQhY/Z4J2LeKBiOkOVZn9ct33Q==} dependencies: antlr4ts: 0.5.0-alpha.4 dev: true - /@szmarczak/http-timer/1.1.2: + /@szmarczak/http-timer@1.1.2: resolution: {integrity: sha512-XIB2XbzHTN6ieIjfIMV9hlVcfPU26s2vafYWQcZHWXHOxiaRZYEDKEwdl129Zyg50+foYV2jCgtrqSA6qNuNSA==} engines: {node: '>=6'} dependencies: defer-to-connect: 1.1.1 dev: true - /@szmarczak/http-timer/5.0.1: + /@szmarczak/http-timer@5.0.1: resolution: {integrity: sha512-+PmQX0PiAYPMeVYe237LJAYvOMYW1j2rH5YROyS3b4CTVJum34HfRvKvAzozHAQG0TnHNdUfY9nCeUyRAs//cw==} engines: {node: '>=14.16'} dependencies: defer-to-connect: 2.0.1 dev: true - /@truffle/abi-utils/0.3.2: + /@truffle/abi-utils@0.3.2: resolution: {integrity: sha512-32queMD64YKL/tmQgSV4Xs073dIaZ9tp7NP1icjwvFSA3Q9yeu7ApYbSbYMsx9H9zWkkVOsfcoJ2kJEieOCzsA==} dependencies: change-case: 3.0.2 @@ -1559,11 +1613,11 @@ packages: web3-utils: 1.7.4 dev: true - /@truffle/blockchain-utils/0.1.4: + /@truffle/blockchain-utils@0.1.4: resolution: {integrity: sha512-HegAo5A8UX9vE8dtceBRgCY207gOb9wj54c8mNOOWHcFpkyJz7kZYGo44As6Imh10/0hD2j7vHQ56Jf+uszJ3A==} dev: true - /@truffle/codec/0.14.5: + /@truffle/codec@0.14.5: resolution: {integrity: sha512-3FCpTJe6o7LGWUfrSdguMpdpH1PTn3u7bIfbj6Cfdzym2OAVSgxTgdlqC1poepbk0xcOVcUW+EsqNwLMqmBiPA==} dependencies: '@truffle/abi-utils': 0.3.2 @@ -1571,7 +1625,7 @@ packages: big.js: 6.2.1 bn.js: 5.2.1 cbor: 5.2.0 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) lodash: 4.17.21 semver: 7.3.7 utf8: 3.0.0 @@ -1580,23 +1634,23 @@ packages: - supports-color dev: true - /@truffle/compile-common/0.8.1: + /@truffle/compile-common@0.8.1: resolution: {integrity: sha512-7mzzG9Cfrn+fDT5Sqi7B6pccvIIV5w/GM8/56YgnjysbDzy5aZ6mv0fe37ZbcznEVQ35NJjBy+lEr/ozOGXwQA==} dependencies: '@truffle/error': 0.1.1 colors: 1.4.0 dev: true - /@truffle/contract-schema/3.4.10: + /@truffle/contract-schema@3.4.10: resolution: {integrity: sha512-BhRNRoRvlj2th6E5RNS0BnS0ZxQe01JJz8I7MjkGqdeXSvrn6qDCAnbmvhNgUv0l5h8w5+gBOQhAJhILf1shdQ==} dependencies: ajv: 6.12.6 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) transitivePeerDependencies: - supports-color dev: true - /@truffle/contract/4.6.2: + /@truffle/contract@4.6.2: resolution: {integrity: sha512-OZZIDmKtHgZS2Q6sCczNe8OfTuMWpRaAo3vwY49LGGs0VXLiwc7nIcCFh+bMg14IRK6vBN4pWE9W9eWSBFy31Q==} dependencies: '@ensdomains/ensjs': 2.1.0 @@ -1606,7 +1660,7 @@ packages: '@truffle/error': 0.1.1 '@truffle/interface-adapter': 0.5.22 bignumber.js: 7.2.1 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) ethers: 4.0.49 web3: 1.7.4 web3-core-helpers: 1.7.4 @@ -1619,24 +1673,24 @@ packages: - utf-8-validate dev: true - /@truffle/debug-utils/6.0.35: + /@truffle/debug-utils@6.0.35: resolution: {integrity: sha512-GuLsc+GFEYiUM683GWh4/ol3jkBts5a601detVWu1Xo5/bSL5gxooOjgOTovjA8dimCjkyi/DnK2yHHC+q+g0g==} dependencies: '@truffle/codec': 0.14.5 '@trufflesuite/chromafi': 3.0.0 bn.js: 5.2.1 chalk: 2.4.2 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) highlightjs-solidity: 2.0.5 transitivePeerDependencies: - supports-color dev: true - /@truffle/error/0.1.1: + /@truffle/error@0.1.1: resolution: {integrity: sha512-sE7c9IHIGdbK4YayH4BC8i8qMjoAOeg6nUXUDZZp8wlU21/EMpaG+CLx+KqcIPyR+GSWIW3Dm0PXkr2nlggFDA==} dev: true - /@truffle/interface-adapter/0.5.22: + /@truffle/interface-adapter@0.5.22: resolution: {integrity: sha512-Bgl5Afb1mPVNedI8CJzZQzVIdrZWSXISTBrXPZmppD4Q+6V1RUzlLxiaGGB4gYHOA+U0pBzD8MCcSycPAD9RsA==} dependencies: bn.js: 5.2.1 @@ -1648,7 +1702,7 @@ packages: - utf-8-validate dev: true - /@trufflesuite/chromafi/3.0.0: + /@trufflesuite/chromafi@3.0.0: resolution: {integrity: sha512-oqWcOqn8nT1bwlPPfidfzS55vqcIDdpfzo3HbU9EnUmcSTX+I8z0UyUFI3tZQjByVJulbzxHxUGS3ZJPwK/GPQ==} dependencies: camelcase: 4.1.0 @@ -1661,33 +1715,33 @@ packages: strip-indent: 2.0.0 dev: true - /@tsconfig/node10/1.0.9: + /@tsconfig/node10@1.0.9: resolution: {integrity: sha512-jNsYVVxU8v5g43Erja32laIDHXeoNvFEpX33OK4d6hljo3jDhCBDhx5dhCCTMWUojscpAagGiRkBKxpdl9fxqA==} dev: true - /@tsconfig/node12/1.0.11: + /@tsconfig/node12@1.0.11: resolution: {integrity: sha512-cqefuRsh12pWyGsIoBKJA9luFu3mRxCA+ORZvA4ktLSzIuCUtWVxGIuXigEwO5/ywWFMZ2QEGKWvkZG1zDMTag==} dev: true - /@tsconfig/node14/1.0.3: + /@tsconfig/node14@1.0.3: resolution: {integrity: sha512-ysT8mhdixWK6Hw3i1V2AeRqZ5WfXg1G43mqoYlM2nc6388Fq5jcXyr5mRsqViLx/GJYdoL0bfXD8nmF+Zn/Iow==} dev: true - /@tsconfig/node16/1.0.3: + /@tsconfig/node16@1.0.3: resolution: {integrity: sha512-yOlFc+7UtL/89t2ZhjPvvB/DeAr3r+Dq58IgzsFkOAvVC6NMJXmCGjbptdXdR9qsX7pKcTL+s87FtYREi2dEEQ==} dev: true - /@typechain/ethers-v5/2.0.0_mwhxf3vrorrl5yk6tbvkb5vxk4: + /@typechain/ethers-v5@2.0.0(ethers@5.6.1)(typechain@3.0.0): resolution: {integrity: sha512-0xdCkyGOzdqh4h5JSf+zoWx85IusEjDcPIwNEHP8mrWSnCae4rvrqB+/gtpdNfX7zjlFlZiMeePn2r63EI3Lrw==} peerDependencies: ethers: ^5.0.0 typechain: ^3.0.0 dependencies: ethers: 5.6.1 - typechain: 3.0.0_typescript@4.9.5 + typechain: 3.0.0(typescript@4.9.5) dev: true - /@typechain/ethers-v5/7.2.0_pwtfr6mt5pw2hiixtkqheirqmq: + /@typechain/ethers-v5@7.2.0(@ethersproject/abi@5.6.1)(@ethersproject/bytes@5.7.0)(@ethersproject/providers@5.6.1)(ethers@5.6.1)(typechain@8.2.0)(typescript@4.9.5): resolution: {integrity: sha512-jfcmlTvaaJjng63QsT49MT6R1HFhtO/TBMWbyzPFSzMmVIqb2tL6prnKBs4ZJrSvmgIXWy+ttSjpaxCTq8D/Tw==} peerDependencies: '@ethersproject/abi': ^5.0.0 @@ -1702,12 +1756,12 @@ packages: '@ethersproject/providers': 5.6.1 ethers: 5.6.1 lodash: 4.17.21 - ts-essentials: 7.0.3_typescript@4.9.5 - typechain: 8.2.0_typescript@4.9.5 + ts-essentials: 7.0.3(typescript@4.9.5) + typechain: 8.2.0(typescript@4.9.5) typescript: 4.9.5 dev: true - /@typechain/hardhat/3.1.0_gx5th54lc6trgzrpj7pwublyoa: + /@typechain/hardhat@3.1.0(hardhat@2.12.7)(lodash@4.17.21)(typechain@8.2.0): resolution: {integrity: sha512-C6Be6l+vTpao19PvMH2CB/lhL1TRLkhdPkvQCF/zqkY1e+0iqY2Bb9Jd3PTt6I8QvMm89ZDerrCJC9927ZHmlg==} peerDependencies: hardhat: ^2.0.10 @@ -1715,28 +1769,28 @@ packages: typechain: ^6.0.0 dependencies: fs-extra: 9.1.0 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) lodash: 4.17.21 - typechain: 8.2.0_typescript@4.9.5 + typechain: 8.2.0(typescript@4.9.5) dev: true - /@types/async-eventemitter/0.2.1: + /@types/async-eventemitter@0.2.1: resolution: {integrity: sha512-M2P4Ng26QbAeITiH7w1d7OxtldgfAe0wobpyJzVK/XOb0cUGKU2R4pfAhqcJBXAe2ife5ZOhSv4wk7p+ffURtg==} dev: true - /@types/bn.js/4.11.6: + /@types/bn.js@4.11.6: resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} dependencies: '@types/node': 15.14.9 dev: true - /@types/bn.js/5.1.1: + /@types/bn.js@5.1.1: resolution: {integrity: sha512-qNrYbZqMx0uJAfKnKclPh+dTwK33KfLHYqtyODwd5HnXOjnkhc4qgn3BrK6RWyGZm5+sIFE7Q7Vz6QQtJB7w7g==} dependencies: '@types/node': 15.14.9 dev: true - /@types/cacheable-request/6.0.2: + /@types/cacheable-request@6.0.2: resolution: {integrity: sha512-B3xVo+dlKM6nnKTcmm5ZtY/OL8bOAOd2Olee9M1zft65ox50OzjEHW91sDiU9j6cvW8Ejg1/Qkf4xd2kugApUA==} dependencies: '@types/http-cache-semantics': 4.0.1 @@ -1745,43 +1799,43 @@ packages: '@types/responselike': 1.0.0 dev: true - /@types/cbor/5.0.1: + /@types/cbor@5.0.1: resolution: {integrity: sha512-zVqJy2KzusZPLOgyGJDnOIbu3DxIGGqxYbEwtEEe4Z+la8jwIhOyb+GMrlHafs5tvKruwf8f8qOYP6zTvse/pw==} dependencies: '@types/node': 15.14.9 dev: true - /@types/chai/4.3.3: + /@types/chai@4.3.3: resolution: {integrity: sha512-hC7OMnszpxhZPduX+m+nrx+uFoLkWOMiR4oa/AZF3MuSETYTZmFfJAHqZEM8MVlvfG7BEUcgvtwoCTxBp6hm3g==} dev: true - /@types/concat-stream/1.6.1: + /@types/concat-stream@1.6.1: resolution: {integrity: sha512-eHE4cQPoj6ngxBZMvVf6Hw7Mh4jMW4U9lpGmS5GBPB9RYxlFg+CHaVN7ErNY4W9XfLIEn20b4VDYaIrbq0q4uA==} dependencies: '@types/node': 15.14.9 dev: true - /@types/debug/4.1.7: + /@types/debug@4.1.7: resolution: {integrity: sha512-9AonUzyTjXXhEOa0DnqpzZi6VHlqKMswga9EXjpXnnqxwLtdvPPtlO8evrI5D9S6asFRCQ6v+wpiUKbw+vKqyg==} dependencies: '@types/ms': 0.7.31 dev: true - /@types/deep-equal-in-any-order/1.0.1: + /@types/deep-equal-in-any-order@1.0.1: resolution: {integrity: sha512-hUWUUE53WjKfcCncSmWmNXVNNT+0Iz7gYFnov3zdCXrX3Thxp1Cnmfd5LwWOeCVUV5LhpiFgS05vaAG72doo9w==} dev: true - /@types/events/3.0.0: + /@types/events@3.0.0: resolution: {integrity: sha512-EaObqwIvayI5a8dCzhFrjKzVwKLxjoG9T6Ppd5CEo07LRKfQ8Yokw54r5+Wq7FaBQ+yXRvQAYPrHwya1/UFt9g==} dev: true - /@types/form-data/0.0.33: + /@types/form-data@0.0.33: resolution: {integrity: sha512-8BSvG1kGm83cyJITQMZSulnl6QV8jqAGreJsc5tPu1Jq0vTSOiY/k24Wx82JRpWwZSqrala6sd5rWi6aNXvqcw==} dependencies: '@types/node': 15.14.9 dev: true - /@types/glob/7.1.1: + /@types/glob@7.1.1: resolution: {integrity: sha512-1Bh06cbWJUHMC97acuD6UMG29nMt0Aqz1vF3guLfG+kHHJhy3AyohZFFxYk2f7Q1SQIrNwvncxAE0N/9s70F2w==} dependencies: '@types/events': 3.0.0 @@ -1789,130 +1843,130 @@ packages: '@types/node': 15.14.9 dev: true - /@types/http-cache-semantics/4.0.1: + /@types/http-cache-semantics@4.0.1: resolution: {integrity: sha512-SZs7ekbP8CN0txVG2xVRH6EgKmEm31BOxA07vkFaETzZz1xh+cbt8BcI0slpymvwhx5dlFnQG2rTlPVQn+iRPQ==} dev: true - /@types/json-schema/7.0.11: + /@types/json-schema@7.0.11: resolution: {integrity: sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ==} dev: true - /@types/keyv/3.1.4: + /@types/keyv@3.1.4: resolution: {integrity: sha512-BQ5aZNSCpj7D6K2ksrRCTmKRLEpnPvWDiLPfoGyhZ++8YtiK9d/3DBKPJgry359X/P1PfruyYwvnvwFjuEiEIg==} dependencies: '@types/node': 15.14.9 dev: true - /@types/lru-cache/5.1.1: + /@types/lru-cache@5.1.1: resolution: {integrity: sha512-ssE3Vlrys7sdIzs5LOxCzTVMsU7i9oa/IaW92wF32JFb3CVczqOkru2xspuKczHEbG3nvmPY7IFqVmGGHdNbYw==} dev: true - /@types/minimatch/3.0.3: + /@types/minimatch@3.0.3: resolution: {integrity: sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA==} dev: true - /@types/mkdirp/0.5.2: + /@types/mkdirp@0.5.2: resolution: {integrity: sha512-U5icWpv7YnZYGsN4/cmh3WD2onMY0aJIiTE6+51TwJCttdHvtCYmkBNOobHlXwrJRL0nkH9jH4kD+1FAdMN4Tg==} dependencies: '@types/node': 15.14.9 dev: true - /@types/mocha/8.2.2: + /@types/mocha@8.2.2: resolution: {integrity: sha512-Lwh0lzzqT5Pqh6z61P3c3P5nm6fzQK/MMHl9UKeneAeInVflBSz1O2EkX6gM6xfJd7FBXBY5purtLx7fUiZ7Hw==} dev: true - /@types/ms/0.7.31: + /@types/ms@0.7.31: resolution: {integrity: sha512-iiUgKzV9AuaEkZqkOLDIvlQiL6ltuZd9tGcW3gwpnX8JbuiuhFlEGmmFXEXkN50Cvq7Os88IY2v0dkDqXYWVgA==} dev: true - /@types/node-fetch/2.6.2: + /@types/node-fetch@2.6.2: resolution: {integrity: sha512-DHqhlq5jeESLy19TYhLakJ07kNumXWjcDdxXsLUMJZ6ue8VZJj4kLPQVE/2mdHh3xZziNF1xppu5lwmS53HR+A==} dependencies: '@types/node': 15.14.9 form-data: 3.0.1 dev: true - /@types/node/10.17.60: + /@types/node@10.17.60: resolution: {integrity: sha512-F0KIgDJfy2nA3zMLmWGKxcH2ZVEtCZXHHdOQs2gSaQ27+lNeEfGxzkIw90aXswATX7AZ33tahPbzy6KAfUreVw==} dev: true - /@types/node/12.19.16: + /@types/node@12.19.16: resolution: {integrity: sha512-7xHmXm/QJ7cbK2laF+YYD7gb5MggHIIQwqyjin3bpEGiSuvScMQ5JZZXPvRipi1MwckTQbJZROMns/JxdnIL1Q==} dev: true - /@types/node/15.14.9: + /@types/node@15.14.9: resolution: {integrity: sha512-qjd88DrCxupx/kJD5yQgZdcYKZKSIGBVDIBE1/LTGcNm3d2Np/jxojkdePDdfnBHJc5W7vSMpbJ1aB7p/Py69A==} dev: true - /@types/node/8.10.66: + /@types/node@8.10.66: resolution: {integrity: sha512-tktOkFUA4kXx2hhhrB8bIFb5TbwzS4uOhKEmwiD+NoiL0qtP2OQ9mFldbgD4dV1djrlBYP6eBuQZiWjuHUpqFw==} dev: true - /@types/pbkdf2/3.1.0: + /@types/pbkdf2@3.1.0: resolution: {integrity: sha512-Cf63Rv7jCQ0LaL8tNXmEyqTHuIJxRdlS5vMh1mj5voN4+QFhVZnlZruezqpWYDiJ8UTzhP0VmeLXCmBk66YrMQ==} dependencies: '@types/node': 15.14.9 dev: true - /@types/prettier/2.7.1: + /@types/prettier@2.7.1: resolution: {integrity: sha512-ri0UmynRRvZiiUJdiz38MmIblKK+oH30MztdBVR95dv/Ubw6neWSb8u1XpRb72L4qsZOhz+L+z9JD40SJmfWow==} dev: true - /@types/qs/6.9.7: + /@types/qs@6.9.7: resolution: {integrity: sha512-FGa1F62FT09qcrueBA6qYTrJPVDzah9a+493+o2PCXsesWHIn27G98TsSMs3WPNbZIEj4+VJf6saSFpvD+3Zsw==} dev: true - /@types/resolve/0.0.8: + /@types/resolve@0.0.8: resolution: {integrity: sha512-auApPaJf3NPfe18hSoJkp8EbZzer2ISk7o8mCC3M9he/a04+gbMF97NkpD2S8riMGvm4BMRI59/SZQSaLTKpsQ==} dependencies: '@types/node': 15.14.9 dev: true - /@types/responselike/1.0.0: + /@types/responselike@1.0.0: resolution: {integrity: sha512-85Y2BjiufFzaMIlvJDvTTB8Fxl2xfLo4HgmHzVBz08w4wDePCTjYw66PdrolO0kzli3yam/YCgRufyo1DdQVTA==} dependencies: '@types/node': 15.14.9 dev: true - /@types/secp256k1/4.0.3: + /@types/secp256k1@4.0.3: resolution: {integrity: sha512-Da66lEIFeIz9ltsdMZcpQvmrmmoqrfju8pm1BH8WbYjZSwUgCwXLb9C+9XYogwBITnbsSaMdVPb2ekf7TV+03w==} dependencies: '@types/node': 15.14.9 dev: true - /@types/semver/7.5.0: + /@types/semver@7.5.0: resolution: {integrity: sha512-G8hZ6XJiHnuhQKR7ZmysCeJWE08o8T0AXtk5darsCaTVsYZhhgUrq53jizaR2FvsoeCwJhlmwTjkXBY5Pn/ZHw==} dev: true - /@types/sinon-chai/3.2.8: + /@types/sinon-chai@3.2.8: resolution: {integrity: sha512-d4ImIQbT/rKMG8+AXpmcan5T2/PNeSjrYhvkwet6z0p8kzYtfgA32xzOBlbU0yqJfq+/0Ml805iFoODO0LP5/g==} dependencies: '@types/chai': 4.3.3 '@types/sinon': 10.0.13 dev: true - /@types/sinon/10.0.13: + /@types/sinon@10.0.13: resolution: {integrity: sha512-UVjDqJblVNQYvVNUsj0PuYYw0ELRmgt1Nt5Vk0pT5f16ROGfcKJY8o1HVuMOJOpD727RrGB9EGvoaTQE5tgxZQ==} dependencies: '@types/sinonjs__fake-timers': 8.1.2 dev: true - /@types/sinonjs__fake-timers/8.1.2: + /@types/sinonjs__fake-timers@8.1.2: resolution: {integrity: sha512-9GcLXF0/v3t80caGs5p2rRfkB+a8VBGLJZVih6CNFkx8IZ994wiKKLSRs9nuFwk1HevWs/1mnUmkApGrSGsShA==} dev: true - /@types/underscore/1.11.4: + /@types/underscore@1.11.4: resolution: {integrity: sha512-uO4CD2ELOjw8tasUrAhvnn2W4A0ZECOvMjCivJr4gA9pGgjv+qxKWY9GLTMVEK8ej85BxQOocUyE7hImmSQYcg==} dev: true - /@types/web3/1.0.19: + /@types/web3@1.0.19: resolution: {integrity: sha512-fhZ9DyvDYDwHZUp5/STa9XW2re0E8GxoioYJ4pEUZ13YHpApSagixj7IAdoYH5uAK+UalGq6Ml8LYzmgRA/q+A==} dependencies: '@types/bn.js': 5.1.1 '@types/underscore': 1.11.4 dev: true - /@typescript-eslint/eslint-plugin/5.59.8_loqfnwogukjtmydbmg57mzzpb4: + /@typescript-eslint/eslint-plugin@5.59.8(@typescript-eslint/parser@5.59.8)(eslint@8.42.0)(typescript@4.9.5): resolution: {integrity: sha512-JDMOmhXteJ4WVKOiHXGCoB96ADWg9q7efPWHRViT/f09bA8XOMLAVHHju3l0MkZnG1izaWXYmgvQcUjTRcpShQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1924,23 +1978,23 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.5.1 - '@typescript-eslint/parser': 5.59.8_kigkzfftsmftz3xok324pyvzui + '@typescript-eslint/parser': 5.59.8(eslint@8.42.0)(typescript@4.9.5) '@typescript-eslint/scope-manager': 5.59.8 - '@typescript-eslint/type-utils': 5.59.8_kigkzfftsmftz3xok324pyvzui - '@typescript-eslint/utils': 5.59.8_kigkzfftsmftz3xok324pyvzui - debug: 4.3.4 + '@typescript-eslint/type-utils': 5.59.8(eslint@8.42.0)(typescript@4.9.5) + '@typescript-eslint/utils': 5.59.8(eslint@8.42.0)(typescript@4.9.5) + debug: 4.3.4(supports-color@8.1.1) eslint: 8.42.0 grapheme-splitter: 1.0.4 ignore: 5.2.4 natural-compare-lite: 1.4.0 semver: 7.5.0 - tsutils: 3.21.0_typescript@4.9.5 + tsutils: 3.21.0(typescript@4.9.5) typescript: 4.9.5 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/parser/5.59.8_kigkzfftsmftz3xok324pyvzui: + /@typescript-eslint/parser@5.59.8(eslint@8.42.0)(typescript@4.9.5): resolution: {integrity: sha512-AnR19RjJcpjoeGojmwZtCwBX/RidqDZtzcbG3xHrmz0aHHoOcbWnpDllenRDmDvsV0RQ6+tbb09/kyc+UT9Orw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1952,15 +2006,15 @@ packages: dependencies: '@typescript-eslint/scope-manager': 5.59.8 '@typescript-eslint/types': 5.59.8 - '@typescript-eslint/typescript-estree': 5.59.8_typescript@4.9.5 - debug: 4.3.4 + '@typescript-eslint/typescript-estree': 5.59.8(typescript@4.9.5) + debug: 4.3.4(supports-color@8.1.1) eslint: 8.42.0 typescript: 4.9.5 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/scope-manager/5.59.8: + /@typescript-eslint/scope-manager@5.59.8: resolution: {integrity: sha512-/w08ndCYI8gxGf+9zKf1vtx/16y8MHrZs5/tnjHhMLNSixuNcJavSX4wAiPf4aS5x41Es9YPCn44MIe4cxIlig==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: @@ -1968,7 +2022,7 @@ packages: '@typescript-eslint/visitor-keys': 5.59.8 dev: true - /@typescript-eslint/type-utils/5.59.8_kigkzfftsmftz3xok324pyvzui: + /@typescript-eslint/type-utils@5.59.8(eslint@8.42.0)(typescript@4.9.5): resolution: {integrity: sha512-+5M518uEIHFBy3FnyqZUF3BMP+AXnYn4oyH8RF012+e7/msMY98FhGL5SrN29NQ9xDgvqCgYnsOiKp1VjZ/fpA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -1978,22 +2032,22 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 5.59.8_typescript@4.9.5 - '@typescript-eslint/utils': 5.59.8_kigkzfftsmftz3xok324pyvzui - debug: 4.3.4 + '@typescript-eslint/typescript-estree': 5.59.8(typescript@4.9.5) + '@typescript-eslint/utils': 5.59.8(eslint@8.42.0)(typescript@4.9.5) + debug: 4.3.4(supports-color@8.1.1) eslint: 8.42.0 - tsutils: 3.21.0_typescript@4.9.5 + tsutils: 3.21.0(typescript@4.9.5) typescript: 4.9.5 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/types/5.59.8: + /@typescript-eslint/types@5.59.8: resolution: {integrity: sha512-+uWuOhBTj/L6awoWIg0BlWy0u9TyFpCHrAuQ5bNfxDaZ1Ppb3mx6tUigc74LHcbHpOHuOTOJrBoAnhdHdaea1w==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /@typescript-eslint/typescript-estree/5.59.8_typescript@4.9.5: + /@typescript-eslint/typescript-estree@5.59.8(typescript@4.9.5): resolution: {integrity: sha512-Jy/lPSDJGNow14vYu6IrW790p7HIf/SOV1Bb6lZ7NUkLc2iB2Z9elESmsaUtLw8kVqogSbtLH9tut5GCX1RLDg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: @@ -2004,28 +2058,28 @@ packages: dependencies: '@typescript-eslint/types': 5.59.8 '@typescript-eslint/visitor-keys': 5.59.8 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) globby: 11.1.0 is-glob: 4.0.3 semver: 7.5.0 - tsutils: 3.21.0_typescript@4.9.5 + tsutils: 3.21.0(typescript@4.9.5) typescript: 4.9.5 transitivePeerDependencies: - supports-color dev: true - /@typescript-eslint/utils/5.59.8_kigkzfftsmftz3xok324pyvzui: + /@typescript-eslint/utils@5.59.8(eslint@8.42.0)(typescript@4.9.5): resolution: {integrity: sha512-Tr65630KysnNn9f9G7ROF3w1b5/7f6QVCJ+WK9nhIocWmx9F+TmCAcglF26Vm7z8KCTwoKcNEBZrhlklla3CKg==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} peerDependencies: eslint: ^6.0.0 || ^7.0.0 || ^8.0.0 dependencies: - '@eslint-community/eslint-utils': 4.4.0_eslint@8.42.0 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.42.0) '@types/json-schema': 7.0.11 '@types/semver': 7.5.0 '@typescript-eslint/scope-manager': 5.59.8 '@typescript-eslint/types': 5.59.8 - '@typescript-eslint/typescript-estree': 5.59.8_typescript@4.9.5 + '@typescript-eslint/typescript-estree': 5.59.8(typescript@4.9.5) eslint: 8.42.0 eslint-scope: 5.1.1 semver: 7.5.0 @@ -2034,7 +2088,7 @@ packages: - typescript dev: true - /@typescript-eslint/visitor-keys/5.59.8: + /@typescript-eslint/visitor-keys@5.59.8: resolution: {integrity: sha512-pJhi2ms0x0xgloT7xYabil3SGGlojNNKjK/q6dB3Ey0uJLMjK2UDGJvHieiyJVW/7C3KI+Z4Q3pEHkm4ejA+xQ==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: @@ -2042,48 +2096,48 @@ packages: eslint-visitor-keys: 3.4.1 dev: true - /@yarnpkg/lockfile/1.1.0: + /@yarnpkg/lockfile@1.1.0: resolution: {integrity: sha512-GpSwvyXOcOOlV70vbnzjj4fW5xW/FdUF6nQEt1ENy7m4ZCczi1+/buVUPAqmGfqznsORNFzUMjctTIp8a9tuCQ==} dev: true - /abbrev/1.0.9: + /abbrev@1.0.9: resolution: {integrity: sha512-LEyx4aLEC3x6T0UguF6YILf+ntvmOaWsVfENmIW0E9H09vKlLDGelMjjSm0jkDHALj8A8quZ/HapKNigzwge+Q==} dev: true - /abbrev/1.1.1: + /abbrev@1.1.1: resolution: {integrity: sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==} dev: true - /abi-to-sol/0.6.6: + /abi-to-sol@0.6.6: resolution: {integrity: sha512-PRn81rSpv6NXFPYQSw7ujruqIP6UkwZ/XoFldtiqCX8+2kHVc73xVaUVvdbro06vvBVZiwnxhEIGdI4BRMwGHw==} hasBin: true dependencies: '@truffle/abi-utils': 0.3.2 '@truffle/contract-schema': 3.4.10 ajv: 6.12.6 - better-ajv-errors: 0.8.2_ajv@6.12.6 + better-ajv-errors: 0.8.2(ajv@6.12.6) neodoc: 2.0.2 semver: 7.3.7 source-map-support: 0.5.21 optionalDependencies: prettier: 2.8.8 - prettier-plugin-solidity: 1.1.3_prettier@2.8.8 + prettier-plugin-solidity: 1.1.3(prettier@2.8.8) transitivePeerDependencies: - supports-color dev: true - /abort-controller/3.0.0: + /abort-controller@3.0.0: resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} engines: {node: '>=6.5'} dependencies: event-target-shim: 5.0.1 dev: true - /abortcontroller-polyfill/1.7.3: + /abortcontroller-polyfill@1.7.3: resolution: {integrity: sha512-zetDJxd89y3X99Kvo4qFx8GKlt6GsvN3UcRZHwU6iFA/0KiOmhkTVhe8oRoTBiTVPZu09x3vCra47+w8Yz1+2Q==} dev: true - /abstract-level/1.0.3: + /abstract-level@1.0.3: resolution: {integrity: sha512-t6jv+xHy+VYwc4xqZMn2Pa9DjcdzvzZmQGRjTFc8spIbRGHgBrEKbPq+rYXc7CCo0lxgYvSgKVg9qZAhpVQSjA==} engines: {node: '>=12'} dependencies: @@ -2096,33 +2150,33 @@ packages: queue-microtask: 1.2.3 dev: true - /abstract-leveldown/2.6.3: + /abstract-leveldown@2.6.3: resolution: {integrity: sha512-2++wDf/DYqkPR3o5tbfdhF96EfMApo1GpPfzOsR/ZYXdkSmELlvOOEAl9iKkRsktMPHdGjO4rtkBpf2I7TiTeA==} dependencies: xtend: 4.0.2 dev: true - /abstract-leveldown/2.7.2: + /abstract-leveldown@2.7.2: resolution: {integrity: sha512-+OVvxH2rHVEhWLdbudP6p0+dNMXu8JA1CbhP19T8paTYAcX7oJ4OVjT+ZUVpv7mITxXHqDMej+GdqXBmXkw09w==} dependencies: xtend: 4.0.2 dev: true - /abstract-leveldown/3.0.0: + /abstract-leveldown@3.0.0: resolution: {integrity: sha512-KUWx9UWGQD12zsmLNj64/pndaz4iJh/Pj7nopgkfDG6RlCcbMZvT6+9l7dchK4idog2Is8VdC/PvNbFuFmalIQ==} engines: {node: '>=4'} dependencies: xtend: 4.0.2 dev: true - /abstract-leveldown/5.0.0: + /abstract-leveldown@5.0.0: resolution: {integrity: sha512-5mU5P1gXtsMIXg65/rsYGsi93+MlogXZ9FA8JnwKurHQg64bfXwGYVdVdijNTVNOlAsuIiOwHdvFFD5JqCJQ7A==} engines: {node: '>=6'} dependencies: xtend: 4.0.2 dev: true - /accepts/1.3.7: + /accepts@1.3.7: resolution: {integrity: sha512-Il80Qs2WjYlJIBNzNkK6KYqlVMTbZLXgHx2oT0pU/fjRHyEp+PEfEPY0R3WCwAGVOtauxh1hOxNgIf5bv7dQpA==} engines: {node: '>= 0.6'} dependencies: @@ -2130,7 +2184,7 @@ packages: negotiator: 0.6.2 dev: true - /acorn-jsx/5.3.2_acorn@8.8.0: + /acorn-jsx@5.3.2(acorn@8.8.0): resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==} peerDependencies: acorn: ^6.0.0 || ^7.0.0 || ^8.0.0 @@ -2138,40 +2192,40 @@ packages: acorn: 8.8.0 dev: true - /acorn/8.8.0: + /acorn@8.8.0: resolution: {integrity: sha512-QOxyigPVrpZ2GXT+PFyZTl6TtOFc5egxHIP9IlQ+RbupQuX4RkT/Bee4/kQuC02Xkzg84JcT7oLYtDIQxp+v7w==} engines: {node: '>=0.4.0'} hasBin: true dev: true - /address/1.1.2: + /address@1.1.2: resolution: {integrity: sha512-aT6camzM4xEA54YVJYSqxz1kv4IHnQZRtThJJHhUMRExaU5spC7jX5ugSwTaTgJliIgs4VhZOk7htClvQ/LmRA==} engines: {node: '>= 0.12.0'} dev: true - /adm-zip/0.4.16: + /adm-zip@0.4.16: resolution: {integrity: sha512-TFi4HBKSGfIKsK5YCkKaaFG2m4PEDyViZmEwof3MTIgzimHLto6muaHVpbrljdIvIrFZzEq/p4nafOeLcYegrg==} engines: {node: '>=0.3.0'} dev: true - /aes-js/3.0.0: + /aes-js@3.0.0: resolution: {integrity: sha512-H7wUZRn8WpTq9jocdxQ2c8x2sKo9ZVmzfRE13GiNJXfp7NcKYEdvl3vspKjXox6RIG2VtaRe4JFvxG4rqp2Zuw==} - /aes-js/3.1.2: + /aes-js@3.1.2: resolution: {integrity: sha512-e5pEa2kBnBOgR4Y/p20pskXI74UEz7de8ZGVo58asOtvSVG5YAbJeELPZxOmt+Bnz3rX753YKhfIn4X4l1PPRQ==} dev: true optional: true - /agent-base/6.0.2: + /agent-base@6.0.2: resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} engines: {node: '>= 6.0.0'} dependencies: - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) transitivePeerDependencies: - supports-color dev: true - /aggregate-error/3.1.0: + /aggregate-error@3.1.0: resolution: {integrity: sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==} engines: {node: '>=8'} dependencies: @@ -2179,7 +2233,7 @@ packages: indent-string: 4.0.0 dev: true - /ajv/6.12.6: + /ajv@6.12.6: resolution: {integrity: sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g==} dependencies: fast-deep-equal: 3.1.3 @@ -2188,7 +2242,7 @@ packages: uri-js: 4.4.1 dev: true - /ajv/8.11.0: + /ajv@8.11.0: resolution: {integrity: sha512-wGgprdCvMalC0BztXvitD2hC04YffAvtsUn93JbGXYLAtCUO4xd17mCCZQxUOItiBwZvJScWo8NIvQMQ71rdpg==} dependencies: fast-deep-equal: 3.1.3 @@ -2197,88 +2251,88 @@ packages: uri-js: 4.4.1 dev: true - /amdefine/1.0.1: + /amdefine@1.0.1: resolution: {integrity: sha512-S2Hw0TtNkMJhIabBwIojKL9YHO5T0n5eNqWJ7Lrlel/zDbftQpxpapi8tZs3X1HWa+u+QeydGmzzNU0m09+Rcg==} engines: {node: '>=0.4.2'} dev: true optional: true - /ansi-colors/3.2.3: + /ansi-colors@3.2.3: resolution: {integrity: sha512-LEHHyuhlPY3TmuUYMh2oz89lTShfvgbmzaBcxve9t/9Wuy7Dwf4yoAKcND7KFT1HAQfqZ12qtc+DUrBMeKF9nw==} engines: {node: '>=6'} dev: true - /ansi-colors/3.2.4: + /ansi-colors@3.2.4: resolution: {integrity: sha512-hHUXGagefjN2iRrID63xckIvotOXOojhQKWIPUZ4mNUZ9nLZW+7FMNoE1lOkEhNWYsx/7ysGIuJYCiMAA9FnrA==} engines: {node: '>=6'} dev: true - /ansi-colors/4.1.1: + /ansi-colors@4.1.1: resolution: {integrity: sha512-JoX0apGbHaUJBNl6yF+p6JAFYZ666/hhCGKN5t9QFjbJQKUU/g8MNbFDbvfrgKXvI1QpZplPOnwIo99lX/AAmA==} engines: {node: '>=6'} dev: true - /ansi-colors/4.1.3: + /ansi-colors@4.1.3: resolution: {integrity: sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==} engines: {node: '>=6'} dev: true - /ansi-escapes/4.3.2: + /ansi-escapes@4.3.2: resolution: {integrity: sha512-gKXj5ALrKWQLsYG9jlTRmR/xKluxHV+Z9QEwNIgCfM1/uwPMCuzVVnh5mwTd+OuBZcwSIMbqssNWRm1lE51QaQ==} engines: {node: '>=8'} dependencies: type-fest: 0.21.3 dev: true - /ansi-regex/2.1.1: + /ansi-regex@2.1.1: resolution: {integrity: sha512-TIGnTpdo+E3+pCyAluZvtED5p5wCqLdezCyhPZzKPcxvFplEt4i+W7OONCKgeZFT3+y5NZZfOOS/Bdcanm1MYA==} engines: {node: '>=0.10.0'} dev: true - /ansi-regex/3.0.1: + /ansi-regex@3.0.1: resolution: {integrity: sha512-+O9Jct8wf++lXxxFc4hc8LsjaSq0HFzzL7cVsw8pRDIPdjKD2mT4ytDZlLuSBZ4cLKZFXIrMGO7DbQCtMJJMKw==} engines: {node: '>=4'} dev: true - /ansi-regex/4.1.1: + /ansi-regex@4.1.1: resolution: {integrity: sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==} engines: {node: '>=6'} dev: true - /ansi-regex/5.0.1: + /ansi-regex@5.0.1: resolution: {integrity: sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==} engines: {node: '>=8'} dev: true - /ansi-styles/2.2.1: + /ansi-styles@2.2.1: resolution: {integrity: sha512-kmCevFghRiWM7HB5zTPULl4r9bVFSWjz62MhqizDGUrq2NWuNMQyuv4tHHoKJHs69M/MF64lEcHdYIocrdWQYA==} engines: {node: '>=0.10.0'} dev: true - /ansi-styles/3.2.1: + /ansi-styles@3.2.1: resolution: {integrity: sha512-VT0ZI6kZRdTh8YyJw3SMbYm/u+NqfsAxEpWO0Pf9sq8/e94WxxOpPKx9FR1FlyCtOVDNOQ+8ntlqFxiRc+r5qA==} engines: {node: '>=4'} dependencies: color-convert: 1.9.3 dev: true - /ansi-styles/4.3.0: + /ansi-styles@4.3.0: resolution: {integrity: sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==} engines: {node: '>=8'} dependencies: color-convert: 2.0.1 dev: true - /antlr4/4.13.0: + /antlr4@4.13.0: resolution: {integrity: sha512-zooUbt+UscjnWyOrsuY/tVFL4rwrAGwOivpQmvmUDE22hy/lUA467Rc1rcixyRwcRUIXFYBwv7+dClDSHdmmew==} engines: {node: '>=16'} dev: true - /antlr4ts/0.5.0-alpha.4: + /antlr4ts@0.5.0-alpha.4: resolution: {integrity: sha512-WPQDt1B74OfPv/IMS2ekXAKkTZIHl88uMetg6q3OTqgFxZ/dxDXI0EWLyZid/1Pe6hTftyg5N7gel5wNAGxXyQ==} dev: true - /anymatch/3.1.2: + /anymatch@3.1.2: resolution: {integrity: sha512-P43ePfOAIupkguHUycrc4qJ9kz8ZiuOUijaETwX7THt0Y/GNK7v0aa8rY816xWjZ7rJdA5XdMcpVFTKMq+RvWg==} engines: {node: '>= 8'} dependencies: @@ -2286,83 +2340,83 @@ packages: picomatch: 2.3.1 dev: true - /arg/4.1.3: + /arg@4.1.3: resolution: {integrity: sha512-58S9QDqG0Xx27YwPSt9fJxivjYl432YCwfDMfZ+71RAqUrZef7LrKQZ3LHLOwCS4FLNBplP533Zx895SeOCHvA==} dev: true - /argparse/1.0.10: + /argparse@1.0.10: resolution: {integrity: sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==} dependencies: sprintf-js: 1.0.3 dev: true - /argparse/2.0.1: + /argparse@2.0.1: resolution: {integrity: sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==} dev: true - /arr-diff/4.0.0: + /arr-diff@4.0.0: resolution: {integrity: sha512-YVIQ82gZPGBebQV/a8dar4AitzCQs0jjXwMPZllpXMaGjXPYVUawSxQrRsjhjupyVxEvbHgUmIhKVlND+j02kA==} engines: {node: '>=0.10.0'} dev: true - /arr-flatten/1.1.0: + /arr-flatten@1.1.0: resolution: {integrity: sha512-L3hKV5R/p5o81R7O02IGnwpDmkp6E982XhtbuwSe3O4qOtMMMtodicASA1Cny2U+aCXcNpml+m4dPsvsJ3jatg==} engines: {node: '>=0.10.0'} dev: true - /arr-union/3.1.0: + /arr-union@3.1.0: resolution: {integrity: sha512-sKpyeERZ02v1FeCZT8lrfJq5u6goHCtpTAzPwJYe7c8SPFOboNjNg1vz2L4VTn9T4PQxEx13TbXLmYUcS6Ug7Q==} engines: {node: '>=0.10.0'} dev: true - /array-back/1.0.4: + /array-back@1.0.4: resolution: {integrity: sha512-1WxbZvrmyhkNoeYcizokbmh5oiOCIfyvGtcqbK3Ls1v1fKcquzxnQSceOx6tzq7jmai2kFLWIpGND2cLhH6TPw==} engines: {node: '>=0.12.0'} dependencies: typical: 2.6.1 dev: true - /array-back/2.0.0: + /array-back@2.0.0: resolution: {integrity: sha512-eJv4pLLufP3g5kcZry0j6WXpIbzYw9GUB4mVJZno9wfwiBxbizTnHCw3VJb07cBihbFX48Y7oSrW9y+gt4glyw==} engines: {node: '>=4'} dependencies: typical: 2.6.1 dev: true - /array-back/3.1.0: + /array-back@3.1.0: resolution: {integrity: sha512-TkuxA4UCOvxuDK6NZYXCalszEzj+TLszyASooky+i742l9TqsOdYCMJJupxRic61hwquNtppB3hgcuq9SVSH1Q==} engines: {node: '>=6'} dev: true - /array-back/4.0.2: + /array-back@4.0.2: resolution: {integrity: sha512-NbdMezxqf94cnNfWLL7V/im0Ub+Anbb0IoZhvzie8+4HJ4nMQuzHuy49FkGYCJK2yAloZ3meiB6AVMClbrI1vg==} engines: {node: '>=8'} dev: true - /array-filter/1.0.0: + /array-filter@1.0.0: resolution: {integrity: sha512-Ene1hbrinPZ1qPoZp7NSx4jQnh4nr7MtY78pHNb+yr8yHbxmTS7ChGW0a55JKA7TkRDeoQxK4GcJaCvBYplSKA==} dev: true - /array-flatten/1.1.1: + /array-flatten@1.1.1: resolution: {integrity: sha512-PCVAQswWemu6UdxsDFFX/+gVeYqKAod3D3UVm91jHwynguOwAvYPhx8nNlM++NqRcK6CxxpUafjmhIdKiHibqg==} dev: true - /array-union/2.1.0: + /array-union@2.1.0: resolution: {integrity: sha512-HGyxoOTYUyCM6stUe6EJgnd4EoewAI7zMdfqO+kGjnlZmBDz/cR5pf8r/cR4Wq60sL/p0IkcjUEEPwS3GFrIyw==} engines: {node: '>=8'} dev: true - /array-uniq/1.0.3: + /array-uniq@1.0.3: resolution: {integrity: sha512-MNha4BWQ6JbwhFhj03YK552f7cb3AzoE8SzeljgChvL1dl3IcvggXVz1DilzySZkCja+CXuZbdW7yATchWn8/Q==} engines: {node: '>=0.10.0'} dev: true - /array-unique/0.3.2: + /array-unique@0.3.2: resolution: {integrity: sha512-SleRWjh9JUud2wH1hPs9rZBZ33H6T9HOiL0uwGnGx9FpE6wKGyfWugmbkEOIs6qWrZhg0LWeLziLrEwQJhs5mQ==} engines: {node: '>=0.10.0'} dev: true - /array.prototype.reduce/1.0.4: + /array.prototype.reduce@1.0.4: resolution: {integrity: sha512-WnM+AjG/DvLRLo4DDl+r+SvCzYtD2Jd9oeBYMcEaI7t3fFrHY9M53/wdLcTvmZNQ70IU6Htj0emFkZ5TS+lrdw==} engines: {node: '>= 0.4'} dependencies: @@ -2373,11 +2427,11 @@ packages: is-string: 1.0.7 dev: true - /asap/2.0.6: + /asap@2.0.6: resolution: {integrity: sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA==} dev: true - /asn1.js/4.10.1: + /asn1.js@4.10.1: resolution: {integrity: sha512-p32cOF5q0Zqs9uBiONKYLm6BClCoBCM5O9JfeUSlnQLBTxYdTK+pW+nXflm8UkKd2UYlEbYz5qEi0JuZR9ckSw==} dependencies: bn.js: 4.12.0 @@ -2385,91 +2439,91 @@ packages: minimalistic-assert: 1.0.1 dev: true - /asn1/0.2.4: + /asn1@0.2.4: resolution: {integrity: sha512-jxwzQpLQjSmWXgwaCZE9Nz+glAG01yF1QnWgbhGwHI5A6FRIEY6IVqtHhIepHqI7/kyEyQEagBC5mBEFlIYvdg==} dependencies: safer-buffer: 2.1.2 dev: true - /assert-plus/1.0.0: + /assert-plus@1.0.0: resolution: {integrity: sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw==} engines: {node: '>=0.8'} dev: true - /assertion-error/1.1.0: + /assertion-error@1.1.0: resolution: {integrity: sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw==} - /assign-symbols/1.0.0: + /assign-symbols@1.0.0: resolution: {integrity: sha512-Q+JC7Whu8HhmTdBph/Tq59IoRtoy6KAm5zzPv00WdujX82lbAL8K7WVjne7vdCsAmbF4AYaDOPyO3k0kl8qIrw==} engines: {node: '>=0.10.0'} dev: true - /ast-parents/0.0.1: + /ast-parents@0.0.1: resolution: {integrity: sha512-XHusKxKz3zoYk1ic8Un640joHbFMhbqneyoZfoKnEGtf2ey9Uh/IdpcQplODdO/kENaMIWsD0nJm4+wX3UNLHA==} dev: true - /astral-regex/2.0.0: + /astral-regex@2.0.0: resolution: {integrity: sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==} engines: {node: '>=8'} dev: true - /async-eventemitter/0.2.4: + /async-eventemitter@0.2.4: resolution: {integrity: sha512-pd20BwL7Yt1zwDFy+8MX8F1+WCT8aQeKj0kQnTrH9WaeRETlRamVhD0JtRPmrV4GfOJ2F9CvdQkZeZhnh2TuHw==} dependencies: async: 2.6.3 dev: true - /async-limiter/1.0.1: + /async-limiter@1.0.1: resolution: {integrity: sha512-csOlWGAcRFJaI6m+F2WKdnMKr4HhdhFVBk0H/QbJFMCr+uO2kwohwXQPxw/9OCxp05r5ghVBFSyioixx3gfkNQ==} dev: true - /async/1.5.2: + /async@1.5.2: resolution: {integrity: sha512-nSVgobk4rv61R9PUSDtYt7mPVB2olxNR5RWJcAsH676/ef11bUZwvu7+RGYrYauVdDPcO519v68wRhXQtxsV9w==} dev: true - /async/2.6.2: + /async@2.6.2: resolution: {integrity: sha512-H1qVYh1MYhEEFLsP97cVKqCGo7KfCyTt6uEWqsTBr9SO84oK9Uwbyd/yCW+6rKJLHksBNUVWZDAjfS+Ccx0Bbg==} dependencies: lodash: 4.17.21 dev: true - /async/2.6.3: + /async@2.6.3: resolution: {integrity: sha512-zflvls11DCy+dQWzTW2dzuilv8Z5X/pjfmZOWba6TNIVDm+2UDaJmXSOXlasHKfNBs8oo3M0aT50fDEWfKZjXg==} dependencies: lodash: 4.17.21 dev: true - /asynckit/0.4.0: + /asynckit@0.4.0: resolution: {integrity: sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==} dev: true - /at-least-node/1.0.0: + /at-least-node@1.0.0: resolution: {integrity: sha512-+q/t7Ekv1EDY2l6Gda6LLiX14rU9TV20Wa3ofeQmwPFZbOMo9DXrLbOjFaaclkXKWidIaopwAObQDqwWtGUjqg==} engines: {node: '>= 4.0.0'} dev: true - /atob/2.1.2: + /atob@2.1.2: resolution: {integrity: sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==} engines: {node: '>= 4.5.0'} hasBin: true dev: true - /available-typed-arrays/1.0.2: + /available-typed-arrays@1.0.2: resolution: {integrity: sha512-XWX3OX8Onv97LMk/ftVyBibpGwY5a8SmuxZPzeOxqmuEqUCOM9ZE+uIaD1VNJ5QnvU2UQusvmKbuM1FR8QWGfQ==} engines: {node: '>= 0.4'} dependencies: array-filter: 1.0.0 dev: true - /aws-sign2/0.7.0: + /aws-sign2@0.7.0: resolution: {integrity: sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA==} dev: true - /aws4/1.11.0: + /aws4@1.11.0: resolution: {integrity: sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA==} dev: true - /babel-code-frame/6.26.0: + /babel-code-frame@6.26.0: resolution: {integrity: sha512-XqYMR2dfdGMW+hd0IUZ2PwK+fGeFkOxZJ0wY+JaQAHzt1Zx8LcvpiZD2NiGkEG8qx0CfkAOr5xt76d1e8vG90g==} dependencies: chalk: 1.1.3 @@ -2477,7 +2531,7 @@ packages: js-tokens: 3.0.2 dev: true - /babel-core/6.26.3: + /babel-core@6.26.3: resolution: {integrity: sha512-6jyFLuDmeidKmUEb3NM+/yawG0M2bDZ9Z1qbZP59cyHLz8kYGKYwpJP0UwUKKUiTRNvxfLesJnTedqczP7cTDA==} dependencies: babel-code-frame: 6.26.0 @@ -2503,7 +2557,7 @@ packages: - supports-color dev: true - /babel-generator/6.26.1: + /babel-generator@6.26.1: resolution: {integrity: sha512-HyfwY6ApZj7BYTcJURpM5tznulaBvyio7/0d4zFOeMPUmfxkCjHocCuoLa2SAGzBI8AREcH3eP3758F672DppA==} dependencies: babel-messages: 6.23.0 @@ -2516,7 +2570,7 @@ packages: trim-right: 1.0.1 dev: true - /babel-helper-builder-binary-assignment-operator-visitor/6.24.1: + /babel-helper-builder-binary-assignment-operator-visitor@6.24.1: resolution: {integrity: sha512-gCtfYORSG1fUMX4kKraymq607FWgMWg+j42IFPc18kFQEsmtaibP4UrqsXt8FlEJle25HUd4tsoDR7H2wDhe9Q==} dependencies: babel-helper-explode-assignable-expression: 6.24.1 @@ -2526,7 +2580,7 @@ packages: - supports-color dev: true - /babel-helper-call-delegate/6.24.1: + /babel-helper-call-delegate@6.24.1: resolution: {integrity: sha512-RL8n2NiEj+kKztlrVJM9JT1cXzzAdvWFh76xh/H1I4nKwunzE4INBXn8ieCZ+wh4zWszZk7NBS1s/8HR5jDkzQ==} dependencies: babel-helper-hoist-variables: 6.24.1 @@ -2537,7 +2591,7 @@ packages: - supports-color dev: true - /babel-helper-define-map/6.26.0: + /babel-helper-define-map@6.26.0: resolution: {integrity: sha512-bHkmjcC9lM1kmZcVpA5t2om2nzT/xiZpo6TJq7UlZ3wqKfzia4veeXbIhKvJXAMzhhEBd3cR1IElL5AenWEUpA==} dependencies: babel-helper-function-name: 6.24.1 @@ -2548,7 +2602,7 @@ packages: - supports-color dev: true - /babel-helper-explode-assignable-expression/6.24.1: + /babel-helper-explode-assignable-expression@6.24.1: resolution: {integrity: sha512-qe5csbhbvq6ccry9G7tkXbzNtcDiH4r51rrPUbwwoTzZ18AqxWYRZT6AOmxrpxKnQBW0pYlBI/8vh73Z//78nQ==} dependencies: babel-runtime: 6.26.0 @@ -2558,7 +2612,7 @@ packages: - supports-color dev: true - /babel-helper-function-name/6.24.1: + /babel-helper-function-name@6.24.1: resolution: {integrity: sha512-Oo6+e2iX+o9eVvJ9Y5eKL5iryeRdsIkwRYheCuhYdVHsdEQysbc2z2QkqCLIYnNxkT5Ss3ggrHdXiDI7Dhrn4Q==} dependencies: babel-helper-get-function-arity: 6.24.1 @@ -2570,28 +2624,28 @@ packages: - supports-color dev: true - /babel-helper-get-function-arity/6.24.1: + /babel-helper-get-function-arity@6.24.1: resolution: {integrity: sha512-WfgKFX6swFB1jS2vo+DwivRN4NB8XUdM3ij0Y1gnC21y1tdBoe6xjVnd7NSI6alv+gZXCtJqvrTeMW3fR/c0ng==} dependencies: babel-runtime: 6.26.0 babel-types: 6.26.0 dev: true - /babel-helper-hoist-variables/6.24.1: + /babel-helper-hoist-variables@6.24.1: resolution: {integrity: sha512-zAYl3tqerLItvG5cKYw7f1SpvIxS9zi7ohyGHaI9cgDUjAT6YcY9jIEH5CstetP5wHIVSceXwNS7Z5BpJg+rOw==} dependencies: babel-runtime: 6.26.0 babel-types: 6.26.0 dev: true - /babel-helper-optimise-call-expression/6.24.1: + /babel-helper-optimise-call-expression@6.24.1: resolution: {integrity: sha512-Op9IhEaxhbRT8MDXx2iNuMgciu2V8lDvYCNQbDGjdBNCjaMvyLf4wl4A3b8IgndCyQF8TwfgsQ8T3VD8aX1/pA==} dependencies: babel-runtime: 6.26.0 babel-types: 6.26.0 dev: true - /babel-helper-regex/6.26.0: + /babel-helper-regex@6.26.0: resolution: {integrity: sha512-VlPiWmqmGJp0x0oK27Out1D+71nVVCTSdlbhIVoaBAj2lUgrNjBCRR9+llO4lTSb2O4r7PJg+RobRkhBrf6ofg==} dependencies: babel-runtime: 6.26.0 @@ -2599,7 +2653,7 @@ packages: lodash: 4.17.21 dev: true - /babel-helper-remap-async-to-generator/6.24.1: + /babel-helper-remap-async-to-generator@6.24.1: resolution: {integrity: sha512-RYqaPD0mQyQIFRu7Ho5wE2yvA/5jxqCIj/Lv4BXNq23mHYu/vxikOy2JueLiBxQknwapwrJeNCesvY0ZcfnlHg==} dependencies: babel-helper-function-name: 6.24.1 @@ -2611,7 +2665,7 @@ packages: - supports-color dev: true - /babel-helper-replace-supers/6.24.1: + /babel-helper-replace-supers@6.24.1: resolution: {integrity: sha512-sLI+u7sXJh6+ToqDr57Bv973kCepItDhMou0xCP2YPVmR1jkHSCY+p1no8xErbV1Siz5QE8qKT1WIwybSWlqjw==} dependencies: babel-helper-optimise-call-expression: 6.24.1 @@ -2624,7 +2678,7 @@ packages: - supports-color dev: true - /babel-helpers/6.24.1: + /babel-helpers@6.24.1: resolution: {integrity: sha512-n7pFrqQm44TCYvrCDb0MqabAF+JUBq+ijBvNMUxpkLjJaAu32faIexewMumrH5KLLJ1HDyT0PTEqRyAe/GwwuQ==} dependencies: babel-runtime: 6.26.0 @@ -2633,31 +2687,31 @@ packages: - supports-color dev: true - /babel-messages/6.23.0: + /babel-messages@6.23.0: resolution: {integrity: sha512-Bl3ZiA+LjqaMtNYopA9TYE9HP1tQ+E5dLxE0XrAzcIJeK2UqF0/EaqXwBn9esd4UmTfEab+P+UYQ1GnioFIb/w==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-check-es2015-constants/6.22.0: + /babel-plugin-check-es2015-constants@6.22.0: resolution: {integrity: sha512-B1M5KBP29248dViEo1owyY32lk1ZSH2DaNNrXLGt8lyjjHm7pBqAdQ7VKUPR6EEDO323+OvT3MQXbCin8ooWdA==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-syntax-async-functions/6.13.0: + /babel-plugin-syntax-async-functions@6.13.0: resolution: {integrity: sha512-4Zp4unmHgw30A1eWI5EpACji2qMocisdXhAftfhXoSV9j0Tvj6nRFE3tOmRY912E0FMRm/L5xWE7MGVT2FoLnw==} dev: true - /babel-plugin-syntax-exponentiation-operator/6.13.0: + /babel-plugin-syntax-exponentiation-operator@6.13.0: resolution: {integrity: sha512-Z/flU+T9ta0aIEKl1tGEmN/pZiI1uXmCiGFRegKacQfEJzp7iNsKloZmyJlQr+75FCJtiFfGIK03SiCvCt9cPQ==} dev: true - /babel-plugin-syntax-trailing-function-commas/6.22.0: + /babel-plugin-syntax-trailing-function-commas@6.22.0: resolution: {integrity: sha512-Gx9CH3Q/3GKbhs07Bszw5fPTlU+ygrOGfAhEt7W2JICwufpC4SuO0mG0+4NykPBSYPMJhqvVlDBU17qB1D+hMQ==} dev: true - /babel-plugin-transform-async-to-generator/6.24.1: + /babel-plugin-transform-async-to-generator@6.24.1: resolution: {integrity: sha512-7BgYJujNCg0Ti3x0c/DL3tStvnKS6ktIYOmo9wginv/dfZOrbSZ+qG4IRRHMBOzZ5Awb1skTiAsQXg/+IWkZYw==} dependencies: babel-helper-remap-async-to-generator: 6.24.1 @@ -2667,19 +2721,19 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-arrow-functions/6.22.0: + /babel-plugin-transform-es2015-arrow-functions@6.22.0: resolution: {integrity: sha512-PCqwwzODXW7JMrzu+yZIaYbPQSKjDTAsNNlK2l5Gg9g4rz2VzLnZsStvp/3c46GfXpwkyufb3NCyG9+50FF1Vg==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-block-scoped-functions/6.22.0: + /babel-plugin-transform-es2015-block-scoped-functions@6.22.0: resolution: {integrity: sha512-2+ujAT2UMBzYFm7tidUsYh+ZoIutxJ3pN9IYrF1/H6dCKtECfhmB8UkHVpyxDwkj0CYbQG35ykoz925TUnBc3A==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-block-scoping/6.26.0: + /babel-plugin-transform-es2015-block-scoping@6.26.0: resolution: {integrity: sha512-YiN6sFAQ5lML8JjCmr7uerS5Yc/EMbgg9G8ZNmk2E3nYX4ckHR01wrkeeMijEf5WHNK5TW0Sl0Uu3pv3EdOJWw==} dependencies: babel-runtime: 6.26.0 @@ -2691,7 +2745,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-classes/6.24.1: + /babel-plugin-transform-es2015-classes@6.24.1: resolution: {integrity: sha512-5Dy7ZbRinGrNtmWpquZKZ3EGY8sDgIVB4CU8Om8q8tnMLrD/m94cKglVcHps0BCTdZ0TJeeAWOq2TK9MIY6cag==} dependencies: babel-helper-define-map: 6.26.0 @@ -2707,7 +2761,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-computed-properties/6.24.1: + /babel-plugin-transform-es2015-computed-properties@6.24.1: resolution: {integrity: sha512-C/uAv4ktFP/Hmh01gMTvYvICrKze0XVX9f2PdIXuriCSvUmV9j+u+BB9f5fJK3+878yMK6dkdcq+Ymr9mrcLzw==} dependencies: babel-runtime: 6.26.0 @@ -2716,26 +2770,26 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-destructuring/6.23.0: + /babel-plugin-transform-es2015-destructuring@6.23.0: resolution: {integrity: sha512-aNv/GDAW0j/f4Uy1OEPZn1mqD+Nfy9viFGBfQ5bZyT35YqOiqx7/tXdyfZkJ1sC21NyEsBdfDY6PYmLHF4r5iA==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-duplicate-keys/6.24.1: + /babel-plugin-transform-es2015-duplicate-keys@6.24.1: resolution: {integrity: sha512-ossocTuPOssfxO2h+Z3/Ea1Vo1wWx31Uqy9vIiJusOP4TbF7tPs9U0sJ9pX9OJPf4lXRGj5+6Gkl/HHKiAP5ug==} dependencies: babel-runtime: 6.26.0 babel-types: 6.26.0 dev: true - /babel-plugin-transform-es2015-for-of/6.23.0: + /babel-plugin-transform-es2015-for-of@6.23.0: resolution: {integrity: sha512-DLuRwoygCoXx+YfxHLkVx5/NpeSbVwfoTeBykpJK7JhYWlL/O8hgAK/reforUnZDlxasOrVPPJVI/guE3dCwkw==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-function-name/6.24.1: + /babel-plugin-transform-es2015-function-name@6.24.1: resolution: {integrity: sha512-iFp5KIcorf11iBqu/y/a7DK3MN5di3pNCzto61FqCNnUX4qeBwcV1SLqe10oXNnCaxBUImX3SckX2/o1nsrTcg==} dependencies: babel-helper-function-name: 6.24.1 @@ -2745,13 +2799,13 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-literals/6.22.0: + /babel-plugin-transform-es2015-literals@6.22.0: resolution: {integrity: sha512-tjFl0cwMPpDYyoqYA9li1/7mGFit39XiNX5DKC/uCNjBctMxyL1/PT/l4rSlbvBG1pOKI88STRdUsWXB3/Q9hQ==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-modules-amd/6.24.1: + /babel-plugin-transform-es2015-modules-amd@6.24.1: resolution: {integrity: sha512-LnIIdGWIKdw7zwckqx+eGjcS8/cl8D74A3BpJbGjKTFFNJSMrjN4bIh22HY1AlkUbeLG6X6OZj56BDvWD+OeFA==} dependencies: babel-plugin-transform-es2015-modules-commonjs: 6.26.2 @@ -2761,7 +2815,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-modules-commonjs/6.26.2: + /babel-plugin-transform-es2015-modules-commonjs@6.26.2: resolution: {integrity: sha512-CV9ROOHEdrjcwhIaJNBGMBCodN+1cfkwtM1SbUHmvyy35KGT7fohbpOxkE2uLz1o6odKK2Ck/tz47z+VqQfi9Q==} dependencies: babel-plugin-transform-strict-mode: 6.24.1 @@ -2772,7 +2826,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-modules-systemjs/6.24.1: + /babel-plugin-transform-es2015-modules-systemjs@6.24.1: resolution: {integrity: sha512-ONFIPsq8y4bls5PPsAWYXH/21Hqv64TBxdje0FvU3MhIV6QM2j5YS7KvAzg/nTIVLot2D2fmFQrFWCbgHlFEjg==} dependencies: babel-helper-hoist-variables: 6.24.1 @@ -2782,7 +2836,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-modules-umd/6.24.1: + /babel-plugin-transform-es2015-modules-umd@6.24.1: resolution: {integrity: sha512-LpVbiT9CLsuAIp3IG0tfbVo81QIhn6pE8xBJ7XSeCtFlMltuar5VuBV6y6Q45tpui9QWcy5i0vLQfCfrnF7Kiw==} dependencies: babel-plugin-transform-es2015-modules-amd: 6.24.1 @@ -2792,7 +2846,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-object-super/6.24.1: + /babel-plugin-transform-es2015-object-super@6.24.1: resolution: {integrity: sha512-8G5hpZMecb53vpD3mjs64NhI1au24TAmokQ4B+TBFBjN9cVoGoOvotdrMMRmHvVZUEvqGUPWL514woru1ChZMA==} dependencies: babel-helper-replace-supers: 6.24.1 @@ -2801,7 +2855,7 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-parameters/6.24.1: + /babel-plugin-transform-es2015-parameters@6.24.1: resolution: {integrity: sha512-8HxlW+BB5HqniD+nLkQ4xSAVq3bR/pcYW9IigY+2y0dI+Y7INFeTbfAQr+63T3E4UDsZGjyb+l9txUnABWxlOQ==} dependencies: babel-helper-call-delegate: 6.24.1 @@ -2814,20 +2868,20 @@ packages: - supports-color dev: true - /babel-plugin-transform-es2015-shorthand-properties/6.24.1: + /babel-plugin-transform-es2015-shorthand-properties@6.24.1: resolution: {integrity: sha512-mDdocSfUVm1/7Jw/FIRNw9vPrBQNePy6wZJlR8HAUBLybNp1w/6lr6zZ2pjMShee65t/ybR5pT8ulkLzD1xwiw==} dependencies: babel-runtime: 6.26.0 babel-types: 6.26.0 dev: true - /babel-plugin-transform-es2015-spread/6.22.0: + /babel-plugin-transform-es2015-spread@6.22.0: resolution: {integrity: sha512-3Ghhi26r4l3d0Js933E5+IhHwk0A1yiutj9gwvzmFbVV0sPMYk2lekhOufHBswX7NCoSeF4Xrl3sCIuSIa+zOg==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-sticky-regex/6.24.1: + /babel-plugin-transform-es2015-sticky-regex@6.24.1: resolution: {integrity: sha512-CYP359ADryTo3pCsH0oxRo/0yn6UsEZLqYohHmvLQdfS9xkf+MbCzE3/Kolw9OYIY4ZMilH25z/5CbQbwDD+lQ==} dependencies: babel-helper-regex: 6.26.0 @@ -2835,19 +2889,19 @@ packages: babel-types: 6.26.0 dev: true - /babel-plugin-transform-es2015-template-literals/6.22.0: + /babel-plugin-transform-es2015-template-literals@6.22.0: resolution: {integrity: sha512-x8b9W0ngnKzDMHimVtTfn5ryimars1ByTqsfBDwAqLibmuuQY6pgBQi5z1ErIsUOWBdw1bW9FSz5RZUojM4apg==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-typeof-symbol/6.23.0: + /babel-plugin-transform-es2015-typeof-symbol@6.23.0: resolution: {integrity: sha512-fz6J2Sf4gYN6gWgRZaoFXmq93X+Li/8vf+fb0sGDVtdeWvxC9y5/bTD7bvfWMEq6zetGEHpWjtzRGSugt5kNqw==} dependencies: babel-runtime: 6.26.0 dev: true - /babel-plugin-transform-es2015-unicode-regex/6.24.1: + /babel-plugin-transform-es2015-unicode-regex@6.24.1: resolution: {integrity: sha512-v61Dbbihf5XxnYjtBN04B/JBvsScY37R1cZT5r9permN1cp+b70DY3Ib3fIkgn1DI9U3tGgBJZVD8p/mE/4JbQ==} dependencies: babel-helper-regex: 6.26.0 @@ -2855,7 +2909,7 @@ packages: regexpu-core: 2.0.0 dev: true - /babel-plugin-transform-exponentiation-operator/6.24.1: + /babel-plugin-transform-exponentiation-operator@6.24.1: resolution: {integrity: sha512-LzXDmbMkklvNhprr20//RStKVcT8Cu+SQtX18eMHLhjHf2yFzwtQ0S2f0jQ+89rokoNdmwoSqYzAhq86FxlLSQ==} dependencies: babel-helper-builder-binary-assignment-operator-visitor: 6.24.1 @@ -2865,20 +2919,20 @@ packages: - supports-color dev: true - /babel-plugin-transform-regenerator/6.26.0: + /babel-plugin-transform-regenerator@6.26.0: resolution: {integrity: sha512-LS+dBkUGlNR15/5WHKe/8Neawx663qttS6AGqoOUhICc9d1KciBvtrQSuc0PI+CxQ2Q/S1aKuJ+u64GtLdcEZg==} dependencies: regenerator-transform: 0.10.1 dev: true - /babel-plugin-transform-strict-mode/6.24.1: + /babel-plugin-transform-strict-mode@6.24.1: resolution: {integrity: sha512-j3KtSpjyLSJxNoCDrhwiJad8kw0gJ9REGj8/CqL0HeRyLnvUNYV9zcqluL6QJSXh3nfsLEmSLvwRfGzrgR96Pw==} dependencies: babel-runtime: 6.26.0 babel-types: 6.26.0 dev: true - /babel-preset-env/1.7.0: + /babel-preset-env@1.7.0: resolution: {integrity: sha512-9OR2afuKDneX2/q2EurSftUYM0xGu4O2D9adAhVfADDhrYDaxXV0rBbevVYoY9n6nyX1PmQW/0jtpJvUNr9CHg==} dependencies: babel-plugin-check-es2015-constants: 6.22.0 @@ -2915,7 +2969,7 @@ packages: - supports-color dev: true - /babel-register/6.26.0: + /babel-register@6.26.0: resolution: {integrity: sha512-veliHlHX06wjaeY8xNITbveXSiI+ASFnOqvne/LaIJIqOWi2Ogmj91KOugEz/hoh/fwMhXNBJPCv8Xaz5CyM4A==} dependencies: babel-core: 6.26.3 @@ -2929,14 +2983,14 @@ packages: - supports-color dev: true - /babel-runtime/6.26.0: + /babel-runtime@6.26.0: resolution: {integrity: sha512-ITKNuq2wKlW1fJg9sSW52eepoYgZBggvOAHC0u/CYu/qxQ9EVzThCgR69BnSXLHjy2f7SY5zaQ4yt7H9ZVxY2g==} dependencies: core-js: 2.6.12 regenerator-runtime: 0.11.1 dev: true - /babel-template/6.26.0: + /babel-template@6.26.0: resolution: {integrity: sha512-PCOcLFW7/eazGUKIoqH97sO9A2UYMahsn/yRQ7uOk37iutwjq7ODtcTNF+iFDSHNfkctqsLRjLP7URnOx0T1fg==} dependencies: babel-runtime: 6.26.0 @@ -2948,7 +3002,7 @@ packages: - supports-color dev: true - /babel-traverse/6.26.0: + /babel-traverse@6.26.0: resolution: {integrity: sha512-iSxeXx7apsjCHe9c7n8VtRXGzI2Bk1rBSOJgCCjfyXb6v1aCqE1KSEpq/8SXuVN8Ka/Rh1WDTF0MDzkvTA4MIA==} dependencies: babel-code-frame: 6.26.0 @@ -2964,7 +3018,7 @@ packages: - supports-color dev: true - /babel-types/6.26.0: + /babel-types@6.26.0: resolution: {integrity: sha512-zhe3V/26rCWsEZK8kZN+HaQj5yQ1CilTObixFzKW1UWjqG7618Twz6YEsCnjfg5gBcJh02DrpCkS9h98ZqDY+g==} dependencies: babel-runtime: 6.26.0 @@ -2973,7 +3027,7 @@ packages: to-fast-properties: 1.0.3 dev: true - /babelify/7.3.0: + /babelify@7.3.0: resolution: {integrity: sha512-vID8Fz6pPN5pJMdlUnNFSfrlcx5MUule4k9aKs/zbZPyXxMTcRrB0M4Tarw22L8afr8eYSWxDPYCob3TdrqtlA==} dependencies: babel-core: 6.26.3 @@ -2982,29 +3036,33 @@ packages: - supports-color dev: true - /babylon/6.18.0: + /babylon@6.18.0: resolution: {integrity: sha512-q/UEjfGJ2Cm3oKV71DJz9d25TPnq5rhBVL2Q4fA5wcC3jcrdn7+SssEybFIxwAvvP+YCsCYNKughoF33GxgycQ==} hasBin: true dev: true - /backoff/2.5.0: + /backoff@2.5.0: resolution: {integrity: sha512-wC5ihrnUXmR2douXmXLCe5O3zg3GKIyvRi/hi58a/XyRxVI+3/yM0PYueQOZXPXQ9pxBislYkw+sF9b7C/RuMA==} engines: {node: '>= 0.6'} dependencies: precond: 0.2.3 dev: true - /balanced-match/1.0.0: + /balanced-match@1.0.0: resolution: {integrity: sha512-9Y0g0Q8rmSt+H33DfKv7FOc3v+iRI+o1lbzt8jGcIosYW37IIW/2XVYq5NPdmaD5NQ59Nk26Kl/vZbwW9Fr8vg==} dev: true - /base-x/3.0.9: + /base-x@3.0.9: resolution: {integrity: sha512-H7JU6iBHTal1gp56aKoaa//YUxEaAOUiydvrV/pILqIHXTtqxSkATOnDA2u+jZ/61sD+L/412+7kzXRtWukhpQ==} dependencies: safe-buffer: 5.2.1 dev: true - /base/0.11.2: + /base64-js@1.5.1: + resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} + dev: true + + /base@0.11.2: resolution: {integrity: sha512-5T6P4xPgpp0YDFvSWwEZ4NoE3aM4QBQXDzmVbraCkFj8zHM+mba8SyqB5DbZWyR7mYHo6Y7BdQo3MoA4m0TeQg==} engines: {node: '>=0.10.0'} dependencies: @@ -3017,20 +3075,16 @@ packages: pascalcase: 0.1.1 dev: true - /base64-js/1.5.1: - resolution: {integrity: sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==} - dev: true - - /bcrypt-pbkdf/1.0.2: + /bcrypt-pbkdf@1.0.2: resolution: {integrity: sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w==} dependencies: tweetnacl: 0.14.5 dev: true - /bech32/1.1.4: + /bech32@1.1.4: resolution: {integrity: sha512-s0IrSOzLlbvX7yp4WBfPITzpAU8sqQcpsmwXDiKwrG4r491vwCO/XpejasRNl0piBMe/DvP4Tz0mIS/X1DPJBQ==} - /better-ajv-errors/0.8.2_ajv@6.12.6: + /better-ajv-errors@0.8.2(ajv@6.12.6): resolution: {integrity: sha512-FnODTBJSQSHmJXDLPiC7ca0dC4S1HSTPv1+Hg2sm/C71i3Dj0l1jcUEaq/3OQ6MmnUveshTsUvUj65pDSr3Qow==} peerDependencies: ajv: 4.11.8 - 8 @@ -3045,47 +3099,47 @@ packages: leven: 3.1.0 dev: true - /big-integer/1.6.36: + /big-integer@1.6.36: resolution: {integrity: sha512-t70bfa7HYEA1D9idDbmuv7YbsbVkQ+Hp+8KFSul4aE5e/i1bjCNIRYJZlA8Q8p0r9T8cF/RVvwUgRA//FydEyg==} engines: {node: '>=0.6'} dev: true - /big.js/6.2.1: + /big.js@6.2.1: resolution: {integrity: sha512-bCtHMwL9LeDIozFn+oNhhFoq+yQ3BNdnsLSASUxLciOb1vgvpHsIO1dsENiGMgbb4SkP5TrzWzRiLddn8ahVOQ==} dev: true - /bigint-crypto-utils/3.1.8: + /bigint-crypto-utils@3.1.8: resolution: {integrity: sha512-+VMV9Laq8pXLBKKKK49nOoq9bfR3j7NNQAtbA617a4nw9bVLo8rsqkKMBgM2AJWlNX9fEIyYaYX+d0laqYV4tw==} engines: {node: '>=10.4.0'} dependencies: bigint-mod-arith: 3.1.2 dev: true - /bigint-mod-arith/3.1.2: + /bigint-mod-arith@3.1.2: resolution: {integrity: sha512-nx8J8bBeiRR+NlsROFH9jHswW5HO8mgfOSqW0AmjicMMvaONDa8AO+5ViKDUUNytBPWiwfvZP4/Bj4Y3lUfvgQ==} engines: {node: '>=10.4.0'} dev: true - /bignumber.js/7.2.1: + /bignumber.js@7.2.1: resolution: {integrity: sha512-S4XzBk5sMB+Rcb/LNcpzXr57VRTxgAvaAEDAl1AwRx27j00hT84O6OkteE7u8UB3NuaaygCRrEpqox4uDOrbdQ==} dev: true - /bignumber.js/9.1.0: + /bignumber.js@9.1.0: resolution: {integrity: sha512-4LwHK4nfDOraBCtst+wOWIHbu1vhvAPJK8g8nROd4iuc3PSEjWif/qwbkh8jwCJz6yDBvtU4KPynETgrfh7y3A==} dev: true - /binary-extensions/2.2.0: + /binary-extensions@2.2.0: resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} engines: {node: '>=8'} dev: true - /bindings/1.5.0: + /bindings@1.5.0: resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==} dependencies: file-uri-to-path: 1.0.0 dev: true - /bip39/2.5.0: + /bip39@2.5.0: resolution: {integrity: sha512-xwIx/8JKoT2+IPJpFEfXoWdYwP7UVAoUxxLNfGCfVowaJE7yg1Y5B1BVPqlUNsBq5/nGwmFkwRJ8xDW4sX8OdA==} dependencies: create-hash: 1.2.0 @@ -3095,31 +3149,31 @@ packages: unorm: 1.6.0 dev: true - /bip66/1.1.5: + /bip66@1.1.5: resolution: {integrity: sha512-nemMHz95EmS38a26XbbdxIYj5csHd3RMP3H5bwQknX0WYHF01qhpufP42mLOwVICuH2JmhIhXiWs89MfUGL7Xw==} dependencies: safe-buffer: 5.2.1 dev: true - /blakejs/1.2.1: + /blakejs@1.2.1: resolution: {integrity: sha512-QXUSXI3QVc/gJME0dBpXrag1kbzOqCjCX8/b54ntNyW6sjtoqxqRk3LTmXzaJoh71zMsDCjM+47jS7XiwN/+fQ==} dev: true - /bluebird/3.7.2: + /bluebird@3.7.2: resolution: {integrity: sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==} dev: true - /bn.js/4.11.6: + /bn.js@4.11.6: resolution: {integrity: sha512-XWwnNNFCuuSQ0m3r3C4LE3EiORltHd9M05pq6FOlVeiophzRbMo50Sbz1ehl8K3Z+jw9+vmgnXefY1hz8X+2wA==} dev: true - /bn.js/4.12.0: + /bn.js@4.12.0: resolution: {integrity: sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA==} - /bn.js/5.2.1: + /bn.js@5.2.1: resolution: {integrity: sha512-eXRvHzWyYPBuB4NBy0cmYQjGitUrtqwbvlzP3G6VFnNRbsZQIxQ10PbKKHt8gZ/HW/D/747aDl+QkDqg3KQLMQ==} - /body-parser/1.19.0: + /body-parser@1.19.0: resolution: {integrity: sha512-dhEPs72UPbDnAQJ9ZKMNTP6ptJaionhP5cBb541nXPlW60Jepo9RV/a4fX4XWW9CuFNK22krhrj1+rgzifNCsw==} engines: {node: '>= 0.8'} dependencies: @@ -3137,24 +3191,24 @@ packages: - supports-color dev: true - /boolbase/1.0.0: + /boolbase@1.0.0: resolution: {integrity: sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==} dev: true - /brace-expansion/1.1.11: + /brace-expansion@1.1.11: resolution: {integrity: sha512-iCuPHDFgrHX7H2vEI/5xpz07zSHB00TpugqhmYtVmMO6518mCuRMoOYFldEBl0g187ufozdaHgWKcYFb61qGiA==} dependencies: balanced-match: 1.0.0 concat-map: 0.0.1 dev: true - /brace-expansion/2.0.1: + /brace-expansion@2.0.1: resolution: {integrity: sha512-XnAIvQ8eM+kC6aULx6wuQiwVsnzsi9d3WxzV3FpWTGA19F621kwdbsAcFKXgKUHZWsy+mY6iL1sHTxWEFCytDA==} dependencies: balanced-match: 1.0.0 dev: true - /braces/2.3.2: + /braces@2.3.2: resolution: {integrity: sha512-aNdbnj9P8PjdXU4ybaWLK2IF3jc/EoDYbC7AazW6to3TRsfXxscC9UXOB5iDiEQrkyIbWp2SLQda4+QAa7nc3w==} engines: {node: '>=0.10.0'} dependencies: @@ -3172,17 +3226,17 @@ packages: - supports-color dev: true - /braces/3.0.2: + /braces@3.0.2: resolution: {integrity: sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==} engines: {node: '>=8'} dependencies: fill-range: 7.0.1 dev: true - /brorand/1.1.0: + /brorand@1.1.0: resolution: {integrity: sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==} - /browser-level/1.0.1: + /browser-level@1.0.1: resolution: {integrity: sha512-XECYKJ+Dbzw0lbydyQuJzwNXtOpbMSq737qxJN11sIRTErOMShvDpbzTlgju7orJKvx4epULolZAuJGLzCmWRQ==} dependencies: abstract-level: 1.0.3 @@ -3191,11 +3245,11 @@ packages: run-parallel-limit: 1.1.0 dev: true - /browser-stdout/1.3.1: + /browser-stdout@1.3.1: resolution: {integrity: sha512-qhAVI1+Av2X7qelOfAIYwXONood6XlZE/fXaBSmW/T5SzLAmCgzi+eiWE7fUvbHaeNBQH13UftjpXxsfLkMpgw==} dev: true - /browserify-aes/1.2.0: + /browserify-aes@1.2.0: resolution: {integrity: sha512-+7CHXqGuspUn/Sl5aO7Ea0xWGAtETPXNSAjHo48JfLdPWcMng33Xe4znFvQweqc/uzk5zSOI3H52CYnjCfb5hA==} dependencies: buffer-xor: 1.0.3 @@ -3206,7 +3260,7 @@ packages: safe-buffer: 5.2.1 dev: true - /browserify-cipher/1.0.1: + /browserify-cipher@1.0.1: resolution: {integrity: sha512-sPhkz0ARKbf4rRQt2hTpAHqn47X3llLkUGn+xEJzLjwY8LRs2p0v7ljvI5EyoRO/mexrNunNECisZs+gw2zz1w==} dependencies: browserify-aes: 1.2.0 @@ -3214,7 +3268,7 @@ packages: evp_bytestokey: 1.0.3 dev: true - /browserify-des/1.0.2: + /browserify-des@1.0.2: resolution: {integrity: sha512-BioO1xf3hFwz4kc6iBhI3ieDFompMhrMlnDFC4/0/vd5MokpuAc3R+LYbwTA9A5Yc9pq9UYPqffKpW2ObuwX5A==} dependencies: cipher-base: 1.0.4 @@ -3223,21 +3277,21 @@ packages: safe-buffer: 5.2.1 dev: true - /browserify-rsa/4.0.1: + /browserify-rsa@4.0.1: resolution: {integrity: sha512-+YpEyaLDDvvdzIxQ+cCx73r5YEhS3ANGOkiHdyWqW4t3gdeoNEYjSiQwntbU4Uo2/9yRkpYX3SRFeH+7jc2Duw==} dependencies: bn.js: 4.12.0 randombytes: 2.1.0 dev: true - /browserify-sha3/0.0.4: + /browserify-sha3@0.0.4: resolution: {integrity: sha512-WmXX4M8lltqzMnBiPbP9KQdITknmxe4Wp3rhGfpYJst5yOeGwKkHpC0t+Ty22laH4Ltg9YO+p14p93wiipqjxA==} dependencies: js-sha3: 0.6.1 safe-buffer: 5.2.1 dev: true - /browserify-sign/4.0.4: + /browserify-sign@4.0.4: resolution: {integrity: sha512-D2ItxCwNtLcHRrOCuEDZQlIezlFyUV/N5IYz6TY1svu1noyThFuthoEjzT8ChZe3UEctqnwmykcPhet3Eiz58A==} dependencies: bn.js: 4.12.0 @@ -3249,7 +3303,7 @@ packages: parse-asn1: 5.1.5 dev: true - /browserslist/3.2.8: + /browserslist@3.2.8: resolution: {integrity: sha512-WHVocJYavUwVgVViC0ORikPHQquXwVh939TaelZ4WDqpWgTX/FsGhl/+P4qBUAGcRvtOgDgC+xftNWWp2RUTAQ==} hasBin: true dependencies: @@ -3257,13 +3311,13 @@ packages: electron-to-chromium: 1.4.270 dev: true - /bs58/4.0.1: + /bs58@4.0.1: resolution: {integrity: sha512-Ok3Wdf5vOIlBrgCvTq96gBkJw+JUEzdBgyaza5HLtPm7yTHkjRy8+JzNyHF7BHa0bNWOQIp3m5YF0nnFcOIKLw==} dependencies: base-x: 3.0.9 dev: true - /bs58check/2.1.2: + /bs58check@2.1.2: resolution: {integrity: sha512-0TS1jicxdU09dwJMNZtVAfzPi6Q6QeN0pM1Fkzrjn+XYHvzMKPU3pHVpva+769iNVSfIYWf7LJ6WR+BuuMf8cA==} dependencies: bs58: 4.0.1 @@ -3271,39 +3325,39 @@ packages: safe-buffer: 5.2.1 dev: true - /buffer-from/1.1.2: + /buffer-from@1.1.2: resolution: {integrity: sha512-E+XQCRwSbaaiChtv6k6Dwgc+bx+Bs6vuKJHHl5kox/BaKbhiXzqQOwK4cO22yElGp2OCmjwVhT3HmxgyPGnJfQ==} dev: true - /buffer-to-arraybuffer/0.0.5: + /buffer-to-arraybuffer@0.0.5: resolution: {integrity: sha512-3dthu5CYiVB1DEJp61FtApNnNndTckcqe4pFcLdvHtrpG+kcyekCJKg4MRiDcFW7A6AODnXB9U4dwQiCW5kzJQ==} dev: true - /buffer-xor/1.0.3: + /buffer-xor@1.0.3: resolution: {integrity: sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ==} dev: true - /buffer-xor/2.0.2: + /buffer-xor@2.0.2: resolution: {integrity: sha512-eHslX0bin3GB+Lx2p7lEYRShRewuNZL3fUl4qlVJGGiwoPGftmt8JQgk2Y9Ji5/01TnVDo33E5b5O3vUB1HdqQ==} dependencies: safe-buffer: 5.2.1 dev: true - /buffer/5.7.1: + /buffer@5.7.1: resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==} dependencies: base64-js: 1.5.1 ieee754: 1.2.1 dev: true - /buffer/6.0.3: + /buffer@6.0.3: resolution: {integrity: sha512-FTiCpNxtwiZZHEZbcbTIcZjERVICn9yq/pDFkTl95/AxzD1naBctN7YO68riM/gLSDY7sdrMby8hofADYuuqOA==} dependencies: base64-js: 1.5.1 ieee754: 1.2.1 dev: true - /bufferutil/4.0.6: + /bufferutil@4.0.6: resolution: {integrity: sha512-jduaYOYtnio4aIAyc6UbvPCVcgq7nYpVnucyxr6eCYg/Woad9Hf/oxxBRDnGGjPfjUm6j5O/uBWhIu4iLebFaw==} engines: {node: '>=6.14.2'} requiresBuild: true @@ -3311,42 +3365,42 @@ packages: node-gyp-build: 4.5.0 dev: true - /bufio/1.0.7: + /bufio@1.0.7: resolution: {integrity: sha512-bd1dDQhiC+bEbEfg56IdBv7faWa6OipMs/AFFFvtFnB3wAYjlwQpQRZ0pm6ZkgtfL0pILRXhKxOiQj6UzoMR7A==} engines: {node: '>=8.0.0'} dev: false - /busboy/1.6.0: + /busboy@1.6.0: resolution: {integrity: sha512-8SFQbg/0hQ9xy3UNTB0YEnsNBbWfhf7RtnzpL7TkBiTBRfrQ9Fxcnz7VJsleJpyp6rVLvXiuORqjlHi5q+PYuA==} engines: {node: '>=10.16.0'} dependencies: streamsearch: 1.1.0 dev: true - /bytes/3.1.0: + /bytes@3.1.0: resolution: {integrity: sha512-zauLjrfCG+xvoyaqLoV8bLVXXNGC4JqlxFCutSDWA6fJrTo2ZuvLYTqZ7aHBLZSMOopbzwv8f+wZcVzfVTI2Dg==} engines: {node: '>= 0.8'} dev: true - /bytes/3.1.2: + /bytes@3.1.2: resolution: {integrity: sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg==} engines: {node: '>= 0.8'} dev: true - /bytewise-core/1.2.3: + /bytewise-core@1.2.3: resolution: {integrity: sha512-nZD//kc78OOxeYtRlVk8/zXqTB4gf/nlguL1ggWA8FuchMyOxcyHR4QPQZMUmA7czC+YnaBrPUCubqAWe50DaA==} dependencies: typewise-core: 1.2.0 dev: true - /bytewise/1.1.0: + /bytewise@1.1.0: resolution: {integrity: sha512-rHuuseJ9iQ0na6UDhnrRVDh8YnWVlU6xM3VH6q/+yHDeUH2zIhUzP+2/h3LIrhLDBtTqzWpE3p3tP/boefskKQ==} dependencies: bytewise-core: 1.2.3 typewise: 1.0.3 dev: true - /cache-base/1.0.1: + /cache-base@1.0.1: resolution: {integrity: sha512-AKcdTnFSWATd5/GCPRxr2ChwIJ85CeyrEyjRHlKxQ56d4XJMGym0uAiKn0xbLOGOl3+yRpOTi484dVCEc5AUzQ==} engines: {node: '>=0.10.0'} dependencies: @@ -3361,12 +3415,12 @@ packages: unset-value: 1.0.0 dev: true - /cacheable-lookup/6.1.0: + /cacheable-lookup@6.1.0: resolution: {integrity: sha512-KJ/Dmo1lDDhmW2XDPMo+9oiy/CeqosPguPCrgcVzKyZrL6pM1gU2GmPY/xo6OQPTUaA/c0kwHuywB4E6nmT9ww==} engines: {node: '>=10.6.0'} dev: true - /cacheable-request/6.1.0: + /cacheable-request@6.1.0: resolution: {integrity: sha512-Oj3cAGPCqOZX7Rz64Uny2GYAZNliQSqfbePrgAQ1wKAihYmCUnraBtJtKcGR4xz7wF+LoJC+ssFZvv5BgF9Igg==} engines: {node: '>=8'} dependencies: @@ -3379,7 +3433,7 @@ packages: responselike: 1.0.2 dev: true - /cacheable-request/7.0.2: + /cacheable-request@7.0.2: resolution: {integrity: sha512-pouW8/FmiPQbuGpkXQ9BAPv/Mo5xDGANgSNXzTzJ8DrKGuXOssM4wIQRjfanNRh3Yu5cfYPvcorqbhg2KIJtew==} engines: {node: '>=8'} dependencies: @@ -3392,66 +3446,66 @@ packages: responselike: 2.0.1 dev: true - /cachedown/1.0.0: + /cachedown@1.0.0: resolution: {integrity: sha512-t+yVk82vQWCJF3PsWHMld+jhhjkkWjcAzz8NbFx1iULOXWl8Tm/FdM4smZNVw3MRr0X+lVTx9PKzvEn4Ng19RQ==} dependencies: abstract-leveldown: 2.7.2 lru-cache: 3.2.0 dev: true - /call-bind/1.0.2: + /call-bind@1.0.2: resolution: {integrity: sha512-7O+FbCihrB5WGbFYesctwmTKae6rOiIzmz1icreWJ+0aA7LJfuqhEso2T9ncpcFtzMQtzXf2QGGueWJGTYsqrA==} dependencies: function-bind: 1.1.1 get-intrinsic: 1.1.3 dev: true - /callsites/3.1.0: + /callsites@3.1.0: resolution: {integrity: sha512-P8BjAsXvZS+VIDUI11hHCQEv74YT67YUi5JJFNWIqL235sBmjX4+qx9Muvls5ivyNENctx46xQLQ3aTuE7ssaQ==} engines: {node: '>=6'} dev: true - /camel-case/3.0.0: + /camel-case@3.0.0: resolution: {integrity: sha512-+MbKztAYHXPr1jNTSKQF52VpcFjwY5RkR7fxksV8Doo4KAYc5Fl4UJRgthBbTmEx8C54DqahhbLJkDwjI3PI/w==} dependencies: no-case: 2.3.2 upper-case: 1.1.3 dev: true - /camelcase/3.0.0: + /camelcase@3.0.0: resolution: {integrity: sha512-4nhGqUkc4BqbBBB4Q6zLuD7lzzrHYrjKGeYaEji/3tFR5VdJu9v+LilhGIVe8wxEJPPOeWo7eg8dwY13TZ1BNg==} engines: {node: '>=0.10.0'} dev: true - /camelcase/4.1.0: + /camelcase@4.1.0: resolution: {integrity: sha512-FxAv7HpHrXbh3aPo4o2qxHay2lkLY3x5Mw3KeE4KQE8ysVfziWeRZDwcjauvwBSGEC/nXUPzZy8zeh4HokqOnw==} engines: {node: '>=4'} dev: true - /camelcase/5.3.1: + /camelcase@5.3.1: resolution: {integrity: sha512-L28STB170nwWS63UjtlEOE3dldQApaJXZkOI1uMFfzf3rRuPegHaHesyee+YxQ+W6SvRDQV6UrdOdRiR153wJg==} engines: {node: '>=6'} dev: true - /camelcase/6.3.0: + /camelcase@6.3.0: resolution: {integrity: sha512-Gmy6FhYlCY7uOElZUSbxo2UCDH8owEk996gkbrpsgGtrJLM3J7jGxl9Ic7Qwwj4ivOE5AWZWRMecDdF7hqGjFA==} engines: {node: '>=10'} dev: true - /caniuse-lite/1.0.30001414: + /caniuse-lite@1.0.30001414: resolution: {integrity: sha512-t55jfSaWjCdocnFdKQoO+d2ct9C59UZg4dY3OnUlSZ447r8pUtIKdp0hpAzrGFultmTC+Us+KpKi4GZl/LXlFg==} dev: true - /caseless/0.12.0: + /caseless@0.12.0: resolution: {integrity: sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw==} dev: true - /catering/2.1.1: + /catering@2.1.1: resolution: {integrity: sha512-K7Qy8O9p76sL3/3m7/zLKbRkyOlSZAgzEaLhyj2mXS8PsCud2Eo4hAb8aLtZqHh0QGqLcb9dlJSu6lHRVENm1w==} engines: {node: '>=6'} dev: true - /cbor/5.2.0: + /cbor@5.2.0: resolution: {integrity: sha512-5IMhi9e1QU76ppa5/ajP1BmMWZ2FHkhAhjeVKQ/EFCgYSEaeVaoGtL7cxJskf9oCCk+XjzaIdc3IuU/dbA/o2A==} engines: {node: '>=6.0.0'} dependencies: @@ -3459,14 +3513,14 @@ packages: nofilter: 1.0.4 dev: true - /cbor/8.1.0: + /cbor@8.1.0: resolution: {integrity: sha512-DwGjNW9omn6EwP70aXsn7FQJx5kO12tX0bZkaTjzdVFM6/7nhA4t0EENocKGx6D2Bch9PE2KzCUf5SceBdeijg==} engines: {node: '>=12.19'} dependencies: nofilter: 3.1.0 dev: true - /chai-bn/0.2.2_bn.js@4.12.0+chai@4.3.6: + /chai-bn@0.2.2(bn.js@4.12.0)(chai@4.3.6): resolution: {integrity: sha512-MzjelH0p8vWn65QKmEq/DLBG1Hle4WeyqT79ANhXZhn/UxRWO0OogkAxi5oGGtfzwU9bZR8mvbvYdoqNVWQwFg==} peerDependencies: bn.js: ^4.11.0 @@ -3476,7 +3530,7 @@ packages: chai: 4.3.6 dev: true - /chai/4.3.6: + /chai@4.3.6: resolution: {integrity: sha512-bbcp3YfHCUzMOvKqsztczerVgBKSsEijCySNlHHbX3VG1nskvqjz5Rfso1gGwD6w6oOV3eI60pKuMOV5MV7p3Q==} engines: {node: '>=4'} dependencies: @@ -3488,7 +3542,7 @@ packages: pathval: 1.1.1 type-detect: 4.0.8 - /chalk/1.1.3: + /chalk@1.1.3: resolution: {integrity: sha512-U3lRVLMSlsCfjqYPbLyVv11M9CPW4I728d6TCKMAOJueEeB9/8o+eSsMnxPJD+Q+K909sdESg7C+tIkoH6on1A==} engines: {node: '>=0.10.0'} dependencies: @@ -3499,7 +3553,7 @@ packages: supports-color: 2.0.0 dev: true - /chalk/2.4.2: + /chalk@2.4.2: resolution: {integrity: sha512-Mti+f9lpJNcwF4tWV8/OrTTtF1gZi+f8FqlyAdouralcFWFQWF2+NgCHShjkCb+IFBLq9buZwE1xckQU4peSuQ==} engines: {node: '>=4'} dependencies: @@ -3508,7 +3562,7 @@ packages: supports-color: 5.5.0 dev: true - /chalk/4.1.2: + /chalk@4.1.2: resolution: {integrity: sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==} engines: {node: '>=10'} dependencies: @@ -3516,7 +3570,7 @@ packages: supports-color: 7.2.0 dev: true - /change-case/3.0.2: + /change-case@3.0.2: resolution: {integrity: sha512-Mww+SLF6MZ0U6kdg11algyKd5BARbyM4TbFBepwowYSR5ClfQGCGtxNXgykpN0uF/bstWeaGDT4JWaDh8zWAHA==} dependencies: camel-case: 3.0.0 @@ -3539,20 +3593,20 @@ packages: upper-case-first: 1.1.2 dev: true - /charenc/0.0.2: + /charenc@0.0.2: resolution: {integrity: sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA==} dev: true - /check-error/1.0.2: + /check-error@1.0.2: resolution: {integrity: sha512-BrgHpW9NURQgzoNyjfq0Wu6VFO6D7IZEmJNdtgNqpzGG8RuNFHt2jQxWlAs4HMe119chBnv+34syEZtc6IhLtA==} - /checkpoint-store/1.1.0: + /checkpoint-store@1.1.0: resolution: {integrity: sha512-J/NdY2WvIx654cc6LWSq/IYFFCUf75fFTgwzFnmbqyORH4MwgiQCgswLLKBGzmsyTI5V7i5bp/So6sMbDWhedg==} dependencies: functional-red-black-tree: 1.0.1 dev: true - /cheerio-select/2.1.0: + /cheerio-select@2.1.0: resolution: {integrity: sha512-9v9kG0LvzrlcungtnJtpGNxY+fzECQKhK4EGJX2vByejiMX84MFNQw4UxPJl3bFbTMw+Dfs37XaIkCwTZfLh4g==} dependencies: boolbase: 1.0.0 @@ -3563,7 +3617,7 @@ packages: domutils: 3.0.1 dev: true - /cheerio/1.0.0-rc.12: + /cheerio@1.0.0-rc.12: resolution: {integrity: sha512-VqR8m68vM46BNnuZ5NtnGBKIE/DfN0cRIzg9n40EIq9NOv90ayxLBXA8fXC5gquFRGJSTRqBq25Jt2ECLR431Q==} engines: {node: '>= 6'} dependencies: @@ -3576,7 +3630,7 @@ packages: parse5-htmlparser2-tree-adapter: 7.0.0 dev: true - /chokidar/3.3.0: + /chokidar@3.3.0: resolution: {integrity: sha512-dGmKLDdT3Gdl7fBUe8XK+gAtGmzy5Fn0XkkWQuYxGIgWVPPse2CxFA5mtrlD0TOHaHjEUqkWNyP1XdHoJES/4A==} engines: {node: '>= 8.10.0'} dependencies: @@ -3591,7 +3645,7 @@ packages: fsevents: 2.1.3 dev: true - /chokidar/3.5.3: + /chokidar@3.5.3: resolution: {integrity: sha512-Dr3sfKRP6oTcjf2JmUmFJfeVMvXBdegxB0iVQ5eb2V10uFJUCAS8OByZdVAyVb8xXNz3GjjTgj9kLWsZTqE6kw==} engines: {node: '>= 8.10.0'} dependencies: @@ -3606,15 +3660,15 @@ packages: fsevents: 2.3.2 dev: true - /chownr/1.1.4: + /chownr@1.1.4: resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} dev: true - /ci-info/2.0.0: + /ci-info@2.0.0: resolution: {integrity: sha512-5tK7EtrZ0N+OLFMthtqOj4fI2Jeb88C4CAZPu25LDVUgXJ0A3Js4PMGqrn0JU1W0Mh1/Z8wZzYPxqUrXeBboCQ==} dev: true - /cids/0.7.5: + /cids@0.7.5: resolution: {integrity: sha512-zT7mPeghoWAu+ppn8+BS1tQ5qGmbMfB4AregnQjA/qHY3GC1m1ptI9GkWNlgeu38r7CuRdXB47uY2XgAYt6QVA==} engines: {node: '>=4.0.0', npm: '>=3.0.0'} deprecated: This module has been superseded by the multiformats module @@ -3626,18 +3680,18 @@ packages: multihashes: 0.4.21 dev: true - /cipher-base/1.0.4: + /cipher-base@1.0.4: resolution: {integrity: sha512-Kkht5ye6ZGmwv40uUDZztayT2ThLQGfnj/T71N/XzeZeo3nf8foyW7zGTsPYkEya3m5f3cAypH+qe7YOrM1U2Q==} dependencies: inherits: 2.0.4 safe-buffer: 5.2.1 dev: true - /class-is/1.1.0: + /class-is@1.1.0: resolution: {integrity: sha512-rhjH9AG1fvabIDoGRVH587413LPjTZgmDF9fOFCbFJQV4yuocX1mHxxvXI4g3cGwbVY9wAYIoKlg1N79frJKQw==} dev: true - /class-utils/0.3.6: + /class-utils@0.3.6: resolution: {integrity: sha512-qOhPa/Fj7s6TY8H8esGu5QNpMMQxz79h+urzrNYN6mn+9BnxlDGf5QZ+XeCDsxSjPqsSR56XOZOJmpeurnLMeg==} engines: {node: '>=0.10.0'} dependencies: @@ -3647,7 +3701,7 @@ packages: static-extend: 0.1.2 dev: true - /classic-level/1.2.0: + /classic-level@1.2.0: resolution: {integrity: sha512-qw5B31ANxSluWz9xBzklRWTUAJ1SXIdaVKTVS7HcTGKOAmExx65Wo5BUICW+YGORe2FOUaDghoI9ZDxj82QcFg==} engines: {node: '>=12'} requiresBuild: true @@ -3659,12 +3713,12 @@ packages: node-gyp-build: 4.5.0 dev: true - /clean-stack/2.2.0: + /clean-stack@2.2.0: resolution: {integrity: sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==} engines: {node: '>=6'} dev: true - /cli-table3/0.5.1: + /cli-table3@0.5.1: resolution: {integrity: sha512-7Qg2Jrep1S/+Q3EceiZtQcDPWxhAvBw+ERf1162v4sikJrvojMHFqXt8QIVha8UlH9rgU0BeWPytZ9/TzYqlUw==} engines: {node: '>=6'} dependencies: @@ -3674,7 +3728,7 @@ packages: colors: 1.4.0 dev: true - /cli-table3/0.6.3: + /cli-table3@0.6.3: resolution: {integrity: sha512-w5Jac5SykAeZJKntOxJCrm63Eg5/4dhMWIcuTbo9rpE+brgaSZo0RuNJZeOyMgsUdhDeojvgyQLmjI+K50ZGyg==} engines: {node: 10.* || >= 12.*} dependencies: @@ -3683,7 +3737,7 @@ packages: '@colors/colors': 1.5.0 dev: true - /cliui/3.2.0: + /cliui@3.2.0: resolution: {integrity: sha512-0yayqDxWQbqk3ojkYqUKqaAQ6AfNKeKWRNA8kR0WXzAsdHpP4BIaOmMAG87JGuO6qcobyW4GjxHd9PmhEd+T9w==} dependencies: string-width: 1.0.2 @@ -3691,7 +3745,7 @@ packages: wrap-ansi: 2.1.0 dev: true - /cliui/5.0.0: + /cliui@5.0.0: resolution: {integrity: sha512-PYeGSEmmHM6zvoef2w8TPzlrnNpXIjTipYK780YswmIP9vjxmd6Y2a3CB2Ks6/AU8NHjZugXvo8w3oWM2qnwXA==} dependencies: string-width: 3.1.0 @@ -3699,7 +3753,7 @@ packages: wrap-ansi: 5.1.0 dev: true - /cliui/7.0.4: + /cliui@7.0.4: resolution: {integrity: sha512-OcRE68cOsVMXp1Yvonl/fzkQOyjLSu/8bhPDfQt0e0/Eb283TKP20Fs2MqoPsr9SwA595rRCA+QMzYc9nBP+JQ==} dependencies: string-width: 4.2.3 @@ -3707,28 +3761,28 @@ packages: wrap-ansi: 7.0.0 dev: true - /clone-response/1.0.2: + /clone-response@1.0.2: resolution: {integrity: sha512-yjLXh88P599UOyPTFX0POsd7WxnbsVsGohcwzHOLspIhhpalPw1BcqED8NblyZLKcGrL8dTgMlcaZxV2jAD41Q==} dependencies: mimic-response: 1.0.1 dev: true - /clone/2.1.2: + /clone@2.1.2: resolution: {integrity: sha512-3Pe/CF1Nn94hyhIYpjtiLhdCoEoz0DqQ+988E9gmeEdQZlojxnOb74wctFyuwWQHzqyf9X7C7MG8juUpqBJT8w==} engines: {node: '>=0.8'} dev: true - /code-error-fragment/0.0.230: + /code-error-fragment@0.0.230: resolution: {integrity: sha512-cadkfKp6932H8UkhzE/gcUqhRMNf8jHzkAN7+5Myabswaghu4xABTgPHDCjW+dBAJxj/SpkTYokpzDqY4pCzQw==} engines: {node: '>= 4'} dev: true - /code-point-at/1.1.0: + /code-point-at@1.1.0: resolution: {integrity: sha512-RpAVKQA5T63xEj6/giIbUEtZwJ4UFIc3ZtvEkiaUERylqe8xb5IvqcgOurZLahv93CLKfxcw5YI+DZcUBRyLXA==} engines: {node: '>=0.10.0'} dev: true - /collection-visit/1.0.0: + /collection-visit@1.0.0: resolution: {integrity: sha512-lNkKvzEeMBBjUGHZ+q6z9pSJla0KWAQPvtzhEV9+iGyQYG+pBpl7xKDhxoNSOZH2hhv0v5k0y2yAM4o4SjoSkw==} engines: {node: '>=0.10.0'} dependencies: @@ -3736,44 +3790,44 @@ packages: object-visit: 1.0.1 dev: true - /color-convert/1.9.3: + /color-convert@1.9.3: resolution: {integrity: sha512-QfAUtd+vFdAtFQcC8CCyYt1fYWxSqAiK2cSD6zDB8N3cpsEBAvRxp9zOGg6G/SHHJYAT88/az/IuDGALsNVbGg==} dependencies: color-name: 1.1.3 dev: true - /color-convert/2.0.1: + /color-convert@2.0.1: resolution: {integrity: sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==} engines: {node: '>=7.0.0'} dependencies: color-name: 1.1.4 dev: true - /color-name/1.1.3: + /color-name@1.1.3: resolution: {integrity: sha512-72fSenhMw2HZMTVHeCA9KCmpEIbzWiQsjN+BHcBbS9vr1mtt+vJjPdksIBNUmKAW8TFUDPJK5SUU3QhE9NEXDw==} dev: true - /color-name/1.1.4: + /color-name@1.1.4: resolution: {integrity: sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==} dev: true - /colors/1.4.0: + /colors@1.4.0: resolution: {integrity: sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA==} engines: {node: '>=0.1.90'} dev: true - /combined-stream/1.0.8: + /combined-stream@1.0.8: resolution: {integrity: sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==} engines: {node: '>= 0.8'} dependencies: delayed-stream: 1.0.0 dev: true - /command-exists/1.2.9: + /command-exists@1.2.9: resolution: {integrity: sha512-LTQ/SGc+s0Xc0Fu5WaKnR0YiygZkm9eKFvyS+fRsU7/ZWFF8ykFM6Pc9aCVf1+xasOOZpO3BAVgVrKvsqKHV7w==} dev: true - /command-line-args/4.0.7: + /command-line-args@4.0.7: resolution: {integrity: sha512-aUdPvQRAyBvQd2n7jXcsMDz68ckBJELXNzBybCHOibUWEg0mWTnaYCSRU8h9R+aNRSvDihJtssSRCiDRpLaezA==} hasBin: true dependencies: @@ -3782,7 +3836,7 @@ packages: typical: 2.6.1 dev: true - /command-line-args/5.2.1: + /command-line-args@5.2.1: resolution: {integrity: sha512-H4UfQhZyakIjC74I9d34fGYDwk3XpSr17QhEd0Q3I9Xq1CETHo4Hcuo87WyWHpAF1aSLjLRf5lD9ZGX2qStUvg==} engines: {node: '>=4.0.0'} dependencies: @@ -3792,7 +3846,7 @@ packages: typical: 4.0.0 dev: true - /command-line-usage/6.1.3: + /command-line-usage@6.1.3: resolution: {integrity: sha512-sH5ZSPr+7UStsloltmDh7Ce5fb8XPlHyoPzTpyyMuYCtervL65+ubVZ6Q61cFtFl62UyJlc8/JwERRbAFPUqgw==} engines: {node: '>=8.0.0'} dependencies: @@ -3802,28 +3856,28 @@ packages: typical: 5.2.0 dev: true - /commander/10.0.1: + /commander@10.0.1: resolution: {integrity: sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug==} engines: {node: '>=14'} dev: true - /commander/3.0.2: + /commander@3.0.2: resolution: {integrity: sha512-Gar0ASD4BDyKC4hl4DwHqDrmvjoxWKZigVnAbn5H1owvm4CxCPdb0HQDehwNYMJpla5+M2tPmPARzhtYuwpHow==} dev: true - /compare-versions/5.0.3: + /compare-versions@5.0.3: resolution: {integrity: sha512-4UZlZP8Z99MGEY+Ovg/uJxJuvoXuN4M6B3hKaiackiHrgzQFEe3diJi1mf1PNHbFujM7FvLrK2bpgIaImbtZ1A==} dev: true - /component-emitter/1.3.0: + /component-emitter@1.3.0: resolution: {integrity: sha512-Rd3se6QB+sO1TwqZjscQrurpEPIfO0/yYnSin6Q/rD3mOutHvUrCAhJub3r90uNb+SESBuE0QYoB90YdfatsRg==} dev: true - /concat-map/0.0.1: + /concat-map@0.0.1: resolution: {integrity: sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg==} dev: true - /concat-stream/1.6.2: + /concat-stream@1.6.2: resolution: {integrity: sha512-27HBghJxjiZtIk3Ycvn/4kbJk/1uZuJFfuPEns6LaEvpvG1f0hTea8lilrouyo9mVc2GWdcEZ8OLoGmSADlrCw==} engines: {'0': node >= 0.8} dependencies: @@ -3833,21 +3887,21 @@ packages: typedarray: 0.0.6 dev: true - /constant-case/2.0.0: + /constant-case@2.0.0: resolution: {integrity: sha512-eS0N9WwmjTqrOmR3o83F5vW8Z+9R1HnVz3xmzT2PMFug9ly+Au/fxRWlEBSb6LcZwspSsEn9Xs1uw9YgzAg1EQ==} dependencies: snake-case: 2.1.0 upper-case: 1.1.3 dev: true - /content-disposition/0.5.3: + /content-disposition@0.5.3: resolution: {integrity: sha512-ExO0774ikEObIAEV9kDo50o+79VCUdEB6n6lzKgGwupcVeRlhrj3qGAfwq8G6uBJjkqLrhT0qEYFcWng8z1z0g==} engines: {node: '>= 0.6'} dependencies: safe-buffer: 5.1.2 dev: true - /content-hash/2.5.2: + /content-hash@2.5.2: resolution: {integrity: sha512-FvIQKy0S1JaWV10sMsA7TRx8bpU+pqPkhbsfvOJAdjRXvYxEckAwQWGwtRjiaJfh+E0DvcWUGqcdjwMGFjsSdw==} dependencies: cids: 0.7.5 @@ -3855,65 +3909,65 @@ packages: multihashes: 0.4.21 dev: true - /content-type/1.0.4: + /content-type@1.0.4: resolution: {integrity: sha512-hIP3EEPs8tB9AT1L+NUqtwOAps4mk2Zob89MWXMHjHWg9milF/j4osnnQLXBCBFBk/tvIG/tUc9mOUJiPBhPXA==} engines: {node: '>= 0.6'} dev: true - /convert-source-map/1.8.0: + /convert-source-map@1.8.0: resolution: {integrity: sha512-+OQdjP49zViI/6i7nIJpA8rAl4sV/JdPfU9nZs3VqOwGIgizICvuN2ru6fMd+4llL0tar18UYJXfZ/TWtmhUjA==} dependencies: safe-buffer: 5.1.2 dev: true - /cookie-signature/1.0.6: + /cookie-signature@1.0.6: resolution: {integrity: sha512-QADzlaHc8icV8I7vbaJXJwod9HWYp8uCqf1xa4OfNu1T7JVxQIrUgOWtHdNDtPiywmFbiS12VjotIXLrKM3orQ==} dev: true - /cookie/0.4.0: + /cookie@0.4.0: resolution: {integrity: sha512-+Hp8fLp57wnUSt0tY0tHEXh4voZRDnoIrZPqlo3DPiI4y9lwg/jqx+1Om94/W6ZaPDOUbnjOt/99w66zk+l1Xg==} engines: {node: '>= 0.6'} dev: true - /cookie/0.4.2: + /cookie@0.4.2: resolution: {integrity: sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA==} engines: {node: '>= 0.6'} dev: true - /cookiejar/2.1.2: + /cookiejar@2.1.2: resolution: {integrity: sha512-Mw+adcfzPxcPeI+0WlvRrr/3lGVO0bD75SxX6811cxSh1Wbxx7xZBGK1eVtDf6si8rg2lhnUjsVLMFMfbRIuwA==} dev: true - /copy-descriptor/0.1.1: + /copy-descriptor@0.1.1: resolution: {integrity: sha512-XgZ0pFcakEUlbwQEVNg3+QAis1FyTL3Qel9FYy8pSkQqoG3PNoT0bOCQtOXcOkur21r2Eq2kI+IE+gsmAEVlYw==} engines: {node: '>=0.10.0'} dev: true - /core-js-pure/3.25.3: + /core-js-pure@3.25.3: resolution: {integrity: sha512-T/7qvgv70MEvRkZ8p6BasLZmOVYKzOaWNBEHAU8FmveCJkl4nko2quqPQOmy6AJIp5MBanhz9no3A94NoRb0XA==} requiresBuild: true dev: true - /core-js/2.6.12: + /core-js@2.6.12: resolution: {integrity: sha512-Kb2wC0fvsWfQrgk8HU5lW6U/Lcs8+9aaYcy4ZFc6DDlo4nZ7n70dEgE5rtR0oG6ufKDUnrwfWL1mXR5ljDatrQ==} deprecated: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js. requiresBuild: true dev: true - /core-js/3.30.1: + /core-js@3.30.1: resolution: {integrity: sha512-ZNS5nbiSwDTq4hFosEDqm65izl2CWmLz0hARJMyNQBgkUZMIF51cQiMvIQKA6hvuaeWxQDP3hEedM1JZIgTldQ==} requiresBuild: true dev: true - /core-util-is/1.0.2: + /core-util-is@1.0.2: resolution: {integrity: sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ==} dev: true - /core-util-is/1.0.3: + /core-util-is@1.0.3: resolution: {integrity: sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==} dev: true - /cors/2.8.5: + /cors@2.8.5: resolution: {integrity: sha512-KIHbLJqu73RGr/hnbrO9uBeixNGuvSQjul/jdFvS/KFSIH1hWVd1ng7zOHx+YrEfInLG7q4n6GHQ9cDtxv/P6g==} engines: {node: '>= 0.10'} dependencies: @@ -3921,7 +3975,7 @@ packages: vary: 1.1.2 dev: true - /cosmiconfig/8.2.0: + /cosmiconfig@8.2.0: resolution: {integrity: sha512-3rTMnFJA1tCOPwRxtgF4wd7Ab2qvDbL8jX+3smjIbS4HlZBagTlpERbdN7iAbWlrfxE3M8c27kTwTawQ7st+OQ==} engines: {node: '>=14'} dependencies: @@ -3931,20 +3985,20 @@ packages: path-type: 4.0.0 dev: true - /crc-32/1.2.2: + /crc-32@1.2.2: resolution: {integrity: sha512-ROmzCKrTnOwybPcJApAA6WBWij23HVfGVNKqqrZpuyZOHqK2CwHSvpGuyt/UNNvaIjEd8X5IFGp4Mh+Ie1IHJQ==} engines: {node: '>=0.8'} hasBin: true dev: true - /create-ecdh/4.0.3: + /create-ecdh@4.0.3: resolution: {integrity: sha512-GbEHQPMOswGpKXM9kCWVrremUcBmjteUaQ01T9rkKCPDXfUHX0IoP9LpHYo2NPFampa4e+/pFDc3jQdxrxQLaw==} dependencies: bn.js: 4.12.0 elliptic: 6.5.4 dev: true - /create-hash/1.2.0: + /create-hash@1.2.0: resolution: {integrity: sha512-z00bCGNHDG8mHAkP7CtT1qVu+bFQUPjYq/4Iv3C3kWjTFV10zIjfSoeqXo9Asws8gwSHDGj/hl2u4OGIjapeCg==} dependencies: cipher-base: 1.0.4 @@ -3954,7 +4008,7 @@ packages: sha.js: 2.4.11 dev: true - /create-hmac/1.1.7: + /create-hmac@1.1.7: resolution: {integrity: sha512-MJG9liiZ+ogc4TzUwuvbER1JRdgvUFSB5+VR/g5h82fGaIRWMWddtKBHi7/sVhfjQZ6SehlyhvQYrcYkaUIpLg==} dependencies: cipher-base: 1.0.4 @@ -3965,11 +4019,11 @@ packages: sha.js: 2.4.11 dev: true - /create-require/1.1.1: + /create-require@1.1.1: resolution: {integrity: sha512-dcKFX3jn0MpIaXjisoRvexIJVEKzaq7z2rZKxf+MSr9TkdmHmsU4m2lcLojrj/FHl8mk5VxMmYA+ftRkP/3oKQ==} dev: true - /cross-fetch/2.2.6: + /cross-fetch@2.2.6: resolution: {integrity: sha512-9JZz+vXCmfKUZ68zAptS7k4Nu8e2qcibe7WVZYps7sAgk5R8GYTc+T1WR0v1rlP9HxgARmOX1UTIJZFytajpNA==} dependencies: node-fetch: 2.6.7 @@ -3978,7 +4032,7 @@ packages: - encoding dev: true - /cross-fetch/3.1.5: + /cross-fetch@3.1.5: resolution: {integrity: sha512-lvb1SBsI0Z7GDwmuid+mU3kWVBwTVUbe7S0H52yaaAdQOXq2YktTCZdlAcNKFzE6QtRz0snpw9bNiPeOIkkQvw==} dependencies: node-fetch: 2.6.7 @@ -3986,7 +4040,7 @@ packages: - encoding dev: true - /cross-spawn/6.0.5: + /cross-spawn@6.0.5: resolution: {integrity: sha512-eTVLrBSt7fjbDygz805pMnstIs2VTBNkRm0qxZd+M7A5XDdxVRWO5MxGBXZhjY4cqLYLdtrGqRf8mBPmzwSpWQ==} engines: {node: '>=4.8'} dependencies: @@ -3997,7 +4051,7 @@ packages: which: 1.3.1 dev: true - /cross-spawn/7.0.3: + /cross-spawn@7.0.3: resolution: {integrity: sha512-iRDPJKUPVEND7dHPO8rkbOnPpyDygcDFtWjpeWNCgy8WP2rXcxXL8TskReQl6OrB2G7+UJrags1q15Fudc7G6w==} engines: {node: '>= 8'} dependencies: @@ -4006,11 +4060,11 @@ packages: which: 2.0.2 dev: true - /crypt/0.0.2: + /crypt@0.0.2: resolution: {integrity: sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow==} dev: true - /crypto-addr-codec/0.1.7: + /crypto-addr-codec@0.1.7: resolution: {integrity: sha512-X4hzfBzNhy4mAc3UpiXEC/L0jo5E8wAa9unsnA8nNXYzXjCcGk83hfC5avJWCSGT8V91xMnAS9AKMHmjw5+XCg==} dependencies: base-x: 3.0.9 @@ -4022,7 +4076,7 @@ packages: sha3: 2.1.4 dev: true - /crypto-browserify/3.12.0: + /crypto-browserify@3.12.0: resolution: {integrity: sha512-fz4spIh+znjO2VjL+IdhEpRJ3YN6sMzITSBijk6FK2UvTqruSQW+/cCZTSNsMiZNvUeq0CqurF+dAbyiGOY6Wg==} dependencies: browserify-cipher: 1.0.1 @@ -4038,7 +4092,7 @@ packages: randomfill: 1.0.4 dev: true - /css-select/5.1.0: + /css-select@5.1.0: resolution: {integrity: sha512-nwoRF1rvRRnnCqqY7updORDsuqKzqYJ28+oSMaJMMgOauh3fvwHqMS7EZpIPqK8GL+g9mKxF1vP/ZjSeNjEVHg==} dependencies: boolbase: 1.0.0 @@ -4048,30 +4102,30 @@ packages: nth-check: 2.1.1 dev: true - /css-what/6.1.0: + /css-what@6.1.0: resolution: {integrity: sha512-HTUrgRJ7r4dsZKU6GjmpfRK1O76h97Z8MfS1G0FozR+oF2kG6Vfe8JE6zwrkbxigziPHinCJ+gCPjA9EaBDtRw==} engines: {node: '>= 6'} dev: true - /d/1.0.1: + /d@1.0.1: resolution: {integrity: sha512-m62ShEObQ39CfralilEQRjH6oAMtNCV1xJyEx5LpRYUVN+EviphDgUc/F3hnYbADmkiNs67Y+3ylmlG7Lnu+FA==} dependencies: es5-ext: 0.10.62 type: 1.2.0 dev: true - /dashdash/1.14.1: + /dashdash@1.14.1: resolution: {integrity: sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g==} engines: {node: '>=0.10'} dependencies: assert-plus: 1.0.0 dev: true - /death/1.1.0: + /death@1.1.0: resolution: {integrity: sha512-vsV6S4KVHvTGxbEcij7hkWRv0It+sGGWVOM67dQde/o5Xjnr+KmLjxWJii2uEObIrt1CcM9w0Yaovx+iOlIL+w==} dev: true - /debug/2.6.9: + /debug@2.6.9: resolution: {integrity: sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA==} peerDependencies: supports-color: '*' @@ -4082,19 +4136,7 @@ packages: ms: 2.0.0 dev: true - /debug/3.2.6: - resolution: {integrity: sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==} - deprecated: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) - peerDependencies: - supports-color: '*' - peerDependenciesMeta: - supports-color: - optional: true - dependencies: - ms: 2.1.3 - dev: true - - /debug/3.2.6_supports-color@6.0.0: + /debug@3.2.6(supports-color@6.0.0): resolution: {integrity: sha512-mel+jf7nrtEl5Pn1Qx46zARXKDpBbvzezse7p7LqINmdoIk8PYP5SySaxEmYv6TZ0JyEKA1hsCId6DIhgITtWQ==} deprecated: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797) peerDependencies: @@ -4107,7 +4149,7 @@ packages: supports-color: 6.0.0 dev: true - /debug/3.2.7: + /debug@3.2.7: resolution: {integrity: sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==} peerDependencies: supports-color: '*' @@ -4118,19 +4160,7 @@ packages: ms: 2.1.3 dev: true - /debug/4.3.4: - resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} - engines: {node: '>=6.0'} - peerDependencies: - supports-color: '*' - peerDependenciesMeta: - supports-color: - optional: true - dependencies: - ms: 2.1.2 - dev: true - - /debug/4.3.4_supports-color@8.1.1: + /debug@4.3.4(supports-color@8.1.1): resolution: {integrity: sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ==} engines: {node: '>=6.0'} peerDependencies: @@ -4143,49 +4173,49 @@ packages: supports-color: 8.1.1 dev: true - /decamelize/1.2.0: + /decamelize@1.2.0: resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} engines: {node: '>=0.10.0'} dev: true - /decamelize/4.0.0: + /decamelize@4.0.0: resolution: {integrity: sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ==} engines: {node: '>=10'} dev: true - /decode-uri-component/0.2.0: + /decode-uri-component@0.2.0: resolution: {integrity: sha512-hjf+xovcEn31w/EUYdTXQh/8smFL/dzYjohQGEIgjyNavaJfBY2p5F527Bo1VPATxv0VYTUC2bOcXvqFwk78Og==} engines: {node: '>=0.10'} dev: true - /decompress-response/3.3.0: + /decompress-response@3.3.0: resolution: {integrity: sha512-BzRPQuY1ip+qDonAOz42gRm/pg9F768C+npV/4JOsxRC2sq+Rlk+Q4ZCAsOhnIaMrgarILY+RMUIvMmmX1qAEA==} engines: {node: '>=4'} dependencies: mimic-response: 1.0.1 dev: true - /decompress-response/6.0.0: + /decompress-response@6.0.0: resolution: {integrity: sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==} engines: {node: '>=10'} dependencies: mimic-response: 3.1.0 dev: true - /deep-eql/3.0.1: + /deep-eql@3.0.1: resolution: {integrity: sha512-+QeIQyN5ZuO+3Uk5DYh6/1eKO0m0YmJFGNmFHGACpf1ClL1nmlV/p4gNgbl2pJGxgXb4faqo6UE+M5ACEMyVcw==} engines: {node: '>=0.12'} dependencies: type-detect: 4.0.8 - /deep-equal-in-any-order/2.0.6: + /deep-equal-in-any-order@2.0.6: resolution: {integrity: sha512-RfnWHQzph10YrUjvWwhd15Dne8ciSJcZ3U6OD7owPwiVwsdE5IFSoZGg8rlwJD11ES+9H5y8j3fCofviRHOqLQ==} dependencies: lodash.mapvalues: 4.6.0 sort-any: 2.0.0 dev: true - /deep-equal/1.1.1: + /deep-equal@1.1.1: resolution: {integrity: sha512-yd9c5AdiqVcR+JjcwUQb9DkhJc8ngNr0MahEBGvDiJw8puWab2yZlh+nkasOnZP+EGTAP6rRp2JzJhJZzvNF8g==} dependencies: is-arguments: 1.0.4 @@ -4196,31 +4226,31 @@ packages: regexp.prototype.flags: 1.4.3 dev: true - /deep-extend/0.6.0: + /deep-extend@0.6.0: resolution: {integrity: sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==} engines: {node: '>=4.0.0'} dev: true - /deep-is/0.1.4: + /deep-is@0.1.4: resolution: {integrity: sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==} dev: true - /defer-to-connect/1.1.1: + /defer-to-connect@1.1.1: resolution: {integrity: sha512-J7thop4u3mRTkYRQ+Vpfwy2G5Ehoy82I14+14W4YMDLKdWloI9gSzRbV30s/NckQGVJtPkWNcW4oMAUigTdqiQ==} dev: true - /defer-to-connect/2.0.1: + /defer-to-connect@2.0.1: resolution: {integrity: sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg==} engines: {node: '>=10'} dev: true - /deferred-leveldown/1.2.2: + /deferred-leveldown@1.2.2: resolution: {integrity: sha512-uukrWD2bguRtXilKt6cAWKyoXrTSMo5m7crUdLfWQmu8kIm88w3QZoUL+6nhpfKVmhHANER6Re3sKoNoZ3IKMA==} dependencies: abstract-leveldown: 2.6.3 dev: true - /deferred-leveldown/4.0.2: + /deferred-leveldown@4.0.2: resolution: {integrity: sha512-5fMC8ek8alH16QiV0lTCis610D1Zt1+LA4MS4d63JgS32lrCjTFDUFz2ao09/j2I4Bqb5jL4FZYwu7Jz0XO1ww==} engines: {node: '>=6'} dependencies: @@ -4228,7 +4258,7 @@ packages: inherits: 2.0.4 dev: true - /define-properties/1.1.4: + /define-properties@1.1.4: resolution: {integrity: sha512-uckOqKcfaVvtBdsVkdPv3XjveQJsNQqmhXgRi8uhvWWuPYZCNlzT8qAyblUgNoXdHdjMTzAqeGjAoli8f+bzPA==} engines: {node: '>= 0.4'} dependencies: @@ -4236,21 +4266,21 @@ packages: object-keys: 1.1.1 dev: true - /define-property/0.2.5: + /define-property@0.2.5: resolution: {integrity: sha512-Rr7ADjQZenceVOAKop6ALkkRAmH1A4Gx9hV/7ZujPUN2rkATqFO0JZLZInbAjpZYoJ1gUx8MRMQVkYemcbMSTA==} engines: {node: '>=0.10.0'} dependencies: is-descriptor: 0.1.6 dev: true - /define-property/1.0.0: + /define-property@1.0.0: resolution: {integrity: sha512-cZTYKFWspt9jZsMscWo8sc/5lbPC9Q0N5nBLgb+Yd915iL3udB1uFgS3B8YCx66UVHq018DAVFoee7x+gxggeA==} engines: {node: '>=0.10.0'} dependencies: is-descriptor: 1.0.2 dev: true - /define-property/2.0.2: + /define-property@2.0.2: resolution: {integrity: sha512-jwK2UV4cnPpbcG7+VRARKTZPUWowwXA8bzH5NP6ud0oeAxyYPuGZUAC7hMugpCdz4BeSZl2Dl9k66CHJ/46ZYQ==} engines: {node: '>=0.10.0'} dependencies: @@ -4258,49 +4288,49 @@ packages: isobject: 3.0.1 dev: true - /defined/1.0.0: + /defined@1.0.0: resolution: {integrity: sha512-Y2caI5+ZwS5c3RiNDJ6u53VhQHv+hHKwhkI1iHvceKUHw9Df6EK2zRLfjejRgMuCuxK7PfSWIMwWecceVvThjQ==} dev: true - /delayed-stream/1.0.0: + /delayed-stream@1.0.0: resolution: {integrity: sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==} engines: {node: '>=0.4.0'} dev: true - /depd/1.1.2: + /depd@1.1.2: resolution: {integrity: sha512-7emPTl6Dpo6JRXOXjLRxck+FlLRX5847cLKEn00PLAgc3g2hTZZgr+e4c2v6QpSmLeFP3n5yUo7ft6avBK/5jQ==} engines: {node: '>= 0.6'} dev: true - /depd/2.0.0: + /depd@2.0.0: resolution: {integrity: sha512-g7nH6P6dyDioJogAAGprGpCtVImJhpPk/roCzdb3fIh61/s/nPsfR6onyMwkCAR/OlC3yBC0lESvUoQEAssIrw==} engines: {node: '>= 0.8'} dev: true - /des.js/1.0.1: + /des.js@1.0.1: resolution: {integrity: sha512-Q0I4pfFrv2VPd34/vfLrFOoRmlYj3OV50i7fskps1jZWK1kApMWWT9G6RRUeYedLcBDIhnSDaUvJMb3AhUlaEA==} dependencies: inherits: 2.0.4 minimalistic-assert: 1.0.1 dev: true - /destroy/1.0.4: + /destroy@1.0.4: resolution: {integrity: sha512-3NdhDuEXnfun/z7x9GOElY49LoqVHoGScmOKwmxhsS8N5Y+Z8KyPPDnaSzqWgYt/ji4mqwfTS34Htrk0zPIXVg==} dev: true - /detect-indent/4.0.0: + /detect-indent@4.0.0: resolution: {integrity: sha512-BDKtmHlOzwI7iRuEkhzsnPoi5ypEhWAJB5RvHWe1kMr06js3uK5B3734i3ui5Yd+wOJV1cpE4JnivPD283GU/A==} engines: {node: '>=0.10.0'} dependencies: repeating: 2.0.1 dev: true - /detect-indent/5.0.0: + /detect-indent@5.0.0: resolution: {integrity: sha512-rlpvsxUtM0PQvy9iZe640/IWwWYyBsTApREbA1pHOpmOUIl9MkP/U4z7vTtg4Oaojvqhxt7sdufnT0EzGaR31g==} engines: {node: '>=4'} dev: true - /detect-port/1.3.0: + /detect-port@1.3.0: resolution: {integrity: sha512-E+B1gzkl2gqxt1IhUzwjrxBKRqx1UzC3WLONHinn8S3T6lwV/agVCyitiFOsGJ/eYuEUBvD71MZHy3Pv1G9doQ==} engines: {node: '>= 4.2.1'} hasBin: true @@ -4311,22 +4341,22 @@ packages: - supports-color dev: true - /diff/3.5.0: + /diff@3.5.0: resolution: {integrity: sha512-A46qtFgd+g7pDZinpnwiRJtxbC1hpgf0uzP3iG89scHk0AUC7A1TGxf5OiiOUv/JMZR8GOt8hL900hV0bOy5xA==} engines: {node: '>=0.3.1'} dev: true - /diff/4.0.2: + /diff@4.0.2: resolution: {integrity: sha512-58lmxKSA4BNyLz+HHMUzlOEpg09FV+ev6ZMe3vJihgdxzgcwZ8VoEEPmALCZG9LmqfVoNMMKpttIYTVG6uDY7A==} engines: {node: '>=0.3.1'} dev: true - /diff/5.0.0: + /diff@5.0.0: resolution: {integrity: sha512-/VTCrvm5Z0JGty/BWHljh+BAiw3IK+2j87NGMu8Nwc/f48WoDAC395uomO9ZD117ZOBaHmkX1oyLvkVM/aIT3w==} engines: {node: '>=0.3.1'} dev: true - /diffie-hellman/5.0.3: + /diffie-hellman@5.0.3: resolution: {integrity: sha512-kqag/Nl+f3GwyK25fhUMYj81BUOrZ9IuJsjIcDE5icNM9FJHAVm3VcUDxdLPoQtTuUylWm6ZIknYJwwaPxsUzg==} dependencies: bn.js: 4.12.0 @@ -4334,27 +4364,27 @@ packages: randombytes: 2.1.0 dev: true - /difflib/0.2.4: + /difflib@0.2.4: resolution: {integrity: sha512-9YVwmMb0wQHQNr5J9m6BSj6fk4pfGITGQOOs+D9Fl+INODWFOfvhIU1hNv6GgR1RBoC/9NJcwu77zShxV0kT7w==} dependencies: heap: 0.2.6 dev: true - /dir-glob/3.0.1: + /dir-glob@3.0.1: resolution: {integrity: sha512-WkrWp9GR4KXfKGYzOLmTuGVi1UWFfws377n9cc55/tb6DuqyF6pcQ5AbiHEshaDpY9v6oaSr2XCDidGmMwdzIA==} engines: {node: '>=8'} dependencies: path-type: 4.0.0 dev: true - /doctrine/3.0.0: + /doctrine@3.0.0: resolution: {integrity: sha512-yS+Q5i3hBf7GBkd4KG8a7eBNNWNGLTaEwwYWUijIYM7zrlYDM0BFXHjjPWlWZ1Rg7UaddZeIDmi9jF3HmqiQ2w==} engines: {node: '>=6.0.0'} dependencies: esutils: 2.0.3 dev: true - /dom-serializer/2.0.0: + /dom-serializer@2.0.0: resolution: {integrity: sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==} dependencies: domelementtype: 2.3.0 @@ -4362,22 +4392,22 @@ packages: entities: 4.4.0 dev: true - /dom-walk/0.1.1: + /dom-walk@0.1.1: resolution: {integrity: sha512-8CGZnLAdYN/o0SHjlP3nLvliHpi2f/prVU63/Hc4DTDpBgsNVAJekegjFtxfZ7NTUEDzHUByjX1gT3eYakIKqg==} dev: true - /domelementtype/2.3.0: + /domelementtype@2.3.0: resolution: {integrity: sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==} dev: true - /domhandler/5.0.3: + /domhandler@5.0.3: resolution: {integrity: sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==} engines: {node: '>= 4'} dependencies: domelementtype: 2.3.0 dev: true - /domutils/3.0.1: + /domutils@3.0.1: resolution: {integrity: sha512-z08c1l761iKhDFtfXO04C7kTdPBLi41zwOZl00WS8b5eiaebNpY00HKbztwBq+e3vyqWNwWF3mP9YLUeqIrF+Q==} dependencies: dom-serializer: 2.0.0 @@ -4385,20 +4415,20 @@ packages: domhandler: 5.0.3 dev: true - /dot-case/2.1.1: + /dot-case@2.1.1: resolution: {integrity: sha512-HnM6ZlFqcajLsyudHq7LeeLDr2rFAVYtDv/hV5qchQEidSck8j9OPUsXY9KwJv/lHMtYlX4DjRQqwFYa+0r8Ug==} dependencies: no-case: 2.3.2 dev: true - /dotignore/0.1.2: + /dotignore@0.1.2: resolution: {integrity: sha512-UGGGWfSauusaVJC+8fgV+NVvBXkCTmVv7sk6nojDZZvuOUNGUy0Zk4UpHQD6EDjS0jpBwcACvH4eofvyzBcRDw==} hasBin: true dependencies: minimatch: 3.1.2 dev: true - /drbg.js/1.0.1: + /drbg.js@1.0.1: resolution: {integrity: sha512-F4wZ06PvqxYLFEZKkFxTDcns9oFNk34hvmJSEwdzsxVQ8YI5YaxtACgQatkYgv2VI2CFkUd2Y+xosPQnHv809g==} engines: {node: '>=0.10'} dependencies: @@ -4407,26 +4437,26 @@ packages: create-hmac: 1.1.7 dev: true - /duplexer3/0.1.4: + /duplexer3@0.1.4: resolution: {integrity: sha512-CEj8FwwNA4cVH2uFCoHUrmojhYh1vmCdOaneKJXwkeY1i9jnlslVo9dx+hQ5Hl9GnH/Bwy/IjxAyOePyPKYnzA==} dev: true - /ecc-jsbn/0.1.2: + /ecc-jsbn@0.1.2: resolution: {integrity: sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw==} dependencies: jsbn: 0.1.1 safer-buffer: 2.1.2 dev: true - /ee-first/1.1.1: + /ee-first@1.1.1: resolution: {integrity: sha512-WMwm9LhRUo+WUaRN+vRuETqG89IgZphVSNkdFgeb6sS/E4OrDIN7t48CAewSHXc6C8lefD8KKfr5vY61brQlow==} dev: true - /electron-to-chromium/1.4.270: + /electron-to-chromium@1.4.270: resolution: {integrity: sha512-KNhIzgLiJmDDC444dj9vEOpZEgsV96ult9Iff98Vanumn+ShJHd5se8aX6KeVxdc0YQeqdrezBZv89rleDbvSg==} dev: true - /elliptic/6.5.4: + /elliptic@6.5.4: resolution: {integrity: sha512-iLhC6ULemrljPZb+QutR5TQGB+pdW6KGD5RSegS+8sorOZT+rdQFbsQFJgvN3eRqNALqJer4oQ16YvJHlU8hzQ==} dependencies: bn.js: 4.12.0 @@ -4437,20 +4467,20 @@ packages: minimalistic-assert: 1.0.1 minimalistic-crypto-utils: 1.0.1 - /emoji-regex/7.0.3: + /emoji-regex@7.0.3: resolution: {integrity: sha512-CwBLREIQ7LvYFB0WyRvwhq5N5qPhc6PMjD6bYggFlI5YyDgl+0vxq5VHbMOFqLg7hfWzmu8T5Z1QofhmTIhItA==} dev: true - /emoji-regex/8.0.0: + /emoji-regex@8.0.0: resolution: {integrity: sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==} dev: true - /encodeurl/1.0.2: + /encodeurl@1.0.2: resolution: {integrity: sha512-TPJXq8JqFaVYm2CWmPvnP2Iyo4ZSM7/QKcSmuMLDObfpH5fi7RUGmd/rTDf+rut/saiDiQEeVTNgAmJEdAOx0w==} engines: {node: '>= 0.8'} dev: true - /encoding-down/5.0.4: + /encoding-down@5.0.4: resolution: {integrity: sha512-8CIZLDcSKxgzT+zX8ZVfgNbu8Md2wq/iqa1Y7zyVR18QBEAc0Nmzuvj/N5ykSKpfGzjM8qxbaFntLPwnVoUhZw==} engines: {node: '>=6'} dependencies: @@ -4461,49 +4491,49 @@ packages: xtend: 4.0.2 dev: true - /encoding/0.1.13: + /encoding@0.1.13: resolution: {integrity: sha512-ETBauow1T35Y/WZMkio9jiM0Z5xjHHmJ4XmjZOq1l/dXz3lr2sRn87nJy20RupqSh1F2m3HHPSp8ShIPQJrJ3A==} dependencies: iconv-lite: 0.6.3 dev: true - /end-of-stream/1.4.4: + /end-of-stream@1.4.4: resolution: {integrity: sha512-+uw1inIHVPQoaVuHzRyXd21icM+cnt4CzD5rW+NC1wjOUSTOs+Te7FOv7AhN7vS9x/oIyhLP5PR1H+phQAHu5Q==} dependencies: once: 1.4.0 dev: true - /enquirer/2.3.6: + /enquirer@2.3.6: resolution: {integrity: sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==} engines: {node: '>=8.6'} dependencies: ansi-colors: 4.1.3 dev: true - /entities/4.4.0: + /entities@4.4.0: resolution: {integrity: sha512-oYp7156SP8LkeGD0GF85ad1X9Ai79WtRsZ2gxJqtBuzH+98YUV6jkHEKlZkMbcrjJjIVJNIDP/3WL9wQkoPbWA==} engines: {node: '>=0.12'} dev: true - /env-paths/2.2.1: + /env-paths@2.2.1: resolution: {integrity: sha512-+h1lkLKhZMTYjog1VEpJNG7NZJWcuc2DDk/qsqSTRRCOXiLjeQ1d1/udrUGhqMxUgAlwKNZ0cf2uqan5GLuS2A==} engines: {node: '>=6'} dev: true - /errno/0.1.8: + /errno@0.1.8: resolution: {integrity: sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A==} hasBin: true dependencies: prr: 1.0.1 dev: true - /error-ex/1.3.2: + /error-ex@1.3.2: resolution: {integrity: sha512-7dFHNmqeFSEt2ZBsCriorKnn3Z2pj+fd9kmI6QoWw4//DL+icEBfc0U7qJCisqrTsKTjw4fNFy2pW9OqStD84g==} dependencies: is-arrayish: 0.2.1 dev: true - /es-abstract/1.20.3: + /es-abstract@1.20.3: resolution: {integrity: sha512-AyrnaKVpMzljIdwjzrj+LxGmj8ik2LckwXacHqrJJ/jxz6dDDBcZ7I7nlHM0FvEW8MfbWJwOd+yT2XzYW49Frw==} engines: {node: '>= 0.4'} dependencies: @@ -4533,11 +4563,11 @@ packages: unbox-primitive: 1.0.2 dev: true - /es-array-method-boxes-properly/1.0.0: + /es-array-method-boxes-properly@1.0.0: resolution: {integrity: sha512-wd6JXUmyHmt8T5a2xreUwKcGPq6f1f+WwIJkijUqiGcJz1qqnZgP6XIK+QyIWU5lT7imeNxUll48bziG+TSYcA==} dev: true - /es-to-primitive/1.2.1: + /es-to-primitive@1.2.1: resolution: {integrity: sha512-QCOllgZJtaUo9miYBcLChTUaHNjJF3PYs1VidD7AwiEj1kYxKeQTctLAezAOH5ZKRH0g2IgPn6KwB4IT8iRpvA==} engines: {node: '>= 0.4'} dependencies: @@ -4546,7 +4576,7 @@ packages: is-symbol: 1.0.3 dev: true - /es5-ext/0.10.62: + /es5-ext@0.10.62: resolution: {integrity: sha512-BHLqn0klhEpnOKSrzn/Xsz2UIW8j+cGmo9JLzr8BiUapV8hPL9+FliFqjwr9ngW7jWdnxv6eO+/LqyhJVqgrjA==} engines: {node: '>=0.10'} requiresBuild: true @@ -4556,7 +4586,7 @@ packages: next-tick: 1.1.0 dev: true - /es6-iterator/2.0.3: + /es6-iterator@2.0.3: resolution: {integrity: sha512-zw4SRzoUkd+cl+ZoE15A9o1oQd920Bb0iOJMQkQhl3jNc03YqVjAhG7scf9C5KWRU/R13Orf588uCC6525o02g==} dependencies: d: 1.0.1 @@ -4564,37 +4594,37 @@ packages: es6-symbol: 3.1.3 dev: true - /es6-promise/4.2.8: + /es6-promise@4.2.8: resolution: {integrity: sha512-HJDGx5daxeIvxdBxvG2cb9g4tEvwIk3i8+nhX0yGrYmZUzbkdg8QbDevheDB8gd0//uPj4c1EQua8Q+MViT0/w==} dev: true - /es6-symbol/3.1.3: + /es6-symbol@3.1.3: resolution: {integrity: sha512-NJ6Yn3FuDinBaBRWl/q5X/s4koRHBrgKAu+yGI6JCBeiu3qrcbJhwT2GeR/EXVfylRk8dpQVJoLEFhK+Mu31NA==} dependencies: d: 1.0.1 ext: 1.4.0 dev: true - /escalade/3.1.1: + /escalade@3.1.1: resolution: {integrity: sha512-k0er2gUkLf8O0zKJiAhmkTnJlTvINGv7ygDNPbeIsX/TJjGJZHuh9B2UxbsaEkmlEo9MfhrSzmhIlhRlI2GXnw==} engines: {node: '>=6'} dev: true - /escape-html/1.0.3: + /escape-html@1.0.3: resolution: {integrity: sha512-NiSupZ4OeuGwr68lGIeym/ksIZMJodUGOSCZ/FSnTxcrekbvqrgdUxlJOMpijaKZVjAJrWrGs/6Jy8OMuyj9ow==} dev: true - /escape-string-regexp/1.0.5: + /escape-string-regexp@1.0.5: resolution: {integrity: sha512-vbRorB5FUQWvla16U8R/qgaFIya2qGzwDrNmCZuYKrbdSUMG6I1ZCGQRefkRVhuOkIGVne7BQ35DSfo1qvJqFg==} engines: {node: '>=0.8.0'} dev: true - /escape-string-regexp/4.0.0: + /escape-string-regexp@4.0.0: resolution: {integrity: sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==} engines: {node: '>=10'} dev: true - /escodegen/1.8.1: + /escodegen@1.8.1: resolution: {integrity: sha512-yhi5S+mNTOuRvyW4gWlg5W1byMaQGWWSYHXsuFZ7GBo7tpyOwi2EdzMP/QWxh9hwkD2m+wDVHJsxhRIj+v/b/A==} engines: {node: '>=0.12.0'} hasBin: true @@ -4607,7 +4637,7 @@ packages: source-map: 0.2.0 dev: true - /eslint-config-prettier/8.8.0_eslint@8.42.0: + /eslint-config-prettier@8.8.0(eslint@8.42.0): resolution: {integrity: sha512-wLbQiFre3tdGgpDv67NQKnJuTlcUVYHas3k+DZCc2U2BadthoEY4B7hLPvAxaqdyOGCzuLfii2fqGph10va7oA==} hasBin: true peerDependencies: @@ -4616,7 +4646,7 @@ packages: eslint: 8.42.0 dev: true - /eslint-plugin-prettier/4.2.1_vnriwwub2rhvoyn4ckagrc4lpi: + /eslint-plugin-prettier@4.2.1(eslint-config-prettier@8.8.0)(eslint@8.42.0)(prettier@2.8.8): resolution: {integrity: sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ==} engines: {node: '>=12.0.0'} peerDependencies: @@ -4628,12 +4658,12 @@ packages: optional: true dependencies: eslint: 8.42.0 - eslint-config-prettier: 8.8.0_eslint@8.42.0 + eslint-config-prettier: 8.8.0(eslint@8.42.0) prettier: 2.8.8 prettier-linter-helpers: 1.0.0 dev: true - /eslint-scope/5.1.1: + /eslint-scope@5.1.1: resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==} engines: {node: '>=8.0.0'} dependencies: @@ -4641,7 +4671,7 @@ packages: estraverse: 4.3.0 dev: true - /eslint-scope/7.2.0: + /eslint-scope@7.2.0: resolution: {integrity: sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: @@ -4649,17 +4679,17 @@ packages: estraverse: 5.3.0 dev: true - /eslint-visitor-keys/3.4.1: + /eslint-visitor-keys@3.4.1: resolution: {integrity: sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dev: true - /eslint/8.42.0: + /eslint@8.42.0: resolution: {integrity: sha512-ulg9Ms6E1WPf67PHaEY4/6E2tEn5/f7FXGzr3t9cBMugOmf1INYvuUwwh1aXQN4MfJ6a5K2iNwP3w4AColvI9A==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} hasBin: true dependencies: - '@eslint-community/eslint-utils': 4.4.0_eslint@8.42.0 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.42.0) '@eslint-community/regexpp': 4.5.1 '@eslint/eslintrc': 2.0.3 '@eslint/js': 8.42.0 @@ -4669,7 +4699,7 @@ packages: ajv: 6.12.6 chalk: 4.1.2 cross-spawn: 7.0.3 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) doctrine: 3.0.0 escape-string-regexp: 4.0.0 eslint-scope: 7.2.0 @@ -4702,67 +4732,67 @@ packages: - supports-color dev: true - /espree/9.5.2: + /espree@9.5.2: resolution: {integrity: sha512-7OASN1Wma5fum5SrNhFMAMJxOUAbhyfQ8dQ//PJaJbNw0URTPWqIghHWt1MmAANKhHZIYOHruW4Kw4ruUWOdGw==} engines: {node: ^12.22.0 || ^14.17.0 || >=16.0.0} dependencies: acorn: 8.8.0 - acorn-jsx: 5.3.2_acorn@8.8.0 + acorn-jsx: 5.3.2(acorn@8.8.0) eslint-visitor-keys: 3.4.1 dev: true - /esprima/2.7.3: + /esprima@2.7.3: resolution: {integrity: sha512-OarPfz0lFCiW4/AV2Oy1Rp9qu0iusTKqykwTspGCZtPxmF81JR4MmIebvF1F9+UOKth2ZubLQ4XGGaU+hSn99A==} engines: {node: '>=0.10.0'} hasBin: true dev: true - /esprima/4.0.1: + /esprima@4.0.1: resolution: {integrity: sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==} engines: {node: '>=4'} hasBin: true dev: true - /esquery/1.5.0: + /esquery@1.5.0: resolution: {integrity: sha512-YQLXUplAwJgCydQ78IMJywZCceoqk1oH01OERdSAJc/7U2AylwjhSCLDEtqwg811idIS/9fIU5GjG73IgjKMVg==} engines: {node: '>=0.10'} dependencies: estraverse: 5.3.0 dev: true - /esrecurse/4.3.0: + /esrecurse@4.3.0: resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==} engines: {node: '>=4.0'} dependencies: estraverse: 5.3.0 dev: true - /estraverse/1.9.3: + /estraverse@1.9.3: resolution: {integrity: sha512-25w1fMXQrGdoquWnScXZGckOv+Wes+JDnuN/+7ex3SauFRS72r2lFDec0EKPt2YD1wUJ/IrfEex+9yp4hfSOJA==} engines: {node: '>=0.10.0'} dev: true - /estraverse/4.3.0: + /estraverse@4.3.0: resolution: {integrity: sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==} engines: {node: '>=4.0'} dev: true - /estraverse/5.3.0: + /estraverse@5.3.0: resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==} engines: {node: '>=4.0'} dev: true - /esutils/2.0.3: + /esutils@2.0.3: resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==} engines: {node: '>=0.10.0'} dev: true - /etag/1.8.1: + /etag@1.8.1: resolution: {integrity: sha512-aIL5Fx7mawVa300al2BnEE4iNvo1qETxLrPI/o05L7z6go7fCw1J6EQmbK4FmJ2AS7kgVF/KEZWufBfdClMcPg==} engines: {node: '>= 0.6'} dev: true - /eth-block-tracker/3.0.1: + /eth-block-tracker@3.0.1: resolution: {integrity: sha512-WUVxWLuhMmsfenfZvFO5sbl1qFY2IqUlw/FPVmjjdElpqLsZtSG+wPe9Dz7W/sB6e80HgFKknOmKk2eNlznHug==} dependencies: eth-query: 2.1.2 @@ -4776,14 +4806,14 @@ packages: - supports-color dev: true - /eth-ens-namehash/2.0.8: + /eth-ens-namehash@2.0.8: resolution: {integrity: sha512-VWEI1+KJfz4Km//dadyvBBoBeSQ0MHTXPvr8UIXiLW6IanxvAV+DmlZAijZwAyggqGUfwQBeHf7tc9wzc1piSw==} dependencies: idna-uts46-hx: 2.3.1 js-sha3: 0.5.7 dev: true - /eth-gas-reporter/0.2.25: + /eth-gas-reporter@0.2.25: resolution: {integrity: sha512-1fRgyE4xUB8SoqLgN3eDfpDfwEfRxh2Sz1b7wzFbyQA+9TekMmvSjjoRu9SKcSVyK+vLkLIsVbJDsTWjw195OQ==} peerDependencies: '@codechecks/client': ^0.1.0 @@ -4803,12 +4833,12 @@ packages: mocha: 7.2.0 req-cwd: 2.0.0 request: 2.88.2 - request-promise-native: 1.0.9_request@2.88.2 + request-promise-native: 1.0.9(request@2.88.2) sha1: 1.1.1 sync-request: 6.1.0 dev: true - /eth-json-rpc-infura/3.2.1: + /eth-json-rpc-infura@3.2.1: resolution: {integrity: sha512-W7zR4DZvyTn23Bxc0EWsq4XGDdD63+XPUCEhV2zQvQGavDVC4ZpFDK4k99qN7bd7/fjj37+rxmuBOBeIqCA5Mw==} dependencies: cross-fetch: 2.2.6 @@ -4820,7 +4850,7 @@ packages: - supports-color dev: true - /eth-json-rpc-middleware/1.6.0: + /eth-json-rpc-middleware@1.6.0: resolution: {integrity: sha512-tDVCTlrUvdqHKqivYMjtFZsdD7TtpNLBCfKAcOpaVs7orBMS/A8HWro6dIzNtTZIR05FAbJ3bioFOnZpuCew9Q==} dependencies: async: 2.6.3 @@ -4840,7 +4870,7 @@ packages: - supports-color dev: true - /eth-lib/0.1.29: + /eth-lib@0.1.29: resolution: {integrity: sha512-bfttrr3/7gG4E02HoWTDUcDDslN003OlOoBxk9virpAZQ1ja/jDgwkWB8QfJF7ojuEowrqy+lzp9VcJG7/k5bQ==} dependencies: bn.js: 4.12.0 @@ -4855,7 +4885,7 @@ packages: - utf-8-validate dev: true - /eth-lib/0.2.8: + /eth-lib@0.2.8: resolution: {integrity: sha512-ArJ7x1WcWOlSpzdoTBX8vkwlkSQ85CjjifSZtV4co64vWxSV8geWfPI9x4SVYu3DSxnX4yWFVTtGL+j9DUFLNw==} dependencies: bn.js: 4.12.0 @@ -4863,14 +4893,14 @@ packages: xhr-request-promise: 0.1.2 dev: true - /eth-query/2.1.2: + /eth-query@2.1.2: resolution: {integrity: sha512-srES0ZcvwkR/wd5OQBRA1bIJMww1skfGS0s8wlwK3/oNP4+wnds60krvu5R1QbpRQjMmpG5OMIWro5s7gvDPsA==} dependencies: json-rpc-random-id: 1.0.1 xtend: 4.0.2 dev: true - /eth-sig-util/1.4.2: + /eth-sig-util@1.4.2: resolution: {integrity: sha512-iNZ576iTOGcfllftB73cPB5AN+XUQAT/T8xzsILsghXC1o8gJUqe3RHlcDqagu+biFpYQ61KQrZZJza8eRSYqw==} deprecated: Deprecated in favor of '@metamask/eth-sig-util' dependencies: @@ -4878,7 +4908,7 @@ packages: ethereumjs-util: 5.2.1 dev: true - /eth-sig-util/3.0.0: + /eth-sig-util@3.0.0: resolution: {integrity: sha512-4eFkMOhpGbTxBQ3AMzVf0haUX2uTur7DpWiHzWyTURa28BVJJtOkcb9Ok5TV0YvEPG61DODPW7ZUATbJTslioQ==} deprecated: Deprecated in favor of '@metamask/eth-sig-util' dependencies: @@ -4890,7 +4920,7 @@ packages: tweetnacl-util: 0.15.1 dev: true - /eth-tx-summary/3.2.4: + /eth-tx-summary@3.2.4: resolution: {integrity: sha512-NtlDnaVZah146Rm8HMRUNMgIwG/ED4jiqk0TME9zFheMl1jOp6jL1m0NKGjJwehXQ6ZKCPr16MTr+qspKpEXNg==} dependencies: async: 2.6.3 @@ -4905,7 +4935,7 @@ packages: through2: 2.0.5 dev: true - /ethashjs/0.0.8: + /ethashjs@0.0.8: resolution: {integrity: sha512-/MSbf/r2/Ld8o0l15AymjOTlPqpN8Cr4ByUEA9GtR4x0yAh3TdtDzEg29zMjXCNPI7u6E5fOQdj/Cf9Tc7oVNw==} deprecated: 'New package name format for new versions: @ethereumjs/ethash. Please update.' dependencies: @@ -4915,21 +4945,21 @@ packages: miller-rabin: 4.0.1 dev: true - /ethereum-bloom-filters/1.0.10: + /ethereum-bloom-filters@1.0.10: resolution: {integrity: sha512-rxJ5OFN3RwjQxDcFP2Z5+Q9ho4eIdEmSc2ht0fCu8Se9nbXjZ7/031uXoUYJ87KHCOdVeiUuwSnoS7hmYAGVHA==} dependencies: js-sha3: 0.8.0 dev: true - /ethereum-common/0.0.18: + /ethereum-common@0.0.18: resolution: {integrity: sha512-EoltVQTRNg2Uy4o84qpa2aXymXDJhxm7eos/ACOg0DG4baAbMjhbdAEsx9GeE8sC3XCxnYvrrzZDH8D8MtA2iQ==} dev: true - /ethereum-common/0.2.0: + /ethereum-common@0.2.0: resolution: {integrity: sha512-XOnAR/3rntJgbCdGhqdaLIxDLWKLmsZOGhHdBKadEr6gEnJLH52k93Ou+TUdFaPN3hJc3isBZBal3U/XZ15abA==} dev: true - /ethereum-cryptography/0.1.3: + /ethereum-cryptography@0.1.3: resolution: {integrity: sha512-w8/4x1SGGzc+tO97TASLja6SLd3fRIK2tLVcV2Gx4IB21hE19atll5Cq9o3d0ZmAYC/8aw0ipieTSiekAea4SQ==} dependencies: '@types/pbkdf2': 3.1.0 @@ -4949,7 +4979,7 @@ packages: setimmediate: 1.0.5 dev: true - /ethereum-cryptography/1.1.2: + /ethereum-cryptography@1.1.2: resolution: {integrity: sha512-XDSJlg4BD+hq9N2FjvotwUET9Tfxpxc3kWGE2AqUG5vcbeunnbImVk3cj6e/xT3phdW21mE8R5IugU4fspQDcQ==} dependencies: '@noble/hashes': 1.1.2 @@ -4958,13 +4988,13 @@ packages: '@scure/bip39': 1.1.0 dev: true - /ethereum-waffle/3.3.0_typescript@4.9.5: + /ethereum-waffle@3.3.0(typescript@4.9.5): resolution: {integrity: sha512-4xm3RWAPCu5LlaVxYEg0tG3L7g5ovBw1GY/UebrzZ+OTx22vcPjI+bvelFlGBpkdnO5yOIFXjH2eK59tNAe9IA==} engines: {node: '>=10.0'} hasBin: true dependencies: '@ethereum-waffle/chai': 3.4.4 - '@ethereum-waffle/compiler': 3.4.4_typescript@4.9.5 + '@ethereum-waffle/compiler': 3.4.4(typescript@4.9.5) '@ethereum-waffle/mock-contract': 3.4.4 '@ethereum-waffle/provider': 3.4.4 ethers: 5.6.1 @@ -4976,21 +5006,21 @@ packages: - utf-8-validate dev: true - /ethereumjs-abi/0.6.5: + /ethereumjs-abi@0.6.5: resolution: {integrity: sha512-rCjJZ/AE96c/AAZc6O3kaog4FhOsAViaysBxqJNy2+LHP0ttH0zkZ7nXdVHOAyt6lFwLO0nlCwWszysG/ao1+g==} dependencies: bn.js: 4.12.0 ethereumjs-util: 4.5.0 dev: true - /ethereumjs-abi/0.6.8: + /ethereumjs-abi@0.6.8: resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==} dependencies: bn.js: 4.12.0 ethereumjs-util: 6.2.1 dev: true - /ethereumjs-account/2.0.5: + /ethereumjs-account@2.0.5: resolution: {integrity: sha512-bgDojnXGjhMwo6eXQC0bY6UK2liSFUSMwwylOmQvZbSl/D7NXQ3+vrGO46ZeOgjGfxXmgIeVNDIiHw7fNZM4VA==} dependencies: ethereumjs-util: 5.2.1 @@ -4998,7 +5028,7 @@ packages: safe-buffer: 5.2.1 dev: true - /ethereumjs-account/3.0.0: + /ethereumjs-account@3.0.0: resolution: {integrity: sha512-WP6BdscjiiPkQfF9PVfMcwx/rDvfZTjFKY0Uwc09zSQr9JfIVH87dYIJu0gNhBhpmovV4yq295fdllS925fnBA==} deprecated: Please use Util.Account class found on package ethereumjs-util@^7.0.6 https://github.com/ethereumjs/ethereumjs-util/releases/tag/v7.0.6 dependencies: @@ -5007,7 +5037,7 @@ packages: safe-buffer: 5.2.1 dev: true - /ethereumjs-block/1.7.1: + /ethereumjs-block@1.7.1: resolution: {integrity: sha512-B+sSdtqm78fmKkBq78/QLKJbu/4Ts4P2KFISdgcuZUPDm9x+N7qgBPIIFUGbaakQh8bzuquiRVbdmvPKqbILRg==} deprecated: 'New package name format for new versions: @ethereumjs/block. Please update.' dependencies: @@ -5018,7 +5048,7 @@ packages: merkle-patricia-tree: 2.3.2 dev: true - /ethereumjs-block/2.2.2: + /ethereumjs-block@2.2.2: resolution: {integrity: sha512-2p49ifhek3h2zeg/+da6XpdFR3GlqY3BIEiqxGF8j9aSRIgkb7M1Ky+yULBKJOu8PAZxfhsYA+HxUk2aCQp3vg==} deprecated: 'New package name format for new versions: @ethereumjs/block. Please update.' dependencies: @@ -5029,7 +5059,7 @@ packages: merkle-patricia-tree: 2.3.2 dev: true - /ethereumjs-blockchain/4.0.4: + /ethereumjs-blockchain@4.0.4: resolution: {integrity: sha512-zCxaRMUOzzjvX78DTGiKjA+4h2/sF0OYL1QuPux0DHpyq8XiNoF5GYHtb++GUxVlMsMfZV7AVyzbtgcRdIcEPQ==} deprecated: 'New package name format for new versions: @ethereumjs/blockchain. Please update.' dependencies: @@ -5045,12 +5075,12 @@ packages: semaphore: 1.1.0 dev: true - /ethereumjs-common/1.5.0: + /ethereumjs-common@1.5.0: resolution: {integrity: sha512-SZOjgK1356hIY7MRj3/ma5qtfr/4B5BL+G4rP/XSMYr2z1H5el4RX5GReYCKmQmYI/nSBmRnwrZ17IfHuG0viQ==} deprecated: 'New package name format for new versions: @ethereumjs/common. Please update.' dev: true - /ethereumjs-tx/1.3.7: + /ethereumjs-tx@1.3.7: resolution: {integrity: sha512-wvLMxzt1RPhAQ9Yi3/HKZTn0FZYpnsmQdbKYfUUpi4j1SEIcbkd9tndVjcPrufY3V7j2IebOpC00Zp2P/Ay2kA==} deprecated: 'New package name format for new versions: @ethereumjs/tx. Please update.' dependencies: @@ -5058,7 +5088,7 @@ packages: ethereumjs-util: 5.2.1 dev: true - /ethereumjs-tx/2.1.2: + /ethereumjs-tx@2.1.2: resolution: {integrity: sha512-zZEK1onCeiORb0wyCXUvg94Ve5It/K6GD1K+26KfFKodiBiS6d9lfCXlUKGBBdQ+bv7Day+JK0tj1K+BeNFRAw==} deprecated: 'New package name format for new versions: @ethereumjs/tx. Please update.' dependencies: @@ -5066,7 +5096,7 @@ packages: ethereumjs-util: 6.2.1 dev: true - /ethereumjs-util/4.5.0: + /ethereumjs-util@4.5.0: resolution: {integrity: sha512-gT1zBY8aQKkexYu7XNeBZBnJsRLo+sWD1XWRLJOaDSz49/9kCOs6ERP52Bw/TA4uaVFKpM+O8ebWy44Ib5B6xw==} dependencies: bn.js: 4.12.0 @@ -5076,7 +5106,7 @@ packages: secp256k1: 3.7.1 dev: true - /ethereumjs-util/5.2.1: + /ethereumjs-util@5.2.1: resolution: {integrity: sha512-v3kT+7zdyCm1HIqWlLNrHGqHGLpGYIhjeHxQjnDXjLT2FyGJDsd3LWMYUo7pAFRrk86CR3nUJfhC81CCoJNNGQ==} dependencies: bn.js: 4.12.0 @@ -5088,7 +5118,7 @@ packages: safe-buffer: 5.2.1 dev: true - /ethereumjs-util/6.2.1: + /ethereumjs-util@6.2.1: resolution: {integrity: sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==} dependencies: '@types/bn.js': 4.11.6 @@ -5100,7 +5130,7 @@ packages: rlp: 2.2.7 dev: true - /ethereumjs-util/7.1.5: + /ethereumjs-util@7.1.5: resolution: {integrity: sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg==} engines: {node: '>=10.0.0'} dependencies: @@ -5111,7 +5141,7 @@ packages: rlp: 2.2.7 dev: true - /ethereumjs-vm/2.6.0: + /ethereumjs-vm@2.6.0: resolution: {integrity: sha512-r/XIUik/ynGbxS3y+mvGnbOKnuLo40V5Mj1J25+HEO63aWYREIqvWeRO/hnROlMBE5WoniQmPmhiaN0ctiHaXw==} deprecated: 'New package name format for new versions: @ethereumjs/vm. Please update.' dependencies: @@ -5128,7 +5158,7 @@ packages: safe-buffer: 5.2.1 dev: true - /ethereumjs-vm/4.2.0: + /ethereumjs-vm@4.2.0: resolution: {integrity: sha512-X6qqZbsY33p5FTuZqCnQ4+lo957iUJMM6Mpa6bL4UW0dxM6WmDSHuI4j/zOp1E2TDKImBGCJA9QPfc08PaNubA==} deprecated: 'New package name format for new versions: @ethereumjs/vm. Please update.' dependencies: @@ -5149,7 +5179,7 @@ packages: util.promisify: 1.1.1 dev: true - /ethereumjs-wallet/0.6.5: + /ethereumjs-wallet@0.6.5: resolution: {integrity: sha512-MDwjwB9VQVnpp/Dc1XzA6J1a3wgHQ4hSvA1uWNatdpOrtCbPVuQSKSyRnjLvS0a+KKMw2pvQ9Ybqpb3+eW8oNA==} requiresBuild: true dependencies: @@ -5165,7 +5195,7 @@ packages: dev: true optional: true - /ethers/4.0.49: + /ethers@4.0.49: resolution: {integrity: sha512-kPltTvWiyu+OktYy1IStSO16i2e7cS9D9OxZ81q2UUaiNPVrm/RTcbxamCXF9VUSKzJIdJV68EAIhTEVBalRWg==} dependencies: aes-js: 3.0.0 @@ -5179,7 +5209,7 @@ packages: xmlhttprequest: 1.8.0 dev: true - /ethers/5.6.1: + /ethers@5.6.1: resolution: {integrity: sha512-qtl/2W+dwmUa5Z3JqwsbV3JEBZZHNARe5K/A2ePcNAuhJYnEKIgGOT/O9ouPwBijSqVoQnmQMzi5D48LFNOY2A==} dependencies: '@ethersproject/abi': 5.6.0 @@ -5216,7 +5246,7 @@ packages: - bufferutil - utf-8-validate - /ethjs-abi/0.2.1: + /ethjs-abi@0.2.1: resolution: {integrity: sha512-g2AULSDYI6nEJyJaEVEXtTimRY2aPC2fi7ddSy0W+LXvEVL8Fe1y76o43ecbgdUKwZD+xsmEgX1yJr1Ia3r1IA==} engines: {node: '>=6.5.0', npm: '>=3'} dependencies: @@ -5225,7 +5255,7 @@ packages: number-to-bn: 1.7.0 dev: true - /ethjs-unit/0.1.6: + /ethjs-unit@0.1.6: resolution: {integrity: sha512-/Sn9Y0oKl0uqQuvgFk/zQgR7aw1g36qX/jzSQ5lSwlO0GigPymk4eGQfeNTD03w1dPOqfz8V77Cy43jH56pagw==} engines: {node: '>=6.5.0', npm: '>=3'} dependencies: @@ -5233,7 +5263,7 @@ packages: number-to-bn: 1.7.0 dev: true - /ethjs-util/0.1.6: + /ethjs-util@0.1.6: resolution: {integrity: sha512-CUnVOQq7gSpDHZVVrQW8ExxUETWrnrvXYvYz55wOU8Uj4VCgw56XC2B/fVqQN+f7gmrnRHSLVnFAwsCuNwji8w==} engines: {node: '>=6.5.0', npm: '>=3'} dependencies: @@ -5241,28 +5271,28 @@ packages: strip-hex-prefix: 1.0.0 dev: true - /event-target-shim/5.0.1: + /event-target-shim@5.0.1: resolution: {integrity: sha512-i/2XbnSz/uxRCU6+NdVJgKWDTM427+MqYbkQzD321DuCQJUqOuJKIA0IM2+W2xtYHdKOmZ4dR6fExsd4SXL+WQ==} engines: {node: '>=6'} dev: true - /eventemitter3/4.0.4: + /eventemitter3@4.0.4: resolution: {integrity: sha512-rlaVLnVxtxvoyLsQQFBx53YmXHDxRIzzTLbdfxqi4yocpSjAxXwkU0cScM5JgSKMqEhrZpnvQ2D9gjylR0AimQ==} dev: true - /events/3.3.0: + /events@3.3.0: resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==} engines: {node: '>=0.8.x'} dev: true - /evp_bytestokey/1.0.3: + /evp_bytestokey@1.0.3: resolution: {integrity: sha512-/f2Go4TognH/KvCISP7OUsHn85hT9nUkxxA9BEWxFn+Oj9o8ZNLm/40hdlgSLyuOimsrTKLUMEorQexp/aPQeA==} dependencies: md5.js: 1.3.5 safe-buffer: 5.2.1 dev: true - /expand-brackets/2.1.4: + /expand-brackets@2.1.4: resolution: {integrity: sha512-w/ozOKR9Obk3qoWeY/WDi6MFta9AoMR+zud60mdnbniMcBxRuFJyDt2LdX/14A1UABeqk+Uk+LDfUpvoGKppZA==} engines: {node: '>=0.10.0'} dependencies: @@ -5277,7 +5307,7 @@ packages: - supports-color dev: true - /express/4.17.1: + /express@4.17.1: resolution: {integrity: sha512-mHJ9O79RqluphRrcw2X/GTh3k9tVv8YcoyY4Kkh4WDMUYKRZUq0h1o0w2rrrxBqM7VoeUVqgb27xlEMXTnYt4g==} engines: {node: '>= 0.10.0'} dependencies: @@ -5315,20 +5345,20 @@ packages: - supports-color dev: true - /ext/1.4.0: + /ext@1.4.0: resolution: {integrity: sha512-Key5NIsUxdqKg3vIsdw9dSuXpPCQ297y6wBjL30edxwPgt2E44WcWBZey/ZvUc6sERLTxKdyCu4gZFmUbk1Q7A==} dependencies: type: 2.0.0 dev: true - /extend-shallow/2.0.1: + /extend-shallow@2.0.1: resolution: {integrity: sha512-zCnTtlxNoAiDc3gqY2aYAWFx7XWWiasuF2K8Me5WbN8otHKTUKBwjPtNpRs/rbUZm7KxWAaNj7P1a/p52GbVug==} engines: {node: '>=0.10.0'} dependencies: is-extendable: 0.1.1 dev: true - /extend-shallow/3.0.2: + /extend-shallow@3.0.2: resolution: {integrity: sha512-BwY5b5Ql4+qZoefgMj2NUmx+tehVTH/Kf4k1ZEtOHNFcm2wSxMRo992l6X3TIgni2eZVTZ85xMOjF31fwZAj6Q==} engines: {node: '>=0.10.0'} dependencies: @@ -5336,11 +5366,11 @@ packages: is-extendable: 1.0.1 dev: true - /extend/3.0.2: + /extend@3.0.2: resolution: {integrity: sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g==} dev: true - /extglob/2.0.4: + /extglob@2.0.4: resolution: {integrity: sha512-Nmb6QXkELsuBr24CJSkilo6UHHgbekK5UiZgfE6UHD3Eb27YC6oD+bhcT+tJ6cl8dmsgdQxnWlcry8ksBIBLpw==} engines: {node: '>=0.10.0'} dependencies: @@ -5356,38 +5386,38 @@ packages: - supports-color dev: true - /extsprintf/1.3.0: + /extsprintf@1.3.0: resolution: {integrity: sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g==} engines: {'0': node >=0.6.0} dev: true - /extsprintf/1.4.0: + /extsprintf@1.4.0: resolution: {integrity: sha512-6NW8DZ8pWBc5NbGYUiqqccj9dXnuSzilZYqprdKJBZsQodGH9IyUoFOGxIWVDcBzHMb8ET24aqx9p66tZEWZkA==} engines: {'0': node >=0.6.0} dev: true - /fake-merkle-patricia-tree/1.0.1: + /fake-merkle-patricia-tree@1.0.1: resolution: {integrity: sha512-Tgq37lkc9pUIgIKw5uitNUKcgcYL3R6JvXtKQbOf/ZSavXbidsksgp/pAY6p//uhw0I4yoMsvTSovvVIsk/qxA==} dependencies: checkpoint-store: 1.1.0 dev: true - /fast-check/3.1.1: + /fast-check@3.1.1: resolution: {integrity: sha512-3vtXinVyuUKCKFKYcwXhGE6NtGWkqF8Yh3rvMZNzmwz8EPrgoc/v4pDdLHyLnCyCI5MZpZZkDEwFyXyEONOxpA==} engines: {node: '>=8.0.0'} dependencies: pure-rand: 5.0.3 dev: true - /fast-deep-equal/3.1.3: + /fast-deep-equal@3.1.3: resolution: {integrity: sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==} dev: true - /fast-diff/1.2.0: + /fast-diff@1.2.0: resolution: {integrity: sha512-xJuoT5+L99XlZ8twedaRf6Ax2TgQVxvgZOYoPKqZufmJib0tL2tegPBOZb1pVNgIhlqDlA0eO0c3wBvQcmzx4w==} dev: true - /fast-glob/3.2.12: + /fast-glob@3.2.12: resolution: {integrity: sha512-DVj4CQIYYow0BlaelwK1pHl5n5cRSJfM60UA0zK891sVInoPri2Ekj7+e1CT3/3qxXenpI+nBBmQAcJPJgaj4w==} engines: {node: '>=8.6.0'} dependencies: @@ -5398,38 +5428,38 @@ packages: micromatch: 4.0.5 dev: true - /fast-json-stable-stringify/2.1.0: + /fast-json-stable-stringify@2.1.0: resolution: {integrity: sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==} dev: true - /fast-levenshtein/2.0.6: + /fast-levenshtein@2.0.6: resolution: {integrity: sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==} dev: true - /fastq/1.6.0: + /fastq@1.6.0: resolution: {integrity: sha512-jmxqQ3Z/nXoeyDmWAzF9kH1aGZSis6e/SbfPmJpUnyZ0ogr6iscHQaml4wsEepEWSdtmpy+eVXmCRIMpxaXqOA==} dependencies: reusify: 1.0.4 dev: true - /fetch-ponyfill/4.1.0: + /fetch-ponyfill@4.1.0: resolution: {integrity: sha512-knK9sGskIg2T7OnYLdZ2hZXn0CtDrAIBxYQLpmEf0BqfdWnwmM1weccUl5+4EdA44tzNSFAuxITPbXtPehUB3g==} dependencies: node-fetch: 1.7.3 dev: true - /file-entry-cache/6.0.1: + /file-entry-cache@6.0.1: resolution: {integrity: sha512-7Gps/XWymbLk2QLYK4NzpMOrYjMhdIxXuIvy2QBsLE6ljuodKvdkWs/cpyJJ3CVIVpH0Oi1Hvg1ovbMzLdFBBg==} engines: {node: ^10.12.0 || >=12.0.0} dependencies: flat-cache: 3.0.4 dev: true - /file-uri-to-path/1.0.0: + /file-uri-to-path@1.0.0: resolution: {integrity: sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw==} dev: true - /fill-range/4.0.0: + /fill-range@4.0.0: resolution: {integrity: sha512-VcpLTWqWDiTerugjj8e3+esbg+skS3M9e54UuR3iCeIDMXCLTsAH8hTSzDQU/X6/6t3eYkOKoZSef2PlU6U1XQ==} engines: {node: '>=0.10.0'} dependencies: @@ -5439,14 +5469,14 @@ packages: to-regex-range: 2.1.1 dev: true - /fill-range/7.0.1: + /fill-range@7.0.1: resolution: {integrity: sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==} engines: {node: '>=8'} dependencies: to-regex-range: 5.0.1 dev: true - /finalhandler/1.1.2: + /finalhandler@1.1.2: resolution: {integrity: sha512-aAWcW57uxVNrQZqFXjITpW3sIUQmHGG3qSb9mUah9MgMC4NeWhNOlNjXEYq3HjRAvL6arUviZGGJsBg6z0zsWA==} engines: {node: '>= 0.8'} dependencies: @@ -5461,7 +5491,7 @@ packages: - supports-color dev: true - /find-replace/1.0.3: + /find-replace@1.0.3: resolution: {integrity: sha512-KrUnjzDCD9426YnCP56zGYy/eieTnhtK6Vn++j+JJzmlsWWwEkDnsyVF575spT6HJ6Ow9tlbT3TQTDsa+O4UWA==} engines: {node: '>=4.0.0'} dependencies: @@ -5469,14 +5499,14 @@ packages: test-value: 2.1.0 dev: true - /find-replace/3.0.0: + /find-replace@3.0.0: resolution: {integrity: sha512-6Tb2myMioCAgv5kfvP5/PkZZ/ntTpVK39fHY7WkWBgvbeE+VHd/tZuZ4mrC+bxh4cfOZeYKVPaJIZtZXV7GNCQ==} engines: {node: '>=4.0.0'} dependencies: array-back: 3.1.0 dev: true - /find-up/1.1.2: + /find-up@1.1.2: resolution: {integrity: sha512-jvElSjyuo4EMQGoTwo1uJU5pQMwTW5lS1x05zzfJuTIyLR3zwO27LYrxNg+dlvKpGOuGy/MzBdXh80g0ve5+HA==} engines: {node: '>=0.10.0'} dependencies: @@ -5484,21 +5514,21 @@ packages: pinkie-promise: 2.0.1 dev: true - /find-up/2.1.0: + /find-up@2.1.0: resolution: {integrity: sha512-NWzkk0jSJtTt08+FBFMvXoeZnOJD+jTtsRmBYbAIzJdX6l7dLgR7CTubCM5/eDdPUBvLCeVasP1brfVR/9/EZQ==} engines: {node: '>=4'} dependencies: locate-path: 2.0.0 dev: true - /find-up/3.0.0: + /find-up@3.0.0: resolution: {integrity: sha512-1yD6RmLI1XBfxugvORwlck6f75tYL+iR0jqwsOrOxMZyGYqUuDhJ0l4AXdO1iX/FTs9cBAMEk1gWSEx1kSbylg==} engines: {node: '>=6'} dependencies: locate-path: 3.0.0 dev: true - /find-up/4.1.0: + /find-up@4.1.0: resolution: {integrity: sha512-PpOwAdQ/YlXQ2vj8a3h8IipDuYRi3wceVQQGYWxNINccq40Anw7BlsEXCMbt1Zt+OLA6Fq9suIpIWD0OsnISlw==} engines: {node: '>=8'} dependencies: @@ -5506,7 +5536,7 @@ packages: path-exists: 4.0.0 dev: true - /find-up/5.0.0: + /find-up@5.0.0: resolution: {integrity: sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==} engines: {node: '>=10'} dependencies: @@ -5514,7 +5544,7 @@ packages: path-exists: 4.0.0 dev: true - /find-yarn-workspace-root/1.2.1: + /find-yarn-workspace-root@1.2.1: resolution: {integrity: sha512-dVtfb0WuQG+8Ag2uWkbG79hOUzEsRrhBzgfn86g2sJPkzmcpGdghbNTfUKGTxymFrY/tLIodDzLoW9nOJ4FY8Q==} dependencies: fs-extra: 4.0.3 @@ -5523,13 +5553,13 @@ packages: - supports-color dev: true - /find-yarn-workspace-root/2.0.0: + /find-yarn-workspace-root@2.0.0: resolution: {integrity: sha512-1IMnbjt4KzsQfnhnzNd8wUEgXZ44IzZaZmnLYx7D5FZlaHt2gW20Cri8Q+E/t5tIj4+epTBub+2Zxu/vNILzqQ==} dependencies: micromatch: 4.0.5 dev: true - /flat-cache/3.0.4: + /flat-cache@3.0.4: resolution: {integrity: sha512-dm9s5Pw7Jc0GvMYbshN6zchCA9RgQlzzEZX3vylR9IqFfS8XciblUXOKfW6SiuJ0e13eDYZoZV5wdrev7P3Nwg==} engines: {node: ^10.12.0 || >=12.0.0} dependencies: @@ -5537,27 +5567,27 @@ packages: rimraf: 3.0.2 dev: true - /flat/4.1.1: + /flat@4.1.1: resolution: {integrity: sha512-FmTtBsHskrU6FJ2VxCnsDb84wu9zhmO3cUX2kGFb5tuwhfXxGciiT0oRY+cck35QmG+NmGh5eLz6lLCpWTqwpA==} hasBin: true dependencies: is-buffer: 2.0.5 dev: true - /flat/5.0.2: + /flat@5.0.2: resolution: {integrity: sha512-b6suED+5/3rTpUBdG1gupIl8MPFCAMA0QXwmljLhvCUKcUvdE4gWky9zpuGCcXHOsz4J9wPGNWq6OKpmIzz3hQ==} hasBin: true dev: true - /flatted/3.2.7: + /flatted@3.2.7: resolution: {integrity: sha512-5nqDSxl8nn5BSNxyR3n4I6eDmbolI6WT+QqR547RwxQapgjQBmtktdP+HTBb/a/zLsbzERTONyUB5pefh5TtjQ==} dev: true - /flow-stoplight/1.0.0: + /flow-stoplight@1.0.0: resolution: {integrity: sha512-rDjbZUKpN8OYhB0IE/vY/I8UWO/602IIJEU/76Tv4LvYnwHCk0BCsvz4eRr9n+FQcri7L5cyaXOo0+/Kh4HisA==} dev: true - /follow-redirects/1.15.2_debug@4.3.4: + /follow-redirects@1.15.2(debug@4.3.4): resolution: {integrity: sha512-VQLG33o04KaQ8uYi2tVNbdrWp1QWxNNea+nmIB4EVM28v0hmP17z7aG1+wAkNzVq4KeXTq3221ye5qTJP91JwA==} engines: {node: '>=4.0'} peerDependencies: @@ -5566,33 +5596,33 @@ packages: debug: optional: true dependencies: - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) dev: true - /for-each/0.3.3: + /for-each@0.3.3: resolution: {integrity: sha512-jqYfLp7mo9vIyQf8ykW2v7A+2N4QjeCeI5+Dz9XraiO1ign81wjiH7Fb9vSOWvQfNtmSa4H2RoQTrrXivdUZmw==} dependencies: is-callable: 1.2.7 dev: true - /for-in/1.0.2: + /for-in@1.0.2: resolution: {integrity: sha512-7EwmXrOjyL+ChxMhmG5lnW9MPt1aIeZEwKhQzoBUdTV0N3zuwWDZYVJatDvZ2OyzPUvdIAZDsCetk3coyMfcnQ==} engines: {node: '>=0.10.0'} dev: true - /foreach/2.0.5: + /foreach@2.0.5: resolution: {integrity: sha512-ZBbtRiapkZYLsqoPyZOR+uPfto0GRMNQN1GwzZtZt7iZvPPbDDQV0JF5Hx4o/QFQ5c0vyuoZ98T8RSBbopzWtA==} dev: true - /forever-agent/0.6.1: + /forever-agent@0.6.1: resolution: {integrity: sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw==} dev: true - /form-data-encoder/1.7.1: + /form-data-encoder@1.7.1: resolution: {integrity: sha512-EFRDrsMm/kyqbTQocNvRXMLjc7Es2Vk+IQFx/YW7hkUH1eBl4J1fqiP34l74Yt0pFLCNpc06fkbVk00008mzjg==} dev: true - /form-data/2.3.3: + /form-data@2.3.3: resolution: {integrity: sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ==} engines: {node: '>= 0.12'} dependencies: @@ -5601,7 +5631,7 @@ packages: mime-types: 2.1.27 dev: true - /form-data/3.0.1: + /form-data@3.0.1: resolution: {integrity: sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg==} engines: {node: '>= 6'} dependencies: @@ -5610,28 +5640,28 @@ packages: mime-types: 2.1.27 dev: true - /forwarded/0.1.2: + /forwarded@0.1.2: resolution: {integrity: sha512-Ua9xNhH0b8pwE3yRbFfXJvfdWF0UHNCdeyb2sbi9Ul/M+r3PTdrz7Cv4SCfZRMjmzEM9PhraqfZFbGTIg3OMyA==} engines: {node: '>= 0.6'} dev: true - /fp-ts/1.19.3: + /fp-ts@1.19.3: resolution: {integrity: sha512-H5KQDspykdHuztLTg+ajGN0Z2qUjcEf3Ybxc6hLt0k7/zPkn29XnKnxlBPyW2XIddWrGaJBzBl4VLYOtk39yZg==} dev: true - /fragment-cache/0.2.1: + /fragment-cache@0.2.1: resolution: {integrity: sha512-GMBAbW9antB8iZRHLoGw0b3HANt57diZYFO/HL1JGIC1MjKrdmhxvrJbupnVvpys0zsz7yBApXdQyfepKly2kA==} engines: {node: '>=0.10.0'} dependencies: map-cache: 0.2.2 dev: true - /fresh/0.5.2: + /fresh@0.5.2: resolution: {integrity: sha512-zJ2mQYM18rEFOudeV4GShTGIQ7RbzA7ozbU9I/XBpm7kqgMywgmylMwXHxZJmkVoYkna9d2pVXVXPdYTP9ej8Q==} engines: {node: '>= 0.6'} dev: true - /fs-extra/0.30.0: + /fs-extra@0.30.0: resolution: {integrity: sha512-UvSPKyhMn6LEd/WpUaV9C9t3zATuqoqfWc3QdPhPLb58prN9tqYPlPWi8Krxi44loBoUzlobqZ3+8tGpxxSzwA==} dependencies: graceful-fs: 4.2.10 @@ -5641,7 +5671,7 @@ packages: rimraf: 2.7.1 dev: true - /fs-extra/4.0.3: + /fs-extra@4.0.3: resolution: {integrity: sha512-q6rbdDd1o2mAnQreO7YADIxf/Whx4AHBiRf6d+/cVT8h44ss+lHgxf1FemcqDnQt9X3ct4McHr+JMGlYSsK7Cg==} dependencies: graceful-fs: 4.2.10 @@ -5649,7 +5679,7 @@ packages: universalify: 0.1.2 dev: true - /fs-extra/7.0.1: + /fs-extra@7.0.1: resolution: {integrity: sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw==} engines: {node: '>=6 <7 || >=8'} dependencies: @@ -5658,7 +5688,7 @@ packages: universalify: 0.1.2 dev: true - /fs-extra/8.1.0: + /fs-extra@8.1.0: resolution: {integrity: sha512-yhlQgA6mnOJUKOsRUFsgJdQCvkKhcz8tlZG5HBQfReYZy46OwLcY+Zia0mtdHsOo9y/hP+CxMN0TU9QxoOtG4g==} engines: {node: '>=6 <7 || >=8'} dependencies: @@ -5667,7 +5697,7 @@ packages: universalify: 0.1.2 dev: true - /fs-extra/9.1.0: + /fs-extra@9.1.0: resolution: {integrity: sha512-hcg3ZmepS30/7BSFqRvoo3DOMQu7IjqxO5nCDt+zM9XWjb33Wg7ziNT+Qvqbuc3+gWpzO02JubVyk2G4Zvo1OQ==} engines: {node: '>=10'} dependencies: @@ -5677,21 +5707,21 @@ packages: universalify: 2.0.0 dev: true - /fs-minipass/1.2.7: + /fs-minipass@1.2.7: resolution: {integrity: sha512-GWSSJGFy4e9GUeCcbIkED+bgAoFyj7XF1mV8rma3QW4NIqX9Kyx79N/PF61H5udOV3aY1IaMLs6pGbH71nlCTA==} dependencies: minipass: 2.9.0 dev: true - /fs-readdir-recursive/1.1.0: + /fs-readdir-recursive@1.1.0: resolution: {integrity: sha512-GNanXlVr2pf02+sPN40XN8HG+ePaNcvM0q5mZBd668Obwb0yD5GiUbZOFgwn8kGMY6I3mdyDJzieUy3PTYyTRA==} dev: true - /fs.realpath/1.0.0: + /fs.realpath@1.0.0: resolution: {integrity: sha512-OO0pH2lK6a0hZnAdau5ItzHPI6pUlvI7jMVnxUQRtw4owF2wk8lOSabtGDCTP4Ggrg2MbGnWO9X8K1t4+fGMDw==} dev: true - /fsevents/2.1.3: + /fsevents@2.1.3: resolution: {integrity: sha512-Auw9a4AxqWpa9GUfj370BMPzzyncfBABW8Mab7BGWBYDj4Isgq+cDKtx0i6u9jcX9pQDnswsaaOTgTmA5pEjuQ==} engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} os: [darwin] @@ -5700,7 +5730,7 @@ packages: dev: true optional: true - /fsevents/2.3.2: + /fsevents@2.3.2: resolution: {integrity: sha512-xiqMQR4xAeHTuB9uWm+fFRcIOgKBMiOBP+eXiyT7jsgVCq1bkVygt00oASowB7EdtpOHaaPgKt812P9ab+DDKA==} engines: {node: ^8.16.0 || ^10.6.0 || >=11.0.0} os: [darwin] @@ -5708,11 +5738,11 @@ packages: dev: true optional: true - /function-bind/1.1.1: + /function-bind@1.1.1: resolution: {integrity: sha512-yIovAzMX49sF8Yl58fSCWJ5svSLuaibPxXQJFLmBObTuCr0Mf1KiPopGM9NiFjiYBCbfaa2Fh6breQ6ANVTI0A==} dev: true - /function.prototype.name/1.1.5: + /function.prototype.name@1.1.5: resolution: {integrity: sha512-uN7m/BzVKQnCUF/iW8jYea67v++2u7m5UgENbHRtdDVclOUP+FMPlCNdmk0h/ysGyo2tavMJEDqJAkJdRa1vMA==} engines: {node: '>= 0.4'} dependencies: @@ -5722,15 +5752,15 @@ packages: functions-have-names: 1.2.3 dev: true - /functional-red-black-tree/1.0.1: + /functional-red-black-tree@1.0.1: resolution: {integrity: sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g==} dev: true - /functions-have-names/1.2.3: + /functions-have-names@1.2.3: resolution: {integrity: sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ==} dev: true - /ganache-core/2.13.2: + /ganache-core@2.13.2: resolution: {integrity: sha512-tIF5cR+ANQz0+3pHWxHjIwHqFXcVo0Mb+kcsNhglNFALcYo49aQpnS9dqHartqPfMFjiHh/qFoD3mYK0d/qGgw==} engines: {node: '>=8.9.0'} deprecated: ganache-core is now ganache; visit https://trfl.io/g7 for details @@ -5740,7 +5770,7 @@ packages: bip39: 2.5.0 cachedown: 1.0.0 clone: 2.1.2 - debug: 3.2.6 + debug: 3.2.6(supports-color@6.0.0) encoding-down: 5.0.4 eth-sig-util: 3.0.0 ethereumjs-abi: 0.6.8 @@ -5774,19 +5804,19 @@ packages: bundledDependencies: - keccak - /get-caller-file/1.0.3: + /get-caller-file@1.0.3: resolution: {integrity: sha512-3t6rVToeoZfYSGd8YoLFR2DJkiQrIiUrGcjvFX2mDw3bn6k2OtwHN0TNCLbBO+w8qTvimhDkv+LSscbJY1vE6w==} dev: true - /get-caller-file/2.0.5: + /get-caller-file@2.0.5: resolution: {integrity: sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg==} engines: {node: 6.* || 8.* || >= 10.*} dev: true - /get-func-name/2.0.0: + /get-func-name@2.0.0: resolution: {integrity: sha512-Hm0ixYtaSZ/V7C8FJrtZIuBBI+iSgL+1Aq82zSu8VQNB4S3Gk8e7Qs3VwBDJAhmRZcFqkl3tQu36g/Foh5I5ig==} - /get-intrinsic/1.1.3: + /get-intrinsic@1.1.3: resolution: {integrity: sha512-QJVz1Tj7MS099PevUG5jvnt9tSkXN8K14dxQlikJuPt4uD9hHAHjLyLBiLR5zELelBdD9QNRAXZzsJx0WaDL9A==} dependencies: function-bind: 1.1.1 @@ -5794,36 +5824,36 @@ packages: has-symbols: 1.0.3 dev: true - /get-port/3.2.0: + /get-port@3.2.0: resolution: {integrity: sha512-x5UJKlgeUiNT8nyo/AcnwLnZuZNcSjSw0kogRB+Whd1fjjFq4B1hySFxSFWWSn4mIBzg3sRNUDFYc4g5gjPoLg==} engines: {node: '>=4'} dev: true - /get-stream/3.0.0: + /get-stream@3.0.0: resolution: {integrity: sha512-GlhdIUuVakc8SJ6kK0zAFbiGzRFzNnY4jUuEbV9UROo4Y+0Ny4fjvcZFVTeDA4odpFyOQzaw6hXukJSq/f28sQ==} engines: {node: '>=4'} dev: true - /get-stream/4.1.0: + /get-stream@4.1.0: resolution: {integrity: sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==} engines: {node: '>=6'} dependencies: pump: 3.0.0 dev: true - /get-stream/5.1.0: + /get-stream@5.1.0: resolution: {integrity: sha512-EXr1FOzrzTfGeL0gQdeFEvOMm2mzMOglyiOXSTpPC+iAjAKftbr3jpCMWynogwYnM+eSj9sHGc6wjIcDvYiygw==} engines: {node: '>=8'} dependencies: pump: 3.0.0 dev: true - /get-stream/6.0.1: + /get-stream@6.0.1: resolution: {integrity: sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==} engines: {node: '>=10'} dev: true - /get-symbol-description/1.0.0: + /get-symbol-description@1.0.0: resolution: {integrity: sha512-2EmdH1YvIQiZpltCNgkuiUnyukzxM/R6NDJX31Ke3BG1Nq5b0S2PhX59UKi9vZpPDQVdqn+1IcaAwnzTT5vCjw==} engines: {node: '>= 0.4'} dependencies: @@ -5831,18 +5861,18 @@ packages: get-intrinsic: 1.1.3 dev: true - /get-value/2.0.6: + /get-value@2.0.6: resolution: {integrity: sha512-Ln0UQDlxH1BapMu3GPtf7CuYNwRZf2gwCuPqbyG6pB8WfmFpzqcy4xtAaAMUhnNqjMKTiCPZG2oMT3YSx8U2NA==} engines: {node: '>=0.10.0'} dev: true - /getpass/0.1.7: + /getpass@0.1.7: resolution: {integrity: sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng==} dependencies: assert-plus: 1.0.0 dev: true - /ghost-testrpc/0.0.2: + /ghost-testrpc@0.0.2: resolution: {integrity: sha512-i08dAEgJ2g8z5buJIrCTduwPIhih3DP+hOCTyyryikfV8T0bNvHnGXO67i0DD1H4GBDETTclPy9njZbfluQYrQ==} hasBin: true dependencies: @@ -5850,21 +5880,21 @@ packages: node-emoji: 1.11.0 dev: true - /glob-parent/5.1.2: + /glob-parent@5.1.2: resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==} engines: {node: '>= 6'} dependencies: is-glob: 4.0.3 dev: true - /glob-parent/6.0.2: + /glob-parent@6.0.2: resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==} engines: {node: '>=10.13.0'} dependencies: is-glob: 4.0.3 dev: true - /glob/5.0.15: + /glob@5.0.15: resolution: {integrity: sha512-c9IPMazfRITpmAAKi22dK1VKxGDX9ehhqfABDriL/lzO92xcUKEJPQHrVA/2YHSNFB4iFlykVmWvwo48nr3OxA==} dependencies: inflight: 1.0.6 @@ -5874,7 +5904,7 @@ packages: path-is-absolute: 1.0.1 dev: true - /glob/7.1.3: + /glob@7.1.3: resolution: {integrity: sha512-vcfuiIxogLV4DlGBHIUOwI0IbrJ8HWPc4MU7HzviGeNho/UJDfi6B5p3sHeWIQ0KGIU0Jpxi5ZHxemQfLkkAwQ==} dependencies: fs.realpath: 1.0.0 @@ -5885,7 +5915,7 @@ packages: path-is-absolute: 1.0.1 dev: true - /glob/7.1.7: + /glob@7.1.7: resolution: {integrity: sha512-OvD9ENzPLbegENnYP5UUfJIirTg4+XwMWGaQfQTY0JenxNvvIKP3U3/tAQSPIu/lHxXYSZmpXlUHeqAIdKzBLQ==} dependencies: fs.realpath: 1.0.0 @@ -5896,7 +5926,7 @@ packages: path-is-absolute: 1.0.1 dev: true - /glob/7.2.0: + /glob@7.2.0: resolution: {integrity: sha512-lmLf6gtyrPq8tTjSmrO94wBeQbFR3HbLHbuyD69wuyQkImp2hWqMGB47OX65FBkPffO641IP9jWa1z4ivqG26Q==} dependencies: fs.realpath: 1.0.0 @@ -5907,7 +5937,7 @@ packages: path-is-absolute: 1.0.1 dev: true - /glob/7.2.3: + /glob@7.2.3: resolution: {integrity: sha512-nFR0zLpU2YCaRxwoCJvL6UvCH2JFyFVIvwTLsIf21AuHlMskA1hhTdk+LlYJtOlYt9v6dvszD2BGRqBL+iQK9Q==} dependencies: fs.realpath: 1.0.0 @@ -5918,7 +5948,7 @@ packages: path-is-absolute: 1.0.1 dev: true - /glob/8.1.0: + /glob@8.1.0: resolution: {integrity: sha512-r8hpEjiQEYlF2QU0df3dS+nxxSIreXQS1qRhMJM0Q5NDdR386C7jb7Hwwod8Fgiuex+k0GFjgft18yvxm5XoCQ==} engines: {node: '>=12'} dependencies: @@ -5929,14 +5959,14 @@ packages: once: 1.4.0 dev: true - /global-modules/2.0.0: + /global-modules@2.0.0: resolution: {integrity: sha512-NGbfmJBp9x8IxyJSd1P+otYK8vonoJactOogrVfFRIAEY1ukil8RSKDz2Yo7wh1oihl51l/r6W4epkeKJHqL8A==} engines: {node: '>=6'} dependencies: global-prefix: 3.0.0 dev: true - /global-prefix/3.0.0: + /global-prefix@3.0.0: resolution: {integrity: sha512-awConJSVCHVGND6x3tmMaKcQvwXLhjdkmomy2W+Goaui8YPgYgXJZewhg3fWC+DlfqqQuWg8AwqjGTD2nAPVWg==} engines: {node: '>=6'} dependencies: @@ -5945,26 +5975,26 @@ packages: which: 1.3.1 dev: true - /global/4.3.2: + /global@4.3.2: resolution: {integrity: sha512-/4AybdwIDU4HkCUbJkZdWpe4P6vuw/CUtu+0I1YlLIPe7OlUO7KNJ+q/rO70CW2/NW6Jc6I62++Hzsf5Alu6rQ==} dependencies: min-document: 2.19.0 process: 0.5.2 dev: true - /globals/13.20.0: + /globals@13.20.0: resolution: {integrity: sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==} engines: {node: '>=8'} dependencies: type-fest: 0.20.2 dev: true - /globals/9.18.0: + /globals@9.18.0: resolution: {integrity: sha512-S0nG3CLEQiY/ILxqtztTWH/3iRRdyBLw6KMDxnKMchrtbj2OFmehVh0WUCfW3DUrIgx/qFrJPICrq4Z4sTR9UQ==} engines: {node: '>=0.10.0'} dev: true - /globby/10.0.2: + /globby@10.0.2: resolution: {integrity: sha512-7dUi7RvCoT/xast/o/dLN53oqND4yk0nsHkhRgn9w65C4PofCLOoJ39iSOg+qVDdWQPIEj+eszMHQ+aLVwwQSg==} engines: {node: '>=8'} dependencies: @@ -5978,7 +6008,7 @@ packages: slash: 3.0.0 dev: true - /globby/11.1.0: + /globby@11.1.0: resolution: {integrity: sha512-jhIXaOzy1sb8IyocaruWSn1TjmnBVs8Ayhcy83rmxNJ8q2uWKCAj3CnJY+KpGSXCueAPc0i05kVvVKtP1t9S3g==} engines: {node: '>=10'} dependencies: @@ -5990,7 +6020,7 @@ packages: slash: 3.0.0 dev: true - /got/12.1.0: + /got@12.1.0: resolution: {integrity: sha512-hBv2ty9QN2RdbJJMK3hesmSkFTjVIHyIDDbssCKnSmq62edGgImJWD10Eb1k77TiV1bxloxqcFAVK8+9pkhOig==} engines: {node: '>=14.16'} dependencies: @@ -6009,7 +6039,7 @@ packages: responselike: 2.0.1 dev: true - /got/7.1.0: + /got@7.1.0: resolution: {integrity: sha512-Y5WMo7xKKq1muPsxD+KmrR8DH5auG7fBdDVueZwETwV6VytKyU9OX/ddpq2/1hp1vIPvVb4T81dKQz3BivkNLw==} engines: {node: '>=4'} dependencies: @@ -6031,7 +6061,7 @@ packages: url-to-options: 1.0.1 dev: true - /got/9.6.0: + /got@9.6.0: resolution: {integrity: sha512-R7eWptXuGYxwijs0eV+v3o6+XH1IqVK8dJOEecQfTmkncw9AV4dcw/Dhxi8MdlqPthxxpZyizMzyg8RTmEsG+Q==} engines: {node: '>=8.6'} dependencies: @@ -6050,24 +6080,24 @@ packages: url-parse-lax: 3.0.0 dev: true - /graceful-fs/4.2.10: + /graceful-fs@4.2.10: resolution: {integrity: sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA==} dev: true - /grapheme-splitter/1.0.4: + /grapheme-splitter@1.0.4: resolution: {integrity: sha512-bzh50DW9kTPM00T8y4o8vQg89Di9oLJVLW/KaOGIXJWP/iqCN6WKYkbNOF04vFLJhwcpYUh9ydh/+5vpOqV4YQ==} dev: true - /graphemer/1.4.0: + /graphemer@1.4.0: resolution: {integrity: sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==} dev: true - /growl/1.10.5: + /growl@1.10.5: resolution: {integrity: sha512-qBr4OuELkhPenW6goKVXiv47US3clb3/IbuWF9KNKEijAy9oeHxU9IgzjvJhHkUzhaj7rOUD7+YGWqUjLp5oSA==} engines: {node: '>=4.x'} dev: true - /handlebars/4.7.7: + /handlebars@4.7.7: resolution: {integrity: sha512-aAcXm5OAfE/8IXkcZvCepKU3VzW1/39Fb5ZuqMtgI/hT8X2YgoMvBY5dLhq/cpOvw7Lk1nK/UF71aLG/ZnVYRA==} engines: {node: '>=0.4.7'} hasBin: true @@ -6080,12 +6110,12 @@ packages: uglify-js: 3.17.3 dev: true - /har-schema/2.0.0: + /har-schema@2.0.0: resolution: {integrity: sha512-Oqluz6zhGX8cyRaTQlFMPw80bSJVG2x/cFb8ZPhUILGgHka9SsokCCOQgpveePerqidZOrT14ipqfJb7ILcW5Q==} engines: {node: '>=4'} dev: true - /har-validator/5.1.5: + /har-validator@5.1.5: resolution: {integrity: sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w==} engines: {node: '>=6'} deprecated: this library is no longer supported @@ -6094,39 +6124,39 @@ packages: har-schema: 2.0.0 dev: true - /hardhat-abi-exporter/2.2.1_hardhat@2.12.7: + /hardhat-abi-exporter@2.2.1(hardhat@2.12.7): resolution: {integrity: sha512-Um7+RPvJEj+OqWjPoPKlTTkO1Akr10pqpgMk8Pw2jz2wrGv5XQBGNW5aQgGVDUosYktUIWDaEhcwwFKbFsir9A==} engines: {node: '>=12.10.0'} peerDependencies: hardhat: ^2.0.0 dependencies: - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) dev: true - /hardhat-contract-sizer/2.5.1_hardhat@2.12.7: + /hardhat-contract-sizer@2.5.1(hardhat@2.12.7): resolution: {integrity: sha512-28yRb73e30aBVaZOOHTlHZFIdIasA/iFunIehrUviIJTubvdQjtSiQUo2wexHFtt71mQeMPP8qjw2sdbgatDnQ==} peerDependencies: hardhat: ^2.0.0 dependencies: chalk: 4.1.2 cli-table3: 0.6.3 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) dev: true - /hardhat-gas-reporter/1.0.9_hardhat@2.12.7: + /hardhat-gas-reporter@1.0.9(hardhat@2.12.7): resolution: {integrity: sha512-INN26G3EW43adGKBNzYWOlI3+rlLnasXTwW79YNnUhXPDa+yHESgt639dJEs37gCjhkbNKcRRJnomXEuMFBXJg==} peerDependencies: hardhat: ^2.0.2 dependencies: array-uniq: 1.0.3 eth-gas-reporter: 0.2.25 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) sha1: 1.1.1 transitivePeerDependencies: - '@codechecks/client' dev: true - /hardhat-ignore-warnings/0.2.9: + /hardhat-ignore-warnings@0.2.9: resolution: {integrity: sha512-q1oj6/ixiAx+lgIyGLBajVCSC7qUtAoK7LS9Nr8UVHYo8Iuh5naBiVGo4RDJ6wxbDGYBkeSukUGZrMqzC2DWwA==} dependencies: minimatch: 5.1.6 @@ -6134,7 +6164,7 @@ packages: solidity-comments: 0.0.2 dev: true - /hardhat/2.12.7_goz53koj4ourpjwgrks4nqbe6i: + /hardhat@2.12.7(ts-node@10.0.0)(typescript@4.9.5): resolution: {integrity: sha512-voWoN6zn5d8BOEaczSyK/1PyfdeOeI3SbGCFb36yCHTJUt6OIqLb+ZDX30VhA1UsYKzLqG7UnWl3fKJUuANc6A==} engines: {node: ^14.0.0 || ^16.0.0 || ^18.0.0} hasBin: true @@ -6170,7 +6200,7 @@ packages: chalk: 2.4.2 chokidar: 3.5.3 ci-info: 2.0.0 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) enquirer: 2.3.6 env-paths: 2.2.1 ethereum-cryptography: 1.1.2 @@ -6190,10 +6220,10 @@ packages: raw-body: 2.5.1 resolve: 1.17.0 semver: 6.3.0 - solc: 0.7.3_debug@4.3.4 + solc: 0.7.3(debug@4.3.4) source-map-support: 0.5.21 stacktrace-parser: 0.1.10 - ts-node: 10.0.0_zlol4fzmmjgb3bdeviopae4asm + ts-node: 10.0.0(@types/node@15.14.9)(typescript@4.9.5) tsort: 0.0.1 typescript: 4.9.5 undici: 5.19.1 @@ -6205,61 +6235,61 @@ packages: - utf-8-validate dev: true - /has-ansi/2.0.0: + /has-ansi@2.0.0: resolution: {integrity: sha512-C8vBJ8DwUCx19vhm7urhTuUsr4/IyP6l4VzNQDv+ryHQObW3TTTp9yB68WpYgRe2bbaGuZ/se74IqFeVnMnLZg==} engines: {node: '>=0.10.0'} dependencies: ansi-regex: 2.1.1 dev: true - /has-bigints/1.0.2: + /has-bigints@1.0.2: resolution: {integrity: sha512-tSvCKtBr9lkF0Ex0aQiP9N+OpV4zi2r/Nee5VkRDbaqv35RLYMzbwQfFSZZH0kR+Rd6302UJZ2p/bJCEoR3VoQ==} dev: true - /has-flag/1.0.0: + /has-flag@1.0.0: resolution: {integrity: sha512-DyYHfIYwAJmjAjSSPKANxI8bFY9YtFrgkAfinBojQ8YJTOuOuav64tMUJv584SES4xl74PmuaevIyaLESHdTAA==} engines: {node: '>=0.10.0'} dev: true - /has-flag/3.0.0: + /has-flag@3.0.0: resolution: {integrity: sha512-sKJf1+ceQBr4SMkvQnBDNDtf4TXpVhVGateu0t918bl30FnbE2m4vNLX+VWe/dpjlb+HugGYzW7uQXH98HPEYw==} engines: {node: '>=4'} dev: true - /has-flag/4.0.0: + /has-flag@4.0.0: resolution: {integrity: sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==} engines: {node: '>=8'} dev: true - /has-property-descriptors/1.0.0: + /has-property-descriptors@1.0.0: resolution: {integrity: sha512-62DVLZGoiEBDHQyqG4w9xCuZ7eJEwNmJRWw2VY84Oedb7WFcA27fiEVe8oUQx9hAUJ4ekurquucTGwsyO1XGdQ==} dependencies: get-intrinsic: 1.1.3 dev: true - /has-symbol-support-x/1.4.2: + /has-symbol-support-x@1.4.2: resolution: {integrity: sha512-3ToOva++HaW+eCpgqZrCfN51IPB+7bJNVT6CUATzueB5Heb8o6Nam0V3HG5dlDvZU1Gn5QLcbahiKw/XVk5JJw==} dev: true - /has-symbols/1.0.3: + /has-symbols@1.0.3: resolution: {integrity: sha512-l3LCuF6MgDNwTDKkdYGEihYjt5pRPbEg46rtlmnSPlUbgmB8LOIrKJbYYFBSbnPaJexMKtiPO8hmeRjRz2Td+A==} engines: {node: '>= 0.4'} dev: true - /has-to-string-tag-x/1.4.1: + /has-to-string-tag-x@1.4.1: resolution: {integrity: sha512-vdbKfmw+3LoOYVr+mtxHaX5a96+0f3DljYd8JOqvOLsf5mw2Otda2qCDT9qRqLAhrjyQ0h7ual5nOiASpsGNFw==} dependencies: has-symbol-support-x: 1.4.2 dev: true - /has-tostringtag/1.0.0: + /has-tostringtag@1.0.0: resolution: {integrity: sha512-kFjcSNhnlGV1kyoGk7OXKSawH5JOb/LzUc5w9B02hOTO0dfFRjbHQKvg1d6cf3HbeUmtU9VbbV3qzZ2Teh97WQ==} engines: {node: '>= 0.4'} dependencies: has-symbols: 1.0.3 dev: true - /has-value/0.3.1: + /has-value@0.3.1: resolution: {integrity: sha512-gpG936j8/MzaeID5Yif+577c17TxaDmhuyVgSwtnL/q8UUTySg8Mecb+8Cf1otgLoD7DDH75axp86ER7LFsf3Q==} engines: {node: '>=0.10.0'} dependencies: @@ -6268,7 +6298,7 @@ packages: isobject: 2.1.0 dev: true - /has-value/1.0.0: + /has-value@1.0.0: resolution: {integrity: sha512-IBXk4GTsLYdQ7Rvt+GRBrFSVEkmuOUy4re0Xjd9kJSUQpnTrWR4/y9RpfexN9vkAPMFuQoeWKwqzPozRTlasGw==} engines: {node: '>=0.10.0'} dependencies: @@ -6277,12 +6307,12 @@ packages: isobject: 3.0.1 dev: true - /has-values/0.1.4: + /has-values@0.1.4: resolution: {integrity: sha512-J8S0cEdWuQbqD9//tlZxiMuMNmxB8PlEwvYwuxsTmR1G5RXUePEX/SJn7aD0GMLieuZYSwNH0cQuJGwnYunXRQ==} engines: {node: '>=0.10.0'} dev: true - /has-values/1.0.0: + /has-values@1.0.0: resolution: {integrity: sha512-ODYZC64uqzmtfGMEAX/FvZiRyWLpAC3vYnNunURUnkGVTS+mI0smVsWaPydRBsE3g+ok7h960jChO8mFcWlHaQ==} engines: {node: '>=0.10.0'} dependencies: @@ -6290,14 +6320,14 @@ packages: kind-of: 4.0.0 dev: true - /has/1.0.3: + /has@1.0.3: resolution: {integrity: sha512-f2dvO0VU6Oej7RkWJGrehjbzMAjFp5/VKPp5tTpWIV4JHHZK1/BxbFRtf/siA2SWTe09caDmVtYYzWEIbBS4zw==} engines: {node: '>= 0.4.0'} dependencies: function-bind: 1.1.1 dev: true - /hash-base/3.1.0: + /hash-base@3.1.0: resolution: {integrity: sha512-1nmYp/rhMDiE7AYkDw+lLwlAzz0AntGIe51F3RfFfEqyQ3feY2eI/NcwC6umIQVOASPMsWJLJScWKSSvzL9IVA==} engines: {node: '>=4'} dependencies: @@ -6306,51 +6336,51 @@ packages: safe-buffer: 5.2.1 dev: true - /hash.js/1.1.3: + /hash.js@1.1.3: resolution: {integrity: sha512-/UETyP0W22QILqS+6HowevwhEFJ3MBJnwTf75Qob9Wz9t0DPuisL8kW8YZMK62dHAKE1c1p+gY1TtOLY+USEHA==} dependencies: inherits: 2.0.4 minimalistic-assert: 1.0.1 dev: true - /hash.js/1.1.7: + /hash.js@1.1.7: resolution: {integrity: sha512-taOaskGt4z4SOANNseOviYDvjEJinIkRgmp7LbKP2YTTmVxWBl87s/uzK9r+44BclBSp2X7K1hqeNfz9JbBeXA==} dependencies: inherits: 2.0.4 minimalistic-assert: 1.0.1 - /he/1.2.0: + /he@1.2.0: resolution: {integrity: sha512-F/1DnUGPopORZi0ni+CvrCgHQ5FyEAHRLSApuYWMmrbSwoN2Mn/7k+Gl38gJnR7yyDZk6WLXwiGod1JOWNDKGw==} hasBin: true dev: true - /header-case/1.0.1: + /header-case@1.0.1: resolution: {integrity: sha512-i0q9mkOeSuhXw6bGgiQCCBgY/jlZuV/7dZXyZ9c6LcBrqwvT8eT719E9uxE5LiZftdl+z81Ugbg/VvXV4OJOeQ==} dependencies: no-case: 2.3.2 upper-case: 1.1.3 dev: true - /heap/0.2.6: + /heap@0.2.6: resolution: {integrity: sha512-MzzWcnfB1e4EG2vHi3dXHoBupmuXNZzx6pY6HldVS55JKKBoq3xOyzfSaZRkJp37HIhEYC78knabHff3zc4dQQ==} dev: true - /highlight.js/10.7.3: + /highlight.js@10.7.3: resolution: {integrity: sha512-tzcUFauisWKNHaRkN4Wjl/ZA07gENAjFl3J/c480dprkGTg5EQstgaNFqBfUqCq54kZRIEcreTsAgF/m2quD7A==} dev: true - /highlightjs-solidity/2.0.5: + /highlightjs-solidity@2.0.5: resolution: {integrity: sha512-ReXxQSGQkODMUgHcWzVSnfDCDrL2HshOYgw3OlIYmfHeRzUPkfJTUIp95pK4CmbiNG2eMTOmNLpfCz9Zq7Cwmg==} dev: true - /hmac-drbg/1.0.1: + /hmac-drbg@1.0.1: resolution: {integrity: sha512-Tti3gMqLdZfhOQY1Mzf/AanLiqh1WTiJgEj26ZuYQ9fbkLomzGchCws4FyrSd4VkpBfiNhaE1On+lOz894jvXg==} dependencies: hash.js: 1.1.7 minimalistic-assert: 1.0.1 minimalistic-crypto-utils: 1.0.1 - /home-or-tmp/2.0.0: + /home-or-tmp@2.0.0: resolution: {integrity: sha512-ycURW7oUxE2sNiPVw1HVEFsW+ecOpJ5zaj7eC0RlwhibhRBod20muUN8qu/gzx956YrLolVvs1MTXwKgC2rVEg==} engines: {node: '>=0.10.0'} dependencies: @@ -6358,11 +6388,11 @@ packages: os-tmpdir: 1.0.2 dev: true - /hosted-git-info/2.8.9: + /hosted-git-info@2.8.9: resolution: {integrity: sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==} dev: true - /htmlparser2/8.0.1: + /htmlparser2@8.0.1: resolution: {integrity: sha512-4lVbmc1diZC7GUJQtRQ5yBAeUCL1exyMwmForWkRLnwyzWBFxN633SALPMGYaWZvKe9j1pRZJpauvmxENSp/EA==} dependencies: domelementtype: 2.3.0 @@ -6371,7 +6401,7 @@ packages: entities: 4.4.0 dev: true - /http-basic/8.1.3: + /http-basic@8.1.3: resolution: {integrity: sha512-/EcDMwJZh3mABI2NhGfHOGOeOZITqfkEO4p/xK+l3NpyncIHUQBoMvCSF/b5GqvKtySC2srL/GGG3+EtlqlmCw==} engines: {node: '>=6.0.0'} dependencies: @@ -6381,11 +6411,11 @@ packages: parse-cache-control: 1.0.1 dev: true - /http-cache-semantics/4.0.3: + /http-cache-semantics@4.0.3: resolution: {integrity: sha512-TcIMG3qeVLgDr1TEd2XvHaTnMPwYQUQMIBLy+5pLSDKYFc7UIqj39w8EGzZkaxoLv/l2K8HaI0t5AVA+YYgUew==} dev: true - /http-errors/1.7.2: + /http-errors@1.7.2: resolution: {integrity: sha512-uUQBt3H/cSIVfch6i1EuPNy/YsRSOUBXTVfZ+yR7Zjez3qjBz6i9+i4zjNaoqcoFVI4lQJ5plg63TvGfRSDCRg==} engines: {node: '>= 0.6'} dependencies: @@ -6396,7 +6426,7 @@ packages: toidentifier: 1.0.0 dev: true - /http-errors/1.7.3: + /http-errors@1.7.3: resolution: {integrity: sha512-ZTTX0MWrsQ2ZAhA1cejAwDLycFsd7I7nVtnkT3Ol0aqodaKW+0CTZDQ1uBv5whptCnc8e8HeRRJxRs0kmm/Qfw==} engines: {node: '>= 0.6'} dependencies: @@ -6407,7 +6437,7 @@ packages: toidentifier: 1.0.0 dev: true - /http-errors/2.0.0: + /http-errors@2.0.0: resolution: {integrity: sha512-FtwrG/euBzaEjYeRqOgly7G0qviiXoJWnvEH2Z1plBdXgbyjv34pHTSb9zoeHMyDy33+DWy5Wt9Wo+TURtOYSQ==} engines: {node: '>= 0.8'} dependencies: @@ -6418,17 +6448,17 @@ packages: toidentifier: 1.0.1 dev: true - /http-https/1.0.0: + /http-https@1.0.0: resolution: {integrity: sha512-o0PWwVCSp3O0wS6FvNr6xfBCHgt0m1tvPLFOCc2iFDKTRAXhB7m8klDf7ErowFH8POa6dVdGatKU5I1YYwzUyg==} dev: true - /http-response-object/3.0.2: + /http-response-object@3.0.2: resolution: {integrity: sha512-bqX0XTF6fnXSQcEJ2Iuyr75yVakyjIDCqroJQ/aHfSdlM743Cwqoi2nDYMzLGWUcuTWGWy8AAvOKXTfiv6q9RA==} dependencies: '@types/node': 10.17.60 dev: true - /http-signature/1.2.0: + /http-signature@1.2.0: resolution: {integrity: sha512-CAbnr6Rz4CYQkLYUtSNXxQPUH2gK8f3iWexVlsnMeD+GjlsQ0Xsy1cOX+mN3dtxYomRy21CiOzU8Uhw6OwncEQ==} engines: {node: '>=0.8', npm: '>=1.3.7'} dependencies: @@ -6437,7 +6467,7 @@ packages: sshpk: 1.16.1 dev: true - /http2-wrapper/2.1.11: + /http2-wrapper@2.1.11: resolution: {integrity: sha512-aNAk5JzLturWEUiuhAN73Jcbq96R7rTitAoXV54FYMatvihnpD2+6PUgU4ce3D/m5VDbw+F5CsyKSF176ptitQ==} engines: {node: '>=10.19.0'} dependencies: @@ -6445,64 +6475,64 @@ packages: resolve-alpn: 1.2.1 dev: true - /https-proxy-agent/5.0.1: + /https-proxy-agent@5.0.1: resolution: {integrity: sha512-dFcAjpTQFgoLMzC2VwU+C/CbS7uRL0lWmxDITmqm7C+7F0Odmj6s9l6alZc6AELXhrnggM2CeWSXHGOdX2YtwA==} engines: {node: '>= 6'} dependencies: agent-base: 6.0.2 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) transitivePeerDependencies: - supports-color dev: true - /iconv-lite/0.4.24: + /iconv-lite@0.4.24: resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==} engines: {node: '>=0.10.0'} dependencies: safer-buffer: 2.1.2 dev: true - /iconv-lite/0.6.3: + /iconv-lite@0.6.3: resolution: {integrity: sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==} engines: {node: '>=0.10.0'} dependencies: safer-buffer: 2.1.2 dev: true - /idna-uts46-hx/2.3.1: + /idna-uts46-hx@2.3.1: resolution: {integrity: sha512-PWoF9Keq6laYdIRwwCdhTPl60xRqAloYNMQLiyUnG42VjT53oW07BXIRM+NK7eQjzXjAk2gUvX9caRxlnF9TAA==} engines: {node: '>=4.0.0'} dependencies: punycode: 2.1.0 dev: true - /ieee754/1.2.1: + /ieee754@1.2.1: resolution: {integrity: sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==} dev: true - /ignore/5.2.0: + /ignore@5.2.0: resolution: {integrity: sha512-CmxgYGiEPCLhfLnpPp1MoRmifwEIOgjcHXxOBjv7mY96c+eWScsOP9c112ZyLdWHi0FxHjI+4uVhKYp/gcdRmQ==} engines: {node: '>= 4'} dev: true - /ignore/5.2.4: + /ignore@5.2.4: resolution: {integrity: sha512-MAb38BcSbH0eHNBxn7ql2NH/kX33OkB3lZ1BNdh7ENeRChHTYsTvWrMubiIAMNS2llXEEgZ1MUOBtXChP3kaFQ==} engines: {node: '>= 4'} dev: true - /immediate/3.2.3: + /immediate@3.2.3: resolution: {integrity: sha512-RrGCXRm/fRVqMIhqXrGEX9rRADavPiDFSoMb/k64i9XMk8uH4r/Omi5Ctierj6XzNecwDbO4WuFbDD1zmpl3Tg==} dev: true - /immediate/3.3.0: + /immediate@3.3.0: resolution: {integrity: sha512-HR7EVodfFUdQCTIeySw+WDRFJlPcLOJbXfwwZ7Oom6tjsvZ3bOkCDJHehQC3nxJrv7+f9XecwazynjU8e4Vw3Q==} dev: true - /immutable/4.1.0: + /immutable@4.1.0: resolution: {integrity: sha512-oNkuqVTA8jqG1Q6c+UglTOD1xhC1BtjKI7XkCXRkZHrN5m18/XsnUp8Q89GkQO/z+0WjonSvl0FLhDYftp46nQ==} dev: true - /import-fresh/3.3.0: + /import-fresh@3.3.0: resolution: {integrity: sha512-veYYhQa+D1QBKznvhUHxb8faxlrwUnxseDAbAp457E0wLNio2bOSKnjYDhMj+YiAq61xrMGhQk9iXVk5FzgQMw==} engines: {node: '>=6'} dependencies: @@ -6510,35 +6540,35 @@ packages: resolve-from: 4.0.0 dev: true - /imurmurhash/0.1.4: + /imurmurhash@0.1.4: resolution: {integrity: sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==} engines: {node: '>=0.8.19'} dev: true - /indent-string/4.0.0: + /indent-string@4.0.0: resolution: {integrity: sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==} engines: {node: '>=8'} dev: true - /inflight/1.0.6: + /inflight@1.0.6: resolution: {integrity: sha512-k92I/b08q4wvFscXCLvqfsHCrjrF7yiXsQuIVvVE7N82W3+aqpzuUdBbfhWcy/FZR3/4IgflMgKLOsvPDrGCJA==} dependencies: once: 1.4.0 wrappy: 1.0.2 dev: true - /inherits/2.0.3: + /inherits@2.0.3: resolution: {integrity: sha512-x00IRNXNy63jwGkJmzPigoySHbaqpNuzKbBOmzK+g2OdZpQ9w+sxCN+VSB3ja7IAge2OP2qpfxTjeNcyjmW1uw==} dev: true - /inherits/2.0.4: + /inherits@2.0.4: resolution: {integrity: sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==} - /ini/1.3.8: + /ini@1.3.8: resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==} dev: true - /internal-slot/1.0.3: + /internal-slot@1.0.3: resolution: {integrity: sha512-O0DB1JC/sPyZl7cIo78n5dR7eUSwwpYPiXRhTzNxZVAMUuB8vlnRFyLxdrVToks6XPLVnFfbzaVd5WLjhgg+vA==} engines: {node: '>= 0.4'} dependencies: @@ -6547,70 +6577,70 @@ packages: side-channel: 1.0.4 dev: true - /interpret/1.2.0: + /interpret@1.2.0: resolution: {integrity: sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw==} engines: {node: '>= 0.10'} dev: true - /invariant/2.2.4: + /invariant@2.2.4: resolution: {integrity: sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==} dependencies: loose-envify: 1.4.0 dev: true - /invert-kv/1.0.0: + /invert-kv@1.0.0: resolution: {integrity: sha512-xgs2NH9AE66ucSq4cNG1nhSFghr5l6tdL15Pk+jl46bmmBapgoaY/AacXyaDznAqmGL99TiLSQgO/XazFSKYeQ==} engines: {node: '>=0.10.0'} dev: true - /io-ts/1.10.4: + /io-ts@1.10.4: resolution: {integrity: sha512-b23PteSnYXSONJ6JQXRAlvJhuw8KOtkqa87W4wDtvMrud/DTJd5X+NpOOI+O/zZwVq6v0VLAaJ+1EDViKEuN9g==} dependencies: fp-ts: 1.19.3 dev: true - /ipaddr.js/1.9.0: + /ipaddr.js@1.9.0: resolution: {integrity: sha512-M4Sjn6N/+O6/IXSJseKqHoFc+5FdGJ22sXqnjTpdZweHK64MzEPAyQZyEU3R/KRv2GLoa7nNtg/C2Ev6m7z+eA==} engines: {node: '>= 0.10'} dev: true - /is-accessor-descriptor/0.1.6: + /is-accessor-descriptor@0.1.6: resolution: {integrity: sha512-e1BM1qnDbMRG3ll2U9dSK0UMHuWOs3pY3AtcFsmvwPtKL3MML/Q86i+GilLfvqEs4GW+ExB91tQ3Ig9noDIZ+A==} engines: {node: '>=0.10.0'} dependencies: kind-of: 3.2.2 dev: true - /is-accessor-descriptor/1.0.0: + /is-accessor-descriptor@1.0.0: resolution: {integrity: sha512-m5hnHTkcVsPfqx3AKlyttIPb7J+XykHvJP2B9bZDjlhLIoEq4XoK64Vg7boZlVWYK6LUY94dYPEE7Lh0ZkZKcQ==} engines: {node: '>=0.10.0'} dependencies: kind-of: 6.0.3 dev: true - /is-arguments/1.0.4: + /is-arguments@1.0.4: resolution: {integrity: sha512-xPh0Rmt8NE65sNzvyUmWgI1tz3mKq74lGA0mL8LYZcoIzKOzDh6HmrYm3d18k60nHerC8A9Km8kYu87zfSFnLA==} engines: {node: '>= 0.4'} dev: true - /is-arrayish/0.2.1: + /is-arrayish@0.2.1: resolution: {integrity: sha512-zz06S8t0ozoDXMG+ube26zeCTNXcKIPJZJi8hBrF4idCLms4CG9QtK7qBl1boi5ODzFpjswb5JPmHCbMpjaYzg==} dev: true - /is-bigint/1.0.4: + /is-bigint@1.0.4: resolution: {integrity: sha512-zB9CruMamjym81i2JZ3UMn54PKGsQzsJeo6xvN3HJJ4CAsQNB6iRutp2To77OfCNuoxspsIhzaPoO1zyCEhFOg==} dependencies: has-bigints: 1.0.2 dev: true - /is-binary-path/2.1.0: + /is-binary-path@2.1.0: resolution: {integrity: sha512-ZMERYes6pDydyuGidse7OsHxtbI7WVeUEozgR/g7rd0xUimYNlvZRE/K2MgZTjWy725IfelLeVcEM97mmtRGXw==} engines: {node: '>=8'} dependencies: binary-extensions: 2.2.0 dev: true - /is-boolean-object/1.1.2: + /is-boolean-object@1.1.2: resolution: {integrity: sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==} engines: {node: '>= 0.4'} dependencies: @@ -6618,53 +6648,53 @@ packages: has-tostringtag: 1.0.0 dev: true - /is-buffer/1.1.6: + /is-buffer@1.1.6: resolution: {integrity: sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w==} dev: true - /is-buffer/2.0.5: + /is-buffer@2.0.5: resolution: {integrity: sha512-i2R6zNFDwgEHJyQUtJEk0XFi1i0dPFn/oqjK3/vPCcDeJvW5NQ83V8QbicfF1SupOaB0h8ntgBC2YiE7dfyctQ==} engines: {node: '>=4'} dev: true - /is-callable/1.2.7: + /is-callable@1.2.7: resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} engines: {node: '>= 0.4'} dev: true - /is-ci/2.0.0: + /is-ci@2.0.0: resolution: {integrity: sha512-YfJT7rkpQB0updsdHLGWrvhBJfcfzNNawYDNIyQXJz0IViGf75O8EBPKSdvw2rF+LGCsX4FZ8tcr3b19LcZq4w==} hasBin: true dependencies: ci-info: 2.0.0 dev: true - /is-core-module/2.10.0: + /is-core-module@2.10.0: resolution: {integrity: sha512-Erxj2n/LDAZ7H8WNJXd9tw38GYM3dv8rk8Zcs+jJuxYTW7sozH+SS8NtrSjVL1/vpLvWi1hxy96IzjJ3EHTJJg==} dependencies: has: 1.0.3 dev: true - /is-data-descriptor/0.1.4: + /is-data-descriptor@0.1.4: resolution: {integrity: sha512-+w9D5ulSoBNlmw9OHn3U2v51SyoCd0he+bB3xMl62oijhrspxowjU+AIcDY0N3iEJbUEkB15IlMASQsxYigvXg==} engines: {node: '>=0.10.0'} dependencies: kind-of: 3.2.2 dev: true - /is-data-descriptor/1.0.0: + /is-data-descriptor@1.0.0: resolution: {integrity: sha512-jbRXy1FmtAoCjQkVmIVYwuuqDFUbaOeDjmed1tOGPrsMhtJA4rD9tkgA0F1qJ3gRFRXcHYVkdeaP50Q5rE/jLQ==} engines: {node: '>=0.10.0'} dependencies: kind-of: 6.0.3 dev: true - /is-date-object/1.0.2: + /is-date-object@1.0.2: resolution: {integrity: sha512-USlDT524woQ08aoZFzh3/Z6ch9Y/EWXEHQ/AaRN0SkKq4t2Jw2R2339tSXmwuVoY7LLlBCbOIlx2myP/L5zk0g==} engines: {node: '>= 0.4'} dev: true - /is-descriptor/0.1.6: + /is-descriptor@0.1.6: resolution: {integrity: sha512-avDYr0SB3DwO9zsMov0gKCESFYqCnE4hq/4z3TdUlukEy5t9C0YRq7HLrsN52NAcqXKaepeCD0n+B0arnVG3Hg==} engines: {node: '>=0.10.0'} dependencies: @@ -6673,7 +6703,7 @@ packages: kind-of: 5.1.0 dev: true - /is-descriptor/1.0.2: + /is-descriptor@1.0.2: resolution: {integrity: sha512-2eis5WqQGV7peooDyLmNEPUrps9+SXX5c9pL3xEB+4e9HnGuDa7mB7kHxHw4CbqS9k1T2hOH3miL8n8WtiYVtg==} engines: {node: '>=0.10.0'} dependencies: @@ -6682,134 +6712,134 @@ packages: kind-of: 6.0.3 dev: true - /is-docker/2.2.1: + /is-docker@2.2.1: resolution: {integrity: sha512-F+i2BKsFrH66iaUFc0woD8sLy8getkwTwtOBjvs56Cx4CgJDeKQeqfz8wAYiSb8JOprWhHH5p77PbmYCvvUuXQ==} engines: {node: '>=8'} hasBin: true dev: true - /is-extendable/0.1.1: + /is-extendable@0.1.1: resolution: {integrity: sha512-5BMULNob1vgFX6EjQw5izWDxrecWK9AM72rugNr0TFldMOi0fj6Jk+zeKIt0xGj4cEfQIJth4w3OKWOJ4f+AFw==} engines: {node: '>=0.10.0'} dev: true - /is-extendable/1.0.1: + /is-extendable@1.0.1: resolution: {integrity: sha512-arnXMxT1hhoKo9k1LZdmlNyJdDDfy2v0fXjFlmok4+i8ul/6WlbVge9bhM74OpNPQPMGUToDtz+KXa1PneJxOA==} engines: {node: '>=0.10.0'} dependencies: is-plain-object: 2.0.4 dev: true - /is-extglob/2.1.1: + /is-extglob@2.1.1: resolution: {integrity: sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==} engines: {node: '>=0.10.0'} dev: true - /is-finite/1.1.0: + /is-finite@1.1.0: resolution: {integrity: sha512-cdyMtqX/BOqqNBBiKlIVkytNHm49MtMlYyn1zxzvJKWmFMlGzm+ry5BBfYyeY9YmNKbRSo/o7OX9w9ale0wg3w==} engines: {node: '>=0.10.0'} dev: true - /is-fn/1.0.0: + /is-fn@1.0.0: resolution: {integrity: sha512-XoFPJQmsAShb3jEQRfzf2rqXavq7fIqF/jOekp308JlThqrODnMpweVSGilKTCXELfLhltGP2AGgbQGVP8F1dg==} engines: {node: '>=0.10.0'} dev: true - /is-fullwidth-code-point/1.0.0: + /is-fullwidth-code-point@1.0.0: resolution: {integrity: sha512-1pqUqRjkhPJ9miNq9SwMfdvi6lBJcd6eFxvfaivQhaH3SgisfiuudvFntdKOmxuee/77l+FPjKrQjWvmPjWrRw==} engines: {node: '>=0.10.0'} dependencies: number-is-nan: 1.0.1 dev: true - /is-fullwidth-code-point/2.0.0: + /is-fullwidth-code-point@2.0.0: resolution: {integrity: sha512-VHskAKYM8RfSFXwee5t5cbN5PZeq1Wrh6qd5bkyiXIf6UQcN6w/A0eXM9r6t8d+GYOh+o6ZhiEnb88LN/Y8m2w==} engines: {node: '>=4'} dev: true - /is-fullwidth-code-point/3.0.0: + /is-fullwidth-code-point@3.0.0: resolution: {integrity: sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==} engines: {node: '>=8'} dev: true - /is-function/1.0.1: + /is-function@1.0.1: resolution: {integrity: sha512-coTeFCk0VaNTNO/FwMMaI30KOPOIkLp1q5M7dIVDn4Zop70KyGFZqXSgKClBisjrD3S2cVIuD7MD793/lyLGZQ==} dev: true - /is-generator-function/1.0.8: + /is-generator-function@1.0.8: resolution: {integrity: sha512-2Omr/twNtufVZFr1GhxjOMFPAj2sjc/dKaIqBhvo4qciXfJmITGH6ZGd8eZYNHza8t1y0e01AuqRhJwfWp26WQ==} engines: {node: '>= 0.4'} dev: true - /is-glob/4.0.3: + /is-glob@4.0.3: resolution: {integrity: sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==} engines: {node: '>=0.10.0'} dependencies: is-extglob: 2.1.1 dev: true - /is-hex-prefixed/1.0.0: + /is-hex-prefixed@1.0.0: resolution: {integrity: sha512-WvtOiug1VFrE9v1Cydwm+FnXd3+w9GaeVUss5W4v/SLy3UW00vP+6iNF2SdnfiBoLy4bTqVdkftNGTUeOFVsbA==} engines: {node: '>=6.5.0', npm: '>=3'} dev: true - /is-lower-case/1.1.3: + /is-lower-case@1.1.3: resolution: {integrity: sha512-+5A1e/WJpLLXZEDlgz4G//WYSHyQBD32qa4Jd3Lw06qQlv3fJHnp3YIHjTQSGzHMgzmVKz2ZP3rBxTHkPw/lxA==} dependencies: lower-case: 1.1.4 dev: true - /is-negative-zero/2.0.2: + /is-negative-zero@2.0.2: resolution: {integrity: sha512-dqJvarLawXsFbNDeJW7zAz8ItJ9cd28YufuuFzh0G8pNHjJMnY08Dv7sYX2uF5UpQOwieAeOExEYAWWfu7ZZUA==} engines: {node: '>= 0.4'} dev: true - /is-number-object/1.0.7: + /is-number-object@1.0.7: resolution: {integrity: sha512-k1U0IRzLMo7ZlYIfzRu23Oh6MiIFasgpb9X76eqfFZAqwH44UI4KTBvBYIZ1dSL9ZzChTB9ShHfLkR4pdW5krQ==} engines: {node: '>= 0.4'} dependencies: has-tostringtag: 1.0.0 dev: true - /is-number/3.0.0: + /is-number@3.0.0: resolution: {integrity: sha512-4cboCqIpliH+mAvFNegjZQ4kgKc3ZUhQVr3HvWbSh5q3WH2v82ct+T2Y1hdU5Gdtorx/cLifQjqCbL7bpznLTg==} engines: {node: '>=0.10.0'} dependencies: kind-of: 3.2.2 dev: true - /is-number/7.0.0: + /is-number@7.0.0: resolution: {integrity: sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==} engines: {node: '>=0.12.0'} dev: true - /is-object/1.0.1: + /is-object@1.0.1: resolution: {integrity: sha512-+XzmTRB/JXoIdK20Ge8K8PRsP5UlthLaVhIRxzIwQ73jRgER8iRw98DilvERx/tSjOHLy9JM4sKUfLRMB5ui0Q==} dev: true - /is-path-inside/3.0.3: + /is-path-inside@3.0.3: resolution: {integrity: sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==} engines: {node: '>=8'} dev: true - /is-plain-obj/1.1.0: + /is-plain-obj@1.1.0: resolution: {integrity: sha512-yvkRyxmFKEOQ4pNXCmJG5AEQNlXJS5LaONXo5/cLdTZdWvsZ1ioJEonLGAosKlMWE8lwUy/bJzMjcw8az73+Fg==} engines: {node: '>=0.10.0'} dev: true - /is-plain-obj/2.1.0: + /is-plain-obj@2.1.0: resolution: {integrity: sha512-YWnfyRwxL/+SsrWYfOpUtz5b3YD+nyfkHvjbcanzk8zgyO4ASD67uVMRt8k5bM4lLMDnXfriRhOpemw+NfT1eA==} engines: {node: '>=8'} dev: true - /is-plain-object/2.0.4: + /is-plain-object@2.0.4: resolution: {integrity: sha512-h5PpgXkWitc38BBMYawTYMWJHFZJVnBquFE57xFpjB8pJFiF6gZ+bU+WyI/yqXiFR5mdLsgYNaPe8uao6Uv9Og==} engines: {node: '>=0.10.0'} dependencies: isobject: 3.0.1 dev: true - /is-regex/1.1.4: + /is-regex@1.1.4: resolution: {integrity: sha512-kvRdxDsxZjhzUX07ZnLydzS1TU/TJlTUHHY4YLL87e37oUA49DfkLqgy+VjFocowy29cKvcSiu+kIv728jTTVg==} engines: {node: '>= 0.4'} dependencies: @@ -6817,37 +6847,37 @@ packages: has-tostringtag: 1.0.0 dev: true - /is-retry-allowed/1.2.0: + /is-retry-allowed@1.2.0: resolution: {integrity: sha512-RUbUeKwvm3XG2VYamhJL1xFktgjvPzL0Hq8C+6yrWIswDy3BIXGqCxhxkc30N9jqK311gVU137K8Ei55/zVJRg==} engines: {node: '>=0.10.0'} dev: true - /is-shared-array-buffer/1.0.2: + /is-shared-array-buffer@1.0.2: resolution: {integrity: sha512-sqN2UDu1/0y6uvXyStCOzyhAjCSlHceFoMKJW8W9EU9cvic/QdsZ0kEU93HEy3IUEFZIiH/3w+AH/UQbPHNdhA==} dependencies: call-bind: 1.0.2 dev: true - /is-stream/1.1.0: + /is-stream@1.1.0: resolution: {integrity: sha512-uQPm8kcs47jx38atAcWTVxyltQYoPT68y9aWYdV6yWXSyW8mzSat0TL6CiWdZeCdF3KrAvpVtnHbTv4RN+rqdQ==} engines: {node: '>=0.10.0'} dev: true - /is-string/1.0.7: + /is-string@1.0.7: resolution: {integrity: sha512-tE2UXzivje6ofPW7l23cjDOMa09gb7xlAqG6jG5ej6uPV32TlWP3NKPigtaGeHNu9fohccRYvIiZMfOOnOYUtg==} engines: {node: '>= 0.4'} dependencies: has-tostringtag: 1.0.0 dev: true - /is-symbol/1.0.3: + /is-symbol@1.0.3: resolution: {integrity: sha512-OwijhaRSgqvhm/0ZdAcXNZt9lYdKFpcRDT5ULUuYXPoT794UNOdU+gpT6Rzo7b4V2HUl/op6GqY894AZwv9faQ==} engines: {node: '>= 0.4'} dependencies: has-symbols: 1.0.3 dev: true - /is-typed-array/1.1.5: + /is-typed-array@1.1.5: resolution: {integrity: sha512-S+GRDgJlR3PyEbsX/Fobd9cqpZBuvUS+8asRqYDMLCb2qMzt1oz5m5oxQCxOgUDxiWsOVNi4yaF+/uvdlHlYug==} engines: {node: '>= 0.4'} dependencies: @@ -6858,76 +6888,76 @@ packages: has-symbols: 1.0.3 dev: true - /is-typedarray/1.0.0: + /is-typedarray@1.0.0: resolution: {integrity: sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA==} dev: true - /is-unicode-supported/0.1.0: + /is-unicode-supported@0.1.0: resolution: {integrity: sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw==} engines: {node: '>=10'} dev: true - /is-upper-case/1.1.2: + /is-upper-case@1.1.2: resolution: {integrity: sha512-GQYSJMgfeAmVwh9ixyk888l7OIhNAGKtY6QA+IrWlu9MDTCaXmeozOZ2S9Knj7bQwBO/H6J2kb+pbyTUiMNbsw==} dependencies: upper-case: 1.1.3 dev: true - /is-url/1.2.4: + /is-url@1.2.4: resolution: {integrity: sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww==} dev: true - /is-utf8/0.2.1: + /is-utf8@0.2.1: resolution: {integrity: sha512-rMYPYvCzsXywIsldgLaSoPlw5PfoB/ssr7hY4pLfcodrA5M/eArza1a9VmTiNIBNMjOGr1Ow9mTyU2o69U6U9Q==} dev: true - /is-weakref/1.0.2: + /is-weakref@1.0.2: resolution: {integrity: sha512-qctsuLZmIQ0+vSSMfoVvyFe2+GSEvnmZ2ezTup1SBse9+twCCeial6EEi3Nc2KFcf6+qz2FBPnjXsk8xhKSaPQ==} dependencies: call-bind: 1.0.2 dev: true - /is-windows/1.0.2: + /is-windows@1.0.2: resolution: {integrity: sha512-eXK1UInq2bPmjyX6e3VHIzMLobc4J94i4AWn+Hpq3OU5KkrRC96OAcR3PRJ/pGu6m8TRnBHP9dkXQVsT/COVIA==} engines: {node: '>=0.10.0'} dev: true - /is-wsl/2.2.0: + /is-wsl@2.2.0: resolution: {integrity: sha512-fKzAra0rGJUUBwGBgNkHZuToZcn+TtXHpeCgmkMJMMYx1sQDYaCSyjJBSCa2nH1DGm7s3n1oBnohoVTBaN7Lww==} engines: {node: '>=8'} dependencies: is-docker: 2.2.1 dev: true - /isarray/0.0.1: + /isarray@0.0.1: resolution: {integrity: sha512-D2S+3GLxWH+uhrNEcoh/fnmYeP8E8/zHl644d/jdA0g2uyXvy3sb0qxotE+ne0LtccHknQzWwZEzhak7oJ0COQ==} dev: true - /isarray/1.0.0: + /isarray@1.0.0: resolution: {integrity: sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==} dev: true - /isexe/2.0.0: + /isexe@2.0.0: resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==} dev: true - /isobject/2.1.0: + /isobject@2.1.0: resolution: {integrity: sha512-+OUdGJlgjOBZDfxnDjYYG6zp487z0JGNQq3cYQYg5f5hKR+syHMsaztzGeml/4kGG55CSpKSpWTY+jYGgsHLgA==} engines: {node: '>=0.10.0'} dependencies: isarray: 1.0.0 dev: true - /isobject/3.0.1: + /isobject@3.0.1: resolution: {integrity: sha512-WhB9zCku7EGTj/HQQRz5aUQEUeoQZH2bWcltRErOpymJ4boYE6wL9Tbr23krRPSZ+C5zqNSrSw+Cc7sZZ4b7vg==} engines: {node: '>=0.10.0'} dev: true - /isstream/0.1.2: + /isstream@0.1.2: resolution: {integrity: sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g==} dev: true - /istanbul/0.4.5: + /istanbul@0.4.5: resolution: {integrity: sha512-nMtdn4hvK0HjUlzr1DrKSUY8ychprt8dzHOgY2KXsIhHu5PuQQEOTM27gV9Xblyon7aUH/TSFIjRHEODF/FRPg==} deprecated: |- This module is no longer maintained, try this instead: @@ -6951,7 +6981,7 @@ packages: wordwrap: 1.0.0 dev: true - /isurl/1.0.0: + /isurl@1.0.0: resolution: {integrity: sha512-1P/yWsxPlDtn7QeRD+ULKQPaIaN6yF368GZ2vDfv0AL0NwpStafjWCDDdn0k8wgFMWpVAqG7oJhxHnlud42i9w==} engines: {node: '>= 4'} dependencies: @@ -6959,30 +6989,30 @@ packages: is-object: 1.0.1 dev: true - /js-sha3/0.5.5: + /js-sha3@0.5.5: resolution: {integrity: sha512-yLLwn44IVeunwjpDVTDZmQeVbB0h+dZpY2eO68B/Zik8hu6dH+rKeLxwua79GGIvW6xr8NBAcrtiUbYrTjEFTA==} dev: true - /js-sha3/0.5.7: + /js-sha3@0.5.7: resolution: {integrity: sha512-GII20kjaPX0zJ8wzkTbNDYMY7msuZcTWk8S5UOh6806Jq/wz1J8/bnr8uGU0DAUmYDjj2Mr4X1cW8v/GLYnR+g==} dev: true - /js-sha3/0.6.1: + /js-sha3@0.6.1: resolution: {integrity: sha512-2OHj7sAZ9gnJS4lQsgIsTslmqVrNQdDC99bvwYGQKU1w6k/gwsTLeGBfWt8yHCuTOGqk7DXzuVlK8J+dDXnG7A==} dev: true - /js-sha3/0.8.0: + /js-sha3@0.8.0: resolution: {integrity: sha512-gF1cRrHhIzNfToc802P800N8PpXS+evLLXfsVpowqmAFR9uwbi89WvXg2QspOmXL8QL86J4T1EpFu+yUkwJY3Q==} - /js-tokens/3.0.2: + /js-tokens@3.0.2: resolution: {integrity: sha512-RjTcuD4xjtthQkaWH7dFlH85L+QaVtSoOyGdZ3g6HFhS9dFNDfLyqgm2NFe2X6cQpeFmt0452FJjFG5UameExg==} dev: true - /js-tokens/4.0.0: + /js-tokens@4.0.0: resolution: {integrity: sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==} dev: true - /js-yaml/3.13.1: + /js-yaml@3.13.1: resolution: {integrity: sha512-YfbcO7jXDdyj0DGxYVSlSeQNHbD7XPWvrVWeVUujrQEoZzWJIRrCPoyk6kL6IAjAG2IolMK4T0hNUe0HOUs5Jw==} hasBin: true dependencies: @@ -6990,7 +7020,7 @@ packages: esprima: 4.0.1 dev: true - /js-yaml/3.14.1: + /js-yaml@3.14.1: resolution: {integrity: sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==} hasBin: true dependencies: @@ -6998,40 +7028,40 @@ packages: esprima: 4.0.1 dev: true - /js-yaml/4.1.0: + /js-yaml@4.1.0: resolution: {integrity: sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==} hasBin: true dependencies: argparse: 2.0.1 dev: true - /jsbn/0.1.1: + /jsbn@0.1.1: resolution: {integrity: sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg==} dev: true - /jsesc/0.5.0: + /jsesc@0.5.0: resolution: {integrity: sha512-uZz5UnB7u4T9LvwmFqXii7pZSouaRPorGs5who1Ip7VO0wxanFvBL7GkM6dTHlgX+jhBApRetaWpnDabOeTcnA==} hasBin: true dev: true - /jsesc/1.3.0: + /jsesc@1.3.0: resolution: {integrity: sha512-Mke0DA0QjUWuJlhsE0ZPPhYiJkRap642SmI/4ztCFaUs6V2AiH1sfecc+57NgaryfAA2VR3v6O+CSjC1jZJKOA==} hasBin: true dev: true - /json-buffer/3.0.0: + /json-buffer@3.0.0: resolution: {integrity: sha512-CuUqjv0FUZIdXkHPI8MezCnFCdaTAacej1TZYulLoAg1h/PhwkdXFN4V/gzY4g+fMBCOV2xF+rp7t2XD2ns/NQ==} dev: true - /json-buffer/3.0.1: + /json-buffer@3.0.1: resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==} dev: true - /json-parse-even-better-errors/2.3.1: + /json-parse-even-better-errors@2.3.1: resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==} dev: true - /json-rpc-engine/3.8.0: + /json-rpc-engine@3.8.0: resolution: {integrity: sha512-6QNcvm2gFuuK4TKU1uwfH0Qd/cOSb9c1lls0gbnIhciktIUQJwz6NQNAW4B1KiGPenv7IKu97V222Yo1bNhGuA==} dependencies: async: 2.6.3 @@ -7044,43 +7074,43 @@ packages: - supports-color dev: true - /json-rpc-error/2.0.0: + /json-rpc-error@2.0.0: resolution: {integrity: sha512-EwUeWP+KgAZ/xqFpaP6YDAXMtCJi+o/QQpCQFIYyxr01AdADi2y413eM8hSqJcoQym9WMePAJWoaODEJufC4Ug==} dependencies: inherits: 2.0.4 dev: true - /json-rpc-random-id/1.0.1: + /json-rpc-random-id@1.0.1: resolution: {integrity: sha512-RJ9YYNCkhVDBuP4zN5BBtYAzEl03yq/jIIsyif0JY9qyJuQQZNeDK7anAPKKlyEtLSj2s8h6hNh2F8zO5q7ScA==} dev: true - /json-schema-traverse/0.4.1: + /json-schema-traverse@0.4.1: resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==} dev: true - /json-schema-traverse/1.0.0: + /json-schema-traverse@1.0.0: resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==} dev: true - /json-schema/0.2.3: + /json-schema@0.2.3: resolution: {integrity: sha512-a3xHnILGMtk+hDOqNwHzF6e2fNbiMrXZvxKQiEv2MlgQP+pjIOzqAmKYD2mDpXYE/44M7g+n9p2bKkYWDUcXCQ==} dev: true - /json-stable-stringify-without-jsonify/1.0.1: + /json-stable-stringify-without-jsonify@1.0.1: resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==} dev: true - /json-stable-stringify/1.0.1: + /json-stable-stringify@1.0.1: resolution: {integrity: sha512-i/J297TW6xyj7sDFa7AmBPkQvLIxWr2kKPWI26tXydnZrzVAocNqn5DMNT1Mzk0vit1V5UkRM7C1KdVNp7Lmcg==} dependencies: jsonify: 0.0.0 dev: true - /json-stringify-safe/5.0.1: + /json-stringify-safe@5.0.1: resolution: {integrity: sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA==} dev: true - /json-to-ast/2.1.0: + /json-to-ast@2.1.0: resolution: {integrity: sha512-W9Lq347r8tA1DfMvAGn9QNcgYm4Wm7Yc+k8e6vezpMnRT+NHbtlxgNBXRVjXe9YM6eTn6+p/MKOlV/aABJcSnQ==} engines: {node: '>= 4'} dependencies: @@ -7088,24 +7118,24 @@ packages: grapheme-splitter: 1.0.4 dev: true - /json5/0.5.1: + /json5@0.5.1: resolution: {integrity: sha512-4xrs1aW+6N5DalkqSVA8fxh458CXvR99WU8WLKmq4v8eWAL86Xo3BVqyd3SkA9wEVjCMqyvvRRkshAdOnBp5rw==} hasBin: true dev: true - /jsonfile/2.4.0: + /jsonfile@2.4.0: resolution: {integrity: sha512-PKllAqbgLgxHaj8TElYymKCAgrASebJrWpTnEkOaTowt23VKXXN0sUeriJ+eh7y6ufb/CC5ap11pz71/cM0hUw==} optionalDependencies: graceful-fs: 4.2.10 dev: true - /jsonfile/4.0.0: + /jsonfile@4.0.0: resolution: {integrity: sha512-m6F1R3z8jjlf2imQHS2Qez5sjKWQzbuuhuJ/FKYFRZvPE3PuHcSMVZzfsLhGVOkfd20obL5SWEBew5ShlquNxg==} optionalDependencies: graceful-fs: 4.2.10 dev: true - /jsonfile/6.1.0: + /jsonfile@6.1.0: resolution: {integrity: sha512-5dgndWOriYSm5cnYaJNhalLNDKOqFwyDB/rr1E9ZsGciGvKPs8R2xYGCacuf3z6K1YKDz182fd+fY3cn3pMqXQ==} dependencies: universalify: 2.0.0 @@ -7113,20 +7143,20 @@ packages: graceful-fs: 4.2.10 dev: true - /jsonify/0.0.0: + /jsonify@0.0.0: resolution: {integrity: sha512-trvBk1ki43VZptdBI5rIlG4YOzyeH/WefQt5rj1grasPn4iiZWKet8nkgc4GlsAylaztn0qZfUYOiTsASJFdNA==} dev: true - /jsonpointer/5.0.1: + /jsonpointer@5.0.1: resolution: {integrity: sha512-p/nXbhSEcu3pZRdkW1OfJhpsVtW1gd4Wa1fnQc9YLiTfAjn0312eMKimbdIQzuZl9aa9xUGaRlP9T/CJE/ditQ==} engines: {node: '>=0.10.0'} dev: true - /jsonschema/1.4.0: + /jsonschema@1.4.0: resolution: {integrity: sha512-/YgW6pRMr6M7C+4o8kS+B/2myEpHCrxO4PEWnqJNBFMjn7EWXqlQ4tGwL6xTHeRplwuZmcAncdvfOad1nT2yMw==} dev: true - /jsprim/1.4.1: + /jsprim@1.4.1: resolution: {integrity: sha512-4Dj8Rf+fQ+/Pn7C5qeEX02op1WfOss3PKTE9Nsop3Dx+6UPxlm1dr/og7o2cRa5hNN07CACr4NFzRLtj/rjWog==} engines: {'0': node >=0.6.0} dependencies: @@ -7136,7 +7166,7 @@ packages: verror: 1.10.0 dev: true - /keccak/3.0.2: + /keccak@3.0.2: resolution: {integrity: sha512-PyKKjkH53wDMLGrvmRGSNWgmSxZOUqbnXwKL9tmgbFYA1iAYqW21kfR7mZXV0MlESiefxQQE9X9fTa3X+2MPDQ==} engines: {node: '>=10.0.0'} requiresBuild: true @@ -7146,93 +7176,93 @@ packages: readable-stream: 3.6.0 dev: true - /keccakjs/0.2.3: + /keccakjs@0.2.3: resolution: {integrity: sha512-BjLkNDcfaZ6l8HBG9tH0tpmDv3sS2mA7FNQxFHpCdzP3Gb2MVruXBSuoM66SnVxKJpAr5dKGdkHD+bDokt8fTg==} dependencies: browserify-sha3: 0.0.4 sha3: 1.2.6 dev: true - /keyv/3.1.0: + /keyv@3.1.0: resolution: {integrity: sha512-9ykJ/46SN/9KPM/sichzQ7OvXyGDYKGTaDlKMGCAlg2UK8KRy4jb0d8sFc+0Tt0YYnThq8X2RZgCg74RPxgcVA==} dependencies: json-buffer: 3.0.0 dev: true - /keyv/4.5.0: + /keyv@4.5.0: resolution: {integrity: sha512-2YvuMsA+jnFGtBareKqgANOEKe1mk3HKiXu2fRmAfyxG0MJAywNhi5ttWA3PMjl4NmpyjZNbFifR2vNjW1znfA==} dependencies: json-buffer: 3.0.1 dev: true - /kind-of/3.2.2: + /kind-of@3.2.2: resolution: {integrity: sha512-NOW9QQXMoZGg/oqnVNoNTTIFEIid1627WCffUBJEdMxYApq7mNE7CpzucIPc+ZQg25Phej7IJSmX3hO+oblOtQ==} engines: {node: '>=0.10.0'} dependencies: is-buffer: 1.1.6 dev: true - /kind-of/4.0.0: + /kind-of@4.0.0: resolution: {integrity: sha512-24XsCxmEbRwEDbz/qz3stgin8TTzZ1ESR56OMCN0ujYg+vRutNSiOj9bHH9u85DKgXguraugV5sFuvbD4FW/hw==} engines: {node: '>=0.10.0'} dependencies: is-buffer: 1.1.6 dev: true - /kind-of/5.1.0: + /kind-of@5.1.0: resolution: {integrity: sha512-NGEErnH6F2vUuXDh+OlbcKW7/wOcfdRHaZ7VWtqCztfHri/++YKmP51OdWeGPuqCOba6kk2OTe5d02VmTB80Pw==} engines: {node: '>=0.10.0'} dev: true - /kind-of/6.0.3: + /kind-of@6.0.3: resolution: {integrity: sha512-dcS1ul+9tmeD95T+x28/ehLgd9mENa3LsvDTtzm3vyBEO7RPptvAD+t44WVXaUjTBRcrpFeFlC8WCruUR456hw==} engines: {node: '>=0.10.0'} dev: true - /klaw-sync/6.0.0: + /klaw-sync@6.0.0: resolution: {integrity: sha512-nIeuVSzdCCs6TDPTqI8w1Yre34sSq7AkZ4B3sfOBbI2CgVSB4Du4aLQijFU2+lhAFCwt9+42Hel6lQNIv6AntQ==} dependencies: graceful-fs: 4.2.10 dev: true - /klaw/1.3.1: + /klaw@1.3.1: resolution: {integrity: sha512-TED5xi9gGQjGpNnvRWknrwAB1eL5GciPfVFOt3Vk1OJCVDQbzuSfrF3hkUQKlsgKrG1F+0t5W0m+Fje1jIt8rw==} optionalDependencies: graceful-fs: 4.2.10 dev: true - /lcid/1.0.0: + /lcid@1.0.0: resolution: {integrity: sha512-YiGkH6EnGrDGqLMITnGjXtGmNtjoXw9SVUzcaos8RBi7Ps0VBylkq+vOcY9QE5poLasPCR849ucFUkl0UzUyOw==} engines: {node: '>=0.10.0'} dependencies: invert-kv: 1.0.0 dev: true - /level-codec/7.0.1: + /level-codec@7.0.1: resolution: {integrity: sha512-Ua/R9B9r3RasXdRmOtd+t9TCOEIIlts+TN/7XTT2unhDaL6sJn83S3rUyljbr6lVtw49N3/yA0HHjpV6Kzb2aQ==} dev: true - /level-codec/9.0.2: + /level-codec@9.0.2: resolution: {integrity: sha512-UyIwNb1lJBChJnGfjmO0OR+ezh2iVu1Kas3nvBS/BzGnx79dv6g7unpKIDNPMhfdTEGoc7mC8uAu51XEtX+FHQ==} engines: {node: '>=6'} dependencies: buffer: 5.7.1 dev: true - /level-errors/1.0.5: + /level-errors@1.0.5: resolution: {integrity: sha512-/cLUpQduF6bNrWuAC4pwtUKA5t669pCsCi2XbmojG2tFeOr9j6ShtdDCtFFQO1DRt+EVZhx9gPzP9G2bUaG4ig==} dependencies: errno: 0.1.8 dev: true - /level-errors/2.0.1: + /level-errors@2.0.1: resolution: {integrity: sha512-UVprBJXite4gPS+3VznfgDSU8PTRuVX0NXwoWW50KLxd2yw4Y1t2JUR5In1itQnudZqRMT9DlAM3Q//9NCjCFw==} engines: {node: '>=6'} dependencies: errno: 0.1.8 dev: true - /level-iterator-stream/1.3.1: + /level-iterator-stream@1.3.1: resolution: {integrity: sha512-1qua0RHNtr4nrZBgYlpV0qHHeHpcRRWTxEZJ8xsemoHAXNL5tbooh4tPEEqIqsbWCAJBmUmkwYK/sW5OrFjWWw==} dependencies: inherits: 2.0.4 @@ -7241,7 +7271,7 @@ packages: xtend: 4.0.2 dev: true - /level-iterator-stream/2.0.3: + /level-iterator-stream@2.0.3: resolution: {integrity: sha512-I6Heg70nfF+e5Y3/qfthJFexhRw/Gi3bIymCoXAlijZdAcLaPuWSJs3KXyTYf23ID6g0o2QF62Yh+grOXY3Rig==} engines: {node: '>=4'} dependencies: @@ -7250,7 +7280,7 @@ packages: xtend: 4.0.2 dev: true - /level-iterator-stream/3.0.1: + /level-iterator-stream@3.0.1: resolution: {integrity: sha512-nEIQvxEED9yRThxvOrq8Aqziy4EGzrxSZK+QzEFAVuJvQ8glfyZ96GB6BoI4sBbLfjMXm2w4vu3Tkcm9obcY0g==} engines: {node: '>=6'} dependencies: @@ -7259,7 +7289,7 @@ packages: xtend: 4.0.2 dev: true - /level-mem/3.0.1: + /level-mem@3.0.1: resolution: {integrity: sha512-LbtfK9+3Ug1UmvvhR2DqLqXiPW1OJ5jEh0a3m9ZgAipiwpSxGj/qaVVy54RG5vAQN1nCuXqjvprCuKSCxcJHBg==} engines: {node: '>=6'} dependencies: @@ -7267,7 +7297,7 @@ packages: memdown: 3.0.0 dev: true - /level-packager/4.0.1: + /level-packager@4.0.1: resolution: {integrity: sha512-svCRKfYLn9/4CoFfi+d8krOtrp6RoX8+xm0Na5cgXMqSyRru0AnDYdLl+YI8u1FyS6gGZ94ILLZDE5dh2but3Q==} engines: {node: '>=6'} dependencies: @@ -7275,13 +7305,13 @@ packages: levelup: 3.1.1 dev: true - /level-post/1.0.7: + /level-post@1.0.7: resolution: {integrity: sha512-PWYqG4Q00asOrLhX7BejSajByB4EmG2GaKHfj3h5UmmZ2duciXLPGYWIjBzLECFWUGOZWlm5B20h/n3Gs3HKew==} dependencies: ltgt: 2.2.1 dev: true - /level-sublevel/6.6.4: + /level-sublevel@6.6.4: resolution: {integrity: sha512-pcCrTUOiO48+Kp6F1+UAzF/OtWqLcQVTVF39HLdZ3RO8XBoXt+XVPKZO1vVr1aUoxHZA9OtD2e1v7G+3S5KFDA==} dependencies: bytewise: 1.1.0 @@ -7296,12 +7326,12 @@ packages: xtend: 4.0.2 dev: true - /level-supports/4.0.1: + /level-supports@4.0.1: resolution: {integrity: sha512-PbXpve8rKeNcZ9C1mUicC9auIYFyGpkV9/i6g76tLgANwWhtG2v7I4xNBUlkn3lE2/dZF3Pi0ygYGtLc4RXXdA==} engines: {node: '>=12'} dev: true - /level-transcoder/1.0.1: + /level-transcoder@1.0.1: resolution: {integrity: sha512-t7bFwFtsQeD8cl8NIoQ2iwxA0CL/9IFw7/9gAjOonH0PWTTiRfY7Hq+Ejbsxh86tXobDQ6IOiddjNYIfOBs06w==} engines: {node: '>=12'} dependencies: @@ -7309,14 +7339,14 @@ packages: module-error: 1.0.2 dev: true - /level-ws/0.0.0: + /level-ws@0.0.0: resolution: {integrity: sha512-XUTaO/+Db51Uiyp/t7fCMGVFOTdtLS/NIACxE/GHsij15mKzxksZifKVjlXDF41JMUP/oM1Oc4YNGdKnc3dVLw==} dependencies: readable-stream: 1.0.34 xtend: 2.1.2 dev: true - /level-ws/1.0.0: + /level-ws@1.0.0: resolution: {integrity: sha512-RXEfCmkd6WWFlArh3X8ONvQPm8jNpfA0s/36M4QzLqrLEIt1iJE9WBHLZ5vZJK6haMjJPJGJCQWfjMNnRcq/9Q==} engines: {node: '>=6'} dependencies: @@ -7325,7 +7355,7 @@ packages: xtend: 4.0.2 dev: true - /level/8.0.0: + /level@8.0.0: resolution: {integrity: sha512-ypf0jjAk2BWI33yzEaaotpq7fkOPALKAgDBxggO6Q9HGX2MRXn0wbP1Jn/tJv1gtL867+YOjOB49WaUF3UoJNQ==} engines: {node: '>=12'} dependencies: @@ -7333,7 +7363,7 @@ packages: classic-level: 1.2.0 dev: true - /levelup/1.3.9: + /levelup@1.3.9: resolution: {integrity: sha512-VVGHfKIlmw8w1XqpGOAGwq6sZm2WwWLmlDcULkKWQXEA5EopA8OBNJ2Ck2v6bdk8HeEZSbCSEgzXadyQFm76sQ==} dependencies: deferred-leveldown: 1.2.2 @@ -7345,7 +7375,7 @@ packages: xtend: 4.0.2 dev: true - /levelup/3.1.1: + /levelup@3.1.1: resolution: {integrity: sha512-9N10xRkUU4dShSRRFTBdNaBxofz+PGaIZO962ckboJZiNmLuhVT6FZ6ZKAsICKfUBO76ySaYU6fJWX/jnj3Lcg==} engines: {node: '>=6'} dependencies: @@ -7355,12 +7385,12 @@ packages: xtend: 4.0.2 dev: true - /leven/3.1.0: + /leven@3.1.0: resolution: {integrity: sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==} engines: {node: '>=6'} dev: true - /levn/0.3.0: + /levn@0.3.0: resolution: {integrity: sha512-0OO4y2iOHix2W6ujICbKIaEQXvFQHue65vUG3pb5EUomzPI90z9hsA1VsO/dbIIpC53J8gxM9Q4Oho0jrCM/yA==} engines: {node: '>= 0.8.0'} dependencies: @@ -7368,7 +7398,7 @@ packages: type-check: 0.3.2 dev: true - /levn/0.4.1: + /levn@0.4.1: resolution: {integrity: sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==} engines: {node: '>= 0.8.0'} dependencies: @@ -7376,11 +7406,11 @@ packages: type-check: 0.4.0 dev: true - /lines-and-columns/1.2.4: + /lines-and-columns@1.2.4: resolution: {integrity: sha512-7ylylesZQ/PV29jhEDl3Ufjo6ZX7gCqJr5F7PKrqc93v7fzSymt1BpwEU8nAUXs8qzzvqhbjhK5QZg6Mt/HkBg==} dev: true - /load-json-file/1.1.0: + /load-json-file@1.1.0: resolution: {integrity: sha512-cy7ZdNRXdablkXYNI049pthVeXFurRyb9+hA/dZzerZ0pGTx42z+y+ssxBaVV2l70t1muq5IdKhn4UtcoGUY9A==} engines: {node: '>=0.10.0'} dependencies: @@ -7391,7 +7421,7 @@ packages: strip-bom: 2.0.0 dev: true - /locate-path/2.0.0: + /locate-path@2.0.0: resolution: {integrity: sha512-NCI2kiDkyR7VeEKm27Kda/iQHyKJe1Bu0FlTbYp3CqJu+9IFe9bLyAjMxf5ZDDbEg+iMPzB5zYyUTSm8wVTKmA==} engines: {node: '>=4'} dependencies: @@ -7399,7 +7429,7 @@ packages: path-exists: 3.0.0 dev: true - /locate-path/3.0.0: + /locate-path@3.0.0: resolution: {integrity: sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==} engines: {node: '>=6'} dependencies: @@ -7407,60 +7437,60 @@ packages: path-exists: 3.0.0 dev: true - /locate-path/5.0.0: + /locate-path@5.0.0: resolution: {integrity: sha512-t7hw9pI+WvuwNJXwk5zVHpyhIqzg2qTlklJOf0mVxGSbe3Fp2VieZcduNYjaLDoy6p9uGpQEGWG87WpMKlNq8g==} engines: {node: '>=8'} dependencies: p-locate: 4.1.0 dev: true - /locate-path/6.0.0: + /locate-path@6.0.0: resolution: {integrity: sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==} engines: {node: '>=10'} dependencies: p-locate: 5.0.0 dev: true - /lodash.assign/4.2.0: + /lodash.assign@4.2.0: resolution: {integrity: sha512-hFuH8TY+Yji7Eja3mGiuAxBqLagejScbG8GbG0j6o9vzn0YL14My+ktnqtZgFTosKymC9/44wP6s7xyuLfnClw==} dev: true - /lodash.camelcase/4.3.0: + /lodash.camelcase@4.3.0: resolution: {integrity: sha512-TwuEnCnxbc3rAvhf/LbG7tJUDzhqXyFnv3dtzLOPgCG/hODL7WFnsbwktkD7yUV0RrreP/l1PALq/YSg6VvjlA==} dev: true - /lodash.flatten/4.4.0: + /lodash.flatten@4.4.0: resolution: {integrity: sha512-C5N2Z3DgnnKr0LOpv/hKCgKdb7ZZwafIrsesve6lmzvZIRZRGaZ/l6Q8+2W7NaT+ZwO3fFlSCzCzrDCFdJfZ4g==} dev: true - /lodash.mapvalues/4.6.0: + /lodash.mapvalues@4.6.0: resolution: {integrity: sha512-JPFqXFeZQ7BfS00H58kClY7SPVeHertPE0lNuCyZ26/XlN8TvakYD7b9bGyNmXbT/D3BbtPAAmq90gPWqLkxlQ==} dev: true - /lodash.merge/4.6.2: + /lodash.merge@4.6.2: resolution: {integrity: sha512-0KpjqXRVvrYyCsX1swR/XTK0va6VQkQM6MNo7PqW77ByjAhoARA8EfrP1N4+KlKj8YS0ZUCtRT/YUuhyYDujIQ==} dev: true - /lodash.truncate/4.4.2: + /lodash.truncate@4.4.2: resolution: {integrity: sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==} dev: true - /lodash/4.17.20: + /lodash@4.17.20: resolution: {integrity: sha512-PlhdFcillOINfeV7Ni6oF1TAEayyZBoZ8bcshTHqOYJYlrqzRK5hagpagky5o4HfCzzd1TRkXPMFq6cKk9rGmA==} dev: true - /lodash/4.17.21: + /lodash@4.17.21: resolution: {integrity: sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg==} dev: true - /log-symbols/3.0.0: + /log-symbols@3.0.0: resolution: {integrity: sha512-dSkNGuI7iG3mfvDzUuYZyvk5dD9ocYCYzNU6CYDE6+Xqd+gwme6Z00NS3dUh8mq/73HaEtT7m6W+yUPtU6BZnQ==} engines: {node: '>=8'} dependencies: chalk: 2.4.2 dev: true - /log-symbols/4.1.0: + /log-symbols@4.1.0: resolution: {integrity: sha512-8XPvpAA8uyhfteu8pIvQxpJZ7SYYdpUivZpGy6sFsBuKRY/7rQGavedeB8aK+Zkyq6upMFVL/9AW6vOYzfRyLg==} engines: {node: '>=10'} dependencies: @@ -7468,108 +7498,108 @@ packages: is-unicode-supported: 0.1.0 dev: true - /looper/2.0.0: + /looper@2.0.0: resolution: {integrity: sha512-6DzMHJcjbQX/UPHc1rRCBfKlLwDkvuGZ715cIR36wSdYqWXFT35uLXq5P/2orl3tz+t+VOVPxw4yPinQlUDGDQ==} dev: true - /looper/3.0.0: + /looper@3.0.0: resolution: {integrity: sha512-LJ9wplN/uSn72oJRsXTx+snxPet5c8XiZmOKCm906NVYu+ag6SB6vUcnJcWxgnl2NfbIyeobAn7Bwv6xRj2XJg==} dev: true - /loose-envify/1.4.0: + /loose-envify@1.4.0: resolution: {integrity: sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==} hasBin: true dependencies: js-tokens: 4.0.0 dev: true - /loupe/2.3.4: + /loupe@2.3.4: resolution: {integrity: sha512-OvKfgCC2Ndby6aSTREl5aCCPTNIzlDfQZvZxNUrBrihDhL3xcrYegTblhmEiCrg2kKQz4XsFIaemE5BF4ybSaQ==} dependencies: get-func-name: 2.0.0 - /lower-case-first/1.0.2: + /lower-case-first@1.0.2: resolution: {integrity: sha512-UuxaYakO7XeONbKrZf5FEgkantPf5DUqDayzP5VXZrtRPdH86s4kN47I8B3TW10S4QKiE3ziHNf3kRN//okHjA==} dependencies: lower-case: 1.1.4 dev: true - /lower-case/1.1.4: + /lower-case@1.1.4: resolution: {integrity: sha512-2Fgx1Ycm599x+WGpIYwJOvsjmXFzTSc34IwDWALRA/8AopUKAVPwfJ+h5+f85BCp0PWmmJcWzEpxOpoXycMpdA==} dev: true - /lowercase-keys/1.0.1: + /lowercase-keys@1.0.1: resolution: {integrity: sha512-G2Lj61tXDnVFFOi8VZds+SoQjtQC3dgokKdDG2mTm1tx4m50NUHBOZSBwQQHyy0V12A0JTG4icfZQH+xPyh8VA==} engines: {node: '>=0.10.0'} dev: true - /lowercase-keys/2.0.0: + /lowercase-keys@2.0.0: resolution: {integrity: sha512-tqNXrS78oMOE73NMxK4EMLQsQowWf8jKooH9g7xPavRT706R6bkQJ6DY2Te7QukaZsulxa30wQ7bk0pm4XiHmA==} engines: {node: '>=8'} dev: true - /lowercase-keys/3.0.0: + /lowercase-keys@3.0.0: resolution: {integrity: sha512-ozCC6gdQ+glXOQsveKD0YsDy8DSQFjDTz4zyzEHNV5+JP5D62LmfDZ6o1cycFx9ouG940M5dE8C8CTewdj2YWQ==} engines: {node: ^12.20.0 || ^14.13.1 || >=16.0.0} dev: true - /lru-cache/3.2.0: + /lru-cache@3.2.0: resolution: {integrity: sha512-91gyOKTc2k66UG6kHiH4h3S2eltcPwE1STVfMYC/NG+nZwf8IIuiamfmpGZjpbbxzSyEJaLC0tNSmhjlQUTJow==} dependencies: pseudomap: 1.0.2 dev: true - /lru-cache/5.1.1: + /lru-cache@5.1.1: resolution: {integrity: sha512-KpNARQA3Iwv+jTA0utUVVbrh+Jlrr1Fv0e56GGzAFOXN7dk/FviaDW8LHmK52DlcH4WP2n6gI8vN1aesBFgo9w==} dependencies: yallist: 3.1.1 dev: true - /lru-cache/6.0.0: + /lru-cache@6.0.0: resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} engines: {node: '>=10'} dependencies: yallist: 4.0.0 dev: true - /lru_map/0.3.3: + /lru_map@0.3.3: resolution: {integrity: sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ==} dev: true - /ltgt/2.1.3: + /ltgt@2.1.3: resolution: {integrity: sha512-5VjHC5GsENtIi5rbJd+feEpDKhfr7j0odoUR2Uh978g+2p93nd5o34cTjQWohXsPsCZeqoDnIqEf88mPCe0Pfw==} dev: true - /ltgt/2.2.1: + /ltgt@2.2.1: resolution: {integrity: sha512-AI2r85+4MquTw9ZYqabu4nMwy9Oftlfa/e/52t9IjtfG+mGBbTNdAoZ3RQKLHR6r0wQnwZnPIEh/Ya6XTWAKNA==} dev: true - /make-error/1.3.6: + /make-error@1.3.6: resolution: {integrity: sha512-s8UhlNe7vPKomQhC1qFelMokr/Sc3AgNbso3n74mVPA5LTZwkB9NlXf4XPamLxJE8h0gh73rM94xvwRT2CVInw==} dev: true - /map-cache/0.2.2: + /map-cache@0.2.2: resolution: {integrity: sha512-8y/eV9QQZCiyn1SprXSrCmqJN0yNRATe+PO8ztwqrvrbdRLA3eYJF0yaR0YayLWkMbsQSKWS9N2gPcGEc4UsZg==} engines: {node: '>=0.10.0'} dev: true - /map-visit/1.0.0: + /map-visit@1.0.0: resolution: {integrity: sha512-4y7uGv8bd2WdM9vpQsiQNo41Ln1NvhvDRuVt0k2JZQ+ezN2uaQes7lZeZ+QQUHOLQAtDaBJ+7wCbi+ab/KFs+w==} engines: {node: '>=0.10.0'} dependencies: object-visit: 1.0.1 dev: true - /markdown-table/1.1.3: + /markdown-table@1.1.3: resolution: {integrity: sha512-1RUZVgQlpJSPWYbFSpmudq5nHY1doEIv89gBtF0s4gW1GF2XorxcA/70M5vq7rLv0a6mhOUccRsqkwhwLCIQ2Q==} dev: true - /mcl-wasm/0.7.9: + /mcl-wasm@0.7.9: resolution: {integrity: sha512-iJIUcQWA88IJB/5L15GnJVnSQJmf/YaxxV6zRavv83HILHaJQb6y0iFyDMdDO0gN8X37tdxmAOrH/P8B6RB8sQ==} engines: {node: '>=8.9.0'} dev: true - /md5.js/1.3.5: + /md5.js@1.3.5: resolution: {integrity: sha512-xitP+WxNPcTTOgnTJcrhM0xvdPepipPSf3I8EIpGKeFLjt3PlJLIDG3u8EX53ZIubkb+5U2+3rELYpEhHhzdkg==} dependencies: hash-base: 3.1.0 @@ -7577,12 +7607,12 @@ packages: safe-buffer: 5.2.1 dev: true - /media-typer/0.3.0: + /media-typer@0.3.0: resolution: {integrity: sha512-dq+qelQ9akHpcOl/gUVRTxVIOkAJ1wR3QAvb4RsVjS8oVoFjDGTc679wJYmUmknUF5HwMLOgb5O+a3KxfWapPQ==} engines: {node: '>= 0.6'} dev: true - /memdown/1.4.1: + /memdown@1.4.1: resolution: {integrity: sha512-iVrGHZB8i4OQfM155xx8akvG9FIj+ht14DX5CQkCTG4EHzZ3d3sgckIf/Lm9ivZalEsFuEVnWv2B2WZvbrro2w==} dependencies: abstract-leveldown: 2.7.2 @@ -7593,7 +7623,7 @@ packages: safe-buffer: 5.1.2 dev: true - /memdown/3.0.0: + /memdown@3.0.0: resolution: {integrity: sha512-tbV02LfZMWLcHcq4tw++NuqMO+FZX8tNJEiD2aNRm48ZZusVg5N8NART+dmBkepJVye986oixErf7jfXboMGMA==} engines: {node: '>=6'} dependencies: @@ -7605,7 +7635,7 @@ packages: safe-buffer: 5.1.2 dev: true - /memory-level/1.0.0: + /memory-level@1.0.0: resolution: {integrity: sha512-UXzwewuWeHBz5krr7EvehKcmLFNoXxGcvuYhC41tRnkrTbJohtS7kVn9akmgirtRygg+f7Yjsfi8Uu5SGSQ4Og==} engines: {node: '>=12'} dependencies: @@ -7614,21 +7644,21 @@ packages: module-error: 1.0.2 dev: true - /memorystream/0.3.1: + /memorystream@0.3.1: resolution: {integrity: sha512-S3UwM3yj5mtUSEfP41UZmt/0SCoVYUcU1rkXv+BQ5Ig8ndL4sPoJNBUJERafdPb5jjHJGuMgytgKvKIf58XNBw==} engines: {node: '>= 0.10.0'} dev: true - /merge-descriptors/1.0.1: + /merge-descriptors@1.0.1: resolution: {integrity: sha512-cCi6g3/Zr1iqQi6ySbseM1Xvooa98N0w31jzUYrXPX2xqObmFGHJ0tQ5u74H3mVh7wLouTseZyYIq39g8cNp1w==} dev: true - /merge2/1.4.1: + /merge2@1.4.1: resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==} engines: {node: '>= 8'} dev: true - /merkle-patricia-tree/2.3.2: + /merkle-patricia-tree@2.3.2: resolution: {integrity: sha512-81PW5m8oz/pz3GvsAwbauj7Y00rqm81Tzad77tHBwU7pIAtN+TJnMSOJhxBKflSVYhptMMb9RskhqHqrSm1V+g==} dependencies: async: 1.5.2 @@ -7641,7 +7671,7 @@ packages: semaphore: 1.1.0 dev: true - /merkle-patricia-tree/3.0.0: + /merkle-patricia-tree@3.0.0: resolution: {integrity: sha512-soRaMuNf/ILmw3KWbybaCjhx86EYeBbD8ph0edQCTed0JN/rxDt1EBN52Ajre3VyGo+91f8+/rfPIRQnnGMqmQ==} dependencies: async: 2.6.3 @@ -7653,12 +7683,12 @@ packages: semaphore: 1.1.0 dev: true - /methods/1.1.2: + /methods@1.1.2: resolution: {integrity: sha512-iclAHeNqNm68zFtnZ0e+1L2yUIdvzNoauKU4WBA3VvH/vPFieF7qfRlwUZU+DA9P9bPXIS90ulxoUoCH23sV2w==} engines: {node: '>= 0.6'} dev: true - /micromatch/3.1.10: + /micromatch@3.1.10: resolution: {integrity: sha512-MWikgl9n9M3w+bpsY3He8L+w9eF9338xRl8IAO5viDizwSzziFEyUzo2xrrloB64ADbTf8uA8vRqqttDTOmccg==} engines: {node: '>=0.10.0'} dependencies: @@ -7679,7 +7709,7 @@ packages: - supports-color dev: true - /micromatch/4.0.5: + /micromatch@4.0.5: resolution: {integrity: sha512-DMy+ERcEW2q8Z2Po+WNXuw3c5YaUSFjAO5GsJqfEl7UjvtIuFKO6ZrKvcItdy98dwFI2N1tg3zNIdKaQT+aNdA==} engines: {node: '>=8.6'} dependencies: @@ -7687,7 +7717,7 @@ packages: picomatch: 2.3.1 dev: true - /miller-rabin/4.0.1: + /miller-rabin@4.0.1: resolution: {integrity: sha512-115fLhvZVqWwHPbClyntxEVfVDfl9DLLTuJvq3g2O/Oxi8AiNouAHvDSzHS0viUJc+V5vm3eq91Xwqn9dp4jRA==} hasBin: true dependencies: @@ -7695,90 +7725,90 @@ packages: brorand: 1.1.0 dev: true - /mime-db/1.44.0: + /mime-db@1.44.0: resolution: {integrity: sha512-/NOTfLrsPBVeH7YtFPgsVWveuL+4SjjYxaQ1xtM1KMFj7HdxlBlxeyNLzhyJVx7r4rZGJAZ/6lkKCitSc/Nmpg==} engines: {node: '>= 0.6'} dev: true - /mime-types/2.1.27: + /mime-types@2.1.27: resolution: {integrity: sha512-JIhqnCasI9yD+SsmkquHBxTSEuZdQX5BuQnS2Vc7puQQQ+8yiP5AY5uWhpdv4YL4VM5c6iliiYWPgJ/nJQLp7w==} engines: {node: '>= 0.6'} dependencies: mime-db: 1.44.0 dev: true - /mime/1.6.0: + /mime@1.6.0: resolution: {integrity: sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==} engines: {node: '>=4'} hasBin: true dev: true - /mimic-response/1.0.1: + /mimic-response@1.0.1: resolution: {integrity: sha512-j5EctnkH7amfV/q5Hgmoal1g2QHFJRraOtmx0JpIqkxhBhI/lJSl1nMpQ45hVarwNETOoWEimndZ4QK0RHxuxQ==} engines: {node: '>=4'} dev: true - /mimic-response/3.1.0: + /mimic-response@3.1.0: resolution: {integrity: sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==} engines: {node: '>=10'} dev: true - /min-document/2.19.0: + /min-document@2.19.0: resolution: {integrity: sha512-9Wy1B3m3f66bPPmU5hdA4DR4PB2OfDU/+GS3yAB7IQozE3tqXaVv2zOjgla7MEGSRv95+ILmOuvhLkOK6wJtCQ==} dependencies: dom-walk: 0.1.1 dev: true - /minimalistic-assert/1.0.1: + /minimalistic-assert@1.0.1: resolution: {integrity: sha512-UtJcAD4yEaGtjPezWuO9wC4nwUnVH/8/Im3yEHQP4b67cXlD/Qr9hdITCU1xDbSEXg2XKNaP8jsReV7vQd00/A==} - /minimalistic-crypto-utils/1.0.1: + /minimalistic-crypto-utils@1.0.1: resolution: {integrity: sha512-JIYlbt6g8i5jKfJ3xz7rF0LXmv2TkDxBLUkiBeZ7bAx4GnnNMr8xFpGnOxn6GhTEHx3SjRrZEoU+j04prX1ktg==} - /minimatch/3.0.4: + /minimatch@3.0.4: resolution: {integrity: sha512-yJHVQEhyqPLUTgt9B83PXu6W3rx4MvvHvSUvToogpwoGDOUQ+yDrR0HRot+yOCdCO7u4hX3pWft6kWBBcqh0UA==} dependencies: brace-expansion: 1.1.11 dev: true - /minimatch/3.1.2: + /minimatch@3.1.2: resolution: {integrity: sha512-J7p63hRiAjw1NDEww1W7i37+ByIrOWO5XQQAzZ3VOcL0PNybwpfmV/N05zFAzwQ9USyEcX6t3UO+K5aqBQOIHw==} dependencies: brace-expansion: 1.1.11 dev: true - /minimatch/5.0.1: + /minimatch@5.0.1: resolution: {integrity: sha512-nLDxIFRyhDblz3qMuq+SoRZED4+miJ/G+tdDrjkkkRnjAsBexeGpgjLEQ0blJy7rHhR2b93rhQY4SvyWu9v03g==} engines: {node: '>=10'} dependencies: brace-expansion: 2.0.1 dev: true - /minimatch/5.1.6: + /minimatch@5.1.6: resolution: {integrity: sha512-lKwV/1brpG6mBUFHtb7NUmtABCb2WZZmm2wNiOA5hAb8VdCS4B3dtMWyvcoViccwAW/COERjXLt0zP1zXUN26g==} engines: {node: '>=10'} dependencies: brace-expansion: 2.0.1 dev: true - /minimist/1.2.6: + /minimist@1.2.6: resolution: {integrity: sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q==} dev: true - /minipass/2.9.0: + /minipass@2.9.0: resolution: {integrity: sha512-wxfUjg9WebH+CUDX/CdbRlh5SmfZiy/hpkxaRI16Y9W56Pa75sWgd/rvFilSgrauD9NyFymP/+JFV3KwzIsJeg==} dependencies: safe-buffer: 5.2.1 yallist: 3.1.1 dev: true - /minizlib/1.3.3: + /minizlib@1.3.3: resolution: {integrity: sha512-6ZYMOEnmVsdCeTJVE0W9ZD+pVnE8h9Hma/iOwwRDsdQoePpoX56/8B6z3P9VNwppJuBKNRuFDRNRqRWexT9G9Q==} dependencies: minipass: 2.9.0 dev: true - /mixin-deep/1.3.2: + /mixin-deep@1.3.2: resolution: {integrity: sha512-WRoDn//mXBiJ1H40rqa3vH0toePwSsGb45iInWlTySa+Uu4k3tYUSxa2v1KqAiLtvlrSzaExqS1gtk96A9zvEA==} engines: {node: '>=0.10.0'} dependencies: @@ -7786,7 +7816,7 @@ packages: is-extendable: 1.0.1 dev: true - /mkdirp-promise/5.0.1: + /mkdirp-promise@5.0.1: resolution: {integrity: sha512-Hepn5kb1lJPtVW84RFT40YG1OddBNTOVUZR2bzQUHc+Z03en8/3uX0+060JDhcEzyO08HmipsN9DcnFMxhIL9w==} engines: {node: '>=4'} deprecated: This package is broken and no longer maintained. 'mkdirp' itself supports promises now, please switch to that. @@ -7794,33 +7824,33 @@ packages: mkdirp: 1.0.4 dev: true - /mkdirp/0.5.5: + /mkdirp@0.5.5: resolution: {integrity: sha512-NKmAlESf6jMGym1++R0Ra7wvhV+wFW63FaSOFPwRahvea0gMUcGUhVeAg/0BC0wiv9ih5NYPB1Wn1UEI1/L+xQ==} hasBin: true dependencies: minimist: 1.2.6 dev: true - /mkdirp/0.5.6: + /mkdirp@0.5.6: resolution: {integrity: sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==} hasBin: true dependencies: minimist: 1.2.6 dev: true - /mkdirp/1.0.4: + /mkdirp@1.0.4: resolution: {integrity: sha512-vVqVZQyf3WLx2Shd0qJ9xuvqgAyKPLAiqITEtqW0oIUjzo3PePDd6fW9iFz30ef7Ysp/oiWqbhszeGWW2T6Gzw==} engines: {node: '>=10'} hasBin: true dev: true - /mnemonist/0.38.5: + /mnemonist@0.38.5: resolution: {integrity: sha512-bZTFT5rrPKtPJxj8KSV0WkPyNxl72vQepqqVUAW2ARUpUSF2qXMB6jZj7hW5/k7C1rtpzqbD/IIbJwLXUjCHeg==} dependencies: obliterator: 2.0.4 dev: true - /mocha/10.2.0: + /mocha@10.2.0: resolution: {integrity: sha512-IDY7fl/BecMwFHzoqF2sg/SHHANeBoMMXFlS9r0OXKDssYE1M5O43wUY/9BVPeIvfH2zmEbBfseqN9gBQZzXkg==} engines: {node: '>= 14.0.0'} hasBin: true @@ -7828,7 +7858,7 @@ packages: ansi-colors: 4.1.1 browser-stdout: 1.3.1 chokidar: 3.5.3 - debug: 4.3.4_supports-color@8.1.1 + debug: 4.3.4(supports-color@8.1.1) diff: 5.0.0 escape-string-regexp: 4.0.0 find-up: 5.0.0 @@ -7848,7 +7878,7 @@ packages: yargs-unparser: 2.0.0 dev: true - /mocha/7.1.2: + /mocha@7.1.2: resolution: {integrity: sha512-o96kdRKMKI3E8U0bjnfqW4QMk12MwZ4mhdBTf+B5a1q9+aq2HRnj+3ZdJu0B/ZhJeK78MgYuv6L8d/rA5AeBJA==} engines: {node: '>= 8.10.0'} hasBin: true @@ -7856,7 +7886,7 @@ packages: ansi-colors: 3.2.3 browser-stdout: 1.3.1 chokidar: 3.3.0 - debug: 3.2.6_supports-color@6.0.0 + debug: 3.2.6(supports-color@6.0.0) diff: 3.5.0 escape-string-regexp: 1.0.5 find-up: 3.0.0 @@ -7879,7 +7909,7 @@ packages: yargs-unparser: 1.6.0 dev: true - /mocha/7.2.0: + /mocha@7.2.0: resolution: {integrity: sha512-O9CIypScywTVpNaRrCAgoUnJgozpIofjKUYmJhiCIJMiuYnLI6otcb1/kpW9/n/tJODHGZ7i8aLQoDVsMtOKQQ==} engines: {node: '>= 8.10.0'} hasBin: true @@ -7887,7 +7917,7 @@ packages: ansi-colors: 3.2.3 browser-stdout: 1.3.1 chokidar: 3.3.0 - debug: 3.2.6_supports-color@6.0.0 + debug: 3.2.6(supports-color@6.0.0) diff: 3.5.0 escape-string-regexp: 1.0.5 find-up: 3.0.0 @@ -7910,36 +7940,36 @@ packages: yargs-unparser: 1.6.0 dev: true - /mock-fs/4.12.0: + /mock-fs@4.12.0: resolution: {integrity: sha512-/P/HtrlvBxY4o/PzXY9cCNBrdylDNxg7gnrv2sMNxj+UJ2m8jSpl0/A6fuJeNAWr99ZvGWH8XCbE0vmnM5KupQ==} dev: true - /module-error/1.0.2: + /module-error@1.0.2: resolution: {integrity: sha512-0yuvsqSCv8LbaOKhnsQ/T5JhyFlCYLPXK3U2sgV10zoKQwzs/MyfuQUOZQ1V/6OCOJsK/TRgNVrPuPDqtdMFtA==} engines: {node: '>=10'} dev: true - /moment/2.29.4: + /moment@2.29.4: resolution: {integrity: sha512-5LC9SOxjSc2HF6vO2CyuTDNivEdoz2IvyJJGj6X8DJ0eFyfszE0QiEd+iXmBvUP3WHxSjFH/vIsA0EN00cgr8w==} dev: true - /ms/2.0.0: + /ms@2.0.0: resolution: {integrity: sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A==} dev: true - /ms/2.1.1: + /ms@2.1.1: resolution: {integrity: sha512-tgp+dl5cGk28utYktBsrFqA7HKgrhgPsg6Z/EfhWI4gl1Hwq8B/GmY/0oXZ6nF8hDVesS/FpnYaD/kOWhYQvyg==} dev: true - /ms/2.1.2: + /ms@2.1.2: resolution: {integrity: sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w==} dev: true - /ms/2.1.3: + /ms@2.1.3: resolution: {integrity: sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==} dev: true - /multibase/0.6.1: + /multibase@0.6.1: resolution: {integrity: sha512-pFfAwyTjbbQgNc3G7D48JkJxWtoJoBMaR4xQUOuB8RnCgRqaYmWNFeJTTvrJ2w51bjLq2zTby6Rqj9TQ9elSUw==} deprecated: This module has been superseded by the multiformats module dependencies: @@ -7947,7 +7977,7 @@ packages: buffer: 5.7.1 dev: true - /multibase/0.7.0: + /multibase@0.7.0: resolution: {integrity: sha512-TW8q03O0f6PNFTQDvh3xxH03c8CjGaaYrjkl9UQPG6rz53TQzzxJVCIWVjzcbN/Q5Y53Zd0IBQBMVktVgNx4Fg==} deprecated: This module has been superseded by the multiformats module dependencies: @@ -7955,14 +7985,14 @@ packages: buffer: 5.7.1 dev: true - /multicodec/0.5.7: + /multicodec@0.5.7: resolution: {integrity: sha512-PscoRxm3f+88fAtELwUnZxGDkduE2HD9Q6GHUOywQLjOGT/HAdhjLDYNZ1e7VR0s0TP0EwZ16LNUTFpoBGivOA==} deprecated: This module has been superseded by the multiformats module dependencies: varint: 5.0.2 dev: true - /multicodec/1.0.4: + /multicodec@1.0.4: resolution: {integrity: sha512-NDd7FeS3QamVtbgfvu5h7fd1IlbaC4EQ0/pgU4zqE2vdHCmBGsUa0TiM8/TdSeG6BMPC92OOCf8F1ocE/Wkrrg==} deprecated: This module has been superseded by the multiformats module dependencies: @@ -7970,7 +8000,7 @@ packages: varint: 5.0.2 dev: true - /multihashes/0.4.21: + /multihashes@0.4.21: resolution: {integrity: sha512-uVSvmeCWf36pU2nB4/1kzYZjsXD9vofZKpgudqkceYY5g2aZZXJ5r9lxuzoRLl1OAp28XljXsEJ/X/85ZsKmKw==} dependencies: buffer: 5.7.1 @@ -7978,29 +8008,29 @@ packages: varint: 5.0.2 dev: true - /nan/2.13.2: + /nan@2.13.2: resolution: {integrity: sha512-TghvYc72wlMGMVMluVo9WRJc0mB8KxxF/gZ4YYFy7V2ZQX9l7rgbPg7vjS9mt6U5HXODVFVI2bOduCzwOMv/lw==} dev: true - /nan/2.16.0: + /nan@2.16.0: resolution: {integrity: sha512-UdAqHyFngu7TfQKsCBgAA6pWDkT8MAO7d0jyOecVhN5354xbLqdn8mV9Tat9gepAupm0bt2DbeaSC8vS52MuFA==} dev: true - /nano-base32/1.0.1: + /nano-base32@1.0.1: resolution: {integrity: sha512-sxEtoTqAPdjWVGv71Q17koMFGsOMSiHsIFEvzOM7cNp8BXB4AnEwmDabm5dorusJf/v1z7QxaZYxUorU9RKaAw==} dev: true - /nano-json-stream-parser/0.1.2: + /nano-json-stream-parser@0.1.2: resolution: {integrity: sha512-9MqxMH/BSJC7dnLsEMPyfN5Dvoo49IsPFYMcHw3Bcfc2kN0lpHRBSzlMSVx4HGyJ7s9B31CyBTVehWJoQ8Ctew==} dev: true - /nanoid/3.3.3: + /nanoid@3.3.3: resolution: {integrity: sha512-p1sjXuopFs0xg+fPASzQ28agW1oHD7xDsd9Xkf3T15H3c/cifrFHVwrh74PdoklAPi+i7MdRsE47vm2r6JoB+w==} engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1} hasBin: true dev: true - /nanomatch/1.2.13: + /nanomatch@1.2.13: resolution: {integrity: sha512-fpoe2T0RbHwBTBUOftAfBPaDEi06ufaUai0mE6Yn1kacc3SnTErfb/h+X94VXzI64rKFHYImXSvdwGGCmwOqCA==} engines: {node: '>=0.10.0'} dependencies: @@ -8019,72 +8049,72 @@ packages: - supports-color dev: true - /napi-macros/2.0.0: + /napi-macros@2.0.0: resolution: {integrity: sha512-A0xLykHtARfueITVDernsAWdtIMbOJgKgcluwENp3AlsKN/PloyO10HtmoqnFAQAcxPkgZN7wdfPfEd0zNGxbg==} dev: true - /natural-compare-lite/1.4.0: + /natural-compare-lite@1.4.0: resolution: {integrity: sha512-Tj+HTDSJJKaZnfiuw+iaF9skdPpTo2GtEly5JHnWV/hfv2Qj/9RKsGISQtLh2ox3l5EAGw487hnBee0sIJ6v2g==} dev: true - /natural-compare/1.4.0: + /natural-compare@1.4.0: resolution: {integrity: sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==} dev: true - /negotiator/0.6.2: + /negotiator@0.6.2: resolution: {integrity: sha512-hZXc7K2e+PgeI1eDBe/10Ard4ekbfrrqG8Ep+8Jmf4JID2bNg7NvCPOZN+kfF574pFQI7mum2AUqDidoKqcTOw==} engines: {node: '>= 0.6'} dev: true - /neo-async/2.6.2: + /neo-async@2.6.2: resolution: {integrity: sha512-Yd3UES5mWCSqR+qNT93S3UoYUkqAZ9lLg8a7g9rimsWmYGK8cVToA4/sF3RrshdyV3sAGMXVUmpMYOw+dLpOuw==} dev: true - /neodoc/2.0.2: + /neodoc@2.0.2: resolution: {integrity: sha512-NAppJ0YecKWdhSXFYCHbo6RutiX8vOt/Jo3l46mUg6pQlpJNaqc5cGxdrW2jITQm5JIYySbFVPDl3RrREXNyPw==} dependencies: ansi-regex: 2.1.1 dev: true - /next-tick/1.1.0: + /next-tick@1.1.0: resolution: {integrity: sha512-CXdUiJembsNjuToQvxayPZF9Vqht7hewsvy2sOWafLvi2awflj9mOC6bHIg50orX8IJvWKY9wYQ/zB2kogPslQ==} dev: true - /nice-try/1.0.5: + /nice-try@1.0.5: resolution: {integrity: sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ==} dev: true - /no-case/2.3.2: + /no-case@2.3.2: resolution: {integrity: sha512-rmTZ9kz+f3rCvK2TD1Ue/oZlns7OGoIWP4fc3llxxRXlOkHKoWPPWJOfFYpITabSow43QJbRIoHQXtt10VldyQ==} dependencies: lower-case: 1.1.4 dev: true - /node-addon-api/2.0.2: + /node-addon-api@2.0.2: resolution: {integrity: sha512-Ntyt4AIXyaLIuMHF6IOoTakB3K+RWxwtsHNRxllEoA6vPwP9o4866g6YWDLUdnucilZhmkxiHwHr11gAENw+QA==} dev: true - /node-emoji/1.11.0: + /node-emoji@1.11.0: resolution: {integrity: sha512-wo2DpQkQp7Sjm2A0cq+sN7EHKO6Sl0ctXeBdFZrL9T9+UywORbufTcTZxom8YqpLQt/FqNMUkOpkZrJVYSKD3A==} dependencies: lodash: 4.17.21 dev: true - /node-environment-flags/1.0.6: + /node-environment-flags@1.0.6: resolution: {integrity: sha512-5Evy2epuL+6TM0lCQGpFIj6KwiEsGh1SrHUhTbNX+sLbBtjidPZFAnVK9y5yU1+h//RitLbRHTIMyxQPtxMdHw==} dependencies: object.getownpropertydescriptors: 2.1.4 semver: 5.7.1 dev: true - /node-fetch/1.7.3: + /node-fetch@1.7.3: resolution: {integrity: sha512-NhZ4CsKx7cYm2vSrBAr2PvFOe6sWDf0UYLRqA6svUYg7+/TSfVAu49jYC4BvQ4Sms9SZgdqGBgroqfDhJdTyKQ==} dependencies: encoding: 0.1.13 is-stream: 1.1.0 dev: true - /node-fetch/2.6.7: + /node-fetch@2.6.7: resolution: {integrity: sha512-ZjMPFEfVx5j+y2yF35Kzx5sF7kDzxuDj6ziH4FFbOp87zKDZNx8yExJIb05OGF4Nlt9IHFIMBkRl41VdvcNdbQ==} engines: {node: 4.x || >=6.0.0} peerDependencies: @@ -8096,36 +8126,36 @@ packages: whatwg-url: 5.0.0 dev: true - /node-gyp-build/4.5.0: + /node-gyp-build@4.5.0: resolution: {integrity: sha512-2iGbaQBV+ITgCz76ZEjmhUKAKVf7xfY1sRl4UiKQspfZMH2h06SyhNsnSVy50cwkFQDGLyif6m/6uFXHkOZ6rg==} hasBin: true dev: true - /node-interval-tree/2.1.2: + /node-interval-tree@2.1.2: resolution: {integrity: sha512-bJ9zMDuNGzVQg1xv0bCPzyEDxHgbrx7/xGj6CDokvizZZmastPsOh0JJLuY8wA5q2SfX1TLNMk7XNV8WxbGxzA==} engines: {node: '>= 14.0.0'} dependencies: shallowequal: 1.1.0 dev: true - /nofilter/1.0.4: + /nofilter@1.0.4: resolution: {integrity: sha512-N8lidFp+fCz+TD51+haYdbDGrcBWwuHX40F5+z0qkUjMJ5Tp+rdSuAkMJ9N9eoolDlEVTf6u5icM+cNKkKW2mA==} engines: {node: '>=8'} dev: true - /nofilter/3.1.0: + /nofilter@3.1.0: resolution: {integrity: sha512-l2NNj07e9afPnhAhvgVrCD/oy2Ai1yfLpuo3EpiO1jFTsB4sFz6oIfAfSZyQzVpkZQ9xS8ZS5g1jCBgq4Hwo0g==} engines: {node: '>=12.19'} dev: true - /nopt/3.0.6: + /nopt@3.0.6: resolution: {integrity: sha512-4GUt3kSEYmk4ITxzB/b9vaIDfUVWN/Ml1Fwl11IlnIG2iaJ9O6WXZ9SrYM9NLI8OCBieN2Y8SWC2oJV0RQ7qYg==} hasBin: true dependencies: abbrev: 1.1.1 dev: true - /normalize-package-data/2.5.0: + /normalize-package-data@2.5.0: resolution: {integrity: sha512-/5CMN3T0R4XTj4DcGaexo+roZSdSFW/0AOOTROrjxzCG1wrWXEsGbRKevjlIL+ZDE4sZlJr5ED4YW0yqmkK+eA==} dependencies: hosted-git-info: 2.8.9 @@ -8134,33 +8164,33 @@ packages: validate-npm-package-license: 3.0.4 dev: true - /normalize-path/3.0.0: + /normalize-path@3.0.0: resolution: {integrity: sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA==} engines: {node: '>=0.10.0'} dev: true - /normalize-url/4.5.1: + /normalize-url@4.5.1: resolution: {integrity: sha512-9UZCFRHQdNrfTpGg8+1INIg93B6zE0aXMVFkw1WFwvO4SlZywU6aLg5Of0Ap/PgcbSw4LNxvMWXMeugwMCX0AA==} engines: {node: '>=8'} dev: true - /normalize-url/6.1.0: + /normalize-url@6.1.0: resolution: {integrity: sha512-DlL+XwOy3NxAQ8xuC0okPgK46iuVNAK01YN7RueYBqqFeGsBjV9XmCAzAdgt+667bCl5kPh9EqKKDwnaPG1I7A==} engines: {node: '>=10'} dev: true - /nth-check/2.1.1: + /nth-check@2.1.1: resolution: {integrity: sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==} dependencies: boolbase: 1.0.0 dev: true - /number-is-nan/1.0.1: + /number-is-nan@1.0.1: resolution: {integrity: sha512-4jbtZXNAsfZbAHiiqjLPBiCl16dES1zI4Hpzzxw61Tk+loF+sBDBKx1ICKKKwIqQ7M0mFn1TmkN7euSncWgHiQ==} engines: {node: '>=0.10.0'} dev: true - /number-to-bn/1.7.0: + /number-to-bn@1.7.0: resolution: {integrity: sha512-wsJ9gfSz1/s4ZsJN01lyonwuxA1tml6X1yBDnfpMglypcBRFZZkus26EdPSlqS5GJfYddVZa22p3VNb3z5m5Ig==} engines: {node: '>=6.5.0', npm: '>=3'} dependencies: @@ -8168,16 +8198,16 @@ packages: strip-hex-prefix: 1.0.0 dev: true - /oauth-sign/0.9.0: + /oauth-sign@0.9.0: resolution: {integrity: sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ==} dev: true - /object-assign/4.1.1: + /object-assign@4.1.1: resolution: {integrity: sha512-rJgTQnkUnH1sFw8yT6VSU3zD3sWmu6sZhIseY8VX+GRu3P6F7Fu+JNDoXfklElbLJSnc3FUQHVe4cU5hj+BcUg==} engines: {node: '>=0.10.0'} dev: true - /object-copy/0.1.0: + /object-copy@0.1.0: resolution: {integrity: sha512-79LYn6VAb63zgtmAteVOWo9Vdj71ZVBy3Pbse+VqxDpEP83XuujMrGqHIwAXJ5I/aM0zU7dIyIAhifVTPrNItQ==} engines: {node: '>=0.10.0'} dependencies: @@ -8186,11 +8216,11 @@ packages: kind-of: 3.2.2 dev: true - /object-inspect/1.12.2: + /object-inspect@1.12.2: resolution: {integrity: sha512-z+cPxW0QGUp0mcqcsgQyLVRDoXFQbXOwBaqyF7VIgI4TWNQsDHrBpUQslRmIfAoYWdYzs6UlKJtB2XJpTaNSpQ==} dev: true - /object-is/1.1.5: + /object-is@1.1.5: resolution: {integrity: sha512-3cyDsyHgtmi7I7DfSSI2LDp6SK2lwvtbg0p0R1e0RvTqF5ceGx+K2dfSjm1bKDMVCFEDAQvy+o8c6a7VujOddw==} engines: {node: '>= 0.4'} dependencies: @@ -8198,23 +8228,23 @@ packages: define-properties: 1.1.4 dev: true - /object-keys/0.4.0: + /object-keys@0.4.0: resolution: {integrity: sha512-ncrLw+X55z7bkl5PnUvHwFK9FcGuFYo9gtjws2XtSzL+aZ8tm830P60WJ0dSmFVaSalWieW5MD7kEdnXda9yJw==} dev: true - /object-keys/1.1.1: + /object-keys@1.1.1: resolution: {integrity: sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==} engines: {node: '>= 0.4'} dev: true - /object-visit/1.0.1: + /object-visit@1.0.1: resolution: {integrity: sha512-GBaMwwAVK9qbQN3Scdo0OyvgPW7l3lnaVMj84uTOZlswkX0KpF6fyDBJhtTthf7pymztoN36/KEr1DyhF96zEA==} engines: {node: '>=0.10.0'} dependencies: isobject: 3.0.1 dev: true - /object.assign/4.1.0: + /object.assign@4.1.0: resolution: {integrity: sha512-exHJeq6kBKj58mqGyTQ9DFvrZC/eR6OwxzoM9YRoGBqrXYonaFyGiFMuc9VZrXf7DarreEwMpurG3dd+CNyW5w==} engines: {node: '>= 0.4'} dependencies: @@ -8224,7 +8254,7 @@ packages: object-keys: 1.1.1 dev: true - /object.assign/4.1.4: + /object.assign@4.1.4: resolution: {integrity: sha512-1mxKf0e58bvyjSCtKYY4sRe9itRk3PJpquJOjeIkz885CczcI4IvJJDLPS72oowuSh+pBxUFROpX+TU++hxhZQ==} engines: {node: '>= 0.4'} dependencies: @@ -8234,7 +8264,7 @@ packages: object-keys: 1.1.1 dev: true - /object.getownpropertydescriptors/2.1.4: + /object.getownpropertydescriptors@2.1.4: resolution: {integrity: sha512-sccv3L/pMModT6dJAYF3fzGMVcb38ysQ0tEE6ixv2yXJDtEIPph268OlAdJj5/qZMZDq2g/jqvwppt36uS/uQQ==} engines: {node: '>= 0.8'} dependencies: @@ -8244,44 +8274,44 @@ packages: es-abstract: 1.20.3 dev: true - /object.pick/1.3.0: + /object.pick@1.3.0: resolution: {integrity: sha512-tqa/UMy/CCoYmj+H5qc07qvSL9dqcs/WZENZ1JbtWBlATP+iVOe778gE6MSijnyCnORzDuX6hU+LA4SZ09YjFQ==} engines: {node: '>=0.10.0'} dependencies: isobject: 3.0.1 dev: true - /obliterator/2.0.4: + /obliterator@2.0.4: resolution: {integrity: sha512-lgHwxlxV1qIg1Eap7LgIeoBWIMFibOjbrYPIPJZcI1mmGAI2m3lNYpK12Y+GBdPQ0U1hRwSord7GIaawz962qQ==} dev: true - /oboe/2.1.4: + /oboe@2.1.4: resolution: {integrity: sha512-ymBJ4xSC6GBXLT9Y7lirj+xbqBLa+jADGJldGEYG7u8sZbS9GyG+u1Xk9c5cbriKwSpCg41qUhPjvU5xOpvIyQ==} dependencies: http-https: 1.0.0 dev: true optional: true - /oboe/2.1.5: + /oboe@2.1.5: resolution: {integrity: sha512-zRFWiF+FoicxEs3jNI/WYUrVEgA7DeET/InK0XQuudGHRg8iIob3cNPrJTKaz4004uaA9Pbe+Dwa8iluhjLZWA==} dependencies: http-https: 1.0.0 dev: true - /on-finished/2.3.0: + /on-finished@2.3.0: resolution: {integrity: sha512-ikqdkGAAyf/X/gPhXGvfgAytDZtDbr+bkNUJ0N9h5MI/dmdgCs3l6hoHrcUv41sRKew3jIwrp4qQDXiK99Utww==} engines: {node: '>= 0.8'} dependencies: ee-first: 1.1.1 dev: true - /once/1.4.0: + /once@1.4.0: resolution: {integrity: sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==} dependencies: wrappy: 1.0.2 dev: true - /open/7.4.2: + /open@7.4.2: resolution: {integrity: sha512-MVHddDVweXZF3awtlAS+6pgKLlm/JgxZ90+/NBurBoQctVOOB/zDdVjcyPzQ+0laDGbsWgrRkflI65sQeOgT9Q==} engines: {node: '>=8'} dependencies: @@ -8289,7 +8319,7 @@ packages: is-wsl: 2.2.0 dev: true - /optionator/0.8.3: + /optionator@0.8.3: resolution: {integrity: sha512-+IW9pACdk3XWmmTXG8m3upGUJst5XRGzxMRjXzAuJ1XnIFNvfhjjIuYkDvysnPQ7qzqVzLt78BCruntqRhWQbA==} engines: {node: '>= 0.8.0'} dependencies: @@ -8301,7 +8331,7 @@ packages: word-wrap: 1.2.3 dev: true - /optionator/0.9.1: + /optionator@0.9.1: resolution: {integrity: sha512-74RlY5FCnhq4jRxVUPKDaRwrVNXMqsGsiW6AJw4XK8hmtm10wC0ypZBLw5IIp85NZMr91+qd1RvvENwg7jjRFw==} engines: {node: '>= 0.8.0'} dependencies: @@ -8313,130 +8343,130 @@ packages: word-wrap: 1.2.3 dev: true - /os-homedir/1.0.2: + /os-homedir@1.0.2: resolution: {integrity: sha512-B5JU3cabzk8c67mRRd3ECmROafjYMXbuzlwtqdM8IbS8ktlTix8aFGb2bAGKrSRIlnfKwovGUUr72JUPyOb6kQ==} engines: {node: '>=0.10.0'} dev: true - /os-locale/1.4.0: + /os-locale@1.4.0: resolution: {integrity: sha512-PRT7ZORmwu2MEFt4/fv3Q+mEfN4zetKxufQrkShY2oGvUms9r8otu5HfdyIFHkYXjO7laNsoVGmM2MANfuTA8g==} engines: {node: '>=0.10.0'} dependencies: lcid: 1.0.0 dev: true - /os-tmpdir/1.0.2: + /os-tmpdir@1.0.2: resolution: {integrity: sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g==} engines: {node: '>=0.10.0'} dev: true - /p-cancelable/0.3.0: + /p-cancelable@0.3.0: resolution: {integrity: sha512-RVbZPLso8+jFeq1MfNvgXtCRED2raz/dKpacfTNxsx6pLEpEomM7gah6VeHSYV3+vo0OAi4MkArtQcWWXuQoyw==} engines: {node: '>=4'} dev: true - /p-cancelable/1.1.0: + /p-cancelable@1.1.0: resolution: {integrity: sha512-s73XxOZ4zpt1edZYZzvhqFa6uvQc1vwUa0K0BdtIZgQMAJj9IbebH+JkgKZc9h+B05PKHLOTl4ajG1BmNrVZlw==} engines: {node: '>=6'} dev: true - /p-cancelable/3.0.0: + /p-cancelable@3.0.0: resolution: {integrity: sha512-mlVgR3PGuzlo0MmTdk4cXqXWlwQDLnONTAg6sm62XkMJEiRxN3GL3SffkYvqwonbkJBcrI7Uvv5Zh9yjvn2iUw==} engines: {node: '>=12.20'} dev: true - /p-finally/1.0.0: + /p-finally@1.0.0: resolution: {integrity: sha512-LICb2p9CB7FS+0eR1oqWnHhp0FljGLZCWBE9aix0Uye9W8LTQPwMTYVGWQWIw9RdQiDg4+epXQODwIYJtSJaow==} engines: {node: '>=4'} dev: true - /p-limit/1.3.0: + /p-limit@1.3.0: resolution: {integrity: sha512-vvcXsLAJ9Dr5rQOPk7toZQZJApBl2K4J6dANSsEuh6QI41JYcsS/qhTGa9ErIUUgK3WNQoJYvylxvjqmiqEA9Q==} engines: {node: '>=4'} dependencies: p-try: 1.0.0 dev: true - /p-limit/2.3.0: + /p-limit@2.3.0: resolution: {integrity: sha512-//88mFWSJx8lxCzwdAABTJL2MyWB12+eIY7MDL2SqLmAkeKU9qxRvWuSyTjm3FUmpBEMuFfckAIqEaVGUDxb6w==} engines: {node: '>=6'} dependencies: p-try: 2.2.0 dev: true - /p-limit/3.1.0: + /p-limit@3.1.0: resolution: {integrity: sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==} engines: {node: '>=10'} dependencies: yocto-queue: 0.1.0 dev: true - /p-locate/2.0.0: + /p-locate@2.0.0: resolution: {integrity: sha512-nQja7m7gSKuewoVRen45CtVfODR3crN3goVQ0DDZ9N3yHxgpkuBhZqsaiotSQRrADUrne346peY7kT3TSACykg==} engines: {node: '>=4'} dependencies: p-limit: 1.3.0 dev: true - /p-locate/3.0.0: + /p-locate@3.0.0: resolution: {integrity: sha512-x+12w/To+4GFfgJhBEpiDcLozRJGegY+Ei7/z0tSLkMmxGZNybVMSfWj9aJn8Z5Fc7dBUNJOOVgPv2H7IwulSQ==} engines: {node: '>=6'} dependencies: p-limit: 2.3.0 dev: true - /p-locate/4.1.0: + /p-locate@4.1.0: resolution: {integrity: sha512-R79ZZ/0wAxKGu3oYMlz8jy/kbhsNrS7SKZ7PxEHBgJ5+F2mtFW2fK2cOtBh1cHYkQsbzFV7I+EoRKe6Yt0oK7A==} engines: {node: '>=8'} dependencies: p-limit: 2.3.0 dev: true - /p-locate/5.0.0: + /p-locate@5.0.0: resolution: {integrity: sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==} engines: {node: '>=10'} dependencies: p-limit: 3.1.0 dev: true - /p-map/4.0.0: + /p-map@4.0.0: resolution: {integrity: sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==} engines: {node: '>=10'} dependencies: aggregate-error: 3.1.0 dev: true - /p-timeout/1.2.1: + /p-timeout@1.2.1: resolution: {integrity: sha512-gb0ryzr+K2qFqFv6qi3khoeqMZF/+ajxQipEF6NteZVnvz9tzdsfAVj3lYtn1gAXvH5lfLwfxEII799gt/mRIA==} engines: {node: '>=4'} dependencies: p-finally: 1.0.0 dev: true - /p-try/1.0.0: + /p-try@1.0.0: resolution: {integrity: sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww==} engines: {node: '>=4'} dev: true - /p-try/2.2.0: + /p-try@2.2.0: resolution: {integrity: sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==} engines: {node: '>=6'} dev: true - /param-case/2.1.1: + /param-case@2.1.1: resolution: {integrity: sha512-eQE845L6ot89sk2N8liD8HAuH4ca6Vvr7VWAWwt7+kvvG5aBcPmmphQ68JsEG2qa9n1TykS2DLeMt363AAH8/w==} dependencies: no-case: 2.3.2 dev: true - /parent-module/1.0.1: + /parent-module@1.0.1: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} dependencies: callsites: 3.1.0 dev: true - /parse-asn1/5.1.5: + /parse-asn1@5.1.5: resolution: {integrity: sha512-jkMYn1dcJqF6d5CpU689bq7w/b5ALS9ROVSpQDPrZsqqesUJii9qutvoT5ltGedNXMO2e16YUWIghG9KxaViTQ==} dependencies: asn1.js: 4.10.1 @@ -8447,22 +8477,22 @@ packages: safe-buffer: 5.2.1 dev: true - /parse-cache-control/1.0.1: + /parse-cache-control@1.0.1: resolution: {integrity: sha512-60zvsJReQPX5/QP0Kzfd/VrpjScIQ7SHBW6bFCYfEP+fp0Eppr1SHhIO5nd1PjZtvclzSzES9D/p5nFJurwfWg==} dev: true - /parse-headers/2.0.3: + /parse-headers@2.0.3: resolution: {integrity: sha512-QhhZ+DCCit2Coi2vmAKbq5RGTRcQUOE2+REgv8vdyu7MnYx2eZztegqtTx99TZ86GTIwqiy3+4nQTWZ2tgmdCA==} dev: true - /parse-json/2.2.0: + /parse-json@2.2.0: resolution: {integrity: sha512-QR/GGaKCkhwk1ePQNYDRKYZ3mwU9ypsKhB0XyFnLQdomyEqk3e8wpW3V5Jp88zbxK4n5ST1nqo+g9juTpownhQ==} engines: {node: '>=0.10.0'} dependencies: error-ex: 1.3.2 dev: true - /parse-json/5.2.0: + /parse-json@5.2.0: resolution: {integrity: sha512-ayCKvm/phCGxOkYRSCM82iDwct8/EonSEgCSxWxD7ve6jHggsFl4fZVQBPRNgQoKiuV/odhFrGzQXZwbifC8Rg==} engines: {node: '>=8'} dependencies: @@ -8472,37 +8502,37 @@ packages: lines-and-columns: 1.2.4 dev: true - /parse5-htmlparser2-tree-adapter/7.0.0: + /parse5-htmlparser2-tree-adapter@7.0.0: resolution: {integrity: sha512-B77tOZrqqfUfnVcOrUvfdLbz4pu4RopLD/4vmu3HUPswwTA8OH0EMW9BlWR2B0RCoiZRAHEUu7IxeP1Pd1UU+g==} dependencies: domhandler: 5.0.3 parse5: 7.1.1 dev: true - /parse5/7.1.1: + /parse5@7.1.1: resolution: {integrity: sha512-kwpuwzB+px5WUg9pyK0IcK/shltJN5/OVhQagxhCQNtT9Y9QRZqNY2e1cmbu/paRh5LMnz/oVTVLBpjFmMZhSg==} dependencies: entities: 4.4.0 dev: true - /parseurl/1.3.3: + /parseurl@1.3.3: resolution: {integrity: sha512-CiyeOxFT/JZyN5m0z9PfXw4SCBJ6Sygz1Dpl0wqjlhDEGGBP1GnsUVEL0p63hoG1fcj3fHynXi9NYO4nWOL+qQ==} engines: {node: '>= 0.8'} dev: true - /pascal-case/2.0.1: + /pascal-case@2.0.1: resolution: {integrity: sha512-qjS4s8rBOJa2Xm0jmxXiyh1+OFf6ekCWOvUaRgAQSktzlTbMotS0nmG9gyYAybCWBcuP4fsBeRCKNwGBnMe2OQ==} dependencies: camel-case: 3.0.0 upper-case-first: 1.1.2 dev: true - /pascalcase/0.1.1: + /pascalcase@0.1.1: resolution: {integrity: sha512-XHXfu/yOQRy9vYOtUDVMN60OEJjW013GoObG1o+xwQTpB9eYJX/BjXMsdW13ZDPruFhYYn0AG22w0xgQMwl3Nw==} engines: {node: '>=0.10.0'} dev: true - /patch-package/6.2.2: + /patch-package@6.2.2: resolution: {integrity: sha512-YqScVYkVcClUY0v8fF0kWOjDYopzIM8e3bj/RU1DPeEF14+dCGm6UeOYm4jvCyxqIEQ5/eJzmbWfDWnUleFNMg==} engines: {npm: '>5'} hasBin: true @@ -8523,7 +8553,7 @@ packages: - supports-color dev: true - /patch-package/6.4.7: + /patch-package@6.4.7: resolution: {integrity: sha512-S0vh/ZEafZ17hbhgqdnpunKDfzHQibQizx9g8yEf5dcVk3KOflOfdufRXQX8CSEkyOQwuM/bNz1GwKvFj54kaQ==} engines: {npm: '>5'} hasBin: true @@ -8543,57 +8573,57 @@ packages: tmp: 0.0.33 dev: true - /path-browserify/1.0.1: + /path-browserify@1.0.1: resolution: {integrity: sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g==} dev: true - /path-case/2.1.1: + /path-case@2.1.1: resolution: {integrity: sha512-Ou0N05MioItesaLr9q8TtHVWmJ6fxWdqKB2RohFmNWVyJ+2zeKIeDNWAN6B/Pe7wpzWChhZX6nONYmOnMeJQ/Q==} dependencies: no-case: 2.3.2 dev: true - /path-exists/2.1.0: + /path-exists@2.1.0: resolution: {integrity: sha512-yTltuKuhtNeFJKa1PiRzfLAU5182q1y4Eb4XCJ3PBqyzEDkAZRzBrKKBct682ls9reBVHf9udYLN5Nd+K1B9BQ==} engines: {node: '>=0.10.0'} dependencies: pinkie-promise: 2.0.1 dev: true - /path-exists/3.0.0: + /path-exists@3.0.0: resolution: {integrity: sha512-bpC7GYwiDYQ4wYLe+FA8lhRjhQCMcQGuSgGGqDkg/QerRWw9CmGRT0iSOVRSZJ29NMLZgIzqaljJ63oaL4NIJQ==} engines: {node: '>=4'} dev: true - /path-exists/4.0.0: + /path-exists@4.0.0: resolution: {integrity: sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==} engines: {node: '>=8'} dev: true - /path-is-absolute/1.0.1: + /path-is-absolute@1.0.1: resolution: {integrity: sha512-AVbw3UJ2e9bq64vSaS9Am0fje1Pa8pbGqTTsmXfaIiMpnr5DlDhfJOuLj9Sf95ZPVDAUerDfEk88MPmPe7UCQg==} engines: {node: '>=0.10.0'} dev: true - /path-key/2.0.1: + /path-key@2.0.1: resolution: {integrity: sha512-fEHGKCSmUSDPv4uoj8AlD+joPlq3peND+HRYyxFz4KPw4z926S/b8rIuFs2FYJg3BwsxJf6A9/3eIdLaYC+9Dw==} engines: {node: '>=4'} dev: true - /path-key/3.1.1: + /path-key@3.1.1: resolution: {integrity: sha512-ojmeN0qd+y0jszEtoY48r0Peq5dwMEkIlCOu6Q5f41lfkswXuKtYrhgoTpLnyIcHm24Uhqx+5Tqm2InSwLhE6Q==} engines: {node: '>=8'} dev: true - /path-parse/1.0.7: + /path-parse@1.0.7: resolution: {integrity: sha512-LDJzPVEEEPR+y48z93A0Ed0yXb8pAByGWo/k5YYdYgpY2/2EsOsksJrq7lOHxryrVOn1ejG6oAp8ahvOIQD8sw==} dev: true - /path-to-regexp/0.1.7: + /path-to-regexp@0.1.7: resolution: {integrity: sha512-5DFkuoqlv1uYQKxy8omFBeJPQcdoE07Kv2sferDCrAq1ohOU+MSDswDIbnx3YAM60qIOnYa53wBhXW0EbMonrQ==} dev: true - /path-type/1.1.0: + /path-type@1.1.0: resolution: {integrity: sha512-S4eENJz1pkiQn9Znv33Q+deTOKmbl+jj1Fl+qiP/vYezj+S8x+J3Uo0ISrx/QoEvIlOaDWJhPaRd1flJ9HXZqg==} engines: {node: '>=0.10.0'} dependencies: @@ -8602,15 +8632,15 @@ packages: pinkie-promise: 2.0.1 dev: true - /path-type/4.0.0: + /path-type@4.0.0: resolution: {integrity: sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw==} engines: {node: '>=8'} dev: true - /pathval/1.1.1: + /pathval@1.1.1: resolution: {integrity: sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ==} - /pbkdf2/3.1.2: + /pbkdf2@3.1.2: resolution: {integrity: sha512-iuh7L6jA7JEGu2WxDwtQP1ddOpaJNC4KlDEFfdQajSGgGPNi4OyDc2R7QnbY2bR9QjBVGwgvTdNJZoE7RaxUMA==} engines: {node: '>=0.12'} dependencies: @@ -8621,85 +8651,85 @@ packages: sha.js: 2.4.11 dev: true - /performance-now/2.1.0: + /performance-now@2.1.0: resolution: {integrity: sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow==} dev: true - /picomatch/2.3.1: + /picomatch@2.3.1: resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} engines: {node: '>=8.6'} dev: true - /pify/2.3.0: + /pify@2.3.0: resolution: {integrity: sha512-udgsAY+fTnvv7kI7aaxbqwWNb0AHiB0qBO89PZKPkoTmGOgdbrHDKD+0B2X4uTfJ/FT1R09r9gTsjUjNJotuog==} engines: {node: '>=0.10.0'} dev: true - /pify/4.0.1: + /pify@4.0.1: resolution: {integrity: sha512-uB80kBFb/tfd68bVleG9T5GGsGPjJrLAUpR5PZIrhBnIaRTQRjqdJSsIKkOP6OAIFbj7GOrcudc5pNjZ+geV2g==} engines: {node: '>=6'} dev: true - /pinkie-promise/2.0.1: + /pinkie-promise@2.0.1: resolution: {integrity: sha512-0Gni6D4UcLTbv9c57DfxDGdr41XfgUjqWZu492f0cIGr16zDU06BWP/RAEvOuo7CQ0CNjHaLlM59YJJFm3NWlw==} engines: {node: '>=0.10.0'} dependencies: pinkie: 2.0.4 dev: true - /pinkie/2.0.4: + /pinkie@2.0.4: resolution: {integrity: sha512-MnUuEycAemtSaeFSjXKW/aroV7akBbY+Sv+RkyqFjgAe73F+MR0TBWKBRDkmfWq/HiFmdavfZ1G7h4SPZXaCSg==} engines: {node: '>=0.10.0'} dev: true - /pluralize/8.0.0: + /pluralize@8.0.0: resolution: {integrity: sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==} engines: {node: '>=4'} dev: true - /posix-character-classes/0.1.1: + /posix-character-classes@0.1.1: resolution: {integrity: sha512-xTgYBc3fuo7Yt7JbiuFxSYGToMoz8fLoE6TC9Wx1P/u+LfeThMOAqmuyECnlBaaJb+u1m9hHiXUEtwW4OzfUJg==} engines: {node: '>=0.10.0'} dev: true - /postinstall-postinstall/2.1.0: + /postinstall-postinstall@2.1.0: resolution: {integrity: sha512-7hQX6ZlZXIoRiWNrbMQaLzUUfH+sSx39u8EJ9HYuDc1kLo9IXKWjM5RSquZN1ad5GnH8CGFM78fsAAQi3OKEEQ==} requiresBuild: true dev: true - /precond/0.2.3: + /precond@0.2.3: resolution: {integrity: sha512-QCYG84SgGyGzqJ/vlMsxeXd/pgL/I94ixdNFyh1PusWmTCyVfPJjZ1K1jvHtsbfnXQs2TSkEP2fR7QiMZAnKFQ==} engines: {node: '>= 0.6'} dev: true - /prelude-ls/1.1.2: + /prelude-ls@1.1.2: resolution: {integrity: sha512-ESF23V4SKG6lVSGZgYNpbsiaAkdab6ZgOxe52p7+Kid3W3u3bxR4Vfd/o21dmN7jSt0IwgZ4v5MUd26FEtXE9w==} engines: {node: '>= 0.8.0'} dev: true - /prelude-ls/1.2.1: + /prelude-ls@1.2.1: resolution: {integrity: sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==} engines: {node: '>= 0.8.0'} dev: true - /prepend-http/1.0.4: + /prepend-http@1.0.4: resolution: {integrity: sha512-PhmXi5XmoyKw1Un4E+opM2KcsJInDvKyuOumcjjw3waw86ZNjHwVUOOWLc4bCzLdcKNaWBH9e99sbWzDQsVaYg==} engines: {node: '>=0.10.0'} dev: true - /prepend-http/2.0.0: + /prepend-http@2.0.0: resolution: {integrity: sha512-ravE6m9Atw9Z/jjttRUZ+clIXogdghyZAuWJ3qEzjT+jI/dL1ifAqhZeC5VHzQp1MSt1+jxKkFNemj/iO7tVUA==} engines: {node: '>=4'} dev: true - /prettier-linter-helpers/1.0.0: + /prettier-linter-helpers@1.0.0: resolution: {integrity: sha512-GbK2cP9nraSSUF9N2XwUwqfzlAFlMNYYl+ShE/V+H8a9uNl/oUqB1w2EL54Jh0OlyRSd8RfWYJ3coVS4TROP2w==} engines: {node: '>=6.0.0'} dependencies: fast-diff: 1.2.0 dev: true - /prettier-plugin-solidity/1.1.3_prettier@2.8.8: + /prettier-plugin-solidity@1.1.3(prettier@2.8.8): resolution: {integrity: sha512-fQ9yucPi2sBbA2U2Xjh6m4isUTJ7S7QLc/XDDsktqqxYfTwdYKJ0EnnywXHwCGAaYbQNK+HIYPL1OemxuMsgeg==} engines: {node: '>=12'} peerDependencies: @@ -8711,27 +8741,27 @@ packages: solidity-comments-extractor: 0.0.7 dev: true - /prettier/2.8.8: + /prettier@2.8.8: resolution: {integrity: sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q==} engines: {node: '>=10.13.0'} hasBin: true dev: true - /private/0.1.8: + /private@0.1.8: resolution: {integrity: sha512-VvivMrbvd2nKkiG38qjULzlc+4Vx4wm/whI9pQD35YrARNnhxeiRktSOhSukRLFNlzg6Br/cJPet5J/u19r/mg==} engines: {node: '>= 0.6'} dev: true - /process-nextick-args/2.0.1: + /process-nextick-args@2.0.1: resolution: {integrity: sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==} dev: true - /process/0.5.2: + /process@0.5.2: resolution: {integrity: sha512-oNpcutj+nYX2FjdEW7PGltWhXulAnFlM0My/k48L90hARCOJtvBbQXc/6itV2jDvU5xAAtonP+r6wmQgCcbAUA==} engines: {node: '>= 0.6.0'} dev: true - /promise-to-callback/1.0.0: + /promise-to-callback@1.0.0: resolution: {integrity: sha512-uhMIZmKM5ZteDMfLgJnoSq9GCwsNKrYau73Awf1jIy6/eUcuuZ3P+CD9zUv0kJsIUbU+x6uLNIhXhLHDs1pNPA==} engines: {node: '>=0.10.0'} dependencies: @@ -8739,13 +8769,13 @@ packages: set-immediate-shim: 1.0.1 dev: true - /promise/8.3.0: + /promise@8.3.0: resolution: {integrity: sha512-rZPNPKTOYVNEEKFaq1HqTgOwZD+4/YHS5ukLzQCypkj+OkYx7iv0mA91lJlpPPZ8vMau3IIGj5Qlwrx+8iiSmg==} dependencies: asap: 2.0.6 dev: true - /proper-lockfile/4.1.2: + /proper-lockfile@4.1.2: resolution: {integrity: sha512-TjNPblN4BwAWMXU8s9AEz4JmQxnD1NNL7bNOY/AKUzyamc379FWASUhc/K1pL2noVb+XmZKLL68cjzLsiOAMaA==} dependencies: graceful-fs: 4.2.10 @@ -8753,7 +8783,7 @@ packages: signal-exit: 3.0.7 dev: true - /proxy-addr/2.0.5: + /proxy-addr@2.0.5: resolution: {integrity: sha512-t/7RxHXPH6cJtP0pRG6smSr9QJidhB+3kXu0KgXnbGYMgzEnUxRQ4/LDdfOwZEMyIh3/xHb8PX3t+lfL9z+YVQ==} engines: {node: '>= 0.10'} dependencies: @@ -8761,19 +8791,19 @@ packages: ipaddr.js: 1.9.0 dev: true - /prr/1.0.1: + /prr@1.0.1: resolution: {integrity: sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw==} dev: true - /pseudomap/1.0.2: + /pseudomap@1.0.2: resolution: {integrity: sha512-b/YwNhb8lk1Zz2+bXXpS/LK9OisiZZ1SNsSLxN1x2OXVEhW2Ckr/7mWE5vrC1ZTiJlD9g19jWszTmJsB+oEpFQ==} dev: true - /psl/1.9.0: + /psl@1.9.0: resolution: {integrity: sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag==} dev: true - /public-encrypt/4.0.3: + /public-encrypt@4.0.3: resolution: {integrity: sha512-zVpa8oKZSz5bTMTFClc1fQOnyyEzpl5ozpi1B5YcvBrdohMjH2rfsBtyXcuNuwjsDIXmBYlF2N5FlJYhR29t8Q==} dependencies: bn.js: 4.12.0 @@ -8784,15 +8814,15 @@ packages: safe-buffer: 5.2.1 dev: true - /pull-cat/1.1.11: + /pull-cat@1.1.11: resolution: {integrity: sha512-i3w+xZ3DCtTVz8S62hBOuNLRHqVDsHMNZmgrZsjPnsxXUgbWtXEee84lo1XswE7W2a3WHyqsNuDJTjVLAQR8xg==} dev: true - /pull-defer/0.2.3: + /pull-defer@0.2.3: resolution: {integrity: sha512-/An3KE7mVjZCqNhZsr22k1Tx8MACnUnHZZNPSJ0S62td8JtYr/AiRG42Vz7Syu31SoTLUzVIe61jtT/pNdjVYA==} dev: true - /pull-level/2.0.4: + /pull-level@2.0.4: resolution: {integrity: sha512-fW6pljDeUThpq5KXwKbRG3X7Ogk3vc75d5OQU/TvXXui65ykm+Bn+fiktg+MOx2jJ85cd+sheufPL+rw9QSVZg==} dependencies: level-post: 1.0.7 @@ -8804,70 +8834,70 @@ packages: stream-to-pull-stream: 1.7.3 dev: true - /pull-live/1.0.1: + /pull-live@1.0.1: resolution: {integrity: sha512-tkNz1QT5gId8aPhV5+dmwoIiA1nmfDOzJDlOOUpU5DNusj6neNd3EePybJ5+sITr2FwyCs/FVpx74YMCfc8YeA==} dependencies: pull-cat: 1.1.11 pull-stream: 3.6.14 dev: true - /pull-pushable/2.2.0: + /pull-pushable@2.2.0: resolution: {integrity: sha512-M7dp95enQ2kaHvfCt2+DJfyzgCSpWVR2h2kWYnVsW6ZpxQBx5wOu0QWOvQPVoPnBLUZYitYP2y7HyHkLQNeGXg==} dev: true - /pull-stream/3.6.14: + /pull-stream@3.6.14: resolution: {integrity: sha512-KIqdvpqHHaTUA2mCYcLG1ibEbu/LCKoJZsBWyv9lSYtPkJPBq8m3Hxa103xHi6D2thj5YXa0TqK3L3GUkwgnew==} dev: true - /pull-window/2.1.4: + /pull-window@2.1.4: resolution: {integrity: sha512-cbDzN76BMlcGG46OImrgpkMf/VkCnupj8JhsrpBw3aWBM9ye345aYnqitmZCgauBkc0HbbRRn9hCnsa3k2FNUg==} dependencies: looper: 2.0.0 dev: true - /pump/3.0.0: + /pump@3.0.0: resolution: {integrity: sha512-LwZy+p3SFs1Pytd/jYct4wpv49HiYCqd9Rlc5ZVdk0V+8Yzv6jR5Blk3TRmPL1ft69TxP0IMZGJ+WPFU2BFhww==} dependencies: end-of-stream: 1.4.4 once: 1.4.0 dev: true - /punycode/1.3.2: + /punycode@1.3.2: resolution: {integrity: sha512-RofWgt/7fL5wP1Y7fxE7/EmTLzQVnB0ycyibJ0OOHIlJqTNzglYFxVwETOcIoJqJmpDXJ9xImDv+Fq34F/d4Dw==} dev: true - /punycode/2.1.0: + /punycode@2.1.0: resolution: {integrity: sha512-Yxz2kRwT90aPiWEMHVYnEf4+rhwF1tBmmZ4KepCP+Wkium9JxtWnUm1nqGwpiAHr/tnTSeHqr3wb++jgSkXjhA==} engines: {node: '>=6'} dev: true - /punycode/2.1.1: + /punycode@2.1.1: resolution: {integrity: sha512-XRsRjdf+j5ml+y/6GKHPZbrF/8p2Yga0JPtdqTIY2Xe5ohJPD9saDJJLPvp9+NSBprVvevdXZybnj2cv8OEd0A==} engines: {node: '>=6'} dev: true - /pure-rand/5.0.3: + /pure-rand@5.0.3: resolution: {integrity: sha512-9N8x1h8dptBQpHyC7aZMS+iNOAm97WMGY0AFrguU1cpfW3I5jINkWe5BIY5md0ofy+1TCIELsVcm/GJXZSaPbw==} dev: true - /qs/6.11.0: + /qs@6.11.0: resolution: {integrity: sha512-MvjoMCJwEarSbUYk5O+nmoSzSutSsTwF85zcHPQ9OrlFoZOYIjaqBAJIqIXjptyD5vThxGq52Xu/MaJzRkIk4Q==} engines: {node: '>=0.6'} dependencies: side-channel: 1.0.4 dev: true - /qs/6.5.3: + /qs@6.5.3: resolution: {integrity: sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA==} engines: {node: '>=0.6'} dev: true - /qs/6.7.0: + /qs@6.7.0: resolution: {integrity: sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==} engines: {node: '>=0.6'} dev: true - /query-string/5.1.1: + /query-string@5.1.1: resolution: {integrity: sha512-gjWOsm2SoGlgLEdAGt7a6slVOk9mGiXmPFMqrEhLQ68rhQuBnpfs3+EmlvqKyxnCo9/PPlF+9MtY02S1aFg+Jw==} engines: {node: '>=0.10.0'} dependencies: @@ -8876,40 +8906,40 @@ packages: strict-uri-encode: 1.1.0 dev: true - /querystring/0.2.0: + /querystring@0.2.0: resolution: {integrity: sha512-X/xY82scca2tau62i9mDyU9K+I+djTMUsvwf7xnUX5GLvVzgJybOJf4Y6o9Zx3oJK/LSXg5tTZBjwzqVPaPO2g==} engines: {node: '>=0.4.x'} deprecated: The querystring API is considered Legacy. new code should use the URLSearchParams API instead. dev: true - /queue-microtask/1.2.3: + /queue-microtask@1.2.3: resolution: {integrity: sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==} dev: true - /quick-lru/5.1.1: + /quick-lru@5.1.1: resolution: {integrity: sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA==} engines: {node: '>=10'} dev: true - /randombytes/2.1.0: + /randombytes@2.1.0: resolution: {integrity: sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ==} dependencies: safe-buffer: 5.2.1 dev: true - /randomfill/1.0.4: + /randomfill@1.0.4: resolution: {integrity: sha512-87lcbR8+MhcWcUiQ+9e+Rwx8MyR2P7qnt15ynUlbm3TU/fjbgz4GsvfSUDTemtCCtVCqb4ZcEFlyPNTh9bBTLw==} dependencies: randombytes: 2.1.0 safe-buffer: 5.2.1 dev: true - /range-parser/1.2.1: + /range-parser@1.2.1: resolution: {integrity: sha512-Hrgsx+orqoygnmhFbKaHE6c296J+HTAQXoxEF6gNupROmmGJRoyzfG3ccAveqCBrwr/2yxQ5BVd/GTl5agOwSg==} engines: {node: '>= 0.6'} dev: true - /raw-body/2.4.0: + /raw-body@2.4.0: resolution: {integrity: sha512-4Oz8DUIwdvoa5qMJelxipzi/iJIi40O5cGV1wNYp5hvZP8ZN0T+jiNkL0QepXs+EsQ9XJ8ipEDoiH70ySUJP3Q==} engines: {node: '>= 0.8'} dependencies: @@ -8919,7 +8949,7 @@ packages: unpipe: 1.0.0 dev: true - /raw-body/2.5.1: + /raw-body@2.5.1: resolution: {integrity: sha512-qqJBtEyVgS0ZmPGdCFPWJ3FreoqvG4MVQln/kCgF7Olq95IbOp0/BWyMwbdtn4VTvkM8Y7khCQ2Xgk/tcrCXig==} engines: {node: '>= 0.8'} dependencies: @@ -8929,7 +8959,7 @@ packages: unpipe: 1.0.0 dev: true - /read-pkg-up/1.0.1: + /read-pkg-up@1.0.1: resolution: {integrity: sha512-WD9MTlNtI55IwYUS27iHh9tK3YoIVhxis8yKhLpTqWtml739uXc9NWTpxoHkfZf3+DkCCsXox94/VWZniuZm6A==} engines: {node: '>=0.10.0'} dependencies: @@ -8937,7 +8967,7 @@ packages: read-pkg: 1.1.0 dev: true - /read-pkg/1.1.0: + /read-pkg@1.1.0: resolution: {integrity: sha512-7BGwRHqt4s/uVbuyoeejRn4YmFnYZiFl4AuaeXHlgZf3sONF0SOGlxs2Pw8g6hCKupo08RafIO5YXFNOKTfwsQ==} engines: {node: '>=0.10.0'} dependencies: @@ -8946,7 +8976,7 @@ packages: path-type: 1.1.0 dev: true - /readable-stream/1.0.34: + /readable-stream@1.0.34: resolution: {integrity: sha512-ok1qVCJuRkNmvebYikljxJA/UEsKwLl2nI1OmaqAu4/UE+h0wKCHok4XkL/gvi39OacXvw59RJUOFUkDib2rHg==} dependencies: core-util-is: 1.0.3 @@ -8955,7 +8985,7 @@ packages: string_decoder: 0.10.31 dev: true - /readable-stream/2.3.7: + /readable-stream@2.3.7: resolution: {integrity: sha512-Ebho8K4jIbHAxnuxi7o42OrZgF/ZTNcsZj6nRKyUmkhLFq8CHItp/fy6hQZuZmP/n3yZ9VBUbp4zz/mX8hmYPw==} dependencies: core-util-is: 1.0.3 @@ -8967,7 +8997,7 @@ packages: util-deprecate: 1.0.2 dev: true - /readable-stream/3.6.0: + /readable-stream@3.6.0: resolution: {integrity: sha512-BViHy7LKeTz4oNnkcLJ+lVSL6vpiFeX6/d3oSH8zCW7UxP2onchk+vTGB143xuFjHS3deTgkKoXXymXqymiIdA==} engines: {node: '>= 6'} dependencies: @@ -8976,52 +9006,52 @@ packages: util-deprecate: 1.0.2 dev: true - /readdirp/3.2.0: + /readdirp@3.2.0: resolution: {integrity: sha512-crk4Qu3pmXwgxdSgGhgA/eXiJAPQiX4GMOZZMXnqKxHX7TaoL+3gQVo/WeuAiogr07DpnfjIMpXXa+PAIvwPGQ==} engines: {node: '>= 8'} dependencies: picomatch: 2.3.1 dev: true - /readdirp/3.6.0: + /readdirp@3.6.0: resolution: {integrity: sha512-hOS089on8RduqdbhvQ5Z37A0ESjsqz6qnRcffsMU3495FuTdqSm+7bhJ29JvIOsBDEEnan5DPu9t3To9VRlMzA==} engines: {node: '>=8.10.0'} dependencies: picomatch: 2.3.1 dev: true - /rechoir/0.6.2: + /rechoir@0.6.2: resolution: {integrity: sha512-HFM8rkZ+i3zrV+4LQjwQ0W+ez98pApMGM3HUrN04j3CqzPOzl9nmP15Y8YXNm8QHGv/eacOVEjqhmWpkRV0NAw==} engines: {node: '>= 0.10'} dependencies: resolve: 1.22.1 dev: true - /recursive-readdir/2.2.2: + /recursive-readdir@2.2.2: resolution: {integrity: sha512-nRCcW9Sj7NuZwa2XvH9co8NPeXUBhZP7CRKJtU+cS6PW9FpCIFoI5ib0NT1ZrbNuPoRy0ylyCaUL8Gih4LSyFg==} engines: {node: '>=0.10.0'} dependencies: minimatch: 3.0.4 dev: true - /reduce-flatten/2.0.0: + /reduce-flatten@2.0.0: resolution: {integrity: sha512-EJ4UNY/U1t2P/2k6oqotuX2Cc3T6nxJwsM0N0asT7dhrtH1ltUxDn4NalSYmPE2rCkVpcf/X6R0wDwcFpzhd4w==} engines: {node: '>=6'} dev: true - /regenerate/1.4.2: + /regenerate@1.4.2: resolution: {integrity: sha512-zrceR/XhGYU/d/opr2EKO7aRHUeiBI8qjtfHqADTwZd6Szfy16la6kqD0MIUs5z5hx6AaKa+PixpPrR289+I0A==} dev: true - /regenerator-runtime/0.11.1: + /regenerator-runtime@0.11.1: resolution: {integrity: sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg==} dev: true - /regenerator-runtime/0.13.9: + /regenerator-runtime@0.13.9: resolution: {integrity: sha512-p3VT+cOEgxFsRRA9X4lkI1E+k2/CtnKtU4gcxyaCUreilL/vqI6CdZ3wxVUx3UOUg+gnUOQQcRI7BmSI656MYA==} dev: true - /regenerator-transform/0.10.1: + /regenerator-transform@0.10.1: resolution: {integrity: sha512-PJepbvDbuK1xgIgnau7Y90cwaAmO/LCLMI2mPvaXq2heGMR3aWW5/BQvYrhJ8jgmQjXewXvBjzfqKcVOmhjZ6Q==} dependencies: babel-runtime: 6.26.0 @@ -9029,7 +9059,7 @@ packages: private: 0.1.8 dev: true - /regex-not/1.0.2: + /regex-not@1.0.2: resolution: {integrity: sha512-J6SDjUgDxQj5NusnOtdFxDwN/+HWykR8GELwctJ7mdqhcyy1xEc4SRFHUXvxTp661YaVKAjfRLZ9cCqS6tn32A==} engines: {node: '>=0.10.0'} dependencies: @@ -9037,7 +9067,7 @@ packages: safe-regex: 1.1.0 dev: true - /regexp.prototype.flags/1.4.3: + /regexp.prototype.flags@1.4.3: resolution: {integrity: sha512-fjggEOO3slI6Wvgjwflkc4NFRCTZAu5CnNfBd5qOMYhWdn67nJBBu34/TkD++eeFmd8C9r9jfXJ27+nSiRkSUA==} engines: {node: '>= 0.4'} dependencies: @@ -9046,7 +9076,7 @@ packages: functions-have-names: 1.2.3 dev: true - /regexpu-core/2.0.0: + /regexpu-core@2.0.0: resolution: {integrity: sha512-tJ9+S4oKjxY8IZ9jmjnp/mtytu1u3iyIQAfmI51IKWH6bFf7XR1ybtaO6j7INhZKXOTYADk7V5qxaqLkmNxiZQ==} dependencies: regenerate: 1.4.2 @@ -9054,49 +9084,49 @@ packages: regjsparser: 0.1.5 dev: true - /regjsgen/0.2.0: + /regjsgen@0.2.0: resolution: {integrity: sha512-x+Y3yA24uF68m5GA+tBjbGYo64xXVJpbToBaWCoSNSc1hdk6dfctaRWrNFTVJZIIhL5GxW8zwjoixbnifnK59g==} dev: true - /regjsparser/0.1.5: + /regjsparser@0.1.5: resolution: {integrity: sha512-jlQ9gYLfk2p3V5Ag5fYhA7fv7OHzd1KUH0PRP46xc3TgwjwgROIW572AfYg/X9kaNq/LJnu6oJcFRXlIrGoTRw==} hasBin: true dependencies: jsesc: 0.5.0 dev: true - /repeat-element/1.1.4: + /repeat-element@1.1.4: resolution: {integrity: sha512-LFiNfRcSu7KK3evMyYOuCzv3L10TW7yC1G2/+StMjK8Y6Vqd2MG7r/Qjw4ghtuCOjFvlnms/iMmLqpvW/ES/WQ==} engines: {node: '>=0.10.0'} dev: true - /repeat-string/1.6.1: + /repeat-string@1.6.1: resolution: {integrity: sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==} engines: {node: '>=0.10'} dev: true - /repeating/2.0.1: + /repeating@2.0.1: resolution: {integrity: sha512-ZqtSMuVybkISo2OWvqvm7iHSWngvdaW3IpsT9/uP8v4gMi591LY6h35wdOfvQdWCKFWZWm2Y1Opp4kV7vQKT6A==} engines: {node: '>=0.10.0'} dependencies: is-finite: 1.1.0 dev: true - /req-cwd/2.0.0: + /req-cwd@2.0.0: resolution: {integrity: sha512-ueoIoLo1OfB6b05COxAA9UpeoscNpYyM+BqYlA7H6LVF4hKGPXQQSSaD2YmvDVJMkk4UDpAHIeU1zG53IqjvlQ==} engines: {node: '>=4'} dependencies: req-from: 2.0.0 dev: true - /req-from/2.0.0: + /req-from@2.0.0: resolution: {integrity: sha512-LzTfEVDVQHBRfjOUMgNBA+V6DWsSnoeKzf42J7l0xa/B4jyPOuuF5MlNSmomLNGemWTnV2TIdjSSLnEn95fOQA==} engines: {node: '>=4'} dependencies: resolve-from: 3.0.0 dev: true - /request-promise-core/1.1.4_request@2.88.2: + /request-promise-core@1.1.4(request@2.88.2): resolution: {integrity: sha512-TTbAfBBRdWD7aNNOoVOBH4pN/KigV6LyapYNNlAPA8JwbovRti1E88m3sYAwsLi5ryhPKsE9APwnjFTgdUjTpw==} engines: {node: '>=0.10.0'} peerDependencies: @@ -9106,7 +9136,7 @@ packages: request: 2.88.2 dev: true - /request-promise-native/1.0.9_request@2.88.2: + /request-promise-native@1.0.9(request@2.88.2): resolution: {integrity: sha512-wcW+sIUiWnKgNY0dqCpOZkUbF/I+YPi+f09JZIDa39Ec+q82CpSYniDp+ISgTTbKmnpJWASeJBPZmoxH84wt3g==} engines: {node: '>=0.12.0'} deprecated: request-promise-native has been deprecated because it extends the now deprecated request package, see https://github.com/request/request/issues/3142 @@ -9114,12 +9144,12 @@ packages: request: ^2.34 dependencies: request: 2.88.2 - request-promise-core: 1.1.4_request@2.88.2 + request-promise-core: 1.1.4(request@2.88.2) stealthy-require: 1.1.1 tough-cookie: 2.5.0 dev: true - /request/2.88.2: + /request@2.88.2: resolution: {integrity: sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw==} engines: {node: '>= 6'} deprecated: request has been deprecated, see https://github.com/request/request/issues/3142 @@ -9146,59 +9176,59 @@ packages: uuid: 3.4.0 dev: true - /require-directory/2.1.1: + /require-directory@2.1.1: resolution: {integrity: sha512-fGxEI7+wsG9xrvdjsrlmL22OMTTiHRwAMroiEeMgq8gzoLC/PQr7RsRDSTLUg/bZAZtF+TVIkHc6/4RIKrui+Q==} engines: {node: '>=0.10.0'} dev: true - /require-from-string/1.2.1: + /require-from-string@1.2.1: resolution: {integrity: sha512-H7AkJWMobeskkttHyhTVtS0fxpFLjxhbfMa6Bk3wimP7sdPRGL3EyCg3sAQenFfAe+xQ+oAc85Nmtvq0ROM83Q==} engines: {node: '>=0.10.0'} dev: true - /require-from-string/2.0.2: + /require-from-string@2.0.2: resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==} engines: {node: '>=0.10.0'} dev: true - /require-main-filename/1.0.1: + /require-main-filename@1.0.1: resolution: {integrity: sha512-IqSUtOVP4ksd1C/ej5zeEh/BIP2ajqpn8c5x+q99gvcIG/Qf0cud5raVnE/Dwd0ua9TXYDoDc0RE5hBSdz22Ug==} dev: true - /require-main-filename/2.0.0: + /require-main-filename@2.0.0: resolution: {integrity: sha512-NKN5kMDylKuldxYLSUfrbo5Tuzh4hd+2E8NPPX02mZtn1VuREQToYe/ZdlJy+J3uCpfaiGF05e7B8W0iXbQHmg==} dev: true - /resolve-alpn/1.2.1: + /resolve-alpn@1.2.1: resolution: {integrity: sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g==} dev: true - /resolve-from/3.0.0: + /resolve-from@3.0.0: resolution: {integrity: sha512-GnlH6vxLymXJNMBo7XP1fJIzBFbdYt49CuTwmB/6N53t+kMPRMFKz783LlQ4tv28XoQfMWinAJX6WCGf2IlaIw==} engines: {node: '>=4'} dev: true - /resolve-from/4.0.0: + /resolve-from@4.0.0: resolution: {integrity: sha512-pb/MYmXstAkysRFx8piNI1tGFNQIFA3vkE3Gq4EuA1dF6gHp/+vgZqsCGJapvy8N3Q+4o7FwvquPJcnZ7RYy4g==} engines: {node: '>=4'} dev: true - /resolve-url/0.2.1: + /resolve-url@0.2.1: resolution: {integrity: sha512-ZuF55hVUQaaczgOIwqWzkEcEidmlD/xl44x1UZnhOXcYuFN2S6+rcxpG+C1N3So0wvNI3DmJICUFfu2SxhBmvg==} deprecated: https://github.com/lydell/resolve-url#deprecated dev: true - /resolve/1.1.7: + /resolve@1.1.7: resolution: {integrity: sha512-9znBF0vBcaSN3W2j7wKvdERPwqTxSpCq+if5C0WoTCyV9n24rua28jeuQ2pL/HOf+yUe/Mef+H/5p60K0Id3bg==} dev: true - /resolve/1.17.0: + /resolve@1.17.0: resolution: {integrity: sha512-ic+7JYiV8Vi2yzQGFWOkiZD5Z9z7O2Zhm9XMaTxdJExKasieFCr+yXZ/WmXsckHiKl12ar0y6XiXDx3m4RHn1w==} dependencies: path-parse: 1.0.7 dev: true - /resolve/1.22.1: + /resolve@1.22.1: resolution: {integrity: sha512-nBpuuYuY5jFsli/JIs1oldw6fOQCBioohqWZg/2hiaOybXOft4lonv85uDOKXdf8rhyK159cxU5cDcK/NKk8zw==} hasBin: true dependencies: @@ -9207,102 +9237,102 @@ packages: supports-preserve-symlinks-flag: 1.0.0 dev: true - /responselike/1.0.2: + /responselike@1.0.2: resolution: {integrity: sha512-/Fpe5guzJk1gPqdJLJR5u7eG/gNY4nImjbRDaVWVMRhne55TCmj2i9Q+54PBRfatRC8v/rIiv9BN0pMd9OV5EQ==} dependencies: lowercase-keys: 1.0.1 dev: true - /responselike/2.0.1: + /responselike@2.0.1: resolution: {integrity: sha512-4gl03wn3hj1HP3yzgdI7d3lCkF95F21Pz4BPGvKHinyQzALR5CapwC8yIi0Rh58DEMQ/SguC03wFj2k0M/mHhw==} dependencies: lowercase-keys: 2.0.0 dev: true - /resumer/0.0.0: + /resumer@0.0.0: resolution: {integrity: sha512-Fn9X8rX8yYF4m81rZCK/5VmrmsSbqS/i3rDLl6ZZHAXgC2nTAx3dhwG8q8odP/RmdLa2YrybDJaAMg+X1ajY3w==} dependencies: through: 2.3.8 dev: true - /ret/0.1.15: + /ret@0.1.15: resolution: {integrity: sha512-TTlYpa+OL+vMMNG24xSlQGEJ3B/RzEfUlLct7b5G/ytav+wPrplCpVMFuwzXbkecJrb6IYo1iFb0S9v37754mg==} engines: {node: '>=0.12'} dev: true - /retry/0.12.0: + /retry@0.12.0: resolution: {integrity: sha512-9LkiTwjUh6rT555DtE9rTX+BKByPfrMzEAtnlEtdEwr3Nkffwiihqe2bWADg+OQRjt9gl6ICdmB/ZFDCGAtSow==} engines: {node: '>= 4'} dev: true - /reusify/1.0.4: + /reusify@1.0.4: resolution: {integrity: sha512-U9nH88a3fc/ekCF1l0/UP1IosiuIjyTh7hBvXVMHYgVcfGvt897Xguj2UOLDeI5BG2m7/uwyaLVT6fbtCwTyzw==} engines: {iojs: '>=1.0.0', node: '>=0.10.0'} dev: true - /rimraf/2.7.1: + /rimraf@2.7.1: resolution: {integrity: sha512-uWjbaKIK3T1OSVptzX7Nl6PvQ3qAGtKEtVRjRuazjfL3Bx5eI409VZSqgND+4UNnmzLVdPj9FqFJNPqBZFve4w==} hasBin: true dependencies: glob: 7.2.3 dev: true - /rimraf/3.0.2: + /rimraf@3.0.2: resolution: {integrity: sha512-JZkJMZkAGFFPP2YqXZXPbMlMBgsxzE8ILs4lMIX/2o0L9UBw9O/Y3o6wFw/i9YLapcUJWwqbi3kdxIPdC62TIA==} hasBin: true dependencies: glob: 7.2.3 dev: true - /ripemd160-min/0.0.6: + /ripemd160-min@0.0.6: resolution: {integrity: sha512-+GcJgQivhs6S9qvLogusiTcS9kQUfgR75whKuy5jIhuiOfQuJ8fjqxV6EGD5duH1Y/FawFUMtMhyeq3Fbnib8A==} engines: {node: '>=8'} dev: true - /ripemd160/2.0.2: + /ripemd160@2.0.2: resolution: {integrity: sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==} dependencies: hash-base: 3.1.0 inherits: 2.0.4 dev: true - /rlp/2.2.7: + /rlp@2.2.7: resolution: {integrity: sha512-d5gdPmgQ0Z+AklL2NVXr/IoSjNZFfTVvQWzL/AM2AOcSzYP2xjlb0AC8YyCLc41MSNf6P6QVtjgPdmVtzb+4lQ==} hasBin: true dependencies: bn.js: 5.2.1 dev: true - /run-parallel-limit/1.1.0: + /run-parallel-limit@1.1.0: resolution: {integrity: sha512-jJA7irRNM91jaKc3Hcl1npHsFLOXOoTkPCUL1JEa1R82O2miplXXRaGdjW/KM/98YQWDhJLiSs793CnXfblJUw==} dependencies: queue-microtask: 1.2.3 dev: true - /run-parallel/1.1.9: + /run-parallel@1.1.9: resolution: {integrity: sha512-DEqnSRTDw/Tc3FXf49zedI638Z9onwUotBMiUFKmrO2sdFKIbXamXGQ3Axd4qgphxKB4kw/qP1w5kTxnfU1B9Q==} dev: true - /rustbn.js/0.2.0: + /rustbn.js@0.2.0: resolution: {integrity: sha512-4VlvkRUuCJvr2J6Y0ImW7NvTCriMi7ErOAqWk1y69vAdoNIzCF3yPmgeNzx+RQTLEDFq5sHfscn1MwHxP9hNfA==} dev: true - /safe-buffer/5.1.2: + /safe-buffer@5.1.2: resolution: {integrity: sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==} dev: true - /safe-buffer/5.2.1: + /safe-buffer@5.2.1: resolution: {integrity: sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==} dev: true - /safe-event-emitter/1.0.1: + /safe-event-emitter@1.0.1: resolution: {integrity: sha512-e1wFe99A91XYYxoQbcq2ZJUWurxEyP8vfz7A7vuUe1s95q8r5ebraVaA1BukYJcpM6V16ugWoD9vngi8Ccu5fg==} deprecated: Renamed to @metamask/safe-event-emitter dependencies: events: 3.3.0 dev: true - /safe-regex-test/1.0.0: + /safe-regex-test@1.0.0: resolution: {integrity: sha512-JBUUzyOgEwXQY1NuPtvcj/qcBDbDmEvWufhlnXZIm75DEHp+afM1r1ujJpJsV/gSM4t59tpDyPi1sd6ZaPFfsA==} dependencies: call-bind: 1.0.2 @@ -9310,17 +9340,17 @@ packages: is-regex: 1.1.4 dev: true - /safe-regex/1.1.0: + /safe-regex@1.1.0: resolution: {integrity: sha512-aJXcif4xnaNUzvUuC5gcb46oTS7zvg4jpMTnuqtrEPlR3vFr4pxtdTwaF1Qs3Enjn9HK+ZlwQui+a7z0SywIzg==} dependencies: ret: 0.1.15 dev: true - /safer-buffer/2.1.2: + /safer-buffer@2.1.2: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} dev: true - /sc-istanbul/0.4.6: + /sc-istanbul@0.4.6: resolution: {integrity: sha512-qJFF/8tW/zJsbyfh/iT/ZM5QNHE3CXxtLJbZsL+CzdJLBsPD7SedJZoUA4d8iAcN2IoMp/Dx80shOOd2x96X/g==} hasBin: true dependencies: @@ -9340,21 +9370,21 @@ packages: wordwrap: 1.0.0 dev: true - /scrypt-js/2.0.4: + /scrypt-js@2.0.4: resolution: {integrity: sha512-4KsaGcPnuhtCZQCxFxN3GVYIhKFPTdLd8PLC552XwbMndtD0cjRFAhDuuydXQ0h08ZfPgzqe6EKHozpuH74iDw==} dev: true - /scrypt-js/3.0.1: + /scrypt-js@3.0.1: resolution: {integrity: sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA==} - /scryptsy/1.2.1: + /scryptsy@1.2.1: resolution: {integrity: sha512-aldIRgMozSJ/Gl6K6qmJZysRP82lz83Wb42vl4PWN8SaLFHIaOzLPc9nUUW2jQN88CuGm5q5HefJ9jZ3nWSmTw==} dependencies: pbkdf2: 3.1.2 dev: true optional: true - /secp256k1/3.7.1: + /secp256k1@3.7.1: resolution: {integrity: sha512-1cf8sbnRreXrQFdH6qsg2H71Xw91fCCS9Yp021GnUNJzWJS/py96fS4lHbnTnouLp08Xj6jBoBB6V78Tdbdu5g==} engines: {node: '>=4.0.0'} requiresBuild: true @@ -9369,7 +9399,7 @@ packages: safe-buffer: 5.2.1 dev: true - /secp256k1/4.0.3: + /secp256k1@4.0.3: resolution: {integrity: sha512-NLZVf+ROMxwtEj3Xa562qgv2BK5e2WNmXPiOdVIPLgs6lyTzMvBq0aWTYMI5XCP9jZMVKOcqZLw/Wc4vDkuxhA==} engines: {node: '>=10.0.0'} requiresBuild: true @@ -9379,31 +9409,31 @@ packages: node-gyp-build: 4.5.0 dev: true - /seedrandom/3.0.1: + /seedrandom@3.0.1: resolution: {integrity: sha512-1/02Y/rUeU1CJBAGLebiC5Lbo5FnB22gQbIFFYTLkwvp1xdABZJH1sn4ZT1MzXmPpzv+Rf/Lu2NcsLJiK4rcDg==} dev: true - /semaphore/1.1.0: + /semaphore@1.1.0: resolution: {integrity: sha512-O4OZEaNtkMd/K0i6js9SL+gqy0ZCBMgUvlSqHKi4IBdjhe7wB8pwztUk1BbZ1fmrvpwFrPbHzqd2w5pTcJH6LA==} engines: {node: '>=0.8.0'} dev: true - /semver/5.4.1: + /semver@5.4.1: resolution: {integrity: sha512-WfG/X9+oATh81XtllIo/I8gOiY9EXRdv1cQdyykeXK17YcUW3EXUAi2To4pcH6nZtJPr7ZOpM5OMyWJZm+8Rsg==} hasBin: true dev: true - /semver/5.7.1: + /semver@5.7.1: resolution: {integrity: sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==} hasBin: true dev: true - /semver/6.3.0: + /semver@6.3.0: resolution: {integrity: sha512-b39TBaTSfV6yBrapU89p5fKekE2m/NwnDocOVruQFS1/veMgdzuPcnOM34M6CwxW8jH/lxEa5rBoDeUwu5HHTw==} hasBin: true dev: true - /semver/7.3.7: + /semver@7.3.7: resolution: {integrity: sha512-QlYTucUYOews+WeEujDoEGziz4K6c47V/Bd+LjSSYcA94p+DmINdf7ncaUinThfvZyu13lN9OY1XDxt8C0Tw0g==} engines: {node: '>=10'} hasBin: true @@ -9411,7 +9441,7 @@ packages: lru-cache: 6.0.0 dev: true - /semver/7.5.0: + /semver@7.5.0: resolution: {integrity: sha512-+XC0AD/R7Q2mPSRuy2Id0+CGTZ98+8f+KvwirxOKIEyid+XSx6HbC63p+O4IndTHuX5Z+JxQ0TghCkO5Cg/2HA==} engines: {node: '>=10'} hasBin: true @@ -9419,7 +9449,7 @@ packages: lru-cache: 6.0.0 dev: true - /send/0.17.1: + /send@0.17.1: resolution: {integrity: sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==} engines: {node: '>= 0.8.0'} dependencies: @@ -9440,20 +9470,20 @@ packages: - supports-color dev: true - /sentence-case/2.1.1: + /sentence-case@2.1.1: resolution: {integrity: sha512-ENl7cYHaK/Ktwk5OTD+aDbQ3uC8IByu/6Bkg+HDv8Mm+XnBnppVNalcfJTNsp1ibstKh030/JKQQWglDvtKwEQ==} dependencies: no-case: 2.3.2 upper-case-first: 1.1.2 dev: true - /serialize-javascript/6.0.0: + /serialize-javascript@6.0.0: resolution: {integrity: sha512-Qr3TosvguFt8ePWqsvRfrKyQXIiW+nGbYpy8XK24NQHE83caxWt+mIymTT19DGFbNWNLfEwsrkSmN64lVWB9ag==} dependencies: randombytes: 2.1.0 dev: true - /serve-static/1.14.1: + /serve-static@1.14.1: resolution: {integrity: sha512-JMrvUwE54emCYWlTI+hGrGv5I8dEwmco/00EvkzIIsR7MqrHonbD9pO2MOfFnpFntl7ecpZs+3mW+XbQZu9QCg==} engines: {node: '>= 0.8.0'} dependencies: @@ -9465,7 +9495,7 @@ packages: - supports-color dev: true - /servify/0.1.12: + /servify@0.1.12: resolution: {integrity: sha512-/xE6GvsKKqyo1BAY+KxOWXcLpPsUUyji7Qg3bVD7hh1eRze5bR1uYiuDA/k3Gof1s9BTzQZEJK8sNcNGFIzeWw==} engines: {node: '>=6'} dependencies: @@ -9478,16 +9508,16 @@ packages: - supports-color dev: true - /set-blocking/2.0.0: + /set-blocking@2.0.0: resolution: {integrity: sha512-KiKBS8AnWGEyLzofFfmvKwpdPzqiy16LvQfK3yv/fVH7Bj13/wl3JSR1J+rfgRE9q7xUJK4qvgS8raSOeLUehw==} dev: true - /set-immediate-shim/1.0.1: + /set-immediate-shim@1.0.1: resolution: {integrity: sha512-Li5AOqrZWCVA2n5kryzEmqai6bKSIvpz5oUJHPVj6+dsbD3X1ixtsY5tEnsaNpH3pFAHmG8eIHUrtEtohrg+UQ==} engines: {node: '>=0.10.0'} dev: true - /set-value/2.0.1: + /set-value@2.0.1: resolution: {integrity: sha512-JxHc1weCN68wRY0fhCoXpyK55m/XPHafOmK4UWD7m2CI14GMcFypt4w/0+NV5f/ZMby2F6S2wwA7fgynh9gWSw==} engines: {node: '>=0.10.0'} dependencies: @@ -9497,23 +9527,23 @@ packages: split-string: 3.1.0 dev: true - /setimmediate/1.0.4: + /setimmediate@1.0.4: resolution: {integrity: sha512-/TjEmXQVEzdod/FFskf3o7oOAsGhHf2j1dZqRFbDzq4F3mvvxflIIi4Hd3bLQE9y/CpwqfSQam5JakI/mi3Pog==} dev: true - /setimmediate/1.0.5: + /setimmediate@1.0.5: resolution: {integrity: sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==} dev: true - /setprototypeof/1.1.1: + /setprototypeof@1.1.1: resolution: {integrity: sha512-JvdAWfbXeIGaZ9cILp38HntZSFSo3mWg6xGcJJsd+d4aRMOqauag1C63dJfDw7OaMYwEbHMOxEZ1lqVRYP2OAw==} dev: true - /setprototypeof/1.2.0: + /setprototypeof@1.2.0: resolution: {integrity: sha512-E5LDX7Wrp85Kil5bhZv46j8jOeboKq5JMmYM3gVGdGH8xFpPWXUMsNrlODCrkoxMEeNi/XZIwuRvY4XNwYMJpw==} dev: true - /sha.js/2.4.11: + /sha.js@2.4.11: resolution: {integrity: sha512-QMEp5B7cftE7APOjk5Y6xgrbWu+WkLVQwk8JNjZ8nKRciZaByEW6MubieAiToS7+dwvrjGhH8jRXz3MVd0AYqQ==} hasBin: true dependencies: @@ -9521,55 +9551,55 @@ packages: safe-buffer: 5.2.1 dev: true - /sha1/1.1.1: + /sha1@1.1.1: resolution: {integrity: sha512-dZBS6OrMjtgVkopB1Gmo4RQCDKiZsqcpAQpkV/aaj+FCrCg8r4I4qMkDPQjBgLIxlmu9k4nUbWq6ohXahOneYA==} dependencies: charenc: 0.0.2 crypt: 0.0.2 dev: true - /sha3/1.2.6: + /sha3@1.2.6: resolution: {integrity: sha512-KgLGmJGrmNB4JWVsAV11Yk6KbvsAiygWJc7t5IebWva/0NukNrjJqhtKhzy3Eiv2AKuGvhZZt7dt1mDo7HkoiQ==} requiresBuild: true dependencies: nan: 2.13.2 dev: true - /sha3/2.1.4: + /sha3@2.1.4: resolution: {integrity: sha512-S8cNxbyb0UGUM2VhRD4Poe5N58gJnJsLJ5vC7FYWGUmGhcsj4++WaIOBFVDxlG0W3To6xBuiRh+i0Qp2oNCOtg==} dependencies: buffer: 6.0.3 dev: true - /shallowequal/1.1.0: + /shallowequal@1.1.0: resolution: {integrity: sha512-y0m1JoUZSlPAjXVtPPW70aZWfIL/dSP7AFkRnniLCrK/8MDKog3TySTBmckD+RObVxH0v4Tox67+F14PdED2oQ==} dev: true - /shebang-command/1.2.0: + /shebang-command@1.2.0: resolution: {integrity: sha512-EV3L1+UQWGor21OmnvojK36mhg+TyIKDh3iFBKBohr5xeXIhNBcx8oWdgkTEEQ+BEFFYdLRuqMfd5L84N1V5Vg==} engines: {node: '>=0.10.0'} dependencies: shebang-regex: 1.0.0 dev: true - /shebang-command/2.0.0: + /shebang-command@2.0.0: resolution: {integrity: sha512-kHxr2zZpYtdmrN1qDjrrX/Z1rR1kG8Dx+gkpK1G4eXmvXswmcE1hTWBWYUzlraYw1/yZp6YuDY77YtvbN0dmDA==} engines: {node: '>=8'} dependencies: shebang-regex: 3.0.0 dev: true - /shebang-regex/1.0.0: + /shebang-regex@1.0.0: resolution: {integrity: sha512-wpoSFAxys6b2a2wHZ1XpDSgD7N9iVjg29Ph9uV/uaP9Ex/KXlkTZTeddxDPSYQpgvzKLGJke2UU0AzoGCjNIvQ==} engines: {node: '>=0.10.0'} dev: true - /shebang-regex/3.0.0: + /shebang-regex@3.0.0: resolution: {integrity: sha512-7++dFhtcx3353uBaq8DDR4NuxBetBzC7ZQOhmTQInHEd6bSrXdiEyzCvG07Z44UYdLShWUyXt5M/yhz8ekcb1A==} engines: {node: '>=8'} dev: true - /shelljs/0.8.3: + /shelljs@0.8.3: resolution: {integrity: sha512-fc0BKlAWiLpwZljmOvAOTE/gXawtCoNrP5oaY7KIaQbbyHeQVg01pSEuEGvGh3HEdBU4baCD7wQBwADmM/7f7A==} engines: {node: '>=4'} hasBin: true @@ -9579,7 +9609,7 @@ packages: rechoir: 0.6.2 dev: true - /side-channel/1.0.4: + /side-channel@1.0.4: resolution: {integrity: sha512-q5XPytqFEIKHkGdiMIrY10mvLRvnQh42/+GoBlFW3b2LXLE2xxJpZFdm94we0BaoV3RwJyGqg5wS7epxTv0Zvw==} dependencies: call-bind: 1.0.2 @@ -9587,15 +9617,15 @@ packages: object-inspect: 1.12.2 dev: true - /signal-exit/3.0.7: + /signal-exit@3.0.7: resolution: {integrity: sha512-wnD2ZE+l+SPC/uoS0vXeE9L1+0wuaMqKlfz9AMUo38JsyLSBWSFcHR1Rri62LZc12vLr1gb3jl7iwQhgwpAbGQ==} dev: true - /simple-concat/1.0.0: + /simple-concat@1.0.0: resolution: {integrity: sha512-pgxq9iGMSS24atefsqEznXW1Te610qB4pwMdrEg6mxczHh7sPtPyiixkP/VaQic8JjZofnIvT7CDeKlHqfbPBg==} dev: true - /simple-get/2.8.1: + /simple-get@2.8.1: resolution: {integrity: sha512-lSSHRSw3mQNUGPAYRqo7xy9dhKmxFXIjLjp4KHpf99GEH2VH7C3AM+Qfx6du6jhfUi6Vm7XnbEVEf7Wb6N8jRw==} dependencies: decompress-response: 3.3.0 @@ -9603,22 +9633,22 @@ packages: simple-concat: 1.0.0 dev: true - /slash/1.0.0: + /slash@1.0.0: resolution: {integrity: sha512-3TYDR7xWt4dIqV2JauJr+EJeW356RXijHeUlO+8djJ+uBXPn8/2dpzBc8yQhh583sVvc9CvFAeQVgijsH+PNNg==} engines: {node: '>=0.10.0'} dev: true - /slash/2.0.0: + /slash@2.0.0: resolution: {integrity: sha512-ZYKh3Wh2z1PpEXWr0MpSBZ0V6mZHAQfYevttO11c51CaWjGTaadiKZ+wVt1PbMlDV5qhMFslpZCemhwOK7C89A==} engines: {node: '>=6'} dev: true - /slash/3.0.0: + /slash@3.0.0: resolution: {integrity: sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q==} engines: {node: '>=8'} dev: true - /slice-ansi/4.0.0: + /slice-ansi@4.0.0: resolution: {integrity: sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==} engines: {node: '>=10'} dependencies: @@ -9627,13 +9657,13 @@ packages: is-fullwidth-code-point: 3.0.0 dev: true - /snake-case/2.1.0: + /snake-case@2.1.0: resolution: {integrity: sha512-FMR5YoPFwOLuh4rRz92dywJjyKYZNLpMn1R5ujVpIYkbA9p01fq8RMg0FkO4M+Yobt4MjHeLTJVm5xFFBHSV2Q==} dependencies: no-case: 2.3.2 dev: true - /snapdragon-node/2.1.1: + /snapdragon-node@2.1.1: resolution: {integrity: sha512-O27l4xaMYt/RSQ5TR3vpWCAB5Kb/czIcqUFOM/C4fYcLnbZUc1PkjTAMjof2pBWaSTwOUd6qUHcFGVGj7aIwnw==} engines: {node: '>=0.10.0'} dependencies: @@ -9642,14 +9672,14 @@ packages: snapdragon-util: 3.0.1 dev: true - /snapdragon-util/3.0.1: + /snapdragon-util@3.0.1: resolution: {integrity: sha512-mbKkMdQKsjX4BAL4bRYTj21edOf8cN7XHdYUJEe+Zn99hVEYcMvKPct1IqNe7+AZPirn8BCDOQBHQZknqmKlZQ==} engines: {node: '>=0.10.0'} dependencies: kind-of: 3.2.2 dev: true - /snapdragon/0.8.2: + /snapdragon@0.8.2: resolution: {integrity: sha512-FtyOnWN/wCHTVXOMwvSv26d+ko5vWlIDD6zoUJ7LW8vh+ZBC8QdljveRP+crNrtBwioEUWy/4dMtbBjA4ioNlg==} engines: {node: '>=0.10.0'} dependencies: @@ -9665,7 +9695,7 @@ packages: - supports-color dev: true - /solc/0.4.26: + /solc@0.4.26: resolution: {integrity: sha512-o+c6FpkiHd+HPjmjEVpQgH7fqZ14tJpXhho+/bQXlXbliLIS/xjXb42Vxh+qQY1WCSTMQ0+a5vR9vi0MfhU6mA==} hasBin: true dependencies: @@ -9676,7 +9706,7 @@ packages: yargs: 4.8.1 dev: true - /solc/0.6.12: + /solc@0.6.12: resolution: {integrity: sha512-Lm0Ql2G9Qc7yPP2Ba+WNmzw2jwsrd3u4PobHYlSOxaut3TtUbj9+5ZrT6f4DUpNPEoBaFUOEg9Op9C0mk7ge9g==} engines: {node: '>=8.0.0'} hasBin: true @@ -9691,14 +9721,14 @@ packages: tmp: 0.0.33 dev: true - /solc/0.7.3_debug@4.3.4: + /solc@0.7.3(debug@4.3.4): resolution: {integrity: sha512-GAsWNAjGzIDg7VxzP6mPjdurby3IkGCjQcM8GFYZT6RyaoUZKmMU6Y7YwG+tFGhv7dwZ8rmR4iwFDrrD99JwqA==} engines: {node: '>=8.0.0'} hasBin: true dependencies: command-exists: 1.2.9 commander: 3.0.2 - follow-redirects: 1.15.2_debug@4.3.4 + follow-redirects: 1.15.2(debug@4.3.4) fs-extra: 0.30.0 js-sha3: 0.8.0 memorystream: 0.3.1 @@ -9709,7 +9739,7 @@ packages: - debug dev: true - /solhint-plugin-prettier/0.0.5_x46sgpbsioqs6smmgnper2ntba: + /solhint-plugin-prettier@0.0.5(prettier-plugin-solidity@1.1.3)(prettier@2.8.8): resolution: {integrity: sha512-7jmWcnVshIrO2FFinIvDQmhQpfpS2rRRn3RejiYgnjIE68xO2bvrYvjqVNfrio4xH9ghOqn83tKuTzLjEbmGIA==} peerDependencies: prettier: ^1.15.0 || ^2.0.0 @@ -9717,10 +9747,10 @@ packages: dependencies: prettier: 2.8.8 prettier-linter-helpers: 1.0.0 - prettier-plugin-solidity: 1.1.3_prettier@2.8.8 + prettier-plugin-solidity: 1.1.3(prettier@2.8.8) dev: true - /solhint/3.4.1: + /solhint@3.4.1: resolution: {integrity: sha512-pzZn2RlZhws1XwvLPVSsxfHrwsteFf5eySOhpAytzXwKQYbTCJV6z8EevYDiSVKMpWrvbKpEtJ055CuEmzp4Xg==} hasBin: true dependencies: @@ -9745,11 +9775,11 @@ packages: prettier: 2.8.8 dev: true - /solidity-ast/0.4.45: + /solidity-ast@0.4.45: resolution: {integrity: sha512-N6uqfaDulVZqjpjru+KvMLjV89M3hesyr/1/t8nkjohRagFSDmDxZvb9viKV98pdwpMzs61Nt2JAApgh0fkL0g==} dev: true - /solidity-comments-darwin-arm64/0.0.2: + /solidity-comments-darwin-arm64@0.0.2: resolution: {integrity: sha512-HidWkVLSh7v+Vu0CA7oI21GWP/ZY7ro8g8OmIxE8oTqyMwgMbE8F1yc58Sj682Hj199HCZsjmtn1BE4PCbLiGA==} engines: {node: '>= 10'} cpu: [arm64] @@ -9758,7 +9788,7 @@ packages: dev: true optional: true - /solidity-comments-darwin-x64/0.0.2: + /solidity-comments-darwin-x64@0.0.2: resolution: {integrity: sha512-Zjs0Ruz6faBTPT6fBecUt6qh4CdloT8Bwoc0+qxRoTn9UhYscmbPQkUgQEbS0FQPysYqVzzxJB4h1Ofbf4wwtA==} engines: {node: '>= 10'} cpu: [x64] @@ -9767,11 +9797,11 @@ packages: dev: true optional: true - /solidity-comments-extractor/0.0.7: + /solidity-comments-extractor@0.0.7: resolution: {integrity: sha512-wciNMLg/Irp8OKGrh3S2tfvZiZ0NEyILfcRCXCD4mp7SgK/i9gzLfhY2hY7VMCQJ3kH9UB9BzNdibIVMchzyYw==} dev: true - /solidity-comments-freebsd-x64/0.0.2: + /solidity-comments-freebsd-x64@0.0.2: resolution: {integrity: sha512-8Qe4mpjuAxFSwZJVk7B8gAoLCdbtS412bQzBwk63L8dmlHogvE39iT70aAk3RHUddAppT5RMBunlPUCFYJ3ZTw==} engines: {node: '>= 10'} cpu: [x64] @@ -9780,7 +9810,7 @@ packages: dev: true optional: true - /solidity-comments-linux-arm64-gnu/0.0.2: + /solidity-comments-linux-arm64-gnu@0.0.2: resolution: {integrity: sha512-spkb0MZZnmrP+Wtq4UxP+nyPAVRe82idOjqndolcNR0S9Xvu4ebwq+LvF4HiUgjTDmeiqYiFZQ8T9KGdLSIoIg==} engines: {node: '>= 10'} cpu: [arm64] @@ -9789,7 +9819,7 @@ packages: dev: true optional: true - /solidity-comments-linux-arm64-musl/0.0.2: + /solidity-comments-linux-arm64-musl@0.0.2: resolution: {integrity: sha512-guCDbHArcjE+JDXYkxx5RZzY1YF6OnAKCo+sTC5fstyW/KGKaQJNPyBNWuwYsQiaEHpvhW1ha537IvlGek8GqA==} engines: {node: '>= 10'} cpu: [arm64] @@ -9798,7 +9828,7 @@ packages: dev: true optional: true - /solidity-comments-linux-x64-gnu/0.0.2: + /solidity-comments-linux-x64-gnu@0.0.2: resolution: {integrity: sha512-zIqLehBK/g7tvrFmQljrfZXfkEeLt2v6wbe+uFu6kH/qAHZa7ybt8Vc0wYcmjo2U0PeBm15d79ee3AkwbIjFdQ==} engines: {node: '>= 10'} cpu: [x64] @@ -9807,7 +9837,7 @@ packages: dev: true optional: true - /solidity-comments-linux-x64-musl/0.0.2: + /solidity-comments-linux-x64-musl@0.0.2: resolution: {integrity: sha512-R9FeDloVlFGTaVkOlELDVC7+1Tjx5WBPI5L8r0AGOPHK3+jOcRh6sKYpI+VskSPDc3vOO46INkpDgUXrKydlIw==} engines: {node: '>= 10'} cpu: [x64] @@ -9816,7 +9846,7 @@ packages: dev: true optional: true - /solidity-comments-win32-arm64-msvc/0.0.2: + /solidity-comments-win32-arm64-msvc@0.0.2: resolution: {integrity: sha512-QnWJoCQcJj+rnutULOihN9bixOtYWDdF5Rfz9fpHejL1BtNjdLW1om55XNVHGAHPqBxV4aeQQ6OirKnp9zKsug==} engines: {node: '>= 10'} cpu: [arm64] @@ -9825,7 +9855,7 @@ packages: dev: true optional: true - /solidity-comments-win32-ia32-msvc/0.0.2: + /solidity-comments-win32-ia32-msvc@0.0.2: resolution: {integrity: sha512-vUg4nADtm/NcOtlIymG23NWJUSuMsvX15nU7ynhGBsdKtt8xhdP3C/zA6vjDk8Jg+FXGQL6IHVQ++g/7rSQi0w==} engines: {node: '>= 10'} cpu: [ia32] @@ -9834,7 +9864,7 @@ packages: dev: true optional: true - /solidity-comments-win32-x64-msvc/0.0.2: + /solidity-comments-win32-x64-msvc@0.0.2: resolution: {integrity: sha512-36j+KUF4V/y0t3qatHm/LF5sCUCBx2UndxE1kq5bOzh/s+nQgatuyB+Pd5BfuPQHdWu2KaExYe20FlAa6NL7+Q==} engines: {node: '>= 10'} cpu: [x64] @@ -9843,7 +9873,7 @@ packages: dev: true optional: true - /solidity-comments/0.0.2: + /solidity-comments@0.0.2: resolution: {integrity: sha512-G+aK6qtyUfkn1guS8uzqUeua1dURwPlcOjoTYW/TwmXAcE7z/1+oGCfZUdMSe4ZMKklNbVZNiG5ibnF8gkkFfw==} engines: {node: '>= 12'} optionalDependencies: @@ -9859,7 +9889,7 @@ packages: solidity-comments-win32-x64-msvc: 0.0.2 dev: true - /solidity-coverage/0.8.4_hardhat@2.12.7: + /solidity-coverage@0.8.4(hardhat@2.12.7): resolution: {integrity: sha512-xeHOfBOjdMF6hWTbt42iH4x+7j1Atmrf5OldDPMxI+i/COdExUxszOswD9qqvcBTaLGiOrrpnh9UZjSpt4rBsg==} hasBin: true peerDependencies: @@ -9875,7 +9905,7 @@ packages: ghost-testrpc: 0.0.2 global-modules: 2.0.0 globby: 10.0.2 - hardhat: 2.12.7_goz53koj4ourpjwgrks4nqbe6i + hardhat: 2.12.7(ts-node@10.0.0)(typescript@4.9.5) jsonschema: 1.4.0 lodash: 4.17.21 mocha: 7.1.2 @@ -9890,13 +9920,13 @@ packages: - supports-color dev: true - /sort-any/2.0.0: + /sort-any@2.0.0: resolution: {integrity: sha512-T9JoiDewQEmWcnmPn/s9h/PH9t3d/LSWi0RgVmXSuDYeZXTZOZ1/wrK2PHaptuR1VXe3clLLt0pD6sgVOwjNEA==} dependencies: lodash: 4.17.21 dev: true - /source-map-resolve/0.5.3: + /source-map-resolve@0.5.3: resolution: {integrity: sha512-Htz+RnsXWk5+P2slx5Jh3Q66vhQj1Cllm0zvnaY98+NFx+Dv2CF/f5O/t8x+KaNdrdIAsruNzoh/KpialbqAnw==} deprecated: See https://github.com/lydell/source-map-resolve#deprecated dependencies: @@ -9907,32 +9937,32 @@ packages: urix: 0.1.0 dev: true - /source-map-support/0.4.18: + /source-map-support@0.4.18: resolution: {integrity: sha512-try0/JqxPLF9nOjvSta7tVondkP5dwgyLDjVoyMDlmjugT2lRZ1OfsrYTkCd2hkDnJTKRbO/Rl3orm8vlsUzbA==} dependencies: source-map: 0.5.7 dev: true - /source-map-support/0.5.12: + /source-map-support@0.5.12: resolution: {integrity: sha512-4h2Pbvyy15EE02G+JOZpUCmqWJuqrs+sEkzewTm++BPi7Hvn/HwcqLAcNxYAyI0x13CpPPn+kMjl+hplXMHITQ==} dependencies: buffer-from: 1.1.2 source-map: 0.6.1 dev: true - /source-map-support/0.5.21: + /source-map-support@0.5.21: resolution: {integrity: sha512-uBHU3L3czsIyYXKX88fdrGovxdSCoTGDRZ6SYXtSRxLZUzHg5P/66Ht6uoUlHu9EZod+inXhKo3qQgwXUT/y1w==} dependencies: buffer-from: 1.1.2 source-map: 0.6.1 dev: true - /source-map-url/0.4.1: + /source-map-url@0.4.1: resolution: {integrity: sha512-cPiFOTLUKvJFIg4SKVScy4ilPPW6rFgMgfuZJPNoDuMs3nC1HbMUycBoJw77xFIp6z1UJQJOfx6C9GMH80DiTw==} deprecated: See https://github.com/lydell/source-map-url#deprecated dev: true - /source-map/0.2.0: + /source-map@0.2.0: resolution: {integrity: sha512-CBdZ2oa/BHhS4xj5DlhjWNHcan57/5YuvfdLf17iVmIpd9KRm+DFLmC6nBNj+6Ua7Kt3TmOjDpQT1aTYOQtoUA==} engines: {node: '>=0.8.0'} requiresBuild: true @@ -9941,50 +9971,50 @@ packages: dev: true optional: true - /source-map/0.5.7: + /source-map@0.5.7: resolution: {integrity: sha512-LbrmJOMUSdEVxIKvdcJzQC+nQhe8FUZQTXQy6+I75skNgn3OoQ0DZA8YnFa7gp8tqtL3KPf1kmo0R5DoApeSGQ==} engines: {node: '>=0.10.0'} dev: true - /source-map/0.6.1: + /source-map@0.6.1: resolution: {integrity: sha512-UjgapumWlbMhkBgzT7Ykc5YXUT46F0iKu8SGXq0bcwP5dz/h0Plj6enJqjz1Zbq2l5WaqYnrVbwWOWMyF3F47g==} engines: {node: '>=0.10.0'} dev: true - /spdx-correct/3.1.1: + /spdx-correct@3.1.1: resolution: {integrity: sha512-cOYcUWwhCuHCXi49RhFRCyJEK3iPj1Ziz9DpViV3tbZOwXD49QzIN3MpOLJNxh2qwq2lJJZaKMVw9qNi4jTC0w==} dependencies: spdx-expression-parse: 3.0.1 spdx-license-ids: 3.0.12 dev: true - /spdx-exceptions/2.3.0: + /spdx-exceptions@2.3.0: resolution: {integrity: sha512-/tTrYOC7PPI1nUAgx34hUpqXuyJG+DTHJTnIULG4rDygi4xu/tfgmq1e1cIRwRzwZgo4NLySi+ricLkZkw4i5A==} dev: true - /spdx-expression-parse/3.0.1: + /spdx-expression-parse@3.0.1: resolution: {integrity: sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==} dependencies: spdx-exceptions: 2.3.0 spdx-license-ids: 3.0.12 dev: true - /spdx-license-ids/3.0.12: + /spdx-license-ids@3.0.12: resolution: {integrity: sha512-rr+VVSXtRhO4OHbXUiAF7xW3Bo9DuuF6C5jH+q/x15j2jniycgKbxU09Hr0WqlSLUs4i4ltHGXqTe7VHclYWyA==} dev: true - /split-string/3.1.0: + /split-string@3.1.0: resolution: {integrity: sha512-NzNVhJDYpwceVVii8/Hu6DKfD2G+NrQHlS/V/qgv763EYudVwEcMQNxd2lh+0VrUByXN/oJkl5grOhYWvQUYiw==} engines: {node: '>=0.10.0'} dependencies: extend-shallow: 3.0.2 dev: true - /sprintf-js/1.0.3: + /sprintf-js@1.0.3: resolution: {integrity: sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==} dev: true - /sshpk/1.16.1: + /sshpk@1.16.1: resolution: {integrity: sha512-HXXqVUq7+pcKeLqqZj6mHFUMvXtOJt1uoUx09pFW6011inTMxqI8BA8PM95myrIyyKwdnzjdFjLiE6KBPVtJIg==} engines: {node: '>=0.10.0'} hasBin: true @@ -10000,14 +10030,14 @@ packages: tweetnacl: 0.14.5 dev: true - /stacktrace-parser/0.1.10: + /stacktrace-parser@0.1.10: resolution: {integrity: sha512-KJP1OCML99+8fhOHxwwzyWrlUuVX5GQ0ZpJTd1DFXhdkrvg1szxfHhawXUZ3g9TkXORQd4/WG68jMlQZ2p8wlg==} engines: {node: '>=6'} dependencies: type-fest: 0.7.1 dev: true - /static-extend/0.1.2: + /static-extend@0.1.2: resolution: {integrity: sha512-72E9+uLc27Mt718pMHt9VMNiAL4LMsmDbBva8mxWUCkT07fSzEGMYUCk0XWY6lp0j6RBAG4cJ3mWuZv2OE3s0g==} engines: {node: '>=0.10.0'} dependencies: @@ -10015,43 +10045,43 @@ packages: object-copy: 0.1.0 dev: true - /statuses/1.5.0: + /statuses@1.5.0: resolution: {integrity: sha512-OpZ3zP+jT1PI7I8nemJX4AKmAX070ZkYPVWV/AaKTJl+tXCTGyVdC1a4SL8RUQYEwk/f34ZX8UTykN68FwrqAA==} engines: {node: '>= 0.6'} dev: true - /statuses/2.0.1: + /statuses@2.0.1: resolution: {integrity: sha512-RwNA9Z/7PrK06rYLIzFMlaF+l73iwpzsqRIFgbMLbTcLD6cOao82TaWefPXQvB2fOC4AjuYSEndS7N/mTCbkdQ==} engines: {node: '>= 0.8'} dev: true - /stealthy-require/1.1.1: + /stealthy-require@1.1.1: resolution: {integrity: sha512-ZnWpYnYugiOVEY5GkcuJK1io5V8QmNYChG62gSit9pQVGErXtrKuPC55ITaVSukmMta5qpMU7vqLt2Lnni4f/g==} engines: {node: '>=0.10.0'} dev: true - /stream-to-pull-stream/1.7.3: + /stream-to-pull-stream@1.7.3: resolution: {integrity: sha512-6sNyqJpr5dIOQdgNy/xcDWwDuzAsAwVzhzrWlAPAQ7Lkjx/rv0wgvxEyKwTq6FmNd5rjTrELt/CLmaSw7crMGg==} dependencies: looper: 3.0.0 pull-stream: 3.6.14 dev: true - /streamsearch/1.1.0: + /streamsearch@1.1.0: resolution: {integrity: sha512-Mcc5wHehp9aXz1ax6bZUyY5afg9u2rv5cqQI3mRrYkGC8rW2hM02jWuwjtL++LS5qinSyhj2QfLyNsuc+VsExg==} engines: {node: '>=10.0.0'} dev: true - /strict-uri-encode/1.1.0: + /strict-uri-encode@1.1.0: resolution: {integrity: sha512-R3f198pcvnB+5IpnBlRkphuE9n46WyVl8I39W/ZUTZLz4nqSP/oLYUrcnJrw462Ds8he4YKMov2efsTIw1BDGQ==} engines: {node: '>=0.10.0'} dev: true - /string-format/2.0.0: + /string-format@2.0.0: resolution: {integrity: sha512-bbEs3scLeYNXLecRRuk6uJxdXUSj6le/8rNPHChIJTn2V79aXVTR1EH2OH5zLKKoz0V02fOUKZZcw01pLUShZA==} dev: true - /string-width/1.0.2: + /string-width@1.0.2: resolution: {integrity: sha512-0XsVpQLnVCXHJfyEs8tC0zpTVIr5PKKsQtkT29IwupnPTjtPmQ3xT/4yCREF9hYkV/3M3kzcUTSAZT6a6h81tw==} engines: {node: '>=0.10.0'} dependencies: @@ -10060,7 +10090,7 @@ packages: strip-ansi: 3.0.1 dev: true - /string-width/2.1.1: + /string-width@2.1.1: resolution: {integrity: sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==} engines: {node: '>=4'} dependencies: @@ -10068,7 +10098,7 @@ packages: strip-ansi: 4.0.0 dev: true - /string-width/3.1.0: + /string-width@3.1.0: resolution: {integrity: sha512-vafcv6KjVZKSgz06oM/H6GDBrAtz8vdhQakGjFIvNrHA6y3HCF1CInLy+QLq8dTJPQ1b+KDUqDFctkdRW44e1w==} engines: {node: '>=6'} dependencies: @@ -10077,7 +10107,7 @@ packages: strip-ansi: 5.2.0 dev: true - /string-width/4.2.3: + /string-width@4.2.3: resolution: {integrity: sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==} engines: {node: '>=8'} dependencies: @@ -10086,7 +10116,7 @@ packages: strip-ansi: 6.0.1 dev: true - /string.prototype.trim/1.2.6: + /string.prototype.trim@1.2.6: resolution: {integrity: sha512-8lMR2m+U0VJTPp6JjvJTtGyc4FIGq9CdRt7O9p6T0e6K4vjU+OP+SQJpbe/SBmRcCUIvNUnjsbmY6lnMp8MhsQ==} engines: {node: '>= 0.4'} dependencies: @@ -10095,7 +10125,7 @@ packages: es-abstract: 1.20.3 dev: true - /string.prototype.trimend/1.0.5: + /string.prototype.trimend@1.0.5: resolution: {integrity: sha512-I7RGvmjV4pJ7O3kdf+LXFpVfdNOxtCW/2C8f6jNiW4+PQchwxkCDzlk1/7p+Wl4bqFIZeF47qAHXLuHHWKAxog==} dependencies: call-bind: 1.0.2 @@ -10103,7 +10133,7 @@ packages: es-abstract: 1.20.3 dev: true - /string.prototype.trimstart/1.0.5: + /string.prototype.trimstart@1.0.5: resolution: {integrity: sha512-THx16TJCGlsN0o6dl2o6ncWUsdgnLRSA23rRE5pyGBw/mLr3Ej/R2LaqCtgP8VNMGZsvMWnf9ooZPyY2bHvUFg==} dependencies: call-bind: 1.0.2 @@ -10111,132 +10141,132 @@ packages: es-abstract: 1.20.3 dev: true - /string_decoder/0.10.31: + /string_decoder@0.10.31: resolution: {integrity: sha512-ev2QzSzWPYmy9GuqfIVildA4OdcGLeFZQrq5ys6RtiuF+RQQiZWr8TZNyAcuVXyQRYfEO+MsoB/1BuQVhOJuoQ==} dev: true - /string_decoder/1.1.1: + /string_decoder@1.1.1: resolution: {integrity: sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==} dependencies: safe-buffer: 5.1.2 dev: true - /string_decoder/1.3.0: + /string_decoder@1.3.0: resolution: {integrity: sha512-hkRX8U1WjJFd8LsDJ2yQ/wWWxaopEsABU1XfkM8A+j0+85JAGppt16cr1Whg6KIbb4okU6Mql6BOj+uup/wKeA==} dependencies: safe-buffer: 5.2.1 dev: true - /strip-ansi/3.0.1: + /strip-ansi@3.0.1: resolution: {integrity: sha512-VhumSSbBqDTP8p2ZLKj40UjBCV4+v8bUSEpUb4KjRgWk9pbqGF4REFj6KEagidb2f/M6AzC0EmFyDNGaw9OCzg==} engines: {node: '>=0.10.0'} dependencies: ansi-regex: 2.1.1 dev: true - /strip-ansi/4.0.0: + /strip-ansi@4.0.0: resolution: {integrity: sha512-4XaJ2zQdCzROZDivEVIDPkcQn8LMFSa8kj8Gxb/Lnwzv9A8VctNZ+lfivC/sV3ivW8ElJTERXZoPBRrZKkNKow==} engines: {node: '>=4'} dependencies: ansi-regex: 3.0.1 dev: true - /strip-ansi/5.2.0: + /strip-ansi@5.2.0: resolution: {integrity: sha512-DuRs1gKbBqsMKIZlrffwlug8MHkcnpjs5VPmL1PAh+mA30U0DTotfDZ0d2UUsXpPmPmMMJ6W773MaA3J+lbiWA==} engines: {node: '>=6'} dependencies: ansi-regex: 4.1.1 dev: true - /strip-ansi/6.0.1: + /strip-ansi@6.0.1: resolution: {integrity: sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==} engines: {node: '>=8'} dependencies: ansi-regex: 5.0.1 dev: true - /strip-bom/2.0.0: + /strip-bom@2.0.0: resolution: {integrity: sha512-kwrX1y7czp1E69n2ajbG65mIo9dqvJ+8aBQXOGVxqwvNbsXdFM6Lq37dLAY3mknUwru8CfcCbfOLL/gMo+fi3g==} engines: {node: '>=0.10.0'} dependencies: is-utf8: 0.2.1 dev: true - /strip-hex-prefix/1.0.0: + /strip-hex-prefix@1.0.0: resolution: {integrity: sha512-q8d4ue7JGEiVcypji1bALTos+0pWtyGlivAWyPuTkHzuTCJqrK9sWxYQZUq6Nq3cuyv3bm734IhHvHtGGURU6A==} engines: {node: '>=6.5.0', npm: '>=3'} dependencies: is-hex-prefixed: 1.0.0 dev: true - /strip-indent/2.0.0: + /strip-indent@2.0.0: resolution: {integrity: sha512-RsSNPLpq6YUL7QYy44RnPVTn/lcVZtb48Uof3X5JLbF4zD/Gs7ZFDv2HWol+leoQN2mT86LAzSshGfkTlSOpsA==} engines: {node: '>=4'} dev: true - /strip-json-comments/2.0.1: + /strip-json-comments@2.0.1: resolution: {integrity: sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==} engines: {node: '>=0.10.0'} dev: true - /strip-json-comments/3.1.1: + /strip-json-comments@3.1.1: resolution: {integrity: sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig==} engines: {node: '>=8'} dev: true - /supports-color/2.0.0: + /supports-color@2.0.0: resolution: {integrity: sha512-KKNVtd6pCYgPIKU4cp2733HWYCpplQhddZLBUryaAHou723x+FRzQ5Df824Fj+IyyuiQTRoub4SnIFfIcrp70g==} engines: {node: '>=0.8.0'} dev: true - /supports-color/3.2.3: + /supports-color@3.2.3: resolution: {integrity: sha512-Jds2VIYDrlp5ui7t8abHN2bjAu4LV/q4N2KivFPpGH0lrka0BMq/33AmECUXlKPcHigkNaqfXRENFju+rlcy+A==} engines: {node: '>=0.8.0'} dependencies: has-flag: 1.0.0 dev: true - /supports-color/5.5.0: + /supports-color@5.5.0: resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==} engines: {node: '>=4'} dependencies: has-flag: 3.0.0 dev: true - /supports-color/6.0.0: + /supports-color@6.0.0: resolution: {integrity: sha512-on9Kwidc1IUQo+bQdhi8+Tijpo0e1SS6RoGo2guUwn5vdaxw8RXOF9Vb2ws+ihWOmh4JnCJOvaziZWP1VABaLg==} engines: {node: '>=6'} dependencies: has-flag: 3.0.0 dev: true - /supports-color/7.2.0: + /supports-color@7.2.0: resolution: {integrity: sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==} engines: {node: '>=8'} dependencies: has-flag: 4.0.0 dev: true - /supports-color/8.1.1: + /supports-color@8.1.1: resolution: {integrity: sha512-MpUEN2OodtUzxvKQl72cUF7RQ5EiHsGvSsVG0ia9c5RbWGL2CI4C7EpPS8UTBIplnlzZiNuV56w+FuNxy3ty2Q==} engines: {node: '>=10'} dependencies: has-flag: 4.0.0 dev: true - /supports-preserve-symlinks-flag/1.0.0: + /supports-preserve-symlinks-flag@1.0.0: resolution: {integrity: sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==} engines: {node: '>= 0.4'} dev: true - /swap-case/1.1.2: + /swap-case@1.1.2: resolution: {integrity: sha512-BAmWG6/bx8syfc6qXPprof3Mn5vQgf5dwdUNJhsNqU9WdPt5P+ES/wQ5bxfijy8zwZgZZHslC3iAsxsuQMCzJQ==} dependencies: lower-case: 1.1.4 upper-case: 1.1.3 dev: true - /swarm-js/0.1.40: + /swarm-js@0.1.40: resolution: {integrity: sha512-yqiOCEoA4/IShXkY3WKwP5PvZhmoOOD8clsKA7EEcRILMkTEYHCQ21HDCAcVpmIxZq4LyZvWeRJ6quIyHk1caA==} dependencies: bluebird: 3.7.2 @@ -10256,7 +10286,7 @@ packages: - utf-8-validate dev: true - /sync-request/6.1.0: + /sync-request@6.1.0: resolution: {integrity: sha512-8fjNkrNlNCrVc/av+Jn+xxqfCjYaBoHqCsDz6mt030UMxJGr+GSfCV1dQt2gRtlL63+VPidwDVLr7V2OcTSdRw==} engines: {node: '>=8.0.0'} dependencies: @@ -10265,13 +10295,13 @@ packages: then-request: 6.0.2 dev: true - /sync-rpc/1.3.6: + /sync-rpc@1.3.6: resolution: {integrity: sha512-J8jTXuZzRlvU7HemDgHi3pGnh/rkoqR/OZSjhTyyZrEkkYQbk7Z33AXp37mkPfPpfdOuj7Ex3H/TJM1z48uPQw==} dependencies: get-port: 3.2.0 dev: true - /table-layout/1.0.2: + /table-layout@1.0.2: resolution: {integrity: sha512-qd/R7n5rQTRFi+Zf2sk5XVVd9UQl6ZkduPFC3S7WEGJAmetDTjY3qPN50eSKzwuzEyQKy5TN2TiZdkIjos2L6A==} engines: {node: '>=8.0.0'} dependencies: @@ -10281,7 +10311,7 @@ packages: wordwrapjs: 4.0.1 dev: true - /table/6.8.0: + /table@6.8.0: resolution: {integrity: sha512-s/fitrbVeEyHKFa7mFdkuQMWlH1Wgw/yEXMt5xACT4ZpzWFluehAxRtUUQKPuWhaLAWhFcVx6w3oC8VKaUfPGA==} engines: {node: '>=10.0.0'} dependencies: @@ -10292,7 +10322,7 @@ packages: strip-ansi: 6.0.1 dev: true - /table/6.8.1: + /table@6.8.1: resolution: {integrity: sha512-Y4X9zqrCftUhMeH2EptSSERdVKt/nEdijTOacGD/97EKjhQ/Qs8RTlEGABSJNNN8lac9kheH+af7yAkEWlgneA==} engines: {node: '>=10.0.0'} dependencies: @@ -10303,7 +10333,7 @@ packages: strip-ansi: 6.0.1 dev: true - /tape/4.16.1: + /tape@4.16.1: resolution: {integrity: sha512-U4DWOikL5gBYUrlzx+J0oaRedm2vKLFbtA/+BRAXboGWpXO7bMP8ddxlq3Cse2bvXFQ0jZMOj6kk3546mvCdFg==} hasBin: true dependencies: @@ -10324,7 +10354,7 @@ packages: through: 2.3.8 dev: true - /tar/4.4.19: + /tar@4.4.19: resolution: {integrity: sha512-a20gEsvHnWe0ygBY8JbxoM4w3SJdhc7ZAuxkLqh+nvNQN2IOt0B5lLgM490X5Hl8FF0dl0tOf2ewFYAlIFgzVA==} engines: {node: '>=4.5'} dependencies: @@ -10337,7 +10367,7 @@ packages: yallist: 3.1.1 dev: true - /test-value/2.1.0: + /test-value@2.1.0: resolution: {integrity: sha512-+1epbAxtKeXttkGFMTX9H42oqzOTufR1ceCF+GYA5aOmvaPq9wd4PUS8329fn2RRLGNeUkgRLnVpycjx8DsO2w==} engines: {node: '>=0.10.0'} dependencies: @@ -10345,16 +10375,16 @@ packages: typical: 2.6.1 dev: true - /testrpc/0.0.1: + /testrpc@0.0.1: resolution: {integrity: sha512-afH1hO+SQ/VPlmaLUFj2636QMeDvPCeQMc/9RBMW0IfjNe9gFD9Ra3ShqYkB7py0do1ZcCna/9acHyzTJ+GcNA==} deprecated: testrpc has been renamed to ganache-cli, please use this package from now on. dev: true - /text-table/0.2.0: + /text-table@0.2.0: resolution: {integrity: sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==} dev: true - /then-request/6.0.2: + /then-request@6.0.2: resolution: {integrity: sha512-3ZBiG7JvP3wbDzA9iNY5zJQcHL4jn/0BWtXIkagfz7QgOL/LqjCEOBQuJNZfu0XYnv5JhKh+cDxCPM4ILrqruA==} engines: {node: '>=6.0.0'} dependencies: @@ -10371,61 +10401,61 @@ packages: qs: 6.11.0 dev: true - /through/2.3.8: - resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} - dev: true - - /through2/2.0.5: + /through2@2.0.5: resolution: {integrity: sha512-/mrRod8xqpA+IHSLyGCQ2s8SPHiCDEeQJSep1jqLYeEUClOFG2Qsh+4FU6G9VeqpZnGW/Su8LQGc4YKni5rYSQ==} dependencies: readable-stream: 2.3.7 xtend: 4.0.2 dev: true - /timed-out/4.0.1: + /through@2.3.8: + resolution: {integrity: sha512-w89qg7PI8wAdvX60bMDP+bFoD5Dvhm9oLheFp5O4a2QF0cSBGsBX4qZmadPMvVqlLJBBci+WqGGOAPvcDeNSVg==} + dev: true + + /timed-out@4.0.1: resolution: {integrity: sha512-G7r3AhovYtr5YKOWQkta8RKAPb+J9IsO4uVmzjl8AZwfhs8UcUwTiD6gcJYSgOtzyjvQKrKYn41syHbUWMkafA==} engines: {node: '>=0.10.0'} dev: true - /title-case/2.1.1: + /title-case@2.1.1: resolution: {integrity: sha512-EkJoZ2O3zdCz3zJsYCsxyq2OC5hrxR9mfdd5I+w8h/tmFfeOxJ+vvkxsKxdmN0WtS9zLdHEgfgVOiMVgv+Po4Q==} dependencies: no-case: 2.3.2 upper-case: 1.1.3 dev: true - /tmp/0.0.33: + /tmp@0.0.33: resolution: {integrity: sha512-jRCJlojKnZ3addtTOjdIqoRuPEKBvNXcGYqzO6zWZX8KfKEpnGY5jfggJQ3EjKuu8D4bJRr0y+cYJFmYbImXGw==} engines: {node: '>=0.6.0'} dependencies: os-tmpdir: 1.0.2 dev: true - /tmp/0.1.0: + /tmp@0.1.0: resolution: {integrity: sha512-J7Z2K08jbGcdA1kkQpJSqLF6T0tdQqpR2pnSUXsIchbPdTI9v3e85cLW0d6WDhwuAleOV71j2xWs8qMPfK7nKw==} engines: {node: '>=6'} dependencies: rimraf: 2.7.1 dev: true - /to-fast-properties/1.0.3: + /to-fast-properties@1.0.3: resolution: {integrity: sha512-lxrWP8ejsq+7E3nNjwYmUBMAgjMTZoTI+sdBOpvNyijeDLa29LUn9QaoXAHv4+Z578hbmHHJKZknzxVtvo77og==} engines: {node: '>=0.10.0'} dev: true - /to-object-path/0.3.0: + /to-object-path@0.3.0: resolution: {integrity: sha512-9mWHdnGRuh3onocaHzukyvCZhzvr6tiflAy/JRFXcJX0TjgfWA9pk9t8CMbzmBE4Jfw58pXbkngtBtqYxzNEyg==} engines: {node: '>=0.10.0'} dependencies: kind-of: 3.2.2 dev: true - /to-readable-stream/1.0.0: + /to-readable-stream@1.0.0: resolution: {integrity: sha512-Iq25XBt6zD5npPhlLVXGFN3/gyR2/qODcKNNyTMd4vbm39HUaOiAM4PMq0eMVC/Tkxz+Zjdsc55g9yyz+Yq00Q==} engines: {node: '>=6'} dev: true - /to-regex-range/2.1.1: + /to-regex-range@2.1.1: resolution: {integrity: sha512-ZZWNfCjUokXXDGXFpZehJIkZqq91BcULFq/Pi7M5i4JnxXdhMKAK682z8bCW3o8Hj1wuuzoKcW3DfVzaP6VuNg==} engines: {node: '>=0.10.0'} dependencies: @@ -10433,14 +10463,14 @@ packages: repeat-string: 1.6.1 dev: true - /to-regex-range/5.0.1: + /to-regex-range@5.0.1: resolution: {integrity: sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==} engines: {node: '>=8.0'} dependencies: is-number: 7.0.0 dev: true - /to-regex/3.0.2: + /to-regex@3.0.2: resolution: {integrity: sha512-FWtleNAtZ/Ki2qtqej2CXTOayOH9bHDQF+Q48VpWyDXjbYxA4Yz8iDB31zXOBUlOHHKidDbqGVrTUvQMPmBGBw==} engines: {node: '>=0.10.0'} dependencies: @@ -10450,17 +10480,17 @@ packages: safe-regex: 1.1.0 dev: true - /toidentifier/1.0.0: + /toidentifier@1.0.0: resolution: {integrity: sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==} engines: {node: '>=0.6'} dev: true - /toidentifier/1.0.1: + /toidentifier@1.0.1: resolution: {integrity: sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA==} engines: {node: '>=0.6'} dev: true - /tough-cookie/2.5.0: + /tough-cookie@2.5.0: resolution: {integrity: sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g==} engines: {node: '>=0.8'} dependencies: @@ -10468,16 +10498,16 @@ packages: punycode: 2.1.1 dev: true - /tr46/0.0.3: + /tr46@0.0.3: resolution: {integrity: sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw==} dev: true - /trim-right/1.0.1: + /trim-right@1.0.1: resolution: {integrity: sha512-WZGXGstmCWgeevgTL54hrCuw1dyMQIzWy7ZfqRJfSmJZBwklI15egmQytFP6bPidmw3M8d5yEowl1niq4vmqZw==} engines: {node: '>=0.10.0'} dev: true - /ts-command-line-args/2.5.1: + /ts-command-line-args@2.5.1: resolution: {integrity: sha512-H69ZwTw3rFHb5WYpQya40YAX2/w7Ut75uUECbgBIsLmM+BNuYnxsltfyyLMxy6sEeKxgijLTnQtLd0nKd6+IYw==} hasBin: true dependencies: @@ -10487,11 +10517,11 @@ packages: string-format: 2.0.0 dev: true - /ts-essentials/1.0.4: + /ts-essentials@1.0.4: resolution: {integrity: sha512-q3N1xS4vZpRouhYHDPwO0bDW3EZ6SK9CrrDHxi/D6BPReSjpVgWIOpLS2o0gSBZm+7q/wyKp6RVM1AeeW7uyfQ==} dev: true - /ts-essentials/6.0.7_typescript@4.9.5: + /ts-essentials@6.0.7(typescript@4.9.5): resolution: {integrity: sha512-2E4HIIj4tQJlIHuATRHayv0EfMGK3ris/GRk1E3CFnsZzeNV+hUmelbaTZHLtXaZppM5oLhHRtO04gINC4Jusw==} peerDependencies: typescript: '>=3.7.0' @@ -10499,7 +10529,7 @@ packages: typescript: 4.9.5 dev: true - /ts-essentials/7.0.3_typescript@4.9.5: + /ts-essentials@7.0.3(typescript@4.9.5): resolution: {integrity: sha512-8+gr5+lqO3G84KdiTSMRLtuyJ+nTBVRKuCrK4lidMPdVeEp0uqC875uE5NMcaA7YYMN7XsNiFQuMvasF8HT/xQ==} peerDependencies: typescript: '>=3.7.0' @@ -10507,7 +10537,7 @@ packages: typescript: 4.9.5 dev: true - /ts-generator/0.1.1: + /ts-generator@0.1.1: resolution: {integrity: sha512-N+ahhZxTLYu1HNTQetwWcx3so8hcYbkKBHTr4b4/YgObFTIKkOSSsaa+nal12w8mfrJAyzJfETXawbNjSfP2gQ==} hasBin: true dependencies: @@ -10522,7 +10552,7 @@ packages: ts-essentials: 1.0.4 dev: true - /ts-node/10.0.0_zlol4fzmmjgb3bdeviopae4asm: + /ts-node@10.0.0(@types/node@15.14.9)(typescript@4.9.5): resolution: {integrity: sha512-ROWeOIUvfFbPZkoDis0L/55Fk+6gFQNZwwKPLinacRl6tsxstTF1DbAcLKkovwnpKMVvOMHP1TIbnwXwtLg1gg==} engines: {node: '>=12.0.0'} hasBin: true @@ -10551,19 +10581,19 @@ packages: yn: 3.1.1 dev: true - /tslib/1.14.1: + /tslib@1.14.1: resolution: {integrity: sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg==} dev: true - /tslib/2.4.0: + /tslib@2.4.0: resolution: {integrity: sha512-d6xOpEDfsi2CZVlPQzGeux8XMwLT9hssAsaPYExaQMuYskwb+x1x7J371tWlbBdWHroy99KnVB6qIkUbs5X3UQ==} dev: true - /tsort/0.0.1: + /tsort@0.0.1: resolution: {integrity: sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw==} dev: true - /tsutils/3.21.0_typescript@4.9.5: + /tsutils@3.21.0(typescript@4.9.5): resolution: {integrity: sha512-mHKK3iUXL+3UF6xL5k0PEhKRUBKPBCv/+RkEOpjRWxxx27KKRBmmA60A9pgOUvMi8GKhRMPEmjBRPzs2W7O1OA==} engines: {node: '>= 6'} peerDependencies: @@ -10573,58 +10603,58 @@ packages: typescript: 4.9.5 dev: true - /tunnel-agent/0.6.0: + /tunnel-agent@0.6.0: resolution: {integrity: sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==} dependencies: safe-buffer: 5.2.1 dev: true - /tweetnacl-util/0.15.1: + /tweetnacl-util@0.15.1: resolution: {integrity: sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw==} dev: true - /tweetnacl/0.14.5: + /tweetnacl@0.14.5: resolution: {integrity: sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA==} dev: true - /tweetnacl/1.0.3: + /tweetnacl@1.0.3: resolution: {integrity: sha512-6rt+RN7aOi1nGMyC4Xa5DdYiukl2UWCbcJft7YhxReBGQD7OAM8Pbxw6YMo4r2diNEA8FEmu32YOn9rhaiE5yw==} dev: true - /type-check/0.3.2: + /type-check@0.3.2: resolution: {integrity: sha512-ZCmOJdvOWDBYJlzAoFkC+Q0+bUyEOS1ltgp1MGU03fqHG+dbi9tBFU2Rd9QKiDZFAYrhPh2JUf7rZRIuHRKtOg==} engines: {node: '>= 0.8.0'} dependencies: prelude-ls: 1.1.2 dev: true - /type-check/0.4.0: + /type-check@0.4.0: resolution: {integrity: sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==} engines: {node: '>= 0.8.0'} dependencies: prelude-ls: 1.2.1 dev: true - /type-detect/4.0.8: + /type-detect@4.0.8: resolution: {integrity: sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g==} engines: {node: '>=4'} - /type-fest/0.20.2: + /type-fest@0.20.2: resolution: {integrity: sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==} engines: {node: '>=10'} dev: true - /type-fest/0.21.3: + /type-fest@0.21.3: resolution: {integrity: sha512-t0rzBq87m3fVcduHDUFhKmyyX+9eo6WQjZvf51Ea/M0Q7+T374Jp1aUiyUl0GKxp8M/OETVHSDvmkyPgvX+X2w==} engines: {node: '>=10'} dev: true - /type-fest/0.7.1: + /type-fest@0.7.1: resolution: {integrity: sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg==} engines: {node: '>=8'} dev: true - /type-is/1.6.18: + /type-is@1.6.18: resolution: {integrity: sha512-TkRKr9sUTxEH8MdfuCSP7VizJyzRNMjj2J2do2Jr3Kym598JVdEksuzPQCnlFPW4ky9Q+iA+ma9BGm06XQBy8g==} engines: {node: '>= 0.6'} dependencies: @@ -10632,38 +10662,38 @@ packages: mime-types: 2.1.27 dev: true - /type/1.2.0: + /type@1.2.0: resolution: {integrity: sha512-+5nt5AAniqsCnu2cEQQdpzCAh33kVx8n0VoFidKpB1dVVLAN/F+bgVOqOJqOnEnrhp222clB5p3vUlD+1QAnfg==} dev: true - /type/2.0.0: + /type@2.0.0: resolution: {integrity: sha512-KBt58xCHry4Cejnc2ISQAF7QY+ORngsWfxezO68+12hKV6lQY8P/psIkcbjeHWn7MqcgciWJyCCevFMJdIXpow==} dev: true - /typechain/3.0.0_typescript@4.9.5: + /typechain@3.0.0(typescript@4.9.5): resolution: {integrity: sha512-ft4KVmiN3zH4JUFu2WJBrwfHeDf772Tt2d8bssDTo/YcckKW2D+OwFrHXRC6hJvO3mHjFQTihoMV6fJOi0Hngg==} hasBin: true dependencies: command-line-args: 4.0.7 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) fs-extra: 7.0.1 js-sha3: 0.8.0 lodash: 4.17.21 - ts-essentials: 6.0.7_typescript@4.9.5 + ts-essentials: 6.0.7(typescript@4.9.5) ts-generator: 0.1.1 transitivePeerDependencies: - supports-color - typescript dev: true - /typechain/8.2.0_typescript@4.9.5: + /typechain@8.2.0(typescript@4.9.5): resolution: {integrity: sha512-tZqhqjxJ9xAS/Lh32jccTjMkpx7sTdUVVHAy5Bf0TIer5QFNYXotiX74oCvoVYjyxUKDK3MXHtMFzMyD3kE+jg==} hasBin: true peerDependencies: typescript: '>=4.3.0' dependencies: '@types/prettier': 2.7.1 - debug: 4.3.4 + debug: 4.3.4(supports-color@8.1.1) fs-extra: 7.0.1 glob: 7.1.7 js-sha3: 0.8.0 @@ -10671,57 +10701,57 @@ packages: mkdirp: 1.0.4 prettier: 2.8.8 ts-command-line-args: 2.5.1 - ts-essentials: 7.0.3_typescript@4.9.5 + ts-essentials: 7.0.3(typescript@4.9.5) typescript: 4.9.5 transitivePeerDependencies: - supports-color dev: true - /typedarray-to-buffer/3.1.5: + /typedarray-to-buffer@3.1.5: resolution: {integrity: sha512-zdu8XMNEDepKKR+XYOXAVPtWui0ly0NtohUscw+UmaHiAWT8hrV1rr//H6V+0DvJ3OQ19S979M0laLfX8rm82Q==} dependencies: is-typedarray: 1.0.0 dev: true - /typedarray/0.0.6: + /typedarray@0.0.6: resolution: {integrity: sha512-/aCDEGatGvZ2BIk+HmLf4ifCJFwvKFNb9/JeZPMulfgFracn9QFcAf5GO8B/mweUjSoblS5In0cWhqpfs/5PQA==} dev: true - /typescript/4.9.5: + /typescript@4.9.5: resolution: {integrity: sha512-1FXk9E2Hm+QzZQ7z+McJiHL4NW1F2EzMu9Nq9i3zAaGqibafqYwCVU6WyWAuyQRRzOlxou8xZSyXLEN8oKj24g==} engines: {node: '>=4.2.0'} hasBin: true dev: true - /typewise-core/1.2.0: + /typewise-core@1.2.0: resolution: {integrity: sha512-2SCC/WLzj2SbUwzFOzqMCkz5amXLlxtJqDKTICqg30x+2DZxcfZN2MvQZmGfXWKNWaKK9pBPsvkcwv8bF/gxKg==} dev: true - /typewise/1.0.3: + /typewise@1.0.3: resolution: {integrity: sha512-aXofE06xGhaQSPzt8hlTY+/YWQhm9P0jYUp1f2XtmW/3Bk0qzXcyFWAtPoo2uTGQj1ZwbDuSyuxicq+aDo8lCQ==} dependencies: typewise-core: 1.2.0 dev: true - /typewiselite/1.0.0: + /typewiselite@1.0.0: resolution: {integrity: sha512-J9alhjVHupW3Wfz6qFRGgQw0N3gr8hOkw6zm7FZ6UR1Cse/oD9/JVok7DNE9TT9IbciDHX2Ex9+ksE6cRmtymw==} dev: true - /typical/2.6.1: + /typical@2.6.1: resolution: {integrity: sha512-ofhi8kjIje6npGozTip9Fr8iecmYfEbS06i0JnIg+rh51KakryWF4+jX8lLKZVhy6N+ID45WYSFCxPOdTWCzNg==} dev: true - /typical/4.0.0: + /typical@4.0.0: resolution: {integrity: sha512-VAH4IvQ7BDFYglMd7BPRDfLgxZZX4O4TFcRDA6EN5X7erNJJq+McIEp8np9aVtxrCJ6qx4GTYVfOWNjcqwZgRw==} engines: {node: '>=8'} dev: true - /typical/5.2.0: + /typical@5.2.0: resolution: {integrity: sha512-dvdQgNDNJo+8B2uBQoqdb11eUCE1JQXhvjC/CZtgvZseVd5TYMXnq0+vuUemXbd/Se29cTaUuPX3YIc2xgbvIg==} engines: {node: '>=8'} dev: true - /uglify-js/3.17.3: + /uglify-js@3.17.3: resolution: {integrity: sha512-JmMFDME3iufZnBpyKL+uS78LRiC+mK55zWfM5f/pWBJfpOttXAqYfdDGRukYhJuyRinvPVAtUhvy7rlDybNtFg==} engines: {node: '>=0.8.0'} hasBin: true @@ -10729,11 +10759,11 @@ packages: dev: true optional: true - /ultron/1.1.1: + /ultron@1.1.1: resolution: {integrity: sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og==} dev: true - /unbox-primitive/1.0.2: + /unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} dependencies: call-bind: 1.0.2 @@ -10742,24 +10772,24 @@ packages: which-boxed-primitive: 1.0.2 dev: true - /underscore/1.9.1: + /underscore@1.9.1: resolution: {integrity: sha512-5/4etnCkd9c8gwgowi5/om/mYO5ajCaOgdzj/oW+0eQV9WxKBDZw5+ycmKmeaTXjInS/W0BzpGLo2xR2aBwZdg==} dev: true optional: true - /undici/5.10.0: + /undici@5.10.0: resolution: {integrity: sha512-c8HsD3IbwmjjbLvoZuRI26TZic+TSEe8FPMLLOkN1AfYRhdjnKBU6yL+IwcSCbdZiX4e5t0lfMDLDCqj4Sq70g==} engines: {node: '>=12.18'} dev: true - /undici/5.19.1: + /undici@5.19.1: resolution: {integrity: sha512-YiZ61LPIgY73E7syxCDxxa3LV2yl3sN8spnIuTct60boiiRaE1J8mNWHO8Im2Zi/sFrPusjLlmRPrsyraSqX6A==} engines: {node: '>=12.18'} dependencies: busboy: 1.6.0 dev: true - /union-value/1.0.1: + /union-value@1.0.1: resolution: {integrity: sha512-tJfXmxMeWYnczCVs7XAEvIV7ieppALdyepWMkHkwciRpZraG/xwT+s2JN8+pr1+8jCRf80FFzvr+MpQeeoF4Xg==} engines: {node: '>=0.10.0'} dependencies: @@ -10769,27 +10799,27 @@ packages: set-value: 2.0.1 dev: true - /universalify/0.1.2: + /universalify@0.1.2: resolution: {integrity: sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg==} engines: {node: '>= 4.0.0'} dev: true - /universalify/2.0.0: + /universalify@2.0.0: resolution: {integrity: sha512-hAZsKq7Yy11Zu1DE0OzWjw7nnLZmJZYTDZZyEFHZdUhV8FkH5MCfoU1XMaxXovpyW5nq5scPqq0ZDP9Zyl04oQ==} engines: {node: '>= 10.0.0'} dev: true - /unorm/1.6.0: + /unorm@1.6.0: resolution: {integrity: sha512-b2/KCUlYZUeA7JFUuRJZPUtr4gZvBh7tavtv4fvk4+KV9pfGiR6CQAQAWl49ZpR3ts2dk4FYkP7EIgDJoiOLDA==} engines: {node: '>= 0.4.0'} dev: true - /unpipe/1.0.0: + /unpipe@1.0.0: resolution: {integrity: sha512-pjy2bYhSsufwWlKwPc+l3cN7+wuJlK6uz0YdJEOlQDbl6jo/YlPi4mb8agUkVC8BF7V8NuzeyPNqRksA3hztKQ==} engines: {node: '>= 0.8'} dev: true - /unset-value/1.0.0: + /unset-value@1.0.0: resolution: {integrity: sha512-PcA2tsuGSF9cnySLHTLSh2qrQiJ70mn+r+Glzxv2TWZblxsxCC52BDlZoPCsz7STd9pN7EZetkWZBAvk4cgZdQ==} engines: {node: '>=0.10.0'} dependencies: @@ -10797,63 +10827,63 @@ packages: isobject: 3.0.1 dev: true - /upper-case-first/1.1.2: + /upper-case-first@1.1.2: resolution: {integrity: sha512-wINKYvI3Db8dtjikdAqoBbZoP6Q+PZUyfMR7pmwHzjC2quzSkUq5DmPrTtPEqHaz8AGtmsB4TqwapMTM1QAQOQ==} dependencies: upper-case: 1.1.3 dev: true - /upper-case/1.1.3: + /upper-case@1.1.3: resolution: {integrity: sha512-WRbjgmYzgXkCV7zNVpy5YgrHgbBv126rMALQQMrmzOVC4GM2waQ9x7xtm8VU+1yF2kWyPzI9zbZ48n4vSxwfSA==} dev: true - /uri-js/4.4.1: + /uri-js@4.4.1: resolution: {integrity: sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==} dependencies: punycode: 2.1.1 dev: true - /urix/0.1.0: + /urix@0.1.0: resolution: {integrity: sha512-Am1ousAhSLBeB9cG/7k7r2R0zj50uDRlZHPGbazid5s9rlF1F/QKYObEKSIunSjIOkJZqwRRLpvewjEkM7pSqg==} deprecated: Please see https://github.com/lydell/urix#deprecated dev: true - /url-parse-lax/1.0.0: + /url-parse-lax@1.0.0: resolution: {integrity: sha512-BVA4lR5PIviy2PMseNd2jbFQ+jwSwQGdJejf5ctd1rEXt0Ypd7yanUK9+lYechVlN5VaTJGsu2U/3MDDu6KgBA==} engines: {node: '>=0.10.0'} dependencies: prepend-http: 1.0.4 dev: true - /url-parse-lax/3.0.0: + /url-parse-lax@3.0.0: resolution: {integrity: sha512-NjFKA0DidqPa5ciFcSrXnAltTtzz84ogy+NebPvfEgAck0+TNg4UJ4IN+fB7zRZfbgUf0syOo9MDxFkDSMuFaQ==} engines: {node: '>=4'} dependencies: prepend-http: 2.0.0 dev: true - /url-set-query/1.0.0: + /url-set-query@1.0.0: resolution: {integrity: sha512-3AChu4NiXquPfeckE5R5cGdiHCMWJx1dwCWOmWIL4KHAziJNOFIYJlpGFeKDvwLPHovZRCxK3cYlwzqI9Vp+Gg==} dev: true - /url-to-options/1.0.1: + /url-to-options@1.0.1: resolution: {integrity: sha512-0kQLIzG4fdk/G5NONku64rSH/x32NOA39LVQqlK8Le6lvTF6GGRJpqaQFGgU+CLwySIqBSMdwYM0sYcW9f6P4A==} engines: {node: '>= 4'} dev: true - /url/0.11.0: + /url@0.11.0: resolution: {integrity: sha512-kbailJa29QrtXnxgq+DdCEGlbTeYM2eJUxsz6vjZavrCYPMIFHMKQmSKYAIuUK2i7hgPm28a8piX5NTUtM/LKQ==} dependencies: punycode: 1.3.2 querystring: 0.2.0 dev: true - /use/3.1.1: + /use@3.1.1: resolution: {integrity: sha512-cwESVXlO3url9YWlFW/TA9cshCEhtu7IKJ/p5soJ/gGpj7vbvFrAY/eIioQ6Dw23KjZhYgiIo8HOs1nQ2vr/oQ==} engines: {node: '>=0.10.0'} dev: true - /utf-8-validate/5.0.9: + /utf-8-validate@5.0.9: resolution: {integrity: sha512-Yek7dAy0v3Kl0orwMlvi7TPtiCNrdfHNd7Gcc/pLq4BLXqfAmd0J7OWMizUQnTTJsyjKn02mU7anqwfmUP4J8Q==} engines: {node: '>=6.14.2'} requiresBuild: true @@ -10861,15 +10891,15 @@ packages: node-gyp-build: 4.5.0 dev: true - /utf8/3.0.0: + /utf8@3.0.0: resolution: {integrity: sha512-E8VjFIQ/TyQgp+TZfS6l8yp/xWppSAHzidGiRrqe4bK4XP9pTRyKFgGJpO3SN7zdX4DeomTrwaseCHovfpFcqQ==} dev: true - /util-deprecate/1.0.2: + /util-deprecate@1.0.2: resolution: {integrity: sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==} dev: true - /util.promisify/1.1.1: + /util.promisify@1.1.1: resolution: {integrity: sha512-/s3UsZUrIfa6xDhr7zZhnE9SLQ5RIXyYfiVnMMyMDzOc8WhWN4Nbh36H842OyurKbCDAesZOJaVyvmSl6fhGQw==} dependencies: call-bind: 1.0.2 @@ -10879,7 +10909,7 @@ packages: object.getownpropertydescriptors: 2.1.4 dev: true - /util/0.12.3: + /util@0.12.3: resolution: {integrity: sha512-I8XkoQwE+fPQEhy9v012V+TSdH2kp9ts29i20TaaDUXsg7x/onePbhFJUExBfv/2ay1ZOp/Vsm3nDlmnFGSAog==} dependencies: inherits: 2.0.4 @@ -10890,50 +10920,50 @@ packages: which-typed-array: 1.1.4 dev: true - /utils-merge/1.0.1: + /utils-merge@1.0.1: resolution: {integrity: sha1-n5VxD1CiZ5R7LMwSR0HBAoQn5xM=} engines: {node: '>= 0.4.0'} dev: true - /uuid/2.0.1: + /uuid@2.0.1: resolution: {integrity: sha512-nWg9+Oa3qD2CQzHIP4qKUqwNfzKn8P0LtFhotaCTFchsV7ZfDhAybeip/HZVeMIpZi9JgY1E3nUlwaCmZT1sEg==} deprecated: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. dev: true - /uuid/3.3.2: + /uuid@3.3.2: resolution: {integrity: sha512-yXJmeNaw3DnnKAOKJE51sL/ZaYfWJRl1pK9dr19YFCu0ObS231AB1/LbqTKRAQ5kw8A90rA6fr4riOUpTZvQZA==} deprecated: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. hasBin: true dev: true - /uuid/3.4.0: + /uuid@3.4.0: resolution: {integrity: sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A==} deprecated: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. hasBin: true dev: true - /uuid/8.3.2: + /uuid@8.3.2: resolution: {integrity: sha512-+NYs2QeMWy+GWFOEm9xnn6HCDp0l7QBD7ml8zLUmJ+93Q5NF0NocErnwkTkXVFNiX3/fpC6afS8Dhb/gz7R7eg==} hasBin: true dev: true - /validate-npm-package-license/3.0.4: + /validate-npm-package-license@3.0.4: resolution: {integrity: sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==} dependencies: spdx-correct: 3.1.1 spdx-expression-parse: 3.0.1 dev: true - /varint/5.0.2: + /varint@5.0.2: resolution: {integrity: sha512-lKxKYG6H03yCZUpAGOPOsMcGxd1RHCu1iKvEHYDPmTyq2HueGhD73ssNBqqQWfvYs04G9iUFRvmAVLW20Jw6ow==} dev: true - /vary/1.1.2: + /vary@1.1.2: resolution: {integrity: sha512-BNGbWLfd0eUPabhkXUVm0j8uuvREyTh5ovRa/dyow/BqAbZJyC+5fU+IzQOzmAKzYqYRAISoRhdQr3eIZ/PXqg==} engines: {node: '>= 0.8'} dev: true - /verror/1.10.0: + /verror@1.10.0: resolution: {integrity: sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw==} engines: {'0': node >=0.6.0} dependencies: @@ -10942,7 +10972,7 @@ packages: extsprintf: 1.4.0 dev: true - /web3-bzz/1.2.11: + /web3-bzz@1.2.11: resolution: {integrity: sha512-XGpWUEElGypBjeFyUhTkiPXFbDVD6Nr/S5jznE3t8cWUA0FxRf1n3n/NuIZeb0H9RkN2Ctd/jNma/k8XGa3YKg==} engines: {node: '>=8.0.0'} dependencies: @@ -10957,7 +10987,7 @@ packages: dev: true optional: true - /web3-bzz/1.7.4: + /web3-bzz@1.7.4: resolution: {integrity: sha512-w9zRhyEqTK/yi0LGRHjZMcPCfP24LBjYXI/9YxFw9VqsIZ9/G0CRCnUt12lUx0A56LRAMpF7iQ8eA73aBcO29Q==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -10971,7 +11001,7 @@ packages: - utf-8-validate dev: true - /web3-bzz/1.8.0: + /web3-bzz@1.8.0: resolution: {integrity: sha512-caDtdKeLi7+2Vb+y+cq2yyhkNjnxkFzVW0j1DtemarBg3dycG1iEl75CVQMLNO6Wkg+HH9tZtRnUyFIe5LIUeQ==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -10985,7 +11015,7 @@ packages: - utf-8-validate dev: true - /web3-core-helpers/1.2.11: + /web3-core-helpers@1.2.11: resolution: {integrity: sha512-PEPoAoZd5ME7UfbnCZBdzIerpe74GEvlwT4AjOmHeCVZoIFk7EqvOZDejJHt+feJA6kMVTdd0xzRNN295UhC1A==} engines: {node: '>=8.0.0'} dependencies: @@ -10995,7 +11025,7 @@ packages: dev: true optional: true - /web3-core-helpers/1.7.4: + /web3-core-helpers@1.7.4: resolution: {integrity: sha512-F8PH11qIkE/LpK4/h1fF/lGYgt4B6doeMi8rukeV/s4ivseZHHslv1L6aaijLX/g/j4PsFmR42byynBI/MIzFg==} engines: {node: '>=8.0.0'} dependencies: @@ -11003,7 +11033,7 @@ packages: web3-utils: 1.7.4 dev: true - /web3-core-helpers/1.8.0: + /web3-core-helpers@1.8.0: resolution: {integrity: sha512-nMAVwZB3rEp/khHI2BvFy0e/xCryf501p5NGjswmJtEM+Zrd3Biaw52JrB1qAZZIzCA8cmLKaOgdfamoDOpWdw==} engines: {node: '>=8.0.0'} dependencies: @@ -11011,7 +11041,7 @@ packages: web3-utils: 1.8.0 dev: true - /web3-core-method/1.2.11: + /web3-core-method@1.2.11: resolution: {integrity: sha512-ff0q76Cde94HAxLDZ6DbdmKniYCQVtvuaYh+rtOUMB6kssa5FX0q3vPmixi7NPooFnbKmmZCM6NvXg4IreTPIw==} engines: {node: '>=8.0.0'} dependencies: @@ -11024,7 +11054,7 @@ packages: dev: true optional: true - /web3-core-method/1.7.4: + /web3-core-method@1.7.4: resolution: {integrity: sha512-56K7pq+8lZRkxJyzf5MHQPI9/VL3IJLoy4L/+q8HRdZJ3CkB1DkXYaXGU2PeylG1GosGiSzgIfu1ljqS7CP9xQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11035,7 +11065,7 @@ packages: web3-utils: 1.7.4 dev: true - /web3-core-method/1.8.0: + /web3-core-method@1.8.0: resolution: {integrity: sha512-c94RAzo3gpXwf2rf8rL8C77jOzNWF4mXUoUfZYYsiY35cJFd46jQDPI00CB5+ZbICTiA5mlVzMj4e7jAsTqiLA==} engines: {node: '>=8.0.0'} dependencies: @@ -11046,7 +11076,7 @@ packages: web3-utils: 1.8.0 dev: true - /web3-core-promievent/1.2.11: + /web3-core-promievent@1.2.11: resolution: {integrity: sha512-il4McoDa/Ox9Agh4kyfQ8Ak/9ABYpnF8poBLL33R/EnxLsJOGQG2nZhkJa3I067hocrPSjEdlPt/0bHXsln4qA==} engines: {node: '>=8.0.0'} dependencies: @@ -11054,21 +11084,21 @@ packages: dev: true optional: true - /web3-core-promievent/1.7.4: + /web3-core-promievent@1.7.4: resolution: {integrity: sha512-o4uxwXKDldN7ER7VUvDfWsqTx9nQSP1aDssi1XYXeYC2xJbVo0n+z6ryKtmcoWoRdRj7uSpVzal3nEmlr480mA==} engines: {node: '>=8.0.0'} dependencies: eventemitter3: 4.0.4 dev: true - /web3-core-promievent/1.8.0: + /web3-core-promievent@1.8.0: resolution: {integrity: sha512-FGLyjAuOaAQ+ZhV6iuw9tg/9WvIkSZXKHQ4mdTyQ8MxVraOtFivOCbuLLsGgapfHYX+RPxsc1j1YzQjKoupagQ==} engines: {node: '>=8.0.0'} dependencies: eventemitter3: 4.0.4 dev: true - /web3-core-requestmanager/1.2.11: + /web3-core-requestmanager@1.2.11: resolution: {integrity: sha512-oFhBtLfOiIbmfl6T6gYjjj9igOvtyxJ+fjS+byRxiwFJyJ5BQOz4/9/17gWR1Cq74paTlI7vDGxYfuvfE/mKvA==} engines: {node: '>=8.0.0'} dependencies: @@ -11082,7 +11112,7 @@ packages: dev: true optional: true - /web3-core-requestmanager/1.7.4: + /web3-core-requestmanager@1.7.4: resolution: {integrity: sha512-IuXdAm65BQtPL4aI6LZJJOrKAs0SM5IK2Cqo2/lMNvVMT9Kssq6qOk68Uf7EBDH0rPuINi+ReLP+uH+0g3AnPA==} engines: {node: '>=8.0.0'} dependencies: @@ -11095,7 +11125,7 @@ packages: - supports-color dev: true - /web3-core-requestmanager/1.8.0: + /web3-core-requestmanager@1.8.0: resolution: {integrity: sha512-2AoYCs3Owl5foWcf4uKPONyqFygSl9T54L8b581U16nsUirjhoTUGK/PBhMDVcLCmW4QQmcY5A8oPFpkQc1TTg==} engines: {node: '>=8.0.0'} dependencies: @@ -11109,7 +11139,7 @@ packages: - supports-color dev: true - /web3-core-subscriptions/1.2.11: + /web3-core-subscriptions@1.2.11: resolution: {integrity: sha512-qEF/OVqkCvQ7MPs1JylIZCZkin0aKK9lDxpAtQ1F8niEDGFqn7DT8E/vzbIa0GsOjL2fZjDhWJsaW+BSoAW1gg==} engines: {node: '>=8.0.0'} dependencies: @@ -11119,7 +11149,7 @@ packages: dev: true optional: true - /web3-core-subscriptions/1.7.4: + /web3-core-subscriptions@1.7.4: resolution: {integrity: sha512-VJvKWaXRyxk2nFWumOR94ut9xvjzMrRtS38c4qj8WBIRSsugrZr5lqUwgndtj0qx4F+50JhnU++QEqUEAtKm3g==} engines: {node: '>=8.0.0'} dependencies: @@ -11127,7 +11157,7 @@ packages: web3-core-helpers: 1.7.4 dev: true - /web3-core-subscriptions/1.8.0: + /web3-core-subscriptions@1.8.0: resolution: {integrity: sha512-7lHVRzDdg0+Gcog55lG6Q3D8JV+jN+4Ly6F8cSn9xFUAwOkdbgdWsjknQG7t7CDWy21DQkvdiY2BJF8S68AqOA==} engines: {node: '>=8.0.0'} dependencies: @@ -11135,7 +11165,7 @@ packages: web3-core-helpers: 1.8.0 dev: true - /web3-core/1.2.11: + /web3-core@1.2.11: resolution: {integrity: sha512-CN7MEYOY5ryo5iVleIWRE3a3cZqVaLlIbIzDPsvQRUfzYnvzZQRZBm9Mq+ttDi2STOOzc1MKylspz/o3yq/LjQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11151,7 +11181,7 @@ packages: dev: true optional: true - /web3-core/1.7.4: + /web3-core@1.7.4: resolution: {integrity: sha512-L0DCPlIh9bgIED37tYbe7bsWrddoXYc897ANGvTJ6MFkSNGiMwDkTLWSgYd9Mf8qu8b4iuPqXZHMwIo4atoh7Q==} engines: {node: '>=8.0.0'} dependencies: @@ -11166,7 +11196,7 @@ packages: - supports-color dev: true - /web3-core/1.8.0: + /web3-core@1.8.0: resolution: {integrity: sha512-9sCA+Z02ci6zoY2bAquFiDjujRwmSKHiSGi4B8IstML8okSytnzXk1izHYSynE7ahIkguhjWAuXFvX76F5rAbA==} engines: {node: '>=8.0.0'} dependencies: @@ -11182,7 +11212,7 @@ packages: - supports-color dev: true - /web3-eth-abi/1.2.11: + /web3-eth-abi@1.2.11: resolution: {integrity: sha512-PkRYc0+MjuLSgg03QVWqWlQivJqRwKItKtEpRUaxUAeLE7i/uU39gmzm2keHGcQXo3POXAbOnMqkDvOep89Crg==} engines: {node: '>=8.0.0'} dependencies: @@ -11192,7 +11222,7 @@ packages: dev: true optional: true - /web3-eth-abi/1.7.4: + /web3-eth-abi@1.7.4: resolution: {integrity: sha512-eMZr8zgTbqyL9MCTCAvb67RbVyN5ZX7DvA0jbLOqRWCiw+KlJKTGnymKO6jPE8n5yjk4w01e165Qb11hTDwHgg==} engines: {node: '>=8.0.0'} dependencies: @@ -11200,7 +11230,7 @@ packages: web3-utils: 1.7.4 dev: true - /web3-eth-abi/1.8.0: + /web3-eth-abi@1.8.0: resolution: {integrity: sha512-xPeMb2hS9YLQK/Q5YZpkcmzoRGM+/R8bogSrYHhNC3hjZSSU0YRH+1ZKK0f9YF4qDZaPMI8tKWIMSCDIpjG6fg==} engines: {node: '>=8.0.0'} dependencies: @@ -11208,7 +11238,7 @@ packages: web3-utils: 1.8.0 dev: true - /web3-eth-accounts/1.2.11: + /web3-eth-accounts@1.2.11: resolution: {integrity: sha512-6FwPqEpCfKIh3nSSGeo3uBm2iFSnFJDfwL3oS9pyegRBXNsGRVpgiW63yhNzL0796StsvjHWwQnQHsZNxWAkGw==} engines: {node: '>=8.0.0'} dependencies: @@ -11228,7 +11258,7 @@ packages: dev: true optional: true - /web3-eth-accounts/1.7.4: + /web3-eth-accounts@1.7.4: resolution: {integrity: sha512-Y9vYLRKP7VU7Cgq6wG1jFaG2k3/eIuiTKAG8RAuQnb6Cd9k5BRqTm5uPIiSo0AP/u11jDomZ8j7+WEgkU9+Btw==} engines: {node: '>=8.0.0'} dependencies: @@ -11247,7 +11277,7 @@ packages: - supports-color dev: true - /web3-eth-accounts/1.8.0: + /web3-eth-accounts@1.8.0: resolution: {integrity: sha512-HQ/MDSv4bexwJLvnqsM6xpGE7c2NVOqyhzOZFyMUKXbIwIq85T3TaLnM9pCN7XqMpDcfxqiZ3q43JqQVkzHdmw==} engines: {node: '>=8.0.0'} dependencies: @@ -11267,7 +11297,7 @@ packages: - supports-color dev: true - /web3-eth-contract/1.2.11: + /web3-eth-contract@1.2.11: resolution: {integrity: sha512-MzYuI/Rq2o6gn7vCGcnQgco63isPNK5lMAan2E51AJLknjSLnOxwNY3gM8BcKoy4Z+v5Dv00a03Xuk78JowFow==} engines: {node: '>=8.0.0'} dependencies: @@ -11285,7 +11315,7 @@ packages: dev: true optional: true - /web3-eth-contract/1.7.4: + /web3-eth-contract@1.7.4: resolution: {integrity: sha512-ZgSZMDVI1pE9uMQpK0T0HDT2oewHcfTCv0osEqf5qyn5KrcQDg1GT96/+S0dfqZ4HKj4lzS5O0rFyQiLPQ8LzQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11301,7 +11331,7 @@ packages: - supports-color dev: true - /web3-eth-contract/1.8.0: + /web3-eth-contract@1.8.0: resolution: {integrity: sha512-6xeXhW2YoCrz2Ayf2Vm4srWiMOB6LawkvxWJDnUWJ8SMATg4Pgu42C/j8rz/enXbYWt2IKuj0kk8+QszxQbK+Q==} engines: {node: '>=8.0.0'} dependencies: @@ -11318,7 +11348,7 @@ packages: - supports-color dev: true - /web3-eth-ens/1.2.11: + /web3-eth-ens@1.2.11: resolution: {integrity: sha512-dbW7dXP6HqT1EAPvnniZVnmw6TmQEKF6/1KgAxbo8iBBYrVTMDGFQUUnZ+C4VETGrwwaqtX4L9d/FrQhZ6SUiA==} engines: {node: '>=8.0.0'} dependencies: @@ -11336,7 +11366,7 @@ packages: dev: true optional: true - /web3-eth-ens/1.7.4: + /web3-eth-ens@1.7.4: resolution: {integrity: sha512-Gw5CVU1+bFXP5RVXTCqJOmHn71X2ghNk9VcEH+9PchLr0PrKbHTA3hySpsPco1WJAyK4t8SNQVlNr3+bJ6/WZA==} engines: {node: '>=8.0.0'} dependencies: @@ -11352,7 +11382,7 @@ packages: - supports-color dev: true - /web3-eth-ens/1.8.0: + /web3-eth-ens@1.8.0: resolution: {integrity: sha512-/eFbQEwvsMOEiOhw9/iuRXCsPkqAmHHWuFOrThQkozRgcnSTRnvxkkRC/b6koiT5/HaKeUs4yQDg+/ixsIxZxA==} engines: {node: '>=8.0.0'} dependencies: @@ -11369,7 +11399,7 @@ packages: - supports-color dev: true - /web3-eth-iban/1.2.11: + /web3-eth-iban@1.2.11: resolution: {integrity: sha512-ozuVlZ5jwFC2hJY4+fH9pIcuH1xP0HEFhtWsR69u9uDIANHLPQQtWYmdj7xQ3p2YT4bQLq/axKhZi7EZVetmxQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11378,7 +11408,7 @@ packages: dev: true optional: true - /web3-eth-iban/1.7.4: + /web3-eth-iban@1.7.4: resolution: {integrity: sha512-XyrsgWlZQMv5gRcjXMsNvAoCRvV5wN7YCfFV5+tHUCqN8g9T/o4XUS20vDWD0k4HNiAcWGFqT1nrls02MGZ08w==} engines: {node: '>=8.0.0'} dependencies: @@ -11386,7 +11416,7 @@ packages: web3-utils: 1.7.4 dev: true - /web3-eth-iban/1.8.0: + /web3-eth-iban@1.8.0: resolution: {integrity: sha512-4RbvUxcMpo/e5811sE3a6inJ2H4+FFqUVmlRYs0RaXaxiHweahSRBNcpO0UWgmlePTolj0rXqPT2oEr0DuC8kg==} engines: {node: '>=8.0.0'} dependencies: @@ -11394,7 +11424,7 @@ packages: web3-utils: 1.8.0 dev: true - /web3-eth-personal/1.2.11: + /web3-eth-personal@1.2.11: resolution: {integrity: sha512-42IzUtKq9iHZ8K9VN0vAI50iSU9tOA1V7XU2BhF/tb7We2iKBVdkley2fg26TxlOcKNEHm7o6HRtiiFsVK4Ifw==} engines: {node: '>=8.0.0'} dependencies: @@ -11409,7 +11439,7 @@ packages: dev: true optional: true - /web3-eth-personal/1.7.4: + /web3-eth-personal@1.7.4: resolution: {integrity: sha512-O10C1Hln5wvLQsDhlhmV58RhXo+GPZ5+W76frSsyIrkJWLtYQTCr5WxHtRC9sMD1idXLqODKKgI2DL+7xeZ0/g==} engines: {node: '>=8.0.0'} dependencies: @@ -11423,7 +11453,7 @@ packages: - supports-color dev: true - /web3-eth-personal/1.8.0: + /web3-eth-personal@1.8.0: resolution: {integrity: sha512-L7FT4nR3HmsfZyIAhFpEctKkYGOjRC2h6iFKs9gnFCHZga8yLcYcGaYOBIoYtaKom99MuGBoosayWt/Twh7F5A==} engines: {node: '>=8.0.0'} dependencies: @@ -11438,7 +11468,7 @@ packages: - supports-color dev: true - /web3-eth/1.2.11: + /web3-eth@1.2.11: resolution: {integrity: sha512-REvxW1wJ58AgHPcXPJOL49d1K/dPmuw4LjPLBPStOVkQjzDTVmJEIsiLwn2YeuNDd4pfakBwT8L3bz1G1/wVsQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11460,7 +11490,7 @@ packages: dev: true optional: true - /web3-eth/1.7.4: + /web3-eth@1.7.4: resolution: {integrity: sha512-JG0tTMv0Ijj039emXNHi07jLb0OiWSA9O24MRSk5vToTQyDNXihdF2oyq85LfHuF690lXZaAXrjhtLNlYqb7Ug==} engines: {node: '>=8.0.0'} dependencies: @@ -11480,7 +11510,7 @@ packages: - supports-color dev: true - /web3-eth/1.8.0: + /web3-eth@1.8.0: resolution: {integrity: sha512-hist52os3OT4TQFB/GxPSMxTh3995sz6LPvQpPvj7ktSbpg9RNSFaSsPlCT63wUAHA3PZb1FemkAIeQM5t72Lw==} engines: {node: '>=8.0.0'} dependencies: @@ -11501,7 +11531,7 @@ packages: - supports-color dev: true - /web3-net/1.2.11: + /web3-net@1.2.11: resolution: {integrity: sha512-sjrSDj0pTfZouR5BSTItCuZ5K/oZPVdVciPQ6981PPPIwJJkCMeVjD7I4zO3qDPCnBjBSbWvVnLdwqUBPtHxyg==} engines: {node: '>=8.0.0'} dependencies: @@ -11513,7 +11543,7 @@ packages: dev: true optional: true - /web3-net/1.7.4: + /web3-net@1.7.4: resolution: {integrity: sha512-d2Gj+DIARHvwIdmxFQ4PwAAXZVxYCR2lET0cxz4KXbE5Og3DNjJi+MoPkX+WqoUXqimu/EOd4Cd+7gefqVAFDg==} engines: {node: '>=8.0.0'} dependencies: @@ -11524,7 +11554,7 @@ packages: - supports-color dev: true - /web3-net/1.8.0: + /web3-net@1.8.0: resolution: {integrity: sha512-kX6EAacK7QrOe7DOh0t5yHS5q2kxZmTCxPVwSz9io9xBeE4n4UhmzGJ/VfhP2eM3OPKYeypcR3LEO6zZ8xn2vw==} engines: {node: '>=8.0.0'} dependencies: @@ -11536,7 +11566,7 @@ packages: - supports-color dev: true - /web3-provider-engine/14.2.1: + /web3-provider-engine@14.2.1: resolution: {integrity: sha512-iSv31h2qXkr9vrL6UZDm4leZMc32SjWJFGOp/D92JXfcEboCqraZyuExDkpxKw8ziTufXieNM7LSXNHzszYdJw==} dependencies: async: 2.6.3 @@ -11566,7 +11596,7 @@ packages: - utf-8-validate dev: true - /web3-providers-http/1.2.11: + /web3-providers-http@1.2.11: resolution: {integrity: sha512-psh4hYGb1+ijWywfwpB2cvvOIMISlR44F/rJtYkRmQ5jMvG4FOCPlQJPiHQZo+2cc3HbktvvSJzIhkWQJdmvrA==} engines: {node: '>=8.0.0'} dependencies: @@ -11575,7 +11605,7 @@ packages: dev: true optional: true - /web3-providers-http/1.7.4: + /web3-providers-http@1.7.4: resolution: {integrity: sha512-AU+/S+49rcogUER99TlhW+UBMk0N2DxvN54CJ2pK7alc2TQ7+cprNPLHJu4KREe8ndV0fT6JtWUfOMyTvl+FRA==} engines: {node: '>=8.0.0'} dependencies: @@ -11583,7 +11613,7 @@ packages: xhr2-cookies: 1.1.0 dev: true - /web3-providers-http/1.8.0: + /web3-providers-http@1.8.0: resolution: {integrity: sha512-/MqxwRzExohBWW97mqlCSW/+NHydGRyoEDUS1bAIF2YjfKFwyRtHgrEzOojzkC9JvB+8LofMvbXk9CcltpZapw==} engines: {node: '>=8.0.0'} dependencies: @@ -11595,7 +11625,7 @@ packages: - encoding dev: true - /web3-providers-ipc/1.2.11: + /web3-providers-ipc@1.2.11: resolution: {integrity: sha512-yhc7Y/k8hBV/KlELxynWjJDzmgDEDjIjBzXK+e0rHBsYEhdCNdIH5Psa456c+l0qTEU2YzycF8VAjYpWfPnBpQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11605,7 +11635,7 @@ packages: dev: true optional: true - /web3-providers-ipc/1.7.4: + /web3-providers-ipc@1.7.4: resolution: {integrity: sha512-jhArOZ235dZy8fS8090t60nTxbd1ap92ibQw5xIrAQ9m7LcZKNfmLAQUVsD+3dTFvadRMi6z1vCO7zRi84gWHw==} engines: {node: '>=8.0.0'} dependencies: @@ -11613,7 +11643,7 @@ packages: web3-core-helpers: 1.7.4 dev: true - /web3-providers-ipc/1.8.0: + /web3-providers-ipc@1.8.0: resolution: {integrity: sha512-tAXHtVXNUOgehaBU8pzAlB3qhjn/PRpjdzEjzHNFqtRRTwzSEKOJxFeEhaUA4FzHnTlbnrs8ujHWUitcp1elfg==} engines: {node: '>=8.0.0'} dependencies: @@ -11621,7 +11651,7 @@ packages: web3-core-helpers: 1.8.0 dev: true - /web3-providers-ws/1.2.11: + /web3-providers-ws@1.2.11: resolution: {integrity: sha512-ZxnjIY1Er8Ty+cE4migzr43zA/+72AF1myzsLaU5eVgdsfV7Jqx7Dix1hbevNZDKFlSoEyq/3j/jYalh3So1Zg==} engines: {node: '>=8.0.0'} dependencies: @@ -11634,7 +11664,7 @@ packages: dev: true optional: true - /web3-providers-ws/1.7.4: + /web3-providers-ws@1.7.4: resolution: {integrity: sha512-g72X77nrcHMFU8hRzQJzfgi/072n8dHwRCoTw+WQrGp+XCQ71fsk2qIu3Tp+nlp5BPn8bRudQbPblVm2uT4myQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11645,7 +11675,7 @@ packages: - supports-color dev: true - /web3-providers-ws/1.8.0: + /web3-providers-ws@1.8.0: resolution: {integrity: sha512-bcZtSifsqyJxwkfQYamfdIRp4nhj9eJd7cxHg1uUkfLJK125WP96wyJL1xbPt7qt0MpfnTFn8/UuIqIB6nFENg==} engines: {node: '>=8.0.0'} dependencies: @@ -11656,7 +11686,7 @@ packages: - supports-color dev: true - /web3-shh/1.2.11: + /web3-shh@1.2.11: resolution: {integrity: sha512-B3OrO3oG1L+bv3E1sTwCx66injW1A8hhwpknDUbV+sw3fehFazA06z9SGXUefuFI1kVs4q2vRi0n4oCcI4dZDg==} engines: {node: '>=8.0.0'} dependencies: @@ -11669,7 +11699,7 @@ packages: dev: true optional: true - /web3-shh/1.7.4: + /web3-shh@1.7.4: resolution: {integrity: sha512-mlSZxSYcMkuMCxqhTYnZkUdahZ11h+bBv/8TlkXp/IHpEe4/Gg+KAbmfudakq3EzG/04z70XQmPgWcUPrsEJ+A==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -11682,7 +11712,7 @@ packages: - supports-color dev: true - /web3-shh/1.8.0: + /web3-shh@1.8.0: resolution: {integrity: sha512-DNRgSa9Jf9xYFUGKSMylrf+zt3MPjhI2qF+UWX07o0y3+uf8zalDGiJOWvIS4upAsdPiKKVJ7co+Neof47OMmg==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -11696,7 +11726,7 @@ packages: - supports-color dev: true - /web3-utils/1.2.11: + /web3-utils@1.2.11: resolution: {integrity: sha512-3Tq09izhD+ThqHEaWYX4VOT7dNPdZiO+c/1QMA0s5X2lDFKK/xHJb7cyTRRVzN2LvlHbR7baS1tmQhSua51TcQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11711,7 +11741,7 @@ packages: dev: true optional: true - /web3-utils/1.7.4: + /web3-utils@1.7.4: resolution: {integrity: sha512-acBdm6Evd0TEZRnChM/MCvGsMwYKmSh7OaUfNf5OKG0CIeGWD/6gqLOWIwmwSnre/2WrA1nKGId5uW2e5EfluA==} engines: {node: '>=8.0.0'} dependencies: @@ -11724,7 +11754,7 @@ packages: utf8: 3.0.0 dev: true - /web3-utils/1.8.0: + /web3-utils@1.8.0: resolution: {integrity: sha512-7nUIl7UWpLVka2f09CMbKOSEvorvHnaugIabU4mj7zfMvm0tSByLcEu3eyV9qgS11qxxLuOkzBIwCstTflhmpQ==} engines: {node: '>=8.0.0'} dependencies: @@ -11737,7 +11767,7 @@ packages: utf8: 3.0.0 dev: true - /web3/1.2.11: + /web3@1.2.11: resolution: {integrity: sha512-mjQ8HeU41G6hgOYm1pmeH0mRAeNKJGnJEUzDMoerkpw7QUQT4exVREgF1MYPvL/z6vAshOXei25LE/t/Bxl8yQ==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -11756,7 +11786,7 @@ packages: dev: true optional: true - /web3/1.7.4: + /web3@1.7.4: resolution: {integrity: sha512-iFGK5jO32vnXM/ASaJBaI0+gVR6uHozvYdxkdhaeOCD6HIQ4iIXadbO2atVpE9oc/H8l2MovJ4LtPhG7lIBN8A==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -11774,7 +11804,7 @@ packages: - utf-8-validate dev: true - /web3/1.8.0: + /web3@1.8.0: resolution: {integrity: sha512-sldr9stK/SALSJTgI/8qpnDuBJNMGjVR84hJ+AcdQ+MLBGLMGsCDNubCoyO6qgk1/Y9SQ7ignegOI/7BPLoiDA==} engines: {node: '>=8.0.0'} requiresBuild: true @@ -11793,11 +11823,11 @@ packages: - utf-8-validate dev: true - /webidl-conversions/3.0.1: + /webidl-conversions@3.0.1: resolution: {integrity: sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ==} dev: true - /websocket/1.0.32: + /websocket@1.0.32: resolution: {integrity: sha512-i4yhcllSP4wrpoPMU2N0TQ/q0O94LRG/eUQjEAamRltjQ1oT1PFFKOG4i877OlJgCG8rw6LrrowJp+TYCEWF7Q==} engines: {node: '>=4.0.0'} dependencies: @@ -11811,7 +11841,7 @@ packages: - supports-color dev: true - /websocket/1.0.34: + /websocket@1.0.34: resolution: {integrity: sha512-PRDso2sGwF6kM75QykIesBijKSVceR6jL2G8NGYyq2XrItNC2P5/qL5XeR056GhA+Ly7JMFvJb9I312mJfmqnQ==} engines: {node: '>=4.0.0'} dependencies: @@ -11825,18 +11855,18 @@ packages: - supports-color dev: true - /whatwg-fetch/2.0.4: + /whatwg-fetch@2.0.4: resolution: {integrity: sha512-dcQ1GWpOD/eEQ97k66aiEVpNnapVj90/+R+SXTPYGHpYBBypfKJEQjLrvMZ7YXbKm21gXd4NcuxUTjiv1YtLng==} dev: true - /whatwg-url/5.0.0: + /whatwg-url@5.0.0: resolution: {integrity: sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw==} dependencies: tr46: 0.0.3 webidl-conversions: 3.0.1 dev: true - /which-boxed-primitive/1.0.2: + /which-boxed-primitive@1.0.2: resolution: {integrity: sha512-bwZdv0AKLpplFY2KZRX6TvyuN7ojjr7lwkg6ml0roIy9YeuSr7JS372qlNW18UQYzgYK9ziGcerWqZOmEn9VNg==} dependencies: is-bigint: 1.0.4 @@ -11846,15 +11876,15 @@ packages: is-symbol: 1.0.3 dev: true - /which-module/1.0.0: + /which-module@1.0.0: resolution: {integrity: sha512-F6+WgncZi/mJDrammbTuHe1q0R5hOXv/mBaiNA2TCNT/LTHusX0V+CJnj9XT8ki5ln2UZyyddDgHfCzyrOH7MQ==} dev: true - /which-module/2.0.0: + /which-module@2.0.0: resolution: {integrity: sha512-B+enWhmw6cjfVC7kS8Pj9pCrKSc5txArRyaYGe088shv/FGWH+0Rjx/xPgtsWfsUtS27FkP697E4DDhgrgoc0Q==} dev: true - /which-typed-array/1.1.4: + /which-typed-array@1.1.4: resolution: {integrity: sha512-49E0SpUe90cjpoc7BOJwyPHRqSAd12c10Qm2amdEZrJPCY2NDxaW01zHITrem+rnETY3dwrbH3UUrUwagfCYDA==} engines: {node: '>= 0.4'} dependencies: @@ -11867,14 +11897,14 @@ packages: is-typed-array: 1.1.5 dev: true - /which/1.3.1: + /which@1.3.1: resolution: {integrity: sha512-HxJdYWq1MTIQbJ3nw0cqssHoTNU267KlrDuGZ1WYlxDStUtKUhOaJmh112/TZmHxxUfuJqPXSOm7tDyas0OSIQ==} hasBin: true dependencies: isexe: 2.0.0 dev: true - /which/2.0.2: + /which@2.0.2: resolution: {integrity: sha512-BLI3Tl1TW3Pvl70l3yq3Y64i+awpwXqsGBYWkkqMtnbXgrMD+yj7rhW0kuEDxzJaYXGjEW5ogapKNMEKNMjibA==} engines: {node: '>= 8'} hasBin: true @@ -11882,28 +11912,28 @@ packages: isexe: 2.0.0 dev: true - /wide-align/1.1.3: + /wide-align@1.1.3: resolution: {integrity: sha512-QGkOQc8XL6Bt5PwnsExKBPuMKBxnGxWWW3fU55Xt4feHozMUhdUMaBCk290qpm/wG5u/RSKzwdAC4i51YigihA==} dependencies: string-width: 2.1.1 dev: true - /window-size/0.2.0: + /window-size@0.2.0: resolution: {integrity: sha512-UD7d8HFA2+PZsbKyaOCEy8gMh1oDtHgJh1LfgjQ4zVXmYjAT/kvz3PueITKuqDiIXQe7yzpPnxX3lNc+AhQMyw==} engines: {node: '>= 0.10.0'} hasBin: true dev: true - /word-wrap/1.2.3: + /word-wrap@1.2.3: resolution: {integrity: sha512-Hz/mrNwitNRh/HUAtM/VT/5VH+ygD6DV7mYKZAtHOrbs8U7lvPS6xf7EJKMF0uW1KJCl0H701g3ZGus+muE5vQ==} engines: {node: '>=0.10.0'} dev: true - /wordwrap/1.0.0: + /wordwrap@1.0.0: resolution: {integrity: sha512-gvVzJFlPycKc5dZN4yPkP8w7Dc37BtP1yczEneOb4uq34pXZcvrtRTmWV8W+Ume+XCxKgbjM+nevkyFPMybd4Q==} dev: true - /wordwrapjs/4.0.1: + /wordwrapjs@4.0.1: resolution: {integrity: sha512-kKlNACbvHrkpIw6oPeYDSmdCTu2hdMHoyXLTcUKala++lx5Y+wjJ/e474Jqv5abnVmwxw08DiTuHmw69lJGksA==} engines: {node: '>=8.0.0'} dependencies: @@ -11911,11 +11941,11 @@ packages: typical: 5.2.0 dev: true - /workerpool/6.2.1: + /workerpool@6.2.1: resolution: {integrity: sha512-ILEIE97kDZvF9Wb9f6h5aXK4swSlKGUcOEGiIYb2OOu/IrDU9iwj0fD//SsA6E5ibwJxpEvhullJY4Sl4GcpAw==} dev: true - /wrap-ansi/2.1.0: + /wrap-ansi@2.1.0: resolution: {integrity: sha512-vAaEaDM946gbNpH5pLVNR+vX2ht6n0Bt3GXwVB1AuAqZosOvHNF3P7wDnh8KLkSqgUh0uh77le7Owgoz+Z9XBw==} engines: {node: '>=0.10.0'} dependencies: @@ -11923,7 +11953,7 @@ packages: strip-ansi: 3.0.1 dev: true - /wrap-ansi/5.1.0: + /wrap-ansi@5.1.0: resolution: {integrity: sha512-QC1/iN/2/RPVJ5jYK8BGttj5z83LmSKmvbvrXPNCLZSEb32KKVDJDl/MOt2N01qU2H/FkzEa9PKto1BqDjtd7Q==} engines: {node: '>=6'} dependencies: @@ -11932,7 +11962,7 @@ packages: strip-ansi: 5.2.0 dev: true - /wrap-ansi/7.0.0: + /wrap-ansi@7.0.0: resolution: {integrity: sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==} engines: {node: '>=10'} dependencies: @@ -11941,11 +11971,11 @@ packages: strip-ansi: 6.0.1 dev: true - /wrappy/1.0.2: + /wrappy@1.0.2: resolution: {integrity: sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==} dev: true - /ws/3.3.3: + /ws@3.3.3: resolution: {integrity: sha512-nnWLa/NwZSt4KQJu51MYlCcSQ5g7INpOrOMt4XV8j4dqTXdmlUmSHQ8/oLC069ckre0fRsgfvsKwbTdtKLCDkA==} peerDependencies: bufferutil: ^4.0.1 @@ -11961,7 +11991,7 @@ packages: ultron: 1.1.1 dev: true - /ws/5.2.3: + /ws@5.2.3: resolution: {integrity: sha512-jZArVERrMsKUatIdnLzqvcfydI85dvd/Fp1u/VOpfdDWQ4c9qWXe+VIeAbQ5FrDwciAkr+lzofXLz3Kuf26AOA==} peerDependencies: bufferutil: ^4.0.1 @@ -11975,7 +12005,7 @@ packages: async-limiter: 1.0.1 dev: true - /ws/7.4.6: + /ws@7.4.6: resolution: {integrity: sha512-YmhHDO4MzaDLB+M9ym/mDA5z0naX8j7SIlT8f8z+I0VtzsRbekxEutHSme7NPS2qE8StCYQNUnfWdXta/Yu85A==} engines: {node: '>=8.3.0'} peerDependencies: @@ -11987,7 +12017,7 @@ packages: utf-8-validate: optional: true - /ws/7.5.9: + /ws@7.5.9: resolution: {integrity: sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q==} engines: {node: '>=8.3.0'} peerDependencies: @@ -12000,13 +12030,13 @@ packages: optional: true dev: true - /xhr-request-promise/0.1.2: + /xhr-request-promise@0.1.2: resolution: {integrity: sha512-yAQlCCNLwPgoGxw4k+IdRp1uZ7MZibS4kFw2boSUOesjnmvcxxj73j5a8KavE5Bzas++8P49OpJ4m8qjWGiDsA==} dependencies: xhr-request: 1.1.0 dev: true - /xhr-request/1.1.0: + /xhr-request@1.1.0: resolution: {integrity: sha512-Y7qzEaR3FDtL3fP30k9wO/e+FBnBByZeybKOhASsGP30NIkRAAkKD/sCnLvgEfAIEC1rcmK7YG8f4oEnIrrWzA==} dependencies: buffer-to-arraybuffer: 0.0.5 @@ -12018,7 +12048,13 @@ packages: xhr: 2.5.0 dev: true - /xhr/2.5.0: + /xhr2-cookies@1.1.0: + resolution: {integrity: sha512-hjXUA6q+jl/bd8ADHcVfFsSPIf+tyLIjuO9TwJC9WI6JP2zKcS7C+p56I9kCLLsaCiNT035iYvEUUzdEFj/8+g==} + dependencies: + cookiejar: 2.1.2 + dev: true + + /xhr@2.5.0: resolution: {integrity: sha512-4nlO/14t3BNUZRXIXfXe+3N6w3s1KoxcJUUURctd64BLRe67E4gRwp4PjywtDY72fXpZ1y6Ch0VZQRY/gMPzzQ==} dependencies: global: 4.3.2 @@ -12027,75 +12063,69 @@ packages: xtend: 4.0.2 dev: true - /xhr2-cookies/1.1.0: - resolution: {integrity: sha512-hjXUA6q+jl/bd8ADHcVfFsSPIf+tyLIjuO9TwJC9WI6JP2zKcS7C+p56I9kCLLsaCiNT035iYvEUUzdEFj/8+g==} - dependencies: - cookiejar: 2.1.2 - dev: true - - /xmlhttprequest/1.8.0: + /xmlhttprequest@1.8.0: resolution: {integrity: sha512-58Im/U0mlVBLM38NdZjHyhuMtCqa61469k2YP/AaPbvCoV9aQGUpbJBj1QRm2ytRiVQBD/fsw7L2bJGDVQswBA==} engines: {node: '>=0.4.0'} dev: true - /xtend/2.1.2: + /xtend@2.1.2: resolution: {integrity: sha512-vMNKzr2rHP9Dp/e1NQFnLQlwlhp9L/LfvnsVdHxN1f+uggyVI3i08uD14GPvCToPkdsRfyPqIyYGmIk58V98ZQ==} engines: {node: '>=0.4'} dependencies: object-keys: 0.4.0 dev: true - /xtend/4.0.2: + /xtend@4.0.2: resolution: {integrity: sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ==} engines: {node: '>=0.4'} dev: true - /y18n/3.2.2: + /y18n@3.2.2: resolution: {integrity: sha512-uGZHXkHnhF0XeeAPgnKfPv1bgKAYyVvmNL1xlKsPYZPaIHxGti2hHqvOCQv71XMsLxu1QjergkqogUnms5D3YQ==} dev: true - /y18n/4.0.3: + /y18n@4.0.3: resolution: {integrity: sha512-JKhqTOwSrqNA1NY5lSztJ1GrBiUodLMmIZuLiDaMRJ+itFd+ABVE8XBjOvIWL+rSqNDC74LCSFmlb/U4UZ4hJQ==} dev: true - /y18n/5.0.8: + /y18n@5.0.8: resolution: {integrity: sha512-0pfFzegeDWJHJIAmTLRP2DwHjdF5s7jo9tuztdQxAhINCdvS+3nGINqPd00AphqJR/0LhANUS6/+7SCb98YOfA==} engines: {node: '>=10'} dev: true - /yaeti/0.0.6: + /yaeti@0.0.6: resolution: {integrity: sha512-MvQa//+KcZCUkBTIC9blM+CU9J2GzuTytsOUwf2lidtvkx/6gnEp1QvJv34t9vdjhFmha/mUiNDbN0D0mJWdug==} engines: {node: '>=0.10.32'} dev: true - /yallist/3.1.1: + /yallist@3.1.1: resolution: {integrity: sha512-a4UGQaWPH59mOXUYnAG2ewncQS4i4F43Tv3JoAM+s2VDAmS9NsK8GpDMLrCHPksFT7h3K6TOoUNn2pb7RoXx4g==} dev: true - /yallist/4.0.0: + /yallist@4.0.0: resolution: {integrity: sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==} dev: true - /yargs-parser/13.1.2: + /yargs-parser@13.1.2: resolution: {integrity: sha512-3lbsNRf/j+A4QuSZfDRA7HRSfWrzO0YjqTJd5kjAq37Zep1CEgaYmrH9Q3GwPiB9cHyd1Y1UwggGhJGoxipbzg==} dependencies: camelcase: 5.3.1 decamelize: 1.2.0 dev: true - /yargs-parser/2.4.1: + /yargs-parser@2.4.1: resolution: {integrity: sha512-9pIKIJhnI5tonzG6OnCFlz/yln8xHYcGl+pn3xR0Vzff0vzN1PbNRaelgfgRUwZ3s4i3jvxT9WhmUGL4whnasA==} dependencies: camelcase: 3.0.0 lodash.assign: 4.2.0 dev: true - /yargs-parser/20.2.4: + /yargs-parser@20.2.4: resolution: {integrity: sha512-WOkpgNhPTlE73h4VFAFsOnomJVaovO8VqLDzy5saChRBFQFBoMYirowyW+Q9HB4HFF4Z7VZTiG3iSzJJA29yRA==} engines: {node: '>=10'} dev: true - /yargs-unparser/1.6.0: + /yargs-unparser@1.6.0: resolution: {integrity: sha512-W9tKgmSn0DpSatfri0nx52Joq5hVXgeLiqR/5G0sZNDoLZFOr/xjBUDcShCOGNsBnEMNo1KAMBkTej1Hm62HTw==} engines: {node: '>=6'} dependencies: @@ -12104,7 +12134,7 @@ packages: yargs: 13.3.2 dev: true - /yargs-unparser/2.0.0: + /yargs-unparser@2.0.0: resolution: {integrity: sha512-7pRTIA9Qc1caZ0bZ6RYRGbHJthJWuakf+WmHK0rVeLkNrrGhfoabBNdue6kdINI6r4if7ocq9aD/n7xwKOdzOA==} engines: {node: '>=10'} dependencies: @@ -12114,7 +12144,7 @@ packages: is-plain-obj: 2.1.0 dev: true - /yargs/13.3.2: + /yargs@13.3.2: resolution: {integrity: sha512-AX3Zw5iPruN5ie6xGRIDgqkT+ZhnRlZMLMHAs8tg7nRruy2Nb+i5o9bwghAogtM08q1dpr2LVoS8KSTMYpWXUw==} dependencies: cliui: 5.0.0 @@ -12129,7 +12159,7 @@ packages: yargs-parser: 13.1.2 dev: true - /yargs/16.2.0: + /yargs@16.2.0: resolution: {integrity: sha512-D1mvvtDG0L5ft/jGWkLpG1+m0eQxOfaBvTNELraWj22wSVUMWxZUvYgJYcKh6jGGIkJFhH4IZPQhR4TKpc8mBw==} engines: {node: '>=10'} dependencies: @@ -12142,7 +12172,7 @@ packages: yargs-parser: 20.2.4 dev: true - /yargs/4.8.1: + /yargs@4.8.1: resolution: {integrity: sha512-LqodLrnIDM3IFT+Hf/5sxBnEGECrfdC1uIbgZeJmESCSo4HoCAaKEus8MylXHAkdacGc0ye+Qa+dpkuom8uVYA==} dependencies: cliui: 3.2.0 @@ -12161,12 +12191,12 @@ packages: yargs-parser: 2.4.1 dev: true - /yn/3.1.1: + /yn@3.1.1: resolution: {integrity: sha512-Ux4ygGWsu2c7isFWe8Yu1YluJmqVhxqK2cLXNQA5AcC3QfbGNpM7fu0Y8b/z16pXLnFxZYvWhd3fhBY9DLmC6Q==} engines: {node: '>=6'} dev: true - /yocto-queue/0.1.0: + /yocto-queue@0.1.0: resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==} engines: {node: '>=10'} dev: true diff --git a/core/services/chainlink/application.go b/core/services/chainlink/application.go index 1541f473c12..5cb7828d016 100644 --- a/core/services/chainlink/application.go +++ b/core/services/chainlink/application.go @@ -50,6 +50,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/promreporter" "github.com/smartcontractkit/chainlink/v2/core/services/relay" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization" "github.com/smartcontractkit/chainlink/v2/core/services/telemetry" "github.com/smartcontractkit/chainlink/v2/core/services/vrf" @@ -300,6 +301,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { pipelineORM = pipeline.NewORM(db, globalLogger, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) bridgeORM = bridges.NewORM(db, globalLogger, cfg.Database()) sessionORM = sessions.NewORM(db, cfg.WebServer().SessionTimeout().Duration(), globalLogger, cfg.Database(), auditLogger) + mercuryORM = mercury.NewORM(db, globalLogger, cfg.Database()) pipelineRunner = pipeline.NewRunner(pipelineORM, bridgeORM, cfg.JobPipeline(), cfg.WebServer(), chains.EVM, keyStore.Eth(), keyStore.VRF(), globalLogger, restrictedHTTPClient, unrestrictedHTTPClient) jobORM = job.NewORM(db, chains.EVM, pipelineORM, bridgeORM, keyStore, globalLogger, cfg.Database()) txmORM = txmgr.NewTxStore(db, globalLogger, cfg.Database()) @@ -426,6 +428,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { db, jobORM, bridgeORM, + mercuryORM, pipelineRunner, peerWrapper, monitoringEndpointGen, diff --git a/core/services/job/spawner_test.go b/core/services/job/spawner_test.go index abaf69316d9..0e5b2b8991c 100644 --- a/core/services/job/spawner_test.go +++ b/core/services/job/spawner_test.go @@ -279,7 +279,7 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { processConfig := plugins.NewRegistrarConfig(loop.GRPCOpts{}, func(name string) (*plugins.RegisteredLoop, error) { return nil, nil }) ocr2DelegateConfig := ocr2.NewDelegateConfig(config.OCR2(), config.Mercury(), config.Threshold(), config.Insecure(), config.JobPipeline(), config.Database(), processConfig) - d := ocr2.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, cs, lggr, ocr2DelegateConfig, + d := ocr2.NewDelegate(nil, orm, nil, nil, nil, nil, monitoringEndpoint, cs, lggr, ocr2DelegateConfig, keyStore.OCR2(), keyStore.DKGSign(), keyStore.DKGEncrypt(), ethKeyStore, relayers, mailMon, nil) delegateOCR2 := &delegate{jobOCR2VRF.Type, []job.ServiceCtx{}, 0, nil, d} diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 7ebb064ae8b..462b2bba304 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -60,6 +60,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/relay" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" functionsRelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" + evmmercury "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" evmrelaytypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization" "github.com/smartcontractkit/chainlink/v2/core/services/telemetry" @@ -71,6 +72,7 @@ type Delegate struct { db *sqlx.DB jobORM job.ORM bridgeORM bridges.ORM + mercuryORM evmmercury.ORM pipelineRunner pipeline.Runner peerWrapper *ocrcommon.SingletonPeerWrapper monitoringEndpointGen telemetry.MonitoringEndpointGenerator @@ -179,6 +181,7 @@ func NewDelegate( db *sqlx.DB, jobORM job.ORM, bridgeORM bridges.ORM, + mercuryORM evmmercury.ORM, pipelineRunner pipeline.Runner, peerWrapper *ocrcommon.SingletonPeerWrapper, monitoringEndpointGen telemetry.MonitoringEndpointGenerator, @@ -197,6 +200,7 @@ func NewDelegate( db: db, jobORM: jobORM, bridgeORM: bridgeORM, + mercuryORM: mercuryORM, pipelineRunner: pipelineRunner, peerWrapper: peerWrapper, monitoringEndpointGen: monitoringEndpointGen, @@ -520,7 +524,8 @@ func (d *Delegate) newServicesMercury( } chEnhancedTelem := make(chan ocrcommon.EnhancedTelemetryMercuryData, 100) - mercuryServices, err2 := mercury.NewServices(jb, mercuryProvider, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, d.cfg.JobPipeline(), chEnhancedTelem, chain) + + mercuryServices, err2 := mercury.NewServices(jb, mercuryProvider, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, d.cfg.JobPipeline(), chEnhancedTelem, chain, d.mercuryORM, *spec.FeedID) if ocrcommon.ShouldCollectEnhancedTelemetryMercury(&jb) { enhancedTelemService := ocrcommon.NewEnhancedTelemetryService(&jb, chEnhancedTelem, make(chan struct{}), d.monitoringEndpointGen.GenMonitoringEndpoint(spec.FeedID.String(), synchronization.EnhancedEAMercury), lggr.Named("Enhanced Telemetry Mercury")) diff --git a/core/services/ocr2/plugins/mercury/plugin.go b/core/services/ocr2/plugins/mercury/plugin.go index fc3c702b894..1b29fd6ccf0 100644 --- a/core/services/ocr2/plugins/mercury/plugin.go +++ b/core/services/ocr2/plugins/mercury/plugin.go @@ -32,6 +32,8 @@ func NewServices( cfg Config, chEnhancedTelem chan ocrcommon.EnhancedTelemetryMercuryData, chainHeadTracker mercury.ChainHeadTracker, + orm mercury.DataSourceORM, + feedID [32]byte, ) ([]job.ServiceCtx, error) { if jb.PipelineSpec == nil { return nil, errors.New("expected job to have a non-nil PipelineSpec") @@ -47,6 +49,7 @@ func NewServices( } lggr = lggr.Named("MercuryPlugin").With("jobID", jb.ID, "jobName", jb.Name.ValueOrZero()) ds := mercury.NewDataSource( + orm, pipelineRunner, jb, *jb.PipelineSpec, @@ -56,6 +59,7 @@ func NewServices( chainHeadTracker, ocr2Provider.ContractTransmitter(), pluginConfig.InitialBlockNumber.Ptr(), + feedID, ) argsNoPlugin.MercuryPluginFactory = relaymercury.NewFactory( ds, diff --git a/core/services/relay/evm/mercury/data_source.go b/core/services/relay/evm/mercury/data_source.go index 533cbca700e..d09e424ada2 100644 --- a/core/services/relay/evm/mercury/data_source.go +++ b/core/services/relay/evm/mercury/data_source.go @@ -19,7 +19,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -45,6 +47,9 @@ type datasource struct { spec pipeline.Spec lggr logger.Logger runResults chan<- pipeline.Run + orm DataSourceORM + codec relaymercury.ReportCodec + feedID [32]byte mu sync.RWMutex @@ -56,8 +61,12 @@ type datasource struct { var _ relaymercury.DataSource = &datasource{} -func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, chainHeadTracker ChainHeadTracker, fetcher Fetcher, initialBlockNumber *int64) *datasource { - return &datasource{pr, jb, spec, lggr, rr, sync.RWMutex{}, enhancedTelemChan, chainHeadTracker, fetcher, initialBlockNumber} +type DataSourceORM interface { + LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) +} + +func NewDataSource(orm DataSourceORM, pr pipeline.Runner, jb job.Job, spec pipeline.Spec, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, chainHeadTracker ChainHeadTracker, fetcher Fetcher, initialBlockNumber *int64, feedID [32]byte) *datasource { + return &datasource{pr, jb, spec, lggr, rr, orm, &reportcodec.EVMReportCodec{}, feedID, sync.RWMutex{}, enhancedTelemChan, chainHeadTracker, fetcher, initialBlockNumber} } func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestamp, fetchMaxFinalizedBlockNum bool) (obs relaymercury.Observation, err error) { @@ -70,6 +79,15 @@ func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestam wg.Add(1) go func() { defer wg.Done() + latest, dbErr := ds.orm.LatestReport(ctx, ds.feedID) + if dbErr != nil { + obs.MaxFinalizedBlockNumber.Err = dbErr + return + } + if latest != nil { + obs.MaxFinalizedBlockNumber.Val, obs.MaxFinalizedBlockNumber.Err = ds.codec.CurrentBlockNumFromReport(latest) + return + } val, fetchErr := ds.fetcher.FetchInitialMaxFinalizedBlockNumber(ctx) if fetchErr != nil { obs.MaxFinalizedBlockNumber.Err = fetchErr diff --git a/core/services/relay/evm/mercury/data_source_test.go b/core/services/relay/evm/mercury/data_source_test.go index f30b9e629de..c6f4dec0432 100644 --- a/core/services/relay/evm/mercury/data_source_test.go +++ b/core/services/relay/evm/mercury/data_source_test.go @@ -25,8 +25,10 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -83,8 +85,18 @@ type mockHeadTracker struct { func (m *mockHeadTracker) Client() evmclient.Client { return m.c } func (m *mockHeadTracker) HeadTracker() httypes.HeadTracker { return m.h } +type mockORM struct { + report []byte + err error +} + +func (m *mockORM) LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) { + return m.report, m.err +} + func TestMercury_Observe(t *testing.T) { - ds := &datasource{lggr: logger.TestLogger(t)} + orm := &mockORM{} + ds := &datasource{lggr: logger.TestLogger(t), orm: orm, codec: (&reportcodec.EVMReportCodec{})} ctx := testutils.Context(t) repts := ocrtypes.ReportTimestamp{} @@ -133,62 +145,88 @@ func TestMercury_Observe(t *testing.T) { h.On("LatestChain").Return(head) t.Run("when fetchMaxFinalizedBlockNum=true", func(t *testing.T) { - t.Run("if FetchInitialMaxFinalizedBlockNumber returns error", func(t *testing.T) { - fetcher.err = errors.New("mock fetcher error") + t.Run("with latest report in database", func(t *testing.T) { + orm.report = sampleReport + orm.err = nil obs, err := ds.Observe(ctx, repts, true) assert.NoError(t, err) - assert.EqualError(t, obs.MaxFinalizedBlockNumber.Err, "mock fetcher error") - assert.Zero(t, obs.MaxFinalizedBlockNumber.Val) + assert.NoError(t, obs.MaxFinalizedBlockNumber.Err) + assert.Equal(t, int64(143), obs.MaxFinalizedBlockNumber.Val) }) - t.Run("if FetchInitialMaxFinalizedBlockNumber succeeds", func(t *testing.T) { - fetcher.err = nil - var num int64 = 32 - fetcher.num = &num + t.Run("if querying latest report fails", func(t *testing.T) { + orm.report = nil + orm.err = errors.New("something exploded") obs, err := ds.Observe(ctx, repts, true) assert.NoError(t, err) - assert.NoError(t, obs.MaxFinalizedBlockNumber.Err) - assert.Equal(t, int64(32), obs.MaxFinalizedBlockNumber.Val) + assert.EqualError(t, obs.MaxFinalizedBlockNumber.Err, "something exploded") + assert.Zero(t, obs.MaxFinalizedBlockNumber.Val) }) - t.Run("if FetchInitialMaxFinalizedBlockNumber returns nil (new feed) and initialBlockNumber is set", func(t *testing.T) { - var initialBlockNumber int64 = 50 - ds.initialBlockNumber = &initialBlockNumber - fetcher.err = nil - fetcher.num = nil - obs, err := ds.Observe(ctx, repts, true) - assert.NoError(t, err) + orm.report = nil + orm.err = nil - assert.NoError(t, obs.MaxFinalizedBlockNumber.Err) - assert.Equal(t, int64(49), obs.MaxFinalizedBlockNumber.Val) - }) - t.Run("if FetchInitialMaxFinalizedBlockNumber returns nil (new feed) and initialBlockNumber is not set", func(t *testing.T) { - ds.initialBlockNumber = nil - t.Run("if current block num is valid", func(t *testing.T) { + t.Run("without latest report in database", func(t *testing.T) { + t.Run("if FetchInitialMaxFinalizedBlockNumber returns error", func(t *testing.T) { + fetcher.err = errors.New("mock fetcher error") + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.EqualError(t, obs.MaxFinalizedBlockNumber.Err, "mock fetcher error") + assert.Zero(t, obs.MaxFinalizedBlockNumber.Val) + }) + t.Run("if FetchInitialMaxFinalizedBlockNumber succeeds", func(t *testing.T) { fetcher.err = nil - fetcher.num = nil + var num int64 = 32 + fetcher.num = &num obs, err := ds.Observe(ctx, repts, true) assert.NoError(t, err) assert.NoError(t, obs.MaxFinalizedBlockNumber.Err) - assert.Equal(t, head.Number-1, obs.MaxFinalizedBlockNumber.Val) + assert.Equal(t, int64(32), obs.MaxFinalizedBlockNumber.Val) }) - t.Run("if current block num errored", func(t *testing.T) { - h2 := commonmocks.NewHeadTracker[*evmtypes.Head, common.Hash](t) - h2.On("LatestChain").Return((*evmtypes.Head)(nil)) - ht.h = h2 - c2 := evmtest.NewEthClientMock(t) - c2.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(nil, errors.New("head retrieval failed")) - ht.c = c2 + t.Run("if FetchInitialMaxFinalizedBlockNumber returns nil (new feed) and initialBlockNumber is set", func(t *testing.T) { + var initialBlockNumber int64 = 50 + ds.initialBlockNumber = &initialBlockNumber + fetcher.err = nil + fetcher.num = nil obs, err := ds.Observe(ctx, repts, true) assert.NoError(t, err) - assert.EqualError(t, obs.MaxFinalizedBlockNumber.Err, "FetchInitialMaxFinalizedBlockNumber returned empty LatestReport; this is a new feed. No initialBlockNumber was set, tried to use current block number to determine maxFinalizedBlockNumber but got error: head retrieval failed") + assert.NoError(t, obs.MaxFinalizedBlockNumber.Err) + assert.Equal(t, int64(49), obs.MaxFinalizedBlockNumber.Val) + }) + t.Run("if FetchInitialMaxFinalizedBlockNumber returns nil (new feed) and initialBlockNumber is not set", func(t *testing.T) { + ds.initialBlockNumber = nil + t.Run("if current block num is valid", func(t *testing.T) { + fetcher.err = nil + fetcher.num = nil + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.NoError(t, obs.MaxFinalizedBlockNumber.Err) + assert.Equal(t, head.Number-1, obs.MaxFinalizedBlockNumber.Val) + }) + t.Run("if current block num errored", func(t *testing.T) { + h2 := commonmocks.NewHeadTracker[*evmtypes.Head, common.Hash](t) + h2.On("LatestChain").Return((*evmtypes.Head)(nil)) + ht.h = h2 + c2 := evmtest.NewEthClientMock(t) + c2.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(nil, errors.New("head retrieval failed")) + ht.c = c2 + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.EqualError(t, obs.MaxFinalizedBlockNumber.Err, "FetchInitialMaxFinalizedBlockNumber returned empty LatestReport; this is a new feed. No initialBlockNumber was set, tried to use current block number to determine maxFinalizedBlockNumber but got error: head retrieval failed") + }) }) }) }) diff --git a/core/services/relay/evm/mercury/helpers_test.go b/core/services/relay/evm/mercury/helpers_test.go index 349aa73e2cc..2b37df0b39a 100644 --- a/core/services/relay/evm/mercury/helpers_test.go +++ b/core/services/relay/evm/mercury/helpers_test.go @@ -13,10 +13,10 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/utils" ) -func buildSampleReport() []byte { - feedID := [32]byte{'f', 'o', 'o'} +func buildSampleReport(p int64) []byte { + feedID := sampleFeedID timestamp := uint32(42) - bp := big.NewInt(242) + bp := big.NewInt(p) bid := big.NewInt(243) ask := big.NewInt(244) currentBlockNumber := uint64(143) @@ -52,9 +52,18 @@ func buildSamplePayload() []byte { return payload } +var sampleReports [][]byte + +func init() { + sampleReports = make([][]byte, 4) + for i := 0; i < len(sampleReports); i++ { + sampleReports[i] = buildSampleReport(int64(i)) + } +} + var ( sampleFeedID = [32]uint8{28, 145, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114} - sampleReport = buildSampleReport() + sampleReport = buildSampleReport(242) sampleClientPubKey = hexutil.MustDecode("0x724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93") sig2 = ocrtypes.AttributedOnchainSignature{Signature: mustDecodeBase64("kbeuRczizOJCxBzj7MUAFpz3yl2WRM6K/f0ieEBvA+oTFUaKslbQey10krumVjzAvlvKxMfyZo0WkOgNyfF6xwE="), Signer: 2} sig3 = ocrtypes.AttributedOnchainSignature{Signature: mustDecodeBase64("9jz4b6Dh2WhXxQ97a6/S9UNjSfrEi9016XKTrfN0mLQFDiNuws23x7Z4n+6g0sqKH/hnxx1VukWUH/ohtw83/wE="), Signer: 3} diff --git a/core/services/relay/evm/mercury/orm.go b/core/services/relay/evm/mercury/orm.go index 208c403caff..601bc122023 100644 --- a/core/services/relay/evm/mercury/orm.go +++ b/core/services/relay/evm/mercury/orm.go @@ -1,7 +1,11 @@ package mercury import ( + "context" "crypto/sha256" + "database/sql" + "errors" + "sync" "github.com/ethereum/go-ethereum/common" "github.com/lib/pq" @@ -11,34 +15,72 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" ) -type ORM struct { - q pg.Q +type ORM interface { + InsertTransmitRequest(req *pb.TransmitRequest, reportCtx ocrtypes.ReportContext, qopts ...pg.QOpt) error + DeleteTransmitRequests(reqs []*pb.TransmitRequest, qopts ...pg.QOpt) error + GetTransmitRequests(qopts ...pg.QOpt) ([]*Transmission, error) + PruneTransmitRequests(maxSize int, qopts ...pg.QOpt) error + LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) } -func NewORM(db *sqlx.DB, lggr logger.Logger, cfg pg.QConfig) *ORM { +type ORMCodec interface { + FeedIDFromReport(report ocrtypes.Report) (feedID [32]byte, err error) +} + +type orm struct { + q pg.Q + codec ORMCodec +} + +func NewORM(db *sqlx.DB, lggr logger.Logger, cfg pg.QConfig) ORM { namedLogger := lggr.Named("MercuryORM") q := pg.NewQ(db, namedLogger, cfg) - return &ORM{ - q: q, + return &orm{ + q: q, + codec: (&reportcodec.EVMReportCodec{}), } } // InsertTransmitRequest inserts one transmit request if the payload does not exist already. -func (o *ORM) InsertTransmitRequest(req *pb.TransmitRequest, reportCtx ocrtypes.ReportContext, qopts ...pg.QOpt) error { +func (o *orm) InsertTransmitRequest(req *pb.TransmitRequest, reportCtx ocrtypes.ReportContext, qopts ...pg.QOpt) error { q := o.q.WithOpts(qopts...) - err := q.ExecQ(` + var wg sync.WaitGroup + wg.Add(2) + var err1, err2 error + + go func() { + defer wg.Done() + err1 = q.ExecQ(` INSERT INTO mercury_transmit_requests (payload, payload_hash, config_digest, epoch, round, extra_hash) VALUES ($1, $2, $3, $4, $5, $6) ON CONFLICT (payload_hash) DO NOTHING `, req.Payload, hashPayload(req.Payload), reportCtx.ConfigDigest[:], reportCtx.Epoch, reportCtx.Round, reportCtx.ExtraHash[:]) - return err + }() + + feedID, err := o.codec.FeedIDFromReport(req.Payload) + if err != nil { + return err + } + go func() { + defer wg.Done() + err2 = q.ExecQ(` + INSERT INTO feed_latest_reports (feed_id, report, epoch, round, updated_at) + VALUES ($1, $2, $3, $4, NOW()) + ON CONFLICT (feed_id) DO UPDATE + SET feed_id=$1, report=$2, epoch=$3, round=$4, updated_at=NOW() + WHERE excluded.epoch > feed_latest_reports.epoch OR (excluded.epoch = feed_latest_reports.epoch AND excluded.round > feed_latest_reports.round) + `, feedID[:], req.Payload, reportCtx.Epoch, reportCtx.Round) + }() + wg.Wait() + return errors.Join(err1, err2) } // DeleteTransmitRequest deletes the given transmit requests if they exist. -func (o *ORM) DeleteTransmitRequests(reqs []*pb.TransmitRequest, qopts ...pg.QOpt) error { +func (o *orm) DeleteTransmitRequests(reqs []*pb.TransmitRequest, qopts ...pg.QOpt) error { if len(reqs) == 0 { return nil } @@ -57,7 +99,7 @@ func (o *ORM) DeleteTransmitRequests(reqs []*pb.TransmitRequest, qopts ...pg.QOp } // GetTransmitRequests returns all transmit requests in chronologically descending order. -func (o *ORM) GetTransmitRequests(qopts ...pg.QOpt) ([]*Transmission, error) { +func (o *orm) GetTransmitRequests(qopts ...pg.QOpt) ([]*Transmission, error) { q := o.q.WithOpts(qopts...) // The priority queue uses epoch and round to sort transmissions so order by // the same fields here for optimal insertion into the pq. @@ -100,7 +142,7 @@ func (o *ORM) GetTransmitRequests(qopts ...pg.QOpt) ([]*Transmission, error) { // PruneTransmitRequests keeps at most maxSize rows in the table, deleting the // oldest transactions. -func (o *ORM) PruneTransmitRequests(maxSize int, qopts ...pg.QOpt) error { +func (o *orm) PruneTransmitRequests(maxSize int, qopts ...pg.QOpt) error { q := o.q.WithOpts(qopts...) // Prune the oldest requests by epoch and round. return q.ExecQ(` @@ -114,6 +156,15 @@ func (o *ORM) PruneTransmitRequests(maxSize int, qopts ...pg.QOpt) error { `, maxSize) } +func (o *orm) LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) { + q := o.q.WithOpts(qopts...) + err = q.GetContext(ctx, &report, `SELECT report FROM feed_latest_reports WHERE feed_id = $1`, feedID[:]) + if errors.Is(err, sql.ErrNoRows) { + return nil, nil + } + return report, err +} + func hashPayload(payload []byte) []byte { checksum := sha256.Sum256(payload) return checksum[:] diff --git a/core/services/relay/evm/mercury/orm_test.go b/core/services/relay/evm/mercury/orm_test.go index 2605c2e1926..27dba9b5c92 100644 --- a/core/services/relay/evm/mercury/orm_test.go +++ b/core/services/relay/evm/mercury/orm_test.go @@ -4,8 +4,10 @@ import ( "testing" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" @@ -15,43 +17,61 @@ func TestORM(t *testing.T) { db := pgtest.NewSqlxDB(t) lggr := logger.TestLogger(t) orm := NewORM(db, lggr, pgtest.NewQConfig(true)) + feedID := sampleFeedID - reportContext := ocrtypes.ReportContext{ - ReportTimestamp: ocrtypes.ReportTimestamp{ - ConfigDigest: ocrtypes.ConfigDigest{'1'}, - Epoch: 10, - Round: 20, - }, - ExtraHash: [32]byte{'2'}, + reports := sampleReports + reportContexts := make([]ocrtypes.ReportContext, 4) + for i := range reportContexts { + reportContexts[i] = ocrtypes.ReportContext{ + ReportTimestamp: ocrtypes.ReportTimestamp{ + ConfigDigest: ocrtypes.ConfigDigest{'1'}, + Epoch: 10, + Round: uint8(i), + }, + ExtraHash: [32]byte{'2'}, + } } + l, err := orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Nil(t, l) + // Test insert and get requests. - err := orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("report-1")}, reportContext) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[0]}, reportContexts[0]) require.NoError(t, err) - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("report-2")}, reportContext) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[1]}, reportContexts[1]) require.NoError(t, err) - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("report-3")}, reportContext) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[2]}, reportContexts[2]) require.NoError(t, err) transmissions, err := orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-1")}, ReportCtx: reportContext}, - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}, ReportCtx: reportContext}, - {Req: &pb.TransmitRequest{Payload: []byte("report-3")}, ReportCtx: reportContext}, + {Req: &pb.TransmitRequest{Payload: reports[2]}, ReportCtx: reportContexts[2]}, + {Req: &pb.TransmitRequest{Payload: reports[1]}, ReportCtx: reportContexts[1]}, + {Req: &pb.TransmitRequest{Payload: reports[0]}, ReportCtx: reportContexts[0]}, }) + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.NotEqual(t, reports[0], l) + assert.Equal(t, reports[2], l) + // Test requests can be deleted. - err = orm.DeleteTransmitRequests([]*pb.TransmitRequest{{Payload: []byte("report-2")}}) + err = orm.DeleteTransmitRequests([]*pb.TransmitRequest{{Payload: reports[1]}}) require.NoError(t, err) transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-1")}, ReportCtx: reportContext}, - {Req: &pb.TransmitRequest{Payload: []byte("report-3")}, ReportCtx: reportContext}, + {Req: &pb.TransmitRequest{Payload: reports[2]}, ReportCtx: reportContexts[2]}, + {Req: &pb.TransmitRequest{Payload: reports[0]}, ReportCtx: reportContexts[0]}, }) + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[2], l) + // Test deleting non-existent requests does not error. err = orm.DeleteTransmitRequests([]*pb.TransmitRequest{{Payload: []byte("does-not-exist")}}) require.NoError(t, err) @@ -59,42 +79,50 @@ func TestORM(t *testing.T) { transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-1")}, ReportCtx: reportContext}, - {Req: &pb.TransmitRequest{Payload: []byte("report-3")}, ReportCtx: reportContext}, + {Req: &pb.TransmitRequest{Payload: reports[2]}, ReportCtx: reportContexts[2]}, + {Req: &pb.TransmitRequest{Payload: reports[0]}, ReportCtx: reportContexts[0]}, }) // Test deleting multiple requests. err = orm.DeleteTransmitRequests([]*pb.TransmitRequest{ - {Payload: []byte("report-1")}, - {Payload: []byte("report-3")}, + {Payload: reports[0]}, + {Payload: reports[2]}, }) require.NoError(t, err) + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[2], l) + transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Empty(t, transmissions) // More inserts. - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("report-4")}, reportContext) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[3]}, reportContexts[3]) require.NoError(t, err) transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-4")}, ReportCtx: reportContext}, + {Req: &pb.TransmitRequest{Payload: reports[3]}, ReportCtx: reportContexts[3]}, }) // Duplicate requests are ignored. - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("report-4")}, reportContext) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[3]}, reportContexts[3]) require.NoError(t, err) - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("report-4")}, reportContext) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[3]}, reportContexts[3]) require.NoError(t, err) transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-4")}, ReportCtx: reportContext}, + {Req: &pb.TransmitRequest{Payload: reports[3]}, ReportCtx: reportContexts[3]}, }) + + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[3], l) } func TestORM_PruneTransmitRequests(t *testing.T) { @@ -102,6 +130,8 @@ func TestORM_PruneTransmitRequests(t *testing.T) { lggr := logger.TestLogger(t) orm := NewORM(db, lggr, pgtest.NewQConfig(true)) + reports := sampleReports + makeReportContext := func(epoch uint32, round uint8) ocrtypes.ReportContext { return ocrtypes.ReportContext{ ReportTimestamp: ocrtypes.ReportTimestamp{ @@ -113,9 +143,9 @@ func TestORM_PruneTransmitRequests(t *testing.T) { } } - err := orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("1")}, makeReportContext(1, 1)) + err := orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[0]}, makeReportContext(1, 1)) require.NoError(t, err) - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("2")}, makeReportContext(1, 2)) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[1]}, makeReportContext(1, 2)) require.NoError(t, err) // Max size greater than table size, expect no-op @@ -125,8 +155,8 @@ func TestORM_PruneTransmitRequests(t *testing.T) { transmissions, err := orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("2")}, ReportCtx: makeReportContext(1, 2)}, - {Req: &pb.TransmitRequest{Payload: []byte("1")}, ReportCtx: makeReportContext(1, 1)}, + {Req: &pb.TransmitRequest{Payload: reports[1]}, ReportCtx: makeReportContext(1, 2)}, + {Req: &pb.TransmitRequest{Payload: reports[0]}, ReportCtx: makeReportContext(1, 1)}, }) // Max size equal to table size, expect no-op @@ -136,13 +166,13 @@ func TestORM_PruneTransmitRequests(t *testing.T) { transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("2")}, ReportCtx: makeReportContext(1, 2)}, - {Req: &pb.TransmitRequest{Payload: []byte("1")}, ReportCtx: makeReportContext(1, 1)}, + {Req: &pb.TransmitRequest{Payload: reports[1]}, ReportCtx: makeReportContext(1, 2)}, + {Req: &pb.TransmitRequest{Payload: reports[0]}, ReportCtx: makeReportContext(1, 1)}, }) - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("3")}, makeReportContext(2, 1)) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[2]}, makeReportContext(2, 1)) require.NoError(t, err) - err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: []byte("4")}, makeReportContext(2, 2)) + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[3]}, makeReportContext(2, 2)) require.NoError(t, err) // Max size is table size + 1, expect the oldest row to be pruned. @@ -152,8 +182,70 @@ func TestORM_PruneTransmitRequests(t *testing.T) { transmissions, err = orm.GetTransmitRequests() require.NoError(t, err) require.Equal(t, transmissions, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("4")}, ReportCtx: makeReportContext(2, 2)}, - {Req: &pb.TransmitRequest{Payload: []byte("3")}, ReportCtx: makeReportContext(2, 1)}, - {Req: &pb.TransmitRequest{Payload: []byte("2")}, ReportCtx: makeReportContext(1, 2)}, + {Req: &pb.TransmitRequest{Payload: reports[3]}, ReportCtx: makeReportContext(2, 2)}, + {Req: &pb.TransmitRequest{Payload: reports[2]}, ReportCtx: makeReportContext(2, 1)}, + {Req: &pb.TransmitRequest{Payload: reports[1]}, ReportCtx: makeReportContext(1, 2)}, + }) +} + +func TestORM_InsertTransmitRequest_LatestReport(t *testing.T) { + db := pgtest.NewSqlxDB(t) + lggr := logger.TestLogger(t) + orm := NewORM(db, lggr, pgtest.NewQConfig(true)) + feedID := sampleFeedID + + reports := sampleReports + + makeReportContext := func(epoch uint32, round uint8) ocrtypes.ReportContext { + return ocrtypes.ReportContext{ + ReportTimestamp: ocrtypes.ReportTimestamp{ + ConfigDigest: ocrtypes.ConfigDigest{'1'}, + Epoch: epoch, + Round: round, + }, + ExtraHash: [32]byte{'2'}, + } + } + + err := orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[0]}, makeReportContext( + 0, 0, + )) + require.NoError(t, err) + + l, err := orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[0], l) + + t.Run("replaces if epoch and round are larger", func(t *testing.T) { + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[1]}, makeReportContext(1, 1)) + require.NoError(t, err) + + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[1], l) + }) + t.Run("replaces if epoch is the same but round is greater", func(t *testing.T) { + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[2]}, makeReportContext(1, 2)) + require.NoError(t, err) + + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[2], l) + }) + t.Run("replaces if epoch is larger but round is smaller", func(t *testing.T) { + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[3]}, makeReportContext(2, 1)) + require.NoError(t, err) + + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[3], l) + }) + t.Run("does not overwrite if epoch/round is the same", func(t *testing.T) { + err = orm.InsertTransmitRequest(&pb.TransmitRequest{Payload: reports[0]}, makeReportContext(2, 1)) + require.NoError(t, err) + + l, err = orm.LatestReport(testutils.Context(t), feedID) + require.NoError(t, err) + assert.Equal(t, reports[3], l) }) } diff --git a/core/services/relay/evm/mercury/persistence_manager.go b/core/services/relay/evm/mercury/persistence_manager.go index ee493acf130..df170313839 100644 --- a/core/services/relay/evm/mercury/persistence_manager.go +++ b/core/services/relay/evm/mercury/persistence_manager.go @@ -20,7 +20,7 @@ var ( type PersistenceManager struct { lggr logger.Logger - orm *ORM + orm ORM once utils.StartStopOnce stopCh utils.StopChan @@ -30,7 +30,7 @@ type PersistenceManager struct { deleteQueue []*pb.TransmitRequest } -func NewPersistenceManager(lggr logger.Logger, orm *ORM) *PersistenceManager { +func NewPersistenceManager(lggr logger.Logger, orm ORM) *PersistenceManager { return &PersistenceManager{ lggr: lggr.Named("MercuryPersistenceManager"), orm: orm, diff --git a/core/services/relay/evm/mercury/persistence_manager_test.go b/core/services/relay/evm/mercury/persistence_manager_test.go index 2cd299c2ef8..5ad1efedf1b 100644 --- a/core/services/relay/evm/mercury/persistence_manager_test.go +++ b/core/services/relay/evm/mercury/persistence_manager_test.go @@ -24,25 +24,27 @@ func TestPersistenceManager(t *testing.T) { ctx := context.Background() pm := bootstrapPersistenceManager(t) - err := pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-1")}, ocrtypes.ReportContext{}) + reports := sampleReports + + err := pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[0]}, ocrtypes.ReportContext{}) require.NoError(t, err) - err = pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-2")}, ocrtypes.ReportContext{}) + err = pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[1]}, ocrtypes.ReportContext{}) require.NoError(t, err) transmissions, err := pm.Load(ctx) require.NoError(t, err) require.Equal(t, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-1")}}, - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}}, + {Req: &pb.TransmitRequest{Payload: reports[0]}}, + {Req: &pb.TransmitRequest{Payload: reports[1]}}, }, transmissions) - err = pm.Delete(ctx, &pb.TransmitRequest{Payload: []byte("report-1")}) + err = pm.Delete(ctx, &pb.TransmitRequest{Payload: reports[0]}) require.NoError(t, err) transmissions, err = pm.Load(ctx) require.NoError(t, err) require.Equal(t, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}}, + {Req: &pb.TransmitRequest{Payload: reports[1]}}, }, transmissions) } @@ -50,37 +52,39 @@ func TestPersistenceManagerAsyncDelete(t *testing.T) { ctx := context.Background() pm := bootstrapPersistenceManager(t) - err := pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-1")}, ocrtypes.ReportContext{}) + reports := sampleReports + + err := pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[0]}, ocrtypes.ReportContext{}) require.NoError(t, err) - err = pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-2")}, ocrtypes.ReportContext{}) + err = pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[1]}, ocrtypes.ReportContext{}) require.NoError(t, err) flushDeletesFrequency = 10 * time.Millisecond err = pm.Start(ctx) require.NoError(t, err) - pm.AsyncDelete(&pb.TransmitRequest{Payload: []byte("report-1")}) + pm.AsyncDelete(&pb.TransmitRequest{Payload: reports[0]}) time.Sleep(15 * time.Millisecond) transmissions, err := pm.Load(ctx) require.NoError(t, err) require.Equal(t, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}}, + {Req: &pb.TransmitRequest{Payload: reports[1]}}, }, transmissions) // Test AsyncDelete is a no-op after Close. err = pm.Close() require.NoError(t, err) - pm.AsyncDelete(&pb.TransmitRequest{Payload: []byte("report-2")}) + pm.AsyncDelete(&pb.TransmitRequest{Payload: reports[1]}) time.Sleep(15 * time.Millisecond) transmissions, err = pm.Load(ctx) require.NoError(t, err) require.Equal(t, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}}, + {Req: &pb.TransmitRequest{Payload: reports[1]}}, }, transmissions) } @@ -88,11 +92,13 @@ func TestPersistenceManagerPrune(t *testing.T) { ctx := context.Background() pm := bootstrapPersistenceManager(t) - err := pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-1")}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 1}}) + reports := sampleReports + + err := pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[0]}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 1}}) require.NoError(t, err) - err = pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-2")}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 2}}) + err = pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[1]}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 2}}) require.NoError(t, err) - err = pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-3")}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 3}}) + err = pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[2]}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 3}}) require.NoError(t, err) maxTransmitQueueSize = 2 @@ -105,15 +111,15 @@ func TestPersistenceManagerPrune(t *testing.T) { transmissions, err := pm.Load(ctx) require.NoError(t, err) require.Equal(t, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-3")}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 3}}}, - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 2}}}, + {Req: &pb.TransmitRequest{Payload: reports[2]}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 3}}}, + {Req: &pb.TransmitRequest{Payload: reports[1]}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 2}}}, }, transmissions) // Test pruning stops after Close. err = pm.Close() require.NoError(t, err) - err = pm.Insert(ctx, &pb.TransmitRequest{Payload: []byte("report-4")}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 4}}) + err = pm.Insert(ctx, &pb.TransmitRequest{Payload: reports[3]}, ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 4}}) require.NoError(t, err) time.Sleep(15 * time.Millisecond) @@ -121,8 +127,8 @@ func TestPersistenceManagerPrune(t *testing.T) { transmissions, err = pm.Load(ctx) require.NoError(t, err) require.Equal(t, []*Transmission{ - {Req: &pb.TransmitRequest{Payload: []byte("report-4")}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 4}}}, - {Req: &pb.TransmitRequest{Payload: []byte("report-3")}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 3}}}, - {Req: &pb.TransmitRequest{Payload: []byte("report-2")}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 2}}}, + {Req: &pb.TransmitRequest{Payload: reports[3]}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 4}}}, + {Req: &pb.TransmitRequest{Payload: reports[2]}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 3}}}, + {Req: &pb.TransmitRequest{Payload: reports[1]}, ReportCtx: ocrtypes.ReportContext{ReportTimestamp: ocrtypes.ReportTimestamp{Epoch: 2}}}, }, transmissions) } diff --git a/core/services/relay/evm/mercury/reportcodec/report_codec.go b/core/services/relay/evm/mercury/reportcodec/report_codec.go index 9f08e413363..9b28050d2a0 100644 --- a/core/services/relay/evm/mercury/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/reportcodec/report_codec.go @@ -100,6 +100,13 @@ func (r *EVMReportCodec) MaxReportLength(n int) (int, error) { return maxReportLength, nil } +func (r *EVMReportCodec) FeedIDFromReport(report ocrtypes.Report) (feedID [32]byte, err error) { + if n := copy(feedID[:], report); n != 32 { + return feedID, errors.Errorf("invalid length for report: %d", len(report)) + } + return feedID, nil +} + func (r *EVMReportCodec) CurrentBlockNumFromReport(report ocrtypes.Report) (int64, error) { reportElems := map[string]interface{}{} if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { diff --git a/core/services/relay/evm/mercury/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/reportcodec/report_codec_test.go index 757797807b9..05b33d13a87 100644 --- a/core/services/relay/evm/mercury/reportcodec/report_codec_test.go +++ b/core/services/relay/evm/mercury/reportcodec/report_codec_test.go @@ -130,12 +130,13 @@ func Test_ReportCodec_MaxReportLength(t *testing.T) { func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { r := EVMReportCodec{} + feedID := utils.NewHash() var validBn int64 = 42 var invalidBn int64 = -1 t.Run("CurrentBlockNumFromReport extracts the current block number from a valid report", func(t *testing.T) { - report := buildSampleReport(validBn) + report := buildSampleReport(validBn, feedID) bn, err := r.CurrentBlockNumFromReport(report) require.NoError(t, err) @@ -143,7 +144,7 @@ func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { assert.Equal(t, validBn, bn) }) t.Run("CurrentBlockNumFromReport returns error if block num is too large", func(t *testing.T) { - report := buildSampleReport(invalidBn) + report := buildSampleReport(invalidBn, feedID) _, err := r.CurrentBlockNumFromReport(report) require.Error(t, err) @@ -152,8 +153,29 @@ func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { }) } -func buildSampleReport(bn int64) []byte { - feedID := [32]byte{'f', 'o', 'o'} +func Test_ReportCodec_FeedIDFromReport(t *testing.T) { + r := EVMReportCodec{} + + feedID := utils.NewHash() + var validBn int64 = 42 + + t.Run("FeedIDFromReport extracts the current block number from a valid report", func(t *testing.T) { + report := buildSampleReport(validBn, feedID) + + f, err := r.FeedIDFromReport(report) + require.NoError(t, err) + + assert.Equal(t, feedID[:], f[:]) + }) + t.Run("FeedIDFromReport returns error if report is invalid", func(t *testing.T) { + report := []byte{1} + + _, err := r.FeedIDFromReport(report) + assert.EqualError(t, err, "invalid length for report: 1") + }) +} + +func buildSampleReport(bn int64, feedID [32]byte) []byte { timestamp := uint32(42) bp := big.NewInt(242) bid := big.NewInt(243) diff --git a/core/store/migrate/migrations/0186_create_feed_latest_reports.sql b/core/store/migrate/migrations/0186_create_feed_latest_reports.sql new file mode 100644 index 00000000000..9d90562fb94 --- /dev/null +++ b/core/store/migrate/migrations/0186_create_feed_latest_reports.sql @@ -0,0 +1,13 @@ +-- +goose Up + +CREATE TABLE feed_latest_reports ( + feed_id BYTEA PRIMARY KEY CHECK (octet_length(feed_id) = 32), + report BYTEA NOT NULL, + epoch BIGINT NOT NULL, + round INT NOT NULL, + updated_at TIMESTAMPTZ NOT NULL +); + +-- +goose Down + +DROP TABLE feed_latest_reports; From 1c69307bbe58d21858536cb2f775cd8b4d2196f9 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Wed, 9 Aug 2023 11:14:47 -0400 Subject: [PATCH 123/270] More Frequent Testnet Tests (#10120) --- .github/workflows/integration-tests.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 481028387ce..9f9cd33b272 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -3,7 +3,8 @@ on: merge_group: pull_request: schedule: - - cron: "0 0 * * *" + # - cron: "0 0 * * *" + - cron: "0 * * * *" # every hour while we debug for flakes push: tags: - "*" From d1871ab89d6fb1e2af04cb3ea1e8294fecca1dea Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Wed, 9 Aug 2023 19:34:38 +0300 Subject: [PATCH 124/270] ocrv1 test (#10130) --- .../actions/ocr_helpers_local.go | 272 ++++++++++++++++++ .../contracts/contract_models.go | 1 + .../contracts/ethereum_contracts.go | 2 +- .../contracts/ethereum_contracts_local.go | 96 +++++++ integration-tests/docker/test_env/cl_node.go | 14 +- integration-tests/smoke/ocr_test.go | 102 ++----- 6 files changed, 402 insertions(+), 85 deletions(-) create mode 100644 integration-tests/actions/ocr_helpers_local.go create mode 100644 integration-tests/contracts/ethereum_contracts_local.go diff --git a/integration-tests/actions/ocr_helpers_local.go b/integration-tests/actions/ocr_helpers_local.go new file mode 100644 index 00000000000..1bee5703f27 --- /dev/null +++ b/integration-tests/actions/ocr_helpers_local.go @@ -0,0 +1,272 @@ +package actions + +import ( + "fmt" + "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/common" + "github.com/google/uuid" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" + "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "golang.org/x/sync/errgroup" + "math/big" + "strings" +) + +/* + These methods should be cleaned merged after we decouple ChainlinkClient and ChainlinkK8sClient + Please, use them while refactoring other tests to local docker env +*/ + +// FundChainlinkNodesLocal will fund all the provided Chainlink nodes with a set amount of native currency +func FundChainlinkNodesLocal( + nodes []*client.ChainlinkClient, + client blockchain.EVMClient, + amount *big.Float, +) error { + for _, cl := range nodes { + toAddress, err := cl.PrimaryEthAddress() + if err != nil { + return err + } + gasEstimates, err := client.EstimateGas(ethereum.CallMsg{}) + if err != nil { + return err + } + err = client.Fund(toAddress, amount, gasEstimates) + if err != nil { + return err + } + } + return client.WaitForEvents() +} + +func ChainlinkNodeAddressesLocal(nodes []*client.ChainlinkClient) ([]common.Address, error) { + addresses := make([]common.Address, 0) + for _, node := range nodes { + primaryAddress, err := node.PrimaryEthAddress() + if err != nil { + return nil, err + } + addresses = append(addresses, common.HexToAddress(primaryAddress)) + } + return addresses, nil +} + +func DeployOCRContractsLocal( + numberOfContracts int, + linkTokenContract contracts.LinkToken, + contractDeployer contracts.ContractDeployer, + bootstrapNode *client.ChainlinkClient, + workerNodes []*client.ChainlinkClient, + client blockchain.EVMClient, +) ([]contracts.OffchainAggregator, error) { + // Deploy contracts + var ocrInstances []contracts.OffchainAggregator + for contractCount := 0; contractCount < numberOfContracts; contractCount++ { + ocrInstance, err := contractDeployer.DeployOffChainAggregator( + linkTokenContract.Address(), + contracts.DefaultOffChainAggregatorOptions(), + ) + if err != nil { + return nil, fmt.Errorf("OCR instance deployment have failed: %w", err) + } + ocrInstances = append(ocrInstances, ocrInstance) + if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("failed to wait for OCR contract deployments: %w", err) + } + } + } + err := client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("error waiting for OCR contract deployments: %w", err) + } + + // Gather transmitter and address payees + var transmitters, payees []string + for _, node := range workerNodes { + addr, err := node.PrimaryEthAddress() + if err != nil { + return nil, fmt.Errorf("error getting node's primary ETH address: %w", err) + } + transmitters = append(transmitters, addr) + payees = append(payees, client.GetDefaultWallet().Address()) + } + + // Set Payees + for contractCount, ocrInstance := range ocrInstances { + err = ocrInstance.SetPayees(transmitters, payees) + if err != nil { + return nil, fmt.Errorf("error settings OCR payees: %w", err) + } + if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("failed to wait for setting OCR payees: %w", err) + } + } + } + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("error waiting for OCR contracts to set payees and transmitters: %w", err) + } + + // Set Config + transmitterAddresses, err := ChainlinkNodeAddressesLocal(workerNodes) + if err != nil { + return nil, fmt.Errorf("getting node common addresses should not fail: %w", err) + } + for contractCount, ocrInstance := range ocrInstances { + // Exclude the first node, which will be used as a bootstrapper + err = ocrInstance.SetConfigLocal( + workerNodes, + contracts.DefaultOffChainAggregatorConfig(len(workerNodes)), + transmitterAddresses, + ) + if err != nil { + return nil, fmt.Errorf("error setting OCR config for contract '%s': %w", ocrInstance.Address(), err) + } + if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("failed to wait for setting OCR config: %w", err) + } + } + } + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("error waiting for OCR contracts to set config: %w", err) + } + return ocrInstances, nil +} + +func CreateOCRJobsLocal( + ocrInstances []contracts.OffchainAggregator, + bootstrapNode *client.ChainlinkClient, + workerNodes []*client.ChainlinkClient, + mockValue int, + mockserver *ctfClient.MockserverClient, +) error { + for _, ocrInstance := range ocrInstances { + bootstrapP2PIds, err := bootstrapNode.MustReadP2PKeys() + if err != nil { + return fmt.Errorf("reading P2P keys from bootstrap node have failed: %w", err) + } + bootstrapP2PId := bootstrapP2PIds.Data[0].Attributes.PeerID + bootstrapSpec := &client.OCRBootstrapJobSpec{ + Name: fmt.Sprintf("bootstrap-%s", uuid.New().String()), + ContractAddress: ocrInstance.Address(), + P2PPeerID: bootstrapP2PId, + IsBootstrapPeer: true, + } + _, err = bootstrapNode.MustCreateJob(bootstrapSpec) + if err != nil { + return fmt.Errorf("creating bootstrap job have failed: %w", err) + } + + for _, node := range workerNodes { + nodeP2PIds, err := node.MustReadP2PKeys() + if err != nil { + return fmt.Errorf("reading P2P keys from OCR node have failed: %w", err) + } + nodeP2PId := nodeP2PIds.Data[0].Attributes.PeerID + nodeTransmitterAddress, err := node.PrimaryEthAddress() + if err != nil { + return fmt.Errorf("getting primary ETH address from OCR node have failed: %w", err) + } + nodeOCRKeys, err := node.MustReadOCRKeys() + if err != nil { + return fmt.Errorf("getting OCR keys from OCR node have failed: %w", err) + } + nodeOCRKeyId := nodeOCRKeys.Data[0].ID + + nodeContractPairID, err := BuildNodeContractPairIDLocal(node, ocrInstance) + if err != nil { + return err + } + bta := &client.BridgeTypeAttributes{ + Name: nodeContractPairID, + URL: fmt.Sprintf("%s/%s", mockserver.Config.ClusterURL, strings.TrimPrefix(nodeContractPairID, "/")), + } + err = SetAdapterResponseLocal(mockValue, ocrInstance, node, mockserver) + if err != nil { + return fmt.Errorf("setting adapter response for OCR node failed: %w", err) + } + err = node.MustCreateBridge(bta) + if err != nil { + return fmt.Errorf("creating bridge job have failed: %w", err) + } + + bootstrapPeers := []*client.ChainlinkClient{bootstrapNode} + ocrSpec := &client.OCRTaskJobSpec{ + ContractAddress: ocrInstance.Address(), + P2PPeerID: nodeP2PId, + P2PBootstrapPeers: bootstrapPeers, + KeyBundleID: nodeOCRKeyId, + TransmitterAddress: nodeTransmitterAddress, + ObservationSource: client.ObservationSourceSpecBridge(bta), + } + _, err = node.MustCreateJob(ocrSpec) + if err != nil { + return fmt.Errorf("creating OCR task job on OCR node have failed: %w", err) + } + } + } + return nil +} + +func BuildNodeContractPairIDLocal(node *client.ChainlinkClient, ocrInstance contracts.OffchainAggregator) (string, error) { + if node == nil { + return "", fmt.Errorf("chainlink node is nil") + } + if ocrInstance == nil { + return "", fmt.Errorf("OCR Instance is nil") + } + nodeAddress, err := node.PrimaryEthAddress() + if err != nil { + return "", fmt.Errorf("getting chainlink node's primary ETH address failed: %w", err) + } + shortNodeAddr := nodeAddress[2:12] + shortOCRAddr := ocrInstance.Address()[2:12] + return strings.ToLower(fmt.Sprintf("node_%s_contract_%s", shortNodeAddr, shortOCRAddr)), nil +} + +func SetAdapterResponseLocal( + response int, + ocrInstance contracts.OffchainAggregator, + chainlinkNode *client.ChainlinkClient, + mockserver *ctfClient.MockserverClient, +) error { + nodeContractPairID, err := BuildNodeContractPairIDLocal(chainlinkNode, ocrInstance) + if err != nil { + return err + } + path := fmt.Sprintf("/%s", nodeContractPairID) + err = mockserver.SetValuePath(path, response) + if err != nil { + return fmt.Errorf("setting mockserver value path failed: %w", err) + } + return nil +} + +func SetAllAdapterResponsesToTheSameValueLocal( + response int, + ocrInstances []contracts.OffchainAggregator, + chainlinkNodes []*client.ChainlinkClient, + mockserver *ctfClient.MockserverClient, +) error { + eg := &errgroup.Group{} + for _, o := range ocrInstances { + ocrInstance := o + for _, n := range chainlinkNodes { + node := n + eg.Go(func() error { + return SetAdapterResponseLocal(response, ocrInstance, node, mockserver) + }) + } + } + return eg.Wait() +} diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index ba63d72e9f9..ce65864a803 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -138,6 +138,7 @@ type OffchainAggregator interface { Fund(nativeAmount *big.Float) error GetContractData(ctx context.Context) (*OffchainAggregatorData, error) SetConfig(chainlinkNodes []*client.ChainlinkK8sClient, ocrConfig OffChainAggregatorConfig, transmitters []common.Address) error + SetConfigLocal(chainlinkNodes []*client.ChainlinkClient, ocrConfig OffChainAggregatorConfig, transmitters []common.Address) error SetPayees([]string, []string) error RequestNewRound() error GetLatestAnswer(ctx context.Context) (*big.Int, error) diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index 794a5680f2d..32f989cd3e1 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -789,7 +789,7 @@ func (o *EthereumOffchainAggregator) SetConfig( return err } if len(ocrKeys.Data) == 0 { - return fmt.Errorf("no OCR keys found for node %s", node.ChartName) + return fmt.Errorf("no OCR keys found for node %v", node) } primaryOCRKey := ocrKeys.Data[0] if err != nil { diff --git a/integration-tests/contracts/ethereum_contracts_local.go b/integration-tests/contracts/ethereum_contracts_local.go new file mode 100644 index 00000000000..aba6bc354e1 --- /dev/null +++ b/integration-tests/contracts/ethereum_contracts_local.go @@ -0,0 +1,96 @@ +package contracts + +import ( + "encoding/hex" + "fmt" + "github.com/ethereum/go-ethereum/common" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/integration-tests/client" + ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" + ocrTypes "github.com/smartcontractkit/libocr/offchainreporting/types" +) + +// SetConfigLocal sets the payees and the offchain reporting protocol configuration +func (o *EthereumOffchainAggregator) SetConfigLocal( + chainlinkNodes []*client.ChainlinkClient, + ocrConfig OffChainAggregatorConfig, + transmitters []common.Address, +) error { + // Gather necessary addresses and keys from our chainlink nodes to properly configure the OCR contract + log.Info().Str("Contract Address", o.address.Hex()).Msg("Configuring OCR Contract") + for i, node := range chainlinkNodes { + ocrKeys, err := node.MustReadOCRKeys() + if err != nil { + return err + } + if len(ocrKeys.Data) == 0 { + return fmt.Errorf("no OCR keys found for node %v", node) + } + primaryOCRKey := ocrKeys.Data[0] + if err != nil { + return err + } + p2pKeys, err := node.MustReadP2PKeys() + if err != nil { + return err + } + primaryP2PKey := p2pKeys.Data[0] + + // Need to convert the key representations + var onChainSigningAddress [20]byte + var configPublicKey [32]byte + offchainSigningAddress, err := hex.DecodeString(primaryOCRKey.Attributes.OffChainPublicKey) + if err != nil { + return err + } + decodeConfigKey, err := hex.DecodeString(primaryOCRKey.Attributes.ConfigPublicKey) + if err != nil { + return err + } + + // https://stackoverflow.com/questions/8032170/how-to-assign-string-to-bytes-array + copy(onChainSigningAddress[:], common.HexToAddress(primaryOCRKey.Attributes.OnChainSigningAddress).Bytes()) + copy(configPublicKey[:], decodeConfigKey) + + oracleIdentity := ocrConfigHelper.OracleIdentity{ + TransmitAddress: transmitters[i], + OnChainSigningAddress: onChainSigningAddress, + PeerID: primaryP2PKey.Attributes.PeerID, + OffchainPublicKey: offchainSigningAddress, + } + oracleIdentityExtra := ocrConfigHelper.OracleIdentityExtra{ + OracleIdentity: oracleIdentity, + SharedSecretEncryptionPublicKey: ocrTypes.SharedSecretEncryptionPublicKey(configPublicKey), + } + + ocrConfig.OracleIdentities = append(ocrConfig.OracleIdentities, oracleIdentityExtra) + } + + signers, transmitters, threshold, encodedConfigVersion, encodedConfig, err := ocrConfigHelper.ContractSetConfigArgs( + ocrConfig.DeltaProgress, + ocrConfig.DeltaResend, + ocrConfig.DeltaRound, + ocrConfig.DeltaGrace, + ocrConfig.DeltaC, + ocrConfig.AlphaPPB, + ocrConfig.DeltaStage, + ocrConfig.RMax, + ocrConfig.S, + ocrConfig.OracleIdentities, + ocrConfig.F, + ) + if err != nil { + return err + } + + // Set Config + opts, err := o.client.TransactionOpts(o.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := o.ocr.SetConfig(opts, signers, transmitters, threshold, encodedConfigVersion, encodedConfig) + if err != nil { + return err + } + return o.client.ProcessTransaction(tx) +} diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 5c1545dd748..1bada7123aa 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -239,15 +239,19 @@ func (n *ClNode) StartContainer() error { if err != nil { return err } - + ip, err := container.ContainerIP(context.Background()) + if err != nil { + return err + } log.Info().Str("containerName", n.ContainerName). Str("clEndpoint", clEndpoint). + Str("clInternalIP", ip). Msg("Started Chainlink Node container") - clClient, err := client.NewChainlinkClient(&client.ChainlinkConfig{ - URL: clEndpoint, - Email: "local@local.com", - Password: "localdevpassword", + URL: clEndpoint, + Email: "local@local.com", + Password: "localdevpassword", + InternalIP: ip, }) if err != nil { return errors.Wrap(err, ErrConnectNodeClient) diff --git a/integration-tests/smoke/ocr_test.go b/integration-tests/smoke/ocr_test.go index 59bbdac6688..b9f2365bb72 100644 --- a/integration-tests/smoke/ocr_test.go +++ b/integration-tests/smoke/ocr_test.go @@ -1,112 +1,56 @@ package smoke import ( - "context" - "fmt" - "math/big" - "strings" "testing" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - + "context" "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/config" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/stretchr/testify/require" + "math/big" ) func TestOCRBasic(t *testing.T) { t.Parallel() - testEnvironment, testNetwork := setupOCRTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } - - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - bootstrapNode, workerNodes := chainlinkNodes[0], chainlinkNodes[1:] - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Creating mockserver clients shouldn't fail") + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(6). + WithFunding(big.NewFloat(10)). + Build() + require.NoError(t, err) + env.ParallelTransactions(true) - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - chainClient.ParallelTransactions(true) + nodeClients := env.GetAPIs() + bootstrapNode, workerNodes := nodeClients[0], nodeClients[1:] - linkTokenContract, err := contractDeployer.DeployLinkTokenContract() + linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodes(workerNodes, chainClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") - ocrInstances, err := actions.DeployOCRContracts(1, linkTokenContract, contractDeployer, bootstrapNode, workerNodes, chainClient) + ocrInstances, err := actions.DeployOCRContractsLocal(1, linkTokenContract, env.Geth.ContractDeployer, bootstrapNode, workerNodes, env.Geth.EthClient) require.NoError(t, err) - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") - err = actions.CreateOCRJobs(ocrInstances, bootstrapNode, workerNodes, 5, mockServer) + err = actions.CreateOCRJobsLocal(ocrInstances, bootstrapNode, workerNodes, 5, env.MockServer.Client) require.NoError(t, err) - err = actions.StartNewRound(1, ocrInstances, chainClient) + + _ = actions.StartNewRound(1, ocrInstances, env.Geth.EthClient) require.NoError(t, err) answer, err := ocrInstances[0].GetLatestAnswer(context.Background()) require.NoError(t, err, "Getting latest answer from OCR contract shouldn't fail") require.Equal(t, int64(5), answer.Int64(), "Expected latest answer from OCR contract to be 5 but got %d", answer.Int64()) - err = actions.SetAllAdapterResponsesToTheSameValue(10, ocrInstances, workerNodes, mockServer) + err = actions.SetAllAdapterResponsesToTheSameValueLocal(10, ocrInstances, workerNodes, env.MockServer.Client) require.NoError(t, err) - err = actions.StartNewRound(2, ocrInstances, chainClient) + err = actions.StartNewRound(2, ocrInstances, env.Geth.EthClient) require.NoError(t, err) answer, err = ocrInstances[0].GetLatestAnswer(context.Background()) require.NoError(t, err, "Error getting latest OCR answer") require.Equal(t, int64(10), answer.Int64(), "Expected latest answer from OCR contract to be 10 but got %d", answer.Int64()) } - -func setupOCRTest(t *testing.T) ( - testEnvironment *environment.Environment, - testNetwork blockchain.EVMNetwork, -) { - testNetwork = networks.SelectedNetwork - evmConfig := ethereum.New(nil) - if !testNetwork.Simulated { - evmConfig = ethereum.New(ðereum.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) - } - chainlinkChart, err := chainlink.NewDeployment(6, map[string]interface{}{ - "toml": client.AddNetworksConfig(config.BaseOCRP2PV1Config, testNetwork), - }) - require.NoError(t, err, "Error creating chainlink deployment") - - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-ocr-%s", strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(evmConfig). - AddHelmCharts(chainlinkChart) - err = testEnvironment.Run() - require.NoError(t, err, "Error running test environment") - return testEnvironment, testNetwork -} From 50d30757af82f1ab9c51343eda81ba5d15bc8b3c Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Wed, 9 Aug 2023 20:13:10 +0300 Subject: [PATCH 125/270] Integrate v3 types (#10118) * update ocr2keepers * core folder * fixes in core folder * logprovider package * evm21 folder (wip) * update ocr2keepers * align changes * transmit event provider * update dependency * really update dependency * fix upkeep state store errors * Rework feed lookup to use v3 types * build errors * encoder fix * registry test * log provider: fix int test * fix upkeep provider * fix errors * fix abi test * fix imports in delegate.go * Fix block subscriber test * update ocr2keepers * update dependency * fix goimports * Update encoder and transmit event tests * Fix go imports * Bump to latest keepers * bump ocr2keepers * Update ocr2keepers * fix registry test * Use a pointer to the check result in feed lookup so we can mutate the failure reason * Update payload and trigger test * extract testutil * update ocr2keepers everywhere * avoid creating multiple byte slices * update ocr2keepers * enrich tests * update to ocr2keepers tag * check upkeep id conversion result * fix trigger id on transmit events * cleanup trigger IDcleanup trigger IDcleanup trigger IDcleanup trigger IDcleanup trigger IDcleanup trigger IDcleanup trigger IDcleanup trigger IDcleanup trigger ID * Cleanup payload builder * Fix upkeep state store test * fix workID for transmit logs * change logs from Error to Warn --------- Co-authored-by: Akshay Aggarwal Co-authored-by: Fergal Gribben Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/services/ocr2/delegate.go | 49 +-- .../ocr2/plugins/ocr2keeper/evm21/abi.go | 20 +- .../ocr2/plugins/ocr2keeper/evm21/abi_test.go | 58 ++- .../ocr2keeper/evm21/block_subscriber.go | 7 +- .../ocr2keeper/evm21/block_subscriber_test.go | 58 ++- .../plugins/ocr2keeper/evm21/core/payload.go | 75 +--- .../ocr2keeper/evm21/core/payload_test.go | 166 ++++--- .../plugins/ocr2keeper/evm21/core/trigger.go | 17 +- .../ocr2keeper/evm21/core/trigger_test.go | 20 +- .../plugins/ocr2keeper/evm21/core/type.go | 19 +- .../ocr2keeper/evm21/core/type_test.go | 15 +- .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 179 +------- .../plugins/ocr2keeper/evm21/encoder_test.go | 408 ++---------------- .../plugins/ocr2keeper/evm21/feed_lookup.go | 49 +-- .../ocr2keeper/evm21/feed_lookup_test.go | 94 ++-- .../evm21/logprovider/integration_test.go | 14 +- .../ocr2keeper/evm21/logprovider/provider.go | 31 +- .../evm21/logprovider/provider_test.go | 14 +- .../ocr2keeper/evm21/logprovider/recoverer.go | 9 +- .../evm21/logprovider/recoverer_test.go | 11 +- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 69 +-- .../plugins/ocr2keeper/evm21/registry_test.go | 41 +- .../ocr2/plugins/ocr2keeper/evm21/testutil.go | 29 ++ .../evm21/transmit_event_provider.go | 60 ++- .../evm21/transmit_event_provider_test.go | 29 +- .../ocr2keeper/evm21/upkeep_provider.go | 26 +- .../ocr2keeper/evm21/upkeep_provider_test.go | 23 +- .../ocr2keeper/evm21/upkeep_state_store.go | 16 +- .../evm21/upkeep_state_store_test.go | 41 +- core/services/ocr2/plugins/ocr2keeper/util.go | 7 +- go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 36 files changed, 639 insertions(+), 1033 deletions(-) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go diff --git a/core/scripts/go.mod b/core/scripts/go.mod index ef34d7c9432..bb43820b416 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.5 + github.com/smartcontractkit/ocr2keepers v0.7.6 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 3fc15fa2680..88b190394fe 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= -github.com/smartcontractkit/ocr2keepers v0.7.5/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.6 h1:BIJGekJDHuvsKjqB2jCapNY+P16KypTLrAlsCcgkzZc= +github.com/smartcontractkit/ocr2keepers v0.7.6/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 462b2bba304..0ad12b6f981 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -9,20 +9,21 @@ import ( "math/big" "time" - "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" "gopkg.in/guregu/null.v4" "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" - "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" - "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" - "github.com/smartcontractkit/ocr2keepers/pkg/runner" "github.com/smartcontractkit/libocr/commontypes" libocr2 "github.com/smartcontractkit/libocr/offchainreporting2plus" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - "github.com/smartcontractkit/ocr2keepers/pkg/config" + ocr2keepers20 "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepersconfig "github.com/smartcontractkit/ocr2keepers/pkg/config" + ocr2keepers20coordinator "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" + ocr2keepers20polling "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" + ocr2keepers20runner "github.com/smartcontractkit/ocr2keepers/pkg/runner" + ocr2keepers21 "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" + ocr2keepers21types "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/ocr2vrf/altbn_128" dkgpkg "github.com/smartcontractkit/ocr2vrf/dkg" "github.com/smartcontractkit/ocr2vrf/ocr2vrf" @@ -879,11 +880,11 @@ func (d *Delegate) newServicesOCR2Keepers21( } // set some defaults - conf := config.ReportingFactoryConfig{ - CacheExpiration: config.DefaultCacheExpiration, - CacheEvictionInterval: config.DefaultCacheClearInterval, - MaxServiceWorkers: config.DefaultMaxServiceWorkers, - ServiceQueueLength: config.DefaultServiceQueueLength, + conf := ocr2keepersconfig.ReportingFactoryConfig{ + CacheExpiration: ocr2keepersconfig.DefaultCacheExpiration, + CacheEvictionInterval: ocr2keepersconfig.DefaultCacheClearInterval, + MaxServiceWorkers: ocr2keepersconfig.DefaultMaxServiceWorkers, + ServiceQueueLength: ocr2keepersconfig.DefaultServiceQueueLength, } // override if set in config @@ -903,7 +904,7 @@ func (d *Delegate) newServicesOCR2Keepers21( conf.ServiceQueueLength = cfg.ServiceQueueLength } - dConf := plugin.DelegateConfig{ + dConf := ocr2keepers21.DelegateConfig{ BinaryNetworkEndpointFactory: d.peerWrapper.Peer2, V2Bootstrappers: bootstrapPeers, ContractTransmitter: evmrelay.NewKeepersOCR3ContractTransmitter(keeperProvider.ContractTransmitter()), @@ -928,7 +929,7 @@ func (d *Delegate) newServicesOCR2Keepers21( UpkeepTypeGetter: ocr2keeper21core.GetUpkeepType, } - pluginService, err := plugin.NewDelegate(dConf) + pluginService, err := ocr2keepers21.NewDelegate(dConf) if err != nil { return nil, errors.Wrap(err, "could not create new keepers ocr2 delegate") } @@ -973,11 +974,11 @@ func (d *Delegate) newServicesOCR2Keepers20( w := &logWriter{log: lggr.Named("Automation Dependencies")} // set some defaults - conf := config.ReportingFactoryConfig{ - CacheExpiration: config.DefaultCacheExpiration, - CacheEvictionInterval: config.DefaultCacheClearInterval, - MaxServiceWorkers: config.DefaultMaxServiceWorkers, - ServiceQueueLength: config.DefaultServiceQueueLength, + conf := ocr2keepersconfig.ReportingFactoryConfig{ + CacheExpiration: ocr2keepersconfig.DefaultCacheExpiration, + CacheEvictionInterval: ocr2keepersconfig.DefaultCacheClearInterval, + MaxServiceWorkers: ocr2keepersconfig.DefaultMaxServiceWorkers, + ServiceQueueLength: ocr2keepersconfig.DefaultServiceQueueLength, } // override if set in config @@ -997,7 +998,7 @@ func (d *Delegate) newServicesOCR2Keepers20( conf.ServiceQueueLength = cfg.ServiceQueueLength } - runr, err2 := runner.NewRunner( + runr, err2 := ocr2keepers20runner.NewRunner( log.New(w, "[automation-plugin-runner] ", log.Lshortfile), rgstry, encoder, @@ -1010,7 +1011,7 @@ func (d *Delegate) newServicesOCR2Keepers20( return nil, errors.Wrap(err2, "failed to create automation pipeline runner") } - condObs := &polling.PollingObserverFactory{ + condObs := &ocr2keepers20polling.PollingObserverFactory{ Logger: log.New(w, "[automation-plugin-conditional-observer] ", log.Lshortfile), Source: rgstry, Heads: rgstry, @@ -1018,14 +1019,14 @@ func (d *Delegate) newServicesOCR2Keepers20( Encoder: encoder, } - coord := &coordinator.CoordinatorFactory{ + coord := &ocr2keepers20coordinator.CoordinatorFactory{ Logger: log.New(w, "[automation-plugin-coordinator] ", log.Lshortfile), Encoder: encoder, Logs: logProvider, CacheClean: conf.CacheEvictionInterval, } - dConf := ocr2keepers.DelegateConfig{ + dConf := ocr2keepers20.DelegateConfig{ BinaryNetworkEndpointFactory: d.peerWrapper.Peer2, V2Bootstrappers: bootstrapPeers, ContractTransmitter: keeperProvider.ContractTransmitter(), @@ -1048,7 +1049,7 @@ func (d *Delegate) newServicesOCR2Keepers20( ServiceQueueLength: cfg.ServiceQueueLength, } - pluginService, err := ocr2keepers.NewDelegate(dConf) + pluginService, err := ocr2keepers20.NewDelegate(dConf) if err != nil { return nil, errors.Wrap(err, "could not create new keepers ocr2 delegate") } @@ -1252,6 +1253,6 @@ func (l *logWriter) Write(p []byte) (n int, err error) { type mockRecoverableProvider struct { } -func (_m *mockRecoverableProvider) GetRecoverables() ([]ocr2keepers.UpkeepPayload, error) { +func (_m *mockRecoverableProvider) GetRecoveryProposals(ctx context.Context) ([]ocr2keepers21types.UpkeepPayload, error) { return nil, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go index c427bd4d5f9..d012d64396a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go @@ -6,7 +6,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -49,7 +49,7 @@ func NewEvmRegistryPackerV2_1(abi abi.ABI, utilsAbi abi.ABI) *evmRegistryPackerV return &evmRegistryPackerV2_1{abi: abi, utilsAbi: utilsAbi} } -func (rp *evmRegistryPackerV2_1) UnpackCheckResult(key ocr2keepers.UpkeepPayload, raw string) (ocr2keepers.CheckResult, error) { +func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, raw string) (ocr2keepers.CheckResult, error) { var result ocr2keepers.CheckResult b, err := hexutil.Decode(raw) @@ -63,21 +63,21 @@ func (rp *evmRegistryPackerV2_1) UnpackCheckResult(key ocr2keepers.UpkeepPayload } result = ocr2keepers.CheckResult{ - Eligible: *abi.ConvertType(out[0], new(bool)).(*bool), - Retryable: false, - GasAllocated: uint64((*abi.ConvertType(out[4], new(*big.Int)).(**big.Int)).Int64()), - Payload: key, - } - ext := EVMAutomationResultExtension21{ + Eligible: *abi.ConvertType(out[0], new(bool)).(*bool), + Retryable: false, + GasAllocated: uint64((*abi.ConvertType(out[4], new(*big.Int)).(**big.Int)).Int64()), + UpkeepID: p.UpkeepID, + Trigger: p.Trigger, + WorkID: p.WorkID, FastGasWei: *abi.ConvertType(out[5], new(*big.Int)).(**big.Int), LinkNative: *abi.ConvertType(out[6], new(*big.Int)).(**big.Int), FailureReason: *abi.ConvertType(out[2], new(uint8)).(*uint8), } - result.Extension = ext + rawPerformData := *abi.ConvertType(out[1], new([]byte)).(*[]byte) // if NONE we expect the perform data. if TARGET_CHECK_REVERTED we will have the error data in the perform data used for off chain lookup - if ext.FailureReason == UPKEEP_FAILURE_REASON_NONE || (ext.FailureReason == UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED && len(rawPerformData) > 0) { + if result.FailureReason == UPKEEP_FAILURE_REASON_NONE || (result.FailureReason == UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED && len(rawPerformData) > 0) { result.PerformData = rawPerformData } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go index 7461b05b953..e5507277da2 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go @@ -8,7 +8,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" automation21Utils "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -17,50 +17,43 @@ import ( ) func TestUnpackCheckResults(t *testing.T) { - upkeepId, _ := new(big.Int).SetString("1843548457736589226156809205796175506139185429616502850435279853710366065936", 10) - payload1, _ := core.NewUpkeepPayload(upkeepId, 0, ocr2keepers.NewTrigger(19447615, "0x0", struct{}{}), []byte{}) - payload2, _ := core.NewUpkeepPayload(upkeepId, 0, ocr2keepers.NewTrigger(19448272, "0x0", struct{}{}), []byte{}) + uid, _ := new(big.Int).SetString("1843548457736589226156809205796175506139185429616502850435279853710366065936", 10) + upkeepId := ocr2keepers.UpkeepIdentifier{} + upkeepId.FromBigInt(uid) + payload1, _ := core.NewUpkeepPayload(uid, ocr2keepers.NewTrigger(19447615, common.HexToHash("0x0")), []byte{}) + + payload2, _ := core.NewUpkeepPayload(uid, ocr2keepers.NewTrigger(19448272, common.HexToHash("0x0")), []byte{}) tests := []struct { Name string Payload ocr2keepers.UpkeepPayload RawData string - ExpectedResult EVMAutomationUpkeepResult21 + ExpectedResult ocr2keepers.CheckResult }{ { Name: "upkeep not needed", Payload: payload1, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000421c000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000000", - ExpectedResult: EVMAutomationUpkeepResult21{ - Block: 19447615, - ID: upkeepId, - Eligible: false, - FailureReason: UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED, - GasUsed: big.NewInt(16924), - PerformData: nil, - FastGasWei: big.NewInt(1000000000), - LinkNative: big.NewInt(3532383906411401), - CheckBlockNumber: 0, - CheckBlockHash: [32]byte{}, - ExecuteGas: 5000000, + ExpectedResult: ocr2keepers.CheckResult{ + UpkeepID: upkeepId, + Eligible: false, + FailureReason: UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED, + PerformData: nil, + FastGasWei: big.NewInt(1000000000), + LinkNative: big.NewInt(3532383906411401), }, }, { Name: "target check reverted", Payload: payload2, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000007531000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000008914039bf676e20aad43a5642485e666575ed0d927a4b5679745e947e7d125ee2687c10000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000024462e8a50d00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000128c1d000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000009666565644944537472000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000184554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000000000184254432d5553442d415242495452554d2d544553544e45540000000000000000000000000000000000000000000000000000000000000000000000000000000b626c6f636b4e756d6265720000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000006400000000000000000000000000000000000000000000000000000000000000000000000000000000", - ExpectedResult: EVMAutomationUpkeepResult21{ - Block: 19448272, - ID: upkeepId, - Eligible: false, - FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, - GasUsed: big.NewInt(30001), - PerformData: []byte{98, 232, 165, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 193, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 68, 83, 116, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 66, 84, 67, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - FastGasWei: big.NewInt(1000000000), - LinkNative: big.NewInt(3532383906411401), - CheckBlockNumber: 8983555, - CheckBlockHash: [32]byte{155, 246, 118, 226, 10, 173, 67, 165, 100, 36, 133, 230, 102, 87, 94, 208, 217, 39, 164, 181, 103, 151, 69, 233, 71, 231, 209, 37, 238, 38, 135, 193}, - ExecuteGas: 5000000, + ExpectedResult: ocr2keepers.CheckResult{ + UpkeepID: upkeepId, + Eligible: false, + FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + PerformData: []byte{98, 232, 165, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 193, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 68, 83, 116, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 66, 84, 67, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + FastGasWei: big.NewInt(1000000000), + LinkNative: big.NewInt(3532383906411401), }, }, } @@ -70,12 +63,9 @@ func TestUnpackCheckResults(t *testing.T) { assert.NoError(t, err) rs, err := packer.UnpackCheckResult(test.Payload, test.RawData) assert.Nil(t, err) - assert.Equal(t, test.ExpectedResult.Block, uint32(rs.Payload.Trigger.BlockNumber)) - assert.Equal(t, ocr2keepers.UpkeepIdentifier(test.ExpectedResult.ID.Bytes()), rs.Payload.Upkeep.ID) + assert.Equal(t, test.ExpectedResult.UpkeepID, rs.UpkeepID) assert.Equal(t, test.ExpectedResult.Eligible, rs.Eligible) - ext, ok := rs.Extension.(EVMAutomationResultExtension21) - assert.True(t, ok) - assert.Equal(t, test.ExpectedResult.FailureReason, ext.FailureReason) + assert.Equal(t, test.ExpectedResult.FailureReason, rs.FailureReason) }) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go index d8f7b3d5da4..0d0e381d0a6 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go @@ -7,7 +7,7 @@ import ( "time" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" @@ -32,7 +32,10 @@ type BlockKey struct { } func (bk *BlockKey) getBlockKey() ocr2keepers.BlockKey { - return ocr2keepers.BlockKey(fmt.Sprintf("%d%s%s", bk.block, BlockKeySeparator, bk.hash.Hex())) + return ocr2keepers.BlockKey{ + Number: ocr2keepers.BlockNumber(bk.block), + Hash: bk.hash, + } } type BlockSubscriber struct { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go index a34d7aac8d6..358bfeffa3c 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go @@ -7,7 +7,7 @@ import ( "time" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" @@ -184,9 +184,18 @@ func TestBlockSubscriber_BuildHistory(t *testing.T) { }, Block: 100, ExpectedHistory: ocr2keepers.BlockHistory{ - "100|0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b", - "98|0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", - "97|0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe", + ocr2keepers.BlockKey{ + Number: 100, + Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + }, + ocr2keepers.BlockKey{ + Number: 98, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + ocr2keepers.BlockKey{ + Number: 97, + Hash: common.HexToHash("0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe"), + }, }, }, } @@ -299,7 +308,16 @@ func TestBlockSubscriber_Start(t *testing.T) { time.Sleep(100 * time.Millisecond) bk1 := <-c1 - assert.Equal(t, ocr2keepers.BlockHistory{"101|0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", "100|0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"}, bk1) + assert.Equal(t, ocr2keepers.BlockHistory{ + ocr2keepers.BlockKey{ + Number: 101, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + ocr2keepers.BlockKey{ + Number: 100, + Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + }, + }, bk1) // add 2nd subscriber subId2, c2, err := bs.Subscribe() @@ -314,12 +332,38 @@ func TestBlockSubscriber_Start(t *testing.T) { time.Sleep(100 * time.Millisecond) bk1 = <-c1 assert.Equal(t, - ocr2keepers.BlockHistory{"103|0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", "101|0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", "100|0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"}, + ocr2keepers.BlockHistory{ + ocr2keepers.BlockKey{ + Number: 103, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + ocr2keepers.BlockKey{ + Number: 101, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + ocr2keepers.BlockKey{ + Number: 100, + Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + }, + }, bk1, ) bk2 := <-c2 assert.Equal(t, - ocr2keepers.BlockHistory{"103|0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", "101|0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", "100|0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"}, + ocr2keepers.BlockHistory{ + ocr2keepers.BlockKey{ + Number: 103, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + ocr2keepers.BlockKey{ + Number: 101, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + ocr2keepers.BlockKey{ + Number: 100, + Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + }, + }, bk2, ) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go index bc4e9ebe3c8..f37a8ee94e6 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go @@ -2,83 +2,50 @@ package core import ( "encoding/hex" - "encoding/json" "fmt" "math/big" - "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" ) -// UpkeepTriggerID returns the identifier using the given upkeepID and trigger. -// It follows the same logic as the contract, but performs it locally. -func UpkeepTriggerID(id *big.Int, trigger []byte) string { - idBytes := append(id.Bytes(), trigger...) - triggerIDBytes := crypto.Keccak256(idBytes) - return hex.EncodeToString(triggerIDBytes) -} +var ( + ErrInvalidUpkeepID = fmt.Errorf("invalid upkeepID") +) // UpkeepWorkID returns the identifier using the given upkeepID and trigger extension(tx hash and log index). func UpkeepWorkID(id *big.Int, trigger ocr2keepers.Trigger) (string, error) { - extensionBytes, err := json.Marshal(trigger.Extension) - if err != nil { - return "", err + var triggerExtBytes []byte + if trigger.LogTriggerExtension != nil { + triggerExtBytes = trigger.LogTriggerExtension.LogIdentifier() + } + uid := &ocr2keepers.UpkeepIdentifier{} + ok := uid.FromBigInt(id) + if !ok { + return "", ErrInvalidUpkeepID } - // TODO (auto-4314): Ensure it works with conditionals and add unit tests - combined := fmt.Sprintf("%s%s", id, extensionBytes) - hash := crypto.Keccak256([]byte(combined)) + hash := crypto.Keccak256(append(uid[:], triggerExtBytes...)) return hex.EncodeToString(hash[:]), nil } -func NewUpkeepPayload(uid *big.Int, tp int, trigger ocr2keepers.Trigger, checkData []byte) (ocr2keepers.UpkeepPayload, error) { - // construct payload +func NewUpkeepPayload(id *big.Int, trigger ocr2keepers.Trigger, checkData []byte) (ocr2keepers.UpkeepPayload, error) { + uid := &ocr2keepers.UpkeepIdentifier{} + ok := uid.FromBigInt(id) + if !ok { + return ocr2keepers.UpkeepPayload{}, ErrInvalidUpkeepID + } p := ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(uid.Bytes()), - Type: tp, - Config: struct{}{}, // empty struct by default - }, + UpkeepID: *uid, Trigger: trigger, CheckData: checkData, } // set work id based on upkeep id and trigger - wid, err := UpkeepWorkID(uid, trigger) + wid, err := UpkeepWorkID(id, trigger) if err != nil { return ocr2keepers.UpkeepPayload{}, fmt.Errorf("error while generating workID: %w", err) } p.WorkID = wid - // manually convert trigger to triggerWrapper - triggerW := triggerWrapper{ - BlockNum: uint32(trigger.BlockNumber), - BlockHash: common.HexToHash(trigger.BlockHash), - } - - switch ocr2keepers.UpkeepType(tp) { - case ocr2keepers.LogTrigger: - trExt, ok := trigger.Extension.(LogTriggerExtension) - if !ok { - return ocr2keepers.UpkeepPayload{}, fmt.Errorf("unrecognized trigger extension data") - } - hex, parseErr := common.ParseHexOrString(trExt.TxHash) - if parseErr != nil { - return ocr2keepers.UpkeepPayload{}, fmt.Errorf("tx hash parse error: %w", err) - } - triggerW.TxHash = common.BytesToHash(hex[:]) - triggerW.LogIndex = uint32(trExt.LogIndex) - default: - } - - // get trigger in bytes - triggerBytes, err := PackTrigger(uid, triggerW) - if err != nil { - return ocr2keepers.UpkeepPayload{}, fmt.Errorf("%w: failed to pack trigger", err) - } - - // set trigger id based on upkeep id and trigger - p.ID = UpkeepTriggerID(uid, triggerBytes) - // end return p, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go index 61805d3d61a..afb0d77a3fb 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go @@ -1,74 +1,136 @@ package core import ( - "encoding/hex" "math/big" "testing" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + "github.com/ethereum/go-ethereum/common" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" ) -func TestTriggerID(t *testing.T) { - upkeepIDStr := "82566255084862886500628610724995377215109748679571001950554849251333329872882" - // Convert the string to a big.Int - var upkeepID big.Int - _, success := upkeepID.SetString(upkeepIDStr, 10) - if !success { - t.Fatal("Invalid big integer value") - } - - triggerStr := "deadbeef" - triggerBytes, err := hex.DecodeString(triggerStr) - if err != nil { - t.Fatalf("Error decoding hex string: %s", err) - } - - res := UpkeepTriggerID(&upkeepID, triggerBytes) - - expectedResult := "fe466794c97e8b54ca25b696ff3ee448a7d03e4a82a2e45d9d84de62ef4cc260" - assert.Equal(t, res, expectedResult, "UpkeepTriggerID mismatch") -} - func TestWorkID(t *testing.T) { - id := big.NewInt(12345) - trigger := ocr2keepers.Trigger{ - BlockNumber: 123, - BlockHash: "0xabcdef", - Extension: map[string]interface{}{ - "txHash": "0xdeadbeef", - "logIndex": "123", + tests := []struct { + name string + upkeepID string + trigger ocr2keepers.Trigger + expected string + errored bool + }{ + { + name: "happy flow no extension", + upkeepID: "12345", + trigger: ocr2keepers.Trigger{ + BlockNumber: 123, + BlockHash: common.HexToHash("0xabcdef"), + }, + expected: "e546b0a52c2879744f6def0fb483d581dc6d205de83af8440456804dd8b62380", + }, + { + name: "empty trigger", + upkeepID: "12345", + trigger: ocr2keepers.Trigger{}, + // same as with no extension + expected: "e546b0a52c2879744f6def0fb483d581dc6d205de83af8440456804dd8b62380", + }, + { + name: "happy flow with extension", + upkeepID: genUpkeepID(ocr2keepers.LogTrigger, "12345").String(), + trigger: ocr2keepers.Trigger{ + BlockNumber: 123, + BlockHash: common.HexToHash("0xabcdef"), + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + Index: 1, + TxHash: common.HexToHash("0x12345"), + }, + }, + expected: "91ace35299de40860e17d31adbc64bee48f437362cedd3b69ccf749a2f38d8e5", + }, + { + name: "empty upkeepID", + upkeepID: "0", + trigger: ocr2keepers.Trigger{ + BlockNumber: 123, + BlockHash: common.HexToHash("0xabcdef"), + }, + expected: "290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563", }, } - res, err := UpkeepWorkID(id, trigger) - if err != nil { - t.Fatalf("Error computing UpkeepWorkID: %s", err) - } + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + // Convert the string to a big.Int + var upkeepID big.Int + _, success := upkeepID.SetString(tc.upkeepID, 10) + if !success { + t.Fatal("Invalid big integer value") + } - expectedResult := "182244f3e4fa6e9556a17b84718b7ffe19f0d67a811d771bd5479fe16e02bf82" - assert.Equal(t, res, expectedResult, "UpkeepWorkID mismatch") + res, err := UpkeepWorkID(&upkeepID, tc.trigger) + if tc.errored { + assert.Error(t, err) + return + } + assert.NoError(t, err) + + assert.Equal(t, tc.expected, res, "UpkeepWorkID mismatch") + }) + } } func TestNewUpkeepPayload(t *testing.T) { - logExt := LogTriggerExtension{ - LogIndex: 1, - TxHash: "0x1234567890123456789012345678901234567890123456789012345678901234", + tests := []struct { + name string + upkeepID *big.Int + upkeepType ocr2keepers.UpkeepType + trigger ocr2keepers.Trigger + check []byte + errored bool + workID string + }{ + { + name: "happy flow no extension", + upkeepID: big.NewInt(111), + upkeepType: ocr2keepers.ConditionTrigger, + trigger: ocr2keepers.Trigger{ + BlockNumber: 11, + BlockHash: common.HexToHash("0x11111"), + }, + check: []byte("check-data-111"), + workID: "39f2babe526038520877fc7c33d81accf578af4a06c5fa6b0d038cae36e12711", + }, + { + name: "happy flow with extension", + upkeepID: big.NewInt(111), + upkeepType: ocr2keepers.LogTrigger, + trigger: ocr2keepers.Trigger{ + BlockNumber: 11, + BlockHash: common.HexToHash("0x11111"), + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + Index: 1, + TxHash: common.HexToHash("0x11111"), + }, + }, + check: []byte("check-data-111"), + workID: "9fd4d46e09ad25e831fdee664dbaa3b68c37034303234bf70001e3577af43a4f", + }, } - payload, err := NewUpkeepPayload( - big.NewInt(111), - 1, - ocr2keepers.Trigger{ - BlockNumber: 11, - BlockHash: "0x11111", - Extension: logExt, - }, - []byte("check-data-111"), - ) - if err != nil { - t.Fatal(err) + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + payload, err := NewUpkeepPayload( + tc.upkeepID, + tc.trigger, + tc.check, + ) + if tc.errored { + assert.Error(t, err) + return + } + assert.NoError(t, err) + + assert.Equal(t, tc.workID, payload.WorkID) + }) } - assert.Equal(t, "151b4fd0c9f8d97307938fb7d64d6efbc821891a0eb9ae2708ccfe98e1706b40", payload.ID) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go index c7a5295fd14..9999aefbd25 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger.go @@ -7,7 +7,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" ) @@ -16,11 +16,6 @@ type triggerWrapper = automation_utils_2_1.KeeperRegistryBase21LogTrigger var ErrABINotParsable = fmt.Errorf("error parsing abi") -type LogTriggerExtension struct { - TxHash string - LogIndex int64 -} - // according to the upkeep type of the given id. func PackTrigger(id *big.Int, trig triggerWrapper) ([]byte, error) { var trigger []byte @@ -33,7 +28,10 @@ func PackTrigger(id *big.Int, trig triggerWrapper) ([]byte, error) { } // pack trigger based on upkeep type - upkeepType := GetUpkeepType(id.Bytes()) + upkeepType, ok := getUpkeepTypeFromBigInt(id) + if !ok { + return nil, ErrInvalidUpkeepID + } switch upkeepType { case ocr2keepers.ConditionTrigger: trig := automation_utils_2_1.KeeperRegistryBase21ConditionalTrigger{ @@ -66,7 +64,10 @@ func UnpackTrigger(id *big.Int, raw []byte) (triggerWrapper, error) { return triggerWrapper{}, fmt.Errorf("%w: %s", ErrABINotParsable, err) } - upkeepType := GetUpkeepType(id.Bytes()) + upkeepType, ok := getUpkeepTypeFromBigInt(id) + if !ok { + return triggerWrapper{}, ErrInvalidUpkeepID + } switch upkeepType { case ocr2keepers.ConditionTrigger: unpacked, err := utilsABI.Methods["_conditionalTrigger"].Inputs.Unpack(raw) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go index 4f682c4fb69..5fa5ae5c910 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/trigger_test.go @@ -7,14 +7,14 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" ) func TestPackUnpackTrigger(t *testing.T) { tests := []struct { name string - id ocr2keepers.UpkeepIdentifier + id []byte trigger triggerWrapper encoded []byte err error @@ -61,16 +61,17 @@ func TestPackUnpackTrigger(t *testing.T) { for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { - id, ok := big.NewInt(0).SetString(hexutil.Encode(tc.id)[2:], 16) - assert.True(t, ok) + var idBytes [32]byte + copy(idBytes[:], tc.id) + id := ocr2keepers.UpkeepIdentifier(idBytes) - encoded, err := PackTrigger(id, tc.trigger) + encoded, err := PackTrigger(id.BigInt(), tc.trigger) if tc.err != nil { assert.EqualError(t, err, tc.err.Error()) } else { assert.NoError(t, err) assert.Equal(t, tc.encoded, encoded) - decoded, err := UnpackTrigger(id, encoded) + decoded, err := UnpackTrigger(id.BigInt(), encoded) assert.NoError(t, err) assert.Equal(t, tc.trigger.BlockNum, decoded.BlockNum) } @@ -84,10 +85,11 @@ func TestPackUnpackTrigger(t *testing.T) { t.Run("unpacking unknown type", func(t *testing.T) { uid := append([]byte{1}, common.LeftPadBytes([]byte{8}, 15)...) - id, ok := big.NewInt(0).SetString(hexutil.Encode(uid)[2:], 16) - assert.True(t, ok) + var idBytes [32]byte + copy(idBytes[:], uid) + id := ocr2keepers.UpkeepIdentifier(idBytes) decoded, _ := hexutil.Decode("0x00000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") - _, err := UnpackTrigger(id, decoded) + _, err := UnpackTrigger(id.BigInt(), decoded) assert.EqualError(t, err, "unknown trigger type: 8") }) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go index c850f60d6e7..aeb56a16f62 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type.go @@ -3,7 +3,7 @@ package core import ( "math/big" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" ) const ( @@ -17,18 +17,7 @@ const ( // GetUpkeepType returns the upkeep type from the given ID. // it follows the same logic as the contract, but performs it locally. -// -// TODO: check endianness func GetUpkeepType(id ocr2keepers.UpkeepIdentifier) ocr2keepers.UpkeepType { - // TODO: auto-4319: Ensure consistent definition of string vs bytes for UpkeepID - // and ensure bytes are zero padded for small integers - if len(id) < upkeepTypeByteIndex+1 { - return ocr2keepers.ConditionTrigger - } - idx, ok := big.NewInt(0).SetString(string(id), 10) - if ok { - id = ocr2keepers.UpkeepIdentifier(idx.Bytes()) - } for i := upkeepTypeStartIndex; i < upkeepTypeByteIndex; i++ { if id[i] != 0 { // old id return ocr2keepers.ConditionTrigger @@ -37,3 +26,9 @@ func GetUpkeepType(id ocr2keepers.UpkeepIdentifier) ocr2keepers.UpkeepType { typeByte := id[upkeepTypeByteIndex] return ocr2keepers.UpkeepType(typeByte) } + +func getUpkeepTypeFromBigInt(id *big.Int) (ocr2keepers.UpkeepType, bool) { + uid := &ocr2keepers.UpkeepIdentifier{} + ok := uid.FromBigInt(id) + return GetUpkeepType(*uid), ok +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go index 0c4219e6505..dd313a30078 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" ) @@ -13,7 +13,7 @@ import ( func TestGetUpkeepType(t *testing.T) { tests := []struct { name string - upkeepID ocr2keepers.UpkeepIdentifier + upkeepID []byte upkeepType ocr2keepers.UpkeepType }{ { @@ -31,11 +31,6 @@ func TestGetUpkeepType(t *testing.T) { genUpkeepID(ocr2keepers.ConditionTrigger, "").Bytes(), ocr2keepers.ConditionTrigger, }, - { - "log trigger string", - []byte(genUpkeepID(ocr2keepers.LogTrigger, "111").String()), - ocr2keepers.LogTrigger, - }, { "log trigger", genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes(), @@ -43,7 +38,7 @@ func TestGetUpkeepType(t *testing.T) { }, { "log trigger id", - func() ocr2keepers.UpkeepIdentifier { + func() []byte { id, _ := big.NewInt(0).SetString("32329108151019397958065800113404894502874153543356521479058624064899121404671", 10) return id.Bytes() }(), @@ -53,7 +48,9 @@ func TestGetUpkeepType(t *testing.T) { for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { - assert.Equal(t, tc.upkeepType, GetUpkeepType(tc.upkeepID)) + uid := ocr2keepers.UpkeepIdentifier{} + copy(uid[:], tc.upkeepID) + assert.Equal(t, tc.upkeepType, GetUpkeepType(uid)) }) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index a6be18e8699..42d08461d89 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -1,13 +1,11 @@ package evm import ( - "encoding/json" "fmt" "math/big" - "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" "github.com/smartcontractkit/ocr2keepers/pkg/encoding" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" @@ -22,31 +20,6 @@ type EVMAutomationEncoder21 struct { packer *evmRegistryPackerV2_1 } -type EVMAutomationUpkeepResult21 struct { - // Block is the block number used to build an UpkeepKey for this result - Block uint32 - // ID is the unique identifier for the upkeep - ID *big.Int - Eligible bool - FailureReason uint8 - GasUsed *big.Int - PerformData []byte - FastGasWei *big.Int - LinkNative *big.Int - // CheckBlockNumber is the block number that the contract indicates the - // upkeep was checked on - CheckBlockNumber uint32 - CheckBlockHash [32]byte - ExecuteGas uint32 - Retryable bool -} - -type EVMAutomationResultExtension21 struct { - FastGasWei *big.Int - LinkNative *big.Int - FailureReason uint8 // this is not encoded, only pass along for the purpose of pipeline run -} - func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([]byte, error) { if len(results) == 0 { return nil, ErrEmptyResults @@ -63,52 +36,26 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] highestCheckBlock := big.NewInt(0) for i, result := range results { - result := result - if err := decodeExtensions(&result); err != nil { - return nil, err - } - - ext, ok := result.Extension.(EVMAutomationResultExtension21) - if !ok { - // decodeExtensions should catch this, but in the case it doesn't ... - return nil, fmt.Errorf("unexpected check result extension struct") - } - - checkBlock := big.NewInt(result.Payload.Trigger.BlockNumber) + checkBlock := big.NewInt(int64(result.Trigger.BlockNumber)) if checkBlock.Cmp(highestCheckBlock) == 1 { highestCheckBlock = checkBlock - report.FastGasWei = ext.FastGasWei - report.LinkNative = ext.LinkNative + report.FastGasWei = result.FastGasWei + report.LinkNative = result.LinkNative } - id, ok := big.NewInt(0).SetString(string(result.Payload.Upkeep.ID), 10) - if !ok { - // TODO auto 4204: handle properly, this is just for happy path - id = big.NewInt(0).SetBytes(result.Payload.Upkeep.ID) - } + id := result.UpkeepID.BigInt() report.UpkeepIds[i] = id report.GasLimits[i] = big.NewInt(0).SetUint64(result.GasAllocated) triggerW := triggerWrapper{ - BlockNum: uint32(result.Payload.Trigger.BlockNumber), - BlockHash: common.HexToHash(result.Payload.Trigger.BlockHash), + BlockNum: uint32(result.Trigger.BlockNumber), + BlockHash: result.Trigger.BlockHash, } - switch core.GetUpkeepType(id.Bytes()) { + switch core.GetUpkeepType(result.UpkeepID) { case ocr2keepers.LogTrigger: - trExt, ok := result.Payload.Trigger.Extension.(core.LogTriggerExtension) - if !ok { - // decodeExtensions should catch this, but in the case it doesn't ... - return nil, fmt.Errorf("unrecognized trigger extension data") - } - - hex, err := common.ParseHexOrString(trExt.TxHash) - if err != nil { - return nil, fmt.Errorf("tx hash parse error: %w", err) - } - - triggerW.TxHash = common.BytesToHash(hex[:]) - triggerW.LogIndex = uint32(trExt.LogIndex) + triggerW.TxHash = result.Trigger.LogTriggerExtension.TxHash + triggerW.LogIndex = result.Trigger.LogTriggerExtension.Index default: // no special handling here for conditional triggers } @@ -142,107 +89,27 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk // TODO: log error and continue instead? return nil, fmt.Errorf("%w: failed to unpack trigger", err) } - logExt := core.LogTriggerExtension{} + id := &ocr2keepers.UpkeepIdentifier{} + id.FromBigInt(upkeepId) - switch core.GetUpkeepType(upkeepId.Bytes()) { + trigger := ocr2keepers.NewTrigger( + ocr2keepers.BlockNumber(triggerW.BlockNum), + triggerW.BlockHash, + ) + switch core.GetUpkeepType(*id) { case ocr2keepers.LogTrigger: - logExt.TxHash = common.BytesToHash(triggerW.TxHash[:]).Hex() - logExt.LogIndex = int64(triggerW.LogIndex) + trigger.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{} + trigger.LogTriggerExtension.TxHash = triggerW.TxHash + trigger.LogTriggerExtension.Index = triggerW.LogIndex default: } - trigger := ocr2keepers.NewTrigger( - int64(triggerW.BlockNum), - common.BytesToHash(triggerW.BlockHash[:]).Hex(), - logExt, - ) - id := core.UpkeepTriggerID(upkeepId, report.Triggers[i]) workID, _ := core.UpkeepWorkID(upkeepId, trigger) reportedUpkeeps[i] = ocr2keepers.ReportedUpkeep{ - ID: id, - WorkID: workID, - UpkeepID: ocr2keepers.UpkeepIdentifier(upkeepId.String()), - Trigger: trigger, - PerformData: report.PerformDatas[i], + WorkID: workID, + UpkeepID: *id, + Trigger: trigger, } } return reportedUpkeeps, nil } - -type BlockKeyHelper[T uint32 | int64] struct { -} - -func (kh BlockKeyHelper[T]) MakeBlockKey(b T) ocr2keepers.BlockKey { - return ocr2keepers.BlockKey(fmt.Sprintf("%d", b)) -} - -type UpkeepKeyHelper[T uint32 | int64] struct { -} - -func (kh UpkeepKeyHelper[T]) MakeUpkeepKey(b T, id *big.Int) ocr2keepers.UpkeepKey { - return ocr2keepers.UpkeepKey(fmt.Sprintf("%d%s%s", b, separator, id)) -} - -func decodeExtensions(result *ocr2keepers.CheckResult) error { - if result == nil { - return fmt.Errorf("non-nil value expected in decoding") - } - - rC := *result - - // decode the trigger extension data if not decoded - switch typedExt := rC.Payload.Trigger.Extension.(type) { - case core.LogTriggerExtension: - // no decoding required - break - case []byte: - switch core.GetUpkeepType(result.Payload.Upkeep.ID) { - case ocr2keepers.LogTrigger: - var ext core.LogTriggerExtension - - // in the case of a string, the value is probably still json - // encoded and coming from a plugin outcome - if err := json.Unmarshal(typedExt, &ext); err != nil { - return fmt.Errorf("%w: json encoded values do not match LogTriggerExtension struct: %s", err, string(typedExt)) - } - - result.Payload.Trigger.Extension = ext - case ocr2keepers.ConditionTrigger: - // no special handling for conditional triggers - break - default: - return fmt.Errorf("unknown upkeep type") - } - case struct{}, nil: - // empty fallback - break - default: - return fmt.Errorf("unrecognized trigger extension data") - } - - // decode the result extension data if not decoded - switch typedExt := result.Extension.(type) { - case EVMAutomationResultExtension21: - // no decoding required - break - case []byte: - var ext EVMAutomationResultExtension21 - - // in the case of a string, the value is probably still json - // encoded and coming from a plugin outcome - if err := json.Unmarshal(typedExt, &ext); err != nil { - return fmt.Errorf("%w: json encoded values do not match EVMAutomationResultExtension21 struct", err) - } - - result.Extension = ext - case struct{}, nil: - // empty fallback - break - default: - return fmt.Errorf("unrecognized CheckResult extension data") - } - - // TODO: decode upkeep config data if not decoded - - return nil -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go index 77c11ff7fce..241d3396d93 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go @@ -1,16 +1,13 @@ package evm import ( - "errors" - "fmt" "math/big" "strings" "testing" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -18,7 +15,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) -func TestEVMAutomationEncoder21_Encode(t *testing.T) { +func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) assert.Nil(t, err) utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) @@ -38,9 +35,9 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { { "happy flow single", []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "10").String()), 1, 1), + newResult(1, 1, genUpkeepID(ocr2keepers.LogTrigger, "123"), 1, 1), }, - 640, + 704, 1, 1, nil, @@ -48,9 +45,9 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { { "happy flow multiple", []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "10").String()), 1, 1), - newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 2, 2), - newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "30").String()), 3, 3), + newResult(1, 1, genUpkeepID(ocr2keepers.LogTrigger, "10"), 1, 1), + newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "20"), 1, 1), + newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "30"), 1, 1), }, 1280, 3, @@ -60,9 +57,9 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { { "happy flow highest block number first", []ocr2keepers.CheckResult{ - newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "30").String()), 1000, 2000), - newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 2, 2), - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "10").String()), 1, 1), + newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "30"), 1, 1), + newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "20"), 1, 1), + newResult(1, 1, genUpkeepID(ocr2keepers.LogTrigger, "10"), 1, 1), }, 1280, 1000, @@ -90,389 +87,48 @@ func TestEVMAutomationEncoder21_Encode(t *testing.T) { assert.Nil(t, err) assert.Len(t, b, tc.reportSize) - upkeeps, err := decode(encoder.packer, b) + results, err := encoder.Extract(b) assert.Nil(t, err) - assert.Len(t, upkeeps, len(tc.results)) - - for i, u := range upkeeps { - upkeep, ok := u.(EVMAutomationUpkeepResult21) - assert.True(t, ok) + assert.Len(t, results, len(tc.results)) - assert.Equal(t, upkeep.Block, uint32(tc.results[i].Payload.Trigger.BlockNumber)) - assert.Equal(t, ocr2keepers.UpkeepIdentifier(upkeep.ID.String()), tc.results[i].Payload.Upkeep.ID) - assert.Equal(t, upkeep.Eligible, tc.results[i].Eligible) - assert.Equal(t, upkeep.PerformData, tc.results[i].PerformData) - assert.Equal(t, upkeep.CheckBlockNumber, uint32(tc.results[i].Payload.Trigger.BlockNumber)) - assert.Equal(t, common.BytesToHash(upkeep.CheckBlockHash[:]), common.HexToHash(tc.results[i].Payload.Trigger.BlockHash)) - assert.Equal(t, upkeep.FastGasWei, big.NewInt(tc.expectedFastGasWei)) - assert.Equal(t, upkeep.LinkNative, big.NewInt(tc.expectedLinkNative)) + for i, r := range results { + assert.Equal(t, r.UpkeepID, tc.results[i].UpkeepID) + assert.Equal(t, r.WorkID, tc.results[i].WorkID) + assert.Equal(t, r.Trigger, tc.results[i].Trigger) } }) } } -func TestEVMAutomationEncoder21_Encode_errors(t *testing.T) { - keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) - assert.Nil(t, err) - utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) - assert.Nil(t, err) - encoder := EVMAutomationEncoder21{ - packer: NewEvmRegistryPackerV2_1(keepersABI, utilsABI), - } - - t.Run("a non-EVMAutomationResultExtension21 extension causes an error", func(t *testing.T) { - result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "30").String()), 1, 1) - result.Extension = "invalid" - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unrecognized CheckResult extension data") - }) - - // TODO auto 4204: handle upkeep ID decoding properly - /* - t.Run("an invalid upkeep ID causes an error", func(t *testing.T) { - result := newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(conditionTrigger, "30").String()), 1, 1) - result.Payload.Upkeep.ID = []byte("invalid") - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "failed to parse big int from upkeep id: invalid") - })*/ - - t.Run("a non-LogTriggerExtension extension causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 1, 1) - result.Payload.Trigger.Extension = "invalid" - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unrecognized trigger extension data") - }) - - t.Run("a non hex tx (empty) hash causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 1, 1) - result.Payload.Trigger.Extension = core.LogTriggerExtension{ - TxHash: "", - } - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "tx hash parse error: empty hex string") - }) - - t.Run("an invalid result extension causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(5, "20").String()), 1, 1) - result.Extension = struct{}{} - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unexpected check result extension struct") - }) - - t.Run("invalid trigger extension causes an error", func(t *testing.T) { - result := newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "20").String()), 1, 1) - result.Payload.Trigger.Extension = struct{}{} - b, err := encoder.Encode(result) - assert.Nil(t, b) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unrecognized trigger extension data") - }) -} - -func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { - keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) - assert.Nil(t, err) - utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) - assert.Nil(t, err) - encoder := EVMAutomationEncoder21{ - packer: NewEvmRegistryPackerV2_1(keepersABI, utilsABI), - } - - tests := []struct { - name string - results []ocr2keepers.CheckResult - expectedErr error - }{ - { - "happy flow single", - []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "10").String()), 1, 1), - }, - nil, - }, - { - "happy flow multiple", - []ocr2keepers.CheckResult{ - newResult(1, "1", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "10").String()), 1, 1), - newResult(2, "2", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "20").String()), 1, 1), - newResult(3, "3", ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "30").String()), 1, 1), - }, - nil, - }, - { - "empty results", - []ocr2keepers.CheckResult{}, - errors.New(""), - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - b, _ := encoder.Encode(tc.results...) - reportedUpkeeps, err := encoder.Extract(b) - if tc.expectedErr != nil { - assert.Error(t, err) - return - } - assert.Nil(t, err) - assert.Len(t, reportedUpkeeps, len(tc.results)) - - for i, upkeep := range reportedUpkeeps { - assert.Equal(t, tc.results[i].Payload.Upkeep.ID, upkeep.UpkeepID) - assert.Equal(t, tc.results[i].Payload.Trigger.BlockHash, upkeep.Trigger.BlockHash) - assert.Equal(t, tc.results[i].Payload.Trigger.BlockNumber, upkeep.Trigger.BlockNumber) - assert.Equal(t, tc.results[i].PerformData, upkeep.PerformData) - } - }) - } -} +func newResult(block int64, checkBlock ocr2keepers.BlockNumber, id ocr2keepers.UpkeepIdentifier, fastGasWei, linkNative int64) ocr2keepers.CheckResult { + tp := core.GetUpkeepType(id) -func TestEVMAutomationEncoder21_EncodeExtract_errors(t *testing.T) { - keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) - assert.Nil(t, err) - utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) - assert.Nil(t, err) - encoder := EVMAutomationEncoder21{ - packer: NewEvmRegistryPackerV2_1(keepersABI, utilsABI), + trig := ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(block), + BlockHash: [32]byte{1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8}, } - t.Run("attempting to decode a report with an invalid trigger type returns an error", func(t *testing.T) { - encodedConditionTrigger := []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 49, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 86, 120, 144, 18, 52, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 5, 100, 97, 116, 97, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0} - reportedUpkeeps, err := encoder.Extract(encodedConditionTrigger) - assert.Nil(t, reportedUpkeeps) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unknown trigger type: 9: failed to unpack trigger") - }) -} - -func TestBlockKeyHelper_MakeBlockKey(t *testing.T) { - helper := BlockKeyHelper[int64]{} - blockKey := helper.MakeBlockKey(1234) - assert.Equal(t, blockKey, ocr2keepers.BlockKey("1234")) -} - -func TestUpkeepKeyHelper_MakeBlockKey(t *testing.T) { - helper := UpkeepKeyHelper[int64]{} - blockKey := helper.MakeUpkeepKey(1234, big.NewInt(5678)) - assert.Equal(t, blockKey, ocr2keepers.UpkeepKey("1234|5678")) -} - -func newResult(block int64, checkBlock ocr2keepers.BlockKey, id ocr2keepers.UpkeepIdentifier, fastGasWei, linkNative int64) ocr2keepers.CheckResult { - logExt := core.LogTriggerExtension{} - tp := core.GetUpkeepType(id) if tp == ocr2keepers.LogTrigger { - logExt.LogIndex = 1 - logExt.TxHash = "0x1234567890123456789012345678901234567890123456789012345678901234" + trig.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{ + Index: 1, + TxHash: common.HexToHash("0x1234567890123456789012345678901234567890123456789012345678901234"), + } } payload, _ := core.NewUpkeepPayload( - new(big.Int).SetBytes(id), - int(tp), - ocr2keepers.Trigger{ - BlockNumber: block, - BlockHash: hexutil.Encode([]byte{1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8, 1, 2, 3, 4, 5, 6, 7, 8}), - Extension: logExt, - }, + id.BigInt(), + trig, []byte{}, ) return ocr2keepers.CheckResult{ - Payload: payload, + UpkeepID: id, + Trigger: payload.Trigger, + WorkID: payload.WorkID, Eligible: true, GasAllocated: 100, PerformData: []byte("data0"), - Extension: EVMAutomationResultExtension21{ - FastGasWei: big.NewInt(fastGasWei), - LinkNative: big.NewInt(linkNative), - }, - } -} - -func decode(packer *evmRegistryPackerV2_1, raw []byte) ([]ocr2keepers.UpkeepResult, error) { - report, err := packer.UnpackReport(raw) - if err != nil { - return nil, err + FastGasWei: big.NewInt(fastGasWei), + LinkNative: big.NewInt(linkNative), } - - res := make([]ocr2keepers.UpkeepResult, len(report.UpkeepIds)) - - for i := 0; i < len(report.UpkeepIds); i++ { - trigger, err := core.UnpackTrigger(report.UpkeepIds[i], report.Triggers[i]) - if err != nil { - return nil, fmt.Errorf("%w: failed to unpack trigger", err) - } - r := EVMAutomationUpkeepResult21{ - Block: trigger.BlockNum, - ID: report.UpkeepIds[i], - Eligible: true, - PerformData: report.PerformDatas[i], - FastGasWei: report.FastGasWei, - LinkNative: report.LinkNative, - CheckBlockNumber: trigger.BlockNum, - CheckBlockHash: trigger.BlockHash, - } - res[i] = ocr2keepers.UpkeepResult(r) - } - - return res, nil -} - -func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) *big.Int { - b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) - b = append(b, []byte(rand)...) - return big.NewInt(0).SetBytes(b) -} - -func Test_decodeExtensions(t *testing.T) { - t.Run("a nil result returns an error", func(t *testing.T) { - err := decodeExtensions(nil) - assert.Error(t, err) - assert.Equal(t, err.Error(), "non-nil value expected in decoding") - }) - - t.Run("two types of extension do not require decoding", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Trigger: ocr2keepers.Trigger{ - Extension: core.LogTriggerExtension{}, - }, - }, - Extension: EVMAutomationResultExtension21{}, - }) - assert.NoError(t, err) - }) - - t.Run("empty structs do not require decoding", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Trigger: ocr2keepers.Trigger{ - Extension: struct{}{}, - }, - }, - Extension: struct{}{}, - }) - assert.NoError(t, err) - }) - - t.Run("CheckResult extension as json gets decoded", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Trigger: ocr2keepers.Trigger{ - Extension: struct{}{}, - }, - }, - Extension: []byte(`{"FastGasWei":1,"LinkNative":2,"FailureReason":3}`), - }) - assert.NoError(t, err) - }) - - t.Run("trigger extension as json for logTrigger gets decoded", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes()), - }, - Trigger: ocr2keepers.Trigger{ - Extension: []byte(`{"TxHash": "abc", "LogIndex": 123}`), - }, - }, - Extension: struct{}{}, - }) - assert.NoError(t, err) - }) - - t.Run("trigger extension as invalid json returns an error for logTrigger", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes()), - }, - Trigger: ocr2keepers.Trigger{ - Extension: []byte(`invalid`), - }, - }, - Extension: struct{}{}, - }) - assert.Error(t, err) - assert.Equal(t, err.Error(), "invalid character 'i' looking for beginning of value: json encoded values do not match LogTriggerExtension struct: invalid") - }) - - t.Run("trigger extension for conditionTrigger requires no decoding", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(ocr2keepers.ConditionTrigger, "111").Bytes()), - }, - Trigger: ocr2keepers.Trigger{ - Extension: []byte(""), - }, - }, - Extension: struct{}{}, - }) - assert.NoError(t, err) - }) - - t.Run("trigger extension for an unknown upkeep type returns an error", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(genUpkeepID(99, "111").Bytes()), - }, - Trigger: ocr2keepers.Trigger{ - Extension: []byte(""), - }, - }, - Extension: struct{}{}, - }) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unknown upkeep type") - }) - - t.Run("CheckResult extension as invalid json returns an error", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Trigger: ocr2keepers.Trigger{ - Extension: struct{}{}, - }, - }, - Extension: []byte(`invalid`), - }) - assert.Error(t, err) - assert.Equal(t, err.Error(), "invalid character 'i' looking for beginning of value: json encoded values do not match EVMAutomationResultExtension21 struct") - }) - - t.Run("unrecognized trigger extension returns an error", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Trigger: ocr2keepers.Trigger{ - Extension: "invalid", - }, - }, - }) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unrecognized trigger extension data") - }) - - t.Run("unrecognized CheckResult extension returns an error", func(t *testing.T) { - err := decodeExtensions(&ocr2keepers.CheckResult{ - Payload: ocr2keepers.UpkeepPayload{ - Trigger: ocr2keepers.Trigger{ - Extension: core.LogTriggerExtension{}, - }, - }, - Extension: "invalid", - }) - assert.Error(t, err) - assert.Equal(t, err.Error(), "unrecognized CheckResult extension data") - }) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 30cb008b566..b3041551067 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -22,7 +22,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common/hexutil" "github.com/patrickmn/go-cache" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" ) const ( @@ -74,13 +74,14 @@ type AdminOffchainConfig struct { // feedLookup looks through check upkeep results looking for any that need off chain lookup func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keepers.CheckResult) ([]ocr2keepers.CheckResult, error) { lookups := map[int]*FeedLookup{} - for i, res := range upkeepResults { - ext := res.Extension.(EVMAutomationResultExtension21) - if ext.FailureReason != UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED { + for i := range upkeepResults { + res := &upkeepResults[i] + if res.FailureReason != UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED { continue } - block, upkeepId := r.getBlockAndUpkeepId(res.Payload) + block := big.NewInt(int64(res.Trigger.BlockNumber)) + upkeepId := res.UpkeepID opts, err := r.buildCallOpts(ctx, block) if err != nil { @@ -88,15 +89,14 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper return nil, err } - allowed, err := r.allowedToUseMercury(opts, upkeepId) + allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) if err != nil { r.lggr.Errorf("[FeedLookup] upkeep %s block %d failed to time mercury allow list: %v", upkeepId, block, err) continue } if !allowed { - ext.FailureReason = UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED - upkeepResults[i].Extension = ext + res.FailureReason = UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED r.lggr.Errorf("[FeedLookup] upkeep %s block %d NOT allowed to time Mercury server", upkeepId, block) continue } @@ -107,7 +107,7 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper r.lggr.Errorf("[FeedLookup] upkeep %s block %d decodeFeedLookup: %v", upkeepId, block, err) continue } - lookup.upkeepId = upkeepId + lookup.upkeepId = upkeepId.BigInt() // the block here is exclusively used to call checkCallback at this block, not to be confused with the block number // in the revert for mercury v0.2, which is denoted by time in the struct bc starting from v0.3, only timestamp will be supported lookup.block = uint64(block.Int64()) @@ -152,28 +152,19 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * return } - ext, ok := upkeepResults[i].Extension.(EVMAutomationResultExtension21) - if !ok { - r.lggr.Errorf("[FeedLookup] upkeep %s block %d unexpected check result extension struct", lookup.upkeepId, lookup.block) - return - } - if int(failureReason) == UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED { - ext.FailureReason = UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED - upkeepResults[i].Extension = ext + upkeepResults[i].FailureReason = UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED r.lggr.Debugf("[FeedLookup] upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) return } if !needed { - ext.FailureReason = UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED - upkeepResults[i].Extension = ext + upkeepResults[i].FailureReason = UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED r.lggr.Debugf("[FeedLookup] upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) return } - ext.FailureReason = UPKEEP_FAILURE_REASON_NONE - upkeepResults[i].Extension = ext + upkeepResults[i].FailureReason = UPKEEP_FAILURE_REASON_NONE upkeepResults[i].Eligible = true upkeepResults[i].PerformData = performData r.lggr.Infof("[FeedLookup] upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) @@ -315,7 +306,7 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { - r.lggr.Errorf("FeedLookup upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + r.lggr.Warnf("FeedLookup upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) return err1 } defer resp.Body.Close() @@ -325,7 +316,7 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { - r.lggr.Errorf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) + r.lggr.Warnf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) retryable = true return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { @@ -335,12 +326,12 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy var m MercuryResponse err1 = json.Unmarshal(body, &m) if err1 != nil { - r.lggr.Errorf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + r.lggr.Warnf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { - r.lggr.Errorf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) + r.lggr.Warnf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) return err1 } ch <- MercuryBytes{Index: index, Bytes: blobBytes} @@ -395,7 +386,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { - r.lggr.Errorf("FeedLookup upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + r.lggr.Warnf("FeedLookup upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) return err1 } defer resp.Body.Close() @@ -405,7 +396,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { - r.lggr.Errorf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) + r.lggr.Warnf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) retryable = true return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { @@ -415,12 +406,12 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy var m MercuryResponse err1 = json.Unmarshal(body, &m) if err1 != nil { - r.lggr.Errorf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + r.lggr.Warnf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { - r.lggr.Errorf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, err1) + r.lggr.Warnf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, err1) return err1 } ch <- MercuryBytes{ diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index fea36036066..5c13e860a84 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -17,7 +17,7 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/patrickmn/go-cache" "github.com/pkg/errors" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" @@ -76,6 +76,8 @@ func setupEVMRegistry(t *testing.T) *EvmRegistry { func TestEvmRegistry_FeedLookup(t *testing.T) { upkeepId, ok := new(big.Int).SetString("71022726777042968814359024671382968091267501884371696415772139504780367423725", 10) + var upkeepIdentifier [32]byte + copy(upkeepIdentifier[:], upkeepId.Bytes()) assert.True(t, ok, t.Name()) tests := []struct { name string @@ -97,18 +99,11 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { input: []ocr2keepers.CheckResult{ { PerformData: []byte{125, 221, 147, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 141, 110, 193, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 100, 72, 101, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 53, 53, 52, 52, 56, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: upkeepId.Bytes(), - Type: 0, - Config: nil, - }, - CheckData: nil, - Trigger: ocr2keepers.Trigger{ - BlockNumber: 26046145, - }, + UpkeepID: upkeepIdentifier, + Trigger: ocr2keepers.Trigger{ + BlockNumber: 26046145, }, - Extension: EVMAutomationResultExtension21{FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED}, + FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, }, }, blob: "0x00066dfcd1ed2d95b18c948dbc5bd64c687afe93e4ca7d663ddec14c20090ad80000000000000000000000000000000000000000000000000000000000159761000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000002200000000000000000000000000000000000000000000000000000000000000280000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001204554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000648a1fbb000000000000000000000000000000000000000000000000000000274421041500000000000000000000000000000000000000000000000000000027437c6ecd0000000000000000000000000000000000000000000000000000002744c5995d00000000000000000000000000000000000000000000000000000000018d6ec108936dfe39c48715572a51ac868129958f937fb95ef5abdf73a239cf86a4fee700000000000000000000000000000000000000000000000000000000018d6ec100000000000000000000000000000000000000000000000000000000648a1fbb00000000000000000000000000000000000000000000000000000000000000028a26e557ee2feb91ccb116f3ab4eb1469afe5c3b012538cb151dbe3fbceaf6f117b24ac2a82cff25b286ae0a9b903dc6badaa16f6e67bf0983461b008574e30a00000000000000000000000000000000000000000000000000000000000000020db5c5924481061b98df59caefd9c4c1e72657c4976bf7c7568730fbdaf828080bff6b1edea2c8fed5e8bbac5574aa94cf809d898f5055cb1db14a16f1493726", @@ -121,18 +116,11 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { { Eligible: true, PerformData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 3, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 224, 0, 6, 109, 252, 209, 237, 45, 149, 177, 140, 148, 141, 188, 91, 214, 76, 104, 122, 254, 147, 228, 202, 125, 102, 61, 222, 193, 76, 32, 9, 10, 216, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21, 151, 97, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 128, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 32, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 138, 31, 187, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 39, 68, 33, 4, 21, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 39, 67, 124, 110, 205, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 39, 68, 197, 153, 93, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 141, 110, 193, 8, 147, 109, 254, 57, 196, 135, 21, 87, 42, 81, 172, 134, 129, 41, 149, 143, 147, 127, 185, 94, 245, 171, 223, 115, 162, 57, 207, 134, 164, 254, 231, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 141, 110, 193, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 138, 31, 187, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 138, 38, 229, 87, 238, 47, 235, 145, 204, 177, 22, 243, 171, 78, 177, 70, 154, 254, 92, 59, 1, 37, 56, 203, 21, 29, 190, 63, 188, 234, 246, 241, 23, 178, 74, 194, 168, 44, 255, 37, 178, 134, 174, 10, 155, 144, 61, 198, 186, 218, 161, 111, 110, 103, 191, 9, 131, 70, 27, 0, 133, 116, 227, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 13, 181, 197, 146, 68, 129, 6, 27, 152, 223, 89, 202, 239, 217, 196, 193, 231, 38, 87, 196, 151, 107, 247, 199, 86, 135, 48, 251, 218, 248, 40, 8, 11, 255, 107, 30, 222, 162, 200, 254, 213, 232, 187, 172, 85, 116, 170, 148, 207, 128, 157, 137, 143, 80, 85, 203, 29, 177, 74, 22, 241, 73, 55, 38, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 120, 111, 101, 122, 90, 54, 44, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: upkeepId.Bytes(), - Type: 0, - Config: nil, - }, - CheckData: nil, - Trigger: ocr2keepers.Trigger{ - BlockNumber: 26046145, - }, + UpkeepID: upkeepIdentifier, + Trigger: ocr2keepers.Trigger{ + BlockNumber: 26046145, }, - Extension: EVMAutomationResultExtension21{FailureReason: UPKEEP_FAILURE_REASON_NONE}, + FailureReason: UPKEEP_FAILURE_REASON_NONE, }, }, hasError: false, @@ -143,36 +131,22 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { input: []ocr2keepers.CheckResult{ { PerformData: []byte{}, - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: upkeepId.Bytes(), - Type: 0, - Config: nil, - }, - CheckData: nil, - Trigger: ocr2keepers.Trigger{ - BlockNumber: 26046145, - }, + UpkeepID: upkeepIdentifier, + Trigger: ocr2keepers.Trigger{ + BlockNumber: 26046145, }, - Extension: EVMAutomationResultExtension21{FailureReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE}, + FailureReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, }, }, expectedResults: []ocr2keepers.CheckResult{ { Eligible: false, PerformData: []byte{}, - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: upkeepId.Bytes(), - Type: 0, - Config: nil, - }, - CheckData: nil, - Trigger: ocr2keepers.Trigger{ - BlockNumber: 26046145, - }, + UpkeepID: upkeepIdentifier, + Trigger: ocr2keepers.Trigger{ + BlockNumber: 26046145, }, - Extension: EVMAutomationResultExtension21{FailureReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE}, + FailureReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, }, }, hasError: true, @@ -182,36 +156,22 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { input: []ocr2keepers.CheckResult{ { PerformData: []byte{}, - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: upkeepId.Bytes(), - Type: 0, - Config: nil, - }, - CheckData: nil, - Trigger: ocr2keepers.Trigger{ - BlockNumber: 26046145, - }, + UpkeepID: upkeepIdentifier, + Trigger: ocr2keepers.Trigger{ + BlockNumber: 26046145, }, - Extension: EVMAutomationResultExtension21{FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED}, + FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, }, }, expectedResults: []ocr2keepers.CheckResult{ { Eligible: false, PerformData: []byte{}, - Payload: ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: upkeepId.Bytes(), - Type: 0, - Config: nil, - }, - CheckData: nil, - Trigger: ocr2keepers.Trigger{ - BlockNumber: 26046145, - }, + UpkeepID: upkeepIdentifier, + Trigger: ocr2keepers.Trigger{ + BlockNumber: 26046145, }, - Extension: EVMAutomationResultExtension21{FailureReason: UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED}, + FailureReason: UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED, }, }, hasError: false, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index c486ae02559..ef0b8d62283 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -22,7 +22,7 @@ import ( "github.com/smartcontractkit/sqlx" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/assets" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" @@ -78,7 +78,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { // let it time to poll <-time.After(pollerTimeout) - logs, _ := logProvider.GetLogs(ctx) + logs, _ := logProvider.GetLatestPayloads(ctx) require.NoError(t, logProvider.Close()) require.GreaterOrEqual(t, len(logs), n, "failed to get all logs") @@ -97,7 +97,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { }() defer logProvider.Close() - logsAfterRestart, _ := logProvider.GetLogs(ctx) + logsAfterRestart, _ := logProvider.GetLatestPayloads(ctx) require.GreaterOrEqual(t, len(logsAfterRestart), 0, "logs should have been marked visited") @@ -107,7 +107,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { <-time.After(pollerTimeout) - logsAfterRestart, _ = logProvider.GetLogs(ctx) + logsAfterRestart, _ = logProvider.GetLatestPayloads(ctx) require.NoError(t, logProvider.Close()) require.GreaterOrEqual(t, len(logsAfterRestart), n, "failed to get logs after restart") @@ -173,7 +173,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { // require.GreaterOrEqual(t, atomic.LoadInt32(&limitErrs), int32(1), "didn't got rate limit errors") t.Logf("got %d rate limit errors", atomic.LoadInt32(&limitErrs)) - _, err := logProvider.GetLogs(ctx) + _, err := logProvider.GetLatestPayloads(ctx) require.NoError(t, err) require.NoError(t, logProvider.Close()) @@ -231,7 +231,7 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { <-time.After(pollerTimeout * 2) // let the provider work - logs, err := logProvider.GetLogs(ctx) + logs, err := logProvider.GetLatestPayloads(ctx) require.NoError(t, err) require.NoError(t, logProvider.Close()) @@ -298,7 +298,7 @@ func deployUpkeepCounter( // creating some dummy upkeepID to register filter upkeepID := ocr2keepers.UpkeepIdentifier(append(common.LeftPadBytes([]byte{1}, 16), upkeepAddr[:16]...)) - id := big.NewInt(0).SetBytes(upkeepID) + id := upkeepID.BigInt() ids = append(ids, id) err = logProvider.RegisterFilter(id, newPlainLogTriggerConfig(upkeepAddr)) require.NoError(t, err) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index c6112a74223..670a7b34359 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -13,8 +13,7 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "go.uber.org/multierr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" @@ -45,8 +44,8 @@ type LogEventProvider interface { RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfig) error // UnregisterFilter removes the filter for the given upkeepID. UnregisterFilter(upkeepID *big.Int) error - // GetLogs returns the logs in the given range. - GetLogs(context.Context) ([]ocr2keepers.UpkeepPayload, error) + // GetLatestPayloads returns the logs in the given range. + GetLatestPayloads(context.Context) ([]ocr2keepers.UpkeepPayload, error) } type LogEventProviderTest interface { @@ -55,8 +54,8 @@ type LogEventProviderTest interface { CurrentPartitionIdx() uint64 } -var _ keepersflows.PayloadBuilder = &logEventProvider{} -var _ keepersflows.LogEventProvider = &logEventProvider{} +var _ ocr2keepers.PayloadBuilder = &logEventProvider{} +var _ ocr2keepers.LogEventProvider = &logEventProvider{} // logEventProvider manages log filters for upkeeps and enables to read the log events. type logEventProvider struct { @@ -128,12 +127,12 @@ func (p *logEventProvider) Close() error { return nil } -func (p *logEventProvider) BuildPayload(ctx context.Context, proposal ocr2keepers.CoordinatedProposal) (ocr2keepers.UpkeepPayload, error) { +func (p *logEventProvider) BuildPayloads(ctx context.Context, proposals ...ocr2keepers.CoordinatedProposal) ([]ocr2keepers.UpkeepPayload, error) { // TODO: implement - return ocr2keepers.UpkeepPayload{}, nil + return []ocr2keepers.UpkeepPayload{}, nil } -func (p *logEventProvider) GetLogs(context.Context) ([]ocr2keepers.UpkeepPayload, error) { +func (p *logEventProvider) GetLatestPayloads(context.Context) ([]ocr2keepers.UpkeepPayload, error) { latest := p.buffer.latestBlockSeen() diff := latest - p.opts.LogBlocksLookback if diff < 0 { @@ -145,20 +144,20 @@ func (p *logEventProvider) GetLogs(context.Context) ([]ocr2keepers.UpkeepPayload for _, l := range logs { log := l.log trig := ocr2keepers.NewTrigger( - log.BlockNumber, - log.BlockHash.Hex(), - core.LogTriggerExtension{ - TxHash: log.TxHash.Hex(), - LogIndex: log.LogIndex, - }, + ocr2keepers.BlockNumber(log.BlockNumber), + log.BlockHash, ) + trig.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{ + TxHash: log.TxHash, + Index: uint32(log.LogIndex), + } checkData, err := p.packer.PackLogData(log) if err != nil { p.lggr.Warnw("failed to pack log data", "err", err, "log", log) continue } - payload, err := core.NewUpkeepPayload(l.id, logTriggerType, trig, checkData) + payload, err := core.NewUpkeepPayload(l.id, trig, checkData) if err != nil { // skip invalid payloads continue diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go index 7368dea5621..7886623f92e 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go @@ -12,7 +12,7 @@ import ( "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" @@ -274,8 +274,10 @@ func TestLogEventProvider_ReadLogs(t *testing.T) { } func newEntry(p *logEventProvider, i int, args ...string) (LogTriggerConfig, upkeepFilter) { - id := ocr2keepers.UpkeepIdentifier(append(common.LeftPadBytes([]byte{1}, 16), []byte(fmt.Sprintf("%d", i))...)) - uid := big.NewInt(0).SetBytes(id) + idBytes := append(common.LeftPadBytes([]byte{1}, 16), []byte(fmt.Sprintf("%d", i))...) + id := ocr2keepers.UpkeepIdentifier{} + copy(id[:], idBytes) + uid := id.BigInt() for len(args) < 2 { args = append(args, "0x3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d") } @@ -286,12 +288,12 @@ func newEntry(p *logEventProvider, i int, args ...string) (LogTriggerConfig, upk Topic0: common.HexToHash(topic0), } filter := p.newLogFilter(uid, cfg) - eventSigs := make([]common.Hash, len(filter.EventSigs)) - copy(eventSigs, filter.EventSigs) + topics := make([]common.Hash, len(filter.EventSigs)) + copy(topics, filter.EventSigs) f := upkeepFilter{ upkeepID: uid, addr: filter.Addresses[0].Bytes(), - topics: eventSigs, + topics: topics, blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), } return cfg, f diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go index 41f394af63f..4284448b40b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go @@ -6,8 +6,7 @@ import ( "sync" "time" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -31,7 +30,7 @@ type logRecoverer struct { poller logpoller.LogPoller } -var _ keepersflows.RecoverableProvider = &logRecoverer{} +var _ ocr2keepers.RecoverableProvider = &logRecoverer{} func NewLogRecoverer(lggr logger.Logger, poller logpoller.LogPoller, interval time.Duration) *logRecoverer { if interval == 0 { @@ -79,7 +78,7 @@ func (r *logRecoverer) Close() error { return nil } -func (r *logRecoverer) GetRecoverables() ([]ocr2keepers.UpkeepPayload, error) { +func (r *logRecoverer) GetRecoveryProposals(ctx context.Context) ([]ocr2keepers.UpkeepPayload, error) { r.lock.Lock() defer r.lock.Unlock() @@ -91,7 +90,7 @@ func (r *logRecoverer) GetRecoverables() ([]ocr2keepers.UpkeepPayload, error) { r.pending = make([]ocr2keepers.UpkeepPayload, 0) for _, p := range pending { - r.visited[p.ID] = true + r.visited[p.WorkID] = true } return pending, nil diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go index 5b1a1ac29f0..79a8f1e1941 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go @@ -1,16 +1,19 @@ package logprovider import ( + "context" "testing" "time" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/logger" ) func TestLogRecoverer_GetRecoverables(t *testing.T) { + ctx, cancel := context.WithCancel(context.Background()) + defer cancel() r := NewLogRecoverer(logger.TestLogger(t), nil, time.Millisecond*10) tests := []struct { @@ -28,10 +31,10 @@ func TestLogRecoverer_GetRecoverables(t *testing.T) { { "happy flow", []ocr2keepers.UpkeepPayload{ - {ID: "1"}, {ID: "2"}, + {WorkID: "1"}, {WorkID: "2"}, }, []ocr2keepers.UpkeepPayload{ - {ID: "1"}, {ID: "2"}, + {WorkID: "1"}, {WorkID: "2"}, }, false, }, @@ -43,7 +46,7 @@ func TestLogRecoverer_GetRecoverables(t *testing.T) { r.pending = tc.pending r.lock.Unlock() - got, err := r.GetRecoverables() + got, err := r.GetRecoveryProposals(ctx) if tc.wantErr { require.Error(t, err) } else { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index a99283cf3d8..fedafe3c4e5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -18,7 +18,7 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/rpc" "github.com/patrickmn/go-cache" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "go.uber.org/multierr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" @@ -55,7 +55,6 @@ var ( ErrABINotParsable = fmt.Errorf("error parsing abi") ActiveUpkeepIDBatchSize int64 = 1000 FetchUpkeepConfigBatchSize = 10 - separator = "|" reInitializationDelay = 15 * time.Minute logEventLookback int64 = 250 ) @@ -211,14 +210,16 @@ func (r *EvmRegistry) GetActiveUpkeepIDsByType(ctx context.Context, triggers ... keys := make([]ocr2keepers.UpkeepIdentifier, 0) for _, value := range r.active { + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(value.ID) if len(triggers) == 0 { - keys = append(keys, ocr2keepers.UpkeepIdentifier(value.ID.String())) + keys = append(keys, *uid) continue } - trigger := core.GetUpkeepType(value.ID.Bytes()) + trigger := core.GetUpkeepType(*uid) for _, t := range triggers { if trigger == ocr2keepers.UpkeepType(t) { - keys = append(keys, ocr2keepers.UpkeepIdentifier(value.ID.String())) + keys = append(keys, *uid) break } } @@ -408,7 +409,9 @@ func (r *EvmRegistry) initialize() error { // register upkeep ids for log triggers for _, id := range ids { - switch core.GetUpkeepType(id.Bytes()) { + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(id) + switch core.GetUpkeepType(*uid) { case ocr2keepers.LogTrigger: if err := r.updateTriggerConfig(id, nil); err != nil { r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", id.String(), err) @@ -502,7 +505,9 @@ func (r *EvmRegistry) processUpkeepStateLog(l logpoller.Log) error { r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", l.Id.String(), err) } case *iregistry21.IKeeperRegistryMasterUpkeepRegistered: - trigger := core.GetUpkeepType(l.Id.Bytes()) + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(l.Id) + trigger := core.GetUpkeepType(*uid) r.lggr.Debugf("KeeperRegistryUpkeepRegistered log detected for upkeep ID %s (trigger=%d) in transaction %s", l.Id.String(), trigger, hash) r.addToActive(l.Id, false) if err := r.updateTriggerConfig(l.Id, nil); err != nil { @@ -532,7 +537,9 @@ func (r *EvmRegistry) removeFromActive(id *big.Int) { delete(r.active, id.String()) r.mu.Unlock() - trigger := core.GetUpkeepType(id.Bytes()) + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(id) + trigger := core.GetUpkeepType(*uid) switch trigger { case ocr2keepers.LogTrigger: if err := r.logEventProvider.UnregisterFilter(id); err != nil { @@ -554,7 +561,7 @@ func (r *EvmRegistry) addToActive(id *big.Int, force bool) { if _, ok := r.active[id.String()]; !ok || force { actives, err := r.getUpkeepConfigs(r.ctx, []*big.Int{id}) if err != nil { - r.lggr.Errorf("failed to get upkeep configs during adding active upkeep: %w", err) + r.lggr.Warnf("failed to get upkeep configs during adding active upkeep: %w", err) return } @@ -654,23 +661,22 @@ func (r *EvmRegistry) doCheck(ctx context.Context, keys []ocr2keepers.UpkeepPayl } } -func (r *EvmRegistry) getBlockAndUpkeepId(key ocr2keepers.UpkeepPayload) (*big.Int, *big.Int) { - block := new(big.Int).SetInt64(key.Trigger.BlockNumber) - upkeepId := new(big.Int).SetBytes(key.Upkeep.ID) - return block, upkeepId +func (r *EvmRegistry) getBlockAndUpkeepId(upkeepID ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) (*big.Int, *big.Int) { + block := new(big.Int).SetInt64(int64(trigger.BlockNumber)) + return block, upkeepID.BigInt() } // TODO (AUTO-2013): Have better error handling to not return nil results in case of partial errors -func (r *EvmRegistry) checkUpkeeps(ctx context.Context, keys []ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { +func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { var ( - checkReqs = make([]rpc.BatchElem, len(keys)) - checkResults = make([]*string, len(keys)) - blocks = make([]*big.Int, len(keys)) - upkeepIds = make([]*big.Int, len(keys)) + checkReqs = make([]rpc.BatchElem, len(payloads)) + checkResults = make([]*string, len(payloads)) + blocks = make([]*big.Int, len(payloads)) + upkeepIds = make([]*big.Int, len(payloads)) ) - for i, key := range keys { - block, upkeepId := r.getBlockAndUpkeepId(key) + for i, p := range payloads { + block, upkeepId := r.getBlockAndUpkeepId(p.UpkeepID, p.Trigger) blocks[i] = block upkeepIds[i] = upkeepId @@ -679,10 +685,12 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, keys []ocr2keepers.Upkee return nil, err } var payload []byte - switch core.GetUpkeepType(upkeepId.Bytes()) { + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(upkeepId) + switch core.GetUpkeepType(*uid) { case ocr2keepers.LogTrigger: // check data will include the log trigger config - payload, err = r.abi.Pack("checkUpkeep", upkeepId, key.CheckData) + payload, err = r.abi.Pack("checkUpkeep", upkeepId, p.CheckData) if err != nil { return nil, err } @@ -715,16 +723,16 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, keys []ocr2keepers.Upkee var ( multiErr error - results = make([]ocr2keepers.CheckResult, len(keys)) + results = make([]ocr2keepers.CheckResult, len(payloads)) ) for i, req := range checkReqs { if req.Error != nil { - r.lggr.Debugf("error encountered for key %s with message '%s' in check", keys[i], req.Error) + r.lggr.Debugf("error encountered for key %s with message '%s' in check", payloads[i], req.Error) multierr.AppendInto(&multiErr, req.Error) } else { var err error - results[i], err = r.packer.UnpackCheckResult(keys[i], *checkResults[i]) + results[i], err = r.packer.UnpackCheckResult(payloads[i], *checkResults[i]) if err != nil { return nil, errors.Wrap(err, "failed to unpack check result") } @@ -747,7 +755,7 @@ func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults [ continue } - block, upkeepId := r.getBlockAndUpkeepId(cr.Payload) + block, upkeepId := r.getBlockAndUpkeepId(cr.UpkeepID, cr.Trigger) opts, err := r.buildCallOpts(ctx, block) if err != nil { @@ -786,7 +794,7 @@ func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults [ var multiErr error for i, req := range performReqs { if req.Error != nil { - r.lggr.Debugf("error encountered for key %d|%s with message '%s' in simulate perform", checkResults[i].Payload.Trigger.BlockNumber, new(big.Int).SetBytes(checkResults[i].Payload.Upkeep.ID), req.Error) + r.lggr.Debugf("error encountered for key %d|%s with message '%s' in simulate perform", checkResults[i].Trigger.BlockNumber, checkResults[i].UpkeepID.BigInt(), req.Error) multierr.AppendInto(&multiErr, req.Error) } else { simulatePerformSuccess, err := r.packer.UnpackPerformResult(*performResults[i]) @@ -871,8 +879,9 @@ func (r *EvmRegistry) getUpkeepConfigs(ctx context.Context, ids []*big.Int) ([]a } func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { - uid := id.String() - switch core.GetUpkeepType(id.Bytes()) { + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(id) + switch core.GetUpkeepType(*uid) { case ocr2keepers.LogTrigger: if len(cfg) == 0 { fetched, err := r.fetchTriggerConfig(id) @@ -888,7 +897,7 @@ func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { if err := r.logEventProvider.RegisterFilter(id, logprovider.LogTriggerConfig(parsed)); err != nil { return errors.Wrap(err, "failed to register log filter") } - r.lggr.Debugw("registered log filter", "upkeepID", uid, "cfg", parsed) + r.lggr.Debugw("registered log filter", "upkeepID", id.String(), "cfg", parsed) default: } return nil diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go index 75132f832f1..ac4668845d5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go @@ -8,7 +8,7 @@ import ( "time" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" @@ -26,11 +26,12 @@ func TestGetActiveUpkeepIDs(t *testing.T) { ExpectedKeys []ocr2keepers.UpkeepIdentifier }{ {Name: "NoActiveIDs", LatestHead: 1, ActiveIDs: []string{}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{}}, - {Name: "AvailableActiveIDs", LatestHead: 1, ActiveIDs: []string{"8", "9", "3", "1"}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - ocr2keepers.UpkeepIdentifier("8"), - ocr2keepers.UpkeepIdentifier("9"), - ocr2keepers.UpkeepIdentifier("3"), - ocr2keepers.UpkeepIdentifier("1"), + {Name: "AvailableActiveIDs", LatestHead: 1, ActiveIDs: []string{ + "32329108151019397958065800113404894502874153543356521479058624064899121404671", + "5820911532554020907796191562093071158274499580927271776163559390280294438608", + }, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ + upkeepIDFromInt("32329108151019397958065800113404894502874153543356521479058624064899121404671"), + upkeepIDFromInt("5820911532554020907796191562093071158274499580927271776163559390280294438608"), }}, } @@ -81,7 +82,7 @@ func TestGetActiveUpkeepIDsByType(t *testing.T) { LatestHead: 1, ActiveIDs: []string{"8", "32329108151019397958065800113404894502874153543356521479058624064899121404671"}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - ocr2keepers.UpkeepIdentifier("32329108151019397958065800113404894502874153543356521479058624064899121404671"), + upkeepIDFromInt("32329108151019397958065800113404894502874153543356521479058624064899121404671"), }, Triggers: []uint8{uint8(ocr2keepers.LogTrigger)}, }, @@ -90,7 +91,7 @@ func TestGetActiveUpkeepIDsByType(t *testing.T) { LatestHead: 1, ActiveIDs: []string{"8", "32329108151019397958065800113404894502874153543356521479058624064899121404671"}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - ocr2keepers.UpkeepIdentifier("8"), + upkeepIDFromInt("8"), }, Triggers: []uint8{uint8(ocr2keepers.ConditionTrigger)}, }, @@ -99,8 +100,8 @@ func TestGetActiveUpkeepIDsByType(t *testing.T) { LatestHead: 1, ActiveIDs: []string{"8", "32329108151019397958065800113404894502874153543356521479058624064899121404671"}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - ocr2keepers.UpkeepIdentifier("8"), - ocr2keepers.UpkeepIdentifier("32329108151019397958065800113404894502874153543356521479058624064899121404671"), + upkeepIDFromInt("8"), + upkeepIDFromInt("32329108151019397958065800113404894502874153543356521479058624064899121404671"), }, Triggers: []uint8{uint8(ocr2keepers.LogTrigger), uint8(ocr2keepers.ConditionTrigger)}, }, @@ -316,26 +317,22 @@ func TestRegistry_GetBlockAndUpkeepId(t *testing.T) { { "happy flow", ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier([]byte("10")), - }, + UpkeepID: upkeepIDFromInt("10"), Trigger: ocr2keepers.Trigger{ BlockNumber: 1, - BlockHash: common.Bytes2Hex([]byte{1, 2, 3, 4, 5, 6, 7, 8}), + BlockHash: common.HexToHash("0x1"), }, }, big.NewInt(1), - big.NewInt(0).SetBytes([]byte("10")), + big.NewInt(10), }, { - "empty block number", + "empty trigger", ocr2keepers.UpkeepPayload{ - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier([]byte("10")), - }, + UpkeepID: upkeepIDFromInt("10"), }, big.NewInt(0), - big.NewInt(0).SetBytes([]byte("10")), + big.NewInt(10), }, { "empty payload", @@ -347,9 +344,9 @@ func TestRegistry_GetBlockAndUpkeepId(t *testing.T) { for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { - block, upkeep := r.getBlockAndUpkeepId(tc.input) + block, upkeep := r.getBlockAndUpkeepId(tc.input.UpkeepID, tc.input.Trigger) assert.Equal(t, tc.wantBlock, block) - assert.Equal(t, tc.wantUpkeep, upkeep) + assert.Equal(t, tc.wantUpkeep.String(), upkeep.String()) }) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go b/core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go new file mode 100644 index 00000000000..be3394cce36 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go @@ -0,0 +1,29 @@ +package evm + +import ( + "math/big" + + "github.com/ethereum/go-ethereum/common" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" +) + +// genUpkeepID generates an ocr2keepers.UpkeepIdentifier with a specific UpkeepType and some random string +func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) ocr2keepers.UpkeepIdentifier { + b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) + b = append(b, []byte(rand)...) + b = common.RightPadBytes(b, 32-len(b)) + if len(b) > 32 { + b = b[:32] + } + var id [32]byte + copy(id[:], b) + return ocr2keepers.UpkeepIdentifier(id) +} + +// upkeepIDFromInt converts an int string to ocr2keepers.UpkeepIdentifier +func upkeepIDFromInt(id string) ocr2keepers.UpkeepIdentifier { + uid := &ocr2keepers.UpkeepIdentifier{} + idInt, _ := big.NewInt(0).SetString(id, 10) + uid.FromBigInt(idInt) + return *uid +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go index e9bfbfabb23..9f91fae2ebb 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go @@ -7,7 +7,7 @@ import ( "sync" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" @@ -18,6 +18,8 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/utils" ) +var _ ocr2keepers.TransmitEventProvider = &TransmitEventProvider{} + type TransmitEventProvider struct { sync utils.StartStopOnce mu sync.RWMutex @@ -120,7 +122,7 @@ func (c *TransmitEventProvider) HealthReport() map[string]error { return map[string]error{c.Name(): c.sync.Healthy()} } -func (c *TransmitEventProvider) Events(ctx context.Context) ([]ocr2keepers.TransmitEvent, error) { +func (c *TransmitEventProvider) GetLatestEvents(ctx context.Context) ([]ocr2keepers.TransmitEvent, error) { end, err := c.logPoller.LatestBlock(pg.WithParentCtx(ctx)) if err != nil { return nil, fmt.Errorf("%w: failed to get latest block from log poller", err) @@ -209,15 +211,38 @@ func (c *TransmitEventProvider) convertToTransmitEvents(logs []transmitEventLog, vals := []ocr2keepers.TransmitEvent{} for _, l := range logs { - upkeepId := ocr2keepers.UpkeepIdentifier(l.Id().Bytes()) - triggerID := l.TriggerID() + id := l.Id() + upkeepId := &ocr2keepers.UpkeepIdentifier{} + ok := upkeepId.FromBigInt(id) + if !ok { + return nil, core.ErrInvalidUpkeepID + } + triggerW, err := core.UnpackTrigger(id, l.Trigger()) + if err != nil { + return nil, fmt.Errorf("%w: failed to unpack trigger", err) + } + trigger := ocr2keepers.NewTrigger( + ocr2keepers.BlockNumber(triggerW.BlockNum), + triggerW.BlockHash, + ) + switch core.GetUpkeepType(*upkeepId) { + case ocr2keepers.LogTrigger: + trigger.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{} + trigger.LogTriggerExtension.TxHash = triggerW.TxHash + trigger.LogTriggerExtension.Index = triggerW.LogIndex + default: + } + workID, err := core.UpkeepWorkID(id, trigger) + if err != nil { + return nil, err + } vals = append(vals, ocr2keepers.TransmitEvent{ Type: l.TransmitEventType(), - TransmitBlock: BlockKeyHelper[int64]{}.MakeBlockKey(l.BlockNumber), + TransmitBlock: ocr2keepers.BlockNumber(l.BlockNumber), Confirmations: latestBlock - l.BlockNumber, - TransactionHash: l.TxHash.Hex(), - ID: triggerID, - UpkeepID: upkeepId, + TransactionHash: l.TxHash, + WorkID: workID, + UpkeepID: *upkeepId, }) } @@ -248,18 +273,18 @@ func (l transmitEventLog) Id() *big.Int { } } -func (l transmitEventLog) TriggerID() string { +func (l transmitEventLog) Trigger() []byte { switch { case l.Performed != nil: - return core.UpkeepTriggerID(l.Performed.Id, l.Performed.Trigger) + return l.Performed.Trigger case l.Stale != nil: - return core.UpkeepTriggerID(l.Stale.Id, l.Stale.Trigger) + return l.Stale.Trigger case l.Reorged != nil: - return core.UpkeepTriggerID(l.Reorged.Id, l.Reorged.Trigger) + return l.Reorged.Trigger case l.InsufficientFunds != nil: - return core.UpkeepTriggerID(l.InsufficientFunds.Id, l.InsufficientFunds.Trigger) + return l.InsufficientFunds.Trigger default: - return "" + return []byte{} } } @@ -270,12 +295,11 @@ func (l transmitEventLog) TransmitEventType() ocr2keepers.TransmitEventType { case l.Stale != nil: return ocr2keepers.StaleReportEvent case l.Reorged != nil: - // TODO: use reorged event type - return ocr2keepers.TransmitEventType(2) + return ocr2keepers.ReorgReportEvent case l.InsufficientFunds != nil: - // TODO: use insufficient funds event type - return ocr2keepers.TransmitEventType(3) + return ocr2keepers.InsufficientFundsReportEvent default: + // TODO: use unknown type return ocr2keepers.TransmitEventType(0) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go index f59bb2e7175..5c08cc1ebdf 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go @@ -7,7 +7,8 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + "github.com/ethereum/go-ethereum/common/hexutil" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" @@ -90,7 +91,7 @@ func TestTransmitEventProvider(t *testing.T) { mp.On("LatestBlock", mock.Anything).Return(tc.latestBlock, nil) mp.On("LogsWithSigs", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.logs, nil) - res, err := provider.Events(ctx) + res, err := provider.GetLatestEvents(ctx) require.Equal(t, tc.errored, err != nil) require.Len(t, res, tc.resultsLen) }) @@ -99,7 +100,7 @@ func TestTransmitEventProvider(t *testing.T) { func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { provider := &TransmitEventProvider{} - id := genUpkeepID(ocr2keepers.LogTrigger, "111") + id := genUpkeepID(ocr2keepers.LogTrigger, "1111111111111111") tests := []struct { name string performed []transmitEventLog @@ -116,7 +117,11 @@ func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { BlockHash: common.HexToHash("0x0102030405060708010203040506070801020304050607080102030405060708"), }, Performed: &iregistry21.IKeeperRegistryMasterUpkeepPerformed{ - Id: id, + Id: id.BigInt(), + Trigger: func() []byte { + b, _ := hexutil.Decode("0x0000000000000000000000000000000000000000000000000000000001111111000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000001111111") + return b + }(), }, }, }, @@ -124,8 +129,8 @@ func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { []ocr2keepers.TransmitEvent{ { Type: ocr2keepers.PerformEvent, - UpkeepID: ocr2keepers.UpkeepIdentifier(id.Bytes()), - CheckBlock: ocr2keepers.BlockKey(""), // empty for log triggers + UpkeepID: id, + CheckBlock: ocr2keepers.BlockNumber(0), // empty for log triggers }, }, false, @@ -169,7 +174,7 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, Performed: &iregistry21.IKeeperRegistryMasterUpkeepPerformed{ - Id: uid, + Id: uid.BigInt(), Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, @@ -183,7 +188,7 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, Stale: &iregistry21.IKeeperRegistryMasterStaleUpkeepReport{ - Id: uid, + Id: uid.BigInt(), Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, @@ -197,7 +202,7 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, InsufficientFunds: &iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{ - Id: uid, + Id: uid.BigInt(), Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, @@ -211,7 +216,7 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, Reorged: &iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{ - Id: uid, + Id: uid.BigInt(), Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, @@ -232,8 +237,8 @@ func TestTransmitEventLog(t *testing.T) { for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { if tc.log.Id() != nil { - require.Equal(t, uid.Int64(), tc.log.Id().Int64()) - require.Equal(t, "069d79304de8a5f4505a921893750ab549ec93837c5a99df2fb6fc827834fae7", tc.log.TriggerID()) + require.Equal(t, uid.BigInt().Int64(), tc.log.Id().Int64()) + require.Equal(t, []byte{0x1, 0x2, 0x3, 0x4, 0x5, 0x6, 0x7, 0x8}, tc.log.Trigger()) } require.Equal(t, tc.etype, tc.log.TransmitEventType()) }) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go index 1fc44fd97ae..e9b4f67947f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go @@ -4,33 +4,38 @@ import ( "context" "math/big" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - keepersflows "github.com/smartcontractkit/ocr2keepers/pkg/v3/flows" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) -var _ keepersflows.UpkeepProvider = &upkeepProvider{} +var _ ocr2keepers.ConditionalUpkeepProvider = &upkeepProvider{} type upkeepProvider struct { reg *EvmRegistry + lp logpoller.LogPoller } -func NewUpkeepProvider(reg *EvmRegistry) *upkeepProvider { +func NewUpkeepProvider(reg *EvmRegistry, lp logpoller.LogPoller) *upkeepProvider { return &upkeepProvider{ reg: reg, + lp: lp, } } -func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context, blockKey ocr2keepers.BlockKey) ([]ocr2keepers.UpkeepPayload, error) { +func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context) ([]ocr2keepers.UpkeepPayload, error) { ids, err := p.reg.GetActiveUpkeepIDsByType(ctx, uint8(ocr2keepers.ConditionTrigger)) if err != nil { return nil, err } - block, ok := big.NewInt(0).SetString(string(blockKey), 10) - if !ok { - return nil, ocr2keepers.ErrInvalidBlockKey + latestBlock, err := p.lp.LatestBlock(pg.WithParentCtx(ctx)) + if err != nil { + return nil, err } + + block := big.NewInt(latestBlock) blockHash, err := p.reg.getBlockHash(block) if err != nil { return nil, err @@ -39,9 +44,8 @@ func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context, blockKey ocr2keep var payloads []ocr2keepers.UpkeepPayload for _, uid := range ids { payload, err := core.NewUpkeepPayload( - big.NewInt(0).SetBytes(uid), - int(ocr2keepers.ConditionTrigger), - ocr2keepers.NewTrigger(block.Int64(), blockHash.Hex(), struct{}{}), + uid.BigInt(), + ocr2keepers.NewTrigger(ocr2keepers.BlockNumber(block.Int64()), blockHash), nil, ) if err != nil { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go index 6bb537ae96d..ddf93183336 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go @@ -8,11 +8,12 @@ import ( "testing" coreTypes "github.com/ethereum/go-ethereum/core/types" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" clientmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" ) @@ -26,8 +27,9 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { active: map[string]activeUpkeep{}, client: c, } + var lp logpoller.LogPoller - p := NewUpkeepProvider(r) + p := NewUpkeepProvider(r, lp) tests := []struct { name string @@ -56,13 +58,10 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { coreTypes.Header{Number: big.NewInt(1)}, []ocr2keepers.UpkeepPayload{ { - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(big.NewInt(1).String()), - }, - }, { - Upkeep: ocr2keepers.ConfiguredUpkeep{ - ID: ocr2keepers.UpkeepIdentifier(big.NewInt(2).String()), - }, + UpkeepID: upkeepIDFromInt("10"), + }, + { + UpkeepID: upkeepIDFromInt("15"), }, }, false, @@ -78,16 +77,16 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { r.active = tc.active r.mu.Unlock() - got, err := p.GetActiveUpkeeps(ctx, BlockKeyHelper[int64]{}.MakeBlockKey(b.Number().Int64())) + got, err := p.GetActiveUpkeeps(ctx) require.NoError(t, err) require.Len(t, got, len(tc.want)) sort.Slice(got, func(i, j int) bool { - return bytes.Compare(got[i].Upkeep.ID, got[j].Upkeep.ID) < 0 + return bytes.Compare(got[i].UpkeepID[:], got[j].UpkeepID[:]) < 0 }) for i, payload := range got { expected := tc.want[i] // require.Equal(t, expected.ID, payload.ID) // TODO: uncomment once we change to workID - require.Equal(t, expected.Upkeep.ID, payload.Upkeep.ID) + require.Equal(t, expected.UpkeepID, payload.UpkeepID) require.Equal(t, b.Number().Int64(), payload.Trigger.BlockNumber) } }) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go index 1ca18e28e72..c3cc75c1eff 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go @@ -4,7 +4,7 @@ import ( "math/big" "sync" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" mapset "github.com/deckarep/golang-set/v2" @@ -71,27 +71,27 @@ func (u *UpkeepStateStore) SetUpkeepState(pl ocr2keepers.UpkeepPayload, us ocr2k u.mu.Lock() defer u.mu.Unlock() - upkeepId := big.NewInt(0).SetBytes(pl.Upkeep.ID) + upkeepId := pl.UpkeepID.BigInt() state := &upkeepState{ payload: &pl, state: &us, - block: pl.Trigger.BlockNumber, + block: int64(pl.Trigger.BlockNumber), upkeepId: upkeepId.String(), } - s, ok := u.statesByID[pl.ID] + s, ok := u.statesByID[pl.WorkID] if ok { s.payload = state.payload s.state = state.state s.block = state.block s.upkeepId = state.upkeepId - u.statesByID[pl.ID] = s - u.lggr.Infof("upkeep %s is overridden, payload ID is %s, block is %d", s.upkeepId, s.payload.ID, s.block) + u.statesByID[pl.WorkID] = s + u.lggr.Infof("upkeep %s is overridden, payload ID is %s, block is %d", s.upkeepId, s.payload.WorkID, s.block) return nil } - u.statesByID[pl.ID] = state + u.statesByID[pl.WorkID] = state u.states = append(u.states, state) - u.lggr.Infof("added new state with upkeep %s payload ID %s block %d", state.upkeepId, state.payload.ID, state.block) + u.lggr.Infof("added new state with upkeep %s payload ID %s block %d", state.upkeepId, state.payload.WorkID, state.block) return nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go index 022cd03bb8e..4a5817f9314 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go @@ -4,7 +4,8 @@ import ( "math/big" "testing" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + "github.com/ethereum/go-ethereum/common" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -16,36 +17,34 @@ var ( upkeepId2 = big.NewInt(200) trigger1 = ocr2keepers.Trigger{ BlockNumber: block1, - BlockHash: "0x1231eqwe12eqwd", - Extension: core.LogTriggerExtension{ - LogIndex: 1, - TxHash: "0x1234567890123456789012345678901234567890123456789012345678901234", + BlockHash: common.HexToHash("0x1"), + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + Index: 1, + TxHash: common.HexToHash("0x1"), }, } trigger2 = ocr2keepers.Trigger{ BlockNumber: block3, - BlockHash: "0x1231eqwe12eqwd", - Extension: core.LogTriggerExtension{ - LogIndex: 1, - TxHash: "0x1234567890123456789012345678901234567890123456789012345678901234", + BlockHash: common.HexToHash("0x1"), + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + Index: 2, // a different BlockNumber isn't enough to generate a unique work ID, so we change the index here to generate a separate work ID + TxHash: common.HexToHash("0x1"), }, } - payload2, _ = core.NewUpkeepPayload(upkeepId1, conditionalType, trigger1, []byte{}) - payload3, _ = core.NewUpkeepPayload(upkeepId2, logTriggerType, trigger1, []byte{}) - payload4, _ = core.NewUpkeepPayload(upkeepId1, logTriggerType, trigger2, []byte{}) - payload5, _ = core.NewUpkeepPayload(upkeepId1, logTriggerType, trigger1, []byte{}) + payload2, _ = core.NewUpkeepPayload(upkeepId1, trigger1, []byte{}) + payload3, _ = core.NewUpkeepPayload(upkeepId2, trigger1, []byte{}) + payload4, _ = core.NewUpkeepPayload(upkeepId1, trigger2, []byte{}) + payload5, _ = core.NewUpkeepPayload(upkeepId1, trigger1, []byte{}) ) const ( - conditionalType = 0 - logTriggerType = 1 - block1 = 111 - block3 = 113 + block1 = 111 + block3 = 113 ) func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { p := ocr2keepers.Performed - e := ocr2keepers.Eligible + e := ocr2keepers.Ineligible tests := []struct { name string @@ -69,8 +68,8 @@ func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { payload4, payload5, // this overrides payload 2 bc they have the same payload ID }, - states: []ocr2keepers.UpkeepState{ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Eligible}, - oldIds: []string{payload2.ID, payload3.ID, payload4.ID}, + states: []ocr2keepers.UpkeepState{ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Ineligible}, + oldIds: []string{payload2.WorkID, payload3.WorkID, payload4.WorkID}, oldIdResult: []upkeepState{ { payload: &payload3, @@ -81,7 +80,7 @@ func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { state: &p, }, }, - newIds: []string{payload3.ID, payload4.ID, payload5.ID}, + newIds: []string{payload3.WorkID, payload4.WorkID, payload5.WorkID}, newIdResult: []upkeepState{ { payload: &payload3, diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index bc938ed6a80..f459fcd1673 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -15,6 +15,8 @@ import ( "github.com/smartcontractkit/chainlink-relay/pkg/types" + ocr2keepers21 "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" @@ -22,7 +24,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/models" kevm20 "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm20" kevm21 "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21" - "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) @@ -36,7 +37,7 @@ type Encoder interface { } type Encoder21 interface { - plugin.Encoder + ocr2keepers21.Encoder } var ( @@ -127,7 +128,7 @@ func EVMDependencies21( pr pipeline.Runner, mc *models.MercuryCredentials, keyring ocrtypes.OnchainKeyring, -) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, logprovider.LogEventProvider, ocr3types.OnchainKeyring[plugin.AutomationReportInfo], *kevm21.BlockSubscriber, error) { +) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[plugin.AutomationReportInfo], *kevm21.BlockSubscriber, error) { var err error var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider diff --git a/go.mod b/go.mod index 4aa072e0ff6..a7e6ada36ea 100644 --- a/go.mod +++ b/go.mod @@ -71,7 +71,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.5 + github.com/smartcontractkit/ocr2keepers v0.7.6 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index e778078b31a..d45c6e3758c 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= -github.com/smartcontractkit/ocr2keepers v0.7.5/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.6 h1:BIJGekJDHuvsKjqB2jCapNY+P16KypTLrAlsCcgkzZc= +github.com/smartcontractkit/ocr2keepers v0.7.6/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 7cd0c1bfae8..1be0876f9c6 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.5 + github.com/smartcontractkit/ocr2keepers v0.7.6 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.7 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 38448c2cdd2..8f5bb457bf9 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/chainlink-testing-framework v1.15.1 h1:/i+JuVgStYoiK github.com/smartcontractkit/chainlink-testing-framework v1.15.1/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.5 h1:aPRp8lxFoF4bycQWYjAgBCFGHlYRkXt9GPvHQTzbJyA= -github.com/smartcontractkit/ocr2keepers v0.7.5/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.6 h1:BIJGekJDHuvsKjqB2jCapNY+P16KypTLrAlsCcgkzZc= +github.com/smartcontractkit/ocr2keepers v0.7.6/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From 9ca4cba8369e64f5eb85d787fd0f9c57029909e1 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Wed, 9 Aug 2023 13:53:35 -0400 Subject: [PATCH 126/270] Fix contract typo (#10129) * add automation custom telem to job * fix contract typo * update --- contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol | 2 +- .../src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index 54c4aa81f54..19c42cfe5c8 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -749,7 +749,7 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { return (false, dedupID); } if (transmitInfo.upkeep.balance < transmitInfo.maxLinkPayment) { - // Can happen due to flucutations in gas / link prices + // Can happen due to fluctuations in gas / link prices emit InsufficientFundsUpkeepReport(upkeepId, rawTrigger); return (false, dedupID); } diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol index bc93e0cdb10..c26538b0923 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol @@ -189,7 +189,7 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { } /** - * @notice allows the owner to withdraw any LINK accidentially sent to the contract + * @notice allows the owner to withdraw any LINK accidentally sent to the contract */ function recoverFunds() external onlyOwner { uint256 total = i_link.balanceOf(address(this)); From 8e89b62488d74953312e1aa94fb68b2c9cc21037 Mon Sep 17 00:00:00 2001 From: JonWong203 <82334955+JonWong203@users.noreply.github.com> Date: Wed, 9 Aug 2023 14:06:36 -0400 Subject: [PATCH 127/270] config digest field added to proto messages (#10123) --- .../telem/telem_automation_custom.pb.go | 86 ++++++++++++------- .../telem/telem_automation_custom.proto | 2 + 2 files changed, 55 insertions(+), 33 deletions(-) diff --git a/core/services/synchronization/telem/telem_automation_custom.pb.go b/core/services/synchronization/telem/telem_automation_custom.pb.go index 507a169167e..e88cb2f951a 100644 --- a/core/services/synchronization/telem/telem_automation_custom.pb.go +++ b/core/services/synchronization/telem/telem_automation_custom.pb.go @@ -25,9 +25,10 @@ type BlockNumber struct { sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - BlockNumber uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` - BlockHash string `protobuf:"bytes,3,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"` + Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + BlockNumber uint64 `protobuf:"varint,2,opt,name=block_number,json=blockNumber,proto3" json:"block_number,omitempty"` + BlockHash string `protobuf:"bytes,3,opt,name=block_hash,json=blockHash,proto3" json:"block_hash,omitempty"` + ConfigDigest []byte `protobuf:"bytes,4,opt,name=config_digest,json=configDigest,proto3" json:"config_digest,omitempty"` } func (x *BlockNumber) Reset() { @@ -83,13 +84,21 @@ func (x *BlockNumber) GetBlockHash() string { return "" } +func (x *BlockNumber) GetConfigDigest() []byte { + if x != nil { + return x.ConfigDigest + } + return nil +} + type NodeVersion struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache unknownFields protoimpl.UnknownFields - Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - NodeVersion string `protobuf:"bytes,2,opt,name=node_version,json=nodeVersion,proto3" json:"node_version,omitempty"` + Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` + NodeVersion string `protobuf:"bytes,2,opt,name=node_version,json=nodeVersion,proto3" json:"node_version,omitempty"` + ConfigDigest []byte `protobuf:"bytes,3,opt,name=config_digest,json=configDigest,proto3" json:"config_digest,omitempty"` } func (x *NodeVersion) Reset() { @@ -138,6 +147,13 @@ func (x *NodeVersion) GetNodeVersion() string { return "" } +func (x *NodeVersion) GetConfigDigest() []byte { + if x != nil { + return x.ConfigDigest + } + return nil +} + type AutomationTelemWrapper struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -224,34 +240,38 @@ var File_telem_automation_custom_proto protoreflect.FileDescriptor var file_telem_automation_custom_proto_rawDesc = []byte{ 0x0a, 0x1d, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x5f, 0x61, 0x75, 0x74, 0x6f, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x63, 0x75, 0x73, 0x74, 0x6f, 0x6d, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, - 0x05, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x22, 0x6d, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, - 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, - 0x61, 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, - 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, - 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, - 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, 0x63, - 0x6b, 0x48, 0x61, 0x73, 0x68, 0x22, 0x4e, 0x0a, 0x0b, 0x4e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, - 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, - 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, - 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, - 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6e, 0x6f, 0x64, 0x65, 0x56, 0x65, - 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x22, 0x91, 0x01, 0x0a, 0x16, 0x41, 0x75, 0x74, 0x6f, 0x6d, 0x61, - 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x65, 0x6c, 0x65, 0x6d, 0x57, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, - 0x12, 0x37, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x2e, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x48, 0x00, 0x52, 0x0b, 0x62, 0x6c, - 0x6f, 0x63, 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x37, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, - 0x65, 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, - 0x12, 0x2e, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, - 0x69, 0x6f, 0x6e, 0x48, 0x00, 0x52, 0x0b, 0x6e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, - 0x6f, 0x6e, 0x42, 0x05, 0x0a, 0x03, 0x6d, 0x73, 0x67, 0x42, 0x4e, 0x5a, 0x4c, 0x67, 0x69, 0x74, - 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x63, 0x6f, 0x6e, - 0x74, 0x72, 0x61, 0x63, 0x74, 0x6b, 0x69, 0x74, 0x2f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x69, - 0x6e, 0x6b, 0x2f, 0x76, 0x32, 0x2f, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, - 0x63, 0x65, 0x73, 0x2f, 0x73, 0x79, 0x6e, 0x63, 0x68, 0x72, 0x6f, 0x6e, 0x69, 0x7a, 0x61, 0x74, - 0x69, 0x6f, 0x6e, 0x2f, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x33, + 0x05, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x22, 0x92, 0x01, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x63, 0x6b, + 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, + 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, + 0x74, 0x61, 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, + 0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, + 0x6b, 0x4e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x1d, 0x0a, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, + 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x09, 0x62, 0x6c, 0x6f, + 0x63, 0x6b, 0x48, 0x61, 0x73, 0x68, 0x12, 0x23, 0x0a, 0x0d, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, + 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0c, 0x63, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, 0x22, 0x73, 0x0a, 0x0b, 0x4e, + 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, + 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, + 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, 0x65, + 0x5f, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, + 0x6e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x12, 0x23, 0x0a, 0x0d, 0x63, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x64, 0x69, 0x67, 0x65, 0x73, 0x74, 0x18, 0x03, 0x20, 0x01, + 0x28, 0x0c, 0x52, 0x0c, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x44, 0x69, 0x67, 0x65, 0x73, 0x74, + 0x22, 0x91, 0x01, 0x0a, 0x16, 0x41, 0x75, 0x74, 0x6f, 0x6d, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x54, + 0x65, 0x6c, 0x65, 0x6d, 0x57, 0x72, 0x61, 0x70, 0x70, 0x65, 0x72, 0x12, 0x37, 0x0a, 0x0c, 0x62, + 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x65, 0x6c, 0x65, 0x6d, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, + 0x75, 0x6d, 0x62, 0x65, 0x72, 0x48, 0x00, 0x52, 0x0b, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x4e, 0x75, + 0x6d, 0x62, 0x65, 0x72, 0x12, 0x37, 0x0a, 0x0c, 0x6e, 0x6f, 0x64, 0x65, 0x5f, 0x76, 0x65, 0x72, + 0x73, 0x69, 0x6f, 0x6e, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x74, 0x65, 0x6c, + 0x65, 0x6d, 0x2e, 0x4e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x48, 0x00, + 0x52, 0x0b, 0x6e, 0x6f, 0x64, 0x65, 0x56, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x42, 0x05, 0x0a, + 0x03, 0x6d, 0x73, 0x67, 0x42, 0x4e, 0x5a, 0x4c, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, + 0x6f, 0x6d, 0x2f, 0x73, 0x6d, 0x61, 0x72, 0x74, 0x63, 0x6f, 0x6e, 0x74, 0x72, 0x61, 0x63, 0x74, + 0x6b, 0x69, 0x74, 0x2f, 0x63, 0x68, 0x61, 0x69, 0x6e, 0x6c, 0x69, 0x6e, 0x6b, 0x2f, 0x76, 0x32, + 0x2f, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2f, 0x73, + 0x79, 0x6e, 0x63, 0x68, 0x72, 0x6f, 0x6e, 0x69, 0x7a, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x2f, 0x74, + 0x65, 0x6c, 0x65, 0x6d, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/core/services/synchronization/telem/telem_automation_custom.proto b/core/services/synchronization/telem/telem_automation_custom.proto index a1b338c6899..bded8e8b70a 100644 --- a/core/services/synchronization/telem/telem_automation_custom.proto +++ b/core/services/synchronization/telem/telem_automation_custom.proto @@ -8,11 +8,13 @@ message BlockNumber { uint64 timestamp = 1; uint64 block_number = 2; string block_hash = 3; + bytes config_digest = 4; } message NodeVersion { uint64 timestamp = 1; string node_version = 2; + bytes config_digest = 3; } message AutomationTelemWrapper{ From d0d1adc5c0a654f65f23ceb0c5a9a356d30f159c Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Thu, 10 Aug 2023 00:38:52 +0300 Subject: [PATCH 128/270] TT-433 OCRv2 Smoke Test (local env) (#10135) * ocrv2 test * turn off logwatch --- .../actions/ocr2_helpers_local.go | 269 ++++++++++++++++++ integration-tests/docker/test_env/test_env.go | 3 +- .../docker/test_env/test_env_builder.go | 101 ++----- integration-tests/smoke/ocr2_test.go | 63 ++-- integration-tests/types/config/node/core.go | 23 ++ 5 files changed, 348 insertions(+), 111 deletions(-) create mode 100644 integration-tests/actions/ocr2_helpers_local.go diff --git a/integration-tests/actions/ocr2_helpers_local.go b/integration-tests/actions/ocr2_helpers_local.go new file mode 100644 index 00000000000..c1e863561da --- /dev/null +++ b/integration-tests/actions/ocr2_helpers_local.go @@ -0,0 +1,269 @@ +package actions + +import ( + "crypto/ed25519" + "encoding/hex" + "fmt" + "github.com/ethereum/go-ethereum/common" + "github.com/google/uuid" + "github.com/lib/pq" + "github.com/rs/zerolog/log" + ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" + "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "github.com/smartcontractkit/libocr/offchainreporting2/reportingplugin/median" + "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "golang.org/x/sync/errgroup" + "gopkg.in/guregu/null.v4" + "strings" + "time" +) + +func CreateOCRv2JobsLocal( + ocrInstances []contracts.OffchainAggregatorV2, + bootstrapNode *client.ChainlinkClient, + workerChainlinkNodes []*client.ChainlinkClient, + mockserver *ctfClient.MockserverClient, + mockServerPath string, // Path on the mock server for the Chainlink nodes to query + mockServerValue int, // Value to get from the mock server when querying the path + chainId uint64, // EVM chain ID + forwardingAllowed bool, +) error { + // Collect P2P ID + bootstrapP2PIds, err := bootstrapNode.MustReadP2PKeys() + if err != nil { + return err + } + p2pV2Bootstrapper := fmt.Sprintf("%s@%s:%d", bootstrapP2PIds.Data[0].Attributes.PeerID, bootstrapNode.InternalIP(), 6690) + // Set the value for the jobs to report on + err = mockserver.SetValuePath(mockServerPath, mockServerValue) + if err != nil { + return err + } + // Set the juelsPerFeeCoinSource config value + err = mockserver.SetValuePath(fmt.Sprintf("%s/juelsPerFeeCoinSource", mockServerPath), mockServerValue) + if err != nil { + return err + } + + for _, ocrInstance := range ocrInstances { + bootstrapSpec := &client.OCR2TaskJobSpec{ + Name: fmt.Sprintf("ocr2_bootstrap-%s", uuid.NewString()), + JobType: "bootstrap", + OCR2OracleSpec: job.OCR2OracleSpec{ + ContractID: ocrInstance.Address(), + Relay: "evm", + RelayConfig: map[string]interface{}{ + "chainID": chainId, + }, + MonitoringEndpoint: null.StringFrom(fmt.Sprintf("%s/%s", mockserver.Config.ClusterURL, mockServerPath)), + ContractConfigTrackerPollInterval: *models.NewInterval(15 * time.Second), + }, + } + _, err := bootstrapNode.MustCreateJob(bootstrapSpec) + if err != nil { + return fmt.Errorf("creating bootstrap job have failed: %w", err) + } + + for _, chainlinkNode := range workerChainlinkNodes { + nodeTransmitterAddress, err := chainlinkNode.PrimaryEthAddress() + if err != nil { + return fmt.Errorf("getting primary ETH address from OCR node have failed: %w", err) + } + nodeOCRKeys, err := chainlinkNode.MustReadOCR2Keys() + if err != nil { + return fmt.Errorf("getting OCR keys from OCR node have failed: %w", err) + } + nodeOCRKeyId := nodeOCRKeys.Data[0].ID + + bta := &client.BridgeTypeAttributes{ + Name: fmt.Sprintf("%s-%s", mockServerPath, uuid.NewString()), + URL: fmt.Sprintf("%s/%s", mockserver.Config.ClusterURL, mockServerPath), + } + juelsBridge := &client.BridgeTypeAttributes{ + Name: fmt.Sprintf("juels-%s", uuid.NewString()), + URL: fmt.Sprintf("%s/%s/juelsPerFeeCoinSource", mockserver.Config.ClusterURL, mockServerPath), + } + err = chainlinkNode.MustCreateBridge(bta) + if err != nil { + return fmt.Errorf("creating bridge job have failed: %w", err) + } + err = chainlinkNode.MustCreateBridge(juelsBridge) + if err != nil { + return fmt.Errorf("creating bridge job have failed: %w", err) + } + + ocrSpec := &client.OCR2TaskJobSpec{ + Name: fmt.Sprintf("ocr2-%s", uuid.NewString()), + JobType: "offchainreporting2", + MaxTaskDuration: "1m", + ObservationSource: client.ObservationSourceSpecBridge(bta), + ForwardingAllowed: forwardingAllowed, + OCR2OracleSpec: job.OCR2OracleSpec{ + PluginType: "median", + Relay: "evm", + RelayConfig: map[string]interface{}{ + "chainID": chainId, + }, + PluginConfig: map[string]any{ + "juelsPerFeeCoinSource": fmt.Sprintf("\"\"\"%s\"\"\"", client.ObservationSourceSpecBridge(juelsBridge)), + }, + ContractConfigTrackerPollInterval: *models.NewInterval(15 * time.Second), + ContractID: ocrInstance.Address(), // registryAddr + OCRKeyBundleID: null.StringFrom(nodeOCRKeyId), // get node ocr2config.ID + TransmitterID: null.StringFrom(nodeTransmitterAddress), // node addr + P2PV2Bootstrappers: pq.StringArray{p2pV2Bootstrapper}, // bootstrap node key and address @bootstrap:6690 + }, + } + _, err = chainlinkNode.MustCreateJob(ocrSpec) + if err != nil { + return fmt.Errorf("creating OCR task job on OCR node have failed: %w", err) + } + } + } + return nil +} + +func BuildMedianOCR2ConfigLocal(workerNodes []*client.ChainlinkClient) (*contracts.OCRv2Config, error) { + S, oracleIdentities, err := GetOracleIdentitiesWithKeyIndexLocal(workerNodes, 0) + if err != nil { + return nil, err + } + signerKeys, transmitterAccounts, f_, onchainConfig, offchainConfigVersion, offchainConfig, err := confighelper.ContractSetConfigArgsForTests( + 30*time.Second, // deltaProgress time.Duration, + 30*time.Second, // deltaResend time.Duration, + 10*time.Second, // deltaRound time.Duration, + 20*time.Second, // deltaGrace time.Duration, + 20*time.Second, // deltaStage time.Duration, + 3, // rMax uint8, + S, // s []int, + oracleIdentities, // oracles []OracleIdentityExtra, + median.OffchainConfig{ + AlphaReportInfinite: false, + AlphaReportPPB: 1, + AlphaAcceptInfinite: false, + AlphaAcceptPPB: 1, + DeltaC: time.Minute * 30, + }.Encode(), // reportingPluginConfig []byte, + 5*time.Second, // maxDurationQuery time.Duration, + 5*time.Second, // maxDurationObservation time.Duration, + 5*time.Second, // maxDurationReport time.Duration, + 5*time.Second, // maxDurationShouldAcceptFinalizedReport time.Duration, + 5*time.Second, // maxDurationShouldTransmitAcceptedReport time.Duration, + 1, // f int, + nil, // The median reporting plugin has an empty onchain config + ) + if err != nil { + return nil, err + } + + // Convert signers to addresses + var signerAddresses []common.Address + for _, signer := range signerKeys { + signerAddresses = append(signerAddresses, common.BytesToAddress(signer)) + } + + // Convert transmitters to addresses + var transmitterAddresses []common.Address + for _, account := range transmitterAccounts { + transmitterAddresses = append(transmitterAddresses, common.HexToAddress(string(account))) + } + + return &contracts.OCRv2Config{ + Signers: signerAddresses, + Transmitters: transmitterAddresses, + F: f_, + OnchainConfig: onchainConfig, + OffchainConfigVersion: offchainConfigVersion, + OffchainConfig: []byte(fmt.Sprintf("0x%s", offchainConfig)), + }, nil +} + +func GetOracleIdentitiesWithKeyIndexLocal( + chainlinkNodes []*client.ChainlinkClient, + keyIndex int, +) ([]int, []confighelper.OracleIdentityExtra, error) { + S := make([]int, len(chainlinkNodes)) + oracleIdentities := make([]confighelper.OracleIdentityExtra, len(chainlinkNodes)) + sharedSecretEncryptionPublicKeys := make([]types.ConfigEncryptionPublicKey, len(chainlinkNodes)) + eg := &errgroup.Group{} + for i, cl := range chainlinkNodes { + index, chainlinkNode := i, cl + eg.Go(func() error { + addresses, err := chainlinkNode.EthAddresses() + if err != nil { + return err + } + ocr2Keys, err := chainlinkNode.MustReadOCR2Keys() + if err != nil { + return err + } + var ocr2Config client.OCR2KeyAttributes + for _, key := range ocr2Keys.Data { + if key.Attributes.ChainType == string(chaintype.EVM) { + ocr2Config = key.Attributes + break + } + } + + keys, err := chainlinkNode.MustReadP2PKeys() + if err != nil { + return err + } + p2pKeyID := keys.Data[0].Attributes.PeerID + + offchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OffChainPublicKey, "ocr2off_evm_")) + if err != nil { + return err + } + + offchainPkBytesFixed := [ed25519.PublicKeySize]byte{} + n := copy(offchainPkBytesFixed[:], offchainPkBytes) + if n != ed25519.PublicKeySize { + return fmt.Errorf("wrong number of elements copied") + } + + configPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.ConfigPublicKey, "ocr2cfg_evm_")) + if err != nil { + return err + } + + configPkBytesFixed := [ed25519.PublicKeySize]byte{} + n = copy(configPkBytesFixed[:], configPkBytes) + if n != ed25519.PublicKeySize { + return fmt.Errorf("wrong number of elements copied") + } + + onchainPkBytes, err := hex.DecodeString(strings.TrimPrefix(ocr2Config.OnChainPublicKey, "ocr2on_evm_")) + if err != nil { + return err + } + + sharedSecretEncryptionPublicKeys[index] = configPkBytesFixed + oracleIdentities[index] = confighelper.OracleIdentityExtra{ + OracleIdentity: confighelper.OracleIdentity{ + OnchainPublicKey: onchainPkBytes, + OffchainPublicKey: offchainPkBytesFixed, + PeerID: p2pKeyID, + TransmitAccount: types.Account(addresses[keyIndex]), + }, + ConfigEncryptionPublicKey: configPkBytesFixed, + } + S[index] = 1 + log.Debug(). + Interface("OnChainPK", onchainPkBytes). + Interface("OffChainPK", offchainPkBytesFixed). + Interface("ConfigPK", configPkBytesFixed). + Str("PeerID", p2pKeyID). + Str("Address", addresses[keyIndex]). + Msg("Oracle identity") + return nil + }) + } + + return S, oracleIdentities, eg.Wait() +} diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index 895f08782c9..6d76a7f82e0 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -102,8 +102,7 @@ func (te *CLClusterTestEnv) StartClNodes(nodeConfig *chainlink.Config, count int } n := NewClNode([]string{te.Network.Name}, nodeConfig, WithNodeContainerName(nodeContainerName), - WithDbContainerName(dbContainerName), - WithLogWatch(te.LogWatch)) + WithDbContainerName(dbContainerName)) err := n.StartContainer() if err != nil { mu.Lock() diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index 43eb3a48aa2..bd28a1dabe4 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -6,6 +6,7 @@ import ( "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "math/big" ) @@ -13,6 +14,7 @@ type CLTestEnvBuilder struct { hasLogWatch bool hasGeth bool hasMockServer bool + clNodeConfig *chainlink.Config clNodesCount int externalAdapterCount int customNodeCsaKeys []string @@ -48,6 +50,11 @@ func (b *CLTestEnvBuilder) WithGeth() *CLTestEnvBuilder { return b } +func (b *CLTestEnvBuilder) WithCLNodeConfig(cfg *chainlink.Config) *CLTestEnvBuilder { + b.clNodeConfig = cfg + return b +} + func (b *CLTestEnvBuilder) WithMockServer(externalAdapterCount int) *CLTestEnvBuilder { b.hasMockServer = true b.externalAdapterCount = externalAdapterCount @@ -62,12 +69,12 @@ func (b *CLTestEnvBuilder) Build() (*CLClusterTestEnv, error) { return nil, err } _ = os.Setenv("TESTCONTAINERS_RYUK_DISABLED", "true") - return b.connectExistingEnv(cfg) + return b.buildNewEnv(cfg) } - return b.buildNewEnv() + return b.buildNewEnv(nil) } -func (b *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { +func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { log.Info(). Bool("hasGeth", b.hasGeth). Bool("hasMockServer", b.hasMockServer). @@ -76,75 +83,19 @@ func (b *CLTestEnvBuilder) connectExistingEnv(cfg *TestEnvConfig) (*CLClusterTes Strs("customNodeCsaKeys", b.customNodeCsaKeys). Strs("defaultNodeCsaKeys", b.defaultNodeCsaKeys). Msg("Building CL cluster test environment..") - te, err := NewTestEnvFromCfg(cfg) - if err != nil { - return te, err - } - - if b.hasLogWatch { - lw, err := logwatch.NewLogWatch(nil, nil) - if err != nil { - return te, err - } - te.LogWatch = lw - } - - if b.hasMockServer { - err := te.StartMockServer() - if err != nil { - return te, err - } - err = te.MockServer.SetExternalAdapterMocks(b.externalAdapterCount) - if err != nil { - return te, err - } - } - - if b.hasGeth { - err := te.StartGeth() - if err != nil { - return te, err - } - } - var nodeCsaKeys []string - - // Start Chainlink Nodes - if b.clNodesCount > 0 { - // Create nodes - nodeConfig := node.NewConfig(node.BaseConf, - node.WithOCR1(), - node.WithP2Pv1(), - node.WithSimulatedEVM(te.Geth.InternalHttpUrl, te.Geth.InternalWsUrl), - ) - err = te.StartClNodes(nodeConfig, b.clNodesCount) + var te *CLClusterTestEnv + var err error + if cfg != nil { + te, err = NewTestEnvFromCfg(cfg) if err != nil { return te, err } - - nodeCsaKeys, err = te.GetNodeCSAKeys() + } else { + te, err = NewTestEnv() if err != nil { return te, err } - b.defaultNodeCsaKeys = nodeCsaKeys - } - - return te, nil -} - -func (b *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { - log.Info(). - Bool("hasGeth", b.hasGeth). - Bool("hasMockServer", b.hasMockServer). - Int("externalAdapterCount", b.externalAdapterCount). - Int("clNodesCount", b.clNodesCount). - Strs("customNodeCsaKeys", b.customNodeCsaKeys). - Strs("defaultNodeCsaKeys", b.defaultNodeCsaKeys). - Msg("Building CL cluster test environment..") - - te, err := NewTestEnv() - if err != nil { - return te, err } if b.hasLogWatch { @@ -177,13 +128,17 @@ func (b *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { // Start Chainlink Nodes if b.clNodesCount > 0 { - // Create nodes - nodeConfig := node.NewConfig(node.BaseConf, - node.WithOCR1(), - node.WithP2Pv1(), - node.WithSimulatedEVM(te.Geth.InternalHttpUrl, te.Geth.InternalWsUrl), - ) - err = te.StartClNodes(nodeConfig, b.clNodesCount) + var cfg *chainlink.Config + if b.clNodeConfig != nil { + cfg = b.clNodeConfig + } else { + cfg = node.NewConfig(node.BaseConf, + node.WithOCR1(), + node.WithP2Pv1(), + ) + } + node.SetDefaultSimulatedGeth(cfg, te.Geth.InternalWsUrl, te.Geth.InternalHttpUrl) + err := te.StartClNodes(cfg, b.clNodesCount) if err != nil { return te, err } @@ -198,7 +153,7 @@ func (b *CLTestEnvBuilder) buildNewEnv() (*CLClusterTestEnv, error) { if b.hasGeth && b.clNodesCount > 0 && b.ETHFunds != nil { te.ParallelTransactions(true) defer te.ParallelTransactions(false) - if err = te.FundChainlinkNodes(b.ETHFunds); err != nil { + if err := te.FundChainlinkNodes(b.ETHFunds); err != nil { return te, err } } diff --git a/integration-tests/smoke/ocr2_test.go b/integration-tests/smoke/ocr2_test.go index a9f374c607a..c49b98ee36b 100644 --- a/integration-tests/smoke/ocr2_test.go +++ b/integration-tests/smoke/ocr2_test.go @@ -4,56 +4,47 @@ import ( "context" "fmt" "math/big" - "strings" "testing" "time" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - "github.com/smartcontractkit/chainlink-env/environment" "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/config" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" + "github.com/stretchr/testify/require" + "strings" ) // Tests a basic OCRv2 median feed func TestOCRv2Basic(t *testing.T) { - testEnvironment, testNetwork := setupOCR2Test(t, false) - if testEnvironment.WillUseRemoteRunner() { - return - } + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodeConfig(node.NewConfig(node.BaseConf, + node.WithOCR2(), + node.WithP2Pv2(), + )). + WithCLNodes(6). + WithFunding(big.NewFloat(10)). + Build() + require.NoError(t, err) + env.ParallelTransactions(true) - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - bootstrapNode, workerNodes := chainlinkNodes[0], chainlinkNodes[1:] - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Creating mockserver clients shouldn't fail") - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - chainClient.ParallelTransactions(true) + nodeClients := env.GetAPIs() + bootstrapNode, workerNodes := nodeClients[0], nodeClients[1:] - linkToken, err := contractDeployer.DeployLinkTokenContract() + linkToken, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodes(workerNodes, chainClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") // Gather transmitters @@ -66,19 +57,19 @@ func TestOCRv2Basic(t *testing.T) { transmitters = append(transmitters, addr) } - aggregatorContracts, err := actions.DeployOCRv2Contracts(1, linkToken, contractDeployer, transmitters, chainClient) + aggregatorContracts, err := actions.DeployOCRv2Contracts(1, linkToken, env.Geth.ContractDeployer, transmitters, env.Geth.EthClient) require.NoError(t, err, "Error deploying OCRv2 aggregator contracts") - err = actions.CreateOCRv2Jobs(aggregatorContracts, bootstrapNode, workerNodes, mockServer, "ocr2", 5, chainClient.GetChainID().Uint64(), false) + err = actions.CreateOCRv2JobsLocal(aggregatorContracts, bootstrapNode, workerNodes, env.MockServer.Client, "ocr2", 5, env.Geth.EthClient.GetChainID().Uint64(), false) require.NoError(t, err, "Error creating OCRv2 jobs") - ocrv2Config, err := actions.BuildMedianOCR2Config(workerNodes) + ocrv2Config, err := actions.BuildMedianOCR2ConfigLocal(workerNodes) require.NoError(t, err, "Error building OCRv2 config") - err = actions.ConfigureOCRv2AggregatorContracts(chainClient, ocrv2Config, aggregatorContracts) + err = actions.ConfigureOCRv2AggregatorContracts(env.Geth.EthClient, ocrv2Config, aggregatorContracts) require.NoError(t, err, "Error configuring OCRv2 aggregator contracts") - err = actions.StartNewOCR2Round(1, aggregatorContracts, chainClient, time.Minute*5) + err = actions.StartNewOCR2Round(1, aggregatorContracts, env.Geth.EthClient, time.Minute*5) require.NoError(t, err, "Error starting new OCR2 round") roundData, err := aggregatorContracts[0].GetRound(context.Background(), big.NewInt(1)) require.NoError(t, err, "Getting latest answer from OCR contract shouldn't fail") @@ -87,9 +78,9 @@ func TestOCRv2Basic(t *testing.T) { roundData.Answer.Int64(), ) - err = mockServer.SetValuePath("ocr2", 10) + err = env.MockServer.Client.SetValuePath("ocr2", 10) require.NoError(t, err) - err = actions.StartNewOCR2Round(2, aggregatorContracts, chainClient, time.Minute*5) + err = actions.StartNewOCR2Round(2, aggregatorContracts, env.Geth.EthClient, time.Minute*5) require.NoError(t, err) roundData, err = aggregatorContracts[0].GetRound(context.Background(), big.NewInt(2)) diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go index 43b8ff84ab8..a4aeb1b7edd 100644 --- a/integration-tests/types/config/node/core.go +++ b/integration-tests/types/config/node/core.go @@ -93,6 +93,29 @@ func WithP2Pv2() NodeConfigOpt { } } +func SetDefaultSimulatedGeth(cfg *chainlink.Config, ws, http string) { + if cfg.EVM == nil { + cfg.EVM = evmcfg.EVMConfigs{ + { + ChainID: utils.NewBig(big.NewInt(1337)), + Chain: evmcfg.Chain{ + AutoCreateKey: ptr(true), + FinalityDepth: ptr[uint32](1), + MinContractPayment: assets.NewLinkFromJuels(0), + }, + Nodes: []*evmcfg.Node{ + { + Name: ptr("1337_primary_local_0"), + WSURL: mustURL(ws), + HTTPURL: mustURL(http), + SendOnly: ptr(false), + }, + }, + }, + } + } +} + func WithSimulatedEVM(httpUrl, wsUrl string) NodeConfigOpt { return func(c *chainlink.Config) { c.EVM = evmcfg.EVMConfigs{ From f0ae2c451ed8572471dd9d41b2a14289d43aa8c0 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Thu, 10 Aug 2023 10:54:54 +0100 Subject: [PATCH 129/270] Cleanup ocr2keepers v2 package split (#10136) * Cleanup ocr2keepers v2 package split * move runner * update * remove encoding from 21 * update * update config * update to ocr2keepers tag --- .../chaincli/handler/keeper_deployer.go | 6 ++-- core/scripts/chaincli/handler/ocr2_config.go | 4 +-- core/scripts/chaincli/handler/report.go | 4 +-- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +-- core/services/ocr2/delegate.go | 31 ++++++++++--------- .../ocr2/plugins/ocr2keeper/evm20/abi.go | 2 +- .../ocr2/plugins/ocr2keeper/evm20/abi_test.go | 2 +- .../ocr2/plugins/ocr2keeper/evm20/encoder.go | 4 +-- .../plugins/ocr2keeper/evm20/encoder_test.go | 2 +- .../ocr2/plugins/ocr2keeper/evm20/head.go | 2 +- .../plugins/ocr2keeper/evm20/log_provider.go | 4 +-- .../ocr2/plugins/ocr2keeper/evm20/registry.go | 2 +- .../plugins/ocr2keeper/evm20/registry_test.go | 2 +- .../ocr2/plugins/ocr2keeper/evm21/encoder.go | 2 -- .../plugins/ocr2keeper/integration_21_test.go | 2 +- .../plugins/ocr2keeper/integration_test.go | 2 +- core/services/ocr2/plugins/ocr2keeper/util.go | 26 ++++++++-------- go.mod | 2 +- go.sum | 4 +-- .../actions/automation_ocr_helpers.go | 4 +-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +-- 23 files changed, 59 insertions(+), 60 deletions(-) diff --git a/core/scripts/chaincli/handler/keeper_deployer.go b/core/scripts/chaincli/handler/keeper_deployer.go index a53f236453a..089b176695c 100644 --- a/core/scripts/chaincli/handler/keeper_deployer.go +++ b/core/scripts/chaincli/handler/keeper_deployer.go @@ -19,7 +19,7 @@ import ( "github.com/smartcontractkit/chainlink/core/scripts/chaincli/config" - offchain "github.com/smartcontractkit/ocr2keepers/pkg/config" + offchain20config "github.com/smartcontractkit/ocr2keepers/pkg/v2/config" "github.com/smartcontractkit/chainlink/v2/core/cmd" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" @@ -148,7 +148,7 @@ func (d *v20KeeperDeployer) SetKeepers(opts *bind.TransactOpts, cls []cmd.HTTPCl } wg.Wait() - offC, err := json.Marshal(offchain.OffchainConfig{ + offC, err := json.Marshal(offchain20config.OffchainConfig{ PerformLockoutWindow: 100 * 3 * 1000, // ~100 block lockout (on mumbai) MinConfirmations: 1, }) @@ -288,7 +288,7 @@ func (d *v21KeeperDeployer) SetKeepers(opts *bind.TransactOpts, cls []cmd.HTTPCl } wg.Wait() - offC, err := json.Marshal(offchain.OffchainConfig{ + offC, err := json.Marshal(offchain20config.OffchainConfig{ PerformLockoutWindow: 100 * 3 * 1000, // ~100 block lockout (on mumbai) MinConfirmations: 1, MercuryLookup: d.cfg.UpkeepType == config.Mercury || d.cfg.UpkeepType == config.LogTriggeredFeedLookup, diff --git a/core/scripts/chaincli/handler/ocr2_config.go b/core/scripts/chaincli/handler/ocr2_config.go index 4586fdbc419..7cf25364058 100644 --- a/core/scripts/chaincli/handler/ocr2_config.go +++ b/core/scripts/chaincli/handler/ocr2_config.go @@ -12,7 +12,7 @@ import ( "github.com/ethereum/go-ethereum/core/types" "github.com/olekukonko/tablewriter" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" - ocr2config "github.com/smartcontractkit/ocr2keepers/pkg/config" + ocr2keepers20config "github.com/smartcontractkit/ocr2keepers/pkg/v2/config" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" ) @@ -112,7 +112,7 @@ func printConfigValues(config *confighelper.PublicConfig) { data = append(data, []string{"MaxDurationShouldTransmitAcceptedReport", config.MaxDurationShouldTransmitAcceptedReport.String()}) data = append(data, []string{"F", fmt.Sprintf("%v", config.F)}) - if offConf, err := ocr2config.DecodeOffchainConfig(config.ReportingPluginConfig); err == nil { + if offConf, err := ocr2keepers20config.DecodeOffchainConfig(config.ReportingPluginConfig); err == nil { data = append(data, []string{"", ""}) data = append(data, []string{"TargetProbability", offConf.TargetProbability}) data = append(data, []string{"GasLimitPerReport", fmt.Sprintf("%d", offConf.GasLimitPerReport)}) diff --git a/core/scripts/chaincli/handler/report.go b/core/scripts/chaincli/handler/report.go index d1523632dbf..90f2be96548 100644 --- a/core/scripts/chaincli/handler/report.go +++ b/core/scripts/chaincli/handler/report.go @@ -17,7 +17,7 @@ import ( "github.com/ethereum/go-ethereum/rpc" "github.com/olekukonko/tablewriter" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers20 "github.com/smartcontractkit/ocr2keepers/pkg/v2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" evm "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm20" @@ -294,7 +294,7 @@ type OCR2TransmitTx struct { OCR2Transaction } -func (t *OCR2TransmitTx) UpkeepsInTransmit() ([]ocr2keepers.UpkeepResult, error) { +func (t *OCR2TransmitTx) UpkeepsInTransmit() ([]ocr2keepers20.UpkeepResult, error) { txData := t.tx.Data() diff --git a/core/scripts/go.mod b/core/scripts/go.mod index bb43820b416..ef684bea070 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.6 + github.com/smartcontractkit/ocr2keepers v0.7.7 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 88b190394fe..d39c13df553 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.6 h1:BIJGekJDHuvsKjqB2jCapNY+P16KypTLrAlsCcgkzZc= -github.com/smartcontractkit/ocr2keepers v0.7.6/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= +github.com/smartcontractkit/ocr2keepers v0.7.7/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 0ad12b6f981..2ee64582664 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -17,11 +17,12 @@ import ( "github.com/smartcontractkit/libocr/commontypes" libocr2 "github.com/smartcontractkit/libocr/offchainreporting2plus" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - ocr2keepers20 "github.com/smartcontractkit/ocr2keepers/pkg" - ocr2keepersconfig "github.com/smartcontractkit/ocr2keepers/pkg/config" - ocr2keepers20coordinator "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" - ocr2keepers20polling "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" - ocr2keepers20runner "github.com/smartcontractkit/ocr2keepers/pkg/runner" + ocr2keepers20 "github.com/smartcontractkit/ocr2keepers/pkg/v2" + ocr2keepers20config "github.com/smartcontractkit/ocr2keepers/pkg/v2/config" + ocr2keepers20coordinator "github.com/smartcontractkit/ocr2keepers/pkg/v2/coordinator" + ocr2keepers20polling "github.com/smartcontractkit/ocr2keepers/pkg/v2/observer/polling" + ocr2keepers20runner "github.com/smartcontractkit/ocr2keepers/pkg/v2/runner" + ocr2keepers21config "github.com/smartcontractkit/ocr2keepers/pkg/v3/config" ocr2keepers21 "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" ocr2keepers21types "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/ocr2vrf/altbn_128" @@ -880,11 +881,11 @@ func (d *Delegate) newServicesOCR2Keepers21( } // set some defaults - conf := ocr2keepersconfig.ReportingFactoryConfig{ - CacheExpiration: ocr2keepersconfig.DefaultCacheExpiration, - CacheEvictionInterval: ocr2keepersconfig.DefaultCacheClearInterval, - MaxServiceWorkers: ocr2keepersconfig.DefaultMaxServiceWorkers, - ServiceQueueLength: ocr2keepersconfig.DefaultServiceQueueLength, + conf := ocr2keepers21config.ReportingFactoryConfig{ + CacheExpiration: ocr2keepers21config.DefaultCacheExpiration, + CacheEvictionInterval: ocr2keepers21config.DefaultCacheClearInterval, + MaxServiceWorkers: ocr2keepers21config.DefaultMaxServiceWorkers, + ServiceQueueLength: ocr2keepers21config.DefaultServiceQueueLength, } // override if set in config @@ -974,11 +975,11 @@ func (d *Delegate) newServicesOCR2Keepers20( w := &logWriter{log: lggr.Named("Automation Dependencies")} // set some defaults - conf := ocr2keepersconfig.ReportingFactoryConfig{ - CacheExpiration: ocr2keepersconfig.DefaultCacheExpiration, - CacheEvictionInterval: ocr2keepersconfig.DefaultCacheClearInterval, - MaxServiceWorkers: ocr2keepersconfig.DefaultMaxServiceWorkers, - ServiceQueueLength: ocr2keepersconfig.DefaultServiceQueueLength, + conf := ocr2keepers20config.ReportingFactoryConfig{ + CacheExpiration: ocr2keepers20config.DefaultCacheExpiration, + CacheEvictionInterval: ocr2keepers20config.DefaultCacheClearInterval, + MaxServiceWorkers: ocr2keepers20config.DefaultMaxServiceWorkers, + ServiceQueueLength: ocr2keepers20config.DefaultServiceQueueLength, } // override if set in config diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm20/abi.go index 20f600972ec..4c0beee8fd6 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/abi.go @@ -8,7 +8,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" ) type evmRegistryPackerV2_0 struct { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm20/abi_test.go index 37e887908ed..7efc3feb1f0 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/abi_test.go @@ -8,7 +8,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common/hexutil" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" "github.com/stretchr/testify/assert" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm20/encoder.go index bbb2b1c052a..3984cb7496b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/encoder.go @@ -6,8 +6,8 @@ import ( "reflect" "github.com/ethereum/go-ethereum/accounts/abi" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - "github.com/smartcontractkit/ocr2keepers/pkg/encoding" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" + "github.com/smartcontractkit/ocr2keepers/pkg/v2/encoding" ) type EVMAutomationEncoder20 struct { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm20/encoder_test.go index 2e49c02f260..74be6b46ee5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/encoder_test.go @@ -5,7 +5,7 @@ import ( "testing" "github.com/pkg/errors" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" "github.com/stretchr/testify/assert" ) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/head.go b/core/services/ocr2/plugins/ocr2keeper/evm20/head.go index 152ca4f6ce9..1023bff5dd2 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/head.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/head.go @@ -4,7 +4,7 @@ import ( "context" "fmt" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/log_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm20/log_provider.go index e5fa073fd27..69533e95869 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/log_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/log_provider.go @@ -10,9 +10,9 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" gethtypes "github.com/ethereum/go-ethereum/core/types" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - "github.com/smartcontractkit/ocr2keepers/pkg/encoding" pluginutils "github.com/smartcontractkit/ocr2keepers/pkg/util" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" + "github.com/smartcontractkit/ocr2keepers/pkg/v2/encoding" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm20/registry.go index f437f95480c..82cad9d4a5b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/registry.go @@ -15,7 +15,7 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/ethereum/go-ethereum/rpc" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" "go.uber.org/multierr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" diff --git a/core/services/ocr2/plugins/ocr2keeper/evm20/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm20/registry_test.go index 1d84cd2b4b2..348b5a47c0f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm20/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm20/registry_test.go @@ -8,7 +8,7 @@ import ( "time" "github.com/ethereum/go-ethereum/common" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v2" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go index 42d08461d89..cfdd26d3fd5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go @@ -4,7 +4,6 @@ import ( "fmt" "math/big" - "github.com/smartcontractkit/ocr2keepers/pkg/encoding" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -16,7 +15,6 @@ var ( ) type EVMAutomationEncoder21 struct { - encoding.BasicEncoder packer *evmRegistryPackerV2_1 } diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go index 2fd21d400c7..25243580805 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go @@ -23,7 +23,7 @@ import ( "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" ocrTypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - "github.com/smartcontractkit/ocr2keepers/pkg/config" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/config" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/umbracle/ethgo/abi" diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_test.go index 453aac147c5..b5c077124a3 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_test.go @@ -23,7 +23,7 @@ import ( "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" ocrTypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - "github.com/smartcontractkit/ocr2keepers/pkg/config" + "github.com/smartcontractkit/ocr2keepers/pkg/v2/config" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index f459fcd1673..8c79f13844a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -6,11 +6,11 @@ import ( "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg" - "github.com/smartcontractkit/ocr2keepers/pkg/coordinator" - "github.com/smartcontractkit/ocr2keepers/pkg/observer/polling" - "github.com/smartcontractkit/ocr2keepers/pkg/runner" - "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" + ocr2keepers20 "github.com/smartcontractkit/ocr2keepers/pkg/v2" + ocr2keepers20coordinator "github.com/smartcontractkit/ocr2keepers/pkg/v2/coordinator" + ocr2keepers20polling "github.com/smartcontractkit/ocr2keepers/pkg/v2/observer/polling" + ocr2keepers20runner "github.com/smartcontractkit/ocr2keepers/pkg/v2/runner" + ocr2keepers21plugin "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" "github.com/smartcontractkit/sqlx" "github.com/smartcontractkit/chainlink-relay/pkg/types" @@ -28,12 +28,12 @@ import ( evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) -type Encoder interface { - ocr2keepers.Encoder - coordinator.Encoder - polling.Encoder - runner.Encoder - coordinator.Encoder +type Encoder20 interface { + ocr2keepers20.Encoder + ocr2keepers20coordinator.Encoder + ocr2keepers20polling.Encoder + ocr2keepers20runner.Encoder + ocr2keepers20coordinator.Encoder } type Encoder21 interface { @@ -73,7 +73,7 @@ func EVMDependencies20( lggr logger.Logger, set evm.ChainSet, pr pipeline.Runner, -) (evmrelay.OCR2KeeperProvider, *kevm20.EvmRegistry, Encoder, *kevm20.LogProvider, error) { +) (evmrelay.OCR2KeeperProvider, *kevm20.EvmRegistry, Encoder20, *kevm20.LogProvider, error) { var err error var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider @@ -128,7 +128,7 @@ func EVMDependencies21( pr pipeline.Runner, mc *models.MercuryCredentials, keyring ocrtypes.OnchainKeyring, -) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[plugin.AutomationReportInfo], *kevm21.BlockSubscriber, error) { +) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[ocr2keepers21plugin.AutomationReportInfo], *kevm21.BlockSubscriber, error) { var err error var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider diff --git a/go.mod b/go.mod index a7e6ada36ea..7d06ff81986 100644 --- a/go.mod +++ b/go.mod @@ -71,7 +71,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.6 + github.com/smartcontractkit/ocr2keepers v0.7.7 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index d45c6e3758c..5ac059e984f 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.6 h1:BIJGekJDHuvsKjqB2jCapNY+P16KypTLrAlsCcgkzZc= -github.com/smartcontractkit/ocr2keepers v0.7.6/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= +github.com/smartcontractkit/ocr2keepers v0.7.7/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/actions/automation_ocr_helpers.go b/integration-tests/actions/automation_ocr_helpers.go index 01abbeb3188..cfc0b5830d2 100644 --- a/integration-tests/actions/automation_ocr_helpers.go +++ b/integration-tests/actions/automation_ocr_helpers.go @@ -17,7 +17,7 @@ import ( "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" - "github.com/smartcontractkit/ocr2keepers/pkg/config" + ocr2keepers20config "github.com/smartcontractkit/ocr2keepers/pkg/v2/config" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" @@ -52,7 +52,7 @@ func BuildAutoOCR2ConfigVarsWithKeyIndex( return contracts.OCRv2Config{}, err } - offC, err := json.Marshal(config.OffchainConfig{ + offC, err := json.Marshal(ocr2keepers20config.OffchainConfig{ TargetProbability: "0.999", TargetInRounds: 1, PerformLockoutWindow: 3600000, // Intentionally set to be higher than in prod for testing purpose diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 1be0876f9c6..80412691461 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.6 + github.com/smartcontractkit/ocr2keepers v0.7.7 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.7 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 8f5bb457bf9..5a507c3b413 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/chainlink-testing-framework v1.15.1 h1:/i+JuVgStYoiK github.com/smartcontractkit/chainlink-testing-framework v1.15.1/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.6 h1:BIJGekJDHuvsKjqB2jCapNY+P16KypTLrAlsCcgkzZc= -github.com/smartcontractkit/ocr2keepers v0.7.6/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= +github.com/smartcontractkit/ocr2keepers v0.7.7/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From 390b67674c0f45665843d8b4b2d445357e459173 Mon Sep 17 00:00:00 2001 From: Ilja Pavlovs Date: Thu, 10 Aug 2023 17:58:43 +0300 Subject: [PATCH 130/270] Chore/vrf 470 add test contract (#10141) * fix VRF V3 setup script * VRF-470 - add test contract * VRF-470 - cleanup * VRF-470 - fixing lint issues --- contracts/scripts/native_solc_compile_all_vrf | 2 + .../testhelpers/VRFV2OwnerTestConsumer.sol | 126 ++++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + core/gethwrappers/go_generate.go | 1 + core/scripts/vrfv2/testnet/main.go | 81 +++++++++++ 5 files changed, 211 insertions(+) create mode 100644 contracts/src/v0.8/vrf/testhelpers/VRFV2OwnerTestConsumer.sol diff --git a/contracts/scripts/native_solc_compile_all_vrf b/contracts/scripts/native_solc_compile_all_vrf index bce353df965..c3ed365fe2f 100755 --- a/contracts/scripts/native_solc_compile_all_vrf +++ b/contracts/scripts/native_solc_compile_all_vrf @@ -81,4 +81,6 @@ compileContract vrf/testhelpers/VRFOwnerlessConsumerExample.sol compileContract vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol compileContract vrf/testhelpers/VRFLoadTestExternalSubOwner.sol compileContract vrf/testhelpers/VRFV2LoadTestWithMetrics.sol +compileContract vrf/testhelpers/VRFV2OwnerTestConsumer.sol + diff --git a/contracts/src/v0.8/vrf/testhelpers/VRFV2OwnerTestConsumer.sol b/contracts/src/v0.8/vrf/testhelpers/VRFV2OwnerTestConsumer.sol new file mode 100644 index 00000000000..361c32706f4 --- /dev/null +++ b/contracts/src/v0.8/vrf/testhelpers/VRFV2OwnerTestConsumer.sol @@ -0,0 +1,126 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import "../../interfaces/VRFCoordinatorV2Interface.sol"; +import "../VRFConsumerBaseV2.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "../../ChainSpecificUtil.sol"; +import "../../shared/interfaces/LinkTokenInterface.sol"; + +contract VRFV2OwnerTestConsumer is VRFConsumerBaseV2, ConfirmedOwner { + VRFCoordinatorV2Interface public COORDINATOR; + uint64 public subId; + uint256 public s_responseCount; + uint256 public s_requestCount; + uint256 public s_averageFulfillmentInMillions = 0; // in millions for better precision + uint256 public s_slowestFulfillment = 0; + uint256 public s_fastestFulfillment = 999; + uint256 public s_lastRequestId; + mapping(uint256 => uint256) requestHeights; // requestIds to block number when rand request was made + + struct RequestStatus { + bool fulfilled; + uint256[] randomWords; + uint requestTimestamp; + uint fulfilmentTimestamp; + uint256 requestBlockNumber; + uint256 fulfilmentBlockNumber; + } + + mapping(uint256 => RequestStatus) /* requestId */ /* requestStatus */ public s_requests; + + constructor(address _vrfCoordinator) VRFConsumerBaseV2(_vrfCoordinator) ConfirmedOwner(msg.sender) { + COORDINATOR = VRFCoordinatorV2Interface(_vrfCoordinator); + // create a subscription, address(this) will be the owner + subId = COORDINATOR.createSubscription(); + // add address(this) as a consumer on the subscription + COORDINATOR.addConsumer(subId, address(this)); + } + + function fulfillRandomWords(uint256 _requestId, uint256[] memory _randomWords) internal override { + uint256 fulfilmentBlockNumber = ChainSpecificUtil.getBlockNumber(); + uint256 requestDelay = fulfilmentBlockNumber - requestHeights[_requestId]; + uint256 requestDelayInMillions = requestDelay * 1_000_000; + + if (requestDelay > s_slowestFulfillment) { + s_slowestFulfillment = requestDelay; + } + s_fastestFulfillment = requestDelay < s_fastestFulfillment ? requestDelay : s_fastestFulfillment; + s_averageFulfillmentInMillions = s_responseCount > 0 + ? (s_averageFulfillmentInMillions * s_responseCount + requestDelayInMillions) / (s_responseCount + 1) + : requestDelayInMillions; + + s_requests[_requestId].fulfilled = true; + s_requests[_requestId].randomWords = _randomWords; + s_requests[_requestId].fulfilmentTimestamp = block.timestamp; + s_requests[_requestId].fulfilmentBlockNumber = fulfilmentBlockNumber; + + s_responseCount++; + } + + function requestRandomWords( + uint16 _requestConfirmations, + bytes32 _keyHash, + uint32 _callbackGasLimit, + uint32 _numWords, + uint16 _requestCount + ) external onlyOwner { + for (uint16 i = 0; i < _requestCount; i++) { + uint256 requestId = COORDINATOR.requestRandomWords( + _keyHash, + subId, + _requestConfirmations, + _callbackGasLimit, + _numWords + ); + s_lastRequestId = requestId; + uint256 requestBlockNumber = ChainSpecificUtil.getBlockNumber(); + s_requests[requestId] = RequestStatus({ + randomWords: new uint256[](0), + fulfilled: false, + requestTimestamp: block.timestamp, + fulfilmentTimestamp: 0, + requestBlockNumber: requestBlockNumber, + fulfilmentBlockNumber: 0 + }); + s_requestCount++; + requestHeights[requestId] = requestBlockNumber; + } + + COORDINATOR.removeConsumer(subId, address(this)); + COORDINATOR.cancelSubscription(subId, msg.sender); + } + + function reset() external { + s_averageFulfillmentInMillions = 0; // in millions for better precision + s_slowestFulfillment = 0; + s_fastestFulfillment = 999; + s_requestCount = 0; + s_responseCount = 0; + } + + function getRequestStatus( + uint256 _requestId + ) + external + view + returns ( + bool fulfilled, + uint256[] memory randomWords, + uint requestTimestamp, + uint fulfilmentTimestamp, + uint256 requestBlockNumber, + uint256 fulfilmentBlockNumber + ) + { + RequestStatus memory request = s_requests[_requestId]; + return ( + request.fulfilled, + request.randomWords, + request.requestTimestamp, + request.fulfilmentTimestamp, + request.requestBlockNumber, + request.fulfilmentBlockNumber + ); + } +} diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index a475c97cfc5..b9b7e48ce81 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -82,6 +82,7 @@ vrf_load_test_with_metrics: ../../contracts/solc/v0.8.6/VRFV2LoadTestWithMetrics vrf_malicious_consumer_v2: ../../contracts/solc/v0.8.6/VRFMaliciousConsumerV2.abi ../../contracts/solc/v0.8.6/VRFMaliciousConsumerV2.bin 9755fa8ffc7f5f0b337d5d413d77b0c9f6cd6f68c31727d49acdf9d4a51bc522 vrf_malicious_consumer_v2_plus: ../../contracts/solc/v0.8.6/VRFMaliciousConsumerV2Plus.abi ../../contracts/solc/v0.8.6/VRFMaliciousConsumerV2Plus.bin 0c8349f763bf7240127d9d1f788fbd32cae7df22489efda26df02093e3dba97e vrf_owner: ../../contracts/solc/v0.8.6/VRFOwner.abi ../../contracts/solc/v0.8.6/VRFOwner.bin eccfae5ee295b5850e22f61240c469f79752b8d9a3bac5d64aec7ac8def2f6cb +vrf_owner_test_consumer: ../../contracts/solc/v0.8.6/VRFV2OwnerTestConsumer.abi ../../contracts/solc/v0.8.6/VRFV2OwnerTestConsumer.bin 9a53f1f6d23f6f9bd9781284d8406e4b0741d59d13da2bdf4a9e0a8754c88101 vrf_ownerless_consumer_example: ../../contracts/solc/v0.8.6/VRFOwnerlessConsumerExample.abi ../../contracts/solc/v0.8.6/VRFOwnerlessConsumerExample.bin 9893b3805863273917fb282eed32274e32aa3d5c2a67a911510133e1218132be vrf_single_consumer_example: ../../contracts/solc/v0.8.6/VRFSingleConsumerExample.abi ../../contracts/solc/v0.8.6/VRFSingleConsumerExample.bin 892a5ed35da2e933f7fd7835cd6f7f70ef3aa63a9c03a22c5b1fd026711b0ece vrf_v2plus_single_consumer: ../../contracts/solc/v0.8.6/VRFV2PlusSingleConsumerExample.abi ../../contracts/solc/v0.8.6/VRFV2PlusSingleConsumerExample.bin ae52552860445980ebe6a6f38277ef2857672d41fff67ea440f4f2e1447ebdeb diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 02f627f4ab4..9754b60cde0 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -69,6 +69,7 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin VRFLoadTestOwnerlessConsumer vrf_load_test_ownerless_consumer //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin VRFLoadTestExternalSubOwner vrf_load_test_external_sub_owner //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFV2LoadTestWithMetrics.abi ../../contracts/solc/v0.8.6/VRFV2LoadTestWithMetrics.bin VRFV2LoadTestWithMetrics vrf_load_test_with_metrics +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFV2OwnerTestConsumer.abi ../../contracts/solc/v0.8.6/VRFV2OwnerTestConsumer.bin VRFV2OwnerTestConsumer vrf_owner_test_consumer //go:generate go run ./generation/generate_link/wrap_link.go diff --git a/core/scripts/vrfv2/testnet/main.go b/core/scripts/vrfv2/testnet/main.go index 0a80fc0b37d..f23faca638f 100644 --- a/core/scripts/vrfv2/testnet/main.go +++ b/core/scripts/vrfv2/testnet/main.go @@ -7,6 +7,7 @@ import ( "flag" "fmt" "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/scripts" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_owner_test_consumer" "log" "math/big" "os" @@ -707,6 +708,17 @@ func main() { consumerCoordinator := loadTestConsumerDeployCmd.String("coordinator-address", "", "coordinator address") helpers.ParseArgs(loadTestConsumerDeployCmd, os.Args[2:], "coordinator-address") scripts.EoaLoadTestConsumerWithMetricsDeploy(e, *consumerCoordinator) + case "eoa-vrf-owner-test-consumer-deploy": + loadTestConsumerDeployCmd := flag.NewFlagSet("eoa-vrf-owner-test-consumer-deploy", flag.ExitOnError) + consumerCoordinator := loadTestConsumerDeployCmd.String("coordinator-address", "", "coordinator address") + helpers.ParseArgs(loadTestConsumerDeployCmd, os.Args[2:], "coordinator-address") + _, tx, _, err := vrf_owner_test_consumer.DeployVRFV2OwnerTestConsumer( + e.Owner, + e.Ec, + common.HexToAddress(*consumerCoordinator), + ) + helpers.PanicErr(err) + helpers.ConfirmContractDeployed(context.Background(), e.Ec, tx, e.ChainID) case "eoa-create-sub": createSubCmd := flag.NewFlagSet("eoa-create-sub", flag.ExitOnError) coordinatorAddress := createSubCmd.String("coordinator-address", "", "coordinator address") @@ -824,6 +836,75 @@ func main() { for i, tx := range txes { helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID, fmt.Sprintf("load test %d", i+1)) } + case "eoa-vrf-owner-test-request": + request := flag.NewFlagSet("eoa-eoa-vrf-owner-test-request", flag.ExitOnError) + consumerAddress := request.String("consumer-address", "", "consumer address") + requestConfirmations := request.Uint("request-confirmations", 3, "minimum request confirmations") + keyHash := request.String("key-hash", "", "key hash") + cbGasLimit := request.Uint("cb-gas-limit", 100_000, "request callback gas limit") + numWords := request.Uint("num-words", 1, "num words to request") + requests := request.Uint("requests", 10, "number of randomness requests to make per run") + runs := request.Uint("runs", 1, "number of runs to do. total randomness requests will be (requests * runs).") + helpers.ParseArgs(request, os.Args[2:], "consumer-address", "key-hash") + keyHashBytes := common.HexToHash(*keyHash) + + consumer, err := vrf_owner_test_consumer.NewVRFV2OwnerTestConsumer( + common.HexToAddress(*consumerAddress), + e.Ec) + helpers.PanicErr(err) + var txes []*types.Transaction + for i := 0; i < int(*runs); i++ { + tx, err := consumer.RequestRandomWords( + e.Owner, + uint16(*requestConfirmations), + keyHashBytes, + uint32(*cbGasLimit), + uint32(*numWords), + uint16(*requests), + ) + helpers.PanicErr(err) + fmt.Printf("TX %d: %s\n", i+1, helpers.ExplorerLink(e.ChainID, tx.Hash())) + txes = append(txes, tx) + } + fmt.Println("Total number of requests sent:", (*requests)*(*runs)) + fmt.Println("fetching receipts for all transactions") + for i, tx := range txes { + helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID, fmt.Sprintf("load test %d", i+1)) + } + case "eoa-vrf-owner-test-read-metrics": + request := flag.NewFlagSet("eoa-load-test-read-metrics", flag.ExitOnError) + consumerAddress := request.String("consumer-address", "", "consumer address") + helpers.ParseArgs(request, os.Args[2:], "consumer-address") + consumer, err := vrf_owner_test_consumer.NewVRFV2OwnerTestConsumer( + common.HexToAddress(*consumerAddress), + e.Ec) + helpers.PanicErr(err) + responseCount, err := consumer.SResponseCount(nil) + helpers.PanicErr(err) + fmt.Println("Response Count: ", responseCount) + requestCount, err := consumer.SRequestCount(nil) + helpers.PanicErr(err) + fmt.Println("Request Count: ", requestCount) + averageFulfillmentInMillions, err := consumer.SAverageFulfillmentInMillions(nil) + helpers.PanicErr(err) + fmt.Println("Average Fulfillment In Millions: ", averageFulfillmentInMillions) + slowestFulfillment, err := consumer.SSlowestFulfillment(nil) + helpers.PanicErr(err) + fmt.Println("Slowest Fulfillment: ", slowestFulfillment) + fastestFulfillment, err := consumer.SFastestFulfillment(nil) + helpers.PanicErr(err) + fmt.Println("Fastest Fulfillment: ", fastestFulfillment) + case "eoa-vrf-owner-test-reset-metrics": + request := flag.NewFlagSet("eoa-vrf-owner-test-reset-metrics", flag.ExitOnError) + consumerAddress := request.String("consumer-address", "", "consumer address") + helpers.ParseArgs(request, os.Args[2:], "consumer-address") + consumer, err := vrf_owner_test_consumer.NewVRFV2OwnerTestConsumer( + common.HexToAddress(*consumerAddress), + e.Ec) + helpers.PanicErr(err) + _, err = consumer.Reset(e.Owner) + helpers.PanicErr(err) + fmt.Println("Load Test Consumer With Metrics was reset ") case "eoa-load-test-request-with-metrics": request := flag.NewFlagSet("eoa-load-test-request-with-metrics", flag.ExitOnError) consumerAddress := request.String("consumer-address", "", "consumer address") From 4bd351ad5a6630a56883ff2b96e92153575882f7 Mon Sep 17 00:00:00 2001 From: Sri Kidambi <1702865+kidambisrinivas@users.noreply.github.com> Date: Thu, 10 Aug 2023 16:35:20 +0100 Subject: [PATCH 131/270] Fix RequestRandomWords ABI (#10146) * Fix RequestRandomWords ABI * Removed RandomWordsRequestedV2PlusABI --------- Co-authored-by: Sri Kidambi --- core/scripts/vrfv2plus/testnet/super_scripts.go | 4 +--- core/services/vrf/v2/listener_v2.go | 3 --- 2 files changed, 1 insertion(+), 6 deletions(-) diff --git a/core/scripts/vrfv2plus/testnet/super_scripts.go b/core/scripts/vrfv2plus/testnet/super_scripts.go index c91a46ab3e8..c5814195945 100644 --- a/core/scripts/vrfv2plus/testnet/super_scripts.go +++ b/core/scripts/vrfv2plus/testnet/super_scripts.go @@ -19,7 +19,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/services/signatures/secp256k1" - v2 "github.com/smartcontractkit/chainlink/v2/core/services/vrf/v2" ) const formattedVRFJob = ` @@ -38,7 +37,7 @@ pollPeriod = "5s" requestTimeout = "24h" observationSource = """ decode_log [type=ethabidecodelog - abi="%s" + abi="RandomWordsRequested(bytes32 indexed keyHash,uint256 requestId,uint256 preSeed,uint256 indexed subId,uint16 minimumRequestConfirmations,uint32 callbackGasLimit,uint32 numWords,bytes extraArgs,address indexed sender)" data="$(jobRun.logData)" topics="$(jobRun.logTopics)"] generate_proof [type=vrfv2plus @@ -206,7 +205,6 @@ func deployUniverse(e helpers.Environment) { compressedPkHex, e.ChainID, *registerKeyOracleAddress, - v2.RandomWordsRequestedV2PlusABI, coordinatorAddress, coordinatorAddress, coordinatorAddress, diff --git a/core/services/vrf/v2/listener_v2.go b/core/services/vrf/v2/listener_v2.go index e653cf67550..9b643d4f571 100644 --- a/core/services/vrf/v2/listener_v2.go +++ b/core/services/vrf/v2/listener_v2.go @@ -54,9 +54,6 @@ var ( batchCoordinatorV2ABI = evmtypes.MustGetABI(batch_vrf_coordinator_v2.BatchVRFCoordinatorV2ABI) batchCoordinatorV2PlusABI = evmtypes.MustGetABI(batch_vrf_coordinator_v2plus.BatchVRFCoordinatorV2PlusABI) vrfOwnerABI = evmtypes.MustGetABI(vrf_owner.VRFOwnerMetaData.ABI) - // RandomWordsRequestedV2PlusABI is the ABI of the RandomWordsRequested event - // for V2Plus. - RandomWordsRequestedV2PlusABI = coordinatorV2PlusABI.Events["RandomWordsRequested"].Sig ) const ( From 460e219b78cf3eeeb411dfddc4cb9afb2bf7c34a Mon Sep 17 00:00:00 2001 From: ilija42 <57732589+ilija42@users.noreply.github.com> Date: Thu, 10 Aug 2023 17:44:06 +0200 Subject: [PATCH 132/270] NOP UX transmitter ID and Sender keys error messages improvements (#10144) * Validate "sending keys & transmitterID defined" earlier for NOP UX * Add ErrNoSuchSendingKey beside ErrNoSuchTransmitterKey for better NOPUX * Update ocr2 job creation transmitter key validatiosn unit tests * Add job orm validation func ValidateKeyStoreMatch unit test * Fix go imports for job_orm_test.go * Fix go imports for job_orm_test.go --- core/services/job/job_orm_test.go | 71 ++++++++++++++++++++++++++++++- core/services/job/orm.go | 31 +++++++------- core/web/jobs_controller.go | 4 +- 3 files changed, 87 insertions(+), 19 deletions(-) diff --git a/core/services/job/job_orm_test.go b/core/services/job/job_orm_test.go index 4b7f9a7ea7b..ef2e216794e 100644 --- a/core/services/job/job_orm_test.go +++ b/core/services/job/job_orm_test.go @@ -15,6 +15,8 @@ import ( "github.com/stretchr/testify/require" "gopkg.in/guregu/null.v4" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" + "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/bridges" evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" @@ -787,7 +789,7 @@ func TestORM_CreateJob_OCR2_DuplicatedContractAddress(t *testing.T) { require.Error(t, err) } -func TestORM_CreateJob_OCR2_Sending_Keys_TransmitterID_Validations(t *testing.T) { +func TestORM_CreateJob_OCR2_Sending_Keys_Transmitter_Keys_Validations(t *testing.T) { customChainID := utils.NewBig(testutils.NewRandomEVMChainID()) config := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { @@ -823,7 +825,7 @@ func TestORM_CreateJob_OCR2_Sending_Keys_TransmitterID_Validations(t *testing.T) jb.OCR2OracleSpec.TransmitterID = null.String{} _, address2 := cltest.MustInsertRandomKey(t, keyStore.Eth()) jb.OCR2OracleSpec.RelayConfig["sendingKeys"] = interface{}([]any{address.String(), address2.String(), common.HexToAddress("0X0").String()}) - assert.Equal(t, "CreateJobFailed: no EVM key matching: \"0x0000000000000000000000000000000000000000\": no such transmitter key exists", jobORM.CreateJob(&jb).Error()) + assert.Equal(t, "CreateJobFailed: no EVM key matching: \"0x0000000000000000000000000000000000000000\": no such sending key exists", jobORM.CreateJob(&jb).Error()) jb.OCR2OracleSpec.RelayConfig["sendingKeys"] = interface{}([]any{1, 2, 3}) assert.Equal(t, "CreateJobFailed: sending keys are of wrong type", jobORM.CreateJob(&jb).Error()) @@ -842,6 +844,71 @@ func TestORM_CreateJob_OCR2_Sending_Keys_TransmitterID_Validations(t *testing.T) }) } +func TestORM_ValidateKeyStoreMatch(t *testing.T) { + config := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) {}) + + keyStore := cltest.NewKeyStore(t, pgtest.NewSqlxDB(t), config.Database()) + require.NoError(t, keyStore.OCR2().Add(cltest.DefaultOCR2Key)) + + jb, err := ocr2validate.ValidatedOracleSpecToml(config.OCR2(), config.Insecure(), testspecs.OCR2EVMSpecMinimal) + require.NoError(t, err) + + t.Run("test ETH key validation", func(t *testing.T) { + jb.OCR2OracleSpec.Relay = relay.EVM + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, "bad key") + require.EqualError(t, err, "no EVM key matching: \"bad key\"") + + _, evmKey := cltest.MustInsertRandomKey(t, keyStore.Eth()) + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, evmKey.String()) + require.NoError(t, err) + }) + + t.Run("test Cosmos key validation", func(t *testing.T) { + jb.OCR2OracleSpec.Relay = relay.Cosmos + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, "bad key") + require.EqualError(t, err, "no Cosmos key matching: \"bad key\"") + + cosmosKey, err := keyStore.Cosmos().Create() + require.NoError(t, err) + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, cosmosKey.ID()) + require.NoError(t, err) + }) + + t.Run("test Solana key validation", func(t *testing.T) { + jb.OCR2OracleSpec.Relay = relay.Solana + + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, "bad key") + require.EqualError(t, err, "no Solana key matching: \"bad key\"") + + solanaKey, err := keyStore.Solana().Create() + require.NoError(t, err) + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, solanaKey.ID()) + require.NoError(t, err) + }) + + t.Run("test Starknet key validation", func(t *testing.T) { + jb.OCR2OracleSpec.Relay = relay.StarkNet + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, "bad key") + require.EqualError(t, err, "no Starknet key matching: \"bad key\"") + + starkNetKey, err := keyStore.StarkNet().Create() + require.NoError(t, err) + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, starkNetKey.ID()) + require.NoError(t, err) + }) + + t.Run("test Mercury ETH key validation", func(t *testing.T) { + jb.OCR2OracleSpec.PluginType = job.Mercury + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, "bad key") + require.EqualError(t, err, "no CSA key matching: \"bad key\"") + + csaKey, err := keyStore.CSA().Create() + require.NoError(t, err) + err = job.ValidateKeyStoreMatch(jb.OCR2OracleSpec, keyStore, csaKey.ID()) + require.NoError(t, err) + }) +} + func Test_FindJobs(t *testing.T) { t.Parallel() diff --git a/core/services/job/orm.go b/core/services/job/orm.go index 946efa3261f..a7e7f16bc20 100644 --- a/core/services/job/orm.go +++ b/core/services/job/orm.go @@ -38,6 +38,7 @@ import ( var ( ErrNoSuchKeyBundle = errors.New("no such key bundle exists") ErrNoSuchTransmitterKey = errors.New("no such transmitter key exists") + ErrNoSuchSendingKey = errors.New("no such sending key exists") ErrNoSuchPublicKey = errors.New("no such public key exists") ) @@ -242,6 +243,10 @@ func (o *orm) CreateJob(jb *Job, qopts ...pg.QOpt) error { } } + if jb.OCR2OracleSpec.RelayConfig["sendingKeys"] != nil && jb.OCR2OracleSpec.TransmitterID.Valid { + return errors.New("sending keys and transmitter ID can't both be defined") + } + // checks if they are present and if they are valid sendingKeysDefined, err := areSendingKeysDefined(jb, o.keyStore) if err != nil { @@ -252,13 +257,9 @@ func (o *orm) CreateJob(jb *Job, qopts ...pg.QOpt) error { return errors.New("neither sending keys nor transmitter ID is defined") } - if sendingKeysDefined && jb.OCR2OracleSpec.TransmitterID.Valid { - return errors.New("sending keys and transmitter ID can't both be defined") - } - if !sendingKeysDefined { - if err = validateKeyStoreMatch(jb.OCR2OracleSpec, o.keyStore, jb.OCR2OracleSpec.TransmitterID.String); err != nil { - return err + if err = ValidateKeyStoreMatch(jb.OCR2OracleSpec, o.keyStore, jb.OCR2OracleSpec.TransmitterID.String); err != nil { + return errors.Wrap(ErrNoSuchTransmitterKey, err.Error()) } } @@ -452,34 +453,34 @@ func (o *orm) CreateJob(jb *Job, qopts ...pg.QOpt) error { return o.findJob(jb, "id", jobID, qopts...) } -// validateKeyStoreMatch confirms that the key has a valid match in the keystore -func validateKeyStoreMatch(spec *OCR2OracleSpec, keyStore keystore.Master, key string) error { +// ValidateKeyStoreMatch confirms that the key has a valid match in the keystore +func ValidateKeyStoreMatch(spec *OCR2OracleSpec, keyStore keystore.Master, key string) error { if spec.PluginType == Mercury { _, err := keyStore.CSA().Get(key) if err != nil { - return errors.Wrapf(ErrNoSuchTransmitterKey, "no CSA key matching: %q", key) + return errors.Errorf("no CSA key matching: %q", key) } } else { switch spec.Relay { case relay.EVM: _, err := keyStore.Eth().Get(key) if err != nil { - return errors.Wrapf(ErrNoSuchTransmitterKey, "no EVM key matching: %q", key) + return errors.Errorf("no EVM key matching: %q", key) } case relay.Cosmos: _, err := keyStore.Cosmos().Get(key) if err != nil { - return errors.Wrapf(ErrNoSuchTransmitterKey, "no Cosmos key matching %q", key) + return errors.Errorf("no Cosmos key matching: %q", key) } case relay.Solana: _, err := keyStore.Solana().Get(key) if err != nil { - return errors.Wrapf(ErrNoSuchTransmitterKey, "no Solana key matching: %q", key) + return errors.Errorf("no Solana key matching: %q", key) } case relay.StarkNet: _, err := keyStore.StarkNet().Get(key) if err != nil { - return errors.Wrapf(ErrNoSuchTransmitterKey, "no Starknet key matching %q", key) + return errors.Errorf("no Starknet key matching: %q", key) } } } @@ -494,8 +495,8 @@ func areSendingKeysDefined(jb *Job, keystore keystore.Master) (bool, error) { } for _, sendingKey := range sendingKeys { - if err = validateKeyStoreMatch(jb.OCR2OracleSpec, keystore, sendingKey); err != nil { - return false, err + if err = ValidateKeyStoreMatch(jb.OCR2OracleSpec, keystore, sendingKey); err != nil { + return false, errors.Wrap(ErrNoSuchSendingKey, err.Error()) } } diff --git a/core/web/jobs_controller.go b/core/web/jobs_controller.go index e82a3e1ab05..77a2a34091c 100644 --- a/core/web/jobs_controller.go +++ b/core/web/jobs_controller.go @@ -113,7 +113,7 @@ func (jc *JobsController) Create(c *gin.Context) { defer cancel() err = jc.App.AddJobV2(ctx, &jb) if err != nil { - if errors.Is(errors.Cause(err), job.ErrNoSuchKeyBundle) || errors.As(err, &keystore.KeyNotFoundError{}) || errors.Is(errors.Cause(err), job.ErrNoSuchTransmitterKey) { + if errors.Is(errors.Cause(err), job.ErrNoSuchKeyBundle) || errors.As(err, &keystore.KeyNotFoundError{}) || errors.Is(errors.Cause(err), job.ErrNoSuchTransmitterKey) || errors.Is(errors.Cause(err), job.ErrNoSuchSendingKey) { jsonAPIError(c, http.StatusBadRequest, err) return } @@ -201,7 +201,7 @@ func (jc *JobsController) Update(c *gin.Context) { err = jc.App.AddJobV2(ctx, &jb) if err != nil { - if errors.Is(errors.Cause(err), job.ErrNoSuchKeyBundle) || errors.As(err, &keystore.KeyNotFoundError{}) || errors.Is(errors.Cause(err), job.ErrNoSuchTransmitterKey) { + if errors.Is(errors.Cause(err), job.ErrNoSuchKeyBundle) || errors.As(err, &keystore.KeyNotFoundError{}) || errors.Is(errors.Cause(err), job.ErrNoSuchTransmitterKey) || errors.Is(errors.Cause(err), job.ErrNoSuchSendingKey) { jsonAPIError(c, http.StatusBadRequest, err) return } From e09a969d86ec39aafd2db796ba691de205ca50bc Mon Sep 17 00:00:00 2001 From: Makram Date: Thu, 10 Aug 2023 19:16:24 +0300 Subject: [PATCH 133/270] fix: fold reentrancy check into s_config (#10142) * fix: fold reentrancy check into s_config * chore: revert gas profiling changes * fix: native_solc_compile_all_vrf * fix: remove unused updateConsumerNonce function * fix: remove script changes --- contracts/scripts/native_solc_compile_all_vrf | 2 -- .../src/v0.8/dev/vrf/SubscriptionAPI.sol | 33 +++++++++++++++++-- .../src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 25 +++----------- .../vrf_coordinator_v2plus.go | 10 +++--- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 5 files changed, 43 insertions(+), 29 deletions(-) diff --git a/contracts/scripts/native_solc_compile_all_vrf b/contracts/scripts/native_solc_compile_all_vrf index c3ed365fe2f..6b40f258af9 100755 --- a/contracts/scripts/native_solc_compile_all_vrf +++ b/contracts/scripts/native_solc_compile_all_vrf @@ -82,5 +82,3 @@ compileContract vrf/testhelpers/VRFLoadTestOwnerlessConsumer.sol compileContract vrf/testhelpers/VRFLoadTestExternalSubOwner.sol compileContract vrf/testhelpers/VRFV2LoadTestWithMetrics.sol compileContract vrf/testhelpers/VRFV2OwnerTestConsumer.sol - - diff --git a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol index 82711bb403f..e0909460639 100644 --- a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol +++ b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol @@ -4,11 +4,10 @@ pragma solidity ^0.8.0; import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../shared/access/ConfirmedOwner.sol"; import "../../interfaces/AggregatorV3Interface.sol"; -import "@openzeppelin/contracts/security/ReentrancyGuard.sol"; import "../../shared/interfaces/IERC677Receiver.sol"; import "../interfaces/IVRFSubscriptionV2Plus.sol"; -abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, IERC677Receiver, IVRFSubscriptionV2Plus { +abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscriptionV2Plus { /// @dev may not be provided upon construction on some chains due to lack of availability LinkTokenInterface public LINK; /// @dev may not be provided upon construction on some chains due to lack of availability @@ -83,6 +82,36 @@ abstract contract SubscriptionAPI is ConfirmedOwner, ReentrancyGuard, IERC677Rec event SubscriptionOwnerTransferRequested(uint256 indexed subId, address from, address to); event SubscriptionOwnerTransferred(uint256 indexed subId, address from, address to); + struct Config { + uint16 minimumRequestConfirmations; + uint32 maxGasLimit; + // Reentrancy protection. + bool reentrancyLock; + // stalenessSeconds is how long before we consider the feed price to be stale + // and fallback to fallbackWeiPerUnitLink. + uint32 stalenessSeconds; + // Gas to cover oracle payment after we calculate the payment. + // We make it configurable in case those operations are repriced. + // The recommended number is below, though it may vary slightly + // if certain chains do not implement certain EIP's. + // 21000 + // base cost of the transaction + // 100 + 5000 + // warm subscription balance read and update. See https://eips.ethereum.org/EIPS/eip-2929 + // 2*2100 + 5000 - // cold read oracle address and oracle balance and first time oracle balance update, note first time will be 20k, but 5k subsequently + // 4800 + // request delete refund (refunds happen after execution), note pre-london fork was 15k. See https://eips.ethereum.org/EIPS/eip-3529 + // 6685 + // Positive static costs of argument encoding etc. note that it varies by +/- x*12 for every x bytes of non-zero data in the proof. + // Total: 37,185 gas. + uint32 gasAfterPaymentCalculation; + } + Config public s_config; + + error Reentrant(); + modifier nonReentrant() { + if (s_config.reentrancyLock) { + revert Reentrant(); + } + _; + } + constructor() ConfirmedOwner(msg.sender) {} /** diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 5a0d5825f6f..369344b5703 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -67,26 +67,8 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { bool success ); - struct Config { - uint16 minimumRequestConfirmations; - uint32 maxGasLimit; - // stalenessSeconds is how long before we consider the feed price to be stale - // and fallback to fallbackWeiPerUnitLink. - uint32 stalenessSeconds; - // Gas to cover oracle payment after we calculate the payment. - // We make it configurable in case those operations are repriced. - // The recommended number is below, though it may vary slightly - // if certain chains do not implement certain EIP's. - // 21000 + // base cost of the transaction - // 100 + 5000 + // warm subscription balance read and update. See https://eips.ethereum.org/EIPS/eip-2929 - // 2*2100 + 5000 - // cold read oracle address and oracle balance and first time oracle balance update, note first time will be 20k, but 5k subsequently - // 4800 + // request delete refund (refunds happen after execution), note pre-london fork was 15k. See https://eips.ethereum.org/EIPS/eip-3529 - // 6685 + // Positive static costs of argument encoding etc. note that it varies by +/- x*12 for every x bytes of non-zero data in the proof. - // Total: 37,185 gas. - uint32 gasAfterPaymentCalculation; - } int256 public s_fallbackWeiPerUnitLink; - Config public s_config; + FeeConfig public s_feeConfig; struct FeeConfig { // Flat fee charged per fulfillment in millionths of link @@ -185,7 +167,8 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { minimumRequestConfirmations: minimumRequestConfirmations, maxGasLimit: maxGasLimit, stalenessSeconds: stalenessSeconds, - gasAfterPaymentCalculation: gasAfterPaymentCalculation + gasAfterPaymentCalculation: gasAfterPaymentCalculation, + reentrancyLock: false }); s_feeConfig = feeConfig; s_fallbackWeiPerUnitLink = fallbackWeiPerUnitLink; @@ -427,7 +410,9 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { // during the consumers callback code via reentrancyLock. // Note that callWithExactGas will revert if we do not have sufficient gas // to give the callee their requested amount. + s_config.reentrancyLock = true; bool success = callWithExactGas(rc.callbackGasLimit, rc.sender, resp); + s_config.reentrancyLock = false; // Increment the req count for the subscription. uint64 reqCount = s_subscriptions[rc.subId].reqCount; diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index 9bdbdfa4ccd..9558960e82a 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -66,8 +66,8 @@ type VRFV2PlusClientRandomWordsRequest struct { } var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200618338038062006183833981016040819052620000349162000188565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000dc565b505060016002555060601b6001600160601b031916608052620001ba565b6001600160a01b038116331415620001375760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019b57600080fd5b81516001600160a01b0381168114620001b357600080fd5b9392505050565b60805160601c615fa3620001e0600039600081816105f80152613bcc0152615fa36000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd14610948578063ee9d2d381461096f578063f2fde38b1461099c57600080fd5b8063dc311dd3146108e4578063e72f6e3014610915578063e8509bff1461093557600080fd5b8063d98e620e116100bb578063d98e620e1461086e578063da2f26101461088e578063dac83d29146108c457600080fd5b8063bec4c08c1461080e578063caf70c4a1461082e578063cb6317971461084e57600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107ae578063b08c8795146107ce578063b2a7cac5146107ee57600080fd5b8063a4c0ed361461074e578063a8cb447b1461076e578063aa433aff1461078e57600080fd5b80639b1c385e116101745780639b1c385e146106df5780639d40a6fd146106ff578063a21a23e41461073957600080fd5b806386fe91c7146106955780638da5cb5b146106c157600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461061a5780636f64f03f1461066057806379ba50971461068057600080fd5b806364d51a2a146105b157806366316d8d146105c6578063689c4517146105e657600080fd5b806346d8d4861161022d57806346d8d4861461055157806357133e64146105715780635d06b4ab1461059157600080fd5b806340d6bb82146104f657806341af6c871461052157600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610482578063330987b31461049e578063405b84fa146104d657600080fd5b80630ae095401461040257806315c48b84146104225780631b6b6d231461044a57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103e257600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109bc565b60405161031a93929190615a6d565b60405180910390f35b34801561032f57600080fd5b5061034361033e3660046153d3565b610a38565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600f546103b19061ffff81169063ffffffff620100008204811691660100000000000081048216916a01000000000000000000009091041684565b6040805161ffff909516855263ffffffff93841660208601529183169184019190915216606082015260800161031a565b3480156103ee57600080fd5b506103436103fd366004615514565b610bfa565b34801561040e57600080fd5b5061034361041d3660046157d1565b610d8e565b34801561042e57600080fd5b5061043760c881565b60405161ffff909116815260200161031a565b34801561045657600080fd5b5060035461046a906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b34801561048e57600080fd5b506040516001815260200161031a565b3480156104aa57600080fd5b506104be6104b93660046155e7565b610e7a565b6040516001600160601b03909116815260200161031a565b3480156104e257600080fd5b506103436104f13660046157d1565b6113b6565b34801561050257600080fd5b5061050c6101f481565b60405163ffffffff909116815260200161031a565b34801561052d57600080fd5b5061054161053c366004615569565b611796565b604051901515815260200161031a565b34801561055d57600080fd5b5061034361056c3660046153f0565b611998565b34801561057d57600080fd5b5061034361058c366004615425565b611b33565b34801561059d57600080fd5b506103436105ac3660046153d3565b611bac565b3480156105bd57600080fd5b50610437606481565b3480156105d257600080fd5b506103436105e13660046153f0565b611c83565b3480156105f257600080fd5b5061046a7f000000000000000000000000000000000000000000000000000000000000000081565b34801561062657600080fd5b506010546106439063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561066c57600080fd5b5061034361067b36600461545e565b611e3f565b34801561068c57600080fd5b50610343611f57565b3480156106a157600080fd5b506008546104be906801000000000000000090046001600160601b031681565b3480156106cd57600080fd5b506000546001600160a01b031661046a565b3480156106eb57600080fd5b5061035b6106fa3660046156e3565b612008565b34801561070b57600080fd5b506008546107209067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561074557600080fd5b5061035b612449565b34801561075a57600080fd5b5061034361076936600461548b565b6126ee565b34801561077a57600080fd5b506103436107893660046153d3565b6128dd565b34801561079a57600080fd5b506103436107a9366004615569565b6129f9565b3480156107ba57600080fd5b5060045461046a906001600160a01b031681565b3480156107da57600080fd5b506103436107e9366004615733565b612a59565b3480156107fa57600080fd5b50610343610809366004615569565b612be3565b34801561081a57600080fd5b506103436108293660046157d1565b612d50565b34801561083a57600080fd5b5061035b610849366004615530565b612f23565b34801561085a57600080fd5b506103436108693660046157d1565b612f53565b34801561087a57600080fd5b5061035b610889366004615569565b613270565b34801561089a57600080fd5b5061046a6108a9366004615569565b600b602052600090815260409020546001600160a01b031681565b3480156108d057600080fd5b506103436108df3660046157d1565b613291565b3480156108f057600080fd5b506109046108ff366004615569565b6133c9565b60405161031a959493929190615c6b565b34801561092157600080fd5b506103436109303660046153d3565b6134c5565b610343610943366004615569565b61368d565b34801561095457600080fd5b506008546104be90600160a01b90046001600160601b031681565b34801561097b57600080fd5b5061035b61098a366004615569565b600d6020526000908152604090205481565b3480156109a857600080fd5b506103436109b73660046153d3565b6137e5565b600f54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a2657602002820191906000526020600020905b815481526020019060010190808311610a12575b50505050509050925092509250909192565b610a406137f6565b60115460005b81811015610bcd57826001600160a01b031660118281548110610a6b57610a6b615f27565b6000918252602090912001546001600160a01b03161415610bbb576011610a93600184615e1f565b81548110610aa357610aa3615f27565b600091825260209091200154601180546001600160a01b039092169183908110610acf57610acf615f27565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826011610b06600185615e1f565b81548110610b1657610b16615f27565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506011805480610b5557610b55615f11565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bc581615e8e565b915050610a46565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c026137f6565b604080518082018252600091610c31919084906002908390839080828437600092019190915250612f23915050565b6000818152600b60205260409020549091506001600160a01b031680610c6d57604051631dfd6e1360e21b815260048101839052602401610bee565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d455782600c8281548110610ca857610ca8615f27565b90600052602060002001541415610d3357600c805460009190610ccd90600190615e1f565b81548110610cdd57610cdd615f27565b9060005260206000200154905080600c8381548110610cfe57610cfe615f27565b600091825260209091200155600c805480610d1b57610d1b615f11565b60019003818190600052602060002001600090559055505b80610d3d81615e8e565b915050610c8a565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d8191815260200190565b60405180910390a2505050565b60008281526006602052604090205482906001600160a01b031680610dc657604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610dfa57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b600280541415610e3a5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028055610e4784611796565b15610e6557604051631685ecdd60e31b815260040160405180910390fd5b610e6f8484613852565b505060016002555050565b6000600280541415610ebc5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b6002805560005a90506000610ed185856139e9565b90506000610ee560808601606087016157f6565b63ffffffff1667ffffffffffffffff811115610f0357610f03615f3d565b604051908082528060200260200182016040528015610f2c578160200160208202803683370190505b50905060005b610f4260808701606088016157f6565b63ffffffff16811015610fb757826040015181604051602001610f6f929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f9a57610f9a615f27565b602090810291909101015280610faf81615e8e565b915050610f32565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e3000000000000000000000000000000000000000000000000000000009161100891908690602401615ae0565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b0319909416939093179092529150600090611084906110689060608b01908b016157f6565b63ffffffff1661107e60a08b0160808c016153d3565b84613d3e565b602089810135600090815260079091526040902054909150600160c01b900467ffffffffffffffff166110b8816001615d9e565b6020808b01356000908152600790915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915561111961111460a08c018c615cc1565b613d8c565b51600f54909150600090611144908a906a0100000000000000000000900463ffffffff163a85613e3b565b9050811561124d576020808c01356000908152600790915260409020546001600160601b03808316600160601b90920416101561119457604051631e9acf1760e31b815260040160405180910390fd5b60208b81013560009081526007909152604090208054829190600c906111cb908490600160601b90046001600160601b0316615e36565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600a90915281208054859450909261122491859116615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550611339565b6020808c01356000908152600790915260409020546001600160601b038083169116101561128e57604051631e9acf1760e31b815260040160405180910390fd5b6020808c0135600090815260079091526040812080548392906112bb9084906001600160601b0316615e36565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261131491859116615dca565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113546040518060200160405280851515815250613e8b565b90508b6020013589602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8b6040015185858a6040516113999493929190615c30565b60405180910390a35060016002559b9a5050505050505050505050565b6113bf81613f11565b6113e757604051635428d44960e01b81526001600160a01b0382166004820152602401610bee565b6000806000806113f6866133c9565b945094505093509350336001600160a01b0316826001600160a01b0316146114605760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610bee565b61146986611796565b156114b65760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610bee565b60006040518060c001604052806114cb600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b0316815250905060008160405160200161151f91906159f8565b604051602081830303815290604052905061153988613f7b565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061158b9085906004016159e5565b6000604051808303818588803b1580156115a457600080fd5b505af11580156115b8573d6000803e3d6000fd5b505060035460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561161457600080fd5b505af1158015611628573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061164c919061554c565b6116985760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610bee565b60005b8351811015611749578381815181106116b6576116b6615f27565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561171e57600080fd5b505af1158015611732573d6000803e3d6000fd5b50505050808061174190615e8e565b91505061169b565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600660209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561182057602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611802575b505050505081525050905060005b81604001515181101561198e5760005b600c5481101561197b576000611944600c838154811061186057611860615f27565b90600052602060002001548560400151858151811061188157611881615f27565b60200260200101518860056000896040015189815181106118a4576118a4615f27565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119685750600195945050505050565b508061197381615e8e565b91505061183e565b508061198681615e8e565b91505061182e565b5060009392505050565b6002805414156119d85760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028055336000908152600a60205260409020546001600160601b0380831691161015611a1857604051631e9acf1760e31b815260040160405180910390fd5b336000908152600a602052604081208054839290611a409084906001600160601b0316615e36565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600860148282829054906101000a90046001600160601b0316611a889190615e36565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611b02576040519150601f19603f3d011682016040523d82523d6000602084013e611b07565b606091505b5050905080611b2957604051630dcf35db60e41b815260040160405180910390fd5b5050600160025550565b611b3b6137f6565b6003546001600160a01b031615611b7e576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600380546001600160a01b039384166001600160a01b03199182161790915560048054929093169116179055565b611bb46137f6565b611bbd81613f11565b15611bff576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610bee565b601180546001810182556000919091527f31ecc21a745e3968a04e9570e4425bc18fa8019c68028196b546d1669c200c680180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600280541415611cc35760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028055336000908152600960205260409020546001600160601b0380831691161015611d0357604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611d2b9084906001600160601b0316615e36565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550806008808282829054906101000a90046001600160601b0316611d729190615e36565b82546101009290920a6001600160601b0381810219909316918316021790915560035460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611de157600080fd5b505af1158015611df5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611e19919061554c565b611e3657604051631e9acf1760e31b815260040160405180910390fd5b50506001600255565b611e476137f6565b604080518082018252600091611e76919084906002908390839080828437600092019190915250612f23915050565b6000818152600b60205260409020549091506001600160a01b031615611ecb576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610bee565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d81565b6001546001600160a01b03163314611fb15760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610bee565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600060028054141561204a5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556020808301356000908152600690915260409020546001600160a01b031661208957604051630fb532db60e11b815260040160405180910390fd5b33600090815260056020908152604080832085830135845290915290205467ffffffffffffffff16806120db576040516379bfd40160e01b815260208401356004820152336024820152604401610bee565b600f5461ffff166120f26060850160408601615718565b61ffff161080612115575060c861210f6060850160408601615718565b61ffff16115b1561215b5761212a6060840160408501615718565b600f5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610bee565b600f5462010000900463ffffffff1661217a60808501606086016157f6565b63ffffffff1611156121e35761219660808401606085016157f6565b600f546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610bee565b6101f46121f660a08501608086016157f6565b63ffffffff1611156122555761221260a08401608085016157f6565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610bee565b6000612262826001615d9e565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e0808501849052855180860390910181526101009094019094528251920191909120929350906000906122ee9061111490890189615cc1565b905060006122fb82613e8b565b9050836123066141ca565b60208a013561231b60808c0160608d016157f6565b61232b60a08d0160808e016157f6565b33866040516020016123439796959493929190615b6d565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d60400160208101906123ba9190615718565b8e60600160208101906123cd91906157f6565b8f60800160208101906123e091906157f6565b896040516123f396959493929190615b2e565b60405180910390a4505033600090815260056020908152604080832098820135835297905295909520805467ffffffffffffffff191667ffffffffffffffff939093169290921790915560016002559392505050565b600060028054141561248b5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b6002805560003361249d600143615e1f565b600854604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206008805491925067ffffffffffffffff90911690600061253583615ea9565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561257757612577615f3d565b6040519080825280602002602001820160405280156125a0578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526007835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526006855294909120825181546001600160a01b03199081166001600160a01b0392831617835592516001830180549094169116179091559251805194955090936126ab92600285019201906151fe565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a2509050600160025590565b60028054141561272e5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556003546001600160a01b03163314612776576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146127b0576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006127be82840184615569565b6000818152600660205260409020549091506001600160a01b03166127f657604051630fb532db60e11b815260040160405180910390fd5b600081815260076020526040812080546001600160601b03169186919061281d8385615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550846008808282829054906101000a90046001600160601b03166128649190615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846128b79190615d86565b604080519283526020830191909152015b60405180910390a25050600160025550505050565b6128e56137f6565b6008544790600160a01b90046001600160601b031681811115612925576040516354ced18160e11b81526004810182905260248101839052604401610bee565b818110156129f45760006129398284615e1f565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d8060008114612988576040519150601f19603f3d011682016040523d82523d6000602084013e61298d565b606091505b50509050806129af57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a150505b505050565b612a016137f6565b6000818152600660205260409020546001600160a01b0316612a3657604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040902054610bf79082906001600160a01b0316613852565b612a616137f6565b60c861ffff87161115612a9b5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610bee565b60008213612abf576040516321ea67b360e11b815260048101839052602401610bee565b604080516080808201835261ffff891680835263ffffffff89811660208086018290528a83168688018190528a84166060978801819052600f805465ffffffffffff19168717620100008602176dffffffffffffffff0000000000001916660100000000000084026dffffffff000000000000000000001916176a010000000000000000000083021790558951601080548c86015192881667ffffffffffffffff1990911617640100000000928816929092029190911790819055600e8c9055895196875286840194909452978501529483019590955291810186905283821660a08201529290911c1660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600280541415612c235760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556000818152600660205260409020546001600160a01b0316612c5c57604051630fb532db60e11b815260040160405180910390fd5b6000818152600660205260409020600101546001600160a01b03163314612cce57600081815260066020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610bee565b6000818152600660209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a250506001600255565b60008281526006602052604090205482906001600160a01b031680612d8857604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612dbc57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b600280541415612dfc5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b60028080556000858152600660205260409020015460641415612e4b576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff1615612e8357610e6f565b6001600160a01b03831660008181526005602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600683528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a2505060016002555050565b600081604051602001612f3691906159d7565b604051602081830303815290604052805190602001209050919050565b60008281526006602052604090205482906001600160a01b031680612f8b57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612fbf57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b600280541415612fff5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b6002805561300c84611796565b1561302a57604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260056020908152604080832087845290915290205467ffffffffffffffff16613087576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610bee565b6000848152600660209081526040808320600201805482518185028101850190935280835291929091908301828280156130ea57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116130cc575b505050505090506000600182516131019190615e1f565b905060005b825181101561320d57856001600160a01b031683828151811061312b5761312b615f27565b60200260200101516001600160a01b031614156131fb57600083838151811061315657613156615f27565b6020026020010151905080600660008a8152602001908152602001600020600201838154811061318857613188615f27565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394909416939093179092558981526006909152604090206002018054806131d3576131d3615f11565b600082815260209020810160001990810180546001600160a01b03191690550190555061320d565b8061320581615e8e565b915050613106565b506001600160a01b03851660008181526005602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a791016128c8565b600c818154811061328057600080fd5b600091825260209091200154905081565b60008281526006602052604090205482906001600160a01b0316806132c957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b038216146132fd57604051636c51fda960e11b81526001600160a01b0382166004820152602401610bee565b60028054141561333d5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556000848152600660205260409020600101546001600160a01b03848116911614610e6f5760008481526006602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612f10565b6000818152600660205260408120548190819081906060906001600160a01b031661340757604051630fb532db60e11b815260040160405180910390fd5b60008681526007602090815260408083205460068352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156134ab57602002820191906000526020600020905b81546001600160a01b0316815260019091019060200180831161348d575b505050505090509450945094509450945091939590929450565b6134cd6137f6565b6003546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561352a57600080fd5b505afa15801561353e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135629190615582565b6008549091506801000000000000000090046001600160601b0316818111156135a8576040516354ced18160e11b81526004810182905260248101839052604401610bee565b818110156129f45760006135bc8284615e1f565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561360c57600080fd5b505af1158015613620573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613644919061554c565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b6002805414156136cd5760405162461bcd60e51b815260206004820152601f6024820152600080516020615f778339815191526044820152606401610bee565b600280556000818152600660205260409020546001600160a01b031661370657604051630fb532db60e11b815260040160405180910390fd5b60008181526007602052604090208054600160601b90046001600160601b0316903490600c6137358385615dca565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600860148282829054906101000a90046001600160601b031661377d9190615dca565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846137d09190615d86565b60408051928352602083019190915201612d3f565b6137ed6137f6565b610bf781614263565b6000546001600160a01b031633146138505760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610bee565b565b60008061385e84613f7b565b60035460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156138bb57600080fd5b505af11580156138cf573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906138f3919061554c565b61391057604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613966576040519150601f19603f3d011682016040523d82523d6000602084013e61396b565b606091505b505090508061398d57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b604080516060810182526000808252602082018190528183018190528251808401845291929091613a329186906002908390839080828437600092019190915250612f23915050565b6000818152600b60205260409020549091506001600160a01b031680613a6e57604051631dfd6e1360e21b815260048101839052602401610bee565b6000828660c00135604051602001613a90929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d90935291205490915080613aef576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81613afd6020880188615811565b6020880135613b1260608a0160408b016157f6565b613b2260808b0160608c016157f6565b613b3260a08c0160808d016153d3565b613b3f60a08d018d615cc1565b604051602001613b56989796959493929190615bb7565b604051602081830303815290604052805190602001208114613ba4576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613bbb613bb66020890189615811565b61430d565b905080613cc9576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613bfe60208a018a615811565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613c3e57600080fd5b505afa158015613c52573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c769190615582565b905080613cc957613c8a6020880188615811565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610bee565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613d11613d0b368c90038c018c61563f565b83614414565b90506040518060600160405280888152602001868152602001828152509750505050505050505b92915050565b60005a611388811015613d5057600080fd5b611388810390508460408204820311613d6857600080fd5b50823b613d7457600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613db55750604080516020810190915260008152613d38565b7f92fd133800000000000000000000000000000000000000000000000000000000613de08385615e5e565b6001600160e01b03191614613e21576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613e2e8260048186615d5c565b810190613d85919061559b565b60008115613e6957601054613e629086908690640100000000900463ffffffff168661447f565b9050613e83565b601054613e80908690869063ffffffff16866144e9565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613ec491511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601154811015613f7257826001600160a01b031660118281548110613f3c57613f3c615f27565b6000918252602090912001546001600160a01b03161415613f605750600192915050565b80613f6a81615e8e565b915050613f15565b50600092915050565b6000818152600660209081526040808320815160608101835281546001600160a01b0390811682526001830154168185015260028201805484518187028101870186528181528796879694959486019391929083018282801561400757602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613fe9575b505050919092525050506000858152600760209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b8260400151518110156140e557600560008460400151838151811061409457614094615f27565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff19169055806140dd81615e8e565b91505061406d565b50600085815260066020526040812080546001600160a01b0319908116825560018201805490911690559061411d6002830182615263565b50506000858152600760205260408120556008805485919081906141579084906801000000000000000090046001600160601b0316615e36565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600860148282829054906101000a90046001600160601b031661419f9190615e36565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b18114806141df575062066eed81145b1561425c5760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561421e57600080fd5b505afa158015614232573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906142569190615582565b91505090565b4391505090565b6001600160a01b0381163314156142bc5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610bee565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b1811480614322575062066eed81145b15614404576101008367ffffffffffffffff1661433d6141ca565b6143479190615e1f565b118061436457506143566141ca565b8367ffffffffffffffff1610155b156143725750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156143cc57600080fd5b505afa1580156143e0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613d859190615582565b505067ffffffffffffffff164090565b60006144488360000151846020015185604001518660600151868860a001518960c001518a60e001518b61010001516145f0565b60038360200151604051602001614460929190615acc565b60408051601f1981840301815291905280516020909101209392505050565b60008061448a61482b565b905060005a6144998888615d86565b6144a39190615e1f565b6144ad9085615e00565b905060006144c663ffffffff871664e8d4a51000615e00565b9050826144d38284615d86565b6144dd9190615d86565b98975050505050505050565b6000806144f4614887565b90506000811361451a576040516321ea67b360e11b815260048101829052602401610bee565b600061452461482b565b9050600082825a6145358b8b615d86565b61453f9190615e1f565b6145499088615e00565b6145539190615d86565b61456590670de0b6b3a7640000615e00565b61456f9190615dec565b9050600061458863ffffffff881664e8d4a51000615e00565b90506145a0816b033b2e3c9fd0803ce8000000615e1f565b8211156145d9576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6145e38183615d86565b9998505050505050505050565b6145f98961496e565b6146455760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610bee565b61464e8861496e565b61469a5760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610bee565b6146a38361496e565b6146ef5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610bee565b6146f88261496e565b6147445760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610bee565b614750878a8887614a47565b61479c5760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610bee565b60006147a88a87614b7c565b905060006147bb898b878b868989614be0565b905060006147cc838d8d8a86614d00565b9050808a1461481d5760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610bee565b505050505050505050505050565b60004661a4b1811480614840575062066eed81145b1561487f57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561421e57600080fd5b600091505090565b600f5460048054604080517ffeaf968c00000000000000000000000000000000000000000000000000000000815290516000946601000000000000900463ffffffff169384151593869384936001600160a01b039092169263feaf968c928282019260a09290829003018186803b15801561490157600080fd5b505afa158015614915573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614939919061583b565b50945090925084915050801561495d57506149548242615e1f565b8463ffffffff16105b15613e835750600e54949350505050565b80516000906401000003d019116149c75760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610bee565b60208201516401000003d01911614a205760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610bee565b60208201516401000003d019908009614a408360005b6020020151614d40565b1492915050565b60006001600160a01b038216614a9f5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610bee565b602084015160009060011615614ab657601c614ab9565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614b54573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614b84615281565b614bb160018484604051602001614b9d939291906159b6565b604051602081830303815290604052614d64565b90505b614bbd8161496e565b613d38578051604080516020810192909252614bd99101614b9d565b9050614bb4565b614be8615281565b825186516401000003d0199081900691061415614c475760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610bee565b614c52878988614db3565b614c9e5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610bee565b614ca9848685614db3565b614cf55760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610bee565b6144dd868484614eed565b600060028686868587604051602001614d1e96959493929190615957565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614d6c615281565b614d7582614fb4565b8152614d8a614d85826000614a36565b614fef565b602082018190526002900660011415614dae576020810180516401000003d0190390525b919050565b600082614e025760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610bee565b83516020850151600090614e1890600290615ed1565b15614e2457601c614e27565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614e99573d6000803e3d6000fd5b505050602060405103519050600086604051602001614eb89190615945565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614ef5615281565b835160208086015185519186015160009384938493614f169390919061500f565b919450925090506401000003d019858209600114614f765760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610bee565b60405180604001604052806401000003d01980614f9557614f95615efb565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d0198110614dae57604080516020808201939093528151808203840181529082019091528051910120614fbc565b6000613d388260026150086401000003d0196001615d86565b901c6150ef565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a089050600061504f83838585615191565b909850905061506088828e886151b5565b909850905061507188828c876151b5565b909850905060006150848d878b856151b5565b909850905061509588828686615191565b90985090506150a688828e896151b5565b90985090508181146150db576401000003d019818a0998506401000003d01982890997506401000003d01981830996506150df565b8196505b5050505050509450945094915050565b6000806150fa61529f565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a082015261512c6152bd565b60208160c0846005600019fa9250826151875760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610bee565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b828054828255906000526020600020908101928215615253579160200282015b8281111561525357825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019061521e565b5061525f9291506152db565b5090565b5080546000825590600052602060002090810190610bf791906152db565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561525f57600081556001016152dc565b8035614dae81615f53565b8060408101831015613d3857600080fd5b600082601f83011261531d57600080fd5b615325615d0f565b80838560408601111561533757600080fd5b60005b600281101561535957813584526020938401939091019060010161533a565b509095945050505050565b600060c0828403121561537657600080fd5b50919050565b803561ffff81168114614dae57600080fd5b803563ffffffff81168114614dae57600080fd5b805169ffffffffffffffffffff81168114614dae57600080fd5b80356001600160601b0381168114614dae57600080fd5b6000602082840312156153e557600080fd5b8135613d8581615f53565b6000806040838503121561540357600080fd5b823561540e81615f53565b915061541c602084016153bc565b90509250929050565b6000806040838503121561543857600080fd5b823561544381615f53565b9150602083013561545381615f53565b809150509250929050565b6000806060838503121561547157600080fd5b823561547c81615f53565b915061541c84602085016152fb565b600080600080606085870312156154a157600080fd5b84356154ac81615f53565b935060208501359250604085013567ffffffffffffffff808211156154d057600080fd5b818701915087601f8301126154e457600080fd5b8135818111156154f357600080fd5b88602082850101111561550557600080fd5b95989497505060200194505050565b60006040828403121561552657600080fd5b613d8583836152fb565b60006040828403121561554257600080fd5b613d85838361530c565b60006020828403121561555e57600080fd5b8151613d8581615f68565b60006020828403121561557b57600080fd5b5035919050565b60006020828403121561559457600080fd5b5051919050565b6000602082840312156155ad57600080fd5b6040516020810181811067ffffffffffffffff821117156155d0576155d0615f3d565b60405282356155de81615f68565b81529392505050565b6000808284036101c08112156155fc57600080fd5b6101a08082121561560c57600080fd5b849350830135905067ffffffffffffffff81111561562957600080fd5b61563585828601615364565b9150509250929050565b60006101a0828403121561565257600080fd5b61565a615d38565b615664848461530c565b8152615673846040850161530c565b60208201526080830135604082015260a0830135606082015260c083013560808201526156a260e084016152f0565b60a08201526101006156b68582860161530c565b60c08301526156c985610140860161530c565b60e083015261018084013581830152508091505092915050565b6000602082840312156156f557600080fd5b813567ffffffffffffffff81111561570c57600080fd5b613e8384828501615364565b60006020828403121561572a57600080fd5b613d858261537c565b60008060008060008086880360e081121561574d57600080fd5b6157568861537c565b96506157646020890161538e565b95506157726040890161538e565b94506157806060890161538e565b9350608088013592506040609f198201121561579b57600080fd5b506157a4615d0f565b6157b060a0890161538e565b81526157be60c0890161538e565b6020820152809150509295509295509295565b600080604083850312156157e457600080fd5b82359150602083013561545381615f53565b60006020828403121561580857600080fd5b613d858261538e565b60006020828403121561582357600080fd5b813567ffffffffffffffff81168114613d8557600080fd5b600080600080600060a0868803121561585357600080fd5b61585c866153a2565b945060208601519350604086015192506060860151915061587f608087016153a2565b90509295509295909350565b600081518084526020808501945080840160005b838110156158c45781516001600160a01b03168752958201959082019060010161589f565b509495945050505050565b8060005b60028110156158f25781518452602093840193909101906001016158d3565b50505050565b6000815180845260005b8181101561591e57602081850181015186830182015201615902565b81811115615930576000602083870101525b50601f01601f19169290920160200192915050565b61594f81836158cf565b604001919050565b86815261596760208201876158cf565b61597460608201866158cf565b61598160a08201856158cf565b61598e60e08201846158cf565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526159c660208201846158cf565b606081019190915260800192915050565b60408101613d3882846158cf565b602081526000613d8560208301846158f8565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c06080840152615a3e60e084018261588b565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615abe57845183529383019391830191600101615aa2565b509098975050505050505050565b82815260608101613d8560208301846158cf565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615b2157845183529383019391830191600101615b05565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a08301526144dd60c08301846158f8565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c08301526145e360e08301846158f8565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615c5860808301856158f8565b9050821515606083015295945050505050565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615cb660a083018461588b565b979650505050505050565b6000808335601e19843603018112615cd857600080fd5b83018035915067ffffffffffffffff821115615cf357600080fd5b602001915036819003821315615d0857600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615d3257615d32615f3d565b60405290565b604051610120810167ffffffffffffffff81118282101715615d3257615d32615f3d565b60008085851115615d6c57600080fd5b83861115615d7957600080fd5b5050820193919092039150565b60008219821115615d9957615d99615ee5565b500190565b600067ffffffffffffffff808316818516808303821115615dc157615dc1615ee5565b01949350505050565b60006001600160601b03808316818516808303821115615dc157615dc1615ee5565b600082615dfb57615dfb615efb565b500490565b6000816000190483118215151615615e1a57615e1a615ee5565b500290565b600082821015615e3157615e31615ee5565b500390565b60006001600160601b0383811690831681811015615e5657615e56615ee5565b039392505050565b6001600160e01b03198135818116916004851015615e865780818660040360031b1b83161692505b505092915050565b6000600019821415615ea257615ea2615ee5565b5060010190565b600067ffffffffffffffff80831681811415615ec757615ec7615ee5565b6001019392505050565b600082615ee057615ee0615efb565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610bf757600080fd5b8015158114610bf757600080fdfe5265656e7472616e637947756172643a207265656e7472616e742063616c6c00a164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"reentrancyLock\",\"type\":\"bool\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200605038038062006050833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615e75620001db6000396000818161060b0152613ac70152615e756000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095b578063ee9d2d3814610982578063f2fde38b146109af57600080fd5b8063dc311dd3146108f7578063e72f6e3014610928578063e8509bff1461094857600080fd5b8063d98e620e116100bb578063d98e620e14610881578063da2f2610146108a1578063dac83d29146108d757600080fd5b8063bec4c08c14610821578063caf70c4a14610841578063cb6317971461086157600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107c1578063b08c8795146107e1578063b2a7cac51461080157600080fd5b8063a4c0ed3614610761578063a8cb447b14610781578063aa433aff146107a157600080fd5b80639b1c385e116101745780639b1c385e146106f25780639d40a6fd14610712578063a21a23e41461074c57600080fd5b806386fe91c7146106a85780638da5cb5b146106d457600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461062d5780636f64f03f1461067357806379ba50971461069357600080fd5b806364d51a2a146105c457806366316d8d146105d9578063689c4517146105f957600080fd5b806346d8d4861161022d57806346d8d4861461056457806357133e64146105845780635d06b4ab146105a457600080fd5b806340d6bb821461050957806341af6c871461053457600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610495578063330987b3146104b1578063405b84fa146104e957600080fd5b80630ae095401461041557806315c48b84146104355780631b6b6d231461045d57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103f557600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109cf565b60405161031a9392919061595f565b60405180910390f35b34801561032f57600080fd5b5061034361033e3660046152cb565b610a4b565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600a546103bd9061ffff81169063ffffffff62010000820481169160ff600160301b8204169167010000000000000082048116916b01000000000000000000000090041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a00161031a565b34801561040157600080fd5b5061034361041036600461540c565b610c0d565b34801561042157600080fd5b506103436104303660046156c9565b610da1565b34801561044157600080fd5b5061044a60c881565b60405161ffff909116815260200161031a565b34801561046957600080fd5b5060025461047d906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b3480156104a157600080fd5b506040516001815260200161031a565b3480156104bd57600080fd5b506104d16104cc3660046154df565b610e6f565b6040516001600160601b03909116815260200161031a565b3480156104f557600080fd5b506103436105043660046156c9565b6113b7565b34801561051557600080fd5b5061051f6101f481565b60405163ffffffff909116815260200161031a565b34801561054057600080fd5b5061055461054f366004615461565b611797565b604051901515815260200161031a565b34801561057057600080fd5b5061034361057f3660046152e8565b611999565b34801561059057600080fd5b5061034361059f36600461531d565b611b16565b3480156105b057600080fd5b506103436105bf3660046152cb565b611b8f565b3480156105d057600080fd5b5061044a606481565b3480156105e557600080fd5b506103436105f43660046152e8565b611c66565b34801561060557600080fd5b5061047d7f000000000000000000000000000000000000000000000000000000000000000081565b34801561063957600080fd5b50600f546106569063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561067f57600080fd5b5061034361068e366004615356565b611e05565b34801561069f57600080fd5b50610343611f1d565b3480156106b457600080fd5b506007546104d1906801000000000000000090046001600160601b031681565b3480156106e057600080fd5b506000546001600160a01b031661047d565b3480156106fe57600080fd5b5061035b61070d3660046155db565b611fce565b34801561071e57600080fd5b506007546107339067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561075857600080fd5b5061035b6123f3565b34801561076d57600080fd5b5061034361077c366004615383565b61267b565b34801561078d57600080fd5b5061034361079c3660046152cb565b61284d565b3480156107ad57600080fd5b506103436107bc366004615461565b612968565b3480156107cd57600080fd5b5060035461047d906001600160a01b031681565b3480156107ed57600080fd5b506103436107fc36600461562b565b6129c8565b34801561080d57600080fd5b5061034361081c366004615461565b612b64565b34801561082d57600080fd5b5061034361083c3660046156c9565b612cb3565b34801561084d57600080fd5b5061035b61085c366004615428565b612e69565b34801561086d57600080fd5b5061034361087c3660046156c9565b612e99565b34801561088d57600080fd5b5061035b61089c366004615461565b61319d565b3480156108ad57600080fd5b5061047d6108bc366004615461565b600b602052600090815260409020546001600160a01b031681565b3480156108e357600080fd5b506103436108f23660046156c9565b6131be565b34801561090357600080fd5b50610917610912366004615461565b6132dd565b60405161031a959493929190615b5d565b34801561093457600080fd5b506103436109433660046152cb565b6133d9565b610343610956366004615461565b6135a1565b34801561096757600080fd5b506007546104d190600160a01b90046001600160601b031681565b34801561098e57600080fd5b5061035b61099d366004615461565b600d6020526000908152604090205481565b3480156109bb57600080fd5b506103436109ca3660046152cb565b6136e0565b600a54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3957602002820191906000526020600020905b815481526020019060010190808311610a25575b50505050509050925092509250909192565b610a536136f1565b60105460005b81811015610be057826001600160a01b031660108281548110610a7e57610a7e615e19565b6000918252602090912001546001600160a01b03161415610bce576010610aa6600184615d11565b81548110610ab657610ab6615e19565b600091825260209091200154601080546001600160a01b039092169183908110610ae257610ae2615e19565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826010610b19600185615d11565b81548110610b2957610b29615e19565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506010805480610b6857610b68615e03565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bd881615d80565b915050610a59565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c156136f1565b604080518082018252600091610c44919084906002908390839080828437600092019190915250612e69915050565b6000818152600b60205260409020549091506001600160a01b031680610c8057604051631dfd6e1360e21b815260048101839052602401610c01565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d585782600c8281548110610cbb57610cbb615e19565b90600052602060002001541415610d4657600c805460009190610ce090600190615d11565b81548110610cf057610cf0615e19565b9060005260206000200154905080600c8381548110610d1157610d11615e19565b600091825260209091200155600c805480610d2e57610d2e615e03565b60019003818190600052602060002001600090559055505b80610d5081615d80565b915050610c9d565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9491815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610dd957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0d57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615610e385760405163769dd35360e11b815260040160405180910390fd5b610e4184611797565b15610e5f57604051631685ecdd60e31b815260040160405180910390fd5b610e69848461374d565b50505050565b600a54600090600160301b900460ff1615610e9d5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eae85856138e4565b90506000610ec260808601606087016156ee565b63ffffffff1667ffffffffffffffff811115610ee057610ee0615e2f565b604051908082528060200260200182016040528015610f09578160200160208202803683370190505b50905060005b610f1f60808701606088016156ee565b63ffffffff16811015610f9457826040015181604051602001610f4c929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f7757610f77615e19565b602090810291909101015280610f8c81615d80565b915050610f0f565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e30000000000000000000000000000000000000000000000000000000091610fe5919086906024016159d2565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990941693909317909252600a805466ff0000000000001916600160301b17905591506000906110779061105b9060608b01908b016156ee565b63ffffffff1661107160a08b0160808c016152cb565b84613c35565b600a805466ff00000000000019169055602089810135600090815260069091526040902054909150600160c01b900467ffffffffffffffff166110bb816001615c90565b6020808b01356000908152600690915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915561111c61111760a08c018c615bb3565b613c83565b51600a54909150600090611148908a906b010000000000000000000000900463ffffffff163a85613d32565b90508115611251576020808c01356000908152600690915260409020546001600160601b03808316600160601b90920416101561119857604051631e9acf1760e31b815260040160405180910390fd5b60208b81013560009081526006909152604090208054829190600c906111cf908490600160601b90046001600160601b0316615d28565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261122891859116615cbc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555061133d565b6020808c01356000908152600690915260409020546001600160601b038083169116101561129257604051631e9acf1760e31b815260040160405180910390fd5b6020808c0135600090815260069091526040812080548392906112bf9084906001600160601b0316615d28565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600890915281208054859450909261131891859116615cbc565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113586040518060200160405280851515815250613d82565b90508b6020013589602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8b6040015185858a60405161139d9493929190615b22565b60405180910390a350985050505050505050505b92915050565b6113c081613e08565b6113e857604051635428d44960e01b81526001600160a01b0382166004820152602401610c01565b6000806000806113f7866132dd565b945094505093509350336001600160a01b0316826001600160a01b0316146114615760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c01565b61146a86611797565b156114b75760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c01565b60006040518060c001604052806114cc600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b0316815250905060008160405160200161152091906158ea565b604051602081830303815290604052905061153a88613e72565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061158c9085906004016158d7565b6000604051808303818588803b1580156115a557600080fd5b505af11580156115b9573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561161557600080fd5b505af1158015611629573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061164d9190615444565b6116995760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c01565b60005b835181101561174a578381815181106116b7576116b7615e19565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561171f57600080fd5b505af1158015611733573d6000803e3d6000fd5b50505050808061174290615d80565b91505061169c565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561182157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611803575b505050505081525050905060005b81604001515181101561198f5760005b600c5481101561197c576000611945600c838154811061186157611861615e19565b90600052602060002001548560400151858151811061188257611882615e19565b60200260200101518860046000896040015189815181106118a5576118a5615e19565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119695750600195945050505050565b508061197481615d80565b91505061183f565b508061198781615d80565b91505061182f565b5060009392505050565b600a54600160301b900460ff16156119c45760405163769dd35360e11b815260040160405180910390fd5b336000908152600960205260409020546001600160601b0380831691161015611a0057604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611a289084906001600160601b0316615d28565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a709190615d28565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611aea576040519150601f19603f3d011682016040523d82523d6000602084013e611aef565b606091505b5050905080611b1157604051630dcf35db60e41b815260040160405180910390fd5b505050565b611b1e6136f1565b6002546001600160a01b031615611b61576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611b976136f1565b611ba081613e08565b15611be2576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c01565b601080546001810182556000919091527f1b6847dc741a1b0cd08d278845f9d819d87b734759afb55fe2de5cb82a9ae6720180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600a54600160301b900460ff1615611c915760405163769dd35360e11b815260040160405180910390fd5b336000908152600860205260409020546001600160601b0380831691161015611ccd57604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611cf59084906001600160601b0316615d28565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611d3d9190615d28565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611dac57600080fd5b505af1158015611dc0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611de49190615444565b611e0157604051631e9acf1760e31b815260040160405180910390fd5b5050565b611e0d6136f1565b604080518082018252600091611e3c919084906002908390839080828437600092019190915250612e69915050565b6000818152600b60205260409020549091506001600160a01b031615611e91576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c01565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d94565b6001546001600160a01b03163314611f775760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c01565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600a54600090600160301b900460ff1615611ffc5760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b031661203757604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612089576040516379bfd40160e01b815260208401356004820152336024820152604401610c01565b600a5461ffff166120a06060850160408601615610565b61ffff1610806120c3575060c86120bd6060850160408601615610565b61ffff16115b15612109576120d86060840160408501615610565b600a5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c01565b600a5462010000900463ffffffff1661212860808501606086016156ee565b63ffffffff1611156121915761214460808401606085016156ee565b600a546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c01565b6101f46121a460a08501608086016156ee565b63ffffffff161115612203576121c060a08401608085016156ee565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c01565b6000612210826001615c90565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061229c9061111790890189615bb3565b905060006122a982613d82565b9050836122b46140c2565b60208a01356122c960808c0160608d016156ee565b6122d960a08d0160808e016156ee565b33866040516020016122f19796959493929190615a5f565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d60400160208101906123689190615610565b8e606001602081019061237b91906156ee565b8f608001602081019061238e91906156ee565b896040516123a196959493929190615a20565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff191667ffffffffffffffff9490941693909317909255925050505b919050565b600a54600090600160301b900460ff16156124215760405163769dd35360e11b815260040160405180910390fd5b60003361242f600143615d11565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124c783615d9b565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561250957612509615e2f565b604051908082528060200260200182016040528015612532578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b03928316178355925160018301805490941691161790915592518051949550909361263d92600285019201906150f6565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600a54600160301b900460ff16156126a65760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b031633146126ea576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612724576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061273282840184615461565b6000818152600560205260409020549091506001600160a01b031661276a57604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127918385615cbc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127d99190615cbc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a82878461282c9190615c78565b604080519283526020830191909152015b60405180910390a2505050505050565b6128556136f1565b6007544790600160a01b90046001600160601b031681811115612895576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b115760006128a98284615d11565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128f8576040519150601f19603f3d011682016040523d82523d6000602084013e6128fd565b606091505b505090508061291f57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6129706136f1565b6000818152600560205260409020546001600160a01b03166129a557604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0a9082906001600160a01b031661374d565b6129d06136f1565b60c861ffff87161115612a0a5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c01565b60008213612a2e576040516321ea67b360e11b815260048101839052602401610c01565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600a805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff00000000000000000000001916176b01000000000000000000000083021790558a51600f80548d87015192891667ffffffffffffffff1990911617640100000000928916929092029190911790819055600e8d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600a54600160301b900460ff1615612b8f5760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612bc457604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c3657600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c01565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612ceb57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d1f57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612d4a5760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612d96576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612dce57610e69565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612e7c91906158c9565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612ed157604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612f0557604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612f305760405163769dd35360e11b815260040160405180910390fd5b612f3984611797565b15612f5757604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16612fb4576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c01565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561301757602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612ff9575b5050505050905060006001825161302e9190615d11565b905060005b825181101561313a57856001600160a01b031683828151811061305857613058615e19565b60200260200101516001600160a01b0316141561312857600083838151811061308357613083615e19565b6020026020010151905080600560008a815260200190815260200160002060020183815481106130b5576130b5615e19565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260059091526040902060020180548061310057613100615e03565b600082815260209020810160001990810180546001600160a01b03191690550190555061313a565b8061313281615d80565b915050613033565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161283d565b600c81815481106131ad57600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b0316806131f657604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461322a57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff16156132555760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e695760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e5b565b6000818152600560205260408120548190819081906060906001600160a01b031661331b57604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156133bf57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133a1575b505050505090509450945094509450945091939590929450565b6133e16136f1565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561343e57600080fd5b505afa158015613452573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613476919061547a565b6007549091506801000000000000000090046001600160601b0316818111156134bc576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b115760006134d08284615d11565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561352057600080fd5b505af1158015613534573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135589190615444565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600a54600160301b900460ff16156135cc5760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b031661360157604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136308385615cbc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136789190615cbc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136cb9190615c78565b60408051928352602083019190915201612ca7565b6136e86136f1565b610c0a8161415b565b6000546001600160a01b0316331461374b5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c01565b565b60008061375984613e72565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137b657600080fd5b505af11580156137ca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137ee9190615444565b61380b57604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613861576040519150601f19603f3d011682016040523d82523d6000602084013e613866565b606091505b505090508061388857604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b60408051606081018252600080825260208201819052818301819052825180840184529192909161392d9186906002908390839080828437600092019190915250612e69915050565b6000818152600b60205260409020549091506001600160a01b03168061396957604051631dfd6e1360e21b815260048101839052602401610c01565b6000828660c0013560405160200161398b929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d909352912054909150806139ea576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816139f86020880188615709565b6020880135613a0d60608a0160408b016156ee565b613a1d60808b0160608c016156ee565b613a2d60a08c0160808d016152cb565b613a3a60a08d018d615bb3565b604051602001613a51989796959493929190615aa9565b604051602081830303815290604052805190602001208114613a9f576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613ab6613ab16020890189615709565b614205565b905080613bc4576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613af960208a018a615709565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613b3957600080fd5b505afa158015613b4d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b71919061547a565b905080613bc457613b856020880188615709565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c01565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c0c613c06368c90038c018c615537565b8361430c565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613c4757600080fd5b611388810390508460408204820311613c5f57600080fd5b50823b613c6b57600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613cac57506040805160208101909152600081526113b1565b7f92fd133800000000000000000000000000000000000000000000000000000000613cd78385615d50565b6001600160e01b03191614613d18576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d258260048186615c4e565b810190613c7c9190615493565b60008115613d6057600f54613d599086908690640100000000900463ffffffff1686614377565b9050613d7a565b600f54613d77908690869063ffffffff16866143e1565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613dbb91511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601054811015613e6957826001600160a01b031660108281548110613e3357613e33615e19565b6000918252602090912001546001600160a01b03161415613e575750600192915050565b80613e6181615d80565b915050613e0c565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613efe57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613ee0575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b826040015151811015613fdc576004600084604001518381518110613f8b57613f8b615e19565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613fd481615d80565b915050613f64565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590614014600283018261515b565b50506000858152600660205260408120556007805485919060089061404f9084906801000000000000000090046001600160601b0316615d28565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b03166140979190615d28565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b18114806140d7575062066eed81145b156141545760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561411657600080fd5b505afa15801561412a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061414e919061547a565b91505090565b4391505090565b6001600160a01b0381163314156141b45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c01565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b181148061421a575062066eed81145b156142fc576101008367ffffffffffffffff166142356140c2565b61423f9190615d11565b118061425c575061424e6140c2565b8367ffffffffffffffff1610155b1561426a5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156142c457600080fd5b505afa1580156142d8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c7c919061547a565b505067ffffffffffffffff164090565b60006143408360000151846020015185604001518660600151868860a001518960c001518a60e001518b61010001516144e8565b600383602001516040516020016143589291906159be565b60408051601f1981840301815291905280516020909101209392505050565b600080614382614723565b905060005a6143918888615c78565b61439b9190615d11565b6143a59085615cf2565b905060006143be63ffffffff871664e8d4a51000615cf2565b9050826143cb8284615c78565b6143d59190615c78565b98975050505050505050565b6000806143ec61477f565b905060008113614412576040516321ea67b360e11b815260048101829052602401610c01565b600061441c614723565b9050600082825a61442d8b8b615c78565b6144379190615d11565b6144419088615cf2565b61444b9190615c78565b61445d90670de0b6b3a7640000615cf2565b6144679190615cde565b9050600061448063ffffffff881664e8d4a51000615cf2565b9050614498816b033b2e3c9fd0803ce8000000615d11565b8211156144d1576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6144db8183615c78565b9998505050505050505050565b6144f189614867565b61453d5760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c01565b61454688614867565b6145925760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c01565b61459b83614867565b6145e75760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c01565b6145f082614867565b61463c5760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c01565b614648878a8887614940565b6146945760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c01565b60006146a08a87614a75565b905060006146b3898b878b868989614ad9565b905060006146c4838d8d8a86614bf9565b9050808a146147155760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c01565b505050505050505050505050565b60004661a4b1811480614738575062066eed81145b1561477757606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561411657600080fd5b600091505090565b600a54600354604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b1580156147fa57600080fd5b505afa15801561480e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906148329190615733565b509450909250849150508015614856575061484d8242615d11565b8463ffffffff16105b15613d7a5750600e54949350505050565b80516000906401000003d019116148c05760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d019116149195760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d0199080096149398360005b6020020151614c39565b1492915050565b60006001600160a01b0382166149985760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c01565b6020840151600090600116156149af57601c6149b2565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614a4d573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614a7d615179565b614aaa60018484604051602001614a96939291906158a8565b604051602081830303815290604052614c5d565b90505b614ab681614867565b6113b1578051604080516020810192909252614ad29101614a96565b9050614aad565b614ae1615179565b825186516401000003d0199081900691061415614b405760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c01565b614b4b878988614cab565b614b975760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c01565b614ba2848685614cab565b614bee5760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c01565b6143d5868484614de5565b600060028686868587604051602001614c1796959493929190615849565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614c65615179565b614c6e82614eac565b8152614c83614c7e82600061492f565b614ee7565b6020820181905260029006600114156123ee576020810180516401000003d019039052919050565b600082614cfa5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c01565b83516020850151600090614d1090600290615dc3565b15614d1c57601c614d1f565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614d91573d6000803e3d6000fd5b505050602060405103519050600086604051602001614db09190615837565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614ded615179565b835160208086015185519186015160009384938493614e0e93909190614f07565b919450925090506401000003d019858209600114614e6e5760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c01565b60405180604001604052806401000003d01980614e8d57614e8d615ded565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106123ee57604080516020808201939093528151808203840181529082019091528051910120614eb4565b60006113b1826002614f006401000003d0196001615c78565b901c614fe7565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614f4783838585615089565b9098509050614f5888828e886150ad565b9098509050614f6988828c876150ad565b90985090506000614f7c8d878b856150ad565b9098509050614f8d88828686615089565b9098509050614f9e88828e896150ad565b9098509050818114614fd3576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614fd7565b8196505b5050505050509450945094915050565b600080614ff2615197565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a08201526150246151b5565b60208160c0846005600019fa92508261507f5760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c01565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b82805482825590600052602060002090810192821561514b579160200282015b8281111561514b57825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190615116565b506151579291506151d3565b5090565b5080546000825590600052602060002090810190610c0a91906151d3565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561515757600081556001016151d4565b80356123ee81615e45565b80604081018310156113b157600080fd5b600082601f83011261521557600080fd5b61521d615c01565b80838560408601111561522f57600080fd5b60005b6002811015615251578135845260209384019390910190600101615232565b509095945050505050565b600060c0828403121561526e57600080fd5b50919050565b803561ffff811681146123ee57600080fd5b803563ffffffff811681146123ee57600080fd5b805169ffffffffffffffffffff811681146123ee57600080fd5b80356001600160601b03811681146123ee57600080fd5b6000602082840312156152dd57600080fd5b8135613c7c81615e45565b600080604083850312156152fb57600080fd5b823561530681615e45565b9150615314602084016152b4565b90509250929050565b6000806040838503121561533057600080fd5b823561533b81615e45565b9150602083013561534b81615e45565b809150509250929050565b6000806060838503121561536957600080fd5b823561537481615e45565b915061531484602085016151f3565b6000806000806060858703121561539957600080fd5b84356153a481615e45565b935060208501359250604085013567ffffffffffffffff808211156153c857600080fd5b818701915087601f8301126153dc57600080fd5b8135818111156153eb57600080fd5b8860208285010111156153fd57600080fd5b95989497505060200194505050565b60006040828403121561541e57600080fd5b613c7c83836151f3565b60006040828403121561543a57600080fd5b613c7c8383615204565b60006020828403121561545657600080fd5b8151613c7c81615e5a565b60006020828403121561547357600080fd5b5035919050565b60006020828403121561548c57600080fd5b5051919050565b6000602082840312156154a557600080fd5b6040516020810181811067ffffffffffffffff821117156154c8576154c8615e2f565b60405282356154d681615e5a565b81529392505050565b6000808284036101c08112156154f457600080fd5b6101a08082121561550457600080fd5b849350830135905067ffffffffffffffff81111561552157600080fd5b61552d8582860161525c565b9150509250929050565b60006101a0828403121561554a57600080fd5b615552615c2a565b61555c8484615204565b815261556b8460408501615204565b60208201526080830135604082015260a0830135606082015260c0830135608082015261559a60e084016151e8565b60a08201526101006155ae85828601615204565b60c08301526155c1856101408601615204565b60e083015261018084013581830152508091505092915050565b6000602082840312156155ed57600080fd5b813567ffffffffffffffff81111561560457600080fd5b613d7a8482850161525c565b60006020828403121561562257600080fd5b613c7c82615274565b60008060008060008086880360e081121561564557600080fd5b61564e88615274565b965061565c60208901615286565b955061566a60408901615286565b945061567860608901615286565b9350608088013592506040609f198201121561569357600080fd5b5061569c615c01565b6156a860a08901615286565b81526156b660c08901615286565b6020820152809150509295509295509295565b600080604083850312156156dc57600080fd5b82359150602083013561534b81615e45565b60006020828403121561570057600080fd5b613c7c82615286565b60006020828403121561571b57600080fd5b813567ffffffffffffffff81168114613c7c57600080fd5b600080600080600060a0868803121561574b57600080fd5b6157548661529a565b94506020860151935060408601519250606086015191506157776080870161529a565b90509295509295909350565b600081518084526020808501945080840160005b838110156157bc5781516001600160a01b031687529582019590820190600101615797565b509495945050505050565b8060005b6002811015610e695781518452602093840193909101906001016157cb565b6000815180845260005b81811015615810576020818501810151868301820152016157f4565b81811115615822576000602083870101525b50601f01601f19169290920160200192915050565b61584181836157c7565b604001919050565b86815261585960208201876157c7565b61586660608201866157c7565b61587360a08201856157c7565b61588060e08201846157c7565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526158b860208201846157c7565b606081019190915260800192915050565b604081016113b182846157c7565b602081526000613c7c60208301846157ea565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261593060e0840182615783565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159b057845183529383019391830191600101615994565b509098975050505050505050565b82815260608101613c7c60208301846157c7565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a13578451835293830193918301916001016159f7565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a08301526143d560c08301846157ea565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c08301526144db60e08301846157ea565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b4a60808301856157ea565b9050821515606083015295945050505050565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615ba860a0830184615783565b979650505050505050565b6000808335601e19843603018112615bca57600080fd5b83018035915067ffffffffffffffff821115615be557600080fd5b602001915036819003821315615bfa57600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c2457615c24615e2f565b60405290565b604051610120810167ffffffffffffffff81118282101715615c2457615c24615e2f565b60008085851115615c5e57600080fd5b83861115615c6b57600080fd5b5050820193919092039150565b60008219821115615c8b57615c8b615dd7565b500190565b600067ffffffffffffffff808316818516808303821115615cb357615cb3615dd7565b01949350505050565b60006001600160601b03808316818516808303821115615cb357615cb3615dd7565b600082615ced57615ced615ded565b500490565b6000816000190483118215151615615d0c57615d0c615dd7565b500290565b600082821015615d2357615d23615dd7565b500390565b60006001600160601b0383811690831681811015615d4857615d48615dd7565b039392505050565b6001600160e01b03198135818116916004851015615d785780818660040360031b1b83161692505b505092915050565b6000600019821415615d9457615d94615dd7565b5060010190565b600067ffffffffffffffff80831681811415615db957615db9615dd7565b6001019392505050565b600082615dd257615dd2615ded565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0a57600080fd5b8015158114610c0a57600080fdfea164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI @@ -496,8 +496,9 @@ func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusCaller) SConfig(opts *bind.Call outstruct.MinimumRequestConfirmations = *abi.ConvertType(out[0], new(uint16)).(*uint16) outstruct.MaxGasLimit = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.StalenessSeconds = *abi.ConvertType(out[2], new(uint32)).(*uint32) - outstruct.GasAfterPaymentCalculation = *abi.ConvertType(out[3], new(uint32)).(*uint32) + outstruct.ReentrancyLock = *abi.ConvertType(out[2], new(bool)).(*bool) + outstruct.StalenessSeconds = *abi.ConvertType(out[3], new(uint32)).(*uint32) + outstruct.GasAfterPaymentCalculation = *abi.ConvertType(out[4], new(uint32)).(*uint32) return *outstruct, err @@ -3562,6 +3563,7 @@ type GetSubscription struct { type SConfig struct { MinimumRequestConfirmations uint16 MaxGasLimit uint32 + ReentrancyLock bool StalenessSeconds uint32 GasAfterPaymentCalculation uint32 } diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index b9b7e48ce81..68acad0e7aa 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -74,7 +74,7 @@ vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2Up vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b vrf_coordinator_v2_plus_v2_example: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.bin 02d0ec25e4f3d72f818e7ebc2b5f5949a94889ab0da091f0d3e7f5e4a20a0bb6 -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 109aa4e3d3ca95738d8da15aefc2bf8b09b8f90204ef1a1176ca2d0a8ffe9a9a +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin c7714a63e793d5795f8c787de3a0cddeff240df8458fc8f89c96b2480ae09823 vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c From e37860817f26f3d8fd3f6c8af6f11a0b57fcfabb Mon Sep 17 00:00:00 2001 From: Chris Cushman <104409744+vreff@users.noreply.github.com> Date: Thu, 10 Aug 2023 12:17:46 -0400 Subject: [PATCH 134/270] Trusted BHS (#9809) * Trusted BHS * Make trustedblockhash store extend blockhashstore so that no changes to the coordinator are required. * Prettier on vendored blockhashstore file * Fix whitelist to use mapping from constructor, and add foundry tests * prettier * Update gethwrapper * Resolve merge conflicts * Update migration * Fix trusted BHS job validation * Add integration tests * Fix validate error * Fix delegate nil pointer * Update contracts/test/v0.8/foundry/vrf/TrustedBlockhashStore.t.sol fix typo Co-authored-by: Sam * Fix shadowed test variable warning * Remove accidentally required field * Beef up multithreadedness * Make trusted timeout a const instead of var * Update core/services/blockhashstore/feeder.go Co-authored-by: Makram * Use zero address instead of long zero hex * Update migration number * Re-add required batch size type --------- Co-authored-by: Sam Co-authored-by: Makram --- contracts/scripts/native_solc_compile_all_vrf | 1 + contracts/src/v0.8/dev/vrf/BlockhashStore.sol | 78 ++ .../v0.8/dev/vrf/TrustedBlockhashStore.sol | 66 ++ .../foundry/vrf/TrustedBlockhashStore.t.sol | 72 ++ .../trusted_blockhash_store.go | 680 ++++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + core/services/blockhashstore/bhs.go | 60 +- core/services/blockhashstore/bhs_test.go | 1 + core/services/blockhashstore/common.go | 4 + core/services/blockhashstore/delegate.go | 29 +- core/services/blockhashstore/delegate_test.go | 3 +- core/services/blockhashstore/feeder.go | 171 ++++- core/services/blockhashstore/feeder_test.go | 12 + core/services/blockhashstore/test_util.go | 10 + core/services/blockhashstore/validate.go | 10 +- core/services/blockhashstore/validate_test.go | 16 + core/services/blockheaderfeeder/delegate.go | 2 +- core/services/job/job_orm_test.go | 2 + core/services/job/models.go | 6 + core/services/job/orm.go | 4 +- core/services/vrf/v1/integration_test.go | 2 +- .../vrf/v2/integration_helpers_test.go | 183 ++++- .../vrf/v2/integration_v2_plus_test.go | 59 +- core/services/vrf/v2/integration_v2_test.go | 40 ++ core/services/vrf/vrftesthelpers/helpers.go | 27 +- .../migrations/0187_trusted_bhs_vrfv2plus.sql | 10 + core/testdata/testspecs/v2_specs.go | 39 +- core/web/presenters/job.go | 48 +- core/web/presenters/job_test.go | 30 +- core/web/resolver/spec.go | 14 + core/web/resolver/spec_test.go | 34 +- core/web/schema/type/spec.graphql | 2 + 32 files changed, 1596 insertions(+), 120 deletions(-) create mode 100644 contracts/src/v0.8/dev/vrf/BlockhashStore.sol create mode 100644 contracts/src/v0.8/dev/vrf/TrustedBlockhashStore.sol create mode 100644 contracts/test/v0.8/foundry/vrf/TrustedBlockhashStore.t.sol create mode 100644 core/gethwrappers/generated/trusted_blockhash_store/trusted_blockhash_store.go create mode 100644 core/store/migrate/migrations/0187_trusted_bhs_vrfv2plus.sql diff --git a/contracts/scripts/native_solc_compile_all_vrf b/contracts/scripts/native_solc_compile_all_vrf index 6b40f258af9..ac5a183e55d 100755 --- a/contracts/scripts/native_solc_compile_all_vrf +++ b/contracts/scripts/native_solc_compile_all_vrf @@ -67,6 +67,7 @@ compileContract dev/vrf/testhelpers/VRFV2PlusRevertingExample.sol compileContract dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol compileContract dev/vrf/libraries/VRFV2PlusClient.sol compileContract dev/vrf/testhelpers/VRFCoordinatorV2Plus_V2Example.sol +compileContract dev/vrf/TrustedBlockhashStore.sol # VRF V2 Wrapper compileContract vrf/VRFV2Wrapper.sol diff --git a/contracts/src/v0.8/dev/vrf/BlockhashStore.sol b/contracts/src/v0.8/dev/vrf/BlockhashStore.sol new file mode 100644 index 00000000000..107746f8019 --- /dev/null +++ b/contracts/src/v0.8/dev/vrf/BlockhashStore.sol @@ -0,0 +1,78 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.6; + +import "../../ChainSpecificUtil.sol"; + +/** + * @title BlockhashStore + * @notice This contract provides a way to access blockhashes older than + * the 256 block limit imposed by the BLOCKHASH opcode. + * You may assume that any blockhash stored by the contract is correct. + * Note that the contract depends on the format of serialized Ethereum + * blocks. If a future hardfork of Ethereum changes that format, the + * logic in this contract may become incorrect and an updated version + * would have to be deployed. + */ +contract BlockhashStore { + mapping(uint => bytes32) internal s_blockhashes; + + /** + * @notice stores blockhash of a given block, assuming it is available through BLOCKHASH + * @param n the number of the block whose blockhash should be stored + */ + function store(uint256 n) public { + bytes32 h = ChainSpecificUtil.getBlockhash(uint64(n)); + require(h != 0x0, "blockhash(n) failed"); + s_blockhashes[n] = h; + } + + /** + * @notice stores blockhash of the earliest block still available through BLOCKHASH. + */ + function storeEarliest() external { + store(ChainSpecificUtil.getBlockNumber() - 256); + } + + /** + * @notice stores blockhash after verifying blockheader of child/subsequent block + * @param n the number of the block whose blockhash should be stored + * @param header the rlp-encoded blockheader of block n+1. We verify its correctness by checking + * that it hashes to a stored blockhash, and then extract parentHash to get the n-th blockhash. + */ + function storeVerifyHeader(uint256 n, bytes memory header) public { + require(keccak256(header) == s_blockhashes[n + 1], "header has unknown blockhash"); + + // At this point, we know that header is the correct blockheader for block n+1. + + // The header is an rlp-encoded list. The head item of that list is the 32-byte blockhash of the parent block. + // Based on how rlp works, we know that blockheaders always have the following form: + // 0xf9____a0PARENTHASH... + // ^ ^ ^ + // | | | + // | | +--- PARENTHASH is 32 bytes. rlpenc(PARENTHASH) is 0xa || PARENTHASH. + // | | + // | +--- 2 bytes containing the sum of the lengths of the encoded list items + // | + // +--- 0xf9 because we have a list and (sum of lengths of encoded list items) fits exactly into two bytes. + // + // As a consequence, the PARENTHASH is always at offset 4 of the rlp-encoded block header. + + bytes32 parentHash; + assembly { + parentHash := mload(add(header, 36)) // 36 = 32 byte offset for length prefix of ABI-encoded array + // + 4 byte offset of PARENTHASH (see above) + } + + s_blockhashes[n] = parentHash; + } + + /** + * @notice gets a blockhash from the store. If no hash is known, this function reverts. + * @param n the number of the block whose blockhash should be returned + */ + function getBlockhash(uint256 n) external view returns (bytes32) { + bytes32 h = s_blockhashes[n]; + require(h != 0x0, "blockhash not found in store"); + return h; + } +} diff --git a/contracts/src/v0.8/dev/vrf/TrustedBlockhashStore.sol b/contracts/src/v0.8/dev/vrf/TrustedBlockhashStore.sol new file mode 100644 index 00000000000..bbbc08f3a22 --- /dev/null +++ b/contracts/src/v0.8/dev/vrf/TrustedBlockhashStore.sol @@ -0,0 +1,66 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.6; + +import "../../ChainSpecificUtil.sol"; +import "../../shared/access/ConfirmedOwner.sol"; +import "./BlockhashStore.sol"; + +contract TrustedBlockhashStore is ConfirmedOwner, BlockhashStore { + error NotInWhitelist(); + error InvalidTrustedBlockhashes(); + error InvalidRecentBlockhash(); + + mapping(address => bool) public s_whitelistStatus; + address[] public s_whitelist; + + constructor(address[] memory whitelist) ConfirmedOwner(msg.sender) { + setWhitelist(whitelist); + } + + /** + * @notice sets the whitelist of addresses that can store blockhashes + * @param whitelist the whitelist of addresses that can store blockhashes + */ + function setWhitelist(address[] memory whitelist) public onlyOwner { + address[] memory previousWhitelist = s_whitelist; + s_whitelist = whitelist; + + // Unset whitelist status for all addresses in the previous whitelist, + // and set whitelist status for all addresses in the new whitelist. + for (uint256 i = 0; i < previousWhitelist.length; i++) { + s_whitelistStatus[previousWhitelist[i]] = false; + } + for (uint256 i = 0; i < whitelist.length; i++) { + s_whitelistStatus[whitelist[i]] = true; + } + } + + /** + * @notice stores a list of blockhashes and their respective blocks, only callable + * by a whitelisted address + * @param blockhashes the list of blockhashes and their respective blocks + */ + function storeTrusted( + uint256[] calldata blockNums, + bytes32[] calldata blockhashes, + uint256 recentBlockNumber, + bytes32 recentBlockhash + ) external { + bytes32 onChainHash = ChainSpecificUtil.getBlockhash(uint64(recentBlockNumber)); + if (onChainHash != recentBlockhash) { + revert InvalidRecentBlockhash(); + } + + if (!s_whitelistStatus[msg.sender]) { + revert NotInWhitelist(); + } + + if (blockNums.length != blockhashes.length) { + revert InvalidTrustedBlockhashes(); + } + + for (uint256 i = 0; i < blockNums.length; i++) { + s_blockhashes[blockNums[i]] = blockhashes[i]; + } + } +} diff --git a/contracts/test/v0.8/foundry/vrf/TrustedBlockhashStore.t.sol b/contracts/test/v0.8/foundry/vrf/TrustedBlockhashStore.t.sol new file mode 100644 index 00000000000..d2f52552e43 --- /dev/null +++ b/contracts/test/v0.8/foundry/vrf/TrustedBlockhashStore.t.sol @@ -0,0 +1,72 @@ +pragma solidity 0.8.6; + +import "../BaseTest.t.sol"; +import {TrustedBlockhashStore} from "../../../../src/v0.8/dev/vrf/TrustedBlockhashStore.sol"; +import {console} from "forge-std/console.sol"; + +contract TrustedBlockhashStoreTest is BaseTest { + address internal constant LINK_WHALE = 0xD883a6A1C22fC4AbFE938a5aDF9B2Cc31b1BF18B; + address internal constant LINK_WHALE_2 = 0xe9b2C5A6D9bA93dD354783a9De0a265da7551a20; + TrustedBlockhashStore bhs; + uint256 unreachableBlockNumber = 5; + bytes32 unreachableBlockhash; + + function setUp() public override { + BaseTest.setUp(); + + // Get the blockhash for a block that later becomes unreachable in the EVM. + vm.roll(10); + unreachableBlockhash = blockhash(unreachableBlockNumber); + + // Fund our users. + vm.roll(1000); + vm.deal(LINK_WHALE, 10_000 ether); + changePrank(LINK_WHALE); + + address[] memory whitelist = new address[](1); + whitelist[0] = LINK_WHALE; + bhs = new TrustedBlockhashStore(whitelist); + } + + function testGenericBHSFunctions() public { + // Should store. + uint256 blockNumber = 999; + bhs.store(blockNumber); + assertEq(bhs.getBlockhash(blockNumber), blockhash(blockNumber)); + + // Should store earliest. + uint256 earliestBlockNumber = block.number - 256; + bhs.storeEarliest(); + assertEq(bhs.getBlockhash(earliestBlockNumber), blockhash(earliestBlockNumber)); + } + + function testTrustedBHSFunctions() public { + uint256 recentBlockNumber = 999; + + // Assume that the EVM cannot access the blockhash for block 5. + uint256 unreachableBlock = 5; + assertEq(blockhash(unreachableBlock), 0); + + // Store blockhash from whitelisted address; + uint256[] memory blockNums = new uint256[](1); + blockNums[0] = unreachableBlock; + bytes32[] memory blockhashes = new bytes32[](1); + blockhashes[0] = unreachableBlockhash; + + // Should not be able to store with invalid recent blockhash + vm.expectRevert(TrustedBlockhashStore.InvalidRecentBlockhash.selector); + bhs.storeTrusted(blockNums, blockhashes, recentBlockNumber, blockhash(998)); + + // Should not be able to store or change whitelist for non-whitelisted address. + changePrank(LINK_WHALE_2); + vm.expectRevert(TrustedBlockhashStore.NotInWhitelist.selector); + bhs.storeTrusted(blockNums, blockhashes, recentBlockNumber, blockhash(recentBlockNumber)); + vm.expectRevert("Only callable by owner"); + bhs.setWhitelist(new address[](0)); + + // Should store unreachable blocks via whitelisted address. + changePrank(LINK_WHALE); + bhs.storeTrusted(blockNums, blockhashes, recentBlockNumber, blockhash(recentBlockNumber)); + assertEq(bhs.getBlockhash(unreachableBlock), unreachableBlockhash); + } +} diff --git a/core/gethwrappers/generated/trusted_blockhash_store/trusted_blockhash_store.go b/core/gethwrappers/generated/trusted_blockhash_store/trusted_blockhash_store.go new file mode 100644 index 00000000000..0ddddead4bd --- /dev/null +++ b/core/gethwrappers/generated/trusted_blockhash_store/trusted_blockhash_store.go @@ -0,0 +1,680 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package trusted_blockhash_store + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var TrustedBlockhashStoreMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"whitelist\",\"type\":\"address[]\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidRecentBlockhash\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrustedBlockhashes\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotInWhitelist\",\"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\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"getBlockhash\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_whitelist\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_whitelistStatus\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"whitelist\",\"type\":\"address[]\"}],\"name\":\"setWhitelist\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"}],\"name\":\"store\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"storeEarliest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"blockNums\",\"type\":\"uint256[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"blockhashes\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint256\",\"name\":\"recentBlockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"recentBlockhash\",\"type\":\"bytes32\"}],\"name\":\"storeTrusted\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"n\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"header\",\"type\":\"bytes\"}],\"name\":\"storeVerifyHeader\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60806040523480156200001157600080fd5b50604051620014db380380620014db8339810160408190526200003491620003e8565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d9565b505050620000d2816200018560201b60201c565b5062000517565b6001600160a01b038116331415620001345760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6200018f620002ec565b60006004805480602002602001604051908101604052809291908181526020018280548015620001e957602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311620001ca575b5050855193945062000207936004935060208701925090506200034a565b5060005b81518110156200027757600060036000848481518110620002305762000230620004eb565b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff1916911515919091179055806200026e81620004c1565b9150506200020b565b5060005b8251811015620002e757600160036000858481518110620002a057620002a0620004eb565b6020908102919091018101516001600160a01b03168252810191909152604001600020805460ff191691151591909117905580620002de81620004c1565b9150506200027b565b505050565b6000546001600160a01b03163314620003485760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000082565b565b828054828255906000526020600020908101928215620003a2579160200282015b82811115620003a257825182546001600160a01b0319166001600160a01b039091161782556020909201916001909101906200036b565b50620003b0929150620003b4565b5090565b5b80821115620003b05760008155600101620003b5565b80516001600160a01b0381168114620003e357600080fd5b919050565b60006020808385031215620003fc57600080fd5b82516001600160401b03808211156200041457600080fd5b818501915085601f8301126200042957600080fd5b8151818111156200043e576200043e62000501565b8060051b604051601f19603f8301168101818110858211171562000466576200046662000501565b604052828152858101935084860182860187018a10156200048657600080fd5b600095505b83861015620004b4576200049f81620003cb565b8552600195909501949386019386016200048b565b5098975050505050505050565b6000600019821415620004e457634e487b7160e01b600052601160045260246000fd5b5060010190565b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b610fb480620005276000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80638da5cb5b11610081578063f2fde38b1161005b578063f2fde38b146101b5578063f4217648146101c8578063fadff0e1146101db57600080fd5b80638da5cb5b14610143578063e9413d3814610161578063e9ecc1541461018257600080fd5b80636057361d116100b25780636057361d1461012057806379ba50971461013357806383b6d6b71461013b57600080fd5b80633b69ad60146100ce5780635c7de309146100e3575b600080fd5b6100e16100dc366004610cf6565b6101ee565b005b6100f66100f1366004610d8d565b610326565b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b6100e161012e366004610d8d565b61035d565b6100e16103e8565b6100e16104e5565b60005473ffffffffffffffffffffffffffffffffffffffff166100f6565b61017461016f366004610d8d565b6104ff565b604051908152602001610117565b6101a5610190366004610c27565b60036020526000908152604090205460ff1681565b6040519015158152602001610117565b6100e16101c3366004610c27565b61057b565b6100e16101d6366004610c42565b61058f565b6100e16101e9366004610da6565b610745565b60006101f9836107e8565b9050818114610234576040517fd2f69c9500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3360009081526003602052604090205460ff1661027d576040517f5b0aa2ba00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8584146102b6576040517fbd75093300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b8681101561031c578585828181106102d3576102d3610f49565b90506020020135600260008a8a858181106102f0576102f0610f49565b90506020020135815260200190815260200160002081905550808061031490610ee1565b9150506102b9565b5050505050505050565b6004818154811061033657600080fd5b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff16905081565b6000610368826107e8565b9050806103d6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f626c6f636b68617368286e29206661696c65640000000000000000000000000060448201526064015b60405180910390fd5b60009182526002602052604090912055565b60015473ffffffffffffffffffffffffffffffffffffffff163314610469576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016103cd565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6104fd6101006104f36108f6565b61012e9190610eca565b565b60008181526002602052604081205480610575576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f626c6f636b68617368206e6f7420666f756e6420696e2073746f72650000000060448201526064016103cd565b92915050565b61058361099c565b61058c81610a1d565b50565b61059761099c565b600060048054806020026020016040519081016040528092919081815260200182805480156105fc57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116105d1575b5050855193945061061893600493506020870192509050610b13565b5060005b81518110156106ac5760006003600084848151811061063d5761063d610f49565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055806106a481610ee1565b91505061061c565b5060005b8251811015610740576001600360008584815181106106d1576106d1610f49565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff16825281019190915260400160002080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169115159190911790558061073881610ee1565b9150506106b0565b505050565b60026000610754846001610eb2565b8152602001908152602001600020548180519060200120146107d2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f6865616465722068617320756e6b6e6f776e20626c6f636b686173680000000060448201526064016103cd565b6024015160009182526002602052604090912055565b60004661a4b18114806107fd575062066eed81145b156108e6576101008367ffffffffffffffff166108186108f6565b6108229190610eca565b118061083f57506108316108f6565b8367ffffffffffffffff1610155b1561084d5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156108a757600080fd5b505afa1580156108bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108df9190610d74565b9392505050565b505067ffffffffffffffff164090565b60004661a4b181148061090b575062066eed81145b1561099557606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561095757600080fd5b505afa15801561096b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061098f9190610d74565b91505090565b4391505090565b60005473ffffffffffffffffffffffffffffffffffffffff1633146104fd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103cd565b73ffffffffffffffffffffffffffffffffffffffff8116331415610a9d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103cd565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215610b8d579160200282015b82811115610b8d57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190610b33565b50610b99929150610b9d565b5090565b5b80821115610b995760008155600101610b9e565b803573ffffffffffffffffffffffffffffffffffffffff81168114610bd657600080fd5b919050565b60008083601f840112610bed57600080fd5b50813567ffffffffffffffff811115610c0557600080fd5b6020830191508360208260051b8501011115610c2057600080fd5b9250929050565b600060208284031215610c3957600080fd5b6108df82610bb2565b60006020808385031215610c5557600080fd5b823567ffffffffffffffff80821115610c6d57600080fd5b818501915085601f830112610c8157600080fd5b813581811115610c9357610c93610f78565b8060051b9150610ca4848301610e63565b8181528481019084860184860187018a1015610cbf57600080fd5b600095505b83861015610ce957610cd581610bb2565b835260019590950194918601918601610cc4565b5098975050505050505050565b60008060008060008060808789031215610d0f57600080fd5b863567ffffffffffffffff80821115610d2757600080fd5b610d338a838b01610bdb565b90985096506020890135915080821115610d4c57600080fd5b50610d5989828a01610bdb565b979a9699509760408101359660609091013595509350505050565b600060208284031215610d8657600080fd5b5051919050565b600060208284031215610d9f57600080fd5b5035919050565b60008060408385031215610db957600080fd5b8235915060208084013567ffffffffffffffff80821115610dd957600080fd5b818601915086601f830112610ded57600080fd5b813581811115610dff57610dff610f78565b610e2f847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610e63565b91508082528784828501011115610e4557600080fd5b80848401858401376000848284010152508093505050509250929050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610eaa57610eaa610f78565b604052919050565b60008219821115610ec557610ec5610f1a565b500190565b600082821015610edc57610edc610f1a565b500390565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610f1357610f13610f1a565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var TrustedBlockhashStoreABI = TrustedBlockhashStoreMetaData.ABI + +var TrustedBlockhashStoreBin = TrustedBlockhashStoreMetaData.Bin + +func DeployTrustedBlockhashStore(auth *bind.TransactOpts, backend bind.ContractBackend, whitelist []common.Address) (common.Address, *types.Transaction, *TrustedBlockhashStore, error) { + parsed, err := TrustedBlockhashStoreMetaData.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(TrustedBlockhashStoreBin), backend, whitelist) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &TrustedBlockhashStore{TrustedBlockhashStoreCaller: TrustedBlockhashStoreCaller{contract: contract}, TrustedBlockhashStoreTransactor: TrustedBlockhashStoreTransactor{contract: contract}, TrustedBlockhashStoreFilterer: TrustedBlockhashStoreFilterer{contract: contract}}, nil +} + +type TrustedBlockhashStore struct { + address common.Address + abi abi.ABI + TrustedBlockhashStoreCaller + TrustedBlockhashStoreTransactor + TrustedBlockhashStoreFilterer +} + +type TrustedBlockhashStoreCaller struct { + contract *bind.BoundContract +} + +type TrustedBlockhashStoreTransactor struct { + contract *bind.BoundContract +} + +type TrustedBlockhashStoreFilterer struct { + contract *bind.BoundContract +} + +type TrustedBlockhashStoreSession struct { + Contract *TrustedBlockhashStore + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type TrustedBlockhashStoreCallerSession struct { + Contract *TrustedBlockhashStoreCaller + CallOpts bind.CallOpts +} + +type TrustedBlockhashStoreTransactorSession struct { + Contract *TrustedBlockhashStoreTransactor + TransactOpts bind.TransactOpts +} + +type TrustedBlockhashStoreRaw struct { + Contract *TrustedBlockhashStore +} + +type TrustedBlockhashStoreCallerRaw struct { + Contract *TrustedBlockhashStoreCaller +} + +type TrustedBlockhashStoreTransactorRaw struct { + Contract *TrustedBlockhashStoreTransactor +} + +func NewTrustedBlockhashStore(address common.Address, backend bind.ContractBackend) (*TrustedBlockhashStore, error) { + abi, err := abi.JSON(strings.NewReader(TrustedBlockhashStoreABI)) + if err != nil { + return nil, err + } + contract, err := bindTrustedBlockhashStore(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &TrustedBlockhashStore{address: address, abi: abi, TrustedBlockhashStoreCaller: TrustedBlockhashStoreCaller{contract: contract}, TrustedBlockhashStoreTransactor: TrustedBlockhashStoreTransactor{contract: contract}, TrustedBlockhashStoreFilterer: TrustedBlockhashStoreFilterer{contract: contract}}, nil +} + +func NewTrustedBlockhashStoreCaller(address common.Address, caller bind.ContractCaller) (*TrustedBlockhashStoreCaller, error) { + contract, err := bindTrustedBlockhashStore(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &TrustedBlockhashStoreCaller{contract: contract}, nil +} + +func NewTrustedBlockhashStoreTransactor(address common.Address, transactor bind.ContractTransactor) (*TrustedBlockhashStoreTransactor, error) { + contract, err := bindTrustedBlockhashStore(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &TrustedBlockhashStoreTransactor{contract: contract}, nil +} + +func NewTrustedBlockhashStoreFilterer(address common.Address, filterer bind.ContractFilterer) (*TrustedBlockhashStoreFilterer, error) { + contract, err := bindTrustedBlockhashStore(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &TrustedBlockhashStoreFilterer{contract: contract}, nil +} + +func bindTrustedBlockhashStore(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := TrustedBlockhashStoreMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _TrustedBlockhashStore.Contract.TrustedBlockhashStoreCaller.contract.Call(opts, result, method, params...) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.TrustedBlockhashStoreTransactor.contract.Transfer(opts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.TrustedBlockhashStoreTransactor.contract.Transact(opts, method, params...) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _TrustedBlockhashStore.Contract.contract.Call(opts, result, method, params...) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.contract.Transfer(opts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.contract.Transact(opts, method, params...) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCaller) GetBlockhash(opts *bind.CallOpts, n *big.Int) ([32]byte, error) { + var out []interface{} + err := _TrustedBlockhashStore.contract.Call(opts, &out, "getBlockhash", n) + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) GetBlockhash(n *big.Int) ([32]byte, error) { + return _TrustedBlockhashStore.Contract.GetBlockhash(&_TrustedBlockhashStore.CallOpts, n) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCallerSession) GetBlockhash(n *big.Int) ([32]byte, error) { + return _TrustedBlockhashStore.Contract.GetBlockhash(&_TrustedBlockhashStore.CallOpts, n) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _TrustedBlockhashStore.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 (_TrustedBlockhashStore *TrustedBlockhashStoreSession) Owner() (common.Address, error) { + return _TrustedBlockhashStore.Contract.Owner(&_TrustedBlockhashStore.CallOpts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCallerSession) Owner() (common.Address, error) { + return _TrustedBlockhashStore.Contract.Owner(&_TrustedBlockhashStore.CallOpts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCaller) SWhitelist(opts *bind.CallOpts, arg0 *big.Int) (common.Address, error) { + var out []interface{} + err := _TrustedBlockhashStore.contract.Call(opts, &out, "s_whitelist", arg0) + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) SWhitelist(arg0 *big.Int) (common.Address, error) { + return _TrustedBlockhashStore.Contract.SWhitelist(&_TrustedBlockhashStore.CallOpts, arg0) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCallerSession) SWhitelist(arg0 *big.Int) (common.Address, error) { + return _TrustedBlockhashStore.Contract.SWhitelist(&_TrustedBlockhashStore.CallOpts, arg0) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCaller) SWhitelistStatus(opts *bind.CallOpts, arg0 common.Address) (bool, error) { + var out []interface{} + err := _TrustedBlockhashStore.contract.Call(opts, &out, "s_whitelistStatus", arg0) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) SWhitelistStatus(arg0 common.Address) (bool, error) { + return _TrustedBlockhashStore.Contract.SWhitelistStatus(&_TrustedBlockhashStore.CallOpts, arg0) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreCallerSession) SWhitelistStatus(arg0 common.Address) (bool, error) { + return _TrustedBlockhashStore.Contract.SWhitelistStatus(&_TrustedBlockhashStore.CallOpts, arg0) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "acceptOwnership") +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) AcceptOwnership() (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.AcceptOwnership(&_TrustedBlockhashStore.TransactOpts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.AcceptOwnership(&_TrustedBlockhashStore.TransactOpts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) SetWhitelist(opts *bind.TransactOpts, whitelist []common.Address) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "setWhitelist", whitelist) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) SetWhitelist(whitelist []common.Address) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.SetWhitelist(&_TrustedBlockhashStore.TransactOpts, whitelist) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) SetWhitelist(whitelist []common.Address) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.SetWhitelist(&_TrustedBlockhashStore.TransactOpts, whitelist) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) Store(opts *bind.TransactOpts, n *big.Int) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "store", n) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) Store(n *big.Int) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.Store(&_TrustedBlockhashStore.TransactOpts, n) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) Store(n *big.Int) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.Store(&_TrustedBlockhashStore.TransactOpts, n) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) StoreEarliest(opts *bind.TransactOpts) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "storeEarliest") +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) StoreEarliest() (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.StoreEarliest(&_TrustedBlockhashStore.TransactOpts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) StoreEarliest() (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.StoreEarliest(&_TrustedBlockhashStore.TransactOpts) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) StoreTrusted(opts *bind.TransactOpts, blockNums []*big.Int, blockhashes [][32]byte, recentBlockNumber *big.Int, recentBlockhash [32]byte) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "storeTrusted", blockNums, blockhashes, recentBlockNumber, recentBlockhash) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) StoreTrusted(blockNums []*big.Int, blockhashes [][32]byte, recentBlockNumber *big.Int, recentBlockhash [32]byte) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.StoreTrusted(&_TrustedBlockhashStore.TransactOpts, blockNums, blockhashes, recentBlockNumber, recentBlockhash) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) StoreTrusted(blockNums []*big.Int, blockhashes [][32]byte, recentBlockNumber *big.Int, recentBlockhash [32]byte) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.StoreTrusted(&_TrustedBlockhashStore.TransactOpts, blockNums, blockhashes, recentBlockNumber, recentBlockhash) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) StoreVerifyHeader(opts *bind.TransactOpts, n *big.Int, header []byte) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "storeVerifyHeader", n, header) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) StoreVerifyHeader(n *big.Int, header []byte) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.StoreVerifyHeader(&_TrustedBlockhashStore.TransactOpts, n, header) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) StoreVerifyHeader(n *big.Int, header []byte) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.StoreVerifyHeader(&_TrustedBlockhashStore.TransactOpts, n, header) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _TrustedBlockhashStore.contract.Transact(opts, "transferOwnership", to) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.TransferOwnership(&_TrustedBlockhashStore.TransactOpts, to) +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _TrustedBlockhashStore.Contract.TransferOwnership(&_TrustedBlockhashStore.TransactOpts, to) +} + +type TrustedBlockhashStoreOwnershipTransferRequestedIterator struct { + Event *TrustedBlockhashStoreOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *TrustedBlockhashStoreOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TrustedBlockhashStoreOwnershipTransferRequested) + 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(TrustedBlockhashStoreOwnershipTransferRequested) + 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 *TrustedBlockhashStoreOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *TrustedBlockhashStoreOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TrustedBlockhashStoreOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TrustedBlockhashStoreOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TrustedBlockhashStore.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &TrustedBlockhashStoreOwnershipTransferRequestedIterator{contract: _TrustedBlockhashStore.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *TrustedBlockhashStoreOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TrustedBlockhashStore.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TrustedBlockhashStoreOwnershipTransferRequested) + if err := _TrustedBlockhashStore.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_TrustedBlockhashStore *TrustedBlockhashStoreFilterer) ParseOwnershipTransferRequested(log types.Log) (*TrustedBlockhashStoreOwnershipTransferRequested, error) { + event := new(TrustedBlockhashStoreOwnershipTransferRequested) + if err := _TrustedBlockhashStore.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type TrustedBlockhashStoreOwnershipTransferredIterator struct { + Event *TrustedBlockhashStoreOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *TrustedBlockhashStoreOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(TrustedBlockhashStoreOwnershipTransferred) + 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(TrustedBlockhashStoreOwnershipTransferred) + 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 *TrustedBlockhashStoreOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *TrustedBlockhashStoreOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type TrustedBlockhashStoreOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TrustedBlockhashStoreOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TrustedBlockhashStore.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &TrustedBlockhashStoreOwnershipTransferredIterator{contract: _TrustedBlockhashStore.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_TrustedBlockhashStore *TrustedBlockhashStoreFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *TrustedBlockhashStoreOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _TrustedBlockhashStore.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(TrustedBlockhashStoreOwnershipTransferred) + if err := _TrustedBlockhashStore.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 (_TrustedBlockhashStore *TrustedBlockhashStoreFilterer) ParseOwnershipTransferred(log types.Log) (*TrustedBlockhashStoreOwnershipTransferred, error) { + event := new(TrustedBlockhashStoreOwnershipTransferred) + if err := _TrustedBlockhashStore.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_TrustedBlockhashStore *TrustedBlockhashStore) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _TrustedBlockhashStore.abi.Events["OwnershipTransferRequested"].ID: + return _TrustedBlockhashStore.ParseOwnershipTransferRequested(log) + case _TrustedBlockhashStore.abi.Events["OwnershipTransferred"].ID: + return _TrustedBlockhashStore.ParseOwnershipTransferred(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (TrustedBlockhashStoreOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (TrustedBlockhashStoreOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (_TrustedBlockhashStore *TrustedBlockhashStore) Address() common.Address { + return _TrustedBlockhashStore.address +} + +type TrustedBlockhashStoreInterface interface { + GetBlockhash(opts *bind.CallOpts, n *big.Int) ([32]byte, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SWhitelist(opts *bind.CallOpts, arg0 *big.Int) (common.Address, error) + + SWhitelistStatus(opts *bind.CallOpts, arg0 common.Address) (bool, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + SetWhitelist(opts *bind.TransactOpts, whitelist []common.Address) (*types.Transaction, error) + + Store(opts *bind.TransactOpts, n *big.Int) (*types.Transaction, error) + + StoreEarliest(opts *bind.TransactOpts) (*types.Transaction, error) + + StoreTrusted(opts *bind.TransactOpts, blockNums []*big.Int, blockhashes [][32]byte, recentBlockNumber *big.Int, recentBlockhash [32]byte) (*types.Transaction, error) + + StoreVerifyHeader(opts *bind.TransactOpts, n *big.Int, header []byte) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TrustedBlockhashStoreOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *TrustedBlockhashStoreOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*TrustedBlockhashStoreOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*TrustedBlockhashStoreOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *TrustedBlockhashStoreOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*TrustedBlockhashStoreOwnershipTransferred, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 68acad0e7aa..ca1265dbaa6 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -61,6 +61,7 @@ solidity_vrf_v08_verifier_wrapper: ../../contracts/solc/v0.8.6/VRFTestHelper.abi solidity_vrf_verifier_wrapper: ../../contracts/solc/v0.6/VRFTestHelper.abi ../../contracts/solc/v0.6/VRFTestHelper.bin 44c2b67d8d2990ab580453deb29d63508c6147a3dc49908a1db563bef06e6474 solidity_vrf_wrapper: ../../contracts/solc/v0.6/VRF.abi ../../contracts/solc/v0.6/VRF.bin 04ede5b83c06ba5b76ef99c081c72928007d8a7aaefcf21449a46a07cbd4bfc2 test_api_consumer_wrapper: ../../contracts/solc/v0.6/TestAPIConsumer.abi ../../contracts/solc/v0.6/TestAPIConsumer.bin ed10893cb18894c18e275302329c955f14ea2de37ee044f84aa1e067ac5ea71e +trusted_blockhash_store: ../../contracts/solc/v0.8.6/TrustedBlockhashStore.abi ../../contracts/solc/v0.8.6/TrustedBlockhashStore.bin a85d2899892aa9fd73fc99852ccba52c3983375113580673e6c5d655bfa79909 type_and_version_interface_wrapper: ../../contracts/solc/v0.8.6/TypeAndVersionInterface.abi ../../contracts/solc/v0.8.6/TypeAndVersionInterface.bin bc9c3a6e73e3ebd5b58754df0deeb3b33f4bb404d5709bb904aed51d32f4b45e upkeep_counter_wrapper: ../../contracts/solc/v0.7/UpkeepCounter.abi ../../contracts/solc/v0.7/UpkeepCounter.bin 901961ebf18906febc1c350f02da85c7ea1c2a68da70cfd94efa27c837a48663 upkeep_perform_counter_restrictive_wrapper: ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.abi ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.bin 8975a058fba528e16d8414dc6f13946d17a145fcbc66cf25a32449b6fe1ce878 diff --git a/core/services/blockhashstore/bhs.go b/core/services/blockhashstore/bhs.go index adc1cdb354d..70a9c77669c 100644 --- a/core/services/blockhashstore/bhs.go +++ b/core/services/blockhashstore/bhs.go @@ -17,6 +17,7 @@ import ( txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/blockhash_store" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/trusted_blockhash_store" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/services/pg" @@ -41,7 +42,9 @@ type BulletproofBHS struct { fromAddresses []ethkey.EIP55Address txm txmgr.TxManager abi *abi.ABI + trustedAbi *abi.ABI bhs blockhash_store.BlockhashStoreInterface + trustedBHS *trusted_blockhash_store.TrustedBlockhashStore chainID *big.Int gethks keystore.Eth } @@ -53,6 +56,7 @@ func NewBulletproofBHS( fromAddresses []ethkey.EIP55Address, txm txmgr.TxManager, bhs blockhash_store.BlockhashStoreInterface, + trustedBHS *trusted_blockhash_store.TrustedBlockhashStore, chainID *big.Int, gethks keystore.Eth, ) (*BulletproofBHS, error) { @@ -62,13 +66,20 @@ func NewBulletproofBHS( return nil, errors.Wrap(err, "building ABI") } + trustedBHSAbi, err := trusted_blockhash_store.TrustedBlockhashStoreMetaData.GetAbi() + if err != nil { + return nil, errors.Wrap(err, "building trusted BHS ABI") + } + return &BulletproofBHS{ config: config, dbConfig: dbConfig, fromAddresses: fromAddresses, txm: txm, abi: bhsABI, + trustedAbi: trustedBHSAbi, bhs: bhs, + trustedBHS: trustedBHS, chainID: chainID, gethks: gethks, }, nil @@ -103,9 +114,56 @@ func (c *BulletproofBHS) Store(ctx context.Context, blockNum uint64) error { return nil } +func (c *BulletproofBHS) StoreTrusted( + ctx context.Context, + blockNums []uint64, + blockhashes []common.Hash, + recentBlock uint64, + recentBlockhash common.Hash, +) error { + // Convert and pack arguments for a "storeTrusted" function call to the trusted BHS. + var blockNumsBig []*big.Int + for _, b := range blockNums { + blockNumsBig = append(blockNumsBig, new(big.Int).SetUint64(b)) + } + recentBlockBig := new(big.Int).SetUint64(recentBlock) + payload, err := c.trustedAbi.Pack("storeTrusted", blockNumsBig, blockhashes, recentBlockBig, recentBlockhash) + if err != nil { + return errors.Wrap(err, "packing args") + } + + // Create a transaction from the given batch and send it to the TXM. + fromAddress, err := c.gethks.GetRoundRobinAddress(c.chainID, SendingKeys(c.fromAddresses)...) + if err != nil { + return errors.Wrap(err, "getting next from address") + } + _, err = c.txm.CreateTransaction(txmgr.TxRequest{ + FromAddress: fromAddress, + ToAddress: c.trustedBHS.Address(), + EncodedPayload: payload, + FeeLimit: c.config.LimitDefault(), + + Strategy: txmgrcommon.NewSendEveryStrategy(), + }, pg.WithParentCtx(ctx)) + if err != nil { + return errors.Wrap(err, "creating transaction") + } + + return nil +} + +func (c *BulletproofBHS) IsTrusted() bool { + return c.trustedBHS != nil +} + // IsStored satisfies the BHS interface. func (c *BulletproofBHS) IsStored(ctx context.Context, blockNum uint64) (bool, error) { - _, err := c.bhs.GetBlockhash(&bind.CallOpts{Context: ctx}, big.NewInt(int64(blockNum))) + var err error + if c.IsTrusted() { + _, err = c.trustedBHS.GetBlockhash(&bind.CallOpts{Context: ctx}, big.NewInt(int64(blockNum))) + } else { + _, err = c.bhs.GetBlockhash(&bind.CallOpts{Context: ctx}, big.NewInt(int64(blockNum))) + } if err != nil && strings.Contains(err.Error(), "reverted") { // Transaction reverted because the blockhash is not stored return false, nil diff --git a/core/services/blockhashstore/bhs_test.go b/core/services/blockhashstore/bhs_test.go index 61332ecb0ab..6f90d6312f3 100644 --- a/core/services/blockhashstore/bhs_test.go +++ b/core/services/blockhashstore/bhs_test.go @@ -50,6 +50,7 @@ func TestStoreRotatesFromAddresses(t *testing.T) { fromAddresses, txm, store, + nil, &cltest.FixtureChainID, ks.Eth(), ) diff --git a/core/services/blockhashstore/common.go b/core/services/blockhashstore/common.go index f8c5b62b98d..61aaf989298 100644 --- a/core/services/blockhashstore/common.go +++ b/core/services/blockhashstore/common.go @@ -42,6 +42,10 @@ type BHS interface { // StoreEarliest stores the earliest possible blockhash (i.e. block.number - 256) StoreEarliest(ctx context.Context) error + + IsTrusted() bool + + StoreTrusted(ctx context.Context, blockNums []uint64, blockhashes []common.Hash, recentBlock uint64, recentBlockhash common.Hash) error } func GetUnfulfilledBlocksAndRequests( diff --git a/core/services/blockhashstore/delegate.go b/core/services/blockhashstore/delegate.go index d8d51327bcd..ad248c8980d 100644 --- a/core/services/blockhashstore/delegate.go +++ b/core/services/blockhashstore/delegate.go @@ -10,6 +10,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/blockhash_store" v1 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/solidity_vrf_coordinator_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/trusted_blockhash_store" v2 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2" v2plus "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -88,6 +89,17 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { return nil, errors.Wrap(err, "building BHS") } + var trustedBHS *trusted_blockhash_store.TrustedBlockhashStore + if jb.BlockhashStoreSpec.TrustedBlockhashStoreAddress != nil && jb.BlockhashStoreSpec.TrustedBlockhashStoreAddress.Hex() != EmptyAddress { + trustedBHS, err = trusted_blockhash_store.NewTrustedBlockhashStore( + jb.BlockhashStoreSpec.TrustedBlockhashStoreAddress.Address(), + chain.Client(), + ) + if err != nil { + return nil, errors.Wrap(err, "building trusted BHS") + } + } + lp := chain.LogPoller() var coordinators []Coordinator if jb.BlockhashStoreSpec.CoordinatorV1Address != nil { @@ -136,7 +148,16 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { coordinators = append(coordinators, coord) } - bpBHS, err := NewBulletproofBHS(chain.Config().EVM().GasEstimator(), chain.Config().Database(), fromAddresses, chain.TxManager(), bhs, chain.ID(), d.ks) + bpBHS, err := NewBulletproofBHS( + chain.Config().EVM().GasEstimator(), + chain.Config().Database(), + fromAddresses, + chain.TxManager(), + bhs, + trustedBHS, + chain.ID(), + d.ks, + ) if err != nil { return nil, errors.Wrap(err, "building bulletproof bhs") } @@ -146,14 +167,16 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { log, NewMultiCoordinator(coordinators...), bpBHS, + lp, + jb.BlockhashStoreSpec.TrustedBlockhashStoreBatchSize, int(jb.BlockhashStoreSpec.WaitBlocks), int(jb.BlockhashStoreSpec.LookbackBlocks), func(ctx context.Context) (uint64, error) { - head, err := chain.Client().HeadByNumber(ctx, nil) + head, err := lp.LatestBlock(pg.WithParentCtx(ctx)) if err != nil { return 0, errors.Wrap(err, "getting chain head") } - return uint64(head.Number), nil + return uint64(head), nil }) return []job.ServiceCtx{&service{ diff --git a/core/services/blockhashstore/delegate_test.go b/core/services/blockhashstore/delegate_test.go index 7ed3a9119c7..a877906228a 100644 --- a/core/services/blockhashstore/delegate_test.go +++ b/core/services/blockhashstore/delegate_test.go @@ -57,6 +57,7 @@ func createTestDelegate(t *testing.T) (*blockhashstore.Delegate, *testData) { sendingKey, _ := cltest.MustAddRandomKeyToKeystore(t, kst) lp := &mocklp.LogPoller{} lp.On("RegisterFilter", mock.Anything).Return(nil) + lp.On("LatestBlock", mock.Anything, mock.Anything).Return(int64(0), nil) chainSet := evmtest.NewChainSet( t, evmtest.TestChainOpts{ @@ -161,8 +162,6 @@ func TestDelegate_StartStop(t *testing.T) { require.NoError(t, err) require.Len(t, services, 1) - blocks := cltest.NewBlocks(t, 1) - testData.ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Return(blocks.Head(0), nil) err = services[0].Start(testutils.Context(t)) require.NoError(t, err) diff --git a/core/services/blockhashstore/feeder.go b/core/services/blockhashstore/feeder.go index ba1445f0e1a..22bbf7f163d 100644 --- a/core/services/blockhashstore/feeder.go +++ b/core/services/blockhashstore/feeder.go @@ -2,46 +2,64 @@ package blockhashstore import ( "context" + "sync" + "time" + "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" "go.uber.org/multierr" + "golang.org/x/exp/maps" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/logger" ) +const trustedTimeout = 1 * time.Second + // NewFeeder creates a new Feeder instance. func NewFeeder( logger logger.Logger, coordinator Coordinator, bhs BHS, + lp logpoller.LogPoller, + trustedBHSBatchSize int32, waitBlocks int, lookbackBlocks int, latestBlock func(ctx context.Context) (uint64, error), ) *Feeder { return &Feeder{ - lggr: logger, - coordinator: coordinator, - bhs: bhs, - waitBlocks: waitBlocks, - lookbackBlocks: lookbackBlocks, - latestBlock: latestBlock, - stored: make(map[uint64]struct{}), - lastRunBlock: 0, + lggr: logger, + coordinator: coordinator, + bhs: bhs, + lp: lp, + trustedBHSBatchSize: trustedBHSBatchSize, + waitBlocks: waitBlocks, + lookbackBlocks: lookbackBlocks, + latestBlock: latestBlock, + stored: make(map[uint64]struct{}), + lastRunBlock: 0, + wgStored: sync.WaitGroup{}, } } // Feeder checks recent VRF coordinator events and stores any blockhashes for blocks within // waitBlocks and lookbackBlocks that have unfulfilled requests. type Feeder struct { - lggr logger.Logger - coordinator Coordinator - bhs BHS - waitBlocks int - lookbackBlocks int - latestBlock func(ctx context.Context) (uint64, error) + lggr logger.Logger + coordinator Coordinator + bhs BHS + lp logpoller.LogPoller + trustedBHSBatchSize int32 + waitBlocks int + lookbackBlocks int + latestBlock func(ctx context.Context) (uint64, error) stored map[uint64]struct{} lastRunBlock uint64 + wgStored sync.WaitGroup + batchLock sync.Mutex + storedLock sync.RWMutex + errsLock sync.Mutex } // Run the feeder. @@ -64,6 +82,11 @@ func (f *Feeder) Run(ctx context.Context) error { return err } + // For a trusted BHS, run our trusted logic. + if f.bhs.IsTrusted() { + return f.runTrusted(ctx, latestBlock, fromBlock, blockToRequests) + } + var errs error for block, unfulfilledReqs := range blockToRequests { if len(unfulfilledReqs) == 0 { @@ -114,3 +137,123 @@ func (f *Feeder) Run(ctx context.Context) error { f.lastRunBlock = latestBlock return errs } + +func (f *Feeder) runTrusted( + ctx context.Context, + latestBlock uint64, + fromBlock uint64, + blockToRequests map[uint64]map[string]struct{}, +) error { + var errs error + + // Iterate through each request block via waitGroup. + // For blocks with pending requests, add them to the batch to be stored. + // Note: Golang maps sort items in a range randomly, so although the batch size is used + // to limit blocks-per-batch, every block has an equal chance of getting picked up + // on each run. + var batch = make(map[uint64]struct{}) + for blockKey, unfulfilledReqs := range blockToRequests { + f.wgStored.Add(1) + var unfulfilled = unfulfilledReqs + var block = blockKey + go func() { + defer f.wgStored.Done() + if len(unfulfilled) == 0 { + return + } + f.storedLock.RLock() + if _, ok := f.stored[block]; ok { + // Already stored + f.storedLock.RUnlock() + return + } + f.storedLock.RUnlock() + + // Do not store a block if it has been marked as stored; otherwise, store it even + // if the RPC call errors, as to be conservative. + timeoutCtx, cancel := context.WithTimeout(ctx, trustedTimeout) + defer cancel() + stored, err := f.bhs.IsStored(timeoutCtx, block) + if err != nil { + f.lggr.Errorw("Failed to check if block is already stored, attempting to store anyway", + "err", err, + "block", block) + f.errsLock.Lock() + errs = multierr.Append(errs, errors.Wrap(err, "checking if stored")) + f.errsLock.Unlock() + } else if stored { + f.lggr.Infow("Blockhash already stored", + "block", block, "latestBlock", latestBlock, + "unfulfilledReqIDs", LimitReqIDs(unfulfilled, 50)) + f.storedLock.Lock() + f.stored[block] = struct{}{} + f.storedLock.Unlock() + return + } + + // If there's room, store the block in the batch. Threadsafe. + f.batchLock.Lock() + if len(batch) < int(f.trustedBHSBatchSize) { + batch[block] = struct{}{} + } + f.batchLock.Unlock() + }() + } + + // Ensure all blocks are checked before storing the batch. + f.wgStored.Wait() + + // For a non-empty batch, store all blocks. + if len(batch) != 0 { + var blocksToStore []uint64 + var blockhashesToStore []common.Hash + var latestBlockhash common.Hash + + // Get all logpoller blocks for the range including the batch and the latest block, + // as to include the recent blockhash. + lpBlocks, err := f.lp.GetBlocksRange(ctx, append(maps.Keys(batch), latestBlock)) + if err != nil { + f.lggr.Errorw("Failed to get blocks range", + "err", err, + "blocks", batch) + errs = multierr.Append(errs, errors.Wrap(err, "log poller get blocks range")) + return errs + } + + // If the log poller block's blocknumber is included in the desired batch, + // append its blockhash to our blockhashes we want to store. + // If it is the log poller block pertaining to our recent block number, assig it. + for _, b := range lpBlocks { + if _, ok := batch[uint64(b.BlockNumber)]; ok { + blocksToStore = append(blocksToStore, uint64(b.BlockNumber)) + blockhashesToStore = append(blockhashesToStore, b.BlockHash) + } + if b.BlockNumber == int64(latestBlock) { + latestBlockhash = b.BlockHash + } + } + + // Store the batch of blocks and their blockhashes. + err = f.bhs.StoreTrusted(ctx, blocksToStore, blockhashesToStore, latestBlock, latestBlockhash) + if err != nil { + f.lggr.Errorw("Failed to store trusted", + "err", err, + "blocks", blocksToStore, + "blockhashesToStore", blockhashesToStore, + "latestBlock", latestBlock, + "latestBlockhash", latestBlockhash, + ) + errs = multierr.Append(errs, errors.Wrap(err, "checking if stored")) + return errs + } + } + + // Prune stored, anything older than fromBlock can be discarded. + for b := range f.stored { + if b < fromBlock { + delete(f.stored, b) + } + } + + return errs +} diff --git a/core/services/blockhashstore/feeder_test.go b/core/services/blockhashstore/feeder_test.go index 1205f09e3a6..cd444d3e026 100644 --- a/core/services/blockhashstore/feeder_test.go +++ b/core/services/blockhashstore/feeder_test.go @@ -229,10 +229,13 @@ func TestFeeder(t *testing.T) { FulfillmentEvents: test.fulfillments, } + lp := &mocklp.LogPoller{} feeder := NewFeeder( logger.TestLogger(t), coordinator, &test.bhs, + lp, + 0, test.wait, test.lookback, func(ctx context.Context) (uint64, error) { @@ -322,6 +325,8 @@ func TestFeederWithLogPollerVRFv1(t *testing.T) { logger.TestLogger(t), coordinator, &test.bhs, + lp, + 0, test.wait, test.lookback, func(ctx context.Context) (uint64, error) { @@ -415,6 +420,8 @@ func TestFeederWithLogPollerVRFv2(t *testing.T) { logger.TestLogger(t), coordinator, &test.bhs, + lp, + 0, test.wait, test.lookback, func(ctx context.Context) (uint64, error) { @@ -508,6 +515,8 @@ func TestFeederWithLogPollerVRFv2Plus(t *testing.T) { logger.TestLogger(t), coordinator, &test.bhs, + lp, + 0, test.wait, test.lookback, func(ctx context.Context) (uint64, error) { @@ -533,10 +542,13 @@ func TestFeeder_CachesStoredBlocks(t *testing.T) { bhs := &TestBHS{} + lp := &mocklp.LogPoller{} feeder := NewFeeder( logger.TestLogger(t), coordinator, bhs, + lp, + 0, 100, 200, func(ctx context.Context) (uint64, error) { diff --git a/core/services/blockhashstore/test_util.go b/core/services/blockhashstore/test_util.go index f82296e7d00..6b7c3836650 100644 --- a/core/services/blockhashstore/test_util.go +++ b/core/services/blockhashstore/test_util.go @@ -61,6 +61,16 @@ func (t *TestBHS) Store(_ context.Context, blockNum uint64) error { return nil } +func (t *TestBHS) IsTrusted() bool { + return false +} + +func (t *TestBHS) StoreTrusted( + ctx context.Context, blockNums []uint64, blockhashes []common.Hash, recentBlock uint64, recentBlockhash common.Hash, +) error { + return errors.New("not implemented") +} + func (t *TestBHS) IsStored(_ context.Context, blockNum uint64) (bool, error) { for _, e := range t.ErrorsIsStored { if e == blockNum { diff --git a/core/services/blockhashstore/validate.go b/core/services/blockhashstore/validate.go index 503e15c9a19..157f6f2ec03 100644 --- a/core/services/blockhashstore/validate.go +++ b/core/services/blockhashstore/validate.go @@ -8,8 +8,11 @@ import ( "github.com/pkg/errors" "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) +var EmptyAddress = utils.ZeroAddress.Hex() + // ValidatedSpec validates and converts the given toml string to a job.Job. func ValidatedSpec(tomlString string) (job.Job, error) { jb := job.Job{ @@ -48,6 +51,9 @@ func ValidatedSpec(tomlString string) (job.Job, error) { if spec.EVMChainID == nil { return jb, notSet("evmChainID") } + if spec.TrustedBlockhashStoreAddress != nil && spec.TrustedBlockhashStoreAddress.Hex() != EmptyAddress && spec.TrustedBlockhashStoreBatchSize == 0 { + return jb, notSet("trustedBlockhashStoreBatchSize") + } // Defaults if spec.WaitBlocks == 0 { @@ -67,10 +73,10 @@ func ValidatedSpec(tomlString string) (job.Job, error) { if spec.WaitBlocks >= spec.LookbackBlocks { return jb, errors.New(`"waitBlocks" must be less than "lookbackBlocks"`) } - if spec.WaitBlocks >= 256 { + if (spec.TrustedBlockhashStoreAddress == nil || spec.TrustedBlockhashStoreAddress.Hex() == EmptyAddress) && spec.WaitBlocks >= 256 { return jb, errors.New(`"waitBlocks" must be less than 256`) } - if spec.LookbackBlocks >= 256 { + if (spec.TrustedBlockhashStoreAddress == nil || spec.TrustedBlockhashStoreAddress.Hex() == EmptyAddress) && spec.LookbackBlocks >= 256 { return jb, errors.New(`"lookbackBlocks" must be less than 256`) } diff --git a/core/services/blockhashstore/validate_test.go b/core/services/blockhashstore/validate_test.go index d6d158f4c24..10eaae10d34 100644 --- a/core/services/blockhashstore/validate_test.go +++ b/core/services/blockhashstore/validate_test.go @@ -183,6 +183,22 @@ evmChainID = "4"`, require.EqualError(t, err, `"waitBlocks" must be less than "lookbackBlocks"`) }, }, + { + name: "invalid waitBlocks higher than lookbackBlocks", + toml: ` +type = "blockhashstore" +name = "valid-test" +coordinatorV1Address = "0x1F72B4A5DCf7CC6d2E38423bF2f4BFA7db97d139" +coordinatorV2Address = "0x2be990eE17832b59E0086534c5ea2459Aa75E38F" +waitBlocks = 10 +lookbackBlocks = 100 +blockhashStoreAddress = "0x3e20Cef636EdA7ba135bCbA4fe6177Bd3cE0aB17" +trustedBlockhashStoreAddress = "0x469aA2CD13e037DC5236320783dCfd0e641c0559" +evmChainID = "4"`, + assertion: func(t *testing.T, os job.Job, err error) { + require.EqualError(t, err, `"trustedBlockhashStoreBatchSize" must be set`) + }, + }, { name: "invalid toml", toml: ` diff --git a/core/services/blockheaderfeeder/delegate.go b/core/services/blockheaderfeeder/delegate.go index 3d026289e8f..251d60f7ad1 100644 --- a/core/services/blockheaderfeeder/delegate.go +++ b/core/services/blockheaderfeeder/delegate.go @@ -138,7 +138,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { coordinators = append(coordinators, coord) } - bpBHS, err := blockhashstore.NewBulletproofBHS(chain.Config().EVM().GasEstimator(), chain.Config().Database(), fromAddresses, chain.TxManager(), bhs, chain.ID(), d.ks) + bpBHS, err := blockhashstore.NewBulletproofBHS(chain.Config().EVM().GasEstimator(), chain.Config().Database(), fromAddresses, chain.TxManager(), bhs, nil, chain.ID(), d.ks) if err != nil { return nil, errors.Wrap(err, "building bulletproof bhs") } diff --git a/core/services/job/job_orm_test.go b/core/services/job/job_orm_test.go index ef2e216794e..b707fef3122 100644 --- a/core/services/job/job_orm_test.go +++ b/core/services/job/job_orm_test.go @@ -257,6 +257,8 @@ func TestORM(t *testing.T) { require.Equal(t, jb.BlockhashStoreSpec.WaitBlocks, savedJob.BlockhashStoreSpec.WaitBlocks) require.Equal(t, jb.BlockhashStoreSpec.LookbackBlocks, savedJob.BlockhashStoreSpec.LookbackBlocks) require.Equal(t, jb.BlockhashStoreSpec.BlockhashStoreAddress, savedJob.BlockhashStoreSpec.BlockhashStoreAddress) + require.Equal(t, jb.BlockhashStoreSpec.TrustedBlockhashStoreAddress, savedJob.BlockhashStoreSpec.TrustedBlockhashStoreAddress) + require.Equal(t, jb.BlockhashStoreSpec.TrustedBlockhashStoreBatchSize, savedJob.BlockhashStoreSpec.TrustedBlockhashStoreBatchSize) require.Equal(t, jb.BlockhashStoreSpec.PollPeriod, savedJob.BlockhashStoreSpec.PollPeriod) require.Equal(t, jb.BlockhashStoreSpec.RunTimeout, savedJob.BlockhashStoreSpec.RunTimeout) require.Equal(t, jb.BlockhashStoreSpec.EVMChainID, savedJob.BlockhashStoreSpec.EVMChainID) diff --git a/core/services/job/models.go b/core/services/job/models.go index afab19b3b77..d14c16d1adf 100644 --- a/core/services/job/models.go +++ b/core/services/job/models.go @@ -553,6 +553,12 @@ type BlockhashStoreSpec struct { // into. BlockhashStoreAddress ethkey.EIP55Address `toml:"blockhashStoreAddress"` + // BatchBlockhashStoreAddress is the address of the trusted BlockhashStore contract to store blockhashes + TrustedBlockhashStoreAddress *ethkey.EIP55Address `toml:"trustedBlockhashStoreAddress"` + + // BatchBlockhashStoreBatchSize is the number of blockhashes to store in a single batch + TrustedBlockhashStoreBatchSize int32 `toml:"trustedBlockhashStoreBatchSize"` + // PollPeriod defines how often recent blocks should be scanned for blockhash storage. PollPeriod time.Duration `toml:"pollPeriod"` diff --git a/core/services/job/orm.go b/core/services/job/orm.go index a7e7f16bc20..8543c13a14a 100644 --- a/core/services/job/orm.go +++ b/core/services/job/orm.go @@ -375,8 +375,8 @@ func (o *orm) CreateJob(jb *Job, qopts ...pg.QOpt) error { } case BlockhashStore: var specID int32 - sql := `INSERT INTO blockhash_store_specs (coordinator_v1_address, coordinator_v2_address, coordinator_v2_plus_address, wait_blocks, lookback_blocks, blockhash_store_address, poll_period, run_timeout, evm_chain_id, from_addresses, created_at, updated_at) - VALUES (:coordinator_v1_address, :coordinator_v2_address, :coordinator_v2_plus_address, :wait_blocks, :lookback_blocks, :blockhash_store_address, :poll_period, :run_timeout, :evm_chain_id, :from_addresses, NOW(), NOW()) + sql := `INSERT INTO blockhash_store_specs (coordinator_v1_address, coordinator_v2_address, coordinator_v2_plus_address, trusted_blockhash_store_address, trusted_blockhash_store_batch_size, wait_blocks, lookback_blocks, blockhash_store_address, poll_period, run_timeout, evm_chain_id, from_addresses, created_at, updated_at) + VALUES (:coordinator_v1_address, :coordinator_v2_address, :coordinator_v2_plus_address, :trusted_blockhash_store_address, :trusted_blockhash_store_batch_size, :wait_blocks, :lookback_blocks, :blockhash_store_address, :poll_period, :run_timeout, :evm_chain_id, :from_addresses, NOW(), NOW()) RETURNING id;` if err := pg.PrepareQueryRowx(tx, sql, &specID, toBlockhashStoreSpecRow(jb.BlockhashStoreSpec)); err != nil { return errors.Wrap(err, "failed to create BlockhashStore spec") diff --git a/core/services/vrf/v1/integration_test.go b/core/services/vrf/v1/integration_test.go index d9154a4873f..87cf235cfae 100644 --- a/core/services/vrf/v1/integration_test.go +++ b/core/services/vrf/v1/integration_test.go @@ -147,7 +147,7 @@ func TestIntegration_VRF_WithBHS(t *testing.T) { // Create BHS Job and start it bhsJob := vrftesthelpers.CreateAndStartBHSJob(t, sendingKeys, app, cu.BHSContractAddress.String(), - cu.RootContractAddress.String(), "", "") + cu.RootContractAddress.String(), "", "", "", 0, 200) // Ensure log poller is ready and has all logs. require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) diff --git a/core/services/vrf/v2/integration_helpers_test.go b/core/services/vrf/v2/integration_helpers_test.go index fd491367d27..5867796b7c5 100644 --- a/core/services/vrf/v2/integration_helpers_test.go +++ b/core/services/vrf/v2/integration_helpers_test.go @@ -242,7 +242,7 @@ func testMultipleConsumersNeedBHS( _ = vrftesthelpers.CreateAndStartBHSJob( t, bhsKeyAddresses, app, uni.bhsContractAddress.String(), "", - v2CoordinatorAddress, v2PlusCoordinatorAddress) + v2CoordinatorAddress, v2PlusCoordinatorAddress, "", 0, 200) // Ensure log poller is ready and has all logs. require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) @@ -298,6 +298,161 @@ func testMultipleConsumersNeedBHS( } } +func testMultipleConsumersNeedTrustedBHS( + t *testing.T, + ownerKey ethkey.KeyV2, + uni coordinatorV2PlusUniverse, + consumers []*bind.TransactOpts, + consumerContracts []vrftesthelpers.VRFConsumerContract, + consumerContractAddresses []common.Address, + coordinator v22.CoordinatorV2_X, + coordinatorAddress common.Address, + batchCoordinatorAddress common.Address, + vrfVersion vrfcommon.Version, + nativePayment bool, + addedDelay bool, + assertions ...func( + t *testing.T, + coordinator v22.CoordinatorV2_X, + rwfe v22.RandomWordsFulfilled), +) { + nConsumers := len(consumers) + vrfKey := cltest.MustGenerateRandomKey(t) + sendEth(t, ownerKey, uni.backend, vrfKey.Address, 10) + + // generate n BHS keys to make sure BHS job rotates sending keys + var bhsKeys []ethkey.KeyV2 + var bhsKeyAddresses []common.Address + var bhsKeyAddressesStrings []string + var keySpecificOverrides []toml.KeySpecific + var keys []interface{} + gasLanePriceWei := assets.GWei(10) + for i := 0; i < nConsumers; i++ { + bhsKey := cltest.MustGenerateRandomKey(t) + bhsKeys = append(bhsKeys, bhsKey) + bhsKeyAddressesStrings = append(bhsKeyAddressesStrings, bhsKey.Address.String()) + bhsKeyAddresses = append(bhsKeyAddresses, bhsKey.Address) + keys = append(keys, bhsKey) + keySpecificOverrides = append(keySpecificOverrides, toml.KeySpecific{ + Key: ptr(bhsKey.EIP55Address), + GasEstimator: toml.KeySpecificGasEstimator{PriceMax: gasLanePriceWei}, + }) + sendEth(t, ownerKey, uni.backend, bhsKey.Address, 10) + } + keySpecificOverrides = append(keySpecificOverrides, toml.KeySpecific{ + // Gas lane. + Key: ptr(vrfKey.EIP55Address), + GasEstimator: toml.KeySpecificGasEstimator{PriceMax: gasLanePriceWei}, + }) + + // Whitelist vrf key for trusted BHS. + _, err := uni.trustedBhsContract.SetWhitelist(uni.neil, bhsKeyAddresses) + require.NoError(t, err) + uni.backend.Commit() + + config, db := heavyweight.FullTestDBV2(t, "vrfv2_needs_trusted_blockhash_store", func(c *chainlink.Config, s *chainlink.Secrets) { + simulatedOverrides(t, assets.GWei(10), keySpecificOverrides...)(c, s) + c.EVM[0].MinIncomingConfirmations = ptr[uint32](2) + c.Feature.LogPoller = ptr(true) + c.EVM[0].FinalityDepth = ptr[uint32](2) + c.EVM[0].LogPollInterval = models.MustNewDuration(time.Second) + }) + keys = append(keys, ownerKey, vrfKey) + app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, config, uni.backend, keys...) + require.NoError(t, app.Start(testutils.Context(t))) + + // Create VRF job. + vrfJobs := createVRFJobs( + t, + [][]ethkey.KeyV2{{vrfKey}}, + app, + coordinator, + coordinatorAddress, + batchCoordinatorAddress, + uni.coordinatorV2UniverseCommon, + nil, + vrfVersion, + false, + gasLanePriceWei) + keyHash := vrfJobs[0].VRFSpec.PublicKey.MustHash() + + var ( + v2CoordinatorAddress string + v2PlusCoordinatorAddress string + ) + + if vrfVersion == vrfcommon.V2 { + v2CoordinatorAddress = coordinatorAddress.String() + } else if vrfVersion == vrfcommon.V2Plus { + v2PlusCoordinatorAddress = coordinatorAddress.String() + } + + _ = vrftesthelpers.CreateAndStartBHSJob( + t, bhsKeyAddressesStrings, app, "", "", + v2CoordinatorAddress, v2PlusCoordinatorAddress, uni.trustedBhsContractAddress.String(), 20, 1000) + + // Ensure log poller is ready and has all logs. + require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) + require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), 1)) + + for i := 0; i < nConsumers; i++ { + consumer := consumers[i] + consumerContract := consumerContracts[i] + + // Create a subscription and fund with 0 LINK. + _, subID := subscribeVRF(t, consumer, consumerContract, coordinator, uni.backend, new(big.Int), nativePayment) + if vrfVersion == vrfcommon.V2 { + require.Equal(t, uint64(i+1), subID.Uint64()) + } + + // Make the randomness request. It will not yet succeed since it is underfunded. + numWords := uint32(20) + + requestID, requestBlock := requestRandomnessAndAssertRandomWordsRequestedEvent(t, consumerContract, consumer, keyHash, subID, numWords, 500_000, coordinator, uni.backend, nativePayment) + + // Wait 101 blocks. + for i := 0; i < 100; i++ { + uni.backend.Commit() + } + + // For an added delay, we even go beyond the EVM lookback limit. This is not a problem in a trusted BHS setup. + if addedDelay { + for i := 0; i < 300; i++ { + uni.backend.Commit() + } + } + + verifyBlockhashStoredTrusted(t, uni, requestBlock) + + // Wait another 160 blocks so that the request is outside of the 256 block window + for i := 0; i < 160; i++ { + uni.backend.Commit() + } + + // Fund the subscription + topUpSubscription(t, consumer, consumerContract, uni.backend, big.NewInt(5e18 /* 5 LINK */), nativePayment) + + // Wait for fulfillment to be queued. + gomega.NewGomegaWithT(t).Eventually(func() bool { + uni.backend.Commit() + runs, err := app.PipelineORM().GetAllRuns() + require.NoError(t, err) + t.Log("runs", len(runs)) + return len(runs) == 1 + }, testutils.WaitTimeout(t), time.Second).Should(gomega.BeTrue()) + + mine(t, requestID, subID, uni.backend, db, vrfVersion) + + rwfe := assertRandomWordsFulfilled(t, requestID, true, coordinator, nativePayment) + if len(assertions) > 0 { + assertions[0](t, coordinator, rwfe) + } + + // Assert correct number of random words sent by coordinator. + assertNumRandomWords(t, consumerContract, numWords) + } +} + func verifyBlockhashStored( t *testing.T, uni coordinatorV2UniverseCommon, @@ -324,6 +479,32 @@ func verifyBlockhashStored( }, testutils.WaitTimeout(t), time.Second).Should(gomega.BeTrue()) } +func verifyBlockhashStoredTrusted( + t *testing.T, + uni coordinatorV2PlusUniverse, + requestBlock uint64, +) { + // Wait for the blockhash to be stored + gomega.NewGomegaWithT(t).Eventually(func() bool { + uni.backend.Commit() + callOpts := &bind.CallOpts{ + Pending: false, + From: common.Address{}, + BlockNumber: nil, + Context: nil, + } + _, err := uni.trustedBhsContract.GetBlockhash(callOpts, big.NewInt(int64(requestBlock))) + if err == nil { + return true + } else if strings.Contains(err.Error(), "execution reverted") { + return false + } else { + t.Fatal(err) + return false + } + }, time.Second*300, time.Second).Should(gomega.BeTrue()) +} + func testSingleConsumerHappyPathBatchFulfillment( t *testing.T, ownerKey ethkey.KeyV2, diff --git a/core/services/vrf/v2/integration_v2_plus_test.go b/core/services/vrf/v2/integration_v2_plus_test.go index 6cd5900d01b..4e1cf62d01d 100644 --- a/core/services/vrf/v2/integration_v2_plus_test.go +++ b/core/services/vrf/v2/integration_v2_plus_test.go @@ -25,6 +25,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/blockhash_store" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_v3_aggregator_contract" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/trusted_blockhash_store" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_consumer_v2_plus_upgradeable_example" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_consumer_v2_upgradeable_example" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2_plus_v2_example" @@ -59,9 +60,11 @@ type coordinatorV2PlusUniverse struct { batchCoordinatorContractAddress common.Address migrationTestCoordinator *vrf_coordinator_v2_plus_v2_example.VRFCoordinatorV2PlusV2Example migrationTestCoordinatorAddress common.Address + trustedBhsContract *trusted_blockhash_store.TrustedBlockhashStore + trustedBhsContractAddress common.Address } -func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumers int) coordinatorV2PlusUniverse { +func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumers int, trusting bool) coordinatorV2PlusUniverse { testutils.SkipShort(t, "VRFCoordinatorV2Universe") oracleTransactor, err := bind.NewKeyedTransactorWithChainID(key.ToEcdsaPrivKey(), testutils.SimulatedChainID) require.NoError(t, err) @@ -119,14 +122,22 @@ func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumer bhsAddress, _, bhsContract, err := blockhash_store.DeployBlockhashStore(neil, backend) require.NoError(t, err, "failed to deploy BlockhashStore contract to simulated ethereum blockchain") + // Deploy trusted BHS + trustedBHSAddress, _, trustedBhsContract, err := trusted_blockhash_store.DeployTrustedBlockhashStore(neil, backend, []common.Address{}) + require.NoError(t, err, "failed to deploy trusted BlockhashStore contract to simulated ethereum blockchain") + // Deploy batch blockhash store batchBHSAddress, _, batchBHSContract, err := batch_blockhash_store.DeployBatchBlockhashStore(neil, backend, bhsAddress) require.NoError(t, err, "failed to deploy BatchBlockhashStore contract to simulated ethereum blockchain") // Deploy VRF V2plus coordinator + var bhsAddr = bhsAddress + if trusting { + bhsAddr = trustedBHSAddress + } coordinatorAddress, _, coordinatorContract, err := vrf_coordinator_v2plus.DeployVRFCoordinatorV2Plus( - neil, backend, bhsAddress) + neil, backend, bhsAddr) require.NoError(t, err, "failed to deploy VRFCoordinatorV2 contract to simulated ethereum blockchain") backend.Commit() @@ -287,13 +298,15 @@ func newVRFCoordinatorV2PlusUniverse(t *testing.T, key ethkey.KeyV2, numConsumer submanager: submanager, migrationTestCoordinator: migrationTestCoordinator, migrationTestCoordinatorAddress: migrationTestCoordinatorAddress, + trustedBhsContract: trustedBhsContract, + trustedBhsContractAddress: trustedBHSAddress, } } func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) t.Run("link payment", func(tt *testing.T) { testSingleConsumerHappyPathBatchFulfillment( t, @@ -346,7 +359,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment(t *testi func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment_BigGasCallback(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) t.Run("link payment", func(tt *testing.T) { testSingleConsumerHappyPathBatchFulfillment( t, @@ -399,7 +412,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath_BatchFulfillment_BigGasCa func TestVRFV2PlusIntegration_SingleConsumer_HappyPath(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) t.Run("link payment", func(tt *testing.T) { testSingleConsumerHappyPath( t, @@ -445,7 +458,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_HappyPath(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_EOA_Request(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) testEoa( t, ownerKey, @@ -460,7 +473,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_EOA_Request(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_EOA_Request_Batching_Enabled(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) testEoa( t, ownerKey, @@ -475,7 +488,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_EOA_Request_Batching_Enabled(t *tes func TestVRFV2PlusIntegration_SingleConsumer_EIP150_HappyPath(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) testSingleConsumerEIP150( t, ownerKey, @@ -490,7 +503,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_EIP150_HappyPath(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_EIP150_Revert(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) testSingleConsumerEIP150Revert( t, ownerKey, @@ -505,7 +518,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_EIP150_Revert(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_NeedsBlockhashStore(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 2) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 2, false) t.Run("link payment", func(tt *testing.T) { testMultipleConsumersNeedBHS( t, @@ -543,7 +556,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_NeedsBlockhashStore(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_BlockHeaderFeeder(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) t.Run("link payment", func(tt *testing.T) { testBlockHeaderFeeder( t, @@ -581,7 +594,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_BlockHeaderFeeder(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_NeedsTopUp(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) t.Run("link payment", func(tt *testing.T) { testSingleConsumerNeedsTopUp( t, @@ -622,7 +635,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_NeedsTopUp(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_BigGasCallback_Sandwich(t *testing.T) { ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) testSingleConsumerBigGasCallbackSandwich( t, ownerKey, @@ -636,7 +649,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_BigGasCallback_Sandwich(t *testing. func TestVRFV2PlusIntegration_SingleConsumer_MultipleGasLanes(t *testing.T) { ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) testSingleConsumerMultipleGasLanes( t, ownerKey, @@ -650,7 +663,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_MultipleGasLanes(t *testing.T) { func TestVRFV2PlusIntegration_SingleConsumer_AlwaysRevertingCallback_StillFulfilled(t *testing.T) { ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 0) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 0, false) testSingleConsumerAlwaysRevertingCallbackStillFulfilled( t, ownerKey, @@ -664,7 +677,7 @@ func TestVRFV2PlusIntegration_SingleConsumer_AlwaysRevertingCallback_StillFulfil func TestVRFV2PlusIntegration_ConsumerProxy_HappyPath(t *testing.T) { ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 0) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 0, false) testConsumerProxyHappyPath( t, ownerKey, @@ -678,7 +691,7 @@ func TestVRFV2PlusIntegration_ConsumerProxy_HappyPath(t *testing.T) { func TestVRFV2PlusIntegration_ConsumerProxy_CoordinatorZeroAddress(t *testing.T) { ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 0) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 0, false) testConsumerProxyCoordinatorZeroAddress(t, uni.coordinatorV2UniverseCommon) } @@ -805,7 +818,7 @@ func TestVRFV2PlusIntegration_SimpleConsumerExample(t *testing.T) { func TestVRFV2PlusIntegration_TestMaliciousConsumer(t *testing.T) { t.Parallel() key := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, key, 1, false) testMaliciousConsumer( t, key, @@ -818,7 +831,7 @@ func TestVRFV2PlusIntegration_TestMaliciousConsumer(t *testing.T) { func TestVRFV2PlusIntegration_RequestCost(t *testing.T) { key := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, key, 1, false) cfg := configtest.NewGeneralConfigSimulated(t, nil) app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, cfg, uni.backend, key) @@ -898,7 +911,7 @@ func TestVRFV2PlusIntegration_RequestCost(t *testing.T) { func TestVRFV2PlusIntegration_MaxConsumersCost(t *testing.T) { key := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, key, 1, false) carol := uni.vrfConsumers[0] carolContract := uni.consumerContracts[0] carolContractAddress := uni.consumerContractAddresses[0] @@ -978,7 +991,7 @@ func requestAndEstimateFulfillmentCost( func TestVRFV2PlusIntegration_FulfillmentCost(t *testing.T) { key := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, key, 1, false) cfg := configtest.NewGeneralConfigSimulated(t, nil) app := cltest.NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain(t, cfg, uni.backend, key) @@ -1131,7 +1144,7 @@ func setupSubscriptionAndFund( func TestVRFV2PlusIntegration_Migration(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 1, false) key1 := cltest.MustGenerateRandomKey(t) gasLanePriceWei := assets.GWei(10) config, db := heavyweight.FullTestDBV2(t, "vrfv2plus_migration", func(c *chainlink.Config, s *chainlink.Secrets) { @@ -1301,7 +1314,7 @@ func requestRandomnessAndValidate(t *testing.T, func TestVRFV2PlusIntegration_CancelSubscription(t *testing.T) { key := cltest.MustGenerateRandomKey(t) - uni := newVRFCoordinatorV2PlusUniverse(t, key, 1) + uni := newVRFCoordinatorV2PlusUniverse(t, key, 1, false) consumer := uni.vrfConsumers[0] consumerContract := uni.consumerContracts[0] consumerContractAddress := uni.consumerContractAddresses[0] diff --git a/core/services/vrf/v2/integration_v2_test.go b/core/services/vrf/v2/integration_v2_test.go index f0747baf800..24edf0ffff8 100644 --- a/core/services/vrf/v2/integration_v2_test.go +++ b/core/services/vrf/v2/integration_v2_test.go @@ -1297,6 +1297,46 @@ func TestVRFV2Integration_SingleConsumer_NeedsBlockhashStore(t *testing.T) { ) } +func TestVRFV2Integration_SingleConsumer_NeedsTrustedBlockhashStore(t *testing.T) { + t.Parallel() + ownerKey := cltest.MustGenerateRandomKey(t) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 2, true) + testMultipleConsumersNeedTrustedBHS( + t, + ownerKey, + uni, + uni.vrfConsumers, + uni.consumerContracts, + uni.consumerContractAddresses, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + vrfcommon.V2Plus, + false, + false, + ) +} + +func TestVRFV2Integration_SingleConsumer_NeedsTrustedBlockhashStore_AfterDelay(t *testing.T) { + t.Parallel() + ownerKey := cltest.MustGenerateRandomKey(t) + uni := newVRFCoordinatorV2PlusUniverse(t, ownerKey, 2, true) + testMultipleConsumersNeedTrustedBHS( + t, + ownerKey, + uni, + uni.vrfConsumers, + uni.consumerContracts, + uni.consumerContractAddresses, + uni.rootContract, + uni.rootContractAddress, + uni.batchCoordinatorContractAddress, + vrfcommon.V2Plus, + false, + true, + ) +} + func TestVRFV2Integration_SingleConsumer_BlockHeaderFeeder(t *testing.T) { t.Parallel() ownerKey := cltest.MustGenerateRandomKey(t) diff --git a/core/services/vrf/vrftesthelpers/helpers.go b/core/services/vrf/vrftesthelpers/helpers.go index 883fdd7403c..d40e2bc747f 100644 --- a/core/services/vrf/vrftesthelpers/helpers.go +++ b/core/services/vrf/vrftesthelpers/helpers.go @@ -50,21 +50,24 @@ func CreateAndStartBHSJob( fromAddresses []string, app *cltest.TestApplication, bhsAddress, coordinatorV1Address, coordinatorV2Address, coordinatorV2PlusAddress string, + trustedBlockhashStoreAddress string, trustedBlockhashStoreBatchSize int32, lookback int, ) job.Job { jid := uuid.New() s := testspecs.GenerateBlockhashStoreSpec(testspecs.BlockhashStoreSpecParams{ - JobID: jid.String(), - Name: "blockhash-store", - CoordinatorV1Address: coordinatorV1Address, - CoordinatorV2Address: coordinatorV2Address, - CoordinatorV2PlusAddress: coordinatorV2PlusAddress, - WaitBlocks: 100, - LookbackBlocks: 200, - BlockhashStoreAddress: bhsAddress, - PollPeriod: time.Second, - RunTimeout: 100 * time.Millisecond, - EVMChainID: 1337, - FromAddresses: fromAddresses, + JobID: jid.String(), + Name: "blockhash-store", + CoordinatorV1Address: coordinatorV1Address, + CoordinatorV2Address: coordinatorV2Address, + CoordinatorV2PlusAddress: coordinatorV2PlusAddress, + WaitBlocks: 100, + LookbackBlocks: lookback, + BlockhashStoreAddress: bhsAddress, + TrustedBlockhashStoreAddress: trustedBlockhashStoreAddress, + TrustedBlockhashStoreBatchSize: trustedBlockhashStoreBatchSize, + PollPeriod: time.Second, + RunTimeout: 100 * time.Millisecond, + EVMChainID: 1337, + FromAddresses: fromAddresses, }) jb, err := blockhashstore.ValidatedSpec(s.Toml()) require.NoError(t, err) diff --git a/core/store/migrate/migrations/0187_trusted_bhs_vrfv2plus.sql b/core/store/migrate/migrations/0187_trusted_bhs_vrfv2plus.sql new file mode 100644 index 00000000000..288e5e00a85 --- /dev/null +++ b/core/store/migrate/migrations/0187_trusted_bhs_vrfv2plus.sql @@ -0,0 +1,10 @@ +-- +goose Up +ALTER TABLE blockhash_store_specs + ADD COLUMN IF NOT EXISTS "trusted_blockhash_store_address" bytea + CHECK (octet_length(trusted_blockhash_store_address) = 20); + +ALTER TABLE blockhash_store_specs + ADD COLUMN IF NOT EXISTS "trusted_blockhash_store_batch_size" integer DEFAULT 0; +-- +goose Down +ALTER TABLE blockhash_store_specs DROP COLUMN "trusted_blockhash_store_address"; +ALTER TABLE blockhash_store_specs DROP COLUMN "trusted_blockhash_store_batch_size"; \ No newline at end of file diff --git a/core/testdata/testspecs/v2_specs.go b/core/testdata/testspecs/v2_specs.go index 923afa5a740..4c44f3b9c5e 100644 --- a/core/testdata/testspecs/v2_specs.go +++ b/core/testdata/testspecs/v2_specs.go @@ -11,6 +11,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/services/vrf/vrfcommon" "github.com/smartcontractkit/chainlink/v2/core/services/webhook" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) var ( @@ -585,18 +586,20 @@ ds -> ds_parse -> ds_multiply; // BlockhashStoreSpecParams defines params for building a blockhash store job spec. type BlockhashStoreSpecParams struct { - JobID string - Name string - CoordinatorV1Address string - CoordinatorV2Address string - CoordinatorV2PlusAddress string - WaitBlocks int - LookbackBlocks int - BlockhashStoreAddress string - PollPeriod time.Duration - RunTimeout time.Duration - EVMChainID int64 - FromAddresses []string + JobID string + Name string + CoordinatorV1Address string + CoordinatorV2Address string + CoordinatorV2PlusAddress string + WaitBlocks int + LookbackBlocks int + BlockhashStoreAddress string + TrustedBlockhashStoreAddress string + TrustedBlockhashStoreBatchSize int32 + PollPeriod time.Duration + RunTimeout time.Duration + EVMChainID int64 + FromAddresses []string } // BlockhashStoreSpec defines a blockhash store job spec. @@ -632,6 +635,14 @@ func GenerateBlockhashStoreSpec(params BlockhashStoreSpecParams) BlockhashStoreS params.CoordinatorV2PlusAddress = "0x92B5e28Ac583812874e4271380c7d070C5FB6E6b" } + if params.TrustedBlockhashStoreAddress == "" { + params.TrustedBlockhashStoreAddress = utils.ZeroAddress.Hex() + } + + if params.TrustedBlockhashStoreBatchSize == 0 { + params.TrustedBlockhashStoreBatchSize = 20 + } + if params.WaitBlocks == 0 { params.WaitBlocks = 100 } @@ -673,6 +684,8 @@ coordinatorV2PlusAddress = "%s" waitBlocks = %d lookbackBlocks = %d blockhashStoreAddress = "%s" +trustedBlockhashStoreAddress = "%s" +trustedBlockhashStoreBatchSize = %d pollPeriod = "%s" runTimeout = "%s" evmChainID = "%d" @@ -680,7 +693,7 @@ fromAddresses = %s ` toml := fmt.Sprintf(template, params.Name, params.CoordinatorV1Address, params.CoordinatorV2Address, params.CoordinatorV2PlusAddress, params.WaitBlocks, params.LookbackBlocks, - params.BlockhashStoreAddress, params.PollPeriod.String(), params.RunTimeout.String(), + params.BlockhashStoreAddress, params.TrustedBlockhashStoreAddress, params.TrustedBlockhashStoreBatchSize, params.PollPeriod.String(), params.RunTimeout.String(), params.EVMChainID, formattedFromAddresses) return BlockhashStoreSpec{BlockhashStoreSpecParams: params, toml: toml} diff --git a/core/web/presenters/job.go b/core/web/presenters/job.go index 571a6509680..01e01c9fa1e 100644 --- a/core/web/presenters/job.go +++ b/core/web/presenters/job.go @@ -325,33 +325,37 @@ func NewVRFSpec(spec *job.VRFSpec) *VRFSpec { // BlockhashStoreSpec defines the job parameters for a blockhash store feeder job. type BlockhashStoreSpec struct { - CoordinatorV1Address *ethkey.EIP55Address `json:"coordinatorV1Address"` - CoordinatorV2Address *ethkey.EIP55Address `json:"coordinatorV2Address"` - CoordinatorV2PlusAddress *ethkey.EIP55Address `json:"coordinatorV2PlusAddress"` - WaitBlocks int32 `json:"waitBlocks"` - LookbackBlocks int32 `json:"lookbackBlocks"` - BlockhashStoreAddress ethkey.EIP55Address `json:"blockhashStoreAddress"` - PollPeriod time.Duration `json:"pollPeriod"` - RunTimeout time.Duration `json:"runTimeout"` - EVMChainID *utils.Big `json:"evmChainID"` - FromAddresses []ethkey.EIP55Address `json:"fromAddresses"` - CreatedAt time.Time `json:"createdAt"` - UpdatedAt time.Time `json:"updatedAt"` + CoordinatorV1Address *ethkey.EIP55Address `json:"coordinatorV1Address"` + CoordinatorV2Address *ethkey.EIP55Address `json:"coordinatorV2Address"` + CoordinatorV2PlusAddress *ethkey.EIP55Address `json:"coordinatorV2PlusAddress"` + WaitBlocks int32 `json:"waitBlocks"` + LookbackBlocks int32 `json:"lookbackBlocks"` + BlockhashStoreAddress ethkey.EIP55Address `json:"blockhashStoreAddress"` + TrustedBlockhashStoreAddress *ethkey.EIP55Address `json:"trustedBlockhashStoreAddress"` + TrustedBlockhashStoreBatchSize int32 `json:"trustedBlockhashStoreBatchSize"` + PollPeriod time.Duration `json:"pollPeriod"` + RunTimeout time.Duration `json:"runTimeout"` + EVMChainID *utils.Big `json:"evmChainID"` + FromAddresses []ethkey.EIP55Address `json:"fromAddresses"` + CreatedAt time.Time `json:"createdAt"` + UpdatedAt time.Time `json:"updatedAt"` } // NewBlockhashStoreSpec creates a new BlockhashStoreSpec for the given parameters. func NewBlockhashStoreSpec(spec *job.BlockhashStoreSpec) *BlockhashStoreSpec { return &BlockhashStoreSpec{ - CoordinatorV1Address: spec.CoordinatorV1Address, - CoordinatorV2Address: spec.CoordinatorV2Address, - CoordinatorV2PlusAddress: spec.CoordinatorV2PlusAddress, - WaitBlocks: spec.WaitBlocks, - LookbackBlocks: spec.LookbackBlocks, - BlockhashStoreAddress: spec.BlockhashStoreAddress, - PollPeriod: spec.PollPeriod, - RunTimeout: spec.RunTimeout, - EVMChainID: spec.EVMChainID, - FromAddresses: spec.FromAddresses, + CoordinatorV1Address: spec.CoordinatorV1Address, + CoordinatorV2Address: spec.CoordinatorV2Address, + CoordinatorV2PlusAddress: spec.CoordinatorV2PlusAddress, + WaitBlocks: spec.WaitBlocks, + LookbackBlocks: spec.LookbackBlocks, + BlockhashStoreAddress: spec.BlockhashStoreAddress, + TrustedBlockhashStoreAddress: spec.TrustedBlockhashStoreAddress, + TrustedBlockhashStoreBatchSize: spec.TrustedBlockhashStoreBatchSize, + PollPeriod: spec.PollPeriod, + RunTimeout: spec.RunTimeout, + EVMChainID: spec.EVMChainID, + FromAddresses: spec.FromAddresses, } } diff --git a/core/web/presenters/job_test.go b/core/web/presenters/job_test.go index 3e8f4176a17..a069a3e1ba5 100644 --- a/core/web/presenters/job_test.go +++ b/core/web/presenters/job_test.go @@ -53,6 +53,10 @@ func TestJob(t *testing.T) { batchBHSAddress, err := ethkey.NewEIP55Address("0xF6bB415b033D19EFf24A872a4785c6e1C4426103") require.NoError(t, err) + trustedBlockhashStoreAddress, err := ethkey.NewEIP55Address("0x0ad9FE7a58216242a8475ca92F222b0640E26B63") + require.NoError(t, err) + trustedBlockhashStoreBatchSize := int32(20) + var specGasLimit uint32 = 1000 testCases := []struct { @@ -472,17 +476,19 @@ func TestJob(t *testing.T) { job: job.Job{ ID: 1, BlockhashStoreSpec: &job.BlockhashStoreSpec{ - ID: 1, - CoordinatorV1Address: &v1CoordAddress, - CoordinatorV2Address: &v2CoordAddress, - CoordinatorV2PlusAddress: &v2PlusCoordAddress, - WaitBlocks: 123, - LookbackBlocks: 223, - BlockhashStoreAddress: contractAddress, - PollPeriod: 25 * time.Second, - RunTimeout: 10 * time.Second, - EVMChainID: utils.NewBigI(4), - FromAddresses: []ethkey.EIP55Address{fromAddress}, + ID: 1, + CoordinatorV1Address: &v1CoordAddress, + CoordinatorV2Address: &v2CoordAddress, + CoordinatorV2PlusAddress: &v2PlusCoordAddress, + WaitBlocks: 123, + LookbackBlocks: 223, + BlockhashStoreAddress: contractAddress, + PollPeriod: 25 * time.Second, + RunTimeout: 10 * time.Second, + EVMChainID: utils.NewBigI(4), + FromAddresses: []ethkey.EIP55Address{fromAddress}, + TrustedBlockhashStoreAddress: &trustedBlockhashStoreAddress, + TrustedBlockhashStoreBatchSize: trustedBlockhashStoreBatchSize, }, PipelineSpec: &pipeline.Spec{ ID: 1, @@ -521,6 +527,8 @@ func TestJob(t *testing.T) { "waitBlocks": 123, "lookbackBlocks": 223, "blockhashStoreAddress": "0x9E40733cC9df84636505f4e6Db28DCa0dC5D1bba", + "trustedBlockhashStoreAddress": "0x0ad9FE7a58216242a8475ca92F222b0640E26B63", + "trustedBlockhashStoreBatchSize": 20, "pollPeriod": 25000000000, "runTimeout": 10000000000, "evmChainID": "4", diff --git a/core/web/resolver/spec.go b/core/web/resolver/spec.go index abcb468e1a7..fa3e5a14fa0 100644 --- a/core/web/resolver/spec.go +++ b/core/web/resolver/spec.go @@ -799,6 +799,20 @@ func (b *BlockhashStoreSpecResolver) BlockhashStoreAddress() string { return b.spec.BlockhashStoreAddress.String() } +// TrustedBlockhashStoreAddress returns the address of the job's TrustedBlockhashStoreAddress, if any. +func (b *BlockhashStoreSpecResolver) TrustedBlockhashStoreAddress() *string { + if b.spec.TrustedBlockhashStoreAddress == nil { + return nil + } + addr := b.spec.TrustedBlockhashStoreAddress.String() + return &addr +} + +// BatchBlockhashStoreAddress returns the job's BatchBlockhashStoreAddress param. +func (b *BlockhashStoreSpecResolver) TrustedBlockhashStoreBatchSize() int32 { + return b.spec.TrustedBlockhashStoreBatchSize +} + // PollPeriod return's the job's PollPeriod param. func (b *BlockhashStoreSpecResolver) PollPeriod() string { return b.spec.PollPeriod.String() diff --git a/core/web/resolver/spec_test.go b/core/web/resolver/spec_test.go index f3686774f13..8c6dadc880e 100644 --- a/core/web/resolver/spec_test.go +++ b/core/web/resolver/spec_test.go @@ -755,6 +755,10 @@ func TestResolver_BlockhashStoreSpec(t *testing.T) { blockhashStoreAddress, err := ethkey.NewEIP55Address("0xb26A6829D454336818477B946f03Fb21c9706f3A") require.NoError(t, err) + trustedBlockhashStoreAddress, err := ethkey.NewEIP55Address("0x0ad9FE7a58216242a8475ca92F222b0640E26B63") + require.NoError(t, err) + trustedBlockhashStoreBatchSize := int32(20) + testCases := []GQLTestCase{ { name: "blockhash store spec", @@ -764,17 +768,19 @@ func TestResolver_BlockhashStoreSpec(t *testing.T) { f.Mocks.jobORM.On("FindJobWithoutSpecErrors", id).Return(job.Job{ Type: job.BlockhashStore, BlockhashStoreSpec: &job.BlockhashStoreSpec{ - CoordinatorV1Address: &coordinatorV1Address, - CoordinatorV2Address: &coordinatorV2Address, - CoordinatorV2PlusAddress: &coordinatorV2PlusAddress, - CreatedAt: f.Timestamp(), - EVMChainID: utils.NewBigI(42), - FromAddresses: []ethkey.EIP55Address{fromAddress1, fromAddress2}, - PollPeriod: 1 * time.Minute, - RunTimeout: 37 * time.Second, - WaitBlocks: 100, - LookbackBlocks: 200, - BlockhashStoreAddress: blockhashStoreAddress, + CoordinatorV1Address: &coordinatorV1Address, + CoordinatorV2Address: &coordinatorV2Address, + CoordinatorV2PlusAddress: &coordinatorV2PlusAddress, + CreatedAt: f.Timestamp(), + EVMChainID: utils.NewBigI(42), + FromAddresses: []ethkey.EIP55Address{fromAddress1, fromAddress2}, + PollPeriod: 1 * time.Minute, + RunTimeout: 37 * time.Second, + WaitBlocks: 100, + LookbackBlocks: 200, + BlockhashStoreAddress: blockhashStoreAddress, + TrustedBlockhashStoreAddress: &trustedBlockhashStoreAddress, + TrustedBlockhashStoreBatchSize: trustedBlockhashStoreBatchSize, }, }, nil) }, @@ -796,6 +802,8 @@ func TestResolver_BlockhashStoreSpec(t *testing.T) { waitBlocks lookbackBlocks blockhashStoreAddress + trustedBlockhashStoreAddress + trustedBlockhashStoreBatchSize } } } @@ -817,7 +825,9 @@ func TestResolver_BlockhashStoreSpec(t *testing.T) { "runTimeout": "37s", "waitBlocks": 100, "lookbackBlocks": 200, - "blockhashStoreAddress": "0xb26A6829D454336818477B946f03Fb21c9706f3A" + "blockhashStoreAddress": "0xb26A6829D454336818477B946f03Fb21c9706f3A", + "trustedBlockhashStoreAddress": "0x0ad9FE7a58216242a8475ca92F222b0640E26B63", + "trustedBlockhashStoreBatchSize": 20 } } } diff --git a/core/web/schema/type/spec.graphql b/core/web/schema/type/spec.graphql index 636c9d0fc2c..c92a1dd1ea9 100644 --- a/core/web/schema/type/spec.graphql +++ b/core/web/schema/type/spec.graphql @@ -126,6 +126,8 @@ type BlockhashStoreSpec { waitBlocks: Int! lookbackBlocks: Int! blockhashStoreAddress: String! + trustedBlockhashStoreAddress: String + trustedBlockhashStoreBatchSize: Int! pollPeriod: String! runTimeout: String! evmChainID: String From b70a4826da928a618b201b758ff938d3503b6ffa Mon Sep 17 00:00:00 2001 From: Tate Date: Thu, 10 Aug 2023 10:22:17 -0600 Subject: [PATCH 135/270] [TT-519] Test Matrix Cache Issue Fix (#10148) * [TT-519] Test Matrix Cache Issue Fix * Use a contains in the matrix check --- .github/actions/setup-go/action.yml | 7 +++++++ .github/workflows/ci-core.yml | 2 ++ .github/workflows/integration-tests.yml | 15 +++++++++------ 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/.github/actions/setup-go/action.yml b/.github/actions/setup-go/action.yml index 996fb4ac507..3695c72abc5 100644 --- a/.github/actions/setup-go/action.yml +++ b/.github/actions/setup-go/action.yml @@ -4,6 +4,12 @@ inputs: only-modules: description: Set to 'true' to only cache modules default: 'false' + cache-go-modules: + description: | + Option to cache go modules + In matrix jobs the caching will fail in all but the first one to complete and + in doing so it will waste time in the pipeline + default: 'true' cache-version: description: Set this to cache bust default: "1" @@ -30,6 +36,7 @@ runs: echo "gobuildcache=$(go env GOCACHE)" >> $GITHUB_OUTPUT - uses: actions/cache@v3 + if: ${{ inputs.cache-go-modules == 'true' }} name: Cache Go Modules with: path: | diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 7f20f62390e..d3ef925a604 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -153,6 +153,8 @@ jobs: prod: "true" - name: Setup Go uses: ./.github/actions/setup-go + with: + cache-go-modules: ${{ contains(matrix.split.id, '1/') }} - name: Setup Solana uses: ./.github/actions/setup-solana - name: Setup wasmd diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 9f9cd33b272..9482b2ad956 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -191,14 +191,16 @@ jobs: nodes: 1 os: ubuntu-latest pyroscope_env: ci-smoke-vrf-evm-simulated + cache: 'true' - name: vrfv2 nodes: 1 os: ubuntu-latest pyroscope_env: ci-smoke-vrf2-evm-simulated - - name: ocr2vrf - nodes: 2 - os: ubuntu-latest - pyroscope_env: ci-smoke-ocr2vrf-evm-simulated + # temporarily disabled + # - name: ocr2vrf + # nodes: 2 + # os: ubuntu-latest + # pyroscope_env: ci-smoke-ocr2vrf-evm-simulated runs-on: ${{ matrix.product.os }} name: ETH Smoke Tests ${{ matrix.product.name }} steps: @@ -209,7 +211,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.3 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.6 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -225,6 +227,7 @@ jobs: publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod + cache_go_vendors: ${{ matrix.product.cache }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -232,7 +235,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.6 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod From 10f3984c96efa21add69835b72f63ebb7fa200d9 Mon Sep 17 00:00:00 2001 From: Mohamed Mehany <7327188+mohamed-mehany@users.noreply.github.com> Date: Thu, 10 Aug 2023 19:51:52 +0200 Subject: [PATCH 136/270] Adds Scroll mainnet and Sepolia testnet support (#10107) * Adds Scroll mainnet and Sepolia tesnet support * Add CallMsg Data * Typo fix * Adds Scroll mainnet and Sepolia tesnet support * Add on demand soak option * Upgrade CTF version to include Scroll changes --------- Co-authored-by: davidcauchi --- .github/workflows/on-demand-ocr-soak-test.yml | 2 + .../config/toml/defaults/Scroll_Mainnet.toml | 21 +++ .../config/toml/defaults/Scroll_Sepolia.toml | 21 +++ docs/CONFIG.md | 154 ++++++++++++++++++ integration-tests/actions/actions.go | 8 +- .../contracts/contract_deployer.go | 6 + integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- integration-tests/networks/known_networks.go | 24 +++ 9 files changed, 238 insertions(+), 4 deletions(-) create mode 100644 core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml create mode 100644 core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 5d5c2017c31..b94e36179f7 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -16,6 +16,8 @@ on: - "BASE_MAINNET" - "BSC_MAINNET" - "BSC_TESTNET" + - "SCROLL_SEPOLIA" + - "SCROLL_MAINNET" fundingPrivateKey: description: Private funding key (Skip for Simulated) required: false diff --git a/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml b/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml new file mode 100644 index 00000000000..63c08559016 --- /dev/null +++ b/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml @@ -0,0 +1,21 @@ +ChainID = '534352' +FinalityDepth = 1 +LogPollInterval = '3s' +MinIncomingConfirmations = 1 +# Scroll only emits blocks when a new tx is received, so this method of liveness detection is not useful +NoNewHeadsThreshold = '0' +OCR.ContractConfirmations = 1 + +[GasEstimator] +Mode = 'L2Suggested' +# Scroll uses the L2Suggested estimator; we don't want to place any limits on the minimum gas price +PriceMin = '0' +# Never bump gas on Scroll +BumpThreshold = 0 + +[GasEstimator.BlockHistory] +# Force an error if someone enables the estimator by accident; we never want to run the block history estimator on Scroll +BlockHistorySize = 0 + +[HeadTracker] +HistoryDepth = 50 diff --git a/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml b/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml new file mode 100644 index 00000000000..5a1a0f9ba7d --- /dev/null +++ b/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml @@ -0,0 +1,21 @@ +ChainID = '534351' +FinalityDepth = 1 +LogPollInterval = '3s' +MinIncomingConfirmations = 1 +# Scroll only emits blocks when a new tx is received, so this method of liveness detection is not useful +NoNewHeadsThreshold = '0' +OCR.ContractConfirmations = 1 + +[GasEstimator] +Mode = 'L2Suggested' +# Scroll uses the L2Suggested estimator; we don't want to place any limits on the minimum gas price +PriceMin = '0' +# Never bump gas on Scroll +BumpThreshold = 0 + +[GasEstimator.BlockHistory] +# Force an error if someone enables the estimator by accident; we never want to run the block history estimator on Scroll +BlockHistorySize = 0 + +[HeadTracker] +HistoryDepth = 50 diff --git a/docs/CONFIG.md b/docs/CONFIG.md index 703c383568c..ab19672e668 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -4009,6 +4009,160 @@ GasLimit = 5300000

+
Scroll Sepolia (534351)

+ +```toml +AutoCreateKey = true +BlockBackfillDepth = 10 +BlockBackfillSkip = false +FinalityDepth = 1 +FinalityTagEnabled = false +LogBackfillBatchSize = 1000 +LogPollInterval = '3s' +LogKeepBlocksDepth = 100000 +MinIncomingConfirmations = 1 +MinContractPayment = '0.00001 link' +NonceAutoSync = true +NoNewHeadsThreshold = '0s' +RPCDefaultBatchSize = 250 +RPCBlockQueryDelay = 1 + +[Transactions] +ForwardersEnabled = false +MaxInFlight = 16 +MaxQueued = 250 +ReaperInterval = '1h0m0s' +ReaperThreshold = '168h0m0s' +ResendAfterThreshold = '1m0s' + +[BalanceMonitor] +Enabled = true + +[GasEstimator] +Mode = 'L2Suggested' +PriceDefault = '20 gwei' +PriceMax = '115792089237316195423570985008687907853269984665.640564039457584007913129639935 tether' +PriceMin = '0' +LimitDefault = 500000 +LimitMax = 500000 +LimitMultiplier = '1' +LimitTransfer = 21000 +BumpMin = '5 gwei' +BumpPercent = 20 +BumpThreshold = 0 +EIP1559DynamicFees = false +FeeCapDefault = '100 gwei' +TipCapDefault = '1 wei' +TipCapMin = '1 wei' + +[GasEstimator.BlockHistory] +BatchSize = 25 +BlockHistorySize = 0 +CheckInclusionBlocks = 12 +CheckInclusionPercentile = 90 +TransactionPercentile = 60 + +[HeadTracker] +HistoryDepth = 50 +MaxBufferSize = 3 +SamplingInterval = '1s' + +[NodePool] +PollFailureThreshold = 5 +PollInterval = '10s' +SelectionMode = 'HighestHead' +SyncThreshold = 5 + +[OCR] +ContractConfirmations = 1 +ContractTransmitterTransmitTimeout = '10s' +DatabaseTimeout = '10s' +ObservationGracePeriod = '1s' + +[OCR2] +[OCR2.Automation] +GasLimit = 5300000 +``` + +

+ +
Scroll Mainnet (534352)

+ +```toml +AutoCreateKey = true +BlockBackfillDepth = 10 +BlockBackfillSkip = false +FinalityDepth = 1 +FinalityTagEnabled = false +LogBackfillBatchSize = 1000 +LogPollInterval = '3s' +LogKeepBlocksDepth = 100000 +MinIncomingConfirmations = 1 +MinContractPayment = '0.00001 link' +NonceAutoSync = true +NoNewHeadsThreshold = '0s' +RPCDefaultBatchSize = 250 +RPCBlockQueryDelay = 1 + +[Transactions] +ForwardersEnabled = false +MaxInFlight = 16 +MaxQueued = 250 +ReaperInterval = '1h0m0s' +ReaperThreshold = '168h0m0s' +ResendAfterThreshold = '1m0s' + +[BalanceMonitor] +Enabled = true + +[GasEstimator] +Mode = 'L2Suggested' +PriceDefault = '20 gwei' +PriceMax = '115792089237316195423570985008687907853269984665.640564039457584007913129639935 tether' +PriceMin = '0' +LimitDefault = 500000 +LimitMax = 500000 +LimitMultiplier = '1' +LimitTransfer = 21000 +BumpMin = '5 gwei' +BumpPercent = 20 +BumpThreshold = 0 +EIP1559DynamicFees = false +FeeCapDefault = '100 gwei' +TipCapDefault = '1 wei' +TipCapMin = '1 wei' + +[GasEstimator.BlockHistory] +BatchSize = 25 +BlockHistorySize = 0 +CheckInclusionBlocks = 12 +CheckInclusionPercentile = 90 +TransactionPercentile = 60 + +[HeadTracker] +HistoryDepth = 50 +MaxBufferSize = 3 +SamplingInterval = '1s' + +[NodePool] +PollFailureThreshold = 5 +PollInterval = '10s' +SelectionMode = 'HighestHead' +SyncThreshold = 5 + +[OCR] +ContractConfirmations = 1 +ContractTransmitterTransmitTimeout = '10s' +DatabaseTimeout = '10s' +ObservationGracePeriod = '1s' + +[OCR2] +[OCR2.Automation] +GasLimit = 5300000 +``` + +

+
Ethereum Sepolia (11155111)

```toml diff --git a/integration-tests/actions/actions.go b/integration-tests/actions/actions.go index 0565de64c97..00d4317e85d 100644 --- a/integration-tests/actions/actions.go +++ b/integration-tests/actions/actions.go @@ -41,7 +41,13 @@ func FundChainlinkNodes( if err != nil { return err } - gasEstimates, err := client.EstimateGas(ethereum.CallMsg{}) + recipient := common.HexToAddress(toAddress) + msg := ethereum.CallMsg{ + From: common.HexToAddress(client.GetDefaultWallet().Address()), + To: &recipient, + Value: utils.EtherToWei(amount), + } + gasEstimates, err := client.EstimateGas(msg) if err != nil { return err } diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 70ab55eff9e..d6892791e56 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -116,6 +116,8 @@ func NewContractDeployer(bcClient blockchain.EVMClient) (ContractDeployer, error return &QuorumContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil case *blockchain.BSCClient: return &BSCContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil + case *blockchain.ScrollClient: + return &ScrollContractDeployer{NewEthereumContractDeployer(clientImpl)}, nil } return nil, errors.New("unknown blockchain client implementation for contract deployer, register blockchain client in NewContractDeployer") } @@ -166,6 +168,10 @@ type BSCContractDeployer struct { *EthereumContractDeployer } +type ScrollContractDeployer struct { + *EthereumContractDeployer +} + // NewEthereumContractDeployer returns an instantiated instance of the ETH contract deployer func NewEthereumContractDeployer(ethClient blockchain.EVMClient) *EthereumContractDeployer { return &EthereumContractDeployer{ diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 80412691461..37edc3d2fc6 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -20,7 +20,7 @@ require ( github.com/rs/zerolog v1.29.1 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-env v0.36.0 - github.com/smartcontractkit/chainlink-testing-framework v1.15.1 + github.com/smartcontractkit/chainlink-testing-framework v1.15.2 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 github.com/smartcontractkit/ocr2keepers v0.7.7 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 5a507c3b413..f70fd26b2c7 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2251,8 +2251,8 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= -github.com/smartcontractkit/chainlink-testing-framework v1.15.1 h1:/i+JuVgStYoiKaLXisgRd96gyMd8NVwwYe/G+Tzy3+8= -github.com/smartcontractkit/chainlink-testing-framework v1.15.1/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= +github.com/smartcontractkit/chainlink-testing-framework v1.15.2 h1:WhZvHHz104RKC9u5u+zHeP4YwyyFVG3bW0DVRSe4FnE= +github.com/smartcontractkit/chainlink-testing-framework v1.15.2/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= diff --git a/integration-tests/networks/known_networks.go b/integration-tests/networks/known_networks.go index b24a2583039..da8675caa6a 100644 --- a/integration-tests/networks/known_networks.go +++ b/integration-tests/networks/known_networks.go @@ -345,6 +345,28 @@ var ( GasEstimationBuffer: 1000, } + ScrollSepolia = blockchain.EVMNetwork{ + Name: "Scroll Sepolia", + ClientImplementation: blockchain.ScrollClientImplementation, + ChainID: 534351, + Simulated: false, + ChainlinkTransactionLimit: 5000, + Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, + MinimumConfirmations: 1, + GasEstimationBuffer: 0, + } + + ScrollMainnet = blockchain.EVMNetwork{ + Name: "Scroll Mainnet", + ClientImplementation: blockchain.ScrollClientImplementation, + ChainID: 534352, + Simulated: false, + ChainlinkTransactionLimit: 5000, + Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, + MinimumConfirmations: 1, + GasEstimationBuffer: 0, + } + CeloMainnet = blockchain.EVMNetwork{ Name: "Celo", ClientImplementation: blockchain.CeloClientImplementation, @@ -418,6 +440,8 @@ var ( "AVALANCHE_FUJI": AvalancheFuji, "AVALANCHE_MAINNET": AvalancheMainnet, "QUORUM": Quorum, + "SCROLL_SEPOLIA": ScrollSepolia, + "SCROLL_MAINNET": ScrollMainnet, "BASE_MAINNET": BaseMainnet, "BSC_TESTNET": BSCTestnet, "BSC_MAINNET": BSCMainnet, From ecf288ee22c6b74f42d8f2eb918a56182c65872e Mon Sep 17 00:00:00 2001 From: Mateusz Sekara Date: Thu, 10 Aug 2023 20:24:10 +0200 Subject: [PATCH 137/270] [CCIP-843] LogPoller - LatestBlock query improvement (#10150) * Introducing block_number lower bound filter. This will make life easier for Postgres by limiting number of records to be scanned. * Spec --- core/chains/evm/logpoller/disabled.go | 2 +- core/chains/evm/logpoller/log_poller.go | 6 ++--- core/chains/evm/logpoller/mocks/log_poller.go | 18 +++++++------- core/chains/evm/logpoller/observability.go | 4 ++-- core/chains/evm/logpoller/orm.go | 7 +++--- core/chains/evm/logpoller/orm_test.go | 24 ++++++++++++++++++- 6 files changed, 42 insertions(+), 19 deletions(-) diff --git a/core/chains/evm/logpoller/disabled.go b/core/chains/evm/logpoller/disabled.go index 939cc98558d..397ce2eda69 100644 --- a/core/chains/evm/logpoller/disabled.go +++ b/core/chains/evm/logpoller/disabled.go @@ -95,6 +95,6 @@ func (d disabled) IndexedLogsCreatedAfter(eventSig common.Hash, address common.A return nil, ErrDisabled } -func (d disabled) LatestBlockByEventSigsAddrsWithConfs(eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { +func (d disabled) LatestBlockByEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { return 0, ErrDisabled } diff --git a/core/chains/evm/logpoller/log_poller.go b/core/chains/evm/logpoller/log_poller.go index 0146d1d5f52..f0892c61885 100644 --- a/core/chains/evm/logpoller/log_poller.go +++ b/core/chains/evm/logpoller/log_poller.go @@ -45,7 +45,7 @@ type LogPoller interface { LogsCreatedAfter(eventSig common.Hash, address common.Address, time time.Time, confs int, qopts ...pg.QOpt) ([]Log, error) LatestLogByEventSigWithConfs(eventSig common.Hash, address common.Address, confs int, qopts ...pg.QOpt) (*Log, error) LatestLogEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) ([]Log, error) - LatestBlockByEventSigsAddrsWithConfs(eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) + LatestBlockByEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) // Content based querying IndexedLogs(eventSig common.Hash, address common.Address, topicIndex int, topicValues []common.Hash, confs int, qopts ...pg.QOpt) ([]Log, error) @@ -994,8 +994,8 @@ func (lp *logPoller) LatestLogEventSigsAddrsWithConfs(fromBlock int64, eventSigs return lp.orm.SelectLatestLogEventSigsAddrsWithConfs(fromBlock, addresses, eventSigs, confs, qopts...) } -func (lp *logPoller) LatestBlockByEventSigsAddrsWithConfs(eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { - return lp.orm.SelectLatestBlockNumberEventSigsAddrsWithConfs(eventSigs, addresses, confs, qopts...) +func (lp *logPoller) LatestBlockByEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { + return lp.orm.SelectLatestBlockNumberEventSigsAddrsWithConfs(fromBlock, eventSigs, addresses, confs, qopts...) } // GetBlocksRange tries to get the specified block numbers from the log pollers diff --git a/core/chains/evm/logpoller/mocks/log_poller.go b/core/chains/evm/logpoller/mocks/log_poller.go index 17e20529b3d..c903f8ea973 100644 --- a/core/chains/evm/logpoller/mocks/log_poller.go +++ b/core/chains/evm/logpoller/mocks/log_poller.go @@ -312,30 +312,30 @@ func (_m *LogPoller) LatestBlock(qopts ...pg.QOpt) (int64, error) { return r0, r1 } -// LatestBlockByEventSigsAddrsWithConfs provides a mock function with given fields: eventSigs, addresses, confs, qopts -func (_m *LogPoller) LatestBlockByEventSigsAddrsWithConfs(eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { +// LatestBlockByEventSigsAddrsWithConfs provides a mock function with given fields: fromBlock, eventSigs, addresses, confs, qopts +func (_m *LogPoller) LatestBlockByEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { _va := make([]interface{}, len(qopts)) for _i := range qopts { _va[_i] = qopts[_i] } var _ca []interface{} - _ca = append(_ca, eventSigs, addresses, confs) + _ca = append(_ca, fromBlock, eventSigs, addresses, confs) _ca = append(_ca, _va...) ret := _m.Called(_ca...) var r0 int64 var r1 error - if rf, ok := ret.Get(0).(func([]common.Hash, []common.Address, int, ...pg.QOpt) (int64, error)); ok { - return rf(eventSigs, addresses, confs, qopts...) + if rf, ok := ret.Get(0).(func(int64, []common.Hash, []common.Address, int, ...pg.QOpt) (int64, error)); ok { + return rf(fromBlock, eventSigs, addresses, confs, qopts...) } - if rf, ok := ret.Get(0).(func([]common.Hash, []common.Address, int, ...pg.QOpt) int64); ok { - r0 = rf(eventSigs, addresses, confs, qopts...) + if rf, ok := ret.Get(0).(func(int64, []common.Hash, []common.Address, int, ...pg.QOpt) int64); ok { + r0 = rf(fromBlock, eventSigs, addresses, confs, qopts...) } else { r0 = ret.Get(0).(int64) } - if rf, ok := ret.Get(1).(func([]common.Hash, []common.Address, int, ...pg.QOpt) error); ok { - r1 = rf(eventSigs, addresses, confs, qopts...) + if rf, ok := ret.Get(1).(func(int64, []common.Hash, []common.Address, int, ...pg.QOpt) error); ok { + r1 = rf(fromBlock, eventSigs, addresses, confs, qopts...) } else { r1 = ret.Error(1) } diff --git a/core/chains/evm/logpoller/observability.go b/core/chains/evm/logpoller/observability.go index 7a04a005af2..4212314f2c8 100644 --- a/core/chains/evm/logpoller/observability.go +++ b/core/chains/evm/logpoller/observability.go @@ -86,9 +86,9 @@ func (o *ObservedLogPoller) LatestLogEventSigsAddrsWithConfs(fromBlock int64, ev }) } -func (o *ObservedLogPoller) LatestBlockByEventSigsAddrsWithConfs(eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { +func (o *ObservedLogPoller) LatestBlockByEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { return withObservedQuery(o, "LatestBlockByEventSigsAddrsWithConfs", func() (int64, error) { - return o.LogPoller.LatestBlockByEventSigsAddrsWithConfs(eventSigs, addresses, confs, qopts...) + return o.LogPoller.LatestBlockByEventSigsAddrsWithConfs(0, eventSigs, addresses, confs, qopts...) }) } diff --git a/core/chains/evm/logpoller/orm.go b/core/chains/evm/logpoller/orm.go index 73084f1dfe7..e8ced08a1e7 100644 --- a/core/chains/evm/logpoller/orm.go +++ b/core/chains/evm/logpoller/orm.go @@ -320,7 +320,7 @@ func (o *ORM) SelectLatestLogEventSigsAddrsWithConfs(fromBlock int64, addresses } // SelectLatestBlockNumberEventSigsAddrsWithConfs finds the latest block number that matches a list of Addresses and list of events. It returns 0 if there is no matching block -func (o *ORM) SelectLatestBlockNumberEventSigsAddrsWithConfs(eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { +func (o *ORM) SelectLatestBlockNumberEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { var blockNumber int64 sigs := concatBytes(eventSigs) addrs := concatBytes(addresses) @@ -331,8 +331,9 @@ func (o *ORM) SelectLatestBlockNumberEventSigsAddrsWithConfs(eventSigs []common. WHERE evm_chain_id = $1 AND event_sig = ANY($2) AND address = ANY($3) AND - block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $4`, - o.chainID.Int64(), sigs, addrs, confs) + block_number > $4 AND + block_number <= (SELECT COALESCE(block_number, 0) FROM evm_log_poller_blocks WHERE evm_chain_id = $1 ORDER BY block_number DESC LIMIT 1) - $5`, + o.chainID.Int64(), sigs, addrs, fromBlock, confs) if err != nil { return 0, err } diff --git a/core/chains/evm/logpoller/orm_test.go b/core/chains/evm/logpoller/orm_test.go index cab43f7991b..73128c311d8 100644 --- a/core/chains/evm/logpoller/orm_test.go +++ b/core/chains/evm/logpoller/orm_test.go @@ -1022,6 +1022,7 @@ func TestSelectLatestBlockNumberEventSigsAddrsWithConfs(t *testing.T) { events []common.Hash addrs []common.Address confs int + fromBlock int64 expectedBlockNumber int64 }{ { @@ -1029,6 +1030,7 @@ func TestSelectLatestBlockNumberEventSigsAddrsWithConfs(t *testing.T) { events: []common.Hash{event2}, addrs: []common.Address{address1}, confs: 0, + fromBlock: 0, expectedBlockNumber: 0, }, { @@ -1036,6 +1038,7 @@ func TestSelectLatestBlockNumberEventSigsAddrsWithConfs(t *testing.T) { events: []common.Hash{event2}, addrs: []common.Address{address2}, confs: 5, + fromBlock: 0, expectedBlockNumber: 0, }, { @@ -1043,6 +1046,7 @@ func TestSelectLatestBlockNumberEventSigsAddrsWithConfs(t *testing.T) { events: []common.Hash{event1}, addrs: []common.Address{address1}, confs: 0, + fromBlock: 0, expectedBlockNumber: 1, }, { @@ -1050,6 +1054,7 @@ func TestSelectLatestBlockNumberEventSigsAddrsWithConfs(t *testing.T) { events: []common.Hash{event1, event2}, addrs: []common.Address{address1, address2}, confs: 0, + fromBlock: 0, expectedBlockNumber: 3, }, { @@ -1057,12 +1062,29 @@ func TestSelectLatestBlockNumberEventSigsAddrsWithConfs(t *testing.T) { events: []common.Hash{event2}, addrs: []common.Address{address2}, confs: 1, + fromBlock: 0, expectedBlockNumber: 2, }, + { + name: "returns 0 if from block is not matching", + events: []common.Hash{event1, event2}, + addrs: []common.Address{address1, address2}, + confs: 0, + fromBlock: 3, + expectedBlockNumber: 0, + }, + { + name: "picks max block from two events when from block is lower", + events: []common.Hash{event1, event2}, + addrs: []common.Address{address1, address2}, + confs: 0, + fromBlock: 2, + expectedBlockNumber: 3, + }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - blockNumber, err := th.ORM.SelectLatestBlockNumberEventSigsAddrsWithConfs(tt.events, tt.addrs, tt.confs) + blockNumber, err := th.ORM.SelectLatestBlockNumberEventSigsAddrsWithConfs(tt.fromBlock, tt.events, tt.addrs, tt.confs) require.NoError(t, err) assert.Equal(t, tt.expectedBlockNumber, blockNumber) }) From b649cf2a7c2169354e4ec11c53962e9e7785c434 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Thu, 10 Aug 2023 23:20:47 +0300 Subject: [PATCH 138/270] fix Geth healthcheck (#10157) --- integration-tests/docker/test_env/geth.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index 8104e665987..b1f496db367 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -178,8 +178,9 @@ func (g *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, Image: "ethereum/client-go:stable", ExposedPorts: []string{"8544/tcp", "8545/tcp"}, Networks: networks, - WaitingFor: tcwait.ForLog("Commit new sealing work"). - WithStartupTimeout(999 * time.Second). + WaitingFor: tcwait.ForHTTP("/"). + WithPort("8544/tcp"). + WithStartupTimeout(120 * time.Second). WithPollInterval(1 * time.Second), Entrypoint: []string{"sh", "./root/init.sh", "--dev", From a97e533db503e55093f5e92501516db6fbc497a0 Mon Sep 17 00:00:00 2001 From: Lei Date: Thu, 10 Aug 2023 14:34:21 -0700 Subject: [PATCH 139/270] SetupAutomationBasic test for v21 (#10111) --- .../actions/automation_ocr_helpers.go | 11 ++ .../chaos/automation_chaos_test.go | 2 +- .../contracts/contract_deployer.go | 174 +++++++++++++++-- .../ethereum/KeeperRegistryVersions.go | 1 + .../contracts/ethereum_keeper_contracts.go | 113 +++++++++-- .../reorg/automation_reorg_test.go | 2 +- integration-tests/smoke/automation_test.go | 181 ++++++++++-------- .../testsetups/keeper_benchmark.go | 3 +- 8 files changed, 370 insertions(+), 117 deletions(-) diff --git a/integration-tests/actions/automation_ocr_helpers.go b/integration-tests/actions/automation_ocr_helpers.go index cfc0b5830d2..af2ffe89a06 100644 --- a/integration-tests/actions/automation_ocr_helpers.go +++ b/integration-tests/actions/automation_ocr_helpers.go @@ -123,6 +123,7 @@ func CreateOCRKeeperJobs( registryAddr string, chainID int64, keyIndex int, + registryVersion ethereum.KeeperRegistryVersion, ) { l := utils.GetTestLogger(t) bootstrapNode := chainlinkNodes[0] @@ -130,6 +131,15 @@ func CreateOCRKeeperJobs( require.NoError(t, err, "Shouldn't fail reading P2P keys from bootstrap node") bootstrapP2PId := bootstrapP2PIds.Data[0].Attributes.PeerID + var contractVersion string + if registryVersion == ethereum.RegistryVersion_2_1 { + contractVersion = "v2.1" + } else if registryVersion == ethereum.RegistryVersion_2_0 { + contractVersion = "v2.0" + } else { + require.FailNow(t, "v2.0 and v2.1 are the only supported versions") + } + bootstrapSpec := &client.OCR2TaskJobSpec{ Name: "ocr2 bootstrap node " + registryAddr, JobType: "bootstrap", @@ -170,6 +180,7 @@ func CreateOCRKeeperJobs( }, PluginConfig: map[string]interface{}{ "mercuryCredentialName": "\"cred1\"", + "contractVersion": "\"" + contractVersion + "\"", }, ContractConfigTrackerPollInterval: *models.NewInterval(time.Second * 15), ContractID: registryAddr, // registryAddr diff --git a/integration-tests/chaos/automation_chaos_test.go b/integration-tests/chaos/automation_chaos_test.go index a693c4568fc..8b803eca320 100644 --- a/integration-tests/chaos/automation_chaos_test.go +++ b/integration-tests/chaos/automation_chaos_test.go @@ -235,7 +235,7 @@ func TestAutomationChaos(t *testing.T) { chainClient, ) - actions.CreateOCRKeeperJobs(t, chainlinkNodes, registry.Address(), network.ChainID, 0) + actions.CreateOCRKeeperJobs(t, chainlinkNodes, registry.Address(), network.ChainID, 0, eth_contracts.RegistryVersion_2_0) nodesWithoutBootstrap := chainlinkNodes[1:] ocrConfig, err := actions.BuildAutoOCR2ConfigVars(t, nodesWithoutBootstrap, defaultOCRRegistryConfig, registrar.Address(), 5*time.Second) require.NoError(t, err, "Error building OCR config vars") diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index d6892791e56..4408555bd31 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -17,19 +17,25 @@ import ( eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" + automationForwarderLogic "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_forwarder_logic" + registrar21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_registrar_wrapper2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flags_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" + iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper2_0" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic1_3" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic2_0" + registrylogica21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1" + registrylogicb21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_3" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" + registry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_aggregator_proxy" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_ethlink_aggregator_wrapper" @@ -578,6 +584,35 @@ func (e *EthereumContractDeployer) DeployKeeperRegistrar(registryVersion eth_con registrar20: instance.(*keeper_registrar_wrapper2_0.KeeperRegistrar), address: address, }, err + } else if registryVersion == eth_contracts.RegistryVersion_2_1 { + // deploy registrar 2.1 + address, _, instance, err := e.client.DeployContract("AutomationRegistrar", func( + opts *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + // set default TriggerType to 0(conditional), AutoApproveConfigType to 2(auto approve enabled), AutoApproveMaxAllowed to 1000 + triggerConfigs := []registrar21.AutomationRegistrar21InitialTriggerConfig{ + {TriggerType: 0, AutoApproveType: 2, AutoApproveMaxAllowed: 1000}, + } + + return registrar21.DeployAutomationRegistrar( + opts, + backend, + common.HexToAddress(linkAddr), + common.HexToAddress(registrarSettings.RegistryAddr), + registrarSettings.MinLinkJuels, + triggerConfigs) + }) + + if err != nil { + return nil, err + } + + return &EthereumKeeperRegistrar{ + client: e.client, + registrar21: instance.(*registrar21.AutomationRegistrar), + address: address, + }, err } // non OCR registrar address, _, instance, err := e.client.DeployContract("KeeperRegistrar", func( @@ -617,21 +652,37 @@ func (e *EthereumContractDeployer) LoadKeeperRegistrar(address common.Address, r client: e.client, registrar: instance.(*keeper_registrar_wrapper1_2.KeeperRegistrar), }, err + } else if registryVersion == eth_contracts.RegistryVersion_2_0 { + instance, err := e.client.LoadContract("KeeperRegistrar", address, func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return keeper_registrar_wrapper2_0.NewKeeperRegistrar(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumKeeperRegistrar{ + address: &address, + client: e.client, + registrar20: instance.(*keeper_registrar_wrapper2_0.KeeperRegistrar), + }, err + } else { + instance, err := e.client.LoadContract("AutomationRegistrar", address, func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return registrar21.NewAutomationRegistrar(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumKeeperRegistrar{ + address: &address, + client: e.client, + registrar21: instance.(*registrar21.AutomationRegistrar), + }, err } - instance, err := e.client.LoadContract("KeeperRegistrar", address, func( - address common.Address, - backend bind.ContractBackend, - ) (interface{}, error) { - return keeper_registrar_wrapper2_0.NewKeeperRegistrar(address, backend) - }) - if err != nil { - return nil, err - } - return &EthereumKeeperRegistrar{ - address: &address, - client: e.client, - registrar20: instance.(*keeper_registrar_wrapper2_0.KeeperRegistrar), - }, err } func (e *EthereumContractDeployer) DeployKeeperRegistry( @@ -821,6 +872,86 @@ func (e *EthereumContractDeployer) DeployKeeperRegistry( address: address, }, err + case eth_contracts.RegistryVersion_2_1: + automationForwarderLogicAddr, _, _, err := e.client.DeployContract("automationForwarderLogic", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return automationForwarderLogic.DeployAutomationForwarderLogic(auth, backend) + }) + + if err != nil { + return nil, err + } + + if err := e.client.WaitForEvents(); err != nil { + return nil, err + } + + registryLogicBAddr, _, _, err := e.client.DeployContract("KeeperRegistryLogicB2_1", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + + return registrylogicb21.DeployKeeperRegistryLogicB( + auth, + backend, + mode, + common.HexToAddress(opts.LinkAddr), + common.HexToAddress(opts.ETHFeedAddr), + common.HexToAddress(opts.GasFeedAddr), + *automationForwarderLogicAddr, + ) + }) + if err != nil { + return nil, err + } + + if err := e.client.WaitForEvents(); err != nil { + return nil, err + } + + registryLogicAAddr, _, _, err := e.client.DeployContract("KeeperRegistryLogicA2_1", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + + return registrylogica21.DeployKeeperRegistryLogicA( + auth, + backend, + *registryLogicBAddr, + ) + }) + if err != nil { + return nil, err + } + if err := e.client.WaitForEvents(); err != nil { + return nil, err + } + + address, _, instance, err := e.client.DeployContract("KeeperRegistry2_0", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return registry21.DeployKeeperRegistry( + auth, + backend, + *registryLogicAAddr, + ) + }) + if err != nil { + return nil, err + } + if err := e.client.WaitForEvents(); err != nil { + return nil, err + } + + return &EthereumKeeperRegistry{ + client: e.client, + version: eth_contracts.RegistryVersion_2_1, + registry2_1: instance.(*registry21.KeeperRegistry), + address: address, + }, err default: return nil, fmt.Errorf("keeper registry version %d is not supported", opts.RegistryVersion) } @@ -889,6 +1020,21 @@ func (e *EthereumContractDeployer) LoadKeeperRegistry(address common.Address, re client: e.client, registry2_0: instance.(*keeper_registry_wrapper2_0.KeeperRegistry), }, err + case eth_contracts.RegistryVersion_2_1: + instance, err := e.client.LoadContract("KeeperRegistry", address, func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return iregistry21.NewIKeeperRegistryMaster(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumKeeperRegistry{ + address: &address, + client: e.client, + registry2_1: instance.(*registry21.KeeperRegistry), + }, err default: return nil, fmt.Errorf("keeper registry version %d is not supported", registryVersion) } diff --git a/integration-tests/contracts/ethereum/KeeperRegistryVersions.go b/integration-tests/contracts/ethereum/KeeperRegistryVersions.go index 9ce38e0d82b..f15e43524d0 100644 --- a/integration-tests/contracts/ethereum/KeeperRegistryVersions.go +++ b/integration-tests/contracts/ethereum/KeeperRegistryVersions.go @@ -17,4 +17,5 @@ const ( RegistryVersion_1_2 RegistryVersion_1_3 RegistryVersion_2_0 + RegistryVersion_2_1 ) diff --git a/integration-tests/contracts/ethereum_keeper_contracts.go b/integration-tests/contracts/ethereum_keeper_contracts.go index afbc3db400d..615131590cd 100644 --- a/integration-tests/contracts/ethereum_keeper_contracts.go +++ b/integration-tests/contracts/ethereum_keeper_contracts.go @@ -15,9 +15,14 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" goabi "github.com/umbracle/ethgo/abi" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + cltypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" + registrar21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_registrar_wrapper2_1" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" + registry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper2_0" @@ -25,6 +30,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_3" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/upkeep_transcoder" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -32,6 +38,9 @@ import ( "github.com/smartcontractkit/chainlink/integration-tests/testreporters" ) +var utilsABI = cltypes.MustGetABI(automation_utils_2_1.AutomationUtilsABI) +var registrarABI = cltypes.MustGetABI(registrar21.AutomationRegistrarABI) + type KeeperRegistrar interface { Address() string @@ -154,6 +163,7 @@ type KeeperRegistrySettings struct { FallbackLinkPrice *big.Int // LINK price used if the LINK price feed is stale MaxCheckDataSize uint32 MaxPerformDataSize uint32 + RegistryVersion ethereum.KeeperRegistryVersion } // KeeperRegistrarSettings represents settings for registrar contract @@ -194,6 +204,7 @@ type EthereumKeeperRegistry struct { registry1_2 *keeper_registry_wrapper1_2.KeeperRegistry registry1_3 *keeper_registry_wrapper1_3.KeeperRegistry registry2_0 *keeper_registry_wrapper2_0.KeeperRegistry + registry2_1 *keeper_registry_wrapper_2_1.KeeperRegistry address *common.Address } @@ -210,23 +221,47 @@ func (v *EthereumKeeperRegistry) Fund(ethAmount *big.Float) error { } func (rcs *KeeperRegistrySettings) EncodeOnChainConfig(registrar string) ([]byte, error) { - configType := goabi.MustNewType("tuple(uint32 paymentPremiumPPB,uint32 flatFeeMicroLink,uint32 checkGasLimit,uint24 stalenessSeconds,uint16 gasCeilingMultiplier,uint96 minUpkeepSpend,uint32 maxPerformGas,uint32 maxCheckDataSize,uint32 maxPerformDataSize,uint256 fallbackGasPrice,uint256 fallbackLinkPrice,address transcoder,address registrar)") - onchainConfig, err := goabi.Encode(map[string]interface{}{ - "paymentPremiumPPB": rcs.PaymentPremiumPPB, - "flatFeeMicroLink": rcs.FlatFeeMicroLINK, - "checkGasLimit": rcs.CheckGasLimit, - "stalenessSeconds": rcs.StalenessSeconds, - "gasCeilingMultiplier": rcs.GasCeilingMultiplier, - "minUpkeepSpend": rcs.MinUpkeepSpend, - "maxPerformGas": rcs.MaxPerformGas, - "maxCheckDataSize": rcs.MaxCheckDataSize, - "maxPerformDataSize": rcs.MaxPerformDataSize, - "fallbackGasPrice": rcs.FallbackGasPrice, - "fallbackLinkPrice": rcs.FallbackLinkPrice, - "transcoder": common.Address{}, - "registrar": registrar, - }, configType) - return onchainConfig, err + if rcs.RegistryVersion == ethereum.RegistryVersion_2_1 { + onchainConfigStruct := registry21.KeeperRegistryBase21OnchainConfig{ + PaymentPremiumPPB: rcs.PaymentPremiumPPB, + FlatFeeMicroLink: rcs.FlatFeeMicroLINK, + CheckGasLimit: rcs.CheckGasLimit, + StalenessSeconds: rcs.StalenessSeconds, + GasCeilingMultiplier: rcs.GasCeilingMultiplier, + MinUpkeepSpend: rcs.MinUpkeepSpend, + MaxPerformGas: rcs.MaxPerformGas, + MaxCheckDataSize: rcs.MaxCheckDataSize, + MaxPerformDataSize: rcs.MaxPerformDataSize, + MaxRevertDataSize: uint32(1000), + FallbackGasPrice: rcs.FallbackGasPrice, + FallbackLinkPrice: rcs.FallbackLinkPrice, + Transcoder: common.Address{}, + Registrars: []common.Address{common.HexToAddress(registrar)}, + UpkeepPrivilegeManager: common.Address{}, + } + encodedOnchainConfig, err := utilsABI.Pack("_onChainConfig", &onchainConfigStruct) + + // slice off the first 4 bytes which is the function signature + return encodedOnchainConfig[4:], err + } else { + configType := goabi.MustNewType("tuple(uint32 paymentPremiumPPB,uint32 flatFeeMicroLink,uint32 checkGasLimit,uint24 stalenessSeconds,uint16 gasCeilingMultiplier,uint96 minUpkeepSpend,uint32 maxPerformGas,uint32 maxCheckDataSize,uint32 maxPerformDataSize,uint256 fallbackGasPrice,uint256 fallbackLinkPrice,address transcoder,address registrar)") + onchainConfig, err := goabi.Encode(map[string]interface{}{ + "paymentPremiumPPB": rcs.PaymentPremiumPPB, + "flatFeeMicroLink": rcs.FlatFeeMicroLINK, + "checkGasLimit": rcs.CheckGasLimit, + "stalenessSeconds": rcs.StalenessSeconds, + "gasCeilingMultiplier": rcs.GasCeilingMultiplier, + "minUpkeepSpend": rcs.MinUpkeepSpend, + "maxPerformGas": rcs.MaxPerformGas, + "maxCheckDataSize": rcs.MaxCheckDataSize, + "maxPerformDataSize": rcs.MaxPerformDataSize, + "fallbackGasPrice": rcs.FallbackGasPrice, + "fallbackLinkPrice": rcs.FallbackLinkPrice, + "transcoder": common.Address{}, + "registrar": registrar, + }, configType) + return onchainConfig, err + } } func (v *EthereumKeeperRegistry) SetConfig(config KeeperRegistrySettings, ocrConfig OCRv2Config) error { @@ -318,6 +353,19 @@ func (v *EthereumKeeperRegistry) SetConfig(config KeeperRegistrySettings, ocrCon return err } return v.client.ProcessTransaction(tx) + case ethereum.RegistryVersion_2_1: + tx, err := v.registry2_1.SetConfig(txOpts, + ocrConfig.Signers, + ocrConfig.Transmitters, + ocrConfig.F, + ocrConfig.OnchainConfig, + ocrConfig.OffchainConfigVersion, + ocrConfig.OffchainConfig, + ) + if err != nil { + return err + } + return v.client.ProcessTransaction(tx) } return fmt.Errorf("keeper registry version %d is not supported", v.version) @@ -947,7 +995,14 @@ func (v *EthereumKeeperRegistry) ParseUpkeepIdFromRegisteredLog(log *types.Log) return nil, err } return parsedLog.Id, nil + case ethereum.RegistryVersion_2_1: + parsedLog, err := v.registry2_1.ParseUpkeepRegistered(*log) + if err != nil { + return nil, err + } + return parsedLog.Id, nil } + return nil, fmt.Errorf("keeper registry version %d is not supported", v.version) } @@ -1618,6 +1673,7 @@ type EthereumKeeperRegistrar struct { client blockchain.EVMClient registrar *keeper_registrar_wrapper1_2.KeeperRegistrar registrar20 *keeper_registrar_wrapper2_0.KeeperRegistrar + registrar21 *registrar21.AutomationRegistrar address *common.Address } @@ -1662,6 +1718,27 @@ func (v *EthereumKeeperRegistrar) EncodeRegisterRequest( amount, common.HexToAddress(senderAddr), ) + + if err != nil { + return nil, err + } + return req, nil + } else if v.registrar21 != nil { + req, err := registrarABI.Pack( + "register", + name, + email, + common.HexToAddress(upkeepAddr), + gasLimit, + common.HexToAddress(adminAddr), + uint8(0), // trigger type + checkData, + []byte{}, // triggerConfig + []byte{}, // offchainConfig + amount, + common.HexToAddress(senderAddr), + ) + if err != nil { return nil, err } diff --git a/integration-tests/reorg/automation_reorg_test.go b/integration-tests/reorg/automation_reorg_test.go index a26e0f37f2a..3504aa3ad6a 100644 --- a/integration-tests/reorg/automation_reorg_test.go +++ b/integration-tests/reorg/automation_reorg_test.go @@ -178,7 +178,7 @@ func TestAutomationReorg(t *testing.T) { chainClient, ) - actions.CreateOCRKeeperJobs(t, chainlinkNodes, registry.Address(), network.ChainID, 0) + actions.CreateOCRKeeperJobs(t, chainlinkNodes, registry.Address(), network.ChainID, 0, ethereum.RegistryVersion_2_0) nodesWithoutBootstrap := chainlinkNodes[1:] ocrConfig, err := actions.BuildAutoOCR2ConfigVars(t, nodesWithoutBootstrap, defaultOCRRegistryConfig, registrar.Address(), 5*time.Second) require.NoError(t, err, "OCR2 config should be built successfully") diff --git a/integration-tests/smoke/automation_test.go b/integration-tests/smoke/automation_test.go index 9e2df3d8c0d..bf1d607bbb4 100644 --- a/integration-tests/smoke/automation_test.go +++ b/integration-tests/smoke/automation_test.go @@ -101,101 +101,115 @@ func TestAutomationBasic(t *testing.T) { func SetupAutomationBasic(t *testing.T, nodeUpgrade bool) { t.Parallel() l := utils.GetTestLogger(t) - var ( - upgradeImage string - upgradeVersion string - err error - testName = "basic-upkeep" - ) - if nodeUpgrade { - upgradeImage, err = utils.GetEnv("UPGRADE_IMAGE") - require.NoError(t, err, "Error getting upgrade image") - upgradeVersion, err = utils.GetEnv("UPGRADE_VERSION") - require.NoError(t, err, "Error getting upgrade version") - testName = "node-upgrade" - } - chainClient, chainlinkNodes, contractDeployer, linkToken, registry, registrar, onlyStartRunner, testEnv := setupAutomationTest( - t, testName, ethereum.RegistryVersion_2_0, defaultOCRRegistryConfig, nodeUpgrade, - ) - if onlyStartRunner { - return - } - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - defaultAmountOfUpkeeps, - big.NewInt(automationDefaultLinkFunds), - automationDefaultUpkeepGasLimit, - ) - - l.Info().Msg("Waiting for all upkeeps to be performed") - gom := gomega.NewGomegaWithT(t) - gom.Eventually(func(g gomega.Gomega) { - // Check if the upkeeps are performing multiple times by analyzing their counters and checking they are greater than 10 - for i := 0; i < len(upkeepIDs); i++ { - counter, err := consumers[i].Counter(context.Background()) - require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) - expect := 5 - l.Info().Int64("Upkeeps Performed", counter.Int64()).Int("Upkeep ID", i).Msg("Number of upkeeps performed") - g.Expect(counter.Int64()).Should(gomega.BeNumerically(">=", int64(expect)), - "Expected consumer counter to be greater than %d, but got %d", expect, counter.Int64()) - } - }, "5m", "1s").Should(gomega.Succeed()) // ~1m for cluster setup, ~2m for performing each upkeep 5 times, ~2m buffer + registryVersions := map[string]ethereum.KeeperRegistryVersion{ + "registry_2_0": ethereum.RegistryVersion_2_0, + //"registry_2_1": ethereum.RegistryVersion_2_1, + } - if nodeUpgrade { - expect := 5 - // Upgrade the nodes one at a time and check that the upkeeps are still being performed - for i := 0; i < 5; i++ { - actions.UpgradeChainlinkNodeVersions(testEnv, upgradeImage, upgradeVersion, chainlinkNodes[i]) - time.Sleep(time.Second * 10) - expect = expect + 5 + for n, rv := range registryVersions { + name := n + registryVersion := rv + t.Run(name, func(t *testing.T) { + t.Parallel() + + var ( + upgradeImage string + upgradeVersion string + err error + testName = "basic-upkeep" + ) + if nodeUpgrade { + upgradeImage, err = utils.GetEnv("UPGRADE_IMAGE") + require.NoError(t, err, "Error getting upgrade image") + upgradeVersion, err = utils.GetEnv("UPGRADE_VERSION") + require.NoError(t, err, "Error getting upgrade version") + testName = "node-upgrade" + } + chainClient, chainlinkNodes, contractDeployer, linkToken, registry, registrar, onlyStartRunner, testEnv := setupAutomationTest( + t, testName, registryVersion, defaultOCRRegistryConfig, nodeUpgrade, + ) + if onlyStartRunner { + return + } + + consumers, upkeepIDs := actions.DeployConsumers( + t, + registry, + registrar, + linkToken, + contractDeployer, + chainClient, + defaultAmountOfUpkeeps, + big.NewInt(automationDefaultLinkFunds), + automationDefaultUpkeepGasLimit, + ) + + l.Info().Msg("Waiting for all upkeeps to be performed") + gom := gomega.NewGomegaWithT(t) gom.Eventually(func(g gomega.Gomega) { - // Check if the upkeeps are performing multiple times by analyzing their counters and checking they are increasing by 5 in each step within 5 minutes + // Check if the upkeeps are performing multiple times by analyzing their counters and checking they are greater than 10 for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) - l.Info().Int64("Upkeeps Performed", counter.Int64()).Int("Upkeep ID", i).Msg("Number of upkeeps performed") + expect := 5 + l.Info().Int64("Upkeeps Performed", counter.Int64()).Int("Upkeep Index", i).Msg("Number of upkeeps performed") g.Expect(counter.Int64()).Should(gomega.BeNumerically(">=", int64(expect)), "Expected consumer counter to be greater than %d, but got %d", expect, counter.Int64()) } - }, "5m", "1s").Should(gomega.Succeed()) - } - } + }, "5m", "1s").Should(gomega.Succeed()) // ~1m for cluster setup, ~2m for performing each upkeep 5 times, ~2m buffer + + if nodeUpgrade { + expect := 5 + // Upgrade the nodes one at a time and check that the upkeeps are still being performed + for i := 0; i < 5; i++ { + actions.UpgradeChainlinkNodeVersions(testEnv, upgradeImage, upgradeVersion, chainlinkNodes[i]) + time.Sleep(time.Second * 10) + expect = expect + 5 + gom.Eventually(func(g gomega.Gomega) { + // Check if the upkeeps are performing multiple times by analyzing their counters and checking they are increasing by 5 in each step within 5 minutes + for i := 0; i < len(upkeepIDs); i++ { + counter, err := consumers[i].Counter(context.Background()) + require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) + l.Info().Int64("Upkeeps Performed", counter.Int64()).Int("Upkeep ID", i).Msg("Number of upkeeps performed") + g.Expect(counter.Int64()).Should(gomega.BeNumerically(">=", int64(expect)), + "Expected consumer counter to be greater than %d, but got %d", expect, counter.Int64()) + } + }, "5m", "1s").Should(gomega.Succeed()) + } + } - // Cancel all the registered upkeeps via the registry - for i := 0; i < len(upkeepIDs); i++ { - err := registry.CancelUpkeep(upkeepIDs[i]) - require.NoError(t, err, "Could not cancel upkeep at index %d", i) - } + // Cancel all the registered upkeeps via the registry + for i := 0; i < len(upkeepIDs); i++ { + err := registry.CancelUpkeep(upkeepIDs[i]) + require.NoError(t, err, "Could not cancel upkeep at index %d", i) + } - err = chainClient.WaitForEvents() - require.NoError(t, err, "Error encountered when waiting for upkeeps to be cancelled") + err = chainClient.WaitForEvents() + require.NoError(t, err, "Error encountered when waiting for upkeeps to be cancelled") - var countersAfterCancellation = make([]*big.Int, len(upkeepIDs)) + var countersAfterCancellation = make([]*big.Int, len(upkeepIDs)) - for i := 0; i < len(upkeepIDs); i++ { - // Obtain the amount of times the upkeep has been executed so far - countersAfterCancellation[i], err = consumers[i].Counter(context.Background()) - require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) - l.Info().Int64("Upkeep Count", countersAfterCancellation[i].Int64()).Int("Upkeep Index", i).Msg("Cancelled upkeep") - } + for i := 0; i < len(upkeepIDs); i++ { + // Obtain the amount of times the upkeep has been executed so far + countersAfterCancellation[i], err = consumers[i].Counter(context.Background()) + require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) + l.Info().Int64("Upkeep Count", countersAfterCancellation[i].Int64()).Int("Upkeep Index", i).Msg("Cancelled upkeep") + } - l.Info().Msg("Making sure the counter stays consistent") - gom.Consistently(func(g gomega.Gomega) { - for i := 0; i < len(upkeepIDs); i++ { - // Expect the counter to remain constant (At most increase by 1 to account for stale performs) because the upkeep was cancelled - latestCounter, err := consumers[i].Counter(context.Background()) - g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Failed to retrieve consumer counter for upkeep at index %d", i) - g.Expect(latestCounter.Int64()).Should(gomega.BeNumerically("<=", countersAfterCancellation[i].Int64()+1), - "Expected consumer counter to remain less than or equal to %d, but got %d", - countersAfterCancellation[i].Int64()+1, latestCounter.Int64()) - } - }, "1m", "1s").Should(gomega.Succeed()) + l.Info().Msg("Making sure the counter stays consistent") + gom.Consistently(func(g gomega.Gomega) { + for i := 0; i < len(upkeepIDs); i++ { + // Expect the counter to remain constant (At most increase by 1 to account for stale performs) because the upkeep was cancelled + latestCounter, err := consumers[i].Counter(context.Background()) + g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Failed to retrieve consumer counter for upkeep at index %d", i) + g.Expect(latestCounter.Int64()).Should(gomega.BeNumerically("<=", countersAfterCancellation[i].Int64()+1), + "Expected consumer counter to remain less than or equal to %d, but got %d", + countersAfterCancellation[i].Int64()+1, latestCounter.Int64()) + } + }, "1m", "1s").Should(gomega.Succeed()) + }) + } } func TestAutomationAddFunds(t *testing.T) { @@ -791,6 +805,9 @@ func setupAutomationTest( onlyStartRunner bool, testEnvironment *environment.Environment, ) { + // Add registry version to config + registryConfig.RegistryVersion = registryVersion + network := networks.SelectedNetwork evmConfig := eth.New(nil) if !network.Simulated { @@ -848,7 +865,7 @@ func setupAutomationTest( chainClient, ) - actions.CreateOCRKeeperJobs(t, chainlinkNodes, registry.Address(), network.ChainID, 0) + actions.CreateOCRKeeperJobs(t, chainlinkNodes, registry.Address(), network.ChainID, 0, registryVersion) nodesWithoutBootstrap := chainlinkNodes[1:] ocrConfig, err := actions.BuildAutoOCR2ConfigVars(t, nodesWithoutBootstrap, registryConfig, registrar.Address(), 5*time.Second) require.NoError(t, err, "Error building OCR config vars") diff --git a/integration-tests/testsetups/keeper_benchmark.go b/integration-tests/testsetups/keeper_benchmark.go index c6430072877..4b2691ca2ef 100644 --- a/integration-tests/testsetups/keeper_benchmark.go +++ b/integration-tests/testsetups/keeper_benchmark.go @@ -21,6 +21,7 @@ import ( "github.com/smartcontractkit/chainlink-testing-framework/blockchain" reportModel "github.com/smartcontractkit/chainlink-testing-framework/testreporters" "github.com/smartcontractkit/chainlink-testing-framework/utils" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_3" @@ -240,7 +241,7 @@ func (k *KeeperBenchmarkTest) Run(t *testing.T) { // Send keeper jobs to registry and chainlink nodes if inputs.RegistryVersions[rIndex] == ethereum.RegistryVersion_2_0 { - actions.CreateOCRKeeperJobs(t, k.chainlinkNodes, k.keeperRegistries[rIndex].Address(), k.chainClient.GetChainID().Int64(), txKeyId) + actions.CreateOCRKeeperJobs(t, k.chainlinkNodes, k.keeperRegistries[rIndex].Address(), k.chainClient.GetChainID().Int64(), txKeyId, ethereum.RegistryVersion_2_0) err = k.keeperRegistries[rIndex].SetConfig(*inputs.KeeperRegistrySettings, ocrConfig) require.NoError(t, err, "Registry config should be be set successfully") // Give time for OCR nodes to bootstrap From 79f9447ce841a0c684612251000b2268c24f9da3 Mon Sep 17 00:00:00 2001 From: Awbrey Hughlett Date: Thu, 10 Aug 2023 16:49:45 -0500 Subject: [PATCH 140/270] Fix log provider rate limit integration test (#10122) * Fix log provider rate limit integration test This commit introduces three main integration tests for ReadLogs rate limiting. The tests attempt to capture use cases for the rate limiting feature. As the tests are currently written, some changes were required in the provider `readLogs` function to satisfy the test cases. * addressed PR comments, cleaned up commented code, and added in-line documentation to tests * removed unused type constant * comments and small fix for chains with low number of blocks * updating backfill test * greater than 2 to avoid flakyness * simplified common code in rate limit test into test setup * collapsed all deferrables into a single function --------- Co-authored-by: amirylm --- .../evm21/logprovider/integration_test.go | 284 +++++++++++++----- .../ocr2keeper/evm21/logprovider/provider.go | 69 +++-- 2 files changed, 250 insertions(+), 103 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index ef0b8d62283..5120deee9ba 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -2,11 +2,10 @@ package logprovider_test import ( "context" + "errors" "fmt" "math/big" "strings" - "sync" - "sync/atomic" "testing" "time" @@ -16,6 +15,7 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core" "github.com/ethereum/go-ethereum/eth/ethconfig" + "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "go.uber.org/zap/zapcore" "golang.org/x/time/rate" @@ -36,6 +36,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) func TestIntegration_LogEventProvider(t *testing.T) { @@ -52,7 +53,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { opts := &logprovider.LogEventProviderOptions{ ReadInterval: time.Second / 2, } - logProvider, lp, ethClient := setupLogProvider(t, db, backend, opts) + logProvider, _, lp, ethClient := setupLogProvider(t, db, backend, opts) n := 10 @@ -115,76 +116,209 @@ func TestIntegration_LogEventProvider(t *testing.T) { } func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { - t.Skip() + type deferableFunc func() + + setupTest := func( + t *testing.T, + opts *logprovider.LogEventProviderOptions, + ) ( + context.Context, + *backends.SimulatedBackend, + func(blockHash common.Hash), + logprovider.LogEventProviderTest, + []*big.Int, + func(), + ) { + ctx, cancel := context.WithCancel(testutils.Context(t)) + backend, stopMining, accounts := setupBackend(t) + userContractAccount := accounts[2] + db := setupDB(t) + + deferFunc := func() { + cancel() + stopMining() + _ = db.Close() + } - ctx, cancel := context.WithCancel(testutils.Context(t)) - defer cancel() + logProvider, _, lp, ethClient := setupLogProvider(t, db, backend, opts) + + rounds := 5 + numberOfUserContracts := 10 + poll := pollFn(ctx, t, lp, ethClient) + + // deployUpkeepCounter creates 'n' blocks and 'n' contracts + ids, _, contracts := deployUpkeepCounter( + t, + numberOfUserContracts, + backend, + userContractAccount, + logProvider) + + // have log poller save logs for current blocks + lp.PollAndSaveLogs(ctx, int64(numberOfUserContracts)) + + for i := 0; i < rounds; i++ { + triggerEvents( + ctx, + t, + backend, + userContractAccount, + numberOfUserContracts, + poll, + contracts...) + + for dummyBlocks := 0; dummyBlocks < numberOfUserContracts; dummyBlocks++ { + _ = backend.Commit() + } - backend, stopMining, accounts := setupBackend(t) - defer stopMining() - carrol := accounts[2] + poll(backend.Commit()) + } - db := setupDB(t) - defer db.Close() + { + // total block history at this point should be 566 + var minimumBlockCount int64 = 500 + latestBlock, _ := lp.LatestBlock() - opts := &logprovider.LogEventProviderOptions{ - BlockRateLimit: rate.Every(time.Minute), - BlockLimitBurst: 5, - ReadInterval: time.Second / 2, + assert.GreaterOrEqual(t, latestBlock, minimumBlockCount, "to ensure the integrety of the test, the minimum block count before the test should be %d but got %d", minimumBlockCount, latestBlock) + } + + require.NoError(t, logProvider.ReadLogs(ctx, true, ids...)) + + return ctx, backend, poll, logProvider, ids, deferFunc } - logProvider, lp, ethClient := setupLogProvider(t, db, backend, opts) - n := 10 + // polling for logs at approximately the same rate as a chain produces + // blocks should not encounter rate limits + t.Run("should allow constant polls within the rate and burst limit", func(t *testing.T) { + ctx, backend, poll, logProvider, ids, deferFunc := setupTest(t, &logprovider.LogEventProviderOptions{ + // BlockRateLimit is set low to ensure the test does not exceed the + // rate limit + BlockRateLimit: rate.Every(50 * time.Millisecond), + // BlockLimitBurst is just set to a non-zero value + BlockLimitBurst: 5, + }) - ids, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) - lp.PollAndSaveLogs(ctx, int64(n)) - poll := pollFn(ctx, t, lp, ethClient) - rounds := 4 + defer deferFunc() - for i := 0; i < rounds; i++ { - triggerEvents(ctx, t, backend, carrol, n, poll, contracts...) - poll(backend.Commit()) - for dummyBlocks := 0; dummyBlocks < n; dummyBlocks++ { - _ = backend.Commit() + // set the wait time between reads higher than the rate limit + readWait := 50 * time.Millisecond + timer := time.NewTimer(readWait) + + for i := 0; i < 4; i++ { + <-timer.C + + // advance 1 block for every read + poll(backend.Commit()) + + err := logProvider.ReadLogs(ctx, true, ids...) + if err != nil { + assert.False(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") + } + + timer.Reset(readWait) } - } - require.NoError(t, logProvider.ReadLogs(ctx, true, ids...)) - - var wg sync.WaitGroup - workers := 20 - limitErrs := int32(0) - for i := 0; i < workers; i++ { - idsCp := make([]*big.Int, len(ids)) - copy(idsCp, ids) - wg.Add(1) - go func(i int, ids []*big.Int) { - defer wg.Done() + + poll(backend.Commit()) + + _, err := logProvider.GetLatestPayloads(ctx) + + require.NoError(t, err) + require.NoError(t, logProvider.Close()) + }) + + t.Run("should produce a rate limit error for over burst limit", func(t *testing.T) { + ctx, backend, poll, logProvider, ids, deferFunc := setupTest(t, &logprovider.LogEventProviderOptions{ + // BlockRateLimit is set low to ensure the test does not exceed the + // rate limit + BlockRateLimit: rate.Every(50 * time.Millisecond), + // BlockLimitBurst is just set to a non-zero value + BlockLimitBurst: 5, + }) + + defer deferFunc() + + // set the wait time between reads higher than the rate limit + readWait := 50 * time.Millisecond + timer := time.NewTimer(readWait) + + for i := 0; i < 4; i++ { + <-timer.C + + // advance 4 blocks for every read + for x := 0; x < 4; x++ { + poll(backend.Commit()) + } + err := logProvider.ReadLogs(ctx, true, ids...) if err != nil { - require.True(t, strings.Contains(err.Error(), logprovider.BlockLimitExceeded)) - atomic.AddInt32(&limitErrs, 1) + assert.True(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") } - }(i, idsCp) - } - poll(backend.Commit()) - wg.Wait() - // TODO: fix test (might be caused by timeouts) and uncomment - // require.GreaterOrEqual(t, atomic.LoadInt32(&limitErrs), int32(1), "didn't got rate limit errors") - t.Logf("got %d rate limit errors", atomic.LoadInt32(&limitErrs)) + timer.Reset(readWait) + } - _, err := logProvider.GetLatestPayloads(ctx) - require.NoError(t, err) - require.NoError(t, logProvider.Close()) + poll(backend.Commit()) + + _, err := logProvider.GetLatestPayloads(ctx) + + require.NoError(t, err) + require.NoError(t, logProvider.Close()) + }) + + t.Run("should allow polling after lookback number of blocks have passed", func(t *testing.T) { + ctx, backend, poll, logProvider, ids, deferFunc := setupTest(t, &logprovider.LogEventProviderOptions{ + // BlockRateLimit is set low to ensure the test does not exceed the + // rate limit + BlockRateLimit: rate.Every(50 * time.Millisecond), + // BlockLimitBurst is set low to ensure the test exceeds the burst limit + BlockLimitBurst: 5, + // LogBlocksLookback is set low to reduce the number of blocks required + // to reset the block limiter to maxBurst + LogBlocksLookback: 50, + }) + + defer deferFunc() + + // simulate a burst in unpolled blocks + for i := 0; i < 20; i++ { + _ = backend.Commit() + } + + poll(backend.Commit()) + + // all entries should error at this point because there are too many + // blocks to processes + err := logProvider.ReadLogs(ctx, true, ids...) + if err != nil { + assert.True(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") + } - // TODO: fix test (might be caused by timeouts) and uncomment - // require.Equal(t, len(logs), n*rounds, "failed to read all logs") + // progress the chain by the same number of blocks as the lookback limit + // to trigger the usage of maxBurst + for i := 0; i < 50; i++ { + _ = backend.Commit() + } + + poll(backend.Commit()) + + // all entries should reset to the maxBurst because they are beyond + // the log lookback + err = logProvider.ReadLogs(ctx, true, ids...) + if err != nil { + assert.True(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") + } + + poll(backend.Commit()) + + _, err = logProvider.GetLatestPayloads(ctx) + + require.NoError(t, err) + require.NoError(t, logProvider.Close()) + }) } func TestIntegration_LogEventProvider_Backfill(t *testing.T) { - t.Skip() - - ctx, cancel := context.WithCancel(testutils.Context(t)) + ctx, cancel := context.WithTimeout(testutils.Context(t), time.Second*30) defer cancel() backend, stopMining, accounts := setupBackend(t) @@ -194,12 +328,11 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { db := setupDB(t) defer db.Close() - logProvider, lp, ethClient := setupLogProvider(t, db, backend, &logprovider.LogEventProviderOptions{ + logProvider, _, lp, ethClient := setupLogProvider(t, db, backend, &logprovider.LogEventProviderOptions{ ReadInterval: time.Second / 4, }) n := 10 - pollerTimeout := time.Second * 2 _, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) @@ -212,8 +345,20 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { poll(backend.Commit()) } - <-time.After(pollerTimeout) // let the log poller work + t.Log("waiting for log poller to get updated") + // let the log poller work + b, err := ethClient.BlockByHash(ctx, backend.Commit()) + latestBlock := b.Number().Int64() + for { + latestPolled, err := lp.LatestBlock(pg.WithParentCtx(ctx)) + require.NoError(t, err) + if latestPolled >= latestBlock { + break + } + lp.PollAndSaveLogs(ctx, latestBlock) + } + // starting the log provider should backfill logs go func() { if err := logProvider.Start(ctx); err != nil { t.Logf("error starting log provider: %s", err) @@ -222,21 +367,19 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { }() defer logProvider.Close() - go func(dummyPolls int) { - for i := 0; i < dummyPolls; i++ { - poll(backend.Commit()) - time.Sleep(20 * time.Millisecond) + t.Log("waiting for log provider to do some backfilling") + for ctx.Err() == nil { + currentPartition := logProvider.CurrentPartitionIdx() + if currentPartition >= 2 { + break } - }(n * rounds) - - <-time.After(pollerTimeout * 2) // let the provider work + } logs, err := logProvider.GetLatestPayloads(ctx) require.NoError(t, err) require.NoError(t, logProvider.Close()) - expected := 0 // TODO: fix test (might be caused by timeouts) and change to n - require.GreaterOrEqual(t, len(logs), expected, "failed to backfill logs") + require.GreaterOrEqual(t, len(logs), len(contracts), "failed to backfill logs") } func pollFn(ctx context.Context, t *testing.T, lp logpoller.LogPollerTest, ethClient *evmclient.SimulatedBackendClient) func(blockHash common.Hash) { @@ -314,7 +457,7 @@ func newPlainLogTriggerConfig(upkeepAddr common.Address) logprovider.LogTriggerC } } -func setupLogProvider(t *testing.T, db *sqlx.DB, backend *backends.SimulatedBackend, opts *logprovider.LogEventProviderOptions) (logprovider.LogEventProviderTest, logpoller.LogPollerTest, *evmclient.SimulatedBackendClient) { +func setupLogProvider(t *testing.T, db *sqlx.DB, backend *backends.SimulatedBackend, opts *logprovider.LogEventProviderOptions) (logprovider.LogEventProviderTest, logprovider.UpkeepFilterStore, logpoller.LogPollerTest, *evmclient.SimulatedBackendClient) { ethClient := evmclient.NewSimulatedBackendClient(t, backend, big.NewInt(1337)) pollerLggr := logger.TestLogger(t) pollerLggr.SetLogLevel(zapcore.WarnLevel) @@ -324,9 +467,10 @@ func setupLogProvider(t *testing.T, db *sqlx.DB, backend *backends.SimulatedBack lggr := logger.TestLogger(t) logDataABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) require.NoError(t, err) - logProvider := logprovider.New(lggr, lp, logprovider.NewLogEventsPacker(logDataABI), logprovider.NewUpkeepFilterStore(), opts) + filterStore := logprovider.NewUpkeepFilterStore() + logProvider := logprovider.New(lggr, lp, logprovider.NewLogEventsPacker(logDataABI), filterStore, opts) - return logProvider, lp, ethClient + return logProvider, filterStore, lp, ethClient } func setupBackend(t *testing.T) (*backends.SimulatedBackend, func(), []*bind.TransactOpts) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 670a7b34359..3c706bf2370 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -3,6 +3,7 @@ package logprovider import ( "context" "crypto/sha256" + "errors" "fmt" "hash" "math/big" @@ -14,7 +15,6 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" - "go.uber.org/multierr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -23,13 +23,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) -const ( - BlockLimitExceeded = "block limit exceeded" - logTriggerType = 1 -) - var ( - ErrHeadNotAvailable = fmt.Errorf("head not available") + ErrHeadNotAvailable = fmt.Errorf("head not available") + ErrBlockLimitExceeded = fmt.Errorf("block limit exceeded") ) // LogTriggerConfig is an alias for log trigger config. @@ -236,6 +232,9 @@ func (p *logEventProvider) startReader(pctx context.Context, readQ <-chan []*big select { case batch := <-readQ: if err := p.ReadLogs(ctx, true, batch...); err != nil { + if ctx.Err() != nil { + return + } lggr.Warnw("failed to read logs", "err", err) } case <-ctx.Done(): @@ -315,60 +314,64 @@ func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big } // readLogs calls log poller to get the logs for the given upkeep entries. -// we use p.opts.LookbackBuffer to check for reorgs based logs. // // TODO: batch entries by contract address and call log poller once per contract address // NOTE: the entries are already grouped by contract address func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries []upkeepFilter) (merr error) { - // mainLggr := p.lggr.With("latestBlock", latest) - logBlocksLookback := p.opts.LogBlocksLookback - maxBurst := int(logBlocksLookback*2 + 1) + lookbackBlocks := p.opts.LogBlocksLookback + if latest < lookbackBlocks { + // special case of an empty or new blockchain (e.g. simulated chain) + lookbackBlocks = latest + } + // maxBurst will be used to increase the burst limit to allow a long range scan + maxBurst := int(lookbackBlocks + 1) for _, entry := range entries { if len(entry.addr) == 0 { continue } - // lggr := mainLggr.With("upkeep", entry.upkeepID.String(), "addrs", entry.addr, "sigs", entry.topics) + // start should either be the last block polled for the entry or the + // lookback range in the case this is the first time the entry is polled start := entry.lastPollBlock - if start == 0 || start < latest-logBlocksLookback { - // long range or first time polling, - // using a larger lookback and burst - start = latest - logBlocksLookback*2 + if start == 0 || start < latest-lookbackBlocks { + start = latest - lookbackBlocks entry.blockLimiter.SetBurst(maxBurst) } + resv := entry.blockLimiter.ReserveN(time.Now(), int(latest-start)) if !resv.OK() { - merr = multierr.Append(merr, fmt.Errorf("%s: %s", BlockLimitExceeded, entry.upkeepID.String())) + merr = errors.Join(merr, fmt.Errorf("%w: %s", ErrBlockLimitExceeded, entry.upkeepID.String())) continue } - start = start - p.opts.LookbackBuffer // adding a buffer to check for reorgs + // adding a buffer to check for reorged logs. + start = start - p.opts.LookbackBuffer if start < 0 { start = 0 } - // lggr = lggr.With("startBlock", start) + logs, err := p.poller.LogsWithSigs(start, latest, entry.topics, common.BytesToAddress(entry.addr), pg.WithParentCtx(ctx)) if err != nil { - resv.Cancel() // cancels limit reservation as we failed to get logs + // cancel limit reservation as we failed to get logs + resv.Cancel() + // exit if the context was canceled if ctx.Err() != nil { - return multierr.Append(merr, ctx.Err()) + return merr } - merr = multierr.Append(merr, fmt.Errorf("failed to get logs for upkeep %s: %w", entry.upkeepID.String(), err)) + + merr = errors.Join(merr, fmt.Errorf("failed to get logs for upkeep %s: %w", entry.upkeepID.String(), err)) + continue } - // if this limiter's burst was set to the max, - // we need to reset it + // if this limiter's burst was set to the max -> + // reset it and cancel the reservation to allow further processing if entry.blockLimiter.Burst() == maxBurst { - resv.Cancel() // cancel the reservation as we are resetting the burst + resv.Cancel() entry.blockLimiter.SetBurst(p.opts.BlockLimitBurst) } - added := p.buffer.enqueue(entry.upkeepID, logs...) - // if we added logs or couldn't find, update the last poll block - if added > 0 || len(logs) == 0 { - entry.lastPollBlock = latest - } - // if n := len(logs); n > 0 { - // lggr.Debugw("got logs for upkeep", "logs", n, "added", added) - // } + + p.buffer.enqueue(entry.upkeepID, logs...) + + entry.lastPollBlock = latest } return merr From cfb92ed4d82e104191ff00d0d364def76d8f97e7 Mon Sep 17 00:00:00 2001 From: Tate Date: Fri, 11 Aug 2023 00:51:07 -0600 Subject: [PATCH 141/270] [TT-519] Test Cache Fix attempt 2 (#10160) --- .github/workflows/integration-tests.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 9482b2ad956..2de2728eeaf 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -191,7 +191,6 @@ jobs: nodes: 1 os: ubuntu-latest pyroscope_env: ci-smoke-vrf-evm-simulated - cache: 'true' - name: vrfv2 nodes: 1 os: ubuntu-latest @@ -211,7 +210,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.6 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -227,7 +226,7 @@ jobs: publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod - cache_go_vendors: ${{ matrix.product.cache }} + matrix_id: ${{ matrix.product.name }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -235,10 +234,11 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.6 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.7 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod + matrix_id: ${{ matrix.product.name }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} From 46df8c7fdae142e26d303f95dfcba1d5aca9b709 Mon Sep 17 00:00:00 2001 From: Mateusz Sekara Date: Fri, 11 Aug 2023 10:19:40 +0200 Subject: [PATCH 142/270] Fixing passing 0 instead of proper `fromBlock` value (#10163) --- core/chains/evm/logpoller/observability.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/chains/evm/logpoller/observability.go b/core/chains/evm/logpoller/observability.go index 4212314f2c8..f52d2878597 100644 --- a/core/chains/evm/logpoller/observability.go +++ b/core/chains/evm/logpoller/observability.go @@ -88,7 +88,7 @@ func (o *ObservedLogPoller) LatestLogEventSigsAddrsWithConfs(fromBlock int64, ev func (o *ObservedLogPoller) LatestBlockByEventSigsAddrsWithConfs(fromBlock int64, eventSigs []common.Hash, addresses []common.Address, confs int, qopts ...pg.QOpt) (int64, error) { return withObservedQuery(o, "LatestBlockByEventSigsAddrsWithConfs", func() (int64, error) { - return o.LogPoller.LatestBlockByEventSigsAddrsWithConfs(0, eventSigs, addresses, confs, qopts...) + return o.LogPoller.LatestBlockByEventSigsAddrsWithConfs(fromBlock, eventSigs, addresses, confs, qopts...) }) } From 2c21702ba91a0e04babfb87118f70b9f47942bbb Mon Sep 17 00:00:00 2001 From: Makram Date: Fri, 11 Aug 2023 11:22:13 +0300 Subject: [PATCH 143/270] chore: add vrf owner test consumer (#10161) --- .../vrf_owner_test_consumer.go | 863 ++++++++++++++++++ 1 file changed, 863 insertions(+) create mode 100644 core/gethwrappers/generated/vrf_owner_test_consumer/vrf_owner_test_consumer.go diff --git a/core/gethwrappers/generated/vrf_owner_test_consumer/vrf_owner_test_consumer.go b/core/gethwrappers/generated/vrf_owner_test_consumer/vrf_owner_test_consumer.go new file mode 100644 index 00000000000..e815f5491d9 --- /dev/null +++ b/core/gethwrappers/generated/vrf_owner_test_consumer/vrf_owner_test_consumer.go @@ -0,0 +1,863 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package vrf_owner_test_consumer + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var VRFV2OwnerTestConsumerMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_vrfCoordinator\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"have\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"want\",\"type\":\"address\"}],\"name\":\"OnlyCoordinatorCanFulfill\",\"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\"},{\"inputs\":[],\"name\":\"COORDINATOR\",\"outputs\":[{\"internalType\":\"contractVRFCoordinatorV2Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_requestId\",\"type\":\"uint256\"}],\"name\":\"getRequestStatus\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"fulfilled\",\"type\":\"bool\"},{\"internalType\":\"uint256[]\",\"name\":\"randomWords\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256\",\"name\":\"requestTimestamp\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fulfilmentTimestamp\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestBlockNumber\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fulfilmentBlockNumber\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"internalType\":\"uint256[]\",\"name\":\"randomWords\",\"type\":\"uint256[]\"}],\"name\":\"rawFulfillRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"_requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"bytes32\",\"name\":\"_keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"_callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"_numWords\",\"type\":\"uint32\"},{\"internalType\":\"uint16\",\"name\":\"_requestCount\",\"type\":\"uint16\"}],\"name\":\"requestRandomWords\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"reset\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_averageFulfillmentInMillions\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fastestFulfillment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_requestCount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requests\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"fulfilled\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"requestTimestamp\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fulfilmentTimestamp\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"requestBlockNumber\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fulfilmentBlockNumber\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_responseCount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_slowestFulfillment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"subId\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a0604052600060055560006006556103e76007553480156200002157600080fd5b50604051620013ae380380620013ae8339810160408190526200004491620002bf565b6001600160601b0319606082901b166080523380600081620000ad5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000e057620000e08162000213565b5050600280546001600160a01b0319166001600160a01b0384169081179091556040805163288688f960e21b8152905191925063a21a23e49160048083019260209291908290030181600087803b1580156200013b57600080fd5b505af115801562000150573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001769190620002f1565b600280546001600160401b03928316600160a01b908102600160a01b600160e01b03198316811793849055604051631cd0704360e21b81529190930490931660048401523060248401526001600160a01b0391821691161790637341c10c90604401600060405180830381600087803b158015620001f357600080fd5b505af115801562000208573d6000803e3d6000fd5b50505050506200031c565b6001600160a01b0381163314156200026e5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000a4565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620002d257600080fd5b81516001600160a01b0381168114620002ea57600080fd5b9392505050565b6000602082840312156200030457600080fd5b81516001600160401b0381168114620002ea57600080fd5b60805160601c61106c62000342600039600081816103000152610368015261106c6000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c8063a168fa8911610097578063d8a4676f11610066578063d8a4676f14610262578063dc1670db14610287578063eb1d28bb14610290578063f2fde38b146102d557600080fd5b8063a168fa89146101bc578063ad603ea214610227578063b1e217491461023a578063d826f88f1461024357600080fd5b8063737144bc116100d3578063737144bc1461018457806374dba1241461018d57806379ba5097146101965780638da5cb5b1461019e57600080fd5b80631757f11c146101055780631fe543e3146101215780633b2bcbf114610136578063557d2e921461017b575b600080fd5b61010e60065481565b6040519081526020015b60405180910390f35b61013461012f366004610da4565b6102e8565b005b6002546101569073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610118565b61010e60045481565b61010e60055481565b61010e60075481565b6101346103a8565b60005473ffffffffffffffffffffffffffffffffffffffff16610156565b6101fd6101ca366004610d72565b600a602052600090815260409020805460028201546003830154600484015460059094015460ff90931693919290919085565b6040805195151586526020860194909452928401919091526060830152608082015260a001610118565b610134610235366004610d14565b6104a5565b61010e60085481565b6101346000600581905560068190556103e76007556004819055600355565b610275610270366004610d72565b610809565b60405161011896959493929190610e93565b61010e60035481565b6002546102bc9074010000000000000000000000000000000000000000900467ffffffffffffffff1681565b60405167ffffffffffffffff9091168152602001610118565b6101346102e3366004610cd7565b6108ee565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461039a576040517f1cf993f400000000000000000000000000000000000000000000000000000000815233600482015273ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001660248201526044015b60405180910390fd5b6103a48282610902565b5050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610429576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610391565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6104ad610a2d565b60005b8161ffff168161ffff1610156106ad576002546040517f5d3b1d300000000000000000000000000000000000000000000000000000000081526004810187905274010000000000000000000000000000000000000000820467ffffffffffffffff16602482015261ffff8816604482015263ffffffff80871660648301528516608482015260009173ffffffffffffffffffffffffffffffffffffffff1690635d3b1d309060a401602060405180830381600087803b15801561057257600080fd5b505af1158015610586573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906105aa9190610d8b565b6008819055905060006105bb610ab0565b6040805160c08101825260008082528251818152602080820185528084019182524284860152606084018390526080840186905260a08401839052878352600a815293909120825181547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169015151781559051805194955091939092610649926001850192910190610c4c565b506040820151600282015560608201516003820155608082015160048083019190915560a090920151600590910155805490600061068683610fc8565b909155505060009182526009602052604090912055806106a581610fa6565b9150506104b0565b506002546040517f9f87fad700000000000000000000000000000000000000000000000000000000815274010000000000000000000000000000000000000000820467ffffffffffffffff16600482015230602482015273ffffffffffffffffffffffffffffffffffffffff90911690639f87fad790604401600060405180830381600087803b15801561074057600080fd5b505af1158015610754573d6000803e3d6000fd5b50506002546040517fd7ae1d3000000000000000000000000000000000000000000000000000000000815274010000000000000000000000000000000000000000820467ffffffffffffffff16600482015233602482015273ffffffffffffffffffffffffffffffffffffffff909116925063d7ae1d309150604401600060405180830381600087803b1580156107ea57600080fd5b505af11580156107fe573d6000803e3d6000fd5b505050505050505050565b6000818152600a60209081526040808320815160c081018352815460ff161515815260018201805484518187028101870190955280855260609587958695869586958695919492938584019390929083018282801561088757602002820191906000526020600020905b815481526020019060010190808311610873575b505050505081526020016002820154815260200160038201548152602001600482015481526020016005820154815250509050806000015181602001518260400151836060015184608001518560a001519650965096509650965096505091939550919395565b6108f6610a2d565b6108ff81610b56565b50565b600061090c610ab0565b600084815260096020526040812054919250906109299083610f8f565b9050600061093a82620f4240610f52565b905060065482111561094c5760068290555b600754821061095d5760075461095f565b815b60075560035461096f57806109a2565b60035461097d906001610eff565b8160035460055461098e9190610f52565b6109989190610eff565b6109a29190610f17565b6005556000858152600a6020908152604090912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117825586516109f4939290910191870190610c4c565b506000858152600a60205260408120426003808301919091556005909101859055805491610a2183610fc8565b91905055505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610aae576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610391565b565b60004661a4b1811480610ac5575062066eed81145b15610b4f57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b158015610b1157600080fd5b505afa158015610b25573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b499190610d8b565b91505090565b4391505090565b73ffffffffffffffffffffffffffffffffffffffff8116331415610bd6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610391565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b828054828255906000526020600020908101928215610c87579160200282015b82811115610c87578251825591602001919060010190610c6c565b50610c93929150610c97565b5090565b5b80821115610c935760008155600101610c98565b803561ffff81168114610cbe57600080fd5b919050565b803563ffffffff81168114610cbe57600080fd5b600060208284031215610ce957600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610d0d57600080fd5b9392505050565b600080600080600060a08688031215610d2c57600080fd5b610d3586610cac565b945060208601359350610d4a60408701610cc3565b9250610d5860608701610cc3565b9150610d6660808701610cac565b90509295509295909350565b600060208284031215610d8457600080fd5b5035919050565b600060208284031215610d9d57600080fd5b5051919050565b60008060408385031215610db757600080fd5b8235915060208084013567ffffffffffffffff80821115610dd757600080fd5b818601915086601f830112610deb57600080fd5b813581811115610dfd57610dfd611030565b8060051b6040517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0603f83011681018181108582111715610e4057610e40611030565b604052828152858101935084860182860187018b1015610e5f57600080fd5b600095505b83861015610e82578035855260019590950194938601938601610e64565b508096505050505050509250929050565b600060c082018815158352602060c08185015281895180845260e086019150828b01935060005b81811015610ed657845183529383019391830191600101610eba565b505060408501989098525050506060810193909352608083019190915260a09091015292915050565b60008219821115610f1257610f12611001565b500190565b600082610f4d577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615610f8a57610f8a611001565b500290565b600082821015610fa157610fa1611001565b500390565b600061ffff80831681811415610fbe57610fbe611001565b6001019392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff821415610ffa57610ffa611001565b5060010190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var VRFV2OwnerTestConsumerABI = VRFV2OwnerTestConsumerMetaData.ABI + +var VRFV2OwnerTestConsumerBin = VRFV2OwnerTestConsumerMetaData.Bin + +func DeployVRFV2OwnerTestConsumer(auth *bind.TransactOpts, backend bind.ContractBackend, _vrfCoordinator common.Address) (common.Address, *types.Transaction, *VRFV2OwnerTestConsumer, error) { + parsed, err := VRFV2OwnerTestConsumerMetaData.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(VRFV2OwnerTestConsumerBin), backend, _vrfCoordinator) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &VRFV2OwnerTestConsumer{VRFV2OwnerTestConsumerCaller: VRFV2OwnerTestConsumerCaller{contract: contract}, VRFV2OwnerTestConsumerTransactor: VRFV2OwnerTestConsumerTransactor{contract: contract}, VRFV2OwnerTestConsumerFilterer: VRFV2OwnerTestConsumerFilterer{contract: contract}}, nil +} + +type VRFV2OwnerTestConsumer struct { + address common.Address + abi abi.ABI + VRFV2OwnerTestConsumerCaller + VRFV2OwnerTestConsumerTransactor + VRFV2OwnerTestConsumerFilterer +} + +type VRFV2OwnerTestConsumerCaller struct { + contract *bind.BoundContract +} + +type VRFV2OwnerTestConsumerTransactor struct { + contract *bind.BoundContract +} + +type VRFV2OwnerTestConsumerFilterer struct { + contract *bind.BoundContract +} + +type VRFV2OwnerTestConsumerSession struct { + Contract *VRFV2OwnerTestConsumer + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type VRFV2OwnerTestConsumerCallerSession struct { + Contract *VRFV2OwnerTestConsumerCaller + CallOpts bind.CallOpts +} + +type VRFV2OwnerTestConsumerTransactorSession struct { + Contract *VRFV2OwnerTestConsumerTransactor + TransactOpts bind.TransactOpts +} + +type VRFV2OwnerTestConsumerRaw struct { + Contract *VRFV2OwnerTestConsumer +} + +type VRFV2OwnerTestConsumerCallerRaw struct { + Contract *VRFV2OwnerTestConsumerCaller +} + +type VRFV2OwnerTestConsumerTransactorRaw struct { + Contract *VRFV2OwnerTestConsumerTransactor +} + +func NewVRFV2OwnerTestConsumer(address common.Address, backend bind.ContractBackend) (*VRFV2OwnerTestConsumer, error) { + abi, err := abi.JSON(strings.NewReader(VRFV2OwnerTestConsumerABI)) + if err != nil { + return nil, err + } + contract, err := bindVRFV2OwnerTestConsumer(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &VRFV2OwnerTestConsumer{address: address, abi: abi, VRFV2OwnerTestConsumerCaller: VRFV2OwnerTestConsumerCaller{contract: contract}, VRFV2OwnerTestConsumerTransactor: VRFV2OwnerTestConsumerTransactor{contract: contract}, VRFV2OwnerTestConsumerFilterer: VRFV2OwnerTestConsumerFilterer{contract: contract}}, nil +} + +func NewVRFV2OwnerTestConsumerCaller(address common.Address, caller bind.ContractCaller) (*VRFV2OwnerTestConsumerCaller, error) { + contract, err := bindVRFV2OwnerTestConsumer(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &VRFV2OwnerTestConsumerCaller{contract: contract}, nil +} + +func NewVRFV2OwnerTestConsumerTransactor(address common.Address, transactor bind.ContractTransactor) (*VRFV2OwnerTestConsumerTransactor, error) { + contract, err := bindVRFV2OwnerTestConsumer(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &VRFV2OwnerTestConsumerTransactor{contract: contract}, nil +} + +func NewVRFV2OwnerTestConsumerFilterer(address common.Address, filterer bind.ContractFilterer) (*VRFV2OwnerTestConsumerFilterer, error) { + contract, err := bindVRFV2OwnerTestConsumer(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &VRFV2OwnerTestConsumerFilterer{contract: contract}, nil +} + +func bindVRFV2OwnerTestConsumer(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := VRFV2OwnerTestConsumerMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VRFV2OwnerTestConsumer.Contract.VRFV2OwnerTestConsumerCaller.contract.Call(opts, result, method, params...) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.VRFV2OwnerTestConsumerTransactor.contract.Transfer(opts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.VRFV2OwnerTestConsumerTransactor.contract.Transact(opts, method, params...) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VRFV2OwnerTestConsumer.Contract.contract.Call(opts, result, method, params...) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.contract.Transfer(opts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.contract.Transact(opts, method, params...) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) COORDINATOR(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "COORDINATOR") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) COORDINATOR() (common.Address, error) { + return _VRFV2OwnerTestConsumer.Contract.COORDINATOR(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) COORDINATOR() (common.Address, error) { + return _VRFV2OwnerTestConsumer.Contract.COORDINATOR(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) GetRequestStatus(opts *bind.CallOpts, _requestId *big.Int) (GetRequestStatus, + + error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "getRequestStatus", _requestId) + + outstruct := new(GetRequestStatus) + if err != nil { + return *outstruct, err + } + + outstruct.Fulfilled = *abi.ConvertType(out[0], new(bool)).(*bool) + outstruct.RandomWords = *abi.ConvertType(out[1], new([]*big.Int)).(*[]*big.Int) + outstruct.RequestTimestamp = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) + outstruct.FulfilmentTimestamp = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + outstruct.RequestBlockNumber = *abi.ConvertType(out[4], new(*big.Int)).(**big.Int) + outstruct.FulfilmentBlockNumber = *abi.ConvertType(out[5], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) GetRequestStatus(_requestId *big.Int) (GetRequestStatus, + + error) { + return _VRFV2OwnerTestConsumer.Contract.GetRequestStatus(&_VRFV2OwnerTestConsumer.CallOpts, _requestId) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) GetRequestStatus(_requestId *big.Int) (GetRequestStatus, + + error) { + return _VRFV2OwnerTestConsumer.Contract.GetRequestStatus(&_VRFV2OwnerTestConsumer.CallOpts, _requestId) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.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 (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) Owner() (common.Address, error) { + return _VRFV2OwnerTestConsumer.Contract.Owner(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) Owner() (common.Address, error) { + return _VRFV2OwnerTestConsumer.Contract.Owner(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SAverageFulfillmentInMillions(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_averageFulfillmentInMillions") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SAverageFulfillmentInMillions() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SAverageFulfillmentInMillions(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SAverageFulfillmentInMillions() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SAverageFulfillmentInMillions(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SFastestFulfillment(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_fastestFulfillment") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SFastestFulfillment() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SFastestFulfillment(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SFastestFulfillment() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SFastestFulfillment(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SLastRequestId(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_lastRequestId") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SLastRequestId() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SLastRequestId(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SLastRequestId() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SLastRequestId(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SRequestCount(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_requestCount") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SRequestCount() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SRequestCount(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SRequestCount() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SRequestCount(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SRequests(opts *bind.CallOpts, arg0 *big.Int) (SRequests, + + error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_requests", arg0) + + outstruct := new(SRequests) + if err != nil { + return *outstruct, err + } + + outstruct.Fulfilled = *abi.ConvertType(out[0], new(bool)).(*bool) + outstruct.RequestTimestamp = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + outstruct.FulfilmentTimestamp = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) + outstruct.RequestBlockNumber = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + outstruct.FulfilmentBlockNumber = *abi.ConvertType(out[4], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SRequests(arg0 *big.Int) (SRequests, + + error) { + return _VRFV2OwnerTestConsumer.Contract.SRequests(&_VRFV2OwnerTestConsumer.CallOpts, arg0) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SRequests(arg0 *big.Int) (SRequests, + + error) { + return _VRFV2OwnerTestConsumer.Contract.SRequests(&_VRFV2OwnerTestConsumer.CallOpts, arg0) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SResponseCount(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_responseCount") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SResponseCount() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SResponseCount(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SResponseCount() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SResponseCount(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SSlowestFulfillment(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "s_slowestFulfillment") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SSlowestFulfillment() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SSlowestFulfillment(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SSlowestFulfillment() (*big.Int, error) { + return _VRFV2OwnerTestConsumer.Contract.SSlowestFulfillment(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCaller) SubId(opts *bind.CallOpts) (uint64, error) { + var out []interface{} + err := _VRFV2OwnerTestConsumer.contract.Call(opts, &out, "subId") + + if err != nil { + return *new(uint64), err + } + + out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) + + return out0, err + +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) SubId() (uint64, error) { + return _VRFV2OwnerTestConsumer.Contract.SubId(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerCallerSession) SubId() (uint64, error) { + return _VRFV2OwnerTestConsumer.Contract.SubId(&_VRFV2OwnerTestConsumer.CallOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.contract.Transact(opts, "acceptOwnership") +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) AcceptOwnership() (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.AcceptOwnership(&_VRFV2OwnerTestConsumer.TransactOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.AcceptOwnership(&_VRFV2OwnerTestConsumer.TransactOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactor) RawFulfillRandomWords(opts *bind.TransactOpts, requestId *big.Int, randomWords []*big.Int) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.contract.Transact(opts, "rawFulfillRandomWords", requestId, randomWords) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) RawFulfillRandomWords(requestId *big.Int, randomWords []*big.Int) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.RawFulfillRandomWords(&_VRFV2OwnerTestConsumer.TransactOpts, requestId, randomWords) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorSession) RawFulfillRandomWords(requestId *big.Int, randomWords []*big.Int) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.RawFulfillRandomWords(&_VRFV2OwnerTestConsumer.TransactOpts, requestId, randomWords) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactor) RequestRandomWords(opts *bind.TransactOpts, _requestConfirmations uint16, _keyHash [32]byte, _callbackGasLimit uint32, _numWords uint32, _requestCount uint16) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.contract.Transact(opts, "requestRandomWords", _requestConfirmations, _keyHash, _callbackGasLimit, _numWords, _requestCount) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) RequestRandomWords(_requestConfirmations uint16, _keyHash [32]byte, _callbackGasLimit uint32, _numWords uint32, _requestCount uint16) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.RequestRandomWords(&_VRFV2OwnerTestConsumer.TransactOpts, _requestConfirmations, _keyHash, _callbackGasLimit, _numWords, _requestCount) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorSession) RequestRandomWords(_requestConfirmations uint16, _keyHash [32]byte, _callbackGasLimit uint32, _numWords uint32, _requestCount uint16) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.RequestRandomWords(&_VRFV2OwnerTestConsumer.TransactOpts, _requestConfirmations, _keyHash, _callbackGasLimit, _numWords, _requestCount) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactor) Reset(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.contract.Transact(opts, "reset") +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) Reset() (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.Reset(&_VRFV2OwnerTestConsumer.TransactOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorSession) Reset() (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.Reset(&_VRFV2OwnerTestConsumer.TransactOpts) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.contract.Transact(opts, "transferOwnership", to) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.TransferOwnership(&_VRFV2OwnerTestConsumer.TransactOpts, to) +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _VRFV2OwnerTestConsumer.Contract.TransferOwnership(&_VRFV2OwnerTestConsumer.TransactOpts, to) +} + +type VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator struct { + Event *VRFV2OwnerTestConsumerOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VRFV2OwnerTestConsumerOwnershipTransferRequested) + 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(VRFV2OwnerTestConsumerOwnershipTransferRequested) + 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 *VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VRFV2OwnerTestConsumerOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VRFV2OwnerTestConsumer.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator{contract: _VRFV2OwnerTestConsumer.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VRFV2OwnerTestConsumerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VRFV2OwnerTestConsumer.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VRFV2OwnerTestConsumerOwnershipTransferRequested) + if err := _VRFV2OwnerTestConsumer.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerFilterer) ParseOwnershipTransferRequested(log types.Log) (*VRFV2OwnerTestConsumerOwnershipTransferRequested, error) { + event := new(VRFV2OwnerTestConsumerOwnershipTransferRequested) + if err := _VRFV2OwnerTestConsumer.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VRFV2OwnerTestConsumerOwnershipTransferredIterator struct { + Event *VRFV2OwnerTestConsumerOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VRFV2OwnerTestConsumerOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VRFV2OwnerTestConsumerOwnershipTransferred) + 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(VRFV2OwnerTestConsumerOwnershipTransferred) + 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 *VRFV2OwnerTestConsumerOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *VRFV2OwnerTestConsumerOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VRFV2OwnerTestConsumerOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VRFV2OwnerTestConsumerOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VRFV2OwnerTestConsumer.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &VRFV2OwnerTestConsumerOwnershipTransferredIterator{contract: _VRFV2OwnerTestConsumer.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VRFV2OwnerTestConsumerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VRFV2OwnerTestConsumer.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VRFV2OwnerTestConsumerOwnershipTransferred) + if err := _VRFV2OwnerTestConsumer.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 (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumerFilterer) ParseOwnershipTransferred(log types.Log) (*VRFV2OwnerTestConsumerOwnershipTransferred, error) { + event := new(VRFV2OwnerTestConsumerOwnershipTransferred) + if err := _VRFV2OwnerTestConsumer.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type GetRequestStatus struct { + Fulfilled bool + RandomWords []*big.Int + RequestTimestamp *big.Int + FulfilmentTimestamp *big.Int + RequestBlockNumber *big.Int + FulfilmentBlockNumber *big.Int +} +type SRequests struct { + Fulfilled bool + RequestTimestamp *big.Int + FulfilmentTimestamp *big.Int + RequestBlockNumber *big.Int + FulfilmentBlockNumber *big.Int +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumer) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _VRFV2OwnerTestConsumer.abi.Events["OwnershipTransferRequested"].ID: + return _VRFV2OwnerTestConsumer.ParseOwnershipTransferRequested(log) + case _VRFV2OwnerTestConsumer.abi.Events["OwnershipTransferred"].ID: + return _VRFV2OwnerTestConsumer.ParseOwnershipTransferred(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (VRFV2OwnerTestConsumerOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (VRFV2OwnerTestConsumerOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (_VRFV2OwnerTestConsumer *VRFV2OwnerTestConsumer) Address() common.Address { + return _VRFV2OwnerTestConsumer.address +} + +type VRFV2OwnerTestConsumerInterface interface { + COORDINATOR(opts *bind.CallOpts) (common.Address, error) + + GetRequestStatus(opts *bind.CallOpts, _requestId *big.Int) (GetRequestStatus, + + error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SAverageFulfillmentInMillions(opts *bind.CallOpts) (*big.Int, error) + + SFastestFulfillment(opts *bind.CallOpts) (*big.Int, error) + + SLastRequestId(opts *bind.CallOpts) (*big.Int, error) + + SRequestCount(opts *bind.CallOpts) (*big.Int, error) + + SRequests(opts *bind.CallOpts, arg0 *big.Int) (SRequests, + + error) + + SResponseCount(opts *bind.CallOpts) (*big.Int, error) + + SSlowestFulfillment(opts *bind.CallOpts) (*big.Int, error) + + SubId(opts *bind.CallOpts) (uint64, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + RawFulfillRandomWords(opts *bind.TransactOpts, requestId *big.Int, randomWords []*big.Int) (*types.Transaction, error) + + RequestRandomWords(opts *bind.TransactOpts, _requestConfirmations uint16, _keyHash [32]byte, _callbackGasLimit uint32, _numWords uint32, _requestCount uint16) (*types.Transaction, error) + + Reset(opts *bind.TransactOpts) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VRFV2OwnerTestConsumerOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VRFV2OwnerTestConsumerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*VRFV2OwnerTestConsumerOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VRFV2OwnerTestConsumerOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VRFV2OwnerTestConsumerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*VRFV2OwnerTestConsumerOwnershipTransferred, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} From aeda3d5e45ff53aed3c9ec50091baef7d387ca68 Mon Sep 17 00:00:00 2001 From: Gheorghe Strimtu Date: Fri, 11 Aug 2023 13:00:18 +0300 Subject: [PATCH 144/270] REAL-2549 staking events mock contracts (#10131) * REAL-2549 staking events mock contracts * more functions --- .../contracts/contract_deployer.go | 36 + .../contracts/contract_models.go | 19 + .../ethereum/OffchainAggregatorEventsMock.go | 2582 ++++++++++++ .../contracts/ethereum/StakingEventsMock.go | 3675 +++++++++++++++++ .../contracts/ethereum_contracts.go | 154 + 5 files changed, 6466 insertions(+) create mode 100644 integration-tests/contracts/ethereum/OffchainAggregatorEventsMock.go create mode 100644 integration-tests/contracts/ethereum/StakingEventsMock.go diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 4408555bd31..d72e679e2c0 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -94,6 +94,8 @@ type ContractDeployer interface { DeployBatchBlockhashStore(blockhashStoreAddr string) (BatchBlockhashStore, error) DeployFunctionsOracleEventsMock() (FunctionsOracleEventsMock, error) DeployFunctionsBillingRegistryEventsMock() (FunctionsBillingRegistryEventsMock, error) + DeployStakingEventsMock() (StakingEventsMock, error) + DeployOffchainAggregatorEventsMock() (OffchainAggregatorEventsMock, error) DeployMockAggregatorProxy(aggregatorAddr string) (MockAggregatorProxy, error) DeployOffchainAggregatorV2(linkAddr string, offchainOptions OffchainOptions) (OffchainAggregatorV2, error) DeployKeeperRegistryCheckUpkeepGasUsageWrapper(keeperRegistryAddr string) (KeeperRegistryCheckUpkeepGasUsageWrapper, error) @@ -300,6 +302,40 @@ func (e *EthereumContractDeployer) DeployFunctionsBillingRegistryEventsMock() (F }, nil } +func (e *EthereumContractDeployer) DeployStakingEventsMock() (StakingEventsMock, error) { + address, _, instance, err := e.client.DeployContract("StakingEventsMock", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return eth_contracts.DeployStakingEventsMock(auth, backend) + }) + if err != nil { + return nil, err + } + return &EthereumStakingEventsMock{ + client: e.client, + eventsMock: instance.(*eth_contracts.StakingEventsMock), + address: address, + }, nil +} + +func (e *EthereumContractDeployer) DeployOffchainAggregatorEventsMock() (OffchainAggregatorEventsMock, error) { + address, _, instance, err := e.client.DeployContract("OffchainAggregatorEventsMock", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return eth_contracts.DeployOffchainAggregatorEventsMock(auth, backend) + }) + if err != nil { + return nil, err + } + return &EthereumOffchainAggregatorEventsMock{ + client: e.client, + eventsMock: instance.(*eth_contracts.OffchainAggregatorEventsMock), + address: address, + }, nil +} + // DeployLinkTokenContract deploys a Link Token contract to an EVM chain func (e *EthereumContractDeployer) DeployLinkTokenContract() (LinkToken, error) { linkTokenAddress, _, instance, err := e.client.DeployContract("LINK Token", func( diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index ce65864a803..6597416d796 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -237,6 +237,25 @@ type FunctionsBillingRegistryEventsMock interface { BillingEnd(requestId [32]byte, subscriptionId uint64, signerPayment *big.Int, transmitterPayment *big.Int, totalCost *big.Int, success bool) error } +type StakingEventsMock interface { + Address() string + PoolSizeIncreased(maxPoolSize *big.Int) error + MaxCommunityStakeAmountIncreased(maxStakeAmount *big.Int) error + MaxOperatorStakeAmountIncreased(maxStakeAmount *big.Int) error + RewardInitialized(rate *big.Int, available *big.Int, startTimestamp *big.Int, endTimestamp *big.Int) error + AlertRaised(alerter common.Address, roundId *big.Int, rewardAmount *big.Int) error + Staked(staker common.Address, newStake *big.Int, totalStake *big.Int) error + OperatorAdded(operator common.Address) error + OperatorRemoved(operator common.Address, amount *big.Int) error + FeedOperatorsSet(feedOperators []common.Address) error +} + +type OffchainAggregatorEventsMock interface { + Address() string + ConfigSet(previousConfigBlockNumber uint32, configCount uint64, signers []common.Address, transmitters []common.Address, threshold uint8, encodedConfigVersion uint64, encoded []byte) error + NewTransmission(aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) error +} + type MockAggregatorProxy interface { Address() string UpdateAggregator(aggregator common.Address) error diff --git a/integration-tests/contracts/ethereum/OffchainAggregatorEventsMock.go b/integration-tests/contracts/ethereum/OffchainAggregatorEventsMock.go new file mode 100644 index 00000000000..86963e01a45 --- /dev/null +++ b/integration-tests/contracts/ethereum/OffchainAggregatorEventsMock.go @@ -0,0 +1,2582 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package ethereum + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var OffchainAggregatorEventsMockMetaData = &bind.MetaData{ + ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"int256\",\"name\":\"current\",\"type\":\"int256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"roundId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"updatedAt\",\"type\":\"uint256\"}],\"name\":\"AnswerUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"old\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"}],\"name\":\"BillingAccessControllerSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maximumGasPrice\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"reasonableGasPrice\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"microLinkPerEth\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"linkGweiPerObservation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"linkGweiPerTransmission\",\"type\":\"uint32\"}],\"name\":\"BillingSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"threshold\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"encodedConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"encoded\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_oldLinkToken\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"_newLinkToken\",\"type\":\"address\"}],\"name\":\"LinkTokenSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"roundId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"startedBy\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startedAt\",\"type\":\"uint256\"}],\"name\":\"NewRound\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint32\",\"name\":\"aggregatorRoundId\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int192\",\"name\":\"answer\",\"type\":\"int192\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"int192[]\",\"name\":\"observations\",\"type\":\"int192[]\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"observers\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"rawReportContext\",\"type\":\"bytes32\"}],\"name\":\"NewTransmission\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"}],\"name\":\"OraclePaid\",\"type\":\"event\"},{\"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\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previous\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"old\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"}],\"name\":\"RequesterAccessControllerSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes16\",\"name\":\"configDigest\",\"type\":\"bytes16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"round\",\"type\":\"uint8\"}],\"name\":\"RoundRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"previousValidator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousGasLimit\",\"type\":\"uint32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"currentValidator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"currentGasLimit\",\"type\":\"uint32\"}],\"name\":\"ValidatorConfigSet\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"current\",\"type\":\"int256\"},{\"internalType\":\"uint256\",\"name\":\"roundId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"updatedAt\",\"type\":\"uint256\"}],\"name\":\"emitAnswerUpdated\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"old\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"}],\"name\":\"emitBillingAccessControllerSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"maximumGasPrice\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"reasonableGasPrice\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"microLinkPerEth\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"linkGweiPerObservation\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"linkGweiPerTransmission\",\"type\":\"uint32\"}],\"name\":\"emitBillingSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"threshold\",\"type\":\"uint8\"},{\"internalType\":\"uint64\",\"name\":\"encodedConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"encoded\",\"type\":\"bytes\"}],\"name\":\"emitConfigSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_oldLinkToken\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_newLinkToken\",\"type\":\"address\"}],\"name\":\"emitLinkTokenSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"roundId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"startedBy\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"startedAt\",\"type\":\"uint256\"}],\"name\":\"emitNewRound\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"aggregatorRoundId\",\"type\":\"uint32\"},{\"internalType\":\"int192\",\"name\":\"answer\",\"type\":\"int192\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"int192[]\",\"name\":\"observations\",\"type\":\"int192[]\"},{\"internalType\":\"bytes\",\"name\":\"observers\",\"type\":\"bytes\"},{\"internalType\":\"bytes32\",\"name\":\"rawReportContext\",\"type\":\"bytes32\"}],\"name\":\"emitNewTransmission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"}],\"name\":\"emitOraclePaid\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"emitPayeeshipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"previous\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"}],\"name\":\"emitPayeeshipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"old\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"current\",\"type\":\"address\"}],\"name\":\"emitRequesterAccessControllerSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"},{\"internalType\":\"bytes16\",\"name\":\"configDigest\",\"type\":\"bytes16\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"},{\"internalType\":\"uint8\",\"name\":\"round\",\"type\":\"uint8\"}],\"name\":\"emitRoundRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"previousValidator\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"previousGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"currentValidator\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"currentGasLimit\",\"type\":\"uint32\"}],\"name\":\"emitValidatorConfigSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610faf806100206000396000f3fe608060405234801561001057600080fd5b50600436106100f55760003560e01c80638b28369d11610097578063a57c1e0c11610066578063a57c1e0c146101cd578063b019b4e8146101e0578063f7420bc2146101f3578063faf1347c1461020657600080fd5b80638b28369d1461018157806395aa14461461019457806399e1a39b146101a7578063a3296557146101ba57600080fd5b806358e1e734116100d357806358e1e734146101355780636602e6ce14610148578063715bd44e1461015b57806389ffde8d1461016e57600080fd5b8063275c7ea4146100fa5780632c769fd71461010f578063448be1e014610122575b600080fd5b61010d610108366004610c76565b610219565b005b61010d61011d366004610aad565b610265565b61010d610130366004610931565b6102a5565b61010d610143366004610964565b6102fa565b61010d610156366004610a64565b610370565b61010d6101693660046109f4565b6103d3565b61010d61017c366004610931565b61045b565b61010d61018f366004610ad9565b6104a8565b61010d6101a2366004610b0e565b6104f1565b61010d6101b5366004610964565b61053f565b61010d6101c8366004610c11565b6105b5565b61010d6101db366004610931565b610614565b61010d6101ee366004610931565b610672565b61010d610201366004610931565b6106d0565b61010d6102143660046109a7565b61072e565b7f25d719d88a4512dd76c7442b910a83360845505894eb444ef299409e180f8fb9878787878787876040516102549796959493929190610e8a565b60405180910390a150505050505050565b81837f0559884fd3a460db3073b7fc896cc77986f16e378210ded43186175bf646fc5f8360405161029891815260200190565b60405180910390a3505050565b6040805173ffffffffffffffffffffffffffffffffffffffff8085168252831660208201527f793cb73064f3c8cde7e187ae515511e6e56d1ee89bf08b82fa60fb70f8d4891291015b60405180910390a15050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b360405160405180910390a4505050565b6040805163ffffffff80861682528316602082015273ffffffffffffffffffffffffffffffffffffffff80851692908716917fb04e3a37abe9c0fcdfebdeae019a8e2b12ddf53f5d55ffb0caccc1bedaca1541910160405180910390a350505050565b604080517fffffffffffffffffffffffffffffffff000000000000000000000000000000008516815263ffffffff8416602082015260ff831681830152905173ffffffffffffffffffffffffffffffffffffffff8616917f3ea16a923ff4b1df6526e854c9e3a995c43385d70e73359e10623c74f0b52037919081900360600190a250505050565b6040805173ffffffffffffffffffffffffffffffffffffffff8085168252831660208201527f27b89aede8b560578baaa25ee5ce3852c5eecad1e114b941bbd89e1eb4bae63491016102ee565b8173ffffffffffffffffffffffffffffffffffffffff16837f0109fc6f55cf40689f02fbaad7af7fe7bbac8a3d2186600afc7d3e10cac602718360405161029891815260200190565b8563ffffffff167ff6a97944f31ea060dfde0566e4167c1a1082551e64b60ecb14d599a9d023d451868686868660405161052f959493929190610dfd565b60405180910390a2505050505050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836760405160405180910390a4505050565b6040805163ffffffff878116825286811660208301528581168284015284811660608301528316608082015290517fd0d9486a2c673e2a4b57fc82e4c8a556b3e2b82dd5db07e2c04a920ca0f469b69181900360a00190a15050505050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f4966a50c93f855342ccf6c5c0d358b85b91335b2acedc7da0932f691f351711a60405160405180910390a35050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a35050565b8073ffffffffffffffffffffffffffffffffffffffff168373ffffffffffffffffffffffffffffffffffffffff168573ffffffffffffffffffffffffffffffffffffffff167fd0b1dac935d85bd54cf0a33b0d41d39f8cf53a968465fc7ea2377526b8ac712c856040516107a491815260200190565b60405180910390a450505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146107d657600080fd5b919050565b600082601f8301126107ec57600080fd5b813560206108016107fc83610f4f565b610f00565b80838252828201915082860187848660051b890101111561082157600080fd5b60005b8581101561084757610835826107b2565b84529284019290840190600101610824565b5090979650505050505050565b600082601f83011261086557600080fd5b813567ffffffffffffffff81111561087f5761087f610f73565b6108b060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610f00565b8181528460208386010111156108c557600080fd5b816020850160208301376000918101602001919091529392505050565b8035601781900b81146107d657600080fd5b803563ffffffff811681146107d657600080fd5b803567ffffffffffffffff811681146107d657600080fd5b803560ff811681146107d657600080fd5b6000806040838503121561094457600080fd5b61094d836107b2565b915061095b602084016107b2565b90509250929050565b60008060006060848603121561097957600080fd5b610982846107b2565b9250610990602085016107b2565b915061099e604085016107b2565b90509250925092565b600080600080608085870312156109bd57600080fd5b6109c6856107b2565b93506109d4602086016107b2565b9250604085013591506109e9606086016107b2565b905092959194509250565b60008060008060808587031215610a0a57600080fd5b610a13856107b2565b935060208501357fffffffffffffffffffffffffffffffff0000000000000000000000000000000081168114610a4857600080fd5b9250610a56604086016108f4565b91506109e960608601610920565b60008060008060808587031215610a7a57600080fd5b610a83856107b2565b9350610a91602086016108f4565b9250610a9f604086016107b2565b91506109e9606086016108f4565b600080600060608486031215610ac257600080fd5b505081359360208301359350604090920135919050565b600080600060608486031215610aee57600080fd5b83359250610afe602085016107b2565b9150604084013590509250925092565b60008060008060008060c08789031215610b2757600080fd5b610b30876108f4565b95506020610b3f8189016108e2565b9550610b4d604089016107b2565b9450606088013567ffffffffffffffff80821115610b6a57600080fd5b818a0191508a601f830112610b7e57600080fd5b8135610b8c6107fc82610f4f565b8082825285820191508585018e878560051b8801011115610bac57600080fd5b600095505b83861015610bd657610bc2816108e2565b835260019590950194918601918601610bb1565b509750505060808a0135925080831115610bef57600080fd5b5050610bfd89828a01610854565b92505060a087013590509295509295509295565b600080600080600060a08688031215610c2957600080fd5b610c32866108f4565b9450610c40602087016108f4565b9350610c4e604087016108f4565b9250610c5c606087016108f4565b9150610c6a608087016108f4565b90509295509295909350565b600080600080600080600060e0888a031215610c9157600080fd5b610c9a886108f4565b9650610ca860208901610908565b9550604088013567ffffffffffffffff80821115610cc557600080fd5b610cd18b838c016107db565b965060608a0135915080821115610ce757600080fd5b610cf38b838c016107db565b9550610d0160808b01610920565b9450610d0f60a08b01610908565b935060c08a0135915080821115610d2557600080fd5b50610d328a828b01610854565b91505092959891949750929550565b600081518084526020808501945080840160005b83811015610d8757815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101610d55565b509495945050505050565b6000815180845260005b81811015610db857602081850181015186830182015201610d9c565b81811115610dca576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b600060a08201601788810b8452602073ffffffffffffffffffffffffffffffffffffffff89168186015260a0604086015282885180855260c087019150828a01945060005b81811015610e60578551850b83529483019491830191600101610e42565b50508581036060870152610e748189610d92565b9450505050508260808301529695505050505050565b63ffffffff88168152600067ffffffffffffffff808916602084015260e06040840152610eba60e0840189610d41565b8381036060850152610ecc8189610d41565b905060ff8716608085015281861660a085015283810360c0850152610ef18186610d92565b9b9a5050505050505050505050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610f4757610f47610f73565b604052919050565b600067ffffffffffffffff821115610f6957610f69610f73565b5060051b60200190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var OffchainAggregatorEventsMockABI = OffchainAggregatorEventsMockMetaData.ABI + +var OffchainAggregatorEventsMockBin = OffchainAggregatorEventsMockMetaData.Bin + +func DeployOffchainAggregatorEventsMock(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *OffchainAggregatorEventsMock, error) { + parsed, err := OffchainAggregatorEventsMockMetaData.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(OffchainAggregatorEventsMockBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &OffchainAggregatorEventsMock{OffchainAggregatorEventsMockCaller: OffchainAggregatorEventsMockCaller{contract: contract}, OffchainAggregatorEventsMockTransactor: OffchainAggregatorEventsMockTransactor{contract: contract}, OffchainAggregatorEventsMockFilterer: OffchainAggregatorEventsMockFilterer{contract: contract}}, nil +} + +type OffchainAggregatorEventsMock struct { + address common.Address + abi abi.ABI + OffchainAggregatorEventsMockCaller + OffchainAggregatorEventsMockTransactor + OffchainAggregatorEventsMockFilterer +} + +type OffchainAggregatorEventsMockCaller struct { + contract *bind.BoundContract +} + +type OffchainAggregatorEventsMockTransactor struct { + contract *bind.BoundContract +} + +type OffchainAggregatorEventsMockFilterer struct { + contract *bind.BoundContract +} + +type OffchainAggregatorEventsMockSession struct { + Contract *OffchainAggregatorEventsMock + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type OffchainAggregatorEventsMockCallerSession struct { + Contract *OffchainAggregatorEventsMockCaller + CallOpts bind.CallOpts +} + +type OffchainAggregatorEventsMockTransactorSession struct { + Contract *OffchainAggregatorEventsMockTransactor + TransactOpts bind.TransactOpts +} + +type OffchainAggregatorEventsMockRaw struct { + Contract *OffchainAggregatorEventsMock +} + +type OffchainAggregatorEventsMockCallerRaw struct { + Contract *OffchainAggregatorEventsMockCaller +} + +type OffchainAggregatorEventsMockTransactorRaw struct { + Contract *OffchainAggregatorEventsMockTransactor +} + +func NewOffchainAggregatorEventsMock(address common.Address, backend bind.ContractBackend) (*OffchainAggregatorEventsMock, error) { + abi, err := abi.JSON(strings.NewReader(OffchainAggregatorEventsMockABI)) + if err != nil { + return nil, err + } + contract, err := bindOffchainAggregatorEventsMock(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMock{address: address, abi: abi, OffchainAggregatorEventsMockCaller: OffchainAggregatorEventsMockCaller{contract: contract}, OffchainAggregatorEventsMockTransactor: OffchainAggregatorEventsMockTransactor{contract: contract}, OffchainAggregatorEventsMockFilterer: OffchainAggregatorEventsMockFilterer{contract: contract}}, nil +} + +func NewOffchainAggregatorEventsMockCaller(address common.Address, caller bind.ContractCaller) (*OffchainAggregatorEventsMockCaller, error) { + contract, err := bindOffchainAggregatorEventsMock(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockCaller{contract: contract}, nil +} + +func NewOffchainAggregatorEventsMockTransactor(address common.Address, transactor bind.ContractTransactor) (*OffchainAggregatorEventsMockTransactor, error) { + contract, err := bindOffchainAggregatorEventsMock(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockTransactor{contract: contract}, nil +} + +func NewOffchainAggregatorEventsMockFilterer(address common.Address, filterer bind.ContractFilterer) (*OffchainAggregatorEventsMockFilterer, error) { + contract, err := bindOffchainAggregatorEventsMock(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockFilterer{contract: contract}, nil +} + +func bindOffchainAggregatorEventsMock(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := OffchainAggregatorEventsMockMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _OffchainAggregatorEventsMock.Contract.OffchainAggregatorEventsMockCaller.contract.Call(opts, result, method, params...) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.OffchainAggregatorEventsMockTransactor.contract.Transfer(opts) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.OffchainAggregatorEventsMockTransactor.contract.Transact(opts, method, params...) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _OffchainAggregatorEventsMock.Contract.contract.Call(opts, result, method, params...) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.contract.Transfer(opts) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.contract.Transact(opts, method, params...) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitAnswerUpdated(opts *bind.TransactOpts, current *big.Int, roundId *big.Int, updatedAt *big.Int) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitAnswerUpdated", current, roundId, updatedAt) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitAnswerUpdated(current *big.Int, roundId *big.Int, updatedAt *big.Int) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitAnswerUpdated(&_OffchainAggregatorEventsMock.TransactOpts, current, roundId, updatedAt) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitAnswerUpdated(current *big.Int, roundId *big.Int, updatedAt *big.Int) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitAnswerUpdated(&_OffchainAggregatorEventsMock.TransactOpts, current, roundId, updatedAt) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitBillingAccessControllerSet(opts *bind.TransactOpts, old common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitBillingAccessControllerSet", old, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitBillingAccessControllerSet(old common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitBillingAccessControllerSet(&_OffchainAggregatorEventsMock.TransactOpts, old, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitBillingAccessControllerSet(old common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitBillingAccessControllerSet(&_OffchainAggregatorEventsMock.TransactOpts, old, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitBillingSet(opts *bind.TransactOpts, maximumGasPrice uint32, reasonableGasPrice uint32, microLinkPerEth uint32, linkGweiPerObservation uint32, linkGweiPerTransmission uint32) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitBillingSet", maximumGasPrice, reasonableGasPrice, microLinkPerEth, linkGweiPerObservation, linkGweiPerTransmission) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitBillingSet(maximumGasPrice uint32, reasonableGasPrice uint32, microLinkPerEth uint32, linkGweiPerObservation uint32, linkGweiPerTransmission uint32) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitBillingSet(&_OffchainAggregatorEventsMock.TransactOpts, maximumGasPrice, reasonableGasPrice, microLinkPerEth, linkGweiPerObservation, linkGweiPerTransmission) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitBillingSet(maximumGasPrice uint32, reasonableGasPrice uint32, microLinkPerEth uint32, linkGweiPerObservation uint32, linkGweiPerTransmission uint32) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitBillingSet(&_OffchainAggregatorEventsMock.TransactOpts, maximumGasPrice, reasonableGasPrice, microLinkPerEth, linkGweiPerObservation, linkGweiPerTransmission) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitConfigSet(opts *bind.TransactOpts, previousConfigBlockNumber uint32, configCount uint64, signers []common.Address, transmitters []common.Address, threshold uint8, encodedConfigVersion uint64, encoded []byte) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitConfigSet", previousConfigBlockNumber, configCount, signers, transmitters, threshold, encodedConfigVersion, encoded) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitConfigSet(previousConfigBlockNumber uint32, configCount uint64, signers []common.Address, transmitters []common.Address, threshold uint8, encodedConfigVersion uint64, encoded []byte) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitConfigSet(&_OffchainAggregatorEventsMock.TransactOpts, previousConfigBlockNumber, configCount, signers, transmitters, threshold, encodedConfigVersion, encoded) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitConfigSet(previousConfigBlockNumber uint32, configCount uint64, signers []common.Address, transmitters []common.Address, threshold uint8, encodedConfigVersion uint64, encoded []byte) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitConfigSet(&_OffchainAggregatorEventsMock.TransactOpts, previousConfigBlockNumber, configCount, signers, transmitters, threshold, encodedConfigVersion, encoded) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitLinkTokenSet(opts *bind.TransactOpts, _oldLinkToken common.Address, _newLinkToken common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitLinkTokenSet", _oldLinkToken, _newLinkToken) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitLinkTokenSet(_oldLinkToken common.Address, _newLinkToken common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitLinkTokenSet(&_OffchainAggregatorEventsMock.TransactOpts, _oldLinkToken, _newLinkToken) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitLinkTokenSet(_oldLinkToken common.Address, _newLinkToken common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitLinkTokenSet(&_OffchainAggregatorEventsMock.TransactOpts, _oldLinkToken, _newLinkToken) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitNewRound(opts *bind.TransactOpts, roundId *big.Int, startedBy common.Address, startedAt *big.Int) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitNewRound", roundId, startedBy, startedAt) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitNewRound(roundId *big.Int, startedBy common.Address, startedAt *big.Int) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitNewRound(&_OffchainAggregatorEventsMock.TransactOpts, roundId, startedBy, startedAt) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitNewRound(roundId *big.Int, startedBy common.Address, startedAt *big.Int) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitNewRound(&_OffchainAggregatorEventsMock.TransactOpts, roundId, startedBy, startedAt) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitNewTransmission(opts *bind.TransactOpts, aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitNewTransmission", aggregatorRoundId, answer, transmitter, observations, observers, rawReportContext) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitNewTransmission(aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitNewTransmission(&_OffchainAggregatorEventsMock.TransactOpts, aggregatorRoundId, answer, transmitter, observations, observers, rawReportContext) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitNewTransmission(aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitNewTransmission(&_OffchainAggregatorEventsMock.TransactOpts, aggregatorRoundId, answer, transmitter, observations, observers, rawReportContext) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitOraclePaid(opts *bind.TransactOpts, transmitter common.Address, payee common.Address, amount *big.Int, linkToken common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitOraclePaid", transmitter, payee, amount, linkToken) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitOraclePaid(transmitter common.Address, payee common.Address, amount *big.Int, linkToken common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitOraclePaid(&_OffchainAggregatorEventsMock.TransactOpts, transmitter, payee, amount, linkToken) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitOraclePaid(transmitter common.Address, payee common.Address, amount *big.Int, linkToken common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitOraclePaid(&_OffchainAggregatorEventsMock.TransactOpts, transmitter, payee, amount, linkToken) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitOwnershipTransferRequested", from, to) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitOwnershipTransferRequested(&_OffchainAggregatorEventsMock.TransactOpts, from, to) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitOwnershipTransferRequested(&_OffchainAggregatorEventsMock.TransactOpts, from, to) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitOwnershipTransferred", from, to) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitOwnershipTransferred(&_OffchainAggregatorEventsMock.TransactOpts, from, to) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitOwnershipTransferred(&_OffchainAggregatorEventsMock.TransactOpts, from, to) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitPayeeshipTransferRequested(opts *bind.TransactOpts, transmitter common.Address, current common.Address, proposed common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitPayeeshipTransferRequested", transmitter, current, proposed) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitPayeeshipTransferRequested(transmitter common.Address, current common.Address, proposed common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitPayeeshipTransferRequested(&_OffchainAggregatorEventsMock.TransactOpts, transmitter, current, proposed) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitPayeeshipTransferRequested(transmitter common.Address, current common.Address, proposed common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitPayeeshipTransferRequested(&_OffchainAggregatorEventsMock.TransactOpts, transmitter, current, proposed) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitPayeeshipTransferred(opts *bind.TransactOpts, transmitter common.Address, previous common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitPayeeshipTransferred", transmitter, previous, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitPayeeshipTransferred(transmitter common.Address, previous common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitPayeeshipTransferred(&_OffchainAggregatorEventsMock.TransactOpts, transmitter, previous, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitPayeeshipTransferred(transmitter common.Address, previous common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitPayeeshipTransferred(&_OffchainAggregatorEventsMock.TransactOpts, transmitter, previous, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitRequesterAccessControllerSet(opts *bind.TransactOpts, old common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitRequesterAccessControllerSet", old, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitRequesterAccessControllerSet(old common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitRequesterAccessControllerSet(&_OffchainAggregatorEventsMock.TransactOpts, old, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitRequesterAccessControllerSet(old common.Address, current common.Address) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitRequesterAccessControllerSet(&_OffchainAggregatorEventsMock.TransactOpts, old, current) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitRoundRequested(opts *bind.TransactOpts, requester common.Address, configDigest [16]byte, epoch uint32, round uint8) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitRoundRequested", requester, configDigest, epoch, round) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitRoundRequested(requester common.Address, configDigest [16]byte, epoch uint32, round uint8) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitRoundRequested(&_OffchainAggregatorEventsMock.TransactOpts, requester, configDigest, epoch, round) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitRoundRequested(requester common.Address, configDigest [16]byte, epoch uint32, round uint8) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitRoundRequested(&_OffchainAggregatorEventsMock.TransactOpts, requester, configDigest, epoch, round) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactor) EmitValidatorConfigSet(opts *bind.TransactOpts, previousValidator common.Address, previousGasLimit uint32, currentValidator common.Address, currentGasLimit uint32) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.contract.Transact(opts, "emitValidatorConfigSet", previousValidator, previousGasLimit, currentValidator, currentGasLimit) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockSession) EmitValidatorConfigSet(previousValidator common.Address, previousGasLimit uint32, currentValidator common.Address, currentGasLimit uint32) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitValidatorConfigSet(&_OffchainAggregatorEventsMock.TransactOpts, previousValidator, previousGasLimit, currentValidator, currentGasLimit) +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockTransactorSession) EmitValidatorConfigSet(previousValidator common.Address, previousGasLimit uint32, currentValidator common.Address, currentGasLimit uint32) (*types.Transaction, error) { + return _OffchainAggregatorEventsMock.Contract.EmitValidatorConfigSet(&_OffchainAggregatorEventsMock.TransactOpts, previousValidator, previousGasLimit, currentValidator, currentGasLimit) +} + +type OffchainAggregatorEventsMockAnswerUpdatedIterator struct { + Event *OffchainAggregatorEventsMockAnswerUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockAnswerUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockAnswerUpdated) + 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(OffchainAggregatorEventsMockAnswerUpdated) + 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 *OffchainAggregatorEventsMockAnswerUpdatedIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockAnswerUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockAnswerUpdated struct { + Current *big.Int + RoundId *big.Int + UpdatedAt *big.Int + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterAnswerUpdated(opts *bind.FilterOpts, current []*big.Int, roundId []*big.Int) (*OffchainAggregatorEventsMockAnswerUpdatedIterator, error) { + + var currentRule []interface{} + for _, currentItem := range current { + currentRule = append(currentRule, currentItem) + } + var roundIdRule []interface{} + for _, roundIdItem := range roundId { + roundIdRule = append(roundIdRule, roundIdItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "AnswerUpdated", currentRule, roundIdRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockAnswerUpdatedIterator{contract: _OffchainAggregatorEventsMock.contract, event: "AnswerUpdated", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchAnswerUpdated(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockAnswerUpdated, current []*big.Int, roundId []*big.Int) (event.Subscription, error) { + + var currentRule []interface{} + for _, currentItem := range current { + currentRule = append(currentRule, currentItem) + } + var roundIdRule []interface{} + for _, roundIdItem := range roundId { + roundIdRule = append(roundIdRule, roundIdItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "AnswerUpdated", currentRule, roundIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockAnswerUpdated) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "AnswerUpdated", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseAnswerUpdated(log types.Log) (*OffchainAggregatorEventsMockAnswerUpdated, error) { + event := new(OffchainAggregatorEventsMockAnswerUpdated) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "AnswerUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockBillingAccessControllerSetIterator struct { + Event *OffchainAggregatorEventsMockBillingAccessControllerSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockBillingAccessControllerSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockBillingAccessControllerSet) + 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(OffchainAggregatorEventsMockBillingAccessControllerSet) + 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 *OffchainAggregatorEventsMockBillingAccessControllerSetIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockBillingAccessControllerSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockBillingAccessControllerSet struct { + Old common.Address + Current common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterBillingAccessControllerSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockBillingAccessControllerSetIterator, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "BillingAccessControllerSet") + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockBillingAccessControllerSetIterator{contract: _OffchainAggregatorEventsMock.contract, event: "BillingAccessControllerSet", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchBillingAccessControllerSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockBillingAccessControllerSet) (event.Subscription, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "BillingAccessControllerSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockBillingAccessControllerSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "BillingAccessControllerSet", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseBillingAccessControllerSet(log types.Log) (*OffchainAggregatorEventsMockBillingAccessControllerSet, error) { + event := new(OffchainAggregatorEventsMockBillingAccessControllerSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "BillingAccessControllerSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockBillingSetIterator struct { + Event *OffchainAggregatorEventsMockBillingSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockBillingSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockBillingSet) + 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(OffchainAggregatorEventsMockBillingSet) + 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 *OffchainAggregatorEventsMockBillingSetIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockBillingSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockBillingSet struct { + MaximumGasPrice uint32 + ReasonableGasPrice uint32 + MicroLinkPerEth uint32 + LinkGweiPerObservation uint32 + LinkGweiPerTransmission uint32 + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterBillingSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockBillingSetIterator, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "BillingSet") + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockBillingSetIterator{contract: _OffchainAggregatorEventsMock.contract, event: "BillingSet", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchBillingSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockBillingSet) (event.Subscription, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "BillingSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockBillingSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "BillingSet", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseBillingSet(log types.Log) (*OffchainAggregatorEventsMockBillingSet, error) { + event := new(OffchainAggregatorEventsMockBillingSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "BillingSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockConfigSetIterator struct { + Event *OffchainAggregatorEventsMockConfigSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockConfigSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockConfigSet) + 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(OffchainAggregatorEventsMockConfigSet) + 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 *OffchainAggregatorEventsMockConfigSetIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockConfigSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockConfigSet struct { + PreviousConfigBlockNumber uint32 + ConfigCount uint64 + Signers []common.Address + Transmitters []common.Address + Threshold uint8 + EncodedConfigVersion uint64 + Encoded []byte + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterConfigSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockConfigSetIterator, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "ConfigSet") + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockConfigSetIterator{contract: _OffchainAggregatorEventsMock.contract, event: "ConfigSet", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockConfigSet) (event.Subscription, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "ConfigSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockConfigSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "ConfigSet", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseConfigSet(log types.Log) (*OffchainAggregatorEventsMockConfigSet, error) { + event := new(OffchainAggregatorEventsMockConfigSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "ConfigSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockLinkTokenSetIterator struct { + Event *OffchainAggregatorEventsMockLinkTokenSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockLinkTokenSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockLinkTokenSet) + 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(OffchainAggregatorEventsMockLinkTokenSet) + 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 *OffchainAggregatorEventsMockLinkTokenSetIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockLinkTokenSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockLinkTokenSet struct { + OldLinkToken common.Address + NewLinkToken common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterLinkTokenSet(opts *bind.FilterOpts, _oldLinkToken []common.Address, _newLinkToken []common.Address) (*OffchainAggregatorEventsMockLinkTokenSetIterator, error) { + + var _oldLinkTokenRule []interface{} + for _, _oldLinkTokenItem := range _oldLinkToken { + _oldLinkTokenRule = append(_oldLinkTokenRule, _oldLinkTokenItem) + } + var _newLinkTokenRule []interface{} + for _, _newLinkTokenItem := range _newLinkToken { + _newLinkTokenRule = append(_newLinkTokenRule, _newLinkTokenItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "LinkTokenSet", _oldLinkTokenRule, _newLinkTokenRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockLinkTokenSetIterator{contract: _OffchainAggregatorEventsMock.contract, event: "LinkTokenSet", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchLinkTokenSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockLinkTokenSet, _oldLinkToken []common.Address, _newLinkToken []common.Address) (event.Subscription, error) { + + var _oldLinkTokenRule []interface{} + for _, _oldLinkTokenItem := range _oldLinkToken { + _oldLinkTokenRule = append(_oldLinkTokenRule, _oldLinkTokenItem) + } + var _newLinkTokenRule []interface{} + for _, _newLinkTokenItem := range _newLinkToken { + _newLinkTokenRule = append(_newLinkTokenRule, _newLinkTokenItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "LinkTokenSet", _oldLinkTokenRule, _newLinkTokenRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockLinkTokenSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "LinkTokenSet", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseLinkTokenSet(log types.Log) (*OffchainAggregatorEventsMockLinkTokenSet, error) { + event := new(OffchainAggregatorEventsMockLinkTokenSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "LinkTokenSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockNewRoundIterator struct { + Event *OffchainAggregatorEventsMockNewRound + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockNewRoundIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockNewRound) + 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(OffchainAggregatorEventsMockNewRound) + 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 *OffchainAggregatorEventsMockNewRoundIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockNewRoundIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockNewRound struct { + RoundId *big.Int + StartedBy common.Address + StartedAt *big.Int + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterNewRound(opts *bind.FilterOpts, roundId []*big.Int, startedBy []common.Address) (*OffchainAggregatorEventsMockNewRoundIterator, error) { + + var roundIdRule []interface{} + for _, roundIdItem := range roundId { + roundIdRule = append(roundIdRule, roundIdItem) + } + var startedByRule []interface{} + for _, startedByItem := range startedBy { + startedByRule = append(startedByRule, startedByItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "NewRound", roundIdRule, startedByRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockNewRoundIterator{contract: _OffchainAggregatorEventsMock.contract, event: "NewRound", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchNewRound(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockNewRound, roundId []*big.Int, startedBy []common.Address) (event.Subscription, error) { + + var roundIdRule []interface{} + for _, roundIdItem := range roundId { + roundIdRule = append(roundIdRule, roundIdItem) + } + var startedByRule []interface{} + for _, startedByItem := range startedBy { + startedByRule = append(startedByRule, startedByItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "NewRound", roundIdRule, startedByRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockNewRound) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "NewRound", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseNewRound(log types.Log) (*OffchainAggregatorEventsMockNewRound, error) { + event := new(OffchainAggregatorEventsMockNewRound) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "NewRound", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockNewTransmissionIterator struct { + Event *OffchainAggregatorEventsMockNewTransmission + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockNewTransmissionIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockNewTransmission) + 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(OffchainAggregatorEventsMockNewTransmission) + 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 *OffchainAggregatorEventsMockNewTransmissionIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockNewTransmissionIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockNewTransmission struct { + AggregatorRoundId uint32 + Answer *big.Int + Transmitter common.Address + Observations []*big.Int + Observers []byte + RawReportContext [32]byte + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterNewTransmission(opts *bind.FilterOpts, aggregatorRoundId []uint32) (*OffchainAggregatorEventsMockNewTransmissionIterator, error) { + + var aggregatorRoundIdRule []interface{} + for _, aggregatorRoundIdItem := range aggregatorRoundId { + aggregatorRoundIdRule = append(aggregatorRoundIdRule, aggregatorRoundIdItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "NewTransmission", aggregatorRoundIdRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockNewTransmissionIterator{contract: _OffchainAggregatorEventsMock.contract, event: "NewTransmission", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchNewTransmission(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockNewTransmission, aggregatorRoundId []uint32) (event.Subscription, error) { + + var aggregatorRoundIdRule []interface{} + for _, aggregatorRoundIdItem := range aggregatorRoundId { + aggregatorRoundIdRule = append(aggregatorRoundIdRule, aggregatorRoundIdItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "NewTransmission", aggregatorRoundIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockNewTransmission) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "NewTransmission", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseNewTransmission(log types.Log) (*OffchainAggregatorEventsMockNewTransmission, error) { + event := new(OffchainAggregatorEventsMockNewTransmission) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "NewTransmission", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockOraclePaidIterator struct { + Event *OffchainAggregatorEventsMockOraclePaid + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockOraclePaidIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockOraclePaid) + 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(OffchainAggregatorEventsMockOraclePaid) + 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 *OffchainAggregatorEventsMockOraclePaidIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockOraclePaidIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockOraclePaid struct { + Transmitter common.Address + Payee common.Address + Amount *big.Int + LinkToken common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterOraclePaid(opts *bind.FilterOpts, transmitter []common.Address, payee []common.Address, linkToken []common.Address) (*OffchainAggregatorEventsMockOraclePaidIterator, error) { + + var transmitterRule []interface{} + for _, transmitterItem := range transmitter { + transmitterRule = append(transmitterRule, transmitterItem) + } + var payeeRule []interface{} + for _, payeeItem := range payee { + payeeRule = append(payeeRule, payeeItem) + } + + var linkTokenRule []interface{} + for _, linkTokenItem := range linkToken { + linkTokenRule = append(linkTokenRule, linkTokenItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "OraclePaid", transmitterRule, payeeRule, linkTokenRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockOraclePaidIterator{contract: _OffchainAggregatorEventsMock.contract, event: "OraclePaid", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchOraclePaid(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockOraclePaid, transmitter []common.Address, payee []common.Address, linkToken []common.Address) (event.Subscription, error) { + + var transmitterRule []interface{} + for _, transmitterItem := range transmitter { + transmitterRule = append(transmitterRule, transmitterItem) + } + var payeeRule []interface{} + for _, payeeItem := range payee { + payeeRule = append(payeeRule, payeeItem) + } + + var linkTokenRule []interface{} + for _, linkTokenItem := range linkToken { + linkTokenRule = append(linkTokenRule, linkTokenItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "OraclePaid", transmitterRule, payeeRule, linkTokenRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockOraclePaid) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "OraclePaid", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseOraclePaid(log types.Log) (*OffchainAggregatorEventsMockOraclePaid, error) { + event := new(OffchainAggregatorEventsMockOraclePaid) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "OraclePaid", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockOwnershipTransferRequestedIterator struct { + Event *OffchainAggregatorEventsMockOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockOwnershipTransferRequested) + 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(OffchainAggregatorEventsMockOwnershipTransferRequested) + 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 *OffchainAggregatorEventsMockOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*OffchainAggregatorEventsMockOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockOwnershipTransferRequestedIterator{contract: _OffchainAggregatorEventsMock.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockOwnershipTransferRequested) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseOwnershipTransferRequested(log types.Log) (*OffchainAggregatorEventsMockOwnershipTransferRequested, error) { + event := new(OffchainAggregatorEventsMockOwnershipTransferRequested) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockOwnershipTransferredIterator struct { + Event *OffchainAggregatorEventsMockOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockOwnershipTransferred) + 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(OffchainAggregatorEventsMockOwnershipTransferred) + 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 *OffchainAggregatorEventsMockOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*OffchainAggregatorEventsMockOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockOwnershipTransferredIterator{contract: _OffchainAggregatorEventsMock.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockOwnershipTransferred) + if err := _OffchainAggregatorEventsMock.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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseOwnershipTransferred(log types.Log) (*OffchainAggregatorEventsMockOwnershipTransferred, error) { + event := new(OffchainAggregatorEventsMockOwnershipTransferred) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator struct { + Event *OffchainAggregatorEventsMockPayeeshipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockPayeeshipTransferRequested) + 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(OffchainAggregatorEventsMockPayeeshipTransferRequested) + 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 *OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockPayeeshipTransferRequested struct { + Transmitter common.Address + Current common.Address + Proposed common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterPayeeshipTransferRequested(opts *bind.FilterOpts, transmitter []common.Address, current []common.Address, proposed []common.Address) (*OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator, error) { + + var transmitterRule []interface{} + for _, transmitterItem := range transmitter { + transmitterRule = append(transmitterRule, transmitterItem) + } + var currentRule []interface{} + for _, currentItem := range current { + currentRule = append(currentRule, currentItem) + } + var proposedRule []interface{} + for _, proposedItem := range proposed { + proposedRule = append(proposedRule, proposedItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "PayeeshipTransferRequested", transmitterRule, currentRule, proposedRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator{contract: _OffchainAggregatorEventsMock.contract, event: "PayeeshipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchPayeeshipTransferRequested(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockPayeeshipTransferRequested, transmitter []common.Address, current []common.Address, proposed []common.Address) (event.Subscription, error) { + + var transmitterRule []interface{} + for _, transmitterItem := range transmitter { + transmitterRule = append(transmitterRule, transmitterItem) + } + var currentRule []interface{} + for _, currentItem := range current { + currentRule = append(currentRule, currentItem) + } + var proposedRule []interface{} + for _, proposedItem := range proposed { + proposedRule = append(proposedRule, proposedItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "PayeeshipTransferRequested", transmitterRule, currentRule, proposedRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockPayeeshipTransferRequested) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "PayeeshipTransferRequested", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParsePayeeshipTransferRequested(log types.Log) (*OffchainAggregatorEventsMockPayeeshipTransferRequested, error) { + event := new(OffchainAggregatorEventsMockPayeeshipTransferRequested) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "PayeeshipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockPayeeshipTransferredIterator struct { + Event *OffchainAggregatorEventsMockPayeeshipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockPayeeshipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockPayeeshipTransferred) + 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(OffchainAggregatorEventsMockPayeeshipTransferred) + 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 *OffchainAggregatorEventsMockPayeeshipTransferredIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockPayeeshipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockPayeeshipTransferred struct { + Transmitter common.Address + Previous common.Address + Current common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterPayeeshipTransferred(opts *bind.FilterOpts, transmitter []common.Address, previous []common.Address, current []common.Address) (*OffchainAggregatorEventsMockPayeeshipTransferredIterator, error) { + + var transmitterRule []interface{} + for _, transmitterItem := range transmitter { + transmitterRule = append(transmitterRule, transmitterItem) + } + var previousRule []interface{} + for _, previousItem := range previous { + previousRule = append(previousRule, previousItem) + } + var currentRule []interface{} + for _, currentItem := range current { + currentRule = append(currentRule, currentItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "PayeeshipTransferred", transmitterRule, previousRule, currentRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockPayeeshipTransferredIterator{contract: _OffchainAggregatorEventsMock.contract, event: "PayeeshipTransferred", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchPayeeshipTransferred(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockPayeeshipTransferred, transmitter []common.Address, previous []common.Address, current []common.Address) (event.Subscription, error) { + + var transmitterRule []interface{} + for _, transmitterItem := range transmitter { + transmitterRule = append(transmitterRule, transmitterItem) + } + var previousRule []interface{} + for _, previousItem := range previous { + previousRule = append(previousRule, previousItem) + } + var currentRule []interface{} + for _, currentItem := range current { + currentRule = append(currentRule, currentItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "PayeeshipTransferred", transmitterRule, previousRule, currentRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockPayeeshipTransferred) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "PayeeshipTransferred", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParsePayeeshipTransferred(log types.Log) (*OffchainAggregatorEventsMockPayeeshipTransferred, error) { + event := new(OffchainAggregatorEventsMockPayeeshipTransferred) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "PayeeshipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockRequesterAccessControllerSetIterator struct { + Event *OffchainAggregatorEventsMockRequesterAccessControllerSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockRequesterAccessControllerSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockRequesterAccessControllerSet) + 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(OffchainAggregatorEventsMockRequesterAccessControllerSet) + 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 *OffchainAggregatorEventsMockRequesterAccessControllerSetIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockRequesterAccessControllerSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockRequesterAccessControllerSet struct { + Old common.Address + Current common.Address + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterRequesterAccessControllerSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockRequesterAccessControllerSetIterator, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "RequesterAccessControllerSet") + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockRequesterAccessControllerSetIterator{contract: _OffchainAggregatorEventsMock.contract, event: "RequesterAccessControllerSet", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchRequesterAccessControllerSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockRequesterAccessControllerSet) (event.Subscription, error) { + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "RequesterAccessControllerSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockRequesterAccessControllerSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "RequesterAccessControllerSet", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseRequesterAccessControllerSet(log types.Log) (*OffchainAggregatorEventsMockRequesterAccessControllerSet, error) { + event := new(OffchainAggregatorEventsMockRequesterAccessControllerSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "RequesterAccessControllerSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockRoundRequestedIterator struct { + Event *OffchainAggregatorEventsMockRoundRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockRoundRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockRoundRequested) + 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(OffchainAggregatorEventsMockRoundRequested) + 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 *OffchainAggregatorEventsMockRoundRequestedIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockRoundRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockRoundRequested struct { + Requester common.Address + ConfigDigest [16]byte + Epoch uint32 + Round uint8 + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterRoundRequested(opts *bind.FilterOpts, requester []common.Address) (*OffchainAggregatorEventsMockRoundRequestedIterator, error) { + + var requesterRule []interface{} + for _, requesterItem := range requester { + requesterRule = append(requesterRule, requesterItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "RoundRequested", requesterRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockRoundRequestedIterator{contract: _OffchainAggregatorEventsMock.contract, event: "RoundRequested", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchRoundRequested(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockRoundRequested, requester []common.Address) (event.Subscription, error) { + + var requesterRule []interface{} + for _, requesterItem := range requester { + requesterRule = append(requesterRule, requesterItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "RoundRequested", requesterRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockRoundRequested) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "RoundRequested", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseRoundRequested(log types.Log) (*OffchainAggregatorEventsMockRoundRequested, error) { + event := new(OffchainAggregatorEventsMockRoundRequested) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "RoundRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type OffchainAggregatorEventsMockValidatorConfigSetIterator struct { + Event *OffchainAggregatorEventsMockValidatorConfigSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *OffchainAggregatorEventsMockValidatorConfigSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(OffchainAggregatorEventsMockValidatorConfigSet) + 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(OffchainAggregatorEventsMockValidatorConfigSet) + 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 *OffchainAggregatorEventsMockValidatorConfigSetIterator) Error() error { + return it.fail +} + +func (it *OffchainAggregatorEventsMockValidatorConfigSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type OffchainAggregatorEventsMockValidatorConfigSet struct { + PreviousValidator common.Address + PreviousGasLimit uint32 + CurrentValidator common.Address + CurrentGasLimit uint32 + Raw types.Log +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) FilterValidatorConfigSet(opts *bind.FilterOpts, previousValidator []common.Address, currentValidator []common.Address) (*OffchainAggregatorEventsMockValidatorConfigSetIterator, error) { + + var previousValidatorRule []interface{} + for _, previousValidatorItem := range previousValidator { + previousValidatorRule = append(previousValidatorRule, previousValidatorItem) + } + + var currentValidatorRule []interface{} + for _, currentValidatorItem := range currentValidator { + currentValidatorRule = append(currentValidatorRule, currentValidatorItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.FilterLogs(opts, "ValidatorConfigSet", previousValidatorRule, currentValidatorRule) + if err != nil { + return nil, err + } + return &OffchainAggregatorEventsMockValidatorConfigSetIterator{contract: _OffchainAggregatorEventsMock.contract, event: "ValidatorConfigSet", logs: logs, sub: sub}, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) WatchValidatorConfigSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockValidatorConfigSet, previousValidator []common.Address, currentValidator []common.Address) (event.Subscription, error) { + + var previousValidatorRule []interface{} + for _, previousValidatorItem := range previousValidator { + previousValidatorRule = append(previousValidatorRule, previousValidatorItem) + } + + var currentValidatorRule []interface{} + for _, currentValidatorItem := range currentValidator { + currentValidatorRule = append(currentValidatorRule, currentValidatorItem) + } + + logs, sub, err := _OffchainAggregatorEventsMock.contract.WatchLogs(opts, "ValidatorConfigSet", previousValidatorRule, currentValidatorRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(OffchainAggregatorEventsMockValidatorConfigSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "ValidatorConfigSet", 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 (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMockFilterer) ParseValidatorConfigSet(log types.Log) (*OffchainAggregatorEventsMockValidatorConfigSet, error) { + event := new(OffchainAggregatorEventsMockValidatorConfigSet) + if err := _OffchainAggregatorEventsMock.contract.UnpackLog(event, "ValidatorConfigSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMock) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _OffchainAggregatorEventsMock.abi.Events["AnswerUpdated"].ID: + return _OffchainAggregatorEventsMock.ParseAnswerUpdated(log) + case _OffchainAggregatorEventsMock.abi.Events["BillingAccessControllerSet"].ID: + return _OffchainAggregatorEventsMock.ParseBillingAccessControllerSet(log) + case _OffchainAggregatorEventsMock.abi.Events["BillingSet"].ID: + return _OffchainAggregatorEventsMock.ParseBillingSet(log) + case _OffchainAggregatorEventsMock.abi.Events["ConfigSet"].ID: + return _OffchainAggregatorEventsMock.ParseConfigSet(log) + case _OffchainAggregatorEventsMock.abi.Events["LinkTokenSet"].ID: + return _OffchainAggregatorEventsMock.ParseLinkTokenSet(log) + case _OffchainAggregatorEventsMock.abi.Events["NewRound"].ID: + return _OffchainAggregatorEventsMock.ParseNewRound(log) + case _OffchainAggregatorEventsMock.abi.Events["NewTransmission"].ID: + return _OffchainAggregatorEventsMock.ParseNewTransmission(log) + case _OffchainAggregatorEventsMock.abi.Events["OraclePaid"].ID: + return _OffchainAggregatorEventsMock.ParseOraclePaid(log) + case _OffchainAggregatorEventsMock.abi.Events["OwnershipTransferRequested"].ID: + return _OffchainAggregatorEventsMock.ParseOwnershipTransferRequested(log) + case _OffchainAggregatorEventsMock.abi.Events["OwnershipTransferred"].ID: + return _OffchainAggregatorEventsMock.ParseOwnershipTransferred(log) + case _OffchainAggregatorEventsMock.abi.Events["PayeeshipTransferRequested"].ID: + return _OffchainAggregatorEventsMock.ParsePayeeshipTransferRequested(log) + case _OffchainAggregatorEventsMock.abi.Events["PayeeshipTransferred"].ID: + return _OffchainAggregatorEventsMock.ParsePayeeshipTransferred(log) + case _OffchainAggregatorEventsMock.abi.Events["RequesterAccessControllerSet"].ID: + return _OffchainAggregatorEventsMock.ParseRequesterAccessControllerSet(log) + case _OffchainAggregatorEventsMock.abi.Events["RoundRequested"].ID: + return _OffchainAggregatorEventsMock.ParseRoundRequested(log) + case _OffchainAggregatorEventsMock.abi.Events["ValidatorConfigSet"].ID: + return _OffchainAggregatorEventsMock.ParseValidatorConfigSet(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (OffchainAggregatorEventsMockAnswerUpdated) Topic() common.Hash { + return common.HexToHash("0x0559884fd3a460db3073b7fc896cc77986f16e378210ded43186175bf646fc5f") +} + +func (OffchainAggregatorEventsMockBillingAccessControllerSet) Topic() common.Hash { + return common.HexToHash("0x793cb73064f3c8cde7e187ae515511e6e56d1ee89bf08b82fa60fb70f8d48912") +} + +func (OffchainAggregatorEventsMockBillingSet) Topic() common.Hash { + return common.HexToHash("0xd0d9486a2c673e2a4b57fc82e4c8a556b3e2b82dd5db07e2c04a920ca0f469b6") +} + +func (OffchainAggregatorEventsMockConfigSet) Topic() common.Hash { + return common.HexToHash("0x25d719d88a4512dd76c7442b910a83360845505894eb444ef299409e180f8fb9") +} + +func (OffchainAggregatorEventsMockLinkTokenSet) Topic() common.Hash { + return common.HexToHash("0x4966a50c93f855342ccf6c5c0d358b85b91335b2acedc7da0932f691f351711a") +} + +func (OffchainAggregatorEventsMockNewRound) Topic() common.Hash { + return common.HexToHash("0x0109fc6f55cf40689f02fbaad7af7fe7bbac8a3d2186600afc7d3e10cac60271") +} + +func (OffchainAggregatorEventsMockNewTransmission) Topic() common.Hash { + return common.HexToHash("0xf6a97944f31ea060dfde0566e4167c1a1082551e64b60ecb14d599a9d023d451") +} + +func (OffchainAggregatorEventsMockOraclePaid) Topic() common.Hash { + return common.HexToHash("0xd0b1dac935d85bd54cf0a33b0d41d39f8cf53a968465fc7ea2377526b8ac712c") +} + +func (OffchainAggregatorEventsMockOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (OffchainAggregatorEventsMockOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (OffchainAggregatorEventsMockPayeeshipTransferRequested) Topic() common.Hash { + return common.HexToHash("0x84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e38367") +} + +func (OffchainAggregatorEventsMockPayeeshipTransferred) Topic() common.Hash { + return common.HexToHash("0x78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b3") +} + +func (OffchainAggregatorEventsMockRequesterAccessControllerSet) Topic() common.Hash { + return common.HexToHash("0x27b89aede8b560578baaa25ee5ce3852c5eecad1e114b941bbd89e1eb4bae634") +} + +func (OffchainAggregatorEventsMockRoundRequested) Topic() common.Hash { + return common.HexToHash("0x3ea16a923ff4b1df6526e854c9e3a995c43385d70e73359e10623c74f0b52037") +} + +func (OffchainAggregatorEventsMockValidatorConfigSet) Topic() common.Hash { + return common.HexToHash("0xb04e3a37abe9c0fcdfebdeae019a8e2b12ddf53f5d55ffb0caccc1bedaca1541") +} + +func (_OffchainAggregatorEventsMock *OffchainAggregatorEventsMock) Address() common.Address { + return _OffchainAggregatorEventsMock.address +} + +type OffchainAggregatorEventsMockInterface interface { + EmitAnswerUpdated(opts *bind.TransactOpts, current *big.Int, roundId *big.Int, updatedAt *big.Int) (*types.Transaction, error) + + EmitBillingAccessControllerSet(opts *bind.TransactOpts, old common.Address, current common.Address) (*types.Transaction, error) + + EmitBillingSet(opts *bind.TransactOpts, maximumGasPrice uint32, reasonableGasPrice uint32, microLinkPerEth uint32, linkGweiPerObservation uint32, linkGweiPerTransmission uint32) (*types.Transaction, error) + + EmitConfigSet(opts *bind.TransactOpts, previousConfigBlockNumber uint32, configCount uint64, signers []common.Address, transmitters []common.Address, threshold uint8, encodedConfigVersion uint64, encoded []byte) (*types.Transaction, error) + + EmitLinkTokenSet(opts *bind.TransactOpts, _oldLinkToken common.Address, _newLinkToken common.Address) (*types.Transaction, error) + + EmitNewRound(opts *bind.TransactOpts, roundId *big.Int, startedBy common.Address, startedAt *big.Int) (*types.Transaction, error) + + EmitNewTransmission(opts *bind.TransactOpts, aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) (*types.Transaction, error) + + EmitOraclePaid(opts *bind.TransactOpts, transmitter common.Address, payee common.Address, amount *big.Int, linkToken common.Address) (*types.Transaction, error) + + EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitPayeeshipTransferRequested(opts *bind.TransactOpts, transmitter common.Address, current common.Address, proposed common.Address) (*types.Transaction, error) + + EmitPayeeshipTransferred(opts *bind.TransactOpts, transmitter common.Address, previous common.Address, current common.Address) (*types.Transaction, error) + + EmitRequesterAccessControllerSet(opts *bind.TransactOpts, old common.Address, current common.Address) (*types.Transaction, error) + + EmitRoundRequested(opts *bind.TransactOpts, requester common.Address, configDigest [16]byte, epoch uint32, round uint8) (*types.Transaction, error) + + EmitValidatorConfigSet(opts *bind.TransactOpts, previousValidator common.Address, previousGasLimit uint32, currentValidator common.Address, currentGasLimit uint32) (*types.Transaction, error) + + FilterAnswerUpdated(opts *bind.FilterOpts, current []*big.Int, roundId []*big.Int) (*OffchainAggregatorEventsMockAnswerUpdatedIterator, error) + + WatchAnswerUpdated(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockAnswerUpdated, current []*big.Int, roundId []*big.Int) (event.Subscription, error) + + ParseAnswerUpdated(log types.Log) (*OffchainAggregatorEventsMockAnswerUpdated, error) + + FilterBillingAccessControllerSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockBillingAccessControllerSetIterator, error) + + WatchBillingAccessControllerSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockBillingAccessControllerSet) (event.Subscription, error) + + ParseBillingAccessControllerSet(log types.Log) (*OffchainAggregatorEventsMockBillingAccessControllerSet, error) + + FilterBillingSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockBillingSetIterator, error) + + WatchBillingSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockBillingSet) (event.Subscription, error) + + ParseBillingSet(log types.Log) (*OffchainAggregatorEventsMockBillingSet, error) + + FilterConfigSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockConfigSetIterator, error) + + WatchConfigSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockConfigSet) (event.Subscription, error) + + ParseConfigSet(log types.Log) (*OffchainAggregatorEventsMockConfigSet, error) + + FilterLinkTokenSet(opts *bind.FilterOpts, _oldLinkToken []common.Address, _newLinkToken []common.Address) (*OffchainAggregatorEventsMockLinkTokenSetIterator, error) + + WatchLinkTokenSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockLinkTokenSet, _oldLinkToken []common.Address, _newLinkToken []common.Address) (event.Subscription, error) + + ParseLinkTokenSet(log types.Log) (*OffchainAggregatorEventsMockLinkTokenSet, error) + + FilterNewRound(opts *bind.FilterOpts, roundId []*big.Int, startedBy []common.Address) (*OffchainAggregatorEventsMockNewRoundIterator, error) + + WatchNewRound(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockNewRound, roundId []*big.Int, startedBy []common.Address) (event.Subscription, error) + + ParseNewRound(log types.Log) (*OffchainAggregatorEventsMockNewRound, error) + + FilterNewTransmission(opts *bind.FilterOpts, aggregatorRoundId []uint32) (*OffchainAggregatorEventsMockNewTransmissionIterator, error) + + WatchNewTransmission(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockNewTransmission, aggregatorRoundId []uint32) (event.Subscription, error) + + ParseNewTransmission(log types.Log) (*OffchainAggregatorEventsMockNewTransmission, error) + + FilterOraclePaid(opts *bind.FilterOpts, transmitter []common.Address, payee []common.Address, linkToken []common.Address) (*OffchainAggregatorEventsMockOraclePaidIterator, error) + + WatchOraclePaid(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockOraclePaid, transmitter []common.Address, payee []common.Address, linkToken []common.Address) (event.Subscription, error) + + ParseOraclePaid(log types.Log) (*OffchainAggregatorEventsMockOraclePaid, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*OffchainAggregatorEventsMockOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*OffchainAggregatorEventsMockOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*OffchainAggregatorEventsMockOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*OffchainAggregatorEventsMockOwnershipTransferred, error) + + FilterPayeeshipTransferRequested(opts *bind.FilterOpts, transmitter []common.Address, current []common.Address, proposed []common.Address) (*OffchainAggregatorEventsMockPayeeshipTransferRequestedIterator, error) + + WatchPayeeshipTransferRequested(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockPayeeshipTransferRequested, transmitter []common.Address, current []common.Address, proposed []common.Address) (event.Subscription, error) + + ParsePayeeshipTransferRequested(log types.Log) (*OffchainAggregatorEventsMockPayeeshipTransferRequested, error) + + FilterPayeeshipTransferred(opts *bind.FilterOpts, transmitter []common.Address, previous []common.Address, current []common.Address) (*OffchainAggregatorEventsMockPayeeshipTransferredIterator, error) + + WatchPayeeshipTransferred(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockPayeeshipTransferred, transmitter []common.Address, previous []common.Address, current []common.Address) (event.Subscription, error) + + ParsePayeeshipTransferred(log types.Log) (*OffchainAggregatorEventsMockPayeeshipTransferred, error) + + FilterRequesterAccessControllerSet(opts *bind.FilterOpts) (*OffchainAggregatorEventsMockRequesterAccessControllerSetIterator, error) + + WatchRequesterAccessControllerSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockRequesterAccessControllerSet) (event.Subscription, error) + + ParseRequesterAccessControllerSet(log types.Log) (*OffchainAggregatorEventsMockRequesterAccessControllerSet, error) + + FilterRoundRequested(opts *bind.FilterOpts, requester []common.Address) (*OffchainAggregatorEventsMockRoundRequestedIterator, error) + + WatchRoundRequested(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockRoundRequested, requester []common.Address) (event.Subscription, error) + + ParseRoundRequested(log types.Log) (*OffchainAggregatorEventsMockRoundRequested, error) + + FilterValidatorConfigSet(opts *bind.FilterOpts, previousValidator []common.Address, currentValidator []common.Address) (*OffchainAggregatorEventsMockValidatorConfigSetIterator, error) + + WatchValidatorConfigSet(opts *bind.WatchOpts, sink chan<- *OffchainAggregatorEventsMockValidatorConfigSet, previousValidator []common.Address, currentValidator []common.Address) (event.Subscription, error) + + ParseValidatorConfigSet(log types.Log) (*OffchainAggregatorEventsMockValidatorConfigSet, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/integration-tests/contracts/ethereum/StakingEventsMock.go b/integration-tests/contracts/ethereum/StakingEventsMock.go new file mode 100644 index 00000000000..5a1a1663ba9 --- /dev/null +++ b/integration-tests/contracts/ethereum/StakingEventsMock.go @@ -0,0 +1,3675 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package ethereum + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var StakingEventsMockMetaData = &bind.MetaData{ + ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"alerter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"roundId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"rewardAmount\",\"type\":\"uint256\"}],\"name\":\"AlertRaised\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"feedOperators\",\"type\":\"address[]\"}],\"name\":\"FeedOperatorsSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"maxStakeAmount\",\"type\":\"uint256\"}],\"name\":\"MaxCommunityStakeAmountIncreased\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"maxStakeAmount\",\"type\":\"uint256\"}],\"name\":\"MaxOperatorStakeAmountIncreased\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"newMerkleRoot\",\"type\":\"bytes32\"}],\"name\":\"MerkleRootChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"principal\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"baseReward\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"delegationReward\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"Migrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"migrationTarget\",\"type\":\"address\"}],\"name\":\"MigrationTargetAccepted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"migrationTarget\",\"type\":\"address\"}],\"name\":\"MigrationTargetProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"operator\",\"type\":\"address\"}],\"name\":\"OperatorAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"operator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"OperatorRemoved\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"PoolConcluded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[],\"name\":\"PoolOpened\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"maxPoolSize\",\"type\":\"uint256\"}],\"name\":\"PoolSizeIncreased\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountAdded\",\"type\":\"uint256\"}],\"name\":\"RewardAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"rate\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"available\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startTimestamp\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"endTimestamp\",\"type\":\"uint256\"}],\"name\":\"RewardInitialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"rate\",\"type\":\"uint256\"}],\"name\":\"RewardRateChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"operator\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"slashedBaseRewards\",\"type\":\"uint256[]\"},{\"indexed\":false,\"internalType\":\"uint256[]\",\"name\":\"slashedDelegatedRewards\",\"type\":\"uint256[]\"}],\"name\":\"RewardSlashed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"RewardWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newStake\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"totalStake\",\"type\":\"uint256\"}],\"name\":\"Staked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"principal\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"baseReward\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"delegationReward\",\"type\":\"uint256\"}],\"name\":\"Unstaked\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"alerter\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"roundId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"rewardAmount\",\"type\":\"uint256\"}],\"name\":\"emitAlertRaised\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"feedOperators\",\"type\":\"address[]\"}],\"name\":\"emitFeedOperatorsSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"maxStakeAmount\",\"type\":\"uint256\"}],\"name\":\"emitMaxCommunityStakeAmountIncreased\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"maxStakeAmount\",\"type\":\"uint256\"}],\"name\":\"emitMaxOperatorStakeAmountIncreased\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"newMerkleRoot\",\"type\":\"bytes32\"}],\"name\":\"emitMerkleRootChanged\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"principal\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"baseReward\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"delegationReward\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"emitMigrated\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"migrationTarget\",\"type\":\"address\"}],\"name\":\"emitMigrationTargetAccepted\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"migrationTarget\",\"type\":\"address\"}],\"name\":\"emitMigrationTargetProposed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"operator\",\"type\":\"address\"}],\"name\":\"emitOperatorAdded\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"operator\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"emitOperatorRemoved\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"emitPaused\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emitPoolConcluded\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"emitPoolOpened\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"maxPoolSize\",\"type\":\"uint256\"}],\"name\":\"emitPoolSizeIncreased\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amountAdded\",\"type\":\"uint256\"}],\"name\":\"emitRewardAdded\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rate\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"available\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"startTimestamp\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"endTimestamp\",\"type\":\"uint256\"}],\"name\":\"emitRewardInitialized\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rate\",\"type\":\"uint256\"}],\"name\":\"emitRewardRateChanged\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"operator\",\"type\":\"address[]\"},{\"internalType\":\"uint256[]\",\"name\":\"slashedBaseRewards\",\"type\":\"uint256[]\"},{\"internalType\":\"uint256[]\",\"name\":\"slashedDelegatedRewards\",\"type\":\"uint256[]\"}],\"name\":\"emitRewardSlashed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"emitRewardWithdrawn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"newStake\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"totalStake\",\"type\":\"uint256\"}],\"name\":\"emitStaked\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"emitUnpaused\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"staker\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"principal\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"baseReward\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"delegationReward\",\"type\":\"uint256\"}],\"name\":\"emitUnstaked\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610f7b806100206000396000f3fe608060405234801561001057600080fd5b50600436106101985760003560e01c80639ec3ce4b116100e3578063b019b4e81161008c578063f7420bc211610066578063f7420bc214610318578063fa2d7fd01461032b578063fe60093f1461033e57600080fd5b8063b019b4e8146102df578063e0275fae146102f2578063eb6289de1461030557600080fd5b8063ab8711bc116100bd578063ab8711bc146102b1578063add49a96146102c4578063aeac9600146102cc57600080fd5b80639ec3ce4b146102785780639f676e9f1461028b578063a5f3d6831461029e57600080fd5b80637be5c756116101455780639a8d2df71161011f5780639a8d2df71461023f5780639b022d73146102525780639e81ace31461026557600080fd5b80637be5c756146102065780637e31a64b146102195780639652ab7b1461022c57600080fd5b80632752e639116101765780632752e639146101d85780633e8f1e05146101eb5780635d21e09a146101f357600080fd5b8063086c1c4a1461019d5780631351da48146101b257806313c664e8146101c5575b600080fd5b6101b06101ab366004610b25565b610351565b005b6101b06101c0366004610a73565b6103b6565b6101b06101d3366004610d04565b610403565b6101b06101e6366004610b5e565b610433565b6101b0610479565b6101b0610201366004610d04565b6104a4565b6101b0610214366004610a73565b6104d4565b6101b0610227366004610d04565b61051a565b6101b061023a366004610a73565b61054a565b6101b061024d366004610a73565b610590565b6101b0610260366004610d04565b6105d6565b6101b0610273366004610c7c565b610606565b6101b0610286366004610a73565b610645565b6101b0610299366004610d1d565b61068b565b6101b06102ac366004610c3f565b6106d0565b6101b06102bf366004610af2565b6106ff565b6101b0610753565b6101b06102da366004610d04565b61077e565b6101b06102ed366004610a95565b6107ae565b6101b0610300366004610af2565b61080c565b6101b0610313366004610ac8565b610860565b6101b0610326366004610a95565b6108b3565b6101b0610339366004610d04565b610911565b6101b061034c366004610d04565b610941565b6040805173ffffffffffffffffffffffffffffffffffffffff8616815260208101859052908101839052606081018290527f204fccf0d92ed8d48f204adb39b2e81e92bad0dedb93f5716ca9478cfb57de00906080015b60405180910390a150505050565b60405173ffffffffffffffffffffffffffffffffffffffff821681527fac6fa858e9350a46cec16539926e0fde25b7629f84b5a72bffaae4df888ae86d906020015b60405180910390a150565b6040518181527f816587cb2e773af4f3689a03d7520fabff3462605ded374b485b13994c0d7b52906020016103f8565b7f667838b33bdc898470de09e0e746990f2adc11b965b7fe6828e502ebc39e0434858585858560405161046a959493929190610dd0565b60405180910390a15050505050565b6040517fded6ebf04e261e1eb2f3e3b268a2e6aee5b478c15b341eba5cf18b9bc80c2e6390600090a1565b6040518181527fde88a922e0d3b88b24e9623efeb464919c6bf9f66857a65e2bfcf2ce87a9433d906020016103f8565b60405173ffffffffffffffffffffffffffffffffffffffff821681527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258906020016103f8565b6040518181527fb5f554e5ef00806bace1edbb84186512ebcefa2af7706085143f501f29314df7906020016103f8565b60405173ffffffffffffffffffffffffffffffffffffffff821681527ffa33c052bbee754f3c0482a89962daffe749191fa33c696a61e947fbfd68bd84906020016103f8565b60405173ffffffffffffffffffffffffffffffffffffffff821681527f5c74c441be501340b2713817a6c6975e6f3d4a4ae39fa1ac0bf75d3c54a0cad3906020016103f8565b6040518181527f7f4f497e086b2eb55f8a9885ba00d33399bbe0ebcb92ea092834386435a1b9c0906020016103f8565b7e635ea9da6e262e92bb713d71840af7c567807ff35bf73e927490c61283248083838360405161063893929190610e89565b60405180910390a1505050565b60405173ffffffffffffffffffffffffffffffffffffffff821681527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020016103f8565b6040805185815260208101859052908101839052606081018290527f125fc8494f786b470e3c39d0932a62e9e09e291ebd81ea19c57604f6d2b1d167906080016103a8565b7f40aed8e423b39a56b445ae160f4c071fc2cfb48ee0b6dcd5ffeb6bc5b18d10d0816040516103f89190610e76565b6040805173ffffffffffffffffffffffffffffffffffffffff85168152602081018490529081018290527f1449c6dd7851abc30abf37f57715f492010519147cc2652fbc38202c18a6ee9090606001610638565b6040517ff7d0e0f15586495da8c687328ead30fb829d9da55538cb0ef73dd229e517cdb890600090a1565b6040518181527f1b930366dfeaa7eb3b325021e4ae81e36527063452ee55b86c95f85b36f4c31c906020016103f8565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6040805173ffffffffffffffffffffffffffffffffffffffff85168152602081018490529081018290527fd2720e8f454493f612cc97499fe8cbce7fa4d4c18d346fe7104e9042df1c1edd90606001610638565b6040805173ffffffffffffffffffffffffffffffffffffffff84168152602081018390527f2360404a74478febece1a14f11275f22ada88d19ef96f7d785913010bfff4479910160405180910390a15050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a35050565b6040518181527f150a6ec0e6f4e9ddcaaaa1674f157d91165a42d60653016f87a9fc870a39f050906020016103f8565b6040518181527f1e3be2efa25bca5bff2215c7b30b31086e703d6aa7d9b9a1f8ba62c5291219ad906020016103f8565b803573ffffffffffffffffffffffffffffffffffffffff8116811461099557600080fd5b919050565b600082601f8301126109ab57600080fd5b813560206109c06109bb83610f1b565b610ecc565b80838252828201915082860187848660051b89010111156109e057600080fd5b60005b85811015610a06576109f482610971565b845292840192908401906001016109e3565b5090979650505050505050565b600082601f830112610a2457600080fd5b81356020610a346109bb83610f1b565b80838252828201915082860187848660051b8901011115610a5457600080fd5b60005b85811015610a0657813584529284019290840190600101610a57565b600060208284031215610a8557600080fd5b610a8e82610971565b9392505050565b60008060408385031215610aa857600080fd5b610ab183610971565b9150610abf60208401610971565b90509250929050565b60008060408385031215610adb57600080fd5b610ae483610971565b946020939093013593505050565b600080600060608486031215610b0757600080fd5b610b1084610971565b95602085013595506040909401359392505050565b60008060008060808587031215610b3b57600080fd5b610b4485610971565b966020860135965060408601359560600135945092505050565b600080600080600060a08688031215610b7657600080fd5b610b7f86610971565b945060208087013594506040870135935060608701359250608087013567ffffffffffffffff80821115610bb257600080fd5b818901915089601f830112610bc657600080fd5b813581811115610bd857610bd8610f3f565b610c08847fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610ecc565b91508082528a84828501011115610c1e57600080fd5b80848401858401376000848284010152508093505050509295509295909350565b600060208284031215610c5157600080fd5b813567ffffffffffffffff811115610c6857600080fd5b610c748482850161099a565b949350505050565b600080600060608486031215610c9157600080fd5b833567ffffffffffffffff80821115610ca957600080fd5b610cb58783880161099a565b94506020860135915080821115610ccb57600080fd5b610cd787838801610a13565b93506040860135915080821115610ced57600080fd5b50610cfa86828701610a13565b9150509250925092565b600060208284031215610d1657600080fd5b5035919050565b60008060008060808587031215610d3357600080fd5b5050823594602084013594506040840135936060013592509050565b600081518084526020808501945080840160005b83811015610d9557815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101610d63565b509495945050505050565b600081518084526020808501945080840160005b83811015610d9557815187529582019590820190600101610db4565b73ffffffffffffffffffffffffffffffffffffffff8616815260006020868184015285604084015284606084015260a0608084015283518060a085015260005b81811015610e2c5785810183015185820160c001528201610e10565b81811115610e3e57600060c083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160c001979650505050505050565b602081526000610a8e6020830184610d4f565b606081526000610e9c6060830186610d4f565b8281036020840152610eae8186610da0565b90508281036040840152610ec28185610da0565b9695505050505050565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610f1357610f13610f3f565b604052919050565b600067ffffffffffffffff821115610f3557610f35610f3f565b5060051b60200190565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var StakingEventsMockABI = StakingEventsMockMetaData.ABI + +var StakingEventsMockBin = StakingEventsMockMetaData.Bin + +func DeployStakingEventsMock(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *StakingEventsMock, error) { + parsed, err := StakingEventsMockMetaData.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(StakingEventsMockBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &StakingEventsMock{StakingEventsMockCaller: StakingEventsMockCaller{contract: contract}, StakingEventsMockTransactor: StakingEventsMockTransactor{contract: contract}, StakingEventsMockFilterer: StakingEventsMockFilterer{contract: contract}}, nil +} + +type StakingEventsMock struct { + address common.Address + abi abi.ABI + StakingEventsMockCaller + StakingEventsMockTransactor + StakingEventsMockFilterer +} + +type StakingEventsMockCaller struct { + contract *bind.BoundContract +} + +type StakingEventsMockTransactor struct { + contract *bind.BoundContract +} + +type StakingEventsMockFilterer struct { + contract *bind.BoundContract +} + +type StakingEventsMockSession struct { + Contract *StakingEventsMock + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type StakingEventsMockCallerSession struct { + Contract *StakingEventsMockCaller + CallOpts bind.CallOpts +} + +type StakingEventsMockTransactorSession struct { + Contract *StakingEventsMockTransactor + TransactOpts bind.TransactOpts +} + +type StakingEventsMockRaw struct { + Contract *StakingEventsMock +} + +type StakingEventsMockCallerRaw struct { + Contract *StakingEventsMockCaller +} + +type StakingEventsMockTransactorRaw struct { + Contract *StakingEventsMockTransactor +} + +func NewStakingEventsMock(address common.Address, backend bind.ContractBackend) (*StakingEventsMock, error) { + abi, err := abi.JSON(strings.NewReader(StakingEventsMockABI)) + if err != nil { + return nil, err + } + contract, err := bindStakingEventsMock(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &StakingEventsMock{address: address, abi: abi, StakingEventsMockCaller: StakingEventsMockCaller{contract: contract}, StakingEventsMockTransactor: StakingEventsMockTransactor{contract: contract}, StakingEventsMockFilterer: StakingEventsMockFilterer{contract: contract}}, nil +} + +func NewStakingEventsMockCaller(address common.Address, caller bind.ContractCaller) (*StakingEventsMockCaller, error) { + contract, err := bindStakingEventsMock(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &StakingEventsMockCaller{contract: contract}, nil +} + +func NewStakingEventsMockTransactor(address common.Address, transactor bind.ContractTransactor) (*StakingEventsMockTransactor, error) { + contract, err := bindStakingEventsMock(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &StakingEventsMockTransactor{contract: contract}, nil +} + +func NewStakingEventsMockFilterer(address common.Address, filterer bind.ContractFilterer) (*StakingEventsMockFilterer, error) { + contract, err := bindStakingEventsMock(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &StakingEventsMockFilterer{contract: contract}, nil +} + +func bindStakingEventsMock(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := StakingEventsMockMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_StakingEventsMock *StakingEventsMockRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _StakingEventsMock.Contract.StakingEventsMockCaller.contract.Call(opts, result, method, params...) +} + +func (_StakingEventsMock *StakingEventsMockRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _StakingEventsMock.Contract.StakingEventsMockTransactor.contract.Transfer(opts) +} + +func (_StakingEventsMock *StakingEventsMockRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _StakingEventsMock.Contract.StakingEventsMockTransactor.contract.Transact(opts, method, params...) +} + +func (_StakingEventsMock *StakingEventsMockCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _StakingEventsMock.Contract.contract.Call(opts, result, method, params...) +} + +func (_StakingEventsMock *StakingEventsMockTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _StakingEventsMock.Contract.contract.Transfer(opts) +} + +func (_StakingEventsMock *StakingEventsMockTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _StakingEventsMock.Contract.contract.Transact(opts, method, params...) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitAlertRaised(opts *bind.TransactOpts, alerter common.Address, roundId *big.Int, rewardAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitAlertRaised", alerter, roundId, rewardAmount) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitAlertRaised(alerter common.Address, roundId *big.Int, rewardAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitAlertRaised(&_StakingEventsMock.TransactOpts, alerter, roundId, rewardAmount) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitAlertRaised(alerter common.Address, roundId *big.Int, rewardAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitAlertRaised(&_StakingEventsMock.TransactOpts, alerter, roundId, rewardAmount) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitFeedOperatorsSet(opts *bind.TransactOpts, feedOperators []common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitFeedOperatorsSet", feedOperators) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitFeedOperatorsSet(feedOperators []common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitFeedOperatorsSet(&_StakingEventsMock.TransactOpts, feedOperators) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitFeedOperatorsSet(feedOperators []common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitFeedOperatorsSet(&_StakingEventsMock.TransactOpts, feedOperators) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitMaxCommunityStakeAmountIncreased(opts *bind.TransactOpts, maxStakeAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitMaxCommunityStakeAmountIncreased", maxStakeAmount) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitMaxCommunityStakeAmountIncreased(maxStakeAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMaxCommunityStakeAmountIncreased(&_StakingEventsMock.TransactOpts, maxStakeAmount) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitMaxCommunityStakeAmountIncreased(maxStakeAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMaxCommunityStakeAmountIncreased(&_StakingEventsMock.TransactOpts, maxStakeAmount) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitMaxOperatorStakeAmountIncreased(opts *bind.TransactOpts, maxStakeAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitMaxOperatorStakeAmountIncreased", maxStakeAmount) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitMaxOperatorStakeAmountIncreased(maxStakeAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMaxOperatorStakeAmountIncreased(&_StakingEventsMock.TransactOpts, maxStakeAmount) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitMaxOperatorStakeAmountIncreased(maxStakeAmount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMaxOperatorStakeAmountIncreased(&_StakingEventsMock.TransactOpts, maxStakeAmount) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitMerkleRootChanged(opts *bind.TransactOpts, newMerkleRoot [32]byte) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitMerkleRootChanged", newMerkleRoot) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitMerkleRootChanged(newMerkleRoot [32]byte) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMerkleRootChanged(&_StakingEventsMock.TransactOpts, newMerkleRoot) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitMerkleRootChanged(newMerkleRoot [32]byte) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMerkleRootChanged(&_StakingEventsMock.TransactOpts, newMerkleRoot) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitMigrated(opts *bind.TransactOpts, staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int, data []byte) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitMigrated", staker, principal, baseReward, delegationReward, data) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitMigrated(staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int, data []byte) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMigrated(&_StakingEventsMock.TransactOpts, staker, principal, baseReward, delegationReward, data) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitMigrated(staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int, data []byte) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMigrated(&_StakingEventsMock.TransactOpts, staker, principal, baseReward, delegationReward, data) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitMigrationTargetAccepted(opts *bind.TransactOpts, migrationTarget common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitMigrationTargetAccepted", migrationTarget) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitMigrationTargetAccepted(migrationTarget common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMigrationTargetAccepted(&_StakingEventsMock.TransactOpts, migrationTarget) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitMigrationTargetAccepted(migrationTarget common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMigrationTargetAccepted(&_StakingEventsMock.TransactOpts, migrationTarget) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitMigrationTargetProposed(opts *bind.TransactOpts, migrationTarget common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitMigrationTargetProposed", migrationTarget) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitMigrationTargetProposed(migrationTarget common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMigrationTargetProposed(&_StakingEventsMock.TransactOpts, migrationTarget) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitMigrationTargetProposed(migrationTarget common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitMigrationTargetProposed(&_StakingEventsMock.TransactOpts, migrationTarget) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitOperatorAdded(opts *bind.TransactOpts, operator common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitOperatorAdded", operator) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitOperatorAdded(operator common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOperatorAdded(&_StakingEventsMock.TransactOpts, operator) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitOperatorAdded(operator common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOperatorAdded(&_StakingEventsMock.TransactOpts, operator) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitOperatorRemoved(opts *bind.TransactOpts, operator common.Address, amount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitOperatorRemoved", operator, amount) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitOperatorRemoved(operator common.Address, amount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOperatorRemoved(&_StakingEventsMock.TransactOpts, operator, amount) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitOperatorRemoved(operator common.Address, amount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOperatorRemoved(&_StakingEventsMock.TransactOpts, operator, amount) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitOwnershipTransferRequested", from, to) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOwnershipTransferRequested(&_StakingEventsMock.TransactOpts, from, to) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOwnershipTransferRequested(&_StakingEventsMock.TransactOpts, from, to) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitOwnershipTransferred", from, to) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOwnershipTransferred(&_StakingEventsMock.TransactOpts, from, to) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitOwnershipTransferred(&_StakingEventsMock.TransactOpts, from, to) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitPaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitPaused", account) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitPaused(account common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPaused(&_StakingEventsMock.TransactOpts, account) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitPaused(account common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPaused(&_StakingEventsMock.TransactOpts, account) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitPoolConcluded(opts *bind.TransactOpts) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitPoolConcluded") +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitPoolConcluded() (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPoolConcluded(&_StakingEventsMock.TransactOpts) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitPoolConcluded() (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPoolConcluded(&_StakingEventsMock.TransactOpts) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitPoolOpened(opts *bind.TransactOpts) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitPoolOpened") +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitPoolOpened() (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPoolOpened(&_StakingEventsMock.TransactOpts) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitPoolOpened() (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPoolOpened(&_StakingEventsMock.TransactOpts) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitPoolSizeIncreased(opts *bind.TransactOpts, maxPoolSize *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitPoolSizeIncreased", maxPoolSize) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitPoolSizeIncreased(maxPoolSize *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPoolSizeIncreased(&_StakingEventsMock.TransactOpts, maxPoolSize) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitPoolSizeIncreased(maxPoolSize *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitPoolSizeIncreased(&_StakingEventsMock.TransactOpts, maxPoolSize) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitRewardAdded(opts *bind.TransactOpts, amountAdded *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitRewardAdded", amountAdded) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitRewardAdded(amountAdded *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardAdded(&_StakingEventsMock.TransactOpts, amountAdded) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitRewardAdded(amountAdded *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardAdded(&_StakingEventsMock.TransactOpts, amountAdded) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitRewardInitialized(opts *bind.TransactOpts, rate *big.Int, available *big.Int, startTimestamp *big.Int, endTimestamp *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitRewardInitialized", rate, available, startTimestamp, endTimestamp) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitRewardInitialized(rate *big.Int, available *big.Int, startTimestamp *big.Int, endTimestamp *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardInitialized(&_StakingEventsMock.TransactOpts, rate, available, startTimestamp, endTimestamp) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitRewardInitialized(rate *big.Int, available *big.Int, startTimestamp *big.Int, endTimestamp *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardInitialized(&_StakingEventsMock.TransactOpts, rate, available, startTimestamp, endTimestamp) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitRewardRateChanged(opts *bind.TransactOpts, rate *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitRewardRateChanged", rate) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitRewardRateChanged(rate *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardRateChanged(&_StakingEventsMock.TransactOpts, rate) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitRewardRateChanged(rate *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardRateChanged(&_StakingEventsMock.TransactOpts, rate) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitRewardSlashed(opts *bind.TransactOpts, operator []common.Address, slashedBaseRewards []*big.Int, slashedDelegatedRewards []*big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitRewardSlashed", operator, slashedBaseRewards, slashedDelegatedRewards) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitRewardSlashed(operator []common.Address, slashedBaseRewards []*big.Int, slashedDelegatedRewards []*big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardSlashed(&_StakingEventsMock.TransactOpts, operator, slashedBaseRewards, slashedDelegatedRewards) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitRewardSlashed(operator []common.Address, slashedBaseRewards []*big.Int, slashedDelegatedRewards []*big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardSlashed(&_StakingEventsMock.TransactOpts, operator, slashedBaseRewards, slashedDelegatedRewards) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitRewardWithdrawn(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitRewardWithdrawn", amount) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitRewardWithdrawn(amount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardWithdrawn(&_StakingEventsMock.TransactOpts, amount) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitRewardWithdrawn(amount *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitRewardWithdrawn(&_StakingEventsMock.TransactOpts, amount) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitStaked(opts *bind.TransactOpts, staker common.Address, newStake *big.Int, totalStake *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitStaked", staker, newStake, totalStake) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitStaked(staker common.Address, newStake *big.Int, totalStake *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitStaked(&_StakingEventsMock.TransactOpts, staker, newStake, totalStake) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitStaked(staker common.Address, newStake *big.Int, totalStake *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitStaked(&_StakingEventsMock.TransactOpts, staker, newStake, totalStake) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitUnpaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitUnpaused", account) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitUnpaused(account common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitUnpaused(&_StakingEventsMock.TransactOpts, account) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitUnpaused(account common.Address) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitUnpaused(&_StakingEventsMock.TransactOpts, account) +} + +func (_StakingEventsMock *StakingEventsMockTransactor) EmitUnstaked(opts *bind.TransactOpts, staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.contract.Transact(opts, "emitUnstaked", staker, principal, baseReward, delegationReward) +} + +func (_StakingEventsMock *StakingEventsMockSession) EmitUnstaked(staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitUnstaked(&_StakingEventsMock.TransactOpts, staker, principal, baseReward, delegationReward) +} + +func (_StakingEventsMock *StakingEventsMockTransactorSession) EmitUnstaked(staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int) (*types.Transaction, error) { + return _StakingEventsMock.Contract.EmitUnstaked(&_StakingEventsMock.TransactOpts, staker, principal, baseReward, delegationReward) +} + +type StakingEventsMockAlertRaisedIterator struct { + Event *StakingEventsMockAlertRaised + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockAlertRaisedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockAlertRaised) + 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(StakingEventsMockAlertRaised) + 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 *StakingEventsMockAlertRaisedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockAlertRaisedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockAlertRaised struct { + Alerter common.Address + RoundId *big.Int + RewardAmount *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterAlertRaised(opts *bind.FilterOpts) (*StakingEventsMockAlertRaisedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "AlertRaised") + if err != nil { + return nil, err + } + return &StakingEventsMockAlertRaisedIterator{contract: _StakingEventsMock.contract, event: "AlertRaised", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchAlertRaised(opts *bind.WatchOpts, sink chan<- *StakingEventsMockAlertRaised) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "AlertRaised") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockAlertRaised) + if err := _StakingEventsMock.contract.UnpackLog(event, "AlertRaised", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseAlertRaised(log types.Log) (*StakingEventsMockAlertRaised, error) { + event := new(StakingEventsMockAlertRaised) + if err := _StakingEventsMock.contract.UnpackLog(event, "AlertRaised", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockFeedOperatorsSetIterator struct { + Event *StakingEventsMockFeedOperatorsSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockFeedOperatorsSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockFeedOperatorsSet) + 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(StakingEventsMockFeedOperatorsSet) + 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 *StakingEventsMockFeedOperatorsSetIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockFeedOperatorsSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockFeedOperatorsSet struct { + FeedOperators []common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterFeedOperatorsSet(opts *bind.FilterOpts) (*StakingEventsMockFeedOperatorsSetIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "FeedOperatorsSet") + if err != nil { + return nil, err + } + return &StakingEventsMockFeedOperatorsSetIterator{contract: _StakingEventsMock.contract, event: "FeedOperatorsSet", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchFeedOperatorsSet(opts *bind.WatchOpts, sink chan<- *StakingEventsMockFeedOperatorsSet) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "FeedOperatorsSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockFeedOperatorsSet) + if err := _StakingEventsMock.contract.UnpackLog(event, "FeedOperatorsSet", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseFeedOperatorsSet(log types.Log) (*StakingEventsMockFeedOperatorsSet, error) { + event := new(StakingEventsMockFeedOperatorsSet) + if err := _StakingEventsMock.contract.UnpackLog(event, "FeedOperatorsSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockMaxCommunityStakeAmountIncreasedIterator struct { + Event *StakingEventsMockMaxCommunityStakeAmountIncreased + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockMaxCommunityStakeAmountIncreasedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockMaxCommunityStakeAmountIncreased) + 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(StakingEventsMockMaxCommunityStakeAmountIncreased) + 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 *StakingEventsMockMaxCommunityStakeAmountIncreasedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockMaxCommunityStakeAmountIncreasedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockMaxCommunityStakeAmountIncreased struct { + MaxStakeAmount *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterMaxCommunityStakeAmountIncreased(opts *bind.FilterOpts) (*StakingEventsMockMaxCommunityStakeAmountIncreasedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "MaxCommunityStakeAmountIncreased") + if err != nil { + return nil, err + } + return &StakingEventsMockMaxCommunityStakeAmountIncreasedIterator{contract: _StakingEventsMock.contract, event: "MaxCommunityStakeAmountIncreased", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchMaxCommunityStakeAmountIncreased(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMaxCommunityStakeAmountIncreased) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "MaxCommunityStakeAmountIncreased") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockMaxCommunityStakeAmountIncreased) + if err := _StakingEventsMock.contract.UnpackLog(event, "MaxCommunityStakeAmountIncreased", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseMaxCommunityStakeAmountIncreased(log types.Log) (*StakingEventsMockMaxCommunityStakeAmountIncreased, error) { + event := new(StakingEventsMockMaxCommunityStakeAmountIncreased) + if err := _StakingEventsMock.contract.UnpackLog(event, "MaxCommunityStakeAmountIncreased", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockMaxOperatorStakeAmountIncreasedIterator struct { + Event *StakingEventsMockMaxOperatorStakeAmountIncreased + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockMaxOperatorStakeAmountIncreasedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockMaxOperatorStakeAmountIncreased) + 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(StakingEventsMockMaxOperatorStakeAmountIncreased) + 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 *StakingEventsMockMaxOperatorStakeAmountIncreasedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockMaxOperatorStakeAmountIncreasedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockMaxOperatorStakeAmountIncreased struct { + MaxStakeAmount *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterMaxOperatorStakeAmountIncreased(opts *bind.FilterOpts) (*StakingEventsMockMaxOperatorStakeAmountIncreasedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "MaxOperatorStakeAmountIncreased") + if err != nil { + return nil, err + } + return &StakingEventsMockMaxOperatorStakeAmountIncreasedIterator{contract: _StakingEventsMock.contract, event: "MaxOperatorStakeAmountIncreased", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchMaxOperatorStakeAmountIncreased(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMaxOperatorStakeAmountIncreased) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "MaxOperatorStakeAmountIncreased") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockMaxOperatorStakeAmountIncreased) + if err := _StakingEventsMock.contract.UnpackLog(event, "MaxOperatorStakeAmountIncreased", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseMaxOperatorStakeAmountIncreased(log types.Log) (*StakingEventsMockMaxOperatorStakeAmountIncreased, error) { + event := new(StakingEventsMockMaxOperatorStakeAmountIncreased) + if err := _StakingEventsMock.contract.UnpackLog(event, "MaxOperatorStakeAmountIncreased", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockMerkleRootChangedIterator struct { + Event *StakingEventsMockMerkleRootChanged + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockMerkleRootChangedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockMerkleRootChanged) + 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(StakingEventsMockMerkleRootChanged) + 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 *StakingEventsMockMerkleRootChangedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockMerkleRootChangedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockMerkleRootChanged struct { + NewMerkleRoot [32]byte + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterMerkleRootChanged(opts *bind.FilterOpts) (*StakingEventsMockMerkleRootChangedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "MerkleRootChanged") + if err != nil { + return nil, err + } + return &StakingEventsMockMerkleRootChangedIterator{contract: _StakingEventsMock.contract, event: "MerkleRootChanged", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchMerkleRootChanged(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMerkleRootChanged) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "MerkleRootChanged") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockMerkleRootChanged) + if err := _StakingEventsMock.contract.UnpackLog(event, "MerkleRootChanged", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseMerkleRootChanged(log types.Log) (*StakingEventsMockMerkleRootChanged, error) { + event := new(StakingEventsMockMerkleRootChanged) + if err := _StakingEventsMock.contract.UnpackLog(event, "MerkleRootChanged", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockMigratedIterator struct { + Event *StakingEventsMockMigrated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockMigratedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockMigrated) + 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(StakingEventsMockMigrated) + 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 *StakingEventsMockMigratedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockMigratedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockMigrated struct { + Staker common.Address + Principal *big.Int + BaseReward *big.Int + DelegationReward *big.Int + Data []byte + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterMigrated(opts *bind.FilterOpts) (*StakingEventsMockMigratedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "Migrated") + if err != nil { + return nil, err + } + return &StakingEventsMockMigratedIterator{contract: _StakingEventsMock.contract, event: "Migrated", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchMigrated(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMigrated) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "Migrated") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockMigrated) + if err := _StakingEventsMock.contract.UnpackLog(event, "Migrated", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseMigrated(log types.Log) (*StakingEventsMockMigrated, error) { + event := new(StakingEventsMockMigrated) + if err := _StakingEventsMock.contract.UnpackLog(event, "Migrated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockMigrationTargetAcceptedIterator struct { + Event *StakingEventsMockMigrationTargetAccepted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockMigrationTargetAcceptedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockMigrationTargetAccepted) + 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(StakingEventsMockMigrationTargetAccepted) + 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 *StakingEventsMockMigrationTargetAcceptedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockMigrationTargetAcceptedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockMigrationTargetAccepted struct { + MigrationTarget common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterMigrationTargetAccepted(opts *bind.FilterOpts) (*StakingEventsMockMigrationTargetAcceptedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "MigrationTargetAccepted") + if err != nil { + return nil, err + } + return &StakingEventsMockMigrationTargetAcceptedIterator{contract: _StakingEventsMock.contract, event: "MigrationTargetAccepted", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchMigrationTargetAccepted(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMigrationTargetAccepted) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "MigrationTargetAccepted") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockMigrationTargetAccepted) + if err := _StakingEventsMock.contract.UnpackLog(event, "MigrationTargetAccepted", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseMigrationTargetAccepted(log types.Log) (*StakingEventsMockMigrationTargetAccepted, error) { + event := new(StakingEventsMockMigrationTargetAccepted) + if err := _StakingEventsMock.contract.UnpackLog(event, "MigrationTargetAccepted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockMigrationTargetProposedIterator struct { + Event *StakingEventsMockMigrationTargetProposed + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockMigrationTargetProposedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockMigrationTargetProposed) + 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(StakingEventsMockMigrationTargetProposed) + 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 *StakingEventsMockMigrationTargetProposedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockMigrationTargetProposedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockMigrationTargetProposed struct { + MigrationTarget common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterMigrationTargetProposed(opts *bind.FilterOpts) (*StakingEventsMockMigrationTargetProposedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "MigrationTargetProposed") + if err != nil { + return nil, err + } + return &StakingEventsMockMigrationTargetProposedIterator{contract: _StakingEventsMock.contract, event: "MigrationTargetProposed", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchMigrationTargetProposed(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMigrationTargetProposed) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "MigrationTargetProposed") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockMigrationTargetProposed) + if err := _StakingEventsMock.contract.UnpackLog(event, "MigrationTargetProposed", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseMigrationTargetProposed(log types.Log) (*StakingEventsMockMigrationTargetProposed, error) { + event := new(StakingEventsMockMigrationTargetProposed) + if err := _StakingEventsMock.contract.UnpackLog(event, "MigrationTargetProposed", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockOperatorAddedIterator struct { + Event *StakingEventsMockOperatorAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockOperatorAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockOperatorAdded) + 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(StakingEventsMockOperatorAdded) + 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 *StakingEventsMockOperatorAddedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockOperatorAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockOperatorAdded struct { + Operator common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterOperatorAdded(opts *bind.FilterOpts) (*StakingEventsMockOperatorAddedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "OperatorAdded") + if err != nil { + return nil, err + } + return &StakingEventsMockOperatorAddedIterator{contract: _StakingEventsMock.contract, event: "OperatorAdded", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchOperatorAdded(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOperatorAdded) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "OperatorAdded") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockOperatorAdded) + if err := _StakingEventsMock.contract.UnpackLog(event, "OperatorAdded", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseOperatorAdded(log types.Log) (*StakingEventsMockOperatorAdded, error) { + event := new(StakingEventsMockOperatorAdded) + if err := _StakingEventsMock.contract.UnpackLog(event, "OperatorAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockOperatorRemovedIterator struct { + Event *StakingEventsMockOperatorRemoved + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockOperatorRemovedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockOperatorRemoved) + 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(StakingEventsMockOperatorRemoved) + 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 *StakingEventsMockOperatorRemovedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockOperatorRemovedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockOperatorRemoved struct { + Operator common.Address + Amount *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterOperatorRemoved(opts *bind.FilterOpts) (*StakingEventsMockOperatorRemovedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "OperatorRemoved") + if err != nil { + return nil, err + } + return &StakingEventsMockOperatorRemovedIterator{contract: _StakingEventsMock.contract, event: "OperatorRemoved", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchOperatorRemoved(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOperatorRemoved) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "OperatorRemoved") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockOperatorRemoved) + if err := _StakingEventsMock.contract.UnpackLog(event, "OperatorRemoved", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseOperatorRemoved(log types.Log) (*StakingEventsMockOperatorRemoved, error) { + event := new(StakingEventsMockOperatorRemoved) + if err := _StakingEventsMock.contract.UnpackLog(event, "OperatorRemoved", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockOwnershipTransferRequestedIterator struct { + Event *StakingEventsMockOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockOwnershipTransferRequested) + 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(StakingEventsMockOwnershipTransferRequested) + 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 *StakingEventsMockOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*StakingEventsMockOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &StakingEventsMockOwnershipTransferRequestedIterator{contract: _StakingEventsMock.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockOwnershipTransferRequested) + if err := _StakingEventsMock.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseOwnershipTransferRequested(log types.Log) (*StakingEventsMockOwnershipTransferRequested, error) { + event := new(StakingEventsMockOwnershipTransferRequested) + if err := _StakingEventsMock.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockOwnershipTransferredIterator struct { + Event *StakingEventsMockOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockOwnershipTransferred) + 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(StakingEventsMockOwnershipTransferred) + 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 *StakingEventsMockOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*StakingEventsMockOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &StakingEventsMockOwnershipTransferredIterator{contract: _StakingEventsMock.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockOwnershipTransferred) + if err := _StakingEventsMock.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 (_StakingEventsMock *StakingEventsMockFilterer) ParseOwnershipTransferred(log types.Log) (*StakingEventsMockOwnershipTransferred, error) { + event := new(StakingEventsMockOwnershipTransferred) + if err := _StakingEventsMock.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockPausedIterator struct { + Event *StakingEventsMockPaused + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockPausedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockPaused) + 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(StakingEventsMockPaused) + 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 *StakingEventsMockPausedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockPausedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockPaused struct { + Account common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterPaused(opts *bind.FilterOpts) (*StakingEventsMockPausedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "Paused") + if err != nil { + return nil, err + } + return &StakingEventsMockPausedIterator{contract: _StakingEventsMock.contract, event: "Paused", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchPaused(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPaused) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "Paused") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockPaused) + if err := _StakingEventsMock.contract.UnpackLog(event, "Paused", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParsePaused(log types.Log) (*StakingEventsMockPaused, error) { + event := new(StakingEventsMockPaused) + if err := _StakingEventsMock.contract.UnpackLog(event, "Paused", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockPoolConcludedIterator struct { + Event *StakingEventsMockPoolConcluded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockPoolConcludedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockPoolConcluded) + 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(StakingEventsMockPoolConcluded) + 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 *StakingEventsMockPoolConcludedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockPoolConcludedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockPoolConcluded struct { + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterPoolConcluded(opts *bind.FilterOpts) (*StakingEventsMockPoolConcludedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "PoolConcluded") + if err != nil { + return nil, err + } + return &StakingEventsMockPoolConcludedIterator{contract: _StakingEventsMock.contract, event: "PoolConcluded", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchPoolConcluded(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPoolConcluded) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "PoolConcluded") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockPoolConcluded) + if err := _StakingEventsMock.contract.UnpackLog(event, "PoolConcluded", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParsePoolConcluded(log types.Log) (*StakingEventsMockPoolConcluded, error) { + event := new(StakingEventsMockPoolConcluded) + if err := _StakingEventsMock.contract.UnpackLog(event, "PoolConcluded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockPoolOpenedIterator struct { + Event *StakingEventsMockPoolOpened + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockPoolOpenedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockPoolOpened) + 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(StakingEventsMockPoolOpened) + 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 *StakingEventsMockPoolOpenedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockPoolOpenedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockPoolOpened struct { + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterPoolOpened(opts *bind.FilterOpts) (*StakingEventsMockPoolOpenedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "PoolOpened") + if err != nil { + return nil, err + } + return &StakingEventsMockPoolOpenedIterator{contract: _StakingEventsMock.contract, event: "PoolOpened", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchPoolOpened(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPoolOpened) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "PoolOpened") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockPoolOpened) + if err := _StakingEventsMock.contract.UnpackLog(event, "PoolOpened", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParsePoolOpened(log types.Log) (*StakingEventsMockPoolOpened, error) { + event := new(StakingEventsMockPoolOpened) + if err := _StakingEventsMock.contract.UnpackLog(event, "PoolOpened", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockPoolSizeIncreasedIterator struct { + Event *StakingEventsMockPoolSizeIncreased + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockPoolSizeIncreasedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockPoolSizeIncreased) + 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(StakingEventsMockPoolSizeIncreased) + 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 *StakingEventsMockPoolSizeIncreasedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockPoolSizeIncreasedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockPoolSizeIncreased struct { + MaxPoolSize *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterPoolSizeIncreased(opts *bind.FilterOpts) (*StakingEventsMockPoolSizeIncreasedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "PoolSizeIncreased") + if err != nil { + return nil, err + } + return &StakingEventsMockPoolSizeIncreasedIterator{contract: _StakingEventsMock.contract, event: "PoolSizeIncreased", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchPoolSizeIncreased(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPoolSizeIncreased) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "PoolSizeIncreased") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockPoolSizeIncreased) + if err := _StakingEventsMock.contract.UnpackLog(event, "PoolSizeIncreased", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParsePoolSizeIncreased(log types.Log) (*StakingEventsMockPoolSizeIncreased, error) { + event := new(StakingEventsMockPoolSizeIncreased) + if err := _StakingEventsMock.contract.UnpackLog(event, "PoolSizeIncreased", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockRewardAddedIterator struct { + Event *StakingEventsMockRewardAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockRewardAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockRewardAdded) + 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(StakingEventsMockRewardAdded) + 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 *StakingEventsMockRewardAddedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockRewardAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockRewardAdded struct { + AmountAdded *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterRewardAdded(opts *bind.FilterOpts) (*StakingEventsMockRewardAddedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "RewardAdded") + if err != nil { + return nil, err + } + return &StakingEventsMockRewardAddedIterator{contract: _StakingEventsMock.contract, event: "RewardAdded", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchRewardAdded(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardAdded) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "RewardAdded") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockRewardAdded) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardAdded", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseRewardAdded(log types.Log) (*StakingEventsMockRewardAdded, error) { + event := new(StakingEventsMockRewardAdded) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockRewardInitializedIterator struct { + Event *StakingEventsMockRewardInitialized + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockRewardInitializedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockRewardInitialized) + 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(StakingEventsMockRewardInitialized) + 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 *StakingEventsMockRewardInitializedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockRewardInitializedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockRewardInitialized struct { + Rate *big.Int + Available *big.Int + StartTimestamp *big.Int + EndTimestamp *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterRewardInitialized(opts *bind.FilterOpts) (*StakingEventsMockRewardInitializedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "RewardInitialized") + if err != nil { + return nil, err + } + return &StakingEventsMockRewardInitializedIterator{contract: _StakingEventsMock.contract, event: "RewardInitialized", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchRewardInitialized(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardInitialized) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "RewardInitialized") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockRewardInitialized) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardInitialized", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseRewardInitialized(log types.Log) (*StakingEventsMockRewardInitialized, error) { + event := new(StakingEventsMockRewardInitialized) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardInitialized", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockRewardRateChangedIterator struct { + Event *StakingEventsMockRewardRateChanged + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockRewardRateChangedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockRewardRateChanged) + 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(StakingEventsMockRewardRateChanged) + 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 *StakingEventsMockRewardRateChangedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockRewardRateChangedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockRewardRateChanged struct { + Rate *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterRewardRateChanged(opts *bind.FilterOpts) (*StakingEventsMockRewardRateChangedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "RewardRateChanged") + if err != nil { + return nil, err + } + return &StakingEventsMockRewardRateChangedIterator{contract: _StakingEventsMock.contract, event: "RewardRateChanged", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchRewardRateChanged(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardRateChanged) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "RewardRateChanged") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockRewardRateChanged) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardRateChanged", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseRewardRateChanged(log types.Log) (*StakingEventsMockRewardRateChanged, error) { + event := new(StakingEventsMockRewardRateChanged) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardRateChanged", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockRewardSlashedIterator struct { + Event *StakingEventsMockRewardSlashed + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockRewardSlashedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockRewardSlashed) + 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(StakingEventsMockRewardSlashed) + 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 *StakingEventsMockRewardSlashedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockRewardSlashedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockRewardSlashed struct { + Operator []common.Address + SlashedBaseRewards []*big.Int + SlashedDelegatedRewards []*big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterRewardSlashed(opts *bind.FilterOpts) (*StakingEventsMockRewardSlashedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "RewardSlashed") + if err != nil { + return nil, err + } + return &StakingEventsMockRewardSlashedIterator{contract: _StakingEventsMock.contract, event: "RewardSlashed", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchRewardSlashed(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardSlashed) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "RewardSlashed") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockRewardSlashed) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardSlashed", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseRewardSlashed(log types.Log) (*StakingEventsMockRewardSlashed, error) { + event := new(StakingEventsMockRewardSlashed) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardSlashed", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockRewardWithdrawnIterator struct { + Event *StakingEventsMockRewardWithdrawn + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockRewardWithdrawnIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockRewardWithdrawn) + 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(StakingEventsMockRewardWithdrawn) + 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 *StakingEventsMockRewardWithdrawnIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockRewardWithdrawnIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockRewardWithdrawn struct { + Amount *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterRewardWithdrawn(opts *bind.FilterOpts) (*StakingEventsMockRewardWithdrawnIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "RewardWithdrawn") + if err != nil { + return nil, err + } + return &StakingEventsMockRewardWithdrawnIterator{contract: _StakingEventsMock.contract, event: "RewardWithdrawn", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchRewardWithdrawn(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardWithdrawn) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "RewardWithdrawn") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockRewardWithdrawn) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardWithdrawn", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseRewardWithdrawn(log types.Log) (*StakingEventsMockRewardWithdrawn, error) { + event := new(StakingEventsMockRewardWithdrawn) + if err := _StakingEventsMock.contract.UnpackLog(event, "RewardWithdrawn", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockStakedIterator struct { + Event *StakingEventsMockStaked + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockStakedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockStaked) + 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(StakingEventsMockStaked) + 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 *StakingEventsMockStakedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockStakedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockStaked struct { + Staker common.Address + NewStake *big.Int + TotalStake *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterStaked(opts *bind.FilterOpts) (*StakingEventsMockStakedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "Staked") + if err != nil { + return nil, err + } + return &StakingEventsMockStakedIterator{contract: _StakingEventsMock.contract, event: "Staked", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchStaked(opts *bind.WatchOpts, sink chan<- *StakingEventsMockStaked) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "Staked") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockStaked) + if err := _StakingEventsMock.contract.UnpackLog(event, "Staked", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseStaked(log types.Log) (*StakingEventsMockStaked, error) { + event := new(StakingEventsMockStaked) + if err := _StakingEventsMock.contract.UnpackLog(event, "Staked", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockUnpausedIterator struct { + Event *StakingEventsMockUnpaused + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockUnpausedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockUnpaused) + 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(StakingEventsMockUnpaused) + 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 *StakingEventsMockUnpausedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockUnpausedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockUnpaused struct { + Account common.Address + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterUnpaused(opts *bind.FilterOpts) (*StakingEventsMockUnpausedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "Unpaused") + if err != nil { + return nil, err + } + return &StakingEventsMockUnpausedIterator{contract: _StakingEventsMock.contract, event: "Unpaused", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *StakingEventsMockUnpaused) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.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(StakingEventsMockUnpaused) + if err := _StakingEventsMock.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 (_StakingEventsMock *StakingEventsMockFilterer) ParseUnpaused(log types.Log) (*StakingEventsMockUnpaused, error) { + event := new(StakingEventsMockUnpaused) + if err := _StakingEventsMock.contract.UnpackLog(event, "Unpaused", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type StakingEventsMockUnstakedIterator struct { + Event *StakingEventsMockUnstaked + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *StakingEventsMockUnstakedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(StakingEventsMockUnstaked) + 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(StakingEventsMockUnstaked) + 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 *StakingEventsMockUnstakedIterator) Error() error { + return it.fail +} + +func (it *StakingEventsMockUnstakedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type StakingEventsMockUnstaked struct { + Staker common.Address + Principal *big.Int + BaseReward *big.Int + DelegationReward *big.Int + Raw types.Log +} + +func (_StakingEventsMock *StakingEventsMockFilterer) FilterUnstaked(opts *bind.FilterOpts) (*StakingEventsMockUnstakedIterator, error) { + + logs, sub, err := _StakingEventsMock.contract.FilterLogs(opts, "Unstaked") + if err != nil { + return nil, err + } + return &StakingEventsMockUnstakedIterator{contract: _StakingEventsMock.contract, event: "Unstaked", logs: logs, sub: sub}, nil +} + +func (_StakingEventsMock *StakingEventsMockFilterer) WatchUnstaked(opts *bind.WatchOpts, sink chan<- *StakingEventsMockUnstaked) (event.Subscription, error) { + + logs, sub, err := _StakingEventsMock.contract.WatchLogs(opts, "Unstaked") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(StakingEventsMockUnstaked) + if err := _StakingEventsMock.contract.UnpackLog(event, "Unstaked", 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 (_StakingEventsMock *StakingEventsMockFilterer) ParseUnstaked(log types.Log) (*StakingEventsMockUnstaked, error) { + event := new(StakingEventsMockUnstaked) + if err := _StakingEventsMock.contract.UnpackLog(event, "Unstaked", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_StakingEventsMock *StakingEventsMock) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _StakingEventsMock.abi.Events["AlertRaised"].ID: + return _StakingEventsMock.ParseAlertRaised(log) + case _StakingEventsMock.abi.Events["FeedOperatorsSet"].ID: + return _StakingEventsMock.ParseFeedOperatorsSet(log) + case _StakingEventsMock.abi.Events["MaxCommunityStakeAmountIncreased"].ID: + return _StakingEventsMock.ParseMaxCommunityStakeAmountIncreased(log) + case _StakingEventsMock.abi.Events["MaxOperatorStakeAmountIncreased"].ID: + return _StakingEventsMock.ParseMaxOperatorStakeAmountIncreased(log) + case _StakingEventsMock.abi.Events["MerkleRootChanged"].ID: + return _StakingEventsMock.ParseMerkleRootChanged(log) + case _StakingEventsMock.abi.Events["Migrated"].ID: + return _StakingEventsMock.ParseMigrated(log) + case _StakingEventsMock.abi.Events["MigrationTargetAccepted"].ID: + return _StakingEventsMock.ParseMigrationTargetAccepted(log) + case _StakingEventsMock.abi.Events["MigrationTargetProposed"].ID: + return _StakingEventsMock.ParseMigrationTargetProposed(log) + case _StakingEventsMock.abi.Events["OperatorAdded"].ID: + return _StakingEventsMock.ParseOperatorAdded(log) + case _StakingEventsMock.abi.Events["OperatorRemoved"].ID: + return _StakingEventsMock.ParseOperatorRemoved(log) + case _StakingEventsMock.abi.Events["OwnershipTransferRequested"].ID: + return _StakingEventsMock.ParseOwnershipTransferRequested(log) + case _StakingEventsMock.abi.Events["OwnershipTransferred"].ID: + return _StakingEventsMock.ParseOwnershipTransferred(log) + case _StakingEventsMock.abi.Events["Paused"].ID: + return _StakingEventsMock.ParsePaused(log) + case _StakingEventsMock.abi.Events["PoolConcluded"].ID: + return _StakingEventsMock.ParsePoolConcluded(log) + case _StakingEventsMock.abi.Events["PoolOpened"].ID: + return _StakingEventsMock.ParsePoolOpened(log) + case _StakingEventsMock.abi.Events["PoolSizeIncreased"].ID: + return _StakingEventsMock.ParsePoolSizeIncreased(log) + case _StakingEventsMock.abi.Events["RewardAdded"].ID: + return _StakingEventsMock.ParseRewardAdded(log) + case _StakingEventsMock.abi.Events["RewardInitialized"].ID: + return _StakingEventsMock.ParseRewardInitialized(log) + case _StakingEventsMock.abi.Events["RewardRateChanged"].ID: + return _StakingEventsMock.ParseRewardRateChanged(log) + case _StakingEventsMock.abi.Events["RewardSlashed"].ID: + return _StakingEventsMock.ParseRewardSlashed(log) + case _StakingEventsMock.abi.Events["RewardWithdrawn"].ID: + return _StakingEventsMock.ParseRewardWithdrawn(log) + case _StakingEventsMock.abi.Events["Staked"].ID: + return _StakingEventsMock.ParseStaked(log) + case _StakingEventsMock.abi.Events["Unpaused"].ID: + return _StakingEventsMock.ParseUnpaused(log) + case _StakingEventsMock.abi.Events["Unstaked"].ID: + return _StakingEventsMock.ParseUnstaked(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (StakingEventsMockAlertRaised) Topic() common.Hash { + return common.HexToHash("0xd2720e8f454493f612cc97499fe8cbce7fa4d4c18d346fe7104e9042df1c1edd") +} + +func (StakingEventsMockFeedOperatorsSet) Topic() common.Hash { + return common.HexToHash("0x40aed8e423b39a56b445ae160f4c071fc2cfb48ee0b6dcd5ffeb6bc5b18d10d0") +} + +func (StakingEventsMockMaxCommunityStakeAmountIncreased) Topic() common.Hash { + return common.HexToHash("0xb5f554e5ef00806bace1edbb84186512ebcefa2af7706085143f501f29314df7") +} + +func (StakingEventsMockMaxOperatorStakeAmountIncreased) Topic() common.Hash { + return common.HexToHash("0x816587cb2e773af4f3689a03d7520fabff3462605ded374b485b13994c0d7b52") +} + +func (StakingEventsMockMerkleRootChanged) Topic() common.Hash { + return common.HexToHash("0x1b930366dfeaa7eb3b325021e4ae81e36527063452ee55b86c95f85b36f4c31c") +} + +func (StakingEventsMockMigrated) Topic() common.Hash { + return common.HexToHash("0x667838b33bdc898470de09e0e746990f2adc11b965b7fe6828e502ebc39e0434") +} + +func (StakingEventsMockMigrationTargetAccepted) Topic() common.Hash { + return common.HexToHash("0xfa33c052bbee754f3c0482a89962daffe749191fa33c696a61e947fbfd68bd84") +} + +func (StakingEventsMockMigrationTargetProposed) Topic() common.Hash { + return common.HexToHash("0x5c74c441be501340b2713817a6c6975e6f3d4a4ae39fa1ac0bf75d3c54a0cad3") +} + +func (StakingEventsMockOperatorAdded) Topic() common.Hash { + return common.HexToHash("0xac6fa858e9350a46cec16539926e0fde25b7629f84b5a72bffaae4df888ae86d") +} + +func (StakingEventsMockOperatorRemoved) Topic() common.Hash { + return common.HexToHash("0x2360404a74478febece1a14f11275f22ada88d19ef96f7d785913010bfff4479") +} + +func (StakingEventsMockOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (StakingEventsMockOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (StakingEventsMockPaused) Topic() common.Hash { + return common.HexToHash("0x62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258") +} + +func (StakingEventsMockPoolConcluded) Topic() common.Hash { + return common.HexToHash("0xf7d0e0f15586495da8c687328ead30fb829d9da55538cb0ef73dd229e517cdb8") +} + +func (StakingEventsMockPoolOpened) Topic() common.Hash { + return common.HexToHash("0xded6ebf04e261e1eb2f3e3b268a2e6aee5b478c15b341eba5cf18b9bc80c2e63") +} + +func (StakingEventsMockPoolSizeIncreased) Topic() common.Hash { + return common.HexToHash("0x7f4f497e086b2eb55f8a9885ba00d33399bbe0ebcb92ea092834386435a1b9c0") +} + +func (StakingEventsMockRewardAdded) Topic() common.Hash { + return common.HexToHash("0xde88a922e0d3b88b24e9623efeb464919c6bf9f66857a65e2bfcf2ce87a9433d") +} + +func (StakingEventsMockRewardInitialized) Topic() common.Hash { + return common.HexToHash("0x125fc8494f786b470e3c39d0932a62e9e09e291ebd81ea19c57604f6d2b1d167") +} + +func (StakingEventsMockRewardRateChanged) Topic() common.Hash { + return common.HexToHash("0x1e3be2efa25bca5bff2215c7b30b31086e703d6aa7d9b9a1f8ba62c5291219ad") +} + +func (StakingEventsMockRewardSlashed) Topic() common.Hash { + return common.HexToHash("0x00635ea9da6e262e92bb713d71840af7c567807ff35bf73e927490c612832480") +} + +func (StakingEventsMockRewardWithdrawn) Topic() common.Hash { + return common.HexToHash("0x150a6ec0e6f4e9ddcaaaa1674f157d91165a42d60653016f87a9fc870a39f050") +} + +func (StakingEventsMockStaked) Topic() common.Hash { + return common.HexToHash("0x1449c6dd7851abc30abf37f57715f492010519147cc2652fbc38202c18a6ee90") +} + +func (StakingEventsMockUnpaused) Topic() common.Hash { + return common.HexToHash("0x5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa") +} + +func (StakingEventsMockUnstaked) Topic() common.Hash { + return common.HexToHash("0x204fccf0d92ed8d48f204adb39b2e81e92bad0dedb93f5716ca9478cfb57de00") +} + +func (_StakingEventsMock *StakingEventsMock) Address() common.Address { + return _StakingEventsMock.address +} + +type StakingEventsMockInterface interface { + EmitAlertRaised(opts *bind.TransactOpts, alerter common.Address, roundId *big.Int, rewardAmount *big.Int) (*types.Transaction, error) + + EmitFeedOperatorsSet(opts *bind.TransactOpts, feedOperators []common.Address) (*types.Transaction, error) + + EmitMaxCommunityStakeAmountIncreased(opts *bind.TransactOpts, maxStakeAmount *big.Int) (*types.Transaction, error) + + EmitMaxOperatorStakeAmountIncreased(opts *bind.TransactOpts, maxStakeAmount *big.Int) (*types.Transaction, error) + + EmitMerkleRootChanged(opts *bind.TransactOpts, newMerkleRoot [32]byte) (*types.Transaction, error) + + EmitMigrated(opts *bind.TransactOpts, staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int, data []byte) (*types.Transaction, error) + + EmitMigrationTargetAccepted(opts *bind.TransactOpts, migrationTarget common.Address) (*types.Transaction, error) + + EmitMigrationTargetProposed(opts *bind.TransactOpts, migrationTarget common.Address) (*types.Transaction, error) + + EmitOperatorAdded(opts *bind.TransactOpts, operator common.Address) (*types.Transaction, error) + + EmitOperatorRemoved(opts *bind.TransactOpts, operator common.Address, amount *big.Int) (*types.Transaction, error) + + EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitPaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) + + EmitPoolConcluded(opts *bind.TransactOpts) (*types.Transaction, error) + + EmitPoolOpened(opts *bind.TransactOpts) (*types.Transaction, error) + + EmitPoolSizeIncreased(opts *bind.TransactOpts, maxPoolSize *big.Int) (*types.Transaction, error) + + EmitRewardAdded(opts *bind.TransactOpts, amountAdded *big.Int) (*types.Transaction, error) + + EmitRewardInitialized(opts *bind.TransactOpts, rate *big.Int, available *big.Int, startTimestamp *big.Int, endTimestamp *big.Int) (*types.Transaction, error) + + EmitRewardRateChanged(opts *bind.TransactOpts, rate *big.Int) (*types.Transaction, error) + + EmitRewardSlashed(opts *bind.TransactOpts, operator []common.Address, slashedBaseRewards []*big.Int, slashedDelegatedRewards []*big.Int) (*types.Transaction, error) + + EmitRewardWithdrawn(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + + EmitStaked(opts *bind.TransactOpts, staker common.Address, newStake *big.Int, totalStake *big.Int) (*types.Transaction, error) + + EmitUnpaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) + + EmitUnstaked(opts *bind.TransactOpts, staker common.Address, principal *big.Int, baseReward *big.Int, delegationReward *big.Int) (*types.Transaction, error) + + FilterAlertRaised(opts *bind.FilterOpts) (*StakingEventsMockAlertRaisedIterator, error) + + WatchAlertRaised(opts *bind.WatchOpts, sink chan<- *StakingEventsMockAlertRaised) (event.Subscription, error) + + ParseAlertRaised(log types.Log) (*StakingEventsMockAlertRaised, error) + + FilterFeedOperatorsSet(opts *bind.FilterOpts) (*StakingEventsMockFeedOperatorsSetIterator, error) + + WatchFeedOperatorsSet(opts *bind.WatchOpts, sink chan<- *StakingEventsMockFeedOperatorsSet) (event.Subscription, error) + + ParseFeedOperatorsSet(log types.Log) (*StakingEventsMockFeedOperatorsSet, error) + + FilterMaxCommunityStakeAmountIncreased(opts *bind.FilterOpts) (*StakingEventsMockMaxCommunityStakeAmountIncreasedIterator, error) + + WatchMaxCommunityStakeAmountIncreased(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMaxCommunityStakeAmountIncreased) (event.Subscription, error) + + ParseMaxCommunityStakeAmountIncreased(log types.Log) (*StakingEventsMockMaxCommunityStakeAmountIncreased, error) + + FilterMaxOperatorStakeAmountIncreased(opts *bind.FilterOpts) (*StakingEventsMockMaxOperatorStakeAmountIncreasedIterator, error) + + WatchMaxOperatorStakeAmountIncreased(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMaxOperatorStakeAmountIncreased) (event.Subscription, error) + + ParseMaxOperatorStakeAmountIncreased(log types.Log) (*StakingEventsMockMaxOperatorStakeAmountIncreased, error) + + FilterMerkleRootChanged(opts *bind.FilterOpts) (*StakingEventsMockMerkleRootChangedIterator, error) + + WatchMerkleRootChanged(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMerkleRootChanged) (event.Subscription, error) + + ParseMerkleRootChanged(log types.Log) (*StakingEventsMockMerkleRootChanged, error) + + FilterMigrated(opts *bind.FilterOpts) (*StakingEventsMockMigratedIterator, error) + + WatchMigrated(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMigrated) (event.Subscription, error) + + ParseMigrated(log types.Log) (*StakingEventsMockMigrated, error) + + FilterMigrationTargetAccepted(opts *bind.FilterOpts) (*StakingEventsMockMigrationTargetAcceptedIterator, error) + + WatchMigrationTargetAccepted(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMigrationTargetAccepted) (event.Subscription, error) + + ParseMigrationTargetAccepted(log types.Log) (*StakingEventsMockMigrationTargetAccepted, error) + + FilterMigrationTargetProposed(opts *bind.FilterOpts) (*StakingEventsMockMigrationTargetProposedIterator, error) + + WatchMigrationTargetProposed(opts *bind.WatchOpts, sink chan<- *StakingEventsMockMigrationTargetProposed) (event.Subscription, error) + + ParseMigrationTargetProposed(log types.Log) (*StakingEventsMockMigrationTargetProposed, error) + + FilterOperatorAdded(opts *bind.FilterOpts) (*StakingEventsMockOperatorAddedIterator, error) + + WatchOperatorAdded(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOperatorAdded) (event.Subscription, error) + + ParseOperatorAdded(log types.Log) (*StakingEventsMockOperatorAdded, error) + + FilterOperatorRemoved(opts *bind.FilterOpts) (*StakingEventsMockOperatorRemovedIterator, error) + + WatchOperatorRemoved(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOperatorRemoved) (event.Subscription, error) + + ParseOperatorRemoved(log types.Log) (*StakingEventsMockOperatorRemoved, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*StakingEventsMockOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*StakingEventsMockOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*StakingEventsMockOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *StakingEventsMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*StakingEventsMockOwnershipTransferred, error) + + FilterPaused(opts *bind.FilterOpts) (*StakingEventsMockPausedIterator, error) + + WatchPaused(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPaused) (event.Subscription, error) + + ParsePaused(log types.Log) (*StakingEventsMockPaused, error) + + FilterPoolConcluded(opts *bind.FilterOpts) (*StakingEventsMockPoolConcludedIterator, error) + + WatchPoolConcluded(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPoolConcluded) (event.Subscription, error) + + ParsePoolConcluded(log types.Log) (*StakingEventsMockPoolConcluded, error) + + FilterPoolOpened(opts *bind.FilterOpts) (*StakingEventsMockPoolOpenedIterator, error) + + WatchPoolOpened(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPoolOpened) (event.Subscription, error) + + ParsePoolOpened(log types.Log) (*StakingEventsMockPoolOpened, error) + + FilterPoolSizeIncreased(opts *bind.FilterOpts) (*StakingEventsMockPoolSizeIncreasedIterator, error) + + WatchPoolSizeIncreased(opts *bind.WatchOpts, sink chan<- *StakingEventsMockPoolSizeIncreased) (event.Subscription, error) + + ParsePoolSizeIncreased(log types.Log) (*StakingEventsMockPoolSizeIncreased, error) + + FilterRewardAdded(opts *bind.FilterOpts) (*StakingEventsMockRewardAddedIterator, error) + + WatchRewardAdded(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardAdded) (event.Subscription, error) + + ParseRewardAdded(log types.Log) (*StakingEventsMockRewardAdded, error) + + FilterRewardInitialized(opts *bind.FilterOpts) (*StakingEventsMockRewardInitializedIterator, error) + + WatchRewardInitialized(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardInitialized) (event.Subscription, error) + + ParseRewardInitialized(log types.Log) (*StakingEventsMockRewardInitialized, error) + + FilterRewardRateChanged(opts *bind.FilterOpts) (*StakingEventsMockRewardRateChangedIterator, error) + + WatchRewardRateChanged(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardRateChanged) (event.Subscription, error) + + ParseRewardRateChanged(log types.Log) (*StakingEventsMockRewardRateChanged, error) + + FilterRewardSlashed(opts *bind.FilterOpts) (*StakingEventsMockRewardSlashedIterator, error) + + WatchRewardSlashed(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardSlashed) (event.Subscription, error) + + ParseRewardSlashed(log types.Log) (*StakingEventsMockRewardSlashed, error) + + FilterRewardWithdrawn(opts *bind.FilterOpts) (*StakingEventsMockRewardWithdrawnIterator, error) + + WatchRewardWithdrawn(opts *bind.WatchOpts, sink chan<- *StakingEventsMockRewardWithdrawn) (event.Subscription, error) + + ParseRewardWithdrawn(log types.Log) (*StakingEventsMockRewardWithdrawn, error) + + FilterStaked(opts *bind.FilterOpts) (*StakingEventsMockStakedIterator, error) + + WatchStaked(opts *bind.WatchOpts, sink chan<- *StakingEventsMockStaked) (event.Subscription, error) + + ParseStaked(log types.Log) (*StakingEventsMockStaked, error) + + FilterUnpaused(opts *bind.FilterOpts) (*StakingEventsMockUnpausedIterator, error) + + WatchUnpaused(opts *bind.WatchOpts, sink chan<- *StakingEventsMockUnpaused) (event.Subscription, error) + + ParseUnpaused(log types.Log) (*StakingEventsMockUnpaused, error) + + FilterUnstaked(opts *bind.FilterOpts) (*StakingEventsMockUnstakedIterator, error) + + WatchUnstaked(opts *bind.WatchOpts, sink chan<- *StakingEventsMockUnstaked) (event.Subscription, error) + + ParseUnstaked(log types.Log) (*StakingEventsMockUnstaked, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index 32f989cd3e1..c63e0bd862f 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -325,6 +325,160 @@ func (f *EthereumFunctionsBillingRegistryEventsMock) BillingEnd(requestId [32]by return f.client.ProcessTransaction(tx) } +// EthereumStakingEventsMock represents the basic events mock contract +type EthereumStakingEventsMock struct { + client blockchain.EVMClient + eventsMock *eth_contracts.StakingEventsMock + address *common.Address +} + +func (f *EthereumStakingEventsMock) Address() string { + return f.address.Hex() +} + +func (f *EthereumStakingEventsMock) MaxCommunityStakeAmountIncreased(maxStakeAmount *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitMaxCommunityStakeAmountIncreased(opts, maxStakeAmount) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) PoolSizeIncreased(maxPoolSize *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitPoolSizeIncreased(opts, maxPoolSize) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) MaxOperatorStakeAmountIncreased(maxStakeAmount *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitMaxOperatorStakeAmountIncreased(opts, maxStakeAmount) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) RewardInitialized(rate *big.Int, available *big.Int, startTimestamp *big.Int, endTimestamp *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitRewardInitialized(opts, rate, available, startTimestamp, endTimestamp) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) AlertRaised(alerter common.Address, roundId *big.Int, rewardAmount *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitAlertRaised(opts, alerter, roundId, rewardAmount) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) Staked(staker common.Address, newStake *big.Int, totalStake *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitStaked(opts, staker, newStake, totalStake) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) OperatorAdded(operator common.Address) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitOperatorAdded(opts, operator) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) OperatorRemoved(operator common.Address, amount *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitOperatorRemoved(opts, operator, amount) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumStakingEventsMock) FeedOperatorsSet(feedOperators []common.Address) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitFeedOperatorsSet(opts, feedOperators) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +// EthereumOffchainAggregatorEventsMock represents the basic events mock contract +type EthereumOffchainAggregatorEventsMock struct { + client blockchain.EVMClient + eventsMock *eth_contracts.OffchainAggregatorEventsMock + address *common.Address +} + +func (f *EthereumOffchainAggregatorEventsMock) Address() string { + return f.address.Hex() +} + +func (f *EthereumOffchainAggregatorEventsMock) ConfigSet(previousConfigBlockNumber uint32, configCount uint64, signers []common.Address, transmitters []common.Address, threshold uint8, encodedConfigVersion uint64, encoded []byte) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitConfigSet(opts, previousConfigBlockNumber, configCount, signers, transmitters, threshold, encodedConfigVersion, encoded) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumOffchainAggregatorEventsMock) NewTransmission(aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.eventsMock.EmitNewTransmission(opts, aggregatorRoundId, answer, transmitter, observations, observers, rawReportContext) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + // EthereumFluxAggregator represents the basic flux aggregation contract type EthereumFluxAggregator struct { client blockchain.EVMClient From ac5e2644c0bc0ebcc932ee5427f8cda301d4ae80 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Fri, 11 Aug 2023 11:52:32 +0100 Subject: [PATCH 145/270] Small update to ocr2keepers types (#10164) * Small update to ocr2keepers types * update ocr2keepers tag --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +-- .../ocr2/plugins/ocr2keeper/evm21/abi.go | 20 +++++++------- .../ocr2/plugins/ocr2keeper/evm21/abi_test.go | 26 +++++++++---------- .../plugins/ocr2keeper/evm21/feed_lookup.go | 10 +++---- .../ocr2keeper/evm21/feed_lookup_test.go | 12 ++++----- go.mod | 2 +- go.sum | 4 +-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +-- 10 files changed, 43 insertions(+), 43 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index ef684bea070..41b825ab5be 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.7 + github.com/smartcontractkit/ocr2keepers v0.7.8 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index d39c13df553..ea4961cf93d 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= -github.com/smartcontractkit/ocr2keepers v0.7.7/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= +github.com/smartcontractkit/ocr2keepers v0.7.8/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go index d012d64396a..eca011a1ff3 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go @@ -63,21 +63,21 @@ func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, } result = ocr2keepers.CheckResult{ - Eligible: *abi.ConvertType(out[0], new(bool)).(*bool), - Retryable: false, - GasAllocated: uint64((*abi.ConvertType(out[4], new(*big.Int)).(**big.Int)).Int64()), - UpkeepID: p.UpkeepID, - Trigger: p.Trigger, - WorkID: p.WorkID, - FastGasWei: *abi.ConvertType(out[5], new(*big.Int)).(**big.Int), - LinkNative: *abi.ConvertType(out[6], new(*big.Int)).(**big.Int), - FailureReason: *abi.ConvertType(out[2], new(uint8)).(*uint8), + Eligible: *abi.ConvertType(out[0], new(bool)).(*bool), + Retryable: false, + GasAllocated: uint64((*abi.ConvertType(out[4], new(*big.Int)).(**big.Int)).Int64()), + UpkeepID: p.UpkeepID, + Trigger: p.Trigger, + WorkID: p.WorkID, + FastGasWei: *abi.ConvertType(out[5], new(*big.Int)).(**big.Int), + LinkNative: *abi.ConvertType(out[6], new(*big.Int)).(**big.Int), + IneligibilityReason: *abi.ConvertType(out[2], new(uint8)).(*uint8), } rawPerformData := *abi.ConvertType(out[1], new([]byte)).(*[]byte) // if NONE we expect the perform data. if TARGET_CHECK_REVERTED we will have the error data in the perform data used for off chain lookup - if result.FailureReason == UPKEEP_FAILURE_REASON_NONE || (result.FailureReason == UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED && len(rawPerformData) > 0) { + if result.IneligibilityReason == UPKEEP_FAILURE_REASON_NONE || (result.IneligibilityReason == UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED && len(rawPerformData) > 0) { result.PerformData = rawPerformData } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go index e5507277da2..b42a40b2f05 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go @@ -35,12 +35,12 @@ func TestUnpackCheckResults(t *testing.T) { Payload: payload1, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000421c000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000000", ExpectedResult: ocr2keepers.CheckResult{ - UpkeepID: upkeepId, - Eligible: false, - FailureReason: UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED, - PerformData: nil, - FastGasWei: big.NewInt(1000000000), - LinkNative: big.NewInt(3532383906411401), + UpkeepID: upkeepId, + Eligible: false, + IneligibilityReason: UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED, + PerformData: nil, + FastGasWei: big.NewInt(1000000000), + LinkNative: big.NewInt(3532383906411401), }, }, { @@ -48,12 +48,12 @@ func TestUnpackCheckResults(t *testing.T) { Payload: payload2, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000007531000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000008914039bf676e20aad43a5642485e666575ed0d927a4b5679745e947e7d125ee2687c10000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000024462e8a50d00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000128c1d000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000009666565644944537472000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000184554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000000000184254432d5553442d415242495452554d2d544553544e45540000000000000000000000000000000000000000000000000000000000000000000000000000000b626c6f636b4e756d6265720000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000006400000000000000000000000000000000000000000000000000000000000000000000000000000000", ExpectedResult: ocr2keepers.CheckResult{ - UpkeepID: upkeepId, - Eligible: false, - FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, - PerformData: []byte{98, 232, 165, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 193, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 68, 83, 116, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 66, 84, 67, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - FastGasWei: big.NewInt(1000000000), - LinkNative: big.NewInt(3532383906411401), + UpkeepID: upkeepId, + Eligible: false, + IneligibilityReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + PerformData: []byte{98, 232, 165, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 193, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 68, 83, 116, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 66, 84, 67, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + FastGasWei: big.NewInt(1000000000), + LinkNative: big.NewInt(3532383906411401), }, }, } @@ -65,7 +65,7 @@ func TestUnpackCheckResults(t *testing.T) { assert.Nil(t, err) assert.Equal(t, test.ExpectedResult.UpkeepID, rs.UpkeepID) assert.Equal(t, test.ExpectedResult.Eligible, rs.Eligible) - assert.Equal(t, test.ExpectedResult.FailureReason, rs.FailureReason) + assert.Equal(t, test.ExpectedResult.IneligibilityReason, rs.IneligibilityReason) }) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index b3041551067..2402c237eac 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -76,7 +76,7 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper lookups := map[int]*FeedLookup{} for i := range upkeepResults { res := &upkeepResults[i] - if res.FailureReason != UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED { + if res.IneligibilityReason != UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED { continue } @@ -96,7 +96,7 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper } if !allowed { - res.FailureReason = UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED + res.IneligibilityReason = UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED r.lggr.Errorf("[FeedLookup] upkeep %s block %d NOT allowed to time Mercury server", upkeepId, block) continue } @@ -153,18 +153,18 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * } if int(failureReason) == UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED { - upkeepResults[i].FailureReason = UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED + upkeepResults[i].IneligibilityReason = UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED r.lggr.Debugf("[FeedLookup] upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) return } if !needed { - upkeepResults[i].FailureReason = UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED + upkeepResults[i].IneligibilityReason = UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED r.lggr.Debugf("[FeedLookup] upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) return } - upkeepResults[i].FailureReason = UPKEEP_FAILURE_REASON_NONE + upkeepResults[i].IneligibilityReason = UPKEEP_FAILURE_REASON_NONE upkeepResults[i].Eligible = true upkeepResults[i].PerformData = performData r.lggr.Infof("[FeedLookup] upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index 5c13e860a84..3ea2bf9c936 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -103,7 +103,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + IneligibilityReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, }, }, blob: "0x00066dfcd1ed2d95b18c948dbc5bd64c687afe93e4ca7d663ddec14c20090ad80000000000000000000000000000000000000000000000000000000000159761000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000002200000000000000000000000000000000000000000000000000000000000000280000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001204554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000648a1fbb000000000000000000000000000000000000000000000000000000274421041500000000000000000000000000000000000000000000000000000027437c6ecd0000000000000000000000000000000000000000000000000000002744c5995d00000000000000000000000000000000000000000000000000000000018d6ec108936dfe39c48715572a51ac868129958f937fb95ef5abdf73a239cf86a4fee700000000000000000000000000000000000000000000000000000000018d6ec100000000000000000000000000000000000000000000000000000000648a1fbb00000000000000000000000000000000000000000000000000000000000000028a26e557ee2feb91ccb116f3ab4eb1469afe5c3b012538cb151dbe3fbceaf6f117b24ac2a82cff25b286ae0a9b903dc6badaa16f6e67bf0983461b008574e30a00000000000000000000000000000000000000000000000000000000000000020db5c5924481061b98df59caefd9c4c1e72657c4976bf7c7568730fbdaf828080bff6b1edea2c8fed5e8bbac5574aa94cf809d898f5055cb1db14a16f1493726", @@ -120,7 +120,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - FailureReason: UPKEEP_FAILURE_REASON_NONE, + IneligibilityReason: UPKEEP_FAILURE_REASON_NONE, }, }, hasError: false, @@ -135,7 +135,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - FailureReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, + IneligibilityReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, }, }, expectedResults: []ocr2keepers.CheckResult{ @@ -146,7 +146,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - FailureReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, + IneligibilityReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, }, }, hasError: true, @@ -160,7 +160,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - FailureReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + IneligibilityReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, }, }, expectedResults: []ocr2keepers.CheckResult{ @@ -171,7 +171,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - FailureReason: UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED, + IneligibilityReason: UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED, }, }, hasError: false, diff --git a/go.mod b/go.mod index 7d06ff81986..51edd6ec7aa 100644 --- a/go.mod +++ b/go.mod @@ -71,7 +71,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.7 + github.com/smartcontractkit/ocr2keepers v0.7.8 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index 5ac059e984f..c326c40bd92 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= -github.com/smartcontractkit/ocr2keepers v0.7.7/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= +github.com/smartcontractkit/ocr2keepers v0.7.8/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 37edc3d2fc6..fa1d5e003aa 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.2 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.7 + github.com/smartcontractkit/ocr2keepers v0.7.8 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.7 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index f70fd26b2c7..7e1a633c4f1 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/chainlink-testing-framework v1.15.2 h1:WhZvHHz104RKC github.com/smartcontractkit/chainlink-testing-framework v1.15.2/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.7 h1:hKsp61nkg6wUmX8IMiVUfEpcnrVE8DSxAc6x5VE2fJo= -github.com/smartcontractkit/ocr2keepers v0.7.7/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= +github.com/smartcontractkit/ocr2keepers v0.7.8/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From cbf448459d0dd9c7f108afb2e683eb6f7848dfd0 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Fri, 11 Aug 2023 07:52:53 -0500 Subject: [PATCH 146/270] bump urfave/cli and pelletier/go-toml/v2 (#10167) --- core/scripts/go.mod | 4 ++-- core/scripts/go.sum | 13 ++++++------- go.mod | 4 ++-- go.sum | 13 ++++++------- integration-tests/go.sum | 2 +- 5 files changed, 17 insertions(+), 19 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 41b825ab5be..d2cb619328c 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -15,7 +15,7 @@ require ( github.com/manyminds/api2go v0.0.0-20171030193247-e7b693844a6f github.com/montanaflynn/stats v0.7.1 github.com/olekukonko/tablewriter v0.0.5 - github.com/pelletier/go-toml/v2 v2.0.8 + github.com/pelletier/go-toml/v2 v2.0.9 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 @@ -27,7 +27,7 @@ require ( github.com/stretchr/testify v1.8.4 github.com/umbracle/ethgo v0.1.3 github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722 - github.com/urfave/cli v1.22.13 + github.com/urfave/cli v1.22.14 go.dedis.ch/kyber/v3 v3.1.0 ) diff --git a/core/scripts/go.sum b/core/scripts/go.sum index ea4961cf93d..d8d440d0297 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -78,8 +78,8 @@ github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/toml v1.2.1 h1:9F2/+DoOYIOksmaJFPw1tGFy1eDnIJXg+UHjuD8lTak= -github.com/BurntSushi/toml v1.2.1/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= +github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= +github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= @@ -1316,8 +1316,8 @@ github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/9 github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pelletier/go-toml/v2 v2.0.1/go.mod h1:r9LEWfGN8R5k0VXJ+0BkIe7MYkRdwZOjgMj2KwnJFUo= -github.com/pelletier/go-toml/v2 v2.0.8 h1:0ctb6s9mE31h0/lhu+J6OPmVeDxJn+kYnJc2jZR9tGQ= -github.com/pelletier/go-toml/v2 v2.0.8/go.mod h1:vuYfssBdrU2XDZ9bYydBu6t+6a6PYNcZljzZR9VXg+4= +github.com/pelletier/go-toml/v2 v2.0.9 h1:uH2qQXheeefCCkuBBSLi7jCiSmj3VRh2+Goq2N7Xxu0= +github.com/pelletier/go-toml/v2 v2.0.9/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= @@ -1507,7 +1507,6 @@ github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1F github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= @@ -1567,8 +1566,8 @@ github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722/go.mod h1:c8J0h9a github.com/unrolled/secure v1.13.0 h1:sdr3Phw2+f8Px8HE5sd1EHdj1aV3yUwed/uZXChLFsk= github.com/unrolled/secure v1.13.0/go.mod h1:BmF5hyM6tXczk3MpQkFf1hpKSRqCyhqcbiQtiAF7+40= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/cli v1.22.13 h1:wsLILXG8qCJNse/qAgLNf23737Cx05GflHg/PJGe1Ok= -github.com/urfave/cli v1.22.13/go.mod h1:VufqObjsMTF2BBwKawpx9R8eAneNEWhoO0yx8Vd+FkE= +github.com/urfave/cli v1.22.14 h1:ebbhrRiGK2i4naQJr+1Xj92HXZCrK7MsyTS/ob3HnAk= +github.com/urfave/cli v1.22.14/go.mod h1:X0eDS6pD6Exaclxm99NJ3FiCDRED7vIHpx2mDOHLvkA= github.com/urfave/cli/v2 v2.17.2-0.20221006022127-8f469abc00aa h1:5SqCsI/2Qya2bCzK15ozrqo2sZxkh0FHynJZOTVoV6Q= github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= diff --git a/go.mod b/go.mod index 51edd6ec7aa..f62c681bedb 100644 --- a/go.mod +++ b/go.mod @@ -52,7 +52,7 @@ require ( github.com/onsi/gomega v1.27.8 github.com/patrickmn/go-cache v2.1.0+incompatible github.com/pelletier/go-toml v1.9.5 - github.com/pelletier/go-toml/v2 v2.0.8 + github.com/pelletier/go-toml/v2 v2.0.9 github.com/pkg/errors v0.9.1 github.com/pressly/goose/v3 v3.5.3 github.com/prometheus/client_golang v1.16.0 @@ -85,7 +85,7 @@ require ( github.com/ulule/limiter/v3 v3.11.2 github.com/umbracle/ethgo v0.1.3 github.com/unrolled/secure v1.13.0 - github.com/urfave/cli v1.22.13 + github.com/urfave/cli v1.22.14 go.dedis.ch/fixbuf v1.0.3 go.dedis.ch/kyber/v3 v3.1.0 go.uber.org/multierr v1.11.0 diff --git a/go.sum b/go.sum index c326c40bd92..99bc4045948 100644 --- a/go.sum +++ b/go.sum @@ -79,8 +79,8 @@ github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg6 github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= -github.com/BurntSushi/toml v1.2.1 h1:9F2/+DoOYIOksmaJFPw1tGFy1eDnIJXg+UHjuD8lTak= -github.com/BurntSushi/toml v1.2.1/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= +github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= +github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= @@ -1323,8 +1323,8 @@ github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/9 github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3ve8= github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pelletier/go-toml/v2 v2.0.1/go.mod h1:r9LEWfGN8R5k0VXJ+0BkIe7MYkRdwZOjgMj2KwnJFUo= -github.com/pelletier/go-toml/v2 v2.0.8 h1:0ctb6s9mE31h0/lhu+J6OPmVeDxJn+kYnJc2jZR9tGQ= -github.com/pelletier/go-toml/v2 v2.0.8/go.mod h1:vuYfssBdrU2XDZ9bYydBu6t+6a6PYNcZljzZR9VXg+4= +github.com/pelletier/go-toml/v2 v2.0.9 h1:uH2qQXheeefCCkuBBSLi7jCiSmj3VRh2+Goq2N7Xxu0= +github.com/pelletier/go-toml/v2 v2.0.9/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdUvyaeZurnPPDc= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= @@ -1513,7 +1513,6 @@ github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1F github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.8.2/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= -github.com/stretchr/testify v1.8.3/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= @@ -1573,8 +1572,8 @@ github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722/go.mod h1:c8J0h9a github.com/unrolled/secure v1.13.0 h1:sdr3Phw2+f8Px8HE5sd1EHdj1aV3yUwed/uZXChLFsk= github.com/unrolled/secure v1.13.0/go.mod h1:BmF5hyM6tXczk3MpQkFf1hpKSRqCyhqcbiQtiAF7+40= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/cli v1.22.13 h1:wsLILXG8qCJNse/qAgLNf23737Cx05GflHg/PJGe1Ok= -github.com/urfave/cli v1.22.13/go.mod h1:VufqObjsMTF2BBwKawpx9R8eAneNEWhoO0yx8Vd+FkE= +github.com/urfave/cli v1.22.14 h1:ebbhrRiGK2i4naQJr+1Xj92HXZCrK7MsyTS/ob3HnAk= +github.com/urfave/cli v1.22.14/go.mod h1:X0eDS6pD6Exaclxm99NJ3FiCDRED7vIHpx2mDOHLvkA= github.com/urfave/cli/v2 v2.17.2-0.20221006022127-8f469abc00aa h1:5SqCsI/2Qya2bCzK15ozrqo2sZxkh0FHynJZOTVoV6Q= github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 7e1a633c4f1..4b0ca86c60a 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2389,7 +2389,7 @@ github.com/umbracle/ethgo v0.1.3/go.mod h1:g9zclCLixH8liBI27Py82klDkW7Oo33AxUOr+ github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722 h1:10Nbw6cACsnQm7r34zlpJky+IzxVLRk6MKTS2d3Vp0E= github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722/go.mod h1:c8J0h9aULj2i3umrfyestM6jCq0LK0U6ly6bWy96nd4= github.com/unrolled/secure v1.13.0 h1:sdr3Phw2+f8Px8HE5sd1EHdj1aV3yUwed/uZXChLFsk= -github.com/urfave/cli v1.22.13 h1:wsLILXG8qCJNse/qAgLNf23737Cx05GflHg/PJGe1Ok= +github.com/urfave/cli v1.22.14 h1:ebbhrRiGK2i4naQJr+1Xj92HXZCrK7MsyTS/ob3HnAk= github.com/urfave/cli/v2 v2.17.2-0.20221006022127-8f469abc00aa h1:5SqCsI/2Qya2bCzK15ozrqo2sZxkh0FHynJZOTVoV6Q= github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= From d5c8b50e95dfc090a1a888c3dea092ec1a829bc4 Mon Sep 17 00:00:00 2001 From: Ilja Pavlovs Date: Fri, 11 Aug 2023 17:23:05 +0300 Subject: [PATCH 147/270] Chore/vrf 538 improvements (#10139) * fix VRF V3 setup script * VRF-538 - do not fund eth keys if its already funded; added from field for the vrf simulation * VRF-470 - fixing deploy-universe cli command issues * Update core/scripts/common/helpers.go Co-authored-by: Makram * Update core/scripts/common/helpers.go Co-authored-by: Makram --------- Co-authored-by: Makram --- core/scripts/common/helpers.go | 74 +++-- core/scripts/vrfv2/testnet/README.md | 7 +- .../vrfv2/testnet/constants/constants.go | 4 +- core/scripts/vrfv2/testnet/jobs/jobs.go | 1 + .../vrfv2/testnet/scripts/super_scripts.go | 274 ++++++++++-------- .../vrfv2/testnet/setup-envs/README.md | 2 + core/scripts/vrfv2/testnet/setup-envs/main.go | 107 ++++--- 7 files changed, 274 insertions(+), 195 deletions(-) diff --git a/core/scripts/common/helpers.go b/core/scripts/common/helpers.go index 4a4864485c1..e761fea5692 100644 --- a/core/scripts/common/helpers.go +++ b/core/scripts/common/helpers.go @@ -109,6 +109,7 @@ func SetupEnv(overrideNonce bool) Environment { // Explicitly set gas price to ensure non-eip 1559 gp, err := ec.SuggestGasPrice(context.Background()) PanicErr(err) + fmt.Println("Suggested Gas Price:", gp, "wei") owner.GasPrice = gp gasLimit, set := os.LookupEnv("GAS_LIMIT") if set { @@ -127,9 +128,9 @@ func SetupEnv(overrideNonce bool) Environment { PanicErr(err) owner.Nonce = big.NewInt(int64(nonce)) - owner.GasPrice = gp.Mul(gp, big.NewInt(2)) } - + owner.GasPrice = gp.Mul(gp, big.NewInt(2)) + fmt.Println("Modified Gas Price that will be set:", owner.GasPrice, "wei") // the execution environment for the scripts return Environment{ Owner: owner, @@ -334,43 +335,52 @@ func ParseHexSlice(arg string) (ret [][]byte) { } func FundNodes(e Environment, transmitters []string, fundingAmount *big.Int) { + for _, transmitter := range transmitters { + FundNode(e, transmitter, fundingAmount) + } +} + +func FundNode(e Environment, address string, fundingAmount *big.Int) { block, err := e.Ec.BlockNumber(context.Background()) PanicErr(err) nonce, err := e.Ec.NonceAt(context.Background(), e.Owner.From, big.NewInt(int64(block))) PanicErr(err) - - for i := 0; i < len(transmitters); i++ { - // Special case for Arbitrum since gas estimation there is different. - var gasLimit uint64 - if IsArbitrumChainID(e.ChainID) { - to := common.HexToAddress(transmitters[i]) - estimated, err := e.Ec.EstimateGas(context.Background(), ethereum.CallMsg{ - From: e.Owner.From, - To: &to, - Value: fundingAmount, - }) - PanicErr(err) - gasLimit = estimated - } else { - gasLimit = uint64(21_000) - } - - tx := types.NewTransaction( - nonce+uint64(i), - common.HexToAddress(transmitters[i]), - fundingAmount, - gasLimit, - e.Owner.GasPrice, - nil, - ) - signedTx, err := e.Owner.Signer(e.Owner.From, tx) - PanicErr(err) - err = e.Ec.SendTransaction(context.Background(), signedTx) + // Special case for Arbitrum since gas estimation there is different. + + var gasLimit uint64 + if IsArbitrumChainID(e.ChainID) { + to := common.HexToAddress(address) + estimated, err := e.Ec.EstimateGas(context.Background(), ethereum.CallMsg{ + From: e.Owner.From, + To: &to, + Value: fundingAmount, + }) PanicErr(err) - - fmt.Printf("Sending to %s: %s\n", transmitters[i], ExplorerLink(e.ChainID, signedTx.Hash())) + gasLimit = estimated + } else { + gasLimit = uint64(21_000) } + toAddress := common.HexToAddress(address) + + tx := types.NewTx( + &types.LegacyTx{ + Nonce: nonce, + GasPrice: e.Owner.GasPrice, + Gas: gasLimit, + To: &toAddress, + Value: fundingAmount, + Data: nil, + }) + + signedTx, err := e.Owner.Signer(e.Owner.From, tx) + PanicErr(err) + err = e.Ec.SendTransaction(context.Background(), signedTx) + PanicErr(err) + fmt.Printf("Sending to %s: %s\n", address, ExplorerLink(e.ChainID, signedTx.Hash())) + PanicErr(err) + _, err = bind.WaitMined(context.Background(), e.Ec, signedTx) + PanicErr(err) } // binarySearch finds the highest value within the range bottom-top at which the test function is diff --git a/core/scripts/vrfv2/testnet/README.md b/core/scripts/vrfv2/testnet/README.md index da772594f52..1b2d986f554 100644 --- a/core/scripts/vrfv2/testnet/README.md +++ b/core/scripts/vrfv2/testnet/README.md @@ -56,7 +56,12 @@ cd /core/scripts/vrfv2/testnet To deploy a full VRF environment on-chain, run: ```shell -go run . deploy-universe --link-address=$LINK --link-eth-feed=$LINK_ETH_FEED --subscription-balance= --uncompressed-pub-key=$PUB_KEY --oracle-address=$ORACLE_ADDRESS +go run . deploy-universe \ +--sending-key-funding-amount 100000000000000000 \ +--subscription-balance=10000000000000000000 \ +--uncompressed-pub-key= \ +--vrf-primary-node-sending-keys="" \ +--batch-fulfillment-enabled false ``` ## Deploying the Consumer Contract diff --git a/core/scripts/vrfv2/testnet/constants/constants.go b/core/scripts/vrfv2/testnet/constants/constants.go index 5d2d67e7b34..73356d48ffc 100644 --- a/core/scripts/vrfv2/testnet/constants/constants.go +++ b/core/scripts/vrfv2/testnet/constants/constants.go @@ -9,8 +9,8 @@ var ( SubscriptionBalanceJuels = assets.Ether(10).ToInt() // optional flags - FallbackWeiPerUnitLink = big.NewInt(6e16) - + FallbackWeiPerUnitLink = big.NewInt(6e16) + BatchFulfillmentEnabled = true MinConfs = 3 NodeSendingKeyFundingAmountGwei = assets.GWei(0).Int64() //100000000 = 0.1 ETH MaxGasLimit = int64(2.5e6) diff --git a/core/scripts/vrfv2/testnet/jobs/jobs.go b/core/scripts/vrfv2/testnet/jobs/jobs.go index 335a264b27c..8ff0195bfa8 100644 --- a/core/scripts/vrfv2/testnet/jobs/jobs.go +++ b/core/scripts/vrfv2/testnet/jobs/jobs.go @@ -28,6 +28,7 @@ estimate_gas [type=estimategaslimit multiplier="1.1" data="$(vrf.output)"] simulate [type=ethcall + from="%s" to="%s" gas="$(estimate_gas)" gasPrice="$(jobSpec.maxGasPrice)" diff --git a/core/scripts/vrfv2/testnet/scripts/super_scripts.go b/core/scripts/vrfv2/testnet/scripts/super_scripts.go index ea6c9e46eab..3594636a604 100644 --- a/core/scripts/vrfv2/testnet/scripts/super_scripts.go +++ b/core/scripts/vrfv2/testnet/scripts/super_scripts.go @@ -33,13 +33,18 @@ var ( type Node struct { URL string CredsFile string - SendingKeys []string + SendingKeys []SendingKey NumberOfSendingKeysToCreate int - SendingKeyFundingAmount int64 + SendingKeyFundingAmount big.Int VrfKeys []string jobSpec string } +type SendingKey struct { + Address string + BalanceEth big.Int +} + type JobSpecs struct { VRFPrimaryNode string VRFBackupyNode string @@ -48,6 +53,24 @@ type JobSpecs struct { BHFNode string } +type ContractAddresses struct { + LinkAddress string + LinkEthAddress string + BhsContractAddress common.Address + BatchBHSAddress common.Address + CoordinatorAddress common.Address + BatchCoordinatorAddress common.Address +} + +type CoordinatorConfig struct { + MinConfs *int + MaxGasLimit *int64 + StalenessSeconds *int64 + GasAfterPayment *int64 + FallbackWeiPerUnitLink *big.Int + FeeConfig vrf_coordinator_v2.VRFCoordinatorV2FeeConfig +} + func DeployUniverseViaCLI(e helpers.Environment) { deployCmd := flag.NewFlagSet("deploy-universe", flag.ExitOnError) @@ -59,15 +82,16 @@ func DeployUniverseViaCLI(e helpers.Environment) { coordinatorAddressString := *deployCmd.String("coordinator-address", "", "address of VRF Coordinator contract") batchCoordinatorAddressString := *deployCmd.String("batch-coordinator-address", "", "address Batch VRF Coordinator contract") - subscriptionBalanceString := deployCmd.String("subscription-balance", constants.SubscriptionBalanceJuels.String(), "amount to fund subscription") + subscriptionBalanceJuelsString := deployCmd.String("subscription-balance", constants.SubscriptionBalanceJuels.String(), "amount to fund subscription") + nodeSendingKeyFundingAmount := deployCmd.Int64("sending-key-funding-amount", constants.NodeSendingKeyFundingAmountGwei, "CL node sending key funding amount") + + batchFulfillmentEnabled := deployCmd.Bool("batch-fulfillment-enabled", constants.BatchFulfillmentEnabled, "whether send randomness fulfillments in batches inside one tx from CL node") // optional flags fallbackWeiPerUnitLinkString := deployCmd.String("fallback-wei-per-unit-link", constants.FallbackWeiPerUnitLink.String(), "fallback wei/link ratio") registerKeyUncompressedPubKey := deployCmd.String("uncompressed-pub-key", "", "uncompressed public key") vrfPrimaryNodeSendingKeysString := deployCmd.String("vrf-primary-node-sending-keys", "", "VRF Primary Node sending keys") - vrfBackupNodeSendingKeysString := deployCmd.String("vrf-backup-node-sending-keys", "", "VRF Backup Node sending keys") - bhsNodeSendingKeysString := deployCmd.String("bhs-node-sending-keys", "", "BHS Node sending keys") - bhfNodeSendingKeysString := deployCmd.String("bhf-node-sending-keys", "", "BHF Node sending keys") + minConfs := deployCmd.Int("min-confs", constants.MinConfs, "min confs") maxGasLimit := deployCmd.Int64("max-gas-limit", constants.MaxGasLimit, "max gas limit") stalenessSeconds := deployCmd.Int64("staleness-seconds", constants.StalenessSeconds, "staleness in seconds") @@ -87,7 +111,7 @@ func DeployUniverseViaCLI(e helpers.Environment) { ) fallbackWeiPerUnitLink := decimal.RequireFromString(*fallbackWeiPerUnitLinkString).BigInt() - subscriptionBalance := decimal.RequireFromString(*subscriptionBalanceString).BigInt() + subscriptionBalanceJuels := decimal.RequireFromString(*subscriptionBalanceJuelsString).BigInt() feeConfig := vrf_coordinator_v2.VRFCoordinatorV2FeeConfig{ FulfillmentFlatFeeLinkPPMTier1: uint32(*flatFeeTier1), @@ -102,23 +126,12 @@ func DeployUniverseViaCLI(e helpers.Environment) { } vrfPrimaryNodeSendingKeys := strings.Split(*vrfPrimaryNodeSendingKeysString, ",") - vrfBackupNodeSendingKeys := strings.Split(*vrfBackupNodeSendingKeysString, ",") - bhsNodeSendingKeys := strings.Split(*bhsNodeSendingKeysString, ",") - bhfNodeSendingKeys := strings.Split(*bhfNodeSendingKeysString, ",") - nodes := make(map[string]Node) + nodesMap := make(map[string]Node) - nodes[VRFPrimaryNodeName] = Node{ - SendingKeys: vrfPrimaryNodeSendingKeys, - } - nodes[VRFBackupNodeName] = Node{ - SendingKeys: vrfBackupNodeSendingKeys, - } - nodes[BHSNodeName] = Node{ - SendingKeys: bhsNodeSendingKeys, - } - nodes[BHFNodeName] = Node{ - SendingKeys: bhfNodeSendingKeys, + nodesMap[VRFPrimaryNodeName] = Node{ + SendingKeys: mapToSendingKeyArr(vrfPrimaryNodeSendingKeys), + SendingKeyFundingAmount: *big.NewInt(*nodeSendingKeyFundingAmount), } bhsContractAddress := common.HexToAddress(bhsContractAddressString) @@ -126,43 +139,58 @@ func DeployUniverseViaCLI(e helpers.Environment) { coordinatorAddress := common.HexToAddress(coordinatorAddressString) batchCoordinatorAddress := common.HexToAddress(batchCoordinatorAddressString) + contractAddresses := ContractAddresses{ + LinkAddress: linkAddress, + LinkEthAddress: linkEthAddress, + BhsContractAddress: bhsContractAddress, + BatchBHSAddress: batchBHSAddress, + CoordinatorAddress: coordinatorAddress, + BatchCoordinatorAddress: batchCoordinatorAddress, + } + + coordinatorConfig := CoordinatorConfig{ + MinConfs: minConfs, + MaxGasLimit: maxGasLimit, + StalenessSeconds: stalenessSeconds, + GasAfterPayment: gasAfterPayment, + FallbackWeiPerUnitLink: fallbackWeiPerUnitLink, + FeeConfig: feeConfig, + } + VRFV2DeployUniverse( e, - fallbackWeiPerUnitLink, - subscriptionBalance, + subscriptionBalanceJuels, registerKeyUncompressedPubKey, - linkAddress, - linkEthAddress, - bhsContractAddress, - batchBHSAddress, - coordinatorAddress, - batchCoordinatorAddress, - minConfs, - maxGasLimit, - stalenessSeconds, - gasAfterPayment, - feeConfig, - nodes, + contractAddresses, + coordinatorConfig, + *batchFulfillmentEnabled, + nodesMap, ) + + vrfPrimaryNode := nodesMap[VRFPrimaryNodeName] + fmt.Println("Funding node's sending keys...") + for _, sendingKey := range vrfPrimaryNode.SendingKeys { + helpers.FundNode(e, sendingKey.Address, &vrfPrimaryNode.SendingKeyFundingAmount) + } +} + +func mapToSendingKeyArr(nodeSendingKeys []string) []SendingKey { + var sendingKeys []SendingKey + + for _, key := range nodeSendingKeys { + sendingKeys = append(sendingKeys, SendingKey{Address: key}) + } + return sendingKeys } func VRFV2DeployUniverse( e helpers.Environment, - fallbackWeiPerUnitLink *big.Int, - subscriptionBalance *big.Int, + subscriptionBalanceJuels *big.Int, registerKeyUncompressedPubKey *string, - linkAddress string, - linkEthAddress string, - bhsContractAddress common.Address, - batchBHSAddress common.Address, - coordinatorAddress common.Address, - batchCoordinatorAddress common.Address, - minConfs *int, - maxGasLimit *int64, - stalenessSeconds *int64, - gasAfterPayment *int64, - feeConfig vrf_coordinator_v2.VRFCoordinatorV2FeeConfig, - nodesMap map[string]Node, //todo - is possible to pass a pointer to the node, so that we read data and also update the data and we dont need to return "nodes" + contractAddresses ContractAddresses, + coordinatorConfig CoordinatorConfig, + batchFulfillmentEnabled bool, + nodesMap map[string]Node, ) JobSpecs { // Put key in ECDSA format @@ -188,49 +216,49 @@ func VRFV2DeployUniverse( keyHash, err := newPK.Hash() helpers.PanicErr(err) - if len(linkAddress) == 0 { + if len(contractAddresses.LinkAddress) == 0 { fmt.Println("\nDeploying LINK Token...") - linkAddress = helpers.DeployLinkToken(e).String() + contractAddresses.LinkAddress = helpers.DeployLinkToken(e).String() } - if len(linkEthAddress) == 0 { + if len(contractAddresses.LinkEthAddress) == 0 { fmt.Println("\nDeploying LINK/ETH Feed...") - linkEthAddress = helpers.DeployLinkEthFeed(e, linkAddress, fallbackWeiPerUnitLink).String() + contractAddresses.LinkEthAddress = helpers.DeployLinkEthFeed(e, contractAddresses.LinkAddress, coordinatorConfig.FallbackWeiPerUnitLink).String() } - if bhsContractAddress.String() == "0x0000000000000000000000000000000000000000" { + if contractAddresses.BhsContractAddress.String() == "0x0000000000000000000000000000000000000000" { fmt.Println("\nDeploying BHS...") - bhsContractAddress = DeployBHS(e) + contractAddresses.BhsContractAddress = DeployBHS(e) } - if batchBHSAddress.String() == "0x0000000000000000000000000000000000000000" { + if contractAddresses.BatchBHSAddress.String() == "0x0000000000000000000000000000000000000000" { fmt.Println("\nDeploying Batch BHS...") - batchBHSAddress = DeployBatchBHS(e, bhsContractAddress) + contractAddresses.BatchBHSAddress = DeployBatchBHS(e, contractAddresses.BhsContractAddress) } - if coordinatorAddress.String() == "0x0000000000000000000000000000000000000000" { + if contractAddresses.CoordinatorAddress.String() == "0x0000000000000000000000000000000000000000" { fmt.Println("\nDeploying Coordinator...") - coordinatorAddress = DeployCoordinator(e, linkAddress, bhsContractAddress.String(), linkEthAddress) + contractAddresses.CoordinatorAddress = DeployCoordinator(e, contractAddresses.LinkAddress, contractAddresses.BhsContractAddress.String(), contractAddresses.LinkEthAddress) } - coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(coordinatorAddress, e.Ec) + coordinator, err := vrf_coordinator_v2.NewVRFCoordinatorV2(contractAddresses.CoordinatorAddress, e.Ec) helpers.PanicErr(err) - if batchCoordinatorAddress.String() == "0x0000000000000000000000000000000000000000" { + if contractAddresses.BatchCoordinatorAddress.String() == "0x0000000000000000000000000000000000000000" { fmt.Println("\nDeploying Batch Coordinator...") - batchCoordinatorAddress = deployBatchCoordinatorV2(e, coordinatorAddress) + contractAddresses.BatchCoordinatorAddress = deployBatchCoordinatorV2(e, contractAddresses.CoordinatorAddress) } fmt.Println("\nSetting Coordinator Config...") SetCoordinatorConfig( e, *coordinator, - uint16(*minConfs), - uint32(*maxGasLimit), - uint32(*stalenessSeconds), - uint32(*gasAfterPayment), - fallbackWeiPerUnitLink, - feeConfig, + uint16(*coordinatorConfig.MinConfs), + uint32(*coordinatorConfig.MaxGasLimit), + uint32(*coordinatorConfig.StalenessSeconds), + uint32(*coordinatorConfig.GasAfterPayment), + coordinatorConfig.FallbackWeiPerUnitLink, + coordinatorConfig.FeeConfig, ) fmt.Println("\nConfig set, getting current config from deployed contract...") @@ -252,7 +280,7 @@ func VRFV2DeployUniverse( } fmt.Println("\nDeploying consumer...") - consumerAddress := EoaLoadTestConsumerWithMetricsDeploy(e, coordinatorAddress.String()) + consumerAddress := EoaLoadTestConsumerWithMetricsDeploy(e, contractAddresses.CoordinatorAddress.String()) fmt.Println("\nAdding subscription...") EoaCreateSub(e, *coordinator) @@ -261,9 +289,9 @@ func VRFV2DeployUniverse( fmt.Println("\nAdding consumer to subscription...") EoaAddConsumerToSub(e, *coordinator, subID, consumerAddress.String()) - if subscriptionBalance.Cmp(big.NewInt(0)) > 0 { - fmt.Println("\nFunding subscription with", subscriptionBalance, "juels...") - EoaFundSubscription(e, *coordinator, linkAddress, subscriptionBalance, subID) + if subscriptionBalanceJuels.Cmp(big.NewInt(0)) > 0 { + fmt.Println("\nFunding subscription with", subscriptionBalanceJuels, "juels...") + EoaFundSubscription(e, *coordinator, contractAddresses.LinkAddress, subscriptionBalanceJuels, subID) } else { fmt.Println("Subscription", subID, "NOT getting funded. You must fund the subscription in order to use it!") } @@ -275,74 +303,76 @@ func VRFV2DeployUniverse( formattedVrfPrimaryJobSpec := fmt.Sprintf( jobs.VRFJobFormatted, - coordinatorAddress, //coordinatorAddress - batchCoordinatorAddress, //batchCoordinatorAddress - false, //batchFulfillmentEnabled - compressedPkHex, //publicKey - *minConfs, //minIncomingConfirmations - e.ChainID, //evmChainID - strings.Join(nodesMap[VRFPrimaryNodeName].SendingKeys, "\",\""), //fromAddresses - coordinatorAddress, - coordinatorAddress, - coordinatorAddress, + contractAddresses.CoordinatorAddress, //coordinatorAddress + contractAddresses.BatchCoordinatorAddress, //batchCoordinatorAddress + batchFulfillmentEnabled, //batchFulfillmentEnabled + compressedPkHex, //publicKey + *coordinatorConfig.MinConfs, //minIncomingConfirmations + e.ChainID, //evmChainID + strings.Join(mapToAddressArr(nodesMap[VRFPrimaryNodeName].SendingKeys), "\",\""), //fromAddresses + contractAddresses.CoordinatorAddress, + nodesMap[VRFPrimaryNodeName].SendingKeys[0].Address, + contractAddresses.CoordinatorAddress, + contractAddresses.CoordinatorAddress, ) formattedVrfBackupJobSpec := fmt.Sprintf( jobs.VRFJobFormatted, - coordinatorAddress, //coordinatorAddress - batchCoordinatorAddress, //batchCoordinatorAddress - false, //batchFulfillmentEnabled - compressedPkHex, //publicKey - 100, //minIncomingConfirmations - e.ChainID, //evmChainID - strings.Join(nodesMap[VRFBackupNodeName].SendingKeys, "\",\""), //fromAddresses - coordinatorAddress, - coordinatorAddress, - coordinatorAddress, + contractAddresses.CoordinatorAddress, //coordinatorAddress + contractAddresses.BatchCoordinatorAddress, //batchCoordinatorAddress + batchFulfillmentEnabled, //batchFulfillmentEnabled + compressedPkHex, //publicKey + 100, //minIncomingConfirmations + e.ChainID, //evmChainID + strings.Join(mapToAddressArr(nodesMap[VRFBackupNodeName].SendingKeys), "\",\""), //fromAddresses + contractAddresses.CoordinatorAddress, + nodesMap[VRFPrimaryNodeName].SendingKeys[0], + contractAddresses.CoordinatorAddress, + contractAddresses.CoordinatorAddress, ) formattedBHSJobSpec := fmt.Sprintf( jobs.BHSJobFormatted, - coordinatorAddress, //coordinatorAddress - 30, //waitBlocks - 200, //lookbackBlocks - bhsContractAddress, //bhs address - e.ChainID, //chain id - strings.Join(nodesMap[BHSNodeName].SendingKeys, "\",\""), //sending addresses + contractAddresses.CoordinatorAddress, //coordinatorAddress + 30, //waitBlocks + 200, //lookbackBlocks + contractAddresses.BhsContractAddress, //bhs address + e.ChainID, //chain id + strings.Join(mapToAddressArr(nodesMap[BHSNodeName].SendingKeys), "\",\""), //sending addresses ) formattedBHSBackupJobSpec := fmt.Sprintf( jobs.BHSJobFormatted, - coordinatorAddress, //coordinatorAddress - 100, //waitBlocks - 200, //lookbackBlocks - bhsContractAddress, //bhs adreess - e.ChainID, //chain id - strings.Join(nodesMap[BHSBackupNodeName].SendingKeys, "\",\""), //sending addresses + contractAddresses.CoordinatorAddress, //coordinatorAddress + 100, //waitBlocks + 200, //lookbackBlocks + contractAddresses.BhsContractAddress, //bhs adreess + e.ChainID, //chain id + strings.Join(mapToAddressArr(nodesMap[BHSBackupNodeName].SendingKeys), "\",\""), //sending addresses ) formattedBHFJobSpec := fmt.Sprintf( jobs.BHFJobFormatted, - coordinatorAddress, //coordinatorAddress - bhsContractAddress, //bhs adreess - batchBHSAddress, //batchBHS - e.ChainID, //chain id - strings.Join(nodesMap[BHFNodeName].SendingKeys, "\",\""), //sending addresses + contractAddresses.CoordinatorAddress, //coordinatorAddress + contractAddresses.BhsContractAddress, //bhs adreess + contractAddresses.BatchBHSAddress, //batchBHS + e.ChainID, //chain id + strings.Join(mapToAddressArr(nodesMap[BHFNodeName].SendingKeys), "\",\""), //sending addresses ) fmt.Println( "\nDeployment complete.", - "\nLINK Token contract address:", linkAddress, - "\nLINK/ETH Feed contract address:", linkEthAddress, - "\nBlockhash Store contract address:", bhsContractAddress, - "\nBatch Blockhash Store contract address:", batchBHSAddress, - "\nVRF Coordinator Address:", coordinatorAddress, - "\nBatch VRF Coordinator Address:", batchCoordinatorAddress, + "\nLINK Token contract address:", contractAddresses.LinkAddress, + "\nLINK/ETH Feed contract address:", contractAddresses.LinkEthAddress, + "\nBlockhash Store contract address:", contractAddresses.BhsContractAddress, + "\nBatch Blockhash Store contract address:", contractAddresses.BatchBHSAddress, + "\nVRF Coordinator Address:", contractAddresses.CoordinatorAddress, + "\nBatch VRF Coordinator Address:", contractAddresses.BatchCoordinatorAddress, "\nVRF Consumer Address:", consumerAddress, "\nVRF Subscription Id:", subID, - "\nVRF Subscription Balance:", *subscriptionBalance, + "\nVRF Subscription Balance:", *subscriptionBalanceJuels, "\nPossible VRF Request command: ", - fmt.Sprintf("go run . eoa-load-test-request-with-metrics --consumer-address=%s --sub-id=%d --key-hash=%s --request-confirmations %d --requests 1 --runs 1 --cb-gas-limit 1_000_000", consumerAddress, subID, keyHash, *minConfs), + fmt.Sprintf("go run . eoa-load-test-request-with-metrics --consumer-address=%s --sub-id=%d --key-hash=%s --request-confirmations %d --requests 1 --runs 1 --cb-gas-limit 1_000_000", consumerAddress, subID, keyHash, *coordinatorConfig.MinConfs), "\nRetrieve Request Status: ", fmt.Sprintf("go run . eoa-load-test-read-metrics --consumer-address=%s", consumerAddress), "\nA node can now be configured to run a VRF job with the below job spec :\n", @@ -358,6 +388,14 @@ func VRFV2DeployUniverse( } } +func mapToAddressArr(sendingKeys []SendingKey) []string { + var sendingKeysString []string + for _, sendingKey := range sendingKeys { + sendingKeysString = append(sendingKeysString, sendingKey.Address) + } + return sendingKeysString +} + func DeployWrapperUniverse(e helpers.Environment) { cmd := flag.NewFlagSet("wrapper-universe-deploy", flag.ExitOnError) linkAddress := cmd.String("link-address", "", "address of link token") diff --git a/core/scripts/vrfv2/testnet/setup-envs/README.md b/core/scripts/vrfv2/testnet/setup-envs/README.md index c158cd6f541..ed045003fba 100644 --- a/core/scripts/vrfv2/testnet/setup-envs/README.md +++ b/core/scripts/vrfv2/testnet/setup-envs/README.md @@ -27,6 +27,8 @@ go run . \ --bhs-bk-creds-file \ --bhf-node-url=http://localhost:6614 \ --bhf-creds-file \ +--batch-fulfillment-enabled true \ +--min-confs 1 \ --num-eth-keys 5 \ --num-vrf-keys 1 \ --sending-key-funding-amount 100000000000000000 diff --git a/core/scripts/vrfv2/testnet/setup-envs/main.go b/core/scripts/vrfv2/testnet/setup-envs/main.go index eb692031f9c..1196108b32f 100644 --- a/core/scripts/vrfv2/testnet/setup-envs/main.go +++ b/core/scripts/vrfv2/testnet/setup-envs/main.go @@ -66,6 +66,9 @@ func main() { maxGasPriceGwei := flag.Int("max-gas-price-gwei", -1, "Max gas price gwei of the eth keys") numVRFKeys := flag.Int("num-vrf-keys", 1, "Number of vrf keys to create") + batchFulfillmentEnabled := flag.Bool("batch-fulfillment-enabled", constants.BatchFulfillmentEnabled, "whether to enable batch fulfillment on Cl node") + minConfs := flag.Int("min-confs", constants.MinConfs, "minimum confirmations") + linkAddress := flag.String("link-address", "", "address of link token") linkEthAddress := flag.String("link-eth-feed", "", "address of link eth feed") bhsContractAddressString := flag.String("bhs-address", "", "address of BHS contract") @@ -75,47 +78,47 @@ func main() { e := helpers.SetupEnv(false) flag.Parse() - nodes := make(map[string]scripts.Node) + nodesMap := make(map[string]scripts.Node) if *vrfPrimaryNodeURL != "" { - nodes[scripts.VRFPrimaryNodeName] = scripts.Node{ + nodesMap[scripts.VRFPrimaryNodeName] = scripts.Node{ URL: *vrfPrimaryNodeURL, - SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + SendingKeyFundingAmount: *big.NewInt(*nodeSendingKeyFundingAmount), CredsFile: *vrfPrimaryCredsFile, } } if *vrfBackupNodeURL != "" { - nodes[scripts.VRFBackupNodeName] = scripts.Node{ + nodesMap[scripts.VRFBackupNodeName] = scripts.Node{ URL: *vrfBackupNodeURL, - SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + SendingKeyFundingAmount: *big.NewInt(*nodeSendingKeyFundingAmount), CredsFile: *vrfBackupCredsFile, } } if *bhsNodeURL != "" { - nodes[scripts.BHSNodeName] = scripts.Node{ + nodesMap[scripts.BHSNodeName] = scripts.Node{ URL: *bhsNodeURL, - SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + SendingKeyFundingAmount: *big.NewInt(*nodeSendingKeyFundingAmount), CredsFile: *bhsCredsFile, } } if *bhsBackupNodeURL != "" { - nodes[scripts.BHSBackupNodeName] = scripts.Node{ + nodesMap[scripts.BHSBackupNodeName] = scripts.Node{ URL: *bhsBackupNodeURL, - SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + SendingKeyFundingAmount: *big.NewInt(*nodeSendingKeyFundingAmount), CredsFile: *bhsBackupCredsFile, } } if *bhfNodeURL != "" { - nodes[scripts.BHFNodeName] = scripts.Node{ + nodesMap[scripts.BHFNodeName] = scripts.Node{ URL: *bhfNodeURL, - SendingKeyFundingAmount: *nodeSendingKeyFundingAmount, + SendingKeyFundingAmount: *big.NewInt(*nodeSendingKeyFundingAmount), CredsFile: *bhfCredsFile, } } output := &bytes.Buffer{} - for key, node := range nodes { + for key, node := range nodesMap { client, app := connectToNode(&node.URL, output, node.CredsFile) ethKeys := createETHKeysIfNeeded(client, app, output, numEthKeys, &node.URL, maxGasPriceGwei) @@ -131,16 +134,12 @@ func main() { node.VrfKeys = mapVrfKeysToStringArr(vrfKeys) } - node.SendingKeys = mapEthKeysToStringArr(ethKeys) - nodes[key] = node + node.SendingKeys = mapEthKeysToSendingKeyArr(ethKeys) printETHKeyData(ethKeys) - - if node.SendingKeyFundingAmount > 0 { - fmt.Println("\nFunding ", key, " Node's Sending Keys...") - helpers.FundNodes(e, node.SendingKeys, big.NewInt(node.SendingKeyFundingAmount)) - } + fundNodesIfNeeded(node, key, e) + nodesMap[key] = node } - importVRFKeyToNodeIfSet(vrfBackupNodeURL, nodes, output, nodes[scripts.VRFBackupNodeName].CredsFile) + importVRFKeyToNodeIfSet(vrfBackupNodeURL, nodesMap, output, nodesMap[scripts.VRFBackupNodeName].CredsFile) fmt.Println() feeConfig := vrf_coordinator_v2.VRFCoordinatorV2FeeConfig{ FulfillmentFlatFeeLinkPPMTier1: uint32(constants.FlatFeeTier1), @@ -154,26 +153,35 @@ func main() { ReqsForTier5: big.NewInt(constants.ReqsForTier5), } + contractAddresses := scripts.ContractAddresses{ + LinkAddress: *linkAddress, + LinkEthAddress: *linkEthAddress, + BhsContractAddress: common.HexToAddress(*bhsContractAddressString), + BatchBHSAddress: common.HexToAddress(*batchBHSAddressString), + CoordinatorAddress: common.HexToAddress(*coordinatorAddressString), + BatchCoordinatorAddress: common.HexToAddress(*batchCoordinatorAddressString), + } + + coordinatorConfig := scripts.CoordinatorConfig{ + MinConfs: minConfs, + MaxGasLimit: &constants.MaxGasLimit, + StalenessSeconds: &constants.StalenessSeconds, + GasAfterPayment: &constants.GasAfterPayment, + FallbackWeiPerUnitLink: constants.FallbackWeiPerUnitLink, + FeeConfig: feeConfig, + } + jobSpecs := scripts.VRFV2DeployUniverse( e, - constants.FallbackWeiPerUnitLink, constants.SubscriptionBalanceJuels, - &nodes[scripts.VRFPrimaryNodeName].VrfKeys[0], - *linkAddress, - *linkEthAddress, - common.HexToAddress(*bhsContractAddressString), - common.HexToAddress(*batchBHSAddressString), - common.HexToAddress(*coordinatorAddressString), - common.HexToAddress(*batchCoordinatorAddressString), - &constants.MinConfs, - &constants.MaxGasLimit, - &constants.StalenessSeconds, - &constants.GasAfterPayment, - feeConfig, - nodes, + &nodesMap[scripts.VRFPrimaryNodeName].VrfKeys[0], + contractAddresses, + coordinatorConfig, + *batchFulfillmentEnabled, + nodesMap, ) - for key, node := range nodes { + for key, node := range nodesMap { client, app := connectToNode(&node.URL, output, node.CredsFile) //GET ALL JOBS @@ -199,6 +207,20 @@ func main() { } } +func fundNodesIfNeeded(node scripts.Node, key string, e helpers.Environment) { + if node.SendingKeyFundingAmount.Int64() > 0 { + fmt.Println("\nFunding", key, "Node's Sending Keys...") + for _, sendingKey := range node.SendingKeys { + fundingToSendWei := node.SendingKeyFundingAmount.Int64() - sendingKey.BalanceEth.Int64() + if fundingToSendWei > 0 { + helpers.FundNode(e, sendingKey.Address, big.NewInt(fundingToSendWei)) + } else { + fmt.Println("\nSkipping Funding", sendingKey.Address, "since it has", sendingKey.BalanceEth.Int64(), "wei") + } + } + } +} + func importVRFKeyToNodeIfSet(vrfBackupNodeURL *string, nodes map[string]scripts.Node, output *bytes.Buffer, file string) { if *vrfBackupNodeURL != "" { vrfBackupNode := nodes[scripts.VRFBackupNodeName] @@ -307,12 +329,13 @@ func printETHKeyData(ethKeys []presenters.ETHKeyResource) { } } -func mapEthKeysToStringArr(ethKeys []presenters.ETHKeyResource) []string { - var ethKeysString []string +func mapEthKeysToSendingKeyArr(ethKeys []presenters.ETHKeyResource) []scripts.SendingKey { + var sendingKeys []scripts.SendingKey for _, ethKey := range ethKeys { - ethKeysString = append(ethKeysString, ethKey.Address) + sendingKey := scripts.SendingKey{Address: ethKey.Address, BalanceEth: *ethKey.EthBalance.ToInt()} + sendingKeys = append(sendingKeys, sendingKey) } - return ethKeysString + return sendingKeys } func mapVrfKeysToStringArr(vrfKeys []presenters.VRFKeyResource) []string { @@ -358,7 +381,7 @@ func createVRFKeyIfNeeded(client *clcmd.Shell, app *cli.App, output *bytes.Buffe switch { case len(vrfKeys) == *numVRFKeys: - fmt.Println(checkMarkEmoji, "found", len(vrfKeys), "vrf keys on", nodeURL) + fmt.Println(checkMarkEmoji, "found", len(vrfKeys), "vrf keys on", *nodeURL) case len(vrfKeys) > *numVRFKeys: fmt.Println(xEmoji, "found", len(vrfKeys), "vrf keys on", nodeURL, " which is more than expected") os.Exit(1) @@ -410,9 +433,9 @@ func createETHKeysIfNeeded(client *clcmd.Shell, app *cli.App, output *bytes.Buff helpers.PanicErr(json.Unmarshal(output.Bytes(), ðKeys)) switch { case len(ethKeys) >= *numEthKeys: - fmt.Println(checkMarkEmoji, "found", len(ethKeys), "eth keys on", nodeURL) + fmt.Println(checkMarkEmoji, "found", len(ethKeys), "eth keys on", *nodeURL) case len(ethKeys) < *numEthKeys: - fmt.Println(xEmoji, "found only", len(ethKeys), "eth keys on", nodeURL, + fmt.Println(xEmoji, "found only", len(ethKeys), "eth keys on", *nodeURL, "; creating", *numEthKeys-len(ethKeys), "more") toCreate := *numEthKeys - len(ethKeys) for i := 0; i < toCreate; i++ { From b79f88ab942adc373fc9a6798586c170ffeb40ce Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Fri, 11 Aug 2023 10:27:55 -0400 Subject: [PATCH 148/270] Fix Live Runs and Wacky Reports (#10153) * Fix runs and wacky reports * DEBUG * More debugs * Remove debug * Update version --- .github/workflows/integration-tests.yml | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 2de2728eeaf..ed657cc0c11 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -319,7 +319,7 @@ jobs: run: | echo "Running migration tests from version '${{ steps.get_latest_version.outputs.latest_version }}' to: '${{ github.sha }}'" - name: Run Migration Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json ./migration 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download @@ -556,7 +556,7 @@ jobs: ref: ${{ needs.get_solana_sha.outputs.sha }} - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 with: test_command_to_run: export ENV_JOB_IMAGE=${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/chainlink-solana-tests:${{ needs.get_solana_sha.outputs.sha }} && make test_smoke cl_repo: ${{ env.CHAINLINK_IMAGE }} @@ -618,16 +618,17 @@ jobs: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} ## Only run OCR smoke test for now - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 env: PYROSCOPE_SERVER: ${{ secrets.QA_PYROSCOPE_INSTANCE }} PYROSCOPE_ENVIRONMENT: ci-smoke-ocr-evm-${{ matrix.testnet }} # TODO: Only for OCR for now PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }} with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json -test.parallel=1 ./smoke/ocr_test.go 2>&1 | tee /tmp/gotest.log | gotestfmt - test_download_vendor_packages_command: make gomod + test_download_vendor_packages_command: cd ./integration-tests && go mod download cl_repo: ${{ env.CHAINLINK_IMAGE }} cl_image_tag: ${{ github.sha }} + aws_registries: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} artifacts_location: ./integration-tests/smoke/logs publish_check_name: ${{ matrix.testnet }} OCR Smoke Test Results token: ${{ secrets.GITHUB_TOKEN }} @@ -635,7 +636,6 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} - continue-on-error: true - name: Collect Metrics if: always() @@ -650,6 +650,7 @@ jobs: testnet-smoke-tests-notify: name: Live Testnet Start Slack Thread + if: ${{ success() || failure() }} environment: integration outputs: thread_ts: ${{ steps.slack.outputs.thread_ts }} From c620d67a88931353005aa75025e743c398b37ac4 Mon Sep 17 00:00:00 2001 From: Michael Fletcher <36506122+Fletch153@users.noreply.github.com> Date: Fri, 11 Aug 2023 15:38:48 +0100 Subject: [PATCH 149/270] Feature/merc 908/integrate billing and rewards (#10103) * Initial implementation of Reward contract * Update mentions of "NOP" to "Payee" + Optimizations * Update function names + event * make proxy upgradable as not needed when onFeePaid * update rewards contract to claim model * Initial implementation of Reward contract * initial implementation * Added LINK + native support + optimisations * Update Native address to wrapped contract * Initial e2e impl * Add functionality to pay all nops within a pool * Amendments and tests * Additional tests * Added ByteUtil tests and removed unused impl * Update verifier test locations * Updates and fixes to tests * Reward Manager tests + prettier * Removed ability to add and remove from reward set * Changed Assets -> uint256 to save gas * Added FeeManager tests * Prevent premiums exceeding 100% * Added support for Unwrapped Native * Added events and tests * Fixed rounding error issues * reward/fee managers are now modifiable * Calldata optimisations * Mitigate parasitic usage risk * Added native billing + cleanup * Added expiry + clean up + tests * Final review of RM * Reorganize contract code and minor FeeManager updates (tests failing) * Fix padding issues & broken tests * Remove SafeERC20 as its not req * fixes + additional tests to FeeManager * Fixes + remaining tests * Added linkAvailableForPayment * Added gas tests * prettier * Improve (somewhat) gas estimations * Bulk approve transfers from feeManager -> rewardManager * Small optimisation * Updates to comments and terminology * Terminology updates * Snapshot * Rebase upstream repo * Update llo go wrappers * update gas snapshots * move dependencies to vendor * small fixes * update pnpm lockfile * update file name to fix test failures * update wrappers * update gas snapshots * Update llo wrappers * Fixed integration tests * Fixed issue around claiming when recipients not set * Add report versioning to FeeManager * Update version to begining of bytes * Update naming to align with convention * gas snapshot * clean up vendor * Add event when paying into pool * Bug fixes * Move contracts to dev until audit * Fixes + optimisations --------- Co-authored-by: Austin Born --- CODEOWNERS | 2 + GNUmakefile | 2 +- contracts/.gas-snapshot | 115 +- contracts/pnpm-lock.yaml | 40 + contracts/scripts/native_solc_compile_all_llo | 2 + contracts/src/v0.8/libraries/ByteUtil.sol | 82 + contracts/src/v0.8/libraries/Common.sol | 43 + .../v0.8/libraries/test/ByteUtilTest.t.sol | 177 ++ contracts/src/v0.8/llo-feeds/Verifier.sol | 209 ++- .../src/v0.8/llo-feeds/VerifierProxy.sol | 100 +- .../src/v0.8/llo-feeds/dev/FeeManager.sol | 356 ++++ .../src/v0.8/llo-feeds/dev/RewardManager.sol | 308 ++++ .../llo-feeds/dev/interfaces/IFeeManager.sol | 64 + .../dev/interfaces/IRewardManager.sol | 54 + .../v0.8/llo-feeds/interfaces/IVerifier.sol | 41 +- .../interfaces/IVerifierFeeManager.sol | 24 + .../llo-feeds/interfaces/IVerifierProxy.sol | 50 +- .../test/fee-manager/BaseFeeManager.t.sol | 344 ++++ .../test/fee-manager/FeeManager.general.t.sol | 137 ++ .../FeeManager.getFeeAndReward.t.sol | 569 ++++++ .../fee-manager/FeeManager.processFee.t.sol | 330 ++++ .../llo-feeds/test/gas/Gas_VerifierTest.t.sol | 82 +- .../llo-feeds/test/mocks/ErroredVerifier.sol | 38 +- .../reward-manager/BaseRewardManager.t.sol | 248 +++ .../reward-manager/RewardManager.claim.t.sol | 740 ++++++++ .../RewardManager.general.t.sol | 66 + .../RewardManager.payRecipients.t.sol | 191 ++ .../RewardManager.setRecipients.t.sol | 152 ++ ...RewardManager.updateRewardRecipients.t.sol | 466 +++++ .../{ => verifier}/BaseVerifierTest.t.sol | 215 ++- .../VerifierActivateConfigTest.t.sol | 15 +- .../VerifierDeactivateFeedTest.t.sol | 15 +- .../VerifierProxyConstructorTest.t.sol | 10 +- .../VerifierProxyInitializeVerifierTest.t.sol | 7 +- ...VerifierProxySetAccessControllerTest.t.sol | 6 +- .../VerifierProxySetVerifierTest.t.sol | 19 +- .../test/verifier/VerifierProxyTest.t.sol | 17 + .../VerifierProxyUnsetVerifierTest.t.sol | 10 +- .../VerifierSetConfigTest.t.sol | 38 +- .../test/{ => verifier}/VerifierTest.t.sol | 6 +- .../verifier/VerifierTestBillingReport.t.sol | 81 + .../VerifierUnsetConfigTest.t.sol | 6 +- .../{ => verifier}/VerifierVerifyTest.t.sol | 34 +- .../src/v0.8/shared/interfaces/IWERC20.sol | 8 + .../src/v0.8/shared/mocks/WERC20Mock.sol | 35 + .../v4.8.0/contracts/interfaces/IERC165.sol | 6 + .../v4.8.0/contracts/interfaces/IERC20.sol | 6 + .../v4.8.0/contracts/mocks/ERC20Mock.sol | 41 + .../contracts/utils/introspection/IERC165.sol | 25 + .../mercury_verifier/mercury_verifier.go | 23 +- .../mercury_verifier_proxy.go | 245 ++- ...rapper-dependency-versions-do-not-edit.txt | 5 - core/gethwrappers/go_generate.go | 4 +- core/gethwrappers/go_generate_llo.go | 9 - .../errored_verifier/errored_verifier.go | 393 ++++ .../exposed_verifier/exposed_verifier.go | 202 +++ .../generated/fee_manager/fee_manager.go | 1318 ++++++++++++++ .../generated/llo_feeds/llo_feeds.go | 1318 ++++++++++++++ .../llo_feeds_test/llo_feeds_test.go | 202 +++ .../reward_manager/reward_manager.go | 1344 ++++++++++++++ .../llo-feeds/generated/verifier/verifier.go | 1602 +++++++++++++++++ .../verifier_proxy/verifier_proxy.go | 1373 ++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 9 + core/gethwrappers/llo-feeds/go_generate.go | 11 + .../ocr2/plugins/mercury/integration_test.go | 1 + .../relay/evm/mercury/config_poller_test.go | 3 +- 66 files changed, 13242 insertions(+), 452 deletions(-) create mode 100644 contracts/src/v0.8/libraries/ByteUtil.sol create mode 100644 contracts/src/v0.8/libraries/Common.sol create mode 100644 contracts/src/v0.8/libraries/test/ByteUtilTest.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/dev/FeeManager.sol create mode 100644 contracts/src/v0.8/llo-feeds/dev/RewardManager.sol create mode 100644 contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol create mode 100644 contracts/src/v0.8/llo-feeds/dev/interfaces/IRewardManager.sol create mode 100644 contracts/src/v0.8/llo-feeds/interfaces/IVerifierFeeManager.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.getFeeAndReward.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/reward-manager/BaseRewardManager.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.claim.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.general.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.payRecipients.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.setRecipients.t.sol create mode 100644 contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.updateRewardRecipients.t.sol rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/BaseVerifierTest.t.sol (56%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierActivateConfigTest.t.sol (81%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierDeactivateFeedTest.t.sol (88%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierProxyConstructorTest.t.sol (67%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierProxyInitializeVerifierTest.t.sol (78%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierProxySetAccessControllerTest.t.sol (82%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierProxySetVerifierTest.t.sol (67%) create mode 100644 contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyTest.t.sol rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierProxyUnsetVerifierTest.t.sol (79%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierSetConfigTest.t.sol (88%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierTest.t.sol (90%) create mode 100644 contracts/src/v0.8/llo-feeds/test/verifier/VerifierTestBillingReport.t.sol rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierUnsetConfigTest.t.sol (90%) rename contracts/src/v0.8/llo-feeds/test/{ => verifier}/VerifierVerifyTest.t.sol (90%) create mode 100644 contracts/src/v0.8/shared/interfaces/IWERC20.sol create mode 100644 contracts/src/v0.8/shared/mocks/WERC20Mock.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol delete mode 100644 core/gethwrappers/go_generate_llo.go create mode 100644 core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go create mode 100644 core/gethwrappers/llo-feeds/generated/exposed_verifier/exposed_verifier.go create mode 100644 core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go create mode 100644 core/gethwrappers/llo-feeds/generated/llo_feeds/llo_feeds.go create mode 100644 core/gethwrappers/llo-feeds/generated/llo_feeds_test/llo_feeds_test.go create mode 100644 core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go create mode 100644 core/gethwrappers/llo-feeds/generated/verifier/verifier.go create mode 100644 core/gethwrappers/llo-feeds/generated/verifier_proxy/verifier_proxy.go create mode 100644 core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt create mode 100644 core/gethwrappers/llo-feeds/go_generate.go diff --git a/CODEOWNERS b/CODEOWNERS index 819f3fd7340..84039a72266 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -64,12 +64,14 @@ core/services/ocr2/plugins/functions @bolekk @justinkaseman @KuphJr @pinebit /contracts/**/*Upkeep* @smartcontractkit/keepers /contracts/**/*Functions* @bolekk @justinkaseman @KuphJr @pinebit /contracts/src/v0.8/functions @bolekk @justinkaseman @KuphJr @pinebit +/contracts/src/v0.8/llo-feeds @austinborn @Fletch153 # Tests /integration-tests/ @smartcontractkit/test-tooling-team /integration-tests/**/*keeper* @smartcontractkit/keepers /integration-tests/**/*automation* @smartcontractkit/keepers + # CI/CD /.github/** @chainchad @javuto @jkongie @jmank88 @samsondav /.github/workflows/integration-tests.yml @smartcontractkit/test-tooling-team diff --git a/GNUmakefile b/GNUmakefile index fb821b3880f..0feef78effd 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -117,7 +117,7 @@ go-solidity-wrappers-functions: pnpmdep abigen ## Recompiles solidity contracts .PHONY: go-solidity-wrappers-llo go-solidity-wrappers-llo: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. ./contracts/scripts/native_solc_compile_all_llo - go generate ./core/gethwrappers/go_generate_llo.go + go generate ./core/gethwrappers/llo-feeds/go_generate.go .PHONY: generate generate: abigen codecgen mockery ## Execute all go:generate commands. diff --git a/contracts/.gas-snapshot b/contracts/.gas-snapshot index 15c5b599d6e..34c7e6a348a 100644 --- a/contracts/.gas-snapshot +++ b/contracts/.gas-snapshot @@ -1,111 +1,8 @@ -AutomationForwarder_forward:testBasicSuccess() (gas: 87621) -AutomationForwarder_forward:testNotAuthorizedReverts() (gas: 20812) -AutomationForwarder_forward:testWrongFunctionSelectorSuccess() (gas: 17949) -AutomationForwarder_updateRegistry:testBasicSuccess() (gas: 14577) -AutomationForwarder_updateRegistry:testNotFromRegistryNotAuthorizedReverts() (gas: 13893) -EIP_712_1014_4337:testEIP712EIP4337AndCreateSmartContractAccount() (gas: 910680) -EIP_712_1014_4337:testEIP712EIP4337AndCreateSmartContractAccountWithPaymaster() (gas: 2299908) -EIP_712_1014_4337:testEIP712EIP4337AndCreateSmartContractAccountWithPaymasterForVRFRequest() (gas: 2893568) -EIP_712_1014_4337:testEIP712EIP4337WithExistingSmartContractAccount() (gas: 875294) -FunctionsOracle_sendRequest:testEmptyRequestDataReverts() (gas: 13430) -FunctionsOracle_setDONPublicKey:testEmptyPublicKeyReverts() (gas: 10974) -FunctionsOracle_setDONPublicKey:testOnlyOwnerReverts() (gas: 11255) -FunctionsOracle_setDONPublicKey:testSetDONPublicKeySuccess() (gas: 126453) FunctionsOracle_setDONPublicKey:testSetDONPublicKey_gas() (gas: 97558) -FunctionsOracle_setRegistry:testEmptyPublicKeyReverts() (gas: 10635) -FunctionsOracle_setRegistry:testOnlyOwnerReverts() (gas: 10927) -FunctionsOracle_setRegistry:testSetRegistrySuccess() (gas: 35791) FunctionsOracle_setRegistry:testSetRegistry_gas() (gas: 31987) -FunctionsOracle_typeAndVersion:testTypeAndVersionSuccess() (gas: 6905) -FunctionsRouter_createSubscription:testCreateSubscriptionSuccess() (gas: 4946892) -HeartbeatRequester_getAggregatorRequestHeartbeat:testBasicSuccess() (gas: 75412) -HeartbeatRequester_getAggregatorRequestHeartbeat:testHeartbeatNotPermittedReverts() (gas: 21730) -HeartbeatRequester_permitHeartbeat:testBasicDeployerSuccess() (gas: 48280) -HeartbeatRequester_permitHeartbeat:testBasicSuccess() (gas: 45856) -HeartbeatRequester_permitHeartbeat:testOnlyCallableByOwnerReverts() (gas: 13796) -HeartbeatRequester_removeHeartbeat:testBasicSuccess() (gas: 30192) -HeartbeatRequester_removeHeartbeat:testOnlyCallableByOwnerReverts() (gas: 11629) -HeartbeatRequester_removeHeartbeat:testRemoveNoPermitsSuccess() (gas: 15660) -VRFCoordinatorV2Plus_Migration:testDeregister() (gas: 98037) -VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCaller() (gas: 27076) -VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCoordinator() (gas: 17633) -VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenPendingFulfillment() (gas: 239503) -VRFCoordinatorV2Plus_Migration:testMigration() (gas: 447420) -VRFV2Plus:testCreateSubscription() (gas: 92680) -VRFV2Plus:testRegisterProvingKey() (gas: 100709) -VRFV2Plus:testRequestAndFulfillRandomWordsLINK() (gas: 669592) -VRFV2Plus:testRequestAndFulfillRandomWordsNative() (gas: 620387) -VRFV2Plus:testSetConfig() (gas: 72716) -VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsLINKWrapper() (gas: 374856) -VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsNativeWrapper() (gas: 275074) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesAMiddleDigest() (gas: 24243) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesTheFirstDigest() (gas: 24210) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyUnsetsDigestsInSequence() (gas: 44307) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfCalledByNonOwner() (gas: 11322) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnEmptyDigest() (gas: 10951) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnNonExistentDigest() (gas: 13425) -VerifierActivateConfigTest:test_revertsIfDigestIsEmpty() (gas: 10939) -VerifierActivateConfigTest:test_revertsIfDigestNotSet() (gas: 13371) -VerifierActivateConfigTest:test_revertsIfNotOwner() (gas: 13410) -VerifierActivateConfigWithDeactivatedConfigTest:test_allowsVerification() (gas: 93382) -VerifierActivateFeedTest:test_revertsIfNoFeedExistsActivate() (gas: 13179) -VerifierActivateFeedTest:test_revertsIfNoFeedExistsDeactivate() (gas: 13179) -VerifierActivateFeedTest:test_revertsIfNotOwnerActivateFeed() (gas: 13360) -VerifierActivateFeedTest:test_revertsIfNotOwnerDeactivateFeed() (gas: 13437) -VerifierConstructorTest:test_revertsIfInitializedWithEmptyVerifierProxy() (gas: 59748) -VerifierConstructorTest:test_setsTheCorrectProperties() (gas: 1613888) -VerifierDeactivateFeedWithVerifyTest:test_currentReportAllowsVerification() (gas: 188235) -VerifierDeactivateFeedWithVerifyTest:test_currentReportFailsVerification() (gas: 108080) -VerifierDeactivateFeedWithVerifyTest:test_previousReportAllowsVerification() (gas: 95709) -VerifierDeactivateFeedWithVerifyTest:test_previousReportFailsVerification() (gas: 64662) -VerifierProxyAccessControlledVerificationTest:test_proxiesToTheVerifierIfHasAccess() (gas: 193000) -VerifierProxyAccessControlledVerificationTest:test_revertsIfNoAccess() (gas: 104244) -VerifierProxyConstructorTest:test_correctlySetsTheCorrectAccessControllerInterface() (gas: 868185) -VerifierProxyConstructorTest:test_correctlySetsTheOwner() (gas: 848303) -VerifierProxyConstructorTest:test_correctlySetsVersion() (gas: 6961) -VerifierProxyInitializeVerifierTest:test_revertsIfDigestAlreadySet() (gas: 49842) -VerifierProxyInitializeVerifierTest:test_revertsIfNotCorrectVerifier() (gas: 13103) -VerifierProxyInitializeVerifierTest:test_revertsIfNotOwner() (gas: 13375) -VerifierProxyInitializeVerifierTest:test_revertsIfVerifierAlreadyInitialized() (gas: 41915) -VerifierProxyInitializeVerifierTest:test_revertsIfZeroAddress() (gas: 10904) -VerifierProxyInitializeVerifierTest:test_updatesVerifierIfVerifier() (gas: 49086) -VerifierProxySetAccessControllerTest:test_emitsTheCorrectEvent() (gas: 35362) -VerifierProxySetAccessControllerTest:test_revertsIfCalledByNonOwner() (gas: 11345) -VerifierProxySetAccessControllerTest:test_successfullySetsNewAccessController() (gas: 32027) -VerifierProxySetAccessControllerTest:test_successfullySetsNewAccessControllerIsEmpty() (gas: 12126) -VerifierProxyUnsetVerifierTest:test_revertsIfDigestDoesNotExist() (gas: 13174) -VerifierProxyUnsetVerifierTest:test_revertsIfNotAdmin() (gas: 11249) -VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest:test_correctlyUnsetsVerifier() (gas: 12686) -VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest:test_emitsAnEventAfterUnsettingVerifier() (gas: 17965) -VerifierProxyVerifyTest:test_proxiesToTheCorrectVerifier() (gas: 190392) -VerifierProxyVerifyTest:test_revertsIfNoVerifierConfigured() (gas: 106909) -VerifierSetConfigTest:test_correctlyUpdatesTheConfig() (gas: 1056693) -VerifierSetConfigTest:test_revertsIfCalledByNonOwner() (gas: 178549) -VerifierSetConfigTest:test_revertsIfDuplicateSigners() (gas: 250802) -VerifierSetConfigTest:test_revertsIfFaultToleranceIsZero() (gas: 175843) -VerifierSetConfigTest:test_revertsIfNotEnoughSigners() (gas: 15106) -VerifierSetConfigTest:test_revertsIfSetWithTooManySigners() (gas: 21461) -VerifierSetConfigTest:test_revertsIfSignerContainsZeroAddress() (gas: 227232) -VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlySetsConfigWhenDigestsAreRemoved() (gas: 537498) -VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesDigestsOnMultipleVerifiersInTheProxy() (gas: 961835) -VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 518984) -VerifierSupportsInterfaceTest:test_falseIfIsNotCorrectInterface() (gas: 5590) -VerifierSupportsInterfaceTest:test_trueIfIsCorrectInterface() (gas: 5611) -VerifierVerifyMultipleConfigDigestTest:test_canVerifyNewerReportsWithNewerConfigs() (gas: 127391) -VerifierVerifyMultipleConfigDigestTest:test_canVerifyOlderReportsWithOlderConfigs() (gas: 183273) -VerifierVerifyMultipleConfigDigestTest:test_revertsIfAReportIsVerifiedWithAnExistingButIncorrectDigest() (gas: 82823) -VerifierVerifyMultipleConfigDigestTest:test_revertsIfVerifyingWithAnUnsetDigest() (gas: 122803) -VerifierVerifySingleConfigDigestTest:test_emitsAnEventIfReportVerified() (gas: 183146) -VerifierVerifySingleConfigDigestTest:test_returnsThePriceAndBlockNumIfReportVerified() (gas: 183283) -VerifierVerifySingleConfigDigestTest:test_revertsIfConfigDigestNotSet() (gas: 110853) -VerifierVerifySingleConfigDigestTest:test_revertsIfDuplicateSignersHaveSigned() (gas: 177012) -VerifierVerifySingleConfigDigestTest:test_revertsIfMismatchedSignatureLength() (gas: 47600) -VerifierVerifySingleConfigDigestTest:test_revertsIfReportHasUnconfiguredFeedID() (gas: 98652) -VerifierVerifySingleConfigDigestTest:test_revertsIfVerifiedByNonProxy() (gas: 99453) -VerifierVerifySingleConfigDigestTest:test_revertsIfVerifiedWithIncorrectAddresses() (gas: 178753) -VerifierVerifySingleConfigDigestTest:test_revertsIfWrongNumberOfSigners() (gas: 104735) -VerifierVerifySingleConfigDigestTest:test_setsTheCorrectEpoch() (gas: 190459) -Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 194809) -Verifier_setConfig:testSetConfigSuccess_gas() (gas: 921474) -Verifier_verify:testVerifyProxySuccess_gas() (gas: 185263) -Verifier_verify:testVerifySuccess_gas() (gas: 180648) \ No newline at end of file +Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 207063) +Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922517) +Verifier_verify:testVerifyProxySuccess_gas() (gas: 197508) +Verifier_verify:testVerifySuccess_gas() (gas: 182991) +Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245475) +Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 262092) \ No newline at end of file diff --git a/contracts/pnpm-lock.yaml b/contracts/pnpm-lock.yaml index 08064578c6d..da673532152 100644 --- a/contracts/pnpm-lock.yaml +++ b/contracts/pnpm-lock.yaml @@ -414,6 +414,7 @@ packages: /@ethersproject/abi@5.0.0-beta.153: resolution: {integrity: sha512-aXweZ1Z7vMNzJdLpR1CZUAIgnwjrZeUSvN9syCwlBaEBUFJmFY+HHnfuTI5vIhVs/mRkfJVrbEyl51JZQqyjAg==} + requiresBuild: true dependencies: '@ethersproject/address': 5.7.0 '@ethersproject/bignumber': 5.7.0 @@ -1572,6 +1573,7 @@ packages: /@sindresorhus/is@0.14.0: resolution: {integrity: sha512-9NET910DNaIPngYnLLPeg+Ogzqsi9uM4mSboU5y6p8S5DzMTVEsJZrawi+BoDNUVBa2DhJqQYUFvMDfgU062LQ==} engines: {node: '>=6'} + requiresBuild: true dev: true /@sindresorhus/is@4.6.0: @@ -1594,6 +1596,7 @@ packages: /@szmarczak/http-timer@1.1.2: resolution: {integrity: sha512-XIB2XbzHTN6ieIjfIMV9hlVcfPU26s2vafYWQcZHWXHOxiaRZYEDKEwdl129Zyg50+foYV2jCgtrqSA6qNuNSA==} engines: {node: '>=6'} + requiresBuild: true dependencies: defer-to-connect: 1.1.1 dev: true @@ -2213,6 +2216,7 @@ packages: /aes-js@3.1.2: resolution: {integrity: sha512-e5pEa2kBnBOgR4Y/p20pskXI74UEz7de8ZGVo58asOtvSVG5YAbJeELPZxOmt+Bnz3rX753YKhfIn4X4l1PPRQ==} + requiresBuild: true dev: true optional: true @@ -2254,6 +2258,7 @@ packages: /amdefine@1.0.1: resolution: {integrity: sha512-S2Hw0TtNkMJhIabBwIojKL9YHO5T0n5eNqWJ7Lrlel/zDbftQpxpapi8tZs3X1HWa+u+QeydGmzzNU0m09+Rcg==} engines: {node: '>=0.4.2'} + requiresBuild: true dev: true optional: true @@ -3423,6 +3428,7 @@ packages: /cacheable-request@6.1.0: resolution: {integrity: sha512-Oj3cAGPCqOZX7Rz64Uny2GYAZNliQSqfbePrgAQ1wKAihYmCUnraBtJtKcGR4xz7wF+LoJC+ssFZvv5BgF9Igg==} engines: {node: '>=8'} + requiresBuild: true dependencies: clone-response: 1.0.2 get-stream: 5.1.0 @@ -3936,6 +3942,7 @@ packages: /cookiejar@2.1.2: resolution: {integrity: sha512-Mw+adcfzPxcPeI+0WlvRrr/3lGVO0bD75SxX6811cxSh1Wbxx7xZBGK1eVtDf6si8rg2lhnUjsVLMFMfbRIuwA==} + requiresBuild: true dev: true /copy-descriptor@0.1.1: @@ -4237,6 +4244,7 @@ packages: /defer-to-connect@1.1.1: resolution: {integrity: sha512-J7thop4u3mRTkYRQ+Vpfwy2G5Ehoy82I14+14W4YMDLKdWloI9gSzRbV30s/NckQGVJtPkWNcW4oMAUigTdqiQ==} + requiresBuild: true dev: true /defer-to-connect@2.0.1: @@ -5837,6 +5845,7 @@ packages: /get-stream@4.1.0: resolution: {integrity: sha512-GMat4EJ5161kIy2HevLlr4luNjBgvmj413KaQA7jt4V8B4RDsfpHk7WQ9GVqfYyyx8OS/L66Kox+rJRNklLK7w==} engines: {node: '>=6'} + requiresBuild: true dependencies: pump: 3.0.0 dev: true @@ -7051,6 +7060,7 @@ packages: /json-buffer@3.0.0: resolution: {integrity: sha512-CuUqjv0FUZIdXkHPI8MezCnFCdaTAacej1TZYulLoAg1h/PhwkdXFN4V/gzY4g+fMBCOV2xF+rp7t2XD2ns/NQ==} + requiresBuild: true dev: true /json-buffer@3.0.1: @@ -7185,6 +7195,7 @@ packages: /keyv@3.1.0: resolution: {integrity: sha512-9ykJ/46SN/9KPM/sichzQ7OvXyGDYKGTaDlKMGCAlg2UK8KRy4jb0d8sFc+0Tt0YYnThq8X2RZgCg74RPxgcVA==} + requiresBuild: true dependencies: json-buffer: 3.0.0 dev: true @@ -8172,6 +8183,7 @@ packages: /normalize-url@4.5.1: resolution: {integrity: sha512-9UZCFRHQdNrfTpGg8+1INIg93B6zE0aXMVFkw1WFwvO4SlZywU6aLg5Of0Ap/PgcbSw4LNxvMWXMeugwMCX0AA==} engines: {node: '>=8'} + requiresBuild: true dev: true /normalize-url@6.1.0: @@ -8287,6 +8299,7 @@ packages: /oboe@2.1.4: resolution: {integrity: sha512-ymBJ4xSC6GBXLT9Y7lirj+xbqBLa+jADGJldGEYG7u8sZbS9GyG+u1Xk9c5cbriKwSpCg41qUhPjvU5xOpvIyQ==} + requiresBuild: true dependencies: http-https: 1.0.0 dev: true @@ -8368,6 +8381,7 @@ packages: /p-cancelable@1.1.0: resolution: {integrity: sha512-s73XxOZ4zpt1edZYZzvhqFa6uvQc1vwUa0K0BdtIZgQMAJj9IbebH+JkgKZc9h+B05PKHLOTl4ajG1BmNrVZlw==} engines: {node: '>=6'} + requiresBuild: true dev: true /p-cancelable@3.0.0: @@ -8720,6 +8734,7 @@ packages: /prepend-http@2.0.0: resolution: {integrity: sha512-ravE6m9Atw9Z/jjttRUZ+clIXogdghyZAuWJ3qEzjT+jI/dL1ifAqhZeC5VHzQp1MSt1+jxKkFNemj/iO7tVUA==} engines: {node: '>=4'} + requiresBuild: true dev: true /prettier-linter-helpers@1.0.0: @@ -9239,6 +9254,7 @@ packages: /responselike@1.0.2: resolution: {integrity: sha512-/Fpe5guzJk1gPqdJLJR5u7eG/gNY4nImjbRDaVWVMRhne55TCmj2i9Q+54PBRfatRC8v/rIiv9BN0pMd9OV5EQ==} + requiresBuild: true dependencies: lowercase-keys: 1.0.1 dev: true @@ -9379,6 +9395,7 @@ packages: /scryptsy@1.2.1: resolution: {integrity: sha512-aldIRgMozSJ/Gl6K6qmJZysRP82lz83Wb42vl4PWN8SaLFHIaOzLPc9nUUW2jQN88CuGm5q5HefJ9jZ3nWSmTw==} + requiresBuild: true dependencies: pbkdf2: 3.1.2 dev: true @@ -10453,6 +10470,7 @@ packages: /to-readable-stream@1.0.0: resolution: {integrity: sha512-Iq25XBt6zD5npPhlLVXGFN3/gyR2/qODcKNNyTMd4vbm39HUaOiAM4PMq0eMVC/Tkxz+Zjdsc55g9yyz+Yq00Q==} engines: {node: '>=6'} + requiresBuild: true dev: true /to-regex-range@2.1.1: @@ -10774,6 +10792,7 @@ packages: /underscore@1.9.1: resolution: {integrity: sha512-5/4etnCkd9c8gwgowi5/om/mYO5ajCaOgdzj/oW+0eQV9WxKBDZw5+ycmKmeaTXjInS/W0BzpGLo2xR2aBwZdg==} + requiresBuild: true dev: true optional: true @@ -10858,6 +10877,7 @@ packages: /url-parse-lax@3.0.0: resolution: {integrity: sha512-NjFKA0DidqPa5ciFcSrXnAltTtzz84ogy+NebPvfEgAck0+TNg4UJ4IN+fB7zRZfbgUf0syOo9MDxFkDSMuFaQ==} engines: {node: '>=4'} + requiresBuild: true dependencies: prepend-http: 2.0.0 dev: true @@ -10975,6 +10995,7 @@ packages: /web3-bzz@1.2.11: resolution: {integrity: sha512-XGpWUEElGypBjeFyUhTkiPXFbDVD6Nr/S5jznE3t8cWUA0FxRf1n3n/NuIZeb0H9RkN2Ctd/jNma/k8XGa3YKg==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: '@types/node': 12.19.16 got: 9.6.0 @@ -11018,6 +11039,7 @@ packages: /web3-core-helpers@1.2.11: resolution: {integrity: sha512-PEPoAoZd5ME7UfbnCZBdzIerpe74GEvlwT4AjOmHeCVZoIFk7EqvOZDejJHt+feJA6kMVTdd0xzRNN295UhC1A==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: underscore: 1.9.1 web3-eth-iban: 1.2.11 @@ -11044,6 +11066,7 @@ packages: /web3-core-method@1.2.11: resolution: {integrity: sha512-ff0q76Cde94HAxLDZ6DbdmKniYCQVtvuaYh+rtOUMB6kssa5FX0q3vPmixi7NPooFnbKmmZCM6NvXg4IreTPIw==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: '@ethersproject/transactions': 5.7.0 underscore: 1.9.1 @@ -11079,6 +11102,7 @@ packages: /web3-core-promievent@1.2.11: resolution: {integrity: sha512-il4McoDa/Ox9Agh4kyfQ8Ak/9ABYpnF8poBLL33R/EnxLsJOGQG2nZhkJa3I067hocrPSjEdlPt/0bHXsln4qA==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: eventemitter3: 4.0.4 dev: true @@ -11101,6 +11125,7 @@ packages: /web3-core-requestmanager@1.2.11: resolution: {integrity: sha512-oFhBtLfOiIbmfl6T6gYjjj9igOvtyxJ+fjS+byRxiwFJyJ5BQOz4/9/17gWR1Cq74paTlI7vDGxYfuvfE/mKvA==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: underscore: 1.9.1 web3-core-helpers: 1.2.11 @@ -11142,6 +11167,7 @@ packages: /web3-core-subscriptions@1.2.11: resolution: {integrity: sha512-qEF/OVqkCvQ7MPs1JylIZCZkin0aKK9lDxpAtQ1F8niEDGFqn7DT8E/vzbIa0GsOjL2fZjDhWJsaW+BSoAW1gg==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: eventemitter3: 4.0.4 underscore: 1.9.1 @@ -11168,6 +11194,7 @@ packages: /web3-core@1.2.11: resolution: {integrity: sha512-CN7MEYOY5ryo5iVleIWRE3a3cZqVaLlIbIzDPsvQRUfzYnvzZQRZBm9Mq+ttDi2STOOzc1MKylspz/o3yq/LjQ==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: '@types/bn.js': 4.11.6 '@types/node': 12.19.16 @@ -11215,6 +11242,7 @@ packages: /web3-eth-abi@1.2.11: resolution: {integrity: sha512-PkRYc0+MjuLSgg03QVWqWlQivJqRwKItKtEpRUaxUAeLE7i/uU39gmzm2keHGcQXo3POXAbOnMqkDvOep89Crg==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: '@ethersproject/abi': 5.0.0-beta.153 underscore: 1.9.1 @@ -11241,6 +11269,7 @@ packages: /web3-eth-accounts@1.2.11: resolution: {integrity: sha512-6FwPqEpCfKIh3nSSGeo3uBm2iFSnFJDfwL3oS9pyegRBXNsGRVpgiW63yhNzL0796StsvjHWwQnQHsZNxWAkGw==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: crypto-browserify: 3.12.0 eth-lib: 0.2.8 @@ -11300,6 +11329,7 @@ packages: /web3-eth-contract@1.2.11: resolution: {integrity: sha512-MzYuI/Rq2o6gn7vCGcnQgco63isPNK5lMAan2E51AJLknjSLnOxwNY3gM8BcKoy4Z+v5Dv00a03Xuk78JowFow==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: '@types/bn.js': 4.11.6 underscore: 1.9.1 @@ -11351,6 +11381,7 @@ packages: /web3-eth-ens@1.2.11: resolution: {integrity: sha512-dbW7dXP6HqT1EAPvnniZVnmw6TmQEKF6/1KgAxbo8iBBYrVTMDGFQUUnZ+C4VETGrwwaqtX4L9d/FrQhZ6SUiA==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: content-hash: 2.5.2 eth-ens-namehash: 2.0.8 @@ -11402,6 +11433,7 @@ packages: /web3-eth-iban@1.2.11: resolution: {integrity: sha512-ozuVlZ5jwFC2hJY4+fH9pIcuH1xP0HEFhtWsR69u9uDIANHLPQQtWYmdj7xQ3p2YT4bQLq/axKhZi7EZVetmxQ==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: bn.js: 4.12.0 web3-utils: 1.2.11 @@ -11427,6 +11459,7 @@ packages: /web3-eth-personal@1.2.11: resolution: {integrity: sha512-42IzUtKq9iHZ8K9VN0vAI50iSU9tOA1V7XU2BhF/tb7We2iKBVdkley2fg26TxlOcKNEHm7o6HRtiiFsVK4Ifw==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: '@types/node': 12.19.16 web3-core: 1.2.11 @@ -11471,6 +11504,7 @@ packages: /web3-eth@1.2.11: resolution: {integrity: sha512-REvxW1wJ58AgHPcXPJOL49d1K/dPmuw4LjPLBPStOVkQjzDTVmJEIsiLwn2YeuNDd4pfakBwT8L3bz1G1/wVsQ==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: underscore: 1.9.1 web3-core: 1.2.11 @@ -11534,6 +11568,7 @@ packages: /web3-net@1.2.11: resolution: {integrity: sha512-sjrSDj0pTfZouR5BSTItCuZ5K/oZPVdVciPQ6981PPPIwJJkCMeVjD7I4zO3qDPCnBjBSbWvVnLdwqUBPtHxyg==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: web3-core: 1.2.11 web3-core-method: 1.2.11 @@ -11599,6 +11634,7 @@ packages: /web3-providers-http@1.2.11: resolution: {integrity: sha512-psh4hYGb1+ijWywfwpB2cvvOIMISlR44F/rJtYkRmQ5jMvG4FOCPlQJPiHQZo+2cc3HbktvvSJzIhkWQJdmvrA==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: web3-core-helpers: 1.2.11 xhr2-cookies: 1.1.0 @@ -11628,6 +11664,7 @@ packages: /web3-providers-ipc@1.2.11: resolution: {integrity: sha512-yhc7Y/k8hBV/KlELxynWjJDzmgDEDjIjBzXK+e0rHBsYEhdCNdIH5Psa456c+l0qTEU2YzycF8VAjYpWfPnBpQ==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: oboe: 2.1.4 underscore: 1.9.1 @@ -11654,6 +11691,7 @@ packages: /web3-providers-ws@1.2.11: resolution: {integrity: sha512-ZxnjIY1Er8Ty+cE4migzr43zA/+72AF1myzsLaU5eVgdsfV7Jqx7Dix1hbevNZDKFlSoEyq/3j/jYalh3So1Zg==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: eventemitter3: 4.0.4 underscore: 1.9.1 @@ -11689,6 +11727,7 @@ packages: /web3-shh@1.2.11: resolution: {integrity: sha512-B3OrO3oG1L+bv3E1sTwCx66injW1A8hhwpknDUbV+sw3fehFazA06z9SGXUefuFI1kVs4q2vRi0n4oCcI4dZDg==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: web3-core: 1.2.11 web3-core-method: 1.2.11 @@ -11729,6 +11768,7 @@ packages: /web3-utils@1.2.11: resolution: {integrity: sha512-3Tq09izhD+ThqHEaWYX4VOT7dNPdZiO+c/1QMA0s5X2lDFKK/xHJb7cyTRRVzN2LvlHbR7baS1tmQhSua51TcQ==} engines: {node: '>=8.0.0'} + requiresBuild: true dependencies: bn.js: 4.12.0 eth-lib: 0.2.8 diff --git a/contracts/scripts/native_solc_compile_all_llo b/contracts/scripts/native_solc_compile_all_llo index 0aad167b35a..7c09857451c 100755 --- a/contracts/scripts/native_solc_compile_all_llo +++ b/contracts/scripts/native_solc_compile_all_llo @@ -27,6 +27,8 @@ compileContract () { compileContract llo-feeds/Verifier.sol compileContract llo-feeds/VerifierProxy.sol +compileContract llo-feeds/dev/FeeManager.sol +compileContract llo-feeds/dev/RewardManager.sol #Test | Mocks compileContract llo-feeds/test/mocks/ErroredVerifier.sol diff --git a/contracts/src/v0.8/libraries/ByteUtil.sol b/contracts/src/v0.8/libraries/ByteUtil.sol new file mode 100644 index 00000000000..906fef3fa77 --- /dev/null +++ b/contracts/src/v0.8/libraries/ByteUtil.sol @@ -0,0 +1,82 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +/* + * @title ByteUtil + * @author Michael Fletcher + * @notice Byte utility functions for efficiently parsing and manipulating packed byte data + */ +library ByteUtil { + // Error message when an offset is out of bounds + error MalformedData(); + + /** + * @dev Reads a uint256 from a position within a byte array. + * @param data Byte array to read from. + * @param offset Position to start reading from. + * @return result The uint256 read from the byte array. + */ + function readUint256(bytes memory data, uint256 offset) internal pure returns (uint256 result) { + //bounds check + if (offset + 32 > data.length) revert MalformedData(); + + assembly { + //load 32 byte word accounting for 32 bit length and offset + result := mload(add(add(data, 32), offset)) + } + } + + /** + * @dev Reads a uint192 from a position within a byte array. + * @param data Byte array to read from. + * @param offset Position to start reading from. + * @return result The uint192 read from the byte array. + */ + function readUint192(bytes memory data, uint256 offset) internal pure returns (uint256 result) { + //bounds check + if (offset + 24 > data.length) revert MalformedData(); + + assembly { + //load 32 byte word accounting for 32 bit length and offset + result := mload(add(add(data, 32), offset)) + //shift the result right 64 bits + result := shr(64, result) + } + } + + /** + * @dev Reads a uint32 from a position within a byte array. + * @param data Byte array to read from. + * @param offset Position to start reading from. + * @return result The uint32 read from the byte array. + */ + function readUint32(bytes memory data, uint256 offset) internal pure returns (uint256 result) { + //bounds check + if (offset + 4 > data.length) revert MalformedData(); + + assembly { + //load 32 byte word accounting for 32 bit length and offset + result := mload(add(add(data, 32), offset)) + //shift the result right 224 bits + result := shr(224, result) + } + } + + /** + * @dev Reads an address from a position within a byte array. + * @param data Byte array to read from. + * @param offset Position to start reading from. + * @return result The uint32 read from the byte array. + */ + function readAddress(bytes memory data, uint256 offset) internal pure returns (address result) { + //bounds check + if (offset + 20 > data.length) revert MalformedData(); + + assembly { + //load 32 byte word accounting for 32 bit length and offset + let word := mload(add(add(data, 32), offset)) + //address is the last 20 bytes of the word, so shift right + result := shr(96, word) + } + } +} diff --git a/contracts/src/v0.8/libraries/Common.sol b/contracts/src/v0.8/libraries/Common.sol new file mode 100644 index 00000000000..2df1e5c94e6 --- /dev/null +++ b/contracts/src/v0.8/libraries/Common.sol @@ -0,0 +1,43 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +/* + * @title Common + * @author Michael Fletcher + * @notice Common functions and structs + */ +library Common { + // @notice The asset struct to hold the address of an asset and amount + struct Asset { + address assetAddress; + uint256 amount; + } + + // @notice Struct to hold the address and its associated weight + struct AddressAndWeight { + address addr; + uint256 weight; + } + + /** + * @notice Checks if an array of AddressAndWeight has duplicate addresses + * @param recipients The array of AddressAndWeight to check + * @return bool True if there are duplicates, false otherwise + */ + function hasDuplicateAddresses(Common.AddressAndWeight[] memory recipients) internal pure returns (bool) { + for (uint256 i = 0; i < recipients.length; ) { + for (uint256 j = i + 1; j < recipients.length; ) { + if (recipients[i].addr == recipients[j].addr) { + return true; + } + unchecked { + ++j; + } + } + unchecked { + ++i; + } + } + return false; + } +} diff --git a/contracts/src/v0.8/libraries/test/ByteUtilTest.t.sol b/contracts/src/v0.8/libraries/test/ByteUtilTest.t.sol new file mode 100644 index 00000000000..eabae4f5729 --- /dev/null +++ b/contracts/src/v0.8/libraries/test/ByteUtilTest.t.sol @@ -0,0 +1,177 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {Test} from "forge-std/Test.sol"; +import {ByteUtil} from "../ByteUtil.sol"; + +contract ByteUtilTest is Test { + using ByteUtil for bytes; + + bytes internal constant B_512 = + hex"ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000000000000000000000000000000000000000000000000000000000000000"; + bytes internal constant B_128 = hex"ffffffffffffffffffffffffffffffff"; + bytes internal constant B_16 = hex"ffff"; + bytes internal constant B_EMPTY = new bytes(0); + + bytes4 internal constant MALFORMED_ERROR_SELECTOR = bytes4(keccak256("MalformedData()")); + + function test_readUint256Max() public { + //read the first 32 bytes + uint256 result = B_512.readUint256(0); + + //the result should be the max value of a uint256 + assertEq(result, type(uint256).max); + } + + function test_readUint192Max() public { + //read the first 24 bytes + uint256 result = B_512.readUint192(0); + + //the result should be the max value of a uint192 + assertEq(result, type(uint192).max); + } + + function test_readUint32Max() public { + //read the first 4 bytes + uint256 result = B_512.readUint32(0); + + //the result should be the max value of a uint32 + assertEq(result, type(uint32).max); + } + + function test_readUint256Min() public { + //read the second 32 bytes + uint256 result = B_512.readUint256(32); + + //the result should be the min value of a uint256 + assertEq(result, type(uint256).min); + } + + function test_readUint192Min() public { + //read the second 24 bytes + uint256 result = B_512.readUint192(32); + + //the result should be the min value of a uint192 + assertEq(result, type(uint192).min); + } + + function test_readUint32Min() public { + //read the second 4 bytes + uint256 result = B_512.readUint32(32); + + //the result should be the min value of a uint32 + assertEq(result, type(uint32).min); + } + + function test_readUint256MultiWord() public { + //read the first 32 bytes + uint256 result = B_512.readUint256(31); + + //the result should be the last byte from the first word (ff), and 31 bytes from the second word (0000) (0xFF...0000) + assertEq(result, type(uint256).max << 248); + } + + function test_readUint192MultiWord() public { + //read the first 24 bytes + uint256 result = B_512.readUint192(31); + + //the result should be the last byte from the first word (ff), and 23 bytes from the second word (0000) (0xFF...0000) + assertEq(result, type(uint192).max << 184); + } + + function test_readUint32MultiWord() public { + //read the first 4 bytes + uint256 result = B_512.readUint32(31); + + //the result should be the last byte from the first word (ff), and 3 bytes from the second word (0000) (0xFF...0000) + assertEq(result, type(uint32).max << 24); + } + + function test_readUint256WithNotEnoughBytes() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //try and read 32 bytes from a 16 byte number + B_128.readUint256(0); + } + + function test_readUint192WithNotEnoughBytes() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //try and read 24 bytes from a 16 byte number + B_128.readUint192(0); + } + + function test_readUint32WithNotEnoughBytes() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //try and read 4 bytes from a 2 byte number + B_16.readUint32(0); + } + + function test_readUint256WithEmptyArray() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //read 20 bytes from an empty array + B_EMPTY.readUint256(0); + } + + function test_readUint192WithEmptyArray() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //read 20 bytes from an empty array + B_EMPTY.readUint192(0); + } + + function test_readUint32WithEmptyArray() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //read 20 bytes from an empty array + B_EMPTY.readUint32(0); + } + + function test_readAddress() public { + //read the first 20 bytes + address result = B_512.readAddress(0); + + //the result should be the max value of a uint256 + assertEq(result, address(type(uint160).max)); + } + + function test_readZeroAddress() public { + //read the first 32 bytes after the first word + address result = B_512.readAddress(32); + + //the result should be 0x00...0 + assertEq(result, address(type(uint160).min)); + } + + function test_readAddressMultiWord() public { + //read the first 20 bytes after byte 13 + address result = B_512.readAddress(13); + + //the result should be the value last 19 bytes of the first word (ffff..) and the first byte of the second word (00) (0xFFFF..00) + assertEq(result, address(type(uint160).max << 8)); + } + + function test_readAddressWithNotEnoughBytes() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //read 20 bytes from a 16 byte array + B_128.readAddress(0); + } + + function test_readAddressWithEmptyArray() public { + //should revert if there's not enough bytes + vm.expectRevert(MALFORMED_ERROR_SELECTOR); + + //read the first 20 bytes of an empty array + B_EMPTY.readAddress(0); + } +} diff --git a/contracts/src/v0.8/llo-feeds/Verifier.sol b/contracts/src/v0.8/llo-feeds/Verifier.sol index 34ec915b160..c528ac06ec8 100644 --- a/contracts/src/v0.8/llo-feeds/Verifier.sol +++ b/contracts/src/v0.8/llo-feeds/Verifier.sol @@ -5,16 +5,17 @@ import {ConfirmedOwner} from "../shared/access/ConfirmedOwner.sol"; import {IVerifier} from "./interfaces/IVerifier.sol"; import {IVerifierProxy} from "./interfaces/IVerifierProxy.sol"; import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; -import {IERC165} from "../vendor/IERC165.sol"; +import {IERC165} from "../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../libraries/Common.sol"; // OCR2 standard uint256 constant MAX_NUM_ORACLES = 31; /* * The verifier contract is used to verify offchain reports signed - * by DONs. A report consists of a price, block number and feed Id. It + * by DONs. A report consists of a price, block number and feed Id. It * represents the observed price of an asset at a specified block number for - * a feed. The verifier contract is used to verify that such reports have + * a feed. The verifier contract is used to verify that such reports have * been signed by the correct signers. **/ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { @@ -148,10 +149,12 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { /// @param ssLength The number of s signature components error MismatchedSignatures(uint256 rsLength, uint256 ssLength); - /// @notice This error is thrown whenever a report has a duplicate - /// signature + /// @notice This error is thrown whenever setting a config with duplicate signatures error NonUniqueSignatures(); + /// @notice This error is thrown whenever a report fails to verify due to bad or duplicate signatures + error BadVerification(); + /// @notice This error is thrown whenever the admin tries to deactivate /// the latest config digest /// @param feedId The feed ID in the signed report @@ -178,6 +181,13 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { i_verifierProxyAddr = verifierProxyAddr; } + modifier checkConfigValid(uint256 numSigners, uint256 f) { + if (f == 0) revert FaultToleranceMustBePositive(); + if (numSigners > MAX_NUM_ORACLES) revert ExcessSigners(numSigners, MAX_NUM_ORACLES); + if (numSigners <= 3 * f) revert InsufficientSigners(numSigners, 3 * f + 1); + _; + } + /// @inheritdoc IERC165 function supportsInterface(bytes4 interfaceId) external pure override returns (bool isVerifier) { return interfaceId == this.verify.selector; @@ -185,7 +195,7 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { /// @inheritdoc TypeAndVersionInterface function typeAndVersion() external pure override returns (string memory) { - return "Verifier 1.0.0"; + return "Verifier 1.1.0"; } /// @inheritdoc IVerifier @@ -223,6 +233,7 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { _verifySignatures(hashedReport, reportContext, rs, ss, rawVs, s_config); emit ReportVerified(feedId, sender); + return reportData; } @@ -285,13 +296,83 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { for (uint256 i; i < numSigners; ++i) { signerAddress = ecrecover(h, uint8(rawVs[i]) + 27, rs[i], ss[i]); o = s_config.oracles[signerAddress]; - if (o.role != Role.Signer) revert AccessForbidden(); + if (o.role != Role.Signer) revert BadVerification(); unchecked { signedCount += 1 << (8 * o.index); } } - if (signedCount & ORACLE_MASK != signedCount) revert NonUniqueSignatures(); + if (signedCount & ORACLE_MASK != signedCount) revert BadVerification(); + } + + /// @inheritdoc IVerifier + function setConfig( + bytes32 feedId, + address[] memory signers, + bytes32[] memory offchainTransmitters, + uint8 f, + bytes memory onchainConfig, + uint64 offchainConfigVersion, + bytes memory offchainConfig, + Common.AddressAndWeight[] memory recipientAddressesAndWeights + ) external override checkConfigValid(signers.length, f) onlyOwner { + VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; + + // Increment the number of times a config has been set first + feedVerifierState.configCount++; + + bytes32 configDigest = _configDigestFromConfigData( + feedId, + feedVerifierState.configCount, + signers, + offchainTransmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig + ); + + feedVerifierState.s_verificationDataConfigs[configDigest].f = f; + feedVerifierState.s_verificationDataConfigs[configDigest].isActive = true; + for (uint8 i; i < signers.length; ++i) { + address signerAddr = signers[i]; + if (signerAddr == address(0)) revert ZeroAddress(); + + // All signer roles are unset by default for a new config digest. + // Here the contract checks to see if a signer's address has already + // been set to ensure that the group of signer addresses that will + // sign reports with the config digest are unique. + bool isSignerAlreadySet = feedVerifierState.s_verificationDataConfigs[configDigest].oracles[signerAddr].role != + Role.Unset; + if (isSignerAlreadySet) revert NonUniqueSignatures(); + feedVerifierState.s_verificationDataConfigs[configDigest].oracles[signerAddr] = Signer({ + role: Role.Signer, + index: i + }); + } + + IVerifierProxy(i_verifierProxyAddr).setVerifier( + feedVerifierState.latestConfigDigest, + configDigest, + recipientAddressesAndWeights + ); + + emit ConfigSet( + feedId, + feedVerifierState.latestConfigBlockNumber, + configDigest, + feedVerifierState.configCount, + signers, + offchainTransmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig + ); + + feedVerifierState.latestEpoch = 0; + feedVerifierState.latestConfigBlockNumber = uint32(block.number); + feedVerifierState.latestConfigDigest = configDigest; } /// @notice Generates the config digest from config data @@ -335,36 +416,30 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { return bytes32((prefix & prefixMask) | (h & ~prefixMask)); } - /// @notice Deactivates the configuration for a config digest - /// @param feedId Feed ID to deactivate config for - /// @param configDigest The config digest to deactivate - /// @dev This function can be called by the contract admin to deactivate an incorrect configuration. - function deactivateConfig(bytes32 feedId, bytes32 configDigest) external onlyOwner { + /// @inheritdoc IVerifier + function activateConfig(bytes32 feedId, bytes32 configDigest) external onlyOwner { VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; if (configDigest == bytes32("")) revert DigestEmpty(); if (feedVerifierState.s_verificationDataConfigs[configDigest].f == 0) revert DigestNotSet(feedId, configDigest); - if (configDigest == feedVerifierState.latestConfigDigest) revert CannotDeactivateLatestConfig(feedId, configDigest); - feedVerifierState.s_verificationDataConfigs[configDigest].isActive = false; - emit ConfigDeactivated(feedId, configDigest); + feedVerifierState.s_verificationDataConfigs[configDigest].isActive = true; + emit ConfigActivated(feedId, configDigest); } - /// @notice Activates the configuration for a config digest - /// @param feedId Feed ID to activate config for - /// @param configDigest The config digest to activate - /// @dev This function can be called by the contract admin to activate a configuration. - function activateConfig(bytes32 feedId, bytes32 configDigest) external onlyOwner { + /// @inheritdoc IVerifier + function deactivateConfig(bytes32 feedId, bytes32 configDigest) external onlyOwner { VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; if (configDigest == bytes32("")) revert DigestEmpty(); if (feedVerifierState.s_verificationDataConfigs[configDigest].f == 0) revert DigestNotSet(feedId, configDigest); - feedVerifierState.s_verificationDataConfigs[configDigest].isActive = true; - emit ConfigActivated(feedId, configDigest); + if (configDigest == feedVerifierState.latestConfigDigest) { + revert CannotDeactivateLatestConfig(feedId, configDigest); + } + feedVerifierState.s_verificationDataConfigs[configDigest].isActive = false; + emit ConfigDeactivated(feedId, configDigest); } - /// @notice Activates the given feed - /// @param feedId Feed ID to activated - /// @dev This function can be called by the contract admin to activate a feed + /// @inheritdoc IVerifier function activateFeed(bytes32 feedId) external onlyOwner { VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; @@ -373,9 +448,7 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { emit FeedActivated(feedId); } - /// @notice Deactivates the given feed - /// @param feedId Feed ID to deactivated - /// @dev This function can be called by the contract admin to deactivate a feed + /// @inheritdoc IVerifier function deactivateFeed(bytes32 feedId) external onlyOwner { VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; @@ -384,82 +457,7 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { emit FeedDeactivated(feedId); } - //***************************// - // Repurposed OCR2 Functions // - //***************************// - - // Reverts transaction if config args are invalid - modifier checkConfigValid(uint256 numSigners, uint256 f) { - if (f == 0) revert FaultToleranceMustBePositive(); - if (numSigners > MAX_NUM_ORACLES) revert ExcessSigners(numSigners, MAX_NUM_ORACLES); - if (numSigners <= 3 * f) revert InsufficientSigners(numSigners, 3 * f + 1); - _; - } - - function setConfig( - bytes32 feedId, - address[] memory signers, - bytes32[] memory offchainTransmitters, - uint8 f, - bytes memory onchainConfig, - uint64 offchainConfigVersion, - bytes memory offchainConfig - ) external override checkConfigValid(signers.length, f) onlyOwner { - VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; - - // Increment the number of times a config has been set first - feedVerifierState.configCount++; - - bytes32 configDigest = _configDigestFromConfigData( - feedId, - feedVerifierState.configCount, - signers, - offchainTransmitters, - f, - onchainConfig, - offchainConfigVersion, - offchainConfig - ); - - feedVerifierState.s_verificationDataConfigs[configDigest].f = f; - feedVerifierState.s_verificationDataConfigs[configDigest].isActive = true; - for (uint8 i; i < signers.length; ++i) { - address signerAddr = signers[i]; - if (signerAddr == address(0)) revert ZeroAddress(); - - // All signer roles are unset by default for a new config digest. - // Here the contract checks to see if a signer's address has already - // been set to ensure that the group of signer addresses that will - // sign reports with the config digest are unique. - bool isSignerAlreadySet = feedVerifierState.s_verificationDataConfigs[configDigest].oracles[signerAddr].role != - Role.Unset; - if (isSignerAlreadySet) revert NonUniqueSignatures(); - feedVerifierState.s_verificationDataConfigs[configDigest].oracles[signerAddr] = Signer({ - role: Role.Signer, - index: i - }); - } - - IVerifierProxy(i_verifierProxyAddr).setVerifier(feedVerifierState.latestConfigDigest, configDigest); - - emit ConfigSet( - feedId, - feedVerifierState.latestConfigBlockNumber, - configDigest, - feedVerifierState.configCount, - signers, - offchainTransmitters, - f, - onchainConfig, - offchainConfigVersion, - offchainConfig - ); - - feedVerifierState.latestEpoch = 0; - feedVerifierState.latestConfigBlockNumber = uint32(block.number); - feedVerifierState.latestConfigDigest = configDigest; - } - + /// @inheritdoc IVerifier function latestConfigDigestAndEpoch( bytes32 feedId ) external view override returns (bool scanLogs, bytes32 configDigest, uint32 epoch) { @@ -467,6 +465,7 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { return (false, feedVerifierState.latestConfigDigest, feedVerifierState.latestEpoch); } + /// @inheritdoc IVerifier function latestConfigDetails( bytes32 feedId ) external view override returns (uint32 configCount, uint32 blockNumber, bytes32 configDigest) { diff --git a/contracts/src/v0.8/llo-feeds/VerifierProxy.sol b/contracts/src/v0.8/llo-feeds/VerifierProxy.sol index 1701c011688..41907432a31 100644 --- a/contracts/src/v0.8/llo-feeds/VerifierProxy.sol +++ b/contracts/src/v0.8/llo-feeds/VerifierProxy.sol @@ -6,7 +6,9 @@ import {IVerifierProxy} from "./interfaces/IVerifierProxy.sol"; import {IVerifier} from "./interfaces/IVerifier.sol"; import {TypeAndVersionInterface} from "../interfaces/TypeAndVersionInterface.sol"; import {AccessControllerInterface} from "../interfaces/AccessControllerInterface.sol"; -import {IERC165} from "../vendor/IERC165.sol"; +import {IERC165} from "../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {IVerifierFeeManager} from "./interfaces/IVerifierFeeManager.sol"; +import {Common} from "../libraries/Common.sol"; /** * The verifier proxy contract is the gateway for all report verification requests @@ -37,6 +39,11 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac /// @param newAccessController The new access controller address event AccessControllerSet(address oldAccessController, address newAccessController); + /// @notice This event is emitted when a new fee manager is set + /// @param oldFeeManager The old fee manager address + /// @param newFeeManager The new fee manager address + event FeeManagerSet(address oldFeeManager, address newFeeManager); + /// @notice This error is thrown whenever an address tries /// to exeecute a transaction that it is not authorized to do so error AccessForbidden(); @@ -62,6 +69,9 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac /// @param configDigest The digest for which a verifier is not found error VerifierNotFound(bytes32 configDigest); + /// @notice This error is thrown whenever billing fails. + error BadVerification(); + /// @notice Mapping of authorized verifiers mapping(address => bool) private s_initializedVerifiers; @@ -69,20 +79,21 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac mapping(bytes32 => address) private s_verifiersByConfig; /// @notice The contract to control addresses that are allowed to verify reports - AccessControllerInterface private s_accessController; + AccessControllerInterface public s_accessController; + + /// @notice The contract to control fees for report verification + IVerifierFeeManager public s_feeManager; constructor(AccessControllerInterface accessController) ConfirmedOwner(msg.sender) { s_accessController = accessController; } - /// @dev reverts if the caller does not have access by the accessController contract or is the contract itself. modifier checkAccess() { AccessControllerInterface ac = s_accessController; if (address(ac) != address(0) && !ac.hasAccess(msg.sender, msg.data)) revert AccessForbidden(); _; } - /// @dev only allow verified addresses to call this function modifier onlyInitializedVerifier() { if (!s_initializedVerifiers[msg.sender]) revert AccessForbidden(); _; @@ -94,8 +105,6 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac _; } - /// @notice Reverts if the config digest has already been assigned - /// a verifier modifier onlyUnsetConfigDigest(bytes32 configDigest) { address configDigestVerifier = s_verifiersByConfig[configDigest]; if (configDigestVerifier != address(0)) revert ConfigDigestAlreadySet(configDigest, configDigestVerifier); @@ -104,44 +113,26 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac /// @inheritdoc TypeAndVersionInterface function typeAndVersion() external pure override returns (string memory) { - return "VerifierProxy 1.0.0"; + return "VerifierProxy 1.1.0"; } - //***************************// - // Admin Functions // - //***************************// - - /// @notice This function can be called by the contract admin to set - /// the proxy's access controller contract - /// @param accessController The new access controller to set - /// @dev The access controller can be set to the zero address to allow - /// all addresses to verify reports - function setAccessController(AccessControllerInterface accessController) external onlyOwner { - address oldAccessController = address(s_accessController); - s_accessController = accessController; - emit AccessControllerSet(oldAccessController, address(accessController)); - } - - /// @notice Returns the current access controller - /// @return accessController The current access controller contract - /// the proxy is using to gate access - function getAccessController() external view returns (AccessControllerInterface accessController) { - return s_accessController; - } - - //***************************// - // Verification Functions // - //***************************// - /// @inheritdoc IVerifierProxy - /// @dev Contract skips checking whether or not the current verifier - /// is valid as it checks this before a new verifier is set. - function verify(bytes calldata signedReport) external override checkAccess returns (bytes memory verifierResponse) { - // First 32 bytes of the signed report is the config digest. - bytes32 configDigest = bytes32(signedReport); + function verify( + bytes calldata payload + ) external payable override checkAccess returns (bytes memory verifierResponse) { + // First 32 bytes of the signed report is the config digest + bytes32 configDigest = bytes32(payload); address verifierAddress = s_verifiersByConfig[configDigest]; if (verifierAddress == address(0)) revert VerifierNotFound(configDigest); - return IVerifier(verifierAddress).verify(signedReport, msg.sender); + + IVerifierFeeManager feeManager = s_feeManager; + + // Bill the verifier + if (address(feeManager) != address(0)) { + feeManager.processFee{value: msg.value}(payload, msg.sender); + } + + return IVerifier(verifierAddress).verify(payload, msg.sender); } /// @inheritdoc IVerifierProxy @@ -155,9 +146,20 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac /// @inheritdoc IVerifierProxy function setVerifier( bytes32 currentConfigDigest, - bytes32 newConfigDigest + bytes32 newConfigDigest, + Common.AddressAndWeight[] calldata addressesAndWeights ) external override onlyUnsetConfigDigest(newConfigDigest) onlyInitializedVerifier { s_verifiersByConfig[newConfigDigest] = msg.sender; + + // Empty recipients array will be ignored and must be set off chain + if (addressesAndWeights.length > 0) { + if (address(s_feeManager) == address(0)) { + revert ZeroAddress(); + } + + s_feeManager.setFeeRecipients(newConfigDigest, addressesAndWeights); + } + emit VerifierSet(currentConfigDigest, newConfigDigest, msg.sender); } @@ -170,7 +172,23 @@ contract VerifierProxy is IVerifierProxy, ConfirmedOwner, TypeAndVersionInterfac } /// @inheritdoc IVerifierProxy - function getVerifier(bytes32 configDigest) external view override returns (address) { + function getVerifier(bytes32 configDigest) external view override returns (address verifierAddress) { return s_verifiersByConfig[configDigest]; } + + /// @inheritdoc IVerifierProxy + function setAccessController(AccessControllerInterface accessController) external onlyOwner { + address oldAccessController = address(s_accessController); + s_accessController = accessController; + emit AccessControllerSet(oldAccessController, address(accessController)); + } + + /// @inheritdoc IVerifierProxy + function setFeeManager(IVerifierFeeManager feeManager) external onlyOwner { + if (address(feeManager) == address(0)) revert ZeroAddress(); + + address oldFeeManager = address(s_feeManager); + s_feeManager = IVerifierFeeManager(feeManager); + emit FeeManagerSet(oldFeeManager, address(feeManager)); + } } diff --git a/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol b/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol new file mode 100644 index 00000000000..5fea27220d2 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol @@ -0,0 +1,356 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import {ConfirmedOwner} from "../../shared/access/ConfirmedOwner.sol"; +import {IFeeManager} from "./interfaces/IFeeManager.sol"; +import {TypeAndVersionInterface} from "../../interfaces/TypeAndVersionInterface.sol"; +import {IERC165} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../libraries/Common.sol"; +import {IRewardManager} from "./interfaces/IRewardManager.sol"; +import {IWERC20} from "../../shared/interfaces/IWERC20.sol"; +import {IERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol"; +import {Math} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol"; + +/** + * @title FeeManager + * @author Michael Fletcher + * @author Austin Born + * @notice This contract is used for the handling of fees required for users verifying reports. + */ +contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { + /// @notice list of subscribers and their discounts subscriberDiscounts[subscriber][feedId][token] + mapping(address => mapping(bytes32 => mapping(address => uint256))) public s_subscriberDiscounts; + + /// @notice the total discount that can be applied to a fee, 1e18 = 100% discount + uint256 private constant PERCENTAGE_SCALAR = 1e18; + + /// @notice the LINK token address + address private immutable i_linkAddress; + + /// @notice the native token address + address private immutable i_nativeAddress; + + /// @notice the proxy address + address private immutable i_proxyAddress; + + /// @notice the reward manager address + IRewardManager private immutable i_rewardManager; + + // @notice the mask to apply to get the report version + bytes32 private constant REPORT_VERSION_MASK = 0xffff000000000000000000000000000000000000000000000000000000000000; + + // @notice the different report versions + bytes32 private constant REPORT_V1 = 0x0001000000000000000000000000000000000000000000000000000000000000; + bytes32 private constant REPORT_V2 = 0x0002000000000000000000000000000000000000000000000000000000000000; + bytes32 private constant REPORT_V3 = 0x0003000000000000000000000000000000000000000000000000000000000000; + + /// @notice the surcharge fee to be paid if paying in native + uint256 public s_nativeSurcharge; + + /// @notice the error thrown if the discount or surcharge is invalid + error InvalidSurcharge(); + + /// @notice the error thrown if the token is invalid + error InvalidToken(); + + /// @notice the error thrown if the discount is invalid + error InvalidDiscount(); + + /// @notice the error thrown if the address is invalid + error InvalidAddress(); + + /// @notice thrown if msg.value is supplied with a bad quote + error InvalidDeposit(); + + /// @notice thrown if a report has expired + error ExpiredReport(); + + /// @notice thrown if a report has no quote + error InvalidQuote(); + + /// @notice thrown if a report has an invalid version + error InvalidReportVersion(); + + // @notice Thrown when the caller is not authorized + error Unauthorized(); + + /// @notice Emitted whenever a subscriber's discount is updated + /// @param subscriber address of the subscriber to update discounts for + /// @param feedId Feed ID for the discount + /// @param token Token address for the discount + /// @param discount Discount to apply, in relation to the PERCENTAGE_SCALAR + event SubscriberDiscountUpdated(address indexed subscriber, bytes32 indexed feedId, address token, uint256 discount); + + /// @notice Emitted when updating the native surcharge + /// @param newSurcharge Surcharge amount to apply relative to PERCENTAGE_SCALAR + event NativeSurchargeUpdated(uint256 newSurcharge); + + /// @notice Emits when this contract does not have enough LINK to send to the reward manager when paying in native + /// @param configDigest Config digest of the report + /// @param linkQuantity Amount of LINK required to pay the reward + /// @param nativeQuantity Amount of native required to pay the reward + event InsufficientLink(bytes32 indexed configDigest, uint256 linkQuantity, uint256 nativeQuantity); + + /// @notice Emitted when funds are withdrawn + /// @param assetAddress Address of the asset withdrawn + /// @param quantity Amount of the asset withdrawn + event Withdraw(address adminAddress, address assetAddress, uint256 quantity); + + /** + * @notice Construct the FeeManager contract + * @param _linkAddress The address of the LINK token + * @param _nativeAddress The address of the wrapped ERC-20 version of the native token (represents fee in native or wrapped) + * @param _proxyAddress The address of the proxy contract + * @param _rewardManagerAddress The address of the reward manager contract + */ + constructor( + address _linkAddress, + address _nativeAddress, + address _proxyAddress, + address _rewardManagerAddress + ) ConfirmedOwner(msg.sender) { + if ( + _linkAddress == address(0) || + _nativeAddress == address(0) || + _proxyAddress == address(0) || + _rewardManagerAddress == address(0) + ) revert InvalidAddress(); + + i_linkAddress = _linkAddress; + i_nativeAddress = _nativeAddress; + i_proxyAddress = _proxyAddress; + i_rewardManager = IRewardManager(_rewardManagerAddress); + + IERC20(i_linkAddress).approve(address(i_rewardManager), type(uint256).max); + } + + modifier onlyOwnerOrProxy() { + if (msg.sender != owner() && msg.sender != i_proxyAddress) revert Unauthorized(); + _; + } + + /// @inheritdoc TypeAndVersionInterface + function typeAndVersion() external pure override returns (string memory) { + return "FeeManager 0.0.1"; + } + + /// @inheritdoc IERC165 + function supportsInterface(bytes4 interfaceId) external pure override returns (bool) { + return interfaceId == this.processFee.selector; + } + + /// @inheritdoc IFeeManager + function processFee(bytes calldata payload, address subscriber) external payable onlyOwnerOrProxy { + if (subscriber == address(this)) revert InvalidAddress(); + + //decode the report from the payload + (, bytes memory report) = abi.decode(payload, (bytes32[3], bytes)); + + //get the feedId from the report + bytes32 feedId = bytes32(report); + + //v2 doesn't need a quote payload, so skip the decoding if the report is a v1 report + Quote memory quote; + if (getReportVersion(feedId) != REPORT_V1) { + //all reports greater than v1 should have a quote payload + (, , , , , bytes memory quoteBytes) = abi.decode( + payload, + (bytes32[3], bytes, bytes32[], bytes32[], bytes32, bytes) + ); + + //decode the quote from the bytes + (quote) = abi.decode(quoteBytes, (Quote)); + } + + //decode the fee, it will always be native or LINK + (Common.Asset memory fee, Common.Asset memory reward) = getFeeAndReward(msg.sender, report, quote); + + //keep track of change in case of any over payment + uint256 change; + + //wrap the amount required to pay the fee + if (msg.value != 0) { + //quote must be in native with enough to cover the fee + if (fee.assetAddress != i_nativeAddress) revert InvalidDeposit(); + if (fee.amount > msg.value) revert InvalidDeposit(); + + //wrap the amount required to pay the fee & approve + IWERC20(i_nativeAddress).deposit{value: fee.amount}(); + + unchecked { + //msg.value is always >= to fee.amount + change = msg.value - fee.amount; + } + } + + //get the config digest which is the first 32 bytes of the payload + bytes32 configDigest = bytes32(payload); + + //some users might not be billed + if (fee.amount != 0) { + //if the fee is in LINK, transfer directly from the subscriber to the reward manager + if (fee.assetAddress == i_linkAddress) { + //distributes the fee + i_rewardManager.onFeePaid(configDigest, subscriber, reward.amount); + } else { + //if the fee is in native wrapped, transfer to this contract in exchange for the equivalent amount of LINK excluding the surcharge + if (msg.value == 0) { + IERC20(fee.assetAddress).transferFrom(subscriber, address(this), fee.amount); + } + + //check that the contract has enough LINK before paying the fee + if (reward.amount > IERC20(i_linkAddress).balanceOf(address(this))) { + // If not enough LINK on this contract to forward for rewards, fire this event and + // call onFeePaid out-of-band to pay out rewards + emit InsufficientLink(configDigest, reward.amount, fee.amount); + } else { + //bill the payee and distribute the fee using the config digest as the key + i_rewardManager.onFeePaid(configDigest, address(this), reward.amount); + } + } + } + + // a refund may be needed if the payee has paid in excess of the fee + if (change != 0) { + payable(subscriber).transfer(change); + } + } + + /// @inheritdoc IFeeManager + function getFeeAndReward( + address subscriber, + bytes memory report, + Quote memory quote + ) public view returns (Common.Asset memory, Common.Asset memory) { + Common.Asset memory fee; + Common.Asset memory reward; + + //get the feedId from the report + bytes32 feedId = bytes32(report); + + //the report needs to be a support version + bytes32 reportVersion = getReportVersion(feedId); + + //version 1 of the reports don't require quotes, so the fee will be 0 + if (reportVersion == REPORT_V1) { + fee.assetAddress = i_nativeAddress; + reward.assetAddress = i_linkAddress; + return (fee, reward); + } + + //verify the quote payload is a supported token + if (quote.quoteAddress != i_nativeAddress && quote.quoteAddress != i_linkAddress) { + revert InvalidQuote(); + } + + //decode the report depending on the version + uint256 linkQuantity; + uint256 nativeQuantity; + uint256 expiresAt; + if (reportVersion == REPORT_V2) { + (, , , , expiresAt, linkQuantity, nativeQuantity) = abi.decode( + report, + (bytes32, uint32, int192, uint32, uint32, uint192, uint192) + ); + } else if (reportVersion == REPORT_V3) { + (, , , , , , expiresAt, linkQuantity, nativeQuantity) = abi.decode( + report, + (bytes32, uint32, int192, int192, int192, uint32, uint32, uint192, uint192) + ); + } else { + revert InvalidReportVersion(); + } + + //read the timestamp bytes from the report data and verify it has not expired + if (expiresAt < block.timestamp) { + revert ExpiredReport(); + } + + //the reward is always set in LINK + reward.assetAddress = i_linkAddress; + reward.amount = linkQuantity; + + //calculate either the LINK fee or native fee if it's within the report + if (quote.quoteAddress == i_linkAddress) { + fee.assetAddress = reward.assetAddress; + fee.amount = reward.amount; + } else { + fee.assetAddress = i_nativeAddress; + fee.amount = Math.ceilDiv(nativeQuantity * (PERCENTAGE_SCALAR + s_nativeSurcharge), PERCENTAGE_SCALAR); + } + + //get the discount being applied + uint256 discount = s_subscriberDiscounts[subscriber][feedId][quote.quoteAddress]; + + //apply the discount to the fee, rounding up + fee.amount = fee.amount - ((fee.amount * discount) / PERCENTAGE_SCALAR); + + //apply the discount to the reward, rounding down + reward.amount = reward.amount - Math.ceilDiv(reward.amount * discount, PERCENTAGE_SCALAR); + + //return the fee + return (fee, reward); + } + + /// @inheritdoc IFeeManager + function setFeeRecipients( + bytes32 configDigest, + Common.AddressAndWeight[] calldata rewardRecipientAndWeights + ) external onlyOwnerOrProxy { + i_rewardManager.setRewardRecipients(configDigest, rewardRecipientAndWeights); + } + + /// @inheritdoc IFeeManager + function setNativeSurcharge(uint256 surcharge) external onlyOwner { + if (surcharge > PERCENTAGE_SCALAR) revert InvalidSurcharge(); + + s_nativeSurcharge = surcharge; + + emit NativeSurchargeUpdated(surcharge); + } + + /// @inheritdoc IFeeManager + function updateSubscriberDiscount( + address subscriber, + bytes32 feedId, + address token, + uint256 discount + ) external onlyOwner { + //make sure the discount is not greater than the total discount that can be applied + if (discount > PERCENTAGE_SCALAR) revert InvalidDiscount(); + //make sure the token is either LINK or native + if (token != i_linkAddress && token != i_nativeAddress) revert InvalidAddress(); + + s_subscriberDiscounts[subscriber][feedId][token] = discount; + + emit SubscriberDiscountUpdated(subscriber, feedId, token, discount); + } + + /// @inheritdoc IFeeManager + function withdraw(address assetAddress, uint256 quantity) external onlyOwner { + //address 0 is used to withdraw native in the context of withdrawing + if (assetAddress == address(0)) { + payable(owner()).transfer(quantity); + return; + } + + //withdraw the requested asset + IERC20(assetAddress).transfer(owner(), quantity); + + //emit event when funds are withdrawn + emit Withdraw(msg.sender, assetAddress, quantity); + } + + function linkAvailableForPayment() external view returns (uint256) { + //return the amount of LINK this contact has available to pay rewards + return IERC20(i_linkAddress).balanceOf(address(this)); + } + + /** + * @notice Gets the current version of the report that is encoded as the last two bytes of the feed + * @param feedId feed id to get the report version for + */ + function getReportVersion(bytes32 feedId) internal pure returns (bytes32) { + return REPORT_VERSION_MASK & feedId; + } +} diff --git a/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol b/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol new file mode 100644 index 00000000000..f32cbd5e24d --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol @@ -0,0 +1,308 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import {ConfirmedOwner} from "../../shared/access/ConfirmedOwner.sol"; +import {IRewardManager} from "./interfaces/IRewardManager.sol"; +import {IERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol"; +import {TypeAndVersionInterface} from "../../interfaces/TypeAndVersionInterface.sol"; +import {IERC165} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../libraries/Common.sol"; + +/** + * @title FeeManager + * @author Michael Fletcher + * @author Austin Born + * @notice This contract will be used to reward any configured recipients within a pool. Recipients will receive a share of their pool relative to their configured weight. + */ +contract RewardManager is IRewardManager, ConfirmedOwner, TypeAndVersionInterface { + // @dev The mapping of total fees collected for a particular pot: s_totalRewardRecipientFees[poolId] + mapping(bytes32 => uint256) public s_totalRewardRecipientFees; + + // @dev The mapping of fee balances for each pot last time the recipient claimed: s_totalRewardRecipientFeesLastClaimedAmounts[poolId][recipient] + mapping(bytes32 => mapping(address => uint256)) private s_totalRewardRecipientFeesLastClaimedAmounts; + + // @dev The mapping of RewardRecipient weights for a particular poolId: s_rewardRecipientWeights[poolId][rewardRecipient]. + mapping(bytes32 => mapping(address => uint256)) public s_rewardRecipientWeights; + + // @dev Keep track of the reward recipient weights that have been set to prevent duplicates + mapping(bytes32 => bool) private s_rewardRecipientWeightsSet; + + // @dev Store a list of pool ids that have been registered, to make off chain lookups easier + bytes32[] public s_registeredPoolIds; + + // @dev The address for the LINK contract + address private immutable i_linkAddress; + + // The total weight of all RewardRecipients. 1e18 = 100% of the pool fees + uint256 private constant PERCENTAGE_SCALAR = 1e18; + + // The fee manager address + address public s_feeManagerAddress; + + // @notice Thrown whenever the RewardRecipient weights are invalid + error InvalidWeights(); + + // @notice Thrown when any given address is invalid + error InvalidAddress(); + + // @notice Thrown when the pool id is invalid + error InvalidPoolId(); + + // @notice Thrown when the calling contract is not within the authorized contracts + error Unauthorized(); + + // Events emitted upon state change + event RewardRecipientsUpdated(bytes32 indexed poolId, Common.AddressAndWeight[] newRewardRecipients); + event RewardsClaimed(bytes32 indexed poolId, address indexed recipient, uint256 quantity); + event FeeManagerUpdated(address newFeeManagerAddress); + event FeePaid(bytes32 poolId, address payee, uint256 quantity); + + /** + * @notice Constructor + * @param linkAddress address of the wrapped LINK token + */ + constructor(address linkAddress) ConfirmedOwner(msg.sender) { + //ensure that the address ia not zero + if (linkAddress == address(0)) revert InvalidAddress(); + + i_linkAddress = linkAddress; + } + + // @inheritdoc TypeAndVersionInterface + function typeAndVersion() external pure override returns (string memory) { + return "RewardManager 0.0.1"; + } + + // @inheritdoc IERC165 + function supportsInterface(bytes4 interfaceId) external pure override returns (bool) { + return interfaceId == this.onFeePaid.selector; + } + + modifier onlyOwnerOrFeeManager() { + if (msg.sender != owner() && msg.sender != s_feeManagerAddress) revert Unauthorized(); + _; + } + + modifier onlyOwnerOrRecipientInPool(bytes32 poolId) { + if (msg.sender != owner() && s_rewardRecipientWeights[poolId][msg.sender] == 0) revert Unauthorized(); + _; + } + + /// @inheritdoc IRewardManager + function onFeePaid(bytes32 poolId, address payee, uint256 amount) external override onlyOwnerOrFeeManager { + //update the total fees collected for this pot + unchecked { + //the total amount for any ERC20 asset cannot exceed 2^256 - 1 + s_totalRewardRecipientFees[poolId] += amount; + } + + //transfer the fee to this contract + IERC20(i_linkAddress).transferFrom(payee, address(this), amount); + + emit FeePaid(poolId, payee, amount); + } + + /// @inheritdoc IRewardManager + function claimRewards(bytes32[] memory poolIds) external override { + _claimRewards(msg.sender, poolIds); + } + + // wrapper impl for claimRewards + function _claimRewards(address recipient, bytes32[] memory poolIds) internal returns (uint256) { + //get the total amount claimable for this recipient + uint256 claimAmount; + + //loop and claim all the rewards in the poolId pot + for (uint256 i; i < poolIds.length; ++i) { + //get the poolId to be claimed + bytes32 poolId = poolIds[i]; + + //get the total fees for the pot + uint256 totalFeesInPot = s_totalRewardRecipientFees[poolId]; + + unchecked { + //get the claimable amount for this recipient, this calculation will never exceed the amount in the pot + uint256 claimableAmount = totalFeesInPot - s_totalRewardRecipientFeesLastClaimedAmounts[poolId][recipient]; + + //calculate the recipients share of the fees, which is their weighted share of the difference between the last amount they claimed and the current amount in the pot. This can never be more than the total amount in existence + uint256 recipientShare = (claimableAmount * s_rewardRecipientWeights[poolId][recipient]) / PERCENTAGE_SCALAR; + + //if there's no fees to claim, continue as there's nothing to update + if (recipientShare == 0) continue; + + //keep track of the total amount claimable, this can never be more than the total amount in existence + claimAmount += recipientShare; + + //set the current total amount of fees in the pot as it's used to calculate future claims + s_totalRewardRecipientFeesLastClaimedAmounts[poolId][recipient] = totalFeesInPot; + + //emit event if the recipient has rewards to claim + emit RewardsClaimed(poolIds[i], recipient, recipientShare); + } + } + + //check if there's any rewards to claim in the given poolId + if (claimAmount != 0) { + //transfer the reward to the recipient + IERC20(i_linkAddress).transfer(recipient, claimAmount); + } + + return claimAmount; + } + + /// @inheritdoc IRewardManager + function setRewardRecipients( + bytes32 poolId, + Common.AddressAndWeight[] calldata rewardRecipientAndWeights + ) external override onlyOwnerOrFeeManager { + //revert if there are no recipients to set + if (rewardRecipientAndWeights.length == 0) revert InvalidAddress(); + + //check that the weights have not been previously set + if (s_rewardRecipientWeightsSet[poolId]) revert InvalidPoolId(); + + //keep track of the registered poolIds to make off chain lookups easier + s_registeredPoolIds.push(poolId); + + //keep track of which pools have had their reward recipients set + s_rewardRecipientWeightsSet[poolId] = true; + + //set the reward recipients, this will only be called once and contain the full set of RewardRecipients with a total weight of 100% + _setRewardRecipientWeights(poolId, rewardRecipientAndWeights, PERCENTAGE_SCALAR); + + emit RewardRecipientsUpdated(poolId, rewardRecipientAndWeights); + } + + function _setRewardRecipientWeights( + bytes32 poolId, + Common.AddressAndWeight[] calldata rewardRecipientAndWeights, + uint256 expectedWeight + ) internal { + //we can't update the weights if it contains duplicates + if (Common.hasDuplicateAddresses(rewardRecipientAndWeights)) revert InvalidAddress(); + + //loop all the reward recipients and validate the weight and address + uint256 totalWeight; + for (uint256 i; i < rewardRecipientAndWeights.length; ++i) { + //get the weight + uint256 recipientWeight = rewardRecipientAndWeights[i].weight; + //get the address + address recipientAddress = rewardRecipientAndWeights[i].addr; + + //ensure the reward recipient address is not zero + if (recipientAddress == address(0)) revert InvalidAddress(); + //ensure the weight is not zero + if (recipientWeight == 0) revert InvalidWeights(); + + //save/overwrite the weight for the reward recipient + s_rewardRecipientWeights[poolId][recipientAddress] = recipientWeight; + + unchecked { + //keep track of the cumulative weight, this cannot overflow as the total weight is restricted at 1e18 + totalWeight += recipientWeight; + } + } + + //if total weight is not met, the fees will either be under or over distributed + if (totalWeight != expectedWeight) revert InvalidWeights(); + } + + /// @inheritdoc IRewardManager + function updateRewardRecipients( + bytes32 poolId, + Common.AddressAndWeight[] calldata newRewardRecipients + ) external override onlyOwner { + //create an array of poolIds to pass to _claimRewards if required + bytes32[] memory poolIds = new bytes32[](1); + poolIds[0] = poolId; + + //loop all the reward recipients and claim their rewards before updating their weights + uint256 existingTotalWeight; + for (uint256 i; i < newRewardRecipients.length; ) { + //get the address + address recipientAddress = newRewardRecipients[i].addr; + //get the existing weight + uint256 existingWeight = s_rewardRecipientWeights[poolId][recipientAddress]; + + //if the existing weight is 0, the recipient isn't part of this configuration + if (existingWeight == 0) revert InvalidAddress(); + + //if a recipient is updated, the rewards must be claimed first as they can't claim previous fees at the new weight + _claimRewards(newRewardRecipients[i].addr, poolIds); + + unchecked { + //keep tally of the weights so that the expected collective weight is known + existingTotalWeight += existingWeight; + //there will never be enough reward recipients for i to overflow + ++i; + } + } + + //update the reward recipients, if the new collective weight isn't equal to the previous collective weight, the fees will either be under or over distributed + _setRewardRecipientWeights(poolId, newRewardRecipients, existingTotalWeight); + + //emit event + emit RewardRecipientsUpdated(poolId, newRewardRecipients); + } + + /// @inheritdoc IRewardManager + function payRecipients(bytes32 poolId, address[] calldata recipients) external onlyOwnerOrRecipientInPool(poolId) { + //convert poolIds to an array to match the interface of _claimRewards + bytes32[] memory poolIdsArray = new bytes32[](1); + poolIdsArray[0] = poolId; + + //loop each recipient and claim the rewards for each of the pools and assets + for (uint256 i; i < recipients.length; ) { + _claimRewards(recipients[i], poolIdsArray); + + unchecked { + //there will never be enough recipients for i to overflow + ++i; + } + } + } + + /// @inheritdoc IRewardManager + function setFeeManager(address newFeeManagerAddress) external onlyOwner { + if (newFeeManagerAddress == address(0)) revert InvalidAddress(); + + s_feeManagerAddress = newFeeManagerAddress; + + emit FeeManagerUpdated(newFeeManagerAddress); + } + + /// @inheritdoc IRewardManager + function getAvailableRewardPoolIds(address recipient) external view returns (bytes32[] memory) { + //get the length of the pool ids which we will loop through and potentially return + uint256 registeredPoolIdsLength = s_registeredPoolIds.length; + + //create a new array with the maximum amount of potential pool ids + bytes32[] memory claimablePoolIds = new bytes32[](registeredPoolIdsLength); + //we want the pools which a recipient has funds for to be sequential, so we need to keep track of the index + uint256 poolIdArrayIndex; + + //loop all the pool ids, and check if the recipient has a registered weight and a claimable amount + for (uint256 i; i < registeredPoolIdsLength; ) { + //get the poolId + bytes32 poolId = s_registeredPoolIds[i]; + //if the recipient has a weight, they are a recipient of this poolId + if (s_rewardRecipientWeights[poolId][recipient] != 0) { + //if the recipient has any LINK, then add the poolId to the array + if (s_totalRewardRecipientFees[poolId] != 0) { + claimablePoolIds[poolIdArrayIndex] = poolId; + unchecked { + //there will never be enough pool ids for i to overflow + ++poolIdArrayIndex; + } + } + } + + unchecked { + //there will never be enough poolIds for i to overflow + ++i; + } + } + + return claimablePoolIds; + } +} diff --git a/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol b/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol new file mode 100644 index 00000000000..7716cdeaa31 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol @@ -0,0 +1,64 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {IVerifierFeeManager} from "../../interfaces/IVerifierFeeManager.sol"; + +interface IFeeManager is IERC165, IVerifierFeeManager { + struct Quote { + address quoteAddress; + } + + /** + * @notice Processes the fee for a report, billing the subscriber and paying the reward manager + * @param payload report and quote data to process the fee for + * @param subscriber address of the user to process fee for + */ + function processFee(bytes calldata payload, address subscriber) external payable; + + /** + * @notice Calculate the applied fee and the reward from a report. If the sender is a subscriber, they will receive a discount. + * @param subscriber address trying to verify + * @param report report to calculate the fee for + * @param quote any metadata required to fetch the fee + * @return (fee, reward) fee and the reward data + */ + function getFeeAndReward( + address subscriber, + bytes memory report, + Quote memory quote + ) external returns (Common.Asset memory, Common.Asset memory); + + /** + * @notice Sets the fee recipients within the reward manager + * @param configDigest digest of the configuration + * @param rewardRecipientAndWeights the address and weights of all the recipients to receive rewards + */ + function setFeeRecipients( + bytes32 configDigest, + Common.AddressAndWeight[] calldata rewardRecipientAndWeights + ) external; + + /** + * @notice Sets the native surcharge + * @param surcharge surcharge to be paid if paying in native + */ + function setNativeSurcharge(uint256 surcharge) external; + + /** + * @notice Adds a subscriber to the fee manager + * @param subscriber address of the subscriber + * @param feedId feed id to apply the discount to + * @param token token to apply the discount to + * @param discount discount to be applied to the fee + */ + function updateSubscriberDiscount(address subscriber, bytes32 feedId, address token, uint256 discount) external; + + /** + * @notice Withdraws any native rewards to the owner address + * @param quantity quantity of native tokens to withdraw, address(0) is native + * @param quantity quantity to withdraw + */ + function withdraw(address assetAddress, uint256 quantity) external; +} diff --git a/contracts/src/v0.8/llo-feeds/dev/interfaces/IRewardManager.sol b/contracts/src/v0.8/llo-feeds/dev/interfaces/IRewardManager.sol new file mode 100644 index 00000000000..b560b8efb61 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/dev/interfaces/IRewardManager.sol @@ -0,0 +1,54 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../../libraries/Common.sol"; + +interface IRewardManager is IERC165 { + /** + * @notice Record the fee received for a particular pool + * @param poolId poolId of the report being verified + * @param payee the user the funds should be deposited from + * @param amount the amount to be paid into the pool + */ + function onFeePaid(bytes32 poolId, address payee, uint256 amount) external; + + /** + * @notice Claims the rewards in a specific pool + * @param poolIds array of poolIds to claim rewards for + */ + function claimRewards(bytes32[] calldata poolIds) external; + + /** + * @notice Set the RewardRecipients and weights for a specific pool. This should only be called once per pool Id. Else updateRewardRecipients should be used. + * @param poolId poolId to set RewardRecipients and weights for + * @param rewardRecipientAndWeights array of each RewardRecipient and associated weight + */ + function setRewardRecipients(bytes32 poolId, Common.AddressAndWeight[] calldata rewardRecipientAndWeights) external; + + /** + * @notice Updates a subset the reward recipients for a specific poolId. The collective weight of the recipients should add up to the recipients existing weights. Any recipients with a weight of 0 will be removed. + * @param poolId the poolId to update + * @param newRewardRecipients array of new reward recipients + */ + function updateRewardRecipients(bytes32 poolId, Common.AddressAndWeight[] calldata newRewardRecipients) external; + + /** + * @notice Pays all the recipients for each of the pool ids + * @param poolId the pool id to pay recipients for + * @param recipients array of recipients to pay within the pool + */ + function payRecipients(bytes32 poolId, address[] calldata recipients) external; + + /** + * @notice Sets the fee manager. This needs to be done post construction to prevent a circular dependency. + * @param newFeeManager address of the new verifier proxy + */ + function setFeeManager(address newFeeManager) external; + + /** + * @notice Gets a list of pool ids which have reward for a specific recipient. + * @param recipient address of the recipient to get pool ids for + */ + function getAvailableRewardPoolIds(address recipient) external view returns (bytes32[] memory); +} diff --git a/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol b/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol index b0e8b358d50..c2bc95cff53 100644 --- a/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol +++ b/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol @@ -1,21 +1,22 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.16; -import {IERC165} from "../../vendor/IERC165.sol"; +import {IERC165} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../libraries/Common.sol"; interface IVerifier is IERC165 { /** * @notice Verifies that the data encoded has been signed * correctly by routing to the correct verifier. * @param signedReport The encoded data to be verified. - * @param requester The original address that requested to verify the contract. + * @param sender The address that requested to verify the contract. * This is only used for logging purposes. * @dev Verification is typically only done through the proxy contract so * we can't just use msg.sender to log the requester as the msg.sender * contract will always be the proxy. * @return response The encoded verified response. */ - function verify(bytes memory signedReport, address requester) external returns (bytes memory response); + function verify(bytes calldata signedReport, address sender) external returns (bytes memory response); /** * @notice sets offchain reporting protocol configuration incl. participating oracles @@ -26,6 +27,7 @@ interface IVerifier is IERC165 { * @param onchainConfig serialized configuration used by the contract (and possibly oracles) * @param offchainConfigVersion version number for offchainEncoding schema * @param offchainConfig serialized configuration used by the oracles exclusively and only passed through the contract + * @param recipientAddressesAndWeights the addresses and weights of all the recipients to receive rewards */ function setConfig( bytes32 feedId, @@ -34,9 +36,40 @@ interface IVerifier is IERC165 { uint8 f, bytes memory onchainConfig, uint64 offchainConfigVersion, - bytes memory offchainConfig + bytes memory offchainConfig, + Common.AddressAndWeight[] memory recipientAddressesAndWeights ) external; + /** + * @notice Activates the configuration for a config digest + * @param feedId Feed ID to activate config for + * @param configDigest The config digest to activate + * @dev This function can be called by the contract admin to activate a configuration. + */ + function activateConfig(bytes32 feedId, bytes32 configDigest) external; + + /** + * @notice Deactivates the configuration for a config digest + * @param feedId Feed ID to deactivate config for + * @param configDigest The config digest to deactivate + * @dev This function can be called by the contract admin to deactivate an incorrect configuration. + */ + function deactivateConfig(bytes32 feedId, bytes32 configDigest) external; + + /** + * @notice Activates the given feed + * @param feedId Feed ID to activated + * @dev This function can be called by the contract admin to activate a feed + */ + function activateFeed(bytes32 feedId) external; + + /** + * @notice Deactivates the given feed + * @param feedId Feed ID to deactivated + * @dev This function can be called by the contract admin to deactivate a feed + */ + function deactivateFeed(bytes32 feedId) external; + /** * @notice returns the latest config digest and epoch for a feed * @param feedId Feed ID to fetch data for diff --git a/contracts/src/v0.8/llo-feeds/interfaces/IVerifierFeeManager.sol b/contracts/src/v0.8/llo-feeds/interfaces/IVerifierFeeManager.sol new file mode 100644 index 00000000000..345122eb50b --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/interfaces/IVerifierFeeManager.sol @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.16; + +import {IERC165} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../libraries/Common.sol"; + +interface IVerifierFeeManager is IERC165 { + /** + * @notice Handles fees for a report from the subscriber and manages rewards + * @param payload report and quote to process the fee for + * @param subscriber address of the fee will be applied + */ + function processFee(bytes calldata payload, address subscriber) external payable; + + /** + * @notice Sets the fee recipients according to the fee manager + * @param configDigest digest of the configuration + * @param rewardRecipientAndWeights the address and weights of all the recipients to receive rewards + */ + function setFeeRecipients( + bytes32 configDigest, + Common.AddressAndWeight[] calldata rewardRecipientAndWeights + ) external; +} diff --git a/contracts/src/v0.8/llo-feeds/interfaces/IVerifierProxy.sol b/contracts/src/v0.8/llo-feeds/interfaces/IVerifierProxy.sol index 66db64f3e13..d128b5090fa 100644 --- a/contracts/src/v0.8/llo-feeds/interfaces/IVerifierProxy.sol +++ b/contracts/src/v0.8/llo-feeds/interfaces/IVerifierProxy.sol @@ -1,31 +1,41 @@ // SPDX-License-Identifier: MIT pragma solidity 0.8.16; +import {Common} from "../../libraries/Common.sol"; +import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; +import {IVerifierFeeManager} from "./IVerifierFeeManager.sol"; + interface IVerifierProxy { /** * @notice Verifies that the data encoded has been signed - * correctly by routing to the correct verifier. - * @param signedReport The encoded data to be verified. - * @return verifierResponse The encoded response from the verifier. + * correctly by routing to the correct verifier, and bills the user if applicable. + * @param payload The encoded data to be verified, including the signed + * report and any metadata for billing. + * @return verifiedReport The encoded report from the verifier. + */ + function verify(bytes calldata payload) external payable returns (bytes memory verifiedReport); + + /** + * @notice Sets the verifier address initially, allowing `setVerifier` to be set by this Verifier in the future + * @param verifierAddress The address of the verifier contract to initialize */ - function verify(bytes memory signedReport) external returns (bytes memory verifierResponse); + function initializeVerifier(address verifierAddress) external; /** * @notice Sets a new verifier for a config digest * @param currentConfigDigest The current config digest * @param newConfigDigest The config digest to set + * @param addressesAndWeights The addresses and weights of reward recipients * reports for a given config digest. */ - function setVerifier(bytes32 currentConfigDigest, bytes32 newConfigDigest) external; - - /** - * @notice Sets the verifier address to initialized - * @param verifierAddr The address of the verifier contract that we want to initialize - */ - function initializeVerifier(address verifierAddr) external; + function setVerifier( + bytes32 currentConfigDigest, + bytes32 newConfigDigest, + Common.AddressAndWeight[] memory addressesAndWeights + ) external; /** - * @notice Removes a verifier + * @notice Removes a verifier for a given config digest * @param configDigest The config digest of the verifier to remove */ function unsetVerifier(bytes32 configDigest) external; @@ -34,8 +44,20 @@ interface IVerifierProxy { * @notice Retrieves the verifier address that verifies reports * for a config digest. * @param configDigest The config digest to query for - * @return verifierAddr The address of the verifier contract that verifies + * @return verifierAddress The address of the verifier contract that verifies * reports for a given config digest. */ - function getVerifier(bytes32 configDigest) external view returns (address verifierAddr); + function getVerifier(bytes32 configDigest) external view returns (address verifierAddress); + + /** + * @notice Called by the admin to set an access controller contract + * @param accessController The new access controller to set + */ + function setAccessController(AccessControllerInterface accessController) external; + + /** + * @notice Updates the fee manager + * @param feeManager The new fee manager + */ + function setFeeManager(IVerifierFeeManager feeManager) external; } diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol new file mode 100644 index 00000000000..be984af3267 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol @@ -0,0 +1,344 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {Test} from "forge-std/Test.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; +import {IFeeManager} from "../../dev/interfaces/IFeeManager.sol"; +import {RewardManager} from "../../dev/RewardManager.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {ERC20Mock} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol"; +import {WERC20Mock} from "../../../shared/mocks/WERC20Mock.sol"; + +/** + * @title BaseFeeManagerTest + * @author Michael Fletcher + * @notice Base class for all feeManager tests + * @dev This contract is intended to be inherited from and not used directly. It contains functionality to setup the feeManager + */ +contract BaseFeeManagerTest is Test { + //contracts + FeeManager internal feeManager; + RewardManager internal rewardManager; + + ERC20Mock internal link; + WERC20Mock internal native; + + //erc20 config + uint256 internal constant DEFAULT_LINK_MINT_QUANTITY = 100 ether; + uint256 internal constant DEFAULT_NATIVE_MINT_QUANTITY = 100 ether; + + //contract owner + address internal constant INVALID_ADDRESS = address(0); + address internal constant ADMIN = address(uint160(uint256(keccak256("ADMIN")))); + address internal constant USER = address(uint160(uint256(keccak256("USER")))); + address internal constant PROXY = address(uint160(uint256(keccak256("PROXY")))); + + //version masks + bytes32 internal constant V_MASK = 0x0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff; + bytes32 internal constant V1_BITMASK = 0x0001000000000000000000000000000000000000000000000000000000000000; + bytes32 internal constant V2_BITMASK = 0x0002000000000000000000000000000000000000000000000000000000000000; + bytes32 internal constant V3_BITMASK = 0x0003000000000000000000000000000000000000000000000000000000000000; + + //feed ids & config digests + bytes32 internal constant DEFAULT_FEED_1_V1 = (keccak256("ETH-USD") & V_MASK) | V1_BITMASK; + bytes32 internal constant DEFAULT_FEED_1_V2 = (keccak256("ETH-USD") & V_MASK) | V2_BITMASK; + bytes32 internal constant DEFAULT_FEED_1_V3 = (keccak256("ETH-USD") & V_MASK) | V3_BITMASK; + + bytes32 internal constant DEFAULT_FEED_2_V3 = (keccak256("LINK-USD") & V_MASK) | V3_BITMASK; + bytes32 internal constant DEFAULT_CONFIG_DIGEST = keccak256("DEFAULT_CONFIG_DIGEST"); + + //report + uint256 internal constant DEFAULT_REPORT_LINK_FEE = 1e10; + uint256 internal constant DEFAULT_REPORT_NATIVE_FEE = 1e12; + + //rewards + uint256 internal constant FEE_SCALAR = 1e18; + + address internal constant NATIVE_WITHDRAW_ADDRESS = address(0); + + //the selector for each error + bytes4 internal immutable INVALID_DISCOUNT_ERROR = FeeManager.InvalidDiscount.selector; + bytes4 internal immutable INVALID_ADDRESS_ERROR = FeeManager.InvalidAddress.selector; + bytes4 internal immutable INVALID_SURCHARGE_ERROR = FeeManager.InvalidSurcharge.selector; + bytes4 internal immutable EXPIRED_REPORT_ERROR = FeeManager.ExpiredReport.selector; + bytes4 internal immutable INVALID_DEPOSIT_ERROR = FeeManager.InvalidDeposit.selector; + bytes4 internal immutable INVALID_QUOTE_ERROR = FeeManager.InvalidQuote.selector; + bytes4 internal immutable UNAUTHORIZED_ERROR = FeeManager.Unauthorized.selector; + bytes4 internal immutable INVALID_REPORT_VERSION_ERROR = FeeManager.InvalidReportVersion.selector; + bytes internal constant ONLY_CALLABLE_BY_OWNER_ERROR = "Only callable by owner"; + bytes internal constant INSUFFICIENT_ALLOWANCE_ERROR = "ERC20: insufficient allowance"; + + //events emitted + event SubscriberDiscountUpdated(address indexed subscriber, bytes32 indexed feedId, address token, uint256 discount); + event NativeSurchargeUpdated(uint256 newSurcharge); + event InsufficientLink(bytes32 indexed configDigest, uint256 linkQuantity, uint256 nativeQuantity); + event Withdraw(address adminAddress, address assetAddress, uint256 quantity); + + function setUp() public virtual { + //change to admin user + vm.startPrank(ADMIN); + + //init required contracts + _initializeContracts(); + } + + function _initializeContracts() internal { + link = new ERC20Mock("LINK", "LINK", ADMIN, 0); + native = new WERC20Mock(); + + rewardManager = new RewardManager(getLinkAddress()); + feeManager = new FeeManager(getLinkAddress(), getNativeAddress(), PROXY, address(rewardManager)); + + //link the feeManager to the reward manager + rewardManager.setFeeManager(address(feeManager)); + + //mint some tokens to the admin + link.mint(ADMIN, DEFAULT_LINK_MINT_QUANTITY); + native.mint(ADMIN, DEFAULT_NATIVE_MINT_QUANTITY); + vm.deal(ADMIN, DEFAULT_NATIVE_MINT_QUANTITY); + + //mint some tokens to the user + link.mint(USER, DEFAULT_LINK_MINT_QUANTITY); + native.mint(USER, DEFAULT_NATIVE_MINT_QUANTITY); + vm.deal(USER, DEFAULT_NATIVE_MINT_QUANTITY); + + //mint some tokens to the proxy + link.mint(PROXY, DEFAULT_LINK_MINT_QUANTITY); + native.mint(PROXY, DEFAULT_NATIVE_MINT_QUANTITY); + vm.deal(PROXY, DEFAULT_NATIVE_MINT_QUANTITY); + } + + function setSubscriberDiscount( + address subscriber, + bytes32 feedId, + address token, + uint256 discount, + address sender + ) internal { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //set the discount + feeManager.updateSubscriberDiscount(subscriber, feedId, token, discount); + + //change back to the original address + changePrank(originalAddr); + } + + function setNativeSurcharge(uint256 surcharge, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //set the surcharge + feeManager.setNativeSurcharge(surcharge); + + //change back to the original address + changePrank(originalAddr); + } + + // solium-disable-next-line no-unused-vars + function getFee( + bytes memory report, + IFeeManager.Quote memory quote, + address subscriber + ) public view returns (Common.Asset memory) { + //get the fee + (Common.Asset memory fee, ) = feeManager.getFeeAndReward(subscriber, report, quote); + + return fee; + } + + function getReward( + bytes memory report, + IFeeManager.Quote memory quote, + address subscriber + ) public view returns (Common.Asset memory) { + //get the reward + (, Common.Asset memory reward) = feeManager.getFeeAndReward(subscriber, report, quote); + + return reward; + } + + function getV0Report(bytes32 feedId) public pure returns (bytes memory) { + return abi.encode(feedId, uint32(0), int192(0), int192(0), int192(0), uint64(0), bytes32(0), uint64(0), uint64(0)); + } + + function getV1Report(bytes32 feedId) public view returns (bytes memory) { + return + abi.encode( + feedId, + uint32(0), + int192(0), + uint32(0), + uint32(block.timestamp), + DEFAULT_REPORT_LINK_FEE, + DEFAULT_REPORT_NATIVE_FEE + ); + } + + function getV1ReportWithExpiryAndFee( + bytes32 feedId, + uint256 expiry, + uint256 linkFee, + uint256 nativeFee + ) public view returns (bytes memory) { + return abi.encode(feedId, uint32(0), int192(0), uint32(0), uint32(expiry), linkFee, nativeFee); + } + + function getV2Report(bytes32 feedId) public view returns (bytes memory) { + return + abi.encode( + feedId, + uint32(0), + int192(0), + int192(0), + int192(0), + uint32(0), + uint32(block.timestamp), + uint192(DEFAULT_REPORT_LINK_FEE), + uint192(DEFAULT_REPORT_NATIVE_FEE) + ); + } + + function getV2ReportWithCustomExpiryAndFee( + bytes32 feedId, + uint256 expiry, + uint256 linkFee, + uint256 nativeFee + ) public pure returns (bytes memory) { + return + abi.encode( + feedId, + uint32(0), + int192(0), + int192(0), + int192(0), + uint32(0), + uint32(expiry), + uint192(linkFee), + uint192(nativeFee) + ); + } + + function getLinkQuote() public view returns (IFeeManager.Quote memory) { + return IFeeManager.Quote(getLinkAddress()); + } + + function getNativeQuote() public view returns (IFeeManager.Quote memory) { + return IFeeManager.Quote(getNativeAddress()); + } + + function withdraw(address assetAddress, uint256 amount, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //set the surcharge + feeManager.withdraw(assetAddress, amount); + + //change back to the original address + changePrank(originalAddr); + } + + function getLinkBalance(address balanceAddress) public view returns (uint256) { + return link.balanceOf(balanceAddress); + } + + function getNativeBalance(address balanceAddress) public view returns (uint256) { + return native.balanceOf(balanceAddress); + } + + function getNativeUnwrappedBalance(address balanceAddress) public view returns (uint256) { + return balanceAddress.balance; + } + + function mintLink(address recipient, uint256 amount) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(ADMIN); + + //mint the link to the recipient + link.mint(recipient, amount); + + //change back to the original address + changePrank(originalAddr); + } + + function mintNative(address recipient, uint256 amount, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //mint the native to the recipient + native.mint(recipient, amount); + + //change back to the original address + changePrank(originalAddr); + } + + function issueUnwrappedNative(address recipient, uint256 quantity) public { + vm.deal(recipient, quantity); + } + + function processFee(bytes memory payload, address subscriber, uint256 wrappedNativeValue, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //process the fee + feeManager.processFee{value: wrappedNativeValue}(payload, subscriber); + + //change back to the original address + changePrank(originalAddr); + } + + function getPayload(bytes memory reportPayload, bytes memory quotePayload) public pure returns (bytes memory) { + return + abi.encode( + [DEFAULT_CONFIG_DIGEST, 0, 0], + reportPayload, + new bytes32[](1), + new bytes32[](1), + bytes32(""), + quotePayload + ); + } + + function getQuotePayload(address quoteAddress) public pure returns (bytes memory) { + return abi.encode(quoteAddress); + } + + function approveLink(address spender, uint256 quantity, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //approve the link to be transferred + link.approve(spender, quantity); + + //change back to the original address + changePrank(originalAddr); + } + + function approveNative(address spender, uint256 quantity, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //approve the link to be transferred + native.approve(spender, quantity); + + //change back to the original address + changePrank(originalAddr); + } + + function getLinkAddress() public view returns (address) { + return address(link); + } + + function getNativeAddress() public view returns (address) { + return address(native); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol new file mode 100644 index 00000000000..69c13d2f8e9 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol @@ -0,0 +1,137 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {Test} from "forge-std/Test.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; +import {Common} from "../../../libraries/Common.sol"; +import "./BaseFeeManager.t.sol"; + +/** + * @title BaseFeeManagerTest + * @author Michael Fletcher + * @notice This contract will test the setup functionality of the feemanager + */ +contract FeeManagerProcessFeeTest is BaseFeeManagerTest { + function setUp() public override { + super.setUp(); + } + + function test_WithdrawERC20() public { + //simulate a fee + mintLink(address(feeManager), DEFAULT_LINK_MINT_QUANTITY); + + //get the balances to ne used for comparison + uint256 contractBalance = getLinkBalance(address(feeManager)); + uint256 adminBalance = getLinkBalance(ADMIN); + + //the amount to withdraw + uint256 withdrawAmount = contractBalance / 2; + + //withdraw some balance + withdraw(getLinkAddress(), withdrawAmount, ADMIN); + + //check the balance has been reduced + uint256 newContractBalance = getLinkBalance(address(feeManager)); + uint256 newAdminBalance = getLinkBalance(ADMIN); + + //check the balance is greater than zero + assertGt(newContractBalance, 0); + //check the balance has been reduced by the correct amount + assertEq(newContractBalance, contractBalance - withdrawAmount); + //check the admin balance has increased by the correct amount + assertEq(newAdminBalance, adminBalance + withdrawAmount); + } + + function test_WithdrawUnwrappedNative() public { + //issue funds straight to the contract to bypass the lack of fallback function + issueUnwrappedNative(address(feeManager), DEFAULT_NATIVE_MINT_QUANTITY); + + //get the balances to be used for comparison + uint256 contractBalance = getNativeUnwrappedBalance(address(feeManager)); + uint256 adminBalance = getNativeUnwrappedBalance(ADMIN); + + //the amount to withdraw + uint256 withdrawAmount = contractBalance / 2; + + //withdraw some balance + withdraw(NATIVE_WITHDRAW_ADDRESS, withdrawAmount, ADMIN); + + //check the balance has been reduced + uint256 newContractBalance = getNativeUnwrappedBalance(address(feeManager)); + uint256 newAdminBalance = getNativeUnwrappedBalance(ADMIN); + + //check the balance is greater than zero + assertGt(newContractBalance, 0); + //check the balance has been reduced by the correct amount + assertEq(newContractBalance, contractBalance - withdrawAmount); + //check the admin balance has increased by the correct amount + assertEq(newAdminBalance, adminBalance + withdrawAmount); + } + + function test_WithdrawNonAdminAddr() public { + //simulate a fee + mintLink(address(feeManager), DEFAULT_LINK_MINT_QUANTITY); + + //should revert if not admin + vm.expectRevert(ONLY_CALLABLE_BY_OWNER_ERROR); + + //withdraw some balance + withdraw(getLinkAddress(), DEFAULT_LINK_MINT_QUANTITY, USER); + } + + function test_eventIsEmittedAfterSurchargeIsSet() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //expect an emit + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit NativeSurchargeUpdated(nativeSurcharge); + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + } + + function test_subscriberDiscountEventIsEmittedOnUpdate() public { + //native surcharge + uint256 discount = FEE_SCALAR / 3; + + //an event should be emitted + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit SubscriberDiscountUpdated(USER, DEFAULT_FEED_1_V3, getNativeAddress(), discount); + + //set the surcharge + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), discount, ADMIN); + } + + function test_eventIsEmittedUponWithdraw() public { + //simulate a fee + mintLink(address(feeManager), DEFAULT_LINK_MINT_QUANTITY); + + //the amount to withdraw + uint256 withdrawAmount = 1; + + //expect an emit + vm.expectEmit(); + + //the event to be emitted + emit Withdraw(ADMIN, getLinkAddress(), withdrawAmount); + + //withdraw some balance + withdraw(getLinkAddress(), withdrawAmount, ADMIN); + } + + function test_linkAvailableForPaymentReturnsLinkBalance() public { + //simulate a deposit of link for the conversion pool + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //check there's a balance + assertGt(getLinkBalance(address(feeManager)), 0); + + //check the link available for payment is the link balance + assertEq(feeManager.linkAvailableForPayment(), getLinkBalance(address(feeManager))); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.getFeeAndReward.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.getFeeAndReward.t.sol new file mode 100644 index 00000000000..0baf8dee084 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.getFeeAndReward.t.sol @@ -0,0 +1,569 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {Test} from "forge-std/Test.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; +import {IFeeManager} from "../../dev/interfaces/IFeeManager.sol"; +import {Common} from "../../../libraries/Common.sol"; +import "./BaseFeeManager.t.sol"; + +/** + * @title BaseFeeManagerTest + * @author Michael Fletcher + * @notice This contract will test the functionality of the feeManager's getFeeAndReward + */ +contract FeeManagerProcessFeeTest is BaseFeeManagerTest { + function test_baseFeeIsAppliedForNative() public { + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be the default + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE); + } + + function test_baseFeeIsAppliedForLink() public { + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //fee should be the default + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_discountAIsNotAppliedWhenSetForOtherUsers() public { + //set the subscriber discount for another user + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), INVALID_ADDRESS); + + //fee should be the default + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE); + } + + function test_discountIsNotAppliedForInvalidTokenAddress() public { + //should revert with invalid address as it's not a configured token + vm.expectRevert(INVALID_ADDRESS_ERROR); + + //set the subscriber discount for another user + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, INVALID_ADDRESS, FEE_SCALAR / 2, ADMIN); + } + + function test_discountIsAppliedForLink() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //fee should be half the default + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE / 2); + } + + function test_DiscountIsAppliedForNative() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be half the default + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE / 2); + } + + function test_discountIsNoLongerAppliedAfterRemoving() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //fee should be half the default + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE / 2); + + //remove the discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), 0, ADMIN); + + //get the fee required by the feeManager + fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //fee should be the default + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_surchargeIsApplied() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected surcharge + uint256 expectedSurcharge = ((DEFAULT_REPORT_NATIVE_FEE * nativeSurcharge) / FEE_SCALAR); + + //expected fee should the base fee offset by the surcharge and discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge); + } + + function test_surchargeIsNotAppliedForLinkFee() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //fee should be the default + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_surchargeIsNoLongerAppliedAfterRemoving() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected surcharge + uint256 expectedSurcharge = ((DEFAULT_REPORT_NATIVE_FEE * nativeSurcharge) / FEE_SCALAR); + + //expected fee should be the base fee offset by the surcharge and discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge); + + //remove the surcharge + setNativeSurcharge(0, ADMIN); + + //get the fee required by the feeManager + fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be the default + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE); + } + + function test_feeIsUpdatedAfterNewSurchargeIsApplied() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected surcharge + uint256 expectedSurcharge = ((DEFAULT_REPORT_NATIVE_FEE * nativeSurcharge) / FEE_SCALAR); + + //expected fee should the base fee offset by the surcharge and discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge); + + //change the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected surcharge + expectedSurcharge = ((DEFAULT_REPORT_NATIVE_FEE * nativeSurcharge) / FEE_SCALAR); + + //expected fee should the base fee offset by the surcharge and discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge); + } + + function test_surchargeIsAppliedForNativeFeeWithDiscount() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected surcharge quantity + uint256 expectedSurcharge = ((DEFAULT_REPORT_NATIVE_FEE * nativeSurcharge) / FEE_SCALAR); + + //calculate the expected discount quantity + uint256 expectedDiscount = ((DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge) / 2); + + //expected fee should the base fee offset by the surcharge and discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge - expectedDiscount); + } + + function test_emptyQuoteRevertsWithError() public { + //expect a revert + vm.expectRevert(INVALID_QUOTE_ERROR); + + //get the fee required by the feeManager + getFee(getV2Report(DEFAULT_FEED_1_V3), IFeeManager.Quote(address(0)), USER); + } + + function test_nativeSurcharge100Percent() public { + //set the surcharge + setNativeSurcharge(FEE_SCALAR, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be twice the base fee + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE * 2); + } + + function test_nativeSurcharge0Percent() public { + //set the surcharge + setNativeSurcharge(0, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should base fee + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE); + } + + function test_nativeSurchargeCannotExceed100Percent() public { + //should revert if surcharge is greater than 100% + vm.expectRevert(INVALID_SURCHARGE_ERROR); + + //set the surcharge above the max + setNativeSurcharge(FEE_SCALAR + 1, ADMIN); + } + + function test_discountIsAppliedWith100PercentSurcharge() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //set the surcharge + setNativeSurcharge(FEE_SCALAR, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected discount quantity + uint256 expectedDiscount = DEFAULT_REPORT_NATIVE_FEE; + + //fee should be twice the surcharge minus the discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE * 2 - expectedDiscount); + } + + function test_feeIsZeroWith100PercentDiscount() public { + //set the subscriber discount to 100% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be zero + assertEq(fee.amount, 0); + } + + function test_feeIsUpdatedAfterDiscountIsRemoved() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected discount quantity + uint256 expectedDiscount = DEFAULT_REPORT_NATIVE_FEE / 2; + + //fee should be 50% of the base fee + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE - expectedDiscount); + + //remove the discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), 0, ADMIN); + + //get the fee required by the feeManager + fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be the base fee + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE); + } + + function test_feeIsUpdatedAfterNewDiscountIsApplied() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected discount quantity + uint256 expectedDiscount = DEFAULT_REPORT_NATIVE_FEE / 2; + + //fee should be 50% of the base fee + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE - expectedDiscount); + + //change the discount to 25% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 4, ADMIN); + + //get the fee required by the feeManager + fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //expected discount is now 25% + expectedDiscount = DEFAULT_REPORT_NATIVE_FEE / 4; + + //fee should be the base fee minus the expected discount + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE - expectedDiscount); + } + + function test_setDiscountOver100Percent() public { + //should revert with invalid discount + vm.expectRevert(INVALID_DISCOUNT_ERROR); + + //set the subscriber discount to over 100% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR + 1, ADMIN); + } + + function test_surchargeIsNotAppliedWith100PercentDiscount() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 5; + + //set the subscriber discount to 100% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR, ADMIN); + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //fee should be zero + assertEq(fee.amount, 0); + } + + function test_nonAdminUserCanNotSetDiscount() public { + //should revert with unauthorized + vm.expectRevert(ONLY_CALLABLE_BY_OWNER_ERROR); + + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR, USER); + } + + function test_surchargeFeeRoundsUpWhenUneven() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 3; + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected surcharge quantity + uint256 expectedSurcharge = (DEFAULT_REPORT_NATIVE_FEE * nativeSurcharge) / FEE_SCALAR; + + //expected fee should the base fee offset by the expected surcharge + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE + expectedSurcharge + 1); + } + + function test_discountFeeRoundsDownWhenUneven() public { + //native surcharge + uint256 discount = FEE_SCALAR / 3; + + //set the subscriber discount to 33.333% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), discount, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected quantity + uint256 expectedDiscount = ((DEFAULT_REPORT_NATIVE_FEE * discount) / FEE_SCALAR); + + //expected fee should the base fee offset by the expected surcharge + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE - expectedDiscount); + } + + function test_reportWithNoExpiryOrFeeReturnsZero() public { + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV0Report(DEFAULT_FEED_1_V1), getNativeQuote(), USER); + + //fee should be zero + assertEq(fee.amount, 0); + } + + function test_correctDiscountIsAppliedWhenBothTokensAreDiscounted() public { + //set the subscriber and native discounts + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 4, ADMIN); + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager for both tokens + Common.Asset memory linkFee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + Common.Asset memory nativeFee = getFee(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //calculate the expected discount quantity for each token + uint256 expectedDiscountLink = (DEFAULT_REPORT_LINK_FEE * FEE_SCALAR) / 4 / FEE_SCALAR; + uint256 expectedDiscountNative = (DEFAULT_REPORT_NATIVE_FEE * FEE_SCALAR) / 2 / FEE_SCALAR; + + //check the fee calculation for each token + assertEq(linkFee.amount, DEFAULT_REPORT_LINK_FEE - expectedDiscountLink); + assertEq(nativeFee.amount, DEFAULT_REPORT_NATIVE_FEE - expectedDiscountNative); + } + + function test_discountIsNotAppliedToOtherFeeds() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_2_V3), getNativeQuote(), USER); + + //fee should be the base fee + assertEq(fee.amount, DEFAULT_REPORT_NATIVE_FEE); + } + + function test_noFeeIsAppliedWhenReportHasZeroFee() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee( + getV2ReportWithCustomExpiryAndFee(DEFAULT_FEED_1_V3, uint32(block.timestamp), 0, 0), + getNativeQuote(), + USER + ); + + //fee should be zero + assertEq(fee.amount, 0); + } + + function test_noFeeIsAppliedWhenReportHasZeroFeeAndDiscountAndSurchargeIsSet() public { + //set the subscriber discount to 50% + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getNativeAddress(), FEE_SCALAR / 2, ADMIN); + + //set the surcharge + setNativeSurcharge(FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee( + getV2ReportWithCustomExpiryAndFee(DEFAULT_FEED_1_V3, uint32(block.timestamp), 0, 0), + getNativeQuote(), + USER + ); + + //fee should be zero + assertEq(fee.amount, 0); + } + + function test_nativeSurchargeEventIsEmittedOnUpdate() public { + //native surcharge + uint256 nativeSurcharge = FEE_SCALAR / 3; + + //an event should be emitted + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit NativeSurchargeUpdated(nativeSurcharge); + + //set the surcharge + setNativeSurcharge(nativeSurcharge, ADMIN); + } + + function test_getBaseRewardWithLinkQuote() public { + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //the reward should equal the base fee + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_getRewardWithLinkQuoteAndLinkDiscount() public { + //set the link discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //the reward should equal the discounted base fee + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE / 2); + } + + function test_getRewardWithNativeQuote() public { + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //the reward should equal the base fee in link + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_getRewardWithNativeQuoteAndSurcharge() public { + //set the native surcharge + setNativeSurcharge(FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //the reward should equal the base fee in link regardless of the surcharge + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_getRewardWithLinkDiscount() public { + //set the link discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 2, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //the reward should equal the discounted base fee + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE / 2); + } + + function test_getLinkFeeIsRoundedUp() public { + //set the link discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 3, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getFee(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //the reward should equal .66% + 1 of the base fee due to a 33% discount rounded up + assertEq(fee.amount, (DEFAULT_REPORT_LINK_FEE * 2) / 3 + 1); + } + + function test_getLinkRewardIsRoundedDown() public { + //set the link discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 3, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getLinkQuote(), USER); + + //the reward should equal .66% of the base fee due to a 33% discount rounded down + assertEq(fee.amount, (DEFAULT_REPORT_LINK_FEE * 2) / 3); + } + + function test_getLinkRewardWithNativeQuoteAndSurchargeWithLinkDiscount() public { + //set the native surcharge + setNativeSurcharge(FEE_SCALAR / 2, ADMIN); + + //set the link discount + setSubscriberDiscount(USER, DEFAULT_FEED_1_V3, getLinkAddress(), FEE_SCALAR / 3, ADMIN); + + //get the fee required by the feeManager + Common.Asset memory fee = getReward(getV2Report(DEFAULT_FEED_1_V3), getNativeQuote(), USER); + + //the reward should equal the base fee in link regardless of the surcharge + assertEq(fee.amount, DEFAULT_REPORT_LINK_FEE); + } + + function test_testRevertIfReportHasExpired() public { + //expect a revert + vm.expectRevert(EXPIRED_REPORT_ERROR); + + //get the fee required by the feeManager + getFee( + getV2ReportWithCustomExpiryAndFee( + DEFAULT_FEED_1_V3, + block.timestamp - 1, + DEFAULT_REPORT_LINK_FEE, + DEFAULT_REPORT_NATIVE_FEE + ), + getNativeQuote(), + USER + ); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol new file mode 100644 index 00000000000..bf7db55e4ce --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol @@ -0,0 +1,330 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {Test} from "forge-std/Test.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; +import {Common} from "../../../libraries/Common.sol"; +import "./BaseFeeManager.t.sol"; + +/** + * @title BaseFeeManagerTest + * @author Michael Fletcher + * @notice This contract will test the functionality of the feeManager processFee + */ +contract FeeManagerProcessFeeTest is BaseFeeManagerTest { + function setUp() public override { + super.setUp(); + } + + function test_nonAdminProxyUserCannotProcessFee() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getLinkAddress())); + + //should revert as the user is not the owner + vm.expectRevert(UNAUTHORIZED_ERROR); + + //process the fee + processFee(payload, USER, 0, USER); + } + + function test_processFeeAsProxy() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getLinkAddress())); + + //approve the link to be transferred from the from the subscriber to the rewardManager + approveLink(address(rewardManager), DEFAULT_REPORT_LINK_FEE, USER); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, PROXY); + + //check the link has been transferred + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //check the user has had the link fee deducted + assertEq(getLinkBalance(USER), DEFAULT_LINK_MINT_QUANTITY - DEFAULT_REPORT_LINK_FEE); + } + + function test_processFeeIfSubscriberIsSelf() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getLinkAddress())); + + //expect a revert due to funds being unapproved + vm.expectRevert(INVALID_ADDRESS_ERROR); + + //process the fee will attempt to transfer link from the contract to the rewardManager, which won't be approved + processFee(payload, address(feeManager), 0, ADMIN); + } + + function test_processFeeWithWithEmptyQuotePayload() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), bytes("")); + + //expect a revert as the quote is invalid + vm.expectRevert(); + + //processing the fee will transfer the link by default + processFee(payload, USER, 0, ADMIN); + } + + function test_processFeeWithWithZeroQuotePayload() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(INVALID_ADDRESS)); + + //expect a revert as the quote is invalid + vm.expectRevert(INVALID_QUOTE_ERROR); + + //processing the fee will transfer the link by default + processFee(payload, USER, 0, ADMIN); + } + + function test_processFeeWithWithCorruptQuotePayload() public { + //get the default payload + bytes memory payload = abi.encode( + [DEFAULT_CONFIG_DIGEST, 0, 0], + getV2Report(DEFAULT_FEED_1_V3), + new bytes32[](1), + new bytes32[](1), + bytes32("") + ); + + //expect an evm revert as the quote is corrupt + vm.expectRevert(); + + //processing the fee will not withdraw anything as there is no fee to collect + processFee(payload, USER, 0, ADMIN); + } + + function test_processFeeDefaultReportsStillVerifiesWithEmptyQuote() public { + //get the default payload + bytes memory payload = getPayload(getV0Report(DEFAULT_FEED_1_V1), bytes("")); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, PROXY); + } + + function test_processFeeWithDefaultReportPayloadAndQuoteStillVerifies() public { + //get the default payload + bytes memory payload = getPayload(getV0Report(DEFAULT_FEED_1_V1), getQuotePayload(getLinkAddress())); + + //processing the fee will not withdraw anything as there is no fee to collect + processFee(payload, USER, 0, ADMIN); + } + + function test_processFeeNative() public { + //simulate a deposit of link for the conversion pool + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + //approve the native to be transferred from the user + approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE, USER); + + //processing the fee will transfer the native from the user to the feeManager + processFee(payload, USER, 0, ADMIN); + + //check the native has been transferred + assertEq(getNativeBalance(address(feeManager)), DEFAULT_REPORT_NATIVE_FEE); + + //check the link has been transferred to the rewardManager + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //check the feeManager has had the link deducted, the remaining balance should be 0 + assertEq(getLinkBalance(address(feeManager)), 0); + + //check the subscriber has had the native deducted + assertEq(getNativeBalance(USER), DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + } + + function test_processFeeEmitsEventIfNotEnoughLink() public { + //simulate a deposit of half the link required for the fee + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE / 2); + + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + //approve the native to be transferred from the user + approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE, USER); + + //expect an emit as there's not enough link + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit InsufficientLink(DEFAULT_CONFIG_DIGEST, DEFAULT_REPORT_LINK_FEE, DEFAULT_REPORT_NATIVE_FEE); + + //processing the fee will transfer the native from the user to the feeManager + processFee(payload, USER, 0, ADMIN); + + //check the native has been transferred + assertEq(getNativeBalance(address(feeManager)), DEFAULT_REPORT_NATIVE_FEE); + + //check no link has been transferred to the rewardManager + assertEq(getLinkBalance(address(rewardManager)), 0); + assertEq(getLinkBalance(address(feeManager)), DEFAULT_REPORT_LINK_FEE / 2); + + //check the subscriber has had the native deducted + assertEq(getNativeBalance(USER), DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + } + + function test_processFeeWithUnwrappedNative() public { + //simulate a deposit of link for the conversion pool + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + //only the proxy or admin can call processFee, they will pass in the native value on the users behalf + processFee(payload, USER, DEFAULT_REPORT_NATIVE_FEE, PROXY); + + //check the native has been transferred and converted to wrapped native + assertEq(getNativeBalance(address(feeManager)), DEFAULT_REPORT_NATIVE_FEE); + assertEq(getNativeUnwrappedBalance(address(feeManager)), 0); + + //check the link has been transferred to the rewardManager + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //check the feeManager has had the link deducted, the remaining balance should be 0 + assertEq(getLinkBalance(address(feeManager)), 0); + + //check the subscriber has had the native deducted + assertEq(getNativeUnwrappedBalance(PROXY), DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + } + + function test_processFeeWithUnwrappedNativeShortFunds() public { + //simulate a deposit of link for the conversion pool + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + //expect a revert as not enough funds + vm.expectRevert(INVALID_DEPOSIT_ERROR); + + //only the proxy or admin can call processFee, they will pass in the native value on the users behalf + processFee(payload, USER, DEFAULT_REPORT_NATIVE_FEE - 1, PROXY); + } + + function test_processFeeWithUnwrappedNativeLinkAddress() public { + //simulate a deposit of link for the conversion pool + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getLinkAddress())); + + //expect a revert as not enough funds + vm.expectRevert(INVALID_DEPOSIT_ERROR); + + //only the proxy or admin can call processFee, they will pass in the native value on the users behalf + processFee(payload, USER, DEFAULT_REPORT_NATIVE_FEE - 1, PROXY); + } + + function test_processFeeWithUnwrappedNativeWithExcessiveFee() public { + //simulate a deposit of link for the conversion pool + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + //call processFee from the proxy to test whether the funds are returned to the subscriber. In reality, the funds would be returned to the caller of the proxy. + processFee(payload, PROXY, DEFAULT_REPORT_NATIVE_FEE * 2, PROXY); + + //check the native has been transferred and converted to wrapped native + assertEq(getNativeBalance(address(feeManager)), DEFAULT_REPORT_NATIVE_FEE); + assertEq(getNativeUnwrappedBalance(address(feeManager)), 0); + + //check the link has been transferred to the rewardManager + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //check the feeManager has had the link deducted, the remaining balance should be 0 + assertEq(getLinkBalance(address(feeManager)), 0); + + //check the subscriber has had the native deducted + assertEq(getNativeUnwrappedBalance(PROXY), DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + } + + function test_processFeeUsesCorrectDigest() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getLinkAddress())); + + //approve the link to be transferred from the from the subscriber to the rewardManager + approveLink(address(rewardManager), DEFAULT_REPORT_LINK_FEE, USER); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, PROXY); + + //check the link has been transferred + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //check the user has had the link fee deducted + assertEq(getLinkBalance(USER), DEFAULT_LINK_MINT_QUANTITY - DEFAULT_REPORT_LINK_FEE); + + //check funds have been paid to the reward manager + assertEq(rewardManager.s_totalRewardRecipientFees(DEFAULT_CONFIG_DIGEST), DEFAULT_REPORT_LINK_FEE); + } + + function test_V1PayloadVerifies() public { + //replicate a default payload + bytes memory payload = abi.encode( + [DEFAULT_CONFIG_DIGEST, 0, 0], + getV1Report(DEFAULT_FEED_1_V1), + new bytes32[](1), + new bytes32[](1), + bytes32("") + ); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, PROXY); + } + + function test_V2PayloadVerifies() public { + //get the default payload + bytes memory payload = getPayload(getV1Report(DEFAULT_FEED_1_V2), getQuotePayload(getLinkAddress())); + + //approve the link to be transferred from the from the subscriber to the rewardManager + approveLink(address(rewardManager), DEFAULT_REPORT_LINK_FEE, USER); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, ADMIN); + + //check the link has been transferred + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //check the user has had the link fee deducted + assertEq(getLinkBalance(USER), DEFAULT_LINK_MINT_QUANTITY - DEFAULT_REPORT_LINK_FEE); + } + + function test_V2PayloadWithoutQuoteFails() public { + //get the default payload + bytes memory payload = getPayload(getV1Report(DEFAULT_FEED_1_V2), bytes("")); + + //expect a revert as the quote is invalid + vm.expectRevert(); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, ADMIN); + } + + function test_V2PayloadWithoutZeroFee() public { + //get the default payload + bytes memory payload = getPayload(getV1Report(DEFAULT_FEED_1_V2), getQuotePayload(getLinkAddress())); + + //expect a revert as the quote is invalid + vm.expectRevert(); + + //processing the fee will transfer the link from the user to the rewardManager + processFee(payload, USER, 0, ADMIN); + } + + function test_processFeeWithInvalidReportVersion() public { + bytes memory data = abi.encode(0x0000100000000000000000000000000000000000000000000000000000000000); + + //get the default payload + bytes memory payload = getPayload(data, getQuotePayload(getLinkAddress())); + + //version is invalid as feedId is 0 + vm.expectRevert(INVALID_REPORT_VERSION_ERROR); + + //processing the fee will not withdraw anything as there is no fee to collect + processFee(payload, USER, 0, ADMIN); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/gas/Gas_VerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/gas/Gas_VerifierTest.t.sol index 48e8689e6e4..e3764fce0a6 100644 --- a/contracts/src/v0.8/llo-feeds/test/gas/Gas_VerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/gas/Gas_VerifierTest.t.sol @@ -1,9 +1,10 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTest, BaseTestWithConfiguredVerifier} from "../BaseVerifierTest.t.sol"; +import {BaseTest, BaseTestWithConfiguredVerifierAndFeeManager} from "../verifier/BaseVerifierTest.t.sol"; import {Verifier} from "../../Verifier.sol"; import {SimpleWriteAccessController} from "../../../SimpleWriteAccessController.sol"; +import {Common} from "../../../libraries/Common.sol"; contract Verifier_setConfig is BaseTest { address[] internal s_signerAddrs; @@ -23,18 +24,76 @@ contract Verifier_setConfig is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } } -contract Verifier_verify is BaseTestWithConfiguredVerifier { +contract Verifier_verifyWithFee is BaseTestWithConfiguredVerifierAndFeeManager { + uint256 internal constant DEFAULT_LINK_MINT_QUANTITY = 100 ether; + uint256 internal constant DEFAULT_NATIVE_MINT_QUANTITY = 100 ether; + + function setUp() public virtual override { + super.setUp(); + + //mint some link and eth to warm the storage + link.mint(address(rewardManager), DEFAULT_LINK_MINT_QUANTITY); + native.mint(address(feeManager), DEFAULT_NATIVE_MINT_QUANTITY); + + //warm the rewardManager + link.mint(address(this), DEFAULT_NATIVE_MINT_QUANTITY); + _approveLink(address(rewardManager), DEFAULT_REPORT_LINK_FEE, address(this)); + (, , bytes32 latestConfigDigest) = s_verifier.latestConfigDetails(FEED_ID); + + //mint some tokens to the user + link.mint(USER, DEFAULT_LINK_MINT_QUANTITY); + native.mint(USER, DEFAULT_NATIVE_MINT_QUANTITY); + vm.deal(USER, DEFAULT_NATIVE_MINT_QUANTITY); + + //mint some link tokens to the feeManager pool + link.mint(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + //approve funds prior to test + _approveLink(address(rewardManager), DEFAULT_REPORT_LINK_FEE, USER); + _approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE, USER); + + changePrank(address(feeManager)); + rewardManager.onFeePaid(latestConfigDigest, address(this), DEFAULT_REPORT_LINK_FEE); + + changePrank(USER); + } + + function testVerifyProxyWithLinkFeeSuccess_gas() public { + bytes memory signedLinkPayload = _generateEncodedBlobWithQuote( + _generateV2Report(), + _generateReportContext(FEED_ID_V3), + _getSigners(FAULT_TOLERANCE + 1), + _generateQuote(address(link)) + ); + + s_verifierProxy.verify(signedLinkPayload); + } + + function testVerifyProxyWithNativeFeeSuccess_gas() public { + bytes memory signedNativePayload = _generateEncodedBlobWithQuote( + _generateV2Report(), + _generateReportContext(FEED_ID_V3), + _getSigners(FAULT_TOLERANCE + 1), + _generateQuote(address(native)) + ); + + s_verifierProxy.verify(signedNativePayload); + } +} + +contract Verifier_verify is BaseTestWithConfiguredVerifierAndFeeManager { bytes internal s_signedReport; bytes32 internal s_configDigest; function setUp() public override { - BaseTestWithConfiguredVerifier.setUp(); - BaseTest.Report memory s_testReportOne = _createReport( + BaseTestWithConfiguredVerifierAndFeeManager.setUp(); + BaseTest.V0Report memory s_testReportOne = _createV0Report( FEED_ID, OBSERVATIONS_TIMESTAMP, MEDIAN, @@ -42,7 +101,8 @@ contract Verifier_verify is BaseTestWithConfiguredVerifier { ASK, BLOCKNUMBER_UPPER_BOUND, blockhash(BLOCKNUMBER_UPPER_BOUND), - BLOCKNUMBER_LOWER_BOUND + BLOCKNUMBER_LOWER_BOUND, + uint32(block.timestamp) ); (, , s_configDigest) = s_verifier.latestConfigDetails(FEED_ID); bytes32[3] memory reportContext; @@ -53,6 +113,7 @@ contract Verifier_verify is BaseTestWithConfiguredVerifier { function testVerifySuccess_gas() public { changePrank(address(s_verifierProxy)); + s_verifier.verify(s_signedReport, msg.sender); } @@ -61,7 +122,7 @@ contract Verifier_verify is BaseTestWithConfiguredVerifier { } } -contract Verifier_accessControlledVerify is BaseTestWithConfiguredVerifier { +contract Verifier_accessControlledVerify is BaseTestWithConfiguredVerifierAndFeeManager { bytes internal s_signedReport; bytes32 internal s_configDigest; SimpleWriteAccessController s_accessController; @@ -70,8 +131,8 @@ contract Verifier_accessControlledVerify is BaseTestWithConfiguredVerifier { address internal constant ACCESS_CONTROLLER_ADDR = address(10000); function setUp() public override { - BaseTestWithConfiguredVerifier.setUp(); - BaseTest.Report memory s_testReportOne = _createReport( + BaseTestWithConfiguredVerifierAndFeeManager.setUp(); + BaseTest.V0Report memory s_testReportOne = _createV0Report( FEED_ID, OBSERVATIONS_TIMESTAMP, MEDIAN, @@ -79,7 +140,8 @@ contract Verifier_accessControlledVerify is BaseTestWithConfiguredVerifier { ASK, BLOCKNUMBER_UPPER_BOUND, blockhash(BLOCKNUMBER_UPPER_BOUND), - BLOCKNUMBER_LOWER_BOUND + BLOCKNUMBER_LOWER_BOUND, + uint32(block.timestamp) ); (, , s_configDigest) = s_verifier.latestConfigDetails(FEED_ID); bytes32[3] memory reportContext; diff --git a/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol b/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol index e58421415b8..13e46f0202b 100644 --- a/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol +++ b/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol @@ -2,13 +2,30 @@ pragma solidity 0.8.16; import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {Common} from "../../../libraries/Common.sol"; contract ErroredVerifier is IVerifier { function supportsInterface(bytes4 interfaceId) public pure override returns (bool) { return interfaceId == this.verify.selector; } - function verify(bytes memory /**signedReport**/, address /**sender**/) external pure override returns (bytes memory) { + function verify( + bytes memory, + /** + * signedReport* + */ + address + ) + external + pure + override + returns ( + /** + * sender* + */ + bytes memory + ) + { revert("Failed to verify"); } @@ -19,11 +36,28 @@ contract ErroredVerifier is IVerifier { uint8, bytes memory, uint64, - bytes memory + bytes memory, + Common.AddressAndWeight[] memory ) external pure override { revert("Failed to set config"); } + function activateConfig(bytes32, bytes32) external pure { + revert("Failed to activate config"); + } + + function deactivateConfig(bytes32, bytes32) external pure { + revert("Failed to deactivate config"); + } + + function activateFeed(bytes32) external pure { + revert("Failed to activate feed"); + } + + function deactivateFeed(bytes32) external pure { + revert("Failed to deactivate feed"); + } + function latestConfigDigestAndEpoch(bytes32) external pure override returns (bool, bytes32, uint32) { revert("Failed to get latest config digest and epoch"); } diff --git a/contracts/src/v0.8/llo-feeds/test/reward-manager/BaseRewardManager.t.sol b/contracts/src/v0.8/llo-feeds/test/reward-manager/BaseRewardManager.t.sol new file mode 100644 index 00000000000..7d7aa6aac38 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/reward-manager/BaseRewardManager.t.sol @@ -0,0 +1,248 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {Test} from "forge-std/Test.sol"; +import {ERC20Mock} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol"; +import {RewardManager} from "../../dev/RewardManager.sol"; +import {Common} from "../../../libraries/Common.sol"; + +/** + * @title BaseRewardManagerTest + * @author Michael Fletcher + * @notice Base class for all reward manager tests + * @dev This contract is intended to be inherited from and not used directly. It contains functionality to setup a primary and secondary pool + */ +contract BaseRewardManagerTest is Test { + //contracts + ERC20Mock internal asset; + ERC20Mock internal unsupported; + RewardManager internal rewardManager; + + //default address for unregistered recipient + address internal constant INVALID_ADDRESS = address(0); + //contract owner + address internal constant ADMIN = address(uint160(uint256(keccak256("ADMIN")))); + //address to represent verifier contract + address internal constant FEE_MANAGER = address(uint160(uint256(keccak256("FEE_MANAGER")))); + //a general user + address internal constant USER = address(uint160(uint256(keccak256("USER")))); + + //default recipients configured in reward manager + address internal constant DEFAULT_RECIPIENT_1 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_1")))); + address internal constant DEFAULT_RECIPIENT_2 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_2")))); + address internal constant DEFAULT_RECIPIENT_3 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_3")))); + address internal constant DEFAULT_RECIPIENT_4 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_4")))); + address internal constant DEFAULT_RECIPIENT_5 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_5")))); + address internal constant DEFAULT_RECIPIENT_6 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_6")))); + address internal constant DEFAULT_RECIPIENT_7 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_7")))); + + //additional recipients not in the reward manager + address internal constant DEFAULT_RECIPIENT_8 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_8")))); + address internal constant DEFAULT_RECIPIENT_9 = address(uint160(uint256(keccak256("DEFAULT_RECIPIENT_9")))); + + //two pools should be enough to test all edge cases + bytes32 internal constant PRIMARY_POOL_ID = keccak256("primary_pool"); + bytes32 internal constant SECONDARY_POOL_ID = keccak256("secondary_pool"); + bytes32 internal constant INVALID_POOL_ID = keccak256("invalid_pool"); + bytes32 internal constant ZERO_POOL_ID = bytes32(0); + + //convenience arrays of all pool combinations used for testing + bytes32[] internal PRIMARY_POOL_ARRAY = [PRIMARY_POOL_ID]; + bytes32[] internal SECONDARY_POOL_ARRAY = [SECONDARY_POOL_ID]; + bytes32[] internal ALL_POOLS = [PRIMARY_POOL_ID, SECONDARY_POOL_ID]; + + //erc20 config + uint256 internal constant DEFAULT_MINT_QUANTITY = 100 ether; + + //reward scalar (this should match the const in the contract) + uint256 internal constant POOL_SCALAR = 1e18; + uint256 internal constant ONE_PERCENT = POOL_SCALAR / 100; + uint256 internal constant FIFTY_PERCENT = POOL_SCALAR / 2; + uint256 internal constant TEN_PERCENT = POOL_SCALAR / 10; + + //the selector for each error + bytes4 internal immutable UNAUTHORIZED_ERROR_SELECTOR = RewardManager.Unauthorized.selector; + bytes4 internal immutable INVALID_ADDRESS_ERROR_SELECTOR = RewardManager.InvalidAddress.selector; + bytes4 internal immutable INVALID_WEIGHT_ERROR_SELECTOR = RewardManager.InvalidWeights.selector; + bytes4 internal immutable INVALID_POOL_ID_ERROR_SELECTOR = RewardManager.InvalidPoolId.selector; + bytes internal constant ONLY_CALLABLE_BY_OWNER_ERROR = "Only callable by owner"; + + // Events emitted within the reward manager + event RewardRecipientsUpdated(bytes32 indexed poolId, Common.AddressAndWeight[] newRewardRecipients); + event RewardsClaimed(bytes32 indexed poolId, address indexed recipient, uint256 quantity); + event FeeManagerUpdated(address newProxyAddress); + event FeePaid(bytes32 poolId, address payee, uint256 quantity); + + function setUp() public virtual { + //change to admin user + vm.startPrank(ADMIN); + + //init required contracts + _initializeERC20Contracts(); + _initializeRewardManager(); + } + + function _initializeERC20Contracts() internal { + //create the contracts + asset = new ERC20Mock("ASSET", "AST", ADMIN, 0); + unsupported = new ERC20Mock("UNSUPPORTED", "UNS", ADMIN, 0); + + //mint some tokens to the admin + asset.mint(ADMIN, DEFAULT_MINT_QUANTITY); + unsupported.mint(ADMIN, DEFAULT_MINT_QUANTITY); + + //mint some tokens to the user + asset.mint(FEE_MANAGER, DEFAULT_MINT_QUANTITY); + unsupported.mint(FEE_MANAGER, DEFAULT_MINT_QUANTITY); + } + + function _initializeRewardManager() internal { + //create the contract + rewardManager = new RewardManager(address(asset)); + + rewardManager.setFeeManager(FEE_MANAGER); + } + + function createPrimaryPool() public { + rewardManager.setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients()); + } + + function createSecondaryPool() public { + rewardManager.setRewardRecipients(SECONDARY_POOL_ID, getSecondaryRecipients()); + } + + //override this to test variations of different recipients. changing this function will require existing tests to be updated as constants are hardcoded to be explicit + function getPrimaryRecipients() public virtual returns (Common.AddressAndWeight[] memory) { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + + //init each recipient with even weights. 2500 = 25% of pool + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, POOL_SCALAR / 4); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, POOL_SCALAR / 4); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, POOL_SCALAR / 4); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, POOL_SCALAR / 4); + + return recipients; + } + + function getPrimaryRecipientAddresses() public pure returns (address[] memory) { + //array of recipients + address[] memory recipients = new address[](4); + + recipients[0] = DEFAULT_RECIPIENT_1; + recipients[1] = DEFAULT_RECIPIENT_2; + recipients[2] = DEFAULT_RECIPIENT_3; + recipients[3] = DEFAULT_RECIPIENT_4; + + return recipients; + } + + //override this to test variations of different recipients. + function getSecondaryRecipients() public virtual returns (Common.AddressAndWeight[] memory) { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + + //init each recipient with even weights. 2500 = 25% of pool + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, POOL_SCALAR / 4); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, POOL_SCALAR / 4); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_6, POOL_SCALAR / 4); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_7, POOL_SCALAR / 4); + + return recipients; + } + + function getSecondaryRecipientAddresses() public pure returns (address[] memory) { + //array of recipients + address[] memory recipients = new address[](4); + + recipients[0] = DEFAULT_RECIPIENT_1; + recipients[1] = DEFAULT_RECIPIENT_5; + recipients[2] = DEFAULT_RECIPIENT_6; + recipients[3] = DEFAULT_RECIPIENT_7; + + return recipients; + } + + function addFundsToPool(bytes32 poolId, Common.Asset memory amount, address sender) public { + //record the current address and switch to the sender + address originalAddr = msg.sender; + changePrank(sender); + + //approve the amount being paid into the pool + ERC20Mock(amount.assetAddress).approve(address(rewardManager), amount.amount); + + //this represents the verifier adding some funds to the pool + rewardManager.onFeePaid(poolId, sender, amount.amount); + + //change back to the original address + changePrank(originalAddr); + } + + function getAsset(uint256 quantity) public view returns (Common.Asset memory) { + return Common.Asset(address(asset), quantity); + } + + function getAssetBalance(address addr) public view returns (uint256) { + return asset.balanceOf(addr); + } + + function claimRewards(bytes32[] memory poolIds, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //claim the rewards + rewardManager.claimRewards(poolIds); + + //change back to the original address + changePrank(originalAddr); + } + + function payRecipients(bytes32 poolId, address[] memory recipients, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //pay the recipients + rewardManager.payRecipients(poolId, recipients); + + //change back to the original address + changePrank(originalAddr); + } + + function setRewardRecipients(bytes32 poolId, Common.AddressAndWeight[] memory recipients, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //pay the recipients + rewardManager.setRewardRecipients(poolId, recipients); + + //change back to the original address + changePrank(originalAddr); + } + + function setFeeManager(address feeManager, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //update the proxy + rewardManager.setFeeManager(feeManager); + + //change back to the original address + changePrank(originalAddr); + } + + function updateRewardRecipients(bytes32 poolId, Common.AddressAndWeight[] memory recipients, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //pay the recipients + rewardManager.updateRewardRecipients(poolId, recipients); + + //change back to the original address + changePrank(originalAddr); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.claim.t.sol b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.claim.t.sol new file mode 100644 index 00000000000..358ffeee40c --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.claim.t.sol @@ -0,0 +1,740 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseRewardManagerTest} from "./BaseRewardManager.t.sol"; +import {Common} from "../../../libraries/Common.sol"; + +/** + * @title BaseRewardManagerTest + * @author Michael Fletcher + * @notice This contract will test the claim functionality of the RewardManager contract. + */ +contract RewardManagerClaimTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a single pool for these tests + createPrimaryPool(); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function test_claimAllRecipients() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + } + + function test_claimRewardsWithDuplicatPoolIdsDoesNotPayoutTwice() public { + //add funds to a different pool to ensure they're not claimed + addFundsToPool(SECONDARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //create an array containing duplicate poolIds + bytes32[] memory poolIds = new bytes32[](2); + poolIds[0] = PRIMARY_POOL_ID; + poolIds[1] = PRIMARY_POOL_ID; + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(poolIds, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //the pool should still have the remaining + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_claimSingleRecipient() public { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[0]; + + //claim the individual rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT - expectedRecipientAmount); + } + + function test_claimMultipleRecipients() public { + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, getPrimaryRecipients()[0].addr); + claimRewards(PRIMARY_POOL_ARRAY, getPrimaryRecipients()[1].addr); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received + assertEq(getAssetBalance(getPrimaryRecipients()[0].addr), expectedRecipientAmount); + assertEq(getAssetBalance(getPrimaryRecipients()[1].addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT - (expectedRecipientAmount * 2)); + } + + function test_claimUnregisteredRecipient() public { + //claim the rewards for a recipient who isn't in this pool + claimRewards(PRIMARY_POOL_ARRAY, getSecondaryRecipients()[1].addr); + + //check the recipients didn't receive any fees from this pool + assertEq(getAssetBalance(getSecondaryRecipients()[1].addr), 0); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_claimUnevenAmountRoundsDown() public { + //adding 1 to the pool should leave 1 wei worth of dust, which the contract doesn't handle due to it being economically infeasible + addFundsToPool(PRIMARY_POOL_ID, getAsset(1), FEE_MANAGER); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //check the rewardManager has the remaining quantity equals 1 wei + assertEq(getAssetBalance(address(rewardManager)), 1); + } + + function test_claimUnregisteredPoolId() public { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[0]; + + //claim the individual rewards for this recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //check the recipients balance is still 0 as there's no pool to receive fees from + assertEq(getAssetBalance(recipient.addr), 0); + + //check the rewardManager has the full amount + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_singleRecipientClaimMultipleDeposits() public { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[0]; + + //claim the individual rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity, which is 3/4 of the initial deposit + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT - expectedRecipientAmount); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //claim the individual rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the recipients balance matches the ratio the recipient should have received, which is 1/4 of each deposit + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount * 2); + + //check the rewardManager has the remaining quantity, which is now 3/4 of both deposits + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 2 - (expectedRecipientAmount * 2)); + } + + function test_recipientsClaimMultipleDeposits() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //the reward manager balance should be 0 as all of the funds have been claimed + assertEq(getAssetBalance(address(rewardManager)), 0); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //expected recipient amount is 1/4 of the pool deposit + expectedRecipientAmount = (POOL_DEPOSIT_AMOUNT / 4) * 2; + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //the reward manager balance should again be 0 as all of the funds have been claimed + assertEq(getAssetBalance(address(rewardManager)), 0); + } + + function test_eventIsEmittedUponClaim() public { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[0]; + + //expect an emit + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit RewardsClaimed(PRIMARY_POOL_ID, recipient.addr, POOL_DEPOSIT_AMOUNT / 4); + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + } + + function test_eventIsNotEmittedUponUnsuccessfulClaim() public { + //record logs to check no events were emitted + vm.recordLogs(); + + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[0]; + + //claim the individual rewards for each recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //no logs should have been emitted + assertEq(vm.getRecordedLogs().length, 0); + } +} + +contract RewardManagerRecipientClaimMultiplePoolsTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a two pools + createPrimaryPool(); + createSecondaryPool(); + + //add funds to each of the pools to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + addFundsToPool(SECONDARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function test_claimAllRecipientsSinglePool() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //check the pool balance is still equal to DEPOSIT_AMOUNT as the test only claims for one of the pools + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_claimMultipleRecipientsSinglePool() public { + //claim the individual rewards for each recipient + claimRewards(SECONDARY_POOL_ARRAY, getSecondaryRecipients()[0].addr); + claimRewards(SECONDARY_POOL_ARRAY, getSecondaryRecipients()[1].addr); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received + assertEq(getAssetBalance(getSecondaryRecipients()[0].addr), expectedRecipientAmount); + assertEq(getAssetBalance(getSecondaryRecipients()[1].addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 2 - (expectedRecipientAmount * 2)); + } + + function test_claimMultipleRecipientsMultiplePools() public { + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, getPrimaryRecipients()[0].addr); + claimRewards(PRIMARY_POOL_ARRAY, getPrimaryRecipients()[1].addr); + claimRewards(SECONDARY_POOL_ARRAY, getSecondaryRecipients()[0].addr); + claimRewards(SECONDARY_POOL_ARRAY, getSecondaryRecipients()[1].addr); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received. The first recipient is shared across both pools so should receive 1/4 of each pool + assertEq(getAssetBalance(getPrimaryRecipients()[0].addr), expectedRecipientAmount * 2); + assertEq(getAssetBalance(getPrimaryRecipients()[1].addr), expectedRecipientAmount); + assertEq(getAssetBalance(getSecondaryRecipients()[1].addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_claimAllRecipientsMultiplePools() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i = 1; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //claim funds for each recipient within the pool + for (uint256 i = 1; i < getSecondaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory secondaryRecipient = getSecondaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(SECONDARY_POOL_ARRAY, secondaryRecipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(secondaryRecipient.addr), expectedRecipientAmount); + } + + //special case to handle the first recipient of each pool as they're the same address + Common.AddressAndWeight memory commonRecipient = getPrimaryRecipients()[0]; + + //claim the individual rewards for each pool + claimRewards(PRIMARY_POOL_ARRAY, commonRecipient.addr); + claimRewards(SECONDARY_POOL_ARRAY, commonRecipient.addr); + + //check the balance matches the ratio the recipient should have received, which is 1/4 of each deposit for each pool + assertEq(getAssetBalance(commonRecipient.addr), expectedRecipientAmount * 2); + } + + function test_claimSingleUniqueRecipient() public { + //the first recipient of the secondary pool is in both pools, so take the second recipient which is unique + Common.AddressAndWeight memory recipient = getSecondaryRecipients()[1]; + + //claim the individual rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received 1/4 of the deposit amount + uint256 recipientExpectedAmount = POOL_DEPOSIT_AMOUNT / 4; + + //the recipient should have received 1/4 of the deposit amount + assertEq(getAssetBalance(recipient.addr), recipientExpectedAmount); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 2 - recipientExpectedAmount); + } + + function test_claimSingleRecipientMultiplePools() public { + //the first recipient of the secondary pool is in both pools + Common.AddressAndWeight memory recipient = getSecondaryRecipients()[0]; + + //claim the individual rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received 1/4 of the deposit amount for each pool + uint256 recipientExpectedAmount = (POOL_DEPOSIT_AMOUNT / 4) * 2; + + //this recipient belongs in both pools so should have received 1/4 of each + assertEq(getAssetBalance(recipient.addr), recipientExpectedAmount); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 2 - recipientExpectedAmount); + } + + function test_claimUnregisteredRecipient() public { + //claim the individual rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, getSecondaryRecipients()[1].addr); + claimRewards(SECONDARY_POOL_ARRAY, getPrimaryRecipients()[1].addr); + + //check the recipients didn't receive any fees from this pool + assertEq(getAssetBalance(getSecondaryRecipients()[1].addr), 0); + assertEq(getAssetBalance(getPrimaryRecipients()[1].addr), 0); + + //check the rewardManager has the remaining quantity + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 2); + } + + function test_claimUnevenAmountRoundsDown() public { + //adding an uneven amount of dust to each pool, this should round down to the nearest whole number with 4 remaining in the contract + addFundsToPool(PRIMARY_POOL_ID, getAsset(3), FEE_MANAGER); + addFundsToPool(SECONDARY_POOL_ID, getAsset(1), FEE_MANAGER); + + //the recipient should have received 1/4 of the deposit amount for each pool + uint256 recipientExpectedAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), recipientExpectedAmount); + } + + //special case to handle the first recipient of each pool as they're the same address + claimRewards(SECONDARY_POOL_ARRAY, getSecondaryRecipients()[0].addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(getSecondaryRecipients()[0].addr), recipientExpectedAmount * 2); + + //claim funds for each recipient of the secondary pool except the first + for (uint256 i = 1; i < getSecondaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getSecondaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), recipientExpectedAmount); + } + + //contract should have 4 remaining + assertEq(getAssetBalance(address(rewardManager)), 4); + } + + function test_singleRecipientClaimMultipleDeposits() public { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getSecondaryRecipients()[0]; + + //claim the individual rewards for this recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received 1/4 of the deposit amount + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity, which is 3/4 of the initial deposit plus the deposit from the second pool + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 2 - expectedRecipientAmount); + + //add funds to the pool to be split among the recipients + addFundsToPool(SECONDARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //claim the individual rewards for this recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received 1/4 of the next deposit amount + expectedRecipientAmount += POOL_DEPOSIT_AMOUNT / 4; + + //check the recipients balance matches the ratio the recipient should have received, which is 1/4 of each deposit + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + + //check the rewardManager has the remaining quantity, which is now 3/4 of both deposits + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT * 3 - expectedRecipientAmount); + } + + function test_recipientsClaimMultipleDeposits() public { + //the recipient should have received 1/4 of the deposit amount + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim funds for each recipient within the pool + for (uint256 i; i < getSecondaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getSecondaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //the reward manager balance should contain only the funds of the secondary pool + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + + //add funds to the pool to be split among the recipients + addFundsToPool(SECONDARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //special case to handle the first recipient of each pool as they're the same address + claimRewards(SECONDARY_POOL_ARRAY, getSecondaryRecipients()[0].addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(getSecondaryRecipients()[0].addr), expectedRecipientAmount * 2); + + //claim funds for each recipient within the pool except the first + for (uint256 i = 1; i < getSecondaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getSecondaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(SECONDARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount * 2); + } + + //the reward manager balance should again be the balance of the secondary pool as the primary pool has been emptied twice + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_claimEmptyPoolWhenSecondPoolContainsFunds() public { + //the recipient should have received 1/4 of the deposit amount + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //claim all rewards for each recipient in the primary pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //claim all the rewards again for the first recipient as that address is a member of both pools + claimRewards(PRIMARY_POOL_ARRAY, getSecondaryRecipients()[0].addr); + + //check the balance + assertEq(getAssetBalance(getSecondaryRecipients()[0].addr), expectedRecipientAmount); + } + + function test_getRewardsAvailableToRecipientInBothPools() public { + //get index 0 as this recipient is in both default pools + bytes32[] memory poolIds = rewardManager.getAvailableRewardPoolIds(getPrimaryRecipients()[0].addr); + + //check the recipient is in both pools + assertEq(poolIds[0], PRIMARY_POOL_ID); + assertEq(poolIds[1], SECONDARY_POOL_ID); + } + + function test_getRewardsAvailableToRecipientInSinglePool() public { + //get index 0 as this recipient is in both default pools + bytes32[] memory poolIds = rewardManager.getAvailableRewardPoolIds(getPrimaryRecipients()[1].addr); + + //check the recipient is in both pools + assertEq(poolIds[0], PRIMARY_POOL_ID); + assertEq(poolIds[1], ZERO_POOL_ID); + } + + function test_getRewardsAvailableToRecipientInNoPools() public { + //get index 0 as this recipient is in both default pools + bytes32[] memory poolIds = rewardManager.getAvailableRewardPoolIds(FEE_MANAGER); + + //check the recipient is in neither pool + assertEq(poolIds[0], ZERO_POOL_ID); + assertEq(poolIds[1], ZERO_POOL_ID); + } +} + +contract RewardManagerRecipientClaimDifferentWeightsTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a single pool for these tests + createPrimaryPool(); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function getPrimaryRecipients() public virtual override returns (Common.AddressAndWeight[] memory) { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + + //init each recipient with uneven weights + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, TEN_PERCENT); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, TEN_PERCENT * 8); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, ONE_PERCENT * 6); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, ONE_PERCENT * 4); + + return recipients; + } + + function test_allRecipientsClaimingReceiveExpectedAmount() public { + //loop all the recipients and claim their expected amount + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received a share proportional to their weight + uint256 expectedRecipientAmount = (POOL_DEPOSIT_AMOUNT * recipient.weight) / POOL_SCALAR; + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + } +} + +contract RewardManagerRecipientClaimUnevenWeightTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a single pool for these tests + createPrimaryPool(); + } + + function getPrimaryRecipients() public virtual override returns (Common.AddressAndWeight[] memory) { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](2); + + uint256 oneThird = POOL_SCALAR / 3; + + //init each recipient with even weights. + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, oneThird); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, 2 * oneThird + 1); + + return recipients; + } + + function test_allRecipientsClaimingReceiveExpectedAmountWithSmallDeposit() public { + //add a smaller amount of funds to the pool + uint256 smallDeposit = 1e8; + + //add a smaller amount of funds to the pool + addFundsToPool(PRIMARY_POOL_ID, getAsset(smallDeposit), FEE_MANAGER); + + //loop all the recipients and claim their expected amount + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received a share proportional to their weight + uint256 expectedRecipientAmount = (smallDeposit * recipient.weight) / POOL_SCALAR; + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //smaller deposits will consequently have less precision and will not be able to be split as evenly, the remaining 1 will be lost due to 333...|... being paid out instead of 333...4| + assertEq(getAssetBalance(address(rewardManager)), 1); + } + + function test_allRecipientsClaimingReceiveExpectedAmount() public { + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //loop all the recipients and claim their expected amount + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //claim the individual rewards for each recipient + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //the recipient should have received a share proportional to their weight + uint256 expectedRecipientAmount = (POOL_DEPOSIT_AMOUNT * recipient.weight) / POOL_SCALAR; + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + + //their should be 0 wei left over indicating a successful split + assertEq(getAssetBalance(address(rewardManager)), 0); + } +} + +contract RewardManagerNoRecipientSet is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //add funds to the pool to be split among the recipients once registered + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function test_claimAllRecipientsAfterRecipientsSet() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //try and claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //there should be no rewards claimed as the recipient is not registered + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the recipient received nothing + assertEq(getAssetBalance(recipient.addr), 0); + } + + //Set the recipients after the rewards have been paid into the pool + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + + //claim funds for each recipient within the pool + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //get the recipient that is claiming + Common.AddressAndWeight memory recipient = getPrimaryRecipients()[i]; + + //there should be no rewards claimed as the recipient is registered + claimRewards(PRIMARY_POOL_ARRAY, recipient.addr); + + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipient.addr), expectedRecipientAmount); + } + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.general.t.sol b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.general.t.sol new file mode 100644 index 00000000000..e656ca1fcf4 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.general.t.sol @@ -0,0 +1,66 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseRewardManagerTest} from "./BaseRewardManager.t.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {RewardManager} from "../../dev/RewardManager.sol"; +import {ERC20Mock} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol"; + +/** + * @title BaseRewardManagerTest + * @author Michael Fletcher + * @notice This contract will test the core functionality of the RewardManager contract + */ +contract RewardManagerSetupTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + } + + function test_rejectsZeroLinkAddressOnConstruction() public { + //should revert if the contract is a zero address + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //create a rewardManager with a zero link address + new RewardManager(address(0)); + } + + function test_eventEmittedUponFeeManagerUpdate() public { + //expect the event to be emitted + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit FeeManagerUpdated(FEE_MANAGER); + + //set the verifier proxy + setFeeManager(FEE_MANAGER, ADMIN); + } + + function test_eventEmittedUponFeePaid() public { + //create pool and add funds + createPrimaryPool(); + + //change to the feeManager who is the one who will be paying the fees + changePrank(FEE_MANAGER); + + //approve the amount being paid into the pool + ERC20Mock(getAsset(POOL_DEPOSIT_AMOUNT).assetAddress).approve(address(rewardManager), POOL_DEPOSIT_AMOUNT); + + //event is emitted when funds are added + vm.expectEmit(); + emit FeePaid(PRIMARY_POOL_ID, FEE_MANAGER, POOL_DEPOSIT_AMOUNT); + + //this represents the verifier adding some funds to the pool + rewardManager.onFeePaid(PRIMARY_POOL_ID, FEE_MANAGER, POOL_DEPOSIT_AMOUNT); + } + + function test_setFeeManagerZeroAddress() public { + //should revert if the contract is a zero address + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //set the verifier proxy + setFeeManager(address(0), ADMIN); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.payRecipients.t.sol b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.payRecipients.t.sol new file mode 100644 index 00000000000..8506210f2df --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.payRecipients.t.sol @@ -0,0 +1,191 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseRewardManagerTest} from "./BaseRewardManager.t.sol"; +import {Common} from "../../../libraries/Common.sol"; + +/** + * @title BaseRewardManagerTest + * @author Michael Fletcher + * @notice This contract will test the payRecipients functionality of the RewardManager contract + */ +contract RewardManagerPayRecipientsTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a single pool for these tests + createPrimaryPool(); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function test_payAllRecipients() public { + //pay all the recipients in the pool + payRecipients(PRIMARY_POOL_ID, getPrimaryRecipientAddresses(), ADMIN); + + //each recipient should receive 1/4 of the pool + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check each recipient received the correct amount + for (uint256 i = 0; i < getPrimaryRecipientAddresses().length; i++) { + assertEq(getAssetBalance(getPrimaryRecipientAddresses()[i]), expectedRecipientAmount); + } + } + + function test_paySingleRecipient() public { + //get the first individual recipient + address recipient = getPrimaryRecipientAddresses()[0]; + + //get a single recipient as an array + address[] memory recipients = new address[](1); + recipients[0] = recipient; + + //pay a single recipient + payRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //the recipient should have received 1/4 of the deposit amount + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + assertEq(getAssetBalance(recipient), expectedRecipientAmount); + } + + function test_payRecipientWithInvalidPool() public { + //get the first individual recipient + address recipient = getPrimaryRecipientAddresses()[0]; + + //get a single recipient as an array + address[] memory recipients = new address[](1); + recipients[0] = recipient; + + //pay a single recipient + payRecipients(SECONDARY_POOL_ID, recipients, ADMIN); + + //the recipient should have received nothing + assertEq(getAssetBalance(recipient), 0); + } + + function test_payRecipientsEmptyRecipientList() public { + //get a single recipient + address[] memory recipients = new address[](0); + + //pay a single recipient + payRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //rewardManager should have the full balance + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_payAllRecipientsWithAdditionalUnregisteredRecipient() public { + //load all the recipients and add an additional one who is not in the pool + address[] memory recipients = new address[](getPrimaryRecipientAddresses().length + 1); + for (uint256 i = 0; i < getPrimaryRecipientAddresses().length; i++) { + recipients[i] = getPrimaryRecipientAddresses()[i]; + } + recipients[recipients.length - 1] = DEFAULT_RECIPIENT_5; + + //pay the recipients + payRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //each recipient should receive 1/4 of the pool except the last + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check each recipient received the correct amount + for (uint256 i = 0; i < getPrimaryRecipientAddresses().length; i++) { + assertEq(getAssetBalance(getPrimaryRecipientAddresses()[i]), expectedRecipientAmount); + } + + //the unregistered recipient should receive nothing + assertEq(getAssetBalance(DEFAULT_RECIPIENT_5), 0); + } + + function test_payAllRecipientsWithAdditionalInvalidRecipient() public { + //load all the recipients and add an additional one which is invalid, that should receive nothing + address[] memory recipients = new address[](getPrimaryRecipientAddresses().length + 1); + for (uint256 i = 0; i < getPrimaryRecipientAddresses().length; i++) { + recipients[i] = getPrimaryRecipientAddresses()[i]; + } + recipients[recipients.length - 1] = INVALID_ADDRESS; + + //pay the recipients + payRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //each recipient should receive 1/4 of the pool except the last + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check each recipient received the correct amount + for (uint256 i = 0; i < getPrimaryRecipientAddresses().length; i++) { + assertEq(getAssetBalance(getPrimaryRecipientAddresses()[i]), expectedRecipientAmount); + } + } + + function test_paySubsetOfRecipientsInPool() public { + //load a subset of the recipients into an array + address[] memory recipients = new address[](getPrimaryRecipientAddresses().length - 1); + for (uint256 i = 0; i < recipients.length; i++) { + recipients[i] = getPrimaryRecipientAddresses()[i]; + } + + //pay the subset of recipients + payRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //each recipient should receive 1/4 of the pool except the last + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check each subset of recipients received the correct amount + for (uint256 i = 0; i < recipients.length - 1; i++) { + assertEq(getAssetBalance(recipients[i]), expectedRecipientAmount); + } + + //check the pool has the remaining balance + assertEq( + getAssetBalance(address(rewardManager)), + POOL_DEPOSIT_AMOUNT - expectedRecipientAmount * recipients.length + ); + } + + function test_payAllRecipientsFromNonAdminUser() public { + //should revert if the caller isn't an admin or recipient within the pool + vm.expectRevert(UNAUTHORIZED_ERROR_SELECTOR); + + //pay all the recipients in the pool + payRecipients(PRIMARY_POOL_ID, getPrimaryRecipientAddresses(), FEE_MANAGER); + } + + function test_payAllRecipientsFromRecipientInPool() public { + //pay all the recipients in the pool + payRecipients(PRIMARY_POOL_ID, getPrimaryRecipientAddresses(), DEFAULT_RECIPIENT_1); + + //each recipient should receive 1/4 of the pool + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //check each recipient received the correct amount + for (uint256 i = 0; i < getPrimaryRecipientAddresses().length; i++) { + assertEq(getAssetBalance(getPrimaryRecipientAddresses()[i]), expectedRecipientAmount); + } + } + + function test_payRecipientsWithInvalidPoolId() public { + //pay all the recipients in the pool + payRecipients(INVALID_POOL_ID, getPrimaryRecipientAddresses(), ADMIN); + + //pool should still contain the full balance + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_addFundsToPoolAsOwner() public { + //add funds to the pool + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function test_addFundsToPoolAsNonOwnerOrFeeManager() public { + //should revert if the caller isn't an admin or recipient within the pool + vm.expectRevert(UNAUTHORIZED_ERROR_SELECTOR); + + //add funds to the pool + rewardManager.onFeePaid(PRIMARY_POOL_ID, USER, POOL_DEPOSIT_AMOUNT); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.setRecipients.t.sol b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.setRecipients.t.sol new file mode 100644 index 00000000000..0c58a8562cf --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.setRecipients.t.sol @@ -0,0 +1,152 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseRewardManagerTest} from "./BaseRewardManager.t.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {RewardManager} from "../../dev/RewardManager.sol"; + +/** + * @title BaseRewardManagerTest + * @author Michael Fletcher + * @notice This contract will test the setRecipient functionality of the RewardManager contract + */ +contract RewardManagerSetRecipientsTest is BaseRewardManagerTest { + function setUp() public override { + //setup contracts + super.setUp(); + } + + function test_setRewardRecipients() public { + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + } + + function test_setRewardRecipientsIsEmpty() public { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + + //should revert if the recipients array is empty + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_setRewardRecipientWithZeroWeight() public { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](5); + + //init each recipient with even weights + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, ONE_PERCENT * 25); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, ONE_PERCENT * 25); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, ONE_PERCENT * 25); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, ONE_PERCENT * 25); + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, 0); + + //Zero weight should fail + vm.expectRevert(INVALID_WEIGHT_ERROR_SELECTOR); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_setRewardRecipientWithZeroAddress() public { + //array of recipients + Common.AddressAndWeight[] memory recipients = getPrimaryRecipients(); + + //override the first recipient with a zero address + recipients[0].addr = address(0); + + //should revert if the recipients array is empty + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_setRewardRecipientWeights() public { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + + //init each recipient with even weights + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, 25); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, 25); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, 25); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, 25); + + //should revert if the recipients array is empty + vm.expectRevert(INVALID_WEIGHT_ERROR_SELECTOR); + + //set the recipients with a recipient with a weight of 100% + setRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_setSingleRewardRecipient() public { + //array of recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](1); + + //init each recipient with even weights + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, POOL_SCALAR); + + //set the recipients with a recipient with a weight of 100% + setRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_setRewardRecipientTwice() public { + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + + //should revert if recipients for this pool have already been set + vm.expectRevert(INVALID_POOL_ID_ERROR_SELECTOR); + + //set the recipients again + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + } + + function test_setRewardRecipientFromNonOwnerOrFeeManagerAddress() public { + //should revert if the sender is not the owner or proxy + vm.expectRevert(UNAUTHORIZED_ERROR_SELECTOR); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), USER); + } + + function test_setRewardRecipientFromManagerAddress() public { + //update the proxy address + setFeeManager(FEE_MANAGER, ADMIN); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), FEE_MANAGER); + } + + function test_eventIsEmittedUponSetRecipients() public { + //expect an emit + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit RewardRecipientsUpdated(PRIMARY_POOL_ID, getPrimaryRecipients()); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + } + + function test_setRecipientContainsDuplicateRecipients() public { + //create a new array to hold the existing recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length * 2); + + //add all the existing recipients + for (uint256 i; i < getPrimaryRecipients().length; i++) { + recipients[i] = getPrimaryRecipients()[i]; + } + //add all the existing recipients again + for (uint256 i; i < getPrimaryRecipients().length; i++) { + recipients[i + getPrimaryRecipients().length] = getPrimaryRecipients()[i]; + } + + //should revert as the list contains a duplicate + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //set the recipients + setRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.updateRewardRecipients.t.sol b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.updateRewardRecipients.t.sol new file mode 100644 index 00000000000..de12f11bf92 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/reward-manager/RewardManager.updateRewardRecipients.t.sol @@ -0,0 +1,466 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseRewardManagerTest} from "./BaseRewardManager.t.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {RewardManager} from "../../dev/RewardManager.sol"; + +/** + * @title BaseRewardManagerTest + * @author Michael Fletcher + * @notice This contract will test the updateRecipient functionality of the RewardManager contract + */ +contract RewardManagerUpdateRewardRecipientsTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a single pool for these tests + createPrimaryPool(); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function test_onlyAdminCanUpdateRecipients() public { + //should revert if the caller is not the admin + vm.expectRevert(ONLY_CALLABLE_BY_OWNER_ERROR); + + //updating a recipient should force the funds to be paid out + updateRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), FEE_MANAGER); + } + + function test_updateAllRecipientsWithSameAddressAndWeight() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //updating a recipient should force the funds to be paid out + updateRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + + //check each recipient received the correct amount + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(getPrimaryRecipients()[i].addr), expectedRecipientAmount); + } + } + + function test_updatePartialRecipientsWithSameAddressAndWeight() public { + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //get a subset of the recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](2); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, ONE_PERCENT * 25); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, ONE_PERCENT * 25); + + //updating a recipient should force the funds to be paid out + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //check each recipient received the correct amount + for (uint256 i; i < recipients.length; i++) { + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipients[i].addr), expectedRecipientAmount); + } + + //the reward manager should still have half remaining funds + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT / 2); + } + + function test_updateRecipientWithNewZeroAddress() public { + //create a new array to hold the existing recipients plus a new zero address + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length + 1); + + //add all the existing recipients + for (uint256 i; i < getPrimaryRecipients().length; i++) { + recipients[i] = getPrimaryRecipients()[i]; + } + //add a new address to the primary recipients + recipients[recipients.length - 1] = Common.AddressAndWeight(address(0), 0); + + //should revert if the recipient is a zero address + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //update the recipients with invalid address + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsContainsDuplicateRecipients() public { + //create a new array to hold the existing recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length * 2); + + //add all the existing recipients + for (uint256 i; i < getPrimaryRecipients().length; i++) { + recipients[i] = getPrimaryRecipients()[i]; + } + //add all the existing recipients again + for (uint256 i; i < getPrimaryRecipients().length; i++) { + recipients[i + getPrimaryRecipients().length] = getPrimaryRecipients()[i]; + } + + //should revert as the list contains a duplicate + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //update the recipients with the duplicate addresses + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsToDifferentSet() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length + 4); + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //copy the recipient and set the weight to 0 which implies the recipient is being replaced + recipients[i] = Common.AddressAndWeight(getPrimaryRecipients()[i].addr, 0); + } + + //add the new recipients individually + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, ONE_PERCENT * 25); + recipients[5] = Common.AddressAndWeight(DEFAULT_RECIPIENT_6, ONE_PERCENT * 25); + recipients[6] = Common.AddressAndWeight(DEFAULT_RECIPIENT_7, ONE_PERCENT * 25); + recipients[7] = Common.AddressAndWeight(DEFAULT_RECIPIENT_8, ONE_PERCENT * 25); + + //should revert as it's not possible to new recipients + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsToDifferentPartialSet() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length + 2); + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //copy the recipient and set the weight to 0 which implies the recipient is being replaced + recipients[i] = Common.AddressAndWeight(getPrimaryRecipients()[i].addr, 0); + } + + //add the new recipients individually + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, FIFTY_PERCENT); + recipients[5] = Common.AddressAndWeight(DEFAULT_RECIPIENT_6, FIFTY_PERCENT); + + //should revert as it's not possible to add new recipients + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsToDifferentLargerSet() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length + 5); + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //copy the recipient and set the weight to 0 which implies the recipient is being replaced + recipients[i] = Common.AddressAndWeight(getPrimaryRecipients()[i].addr, 0); + } + + //add the new recipients individually + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, TEN_PERCENT * 2); + recipients[5] = Common.AddressAndWeight(DEFAULT_RECIPIENT_6, TEN_PERCENT * 2); + recipients[6] = Common.AddressAndWeight(DEFAULT_RECIPIENT_7, TEN_PERCENT * 2); + recipients[7] = Common.AddressAndWeight(DEFAULT_RECIPIENT_8, TEN_PERCENT * 2); + recipients[8] = Common.AddressAndWeight(DEFAULT_RECIPIENT_9, TEN_PERCENT * 2); + + //should revert as changing the recipient set is not allowed + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsUpdateAndRemoveExistingForLargerSet() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](9); + + //update the existing recipients + recipients[0] = Common.AddressAndWeight(getPrimaryRecipients()[0].addr, 0); + recipients[1] = Common.AddressAndWeight(getPrimaryRecipients()[1].addr, 0); + recipients[2] = Common.AddressAndWeight(getPrimaryRecipients()[2].addr, TEN_PERCENT * 3); + recipients[3] = Common.AddressAndWeight(getPrimaryRecipients()[3].addr, TEN_PERCENT * 3); + + //add the new recipients individually + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, TEN_PERCENT); + recipients[5] = Common.AddressAndWeight(DEFAULT_RECIPIENT_6, TEN_PERCENT); + recipients[6] = Common.AddressAndWeight(DEFAULT_RECIPIENT_7, TEN_PERCENT); + recipients[7] = Common.AddressAndWeight(DEFAULT_RECIPIENT_8, TEN_PERCENT); + recipients[8] = Common.AddressAndWeight(DEFAULT_RECIPIENT_9, TEN_PERCENT); + + //should revert as it's not possible to add new recipients + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsUpdateAndRemoveExistingForSmallerSet() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](5); + + //update the existing recipients + recipients[0] = Common.AddressAndWeight(getPrimaryRecipients()[0].addr, 0); + recipients[1] = Common.AddressAndWeight(getPrimaryRecipients()[1].addr, 0); + recipients[2] = Common.AddressAndWeight(getPrimaryRecipients()[2].addr, TEN_PERCENT * 3); + recipients[3] = Common.AddressAndWeight(getPrimaryRecipients()[3].addr, TEN_PERCENT * 2); + + //add the new recipients individually + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, TEN_PERCENT * 5); + + //should revert as it's not possible to add new recipients + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientsToDifferentSetWithInvalidWeights() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](getPrimaryRecipients().length + 2); + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //copy the recipient and set the weight to 0 which implies the recipient is being replaced + recipients[i] = Common.AddressAndWeight(getPrimaryRecipients()[i].addr, 0); + } + + //add the new recipients individually + recipients[4] = Common.AddressAndWeight(DEFAULT_RECIPIENT_5, TEN_PERCENT * 5); + recipients[5] = Common.AddressAndWeight(DEFAULT_RECIPIENT_6, TEN_PERCENT); + + //should revert as the addresses are not in the configured set + vm.expectRevert(INVALID_ADDRESS_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updatePartialRecipientsToSubset() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, 0); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, 0); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, TEN_PERCENT * 5); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, TEN_PERCENT * 5); + + //should revert as changing the recipients is not allowed + vm.expectRevert(INVALID_WEIGHT_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updatePartialRecipientsWithUnderWeightSet() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, TEN_PERCENT); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, TEN_PERCENT); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, TEN_PERCENT); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, TEN_PERCENT); + + //should revert as the new weights exceed the previous weights being replaced + vm.expectRevert(INVALID_WEIGHT_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updatePartialRecipientsWithExcessiveWeight() public { + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, TEN_PERCENT); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, TEN_PERCENT); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, TEN_PERCENT); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, POOL_SCALAR); + + //should revert as the new weights exceed the previous weights being replaced + vm.expectRevert(INVALID_WEIGHT_ERROR_SELECTOR); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + } + + function test_updateRecipientWeights() public { + //expected recipient amount is 1/4 of the pool deposit for original recipients + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //create a list of containing recipients from the primary configured set with their new weights + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, TEN_PERCENT); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, TEN_PERCENT); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, TEN_PERCENT * 3); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, TEN_PERCENT * 5); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //check each recipient received the correct amount + for (uint256 i; i < recipients.length; i++) { + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipients[i].addr), expectedRecipientAmount); + } + + //the reward manager should have no funds remaining + assertEq(getAssetBalance(address(rewardManager)), 0); + + //add more funds to the pool to check new distribution + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //loop each user and claim the rewards + for (uint256 i; i < recipients.length; i++) { + //claim the rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipients[i].addr); + } + + //manually check the balance of each recipient + assertEq( + getAssetBalance(DEFAULT_RECIPIENT_1), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(DEFAULT_RECIPIENT_2), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(DEFAULT_RECIPIENT_3), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT * 3) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(DEFAULT_RECIPIENT_4), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT * 5) / POOL_SCALAR + expectedRecipientAmount + ); + } + + function test_partialUpdateRecipientWeights() public { + //expected recipient amount is 1/4 of the pool deposit for original recipients + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //create a list of containing recipients from the primary configured set with their new weights + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](2); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, TEN_PERCENT); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, TEN_PERCENT * 4); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //check each recipient received the correct amount + for (uint256 i; i < recipients.length; i++) { + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipients[i].addr), expectedRecipientAmount); + } + + //the reward manager should have half the funds remaining + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT / 2); + + //add more funds to the pool to check new distribution + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //loop each user and claim the rewards + for (uint256 i; i < recipients.length; i++) { + //claim the rewards for this recipient + claimRewards(PRIMARY_POOL_ARRAY, recipients[i].addr); + } + + //manually check the balance of each recipient + assertEq( + getAssetBalance(DEFAULT_RECIPIENT_1), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(DEFAULT_RECIPIENT_2), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT * 4) / POOL_SCALAR + expectedRecipientAmount + ); + + //the reward manager should have half the funds remaining + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + } + + function test_eventIsEmittedUponUpdateRecipients() public { + //expect an emit + vm.expectEmit(); + + //emit the event that is expected to be emitted + emit RewardRecipientsUpdated(PRIMARY_POOL_ID, getPrimaryRecipients()); + + //expected recipient amount is 1/4 of the pool deposit + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //updating a recipient should force the funds to be paid out + updateRewardRecipients(PRIMARY_POOL_ID, getPrimaryRecipients(), ADMIN); + + //check each recipient received the correct amount + for (uint256 i; i < getPrimaryRecipients().length; i++) { + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(getPrimaryRecipients()[i].addr), expectedRecipientAmount); + } + } +} + +contract RewardManagerUpdateRewardRecipientsMultiplePoolsTest is BaseRewardManagerTest { + uint256 internal constant POOL_DEPOSIT_AMOUNT = 10e18; + + function setUp() public override { + //setup contracts + super.setUp(); + + //create a single pool for these tests + createPrimaryPool(); + createSecondaryPool(); + + //add funds to the pool to be split among the recipients + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + addFundsToPool(SECONDARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + } + + function getSecondaryRecipients() public override returns (Common.AddressAndWeight[] memory) { + //for testing purposes, the primary and secondary pool to contain the same recipients + return getPrimaryRecipients(); + } + + function test_updatePrimaryRecipientWeights() public { + //expected recipient amount is 1/4 of the pool deposit for original recipients + uint256 expectedRecipientAmount = POOL_DEPOSIT_AMOUNT / 4; + + //create a list of containing recipients from the primary configured set, and new recipients + Common.AddressAndWeight[] memory recipients = new Common.AddressAndWeight[](4); + recipients[0] = Common.AddressAndWeight(DEFAULT_RECIPIENT_1, TEN_PERCENT * 4); + recipients[1] = Common.AddressAndWeight(DEFAULT_RECIPIENT_2, TEN_PERCENT * 4); + recipients[2] = Common.AddressAndWeight(DEFAULT_RECIPIENT_3, TEN_PERCENT); + recipients[3] = Common.AddressAndWeight(DEFAULT_RECIPIENT_4, TEN_PERCENT); + + //updating a recipient should force the funds to be paid out for the primary recipients + updateRewardRecipients(PRIMARY_POOL_ID, recipients, ADMIN); + + //check each recipient received the correct amount + for (uint256 i; i < recipients.length; i++) { + //check the balance matches the ratio the recipient should have received + assertEq(getAssetBalance(recipients[i].addr), expectedRecipientAmount); + } + + //the reward manager should still have the funds for the secondary pool + assertEq(getAssetBalance(address(rewardManager)), POOL_DEPOSIT_AMOUNT); + + //add more funds to the pool to check new distribution + addFundsToPool(PRIMARY_POOL_ID, getAsset(POOL_DEPOSIT_AMOUNT), FEE_MANAGER); + + //claim the rewards for the updated recipients manually + claimRewards(PRIMARY_POOL_ARRAY, recipients[0].addr); + claimRewards(PRIMARY_POOL_ARRAY, recipients[1].addr); + claimRewards(PRIMARY_POOL_ARRAY, recipients[2].addr); + claimRewards(PRIMARY_POOL_ARRAY, recipients[3].addr); + + //check the balance matches the ratio the recipient who were updated should have received + assertEq( + getAssetBalance(recipients[0].addr), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT * 4) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(recipients[1].addr), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT * 4) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(recipients[2].addr), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT) / POOL_SCALAR + expectedRecipientAmount + ); + assertEq( + getAssetBalance(recipients[3].addr), + (POOL_DEPOSIT_AMOUNT * TEN_PERCENT) / POOL_SCALAR + expectedRecipientAmount + ); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol similarity index 56% rename from contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol index f91ef741ed9..1a604798b1d 100644 --- a/contracts/src/v0.8/llo-feeds/test/BaseVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol @@ -2,13 +2,19 @@ pragma solidity 0.8.16; import {Test} from "forge-std/Test.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; -import {IERC165} from "../../vendor/IERC165.sol"; -import {IVerifier} from "../interfaces/IVerifier.sol"; -import {ErroredVerifier} from "./mocks/ErroredVerifier.sol"; -import {Verifier} from "../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {ErroredVerifier} from "../mocks/ErroredVerifier.sol"; +import {Verifier} from "../../Verifier.sol"; import {Strings} from "@openzeppelin/contracts/utils/Strings.sol"; -import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {ERC20Mock} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol"; +import {WERC20Mock} from "../../../shared/mocks/WERC20Mock.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; +import {RewardManager} from "../../dev/RewardManager.sol"; contract BaseTest is Test { uint256 internal constant MAX_ORACLES = 31; @@ -18,9 +24,19 @@ contract BaseTest is Test { address internal constant MOCK_VERIFIER_ADDRESS_TWO = address(200); address internal constant ACCESS_CONTROLLER_ADDRESS = address(300); - bytes32 internal constant FEED_ID = keccak256("ETH-USD"); - bytes32 internal constant FEED_ID_2 = keccak256("LINK-USD"); - bytes32 internal constant FEED_ID_3 = keccak256("BTC-USD"); + bytes32 internal constant V_MASK = 0x0000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff; + bytes32 internal constant V1_BITMASK = 0x0001000000000000000000000000000000000000000000000000000000000000; + bytes32 internal constant V2_BITMASK = 0x0002000000000000000000000000000000000000000000000000000000000000; + bytes32 internal constant V3_BITMASK = 0x0003000000000000000000000000000000000000000000000000000000000000; + + //version 0 feeds + bytes32 internal constant FEED_ID = (keccak256("ETH-USD") & V_MASK) | V1_BITMASK; + bytes32 internal constant FEED_ID_2 = (keccak256("LINK-USD") & V_MASK) | V1_BITMASK; + bytes32 internal constant FEED_ID_3 = (keccak256("BTC-USD") & V_MASK) | V1_BITMASK; + + //version 3 feeds + bytes32 internal constant FEED_ID_V3 = (keccak256("ETH-USD") & V_MASK) | V3_BITMASK; + bytes32 internal constant INVALID_FEED = keccak256("INVALID"); uint32 internal constant OBSERVATIONS_TIMESTAMP = 1000; uint64 internal constant BLOCKNUMBER_LOWER_BOUND = 1000; @@ -47,7 +63,7 @@ contract BaseTest is Test { address signerAddress; } - struct Report { + struct V0Report { // The feed ID the report has data for bytes32 feedId; // The time the median value was observed on @@ -64,6 +80,8 @@ contract BaseTest is Test { bytes32 upperBlockhash; // The lower bound of the block range the median value was observed within uint64 blocknumberLowerBound; + // The current block timestamp + uint64 currentBlockTimestamp; } Signer[MAX_ORACLES] internal s_signers; @@ -111,7 +129,7 @@ contract BaseTest is Test { } function _generateSignerSignatures( - Report memory report, + bytes memory report, bytes32[3] memory reportContext, Signer[] memory signers ) internal pure returns (bytes32[] memory rawRs, bytes32[] memory rawSs, bytes32 rawVs) { @@ -119,7 +137,7 @@ contract BaseTest is Test { bytes32[] memory ss = new bytes32[](signers.length); bytes memory vs = new bytes(signers.length); - bytes32 hash = keccak256(abi.encodePacked(keccak256(abi.encode(report)), reportContext)); + bytes32 hash = keccak256(abi.encodePacked(keccak256(report), reportContext)); for (uint256 i = 0; i < signers.length; i++) { (uint8 v, bytes32 r, bytes32 s) = vm.sign(signers[i].mockPrivateKey, hash); @@ -131,16 +149,17 @@ contract BaseTest is Test { } function _generateEncodedBlob( - Report memory report, + V0Report memory report, bytes32[3] memory reportContext, Signer[] memory signers ) internal pure returns (bytes memory) { + bytes memory reportBytes = abi.encode(report); (bytes32[] memory rs, bytes32[] memory ss, bytes32 rawVs) = _generateSignerSignatures( - report, + reportBytes, reportContext, signers ); - return abi.encode(reportContext, abi.encode(report), rs, ss, rawVs); + return abi.encode(reportContext, reportBytes, rs, ss, rawVs); } function _configDigestFromConfigData( @@ -175,7 +194,7 @@ contract BaseTest is Test { return bytes32((prefix & prefixMask) | (h & ~prefixMask)); } - function _createReport( + function _createV0Report( bytes32 feedId, uint32 observationsTimestamp, int192 median, @@ -183,10 +202,11 @@ contract BaseTest is Test { int192 ask, uint64 blocknumberUpperBound, bytes32 upperBlockhash, - uint64 blocknumberLowerBound - ) internal pure returns (Report memory) { + uint64 blocknumberLowerBound, + uint32 currentBlockTimestamp + ) internal pure returns (V0Report memory) { return - Report({ + V0Report({ feedId: feedId, observationsTimestamp: observationsTimestamp, median: median, @@ -194,7 +214,8 @@ contract BaseTest is Test { ask: ask, blocknumberUpperBound: blocknumberUpperBound, upperBlockhash: upperBlockhash, - blocknumberLowerBound: blocknumberLowerBound + blocknumberLowerBound: blocknumberLowerBound, + currentBlockTimestamp: currentBlockTimestamp }); } @@ -212,12 +233,40 @@ contract BaseTest is Test { } } -contract BaseTestWithConfiguredVerifier is BaseTest { +contract BaseTestWithConfiguredVerifierAndFeeManager is BaseTest { + FeeManager internal feeManager; + RewardManager internal rewardManager; + ERC20Mock internal link; + WERC20Mock internal native; + + uint256 internal constant DEFAULT_REPORT_LINK_FEE = 1e10; + uint256 internal constant DEFAULT_REPORT_NATIVE_FEE = 1e12; + + struct V2Report { + // The feed ID the report has data for + bytes32 feedId; + // The time the median value was observed on + uint32 observationsTimestamp; + // The median value agreed in an OCR round + int192 benchmarkPrice; + // The best bid value agreed in an OCR round + int192 bid; + // The best ask value agreed in an OCR round + int192 ask; + // The timestamp the report is valid from + uint32 validFromTimestamp; + // The expiry of the report + uint32 expiresAt; + // The link fee + uint192 linkFee; + // The native fee + uint192 nativeFee; + } + function setUp() public virtual override { BaseTest.setUp(); Signer[] memory signers = _getSigners(MAX_ORACLES); - // Verifier 1, Feed 1, Config 1 s_verifierProxy.initializeVerifier(address(s_verifier)); s_verifier.setConfig( FEED_ID, @@ -226,12 +275,116 @@ contract BaseTestWithConfiguredVerifier is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) + ); + + s_verifier.setConfig( + FEED_ID_V3, + _getSignerAddresses(signers), + s_offchaintransmitters, + FAULT_TOLERANCE, + bytes(""), + VERIFIER_VERSION, + bytes(""), + new Common.AddressAndWeight[](0) + ); + + link = new ERC20Mock("LINK", "LINK", ADMIN, 0); + native = new WERC20Mock(); + + rewardManager = new RewardManager(address(link)); + feeManager = new FeeManager(address(link), address(native), address(s_verifierProxy), address(rewardManager)); + + s_verifierProxy.setFeeManager(feeManager); + rewardManager.setFeeManager(address(feeManager)); + } + + function _encodeReport(V2Report memory report) internal pure returns (bytes memory) { + return + abi.encode( + report.feedId, + report.observationsTimestamp, + report.benchmarkPrice, + report.bid, + report.ask, + report.validFromTimestamp, + report.expiresAt, + report.linkFee, + report.nativeFee + ); + } + + function _generateEncodedBlobWithQuote( + V2Report memory report, + bytes32[3] memory reportContext, + Signer[] memory signers, + bytes memory quote + ) internal pure returns (bytes memory) { + bytes memory reportBytes = _encodeReport(report); + (bytes32[] memory rs, bytes32[] memory ss, bytes32 rawVs) = _generateSignerSignatures( + reportBytes, + reportContext, + signers ); + + return abi.encode(reportContext, reportBytes, rs, ss, rawVs, quote); + } + + function _generateQuote(address billingAddress) internal returns (bytes memory) { + return abi.encode(billingAddress); + } + + function _generateV2Report() internal returns (V2Report memory) { + return + V2Report({ + feedId: FEED_ID_V3, + observationsTimestamp: OBSERVATIONS_TIMESTAMP, + benchmarkPrice: MEDIAN, + bid: BID, + ask: ASK, + validFromTimestamp: uint32(block.timestamp), + expiresAt: uint32(block.timestamp), + linkFee: uint192(DEFAULT_REPORT_LINK_FEE), + nativeFee: uint192(DEFAULT_REPORT_NATIVE_FEE) + }); + } + + function _generateReportContext(bytes32 feedId) internal returns (bytes32[3] memory) { + (, , bytes32 latestConfigDigest) = s_verifier.latestConfigDetails(feedId); + bytes32[3] memory reportContext; + reportContext[0] = latestConfigDigest; + reportContext[1] = bytes32(abi.encode(uint32(5), uint8(1))); + return reportContext; + } + + function _approveLink(address spender, uint256 quantity, address sender) internal { + address originalAddr = msg.sender; + changePrank(sender); + + link.approve(spender, quantity); + changePrank(originalAddr); + } + + function _approveNative(address spender, uint256 quantity, address sender) internal { + address originalAddr = msg.sender; + changePrank(sender); + + native.approve(spender, quantity); + changePrank(originalAddr); + } + + function _verify(bytes memory payload, uint256 wrappedNativeValue, address sender) internal { + address originalAddr = msg.sender; + changePrank(sender); + + s_verifierProxy.verify{value: wrappedNativeValue}(payload); + + changePrank(originalAddr); } } -contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifier { +contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifierAndFeeManager { bytes32 internal s_configDigestOne; bytes32 internal s_configDigestTwo; bytes32 internal s_configDigestThree; @@ -244,7 +397,7 @@ contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifier uint8 internal constant FAULT_TOLERANCE_THREE = 1; function setUp() public virtual override { - BaseTestWithConfiguredVerifier.setUp(); + BaseTestWithConfiguredVerifierAndFeeManager.setUp(); Signer[] memory signers = _getSigners(MAX_ORACLES); (, , s_configDigestOne) = s_verifier.latestConfigDetails(FEED_ID); @@ -258,7 +411,8 @@ contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifier FAULT_TOLERANCE_TWO, bytes(""), 2, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , s_configDigestTwo) = s_verifier.latestConfigDetails(FEED_ID); @@ -271,7 +425,8 @@ contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifier FAULT_TOLERANCE_THREE, bytes(""), 3, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (s_numConfigsSet, , s_configDigestThree) = s_verifier.latestConfigDetails(FEED_ID); @@ -283,7 +438,8 @@ contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifier FAULT_TOLERANCE, bytes(""), 4, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , s_configDigestFour) = s_verifier.latestConfigDetails(FEED_ID_2); @@ -296,7 +452,8 @@ contract BaseTestWithMultipleConfiguredDigests is BaseTestWithConfiguredVerifier FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , s_configDigestFive) = s_verifier_2.latestConfigDetails(FEED_ID_3); } diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierActivateConfigTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierActivateConfigTest.t.sol similarity index 81% rename from contracts/src/v0.8/llo-feeds/test/VerifierActivateConfigTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierActivateConfigTest.t.sol index e7bc4ab23fb..501f23d10d3 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierActivateConfigTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierActivateConfigTest.t.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTestWithConfiguredVerifier, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; -import {Verifier} from "../Verifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; +import {BaseTestWithConfiguredVerifierAndFeeManager, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; -contract VerifierActivateConfigTest is BaseTestWithConfiguredVerifier { +contract VerifierActivateConfigTest is BaseTestWithConfiguredVerifierAndFeeManager { function test_revertsIfNotOwner() public { vm.expectRevert("Only callable by owner"); @@ -29,13 +29,13 @@ contract VerifierActivateConfigWithDeactivatedConfigTest is BaseTestWithMultiple event ConfigActivated(bytes32 configDigest); - Report internal s_testReportOne; + V0Report internal s_testReportOne; function setUp() public override { BaseTestWithMultipleConfiguredDigests.setUp(); s_reportContext[0] = s_configDigestTwo; s_reportContext[1] = bytes32(abi.encode(uint32(5), uint8(1))); - s_testReportOne = _createReport( + s_testReportOne = _createV0Report( FEED_ID, uint32(block.timestamp), MEDIAN, @@ -43,7 +43,8 @@ contract VerifierActivateConfigWithDeactivatedConfigTest is BaseTestWithMultiple ASK, uint64(block.number), blockhash(block.number + 3), - uint64(block.number + 3) + uint64(block.number + 3), + uint32(block.timestamp) ); s_verifier.deactivateConfig(FEED_ID, s_configDigestTwo); diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierDeactivateFeedTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierDeactivateFeedTest.t.sol similarity index 88% rename from contracts/src/v0.8/llo-feeds/test/VerifierDeactivateFeedTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierDeactivateFeedTest.t.sol index 1f55be2ca72..e44a9a03f81 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierDeactivateFeedTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierDeactivateFeedTest.t.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTestWithConfiguredVerifier, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; -import {Verifier} from "../Verifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; +import {BaseTestWithConfiguredVerifierAndFeeManager, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; -contract VerifierActivateFeedTest is BaseTestWithConfiguredVerifier { +contract VerifierActivateFeedTest is BaseTestWithConfiguredVerifierAndFeeManager { function test_revertsIfNotOwnerActivateFeed() public { changePrank(address(s_verifierProxy)); vm.expectRevert("Only callable by owner"); @@ -34,13 +34,13 @@ contract VerifierDeactivateFeedWithVerifyTest is BaseTestWithMultipleConfiguredD event ConfigActivated(bytes32 configDigest); - Report internal s_testReportOne; + V0Report internal s_testReportOne; function setUp() public override { BaseTestWithMultipleConfiguredDigests.setUp(); s_reportContext[0] = s_configDigestOne; s_reportContext[1] = bytes32(abi.encode(uint32(5), uint8(1))); - s_testReportOne = _createReport( + s_testReportOne = _createV0Report( FEED_ID, uint32(block.timestamp), MEDIAN, @@ -48,7 +48,8 @@ contract VerifierDeactivateFeedWithVerifyTest is BaseTestWithMultipleConfiguredD ASK, uint64(block.number), blockhash(block.number + 3), - uint64(block.number + 3) + uint64(block.number + 3), + uint32(block.timestamp) ); s_verifier.deactivateFeed(FEED_ID); diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierProxyConstructorTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyConstructorTest.t.sol similarity index 67% rename from contracts/src/v0.8/llo-feeds/test/VerifierProxyConstructorTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyConstructorTest.t.sol index 879814d949c..b4d13423ecd 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierProxyConstructorTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyConstructorTest.t.sol @@ -2,9 +2,9 @@ pragma solidity 0.8.16; import {BaseTest} from "./BaseVerifierTest.t.sol"; -import {IVerifier} from "../interfaces/IVerifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; -import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; +import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; contract VerifierProxyConstructorTest is BaseTest { function test_correctlySetsTheOwner() public { @@ -15,11 +15,11 @@ contract VerifierProxyConstructorTest is BaseTest { function test_correctlySetsTheCorrectAccessControllerInterface() public { address accessControllerAddr = address(1234); VerifierProxy proxy = new VerifierProxy(AccessControllerInterface(accessControllerAddr)); - assertEq(address(proxy.getAccessController()), accessControllerAddr); + assertEq(address(proxy.s_accessController()), accessControllerAddr); } function test_correctlySetsVersion() public { string memory version = s_verifierProxy.typeAndVersion(); - assertEq(version, "VerifierProxy 1.0.0"); + assertEq(version, "VerifierProxy 1.1.0"); } } diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierProxyInitializeVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyInitializeVerifierTest.t.sol similarity index 78% rename from contracts/src/v0.8/llo-feeds/test/VerifierProxyInitializeVerifierTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyInitializeVerifierTest.t.sol index 67cf548f268..92b98c6d9d2 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierProxyInitializeVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyInitializeVerifierTest.t.sol @@ -2,16 +2,15 @@ pragma solidity 0.8.16; import {BaseTest} from "./BaseVerifierTest.t.sol"; -import {IVerifier} from "../interfaces/IVerifier.sol"; -import {VerifierProxy} from "..//VerifierProxy.sol"; -import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; +import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; contract VerifierProxyInitializeVerifierTest is BaseTest { bytes32 latestDigest; function setUp() public override { BaseTest.setUp(); - Signer[] memory signers = _getSigners(MAX_ORACLES); } function test_revertsIfNotOwner() public { diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierProxySetAccessControllerTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxySetAccessControllerTest.t.sol similarity index 82% rename from contracts/src/v0.8/llo-feeds/test/VerifierProxySetAccessControllerTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxySetAccessControllerTest.t.sol index ca8c8e22fc2..a93f30a743a 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierProxySetAccessControllerTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxySetAccessControllerTest.t.sol @@ -2,7 +2,7 @@ pragma solidity 0.8.16; import {BaseTest} from "./BaseVerifierTest.t.sol"; -import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; contract VerifierProxySetAccessControllerTest is BaseTest { event AccessControllerSet(address oldAccessController, address newAccessController); @@ -16,13 +16,13 @@ contract VerifierProxySetAccessControllerTest is BaseTest { function test_successfullySetsNewAccessController() public { s_verifierProxy.setAccessController(AccessControllerInterface(ACCESS_CONTROLLER_ADDRESS)); - AccessControllerInterface ac = s_verifierProxy.getAccessController(); + AccessControllerInterface ac = s_verifierProxy.s_accessController(); assertEq(address(ac), ACCESS_CONTROLLER_ADDRESS); } function test_successfullySetsNewAccessControllerIsEmpty() public { s_verifierProxy.setAccessController(AccessControllerInterface(address(0))); - AccessControllerInterface ac = s_verifierProxy.getAccessController(); + AccessControllerInterface ac = s_verifierProxy.s_accessController(); assertEq(address(ac), address(0)); } diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxySetVerifierTest.t.sol similarity index 67% rename from contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxySetVerifierTest.t.sol index 2cc4062e0a4..ee7b2c96b7b 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierProxySetVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxySetVerifierTest.t.sol @@ -1,16 +1,17 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTestWithConfiguredVerifier} from "./BaseVerifierTest.t.sol"; -import {IVerifier} from "../interfaces/IVerifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; -import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; -import {IERC165} from "../../vendor/IERC165.sol"; +import {BaseTestWithConfiguredVerifierAndFeeManager} from "./BaseVerifierTest.t.sol"; +import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../../libraries/Common.sol"; -contract VerifierProxyInitializeVerifierTest is BaseTestWithConfiguredVerifier { +contract VerifierProxyInitializeVerifierTest is BaseTestWithConfiguredVerifierAndFeeManager { function test_revertsIfNotCorrectVerifier() public { vm.expectRevert(abi.encodeWithSelector(VerifierProxy.AccessForbidden.selector)); - s_verifierProxy.setVerifier(bytes32("prev-config"), bytes32("new-config")); + s_verifierProxy.setVerifier(bytes32("prev-config"), bytes32("new-config"), new Common.AddressAndWeight[](0)); } function test_revertsIfDigestAlreadySet() public { @@ -28,13 +29,13 @@ contract VerifierProxyInitializeVerifierTest is BaseTestWithConfiguredVerifier { abi.encodeWithSelector(VerifierProxy.ConfigDigestAlreadySet.selector, takenDigest, address(s_verifier)) ); changePrank(address(maliciousVerifier)); - s_verifierProxy.setVerifier(maliciousDigest, takenDigest); + s_verifierProxy.setVerifier(maliciousDigest, takenDigest, new Common.AddressAndWeight[](0)); } function test_updatesVerifierIfVerifier() public { (, , bytes32 prevDigest) = s_verifier.latestConfigDetails(FEED_ID); changePrank(address(s_verifier)); - s_verifierProxy.setVerifier(prevDigest, bytes32("new-config")); + s_verifierProxy.setVerifier(prevDigest, bytes32("new-config"), new Common.AddressAndWeight[](0)); assertEq(s_verifierProxy.getVerifier(bytes32("new-config")), address(s_verifier)); assertEq(s_verifierProxy.getVerifier(prevDigest), address(s_verifier)); } diff --git a/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyTest.t.sol new file mode 100644 index 00000000000..ffce4e6fa50 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyTest.t.sol @@ -0,0 +1,17 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseTestWithConfiguredVerifierAndFeeManager} from "./BaseVerifierTest.t.sol"; +import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; +import {Common} from "../../../libraries/Common.sol"; +import {FeeManager} from "../../dev/FeeManager.sol"; + +contract VerifierProxyInitializeVerifierTest is BaseTestWithConfiguredVerifierAndFeeManager { + function test_setFeeManagerZeroAddress() public { + vm.expectRevert(abi.encodeWithSelector(VerifierProxy.ZeroAddress.selector)); + s_verifierProxy.setFeeManager(FeeManager(address(0))); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierProxyUnsetVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyUnsetVerifierTest.t.sol similarity index 79% rename from contracts/src/v0.8/llo-feeds/test/VerifierProxyUnsetVerifierTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyUnsetVerifierTest.t.sol index c5b49e41e1b..a64d6ee0f78 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierProxyUnsetVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierProxyUnsetVerifierTest.t.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTest, BaseTestWithConfiguredVerifier} from "./BaseVerifierTest.t.sol"; -import {IVerifier} from "../interfaces/IVerifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; +import {BaseTest, BaseTestWithConfiguredVerifierAndFeeManager} from "./BaseVerifierTest.t.sol"; +import {IVerifier} from "../../interfaces/IVerifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; contract VerifierProxyUnsetVerifierTest is BaseTest { function test_revertsIfNotAdmin() public { @@ -19,13 +19,13 @@ contract VerifierProxyUnsetVerifierTest is BaseTest { } } -contract VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest is BaseTestWithConfiguredVerifier { +contract VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest is BaseTestWithConfiguredVerifierAndFeeManager { bytes32 internal s_configDigest; event VerifierUnset(bytes32 configDigest, address verifierAddr); function setUp() public override { - BaseTestWithConfiguredVerifier.setUp(); + BaseTestWithConfiguredVerifierAndFeeManager.setUp(); (, , s_configDigest) = s_verifier.latestConfigDetails(FEED_ID); } diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierSetConfigTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol similarity index 88% rename from contracts/src/v0.8/llo-feeds/test/VerifierSetConfigTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol index dfffd47f571..ded1da7de62 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierSetConfigTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol @@ -2,8 +2,9 @@ pragma solidity 0.8.16; import {BaseTest, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; -import {Verifier} from "../Verifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {Common} from "../../../libraries/Common.sol"; contract VerifierSetConfigTest is BaseTest { function setUp() public virtual override { @@ -22,7 +23,8 @@ contract VerifierSetConfigTest is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } @@ -36,7 +38,8 @@ contract VerifierSetConfigTest is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } @@ -50,7 +53,8 @@ contract VerifierSetConfigTest is BaseTest { 0, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } @@ -69,7 +73,8 @@ contract VerifierSetConfigTest is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } @@ -85,7 +90,8 @@ contract VerifierSetConfigTest is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } @@ -101,7 +107,8 @@ contract VerifierSetConfigTest is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); } @@ -116,7 +123,8 @@ contract VerifierSetConfigTest is BaseTest { FAULT_TOLERANCE, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); bytes32 expectedConfigDigest = _configDigestFromConfigData( @@ -154,7 +162,8 @@ contract VerifierSetConfigWhenThereAreMultipleDigestsTest is BaseTestWithMultipl 4, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , bytes32 configDigest) = s_verifier.latestConfigDetails(FEED_ID); @@ -172,7 +181,8 @@ contract VerifierSetConfigWhenThereAreMultipleDigestsTest is BaseTestWithMultipl 4, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , bytes32 configDigest) = s_verifier.latestConfigDetails(FEED_ID_2); @@ -186,7 +196,8 @@ contract VerifierSetConfigWhenThereAreMultipleDigestsTest is BaseTestWithMultipl 4, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , bytes32 configDigest2) = s_verifier_2.latestConfigDetails(FEED_ID_3); @@ -206,7 +217,8 @@ contract VerifierSetConfigWhenThereAreMultipleDigestsTest is BaseTestWithMultipl 4, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); bytes32 expectedConfigDigest = _configDigestFromConfigData( diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierTest.t.sol similarity index 90% rename from contracts/src/v0.8/llo-feeds/test/VerifierTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierTest.t.sol index 514b8ce50a0..424b1124b92 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierTest.t.sol @@ -2,8 +2,8 @@ pragma solidity 0.8.16; import {BaseTest} from "./BaseVerifierTest.t.sol"; -import {Verifier} from "../Verifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; contract VerifierConstructorTest is BaseTest { function test_revertsIfInitializedWithEmptyVerifierProxy() public { @@ -26,7 +26,7 @@ contract VerifierConstructorTest is BaseTest { assertEq(configDigestTwo, EMPTY_BYTES); string memory typeAndVersion = s_verifier.typeAndVersion(); - assertEq(typeAndVersion, "Verifier 1.0.0"); + assertEq(typeAndVersion, "Verifier 1.1.0"); } } diff --git a/contracts/src/v0.8/llo-feeds/test/verifier/VerifierTestBillingReport.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierTestBillingReport.t.sol new file mode 100644 index 00000000000..086816a7c57 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierTestBillingReport.t.sol @@ -0,0 +1,81 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseTestWithConfiguredVerifierAndFeeManager} from "./BaseVerifierTest.t.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {Common} from "../../../libraries/Common.sol"; + +contract VerifierTestWithConfiguredVerifierAndFeeManager is BaseTestWithConfiguredVerifierAndFeeManager { + uint256 internal constant DEFAULT_LINK_MINT_QUANTITY = 100 ether; + uint256 internal constant DEFAULT_NATIVE_MINT_QUANTITY = 100 ether; + + function setUp() public virtual override { + super.setUp(); + + //mint some tokens to the user + link.mint(USER, DEFAULT_LINK_MINT_QUANTITY); + native.mint(USER, DEFAULT_NATIVE_MINT_QUANTITY); + vm.deal(USER, DEFAULT_NATIVE_MINT_QUANTITY); + } +} + +contract VerifierTestBillingReport is VerifierTestWithConfiguredVerifierAndFeeManager { + function test_verifyWithLink() public { + bytes memory signedReport = _generateEncodedBlobWithQuote( + _generateV2Report(), + _generateReportContext(FEED_ID_V3), + _getSigners(FAULT_TOLERANCE + 1), + _generateQuote(address(link)) + ); + + _approveLink(address(rewardManager), DEFAULT_REPORT_LINK_FEE, USER); + + _verify(signedReport, 0, USER); + + assertEq(link.balanceOf(USER), DEFAULT_LINK_MINT_QUANTITY - DEFAULT_REPORT_LINK_FEE); + } + + function test_verifyWithNative() public { + bytes memory signedReport = _generateEncodedBlobWithQuote( + _generateV2Report(), + _generateReportContext(FEED_ID_V3), + _getSigners(FAULT_TOLERANCE + 1), + _generateQuote(address(native)) + ); + + _approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE, USER); + + _verify(signedReport, 0, USER); + + assertEq(native.balanceOf(USER), DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + } + + function test_verifyWithNativeUnwrapped() public { + bytes memory signedReport = _generateEncodedBlobWithQuote( + _generateV2Report(), + _generateReportContext(FEED_ID_V3), + _getSigners(FAULT_TOLERANCE + 1), + _generateQuote(address(native)) + ); + + _verify(signedReport, DEFAULT_REPORT_NATIVE_FEE, USER); + + assertEq(USER.balance, DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + assertEq(address(feeManager).balance, 0); + } + + function test_verifyWithNativeUnwrappedReturnsChange() public { + bytes memory signedReport = _generateEncodedBlobWithQuote( + _generateV2Report(), + _generateReportContext(FEED_ID_V3), + _getSigners(FAULT_TOLERANCE + 1), + _generateQuote(address(native)) + ); + + _verify(signedReport, DEFAULT_REPORT_NATIVE_FEE * 2, USER); + + assertEq(USER.balance, DEFAULT_NATIVE_MINT_QUANTITY - DEFAULT_REPORT_NATIVE_FEE); + assertEq(address(feeManager).balance, 0); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierUnsetConfigTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierUnsetConfigTest.t.sol similarity index 90% rename from contracts/src/v0.8/llo-feeds/test/VerifierUnsetConfigTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierUnsetConfigTest.t.sol index d97e0499186..467c5072d55 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierUnsetConfigTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierUnsetConfigTest.t.sol @@ -1,9 +1,9 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTestWithConfiguredVerifier, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; -import {Verifier} from "../Verifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; +import {BaseTestWithConfiguredVerifierAndFeeManager, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; contract VerificationdeactivateConfigWhenThereAreMultipleDigestsTest is BaseTestWithMultipleConfiguredDigests { function test_revertsIfCalledByNonOwner() public { diff --git a/contracts/src/v0.8/llo-feeds/test/VerifierVerifyTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierVerifyTest.t.sol similarity index 90% rename from contracts/src/v0.8/llo-feeds/test/VerifierVerifyTest.t.sol rename to contracts/src/v0.8/llo-feeds/test/verifier/VerifierVerifyTest.t.sol index 065a9cd9c5e..38bb86a663d 100644 --- a/contracts/src/v0.8/llo-feeds/test/VerifierVerifyTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierVerifyTest.t.sol @@ -1,24 +1,25 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity 0.8.16; -import {BaseTestWithConfiguredVerifier} from "./BaseVerifierTest.t.sol"; -import {Verifier} from "../Verifier.sol"; -import {VerifierProxy} from "../VerifierProxy.sol"; -import {AccessControllerInterface} from "../../interfaces/AccessControllerInterface.sol"; +import {BaseTestWithConfiguredVerifierAndFeeManager} from "./BaseVerifierTest.t.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {AccessControllerInterface} from "../../../interfaces/AccessControllerInterface.sol"; +import {Common} from "../../../libraries/Common.sol"; -contract VerifierVerifyTest is BaseTestWithConfiguredVerifier { +contract VerifierVerifyTest is BaseTestWithConfiguredVerifierAndFeeManager { bytes32[3] internal s_reportContext; event ReportVerified(bytes32 indexed feedId, address requester); - Report internal s_testReportOne; + V0Report internal s_testReportOne; function setUp() public virtual override { - BaseTestWithConfiguredVerifier.setUp(); + BaseTestWithConfiguredVerifierAndFeeManager.setUp(); (, , bytes32 configDigest) = s_verifier.latestConfigDetails(FEED_ID); s_reportContext[0] = configDigest; s_reportContext[1] = bytes32(abi.encode(uint32(5), uint8(1))); - s_testReportOne = _createReport( + s_testReportOne = _createV0Report( FEED_ID, OBSERVATIONS_TIMESTAMP, MEDIAN, @@ -26,11 +27,12 @@ contract VerifierVerifyTest is BaseTestWithConfiguredVerifier { ASK, BLOCKNUMBER_UPPER_BOUND, blockhash(BLOCKNUMBER_UPPER_BOUND), - BLOCKNUMBER_LOWER_BOUND + BLOCKNUMBER_LOWER_BOUND, + uint32(block.timestamp) ); } - function assertReportsEqual(bytes memory response, Report memory testReport) public { + function assertReportsEqual(bytes memory response, V0Report memory testReport) public { ( bytes32 feedId, uint32 timestamp, @@ -136,7 +138,7 @@ contract VerifierVerifySingleConfigDigestTest is VerifierVerifyTest { signers[10].mockPrivateKey = 1234; bytes memory signedReport = _generateEncodedBlob(s_testReportOne, s_reportContext, signers); changePrank(address(s_verifierProxy)); - vm.expectRevert(abi.encodeWithSelector(Verifier.AccessForbidden.selector)); + vm.expectRevert(abi.encodeWithSelector(Verifier.BadVerification.selector)); s_verifier.verify(signedReport, msg.sender); } @@ -160,7 +162,7 @@ contract VerifierVerifySingleConfigDigestTest is VerifierVerifyTest { } function test_revertsIfReportHasUnconfiguredFeedID() public { - Report memory report = _createReport( + V0Report memory report = _createV0Report( FEED_ID_2, OBSERVATIONS_TIMESTAMP, MEDIAN, @@ -168,7 +170,8 @@ contract VerifierVerifySingleConfigDigestTest is VerifierVerifyTest { ASK, BLOCKNUMBER_UPPER_BOUND, blockhash(BLOCKNUMBER_UPPER_BOUND), - BLOCKNUMBER_LOWER_BOUND + BLOCKNUMBER_LOWER_BOUND, + uint32(block.timestamp) ); bytes memory signedReport = _generateEncodedBlob(report, s_reportContext, _getSigners(FAULT_TOLERANCE + 1)); vm.expectRevert(abi.encodeWithSelector(Verifier.DigestInactive.selector, FEED_ID_2, s_reportContext[0])); @@ -188,7 +191,7 @@ contract VerifierVerifySingleConfigDigestTest is VerifierVerifyTest { // Duplicate signer at index 1 signers[0] = signers[1]; bytes memory signedReport = _generateEncodedBlob(s_testReportOne, s_reportContext, signers); - vm.expectRevert(abi.encodeWithSelector(Verifier.NonUniqueSignatures.selector)); + vm.expectRevert(abi.encodeWithSelector(Verifier.BadVerification.selector)); changePrank(address(s_verifierProxy)); s_verifier.verify(signedReport, msg.sender); } @@ -248,7 +251,8 @@ contract VerifierVerifyMultipleConfigDigestTest is VerifierVerifyTest { FAULT_TOLERANCE_TWO, bytes(""), VERIFIER_VERSION, - bytes("") + bytes(""), + new Common.AddressAndWeight[](0) ); (, , s_newConfigDigest) = s_verifier.latestConfigDetails(FEED_ID); } diff --git a/contracts/src/v0.8/shared/interfaces/IWERC20.sol b/contracts/src/v0.8/shared/interfaces/IWERC20.sol new file mode 100644 index 00000000000..e79712a593d --- /dev/null +++ b/contracts/src/v0.8/shared/interfaces/IWERC20.sol @@ -0,0 +1,8 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +interface IWERC20 { + function deposit() external payable; + + function withdraw(uint) external; +} diff --git a/contracts/src/v0.8/shared/mocks/WERC20Mock.sol b/contracts/src/v0.8/shared/mocks/WERC20Mock.sol new file mode 100644 index 00000000000..11bdb790c02 --- /dev/null +++ b/contracts/src/v0.8/shared/mocks/WERC20Mock.sol @@ -0,0 +1,35 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {ERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol"; + +contract WERC20Mock is ERC20 { + constructor() ERC20("WERC20Mock", "WERC") {} + + event Deposit(address indexed dst, uint wad); + event Withdrawal(address indexed src, uint wad); + + receive() external payable { + deposit(); + } + + function deposit() public payable { + _mint(msg.sender, msg.value); + emit Deposit(msg.sender, msg.value); + } + + function withdraw(uint wad) public { + require(balanceOf(msg.sender) >= wad); + _burn(msg.sender, wad); + payable(msg.sender).transfer(wad); + emit Withdrawal(msg.sender, wad); + } + + function mint(address account, uint256 amount) external { + _mint(account, amount); + } + + function burn(address account, uint256 amount) external { + _burn(account, amount); + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol new file mode 100644 index 00000000000..91bb8f82e54 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol @@ -0,0 +1,6 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts v4.4.1 (interfaces/IERC165.sol) + +pragma solidity ^0.8.0; + +import "../utils/introspection/IERC165.sol"; \ No newline at end of file diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol new file mode 100644 index 00000000000..7c95dfca935 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol @@ -0,0 +1,6 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts v4.4.1 (interfaces/IERC20.sol) + +pragma solidity ^0.8.0; + +import "../token/ERC20/IERC20.sol"; \ No newline at end of file diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol new file mode 100644 index 00000000000..4db5eb2e066 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/mocks/ERC20Mock.sol @@ -0,0 +1,41 @@ +// SPDX-License-Identifier: MIT + +pragma solidity ^0.8.0; + +import "../token/ERC20/ERC20.sol"; + +// mock class using ERC20 +contract ERC20Mock is ERC20 { + constructor( + string memory name, + string memory symbol, + address initialAccount, + uint256 initialBalance + ) payable ERC20(name, symbol) { + _mint(initialAccount, initialBalance); + } + + function mint(address account, uint256 amount) public { + _mint(account, amount); + } + + function burn(address account, uint256 amount) public { + _burn(account, amount); + } + + function transferInternal( + address from, + address to, + uint256 value + ) public { + _transfer(from, to, value); + } + + function approveInternal( + address owner, + address spender, + uint256 value + ) public { + _approve(owner, spender, value); + } +} \ No newline at end of file diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol new file mode 100644 index 00000000000..5fa65516d27 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol @@ -0,0 +1,25 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts v4.4.1 (utils/introspection/IERC165.sol) + +pragma solidity ^0.8.0; + +/** + * @dev Interface of the ERC165 standard, as defined in the + * https://eips.ethereum.org/EIPS/eip-165[EIP]. + * + * Implementers can declare support of contract interfaces, which can then be + * queried by others ({ERC165Checker}). + * + * For an implementation, see {ERC165}. + */ +interface IERC165 { + /** + * @dev Returns true if this contract implements the interface defined by + * `interfaceId`. See the corresponding + * https://eips.ethereum.org/EIPS/eip-165#how-interfaces-are-identified[EIP section] + * to learn more about how these ids are created. + * + * This function call must use less than 30 000 gas. + */ + function supportsInterface(bytes4 interfaceId) external view returns (bool); +} \ No newline at end of file diff --git a/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go b/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go index b4b449f0530..fda9e535e56 100644 --- a/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go +++ b/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go @@ -30,9 +30,14 @@ var ( _ = abi.ConvertType ) +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + var MercuryVerifierMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierProxyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"CannotDeactivateLatestConfig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DigestEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestInactive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestNotSet\",\"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\":[],\"name\":\"FeedIdEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InactiveFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"expectedNumSigners\",\"type\":\"uint256\"}],\"name\":\"IncorrectSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InvalidFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rsLength\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"ssLength\",\"type\":\"uint256\"}],\"name\":\"MismatchedSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NonUniqueSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedDeactivated\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"}],\"name\":\"ReportVerified\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"isVerifier\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200200c3803806200200c8339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051611e11620001fb6000396000818161031d01526109180152611e116000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806379ba50971161008c578063b70d929d11610066578063b70d929d14610221578063ded6307c14610280578063e84f128e14610293578063f2fde38b146102f057600080fd5b806379ba5097146101de5780638da5cb5b146101e657806394d959801461020e57600080fd5b80633dd86430116100bd5780633dd86430146101a357806344a0b2ad146101b8578063564a0a7a146101cb57600080fd5b806301ffc9a7146100e4578063181f5a771461014e5780633d3ac1b514610190575b600080fd5b6101396100f2366004611487565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b60408051808201909152600e81527f566572696669657220312e302e3000000000000000000000000000000000000060208201525b6040516101459190611534565b61018361019e366004611570565b610303565b6101b66101b13660046115f1565b61049d565b005b6101b66101c6366004611859565b61054f565b6101b66101d93660046115f1565b610a3f565b6101b6610b00565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610145565b6101b661021c366004611931565b610bfd565b61025d61022f3660046115f1565b6000908152600260205260408120600181015490549192909168010000000000000000900463ffffffff1690565b604080519315158452602084019290925263ffffffff1690820152606001610145565b6101b661028e366004611931565b610d5e565b6102cd6102a13660046115f1565b6000908152600260205260409020805460019091015463ffffffff808316936401000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610145565b6101b66102fe366004611953565b610e6f565b60603373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610374576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080610386888a018a61196e565b9450945094509450945060008461039c90611a49565b60008181526002602052604090208054919250906c01000000000000000000000000900460ff1615610402576040517f36dbe748000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b8651600081815260028301602052604090206104218483898985610e83565b61042b8984610f7f565b87516020890120610440818b8a8a8a87610fe7565b60405173ffffffffffffffffffffffffffffffffffffffff8d16815285907f58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc59060200160405180910390a250969c9b505050505050505050505050565b6104a5611263565b60008181526002602052604081208054909163ffffffff90911690036104fa576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff16815560405182907ff438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b490600090a25050565b85518460ff168060000361058f576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8211156105d4576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f60248201526044016103f9565b6105df816003611aec565b821161063757816105f1826003611aec565b6105fc906001611b29565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b61063f611263565b60008981526002602052604081208054909163ffffffff90911690829061066583611b42565b82546101009290920a63ffffffff81810219909316918316021790915582546000925061069a918d91168c8c8c8c8c8c6112e6565b6000818152600284016020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8c16176101001790559091505b8a518160ff1610156108db5760008b8260ff168151811061070057610700611a8e565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610770576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452600190810190925290912054610100900460ff16908111156107c3576107c3611b65565b14801591506107fe576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805180820190915260ff8416815260208101600190526000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684526001908101835292208351815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00821681178355928501519193919284927fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090921617906101009084908111156108c0576108c0611b65565b02179055509050505050806108d490611b94565b90506106dd565b5060018201546040517f2cc994770000000000000000000000000000000000000000000000000000000081526004810191909152602481018290527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1690632cc9947790604401600060405180830381600087803b15801561097157600080fd5b505af1158015610985573d6000803e3d6000fd5b505050508a7fa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da8360000160049054906101000a900463ffffffff16838560000160009054906101000a900463ffffffff168e8e8e8e8e8e6040516109f199989796959493929190611c34565b60405180910390a281547fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff1664010000000063ffffffff431602178255600190910155505050505050505050565b610a47611263565b60008181526002602052604081208054909163ffffffff9091169003610a9c576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff166c0100000000000000000000000017815560405182907ffc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd06190600090a25050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016103f9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c05611263565b600082815260026020526040902081610c4a576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610ca0576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b80600101548203610ce7576040517fa403c01600000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555183907f0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c90610d519085815260200190565b60405180910390a2505050565b610d66611263565b600082815260026020526040902081610dab576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610e01576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555183907f54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe774690610d519085815260200190565b610e77611263565b610e8081611392565b50565b8054600090610e969060ff166001611cca565b8254909150610100900460ff16610ee3576040517ffc10a28300000000000000000000000000000000000000000000000000000000815260048101879052602481018690526044016103f9565b8060ff16845114610f2f5783516040517f5348a282000000000000000000000000000000000000000000000000000000008152600481019190915260ff821660248201526044016103f9565b8251845114610f7757835183516040517ff0d31408000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b505050505050565b6020820151815463ffffffff600883901c81169168010000000000000000900416811115610fe15782547fffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffff166801000000000000000063ffffffff8316021783555b50505050565b60008686604051602001610ffc929190611ce3565b6040516020818303038152906040528051906020012090506000611030604080518082019091526000808252602082015290565b8651600090815b818110156111fb5760018689836020811061105457611054611a8e565b61106191901a601b611cca565b8c848151811061107357611073611a8e565b60200260200101518c858151811061108d5761108d611a8e565b6020026020010151604051600081526020016040526040516110cb949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156110ed573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526001808d01602090815291859020848601909552845460ff80821686529399509395509085019261010090049091169081111561117257611172611b65565b600181111561118357611183611b65565b90525093506001846020015160018111156111a0576111a0611b65565b146111d7576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836000015160080260ff166001901b85019450806111f490611d1f565b9050611037565b50837e01010101010101010101010101010101010101010101010101010101010101851614611256576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146112e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103f9565b565b6000808946308b8b8b8b8b8b8b60405160200161130c9a99989796959493929190611d57565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e060000000000000000000000000000000000000000000000000000000000001791505098975050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603611411576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103f9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561149957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146114c957600080fd5b9392505050565b6000815180845260005b818110156114f6576020818501810151868301820152016114da565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114c960208301846114d0565b803573ffffffffffffffffffffffffffffffffffffffff8116811461156b57600080fd5b919050565b60008060006040848603121561158557600080fd5b833567ffffffffffffffff8082111561159d57600080fd5b818601915086601f8301126115b157600080fd5b8135818111156115c057600080fd5b8760208285010111156115d257600080fd5b6020928301955093506115e89186019050611547565b90509250925092565b60006020828403121561160357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516060810167ffffffffffffffff8111828210171561165c5761165c61160a565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156116a9576116a961160a565b604052919050565b600067ffffffffffffffff8211156116cb576116cb61160a565b5060051b60200190565b600082601f8301126116e657600080fd5b813560206116fb6116f6836116b1565b611662565b82815260059290921b8401810191818101908684111561171a57600080fd5b8286015b8481101561173c5761172f81611547565b835291830191830161171e565b509695505050505050565b600082601f83011261175857600080fd5b813560206117686116f6836116b1565b82815260059290921b8401810191818101908684111561178757600080fd5b8286015b8481101561173c578035835291830191830161178b565b803560ff8116811461156b57600080fd5b600082601f8301126117c457600080fd5b813567ffffffffffffffff8111156117de576117de61160a565b61180f60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611662565b81815284602083860101111561182457600080fd5b816020850160208301376000918101602001919091529392505050565b803567ffffffffffffffff8116811461156b57600080fd5b600080600080600080600060e0888a03121561187457600080fd5b87359650602088013567ffffffffffffffff8082111561189357600080fd5b61189f8b838c016116d5565b975060408a01359150808211156118b557600080fd5b6118c18b838c01611747565b96506118cf60608b016117a2565b955060808a01359150808211156118e557600080fd5b6118f18b838c016117b3565b94506118ff60a08b01611841565b935060c08a013591508082111561191557600080fd5b506119228a828b016117b3565b91505092959891949750929550565b6000806040838503121561194457600080fd5b50508035926020909101359150565b60006020828403121561196557600080fd5b6114c982611547565b600080600080600060e0868803121561198657600080fd5b86601f87011261199557600080fd5b61199d611639565b8060608801898111156119af57600080fd5b885b818110156119c95780358452602093840193016119b1565b5090965035905067ffffffffffffffff808211156119e657600080fd5b6119f289838a016117b3565b95506080880135915080821115611a0857600080fd5b611a1489838a01611747565b945060a0880135915080821115611a2a57600080fd5b50611a3788828901611747565b9598949750929560c001359392505050565b80516020808301519190811015611a88577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611b2457611b24611abd565b500290565b80820180821115611b3c57611b3c611abd565b92915050565b600063ffffffff808316818103611b5b57611b5b611abd565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600060ff821660ff8103611baa57611baa611abd565b60010192915050565b600081518084526020808501945080840160005b83811015611bf957815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101611bc7565b509495945050505050565b600081518084526020808501945080840160005b83811015611bf957815187529582019590820190600101611c18565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152611c648184018a611bb3565b90508281036080840152611c788189611c04565b905060ff871660a084015282810360c0840152611c9581876114d0565b905067ffffffffffffffff851660e0840152828103610100840152611cba81856114d0565b9c9b505050505050505050505050565b60ff8181168382160190811115611b3c57611b3c611abd565b828152600060208083018460005b6003811015611d0e57815183529183019190830190600101611cf1565b505050506080820190509392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611d5057611d50611abd565b5060010190565b60006101408c83528b602084015273ffffffffffffffffffffffffffffffffffffffff8b16604084015267ffffffffffffffff808b166060850152816080850152611da48285018b611bb3565b915083820360a0850152611db8828a611c04565b915060ff881660c085015283820360e0850152611dd582886114d0565b9086166101008501528381036101208501529050611df381856114d0565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierProxyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"CannotDeactivateLatestConfig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DigestEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestInactive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestNotSet\",\"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\":[],\"name\":\"FeedIdEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InactiveFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"expectedNumSigners\",\"type\":\"uint256\"}],\"name\":\"IncorrectSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InvalidFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rsLength\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"ssLength\",\"type\":\"uint256\"}],\"name\":\"MismatchedSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NonUniqueSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedDeactivated\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"}],\"name\":\"ReportVerified\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"recipientAddressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"isVerifier\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162002150380380620021508339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051611f55620001fb6000396000818161031d015261091e0152611f556000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806379ba50971161008c578063b70d929d11610066578063b70d929d14610221578063ded6307c14610280578063e84f128e14610293578063f2fde38b146102f057600080fd5b806379ba5097146101de5780638da5cb5b146101e657806394d959801461020e57600080fd5b80633dd86430116100bd5780633dd86430146101a357806352ba27d6146101b8578063564a0a7a146101cb57600080fd5b806301ffc9a7146100e4578063181f5a771461014e5780633d3ac1b514610190575b600080fd5b6101396100f2366004611487565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b60408051808201909152600e81527f566572696669657220312e312e3000000000000000000000000000000000000060208201525b6040516101459190611534565b61018361019e366004611570565b610303565b6101b66101b13660046115f1565b61049d565b005b6101b66101c6366004611902565b61054f565b6101b66101d93660046115f1565b610a3f565b6101b6610b00565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610145565b6101b661021c3660046119ff565b610bfd565b61025d61022f3660046115f1565b6000908152600260205260408120600181015490549192909168010000000000000000900463ffffffff1690565b604080519315158452602084019290925263ffffffff1690820152606001610145565b6101b661028e3660046119ff565b610d5e565b6102cd6102a13660046115f1565b6000908152600260205260409020805460019091015463ffffffff808316936401000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610145565b6101b66102fe366004611a21565b610e6f565b60603373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610374576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080610386888a018a611a3c565b9450945094509450945060008461039c90611b17565b60008181526002602052604090208054919250906c01000000000000000000000000900460ff1615610402576040517f36dbe748000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b8651600081815260028301602052604090206104218483898985610e83565b61042b8984610f7f565b87516020890120610440818b8a8a8a87610fe7565b60405173ffffffffffffffffffffffffffffffffffffffff8d16815285907f58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc59060200160405180910390a250969c9b505050505050505050505050565b6104a5611263565b60008181526002602052604081208054909163ffffffff90911690036104fa576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff16815560405182907ff438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b490600090a25050565b86518560ff168060000361058f576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8211156105d4576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f60248201526044016103f9565b6105df816003611bba565b821161063757816105f1826003611bba565b6105fc906001611bf7565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b61063f611263565b60008a81526002602052604081208054909163ffffffff90911690829061066583611c10565b82546101009290920a63ffffffff81810219909316918316021790915582546000925061069a918e91168d8d8d8d8d8d6112e6565b6000818152600284016020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8d16176101001790559091505b8b518160ff1610156108db5760008c8260ff168151811061070057610700611b5c565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610770576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452600190810190925290912054610100900460ff16908111156107c3576107c3611c33565b14801591506107fe576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805180820190915260ff8416815260208101600190526000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684526001908101835292208351815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00821681178355928501519193919284927fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090921617906101009084908111156108c0576108c0611c33565b02179055509050505050806108d490611c62565b90506106dd565b5060018201546040517f589ede2800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169163589ede2891610956919085908a90600401611c81565b600060405180830381600087803b15801561097057600080fd5b505af1158015610984573d6000803e3d6000fd5b505050508b7fa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da8360000160049054906101000a900463ffffffff16838560000160009054906101000a900463ffffffff168f8f8f8f8f8f6040516109f099989796959493929190611d78565b60405180910390a281547fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff1664010000000063ffffffff43160217825560019091015550505050505050505050565b610a47611263565b60008181526002602052604081208054909163ffffffff9091169003610a9c576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff166c0100000000000000000000000017815560405182907ffc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd06190600090a25050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016103f9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c05611263565b600082815260026020526040902081610c4a576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610ca0576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b80600101548203610ce7576040517fa403c01600000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555183907f0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c90610d519085815260200190565b60405180910390a2505050565b610d66611263565b600082815260026020526040902081610dab576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610e01576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555183907f54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe774690610d519085815260200190565b610e77611263565b610e8081611392565b50565b8054600090610e969060ff166001611e0e565b8254909150610100900460ff16610ee3576040517ffc10a28300000000000000000000000000000000000000000000000000000000815260048101879052602481018690526044016103f9565b8060ff16845114610f2f5783516040517f5348a282000000000000000000000000000000000000000000000000000000008152600481019190915260ff821660248201526044016103f9565b8251845114610f7757835183516040517ff0d31408000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b505050505050565b6020820151815463ffffffff600883901c81169168010000000000000000900416811115610fe15782547fffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffff166801000000000000000063ffffffff8316021783555b50505050565b60008686604051602001610ffc929190611e27565b6040516020818303038152906040528051906020012090506000611030604080518082019091526000808252602082015290565b8651600090815b818110156111fb5760018689836020811061105457611054611b5c565b61106191901a601b611e0e565b8c848151811061107357611073611b5c565b60200260200101518c858151811061108d5761108d611b5c565b6020026020010151604051600081526020016040526040516110cb949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156110ed573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526001808d01602090815291859020848601909552845460ff80821686529399509395509085019261010090049091169081111561117257611172611c33565b600181111561118357611183611c33565b90525093506001846020015160018111156111a0576111a0611c33565b146111d7576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836000015160080260ff166001901b85019450806111f490611e63565b9050611037565b50837e01010101010101010101010101010101010101010101010101010101010101851614611256576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146112e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103f9565b565b6000808946308b8b8b8b8b8b8b60405160200161130c9a99989796959493929190611e9b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e060000000000000000000000000000000000000000000000000000000000001791505098975050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603611411576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103f9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561149957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146114c957600080fd5b9392505050565b6000815180845260005b818110156114f6576020818501810151868301820152016114da565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114c960208301846114d0565b803573ffffffffffffffffffffffffffffffffffffffff8116811461156b57600080fd5b919050565b60008060006040848603121561158557600080fd5b833567ffffffffffffffff8082111561159d57600080fd5b818601915086601f8301126115b157600080fd5b8135818111156115c057600080fd5b8760208285010111156115d257600080fd5b6020928301955093506115e89186019050611547565b90509250925092565b60006020828403121561160357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561165c5761165c61160a565b60405290565b6040516060810167ffffffffffffffff8111828210171561165c5761165c61160a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156116cc576116cc61160a565b604052919050565b600067ffffffffffffffff8211156116ee576116ee61160a565b5060051b60200190565b600082601f83011261170957600080fd5b8135602061171e611719836116d4565b611685565b82815260059290921b8401810191818101908684111561173d57600080fd5b8286015b8481101561175f5761175281611547565b8352918301918301611741565b509695505050505050565b600082601f83011261177b57600080fd5b8135602061178b611719836116d4565b82815260059290921b840181019181810190868411156117aa57600080fd5b8286015b8481101561175f57803583529183019183016117ae565b803560ff8116811461156b57600080fd5b600082601f8301126117e757600080fd5b813567ffffffffffffffff8111156118015761180161160a565b61183260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611685565b81815284602083860101111561184757600080fd5b816020850160208301376000918101602001919091529392505050565b803567ffffffffffffffff8116811461156b57600080fd5b600082601f83011261188d57600080fd5b8135602061189d611719836116d4565b82815260069290921b840181019181810190868411156118bc57600080fd5b8286015b8481101561175f57604081890312156118d95760008081fd5b6118e1611639565b6118ea82611547565b815281850135858201528352918301916040016118c0565b600080600080600080600080610100898b03121561191f57600080fd5b88359750602089013567ffffffffffffffff8082111561193e57600080fd5b61194a8c838d016116f8565b985060408b013591508082111561196057600080fd5b61196c8c838d0161176a565b975061197a60608c016117c5565b965060808b013591508082111561199057600080fd5b61199c8c838d016117d6565b95506119aa60a08c01611864565b945060c08b01359150808211156119c057600080fd5b6119cc8c838d016117d6565b935060e08b01359150808211156119e257600080fd5b506119ef8b828c0161187c565b9150509295985092959890939650565b60008060408385031215611a1257600080fd5b50508035926020909101359150565b600060208284031215611a3357600080fd5b6114c982611547565b600080600080600060e08688031215611a5457600080fd5b86601f870112611a6357600080fd5b611a6b611662565b806060880189811115611a7d57600080fd5b885b81811015611a97578035845260209384019301611a7f565b5090965035905067ffffffffffffffff80821115611ab457600080fd5b611ac089838a016117d6565b95506080880135915080821115611ad657600080fd5b611ae289838a0161176a565b945060a0880135915080821115611af857600080fd5b50611b058882890161176a565b9598949750929560c001359392505050565b80516020808301519190811015611b56577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611bf257611bf2611b8b565b500290565b80820180821115611c0a57611c0a611b8b565b92915050565b600063ffffffff808316818103611c2957611c29611b8b565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600060ff821660ff8103611c7857611c78611b8b565b60010192915050565b600060608201858352602085818501526040606081860152828651808552608087019150838801945060005b81811015611ce8578551805173ffffffffffffffffffffffffffffffffffffffff168452850151858401529484019491830191600101611cad565b50909998505050505050505050565b600081518084526020808501945080840160005b83811015611d3d57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101611d0b565b509495945050505050565b600081518084526020808501945080840160005b83811015611d3d57815187529582019590820190600101611d5c565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152611da88184018a611cf7565b90508281036080840152611dbc8189611d48565b905060ff871660a084015282810360c0840152611dd981876114d0565b905067ffffffffffffffff851660e0840152828103610100840152611dfe81856114d0565b9c9b505050505050505050505050565b60ff8181168382160190811115611c0a57611c0a611b8b565b828152600060208083018460005b6003811015611e5257815183529183019190830190600101611e35565b505050506080820190509392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611e9457611e94611b8b565b5060010190565b60006101408c83528b602084015273ffffffffffffffffffffffffffffffffffffffff8b16604084015267ffffffffffffffff808b166060850152816080850152611ee88285018b611cf7565b915083820360a0850152611efc828a611d48565b915060ff881660c085015283820360e0850152611f1982886114d0565b9086166101008501528381036101208501529050611f3781856114d0565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", } var MercuryVerifierABI = MercuryVerifierMetaData.ABI @@ -359,16 +364,16 @@ func (_MercuryVerifier *MercuryVerifierTransactorSession) DeactivateFeed(feedId return _MercuryVerifier.Contract.DeactivateFeed(&_MercuryVerifier.TransactOpts, feedId) } -func (_MercuryVerifier *MercuryVerifierTransactor) SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "setConfig", feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_MercuryVerifier *MercuryVerifierTransactor) SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _MercuryVerifier.contract.Transact(opts, "setConfig", feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) } -func (_MercuryVerifier *MercuryVerifierSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.SetConfig(&_MercuryVerifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_MercuryVerifier *MercuryVerifierSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _MercuryVerifier.Contract.SetConfig(&_MercuryVerifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) } -func (_MercuryVerifier *MercuryVerifierTransactorSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.SetConfig(&_MercuryVerifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) +func (_MercuryVerifier *MercuryVerifierTransactorSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _MercuryVerifier.Contract.SetConfig(&_MercuryVerifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) } func (_MercuryVerifier *MercuryVerifierTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { @@ -1537,7 +1542,7 @@ type MercuryVerifierInterface interface { DeactivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) - SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte) (*types.Transaction, error) + SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go b/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go index af82aa4e15b..fc6166d4428 100644 --- a/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go +++ b/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go @@ -30,9 +30,14 @@ var ( _ = abi.ConvertType ) +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + var MercuryVerifierProxyMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"ConfigDigestAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"VerifierAlreadyInitialized\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"VerifierInvalid\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"VerifierNotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldAccessController\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newAccessController\",\"type\":\"address\"}],\"name\":\"AccessControllerSet\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierInitialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"oldConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierUnset\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAccessController\",\"outputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"getVerifier\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"initializeVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"name\":\"setAccessController\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"currentConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"}],\"name\":\"setVerifier\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"unsetVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"verifierResponse\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b5060405161112e38038061112e83398101604081905261002f91610187565b33806000816100855760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156100b5576100b5816100de565b5050600480546001600160a01b0319166001600160a01b039390931692909217909155506101b7565b336001600160a01b038216036101365760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161007c565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561019957600080fd5b81516001600160a01b03811681146101b057600080fd5b9392505050565b610f68806101c66000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80638c2a4d5311610081578063eeb7b2481161005b578063eeb7b248146101c8578063f08391d8146101fe578063f2fde38b1461021157600080fd5b80638c2a4d53146101845780638da5cb5b146101975780638e760afe146101b557600080fd5b80632cc99477116100b25780632cc99477146101545780636e9140941461016957806379ba50971461017c57600080fd5b806316d6b5f6146100ce578063181f5a7714610112575b600080fd5b60045473ffffffffffffffffffffffffffffffffffffffff165b60405173ffffffffffffffffffffffffffffffffffffffff90911681526020015b60405180910390f35b60408051808201909152601381527f566572696669657250726f787920312e302e300000000000000000000000000060208201525b6040516101099190610c40565b610167610162366004610c5a565b610224565b005b610167610177366004610c7c565b61036f565b610167610467565b610167610192366004610cb7565b610564565b60005473ffffffffffffffffffffffffffffffffffffffff166100e8565b6101476101c3366004610cd4565b610795565b6100e86101d6366004610c7c565b60009081526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b61016761020c366004610cb7565b6109bf565b61016761021f366004610cb7565b610a46565b600081815260036020526040902054819073ffffffffffffffffffffffffffffffffffffffff1680156102a7576040517f375d1fe60000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff821660248201526044015b60405180910390fd5b3360009081526002602052604090205460ff166102f0576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600360209081526040918290208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000909116811790915582518781529182018690528183015290517fbeb513e532542a562ac35699e7cd9ae7d198dcd3eee15bada6c857d28ceaddcf9181900360600190a150505050565b610377610a5a565b60008181526003602052604090205473ffffffffffffffffffffffffffffffffffffffff16806103d6576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161029e565b6000828152600360205260409081902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055517f11dc15c4b8ac2b183166cc8427e5385a5ece8308217a4217338c6a7614845c4c9061045b908490849091825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a15050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146104e8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161029e565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b61056c610a5a565b8073ffffffffffffffffffffffffffffffffffffffff81166105ba576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f01ffc9a70000000000000000000000000000000000000000000000000000000081527f3d3ac1b500000000000000000000000000000000000000000000000000000000600482015273ffffffffffffffffffffffffffffffffffffffff8216906301ffc9a790602401602060405180830381865afa158015610644573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906106689190610d46565b61069e576040517f75b0527a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff821660009081526002602052604090205460ff1615610716576040517f4e01ccfd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8316600482015260240161029e565b73ffffffffffffffffffffffffffffffffffffffff821660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f1f2cd7c97f4d801b5efe26cc409617c1fd6c5ef786e79aacb90af40923e4e8e9910161045b565b60045460609073ffffffffffffffffffffffffffffffffffffffff16801580159061085557506040517f6b14daf800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821690636b14daf8906108129033906000903690600401610db1565b602060405180830381865afa15801561082f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108539190610d46565b155b1561088c576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006108988486610dea565b60008181526003602052604090205490915073ffffffffffffffffffffffffffffffffffffffff16806108fa576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161029e565b6040517f3d3ac1b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821690633d3ac1b59061095090899089903390600401610e27565b6000604051808303816000875af115801561096f573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526109b59190810190610e90565b9695505050505050565b6109c7610a5a565b6004805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b6910161045b565b610a4e610a5a565b610a5781610add565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610adb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161029e565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610b5c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161029e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005b83811015610bed578181015183820152602001610bd5565b50506000910152565b60008151808452610c0e816020860160208601610bd2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610c536020830184610bf6565b9392505050565b60008060408385031215610c6d57600080fd5b50508035926020909101359150565b600060208284031215610c8e57600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff81168114610a5757600080fd5b600060208284031215610cc957600080fd5b8135610c5381610c95565b60008060208385031215610ce757600080fd5b823567ffffffffffffffff80821115610cff57600080fd5b818501915085601f830112610d1357600080fd5b813581811115610d2257600080fd5b866020828501011115610d3457600080fd5b60209290920196919550909350505050565b600060208284031215610d5857600080fd5b81518015158114610c5357600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff84168152604060208201526000610de1604083018486610d68565b95945050505050565b80356020831015610e21577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b165b92915050565b604081526000610e3b604083018587610d68565b905073ffffffffffffffffffffffffffffffffffffffff83166020830152949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600060208284031215610ea257600080fd5b815167ffffffffffffffff80821115610eba57600080fd5b818401915084601f830112610ece57600080fd5b815181811115610ee057610ee0610e61565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715610f2657610f26610e61565b81604052828152876020848701011115610f3f57600080fd5b610f50836020830160208801610bd2565b97965050505050505056fea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"ConfigDigestAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"VerifierAlreadyInitialized\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"VerifierInvalid\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"VerifierNotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldAccessController\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newAccessController\",\"type\":\"address\"}],\"name\":\"AccessControllerSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldFeeManager\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newFeeManager\",\"type\":\"address\"}],\"name\":\"FeeManagerSet\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierInitialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"oldConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierUnset\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"getVerifier\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"initializeVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_accessController\",\"outputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeManager\",\"outputs\":[{\"internalType\":\"contractIVerifierFeeManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"name\":\"setAccessController\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractIVerifierFeeManager\",\"name\":\"feeManager\",\"type\":\"address\"}],\"name\":\"setFeeManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"currentConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"addressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setVerifier\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"unsetVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"verifierResponse\",\"type\":\"bytes\"}],\"stateMutability\":\"payable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50604051620014e6380380620014e683398101604081905261003191610189565b33806000816100875760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156100b7576100b7816100e0565b5050600480546001600160a01b0319166001600160a01b039390931692909217909155506101b9565b336001600160a01b038216036101385760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161007e565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561019b57600080fd5b81516001600160a01b03811681146101b257600080fd5b9392505050565b61131d80620001c96000396000f3fe6080604052600436106100d25760003560e01c80638c2a4d531161007f57806394ba28461161005957806394ba284614610256578063eeb7b24814610283578063f08391d8146102c6578063f2fde38b146102e657600080fd5b80638c2a4d53146101f85780638da5cb5b146102185780638e760afe1461024357600080fd5b8063589ede28116100b0578063589ede28146101a35780636e914094146101c357806379ba5097146101e357600080fd5b8063181f5a77146100d757806338416b5b1461012f578063472d35b914610181575b600080fd5b3480156100e357600080fd5b5060408051808201909152601381527f566572696669657250726f787920312e312e300000000000000000000000000060208201525b6040516101269190610f30565b60405180910390f35b34801561013b57600080fd5b5060055461015c9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610126565b34801561018d57600080fd5b506101a161019c366004610f6c565b610306565b005b3480156101af57600080fd5b506101a16101be366004610f89565b610395565b3480156101cf57600080fd5b506101a16101de36600461100c565b6105c0565b3480156101ef57600080fd5b506101a16106ac565b34801561020457600080fd5b506101a1610213366004610f6c565b6107a9565b34801561022457600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff1661015c565b610119610251366004611025565b6109da565b34801561026257600080fd5b5060045461015c9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561028f57600080fd5b5061015c61029e36600461100c565b60009081526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b3480156102d257600080fd5b506101a16102e1366004610f6c565b610caf565b3480156102f257600080fd5b506101a1610301366004610f6c565b610d36565b61030e610d4a565b6005805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f04628abcaa6b1674651352125cb94b65b289145bc2bc4d67720bb7d966372f0391015b60405180910390a15050565b600083815260036020526040902054839073ffffffffffffffffffffffffffffffffffffffff168015610418576040517f375d1fe60000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff821660248201526044015b60405180910390fd5b3360009081526002602052604090205460ff16610461576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260036020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000163317905582156105795760055473ffffffffffffffffffffffffffffffffffffffff166104ec576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6005546040517f69fd2b3400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909116906369fd2b349061054690889088908890600401611097565b600060405180830381600087803b15801561056057600080fd5b505af1158015610574573d6000803e3d6000fd5b505050505b6040805187815260208101879052338183015290517fbeb513e532542a562ac35699e7cd9ae7d198dcd3eee15bada6c857d28ceaddcf9181900360600190a1505050505050565b6105c8610d4a565b60008181526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1680610627576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161040f565b6000828152600360205260409081902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055517f11dc15c4b8ac2b183166cc8427e5385a5ece8308217a4217338c6a7614845c4c90610389908490849091825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60015473ffffffffffffffffffffffffffffffffffffffff16331461072d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161040f565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6107b1610d4a565b8073ffffffffffffffffffffffffffffffffffffffff81166107ff576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f01ffc9a70000000000000000000000000000000000000000000000000000000081527f3d3ac1b500000000000000000000000000000000000000000000000000000000600482015273ffffffffffffffffffffffffffffffffffffffff8216906301ffc9a790602401602060405180830381865afa158015610889573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108ad9190611106565b6108e3576040517f75b0527a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff821660009081526002602052604090205460ff161561095b576040517f4e01ccfd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8316600482015260240161040f565b73ffffffffffffffffffffffffffffffffffffffff821660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f1f2cd7c97f4d801b5efe26cc409617c1fd6c5ef786e79aacb90af40923e4e8e99101610389565b60045460609073ffffffffffffffffffffffffffffffffffffffff168015801590610a9a57506040517f6b14daf800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890610a579033906000903690600401611171565b602060405180830381865afa158015610a74573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a989190611106565b155b15610ad1576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610add84866111aa565b60008181526003602052604090205490915073ffffffffffffffffffffffffffffffffffffffff1680610b3f576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161040f565b60055473ffffffffffffffffffffffffffffffffffffffff168015610be9576040517ff1387e1600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063f1387e16903490610bb6908b908b9033906004016111e7565b6000604051808303818588803b158015610bcf57600080fd5b505af1158015610be3573d6000803e3d6000fd5b50505050505b6040517f3d3ac1b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff831690633d3ac1b590610c3f908a908a9033906004016111e7565b6000604051808303816000875af1158015610c5e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052610ca49190810190611250565b979650505050505050565b610cb7610d4a565b6004805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b69101610389565b610d3e610d4a565b610d4781610dcd565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610dcb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161040f565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610e4c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161040f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005b83811015610edd578181015183820152602001610ec5565b50506000910152565b60008151808452610efe816020860160208601610ec2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f436020830184610ee6565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff81168114610d4757600080fd5b600060208284031215610f7e57600080fd5b8135610f4381610f4a565b60008060008060608587031215610f9f57600080fd5b8435935060208501359250604085013567ffffffffffffffff80821115610fc557600080fd5b818701915087601f830112610fd957600080fd5b813581811115610fe857600080fd5b8860208260061b8501011115610ffd57600080fd5b95989497505060200194505050565b60006020828403121561101e57600080fd5b5035919050565b6000806020838503121561103857600080fd5b823567ffffffffffffffff8082111561105057600080fd5b818501915085601f83011261106457600080fd5b81358181111561107357600080fd5b86602082850101111561108557600080fd5b60209290920196919550909350505050565b8381526040602080830182905282820184905260009190859060608501845b878110156110f95783356110c981610f4a565b73ffffffffffffffffffffffffffffffffffffffff168252838301358383015292840192908401906001016110b6565b5098975050505050505050565b60006020828403121561111857600080fd5b81518015158114610f4357600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff841681526040602082015260006111a1604083018486611128565b95945050505050565b803560208310156111e1577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b165b92915050565b6040815260006111fb604083018587611128565b905073ffffffffffffffffffffffffffffffffffffffff83166020830152949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60006020828403121561126257600080fd5b815167ffffffffffffffff8082111561127a57600080fd5b818401915084601f83011261128e57600080fd5b8151818111156112a0576112a0611221565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156112e6576112e6611221565b816040528281528760208487010111156112ff57600080fd5b610ca4836020830160208801610ec256fea164736f6c6343000810000a", } var MercuryVerifierProxyABI = MercuryVerifierProxyMetaData.ABI @@ -171,9 +176,9 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorRaw) Transact(opts *b return _MercuryVerifierProxy.Contract.contract.Transact(opts, method, params...) } -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) GetAccessController(opts *bind.CallOpts) (common.Address, error) { +func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) { var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "getAccessController") + err := _MercuryVerifierProxy.contract.Call(opts, &out, "getVerifier", configDigest) if err != nil { return *new(common.Address), err @@ -185,17 +190,17 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) GetAccessController(opt } -func (_MercuryVerifierProxy *MercuryVerifierProxySession) GetAccessController() (common.Address, error) { - return _MercuryVerifierProxy.Contract.GetAccessController(&_MercuryVerifierProxy.CallOpts) +func (_MercuryVerifierProxy *MercuryVerifierProxySession) GetVerifier(configDigest [32]byte) (common.Address, error) { + return _MercuryVerifierProxy.Contract.GetVerifier(&_MercuryVerifierProxy.CallOpts, configDigest) } -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) GetAccessController() (common.Address, error) { - return _MercuryVerifierProxy.Contract.GetAccessController(&_MercuryVerifierProxy.CallOpts) +func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) GetVerifier(configDigest [32]byte) (common.Address, error) { + return _MercuryVerifierProxy.Contract.GetVerifier(&_MercuryVerifierProxy.CallOpts, configDigest) } -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) { +func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) Owner(opts *bind.CallOpts) (common.Address, error) { var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "getVerifier", configDigest) + err := _MercuryVerifierProxy.contract.Call(opts, &out, "owner") if err != nil { return *new(common.Address), err @@ -207,17 +212,17 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) GetVerifier(opts *bind. } -func (_MercuryVerifierProxy *MercuryVerifierProxySession) GetVerifier(configDigest [32]byte) (common.Address, error) { - return _MercuryVerifierProxy.Contract.GetVerifier(&_MercuryVerifierProxy.CallOpts, configDigest) +func (_MercuryVerifierProxy *MercuryVerifierProxySession) Owner() (common.Address, error) { + return _MercuryVerifierProxy.Contract.Owner(&_MercuryVerifierProxy.CallOpts) } -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) GetVerifier(configDigest [32]byte) (common.Address, error) { - return _MercuryVerifierProxy.Contract.GetVerifier(&_MercuryVerifierProxy.CallOpts, configDigest) +func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) Owner() (common.Address, error) { + return _MercuryVerifierProxy.Contract.Owner(&_MercuryVerifierProxy.CallOpts) } -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) Owner(opts *bind.CallOpts) (common.Address, error) { +func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) SAccessController(opts *bind.CallOpts) (common.Address, error) { var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "owner") + err := _MercuryVerifierProxy.contract.Call(opts, &out, "s_accessController") if err != nil { return *new(common.Address), err @@ -229,12 +234,34 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) Owner(opts *bind.CallOp } -func (_MercuryVerifierProxy *MercuryVerifierProxySession) Owner() (common.Address, error) { - return _MercuryVerifierProxy.Contract.Owner(&_MercuryVerifierProxy.CallOpts) +func (_MercuryVerifierProxy *MercuryVerifierProxySession) SAccessController() (common.Address, error) { + return _MercuryVerifierProxy.Contract.SAccessController(&_MercuryVerifierProxy.CallOpts) } -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) Owner() (common.Address, error) { - return _MercuryVerifierProxy.Contract.Owner(&_MercuryVerifierProxy.CallOpts) +func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) SAccessController() (common.Address, error) { + return _MercuryVerifierProxy.Contract.SAccessController(&_MercuryVerifierProxy.CallOpts) +} + +func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) SFeeManager(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _MercuryVerifierProxy.contract.Call(opts, &out, "s_feeManager") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_MercuryVerifierProxy *MercuryVerifierProxySession) SFeeManager() (common.Address, error) { + return _MercuryVerifierProxy.Contract.SFeeManager(&_MercuryVerifierProxy.CallOpts) +} + +func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) SFeeManager() (common.Address, error) { + return _MercuryVerifierProxy.Contract.SFeeManager(&_MercuryVerifierProxy.CallOpts) } func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { @@ -295,16 +322,28 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetAccessCon return _MercuryVerifierProxy.Contract.SetAccessController(&_MercuryVerifierProxy.TransactOpts, accessController) } -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "setVerifier", currentConfigDigest, newConfigDigest) +func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) SetFeeManager(opts *bind.TransactOpts, feeManager common.Address) (*types.Transaction, error) { + return _MercuryVerifierProxy.contract.Transact(opts, "setFeeManager", feeManager) +} + +func (_MercuryVerifierProxy *MercuryVerifierProxySession) SetFeeManager(feeManager common.Address) (*types.Transaction, error) { + return _MercuryVerifierProxy.Contract.SetFeeManager(&_MercuryVerifierProxy.TransactOpts, feeManager) } -func (_MercuryVerifierProxy *MercuryVerifierProxySession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetVerifier(&_MercuryVerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest) +func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetFeeManager(feeManager common.Address) (*types.Transaction, error) { + return _MercuryVerifierProxy.Contract.SetFeeManager(&_MercuryVerifierProxy.TransactOpts, feeManager) } -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetVerifier(&_MercuryVerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest) +func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _MercuryVerifierProxy.contract.Transact(opts, "setVerifier", currentConfigDigest, newConfigDigest, addressesAndWeights) +} + +func (_MercuryVerifierProxy *MercuryVerifierProxySession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _MercuryVerifierProxy.Contract.SetVerifier(&_MercuryVerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest, addressesAndWeights) +} + +func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _MercuryVerifierProxy.Contract.SetVerifier(&_MercuryVerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest, addressesAndWeights) } func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { @@ -331,16 +370,16 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) UnsetVerifie return _MercuryVerifierProxy.Contract.UnsetVerifier(&_MercuryVerifierProxy.TransactOpts, configDigest) } -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) Verify(opts *bind.TransactOpts, signedReport []byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "verify", signedReport) +func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) Verify(opts *bind.TransactOpts, payload []byte) (*types.Transaction, error) { + return _MercuryVerifierProxy.contract.Transact(opts, "verify", payload) } -func (_MercuryVerifierProxy *MercuryVerifierProxySession) Verify(signedReport []byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.Verify(&_MercuryVerifierProxy.TransactOpts, signedReport) +func (_MercuryVerifierProxy *MercuryVerifierProxySession) Verify(payload []byte) (*types.Transaction, error) { + return _MercuryVerifierProxy.Contract.Verify(&_MercuryVerifierProxy.TransactOpts, payload) } -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) Verify(signedReport []byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.Verify(&_MercuryVerifierProxy.TransactOpts, signedReport) +func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) Verify(payload []byte) (*types.Transaction, error) { + return _MercuryVerifierProxy.Contract.Verify(&_MercuryVerifierProxy.TransactOpts, payload) } type MercuryVerifierProxyAccessControllerSetIterator struct { @@ -461,6 +500,124 @@ func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseAccessController return event, nil } +type MercuryVerifierProxyFeeManagerSetIterator struct { + Event *MercuryVerifierProxyFeeManagerSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *MercuryVerifierProxyFeeManagerSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(MercuryVerifierProxyFeeManagerSet) + 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(MercuryVerifierProxyFeeManagerSet) + 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 *MercuryVerifierProxyFeeManagerSetIterator) Error() error { + return it.fail +} + +func (it *MercuryVerifierProxyFeeManagerSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type MercuryVerifierProxyFeeManagerSet struct { + OldFeeManager common.Address + NewFeeManager common.Address + Raw types.Log +} + +func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterFeeManagerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyFeeManagerSetIterator, error) { + + logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "FeeManagerSet") + if err != nil { + return nil, err + } + return &MercuryVerifierProxyFeeManagerSetIterator{contract: _MercuryVerifierProxy.contract, event: "FeeManagerSet", logs: logs, sub: sub}, nil +} + +func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchFeeManagerSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyFeeManagerSet) (event.Subscription, error) { + + logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "FeeManagerSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(MercuryVerifierProxyFeeManagerSet) + if err := _MercuryVerifierProxy.contract.UnpackLog(event, "FeeManagerSet", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseFeeManagerSet(log types.Log) (*MercuryVerifierProxyFeeManagerSet, error) { + event := new(MercuryVerifierProxyFeeManagerSet) + if err := _MercuryVerifierProxy.contract.UnpackLog(event, "FeeManagerSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type MercuryVerifierProxyOwnershipTransferRequestedIterator struct { Event *MercuryVerifierProxyOwnershipTransferRequested @@ -1091,6 +1248,8 @@ func (_MercuryVerifierProxy *MercuryVerifierProxy) ParseLog(log types.Log) (gene switch log.Topics[0] { case _MercuryVerifierProxy.abi.Events["AccessControllerSet"].ID: return _MercuryVerifierProxy.ParseAccessControllerSet(log) + case _MercuryVerifierProxy.abi.Events["FeeManagerSet"].ID: + return _MercuryVerifierProxy.ParseFeeManagerSet(log) case _MercuryVerifierProxy.abi.Events["OwnershipTransferRequested"].ID: return _MercuryVerifierProxy.ParseOwnershipTransferRequested(log) case _MercuryVerifierProxy.abi.Events["OwnershipTransferred"].ID: @@ -1111,6 +1270,10 @@ func (MercuryVerifierProxyAccessControllerSet) Topic() common.Hash { return common.HexToHash("0x953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b6") } +func (MercuryVerifierProxyFeeManagerSet) Topic() common.Hash { + return common.HexToHash("0x04628abcaa6b1674651352125cb94b65b289145bc2bc4d67720bb7d966372f03") +} + func (MercuryVerifierProxyOwnershipTransferRequested) Topic() common.Hash { return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") } @@ -1136,12 +1299,14 @@ func (_MercuryVerifierProxy *MercuryVerifierProxy) Address() common.Address { } type MercuryVerifierProxyInterface interface { - GetAccessController(opts *bind.CallOpts) (common.Address, error) - GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) Owner(opts *bind.CallOpts) (common.Address, error) + SAccessController(opts *bind.CallOpts) (common.Address, error) + + SFeeManager(opts *bind.CallOpts) (common.Address, error) + TypeAndVersion(opts *bind.CallOpts) (string, error) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) @@ -1150,13 +1315,15 @@ type MercuryVerifierProxyInterface interface { SetAccessController(opts *bind.TransactOpts, accessController common.Address) (*types.Transaction, error) - SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte) (*types.Transaction, error) + SetFeeManager(opts *bind.TransactOpts, feeManager common.Address) (*types.Transaction, error) + + SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) UnsetVerifier(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) - Verify(opts *bind.TransactOpts, signedReport []byte) (*types.Transaction, error) + Verify(opts *bind.TransactOpts, payload []byte) (*types.Transaction, error) FilterAccessControllerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyAccessControllerSetIterator, error) @@ -1164,6 +1331,12 @@ type MercuryVerifierProxyInterface interface { ParseAccessControllerSet(log types.Log) (*MercuryVerifierProxyAccessControllerSet, error) + FilterFeeManagerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyFeeManagerSetIterator, error) + + WatchFeeManagerSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyFeeManagerSet) (event.Subscription, error) + + ParseFeeManagerSet(log types.Log) (*MercuryVerifierProxyFeeManagerSet, error) + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierProxyOwnershipTransferRequestedIterator, error) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index ca1265dbaa6..e93ffb47b65 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -35,15 +35,10 @@ keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi .. keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 3423537dd5b4c8b42d693a7720053e7dc3ad64fbfab56fb4996c300d2bc26fa0 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 -llo_feeds: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 -llo_feeds_test: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 log_emitter: ../../contracts/solc/v0.8.19/LogEmitter.abi ../../contracts/solc/v0.8.19/LogEmitter.bin 244ba13730c036de0b02beef4e3d9c9a96946ce353c27f366baecc7f5be5a6fd log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin b16d9cafc51d85c4cd0b32fe0f53e37243b769585c5473c6f0e2c5db7dafc817 log_upkeep_counter_wrapper: ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin 13d6543329f89d06cbf3901d7f9ecdc42acc1a84d8c61db291fcbfdbe1138eb1 -mercury_exposed_verifier: ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/MercuryUpkeep.abi ../../contracts/solc/v0.8.16/MercuryUpkeep.bin f19fbcaf789578996cf7d5dc3c2adbad33b661c2d8bb71daf1b87b57a0678564 -mercury_verifier: ../../contracts/solc/v0.8.16/Verifier.abi ../../contracts/solc/v0.8.16/Verifier.bin 24b2db0d5db8e0198bb7eae2ecde65f2596df4bcc7b17d604d25300546c1694e -mercury_verifier_proxy: ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin 3b69ffe9c694e8551b5375c02b9e960adc985e2390566740e7fea70c89e436f1 mock_aggregator_proxy: ../../contracts/solc/v0.8.6/MockAggregatorProxy.abi ../../contracts/solc/v0.8.6/MockAggregatorProxy.bin b16c108f3dd384c342ddff5e94da7c0a8d39d1be5e3d8f2cf61ecc7f0e50ff42 mock_ethlink_aggregator_wrapper: ../../contracts/solc/v0.6/MockETHLINKAggregator.abi ../../contracts/solc/v0.6/MockETHLINKAggregator.bin 1c52c24f797b8482aa12b8251dcea1c072827bd5b3426b822621261944b99ca0 mock_gas_aggregator_wrapper: ../../contracts/solc/v0.6/MockGASAggregator.abi ../../contracts/solc/v0.6/MockGASAggregator.bin bacbb1ea4dc6beac0db8a13ca5c75e2fd61b903d70feea9b3b1c8b10fe8df4f3 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 9754b60cde0..0db49680d76 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -128,9 +128,7 @@ package gethwrappers //go:generate go generate ./functions // Mercury -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/Verifier.abi ../../contracts/solc/v0.8.16/Verifier.bin MercuryVerifier mercury_verifier -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin MercuryVerifierProxy mercury_verifier_proxy -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin MercuryExposedVerifier mercury_exposed_verifier +//go:generate go generate ./llo-feeds // Mocks that contain only events and functions to emit them // These contracts are used in testing Atlas flows. The contracts contain no logic, only events, structures, and functions to emit them. diff --git a/core/gethwrappers/go_generate_llo.go b/core/gethwrappers/go_generate_llo.go deleted file mode 100644 index 63628fe78de..00000000000 --- a/core/gethwrappers/go_generate_llo.go +++ /dev/null @@ -1,9 +0,0 @@ -// Package gethwrappers provides tools for wrapping solidity contracts with -// golang packages, using abigen. -package gethwrappers - -// Chainlink Functions (OCR2DR) -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/Verifier.abi ../../contracts/solc/v0.8.16/Verifier.bin LLOVerifier llo_feeds -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/VerifierProxy.abi ../../contracts/solc/v0.8.16/VerifierProxy.bin LLOVerifierProxy llo_feeds -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../contracts/solc/v0.8.16/ErroredVerifier.bin LLOErroredVerifier llo_feeds_test -//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../contracts/solc/v0.8.16/ExposedVerifier.bin LLOExposedVerifier llo_feeds_test diff --git a/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go b/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go new file mode 100644 index 00000000000..1f20f46b1a0 --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go @@ -0,0 +1,393 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package errored_verifier + +import ( + "errors" + "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" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + +var ErroredVerifierMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610ab7806100206000396000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c8063564a0a7a11610076578063b70d929d1161005b578063b70d929d14610180578063ded6307c146101b6578063e84f128e146101c957600080fd5b8063564a0a7a1461015a57806394d959801461016d57600080fd5b806301ffc9a7146100a85780633d3ac1b5146101125780633dd864301461013257806352ba27d614610147575b600080fd5b6100fd6100b6366004610571565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b610125610120366004610718565b6101ff565b6040516101099190610766565b6101456101403660046107d2565b610269565b005b61014561015536600461098b565b6102cb565b6101456101683660046107d2565b61032d565b61014561017b366004610a88565b61038f565b61019361018e3660046107d2565b6103f1565b604080519315158452602084019290925263ffffffff1690820152606001610109565b6101456101c4366004610a88565b610480565b6101dc6101d73660046107d2565b6104e2565b6040805163ffffffff948516815293909216602084015290820152606001610109565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4661696c656420746f207665726966790000000000000000000000000000000060448201526060906064015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4661696c656420746f20616374697661746520666565640000000000000000006044820152606401610260565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4661696c656420746f2073657420636f6e6669670000000000000000000000006044820152606401610260565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4661696c656420746f20646561637469766174652066656564000000000000006044820152606401610260565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f4661696c656420746f206465616374697661746520636f6e66696700000000006044820152606401610260565b60008060006040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610260906020808252602c908201527f4661696c656420746f20676574206c617465737420636f6e666967206469676560408201527f737420616e642065706f63680000000000000000000000000000000000000000606082015260800190565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4661696c656420746f20616374697661746520636f6e666967000000000000006044820152606401610260565b60008060006040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102609060208082526023908201527f4661696c656420746f20676574206c617465737420636f6e666967206465746160408201527f696c730000000000000000000000000000000000000000000000000000000000606082015260800190565b60006020828403121561058357600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146105b357600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561060c5761060c6105ba565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610659576106596105ba565b604052919050565b600082601f83011261067257600080fd5b813567ffffffffffffffff81111561068c5761068c6105ba565b6106bd60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610612565b8181528460208386010111156106d257600080fd5b816020850160208301376000918101602001919091529392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461071357600080fd5b919050565b6000806040838503121561072b57600080fd5b823567ffffffffffffffff81111561074257600080fd5b61074e85828601610661565b92505061075d602084016106ef565b90509250929050565b600060208083528351808285015260005b8181101561079357858101830151858201604001528201610777565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b6000602082840312156107e457600080fd5b5035919050565b600067ffffffffffffffff821115610805576108056105ba565b5060051b60200190565b600082601f83011261082057600080fd5b81356020610835610830836107eb565b610612565b82815260059290921b8401810191818101908684111561085457600080fd5b8286015b8481101561087657610869816106ef565b8352918301918301610858565b509695505050505050565b600082601f83011261089257600080fd5b813560206108a2610830836107eb565b82815260059290921b840181019181810190868411156108c157600080fd5b8286015b8481101561087657803583529183019183016108c5565b803560ff8116811461071357600080fd5b803567ffffffffffffffff8116811461071357600080fd5b600082601f83011261091657600080fd5b81356020610926610830836107eb565b82815260069290921b8401810191818101908684111561094557600080fd5b8286015b8481101561087657604081890312156109625760008081fd5b61096a6105e9565b610973826106ef565b81528185013585820152835291830191604001610949565b600080600080600080600080610100898b0312156109a857600080fd5b88359750602089013567ffffffffffffffff808211156109c757600080fd5b6109d38c838d0161080f565b985060408b01359150808211156109e957600080fd5b6109f58c838d01610881565b9750610a0360608c016108dc565b965060808b0135915080821115610a1957600080fd5b610a258c838d01610661565b9550610a3360a08c016108ed565b945060c08b0135915080821115610a4957600080fd5b610a558c838d01610661565b935060e08b0135915080821115610a6b57600080fd5b50610a788b828c01610905565b9150509295985092959890939650565b60008060408385031215610a9b57600080fd5b5050803592602090910135915056fea164736f6c6343000810000a", +} + +var ErroredVerifierABI = ErroredVerifierMetaData.ABI + +var ErroredVerifierBin = ErroredVerifierMetaData.Bin + +func DeployErroredVerifier(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *ErroredVerifier, error) { + parsed, err := ErroredVerifierMetaData.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(ErroredVerifierBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &ErroredVerifier{ErroredVerifierCaller: ErroredVerifierCaller{contract: contract}, ErroredVerifierTransactor: ErroredVerifierTransactor{contract: contract}, ErroredVerifierFilterer: ErroredVerifierFilterer{contract: contract}}, nil +} + +type ErroredVerifier struct { + address common.Address + abi abi.ABI + ErroredVerifierCaller + ErroredVerifierTransactor + ErroredVerifierFilterer +} + +type ErroredVerifierCaller struct { + contract *bind.BoundContract +} + +type ErroredVerifierTransactor struct { + contract *bind.BoundContract +} + +type ErroredVerifierFilterer struct { + contract *bind.BoundContract +} + +type ErroredVerifierSession struct { + Contract *ErroredVerifier + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type ErroredVerifierCallerSession struct { + Contract *ErroredVerifierCaller + CallOpts bind.CallOpts +} + +type ErroredVerifierTransactorSession struct { + Contract *ErroredVerifierTransactor + TransactOpts bind.TransactOpts +} + +type ErroredVerifierRaw struct { + Contract *ErroredVerifier +} + +type ErroredVerifierCallerRaw struct { + Contract *ErroredVerifierCaller +} + +type ErroredVerifierTransactorRaw struct { + Contract *ErroredVerifierTransactor +} + +func NewErroredVerifier(address common.Address, backend bind.ContractBackend) (*ErroredVerifier, error) { + abi, err := abi.JSON(strings.NewReader(ErroredVerifierABI)) + if err != nil { + return nil, err + } + contract, err := bindErroredVerifier(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &ErroredVerifier{address: address, abi: abi, ErroredVerifierCaller: ErroredVerifierCaller{contract: contract}, ErroredVerifierTransactor: ErroredVerifierTransactor{contract: contract}, ErroredVerifierFilterer: ErroredVerifierFilterer{contract: contract}}, nil +} + +func NewErroredVerifierCaller(address common.Address, caller bind.ContractCaller) (*ErroredVerifierCaller, error) { + contract, err := bindErroredVerifier(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &ErroredVerifierCaller{contract: contract}, nil +} + +func NewErroredVerifierTransactor(address common.Address, transactor bind.ContractTransactor) (*ErroredVerifierTransactor, error) { + contract, err := bindErroredVerifier(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &ErroredVerifierTransactor{contract: contract}, nil +} + +func NewErroredVerifierFilterer(address common.Address, filterer bind.ContractFilterer) (*ErroredVerifierFilterer, error) { + contract, err := bindErroredVerifier(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &ErroredVerifierFilterer{contract: contract}, nil +} + +func bindErroredVerifier(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := ErroredVerifierMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_ErroredVerifier *ErroredVerifierRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _ErroredVerifier.Contract.ErroredVerifierCaller.contract.Call(opts, result, method, params...) +} + +func (_ErroredVerifier *ErroredVerifierRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _ErroredVerifier.Contract.ErroredVerifierTransactor.contract.Transfer(opts) +} + +func (_ErroredVerifier *ErroredVerifierRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _ErroredVerifier.Contract.ErroredVerifierTransactor.contract.Transact(opts, method, params...) +} + +func (_ErroredVerifier *ErroredVerifierCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _ErroredVerifier.Contract.contract.Call(opts, result, method, params...) +} + +func (_ErroredVerifier *ErroredVerifierTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _ErroredVerifier.Contract.contract.Transfer(opts) +} + +func (_ErroredVerifier *ErroredVerifierTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _ErroredVerifier.Contract.contract.Transact(opts, method, params...) +} + +func (_ErroredVerifier *ErroredVerifierCaller) ActivateConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 [32]byte) error { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "activateConfig", arg0, arg1) + + if err != nil { + return err + } + + return err + +} + +func (_ErroredVerifier *ErroredVerifierSession) ActivateConfig(arg0 [32]byte, arg1 [32]byte) error { + return _ErroredVerifier.Contract.ActivateConfig(&_ErroredVerifier.CallOpts, arg0, arg1) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) ActivateConfig(arg0 [32]byte, arg1 [32]byte) error { + return _ErroredVerifier.Contract.ActivateConfig(&_ErroredVerifier.CallOpts, arg0, arg1) +} + +func (_ErroredVerifier *ErroredVerifierCaller) ActivateFeed(opts *bind.CallOpts, arg0 [32]byte) error { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "activateFeed", arg0) + + if err != nil { + return err + } + + return err + +} + +func (_ErroredVerifier *ErroredVerifierSession) ActivateFeed(arg0 [32]byte) error { + return _ErroredVerifier.Contract.ActivateFeed(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) ActivateFeed(arg0 [32]byte) error { + return _ErroredVerifier.Contract.ActivateFeed(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCaller) DeactivateConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 [32]byte) error { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "deactivateConfig", arg0, arg1) + + if err != nil { + return err + } + + return err + +} + +func (_ErroredVerifier *ErroredVerifierSession) DeactivateConfig(arg0 [32]byte, arg1 [32]byte) error { + return _ErroredVerifier.Contract.DeactivateConfig(&_ErroredVerifier.CallOpts, arg0, arg1) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) DeactivateConfig(arg0 [32]byte, arg1 [32]byte) error { + return _ErroredVerifier.Contract.DeactivateConfig(&_ErroredVerifier.CallOpts, arg0, arg1) +} + +func (_ErroredVerifier *ErroredVerifierCaller) DeactivateFeed(opts *bind.CallOpts, arg0 [32]byte) error { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "deactivateFeed", arg0) + + if err != nil { + return err + } + + return err + +} + +func (_ErroredVerifier *ErroredVerifierSession) DeactivateFeed(arg0 [32]byte) error { + return _ErroredVerifier.Contract.DeactivateFeed(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) DeactivateFeed(arg0 [32]byte) error { + return _ErroredVerifier.Contract.DeactivateFeed(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCaller) LatestConfigDetails(opts *bind.CallOpts, arg0 [32]byte) (uint32, uint32, [32]byte, error) { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "latestConfigDetails", arg0) + + if err != nil { + return *new(uint32), *new(uint32), *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + out1 := *abi.ConvertType(out[1], new(uint32)).(*uint32) + out2 := *abi.ConvertType(out[2], new([32]byte)).(*[32]byte) + + return out0, out1, out2, err + +} + +func (_ErroredVerifier *ErroredVerifierSession) LatestConfigDetails(arg0 [32]byte) (uint32, uint32, [32]byte, error) { + return _ErroredVerifier.Contract.LatestConfigDetails(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) LatestConfigDetails(arg0 [32]byte) (uint32, uint32, [32]byte, error) { + return _ErroredVerifier.Contract.LatestConfigDetails(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCaller) LatestConfigDigestAndEpoch(opts *bind.CallOpts, arg0 [32]byte) (bool, [32]byte, uint32, error) { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "latestConfigDigestAndEpoch", arg0) + + if err != nil { + return *new(bool), *new([32]byte), *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + out1 := *abi.ConvertType(out[1], new([32]byte)).(*[32]byte) + out2 := *abi.ConvertType(out[2], new(uint32)).(*uint32) + + return out0, out1, out2, err + +} + +func (_ErroredVerifier *ErroredVerifierSession) LatestConfigDigestAndEpoch(arg0 [32]byte) (bool, [32]byte, uint32, error) { + return _ErroredVerifier.Contract.LatestConfigDigestAndEpoch(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) LatestConfigDigestAndEpoch(arg0 [32]byte) (bool, [32]byte, uint32, error) { + return _ErroredVerifier.Contract.LatestConfigDigestAndEpoch(&_ErroredVerifier.CallOpts, arg0) +} + +func (_ErroredVerifier *ErroredVerifierCaller) SetConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 []common.Address, arg2 [][32]byte, arg3 uint8, arg4 []byte, arg5 uint64, arg6 []byte, arg7 []CommonAddressAndWeight) error { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "setConfig", arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) + + if err != nil { + return err + } + + return err + +} + +func (_ErroredVerifier *ErroredVerifierSession) SetConfig(arg0 [32]byte, arg1 []common.Address, arg2 [][32]byte, arg3 uint8, arg4 []byte, arg5 uint64, arg6 []byte, arg7 []CommonAddressAndWeight) error { + return _ErroredVerifier.Contract.SetConfig(&_ErroredVerifier.CallOpts, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) SetConfig(arg0 [32]byte, arg1 []common.Address, arg2 [][32]byte, arg3 uint8, arg4 []byte, arg5 uint64, arg6 []byte, arg7 []CommonAddressAndWeight) error { + return _ErroredVerifier.Contract.SetConfig(&_ErroredVerifier.CallOpts, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) +} + +func (_ErroredVerifier *ErroredVerifierCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _ErroredVerifier.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 (_ErroredVerifier *ErroredVerifierSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _ErroredVerifier.Contract.SupportsInterface(&_ErroredVerifier.CallOpts, interfaceId) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _ErroredVerifier.Contract.SupportsInterface(&_ErroredVerifier.CallOpts, interfaceId) +} + +func (_ErroredVerifier *ErroredVerifierCaller) Verify(opts *bind.CallOpts, arg0 []byte, arg1 common.Address) ([]byte, error) { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "verify", arg0, arg1) + + if err != nil { + return *new([]byte), err + } + + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) + + return out0, err + +} + +func (_ErroredVerifier *ErroredVerifierSession) Verify(arg0 []byte, arg1 common.Address) ([]byte, error) { + return _ErroredVerifier.Contract.Verify(&_ErroredVerifier.CallOpts, arg0, arg1) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) Verify(arg0 []byte, arg1 common.Address) ([]byte, error) { + return _ErroredVerifier.Contract.Verify(&_ErroredVerifier.CallOpts, arg0, arg1) +} + +func (_ErroredVerifier *ErroredVerifier) Address() common.Address { + return _ErroredVerifier.address +} + +type ErroredVerifierInterface interface { + ActivateConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 [32]byte) error + + ActivateFeed(opts *bind.CallOpts, arg0 [32]byte) error + + DeactivateConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 [32]byte) error + + DeactivateFeed(opts *bind.CallOpts, arg0 [32]byte) error + + LatestConfigDetails(opts *bind.CallOpts, arg0 [32]byte) (uint32, uint32, [32]byte, error) + + LatestConfigDigestAndEpoch(opts *bind.CallOpts, arg0 [32]byte) (bool, [32]byte, uint32, error) + + SetConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 []common.Address, arg2 [][32]byte, arg3 uint8, arg4 []byte, arg5 uint64, arg6 []byte, arg7 []CommonAddressAndWeight) error + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + Verify(opts *bind.CallOpts, arg0 []byte, arg1 common.Address) ([]byte, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/exposed_verifier/exposed_verifier.go b/core/gethwrappers/llo-feeds/generated/exposed_verifier/exposed_verifier.go new file mode 100644 index 00000000000..2ca74b7cf3d --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/exposed_verifier/exposed_verifier.go @@ -0,0 +1,202 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package exposed_verifier + +import ( + "errors" + "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" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var ExposedVerifierMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_feedId\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_chainId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"_configCount\",\"type\":\"uint64\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"_offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_encodedConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_encodedConfig\",\"type\":\"bytes\"}],\"name\":\"exposedConfigDigestFromConfigData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610696806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80630ebd702314610030575b600080fd5b61004361003e3660046103f7565b610055565b60405190815260200160405180910390f35b60006100a18c8c8c8c8c8c8c8c8c8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508e92508d91506100b19050565b9c9b505050505050505050505050565b6000808b8b8b8b8b8b8b8b8b8b6040516020016100d79a999897969594939291906105a7565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e06000000000000000000000000000000000000000000000000000000000000179150509a9950505050505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461018357600080fd5b919050565b803567ffffffffffffffff8116811461018357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610216576102166101a0565b604052919050565b600067ffffffffffffffff821115610238576102386101a0565b5060051b60200190565b600082601f83011261025357600080fd5b813560206102686102638361021e565b6101cf565b82815260059290921b8401810191818101908684111561028757600080fd5b8286015b848110156102a95761029c8161015f565b835291830191830161028b565b509695505050505050565b600082601f8301126102c557600080fd5b813560206102d56102638361021e565b82815260059290921b840181019181810190868411156102f457600080fd5b8286015b848110156102a957803583529183019183016102f8565b803560ff8116811461018357600080fd5b60008083601f84011261033257600080fd5b50813567ffffffffffffffff81111561034a57600080fd5b60208301915083602082850101111561036257600080fd5b9250929050565b600082601f83011261037a57600080fd5b813567ffffffffffffffff811115610394576103946101a0565b6103c560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016101cf565b8181528460208386010111156103da57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060008060006101408c8e03121561041957600080fd5b8b359a5060208c0135995061043060408d0161015f565b985061043e60608d01610188565b975067ffffffffffffffff8060808e0135111561045a57600080fd5b61046a8e60808f01358f01610242565b97508060a08e0135111561047d57600080fd5b61048d8e60a08f01358f016102b4565b965061049b60c08e0161030f565b95508060e08e013511156104ae57600080fd5b6104be8e60e08f01358f01610320565b90955093506104d06101008e01610188565b9250806101208e013511156104e457600080fd5b506104f68d6101208e01358e01610369565b90509295989b509295989b9093969950565b600081518084526020808501945080840160005b838110156105385781518752958201959082019060010161051c565b509495945050505050565b6000815180845260005b818110156105695760208185018101518683018201520161054d565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b8a815260208082018b905273ffffffffffffffffffffffffffffffffffffffff8a8116604084015267ffffffffffffffff8a1660608401526101406080840181905289519084018190526000926101608501928b820192855b8181101561061e578451831686529483019493830193600101610600565b505050505082810360a08401526106358189610508565b60ff881660c0850152905082810360e08401526106528187610543565b67ffffffffffffffff861661010085015290508281036101208401526106788185610543565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", +} + +var ExposedVerifierABI = ExposedVerifierMetaData.ABI + +var ExposedVerifierBin = ExposedVerifierMetaData.Bin + +func DeployExposedVerifier(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *ExposedVerifier, error) { + parsed, err := ExposedVerifierMetaData.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(ExposedVerifierBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &ExposedVerifier{ExposedVerifierCaller: ExposedVerifierCaller{contract: contract}, ExposedVerifierTransactor: ExposedVerifierTransactor{contract: contract}, ExposedVerifierFilterer: ExposedVerifierFilterer{contract: contract}}, nil +} + +type ExposedVerifier struct { + address common.Address + abi abi.ABI + ExposedVerifierCaller + ExposedVerifierTransactor + ExposedVerifierFilterer +} + +type ExposedVerifierCaller struct { + contract *bind.BoundContract +} + +type ExposedVerifierTransactor struct { + contract *bind.BoundContract +} + +type ExposedVerifierFilterer struct { + contract *bind.BoundContract +} + +type ExposedVerifierSession struct { + Contract *ExposedVerifier + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type ExposedVerifierCallerSession struct { + Contract *ExposedVerifierCaller + CallOpts bind.CallOpts +} + +type ExposedVerifierTransactorSession struct { + Contract *ExposedVerifierTransactor + TransactOpts bind.TransactOpts +} + +type ExposedVerifierRaw struct { + Contract *ExposedVerifier +} + +type ExposedVerifierCallerRaw struct { + Contract *ExposedVerifierCaller +} + +type ExposedVerifierTransactorRaw struct { + Contract *ExposedVerifierTransactor +} + +func NewExposedVerifier(address common.Address, backend bind.ContractBackend) (*ExposedVerifier, error) { + abi, err := abi.JSON(strings.NewReader(ExposedVerifierABI)) + if err != nil { + return nil, err + } + contract, err := bindExposedVerifier(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &ExposedVerifier{address: address, abi: abi, ExposedVerifierCaller: ExposedVerifierCaller{contract: contract}, ExposedVerifierTransactor: ExposedVerifierTransactor{contract: contract}, ExposedVerifierFilterer: ExposedVerifierFilterer{contract: contract}}, nil +} + +func NewExposedVerifierCaller(address common.Address, caller bind.ContractCaller) (*ExposedVerifierCaller, error) { + contract, err := bindExposedVerifier(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &ExposedVerifierCaller{contract: contract}, nil +} + +func NewExposedVerifierTransactor(address common.Address, transactor bind.ContractTransactor) (*ExposedVerifierTransactor, error) { + contract, err := bindExposedVerifier(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &ExposedVerifierTransactor{contract: contract}, nil +} + +func NewExposedVerifierFilterer(address common.Address, filterer bind.ContractFilterer) (*ExposedVerifierFilterer, error) { + contract, err := bindExposedVerifier(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &ExposedVerifierFilterer{contract: contract}, nil +} + +func bindExposedVerifier(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := ExposedVerifierMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_ExposedVerifier *ExposedVerifierRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _ExposedVerifier.Contract.ExposedVerifierCaller.contract.Call(opts, result, method, params...) +} + +func (_ExposedVerifier *ExposedVerifierRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _ExposedVerifier.Contract.ExposedVerifierTransactor.contract.Transfer(opts) +} + +func (_ExposedVerifier *ExposedVerifierRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _ExposedVerifier.Contract.ExposedVerifierTransactor.contract.Transact(opts, method, params...) +} + +func (_ExposedVerifier *ExposedVerifierCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _ExposedVerifier.Contract.contract.Call(opts, result, method, params...) +} + +func (_ExposedVerifier *ExposedVerifierTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _ExposedVerifier.Contract.contract.Transfer(opts) +} + +func (_ExposedVerifier *ExposedVerifierTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _ExposedVerifier.Contract.contract.Transact(opts, method, params...) +} + +func (_ExposedVerifier *ExposedVerifierCaller) ExposedConfigDigestFromConfigData(opts *bind.CallOpts, _feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { + var out []interface{} + err := _ExposedVerifier.contract.Call(opts, &out, "exposedConfigDigestFromConfigData", _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_ExposedVerifier *ExposedVerifierSession) ExposedConfigDigestFromConfigData(_feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { + return _ExposedVerifier.Contract.ExposedConfigDigestFromConfigData(&_ExposedVerifier.CallOpts, _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) +} + +func (_ExposedVerifier *ExposedVerifierCallerSession) ExposedConfigDigestFromConfigData(_feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { + return _ExposedVerifier.Contract.ExposedConfigDigestFromConfigData(&_ExposedVerifier.CallOpts, _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) +} + +func (_ExposedVerifier *ExposedVerifier) Address() common.Address { + return _ExposedVerifier.address +} + +type ExposedVerifierInterface interface { + ExposedConfigDigestFromConfigData(opts *bind.CallOpts, _feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go b/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go new file mode 100644 index 00000000000..9957546c42c --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go @@ -0,0 +1,1318 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package fee_manager + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + +type CommonAsset struct { + AssetAddress common.Address + Amount *big.Int +} + +type IFeeManagerQuote struct { + QuoteAddress common.Address +} + +var FeeManagerMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_nativeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_proxyAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_rewardManagerAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ExpiredReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDeposit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDiscount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidQuote\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReportVersion\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSurcharge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nativeQuantity\",\"type\":\"uint256\"}],\"name\":\"InsufficientLink\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newSurcharge\",\"type\":\"uint256\"}],\"name\":\"NativeSurchargeUpdated\",\"type\":\"event\"},{\"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\":\"subscriber\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"SubscriberDiscountUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"quoteAddress\",\"type\":\"address\"}],\"internalType\":\"structIFeeManager.Quote\",\"name\":\"quote\",\"type\":\"tuple\"}],\"name\":\"getFeeAndReward\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkAvailableForPayment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"}],\"name\":\"processFee\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_nativeSurcharge\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_subscriberDiscounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setFeeRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"surcharge\",\"type\":\"uint256\"}],\"name\":\"setNativeSurcharge\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"updateSubscriberDiscount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101006040523480156200001257600080fd5b506040516200259938038062002599833981016040819052620000359162000288565b33806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf81620001c0565b5050506001600160a01b0384161580620000e057506001600160a01b038316155b80620000f357506001600160a01b038216155b806200010657506001600160a01b038116155b15620001255760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03848116608081905284821660a05283821660c05290821660e081905260405163095ea7b360e01b81526004810191909152600019602482015263095ea7b3906044016020604051808303816000875af11580156200018f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001b59190620002e5565b505050505062000310565b336001600160a01b038216036200021a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200028357600080fd5b919050565b600080600080608085870312156200029f57600080fd5b620002aa856200026b565b9350620002ba602086016200026b565b9250620002ca604086016200026b565b9150620002da606086016200026b565b905092959194509250565b600060208284031215620002f857600080fd5b815180151581146200030957600080fd5b9392505050565b60805160a05160c05160e0516121ed620003ac6000396000818161041b01528181610f38015261118e0152600081816103840152610bc50152600081816106b301528181610706015281816109c501528181610d3001528181610df701526112fa0152600081816106d8015281816107610152818161095001528181610b0501528181610eb70152818161107a01526112a301526121ed6000f3fe6080604052600436106100dd5760003560e01c80638da5cb5b1161007f578063f1387e1611610059578063f1387e16146102d6578063f237f1a8146102e9578063f2fde38b14610309578063f3fef3a31461032957600080fd5b80638da5cb5b1461025e578063c541cbde14610293578063d09dc339146102c157600080fd5b806369fd2b34116100bb57806369fd2b34146101c95780636b54d8a6146101eb57806379ba50971461020b57806387d6d8431461022057600080fd5b806301ffc9a7146100e2578063181f5a771461015957806332f5f746146101a5575b600080fd5b3480156100ee57600080fd5b506101446100fd36600461175e565b7fffffffff00000000000000000000000000000000000000000000000000000000167ff1387e16000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b34801561016557600080fd5b50604080518082018252601081527f4665654d616e6167657220302e302e31000000000000000000000000000000006020820152905161015091906117a7565b3480156101b157600080fd5b506101bb60035481565b604051908152602001610150565b3480156101d557600080fd5b506101e96101e4366004611813565b610349565b005b3480156101f757600080fd5b506101e9610206366004611892565b61048b565b34801561021757600080fd5b506101e9610510565b34801561022c57600080fd5b506101bb61023b3660046118cd565b600260209081526000938452604080852082529284528284209052825290205481565b34801561026a57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610150565b34801561029f57600080fd5b506102b36102ae366004611a44565b610612565b604051610150929190611ae5565b3480156102cd57600080fd5b506101bb610ad4565b6101e96102e4366004611b39565b610b8a565b3480156102f557600080fd5b506101e9610304366004611bb1565b611257565b34801561031557600080fd5b506101e9610324366004611bf9565b6113fe565b34801561033557600080fd5b506101e9610344366004611c16565b611412565b60005473ffffffffffffffffffffffffffffffffffffffff1633148015906103a757503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b156103de576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f633b5f6e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063633b5f6e9061045490869086908690600401611c42565b600060405180830381600087803b15801561046e57600080fd5b505af1158015610482573d6000803e3d6000fd5b50505050505050565b6104936115ac565b670de0b6b3a76400008111156104d5576040517f05e8ac2900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60038190556040518181527fa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e19060200160405180910390a150565b60015473ffffffffffffffffffffffffffffffffffffffff163314610596576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6040805180820190915260008082526020820152604080518082019091526000808252602082015260408051808201909152600080825260208201526040805180820190915260008082526020820152600061066d87611cb1565b90507fffff00000000000000000000000000000000000000000000000000000000000080821690810161070457505073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000811683527f00000000000000000000000000000000000000000000000000000000000000001681529092509050610acc565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff16141580156107b457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff1614155b156107eb576040517ff861803000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080807ffffe000000000000000000000000000000000000000000000000000000000000840161085d578a80602001905181019061082a9190611d49565b77ffffffffffffffffffffffffffffffffffffffffffffffff918216995016965063ffffffff1694506108ff9350505050565b7ffffd00000000000000000000000000000000000000000000000000000000000084016108cd578a8060200190518101906108989190611dc8565b77ffffffffffffffffffffffffffffffffffffffffffffffff9182169b5016985063ffffffff1696506108ff95505050505050565b6040517f52762c7400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b42811015610939576040517fb6c405f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116808852602088018590528b51909116036109ae57855173ffffffffffffffffffffffffffffffffffffffff16875260208087015190880152610a1e565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168752600354610a1890610a0090670de0b6b3a7640000611e98565b610a0a9084611eab565b670de0b6b3a764000061162f565b60208801525b73ffffffffffffffffffffffffffffffffffffffff808d16600090815260026020908152604080832089845282528083208e5190941683529281529190205490880151670de0b6b3a764000090610a76908390611eab565b610a809190611ee8565b8860200151610a8f9190611f23565b886020018181525050610aab818860200151610a0a9190611eab565b8760200151610aba9190611f23565b60208801525095975093955050505050505b935093915050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610b61573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b859190611f36565b905090565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610be857503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b15610c1f576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff821603610c6e576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610c7c83850185611fbd565b915050600081610c8b90611cb1565b6040805160208101909152600081529091507e010000000000000000000000000000000000000000000000000000000000007fffff000000000000000000000000000000000000000000000000000000000000831614610d12576000610cf38688018861208c565b9550505050505080806020019051810190610d0e9190612154565b9150505b600080610d20338685610612565b91509150600034600014610e84577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614610db7576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3483602001511115610df5576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db084602001516040518263ffffffff1660e01b81526004016000604051808303818588803b158015610e6157600080fd5b505af1158015610e75573d6000803e3d6000fd5b50505050508260200151340390505b6000610e90898b612182565b9050836020015160001461120057835173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116911603610f9b5760208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8a8116602483015260448201929092527f00000000000000000000000000000000000000000000000000000000000000009091169063efb03fe990606401600060405180830381600087803b158015610f7e57600080fd5b505af1158015610f92573d6000803e3d6000fd5b50505050611200565b3460000361104c57835160208501516040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8b8116600483015230602483015260448201929092529116906323b872dd906064016020604051808303816000875af1158015611026573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061104a91906121be565b505b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa1580156110d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110fa9190611f36565b8360200151111561114c5760208084015185820151604080519283529282015282917feb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7910160405180910390a2611200565b60208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905230602482015260448101919091527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063efb03fe990606401600060405180830381600087803b1580156111e757600080fd5b505af11580156111fb573d6000803e3d6000fd5b505050505b811561124b5760405173ffffffffffffffffffffffffffffffffffffffff89169083156108fc029084906000818181858888f19350505050158015611249573d6000803e3d6000fd5b505b50505050505050505050565b61125f6115ac565b670de0b6b3a76400008111156112a1576040517f997ea36000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415801561134957507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b15611380576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84811660008181526002602090815260408083208884528252808320948716808452948252918290208590558151938452830184905285927f41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84910160405180910390a350505050565b6114066115ac565b61140f81611669565b50565b61141a6115ac565b73ffffffffffffffffffffffffffffffffffffffff8216611480576000805460405173ffffffffffffffffffffffffffffffffffffffff9091169183156108fc02918491818181858888f1935050505015801561147b573d6000803e3d6000fd5b505050565b8173ffffffffffffffffffffffffffffffffffffffff1663a9059cbb6114bb60005473ffffffffffffffffffffffffffffffffffffffff1690565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af115801561152d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061155191906121be565b506040805133815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb9060600160405180910390a15050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461162d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161058d565b565b6000821561165d5781611643600185611f23565b61164d9190611ee8565b611658906001611e98565b611660565b60005b90505b92915050565b3373ffffffffffffffffffffffffffffffffffffffff8216036116e8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161058d565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561177057600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146117a057600080fd5b9392505050565b600060208083528351808285015260005b818110156117d4578581018301518582016040015282016117b8565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60008060006040848603121561182857600080fd5b83359250602084013567ffffffffffffffff8082111561184757600080fd5b818601915086601f83011261185b57600080fd5b81358181111561186a57600080fd5b8760208260061b850101111561187f57600080fd5b6020830194508093505050509250925092565b6000602082840312156118a457600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461140f57600080fd5b6000806000606084860312156118e257600080fd5b83356118ed816118ab565b9250602084013591506040840135611904816118ab565b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516020810167ffffffffffffffff811182821017156119615761196161190f565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156119ae576119ae61190f565b604052919050565b600082601f8301126119c757600080fd5b813567ffffffffffffffff8111156119e1576119e161190f565b611a1260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611967565b818152846020838601011115611a2757600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008385036060811215611a5a57600080fd5b8435611a65816118ab565b9350602085013567ffffffffffffffff811115611a8157600080fd5b611a8d878288016119b6565b93505060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc082011215611ac057600080fd5b50611ac961193e565b6040850135611ad7816118ab565b815292959194509192509050565b825173ffffffffffffffffffffffffffffffffffffffff1681526020808401519082015260808101825173ffffffffffffffffffffffffffffffffffffffff166040830152602083015160608301526117a0565b600080600060408486031215611b4e57600080fd5b833567ffffffffffffffff80821115611b6657600080fd5b818601915086601f830112611b7a57600080fd5b813581811115611b8957600080fd5b876020828501011115611b9b57600080fd5b60209283019550935050840135611904816118ab565b60008060008060808587031215611bc757600080fd5b8435611bd2816118ab565b9350602085013592506040850135611be9816118ab565b9396929550929360600135925050565b600060208284031215611c0b57600080fd5b81356117a0816118ab565b60008060408385031215611c2957600080fd5b8235611c34816118ab565b946020939093013593505050565b8381526040602080830182905282820184905260009190859060608501845b87811015611ca4578335611c74816118ab565b73ffffffffffffffffffffffffffffffffffffffff16825283830135838301529284019290840190600101611c61565b5098975050505050505050565b80516020808301519190811015611cf0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805163ffffffff81168114611d0a57600080fd5b919050565b8051601781900b8114611d0a57600080fd5b805177ffffffffffffffffffffffffffffffffffffffffffffffff81168114611d0a57600080fd5b600080600080600080600060e0888a031215611d6457600080fd5b87519650611d7460208901611cf6565b9550611d8260408901611d0f565b9450611d9060608901611cf6565b9350611d9e60808901611cf6565b9250611dac60a08901611d21565b9150611dba60c08901611d21565b905092959891949750929550565b60008060008060008060008060006101208a8c031215611de757600080fd5b89519850611df760208b01611cf6565b9750611e0560408b01611d0f565b9650611e1360608b01611d0f565b9550611e2160808b01611d0f565b9450611e2f60a08b01611cf6565b9350611e3d60c08b01611cf6565b9250611e4b60e08b01611d21565b9150611e5a6101008b01611d21565b90509295985092959850929598565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561166357611663611e69565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611ee357611ee3611e69565b500290565b600082611f1e577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b8181038181111561166357611663611e69565b600060208284031215611f4857600080fd5b5051919050565b600082601f830112611f6057600080fd5b6040516060810181811067ffffffffffffffff82111715611f8357611f8361190f565b604052806060840185811115611f9857600080fd5b845b81811015611fb2578035835260209283019201611f9a565b509195945050505050565b60008060808385031215611fd057600080fd5b611fda8484611f4f565b9150606083013567ffffffffffffffff811115611ff657600080fd5b612002858286016119b6565b9150509250929050565b600082601f83011261201d57600080fd5b8135602067ffffffffffffffff8211156120395761203961190f565b8160051b612048828201611967565b928352848101820192828101908785111561206257600080fd5b83870192505b8483101561208157823582529183019190830190612068565b979650505050505050565b60008060008060008061010087890312156120a657600080fd5b6120b08888611f4f565b9550606087013567ffffffffffffffff808211156120cd57600080fd5b6120d98a838b016119b6565b965060808901359150808211156120ef57600080fd5b6120fb8a838b0161200c565b955060a089013591508082111561211157600080fd5b61211d8a838b0161200c565b945060c0890135935060e089013591508082111561213a57600080fd5b5061214789828a016119b6565b9150509295509295509295565b60006020828403121561216657600080fd5b61216e61193e565b8251612179816118ab565b81529392505050565b80356020831015611663577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b6000602082840312156121d057600080fd5b815180151581146117a057600080fdfea164736f6c6343000810000a", +} + +var FeeManagerABI = FeeManagerMetaData.ABI + +var FeeManagerBin = FeeManagerMetaData.Bin + +func DeployFeeManager(auth *bind.TransactOpts, backend bind.ContractBackend, _linkAddress common.Address, _nativeAddress common.Address, _proxyAddress common.Address, _rewardManagerAddress common.Address) (common.Address, *types.Transaction, *FeeManager, error) { + parsed, err := FeeManagerMetaData.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(FeeManagerBin), backend, _linkAddress, _nativeAddress, _proxyAddress, _rewardManagerAddress) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &FeeManager{FeeManagerCaller: FeeManagerCaller{contract: contract}, FeeManagerTransactor: FeeManagerTransactor{contract: contract}, FeeManagerFilterer: FeeManagerFilterer{contract: contract}}, nil +} + +type FeeManager struct { + address common.Address + abi abi.ABI + FeeManagerCaller + FeeManagerTransactor + FeeManagerFilterer +} + +type FeeManagerCaller struct { + contract *bind.BoundContract +} + +type FeeManagerTransactor struct { + contract *bind.BoundContract +} + +type FeeManagerFilterer struct { + contract *bind.BoundContract +} + +type FeeManagerSession struct { + Contract *FeeManager + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type FeeManagerCallerSession struct { + Contract *FeeManagerCaller + CallOpts bind.CallOpts +} + +type FeeManagerTransactorSession struct { + Contract *FeeManagerTransactor + TransactOpts bind.TransactOpts +} + +type FeeManagerRaw struct { + Contract *FeeManager +} + +type FeeManagerCallerRaw struct { + Contract *FeeManagerCaller +} + +type FeeManagerTransactorRaw struct { + Contract *FeeManagerTransactor +} + +func NewFeeManager(address common.Address, backend bind.ContractBackend) (*FeeManager, error) { + abi, err := abi.JSON(strings.NewReader(FeeManagerABI)) + if err != nil { + return nil, err + } + contract, err := bindFeeManager(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &FeeManager{address: address, abi: abi, FeeManagerCaller: FeeManagerCaller{contract: contract}, FeeManagerTransactor: FeeManagerTransactor{contract: contract}, FeeManagerFilterer: FeeManagerFilterer{contract: contract}}, nil +} + +func NewFeeManagerCaller(address common.Address, caller bind.ContractCaller) (*FeeManagerCaller, error) { + contract, err := bindFeeManager(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &FeeManagerCaller{contract: contract}, nil +} + +func NewFeeManagerTransactor(address common.Address, transactor bind.ContractTransactor) (*FeeManagerTransactor, error) { + contract, err := bindFeeManager(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &FeeManagerTransactor{contract: contract}, nil +} + +func NewFeeManagerFilterer(address common.Address, filterer bind.ContractFilterer) (*FeeManagerFilterer, error) { + contract, err := bindFeeManager(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &FeeManagerFilterer{contract: contract}, nil +} + +func bindFeeManager(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := FeeManagerMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_FeeManager *FeeManagerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _FeeManager.Contract.FeeManagerCaller.contract.Call(opts, result, method, params...) +} + +func (_FeeManager *FeeManagerRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FeeManager.Contract.FeeManagerTransactor.contract.Transfer(opts) +} + +func (_FeeManager *FeeManagerRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _FeeManager.Contract.FeeManagerTransactor.contract.Transact(opts, method, params...) +} + +func (_FeeManager *FeeManagerCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _FeeManager.Contract.contract.Call(opts, result, method, params...) +} + +func (_FeeManager *FeeManagerTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FeeManager.Contract.contract.Transfer(opts) +} + +func (_FeeManager *FeeManagerTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _FeeManager.Contract.contract.Transact(opts, method, params...) +} + +func (_FeeManager *FeeManagerCaller) GetFeeAndReward(opts *bind.CallOpts, subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) { + var out []interface{} + err := _FeeManager.contract.Call(opts, &out, "getFeeAndReward", subscriber, report, quote) + + if err != nil { + return *new(CommonAsset), *new(CommonAsset), err + } + + out0 := *abi.ConvertType(out[0], new(CommonAsset)).(*CommonAsset) + out1 := *abi.ConvertType(out[1], new(CommonAsset)).(*CommonAsset) + + return out0, out1, err + +} + +func (_FeeManager *FeeManagerSession) GetFeeAndReward(subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) { + return _FeeManager.Contract.GetFeeAndReward(&_FeeManager.CallOpts, subscriber, report, quote) +} + +func (_FeeManager *FeeManagerCallerSession) GetFeeAndReward(subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) { + return _FeeManager.Contract.GetFeeAndReward(&_FeeManager.CallOpts, subscriber, report, quote) +} + +func (_FeeManager *FeeManagerCaller) LinkAvailableForPayment(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _FeeManager.contract.Call(opts, &out, "linkAvailableForPayment") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_FeeManager *FeeManagerSession) LinkAvailableForPayment() (*big.Int, error) { + return _FeeManager.Contract.LinkAvailableForPayment(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCallerSession) LinkAvailableForPayment() (*big.Int, error) { + return _FeeManager.Contract.LinkAvailableForPayment(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _FeeManager.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 (_FeeManager *FeeManagerSession) Owner() (common.Address, error) { + return _FeeManager.Contract.Owner(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCallerSession) Owner() (common.Address, error) { + return _FeeManager.Contract.Owner(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCaller) SNativeSurcharge(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _FeeManager.contract.Call(opts, &out, "s_nativeSurcharge") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_FeeManager *FeeManagerSession) SNativeSurcharge() (*big.Int, error) { + return _FeeManager.Contract.SNativeSurcharge(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCallerSession) SNativeSurcharge() (*big.Int, error) { + return _FeeManager.Contract.SNativeSurcharge(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCaller) SSubscriberDiscounts(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) { + var out []interface{} + err := _FeeManager.contract.Call(opts, &out, "s_subscriberDiscounts", arg0, arg1, arg2) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_FeeManager *FeeManagerSession) SSubscriberDiscounts(arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) { + return _FeeManager.Contract.SSubscriberDiscounts(&_FeeManager.CallOpts, arg0, arg1, arg2) +} + +func (_FeeManager *FeeManagerCallerSession) SSubscriberDiscounts(arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) { + return _FeeManager.Contract.SSubscriberDiscounts(&_FeeManager.CallOpts, arg0, arg1, arg2) +} + +func (_FeeManager *FeeManagerCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _FeeManager.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 (_FeeManager *FeeManagerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _FeeManager.Contract.SupportsInterface(&_FeeManager.CallOpts, interfaceId) +} + +func (_FeeManager *FeeManagerCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _FeeManager.Contract.SupportsInterface(&_FeeManager.CallOpts, interfaceId) +} + +func (_FeeManager *FeeManagerCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _FeeManager.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_FeeManager *FeeManagerSession) TypeAndVersion() (string, error) { + return _FeeManager.Contract.TypeAndVersion(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerCallerSession) TypeAndVersion() (string, error) { + return _FeeManager.Contract.TypeAndVersion(&_FeeManager.CallOpts) +} + +func (_FeeManager *FeeManagerTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "acceptOwnership") +} + +func (_FeeManager *FeeManagerSession) AcceptOwnership() (*types.Transaction, error) { + return _FeeManager.Contract.AcceptOwnership(&_FeeManager.TransactOpts) +} + +func (_FeeManager *FeeManagerTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _FeeManager.Contract.AcceptOwnership(&_FeeManager.TransactOpts) +} + +func (_FeeManager *FeeManagerTransactor) ProcessFee(opts *bind.TransactOpts, payload []byte, subscriber common.Address) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "processFee", payload, subscriber) +} + +func (_FeeManager *FeeManagerSession) ProcessFee(payload []byte, subscriber common.Address) (*types.Transaction, error) { + return _FeeManager.Contract.ProcessFee(&_FeeManager.TransactOpts, payload, subscriber) +} + +func (_FeeManager *FeeManagerTransactorSession) ProcessFee(payload []byte, subscriber common.Address) (*types.Transaction, error) { + return _FeeManager.Contract.ProcessFee(&_FeeManager.TransactOpts, payload, subscriber) +} + +func (_FeeManager *FeeManagerTransactor) SetFeeRecipients(opts *bind.TransactOpts, configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "setFeeRecipients", configDigest, rewardRecipientAndWeights) +} + +func (_FeeManager *FeeManagerSession) SetFeeRecipients(configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _FeeManager.Contract.SetFeeRecipients(&_FeeManager.TransactOpts, configDigest, rewardRecipientAndWeights) +} + +func (_FeeManager *FeeManagerTransactorSession) SetFeeRecipients(configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _FeeManager.Contract.SetFeeRecipients(&_FeeManager.TransactOpts, configDigest, rewardRecipientAndWeights) +} + +func (_FeeManager *FeeManagerTransactor) SetNativeSurcharge(opts *bind.TransactOpts, surcharge *big.Int) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "setNativeSurcharge", surcharge) +} + +func (_FeeManager *FeeManagerSession) SetNativeSurcharge(surcharge *big.Int) (*types.Transaction, error) { + return _FeeManager.Contract.SetNativeSurcharge(&_FeeManager.TransactOpts, surcharge) +} + +func (_FeeManager *FeeManagerTransactorSession) SetNativeSurcharge(surcharge *big.Int) (*types.Transaction, error) { + return _FeeManager.Contract.SetNativeSurcharge(&_FeeManager.TransactOpts, surcharge) +} + +func (_FeeManager *FeeManagerTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "transferOwnership", to) +} + +func (_FeeManager *FeeManagerSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _FeeManager.Contract.TransferOwnership(&_FeeManager.TransactOpts, to) +} + +func (_FeeManager *FeeManagerTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _FeeManager.Contract.TransferOwnership(&_FeeManager.TransactOpts, to) +} + +func (_FeeManager *FeeManagerTransactor) UpdateSubscriberDiscount(opts *bind.TransactOpts, subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "updateSubscriberDiscount", subscriber, feedId, token, discount) +} + +func (_FeeManager *FeeManagerSession) UpdateSubscriberDiscount(subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) { + return _FeeManager.Contract.UpdateSubscriberDiscount(&_FeeManager.TransactOpts, subscriber, feedId, token, discount) +} + +func (_FeeManager *FeeManagerTransactorSession) UpdateSubscriberDiscount(subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) { + return _FeeManager.Contract.UpdateSubscriberDiscount(&_FeeManager.TransactOpts, subscriber, feedId, token, discount) +} + +func (_FeeManager *FeeManagerTransactor) Withdraw(opts *bind.TransactOpts, assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "withdraw", assetAddress, quantity) +} + +func (_FeeManager *FeeManagerSession) Withdraw(assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) { + return _FeeManager.Contract.Withdraw(&_FeeManager.TransactOpts, assetAddress, quantity) +} + +func (_FeeManager *FeeManagerTransactorSession) Withdraw(assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) { + return _FeeManager.Contract.Withdraw(&_FeeManager.TransactOpts, assetAddress, quantity) +} + +type FeeManagerInsufficientLinkIterator struct { + Event *FeeManagerInsufficientLink + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerInsufficientLinkIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerInsufficientLink) + 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(FeeManagerInsufficientLink) + 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 *FeeManagerInsufficientLinkIterator) Error() error { + return it.fail +} + +func (it *FeeManagerInsufficientLinkIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerInsufficientLink struct { + ConfigDigest [32]byte + LinkQuantity *big.Int + NativeQuantity *big.Int + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterInsufficientLink(opts *bind.FilterOpts, configDigest [][32]byte) (*FeeManagerInsufficientLinkIterator, error) { + + var configDigestRule []interface{} + for _, configDigestItem := range configDigest { + configDigestRule = append(configDigestRule, configDigestItem) + } + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "InsufficientLink", configDigestRule) + if err != nil { + return nil, err + } + return &FeeManagerInsufficientLinkIterator{contract: _FeeManager.contract, event: "InsufficientLink", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchInsufficientLink(opts *bind.WatchOpts, sink chan<- *FeeManagerInsufficientLink, configDigest [][32]byte) (event.Subscription, error) { + + var configDigestRule []interface{} + for _, configDigestItem := range configDigest { + configDigestRule = append(configDigestRule, configDigestItem) + } + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "InsufficientLink", configDigestRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerInsufficientLink) + if err := _FeeManager.contract.UnpackLog(event, "InsufficientLink", 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 (_FeeManager *FeeManagerFilterer) ParseInsufficientLink(log types.Log) (*FeeManagerInsufficientLink, error) { + event := new(FeeManagerInsufficientLink) + if err := _FeeManager.contract.UnpackLog(event, "InsufficientLink", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FeeManagerNativeSurchargeUpdatedIterator struct { + Event *FeeManagerNativeSurchargeUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerNativeSurchargeUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerNativeSurchargeUpdated) + 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(FeeManagerNativeSurchargeUpdated) + 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 *FeeManagerNativeSurchargeUpdatedIterator) Error() error { + return it.fail +} + +func (it *FeeManagerNativeSurchargeUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerNativeSurchargeUpdated struct { + NewSurcharge *big.Int + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterNativeSurchargeUpdated(opts *bind.FilterOpts) (*FeeManagerNativeSurchargeUpdatedIterator, error) { + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "NativeSurchargeUpdated") + if err != nil { + return nil, err + } + return &FeeManagerNativeSurchargeUpdatedIterator{contract: _FeeManager.contract, event: "NativeSurchargeUpdated", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchNativeSurchargeUpdated(opts *bind.WatchOpts, sink chan<- *FeeManagerNativeSurchargeUpdated) (event.Subscription, error) { + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "NativeSurchargeUpdated") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerNativeSurchargeUpdated) + if err := _FeeManager.contract.UnpackLog(event, "NativeSurchargeUpdated", 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 (_FeeManager *FeeManagerFilterer) ParseNativeSurchargeUpdated(log types.Log) (*FeeManagerNativeSurchargeUpdated, error) { + event := new(FeeManagerNativeSurchargeUpdated) + if err := _FeeManager.contract.UnpackLog(event, "NativeSurchargeUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FeeManagerOwnershipTransferRequestedIterator struct { + Event *FeeManagerOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerOwnershipTransferRequested) + 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(FeeManagerOwnershipTransferRequested) + 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 *FeeManagerOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *FeeManagerOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FeeManagerOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &FeeManagerOwnershipTransferRequestedIterator{contract: _FeeManager.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FeeManagerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerOwnershipTransferRequested) + if err := _FeeManager.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_FeeManager *FeeManagerFilterer) ParseOwnershipTransferRequested(log types.Log) (*FeeManagerOwnershipTransferRequested, error) { + event := new(FeeManagerOwnershipTransferRequested) + if err := _FeeManager.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FeeManagerOwnershipTransferredIterator struct { + Event *FeeManagerOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerOwnershipTransferred) + 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(FeeManagerOwnershipTransferred) + 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 *FeeManagerOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *FeeManagerOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FeeManagerOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &FeeManagerOwnershipTransferredIterator{contract: _FeeManager.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FeeManagerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerOwnershipTransferred) + if err := _FeeManager.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 (_FeeManager *FeeManagerFilterer) ParseOwnershipTransferred(log types.Log) (*FeeManagerOwnershipTransferred, error) { + event := new(FeeManagerOwnershipTransferred) + if err := _FeeManager.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FeeManagerSubscriberDiscountUpdatedIterator struct { + Event *FeeManagerSubscriberDiscountUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerSubscriberDiscountUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerSubscriberDiscountUpdated) + 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(FeeManagerSubscriberDiscountUpdated) + 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 *FeeManagerSubscriberDiscountUpdatedIterator) Error() error { + return it.fail +} + +func (it *FeeManagerSubscriberDiscountUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerSubscriberDiscountUpdated struct { + Subscriber common.Address + FeedId [32]byte + Token common.Address + Discount *big.Int + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterSubscriberDiscountUpdated(opts *bind.FilterOpts, subscriber []common.Address, feedId [][32]byte) (*FeeManagerSubscriberDiscountUpdatedIterator, error) { + + var subscriberRule []interface{} + for _, subscriberItem := range subscriber { + subscriberRule = append(subscriberRule, subscriberItem) + } + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "SubscriberDiscountUpdated", subscriberRule, feedIdRule) + if err != nil { + return nil, err + } + return &FeeManagerSubscriberDiscountUpdatedIterator{contract: _FeeManager.contract, event: "SubscriberDiscountUpdated", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchSubscriberDiscountUpdated(opts *bind.WatchOpts, sink chan<- *FeeManagerSubscriberDiscountUpdated, subscriber []common.Address, feedId [][32]byte) (event.Subscription, error) { + + var subscriberRule []interface{} + for _, subscriberItem := range subscriber { + subscriberRule = append(subscriberRule, subscriberItem) + } + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "SubscriberDiscountUpdated", subscriberRule, feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerSubscriberDiscountUpdated) + if err := _FeeManager.contract.UnpackLog(event, "SubscriberDiscountUpdated", 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 (_FeeManager *FeeManagerFilterer) ParseSubscriberDiscountUpdated(log types.Log) (*FeeManagerSubscriberDiscountUpdated, error) { + event := new(FeeManagerSubscriberDiscountUpdated) + if err := _FeeManager.contract.UnpackLog(event, "SubscriberDiscountUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FeeManagerWithdrawIterator struct { + Event *FeeManagerWithdraw + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerWithdrawIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerWithdraw) + 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(FeeManagerWithdraw) + 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 *FeeManagerWithdrawIterator) Error() error { + return it.fail +} + +func (it *FeeManagerWithdrawIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerWithdraw struct { + AdminAddress common.Address + AssetAddress common.Address + Quantity *big.Int + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterWithdraw(opts *bind.FilterOpts) (*FeeManagerWithdrawIterator, error) { + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "Withdraw") + if err != nil { + return nil, err + } + return &FeeManagerWithdrawIterator{contract: _FeeManager.contract, event: "Withdraw", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchWithdraw(opts *bind.WatchOpts, sink chan<- *FeeManagerWithdraw) (event.Subscription, error) { + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "Withdraw") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerWithdraw) + if err := _FeeManager.contract.UnpackLog(event, "Withdraw", 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 (_FeeManager *FeeManagerFilterer) ParseWithdraw(log types.Log) (*FeeManagerWithdraw, error) { + event := new(FeeManagerWithdraw) + if err := _FeeManager.contract.UnpackLog(event, "Withdraw", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_FeeManager *FeeManager) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _FeeManager.abi.Events["InsufficientLink"].ID: + return _FeeManager.ParseInsufficientLink(log) + case _FeeManager.abi.Events["NativeSurchargeUpdated"].ID: + return _FeeManager.ParseNativeSurchargeUpdated(log) + case _FeeManager.abi.Events["OwnershipTransferRequested"].ID: + return _FeeManager.ParseOwnershipTransferRequested(log) + case _FeeManager.abi.Events["OwnershipTransferred"].ID: + return _FeeManager.ParseOwnershipTransferred(log) + case _FeeManager.abi.Events["SubscriberDiscountUpdated"].ID: + return _FeeManager.ParseSubscriberDiscountUpdated(log) + case _FeeManager.abi.Events["Withdraw"].ID: + return _FeeManager.ParseWithdraw(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (FeeManagerInsufficientLink) Topic() common.Hash { + return common.HexToHash("0xeb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7") +} + +func (FeeManagerNativeSurchargeUpdated) Topic() common.Hash { + return common.HexToHash("0xa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e1") +} + +func (FeeManagerOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (FeeManagerOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (FeeManagerSubscriberDiscountUpdated) Topic() common.Hash { + return common.HexToHash("0x41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84") +} + +func (FeeManagerWithdraw) Topic() common.Hash { + return common.HexToHash("0x9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb") +} + +func (_FeeManager *FeeManager) Address() common.Address { + return _FeeManager.address +} + +type FeeManagerInterface interface { + GetFeeAndReward(opts *bind.CallOpts, subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) + + LinkAvailableForPayment(opts *bind.CallOpts) (*big.Int, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SNativeSurcharge(opts *bind.CallOpts) (*big.Int, error) + + SSubscriberDiscounts(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + ProcessFee(opts *bind.TransactOpts, payload []byte, subscriber common.Address) (*types.Transaction, error) + + SetFeeRecipients(opts *bind.TransactOpts, configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + + SetNativeSurcharge(opts *bind.TransactOpts, surcharge *big.Int) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + UpdateSubscriberDiscount(opts *bind.TransactOpts, subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) + + Withdraw(opts *bind.TransactOpts, assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) + + FilterInsufficientLink(opts *bind.FilterOpts, configDigest [][32]byte) (*FeeManagerInsufficientLinkIterator, error) + + WatchInsufficientLink(opts *bind.WatchOpts, sink chan<- *FeeManagerInsufficientLink, configDigest [][32]byte) (event.Subscription, error) + + ParseInsufficientLink(log types.Log) (*FeeManagerInsufficientLink, error) + + FilterNativeSurchargeUpdated(opts *bind.FilterOpts) (*FeeManagerNativeSurchargeUpdatedIterator, error) + + WatchNativeSurchargeUpdated(opts *bind.WatchOpts, sink chan<- *FeeManagerNativeSurchargeUpdated) (event.Subscription, error) + + ParseNativeSurchargeUpdated(log types.Log) (*FeeManagerNativeSurchargeUpdated, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FeeManagerOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FeeManagerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*FeeManagerOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FeeManagerOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FeeManagerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*FeeManagerOwnershipTransferred, error) + + FilterSubscriberDiscountUpdated(opts *bind.FilterOpts, subscriber []common.Address, feedId [][32]byte) (*FeeManagerSubscriberDiscountUpdatedIterator, error) + + WatchSubscriberDiscountUpdated(opts *bind.WatchOpts, sink chan<- *FeeManagerSubscriberDiscountUpdated, subscriber []common.Address, feedId [][32]byte) (event.Subscription, error) + + ParseSubscriberDiscountUpdated(log types.Log) (*FeeManagerSubscriberDiscountUpdated, error) + + FilterWithdraw(opts *bind.FilterOpts) (*FeeManagerWithdrawIterator, error) + + WatchWithdraw(opts *bind.WatchOpts, sink chan<- *FeeManagerWithdraw) (event.Subscription, error) + + ParseWithdraw(log types.Log) (*FeeManagerWithdraw, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/llo_feeds/llo_feeds.go b/core/gethwrappers/llo-feeds/generated/llo_feeds/llo_feeds.go new file mode 100644 index 00000000000..0cf53356440 --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/llo_feeds/llo_feeds.go @@ -0,0 +1,1318 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package llo_feeds + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + +type CommonAsset struct { + AssetAddress common.Address + Amount *big.Int +} + +type IFeeManagerQuote struct { + QuoteAddress common.Address +} + +var LLOFeeManagerMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_nativeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_proxyAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_rewardManagerAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ExpiredReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDeposit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDiscount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidQuote\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSurcharge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidToken\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nativeQuantity\",\"type\":\"uint256\"}],\"name\":\"InsufficientLink\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newSurcharge\",\"type\":\"uint256\"}],\"name\":\"NativeSurchargeSet\",\"type\":\"event\"},{\"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\":\"subscriber\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"SubscriberDiscountUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"quoteAddress\",\"type\":\"address\"}],\"internalType\":\"structIFeeManager.Quote\",\"name\":\"quote\",\"type\":\"tuple\"}],\"name\":\"getFeeAndReward\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkAvailableForPayment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"nativeSurcharge\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"}],\"name\":\"processFee\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setFeeRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"surcharge\",\"type\":\"uint256\"}],\"name\":\"setNativeSurcharge\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"subscriberDiscounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"updateSubscriberDiscount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101006040523480156200001257600080fd5b50604051620024d4380380620024d4833981016040819052620000359162000288565b33806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf81620001c0565b5050506001600160a01b0384161580620000e057506001600160a01b038316155b80620000f357506001600160a01b038216155b806200010657506001600160a01b038116155b15620001255760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03848116608081905284821660a05283821660c05290821660e081905260405163095ea7b360e01b81526004810191909152600019602482015263095ea7b3906044016020604051808303816000875af11580156200018f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001b59190620002e5565b505050505062000310565b336001600160a01b038216036200021a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200028357600080fd5b919050565b600080600080608085870312156200029f57600080fd5b620002aa856200026b565b9350620002ba602086016200026b565b9250620002ca604086016200026b565b9150620002da606086016200026b565b905092959194509250565b600060208284031215620002f857600080fd5b815180151581146200030957600080fd5b9392505050565b60805160a05160c05160e051612128620003ac6000396000818161044c01528181610e5401526110b20152600081816103820152610b1b0152600081816106af015281816107020152818161090f01528181610c6901528181610d3001526112170152600081816106d40152818161075d0152818161089a01528181610a5d01528181610def01528181610fa301526111c001526121286000f3fe6080604052600436106100dd5760003560e01c806393798be71161007f578063f1387e1611610059578063f1387e16146102d6578063f237f1a8146102e9578063f2fde38b14610309578063f3fef3a31461032957600080fd5b806393798be714610255578063c541cbde14610293578063d09dc339146102c157600080fd5b80636b54d8a6116100bb5780636b54d8a6146101c757806379ba5097146101e75780637d75cc49146101fc5780638da5cb5b1461022057600080fd5b806301ffc9a7146100e2578063181f5a771461015957806369fd2b34146101a5575b600080fd5b3480156100ee57600080fd5b506101446100fd36600461167b565b7fffffffff00000000000000000000000000000000000000000000000000000000167ff1387e16000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b34801561016557600080fd5b50604080518082018252601081527f4665654d616e6167657220302e302e31000000000000000000000000000000006020820152905161015091906116c4565b3480156101b157600080fd5b506101c56101c0366004611730565b610349565b005b3480156101d357600080fd5b506101c56101e23660046117af565b6104bc565b3480156101f357600080fd5b506101c5610541565b34801561020857600080fd5b5061021260035481565b604051908152602001610150565b34801561022c57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610150565b34801561026157600080fd5b506102126102703660046117ea565b600260209081526000938452604080852082529284528284209052825290205481565b34801561029f57600080fd5b506102b36102ae366004611961565b61063e565b604051610150929190611a02565b3480156102cd57600080fd5b50610212610a2c565b6101c56102e4366004611a56565b610ae2565b3480156102f557600080fd5b506101c5610304366004611ace565b611174565b34801561031557600080fd5b506101c5610324366004611b16565b61131b565b34801561033557600080fd5b506101c5610344366004611b33565b61132f565b60005473ffffffffffffffffffffffffffffffffffffffff163314806103a457503373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016145b61040f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4f6e6c79206f776e6572206f722070726f78790000000000000000000000000060448201526064015b60405180910390fd5b6040517f633b5f6e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063633b5f6e9061048590869086908690600401611b5f565b600060405180830381600087803b15801561049f57600080fd5b505af11580156104b3573d6000803e3d6000fd5b50505050505050565b6104c46114c9565b670de0b6b3a7640000811115610506576040517f05e8ac2900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60038190556040518181527f4fbcc2b7f4cb5518be923bd7c7c887e29e07b001e2a4a0fdd47c494696d8a1479060200160405180910390a150565b60015473ffffffffffffffffffffffffffffffffffffffff1633146105c2576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610406565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b60408051808201909152600080825260208201526040805180820190915260008082526020820152604080518082019091526000808252602082015260408051808201909152600080825260208201528551610120106107005773ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000811683527f00000000000000000000000000000000000000000000000000000000000000001681529092509050610a24565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff16141580156107b057507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16856000015173ffffffffffffffffffffffffffffffffffffffff1614155b156107e7576040517ff861803000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000888060200190518101906108009190611c39565b63ffffffff169b5077ffffffffffffffffffffffffffffffffffffffffffffffff169b5077ffffffffffffffffffffffffffffffffffffffffffffffff169b5050505050505050505042811015610883576040517fb6c405f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116808652602086018590528951909116036108f857835173ffffffffffffffffffffffffffffffffffffffff16855260208085015190860152610968565b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001685526003546109629061094a90670de0b6b3a7640000611d36565b6109549084611d49565b670de0b6b3a764000061154c565b60208601525b60006109738a611d86565b73ffffffffffffffffffffffffffffffffffffffff808d16600090815260026020908152604080832085845282528083208e519094168352928152919020549088015191925090670de0b6b3a7640000906109cf908390611d49565b6109d99190611dcb565b87602001516109e89190611e06565b876020018181525050610a048187602001516109549190611d49565b8660200151610a139190611e06565b602087015250949650929450505050505b935093915050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610ab9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610add9190611e19565b905090565b60005473ffffffffffffffffffffffffffffffffffffffff16331480610b3d57503373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016145b610ba3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601360248201527f4f6e6c79206f776e6572206f722070726f7879000000000000000000000000006044820152606401610406565b3073ffffffffffffffffffffffffffffffffffffffff821603610bf2576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610c0083850185611ea0565b604080516020810190915260008152909250905081516101201015610c4c576000610c2d85870187611f6f565b9550505050505080806020019051810190610c489190612037565b9150505b600080610c5a33858561063e565b909250905060003415610dbd577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614610cf0576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3483602001511115610d2e576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db084602001516040518263ffffffff1660e01b81526004016000604051808303818588803b158015610d9a57600080fd5b505af1158015610dae573d6000803e3d6000fd5b50505050508260200151340390505b6000610dc9888a612065565b60208501519091501561111e57835173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116911603610ec4576040517f84afb76e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016906384afb76e90610e8d9084908b9088906004016120a1565b600060405180830381600087803b158015610ea757600080fd5b505af1158015610ebb573d6000803e3d6000fd5b5050505061111e565b34600003610f7557835160208501516040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8a8116600483015230602483015260448201929092529116906323b872dd906064016020604051808303816000875af1158015610f4f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f7391906120f9565b505b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610fff573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110239190611e19565b836020015111156110755760208084015185820151604080519283529282015282917feb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7910160405180910390a261111e565b6040517f84afb76e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016906384afb76e906110eb908490309088906004016120a1565b600060405180830381600087803b15801561110557600080fd5b505af1158015611119573d6000803e3d6000fd5b505050505b81156111695760405173ffffffffffffffffffffffffffffffffffffffff88169083156108fc029084906000818181858888f19350505050158015611167573d6000803e3d6000fd5b505b505050505050505050565b61117c6114c9565b670de0b6b3a76400008111156111be576040517f997ea36000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415801561126657507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b1561129d576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84811660008181526002602090815260408083208884528252808320948716808452948252918290208590558151938452830184905285927f41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84910160405180910390a350505050565b6113236114c9565b61132c81611586565b50565b6113376114c9565b73ffffffffffffffffffffffffffffffffffffffff821661139d576000805460405173ffffffffffffffffffffffffffffffffffffffff9091169183156108fc02918491818181858888f19350505050158015611398573d6000803e3d6000fd5b505050565b8173ffffffffffffffffffffffffffffffffffffffff1663a9059cbb6113d860005473ffffffffffffffffffffffffffffffffffffffff1690565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af115801561144a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061146e91906120f9565b506040805133815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb9060600160405180910390a15050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461154a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610406565b565b6000821561157a5781611560600185611e06565b61156a9190611dcb565b611575906001611d36565b61157d565b60005b90505b92915050565b3373ffffffffffffffffffffffffffffffffffffffff821603611605576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610406565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561168d57600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146116bd57600080fd5b9392505050565b600060208083528351808285015260005b818110156116f1578581018301518582016040015282016116d5565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60008060006040848603121561174557600080fd5b83359250602084013567ffffffffffffffff8082111561176457600080fd5b818601915086601f83011261177857600080fd5b81358181111561178757600080fd5b8760208260061b850101111561179c57600080fd5b6020830194508093505050509250925092565b6000602082840312156117c157600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461132c57600080fd5b6000806000606084860312156117ff57600080fd5b833561180a816117c8565b9250602084013591506040840135611821816117c8565b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516020810167ffffffffffffffff8111828210171561187e5761187e61182c565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156118cb576118cb61182c565b604052919050565b600082601f8301126118e457600080fd5b813567ffffffffffffffff8111156118fe576118fe61182c565b61192f60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611884565b81815284602083860101111561194457600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000838503606081121561197757600080fd5b8435611982816117c8565b9350602085013567ffffffffffffffff81111561199e57600080fd5b6119aa878288016118d3565b93505060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0820112156119dd57600080fd5b506119e661185b565b60408501356119f4816117c8565b815292959194509192509050565b825173ffffffffffffffffffffffffffffffffffffffff1681526020808401519082015260808101825173ffffffffffffffffffffffffffffffffffffffff166040830152602083015160608301526116bd565b600080600060408486031215611a6b57600080fd5b833567ffffffffffffffff80821115611a8357600080fd5b818601915086601f830112611a9757600080fd5b813581811115611aa657600080fd5b876020828501011115611ab857600080fd5b60209283019550935050840135611821816117c8565b60008060008060808587031215611ae457600080fd5b8435611aef816117c8565b9350602085013592506040850135611b06816117c8565b9396929550929360600135925050565b600060208284031215611b2857600080fd5b81356116bd816117c8565b60008060408385031215611b4657600080fd5b8235611b51816117c8565b946020939093013593505050565b8381526040602080830182905282820184905260009190859060608501845b87811015611bc1578335611b91816117c8565b73ffffffffffffffffffffffffffffffffffffffff16825283830135838301529284019290840190600101611b7e565b5098975050505050505050565b805163ffffffff81168114611be257600080fd5b919050565b8051601781900b8114611be257600080fd5b805167ffffffffffffffff81168114611be257600080fd5b805177ffffffffffffffffffffffffffffffffffffffffffffffff81168114611be257600080fd5b6000806000806000806000806000806000806101808d8f031215611c5c57600080fd5b8c519b50611c6c60208e01611bce565b9a50611c7a60408e01611be7565b9950611c8860608e01611be7565b9850611c9660808e01611be7565b9750611ca460a08e01611bf9565b965060c08d01519550611cb960e08e01611bf9565b9450611cc86101008e01611bf9565b9350611cd76101208e01611c11565b9250611ce66101408e01611c11565b9150611cf56101608e01611bce565b90509295989b509295989b509295989b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561158057611580611d07565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611d8157611d81611d07565b500290565b80516020808301519190811015611dc5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b600082611e01577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b8181038181111561158057611580611d07565b600060208284031215611e2b57600080fd5b5051919050565b600082601f830112611e4357600080fd5b6040516060810181811067ffffffffffffffff82111715611e6657611e6661182c565b604052806060840185811115611e7b57600080fd5b845b81811015611e95578035835260209283019201611e7d565b509195945050505050565b60008060808385031215611eb357600080fd5b611ebd8484611e32565b9150606083013567ffffffffffffffff811115611ed957600080fd5b611ee5858286016118d3565b9150509250929050565b600082601f830112611f0057600080fd5b8135602067ffffffffffffffff821115611f1c57611f1c61182c565b8160051b611f2b828201611884565b9283528481018201928281019087851115611f4557600080fd5b83870192505b84831015611f6457823582529183019190830190611f4b565b979650505050505050565b6000806000806000806101008789031215611f8957600080fd5b611f938888611e32565b9550606087013567ffffffffffffffff80821115611fb057600080fd5b611fbc8a838b016118d3565b96506080890135915080821115611fd257600080fd5b611fde8a838b01611eef565b955060a0890135915080821115611ff457600080fd5b6120008a838b01611eef565b945060c0890135935060e089013591508082111561201d57600080fd5b5061202a89828a016118d3565b9150509295509295509295565b60006020828403121561204957600080fd5b61205161185b565b825161205c816117c8565b81529392505050565b80356020831015611580577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b83815273ffffffffffffffffffffffffffffffffffffffff83166020820152608081016120f16040830184805173ffffffffffffffffffffffffffffffffffffffff168252602090810151910152565b949350505050565b60006020828403121561210b57600080fd5b815180151581146116bd57600080fdfea164736f6c6343000810000a", +} + +var LLOFeeManagerABI = LLOFeeManagerMetaData.ABI + +var LLOFeeManagerBin = LLOFeeManagerMetaData.Bin + +func DeployLLOFeeManager(auth *bind.TransactOpts, backend bind.ContractBackend, _linkAddress common.Address, _nativeAddress common.Address, _proxyAddress common.Address, _rewardManagerAddress common.Address) (common.Address, *types.Transaction, *LLOFeeManager, error) { + parsed, err := LLOFeeManagerMetaData.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(LLOFeeManagerBin), backend, _linkAddress, _nativeAddress, _proxyAddress, _rewardManagerAddress) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &LLOFeeManager{LLOFeeManagerCaller: LLOFeeManagerCaller{contract: contract}, LLOFeeManagerTransactor: LLOFeeManagerTransactor{contract: contract}, LLOFeeManagerFilterer: LLOFeeManagerFilterer{contract: contract}}, nil +} + +type LLOFeeManager struct { + address common.Address + abi abi.ABI + LLOFeeManagerCaller + LLOFeeManagerTransactor + LLOFeeManagerFilterer +} + +type LLOFeeManagerCaller struct { + contract *bind.BoundContract +} + +type LLOFeeManagerTransactor struct { + contract *bind.BoundContract +} + +type LLOFeeManagerFilterer struct { + contract *bind.BoundContract +} + +type LLOFeeManagerSession struct { + Contract *LLOFeeManager + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type LLOFeeManagerCallerSession struct { + Contract *LLOFeeManagerCaller + CallOpts bind.CallOpts +} + +type LLOFeeManagerTransactorSession struct { + Contract *LLOFeeManagerTransactor + TransactOpts bind.TransactOpts +} + +type LLOFeeManagerRaw struct { + Contract *LLOFeeManager +} + +type LLOFeeManagerCallerRaw struct { + Contract *LLOFeeManagerCaller +} + +type LLOFeeManagerTransactorRaw struct { + Contract *LLOFeeManagerTransactor +} + +func NewLLOFeeManager(address common.Address, backend bind.ContractBackend) (*LLOFeeManager, error) { + abi, err := abi.JSON(strings.NewReader(LLOFeeManagerABI)) + if err != nil { + return nil, err + } + contract, err := bindLLOFeeManager(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &LLOFeeManager{address: address, abi: abi, LLOFeeManagerCaller: LLOFeeManagerCaller{contract: contract}, LLOFeeManagerTransactor: LLOFeeManagerTransactor{contract: contract}, LLOFeeManagerFilterer: LLOFeeManagerFilterer{contract: contract}}, nil +} + +func NewLLOFeeManagerCaller(address common.Address, caller bind.ContractCaller) (*LLOFeeManagerCaller, error) { + contract, err := bindLLOFeeManager(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &LLOFeeManagerCaller{contract: contract}, nil +} + +func NewLLOFeeManagerTransactor(address common.Address, transactor bind.ContractTransactor) (*LLOFeeManagerTransactor, error) { + contract, err := bindLLOFeeManager(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &LLOFeeManagerTransactor{contract: contract}, nil +} + +func NewLLOFeeManagerFilterer(address common.Address, filterer bind.ContractFilterer) (*LLOFeeManagerFilterer, error) { + contract, err := bindLLOFeeManager(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &LLOFeeManagerFilterer{contract: contract}, nil +} + +func bindLLOFeeManager(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := LLOFeeManagerMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_LLOFeeManager *LLOFeeManagerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _LLOFeeManager.Contract.LLOFeeManagerCaller.contract.Call(opts, result, method, params...) +} + +func (_LLOFeeManager *LLOFeeManagerRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LLOFeeManager.Contract.LLOFeeManagerTransactor.contract.Transfer(opts) +} + +func (_LLOFeeManager *LLOFeeManagerRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _LLOFeeManager.Contract.LLOFeeManagerTransactor.contract.Transact(opts, method, params...) +} + +func (_LLOFeeManager *LLOFeeManagerCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _LLOFeeManager.Contract.contract.Call(opts, result, method, params...) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LLOFeeManager.Contract.contract.Transfer(opts) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _LLOFeeManager.Contract.contract.Transact(opts, method, params...) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) GetFeeAndReward(opts *bind.CallOpts, subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) { + var out []interface{} + err := _LLOFeeManager.contract.Call(opts, &out, "getFeeAndReward", subscriber, report, quote) + + if err != nil { + return *new(CommonAsset), *new(CommonAsset), err + } + + out0 := *abi.ConvertType(out[0], new(CommonAsset)).(*CommonAsset) + out1 := *abi.ConvertType(out[1], new(CommonAsset)).(*CommonAsset) + + return out0, out1, err + +} + +func (_LLOFeeManager *LLOFeeManagerSession) GetFeeAndReward(subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) { + return _LLOFeeManager.Contract.GetFeeAndReward(&_LLOFeeManager.CallOpts, subscriber, report, quote) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) GetFeeAndReward(subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) { + return _LLOFeeManager.Contract.GetFeeAndReward(&_LLOFeeManager.CallOpts, subscriber, report, quote) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) LinkAvailableForPayment(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _LLOFeeManager.contract.Call(opts, &out, "linkAvailableForPayment") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LLOFeeManager *LLOFeeManagerSession) LinkAvailableForPayment() (*big.Int, error) { + return _LLOFeeManager.Contract.LinkAvailableForPayment(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) LinkAvailableForPayment() (*big.Int, error) { + return _LLOFeeManager.Contract.LinkAvailableForPayment(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) NativeSurcharge(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _LLOFeeManager.contract.Call(opts, &out, "nativeSurcharge") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LLOFeeManager *LLOFeeManagerSession) NativeSurcharge() (*big.Int, error) { + return _LLOFeeManager.Contract.NativeSurcharge(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) NativeSurcharge() (*big.Int, error) { + return _LLOFeeManager.Contract.NativeSurcharge(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _LLOFeeManager.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 (_LLOFeeManager *LLOFeeManagerSession) Owner() (common.Address, error) { + return _LLOFeeManager.Contract.Owner(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) Owner() (common.Address, error) { + return _LLOFeeManager.Contract.Owner(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) SubscriberDiscounts(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) { + var out []interface{} + err := _LLOFeeManager.contract.Call(opts, &out, "subscriberDiscounts", arg0, arg1, arg2) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LLOFeeManager *LLOFeeManagerSession) SubscriberDiscounts(arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) { + return _LLOFeeManager.Contract.SubscriberDiscounts(&_LLOFeeManager.CallOpts, arg0, arg1, arg2) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) SubscriberDiscounts(arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) { + return _LLOFeeManager.Contract.SubscriberDiscounts(&_LLOFeeManager.CallOpts, arg0, arg1, arg2) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _LLOFeeManager.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 (_LLOFeeManager *LLOFeeManagerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _LLOFeeManager.Contract.SupportsInterface(&_LLOFeeManager.CallOpts, interfaceId) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _LLOFeeManager.Contract.SupportsInterface(&_LLOFeeManager.CallOpts, interfaceId) +} + +func (_LLOFeeManager *LLOFeeManagerCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _LLOFeeManager.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_LLOFeeManager *LLOFeeManagerSession) TypeAndVersion() (string, error) { + return _LLOFeeManager.Contract.TypeAndVersion(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerCallerSession) TypeAndVersion() (string, error) { + return _LLOFeeManager.Contract.TypeAndVersion(&_LLOFeeManager.CallOpts) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "acceptOwnership") +} + +func (_LLOFeeManager *LLOFeeManagerSession) AcceptOwnership() (*types.Transaction, error) { + return _LLOFeeManager.Contract.AcceptOwnership(&_LLOFeeManager.TransactOpts) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _LLOFeeManager.Contract.AcceptOwnership(&_LLOFeeManager.TransactOpts) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) ProcessFee(opts *bind.TransactOpts, payload []byte, subscriber common.Address) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "processFee", payload, subscriber) +} + +func (_LLOFeeManager *LLOFeeManagerSession) ProcessFee(payload []byte, subscriber common.Address) (*types.Transaction, error) { + return _LLOFeeManager.Contract.ProcessFee(&_LLOFeeManager.TransactOpts, payload, subscriber) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) ProcessFee(payload []byte, subscriber common.Address) (*types.Transaction, error) { + return _LLOFeeManager.Contract.ProcessFee(&_LLOFeeManager.TransactOpts, payload, subscriber) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) SetFeeRecipients(opts *bind.TransactOpts, configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "setFeeRecipients", configDigest, rewardRecipientAndWeights) +} + +func (_LLOFeeManager *LLOFeeManagerSession) SetFeeRecipients(configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _LLOFeeManager.Contract.SetFeeRecipients(&_LLOFeeManager.TransactOpts, configDigest, rewardRecipientAndWeights) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) SetFeeRecipients(configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _LLOFeeManager.Contract.SetFeeRecipients(&_LLOFeeManager.TransactOpts, configDigest, rewardRecipientAndWeights) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) SetNativeSurcharge(opts *bind.TransactOpts, surcharge *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "setNativeSurcharge", surcharge) +} + +func (_LLOFeeManager *LLOFeeManagerSession) SetNativeSurcharge(surcharge *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.Contract.SetNativeSurcharge(&_LLOFeeManager.TransactOpts, surcharge) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) SetNativeSurcharge(surcharge *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.Contract.SetNativeSurcharge(&_LLOFeeManager.TransactOpts, surcharge) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "transferOwnership", to) +} + +func (_LLOFeeManager *LLOFeeManagerSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _LLOFeeManager.Contract.TransferOwnership(&_LLOFeeManager.TransactOpts, to) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _LLOFeeManager.Contract.TransferOwnership(&_LLOFeeManager.TransactOpts, to) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) UpdateSubscriberDiscount(opts *bind.TransactOpts, subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "updateSubscriberDiscount", subscriber, feedId, token, discount) +} + +func (_LLOFeeManager *LLOFeeManagerSession) UpdateSubscriberDiscount(subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.Contract.UpdateSubscriberDiscount(&_LLOFeeManager.TransactOpts, subscriber, feedId, token, discount) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) UpdateSubscriberDiscount(subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.Contract.UpdateSubscriberDiscount(&_LLOFeeManager.TransactOpts, subscriber, feedId, token, discount) +} + +func (_LLOFeeManager *LLOFeeManagerTransactor) Withdraw(opts *bind.TransactOpts, assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.contract.Transact(opts, "withdraw", assetAddress, quantity) +} + +func (_LLOFeeManager *LLOFeeManagerSession) Withdraw(assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.Contract.Withdraw(&_LLOFeeManager.TransactOpts, assetAddress, quantity) +} + +func (_LLOFeeManager *LLOFeeManagerTransactorSession) Withdraw(assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) { + return _LLOFeeManager.Contract.Withdraw(&_LLOFeeManager.TransactOpts, assetAddress, quantity) +} + +type LLOFeeManagerInsufficientLinkIterator struct { + Event *LLOFeeManagerInsufficientLink + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LLOFeeManagerInsufficientLinkIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LLOFeeManagerInsufficientLink) + 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(LLOFeeManagerInsufficientLink) + 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 *LLOFeeManagerInsufficientLinkIterator) Error() error { + return it.fail +} + +func (it *LLOFeeManagerInsufficientLinkIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LLOFeeManagerInsufficientLink struct { + ConfigDigest [32]byte + LinkQuantity *big.Int + NativeQuantity *big.Int + Raw types.Log +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) FilterInsufficientLink(opts *bind.FilterOpts, configDigest [][32]byte) (*LLOFeeManagerInsufficientLinkIterator, error) { + + var configDigestRule []interface{} + for _, configDigestItem := range configDigest { + configDigestRule = append(configDigestRule, configDigestItem) + } + + logs, sub, err := _LLOFeeManager.contract.FilterLogs(opts, "InsufficientLink", configDigestRule) + if err != nil { + return nil, err + } + return &LLOFeeManagerInsufficientLinkIterator{contract: _LLOFeeManager.contract, event: "InsufficientLink", logs: logs, sub: sub}, nil +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) WatchInsufficientLink(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerInsufficientLink, configDigest [][32]byte) (event.Subscription, error) { + + var configDigestRule []interface{} + for _, configDigestItem := range configDigest { + configDigestRule = append(configDigestRule, configDigestItem) + } + + logs, sub, err := _LLOFeeManager.contract.WatchLogs(opts, "InsufficientLink", configDigestRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LLOFeeManagerInsufficientLink) + if err := _LLOFeeManager.contract.UnpackLog(event, "InsufficientLink", 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 (_LLOFeeManager *LLOFeeManagerFilterer) ParseInsufficientLink(log types.Log) (*LLOFeeManagerInsufficientLink, error) { + event := new(LLOFeeManagerInsufficientLink) + if err := _LLOFeeManager.contract.UnpackLog(event, "InsufficientLink", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LLOFeeManagerNativeSurchargeSetIterator struct { + Event *LLOFeeManagerNativeSurchargeSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LLOFeeManagerNativeSurchargeSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LLOFeeManagerNativeSurchargeSet) + 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(LLOFeeManagerNativeSurchargeSet) + 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 *LLOFeeManagerNativeSurchargeSetIterator) Error() error { + return it.fail +} + +func (it *LLOFeeManagerNativeSurchargeSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LLOFeeManagerNativeSurchargeSet struct { + NewSurcharge *big.Int + Raw types.Log +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) FilterNativeSurchargeSet(opts *bind.FilterOpts) (*LLOFeeManagerNativeSurchargeSetIterator, error) { + + logs, sub, err := _LLOFeeManager.contract.FilterLogs(opts, "NativeSurchargeSet") + if err != nil { + return nil, err + } + return &LLOFeeManagerNativeSurchargeSetIterator{contract: _LLOFeeManager.contract, event: "NativeSurchargeSet", logs: logs, sub: sub}, nil +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) WatchNativeSurchargeSet(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerNativeSurchargeSet) (event.Subscription, error) { + + logs, sub, err := _LLOFeeManager.contract.WatchLogs(opts, "NativeSurchargeSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LLOFeeManagerNativeSurchargeSet) + if err := _LLOFeeManager.contract.UnpackLog(event, "NativeSurchargeSet", 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 (_LLOFeeManager *LLOFeeManagerFilterer) ParseNativeSurchargeSet(log types.Log) (*LLOFeeManagerNativeSurchargeSet, error) { + event := new(LLOFeeManagerNativeSurchargeSet) + if err := _LLOFeeManager.contract.UnpackLog(event, "NativeSurchargeSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LLOFeeManagerOwnershipTransferRequestedIterator struct { + Event *LLOFeeManagerOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LLOFeeManagerOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LLOFeeManagerOwnershipTransferRequested) + 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(LLOFeeManagerOwnershipTransferRequested) + 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 *LLOFeeManagerOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *LLOFeeManagerOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LLOFeeManagerOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LLOFeeManagerOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LLOFeeManager.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &LLOFeeManagerOwnershipTransferRequestedIterator{contract: _LLOFeeManager.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LLOFeeManager.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LLOFeeManagerOwnershipTransferRequested) + if err := _LLOFeeManager.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_LLOFeeManager *LLOFeeManagerFilterer) ParseOwnershipTransferRequested(log types.Log) (*LLOFeeManagerOwnershipTransferRequested, error) { + event := new(LLOFeeManagerOwnershipTransferRequested) + if err := _LLOFeeManager.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LLOFeeManagerOwnershipTransferredIterator struct { + Event *LLOFeeManagerOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LLOFeeManagerOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LLOFeeManagerOwnershipTransferred) + 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(LLOFeeManagerOwnershipTransferred) + 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 *LLOFeeManagerOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *LLOFeeManagerOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LLOFeeManagerOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LLOFeeManagerOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LLOFeeManager.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &LLOFeeManagerOwnershipTransferredIterator{contract: _LLOFeeManager.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LLOFeeManager.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LLOFeeManagerOwnershipTransferred) + if err := _LLOFeeManager.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 (_LLOFeeManager *LLOFeeManagerFilterer) ParseOwnershipTransferred(log types.Log) (*LLOFeeManagerOwnershipTransferred, error) { + event := new(LLOFeeManagerOwnershipTransferred) + if err := _LLOFeeManager.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LLOFeeManagerSubscriberDiscountUpdatedIterator struct { + Event *LLOFeeManagerSubscriberDiscountUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LLOFeeManagerSubscriberDiscountUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LLOFeeManagerSubscriberDiscountUpdated) + 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(LLOFeeManagerSubscriberDiscountUpdated) + 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 *LLOFeeManagerSubscriberDiscountUpdatedIterator) Error() error { + return it.fail +} + +func (it *LLOFeeManagerSubscriberDiscountUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LLOFeeManagerSubscriberDiscountUpdated struct { + Subscriber common.Address + FeedId [32]byte + Token common.Address + Discount *big.Int + Raw types.Log +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) FilterSubscriberDiscountUpdated(opts *bind.FilterOpts, subscriber []common.Address, feedId [][32]byte) (*LLOFeeManagerSubscriberDiscountUpdatedIterator, error) { + + var subscriberRule []interface{} + for _, subscriberItem := range subscriber { + subscriberRule = append(subscriberRule, subscriberItem) + } + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _LLOFeeManager.contract.FilterLogs(opts, "SubscriberDiscountUpdated", subscriberRule, feedIdRule) + if err != nil { + return nil, err + } + return &LLOFeeManagerSubscriberDiscountUpdatedIterator{contract: _LLOFeeManager.contract, event: "SubscriberDiscountUpdated", logs: logs, sub: sub}, nil +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) WatchSubscriberDiscountUpdated(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerSubscriberDiscountUpdated, subscriber []common.Address, feedId [][32]byte) (event.Subscription, error) { + + var subscriberRule []interface{} + for _, subscriberItem := range subscriber { + subscriberRule = append(subscriberRule, subscriberItem) + } + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _LLOFeeManager.contract.WatchLogs(opts, "SubscriberDiscountUpdated", subscriberRule, feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LLOFeeManagerSubscriberDiscountUpdated) + if err := _LLOFeeManager.contract.UnpackLog(event, "SubscriberDiscountUpdated", 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 (_LLOFeeManager *LLOFeeManagerFilterer) ParseSubscriberDiscountUpdated(log types.Log) (*LLOFeeManagerSubscriberDiscountUpdated, error) { + event := new(LLOFeeManagerSubscriberDiscountUpdated) + if err := _LLOFeeManager.contract.UnpackLog(event, "SubscriberDiscountUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LLOFeeManagerWithdrawIterator struct { + Event *LLOFeeManagerWithdraw + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LLOFeeManagerWithdrawIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LLOFeeManagerWithdraw) + 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(LLOFeeManagerWithdraw) + 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 *LLOFeeManagerWithdrawIterator) Error() error { + return it.fail +} + +func (it *LLOFeeManagerWithdrawIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LLOFeeManagerWithdraw struct { + AdminAddress common.Address + AssetAddress common.Address + Quantity *big.Int + Raw types.Log +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) FilterWithdraw(opts *bind.FilterOpts) (*LLOFeeManagerWithdrawIterator, error) { + + logs, sub, err := _LLOFeeManager.contract.FilterLogs(opts, "Withdraw") + if err != nil { + return nil, err + } + return &LLOFeeManagerWithdrawIterator{contract: _LLOFeeManager.contract, event: "Withdraw", logs: logs, sub: sub}, nil +} + +func (_LLOFeeManager *LLOFeeManagerFilterer) WatchWithdraw(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerWithdraw) (event.Subscription, error) { + + logs, sub, err := _LLOFeeManager.contract.WatchLogs(opts, "Withdraw") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LLOFeeManagerWithdraw) + if err := _LLOFeeManager.contract.UnpackLog(event, "Withdraw", 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 (_LLOFeeManager *LLOFeeManagerFilterer) ParseWithdraw(log types.Log) (*LLOFeeManagerWithdraw, error) { + event := new(LLOFeeManagerWithdraw) + if err := _LLOFeeManager.contract.UnpackLog(event, "Withdraw", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_LLOFeeManager *LLOFeeManager) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _LLOFeeManager.abi.Events["InsufficientLink"].ID: + return _LLOFeeManager.ParseInsufficientLink(log) + case _LLOFeeManager.abi.Events["NativeSurchargeSet"].ID: + return _LLOFeeManager.ParseNativeSurchargeSet(log) + case _LLOFeeManager.abi.Events["OwnershipTransferRequested"].ID: + return _LLOFeeManager.ParseOwnershipTransferRequested(log) + case _LLOFeeManager.abi.Events["OwnershipTransferred"].ID: + return _LLOFeeManager.ParseOwnershipTransferred(log) + case _LLOFeeManager.abi.Events["SubscriberDiscountUpdated"].ID: + return _LLOFeeManager.ParseSubscriberDiscountUpdated(log) + case _LLOFeeManager.abi.Events["Withdraw"].ID: + return _LLOFeeManager.ParseWithdraw(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (LLOFeeManagerInsufficientLink) Topic() common.Hash { + return common.HexToHash("0xeb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7") +} + +func (LLOFeeManagerNativeSurchargeSet) Topic() common.Hash { + return common.HexToHash("0x4fbcc2b7f4cb5518be923bd7c7c887e29e07b001e2a4a0fdd47c494696d8a147") +} + +func (LLOFeeManagerOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (LLOFeeManagerOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (LLOFeeManagerSubscriberDiscountUpdated) Topic() common.Hash { + return common.HexToHash("0x41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84") +} + +func (LLOFeeManagerWithdraw) Topic() common.Hash { + return common.HexToHash("0x9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb") +} + +func (_LLOFeeManager *LLOFeeManager) Address() common.Address { + return _LLOFeeManager.address +} + +type LLOFeeManagerInterface interface { + GetFeeAndReward(opts *bind.CallOpts, subscriber common.Address, report []byte, quote IFeeManagerQuote) (CommonAsset, CommonAsset, error) + + LinkAvailableForPayment(opts *bind.CallOpts) (*big.Int, error) + + NativeSurcharge(opts *bind.CallOpts) (*big.Int, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SubscriberDiscounts(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + ProcessFee(opts *bind.TransactOpts, payload []byte, subscriber common.Address) (*types.Transaction, error) + + SetFeeRecipients(opts *bind.TransactOpts, configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + + SetNativeSurcharge(opts *bind.TransactOpts, surcharge *big.Int) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + UpdateSubscriberDiscount(opts *bind.TransactOpts, subscriber common.Address, feedId [32]byte, token common.Address, discount *big.Int) (*types.Transaction, error) + + Withdraw(opts *bind.TransactOpts, assetAddress common.Address, quantity *big.Int) (*types.Transaction, error) + + FilterInsufficientLink(opts *bind.FilterOpts, configDigest [][32]byte) (*LLOFeeManagerInsufficientLinkIterator, error) + + WatchInsufficientLink(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerInsufficientLink, configDigest [][32]byte) (event.Subscription, error) + + ParseInsufficientLink(log types.Log) (*LLOFeeManagerInsufficientLink, error) + + FilterNativeSurchargeSet(opts *bind.FilterOpts) (*LLOFeeManagerNativeSurchargeSetIterator, error) + + WatchNativeSurchargeSet(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerNativeSurchargeSet) (event.Subscription, error) + + ParseNativeSurchargeSet(log types.Log) (*LLOFeeManagerNativeSurchargeSet, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LLOFeeManagerOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*LLOFeeManagerOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LLOFeeManagerOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*LLOFeeManagerOwnershipTransferred, error) + + FilterSubscriberDiscountUpdated(opts *bind.FilterOpts, subscriber []common.Address, feedId [][32]byte) (*LLOFeeManagerSubscriberDiscountUpdatedIterator, error) + + WatchSubscriberDiscountUpdated(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerSubscriberDiscountUpdated, subscriber []common.Address, feedId [][32]byte) (event.Subscription, error) + + ParseSubscriberDiscountUpdated(log types.Log) (*LLOFeeManagerSubscriberDiscountUpdated, error) + + FilterWithdraw(opts *bind.FilterOpts) (*LLOFeeManagerWithdrawIterator, error) + + WatchWithdraw(opts *bind.WatchOpts, sink chan<- *LLOFeeManagerWithdraw) (event.Subscription, error) + + ParseWithdraw(log types.Log) (*LLOFeeManagerWithdraw, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/llo_feeds_test/llo_feeds_test.go b/core/gethwrappers/llo-feeds/generated/llo_feeds_test/llo_feeds_test.go new file mode 100644 index 00000000000..51f0f6e462e --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/llo_feeds_test/llo_feeds_test.go @@ -0,0 +1,202 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package llo_feeds_test + +import ( + "errors" + "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" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var LLOExposedVerifierMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_feedId\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_chainId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"_configCount\",\"type\":\"uint64\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"_offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_encodedConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_encodedConfig\",\"type\":\"bytes\"}],\"name\":\"exposedConfigDigestFromConfigData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610696806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80630ebd702314610030575b600080fd5b61004361003e3660046103f7565b610055565b60405190815260200160405180910390f35b60006100a18c8c8c8c8c8c8c8c8c8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508e92508d91506100b19050565b9c9b505050505050505050505050565b6000808b8b8b8b8b8b8b8b8b8b6040516020016100d79a999897969594939291906105a7565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e06000000000000000000000000000000000000000000000000000000000000179150509a9950505050505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461018357600080fd5b919050565b803567ffffffffffffffff8116811461018357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610216576102166101a0565b604052919050565b600067ffffffffffffffff821115610238576102386101a0565b5060051b60200190565b600082601f83011261025357600080fd5b813560206102686102638361021e565b6101cf565b82815260059290921b8401810191818101908684111561028757600080fd5b8286015b848110156102a95761029c8161015f565b835291830191830161028b565b509695505050505050565b600082601f8301126102c557600080fd5b813560206102d56102638361021e565b82815260059290921b840181019181810190868411156102f457600080fd5b8286015b848110156102a957803583529183019183016102f8565b803560ff8116811461018357600080fd5b60008083601f84011261033257600080fd5b50813567ffffffffffffffff81111561034a57600080fd5b60208301915083602082850101111561036257600080fd5b9250929050565b600082601f83011261037a57600080fd5b813567ffffffffffffffff811115610394576103946101a0565b6103c560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016101cf565b8181528460208386010111156103da57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060008060006101408c8e03121561041957600080fd5b8b359a5060208c0135995061043060408d0161015f565b985061043e60608d01610188565b975067ffffffffffffffff8060808e0135111561045a57600080fd5b61046a8e60808f01358f01610242565b97508060a08e0135111561047d57600080fd5b61048d8e60a08f01358f016102b4565b965061049b60c08e0161030f565b95508060e08e013511156104ae57600080fd5b6104be8e60e08f01358f01610320565b90955093506104d06101008e01610188565b9250806101208e013511156104e457600080fd5b506104f68d6101208e01358e01610369565b90509295989b509295989b9093969950565b600081518084526020808501945080840160005b838110156105385781518752958201959082019060010161051c565b509495945050505050565b6000815180845260005b818110156105695760208185018101518683018201520161054d565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b8a815260208082018b905273ffffffffffffffffffffffffffffffffffffffff8a8116604084015267ffffffffffffffff8a1660608401526101406080840181905289519084018190526000926101608501928b820192855b8181101561061e578451831686529483019493830193600101610600565b505050505082810360a08401526106358189610508565b60ff881660c0850152905082810360e08401526106528187610543565b67ffffffffffffffff861661010085015290508281036101208401526106788185610543565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", +} + +var LLOExposedVerifierABI = LLOExposedVerifierMetaData.ABI + +var LLOExposedVerifierBin = LLOExposedVerifierMetaData.Bin + +func DeployLLOExposedVerifier(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *LLOExposedVerifier, error) { + parsed, err := LLOExposedVerifierMetaData.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(LLOExposedVerifierBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &LLOExposedVerifier{LLOExposedVerifierCaller: LLOExposedVerifierCaller{contract: contract}, LLOExposedVerifierTransactor: LLOExposedVerifierTransactor{contract: contract}, LLOExposedVerifierFilterer: LLOExposedVerifierFilterer{contract: contract}}, nil +} + +type LLOExposedVerifier struct { + address common.Address + abi abi.ABI + LLOExposedVerifierCaller + LLOExposedVerifierTransactor + LLOExposedVerifierFilterer +} + +type LLOExposedVerifierCaller struct { + contract *bind.BoundContract +} + +type LLOExposedVerifierTransactor struct { + contract *bind.BoundContract +} + +type LLOExposedVerifierFilterer struct { + contract *bind.BoundContract +} + +type LLOExposedVerifierSession struct { + Contract *LLOExposedVerifier + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type LLOExposedVerifierCallerSession struct { + Contract *LLOExposedVerifierCaller + CallOpts bind.CallOpts +} + +type LLOExposedVerifierTransactorSession struct { + Contract *LLOExposedVerifierTransactor + TransactOpts bind.TransactOpts +} + +type LLOExposedVerifierRaw struct { + Contract *LLOExposedVerifier +} + +type LLOExposedVerifierCallerRaw struct { + Contract *LLOExposedVerifierCaller +} + +type LLOExposedVerifierTransactorRaw struct { + Contract *LLOExposedVerifierTransactor +} + +func NewLLOExposedVerifier(address common.Address, backend bind.ContractBackend) (*LLOExposedVerifier, error) { + abi, err := abi.JSON(strings.NewReader(LLOExposedVerifierABI)) + if err != nil { + return nil, err + } + contract, err := bindLLOExposedVerifier(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &LLOExposedVerifier{address: address, abi: abi, LLOExposedVerifierCaller: LLOExposedVerifierCaller{contract: contract}, LLOExposedVerifierTransactor: LLOExposedVerifierTransactor{contract: contract}, LLOExposedVerifierFilterer: LLOExposedVerifierFilterer{contract: contract}}, nil +} + +func NewLLOExposedVerifierCaller(address common.Address, caller bind.ContractCaller) (*LLOExposedVerifierCaller, error) { + contract, err := bindLLOExposedVerifier(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &LLOExposedVerifierCaller{contract: contract}, nil +} + +func NewLLOExposedVerifierTransactor(address common.Address, transactor bind.ContractTransactor) (*LLOExposedVerifierTransactor, error) { + contract, err := bindLLOExposedVerifier(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &LLOExposedVerifierTransactor{contract: contract}, nil +} + +func NewLLOExposedVerifierFilterer(address common.Address, filterer bind.ContractFilterer) (*LLOExposedVerifierFilterer, error) { + contract, err := bindLLOExposedVerifier(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &LLOExposedVerifierFilterer{contract: contract}, nil +} + +func bindLLOExposedVerifier(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := LLOExposedVerifierMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_LLOExposedVerifier *LLOExposedVerifierRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _LLOExposedVerifier.Contract.LLOExposedVerifierCaller.contract.Call(opts, result, method, params...) +} + +func (_LLOExposedVerifier *LLOExposedVerifierRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LLOExposedVerifier.Contract.LLOExposedVerifierTransactor.contract.Transfer(opts) +} + +func (_LLOExposedVerifier *LLOExposedVerifierRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _LLOExposedVerifier.Contract.LLOExposedVerifierTransactor.contract.Transact(opts, method, params...) +} + +func (_LLOExposedVerifier *LLOExposedVerifierCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _LLOExposedVerifier.Contract.contract.Call(opts, result, method, params...) +} + +func (_LLOExposedVerifier *LLOExposedVerifierTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LLOExposedVerifier.Contract.contract.Transfer(opts) +} + +func (_LLOExposedVerifier *LLOExposedVerifierTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _LLOExposedVerifier.Contract.contract.Transact(opts, method, params...) +} + +func (_LLOExposedVerifier *LLOExposedVerifierCaller) ExposedConfigDigestFromConfigData(opts *bind.CallOpts, _feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { + var out []interface{} + err := _LLOExposedVerifier.contract.Call(opts, &out, "exposedConfigDigestFromConfigData", _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_LLOExposedVerifier *LLOExposedVerifierSession) ExposedConfigDigestFromConfigData(_feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { + return _LLOExposedVerifier.Contract.ExposedConfigDigestFromConfigData(&_LLOExposedVerifier.CallOpts, _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) +} + +func (_LLOExposedVerifier *LLOExposedVerifierCallerSession) ExposedConfigDigestFromConfigData(_feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { + return _LLOExposedVerifier.Contract.ExposedConfigDigestFromConfigData(&_LLOExposedVerifier.CallOpts, _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) +} + +func (_LLOExposedVerifier *LLOExposedVerifier) Address() common.Address { + return _LLOExposedVerifier.address +} + +type LLOExposedVerifierInterface interface { + ExposedConfigDigestFromConfigData(opts *bind.CallOpts, _feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go b/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go new file mode 100644 index 00000000000..d533c426c26 --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go @@ -0,0 +1,1344 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package reward_manager + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + +var RewardManagerMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPoolId\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidWeights\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newFeeManagerAddress\",\"type\":\"address\"}],\"name\":\"FeeManagerUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"FeePaid\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"newRewardRecipients\",\"type\":\"tuple[]\"}],\"name\":\"RewardRecipientsUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"RewardsClaimed\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"poolIds\",\"type\":\"bytes32[]\"}],\"name\":\"claimRewards\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getAvailableRewardPoolIds\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"onFeePaid\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"recipients\",\"type\":\"address[]\"}],\"name\":\"payRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeManagerAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_registeredPoolIds\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_rewardRecipientWeights\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_totalRewardRecipientFees\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newFeeManagerAddress\",\"type\":\"address\"}],\"name\":\"setFeeManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setRewardRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"newRewardRecipients\",\"type\":\"tuple[]\"}],\"name\":\"updateRewardRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620019ce380380620019ce8339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b6080516117d3620001fb600039600081816109f10152610dda01526117d36000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c80636992922f11610097578063cd5f729211610066578063cd5f7292146102e0578063efb03fe9146102f3578063f2fde38b14610306578063f34517aa1461031957600080fd5b80636992922f1461026f57806379ba50971461028f5780638ac85a5c146102975780638da5cb5b146102c257600080fd5b806339ee81e1116100d357806339ee81e114610208578063472d35b9146102365780634d32208414610249578063633b5f6e1461025c57600080fd5b806301ffc9a7146101055780630f3c34d11461016f578063181f5a7714610184578063276e7660146101c3575b600080fd5b61015a61011336600461127a565b7fffffffff00000000000000000000000000000000000000000000000000000000167fefb03fe9000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b61018261017d36600461133a565b61032c565b005b604080518082018252601381527f5265776172644d616e6167657220302e302e31000000000000000000000000006020820152905161016691906113e0565b6007546101e39073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610166565b61022861021636600461144c565b60026020526000908152604090205481565b604051908152602001610166565b61018261024436600461148e565b61033a565b6101826102573660046114b0565b610408565b61018261026a36600461152f565b61053f565b61028261027d36600461148e565b6106f5565b604051610166919061159b565b6101826107f1565b6102286102a53660046115df565b600460209081526000928352604080842090915290825290205481565b60005473ffffffffffffffffffffffffffffffffffffffff166101e3565b6102286102ee36600461144c565b6108f3565b61018261030136600461160b565b610914565b61018261031436600461148e565b610aba565b61018261032736600461152f565b610ace565b6103363382610c48565b5050565b610342610e52565b73ffffffffffffffffffffffffffffffffffffffff811661038f576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527fe45f5e140399b0a7e12971ab020724b828fbed8ac408c420884dc7d1bbe506b49060200160405180910390a150565b8261042860005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415801561047a57506000818152600460209081526040808320338452909152902054155b156104b1576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160018082528183019092526000916020808301908036833701905050905084816000815181106104e7576104e7611640565b60200260200101818152505060005b838110156105375761052e85858381811061051357610513611640565b9050602002016020810190610528919061148e565b83610c48565b506001016104f6565b505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061057f575060075473ffffffffffffffffffffffffffffffffffffffff163314155b156105b6576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008190036105f1576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526005602052604090205460ff161561063a576040517f0afa7ee800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006805460018181019092557ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f01849055600084815260056020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690911790556106b6838383670de0b6b3a7640000610ed5565b827fe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b38419683836040516106e892919061166f565b60405180910390a2505050565b60065460609060008167ffffffffffffffff811115610716576107166112bc565b60405190808252806020026020018201604052801561073f578160200160208202803683370190505b5090506000805b838110156107e75760006006828154811061076357610763611640565b600091825260208083209091015480835260048252604080842073ffffffffffffffffffffffffffffffffffffffff8c168552909252912054909150156107de57600081815260026020526040902054156107de57808484815181106107cb576107cb611640565b6020026020010181815250508260010192505b50600101610746565b5090949350505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610877576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6006818154811061090357600080fd5b600091825260209091200154905081565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610954575060075473ffffffffffffffffffffffffffffffffffffffff163314155b1561098b576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526002602052604090819020805483019055517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8381166004830152306024830152604482018390527f000000000000000000000000000000000000000000000000000000000000000016906323b872dd906064016020604051808303816000875af1158015610a3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a5e91906116d3565b506040805184815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f0ae7c9bfbc7dfc3426a34852f9a1cdd2f750abec8190abbff0bbe13d8118c30c9060600160405180910390a1505050565b610ac2610e52565b610acb816110ce565b50565b610ad6610e52565b604080516001808252818301909252600091602080830190803683370190505090508381600081518110610b0c57610b0c611640565b6020026020010181815250506000805b83811015610bfa576000858583818110610b3857610b38611640565b610b4e926020604090920201908101915061148e565b600088815260046020908152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152812054919250819003610bba576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610beb878785818110610bcf57610bcf611640565b610be5926020604090920201908101915061148e565b86610c48565b50929092019150600101610b1c565b50610c0785858584610ed5565b847fe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b3841968585604051610c3992919061166f565b60405180910390a25050505050565b60008060005b8351811015610d87576000848281518110610c6b57610c6b611640565b6020908102919091018101516000818152600283526040808220546003855281832073ffffffffffffffffffffffffffffffffffffffff8c16808552908652828420548585526004875283852091855295529082205492945092830391670de0b6b3a76400009083020490819003610ce65750505050610d77565b600084815260036020908152604080832073ffffffffffffffffffffffffffffffffffffffff8d168085529252909120849055885196820196899087908110610d3157610d31611640565b60200260200101517ffec539b3c42d74cd492c3ecf7966bf014b327beef98e935cdc3ec5e54a6901c783604051610d6a91815260200190565b60405180910390a3505050505b610d8081611724565b9050610c4e565b508015610e49576040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018390527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015610e23573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e4791906116d3565b505b90505b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610ed3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161086e565b565b610f308383808060200260200160405190810160405280939291908181526020016000905b82821015610f2657610f176040830286013681900381019061175c565b81526020019060010190610efa565b50505050506111c3565b15610f67576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b8381101561108d576000858583818110610f8757610f87611640565b9050604002016020013590506000868684818110610fa757610fa7611640565b610fbd926020604090920201908101915061148e565b905073ffffffffffffffffffffffffffffffffffffffff811661100c576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81600003611046576040517f84677ce800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600088815260046020908152604080832073ffffffffffffffffffffffffffffffffffffffff909416835292905220819055919091019061108681611724565b9050610f6b565b508181146110c7576040517f84677ce800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361114d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161086e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000805b82518110156112715760006111dd8260016117b3565b90505b8351811015611268578381815181106111fb576111fb611640565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1684838151811061122f5761122f611640565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1603611260575060019392505050565b6001016111e0565b506001016111c7565b50600092915050565b60006020828403121561128c57600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610e4957600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611332576113326112bc565b604052919050565b6000602080838503121561134d57600080fd5b823567ffffffffffffffff8082111561136557600080fd5b818501915085601f83011261137957600080fd5b81358181111561138b5761138b6112bc565b8060051b915061139c8483016112eb565b81815291830184019184810190888411156113b657600080fd5b938501935b838510156113d4578435825293850193908501906113bb565b98975050505050505050565b600060208083528351808285015260005b8181101561140d578581018301518582016040015282016113f1565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60006020828403121561145e57600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461148957600080fd5b919050565b6000602082840312156114a057600080fd5b6114a982611465565b9392505050565b6000806000604084860312156114c557600080fd5b83359250602084013567ffffffffffffffff808211156114e457600080fd5b818601915086601f8301126114f857600080fd5b81358181111561150757600080fd5b8760208260051b850101111561151c57600080fd5b6020830194508093505050509250925092565b60008060006040848603121561154457600080fd5b83359250602084013567ffffffffffffffff8082111561156357600080fd5b818601915086601f83011261157757600080fd5b81358181111561158657600080fd5b8760208260061b850101111561151c57600080fd5b6020808252825182820181905260009190848201906040850190845b818110156115d3578351835292840192918401916001016115b7565b50909695505050505050565b600080604083850312156115f257600080fd5b8235915061160260208401611465565b90509250929050565b60008060006060848603121561162057600080fd5b8335925061163060208501611465565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020808252818101839052600090604080840186845b878110156116c65773ffffffffffffffffffffffffffffffffffffffff6116ab83611465565b16835281850135858401529183019190830190600101611685565b5090979650505050505050565b6000602082840312156116e557600080fd5b81518015158114610e4957600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611755576117556116f5565b5060010190565b60006040828403121561176e57600080fd5b6040516040810181811067ffffffffffffffff82111715611791576117916112bc565b60405261179d83611465565b8152602083013560208201528091505092915050565b80820180821115610e4c57610e4c6116f556fea164736f6c6343000810000a", +} + +var RewardManagerABI = RewardManagerMetaData.ABI + +var RewardManagerBin = RewardManagerMetaData.Bin + +func DeployRewardManager(auth *bind.TransactOpts, backend bind.ContractBackend, linkAddress common.Address) (common.Address, *types.Transaction, *RewardManager, error) { + parsed, err := RewardManagerMetaData.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(RewardManagerBin), backend, linkAddress) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &RewardManager{RewardManagerCaller: RewardManagerCaller{contract: contract}, RewardManagerTransactor: RewardManagerTransactor{contract: contract}, RewardManagerFilterer: RewardManagerFilterer{contract: contract}}, nil +} + +type RewardManager struct { + address common.Address + abi abi.ABI + RewardManagerCaller + RewardManagerTransactor + RewardManagerFilterer +} + +type RewardManagerCaller struct { + contract *bind.BoundContract +} + +type RewardManagerTransactor struct { + contract *bind.BoundContract +} + +type RewardManagerFilterer struct { + contract *bind.BoundContract +} + +type RewardManagerSession struct { + Contract *RewardManager + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type RewardManagerCallerSession struct { + Contract *RewardManagerCaller + CallOpts bind.CallOpts +} + +type RewardManagerTransactorSession struct { + Contract *RewardManagerTransactor + TransactOpts bind.TransactOpts +} + +type RewardManagerRaw struct { + Contract *RewardManager +} + +type RewardManagerCallerRaw struct { + Contract *RewardManagerCaller +} + +type RewardManagerTransactorRaw struct { + Contract *RewardManagerTransactor +} + +func NewRewardManager(address common.Address, backend bind.ContractBackend) (*RewardManager, error) { + abi, err := abi.JSON(strings.NewReader(RewardManagerABI)) + if err != nil { + return nil, err + } + contract, err := bindRewardManager(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &RewardManager{address: address, abi: abi, RewardManagerCaller: RewardManagerCaller{contract: contract}, RewardManagerTransactor: RewardManagerTransactor{contract: contract}, RewardManagerFilterer: RewardManagerFilterer{contract: contract}}, nil +} + +func NewRewardManagerCaller(address common.Address, caller bind.ContractCaller) (*RewardManagerCaller, error) { + contract, err := bindRewardManager(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &RewardManagerCaller{contract: contract}, nil +} + +func NewRewardManagerTransactor(address common.Address, transactor bind.ContractTransactor) (*RewardManagerTransactor, error) { + contract, err := bindRewardManager(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &RewardManagerTransactor{contract: contract}, nil +} + +func NewRewardManagerFilterer(address common.Address, filterer bind.ContractFilterer) (*RewardManagerFilterer, error) { + contract, err := bindRewardManager(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &RewardManagerFilterer{contract: contract}, nil +} + +func bindRewardManager(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := RewardManagerMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_RewardManager *RewardManagerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _RewardManager.Contract.RewardManagerCaller.contract.Call(opts, result, method, params...) +} + +func (_RewardManager *RewardManagerRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RewardManager.Contract.RewardManagerTransactor.contract.Transfer(opts) +} + +func (_RewardManager *RewardManagerRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _RewardManager.Contract.RewardManagerTransactor.contract.Transact(opts, method, params...) +} + +func (_RewardManager *RewardManagerCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _RewardManager.Contract.contract.Call(opts, result, method, params...) +} + +func (_RewardManager *RewardManagerTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RewardManager.Contract.contract.Transfer(opts) +} + +func (_RewardManager *RewardManagerTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _RewardManager.Contract.contract.Transact(opts, method, params...) +} + +func (_RewardManager *RewardManagerCaller) GetAvailableRewardPoolIds(opts *bind.CallOpts, recipient common.Address) ([][32]byte, error) { + var out []interface{} + err := _RewardManager.contract.Call(opts, &out, "getAvailableRewardPoolIds", recipient) + + if err != nil { + return *new([][32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([][32]byte)).(*[][32]byte) + + return out0, err + +} + +func (_RewardManager *RewardManagerSession) GetAvailableRewardPoolIds(recipient common.Address) ([][32]byte, error) { + return _RewardManager.Contract.GetAvailableRewardPoolIds(&_RewardManager.CallOpts, recipient) +} + +func (_RewardManager *RewardManagerCallerSession) GetAvailableRewardPoolIds(recipient common.Address) ([][32]byte, error) { + return _RewardManager.Contract.GetAvailableRewardPoolIds(&_RewardManager.CallOpts, recipient) +} + +func (_RewardManager *RewardManagerCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RewardManager.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 (_RewardManager *RewardManagerSession) Owner() (common.Address, error) { + return _RewardManager.Contract.Owner(&_RewardManager.CallOpts) +} + +func (_RewardManager *RewardManagerCallerSession) Owner() (common.Address, error) { + return _RewardManager.Contract.Owner(&_RewardManager.CallOpts) +} + +func (_RewardManager *RewardManagerCaller) SFeeManagerAddress(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _RewardManager.contract.Call(opts, &out, "s_feeManagerAddress") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_RewardManager *RewardManagerSession) SFeeManagerAddress() (common.Address, error) { + return _RewardManager.Contract.SFeeManagerAddress(&_RewardManager.CallOpts) +} + +func (_RewardManager *RewardManagerCallerSession) SFeeManagerAddress() (common.Address, error) { + return _RewardManager.Contract.SFeeManagerAddress(&_RewardManager.CallOpts) +} + +func (_RewardManager *RewardManagerCaller) SRegisteredPoolIds(opts *bind.CallOpts, arg0 *big.Int) ([32]byte, error) { + var out []interface{} + err := _RewardManager.contract.Call(opts, &out, "s_registeredPoolIds", arg0) + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_RewardManager *RewardManagerSession) SRegisteredPoolIds(arg0 *big.Int) ([32]byte, error) { + return _RewardManager.Contract.SRegisteredPoolIds(&_RewardManager.CallOpts, arg0) +} + +func (_RewardManager *RewardManagerCallerSession) SRegisteredPoolIds(arg0 *big.Int) ([32]byte, error) { + return _RewardManager.Contract.SRegisteredPoolIds(&_RewardManager.CallOpts, arg0) +} + +func (_RewardManager *RewardManagerCaller) SRewardRecipientWeights(opts *bind.CallOpts, arg0 [32]byte, arg1 common.Address) (*big.Int, error) { + var out []interface{} + err := _RewardManager.contract.Call(opts, &out, "s_rewardRecipientWeights", arg0, arg1) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_RewardManager *RewardManagerSession) SRewardRecipientWeights(arg0 [32]byte, arg1 common.Address) (*big.Int, error) { + return _RewardManager.Contract.SRewardRecipientWeights(&_RewardManager.CallOpts, arg0, arg1) +} + +func (_RewardManager *RewardManagerCallerSession) SRewardRecipientWeights(arg0 [32]byte, arg1 common.Address) (*big.Int, error) { + return _RewardManager.Contract.SRewardRecipientWeights(&_RewardManager.CallOpts, arg0, arg1) +} + +func (_RewardManager *RewardManagerCaller) STotalRewardRecipientFees(opts *bind.CallOpts, arg0 [32]byte) (*big.Int, error) { + var out []interface{} + err := _RewardManager.contract.Call(opts, &out, "s_totalRewardRecipientFees", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_RewardManager *RewardManagerSession) STotalRewardRecipientFees(arg0 [32]byte) (*big.Int, error) { + return _RewardManager.Contract.STotalRewardRecipientFees(&_RewardManager.CallOpts, arg0) +} + +func (_RewardManager *RewardManagerCallerSession) STotalRewardRecipientFees(arg0 [32]byte) (*big.Int, error) { + return _RewardManager.Contract.STotalRewardRecipientFees(&_RewardManager.CallOpts, arg0) +} + +func (_RewardManager *RewardManagerCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _RewardManager.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 (_RewardManager *RewardManagerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _RewardManager.Contract.SupportsInterface(&_RewardManager.CallOpts, interfaceId) +} + +func (_RewardManager *RewardManagerCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _RewardManager.Contract.SupportsInterface(&_RewardManager.CallOpts, interfaceId) +} + +func (_RewardManager *RewardManagerCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _RewardManager.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_RewardManager *RewardManagerSession) TypeAndVersion() (string, error) { + return _RewardManager.Contract.TypeAndVersion(&_RewardManager.CallOpts) +} + +func (_RewardManager *RewardManagerCallerSession) TypeAndVersion() (string, error) { + return _RewardManager.Contract.TypeAndVersion(&_RewardManager.CallOpts) +} + +func (_RewardManager *RewardManagerTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "acceptOwnership") +} + +func (_RewardManager *RewardManagerSession) AcceptOwnership() (*types.Transaction, error) { + return _RewardManager.Contract.AcceptOwnership(&_RewardManager.TransactOpts) +} + +func (_RewardManager *RewardManagerTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _RewardManager.Contract.AcceptOwnership(&_RewardManager.TransactOpts) +} + +func (_RewardManager *RewardManagerTransactor) ClaimRewards(opts *bind.TransactOpts, poolIds [][32]byte) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "claimRewards", poolIds) +} + +func (_RewardManager *RewardManagerSession) ClaimRewards(poolIds [][32]byte) (*types.Transaction, error) { + return _RewardManager.Contract.ClaimRewards(&_RewardManager.TransactOpts, poolIds) +} + +func (_RewardManager *RewardManagerTransactorSession) ClaimRewards(poolIds [][32]byte) (*types.Transaction, error) { + return _RewardManager.Contract.ClaimRewards(&_RewardManager.TransactOpts, poolIds) +} + +func (_RewardManager *RewardManagerTransactor) OnFeePaid(opts *bind.TransactOpts, poolId [32]byte, payee common.Address, amount *big.Int) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "onFeePaid", poolId, payee, amount) +} + +func (_RewardManager *RewardManagerSession) OnFeePaid(poolId [32]byte, payee common.Address, amount *big.Int) (*types.Transaction, error) { + return _RewardManager.Contract.OnFeePaid(&_RewardManager.TransactOpts, poolId, payee, amount) +} + +func (_RewardManager *RewardManagerTransactorSession) OnFeePaid(poolId [32]byte, payee common.Address, amount *big.Int) (*types.Transaction, error) { + return _RewardManager.Contract.OnFeePaid(&_RewardManager.TransactOpts, poolId, payee, amount) +} + +func (_RewardManager *RewardManagerTransactor) PayRecipients(opts *bind.TransactOpts, poolId [32]byte, recipients []common.Address) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "payRecipients", poolId, recipients) +} + +func (_RewardManager *RewardManagerSession) PayRecipients(poolId [32]byte, recipients []common.Address) (*types.Transaction, error) { + return _RewardManager.Contract.PayRecipients(&_RewardManager.TransactOpts, poolId, recipients) +} + +func (_RewardManager *RewardManagerTransactorSession) PayRecipients(poolId [32]byte, recipients []common.Address) (*types.Transaction, error) { + return _RewardManager.Contract.PayRecipients(&_RewardManager.TransactOpts, poolId, recipients) +} + +func (_RewardManager *RewardManagerTransactor) SetFeeManager(opts *bind.TransactOpts, newFeeManagerAddress common.Address) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "setFeeManager", newFeeManagerAddress) +} + +func (_RewardManager *RewardManagerSession) SetFeeManager(newFeeManagerAddress common.Address) (*types.Transaction, error) { + return _RewardManager.Contract.SetFeeManager(&_RewardManager.TransactOpts, newFeeManagerAddress) +} + +func (_RewardManager *RewardManagerTransactorSession) SetFeeManager(newFeeManagerAddress common.Address) (*types.Transaction, error) { + return _RewardManager.Contract.SetFeeManager(&_RewardManager.TransactOpts, newFeeManagerAddress) +} + +func (_RewardManager *RewardManagerTransactor) SetRewardRecipients(opts *bind.TransactOpts, poolId [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "setRewardRecipients", poolId, rewardRecipientAndWeights) +} + +func (_RewardManager *RewardManagerSession) SetRewardRecipients(poolId [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _RewardManager.Contract.SetRewardRecipients(&_RewardManager.TransactOpts, poolId, rewardRecipientAndWeights) +} + +func (_RewardManager *RewardManagerTransactorSession) SetRewardRecipients(poolId [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _RewardManager.Contract.SetRewardRecipients(&_RewardManager.TransactOpts, poolId, rewardRecipientAndWeights) +} + +func (_RewardManager *RewardManagerTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "transferOwnership", to) +} + +func (_RewardManager *RewardManagerSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _RewardManager.Contract.TransferOwnership(&_RewardManager.TransactOpts, to) +} + +func (_RewardManager *RewardManagerTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _RewardManager.Contract.TransferOwnership(&_RewardManager.TransactOpts, to) +} + +func (_RewardManager *RewardManagerTransactor) UpdateRewardRecipients(opts *bind.TransactOpts, poolId [32]byte, newRewardRecipients []CommonAddressAndWeight) (*types.Transaction, error) { + return _RewardManager.contract.Transact(opts, "updateRewardRecipients", poolId, newRewardRecipients) +} + +func (_RewardManager *RewardManagerSession) UpdateRewardRecipients(poolId [32]byte, newRewardRecipients []CommonAddressAndWeight) (*types.Transaction, error) { + return _RewardManager.Contract.UpdateRewardRecipients(&_RewardManager.TransactOpts, poolId, newRewardRecipients) +} + +func (_RewardManager *RewardManagerTransactorSession) UpdateRewardRecipients(poolId [32]byte, newRewardRecipients []CommonAddressAndWeight) (*types.Transaction, error) { + return _RewardManager.Contract.UpdateRewardRecipients(&_RewardManager.TransactOpts, poolId, newRewardRecipients) +} + +type RewardManagerFeeManagerUpdatedIterator struct { + Event *RewardManagerFeeManagerUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *RewardManagerFeeManagerUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardManagerFeeManagerUpdated) + 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(RewardManagerFeeManagerUpdated) + 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 *RewardManagerFeeManagerUpdatedIterator) Error() error { + return it.fail +} + +func (it *RewardManagerFeeManagerUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type RewardManagerFeeManagerUpdated struct { + NewFeeManagerAddress common.Address + Raw types.Log +} + +func (_RewardManager *RewardManagerFilterer) FilterFeeManagerUpdated(opts *bind.FilterOpts) (*RewardManagerFeeManagerUpdatedIterator, error) { + + logs, sub, err := _RewardManager.contract.FilterLogs(opts, "FeeManagerUpdated") + if err != nil { + return nil, err + } + return &RewardManagerFeeManagerUpdatedIterator{contract: _RewardManager.contract, event: "FeeManagerUpdated", logs: logs, sub: sub}, nil +} + +func (_RewardManager *RewardManagerFilterer) WatchFeeManagerUpdated(opts *bind.WatchOpts, sink chan<- *RewardManagerFeeManagerUpdated) (event.Subscription, error) { + + logs, sub, err := _RewardManager.contract.WatchLogs(opts, "FeeManagerUpdated") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(RewardManagerFeeManagerUpdated) + if err := _RewardManager.contract.UnpackLog(event, "FeeManagerUpdated", 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 (_RewardManager *RewardManagerFilterer) ParseFeeManagerUpdated(log types.Log) (*RewardManagerFeeManagerUpdated, error) { + event := new(RewardManagerFeeManagerUpdated) + if err := _RewardManager.contract.UnpackLog(event, "FeeManagerUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type RewardManagerFeePaidIterator struct { + Event *RewardManagerFeePaid + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *RewardManagerFeePaidIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardManagerFeePaid) + 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(RewardManagerFeePaid) + 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 *RewardManagerFeePaidIterator) Error() error { + return it.fail +} + +func (it *RewardManagerFeePaidIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type RewardManagerFeePaid struct { + PoolId [32]byte + Payee common.Address + Quantity *big.Int + Raw types.Log +} + +func (_RewardManager *RewardManagerFilterer) FilterFeePaid(opts *bind.FilterOpts) (*RewardManagerFeePaidIterator, error) { + + logs, sub, err := _RewardManager.contract.FilterLogs(opts, "FeePaid") + if err != nil { + return nil, err + } + return &RewardManagerFeePaidIterator{contract: _RewardManager.contract, event: "FeePaid", logs: logs, sub: sub}, nil +} + +func (_RewardManager *RewardManagerFilterer) WatchFeePaid(opts *bind.WatchOpts, sink chan<- *RewardManagerFeePaid) (event.Subscription, error) { + + logs, sub, err := _RewardManager.contract.WatchLogs(opts, "FeePaid") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(RewardManagerFeePaid) + if err := _RewardManager.contract.UnpackLog(event, "FeePaid", 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 (_RewardManager *RewardManagerFilterer) ParseFeePaid(log types.Log) (*RewardManagerFeePaid, error) { + event := new(RewardManagerFeePaid) + if err := _RewardManager.contract.UnpackLog(event, "FeePaid", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type RewardManagerOwnershipTransferRequestedIterator struct { + Event *RewardManagerOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *RewardManagerOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardManagerOwnershipTransferRequested) + 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(RewardManagerOwnershipTransferRequested) + 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 *RewardManagerOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *RewardManagerOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type RewardManagerOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_RewardManager *RewardManagerFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*RewardManagerOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _RewardManager.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &RewardManagerOwnershipTransferRequestedIterator{contract: _RewardManager.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_RewardManager *RewardManagerFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *RewardManagerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _RewardManager.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(RewardManagerOwnershipTransferRequested) + if err := _RewardManager.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_RewardManager *RewardManagerFilterer) ParseOwnershipTransferRequested(log types.Log) (*RewardManagerOwnershipTransferRequested, error) { + event := new(RewardManagerOwnershipTransferRequested) + if err := _RewardManager.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type RewardManagerOwnershipTransferredIterator struct { + Event *RewardManagerOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *RewardManagerOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardManagerOwnershipTransferred) + 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(RewardManagerOwnershipTransferred) + 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 *RewardManagerOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *RewardManagerOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type RewardManagerOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_RewardManager *RewardManagerFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*RewardManagerOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _RewardManager.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &RewardManagerOwnershipTransferredIterator{contract: _RewardManager.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_RewardManager *RewardManagerFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *RewardManagerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _RewardManager.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(RewardManagerOwnershipTransferred) + if err := _RewardManager.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 (_RewardManager *RewardManagerFilterer) ParseOwnershipTransferred(log types.Log) (*RewardManagerOwnershipTransferred, error) { + event := new(RewardManagerOwnershipTransferred) + if err := _RewardManager.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type RewardManagerRewardRecipientsUpdatedIterator struct { + Event *RewardManagerRewardRecipientsUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *RewardManagerRewardRecipientsUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardManagerRewardRecipientsUpdated) + 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(RewardManagerRewardRecipientsUpdated) + 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 *RewardManagerRewardRecipientsUpdatedIterator) Error() error { + return it.fail +} + +func (it *RewardManagerRewardRecipientsUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type RewardManagerRewardRecipientsUpdated struct { + PoolId [32]byte + NewRewardRecipients []CommonAddressAndWeight + Raw types.Log +} + +func (_RewardManager *RewardManagerFilterer) FilterRewardRecipientsUpdated(opts *bind.FilterOpts, poolId [][32]byte) (*RewardManagerRewardRecipientsUpdatedIterator, error) { + + var poolIdRule []interface{} + for _, poolIdItem := range poolId { + poolIdRule = append(poolIdRule, poolIdItem) + } + + logs, sub, err := _RewardManager.contract.FilterLogs(opts, "RewardRecipientsUpdated", poolIdRule) + if err != nil { + return nil, err + } + return &RewardManagerRewardRecipientsUpdatedIterator{contract: _RewardManager.contract, event: "RewardRecipientsUpdated", logs: logs, sub: sub}, nil +} + +func (_RewardManager *RewardManagerFilterer) WatchRewardRecipientsUpdated(opts *bind.WatchOpts, sink chan<- *RewardManagerRewardRecipientsUpdated, poolId [][32]byte) (event.Subscription, error) { + + var poolIdRule []interface{} + for _, poolIdItem := range poolId { + poolIdRule = append(poolIdRule, poolIdItem) + } + + logs, sub, err := _RewardManager.contract.WatchLogs(opts, "RewardRecipientsUpdated", poolIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(RewardManagerRewardRecipientsUpdated) + if err := _RewardManager.contract.UnpackLog(event, "RewardRecipientsUpdated", 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 (_RewardManager *RewardManagerFilterer) ParseRewardRecipientsUpdated(log types.Log) (*RewardManagerRewardRecipientsUpdated, error) { + event := new(RewardManagerRewardRecipientsUpdated) + if err := _RewardManager.contract.UnpackLog(event, "RewardRecipientsUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type RewardManagerRewardsClaimedIterator struct { + Event *RewardManagerRewardsClaimed + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *RewardManagerRewardsClaimedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(RewardManagerRewardsClaimed) + 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(RewardManagerRewardsClaimed) + 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 *RewardManagerRewardsClaimedIterator) Error() error { + return it.fail +} + +func (it *RewardManagerRewardsClaimedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type RewardManagerRewardsClaimed struct { + PoolId [32]byte + Recipient common.Address + Quantity *big.Int + Raw types.Log +} + +func (_RewardManager *RewardManagerFilterer) FilterRewardsClaimed(opts *bind.FilterOpts, poolId [][32]byte, recipient []common.Address) (*RewardManagerRewardsClaimedIterator, error) { + + var poolIdRule []interface{} + for _, poolIdItem := range poolId { + poolIdRule = append(poolIdRule, poolIdItem) + } + var recipientRule []interface{} + for _, recipientItem := range recipient { + recipientRule = append(recipientRule, recipientItem) + } + + logs, sub, err := _RewardManager.contract.FilterLogs(opts, "RewardsClaimed", poolIdRule, recipientRule) + if err != nil { + return nil, err + } + return &RewardManagerRewardsClaimedIterator{contract: _RewardManager.contract, event: "RewardsClaimed", logs: logs, sub: sub}, nil +} + +func (_RewardManager *RewardManagerFilterer) WatchRewardsClaimed(opts *bind.WatchOpts, sink chan<- *RewardManagerRewardsClaimed, poolId [][32]byte, recipient []common.Address) (event.Subscription, error) { + + var poolIdRule []interface{} + for _, poolIdItem := range poolId { + poolIdRule = append(poolIdRule, poolIdItem) + } + var recipientRule []interface{} + for _, recipientItem := range recipient { + recipientRule = append(recipientRule, recipientItem) + } + + logs, sub, err := _RewardManager.contract.WatchLogs(opts, "RewardsClaimed", poolIdRule, recipientRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(RewardManagerRewardsClaimed) + if err := _RewardManager.contract.UnpackLog(event, "RewardsClaimed", 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 (_RewardManager *RewardManagerFilterer) ParseRewardsClaimed(log types.Log) (*RewardManagerRewardsClaimed, error) { + event := new(RewardManagerRewardsClaimed) + if err := _RewardManager.contract.UnpackLog(event, "RewardsClaimed", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_RewardManager *RewardManager) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _RewardManager.abi.Events["FeeManagerUpdated"].ID: + return _RewardManager.ParseFeeManagerUpdated(log) + case _RewardManager.abi.Events["FeePaid"].ID: + return _RewardManager.ParseFeePaid(log) + case _RewardManager.abi.Events["OwnershipTransferRequested"].ID: + return _RewardManager.ParseOwnershipTransferRequested(log) + case _RewardManager.abi.Events["OwnershipTransferred"].ID: + return _RewardManager.ParseOwnershipTransferred(log) + case _RewardManager.abi.Events["RewardRecipientsUpdated"].ID: + return _RewardManager.ParseRewardRecipientsUpdated(log) + case _RewardManager.abi.Events["RewardsClaimed"].ID: + return _RewardManager.ParseRewardsClaimed(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (RewardManagerFeeManagerUpdated) Topic() common.Hash { + return common.HexToHash("0xe45f5e140399b0a7e12971ab020724b828fbed8ac408c420884dc7d1bbe506b4") +} + +func (RewardManagerFeePaid) Topic() common.Hash { + return common.HexToHash("0x0ae7c9bfbc7dfc3426a34852f9a1cdd2f750abec8190abbff0bbe13d8118c30c") +} + +func (RewardManagerOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (RewardManagerOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (RewardManagerRewardRecipientsUpdated) Topic() common.Hash { + return common.HexToHash("0xe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b384196") +} + +func (RewardManagerRewardsClaimed) Topic() common.Hash { + return common.HexToHash("0xfec539b3c42d74cd492c3ecf7966bf014b327beef98e935cdc3ec5e54a6901c7") +} + +func (_RewardManager *RewardManager) Address() common.Address { + return _RewardManager.address +} + +type RewardManagerInterface interface { + GetAvailableRewardPoolIds(opts *bind.CallOpts, recipient common.Address) ([][32]byte, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SFeeManagerAddress(opts *bind.CallOpts) (common.Address, error) + + SRegisteredPoolIds(opts *bind.CallOpts, arg0 *big.Int) ([32]byte, error) + + SRewardRecipientWeights(opts *bind.CallOpts, arg0 [32]byte, arg1 common.Address) (*big.Int, error) + + STotalRewardRecipientFees(opts *bind.CallOpts, arg0 [32]byte) (*big.Int, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + ClaimRewards(opts *bind.TransactOpts, poolIds [][32]byte) (*types.Transaction, error) + + OnFeePaid(opts *bind.TransactOpts, poolId [32]byte, payee common.Address, amount *big.Int) (*types.Transaction, error) + + PayRecipients(opts *bind.TransactOpts, poolId [32]byte, recipients []common.Address) (*types.Transaction, error) + + SetFeeManager(opts *bind.TransactOpts, newFeeManagerAddress common.Address) (*types.Transaction, error) + + SetRewardRecipients(opts *bind.TransactOpts, poolId [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + UpdateRewardRecipients(opts *bind.TransactOpts, poolId [32]byte, newRewardRecipients []CommonAddressAndWeight) (*types.Transaction, error) + + FilterFeeManagerUpdated(opts *bind.FilterOpts) (*RewardManagerFeeManagerUpdatedIterator, error) + + WatchFeeManagerUpdated(opts *bind.WatchOpts, sink chan<- *RewardManagerFeeManagerUpdated) (event.Subscription, error) + + ParseFeeManagerUpdated(log types.Log) (*RewardManagerFeeManagerUpdated, error) + + FilterFeePaid(opts *bind.FilterOpts) (*RewardManagerFeePaidIterator, error) + + WatchFeePaid(opts *bind.WatchOpts, sink chan<- *RewardManagerFeePaid) (event.Subscription, error) + + ParseFeePaid(log types.Log) (*RewardManagerFeePaid, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*RewardManagerOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *RewardManagerOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*RewardManagerOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*RewardManagerOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *RewardManagerOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*RewardManagerOwnershipTransferred, error) + + FilterRewardRecipientsUpdated(opts *bind.FilterOpts, poolId [][32]byte) (*RewardManagerRewardRecipientsUpdatedIterator, error) + + WatchRewardRecipientsUpdated(opts *bind.WatchOpts, sink chan<- *RewardManagerRewardRecipientsUpdated, poolId [][32]byte) (event.Subscription, error) + + ParseRewardRecipientsUpdated(log types.Log) (*RewardManagerRewardRecipientsUpdated, error) + + FilterRewardsClaimed(opts *bind.FilterOpts, poolId [][32]byte, recipient []common.Address) (*RewardManagerRewardsClaimedIterator, error) + + WatchRewardsClaimed(opts *bind.WatchOpts, sink chan<- *RewardManagerRewardsClaimed, poolId [][32]byte, recipient []common.Address) (event.Subscription, error) + + ParseRewardsClaimed(log types.Log) (*RewardManagerRewardsClaimed, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/verifier/verifier.go b/core/gethwrappers/llo-feeds/generated/verifier/verifier.go new file mode 100644 index 00000000000..d234e79e5e6 --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/verifier/verifier.go @@ -0,0 +1,1602 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package verifier + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + +var VerifierMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierProxyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"CannotDeactivateLatestConfig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DigestEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestInactive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestNotSet\",\"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\":[],\"name\":\"FeedIdEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InactiveFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"expectedNumSigners\",\"type\":\"uint256\"}],\"name\":\"IncorrectSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InvalidFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rsLength\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"ssLength\",\"type\":\"uint256\"}],\"name\":\"MismatchedSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NonUniqueSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedDeactivated\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"}],\"name\":\"ReportVerified\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"recipientAddressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"isVerifier\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162002150380380620021508339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051611f55620001fb6000396000818161031d015261091e0152611f556000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806379ba50971161008c578063b70d929d11610066578063b70d929d14610221578063ded6307c14610280578063e84f128e14610293578063f2fde38b146102f057600080fd5b806379ba5097146101de5780638da5cb5b146101e657806394d959801461020e57600080fd5b80633dd86430116100bd5780633dd86430146101a357806352ba27d6146101b8578063564a0a7a146101cb57600080fd5b806301ffc9a7146100e4578063181f5a771461014e5780633d3ac1b514610190575b600080fd5b6101396100f2366004611487565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b60408051808201909152600e81527f566572696669657220312e312e3000000000000000000000000000000000000060208201525b6040516101459190611534565b61018361019e366004611570565b610303565b6101b66101b13660046115f1565b61049d565b005b6101b66101c6366004611902565b61054f565b6101b66101d93660046115f1565b610a3f565b6101b6610b00565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610145565b6101b661021c3660046119ff565b610bfd565b61025d61022f3660046115f1565b6000908152600260205260408120600181015490549192909168010000000000000000900463ffffffff1690565b604080519315158452602084019290925263ffffffff1690820152606001610145565b6101b661028e3660046119ff565b610d5e565b6102cd6102a13660046115f1565b6000908152600260205260409020805460019091015463ffffffff808316936401000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610145565b6101b66102fe366004611a21565b610e6f565b60603373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610374576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080610386888a018a611a3c565b9450945094509450945060008461039c90611b17565b60008181526002602052604090208054919250906c01000000000000000000000000900460ff1615610402576040517f36dbe748000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b8651600081815260028301602052604090206104218483898985610e83565b61042b8984610f7f565b87516020890120610440818b8a8a8a87610fe7565b60405173ffffffffffffffffffffffffffffffffffffffff8d16815285907f58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc59060200160405180910390a250969c9b505050505050505050505050565b6104a5611263565b60008181526002602052604081208054909163ffffffff90911690036104fa576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff16815560405182907ff438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b490600090a25050565b86518560ff168060000361058f576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8211156105d4576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f60248201526044016103f9565b6105df816003611bba565b821161063757816105f1826003611bba565b6105fc906001611bf7565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b61063f611263565b60008a81526002602052604081208054909163ffffffff90911690829061066583611c10565b82546101009290920a63ffffffff81810219909316918316021790915582546000925061069a918e91168d8d8d8d8d8d6112e6565b6000818152600284016020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8d16176101001790559091505b8b518160ff1610156108db5760008c8260ff168151811061070057610700611b5c565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610770576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452600190810190925290912054610100900460ff16908111156107c3576107c3611c33565b14801591506107fe576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805180820190915260ff8416815260208101600190526000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684526001908101835292208351815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00821681178355928501519193919284927fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090921617906101009084908111156108c0576108c0611c33565b02179055509050505050806108d490611c62565b90506106dd565b5060018201546040517f589ede2800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169163589ede2891610956919085908a90600401611c81565b600060405180830381600087803b15801561097057600080fd5b505af1158015610984573d6000803e3d6000fd5b505050508b7fa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da8360000160049054906101000a900463ffffffff16838560000160009054906101000a900463ffffffff168f8f8f8f8f8f6040516109f099989796959493929190611d78565b60405180910390a281547fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff1664010000000063ffffffff43160217825560019091015550505050505050505050565b610a47611263565b60008181526002602052604081208054909163ffffffff9091169003610a9c576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff166c0100000000000000000000000017815560405182907ffc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd06190600090a25050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016103f9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c05611263565b600082815260026020526040902081610c4a576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610ca0576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b80600101548203610ce7576040517fa403c01600000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555183907f0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c90610d519085815260200190565b60405180910390a2505050565b610d66611263565b600082815260026020526040902081610dab576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610e01576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555183907f54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe774690610d519085815260200190565b610e77611263565b610e8081611392565b50565b8054600090610e969060ff166001611e0e565b8254909150610100900460ff16610ee3576040517ffc10a28300000000000000000000000000000000000000000000000000000000815260048101879052602481018690526044016103f9565b8060ff16845114610f2f5783516040517f5348a282000000000000000000000000000000000000000000000000000000008152600481019190915260ff821660248201526044016103f9565b8251845114610f7757835183516040517ff0d31408000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b505050505050565b6020820151815463ffffffff600883901c81169168010000000000000000900416811115610fe15782547fffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffff166801000000000000000063ffffffff8316021783555b50505050565b60008686604051602001610ffc929190611e27565b6040516020818303038152906040528051906020012090506000611030604080518082019091526000808252602082015290565b8651600090815b818110156111fb5760018689836020811061105457611054611b5c565b61106191901a601b611e0e565b8c848151811061107357611073611b5c565b60200260200101518c858151811061108d5761108d611b5c565b6020026020010151604051600081526020016040526040516110cb949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156110ed573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526001808d01602090815291859020848601909552845460ff80821686529399509395509085019261010090049091169081111561117257611172611c33565b600181111561118357611183611c33565b90525093506001846020015160018111156111a0576111a0611c33565b146111d7576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836000015160080260ff166001901b85019450806111f490611e63565b9050611037565b50837e01010101010101010101010101010101010101010101010101010101010101851614611256576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146112e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103f9565b565b6000808946308b8b8b8b8b8b8b60405160200161130c9a99989796959493929190611e9b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e060000000000000000000000000000000000000000000000000000000000001791505098975050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603611411576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103f9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561149957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146114c957600080fd5b9392505050565b6000815180845260005b818110156114f6576020818501810151868301820152016114da565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114c960208301846114d0565b803573ffffffffffffffffffffffffffffffffffffffff8116811461156b57600080fd5b919050565b60008060006040848603121561158557600080fd5b833567ffffffffffffffff8082111561159d57600080fd5b818601915086601f8301126115b157600080fd5b8135818111156115c057600080fd5b8760208285010111156115d257600080fd5b6020928301955093506115e89186019050611547565b90509250925092565b60006020828403121561160357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561165c5761165c61160a565b60405290565b6040516060810167ffffffffffffffff8111828210171561165c5761165c61160a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156116cc576116cc61160a565b604052919050565b600067ffffffffffffffff8211156116ee576116ee61160a565b5060051b60200190565b600082601f83011261170957600080fd5b8135602061171e611719836116d4565b611685565b82815260059290921b8401810191818101908684111561173d57600080fd5b8286015b8481101561175f5761175281611547565b8352918301918301611741565b509695505050505050565b600082601f83011261177b57600080fd5b8135602061178b611719836116d4565b82815260059290921b840181019181810190868411156117aa57600080fd5b8286015b8481101561175f57803583529183019183016117ae565b803560ff8116811461156b57600080fd5b600082601f8301126117e757600080fd5b813567ffffffffffffffff8111156118015761180161160a565b61183260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611685565b81815284602083860101111561184757600080fd5b816020850160208301376000918101602001919091529392505050565b803567ffffffffffffffff8116811461156b57600080fd5b600082601f83011261188d57600080fd5b8135602061189d611719836116d4565b82815260069290921b840181019181810190868411156118bc57600080fd5b8286015b8481101561175f57604081890312156118d95760008081fd5b6118e1611639565b6118ea82611547565b815281850135858201528352918301916040016118c0565b600080600080600080600080610100898b03121561191f57600080fd5b88359750602089013567ffffffffffffffff8082111561193e57600080fd5b61194a8c838d016116f8565b985060408b013591508082111561196057600080fd5b61196c8c838d0161176a565b975061197a60608c016117c5565b965060808b013591508082111561199057600080fd5b61199c8c838d016117d6565b95506119aa60a08c01611864565b945060c08b01359150808211156119c057600080fd5b6119cc8c838d016117d6565b935060e08b01359150808211156119e257600080fd5b506119ef8b828c0161187c565b9150509295985092959890939650565b60008060408385031215611a1257600080fd5b50508035926020909101359150565b600060208284031215611a3357600080fd5b6114c982611547565b600080600080600060e08688031215611a5457600080fd5b86601f870112611a6357600080fd5b611a6b611662565b806060880189811115611a7d57600080fd5b885b81811015611a97578035845260209384019301611a7f565b5090965035905067ffffffffffffffff80821115611ab457600080fd5b611ac089838a016117d6565b95506080880135915080821115611ad657600080fd5b611ae289838a0161176a565b945060a0880135915080821115611af857600080fd5b50611b058882890161176a565b9598949750929560c001359392505050565b80516020808301519190811015611b56577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611bf257611bf2611b8b565b500290565b80820180821115611c0a57611c0a611b8b565b92915050565b600063ffffffff808316818103611c2957611c29611b8b565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600060ff821660ff8103611c7857611c78611b8b565b60010192915050565b600060608201858352602085818501526040606081860152828651808552608087019150838801945060005b81811015611ce8578551805173ffffffffffffffffffffffffffffffffffffffff168452850151858401529484019491830191600101611cad565b50909998505050505050505050565b600081518084526020808501945080840160005b83811015611d3d57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101611d0b565b509495945050505050565b600081518084526020808501945080840160005b83811015611d3d57815187529582019590820190600101611d5c565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152611da88184018a611cf7565b90508281036080840152611dbc8189611d48565b905060ff871660a084015282810360c0840152611dd981876114d0565b905067ffffffffffffffff851660e0840152828103610100840152611dfe81856114d0565b9c9b505050505050505050505050565b60ff8181168382160190811115611c0a57611c0a611b8b565b828152600060208083018460005b6003811015611e5257815183529183019190830190600101611e35565b505050506080820190509392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611e9457611e94611b8b565b5060010190565b60006101408c83528b602084015273ffffffffffffffffffffffffffffffffffffffff8b16604084015267ffffffffffffffff808b166060850152816080850152611ee88285018b611cf7565b915083820360a0850152611efc828a611d48565b915060ff881660c085015283820360e0850152611f1982886114d0565b9086166101008501528381036101208501529050611f3781856114d0565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", +} + +var VerifierABI = VerifierMetaData.ABI + +var VerifierBin = VerifierMetaData.Bin + +func DeployVerifier(auth *bind.TransactOpts, backend bind.ContractBackend, verifierProxyAddr common.Address) (common.Address, *types.Transaction, *Verifier, error) { + parsed, err := VerifierMetaData.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(VerifierBin), backend, verifierProxyAddr) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &Verifier{VerifierCaller: VerifierCaller{contract: contract}, VerifierTransactor: VerifierTransactor{contract: contract}, VerifierFilterer: VerifierFilterer{contract: contract}}, nil +} + +type Verifier struct { + address common.Address + abi abi.ABI + VerifierCaller + VerifierTransactor + VerifierFilterer +} + +type VerifierCaller struct { + contract *bind.BoundContract +} + +type VerifierTransactor struct { + contract *bind.BoundContract +} + +type VerifierFilterer struct { + contract *bind.BoundContract +} + +type VerifierSession struct { + Contract *Verifier + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type VerifierCallerSession struct { + Contract *VerifierCaller + CallOpts bind.CallOpts +} + +type VerifierTransactorSession struct { + Contract *VerifierTransactor + TransactOpts bind.TransactOpts +} + +type VerifierRaw struct { + Contract *Verifier +} + +type VerifierCallerRaw struct { + Contract *VerifierCaller +} + +type VerifierTransactorRaw struct { + Contract *VerifierTransactor +} + +func NewVerifier(address common.Address, backend bind.ContractBackend) (*Verifier, error) { + abi, err := abi.JSON(strings.NewReader(VerifierABI)) + if err != nil { + return nil, err + } + contract, err := bindVerifier(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &Verifier{address: address, abi: abi, VerifierCaller: VerifierCaller{contract: contract}, VerifierTransactor: VerifierTransactor{contract: contract}, VerifierFilterer: VerifierFilterer{contract: contract}}, nil +} + +func NewVerifierCaller(address common.Address, caller bind.ContractCaller) (*VerifierCaller, error) { + contract, err := bindVerifier(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &VerifierCaller{contract: contract}, nil +} + +func NewVerifierTransactor(address common.Address, transactor bind.ContractTransactor) (*VerifierTransactor, error) { + contract, err := bindVerifier(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &VerifierTransactor{contract: contract}, nil +} + +func NewVerifierFilterer(address common.Address, filterer bind.ContractFilterer) (*VerifierFilterer, error) { + contract, err := bindVerifier(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &VerifierFilterer{contract: contract}, nil +} + +func bindVerifier(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := VerifierMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_Verifier *VerifierRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _Verifier.Contract.VerifierCaller.contract.Call(opts, result, method, params...) +} + +func (_Verifier *VerifierRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _Verifier.Contract.VerifierTransactor.contract.Transfer(opts) +} + +func (_Verifier *VerifierRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _Verifier.Contract.VerifierTransactor.contract.Transact(opts, method, params...) +} + +func (_Verifier *VerifierCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _Verifier.Contract.contract.Call(opts, result, method, params...) +} + +func (_Verifier *VerifierTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _Verifier.Contract.contract.Transfer(opts) +} + +func (_Verifier *VerifierTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _Verifier.Contract.contract.Transact(opts, method, params...) +} + +func (_Verifier *VerifierCaller) LatestConfigDetails(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDetails, + + error) { + var out []interface{} + err := _Verifier.contract.Call(opts, &out, "latestConfigDetails", feedId) + + outstruct := new(LatestConfigDetails) + if err != nil { + return *outstruct, err + } + + outstruct.ConfigCount = *abi.ConvertType(out[0], new(uint32)).(*uint32) + outstruct.BlockNumber = *abi.ConvertType(out[1], new(uint32)).(*uint32) + outstruct.ConfigDigest = *abi.ConvertType(out[2], new([32]byte)).(*[32]byte) + + return *outstruct, err + +} + +func (_Verifier *VerifierSession) LatestConfigDetails(feedId [32]byte) (LatestConfigDetails, + + error) { + return _Verifier.Contract.LatestConfigDetails(&_Verifier.CallOpts, feedId) +} + +func (_Verifier *VerifierCallerSession) LatestConfigDetails(feedId [32]byte) (LatestConfigDetails, + + error) { + return _Verifier.Contract.LatestConfigDetails(&_Verifier.CallOpts, feedId) +} + +func (_Verifier *VerifierCaller) LatestConfigDigestAndEpoch(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDigestAndEpoch, + + error) { + var out []interface{} + err := _Verifier.contract.Call(opts, &out, "latestConfigDigestAndEpoch", feedId) + + outstruct := new(LatestConfigDigestAndEpoch) + if err != nil { + return *outstruct, err + } + + outstruct.ScanLogs = *abi.ConvertType(out[0], new(bool)).(*bool) + outstruct.ConfigDigest = *abi.ConvertType(out[1], new([32]byte)).(*[32]byte) + outstruct.Epoch = *abi.ConvertType(out[2], new(uint32)).(*uint32) + + return *outstruct, err + +} + +func (_Verifier *VerifierSession) LatestConfigDigestAndEpoch(feedId [32]byte) (LatestConfigDigestAndEpoch, + + error) { + return _Verifier.Contract.LatestConfigDigestAndEpoch(&_Verifier.CallOpts, feedId) +} + +func (_Verifier *VerifierCallerSession) LatestConfigDigestAndEpoch(feedId [32]byte) (LatestConfigDigestAndEpoch, + + error) { + return _Verifier.Contract.LatestConfigDigestAndEpoch(&_Verifier.CallOpts, feedId) +} + +func (_Verifier *VerifierCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _Verifier.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 (_Verifier *VerifierSession) Owner() (common.Address, error) { + return _Verifier.Contract.Owner(&_Verifier.CallOpts) +} + +func (_Verifier *VerifierCallerSession) Owner() (common.Address, error) { + return _Verifier.Contract.Owner(&_Verifier.CallOpts) +} + +func (_Verifier *VerifierCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _Verifier.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 (_Verifier *VerifierSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _Verifier.Contract.SupportsInterface(&_Verifier.CallOpts, interfaceId) +} + +func (_Verifier *VerifierCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _Verifier.Contract.SupportsInterface(&_Verifier.CallOpts, interfaceId) +} + +func (_Verifier *VerifierCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _Verifier.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_Verifier *VerifierSession) TypeAndVersion() (string, error) { + return _Verifier.Contract.TypeAndVersion(&_Verifier.CallOpts) +} + +func (_Verifier *VerifierCallerSession) TypeAndVersion() (string, error) { + return _Verifier.Contract.TypeAndVersion(&_Verifier.CallOpts) +} + +func (_Verifier *VerifierTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "acceptOwnership") +} + +func (_Verifier *VerifierSession) AcceptOwnership() (*types.Transaction, error) { + return _Verifier.Contract.AcceptOwnership(&_Verifier.TransactOpts) +} + +func (_Verifier *VerifierTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _Verifier.Contract.AcceptOwnership(&_Verifier.TransactOpts) +} + +func (_Verifier *VerifierTransactor) ActivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "activateConfig", feedId, configDigest) +} + +func (_Verifier *VerifierSession) ActivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.ActivateConfig(&_Verifier.TransactOpts, feedId, configDigest) +} + +func (_Verifier *VerifierTransactorSession) ActivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.ActivateConfig(&_Verifier.TransactOpts, feedId, configDigest) +} + +func (_Verifier *VerifierTransactor) ActivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "activateFeed", feedId) +} + +func (_Verifier *VerifierSession) ActivateFeed(feedId [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.ActivateFeed(&_Verifier.TransactOpts, feedId) +} + +func (_Verifier *VerifierTransactorSession) ActivateFeed(feedId [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.ActivateFeed(&_Verifier.TransactOpts, feedId) +} + +func (_Verifier *VerifierTransactor) DeactivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "deactivateConfig", feedId, configDigest) +} + +func (_Verifier *VerifierSession) DeactivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.DeactivateConfig(&_Verifier.TransactOpts, feedId, configDigest) +} + +func (_Verifier *VerifierTransactorSession) DeactivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.DeactivateConfig(&_Verifier.TransactOpts, feedId, configDigest) +} + +func (_Verifier *VerifierTransactor) DeactivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "deactivateFeed", feedId) +} + +func (_Verifier *VerifierSession) DeactivateFeed(feedId [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.DeactivateFeed(&_Verifier.TransactOpts, feedId) +} + +func (_Verifier *VerifierTransactorSession) DeactivateFeed(feedId [32]byte) (*types.Transaction, error) { + return _Verifier.Contract.DeactivateFeed(&_Verifier.TransactOpts, feedId) +} + +func (_Verifier *VerifierTransactor) SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "setConfig", feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) +} + +func (_Verifier *VerifierSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _Verifier.Contract.SetConfig(&_Verifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) +} + +func (_Verifier *VerifierTransactorSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _Verifier.Contract.SetConfig(&_Verifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) +} + +func (_Verifier *VerifierTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "transferOwnership", to) +} + +func (_Verifier *VerifierSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _Verifier.Contract.TransferOwnership(&_Verifier.TransactOpts, to) +} + +func (_Verifier *VerifierTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _Verifier.Contract.TransferOwnership(&_Verifier.TransactOpts, to) +} + +func (_Verifier *VerifierTransactor) Verify(opts *bind.TransactOpts, signedReport []byte, sender common.Address) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "verify", signedReport, sender) +} + +func (_Verifier *VerifierSession) Verify(signedReport []byte, sender common.Address) (*types.Transaction, error) { + return _Verifier.Contract.Verify(&_Verifier.TransactOpts, signedReport, sender) +} + +func (_Verifier *VerifierTransactorSession) Verify(signedReport []byte, sender common.Address) (*types.Transaction, error) { + return _Verifier.Contract.Verify(&_Verifier.TransactOpts, signedReport, sender) +} + +type VerifierConfigActivatedIterator struct { + Event *VerifierConfigActivated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierConfigActivatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierConfigActivated) + 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(VerifierConfigActivated) + 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 *VerifierConfigActivatedIterator) Error() error { + return it.fail +} + +func (it *VerifierConfigActivatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierConfigActivated struct { + FeedId [32]byte + ConfigDigest [32]byte + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterConfigActivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierConfigActivatedIterator, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "ConfigActivated", feedIdRule) + if err != nil { + return nil, err + } + return &VerifierConfigActivatedIterator{contract: _Verifier.contract, event: "ConfigActivated", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchConfigActivated(opts *bind.WatchOpts, sink chan<- *VerifierConfigActivated, feedId [][32]byte) (event.Subscription, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "ConfigActivated", feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierConfigActivated) + if err := _Verifier.contract.UnpackLog(event, "ConfigActivated", 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 (_Verifier *VerifierFilterer) ParseConfigActivated(log types.Log) (*VerifierConfigActivated, error) { + event := new(VerifierConfigActivated) + if err := _Verifier.contract.UnpackLog(event, "ConfigActivated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierConfigDeactivatedIterator struct { + Event *VerifierConfigDeactivated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierConfigDeactivatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierConfigDeactivated) + 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(VerifierConfigDeactivated) + 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 *VerifierConfigDeactivatedIterator) Error() error { + return it.fail +} + +func (it *VerifierConfigDeactivatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierConfigDeactivated struct { + FeedId [32]byte + ConfigDigest [32]byte + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterConfigDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierConfigDeactivatedIterator, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "ConfigDeactivated", feedIdRule) + if err != nil { + return nil, err + } + return &VerifierConfigDeactivatedIterator{contract: _Verifier.contract, event: "ConfigDeactivated", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchConfigDeactivated(opts *bind.WatchOpts, sink chan<- *VerifierConfigDeactivated, feedId [][32]byte) (event.Subscription, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "ConfigDeactivated", feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierConfigDeactivated) + if err := _Verifier.contract.UnpackLog(event, "ConfigDeactivated", 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 (_Verifier *VerifierFilterer) ParseConfigDeactivated(log types.Log) (*VerifierConfigDeactivated, error) { + event := new(VerifierConfigDeactivated) + if err := _Verifier.contract.UnpackLog(event, "ConfigDeactivated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierConfigSetIterator struct { + Event *VerifierConfigSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierConfigSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierConfigSet) + 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(VerifierConfigSet) + 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 *VerifierConfigSetIterator) Error() error { + return it.fail +} + +func (it *VerifierConfigSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierConfigSet struct { + FeedId [32]byte + PreviousConfigBlockNumber uint32 + ConfigDigest [32]byte + ConfigCount uint64 + Signers []common.Address + OffchainTransmitters [][32]byte + F uint8 + OnchainConfig []byte + OffchainConfigVersion uint64 + OffchainConfig []byte + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterConfigSet(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierConfigSetIterator, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "ConfigSet", feedIdRule) + if err != nil { + return nil, err + } + return &VerifierConfigSetIterator{contract: _Verifier.contract, event: "ConfigSet", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *VerifierConfigSet, feedId [][32]byte) (event.Subscription, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "ConfigSet", feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierConfigSet) + if err := _Verifier.contract.UnpackLog(event, "ConfigSet", 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 (_Verifier *VerifierFilterer) ParseConfigSet(log types.Log) (*VerifierConfigSet, error) { + event := new(VerifierConfigSet) + if err := _Verifier.contract.UnpackLog(event, "ConfigSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierFeedActivatedIterator struct { + Event *VerifierFeedActivated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierFeedActivatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierFeedActivated) + 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(VerifierFeedActivated) + 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 *VerifierFeedActivatedIterator) Error() error { + return it.fail +} + +func (it *VerifierFeedActivatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierFeedActivated struct { + FeedId [32]byte + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterFeedActivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierFeedActivatedIterator, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "FeedActivated", feedIdRule) + if err != nil { + return nil, err + } + return &VerifierFeedActivatedIterator{contract: _Verifier.contract, event: "FeedActivated", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchFeedActivated(opts *bind.WatchOpts, sink chan<- *VerifierFeedActivated, feedId [][32]byte) (event.Subscription, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "FeedActivated", feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierFeedActivated) + if err := _Verifier.contract.UnpackLog(event, "FeedActivated", 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 (_Verifier *VerifierFilterer) ParseFeedActivated(log types.Log) (*VerifierFeedActivated, error) { + event := new(VerifierFeedActivated) + if err := _Verifier.contract.UnpackLog(event, "FeedActivated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierFeedDeactivatedIterator struct { + Event *VerifierFeedDeactivated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierFeedDeactivatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierFeedDeactivated) + 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(VerifierFeedDeactivated) + 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 *VerifierFeedDeactivatedIterator) Error() error { + return it.fail +} + +func (it *VerifierFeedDeactivatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierFeedDeactivated struct { + FeedId [32]byte + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterFeedDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierFeedDeactivatedIterator, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "FeedDeactivated", feedIdRule) + if err != nil { + return nil, err + } + return &VerifierFeedDeactivatedIterator{contract: _Verifier.contract, event: "FeedDeactivated", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchFeedDeactivated(opts *bind.WatchOpts, sink chan<- *VerifierFeedDeactivated, feedId [][32]byte) (event.Subscription, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "FeedDeactivated", feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierFeedDeactivated) + if err := _Verifier.contract.UnpackLog(event, "FeedDeactivated", 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 (_Verifier *VerifierFilterer) ParseFeedDeactivated(log types.Log) (*VerifierFeedDeactivated, error) { + event := new(VerifierFeedDeactivated) + if err := _Verifier.contract.UnpackLog(event, "FeedDeactivated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierOwnershipTransferRequestedIterator struct { + Event *VerifierOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierOwnershipTransferRequested) + 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(VerifierOwnershipTransferRequested) + 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 *VerifierOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *VerifierOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &VerifierOwnershipTransferRequestedIterator{contract: _Verifier.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifierOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierOwnershipTransferRequested) + if err := _Verifier.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_Verifier *VerifierFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifierOwnershipTransferRequested, error) { + event := new(VerifierOwnershipTransferRequested) + if err := _Verifier.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierOwnershipTransferredIterator struct { + Event *VerifierOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierOwnershipTransferred) + 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(VerifierOwnershipTransferred) + 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 *VerifierOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *VerifierOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &VerifierOwnershipTransferredIterator{contract: _Verifier.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifierOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierOwnershipTransferred) + if err := _Verifier.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 (_Verifier *VerifierFilterer) ParseOwnershipTransferred(log types.Log) (*VerifierOwnershipTransferred, error) { + event := new(VerifierOwnershipTransferred) + if err := _Verifier.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierReportVerifiedIterator struct { + Event *VerifierReportVerified + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierReportVerifiedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierReportVerified) + 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(VerifierReportVerified) + 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 *VerifierReportVerifiedIterator) Error() error { + return it.fail +} + +func (it *VerifierReportVerifiedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierReportVerified struct { + FeedId [32]byte + Requester common.Address + Raw types.Log +} + +func (_Verifier *VerifierFilterer) FilterReportVerified(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierReportVerifiedIterator, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.FilterLogs(opts, "ReportVerified", feedIdRule) + if err != nil { + return nil, err + } + return &VerifierReportVerifiedIterator{contract: _Verifier.contract, event: "ReportVerified", logs: logs, sub: sub}, nil +} + +func (_Verifier *VerifierFilterer) WatchReportVerified(opts *bind.WatchOpts, sink chan<- *VerifierReportVerified, feedId [][32]byte) (event.Subscription, error) { + + var feedIdRule []interface{} + for _, feedIdItem := range feedId { + feedIdRule = append(feedIdRule, feedIdItem) + } + + logs, sub, err := _Verifier.contract.WatchLogs(opts, "ReportVerified", feedIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierReportVerified) + if err := _Verifier.contract.UnpackLog(event, "ReportVerified", 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 (_Verifier *VerifierFilterer) ParseReportVerified(log types.Log) (*VerifierReportVerified, error) { + event := new(VerifierReportVerified) + if err := _Verifier.contract.UnpackLog(event, "ReportVerified", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LatestConfigDetails struct { + ConfigCount uint32 + BlockNumber uint32 + ConfigDigest [32]byte +} +type LatestConfigDigestAndEpoch struct { + ScanLogs bool + ConfigDigest [32]byte + Epoch uint32 +} + +func (_Verifier *Verifier) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _Verifier.abi.Events["ConfigActivated"].ID: + return _Verifier.ParseConfigActivated(log) + case _Verifier.abi.Events["ConfigDeactivated"].ID: + return _Verifier.ParseConfigDeactivated(log) + case _Verifier.abi.Events["ConfigSet"].ID: + return _Verifier.ParseConfigSet(log) + case _Verifier.abi.Events["FeedActivated"].ID: + return _Verifier.ParseFeedActivated(log) + case _Verifier.abi.Events["FeedDeactivated"].ID: + return _Verifier.ParseFeedDeactivated(log) + case _Verifier.abi.Events["OwnershipTransferRequested"].ID: + return _Verifier.ParseOwnershipTransferRequested(log) + case _Verifier.abi.Events["OwnershipTransferred"].ID: + return _Verifier.ParseOwnershipTransferred(log) + case _Verifier.abi.Events["ReportVerified"].ID: + return _Verifier.ParseReportVerified(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (VerifierConfigActivated) Topic() common.Hash { + return common.HexToHash("0x54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe7746") +} + +func (VerifierConfigDeactivated) Topic() common.Hash { + return common.HexToHash("0x0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c") +} + +func (VerifierConfigSet) Topic() common.Hash { + return common.HexToHash("0xa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da") +} + +func (VerifierFeedActivated) Topic() common.Hash { + return common.HexToHash("0xf438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b4") +} + +func (VerifierFeedDeactivated) Topic() common.Hash { + return common.HexToHash("0xfc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd061") +} + +func (VerifierOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (VerifierOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (VerifierReportVerified) Topic() common.Hash { + return common.HexToHash("0x58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc5") +} + +func (_Verifier *Verifier) Address() common.Address { + return _Verifier.address +} + +type VerifierInterface interface { + LatestConfigDetails(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDetails, + + error) + + LatestConfigDigestAndEpoch(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDigestAndEpoch, + + error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + ActivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) + + ActivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) + + DeactivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) + + DeactivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) + + SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + Verify(opts *bind.TransactOpts, signedReport []byte, sender common.Address) (*types.Transaction, error) + + FilterConfigActivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierConfigActivatedIterator, error) + + WatchConfigActivated(opts *bind.WatchOpts, sink chan<- *VerifierConfigActivated, feedId [][32]byte) (event.Subscription, error) + + ParseConfigActivated(log types.Log) (*VerifierConfigActivated, error) + + FilterConfigDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierConfigDeactivatedIterator, error) + + WatchConfigDeactivated(opts *bind.WatchOpts, sink chan<- *VerifierConfigDeactivated, feedId [][32]byte) (event.Subscription, error) + + ParseConfigDeactivated(log types.Log) (*VerifierConfigDeactivated, error) + + FilterConfigSet(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierConfigSetIterator, error) + + WatchConfigSet(opts *bind.WatchOpts, sink chan<- *VerifierConfigSet, feedId [][32]byte) (event.Subscription, error) + + ParseConfigSet(log types.Log) (*VerifierConfigSet, error) + + FilterFeedActivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierFeedActivatedIterator, error) + + WatchFeedActivated(opts *bind.WatchOpts, sink chan<- *VerifierFeedActivated, feedId [][32]byte) (event.Subscription, error) + + ParseFeedActivated(log types.Log) (*VerifierFeedActivated, error) + + FilterFeedDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierFeedDeactivatedIterator, error) + + WatchFeedDeactivated(opts *bind.WatchOpts, sink chan<- *VerifierFeedDeactivated, feedId [][32]byte) (event.Subscription, error) + + ParseFeedDeactivated(log types.Log) (*VerifierFeedDeactivated, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifierOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*VerifierOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifierOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*VerifierOwnershipTransferred, error) + + FilterReportVerified(opts *bind.FilterOpts, feedId [][32]byte) (*VerifierReportVerifiedIterator, error) + + WatchReportVerified(opts *bind.WatchOpts, sink chan<- *VerifierReportVerified, feedId [][32]byte) (event.Subscription, error) + + ParseReportVerified(log types.Log) (*VerifierReportVerified, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generated/verifier_proxy/verifier_proxy.go b/core/gethwrappers/llo-feeds/generated/verifier_proxy/verifier_proxy.go new file mode 100644 index 00000000000..40a6d24221b --- /dev/null +++ b/core/gethwrappers/llo-feeds/generated/verifier_proxy/verifier_proxy.go @@ -0,0 +1,1373 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package verifier_proxy + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +type CommonAddressAndWeight struct { + Addr common.Address + Weight *big.Int +} + +var VerifierProxyMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"ConfigDigestAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"VerifierAlreadyInitialized\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"VerifierInvalid\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"VerifierNotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldAccessController\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newAccessController\",\"type\":\"address\"}],\"name\":\"AccessControllerSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldFeeManager\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newFeeManager\",\"type\":\"address\"}],\"name\":\"FeeManagerSet\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierInitialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"oldConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierUnset\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"getVerifier\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"initializeVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_accessController\",\"outputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeManager\",\"outputs\":[{\"internalType\":\"contractIVerifierFeeManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"name\":\"setAccessController\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractIVerifierFeeManager\",\"name\":\"feeManager\",\"type\":\"address\"}],\"name\":\"setFeeManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"currentConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"addressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setVerifier\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"unsetVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"verifierResponse\",\"type\":\"bytes\"}],\"stateMutability\":\"payable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50604051620015333803806200153383398101604081905261003191610189565b33806000816100875760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156100b7576100b7816100e0565b5050600480546001600160a01b0319166001600160a01b039390931692909217909155506101b9565b336001600160a01b038216036101385760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161007e565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561019b57600080fd5b81516001600160a01b03811681146101b257600080fd5b9392505050565b61136a80620001c96000396000f3fe6080604052600436106100d25760003560e01c80638c2a4d531161007f57806394ba28461161005957806394ba284614610256578063eeb7b24814610283578063f08391d8146102c6578063f2fde38b146102e657600080fd5b80638c2a4d53146101f85780638da5cb5b146102185780638e760afe1461024357600080fd5b8063589ede28116100b0578063589ede28146101a35780636e914094146101c357806379ba5097146101e357600080fd5b8063181f5a77146100d757806338416b5b1461012f578063472d35b914610181575b600080fd5b3480156100e357600080fd5b5060408051808201909152601381527f566572696669657250726f787920312e312e300000000000000000000000000060208201525b6040516101269190610f7d565b60405180910390f35b34801561013b57600080fd5b5060055461015c9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610126565b34801561018d57600080fd5b506101a161019c366004610fb9565b610306565b005b3480156101af57600080fd5b506101a16101be366004610fd6565b6103e2565b3480156101cf57600080fd5b506101a16101de366004611059565b61060d565b3480156101ef57600080fd5b506101a16106f9565b34801561020457600080fd5b506101a1610213366004610fb9565b6107f6565b34801561022457600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff1661015c565b610119610251366004611072565b610a27565b34801561026257600080fd5b5060045461015c9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561028f57600080fd5b5061015c61029e366004611059565b60009081526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b3480156102d257600080fd5b506101a16102e1366004610fb9565b610cfc565b3480156102f257600080fd5b506101a1610301366004610fb9565b610d83565b61030e610d97565b73ffffffffffffffffffffffffffffffffffffffff811661035b576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6005805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f04628abcaa6b1674651352125cb94b65b289145bc2bc4d67720bb7d966372f0391015b60405180910390a15050565b600083815260036020526040902054839073ffffffffffffffffffffffffffffffffffffffff168015610465576040517f375d1fe60000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff821660248201526044015b60405180910390fd5b3360009081526002602052604090205460ff166104ae576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260036020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000163317905582156105c65760055473ffffffffffffffffffffffffffffffffffffffff16610539576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6005546040517f69fd2b3400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909116906369fd2b3490610593908890889088906004016110e4565b600060405180830381600087803b1580156105ad57600080fd5b505af11580156105c1573d6000803e3d6000fd5b505050505b6040805187815260208101879052338183015290517fbeb513e532542a562ac35699e7cd9ae7d198dcd3eee15bada6c857d28ceaddcf9181900360600190a1505050505050565b610615610d97565b60008181526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1680610674576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161045c565b6000828152600360205260409081902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055517f11dc15c4b8ac2b183166cc8427e5385a5ece8308217a4217338c6a7614845c4c906103d6908490849091825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60015473ffffffffffffffffffffffffffffffffffffffff16331461077a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161045c565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6107fe610d97565b8073ffffffffffffffffffffffffffffffffffffffff811661084c576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f01ffc9a70000000000000000000000000000000000000000000000000000000081527f3d3ac1b500000000000000000000000000000000000000000000000000000000600482015273ffffffffffffffffffffffffffffffffffffffff8216906301ffc9a790602401602060405180830381865afa1580156108d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108fa9190611153565b610930576040517f75b0527a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff821660009081526002602052604090205460ff16156109a8576040517f4e01ccfd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8316600482015260240161045c565b73ffffffffffffffffffffffffffffffffffffffff821660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f1f2cd7c97f4d801b5efe26cc409617c1fd6c5ef786e79aacb90af40923e4e8e991016103d6565b60045460609073ffffffffffffffffffffffffffffffffffffffff168015801590610ae757506040517f6b14daf800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890610aa490339060009036906004016111be565b602060405180830381865afa158015610ac1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610ae59190611153565b155b15610b1e576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610b2a84866111f7565b60008181526003602052604090205490915073ffffffffffffffffffffffffffffffffffffffff1680610b8c576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161045c565b60055473ffffffffffffffffffffffffffffffffffffffff168015610c36576040517ff1387e1600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063f1387e16903490610c03908b908b903390600401611234565b6000604051808303818588803b158015610c1c57600080fd5b505af1158015610c30573d6000803e3d6000fd5b50505050505b6040517f3d3ac1b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff831690633d3ac1b590610c8c908a908a903390600401611234565b6000604051808303816000875af1158015610cab573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052610cf1919081019061129d565b979650505050505050565b610d04610d97565b6004805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b691016103d6565b610d8b610d97565b610d9481610e1a565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610e18576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161045c565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610e99576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161045c565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005b83811015610f2a578181015183820152602001610f12565b50506000910152565b60008151808452610f4b816020860160208601610f0f565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f906020830184610f33565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff81168114610d9457600080fd5b600060208284031215610fcb57600080fd5b8135610f9081610f97565b60008060008060608587031215610fec57600080fd5b8435935060208501359250604085013567ffffffffffffffff8082111561101257600080fd5b818701915087601f83011261102657600080fd5b81358181111561103557600080fd5b8860208260061b850101111561104a57600080fd5b95989497505060200194505050565b60006020828403121561106b57600080fd5b5035919050565b6000806020838503121561108557600080fd5b823567ffffffffffffffff8082111561109d57600080fd5b818501915085601f8301126110b157600080fd5b8135818111156110c057600080fd5b8660208285010111156110d257600080fd5b60209290920196919550909350505050565b8381526040602080830182905282820184905260009190859060608501845b8781101561114657833561111681610f97565b73ffffffffffffffffffffffffffffffffffffffff16825283830135838301529284019290840190600101611103565b5098975050505050505050565b60006020828403121561116557600080fd5b81518015158114610f9057600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff841681526040602082015260006111ee604083018486611175565b95945050505050565b8035602083101561122e577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b165b92915050565b604081526000611248604083018587611175565b905073ffffffffffffffffffffffffffffffffffffffff83166020830152949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6000602082840312156112af57600080fd5b815167ffffffffffffffff808211156112c757600080fd5b818401915084601f8301126112db57600080fd5b8151818111156112ed576112ed61126e565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156113335761133361126e565b8160405282815287602084870101111561134c57600080fd5b610cf1836020830160208801610f0f56fea164736f6c6343000810000a", +} + +var VerifierProxyABI = VerifierProxyMetaData.ABI + +var VerifierProxyBin = VerifierProxyMetaData.Bin + +func DeployVerifierProxy(auth *bind.TransactOpts, backend bind.ContractBackend, accessController common.Address) (common.Address, *types.Transaction, *VerifierProxy, error) { + parsed, err := VerifierProxyMetaData.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(VerifierProxyBin), backend, accessController) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &VerifierProxy{VerifierProxyCaller: VerifierProxyCaller{contract: contract}, VerifierProxyTransactor: VerifierProxyTransactor{contract: contract}, VerifierProxyFilterer: VerifierProxyFilterer{contract: contract}}, nil +} + +type VerifierProxy struct { + address common.Address + abi abi.ABI + VerifierProxyCaller + VerifierProxyTransactor + VerifierProxyFilterer +} + +type VerifierProxyCaller struct { + contract *bind.BoundContract +} + +type VerifierProxyTransactor struct { + contract *bind.BoundContract +} + +type VerifierProxyFilterer struct { + contract *bind.BoundContract +} + +type VerifierProxySession struct { + Contract *VerifierProxy + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type VerifierProxyCallerSession struct { + Contract *VerifierProxyCaller + CallOpts bind.CallOpts +} + +type VerifierProxyTransactorSession struct { + Contract *VerifierProxyTransactor + TransactOpts bind.TransactOpts +} + +type VerifierProxyRaw struct { + Contract *VerifierProxy +} + +type VerifierProxyCallerRaw struct { + Contract *VerifierProxyCaller +} + +type VerifierProxyTransactorRaw struct { + Contract *VerifierProxyTransactor +} + +func NewVerifierProxy(address common.Address, backend bind.ContractBackend) (*VerifierProxy, error) { + abi, err := abi.JSON(strings.NewReader(VerifierProxyABI)) + if err != nil { + return nil, err + } + contract, err := bindVerifierProxy(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &VerifierProxy{address: address, abi: abi, VerifierProxyCaller: VerifierProxyCaller{contract: contract}, VerifierProxyTransactor: VerifierProxyTransactor{contract: contract}, VerifierProxyFilterer: VerifierProxyFilterer{contract: contract}}, nil +} + +func NewVerifierProxyCaller(address common.Address, caller bind.ContractCaller) (*VerifierProxyCaller, error) { + contract, err := bindVerifierProxy(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &VerifierProxyCaller{contract: contract}, nil +} + +func NewVerifierProxyTransactor(address common.Address, transactor bind.ContractTransactor) (*VerifierProxyTransactor, error) { + contract, err := bindVerifierProxy(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &VerifierProxyTransactor{contract: contract}, nil +} + +func NewVerifierProxyFilterer(address common.Address, filterer bind.ContractFilterer) (*VerifierProxyFilterer, error) { + contract, err := bindVerifierProxy(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &VerifierProxyFilterer{contract: contract}, nil +} + +func bindVerifierProxy(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := VerifierProxyMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_VerifierProxy *VerifierProxyRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VerifierProxy.Contract.VerifierProxyCaller.contract.Call(opts, result, method, params...) +} + +func (_VerifierProxy *VerifierProxyRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifierProxy.Contract.VerifierProxyTransactor.contract.Transfer(opts) +} + +func (_VerifierProxy *VerifierProxyRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VerifierProxy.Contract.VerifierProxyTransactor.contract.Transact(opts, method, params...) +} + +func (_VerifierProxy *VerifierProxyCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _VerifierProxy.Contract.contract.Call(opts, result, method, params...) +} + +func (_VerifierProxy *VerifierProxyTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifierProxy.Contract.contract.Transfer(opts) +} + +func (_VerifierProxy *VerifierProxyTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _VerifierProxy.Contract.contract.Transact(opts, method, params...) +} + +func (_VerifierProxy *VerifierProxyCaller) GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) { + var out []interface{} + err := _VerifierProxy.contract.Call(opts, &out, "getVerifier", configDigest) + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VerifierProxy *VerifierProxySession) GetVerifier(configDigest [32]byte) (common.Address, error) { + return _VerifierProxy.Contract.GetVerifier(&_VerifierProxy.CallOpts, configDigest) +} + +func (_VerifierProxy *VerifierProxyCallerSession) GetVerifier(configDigest [32]byte) (common.Address, error) { + return _VerifierProxy.Contract.GetVerifier(&_VerifierProxy.CallOpts, configDigest) +} + +func (_VerifierProxy *VerifierProxyCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifierProxy.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 (_VerifierProxy *VerifierProxySession) Owner() (common.Address, error) { + return _VerifierProxy.Contract.Owner(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCallerSession) Owner() (common.Address, error) { + return _VerifierProxy.Contract.Owner(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCaller) SAccessController(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifierProxy.contract.Call(opts, &out, "s_accessController") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VerifierProxy *VerifierProxySession) SAccessController() (common.Address, error) { + return _VerifierProxy.Contract.SAccessController(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCallerSession) SAccessController() (common.Address, error) { + return _VerifierProxy.Contract.SAccessController(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCaller) SFeeManager(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _VerifierProxy.contract.Call(opts, &out, "s_feeManager") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_VerifierProxy *VerifierProxySession) SFeeManager() (common.Address, error) { + return _VerifierProxy.Contract.SFeeManager(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCallerSession) SFeeManager() (common.Address, error) { + return _VerifierProxy.Contract.SFeeManager(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _VerifierProxy.contract.Call(opts, &out, "typeAndVersion") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_VerifierProxy *VerifierProxySession) TypeAndVersion() (string, error) { + return _VerifierProxy.Contract.TypeAndVersion(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyCallerSession) TypeAndVersion() (string, error) { + return _VerifierProxy.Contract.TypeAndVersion(&_VerifierProxy.CallOpts) +} + +func (_VerifierProxy *VerifierProxyTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "acceptOwnership") +} + +func (_VerifierProxy *VerifierProxySession) AcceptOwnership() (*types.Transaction, error) { + return _VerifierProxy.Contract.AcceptOwnership(&_VerifierProxy.TransactOpts) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _VerifierProxy.Contract.AcceptOwnership(&_VerifierProxy.TransactOpts) +} + +func (_VerifierProxy *VerifierProxyTransactor) InitializeVerifier(opts *bind.TransactOpts, verifierAddress common.Address) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "initializeVerifier", verifierAddress) +} + +func (_VerifierProxy *VerifierProxySession) InitializeVerifier(verifierAddress common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.InitializeVerifier(&_VerifierProxy.TransactOpts, verifierAddress) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) InitializeVerifier(verifierAddress common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.InitializeVerifier(&_VerifierProxy.TransactOpts, verifierAddress) +} + +func (_VerifierProxy *VerifierProxyTransactor) SetAccessController(opts *bind.TransactOpts, accessController common.Address) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "setAccessController", accessController) +} + +func (_VerifierProxy *VerifierProxySession) SetAccessController(accessController common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.SetAccessController(&_VerifierProxy.TransactOpts, accessController) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) SetAccessController(accessController common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.SetAccessController(&_VerifierProxy.TransactOpts, accessController) +} + +func (_VerifierProxy *VerifierProxyTransactor) SetFeeManager(opts *bind.TransactOpts, feeManager common.Address) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "setFeeManager", feeManager) +} + +func (_VerifierProxy *VerifierProxySession) SetFeeManager(feeManager common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.SetFeeManager(&_VerifierProxy.TransactOpts, feeManager) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) SetFeeManager(feeManager common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.SetFeeManager(&_VerifierProxy.TransactOpts, feeManager) +} + +func (_VerifierProxy *VerifierProxyTransactor) SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "setVerifier", currentConfigDigest, newConfigDigest, addressesAndWeights) +} + +func (_VerifierProxy *VerifierProxySession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _VerifierProxy.Contract.SetVerifier(&_VerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest, addressesAndWeights) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _VerifierProxy.Contract.SetVerifier(&_VerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest, addressesAndWeights) +} + +func (_VerifierProxy *VerifierProxyTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "transferOwnership", to) +} + +func (_VerifierProxy *VerifierProxySession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.TransferOwnership(&_VerifierProxy.TransactOpts, to) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _VerifierProxy.Contract.TransferOwnership(&_VerifierProxy.TransactOpts, to) +} + +func (_VerifierProxy *VerifierProxyTransactor) UnsetVerifier(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "unsetVerifier", configDigest) +} + +func (_VerifierProxy *VerifierProxySession) UnsetVerifier(configDigest [32]byte) (*types.Transaction, error) { + return _VerifierProxy.Contract.UnsetVerifier(&_VerifierProxy.TransactOpts, configDigest) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) UnsetVerifier(configDigest [32]byte) (*types.Transaction, error) { + return _VerifierProxy.Contract.UnsetVerifier(&_VerifierProxy.TransactOpts, configDigest) +} + +func (_VerifierProxy *VerifierProxyTransactor) Verify(opts *bind.TransactOpts, payload []byte) (*types.Transaction, error) { + return _VerifierProxy.contract.Transact(opts, "verify", payload) +} + +func (_VerifierProxy *VerifierProxySession) Verify(payload []byte) (*types.Transaction, error) { + return _VerifierProxy.Contract.Verify(&_VerifierProxy.TransactOpts, payload) +} + +func (_VerifierProxy *VerifierProxyTransactorSession) Verify(payload []byte) (*types.Transaction, error) { + return _VerifierProxy.Contract.Verify(&_VerifierProxy.TransactOpts, payload) +} + +type VerifierProxyAccessControllerSetIterator struct { + Event *VerifierProxyAccessControllerSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyAccessControllerSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyAccessControllerSet) + 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(VerifierProxyAccessControllerSet) + 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 *VerifierProxyAccessControllerSetIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyAccessControllerSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyAccessControllerSet struct { + OldAccessController common.Address + NewAccessController common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterAccessControllerSet(opts *bind.FilterOpts) (*VerifierProxyAccessControllerSetIterator, error) { + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "AccessControllerSet") + if err != nil { + return nil, err + } + return &VerifierProxyAccessControllerSetIterator{contract: _VerifierProxy.contract, event: "AccessControllerSet", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchAccessControllerSet(opts *bind.WatchOpts, sink chan<- *VerifierProxyAccessControllerSet) (event.Subscription, error) { + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "AccessControllerSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyAccessControllerSet) + if err := _VerifierProxy.contract.UnpackLog(event, "AccessControllerSet", 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 (_VerifierProxy *VerifierProxyFilterer) ParseAccessControllerSet(log types.Log) (*VerifierProxyAccessControllerSet, error) { + event := new(VerifierProxyAccessControllerSet) + if err := _VerifierProxy.contract.UnpackLog(event, "AccessControllerSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierProxyFeeManagerSetIterator struct { + Event *VerifierProxyFeeManagerSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyFeeManagerSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyFeeManagerSet) + 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(VerifierProxyFeeManagerSet) + 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 *VerifierProxyFeeManagerSetIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyFeeManagerSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyFeeManagerSet struct { + OldFeeManager common.Address + NewFeeManager common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterFeeManagerSet(opts *bind.FilterOpts) (*VerifierProxyFeeManagerSetIterator, error) { + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "FeeManagerSet") + if err != nil { + return nil, err + } + return &VerifierProxyFeeManagerSetIterator{contract: _VerifierProxy.contract, event: "FeeManagerSet", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchFeeManagerSet(opts *bind.WatchOpts, sink chan<- *VerifierProxyFeeManagerSet) (event.Subscription, error) { + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "FeeManagerSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyFeeManagerSet) + if err := _VerifierProxy.contract.UnpackLog(event, "FeeManagerSet", 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 (_VerifierProxy *VerifierProxyFilterer) ParseFeeManagerSet(log types.Log) (*VerifierProxyFeeManagerSet, error) { + event := new(VerifierProxyFeeManagerSet) + if err := _VerifierProxy.contract.UnpackLog(event, "FeeManagerSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierProxyOwnershipTransferRequestedIterator struct { + Event *VerifierProxyOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyOwnershipTransferRequested) + 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(VerifierProxyOwnershipTransferRequested) + 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 *VerifierProxyOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierProxyOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &VerifierProxyOwnershipTransferRequestedIterator{contract: _VerifierProxy.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifierProxyOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyOwnershipTransferRequested) + if err := _VerifierProxy.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_VerifierProxy *VerifierProxyFilterer) ParseOwnershipTransferRequested(log types.Log) (*VerifierProxyOwnershipTransferRequested, error) { + event := new(VerifierProxyOwnershipTransferRequested) + if err := _VerifierProxy.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierProxyOwnershipTransferredIterator struct { + Event *VerifierProxyOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyOwnershipTransferred) + 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(VerifierProxyOwnershipTransferred) + 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 *VerifierProxyOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierProxyOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &VerifierProxyOwnershipTransferredIterator{contract: _VerifierProxy.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifierProxyOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyOwnershipTransferred) + if err := _VerifierProxy.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 (_VerifierProxy *VerifierProxyFilterer) ParseOwnershipTransferred(log types.Log) (*VerifierProxyOwnershipTransferred, error) { + event := new(VerifierProxyOwnershipTransferred) + if err := _VerifierProxy.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierProxyVerifierInitializedIterator struct { + Event *VerifierProxyVerifierInitialized + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyVerifierInitializedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyVerifierInitialized) + 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(VerifierProxyVerifierInitialized) + 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 *VerifierProxyVerifierInitializedIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyVerifierInitializedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyVerifierInitialized struct { + VerifierAddress common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterVerifierInitialized(opts *bind.FilterOpts) (*VerifierProxyVerifierInitializedIterator, error) { + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "VerifierInitialized") + if err != nil { + return nil, err + } + return &VerifierProxyVerifierInitializedIterator{contract: _VerifierProxy.contract, event: "VerifierInitialized", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchVerifierInitialized(opts *bind.WatchOpts, sink chan<- *VerifierProxyVerifierInitialized) (event.Subscription, error) { + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "VerifierInitialized") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyVerifierInitialized) + if err := _VerifierProxy.contract.UnpackLog(event, "VerifierInitialized", 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 (_VerifierProxy *VerifierProxyFilterer) ParseVerifierInitialized(log types.Log) (*VerifierProxyVerifierInitialized, error) { + event := new(VerifierProxyVerifierInitialized) + if err := _VerifierProxy.contract.UnpackLog(event, "VerifierInitialized", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierProxyVerifierSetIterator struct { + Event *VerifierProxyVerifierSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyVerifierSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyVerifierSet) + 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(VerifierProxyVerifierSet) + 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 *VerifierProxyVerifierSetIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyVerifierSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyVerifierSet struct { + OldConfigDigest [32]byte + NewConfigDigest [32]byte + VerifierAddress common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterVerifierSet(opts *bind.FilterOpts) (*VerifierProxyVerifierSetIterator, error) { + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "VerifierSet") + if err != nil { + return nil, err + } + return &VerifierProxyVerifierSetIterator{contract: _VerifierProxy.contract, event: "VerifierSet", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchVerifierSet(opts *bind.WatchOpts, sink chan<- *VerifierProxyVerifierSet) (event.Subscription, error) { + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "VerifierSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyVerifierSet) + if err := _VerifierProxy.contract.UnpackLog(event, "VerifierSet", 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 (_VerifierProxy *VerifierProxyFilterer) ParseVerifierSet(log types.Log) (*VerifierProxyVerifierSet, error) { + event := new(VerifierProxyVerifierSet) + if err := _VerifierProxy.contract.UnpackLog(event, "VerifierSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type VerifierProxyVerifierUnsetIterator struct { + Event *VerifierProxyVerifierUnset + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *VerifierProxyVerifierUnsetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(VerifierProxyVerifierUnset) + 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(VerifierProxyVerifierUnset) + 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 *VerifierProxyVerifierUnsetIterator) Error() error { + return it.fail +} + +func (it *VerifierProxyVerifierUnsetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type VerifierProxyVerifierUnset struct { + ConfigDigest [32]byte + VerifierAddress common.Address + Raw types.Log +} + +func (_VerifierProxy *VerifierProxyFilterer) FilterVerifierUnset(opts *bind.FilterOpts) (*VerifierProxyVerifierUnsetIterator, error) { + + logs, sub, err := _VerifierProxy.contract.FilterLogs(opts, "VerifierUnset") + if err != nil { + return nil, err + } + return &VerifierProxyVerifierUnsetIterator{contract: _VerifierProxy.contract, event: "VerifierUnset", logs: logs, sub: sub}, nil +} + +func (_VerifierProxy *VerifierProxyFilterer) WatchVerifierUnset(opts *bind.WatchOpts, sink chan<- *VerifierProxyVerifierUnset) (event.Subscription, error) { + + logs, sub, err := _VerifierProxy.contract.WatchLogs(opts, "VerifierUnset") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(VerifierProxyVerifierUnset) + if err := _VerifierProxy.contract.UnpackLog(event, "VerifierUnset", 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 (_VerifierProxy *VerifierProxyFilterer) ParseVerifierUnset(log types.Log) (*VerifierProxyVerifierUnset, error) { + event := new(VerifierProxyVerifierUnset) + if err := _VerifierProxy.contract.UnpackLog(event, "VerifierUnset", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_VerifierProxy *VerifierProxy) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _VerifierProxy.abi.Events["AccessControllerSet"].ID: + return _VerifierProxy.ParseAccessControllerSet(log) + case _VerifierProxy.abi.Events["FeeManagerSet"].ID: + return _VerifierProxy.ParseFeeManagerSet(log) + case _VerifierProxy.abi.Events["OwnershipTransferRequested"].ID: + return _VerifierProxy.ParseOwnershipTransferRequested(log) + case _VerifierProxy.abi.Events["OwnershipTransferred"].ID: + return _VerifierProxy.ParseOwnershipTransferred(log) + case _VerifierProxy.abi.Events["VerifierInitialized"].ID: + return _VerifierProxy.ParseVerifierInitialized(log) + case _VerifierProxy.abi.Events["VerifierSet"].ID: + return _VerifierProxy.ParseVerifierSet(log) + case _VerifierProxy.abi.Events["VerifierUnset"].ID: + return _VerifierProxy.ParseVerifierUnset(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (VerifierProxyAccessControllerSet) Topic() common.Hash { + return common.HexToHash("0x953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b6") +} + +func (VerifierProxyFeeManagerSet) Topic() common.Hash { + return common.HexToHash("0x04628abcaa6b1674651352125cb94b65b289145bc2bc4d67720bb7d966372f03") +} + +func (VerifierProxyOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (VerifierProxyOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (VerifierProxyVerifierInitialized) Topic() common.Hash { + return common.HexToHash("0x1f2cd7c97f4d801b5efe26cc409617c1fd6c5ef786e79aacb90af40923e4e8e9") +} + +func (VerifierProxyVerifierSet) Topic() common.Hash { + return common.HexToHash("0xbeb513e532542a562ac35699e7cd9ae7d198dcd3eee15bada6c857d28ceaddcf") +} + +func (VerifierProxyVerifierUnset) Topic() common.Hash { + return common.HexToHash("0x11dc15c4b8ac2b183166cc8427e5385a5ece8308217a4217338c6a7614845c4c") +} + +func (_VerifierProxy *VerifierProxy) Address() common.Address { + return _VerifierProxy.address +} + +type VerifierProxyInterface interface { + GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SAccessController(opts *bind.CallOpts) (common.Address, error) + + SFeeManager(opts *bind.CallOpts) (common.Address, error) + + TypeAndVersion(opts *bind.CallOpts) (string, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + InitializeVerifier(opts *bind.TransactOpts, verifierAddress common.Address) (*types.Transaction, error) + + SetAccessController(opts *bind.TransactOpts, accessController common.Address) (*types.Transaction, error) + + SetFeeManager(opts *bind.TransactOpts, feeManager common.Address) (*types.Transaction, error) + + SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + UnsetVerifier(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) + + Verify(opts *bind.TransactOpts, payload []byte) (*types.Transaction, error) + + FilterAccessControllerSet(opts *bind.FilterOpts) (*VerifierProxyAccessControllerSetIterator, error) + + WatchAccessControllerSet(opts *bind.WatchOpts, sink chan<- *VerifierProxyAccessControllerSet) (event.Subscription, error) + + ParseAccessControllerSet(log types.Log) (*VerifierProxyAccessControllerSet, error) + + FilterFeeManagerSet(opts *bind.FilterOpts) (*VerifierProxyFeeManagerSetIterator, error) + + WatchFeeManagerSet(opts *bind.WatchOpts, sink chan<- *VerifierProxyFeeManagerSet) (event.Subscription, error) + + ParseFeeManagerSet(log types.Log) (*VerifierProxyFeeManagerSet, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierProxyOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *VerifierProxyOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*VerifierProxyOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*VerifierProxyOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *VerifierProxyOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*VerifierProxyOwnershipTransferred, error) + + FilterVerifierInitialized(opts *bind.FilterOpts) (*VerifierProxyVerifierInitializedIterator, error) + + WatchVerifierInitialized(opts *bind.WatchOpts, sink chan<- *VerifierProxyVerifierInitialized) (event.Subscription, error) + + ParseVerifierInitialized(log types.Log) (*VerifierProxyVerifierInitialized, error) + + FilterVerifierSet(opts *bind.FilterOpts) (*VerifierProxyVerifierSetIterator, error) + + WatchVerifierSet(opts *bind.WatchOpts, sink chan<- *VerifierProxyVerifierSet) (event.Subscription, error) + + ParseVerifierSet(log types.Log) (*VerifierProxyVerifierSet, error) + + FilterVerifierUnset(opts *bind.FilterOpts) (*VerifierProxyVerifierUnsetIterator, error) + + WatchVerifierUnset(opts *bind.WatchOpts, sink chan<- *VerifierProxyVerifierUnset) (event.Subscription, error) + + ParseVerifierUnset(log types.Log) (*VerifierProxyVerifierUnset, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt new file mode 100644 index 00000000000..c50d38674a5 --- /dev/null +++ b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -0,0 +1,9 @@ +GETH_VERSION: 1.12.0 +errored_verifier: ../../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../../contracts/solc/v0.8.16/ErroredVerifier.bin eeae445bed26b9da9c0659d138e810964bd9f667eaf02515ae23c185a3ac0adc +exposed_verifier: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 +fee_manager: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin d5674bbad7231fc588dc8c9d1f803fedb649ba7355b3c5ab11f9810c5c839a6b +llo_feeds: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin cb71e018f67e49d7bc0e194c822204dfd59f79ff42e4fc8fd8ab63f3acd71361 +llo_feeds_test: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 +reward_manager: ../../../contracts/solc/v0.8.16/RewardManager.abi ../../../contracts/solc/v0.8.16/RewardManager.bin 1694433bbcf39684ec105b3b1d9478f7158165c97b711483f1f4f4fa4eb61364 +verifier: ../../../contracts/solc/v0.8.16/Verifier.abi ../../../contracts/solc/v0.8.16/Verifier.bin 8518b13062166f7102d031f82a841573ca4d89eb27e96d633503e49302b75b47 +verifier_proxy: ../../../contracts/solc/v0.8.16/VerifierProxy.abi ../../../contracts/solc/v0.8.16/VerifierProxy.bin 64c61227ccc947171c35c5cd5dc664c492fbe2139fdfee70d4941a0109261341 diff --git a/core/gethwrappers/llo-feeds/go_generate.go b/core/gethwrappers/llo-feeds/go_generate.go new file mode 100644 index 00000000000..8d9e3be0493 --- /dev/null +++ b/core/gethwrappers/llo-feeds/go_generate.go @@ -0,0 +1,11 @@ +// Package gethwrappers provides tools for wrapping solidity contracts with +// golang packages, using abigen. +package gethwrappers + +// Chainlink LLO +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.16/Verifier.abi ../../../contracts/solc/v0.8.16/Verifier.bin Verifier verifier +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.16/VerifierProxy.abi ../../../contracts/solc/v0.8.16/VerifierProxy.bin VerifierProxy verifier_proxy +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../../contracts/solc/v0.8.16/ErroredVerifier.bin ErroredVerifier errored_verifier +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin ExposedVerifier exposed_verifier +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.16/RewardManager.abi ../../../contracts/solc/v0.8.16/RewardManager.bin RewardManager reward_manager +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin FeeManager fee_manager diff --git a/core/services/ocr2/plugins/mercury/integration_test.go b/core/services/ocr2/plugins/mercury/integration_test.go index cb5b98a5216..abb5d26df61 100644 --- a/core/services/ocr2/plugins/mercury/integration_test.go +++ b/core/services/ocr2/plugins/mercury/integration_test.go @@ -300,6 +300,7 @@ func TestIntegration_Mercury(t *testing.T) { onchainConfig, offchainConfigVersion, offchainConfig, + nil, ) require.NoError(t, err) backend.Commit() diff --git a/core/services/relay/evm/mercury/config_poller_test.go b/core/services/relay/evm/mercury/config_poller_test.go index 3e63c064cb1..db1d5ee51a7 100644 --- a/core/services/relay/evm/mercury/config_poller_test.go +++ b/core/services/relay/evm/mercury/config_poller_test.go @@ -82,7 +82,8 @@ func TestMercuryConfigPoller(t *testing.T) { offchainTransmitters[i] = oracles[i].OffchainPublicKey encodedTransmitter[i] = ocrtypes2.Account(fmt.Sprintf("%x", oracles[i].OffchainPublicKey[:])) } - _, err = th.verifierContract.SetConfig(th.user, feedIDBytes, signerAddresses, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig) + + _, err = th.verifierContract.SetConfig(th.user, feedIDBytes, signerAddresses, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, nil) require.NoError(t, err, "failed to setConfig with feed ID") th.backend.Commit() From 313c01eb57b5c6df918e540c8c6b11db60988505 Mon Sep 17 00:00:00 2001 From: Awbrey Hughlett Date: Fri, 11 Aug 2023 10:22:51 -0500 Subject: [PATCH 150/270] Update upkeep state store to match updated interface (#10156) * Update upkeep state store to match updated interface The upkeep state store reader and writer interfaces were changed to provide workIDs and check results respectively. The implementation was updated to match the requirements of the new interfaces. As of right now, `SetUpkeepState` ignores the provided state in favor of assuming state from the result eligibility. * remove reference to ticket * remove array * go mod tidy --- .../ocr2keeper/evm21/upkeep_state_store.go | 111 ++++----- .../evm21/upkeep_state_store_test.go | 227 +++++++++--------- go.mod | 2 +- 3 files changed, 169 insertions(+), 171 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go index c3cc75c1eff..4eba6cd1de4 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go @@ -1,97 +1,92 @@ package evm import ( - "math/big" + "context" "sync" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" - mapset "github.com/deckarep/golang-set/v2" - "github.com/smartcontractkit/chainlink/v2/core/logger" ) -const BlockKeySeparator = "|" - type upkeepState struct { - payload *ocr2keepers.UpkeepPayload - state *ocr2keepers.UpkeepState - block int64 - upkeepId string + upkeepID ocr2keepers.UpkeepIdentifier + workID string + state ocr2keepers.UpkeepState + block uint64 } type UpkeepStateReader interface { - // SelectByUpkeepIDsAndBlockRange retrieves upkeep states for provided upkeep ids and block range, the result is currently not in particular order - SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, start, end int64) ([]*ocr2keepers.UpkeepPayload, []*ocr2keepers.UpkeepState, error) + SelectByWorkIDs(workIDs ...string) (map[string]ocr2keepers.UpkeepState, error) } -type UpkeepStateUpdater interface { - SetUpkeepState(ocr2keepers.UpkeepPayload, ocr2keepers.UpkeepState) error -} +var ( + _ ocr2keepers.UpkeepStateUpdater = &UpkeepStateStore{} + _ UpkeepStateReader = &UpkeepStateStore{} +) type UpkeepStateStore struct { - mu sync.RWMutex - statesByID map[string]*upkeepState - states []*upkeepState - lggr logger.Logger + mu sync.RWMutex + workIDIdx map[string]*upkeepState + lggr logger.Logger } -// NewUpkeepStateStore creates a new state store. This is an initial version of this store. More improvements to come: -// TODO: AUTO-4027 +// NewUpkeepStateStore creates a new state store func NewUpkeepStateStore(lggr logger.Logger) *UpkeepStateStore { return &UpkeepStateStore{ - statesByID: map[string]*upkeepState{}, - lggr: lggr.Named("UpkeepStateStore"), + workIDIdx: map[string]*upkeepState{}, + lggr: lggr.Named("UpkeepStateStore"), } } -func (u *UpkeepStateStore) SelectByUpkeepIDsAndBlockRange(upkeepIds []*big.Int, start, end int64) ([]*ocr2keepers.UpkeepPayload, []*ocr2keepers.UpkeepState, error) { +// SelectByWorkIDs returns all saved state values for the provided ids +func (u *UpkeepStateStore) SelectByWorkIDs(workIDs ...string) (map[string]ocr2keepers.UpkeepState, error) { u.mu.RLock() defer u.mu.RUnlock() - var pl []*ocr2keepers.UpkeepPayload - var us []*ocr2keepers.UpkeepState - uids := mapset.NewSet[string]() - for _, uid := range upkeepIds { - uids.Add(uid.String()) - } + states := make(map[string]ocr2keepers.UpkeepState) - for _, s := range u.states { - if s.block < start || s.block >= end || !uids.Contains(s.upkeepId) { - continue + for _, workID := range workIDs { + if state, ok := u.workIDIdx[workID]; ok { + states[workID] = state.state } - - pl = append(pl, s.payload) - us = append(us, s.state) } - return pl, us, nil + + return states, nil } -func (u *UpkeepStateStore) SetUpkeepState(pl ocr2keepers.UpkeepPayload, us ocr2keepers.UpkeepState) error { - u.mu.Lock() - defer u.mu.Unlock() +// SetUpkeepState applies the provided state to the data store for the provided +// check result. If an item already exists in the data store, the state and +// block are updated. Otherwise, the new state is added. +func (u *UpkeepStateStore) SetUpkeepState(_ context.Context, result ocr2keepers.CheckResult, _ ocr2keepers.UpkeepState) error { + // only if the result is ineligible is the upkeep state updated + if !result.Eligible { + if existing, ok := u.workIDIdx[result.WorkID]; ok { + u.mu.Lock() - upkeepId := pl.UpkeepID.BigInt() - state := &upkeepState{ - payload: &pl, - state: &us, - block: int64(pl.Trigger.BlockNumber), - upkeepId: upkeepId.String(), - } + existing.state = ocr2keepers.Ineligible + existing.block = uint64(result.Trigger.BlockNumber) + + u.mu.Unlock() + + u.lggr.Infof("upkeep %s is overridden, workID is %s, block is %d", existing.upkeepID, existing.workID, existing.block) + } else { + storedState := &upkeepState{ + upkeepID: result.UpkeepID, + workID: result.WorkID, + state: ocr2keepers.Ineligible, + block: uint64(result.Trigger.BlockNumber), + } + + u.mu.Lock() - s, ok := u.statesByID[pl.WorkID] - if ok { - s.payload = state.payload - s.state = state.state - s.block = state.block - s.upkeepId = state.upkeepId - u.statesByID[pl.WorkID] = s - u.lggr.Infof("upkeep %s is overridden, payload ID is %s, block is %d", s.upkeepId, s.payload.WorkID, s.block) - return nil + u.workIDIdx[result.WorkID] = storedState + + u.mu.Unlock() + + u.lggr.Infof("added new state with upkeep %s payload ID %s block %d", storedState.upkeepID, storedState.workID, storedState.block) + } } - u.statesByID[pl.WorkID] = state - u.states = append(u.states, state) - u.lggr.Infof("added new state with upkeep %s payload ID %s block %d", state.upkeepId, state.payload.WorkID, state.block) return nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go index 4a5817f9314..12a41d81254 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go @@ -1,134 +1,137 @@ package evm import ( + "context" "math/big" "testing" - "github.com/ethereum/go-ethereum/common" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) -var ( - upkeepId1 = big.NewInt(100) - upkeepId2 = big.NewInt(200) - trigger1 = ocr2keepers.Trigger{ - BlockNumber: block1, - BlockHash: common.HexToHash("0x1"), - LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ - Index: 1, - TxHash: common.HexToHash("0x1"), +func TestUpkeepStateStore_SelectByWorkIDs(t *testing.T) { + workIDs := []string{"a", "b", "c", "d"} + inserts := []ocr2keepers.CheckResult{ + { + UpkeepID: createUpkeepIDForTest(1), + WorkID: workIDs[0], + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), + }, }, - } - trigger2 = ocr2keepers.Trigger{ - BlockNumber: block3, - BlockHash: common.HexToHash("0x1"), - LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ - Index: 2, // a different BlockNumber isn't enough to generate a unique work ID, so we change the index here to generate a separate work ID - TxHash: common.HexToHash("0x1"), + { + UpkeepID: createUpkeepIDForTest(2), + WorkID: workIDs[1], + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(2), + }, + }, + { + UpkeepID: createUpkeepIDForTest(3), + WorkID: workIDs[2], + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(3), + }, }, } - payload2, _ = core.NewUpkeepPayload(upkeepId1, trigger1, []byte{}) - payload3, _ = core.NewUpkeepPayload(upkeepId2, trigger1, []byte{}) - payload4, _ = core.NewUpkeepPayload(upkeepId1, trigger2, []byte{}) - payload5, _ = core.NewUpkeepPayload(upkeepId1, trigger1, []byte{}) -) -const ( - block1 = 111 - block3 = 113 -) + expected := map[string]ocr2keepers.UpkeepState{ + workIDs[0]: ocr2keepers.Ineligible, + workIDs[1]: ocr2keepers.Ineligible, + workIDs[2]: ocr2keepers.Ineligible, + } -func TestUpkeepStateStore_OverrideUpkeepStates(t *testing.T) { - p := ocr2keepers.Performed - e := ocr2keepers.Ineligible - - tests := []struct { - name string - payloads []ocr2keepers.UpkeepPayload - states []ocr2keepers.UpkeepState - expectedError error - oldIds []string - oldIdResult []upkeepState - newIds []string - newIdResult []upkeepState - upkeepIds []*big.Int - endBlock int64 - startBlock int64 - result []upkeepState - }{ - { - name: "overrides existing upkeep states", - payloads: []ocr2keepers.UpkeepPayload{ - payload2, - payload3, - payload4, - payload5, // this overrides payload 2 bc they have the same payload ID - }, - states: []ocr2keepers.UpkeepState{ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Performed, ocr2keepers.Ineligible}, - oldIds: []string{payload2.WorkID, payload3.WorkID, payload4.WorkID}, - oldIdResult: []upkeepState{ - { - payload: &payload3, - state: &p, - }, - { - payload: &payload4, - state: &p, - }, - }, - newIds: []string{payload3.WorkID, payload4.WorkID, payload5.WorkID}, - newIdResult: []upkeepState{ - { - payload: &payload3, - state: &p, - }, - { - payload: &payload4, - state: &p, - }, - { - payload: &payload5, - state: &e, - }, + store := NewUpkeepStateStore(logger.TestLogger(t)) + + for _, insert := range inserts { + assert.NoError(t, store.SetUpkeepState(context.Background(), insert, ocr2keepers.Performed), "storing states should not produce an error") + } + + states, err := store.SelectByWorkIDs(workIDs...) + assert.NoError(t, err, "no error expected from selecting states") + + assert.Equal(t, expected, states, "upkeep state values should match expected") +} + +func TestUpkeepStateStore_SetUpkeepState(t *testing.T) { + t.Run("should not save state for upkeep eligible", func(t *testing.T) { + uid := &ocr2keepers.UpkeepIdentifier{} + _ = uid.FromBigInt(big.NewInt(1)) + + store := NewUpkeepStateStore(logger.TestLogger(t)) + + assert.NoError(t, store.SetUpkeepState(context.Background(), ocr2keepers.CheckResult{ + UpkeepID: *uid, + WorkID: "test", + Eligible: true, + }, ocr2keepers.Ineligible), "setting state should not return an error") + + assert.Len(t, store.workIDIdx, 0, "should not add to upkeep states") + }) + + t.Run("should insert new state when ineligible and state does not exist in store and ignore state input", func(t *testing.T) { + uid := &ocr2keepers.UpkeepIdentifier{} + _ = uid.FromBigInt(big.NewInt(1)) + + store := NewUpkeepStateStore(logger.TestLogger(t)) + input := ocr2keepers.CheckResult{ + UpkeepID: *uid, + WorkID: "test", + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), }, + Eligible: false, + } - upkeepIds: []*big.Int{upkeepId1}, - endBlock: block3 + 1, - startBlock: block1, - result: []upkeepState{ - { - payload: &payload5, - state: &e, - }, - { - payload: &payload4, - state: &p, - }, + assert.NoError(t, store.SetUpkeepState(context.Background(), input, ocr2keepers.Performed)) + + require.Len(t, store.workIDIdx, 1, "should add to upkeep states") + + assert.Equal(t, ocr2keepers.Ineligible, store.workIDIdx["test"].state, "stored state should be ineligible") + assert.Equal(t, input.UpkeepID, store.workIDIdx["test"].upkeepID, "stored upkeepID should match input") + assert.Equal(t, input.WorkID, store.workIDIdx["test"].workID, "stored workID should match input") + assert.Equal(t, uint64(input.Trigger.BlockNumber), store.workIDIdx["test"].block, "stored block should match input") + }) + + // when eligible and state exists in store, override state, ignore state input + t.Run("should override block when ineligible and state exists in store and ignore state input", func(t *testing.T) { + store := NewUpkeepStateStore(logger.TestLogger(t)) + input := ocr2keepers.CheckResult{ + UpkeepID: createUpkeepIDForTest(1), + WorkID: "test", + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), }, - }, - } + Eligible: false, + } - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - store := NewUpkeepStateStore(logger.TestLogger(t)) - for i, p := range tc.payloads { - err := store.SetUpkeepState(p, tc.states[i]) - require.Equal(t, err, tc.expectedError) - } - - pl, us, err := store.SelectByUpkeepIDsAndBlockRange(tc.upkeepIds, tc.startBlock, tc.endBlock) - require.Nil(t, err) - require.Equal(t, len(tc.result), len(pl)) - require.Equal(t, len(tc.result), len(us)) - for j, r := range tc.result { - require.Equal(t, r.payload, pl[j]) - require.Equal(t, r.state, us[j]) - } - - }) - } + assert.NoError(t, store.SetUpkeepState(context.Background(), input, ocr2keepers.Performed), "setting state should not return an error") + + require.Len(t, store.workIDIdx, 1, "should add to upkeep states") + + // update the block number for the input to indicate a state data change + input.Trigger.BlockNumber = ocr2keepers.BlockNumber(5) + + assert.NoError(t, store.SetUpkeepState(context.Background(), input, ocr2keepers.Performed), "setting state should not return an error") + + require.Len(t, store.workIDIdx, 1, "should update existing upkeep state") + + assert.Equal(t, ocr2keepers.Ineligible, store.workIDIdx["test"].state, "stored state should be ineligible") + assert.Equal(t, input.UpkeepID, store.workIDIdx["test"].upkeepID, "stored upkeepID should match input") + assert.Equal(t, input.WorkID, store.workIDIdx["test"].workID, "stored workID should match input") + assert.Equal(t, uint64(input.Trigger.BlockNumber), store.workIDIdx["test"].block, "stored block should match input") + }) +} + +func createUpkeepIDForTest(v int64) ocr2keepers.UpkeepIdentifier { + uid := &ocr2keepers.UpkeepIdentifier{} + _ = uid.FromBigInt(big.NewInt(v)) + + return *uid } diff --git a/go.mod b/go.mod index f62c681bedb..e34f7d7da7e 100644 --- a/go.mod +++ b/go.mod @@ -12,7 +12,6 @@ require ( github.com/cometbft/cometbft v0.37.2 github.com/cosmos/cosmos-sdk v0.47.4 github.com/danielkov/gin-helmet v0.0.0-20171108135313-1387e224435e - github.com/deckarep/golang-set/v2 v2.3.0 github.com/ethereum/go-ethereum v1.12.0 github.com/fatih/color v1.15.0 github.com/fxamacker/cbor/v2 v2.4.0 @@ -154,6 +153,7 @@ require ( github.com/danieljoos/wincred v1.1.2 // indirect github.com/davecgh/go-spew v1.1.1 // indirect github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c // indirect + github.com/deckarep/golang-set/v2 v2.3.0 // indirect github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 // indirect github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70 // indirect github.com/dgraph-io/badger/v2 v2.2007.4 // indirect From 5419bf4cb837282e49311c3de1d8c411ffe7de5c Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Fri, 11 Aug 2023 11:21:07 -0500 Subject: [PATCH 151/270] update replaces from jmank88 to smartcontractkit (#10168) --- core/scripts/go.mod | 4 ++-- core/scripts/go.sum | 8 ++++---- go.mod | 5 ++--- go.sum | 8 ++++---- integration-tests/go.mod | 4 ++-- integration-tests/go.sum | 8 ++++---- 6 files changed, 18 insertions(+), 19 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index d2cb619328c..f307ed6baaa 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -384,9 +384,9 @@ replace ( github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 - github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + github.com/hashicorp/go-plugin => github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 // until merged upstream: https://github.com/mwitkow/grpc-proxy/pull/69 - github.com/mwitkow/grpc-proxy => github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 + github.com/mwitkow/grpc-proxy => github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f ) diff --git a/core/scripts/go.sum b/core/scripts/go.sum index d8d440d0297..71c4f7a17ec 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -810,10 +810,6 @@ github.com/jbenet/goprocess v0.1.4 h1:DRGOFReOMqqDNXwW70QkacFW0YN9QnwLV0Vqk+3oU0 github.com/jbenet/goprocess v0.1.4/go.mod h1:5yspPrukOVuOLORacaBi858NqyClJPQxYZlqdZVfqY4= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= -github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= -github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= -github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 h1:CAa5/6QLk2AAgTlqMPfPRkf0ebjtPYoJFhTqe7zJaXs= -github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= @@ -1440,6 +1436,10 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= +github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kNwgFlDmbE/n0gTSRMt9GBDfsfGrs4X9b9arPZtFI= +github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= +github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= +github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= diff --git a/go.mod b/go.mod index e34f7d7da7e..2ac69664cee 100644 --- a/go.mod +++ b/go.mod @@ -381,9 +381,8 @@ replace ( github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 - github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + github.com/hashicorp/go-plugin => github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 // until merged upstream: https://github.com/mwitkow/grpc-proxy/pull/69 - github.com/mwitkow/grpc-proxy => github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 - + github.com/mwitkow/grpc-proxy => github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f ) diff --git a/go.sum b/go.sum index 99bc4045948..9dc347808fd 100644 --- a/go.sum +++ b/go.sum @@ -812,10 +812,6 @@ github.com/jbenet/goprocess v0.1.4 h1:DRGOFReOMqqDNXwW70QkacFW0YN9QnwLV0Vqk+3oU0 github.com/jbenet/goprocess v0.1.4/go.mod h1:5yspPrukOVuOLORacaBi858NqyClJPQxYZlqdZVfqY4= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= -github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= -github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= -github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 h1:CAa5/6QLk2AAgTlqMPfPRkf0ebjtPYoJFhTqe7zJaXs= -github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= @@ -1445,6 +1441,10 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= +github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kNwgFlDmbE/n0gTSRMt9GBDfsfGrs4X9b9arPZtFI= +github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= +github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= +github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index fa1d5e003aa..af76c9491c3 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -502,10 +502,10 @@ replace ( github.com/gogo/protobuf => github.com/regen-network/protobuf v1.3.3-alpha.regen.1 // until merged upstream: https://github.com/hashicorp/go-plugin/pull/257 - github.com/hashicorp/go-plugin => github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 + github.com/hashicorp/go-plugin => github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 // until merged upstream: https://github.com/mwitkow/grpc-proxy/pull/69 - github.com/mwitkow/grpc-proxy => github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 + github.com/mwitkow/grpc-proxy => github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f github.com/prometheus/prometheus => github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2 github.com/sercand/kuberesolver v2.4.0+incompatible => github.com/sercand/kuberesolver/v5 v5.1.0 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 4b0ca86c60a..6ef28441699 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1522,10 +1522,6 @@ github.com/jbenet/goprocess v0.1.4 h1:DRGOFReOMqqDNXwW70QkacFW0YN9QnwLV0Vqk+3oU0 github.com/jbenet/goprocess v0.1.4/go.mod h1:5yspPrukOVuOLORacaBi858NqyClJPQxYZlqdZVfqY4= github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= -github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75 h1:KYTOmcwuezD27O7vNF15lj8H7imCBMXCq1RzCdj4e3A= -github.com/jmank88/go-plugin v0.0.0-20230604120638-7bb12ec27e75/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= -github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231 h1:CAa5/6QLk2AAgTlqMPfPRkf0ebjtPYoJFhTqe7zJaXs= -github.com/jmank88/grpc-proxy v0.0.0-20230731114312-86ed94c93231/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= @@ -2253,6 +2249,10 @@ github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.202308 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= github.com/smartcontractkit/chainlink-testing-framework v1.15.2 h1:WhZvHHz104RKC9u5u+zHeP4YwyyFVG3bW0DVRSe4FnE= github.com/smartcontractkit/chainlink-testing-framework v1.15.2/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= +github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kNwgFlDmbE/n0gTSRMt9GBDfsfGrs4X9b9arPZtFI= +github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= +github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= +github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= From 45aa6e7b35a8903d0145498b45ac332a861e5495 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Fri, 11 Aug 2023 15:25:00 -0400 Subject: [PATCH 152/270] Reduce Excessive Reports on Live Tests (#10175) * Fix runs and wacky reports * DEBUG * More debugs * Remove debug * Update version * Fix over-reporting --- .github/workflows/integration-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index ed657cc0c11..ea1a2e77def 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -650,7 +650,7 @@ jobs: testnet-smoke-tests-notify: name: Live Testnet Start Slack Thread - if: ${{ success() || failure() }} + if: ${{ github.event_name == 'schedule' || (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')) }} ## Only run live tests on new tags and nightly environment: integration outputs: thread_ts: ${{ steps.slack.outputs.thread_ts }} From c09c7c7bc314072b2d51a191632409d360a18f68 Mon Sep 17 00:00:00 2001 From: Chris Cushman <104409744+vreff@users.noreply.github.com> Date: Fri, 11 Aug 2023 15:58:30 -0400 Subject: [PATCH 153/270] Remove extraArgs from v2plus log (#10171) * Remove extraArgs from v2plus log * prettier * update interfaces * Make requestCommitment memory * Update tests --- contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 8 ++------ contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol | 12 ++---------- .../vrf_coordinator_v2plus/vrf_coordinator_v2plus.go | 7 +++---- ...rated-wrapper-dependency-versions-do-not-edit.txt | 2 +- core/services/blockhashstore/feeder_test.go | 1 - core/services/vrf/v2/coordinator_v2x_interface.go | 9 --------- core/services/vrf/v2/integration_v2_test.go | 1 - 7 files changed, 8 insertions(+), 32 deletions(-) diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 369344b5703..1250da91d64 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -63,7 +63,6 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { uint256 outputSeed, uint256 indexed subID, uint96 payment, - bytes extraArgs, bool success ); @@ -348,7 +347,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { function getRandomnessFromProof( Proof calldata proof, - RequestCommitment calldata rc + RequestCommitment memory rc ) internal view returns (Output memory) { bytes32 keyHash = hashOfKey(proof.pk); // Only registered proving keys are permitted. @@ -444,12 +443,9 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { s_withdrawableTokens[s_provingKeys[output.keyHash]] += payment; } - bytes memory extraArgs = VRFV2PlusClient._argsToBytes( - VRFV2PlusClient.ExtraArgsV1({nativePayment: nativePayment}) - ); // Include payment in the event for tracking costs. // event RandomWordsFulfilled(uint256 indexed requestId, uint256 outputSeed, uint96 payment, bytes extraArgs, bool success); - emit RandomWordsFulfilled(output.requestId, output.randomness, rc.subId, payment, extraArgs, success); + emit RandomWordsFulfilled(output.requestId, output.randomness, rc.subId, payment, success); return payment; } diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol index 9fd4b02a9fe..2fed36c86b2 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol @@ -256,12 +256,8 @@ contract VRFV2Plus is BaseTest { VmSafe.Log[] memory entries = vm.getRecordedLogs(); assertEq(entries[0].topics[1], bytes32(uint256(requestId))); assertEq(entries[0].topics[2], bytes32(uint256(subId))); - (uint256 loggedOutputSeed, , bytes memory loggedExtraArgs, bool loggedSuccess) = abi.decode( - entries[0].data, - (uint256, uint256, bytes, bool) - ); + (uint256 loggedOutputSeed, , bool loggedSuccess) = abi.decode(entries[0].data, (uint256, uint256, bool)); assertEq(loggedOutputSeed, outputSeed); - assertEq(loggedExtraArgs, rc.extraArgs); assertEq(loggedSuccess, true); (fulfilled, , ) = s_testConsumer.s_requests(requestId); @@ -377,12 +373,8 @@ contract VRFV2Plus is BaseTest { VmSafe.Log[] memory entries = vm.getRecordedLogs(); assertEq(entries[0].topics[1], bytes32(uint256(requestId))); assertEq(entries[0].topics[2], bytes32(uint256(subId))); - (uint256 loggedOutputSeed, , bytes memory loggedExtraArgs, bool loggedSuccess) = abi.decode( - entries[0].data, - (uint256, uint256, bytes, bool) - ); + (uint256 loggedOutputSeed, , bool loggedSuccess) = abi.decode(entries[0].data, (uint256, uint256, bool)); assertEq(loggedOutputSeed, outputSeed); - assertEq(loggedExtraArgs, rc.extraArgs); assertEq(loggedSuccess, true); (fulfilled, , ) = s_testConsumer.s_requests(requestId); diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index 9558960e82a..453d305e5da 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -66,8 +66,8 @@ type VRFV2PlusClientRandomWordsRequest struct { } var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"reentrancyLock\",\"type\":\"bool\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200605038038062006050833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615e75620001db6000396000818161060b0152613ac70152615e756000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095b578063ee9d2d3814610982578063f2fde38b146109af57600080fd5b8063dc311dd3146108f7578063e72f6e3014610928578063e8509bff1461094857600080fd5b8063d98e620e116100bb578063d98e620e14610881578063da2f2610146108a1578063dac83d29146108d757600080fd5b8063bec4c08c14610821578063caf70c4a14610841578063cb6317971461086157600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107c1578063b08c8795146107e1578063b2a7cac51461080157600080fd5b8063a4c0ed3614610761578063a8cb447b14610781578063aa433aff146107a157600080fd5b80639b1c385e116101745780639b1c385e146106f25780639d40a6fd14610712578063a21a23e41461074c57600080fd5b806386fe91c7146106a85780638da5cb5b146106d457600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461062d5780636f64f03f1461067357806379ba50971461069357600080fd5b806364d51a2a146105c457806366316d8d146105d9578063689c4517146105f957600080fd5b806346d8d4861161022d57806346d8d4861461056457806357133e64146105845780635d06b4ab146105a457600080fd5b806340d6bb821461050957806341af6c871461053457600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610495578063330987b3146104b1578063405b84fa146104e957600080fd5b80630ae095401461041557806315c48b84146104355780631b6b6d231461045d57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103f557600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109cf565b60405161031a9392919061595f565b60405180910390f35b34801561032f57600080fd5b5061034361033e3660046152cb565b610a4b565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600a546103bd9061ffff81169063ffffffff62010000820481169160ff600160301b8204169167010000000000000082048116916b01000000000000000000000090041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a00161031a565b34801561040157600080fd5b5061034361041036600461540c565b610c0d565b34801561042157600080fd5b506103436104303660046156c9565b610da1565b34801561044157600080fd5b5061044a60c881565b60405161ffff909116815260200161031a565b34801561046957600080fd5b5060025461047d906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b3480156104a157600080fd5b506040516001815260200161031a565b3480156104bd57600080fd5b506104d16104cc3660046154df565b610e6f565b6040516001600160601b03909116815260200161031a565b3480156104f557600080fd5b506103436105043660046156c9565b6113b7565b34801561051557600080fd5b5061051f6101f481565b60405163ffffffff909116815260200161031a565b34801561054057600080fd5b5061055461054f366004615461565b611797565b604051901515815260200161031a565b34801561057057600080fd5b5061034361057f3660046152e8565b611999565b34801561059057600080fd5b5061034361059f36600461531d565b611b16565b3480156105b057600080fd5b506103436105bf3660046152cb565b611b8f565b3480156105d057600080fd5b5061044a606481565b3480156105e557600080fd5b506103436105f43660046152e8565b611c66565b34801561060557600080fd5b5061047d7f000000000000000000000000000000000000000000000000000000000000000081565b34801561063957600080fd5b50600f546106569063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561067f57600080fd5b5061034361068e366004615356565b611e05565b34801561069f57600080fd5b50610343611f1d565b3480156106b457600080fd5b506007546104d1906801000000000000000090046001600160601b031681565b3480156106e057600080fd5b506000546001600160a01b031661047d565b3480156106fe57600080fd5b5061035b61070d3660046155db565b611fce565b34801561071e57600080fd5b506007546107339067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561075857600080fd5b5061035b6123f3565b34801561076d57600080fd5b5061034361077c366004615383565b61267b565b34801561078d57600080fd5b5061034361079c3660046152cb565b61284d565b3480156107ad57600080fd5b506103436107bc366004615461565b612968565b3480156107cd57600080fd5b5060035461047d906001600160a01b031681565b3480156107ed57600080fd5b506103436107fc36600461562b565b6129c8565b34801561080d57600080fd5b5061034361081c366004615461565b612b64565b34801561082d57600080fd5b5061034361083c3660046156c9565b612cb3565b34801561084d57600080fd5b5061035b61085c366004615428565b612e69565b34801561086d57600080fd5b5061034361087c3660046156c9565b612e99565b34801561088d57600080fd5b5061035b61089c366004615461565b61319d565b3480156108ad57600080fd5b5061047d6108bc366004615461565b600b602052600090815260409020546001600160a01b031681565b3480156108e357600080fd5b506103436108f23660046156c9565b6131be565b34801561090357600080fd5b50610917610912366004615461565b6132dd565b60405161031a959493929190615b5d565b34801561093457600080fd5b506103436109433660046152cb565b6133d9565b610343610956366004615461565b6135a1565b34801561096757600080fd5b506007546104d190600160a01b90046001600160601b031681565b34801561098e57600080fd5b5061035b61099d366004615461565b600d6020526000908152604090205481565b3480156109bb57600080fd5b506103436109ca3660046152cb565b6136e0565b600a54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3957602002820191906000526020600020905b815481526020019060010190808311610a25575b50505050509050925092509250909192565b610a536136f1565b60105460005b81811015610be057826001600160a01b031660108281548110610a7e57610a7e615e19565b6000918252602090912001546001600160a01b03161415610bce576010610aa6600184615d11565b81548110610ab657610ab6615e19565b600091825260209091200154601080546001600160a01b039092169183908110610ae257610ae2615e19565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826010610b19600185615d11565b81548110610b2957610b29615e19565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506010805480610b6857610b68615e03565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bd881615d80565b915050610a59565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c156136f1565b604080518082018252600091610c44919084906002908390839080828437600092019190915250612e69915050565b6000818152600b60205260409020549091506001600160a01b031680610c8057604051631dfd6e1360e21b815260048101839052602401610c01565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d585782600c8281548110610cbb57610cbb615e19565b90600052602060002001541415610d4657600c805460009190610ce090600190615d11565b81548110610cf057610cf0615e19565b9060005260206000200154905080600c8381548110610d1157610d11615e19565b600091825260209091200155600c805480610d2e57610d2e615e03565b60019003818190600052602060002001600090559055505b80610d5081615d80565b915050610c9d565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9491815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610dd957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0d57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615610e385760405163769dd35360e11b815260040160405180910390fd5b610e4184611797565b15610e5f57604051631685ecdd60e31b815260040160405180910390fd5b610e69848461374d565b50505050565b600a54600090600160301b900460ff1615610e9d5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eae85856138e4565b90506000610ec260808601606087016156ee565b63ffffffff1667ffffffffffffffff811115610ee057610ee0615e2f565b604051908082528060200260200182016040528015610f09578160200160208202803683370190505b50905060005b610f1f60808701606088016156ee565b63ffffffff16811015610f9457826040015181604051602001610f4c929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f7757610f77615e19565b602090810291909101015280610f8c81615d80565b915050610f0f565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e30000000000000000000000000000000000000000000000000000000091610fe5919086906024016159d2565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990941693909317909252600a805466ff0000000000001916600160301b17905591506000906110779061105b9060608b01908b016156ee565b63ffffffff1661107160a08b0160808c016152cb565b84613c35565b600a805466ff00000000000019169055602089810135600090815260069091526040902054909150600160c01b900467ffffffffffffffff166110bb816001615c90565b6020808b01356000908152600690915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915561111c61111760a08c018c615bb3565b613c83565b51600a54909150600090611148908a906b010000000000000000000000900463ffffffff163a85613d32565b90508115611251576020808c01356000908152600690915260409020546001600160601b03808316600160601b90920416101561119857604051631e9acf1760e31b815260040160405180910390fd5b60208b81013560009081526006909152604090208054829190600c906111cf908490600160601b90046001600160601b0316615d28565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261122891859116615cbc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555061133d565b6020808c01356000908152600690915260409020546001600160601b038083169116101561129257604051631e9acf1760e31b815260040160405180910390fd5b6020808c0135600090815260069091526040812080548392906112bf9084906001600160601b0316615d28565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600890915281208054859450909261131891859116615cbc565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b60006113586040518060200160405280851515815250613d82565b90508b6020013589602001517f7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e8b6040015185858a60405161139d9493929190615b22565b60405180910390a350985050505050505050505b92915050565b6113c081613e08565b6113e857604051635428d44960e01b81526001600160a01b0382166004820152602401610c01565b6000806000806113f7866132dd565b945094505093509350336001600160a01b0316826001600160a01b0316146114615760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c01565b61146a86611797565b156114b75760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c01565b60006040518060c001604052806114cc600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b0316815250905060008160405160200161152091906158ea565b604051602081830303815290604052905061153a88613e72565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061158c9085906004016158d7565b6000604051808303818588803b1580156115a557600080fd5b505af11580156115b9573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561161557600080fd5b505af1158015611629573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061164d9190615444565b6116995760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c01565b60005b835181101561174a578381815181106116b7576116b7615e19565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561171f57600080fd5b505af1158015611733573d6000803e3d6000fd5b50505050808061174290615d80565b91505061169c565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561182157602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611803575b505050505081525050905060005b81604001515181101561198f5760005b600c5481101561197c576000611945600c838154811061186157611861615e19565b90600052602060002001548560400151858151811061188257611882615e19565b60200260200101518860046000896040015189815181106118a5576118a5615e19565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119695750600195945050505050565b508061197481615d80565b91505061183f565b508061198781615d80565b91505061182f565b5060009392505050565b600a54600160301b900460ff16156119c45760405163769dd35360e11b815260040160405180910390fd5b336000908152600960205260409020546001600160601b0380831691161015611a0057604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611a289084906001600160601b0316615d28565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a709190615d28565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611aea576040519150601f19603f3d011682016040523d82523d6000602084013e611aef565b606091505b5050905080611b1157604051630dcf35db60e41b815260040160405180910390fd5b505050565b611b1e6136f1565b6002546001600160a01b031615611b61576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611b976136f1565b611ba081613e08565b15611be2576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c01565b601080546001810182556000919091527f1b6847dc741a1b0cd08d278845f9d819d87b734759afb55fe2de5cb82a9ae6720180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600a54600160301b900460ff1615611c915760405163769dd35360e11b815260040160405180910390fd5b336000908152600860205260409020546001600160601b0380831691161015611ccd57604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611cf59084906001600160601b0316615d28565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611d3d9190615d28565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611dac57600080fd5b505af1158015611dc0573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611de49190615444565b611e0157604051631e9acf1760e31b815260040160405180910390fd5b5050565b611e0d6136f1565b604080518082018252600091611e3c919084906002908390839080828437600092019190915250612e69915050565b6000818152600b60205260409020549091506001600160a01b031615611e91576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c01565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d94565b6001546001600160a01b03163314611f775760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c01565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600a54600090600160301b900460ff1615611ffc5760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b031661203757604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612089576040516379bfd40160e01b815260208401356004820152336024820152604401610c01565b600a5461ffff166120a06060850160408601615610565b61ffff1610806120c3575060c86120bd6060850160408601615610565b61ffff16115b15612109576120d86060840160408501615610565b600a5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c01565b600a5462010000900463ffffffff1661212860808501606086016156ee565b63ffffffff1611156121915761214460808401606085016156ee565b600a546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c01565b6101f46121a460a08501608086016156ee565b63ffffffff161115612203576121c060a08401608085016156ee565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c01565b6000612210826001615c90565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061229c9061111790890189615bb3565b905060006122a982613d82565b9050836122b46140c2565b60208a01356122c960808c0160608d016156ee565b6122d960a08d0160808e016156ee565b33866040516020016122f19796959493929190615a5f565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d60400160208101906123689190615610565b8e606001602081019061237b91906156ee565b8f608001602081019061238e91906156ee565b896040516123a196959493929190615a20565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff191667ffffffffffffffff9490941693909317909255925050505b919050565b600a54600090600160301b900460ff16156124215760405163769dd35360e11b815260040160405180910390fd5b60003361242f600143615d11565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124c783615d9b565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff81111561250957612509615e2f565b604051908082528060200260200182016040528015612532578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b03928316178355925160018301805490941691161790915592518051949550909361263d92600285019201906150f6565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600a54600160301b900460ff16156126a65760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b031633146126ea576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612724576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061273282840184615461565b6000818152600560205260409020549091506001600160a01b031661276a57604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127918385615cbc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127d99190615cbc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a82878461282c9190615c78565b604080519283526020830191909152015b60405180910390a2505050505050565b6128556136f1565b6007544790600160a01b90046001600160601b031681811115612895576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b115760006128a98284615d11565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128f8576040519150601f19603f3d011682016040523d82523d6000602084013e6128fd565b606091505b505090508061291f57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6129706136f1565b6000818152600560205260409020546001600160a01b03166129a557604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0a9082906001600160a01b031661374d565b6129d06136f1565b60c861ffff87161115612a0a5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c01565b60008213612a2e576040516321ea67b360e11b815260048101839052602401610c01565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600a805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff00000000000000000000001916176b01000000000000000000000083021790558a51600f80548d87015192891667ffffffffffffffff1990911617640100000000928916929092029190911790819055600e8d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600a54600160301b900460ff1615612b8f5760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612bc457604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c3657600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c01565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612ceb57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d1f57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612d4a5760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612d96576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612dce57610e69565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612e7c91906158c9565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612ed157604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612f0557604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612f305760405163769dd35360e11b815260040160405180910390fd5b612f3984611797565b15612f5757604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16612fb4576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c01565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561301757602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612ff9575b5050505050905060006001825161302e9190615d11565b905060005b825181101561313a57856001600160a01b031683828151811061305857613058615e19565b60200260200101516001600160a01b0316141561312857600083838151811061308357613083615e19565b6020026020010151905080600560008a815260200190815260200160002060020183815481106130b5576130b5615e19565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260059091526040902060020180548061310057613100615e03565b600082815260209020810160001990810180546001600160a01b03191690550190555061313a565b8061313281615d80565b915050613033565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161283d565b600c81815481106131ad57600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b0316806131f657604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461322a57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff16156132555760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e695760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e5b565b6000818152600560205260408120548190819081906060906001600160a01b031661331b57604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156133bf57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116133a1575b505050505090509450945094509450945091939590929450565b6133e16136f1565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561343e57600080fd5b505afa158015613452573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613476919061547a565b6007549091506801000000000000000090046001600160601b0316818111156134bc576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b115760006134d08284615d11565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561352057600080fd5b505af1158015613534573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906135589190615444565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600a54600160301b900460ff16156135cc5760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b031661360157604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136308385615cbc565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136789190615cbc565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136cb9190615c78565b60408051928352602083019190915201612ca7565b6136e86136f1565b610c0a8161415b565b6000546001600160a01b0316331461374b5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c01565b565b60008061375984613e72565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137b657600080fd5b505af11580156137ca573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137ee9190615444565b61380b57604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613861576040519150601f19603f3d011682016040523d82523d6000602084013e613866565b606091505b505090508061388857604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b60408051606081018252600080825260208201819052818301819052825180840184529192909161392d9186906002908390839080828437600092019190915250612e69915050565b6000818152600b60205260409020549091506001600160a01b03168061396957604051631dfd6e1360e21b815260048101839052602401610c01565b6000828660c0013560405160200161398b929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d909352912054909150806139ea576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b816139f86020880188615709565b6020880135613a0d60608a0160408b016156ee565b613a1d60808b0160608c016156ee565b613a2d60a08c0160808d016152cb565b613a3a60a08d018d615bb3565b604051602001613a51989796959493929190615aa9565b604051602081830303815290604052805190602001208114613a9f576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613ab6613ab16020890189615709565b614205565b905080613bc4576001600160a01b037f00000000000000000000000000000000000000000000000000000000000000001663e9413d38613af960208a018a615709565b6040516001600160e01b031960e084901b16815267ffffffffffffffff909116600482015260240160206040518083038186803b158015613b3957600080fd5b505afa158015613b4d573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b71919061547a565b905080613bc457613b856020880188615709565b6040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c01565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613c0c613c06368c90038c018c615537565b8361430c565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613c4757600080fd5b611388810390508460408204820311613c5f57600080fd5b50823b613c6b57600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613cac57506040805160208101909152600081526113b1565b7f92fd133800000000000000000000000000000000000000000000000000000000613cd78385615d50565b6001600160e01b03191614613d18576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613d258260048186615c4e565b810190613c7c9190615493565b60008115613d6057600f54613d599086908690640100000000900463ffffffff1686614377565b9050613d7a565b600f54613d77908690869063ffffffff16866143e1565b90505b949350505050565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613dbb91511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b6000805b601054811015613e6957826001600160a01b031660108281548110613e3357613e33615e19565b6000918252602090912001546001600160a01b03161415613e575750600192915050565b80613e6181615d80565b915050613e0c565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613efe57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613ee0575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b826040015151811015613fdc576004600084604001518381518110613f8b57613f8b615e19565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613fd481615d80565b915050613f64565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590614014600283018261515b565b50506000858152600660205260408120556007805485919060089061404f9084906801000000000000000090046001600160601b0316615d28565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b03166140979190615d28565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60004661a4b18114806140d7575062066eed81145b156141545760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b15801561411657600080fd5b505afa15801561412a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061414e919061547a565b91505090565b4391505090565b6001600160a01b0381163314156141b45760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c01565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b181148061421a575062066eed81145b156142fc576101008367ffffffffffffffff166142356140c2565b61423f9190615d11565b118061425c575061424e6140c2565b8367ffffffffffffffff1610155b1561426a5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b1580156142c457600080fd5b505afa1580156142d8573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c7c919061547a565b505067ffffffffffffffff164090565b60006143408360000151846020015185604001518660600151868860a001518960c001518a60e001518b61010001516144e8565b600383602001516040516020016143589291906159be565b60408051601f1981840301815291905280516020909101209392505050565b600080614382614723565b905060005a6143918888615c78565b61439b9190615d11565b6143a59085615cf2565b905060006143be63ffffffff871664e8d4a51000615cf2565b9050826143cb8284615c78565b6143d59190615c78565b98975050505050505050565b6000806143ec61477f565b905060008113614412576040516321ea67b360e11b815260048101829052602401610c01565b600061441c614723565b9050600082825a61442d8b8b615c78565b6144379190615d11565b6144419088615cf2565b61444b9190615c78565b61445d90670de0b6b3a7640000615cf2565b6144679190615cde565b9050600061448063ffffffff881664e8d4a51000615cf2565b9050614498816b033b2e3c9fd0803ce8000000615d11565b8211156144d1576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6144db8183615c78565b9998505050505050505050565b6144f189614867565b61453d5760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c01565b61454688614867565b6145925760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c01565b61459b83614867565b6145e75760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c01565b6145f082614867565b61463c5760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c01565b614648878a8887614940565b6146945760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c01565b60006146a08a87614a75565b905060006146b3898b878b868989614ad9565b905060006146c4838d8d8a86614bf9565b9050808a146147155760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c01565b505050505050505050505050565b60004661a4b1811480614738575062066eed81145b1561477757606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b15801561411657600080fd5b600091505090565b600a54600354604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b1580156147fa57600080fd5b505afa15801561480e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906148329190615733565b509450909250849150508015614856575061484d8242615d11565b8463ffffffff16105b15613d7a5750600e54949350505050565b80516000906401000003d019116148c05760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d019116149195760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d0199080096149398360005b6020020151614c39565b1492915050565b60006001600160a01b0382166149985760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c01565b6020840151600090600116156149af57601c6149b2565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614a4d573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614a7d615179565b614aaa60018484604051602001614a96939291906158a8565b604051602081830303815290604052614c5d565b90505b614ab681614867565b6113b1578051604080516020810192909252614ad29101614a96565b9050614aad565b614ae1615179565b825186516401000003d0199081900691061415614b405760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c01565b614b4b878988614cab565b614b975760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c01565b614ba2848685614cab565b614bee5760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c01565b6143d5868484614de5565b600060028686868587604051602001614c1796959493929190615849565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614c65615179565b614c6e82614eac565b8152614c83614c7e82600061492f565b614ee7565b6020820181905260029006600114156123ee576020810180516401000003d019039052919050565b600082614cfa5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c01565b83516020850151600090614d1090600290615dc3565b15614d1c57601c614d1f565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614d91573d6000803e3d6000fd5b505050602060405103519050600086604051602001614db09190615837565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614ded615179565b835160208086015185519186015160009384938493614e0e93909190614f07565b919450925090506401000003d019858209600114614e6e5760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c01565b60405180604001604052806401000003d01980614e8d57614e8d615ded565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106123ee57604080516020808201939093528151808203840181529082019091528051910120614eb4565b60006113b1826002614f006401000003d0196001615c78565b901c614fe7565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614f4783838585615089565b9098509050614f5888828e886150ad565b9098509050614f6988828c876150ad565b90985090506000614f7c8d878b856150ad565b9098509050614f8d88828686615089565b9098509050614f9e88828e896150ad565b9098509050818114614fd3576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614fd7565b8196505b5050505050509450945094915050565b600080614ff2615197565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a08201526150246151b5565b60208160c0846005600019fa92508261507f5760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c01565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b82805482825590600052602060002090810192821561514b579160200282015b8281111561514b57825182546001600160a01b0319166001600160a01b03909116178255602090920191600190910190615116565b506151579291506151d3565b5090565b5080546000825590600052602060002090810190610c0a91906151d3565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561515757600081556001016151d4565b80356123ee81615e45565b80604081018310156113b157600080fd5b600082601f83011261521557600080fd5b61521d615c01565b80838560408601111561522f57600080fd5b60005b6002811015615251578135845260209384019390910190600101615232565b509095945050505050565b600060c0828403121561526e57600080fd5b50919050565b803561ffff811681146123ee57600080fd5b803563ffffffff811681146123ee57600080fd5b805169ffffffffffffffffffff811681146123ee57600080fd5b80356001600160601b03811681146123ee57600080fd5b6000602082840312156152dd57600080fd5b8135613c7c81615e45565b600080604083850312156152fb57600080fd5b823561530681615e45565b9150615314602084016152b4565b90509250929050565b6000806040838503121561533057600080fd5b823561533b81615e45565b9150602083013561534b81615e45565b809150509250929050565b6000806060838503121561536957600080fd5b823561537481615e45565b915061531484602085016151f3565b6000806000806060858703121561539957600080fd5b84356153a481615e45565b935060208501359250604085013567ffffffffffffffff808211156153c857600080fd5b818701915087601f8301126153dc57600080fd5b8135818111156153eb57600080fd5b8860208285010111156153fd57600080fd5b95989497505060200194505050565b60006040828403121561541e57600080fd5b613c7c83836151f3565b60006040828403121561543a57600080fd5b613c7c8383615204565b60006020828403121561545657600080fd5b8151613c7c81615e5a565b60006020828403121561547357600080fd5b5035919050565b60006020828403121561548c57600080fd5b5051919050565b6000602082840312156154a557600080fd5b6040516020810181811067ffffffffffffffff821117156154c8576154c8615e2f565b60405282356154d681615e5a565b81529392505050565b6000808284036101c08112156154f457600080fd5b6101a08082121561550457600080fd5b849350830135905067ffffffffffffffff81111561552157600080fd5b61552d8582860161525c565b9150509250929050565b60006101a0828403121561554a57600080fd5b615552615c2a565b61555c8484615204565b815261556b8460408501615204565b60208201526080830135604082015260a0830135606082015260c0830135608082015261559a60e084016151e8565b60a08201526101006155ae85828601615204565b60c08301526155c1856101408601615204565b60e083015261018084013581830152508091505092915050565b6000602082840312156155ed57600080fd5b813567ffffffffffffffff81111561560457600080fd5b613d7a8482850161525c565b60006020828403121561562257600080fd5b613c7c82615274565b60008060008060008086880360e081121561564557600080fd5b61564e88615274565b965061565c60208901615286565b955061566a60408901615286565b945061567860608901615286565b9350608088013592506040609f198201121561569357600080fd5b5061569c615c01565b6156a860a08901615286565b81526156b660c08901615286565b6020820152809150509295509295509295565b600080604083850312156156dc57600080fd5b82359150602083013561534b81615e45565b60006020828403121561570057600080fd5b613c7c82615286565b60006020828403121561571b57600080fd5b813567ffffffffffffffff81168114613c7c57600080fd5b600080600080600060a0868803121561574b57600080fd5b6157548661529a565b94506020860151935060408601519250606086015191506157776080870161529a565b90509295509295909350565b600081518084526020808501945080840160005b838110156157bc5781516001600160a01b031687529582019590820190600101615797565b509495945050505050565b8060005b6002811015610e695781518452602093840193909101906001016157cb565b6000815180845260005b81811015615810576020818501810151868301820152016157f4565b81811115615822576000602083870101525b50601f01601f19169290920160200192915050565b61584181836157c7565b604001919050565b86815261585960208201876157c7565b61586660608201866157c7565b61587360a08201856157c7565b61588060e08201846157c7565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526158b860208201846157c7565b606081019190915260800192915050565b604081016113b182846157c7565b602081526000613c7c60208301846157ea565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261593060e0840182615783565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159b057845183529383019391830191600101615994565b509098975050505050505050565b82815260608101613c7c60208301846157c7565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a13578451835293830193918301916001016159f7565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a08301526143d560c08301846157ea565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c08301526144db60e08301846157ea565b88815267ffffffffffffffff88166020820152866040820152600063ffffffff80881660608401528087166080840152506001600160a01b03851660a083015260e060c08301528260e08301526101008385828501376000838501820152601f909301601f191690910190910198975050505050505050565b8481526001600160601b0384166020820152608060408201526000615b4a60808301856157ea565b9050821515606083015295945050505050565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615ba860a0830184615783565b979650505050505050565b6000808335601e19843603018112615bca57600080fd5b83018035915067ffffffffffffffff821115615be557600080fd5b602001915036819003821315615bfa57600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c2457615c24615e2f565b60405290565b604051610120810167ffffffffffffffff81118282101715615c2457615c24615e2f565b60008085851115615c5e57600080fd5b83861115615c6b57600080fd5b5050820193919092039150565b60008219821115615c8b57615c8b615dd7565b500190565b600067ffffffffffffffff808316818516808303821115615cb357615cb3615dd7565b01949350505050565b60006001600160601b03808316818516808303821115615cb357615cb3615dd7565b600082615ced57615ced615ded565b500490565b6000816000190483118215151615615d0c57615d0c615dd7565b500290565b600082821015615d2357615d23615dd7565b500390565b60006001600160601b0383811690831681811015615d4857615d48615dd7565b039392505050565b6001600160e01b03198135818116916004851015615d785780818660040360031b1b83161692505b505092915050565b6000600019821415615d9457615d94615dd7565b5060010190565b600067ffffffffffffffff80831681811415615db957615db9615dd7565b6001019392505050565b600082615dd257615dd2615ded565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0a57600080fd5b8015158114610c0a57600080fdfea164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"reentrancyLock\",\"type\":\"bool\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b50604051620060ca380380620060ca833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615eef620001db6000396000818161060b0152613aae0152615eef6000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095b578063ee9d2d3814610982578063f2fde38b146109af57600080fd5b8063dc311dd3146108f7578063e72f6e3014610928578063e8509bff1461094857600080fd5b8063d98e620e116100bb578063d98e620e14610881578063da2f2610146108a1578063dac83d29146108d757600080fd5b8063bec4c08c14610821578063caf70c4a14610841578063cb6317971461086157600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107c1578063b08c8795146107e1578063b2a7cac51461080157600080fd5b8063a4c0ed3614610761578063a8cb447b14610781578063aa433aff146107a157600080fd5b80639b1c385e116101745780639b1c385e146106f25780639d40a6fd14610712578063a21a23e41461074c57600080fd5b806386fe91c7146106a85780638da5cb5b146106d457600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461062d5780636f64f03f1461067357806379ba50971461069357600080fd5b806364d51a2a146105c457806366316d8d146105d9578063689c4517146105f957600080fd5b806346d8d4861161022d57806346d8d4861461056457806357133e64146105845780635d06b4ab146105a457600080fd5b806340d6bb821461050957806341af6c871461053457600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610495578063330987b3146104b1578063405b84fa146104e957600080fd5b80630ae095401461041557806315c48b84146104355780631b6b6d231461045d57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103f557600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109cf565b60405161031a93929190615976565b60405180910390f35b34801561032f57600080fd5b5061034361033e36600461530c565b610a4b565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600a546103bd9061ffff81169063ffffffff62010000820481169160ff600160301b8204169167010000000000000082048116916b01000000000000000000000090041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a00161031a565b34801561040157600080fd5b5061034361041036600461544d565b610c0d565b34801561042157600080fd5b5061034361043036600461570a565b610da1565b34801561044157600080fd5b5061044a60c881565b60405161ffff909116815260200161031a565b34801561046957600080fd5b5060025461047d906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b3480156104a157600080fd5b506040516001815260200161031a565b3480156104bd57600080fd5b506104d16104cc366004615520565b610e6f565b6040516001600160601b03909116815260200161031a565b3480156104f557600080fd5b5061034361050436600461570a565b6113ad565b34801561051557600080fd5b5061051f6101f481565b60405163ffffffff909116815260200161031a565b34801561054057600080fd5b5061055461054f3660046154a2565b61178d565b604051901515815260200161031a565b34801561057057600080fd5b5061034361057f366004615329565b61198f565b34801561059057600080fd5b5061034361059f36600461535e565b611b0c565b3480156105b057600080fd5b506103436105bf36600461530c565b611b85565b3480156105d057600080fd5b5061044a606481565b3480156105e557600080fd5b506103436105f4366004615329565b611c5c565b34801561060557600080fd5b5061047d7f000000000000000000000000000000000000000000000000000000000000000081565b34801561063957600080fd5b50600f546106569063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561067f57600080fd5b5061034361068e366004615397565b611dfb565b34801561069f57600080fd5b50610343611f13565b3480156106b457600080fd5b506007546104d1906801000000000000000090046001600160601b031681565b3480156106e057600080fd5b506000546001600160a01b031661047d565b3480156106fe57600080fd5b5061035b61070d36600461561c565b611fc4565b34801561071e57600080fd5b506007546107339067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561075857600080fd5b5061035b6123e9565b34801561076d57600080fd5b5061034361077c3660046153c4565b612671565b34801561078d57600080fd5b5061034361079c36600461530c565b612843565b3480156107ad57600080fd5b506103436107bc3660046154a2565b61295e565b3480156107cd57600080fd5b5060035461047d906001600160a01b031681565b3480156107ed57600080fd5b506103436107fc36600461566c565b6129be565b34801561080d57600080fd5b5061034361081c3660046154a2565b612b5a565b34801561082d57600080fd5b5061034361083c36600461570a565b612ca9565b34801561084d57600080fd5b5061035b61085c366004615469565b612e5f565b34801561086d57600080fd5b5061034361087c36600461570a565b612e8f565b34801561088d57600080fd5b5061035b61089c3660046154a2565b613193565b3480156108ad57600080fd5b5061047d6108bc3660046154a2565b600b602052600090815260409020546001600160a01b031681565b3480156108e357600080fd5b506103436108f236600461570a565b6131b4565b34801561090357600080fd5b506109176109123660046154a2565b6132d3565b60405161031a959493929190615b14565b34801561093457600080fd5b5061034361094336600461530c565b6133cf565b6103436109563660046154a2565b613597565b34801561096757600080fd5b506007546104d190600160a01b90046001600160601b031681565b34801561098e57600080fd5b5061035b61099d3660046154a2565b600d6020526000908152604090205481565b3480156109bb57600080fd5b506103436109ca36600461530c565b6136d6565b600a54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3957602002820191906000526020600020905b815481526020019060010190808311610a25575b50505050509050925092509250909192565b610a536136e7565b60105460005b81811015610be057826001600160a01b031660108281548110610a7e57610a7e615e93565b6000918252602090912001546001600160a01b03161415610bce576010610aa6600184615ceb565b81548110610ab657610ab6615e93565b600091825260209091200154601080546001600160a01b039092169183908110610ae257610ae2615e93565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826010610b19600185615ceb565b81548110610b2957610b29615e93565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506010805480610b6857610b68615e7d565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bd881615dfa565b915050610a59565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c156136e7565b604080518082018252600091610c44919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031680610c8057604051631dfd6e1360e21b815260048101839052602401610c01565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d585782600c8281548110610cbb57610cbb615e93565b90600052602060002001541415610d4657600c805460009190610ce090600190615ceb565b81548110610cf057610cf0615e93565b9060005260206000200154905080600c8381548110610d1157610d11615e93565b600091825260209091200155600c805480610d2e57610d2e615e7d565b60019003818190600052602060002001600090559055505b80610d5081615dfa565b915050610c9d565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9491815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610dd957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0d57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615610e385760405163769dd35360e11b815260040160405180910390fd5b610e418461178d565b15610e5f57604051631685ecdd60e31b815260040160405180910390fd5b610e698484613743565b50505050565b600a54600090600160301b900460ff1615610e9d5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eb685610eb186615d5a565b6138da565b90506000610eca608086016060870161572f565b63ffffffff1667ffffffffffffffff811115610ee857610ee8615ea9565b604051908082528060200260200182016040528015610f11578160200160208202803683370190505b50905060005b610f27608087016060880161572f565b63ffffffff16811015610f9c57826040015181604051602001610f54929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f7f57610f7f615e93565b602090810291909101015280610f9481615dfa565b915050610f17565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e30000000000000000000000000000000000000000000000000000000091610fed919086906024016159e9565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990941693909317909252600a805466ff0000000000001916600160301b179055915060009061107f906110639060608b01908b0161572f565b63ffffffff1661107960a08b0160808c0161530c565b84613be9565b600a805466ff00000000000019169055602089810135600090815260069091526040902054909150600160c01b900467ffffffffffffffff166110c3816001615c6a565b6020808b01356000908152600690915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915561112461111f60a08c018c615b6a565b613c37565b51600a54909150600090611150908a906b010000000000000000000000900463ffffffff163a85613ce6565b90508115611259576020808c01356000908152600690915260409020546001600160601b03808316600160601b9092041610156111a057604051631e9acf1760e31b815260040160405180910390fd5b60208b81013560009081526006909152604090208054829190600c906111d7908490600160601b90046001600160601b0316615d02565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261123091859116615c96565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550611345565b6020808c01356000908152600690915260409020546001600160601b038083169116101561129a57604051631e9acf1760e31b815260040160405180910390fd5b6020808c0135600090815260069091526040812080548392906112c79084906001600160601b0316615d02565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600890915281208054859450909261132091859116615c96565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b6020888101516040808b015181519081526001600160601b03851681850152871515818301529051928e0135927f49580fdfd9497e1ed5c1b1cec0495087ae8e3f1267470ec2fb015db32e3d6aa79181900360600190a3985050505050505050505b92915050565b6113b681613d36565b6113de57604051635428d44960e01b81526001600160a01b0382166004820152602401610c01565b6000806000806113ed866132d3565b945094505093509350336001600160a01b0316826001600160a01b0316146114575760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c01565b6114608661178d565b156114ad5760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c01565b60006040518060c001604052806114c2600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016115169190615901565b604051602081830303815290604052905061153088613da0565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b038816906115829085906004016158ee565b6000604051808303818588803b15801561159b57600080fd5b505af11580156115af573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561160b57600080fd5b505af115801561161f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116439190615485565b61168f5760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c01565b60005b8351811015611740578381815181106116ad576116ad615e93565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561171557600080fd5b505af1158015611729573d6000803e3d6000fd5b50505050808061173890615dfa565b915050611692565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561181757602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117f9575b505050505081525050905060005b8160400151518110156119855760005b600c5481101561197257600061193b600c838154811061185757611857615e93565b90600052602060002001548560400151858151811061187857611878615e93565b602002602001015188600460008960400151898151811061189b5761189b615e93565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d60205260409020549091501561195f5750600195945050505050565b508061196a81615dfa565b915050611835565b508061197d81615dfa565b915050611825565b5060009392505050565b600a54600160301b900460ff16156119ba5760405163769dd35360e11b815260040160405180910390fd5b336000908152600960205260409020546001600160601b03808316911610156119f657604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611a1e9084906001600160601b0316615d02565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a669190615d02565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611ae0576040519150601f19603f3d011682016040523d82523d6000602084013e611ae5565b606091505b5050905080611b0757604051630dcf35db60e41b815260040160405180910390fd5b505050565b611b146136e7565b6002546001600160a01b031615611b57576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611b8d6136e7565b611b9681613d36565b15611bd8576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c01565b601080546001810182556000919091527f1b6847dc741a1b0cd08d278845f9d819d87b734759afb55fe2de5cb82a9ae6720180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600a54600160301b900460ff1615611c875760405163769dd35360e11b815260040160405180910390fd5b336000908152600860205260409020546001600160601b0380831691161015611cc357604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611ceb9084906001600160601b0316615d02565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611d339190615d02565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611da257600080fd5b505af1158015611db6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dda9190615485565b611df757604051631e9acf1760e31b815260040160405180910390fd5b5050565b611e036136e7565b604080518082018252600091611e32919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031615611e87576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c01565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d94565b6001546001600160a01b03163314611f6d5760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c01565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600a54600090600160301b900460ff1615611ff25760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b031661202d57604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff168061207f576040516379bfd40160e01b815260208401356004820152336024820152604401610c01565b600a5461ffff166120966060850160408601615651565b61ffff1610806120b9575060c86120b36060850160408601615651565b61ffff16115b156120ff576120ce6060840160408501615651565b600a5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c01565b600a5462010000900463ffffffff1661211e608085016060860161572f565b63ffffffff1611156121875761213a608084016060850161572f565b600a546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c01565b6101f461219a60a085016080860161572f565b63ffffffff1611156121f9576121b660a084016080850161572f565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c01565b6000612206826001615c6a565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e0808501849052855180860390910181526101009094019094528251920191909120929350906000906122929061111f90890189615b6a565b9050600061229f82613ff0565b9050836122aa614076565b60208a01356122bf60808c0160608d0161572f565b6122cf60a08d0160808e0161572f565b33866040516020016122e79796959493929190615a76565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061235e9190615651565b8e6060016020810190612371919061572f565b8f6080016020810190612384919061572f565b8960405161239796959493929190615a37565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff191667ffffffffffffffff9490941693909317909255925050505b919050565b600a54600090600160301b900460ff16156124175760405163769dd35360e11b815260040160405180910390fd5b600033612425600143615ceb565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124bd83615e15565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff8111156124ff576124ff615ea9565b604051908082528060200260200182016040528015612528578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b03928316178355925160018301805490941691161790915592518051949550909361263392600285019201906150aa565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600a54600160301b900460ff161561269c5760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b031633146126e0576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461271a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612728828401846154a2565b6000818152600560205260409020549091506001600160a01b031661276057604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127878385615c96565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127cf9190615c96565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846128229190615c52565b604080519283526020830191909152015b60405180910390a2505050505050565b61284b6136e7565b6007544790600160a01b90046001600160601b03168181111561288b576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b0757600061289f8284615ceb565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128ee576040519150601f19603f3d011682016040523d82523d6000602084013e6128f3565b606091505b505090508061291557604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6129666136e7565b6000818152600560205260409020546001600160a01b031661299b57604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0a9082906001600160a01b0316613743565b6129c66136e7565b60c861ffff87161115612a005760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c01565b60008213612a24576040516321ea67b360e11b815260048101839052602401610c01565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600a805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff00000000000000000000001916176b01000000000000000000000083021790558a51600f80548d87015192891667ffffffffffffffff1990911617640100000000928916929092029190911790819055600e8d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600a54600160301b900460ff1615612b855760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612bba57604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c2c57600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c01565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612ce157604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d1557604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612d405760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612d8c576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612dc457610e69565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612e7291906158e0565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612ec757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612efb57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612f265760405163769dd35360e11b815260040160405180910390fd5b612f2f8461178d565b15612f4d57604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16612faa576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c01565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561300d57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612fef575b505050505090506000600182516130249190615ceb565b905060005b825181101561313057856001600160a01b031683828151811061304e5761304e615e93565b60200260200101516001600160a01b0316141561311e57600083838151811061307957613079615e93565b6020026020010151905080600560008a815260200190815260200160002060020183815481106130ab576130ab615e93565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394909416939093179092558981526005909152604090206002018054806130f6576130f6615e7d565b600082815260209020810160001990810180546001600160a01b031916905501905550613130565b8061312881615dfa565b915050613029565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a79101612833565b600c81815481106131a357600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b0316806131ec57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461322057604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff161561324b5760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e695760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e51565b6000818152600560205260408120548190819081906060906001600160a01b031661331157604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156133b557602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613397575b505050505090509450945094509450945091939590929450565b6133d76136e7565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561343457600080fd5b505afa158015613448573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061346c91906154bb565b6007549091506801000000000000000090046001600160601b0316818111156134b2576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b075760006134c68284615ceb565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561351657600080fd5b505af115801561352a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061354e9190615485565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600a54600160301b900460ff16156135c25760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b03166135f757604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136268385615c96565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b031661366e9190615c96565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136c19190615c52565b60408051928352602083019190915201612c9d565b6136de6136e7565b610c0a8161410f565b6000546001600160a01b031633146137415760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c01565b565b60008061374f84613da0565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137ac57600080fd5b505af11580156137c0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137e49190615485565b61380157604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613857576040519150601f19603f3d011682016040523d82523d6000602084013e61385c565b606091505b505090508061387e57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905281830181905282518084018452919290916139239186906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b03168061395f57604051631dfd6e1360e21b815260048101839052602401610c01565b6000828660c00135604051602001613981929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d909352912054909150806139e0576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85516020808801516040808a015160608b015160808c015160a08d01519351613a0f978a979096959101615ac0565b604051602081830303815290604052805190602001208114613a5d576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a6c87600001516141b9565b905080613b785786516040517fe9413d3800000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063e9413d389060240160206040518083038186803b158015613af857600080fd5b505afa158015613b0c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b3091906154bb565b905080613b785786516040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c01565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613bc0613bba368c90038c018c615578565b836142c0565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613bfb57600080fd5b611388810390508460408204820311613c1357600080fd5b50823b613c1f57600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613c6057506040805160208101909152600081526113a7565b7f92fd133800000000000000000000000000000000000000000000000000000000613c8b8385615d2a565b6001600160e01b03191614613ccc576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613cd98260048186615c28565b810190613c3091906154d4565b60008115613d1457600f54613d0d9086908690640100000000900463ffffffff168661432b565b9050613d2e565b600f54613d2b908690869063ffffffff1686614395565b90505b949350505050565b6000805b601054811015613d9757826001600160a01b031660108281548110613d6157613d61615e93565b6000918252602090912001546001600160a01b03161415613d855750600192915050565b80613d8f81615dfa565b915050613d3a565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613e2c57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613e0e575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b826040015151811015613f0a576004600084604001518381518110613eb957613eb9615e93565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613f0281615dfa565b915050613e92565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590613f42600283018261510f565b505060008581526006602052604081205560078054859190600890613f7d9084906801000000000000000090046001600160601b0316615d02565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b0316613fc59190615d02565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa8260405160240161402991511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b60004661a4b181148061408b575062066eed81145b156141085760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140ca57600080fd5b505afa1580156140de573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061410291906154bb565b91505090565b4391505090565b6001600160a01b0381163314156141685760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c01565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b18114806141ce575062066eed81145b156142b0576101008367ffffffffffffffff166141e9614076565b6141f39190615ceb565b11806142105750614202614076565b8367ffffffffffffffff1610155b1561421e5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561427857600080fd5b505afa15801561428c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c3091906154bb565b505067ffffffffffffffff164090565b60006142f48360000151846020015185604001518660600151868860a001518960c001518a60e001518b610100015161449c565b6003836020015160405160200161430c9291906159d5565b60408051601f1981840301815291905280516020909101209392505050565b6000806143366146d7565b905060005a6143458888615c52565b61434f9190615ceb565b6143599085615ccc565b9050600061437263ffffffff871664e8d4a51000615ccc565b90508261437f8284615c52565b6143899190615c52565b98975050505050505050565b6000806143a0614733565b9050600081136143c6576040516321ea67b360e11b815260048101829052602401610c01565b60006143d06146d7565b9050600082825a6143e18b8b615c52565b6143eb9190615ceb565b6143f59088615ccc565b6143ff9190615c52565b61441190670de0b6b3a7640000615ccc565b61441b9190615cb8565b9050600061443463ffffffff881664e8d4a51000615ccc565b905061444c816b033b2e3c9fd0803ce8000000615ceb565b821115614485576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61448f8183615c52565b9998505050505050505050565b6144a58961481b565b6144f15760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c01565b6144fa8861481b565b6145465760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c01565b61454f8361481b565b61459b5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c01565b6145a48261481b565b6145f05760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c01565b6145fc878a88876148f4565b6146485760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c01565b60006146548a87614a29565b90506000614667898b878b868989614a8d565b90506000614678838d8d8a86614bad565b9050808a146146c95760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c01565b505050505050505050505050565b60004661a4b18114806146ec575062066eed81145b1561472b57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140ca57600080fd5b600091505090565b600a54600354604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b1580156147ae57600080fd5b505afa1580156147c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906147e6919061574a565b50945090925084915050801561480a57506148018242615ceb565b8463ffffffff16105b15613d2e5750600e54949350505050565b80516000906401000003d019116148745760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d019116148cd5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d0199080096148ed8360005b6020020151614bed565b1492915050565b60006001600160a01b03821661494c5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c01565b60208401516000906001161561496357601c614966565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614a01573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614a3161512d565b614a5e60018484604051602001614a4a939291906158bf565b604051602081830303815290604052614c11565b90505b614a6a8161481b565b6113a7578051604080516020810192909252614a869101614a4a565b9050614a61565b614a9561512d565b825186516401000003d0199081900691061415614af45760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c01565b614aff878988614c5f565b614b4b5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c01565b614b56848685614c5f565b614ba25760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c01565b614389868484614d99565b600060028686868587604051602001614bcb96959493929190615860565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614c1961512d565b614c2282614e60565b8152614c37614c328260006148e3565b614e9b565b6020820181905260029006600114156123e4576020810180516401000003d019039052919050565b600082614cae5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c01565b83516020850151600090614cc490600290615e3d565b15614cd057601c614cd3565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614d45573d6000803e3d6000fd5b505050602060405103519050600086604051602001614d64919061584e565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614da161512d565b835160208086015185519186015160009384938493614dc293909190614ebb565b919450925090506401000003d019858209600114614e225760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c01565b60405180604001604052806401000003d01980614e4157614e41615e67565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106123e457604080516020808201939093528151808203840181529082019091528051910120614e68565b60006113a7826002614eb46401000003d0196001615c52565b901c614f9b565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614efb8383858561503d565b9098509050614f0c88828e88615061565b9098509050614f1d88828c87615061565b90985090506000614f308d878b85615061565b9098509050614f418882868661503d565b9098509050614f5288828e89615061565b9098509050818114614f87576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614f8b565b8196505b5050505050509450945094915050565b600080614fa661514b565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a0820152614fd8615169565b60208160c0846005600019fa9250826150335760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c01565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156150ff579160200282015b828111156150ff57825182546001600160a01b0319166001600160a01b039091161782556020909201916001909101906150ca565b5061510b929150615187565b5090565b5080546000825590600052602060002090810190610c0a9190615187565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561510b5760008155600101615188565b80356123e481615ebf565b80604081018310156113a757600080fd5b600082601f8301126151c957600080fd5b6151d1615bb8565b8083856040860111156151e357600080fd5b60005b60028110156152055781358452602093840193909101906001016151e6565b509095945050505050565b600082601f83011261522157600080fd5b813567ffffffffffffffff8082111561523c5761523c615ea9565b604051601f8301601f19908116603f0116810190828211818310171561526457615264615ea9565b8160405283815286602085880101111561527d57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600060c082840312156152af57600080fd5b50919050565b803561ffff811681146123e457600080fd5b803563ffffffff811681146123e457600080fd5b805169ffffffffffffffffffff811681146123e457600080fd5b80356001600160601b03811681146123e457600080fd5b60006020828403121561531e57600080fd5b8135613c3081615ebf565b6000806040838503121561533c57600080fd5b823561534781615ebf565b9150615355602084016152f5565b90509250929050565b6000806040838503121561537157600080fd5b823561537c81615ebf565b9150602083013561538c81615ebf565b809150509250929050565b600080606083850312156153aa57600080fd5b82356153b581615ebf565b915061535584602085016151a7565b600080600080606085870312156153da57600080fd5b84356153e581615ebf565b935060208501359250604085013567ffffffffffffffff8082111561540957600080fd5b818701915087601f83011261541d57600080fd5b81358181111561542c57600080fd5b88602082850101111561543e57600080fd5b95989497505060200194505050565b60006040828403121561545f57600080fd5b613c3083836151a7565b60006040828403121561547b57600080fd5b613c3083836151b8565b60006020828403121561549757600080fd5b8151613c3081615ed4565b6000602082840312156154b457600080fd5b5035919050565b6000602082840312156154cd57600080fd5b5051919050565b6000602082840312156154e657600080fd5b6040516020810181811067ffffffffffffffff8211171561550957615509615ea9565b604052823561551781615ed4565b81529392505050565b6000808284036101c081121561553557600080fd5b6101a08082121561554557600080fd5b849350830135905067ffffffffffffffff81111561556257600080fd5b61556e8582860161529d565b9150509250929050565b60006101a0828403121561558b57600080fd5b615593615be1565b61559d84846151b8565b81526155ac84604085016151b8565b60208201526080830135604082015260a0830135606082015260c083013560808201526155db60e0840161519c565b60a08201526101006155ef858286016151b8565b60c08301526156028561014086016151b8565b60e083015261018084013581830152508091505092915050565b60006020828403121561562e57600080fd5b813567ffffffffffffffff81111561564557600080fd5b613d2e8482850161529d565b60006020828403121561566357600080fd5b613c30826152b5565b60008060008060008086880360e081121561568657600080fd5b61568f886152b5565b965061569d602089016152c7565b95506156ab604089016152c7565b94506156b9606089016152c7565b9350608088013592506040609f19820112156156d457600080fd5b506156dd615bb8565b6156e960a089016152c7565b81526156f760c089016152c7565b6020820152809150509295509295509295565b6000806040838503121561571d57600080fd5b82359150602083013561538c81615ebf565b60006020828403121561574157600080fd5b613c30826152c7565b600080600080600060a0868803121561576257600080fd5b61576b866152db565b945060208601519350604086015192506060860151915061578e608087016152db565b90509295509295909350565b600081518084526020808501945080840160005b838110156157d35781516001600160a01b0316875295820195908201906001016157ae565b509495945050505050565b8060005b6002811015610e695781518452602093840193909101906001016157e2565b6000815180845260005b818110156158275760208185018101518683018201520161580b565b81811115615839576000602083870101525b50601f01601f19169290920160200192915050565b61585881836157de565b604001919050565b86815261587060208201876157de565b61587d60608201866157de565b61588a60a08201856157de565b61589760e08201846157de565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526158cf60208201846157de565b606081019190915260800192915050565b604081016113a782846157de565b602081526000613c306020830184615801565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261594760e084018261579a565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159c7578451835293830193918301916001016159ab565b509098975050505050505050565b82815260608101613c3060208301846157de565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a2a57845183529383019391830191600101615a0e565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261438960c0830184615801565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261448f60e0830184615801565b87815267ffffffffffffffff87166020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261448f60e0830184615801565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615b5f60a083018461579a565b979650505050505050565b6000808335601e19843603018112615b8157600080fd5b83018035915067ffffffffffffffff821115615b9c57600080fd5b602001915036819003821315615bb157600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615bdb57615bdb615ea9565b60405290565b604051610120810167ffffffffffffffff81118282101715615bdb57615bdb615ea9565b60405160c0810167ffffffffffffffff81118282101715615bdb57615bdb615ea9565b60008085851115615c3857600080fd5b83861115615c4557600080fd5b5050820193919092039150565b60008219821115615c6557615c65615e51565b500190565b600067ffffffffffffffff808316818516808303821115615c8d57615c8d615e51565b01949350505050565b60006001600160601b03808316818516808303821115615c8d57615c8d615e51565b600082615cc757615cc7615e67565b500490565b6000816000190483118215151615615ce657615ce6615e51565b500290565b600082821015615cfd57615cfd615e51565b500390565b60006001600160601b0383811690831681811015615d2257615d22615e51565b039392505050565b6001600160e01b03198135818116916004851015615d525780818660040360031b1b83161692505b505092915050565b600060c08236031215615d6c57600080fd5b615d74615c05565b823567ffffffffffffffff8082168214615d8d57600080fd5b81835260208501356020840152615da6604086016152c7565b6040840152615db7606086016152c7565b6060840152615dc86080860161519c565b608084015260a0850135915080821115615de157600080fd5b50615dee36828601615210565b60a08301525092915050565b6000600019821415615e0e57615e0e615e51565b5060010190565b600067ffffffffffffffff80831681811415615e3357615e33615e51565b6001019392505050565b600082615e4c57615e4c615e67565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0a57600080fd5b8015158114610c0a57600080fdfea164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI @@ -2291,7 +2291,6 @@ type VRFCoordinatorV2PlusRandomWordsFulfilled struct { OutputSeed *big.Int SubID *big.Int Payment *big.Int - ExtraArgs []byte Success bool Raw types.Log } @@ -3661,7 +3660,7 @@ func (VRFCoordinatorV2PlusProvingKeyRegistered) Topic() common.Hash { } func (VRFCoordinatorV2PlusRandomWordsFulfilled) Topic() common.Hash { - return common.HexToHash("0x7bad4a5a5566568e03ff9e9fdaedf6b8a760aa3ffc0abad348cf93787f04e17e") + return common.HexToHash("0x49580fdfd9497e1ed5c1b1cec0495087ae8e3f1267470ec2fb015db32e3d6aa7") } func (VRFCoordinatorV2PlusRandomWordsRequested) Topic() common.Hash { diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index e93ffb47b65..370ec8ae28d 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -70,7 +70,7 @@ vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2Up vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b vrf_coordinator_v2_plus_v2_example: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.bin 02d0ec25e4f3d72f818e7ebc2b5f5949a94889ab0da091f0d3e7f5e4a20a0bb6 -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin c7714a63e793d5795f8c787de3a0cddeff240df8458fc8f89c96b2480ae09823 +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 9431978916acb3064a06994d273073168a4081a4ddb0d533bd4baa8bbcc6aa9a vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c diff --git a/core/services/blockhashstore/feeder_test.go b/core/services/blockhashstore/feeder_test.go index cd444d3e026..7efb7052985 100644 --- a/core/services/blockhashstore/feeder_test.go +++ b/core/services/blockhashstore/feeder_test.go @@ -920,7 +920,6 @@ func newRandomnessFulfilledLogV2Plus( nonIndexedData, err := unindexed.Pack( e.OutputSeed, e.Payment, - e.ExtraArgs, e.Success, ) require.NoError(t, err) diff --git a/core/services/vrf/v2/coordinator_v2x_interface.go b/core/services/vrf/v2/coordinator_v2x_interface.go index 95088b01292..8e2942ea927 100644 --- a/core/services/vrf/v2/coordinator_v2x_interface.go +++ b/core/services/vrf/v2/coordinator_v2x_interface.go @@ -587,7 +587,6 @@ var ( type RandomWordsFulfilled interface { RequestID() *big.Int Success() bool - NativePayment() bool SubID() *big.Int Payment() *big.Int Raw() types.Log @@ -649,14 +648,6 @@ func (rwf *v2PlusRandomWordsFulfilled) Success() bool { return rwf.event.Success } -func (rwf *v2PlusRandomWordsFulfilled) NativePayment() bool { - nativePayment, err := extraargs.FromExtraArgsV1(rwf.event.ExtraArgs) - if err != nil { - panic(err) - } - return nativePayment -} - func (rwf *v2PlusRandomWordsFulfilled) SubID() *big.Int { return rwf.event.SubID } diff --git a/core/services/vrf/v2/integration_v2_test.go b/core/services/vrf/v2/integration_v2_test.go index 24edf0ffff8..fe8c201d22b 100644 --- a/core/services/vrf/v2/integration_v2_test.go +++ b/core/services/vrf/v2/integration_v2_test.go @@ -735,7 +735,6 @@ func assertRandomWordsFulfilled( for filter.Next() { require.Equal(t, expectedSuccess, filter.Event().Success(), "fulfillment event success not correct, expected: %+v, actual: %+v", expectedSuccess, filter.Event().Success()) require.Equal(t, requestID, filter.Event().RequestID()) - require.Equal(t, nativePayment, filter.Event().NativePayment()) found = true rwfe = filter.Event() } From 9efa475fb8e94e2dc3f10bdf3cbdf67b48ce5eff Mon Sep 17 00:00:00 2001 From: Lei Date: Fri, 11 Aug 2023 13:08:36 -0700 Subject: [PATCH 154/270] update to use ocr2keepers v3 (#10169) --- .../actions/automation_ocr_helpers.go | 118 +++++++++++++----- 1 file changed, 84 insertions(+), 34 deletions(-) diff --git a/integration-tests/actions/automation_ocr_helpers.go b/integration-tests/actions/automation_ocr_helpers.go index af2ffe89a06..1a01db4d026 100644 --- a/integration-tests/actions/automation_ocr_helpers.go +++ b/integration-tests/actions/automation_ocr_helpers.go @@ -11,18 +11,22 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/lib/pq" + ocr3 "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3confighelper" "github.com/stretchr/testify/require" "gopkg.in/guregu/null.v4" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" - "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + ocr2 "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" ocr2keepers20config "github.com/smartcontractkit/ocr2keepers/pkg/v2/config" + ocr2keepers30config "github.com/smartcontractkit/ocr2keepers/pkg/v3/config" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" + "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" "github.com/smartcontractkit/chainlink/v2/core/store/models" @@ -52,40 +56,86 @@ func BuildAutoOCR2ConfigVarsWithKeyIndex( return contracts.OCRv2Config{}, err } - offC, err := json.Marshal(ocr2keepers20config.OffchainConfig{ - TargetProbability: "0.999", - TargetInRounds: 1, - PerformLockoutWindow: 3600000, // Intentionally set to be higher than in prod for testing purpose - GasLimitPerReport: 5_300_000, - GasOverheadPerUpkeep: 300_000, - SamplingJobDuration: 3000, - MinConfirmations: 0, - MaxUpkeepBatchSize: 1, - }) - if err != nil { - return contracts.OCRv2Config{}, err - } + var offC []byte + var signerOnchainPublicKeys []types.OnchainPublicKey + var transmitterAccounts []types.Account + var f uint8 + var offchainConfigVersion uint64 + var offchainConfig []byte - signerOnchainPublicKeys, transmitterAccounts, f, _, offchainConfigVersion, offchainConfig, err := confighelper.ContractSetConfigArgsForTests( - 10*time.Second, // deltaProgress time.Duration, - 15*time.Second, // deltaResend time.Duration, - 3000*time.Millisecond, // deltaRound time.Duration, - 200*time.Millisecond, // deltaGrace time.Duration, - deltaStage, // deltaStage time.Duration, - 24, // rMax uint8, - S, // s []int, - oracleIdentities, // oracles []OracleIdentityExtra, - offC, // reportingPluginConfig []byte, - 20*time.Millisecond, // maxDurationQuery time.Duration, - 20*time.Millisecond, // maxDurationObservation time.Duration, - 1200*time.Millisecond, // maxDurationReport time.Duration, - 20*time.Millisecond, // maxDurationShouldAcceptFinalizedReport time.Duration, - 20*time.Millisecond, // maxDurationShouldTransmitAcceptedReport time.Duration, - 1, // f int, - nil, // onchainConfig []byte, - ) - if err != nil { - return contracts.OCRv2Config{}, err + if registryConfig.RegistryVersion == ethereum.RegistryVersion_2_1 { + offC, err = json.Marshal(ocr2keepers30config.OffchainConfig{ + TargetProbability: "0.999", + TargetInRounds: 1, + PerformLockoutWindow: 3600000, // Intentionally set to be higher than in prod for testing purpose + GasLimitPerReport: 5_300_000, + GasOverheadPerUpkeep: 300_000, + SamplingJobDuration: 3000, + MinConfirmations: 0, + MaxUpkeepBatchSize: 1, + }) + if err != nil { + return contracts.OCRv2Config{}, err + } + + signerOnchainPublicKeys, transmitterAccounts, f, _, offchainConfigVersion, offchainConfig, err = ocr3.ContractSetConfigArgsForTests( + 10*time.Second, // deltaProgress time.Duration, + 15*time.Second, // deltaResend time.Duration, + 500*time.Millisecond, // deltaInitial time.Duration, + 3000*time.Millisecond, // deltaRound time.Duration, + 200*time.Millisecond, // deltaGrace time.Duration, + 300*time.Millisecond, // deltaCertifiedCommitRequest time.Duration + deltaStage, // deltaStage time.Duration, + 24, // rMax uint64, + S, // s []int, + oracleIdentities, // oracles []OracleIdentityExtra, + offC, // reportingPluginConfig []byte, + 20*time.Millisecond, // maxDurationQuery time.Duration, + 20*time.Millisecond, // maxDurationObservation time.Duration, // good to here + 1200*time.Millisecond, // maxDurationShouldAcceptAttestedReport time.Duration, + 20*time.Millisecond, // maxDurationShouldTransmitAcceptedReport time.Duration, + 1, // f int, + nil, // onchainConfig []byte, + ) + if err != nil { + return contracts.OCRv2Config{}, err + } + } else { + offC, err = json.Marshal(ocr2keepers20config.OffchainConfig{ + TargetProbability: "0.999", + TargetInRounds: 1, + PerformLockoutWindow: 3600000, // Intentionally set to be higher than in prod for testing purpose + GasLimitPerReport: 5_300_000, + GasOverheadPerUpkeep: 300_000, + SamplingJobDuration: 3000, + MinConfirmations: 0, + MaxUpkeepBatchSize: 1, + }) + if err != nil { + return contracts.OCRv2Config{}, err + } + + signerOnchainPublicKeys, transmitterAccounts, f, _, offchainConfigVersion, offchainConfig, err = ocr2.ContractSetConfigArgsForTests( + 10*time.Second, // deltaProgress time.Duration, + 15*time.Second, // deltaResend time.Duration, + 3000*time.Millisecond, // deltaRound time.Duration, + 200*time.Millisecond, // deltaGrace time.Duration, + deltaStage, // deltaStage time.Duration, + 24, // rMax uint8, + S, // s []int, + oracleIdentities, // oracles []OracleIdentityExtra, + offC, // reportingPluginConfig []byte, + 20*time.Millisecond, // maxDurationQuery time.Duration, + 20*time.Millisecond, // maxDurationObservation time.Duration, + 1200*time.Millisecond, // maxDurationReport time.Duration, + 20*time.Millisecond, // maxDurationShouldAcceptFinalizedReport time.Duration, + 20*time.Millisecond, // maxDurationShouldTransmitAcceptedReport time.Duration, + 1, // f int, + nil, // onchainConfig []byte, + ) + if err != nil { + return contracts.OCRv2Config{}, err + } } var signers []common.Address From 3dbc025e9b42971bd774eef2c998f9aeca1b366e Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Mon, 14 Aug 2023 12:01:14 +0300 Subject: [PATCH 155/270] Update wasp, use steps load profile (#10180) * update wasp * update wasp --- integration-tests/docker/test_env/test_env.go | 3 ++- integration-tests/go.mod | 4 ++-- integration-tests/go.sum | 8 +++---- integration-tests/load/vrfv2/README.md | 22 +++++++++++++++++ integration-tests/load/vrfv2/config.go | 16 +++++++------ integration-tests/load/vrfv2/config.toml | 14 ++++++----- integration-tests/load/vrfv2/vrfv2_test.go | 24 +++++++++++++++---- integration-tests/load/vrfv2/vu.go | 5 ++-- 8 files changed, 70 insertions(+), 26 deletions(-) create mode 100644 integration-tests/load/vrfv2/README.md diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index 6d76a7f82e0..d6cfdbe70cc 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -102,7 +102,8 @@ func (te *CLClusterTestEnv) StartClNodes(nodeConfig *chainlink.Config, count int } n := NewClNode([]string{te.Network.Name}, nodeConfig, WithNodeContainerName(nodeContainerName), - WithDbContainerName(dbContainerName)) + WithDbContainerName(dbContainerName), + ) err := n.StartContainer() if err != nil { mu.Lock() diff --git a/integration-tests/go.mod b/integration-tests/go.mod index af76c9491c3..3440cee1512 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -25,7 +25,7 @@ require ( github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 github.com/smartcontractkit/ocr2keepers v0.7.8 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 - github.com/smartcontractkit/wasp v0.2.7 + github.com/smartcontractkit/wasp v0.2.9 github.com/spf13/cobra v1.6.1 github.com/stretchr/testify v1.8.4 github.com/testcontainers/testcontainers-go v0.22.0 @@ -366,7 +366,7 @@ require ( github.com/prometheus/procfs v0.11.0 // indirect github.com/prometheus/prometheus v0.45.0 // indirect github.com/pyroscope-io/client v0.7.1 // indirect - github.com/pyroscope-io/godeltaprof v0.1.0 // indirect + github.com/pyroscope-io/godeltaprof v0.1.2 // indirect github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/rivo/uniseg v0.4.4 // indirect github.com/robfig/cron/v3 v3.0.1 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 6ef28441699..8cb832a0980 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2163,8 +2163,8 @@ github.com/prometheus/prometheus v0.43.1-0.20230327151049-211ae4f1f0a2/go.mod h1 github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= github.com/pyroscope-io/client v0.7.1 h1:yFRhj3vbgjBxehvxQmedmUWJQ4CAfCHhn+itPsuWsHw= github.com/pyroscope-io/client v0.7.1/go.mod h1:4h21iOU4pUOq0prKyDlvYRL+SCKsBc5wKiEtV+rJGqU= -github.com/pyroscope-io/godeltaprof v0.1.0 h1:UBqtjt0yZi4jTxqZmLAs34XG6ycS3vUTlhEUSq4NHLE= -github.com/pyroscope-io/godeltaprof v0.1.0/go.mod h1:psMITXp90+8pFenXkKIpNhrfmI9saQnPbba27VIaiQE= +github.com/pyroscope-io/godeltaprof v0.1.2 h1:MdlEmYELd5w+lvIzmZvXGNMVzW2Qc9jDMuJaPOR75g4= +github.com/pyroscope-io/godeltaprof v0.1.2/go.mod h1:psMITXp90+8pFenXkKIpNhrfmI9saQnPbba27VIaiQE= github.com/rakyll/statik v0.1.7 h1:OF3QCZUuyPxuGEP7B4ypUa7sB/iHtqOTDYZXGM8KOdQ= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 h1:N/ElC8H3+5XpJzTSTfLsJV/mx9Q9g7kxmchpfZyxgzM= github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqnVzQkZxMG4s8nGwiZ5l3QUCyqpo9Y+/ZMZ9VjZe4= @@ -2265,8 +2265,8 @@ github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300- github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= -github.com/smartcontractkit/wasp v0.2.7 h1:9SZ1grPvoNDpxCcQgQi917ifXrjt5JhV/J978HkD0d4= -github.com/smartcontractkit/wasp v0.2.7/go.mod h1:gS2oenc6VEGfewgeqDpVFOSrCZIZX10rVl1PAo+vsxc= +github.com/smartcontractkit/wasp v0.2.9 h1:gIKuhRjdqQCj61OrdxqKZ2vAuXxs+PlibygYkFlP4l8= +github.com/smartcontractkit/wasp v0.2.9/go.mod h1:skquNdMbKxIrHi5O8Kyukf66AaaXuEpEEaSTxfHbhak= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= diff --git a/integration-tests/load/vrfv2/README.md b/integration-tests/load/vrfv2/README.md new file mode 100644 index 00000000000..4b00d4ad0d2 --- /dev/null +++ b/integration-tests/load/vrfv2/README.md @@ -0,0 +1,22 @@ +### VRFv2 Load tests + +## Usage +``` +export LOKI_TOKEN=... +export LOKI_URL=... + +go test -v -run TestVRFV2Load/vrfv2_soak_test +``` + +### Dashboards + +Deploying dashboard: +``` +export GRAFANA_URL=... +export GRAFANA_TOKEN=... +export DATA_SOURCE_NAME=grafanacloud-logs +export DASHBOARD_FOLDER=LoadTests +export DASHBOARD_NAME=${JobTypeName, for example WaspVRFv2} + +go run dashboard.go +``` \ No newline at end of file diff --git a/integration-tests/load/vrfv2/config.go b/integration-tests/load/vrfv2/config.go index 53188f3a0e8..ee5f3ff80dd 100644 --- a/integration-tests/load/vrfv2/config.go +++ b/integration-tests/load/vrfv2/config.go @@ -45,16 +45,18 @@ type SoakVolume struct { } type Load struct { - RPSFrom int64 `toml:"rps_from"` - RPSTo int64 `toml:"rps_to"` - Duration *models.Duration `toml:"duration"` + RPSFrom int64 `toml:"rps_from"` + RPSIncrease int64 `toml:"rps_increase"` + RPSSteps int `toml:"rps_steps"` + Duration *models.Duration `toml:"duration"` } type LoadVolume struct { - ProductsFrom int64 `toml:"products_from"` - ProductsTo int64 `toml:"products_to"` - Pace *models.Duration `toml:"pace"` - Duration *models.Duration `toml:"duration"` + ProductsFrom int64 `toml:"products_from"` + ProductsIncrease int64 `toml:"products_increase"` + ProductsSteps int `toml:"products_steps"` + Pace *models.Duration `toml:"pace"` + Duration *models.Duration `toml:"duration"` } func ReadConfig() (*PerformanceConfig, error) { diff --git a/integration-tests/load/vrfv2/config.toml b/integration-tests/load/vrfv2/config.toml index 51a0e95d35a..8917db88cc2 100644 --- a/integration-tests/load/vrfv2/config.toml +++ b/integration-tests/load/vrfv2/config.toml @@ -1,24 +1,26 @@ # testing one product (jobs + contracts) by varying RPS [Soak] rps = 1 -duration = "10m" +duration = "3m" [Load] rps_from = 1 -rps_to = 5 -duration = "10m" +rps_increase = 1 +rps_steps = 10 +duration = "3m" # testing multiple products (jobs + contracts) by varying instances, deploying more of the same type with stable RPS for each product [SoakVolume] products = 5 pace = "1s" -duration = "10m" +duration = "3m" [LoadVolume] products_from = 1 -products_to = 5 +products_increase = 1 +products_steps = 10 pace = "1s" -duration = "10m" +duration = "3m" [Common] node_funds = 10 diff --git a/integration-tests/load/vrfv2/vrfv2_test.go b/integration-tests/load/vrfv2/vrfv2_test.go index 1a79fce9c39..e414efb067f 100644 --- a/integration-tests/load/vrfv2/vrfv2_test.go +++ b/integration-tests/load/vrfv2/vrfv2_test.go @@ -40,7 +40,10 @@ func TestVRFV2Load(t *testing.T) { // is our "job" stable at all, no memory leaks, no flaking performance under some RPS? t.Run("vrfv2 soak test", func(t *testing.T) { - singleFeedConfig.Schedule = wasp.Plain(cfg.Soak.RPS, cfg.Soak.Duration.Duration()) + singleFeedConfig.Schedule = wasp.Plain( + cfg.Soak.RPS, + cfg.Soak.Duration.Duration(), + ) _, err := wasp.NewProfile(). Add(wasp.NewGenerator(singleFeedConfig)). Run(true) @@ -49,7 +52,12 @@ func TestVRFV2Load(t *testing.T) { // what are the limits for one "job", figuring out the max/optimal performance params by increasing RPS and varying configuration t.Run("vrfv2 load test", func(t *testing.T) { - singleFeedConfig.Schedule = wasp.Line(cfg.Load.RPSFrom, cfg.Load.RPSTo, cfg.Load.Duration.Duration()) + singleFeedConfig.Schedule = wasp.Steps( + cfg.Load.RPSFrom, + cfg.Load.RPSIncrease, + cfg.Load.RPSSteps, + cfg.Load.Duration.Duration(), + ) _, err = wasp.NewProfile(). Add(wasp.NewGenerator(singleFeedConfig)). Run(true) @@ -58,7 +66,10 @@ func TestVRFV2Load(t *testing.T) { // how many "jobs" of the same type we can run at once at a stable load with optimal configuration? t.Run("vrfv2 volume soak test", func(t *testing.T) { - multiFeedConfig.Schedule = wasp.Plain(cfg.SoakVolume.Products, cfg.SoakVolume.Duration.Duration()) + multiFeedConfig.Schedule = wasp.Plain( + cfg.SoakVolume.Products, + cfg.SoakVolume.Duration.Duration(), + ) _, err = wasp.NewProfile(). Add(wasp.NewGenerator(multiFeedConfig)). Run(true) @@ -67,7 +78,12 @@ func TestVRFV2Load(t *testing.T) { // what are the limits if we add more and more "jobs/products" of the same type, each "job" have a stable RPS we vary only amount of jobs t.Run("vrfv2 volume load test", func(t *testing.T) { - multiFeedConfig.Schedule = wasp.Line(cfg.LoadVolume.ProductsFrom, cfg.LoadVolume.ProductsTo, cfg.LoadVolume.Duration.Duration()) + multiFeedConfig.Schedule = wasp.Steps( + cfg.LoadVolume.ProductsFrom, + cfg.LoadVolume.ProductsIncrease, + cfg.LoadVolume.ProductsSteps, + cfg.LoadVolume.Duration.Duration(), + ) _, err = wasp.NewProfile(). Add(wasp.NewGenerator(multiFeedConfig)). Run(true) diff --git a/integration-tests/load/vrfv2/vu.go b/integration-tests/load/vrfv2/vu.go index d8e0702dd50..df05a9168e2 100644 --- a/integration-tests/load/vrfv2/vu.go +++ b/integration-tests/load/vrfv2/vu.go @@ -67,6 +67,7 @@ func (m *JobVolumeVU) Teardown(_ *wasp.Generator) error { func (m *JobVolumeVU) Call(l *wasp.Generator) { time.Sleep(m.pace) + tn := time.Now() err := m.contracts.LoadTestConsumer.RequestRandomness( m.keyHash, vrfConst.SubID, @@ -76,10 +77,10 @@ func (m *JobVolumeVU) Call(l *wasp.Generator) { vrfConst.RandomnessRequestCountPerRequest, ) if err != nil { - l.ResponsesChan <- &wasp.CallResult{Error: err.Error(), Failed: true} + l.ResponsesChan <- &wasp.CallResult{Duration: time.Since(tn), Error: err.Error(), Failed: true} return } - l.ResponsesChan <- &wasp.CallResult{} + l.ResponsesChan <- &wasp.CallResult{Duration: time.Since(tn)} } func (m *JobVolumeVU) Stop(_ *wasp.Generator) { From 27621ae6d7c7054e682b75e9dd080ba4839532de Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Mon, 14 Aug 2023 13:40:23 +0300 Subject: [PATCH 156/270] Upkeep states performed (#10183) * added performed events scanner scanning for work ids in DedupKeyAdded events * refactor upkeep states store * tests * lint * lint in logprovider test * comments and fix scanner close * fix scanner tests * test errors --- .../evm21/logprovider/integration_test.go | 14 +- .../ocr2keeper/evm21/upkeep_state_store.go | 92 ------- .../evm21/upkeep_state_store_test.go | 137 ----------- .../ocr2keeper/evm21/upkeepstate/scanner.go | 86 +++++++ .../evm21/upkeepstate/scanner_test.go | 129 ++++++++++ .../ocr2keeper/evm21/upkeepstate/store.go | 225 ++++++++++++++++++ .../evm21/upkeepstate/store_test.go | 203 ++++++++++++++++ 7 files changed, 649 insertions(+), 237 deletions(-) delete mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go delete mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index 5120deee9ba..a8132c35465 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -116,8 +116,6 @@ func TestIntegration_LogEventProvider(t *testing.T) { } func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { - type deferableFunc func() - setupTest := func( t *testing.T, opts *logprovider.LogEventProviderOptions, @@ -318,7 +316,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { } func TestIntegration_LogEventProvider_Backfill(t *testing.T) { - ctx, cancel := context.WithTimeout(testutils.Context(t), time.Second*30) + ctx, cancel := context.WithTimeout(testutils.Context(t), time.Second*60) defer cancel() backend, stopMining, accounts := setupBackend(t) @@ -350,8 +348,8 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { b, err := ethClient.BlockByHash(ctx, backend.Commit()) latestBlock := b.Number().Int64() for { - latestPolled, err := lp.LatestBlock(pg.WithParentCtx(ctx)) - require.NoError(t, err) + latestPolled, lberr := lp.LatestBlock(pg.WithParentCtx(ctx)) + require.NoError(t, lberr) if latestPolled >= latestBlock { break } @@ -360,8 +358,8 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { // starting the log provider should backfill logs go func() { - if err := logProvider.Start(ctx); err != nil { - t.Logf("error starting log provider: %s", err) + if startErr := logProvider.Start(ctx); err != nil { + t.Logf("error starting log provider: %s", startErr) t.Fail() } }() @@ -370,7 +368,7 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { t.Log("waiting for log provider to do some backfilling") for ctx.Err() == nil { currentPartition := logProvider.CurrentPartitionIdx() - if currentPartition >= 2 { + if currentPartition > 2 { // make sure we went over all items break } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go deleted file mode 100644 index 4eba6cd1de4..00000000000 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store.go +++ /dev/null @@ -1,92 +0,0 @@ -package evm - -import ( - "context" - "sync" - - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" - - "github.com/smartcontractkit/chainlink/v2/core/logger" -) - -type upkeepState struct { - upkeepID ocr2keepers.UpkeepIdentifier - workID string - state ocr2keepers.UpkeepState - block uint64 -} - -type UpkeepStateReader interface { - SelectByWorkIDs(workIDs ...string) (map[string]ocr2keepers.UpkeepState, error) -} - -var ( - _ ocr2keepers.UpkeepStateUpdater = &UpkeepStateStore{} - _ UpkeepStateReader = &UpkeepStateStore{} -) - -type UpkeepStateStore struct { - mu sync.RWMutex - workIDIdx map[string]*upkeepState - lggr logger.Logger -} - -// NewUpkeepStateStore creates a new state store -func NewUpkeepStateStore(lggr logger.Logger) *UpkeepStateStore { - return &UpkeepStateStore{ - workIDIdx: map[string]*upkeepState{}, - lggr: lggr.Named("UpkeepStateStore"), - } -} - -// SelectByWorkIDs returns all saved state values for the provided ids -func (u *UpkeepStateStore) SelectByWorkIDs(workIDs ...string) (map[string]ocr2keepers.UpkeepState, error) { - u.mu.RLock() - defer u.mu.RUnlock() - - states := make(map[string]ocr2keepers.UpkeepState) - - for _, workID := range workIDs { - if state, ok := u.workIDIdx[workID]; ok { - states[workID] = state.state - } - } - - return states, nil -} - -// SetUpkeepState applies the provided state to the data store for the provided -// check result. If an item already exists in the data store, the state and -// block are updated. Otherwise, the new state is added. -func (u *UpkeepStateStore) SetUpkeepState(_ context.Context, result ocr2keepers.CheckResult, _ ocr2keepers.UpkeepState) error { - // only if the result is ineligible is the upkeep state updated - if !result.Eligible { - if existing, ok := u.workIDIdx[result.WorkID]; ok { - u.mu.Lock() - - existing.state = ocr2keepers.Ineligible - existing.block = uint64(result.Trigger.BlockNumber) - - u.mu.Unlock() - - u.lggr.Infof("upkeep %s is overridden, workID is %s, block is %d", existing.upkeepID, existing.workID, existing.block) - } else { - storedState := &upkeepState{ - upkeepID: result.UpkeepID, - workID: result.WorkID, - state: ocr2keepers.Ineligible, - block: uint64(result.Trigger.BlockNumber), - } - - u.mu.Lock() - - u.workIDIdx[result.WorkID] = storedState - - u.mu.Unlock() - - u.lggr.Infof("added new state with upkeep %s payload ID %s block %d", storedState.upkeepID, storedState.workID, storedState.block) - } - } - - return nil -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go deleted file mode 100644 index 12a41d81254..00000000000 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_state_store_test.go +++ /dev/null @@ -1,137 +0,0 @@ -package evm - -import ( - "context" - "math/big" - "testing" - - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - - "github.com/smartcontractkit/chainlink/v2/core/logger" -) - -func TestUpkeepStateStore_SelectByWorkIDs(t *testing.T) { - workIDs := []string{"a", "b", "c", "d"} - inserts := []ocr2keepers.CheckResult{ - { - UpkeepID: createUpkeepIDForTest(1), - WorkID: workIDs[0], - Eligible: false, - Trigger: ocr2keepers.Trigger{ - BlockNumber: ocr2keepers.BlockNumber(1), - }, - }, - { - UpkeepID: createUpkeepIDForTest(2), - WorkID: workIDs[1], - Eligible: false, - Trigger: ocr2keepers.Trigger{ - BlockNumber: ocr2keepers.BlockNumber(2), - }, - }, - { - UpkeepID: createUpkeepIDForTest(3), - WorkID: workIDs[2], - Eligible: false, - Trigger: ocr2keepers.Trigger{ - BlockNumber: ocr2keepers.BlockNumber(3), - }, - }, - } - - expected := map[string]ocr2keepers.UpkeepState{ - workIDs[0]: ocr2keepers.Ineligible, - workIDs[1]: ocr2keepers.Ineligible, - workIDs[2]: ocr2keepers.Ineligible, - } - - store := NewUpkeepStateStore(logger.TestLogger(t)) - - for _, insert := range inserts { - assert.NoError(t, store.SetUpkeepState(context.Background(), insert, ocr2keepers.Performed), "storing states should not produce an error") - } - - states, err := store.SelectByWorkIDs(workIDs...) - assert.NoError(t, err, "no error expected from selecting states") - - assert.Equal(t, expected, states, "upkeep state values should match expected") -} - -func TestUpkeepStateStore_SetUpkeepState(t *testing.T) { - t.Run("should not save state for upkeep eligible", func(t *testing.T) { - uid := &ocr2keepers.UpkeepIdentifier{} - _ = uid.FromBigInt(big.NewInt(1)) - - store := NewUpkeepStateStore(logger.TestLogger(t)) - - assert.NoError(t, store.SetUpkeepState(context.Background(), ocr2keepers.CheckResult{ - UpkeepID: *uid, - WorkID: "test", - Eligible: true, - }, ocr2keepers.Ineligible), "setting state should not return an error") - - assert.Len(t, store.workIDIdx, 0, "should not add to upkeep states") - }) - - t.Run("should insert new state when ineligible and state does not exist in store and ignore state input", func(t *testing.T) { - uid := &ocr2keepers.UpkeepIdentifier{} - _ = uid.FromBigInt(big.NewInt(1)) - - store := NewUpkeepStateStore(logger.TestLogger(t)) - input := ocr2keepers.CheckResult{ - UpkeepID: *uid, - WorkID: "test", - Trigger: ocr2keepers.Trigger{ - BlockNumber: ocr2keepers.BlockNumber(1), - }, - Eligible: false, - } - - assert.NoError(t, store.SetUpkeepState(context.Background(), input, ocr2keepers.Performed)) - - require.Len(t, store.workIDIdx, 1, "should add to upkeep states") - - assert.Equal(t, ocr2keepers.Ineligible, store.workIDIdx["test"].state, "stored state should be ineligible") - assert.Equal(t, input.UpkeepID, store.workIDIdx["test"].upkeepID, "stored upkeepID should match input") - assert.Equal(t, input.WorkID, store.workIDIdx["test"].workID, "stored workID should match input") - assert.Equal(t, uint64(input.Trigger.BlockNumber), store.workIDIdx["test"].block, "stored block should match input") - }) - - // when eligible and state exists in store, override state, ignore state input - t.Run("should override block when ineligible and state exists in store and ignore state input", func(t *testing.T) { - store := NewUpkeepStateStore(logger.TestLogger(t)) - input := ocr2keepers.CheckResult{ - UpkeepID: createUpkeepIDForTest(1), - WorkID: "test", - Trigger: ocr2keepers.Trigger{ - BlockNumber: ocr2keepers.BlockNumber(1), - }, - Eligible: false, - } - - assert.NoError(t, store.SetUpkeepState(context.Background(), input, ocr2keepers.Performed), "setting state should not return an error") - - require.Len(t, store.workIDIdx, 1, "should add to upkeep states") - - // update the block number for the input to indicate a state data change - input.Trigger.BlockNumber = ocr2keepers.BlockNumber(5) - - assert.NoError(t, store.SetUpkeepState(context.Background(), input, ocr2keepers.Performed), "setting state should not return an error") - - require.Len(t, store.workIDIdx, 1, "should update existing upkeep state") - - assert.Equal(t, ocr2keepers.Ineligible, store.workIDIdx["test"].state, "stored state should be ineligible") - assert.Equal(t, input.UpkeepID, store.workIDIdx["test"].upkeepID, "stored upkeepID should match input") - assert.Equal(t, input.WorkID, store.workIDIdx["test"].workID, "stored workID should match input") - assert.Equal(t, uint64(input.Trigger.BlockNumber), store.workIDIdx["test"].block, "stored block should match input") - }) -} - -func createUpkeepIDForTest(v int64) ocr2keepers.UpkeepIdentifier { - uid := &ocr2keepers.UpkeepIdentifier{} - _ = uid.FromBigInt(big.NewInt(v)) - - return *uid -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go new file mode 100644 index 00000000000..7cc029a6d84 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go @@ -0,0 +1,86 @@ +package upkeepstate + +import ( + "context" + "fmt" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" +) + +type PerformedLogsScanner interface { + WorkIDsInRange(ctx context.Context, start, end int64) ([]string, error) +} + +type performedEventsScanner struct { + lggr logger.Logger + poller logpoller.LogPoller + registryAddress common.Address +} + +func NewPerformedEventsScanner( + lggr logger.Logger, + poller logpoller.LogPoller, + registryAddress common.Address, +) *performedEventsScanner { + return &performedEventsScanner{ + lggr: lggr, + poller: poller, + registryAddress: registryAddress, + } +} + +func (s *performedEventsScanner) Start(_ context.Context) error { + return s.poller.RegisterFilter(logpoller.Filter{ + Name: dedupFilterName(s.registryAddress), + EventSigs: []common.Hash{ + // listening to dedup key added event + iregistry21.IKeeperRegistryMasterDedupKeyAdded{}.Topic(), + }, + Addresses: []common.Address{s.registryAddress}, + }) +} + +// implements io.Closer, does nothing upon close +func (s *performedEventsScanner) Close() error { + return nil +} + +func (s *performedEventsScanner) WorkIDsInRange(ctx context.Context, start, end int64) ([]string, error) { + logs, err := s.poller.LogsWithSigs( + start, + end, + []common.Hash{ + iregistry21.IKeeperRegistryMasterDedupKeyAdded{}.Topic(), + }, + s.registryAddress, + pg.WithParentCtx(ctx), + ) + if err != nil { + return nil, fmt.Errorf("error fetching logs: %w", err) + } + + return s.logsToWorkIDs(logs), nil +} + +func (s *performedEventsScanner) logsToWorkIDs(logs []logpoller.Log) []string { + workIDs := make([]string, 0) + for _, log := range logs { + topics := log.GetTopics() + if len(topics) < 2 { + s.lggr.Debugw("unexpected log topics", "topics", topics) + continue + } + workIDs = append(workIDs, hexutil.Encode(topics[1].Bytes())) + } + return workIDs +} + +func dedupFilterName(addr common.Address) string { + return logpoller.FilterName("KeepersRegistry UpkeepStates Deduped", addr) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go new file mode 100644 index 00000000000..a8c8e8f6010 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go @@ -0,0 +1,129 @@ +package upkeepstate + +import ( + "fmt" + "testing" + + "github.com/ethereum/go-ethereum/common" + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" + iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" +) + +func TestPerformedEventsScanner(t *testing.T) { + ctx := testutils.Context(t) + registryAddr := common.HexToAddress("0x12345") + lggr := logger.TestLogger(t) + + tests := []struct { + name string + pollerResults []logpoller.Log + scannerResults []string + pollerErr error + errored bool + }{ + { + "no logs", + []logpoller.Log{}, + []string{}, + nil, + false, + }, + { + "log poller error", + []logpoller.Log{}, + []string{}, + fmt.Errorf("test-error"), + true, + }, + { + "one result", + []logpoller.Log{ + { + BlockNumber: 1, + Address: registryAddr, + Topics: convertTopics([]common.Hash{ + iregistry21.IKeeperRegistryMasterDedupKeyAdded{}.Topic(), + common.HexToHash("0x1111"), + }), + }, + }, + []string{common.HexToHash("0x1111").Hex()}, + nil, + false, + }, + { + "missing workID", + []logpoller.Log{ + { + BlockNumber: 1, + Address: registryAddr, + Topics: convertTopics([]common.Hash{ + iregistry21.IKeeperRegistryMasterDedupKeyAdded{}.Topic(), + }), + }, + }, + []string{}, + nil, + false, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + mp := new(mocks.LogPoller) + mp.On("RegisterFilter", mock.Anything).Return(nil) + mp.On("UnregisterFilter", mock.Anything, mock.Anything).Return(nil) + scanner := NewPerformedEventsScanner(lggr, mp, registryAddr) + + go func() { + _ = scanner.Start(ctx) + }() + defer func() { + _ = scanner.Close() + }() + + mp.On("LogsWithSigs", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.pollerResults, tc.pollerErr) + + results, err := scanner.WorkIDsInRange(ctx, 0, 100) + if tc.errored { + require.Error(t, err) + return + } + require.NoError(t, err) + require.Equal(t, len(tc.scannerResults), len(results)) + + for _, result := range results { + require.Contains(t, tc.scannerResults, result) + } + }) + } +} + +func TestPerformedEventsScanner_LogPollerErrors(t *testing.T) { + ctx := testutils.Context(t) + registryAddr := common.HexToAddress("0x12345") + lggr := logger.TestLogger(t) + + mp := new(mocks.LogPoller) + scanner := NewPerformedEventsScanner(lggr, mp, registryAddr) + + mp.On("LogsWithSigs", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(nil, fmt.Errorf("test error")) + + workIDs, err := scanner.WorkIDsInRange(ctx, 0, 100) + require.Error(t, err) + require.Nil(t, workIDs) +} + +func convertTopics(topics []common.Hash) [][]byte { + var topicsForDB [][]byte + for _, t := range topics { + topicsForDB = append(topicsForDB, t.Bytes()) + } + return topicsForDB +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go new file mode 100644 index 00000000000..4bc547750c7 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go @@ -0,0 +1,225 @@ +package upkeepstate + +import ( + "context" + "sync" + "time" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/logger" +) + +var ( + // CacheExpiration is the amount of time that we keep a record in the cache. + CacheExpiration = 24 * time.Hour + // GCInterval is the amount of time between cache cleanups. + GCInterval = 2 * time.Hour + // TODO: use sentinel value from ocr2keepers + StateUnknown = ocr2keepers.UpkeepState(100) +) + +// UpkeepStateReader is the interface for reading the current state of upkeeps. +type UpkeepStateReader interface { + SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) +} + +// UpkeepStateStore is the interface for managing upkeeps final state in a local store. +type UpkeepStateStore interface { + ocr2keepers.UpkeepStateUpdater + UpkeepStateReader +} + +var ( + _ UpkeepStateStore = &upkeepStateStore{} +) + +// upkeepStateRecord is a record that we save in a local cache. +type upkeepStateRecord struct { + workID string + state ocr2keepers.UpkeepState + block uint64 + + addedAt time.Time +} + +// upkeepStateStore implements UpkeepStateStore. +// It stores the state of ineligible upkeeps in a local, in-memory cache (TODO: save in DB). +// In addition, performed events are fetched by the scanner on demand. +type upkeepStateStore struct { + lggr logger.Logger + + cancel context.CancelFunc + + mu sync.RWMutex + cache map[string]*upkeepStateRecord + + scanner PerformedLogsScanner +} + +// NewUpkeepStateStore creates a new state store +func NewUpkeepStateStore(lggr logger.Logger, scanner PerformedLogsScanner) *upkeepStateStore { + return &upkeepStateStore{ + lggr: lggr.Named("upkeepStateStore"), + cache: map[string]*upkeepStateRecord{}, + scanner: scanner, + } +} + +// Start starts the upkeep state store. +// it does background cleanup of the cache. +func (u *upkeepStateStore) Start(pctx context.Context) error { + ctx, cancel := context.WithCancel(pctx) + defer cancel() + + u.mu.Lock() + u.cancel = cancel + u.mu.Unlock() + + u.lggr.Debug("Starting upkeep state store") + + ticker := time.NewTicker(GCInterval) + defer ticker.Stop() + + for { + select { + case <-ticker.C: + u.cleanup() + case <-ctx.Done(): + return nil + } + } +} + +func (u *upkeepStateStore) Close() error { + u.mu.Lock() + cancel := u.cancel + u.mu.Unlock() + + if cancel != nil { + cancel() + } + + return nil +} + +// SelectByWorkIDs returns the current state of the upkeep for the provided ids. +// If an id is not found, the state is returned as StateUnknown. +// We first check the cache, and if any ids are missing, we fetch them from the scanner. +// TODO: fetch from DB +func (u *upkeepStateStore) SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + states, ok := u.selectFromCache(workIDs...) + if ok { + // all ids were found in the cache + return states, nil + } + if err := u.fetchPerformed(ctx, start, end); err != nil { + return nil, err + } + states, _ = u.selectFromCache(workIDs...) + + return states, nil +} + +// SetUpkeepState updates the state of the upkeep. +// Currently we only store the state if the upkeep is ineligible. +// Performed events will be fetched on demand. +func (u *upkeepStateStore) SetUpkeepState(_ context.Context, result ocr2keepers.CheckResult, _ ocr2keepers.UpkeepState) error { + if result.Eligible { + return nil + } + + u.upsertStateRecord(result.WorkID, ocr2keepers.Ineligible, uint64(result.Trigger.BlockNumber)) + + return nil +} + +// upsertStateRecord inserts or updates a record for the provided +// check result. If an item already exists in the data store, the state and +// block are updated. +// TODO: persist to DB +func (u *upkeepStateStore) upsertStateRecord(workID string, s ocr2keepers.UpkeepState, b uint64) { + u.mu.Lock() + defer u.mu.Unlock() + + record, ok := u.cache[workID] + if !ok { + record = &upkeepStateRecord{ + workID: workID, + addedAt: time.Now(), + } + } + record.state = s + record.block = b + + u.cache[workID] = record +} + +// fetchPerformed fetches all performed logs from the scanner to populate the cache. +func (u *upkeepStateStore) fetchPerformed(ctx context.Context, start, end int64, workIDs ...string) error { + performed, err := u.scanner.WorkIDsInRange(ctx, start, end) + if err != nil { + return err + } + + u.mu.Lock() + defer u.mu.Unlock() + + for _, workID := range performed { + if _, ok := u.cache[workID]; !ok { + s := &upkeepStateRecord{ + workID: workID, + state: ocr2keepers.Performed, + addedAt: time.Now(), + block: uint64(end), // TODO: use block number from log + } + u.cache[workID] = s + } + } + + return nil +} + +// selectFromCache returns all saved state values for the provided ids, +// returning stateNotFound for any ids that are not found. +// the second return value is true if all ids were found in the cache. +func (u *upkeepStateStore) selectFromCache(workIDs ...string) ([]ocr2keepers.UpkeepState, bool) { + u.mu.RLock() + defer u.mu.RUnlock() + + var hasMisses bool + states := make([]ocr2keepers.UpkeepState, len(workIDs)) + for i, workID := range workIDs { + if state, ok := u.cache[workID]; ok { + states[i] = state.state + } else { + hasMisses = true + states[i] = StateUnknown + } + } + + return states, !hasMisses +} + +// cleanup removes any records that are older than the TTL from both cache and DB. +func (u *upkeepStateStore) cleanup() { + u.cleanCache() + u.cleanDB() +} + +// cleanDB cleans up records in the DB that are older than the TTL. +func (u *upkeepStateStore) cleanDB() { + // TODO: implement +} + +// cleanupCache removes any records from the cache that are older than the TTL. +func (u *upkeepStateStore) cleanCache() { + u.mu.Lock() + defer u.mu.Unlock() + + for id, state := range u.cache { + if time.Since(state.addedAt) > CacheExpiration { + delete(u.cache, id) + } + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go new file mode 100644 index 00000000000..368dca8af9f --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go @@ -0,0 +1,203 @@ +package upkeepstate + +import ( + "context" + "fmt" + "math/big" + "sync" + "testing" + "time" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" +) + +func TestUpkeepStateStore(t *testing.T) { + tests := []struct { + name string + inserts []ocr2keepers.CheckResult + workIDsSelect []string + workIDsFromScanner []string + errScanner error + expected []ocr2keepers.UpkeepState + errored bool + }{ + { + name: "empty store", + }, + { + name: "save only ineligible states", + inserts: []ocr2keepers.CheckResult{ + { + UpkeepID: createUpkeepIDForTest(1), + WorkID: "0x1", + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), + }, + }, + { + UpkeepID: createUpkeepIDForTest(2), + WorkID: "ox2", + Eligible: true, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(2), + }, + }, + }, + workIDsSelect: []string{"0x1", "0x2"}, + expected: []ocr2keepers.UpkeepState{ + ocr2keepers.Ineligible, + StateUnknown, + }, + }, + { + name: "fetch results from scanner", + inserts: []ocr2keepers.CheckResult{ + { + UpkeepID: createUpkeepIDForTest(1), + WorkID: "0x1", + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), + }, + }, + }, + workIDsSelect: []string{"0x1", "0x2"}, + workIDsFromScanner: []string{"0x2", "0x222"}, + expected: []ocr2keepers.UpkeepState{ + ocr2keepers.Ineligible, + ocr2keepers.Performed, + }, + }, + { + name: "unknown states", + inserts: []ocr2keepers.CheckResult{ + { + UpkeepID: createUpkeepIDForTest(1), + WorkID: "0x1", + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), + }, + }, + }, + workIDsSelect: []string{"0x2"}, + workIDsFromScanner: []string{}, + expected: []ocr2keepers.UpkeepState{ + StateUnknown, + }, + }, + { + name: "scanner error", + inserts: []ocr2keepers.CheckResult{ + { + UpkeepID: createUpkeepIDForTest(1), + WorkID: "0x1", + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), + }, + }, + }, + workIDsSelect: []string{"0x1", "0x2"}, + workIDsFromScanner: []string{"0x2", "0x222"}, + errScanner: fmt.Errorf("test error"), + errored: true, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + ctx := testutils.Context(t) + + scanner := &mockScanner{} + scanner.addWorkID(tc.workIDsFromScanner...) + scanner.setErr(tc.errScanner) + store := NewUpkeepStateStore(logger.TestLogger(t), scanner) + + for _, insert := range tc.inserts { + assert.NoError(t, store.SetUpkeepState(ctx, insert, ocr2keepers.Performed)) + } + + states, err := store.SelectByWorkIDsInRange(ctx, 1, 100, tc.workIDsSelect...) + if tc.errored { + assert.Error(t, err) + return + } + assert.NoError(t, err) + + assert.Equal(t, len(tc.expected), len(states)) + for i, state := range states { + assert.Equal(t, tc.expected[i], state) + } + }) + } +} + +func TestUpkeepStateStore_Upsert(t *testing.T) { + ctx := testutils.Context(t) + store := NewUpkeepStateStore(logger.TestLogger(t), &mockScanner{}) + + res := ocr2keepers.CheckResult{ + UpkeepID: createUpkeepIDForTest(1), + WorkID: "0x1", + Eligible: false, + Trigger: ocr2keepers.Trigger{ + BlockNumber: ocr2keepers.BlockNumber(1), + }, + } + require.NoError(t, store.SetUpkeepState(ctx, res, ocr2keepers.Performed)) + <-time.After(10 * time.Millisecond) + res.Trigger.BlockNumber = ocr2keepers.BlockNumber(2) + now := time.Now() + require.NoError(t, store.SetUpkeepState(ctx, res, ocr2keepers.Performed)) + + store.mu.Lock() + addedAt := store.cache["0x1"].addedAt + block := store.cache["0x1"].block + store.mu.Unlock() + + require.True(t, now.After(addedAt)) + require.Equal(t, uint64(2), block) +} + +func createUpkeepIDForTest(v int64) ocr2keepers.UpkeepIdentifier { + uid := &ocr2keepers.UpkeepIdentifier{} + _ = uid.FromBigInt(big.NewInt(v)) + + return *uid +} + +type mockScanner struct { + lock sync.Mutex + workIDs []string + err error +} + +func (s *mockScanner) addWorkID(workIDs ...string) { + s.lock.Lock() + defer s.lock.Unlock() + + s.workIDs = append(s.workIDs, workIDs...) +} + +func (s *mockScanner) setErr(err error) { + s.lock.Lock() + defer s.lock.Unlock() + + s.err = err +} + +func (s *mockScanner) WorkIDsInRange(ctx context.Context, start, end int64) ([]string, error) { + s.lock.Lock() + defer s.lock.Unlock() + + res := s.workIDs[:] + s.workIDs = nil + return res, s.err +} From a1a9954a01952ed80bf15ceab71d0ee7148db771 Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Mon, 14 Aug 2023 14:00:06 +0200 Subject: [PATCH 157/270] bump solc-select 0.2.0 -> 1.0.4 (#10184) * bump solc-select 0.2.0 -> 1.0.4 * lock pycryptodome && packaging with hash * update location of solc files --- contracts/scripts/requirements.txt | 4 +++- tools/ci/check_solc_hashes | 8 ++++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/contracts/scripts/requirements.txt b/contracts/scripts/requirements.txt index 38d247c9775..5a6256f6fc9 100644 --- a/contracts/scripts/requirements.txt +++ b/contracts/scripts/requirements.txt @@ -1 +1,3 @@ -solc-select==0.2.0 --hash=sha256:faa2fb5d43b77b6dc48ce73cb863b27631c477d0a350403294ff186c51bd744e +solc-select==1.0.4 --hash=sha256:db7b9de009af6de3a5416b80bbe5b6d636bf314703c016319b8c1231e248a6c7 +pycryptodome==3.18.0 --hash=sha256:c9adee653fc882d98956e33ca2c1fb582e23a8af7ac82fee75bd6113c55a0413 +packaging==23.1 --hash=sha256:7c6658d258d7971c5eb0d9b69fa9265879ec9a9158031206d47800ae2213 \ No newline at end of file diff --git a/tools/ci/check_solc_hashes b/tools/ci/check_solc_hashes index 3e1acd6b718..0fe7d091f13 100755 --- a/tools/ci/check_solc_hashes +++ b/tools/ci/check_solc_hashes @@ -6,10 +6,10 @@ set -e -SOLC_6_6_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.6.6" -SOLC_7_6_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.7.6" -SOLC_8_6_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.8.6" -SOLC_8_15_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.8.15" +SOLC_6_6_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.6.6/solc-0.6.6" +SOLC_7_6_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.7.6/solc-0.7.6" +SOLC_8_6_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.8.6/solc-0.8.6" +SOLC_8_15_LOCAL_PATH="$HOME/.solc-select/artifacts/solc-0.8.15/solc-0.8.15" SOLC_6_6_LOCAL_SHA=`sha256sum -b $SOLC_6_6_LOCAL_PATH | cut -d " " -f1` SOLC_6_6_EXPECTED_SHA="5d8cd4e0cc02e9946497db68c06d56326a78ff95a21c9265cfedb819a10a539d" From b541373b6570f51c76a1f58a6729c92e2226b631 Mon Sep 17 00:00:00 2001 From: Michael Fletcher <36506122+Fletch153@users.noreply.github.com> Date: Mon, 14 Aug 2023 13:53:04 +0100 Subject: [PATCH 158/270] Removed old wrappers (#10174) --- .../mercury_exposed_verifier.go | 202 --- .../mercury_verifier/mercury_verifier.go | 1602 ----------------- .../mercury_verifier_proxy.go | 1373 -------------- .../ocr2/plugins/mercury/integration_test.go | 8 +- .../relay/evm/mercury/config_digest.go | 4 +- .../relay/evm/mercury/config_digest_test.go | 4 +- .../relay/evm/mercury/config_poller.go | 8 +- .../services/relay/evm/mercury/helper_test.go | 10 +- 8 files changed, 17 insertions(+), 3194 deletions(-) delete mode 100644 core/gethwrappers/generated/mercury_exposed_verifier/mercury_exposed_verifier.go delete mode 100644 core/gethwrappers/generated/mercury_verifier/mercury_verifier.go delete mode 100644 core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go diff --git a/core/gethwrappers/generated/mercury_exposed_verifier/mercury_exposed_verifier.go b/core/gethwrappers/generated/mercury_exposed_verifier/mercury_exposed_verifier.go deleted file mode 100644 index 68aa9f0b907..00000000000 --- a/core/gethwrappers/generated/mercury_exposed_verifier/mercury_exposed_verifier.go +++ /dev/null @@ -1,202 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package mercury_exposed_verifier - -import ( - "errors" - "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" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -var MercuryExposedVerifierMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"_feedId\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"_chainId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_contractAddress\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"_configCount\",\"type\":\"uint64\"},{\"internalType\":\"address[]\",\"name\":\"_signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"_offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"_f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"_onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"_encodedConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"_encodedConfig\",\"type\":\"bytes\"}],\"name\":\"exposedConfigDigestFromConfigData\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b50610696806100206000396000f3fe608060405234801561001057600080fd5b506004361061002b5760003560e01c80630ebd702314610030575b600080fd5b61004361003e3660046103f7565b610055565b60405190815260200160405180910390f35b60006100a18c8c8c8c8c8c8c8c8c8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508e92508d91506100b19050565b9c9b505050505050505050505050565b6000808b8b8b8b8b8b8b8b8b8b6040516020016100d79a999897969594939291906105a7565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e06000000000000000000000000000000000000000000000000000000000000179150509a9950505050505050505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461018357600080fd5b919050565b803567ffffffffffffffff8116811461018357600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610216576102166101a0565b604052919050565b600067ffffffffffffffff821115610238576102386101a0565b5060051b60200190565b600082601f83011261025357600080fd5b813560206102686102638361021e565b6101cf565b82815260059290921b8401810191818101908684111561028757600080fd5b8286015b848110156102a95761029c8161015f565b835291830191830161028b565b509695505050505050565b600082601f8301126102c557600080fd5b813560206102d56102638361021e565b82815260059290921b840181019181810190868411156102f457600080fd5b8286015b848110156102a957803583529183019183016102f8565b803560ff8116811461018357600080fd5b60008083601f84011261033257600080fd5b50813567ffffffffffffffff81111561034a57600080fd5b60208301915083602082850101111561036257600080fd5b9250929050565b600082601f83011261037a57600080fd5b813567ffffffffffffffff811115610394576103946101a0565b6103c560207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116016101cf565b8181528460208386010111156103da57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060008060006101408c8e03121561041957600080fd5b8b359a5060208c0135995061043060408d0161015f565b985061043e60608d01610188565b975067ffffffffffffffff8060808e0135111561045a57600080fd5b61046a8e60808f01358f01610242565b97508060a08e0135111561047d57600080fd5b61048d8e60a08f01358f016102b4565b965061049b60c08e0161030f565b95508060e08e013511156104ae57600080fd5b6104be8e60e08f01358f01610320565b90955093506104d06101008e01610188565b9250806101208e013511156104e457600080fd5b506104f68d6101208e01358e01610369565b90509295989b509295989b9093969950565b600081518084526020808501945080840160005b838110156105385781518752958201959082019060010161051c565b509495945050505050565b6000815180845260005b818110156105695760208185018101518683018201520161054d565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b8a815260208082018b905273ffffffffffffffffffffffffffffffffffffffff8a8116604084015267ffffffffffffffff8a1660608401526101406080840181905289519084018190526000926101608501928b820192855b8181101561061e578451831686529483019493830193600101610600565b505050505082810360a08401526106358189610508565b60ff881660c0850152905082810360e08401526106528187610543565b67ffffffffffffffff861661010085015290508281036101208401526106788185610543565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", -} - -var MercuryExposedVerifierABI = MercuryExposedVerifierMetaData.ABI - -var MercuryExposedVerifierBin = MercuryExposedVerifierMetaData.Bin - -func DeployMercuryExposedVerifier(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *MercuryExposedVerifier, error) { - parsed, err := MercuryExposedVerifierMetaData.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(MercuryExposedVerifierBin), backend) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &MercuryExposedVerifier{MercuryExposedVerifierCaller: MercuryExposedVerifierCaller{contract: contract}, MercuryExposedVerifierTransactor: MercuryExposedVerifierTransactor{contract: contract}, MercuryExposedVerifierFilterer: MercuryExposedVerifierFilterer{contract: contract}}, nil -} - -type MercuryExposedVerifier struct { - address common.Address - abi abi.ABI - MercuryExposedVerifierCaller - MercuryExposedVerifierTransactor - MercuryExposedVerifierFilterer -} - -type MercuryExposedVerifierCaller struct { - contract *bind.BoundContract -} - -type MercuryExposedVerifierTransactor struct { - contract *bind.BoundContract -} - -type MercuryExposedVerifierFilterer struct { - contract *bind.BoundContract -} - -type MercuryExposedVerifierSession struct { - Contract *MercuryExposedVerifier - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type MercuryExposedVerifierCallerSession struct { - Contract *MercuryExposedVerifierCaller - CallOpts bind.CallOpts -} - -type MercuryExposedVerifierTransactorSession struct { - Contract *MercuryExposedVerifierTransactor - TransactOpts bind.TransactOpts -} - -type MercuryExposedVerifierRaw struct { - Contract *MercuryExposedVerifier -} - -type MercuryExposedVerifierCallerRaw struct { - Contract *MercuryExposedVerifierCaller -} - -type MercuryExposedVerifierTransactorRaw struct { - Contract *MercuryExposedVerifierTransactor -} - -func NewMercuryExposedVerifier(address common.Address, backend bind.ContractBackend) (*MercuryExposedVerifier, error) { - abi, err := abi.JSON(strings.NewReader(MercuryExposedVerifierABI)) - if err != nil { - return nil, err - } - contract, err := bindMercuryExposedVerifier(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &MercuryExposedVerifier{address: address, abi: abi, MercuryExposedVerifierCaller: MercuryExposedVerifierCaller{contract: contract}, MercuryExposedVerifierTransactor: MercuryExposedVerifierTransactor{contract: contract}, MercuryExposedVerifierFilterer: MercuryExposedVerifierFilterer{contract: contract}}, nil -} - -func NewMercuryExposedVerifierCaller(address common.Address, caller bind.ContractCaller) (*MercuryExposedVerifierCaller, error) { - contract, err := bindMercuryExposedVerifier(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &MercuryExposedVerifierCaller{contract: contract}, nil -} - -func NewMercuryExposedVerifierTransactor(address common.Address, transactor bind.ContractTransactor) (*MercuryExposedVerifierTransactor, error) { - contract, err := bindMercuryExposedVerifier(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &MercuryExposedVerifierTransactor{contract: contract}, nil -} - -func NewMercuryExposedVerifierFilterer(address common.Address, filterer bind.ContractFilterer) (*MercuryExposedVerifierFilterer, error) { - contract, err := bindMercuryExposedVerifier(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &MercuryExposedVerifierFilterer{contract: contract}, nil -} - -func bindMercuryExposedVerifier(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := MercuryExposedVerifierMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _MercuryExposedVerifier.Contract.MercuryExposedVerifierCaller.contract.Call(opts, result, method, params...) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryExposedVerifier.Contract.MercuryExposedVerifierTransactor.contract.Transfer(opts) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _MercuryExposedVerifier.Contract.MercuryExposedVerifierTransactor.contract.Transact(opts, method, params...) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _MercuryExposedVerifier.Contract.contract.Call(opts, result, method, params...) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryExposedVerifier.Contract.contract.Transfer(opts) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _MercuryExposedVerifier.Contract.contract.Transact(opts, method, params...) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierCaller) ExposedConfigDigestFromConfigData(opts *bind.CallOpts, _feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { - var out []interface{} - err := _MercuryExposedVerifier.contract.Call(opts, &out, "exposedConfigDigestFromConfigData", _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierSession) ExposedConfigDigestFromConfigData(_feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { - return _MercuryExposedVerifier.Contract.ExposedConfigDigestFromConfigData(&_MercuryExposedVerifier.CallOpts, _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifierCallerSession) ExposedConfigDigestFromConfigData(_feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) { - return _MercuryExposedVerifier.Contract.ExposedConfigDigestFromConfigData(&_MercuryExposedVerifier.CallOpts, _feedId, _chainId, _contractAddress, _configCount, _signers, _offchainTransmitters, _f, _onchainConfig, _encodedConfigVersion, _encodedConfig) -} - -func (_MercuryExposedVerifier *MercuryExposedVerifier) Address() common.Address { - return _MercuryExposedVerifier.address -} - -type MercuryExposedVerifierInterface interface { - ExposedConfigDigestFromConfigData(opts *bind.CallOpts, _feedId [32]byte, _chainId *big.Int, _contractAddress common.Address, _configCount uint64, _signers []common.Address, _offchainTransmitters [][32]byte, _f uint8, _onchainConfig []byte, _encodedConfigVersion uint64, _encodedConfig []byte) ([32]byte, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go b/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go deleted file mode 100644 index fda9e535e56..00000000000 --- a/core/gethwrappers/generated/mercury_verifier/mercury_verifier.go +++ /dev/null @@ -1,1602 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package mercury_verifier - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -type CommonAddressAndWeight struct { - Addr common.Address - Weight *big.Int -} - -var MercuryVerifierMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierProxyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"CannotDeactivateLatestConfig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DigestEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestInactive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestNotSet\",\"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\":[],\"name\":\"FeedIdEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InactiveFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"expectedNumSigners\",\"type\":\"uint256\"}],\"name\":\"IncorrectSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InvalidFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rsLength\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"ssLength\",\"type\":\"uint256\"}],\"name\":\"MismatchedSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NonUniqueSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedDeactivated\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"}],\"name\":\"ReportVerified\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"recipientAddressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"isVerifier\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162002150380380620021508339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051611f55620001fb6000396000818161031d015261091e0152611f556000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806379ba50971161008c578063b70d929d11610066578063b70d929d14610221578063ded6307c14610280578063e84f128e14610293578063f2fde38b146102f057600080fd5b806379ba5097146101de5780638da5cb5b146101e657806394d959801461020e57600080fd5b80633dd86430116100bd5780633dd86430146101a357806352ba27d6146101b8578063564a0a7a146101cb57600080fd5b806301ffc9a7146100e4578063181f5a771461014e5780633d3ac1b514610190575b600080fd5b6101396100f2366004611487565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b60408051808201909152600e81527f566572696669657220312e312e3000000000000000000000000000000000000060208201525b6040516101459190611534565b61018361019e366004611570565b610303565b6101b66101b13660046115f1565b61049d565b005b6101b66101c6366004611902565b61054f565b6101b66101d93660046115f1565b610a3f565b6101b6610b00565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610145565b6101b661021c3660046119ff565b610bfd565b61025d61022f3660046115f1565b6000908152600260205260408120600181015490549192909168010000000000000000900463ffffffff1690565b604080519315158452602084019290925263ffffffff1690820152606001610145565b6101b661028e3660046119ff565b610d5e565b6102cd6102a13660046115f1565b6000908152600260205260409020805460019091015463ffffffff808316936401000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610145565b6101b66102fe366004611a21565b610e6f565b60603373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610374576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080610386888a018a611a3c565b9450945094509450945060008461039c90611b17565b60008181526002602052604090208054919250906c01000000000000000000000000900460ff1615610402576040517f36dbe748000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b8651600081815260028301602052604090206104218483898985610e83565b61042b8984610f7f565b87516020890120610440818b8a8a8a87610fe7565b60405173ffffffffffffffffffffffffffffffffffffffff8d16815285907f58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc59060200160405180910390a250969c9b505050505050505050505050565b6104a5611263565b60008181526002602052604081208054909163ffffffff90911690036104fa576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff16815560405182907ff438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b490600090a25050565b86518560ff168060000361058f576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8211156105d4576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f60248201526044016103f9565b6105df816003611bba565b821161063757816105f1826003611bba565b6105fc906001611bf7565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b61063f611263565b60008a81526002602052604081208054909163ffffffff90911690829061066583611c10565b82546101009290920a63ffffffff81810219909316918316021790915582546000925061069a918e91168d8d8d8d8d8d6112e6565b6000818152600284016020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8d16176101001790559091505b8b518160ff1610156108db5760008c8260ff168151811061070057610700611b5c565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610770576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452600190810190925290912054610100900460ff16908111156107c3576107c3611c33565b14801591506107fe576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805180820190915260ff8416815260208101600190526000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684526001908101835292208351815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00821681178355928501519193919284927fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090921617906101009084908111156108c0576108c0611c33565b02179055509050505050806108d490611c62565b90506106dd565b5060018201546040517f589ede2800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169163589ede2891610956919085908a90600401611c81565b600060405180830381600087803b15801561097057600080fd5b505af1158015610984573d6000803e3d6000fd5b505050508b7fa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da8360000160049054906101000a900463ffffffff16838560000160009054906101000a900463ffffffff168f8f8f8f8f8f6040516109f099989796959493929190611d78565b60405180910390a281547fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff1664010000000063ffffffff43160217825560019091015550505050505050505050565b610a47611263565b60008181526002602052604081208054909163ffffffff9091169003610a9c576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff166c0100000000000000000000000017815560405182907ffc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd06190600090a25050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016103f9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c05611263565b600082815260026020526040902081610c4a576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610ca0576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b80600101548203610ce7576040517fa403c01600000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555183907f0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c90610d519085815260200190565b60405180910390a2505050565b610d66611263565b600082815260026020526040902081610dab576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610e01576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555183907f54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe774690610d519085815260200190565b610e77611263565b610e8081611392565b50565b8054600090610e969060ff166001611e0e565b8254909150610100900460ff16610ee3576040517ffc10a28300000000000000000000000000000000000000000000000000000000815260048101879052602481018690526044016103f9565b8060ff16845114610f2f5783516040517f5348a282000000000000000000000000000000000000000000000000000000008152600481019190915260ff821660248201526044016103f9565b8251845114610f7757835183516040517ff0d31408000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b505050505050565b6020820151815463ffffffff600883901c81169168010000000000000000900416811115610fe15782547fffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffff166801000000000000000063ffffffff8316021783555b50505050565b60008686604051602001610ffc929190611e27565b6040516020818303038152906040528051906020012090506000611030604080518082019091526000808252602082015290565b8651600090815b818110156111fb5760018689836020811061105457611054611b5c565b61106191901a601b611e0e565b8c848151811061107357611073611b5c565b60200260200101518c858151811061108d5761108d611b5c565b6020026020010151604051600081526020016040526040516110cb949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156110ed573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526001808d01602090815291859020848601909552845460ff80821686529399509395509085019261010090049091169081111561117257611172611c33565b600181111561118357611183611c33565b90525093506001846020015160018111156111a0576111a0611c33565b146111d7576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836000015160080260ff166001901b85019450806111f490611e63565b9050611037565b50837e01010101010101010101010101010101010101010101010101010101010101851614611256576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146112e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103f9565b565b6000808946308b8b8b8b8b8b8b60405160200161130c9a99989796959493929190611e9b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e060000000000000000000000000000000000000000000000000000000000001791505098975050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603611411576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103f9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561149957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146114c957600080fd5b9392505050565b6000815180845260005b818110156114f6576020818501810151868301820152016114da565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114c960208301846114d0565b803573ffffffffffffffffffffffffffffffffffffffff8116811461156b57600080fd5b919050565b60008060006040848603121561158557600080fd5b833567ffffffffffffffff8082111561159d57600080fd5b818601915086601f8301126115b157600080fd5b8135818111156115c057600080fd5b8760208285010111156115d257600080fd5b6020928301955093506115e89186019050611547565b90509250925092565b60006020828403121561160357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561165c5761165c61160a565b60405290565b6040516060810167ffffffffffffffff8111828210171561165c5761165c61160a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156116cc576116cc61160a565b604052919050565b600067ffffffffffffffff8211156116ee576116ee61160a565b5060051b60200190565b600082601f83011261170957600080fd5b8135602061171e611719836116d4565b611685565b82815260059290921b8401810191818101908684111561173d57600080fd5b8286015b8481101561175f5761175281611547565b8352918301918301611741565b509695505050505050565b600082601f83011261177b57600080fd5b8135602061178b611719836116d4565b82815260059290921b840181019181810190868411156117aa57600080fd5b8286015b8481101561175f57803583529183019183016117ae565b803560ff8116811461156b57600080fd5b600082601f8301126117e757600080fd5b813567ffffffffffffffff8111156118015761180161160a565b61183260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611685565b81815284602083860101111561184757600080fd5b816020850160208301376000918101602001919091529392505050565b803567ffffffffffffffff8116811461156b57600080fd5b600082601f83011261188d57600080fd5b8135602061189d611719836116d4565b82815260069290921b840181019181810190868411156118bc57600080fd5b8286015b8481101561175f57604081890312156118d95760008081fd5b6118e1611639565b6118ea82611547565b815281850135858201528352918301916040016118c0565b600080600080600080600080610100898b03121561191f57600080fd5b88359750602089013567ffffffffffffffff8082111561193e57600080fd5b61194a8c838d016116f8565b985060408b013591508082111561196057600080fd5b61196c8c838d0161176a565b975061197a60608c016117c5565b965060808b013591508082111561199057600080fd5b61199c8c838d016117d6565b95506119aa60a08c01611864565b945060c08b01359150808211156119c057600080fd5b6119cc8c838d016117d6565b935060e08b01359150808211156119e257600080fd5b506119ef8b828c0161187c565b9150509295985092959890939650565b60008060408385031215611a1257600080fd5b50508035926020909101359150565b600060208284031215611a3357600080fd5b6114c982611547565b600080600080600060e08688031215611a5457600080fd5b86601f870112611a6357600080fd5b611a6b611662565b806060880189811115611a7d57600080fd5b885b81811015611a97578035845260209384019301611a7f565b5090965035905067ffffffffffffffff80821115611ab457600080fd5b611ac089838a016117d6565b95506080880135915080821115611ad657600080fd5b611ae289838a0161176a565b945060a0880135915080821115611af857600080fd5b50611b058882890161176a565b9598949750929560c001359392505050565b80516020808301519190811015611b56577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611bf257611bf2611b8b565b500290565b80820180821115611c0a57611c0a611b8b565b92915050565b600063ffffffff808316818103611c2957611c29611b8b565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600060ff821660ff8103611c7857611c78611b8b565b60010192915050565b600060608201858352602085818501526040606081860152828651808552608087019150838801945060005b81811015611ce8578551805173ffffffffffffffffffffffffffffffffffffffff168452850151858401529484019491830191600101611cad565b50909998505050505050505050565b600081518084526020808501945080840160005b83811015611d3d57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101611d0b565b509495945050505050565b600081518084526020808501945080840160005b83811015611d3d57815187529582019590820190600101611d5c565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152611da88184018a611cf7565b90508281036080840152611dbc8189611d48565b905060ff871660a084015282810360c0840152611dd981876114d0565b905067ffffffffffffffff851660e0840152828103610100840152611dfe81856114d0565b9c9b505050505050505050505050565b60ff8181168382160190811115611c0a57611c0a611b8b565b828152600060208083018460005b6003811015611e5257815183529183019190830190600101611e35565b505050506080820190509392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611e9457611e94611b8b565b5060010190565b60006101408c83528b602084015273ffffffffffffffffffffffffffffffffffffffff8b16604084015267ffffffffffffffff808b166060850152816080850152611ee88285018b611cf7565b915083820360a0850152611efc828a611d48565b915060ff881660c085015283820360e0850152611f1982886114d0565b9086166101008501528381036101208501529050611f3781856114d0565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", -} - -var MercuryVerifierABI = MercuryVerifierMetaData.ABI - -var MercuryVerifierBin = MercuryVerifierMetaData.Bin - -func DeployMercuryVerifier(auth *bind.TransactOpts, backend bind.ContractBackend, verifierProxyAddr common.Address) (common.Address, *types.Transaction, *MercuryVerifier, error) { - parsed, err := MercuryVerifierMetaData.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(MercuryVerifierBin), backend, verifierProxyAddr) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &MercuryVerifier{MercuryVerifierCaller: MercuryVerifierCaller{contract: contract}, MercuryVerifierTransactor: MercuryVerifierTransactor{contract: contract}, MercuryVerifierFilterer: MercuryVerifierFilterer{contract: contract}}, nil -} - -type MercuryVerifier struct { - address common.Address - abi abi.ABI - MercuryVerifierCaller - MercuryVerifierTransactor - MercuryVerifierFilterer -} - -type MercuryVerifierCaller struct { - contract *bind.BoundContract -} - -type MercuryVerifierTransactor struct { - contract *bind.BoundContract -} - -type MercuryVerifierFilterer struct { - contract *bind.BoundContract -} - -type MercuryVerifierSession struct { - Contract *MercuryVerifier - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type MercuryVerifierCallerSession struct { - Contract *MercuryVerifierCaller - CallOpts bind.CallOpts -} - -type MercuryVerifierTransactorSession struct { - Contract *MercuryVerifierTransactor - TransactOpts bind.TransactOpts -} - -type MercuryVerifierRaw struct { - Contract *MercuryVerifier -} - -type MercuryVerifierCallerRaw struct { - Contract *MercuryVerifierCaller -} - -type MercuryVerifierTransactorRaw struct { - Contract *MercuryVerifierTransactor -} - -func NewMercuryVerifier(address common.Address, backend bind.ContractBackend) (*MercuryVerifier, error) { - abi, err := abi.JSON(strings.NewReader(MercuryVerifierABI)) - if err != nil { - return nil, err - } - contract, err := bindMercuryVerifier(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &MercuryVerifier{address: address, abi: abi, MercuryVerifierCaller: MercuryVerifierCaller{contract: contract}, MercuryVerifierTransactor: MercuryVerifierTransactor{contract: contract}, MercuryVerifierFilterer: MercuryVerifierFilterer{contract: contract}}, nil -} - -func NewMercuryVerifierCaller(address common.Address, caller bind.ContractCaller) (*MercuryVerifierCaller, error) { - contract, err := bindMercuryVerifier(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &MercuryVerifierCaller{contract: contract}, nil -} - -func NewMercuryVerifierTransactor(address common.Address, transactor bind.ContractTransactor) (*MercuryVerifierTransactor, error) { - contract, err := bindMercuryVerifier(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &MercuryVerifierTransactor{contract: contract}, nil -} - -func NewMercuryVerifierFilterer(address common.Address, filterer bind.ContractFilterer) (*MercuryVerifierFilterer, error) { - contract, err := bindMercuryVerifier(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &MercuryVerifierFilterer{contract: contract}, nil -} - -func bindMercuryVerifier(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := MercuryVerifierMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_MercuryVerifier *MercuryVerifierRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _MercuryVerifier.Contract.MercuryVerifierCaller.contract.Call(opts, result, method, params...) -} - -func (_MercuryVerifier *MercuryVerifierRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryVerifier.Contract.MercuryVerifierTransactor.contract.Transfer(opts) -} - -func (_MercuryVerifier *MercuryVerifierRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _MercuryVerifier.Contract.MercuryVerifierTransactor.contract.Transact(opts, method, params...) -} - -func (_MercuryVerifier *MercuryVerifierCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _MercuryVerifier.Contract.contract.Call(opts, result, method, params...) -} - -func (_MercuryVerifier *MercuryVerifierTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryVerifier.Contract.contract.Transfer(opts) -} - -func (_MercuryVerifier *MercuryVerifierTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _MercuryVerifier.Contract.contract.Transact(opts, method, params...) -} - -func (_MercuryVerifier *MercuryVerifierCaller) LatestConfigDetails(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDetails, - - error) { - var out []interface{} - err := _MercuryVerifier.contract.Call(opts, &out, "latestConfigDetails", feedId) - - outstruct := new(LatestConfigDetails) - if err != nil { - return *outstruct, err - } - - outstruct.ConfigCount = *abi.ConvertType(out[0], new(uint32)).(*uint32) - outstruct.BlockNumber = *abi.ConvertType(out[1], new(uint32)).(*uint32) - outstruct.ConfigDigest = *abi.ConvertType(out[2], new([32]byte)).(*[32]byte) - - return *outstruct, err - -} - -func (_MercuryVerifier *MercuryVerifierSession) LatestConfigDetails(feedId [32]byte) (LatestConfigDetails, - - error) { - return _MercuryVerifier.Contract.LatestConfigDetails(&_MercuryVerifier.CallOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierCallerSession) LatestConfigDetails(feedId [32]byte) (LatestConfigDetails, - - error) { - return _MercuryVerifier.Contract.LatestConfigDetails(&_MercuryVerifier.CallOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierCaller) LatestConfigDigestAndEpoch(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDigestAndEpoch, - - error) { - var out []interface{} - err := _MercuryVerifier.contract.Call(opts, &out, "latestConfigDigestAndEpoch", feedId) - - outstruct := new(LatestConfigDigestAndEpoch) - if err != nil { - return *outstruct, err - } - - outstruct.ScanLogs = *abi.ConvertType(out[0], new(bool)).(*bool) - outstruct.ConfigDigest = *abi.ConvertType(out[1], new([32]byte)).(*[32]byte) - outstruct.Epoch = *abi.ConvertType(out[2], new(uint32)).(*uint32) - - return *outstruct, err - -} - -func (_MercuryVerifier *MercuryVerifierSession) LatestConfigDigestAndEpoch(feedId [32]byte) (LatestConfigDigestAndEpoch, - - error) { - return _MercuryVerifier.Contract.LatestConfigDigestAndEpoch(&_MercuryVerifier.CallOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierCallerSession) LatestConfigDigestAndEpoch(feedId [32]byte) (LatestConfigDigestAndEpoch, - - error) { - return _MercuryVerifier.Contract.LatestConfigDigestAndEpoch(&_MercuryVerifier.CallOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _MercuryVerifier.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 (_MercuryVerifier *MercuryVerifierSession) Owner() (common.Address, error) { - return _MercuryVerifier.Contract.Owner(&_MercuryVerifier.CallOpts) -} - -func (_MercuryVerifier *MercuryVerifierCallerSession) Owner() (common.Address, error) { - return _MercuryVerifier.Contract.Owner(&_MercuryVerifier.CallOpts) -} - -func (_MercuryVerifier *MercuryVerifierCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { - var out []interface{} - err := _MercuryVerifier.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 (_MercuryVerifier *MercuryVerifierSession) SupportsInterface(interfaceId [4]byte) (bool, error) { - return _MercuryVerifier.Contract.SupportsInterface(&_MercuryVerifier.CallOpts, interfaceId) -} - -func (_MercuryVerifier *MercuryVerifierCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { - return _MercuryVerifier.Contract.SupportsInterface(&_MercuryVerifier.CallOpts, interfaceId) -} - -func (_MercuryVerifier *MercuryVerifierCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { - var out []interface{} - err := _MercuryVerifier.contract.Call(opts, &out, "typeAndVersion") - - if err != nil { - return *new(string), err - } - - out0 := *abi.ConvertType(out[0], new(string)).(*string) - - return out0, err - -} - -func (_MercuryVerifier *MercuryVerifierSession) TypeAndVersion() (string, error) { - return _MercuryVerifier.Contract.TypeAndVersion(&_MercuryVerifier.CallOpts) -} - -func (_MercuryVerifier *MercuryVerifierCallerSession) TypeAndVersion() (string, error) { - return _MercuryVerifier.Contract.TypeAndVersion(&_MercuryVerifier.CallOpts) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "acceptOwnership") -} - -func (_MercuryVerifier *MercuryVerifierSession) AcceptOwnership() (*types.Transaction, error) { - return _MercuryVerifier.Contract.AcceptOwnership(&_MercuryVerifier.TransactOpts) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _MercuryVerifier.Contract.AcceptOwnership(&_MercuryVerifier.TransactOpts) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) ActivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "activateConfig", feedId, configDigest) -} - -func (_MercuryVerifier *MercuryVerifierSession) ActivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.ActivateConfig(&_MercuryVerifier.TransactOpts, feedId, configDigest) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) ActivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.ActivateConfig(&_MercuryVerifier.TransactOpts, feedId, configDigest) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) ActivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "activateFeed", feedId) -} - -func (_MercuryVerifier *MercuryVerifierSession) ActivateFeed(feedId [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.ActivateFeed(&_MercuryVerifier.TransactOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) ActivateFeed(feedId [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.ActivateFeed(&_MercuryVerifier.TransactOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) DeactivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "deactivateConfig", feedId, configDigest) -} - -func (_MercuryVerifier *MercuryVerifierSession) DeactivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.DeactivateConfig(&_MercuryVerifier.TransactOpts, feedId, configDigest) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) DeactivateConfig(feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.DeactivateConfig(&_MercuryVerifier.TransactOpts, feedId, configDigest) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) DeactivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "deactivateFeed", feedId) -} - -func (_MercuryVerifier *MercuryVerifierSession) DeactivateFeed(feedId [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.DeactivateFeed(&_MercuryVerifier.TransactOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) DeactivateFeed(feedId [32]byte) (*types.Transaction, error) { - return _MercuryVerifier.Contract.DeactivateFeed(&_MercuryVerifier.TransactOpts, feedId) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "setConfig", feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) -} - -func (_MercuryVerifier *MercuryVerifierSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { - return _MercuryVerifier.Contract.SetConfig(&_MercuryVerifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) SetConfig(feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { - return _MercuryVerifier.Contract.SetConfig(&_MercuryVerifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "transferOwnership", to) -} - -func (_MercuryVerifier *MercuryVerifierSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _MercuryVerifier.Contract.TransferOwnership(&_MercuryVerifier.TransactOpts, to) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _MercuryVerifier.Contract.TransferOwnership(&_MercuryVerifier.TransactOpts, to) -} - -func (_MercuryVerifier *MercuryVerifierTransactor) Verify(opts *bind.TransactOpts, signedReport []byte, sender common.Address) (*types.Transaction, error) { - return _MercuryVerifier.contract.Transact(opts, "verify", signedReport, sender) -} - -func (_MercuryVerifier *MercuryVerifierSession) Verify(signedReport []byte, sender common.Address) (*types.Transaction, error) { - return _MercuryVerifier.Contract.Verify(&_MercuryVerifier.TransactOpts, signedReport, sender) -} - -func (_MercuryVerifier *MercuryVerifierTransactorSession) Verify(signedReport []byte, sender common.Address) (*types.Transaction, error) { - return _MercuryVerifier.Contract.Verify(&_MercuryVerifier.TransactOpts, signedReport, sender) -} - -type MercuryVerifierConfigActivatedIterator struct { - Event *MercuryVerifierConfigActivated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierConfigActivatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierConfigActivated) - 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(MercuryVerifierConfigActivated) - 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 *MercuryVerifierConfigActivatedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierConfigActivatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierConfigActivated struct { - FeedId [32]byte - ConfigDigest [32]byte - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterConfigActivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierConfigActivatedIterator, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "ConfigActivated", feedIdRule) - if err != nil { - return nil, err - } - return &MercuryVerifierConfigActivatedIterator{contract: _MercuryVerifier.contract, event: "ConfigActivated", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchConfigActivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierConfigActivated, feedId [][32]byte) (event.Subscription, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "ConfigActivated", feedIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierConfigActivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "ConfigActivated", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseConfigActivated(log types.Log) (*MercuryVerifierConfigActivated, error) { - event := new(MercuryVerifierConfigActivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "ConfigActivated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierConfigDeactivatedIterator struct { - Event *MercuryVerifierConfigDeactivated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierConfigDeactivatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierConfigDeactivated) - 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(MercuryVerifierConfigDeactivated) - 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 *MercuryVerifierConfigDeactivatedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierConfigDeactivatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierConfigDeactivated struct { - FeedId [32]byte - ConfigDigest [32]byte - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterConfigDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierConfigDeactivatedIterator, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "ConfigDeactivated", feedIdRule) - if err != nil { - return nil, err - } - return &MercuryVerifierConfigDeactivatedIterator{contract: _MercuryVerifier.contract, event: "ConfigDeactivated", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchConfigDeactivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierConfigDeactivated, feedId [][32]byte) (event.Subscription, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "ConfigDeactivated", feedIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierConfigDeactivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "ConfigDeactivated", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseConfigDeactivated(log types.Log) (*MercuryVerifierConfigDeactivated, error) { - event := new(MercuryVerifierConfigDeactivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "ConfigDeactivated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierConfigSetIterator struct { - Event *MercuryVerifierConfigSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierConfigSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierConfigSet) - 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(MercuryVerifierConfigSet) - 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 *MercuryVerifierConfigSetIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierConfigSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierConfigSet struct { - FeedId [32]byte - PreviousConfigBlockNumber uint32 - ConfigDigest [32]byte - ConfigCount uint64 - Signers []common.Address - OffchainTransmitters [][32]byte - F uint8 - OnchainConfig []byte - OffchainConfigVersion uint64 - OffchainConfig []byte - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterConfigSet(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierConfigSetIterator, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "ConfigSet", feedIdRule) - if err != nil { - return nil, err - } - return &MercuryVerifierConfigSetIterator{contract: _MercuryVerifier.contract, event: "ConfigSet", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierConfigSet, feedId [][32]byte) (event.Subscription, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "ConfigSet", feedIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierConfigSet) - if err := _MercuryVerifier.contract.UnpackLog(event, "ConfigSet", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseConfigSet(log types.Log) (*MercuryVerifierConfigSet, error) { - event := new(MercuryVerifierConfigSet) - if err := _MercuryVerifier.contract.UnpackLog(event, "ConfigSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierFeedActivatedIterator struct { - Event *MercuryVerifierFeedActivated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierFeedActivatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierFeedActivated) - 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(MercuryVerifierFeedActivated) - 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 *MercuryVerifierFeedActivatedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierFeedActivatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierFeedActivated struct { - FeedId [32]byte - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterFeedActivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierFeedActivatedIterator, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "FeedActivated", feedIdRule) - if err != nil { - return nil, err - } - return &MercuryVerifierFeedActivatedIterator{contract: _MercuryVerifier.contract, event: "FeedActivated", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchFeedActivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierFeedActivated, feedId [][32]byte) (event.Subscription, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "FeedActivated", feedIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierFeedActivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "FeedActivated", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseFeedActivated(log types.Log) (*MercuryVerifierFeedActivated, error) { - event := new(MercuryVerifierFeedActivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "FeedActivated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierFeedDeactivatedIterator struct { - Event *MercuryVerifierFeedDeactivated - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierFeedDeactivatedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierFeedDeactivated) - 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(MercuryVerifierFeedDeactivated) - 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 *MercuryVerifierFeedDeactivatedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierFeedDeactivatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierFeedDeactivated struct { - FeedId [32]byte - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterFeedDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierFeedDeactivatedIterator, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "FeedDeactivated", feedIdRule) - if err != nil { - return nil, err - } - return &MercuryVerifierFeedDeactivatedIterator{contract: _MercuryVerifier.contract, event: "FeedDeactivated", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchFeedDeactivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierFeedDeactivated, feedId [][32]byte) (event.Subscription, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "FeedDeactivated", feedIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierFeedDeactivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "FeedDeactivated", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseFeedDeactivated(log types.Log) (*MercuryVerifierFeedDeactivated, error) { - event := new(MercuryVerifierFeedDeactivated) - if err := _MercuryVerifier.contract.UnpackLog(event, "FeedDeactivated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierOwnershipTransferRequestedIterator struct { - Event *MercuryVerifierOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierOwnershipTransferRequested) - 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(MercuryVerifierOwnershipTransferRequested) - 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 *MercuryVerifierOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &MercuryVerifierOwnershipTransferRequestedIterator{contract: _MercuryVerifier.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *MercuryVerifierOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierOwnershipTransferRequested) - if err := _MercuryVerifier.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseOwnershipTransferRequested(log types.Log) (*MercuryVerifierOwnershipTransferRequested, error) { - event := new(MercuryVerifierOwnershipTransferRequested) - if err := _MercuryVerifier.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierOwnershipTransferredIterator struct { - Event *MercuryVerifierOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierOwnershipTransferred) - 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(MercuryVerifierOwnershipTransferred) - 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 *MercuryVerifierOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &MercuryVerifierOwnershipTransferredIterator{contract: _MercuryVerifier.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *MercuryVerifierOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierOwnershipTransferred) - if err := _MercuryVerifier.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 (_MercuryVerifier *MercuryVerifierFilterer) ParseOwnershipTransferred(log types.Log) (*MercuryVerifierOwnershipTransferred, error) { - event := new(MercuryVerifierOwnershipTransferred) - if err := _MercuryVerifier.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierReportVerifiedIterator struct { - Event *MercuryVerifierReportVerified - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierReportVerifiedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierReportVerified) - 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(MercuryVerifierReportVerified) - 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 *MercuryVerifierReportVerifiedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierReportVerifiedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierReportVerified struct { - FeedId [32]byte - Requester common.Address - Raw types.Log -} - -func (_MercuryVerifier *MercuryVerifierFilterer) FilterReportVerified(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierReportVerifiedIterator, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.FilterLogs(opts, "ReportVerified", feedIdRule) - if err != nil { - return nil, err - } - return &MercuryVerifierReportVerifiedIterator{contract: _MercuryVerifier.contract, event: "ReportVerified", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifier *MercuryVerifierFilterer) WatchReportVerified(opts *bind.WatchOpts, sink chan<- *MercuryVerifierReportVerified, feedId [][32]byte) (event.Subscription, error) { - - var feedIdRule []interface{} - for _, feedIdItem := range feedId { - feedIdRule = append(feedIdRule, feedIdItem) - } - - logs, sub, err := _MercuryVerifier.contract.WatchLogs(opts, "ReportVerified", feedIdRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierReportVerified) - if err := _MercuryVerifier.contract.UnpackLog(event, "ReportVerified", 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 (_MercuryVerifier *MercuryVerifierFilterer) ParseReportVerified(log types.Log) (*MercuryVerifierReportVerified, error) { - event := new(MercuryVerifierReportVerified) - if err := _MercuryVerifier.contract.UnpackLog(event, "ReportVerified", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type LatestConfigDetails struct { - ConfigCount uint32 - BlockNumber uint32 - ConfigDigest [32]byte -} -type LatestConfigDigestAndEpoch struct { - ScanLogs bool - ConfigDigest [32]byte - Epoch uint32 -} - -func (_MercuryVerifier *MercuryVerifier) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _MercuryVerifier.abi.Events["ConfigActivated"].ID: - return _MercuryVerifier.ParseConfigActivated(log) - case _MercuryVerifier.abi.Events["ConfigDeactivated"].ID: - return _MercuryVerifier.ParseConfigDeactivated(log) - case _MercuryVerifier.abi.Events["ConfigSet"].ID: - return _MercuryVerifier.ParseConfigSet(log) - case _MercuryVerifier.abi.Events["FeedActivated"].ID: - return _MercuryVerifier.ParseFeedActivated(log) - case _MercuryVerifier.abi.Events["FeedDeactivated"].ID: - return _MercuryVerifier.ParseFeedDeactivated(log) - case _MercuryVerifier.abi.Events["OwnershipTransferRequested"].ID: - return _MercuryVerifier.ParseOwnershipTransferRequested(log) - case _MercuryVerifier.abi.Events["OwnershipTransferred"].ID: - return _MercuryVerifier.ParseOwnershipTransferred(log) - case _MercuryVerifier.abi.Events["ReportVerified"].ID: - return _MercuryVerifier.ParseReportVerified(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (MercuryVerifierConfigActivated) Topic() common.Hash { - return common.HexToHash("0x54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe7746") -} - -func (MercuryVerifierConfigDeactivated) Topic() common.Hash { - return common.HexToHash("0x0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c") -} - -func (MercuryVerifierConfigSet) Topic() common.Hash { - return common.HexToHash("0xa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da") -} - -func (MercuryVerifierFeedActivated) Topic() common.Hash { - return common.HexToHash("0xf438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b4") -} - -func (MercuryVerifierFeedDeactivated) Topic() common.Hash { - return common.HexToHash("0xfc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd061") -} - -func (MercuryVerifierOwnershipTransferRequested) Topic() common.Hash { - return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") -} - -func (MercuryVerifierOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") -} - -func (MercuryVerifierReportVerified) Topic() common.Hash { - return common.HexToHash("0x58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc5") -} - -func (_MercuryVerifier *MercuryVerifier) Address() common.Address { - return _MercuryVerifier.address -} - -type MercuryVerifierInterface interface { - LatestConfigDetails(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDetails, - - error) - - LatestConfigDigestAndEpoch(opts *bind.CallOpts, feedId [32]byte) (LatestConfigDigestAndEpoch, - - error) - - Owner(opts *bind.CallOpts) (common.Address, error) - - SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) - - TypeAndVersion(opts *bind.CallOpts) (string, error) - - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - - ActivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) - - ActivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) - - DeactivateConfig(opts *bind.TransactOpts, feedId [32]byte, configDigest [32]byte) (*types.Transaction, error) - - DeactivateFeed(opts *bind.TransactOpts, feedId [32]byte) (*types.Transaction, error) - - SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) - - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - Verify(opts *bind.TransactOpts, signedReport []byte, sender common.Address) (*types.Transaction, error) - - FilterConfigActivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierConfigActivatedIterator, error) - - WatchConfigActivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierConfigActivated, feedId [][32]byte) (event.Subscription, error) - - ParseConfigActivated(log types.Log) (*MercuryVerifierConfigActivated, error) - - FilterConfigDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierConfigDeactivatedIterator, error) - - WatchConfigDeactivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierConfigDeactivated, feedId [][32]byte) (event.Subscription, error) - - ParseConfigDeactivated(log types.Log) (*MercuryVerifierConfigDeactivated, error) - - FilterConfigSet(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierConfigSetIterator, error) - - WatchConfigSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierConfigSet, feedId [][32]byte) (event.Subscription, error) - - ParseConfigSet(log types.Log) (*MercuryVerifierConfigSet, error) - - FilterFeedActivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierFeedActivatedIterator, error) - - WatchFeedActivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierFeedActivated, feedId [][32]byte) (event.Subscription, error) - - ParseFeedActivated(log types.Log) (*MercuryVerifierFeedActivated, error) - - FilterFeedDeactivated(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierFeedDeactivatedIterator, error) - - WatchFeedDeactivated(opts *bind.WatchOpts, sink chan<- *MercuryVerifierFeedDeactivated, feedId [][32]byte) (event.Subscription, error) - - ParseFeedDeactivated(log types.Log) (*MercuryVerifierFeedDeactivated, error) - - FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierOwnershipTransferRequestedIterator, error) - - WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *MercuryVerifierOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferRequested(log types.Log) (*MercuryVerifierOwnershipTransferRequested, error) - - FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierOwnershipTransferredIterator, error) - - WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *MercuryVerifierOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferred(log types.Log) (*MercuryVerifierOwnershipTransferred, error) - - FilterReportVerified(opts *bind.FilterOpts, feedId [][32]byte) (*MercuryVerifierReportVerifiedIterator, error) - - WatchReportVerified(opts *bind.WatchOpts, sink chan<- *MercuryVerifierReportVerified, feedId [][32]byte) (event.Subscription, error) - - ParseReportVerified(log types.Log) (*MercuryVerifierReportVerified, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go b/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go deleted file mode 100644 index fc6166d4428..00000000000 --- a/core/gethwrappers/generated/mercury_verifier_proxy/mercury_verifier_proxy.go +++ /dev/null @@ -1,1373 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package mercury_verifier_proxy - -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/v2/core/gethwrappers/generated" -) - -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -type CommonAddressAndWeight struct { - Addr common.Address - Weight *big.Int -} - -var MercuryVerifierProxyMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"ConfigDigestAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifier\",\"type\":\"address\"}],\"name\":\"VerifierAlreadyInitialized\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"VerifierInvalid\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"VerifierNotFound\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldAccessController\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newAccessController\",\"type\":\"address\"}],\"name\":\"AccessControllerSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"oldFeeManager\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newFeeManager\",\"type\":\"address\"}],\"name\":\"FeeManagerSet\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierInitialized\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"oldConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"VerifierUnset\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"getVerifier\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierAddress\",\"type\":\"address\"}],\"name\":\"initializeVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_accessController\",\"outputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeManager\",\"outputs\":[{\"internalType\":\"contractIVerifierFeeManager\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractAccessControllerInterface\",\"name\":\"accessController\",\"type\":\"address\"}],\"name\":\"setAccessController\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"contractIVerifierFeeManager\",\"name\":\"feeManager\",\"type\":\"address\"}],\"name\":\"setFeeManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"currentConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"newConfigDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"addressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setVerifier\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"unsetVerifier\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"verifierResponse\",\"type\":\"bytes\"}],\"stateMutability\":\"payable\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b50604051620014e6380380620014e683398101604081905261003191610189565b33806000816100875760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b03848116919091179091558116156100b7576100b7816100e0565b5050600480546001600160a01b0319166001600160a01b039390931692909217909155506101b9565b336001600160a01b038216036101385760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161007e565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561019b57600080fd5b81516001600160a01b03811681146101b257600080fd5b9392505050565b61131d80620001c96000396000f3fe6080604052600436106100d25760003560e01c80638c2a4d531161007f57806394ba28461161005957806394ba284614610256578063eeb7b24814610283578063f08391d8146102c6578063f2fde38b146102e657600080fd5b80638c2a4d53146101f85780638da5cb5b146102185780638e760afe1461024357600080fd5b8063589ede28116100b0578063589ede28146101a35780636e914094146101c357806379ba5097146101e357600080fd5b8063181f5a77146100d757806338416b5b1461012f578063472d35b914610181575b600080fd5b3480156100e357600080fd5b5060408051808201909152601381527f566572696669657250726f787920312e312e300000000000000000000000000060208201525b6040516101269190610f30565b60405180910390f35b34801561013b57600080fd5b5060055461015c9073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610126565b34801561018d57600080fd5b506101a161019c366004610f6c565b610306565b005b3480156101af57600080fd5b506101a16101be366004610f89565b610395565b3480156101cf57600080fd5b506101a16101de36600461100c565b6105c0565b3480156101ef57600080fd5b506101a16106ac565b34801561020457600080fd5b506101a1610213366004610f6c565b6107a9565b34801561022457600080fd5b5060005473ffffffffffffffffffffffffffffffffffffffff1661015c565b610119610251366004611025565b6109da565b34801561026257600080fd5b5060045461015c9073ffffffffffffffffffffffffffffffffffffffff1681565b34801561028f57600080fd5b5061015c61029e36600461100c565b60009081526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1690565b3480156102d257600080fd5b506101a16102e1366004610f6c565b610caf565b3480156102f257600080fd5b506101a1610301366004610f6c565b610d36565b61030e610d4a565b6005805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f04628abcaa6b1674651352125cb94b65b289145bc2bc4d67720bb7d966372f0391015b60405180910390a15050565b600083815260036020526040902054839073ffffffffffffffffffffffffffffffffffffffff168015610418576040517f375d1fe60000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff821660248201526044015b60405180910390fd5b3360009081526002602052604090205460ff16610461576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260036020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000163317905582156105795760055473ffffffffffffffffffffffffffffffffffffffff166104ec576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6005546040517f69fd2b3400000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff909116906369fd2b349061054690889088908890600401611097565b600060405180830381600087803b15801561056057600080fd5b505af1158015610574573d6000803e3d6000fd5b505050505b6040805187815260208101879052338183015290517fbeb513e532542a562ac35699e7cd9ae7d198dcd3eee15bada6c857d28ceaddcf9181900360600190a1505050505050565b6105c8610d4a565b60008181526003602052604090205473ffffffffffffffffffffffffffffffffffffffff1680610627576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161040f565b6000828152600360205260409081902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055517f11dc15c4b8ac2b183166cc8427e5385a5ece8308217a4217338c6a7614845c4c90610389908490849091825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60015473ffffffffffffffffffffffffffffffffffffffff16331461072d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e657200000000000000000000604482015260640161040f565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6107b1610d4a565b8073ffffffffffffffffffffffffffffffffffffffff81166107ff576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f01ffc9a70000000000000000000000000000000000000000000000000000000081527f3d3ac1b500000000000000000000000000000000000000000000000000000000600482015273ffffffffffffffffffffffffffffffffffffffff8216906301ffc9a790602401602060405180830381865afa158015610889573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906108ad9190611106565b6108e3576040517f75b0527a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff821660009081526002602052604090205460ff161561095b576040517f4e01ccfd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8316600482015260240161040f565b73ffffffffffffffffffffffffffffffffffffffff821660008181526002602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600117905590519182527f1f2cd7c97f4d801b5efe26cc409617c1fd6c5ef786e79aacb90af40923e4e8e99101610389565b60045460609073ffffffffffffffffffffffffffffffffffffffff168015801590610a9a57506040517f6b14daf800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890610a579033906000903690600401611171565b602060405180830381865afa158015610a74573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a989190611106565b155b15610ad1576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610add84866111aa565b60008181526003602052604090205490915073ffffffffffffffffffffffffffffffffffffffff1680610b3f576040517fb151802b0000000000000000000000000000000000000000000000000000000081526004810183905260240161040f565b60055473ffffffffffffffffffffffffffffffffffffffff168015610be9576040517ff1387e1600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff82169063f1387e16903490610bb6908b908b9033906004016111e7565b6000604051808303818588803b158015610bcf57600080fd5b505af1158015610be3573d6000803e3d6000fd5b50505050505b6040517f3d3ac1b500000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff831690633d3ac1b590610c3f908a908a9033906004016111e7565b6000604051808303816000875af1158015610c5e573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0168201604052610ca49190810190611250565b979650505050505050565b610cb7610d4a565b6004805473ffffffffffffffffffffffffffffffffffffffff8381167fffffffffffffffffffffffff000000000000000000000000000000000000000083168117909355604080519190921680825260208201939093527f953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b69101610389565b610d3e610d4a565b610d4781610dcd565b50565b60005473ffffffffffffffffffffffffffffffffffffffff163314610dcb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161040f565b565b3373ffffffffffffffffffffffffffffffffffffffff821603610e4c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161040f565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60005b83811015610edd578181015183820152602001610ec5565b50506000910152565b60008151808452610efe816020860160208601610ec2565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000610f436020830184610ee6565b9392505050565b73ffffffffffffffffffffffffffffffffffffffff81168114610d4757600080fd5b600060208284031215610f7e57600080fd5b8135610f4381610f4a565b60008060008060608587031215610f9f57600080fd5b8435935060208501359250604085013567ffffffffffffffff80821115610fc557600080fd5b818701915087601f830112610fd957600080fd5b813581811115610fe857600080fd5b8860208260061b8501011115610ffd57600080fd5b95989497505060200194505050565b60006020828403121561101e57600080fd5b5035919050565b6000806020838503121561103857600080fd5b823567ffffffffffffffff8082111561105057600080fd5b818501915085601f83011261106457600080fd5b81358181111561107357600080fd5b86602082850101111561108557600080fd5b60209290920196919550909350505050565b8381526040602080830182905282820184905260009190859060608501845b878110156110f95783356110c981610f4a565b73ffffffffffffffffffffffffffffffffffffffff168252838301358383015292840192908401906001016110b6565b5098975050505050505050565b60006020828403121561111857600080fd5b81518015158114610f4357600080fd5b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b73ffffffffffffffffffffffffffffffffffffffff841681526040602082015260006111a1604083018486611128565b95945050505050565b803560208310156111e1577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b165b92915050565b6040815260006111fb604083018587611128565b905073ffffffffffffffffffffffffffffffffffffffff83166020830152949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60006020828403121561126257600080fd5b815167ffffffffffffffff8082111561127a57600080fd5b818401915084601f83011261128e57600080fd5b8151818111156112a0576112a0611221565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156112e6576112e6611221565b816040528281528760208487010111156112ff57600080fd5b610ca4836020830160208801610ec256fea164736f6c6343000810000a", -} - -var MercuryVerifierProxyABI = MercuryVerifierProxyMetaData.ABI - -var MercuryVerifierProxyBin = MercuryVerifierProxyMetaData.Bin - -func DeployMercuryVerifierProxy(auth *bind.TransactOpts, backend bind.ContractBackend, accessController common.Address) (common.Address, *types.Transaction, *MercuryVerifierProxy, error) { - parsed, err := MercuryVerifierProxyMetaData.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(MercuryVerifierProxyBin), backend, accessController) - if err != nil { - return common.Address{}, nil, nil, err - } - return address, tx, &MercuryVerifierProxy{MercuryVerifierProxyCaller: MercuryVerifierProxyCaller{contract: contract}, MercuryVerifierProxyTransactor: MercuryVerifierProxyTransactor{contract: contract}, MercuryVerifierProxyFilterer: MercuryVerifierProxyFilterer{contract: contract}}, nil -} - -type MercuryVerifierProxy struct { - address common.Address - abi abi.ABI - MercuryVerifierProxyCaller - MercuryVerifierProxyTransactor - MercuryVerifierProxyFilterer -} - -type MercuryVerifierProxyCaller struct { - contract *bind.BoundContract -} - -type MercuryVerifierProxyTransactor struct { - contract *bind.BoundContract -} - -type MercuryVerifierProxyFilterer struct { - contract *bind.BoundContract -} - -type MercuryVerifierProxySession struct { - Contract *MercuryVerifierProxy - CallOpts bind.CallOpts - TransactOpts bind.TransactOpts -} - -type MercuryVerifierProxyCallerSession struct { - Contract *MercuryVerifierProxyCaller - CallOpts bind.CallOpts -} - -type MercuryVerifierProxyTransactorSession struct { - Contract *MercuryVerifierProxyTransactor - TransactOpts bind.TransactOpts -} - -type MercuryVerifierProxyRaw struct { - Contract *MercuryVerifierProxy -} - -type MercuryVerifierProxyCallerRaw struct { - Contract *MercuryVerifierProxyCaller -} - -type MercuryVerifierProxyTransactorRaw struct { - Contract *MercuryVerifierProxyTransactor -} - -func NewMercuryVerifierProxy(address common.Address, backend bind.ContractBackend) (*MercuryVerifierProxy, error) { - abi, err := abi.JSON(strings.NewReader(MercuryVerifierProxyABI)) - if err != nil { - return nil, err - } - contract, err := bindMercuryVerifierProxy(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &MercuryVerifierProxy{address: address, abi: abi, MercuryVerifierProxyCaller: MercuryVerifierProxyCaller{contract: contract}, MercuryVerifierProxyTransactor: MercuryVerifierProxyTransactor{contract: contract}, MercuryVerifierProxyFilterer: MercuryVerifierProxyFilterer{contract: contract}}, nil -} - -func NewMercuryVerifierProxyCaller(address common.Address, caller bind.ContractCaller) (*MercuryVerifierProxyCaller, error) { - contract, err := bindMercuryVerifierProxy(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &MercuryVerifierProxyCaller{contract: contract}, nil -} - -func NewMercuryVerifierProxyTransactor(address common.Address, transactor bind.ContractTransactor) (*MercuryVerifierProxyTransactor, error) { - contract, err := bindMercuryVerifierProxy(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &MercuryVerifierProxyTransactor{contract: contract}, nil -} - -func NewMercuryVerifierProxyFilterer(address common.Address, filterer bind.ContractFilterer) (*MercuryVerifierProxyFilterer, error) { - contract, err := bindMercuryVerifierProxy(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &MercuryVerifierProxyFilterer{contract: contract}, nil -} - -func bindMercuryVerifierProxy(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := MercuryVerifierProxyMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _MercuryVerifierProxy.Contract.MercuryVerifierProxyCaller.contract.Call(opts, result, method, params...) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.MercuryVerifierProxyTransactor.contract.Transfer(opts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.MercuryVerifierProxyTransactor.contract.Transact(opts, method, params...) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _MercuryVerifierProxy.Contract.contract.Call(opts, result, method, params...) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.contract.Transfer(opts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.contract.Transact(opts, method, params...) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) { - var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "getVerifier", configDigest) - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) GetVerifier(configDigest [32]byte) (common.Address, error) { - return _MercuryVerifierProxy.Contract.GetVerifier(&_MercuryVerifierProxy.CallOpts, configDigest) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) GetVerifier(configDigest [32]byte) (common.Address, error) { - return _MercuryVerifierProxy.Contract.GetVerifier(&_MercuryVerifierProxy.CallOpts, configDigest) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _MercuryVerifierProxy.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 (_MercuryVerifierProxy *MercuryVerifierProxySession) Owner() (common.Address, error) { - return _MercuryVerifierProxy.Contract.Owner(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) Owner() (common.Address, error) { - return _MercuryVerifierProxy.Contract.Owner(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) SAccessController(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "s_accessController") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) SAccessController() (common.Address, error) { - return _MercuryVerifierProxy.Contract.SAccessController(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) SAccessController() (common.Address, error) { - return _MercuryVerifierProxy.Contract.SAccessController(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) SFeeManager(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "s_feeManager") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) SFeeManager() (common.Address, error) { - return _MercuryVerifierProxy.Contract.SFeeManager(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) SFeeManager() (common.Address, error) { - return _MercuryVerifierProxy.Contract.SFeeManager(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCaller) TypeAndVersion(opts *bind.CallOpts) (string, error) { - var out []interface{} - err := _MercuryVerifierProxy.contract.Call(opts, &out, "typeAndVersion") - - if err != nil { - return *new(string), err - } - - out0 := *abi.ConvertType(out[0], new(string)).(*string) - - return out0, err - -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) TypeAndVersion() (string, error) { - return _MercuryVerifierProxy.Contract.TypeAndVersion(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyCallerSession) TypeAndVersion() (string, error) { - return _MercuryVerifierProxy.Contract.TypeAndVersion(&_MercuryVerifierProxy.CallOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "acceptOwnership") -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) AcceptOwnership() (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.AcceptOwnership(&_MercuryVerifierProxy.TransactOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) AcceptOwnership() (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.AcceptOwnership(&_MercuryVerifierProxy.TransactOpts) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) InitializeVerifier(opts *bind.TransactOpts, verifierAddress common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "initializeVerifier", verifierAddress) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) InitializeVerifier(verifierAddress common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.InitializeVerifier(&_MercuryVerifierProxy.TransactOpts, verifierAddress) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) InitializeVerifier(verifierAddress common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.InitializeVerifier(&_MercuryVerifierProxy.TransactOpts, verifierAddress) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) SetAccessController(opts *bind.TransactOpts, accessController common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "setAccessController", accessController) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) SetAccessController(accessController common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetAccessController(&_MercuryVerifierProxy.TransactOpts, accessController) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetAccessController(accessController common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetAccessController(&_MercuryVerifierProxy.TransactOpts, accessController) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) SetFeeManager(opts *bind.TransactOpts, feeManager common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "setFeeManager", feeManager) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) SetFeeManager(feeManager common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetFeeManager(&_MercuryVerifierProxy.TransactOpts, feeManager) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetFeeManager(feeManager common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetFeeManager(&_MercuryVerifierProxy.TransactOpts, feeManager) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "setVerifier", currentConfigDigest, newConfigDigest, addressesAndWeights) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetVerifier(&_MercuryVerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest, addressesAndWeights) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) SetVerifier(currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.SetVerifier(&_MercuryVerifierProxy.TransactOpts, currentConfigDigest, newConfigDigest, addressesAndWeights) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "transferOwnership", to) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.TransferOwnership(&_MercuryVerifierProxy.TransactOpts, to) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.TransferOwnership(&_MercuryVerifierProxy.TransactOpts, to) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) UnsetVerifier(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "unsetVerifier", configDigest) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) UnsetVerifier(configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.UnsetVerifier(&_MercuryVerifierProxy.TransactOpts, configDigest) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) UnsetVerifier(configDigest [32]byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.UnsetVerifier(&_MercuryVerifierProxy.TransactOpts, configDigest) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactor) Verify(opts *bind.TransactOpts, payload []byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.contract.Transact(opts, "verify", payload) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxySession) Verify(payload []byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.Verify(&_MercuryVerifierProxy.TransactOpts, payload) -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyTransactorSession) Verify(payload []byte) (*types.Transaction, error) { - return _MercuryVerifierProxy.Contract.Verify(&_MercuryVerifierProxy.TransactOpts, payload) -} - -type MercuryVerifierProxyAccessControllerSetIterator struct { - Event *MercuryVerifierProxyAccessControllerSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyAccessControllerSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyAccessControllerSet) - 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(MercuryVerifierProxyAccessControllerSet) - 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 *MercuryVerifierProxyAccessControllerSetIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyAccessControllerSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyAccessControllerSet struct { - OldAccessController common.Address - NewAccessController common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterAccessControllerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyAccessControllerSetIterator, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "AccessControllerSet") - if err != nil { - return nil, err - } - return &MercuryVerifierProxyAccessControllerSetIterator{contract: _MercuryVerifierProxy.contract, event: "AccessControllerSet", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchAccessControllerSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyAccessControllerSet) (event.Subscription, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "AccessControllerSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyAccessControllerSet) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "AccessControllerSet", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseAccessControllerSet(log types.Log) (*MercuryVerifierProxyAccessControllerSet, error) { - event := new(MercuryVerifierProxyAccessControllerSet) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "AccessControllerSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierProxyFeeManagerSetIterator struct { - Event *MercuryVerifierProxyFeeManagerSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyFeeManagerSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyFeeManagerSet) - 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(MercuryVerifierProxyFeeManagerSet) - 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 *MercuryVerifierProxyFeeManagerSetIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyFeeManagerSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyFeeManagerSet struct { - OldFeeManager common.Address - NewFeeManager common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterFeeManagerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyFeeManagerSetIterator, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "FeeManagerSet") - if err != nil { - return nil, err - } - return &MercuryVerifierProxyFeeManagerSetIterator{contract: _MercuryVerifierProxy.contract, event: "FeeManagerSet", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchFeeManagerSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyFeeManagerSet) (event.Subscription, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "FeeManagerSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyFeeManagerSet) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "FeeManagerSet", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseFeeManagerSet(log types.Log) (*MercuryVerifierProxyFeeManagerSet, error) { - event := new(MercuryVerifierProxyFeeManagerSet) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "FeeManagerSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierProxyOwnershipTransferRequestedIterator struct { - Event *MercuryVerifierProxyOwnershipTransferRequested - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyOwnershipTransferRequestedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyOwnershipTransferRequested) - 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(MercuryVerifierProxyOwnershipTransferRequested) - 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 *MercuryVerifierProxyOwnershipTransferRequestedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyOwnershipTransferRequestedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyOwnershipTransferRequested struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierProxyOwnershipTransferRequestedIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return &MercuryVerifierProxyOwnershipTransferRequestedIterator{contract: _MercuryVerifierProxy.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyOwnershipTransferRequested) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseOwnershipTransferRequested(log types.Log) (*MercuryVerifierProxyOwnershipTransferRequested, error) { - event := new(MercuryVerifierProxyOwnershipTransferRequested) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierProxyOwnershipTransferredIterator struct { - Event *MercuryVerifierProxyOwnershipTransferred - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyOwnershipTransferredIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyOwnershipTransferred) - 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(MercuryVerifierProxyOwnershipTransferred) - 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 *MercuryVerifierProxyOwnershipTransferredIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyOwnershipTransferred struct { - From common.Address - To common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierProxyOwnershipTransferredIterator, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return &MercuryVerifierProxyOwnershipTransferredIterator{contract: _MercuryVerifierProxy.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { - - var fromRule []interface{} - for _, fromItem := range from { - fromRule = append(fromRule, fromItem) - } - var toRule []interface{} - for _, toItem := range to { - toRule = append(toRule, toItem) - } - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyOwnershipTransferred) - if err := _MercuryVerifierProxy.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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseOwnershipTransferred(log types.Log) (*MercuryVerifierProxyOwnershipTransferred, error) { - event := new(MercuryVerifierProxyOwnershipTransferred) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierProxyVerifierInitializedIterator struct { - Event *MercuryVerifierProxyVerifierInitialized - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyVerifierInitializedIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyVerifierInitialized) - 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(MercuryVerifierProxyVerifierInitialized) - 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 *MercuryVerifierProxyVerifierInitializedIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyVerifierInitializedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyVerifierInitialized struct { - VerifierAddress common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterVerifierInitialized(opts *bind.FilterOpts) (*MercuryVerifierProxyVerifierInitializedIterator, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "VerifierInitialized") - if err != nil { - return nil, err - } - return &MercuryVerifierProxyVerifierInitializedIterator{contract: _MercuryVerifierProxy.contract, event: "VerifierInitialized", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchVerifierInitialized(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyVerifierInitialized) (event.Subscription, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "VerifierInitialized") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyVerifierInitialized) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "VerifierInitialized", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseVerifierInitialized(log types.Log) (*MercuryVerifierProxyVerifierInitialized, error) { - event := new(MercuryVerifierProxyVerifierInitialized) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "VerifierInitialized", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierProxyVerifierSetIterator struct { - Event *MercuryVerifierProxyVerifierSet - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyVerifierSetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyVerifierSet) - 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(MercuryVerifierProxyVerifierSet) - 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 *MercuryVerifierProxyVerifierSetIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyVerifierSetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyVerifierSet struct { - OldConfigDigest [32]byte - NewConfigDigest [32]byte - VerifierAddress common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterVerifierSet(opts *bind.FilterOpts) (*MercuryVerifierProxyVerifierSetIterator, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "VerifierSet") - if err != nil { - return nil, err - } - return &MercuryVerifierProxyVerifierSetIterator{contract: _MercuryVerifierProxy.contract, event: "VerifierSet", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchVerifierSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyVerifierSet) (event.Subscription, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "VerifierSet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyVerifierSet) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "VerifierSet", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseVerifierSet(log types.Log) (*MercuryVerifierProxyVerifierSet, error) { - event := new(MercuryVerifierProxyVerifierSet) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "VerifierSet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -type MercuryVerifierProxyVerifierUnsetIterator struct { - Event *MercuryVerifierProxyVerifierUnset - - contract *bind.BoundContract - event string - - logs chan types.Log - sub ethereum.Subscription - done bool - fail error -} - -func (it *MercuryVerifierProxyVerifierUnsetIterator) Next() bool { - - if it.fail != nil { - return false - } - - if it.done { - select { - case log := <-it.logs: - it.Event = new(MercuryVerifierProxyVerifierUnset) - 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(MercuryVerifierProxyVerifierUnset) - 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 *MercuryVerifierProxyVerifierUnsetIterator) Error() error { - return it.fail -} - -func (it *MercuryVerifierProxyVerifierUnsetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -type MercuryVerifierProxyVerifierUnset struct { - ConfigDigest [32]byte - VerifierAddress common.Address - Raw types.Log -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) FilterVerifierUnset(opts *bind.FilterOpts) (*MercuryVerifierProxyVerifierUnsetIterator, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.FilterLogs(opts, "VerifierUnset") - if err != nil { - return nil, err - } - return &MercuryVerifierProxyVerifierUnsetIterator{contract: _MercuryVerifierProxy.contract, event: "VerifierUnset", logs: logs, sub: sub}, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) WatchVerifierUnset(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyVerifierUnset) (event.Subscription, error) { - - logs, sub, err := _MercuryVerifierProxy.contract.WatchLogs(opts, "VerifierUnset") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - - event := new(MercuryVerifierProxyVerifierUnset) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "VerifierUnset", 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 (_MercuryVerifierProxy *MercuryVerifierProxyFilterer) ParseVerifierUnset(log types.Log) (*MercuryVerifierProxyVerifierUnset, error) { - event := new(MercuryVerifierProxyVerifierUnset) - if err := _MercuryVerifierProxy.contract.UnpackLog(event, "VerifierUnset", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -func (_MercuryVerifierProxy *MercuryVerifierProxy) ParseLog(log types.Log) (generated.AbigenLog, error) { - switch log.Topics[0] { - case _MercuryVerifierProxy.abi.Events["AccessControllerSet"].ID: - return _MercuryVerifierProxy.ParseAccessControllerSet(log) - case _MercuryVerifierProxy.abi.Events["FeeManagerSet"].ID: - return _MercuryVerifierProxy.ParseFeeManagerSet(log) - case _MercuryVerifierProxy.abi.Events["OwnershipTransferRequested"].ID: - return _MercuryVerifierProxy.ParseOwnershipTransferRequested(log) - case _MercuryVerifierProxy.abi.Events["OwnershipTransferred"].ID: - return _MercuryVerifierProxy.ParseOwnershipTransferred(log) - case _MercuryVerifierProxy.abi.Events["VerifierInitialized"].ID: - return _MercuryVerifierProxy.ParseVerifierInitialized(log) - case _MercuryVerifierProxy.abi.Events["VerifierSet"].ID: - return _MercuryVerifierProxy.ParseVerifierSet(log) - case _MercuryVerifierProxy.abi.Events["VerifierUnset"].ID: - return _MercuryVerifierProxy.ParseVerifierUnset(log) - - default: - return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) - } -} - -func (MercuryVerifierProxyAccessControllerSet) Topic() common.Hash { - return common.HexToHash("0x953e92b1a6442e9c3242531154a3f6f6eb00b4e9c719ba8118fa6235e4ce89b6") -} - -func (MercuryVerifierProxyFeeManagerSet) Topic() common.Hash { - return common.HexToHash("0x04628abcaa6b1674651352125cb94b65b289145bc2bc4d67720bb7d966372f03") -} - -func (MercuryVerifierProxyOwnershipTransferRequested) Topic() common.Hash { - return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") -} - -func (MercuryVerifierProxyOwnershipTransferred) Topic() common.Hash { - return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") -} - -func (MercuryVerifierProxyVerifierInitialized) Topic() common.Hash { - return common.HexToHash("0x1f2cd7c97f4d801b5efe26cc409617c1fd6c5ef786e79aacb90af40923e4e8e9") -} - -func (MercuryVerifierProxyVerifierSet) Topic() common.Hash { - return common.HexToHash("0xbeb513e532542a562ac35699e7cd9ae7d198dcd3eee15bada6c857d28ceaddcf") -} - -func (MercuryVerifierProxyVerifierUnset) Topic() common.Hash { - return common.HexToHash("0x11dc15c4b8ac2b183166cc8427e5385a5ece8308217a4217338c6a7614845c4c") -} - -func (_MercuryVerifierProxy *MercuryVerifierProxy) Address() common.Address { - return _MercuryVerifierProxy.address -} - -type MercuryVerifierProxyInterface interface { - GetVerifier(opts *bind.CallOpts, configDigest [32]byte) (common.Address, error) - - Owner(opts *bind.CallOpts) (common.Address, error) - - SAccessController(opts *bind.CallOpts) (common.Address, error) - - SFeeManager(opts *bind.CallOpts) (common.Address, error) - - TypeAndVersion(opts *bind.CallOpts) (string, error) - - AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) - - InitializeVerifier(opts *bind.TransactOpts, verifierAddress common.Address) (*types.Transaction, error) - - SetAccessController(opts *bind.TransactOpts, accessController common.Address) (*types.Transaction, error) - - SetFeeManager(opts *bind.TransactOpts, feeManager common.Address) (*types.Transaction, error) - - SetVerifier(opts *bind.TransactOpts, currentConfigDigest [32]byte, newConfigDigest [32]byte, addressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) - - TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) - - UnsetVerifier(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) - - Verify(opts *bind.TransactOpts, payload []byte) (*types.Transaction, error) - - FilterAccessControllerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyAccessControllerSetIterator, error) - - WatchAccessControllerSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyAccessControllerSet) (event.Subscription, error) - - ParseAccessControllerSet(log types.Log) (*MercuryVerifierProxyAccessControllerSet, error) - - FilterFeeManagerSet(opts *bind.FilterOpts) (*MercuryVerifierProxyFeeManagerSetIterator, error) - - WatchFeeManagerSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyFeeManagerSet) (event.Subscription, error) - - ParseFeeManagerSet(log types.Log) (*MercuryVerifierProxyFeeManagerSet, error) - - FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierProxyOwnershipTransferRequestedIterator, error) - - WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferRequested(log types.Log) (*MercuryVerifierProxyOwnershipTransferRequested, error) - - FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*MercuryVerifierProxyOwnershipTransferredIterator, error) - - WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) - - ParseOwnershipTransferred(log types.Log) (*MercuryVerifierProxyOwnershipTransferred, error) - - FilterVerifierInitialized(opts *bind.FilterOpts) (*MercuryVerifierProxyVerifierInitializedIterator, error) - - WatchVerifierInitialized(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyVerifierInitialized) (event.Subscription, error) - - ParseVerifierInitialized(log types.Log) (*MercuryVerifierProxyVerifierInitialized, error) - - FilterVerifierSet(opts *bind.FilterOpts) (*MercuryVerifierProxyVerifierSetIterator, error) - - WatchVerifierSet(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyVerifierSet) (event.Subscription, error) - - ParseVerifierSet(log types.Log) (*MercuryVerifierProxyVerifierSet, error) - - FilterVerifierUnset(opts *bind.FilterOpts) (*MercuryVerifierProxyVerifierUnsetIterator, error) - - WatchVerifierUnset(opts *bind.WatchOpts, sink chan<- *MercuryVerifierProxyVerifierUnset) (event.Subscription, error) - - ParseVerifierUnset(log types.Log) (*MercuryVerifierProxyVerifierUnset, error) - - ParseLog(log types.Log) (generated.AbigenLog, error) - - Address() common.Address -} diff --git a/core/services/ocr2/plugins/mercury/integration_test.go b/core/services/ocr2/plugins/mercury/integration_test.go index abb5d26df61..1f919a27e5c 100644 --- a/core/services/ocr2/plugins/mercury/integration_test.go +++ b/core/services/ocr2/plugins/mercury/integration_test.go @@ -39,8 +39,8 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/bridges" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_verifier" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_verifier_proxy" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier_proxy" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" @@ -127,9 +127,9 @@ func TestIntegration_Mercury(t *testing.T) { t.Cleanup(stopMining) // Deploy config contract - verifierProxyAddr, _, verifierProxy, err := mercury_verifier_proxy.DeployMercuryVerifierProxy(steve, backend, common.Address{}) // zero address for access controller disables access control + verifierProxyAddr, _, verifierProxy, err := verifier_proxy.DeployVerifierProxy(steve, backend, common.Address{}) // zero address for access controller disables access control require.NoError(t, err) - verifierAddress, _, verifier, err := mercury_verifier.DeployMercuryVerifier(steve, backend, verifierProxyAddr) + verifierAddress, _, verifier, err := verifier.DeployVerifier(steve, backend, verifierProxyAddr) require.NoError(t, err) _, err = verifierProxy.InitializeVerifier(steve, verifierAddress) require.NoError(t, err) diff --git a/core/services/relay/evm/mercury/config_digest.go b/core/services/relay/evm/mercury/config_digest.go index 4fb57b75f90..b9431fe923f 100644 --- a/core/services/relay/evm/mercury/config_digest.go +++ b/core/services/relay/evm/mercury/config_digest.go @@ -12,11 +12,11 @@ import ( "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "github.com/smartcontractkit/wsrpc/credentials" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_exposed_verifier" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/exposed_verifier" ) func makeConfigDigestArgs() abi.Arguments { - abi, err := abi.JSON(strings.NewReader(mercury_exposed_verifier.MercuryExposedVerifierABI)) + abi, err := abi.JSON(strings.NewReader(exposed_verifier.ExposedVerifierABI)) if err != nil { // assertion panic(fmt.Sprintf("could not parse aggregator ABI: %s", err.Error())) diff --git a/core/services/relay/evm/mercury/config_digest_test.go b/core/services/relay/evm/mercury/config_digest_test.go index bfcbb7ad22a..3e94d075dce 100644 --- a/core/services/relay/evm/mercury/config_digest_test.go +++ b/core/services/relay/evm/mercury/config_digest_test.go @@ -18,7 +18,7 @@ import ( "github.com/smartcontractkit/wsrpc/credentials" "github.com/stretchr/testify/require" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_exposed_verifier" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/exposed_verifier" ) // Adapted from: https://github.com/smartcontractkit/offchain-reporting/blob/991ebe1462fd56826a1ddfb34287d542acb2baee/lib/offchainreporting2/chains/evmutil/config_digest_test.go @@ -32,7 +32,7 @@ func TestConfigCalculationMatches(t *testing.T) { core.GenesisAlloc{owner.From: {Balance: new(big.Int).Lsh(big.NewInt(1), 60)}}, ethconfig.Defaults.Miner.GasCeil, ) - _, _, eoa, err := mercury_exposed_verifier.DeployMercuryExposedVerifier( + _, _, eoa, err := exposed_verifier.DeployExposedVerifier( owner, backend, ) backend.Commit() diff --git a/core/services/relay/evm/mercury/config_poller.go b/core/services/relay/evm/mercury/config_poller.go index 59399070266..78bfc457f26 100644 --- a/core/services/relay/evm/mercury/config_poller.go +++ b/core/services/relay/evm/mercury/config_poller.go @@ -12,7 +12,7 @@ import ( ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_verifier" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) @@ -29,7 +29,7 @@ const ( func init() { var err error - verifierABI, err = abi.JSON(strings.NewReader(mercury_verifier.MercuryVerifierABI)) + verifierABI, err = abi.JSON(strings.NewReader(verifier.VerifierABI)) if err != nil { panic(err) } @@ -42,8 +42,8 @@ type FullConfigFromLog struct { feedID [32]byte } -func unpackLogData(d []byte) (*mercury_verifier.MercuryVerifierConfigSet, error) { - unpacked := new(mercury_verifier.MercuryVerifierConfigSet) +func unpackLogData(d []byte) (*verifier.VerifierConfigSet, error) { + unpacked := new(verifier.VerifierConfigSet) err := verifierABI.UnpackIntoInterface(unpacked, configSetEventName, d) if err != nil { diff --git a/core/services/relay/evm/mercury/helper_test.go b/core/services/relay/evm/mercury/helper_test.go index ca2b2123a1a..c696a66403c 100644 --- a/core/services/relay/evm/mercury/helper_test.go +++ b/core/services/relay/evm/mercury/helper_test.go @@ -15,8 +15,8 @@ import ( evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_verifier" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mercury_verifier_proxy" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier_proxy" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -27,7 +27,7 @@ type TestHarness struct { configPoller *ConfigPoller user *bind.TransactOpts backend *backends.SimulatedBackend - verifierContract *mercury_verifier.MercuryVerifier + verifierContract *verifier.Verifier logPoller logpoller.LogPoller eventBroadcaster *pgmocks.EventBroadcaster subscription *pgmocks.Subscription @@ -42,9 +42,9 @@ func SetupTH(t *testing.T, feedID common.Hash) TestHarness { user.From: {Balance: big.NewInt(1000000000000000000)}}, 5*ethconfig.Defaults.Miner.GasCeil) - proxyAddress, _, verifierProxy, err := mercury_verifier_proxy.DeployMercuryVerifierProxy(user, b, common.Address{}) + proxyAddress, _, verifierProxy, err := verifier_proxy.DeployVerifierProxy(user, b, common.Address{}) require.NoError(t, err, "failed to deploy test mercury verifier proxy contract") - verifierAddress, _, verifierContract, err := mercury_verifier.DeployMercuryVerifier(user, b, proxyAddress) + verifierAddress, _, verifierContract, err := verifier.DeployVerifier(user, b, proxyAddress) require.NoError(t, err, "failed to deploy test mercury verifier contract") _, err = verifierProxy.InitializeVerifier(user, verifierAddress) require.NoError(t, err) From 985168afc0abe573da44d3f84e8f668ac5f8612d Mon Sep 17 00:00:00 2001 From: Patrick Date: Mon, 14 Aug 2023 08:54:22 -0400 Subject: [PATCH 159/270] feature/simple-passwords-log: adding notification for SimplePasswords change (#10170) * feature/simple-passwords-log: adding notification for upcoming configuration change error logs for insecure configs on secure builds * feature/simple-passwords-log: reversing previous commit for develop From a4a10b2dd5d98174d095abff57c2719bf4369b3e Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Mon, 14 Aug 2023 16:21:23 +0300 Subject: [PATCH 160/270] TT-421 migrate forwarders (OCRv1/v2) to docker env (#10186) * TT-421 migrate forwarders (OCRv1/v2) to docker env * TT-421 fix flakes, always wait for contracts --- .../actions/ocr_helpers_local.go | 196 ++++++++++++++++-- integration-tests/docker/test_env/geth.go | 6 + .../docker/test_env/test_env_builder.go | 8 +- integration-tests/smoke/forwarder_ocr_test.go | 134 ++++-------- .../smoke/forwarders_ocr2_test.go | 86 ++++---- integration-tests/smoke/ocr_test.go | 2 +- integration-tests/types/config/node/core.go | 7 +- 7 files changed, 269 insertions(+), 170 deletions(-) diff --git a/integration-tests/actions/ocr_helpers_local.go b/integration-tests/actions/ocr_helpers_local.go index 1bee5703f27..13fc01dcea6 100644 --- a/integration-tests/actions/ocr_helpers_local.go +++ b/integration-tests/actions/ocr_helpers_local.go @@ -5,6 +5,8 @@ import ( "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/google/uuid" + "github.com/pkg/errors" + "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" "github.com/smartcontractkit/chainlink/integration-tests/client" @@ -58,7 +60,6 @@ func DeployOCRContractsLocal( numberOfContracts int, linkTokenContract contracts.LinkToken, contractDeployer contracts.ContractDeployer, - bootstrapNode *client.ChainlinkClient, workerNodes []*client.ChainlinkClient, client blockchain.EVMClient, ) ([]contracts.OffchainAggregator, error) { @@ -73,11 +74,9 @@ func DeployOCRContractsLocal( return nil, fmt.Errorf("OCR instance deployment have failed: %w", err) } ocrInstances = append(ocrInstances, ocrInstance) - if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some - err = client.WaitForEvents() - if err != nil { - return nil, fmt.Errorf("failed to wait for OCR contract deployments: %w", err) - } + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("failed to wait for OCR contract deployments: %w", err) } } err := client.WaitForEvents() @@ -97,29 +96,23 @@ func DeployOCRContractsLocal( } // Set Payees - for contractCount, ocrInstance := range ocrInstances { + for _, ocrInstance := range ocrInstances { err = ocrInstance.SetPayees(transmitters, payees) if err != nil { return nil, fmt.Errorf("error settings OCR payees: %w", err) } - if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some - err = client.WaitForEvents() - if err != nil { - return nil, fmt.Errorf("failed to wait for setting OCR payees: %w", err) - } + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("failed to wait for setting OCR payees: %w", err) } } - err = client.WaitForEvents() - if err != nil { - return nil, fmt.Errorf("error waiting for OCR contracts to set payees and transmitters: %w", err) - } // Set Config transmitterAddresses, err := ChainlinkNodeAddressesLocal(workerNodes) if err != nil { return nil, fmt.Errorf("getting node common addresses should not fail: %w", err) } - for contractCount, ocrInstance := range ocrInstances { + for _, ocrInstance := range ocrInstances { // Exclude the first node, which will be used as a bootstrapper err = ocrInstance.SetConfigLocal( workerNodes, @@ -129,11 +122,9 @@ func DeployOCRContractsLocal( if err != nil { return nil, fmt.Errorf("error setting OCR config for contract '%s': %w", ocrInstance.Address(), err) } - if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some - err = client.WaitForEvents() - if err != nil { - return nil, fmt.Errorf("failed to wait for setting OCR config: %w", err) - } + err = client.WaitForEvents() + if err != nil { + return nil, fmt.Errorf("failed to wait for setting OCR config: %w", err) } } err = client.WaitForEvents() @@ -270,3 +261,164 @@ func SetAllAdapterResponsesToTheSameValueLocal( } return eg.Wait() } + +func TrackForwarderLocal( + chainClient blockchain.EVMClient, + authorizedForwarder common.Address, + node *client.ChainlinkClient, +) error { + chainID := chainClient.GetChainID() + _, _, err := node.TrackForwarder(chainID, authorizedForwarder) + if err != nil { + return errors.Wrap(err, "failed to track forwarder") + } + log.Info().Str("NodeURL", node.Config.URL). + Str("ForwarderAddress", authorizedForwarder.Hex()). + Str("ChaindID", chainID.String()). + Msg("Forwarder tracked") + return nil +} + +func DeployOCRContractsForwarderFlowLocal( + numberOfContracts int, + linkTokenContract contracts.LinkToken, + contractDeployer contracts.ContractDeployer, + workerNodes []*client.ChainlinkClient, + forwarderAddresses []common.Address, + client blockchain.EVMClient, +) ([]contracts.OffchainAggregator, error) { + // Deploy contracts + var ocrInstances []contracts.OffchainAggregator + for contractCount := 0; contractCount < numberOfContracts; contractCount++ { + ocrInstance, err := contractDeployer.DeployOffChainAggregator( + linkTokenContract.Address(), + contracts.DefaultOffChainAggregatorOptions(), + ) + if err != nil { + return nil, errors.Wrap(err, "failed to deploy offchain aggregator") + } + ocrInstances = append(ocrInstances, ocrInstance) + err = client.WaitForEvents() + if err != nil { + return nil, err + } + } + if err := client.WaitForEvents(); err != nil { + return nil, err + } + + // Gather transmitter and address payees + var transmitters, payees []string + for _, forwarderCommonAddress := range forwarderAddresses { + forwarderAddress := forwarderCommonAddress.Hex() + transmitters = append(transmitters, forwarderAddress) + payees = append(payees, client.GetDefaultWallet().Address()) + } + + // Set Payees + for _, ocrInstance := range ocrInstances { + err := ocrInstance.SetPayees(transmitters, payees) + if err != nil { + return nil, errors.Wrap(err, "failed to set OCR payees") + } + if err := client.WaitForEvents(); err != nil { + return nil, err + } + } + if err := client.WaitForEvents(); err != nil { + return nil, err + } + + // Set Config + for _, ocrInstance := range ocrInstances { + // Exclude the first node, which will be used as a bootstrapper + err := ocrInstance.SetConfigLocal( + workerNodes, + contracts.DefaultOffChainAggregatorConfig(len(workerNodes)), + forwarderAddresses, + ) + if err != nil { + return nil, errors.Wrap(err, "failed to set on-chain config") + } + if err = client.WaitForEvents(); err != nil { + return nil, err + } + } + return ocrInstances, client.WaitForEvents() +} + +func CreateOCRJobsWithForwarderLocal( + ocrInstances []contracts.OffchainAggregator, + bootstrapNode *client.ChainlinkClient, + workerNodes []*client.ChainlinkClient, + mockValue int, + mockserver *ctfClient.MockserverClient, +) error { + for _, ocrInstance := range ocrInstances { + bootstrapP2PIds, err := bootstrapNode.MustReadP2PKeys() + if err != nil { + return err + } + bootstrapP2PId := bootstrapP2PIds.Data[0].Attributes.PeerID + bootstrapSpec := &client.OCRBootstrapJobSpec{ + Name: fmt.Sprintf("bootstrap-%s", uuid.New().String()), + ContractAddress: ocrInstance.Address(), + P2PPeerID: bootstrapP2PId, + IsBootstrapPeer: true, + } + _, err = bootstrapNode.MustCreateJob(bootstrapSpec) + if err != nil { + return err + } + + for _, node := range workerNodes { + nodeP2PIds, err := node.MustReadP2PKeys() + if err != nil { + return err + } + nodeP2PId := nodeP2PIds.Data[0].Attributes.PeerID + nodeTransmitterAddress, err := node.PrimaryEthAddress() + if err != nil { + return err + } + nodeOCRKeys, err := node.MustReadOCRKeys() + if err != nil { + return err + } + nodeOCRKeyId := nodeOCRKeys.Data[0].ID + + nodeContractPairID, err := BuildNodeContractPairIDLocal(node, ocrInstance) + if err != nil { + return err + } + bta := &client.BridgeTypeAttributes{ + Name: nodeContractPairID, + URL: fmt.Sprintf("%s/%s", mockserver.Config.ClusterURL, strings.TrimPrefix(nodeContractPairID, "/")), + } + err = SetAdapterResponseLocal(mockValue, ocrInstance, node, mockserver) + if err != nil { + return err + } + err = node.MustCreateBridge(bta) + if err != nil { + return err + } + + bootstrapPeers := []*client.ChainlinkClient{bootstrapNode} + ocrSpec := &client.OCRTaskJobSpec{ + ContractAddress: ocrInstance.Address(), + P2PPeerID: nodeP2PId, + P2PBootstrapPeers: bootstrapPeers, + KeyBundleID: nodeOCRKeyId, + TransmitterAddress: nodeTransmitterAddress, + ObservationSource: client.ObservationSourceSpecBridge(bta), + ForwardingAllowed: true, + } + _, err = node.MustCreateJob(ocrSpec) + if err != nil { + return err + } + } + } + return nil +} diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index b1f496db367..f71ca2ddf94 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -34,6 +34,7 @@ type Geth struct { InternalWsUrl string EthClient *blockchain.EthereumClient ContractDeployer contracts.ContractDeployer + ContractLoader contracts.ContractLoader } func NewGeth(networks []string, opts ...EnvComponentOption) *Geth { @@ -108,6 +109,11 @@ func (g *Geth) StartContainer() error { return err } g.ContractDeployer = cd + cl, err := contracts.NewContractLoader(bc) + if err != nil { + return err + } + g.ContractLoader = cl log.Info().Str("containerName", g.ContainerName). Str("internalHttpUrl", g.InternalHttpUrl). diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index bd28a1dabe4..3e73a0205a5 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -14,6 +14,7 @@ type CLTestEnvBuilder struct { hasLogWatch bool hasGeth bool hasMockServer bool + hasForwarders bool clNodeConfig *chainlink.Config clNodesCount int externalAdapterCount int @@ -40,6 +41,11 @@ func (b *CLTestEnvBuilder) WithCLNodes(clNodesCount int) *CLTestEnvBuilder { return b } +func (b *CLTestEnvBuilder) WithForwarders() *CLTestEnvBuilder { + b.hasForwarders = true + return b +} + func (b *CLTestEnvBuilder) WithFunding(eth *big.Float) *CLTestEnvBuilder { b.ETHFunds = eth return b @@ -137,7 +143,7 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e node.WithP2Pv1(), ) } - node.SetDefaultSimulatedGeth(cfg, te.Geth.InternalWsUrl, te.Geth.InternalHttpUrl) + node.SetDefaultSimulatedGeth(cfg, te.Geth.InternalWsUrl, te.Geth.InternalHttpUrl, b.hasForwarders) err := te.StartClNodes(cfg, b.clNodesCount) if err != nil { return te, err diff --git a/integration-tests/smoke/forwarder_ocr_test.go b/integration-tests/smoke/forwarder_ocr_test.go index bbcaedc9f10..330885581a6 100644 --- a/integration-tests/smoke/forwarder_ocr_test.go +++ b/integration-tests/smoke/forwarder_ocr_test.go @@ -1,139 +1,81 @@ package smoke import ( - "context" - "fmt" "math/big" - "strings" "testing" + "context" "github.com/ethereum/go-ethereum/common" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/stretchr/testify/require" ) func TestForwarderOCRBasic(t *testing.T) { t.Parallel() - testEnvironment, testNetwork := setupForwarderOCRTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithForwarders(). + WithCLNodes(6). + WithFunding(big.NewFloat(10)). + Build() + require.NoError(t, err) + env.ParallelTransactions(true) - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - contractLoader, err := contracts.NewContractLoader(chainClient) - require.NoError(t, err, "Loading contracts shouldn't fail") - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - bootstrapNode, workerNodes := chainlinkNodes[0], chainlinkNodes[1:] - workerNodeAddresses, err := actions.ChainlinkNodeAddresses(workerNodes) - require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Creating mockserver clients shouldn't fail") + nodeClients := env.GetAPIs() + bootstrapNode, workerNodes := nodeClients[0], nodeClients[1:] - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - chainClient.ParallelTransactions(true) + workerNodeAddresses, err := actions.ChainlinkNodeAddressesLocal(workerNodes) + require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") - linkTokenContract, err := contractDeployer.DeployLinkTokenContract() + linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodes(workerNodes, chainClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") operators, authorizedForwarders, _ := actions.DeployForwarderContracts( - t, contractDeployer, linkTokenContract, chainClient, len(workerNodes), + t, env.Geth.ContractDeployer, linkTokenContract, env.Geth.EthClient, len(workerNodes), ) for i := range workerNodes { actions.AcceptAuthorizedReceiversOperator( - t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, chainClient, contractLoader, + t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, env.Geth.EthClient, env.Geth.ContractLoader, ) require.NoError(t, err, "Accepting Authorize Receivers on Operator shouldn't fail") - actions.TrackForwarder(t, chainClient, authorizedForwarders[i], workerNodes[i]) - err = chainClient.WaitForEvents() + err = actions.TrackForwarderLocal(env.Geth.EthClient, authorizedForwarders[i], workerNodes[i]) + require.NoError(t, err) + err = env.Geth.EthClient.WaitForEvents() } - ocrInstances := actions.DeployOCRContractsForwarderFlow( - t, 1, linkTokenContract, contractDeployer, workerNodes, authorizedForwarders, chainClient, + ocrInstances, err := actions.DeployOCRContractsForwarderFlowLocal( + 1, + linkTokenContract, + env.Geth.ContractDeployer, + workerNodes, + authorizedForwarders, + env.Geth.EthClient, ) - err = chainClient.WaitForEvents() - require.NoError(t, err, "Error waiting for events") - actions.CreateOCRJobsWithForwarder(t, ocrInstances, bootstrapNode, workerNodes, 5, mockServer) - err = actions.StartNewRound(1, ocrInstances, chainClient) + err = actions.CreateOCRJobsWithForwarderLocal(ocrInstances, bootstrapNode, workerNodes, 5, env.MockServer.Client) + require.NoError(t, err, "failed to setup forwarder jobs") + err = actions.StartNewRound(1, ocrInstances, env.Geth.EthClient) require.NoError(t, err) - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") + //time.Sleep(999 * time.Second) answer, err := ocrInstances[0].GetLatestAnswer(context.Background()) require.NoError(t, err, "Getting latest answer from OCR contract shouldn't fail") require.Equal(t, int64(5), answer.Int64(), "Expected latest answer from OCR contract to be 5 but got %d", answer.Int64()) - err = actions.SetAllAdapterResponsesToTheSameValue(10, ocrInstances, workerNodes, mockServer) + err = actions.SetAllAdapterResponsesToTheSameValueLocal(10, ocrInstances, workerNodes, env.MockServer.Client) require.NoError(t, err) - err = actions.StartNewRound(2, ocrInstances, chainClient) + err = actions.StartNewRound(2, ocrInstances, env.Geth.EthClient) require.NoError(t, err) - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") answer, err = ocrInstances[0].GetLatestAnswer(context.Background()) require.NoError(t, err, "Error getting latest OCR answer") require.Equal(t, int64(10), answer.Int64(), "Expected latest answer from OCR contract to be 10 but got %d", answer.Int64()) } - -func setupForwarderOCRTest(t *testing.T) (testEnvironment *environment.Environment, testNetwork blockchain.EVMNetwork) { - testNetwork = networks.SelectedNetwork - evmConfig := ethereum.New(nil) - if !testNetwork.Simulated { - evmConfig = ethereum.New(ðereum.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) - } - baseTOML := `[OCR] -Enabled = true - -[Feature] -LogPoller = true - -[P2P] -[P2P.V1] -Enabled = true -ListenIP = '0.0.0.0' -ListenPort = 6690` - networkDetailTOML := `[EVM.Transactions] -ForwardersEnabled = true` - cd, err := chainlink.NewDeployment(6, map[string]interface{}{ - "toml": client.AddNetworkDetailedConfig(baseTOML, networkDetailTOML, testNetwork), - }) - require.NoError(t, err, "Error creating chainlink deployment") - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-ocr-forwarder-%s", strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(evmConfig). - AddHelmCharts(cd) - err = testEnvironment.Run() - require.NoError(t, err, "Error running test environment") - return testEnvironment, testNetwork -} diff --git a/integration-tests/smoke/forwarders_ocr2_test.go b/integration-tests/smoke/forwarders_ocr2_test.go index 2674067cf8b..3676072c3f4 100644 --- a/integration-tests/smoke/forwarders_ocr2_test.go +++ b/integration-tests/smoke/forwarders_ocr2_test.go @@ -8,61 +8,50 @@ import ( "time" "github.com/ethereum/go-ethereum/common" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" - "github.com/smartcontractkit/chainlink-testing-framework/utils" - "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" + "github.com/stretchr/testify/require" ) func TestForwarderOCR2Basic(t *testing.T) { t.Parallel() - testEnvironment, testNetwork := setupOCR2Test(t, true) - if testEnvironment.WillUseRemoteRunner() { - return - } + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodeConfig(node.NewConfig(node.BaseConf, + node.WithOCR2(), + node.WithP2Pv2(), + )). + WithForwarders(). + WithCLNodes(6). + WithFunding(big.NewFloat(10)). + Build() + require.NoError(t, err) + env.ParallelTransactions(true) + + nodeClients := env.GetAPIs() + bootstrapNode, workerNodes := nodeClients[0], nodeClients[1:] - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err := contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - contractLoader, err := contracts.NewContractLoader(chainClient) - require.NoError(t, err, "Loading contracts shouldn't fail") - - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - bootstrapNode, workerNodes := chainlinkNodes[0], chainlinkNodes[1:] - workerNodeAddresses, err := actions.ChainlinkNodeAddresses(workerNodes) + workerNodeAddresses, err := actions.ChainlinkNodeAddressesLocal(workerNodes) require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") - mockServer, err := ctfClient.ConnectMockServer(testEnvironment) - require.NoError(t, err, "Creating mockserver clients shouldn't fail") - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - chainClient.ParallelTransactions(true) - - linkTokenContract, err := contractDeployer.DeployLinkTokenContract() + + linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodes(workerNodes, chainClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") operators, authorizedForwarders, _ := actions.DeployForwarderContracts( - t, contractDeployer, linkTokenContract, chainClient, len(workerNodes), + t, env.Geth.ContractDeployer, linkTokenContract, env.Geth.EthClient, len(workerNodes), ) for i := range workerNodes { - actions.AcceptAuthorizedReceiversOperator(t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, chainClient, contractLoader) + actions.AcceptAuthorizedReceiversOperator(t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, env.Geth.EthClient, env.Geth.ContractLoader) require.NoError(t, err, "Accepting Authorized Receivers on Operator shouldn't fail") - actions.TrackForwarder(t, chainClient, authorizedForwarders[i], workerNodes[i]) - err = chainClient.WaitForEvents() - + err = actions.TrackForwarderLocal(env.Geth.EthClient, authorizedForwarders[i], workerNodes[i]) + require.NoError(t, err, "failed to track forwarders") + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") } @@ -72,25 +61,24 @@ func TestForwarderOCR2Basic(t *testing.T) { transmitters = append(transmitters, forwarderCommonAddress.Hex()) } - ocrInstances, err := actions.DeployOCRv2Contracts(1, linkTokenContract, contractDeployer, transmitters, chainClient) - + ocrInstances, err := actions.DeployOCRv2Contracts(1, linkTokenContract, env.Geth.ContractDeployer, transmitters, env.Geth.EthClient) require.NoError(t, err, "Error deploying OCRv2 contracts with forwarders") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") - err = actions.CreateOCRv2Jobs(ocrInstances, bootstrapNode, workerNodes, mockServer, "ocr2", 5, chainClient.GetChainID().Uint64(), true) + err = actions.CreateOCRv2JobsLocal(ocrInstances, bootstrapNode, workerNodes, env.MockServer.Client, "ocr2", 5, env.Geth.EthClient.GetChainID().Uint64(), true) require.NoError(t, err, "Error creating OCRv2 jobs with forwarders") - err = chainClient.WaitForEvents() + err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") - ocrv2Config, err := actions.BuildMedianOCR2Config(workerNodes) + ocrv2Config, err := actions.BuildMedianOCR2ConfigLocal(workerNodes) require.NoError(t, err, "Error building OCRv2 config") ocrv2Config.Transmitters = authorizedForwarders - err = actions.ConfigureOCRv2AggregatorContracts(chainClient, ocrv2Config, ocrInstances) + err = actions.ConfigureOCRv2AggregatorContracts(env.Geth.EthClient, ocrv2Config, ocrInstances) require.NoError(t, err, "Error configuring OCRv2 aggregator contracts") - err = actions.StartNewOCR2Round(1, ocrInstances, chainClient, time.Minute*10) + err = actions.StartNewOCR2Round(1, ocrInstances, env.Geth.EthClient, time.Minute*10) require.NoError(t, err) answer, err := ocrInstances[0].GetLatestAnswer(context.Background()) @@ -99,9 +87,9 @@ func TestForwarderOCR2Basic(t *testing.T) { for i := 2; i <= 3; i++ { ocrRoundVal := (5 + i) % 10 - err = mockServer.SetValuePath("ocr2", ocrRoundVal) + err = env.MockServer.Client.SetValuePath("ocr2", ocrRoundVal) require.NoError(t, err) - err = actions.StartNewOCR2Round(int64(i), ocrInstances, chainClient, time.Minute*10) + err = actions.StartNewOCR2Round(int64(i), ocrInstances, env.Geth.EthClient, time.Minute*10) require.NoError(t, err) answer, err = ocrInstances[0].GetLatestAnswer(context.Background()) diff --git a/integration-tests/smoke/ocr_test.go b/integration-tests/smoke/ocr_test.go index b9f2365bb72..6219e0e908d 100644 --- a/integration-tests/smoke/ocr_test.go +++ b/integration-tests/smoke/ocr_test.go @@ -30,7 +30,7 @@ func TestOCRBasic(t *testing.T) { err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") - ocrInstances, err := actions.DeployOCRContractsLocal(1, linkTokenContract, env.Geth.ContractDeployer, bootstrapNode, workerNodes, env.Geth.EthClient) + ocrInstances, err := actions.DeployOCRContractsLocal(1, linkTokenContract, env.Geth.ContractDeployer, workerNodes, env.Geth.EthClient) require.NoError(t, err) err = env.Geth.EthClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go index a4aeb1b7edd..e7aa0b7f74b 100644 --- a/integration-tests/types/config/node/core.go +++ b/integration-tests/types/config/node/core.go @@ -93,7 +93,7 @@ func WithP2Pv2() NodeConfigOpt { } } -func SetDefaultSimulatedGeth(cfg *chainlink.Config, ws, http string) { +func SetDefaultSimulatedGeth(cfg *chainlink.Config, ws, http string, forwarders bool) { if cfg.EVM == nil { cfg.EVM = evmcfg.EVMConfigs{ { @@ -113,6 +113,11 @@ func SetDefaultSimulatedGeth(cfg *chainlink.Config, ws, http string) { }, }, } + if forwarders { + cfg.EVM[0].Transactions = evmcfg.Transactions{ + ForwardersEnabled: ptr(true), + } + } } } From 51632e392c47ba3aac7a21eee3aa5a7a47f727f6 Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Mon, 14 Aug 2023 15:58:16 +0200 Subject: [PATCH 161/270] fix wrong hash reference (#10187) --- contracts/scripts/requirements.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contracts/scripts/requirements.txt b/contracts/scripts/requirements.txt index 5a6256f6fc9..50cda389b7b 100644 --- a/contracts/scripts/requirements.txt +++ b/contracts/scripts/requirements.txt @@ -1,3 +1,3 @@ solc-select==1.0.4 --hash=sha256:db7b9de009af6de3a5416b80bbe5b6d636bf314703c016319b8c1231e248a6c7 pycryptodome==3.18.0 --hash=sha256:c9adee653fc882d98956e33ca2c1fb582e23a8af7ac82fee75bd6113c55a0413 -packaging==23.1 --hash=sha256:7c6658d258d7971c5eb0d9b69fa9265879ec9a9158031206d47800ae2213 \ No newline at end of file +packaging==23.1 --hash=sha256:a392980d2b6cffa644431898be54b0045151319d1e7ec34f0cfed48767dd334f \ No newline at end of file From 3df94ec152a471416b713aa096a6c6d515dc8ed0 Mon Sep 17 00:00:00 2001 From: Tate Date: Mon, 14 Aug 2023 13:15:22 -0600 Subject: [PATCH 162/270] [TT-415] keepers docker migration (#10155) * [TT-415] Keepers E2E Test Docker Migration * review comment fixes --- .github/workflows/integration-tests.yml | 212 ++++++++- .../actions/keeper_helpers_local.go | 58 +++ integration-tests/docker/test_env/cl_node.go | 2 +- integration-tests/docker/test_env/geth.go | 5 +- .../docker/test_env/mockserver.go | 2 +- integration-tests/docker/test_env/postgres.go | 2 +- .../docker/test_env/test_env_builder.go | 10 +- integration-tests/smoke/keeper_test.go | 442 ++++++++---------- 8 files changed, 454 insertions(+), 279 deletions(-) create mode 100644 integration-tests/actions/keeper_helpers_local.go diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index ea1a2e77def..09eece04f78 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -159,6 +159,89 @@ jobs: nodes: 9 os: ubuntu-latest pyroscope_env: ci-smoke-automation-evm-simulated + # temporarily disabled + # - name: ocr2vrf + # nodes: 2 + # os: ubuntu-latest + # pyroscope_env: ci-smoke-ocr2vrf-evm-simulated + runs-on: ${{ matrix.product.os }} + name: ETH Smoke Tests ${{ matrix.product.name }} + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + with: + ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} + ## Run this step when changes that require tests to be run are made + - name: Run Tests + if: needs.changes.outputs.src == 'true' + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 + env: + TESTCONTAINERS_RYUK_DISABLED: true + PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 + PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} + PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }} + with: + test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json -test.parallel=${{ matrix.product.nodes }} ./smoke/${{ matrix.product.name }}_test.go 2>&1 | tee /tmp/gotest.log | gotestfmt + test_download_vendor_packages_command: cd ./integration-tests && go mod download + cl_repo: ${{ env.CHAINLINK_IMAGE }} + cl_image_tag: ${{ github.sha }} + aws_registries: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} + artifacts_location: ./integration-tests/smoke/logs + publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} + token: ${{ secrets.GITHUB_TOKEN }} + go_mod_path: ./integration-tests/go.mod + matrix_id: ${{ matrix.product.name }} + QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} + QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} + QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} + + ## Run this step when changes that do not need the test to run are made + - name: Run Setup + if: needs.changes.outputs.src == 'false' + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.6 + with: + test_download_vendor_packages_command: cd ./integration-tests && go mod download + go_mod_path: ./integration-tests/go.mod + QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} + QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} + QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} + + - name: Upload test log + uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce # v3.1.2 + if: failure() + with: + name: test-log-${{ matrix.product.name }} + path: /tmp/gotest.log + retention-days: 7 + continue-on-error: true + - name: Collect Metrics + if: always() + id: collect-gha-metrics + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + with: + basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} + hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} + this-job-name: ETH Smoke Tests ${{ matrix.product.name }} + test-results-file: '{"testType":"go","filePath":"/tmp/gotest.log"}' + continue-on-error: true + + eth-smoke-tests-matrix-docker: + environment: integration + permissions: + checks: write + pull-requests: write + id-token: write + contents: read + needs: [build-chainlink, changes] + env: + SELECTED_NETWORKS: SIMULATED,SIMULATED_1,SIMULATED_2 + CHAINLINK_COMMIT_SHA: ${{ github.sha }} + CHAINLINK_ENV_USER: ${{ github.actor }} + TEST_LOG_LEVEL: debug + strategy: + fail-fast: false + matrix: + product: - name: cron nodes: 1 os: ubuntu-latest @@ -167,14 +250,6 @@ jobs: nodes: 1 os: ubuntu-latest pyroscope_env: "" - - name: keeper - nodes: 30 - os: ubuntu20.04-4cores-16GB - pyroscope_env: ci-smoke-keeper-evm-simulated - - name: forwarder_ocr - nodes: 1 - os: ubuntu-latest - pyroscope_env: ci-smoke-forwarder-ocr-evm-simulated - name: ocr nodes: 1 os: ubuntu-latest @@ -195,11 +270,106 @@ jobs: nodes: 1 os: ubuntu-latest pyroscope_env: ci-smoke-vrf2-evm-simulated - # temporarily disabled - # - name: ocr2vrf - # nodes: 2 - # os: ubuntu-latest - # pyroscope_env: ci-smoke-ocr2vrf-evm-simulated + - name: forwarder_ocr + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-forwarder-ocr-evm-simulated + - name: forwarders_ocr2 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-forwarder-ocr-evm-simulated + + # Keeper tests split out to use minimal environments + - name: keeper-1 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperBasicSmoke$ + - name: keeper-2 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperBlockCountPerTurn/registry_1_1$ + - name: keeper-3 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperBlockCountPerTurn/registry_1_2$ + - name: keeper-4 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperBlockCountPerTurn/registry_1_3$ + - name: keeper-5 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperSimulation$ + - name: keeper-6 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperCheckPerformGasLimit/registry_1_2$ + - name: keeper-7 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperCheckPerformGasLimit/registry_1_3$ + - name: keeper-8 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperRegisterUpkeep$ + - name: keeper-9 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperAddFunds$ + - name: keeper-10 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperRemove$ + - name: keeper-11 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperPauseRegistry$ + - name: keeper-12 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperMigrateRegistry$ + - name: keeper-13 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperNodeDown/registry_1_1$ + - name: keeper-14 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperNodeDown/registry_1_2$ + - name: keeper-15 + nodes: 1 + os: ubuntu-latest + pyroscope_env: ci-smoke-keeper-evm-simulated + file: keeper + run: -run ^TestKeeperNodeDown/registry_1_3$ runs-on: ${{ matrix.product.os }} name: ETH Smoke Tests ${{ matrix.product.name }} steps: @@ -207,6 +377,15 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 with: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} + - name: Build Go Test Command + id: build-go-test-command + run: | + # if the matrix.product.run is set, use it for a different command + if [ "${{ matrix.product.run }}" != "" ]; then + echo "run_command=${{ matrix.product.run }} ./smoke/${{ matrix.product.file }}_test.go" >> "$GITHUB_OUTPUT" + else + echo "run_command=./smoke/${{ matrix.product.name }}_test.go" >> "$GITHUB_OUTPUT" + fi ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' @@ -217,7 +396,7 @@ jobs: PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }} with: - test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json -test.parallel=${{ matrix.product.nodes }} ./smoke/${{ matrix.product.name }}_test.go 2>&1 | tee /tmp/gotest.log | gotestfmt + test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json -test.parallel=${{ matrix.product.nodes }} ${{ steps.build-go-test-command.outputs.run_command }} 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download cl_repo: ${{ env.CHAINLINK_IMAGE }} cl_image_tag: ${{ github.sha }} @@ -230,7 +409,6 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} - ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' @@ -267,10 +445,10 @@ jobs: if: always() runs-on: ubuntu-latest name: ETH Smoke Tests - needs: eth-smoke-tests-matrix + needs: [eth-smoke-tests-matrix,eth-smoke-tests-matrix-docker] steps: - name: Check smoke test matrix status - if: needs.eth-smoke-tests-matrix.result != 'success' + if: needs.eth-smoke-tests-matrix.result != 'success' && needs.eth-smoke-tests-matrix-docker.result != 'success' run: exit 1 - name: Collect Metrics if: always() diff --git a/integration-tests/actions/keeper_helpers_local.go b/integration-tests/actions/keeper_helpers_local.go new file mode 100644 index 00000000000..6fc7ef43dbe --- /dev/null +++ b/integration-tests/actions/keeper_helpers_local.go @@ -0,0 +1,58 @@ +package actions + +import ( + "fmt" + + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" +) + +func CreateKeeperJobsLocal( + chainlinkNodes []*client.ChainlinkClient, + keeperRegistry contracts.KeeperRegistry, + ocrConfig contracts.OCRv2Config, +) ([]*client.Job, error) { + // Send keeper jobs to registry and chainlink nodes + primaryNode := chainlinkNodes[0] + primaryNodeAddress, err := primaryNode.PrimaryEthAddress() + if err != nil { + log.Error().Err(err).Msg("Reading ETH Keys from Chainlink Client shouldn't fail") + return nil, err + } + nodeAddresses, err := ChainlinkNodeAddressesLocal(chainlinkNodes) + if err != nil { + log.Error().Err(err).Msg("Retrieving on-chain wallet addresses for chainlink nodes shouldn't fail") + return nil, err + } + nodeAddressesStr, payees := make([]string, 0), make([]string, 0) + for _, cla := range nodeAddresses { + nodeAddressesStr = append(nodeAddressesStr, cla.Hex()) + payees = append(payees, primaryNodeAddress) + } + err = keeperRegistry.SetKeepers(nodeAddressesStr, payees, ocrConfig) + if err != nil { + log.Error().Err(err).Msg("Setting keepers in the registry shouldn't fail") + return nil, err + } + jobs := []*client.Job{} + for _, chainlinkNode := range chainlinkNodes { + chainlinkNodeAddress, err := chainlinkNode.PrimaryEthAddress() + if err != nil { + log.Error().Err(err).Msg("Error retrieving chainlink node address") + return nil, err + } + job, err := chainlinkNode.MustCreateJob(&client.KeeperJobSpec{ + Name: fmt.Sprintf("keeper-test-%s", keeperRegistry.Address()), + ContractAddress: keeperRegistry.Address(), + FromAddress: chainlinkNodeAddress, + MinIncomingConfirmations: 1, + }) + if err != nil { + log.Error().Err(err).Msg("Creating KeeperV2 Job shouldn't fail") + return nil, err + } + jobs = append(jobs, job) + } + return jobs, nil +} diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 1bada7123aa..0d0f0f18ad2 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -74,7 +74,7 @@ func WithLogWatch(lw *logwatch.LogWatch) ClNodeOption { } func NewClNode(networks []string, nodeConfig *chainlink.Config, opts ...ClNodeOption) *ClNode { - nodeDefaultCName := fmt.Sprintf("%s-%s", "cl-node", uuid.NewString()[0:3]) + nodeDefaultCName := fmt.Sprintf("%s-%s", "cl-node", uuid.NewString()[0:8]) pgDefaultCName := fmt.Sprintf("pg-%s", nodeDefaultCName) pgDb := NewPostgresDb(networks, WithPostgresDbContainerName(pgDefaultCName)) n := &ClNode{ diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index f71ca2ddf94..85c05c664c8 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -5,6 +5,8 @@ import ( "fmt" "time" + "os" + "github.com/ethereum/go-ethereum/accounts" "github.com/ethereum/go-ethereum/accounts/keystore" "github.com/google/uuid" @@ -15,7 +17,6 @@ import ( "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" - "os" ) const ( @@ -40,7 +41,7 @@ type Geth struct { func NewGeth(networks []string, opts ...EnvComponentOption) *Geth { g := &Geth{ EnvComponent: EnvComponent{ - ContainerName: fmt.Sprintf("%s-%s", "geth", uuid.NewString()[0:3]), + ContainerName: fmt.Sprintf("%s-%s", "geth", uuid.NewString()[0:8]), Networks: networks, }, } diff --git a/integration-tests/docker/test_env/mockserver.go b/integration-tests/docker/test_env/mockserver.go index 1149bd9632d..5e5cce69e75 100644 --- a/integration-tests/docker/test_env/mockserver.go +++ b/integration-tests/docker/test_env/mockserver.go @@ -26,7 +26,7 @@ type MockServer struct { func NewMockServer(networks []string, opts ...EnvComponentOption) *MockServer { ms := &MockServer{ EnvComponent: EnvComponent{ - ContainerName: fmt.Sprintf("%s-%s", "mockserver", uuid.NewString()[0:3]), + ContainerName: fmt.Sprintf("%s-%s", "mockserver", uuid.NewString()[0:8]), Networks: networks, }, } diff --git a/integration-tests/docker/test_env/postgres.go b/integration-tests/docker/test_env/postgres.go index 9455303c683..64b48235989 100644 --- a/integration-tests/docker/test_env/postgres.go +++ b/integration-tests/docker/test_env/postgres.go @@ -33,7 +33,7 @@ func WithPostgresDbContainerName(name string) PostgresDbOption { func NewPostgresDb(networks []string, opts ...PostgresDbOption) *PostgresDb { pg := &PostgresDb{ EnvComponent: EnvComponent{ - ContainerName: fmt.Sprintf("%s-%s", "postgres-db", uuid.NewString()[0:3]), + ContainerName: fmt.Sprintf("%s-%s", "postgres-db", uuid.NewString()[0:8]), Networks: networks, }, User: "postgres", diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index 3e73a0205a5..f696e8f601c 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -3,11 +3,12 @@ package test_env import ( "os" + "math/big" + "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" - "math/big" ) type CLTestEnvBuilder struct { @@ -105,15 +106,14 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e } if b.hasLogWatch { - lw, err := logwatch.NewLogWatch(nil, nil) + te.LogWatch, err = logwatch.NewLogWatch(nil, nil) if err != nil { return te, err } - te.LogWatch = lw } if b.hasMockServer { - err := te.StartMockServer() + err = te.StartMockServer() if err != nil { return te, err } @@ -124,7 +124,7 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e } if b.hasGeth { - err := te.StartGeth() + err = te.StartGeth() if err != nil { return te, err } diff --git a/integration-tests/smoke/keeper_test.go b/integration-tests/smoke/keeper_test.go index e38124f6dd6..a24c2d6c23c 100644 --- a/integration-tests/smoke/keeper_test.go +++ b/integration-tests/smoke/keeper_test.go @@ -5,19 +5,13 @@ import ( "fmt" "math/big" "strconv" - "strings" "testing" + "time" "github.com/ethereum/go-ethereum/common" "github.com/onsi/gomega" "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - eth "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver" - mockservercfg "github.com/smartcontractkit/chainlink-env/pkg/helm/mockserver-cfg" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" @@ -25,7 +19,9 @@ import ( "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" + "github.com/smartcontractkit/chainlink/v2/core/store/models" ) const ( @@ -34,21 +30,9 @@ const ( keeperDefaultUpkeepsToDeploy = 10 numUpkeepsAllowedForStragglingTxs = 6 keeperExpectedData = "abcdef" - keeperBaseTOML = `[Keeper] - TurnLookBack = 0 - - [Keeper.Registry] - SyncInterval = '5s' - PerformGasOverhead = 150_000` ) var ( - keeperEnvVars = map[string]any{ - "KEEPER_TURN_LOOK_BACK": "0", - "KEEPER_REGISTRY_SYNC_INTERVAL": "5s", - "KEEPER_REGISTRY_PERFORM_GAS_OVERHEAD": "150000", - } - keeperDefaultRegistryConfig = contracts.KeeperRegistrySettings{ PaymentPremiumPPB: uint32(200000000), FlatFeeMicroLINK: uint32(0), @@ -92,21 +76,16 @@ var ( func TestKeeperBasicSmoke(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_1": ethereum.RegistryVersion_1_1, - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_1, + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "basic-smoke") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -120,11 +99,12 @@ func TestKeeperBasicSmoke(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { // Check if the upkeeps are performing multiple times by analysing their counters and checking they are greater than 10 for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) @@ -133,6 +113,7 @@ func TestKeeperBasicSmoke(t *testing.T) { "Expected consumer counter to be greater than 10, but got %d", counter.Int64()) l.Info().Int64("Upkeep counter", counter.Int64()).Msg("Number of upkeeps performed") } + return nil }, "5m", "1s").Should(gomega.Succeed()) // Cancel all the registered upkeeps via the registry @@ -157,7 +138,7 @@ func TestKeeperBasicSmoke(t *testing.T) { for i := 0; i < len(upkeepIDs); i++ { // Expect the counter to remain constant because the upkeep was cancelled, so it shouldn't increase anymore latestCounter, err := consumers[i].Counter(context.Background()) - require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) + g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Failed to retrieve consumer counter for upkeep at index %d", i) g.Expect(latestCounter.Int64()).Should(gomega.Equal(countersAfterCancellation[i].Int64()), "Expected consumer counter to remain constant at %d, but got %d", countersAfterCancellation[i].Int64(), latestCounter.Int64()) @@ -170,21 +151,16 @@ func TestKeeperBasicSmoke(t *testing.T) { func TestKeeperBlockCountPerTurn(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_1": ethereum.RegistryVersion_1_1, - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_1, + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "bcpt") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -198,15 +174,16 @@ func TestKeeperBlockCountPerTurn(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") keepersPerformed := make([]string, 0) upkeepID := upkeepIDs[0] // Wait for upkeep to be performed twice by different keepers (buddies) - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { counter, err := consumers[0].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's counter shouldn't fail") l.Info().Int64("Upkeep counter", counter.Int64()).Msg("Number of upkeeps performed") @@ -221,9 +198,10 @@ func TestKeeperBlockCountPerTurn(t *testing.T) { l.Info().Str("keeper", latestKeeper).Msg("New keeper performed upkeep") keepersPerformed = append(keepersPerformed, latestKeeper) + return nil }, "1m", "1s").Should(gomega.Succeed()) - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { upkeepInfo, err := registry.GetUpkeepInfo(context.Background(), upkeepID) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Registry's getUpkeep shouldn't fail") @@ -233,6 +211,7 @@ func TestKeeperBlockCountPerTurn(t *testing.T) { l.Info().Str("Keeper", latestKeeper).Msg("New keeper performed upkeep") keepersPerformed = append(keepersPerformed, latestKeeper) + return nil }, "1m", "1s").Should(gomega.Succeed()) // Expect no new keepers to perform for a while @@ -252,7 +231,7 @@ func TestKeeperBlockCountPerTurn(t *testing.T) { require.NoError(t, err, "Error waiting for set config tx") // Expect a new keeper to perform - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { counter, err := consumers[0].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's counter shouldn't fail") l.Info().Int64("Upkeep counter", counter.Int64()).Msg("Num upkeeps performed") @@ -267,6 +246,7 @@ func TestKeeperBlockCountPerTurn(t *testing.T) { l.Info().Str("keeper", latestKeeper).Msg("New keeper performed upkeep") keepersPerformed = append(keepersPerformed, latestKeeper) + return nil }, "1m", "1s").Should(gomega.Succeed()) }) } @@ -274,20 +254,15 @@ func TestKeeperBlockCountPerTurn(t *testing.T) { func TestKeeperSimulation(t *testing.T) { t.Parallel() - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "simulation") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, _, consumersPerformance, upkeepIDs := actions.DeployPerformanceKeeperContracts( t, registryVersion, @@ -305,8 +280,9 @@ func TestKeeperSimulation(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") consumerPerformance := consumersPerformance[0] @@ -335,12 +311,13 @@ func TestKeeperSimulation(t *testing.T) { require.NoError(t, err, "Error waiting to set PerformGasToBurn") // Upkeep should now start performing - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { cnt, err := consumerPerformance.GetUpkeepCount(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's Counter shouldn't fail") g.Expect(cnt.Int64()).Should(gomega.BeNumerically(">", int64(0)), "Expected consumer counter to be greater than 0, but got %d", cnt.Int64(), ) + return nil }, "1m", "1s").Should(gomega.Succeed()) }) } @@ -349,20 +326,14 @@ func TestKeeperSimulation(t *testing.T) { func TestKeeperCheckPerformGasLimit(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "gas-limit") - if onlyStartRunner { - return - } + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) registry, _, consumersPerformance, upkeepIDs := actions.DeployPerformanceKeeperContracts( t, registryVersion, @@ -380,8 +351,9 @@ func TestKeeperCheckPerformGasLimit(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") consumerPerformance := consumersPerformance[0] @@ -404,12 +376,13 @@ func TestKeeperCheckPerformGasLimit(t *testing.T) { require.NoError(t, err, "Error waiting for SetUpkeepGasLimit tx") // Upkeep should now start performing - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { cnt, err := consumerPerformance.GetUpkeepCount(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's counter shouldn't fail") g.Expect(cnt.Int64()).Should(gomega.BeNumerically(">", int64(0)), "Expected consumer counter to be greater than 0, but got %d", cnt.Int64(), ) + return nil }, "1m", "1s").Should(gomega.Succeed()) // Now increase the checkGasBurn on consumer, upkeep should stop performing @@ -463,21 +436,16 @@ func TestKeeperCheckPerformGasLimit(t *testing.T) { func TestKeeperRegisterUpkeep(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_1": ethereum.RegistryVersion_1_1, - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_1, + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "register-upkeep") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, registrar, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -491,15 +459,16 @@ func TestKeeperRegisterUpkeep(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") var initialCounters = make([]*big.Int, len(upkeepIDs)) // Observe that the upkeeps which are initially registered are performing and // store the value of their initial counters in order to compare later on that the value increased. - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) initialCounters[i] = counter @@ -512,6 +481,7 @@ func TestKeeperRegisterUpkeep(t *testing.T) { Int("Upkeep ID", i). Msg("Number of upkeeps performed") } + return nil }, "1m", "1s").Should(gomega.Succeed()) newConsumers, _ := actions.RegisterNewUpkeeps(t, contractDeployer, chainClient, linkToken, @@ -521,15 +491,16 @@ func TestKeeperRegisterUpkeep(t *testing.T) { newUpkeep := newConsumers[0] // Test that the newly registered upkeep is also performing. - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { counter, err := newUpkeep.Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling newly deployed upkeep's counter shouldn't fail") g.Expect(counter.Int64()).Should(gomega.BeNumerically(">", int64(0)), "Expected newly registered upkeep's counter to be greater than 0, but got %d", counter.Int64()) l.Info().Msg("Newly registered upkeeps performed " + strconv.Itoa(int(counter.Int64())) + " times") + return nil }, "1m", "1s").Should(gomega.Succeed()) - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for i := 0; i < len(upkeepIDs); i++ { currentCounter, err := consumers[i].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's counter shouldn't fail") @@ -544,6 +515,7 @@ func TestKeeperRegisterUpkeep(t *testing.T) { "Expected counter to have increased from initial value of %s, but got %s", initialCounters[i], currentCounter) } + return nil }, "1m", "1s").Should(gomega.Succeed()) }) } @@ -551,21 +523,16 @@ func TestKeeperRegisterUpkeep(t *testing.T) { func TestKeeperAddFunds(t *testing.T) { t.Parallel() - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_1": ethereum.RegistryVersion_1_1, - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_1, + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "add-funds") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -579,8 +546,9 @@ func TestKeeperAddFunds(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") // Since the upkeep is currently underfunded, check that it doesn't get executed @@ -617,21 +585,16 @@ func TestKeeperAddFunds(t *testing.T) { func TestKeeperRemove(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_1": ethereum.RegistryVersion_1_1, - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_1, + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "remove") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -645,13 +608,14 @@ func TestKeeperRemove(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") var initialCounters = make([]*big.Int, len(upkeepIDs)) // Make sure the upkeeps are running before we remove a keeper - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for upkeepID := 0; upkeepID < len(upkeepIDs); upkeepID++ { counter, err := consumers[upkeepID].Counter(context.Background()) initialCounters[upkeepID] = counter @@ -659,6 +623,7 @@ func TestKeeperRemove(t *testing.T) { " for upkeep with ID "+strconv.Itoa(upkeepID)) g.Expect(counter.Cmp(big.NewInt(0)) == 1, "Expected consumer counter to be greater than 0, but got %s", counter) } + return nil }, "1m", "1s").Should(gomega.Succeed()) keepers, err := registry.GetKeeperList(context.Background()) @@ -682,13 +647,14 @@ func TestKeeperRemove(t *testing.T) { l.Info().Msg("Successfully removed keeper at address " + keepers[0] + " from the list of Keepers") // The upkeeps should still perform and their counters should have increased compared to the first check - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Failed to retrieve consumer counter for upkeep at index %d", i) g.Expect(counter.Cmp(initialCounters[i]) == 1, "Expected consumer counter to be greater "+ "than initial counter which was %s, but got %s", initialCounters[i], counter) } + return nil }, "1m", "1s").Should(gomega.Succeed()) }) } @@ -696,20 +662,15 @@ func TestKeeperRemove(t *testing.T) { func TestKeeperPauseRegistry(t *testing.T) { t.Parallel() - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "pause-registry") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) + + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -723,18 +684,20 @@ func TestKeeperPauseRegistry(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") // Observe that the upkeeps which are initially registered are performing - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Failed to retrieve consumer counter for upkeep at index %d", i) g.Expect(counter.Int64()).Should(gomega.BeNumerically(">", int64(0)), "Expected consumer counter to be greater than 0, but got %d") } + return nil }, "1m", "1s").Should(gomega.Succeed()) // Pause the registry @@ -767,10 +730,7 @@ func TestKeeperPauseRegistry(t *testing.T) { func TestKeeperMigrateRegistry(t *testing.T) { t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "migrate-registry") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, ethereum.RegistryVersion_1_2, @@ -784,8 +744,9 @@ func TestKeeperMigrateRegistry(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") // Deploy the second registry, second registrar, and the same number of upkeeps as the first one @@ -802,7 +763,8 @@ func TestKeeperMigrateRegistry(t *testing.T) { ) // Set the jobs for the second registry - actions.CreateKeeperJobs(t, chainlinkNodes, secondRegistry, contracts.OCRv2Config{}) + _, err = actions.CreateKeeperJobsLocal(chainlinkNodes, secondRegistry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") @@ -814,11 +776,12 @@ func TestKeeperMigrateRegistry(t *testing.T) { require.NoError(t, err, "Error waiting to set permissions") // Check that the first upkeep from the first registry is performing (before being migrated) - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { counterBeforeMigration, err := consumers[0].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's counter shouldn't fail") g.Expect(counterBeforeMigration.Int64()).Should(gomega.BeNumerically(">", int64(0)), "Expected consumer counter to be greater than 0, but got %s", counterBeforeMigration) + return nil }, "1m", "1s").Should(gomega.Succeed()) // Migrate the upkeep with index 0 from the first to the second registry @@ -837,32 +800,27 @@ func TestKeeperMigrateRegistry(t *testing.T) { require.NoError(t, err, "Error calling consumer's counter") // Check that once we migrated the upkeep, the counter has increased - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { currentCounter, err := consumers[0].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Calling consumer's counter shouldn't fail") g.Expect(currentCounter.Int64()).Should(gomega.BeNumerically(">", counterAfterMigration.Int64()), "Expected counter to have increased, but stayed constant at %s", counterAfterMigration) + return nil }, "1m", "1s").Should(gomega.Succeed()) } func TestKeeperNodeDown(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - registryVersions := map[string]ethereum.KeeperRegistryVersion{ - "registry_1_1": ethereum.RegistryVersion_1_1, - "registry_1_2": ethereum.RegistryVersion_1_2, - "registry_1_3": ethereum.RegistryVersion_1_3, + registryVersions := []ethereum.KeeperRegistryVersion{ + ethereum.RegistryVersion_1_1, + ethereum.RegistryVersion_1_2, + ethereum.RegistryVersion_1_3, } - for n, rv := range registryVersions { - name := n - registryVersion := rv - t.Run(name, func(t *testing.T) { - t.Parallel() - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "node-down") - if onlyStartRunner { - return - } + for _, registryVersion := range registryVersions { + t.Run(fmt.Sprintf("registry_1_%d", registryVersion), func(t *testing.T) { + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, registryVersion, @@ -876,14 +834,15 @@ func TestKeeperNodeDown(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + jobs, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") var initialCounters = make([]*big.Int, len(upkeepIDs)) // Watch upkeeps being performed and store their counters in order to compare them later in the test - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) initialCounters[i] = counter @@ -891,12 +850,13 @@ func TestKeeperNodeDown(t *testing.T) { g.Expect(counter.Int64()).Should(gomega.BeNumerically(">", int64(0)), "Expected consumer counter to be greater than 0, but got %d", counter.Int64()) } + return nil }, "1m", "1s").Should(gomega.Succeed()) // Take down half of the Keeper nodes by deleting the Keeper job registered above (after registry deployment) firstHalfToTakeDown := chainlinkNodes[:len(chainlinkNodes)/2+1] for i, nodeToTakeDown := range firstHalfToTakeDown { - err = nodeToTakeDown.MustDeleteJob("1") + err = nodeToTakeDown.MustDeleteJob(jobs[0].Data.ID) require.NoError(t, err, "Error deleting job from node %d", i) err = chainClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") @@ -904,7 +864,7 @@ func TestKeeperNodeDown(t *testing.T) { l.Info().Msg("Successfully managed to take down the first half of the nodes") // Assert that upkeeps are still performed and their counters have increased - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { for i := 0; i < len(upkeepIDs); i++ { currentCounter, err := consumers[i].Counter(context.Background()) g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Failed to retrieve consumer counter for upkeep at index %d", i) @@ -912,12 +872,17 @@ func TestKeeperNodeDown(t *testing.T) { "Expected counter to have increased from initial value of %s, but got %s", initialCounters[i], currentCounter) } + return nil }, "3m", "1s").Should(gomega.Succeed()) // Take down the other half of the Keeper nodes - secondHalfToTakeDown := chainlinkNodes[len(chainlinkNodes)/2+1:] + nodesAndJobs := []nodeAndJob{} + for i, n := range chainlinkNodes { + nodesAndJobs = append(nodesAndJobs, nodeAndJob{node: n, job: jobs[i]}) + } + secondHalfToTakeDown := nodesAndJobs[len(nodesAndJobs)/2+1:] for i, nodeToTakeDown := range secondHalfToTakeDown { - err = nodeToTakeDown.MustDeleteJob("1") + err = nodeToTakeDown.node.MustDeleteJob(nodeToTakeDown.job.Data.ID) require.NoError(t, err, "Error deleting job from node %d", i) err = chainClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") @@ -953,13 +918,15 @@ func TestKeeperNodeDown(t *testing.T) { } } +type nodeAndJob struct { + node *client.ChainlinkClient + job *client.Job +} + func TestKeeperPauseUnPauseUpkeep(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "pause-upkeep") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) registry, _, consumers, upkeepIDs := actions.DeployKeeperContracts( t, ethereum.RegistryVersion_1_3, @@ -973,11 +940,12 @@ func TestKeeperPauseUnPauseUpkeep(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { // Check if the upkeeps are performing multiple times by analysing their counters and checking they are greater than 5 for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) @@ -986,6 +954,7 @@ func TestKeeperPauseUnPauseUpkeep(t *testing.T) { "Expected consumer counter to be greater than 5, but got %d", counter.Int64()) l.Info().Int64("Upkeep counter", counter.Int64()).Msg("Number of upkeeps performed") } + return nil }, "3m", "1s").Should(gomega.Succeed()) // pause all the registered upkeeps via the registry @@ -1030,7 +999,7 @@ func TestKeeperPauseUnPauseUpkeep(t *testing.T) { err = chainClient.WaitForEvents() require.NoError(t, err, "Error waiting to un-pause upkeeps") - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { // Check if the upkeeps are performing multiple times by analysing their counters and checking they are greater than 5 + numbers of performing before pause for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) @@ -1040,16 +1009,14 @@ func TestKeeperPauseUnPauseUpkeep(t *testing.T) { "Expected consumer counter to be greater than %d, but got %d", int64(5)+countersAfterPause[i].Int64(), counter.Int64()) l.Info().Int64("Upkeeps", counter.Int64()).Msg("Upkeeps Performed") } + return nil }, "3m", "1s").Should(gomega.Succeed()) } func TestKeeperUpdateCheckData(t *testing.T) { t.Parallel() l := utils.GetTestLogger(t) - chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner := setupKeeperTest(t, "pause-upkeep") - if onlyStartRunner { - return - } + chainClient, chainlinkNodes, contractDeployer, linkToken, _ := setupKeeperTest(t) registry, _, performDataChecker, upkeepIDs := actions.DeployPerformDataCheckerContracts( t, ethereum.RegistryVersion_1_3, @@ -1064,8 +1031,9 @@ func TestKeeperUpdateCheckData(t *testing.T) { ) gom := gomega.NewGomegaWithT(t) - actions.CreateKeeperJobs(t, chainlinkNodes, registry, contracts.OCRv2Config{}) - err := chainClient.WaitForEvents() + _, err := actions.CreateKeeperJobsLocal(chainlinkNodes, registry, contracts.OCRv2Config{}) + require.NoError(t, err, "Error creating keeper jobs") + err = chainClient.WaitForEvents() require.NoError(t, err, "Error creating keeper jobs") gom.Consistently(func(g gomega.Gomega) { @@ -1094,7 +1062,7 @@ func TestKeeperUpdateCheckData(t *testing.T) { require.Equal(t, []byte(keeperExpectedData), upkeep.CheckData, "Check data not as expected") } - gom.Eventually(func(g gomega.Gomega) { + gom.Eventually(func(g gomega.Gomega) error { // Check if the upkeeps are performing multiple times by analysing their counters and checking they are greater than 5 for i := 0; i < len(upkeepIDs); i++ { counter, err := performDataChecker[i].Counter(context.Background()) @@ -1103,71 +1071,41 @@ func TestKeeperUpdateCheckData(t *testing.T) { "Expected perform data checker counter to be greater than 5, but got %d", counter.Int64()) l.Info().Int64("Upkeep perform data checker", counter.Int64()).Msg("Number of upkeeps performed") } + return nil }, "3m", "1s").Should(gomega.Succeed()) } -func setupKeeperTest( - t *testing.T, - testName string, -) ( - chainClient blockchain.EVMClient, - chainlinkNodes []*client.ChainlinkK8sClient, - contractDeployer contracts.ContractDeployer, - linkToken contracts.LinkToken, - onlyStartRunner bool, +func setupKeeperTest(t *testing.T) ( + *blockchain.EthereumClient, + []*client.ChainlinkClient, + contracts.ContractDeployer, + contracts.LinkToken, + *test_env.CLClusterTestEnv, ) { - network := networks.SelectedNetwork - evmConfig := eth.New(nil) - if !network.Simulated { - evmConfig = eth.New(ð.Props{ - NetworkName: network.Name, - Simulated: network.Simulated, - WsURLs: network.URLs, - }) - } - - chainlinkChart, err := chainlink.NewDeployment(5, map[string]interface{}{ - "toml": client.AddNetworksConfig(keeperBaseTOML, network), - }) - require.NoError(t, err, "Error creating chainlink deployment") - - networkName := strings.ReplaceAll(strings.ToLower(network.Name), " ", "-") - testEnvironment := environment.New( - &environment.Config{ - NamespacePrefix: fmt.Sprintf("smoke-keeper-%s-%s", testName, networkName), - Test: t, - }). - AddHelm(mockservercfg.New(nil)). - AddHelm(mockserver.New(nil)). - AddHelm(evmConfig). - AddHelmCharts(chainlinkChart) - err = testEnvironment.Run() + clNodeConfig := node.NewConfig(node.BaseConf) + turnLookBack := int64(0) + syncInterval := models.MustMakeDuration(5 * time.Second) + performGasOverhead := uint32(150000) + clNodeConfig.Keeper.TurnLookBack = &turnLookBack + clNodeConfig.Keeper.Registry.SyncInterval = &syncInterval + clNodeConfig.Keeper.Registry.PerformGasOverhead = &performGasOverhead + + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithMockServer(1). + WithCLNodes(5). + WithCLNodeConfig(clNodeConfig). + WithFunding(big.NewFloat(.5)). + Build() require.NoError(t, err, "Error deploying test environment") - onlyStartRunner = testEnvironment.WillUseRemoteRunner() - if !onlyStartRunner { - chainClient, err = blockchain.NewEVMClient(network, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - contractDeployer, err = contracts.NewContractDeployer(chainClient) - require.NoError(t, err, "Deploying contracts shouldn't fail") - chainlinkNodes, err = client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - chainClient.ParallelTransactions(true) - - // Register cleanup for any test - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - err = actions.FundChainlinkNodes(chainlinkNodes, chainClient, big.NewFloat(.5)) - require.NoError(t, err, "Funding Chainlink nodes shouldn't fail") + env.ParallelTransactions(true) - linkToken, err = contractDeployer.DeployLinkTokenContract() - require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") + linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = chainClient.WaitForEvents() - require.NoError(t, err, "Error waiting for events") - } + env.Geth.EthClient.WaitForEvents() + require.NoError(t, err, "Error waiting for events") - return chainClient, chainlinkNodes, contractDeployer, linkToken, onlyStartRunner + return env.Geth.EthClient, env.GetAPIs(), env.Geth.ContractDeployer, linkTokenContract, env } From ee80c6d0657fa7239a29a3fbee3d3c74631c7d4c Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Mon, 14 Aug 2023 22:53:32 +0300 Subject: [PATCH 163/270] debug flag for CL client (#10191) --- integration-tests/client/chainlink.go | 5 +++++ integration-tests/client/chainlink_k8s.go | 4 ++++ integration-tests/smoke/README.md | 5 +++++ 3 files changed, 14 insertions(+) diff --git a/integration-tests/client/chainlink.go b/integration-tests/client/chainlink.go index 28c060f1ef3..7d3bd0284d0 100644 --- a/integration-tests/client/chainlink.go +++ b/integration-tests/client/chainlink.go @@ -13,6 +13,7 @@ import ( "github.com/go-resty/resty/v2" "github.com/rs/zerolog/log" "golang.org/x/sync/errgroup" + "os" ) const ( @@ -46,6 +47,10 @@ func NewChainlinkClient(c *ChainlinkConfig) (*ChainlinkClient, error) { if err != nil { return nil, err } + _, isSet := os.LookupEnv("CL_CLIENT_DEBUG") + if isSet { + rc.SetDebug(true) + } return &ChainlinkClient{ Config: c, APIClient: rc, diff --git a/integration-tests/client/chainlink_k8s.go b/integration-tests/client/chainlink_k8s.go index 5586f320f27..4aa7c6d0fec 100644 --- a/integration-tests/client/chainlink_k8s.go +++ b/integration-tests/client/chainlink_k8s.go @@ -23,6 +23,10 @@ func NewChainlinkK8sClient(c *ChainlinkConfig, podName, chartName string) (*Chai if err != nil { return nil, err } + _, isSet := os.LookupEnv("CL_CLIENT_DEBUG") + if isSet { + rc.SetDebug(true) + } return &ChainlinkK8sClient{ ChainlinkClient: &ChainlinkClient{ APIClient: rc, diff --git a/integration-tests/smoke/README.md b/integration-tests/smoke/README.md index f8a9e94211b..f76c956e4c5 100644 --- a/integration-tests/smoke/README.md +++ b/integration-tests/smoke/README.md @@ -49,4 +49,9 @@ Here is an example for 3 nodes cluster } ] } +``` + +### Debugging CL client API calls +``` +export CL_CLIENT_DEBUG=true ``` \ No newline at end of file From abcbc8ed25a9333e2de9c71889281daf055169b1 Mon Sep 17 00:00:00 2001 From: Chris Cushman <104409744+vreff@users.noreply.github.com> Date: Mon, 14 Aug 2023 16:43:32 -0400 Subject: [PATCH 164/270] [VRFv2+] Change request commitment from calldata to memory (#10176) * Remove extraArgs from v2plus log * prettier * update interfaces * Make requestCommitment memory * Update tests * Change request commitment from calldata to memory * Add wrapper changes * Remove subId from emit RandomWordsFulfilled Event log * Revert "Remove subId from emit RandomWordsFulfilled Event log" This reverts commit 337cfb71b2f021b095f2ada7479e99b31df4e891. * Change proof to memory from calldata * Prettier --------- Co-authored-by: Sri Kidambi <1702865+kidambisrinivas@users.noreply.github.com> Co-authored-by: Sri Kidambi --- contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol | 9 +++------ .../vrf_coordinator_v2plus/vrf_coordinator_v2plus.go | 2 +- ...generated-wrapper-dependency-versions-do-not-edit.txt | 2 +- 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol index 1250da91d64..f08fe8c8f24 100644 --- a/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/VRFCoordinatorV2Plus.sol @@ -346,7 +346,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { } function getRandomnessFromProof( - Proof calldata proof, + Proof memory proof, RequestCommitment memory rc ) internal view returns (Output memory) { bytes32 keyHash = hashOfKey(proof.pk); @@ -388,10 +388,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { * @return payment amount billed to the subscription * @dev simulated offchain to determine if sufficient balance is present to fulfill the request */ - function fulfillRandomWords( - Proof calldata proof, - RequestCommitment calldata rc - ) external nonReentrant returns (uint96) { + function fulfillRandomWords(Proof memory proof, RequestCommitment memory rc) external nonReentrant returns (uint96) { uint256 startGas = gasleft(); Output memory output = getRandomnessFromProof(proof, rc); @@ -419,7 +416,7 @@ contract VRFCoordinatorV2Plus is VRF, SubscriptionAPI { // stack too deep error { - bool nativePayment = _fromBytes(rc.extraArgs).nativePayment; + bool nativePayment = uint8(rc.extraArgs[rc.extraArgs.length - 1]) == 1; // We want to charge users exactly for how much gas they use in their callback. // The gasAfterPaymentCalculation is meant to cover these additional operations where we // decrement the subscription balance and increment the oracles withdrawable balance. diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index 453d305e5da..3f13a956981 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -67,7 +67,7 @@ type VRFV2PlusClientRandomWordsRequest struct { var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"reentrancyLock\",\"type\":\"bool\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620060ca380380620060ca833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615eef620001db6000396000818161060b0152613aae0152615eef6000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095b578063ee9d2d3814610982578063f2fde38b146109af57600080fd5b8063dc311dd3146108f7578063e72f6e3014610928578063e8509bff1461094857600080fd5b8063d98e620e116100bb578063d98e620e14610881578063da2f2610146108a1578063dac83d29146108d757600080fd5b8063bec4c08c14610821578063caf70c4a14610841578063cb6317971461086157600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107c1578063b08c8795146107e1578063b2a7cac51461080157600080fd5b8063a4c0ed3614610761578063a8cb447b14610781578063aa433aff146107a157600080fd5b80639b1c385e116101745780639b1c385e146106f25780639d40a6fd14610712578063a21a23e41461074c57600080fd5b806386fe91c7146106a85780638da5cb5b146106d457600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461062d5780636f64f03f1461067357806379ba50971461069357600080fd5b806364d51a2a146105c457806366316d8d146105d9578063689c4517146105f957600080fd5b806346d8d4861161022d57806346d8d4861461056457806357133e64146105845780635d06b4ab146105a457600080fd5b806340d6bb821461050957806341af6c871461053457600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610495578063330987b3146104b1578063405b84fa146104e957600080fd5b80630ae095401461041557806315c48b84146104355780631b6b6d231461045d57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103f557600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109cf565b60405161031a93929190615976565b60405180910390f35b34801561032f57600080fd5b5061034361033e36600461530c565b610a4b565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600a546103bd9061ffff81169063ffffffff62010000820481169160ff600160301b8204169167010000000000000082048116916b01000000000000000000000090041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a00161031a565b34801561040157600080fd5b5061034361041036600461544d565b610c0d565b34801561042157600080fd5b5061034361043036600461570a565b610da1565b34801561044157600080fd5b5061044a60c881565b60405161ffff909116815260200161031a565b34801561046957600080fd5b5060025461047d906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b3480156104a157600080fd5b506040516001815260200161031a565b3480156104bd57600080fd5b506104d16104cc366004615520565b610e6f565b6040516001600160601b03909116815260200161031a565b3480156104f557600080fd5b5061034361050436600461570a565b6113ad565b34801561051557600080fd5b5061051f6101f481565b60405163ffffffff909116815260200161031a565b34801561054057600080fd5b5061055461054f3660046154a2565b61178d565b604051901515815260200161031a565b34801561057057600080fd5b5061034361057f366004615329565b61198f565b34801561059057600080fd5b5061034361059f36600461535e565b611b0c565b3480156105b057600080fd5b506103436105bf36600461530c565b611b85565b3480156105d057600080fd5b5061044a606481565b3480156105e557600080fd5b506103436105f4366004615329565b611c5c565b34801561060557600080fd5b5061047d7f000000000000000000000000000000000000000000000000000000000000000081565b34801561063957600080fd5b50600f546106569063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561067f57600080fd5b5061034361068e366004615397565b611dfb565b34801561069f57600080fd5b50610343611f13565b3480156106b457600080fd5b506007546104d1906801000000000000000090046001600160601b031681565b3480156106e057600080fd5b506000546001600160a01b031661047d565b3480156106fe57600080fd5b5061035b61070d36600461561c565b611fc4565b34801561071e57600080fd5b506007546107339067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561075857600080fd5b5061035b6123e9565b34801561076d57600080fd5b5061034361077c3660046153c4565b612671565b34801561078d57600080fd5b5061034361079c36600461530c565b612843565b3480156107ad57600080fd5b506103436107bc3660046154a2565b61295e565b3480156107cd57600080fd5b5060035461047d906001600160a01b031681565b3480156107ed57600080fd5b506103436107fc36600461566c565b6129be565b34801561080d57600080fd5b5061034361081c3660046154a2565b612b5a565b34801561082d57600080fd5b5061034361083c36600461570a565b612ca9565b34801561084d57600080fd5b5061035b61085c366004615469565b612e5f565b34801561086d57600080fd5b5061034361087c36600461570a565b612e8f565b34801561088d57600080fd5b5061035b61089c3660046154a2565b613193565b3480156108ad57600080fd5b5061047d6108bc3660046154a2565b600b602052600090815260409020546001600160a01b031681565b3480156108e357600080fd5b506103436108f236600461570a565b6131b4565b34801561090357600080fd5b506109176109123660046154a2565b6132d3565b60405161031a959493929190615b14565b34801561093457600080fd5b5061034361094336600461530c565b6133cf565b6103436109563660046154a2565b613597565b34801561096757600080fd5b506007546104d190600160a01b90046001600160601b031681565b34801561098e57600080fd5b5061035b61099d3660046154a2565b600d6020526000908152604090205481565b3480156109bb57600080fd5b506103436109ca36600461530c565b6136d6565b600a54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3957602002820191906000526020600020905b815481526020019060010190808311610a25575b50505050509050925092509250909192565b610a536136e7565b60105460005b81811015610be057826001600160a01b031660108281548110610a7e57610a7e615e93565b6000918252602090912001546001600160a01b03161415610bce576010610aa6600184615ceb565b81548110610ab657610ab6615e93565b600091825260209091200154601080546001600160a01b039092169183908110610ae257610ae2615e93565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826010610b19600185615ceb565b81548110610b2957610b29615e93565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506010805480610b6857610b68615e7d565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bd881615dfa565b915050610a59565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c156136e7565b604080518082018252600091610c44919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031680610c8057604051631dfd6e1360e21b815260048101839052602401610c01565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d585782600c8281548110610cbb57610cbb615e93565b90600052602060002001541415610d4657600c805460009190610ce090600190615ceb565b81548110610cf057610cf0615e93565b9060005260206000200154905080600c8381548110610d1157610d11615e93565b600091825260209091200155600c805480610d2e57610d2e615e7d565b60019003818190600052602060002001600090559055505b80610d5081615dfa565b915050610c9d565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9491815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610dd957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0d57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615610e385760405163769dd35360e11b815260040160405180910390fd5b610e418461178d565b15610e5f57604051631685ecdd60e31b815260040160405180910390fd5b610e698484613743565b50505050565b600a54600090600160301b900460ff1615610e9d5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eb685610eb186615d5a565b6138da565b90506000610eca608086016060870161572f565b63ffffffff1667ffffffffffffffff811115610ee857610ee8615ea9565b604051908082528060200260200182016040528015610f11578160200160208202803683370190505b50905060005b610f27608087016060880161572f565b63ffffffff16811015610f9c57826040015181604051602001610f54929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f7f57610f7f615e93565b602090810291909101015280610f9481615dfa565b915050610f17565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e30000000000000000000000000000000000000000000000000000000091610fed919086906024016159e9565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990941693909317909252600a805466ff0000000000001916600160301b179055915060009061107f906110639060608b01908b0161572f565b63ffffffff1661107960a08b0160808c0161530c565b84613be9565b600a805466ff00000000000019169055602089810135600090815260069091526040902054909150600160c01b900467ffffffffffffffff166110c3816001615c6a565b6020808b01356000908152600690915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915561112461111f60a08c018c615b6a565b613c37565b51600a54909150600090611150908a906b010000000000000000000000900463ffffffff163a85613ce6565b90508115611259576020808c01356000908152600690915260409020546001600160601b03808316600160601b9092041610156111a057604051631e9acf1760e31b815260040160405180910390fd5b60208b81013560009081526006909152604090208054829190600c906111d7908490600160601b90046001600160601b0316615d02565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261123091859116615c96565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550611345565b6020808c01356000908152600690915260409020546001600160601b038083169116101561129a57604051631e9acf1760e31b815260040160405180910390fd5b6020808c0135600090815260069091526040812080548392906112c79084906001600160601b0316615d02565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600890915281208054859450909261132091859116615c96565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b6020888101516040808b015181519081526001600160601b03851681850152871515818301529051928e0135927f49580fdfd9497e1ed5c1b1cec0495087ae8e3f1267470ec2fb015db32e3d6aa79181900360600190a3985050505050505050505b92915050565b6113b681613d36565b6113de57604051635428d44960e01b81526001600160a01b0382166004820152602401610c01565b6000806000806113ed866132d3565b945094505093509350336001600160a01b0316826001600160a01b0316146114575760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c01565b6114608661178d565b156114ad5760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c01565b60006040518060c001604052806114c2600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016115169190615901565b604051602081830303815290604052905061153088613da0565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b038816906115829085906004016158ee565b6000604051808303818588803b15801561159b57600080fd5b505af11580156115af573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561160b57600080fd5b505af115801561161f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906116439190615485565b61168f5760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c01565b60005b8351811015611740578381815181106116ad576116ad615e93565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561171557600080fd5b505af1158015611729573d6000803e3d6000fd5b50505050808061173890615dfa565b915050611692565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561181757602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117f9575b505050505081525050905060005b8160400151518110156119855760005b600c5481101561197257600061193b600c838154811061185757611857615e93565b90600052602060002001548560400151858151811061187857611878615e93565b602002602001015188600460008960400151898151811061189b5761189b615e93565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d60205260409020549091501561195f5750600195945050505050565b508061196a81615dfa565b915050611835565b508061197d81615dfa565b915050611825565b5060009392505050565b600a54600160301b900460ff16156119ba5760405163769dd35360e11b815260040160405180910390fd5b336000908152600960205260409020546001600160601b03808316911610156119f657604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611a1e9084906001600160601b0316615d02565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a669190615d02565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611ae0576040519150601f19603f3d011682016040523d82523d6000602084013e611ae5565b606091505b5050905080611b0757604051630dcf35db60e41b815260040160405180910390fd5b505050565b611b146136e7565b6002546001600160a01b031615611b57576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611b8d6136e7565b611b9681613d36565b15611bd8576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c01565b601080546001810182556000919091527f1b6847dc741a1b0cd08d278845f9d819d87b734759afb55fe2de5cb82a9ae6720180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600a54600160301b900460ff1615611c875760405163769dd35360e11b815260040160405180910390fd5b336000908152600860205260409020546001600160601b0380831691161015611cc357604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611ceb9084906001600160601b0316615d02565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611d339190615d02565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611da257600080fd5b505af1158015611db6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dda9190615485565b611df757604051631e9acf1760e31b815260040160405180910390fd5b5050565b611e036136e7565b604080518082018252600091611e32919084906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b031615611e87576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c01565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d94565b6001546001600160a01b03163314611f6d5760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c01565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600a54600090600160301b900460ff1615611ff25760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b031661202d57604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff168061207f576040516379bfd40160e01b815260208401356004820152336024820152604401610c01565b600a5461ffff166120966060850160408601615651565b61ffff1610806120b9575060c86120b36060850160408601615651565b61ffff16115b156120ff576120ce6060840160408501615651565b600a5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c01565b600a5462010000900463ffffffff1661211e608085016060860161572f565b63ffffffff1611156121875761213a608084016060850161572f565b600a546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c01565b6101f461219a60a085016080860161572f565b63ffffffff1611156121f9576121b660a084016080850161572f565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c01565b6000612206826001615c6a565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e0808501849052855180860390910181526101009094019094528251920191909120929350906000906122929061111f90890189615b6a565b9050600061229f82613ff0565b9050836122aa614076565b60208a01356122bf60808c0160608d0161572f565b6122cf60a08d0160808e0161572f565b33866040516020016122e79796959493929190615a76565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061235e9190615651565b8e6060016020810190612371919061572f565b8f6080016020810190612384919061572f565b8960405161239796959493929190615a37565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff191667ffffffffffffffff9490941693909317909255925050505b919050565b600a54600090600160301b900460ff16156124175760405163769dd35360e11b815260040160405180910390fd5b600033612425600143615ceb565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124bd83615e15565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff8111156124ff576124ff615ea9565b604051908082528060200260200182016040528015612528578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b03928316178355925160018301805490941691161790915592518051949550909361263392600285019201906150aa565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600a54600160301b900460ff161561269c5760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b031633146126e0576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6020811461271a576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000612728828401846154a2565b6000818152600560205260409020549091506001600160a01b031661276057604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127878385615c96565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127cf9190615c96565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846128229190615c52565b604080519283526020830191909152015b60405180910390a2505050505050565b61284b6136e7565b6007544790600160a01b90046001600160601b03168181111561288b576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b0757600061289f8284615ceb565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128ee576040519150601f19603f3d011682016040523d82523d6000602084013e6128f3565b606091505b505090508061291557604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6129666136e7565b6000818152600560205260409020546001600160a01b031661299b57604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0a9082906001600160a01b0316613743565b6129c66136e7565b60c861ffff87161115612a005760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c01565b60008213612a24576040516321ea67b360e11b815260048101839052602401610c01565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600a805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff00000000000000000000001916176b01000000000000000000000083021790558a51600f80548d87015192891667ffffffffffffffff1990911617640100000000928916929092029190911790819055600e8d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600a54600160301b900460ff1615612b855760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612bba57604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c2c57600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c01565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612ce157604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d1557604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612d405760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612d8c576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612dc457610e69565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612e7291906158e0565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612ec757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612efb57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612f265760405163769dd35360e11b815260040160405180910390fd5b612f2f8461178d565b15612f4d57604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16612faa576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c01565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561300d57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612fef575b505050505090506000600182516130249190615ceb565b905060005b825181101561313057856001600160a01b031683828151811061304e5761304e615e93565b60200260200101516001600160a01b0316141561311e57600083838151811061307957613079615e93565b6020026020010151905080600560008a815260200190815260200160002060020183815481106130ab576130ab615e93565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394909416939093179092558981526005909152604090206002018054806130f6576130f6615e7d565b600082815260209020810160001990810180546001600160a01b031916905501905550613130565b8061312881615dfa565b915050613029565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a79101612833565b600c81815481106131a357600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b0316806131ec57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461322057604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff161561324b5760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e695760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e51565b6000818152600560205260408120548190819081906060906001600160a01b031661331157604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156133b557602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613397575b505050505090509450945094509450945091939590929450565b6133d76136e7565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561343457600080fd5b505afa158015613448573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061346c91906154bb565b6007549091506801000000000000000090046001600160601b0316818111156134b2576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611b075760006134c68284615ceb565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561351657600080fd5b505af115801561352a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061354e9190615485565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600a54600160301b900460ff16156135c25760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b03166135f757604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136268385615c96565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b031661366e9190615c96565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136c19190615c52565b60408051928352602083019190915201612c9d565b6136de6136e7565b610c0a8161410f565b6000546001600160a01b031633146137415760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c01565b565b60008061374f84613da0565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137ac57600080fd5b505af11580156137c0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137e49190615485565b61380157604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613857576040519150601f19603f3d011682016040523d82523d6000602084013e61385c565b606091505b505090508061387e57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905281830181905282518084018452919290916139239186906002908390839080828437600092019190915250612e5f915050565b6000818152600b60205260409020549091506001600160a01b03168061395f57604051631dfd6e1360e21b815260048101839052602401610c01565b6000828660c00135604051602001613981929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d909352912054909150806139e0576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85516020808801516040808a015160608b015160808c015160a08d01519351613a0f978a979096959101615ac0565b604051602081830303815290604052805190602001208114613a5d576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a6c87600001516141b9565b905080613b785786516040517fe9413d3800000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063e9413d389060240160206040518083038186803b158015613af857600080fd5b505afa158015613b0c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b3091906154bb565b905080613b785786516040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c01565b6040805160c08a0135602080830191909152818301849052825180830384018152606090920190925280519101206000613bc0613bba368c90038c018c615578565b836142c0565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613bfb57600080fd5b611388810390508460408204820311613c1357600080fd5b50823b613c1f57600080fd5b60008083516020850160008789f190505b9392505050565b60408051602081019091526000815281613c6057506040805160208101909152600081526113a7565b7f92fd133800000000000000000000000000000000000000000000000000000000613c8b8385615d2a565b6001600160e01b03191614613ccc576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613cd98260048186615c28565b810190613c3091906154d4565b60008115613d1457600f54613d0d9086908690640100000000900463ffffffff168661432b565b9050613d2e565b600f54613d2b908690869063ffffffff1686614395565b90505b949350505050565b6000805b601054811015613d9757826001600160a01b031660108281548110613d6157613d61615e93565b6000918252602090912001546001600160a01b03161415613d855750600192915050565b80613d8f81615dfa565b915050613d3a565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613e2c57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613e0e575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b826040015151811015613f0a576004600084604001518381518110613eb957613eb9615e93565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613f0281615dfa565b915050613e92565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590613f42600283018261510f565b505060008581526006602052604081205560078054859190600890613f7d9084906801000000000000000090046001600160601b0316615d02565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b0316613fc59190615d02565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa8260405160240161402991511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b60004661a4b181148061408b575062066eed81145b156141085760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140ca57600080fd5b505afa1580156140de573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061410291906154bb565b91505090565b4391505090565b6001600160a01b0381163314156141685760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c01565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b18114806141ce575062066eed81145b156142b0576101008367ffffffffffffffff166141e9614076565b6141f39190615ceb565b11806142105750614202614076565b8367ffffffffffffffff1610155b1561421e5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561427857600080fd5b505afa15801561428c573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c3091906154bb565b505067ffffffffffffffff164090565b60006142f48360000151846020015185604001518660600151868860a001518960c001518a60e001518b610100015161449c565b6003836020015160405160200161430c9291906159d5565b60408051601f1981840301815291905280516020909101209392505050565b6000806143366146d7565b905060005a6143458888615c52565b61434f9190615ceb565b6143599085615ccc565b9050600061437263ffffffff871664e8d4a51000615ccc565b90508261437f8284615c52565b6143899190615c52565b98975050505050505050565b6000806143a0614733565b9050600081136143c6576040516321ea67b360e11b815260048101829052602401610c01565b60006143d06146d7565b9050600082825a6143e18b8b615c52565b6143eb9190615ceb565b6143f59088615ccc565b6143ff9190615c52565b61441190670de0b6b3a7640000615ccc565b61441b9190615cb8565b9050600061443463ffffffff881664e8d4a51000615ccc565b905061444c816b033b2e3c9fd0803ce8000000615ceb565b821115614485576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61448f8183615c52565b9998505050505050505050565b6144a58961481b565b6144f15760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c01565b6144fa8861481b565b6145465760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c01565b61454f8361481b565b61459b5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c01565b6145a48261481b565b6145f05760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c01565b6145fc878a88876148f4565b6146485760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c01565b60006146548a87614a29565b90506000614667898b878b868989614a8d565b90506000614678838d8d8a86614bad565b9050808a146146c95760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c01565b505050505050505050505050565b60004661a4b18114806146ec575062066eed81145b1561472b57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140ca57600080fd5b600091505090565b600a54600354604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b1580156147ae57600080fd5b505afa1580156147c2573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906147e6919061574a565b50945090925084915050801561480a57506148018242615ceb565b8463ffffffff16105b15613d2e5750600e54949350505050565b80516000906401000003d019116148745760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d019116148cd5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d0199080096148ed8360005b6020020151614bed565b1492915050565b60006001600160a01b03821661494c5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c01565b60208401516000906001161561496357601c614966565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614a01573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614a3161512d565b614a5e60018484604051602001614a4a939291906158bf565b604051602081830303815290604052614c11565b90505b614a6a8161481b565b6113a7578051604080516020810192909252614a869101614a4a565b9050614a61565b614a9561512d565b825186516401000003d0199081900691061415614af45760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c01565b614aff878988614c5f565b614b4b5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c01565b614b56848685614c5f565b614ba25760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c01565b614389868484614d99565b600060028686868587604051602001614bcb96959493929190615860565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614c1961512d565b614c2282614e60565b8152614c37614c328260006148e3565b614e9b565b6020820181905260029006600114156123e4576020810180516401000003d019039052919050565b600082614cae5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c01565b83516020850151600090614cc490600290615e3d565b15614cd057601c614cd3565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614d45573d6000803e3d6000fd5b505050602060405103519050600086604051602001614d64919061584e565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614da161512d565b835160208086015185519186015160009384938493614dc293909190614ebb565b919450925090506401000003d019858209600114614e225760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c01565b60405180604001604052806401000003d01980614e4157614e41615e67565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106123e457604080516020808201939093528151808203840181529082019091528051910120614e68565b60006113a7826002614eb46401000003d0196001615c52565b901c614f9b565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614efb8383858561503d565b9098509050614f0c88828e88615061565b9098509050614f1d88828c87615061565b90985090506000614f308d878b85615061565b9098509050614f418882868661503d565b9098509050614f5288828e89615061565b9098509050818114614f87576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614f8b565b8196505b5050505050509450945094915050565b600080614fa661514b565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a0820152614fd8615169565b60208160c0846005600019fa9250826150335760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c01565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156150ff579160200282015b828111156150ff57825182546001600160a01b0319166001600160a01b039091161782556020909201916001909101906150ca565b5061510b929150615187565b5090565b5080546000825590600052602060002090810190610c0a9190615187565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561510b5760008155600101615188565b80356123e481615ebf565b80604081018310156113a757600080fd5b600082601f8301126151c957600080fd5b6151d1615bb8565b8083856040860111156151e357600080fd5b60005b60028110156152055781358452602093840193909101906001016151e6565b509095945050505050565b600082601f83011261522157600080fd5b813567ffffffffffffffff8082111561523c5761523c615ea9565b604051601f8301601f19908116603f0116810190828211818310171561526457615264615ea9565b8160405283815286602085880101111561527d57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600060c082840312156152af57600080fd5b50919050565b803561ffff811681146123e457600080fd5b803563ffffffff811681146123e457600080fd5b805169ffffffffffffffffffff811681146123e457600080fd5b80356001600160601b03811681146123e457600080fd5b60006020828403121561531e57600080fd5b8135613c3081615ebf565b6000806040838503121561533c57600080fd5b823561534781615ebf565b9150615355602084016152f5565b90509250929050565b6000806040838503121561537157600080fd5b823561537c81615ebf565b9150602083013561538c81615ebf565b809150509250929050565b600080606083850312156153aa57600080fd5b82356153b581615ebf565b915061535584602085016151a7565b600080600080606085870312156153da57600080fd5b84356153e581615ebf565b935060208501359250604085013567ffffffffffffffff8082111561540957600080fd5b818701915087601f83011261541d57600080fd5b81358181111561542c57600080fd5b88602082850101111561543e57600080fd5b95989497505060200194505050565b60006040828403121561545f57600080fd5b613c3083836151a7565b60006040828403121561547b57600080fd5b613c3083836151b8565b60006020828403121561549757600080fd5b8151613c3081615ed4565b6000602082840312156154b457600080fd5b5035919050565b6000602082840312156154cd57600080fd5b5051919050565b6000602082840312156154e657600080fd5b6040516020810181811067ffffffffffffffff8211171561550957615509615ea9565b604052823561551781615ed4565b81529392505050565b6000808284036101c081121561553557600080fd5b6101a08082121561554557600080fd5b849350830135905067ffffffffffffffff81111561556257600080fd5b61556e8582860161529d565b9150509250929050565b60006101a0828403121561558b57600080fd5b615593615be1565b61559d84846151b8565b81526155ac84604085016151b8565b60208201526080830135604082015260a0830135606082015260c083013560808201526155db60e0840161519c565b60a08201526101006155ef858286016151b8565b60c08301526156028561014086016151b8565b60e083015261018084013581830152508091505092915050565b60006020828403121561562e57600080fd5b813567ffffffffffffffff81111561564557600080fd5b613d2e8482850161529d565b60006020828403121561566357600080fd5b613c30826152b5565b60008060008060008086880360e081121561568657600080fd5b61568f886152b5565b965061569d602089016152c7565b95506156ab604089016152c7565b94506156b9606089016152c7565b9350608088013592506040609f19820112156156d457600080fd5b506156dd615bb8565b6156e960a089016152c7565b81526156f760c089016152c7565b6020820152809150509295509295509295565b6000806040838503121561571d57600080fd5b82359150602083013561538c81615ebf565b60006020828403121561574157600080fd5b613c30826152c7565b600080600080600060a0868803121561576257600080fd5b61576b866152db565b945060208601519350604086015192506060860151915061578e608087016152db565b90509295509295909350565b600081518084526020808501945080840160005b838110156157d35781516001600160a01b0316875295820195908201906001016157ae565b509495945050505050565b8060005b6002811015610e695781518452602093840193909101906001016157e2565b6000815180845260005b818110156158275760208185018101518683018201520161580b565b81811115615839576000602083870101525b50601f01601f19169290920160200192915050565b61585881836157de565b604001919050565b86815261587060208201876157de565b61587d60608201866157de565b61588a60a08201856157de565b61589760e08201846157de565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b8381526158cf60208201846157de565b606081019190915260800192915050565b604081016113a782846157de565b602081526000613c306020830184615801565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261594760e084018261579a565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b818110156159c7578451835293830193918301916001016159ab565b509098975050505050505050565b82815260608101613c3060208301846157de565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a2a57845183529383019391830191600101615a0e565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261438960c0830184615801565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261448f60e0830184615801565b87815267ffffffffffffffff87166020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261448f60e0830184615801565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615b5f60a083018461579a565b979650505050505050565b6000808335601e19843603018112615b8157600080fd5b83018035915067ffffffffffffffff821115615b9c57600080fd5b602001915036819003821315615bb157600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615bdb57615bdb615ea9565b60405290565b604051610120810167ffffffffffffffff81118282101715615bdb57615bdb615ea9565b60405160c0810167ffffffffffffffff81118282101715615bdb57615bdb615ea9565b60008085851115615c3857600080fd5b83861115615c4557600080fd5b5050820193919092039150565b60008219821115615c6557615c65615e51565b500190565b600067ffffffffffffffff808316818516808303821115615c8d57615c8d615e51565b01949350505050565b60006001600160601b03808316818516808303821115615c8d57615c8d615e51565b600082615cc757615cc7615e67565b500490565b6000816000190483118215151615615ce657615ce6615e51565b500290565b600082821015615cfd57615cfd615e51565b500390565b60006001600160601b0383811690831681811015615d2257615d22615e51565b039392505050565b6001600160e01b03198135818116916004851015615d525780818660040360031b1b83161692505b505092915050565b600060c08236031215615d6c57600080fd5b615d74615c05565b823567ffffffffffffffff8082168214615d8d57600080fd5b81835260208501356020840152615da6604086016152c7565b6040840152615db7606086016152c7565b6060840152615dc86080860161519c565b608084015260a0850135915080821115615de157600080fd5b50615dee36828601615210565b60a08301525092915050565b6000600019821415615e0e57615e0e615e51565b5060010190565b600067ffffffffffffffff80831681811415615e3357615e33615e51565b6001019392505050565b600082615e4c57615e4c615e67565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0a57600080fd5b8015158114610c0a57600080fdfea164736f6c6343000806000a", + Bin: "0x60a06040523480156200001157600080fd5b506040516200607b3803806200607b833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615ea0620001db6000396000818161060b0152613a8c0152615ea06000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095b578063ee9d2d3814610982578063f2fde38b146109af57600080fd5b8063dc311dd3146108f7578063e72f6e3014610928578063e8509bff1461094857600080fd5b8063d98e620e116100bb578063d98e620e14610881578063da2f2610146108a1578063dac83d29146108d757600080fd5b8063bec4c08c14610821578063caf70c4a14610841578063cb6317971461086157600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107c1578063b08c8795146107e1578063b2a7cac51461080157600080fd5b8063a4c0ed3614610761578063a8cb447b14610781578063aa433aff146107a157600080fd5b80639b1c385e116101745780639b1c385e146106f25780639d40a6fd14610712578063a21a23e41461074c57600080fd5b806386fe91c7146106a85780638da5cb5b146106d457600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461062d5780636f64f03f1461067357806379ba50971461069357600080fd5b806364d51a2a146105c457806366316d8d146105d9578063689c4517146105f957600080fd5b806346d8d4861161022d57806346d8d4861461056457806357133e64146105845780635d06b4ab146105a457600080fd5b806340d6bb821461050957806341af6c871461053457600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610495578063330987b3146104b1578063405b84fa146104e957600080fd5b80630ae095401461041557806315c48b84146104355780631b6b6d231461045d57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103f557600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109cf565b60405161031a939291906159c7565b60405180910390f35b34801561032f57600080fd5b5061034361033e366004615375565b610a4b565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600a546103bd9061ffff81169063ffffffff62010000820481169160ff600160301b8204169167010000000000000082048116916b01000000000000000000000090041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a00161031a565b34801561040157600080fd5b506103436104103660046154b6565b610c0d565b34801561042157600080fd5b5061034361043036600461575b565b610da1565b34801561044157600080fd5b5061044a60c881565b60405161ffff909116815260200161031a565b34801561046957600080fd5b5060025461047d906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b3480156104a157600080fd5b506040516001815260200161031a565b3480156104bd57600080fd5b506104d16104cc366004615589565b610e6f565b6040516001600160601b03909116815260200161031a565b3480156104f557600080fd5b5061034361050436600461575b565b6113a3565b34801561051557600080fd5b5061051f6101f481565b60405163ffffffff909116815260200161031a565b34801561054057600080fd5b5061055461054f36600461550b565b611783565b604051901515815260200161031a565b34801561057057600080fd5b5061034361057f366004615392565b611985565b34801561059057600080fd5b5061034361059f3660046153c7565b611b02565b3480156105b057600080fd5b506103436105bf366004615375565b611b7b565b3480156105d057600080fd5b5061044a606481565b3480156105e557600080fd5b506103436105f4366004615392565b611c52565b34801561060557600080fd5b5061047d7f000000000000000000000000000000000000000000000000000000000000000081565b34801561063957600080fd5b50600f546106569063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561067f57600080fd5b5061034361068e366004615400565b611df1565b34801561069f57600080fd5b50610343611f09565b3480156106b457600080fd5b506007546104d1906801000000000000000090046001600160601b031681565b3480156106e057600080fd5b506000546001600160a01b031661047d565b3480156106fe57600080fd5b5061035b61070d366004615667565b611fba565b34801561071e57600080fd5b506007546107339067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561075857600080fd5b5061035b6123e4565b34801561076d57600080fd5b5061034361077c36600461542d565b61266c565b34801561078d57600080fd5b5061034361079c366004615375565b61283e565b3480156107ad57600080fd5b506103436107bc36600461550b565b612959565b3480156107cd57600080fd5b5060035461047d906001600160a01b031681565b3480156107ed57600080fd5b506103436107fc3660046156bd565b6129b9565b34801561080d57600080fd5b5061034361081c36600461550b565b612b55565b34801561082d57600080fd5b5061034361083c36600461575b565b612ca4565b34801561084d57600080fd5b5061035b61085c3660046154d2565b612e5a565b34801561086d57600080fd5b5061034361087c36600461575b565b612e8a565b34801561088d57600080fd5b5061035b61089c36600461550b565b61318e565b3480156108ad57600080fd5b5061047d6108bc36600461550b565b600b602052600090815260409020546001600160a01b031681565b3480156108e357600080fd5b506103436108f236600461575b565b6131af565b34801561090357600080fd5b5061091761091236600461550b565b6132ce565b60405161031a959493929190615b65565b34801561093457600080fd5b50610343610943366004615375565b6133ca565b61034361095636600461550b565b613592565b34801561096757600080fd5b506007546104d190600160a01b90046001600160601b031681565b34801561098e57600080fd5b5061035b61099d36600461550b565b600d6020526000908152604090205481565b3480156109bb57600080fd5b506103436109ca366004615375565b6136d1565b600a54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3957602002820191906000526020600020905b815481526020019060010190808311610a25575b50505050509050925092509250909192565b610a536136e2565b60105460005b81811015610be057826001600160a01b031660108281548110610a7e57610a7e615e44565b6000918252602090912001546001600160a01b03161415610bce576010610aa6600184615d3c565b81548110610ab657610ab6615e44565b600091825260209091200154601080546001600160a01b039092169183908110610ae257610ae2615e44565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826010610b19600185615d3c565b81548110610b2957610b29615e44565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506010805480610b6857610b68615e2e565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bd881615dab565b915050610a59565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c156136e2565b604080518082018252600091610c44919084906002908390839080828437600092019190915250612e5a915050565b6000818152600b60205260409020549091506001600160a01b031680610c8057604051631dfd6e1360e21b815260048101839052602401610c01565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d585782600c8281548110610cbb57610cbb615e44565b90600052602060002001541415610d4657600c805460009190610ce090600190615d3c565b81548110610cf057610cf0615e44565b9060005260206000200154905080600c8381548110610d1157610d11615e44565b600091825260209091200155600c805480610d2e57610d2e615e2e565b60019003818190600052602060002001600090559055505b80610d5081615dab565b915050610c9d565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9491815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610dd957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0d57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615610e385760405163769dd35360e11b815260040160405180910390fd5b610e4184611783565b15610e5f57604051631685ecdd60e31b815260040160405180910390fd5b610e69848461373e565b50505050565b600a54600090600160301b900460ff1615610e9d5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eae85856138d5565b90506000846060015163ffffffff1667ffffffffffffffff811115610ed557610ed5615e5a565b604051908082528060200260200182016040528015610efe578160200160208202803683370190505b50905060005b856060015163ffffffff16811015610f7e57826040015181604051602001610f36929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f6157610f61615e44565b602090810291909101015280610f7681615dab565b915050610f04565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e30000000000000000000000000000000000000000000000000000000091610fcf91908690602401615a3a565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990941693909317909252600a805466ff0000000000001916600160301b17905590880151608089015191925060009161104c9163ffffffff169084613bc8565b600a805466ff00000000000019169055602089810151600090815260069091526040902054909150600160c01b900467ffffffffffffffff16611090816001615cbb565b6020808b01516000908152600690915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915560a08a015180516110ef90600190615d3c565b815181106110ff576110ff615e44565b602091010151600a5460f89190911c6001149150600090611138908a906b010000000000000000000000900463ffffffff163a85613c16565b90508115611241576020808c01516000908152600690915260409020546001600160601b03808316600160601b90920416101561118857604051631e9acf1760e31b815260040160405180910390fd5b60208b81015160009081526006909152604090208054829190600c906111bf908490600160601b90046001600160601b0316615d53565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261121891859116615ce7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555061132d565b6020808c01516000908152600690915260409020546001600160601b038083169116101561128257604051631e9acf1760e31b815260040160405180910390fd5b6020808c0151600090815260069091526040812080548392906112af9084906001600160601b0316615d53565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600890915281208054859450909261130891859116615ce7565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b8a6020015188602001517f49580fdfd9497e1ed5c1b1cec0495087ae8e3f1267470ec2fb015db32e3d6aa78a60400151848860405161138a939291909283526001600160601b039190911660208301521515604082015260600190565b60405180910390a3985050505050505050505b92915050565b6113ac81613c66565b6113d457604051635428d44960e01b81526001600160a01b0382166004820152602401610c01565b6000806000806113e3866132ce565b945094505093509350336001600160a01b0316826001600160a01b03161461144d5760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c01565b61145686611783565b156114a35760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c01565b60006040518060c001604052806114b8600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b0316815250905060008160405160200161150c9190615952565b604051602081830303815290604052905061152688613cd0565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061157890859060040161593f565b6000604051808303818588803b15801561159157600080fd5b505af11580156115a5573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561160157600080fd5b505af1158015611615573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061163991906154ee565b6116855760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c01565b60005b8351811015611736578381815181106116a3576116a3615e44565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561170b57600080fd5b505af115801561171f573d6000803e3d6000fd5b50505050808061172e90615dab565b915050611688565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561180d57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117ef575b505050505081525050905060005b81604001515181101561197b5760005b600c54811015611968576000611931600c838154811061184d5761184d615e44565b90600052602060002001548560400151858151811061186e5761186e615e44565b602002602001015188600460008960400151898151811061189157611891615e44565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119555750600195945050505050565b508061196081615dab565b91505061182b565b508061197381615dab565b91505061181b565b5060009392505050565b600a54600160301b900460ff16156119b05760405163769dd35360e11b815260040160405180910390fd5b336000908152600960205260409020546001600160601b03808316911610156119ec57604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611a149084906001600160601b0316615d53565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a5c9190615d53565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611ad6576040519150601f19603f3d011682016040523d82523d6000602084013e611adb565b606091505b5050905080611afd57604051630dcf35db60e41b815260040160405180910390fd5b505050565b611b0a6136e2565b6002546001600160a01b031615611b4d576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611b836136e2565b611b8c81613c66565b15611bce576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c01565b601080546001810182556000919091527f1b6847dc741a1b0cd08d278845f9d819d87b734759afb55fe2de5cb82a9ae6720180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600a54600160301b900460ff1615611c7d5760405163769dd35360e11b815260040160405180910390fd5b336000908152600860205260409020546001600160601b0380831691161015611cb957604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611ce19084906001600160601b0316615d53565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611d299190615d53565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d9857600080fd5b505af1158015611dac573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dd091906154ee565b611ded57604051631e9acf1760e31b815260040160405180910390fd5b5050565b611df96136e2565b604080518082018252600091611e28919084906002908390839080828437600092019190915250612e5a915050565b6000818152600b60205260409020549091506001600160a01b031615611e7d576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c01565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d94565b6001546001600160a01b03163314611f635760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c01565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600a54600090600160301b900460ff1615611fe85760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b031661202357604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612075576040516379bfd40160e01b815260208401356004820152336024820152604401610c01565b600a5461ffff1661208c60608501604086016156a2565b61ffff1610806120af575060c86120a960608501604086016156a2565b61ffff16115b156120f5576120c460608401604085016156a2565b600a5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c01565b600a5462010000900463ffffffff166121146080850160608601615780565b63ffffffff16111561217d576121306080840160608501615780565b600a546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c01565b6101f461219060a0850160808601615780565b63ffffffff1611156121ef576121ac60a0840160808501615780565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c01565b60006121fc826001615cbb565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061228d9061228890890189615bbb565b613f20565b9050600061229a82613fcf565b9050836122a5614055565b60208a01356122ba60808c0160608d01615780565b6122ca60a08d0160808e01615780565b33866040516020016122e29796959493929190615ac7565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061235991906156a2565b8e606001602081019061236c9190615780565b8f608001602081019061237f9190615780565b8960405161239296959493929190615a88565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff191667ffffffffffffffff9490941693909317909255925050505b919050565b600a54600090600160301b900460ff16156124125760405163769dd35360e11b815260040160405180910390fd5b600033612420600143615d3c565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124b883615dc6565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff8111156124fa576124fa615e5a565b604051908082528060200260200182016040528015612523578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b03928316178355925160018301805490941691161790915592518051949550909361262e9260028501920190615089565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600a54600160301b900460ff16156126975760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b031633146126db576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612715576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006127238284018461550b565b6000818152600560205260409020549091506001600160a01b031661275b57604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127828385615ce7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127ca9190615ce7565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a82878461281d9190615ca3565b604080519283526020830191909152015b60405180910390a2505050505050565b6128466136e2565b6007544790600160a01b90046001600160601b031681811115612886576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611afd57600061289a8284615d3c565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128e9576040519150601f19603f3d011682016040523d82523d6000602084013e6128ee565b606091505b505090508061291057604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6129616136e2565b6000818152600560205260409020546001600160a01b031661299657604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0a9082906001600160a01b031661373e565b6129c16136e2565b60c861ffff871611156129fb5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c01565b60008213612a1f576040516321ea67b360e11b815260048101839052602401610c01565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600a805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff00000000000000000000001916176b01000000000000000000000083021790558a51600f80548d87015192891667ffffffffffffffff1990911617640100000000928916929092029190911790819055600e8d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600a54600160301b900460ff1615612b805760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612bb557604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c2757600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c01565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612cdc57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d1057604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612d3b5760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612d87576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612dbf57610e69565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612e6d9190615931565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612ec257604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612ef657604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612f215760405163769dd35360e11b815260040160405180910390fd5b612f2a84611783565b15612f4857604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16612fa5576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c01565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561300857602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612fea575b5050505050905060006001825161301f9190615d3c565b905060005b825181101561312b57856001600160a01b031683828151811061304957613049615e44565b60200260200101516001600160a01b0316141561311957600083838151811061307457613074615e44565b6020026020010151905080600560008a815260200190815260200160002060020183815481106130a6576130a6615e44565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394909416939093179092558981526005909152604090206002018054806130f1576130f1615e2e565b600082815260209020810160001990810180546001600160a01b03191690550190555061312b565b8061312381615dab565b915050613024565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161282e565b600c818154811061319e57600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b0316806131e757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461321b57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff16156132465760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e695760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e4c565b6000818152600560205260408120548190819081906060906001600160a01b031661330c57604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156133b057602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613392575b505050505090509450945094509450945091939590929450565b6133d26136e2565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561342f57600080fd5b505afa158015613443573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134679190615524565b6007549091506801000000000000000090046001600160601b0316818111156134ad576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611afd5760006134c18284615d3c565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561351157600080fd5b505af1158015613525573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061354991906154ee565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600a54600160301b900460ff16156135bd5760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b03166135f257604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136218385615ce7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136699190615ce7565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136bc9190615ca3565b60408051928352602083019190915201612c98565b6136d96136e2565b610c0a816140ee565b6000546001600160a01b0316331461373c5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c01565b565b60008061374a84613cd0565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137a757600080fd5b505af11580156137bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137df91906154ee565b6137fc57604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613852576040519150601f19603f3d011682016040523d82523d6000602084013e613857565b606091505b505090508061387957604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b604080516060810182526000808252602082018190529181019190915260006139018460000151612e5a565b6000818152600b60205260409020549091506001600160a01b03168061393d57604051631dfd6e1360e21b815260048101839052602401610c01565b600082866080015160405160200161395f929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d909352912054909150806139be576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85516020808801516040808a015160608b015160808c015160a08d015193516139ed978a979096959101615b11565b604051602081830303815290604052805190602001208114613a3b576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a4a8760000151614198565b905080613b565786516040517fe9413d3800000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063e9413d389060240160206040518083038186803b158015613ad657600080fd5b505afa158015613aea573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b0e9190615524565b905080613b565786516040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c01565b6000886080015182604051602001613b78929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c90506000613b9f8a8361429f565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613bda57600080fd5b611388810390508460408204820311613bf257600080fd5b50823b613bfe57600080fd5b60008083516020850160008789f190505b9392505050565b60008115613c4457600f54613c3d9086908690640100000000900463ffffffff168661430a565b9050613c5e565b600f54613c5b908690869063ffffffff1686614374565b90505b949350505050565b6000805b601054811015613cc757826001600160a01b031660108281548110613c9157613c91615e44565b6000918252602090912001546001600160a01b03161415613cb55750600192915050565b80613cbf81615dab565b915050613c6a565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613d5c57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613d3e575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b826040015151811015613e3a576004600084604001518381518110613de957613de9615e44565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613e3281615dab565b915050613dc2565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590613e7260028301826150ee565b505060008581526006602052604081205560078054859190600890613ead9084906801000000000000000090046001600160601b0316615d53565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b0316613ef59190615d53565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60408051602081019091526000815281613f49575060408051602081019091526000815261139d565b7f92fd133800000000000000000000000000000000000000000000000000000000613f748385615d7b565b6001600160e01b03191614613fb5576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613fc28260048186615c79565b810190613c0f919061553d565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa8260405160240161400891511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b60004661a4b181148061406a575062066eed81145b156140e75760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140a957600080fd5b505afa1580156140bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140e19190615524565b91505090565b4391505090565b6001600160a01b0381163314156141475760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c01565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b18114806141ad575062066eed81145b1561428f576101008367ffffffffffffffff166141c8614055565b6141d29190615d3c565b11806141ef57506141e1614055565b8367ffffffffffffffff1610155b156141fd5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561425757600080fd5b505afa15801561426b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c0f9190615524565b505067ffffffffffffffff164090565b60006142d38360000151846020015185604001518660600151868860a001518960c001518a60e001518b610100015161447b565b600383602001516040516020016142eb929190615a26565b60408051601f1981840301815291905280516020909101209392505050565b6000806143156146b6565b905060005a6143248888615ca3565b61432e9190615d3c565b6143389085615d1d565b9050600061435163ffffffff871664e8d4a51000615d1d565b90508261435e8284615ca3565b6143689190615ca3565b98975050505050505050565b60008061437f614712565b9050600081136143a5576040516321ea67b360e11b815260048101829052602401610c01565b60006143af6146b6565b9050600082825a6143c08b8b615ca3565b6143ca9190615d3c565b6143d49088615d1d565b6143de9190615ca3565b6143f090670de0b6b3a7640000615d1d565b6143fa9190615d09565b9050600061441363ffffffff881664e8d4a51000615d1d565b905061442b816b033b2e3c9fd0803ce8000000615d3c565b821115614464576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61446e8183615ca3565b9998505050505050505050565b614484896147fa565b6144d05760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c01565b6144d9886147fa565b6145255760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c01565b61452e836147fa565b61457a5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c01565b614583826147fa565b6145cf5760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c01565b6145db878a88876148d3565b6146275760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c01565b60006146338a87614a08565b90506000614646898b878b868989614a6c565b90506000614657838d8d8a86614b8c565b9050808a146146a85760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c01565b505050505050505050505050565b60004661a4b18114806146cb575062066eed81145b1561470a57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140a957600080fd5b600091505090565b600a54600354604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b15801561478d57600080fd5b505afa1580156147a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906147c5919061579b565b5094509092508491505080156147e957506147e08242615d3c565b8463ffffffff16105b15613c5e5750600e54949350505050565b80516000906401000003d019116148535760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d019116148ac5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d0199080096148cc8360005b6020020151614bcc565b1492915050565b60006001600160a01b03821661492b5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c01565b60208401516000906001161561494257601c614945565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa1580156149e0573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614a1061510c565b614a3d60018484604051602001614a2993929190615910565b604051602081830303815290604052614bf0565b90505b614a49816147fa565b61139d578051604080516020810192909252614a659101614a29565b9050614a40565b614a7461510c565b825186516401000003d0199081900691061415614ad35760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c01565b614ade878988614c3e565b614b2a5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c01565b614b35848685614c3e565b614b815760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c01565b614368868484614d78565b600060028686868587604051602001614baa969594939291906158b1565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614bf861510c565b614c0182614e3f565b8152614c16614c118260006148c2565b614e7a565b6020820181905260029006600114156123df576020810180516401000003d019039052919050565b600082614c8d5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c01565b83516020850151600090614ca390600290615dee565b15614caf57601c614cb2565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614d24573d6000803e3d6000fd5b505050602060405103519050600086604051602001614d43919061589f565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614d8061510c565b835160208086015185519186015160009384938493614da193909190614e9a565b919450925090506401000003d019858209600114614e015760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c01565b60405180604001604052806401000003d01980614e2057614e20615e18565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106123df57604080516020808201939093528151808203840181529082019091528051910120614e47565b600061139d826002614e936401000003d0196001615ca3565b901c614f7a565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614eda8383858561501c565b9098509050614eeb88828e88615040565b9098509050614efc88828c87615040565b90985090506000614f0f8d878b85615040565b9098509050614f208882868661501c565b9098509050614f3188828e89615040565b9098509050818114614f66576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614f6a565b8196505b5050505050509450945094915050565b600080614f8561512a565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a0820152614fb7615148565b60208160c0846005600019fa9250826150125760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c01565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156150de579160200282015b828111156150de57825182546001600160a01b0319166001600160a01b039091161782556020909201916001909101906150a9565b506150ea929150615166565b5090565b5080546000825590600052602060002090810190610c0a9190615166565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156150ea5760008155600101615167565b80356123df81615e70565b806040810183101561139d57600080fd5b600082601f8301126151a857600080fd5b6151b0615c09565b8083856040860111156151c257600080fd5b60005b60028110156151e45781358452602093840193909101906001016151c5565b509095945050505050565b600082601f83011261520057600080fd5b813567ffffffffffffffff8082111561521b5761521b615e5a565b604051601f8301601f19908116603f0116810190828211818310171561524357615243615e5a565b8160405283815286602085880101111561525c57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600060c0828403121561528e57600080fd5b615296615c32565b9050813567ffffffffffffffff80821682146152b157600080fd5b818352602084013560208401526152ca60408501615330565b60408401526152db60608501615330565b60608401526152ec6080850161517b565b608084015260a084013591508082111561530557600080fd5b50615312848285016151ef565b60a08301525092915050565b803561ffff811681146123df57600080fd5b803563ffffffff811681146123df57600080fd5b805169ffffffffffffffffffff811681146123df57600080fd5b80356001600160601b03811681146123df57600080fd5b60006020828403121561538757600080fd5b8135613c0f81615e70565b600080604083850312156153a557600080fd5b82356153b081615e70565b91506153be6020840161535e565b90509250929050565b600080604083850312156153da57600080fd5b82356153e581615e70565b915060208301356153f581615e70565b809150509250929050565b6000806060838503121561541357600080fd5b823561541e81615e70565b91506153be8460208501615186565b6000806000806060858703121561544357600080fd5b843561544e81615e70565b935060208501359250604085013567ffffffffffffffff8082111561547257600080fd5b818701915087601f83011261548657600080fd5b81358181111561549557600080fd5b8860208285010111156154a757600080fd5b95989497505060200194505050565b6000604082840312156154c857600080fd5b613c0f8383615186565b6000604082840312156154e457600080fd5b613c0f8383615197565b60006020828403121561550057600080fd5b8151613c0f81615e85565b60006020828403121561551d57600080fd5b5035919050565b60006020828403121561553657600080fd5b5051919050565b60006020828403121561554f57600080fd5b6040516020810181811067ffffffffffffffff8211171561557257615572615e5a565b604052823561558081615e85565b81529392505050565b6000808284036101c081121561559e57600080fd5b6101a0808212156155ae57600080fd5b6155b6615c55565b91506155c28686615197565b82526155d18660408701615197565b60208301526080850135604083015260a0850135606083015260c0850135608083015261560060e0860161517b565b60a083015261010061561487828801615197565b60c0840152615627876101408801615197565b60e08401526101808601359083015290925083013567ffffffffffffffff81111561565157600080fd5b61565d8582860161527c565b9150509250929050565b60006020828403121561567957600080fd5b813567ffffffffffffffff81111561569057600080fd5b820160c08185031215613c0f57600080fd5b6000602082840312156156b457600080fd5b613c0f8261531e565b60008060008060008086880360e08112156156d757600080fd5b6156e08861531e565b96506156ee60208901615330565b95506156fc60408901615330565b945061570a60608901615330565b9350608088013592506040609f198201121561572557600080fd5b5061572e615c09565b61573a60a08901615330565b815261574860c08901615330565b6020820152809150509295509295509295565b6000806040838503121561576e57600080fd5b8235915060208301356153f581615e70565b60006020828403121561579257600080fd5b613c0f82615330565b600080600080600060a086880312156157b357600080fd5b6157bc86615344565b94506020860151935060408601519250606086015191506157df60808701615344565b90509295509295909350565b600081518084526020808501945080840160005b838110156158245781516001600160a01b0316875295820195908201906001016157ff565b509495945050505050565b8060005b6002811015610e69578151845260209384019390910190600101615833565b6000815180845260005b818110156158785760208185018101518683018201520161585c565b8181111561588a576000602083870101525b50601f01601f19169290920160200192915050565b6158a9818361582f565b604001919050565b8681526158c1602082018761582f565b6158ce606082018661582f565b6158db60a082018561582f565b6158e860e082018461582f565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b838152615920602082018461582f565b606081019190915260800192915050565b6040810161139d828461582f565b602081526000613c0f6020830184615852565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261599860e08401826157eb565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615a18578451835293830193918301916001016159fc565b509098975050505050505050565b82815260608101613c0f602083018461582f565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a7b57845183529383019391830191600101615a5f565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261436860c0830184615852565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261446e60e0830184615852565b87815267ffffffffffffffff87166020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261446e60e0830184615852565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615bb060a08301846157eb565b979650505050505050565b6000808335601e19843603018112615bd257600080fd5b83018035915067ffffffffffffffff821115615bed57600080fd5b602001915036819003821315615c0257600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c2c57615c2c615e5a565b60405290565b60405160c0810167ffffffffffffffff81118282101715615c2c57615c2c615e5a565b604051610120810167ffffffffffffffff81118282101715615c2c57615c2c615e5a565b60008085851115615c8957600080fd5b83861115615c9657600080fd5b5050820193919092039150565b60008219821115615cb657615cb6615e02565b500190565b600067ffffffffffffffff808316818516808303821115615cde57615cde615e02565b01949350505050565b60006001600160601b03808316818516808303821115615cde57615cde615e02565b600082615d1857615d18615e18565b500490565b6000816000190483118215151615615d3757615d37615e02565b500290565b600082821015615d4e57615d4e615e02565b500390565b60006001600160601b0383811690831681811015615d7357615d73615e02565b039392505050565b6001600160e01b03198135818116916004851015615da35780818660040360031b1b83161692505b505092915050565b6000600019821415615dbf57615dbf615e02565b5060010190565b600067ffffffffffffffff80831681811415615de457615de4615e02565b6001019392505050565b600082615dfd57615dfd615e18565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0a57600080fd5b8015158114610c0a57600080fdfea164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 370ec8ae28d..80f053cb534 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -70,7 +70,7 @@ vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2Up vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b vrf_coordinator_v2_plus_v2_example: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.bin 02d0ec25e4f3d72f818e7ebc2b5f5949a94889ab0da091f0d3e7f5e4a20a0bb6 -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 9431978916acb3064a06994d273073168a4081a4ddb0d533bd4baa8bbcc6aa9a +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 177efc55a336d4f5b643142b8528be16d710d52324f36ef09f1ff1d27ff41747 vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c From a940319931a09242ac02dc32262e5fe395ff8c22 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Mon, 14 Aug 2023 16:47:28 -0400 Subject: [PATCH 165/270] fix typos in automation 2.1 (#10190) --- .../src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol | 4 ++-- .../src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol index 1535b62f12f..ca3d6f7efd0 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicA2_1.sol @@ -388,7 +388,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { /** * @notice received upkeeps migrated from another registry * @param encodedUpkeeps the raw upkeep data to import - * @dev this function is never called direcly, it is only called by another registry's migrate function + * @dev this function is never called directly, it is only called by another registry's migrate function */ function receiveUpkeeps(bytes calldata encodedUpkeeps) external { if ( @@ -425,7 +425,7 @@ contract KeeperRegistryLogicA2_1 is KeeperRegistryBase2_1, Chainable { /** * @notice sets the upkeep trigger config * @param id the upkeepID to change the trigger for - * @param triggerConfig the new triggerconfig + * @param triggerConfig the new trigger config */ function setUpkeepTriggerConfig(uint256 id, bytes calldata triggerConfig) external { _requireAdminAndNotCancelled(id); diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol index c26538b0923..c34d2a01aaf 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryLogicB2_1.sol @@ -167,7 +167,7 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { ///////////////////////////// /** - * @notice sets the privledge config for an upkeep + * @notice sets the privilege config for an upkeep */ function setUpkeepPrivilegeConfig(uint256 upkeepId, bytes calldata newPrivilegeConfig) external { if (msg.sender != s_storage.upkeepPrivilegeManager) { @@ -240,8 +240,8 @@ contract KeeperRegistryLogicB2_1 is KeeperRegistryBase2_1 { } /** - * @notice sets a generic bytes field used to indicate the privledges that this admin address had - * @param admin the address to set privledges for + * @notice sets a generic bytes field used to indicate the privilege that this admin address had + * @param admin the address to set privilege for * @param newPrivilegeConfig the privileges that this admin has */ function setAdminPrivilegeConfig(address admin, bytes calldata newPrivilegeConfig) external { From 5cc5088993f514c1f71eb1e45e4c97bac13c3fc0 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Tue, 15 Aug 2023 01:56:24 +0300 Subject: [PATCH 166/270] TT-472 migration docker tests (#10199) --- .../migration/upgrade_version_test.go | 79 +++++-------------- 1 file changed, 19 insertions(+), 60 deletions(-) diff --git a/integration-tests/migration/upgrade_version_test.go b/integration-tests/migration/upgrade_version_test.go index b9c3ff01756..1f90bd123eb 100644 --- a/integration-tests/migration/upgrade_version_test.go +++ b/integration-tests/migration/upgrade_version_test.go @@ -1,78 +1,37 @@ package migration import ( - "fmt" - "strings" "testing" - "github.com/stretchr/testify/require" - "go.uber.org/zap/zapcore" - - "github.com/smartcontractkit/chainlink-env/environment" - "github.com/smartcontractkit/chainlink-env/pkg/helm/chainlink" - "github.com/smartcontractkit/chainlink-env/pkg/helm/ethereum" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/utils" + "github.com/stretchr/testify/require" - "github.com/smartcontractkit/chainlink/integration-tests/actions" - "github.com/smartcontractkit/chainlink/integration-tests/client" - "github.com/smartcontractkit/chainlink/integration-tests/config" - "github.com/smartcontractkit/chainlink/integration-tests/networks" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + "os" ) func TestVersionUpgrade(t *testing.T) { t.Parallel() - testEnvironment, testNetwork := setupUpgradeTest(t) - if testEnvironment.WillUseRemoteRunner() { - return - } + env, err := test_env.NewCLTestEnvBuilder(). + WithGeth(). + WithCLNodes(1). + Build() + require.NoError(t, err) upgradeImage, err := utils.GetEnv("UPGRADE_IMAGE") require.NoError(t, err, "Error getting upgrade image") upgradeVersion, err := utils.GetEnv("UPGRADE_VERSION") require.NoError(t, err, "Error getting upgrade version") - chainClient, err := blockchain.NewEVMClient(testNetwork, testEnvironment) - require.NoError(t, err, "Connecting to blockchain nodes shouldn't fail") - chainlinkNodes, err := client.ConnectChainlinkNodes(testEnvironment) - require.NoError(t, err, "Connecting to chainlink nodes shouldn't fail") - - t.Cleanup(func() { - err := actions.TeardownSuite(t, testEnvironment, utils.ProjectRoot, chainlinkNodes, nil, zapcore.ErrorLevel, chainClient) - require.NoError(t, err, "Error tearing down environment") - }) - - err = actions.UpgradeChainlinkNodeVersions(testEnvironment, upgradeImage, upgradeVersion, chainlinkNodes[0]) - require.NoError(t, err, "Upgrading chainlink nodes shouldn't fail") -} - -func setupUpgradeTest(t *testing.T) ( - testEnvironment *environment.Environment, - testNetwork blockchain.EVMNetwork, -) { - testNetwork = networks.SelectedNetwork - evmConfig := ethereum.New(nil) - if !testNetwork.Simulated { - evmConfig = ethereum.New(ðereum.Props{ - NetworkName: testNetwork.Name, - Simulated: testNetwork.Simulated, - WsURLs: testNetwork.URLs, - }) - } - charts, err := chainlink.NewDeployment(1, map[string]any{ - "toml": client.AddNetworksConfig(config.BaseOCRP2PV1Config, testNetwork), - "db": map[string]any{ - "stateful": true, - }, - }) - require.NoError(t, err, "Error creating chainlink deployments") - testEnvironment = environment.New(&environment.Config{ - NamespacePrefix: fmt.Sprintf("upgrade-version-%s", strings.ReplaceAll(strings.ToLower(testNetwork.Name), " ", "-")), - Test: t, - }). - AddHelm(evmConfig). - AddHelmCharts(charts) - err = testEnvironment.Run() - require.NoError(t, err, "Error launching test environment") - return testEnvironment, testNetwork + _ = os.Setenv("CHAINLINK_IMAGE", upgradeImage) + _ = os.Setenv("CHAINLINK_VERSION", upgradeVersion) + + // just restarting CL container with the same name, DB is still the same + // + // [Database] + // MigrateOnStartup = true + // + // by default + err = env.CLNodes[0].Restart(env.CLNodes[0].NodeConfig) + require.NoError(t, err) } From fb8116d5ecdde67f62b789cf8becc5331e9b53e5 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Tue, 15 Aug 2023 03:17:35 +0300 Subject: [PATCH 167/270] enable RUYK container (#10200) * enable RUYK container * fix external http url --- .github/workflows/integration-tests.yml | 1 - integration-tests/docker/test_env/geth.go | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 09eece04f78..b767d99721c 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -391,7 +391,6 @@ jobs: if: needs.changes.outputs.src == 'true' uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 env: - TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }} diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index 85c05c664c8..e26bdf9cb23 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -87,7 +87,7 @@ func (g *Geth) StartContainer() error { networkConfig := blockchain.SimulatedEVMNetwork networkConfig.Name = "geth" networkConfig.URLs = []string{g.ExternalWsUrl} - networkConfig.HTTPURLs = []string{g.ExternalWsUrl} + networkConfig.HTTPURLs = []string{g.ExternalHttpUrl} bc, err := blockchain.NewEVMClientFromNetwork(networkConfig) if err != nil { From 67b1f2d6ebedf62f323695f8060c2ea3ed3b341e Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Tue, 15 Aug 2023 05:51:29 +0200 Subject: [PATCH 168/270] matrix foundry tests and snapshots (#10022) * matrix foundry tests and snapshots * make snapshot great again * add product based make wrapper commands * update snapshots and reduce CI scope * use new wrapper gen in CI * split hardhat CI and generic Solidity CI make running HH CI more restrictive * add shared Foundry profile & fix typeAndVersion * clean up needs trigger and add comment * add foundry.toml CI trigger * getwrapper generation in products folders * rename llo -> llo-feeds * make snapshot-all * foundryup && update snapshots * fix naming in comments --- .github/workflows/solidity-foundry.yml | 25 +- .github/workflows/solidity-hardhat.yml | 177 ++++++++++++++ .github/workflows/solidity.yml | 183 +-------------- GNUmakefile | 33 --- contracts/.gas-snapshot | 8 - contracts/GNUmakefile | 80 +++++++ contracts/foundry.toml | 19 ++ .../gas-snapshots/automation-dev.gas-snapshot | 5 + .../gas-snapshots/automation.gas-snapshot | 8 + .../gas-snapshots/functions.gas-snapshot | 11 + .../gas-snapshots/llo-feeds.gas-snapshot | 219 ++++++++++++++++++ contracts/gas-snapshots/shared.gas-snapshot | 0 contracts/gas-snapshots/vrf.gas-snapshot | 14 ++ contracts/scripts/native_solc_compile_all | 2 +- ..._llo => native_solc_compile_all_llo-feeds} | 0 core/gethwrappers/go_generate_test.go | 4 +- 16 files changed, 560 insertions(+), 228 deletions(-) create mode 100644 .github/workflows/solidity-hardhat.yml delete mode 100644 contracts/.gas-snapshot create mode 100644 contracts/GNUmakefile create mode 100644 contracts/gas-snapshots/automation-dev.gas-snapshot create mode 100644 contracts/gas-snapshots/automation.gas-snapshot create mode 100644 contracts/gas-snapshots/functions.gas-snapshot create mode 100644 contracts/gas-snapshots/llo-feeds.gas-snapshot create mode 100644 contracts/gas-snapshots/shared.gas-snapshot create mode 100644 contracts/gas-snapshots/vrf.gas-snapshot rename contracts/scripts/{native_solc_compile_all_llo => native_solc_compile_all_llo-feeds} (100%) diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index bac136ec164..755874b9462 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -16,13 +16,20 @@ jobs: - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 id: changes with: + # Foundry is only used for Solidity v0.8 contracts, therefore we can ignore + # changes to older contracts. filters: | src: - - 'contracts/**/*' + - 'contracts/src/v0.8/**/*' - '.github/workflows/solidity-foundry.yml' + - 'contacts/foundry.toml' tests: + strategy: + matrix: + product: [ vrf, automation, llo-feeds, functions, automation-dev, shared ] needs: [changes] + if: needs.changes.outputs.changes == 'true' name: Tests # See https://github.com/foundry-rs/foundry/issues/3827 runs-on: ubuntu-22.04 @@ -37,36 +44,38 @@ jobs: # and not native Foundry. This is to make sure the dependencies # stay in sync. - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} uses: ./.github/actions/setup-nodejs - name: Install Foundry - if: ${{ needs.changes.outputs.changes == 'true' }} uses: foundry-rs/foundry-toolchain@v1 with: version: nightly - name: Run Forge build - if: ${{ needs.changes.outputs.changes == 'true' }} run: | forge --version forge build id: build working-directory: contracts + env: + FOUNDRY_PROFILE: ${{ matrix.product }} - name: Run Forge tests - if: ${{ needs.changes.outputs.changes == 'true' }} run: | forge test -vvv id: test working-directory: contracts + env: + FOUNDRY_PROFILE: ${{ matrix.product }} - name: Run Forge snapshot - if: ${{ needs.changes.outputs.changes == 'true' }} run: | - forge snapshot --match-test _gas --check + forge snapshot --check gas-snapshots/${{ matrix.product }}.gas-snapshot id: snapshot working-directory: contracts + env: + FOUNDRY_PROFILE: ${{ matrix.product }} + - name: Collect Metrics if: always() id: collect-gha-metrics @@ -74,5 +83,5 @@ jobs: with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} - this-job-name: Foundry Tests + this-job-name: Foundry Tests ${{ matrix.product }} continue-on-error: true diff --git a/.github/workflows/solidity-hardhat.yml b/.github/workflows/solidity-hardhat.yml new file mode 100644 index 00000000000..4a2394f17f0 --- /dev/null +++ b/.github/workflows/solidity-hardhat.yml @@ -0,0 +1,177 @@ +name: Solidity-Hardhat + +on: + merge_group: + push: + +env: + NODE_OPTIONS: --max_old_space_size=8192 + +defaults: + run: + shell: bash + +jobs: + changes: + name: Detect changes + runs-on: ubuntu-latest + outputs: + changes: ${{ steps.changes.outputs.src }} + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + - uses: dorny/paths-filter@4512585405083f25c027a35db413c2b3b9006d50 # v2.11.1 + id: changes + with: + filters: | + src: + - 'contracts/src/!(v0.8/(llo-feeds|ccip)/**)/**/*' + - 'contracts/test/**/*' + - 'contracts/package.json' + - 'contracts/hardhat.config.ts' + - 'contracts/ci.json' + - '.github/workflows/solidity-hardhat.yml' + + split-tests: + name: Split Solidity Tests + runs-on: ubuntu-latest + outputs: + splits: ${{ steps.split.outputs.splits }} + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + - name: Generate splits + id: split + uses: ./.github/actions/split-tests + with: + config: ./contracts/ci.json + - name: Collect Metrics + id: collect-gha-metrics + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + with: + basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} + hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} + this-job-name: Split Solidity Tests + continue-on-error: true + + solidity-coverage-splits: + needs: [changes, split-tests] + if: needs.changes.outputs.changes == 'true' + name: Solidity Coverage ${{ matrix.split.id }} ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} + strategy: + fail-fast: false + matrix: + split: ${{ fromJson(needs.split-tests.outputs.splits) }} + runs-on: ubuntu20.04-4cores-16GB + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + - name: Setup NodeJS + uses: ./.github/actions/setup-nodejs + - name: Setup Hardhat + uses: ./.github/actions/setup-hardhat + with: + namespace: coverage + - name: Run coverage + env: + SPLIT: ${{ matrix.split.coverageTests }} + shell: bash + run: pnpm coverage --testfiles "$SPLIT" + working-directory: contracts + - name: Push coverage + run: ./tools/bin/codecov -f ./contracts/coverage.json + - name: Rename coverage + run: mv ./contracts/coverage.json ./contracts/coverage-${{ matrix.split.idx }}.json + - name: Upload coverage + uses: actions/upload-artifact@v3 + with: + name: solidity-coverage-${{ matrix.split.idx }} + path: ./contracts/coverage-${{ matrix.split.idx }}.json + - name: Collect Metrics + id: collect-gha-metrics + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + with: + basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} + hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} + this-job-name: Solidity Coverage ${{ matrix.split.id }} + continue-on-error: true + + solidity-coverage: + needs: [changes, solidity-coverage-splits] + if: needs.changes.outputs.changes == 'true' + name: Solidity Coverage ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} + runs-on: ubuntu-latest + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + - name: Setup NodeJS + uses: ./.github/actions/setup-nodejs + - name: Make coverage directory + run: mkdir ./contracts/coverage-reports + - name: Download coverage + uses: actions/download-artifact@v3 + with: + path: ./contracts/coverage-reports + - name: Display structure of downloaded files + run: ls -R coverage-reports + working-directory: contracts + - name: Generate merged report + run: pnpm istanbul report text text-summary + working-directory: contracts + + solidity-splits: + needs: [changes, split-tests] + if: needs.changes.outputs.changes == 'true' + name: Solidity ${{ matrix.split.id }} ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} + strategy: + fail-fast: false + matrix: + split: ${{ fromJson(needs.split-tests.outputs.splits) }} + runs-on: ubuntu20.04-4cores-16GB + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + - name: Setup NodeJS + uses: ./.github/actions/setup-nodejs + - name: Setup Hardhat + uses: ./.github/actions/setup-hardhat + with: + namespace: coverage + - name: Run tests + env: + SPLIT: ${{ matrix.split.tests }} + working-directory: contracts + run: pnpm test -- $SPLIT + - name: Collect Metrics + id: collect-gha-metrics + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + with: + basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} + hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} + this-job-name: Solidity ${{ matrix.split.id }} + continue-on-error: true + + solidity: + needs: [changes, solidity-splits] + name: Solidity + runs-on: ubuntu-latest + if: always() + steps: + - run: echo 'Solidity tests finished!' + - name: Check test results + run: | + if [[ "${{ needs.changes.result }}" = "failure" || "${{ needs.solidity-splits.result }}" = "failure" ]]; then + echo "One or more changes / solidity-splits jobs failed" + exit 1 + else + echo "All test jobs passed successfully" + fi + - name: Collect Metrics + if: always() + id: collect-gha-metrics + uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + with: + basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} + hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} + this-job-name: Solidity + continue-on-error: true \ No newline at end of file diff --git a/.github/workflows/solidity.yml b/.github/workflows/solidity.yml index a8cd4107b32..75e8fda6add 100644 --- a/.github/workflows/solidity.yml +++ b/.github/workflows/solidity.yml @@ -4,9 +4,6 @@ on: merge_group: push: -env: - NODE_OPTIONS: --max_old_space_size=8192 - defaults: run: shell: bash @@ -28,179 +25,20 @@ jobs: - 'contracts/**/*' - '.github/workflows/solidity.yml' - split-tests: - name: Split Solidity Tests - runs-on: ubuntu-latest - outputs: - splits: ${{ steps.split.outputs.splits }} - steps: - - name: Checkout the repo - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - - name: Generate splits - id: split - uses: ./.github/actions/split-tests - with: - config: ./contracts/ci.json - - name: Collect Metrics - id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 - with: - basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} - hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} - this-job-name: Split Solidity Tests - continue-on-error: true - - solidity-coverage-splits: - needs: [changes, split-tests] - name: Solidity Coverage ${{ matrix.split.id }} ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} - strategy: - fail-fast: false - matrix: - split: ${{ fromJson(needs.split-tests.outputs.splits) }} - runs-on: ubuntu20.04-4cores-16GB - steps: - - name: Checkout the repo - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: ./.github/actions/setup-nodejs - - name: Setup Hardhat - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: ./.github/actions/setup-hardhat - with: - namespace: coverage - - name: Run coverage - if: ${{ needs.changes.outputs.changes == 'true' }} - env: - SPLIT: ${{ matrix.split.coverageTests }} - shell: bash - run: pnpm coverage --testfiles "$SPLIT" - working-directory: contracts - - name: Push coverage - if: ${{ needs.changes.outputs.changes == 'true' }} - run: ./tools/bin/codecov -f ./contracts/coverage.json - - name: Rename coverage - if: ${{ needs.changes.outputs.changes == 'true' }} - run: mv ./contracts/coverage.json ./contracts/coverage-${{ matrix.split.idx }}.json - - name: Upload coverage - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: actions/upload-artifact@v3 - with: - name: solidity-coverage-${{ matrix.split.idx }} - path: ./contracts/coverage-${{ matrix.split.idx }}.json - - name: Collect Metrics - if: ${{ needs.changes.outputs.changes == 'true' }} - id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 - with: - basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} - hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} - this-job-name: Solidity Coverage ${{ matrix.split.id }} - continue-on-error: true - - solidity-coverage: - needs: [changes, solidity-coverage-splits] - name: Solidity Coverage ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} - runs-on: ubuntu-latest - steps: - - name: Checkout the repo - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: ./.github/actions/setup-nodejs - - name: Make coverage directory - if: ${{ needs.changes.outputs.changes == 'true' }} - run: mkdir ./contracts/coverage-reports - - name: Download coverage - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: actions/download-artifact@v3 - with: - path: ./contracts/coverage-reports - - name: Display structure of downloaded files - if: ${{ needs.changes.outputs.changes == 'true' }} - run: ls -R coverage-reports - working-directory: contracts - - name: Generate merged report - if: ${{ needs.changes.outputs.changes == 'true' }} - run: pnpm istanbul report text text-summary - working-directory: contracts - - solidity-splits: - needs: [changes, split-tests] - name: Solidity ${{ matrix.split.id }} ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} - strategy: - fail-fast: false - matrix: - split: ${{ fromJson(needs.split-tests.outputs.splits) }} - runs-on: ubuntu20.04-4cores-16GB - steps: - - name: Checkout the repo - uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: ./.github/actions/setup-nodejs - - name: Setup Hardhat - if: ${{ needs.changes.outputs.changes == 'true' }} - uses: ./.github/actions/setup-hardhat - with: - namespace: coverage - - name: Run tests - if: ${{ needs.changes.outputs.changes == 'true' }} - env: - SPLIT: ${{ matrix.split.tests }} - working-directory: contracts - run: pnpm test -- $SPLIT - - name: Collect Metrics - if: ${{ needs.changes.outputs.changes == 'true' }} - id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 - with: - basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} - hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} - this-job-name: Solidity ${{ matrix.split.id }} - continue-on-error: true - - solidity: - needs: [changes, solidity-splits] - name: Solidity - runs-on: ubuntu-latest - if: always() - steps: - - run: echo 'Solidity tests finished!' - - name: Check test results - run: | - if [[ "${{ needs.changes.result }}" = "failure" || "${{ needs.solidity-splits.result }}" = "failure" ]]; then - echo "One or more changes / solidity-splits jobs failed" - exit 1 - else - echo "All test jobs passed successfully" - fi - - name: Collect Metrics - if: always() - id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 - with: - basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} - hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} - this-job-name: Solidity - continue-on-error: true - prepublish-test: needs: [changes] + if: needs.changes.outputs.changes == 'true' name: Prepublish Test ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} runs-on: ubuntu-latest steps: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} uses: ./.github/actions/setup-nodejs - name: Run Prepublish test - if: ${{ needs.changes.outputs.changes == 'true' }} working-directory: contracts run: pnpm prepublishOnly - name: Collect Metrics - if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: @@ -211,6 +49,7 @@ jobs: native-compile: needs: [changes] + if: needs.changes.outputs.changes == 'true' name: Native Compilation ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} runs-on: ubuntu-latest steps: @@ -225,18 +64,15 @@ jobs: - name: Install diff-so-fancy run: echo "$GITHUB_WORKSPACE/diff-so-fancy" >> $GITHUB_PATH - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} uses: ./.github/actions/setup-nodejs with: prod: "true" - name: Setup Go - if: ${{ needs.changes.outputs.changes == 'true' }} uses: ./.github/actions/setup-go - name: Run native compile and generate wrappers - if: ${{ needs.changes.outputs.changes == 'true' }} - run: make go-solidity-wrappers + run: make wrappers-all + working-directory: ./contracts - name: Verify local solc binaries - if: ${{ needs.changes.outputs.changes == 'true' }} run: ./tools/ci/check_solc_hashes - name: Check if Go solidity wrappers are updated if: ${{ needs.changes.outputs.changes == 'true' }} @@ -245,9 +81,8 @@ jobs: env: GITHUB_TOKEN: ${{ github.token }} if: ${{ failure() }} - run: gh pr comment -b 'Go solidity wrappers are out-of-date, regenerate them via the `make go-solidity-wrappers` command' + run: gh pr comment -b 'Go solidity wrappers are out-of-date, regenerate them via the `make wrappers-all` command' - name: Collect Metrics - if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: @@ -261,19 +96,17 @@ jobs: run: working-directory: contracts needs: [changes] + if: needs.changes.outputs.changes == 'true' name: Lint ${{ fromJSON('["(skipped)", ""]')[needs.changes.outputs.changes == 'true'] }} runs-on: ubuntu-latest steps: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} uses: ./.github/actions/setup-nodejs - name: Run pnpm lint - if: ${{ needs.changes.outputs.changes == 'true' }} run: pnpm lint - name: Collect Metrics - if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: @@ -287,19 +120,17 @@ jobs: run: working-directory: contracts needs: [changes] + if: needs.changes.outputs.changes == 'true' name: Prettier Formatting runs-on: ubuntu-latest steps: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Setup NodeJS - if: ${{ needs.changes.outputs.changes == 'true' }} uses: ./.github/actions/setup-nodejs - name: Run prettier check - if: ${{ needs.changes.outputs.changes == 'true' }} run: pnpm prettier:check - name: Collect Metrics - if: ${{ needs.changes.outputs.changes == 'true' }} id: collect-gha-metrics uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 with: diff --git a/GNUmakefile b/GNUmakefile index 0feef78effd..b9d11a7cbc6 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -89,36 +89,6 @@ operator-ui: ## Fetch the frontend abigen: ## Build & install abigen. ./tools/bin/build_abigen -.PHONY: go-solidity-wrappers -go-solidity-wrappers: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - go generate ./core/gethwrappers - -.PHONY: go-solidity-wrappers-transmission -go-solidity-wrappers-transmission: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - ./contracts/scripts/native_solc_compile_all_transmission - go generate ./core/gethwrappers/transmission - -.PHONY: go-solidity-wrappers-ocr2vrf -go-solidity-wrappers-ocr2vrf: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - ./contracts/scripts/native_solc_compile_all_ocr2vrf - # replace the go:generate_disabled directive with the regular go:generate directive - sed -i '' 's/go:generate_disabled/go:generate/g' core/gethwrappers/ocr2vrf/go_generate.go - go generate ./core/gethwrappers/ocr2vrf - go generate ./core/internal/mocks - # put the go:generate_disabled directive back - sed -i '' 's/go:generate/go:generate_disabled/g' core/gethwrappers/ocr2vrf/go_generate.go - - -.PHONY: go-solidity-wrappers-functions -go-solidity-wrappers-functions: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - ./contracts/scripts/native_solc_compile_all_functions - go generate ./core/gethwrappers/functions/go_generate.go - -.PHONY: go-solidity-wrappers-llo -go-solidity-wrappers-llo: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. - ./contracts/scripts/native_solc_compile_all_llo - go generate ./core/gethwrappers/llo-feeds/go_generate.go - .PHONY: generate generate: abigen codecgen mockery ## Execute all go:generate commands. go generate -x ./... @@ -177,9 +147,6 @@ config-docs: ## Generate core node configuration documentation golangci-lint: ## Run golangci-lint for all issues. docker run --rm -v $(shell pwd):/app -w /app golangci/golangci-lint:v1.53.2 golangci-lint run --max-issues-per-linter 0 --max-same-issues 0 > golangci-lint-output.txt -.PHONY: snapshot -snapshot: - cd ./contracts && forge snapshot --match-test _gas GORELEASER_CONFIG ?= .goreleaser.yaml diff --git a/contracts/.gas-snapshot b/contracts/.gas-snapshot deleted file mode 100644 index 34c7e6a348a..00000000000 --- a/contracts/.gas-snapshot +++ /dev/null @@ -1,8 +0,0 @@ -FunctionsOracle_setDONPublicKey:testSetDONPublicKey_gas() (gas: 97558) -FunctionsOracle_setRegistry:testSetRegistry_gas() (gas: 31987) -Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 207063) -Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922517) -Verifier_verify:testVerifyProxySuccess_gas() (gas: 197508) -Verifier_verify:testVerifySuccess_gas() (gas: 182991) -Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245475) -Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 262092) \ No newline at end of file diff --git a/contracts/GNUmakefile b/contracts/GNUmakefile new file mode 100644 index 00000000000..ea70ae43f93 --- /dev/null +++ b/contracts/GNUmakefile @@ -0,0 +1,80 @@ +# ALL_FOUNDRY_PRODUCTS contains a list of all products that have a foundry +# profile defined. Adding a product to this list will make it available for +# snapshotting. +ALL_FOUNDRY_PRODUCTS = vrf automation llo-feeds functions automation-dev shared + +# To make a snapshot for a specific product, either set the `FOUNDRY_PROFILE` env var +# or call the target with `FOUNDRY_PROFILE=product` +# When developing with Foundry, you'll most likely already have the env var set +# to run the tests for the product you're working on. In that case, you can just +# call `make snapshot` and it will use the env var. +# env var example +# export FOUNDRY_PROFILE=llo-feeds +# make snapshot +# make call example +# make FOUNDRY_PROFILE=llo-feeds snapshot +.PHONY: snapshot +snapshot: ## Make a snapshot for a specific product. + export FOUNDRY_PROFILE=$(FOUNDRY_PROFILE) && forge snapshot --snap gas-snapshots/$(FOUNDRY_PROFILE).gas-snapshot + +.PHONY: snapshot-all +snapshot-all: ## Make a snapshot for all products. + for foundry_profile in $(ALL_FOUNDRY_PRODUCTS) ; do \ + make snapshot FOUNDRY_PROFILE=$$foundry_profile ; \ + done + +.PHONY: pnpmdep +pnpmdep: ## Install solidity contract dependencies through pnpm + pnpm i + +.PHONY: abigen +abigen: ## Build & install abigen. + ../tools/bin/build_abigen + + +# To generate gethwrappers for a specific product, either set the `FOUNDRY_PROFILE` +# env var or call the target with `FOUNDRY_PROFILE=product` +# This uses FOUNDRY_PROFILE, even though it does support non-foundry products. This +# is to improve the workflow for developers working with Foundry, which is the +# recommended way to develop Solidity for CL products. +# env var example +# export FOUNDRY_PROFILE=llo-feeds +# make wrappers +# make call example +# make FOUNDRY_PROFILE=llo-feeds wrappers +.PHONY: wrappers +wrappers: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. + ./scripts/native_solc_compile_all_$(FOUNDRY_PROFILE) + go generate ../core/gethwrappers/$(FOUNDRY_PROFILE) + +# This call generates all gethwrappers for all products. It does so based on the +# assumption that native_solc_compile_all contains sub-calls to each product, and +# go_generate does the same. +.PHONY: wrappers-all +wrappers-all: pnpmdep abigen ## Recompiles solidity contracts and their go wrappers. + # go_generate contains a call to compile all contracts before generating wrappers + go generate ../core/gethwrappers/go_generate.go + +# Custom wrapper generation for OCR2VRF as their contracts do not exist in this repo +.PHONY: go-solidity-wrappers-ocr2vrf +go-solidity-wrappers-ocr2vrf: pnpmdep abigen ## Recompiles OCR2VRF solidity contracts and their go wrappers. + ./scripts/native_solc_compile_all_ocr2vrf + # replace the go:generate_disabled directive with the regular go:generate directive + sed -i '' 's/go:generate_disabled/go:generate/g' ../core/gethwrappers/ocr2vrf/go_generate.go + go generate ../core/gethwrappers/ocr2vrf + go generate ../core/internal/mocks + # put the go:generate_disabled directive back + sed -i '' 's/go:generate/go:generate_disabled/g' ../core/gethwrappers/ocr2vrf/go_generate.go + + +help: + @echo "" + @echo " .__ .__ .__ .__ __" + @echo " ____ | |__ _____ |__| ____ | | |__| ____ | | __" + @echo " _/ ___\| | \\\\\\__ \ | |/ \| | | |/ \| |/ /" + @echo " \ \___| Y \/ __ \| | | \ |_| | | \ <" + @echo " \___ >___| (____ /__|___| /____/__|___| /__|_ \\" + @echo " \/ \/ \/ \/ \/ \/" + @echo "" + @grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | \ + awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}' diff --git a/contracts/foundry.toml b/contracts/foundry.toml index f7b3f8b39ad..c1da24ad814 100644 --- a/contracts/foundry.toml +++ b/contracts/foundry.toml @@ -33,4 +33,23 @@ src = 'src/v0.8/automation' test = 'src/v0.8/automation/test' solc_version = '0.8.6' +[profile.automation-dev] +optimizer_runs = 10000 +src = 'src/v0.8/dev/automation' +test = 'src/v0.8/dev/automation/test' + +[profile.llo-feeds] +optimizer_runs = 1000000 +src = 'src/v0.8/llo-feeds' +test = 'src/v0.8/llo-feeds/test' +solc_version = '0.8.16' + +[profile.shared] +optimizer_runs = 1000000 +src = 'src/v0.8/shared' +test = 'src/v0.8/shared/test' +solc_version = '0.8.19' +deny_warnings = true + + # See more config options https://github.com/foundry-rs/foundry/tree/master/config diff --git a/contracts/gas-snapshots/automation-dev.gas-snapshot b/contracts/gas-snapshots/automation-dev.gas-snapshot new file mode 100644 index 00000000000..1a939d69e19 --- /dev/null +++ b/contracts/gas-snapshots/automation-dev.gas-snapshot @@ -0,0 +1,5 @@ +AutomationForwarder_forward:testBasicSuccess() (gas: 87630) +AutomationForwarder_forward:testNotAuthorizedReverts() (gas: 21681) +AutomationForwarder_forward:testWrongFunctionSelectorSuccess() (gas: 17958) +AutomationForwarder_updateRegistry:testBasicSuccess() (gas: 14577) +AutomationForwarder_updateRegistry:testNotFromRegistryNotAuthorizedReverts() (gas: 13893) \ No newline at end of file diff --git a/contracts/gas-snapshots/automation.gas-snapshot b/contracts/gas-snapshots/automation.gas-snapshot new file mode 100644 index 00000000000..934aebf982d --- /dev/null +++ b/contracts/gas-snapshots/automation.gas-snapshot @@ -0,0 +1,8 @@ +HeartbeatRequester_getAggregatorRequestHeartbeat:testBasicSuccess() (gas: 75412) +HeartbeatRequester_getAggregatorRequestHeartbeat:testHeartbeatNotPermittedReverts() (gas: 21730) +HeartbeatRequester_permitHeartbeat:testBasicDeployerSuccess() (gas: 48280) +HeartbeatRequester_permitHeartbeat:testBasicSuccess() (gas: 45856) +HeartbeatRequester_permitHeartbeat:testOnlyCallableByOwnerReverts() (gas: 13796) +HeartbeatRequester_removeHeartbeat:testBasicSuccess() (gas: 30192) +HeartbeatRequester_removeHeartbeat:testOnlyCallableByOwnerReverts() (gas: 11629) +HeartbeatRequester_removeHeartbeat:testRemoveNoPermitsSuccess() (gas: 15660) \ No newline at end of file diff --git a/contracts/gas-snapshots/functions.gas-snapshot b/contracts/gas-snapshots/functions.gas-snapshot new file mode 100644 index 00000000000..bda023cf117 --- /dev/null +++ b/contracts/gas-snapshots/functions.gas-snapshot @@ -0,0 +1,11 @@ +FunctionsOracle_sendRequest:testEmptyRequestDataReverts() (gas: 13430) +FunctionsOracle_setDONPublicKey:testEmptyPublicKeyReverts() (gas: 10974) +FunctionsOracle_setDONPublicKey:testOnlyOwnerReverts() (gas: 11255) +FunctionsOracle_setDONPublicKey:testSetDONPublicKeySuccess() (gas: 126453) +FunctionsOracle_setDONPublicKey:testSetDONPublicKey_gas() (gas: 97558) +FunctionsOracle_setRegistry:testEmptyPublicKeyReverts() (gas: 10635) +FunctionsOracle_setRegistry:testOnlyOwnerReverts() (gas: 10927) +FunctionsOracle_setRegistry:testSetRegistrySuccess() (gas: 35791) +FunctionsOracle_setRegistry:testSetRegistry_gas() (gas: 31987) +FunctionsOracle_typeAndVersion:testTypeAndVersionSuccess() (gas: 6905) +FunctionsRouter_createSubscription:testCreateSubscriptionSuccess() (gas: 111376) \ No newline at end of file diff --git a/contracts/gas-snapshots/llo-feeds.gas-snapshot b/contracts/gas-snapshots/llo-feeds.gas-snapshot new file mode 100644 index 00000000000..b643c6f8cd8 --- /dev/null +++ b/contracts/gas-snapshots/llo-feeds.gas-snapshot @@ -0,0 +1,219 @@ +FeeManagerProcessFeeTest:test_DiscountIsAppliedForNative() (gas: 47654) +FeeManagerProcessFeeTest:test_V1PayloadVerifies() (gas: 17377) +FeeManagerProcessFeeTest:test_V2PayloadVerifies() (gas: 104591) +FeeManagerProcessFeeTest:test_V2PayloadWithoutQuoteFails() (gas: 19950) +FeeManagerProcessFeeTest:test_V2PayloadWithoutZeroFee() (gas: 62375) +FeeManagerProcessFeeTest:test_WithdrawERC20() (gas: 62862) +FeeManagerProcessFeeTest:test_WithdrawNonAdminAddr() (gas: 48655) +FeeManagerProcessFeeTest:test_WithdrawUnwrappedNative() (gas: 20266) +FeeManagerProcessFeeTest:test_baseFeeIsAppliedForLink() (gas: 15021) +FeeManagerProcessFeeTest:test_baseFeeIsAppliedForNative() (gas: 17517) +FeeManagerProcessFeeTest:test_correctDiscountIsAppliedWhenBothTokensAreDiscounted() (gas: 83916) +FeeManagerProcessFeeTest:test_discountAIsNotAppliedWhenSetForOtherUsers() (gas: 51279) +FeeManagerProcessFeeTest:test_discountFeeRoundsDownWhenUneven() (gas: 47800) +FeeManagerProcessFeeTest:test_discountIsAppliedForLink() (gas: 45109) +FeeManagerProcessFeeTest:test_discountIsAppliedWith100PercentSurcharge() (gas: 71303) +FeeManagerProcessFeeTest:test_discountIsNoLongerAppliedAfterRemoving() (gas: 41064) +FeeManagerProcessFeeTest:test_discountIsNotAppliedForInvalidTokenAddress() (gas: 12439) +FeeManagerProcessFeeTest:test_discountIsNotAppliedToOtherFeeds() (gas: 49326) +FeeManagerProcessFeeTest:test_emptyQuoteRevertsWithError() (gas: 12305) +FeeManagerProcessFeeTest:test_eventIsEmittedAfterSurchargeIsSet() (gas: 36250) +FeeManagerProcessFeeTest:test_eventIsEmittedUponWithdraw() (gas: 59974) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterDiscountIsRemoved() (gas: 43550) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewDiscountIsApplied() (gas: 60124) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewSurchargeIsApplied() (gas: 56407) +FeeManagerProcessFeeTest:test_feeIsZeroWith100PercentDiscount() (gas: 47510) +FeeManagerProcessFeeTest:test_getBaseRewardWithLinkQuote() (gas: 15064) +FeeManagerProcessFeeTest:test_getLinkFeeIsRoundedUp() (gas: 45278) +FeeManagerProcessFeeTest:test_getLinkRewardIsRoundedDown() (gas: 45180) +FeeManagerProcessFeeTest:test_getLinkRewardWithNativeQuoteAndSurchargeWithLinkDiscount() (gas: 74934) +FeeManagerProcessFeeTest:test_getRewardWithLinkDiscount() (gas: 45087) +FeeManagerProcessFeeTest:test_getRewardWithLinkQuoteAndLinkDiscount() (gas: 45110) +FeeManagerProcessFeeTest:test_getRewardWithNativeQuote() (gas: 17540) +FeeManagerProcessFeeTest:test_getRewardWithNativeQuoteAndSurcharge() (gas: 45608) +FeeManagerProcessFeeTest:test_linkAvailableForPaymentReturnsLinkBalance() (gas: 47416) +FeeManagerProcessFeeTest:test_nativeSurcharge0Percent() (gas: 25630) +FeeManagerProcessFeeTest:test_nativeSurcharge100Percent() (gas: 45644) +FeeManagerProcessFeeTest:test_nativeSurchargeCannotExceed100Percent() (gas: 12085) +FeeManagerProcessFeeTest:test_nativeSurchargeEventIsEmittedOnUpdate() (gas: 36252) +FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFee() (gas: 47172) +FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFeeAndDiscountAndSurchargeIsSet() (gas: 70762) +FeeManagerProcessFeeTest:test_nonAdminProxyUserCannotProcessFee() (gas: 19062) +FeeManagerProcessFeeTest:test_nonAdminUserCanNotSetDiscount() (gas: 14751) +FeeManagerProcessFeeTest:test_processFeeAsProxy() (gas: 105088) +FeeManagerProcessFeeTest:test_processFeeDefaultReportsStillVerifiesWithEmptyQuote() (gas: 18170) +FeeManagerProcessFeeTest:test_processFeeEmitsEventIfNotEnoughLink() (gas: 121568) +FeeManagerProcessFeeTest:test_processFeeIfSubscriberIsSelf() (gas: 19197) +FeeManagerProcessFeeTest:test_processFeeNative() (gas: 154869) +FeeManagerProcessFeeTest:test_processFeeUsesCorrectDigest() (gas: 106112) +FeeManagerProcessFeeTest:test_processFeeWithDefaultReportPayloadAndQuoteStillVerifies() (gas: 20509) +FeeManagerProcessFeeTest:test_processFeeWithInvalidReportVersion() (gas: 21997) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNative() (gas: 159309) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeLinkAddress() (gas: 68253) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeShortFunds() (gas: 72784) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeWithExcessiveFee() (gas: 166315) +FeeManagerProcessFeeTest:test_processFeeWithWithCorruptQuotePayload() (gas: 19786) +FeeManagerProcessFeeTest:test_processFeeWithWithEmptyQuotePayload() (gas: 20264) +FeeManagerProcessFeeTest:test_processFeeWithWithZeroQuotePayload() (gas: 21226) +FeeManagerProcessFeeTest:test_reportWithNoExpiryOrFeeReturnsZero() (gas: 10966) +FeeManagerProcessFeeTest:test_setDiscountOver100Percent() (gas: 14453) +FeeManagerProcessFeeTest:test_subscriberDiscountEventIsEmittedOnUpdate() (gas: 41119) +FeeManagerProcessFeeTest:test_surchargeFeeRoundsUpWhenUneven() (gas: 45937) +FeeManagerProcessFeeTest:test_surchargeIsApplied() (gas: 45905) +FeeManagerProcessFeeTest:test_surchargeIsAppliedForNativeFeeWithDiscount() (gas: 71618) +FeeManagerProcessFeeTest:test_surchargeIsNoLongerAppliedAfterRemoving() (gas: 40744) +FeeManagerProcessFeeTest:test_surchargeIsNotAppliedForLinkFee() (gas: 45125) +FeeManagerProcessFeeTest:test_surchargeIsNotAppliedWith100PercentDiscount() (gas: 71116) +FeeManagerProcessFeeTest:test_testRevertIfReportHasExpired() (gas: 15561) +RewardManagerClaimTest:test_claimAllRecipients() (gas: 257750) +RewardManagerClaimTest:test_claimMultipleRecipients() (gas: 143154) +RewardManagerClaimTest:test_claimRewardsWithDuplicatPoolIdsDoesNotPayoutTwice() (gas: 306046) +RewardManagerClaimTest:test_claimSingleRecipient() (gas: 82153) +RewardManagerClaimTest:test_claimUnevenAmountRoundsDown() (gas: 291448) +RewardManagerClaimTest:test_claimUnregisteredPoolId() (gas: 33836) +RewardManagerClaimTest:test_claimUnregisteredRecipient() (gas: 35153) +RewardManagerClaimTest:test_eventIsEmittedUponClaim() (gas: 79828) +RewardManagerClaimTest:test_eventIsNotEmittedUponUnsuccessfulClaim() (gas: 24119) +RewardManagerClaimTest:test_recipientsClaimMultipleDeposits() (gas: 345435) +RewardManagerClaimTest:test_singleRecipientClaimMultipleDeposits() (gas: 122526) +RewardManagerNoRecipientSet:test_claimAllRecipientsAfterRecipientsSet() (gas: 456069) +RewardManagerPayRecipientsTest:test_addFundsToPoolAsNonOwnerOrFeeManager() (gas: 12746) +RewardManagerPayRecipientsTest:test_addFundsToPoolAsOwner() (gas: 48620) +RewardManagerPayRecipientsTest:test_payAllRecipients() (gas: 239952) +RewardManagerPayRecipientsTest:test_payAllRecipientsFromNonAdminUser() (gas: 15490) +RewardManagerPayRecipientsTest:test_payAllRecipientsFromRecipientInPool() (gas: 240242) +RewardManagerPayRecipientsTest:test_payAllRecipientsWithAdditionalInvalidRecipient() (gas: 251334) +RewardManagerPayRecipientsTest:test_payAllRecipientsWithAdditionalUnregisteredRecipient() (gas: 254496) +RewardManagerPayRecipientsTest:test_payRecipientWithInvalidPool() (gas: 28014) +RewardManagerPayRecipientsTest:test_payRecipientsEmptyRecipientList() (gas: 19996) +RewardManagerPayRecipientsTest:test_payRecipientsWithInvalidPoolId() (gas: 43841) +RewardManagerPayRecipientsTest:test_paySingleRecipient() (gas: 78279) +RewardManagerPayRecipientsTest:test_paySubsetOfRecipientsInPool() (gas: 189107) +RewardManagerRecipientClaimDifferentWeightsTest:test_allRecipientsClaimingReceiveExpectedAmount() (gas: 260811) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimAllRecipientsMultiplePools() (gas: 476699) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimAllRecipientsSinglePool() (gas: 263819) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimEmptyPoolWhenSecondPoolContainsFunds() (gas: 270760) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimMultipleRecipientsMultiplePools() (gas: 243846) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimMultipleRecipientsSinglePool() (gas: 143216) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimSingleRecipientMultiplePools() (gas: 122217) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimSingleUniqueRecipient() (gas: 96657) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimUnevenAmountRoundsDown() (gas: 532419) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimUnregisteredRecipient() (gas: 55393) +RewardManagerRecipientClaimMultiplePoolsTest:test_getRewardsAvailableToRecipientInBothPools() (gas: 24031) +RewardManagerRecipientClaimMultiplePoolsTest:test_getRewardsAvailableToRecipientInNoPools() (gas: 18192) +RewardManagerRecipientClaimMultiplePoolsTest:test_getRewardsAvailableToRecipientInSinglePool() (gas: 21793) +RewardManagerRecipientClaimMultiplePoolsTest:test_recipientsClaimMultipleDeposits() (gas: 349885) +RewardManagerRecipientClaimMultiplePoolsTest:test_singleRecipientClaimMultipleDeposits() (gas: 122542) +RewardManagerRecipientClaimUnevenWeightTest:test_allRecipientsClaimingReceiveExpectedAmount() (gas: 184329) +RewardManagerRecipientClaimUnevenWeightTest:test_allRecipientsClaimingReceiveExpectedAmountWithSmallDeposit() (gas: 204221) +RewardManagerSetRecipientsTest:test_eventIsEmittedUponSetRecipients() (gas: 185494) +RewardManagerSetRecipientsTest:test_setRecipientContainsDuplicateRecipients() (gas: 117290) +RewardManagerSetRecipientsTest:test_setRewardRecipientFromManagerAddress() (gas: 185271) +RewardManagerSetRecipientsTest:test_setRewardRecipientFromNonOwnerOrFeeManagerAddress() (gas: 16348) +RewardManagerSetRecipientsTest:test_setRewardRecipientTwice() (gas: 184667) +RewardManagerSetRecipientsTest:test_setRewardRecipientWeights() (gas: 174935) +RewardManagerSetRecipientsTest:test_setRewardRecipientWithZeroAddress() (gas: 84821) +RewardManagerSetRecipientsTest:test_setRewardRecipientWithZeroWeight() (gas: 177469) +RewardManagerSetRecipientsTest:test_setRewardRecipients() (gas: 179469) +RewardManagerSetRecipientsTest:test_setRewardRecipientsIsEmpty() (gas: 82005) +RewardManagerSetRecipientsTest:test_setSingleRewardRecipient() (gas: 105112) +RewardManagerSetupTest:test_eventEmittedUponFeeManagerUpdate() (gas: 16365) +RewardManagerSetupTest:test_eventEmittedUponFeePaid() (gas: 250264) +RewardManagerSetupTest:test_rejectsZeroLinkAddressOnConstruction() (gas: 59044) +RewardManagerSetupTest:test_setFeeManagerZeroAddress() (gas: 12015) +RewardManagerUpdateRewardRecipientsMultiplePoolsTest:test_updatePrimaryRecipientWeights() (gas: 342516) +RewardManagerUpdateRewardRecipientsTest:test_eventIsEmittedUponUpdateRecipients() (gas: 267066) +RewardManagerUpdateRewardRecipientsTest:test_onlyAdminCanUpdateRecipients() (gas: 14622) +RewardManagerUpdateRewardRecipientsTest:test_partialUpdateRecipientWeights() (gas: 197909) +RewardManagerUpdateRewardRecipientsTest:test_updateAllRecipientsWithSameAddressAndWeight() (gas: 261004) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsToSubset() (gas: 235391) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithExcessiveWeight() (gas: 248952) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithSameAddressAndWeight() (gas: 141088) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithUnderWeightSet() (gas: 249017) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientWeights() (gas: 337998) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientWithNewZeroAddress() (gas: 247682) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsContainsDuplicateRecipients() (gas: 274972) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentLargerSet() (gas: 250186) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentPartialSet() (gas: 248406) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSet() (gas: 249627) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSetWithInvalidWeights() (gas: 248516) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForLargerSet() (gas: 241638) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForSmallerSet() (gas: 239964) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesAMiddleDigest() (gas: 24243) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesTheFirstDigest() (gas: 24210) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyUnsetsDigestsInSequence() (gas: 44316) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfCalledByNonOwner() (gas: 11322) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnEmptyDigest() (gas: 10951) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnNonExistentDigest() (gas: 13425) +VerifierActivateConfigTest:test_revertsIfDigestIsEmpty() (gas: 10939) +VerifierActivateConfigTest:test_revertsIfDigestNotSet() (gas: 13371) +VerifierActivateConfigTest:test_revertsIfNotOwner() (gas: 13410) +VerifierActivateConfigWithDeactivatedConfigTest:test_allowsVerification() (gas: 93459) +VerifierActivateFeedTest:test_revertsIfNoFeedExistsActivate() (gas: 13179) +VerifierActivateFeedTest:test_revertsIfNoFeedExistsDeactivate() (gas: 13179) +VerifierActivateFeedTest:test_revertsIfNotOwnerActivateFeed() (gas: 13360) +VerifierActivateFeedTest:test_revertsIfNotOwnerDeactivateFeed() (gas: 13437) +VerifierConstructorTest:test_revertsIfInitializedWithEmptyVerifierProxy() (gas: 59818) +VerifierConstructorTest:test_setsTheCorrectProperties() (gas: 1678828) +VerifierDeactivateFeedWithVerifyTest:test_currentReportAllowsVerification() (gas: 188309) +VerifierDeactivateFeedWithVerifyTest:test_currentReportFailsVerification() (gas: 109640) +VerifierDeactivateFeedWithVerifyTest:test_previousReportAllowsVerification() (gas: 95886) +VerifierDeactivateFeedWithVerifyTest:test_previousReportFailsVerification() (gas: 66198) +VerifierProxyAccessControlledVerificationTest:test_proxiesToTheVerifierIfHasAccess() (gas: 203049) +VerifierProxyAccessControlledVerificationTest:test_revertsIfNoAccess() (gas: 105809) +VerifierProxyConstructorTest:test_correctlySetsTheCorrectAccessControllerInterface() (gas: 1073832) +VerifierProxyConstructorTest:test_correctlySetsTheOwner() (gas: 1053935) +VerifierProxyConstructorTest:test_correctlySetsVersion() (gas: 6939) +VerifierProxyInitializeVerifierTest:test_revertsIfDigestAlreadySet() (gas: 50301) +VerifierProxyInitializeVerifierTest:test_revertsIfNotCorrectVerifier() (gas: 13573) +VerifierProxyInitializeVerifierTest:test_revertsIfNotOwner() (gas: 13375) +VerifierProxyInitializeVerifierTest:test_revertsIfVerifierAlreadyInitialized() (gas: 41915) +VerifierProxyInitializeVerifierTest:test_revertsIfZeroAddress() (gas: 10904) +VerifierProxyInitializeVerifierTest:test_setFeeManagerZeroAddress() (gas: 10913) +VerifierProxyInitializeVerifierTest:test_updatesVerifierIfVerifier() (gas: 49628) +VerifierProxySetAccessControllerTest:test_emitsTheCorrectEvent() (gas: 35384) +VerifierProxySetAccessControllerTest:test_revertsIfCalledByNonOwner() (gas: 11367) +VerifierProxySetAccessControllerTest:test_successfullySetsNewAccessController() (gas: 32075) +VerifierProxySetAccessControllerTest:test_successfullySetsNewAccessControllerIsEmpty() (gas: 12174) +VerifierProxyUnsetVerifierTest:test_revertsIfDigestDoesNotExist() (gas: 13174) +VerifierProxyUnsetVerifierTest:test_revertsIfNotAdmin() (gas: 11249) +VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest:test_correctlyUnsetsVerifier() (gas: 12719) +VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest:test_emitsAnEventAfterUnsettingVerifier() (gas: 17965) +VerifierProxyVerifyTest:test_proxiesToTheCorrectVerifier() (gas: 200395) +VerifierProxyVerifyTest:test_revertsIfNoVerifierConfigured() (gas: 108443) +VerifierSetConfigTest:test_correctlyUpdatesTheConfig() (gas: 1057727) +VerifierSetConfigTest:test_revertsIfCalledByNonOwner() (gas: 179223) +VerifierSetConfigTest:test_revertsIfDuplicateSigners() (gas: 251512) +VerifierSetConfigTest:test_revertsIfFaultToleranceIsZero() (gas: 176522) +VerifierSetConfigTest:test_revertsIfNotEnoughSigners() (gas: 15814) +VerifierSetConfigTest:test_revertsIfSetWithTooManySigners() (gas: 22170) +VerifierSetConfigTest:test_revertsIfSignerContainsZeroAddress() (gas: 227942) +VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlySetsConfigWhenDigestsAreRemoved() (gas: 538532) +VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesDigestsOnMultipleVerifiersInTheProxy() (gas: 963972) +VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 520054) +VerifierSupportsInterfaceTest:test_falseIfIsNotCorrectInterface() (gas: 5590) +VerifierSupportsInterfaceTest:test_trueIfIsCorrectInterface() (gas: 5611) +VerifierTestBillingReport:test_verifyWithLink() (gas: 274052) +VerifierTestBillingReport:test_verifyWithNative() (gas: 252372) +VerifierTestBillingReport:test_verifyWithNativeUnwrapped() (gas: 263437) +VerifierTestBillingReport:test_verifyWithNativeUnwrappedReturnsChange() (gas: 270504) +VerifierVerifyMultipleConfigDigestTest:test_canVerifyNewerReportsWithNewerConfigs() (gas: 127500) +VerifierVerifyMultipleConfigDigestTest:test_canVerifyOlderReportsWithOlderConfigs() (gas: 183379) +VerifierVerifyMultipleConfigDigestTest:test_revertsIfAReportIsVerifiedWithAnExistingButIncorrectDigest() (gas: 84470) +VerifierVerifyMultipleConfigDigestTest:test_revertsIfVerifyingWithAnUnsetDigest() (gas: 124369) +VerifierVerifySingleConfigDigestTest:test_emitsAnEventIfReportVerified() (gas: 183237) +VerifierVerifySingleConfigDigestTest:test_returnsThePriceAndBlockNumIfReportVerified() (gas: 183406) +VerifierVerifySingleConfigDigestTest:test_revertsIfConfigDigestNotSet() (gas: 112459) +VerifierVerifySingleConfigDigestTest:test_revertsIfDuplicateSignersHaveSigned() (gas: 178601) +VerifierVerifySingleConfigDigestTest:test_revertsIfMismatchedSignatureLength() (gas: 49278) +VerifierVerifySingleConfigDigestTest:test_revertsIfReportHasUnconfiguredFeedID() (gas: 100262) +VerifierVerifySingleConfigDigestTest:test_revertsIfVerifiedByNonProxy() (gas: 101024) +VerifierVerifySingleConfigDigestTest:test_revertsIfVerifiedWithIncorrectAddresses() (gas: 180352) +VerifierVerifySingleConfigDigestTest:test_revertsIfWrongNumberOfSigners() (gas: 106317) +VerifierVerifySingleConfigDigestTest:test_setsTheCorrectEpoch() (gas: 190539) +Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 207063) +Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922517) +Verifier_verify:testVerifyProxySuccess_gas() (gas: 197508) +Verifier_verify:testVerifySuccess_gas() (gas: 182991) +Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245475) +Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 262092) \ No newline at end of file diff --git a/contracts/gas-snapshots/shared.gas-snapshot b/contracts/gas-snapshots/shared.gas-snapshot new file mode 100644 index 00000000000..e69de29bb2d diff --git a/contracts/gas-snapshots/vrf.gas-snapshot b/contracts/gas-snapshots/vrf.gas-snapshot new file mode 100644 index 00000000000..a6232a44400 --- /dev/null +++ b/contracts/gas-snapshots/vrf.gas-snapshot @@ -0,0 +1,14 @@ +TrustedBlockhashStoreTest:testGenericBHSFunctions() (gas: 53507) +TrustedBlockhashStoreTest:testTrustedBHSFunctions() (gas: 49536) +VRFCoordinatorV2Plus_Migration:testDeregister() (gas: 99350) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCaller() (gas: 27277) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCoordinator() (gas: 17777) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenPendingFulfillment() (gas: 237557) +VRFCoordinatorV2Plus_Migration:testMigration() (gas: 451067) +VRFV2Plus:testCreateSubscription() (gas: 92494) +VRFV2Plus:testRegisterProvingKey() (gas: 100951) +VRFV2Plus:testRequestAndFulfillRandomWordsLINK() (gas: 667896) +VRFV2Plus:testRequestAndFulfillRandomWordsNative() (gas: 618375) +VRFV2Plus:testSetConfig() (gas: 72991) +VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsLINKWrapper() (gas: 373063) +VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsNativeWrapper() (gas: 273557) \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index 1612bc29976..b90405e7de9 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -12,7 +12,7 @@ python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt # 6 and 7 are legacy contracts, for each other 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 6 7 feeds functions llo transmission vrf automation logpoller events_mock +for product in 6 7 feeds functions llo-feeds transmission vrf automation logpoller events_mock do $SCRIPTPATH/native_solc_compile_all_$product done diff --git a/contracts/scripts/native_solc_compile_all_llo b/contracts/scripts/native_solc_compile_all_llo-feeds similarity index 100% rename from contracts/scripts/native_solc_compile_all_llo rename to contracts/scripts/native_solc_compile_all_llo-feeds diff --git a/core/gethwrappers/go_generate_test.go b/core/gethwrappers/go_generate_test.go index fa19bc437be..9ded44c0785 100644 --- a/core/gethwrappers/go_generate_test.go +++ b/core/gethwrappers/go_generate_test.go @@ -94,7 +94,7 @@ func compareCurrentCompilerArtifactAgainstRecordsAndSoliditySources( t *testing.T, versionInfo ContractVersion, ) { hash := VersionHash(versionInfo.AbiPath, versionInfo.BinaryPath) - recompileCommand := fmt.Sprintf("(cd %s; make go-solidity-wrappers)", rootDir) + recompileCommand := fmt.Sprintf("(cd %s/contracts; make wrappers-all)", rootDir) assert.Equal(t, versionInfo.Hash, hash, utils.BoxOutput(`compiled %s and/or %s has changed; please rerun %s, @@ -122,7 +122,7 @@ func init() { } fmt.Printf("some solidity artifacts missing (%s); rebuilding...", solidityArtifactsMissing) - // Don't want to run "make go-solidity-wrappers" here, because that would + // Don't want to run "make wrappers-all" here, because that would // result in an infinite loop cmd := exec.Command("bash", "-c", compileCommand) cmd.Stdout = os.Stdout From af5e478198f9203b014ae5a71649eab318b86a23 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Mon, 14 Aug 2023 22:53:03 -0700 Subject: [PATCH 169/270] [Gateway] Use personal_sign signatures everywhere (EIP-191) (#10201) Co-authored-by: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> --- core/services/gateway/common/utils.go | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/core/services/gateway/common/utils.go b/core/services/gateway/common/utils.go index 5c5ab037a7d..7501504f87b 100644 --- a/core/services/gateway/common/utils.go +++ b/core/services/gateway/common/utils.go @@ -4,8 +4,9 @@ import ( "crypto/ecdsa" "encoding/binary" - "github.com/ethereum/go-ethereum/crypto" "golang.org/x/exp/slices" + + "github.com/smartcontractkit/chainlink/v2/core/utils" ) func Uint32ToBytes(val uint32) []byte { @@ -30,16 +31,22 @@ func AlignedBytesToString(data []byte) string { return string(data[:idx]) } +func flatten(data ...[]byte) []byte { + var result []byte + for _, d := range data { + result = append(result, d...) + } + return result +} + func SignData(privateKey *ecdsa.PrivateKey, data ...[]byte) ([]byte, error) { - hash := crypto.Keccak256Hash(data...) - return crypto.Sign(hash.Bytes(), privateKey) + return utils.GenerateEthSignature(privateKey, flatten(data...)) } func ExtractSigner(signature []byte, data ...[]byte) (signerAddress []byte, err error) { - hash := crypto.Keccak256Hash(data...) - ecdsaPubKey, err := crypto.SigToPub(hash.Bytes(), signature) + addr, err := utils.GetSignersEthAddress(flatten(data...), signature) if err != nil { return nil, err } - return crypto.PubkeyToAddress(*ecdsaPubKey).Bytes(), nil + return addr.Bytes(), nil } From 7d79d178e10b7d3b7f1a7297f7ee94c6a7a6482c Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Tue, 15 Aug 2023 09:08:49 -0400 Subject: [PATCH 170/270] simplify block subscriber and add check/log block checks (#10079) * simplify block subscriber to only use broadcaster * add automation custom telem to job * not expose constants * addressed comments * update channel size * address comments * verify check block and log block (#10154) * verify check block and log block * fix lint issue * add some tests * add more tests * update comments * refactor * fix lint issue * more refactoring * fix lint issues * fix tests * use select * log subscriber comments * comment --------- Co-authored-by: amirylm --- .../ocr2/plugins/ocr2keeper/evm21/abi.go | 46 ++- .../ocr2/plugins/ocr2keeper/evm21/abi_test.go | 8 +- .../ocr2keeper/evm21/block_subscriber.go | 338 +++++++++--------- .../ocr2keeper/evm21/block_subscriber_test.go | 275 +++++++++----- .../plugins/ocr2keeper/evm21/feed_lookup.go | 12 +- .../ocr2keeper/evm21/feed_lookup_test.go | 14 +- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 178 ++++++--- .../plugins/ocr2keeper/evm21/registry_test.go | 229 +++++++++++- core/services/ocr2/plugins/ocr2keeper/util.go | 8 +- 9 files changed, 757 insertions(+), 351 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go index eca011a1ff3..00468dafb57 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go @@ -13,23 +13,35 @@ import ( iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" ) -// enum UpkeepFailureReason is defined by https://github.com/smartcontractkit/chainlink/blob/develop/contracts/src/v0.8/dev/automation/2_1/interfaces/AutomationRegistryInterface2_1.sol#L97 -// make sure failure reasons are in sync between contract and offchain enum +type UpkeepFailureReason uint8 +type PipelineExecutionState uint8 + const ( - UPKEEP_FAILURE_REASON_NONE = iota - UPKEEP_FAILURE_REASON_UPKEEP_CANCELLED - UPKEEP_FAILURE_REASON_UPKEEP_PAUSED - UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED - UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED - UPKEEP_FAILURE_REASON_PERFORM_DATA_EXCEEDS_LIMIT - UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE - UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED - UPKEEP_FAILURE_REASON_REVERT_DATA_EXCEEDS_LIMIT - UPKEEP_FAILURE_REASON_REGISTRY_PAUSED - - // Start of offchain failure types. All onchain failure reasons from - // contract should be put above - UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED + // upkeep failure onchain reasons + UpkeepFailureReasonNone UpkeepFailureReason = 0 + UpkeepFailureReasonUpkeepCancelled UpkeepFailureReason = 1 + UpkeepFailureReasonUpkeepPaused UpkeepFailureReason = 2 + UpkeepFailureReasonTargetCheckReverted UpkeepFailureReason = 3 + UpkeepFailureReasonUpkeepNotNeeded UpkeepFailureReason = 4 + UpkeepFailureReasonPerformDataExceedsLimit UpkeepFailureReason = 5 + UpkeepFailureReasonInsufficientBalance UpkeepFailureReason = 6 + UpkeepFailureReasonMercuryCallbackReverted UpkeepFailureReason = 7 + UpkeepFailureReasonRevertDataExceedsLimit UpkeepFailureReason = 8 + UpkeepFailureReasonRegistryPaused UpkeepFailureReason = 9 + // leaving a gap here for more onchain failure reasons in the future + // upkeep failure offchain reasons + UpkeepFailureReasonMercuryAccessNotAllowed UpkeepFailureReason = 32 + UpkeepFailureReasonLogBlockNoLongerExists UpkeepFailureReason = 31 + UpkeepFailureReasonLogBlockInvalid UpkeepFailureReason = 32 + UpkeepFailureReasonTxHashNoLongerExists UpkeepFailureReason = 33 + + // pipeline execution error + NoPipelineError PipelineExecutionState = 0 + CheckBlockTooOld PipelineExecutionState = 1 + CheckBlockInvalid PipelineExecutionState = 2 + RpcFlakyFailure PipelineExecutionState = 3 + MercuryFlakyFailure PipelineExecutionState = 4 + PackUnpackFailed PipelineExecutionState = 5 ) var utilsABI = types.MustGetABI(automation_utils_2_1.AutomationUtilsABI) @@ -77,7 +89,7 @@ func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, rawPerformData := *abi.ConvertType(out[1], new([]byte)).(*[]byte) // if NONE we expect the perform data. if TARGET_CHECK_REVERTED we will have the error data in the perform data used for off chain lookup - if result.IneligibilityReason == UPKEEP_FAILURE_REASON_NONE || (result.IneligibilityReason == UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED && len(rawPerformData) > 0) { + if result.IneligibilityReason == uint8(UpkeepFailureReasonNone) || (result.IneligibilityReason == uint8(UpkeepFailureReasonTargetCheckReverted) && len(rawPerformData) > 0) { result.PerformData = rawPerformData } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go index b42a40b2f05..942f104c95f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go @@ -37,7 +37,7 @@ func TestUnpackCheckResults(t *testing.T) { ExpectedResult: ocr2keepers.CheckResult{ UpkeepID: upkeepId, Eligible: false, - IneligibilityReason: UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED, + IneligibilityReason: uint8(UpkeepFailureReasonUpkeepNotNeeded), PerformData: nil, FastGasWei: big.NewInt(1000000000), LinkNative: big.NewInt(3532383906411401), @@ -50,7 +50,7 @@ func TestUnpackCheckResults(t *testing.T) { ExpectedResult: ocr2keepers.CheckResult{ UpkeepID: upkeepId, Eligible: false, - IneligibilityReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + IneligibilityReason: uint8(UpkeepFailureReasonTargetCheckReverted), PerformData: []byte{98, 232, 165, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 193, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 68, 83, 116, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 66, 84, 67, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, FastGasWei: big.NewInt(1000000000), LinkNative: big.NewInt(3532383906411401), @@ -106,7 +106,7 @@ func TestPacker_UnpackCheckCallbackResult(t *testing.T) { CallbackResp: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 46, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 96, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 10, 11, 21, 31, 41, 15, 16, 17, 18, 19, 13, 14, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 120, 111, 101, 122, 90, 54, 44, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, UpkeepNeeded: true, PerformData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 10, 11, 21, 31, 41, 15, 16, 17, 18, 19, 13, 14, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 120, 111, 101, 122, 90, 54, 44, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - FailureReason: UPKEEP_FAILURE_REASON_NONE, + FailureReason: uint8(UpkeepFailureReasonNone), GasUsed: big.NewInt(11796), }, { @@ -114,7 +114,7 @@ func TestPacker_UnpackCheckCallbackResult(t *testing.T) { CallbackResp: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 50, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 96, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 10, 11, 21, 31, 41, 15, 16, 17, 18, 19, 13, 14, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 120, 111, 101, 122, 90, 54, 44, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, UpkeepNeeded: false, PerformData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 16, 10, 11, 21, 31, 41, 15, 16, 17, 18, 19, 13, 14, 12, 13, 14, 15, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 8, 120, 111, 101, 122, 90, 54, 44, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - FailureReason: UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED, + FailureReason: uint8(UpkeepFailureReasonUpkeepNotNeeded), GasUsed: big.NewInt(13008), }, { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go index 0d0e381d0a6..04bc77b2580 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go @@ -4,6 +4,7 @@ import ( "context" "fmt" "sync" + "sync/atomic" "time" "github.com/ethereum/go-ethereum/common" @@ -18,266 +19,257 @@ import ( ) const ( - // PollLogInterval is the interval to query log poller - PollLogInterval = time.Second - // CleanUpInterval is the interval for cleaning up block maps - CleanUpInterval = 15 * time.Minute - // ChannelSize represents the channel size for head broadcaster - ChannelSize = 20 + // cleanUpInterval is the interval for cleaning up block maps + cleanUpInterval = 15 * time.Minute + // channelSize represents the channel size for head broadcaster + channelSize = 100 + // lookbackDepth decides valid trigger block lookback range + lookbackDepth = 1024 + // blockHistorySize decides the block history size + blockHistorySize = int64(128) ) -type BlockKey struct { - block int64 - hash common.Hash -} - -func (bk *BlockKey) getBlockKey() ocr2keepers.BlockKey { - return ocr2keepers.BlockKey{ - Number: ocr2keepers.BlockNumber(bk.block), - Hash: bk.hash, - } -} - type BlockSubscriber struct { - sync utils.StartStopOnce - mu sync.RWMutex - ctx context.Context - cancel context.CancelFunc - hb httypes.HeadBroadcaster - lp logpoller.LogPoller - headC chan BlockKey - unsubscribe func() - subscribers map[int]chan ocr2keepers.BlockHistory - blocksFromPoller map[int64]common.Hash - blocksFromBroadcaster map[int64]common.Hash - maxSubId int - lastClearedBlock int64 - lastSentBlock int64 - blockHistorySize int64 - lggr logger.Logger + sync utils.StartStopOnce + mu sync.RWMutex + ctx context.Context + cancel context.CancelFunc + hb httypes.HeadBroadcaster + lp logpoller.LogPoller + headC chan *evmtypes.Head + unsubscribe func() + subscribers map[int]chan ocr2keepers.BlockHistory + blocks map[int64]string + maxSubId int + lastClearedBlock int64 + lastSentBlock int64 + latestBlock atomic.Int64 + blockHistorySize int64 + blockSize int64 + lggr logger.Logger } -func NewBlockSubscriber(hb httypes.HeadBroadcaster, lp logpoller.LogPoller, blockHistorySize int64, lggr logger.Logger) *BlockSubscriber { +func NewBlockSubscriber(hb httypes.HeadBroadcaster, lp logpoller.LogPoller, lggr logger.Logger) *BlockSubscriber { return &BlockSubscriber{ - hb: hb, - lp: lp, - headC: make(chan BlockKey, ChannelSize), - subscribers: map[int]chan ocr2keepers.BlockHistory{}, - blocksFromPoller: map[int64]common.Hash{}, - blocksFromBroadcaster: map[int64]common.Hash{}, - blockHistorySize: blockHistorySize, - lggr: lggr.Named("BlockSubscriber"), + hb: hb, + lp: lp, + headC: make(chan *evmtypes.Head, channelSize), + subscribers: map[int]chan ocr2keepers.BlockHistory{}, + blocks: map[int64]string{}, + blockHistorySize: blockHistorySize, + blockSize: lookbackDepth, + latestBlock: atomic.Int64{}, + lggr: lggr.Named("BlockSubscriber"), } } -func (hw *BlockSubscriber) getBlockRange(ctx context.Context) ([]uint64, error) { - h, err := hw.lp.LatestBlock(pg.WithParentCtx(ctx)) +func (bs *BlockSubscriber) getBlockRange(ctx context.Context) ([]uint64, error) { + h, err := bs.lp.LatestBlock(pg.WithParentCtx(ctx)) if err != nil { return nil, err } - hw.lggr.Infof("latest block from log poller is %d", h) + bs.lggr.Infof("latest block from log poller is %d", h) var blocks []uint64 - for i := int64(0); i < hw.blockHistorySize; i++ { - blocks = append(blocks, uint64(h-i)) + for i := bs.blockSize - 1; i >= 0; i-- { + if h-i > 0 { + blocks = append(blocks, uint64(h-i)) + } } return blocks, nil } -func (hw *BlockSubscriber) getLogPollerBlocks(ctx context.Context, blocks []uint64) error { - // request the past LOOK_BACK blocksFromPoller from log poller - // returned blocksFromPoller are in ASC order - logpollerBlocks, err := hw.lp.GetBlocksRange(ctx, blocks, pg.WithParentCtx(ctx)) +func (bs *BlockSubscriber) initializeBlocks(blocks []uint64) error { + logpollerBlocks, err := bs.lp.GetBlocksRange(bs.ctx, blocks, pg.WithParentCtx(bs.ctx)) if err != nil { return err } - hw.mu.Lock() - for _, b := range logpollerBlocks { - hw.blocksFromPoller[b.BlockNumber] = b.BlockHash + for i, b := range logpollerBlocks { + if i == 0 { + bs.lastClearedBlock = b.BlockNumber - 1 + bs.lggr.Infof("lastClearedBlock is %d", bs.lastClearedBlock) + } + bs.blocks[b.BlockNumber] = b.BlockHash.Hex() } - hw.mu.Unlock() + bs.lggr.Infof("initialize with %d blocks", len(logpollerBlocks)) return nil } -func (hw *BlockSubscriber) buildHistory(block int64) ocr2keepers.BlockHistory { - var keys []BlockKey +func (bs *BlockSubscriber) buildHistory(block int64) ocr2keepers.BlockHistory { + var keys []ocr2keepers.BlockKey // populate keys slice in block DES order - for i := int64(0); i < hw.blockHistorySize; i++ { - if h1, ok1 := hw.blocksFromPoller[block-i]; ok1 { - // if a block exists in log poller, use block data from log poller - keys = append(keys, BlockKey{ - block: block - i, - hash: h1, - }) - } else if h2, ok2 := hw.blocksFromBroadcaster[block-i]; ok2 { - // if a block only exists in broadcaster, use data from broadcaster - keys = append(keys, BlockKey{ - block: block - i, - hash: h2, - }) - } else { - hw.lggr.Infof("block %d is missing", block-i) + for i := int64(0); i < bs.blockHistorySize; i++ { + if block-i > 0 { + if h, ok := bs.blocks[block-i]; ok { + keys = append(keys, ocr2keepers.BlockKey{ + Number: ocr2keepers.BlockNumber(block - i), + Hash: common.HexToHash(h), + }) + } else { + bs.lggr.Infof("block %d is missing", block-i) + } } - // if a block does not exist in both log poller and broadcaster, skip } - return getBlockHistory(keys) + return keys } -func (hw *BlockSubscriber) cleanup() { - hw.mu.Lock() - defer hw.mu.Unlock() +func (bs *BlockSubscriber) cleanup() { + bs.mu.Lock() + defer bs.mu.Unlock() - hw.lggr.Infof("start clearing blocks from %d to %d", hw.lastClearedBlock+1, hw.lastSentBlock-hw.blockHistorySize) - for i := hw.lastClearedBlock + 1; i <= hw.lastSentBlock-hw.blockHistorySize; i++ { - delete(hw.blocksFromPoller, i) - delete(hw.blocksFromBroadcaster, i) + bs.lggr.Infof("start clearing blocks from %d to %d", bs.lastClearedBlock+1, bs.lastSentBlock-bs.blockSize) + for i := bs.lastClearedBlock + 1; i <= bs.lastSentBlock-bs.blockSize; i++ { + delete(bs.blocks, i) } - hw.lastClearedBlock = hw.lastSentBlock - hw.blockHistorySize - hw.lggr.Infof("lastClearedBlock is set to %d", hw.lastClearedBlock) + bs.lastClearedBlock = bs.lastSentBlock - bs.blockSize + bs.lggr.Infof("lastClearedBlock is set to %d", bs.lastClearedBlock) } -func (hw *BlockSubscriber) Start(_ context.Context) error { - hw.lggr.Info("block subscriber started.") - return hw.sync.StartOnce("BlockSubscriber", func() error { - hw.mu.Lock() - defer hw.mu.Unlock() - _, hw.unsubscribe = hw.hb.Subscribe(&headWrapper{headC: hw.headC}) - hw.ctx, hw.cancel = context.WithCancel(context.Background()) - - // poll from head broadcaster channel and push to subscribers - { - go func(ctx context.Context) { - for { - select { - case bk := <-hw.headC: - hw.mu.Lock() - if hw.lastClearedBlock == 0 { - hw.lastClearedBlock = bk.block - 1 - hw.lggr.Infof("lastClearedBlock is %d", hw.lastClearedBlock) - } - hw.blocksFromBroadcaster[bk.block] = bk.hash - hw.lggr.Infof("blocksFromBroadcaster block %d hash is %s", bk.block, bk.hash.String()) - - history := hw.buildHistory(bk.block) - - hw.lastSentBlock = bk.block - hw.lggr.Infof("lastSentBlock is %d", hw.lastSentBlock) - // send history to all subscribers - for _, subC := range hw.subscribers { - subC <- history - } - hw.lggr.Infof("published block history with length %d to %d subscriber(s)", len(history), len(hw.subscribers)) - - hw.mu.Unlock() - case <-ctx.Done(): - return - } - } - }(hw.ctx) +func (bs *BlockSubscriber) Start(ctx context.Context) error { + bs.lggr.Info("block subscriber started.") + return bs.sync.StartOnce("BlockSubscriber", func() error { + bs.mu.Lock() + defer bs.mu.Unlock() + // TODO: we should use ctx instead of context.Background()) + bs.ctx, bs.cancel = context.WithCancel(context.Background()) + // initialize the blocks map with the recent blockSize blocks + blocks, err := bs.getBlockRange(bs.ctx) + if err != nil { + bs.lggr.Errorf("failed to get block range", err) + } + err = bs.initializeBlocks(blocks) + if err != nil { + bs.lggr.Errorf("failed to get log poller blocks", err) } - // poll logs from log poller at an interval and update block map + _, bs.unsubscribe = bs.hb.Subscribe(&headWrapper{headC: bs.headC}) + + // poll from head broadcaster channel and push to subscribers { go func(ctx context.Context) { - ticker := time.NewTicker(PollLogInterval) for { select { - case <-ticker.C: - blocks, err := hw.getBlockRange(ctx) - if err != nil { - hw.lggr.Infof("failed to get block range", err) - return - } - err = hw.getLogPollerBlocks(ctx, blocks) - if err != nil { - hw.lggr.Infof("failed to get log poller blocks", err) - } + case h := <-bs.headC: + bs.processHead(h) case <-ctx.Done(): - ticker.Stop() return } } - }(hw.ctx) + }(bs.ctx) } // clean up block maps { go func(ctx context.Context) { - ticker := time.NewTicker(CleanUpInterval) + ticker := time.NewTicker(cleanUpInterval) for { select { case <-ticker.C: - hw.cleanup() + bs.cleanup() case <-ctx.Done(): ticker.Stop() return } } - }(hw.ctx) + }(bs.ctx) } return nil }) } -func (hw *BlockSubscriber) Close() error { - hw.lggr.Info("stop block subscriber") - return hw.sync.StopOnce("BlockSubscriber", func() error { - hw.mu.Lock() - defer hw.mu.Unlock() +func (bs *BlockSubscriber) Close() error { + bs.lggr.Info("stop block subscriber") + return bs.sync.StopOnce("BlockSubscriber", func() error { + bs.mu.Lock() + defer bs.mu.Unlock() - close(hw.headC) - hw.cancel() - hw.unsubscribe() + close(bs.headC) + bs.cancel() + bs.unsubscribe() return nil }) } -func (hw *BlockSubscriber) Subscribe() (int, chan ocr2keepers.BlockHistory, error) { - hw.mu.Lock() - defer hw.mu.Unlock() +func (bs *BlockSubscriber) Subscribe() (int, chan ocr2keepers.BlockHistory, error) { + bs.mu.Lock() + defer bs.mu.Unlock() - hw.maxSubId++ - subId := hw.maxSubId - newC := make(chan ocr2keepers.BlockHistory, ChannelSize) - hw.subscribers[subId] = newC - hw.lggr.Infof("new subscriber %d", subId) + bs.maxSubId++ + subId := bs.maxSubId + newC := make(chan ocr2keepers.BlockHistory, channelSize) + bs.subscribers[subId] = newC + bs.lggr.Infof("new subscriber %d", subId) return subId, newC, nil } -func (hw *BlockSubscriber) Unsubscribe(subId int) error { - hw.mu.Lock() - defer hw.mu.Unlock() +func (bs *BlockSubscriber) Unsubscribe(subId int) error { + bs.mu.Lock() + defer bs.mu.Unlock() - c, ok := hw.subscribers[subId] + c, ok := bs.subscribers[subId] if !ok { return fmt.Errorf("subscriber %d does not exist", subId) } close(c) - delete(hw.subscribers, subId) - hw.lggr.Infof("subscriber %d unsubscribed", subId) + delete(bs.subscribers, subId) + bs.lggr.Infof("subscriber %d unsubscribed", subId) return nil } +func (bs *BlockSubscriber) processHead(h *evmtypes.Head) { + bs.mu.Lock() + defer bs.mu.Unlock() + // head parent is a linked list with EVM finality depth + // when re-org happens, new heads will have pointers to the new blocks + i := int64(0) + for cp := h; cp != nil; cp = cp.Parent { + if cp != h && bs.blocks[cp.Number] != cp.Hash.Hex() { + bs.lggr.Warnf("overriding block %d old hash %s with new hash %s due to re-org", cp.Number, bs.blocks[cp.Number], cp.Hash.Hex()) + } + bs.blocks[cp.Number] = cp.Hash.Hex() + i++ + if i > bs.blockSize { + break + } + } + bs.lggr.Debugf("blocks block %d hash is %s", h.Number, h.Hash.Hex()) + + history := bs.buildHistory(h.Number) + + bs.latestBlock.Store(h.Number) + bs.lastSentBlock = h.Number + // send history to all subscribers + for _, subC := range bs.subscribers { + // wrapped in a select to not get blocked by certain subscribers + select { + case subC <- history: + default: + bs.lggr.Warnf("subscriber channel is full, dropping block history with length %d", len(history)) + } + } + + bs.lggr.Debugf("published block history with length %d and latestBlock %d to %d subscriber(s)", len(history), bs.latestBlock.Load(), len(bs.subscribers)) +} + +func (bs *BlockSubscriber) queryBlocksMap(bn int64) (string, bool) { + bs.mu.RLock() + defer bs.mu.RUnlock() + v, ok := bs.blocks[bn] + return v, ok +} + type headWrapper struct { - headC chan BlockKey + headC chan *evmtypes.Head } func (w *headWrapper) OnNewLongestChain(_ context.Context, head *evmtypes.Head) { if head != nil { - w.headC <- BlockKey{ - block: head.Number, - hash: head.BlockHash(), + select { + case w.headC <- head: + default: } } } - -func getBlockHistory(keys []BlockKey) ocr2keepers.BlockHistory { - var blockKeys []ocr2keepers.BlockKey - for _, k := range keys { - blockKeys = append(blockKeys, k.getBlockKey()) - } - return blockKeys -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go index 358bfeffa3c..19dfa7d9281 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber_test.go @@ -16,17 +16,21 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/logger" ) -const blockHistorySize = int64(4) +const historySize = 4 +const blockSize = int64(4) func TestBlockSubscriber_Subscribe(t *testing.T) { lggr := logger.TestLogger(t) var hb types.HeadBroadcaster var lp logpoller.LogPoller - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize subId, _, err := bs.Subscribe() assert.Nil(t, err) assert.Equal(t, subId, 1) @@ -43,7 +47,9 @@ func TestBlockSubscriber_Unsubscribe(t *testing.T) { var hb types.HeadBroadcaster var lp logpoller.LogPoller - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize subId, _, err := bs.Subscribe() assert.Nil(t, err) assert.Equal(t, subId, 1) @@ -59,7 +65,9 @@ func TestBlockSubscriber_Unsubscribe_Failure(t *testing.T) { var hb types.HeadBroadcaster var lp logpoller.LogPoller - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize err := bs.Unsubscribe(2) assert.Equal(t, err.Error(), "subscriber 2 does not exist") } @@ -81,7 +89,7 @@ func TestBlockSubscriber_GetBlockRange(t *testing.T) { { Name: "get block range", LatestBlock: 100, - ExpectedBlocks: []uint64{100, 99, 98, 97}, + ExpectedBlocks: []uint64{97, 98, 99, 100}, }, } @@ -89,8 +97,10 @@ func TestBlockSubscriber_GetBlockRange(t *testing.T) { t.Run(tc.Name, func(t *testing.T) { lp := new(mocks.LogPoller) lp.On("LatestBlock", mock.Anything).Return(tc.LatestBlock, tc.LatestBlockErr) - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) - blocks, err := bs.getBlockRange(context.Background()) + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize + blocks, err := bs.getBlockRange(testutils.Context(t)) if tc.LatestBlockErr != nil { assert.Equal(t, tc.LatestBlockErr.Error(), err.Error()) @@ -101,15 +111,16 @@ func TestBlockSubscriber_GetBlockRange(t *testing.T) { } } -func TestBlockSubscriber_GetLogPollerBlocks(t *testing.T) { +func TestBlockSubscriber_InitializeBlocks(t *testing.T) { lggr := logger.TestLogger(t) var hb types.HeadBroadcaster tests := []struct { - Name string - Blocks []uint64 - PollerBlocks []logpoller.LogPollerBlock - Error error + Name string + Blocks []uint64 + PollerBlocks []logpoller.LogPollerBlock + LastClearedBlock int64 + Error error }{ { Name: "failed to get latest block", @@ -117,25 +128,26 @@ func TestBlockSubscriber_GetLogPollerBlocks(t *testing.T) { }, { Name: "get block range", - Blocks: []uint64{100, 99, 98, 97}, + Blocks: []uint64{97, 98, 99, 100}, PollerBlocks: []logpoller.LogPollerBlock{ { - BlockNumber: 100, + BlockNumber: 97, BlockHash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), }, { - BlockNumber: 99, + BlockNumber: 98, BlockHash: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), }, { - BlockNumber: 98, + BlockNumber: 99, BlockHash: common.HexToHash("0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe"), }, { - BlockNumber: 97, + BlockNumber: 100, BlockHash: common.HexToHash("0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe"), }, }, + LastClearedBlock: 96, }, } @@ -143,17 +155,20 @@ func TestBlockSubscriber_GetLogPollerBlocks(t *testing.T) { t.Run(tc.Name, func(t *testing.T) { lp := new(mocks.LogPoller) lp.On("GetBlocksRange", mock.Anything, tc.Blocks, mock.Anything).Return(tc.PollerBlocks, tc.Error) - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) - err := bs.getLogPollerBlocks(context.Background(), tc.Blocks) + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize + err := bs.initializeBlocks(tc.Blocks) if tc.Error != nil { assert.Equal(t, tc.Error.Error(), err.Error()) } else { for _, b := range tc.PollerBlocks { - h, ok := bs.blocksFromPoller[b.BlockNumber] + h, ok := bs.blocks[b.BlockNumber] assert.True(t, ok) - assert.Equal(t, b.BlockHash, h) + assert.Equal(t, b.BlockHash.Hex(), h) } + assert.Equal(t, tc.LastClearedBlock, bs.lastClearedBlock) } }) } @@ -165,28 +180,24 @@ func TestBlockSubscriber_BuildHistory(t *testing.T) { lp := new(mocks.LogPoller) tests := []struct { - Name string - BlocksFromLogPoller map[int64]common.Hash - BlocksFromBroadcaster map[int64]common.Hash - Block int64 - ExpectedHistory ocr2keepers.BlockHistory + Name string + Blocks map[int64]string + Block int64 + ExpectedHistory ocr2keepers.BlockHistory }{ { Name: "build history", - BlocksFromLogPoller: map[int64]common.Hash{ - 100: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), - 97: common.HexToHash("0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe"), - 96: common.HexToHash("0x44f23c588193695abd92697ddc1ba032376d0a784818eddd2d159eee4c41f03f"), - }, - BlocksFromBroadcaster: map[int64]common.Hash{ - 100: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), - 98: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Blocks: map[int64]string{ + 100: "0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba", + 98: "0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", + 97: "0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe", + 95: "0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", }, Block: 100, ExpectedHistory: ocr2keepers.BlockHistory{ ocr2keepers.BlockKey{ Number: 100, - Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + Hash: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), }, ocr2keepers.BlockKey{ Number: 98, @@ -202,9 +213,10 @@ func TestBlockSubscriber_BuildHistory(t *testing.T) { for _, tc := range tests { t.Run(tc.Name, func(t *testing.T) { - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) - bs.blocksFromPoller = tc.BlocksFromLogPoller - bs.blocksFromBroadcaster = tc.BlocksFromBroadcaster + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize + bs.blocks = tc.Blocks history := bs.buildHistory(tc.Block) assert.Equal(t, history, tc.ExpectedHistory) @@ -218,57 +230,44 @@ func TestBlockSubscriber_Cleanup(t *testing.T) { lp := new(mocks.LogPoller) tests := []struct { - Name string - BlocksFromLogPoller map[int64]common.Hash - BlocksFromBroadcaster map[int64]common.Hash - LastClearedBlock int64 - LastSentBlock int64 - ExpectedLastClearedBlock int64 - ExpectedLogPollerBlocks map[int64]common.Hash - ExpectedBroadcasterBlocks map[int64]common.Hash + Name string + Blocks map[int64]string + LastClearedBlock int64 + LastSentBlock int64 + ExpectedLastClearedBlock int64 + ExpectedBlocks map[int64]string }{ { Name: "build history", - BlocksFromLogPoller: map[int64]common.Hash{ - 101: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), - 100: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), - 97: common.HexToHash("0xa7ac5bbc905b81f3a2ad9fb8ef1fe45f4a95768df456736952e4ec6c21296abe"), - 96: common.HexToHash("0x44f23c588193695abd92697ddc1ba032376d0a784818eddd2d159eee4c41f03f"), - 95: common.HexToHash("0x44f23c588193695abd92697ddc1ba032376d0a784818eddd2d159eee4c41f03f"), - }, - BlocksFromBroadcaster: map[int64]common.Hash{ - 102: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), - 100: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), - 98: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), - 95: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Blocks: map[int64]string{ + 102: "0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba", + 100: "0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba", + 98: "0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", + 95: "0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", }, LastClearedBlock: 94, LastSentBlock: 101, ExpectedLastClearedBlock: 97, - ExpectedLogPollerBlocks: map[int64]common.Hash{ - 101: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), - 100: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), - }, - ExpectedBroadcasterBlocks: map[int64]common.Hash{ - 102: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), - 100: common.HexToHash("0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba"), - 98: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + ExpectedBlocks: map[int64]string{ + 102: "0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba", + 100: "0xaf3f8b36a27837e9f1ea3b4da7cdbf2ce0bdf7ef4e87d23add83b19438a2fcba", + 98: "0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", }, }, } for _, tc := range tests { t.Run(tc.Name, func(t *testing.T) { - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) - bs.blocksFromPoller = tc.BlocksFromLogPoller - bs.blocksFromBroadcaster = tc.BlocksFromBroadcaster + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize + bs.blocks = tc.Blocks bs.lastClearedBlock = tc.LastClearedBlock bs.lastSentBlock = tc.LastSentBlock bs.cleanup() assert.Equal(t, tc.ExpectedLastClearedBlock, bs.lastClearedBlock) - assert.Equal(t, tc.ExpectedBroadcasterBlocks, bs.blocksFromBroadcaster) - assert.Equal(t, tc.ExpectedLogPollerBlocks, bs.blocksFromPoller) + assert.Equal(t, tc.ExpectedBlocks, bs.blocks) }) } } @@ -278,33 +277,84 @@ func TestBlockSubscriber_Start(t *testing.T) { hb := commonmocks.NewHeadBroadcaster[*evmtypes.Head, common.Hash](t) hb.On("Subscribe", mock.Anything).Return(&evmtypes.Head{Number: 42}, func() {}) lp := new(mocks.LogPoller) - lp.On("LatestBlock", mock.Anything).Maybe().Return(int64(0), fmt.Errorf("error")) + lp.On("LatestBlock", mock.Anything).Return(int64(100), nil) + blocks := []uint64{97, 98, 99, 100} + pollerBlocks := []logpoller.LogPollerBlock{ + { + BlockNumber: 97, + BlockHash: common.HexToHash("0xda2f9d1359eadd7b93338703adc07d942021a78195564038321ef53f23f87333"), + }, + { + BlockNumber: 98, + BlockHash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, + { + BlockNumber: 99, + BlockHash: common.HexToHash("0x9bc2b51e147f9cad05f1614b7f1d8181cb24c544cbcf841f3155e54e752a3b44"), + }, + { + BlockNumber: 100, + BlockHash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + }, + } + + lp.On("GetBlocksRange", mock.Anything, blocks, mock.Anything).Return(pollerBlocks, nil) - bs := NewBlockSubscriber(hb, lp, blockHistorySize, lggr) + bs := NewBlockSubscriber(hb, lp, lggr) + bs.blockHistorySize = historySize + bs.blockSize = blockSize err := bs.Start(context.Background()) assert.Nil(t, err) + h97 := evmtypes.Head{ + Number: 97, + Hash: common.HexToHash("0xda2f9d1359eadd7b93338703adc07d942021a78195564038321ef53f23f87333"), + Parent: nil, + } + h98 := evmtypes.Head{ + Number: 98, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Parent: &h97, + } + h99 := evmtypes.Head{ + Number: 99, + Hash: common.HexToHash("0x9bc2b51e147f9cad05f1614b7f1d8181cb24c544cbcf841f3155e54e752a3b44"), + Parent: &h98, + } + h100 := evmtypes.Head{ + Number: 100, + Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + Parent: &h99, + } + // no subscribers yet - bs.headC <- BlockKey{ - block: 100, - hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + bs.headC <- &h100 + + expectedBlocks := map[int64]string{ + 97: "0xda2f9d1359eadd7b93338703adc07d942021a78195564038321ef53f23f87333", + 98: "0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0", + 99: "0x9bc2b51e147f9cad05f1614b7f1d8181cb24c544cbcf841f3155e54e752a3b44", + 100: "0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b", } // sleep 100 milli to wait for the go routine to finish time.Sleep(100 * time.Millisecond) - assert.Equal(t, blockHistorySize, bs.blockHistorySize) - assert.Equal(t, int64(99), bs.lastClearedBlock) + assert.Equal(t, int64(historySize), bs.blockHistorySize) + assert.Equal(t, int64(96), bs.lastClearedBlock) assert.Equal(t, int64(100), bs.lastSentBlock) + assert.Equal(t, expectedBlocks, bs.blocks) // add 1 subscriber subId1, c1, err := bs.Subscribe() assert.Nil(t, err) assert.Equal(t, 1, subId1) - bs.headC <- BlockKey{ - block: 101, - hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + h101 := &evmtypes.Head{ + Number: 101, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Parent: &h100, } + bs.headC <- h101 time.Sleep(100 * time.Millisecond) bk1 := <-c1 @@ -317,6 +367,14 @@ func TestBlockSubscriber_Start(t *testing.T) { Number: 100, Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), }, + ocr2keepers.BlockKey{ + Number: 99, + Hash: common.HexToHash("0x9bc2b51e147f9cad05f1614b7f1d8181cb24c544cbcf841f3155e54e752a3b44"), + }, + ocr2keepers.BlockKey{ + Number: 98, + Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + }, }, bk1) // add 2nd subscriber @@ -324,49 +382,78 @@ func TestBlockSubscriber_Start(t *testing.T) { assert.Nil(t, err) assert.Equal(t, 2, subId2) - bs.headC <- BlockKey{ - block: 103, - hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + // re-org happens + new99 := &evmtypes.Head{ + Number: 99, + Hash: common.HexToHash("0x70c03acc4ddbfb253ba41a25dc13fb21b25da8b63bcd1aa7fb55713d33a36c71"), + Parent: &h98, } + new100 := &evmtypes.Head{ + Number: 100, + Hash: common.HexToHash("0x8a876b62d252e63e16cf3487db3486c0a7c0a8e06bc3792a3b116c5ca480503f"), + Parent: new99, + } + new101 := &evmtypes.Head{ + Number: 101, + Hash: common.HexToHash("0x41b5842b8847dcf834e39556d2ac51cc7d960a7de9471ec504673d0038fd6c8e"), + Parent: new100, + } + + new102 := &evmtypes.Head{ + Number: 102, + Hash: common.HexToHash("0x9ac1ebc307554cf1bcfcc2a49462278e89d6878d613a33df38a64d0aeac971b5"), + Parent: new101, + } + + bs.headC <- new102 time.Sleep(100 * time.Millisecond) bk1 = <-c1 assert.Equal(t, ocr2keepers.BlockHistory{ ocr2keepers.BlockKey{ - Number: 103, - Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Number: 102, + Hash: common.HexToHash("0x9ac1ebc307554cf1bcfcc2a49462278e89d6878d613a33df38a64d0aeac971b5"), }, ocr2keepers.BlockKey{ Number: 101, - Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Hash: common.HexToHash("0x41b5842b8847dcf834e39556d2ac51cc7d960a7de9471ec504673d0038fd6c8e"), }, ocr2keepers.BlockKey{ Number: 100, - Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + Hash: common.HexToHash("0x8a876b62d252e63e16cf3487db3486c0a7c0a8e06bc3792a3b116c5ca480503f"), + }, + ocr2keepers.BlockKey{ + Number: 99, + Hash: common.HexToHash("0x70c03acc4ddbfb253ba41a25dc13fb21b25da8b63bcd1aa7fb55713d33a36c71"), }, }, bk1, ) + bk2 := <-c2 assert.Equal(t, ocr2keepers.BlockHistory{ ocr2keepers.BlockKey{ - Number: 103, - Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Number: 102, + Hash: common.HexToHash("0x9ac1ebc307554cf1bcfcc2a49462278e89d6878d613a33df38a64d0aeac971b5"), }, ocr2keepers.BlockKey{ Number: 101, - Hash: common.HexToHash("0xc20c7b47466c081a44a3b168994e89affe85cb894547845d938f923b67c633c0"), + Hash: common.HexToHash("0x41b5842b8847dcf834e39556d2ac51cc7d960a7de9471ec504673d0038fd6c8e"), }, ocr2keepers.BlockKey{ Number: 100, - Hash: common.HexToHash("0x5e7fadfc14e1cfa9c05a91128c16a20c6cbc3be38b4723c3d482d44bf9c0e07b"), + Hash: common.HexToHash("0x8a876b62d252e63e16cf3487db3486c0a7c0a8e06bc3792a3b116c5ca480503f"), + }, + ocr2keepers.BlockKey{ + Number: 99, + Hash: common.HexToHash("0x70c03acc4ddbfb253ba41a25dc13fb21b25da8b63bcd1aa7fb55713d33a36c71"), }, }, bk2, ) - assert.Equal(t, int64(103), bs.lastSentBlock) - assert.Equal(t, int64(99), bs.lastClearedBlock) + assert.Equal(t, int64(102), bs.lastSentBlock) + assert.Equal(t, int64(96), bs.lastClearedBlock) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 2402c237eac..aedb3523edf 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -76,7 +76,7 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper lookups := map[int]*FeedLookup{} for i := range upkeepResults { res := &upkeepResults[i] - if res.IneligibilityReason != UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED { + if res.IneligibilityReason != uint8(UpkeepFailureReasonTargetCheckReverted) { continue } @@ -96,7 +96,7 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper } if !allowed { - res.IneligibilityReason = UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED + res.IneligibilityReason = uint8(UpkeepFailureReasonMercuryAccessNotAllowed) r.lggr.Errorf("[FeedLookup] upkeep %s block %d NOT allowed to time Mercury server", upkeepId, block) continue } @@ -152,19 +152,19 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * return } - if int(failureReason) == UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED { - upkeepResults[i].IneligibilityReason = UPKEEP_FAILURE_REASON_MERCURY_CALLBACK_REVERTED + if failureReason == uint8(UpkeepFailureReasonMercuryCallbackReverted) { + upkeepResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryCallbackReverted) r.lggr.Debugf("[FeedLookup] upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) return } if !needed { - upkeepResults[i].IneligibilityReason = UPKEEP_FAILURE_REASON_UPKEEP_NOT_NEEDED + upkeepResults[i].IneligibilityReason = uint8(UpkeepFailureReasonUpkeepNotNeeded) r.lggr.Debugf("[FeedLookup] upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) return } - upkeepResults[i].IneligibilityReason = UPKEEP_FAILURE_REASON_NONE + upkeepResults[i].IneligibilityReason = uint8(UpkeepFailureReasonNone) upkeepResults[i].Eligible = true upkeepResults[i].PerformData = performData r.lggr.Infof("[FeedLookup] upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index 3ea2bf9c936..f8cdc4dcd2f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -67,7 +67,7 @@ func setupEVMRegistry(t *testing.T) *EvmRegistry { Password: "FakeClientKey", }, abi: feedLookupCompatibleABI, - allowListCache: cache.New(DefaultAllowListExpiration, CleanupInterval), + allowListCache: cache.New(defaultAllowListExpiration, cleanupInterval), }, hc: mockHttpClient, } @@ -103,7 +103,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + IneligibilityReason: uint8(UpkeepFailureReasonTargetCheckReverted), }, }, blob: "0x00066dfcd1ed2d95b18c948dbc5bd64c687afe93e4ca7d663ddec14c20090ad80000000000000000000000000000000000000000000000000000000000159761000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000002200000000000000000000000000000000000000000000000000000000000000280000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001204554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000648a1fbb000000000000000000000000000000000000000000000000000000274421041500000000000000000000000000000000000000000000000000000027437c6ecd0000000000000000000000000000000000000000000000000000002744c5995d00000000000000000000000000000000000000000000000000000000018d6ec108936dfe39c48715572a51ac868129958f937fb95ef5abdf73a239cf86a4fee700000000000000000000000000000000000000000000000000000000018d6ec100000000000000000000000000000000000000000000000000000000648a1fbb00000000000000000000000000000000000000000000000000000000000000028a26e557ee2feb91ccb116f3ab4eb1469afe5c3b012538cb151dbe3fbceaf6f117b24ac2a82cff25b286ae0a9b903dc6badaa16f6e67bf0983461b008574e30a00000000000000000000000000000000000000000000000000000000000000020db5c5924481061b98df59caefd9c4c1e72657c4976bf7c7568730fbdaf828080bff6b1edea2c8fed5e8bbac5574aa94cf809d898f5055cb1db14a16f1493726", @@ -120,7 +120,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: UPKEEP_FAILURE_REASON_NONE, + IneligibilityReason: uint8(UpkeepFailureReasonNone), }, }, hasError: false, @@ -135,7 +135,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, + IneligibilityReason: uint8(UpkeepFailureReasonInsufficientBalance), }, }, expectedResults: []ocr2keepers.CheckResult{ @@ -146,7 +146,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: UPKEEP_FAILURE_REASON_INSUFFICIENT_BALANCE, + IneligibilityReason: uint8(UpkeepFailureReasonInsufficientBalance), }, }, hasError: true, @@ -160,7 +160,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: UPKEEP_FAILURE_REASON_TARGET_CHECK_REVERTED, + IneligibilityReason: uint8(UpkeepFailureReasonTargetCheckReverted), }, }, expectedResults: []ocr2keepers.CheckResult{ @@ -171,7 +171,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: UPKEEP_FAILURE_REASON_MERCURY_ACCESS_NOT_ALLOWED, + IneligibilityReason: uint8(UpkeepFailureReasonMercuryAccessNotAllowed), }, }, hasError: false, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index fedafe3c4e5..864db7e7c83 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -38,18 +38,17 @@ import ( ) const ( - // DefaultAllowListExpiration decides how long an upkeep's allow list info will be valid for. - DefaultAllowListExpiration = 20 * time.Minute - // CleanupInterval decides when the expired items in cache will be deleted. - CleanupInterval = 25 * time.Minute + // defaultAllowListExpiration decides how long an upkeep's allow list info will be valid for. + defaultAllowListExpiration = 20 * time.Minute + // cleanupInterval decides when the expired items in cache will be deleted. + cleanupInterval = 25 * time.Minute + // validCheckBlockRange decides the max distance between the check block and the current block + validCheckBlockRange = 128 ) var ( ErrLogReadFailure = fmt.Errorf("failure reading logs") ErrHeadNotAvailable = fmt.Errorf("head not available") - ErrRegistryCallFailure = fmt.Errorf("registry chain call failure") - ErrBlockKeyNotParsable = fmt.Errorf("block identifier not parsable") - ErrUpkeepKeyNotParsable = fmt.Errorf("upkeep key not parsable") ErrInitializationFailure = fmt.Errorf("failed to initialize registry") ErrContextCancelled = fmt.Errorf("context was cancelled") ErrABINotParsable = fmt.Errorf("error parsing abi") @@ -79,7 +78,7 @@ type LatestBlockGetter interface { LatestBlock() int64 } -func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.MercuryCredentials, lggr logger.Logger) (*EvmRegistry, *EVMAutomationEncoder21, error) { +func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.MercuryCredentials, bs *BlockSubscriber, lggr logger.Logger) (*EvmRegistry, *EVMAutomationEncoder21, error) { feedLookupCompatibleABI, err := abi.JSON(strings.NewReader(feed_lookup_compatible_interface.FeedLookupCompatibleInterfaceABI)) if err != nil { return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) @@ -119,11 +118,12 @@ func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.Mer mercury: &MercuryConfig{ cred: mc, abi: feedLookupCompatibleABI, - allowListCache: cache.New(DefaultAllowListExpiration, CleanupInterval), + allowListCache: cache.New(defaultAllowListExpiration, cleanupInterval), }, hc: http.DefaultClient, enc: EVMAutomationEncoder21{packer: packer}, logEventProvider: logEventProvider, + bs: bs, } if err := r.registerEvents(client.ID().Uint64(), addr); err != nil { @@ -169,30 +169,30 @@ type MercuryConfig struct { } type EvmRegistry struct { - ht types.HeadTracker - sync utils.StartStopOnce - lggr logger.Logger - poller logpoller.LogPoller - addr common.Address - client client.Client - registry Registry - abi abi.ABI - packer *evmRegistryPackerV2_1 - chLog chan logpoller.Log - reInit *time.Timer - mu sync.RWMutex - txHashes map[string]bool - lastPollBlock int64 - ctx context.Context - cancel context.CancelFunc - active map[string]activeUpkeep - headFunc func(ocr2keepers.BlockKey) - runState int - runError error - mercury *MercuryConfig - hc HttpClient - enc EVMAutomationEncoder21 - + ht types.HeadTracker + sync utils.StartStopOnce + lggr logger.Logger + poller logpoller.LogPoller + addr common.Address + client client.Client + registry Registry + abi abi.ABI + packer *evmRegistryPackerV2_1 + chLog chan logpoller.Log + reInit *time.Timer + mu sync.RWMutex + txHashes map[string]bool + lastPollBlock int64 + ctx context.Context + cancel context.CancelFunc + active map[string]activeUpkeep + headFunc func(ocr2keepers.BlockKey) + runState int + runError error + mercury *MercuryConfig + hc HttpClient + enc EVMAutomationEncoder21 + bs *BlockSubscriber logEventProvider logprovider.LogEventProvider } @@ -661,9 +661,10 @@ func (r *EvmRegistry) doCheck(ctx context.Context, keys []ocr2keepers.UpkeepPayl } } -func (r *EvmRegistry) getBlockAndUpkeepId(upkeepID ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) (*big.Int, *big.Int) { +// getBlockAndUpkeepId retrieves check block number, block hash from trigger and upkeep id +func (r *EvmRegistry) getBlockAndUpkeepId(upkeepID ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) (*big.Int, common.Hash, *big.Int) { block := new(big.Int).SetInt64(int64(trigger.BlockNumber)) - return block, upkeepID.BigInt() + return block, common.BytesToHash(trigger.BlockHash[:]), upkeepID.BigInt() } // TODO (AUTO-2013): Have better error handling to not return nil results in case of partial errors @@ -671,14 +672,16 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.U var ( checkReqs = make([]rpc.BatchElem, len(payloads)) checkResults = make([]*string, len(payloads)) - blocks = make([]*big.Int, len(payloads)) - upkeepIds = make([]*big.Int, len(payloads)) + results = make([]ocr2keepers.CheckResult, len(payloads)) ) for i, p := range payloads { - block, upkeepId := r.getBlockAndUpkeepId(p.UpkeepID, p.Trigger) - blocks[i] = block - upkeepIds[i] = upkeepId + block, checkHash, upkeepId := r.getBlockAndUpkeepId(p.UpkeepID, p.Trigger) + state, retryable := r.verifyCheckBlock(ctx, block, upkeepId, checkHash) + if state != NoPipelineError { + results[i] = r.getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, state, retryable) + continue + } opts, err := r.buildCallOpts(ctx, block) if err != nil { @@ -689,6 +692,12 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.U uid.FromBigInt(upkeepId) switch core.GetUpkeepType(*uid) { case ocr2keepers.LogTrigger: + reason, state, retryable := r.verifyLogExists(upkeepId, p) + if reason != UpkeepFailureReasonNone || state != NoPipelineError { + results[i] = r.getIneligibleCheckResultWithoutPerformData(p, reason, state, retryable) + continue + } + // check data will include the log trigger config payload, err = r.abi.Pack("checkUpkeep", upkeepId, p.CheckData) if err != nil { @@ -721,10 +730,7 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.U return nil, err } - var ( - multiErr error - results = make([]ocr2keepers.CheckResult, len(payloads)) - ) + var multiErr error for i, req := range checkReqs { if req.Error != nil { @@ -755,7 +761,7 @@ func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults [ continue } - block, upkeepId := r.getBlockAndUpkeepId(cr.UpkeepID, cr.Trigger) + block, _, upkeepId := r.getBlockAndUpkeepId(cr.UpkeepID, cr.Trigger) opts, err := r.buildCallOpts(ctx, block) if err != nil { @@ -926,3 +932,85 @@ func (r *EvmRegistry) getBlockHash(blockNumber *big.Int) (common.Hash, error) { return block.Hash(), nil } + +func (r *EvmRegistry) getTxBlock(txHash common.Hash) (*big.Int, common.Hash, error) { + // TODO: we need to differentiate here b/w flaky errors and tx not found errors + txr, err := r.client.TransactionReceipt(r.ctx, txHash) + if err != nil { + return nil, common.Hash{}, err + } + + return txr.BlockNumber, txr.BlockHash, nil +} + +// getIneligibleCheckResultWithoutPerformData returns an ineligible check result with ineligibility reason and pipeline execution state but without perform data +func (r *EvmRegistry) getIneligibleCheckResultWithoutPerformData(p ocr2keepers.UpkeepPayload, reason UpkeepFailureReason, state PipelineExecutionState, retryable bool) ocr2keepers.CheckResult { + return ocr2keepers.CheckResult{ + IneligibilityReason: uint8(reason), + PipelineExecutionState: uint8(state), + Retryable: retryable, + UpkeepID: p.UpkeepID, + Trigger: p.Trigger, + WorkID: p.WorkID, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + } +} + +// verifyCheckBlock checks that the check block and hash are valid, returns the pipeline execution state and retryable +func (r *EvmRegistry) verifyCheckBlock(ctx context.Context, checkBlock, upkeepId *big.Int, checkHash common.Hash) (state PipelineExecutionState, retryable bool) { + // verify check block number is not too old + if r.bs.latestBlock.Load()-checkBlock.Int64() > validCheckBlockRange { + r.lggr.Warnf("latest block is %d, check block number %s is too old for upkeepId %s", r.bs.latestBlock.Load(), checkBlock, upkeepId) + return CheckBlockTooOld, false + } + r.lggr.Warnf("latestBlock=%d checkBlock=%d", r.bs.latestBlock.Load(), checkBlock.Int64()) + + var h string + var ok bool + // verify check block number and hash are valid + h, ok = r.bs.queryBlocksMap(checkBlock.Int64()) + if !ok { + r.lggr.Warnf("check block %s does not exist in block subscriber for upkeepId %s, querying eth client", checkBlock, upkeepId) + b, err := r.client.BlockByNumber(ctx, checkBlock) + if err != nil { + r.lggr.Warnf("failed to query block %s: %s", checkBlock, err.Error()) + return RpcFlakyFailure, true + } + h = b.Hash().Hex() + } + if checkHash.Hex() != h { + r.lggr.Warnf("check block %s hash do not match. %s from block subscriber vs %s from trigger for upkeepId %s", checkBlock, h, checkHash.Hex(), upkeepId) + return CheckBlockInvalid, false + } + return NoPipelineError, false +} + +// verifyLogExists checks that the log still exists on chain, returns failure reason, pipeline error, and retryable +func (r *EvmRegistry) verifyLogExists(upkeepId *big.Int, p ocr2keepers.UpkeepPayload) (UpkeepFailureReason, PipelineExecutionState, bool) { + logBlockNumber := int64(p.Trigger.LogTriggerExtension.BlockNumber) + logBlockHash := common.BytesToHash(p.Trigger.LogTriggerExtension.BlockHash[:]) + // if log block number is populated, check log block number and block hash + if logBlockNumber != 0 { + h, ok := r.bs.queryBlocksMap(logBlockNumber) + if ok && h == logBlockHash.Hex() { + r.lggr.Debugf("tx hash %s exists on chain at block number %d for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), logBlockNumber, upkeepId) + return UpkeepFailureReasonNone, NoPipelineError, false + } + r.lggr.Debugf("log block %d does not exist in block subscriber for upkeepId %s, querying eth client", logBlockNumber, upkeepId) + } else { + r.lggr.Debugf("log block not provided, querying eth client for tx hash %s for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) + } + // query eth client as a fallback + bn, _, err := r.getTxBlock(p.Trigger.LogTriggerExtension.TxHash) + if err != nil { + r.lggr.Warnf("failed to query tx hash %s for upkeepId %s: %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId, err.Error()) + return UpkeepFailureReasonNone, RpcFlakyFailure, true + } + if bn == nil { + r.lggr.Warnf("tx hash %s does not exist on chain for upkeepId %s.", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) + return UpkeepFailureReasonLogBlockNoLongerExists, NoPipelineError, false + } + r.lggr.Debugf("tx hash %s exists on chain for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) + return UpkeepFailureReasonNone, NoPipelineError, false +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go index ac4668845d5..a8f24f9ee09 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go @@ -4,16 +4,20 @@ import ( "context" "fmt" "math/big" + "sync/atomic" "testing" "time" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" + evmClientMocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" + "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -344,9 +348,232 @@ func TestRegistry_GetBlockAndUpkeepId(t *testing.T) { for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { - block, upkeep := r.getBlockAndUpkeepId(tc.input.UpkeepID, tc.input.Trigger) + block, _, upkeep := r.getBlockAndUpkeepId(tc.input.UpkeepID, tc.input.Trigger) assert.Equal(t, tc.wantBlock, block) assert.Equal(t, tc.wantUpkeep.String(), upkeep.String()) }) } } + +func TestRegistry_VerifyCheckBlock(t *testing.T) { + lggr := logger.TestLogger(t) + upkeepId := ocr2keepers.UpkeepIdentifier{} + upkeepId.FromBigInt(big.NewInt(12345)) + tests := []struct { + name string + checkBlock *big.Int + latestBlock *big.Int + upkeepId *big.Int + checkHash common.Hash + payload ocr2keepers.UpkeepPayload + blocks map[int64]string + state PipelineExecutionState + retryable bool + makeEthCall bool + }{ + { + name: "check block number too told", + checkBlock: big.NewInt(500), + latestBlock: big.NewInt(800), + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + state: CheckBlockTooOld, + }, + { + name: "check block number invalid", + checkBlock: big.NewInt(500), + latestBlock: big.NewInt(560), + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + state: RpcFlakyFailure, + retryable: true, + makeEthCall: true, + }, + { + name: "check block hash does not match", + checkBlock: big.NewInt(500), + latestBlock: big.NewInt(560), + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + blocks: map[int64]string{ + 500: "0xa518faeadcc423338c62572da84dda35fe44b34f521ce88f6081b703b250cca4", + }, + state: CheckBlockInvalid, + }, + { + name: "check block is valid", + checkBlock: big.NewInt(500), + latestBlock: big.NewInt(560), + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + blocks: map[int64]string{ + 500: "0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83", + }, + state: NoPipelineError, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + bs := &BlockSubscriber{ + latestBlock: atomic.Int64{}, + blocks: tc.blocks, + } + bs.latestBlock.Store(tc.latestBlock.Int64()) + e := &EvmRegistry{ + lggr: lggr, + bs: bs, + } + if tc.makeEthCall { + client := new(evmClientMocks.Client) + client.On("BlockByNumber", mock.Anything, tc.checkBlock).Return(nil, fmt.Errorf("error")) + e.client = client + } + + state, retryable := e.verifyCheckBlock(context.Background(), tc.checkBlock, tc.upkeepId, tc.checkHash) + assert.Equal(t, tc.state, state) + assert.Equal(t, tc.retryable, retryable) + }) + } +} + +func TestRegistry_VerifyLogExists(t *testing.T) { + lggr := logger.TestLogger(t) + upkeepId := ocr2keepers.UpkeepIdentifier{} + upkeepId.FromBigInt(big.NewInt(12345)) + + extension := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71"), + BlockNumber: 500, + } + extension1 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71"), + BlockNumber: 0, + } + + tests := []struct { + name string + upkeepId *big.Int + payload ocr2keepers.UpkeepPayload + blocks map[int64]string + makeEthCall bool + reason UpkeepFailureReason + state PipelineExecutionState + retryable bool + ethCallErr error + receipt *types.Receipt + }{ + { + name: "log block number invalid", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), + WorkID: "work", + }, + reason: UpkeepFailureReasonNone, + state: RpcFlakyFailure, + retryable: true, + makeEthCall: true, + ethCallErr: fmt.Errorf("error"), + }, + { + name: "log block no longer exists", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), + WorkID: "work", + }, + reason: UpkeepFailureReasonLogBlockNoLongerExists, + retryable: false, + makeEthCall: true, + blocks: map[int64]string{ + 500: "0xb2173b4b75f23f56b7b2b6b2cc5fa9ed1079b9d1655b12b40fdb4dbf59006419", + }, + receipt: &types.Receipt{}, + }, + { + name: "eth client returns a matching block", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension1), + WorkID: "work", + }, + reason: UpkeepFailureReasonNone, + retryable: false, + blocks: map[int64]string{ + 500: "0xa518faeadcc423338c62572da84dda35fe44b34f521ce88f6081b703b250cca4", + }, + makeEthCall: true, + receipt: &types.Receipt{ + BlockNumber: big.NewInt(550), + BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + }, + }, + { + name: "log block is valid", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), + WorkID: "work", + }, + reason: UpkeepFailureReasonNone, + retryable: false, + blocks: map[int64]string{ + 500: "0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71", + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + bs := &BlockSubscriber{ + blocks: tc.blocks, + } + e := &EvmRegistry{ + lggr: lggr, + bs: bs, + ctx: context.Background(), + } + + if tc.makeEthCall { + client := new(evmClientMocks.Client) + client.On("TransactionReceipt", mock.Anything, common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651")). + Return(tc.receipt, tc.ethCallErr) + e.client = client + } + + reason, state, retryable := e.verifyLogExists(tc.upkeepId, tc.payload) + assert.Equal(t, tc.reason, reason) + assert.Equal(t, tc.state, state) + assert.Equal(t, tc.retryable, retryable) + }) + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index 8c79f13844a..3d4460a7c1d 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -135,6 +135,8 @@ func EVMDependencies21( var registry *kevm21.EvmRegistry var encoder *kevm21.EVMAutomationEncoder21 + bs := kevm21.NewBlockSubscriber(chain.HeadBroadcaster(), chain.LogPoller(), lggr) + oSpec := spec.OCR2OracleSpec // get the chain from the config @@ -153,19 +155,17 @@ func EVMDependencies21( } rAddr := ethkey.MustEIP55Address(oSpec.ContractID).Address() - if registry, encoder, err = kevm21.NewEVMRegistryService(rAddr, chain, mc, lggr); err != nil { + if registry, encoder, err = kevm21.NewEVMRegistryService(rAddr, chain, mc, bs, lggr); err != nil { return nil, nil, nil, nil, nil, nil, nil, err } - hp := kevm21.NewBlockSubscriber(chain.HeadBroadcaster(), chain.LogPoller(), 128, lggr) - // lookback blocks is hard coded and should provide ample time for logs // to be detected in most cases var lookbackBlocks int64 = 250 // TODO: accept a version of the registry contract and use the correct interfaces logTransmitter, err := kevm21.NewTransmitEventProvider(lggr, chain.LogPoller(), rAddr, chain.Client(), lookbackBlocks) - return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), kevm21.NewOnchainKeyringV3Wrapper(keyring), hp, err + return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), kevm21.NewOnchainKeyringV3Wrapper(keyring), bs, err } func FilterNamesFromSpec21(spec *job.OCR2OracleSpec) (names []string, err error) { From c09d01282f646cc498715ce0c0dbbb66d7511b94 Mon Sep 17 00:00:00 2001 From: martin-cll <121895364+martin-cll@users.noreply.github.com> Date: Tue, 15 Aug 2023 23:09:39 +1000 Subject: [PATCH 171/270] Mercury ConfigPoller should check for the address before Notifying (#10049) --- .../relay/evm/mercury/config_poller.go | 10 ++++++++- .../relay/evm/mercury/config_poller_test.go | 21 ++++++++++++------- .../services/relay/evm/mercury/helper_test.go | 2 ++ 3 files changed, 24 insertions(+), 9 deletions(-) diff --git a/core/services/relay/evm/mercury/config_poller.go b/core/services/relay/evm/mercury/config_poller.go index 78bfc457f26..8a5eade360c 100644 --- a/core/services/relay/evm/mercury/config_poller.go +++ b/core/services/relay/evm/mercury/config_poller.go @@ -191,7 +191,10 @@ func (cp *ConfigPoller) LatestBlockHeight(ctx context.Context) (blockHeight uint } func (cp *ConfigPoller) startLogSubscription() { - feedIdPgHex := cp.feedId.Hex()[2:] // trim the leading 0x to make it comparable to pg's hex encoding. + // trim the leading 0x to make it comparable to pg's hex encoding. + addressPgHex := cp.addr.Hex()[2:] + feedIdPgHex := cp.feedId.Hex()[2:] + for { event, ok := <-cp.subscription.Events() if !ok { @@ -206,6 +209,11 @@ func (cp *ConfigPoller) startLogSubscription() { continue } + address := addressTopicValues[0] + if address != addressPgHex { + continue + } + topicValues := strings.Split(addressTopicValues[1], ",") if len(topicValues) <= feedIdTopicIndex { continue diff --git a/core/services/relay/evm/mercury/config_poller_test.go b/core/services/relay/evm/mercury/config_poller_test.go index db1d5ee51a7..6a692b0eacd 100644 --- a/core/services/relay/evm/mercury/config_poller_test.go +++ b/core/services/relay/evm/mercury/config_poller_test.go @@ -125,34 +125,39 @@ func TestNotify(t *testing.T) { th := SetupTH(t, feedID) th.subscription.On("Events").Return((<-chan pg.Event)(eventCh)) + addressPgHex := th.verifierAddress.Hex()[2:] + notify := th.configPoller.Notify() assert.Empty(t, notify) eventCh <- pg.Event{} // Empty event assert.Empty(t, notify) - eventCh <- pg.Event{Payload: "address"} // missing topic values + eventCh <- pg.Event{Payload: addressPgHex} // missing topic values + assert.Empty(t, notify) + + eventCh <- pg.Event{Payload: addressPgHex + ":val1"} // missing feedId topic value assert.Empty(t, notify) - eventCh <- pg.Event{Payload: "address:val1"} // missing feedId topic value + eventCh <- pg.Event{Payload: addressPgHex + ":8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1,val2"} // wrong index assert.Empty(t, notify) - eventCh <- pg.Event{Payload: "address:8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1,val2"} // wrong index + eventCh <- pg.Event{Payload: addressPgHex + ":val1,val2,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // wrong index assert.Empty(t, notify) - eventCh <- pg.Event{Payload: "address:val1,val2,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // wrong index + eventCh <- pg.Event{Payload: addressPgHex + ":val1,0x8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // 0x prefix assert.Empty(t, notify) - eventCh <- pg.Event{Payload: "address:val1,0x8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // 0x prefix + eventCh <- pg.Event{Payload: "wrong_address:val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // wrong address assert.Empty(t, notify) - eventCh <- pg.Event{Payload: "address:val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} + eventCh <- pg.Event{Payload: addressPgHex + ":val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // expected event to notify on assert.Eventually(t, func() bool { <-notify; return true }, time.Second, 10*time.Millisecond) - eventCh <- pg.Event{Payload: "address:val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // try second time + eventCh <- pg.Event{Payload: addressPgHex + ":val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1"} // try second time assert.Eventually(t, func() bool { <-notify; return true }, time.Second, 10*time.Millisecond) - eventCh <- pg.Event{Payload: "address:val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1:additional"} + eventCh <- pg.Event{Payload: addressPgHex + ":val1,8257737fdf4f79639585fd0ed01bea93c248a9ad940e98dd27f41c9b6230fed1:additional"} // additional colon separated parts assert.Eventually(t, func() bool { <-notify; return true }, time.Second, 10*time.Millisecond) } diff --git a/core/services/relay/evm/mercury/helper_test.go b/core/services/relay/evm/mercury/helper_test.go index c696a66403c..d7789888f0c 100644 --- a/core/services/relay/evm/mercury/helper_test.go +++ b/core/services/relay/evm/mercury/helper_test.go @@ -27,6 +27,7 @@ type TestHarness struct { configPoller *ConfigPoller user *bind.TransactOpts backend *backends.SimulatedBackend + verifierAddress common.Address verifierContract *verifier.Verifier logPoller logpoller.LogPoller eventBroadcaster *pgmocks.EventBroadcaster @@ -73,6 +74,7 @@ func SetupTH(t *testing.T, feedID common.Hash) TestHarness { configPoller: configPoller, user: user, backend: b, + verifierAddress: verifierAddress, verifierContract: verifierContract, logPoller: lp, eventBroadcaster: eventBroadcaster, From 2b56c2510c21d58c8cf1f65069fa93940d93a677 Mon Sep 17 00:00:00 2001 From: frank zhu Date: Tue, 15 Aug 2023 09:25:16 -0500 Subject: [PATCH 172/270] RE-1535 - update ga dep to node v16 (#10138) * update ga dep to node v16 * fix typo --- .github/actions/build-sign-publish-chainlink/action.yml | 4 ++-- .github/actions/goreleaser-build-sign-publish/README.md | 2 +- .github/actions/goreleaser-build-sign-publish/action.yml | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/actions/build-sign-publish-chainlink/action.yml b/.github/actions/build-sign-publish-chainlink/action.yml index 9e0f8c62739..feef0e78d3b 100644 --- a/.github/actions/build-sign-publish-chainlink/action.yml +++ b/.github/actions/build-sign-publish-chainlink/action.yml @@ -93,7 +93,7 @@ runs: - if: inputs.publish == 'true' # Log in to AWS for publish to ECR name: Configure AWS Credentials - uses: aws-actions/configure-aws-credentials@67fbcbb121271f7775d2e7715933280b06314838 # v1.7.0 + uses: aws-actions/configure-aws-credentials@5fd3084fc36e372ff1fff382a39b10d03659f355 # v2.2.0 with: role-to-assume: ${{ inputs.aws-role-to-assume }} role-duration-seconds: ${{ inputs.aws-role-duration-seconds }} @@ -101,7 +101,7 @@ runs: - if: inputs.publish == 'true' name: Login to ECR - uses: docker/login-action@42d299face0c5c43a0487c477f595ac9cf22f1a7 # v1.12.0 + uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc # v2.2.0 with: registry: ${{ inputs.ecr-hostname }} diff --git a/.github/actions/goreleaser-build-sign-publish/README.md b/.github/actions/goreleaser-build-sign-publish/README.md index 5dc1f3c29ea..49edfb25d51 100644 --- a/.github/actions/goreleaser-build-sign-publish/README.md +++ b/.github/actions/goreleaser-build-sign-publish/README.md @@ -27,7 +27,7 @@ jobs: - name: Checkout repository uses: actions/checkout@v3 - name: Configure aws credentials - uses: aws-actions/configure-aws-credentials@67fbcbb121271f7775d2e7715933280b06314838 # v1.7.0 + uses: aws-actions/configure-aws-credentials@5fd3084fc36e372ff1fff382a39b10d03659f355 # v2.2.0 with: role-to-assume: ${{ secrets.aws-role-arn }} role-duration-seconds: ${{ secrets.aws-role-dur-sec }} diff --git a/.github/actions/goreleaser-build-sign-publish/action.yml b/.github/actions/goreleaser-build-sign-publish/action.yml index e0756d579f3..0cc144564c0 100644 --- a/.github/actions/goreleaser-build-sign-publish/action.yml +++ b/.github/actions/goreleaser-build-sign-publish/action.yml @@ -89,7 +89,7 @@ runs: cosign-release: ${{ inputs.cosign-version }} - name: Login to docker registry if: inputs.enable-docker-publish == 'true' - uses: docker/login-action@42d299face0c5c43a0487c477f595ac9cf22f1a7 # v1.12.0 + uses: docker/login-action@465a07811f14bebb1938fbed4728c6a1ff8901fc # v2.2.0 with: registry: ${{ inputs.docker-registry }} - name: Goreleaser release From 1abdb0503d06602f5dbc7e92b8085eebd4f89e71 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Tue, 15 Aug 2023 16:00:33 +0100 Subject: [PATCH 173/270] Upgrade to ocr2keepers latest (#10179) * Upgrade to ocr2keepers latest * update type * add todo * update * update ocr2keepers * added payload builder * get latest block once * update ocr2keepers * Hook in payload builder to delegate * hook in dependencies * fix conditionals * add missing file * use state unknown from ocr2keepers * update block subscriber to latest * update * update ocr2keepers * remove logs * small fixes * fix transmit event provider * fixes * logs * revert block subscriber changes * fix build * cleanup * update block subscriber * fix close * add nil protection * fix integration test * go mod tidy * fix tests --------- Co-authored-by: amirylm --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/services/ocr2/delegate.go | 22 +++++---- .../ocr2keeper/evm21/block_subscriber.go | 13 +++-- .../ocr2keeper/evm21/core/interfaces.go | 12 +++++ .../plugins/ocr2keeper/evm21/core/payload.go | 7 +++ .../ocr2keeper/evm21/logprovider/provider.go | 2 +- .../ocr2keeper/evm21/payload_builder.go | 48 +++++++++++++++++++ .../ocr2/plugins/ocr2keeper/evm21/registry.go | 5 +- .../evm21/transmit_event_provider.go | 1 + .../evm21/transmit_event_provider_test.go | 8 ++-- .../ocr2keeper/evm21/upkeepstate/store.go | 4 +- .../evm21/upkeepstate/store_test.go | 4 +- .../plugins/ocr2keeper/integration_21_test.go | 5 +- core/services/ocr2/plugins/ocr2keeper/util.go | 25 ++++++---- go.mod | 2 +- go.sum | 4 +- .../actions/automation_ocr_helpers.go | 1 - integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 20 files changed, 129 insertions(+), 46 deletions(-) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go diff --git a/core/scripts/go.mod b/core/scripts/go.mod index f307ed6baaa..e1ca822a887 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.8 + github.com/smartcontractkit/ocr2keepers v0.7.9 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 71c4f7a17ec..7a6f462181b 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= -github.com/smartcontractkit/ocr2keepers v0.7.8/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.9 h1:Jh6LJci3vEnEZWV/T13rJRvT/CLSHX90LRLB8ISFyuQ= +github.com/smartcontractkit/ocr2keepers v0.7.9/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 2ee64582664..4dbcbe85a4c 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -875,7 +875,7 @@ func (d *Delegate) newServicesOCR2Keepers21( mc := d.cfg.Mercury().Credentials(credName) - keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, d.chainSet, d.pipelineRunner, mc, kb) + keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, payloadBuilder, upkeepStateStore, up, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, d.chainSet, d.pipelineRunner, mc, kb) if err2 != nil { return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") } @@ -911,23 +911,28 @@ func (d *Delegate) newServicesOCR2Keepers21( ContractTransmitter: evmrelay.NewKeepersOCR3ContractTransmitter(keeperProvider.ContractTransmitter()), ContractConfigTracker: keeperProvider.ContractConfigTracker(), KeepersDatabase: ocrDB, - LocalConfig: lc, Logger: ocrLogger, MonitoringEndpoint: d.monitoringEndpointGen.GenMonitoringEndpoint(spec.ContractID, synchronization.OCR2Automation), OffchainConfigDigester: keeperProvider.OffchainConfigDigester(), OffchainKeyring: kb, OnchainKeyring: wrappedKey, + LocalConfig: lc, + LogProvider: logProvider, EventProvider: transmitEventProvider, - Encoder: encoder, Runnable: rgstry, - LogProvider: logProvider, - CacheExpiration: cfg.CacheExpiration.Value(), - CacheEvictionInterval: cfg.CacheEvictionInterval.Value(), - MaxServiceWorkers: cfg.MaxServiceWorkers, - ServiceQueueLength: cfg.ServiceQueueLength, + Encoder: encoder, BlockSubscriber: blockSub, RecoverableProvider: new(mockRecoverableProvider), + PayloadBuilder: payloadBuilder, + UpkeepProvider: up, + UpkeepStateUpdater: upkeepStateStore, UpkeepTypeGetter: ocr2keeper21core.GetUpkeepType, + WorkIDGenerator: ocr2keeper21core.WorkIDGenerator, + // TODO: Clean up the config + CacheExpiration: cfg.CacheExpiration.Value(), + CacheEvictionInterval: cfg.CacheEvictionInterval.Value(), + MaxServiceWorkers: cfg.MaxServiceWorkers, + ServiceQueueLength: cfg.ServiceQueueLength, } pluginService, err := ocr2keepers21.NewDelegate(dConf) @@ -950,6 +955,7 @@ func (d *Delegate) newServicesOCR2Keepers21( runResultSaver, keeperProvider, rgstry, + blockSub, transmitEventProvider, pluginService, }, nil diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go index 04bc77b2580..2785e6503ed 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go @@ -106,7 +106,7 @@ func (bs *BlockSubscriber) buildHistory(block int64) ocr2keepers.BlockHistory { Hash: common.HexToHash(h), }) } else { - bs.lggr.Infof("block %d is missing", block-i) + bs.lggr.Debugf("block %d is missing", block-i) } } } @@ -117,7 +117,7 @@ func (bs *BlockSubscriber) cleanup() { bs.mu.Lock() defer bs.mu.Unlock() - bs.lggr.Infof("start clearing blocks from %d to %d", bs.lastClearedBlock+1, bs.lastSentBlock-bs.blockSize) + bs.lggr.Debugf("start clearing blocks from %d to %d", bs.lastClearedBlock+1, bs.lastSentBlock-bs.blockSize) for i := bs.lastClearedBlock + 1; i <= bs.lastSentBlock-bs.blockSize; i++ { delete(bs.blocks, i) } @@ -142,7 +142,7 @@ func (bs *BlockSubscriber) Start(ctx context.Context) error { bs.lggr.Errorf("failed to get log poller blocks", err) } - _, bs.unsubscribe = bs.hb.Subscribe(&headWrapper{headC: bs.headC}) + _, bs.unsubscribe = bs.hb.Subscribe(&headWrapper{headC: bs.headC, lggr: bs.lggr}) // poll from head broadcaster channel and push to subscribers { @@ -150,7 +150,9 @@ func (bs *BlockSubscriber) Start(ctx context.Context) error { for { select { case h := <-bs.headC: - bs.processHead(h) + if h != nil { + bs.processHead(h) + } case <-ctx.Done(): return } @@ -184,7 +186,6 @@ func (bs *BlockSubscriber) Close() error { bs.mu.Lock() defer bs.mu.Unlock() - close(bs.headC) bs.cancel() bs.unsubscribe() return nil @@ -263,6 +264,7 @@ func (bs *BlockSubscriber) queryBlocksMap(bn int64) (string, bool) { type headWrapper struct { headC chan *evmtypes.Head + lggr logger.Logger } func (w *headWrapper) OnNewLongestChain(_ context.Context, head *evmtypes.Head) { @@ -270,6 +272,7 @@ func (w *headWrapper) OnNewLongestChain(_ context.Context, head *evmtypes.Head) select { case w.headC <- head: default: + w.lggr.Debugf("head channel is full, discarding head %+v", head) } } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go new file mode 100644 index 00000000000..99db102a109 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go @@ -0,0 +1,12 @@ +package core + +import ( + "context" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" +) + +// UpkeepStateReader is the interface for reading the current state of upkeeps. +type UpkeepStateReader interface { + SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go index f37a8ee94e6..f3c035cb697 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go @@ -29,6 +29,13 @@ func UpkeepWorkID(id *big.Int, trigger ocr2keepers.Trigger) (string, error) { return hex.EncodeToString(hash[:]), nil } +func WorkIDGenerator(u ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) string { + // Error should not happen here since we pass in a valid upkeepID + // TODO: Clean this up + id, _ := UpkeepWorkID(u.BigInt(), trigger) + return id +} + func NewUpkeepPayload(id *big.Int, trigger ocr2keepers.Trigger, checkData []byte) (ocr2keepers.UpkeepPayload, error) { uid := &ocr2keepers.UpkeepIdentifier{} ok := uid.FromBigInt(id) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 3c706bf2370..71cf8a15374 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -123,7 +123,7 @@ func (p *logEventProvider) Close() error { return nil } -func (p *logEventProvider) BuildPayloads(ctx context.Context, proposals ...ocr2keepers.CoordinatedProposal) ([]ocr2keepers.UpkeepPayload, error) { +func (p *logEventProvider) BuildPayloads(ctx context.Context, proposals ...ocr2keepers.CoordinatedBlockProposal) ([]ocr2keepers.UpkeepPayload, error) { // TODO: implement return []ocr2keepers.UpkeepPayload{}, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go new file mode 100644 index 00000000000..51991b5d5aa --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go @@ -0,0 +1,48 @@ +package evm + +import ( + "context" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" +) + +type payloadBuilder struct { + lggr logger.Logger +} + +var _ ocr2keepers.PayloadBuilder = &payloadBuilder{} + +func NewPayloadBuilder(lggr logger.Logger) *payloadBuilder { + return &payloadBuilder{ + lggr: lggr, + } +} + +func (b *payloadBuilder) BuildPayloads(ctx context.Context, proposals ...ocr2keepers.CoordinatedBlockProposal) ([]ocr2keepers.UpkeepPayload, error) { + payloads := make([]ocr2keepers.UpkeepPayload, len(proposals)) + for i, p := range proposals { + b.lggr.Debugf("building payload for coordinated block proposal %+v", p) + var checkData []byte + switch core.GetUpkeepType(p.UpkeepID) { + case ocr2keepers.LogTrigger: + checkData = []byte{} // TODO: call recoverer + case ocr2keepers.ConditionTrigger: + // Trigger.BlockNumber and Trigger.BlockHash are already coordinated + checkData = []byte{} // CheckData derived on chain for conditionals + // TODO: check for upkeepID being active upkeep here + default: + } + payload, err := core.NewUpkeepPayload(p.UpkeepID.BigInt(), p.Trigger, checkData) + if err != nil { + b.lggr.Warnw("failed to build payload", "err", err, "upkeepID", p.UpkeepID) + payloads[i] = ocr2keepers.UpkeepPayload{} + continue + } + payloads[i] = payload + } + + return payloads, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 864db7e7c83..959d80e924a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -229,6 +229,7 @@ func (r *EvmRegistry) GetActiveUpkeepIDsByType(ctx context.Context, triggers ... } func (r *EvmRegistry) CheckUpkeeps(ctx context.Context, keys ...ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { + r.lggr.Debugw("Checking upkeeps", "upkeeps", keys) chResult := make(chan checkResult, 1) go r.doCheck(ctx, keys, chResult) @@ -704,7 +705,9 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.U return nil, err } default: - payload, err = r.abi.Pack("checkUpkeep", upkeepId) + // checkUpkeep is overloaded on the contract for conditionals and log upkeeps + // Need to use the first function (checkUpkeep0) for conditionals + payload, err = r.abi.Pack("checkUpkeep0", upkeepId) if err != nil { return nil, err } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go index 9f91fae2ebb..d3fbc496aae 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go @@ -243,6 +243,7 @@ func (c *TransmitEventProvider) convertToTransmitEvents(logs []transmitEventLog, TransactionHash: l.TxHash, WorkID: workID, UpkeepID: *upkeepId, + CheckBlock: trigger.BlockNumber, }) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go index 5c08cc1ebdf..f41a80655de 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go @@ -130,7 +130,7 @@ func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { { Type: ocr2keepers.PerformEvent, UpkeepID: id, - CheckBlock: ocr2keepers.BlockNumber(0), // empty for log triggers + CheckBlock: ocr2keepers.BlockNumber(1), // empty for log triggers }, }, false, @@ -206,7 +206,7 @@ func TestTransmitEventLog(t *testing.T) { Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, - ocr2keepers.TransmitEventType(3), + ocr2keepers.InsufficientFundsReportEvent, }, { "reorged", @@ -220,7 +220,7 @@ func TestTransmitEventLog(t *testing.T) { Trigger: []byte{1, 2, 3, 4, 5, 6, 7, 8}, }, }, - ocr2keepers.TransmitEventType(2), + ocr2keepers.ReorgReportEvent, }, { "empty", @@ -230,7 +230,7 @@ func TestTransmitEventLog(t *testing.T) { BlockHash: common.HexToHash("0x010203040"), }, }, - ocr2keepers.TransmitEventType(0), + ocr2keepers.UnknownEvent, }, } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go index 4bc547750c7..c70e8226d9b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go @@ -15,8 +15,6 @@ var ( CacheExpiration = 24 * time.Hour // GCInterval is the amount of time between cache cleanups. GCInterval = 2 * time.Hour - // TODO: use sentinel value from ocr2keepers - StateUnknown = ocr2keepers.UpkeepState(100) ) // UpkeepStateReader is the interface for reading the current state of upkeeps. @@ -194,7 +192,7 @@ func (u *upkeepStateStore) selectFromCache(workIDs ...string) ([]ocr2keepers.Upk states[i] = state.state } else { hasMisses = true - states[i] = StateUnknown + states[i] = ocr2keepers.UnknownState } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go index 368dca8af9f..1d89546c844 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go @@ -52,7 +52,7 @@ func TestUpkeepStateStore(t *testing.T) { workIDsSelect: []string{"0x1", "0x2"}, expected: []ocr2keepers.UpkeepState{ ocr2keepers.Ineligible, - StateUnknown, + ocr2keepers.UnknownState, }, }, { @@ -89,7 +89,7 @@ func TestUpkeepStateStore(t *testing.T) { workIDsSelect: []string{"0x2"}, workIDsFromScanner: []string{}, expected: []ocr2keepers.UpkeepState{ - StateUnknown, + ocr2keepers.UnknownState, }, }, { diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go index 25243580805..0f19c49ccb7 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go @@ -76,8 +76,6 @@ func TestFilterNamesFromSpec21(t *testing.T) { } func TestIntegration_KeeperPluginConditionalUpkeep(t *testing.T) { - t.Skip() // TODO: unskip when conditional flow is ready - g := gomega.NewWithT(t) lggr := logger.TestLogger(t) @@ -173,7 +171,6 @@ func TestIntegration_KeeperPluginConditionalUpkeep(t *testing.T) { } func TestIntegration_KeeperPluginLogUpkeep(t *testing.T) { - t.Skip() // TODO: Auto-4282, Run this in CI once the tests properly waits instead of timers g := gomega.NewWithT(t) // setup blockchain @@ -394,7 +391,7 @@ func setupNodes(t *testing.T, nodeKeys [5]ethkey.KeyV2, registry *iregistry21.IK 5*time.Second, // deltaProgress time.Duration, 10*time.Second, // deltaResend time.Duration, 100*time.Millisecond, // deltaInitial time.Duration, - 2500*time.Millisecond, // deltaRound time.Duration, + 1000*time.Millisecond, // deltaRound time.Duration, 40*time.Millisecond, // deltaGrace time.Duration, 200*time.Millisecond, // deltaRequestCertifiedCommit time.Duration, 30*time.Second, // deltaStage time.Duration, diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index 3d4460a7c1d..819f14be20e 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -24,6 +24,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/models" kevm20 "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm20" kevm21 "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) @@ -128,44 +129,52 @@ func EVMDependencies21( pr pipeline.Runner, mc *models.MercuryCredentials, keyring ocrtypes.OnchainKeyring, -) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[ocr2keepers21plugin.AutomationReportInfo], *kevm21.BlockSubscriber, error) { +) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[ocr2keepers21plugin.AutomationReportInfo], *kevm21.BlockSubscriber, ocr2keepers21.PayloadBuilder, ocr2keepers21.UpkeepStateUpdater, ocr2keepers21.ConditionalUpkeepProvider, error) { var err error var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider var registry *kevm21.EvmRegistry var encoder *kevm21.EVMAutomationEncoder21 - bs := kevm21.NewBlockSubscriber(chain.HeadBroadcaster(), chain.LogPoller(), lggr) - oSpec := spec.OCR2OracleSpec // get the chain from the config chainID, err2 := spec.OCR2OracleSpec.RelayConfig.EVMChainID() if err2 != nil { - return nil, nil, nil, nil, nil, nil, nil, err2 + return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err2 } chain, err2 = set.Get(big.NewInt(chainID)) if err2 != nil { - return nil, nil, nil, nil, nil, nil, nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err2) + return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err2) } // the provider will be returned as a dependency if keeperProvider, err = EVMProvider(db, chain, lggr, spec, pr); err != nil { - return nil, nil, nil, nil, nil, nil, nil, err + return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err } + bs := kevm21.NewBlockSubscriber(chain.HeadBroadcaster(), chain.LogPoller(), lggr) rAddr := ethkey.MustEIP55Address(oSpec.ContractID).Address() if registry, encoder, err = kevm21.NewEVMRegistryService(rAddr, chain, mc, bs, lggr); err != nil { - return nil, nil, nil, nil, nil, nil, nil, err + return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err } + pb := kevm21.NewPayloadBuilder(lggr) + scanner := upkeepstate.NewPerformedEventsScanner( + lggr, + chain.LogPoller(), + rAddr, + ) + us := upkeepstate.NewUpkeepStateStore(lggr, scanner) + up := kevm21.NewUpkeepProvider(registry, chain.LogPoller()) + // lookback blocks is hard coded and should provide ample time for logs // to be detected in most cases var lookbackBlocks int64 = 250 // TODO: accept a version of the registry contract and use the correct interfaces logTransmitter, err := kevm21.NewTransmitEventProvider(lggr, chain.LogPoller(), rAddr, chain.Client(), lookbackBlocks) - return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), kevm21.NewOnchainKeyringV3Wrapper(keyring), bs, err + return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), kevm21.NewOnchainKeyringV3Wrapper(keyring), bs, pb, us, up, err } func FilterNamesFromSpec21(spec *job.OCR2OracleSpec) (names []string, err error) { diff --git a/go.mod b/go.mod index 2ac69664cee..a38b5a47c63 100644 --- a/go.mod +++ b/go.mod @@ -70,7 +70,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.8 + github.com/smartcontractkit/ocr2keepers v0.7.9 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index 9dc347808fd..19f3d1cf8d8 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= -github.com/smartcontractkit/ocr2keepers v0.7.8/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.9 h1:Jh6LJci3vEnEZWV/T13rJRvT/CLSHX90LRLB8ISFyuQ= +github.com/smartcontractkit/ocr2keepers v0.7.9/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/actions/automation_ocr_helpers.go b/integration-tests/actions/automation_ocr_helpers.go index 1a01db4d026..0a85ef8f47b 100644 --- a/integration-tests/actions/automation_ocr_helpers.go +++ b/integration-tests/actions/automation_ocr_helpers.go @@ -70,7 +70,6 @@ func BuildAutoOCR2ConfigVarsWithKeyIndex( PerformLockoutWindow: 3600000, // Intentionally set to be higher than in prod for testing purpose GasLimitPerReport: 5_300_000, GasOverheadPerUpkeep: 300_000, - SamplingJobDuration: 3000, MinConfirmations: 0, MaxUpkeepBatchSize: 1, }) diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 3440cee1512..bf91f13c4a8 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.2 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.8 + github.com/smartcontractkit/ocr2keepers v0.7.9 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.9 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 8cb832a0980..4d20eb55875 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.8 h1:Z7fSsbWj/9K0CNPN057jrfoEaPOi23B76YsOxxxmXjU= -github.com/smartcontractkit/ocr2keepers v0.7.8/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.9 h1:Jh6LJci3vEnEZWV/T13rJRvT/CLSHX90LRLB8ISFyuQ= +github.com/smartcontractkit/ocr2keepers v0.7.9/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From a501c107be19d71e18bf45c9062f190a76a0ed71 Mon Sep 17 00:00:00 2001 From: Tate Date: Tue, 15 Aug 2023 09:42:02 -0600 Subject: [PATCH 174/270] [TT-529] Collect Metrics Jobs Per Page Fix (#10198) * [TT-529] Collect Metrics Jobs Per Page Fix * post merge conflict fixees --- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 ++--- .github/workflows/build-publish-develop.yml | 2 +- .github/workflows/build-publish.yml | 2 +- .github/workflows/build.yml | 2 +- .github/workflows/changelog.yml | 2 +- .github/workflows/ci-core.yml | 12 +++++----- .github/workflows/codeql-analysis.yml | 2 +- .github/workflows/dependency-check.yml | 2 +- .../goreleaser-build-publish-develop.yml | 2 +- .github/workflows/integration-chaos-tests.yml | 6 ++--- .../workflows/integration-tests-publish.yml | 2 +- .github/workflows/integration-tests.yml | 22 +++++++++---------- .github/workflows/lint-gh-workflows.yml | 2 +- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/operator-ui.yml | 2 +- .github/workflows/performance-tests.yml | 4 ++-- .github/workflows/readme.yml | 2 +- .github/workflows/sigscanner.yml | 2 +- .github/workflows/solidity-foundry.yml | 2 +- .github/workflows/solidity-hardhat.yml | 8 +++---- .github/workflows/solidity.yml | 8 +++---- ...evelop-from-smartcontractkit-chainlink.yml | 2 +- 23 files changed, 49 insertions(+), 49 deletions(-) diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index 2e136a2f561..7d5e11b157c 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -128,7 +128,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index dcd22f46f06..b814f3ba903 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -36,7 +36,7 @@ jobs: - name: Collect Metrics if: inputs.chainlinkImage == '' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -81,7 +81,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -192,7 +192,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish-develop.yml b/.github/workflows/build-publish-develop.yml index 75c870e1f1b..67bf3e1f78e 100644 --- a/.github/workflows/build-publish-develop.yml +++ b/.github/workflows/build-publish-develop.yml @@ -40,7 +40,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build-publish.yml b/.github/workflows/build-publish.yml index 34af77f17f4..b1efc9fa9a8 100644 --- a/.github/workflows/build-publish.yml +++ b/.github/workflows/build-publish.yml @@ -50,7 +50,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index d38f9eb7f16..d18946b76e6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -22,7 +22,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/changelog.yml b/.github/workflows/changelog.yml index c39e9d38dc2..7378a227ecb 100644 --- a/.github/workflows/changelog.yml +++ b/.github/workflows/changelog.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index d3ef925a604..6a32a899375 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -95,7 +95,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -124,7 +124,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -203,7 +203,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -230,7 +230,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -323,7 +323,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -355,7 +355,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index ceef57d5fe7..37eaa557927 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -48,7 +48,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/dependency-check.yml b/.github/workflows/dependency-check.yml index 7464869a100..e4cb1081429 100644 --- a/.github/workflows/dependency-check.yml +++ b/.github/workflows/dependency-check.yml @@ -47,7 +47,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/goreleaser-build-publish-develop.yml b/.github/workflows/goreleaser-build-publish-develop.yml index 70b6b8f5d64..56fcff14f94 100644 --- a/.github/workflows/goreleaser-build-publish-develop.yml +++ b/.github/workflows/goreleaser-build-publish-develop.yml @@ -39,7 +39,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index 37aefd8f082..a9d3c559f93 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -53,7 +53,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -99,7 +99,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests-publish.yml b/.github/workflows/integration-tests-publish.yml index 5fa164ef4ff..9581a2af510 100644 --- a/.github/workflows/integration-tests-publish.yml +++ b/.github/workflows/integration-tests-publish.yml @@ -20,7 +20,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index b767d99721c..dd74b92d594 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -43,7 +43,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -73,7 +73,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -120,7 +120,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -217,7 +217,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -431,7 +431,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -452,7 +452,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -520,7 +520,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -626,7 +626,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -665,7 +665,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -719,7 +719,7 @@ jobs: - name: Collect Metrics if: needs.changes.outputs.src == 'true' id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -817,7 +817,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/lint-gh-workflows.yml b/.github/workflows/lint-gh-workflows.yml index cadbb3b8e63..95c80f3d5da 100644 --- a/.github/workflows/lint-gh-workflows.yml +++ b/.github/workflows/lint-gh-workflows.yml @@ -13,7 +13,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index b94e36179f7..8a986b3bdd2 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -81,7 +81,7 @@ jobs: steps: - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/operator-ui.yml b/.github/workflows/operator-ui.yml index d9c2d9827e3..8aac69c04dd 100644 --- a/.github/workflows/operator-ui.yml +++ b/.github/workflows/operator-ui.yml @@ -33,7 +33,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 032b35b84d5..60479e6c960 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -42,7 +42,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/readme.yml b/.github/workflows/readme.yml index 22172dd9dc3..d3788674d6d 100644 --- a/.github/workflows/readme.yml +++ b/.github/workflows/readme.yml @@ -31,7 +31,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sigscanner.yml b/.github/workflows/sigscanner.yml index d84891711d8..390af228f06 100644 --- a/.github/workflows/sigscanner.yml +++ b/.github/workflows/sigscanner.yml @@ -26,7 +26,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index 755874b9462..ff357312a6a 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -79,7 +79,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity-hardhat.yml b/.github/workflows/solidity-hardhat.yml index 4a2394f17f0..1c630b48bb8 100644 --- a/.github/workflows/solidity-hardhat.yml +++ b/.github/workflows/solidity-hardhat.yml @@ -47,7 +47,7 @@ jobs: config: ./contracts/ci.json - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -89,7 +89,7 @@ jobs: path: ./contracts/coverage-${{ matrix.split.idx }}.json - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -144,7 +144,7 @@ jobs: run: pnpm test -- $SPLIT - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -169,7 +169,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/solidity.yml b/.github/workflows/solidity.yml index 75e8fda6add..b024782ed42 100644 --- a/.github/workflows/solidity.yml +++ b/.github/workflows/solidity.yml @@ -40,7 +40,7 @@ jobs: run: pnpm prepublishOnly - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -84,7 +84,7 @@ jobs: run: gh pr comment -b 'Go solidity wrappers are out-of-date, regenerate them via the `make wrappers-all` command' - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -108,7 +108,7 @@ jobs: run: pnpm lint - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} @@ -132,7 +132,7 @@ jobs: run: pnpm prettier:check - name: Collect Metrics id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} diff --git a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml index 2718e3865b4..314095a5012 100644 --- a/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml +++ b/.github/workflows/sync-develop-from-smartcontractkit-chainlink.yml @@ -30,7 +30,7 @@ jobs: - name: Collect Metrics if: always() id: collect-gha-metrics - uses: smartcontractkit/push-gha-metrics-action@6f41029bc7f0d0db5827f6804a2322e2a89e3b32 + uses: smartcontractkit/push-gha-metrics-action@d2c2b7bdc9012651230b2608a1bcb0c48538b6ec with: basic-auth: ${{ secrets.GRAFANA_CLOUD_BASIC_AUTH }} hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} From 1f7a1fd8b371a5d2660b84b96dfdd1313e36a344 Mon Sep 17 00:00:00 2001 From: Ilja Pavlovs Date: Tue, 15 Aug 2023 18:54:29 +0300 Subject: [PATCH 175/270] Chore/tt 525 run ctf tests against testnets (#10178) * fix VRF V3 setup script * TT-525 - add possibility to run CTF Docker tests against live testnets * reverting requirements.txt change * fixing keeper_test.go --- .../vrfv2_constants/constants.go | 2 +- .../actions/vrfv2_actions/vrfv2_steps.go | 16 ++-- integration-tests/docker/test_env/geth.go | 54 ++++--------- integration-tests/docker/test_env/test_env.go | 21 +++-- .../docker/test_env/test_env_builder.go | 67 ++++++++++++---- integration-tests/load/vrfv2/vrfv2_test.go | 2 +- integration-tests/smoke/README.md | 12 +++ integration-tests/smoke/flux_test.go | 20 ++--- integration-tests/smoke/forwarder_ocr_test.go | 24 +++--- .../smoke/forwarders_ocr2_test.go | 26 +++---- integration-tests/smoke/keeper_test.go | 8 +- integration-tests/smoke/ocr2_test.go | 14 ++-- integration-tests/smoke/ocr_test.go | 12 +-- integration-tests/smoke/runlog_test.go | 8 +- integration-tests/smoke/vrf_test.go | 8 +- integration-tests/smoke/vrfv2_test.go | 19 +++-- integration-tests/types/config/node/core.go | 76 +++++++++---------- 17 files changed, 207 insertions(+), 182 deletions(-) diff --git a/integration-tests/actions/vrfv2_actions/vrfv2_constants/constants.go b/integration-tests/actions/vrfv2_actions/vrfv2_constants/constants.go index b5e86a88d5c..2ec993e4e6e 100644 --- a/integration-tests/actions/vrfv2_actions/vrfv2_constants/constants.go +++ b/integration-tests/actions/vrfv2_actions/vrfv2_constants/constants.go @@ -13,7 +13,7 @@ var ( //todo - get Sub id when creating subscription - need to listen for SubscriptionCreated Log SubID = uint64(1) VRFSubscriptionFundingAmountLink = big.NewInt(100) - ChainlinkNodeFundingAmountEth = big.NewFloat(1) + ChainlinkNodeFundingAmountEth = big.NewFloat(0.1) NumberOfWords = uint32(3) MaxGasPriceGWei = 1000 CallbackGasLimit = uint32(1000000) diff --git a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go index a428ecb369e..b59f8c761f1 100644 --- a/integration-tests/actions/vrfv2_actions/vrfv2_steps.go +++ b/integration-tests/actions/vrfv2_actions/vrfv2_steps.go @@ -162,19 +162,19 @@ func SetupLocalLoadTestEnv(nodesFunding *big.Float, subFundingLINK *big.Int) (*t } env.ParallelTransactions(true) - mockFeed, err := actions.DeployMockETHLinkFeed(env.Geth.ContractDeployer, vrfConst.LinkEthFeedResponse) + mockFeed, err := actions.DeployMockETHLinkFeed(env.ContractDeployer, vrfConst.LinkEthFeedResponse) if err != nil { return nil, nil, [32]byte{}, err } - lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) + lt, err := actions.DeployLINKToken(env.ContractDeployer) if err != nil { return nil, nil, [32]byte{}, err } - vrfv2Contracts, err := DeployVRFV2Contracts(env.Geth.ContractDeployer, env.Geth.EthClient, lt, mockFeed) + vrfv2Contracts, err := DeployVRFV2Contracts(env.ContractDeployer, env.EVMClient, lt, mockFeed) if err != nil { return nil, nil, [32]byte{}, err } - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() if err != nil { return nil, nil, [32]byte{}, err } @@ -189,7 +189,7 @@ func SetupLocalLoadTestEnv(nodesFunding *big.Float, subFundingLINK *big.Int) (*t if err != nil { return nil, nil, [32]byte{}, err } - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() if err != nil { return nil, nil, [32]byte{}, err } @@ -197,7 +197,7 @@ func SetupLocalLoadTestEnv(nodesFunding *big.Float, subFundingLINK *big.Int) (*t if err != nil { return nil, nil, [32]byte{}, err } - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() if err != nil { return nil, nil, [32]byte{}, err } @@ -205,11 +205,11 @@ func SetupLocalLoadTestEnv(nodesFunding *big.Float, subFundingLINK *big.Int) (*t if err != nil { return nil, nil, [32]byte{}, err } - err = FundVRFCoordinatorV2Subscription(lt, vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.SubID, subFundingLINK) + err = FundVRFCoordinatorV2Subscription(lt, vrfv2Contracts.Coordinator, env.EVMClient, vrfConst.SubID, subFundingLINK) if err != nil { return nil, nil, [32]byte{}, err } - jobs, err := CreateVRFV2Jobs(env.GetAPIs(), vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.MinimumConfirmations) + jobs, err := CreateVRFV2Jobs(env.GetAPIs(), vrfv2Contracts.Coordinator, env.EVMClient, vrfConst.MinimumConfirmations) if err != nil { return nil, nil, [32]byte{}, err } diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index e26bdf9cb23..f6c5f36e767 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -13,7 +13,6 @@ import ( "github.com/pkg/errors" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" @@ -29,13 +28,10 @@ const ( type Geth struct { EnvComponent - ExternalHttpUrl string - InternalHttpUrl string - ExternalWsUrl string - InternalWsUrl string - EthClient *blockchain.EthereumClient - ContractDeployer contracts.ContractDeployer - ContractLoader contracts.ContractLoader + ExternalHttpUrl string + InternalHttpUrl string + ExternalWsUrl string + InternalWsUrl string } func NewGeth(networks []string, opts ...EnvComponentOption) *Geth { @@ -51,10 +47,10 @@ func NewGeth(networks []string, opts ...EnvComponentOption) *Geth { return g } -func (g *Geth) StartContainer() error { +func (g *Geth) StartContainer() (blockchain.EVMNetwork, InternalDockerUrls, error) { r, _, _, err := g.getGethContainerRequest(g.Networks) if err != nil { - return err + return blockchain.EVMNetwork{}, InternalDockerUrls{}, err } ct, err := tc.GenericContainer(context.Background(), tc.GenericContainerRequest{ @@ -63,19 +59,19 @@ func (g *Geth) StartContainer() error { Reuse: true, }) if err != nil { - return errors.Wrapf(err, "cannot start geth container") + return blockchain.EVMNetwork{}, InternalDockerUrls{}, errors.Wrapf(err, "cannot start geth container") } host, err := ct.Host(context.Background()) if err != nil { - return err + return blockchain.EVMNetwork{}, InternalDockerUrls{}, err } httpPort, err := ct.MappedPort(context.Background(), "8544/tcp") if err != nil { - return err + return blockchain.EVMNetwork{}, InternalDockerUrls{}, err } wsPort, err := ct.MappedPort(context.Background(), "8545/tcp") if err != nil { - return err + return blockchain.EVMNetwork{}, InternalDockerUrls{}, err } g.Container = ct @@ -89,32 +85,10 @@ func (g *Geth) StartContainer() error { networkConfig.URLs = []string{g.ExternalWsUrl} networkConfig.HTTPURLs = []string{g.ExternalHttpUrl} - bc, err := blockchain.NewEVMClientFromNetwork(networkConfig) - if err != nil { - return err - } - // Get blockchain.EthereumClient as this is the only possible client for Geth - switch val := bc.(type) { - case *blockchain.EthereumMultinodeClient: - ethClient, ok := val.Clients[0].(*blockchain.EthereumClient) - if !ok { - return errors.Errorf("could not get blockchain.EthereumClient from %+v", val) - } - g.EthClient = ethClient - default: - return errors.Errorf("%+v not supported for geth", val) - } - - cd, err := contracts.NewContractDeployer(bc) - if err != nil { - return err - } - g.ContractDeployer = cd - cl, err := contracts.NewContractLoader(bc) - if err != nil { - return err + internalDockerUrls := InternalDockerUrls{ + HttpUrl: g.InternalHttpUrl, + WsUrl: g.InternalWsUrl, } - g.ContractLoader = cl log.Info().Str("containerName", g.ContainerName). Str("internalHttpUrl", g.InternalHttpUrl). @@ -123,7 +97,7 @@ func (g *Geth) StartContainer() error { Str("internalWsUrl", g.InternalWsUrl). Msg("Started Geth container") - return nil + return networkConfig, internalDockerUrls, nil } func (g *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, *keystore.KeyStore, *accounts.Account, error) { diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index d6cfdbe70cc..f283edf31fa 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -1,6 +1,8 @@ package test_env import ( + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" "sync" "math/big" @@ -28,9 +30,12 @@ type CLClusterTestEnv struct { LogWatch *logwatch.LogWatch /* components */ - CLNodes []*ClNode - Geth *Geth - MockServer *MockServer + CLNodes []*ClNode + Geth *Geth + MockServer *MockServer + EVMClient blockchain.EVMClient + ContractDeployer contracts.ContractDeployer + ContractLoader contracts.ContractLoader } func NewTestEnv() (*CLClusterTestEnv, error) { @@ -64,10 +69,10 @@ func NewTestEnvFromCfg(cfg *TestEnvConfig) (*CLClusterTestEnv, error) { } func (te *CLClusterTestEnv) ParallelTransactions(enabled bool) { - te.Geth.EthClient.ParallelTransactions(enabled) + te.EVMClient.ParallelTransactions(enabled) } -func (te *CLClusterTestEnv) StartGeth() error { +func (te *CLClusterTestEnv) StartGeth() (blockchain.EVMNetwork, InternalDockerUrls, error) { return te.Geth.StartContainer() } @@ -141,11 +146,11 @@ func (te *CLClusterTestEnv) ChainlinkNodeAddresses() ([]common.Address, error) { // FundChainlinkNodes will fund all the provided Chainlink nodes with a set amount of native currency func (te *CLClusterTestEnv) FundChainlinkNodes(amount *big.Float) error { for _, cl := range te.CLNodes { - if err := cl.Fund(te.Geth.EthClient, amount); err != nil { + if err := cl.Fund(te.EVMClient, amount); err != nil { return errors.Wrap(err, ErrFundCLNode) } } - return te.Geth.EthClient.WaitForEvents() + return te.EVMClient.WaitForEvents() } func (te *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { @@ -162,6 +167,6 @@ func (te *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { func (te *CLClusterTestEnv) Terminate() error { // TESTCONTAINERS_RYUK_DISABLED=false by defualt so ryuk will remove all - // the containers and the network + // the containers and the Network return nil } diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index f696e8f601c..aa9374d0640 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -1,6 +1,9 @@ package test_env import ( + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/networks" "os" "math/big" @@ -26,6 +29,11 @@ type CLTestEnvBuilder struct { ETHFunds *big.Float } +type InternalDockerUrls struct { + HttpUrl string + WsUrl string +} + func NewCLTestEnvBuilder() *CLTestEnvBuilder { return &CLTestEnvBuilder{ externalAdapterCount: 1, @@ -96,40 +104,60 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e if cfg != nil { te, err = NewTestEnvFromCfg(cfg) if err != nil { - return te, err + return nil, err } } else { te, err = NewTestEnv() if err != nil { - return te, err + return nil, err } } if b.hasLogWatch { te.LogWatch, err = logwatch.NewLogWatch(nil, nil) if err != nil { - return te, err + return nil, err } } if b.hasMockServer { err = te.StartMockServer() if err != nil { - return te, err + return nil, err } err = te.MockServer.SetExternalAdapterMocks(b.externalAdapterCount) if err != nil { - return te, err + return nil, err } } - - if b.hasGeth { - err = te.StartGeth() + networkConfig := networks.SelectedNetwork + var internalDockerUrls InternalDockerUrls + if b.hasGeth && networkConfig.Simulated { + networkConfig, internalDockerUrls, err = te.StartGeth() if err != nil { - return te, err + return nil, err } } + bc, err := blockchain.NewEVMClientFromNetwork(networkConfig) + if err != nil { + return nil, err + } + + te.EVMClient = bc + + cd, err := contracts.NewContractDeployer(bc) + if err != nil { + return nil, err + } + te.ContractDeployer = cd + + cl, err := contracts.NewContractLoader(bc) + if err != nil { + return nil, err + } + te.ContractLoader = cl + var nodeCsaKeys []string // Start Chainlink Nodes @@ -143,15 +171,28 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e node.WithP2Pv1(), ) } - node.SetDefaultSimulatedGeth(cfg, te.Geth.InternalWsUrl, te.Geth.InternalHttpUrl, b.hasForwarders) + //node.SetDefaultSimulatedGeth(cfg, te.Geth.InternalWsUrl, te.Geth.InternalHttpUrl, b.hasForwarders) + + var httpUrls []string + var wsUrls []string + if networkConfig.Simulated { + httpUrls = []string{internalDockerUrls.HttpUrl} + wsUrls = []string{internalDockerUrls.WsUrl} + } else { + httpUrls = networkConfig.HTTPURLs + wsUrls = networkConfig.URLs + } + + node.SetChainConfig(cfg, wsUrls, httpUrls, networkConfig, b.hasForwarders) + err := te.StartClNodes(cfg, b.clNodesCount) if err != nil { - return te, err + return nil, err } nodeCsaKeys, err = te.GetNodeCSAKeys() if err != nil { - return te, err + return nil, err } b.defaultNodeCsaKeys = nodeCsaKeys } @@ -160,7 +201,7 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e te.ParallelTransactions(true) defer te.ParallelTransactions(false) if err := te.FundChainlinkNodes(b.ETHFunds); err != nil { - return te, err + return nil, err } } diff --git a/integration-tests/load/vrfv2/vrfv2_test.go b/integration-tests/load/vrfv2/vrfv2_test.go index e414efb067f..97a455dc714 100644 --- a/integration-tests/load/vrfv2/vrfv2_test.go +++ b/integration-tests/load/vrfv2/vrfv2_test.go @@ -31,7 +31,7 @@ func TestVRFV2Load(t *testing.T) { T: t, LoadType: wasp.VU, GenName: "vu", - VU: NewJobVolumeVU(cfg.SoakVolume.Pace.Duration(), 1, env.GetAPIs(), env.Geth.EthClient, vrfv2Contracts), + VU: NewJobVolumeVU(cfg.SoakVolume.Pace.Duration(), 1, env.GetAPIs(), env.EVMClient, vrfv2Contracts), Labels: labels, LokiConfig: wasp.NewEnvLokiConfig(), } diff --git a/integration-tests/smoke/README.md b/integration-tests/smoke/README.md index f76c956e4c5..1dedc4e3840 100644 --- a/integration-tests/smoke/README.md +++ b/integration-tests/smoke/README.md @@ -51,6 +51,18 @@ Here is an example for 3 nodes cluster } ``` +### Running against Live Testnets + +``` +SELECTED_NETWORKS= \ +_KEYS= \ +_URLS= \ +_HTTP_URLS= \ +go test -v -run ${TestName} +``` + + + ### Debugging CL client API calls ``` export CL_CLIENT_DEBUG=true diff --git a/integration-tests/smoke/flux_test.go b/integration-tests/smoke/flux_test.go index fa3342c6a6e..da06fc4b57a 100644 --- a/integration-tests/smoke/flux_test.go +++ b/integration-tests/smoke/flux_test.go @@ -29,23 +29,23 @@ func TestFluxBasic(t *testing.T) { require.NoError(t, err) nodeAddresses, err := env.ChainlinkNodeAddresses() require.NoError(t, err, "Retrieving on-chain wallet addresses for chainlink nodes shouldn't fail") - env.Geth.EthClient.ParallelTransactions(true) + env.EVMClient.ParallelTransactions(true) adapterUUID := uuid.NewString() adapterPath := fmt.Sprintf("/variable-%s", adapterUUID) err = env.MockServer.Client.SetValuePath(adapterPath, 1e5) require.NoError(t, err, "Setting mockserver value path shouldn't fail") - lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) + lt, err := actions.DeployLINKToken(env.ContractDeployer) require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - fluxInstance, err := env.Geth.ContractDeployer.DeployFluxAggregatorContract(lt.Address(), contracts.DefaultFluxAggregatorOptions()) + fluxInstance, err := env.ContractDeployer.DeployFluxAggregatorContract(lt.Address(), contracts.DefaultFluxAggregatorOptions()) require.NoError(t, err, "Deploying Flux Aggregator Contract shouldn't fail") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Failed waiting for deployment of flux aggregator contract") err = lt.Transfer(fluxInstance.Address(), big.NewInt(1e18)) require.NoError(t, err, "Funding Flux Aggregator Contract shouldn't fail") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Failed waiting for funding of flux aggregator contract") err = fluxInstance.UpdateAvailableFunds() @@ -65,7 +65,7 @@ func TestFluxBasic(t *testing.T) { }) require.NoError(t, err, "Setting oracle options in the Flux Aggregator contract shouldn't fail") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") oracles, err := fluxInstance.GetOracles(context.Background()) require.NoError(t, err, "Getting oracle details from the Flux aggregator contract shouldn't fail") @@ -97,8 +97,8 @@ func TestFluxBasic(t *testing.T) { // initial value set is performed before jobs creation fluxRoundTimeout := 1 * time.Minute fluxRound := contracts.NewFluxAggregatorRoundConfirmer(fluxInstance, big.NewInt(1), fluxRoundTimeout) - env.Geth.EthClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) - err = env.Geth.EthClient.WaitForEvents() + env.EVMClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") data, err := fluxInstance.GetContractData(context.Background()) require.NoError(t, err, "Getting contract data from flux aggregator contract shouldn't fail") @@ -114,10 +114,10 @@ func TestFluxBasic(t *testing.T) { "Expected allocated funds to be %d, but found %d", int64(3), data.AllocatedFunds.Int64()) fluxRound = contracts.NewFluxAggregatorRoundConfirmer(fluxInstance, big.NewInt(2), fluxRoundTimeout) - env.Geth.EthClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) + env.EVMClient.AddHeaderEventSubscription(fluxInstance.Address(), fluxRound) err = env.MockServer.Client.SetValuePath(adapterPath, 1e10) require.NoError(t, err, "Setting value path in mock server shouldn't fail") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") data, err = fluxInstance.GetContractData(context.Background()) require.NoError(t, err, "Getting contract data from flux aggregator contract shouldn't fail") diff --git a/integration-tests/smoke/forwarder_ocr_test.go b/integration-tests/smoke/forwarder_ocr_test.go index 330885581a6..0b58be41d74 100644 --- a/integration-tests/smoke/forwarder_ocr_test.go +++ b/integration-tests/smoke/forwarder_ocr_test.go @@ -29,38 +29,38 @@ func TestForwarderOCRBasic(t *testing.T) { workerNodeAddresses, err := actions.ChainlinkNodeAddressesLocal(workerNodes) require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") - linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + linkTokenContract, err := env.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.EVMClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") operators, authorizedForwarders, _ := actions.DeployForwarderContracts( - t, env.Geth.ContractDeployer, linkTokenContract, env.Geth.EthClient, len(workerNodes), + t, env.ContractDeployer, linkTokenContract, env.EVMClient, len(workerNodes), ) for i := range workerNodes { actions.AcceptAuthorizedReceiversOperator( - t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, env.Geth.EthClient, env.Geth.ContractLoader, + t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, env.EVMClient, env.ContractLoader, ) require.NoError(t, err, "Accepting Authorize Receivers on Operator shouldn't fail") - err = actions.TrackForwarderLocal(env.Geth.EthClient, authorizedForwarders[i], workerNodes[i]) + err = actions.TrackForwarderLocal(env.EVMClient, authorizedForwarders[i], workerNodes[i]) require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() } ocrInstances, err := actions.DeployOCRContractsForwarderFlowLocal( 1, linkTokenContract, - env.Geth.ContractDeployer, + env.ContractDeployer, workerNodes, authorizedForwarders, - env.Geth.EthClient, + env.EVMClient, ) err = actions.CreateOCRJobsWithForwarderLocal(ocrInstances, bootstrapNode, workerNodes, 5, env.MockServer.Client) require.NoError(t, err, "failed to setup forwarder jobs") - err = actions.StartNewRound(1, ocrInstances, env.Geth.EthClient) + err = actions.StartNewRound(1, ocrInstances, env.EVMClient) require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") //time.Sleep(999 * time.Second) @@ -70,9 +70,9 @@ func TestForwarderOCRBasic(t *testing.T) { err = actions.SetAllAdapterResponsesToTheSameValueLocal(10, ocrInstances, workerNodes, env.MockServer.Client) require.NoError(t, err) - err = actions.StartNewRound(2, ocrInstances, env.Geth.EthClient) + err = actions.StartNewRound(2, ocrInstances, env.EVMClient) require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") answer, err = ocrInstances[0].GetLatestAnswer(context.Background()) diff --git a/integration-tests/smoke/forwarders_ocr2_test.go b/integration-tests/smoke/forwarders_ocr2_test.go index 3676072c3f4..0c184eac479 100644 --- a/integration-tests/smoke/forwarders_ocr2_test.go +++ b/integration-tests/smoke/forwarders_ocr2_test.go @@ -36,22 +36,22 @@ func TestForwarderOCR2Basic(t *testing.T) { workerNodeAddresses, err := actions.ChainlinkNodeAddressesLocal(workerNodes) require.NoError(t, err, "Retreiving on-chain wallet addresses for chainlink nodes shouldn't fail") - linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + linkTokenContract, err := env.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.EVMClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") operators, authorizedForwarders, _ := actions.DeployForwarderContracts( - t, env.Geth.ContractDeployer, linkTokenContract, env.Geth.EthClient, len(workerNodes), + t, env.ContractDeployer, linkTokenContract, env.EVMClient, len(workerNodes), ) for i := range workerNodes { - actions.AcceptAuthorizedReceiversOperator(t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, env.Geth.EthClient, env.Geth.ContractLoader) + actions.AcceptAuthorizedReceiversOperator(t, operators[i], authorizedForwarders[i], []common.Address{workerNodeAddresses[i]}, env.EVMClient, env.ContractLoader) require.NoError(t, err, "Accepting Authorized Receivers on Operator shouldn't fail") - err = actions.TrackForwarderLocal(env.Geth.EthClient, authorizedForwarders[i], workerNodes[i]) + err = actions.TrackForwarderLocal(env.EVMClient, authorizedForwarders[i], workerNodes[i]) require.NoError(t, err, "failed to track forwarders") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") } @@ -61,24 +61,24 @@ func TestForwarderOCR2Basic(t *testing.T) { transmitters = append(transmitters, forwarderCommonAddress.Hex()) } - ocrInstances, err := actions.DeployOCRv2Contracts(1, linkTokenContract, env.Geth.ContractDeployer, transmitters, env.Geth.EthClient) + ocrInstances, err := actions.DeployOCRv2Contracts(1, linkTokenContract, env.ContractDeployer, transmitters, env.EVMClient) require.NoError(t, err, "Error deploying OCRv2 contracts with forwarders") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") - err = actions.CreateOCRv2JobsLocal(ocrInstances, bootstrapNode, workerNodes, env.MockServer.Client, "ocr2", 5, env.Geth.EthClient.GetChainID().Uint64(), true) + err = actions.CreateOCRv2JobsLocal(ocrInstances, bootstrapNode, workerNodes, env.MockServer.Client, "ocr2", 5, env.EVMClient.GetChainID().Uint64(), true) require.NoError(t, err, "Error creating OCRv2 jobs with forwarders") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") ocrv2Config, err := actions.BuildMedianOCR2ConfigLocal(workerNodes) require.NoError(t, err, "Error building OCRv2 config") ocrv2Config.Transmitters = authorizedForwarders - err = actions.ConfigureOCRv2AggregatorContracts(env.Geth.EthClient, ocrv2Config, ocrInstances) + err = actions.ConfigureOCRv2AggregatorContracts(env.EVMClient, ocrv2Config, ocrInstances) require.NoError(t, err, "Error configuring OCRv2 aggregator contracts") - err = actions.StartNewOCR2Round(1, ocrInstances, env.Geth.EthClient, time.Minute*10) + err = actions.StartNewOCR2Round(1, ocrInstances, env.EVMClient, time.Minute*10) require.NoError(t, err) answer, err := ocrInstances[0].GetLatestAnswer(context.Background()) @@ -89,7 +89,7 @@ func TestForwarderOCR2Basic(t *testing.T) { ocrRoundVal := (5 + i) % 10 err = env.MockServer.Client.SetValuePath("ocr2", ocrRoundVal) require.NoError(t, err) - err = actions.StartNewOCR2Round(int64(i), ocrInstances, env.Geth.EthClient, time.Minute*10) + err = actions.StartNewOCR2Round(int64(i), ocrInstances, env.EVMClient, time.Minute*10) require.NoError(t, err) answer, err = ocrInstances[0].GetLatestAnswer(context.Background()) diff --git a/integration-tests/smoke/keeper_test.go b/integration-tests/smoke/keeper_test.go index a24c2d6c23c..00cbe07eb0f 100644 --- a/integration-tests/smoke/keeper_test.go +++ b/integration-tests/smoke/keeper_test.go @@ -1076,7 +1076,7 @@ func TestKeeperUpdateCheckData(t *testing.T) { } func setupKeeperTest(t *testing.T) ( - *blockchain.EthereumClient, + blockchain.EVMClient, []*client.ChainlinkClient, contracts.ContractDeployer, contracts.LinkToken, @@ -1101,11 +1101,11 @@ func setupKeeperTest(t *testing.T) ( env.ParallelTransactions(true) - linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + linkTokenContract, err := env.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") - return env.Geth.EthClient, env.GetAPIs(), env.Geth.ContractDeployer, linkTokenContract, env + return env.EVMClient, env.GetAPIs(), env.ContractDeployer, linkTokenContract, env } diff --git a/integration-tests/smoke/ocr2_test.go b/integration-tests/smoke/ocr2_test.go index c49b98ee36b..7dd0b23223c 100644 --- a/integration-tests/smoke/ocr2_test.go +++ b/integration-tests/smoke/ocr2_test.go @@ -41,10 +41,10 @@ func TestOCRv2Basic(t *testing.T) { nodeClients := env.GetAPIs() bootstrapNode, workerNodes := nodeClients[0], nodeClients[1:] - linkToken, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + linkToken, err := env.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.EVMClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") // Gather transmitters @@ -57,19 +57,19 @@ func TestOCRv2Basic(t *testing.T) { transmitters = append(transmitters, addr) } - aggregatorContracts, err := actions.DeployOCRv2Contracts(1, linkToken, env.Geth.ContractDeployer, transmitters, env.Geth.EthClient) + aggregatorContracts, err := actions.DeployOCRv2Contracts(1, linkToken, env.ContractDeployer, transmitters, env.EVMClient) require.NoError(t, err, "Error deploying OCRv2 aggregator contracts") - err = actions.CreateOCRv2JobsLocal(aggregatorContracts, bootstrapNode, workerNodes, env.MockServer.Client, "ocr2", 5, env.Geth.EthClient.GetChainID().Uint64(), false) + err = actions.CreateOCRv2JobsLocal(aggregatorContracts, bootstrapNode, workerNodes, env.MockServer.Client, "ocr2", 5, env.EVMClient.GetChainID().Uint64(), false) require.NoError(t, err, "Error creating OCRv2 jobs") ocrv2Config, err := actions.BuildMedianOCR2ConfigLocal(workerNodes) require.NoError(t, err, "Error building OCRv2 config") - err = actions.ConfigureOCRv2AggregatorContracts(env.Geth.EthClient, ocrv2Config, aggregatorContracts) + err = actions.ConfigureOCRv2AggregatorContracts(env.EVMClient, ocrv2Config, aggregatorContracts) require.NoError(t, err, "Error configuring OCRv2 aggregator contracts") - err = actions.StartNewOCR2Round(1, aggregatorContracts, env.Geth.EthClient, time.Minute*5) + err = actions.StartNewOCR2Round(1, aggregatorContracts, env.EVMClient, time.Minute*5) require.NoError(t, err, "Error starting new OCR2 round") roundData, err := aggregatorContracts[0].GetRound(context.Background(), big.NewInt(1)) require.NoError(t, err, "Getting latest answer from OCR contract shouldn't fail") @@ -80,7 +80,7 @@ func TestOCRv2Basic(t *testing.T) { err = env.MockServer.Client.SetValuePath("ocr2", 10) require.NoError(t, err) - err = actions.StartNewOCR2Round(2, aggregatorContracts, env.Geth.EthClient, time.Minute*5) + err = actions.StartNewOCR2Round(2, aggregatorContracts, env.EVMClient, time.Minute*5) require.NoError(t, err) roundData, err = aggregatorContracts[0].GetRound(context.Background(), big.NewInt(2)) diff --git a/integration-tests/smoke/ocr_test.go b/integration-tests/smoke/ocr_test.go index 6219e0e908d..1ae52ade305 100644 --- a/integration-tests/smoke/ocr_test.go +++ b/integration-tests/smoke/ocr_test.go @@ -24,21 +24,21 @@ func TestOCRBasic(t *testing.T) { nodeClients := env.GetAPIs() bootstrapNode, workerNodes := nodeClients[0], nodeClients[1:] - linkTokenContract, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + linkTokenContract, err := env.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - err = actions.FundChainlinkNodesLocal(workerNodes, env.Geth.EthClient, big.NewFloat(.05)) + err = actions.FundChainlinkNodesLocal(workerNodes, env.EVMClient, big.NewFloat(.05)) require.NoError(t, err, "Error funding Chainlink nodes") - ocrInstances, err := actions.DeployOCRContractsLocal(1, linkTokenContract, env.Geth.ContractDeployer, workerNodes, env.Geth.EthClient) + ocrInstances, err := actions.DeployOCRContractsLocal(1, linkTokenContract, env.ContractDeployer, workerNodes, env.EVMClient) require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Error waiting for events") err = actions.CreateOCRJobsLocal(ocrInstances, bootstrapNode, workerNodes, 5, env.MockServer.Client) require.NoError(t, err) - _ = actions.StartNewRound(1, ocrInstances, env.Geth.EthClient) + _ = actions.StartNewRound(1, ocrInstances, env.EVMClient) require.NoError(t, err) answer, err := ocrInstances[0].GetLatestAnswer(context.Background()) @@ -47,7 +47,7 @@ func TestOCRBasic(t *testing.T) { err = actions.SetAllAdapterResponsesToTheSameValueLocal(10, ocrInstances, workerNodes, env.MockServer.Client) require.NoError(t, err) - err = actions.StartNewRound(2, ocrInstances, env.Geth.EthClient) + err = actions.StartNewRound(2, ocrInstances, env.EVMClient) require.NoError(t, err) answer, err = ocrInstances[0].GetLatestAnswer(context.Background()) diff --git a/integration-tests/smoke/runlog_test.go b/integration-tests/smoke/runlog_test.go index 98e1a08af05..d40d5677fde 100644 --- a/integration-tests/smoke/runlog_test.go +++ b/integration-tests/smoke/runlog_test.go @@ -25,13 +25,13 @@ func TestRunLogBasic(t *testing.T) { Build() require.NoError(t, err) - lt, err := env.Geth.ContractDeployer.DeployLinkTokenContract() + lt, err := env.ContractDeployer.DeployLinkTokenContract() require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - oracle, err := env.Geth.ContractDeployer.DeployOracle(lt.Address()) + oracle, err := env.ContractDeployer.DeployOracle(lt.Address()) require.NoError(t, err, "Deploying Oracle Contract shouldn't fail") - consumer, err := env.Geth.ContractDeployer.DeployAPIConsumer(lt.Address()) + consumer, err := env.ContractDeployer.DeployAPIConsumer(lt.Address()) require.NoError(t, err, "Deploying Consumer Contract shouldn't fail") - err = env.Geth.EthClient.SetDefaultWallet(0) + err = env.EVMClient.SetDefaultWallet(0) require.NoError(t, err, "Setting default wallet shouldn't fail") err = lt.Transfer(consumer.Address(), big.NewInt(2e18)) require.NoError(t, err, "Transferring %d to consumer contract shouldn't fail", big.NewInt(2e18)) diff --git a/integration-tests/smoke/vrf_test.go b/integration-tests/smoke/vrf_test.go index 728e279a46f..2f3a8bb40f5 100644 --- a/integration-tests/smoke/vrf_test.go +++ b/integration-tests/smoke/vrf_test.go @@ -28,16 +28,16 @@ func TestVRFBasic(t *testing.T) { require.NoError(t, err) env.ParallelTransactions(true) - lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) + lt, err := actions.DeployLINKToken(env.ContractDeployer) require.NoError(t, err, "Deploying Link Token Contract shouldn't fail") - contracts, err := vrfv1.DeployVRFContracts(env.Geth.ContractDeployer, env.Geth.EthClient, lt) + contracts, err := vrfv1.DeployVRFContracts(env.ContractDeployer, env.EVMClient, lt) require.NoError(t, err, "Deploying VRF Contracts shouldn't fail") err = lt.Transfer(contracts.Consumer.Address(), big.NewInt(2e18)) require.NoError(t, err, "Funding consumer contract shouldn't fail") - _, err = env.Geth.ContractDeployer.DeployVRFContract() + _, err = env.ContractDeployer.DeployVRFContract() require.NoError(t, err, "Deploying VRF contract shouldn't fail") - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err, "Waiting for event subscriptions in nodes shouldn't fail") for _, n := range env.CLNodes { diff --git a/integration-tests/smoke/vrfv2_test.go b/integration-tests/smoke/vrfv2_test.go index bb54425dc0a..ed9b9f16318 100644 --- a/integration-tests/smoke/vrfv2_test.go +++ b/integration-tests/smoke/vrfv2_test.go @@ -23,21 +23,20 @@ func TestVRFv2Basic(t *testing.T) { env, err := test_env.NewCLTestEnvBuilder(). WithGeth(). - WithMockServer(1). WithCLNodes(1). WithFunding(vrfConst.ChainlinkNodeFundingAmountEth). Build() require.NoError(t, err) env.ParallelTransactions(true) - mockFeed, err := actions.DeployMockETHLinkFeed(env.Geth.ContractDeployer, vrfConst.LinkEthFeedResponse) + mockFeed, err := actions.DeployMockETHLinkFeed(env.ContractDeployer, vrfConst.LinkEthFeedResponse) require.NoError(t, err) - lt, err := actions.DeployLINKToken(env.Geth.ContractDeployer) + lt, err := actions.DeployLINKToken(env.ContractDeployer) require.NoError(t, err) - vrfv2Contracts, err := vrfv2_actions.DeployVRFV2Contracts(env.Geth.ContractDeployer, env.Geth.EthClient, lt, mockFeed) + vrfv2Contracts, err := vrfv2_actions.DeployVRFV2Contracts(env.ContractDeployer, env.EVMClient, lt, mockFeed) require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err) err = vrfv2Contracts.Coordinator.SetConfig( @@ -49,21 +48,21 @@ func TestVRFv2Basic(t *testing.T) { vrfConst.VRFCoordinatorV2FeeConfig, ) require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err) err = vrfv2Contracts.Coordinator.CreateSubscription() require.NoError(t, err) - err = env.Geth.EthClient.WaitForEvents() + err = env.EVMClient.WaitForEvents() require.NoError(t, err) err = vrfv2Contracts.Coordinator.AddConsumer(vrfConst.SubID, vrfv2Contracts.LoadTestConsumer.Address()) require.NoError(t, err) - err = vrfv2_actions.FundVRFCoordinatorV2Subscription(lt, vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.SubID, vrfConst.VRFSubscriptionFundingAmountLink) + err = vrfv2_actions.FundVRFCoordinatorV2Subscription(lt, vrfv2Contracts.Coordinator, env.EVMClient, vrfConst.SubID, vrfConst.VRFSubscriptionFundingAmountLink) require.NoError(t, err) - vrfV2jobs, err := vrfv2_actions.CreateVRFV2Jobs(env.GetAPIs(), vrfv2Contracts.Coordinator, env.Geth.EthClient, vrfConst.MinimumConfirmations) + vrfV2jobs, err := vrfv2_actions.CreateVRFV2Jobs(env.GetAPIs(), vrfv2Contracts.Coordinator, env.EVMClient, vrfConst.MinimumConfirmations) require.NoError(t, err) // this part is here because VRFv2 can work with only a specific key @@ -89,7 +88,7 @@ func TestVRFv2Basic(t *testing.T) { require.NoError(t, err) gom := gomega.NewGomegaWithT(t) - timeout := time.Minute * 1 + timeout := time.Minute * 2 var lastRequestID *big.Int gom.Eventually(func(g gomega.Gomega) { jobRuns, err := env.CLNodes[0].API.MustReadRunsByJob(vrfV2jobs[0].Job.Data.ID) diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go index e7aa0b7f74b..fc383edb9b5 100644 --- a/integration-tests/types/config/node/core.go +++ b/integration-tests/types/config/node/core.go @@ -1,6 +1,10 @@ package node import ( + "fmt" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "math/big" "net" "time" @@ -9,7 +13,6 @@ import ( evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" "github.com/smartcontractkit/chainlink/v2/core/config/toml" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" "go.uber.org/zap/zapcore" @@ -93,24 +96,38 @@ func WithP2Pv2() NodeConfigOpt { } } -func SetDefaultSimulatedGeth(cfg *chainlink.Config, ws, http string, forwarders bool) { +func SetChainConfig( + cfg *chainlink.Config, + wsUrls, + httpUrls []string, + chain blockchain.EVMNetwork, + forwarders bool, +) { if cfg.EVM == nil { + var nodes []*evmcfg.Node + for i, _ := range wsUrls { + node := evmcfg.Node{ + Name: ptr(fmt.Sprintf("node_%d_%s", i, chain.Name)), + WSURL: mustURL(wsUrls[i]), + HTTPURL: mustURL(httpUrls[i]), + SendOnly: ptr(false), + } + + nodes = append(nodes, &node) + } + var chainConfig evmcfg.Chain + if chain.Simulated { + chainConfig = evmcfg.Chain{ + AutoCreateKey: ptr(true), + FinalityDepth: ptr[uint32](1), + MinContractPayment: assets.NewLinkFromJuels(0), + } + } cfg.EVM = evmcfg.EVMConfigs{ { - ChainID: utils.NewBig(big.NewInt(1337)), - Chain: evmcfg.Chain{ - AutoCreateKey: ptr(true), - FinalityDepth: ptr[uint32](1), - MinContractPayment: assets.NewLinkFromJuels(0), - }, - Nodes: []*evmcfg.Node{ - { - Name: ptr("1337_primary_local_0"), - WSURL: mustURL(ws), - HTTPURL: mustURL(http), - SendOnly: ptr(false), - }, - }, + ChainID: utils.NewBig(big.NewInt(chain.ChainID)), + Chain: chainConfig, + Nodes: nodes, }, } if forwarders { @@ -121,37 +138,14 @@ func SetDefaultSimulatedGeth(cfg *chainlink.Config, ws, http string, forwarders } } -func WithSimulatedEVM(httpUrl, wsUrl string) NodeConfigOpt { - return func(c *chainlink.Config) { - c.EVM = evmcfg.EVMConfigs{ - { - ChainID: utils.NewBig(big.NewInt(1337)), - Chain: evmcfg.Chain{ - AutoCreateKey: ptr(true), - FinalityDepth: ptr[uint32](1), - MinContractPayment: assets.NewLinkFromJuels(0), - }, - Nodes: []*evmcfg.Node{ - { - Name: ptr("1337_primary_local_0"), - WSURL: mustURL(wsUrl), - HTTPURL: mustURL(httpUrl), - SendOnly: ptr(false), - }, - }, - }, - } - } -} - func WithVRFv2EVMEstimator(addr string) NodeConfigOpt { - est := assets.Wei(*big.NewInt(350000)) + est := assets.GWei(vrfv2_constants.MaxGasPriceGWei) return func(c *chainlink.Config) { c.EVM[0].KeySpecific = evmcfg.KeySpecificConfig{ { Key: ptr(ethkey.EIP55Address(addr)), GasEstimator: evmcfg.KeySpecificGasEstimator{ - PriceMax: ptr(est), + PriceMax: est, }, }, } From 9550be000d43a01095c995e6d01c18a250be43e0 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Tue, 15 Aug 2023 13:04:36 -0400 Subject: [PATCH 176/270] Offchain continue execution (#10195) * simplify block subscriber to only use broadcaster * add automation custom telem to job * not expose constants * addressed comments * update channel size * address comments * verify check block and log block (#10154) * verify check block and log block * fix lint issue * add some tests * add more tests * update comments * refactor * fix lint issue * make check pipeline robust * more refactoring * fix lint issues * fix tests * make simulating perform upkeeps robust * make feed lookup robust * make mercury request robust * fix tests * use select * add check upkeeps tests * add simulate perform tests --- .../ocr2/plugins/ocr2keeper/evm21/abi.go | 40 +-- .../ocr2/plugins/ocr2keeper/evm21/abi_test.go | 57 +++- .../plugins/ocr2keeper/evm21/feed_lookup.go | 171 ++++++----- .../ocr2keeper/evm21/feed_lookup_test.go | 54 ++-- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 144 +++++----- .../plugins/ocr2keeper/evm21/registry_test.go | 269 ++++++++++++++++++ 6 files changed, 559 insertions(+), 176 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go index 00468dafb57..50e80f5a482 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go @@ -36,12 +36,16 @@ const ( UpkeepFailureReasonTxHashNoLongerExists UpkeepFailureReason = 33 // pipeline execution error - NoPipelineError PipelineExecutionState = 0 - CheckBlockTooOld PipelineExecutionState = 1 - CheckBlockInvalid PipelineExecutionState = 2 - RpcFlakyFailure PipelineExecutionState = 3 - MercuryFlakyFailure PipelineExecutionState = 4 - PackUnpackFailed PipelineExecutionState = 5 + NoPipelineError PipelineExecutionState = 0 + CheckBlockTooOld PipelineExecutionState = 1 + CheckBlockInvalid PipelineExecutionState = 2 + RpcFlakyFailure PipelineExecutionState = 3 + MercuryFlakyFailure PipelineExecutionState = 4 + PackUnpackDecodeFailed PipelineExecutionState = 5 + MercuryUnmarshalError PipelineExecutionState = 6 + InvalidMercuryRequest PipelineExecutionState = 7 + FailedToReadMercuryResponse PipelineExecutionState = 8 + InvalidRevertDataInput PipelineExecutionState = 9 ) var utilsABI = types.MustGetABI(automation_utils_2_1.AutomationUtilsABI) @@ -62,19 +66,19 @@ func NewEvmRegistryPackerV2_1(abi abi.ABI, utilsAbi abi.ABI) *evmRegistryPackerV } func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, raw string) (ocr2keepers.CheckResult, error) { - var result ocr2keepers.CheckResult - b, err := hexutil.Decode(raw) if err != nil { - return result, err + // decode failed, not retryable + return getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false), fmt.Errorf("upkeepId %s failed to decode checkUpkeep result %s: %s", p.UpkeepID.String(), raw, err) } out, err := rp.abi.Methods["checkUpkeep"].Outputs.UnpackValues(b) if err != nil { - return result, fmt.Errorf("%w: unpack checkUpkeep return: %s", err, raw) + // unpack failed, not retryable + return getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false), fmt.Errorf("upkeepId %s failed to unpack checkUpkeep result %s: %s", p.UpkeepID.String(), raw, err) } - result = ocr2keepers.CheckResult{ + result := ocr2keepers.CheckResult{ Eligible: *abi.ConvertType(out[0], new(bool)).(*bool), Retryable: false, GasAllocated: uint64((*abi.ConvertType(out[4], new(*big.Int)).(**big.Int)).Int64()), @@ -96,31 +100,31 @@ func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, return result, nil } -func (rp *evmRegistryPackerV2_1) UnpackCheckCallbackResult(callbackResp []byte) (bool, []byte, uint8, *big.Int, error) { +func (rp *evmRegistryPackerV2_1) UnpackCheckCallbackResult(callbackResp []byte) (PipelineExecutionState, bool, []byte, uint8, *big.Int, error) { out, err := rp.abi.Methods["checkCallback"].Outputs.UnpackValues(callbackResp) if err != nil { - return false, nil, 0, nil, fmt.Errorf("%w: unpack checkUpkeep return: %s", err, hexutil.Encode(callbackResp)) + return PackUnpackDecodeFailed, false, nil, 0, nil, fmt.Errorf("%w: unpack checkUpkeep return: %s", err, hexutil.Encode(callbackResp)) } upkeepNeeded := *abi.ConvertType(out[0], new(bool)).(*bool) rawPerformData := *abi.ConvertType(out[1], new([]byte)).(*[]byte) failureReason := *abi.ConvertType(out[2], new(uint8)).(*uint8) gasUsed := *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) - return upkeepNeeded, rawPerformData, failureReason, gasUsed, nil + return NoPipelineError, upkeepNeeded, rawPerformData, failureReason, gasUsed, nil } -func (rp *evmRegistryPackerV2_1) UnpackPerformResult(raw string) (bool, error) { +func (rp *evmRegistryPackerV2_1) UnpackPerformResult(raw string) (PipelineExecutionState, bool, error) { b, err := hexutil.Decode(raw) if err != nil { - return false, err + return PackUnpackDecodeFailed, false, err } out, err := rp.abi.Methods["simulatePerformUpkeep"].Outputs.UnpackValues(b) if err != nil { - return false, fmt.Errorf("%w: unpack simulatePerformUpkeep return: %s", err, raw) + return PackUnpackDecodeFailed, false, err } - return *abi.ConvertType(out[0], new(bool)).(*bool), nil + return NoPipelineError, *abi.ConvertType(out[0], new(bool)).(*bool), nil } func (rp *evmRegistryPackerV2_1) UnpackUpkeepInfo(id *big.Int, raw string) (UpkeepInfo, error) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go index 942f104c95f..01c92ad4711 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go @@ -1,6 +1,7 @@ package evm import ( + "fmt" "math/big" "strings" "testing" @@ -20,24 +21,27 @@ func TestUnpackCheckResults(t *testing.T) { uid, _ := new(big.Int).SetString("1843548457736589226156809205796175506139185429616502850435279853710366065936", 10) upkeepId := ocr2keepers.UpkeepIdentifier{} upkeepId.FromBigInt(uid) - payload1, _ := core.NewUpkeepPayload(uid, ocr2keepers.NewTrigger(19447615, common.HexToHash("0x0")), []byte{}) + p1, _ := core.NewUpkeepPayload(uid, ocr2keepers.NewTrigger(19447615, common.HexToHash("0x0")), []byte{}) - payload2, _ := core.NewUpkeepPayload(uid, ocr2keepers.NewTrigger(19448272, common.HexToHash("0x0")), []byte{}) + p2, _ := core.NewUpkeepPayload(uid, ocr2keepers.NewTrigger(19448272, common.HexToHash("0x0")), []byte{}) tests := []struct { Name string Payload ocr2keepers.UpkeepPayload RawData string ExpectedResult ocr2keepers.CheckResult + ExpectedError error }{ { Name: "upkeep not needed", - Payload: payload1, + Payload: p1, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000421c000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000000", ExpectedResult: ocr2keepers.CheckResult{ UpkeepID: upkeepId, Eligible: false, IneligibilityReason: uint8(UpkeepFailureReasonUpkeepNotNeeded), + Trigger: ocr2keepers.NewLogTrigger(ocr2keepers.BlockNumber(19447615), [32]byte{}, nil), + WorkID: "e54c524132d9c8d87b7e43b76f6d769face19ffd2ff93fc24f123dd745d3ce1e", PerformData: nil, FastGasWei: big.NewInt(1000000000), LinkNative: big.NewInt(3532383906411401), @@ -45,27 +49,60 @@ func TestUnpackCheckResults(t *testing.T) { }, { Name: "target check reverted", - Payload: payload2, + Payload: p2, RawData: "0x000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c000000000000000000000000000000000000000000000000000000000000000030000000000000000000000000000000000000000000000000000000000007531000000000000000000000000000000000000000000000000000000003b9aca00000000000000000000000000000000000000000000000000000c8caf37f3b3890000000000000000000000000000000000000000000000000000000000000300000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000008914039bf676e20aad43a5642485e666575ed0d927a4b5679745e947e7d125ee2687c10000000000000000000000000000000000000000000000000000000000000060000000000000000000000000000000000000000000000000000000000000024462e8a50d00000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000001c0000000000000000000000000000000000000000000000000000000000128c1d000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000009666565644944537472000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000184554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000000000184254432d5553442d415242495452554d2d544553544e45540000000000000000000000000000000000000000000000000000000000000000000000000000000b626c6f636b4e756d6265720000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000014000000000000000000000000000000000000006400000000000000000000000000000000000000000000000000000000000000000000000000000000", ExpectedResult: ocr2keepers.CheckResult{ UpkeepID: upkeepId, Eligible: false, IneligibilityReason: uint8(UpkeepFailureReasonTargetCheckReverted), + Trigger: ocr2keepers.NewLogTrigger(ocr2keepers.BlockNumber(19448272), [32]byte{}, nil), + WorkID: "e54c524132d9c8d87b7e43b76f6d769face19ffd2ff93fc24f123dd745d3ce1e", PerformData: []byte{98, 232, 165, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 193, 208, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 68, 83, 116, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 69, 84, 72, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 24, 66, 84, 67, 45, 85, 83, 68, 45, 65, 82, 66, 73, 84, 82, 85, 77, 45, 84, 69, 83, 84, 78, 69, 84, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, FastGasWei: big.NewInt(1000000000), LinkNative: big.NewInt(3532383906411401), }, }, + { + Name: "decode failed", + Payload: p2, + RawData: "invalid_raw_data", + ExpectedResult: ocr2keepers.CheckResult{ + UpkeepID: upkeepId, + PipelineExecutionState: uint8(PackUnpackDecodeFailed), + Trigger: p2.Trigger, + WorkID: p2.WorkID, + }, + ExpectedError: fmt.Errorf("upkeepId %s failed to decode checkUpkeep result invalid_raw_data: hex string without 0x prefix", p2.UpkeepID.String()), + }, + { + Name: "unpack failed", + Payload: p2, + RawData: "0x123123", + ExpectedResult: ocr2keepers.CheckResult{ + UpkeepID: upkeepId, + PipelineExecutionState: uint8(PackUnpackDecodeFailed), + Trigger: p2.Trigger, + WorkID: p2.WorkID, + }, + ExpectedError: fmt.Errorf("upkeepId %s failed to unpack checkUpkeep result 0x123123: abi: cannot marshal in to go type: length insufficient 3 require 32", p2.UpkeepID.String()), + }, } for _, test := range tests { t.Run(test.Name, func(t *testing.T) { packer, err := newPacker() assert.NoError(t, err) rs, err := packer.UnpackCheckResult(test.Payload, test.RawData) - assert.Nil(t, err) + if test.ExpectedError != nil { + assert.Equal(t, test.ExpectedError.Error(), err.Error()) + } else { + assert.Nil(t, err) + } assert.Equal(t, test.ExpectedResult.UpkeepID, rs.UpkeepID) assert.Equal(t, test.ExpectedResult.Eligible, rs.Eligible) + assert.Equal(t, test.ExpectedResult.Trigger, rs.Trigger) + assert.Equal(t, test.ExpectedResult.WorkID, rs.WorkID) assert.Equal(t, test.ExpectedResult.IneligibilityReason, rs.IneligibilityReason) + assert.Equal(t, test.ExpectedResult.PipelineExecutionState, rs.PipelineExecutionState) }) } } @@ -74,19 +111,22 @@ func TestPacker_UnpackPerformResult(t *testing.T) { tests := []struct { Name string RawData string + State PipelineExecutionState }{ { Name: "unpack success", RawData: "0x0000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000a52d", + State: NoPipelineError, }, } for _, test := range tests { t.Run(test.Name, func(t *testing.T) { packer, err := newPacker() assert.NoError(t, err) - rs, err := packer.UnpackPerformResult(test.RawData) + state, rs, err := packer.UnpackPerformResult(test.RawData) assert.Nil(t, err) assert.True(t, rs) + assert.Equal(t, test.State, state) }) } } @@ -100,6 +140,7 @@ func TestPacker_UnpackCheckCallbackResult(t *testing.T) { FailureReason uint8 GasUsed *big.Int ErrorString string + State PipelineExecutionState }{ { Name: "unpack upkeep needed", @@ -123,6 +164,7 @@ func TestPacker_UnpackCheckCallbackResult(t *testing.T) { UpkeepNeeded: false, PerformData: nil, ErrorString: "abi: improperly encoded boolean value: unpack checkUpkeep return: ", + State: PackUnpackDecodeFailed, }, } for _, test := range tests { @@ -130,7 +172,7 @@ func TestPacker_UnpackCheckCallbackResult(t *testing.T) { packer, err := newPacker() assert.NoError(t, err) - needed, pd, failureReason, gasUsed, err := packer.UnpackCheckCallbackResult(test.CallbackResp) + state, needed, pd, failureReason, gasUsed, err := packer.UnpackCheckCallbackResult(test.CallbackResp) if test.ErrorString != "" { assert.EqualError(t, err, test.ErrorString+hexutil.Encode(test.CallbackResp)) @@ -141,6 +183,7 @@ func TestPacker_UnpackCheckCallbackResult(t *testing.T) { assert.Equal(t, test.PerformData, pd) assert.Equal(t, test.FailureReason, failureReason) assert.Equal(t, test.GasUsed, gasUsed) + assert.Equal(t, test.State, state) }) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index aedb3523edf..2bba9b9106e 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -58,11 +58,12 @@ type MercuryResponse struct { ChainlinkBlob string `json:"chainlinkBlob"` } -type MercuryBytes struct { +type MercuryData struct { Index int Error error Retryable bool Bytes []byte + State PipelineExecutionState } // AdminOffchainConfig represents the administrative offchain config for each upkeep. It can be set by s_upkeepManager @@ -72,10 +73,9 @@ type AdminOffchainConfig struct { } // feedLookup looks through check upkeep results looking for any that need off chain lookup -func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keepers.CheckResult) ([]ocr2keepers.CheckResult, error) { +func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers.CheckResult) []ocr2keepers.CheckResult { lookups := map[int]*FeedLookup{} - for i := range upkeepResults { - res := &upkeepResults[i] + for i, res := range checkResults { if res.IneligibilityReason != uint8(UpkeepFailureReasonTargetCheckReverted) { continue } @@ -83,28 +83,28 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper block := big.NewInt(int64(res.Trigger.BlockNumber)) upkeepId := res.UpkeepID - opts, err := r.buildCallOpts(ctx, block) - if err != nil { - r.lggr.Errorf("[FeedLookup] upkeep %s block %d buildCallOpts: %v", upkeepId, block, err) - return nil, err - } + opts := r.buildCallOpts(ctx, block) - allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) + state, retryable, allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) if err != nil { - r.lggr.Errorf("[FeedLookup] upkeep %s block %d failed to time mercury allow list: %v", upkeepId, block, err) + r.lggr.Warnf("[FeedLookup] upkeep %s block %d failed to query mercury allow list: %s", upkeepId, block, err) + checkResults[i].PipelineExecutionState = uint8(state) + checkResults[i].Retryable = retryable continue } if !allowed { - res.IneligibilityReason = uint8(UpkeepFailureReasonMercuryAccessNotAllowed) - r.lggr.Errorf("[FeedLookup] upkeep %s block %d NOT allowed to time Mercury server", upkeepId, block) + r.lggr.Warnf("[FeedLookup] upkeep %s block %d NOT allowed to query Mercury server", upkeepId, block) + checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryAccessNotAllowed) + checkResults[i].Retryable = retryable continue } - r.lggr.Infof("[FeedLookup] upkeep %s block %d decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(upkeepResults[i].PerformData)) - lookup, err := r.decodeFeedLookup(res.PerformData) + r.lggr.Infof("[FeedLookup] upkeep %s block %d decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(checkResults[i].PerformData)) + state, lookup, err := r.decodeFeedLookup(res.PerformData) if err != nil { - r.lggr.Errorf("[FeedLookup] upkeep %s block %d decodeFeedLookup: %v", upkeepId, block, err) + r.lggr.Warnf("[FeedLookup] upkeep %s block %d decodeFeedLookup: %v", upkeepId, block, err) + checkResults[i].PipelineExecutionState = uint8(state) continue } lookup.upkeepId = upkeepId.BigInt() @@ -118,90 +118,94 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, upkeepResults []ocr2keeper var wg sync.WaitGroup for i, lookup := range lookups { wg.Add(1) - go r.doLookup(ctx, &wg, lookup, i, upkeepResults) + go r.doLookup(ctx, &wg, lookup, i, checkResults) } wg.Wait() // don't surface error to plugin bc FeedLookup process should be self-contained. - return upkeepResults, nil + return checkResults } -func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup *FeedLookup, i int, upkeepResults []ocr2keepers.CheckResult) { +func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup *FeedLookup, i int, checkResults []ocr2keepers.CheckResult) { defer wg.Done() - values, retryable, err := r.doMercuryRequest(ctx, lookup) + state, values, retryable, err := r.doMercuryRequest(ctx, lookup) if err != nil { r.lggr.Errorf("[FeedLookup] upkeep %s retryable %v doMercuryRequest: %v", lookup.upkeepId, retryable, err) - upkeepResults[i].Retryable = retryable + checkResults[i].Retryable = retryable + checkResults[i].PipelineExecutionState = uint8(state) return } for j, v := range values { r.lggr.Infof("[FeedLookup] checkCallback values[%d]=%s", j, hexutil.Encode(v)) } - mercuryBytes, err := r.checkCallback(ctx, values, lookup) + state, retryable, mercuryBytes, err := r.checkCallback(ctx, values, lookup) if err != nil { r.lggr.Errorf("[FeedLookup] upkeep %s block %d checkCallback err: %v", lookup.upkeepId, lookup.block, err) + checkResults[i].Retryable = retryable + checkResults[i].PipelineExecutionState = uint8(state) return } r.lggr.Infof("[FeedLookup] checkCallback mercuryBytes=%s", hexutil.Encode(mercuryBytes)) - needed, performData, failureReason, _, err := r.packer.UnpackCheckCallbackResult(mercuryBytes) + state, needed, performData, failureReason, _, err := r.packer.UnpackCheckCallbackResult(mercuryBytes) if err != nil { r.lggr.Errorf("[FeedLookup] upkeep %s block %d UnpackCheckCallbackResult err: %v", lookup.upkeepId, lookup.block, err) + checkResults[i].PipelineExecutionState = uint8(state) return } if failureReason == uint8(UpkeepFailureReasonMercuryCallbackReverted) { - upkeepResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryCallbackReverted) + checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryCallbackReverted) r.lggr.Debugf("[FeedLookup] upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) return } if !needed { - upkeepResults[i].IneligibilityReason = uint8(UpkeepFailureReasonUpkeepNotNeeded) + checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonUpkeepNotNeeded) r.lggr.Debugf("[FeedLookup] upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) return } - upkeepResults[i].IneligibilityReason = uint8(UpkeepFailureReasonNone) - upkeepResults[i].Eligible = true - upkeepResults[i].PerformData = performData + checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonNone) + checkResults[i].Eligible = true + checkResults[i].PerformData = performData r.lggr.Infof("[FeedLookup] upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) } // allowedToUseMercury retrieves upkeep's administrative offchain config and decode a mercuryEnabled bool to indicate if // this upkeep is allowed to use Mercury service. -func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (bool, error) { +func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (state PipelineExecutionState, retryable bool, allow bool, err error) { allowed, ok := r.mercury.allowListCache.Get(upkeepId.String()) if ok { - return allowed.(bool), nil + return NoPipelineError, false, allowed.(bool), nil } cfg, err := r.registry.GetUpkeepPrivilegeConfig(opts, upkeepId) if err != nil { - return false, fmt.Errorf("failed to get upkeep privilege config for upkeep ID %s: %v", upkeepId, err) + return RpcFlakyFailure, true, false, fmt.Errorf("failed to get upkeep privilege config for upkeep ID %s: %v", upkeepId, err) } var a AdminOffchainConfig err = json.Unmarshal(cfg, &a) if err != nil { - return false, fmt.Errorf("failed to unmarshal privilege config for upkeep ID %s: %v", upkeepId, err) + return MercuryUnmarshalError, false, false, fmt.Errorf("failed to unmarshal privilege config for upkeep ID %s: %v", upkeepId, err) } r.mercury.allowListCache.Set(upkeepId.String(), a.MercuryEnabled, cache.DefaultExpiration) - return a.MercuryEnabled, nil + return NoPipelineError, false, a.MercuryEnabled, nil } // decodeFeedLookup decodes the revert error FeedLookup(string feedParamKey, string[] feeds, string feedParamKey, uint256 time, byte[] extraData) -func (r *EvmRegistry) decodeFeedLookup(data []byte) (*FeedLookup, error) { +func (r *EvmRegistry) decodeFeedLookup(data []byte) (PipelineExecutionState, *FeedLookup, error) { e := r.mercury.abi.Errors["FeedLookup"] unpack, err := e.Unpack(data) if err != nil { - return nil, fmt.Errorf("unpack error: %w", err) + return PackUnpackDecodeFailed, nil, fmt.Errorf("unpack error: %w", err) } errorParameters := unpack.([]interface{}) - return &FeedLookup{ + return NoPipelineError, &FeedLookup{ feedParamKey: *abi.ConvertType(errorParameters[0], new(string)).(*string), feeds: *abi.ConvertType(errorParameters[1], new([]string)).(*[]string), timeParamKey: *abi.ConvertType(errorParameters[2], new(string)).(*string), @@ -210,10 +214,10 @@ func (r *EvmRegistry) decodeFeedLookup(data []byte) (*FeedLookup, error) { }, nil } -func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup *FeedLookup) (hexutil.Bytes, error) { +func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup *FeedLookup) (PipelineExecutionState, bool, hexutil.Bytes, error) { payload, err := r.abi.Pack("checkCallback", lookup.upkeepId, values, lookup.extraData) if err != nil { - return nil, err + return PackUnpackDecodeFailed, false, nil, err } var b hexutil.Bytes @@ -225,16 +229,15 @@ func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup // call checkCallback function at the block which OCR3 has agreed upon err = r.client.CallContext(ctx, &b, "eth_call", args, hexutil.EncodeUint64(lookup.block)) if err != nil { - return nil, err + return RpcFlakyFailure, true, nil, err } - return b, nil + return NoPipelineError, false, b, nil } // doMercuryRequest sends requests to Mercury API to retrieve ChainlinkBlob. -func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup) ([][]byte, bool, error) { - // TODO (AUTO-3253): if no feed labels are provided in v0.3, request for all feeds +func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup) (PipelineExecutionState, [][]byte, bool, error) { resultLen := len(ml.feeds) - ch := make(chan MercuryBytes, resultLen) + ch := make(chan MercuryData, resultLen) if ml.feedParamKey == FeedIdHex && ml.timeParamKey == BlockNumber { // only mercury v0.2 for i := range ml.feeds { @@ -247,37 +250,41 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup) ([][ } else { // create a new channel with buffer size 1 since the batch endpoint will only return 1 blob resultLen = 1 - ch = make(chan MercuryBytes, resultLen) + ch = make(chan MercuryData, resultLen) go r.multiFeedsRequest(ctx, ch, ml) } } else { - return nil, false, fmt.Errorf("invalid label combination: feed param key %s and time param key %s", ml.feedParamKey, ml.timeParamKey) + return InvalidRevertDataInput, nil, false, fmt.Errorf("invalid label combination: feed param key %s and time param key %s", ml.feedParamKey, ml.timeParamKey) } var reqErr error results := make([][]byte, len(ml.feeds)) retryable := true allSuccess := true + // use the last execution error as the state, if no execution errors, state will be no error + state := NoPipelineError for i := 0; i < len(results); i++ { m := <-ch if m.Error != nil { reqErr = errors.Join(reqErr, m.Error) retryable = retryable && m.Retryable allSuccess = false + if m.State != NoPipelineError { + state = m.State + } } results[m.Index] = m.Bytes } r.lggr.Debugf("FeedLookup upkeep %s retryable %s reqErr %w", ml.upkeepId.String(), retryable && !allSuccess, reqErr) // only retry when not all successful AND none are not retryable - return results, retryable && !allSuccess, reqErr + return state, results, retryable && !allSuccess, reqErr } // singleFeedRequest sends a Mercury request for a single feed report. -func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBytes, index int, ml *FeedLookup, mv MercuryVersion) { +func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryData, index int, ml *FeedLookup, mv MercuryVersion) { q := url.Values{ ml.feedParamKey: {ml.feeds[index]}, ml.timeParamKey: {ml.time.String()}, - UserId: {ml.upkeepId.String()}, } mercuryURL := r.mercury.cred.URL path := MercuryPathV2 @@ -289,7 +296,7 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy req, err := http.NewRequestWithContext(ctx, http.MethodGet, reqUrl, nil) if err != nil { - ch <- MercuryBytes{Index: index, Error: err} + ch <- MercuryData{Index: index, Error: err, Retryable: false, State: InvalidMercuryRequest} return } @@ -300,26 +307,36 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy req.Header.Set("X-Authorization-Timestamp", strconv.FormatInt(ts, 10)) req.Header.Set("X-Authorization-Signature-SHA256", signature) + // in the case of multiple retries here, use the last attempt's data + state := NoPipelineError retryable := false + sent := false retryErr := retry.Do( func() error { retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { r.lggr.Warnf("FeedLookup upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + retryable = true + state = MercuryFlakyFailure return err1 } defer resp.Body.Close() body, err1 := io.ReadAll(resp.Body) if err1 != nil { + retryable = false + state = FailedToReadMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { r.lggr.Warnf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) retryable = true + state = MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { + retryable = false + state = InvalidMercuryRequest return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) } @@ -327,14 +344,24 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy err1 = json.Unmarshal(body, &m) if err1 != nil { r.lggr.Warnf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + retryable = false + state = MercuryUnmarshalError return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { r.lggr.Warnf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) + retryable = false + state = FailedToReadMercuryResponse return err1 } - ch <- MercuryBytes{Index: index, Bytes: blobBytes} + ch <- MercuryData{ + Index: index, + Bytes: blobBytes, + Retryable: false, + State: NoPipelineError, + } + sent = true return nil }, // only retry when the error is 404 Not Found or 500 Internal Server Error @@ -345,23 +372,22 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryBy retry.Delay(RetryDelay), retry.Attempts(TotalAttempt)) - // if all retries fail, return the error and ask the caller to handle cool down and heavyweight retry - if retryErr != nil { - mb := MercuryBytes{ + if !sent { + md := MercuryData{ Index: index, Retryable: retryable, Error: retryErr, + State: state, } - ch <- mb + ch <- md } } // multiFeedsRequest sends a Mercury request for a multi-feed report -func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBytes, ml *FeedLookup) { +func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryData, ml *FeedLookup) { q := url.Values{ FeedId: {strings.Join(ml.feeds, ",")}, Timestamp: {ml.time.String()}, - UserId: {ml.upkeepId.String()}, } reqUrl := fmt.Sprintf("%s%s%s", r.mercury.cred.URL, MercuryBatchPathV3, q.Encode()) @@ -369,7 +395,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy req, err := http.NewRequestWithContext(ctx, http.MethodGet, reqUrl, nil) if err != nil { - ch <- MercuryBytes{Index: 0, Error: err} + ch <- MercuryData{Index: 0, Error: err, Retryable: false, State: InvalidMercuryRequest} return } @@ -380,26 +406,36 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy req.Header.Set("X-Authorization-Timestamp", strconv.FormatInt(ts, 10)) req.Header.Set("X-Authorization-Signature-SHA256", signature) + // in the case of multiple retries here, use the last attempt's data + state := NoPipelineError retryable := false + sent := false retryErr := retry.Do( func() error { retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { r.lggr.Warnf("FeedLookup upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + retryable = true + state = MercuryFlakyFailure return err1 } defer resp.Body.Close() body, err1 := io.ReadAll(resp.Body) if err1 != nil { + retryable = false + state = FailedToReadMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { r.lggr.Warnf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) retryable = true + state = MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { + retryable = false + state = InvalidMercuryRequest return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) } @@ -407,17 +443,24 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy err1 = json.Unmarshal(body, &m) if err1 != nil { r.lggr.Warnf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + retryable = false + state = MercuryUnmarshalError return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { r.lggr.Warnf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, err1) + retryable = false + state = FailedToReadMercuryResponse return err1 } - ch <- MercuryBytes{ - Index: 0, - Bytes: blobBytes, + ch <- MercuryData{ + Index: 0, + Bytes: blobBytes, + Retryable: false, + State: NoPipelineError, } + sent = true return nil }, // only retry when the error is 404 Not Found or 500 Internal Server Error @@ -428,14 +471,14 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryBy retry.Delay(RetryDelay), retry.Attempts(TotalAttempt)) - // if all retries fail, return the error and ask the caller to handle cool down and heavyweight retry - if retryErr != nil { - mb := MercuryBytes{ + if !sent { + md := MercuryData{ Index: 0, Retryable: retryable, Error: retryErr, + State: state, } - ch <- mb + ch <- md } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index f8cdc4dcd2f..dabf33da9e3 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -11,7 +11,6 @@ import ( "strings" "testing" - "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" @@ -85,7 +84,6 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { blob string callbackResp []byte expectedResults []ocr2keepers.CheckResult - wantErr error callbackNeeded bool extraData []byte checkCallbackResp []byte @@ -220,13 +218,8 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { r.client = client } - got, err := r.feedLookup(context.Background(), tt.input) - if tt.wantErr != nil { - assert.Equal(t, tt.wantErr.Error(), err.Error(), tt.name) - assert.NotNil(t, err, tt.name) - } else { - assert.Equal(t, tt.expectedResults, got, tt.name) - } + got := r.feedLookup(context.Background(), tt.input) + assert.Equal(t, tt.expectedResults, got, tt.name) }) } } @@ -236,11 +229,13 @@ func TestEvmRegistry_DecodeFeedLookup(t *testing.T) { name string data []byte expected *FeedLookup + state PipelineExecutionState err error }{ { - name: "success - decode to feed lookup", - data: []byte{125, 221, 147, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 138, 215, 253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 100, 72, 101, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 53, 53, 52, 52, 56, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 50, 53, 52, 52, 51, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + name: "success - decode to feed lookup", + data: []byte{125, 221, 147, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 138, 215, 253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 100, 72, 101, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 53, 53, 52, 52, 56, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 50, 53, 52, 52, 51, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, + state: NoPipelineError, expected: &FeedLookup{ feedParamKey: FeedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, @@ -250,17 +245,19 @@ func TestEvmRegistry_DecodeFeedLookup(t *testing.T) { }, }, { - name: "failure - unpack error", - data: []byte{1, 2, 3, 4}, - err: errors.New("unpack error: invalid data for unpacking"), + name: "failure - unpack error", + data: []byte{1, 2, 3, 4}, + err: errors.New("unpack error: invalid data for unpacking"), + state: PackUnpackDecodeFailed, }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { r := setupEVMRegistry(t) - fl, err := r.decodeFeedLookup(tt.data) + state, fl, err := r.decodeFeedLookup(tt.data) assert.Equal(t, tt.expected, fl) + assert.Equal(t, tt.state, state) if tt.err != nil { assert.Equal(t, tt.err.Error(), err.Error()) } @@ -276,6 +273,8 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { cached bool allowed bool errorMessage string + state PipelineExecutionState + retryable bool }{ { name: "success - allowed via cache", @@ -301,6 +300,7 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { name: "failure - cannot unmarshal privilege config", cached: false, errorMessage: "failed to unmarshal privilege config for upkeep ID 71022726777042968814359024671382968091267501884371696415772139504780367423725: invalid character '\\x00' looking for beginning of value", + state: MercuryUnmarshalError, }, } @@ -325,7 +325,7 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { } } - allowed, err := r.allowedToUseMercury(nil, upkeepId) + state, retryable, allowed, err := r.allowedToUseMercury(nil, upkeepId) if tt.errorMessage != "" { assert.NotNil(t, err) assert.Equal(t, tt.errorMessage, err.Error()) @@ -333,6 +333,8 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { assert.Nil(t, err) assert.Equal(t, tt.allowed, allowed) } + assert.Equal(t, tt.state, state) + assert.Equal(t, tt.retryable, retryable) }) } } @@ -349,6 +351,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedValues [][]byte expectedRetryable bool expectedError error + state PipelineExecutionState }{ { name: "success", @@ -381,6 +384,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedValues: [][]byte{nil}, expectedRetryable: true, expectedError: errors.New("All attempts fail:\n#1: 500\n#2: 500\n#3: 500"), + state: MercuryFlakyFailure, }, { name: "failure - not retryable", @@ -397,6 +401,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedValues: [][]byte{nil}, expectedRetryable: false, expectedError: errors.New("All attempts fail:\n#1: FeedLookup upkeep 88786950015966611018675766524283132478093844178961698330929478019253453382042 block 25880526 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"), + state: InvalidMercuryRequest, }, } @@ -422,9 +427,10 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { } r.hc = hc - values, retryable, reqErr := r.doMercuryRequest(context.Background(), tt.lookup) + state, values, retryable, reqErr := r.doMercuryRequest(context.Background(), tt.lookup) assert.Equal(t, tt.expectedValues, values) assert.Equal(t, tt.expectedRetryable, retryable) + assert.Equal(t, tt.state, state) if tt.expectedError != nil { assert.Equal(t, tt.expectedError.Error(), reqErr.Error()) } @@ -586,7 +592,7 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { } r.hc = hc - ch := make(chan MercuryBytes, 1) + ch := make(chan MercuryData, 1) r.singleFeedRequest(context.Background(), ch, tt.index, tt.lookup, tt.mv) m := <-ch @@ -745,7 +751,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { } r.hc = hc - ch := make(chan MercuryBytes, 1) + ch := make(chan MercuryData, 1) r.multiFeedsRequest(context.Background(), ch, tt.lookup) m := <-ch @@ -775,13 +781,15 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { values [][]byte statusCode int - callbackMsg ethereum.CallMsg callbackResp []byte callbackErr error upkeepNeeded bool performData []byte wantErr assert.ErrorAssertionFunc + + state PipelineExecutionState + retryable bool }{ { name: "success - empty extra data", @@ -836,6 +844,8 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { callbackResp: []byte{}, callbackErr: errors.New("bad response"), wantErr: assert.Error, + state: RpcFlakyFailure, + retryable: true, }, } @@ -856,8 +866,10 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { }).Once() r.client = client - _, err = r.checkCallback(context.Background(), tt.values, tt.lookup) + state, retryable, _, err := r.checkCallback(context.Background(), tt.values, tt.lookup) tt.wantErr(t, err, fmt.Sprintf("Error asserion failed: %v", tt.name)) + assert.Equal(t, tt.state, state) + assert.Equal(t, tt.retryable, retryable) }) } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 959d80e924a..0d8ef509d81 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -574,10 +574,9 @@ func (r *EvmRegistry) addToActive(id *big.Int, force bool) { } } -func (r *EvmRegistry) buildCallOpts(ctx context.Context, block *big.Int) (*bind.CallOpts, error) { +func (r *EvmRegistry) buildCallOpts(ctx context.Context, block *big.Int) *bind.CallOpts { opts := bind.CallOpts{ - Context: ctx, - BlockNumber: nil, + Context: ctx, } if block == nil || block.Int64() == 0 { @@ -589,14 +588,11 @@ func (r *EvmRegistry) buildCallOpts(ctx context.Context, block *big.Int) (*bind. opts.BlockNumber = block } - return &opts, nil + return &opts } func (r *EvmRegistry) getLatestIDsFromContract(ctx context.Context) ([]*big.Int, error) { - opts, err := r.buildCallOpts(ctx, nil) - if err != nil { - return nil, err - } + opts := r.buildCallOpts(ctx, nil) state, err := r.registry.GetState(opts) if err != nil { @@ -641,13 +637,7 @@ func (r *EvmRegistry) doCheck(ctx context.Context, keys []ocr2keepers.UpkeepPayl return } - upkeepResults, err = r.feedLookup(ctx, upkeepResults) - if err != nil { - chResult <- checkResult{ - err: err, - } - return - } + upkeepResults = r.feedLookup(ctx, upkeepResults) upkeepResults, err = r.simulatePerformUpkeeps(ctx, upkeepResults) if err != nil { @@ -668,53 +658,59 @@ func (r *EvmRegistry) getBlockAndUpkeepId(upkeepID ocr2keepers.UpkeepIdentifier, return block, common.BytesToHash(trigger.BlockHash[:]), upkeepID.BigInt() } -// TODO (AUTO-2013): Have better error handling to not return nil results in case of partial errors func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { var ( - checkReqs = make([]rpc.BatchElem, len(payloads)) - checkResults = make([]*string, len(payloads)) + checkReqs []rpc.BatchElem + checkResults []*string results = make([]ocr2keepers.CheckResult, len(payloads)) ) + indices := map[int]int{} for i, p := range payloads { block, checkHash, upkeepId := r.getBlockAndUpkeepId(p.UpkeepID, p.Trigger) state, retryable := r.verifyCheckBlock(ctx, block, upkeepId, checkHash) if state != NoPipelineError { - results[i] = r.getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, state, retryable) + results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, state, retryable) continue } - opts, err := r.buildCallOpts(ctx, block) - if err != nil { - return nil, err - } + opts := r.buildCallOpts(ctx, block) var payload []byte + var err error uid := &ocr2keepers.UpkeepIdentifier{} uid.FromBigInt(upkeepId) switch core.GetUpkeepType(*uid) { case ocr2keepers.LogTrigger: reason, state, retryable := r.verifyLogExists(upkeepId, p) if reason != UpkeepFailureReasonNone || state != NoPipelineError { - results[i] = r.getIneligibleCheckResultWithoutPerformData(p, reason, state, retryable) + results[i] = getIneligibleCheckResultWithoutPerformData(p, reason, state, retryable) continue } // check data will include the log trigger config payload, err = r.abi.Pack("checkUpkeep", upkeepId, p.CheckData) if err != nil { - return nil, err + // pack error, no retryable + r.lggr.Warnf("failed to pack log trigger checkUpkeep data for upkeepId %s with check data %s: %s", upkeepId, hexutil.Encode(p.CheckData), err) + results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false) + continue } default: // checkUpkeep is overloaded on the contract for conditionals and log upkeeps // Need to use the first function (checkUpkeep0) for conditionals payload, err = r.abi.Pack("checkUpkeep0", upkeepId) if err != nil { - return nil, err + // pack error, no retryable + r.lggr.Warnf("failed to pack conditional checkUpkeep data for upkeepId %s with check data %s: %s", upkeepId, hexutil.Encode(p.CheckData), err) + results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false) + continue } } + indices[len(checkReqs)] = i + results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, NoPipelineError, false) var result string - checkReqs[i] = rpc.BatchElem{ + checkReqs = append(checkReqs, rpc.BatchElem{ Method: "eth_call", Args: []interface{}{ map[string]interface{}{ @@ -724,34 +720,41 @@ func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.U hexutil.EncodeBig(opts.BlockNumber), }, Result: &result, - } + }) - checkResults[i] = &result + checkResults = append(checkResults, &result) } - if err := r.client.BatchCallContext(ctx, checkReqs); err != nil { - return nil, err + if len(checkResults) > 0 { + // In contrast to CallContext, BatchCallContext only returns errors that have occurred + // while sending the request. Any error specific to a request is reported through the + // Error field of the corresponding BatchElem. + // hence, if BatchCallContext returns an error, it will be an error which will terminate the pipeline + if err := r.client.BatchCallContext(ctx, checkReqs); err != nil { + r.lggr.Errorf("failed to batch call for checkUpkeeps: %s", err) + return nil, err + } } - var multiErr error - for i, req := range checkReqs { + index := indices[i] if req.Error != nil { - r.lggr.Debugf("error encountered for key %s with message '%s' in check", payloads[i], req.Error) - multierr.AppendInto(&multiErr, req.Error) + // individual upkeep failed in a batch call, retryable + r.lggr.Warnf("error encountered in check result for upkeepId %s: %s", results[index].UpkeepID.String(), req.Error) + results[index].Retryable = true + results[index].PipelineExecutionState = uint8(RpcFlakyFailure) } else { var err error - results[i], err = r.packer.UnpackCheckResult(payloads[i], *checkResults[i]) + results[index], err = r.packer.UnpackCheckResult(payloads[index], *checkResults[i]) if err != nil { - return nil, errors.Wrap(err, "failed to unpack check result") + r.lggr.Warnf("failed to unpack check result: %s", err) } } } - return results, multiErr + return results, nil } -// TODO (AUTO-2013): Have better error handling to not return nil results in case of partial errors func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults []ocr2keepers.CheckResult) ([]ocr2keepers.CheckResult, error) { var ( performReqs = make([]rpc.BatchElem, 0, len(checkResults)) @@ -766,15 +769,16 @@ func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults [ block, _, upkeepId := r.getBlockAndUpkeepId(cr.UpkeepID, cr.Trigger) - opts, err := r.buildCallOpts(ctx, block) - if err != nil { - return nil, err - } + opts := r.buildCallOpts(ctx, block) // Since checkUpkeep is true, simulate perform upkeep to ensure it doesn't revert payload, err := r.abi.Pack("simulatePerformUpkeep", upkeepId, cr.PerformData) if err != nil { - return nil, err + // pack failed, not retryable + r.lggr.Warnf("failed to pack perform data %s for %s: %s", hexutil.Encode(cr.PerformData), upkeepId, err) + checkResults[i].Eligible = false + checkResults[i].PipelineExecutionState = uint8(PackUnpackDecodeFailed) + continue } var result string @@ -796,28 +800,39 @@ func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults [ if len(performReqs) > 0 { if err := r.client.BatchCallContext(ctx, performReqs); err != nil { + r.lggr.Errorf("failed to batch call for simulatePerformUpkeeps: %s", err) return nil, err } } - var multiErr error for i, req := range performReqs { + idx := performToKeyIdx[i] if req.Error != nil { - r.lggr.Debugf("error encountered for key %d|%s with message '%s' in simulate perform", checkResults[i].Trigger.BlockNumber, checkResults[i].UpkeepID.BigInt(), req.Error) - multierr.AppendInto(&multiErr, req.Error) - } else { - simulatePerformSuccess, err := r.packer.UnpackPerformResult(*performResults[i]) - if err != nil { - return nil, err - } + // individual upkeep failed in a batch call, retryable + r.lggr.Warnf("failed to simulate upkeepId %s: %s", checkResults[idx].UpkeepID.String(), req.Error) + checkResults[idx].Retryable = true + checkResults[idx].Eligible = false + checkResults[idx].PipelineExecutionState = uint8(RpcFlakyFailure) + continue + } - if !simulatePerformSuccess { - checkResults[performToKeyIdx[i]].Eligible = false - } + state, simulatePerformSuccess, err := r.packer.UnpackPerformResult(*performResults[i]) + if err != nil { + // unpack failed, not retryable + r.lggr.Warnf("failed to unpack simulate performUpkeep result for upkeepId %s for state %d: %s", checkResults[idx].UpkeepID.String(), state, req.Error) + checkResults[idx].Retryable = false + checkResults[idx].Eligible = false + checkResults[idx].PipelineExecutionState = uint8(state) + continue + } + + if !simulatePerformSuccess { + r.lggr.Warnf("upkeepId %s is not eligible after simulation", checkResults[idx].UpkeepID.String()) + checkResults[performToKeyIdx[i]].Eligible = false } } - return checkResults, multiErr + return checkResults, nil } // TODO (AUTO-2013): Have better error handling to not return nil results in case of partial errors @@ -832,10 +847,7 @@ func (r *EvmRegistry) getUpkeepConfigs(ctx context.Context, ids []*big.Int) ([]a ) for i, id := range ids { - opts, err := r.buildCallOpts(ctx, nil) - if err != nil { - return nil, fmt.Errorf("failed to get call opts: %s", err) - } + opts := r.buildCallOpts(ctx, nil) payload, err := r.abi.Pack("getUpkeep", id) if err != nil { @@ -914,11 +926,7 @@ func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { // updateTriggerConfig gets invoked upon changes in the trigger config of an upkeep. func (r *EvmRegistry) fetchTriggerConfig(id *big.Int) ([]byte, error) { - opts, err := r.buildCallOpts(r.ctx, nil) - if err != nil { - r.lggr.Warnw("failed to build opts for tx", "err", err) - return nil, err - } + opts := r.buildCallOpts(r.ctx, nil) cfg, err := r.registry.GetUpkeepTriggerConfig(opts, id) if err != nil { r.lggr.Warnw("failed to get trigger config", "err", err) @@ -947,7 +955,7 @@ func (r *EvmRegistry) getTxBlock(txHash common.Hash) (*big.Int, common.Hash, err } // getIneligibleCheckResultWithoutPerformData returns an ineligible check result with ineligibility reason and pipeline execution state but without perform data -func (r *EvmRegistry) getIneligibleCheckResultWithoutPerformData(p ocr2keepers.UpkeepPayload, reason UpkeepFailureReason, state PipelineExecutionState, retryable bool) ocr2keepers.CheckResult { +func getIneligibleCheckResultWithoutPerformData(p ocr2keepers.UpkeepPayload, reason UpkeepFailureReason, state PipelineExecutionState, retryable bool) ocr2keepers.CheckResult { return ocr2keepers.CheckResult{ IneligibilityReason: uint8(reason), PipelineExecutionState: uint8(state), @@ -1007,6 +1015,10 @@ func (r *EvmRegistry) verifyLogExists(upkeepId *big.Int, p ocr2keepers.UpkeepPay // query eth client as a fallback bn, _, err := r.getTxBlock(p.Trigger.LogTriggerExtension.TxHash) if err != nil { + // primitive way of checking errors + if strings.Contains(err.Error(), "missing required field") || strings.Contains(err.Error(), "not found") { + return UpkeepFailureReasonTxHashNoLongerExists, NoPipelineError, false + } r.lggr.Warnf("failed to query tx hash %s for upkeepId %s: %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId, err.Error()) return UpkeepFailureReasonNone, RpcFlakyFailure, true } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go index a8f24f9ee09..57ab7dcc114 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go @@ -10,6 +10,8 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/rpc" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" @@ -577,3 +579,270 @@ func TestRegistry_VerifyLogExists(t *testing.T) { }) } } + +func TestRegistry_CheckUpkeeps(t *testing.T) { + lggr := logger.TestLogger(t) + uid0 := genUpkeepID(ocr2keepers.UpkeepType(0), "p0") + uid1 := genUpkeepID(ocr2keepers.UpkeepType(1), "p1") + uid2 := genUpkeepID(ocr2keepers.UpkeepType(1), "p2") + + extension1 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x0919c83363b439ea634ce2b576cf3e30db26b340fb7a12058c2fcc401bd04ba0"), + BlockNumber: 550, + } + extension2 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), + BlockNumber: 550, + } + + trigger0 := ocr2keepers.NewTrigger(150, common.HexToHash("0x1c77db0abe32327cf3ea9de2aadf79876f9e6b6dfcee9d4719a8a2dc8ca289d0")) + trigger1 := ocr2keepers.NewLogTrigger(560, common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), extension1) + trigger2 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension2) + + tests := []struct { + name string + inputs []ocr2keepers.UpkeepPayload + blocks map[int64]string + latestBlock *big.Int + results []ocr2keepers.CheckResult + err error + ethCalls map[string]bool + receipts map[string]*types.Receipt + ethCallErrors map[string]error + }{ + { + name: "check upkeeps with different upkeep types", + inputs: []ocr2keepers.UpkeepPayload{ + { + UpkeepID: uid0, + Trigger: trigger0, + WorkID: "work0", + }, + { + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + }, + { + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + // check data byte slice length cannot be odd number, abi pack error + CheckData: []byte{0, 0, 0, 0, 1}, + }, + }, + blocks: map[int64]string{ + 550: "0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857", + 560: "0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857", + 570: "0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc", + }, + latestBlock: big.NewInt(580), + results: []ocr2keepers.CheckResult{ + { + PipelineExecutionState: uint8(CheckBlockTooOld), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid0, + Trigger: trigger0, + WorkID: "work0", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + }, + { + PipelineExecutionState: uint8(RpcFlakyFailure), + Retryable: true, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + }, + { + PipelineExecutionState: uint8(PackUnpackDecodeFailed), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + }, + }, + ethCalls: map[string]bool{ + uid1.String(): true, + }, + receipts: map[string]*types.Receipt{ + //uid1.String(): { + // BlockNumber: big.NewInt(550), + // BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + //}, + }, + ethCallErrors: map[string]error{ + uid1.String(): fmt.Errorf("error"), + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + bs := &BlockSubscriber{ + latestBlock: atomic.Int64{}, + blocks: tc.blocks, + } + bs.latestBlock.Store(tc.latestBlock.Int64()) + e := &EvmRegistry{ + lggr: lggr, + bs: bs, + } + client := new(evmClientMocks.Client) + for _, i := range tc.inputs { + uid := i.UpkeepID.String() + if tc.ethCalls[uid] { + client.On("TransactionReceipt", mock.Anything, common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651")). + Return(tc.receipts[uid], tc.ethCallErrors[uid]) + } + } + e.client = client + + results, err := e.checkUpkeeps(context.Background(), tc.inputs) + assert.Equal(t, tc.results, results) + assert.Equal(t, tc.err, err) + }) + } +} + +func TestRegistry_SimulatePerformUpkeeps(t *testing.T) { + uid0 := genUpkeepID(ocr2keepers.UpkeepType(0), "p0") + uid1 := genUpkeepID(ocr2keepers.UpkeepType(1), "p1") + uid2 := genUpkeepID(ocr2keepers.UpkeepType(1), "p2") + + extension1 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), + BlockNumber: 550, + } + + trigger0 := ocr2keepers.NewTrigger(150, common.HexToHash("0x1c77db0abe32327cf3ea9de2aadf79876f9e6b6dfcee9d4719a8a2dc8ca289d0")) + trigger1 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension1) + trigger2 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension1) + + cr0 := ocr2keepers.CheckResult{ + PipelineExecutionState: uint8(CheckBlockTooOld), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid0, + Trigger: trigger0, + WorkID: "work0", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + } + + tests := []struct { + name string + inputs []ocr2keepers.CheckResult + results []ocr2keepers.CheckResult + err error + }{ + { + name: "simulate multiple upkeeps", + inputs: []ocr2keepers.CheckResult{ + cr0, + { + PipelineExecutionState: 0, + Retryable: false, + Eligible: true, + IneligibilityReason: 0, + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + { + PipelineExecutionState: 0, + Retryable: false, + Eligible: true, + IneligibilityReason: 0, + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + }, + results: []ocr2keepers.CheckResult{ + cr0, + { + PipelineExecutionState: uint8(RpcFlakyFailure), + Retryable: true, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + { + PipelineExecutionState: uint8(PackUnpackDecodeFailed), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + e := setupEVMRegistry(t) + client := new(evmClientMocks.Client) + client.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { + return len(b) == 2 && b[0].Method == "eth_call" && b[1].Method == "eth_call" + })).Return(nil). + Run(func(args mock.Arguments) { + be := args.Get(1).([]rpc.BatchElem) + be[0].Error = fmt.Errorf("error") + res := "0x0001" + be[1].Result = res + }).Once() + e.client = client + + results, err := e.simulatePerformUpkeeps(context.Background(), tc.inputs) + assert.Equal(t, tc.results, results) + assert.Equal(t, tc.err, err) + }) + } + +} From 1c0af79239961e2db6e82988214cade24e0491b4 Mon Sep 17 00:00:00 2001 From: Tate Date: Tue, 15 Aug 2023 16:14:50 -0600 Subject: [PATCH 177/270] [TT-519] Matrix Go Cache Key Collision Fix (#10211) --- .github/actions/setup-go/action.yml | 14 +++++--------- .github/workflows/ci-core.yml | 2 +- .github/workflows/integration-tests.yml | 4 ++-- 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/.github/actions/setup-go/action.yml b/.github/actions/setup-go/action.yml index 3695c72abc5..575df306058 100644 --- a/.github/actions/setup-go/action.yml +++ b/.github/actions/setup-go/action.yml @@ -4,12 +4,9 @@ inputs: only-modules: description: Set to 'true' to only cache modules default: 'false' - cache-go-modules: - description: | - Option to cache go modules - In matrix jobs the caching will fail in all but the first one to complete and - in doing so it will waste time in the pipeline - default: 'true' + matrix-id: + description: Job caches can have key collisions when used in a matrix so we need to pass a unique id in for these cases + default: "1" cache-version: description: Set this to cache bust default: "1" @@ -36,16 +33,15 @@ runs: echo "gobuildcache=$(go env GOCACHE)" >> $GITHUB_OUTPUT - uses: actions/cache@v3 - if: ${{ inputs.cache-go-modules == 'true' }} name: Cache Go Modules with: path: | ${{ steps.go-cache-dir.outputs.gomodcache }} # The lifetime of go modules is much higher than the build outputs, so we increase cache efficiency # here by not having the primary key contain the branch name - key: ${{ runner.os }}-gomod-${{ inputs.cache-version }}-${{ hashFiles('./go.sum') }} + key: ${{ runner.os }}-gomod-${{ inputs.matrix-id }}-${{ inputs.cache-version }}-${{ hashFiles('./go.sum') }} restore-keys: | - ${{ runner.os }}-gomod-${{ inputs.cache-version }}- + ${{ runner.os }}-gomod-${{ inputs.matrix-id }}-${{ inputs.cache-version }}- - uses: actions/cache@v3 if: ${{ inputs.only-modules == 'false' }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 6a32a899375..ad7587dedc7 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -154,7 +154,7 @@ jobs: - name: Setup Go uses: ./.github/actions/setup-go with: - cache-go-modules: ${{ contains(matrix.split.id, '1/') }} + matrix-id: ${{ matrix.cmd }}-${{ matrix.split.id }} - name: Setup Solana uses: ./.github/actions/setup-solana - name: Setup wasmd diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index dd74b92d594..3609e00e978 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -174,7 +174,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.8 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -198,7 +198,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.6 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.8 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod From d387b25d870dacb66b3c01e4b370e0e887fdfc40 Mon Sep 17 00:00:00 2001 From: Anindita Ghosh <88458927+AnieeG@users.noreply.github.com> Date: Tue, 15 Aug 2023 16:42:48 -0700 Subject: [PATCH 178/270] non-dev geth container building (#10213) --- integration-tests/actions/actions.go | 2 +- integration-tests/client/chainlink_models.go | 32 ++--- integration-tests/docker/test_env/cl_node.go | 13 +- .../docker/test_env/mockserver.go | 2 +- integration-tests/docker/test_env/test_env.go | 40 +++++- .../docker/test_env/test_env_builder.go | 40 +++++- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- integration-tests/networks/known_networks.go | 26 +++- integration-tests/types/config/node/core.go | 130 +++++++++++++----- .../types/config/node/defaults/sample.toml | 22 +++ 11 files changed, 241 insertions(+), 72 deletions(-) create mode 100644 integration-tests/types/config/node/defaults/sample.toml diff --git a/integration-tests/actions/actions.go b/integration-tests/actions/actions.go index 00d4317e85d..ffb71cb7424 100644 --- a/integration-tests/actions/actions.go +++ b/integration-tests/actions/actions.go @@ -85,7 +85,7 @@ func FundChainlinkNodesAddress( // FundChainlinkNodesAddress will fund all of the provided Chainlink nodes addresses with a set amount of native currency func FundChainlinkNodesAddresses( - nodes []*client.ChainlinkK8sClient, + nodes []*client.ChainlinkClient, client blockchain.EVMClient, amount *big.Float, ) error { diff --git a/integration-tests/client/chainlink_models.go b/integration-tests/client/chainlink_models.go index 122f2d1e720..e01b07ab2c3 100644 --- a/integration-tests/client/chainlink_models.go +++ b/integration-tests/client/chainlink_models.go @@ -598,7 +598,7 @@ schedule = "{{.Schedule}}" observationSource = """ {{.ObservationSource}} """` - return marshallTemplate(c, "CRON Job", cronJobTemplateString) + return MarshallTemplate(c, "CRON Job", cronJobTemplateString) } // PipelineSpec common API call pipeline @@ -618,7 +618,7 @@ func (d *PipelineSpec) String() (string, error) { fetch [type=bridge name="{{.BridgeTypeAttributes.Name}}" requestData="{{.BridgeTypeAttributes.RequestData}}"]; parse [type=jsonparse path="{{.DataPath}}"]; fetch -> parse;` - return marshallTemplate(d, "API call pipeline template", sourceString) + return MarshallTemplate(d, "API call pipeline template", sourceString) } // VRFV2TxPipelineSpec VRFv2 request with tx callback @@ -655,7 +655,7 @@ simulate [type=ethcall contract="{{ .Address }}" data="$(vrf.output)"] decode_log->vrf->estimate_gas->simulate` - return marshallTemplate(d, "VRFV2 pipeline template", sourceString) + return MarshallTemplate(d, "VRFV2 pipeline template", sourceString) } // VRFTxPipelineSpec VRF request with tx callback @@ -687,7 +687,7 @@ submit_tx [type=ethtx to="{{.Address}}" data="$(encode_tx)" txMeta="{\\"requestTxHash\\": $(jobRun.logTxHash),\\"requestID\\": $(decode_log.requestID),\\"jobID\\": $(jobSpec.databaseID)}"] decode_log->vrf->encode_tx->submit_tx` - return marshallTemplate(d, "VRF pipeline template", sourceString) + return MarshallTemplate(d, "VRF pipeline template", sourceString) } // DirectRequestTxPipelineSpec oracle request with tx callback @@ -719,7 +719,7 @@ func (d *DirectRequestTxPipelineSpec) String() (string, error) { parse [type=jsonparse path="{{.DataPath}}"] submit [type=ethtx to="$(decode_log.requester)" data="$(encode_tx)" failOnRevert=true] decode_log -> fetch -> parse -> encode_tx -> submit` - return marshallTemplate(d, "Direct request pipeline template", sourceString) + return MarshallTemplate(d, "Direct request pipeline template", sourceString) } // DirectRequestJobSpec represents a direct request spec @@ -746,7 +746,7 @@ minIncomingConfirmations = {{.MinIncomingConfirmations}} observationSource = """ {{.ObservationSource}} """` - return marshallTemplate(d, "Direct Request Job", directRequestTemplateString) + return MarshallTemplate(d, "Direct Request Job", directRequestTemplateString) } // FluxMonitorJobSpec represents a flux monitor spec @@ -788,7 +788,7 @@ maxTaskDuration = {{if not .Precision}} "180s" {{else}} {{.Precision}} {{end}} observationSource = """ {{.ObservationSource}} """` - return marshallTemplate(f, "Flux Monitor Job", fluxMonitorTemplateString) + return MarshallTemplate(f, "Flux Monitor Job", fluxMonitorTemplateString) } // KeeperJobSpec represents a V2 keeper spec @@ -812,7 +812,7 @@ contractAddress = "{{.ContractAddress}}" fromAddress = "{{.FromAddress}}" minIncomingConfirmations = {{.MinIncomingConfirmations}} ` - return marshallTemplate(k, "Keeper Job", keeperTemplateString) + return MarshallTemplate(k, "Keeper Job", keeperTemplateString) } // OCRBootstrapJobSpec represents the spec for bootstrapping an OCR job, given to one node that then must be linked @@ -843,7 +843,7 @@ contractAddress = "{{.ContractAddress}}" p2pBootstrapPeers = [] isBootstrapPeer = {{.IsBootstrapPeer}} p2pPeerID = "{{.P2PPeerID}}"` - return marshallTemplate(o, "OCR Bootstrap Job", ocrTemplateString) + return MarshallTemplate(o, "OCR Bootstrap Job", ocrTemplateString) } // OCRTaskJobSpec represents an OCR job that is given to other nodes, meant to communicate with the bootstrap node, @@ -954,7 +954,7 @@ observationSource = """ {{.ObservationSource}} """` - return marshallTemplate(specWrap, "OCR Job", ocrTemplateString) + return MarshallTemplate(specWrap, "OCR Job", ocrTemplateString) } // OCR2TaskJobSpec represents an OCR2 job that is given to other nodes, meant to communicate with the bootstrap node, @@ -1062,7 +1062,7 @@ observationSource = """ [relayConfig]{{range $key, $value := .RelayConfig}} {{$key}} = {{$value}}{{end}} ` - return marshallTemplate(specWrap, "OCR2 Job", ocr2TemplateString) + return MarshallTemplate(specWrap, "OCR2 Job", ocr2TemplateString) } // VRFV2JobSpec represents a VRFV2 job @@ -1102,7 +1102,7 @@ observationSource = """ {{.ObservationSource}} """ ` - return marshallTemplate(v, "VRFV2 Job", vrfTemplateString) + return MarshallTemplate(v, "VRFV2 Job", vrfTemplateString) } // VRFJobSpec represents a VRF job @@ -1132,7 +1132,7 @@ observationSource = """ {{.ObservationSource}} """ ` - return marshallTemplate(v, "VRF Job", vrfTemplateString) + return MarshallTemplate(v, "VRF Job", vrfTemplateString) } // BlockhashStoreJobSpec represents a blockhashstore job @@ -1164,7 +1164,7 @@ pollPeriod = "{{.PollPeriod}}" runTimeout = "{{.RunTimeout}}" evmChainID = "{{.EVMChainID}}" ` - return marshallTemplate(b, "BlockhashStore Job", vrfTemplateString) + return MarshallTemplate(b, "BlockhashStore Job", vrfTemplateString) } // WebhookJobSpec reprsents a webhook job @@ -1189,7 +1189,7 @@ externalInitiators = [ observationSource = """ {{.ObservationSource}} """` - return marshallTemplate(w, "Webhook Job", webHookTemplateString) + return MarshallTemplate(w, "Webhook Job", webHookTemplateString) } // ObservationSourceSpecHTTP creates a http GET task spec for json data @@ -1209,7 +1209,7 @@ func ObservationSourceSpecBridge(bta *BridgeTypeAttributes) string { } // marshallTemplate Helper to marshall templates -func marshallTemplate(jobSpec interface{}, name, templateString string) (string, error) { +func MarshallTemplate(jobSpec interface{}, name, templateString string) (string, error) { var buf bytes.Buffer tmpl, err := template.New(name).Parse(templateString) if err != nil { diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 0d0f0f18ad2..88158450027 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -5,6 +5,7 @@ import ( "crypto/ed25519" "encoding/hex" "fmt" + "math/big" "net/url" "os" "strings" @@ -15,22 +16,21 @@ import ( "github.com/pelletier/go-toml/v2" "github.com/pkg/errors" - "math/big" - "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/common" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" + "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" + "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/utils" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" - ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" - "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" - tc "github.com/testcontainers/testcontainers-go" - tcwait "github.com/testcontainers/testcontainers-go/wait" ) var ( @@ -257,6 +257,7 @@ func (n *ClNode) StartContainer() error { return errors.Wrap(err, ErrConnectNodeClient) } + clClient.Config.InternalIP = n.ContainerName n.Container = container n.API = clClient diff --git a/integration-tests/docker/test_env/mockserver.go b/integration-tests/docker/test_env/mockserver.go index 5e5cce69e75..76894aa098b 100644 --- a/integration-tests/docker/test_env/mockserver.go +++ b/integration-tests/docker/test_env/mockserver.go @@ -92,7 +92,7 @@ func (ms *MockServer) StartContainer() error { func (ms *MockServer) getContainerRequest() tc.ContainerRequest { return tc.ContainerRequest{ Name: ms.ContainerName, - Image: "mockserver/mockserver:5.11.2", + Image: "mockserver/mockserver:5.15.0", ExposedPorts: []string{"1080/tcp"}, Env: map[string]string{ "SERVER_PORT": "1080", diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index f283edf31fa..12958f38da7 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -1,22 +1,25 @@ package test_env import ( - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "math/big" "sync" - "math/big" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink-testing-framework/docker/test_env" + + "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + tc "github.com/testcontainers/testcontainers-go" + "go.uber.org/multierr" + "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/docker" "github.com/smartcontractkit/chainlink/integration-tests/utils" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" - tc "github.com/testcontainers/testcontainers-go" - "go.uber.org/multierr" ) var ( @@ -31,7 +34,8 @@ type CLClusterTestEnv struct { /* components */ CLNodes []*ClNode - Geth *Geth + Geth *Geth // for tests using --dev networks + PrivateGethChain []test_env.PrivateGethChain // for tests using non-dev networks MockServer *MockServer EVMClient blockchain.EVMClient ContractDeployer contracts.ContractDeployer @@ -72,6 +76,30 @@ func (te *CLClusterTestEnv) ParallelTransactions(enabled bool) { te.EVMClient.ParallelTransactions(enabled) } +func (m *CLClusterTestEnv) WithPrivateGethChain(evmNetworks []blockchain.EVMNetwork) *CLClusterTestEnv { + var chains []test_env.PrivateGethChain + for _, evmNetwork := range evmNetworks { + n := evmNetwork + chains = append(chains, test_env.NewPrivateGethChain(&n, []string{m.Network.Name})) + } + m.PrivateGethChain = chains + return m +} + +func (m *CLClusterTestEnv) StartPrivateGethChain() error { + for _, chain := range m.PrivateGethChain { + err := chain.PrimaryNode.Start() + if err != nil { + return err + } + err = chain.PrimaryNode.ConnectToClient() + if err != nil { + return err + } + } + return nil +} + func (te *CLClusterTestEnv) StartGeth() (blockchain.EVMNetwork, InternalDockerUrls, error) { return te.Geth.StartContainer() } diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index aa9374d0640..9eb98ea23c3 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -1,15 +1,18 @@ package test_env import ( + "math/big" + "os" + + "github.com/pkg/errors" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/networks" - "os" - - "math/big" "github.com/rs/zerolog/log" - "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" ) @@ -20,6 +23,7 @@ type CLTestEnvBuilder struct { hasMockServer bool hasForwarders bool clNodeConfig *chainlink.Config + nonDevGethNetworks []blockchain.EVMNetwork clNodesCount int externalAdapterCount int customNodeCsaKeys []string @@ -65,6 +69,11 @@ func (b *CLTestEnvBuilder) WithGeth() *CLTestEnvBuilder { return b } +func (m *CLTestEnvBuilder) WithPrivateGethChains(evmNetworks []blockchain.EVMNetwork) *CLTestEnvBuilder { + m.nonDevGethNetworks = evmNetworks + return m +} + func (b *CLTestEnvBuilder) WithCLNodeConfig(cfg *chainlink.Config) *CLTestEnvBuilder { b.clNodeConfig = cfg return b @@ -130,6 +139,28 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e return nil, err } } + if b.nonDevGethNetworks != nil { + te.WithPrivateGethChain(b.nonDevGethNetworks) + err := te.StartPrivateGethChain() + if err != nil { + return te, err + } + var nonDevGethNetworks []blockchain.EVMNetwork + for i, n := range te.PrivateGethChain { + nonDevGethNetworks = append(nonDevGethNetworks, *n.NetworkConfig) + nonDevGethNetworks[i].URLs = []string{n.PrimaryNode.InternalWsUrl} + nonDevGethNetworks[i].HTTPURLs = []string{n.PrimaryNode.InternalHttpUrl} + } + if nonDevGethNetworks == nil { + return nil, errors.New("cannot create nodes with custom config without nonDevGethNetworks") + } + + err = te.StartClNodes(b.clNodeConfig, b.clNodesCount) + if err != nil { + return nil, err + } + return te, nil + } networkConfig := networks.SelectedNetwork var internalDockerUrls InternalDockerUrls if b.hasGeth && networkConfig.Simulated { @@ -137,6 +168,7 @@ func (b *CLTestEnvBuilder) buildNewEnv(cfg *TestEnvConfig) (*CLClusterTestEnv, e if err != nil { return nil, err } + } bc, err := blockchain.NewEVMClientFromNetwork(networkConfig) diff --git a/integration-tests/go.mod b/integration-tests/go.mod index bf91f13c4a8..88aca866beb 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -20,7 +20,7 @@ require ( github.com/rs/zerolog v1.29.1 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-env v0.36.0 - github.com/smartcontractkit/chainlink-testing-framework v1.15.2 + github.com/smartcontractkit/chainlink-testing-framework v1.15.3 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 github.com/smartcontractkit/ocr2keepers v0.7.9 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 4d20eb55875..1c750a7cbcd 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2247,8 +2247,8 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= -github.com/smartcontractkit/chainlink-testing-framework v1.15.2 h1:WhZvHHz104RKC9u5u+zHeP4YwyyFVG3bW0DVRSe4FnE= -github.com/smartcontractkit/chainlink-testing-framework v1.15.2/go.mod h1:WxEBntXbe20FgTZllV5fo4fKLd0TM8NfYdWkX5kt6Mg= +github.com/smartcontractkit/chainlink-testing-framework v1.15.3 h1:phuO4wpbT3GR2ZFIzgwQ3DjfLaZwtHOvJkuEJOC8vxk= +github.com/smartcontractkit/chainlink-testing-framework v1.15.3/go.mod h1:m9p6TzNHs4SXfsS3MJHjTk2vF8jsqHb2ipSSYkjT6zs= github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kNwgFlDmbE/n0gTSRMt9GBDfsfGrs4X9b9arPZtFI= github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= diff --git a/integration-tests/networks/known_networks.go b/integration-tests/networks/known_networks.go index da8675caa6a..a7b70a51763 100644 --- a/integration-tests/networks/known_networks.go +++ b/integration-tests/networks/known_networks.go @@ -60,6 +60,7 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: 2 * time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 10000, + DefaultGasLimit: 6000000, } // SimulatedEVM_NON_DEV_2 represents a simulated network with chain id 2337 which can be used to deploy a non-dev geth node @@ -70,7 +71,7 @@ var ( ClientImplementation: blockchain.EthereumClientImplementation, ChainID: 2337, PrivateKeys: []string{ - "ac0974bec39a17e36ba4a6b4d238ff944bacb478cbed5efcae784d7bf4f2ff80", + "59c6995e998f97a5a0044966f0945389dc9e86dae88c7a8412f4603b6b78690d", }, URLs: []string{"ws://dest-chain-ethereum-geth:8546"}, HTTPURLs: []string{"http://dest-chain-ethereum-geth:8544"}, @@ -78,6 +79,7 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: 2 * time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 10000, + DefaultGasLimit: 6000000, } SimulatedEVMNonDev = blockchain.EVMNetwork{ @@ -107,6 +109,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: 5 * time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 0, + FinalityTag: true, + DefaultGasLimit: 6000000, } // sepoliaTestnet https://sepolia.dev/ @@ -120,6 +124,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 1000, + FinalityTag: true, + DefaultGasLimit: 6000000, } // goerliTestnet https://goerli.net/ @@ -133,6 +139,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: 5 * time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 1000, + FinalityTag: true, + DefaultGasLimit: 6000000, } KlaytnMainnet blockchain.EVMNetwork = blockchain.EVMNetwork{ @@ -195,6 +203,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: 2 * time.Minute}, MinimumConfirmations: 0, GasEstimationBuffer: 0, + FinalityTag: true, + DefaultGasLimit: 100000000, } // arbitrumGoerli https://developer.offchainlabs.com/docs/public_chains @@ -208,6 +218,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 0, GasEstimationBuffer: 0, + FinalityTag: true, + DefaultGasLimit: 100000000, } OptimismMainnet blockchain.EVMNetwork = blockchain.EVMNetwork{ @@ -220,6 +232,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 0, + FinalityTag: true, + DefaultGasLimit: 6000000, } // optimismGoerli https://dev.optimism.io/kovan-to-goerli/ @@ -233,6 +247,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 0, + FinalityTag: true, + DefaultGasLimit: 6000000, } RSKMainnet blockchain.EVMNetwork = blockchain.EVMNetwork{ @@ -270,6 +286,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: 2 * time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 0, + FinalityDepth: 550, + DefaultGasLimit: 6000000, } // PolygonMumbai https://mumbai.polygonscan.com/ @@ -283,6 +301,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 1000, + FinalityDepth: 550, + DefaultGasLimit: 6000000, } AvalancheMainnet blockchain.EVMNetwork = blockchain.EVMNetwork{ @@ -295,6 +315,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 0, + FinalityDepth: 35, + DefaultGasLimit: 6000000, } AvalancheFuji = blockchain.EVMNetwork{ @@ -307,6 +329,8 @@ var ( Timeout: blockchain.JSONStrDuration{Duration: time.Minute}, MinimumConfirmations: 1, GasEstimationBuffer: 1000, + FinalityDepth: 35, + DefaultGasLimit: 6000000, } Quorum = blockchain.EVMNetwork{ diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go index fc383edb9b5..5ee27447a2c 100644 --- a/integration-tests/types/config/node/core.go +++ b/integration-tests/types/config/node/core.go @@ -1,56 +1,67 @@ package node import ( + "bytes" + "embed" "fmt" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "math/big" "net" + "path/filepath" "time" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" + "github.com/smartcontractkit/chainlink/v2/core/utils/config" + + "go.uber.org/zap/zapcore" + "github.com/smartcontractkit/chainlink/v2/core/assets" evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" "github.com/smartcontractkit/chainlink/v2/core/config/toml" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" - "go.uber.org/zap/zapcore" ) -var BaseConf = &chainlink.Config{ - Core: toml.Core{ - RootDir: ptr("/home/chainlink"), - Database: toml.Database{ - MaxIdleConns: ptr(int64(20)), - MaxOpenConns: ptr(int64(40)), - MigrateOnStartup: ptr(true), - }, - Log: toml.Log{ - Level: ptr(toml.LogLevel(zapcore.DebugLevel)), - JSONConsole: ptr(true), - }, - WebServer: toml.WebServer{ - AllowOrigins: ptr("*"), - HTTPPort: ptr[uint16](6688), - SecureCookies: ptr(false), - SessionTimeout: models.MustNewDuration(time.Hour * 999), - TLS: toml.WebServerTLS{ - HTTPSPort: ptr[uint16](0), +var ( + BaseConf = &chainlink.Config{ + Core: toml.Core{ + RootDir: ptr("/home/chainlink"), + Database: toml.Database{ + MaxIdleConns: ptr(int64(20)), + MaxOpenConns: ptr(int64(40)), + MigrateOnStartup: ptr(true), }, - RateLimit: toml.WebServerRateLimit{ - Authenticated: ptr(int64(2000)), - Unauthenticated: ptr(int64(100)), + Log: toml.Log{ + Level: ptr(toml.LogLevel(zapcore.DebugLevel)), + JSONConsole: ptr(true), }, + WebServer: toml.WebServer{ + AllowOrigins: ptr("*"), + HTTPPort: ptr[uint16](6688), + SecureCookies: ptr(false), + SessionTimeout: models.MustNewDuration(time.Hour * 999), + TLS: toml.WebServerTLS{ + HTTPSPort: ptr[uint16](0), + }, + RateLimit: toml.WebServerRateLimit{ + Authenticated: ptr(int64(2000)), + Unauthenticated: ptr(int64(100)), + }, + }, + Feature: toml.Feature{ + LogPoller: ptr(true), + FeedsManager: ptr(true), + UICSAKeys: ptr(true), + }, + P2P: toml.P2P{}, }, - Feature: toml.Feature{ - LogPoller: ptr(true), - FeedsManager: ptr(true), - UICSAKeys: ptr(true), - }, - P2P: toml.P2P{}, - }, -} + } + //go:embed defaults/*.toml + defaultsFS embed.FS +) type NodeConfigOpt = func(c *chainlink.Config) @@ -61,6 +72,23 @@ func NewConfig(baseConf *chainlink.Config, opts ...NodeConfigOpt) *chainlink.Con return baseConf } +func NewConfigFromToml(tomlFile string, opts ...NodeConfigOpt) (*chainlink.Config, error) { + path := filepath.Join("defaults", tomlFile+".toml") + b, err := defaultsFS.ReadFile(path) + if err != nil { + return nil, err + } + var cfg chainlink.Config + err = config.DecodeTOML(bytes.NewReader(b), &cfg) + if err != nil { + return nil, err + } + for _, opt := range opts { + opt(&cfg) + } + return &cfg, err +} + func WithOCR1() NodeConfigOpt { return func(c *chainlink.Config) { c.OCR = toml.OCR{ @@ -138,6 +166,40 @@ func SetChainConfig( } } +func WithPrivateEVMs(networks []blockchain.EVMNetwork) NodeConfigOpt { + var evmConfigs []*evmcfg.EVMConfig + for _, network := range networks { + evmConfigs = append(evmConfigs, &evmcfg.EVMConfig{ + ChainID: utils.NewBig(big.NewInt(network.ChainID)), + Chain: evmcfg.Chain{ + AutoCreateKey: ptr(true), + FinalityDepth: ptr[uint32](50), + MinContractPayment: assets.NewLinkFromJuels(0), + LogPollInterval: models.MustNewDuration(1 * time.Second), + HeadTracker: evmcfg.HeadTracker{ + HistoryDepth: ptr(uint32(100)), + }, + GasEstimator: evmcfg.GasEstimator{ + LimitDefault: ptr(uint32(6000000)), + PriceMax: assets.GWei(200), + FeeCapDefault: assets.GWei(200), + }, + }, + Nodes: []*evmcfg.Node{ + { + Name: ptr(network.Name), + WSURL: mustURL(network.URLs[0]), + HTTPURL: mustURL(network.HTTPURLs[0]), + SendOnly: ptr(false), + }, + }, + }) + } + return func(c *chainlink.Config) { + c.EVM = evmConfigs + } +} + func WithVRFv2EVMEstimator(addr string) NodeConfigOpt { est := assets.GWei(vrfv2_constants.MaxGasPriceGWei) return func(c *chainlink.Config) { diff --git a/integration-tests/types/config/node/defaults/sample.toml b/integration-tests/types/config/node/defaults/sample.toml new file mode 100644 index 00000000000..3663998003c --- /dev/null +++ b/integration-tests/types/config/node/defaults/sample.toml @@ -0,0 +1,22 @@ +[Feature] +LogPoller = true + +[Database] +MaxIdleConns = 50 +MaxOpenConns = 50 + +[OCR2] +Enabled = true +DefaultTransactionQueueDepth = 0 + +[OCR] +Enabled = false +DefaultTransactionQueueDepth = 0 + +[P2P] +[P2P.V2] +Enabled = true +ListenAddresses = ['0.0.0.0:6690'] +AnnounceAddresses = ['0.0.0.0:6690'] +DeltaDial = '500ms' +DeltaReconcile = '5s' \ No newline at end of file From 3cd5267e839e98c59135a138b0da4fc76fc0a959 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 15 Aug 2023 20:23:42 -0500 Subject: [PATCH 179/270] Bump golangci/golangci-lint-action from 3.6.0 to 3.7.0 (#10212) Bumps [golangci/golangci-lint-action](https://github.com/golangci/golangci-lint-action) from 3.6.0 to 3.7.0. - [Release notes](https://github.com/golangci/golangci-lint-action/releases) - [Commits](https://github.com/golangci/golangci-lint-action/compare/639cd343e1d3b897ff35927a75193d57cfcba299...3a919529898de77ec3da873e3063ca4b10e7f5cc) --- updated-dependencies: - dependency-name: golangci/golangci-lint-action dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jordan Krage --- .github/workflows/ci-core.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index ad7587dedc7..57d5ce44500 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -78,7 +78,7 @@ jobs: cache: false - name: golangci-lint if: needs.init.outputs.on_trigger_lint == 'true' - uses: golangci/golangci-lint-action@639cd343e1d3b897ff35927a75193d57cfcba299 # v3.6.0 + uses: golangci/golangci-lint-action@3a919529898de77ec3da873e3063ca4b10e7f5cc # v3.7.0 with: version: v1.53.3 only-new-issues: ${{ github.event.schedule == '' }} # show only new issues, unless it's a scheduled run From 770198083d8853199860942124f2c4a698da557b Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Tue, 15 Aug 2023 20:28:00 -0500 Subject: [PATCH 180/270] .github/workflows: slack alert for data races in nightly runs (#9490) --- .github/workflows/ci-core.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 57d5ce44500..18f10669642 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -227,6 +227,14 @@ jobs: - name: Check test results if: needs.core.result != 'success' run: exit 1 + - name: Notify Slack + if: failure() && ${{ matrix.cmd }} == 'go_core_race_tests' && github.event.schedule != '' + uses: slackapi/slack-github-action@e28cf165c92ffef168d23c5c9000cffc8a25e117 # v1.24.0 + env: + SLACK_BOT_TOKEN: ${{ secrets.QA_SLACK_API_KEY }} + with: + channel-id: '#topic-data-races' + slack-message: "Race tests failed: ${{ job.html_url }}\n${{ github.event.pull_request.html_url || github.event.head_commit.url }}" - name: Collect Metrics if: always() id: collect-gha-metrics From cab207126fa9c55fb78baa546cb7ddac42a778f5 Mon Sep 17 00:00:00 2001 From: Mateusz Sekara Date: Wed, 16 Aug 2023 07:56:20 +0200 Subject: [PATCH 181/270] [CCIP-958] Passing qopts all the way down when starting jobs (#10166) * Unification in LogPoller interface - RegisterFilter and UnregisterFilter accepts pg.QOpt like rest of the LogPoller's interface function * Adding pg.QOpts to the Delegate interface * Propagating qopts in Spawner * Missing qopts in LogPoller --- core/chains/evm/logpoller/disabled.go | 4 +-- core/chains/evm/logpoller/log_poller.go | 12 +++---- .../evm/logpoller/log_poller_internal_test.go | 8 ++--- core/chains/evm/logpoller/log_poller_test.go | 4 +-- core/chains/evm/logpoller/mocks/log_poller.go | 34 +++++++++++++------ core/services/blockhashstore/delegate.go | 2 +- core/services/blockheaderfeeder/delegate.go | 2 +- core/services/cron/delegate.go | 2 +- core/services/directrequest/delegate.go | 2 +- core/services/fluxmonitorv2/delegate.go | 2 +- core/services/gateway/delegate.go | 2 +- core/services/job/mocks/spawner.go | 17 +++++++--- core/services/job/spawner.go | 12 +++---- core/services/job/spawner_test.go | 3 +- core/services/keeper/delegate.go | 2 +- core/services/ocr/delegate.go | 2 +- core/services/ocr2/delegate.go | 4 +-- .../evm21/logprovider/provider_life_cycle.go | 2 +- core/services/ocrbootstrap/delegate.go | 2 +- core/services/vrf/delegate.go | 2 +- core/services/webhook/delegate.go | 2 +- core/web/evm_forwarders_controller.go | 2 +- 22 files changed, 73 insertions(+), 51 deletions(-) diff --git a/core/chains/evm/logpoller/disabled.go b/core/chains/evm/logpoller/disabled.go index 397ce2eda69..80a5550b0a5 100644 --- a/core/chains/evm/logpoller/disabled.go +++ b/core/chains/evm/logpoller/disabled.go @@ -33,9 +33,9 @@ func (disabled) Replay(ctx context.Context, fromBlock int64) error { return ErrD func (disabled) ReplayAsync(fromBlock int64) {} -func (disabled) RegisterFilter(filter Filter) error { return ErrDisabled } +func (disabled) RegisterFilter(filter Filter, qopts ...pg.QOpt) error { return ErrDisabled } -func (disabled) UnregisterFilter(name string, q pg.Queryer) error { return ErrDisabled } +func (disabled) UnregisterFilter(name string, qopts ...pg.QOpt) error { return ErrDisabled } func (disabled) LatestBlock(qopts ...pg.QOpt) (int64, error) { return -1, ErrDisabled } diff --git a/core/chains/evm/logpoller/log_poller.go b/core/chains/evm/logpoller/log_poller.go index f0892c61885..60767970289 100644 --- a/core/chains/evm/logpoller/log_poller.go +++ b/core/chains/evm/logpoller/log_poller.go @@ -34,8 +34,8 @@ type LogPoller interface { services.ServiceCtx Replay(ctx context.Context, fromBlock int64) error ReplayAsync(fromBlock int64) - RegisterFilter(filter Filter) error - UnregisterFilter(name string, q pg.Queryer) error + RegisterFilter(filter Filter, qopts ...pg.QOpt) error + UnregisterFilter(name string, qopts ...pg.QOpt) error LatestBlock(qopts ...pg.QOpt) (int64, error) GetBlocksRange(ctx context.Context, numbers []uint64, qopts ...pg.QOpt) ([]LogPollerBlock, error) @@ -200,7 +200,7 @@ func (filter *Filter) Contains(other *Filter) bool { // Generally speaking this is harmless. We enforce that EventSigs and Addresses are non-empty, // which means that anonymous events are not supported and log.Topics >= 1 always (log.Topics[0] is the event signature). // The filter may be unregistered later by Filter.Name -func (lp *logPoller) RegisterFilter(filter Filter) error { +func (lp *logPoller) RegisterFilter(filter Filter, qopts ...pg.QOpt) error { if len(filter.Addresses) == 0 { return errors.Errorf("at least one address must be specified") } @@ -232,7 +232,7 @@ func (lp *logPoller) RegisterFilter(filter Filter) error { lp.lggr.Debugw("Creating new filter", "filter", filter) } - if err := lp.orm.InsertFilter(filter); err != nil { + if err := lp.orm.InsertFilter(filter, qopts...); err != nil { return errors.Wrap(err, "RegisterFilter failed to save filter to db") } lp.filters[filter.Name] = filter @@ -240,7 +240,7 @@ func (lp *logPoller) RegisterFilter(filter Filter) error { return nil } -func (lp *logPoller) UnregisterFilter(name string, q pg.Queryer) error { +func (lp *logPoller) UnregisterFilter(name string, qopts ...pg.QOpt) error { lp.filterMu.Lock() defer lp.filterMu.Unlock() @@ -250,7 +250,7 @@ func (lp *logPoller) UnregisterFilter(name string, q pg.Queryer) error { return nil } - if err := lp.orm.DeleteFilter(name, pg.WithQueryer(q)); err != nil { + if err := lp.orm.DeleteFilter(name, qopts...); err != nil { return errors.Wrapf(err, "Failed to delete filter %s", name) } delete(lp.filters, name) diff --git a/core/chains/evm/logpoller/log_poller_internal_test.go b/core/chains/evm/logpoller/log_poller_internal_test.go index c1daf448afa..6a78d2e30ae 100644 --- a/core/chains/evm/logpoller/log_poller_internal_test.go +++ b/core/chains/evm/logpoller/log_poller_internal_test.go @@ -101,7 +101,7 @@ func TestLogPoller_RegisterFilter(t *testing.T) { validateFiltersTable(t, lp, orm) // Removing non-existence Filter should log error but return nil - err = lp.UnregisterFilter("Filter doesn't exist", nil) + err = lp.UnregisterFilter("Filter doesn't exist") require.NoError(t, err) require.Equal(t, observedLogs.Len(), 1) require.Contains(t, observedLogs.TakeAll()[0].Entry.Message, "not found") @@ -115,16 +115,16 @@ func TestLogPoller_RegisterFilter(t *testing.T) { require.True(t, ok, "'Emitter Log 1 + 2 dupe' Filter missing") // Removing an existing Filter should remove it from both memory and db - err = lp.UnregisterFilter("Emitter Log 1 + 2", nil) + err = lp.UnregisterFilter("Emitter Log 1 + 2") require.NoError(t, err) _, ok = lp.filters["Emitter Log 1 + 2"] require.False(t, ok, "'Emitter Log 1 Filter' should have been removed by UnregisterFilter()") require.Len(t, lp.filters, 2) validateFiltersTable(t, lp, orm) - err = lp.UnregisterFilter("Emitter Log 1 + 2 dupe", nil) + err = lp.UnregisterFilter("Emitter Log 1 + 2 dupe") require.NoError(t, err) - err = lp.UnregisterFilter("Emitter Log 1", nil) + err = lp.UnregisterFilter("Emitter Log 1") require.NoError(t, err) assert.Len(t, lp.filters, 0) filters, err := lp.orm.LoadFilters() diff --git a/core/chains/evm/logpoller/log_poller_test.go b/core/chains/evm/logpoller/log_poller_test.go index e639e1cbf71..595b961101f 100644 --- a/core/chains/evm/logpoller/log_poller_test.go +++ b/core/chains/evm/logpoller/log_poller_test.go @@ -223,10 +223,10 @@ func Test_BackupLogPoller(t *testing.T) { require.NoError(t, err) defer func() { - assert.NoError(t, th.LogPoller.UnregisterFilter("filter1", nil)) + assert.NoError(t, th.LogPoller.UnregisterFilter("filter1")) }() defer func() { - assert.NoError(t, th.LogPoller.UnregisterFilter("filter2", nil)) + assert.NoError(t, th.LogPoller.UnregisterFilter("filter2")) }() // generate some tx's with logs diff --git a/core/chains/evm/logpoller/mocks/log_poller.go b/core/chains/evm/logpoller/mocks/log_poller.go index c903f8ea973..9e96947abc7 100644 --- a/core/chains/evm/logpoller/mocks/log_poller.go +++ b/core/chains/evm/logpoller/mocks/log_poller.go @@ -602,13 +602,20 @@ func (_m *LogPoller) Ready() error { return r0 } -// RegisterFilter provides a mock function with given fields: filter -func (_m *LogPoller) RegisterFilter(filter logpoller.Filter) error { - ret := _m.Called(filter) +// RegisterFilter provides a mock function with given fields: filter, qopts +func (_m *LogPoller) RegisterFilter(filter logpoller.Filter, qopts ...pg.QOpt) error { + _va := make([]interface{}, len(qopts)) + for _i := range qopts { + _va[_i] = qopts[_i] + } + var _ca []interface{} + _ca = append(_ca, filter) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) var r0 error - if rf, ok := ret.Get(0).(func(logpoller.Filter) error); ok { - r0 = rf(filter) + if rf, ok := ret.Get(0).(func(logpoller.Filter, ...pg.QOpt) error); ok { + r0 = rf(filter, qopts...) } else { r0 = ret.Error(0) } @@ -649,13 +656,20 @@ func (_m *LogPoller) Start(_a0 context.Context) error { return r0 } -// UnregisterFilter provides a mock function with given fields: name, q -func (_m *LogPoller) UnregisterFilter(name string, q pg.Queryer) error { - ret := _m.Called(name, q) +// UnregisterFilter provides a mock function with given fields: name, qopts +func (_m *LogPoller) UnregisterFilter(name string, qopts ...pg.QOpt) error { + _va := make([]interface{}, len(qopts)) + for _i := range qopts { + _va[_i] = qopts[_i] + } + var _ca []interface{} + _ca = append(_ca, name) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) var r0 error - if rf, ok := ret.Get(0).(func(string, pg.Queryer) error); ok { - r0 = rf(name, q) + if rf, ok := ret.Get(0).(func(string, ...pg.QOpt) error); ok { + r0 = rf(name, qopts...) } else { r0 = ret.Error(0) } diff --git a/core/services/blockhashstore/delegate.go b/core/services/blockhashstore/delegate.go index ad248c8980d..dd21d0fbc51 100644 --- a/core/services/blockhashstore/delegate.go +++ b/core/services/blockhashstore/delegate.go @@ -49,7 +49,7 @@ func (d *Delegate) JobType() job.Type { } // ServicesForSpec satisfies the job.Delegate interface. -func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { if jb.BlockhashStoreSpec == nil { return nil, errors.Errorf( "blockhashstore.Delegate expects a BlockhashStoreSpec to be present, got %+v", jb) diff --git a/core/services/blockheaderfeeder/delegate.go b/core/services/blockheaderfeeder/delegate.go index 251d60f7ad1..18faba0b867 100644 --- a/core/services/blockheaderfeeder/delegate.go +++ b/core/services/blockheaderfeeder/delegate.go @@ -48,7 +48,7 @@ func (d *Delegate) JobType() job.Type { } // ServicesForSpec satisfies the job.Delegate interface. -func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { if jb.BlockHeaderFeederSpec == nil { return nil, errors.Errorf("Delegate expects a BlockHeaderFeederSpec to be present, got %+v", jb) } diff --git a/core/services/cron/delegate.go b/core/services/cron/delegate.go index c227fd60d00..a411a120128 100644 --- a/core/services/cron/delegate.go +++ b/core/services/cron/delegate.go @@ -33,7 +33,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec returns the scheduler to be used for running cron jobs -func (d *Delegate) ServicesForSpec(spec job.Job) (services []job.ServiceCtx, err error) { +func (d *Delegate) ServicesForSpec(spec job.Job, qopts ...pg.QOpt) (services []job.ServiceCtx, err error) { if spec.CronSpec == nil { return nil, errors.Errorf("services.Delegate expects a *jobSpec.CronSpec to be present, got %v", spec) } diff --git a/core/services/directrequest/delegate.go b/core/services/directrequest/delegate.go index 9f32a4e11a2..8d86f044172 100644 --- a/core/services/directrequest/delegate.go +++ b/core/services/directrequest/delegate.go @@ -68,7 +68,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec returns the log listener service for a direct request job -func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { if jb.DirectRequestSpec == nil { return nil, errors.Errorf("DirectRequest: directrequest.Delegate expects a *job.DirectRequestSpec to be present, got %v", jb) } diff --git a/core/services/fluxmonitorv2/delegate.go b/core/services/fluxmonitorv2/delegate.go index ba2edf9e0f0..286555e6675 100644 --- a/core/services/fluxmonitorv2/delegate.go +++ b/core/services/fluxmonitorv2/delegate.go @@ -59,7 +59,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec returns the flux monitor service for the job spec -func (d *Delegate) ServicesForSpec(jb job.Job) (services []job.ServiceCtx, err error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) (services []job.ServiceCtx, err error) { if jb.FluxMonitorSpec == nil { return nil, errors.Errorf("Delegate expects a *job.FluxMonitorSpec to be present, got %v", jb) } diff --git a/core/services/gateway/delegate.go b/core/services/gateway/delegate.go index bc170bd4e74..ef7104d666f 100644 --- a/core/services/gateway/delegate.go +++ b/core/services/gateway/delegate.go @@ -37,7 +37,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec returns the scheduler to be used for running observer jobs -func (d *Delegate) ServicesForSpec(spec job.Job) (services []job.ServiceCtx, err error) { +func (d *Delegate) ServicesForSpec(spec job.Job, qopts ...pg.QOpt) (services []job.ServiceCtx, err error) { if spec.GatewaySpec == nil { return nil, errors.Errorf("services.Delegate expects a *jobSpec.GatewaySpec to be present, got %v", spec) } diff --git a/core/services/job/mocks/spawner.go b/core/services/job/mocks/spawner.go index 768be76dc55..6f6c3200af8 100644 --- a/core/services/job/mocks/spawner.go +++ b/core/services/job/mocks/spawner.go @@ -146,13 +146,20 @@ func (_m *Spawner) Start(_a0 context.Context) error { return r0 } -// StartService provides a mock function with given fields: ctx, spec -func (_m *Spawner) StartService(ctx context.Context, spec job.Job) error { - ret := _m.Called(ctx, spec) +// StartService provides a mock function with given fields: ctx, spec, qopts +func (_m *Spawner) StartService(ctx context.Context, spec job.Job, qopts ...pg.QOpt) error { + _va := make([]interface{}, len(qopts)) + for _i := range qopts { + _va[_i] = qopts[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, spec) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) var r0 error - if rf, ok := ret.Get(0).(func(context.Context, job.Job) error); ok { - r0 = rf(ctx, spec) + if rf, ok := ret.Get(0).(func(context.Context, job.Job, ...pg.QOpt) error); ok { + r0 = rf(ctx, spec, qopts...) } else { r0 = ret.Error(0) } diff --git a/core/services/job/spawner.go b/core/services/job/spawner.go index e56fc42af1f..d5c716ab5fd 100644 --- a/core/services/job/spawner.go +++ b/core/services/job/spawner.go @@ -36,7 +36,7 @@ type ( // StartService starts services for the given job spec. // NOTE: Prefer to use CreateJob, this is only publicly exposed for use in tests // to start a job that was previously manually inserted into DB - StartService(ctx context.Context, spec Job) error + StartService(ctx context.Context, spec Job, qopts ...pg.QOpt) error } spawner struct { @@ -62,7 +62,7 @@ type ( // job. In case a given job type relies upon well-defined startup/shutdown // ordering for services, they are started in the order they are given // and stopped in reverse order. - ServicesForSpec(spec Job) ([]ServiceCtx, error) + ServicesForSpec(spec Job, qopts ...pg.QOpt) ([]ServiceCtx, error) AfterJobCreated(spec Job) BeforeJobDeleted(spec Job) // OnDeleteJob will be called from within DELETE db transaction. Any db @@ -176,7 +176,7 @@ func (js *spawner) stopService(jobID int32) { delete(js.activeJobs, jobID) } -func (js *spawner) StartService(ctx context.Context, jb Job) error { +func (js *spawner) StartService(ctx context.Context, jb Job, qopts ...pg.QOpt) error { js.activeJobsMu.Lock() defer js.activeJobsMu.Unlock() @@ -199,7 +199,7 @@ func (js *spawner) StartService(ctx context.Context, jb Job) error { jb.PipelineSpec.GasLimit = &jb.GasLimit.Uint32 } - srvs, err := delegate.ServicesForSpec(jb) + srvs, err := delegate.ServicesForSpec(jb, qopts...) if err != nil { js.lggr.Errorw("Error creating services for job", "jobID", jb.ID, "err", err) cctx, cancel := js.chStop.NewCtx() @@ -250,7 +250,7 @@ func (js *spawner) CreateJob(jb *Job, qopts ...pg.QOpt) (err error) { js.lggr.Infow("Created job", "type", jb.Type, "jobID", jb.ID) delegate.BeforeJobCreated(*jb) - err = js.StartService(pctx, *jb) + err = js.StartService(pctx, *jb, pg.WithQueryer(q.Queryer)) if err != nil { js.lggr.Errorw("Error starting job services", "type", jb.Type, "jobID", jb.ID, "err", err) } else { @@ -368,7 +368,7 @@ func (n *NullDelegate) JobType() Type { } // ServicesForSpec does no-op. -func (n *NullDelegate) ServicesForSpec(spec Job) (s []ServiceCtx, err error) { +func (n *NullDelegate) ServicesForSpec(spec Job, qopts ...pg.QOpt) (s []ServiceCtx, err error) { return } diff --git a/core/services/job/spawner_test.go b/core/services/job/spawner_test.go index 0e5b2b8991c..e0332079d23 100644 --- a/core/services/job/spawner_test.go +++ b/core/services/job/spawner_test.go @@ -27,6 +27,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/ocr" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" "github.com/smartcontractkit/chainlink/v2/core/services/relay" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" @@ -48,7 +49,7 @@ func (d delegate) JobType() job.Type { } // ServicesForSpec satisfies the job.Delegate interface. -func (d delegate) ServicesForSpec(js job.Job) ([]job.ServiceCtx, error) { +func (d delegate) ServicesForSpec(js job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { if js.Type != d.jobType { return nil, nil } diff --git a/core/services/keeper/delegate.go b/core/services/keeper/delegate.go index cebb8dba368..bb9de6c3eeb 100644 --- a/core/services/keeper/delegate.go +++ b/core/services/keeper/delegate.go @@ -54,7 +54,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec satisfies the job.Delegate interface. -func (d *Delegate) ServicesForSpec(spec job.Job) (services []job.ServiceCtx, err error) { +func (d *Delegate) ServicesForSpec(spec job.Job, qopts ...pg.QOpt) (services []job.ServiceCtx, err error) { if spec.KeeperSpec == nil { return nil, errors.Errorf("Delegate expects a *job.KeeperSpec to be present, got %v", spec) } diff --git a/core/services/ocr/delegate.go b/core/services/ocr/delegate.go index f64acb659cb..ebcd04952d2 100644 --- a/core/services/ocr/delegate.go +++ b/core/services/ocr/delegate.go @@ -87,7 +87,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec returns the OCR services that need to run for this job -func (d *Delegate) ServicesForSpec(jb job.Job) (services []job.ServiceCtx, err error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) (services []job.ServiceCtx, err error) { if jb.OCROracleSpec == nil { return nil, errors.Errorf("offchainreporting.Delegate expects an *job.OffchainreportingOracleSpec to be present, got %v", jb) } diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 4dbcbe85a4c..8cd0ef3fb18 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -293,7 +293,7 @@ func (d *Delegate) OnDeleteJob(jb job.Job, q pg.Queryer) error { for _, filter := range filters { d.lggr.Debugf("Unregistering %s filter", filter) - err = lp.UnregisterFilter(filter, q) + err = lp.UnregisterFilter(filter, pg.WithQueryer(q)) if err != nil { return errors.Wrapf(err, "Failed to unregister filter %s", filter) } @@ -302,7 +302,7 @@ func (d *Delegate) OnDeleteJob(jb job.Job, q pg.Queryer) error { } // ServicesForSpec returns the OCR2 services that need to run for this job -func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { spec := jb.OCR2OracleSpec if spec == nil { return nil, errors.Errorf("offchainreporting2.Delegate expects an *job.OCR2OracleSpec to be present, got %v", jb) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go index f9ac19207c0..752a9c3a709 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go @@ -37,7 +37,7 @@ func (p *logEventProvider) RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfi } func (p *logEventProvider) UnregisterFilter(upkeepID *big.Int) error { - err := p.poller.UnregisterFilter(p.filterName(upkeepID), nil) + err := p.poller.UnregisterFilter(p.filterName(upkeepID)) if err == nil { p.filterStore.RemoveActiveUpkeeps(upkeepFilter{ upkeepID: upkeepID, diff --git a/core/services/ocrbootstrap/delegate.go b/core/services/ocrbootstrap/delegate.go index f01e01a25dc..6d269a9067e 100644 --- a/core/services/ocrbootstrap/delegate.go +++ b/core/services/ocrbootstrap/delegate.go @@ -71,7 +71,7 @@ func (d *Delegate) BeforeJobCreated(spec job.Job) { } // ServicesForSpec satisfies the job.Delegate interface. -func (d *Delegate) ServicesForSpec(jobSpec job.Job) (services []job.ServiceCtx, err error) { +func (d *Delegate) ServicesForSpec(jobSpec job.Job, qopts ...pg.QOpt) (services []job.ServiceCtx, err error) { spec := jobSpec.BootstrapSpec if spec == nil { return nil, errors.Errorf("Bootstrap.Delegate expects an *job.BootstrapSpec to be present, got %v", jobSpec) diff --git a/core/services/vrf/delegate.go b/core/services/vrf/delegate.go index a4b5fd1a85d..5005eac9274 100644 --- a/core/services/vrf/delegate.go +++ b/core/services/vrf/delegate.go @@ -73,7 +73,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(spec job.Job, q pg.Queryer) error { return nil } // ServicesForSpec satisfies the job.Delegate interface. -func (d *Delegate) ServicesForSpec(jb job.Job) ([]job.ServiceCtx, error) { +func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { if jb.VRFSpec == nil || jb.PipelineSpec == nil { return nil, errors.Errorf("vrf.Delegate expects a VRFSpec and PipelineSpec to be present, got %+v", jb) } diff --git a/core/services/webhook/delegate.go b/core/services/webhook/delegate.go index 67b535a59d3..e373ff8087a 100644 --- a/core/services/webhook/delegate.go +++ b/core/services/webhook/delegate.go @@ -69,7 +69,7 @@ func (d *Delegate) BeforeJobDeleted(spec job.Job) { func (d *Delegate) OnDeleteJob(jb job.Job, q pg.Queryer) error { return nil } // ServicesForSpec satisfies the job.Delegate interface. -func (d *Delegate) ServicesForSpec(spec job.Job) ([]job.ServiceCtx, error) { +func (d *Delegate) ServicesForSpec(spec job.Job, qopts ...pg.QOpt) ([]job.ServiceCtx, error) { service := &pseudoService{ spec: spec, webhookJobRunner: d.webhookJobRunner, diff --git a/core/web/evm_forwarders_controller.go b/core/web/evm_forwarders_controller.go index b848c327647..68a46a58da7 100644 --- a/core/web/evm_forwarders_controller.go +++ b/core/web/evm_forwarders_controller.go @@ -91,7 +91,7 @@ func (cc *EVMForwardersController) Delete(c *gin.Context) { // handle same as non-existent chain id return nil } - return chain.LogPoller().UnregisterFilter(forwarders.FilterName(addr), tx) + return chain.LogPoller().UnregisterFilter(forwarders.FilterName(addr), pg.WithQueryer(tx)) } orm := forwarders.NewORM(cc.App.GetSqlxDB(), cc.App.GetLogger(), cc.App.GetConfig().Database()) From 388c8f0417744624c1afb13fdaec370825a8ed6a Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Wed, 16 Aug 2023 13:30:48 +0300 Subject: [PATCH 182/270] fix geth healthcheck (#10209) --- integration-tests/docker/test_env/geth.go | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index f6c5f36e767..5831bf92053 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -3,8 +3,6 @@ package test_env import ( "context" "fmt" - "time" - "os" "github.com/ethereum/go-ethereum/accounts" @@ -16,6 +14,7 @@ import ( "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" + "time" ) const ( @@ -159,9 +158,8 @@ func (g *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, Image: "ethereum/client-go:stable", ExposedPorts: []string{"8544/tcp", "8545/tcp"}, Networks: networks, - WaitingFor: tcwait.ForHTTP("/"). - WithPort("8544/tcp"). - WithStartupTimeout(120 * time.Second). + WaitingFor: tcwait.ForListeningPort("8545/tcp"). + WithStartupTimeout(60 * time.Second). WithPollInterval(1 * time.Second), Entrypoint: []string{"sh", "./root/init.sh", "--dev", From 1b09b8baa522a9aa0291a7062780846d6dce04e7 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Wed, 16 Aug 2023 07:42:30 -0500 Subject: [PATCH 183/270] core/scripts/chaincli/handler: fix CSAKeyInfo.Equals (#10216) --- core/scripts/chaincli/handler/scrape_node_config.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/scripts/chaincli/handler/scrape_node_config.go b/core/scripts/chaincli/handler/scrape_node_config.go index 932a03ea77a..65b94147d9d 100644 --- a/core/scripts/chaincli/handler/scrape_node_config.go +++ b/core/scripts/chaincli/handler/scrape_node_config.go @@ -27,7 +27,7 @@ type CSAKeyInfo struct { } func (ci *CSAKeyInfo) Equals(ci2 *CSAKeyInfo) bool { - return ci.PublicKey == ci2.PublicKey && ci.NodeAddress == ci.NodeAddress + return ci.PublicKey == ci2.PublicKey && ci.NodeAddress == ci2.NodeAddress } type NodeInfo struct { From 6d77aea15b0610d5bfa8a987b594feb94f6be73b Mon Sep 17 00:00:00 2001 From: Anirudh Warrier Date: Wed, 16 Aug 2023 18:18:58 +0530 Subject: [PATCH 184/270] update automation scrape_node_config (#10220) --- core/scripts/chaincli/handler/scrape_node_config.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/scripts/chaincli/handler/scrape_node_config.go b/core/scripts/chaincli/handler/scrape_node_config.go index 65b94147d9d..f00beb4b4fe 100644 --- a/core/scripts/chaincli/handler/scrape_node_config.go +++ b/core/scripts/chaincli/handler/scrape_node_config.go @@ -34,11 +34,11 @@ type NodeInfo struct { AdminAddress common.Address `json:"adminAddress"` CSAKeys []*CSAKeyInfo `json:"csaKeys"` DisplayName string `json:"displayName"` - NodeAddress []string `json:"nodeAddress"` Ocr2ConfigPublicKey []string `json:"ocr2ConfigPublicKey"` Ocr2Id []string `json:"ocr2Id"` Ocr2OffchainPublicKey []string `json:"ocr2OffchainPublicKey"` Ocr2OnchainPublicKey []string `json:"ocr2OnchainPublicKey"` + NodeAddress []string `json:"ocrNodeAddress"` OcrSigningAddress []string `json:"ocrSigningAddress"` PayeeAddress common.Address `json:"payeeAddress"` PeerId []string `json:"peerId"` @@ -243,7 +243,7 @@ func (h *baseHandler) scrapeNodeInfo(wg *sync.WaitGroup, i int, cl cmd.HTTPClien // CSA key for each chain. but this is still pending so assume only 1 CSA key on a node for now. csaKey := &CSAKeyInfo{ NodeAddress: nodeAddresses[0], - PublicKey: (*csaKeys)[0].PubKey, + PublicKey: strings.TrimPrefix((*csaKeys)[0].PubKey, "csa_"), } ni := &NodeInfo{ CSAKeys: []*CSAKeyInfo{csaKey}, From 3ee6f7fdfbba332242727228b8f9a25feca0084d Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Wed, 16 Aug 2023 08:06:37 -0500 Subject: [PATCH 185/270] .github/workflows: fix slack race conditional (#10221) --- .github/workflows/ci-core.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 18f10669642..6d243a62322 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -228,7 +228,7 @@ jobs: if: needs.core.result != 'success' run: exit 1 - name: Notify Slack - if: failure() && ${{ matrix.cmd }} == 'go_core_race_tests' && github.event.schedule != '' + if: ${{ failure() && matrix.cmd == 'go_core_race_tests' && github.event.schedule != '' }} uses: slackapi/slack-github-action@e28cf165c92ffef168d23c5c9000cffc8a25e117 # v1.24.0 env: SLACK_BOT_TOKEN: ${{ secrets.QA_SLACK_API_KEY }} From 0ead390c5065e332abc3d6f8c56960b6120d6d06 Mon Sep 17 00:00:00 2001 From: ferglor <19188060+ferglor@users.noreply.github.com> Date: Wed, 16 Aug 2023 14:46:17 +0100 Subject: [PATCH 186/270] Remove the block ticker from keepers (#10223) * Remove the block ticker from keepers * update to tag --------- Co-authored-by: Akshay Aggarwal Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index e1ca822a887..51e9a0b0f79 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.9 + github.com/smartcontractkit/ocr2keepers v0.7.10 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 7a6f462181b..8816f7f0b25 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.9 h1:Jh6LJci3vEnEZWV/T13rJRvT/CLSHX90LRLB8ISFyuQ= -github.com/smartcontractkit/ocr2keepers v0.7.9/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= +github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/go.mod b/go.mod index a38b5a47c63..ca2ba97ff99 100644 --- a/go.mod +++ b/go.mod @@ -70,7 +70,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.9 + github.com/smartcontractkit/ocr2keepers v0.7.10 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index 19f3d1cf8d8..9ef41e1e2c8 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.9 h1:Jh6LJci3vEnEZWV/T13rJRvT/CLSHX90LRLB8ISFyuQ= -github.com/smartcontractkit/ocr2keepers v0.7.9/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= +github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 88aca866beb..df0f1939569 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.3 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 - github.com/smartcontractkit/ocr2keepers v0.7.9 + github.com/smartcontractkit/ocr2keepers v0.7.10 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.9 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 1c750a7cbcd..e7af499b5b8 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.9 h1:Jh6LJci3vEnEZWV/T13rJRvT/CLSHX90LRLB8ISFyuQ= -github.com/smartcontractkit/ocr2keepers v0.7.9/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= +github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From 725a0f912a5555a3fa50f3941b51ade20c27fc07 Mon Sep 17 00:00:00 2001 From: Tate Date: Wed, 16 Aug 2023 08:10:23 -0600 Subject: [PATCH 187/270] [TT-519] Add Cache Fix to Docker tests (#10225) --- .github/workflows/integration-tests.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 3609e00e978..e099b9216dc 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -202,6 +202,7 @@ jobs: with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod + matrix_id: ${{ matrix.product.name }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -389,7 +390,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.8 env: PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} @@ -411,7 +412,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.7 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.8 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod From 85e5ce9387e4e15f0dc2a192342b82b59b355d96 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Wed, 16 Aug 2023 10:13:27 -0500 Subject: [PATCH 188/270] core: sonar cleanup (#10217) --- core/internal/cltest/mocks.go | 14 ++++---------- .../functions/src/generate_ocr2_config_cmd.go | 19 +++++-------------- core/web/eth_keys_controller.go | 5 +---- 3 files changed, 10 insertions(+), 28 deletions(-) diff --git a/core/internal/cltest/mocks.go b/core/internal/cltest/mocks.go index f3a8cdc74cf..295ad366d04 100644 --- a/core/internal/cltest/mocks.go +++ b/core/internal/cltest/mocks.go @@ -135,7 +135,9 @@ type MockCountingPrompter struct { } // Prompt returns an entered string -func (p *MockCountingPrompter) Prompt(string) string { +func (p *MockCountingPrompter) Prompt(string) string { return p.prompt() } + +func (p *MockCountingPrompter) prompt() string { i := p.Count p.Count++ if len(p.EnteredStrings)-1 < i { @@ -146,15 +148,7 @@ func (p *MockCountingPrompter) Prompt(string) string { } // PasswordPrompt returns an entered string -func (p *MockCountingPrompter) PasswordPrompt(string) string { - i := p.Count - p.Count++ - if len(p.EnteredStrings)-1 < i { - p.T.Errorf("Not enough passwords supplied to MockCountingPrompter, wanted %d", i) - p.T.FailNow() - } - return p.EnteredStrings[i] -} +func (p *MockCountingPrompter) PasswordPrompt(string) string { return p.prompt() } // IsTerminal always returns true in tests func (p *MockCountingPrompter) IsTerminal() bool { diff --git a/core/scripts/functions/src/generate_ocr2_config_cmd.go b/core/scripts/functions/src/generate_ocr2_config_cmd.go index 2681adfcd6b..0310360fbe2 100644 --- a/core/scripts/functions/src/generate_ocr2_config_cmd.go +++ b/core/scripts/functions/src/generate_ocr2_config_cmd.go @@ -102,23 +102,14 @@ func (g *generateOCR2Config) Name() string { } func mustParseJSONConfigFile(fileName string) (output TopLevelConfigSource) { - jsonFile, err := os.Open(fileName) - if err != nil { - panic(err) - } - defer jsonFile.Close() - bytes, err := io.ReadAll(jsonFile) - if err != nil { - panic(err) - } - err = json.Unmarshal(bytes, &output) - if err != nil { - panic(err) - } - return + return mustParseJSON[TopLevelConfigSource](fileName) } func mustParseKeysFile(fileName string) (output []NodeKeys) { + return mustParseJSON[[]NodeKeys](fileName) +} + +func mustParseJSON[T any](fileName string) (output T) { jsonFile, err := os.Open(fileName) if err != nil { panic(err) diff --git a/core/web/eth_keys_controller.go b/core/web/eth_keys_controller.go index f37254c6ba2..01c893708ff 100644 --- a/core/web/eth_keys_controller.go +++ b/core/web/eth_keys_controller.go @@ -425,10 +425,7 @@ func (ekc *ETHKeysController) getKeyMaxGasPriceWei(state ethkey.State, keyAddres func (ekc *ETHKeysController) getChain(c *gin.Context, cs evm.ChainSet, chainIDstr string) (chain evm.Chain, ok bool) { chain, err := getChain(ekc.app.GetChains().EVM, chainIDstr) if err != nil { - if errors.Is(err, ErrInvalidChainID) { - jsonAPIError(c, http.StatusBadRequest, err) - return nil, false - } else if errors.Is(err, ErrMultipleChains) { + if errors.Is(err, ErrInvalidChainID) || errors.Is(err, ErrMultipleChains) { jsonAPIError(c, http.StatusBadRequest, err) return nil, false } else if errors.Is(err, ErrMissingChainID) { From 62cac0c3fe3e237647cbab4a07eb7859cbbe53f4 Mon Sep 17 00:00:00 2001 From: Chris Cushman <104409744+vreff@users.noreply.github.com> Date: Wed, 16 Aug 2023 11:15:21 -0400 Subject: [PATCH 189/270] Make script for trusted BHS (#10133) * Trusted BHS * Make trustedblockhash store extend blockhashstore so that no changes to the coordinator are required. * Prettier on vendored blockhashstore file * Fix whitelist to use mapping from constructor, and add foundry tests * prettier * Update gethwrapper * Resolve merge conflicts * Update migration * Fix trusted BHS job validation * Add integration tests * Fix validate error * Fix delegate nil pointer * Update contracts/test/v0.8/foundry/vrf/TrustedBlockhashStore.t.sol fix typo Co-authored-by: Sam * Fix shadowed test variable warning * Remove accidentally required field * Beef up multithreadedness * Make trusted timeout a const instead of var * Update core/services/blockhashstore/feeder.go Co-authored-by: Makram * Use zero address instead of long zero hex * Update migration number * Re-add required batch size type * Make script for trusted BHS * Add required flags to v2plus superscript * Address comments and fix issues --------- Co-authored-by: Sam Co-authored-by: Makram --- core/scripts/common/helpers.go | 17 ++++--- core/scripts/vrfv2/testnet/main.go | 9 ++-- core/scripts/vrfv2plus/testnet/main.go | 48 ++++++++++++++++++- .../vrfv2plus/testnet/super_scripts.go | 2 +- 4 files changed, 63 insertions(+), 13 deletions(-) diff --git a/core/scripts/common/helpers.go b/core/scripts/common/helpers.go index e761fea5692..c5d6499b2fd 100644 --- a/core/scripts/common/helpers.go +++ b/core/scripts/common/helpers.go @@ -413,10 +413,15 @@ func BinarySearch(top, bottom *big.Int, test func(amount *big.Int) bool) *big.In // Get RLP encoded headers of a list of block numbers // Makes RPC network call eth_getBlockByNumber to blockchain RPC node // to fetch header info -func GetRlpHeaders(env Environment, blockNumbers []*big.Int) (headers [][]byte, hashes []string, err error) { +func GetRlpHeaders(env Environment, blockNumbers []*big.Int, getParentBlocks bool) (headers [][]byte, hashes []string, err error) { hashes = make([]string, 0) + var offset *big.Int = big.NewInt(0) + if getParentBlocks { + offset = big.NewInt(1) + } + headers = [][]byte{} var rlpHeader []byte for _, blockNum := range blockNumbers { @@ -426,7 +431,7 @@ func GetRlpHeaders(env Environment, blockNumbers []*big.Int) (headers [][]byte, // Get child block since it's the one that has the parent hash in its header. h, err := env.AvaxEc.HeaderByNumber( context.Background(), - new(big.Int).Set(blockNum).Add(blockNum, big.NewInt(1)), + new(big.Int).Set(blockNum).Add(blockNum, offset), ) if err != nil { return nil, hashes, fmt.Errorf("failed to get header: %+v", err) @@ -445,12 +450,12 @@ func GetRlpHeaders(env Environment, blockNumbers []*big.Int) (headers [][]byte, //bh := crypto.Keccak256Hash(rlpHeader) //fmt.Println("Calculated BH:", bh.String(), // "fetched BH:", h.Hash(), - // "block number:", new(big.Int).Set(blockNum).Add(blockNum, big.NewInt(1)).String()) + // "block number:", new(big.Int).Set(blockNum).Add(blockNum, offset).String()) } else if IsPolygonEdgeNetwork(env.ChainID) { // Get child block since it's the one that has the parent hash in its header. - nextBlockNum := new(big.Int).Set(blockNum).Add(blockNum, big.NewInt(1)) + nextBlockNum := new(big.Int).Set(blockNum).Add(blockNum, offset) var hash string rlpHeader, hash, err = GetPolygonEdgeRLPHeader(env.Jc, nextBlockNum) if err != nil { @@ -463,7 +468,7 @@ func GetRlpHeaders(env Environment, blockNumbers []*big.Int) (headers [][]byte, // Get child block since it's the one that has the parent hash in its header. h, err := env.Ec.HeaderByNumber( context.Background(), - new(big.Int).Set(blockNum).Add(blockNum, big.NewInt(1)), + new(big.Int).Set(blockNum).Add(blockNum, offset), ) if err != nil { return nil, hashes, fmt.Errorf("failed to get header: %+v", err) @@ -501,7 +506,7 @@ func CalculateLatestBlockHeader(env Environment, blockNumberInput int) (err erro blockNumber = blockNumber - 1 blockNumberBigInts := []*big.Int{big.NewInt(int64(blockNumber))} - headers, hashes, err := GetRlpHeaders(env, blockNumberBigInts) + headers, hashes, err := GetRlpHeaders(env, blockNumberBigInts, true) if err != nil { fmt.Println(err) return err diff --git a/core/scripts/vrfv2/testnet/main.go b/core/scripts/vrfv2/testnet/main.go index f23faca638f..d30c0e7fca3 100644 --- a/core/scripts/vrfv2/testnet/main.go +++ b/core/scripts/vrfv2/testnet/main.go @@ -6,13 +6,14 @@ import ( "encoding/hex" "flag" "fmt" - "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/scripts" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_owner_test_consumer" "log" "math/big" "os" "strings" + "github.com/smartcontractkit/chainlink/core/scripts/vrfv2/testnet/scripts" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_owner_test_consumer" + "github.com/ethereum/go-ethereum" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" @@ -386,7 +387,7 @@ func main() { helpers.PanicErr(err) blockRange, err := blockhashstore.DecreasingBlockRange(big.NewInt(*startBlock-1), big.NewInt(*startBlock-*numBlocks-1)) helpers.PanicErr(err) - rlpHeaders, _, err := helpers.GetRlpHeaders(e, blockRange) + rlpHeaders, _, err := helpers.GetRlpHeaders(e, blockRange, true) helpers.PanicErr(err) tx, err := batchBHS.StoreVerifyHeader(e.Owner, blockRange, rlpHeaders) helpers.PanicErr(err) @@ -461,7 +462,7 @@ func main() { fmt.Println("using gas price", e.Owner.GasPrice, "wei") blockNumbers := blockRange[i:j] - blockHeaders, _, err := helpers.GetRlpHeaders(e, blockNumbers) + blockHeaders, _, err := helpers.GetRlpHeaders(e, blockNumbers, true) fmt.Println("storing blockNumbers:", blockNumbers) helpers.PanicErr(err) diff --git a/core/scripts/vrfv2plus/testnet/main.go b/core/scripts/vrfv2plus/testnet/main.go index 92804aeaa26..20e7ea92714 100644 --- a/core/scripts/vrfv2plus/testnet/main.go +++ b/core/scripts/vrfv2plus/testnet/main.go @@ -27,6 +27,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/batch_vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/blockhash_store" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/trusted_blockhash_store" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_coordinator_v2plus" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_load_test_external_sub_owner" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/vrf_load_test_with_metrics" @@ -320,7 +321,7 @@ func main() { helpers.PanicErr(err) blockRange, err := blockhashstore.DecreasingBlockRange(big.NewInt(*startBlock-1), big.NewInt(*startBlock-*numBlocks-1)) helpers.PanicErr(err) - rlpHeaders, _, err := helpers.GetRlpHeaders(e, blockRange) + rlpHeaders, _, err := helpers.GetRlpHeaders(e, blockRange, true) helpers.PanicErr(err) tx, err := batchBHS.StoreVerifyHeader(e.Owner, blockRange, rlpHeaders) helpers.PanicErr(err) @@ -395,7 +396,7 @@ func main() { fmt.Println("using gas price", e.Owner.GasPrice, "wei") blockNumbers := blockRange[i:j] - blockHeaders, _, err := helpers.GetRlpHeaders(e, blockNumbers) + blockHeaders, _, err := helpers.GetRlpHeaders(e, blockNumbers, true) fmt.Println("storing blockNumbers:", blockNumbers) helpers.PanicErr(err) @@ -411,6 +412,49 @@ func main() { fmt.Println("received receipt, continuing") } fmt.Println("done") + case "trusted-bhs-store": + cmd := flag.NewFlagSet("trusted-bhs-backwards", flag.ExitOnError) + trustedBHSAddr := cmd.String("trusted-bhs-address", "", "address of the trusted bhs contract") + blockNumbersString := cmd.String("block-numbers", "", "comma-separated list of block numbers e.g 123,456 ") + batchSizePtr := cmd.Int64("batch-size", -1, "batch size") + helpers.ParseArgs(cmd, os.Args[2:], "trusted-bhs-address", "batch-size", "block-numbers") + + // Parse batch size. + batchSize := int(*batchSizePtr) + + // Parse block numbers. + blockNumbers := helpers.ParseBigIntSlice(*blockNumbersString) + + // Instantiate trusted bhs. + trustedBHS, err := trusted_blockhash_store.NewTrustedBlockhashStore(common.HexToAddress(*trustedBHSAddr), e.Ec) + helpers.PanicErr(err) + + for i := 0; i < len(blockNumbers); i += batchSize { + // Get recent blockhash and block number anew each iteration. We do this so they do not get stale. + recentBlockNumber, err := e.Ec.BlockNumber(context.Background()) + helpers.PanicErr(err) + recentBlock, err := e.Ec.HeaderByNumber(context.Background(), big.NewInt(int64(recentBlockNumber))) + helpers.PanicErr(err) + recentBlockhash := recentBlock.Hash() + + // Get blockhashes to store. + blockNumbersSlice := blockNumbers[i : i+batchSize] + _, blockhashesStrings, err := helpers.GetRlpHeaders(e, blockNumbersSlice, false) + helpers.PanicErr(err) + fmt.Println("storing blockNumbers:", blockNumbers) + var blockhashes [][32]byte + for _, h := range blockhashesStrings { + blockhashes = append(blockhashes, common.HexToHash(h)) + } + + // Execute storage tx. + tx, err := trustedBHS.StoreTrusted(e.Owner, blockNumbersSlice, blockhashes, big.NewInt(int64(recentBlockNumber)), recentBlockhash) + helpers.PanicErr(err) + fmt.Println("waiting for it to mine...") + helpers.ConfirmTXMined(context.Background(), e.Ec, tx, e.ChainID) + fmt.Println("received receipt, continuing") + } + fmt.Println("done") case "latest-head": h, err := e.Ec.HeaderByNumber(context.Background(), nil) helpers.PanicErr(err) diff --git a/core/scripts/vrfv2plus/testnet/super_scripts.go b/core/scripts/vrfv2plus/testnet/super_scripts.go index c5814195945..a617733cb19 100644 --- a/core/scripts/vrfv2plus/testnet/super_scripts.go +++ b/core/scripts/vrfv2plus/testnet/super_scripts.go @@ -81,7 +81,7 @@ func deployUniverse(e helpers.Environment) { flatFeeEthPPM := deployCmd.Int64("flat-fee-eth-ppm", 500, "fulfillment flat fee ETH ppm") helpers.ParseArgs( - deployCmd, os.Args[2:], + deployCmd, os.Args[2:], "uncompressed-pub-key", "oracle-address", ) fallbackWeiPerUnitLink := decimal.RequireFromString(*fallbackWeiPerUnitLinkString).BigInt() From 96f4baccdc2baca6ce30a78ad72a364e9b470235 Mon Sep 17 00:00:00 2001 From: Andrei Smirnov Date: Wed, 16 Aug 2023 18:53:07 +0300 Subject: [PATCH 190/270] Functions: small fixes in scripts (#10218) * Functions: small fixes * Fixed test * Addressed PR feedback --- .../functions/src/generate_jobspecs_cmd.go | 6 ++++-- core/scripts/functions/src/sample_config.json | 1 + core/scripts/functions/templates/oracle.toml | 20 +++++++++++++------ 3 files changed, 19 insertions(+), 8 deletions(-) diff --git a/core/scripts/functions/src/generate_jobspecs_cmd.go b/core/scripts/functions/src/generate_jobspecs_cmd.go index 8d4837b8e8f..d7de2da3b55 100644 --- a/core/scripts/functions/src/generate_jobspecs_cmd.go +++ b/core/scripts/functions/src/generate_jobspecs_cmd.go @@ -28,6 +28,7 @@ func (g *generateJobSpecs) Run(args []string) { nodesFile := fs.String("nodes", "", "a file containing nodes urls, logins and passwords") chainID := fs.Int64("chainid", 80001, "chain id") p2pPort := fs.Int64("p2pport", 6690, "p2p port") + donID := fs.String("donid", "", "don ID string") contractAddress := fs.String("contract", "", "oracle contract address") truncateHostname := fs.Bool("truncateboothostname", false, "truncate host name to first segment (needed for staging DONs)") err := fs.Parse(args) @@ -53,7 +54,7 @@ func (g *generateJobSpecs) Run(args []string) { lines, err = readLines(filepath.Join(templatesDir, oracleSpecTemplate)) helpers.PanicErr(err) for i := 1; i < len(nodes); i++ { - oracleLines := replacePlaceholders(lines, *chainID, *p2pPort, *contractAddress, bootHost, &bootstrapNode, &nca[i], *truncateHostname) + oracleLines := replacePlaceholders(lines, donID, *chainID, *p2pPort, *contractAddress, bootHost, &bootstrapNode, &nca[i], *truncateHostname) outputPath := filepath.Join(artefactsDir, nodes[i].url.Host+".toml") err = writeLines(oracleLines, outputPath) helpers.PanicErr(err) @@ -61,7 +62,7 @@ func (g *generateJobSpecs) Run(args []string) { } } -func replacePlaceholders(lines []string, chainID, p2pPort int64, contractAddress, bootHost string, boot *NodeKeys, node *NodeKeys, truncateHostname bool) (output []string) { +func replacePlaceholders(lines []string, donID string, chainID, p2pPort int64, contractAddress, bootHost string, boot *NodeKeys, node *NodeKeys, truncateHostname bool) (output []string) { chainIDStr := strconv.FormatInt(chainID, 10) if truncateHostname { bootHost = bootHost[:strings.IndexByte(bootHost, '.')] @@ -75,6 +76,7 @@ func replacePlaceholders(lines []string, chainID, p2pPort int64, contractAddress l = strings.Replace(l, "{{ocr2_key_bundle_id}}", node.OCR2BundleID, 1) l = strings.Replace(l, "{{p2p_bootstrapper}}", bootstrapper, 1) l = strings.Replace(l, "{{timestamp}}", ts, 1) + l = strings.Replace(l, "{{don_id}}", donID, 1) output = append(output, l) } return diff --git a/core/scripts/functions/src/sample_config.json b/core/scripts/functions/src/sample_config.json index 5c5dcacc4c4..474000a7adb 100644 --- a/core/scripts/functions/src/sample_config.json +++ b/core/scripts/functions/src/sample_config.json @@ -6,6 +6,7 @@ "MaxRequestBatchSize": 10, "DefaultAggregationMethod": 0, "UniqueReports": true, + "MaxReportTotalCallbackGas": 2000000, "ThresholdOffchainConfig": { "MaxQueryLengthBytes": 10000, diff --git a/core/scripts/functions/templates/oracle.toml b/core/scripts/functions/templates/oracle.toml index 9e4b3704ad8..47465cbaa08 100644 --- a/core/scripts/functions/templates/oracle.toml +++ b/core/scripts/functions/templates/oracle.toml @@ -11,17 +11,25 @@ relay = "evm" pluginType = "functions" transmitterID = "{{node_eth_address}}" observationSource = """ - run_computation [type="bridge" name="ea_bridge" requestData="{\\"note\\": \\"observationSource is unused but the bridge is required\\"}"] - run_computation + run_computation [type="bridge" name="ea_bridge" requestData="{\\"note\\": \\"observationSource is unused but the bridge is required\\"}"] + run_computation """ [relayConfig] chainID = {{chain_id}} [pluginConfig] +contractUpdateCheckFrequencySec = 300 +contractVersion = 1 +donID = "{{don_id}}" +enableRequestSignatureCheck = false +listenerEventHandlerTimeoutSec = 180 +listenerEventsCheckFrequencyMillis = 500 +maxRequestSizeBytes = 30_720 minIncomingConfirmations = 3 -requestTimeoutSec = 300 -requestTimeoutCheckFrequencySec = 10 +pruneBatchSize = 5 +pruneCheckFrequencySec = 30 +pruneMaxStoredRequests = 20 requestTimeoutBatchLookupSize = 20 -listenerEventHandlerTimeoutSec = 120 -maxRequestSizeBytes = 30720 +requestTimeoutCheckFrequencySec = 10 +requestTimeoutSec = 300 From 381ea408018e084889df1e9fa849d6d0638a9880 Mon Sep 17 00:00:00 2001 From: Sergei Drugalev Date: Wed, 16 Aug 2023 20:35:37 +0200 Subject: [PATCH 191/270] Mercury multischema support (#9715) * Moving the existing report functionality into v1 * Mecruty v2 report initial structure * Mercury provider to differentiate between report schemas * Splitting data_source and report codecs * Adding report schema config and fixing bild * Updated chainlink-relay version * Minor renamings + cleanup * Module renaming according to the new structure * Default to schema version 0 * ReportCodec.Observe for report schema v1 * Cleaning up data_source from report schema v1 * Bumping up the relay version * Implement billing * Bumping up the relay version * Bumping up relay version * adding LatestTimestamp method to mercury transmitter * Fix chicken and egg problem on brand new LINK/USD or ETH/USD feeds * Adjust logic * Make logic clearer * Bumping up relay version + fixing tests * mercury_v1 maxReportLength * Fixing v0 report_codec tests * v1 data source tests * v1 report_codec tests * v1 transmitter tests + cleanup * Mercury test helpers into a separate file * Fixing test build after the merge * Renaming mercury report versions + relay bump * WIP * Fix integration test with offchain config * Uncommenting orm/persistence failing tests * compiles/test * reportcodecrename * ReportDecoder module * Decoding report schema from feedId * OCR job specs separated for testing * Plugin config validation update * Fixing Mercury feedId for job_orm_test * Mercury integration test v1 with new contracts * Cleaning up mercury v2 integration tests * Clening up Mercury v3 integration test * Fixing linter errors * Fixing linter errors * Bumping chainlink-relay version in integration tests * Bumping up chainlink-relay version * Addressing review comments * Fixing ident lint errors * Mercury toml config tests * Mercury report decoder feedId prefix types * Mercury report decoder types cleanup * Telemetry tickets added todo * Exposing DecodeSchemaVersionFromFeedId on mercury report decoder * Fixing prometheum metric on error from mercury server * Mercury report decoder exposes pure DecodeV1,DecodeV2,DecodeV3 * Address PR comments * use custom type * Remove unused code * Reducing duplicated lines in data_source_test * wip * fix report codec test * Cleanup decode step * Concurrency for v2/v3 observations * wip * wip * w * All tests passing * fix lint --------- Co-authored-by: Sam Davies --- core/cmd/eth_keys_commands.go | 2 +- core/internal/testutils/testutils.go | 10 + core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/services/job/job_orm_test.go | 4 +- core/services/ocr2/delegate.go | 3 +- .../ocr2/plugins/mercury/config/config.go | 35 +- .../plugins/mercury/config/config_test.go | 140 ++- .../ocr2/plugins/mercury/helpers_test.go | 465 +++++++++ .../ocr2/plugins/mercury/integration_test.go | 911 ++++++++++++------ core/services/ocr2/plugins/mercury/plugin.go | 102 +- core/services/ocr2/validate/validate.go | 6 +- core/services/ocrcommon/telemetry.go | 8 +- core/services/ocrcommon/telemetry_test.go | 11 +- core/services/relay/evm/evm.go | 13 +- .../relay/evm/mercury/config_poller.go | 3 +- .../services/relay/evm/mercury/helper_test.go | 83 -- .../relay/evm/mercury/helpers_test.go | 188 +++- .../evm/mercury/mocks/chain_head_tracker.go | 12 +- .../relay/evm/mercury/mocks/pipeline.go | 39 + .../evm/mercury/offchain_config_digester.go | 19 +- core/services/relay/evm/mercury/orm.go | 18 +- core/services/relay/evm/mercury/orm_test.go | 17 + .../evm/mercury/reportcodec/factories_test.go | 94 -- .../relay/evm/mercury/test_helpers.go | 39 + .../services/relay/evm/mercury/transmitter.go | 106 +- .../relay/evm/mercury/transmitter_test.go | 166 +++- .../services/relay/evm/mercury/types/types.go | 49 + .../relay/evm/mercury/types/types_test.go | 30 + .../relay/evm/mercury/{ => v1}/data_source.go | 39 +- .../evm/mercury/{ => v1}/data_source_test.go | 92 +- .../{ => v1}/reportcodec/report_codec.go | 66 +- .../{ => v1}/reportcodec/report_codec_test.go | 171 ++-- .../relay/evm/mercury/v2/data_source.go | 215 +++++ .../relay/evm/mercury/v2/data_source_test.go | 231 +++++ .../mercury/v2/reportcodec/report_codec.go | 127 +++ .../v2/reportcodec/report_codec_test.go | 120 +++ .../relay/evm/mercury/v3/data_source.go | 253 +++++ .../relay/evm/mercury/v3/data_source_test.go | 259 +++++ .../mercury/v3/reportcodec/report_codec.go | 139 +++ .../v3/reportcodec/report_codec_test.go | 126 +++ core/services/relay/evm/mercury_provider.go | 27 +- core/utils/hash.go | 40 + core/utils/hash_test.go | 65 ++ go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 48 files changed, 3665 insertions(+), 896 deletions(-) create mode 100644 core/services/ocr2/plugins/mercury/helpers_test.go delete mode 100644 core/services/relay/evm/mercury/helper_test.go create mode 100644 core/services/relay/evm/mercury/mocks/pipeline.go delete mode 100644 core/services/relay/evm/mercury/reportcodec/factories_test.go create mode 100644 core/services/relay/evm/mercury/test_helpers.go create mode 100644 core/services/relay/evm/mercury/types/types.go create mode 100644 core/services/relay/evm/mercury/types/types_test.go rename core/services/relay/evm/mercury/{ => v1}/data_source.go (87%) rename core/services/relay/evm/mercury/{ => v1}/data_source_test.go (88%) rename core/services/relay/evm/mercury/{ => v1}/reportcodec/report_codec.go (70%) rename core/services/relay/evm/mercury/{ => v1}/reportcodec/report_codec_test.go (62%) create mode 100644 core/services/relay/evm/mercury/v2/data_source.go create mode 100644 core/services/relay/evm/mercury/v2/data_source_test.go create mode 100644 core/services/relay/evm/mercury/v2/reportcodec/report_codec.go create mode 100644 core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go create mode 100644 core/services/relay/evm/mercury/v3/data_source.go create mode 100644 core/services/relay/evm/mercury/v3/data_source_test.go create mode 100644 core/services/relay/evm/mercury/v3/reportcodec/report_codec.go create mode 100644 core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go create mode 100644 core/utils/hash.go create mode 100644 core/utils/hash_test.go diff --git a/core/cmd/eth_keys_commands.go b/core/cmd/eth_keys_commands.go index 0462cd5ca82..e5f1f025966 100644 --- a/core/cmd/eth_keys_commands.go +++ b/core/cmd/eth_keys_commands.go @@ -169,7 +169,7 @@ func (ps EthKeyPresenters) RenderTable(rt RendererTable) error { // ListETHKeys renders the active account address with its ETH & LINK balance func (s *Shell) ListETHKeys(_ *cli.Context) (err error) { resp, err := s.HTTP.Get("/v2/keys/evm") - + if err != nil { return s.errorOut(err) } diff --git a/core/internal/testutils/testutils.go b/core/internal/testutils/testutils.go index 58d6afd4ea0..447475251c4 100644 --- a/core/internal/testutils/testutils.go +++ b/core/internal/testutils/testutils.go @@ -4,6 +4,7 @@ import ( "context" "crypto/ecdsa" "crypto/rand" + "encoding/base64" "flag" "fmt" "math" @@ -440,3 +441,12 @@ func NewTestFlagSet() *flag.FlagSet { func Ptr[T any](v T) *T { return &v } + +func MustDecodeBase64(s string) (b []byte) { + var err error + b, err = base64.StdEncoding.DecodeString(s) + if err != nil { + panic(err) + } + return +} diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 51e9a0b0f79..2510ec540e4 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -298,7 +298,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 8816f7f0b25..94ae5ba7d3a 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1430,8 +1430,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a h1:8lHQYdub7q3LgD5ebQOA+usDyUqqiHvKEJPGQ8+FxMA= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a/go.mod h1:Nt4mQh6z6q26jrM4FyQLq/2vBp1Sg3l5md3tBRdRLxg= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/core/services/job/job_orm_test.go b/core/services/job/job_orm_test.go index b707fef3122..3ea11f25ea9 100644 --- a/core/services/job/job_orm_test.go +++ b/core/services/job/job_orm_test.go @@ -1047,8 +1047,8 @@ func Test_FindJob(t *testing.T) { jobOCR2.OCR2OracleSpec.PluginConfig["juelsPerFeeCoinSource"] = juelsPerFeeCoinSource - ocr2WithFeedID1 := "0x0000000000000000000000000000000000000000000000000000000000000001" - ocr2WithFeedID2 := "0x0000000000000000000000000000000000000000000000000000000000000002" + ocr2WithFeedID1 := "0x0001000000000000000000000000000000000000000000000000000000000001" + ocr2WithFeedID2 := "0x0001000000000000000000000000000000000000000000000000000000000002" jobOCR2WithFeedID1, err := ocr2validate.ValidatedOracleSpecToml( config.OCR2(), config.Insecure(), diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 8cd0ef3fb18..1aa5b11450f 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -63,6 +63,7 @@ import ( evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" functionsRelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" evmmercury "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" + evmmercurytypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" evmrelaytypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization" "github.com/smartcontractkit/chainlink/v2/core/services/telemetry" @@ -527,7 +528,7 @@ func (d *Delegate) newServicesMercury( chEnhancedTelem := make(chan ocrcommon.EnhancedTelemetryMercuryData, 100) - mercuryServices, err2 := mercury.NewServices(jb, mercuryProvider, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, d.cfg.JobPipeline(), chEnhancedTelem, chain, d.mercuryORM, *spec.FeedID) + mercuryServices, err2 := mercury.NewServices(jb, mercuryProvider, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, d.cfg.JobPipeline(), chEnhancedTelem, chain, d.mercuryORM, (evmmercurytypes.FeedID)(*spec.FeedID)) if ocrcommon.ShouldCollectEnhancedTelemetryMercury(&jb) { enhancedTelemService := ocrcommon.NewEnhancedTelemetryService(&jb, chEnhancedTelem, make(chan struct{}), d.monitoringEndpointGen.GenMonitoringEndpoint(spec.FeedID.String(), synchronization.EnhancedEAMercury), lggr.Named("Enhanced Telemetry Mercury")) diff --git a/core/services/ocr2/plugins/mercury/config/config.go b/core/services/ocr2/plugins/mercury/config/config.go index 69b2e846686..944140d99a8 100644 --- a/core/services/ocr2/plugins/mercury/config/config.go +++ b/core/services/ocr2/plugins/mercury/config/config.go @@ -13,6 +13,8 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/null" "github.com/smartcontractkit/chainlink/v2/core/utils" + + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" ) type PluginConfig struct { @@ -23,11 +25,14 @@ type PluginConfig struct { // server does not have any previous reports. For a brand new feed, this // effectively sets the "first" validFromBlockNumber. InitialBlockNumber null.Int64 `json:"initialBlockNumber" toml:"initialBlockNumber"` + + LinkFeedID *types.FeedID `json:"linkFeedID" toml:"linkFeedID"` + NativeFeedID *types.FeedID `json:"nativeFeedID" toml:"nativeFeedID"` } -func ValidatePluginConfig(config PluginConfig) (merr error) { +func ValidatePluginConfig(config PluginConfig, feedID types.FeedID) (merr error) { if config.RawServerURL == "" { - merr = errors.New("Mercury: ServerURL must be specified") + merr = errors.New("mercury: ServerURL must be specified") } else { var normalizedURI string if schemeRegexp.MatchString(config.RawServerURL) { @@ -42,9 +47,33 @@ func ValidatePluginConfig(config PluginConfig) (merr error) { merr = pkgerrors.Errorf(`Mercury: invalid scheme specified for MercuryServer, got: %q (scheme: %q) but expected a websocket url e.g. "192.0.2.2:4242" or "wss://192.0.2.2:4242"`, config.RawServerURL, uri.Scheme) } } + if len(config.ServerPubKey) != 32 { - merr = errors.Join(merr, errors.New("Mercury: ServerPubKey is required and must be a 32-byte hex string")) + merr = errors.Join(merr, errors.New("mercury: ServerPubKey is required and must be a 32-byte hex string")) } + + switch feedID.Version() { + case 1: + if config.LinkFeedID != nil { + merr = errors.Join(merr, errors.New("linkFeedID may not be specified for v1 jobs")) + } + if config.NativeFeedID != nil { + merr = errors.Join(merr, errors.New("nativeFeedID may not be specified for v1 jobs")) + } + case 2, 3: + if config.LinkFeedID == nil { + merr = errors.Join(merr, fmt.Errorf("linkFeedID must be specified for v%d jobs", feedID.Version())) + } + if config.NativeFeedID == nil { + merr = errors.Join(merr, fmt.Errorf("nativeFeedID must be specified for v%d jobs", feedID.Version())) + } + if config.InitialBlockNumber.Valid { + merr = errors.Join(merr, fmt.Errorf("initialBlockNumber may not be specified for v%d jobs", feedID.Version())) + } + default: + merr = errors.Join(merr, fmt.Errorf("got unsupported schema version %d; supported versions are 1,2,3", feedID.Version())) + } + return merr } diff --git a/core/services/ocr2/plugins/mercury/config/config_test.go b/core/services/ocr2/plugins/mercury/config/config_test.go index 2b0413d3990..60cc548f1fa 100644 --- a/core/services/ocr2/plugins/mercury/config/config_test.go +++ b/core/services/ocr2/plugins/mercury/config/config_test.go @@ -8,38 +8,130 @@ import ( "github.com/stretchr/testify/require" ) +var v1FeedId = [32]uint8{00, 01, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114} +var v2FeedId = [32]uint8{00, 02, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114} + func Test_PluginConfig(t *testing.T) { - t.Run("with valid values", func(t *testing.T) { - rawToml := ` -ServerURL = "example.com:80" -ServerPubKey = "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93" -` + t.Run("Mercury v1", func(t *testing.T) { + t.Run("with valid values", func(t *testing.T) { + rawToml := ` + ServerURL = "example.com:80" + ServerPubKey = "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93" + InitialBlockNumber = 1234 + ` + + var mc PluginConfig + err := toml.Unmarshal([]byte(rawToml), &mc) + require.NoError(t, err) + + assert.Equal(t, "example.com:80", mc.RawServerURL) + assert.Equal(t, "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93", mc.ServerPubKey.String()) + assert.Equal(t, int64(1234), mc.InitialBlockNumber.Int64) + + err = ValidatePluginConfig(mc, v1FeedId) + require.NoError(t, err) + }) + + t.Run("with invalid values", func(t *testing.T) { + rawToml := ` + InitialBlockNumber = "invalid" + ` - var mc PluginConfig - err := toml.Unmarshal([]byte(rawToml), &mc) - require.NoError(t, err) + var mc PluginConfig + err := toml.Unmarshal([]byte(rawToml), &mc) + require.Error(t, err) + assert.EqualError(t, err, `toml: strconv.ParseInt: parsing "invalid": invalid syntax`) - assert.Equal(t, "example.com:80", mc.RawServerURL) - assert.Equal(t, "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93", mc.ServerPubKey.String()) + rawToml = ` + ServerURL = "http://example.com" + ServerPubKey = "4242" + ` - err = ValidatePluginConfig(mc) - require.NoError(t, err) + err = toml.Unmarshal([]byte(rawToml), &mc) + require.NoError(t, err) + + err = ValidatePluginConfig(mc, v1FeedId) + require.Error(t, err) + assert.Contains(t, err.Error(), `Mercury: invalid scheme specified for MercuryServer, got: "http://example.com" (scheme: "http") but expected a websocket url e.g. "192.0.2.2:4242" or "wss://192.0.2.2:4242"`) + assert.Contains(t, err.Error(), `mercury: ServerPubKey is required and must be a 32-byte hex string`) + }) + + t.Run("with unnecessary values", func(t *testing.T) { + rawToml := ` + ServerURL = "example.com:80" + ServerPubKey = "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93" + LinkFeedID = "0x00026b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472" + ` + + var mc PluginConfig + err := toml.Unmarshal([]byte(rawToml), &mc) + require.NoError(t, err) + + err = ValidatePluginConfig(mc, v1FeedId) + assert.Contains(t, err.Error(), `linkFeedID may not be specified for v1 jobs`) + }) }) - t.Run("invalid values", func(t *testing.T) { - rawToml := ` -ServerURL = "http://example.com" -ServerPubKey = "4242" -` + t.Run("Mercury v2/v3", func(t *testing.T) { + t.Run("with valid values", func(t *testing.T) { + rawToml := ` + ServerURL = "example.com:80" + ServerPubKey = "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93" + LinkFeedID = "0x00026b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472" + NativeFeedID = "0x00036b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472" + ` + + var mc PluginConfig + err := toml.Unmarshal([]byte(rawToml), &mc) + require.NoError(t, err) + + err = ValidatePluginConfig(mc, v2FeedId) + require.NoError(t, err) + + require.NotNil(t, mc.LinkFeedID) + require.NotNil(t, mc.NativeFeedID) + assert.Equal(t, "0x00026b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472", (*mc.LinkFeedID).String()) + assert.Equal(t, "0x00036b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472", (*mc.NativeFeedID).String()) + + }) + + t.Run("with invalid values", func(t *testing.T) { + var mc PluginConfig + + rawToml := `LinkFeedID = "test"` + err := toml.Unmarshal([]byte(rawToml), &mc) + assert.Contains(t, err.Error(), "toml: hash: expected a hex string starting with '0x'") + + rawToml = `LinkFeedID = "0xtest"` + err = toml.Unmarshal([]byte(rawToml), &mc) + assert.Contains(t, err.Error(), `toml: hash: UnmarshalText failed: encoding/hex: invalid byte: U+0074 't'`) + + rawToml = ` + ServerURL = "example.com:80" + ServerPubKey = "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93" + LinkFeedID = "0x00026b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472" + ` + err = toml.Unmarshal([]byte(rawToml), &mc) + require.NoError(t, err) + + err = ValidatePluginConfig(mc, v2FeedId) + assert.Contains(t, err.Error(), "nativeFeedID must be specified for v2 jobs") + }) + + t.Run("with unnecessary values", func(t *testing.T) { + rawToml := ` + ServerURL = "example.com:80" + ServerPubKey = "724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93" + InitialBlockNumber = 1234 + ` - var mc PluginConfig - err := toml.Unmarshal([]byte(rawToml), &mc) - require.NoError(t, err) + var mc PluginConfig + err := toml.Unmarshal([]byte(rawToml), &mc) + require.NoError(t, err) - err = ValidatePluginConfig(mc) - require.Error(t, err) - assert.Contains(t, err.Error(), `Mercury: invalid scheme specified for MercuryServer, got: "http://example.com" (scheme: "http") but expected a websocket url e.g. "192.0.2.2:4242" or "wss://192.0.2.2:4242"`) - assert.Contains(t, err.Error(), `Mercury: ServerPubKey is required and must be a 32-byte hex string`) + err = ValidatePluginConfig(mc, v2FeedId) + assert.Contains(t, err.Error(), `initialBlockNumber may not be specified for v2 jobs`) + }) }) } diff --git a/core/services/ocr2/plugins/mercury/helpers_test.go b/core/services/ocr2/plugins/mercury/helpers_test.go new file mode 100644 index 00000000000..e93f161916a --- /dev/null +++ b/core/services/ocr2/plugins/mercury/helpers_test.go @@ -0,0 +1,465 @@ +package mercury_test + +import ( + "context" + "crypto/ed25519" + "encoding/binary" + "errors" + "fmt" + "math/big" + "net" + "testing" + "time" + + "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" + "github.com/ethereum/go-ethereum/common" + "github.com/smartcontractkit/wsrpc" + "github.com/smartcontractkit/wsrpc/credentials" + "github.com/smartcontractkit/wsrpc/peer" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "go.uber.org/zap/zapcore" + "go.uber.org/zap/zaptest/observer" + + "github.com/smartcontractkit/libocr/commontypes" + + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/csakey" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ocr2key" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/p2pkey" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate" + "github.com/smartcontractkit/chainlink/v2/core/services/ocrbootstrap" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" + "github.com/smartcontractkit/chainlink/v2/core/utils" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/keystest" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/store/models" +) + +var _ pb.MercuryServer = &mercuryServer{} + +type request struct { + pk credentials.StaticSizedPublicKey + req *pb.TransmitRequest +} + +type mercuryServer struct { + privKey ed25519.PrivateKey + reqsCh chan request + t *testing.T +} + +func NewMercuryServer(t *testing.T, privKey ed25519.PrivateKey, reqsCh chan request) *mercuryServer { + return &mercuryServer{privKey, reqsCh, t} +} + +func (s *mercuryServer) Transmit(ctx context.Context, req *pb.TransmitRequest) (*pb.TransmitResponse, error) { + p, ok := peer.FromContext(ctx) + if !ok { + return nil, errors.New("could not extract public key") + } + r := request{p.PublicKey, req} + s.reqsCh <- r + + return &pb.TransmitResponse{ + Code: 1, + Error: "", + }, nil +} + +func (s *mercuryServer) LatestReport(ctx context.Context, lrr *pb.LatestReportRequest) (*pb.LatestReportResponse, error) { + p, ok := peer.FromContext(ctx) + if !ok { + return nil, errors.New("could not extract public key") + } + s.t.Logf("mercury server got latest report from %x for feed id 0x%x", p.PublicKey, lrr.FeedId) + + out := new(pb.LatestReportResponse) + out.Report = new(pb.Report) + out.Report.FeedId = lrr.FeedId + + price := big.NewInt(123456789) + encodedPrice, _ := relaymercury.EncodeValueInt192(price) + out.Report.Price = encodedPrice + return out, nil +} + +func startMercuryServer(t *testing.T, srv *mercuryServer, pubKeys []ed25519.PublicKey) (serverURL string) { + // Set up the wsrpc server + lis, err := net.Listen("tcp", "127.0.0.1:0") + if err != nil { + t.Fatalf("[MAIN] failed to listen: %v", err) + } + serverURL = lis.Addr().String() + s := wsrpc.NewServer(wsrpc.Creds(srv.privKey, pubKeys)) + + // Register mercury implementation with the wsrpc server + pb.RegisterMercuryServer(s, srv) + + // Start serving + go s.Serve(lis) + t.Cleanup(s.Stop) + + return +} + +type Feed struct { + name string + id [32]byte + baseBenchmarkPrice *big.Int + baseBid *big.Int + baseAsk *big.Int +} + +func randomFeedID(version uint16) [32]byte { + id := [32]byte(utils.NewHash()) + binary.BigEndian.PutUint16(id[:2], version) + return id +} + +type Node struct { + App chainlink.Application + ClientPubKey credentials.StaticSizedPublicKey + KeyBundle ocr2key.KeyBundle +} + +func (node *Node) AddJob(t *testing.T, spec string) { + c := node.App.GetConfig() + job, err := validate.ValidatedOracleSpecToml(c.OCR2(), c.Insecure(), spec) + require.NoError(t, err) + err = node.App.AddJobV2(context.Background(), &job) + require.NoError(t, err) +} + +func (node *Node) AddBootstrapJob(t *testing.T, spec string) { + job, err := ocrbootstrap.ValidatedBootstrapSpecToml(spec) + require.NoError(t, err) + err = node.App.AddJobV2(context.Background(), &job) + require.NoError(t, err) +} + +func setupNode( + t *testing.T, + port int64, + dbName string, + p2pV2Bootstrappers []commontypes.BootstrapperLocator, + backend *backends.SimulatedBackend, + csaKey csakey.KeyV2, +) (app chainlink.Application, peerID string, clientPubKey credentials.StaticSizedPublicKey, ocr2kb ocr2key.KeyBundle, observedLogs *observer.ObservedLogs) { + k := big.NewInt(port) // keys unique to port + p2pKey := p2pkey.MustNewV2XXXTestingOnly(k) + rdr := keystest.NewRandReaderFromSeed(port) + ocr2kb = ocr2key.MustNewInsecure(rdr, chaintype.EVM) + + p2paddresses := []string{fmt.Sprintf("127.0.0.1:%d", port)} + + config, _ := heavyweight.FullTestDBV2(t, fmt.Sprintf("%s%d", dbName, port), func(c *chainlink.Config, s *chainlink.Secrets) { + // [JobPipeline] + // MaxSuccessfulRuns = 0 + c.JobPipeline.MaxSuccessfulRuns = ptr(uint64(0)) + + // [Feature] + // UICSAKeys=true + // LogPoller = true + // FeedsManager = false + c.Feature.UICSAKeys = ptr(true) + c.Feature.LogPoller = ptr(true) + c.Feature.FeedsManager = ptr(false) + + // [OCR] + // Enabled = false + c.OCR.Enabled = ptr(false) + + // [OCR2] + // Enabled = true + c.OCR2.Enabled = ptr(true) + + // [P2P] + // PeerID = '$PEERID' + // TraceLogging = true + c.P2P.PeerID = ptr(p2pKey.PeerID()) + c.P2P.TraceLogging = ptr(true) + + // [P2P.V1] + // Enabled = false + c.P2P.V1.Enabled = ptr(false) + + // [P2P.V2] + // Enabled = true + // AnnounceAddresses = ['$EXT_IP:17775'] + // ListenAddresses = ['127.0.0.1:17775'] + // DeltaDial = 500ms + // DeltaReconcile = 5s + c.P2P.V2.Enabled = ptr(true) + c.P2P.V2.AnnounceAddresses = &p2paddresses + c.P2P.V2.ListenAddresses = &p2paddresses + c.P2P.V2.DeltaDial = models.MustNewDuration(500 * time.Millisecond) + c.P2P.V2.DeltaReconcile = models.MustNewDuration(5 * time.Second) + }) + + lggr, observedLogs := logger.TestLoggerObserved(t, zapcore.DebugLevel) + app = cltest.NewApplicationWithConfigV2OnSimulatedBlockchain(t, config, backend, p2pKey, ocr2kb, csaKey, lggr.Named(dbName)) + err := app.Start(testutils.Context(t)) + require.NoError(t, err) + + t.Cleanup(func() { + assert.NoError(t, app.Stop()) + }) + + return app, p2pKey.PeerID().Raw(), csaKey.StaticSizedPublicKey(), ocr2kb, observedLogs +} + +func ptr[T any](t T) *T { return &t } + +func addBootstrapJob(t *testing.T, bootstrapNode Node, chainID *big.Int, verifierAddress common.Address, feedName string, feedID [32]byte) { + bootstrapNode.AddBootstrapJob(t, fmt.Sprintf(` +type = "bootstrap" +relay = "evm" +schemaVersion = 1 +name = "boot-%s" +contractID = "%s" +feedID = "0x%x" +contractConfigTrackerPollInterval = "1s" + +[relayConfig] +chainID = %d + `, feedName, verifierAddress, feedID, chainID)) +} + +func addV1MercuryJob( + t *testing.T, + node Node, + i int, + verifierAddress common.Address, + bootstrapPeerID string, + bootstrapNodePort int64, + bmBridge, + bidBridge, + askBridge, + serverURL string, + serverPubKey, + clientPubKey ed25519.PublicKey, + feedName string, + feedID [32]byte, + chainID *big.Int, + fromBlock int, +) { + node.AddJob(t, fmt.Sprintf(` +type = "offchainreporting2" +schemaVersion = 1 +name = "mercury-%[1]d-%[14]s" +forwardingAllowed = false +maxTaskDuration = "1s" +contractID = "%[2]s" +feedID = "0x%[11]x" +contractConfigTrackerPollInterval = "1s" +ocrKeyBundleID = "%[3]s" +p2pv2Bootstrappers = [ + "%[4]s" +] +relay = "evm" +pluginType = "mercury" +transmitterID = "%[10]x" +observationSource = """ + // Benchmark Price + price1 [type=bridge name="%[5]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + price1_parse [type=jsonparse path="result"]; + price1_multiply [type=multiply times=100000000 index=0]; + + price1 -> price1_parse -> price1_multiply; + + // Bid + bid [type=bridge name="%[6]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + bid_parse [type=jsonparse path="result"]; + bid_multiply [type=multiply times=100000000 index=1]; + + bid -> bid_parse -> bid_multiply; + + // Ask + ask [type=bridge name="%[7]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + ask_parse [type=jsonparse path="result"]; + ask_multiply [type=multiply times=100000000 index=2]; + + ask -> ask_parse -> ask_multiply; +""" + +[pluginConfig] +serverURL = "%[8]s" +serverPubKey = "%[9]x" +initialBlockNumber = %[13]d + +[relayConfig] +chainID = %[12]d + + `, + i, + verifierAddress, + node.KeyBundle.ID(), + fmt.Sprintf("%s@127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), + bmBridge, + bidBridge, + askBridge, + serverURL, + serverPubKey, + clientPubKey, + feedID, + chainID, + fromBlock, + feedName, + )) +} + +func addV2MercuryJob( + t *testing.T, + node Node, + i int, + verifierAddress common.Address, + bootstrapPeerID string, + bootstrapNodePort int64, + bmBridge, + serverURL string, + serverPubKey, + clientPubKey ed25519.PublicKey, + feedName string, + feedID [32]byte, + linkFeedID [32]byte, + nativeFeedID [32]byte, +) { + node.AddJob(t, fmt.Sprintf(` +type = "offchainreporting2" +schemaVersion = 1 +name = "mercury-%[1]d-%[10]s" +forwardingAllowed = false +maxTaskDuration = "1s" +contractID = "%[2]s" +feedID = "0x%[9]x" +contractConfigTrackerPollInterval = "1s" +ocrKeyBundleID = "%[3]s" +p2pv2Bootstrappers = [ + "%[4]s" +] +relay = "evm" +pluginType = "mercury" +transmitterID = "%[8]x" +observationSource = """ + // Benchmark Price + price1 [type=bridge name="%[5]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + price1_parse [type=jsonparse path="result"]; + price1_multiply [type=multiply times=100000000 index=0]; + + price1 -> price1_parse -> price1_multiply; +""" + +[pluginConfig] +serverURL = "%[6]s" +serverPubKey = "%[7]x" +linkFeedID = "0x%[11]x" +nativeFeedID = "0x%[12]x" + +[relayConfig] +chainID = 1337 + `, + i, + verifierAddress, + node.KeyBundle.ID(), + fmt.Sprintf("%s@127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), + bmBridge, + serverURL, + serverPubKey, + clientPubKey, + feedID, + feedName, + linkFeedID, + nativeFeedID, + )) +} + +func addV3MercuryJob( + t *testing.T, + node Node, + i int, + verifierAddress common.Address, + bootstrapPeerID string, + bootstrapNodePort int64, + bmBridge, + bidBridge, + askBridge, + serverURL string, + serverPubKey, + clientPubKey ed25519.PublicKey, + feedName string, + feedID [32]byte, + linkFeedID [32]byte, + nativeFeedID [32]byte, +) { + node.AddJob(t, fmt.Sprintf(` +type = "offchainreporting2" +schemaVersion = 1 +name = "mercury-%[1]d-%[12]s" +forwardingAllowed = false +maxTaskDuration = "1s" +contractID = "%[2]s" +feedID = "0x%[11]x" +contractConfigTrackerPollInterval = "1s" +ocrKeyBundleID = "%[3]s" +p2pv2Bootstrappers = [ + "%[4]s" +] +relay = "evm" +pluginType = "mercury" +transmitterID = "%[10]x" +observationSource = """ + // Benchmark Price + price1 [type=bridge name="%[5]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + price1_parse [type=jsonparse path="result"]; + price1_multiply [type=multiply times=100000000 index=0]; + + price1 -> price1_parse -> price1_multiply; + + // Bid + bid [type=bridge name="%[6]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + bid_parse [type=jsonparse path="result"]; + bid_multiply [type=multiply times=100000000 index=1]; + + bid -> bid_parse -> bid_multiply; + + // Ask + ask [type=bridge name="%[7]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; + ask_parse [type=jsonparse path="result"]; + ask_multiply [type=multiply times=100000000 index=2]; + + ask -> ask_parse -> ask_multiply; +""" + +[pluginConfig] +serverURL = "%[8]s" +serverPubKey = "%[9]x" +linkFeedID = "0x%[13]x" +nativeFeedID = "0x%[14]x" + +[relayConfig] +chainID = 1337 + `, + i, + verifierAddress, + node.KeyBundle.ID(), + fmt.Sprintf("%s@127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), + bmBridge, + bidBridge, + askBridge, + serverURL, + serverPubKey, + clientPubKey, + feedID, + feedName, + linkFeedID, + nativeFeedID, + )) +} diff --git a/core/services/ocr2/plugins/mercury/integration_test.go b/core/services/ocr2/plugins/mercury/integration_test.go index 1f919a27e5c..dbbe9ce4da2 100644 --- a/core/services/ocr2/plugins/mercury/integration_test.go +++ b/core/services/ocr2/plugins/mercury/integration_test.go @@ -1,16 +1,14 @@ package mercury_test import ( - "context" "crypto/ed25519" "encoding/hex" - "errors" + "encoding/json" "fmt" "io" "math" "math/big" "math/rand" - "net" "net/http" "net/http/httptest" "net/url" @@ -19,6 +17,7 @@ import ( "testing" "time" + "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core" @@ -26,10 +25,9 @@ import ( "github.com/shopspring/decimal" "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + ocr3confighelper "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3confighelper" ocr2types "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - "github.com/smartcontractkit/wsrpc" "github.com/smartcontractkit/wsrpc/credentials" - "github.com/smartcontractkit/wsrpc/peer" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "go.uber.org/zap/zapcore" @@ -39,48 +37,98 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/bridges" + token "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/fee_manager" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/reward_manager" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier_proxy" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" - "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/keystest" "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/csakey" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ocr2key" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/p2pkey" - "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate" - "github.com/smartcontractkit/chainlink/v2/core/services/ocrbootstrap" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" + reportcodecv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/reportcodec" + reportcodecv2 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2/reportcodec" + reportcodecv3 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/store/models" - "github.com/smartcontractkit/chainlink/v2/core/utils" ) -type Feed struct { - name string - id [32]byte - baseBenchmarkPrice *big.Int - baseBid *big.Int - baseAsk *big.Int +var ( + f = uint8(1) + n = 4 // number of nodes + multiplier int64 = 100000000 + rawOnchainConfig = relaymercury.OnchainConfig{ + Min: big.NewInt(0), + Max: big.NewInt(math.MaxInt64), + } + rawReportingPluginConfig = relaymercury.OffchainConfig{ + ExpirationWindow: 1, + BaseUSDFeeCents: 100, + } +) + +func detectPanicLogs(t *testing.T, logObservers []*observer.ObservedLogs) { + var panicLines []string + for _, observedLogs := range logObservers { + panicLogs := observedLogs.Filter(func(e observer.LoggedEntry) bool { + return e.Level >= zapcore.DPanicLevel + }) + for _, log := range panicLogs.All() { + line := fmt.Sprintf("%v\t%s\t%s\t%s\t%s", log.Time.Format(time.RFC3339), log.Level.CapitalString(), log.LoggerName, log.Caller.TrimmedPath(), log.Message) + panicLines = append(panicLines, line) + } + } + if len(panicLines) > 0 { + t.Errorf("Found logs with DPANIC or higher level:\n%s", strings.Join(panicLines, "\n")) + } } -func randomFeedID() [32]byte { - return [32]byte(utils.NewHash()) +func setupBlockchain(t *testing.T) (*bind.TransactOpts, *backends.SimulatedBackend, *verifier.Verifier, common.Address) { + steve := testutils.MustNewSimTransactor(t) // config contract deployer and owner + genesisData := core.GenesisAlloc{steve.From: {Balance: assets.Ether(1000).ToInt()}} + backend := cltest.NewSimulatedBackend(t, genesisData, uint32(ethconfig.Defaults.Miner.GasCeil)) + backend.Commit() // ensure starting block number at least 1 + stopMining := cltest.Mine(backend, 1*time.Second) // Should be greater than deltaRound since we cannot access old blocks on simulated blockchain + t.Cleanup(stopMining) + + // Deploy contracts + linkTokenAddress, _, linkToken, err := token.DeployLinkToken(steve, backend) + require.NoError(t, err) + _, err = linkToken.Transfer(steve, steve.From, big.NewInt(1000)) + require.NoError(t, err) + nativeTokenAddress, _, nativeToken, err := token.DeployLinkToken(steve, backend) + require.NoError(t, err) + _, err = nativeToken.Transfer(steve, steve.From, big.NewInt(1000)) + require.NoError(t, err) + verifierProxyAddr, _, verifierProxy, err := verifier_proxy.DeployVerifierProxy(steve, backend, common.Address{}) // zero address for access controller disables access control + require.NoError(t, err) + verifierAddress, _, verifier, err := verifier.DeployVerifier(steve, backend, verifierProxyAddr) + require.NoError(t, err) + _, err = verifierProxy.InitializeVerifier(steve, verifierAddress) + require.NoError(t, err) + rewardManagerAddr, _, rewardManager, err := reward_manager.DeployRewardManager(steve, backend, linkTokenAddress) + require.NoError(t, err) + feeManagerAddr, _, _, err := fee_manager.DeployFeeManager(steve, backend, linkTokenAddress, nativeTokenAddress, verifierProxyAddr, rewardManagerAddr) + require.NoError(t, err) + _, err = verifierProxy.SetFeeManager(steve, feeManagerAddr) + require.NoError(t, err) + _, err = rewardManager.SetFeeManager(steve, feeManagerAddr) + require.NoError(t, err) + backend.Commit() + + return steve, backend, verifier, verifierAddress } -func TestIntegration_Mercury(t *testing.T) { +func TestIntegration_MercuryV1(t *testing.T) { t.Parallel() - // test constants - const f = uint8(1) - const n = 4 // number of nodes + var logObservers []*observer.ObservedLogs + t.Cleanup(func() { + detectPanicLogs(t, logObservers) + }) + lggr := logger.TestLogger(t) const fromBlock = 1 // cannot use zero, start from block 1 - const multiplier = 100000000 testStartTimeStamp := uint32(time.Now().Unix()) // test vars @@ -89,24 +137,19 @@ func TestIntegration_Mercury(t *testing.T) { pError := atomic.Int64{} // feeds - btcFeed := Feed{"BTC/USD", randomFeedID(), big.NewInt(20_000 * multiplier), big.NewInt(19_997 * multiplier), big.NewInt(20_004 * multiplier)} - ethFeed := Feed{"ETH/USD", randomFeedID(), big.NewInt(1_568 * multiplier), big.NewInt(1_566 * multiplier), big.NewInt(1_569 * multiplier)} - linkFeed := Feed{"LINK/USD", randomFeedID(), big.NewInt(7150 * multiplier / 1000), big.NewInt(7123 * multiplier / 1000), big.NewInt(7177 * multiplier / 1000)} + btcFeed := Feed{"BTC/USD", randomFeedID(1), big.NewInt(20_000 * multiplier), big.NewInt(19_997 * multiplier), big.NewInt(20_004 * multiplier)} + ethFeed := Feed{"ETH/USD", randomFeedID(1), big.NewInt(1_568 * multiplier), big.NewInt(1_566 * multiplier), big.NewInt(1_569 * multiplier)} + linkFeed := Feed{"LINK/USD", randomFeedID(1), big.NewInt(7150 * multiplier / 1000), big.NewInt(7123 * multiplier / 1000), big.NewInt(7177 * multiplier / 1000)} feeds := []Feed{btcFeed, ethFeed, linkFeed} feedM := make(map[[32]byte]Feed, len(feeds)) for i := range feeds { feedM[feeds[i].id] = feeds[i] } - lggr := logger.TestLogger(t) - reqs := make(chan request) serverKey := csakey.MustNewV2XXXTestingOnly(big.NewInt(-1)) serverPubKey := serverKey.PublicKey srv := NewMercuryServer(t, ed25519.PrivateKey(serverKey.Raw()), reqs) - min := big.NewInt(0) - max := big.NewInt(math.MaxInt64) - clientCSAKeys := make([]csakey.KeyV2, n+1) clientPubKeys := make([]ed25519.PublicKey, n+1) for i := 0; i < n+1; i++ { @@ -118,39 +161,7 @@ func TestIntegration_Mercury(t *testing.T) { serverURL := startMercuryServer(t, srv, clientPubKeys) chainID := testutils.SimulatedChainID - // Setup blockchain - steve := testutils.MustNewSimTransactor(t) // config contract deployer and owner - genesisData := core.GenesisAlloc{steve.From: {Balance: assets.Ether(1000).ToInt()}} - backend := cltest.NewSimulatedBackend(t, genesisData, uint32(ethconfig.Defaults.Miner.GasCeil)) - backend.Commit() // ensure starting block number at least 1 - stopMining := cltest.Mine(backend, 1*time.Second) // Should be greater than deltaRound since we cannot access old blocks on simulated blockchain - t.Cleanup(stopMining) - - // Deploy config contract - verifierProxyAddr, _, verifierProxy, err := verifier_proxy.DeployVerifierProxy(steve, backend, common.Address{}) // zero address for access controller disables access control - require.NoError(t, err) - verifierAddress, _, verifier, err := verifier.DeployVerifier(steve, backend, verifierProxyAddr) - require.NoError(t, err) - _, err = verifierProxy.InitializeVerifier(steve, verifierAddress) - require.NoError(t, err) - backend.Commit() - - var logObservers []*observer.ObservedLogs - t.Cleanup(func() { - var panicLines []string - for _, observedLogs := range logObservers { - panicLogs := observedLogs.Filter(func(e observer.LoggedEntry) bool { - return e.Level >= zapcore.DPanicLevel - }) - for _, log := range panicLogs.All() { - line := fmt.Sprintf("%v\t%s\t%s\t%s\t%s", log.Time.Format(time.RFC3339), log.Level.CapitalString(), log.LoggerName, log.Caller.TrimmedPath(), log.Message) - panicLines = append(panicLines, line) - } - } - if len(panicLines) > 0 { - t.Errorf("Found logs with DPANIC or higher level:\n%s", strings.Join(panicLines, "\n")) - } - }) + steve, backend, verifier, verifierAddress := setupBlockchain(t) // Setup bootstrap + oracle nodes bootstrapNodePort := int64(19700) @@ -204,7 +215,7 @@ func TestIntegration_Mercury(t *testing.T) { require.NoError(t, err) } else { res.WriteHeader(http.StatusInternalServerError) - resp := fmt.Sprintf(`{"error": "pError test error"}`) + resp := `{"error": "pError test error"}` _, err := res.Write([]byte(resp)) require.NoError(t, err) } @@ -227,7 +238,7 @@ func TestIntegration_Mercury(t *testing.T) { askBridge := createBridge(fmt.Sprintf("ask-%d", j), i, feed.baseAsk, node.App.BridgeORM()) bidBridge := createBridge(fmt.Sprintf("bid-%d", j), i, feed.baseBid, node.App.BridgeORM()) - addMercuryJob( + addV1MercuryJob( t, node, i, @@ -249,11 +260,13 @@ func TestIntegration_Mercury(t *testing.T) { } // Setup config on contract - c := relaymercury.OnchainConfig{Min: min, Max: max} - onchainConfig, err := (relaymercury.StandardOnchainConfigCodec{}).Encode(c) + onchainConfig, err := (relaymercury.StandardOnchainConfigCodec{}).Encode(rawOnchainConfig) require.NoError(t, err) - signers, _, _, onchainConfig, offchainConfigVersion, offchainConfig, err := confighelper.ContractSetConfigArgsForTestsMercuryV02( + reportingPluginConfig, err := json.Marshal(rawReportingPluginConfig) + require.NoError(t, err) + + signers, _, _, onchainConfig, offchainConfigVersion, offchainConfig, err := ocr3confighelper.ContractSetConfigArgsForTestsMercuryV02( 2*time.Second, // DeltaProgress 20*time.Second, // DeltaResend 400*time.Millisecond, // DeltaInitial @@ -264,11 +277,12 @@ func TestIntegration_Mercury(t *testing.T) { 100, // rMax []int{len(nodes)}, // S oracles, - []byte{}, // reportingPluginConfig []byte, - 250*time.Millisecond, // Max duration observation - int(f), // f + reportingPluginConfig, // reportingPluginConfig []byte, + 250*time.Millisecond, // Max duration observation + int(f), // f onchainConfig, ) + require.NoError(t, err) signerAddresses, err := evm.OnchainPublicKeyToAddress(signers) require.NoError(t, err) @@ -331,7 +345,7 @@ func TestIntegration_Mercury(t *testing.T) { t.Fatalf("expected payload %#v to contain 'report'", v) } reportElems := make(map[string]interface{}) - err = reportcodec.ReportTypes.UnpackIntoMap(reportElems, report.([]byte)) + err = reportcodecv1.ReportTypes.UnpackIntoMap(reportElems, report.([]byte)) require.NoError(t, err) feedID := ([32]byte)(reportElems["feedId"].([32]uint8)) @@ -342,7 +356,7 @@ func TestIntegration_Mercury(t *testing.T) { continue // already saw all oracles for this feed } - num, err := (&reportcodec.EVMReportCodec{}).CurrentBlockNumFromReport(ocr2types.Report(report.([]byte))) + num, err := (&reportcodecv1.ReportCodec{}).CurrentBlockNumFromReport(ocr2types.Report(report.([]byte))) require.NoError(t, err) currentBlock, err := backend.BlockByNumber(testutils.Context(t), nil) require.NoError(t, err) @@ -395,7 +409,7 @@ func TestIntegration_Mercury(t *testing.T) { t.Fatalf("expected payload %#v to contain 'report'", v) } reportElems := make(map[string]interface{}) - err = reportcodec.ReportTypes.UnpackIntoMap(reportElems, report.([]byte)) + err = reportcodecv1.ReportTypes.UnpackIntoMap(reportElems, report.([]byte)) require.NoError(t, err) feedID := ([32]byte)(reportElems["feedId"].([32]uint8)) @@ -406,7 +420,7 @@ func TestIntegration_Mercury(t *testing.T) { continue // already saw all oracles for this feed } - num, err := (&reportcodec.EVMReportCodec{}).CurrentBlockNumFromReport(ocr2types.Report(report.([]byte))) + num, err := (&reportcodecv1.ReportCodec{}).CurrentBlockNumFromReport(ocr2types.Report(report.([]byte))) require.NoError(t, err) currentBlock, err := backend.BlockByNumber(testutils.Context(t), nil) require.NoError(t, err) @@ -440,253 +454,546 @@ func TestIntegration_Mercury(t *testing.T) { }) } -var _ pb.MercuryServer = &mercuryServer{} +func TestIntegration_MercuryV2(t *testing.T) { + t.Parallel() + + var logObservers []*observer.ObservedLogs + t.Cleanup(func() { + detectPanicLogs(t, logObservers) + }) -type request struct { - pk credentials.StaticSizedPublicKey - req *pb.TransmitRequest -} + testStartTimeStamp := uint32(time.Now().Unix()) -type mercuryServer struct { - privKey ed25519.PrivateKey - reqsCh chan request - t *testing.T -} + // test vars + // pError is the probability that an EA will return an error instead of a result, as integer percentage + // pError = 0 means it will never return error + pError := atomic.Int64{} -func NewMercuryServer(t *testing.T, privKey ed25519.PrivateKey, reqsCh chan request) *mercuryServer { - return &mercuryServer{privKey, reqsCh, t} -} + // feeds + btcFeed := Feed{ + name: "BTC/USD", + id: randomFeedID(2), + baseBenchmarkPrice: big.NewInt(20_000 * multiplier), + } + ethFeed := Feed{ + name: "ETH/USD", + id: randomFeedID(2), + baseBenchmarkPrice: big.NewInt(1_568 * multiplier), + } + linkFeed := Feed{ + name: "LINK/USD", + id: randomFeedID(2), + baseBenchmarkPrice: big.NewInt(7150 * multiplier / 1000), + } + feeds := []Feed{btcFeed, ethFeed, linkFeed} + feedM := make(map[[32]byte]Feed, len(feeds)) + for i := range feeds { + feedM[feeds[i].id] = feeds[i] + } -func (s *mercuryServer) Transmit(ctx context.Context, req *pb.TransmitRequest) (*pb.TransmitResponse, error) { - p, ok := peer.FromContext(ctx) - if !ok { - return nil, errors.New("could not extract public key") + reqs := make(chan request) + serverKey := csakey.MustNewV2XXXTestingOnly(big.NewInt(-1)) + serverPubKey := serverKey.PublicKey + srv := NewMercuryServer(t, ed25519.PrivateKey(serverKey.Raw()), reqs) + clientCSAKeys := make([]csakey.KeyV2, n+1) + clientPubKeys := make([]ed25519.PublicKey, n+1) + for i := 0; i < n+1; i++ { + k := big.NewInt(int64(i)) + key := csakey.MustNewV2XXXTestingOnly(k) + clientCSAKeys[i] = key + clientPubKeys[i] = key.PublicKey } - r := request{p.PublicKey, req} - s.reqsCh <- r + serverURL := startMercuryServer(t, srv, clientPubKeys) + chainID := testutils.SimulatedChainID - return &pb.TransmitResponse{ - Code: 1, - Error: "", - }, nil -} + steve, backend, verifier, verifierAddress := setupBlockchain(t) + + // Setup bootstrap + oracle nodes + bootstrapNodePort := int64(20700) + appBootstrap, bootstrapPeerID, _, bootstrapKb, observedLogs := setupNode(t, bootstrapNodePort, "bootstrap_mercury", nil, backend, clientCSAKeys[n]) + bootstrapNode := Node{App: appBootstrap, KeyBundle: bootstrapKb} + logObservers = append(logObservers, observedLogs) -func (s *mercuryServer) LatestReport(ctx context.Context, lrr *pb.LatestReportRequest) (*pb.LatestReportResponse, error) { - // not implemented in test - p, ok := peer.FromContext(ctx) - if !ok { - return nil, errors.New("could not extract public key") + // Set up n oracles + var ( + oracles []confighelper.OracleIdentityExtra + nodes []Node + ) + for i := int64(0); i < int64(n); i++ { + app, peerID, transmitter, kb, observedLogs := setupNode(t, bootstrapNodePort+i+1, fmt.Sprintf("oracle_mercury%d", i), []commontypes.BootstrapperLocator{ + // Supply the bootstrap IP and port as a V2 peer address + {PeerID: bootstrapPeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", bootstrapNodePort)}}, + }, backend, clientCSAKeys[i]) + + nodes = append(nodes, Node{ + app, transmitter, kb, + }) + + offchainPublicKey, _ := hex.DecodeString(strings.TrimPrefix(kb.OnChainPublicKey(), "0x")) + oracles = append(oracles, confighelper.OracleIdentityExtra{ + OracleIdentity: confighelper.OracleIdentity{ + OnchainPublicKey: offchainPublicKey, + TransmitAccount: ocr2types.Account(fmt.Sprintf("%x", transmitter[:])), + OffchainPublicKey: kb.OffchainPublicKey(), + PeerID: peerID, + }, + ConfigEncryptionPublicKey: kb.ConfigEncryptionPublicKey(), + }) + logObservers = append(logObservers, observedLogs) } - s.t.Logf("mercury server got latest report from %x for feed id 0x%x", p.PublicKey, lrr.FeedId) - return nil, nil -} -func startMercuryServer(t *testing.T, srv *mercuryServer, pubKeys []ed25519.PublicKey) (serverURL string) { - // Set up the wsrpc server - lis, err := net.Listen("tcp", "127.0.0.1:0") - if err != nil { - t.Fatalf("[MAIN] failed to listen: %v", err) + for _, feed := range feeds { + addBootstrapJob(t, bootstrapNode, chainID, verifierAddress, feed.name, feed.id) } - serverURL = fmt.Sprintf("%s", lis.Addr().String()) - s := wsrpc.NewServer(wsrpc.Creds(srv.privKey, pubKeys)) - // Register mercury implementation with the wsrpc server - pb.RegisterMercuryServer(s, srv) + createBridge := func(name string, i int, p *big.Int, borm bridges.ORM) (bridgeName string) { + bridge := httptest.NewServer(http.HandlerFunc(func(res http.ResponseWriter, req *http.Request) { + b, err := io.ReadAll(req.Body) + require.NoError(t, err) + require.Equal(t, `{"data":{"from":"ETH","to":"USD"}}`, string(b)) - // Start serving - go s.Serve(lis) - t.Cleanup(s.Stop) + r := rand.Int63n(101) + if r > pError.Load() { + res.WriteHeader(http.StatusOK) + val := decimal.NewFromBigInt(p, 0).Div(decimal.NewFromInt(multiplier)).Add(decimal.NewFromInt(int64(i)).Div(decimal.NewFromInt(100))).String() + resp := fmt.Sprintf(`{"result": %s}`, val) + _, err := res.Write([]byte(resp)) + require.NoError(t, err) + } else { + res.WriteHeader(http.StatusInternalServerError) + resp := `{"error": "pError test error"}` + _, err := res.Write([]byte(resp)) + require.NoError(t, err) + } + })) + t.Cleanup(bridge.Close) + u, _ := url.Parse(bridge.URL) + bridgeName = fmt.Sprintf("bridge-%s-%d", name, i) + require.NoError(t, borm.CreateBridgeType(&bridges.BridgeType{ + Name: bridges.BridgeName(bridgeName), + URL: models.WebURL(*u), + })) - return -} + return bridgeName + } -type Node struct { - App chainlink.Application - ClientPubKey credentials.StaticSizedPublicKey - KeyBundle ocr2key.KeyBundle -} + // Add OCR jobs - one per feed on each node + for i, node := range nodes { + for j, feed := range feeds { + bmBridge := createBridge(fmt.Sprintf("benchmarkprice-%d", j), i, feed.baseBenchmarkPrice, node.App.BridgeORM()) -func (node *Node) AddJob(t *testing.T, spec string) { - c := node.App.GetConfig() - job, err := validate.ValidatedOracleSpecToml(c.OCR2(), c.Insecure(), spec) + addV2MercuryJob( + t, + node, + i, + verifierAddress, + bootstrapPeerID, + bootstrapNodePort, + bmBridge, + serverURL, + serverPubKey, + clientPubKeys[i], + feed.name, + feed.id, + randomFeedID(2), + randomFeedID(2), + ) + } + } + + // Setup config on contract + onchainConfig, err := (relaymercury.StandardOnchainConfigCodec{}).Encode(rawOnchainConfig) require.NoError(t, err) - err = node.App.AddJobV2(context.Background(), &job) + + reportingPluginConfig, err := json.Marshal(rawReportingPluginConfig) require.NoError(t, err) -} -func (node *Node) AddBootstrapJob(t *testing.T, spec string) { - job, err := ocrbootstrap.ValidatedBootstrapSpecToml(spec) + signers, _, _, onchainConfig, offchainConfigVersion, offchainConfig, err := ocr3confighelper.ContractSetConfigArgsForTestsMercuryV02( + 2*time.Second, // DeltaProgress + 20*time.Second, // DeltaResend + 400*time.Millisecond, // DeltaInitial + 100*time.Millisecond, // DeltaRound + 0, // DeltaGrace + 300*time.Millisecond, // DeltaCertifiedCommitRequest + 1*time.Minute, // DeltaStage + 100, // rMax + []int{len(nodes)}, // S + oracles, + reportingPluginConfig, // reportingPluginConfig []byte, + 250*time.Millisecond, // Max duration observation + int(f), // f + onchainConfig, + ) + require.NoError(t, err) - err = node.App.AddJobV2(context.Background(), &job) + signerAddresses, err := evm.OnchainPublicKeyToAddress(signers) require.NoError(t, err) -} -func setupNode( - t *testing.T, - port int64, - dbName string, - p2pV2Bootstrappers []commontypes.BootstrapperLocator, - backend *backends.SimulatedBackend, - csaKey csakey.KeyV2, -) (app chainlink.Application, peerID string, clientPubKey credentials.StaticSizedPublicKey, ocr2kb ocr2key.KeyBundle, observedLogs *observer.ObservedLogs) { - k := big.NewInt(port) // keys unique to port - p2pKey := p2pkey.MustNewV2XXXTestingOnly(k) - rdr := keystest.NewRandReaderFromSeed(port) - ocr2kb = ocr2key.MustNewInsecure(rdr, chaintype.EVM) - - p2paddresses := []string{fmt.Sprintf("127.0.0.1:%d", port)} - - config, _ := heavyweight.FullTestDBV2(t, fmt.Sprintf("%s%d", dbName, port), func(c *chainlink.Config, s *chainlink.Secrets) { - // [JobPipeline] - // MaxSuccessfulRuns = 0 - c.JobPipeline.MaxSuccessfulRuns = ptr(uint64(0)) - - // [Feature] - // UICSAKeys=true - // LogPoller = true - // FeedsManager = false - c.Feature.UICSAKeys = ptr(true) - c.Feature.LogPoller = ptr(true) - c.Feature.FeedsManager = ptr(false) - - // [OCR] - // Enabled = false - c.OCR.Enabled = ptr(false) - - // [OCR2] - // Enabled = true - c.OCR2.Enabled = ptr(true) - - // [P2P] - // PeerID = '$PEERID' - // TraceLogging = true - c.P2P.PeerID = ptr(p2pKey.PeerID()) - c.P2P.TraceLogging = ptr(true) - - // [P2P.V1] - // Enabled = false - c.P2P.V1.Enabled = ptr(false) - - // [P2P.V2] - // Enabled = true - // AnnounceAddresses = ['$EXT_IP:17775'] - // ListenAddresses = ['127.0.0.1:17775'] - // DeltaDial = 500ms - // DeltaReconcile = 5s - c.P2P.V2.Enabled = ptr(true) - c.P2P.V2.AnnounceAddresses = &p2paddresses - c.P2P.V2.ListenAddresses = &p2paddresses - c.P2P.V2.DeltaDial = models.MustNewDuration(500 * time.Millisecond) - c.P2P.V2.DeltaReconcile = models.MustNewDuration(5 * time.Second) - }) + offchainTransmitters := make([][32]byte, n) + for i := 0; i < n; i++ { + offchainTransmitters[i] = nodes[i].ClientPubKey + } + + for _, feed := range feeds { + _, err = verifier.SetConfig( + steve, + feed.id, + signerAddresses, + offchainTransmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig, + nil, + ) + require.NoError(t, err) + backend.Commit() + } - lggr, observedLogs := logger.TestLoggerObserved(t, zapcore.DebugLevel) - app = cltest.NewApplicationWithConfigV2OnSimulatedBlockchain(t, config, backend, p2pKey, ocr2kb, csaKey, lggr.Named(dbName)) - err := app.Start(testutils.Context(t)) + // Bury it with finality depth + ch, err := bootstrapNode.App.GetChains().EVM.Get(testutils.SimulatedChainID) require.NoError(t, err) + finalityDepth := ch.Config().EVM().FinalityDepth() + for i := 0; i < int(finalityDepth); i++ { + backend.Commit() + } - t.Cleanup(func() { - assert.NoError(t, app.Stop()) + runTestSetup := func() { + // Expect at least one report per feed from each oracle + seen := make(map[[32]byte]map[credentials.StaticSizedPublicKey]struct{}) + for i := range feeds { + // feedID will be deleted when all n oracles have reported + seen[feeds[i].id] = make(map[credentials.StaticSizedPublicKey]struct{}, n) + } + + for req := range reqs { + v := make(map[string]interface{}) + err := mercury.PayloadTypes.UnpackIntoMap(v, req.req.Payload) + require.NoError(t, err) + report, exists := v["report"] + if !exists { + t.Fatalf("expected payload %#v to contain 'report'", v) + } + reportElems := make(map[string]interface{}) + err = reportcodecv2.ReportTypes.UnpackIntoMap(reportElems, report.([]byte)) + require.NoError(t, err) + + feedID := ([32]byte)(reportElems["feedId"].([32]uint8)) + feed, exists := feedM[feedID] + require.True(t, exists) + + if _, exists := seen[feedID]; !exists { + continue // already saw all oracles for this feed + } + + expectedFee := relaymercury.CalculateFee(big.NewInt(123456789), rawReportingPluginConfig.BaseUSDFeeCents) + expectedExpiresAt := reportElems["observationsTimestamp"].(uint32) + rawReportingPluginConfig.ExpirationWindow + + assert.GreaterOrEqual(t, int(reportElems["observationsTimestamp"].(uint32)), int(testStartTimeStamp)) + assert.InDelta(t, feed.baseBenchmarkPrice.Int64(), reportElems["benchmarkPrice"].(*big.Int).Int64(), 5000000) + assert.NotZero(t, reportElems["validFromTimestamp"].(uint32)) + assert.GreaterOrEqual(t, reportElems["observationsTimestamp"].(uint32), reportElems["validFromTimestamp"].(uint32)) + assert.Equal(t, expectedExpiresAt, reportElems["expiresAt"].(uint32)) + assert.Equal(t, expectedFee, reportElems["linkFee"].(*big.Int)) + assert.Equal(t, expectedFee, reportElems["nativeFee"].(*big.Int)) + + t.Logf("oracle %x reported for feed %s (0x%x)", req.pk, feed.name, feed.id) + + seen[feedID][req.pk] = struct{}{} + if len(seen[feedID]) == n { + t.Logf("all oracles reported for feed %s (0x%x)", feed.name, feed.id) + delete(seen, feedID) + if len(seen) == 0 { + break // saw all oracles; success! + } + } + } + } + + t.Run("receives at least one report per feed from each oracle when EAs are at 100% reliability", func(t *testing.T) { + runTestSetup() }) - return app, p2pKey.PeerID().Raw(), csaKey.StaticSizedPublicKey(), ocr2kb, observedLogs + t.Run("receives at least one report per feed from each oracle when EAs are at 80% reliability", func(t *testing.T) { + pError.Store(20) + runTestSetup() + }) } -func ptr[T any](t T) *T { return &t } - -func addBootstrapJob(t *testing.T, bootstrapNode Node, chainID *big.Int, verifierAddress common.Address, feedName string, feedID [32]byte) { - bootstrapNode.AddBootstrapJob(t, fmt.Sprintf(` -type = "bootstrap" -relay = "evm" -schemaVersion = 1 -name = "boot-%s" -contractID = "%s" -feedID = "0x%x" -contractConfigTrackerPollInterval = "1s" - -[relayConfig] -chainID = %d - `, feedName, verifierAddress, feedID, chainID)) -} +func TestIntegration_MercuryV3(t *testing.T) { + t.Parallel() + + var logObservers []*observer.ObservedLogs + t.Cleanup(func() { + detectPanicLogs(t, logObservers) + }) + + testStartTimeStamp := uint32(time.Now().Unix()) + + // test vars + // pError is the probability that an EA will return an error instead of a result, as integer percentage + // pError = 0 means it will never return error + pError := atomic.Int64{} + + // feeds + btcFeed := Feed{ + name: "BTC/USD", + id: randomFeedID(3), + baseBenchmarkPrice: big.NewInt(20_000 * multiplier), + baseBid: big.NewInt(19_997 * multiplier), + baseAsk: big.NewInt(20_004 * multiplier), + } + ethFeed := Feed{ + name: "ETH/USD", + id: randomFeedID(3), + baseBenchmarkPrice: big.NewInt(1_568 * multiplier), + baseBid: big.NewInt(1_566 * multiplier), + baseAsk: big.NewInt(1_569 * multiplier), + } + linkFeed := Feed{ + name: "LINK/USD", + id: randomFeedID(3), + baseBenchmarkPrice: big.NewInt(7150 * multiplier / 1000), + baseBid: big.NewInt(7123 * multiplier / 1000), + baseAsk: big.NewInt(7177 * multiplier / 1000), + } + feeds := []Feed{btcFeed, ethFeed, linkFeed} + feedM := make(map[[32]byte]Feed, len(feeds)) + for i := range feeds { + feedM[feeds[i].id] = feeds[i] + } + + reqs := make(chan request) + serverKey := csakey.MustNewV2XXXTestingOnly(big.NewInt(-1)) + serverPubKey := serverKey.PublicKey + srv := NewMercuryServer(t, ed25519.PrivateKey(serverKey.Raw()), reqs) + clientCSAKeys := make([]csakey.KeyV2, n+1) + clientPubKeys := make([]ed25519.PublicKey, n+1) + for i := 0; i < n+1; i++ { + k := big.NewInt(int64(i)) + key := csakey.MustNewV2XXXTestingOnly(k) + clientCSAKeys[i] = key + clientPubKeys[i] = key.PublicKey + } + serverURL := startMercuryServer(t, srv, clientPubKeys) + chainID := testutils.SimulatedChainID + + steve, backend, verifier, verifierAddress := setupBlockchain(t) + + // Setup bootstrap + oracle nodes + bootstrapNodePort := int64(21700) + appBootstrap, bootstrapPeerID, _, bootstrapKb, observedLogs := setupNode(t, bootstrapNodePort, "bootstrap_mercury", nil, backend, clientCSAKeys[n]) + bootstrapNode := Node{App: appBootstrap, KeyBundle: bootstrapKb} + logObservers = append(logObservers, observedLogs) + + // Set up n oracles + var ( + oracles []confighelper.OracleIdentityExtra + nodes []Node + ) + for i := int64(0); i < int64(n); i++ { + app, peerID, transmitter, kb, observedLogs := setupNode(t, bootstrapNodePort+i+1, fmt.Sprintf("oracle_mercury%d", i), []commontypes.BootstrapperLocator{ + // Supply the bootstrap IP and port as a V2 peer address + {PeerID: bootstrapPeerID, Addrs: []string{fmt.Sprintf("127.0.0.1:%d", bootstrapNodePort)}}, + }, backend, clientCSAKeys[i]) + + nodes = append(nodes, Node{ + app, transmitter, kb, + }) + + offchainPublicKey, _ := hex.DecodeString(strings.TrimPrefix(kb.OnChainPublicKey(), "0x")) + oracles = append(oracles, confighelper.OracleIdentityExtra{ + OracleIdentity: confighelper.OracleIdentity{ + OnchainPublicKey: offchainPublicKey, + TransmitAccount: ocr2types.Account(fmt.Sprintf("%x", transmitter[:])), + OffchainPublicKey: kb.OffchainPublicKey(), + PeerID: peerID, + }, + ConfigEncryptionPublicKey: kb.ConfigEncryptionPublicKey(), + }) + logObservers = append(logObservers, observedLogs) + } + + for _, feed := range feeds { + addBootstrapJob(t, bootstrapNode, chainID, verifierAddress, feed.name, feed.id) + } + + createBridge := func(name string, i int, p *big.Int, borm bridges.ORM) (bridgeName string) { + bridge := httptest.NewServer(http.HandlerFunc(func(res http.ResponseWriter, req *http.Request) { + b, err := io.ReadAll(req.Body) + require.NoError(t, err) + require.Equal(t, `{"data":{"from":"ETH","to":"USD"}}`, string(b)) + + r := rand.Int63n(101) + if r > pError.Load() { + res.WriteHeader(http.StatusOK) + val := decimal.NewFromBigInt(p, 0).Div(decimal.NewFromInt(multiplier)).Add(decimal.NewFromInt(int64(i)).Div(decimal.NewFromInt(100))).String() + resp := fmt.Sprintf(`{"result": %s}`, val) + _, err := res.Write([]byte(resp)) + require.NoError(t, err) + } else { + res.WriteHeader(http.StatusInternalServerError) + resp := `{"error": "pError test error"}` + _, err := res.Write([]byte(resp)) + require.NoError(t, err) + } + })) + t.Cleanup(bridge.Close) + u, _ := url.Parse(bridge.URL) + bridgeName = fmt.Sprintf("bridge-%s-%d", name, i) + require.NoError(t, borm.CreateBridgeType(&bridges.BridgeType{ + Name: bridges.BridgeName(bridgeName), + URL: models.WebURL(*u), + })) + + return bridgeName + } + + // Add OCR jobs - one per feed on each node + for i, node := range nodes { + for j, feed := range feeds { + bmBridge := createBridge(fmt.Sprintf("benchmarkprice-%d", j), i, feed.baseBenchmarkPrice, node.App.BridgeORM()) + bidBridge := createBridge(fmt.Sprintf("bid-%d", j), i, feed.baseBid, node.App.BridgeORM()) + askBridge := createBridge(fmt.Sprintf("ask-%d", j), i, feed.baseAsk, node.App.BridgeORM()) + + addV3MercuryJob( + t, + node, + i, + verifierAddress, + bootstrapPeerID, + bootstrapNodePort, + bmBridge, + bidBridge, + askBridge, + serverURL, + serverPubKey, + clientPubKeys[i], + feed.name, + feed.id, + randomFeedID(2), + randomFeedID(2), + ) + } + } + + // Setup config on contract + onchainConfig, err := (relaymercury.StandardOnchainConfigCodec{}).Encode(rawOnchainConfig) + require.NoError(t, err) + + reportingPluginConfig, err := json.Marshal(rawReportingPluginConfig) + require.NoError(t, err) -func addMercuryJob( - t *testing.T, - node Node, - i int, - verifierAddress common.Address, - bootstrapPeerID string, - bootstrapNodePort int64, - bmBridge, - bidBridge, - askBridge, - serverURL string, - serverPubKey, - clientPubKey ed25519.PublicKey, - feedName string, - feedID [32]byte, - chainID *big.Int, - fromBlock int, -) { - node.AddJob(t, fmt.Sprintf(` -type = "offchainreporting2" -schemaVersion = 1 -name = "mercury-%[1]d-%[14]s" -forwardingAllowed = false -maxTaskDuration = "1s" -contractID = "%[2]s" -feedID = "0x%[11]x" -contractConfigTrackerPollInterval = "1s" -ocrKeyBundleID = "%[3]s" -p2pv2Bootstrappers = [ - "%[4]s" -] -relay = "evm" -pluginType = "mercury" -transmitterID = "%[10]x" -observationSource = """ - // Benchmark Price - price1 [type=bridge name="%[5]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; - price1_parse [type=jsonparse path="result"]; - price1_multiply [type=multiply times=100000000 index=0]; - - price1 -> price1_parse -> price1_multiply; - - // Bid - bid [type=bridge name="%[6]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; - bid_parse [type=jsonparse path="result"]; - bid_multiply [type=multiply times=100000000 index=1]; - - bid -> bid_parse -> bid_multiply; - - // Ask - ask [type=bridge name="%[7]s" timeout="50ms" requestData="{\\"data\\":{\\"from\\":\\"ETH\\",\\"to\\":\\"USD\\"}}"]; - ask_parse [type=jsonparse path="result"]; - ask_multiply [type=multiply times=100000000 index=2]; - - ask -> ask_parse -> ask_multiply; -""" - -[pluginConfig] -serverURL = "%[8]s" -serverPubKey = "%[9]x" - -[relayConfig] -chainID = %[12]d -fromBlock = %[13]d - `, - i, - verifierAddress, - node.KeyBundle.ID(), - fmt.Sprintf("%s@127.0.0.1:%d", bootstrapPeerID, bootstrapNodePort), - bmBridge, - bidBridge, - askBridge, - serverURL, - serverPubKey, - clientPubKey, - feedID, - chainID, - fromBlock, - feedName, - )) + signers, _, _, onchainConfig, offchainConfigVersion, offchainConfig, err := ocr3confighelper.ContractSetConfigArgsForTestsMercuryV02( + 2*time.Second, // DeltaProgress + 20*time.Second, // DeltaResend + 400*time.Millisecond, // DeltaInitial + 100*time.Millisecond, // DeltaRound + 0, // DeltaGrace + 300*time.Millisecond, // DeltaCertifiedCommitRequest + 1*time.Minute, // DeltaStage + 100, // rMax + []int{len(nodes)}, // S + oracles, + reportingPluginConfig, // reportingPluginConfig []byte, + 250*time.Millisecond, // Max duration observation + int(f), // f + onchainConfig, + ) + + require.NoError(t, err) + signerAddresses, err := evm.OnchainPublicKeyToAddress(signers) + require.NoError(t, err) + + offchainTransmitters := make([][32]byte, n) + for i := 0; i < n; i++ { + offchainTransmitters[i] = nodes[i].ClientPubKey + } + + for _, feed := range feeds { + _, err = verifier.SetConfig( + steve, + feed.id, + signerAddresses, + offchainTransmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig, + nil, + ) + require.NoError(t, err) + backend.Commit() + } + + // Bury it with finality depth + ch, err := bootstrapNode.App.GetChains().EVM.Get(testutils.SimulatedChainID) + require.NoError(t, err) + finalityDepth := ch.Config().EVM().FinalityDepth() + for i := 0; i < int(finalityDepth); i++ { + backend.Commit() + } + + runTestSetup := func() { + // Expect at least one report per feed from each oracle + seen := make(map[[32]byte]map[credentials.StaticSizedPublicKey]struct{}) + for i := range feeds { + // feedID will be deleted when all n oracles have reported + seen[feeds[i].id] = make(map[credentials.StaticSizedPublicKey]struct{}, n) + } + + for req := range reqs { + v := make(map[string]interface{}) + err := mercury.PayloadTypes.UnpackIntoMap(v, req.req.Payload) + require.NoError(t, err) + report, exists := v["report"] + if !exists { + t.Fatalf("expected payload %#v to contain 'report'", v) + } + reportElems := make(map[string]interface{}) + err = reportcodecv3.ReportTypes.UnpackIntoMap(reportElems, report.([]byte)) + require.NoError(t, err) + + feedID := ([32]byte)(reportElems["feedId"].([32]uint8)) + feed, exists := feedM[feedID] + require.True(t, exists) + + if _, exists := seen[feedID]; !exists { + continue // already saw all oracles for this feed + } + + expectedFee := relaymercury.CalculateFee(big.NewInt(123456789), rawReportingPluginConfig.BaseUSDFeeCents) + expectedExpiresAt := reportElems["observationsTimestamp"].(uint32) + rawReportingPluginConfig.ExpirationWindow + + assert.GreaterOrEqual(t, int(reportElems["observationsTimestamp"].(uint32)), int(testStartTimeStamp)) + assert.InDelta(t, feed.baseBenchmarkPrice.Int64(), reportElems["benchmarkPrice"].(*big.Int).Int64(), 5000000) + assert.InDelta(t, feed.baseBid.Int64(), reportElems["bid"].(*big.Int).Int64(), 5000000) + assert.InDelta(t, feed.baseAsk.Int64(), reportElems["ask"].(*big.Int).Int64(), 5000000) + assert.NotZero(t, reportElems["validFromTimestamp"].(uint32)) + assert.GreaterOrEqual(t, reportElems["observationsTimestamp"].(uint32), reportElems["validFromTimestamp"].(uint32)) + assert.Equal(t, expectedExpiresAt, reportElems["expiresAt"].(uint32)) + assert.Equal(t, expectedFee, reportElems["linkFee"].(*big.Int)) + assert.Equal(t, expectedFee, reportElems["nativeFee"].(*big.Int)) + + t.Logf("oracle %x reported for feed %s (0x%x)", req.pk, feed.name, feed.id) + + seen[feedID][req.pk] = struct{}{} + if len(seen[feedID]) == n { + t.Logf("all oracles reported for feed %s (0x%x)", feed.name, feed.id) + delete(seen, feedID) + if len(seen) == 0 { + break // saw all oracles; success! + } + } + } + } + + t.Run("receives at least one report per feed from each oracle when EAs are at 100% reliability", func(t *testing.T) { + runTestSetup() + }) + + t.Run("receives at least one report per feed from each oracle when EAs are at 80% reliability", func(t *testing.T) { + pError.Store(20) + runTestSetup() + }) } diff --git a/core/services/ocr2/plugins/mercury/plugin.go b/core/services/ocr2/plugins/mercury/plugin.go index 1b29fd6ccf0..c38096845ea 100644 --- a/core/services/ocr2/plugins/mercury/plugin.go +++ b/core/services/ocr2/plugins/mercury/plugin.go @@ -7,7 +7,9 @@ import ( libocr2 "github.com/smartcontractkit/libocr/offchainreporting2plus" - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" + relaymercuryv2 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" + relaymercuryv3 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -15,7 +17,10 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/mercury/config" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + mercuryv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1" + mercuryv2 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2" + mercuryv3 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3" ) type Config interface { @@ -31,42 +36,89 @@ func NewServices( argsNoPlugin libocr2.MercuryOracleArgs, cfg Config, chEnhancedTelem chan ocrcommon.EnhancedTelemetryMercuryData, - chainHeadTracker mercury.ChainHeadTracker, - orm mercury.DataSourceORM, - feedID [32]byte, + chainHeadTracker types.ChainHeadTracker, + orm types.DataSourceORM, + feedID types.FeedID, ) ([]job.ServiceCtx, error) { if jb.PipelineSpec == nil { return nil, errors.New("expected job to have a non-nil PipelineSpec") } + var pluginConfig config.PluginConfig err := json.Unmarshal(jb.OCR2OracleSpec.PluginConfig.Bytes(), &pluginConfig) if err != nil { return nil, errors.WithStack(err) } - err = config.ValidatePluginConfig(pluginConfig) + err = config.ValidatePluginConfig(pluginConfig, feedID) if err != nil { return nil, err } lggr = lggr.Named("MercuryPlugin").With("jobID", jb.ID, "jobName", jb.Name.ValueOrZero()) - ds := mercury.NewDataSource( - orm, - pipelineRunner, - jb, - *jb.PipelineSpec, - lggr, - runResults, - chEnhancedTelem, - chainHeadTracker, - ocr2Provider.ContractTransmitter(), - pluginConfig.InitialBlockNumber.Ptr(), - feedID, - ) - argsNoPlugin.MercuryPluginFactory = relaymercury.NewFactory( - ds, - lggr, - ocr2Provider.OnchainConfigCodec(), - ocr2Provider.ReportCodec(), - ) + + switch feedID.Version() { + case 1: + ds := mercuryv1.NewDataSource( + orm, + pipelineRunner, + jb, + *jb.PipelineSpec, + lggr, + runResults, + chEnhancedTelem, + chainHeadTracker, + ocr2Provider.ContractTransmitter(), + pluginConfig.InitialBlockNumber.Ptr(), + feedID, + ) + argsNoPlugin.MercuryPluginFactory = relaymercuryv1.NewFactory( + ds, + lggr, + ocr2Provider.OnchainConfigCodec(), + ocr2Provider.ReportCodecV1(), + ) + case 2: + ds := mercuryv2.NewDataSource( + // TODO: Needs ORM to carry timestamps over + pipelineRunner, + jb, + *jb.PipelineSpec, + feedID, + lggr, + runResults, + chEnhancedTelem, + ocr2Provider.ContractTransmitter(), + *pluginConfig.LinkFeedID, + *pluginConfig.NativeFeedID, + ) + argsNoPlugin.MercuryPluginFactory = relaymercuryv2.NewFactory( + ds, + lggr, + ocr2Provider.OnchainConfigCodec(), + ocr2Provider.ReportCodecV2(), + ) + case 3: + ds := mercuryv3.NewDataSource( + pipelineRunner, + jb, + *jb.PipelineSpec, + feedID, + lggr, + runResults, + chEnhancedTelem, + ocr2Provider.ContractTransmitter(), + *pluginConfig.LinkFeedID, + *pluginConfig.NativeFeedID, + ) + argsNoPlugin.MercuryPluginFactory = relaymercuryv3.NewFactory( + ds, + lggr, + ocr2Provider.OnchainConfigCodec(), + ocr2Provider.ReportCodecV3(), + ) + default: + return nil, errors.Errorf("unknown Mercury report schema version: %d", feedID.Version()) + } + oracle, err := libocr2.NewOracle(argsNoPlugin) if err != nil { return nil, errors.WithStack(err) diff --git a/core/services/ocr2/validate/validate.go b/core/services/ocr2/validate/validate.go index 9c6e86ed9e4..ca1ab60deb9 100644 --- a/core/services/ocr2/validate/validate.go +++ b/core/services/ocr2/validate/validate.go @@ -112,7 +112,7 @@ func validateSpec(tree *toml.Tree, spec job.Job) error { // TODO validator for DR-OCR spec: https://app.shortcut.com/chainlinklabs/story/54054/ocr-plugin-for-directrequest-ocr return nil case job.Mercury: - return validateOCR2MercurySpec(spec.OCR2OracleSpec.PluginConfig) + return validateOCR2MercurySpec(spec.OCR2OracleSpec.PluginConfig, *spec.OCR2OracleSpec.FeedID) case "": return errors.New("no plugin specified") default: @@ -188,11 +188,11 @@ func validateOCR2KeeperSpec(jsonConfig job.JSONConfig) error { return nil } -func validateOCR2MercurySpec(jsonConfig job.JSONConfig) error { +func validateOCR2MercurySpec(jsonConfig job.JSONConfig, feedId [32]byte) error { var pluginConfig mercuryconfig.PluginConfig err := json.Unmarshal(jsonConfig.Bytes(), &pluginConfig) if err != nil { return pkgerrors.Wrap(err, "error while unmarshaling plugin config") } - return pkgerrors.Wrap(mercuryconfig.ValidatePluginConfig(pluginConfig), "Mercury PluginConfig is invalid") + return pkgerrors.Wrap(mercuryconfig.ValidatePluginConfig(pluginConfig, feedId), "Mercury PluginConfig is invalid") } diff --git a/core/services/ocrcommon/telemetry.go b/core/services/ocrcommon/telemetry.go index 7a306249c38..636a18262e1 100644 --- a/core/services/ocrcommon/telemetry.go +++ b/core/services/ocrcommon/telemetry.go @@ -16,7 +16,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/synchronization/telem" "github.com/smartcontractkit/chainlink/v2/core/utils" - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" ) type eaTelemetry struct { @@ -35,7 +35,7 @@ type EnhancedTelemetryData struct { type EnhancedTelemetryMercuryData struct { TaskRunResults pipeline.TaskRunResults - Observation relaymercury.Observation + Observation relaymercuryv1.Observation RepTimestamp ocrtypes.ReportTimestamp } @@ -262,7 +262,7 @@ func (e *EnhancedTelemetryService[T]) collectAndSend(trrs *pipeline.TaskRunResul // collectMercuryEnhancedTelemetry checks if enhanced telemetry should be collected, fetches the information needed and // sends the telemetry -func (e *EnhancedTelemetryService[T]) collectMercuryEnhancedTelemetry(obs relaymercury.Observation, trrs pipeline.TaskRunResults, repts ocrtypes.ReportTimestamp) { +func (e *EnhancedTelemetryService[T]) collectMercuryEnhancedTelemetry(obs relaymercuryv1.Observation, trrs pipeline.TaskRunResults, repts ocrtypes.ReportTimestamp) { if e.monitoringEndpoint == nil { return } @@ -395,7 +395,7 @@ func (e *EnhancedTelemetryService[T]) getPricesFromResults(startTask pipeline.Ta } // getFinalValues runs a parse on the pipeline.TaskRunResults and returns the values -func (e *EnhancedTelemetryService[T]) getFinalValues(obs relaymercury.Observation) (int64, int64, int64, int64, []byte, uint64) { +func (e *EnhancedTelemetryService[T]) getFinalValues(obs relaymercuryv1.Observation) (int64, int64, int64, int64, []byte, uint64) { var benchmarkPrice, bid, ask int64 if obs.BenchmarkPrice.Val != nil { diff --git a/core/services/ocrcommon/telemetry_test.go b/core/services/ocrcommon/telemetry_test.go index 0adf26b526f..e7c41c46761 100644 --- a/core/services/ocrcommon/telemetry_test.go +++ b/core/services/ocrcommon/telemetry_test.go @@ -14,6 +14,7 @@ import ( "google.golang.org/protobuf/proto" "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + mercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -422,7 +423,7 @@ var trrsMercury = pipeline.TaskRunResults{ func TestGetFinalValues(t *testing.T) { e := EnhancedTelemetryService[EnhancedTelemetryMercuryData]{} - o := mercury.Observation{ + o := mercuryv1.Observation{ BenchmarkPrice: mercury.ObsResult[*big.Int]{Val: big.NewInt(111111)}, Bid: mercury.ObsResult[*big.Int]{Val: big.NewInt(222222)}, Ask: mercury.ObsResult[*big.Int]{Val: big.NewInt(333333)}, @@ -439,7 +440,7 @@ func TestGetFinalValues(t *testing.T) { require.Equal(t, blockHash, common.HexToHash("0x123321").Bytes()) require.Equal(t, blockTimestamp, uint64(987654321)) - benchmarkPrice, bid, ask, blockNr, blockHash, blockTimestamp = e.getFinalValues(mercury.Observation{}) + benchmarkPrice, bid, ask, blockNr, blockHash, blockTimestamp = e.getFinalValues(mercuryv1.Observation{}) require.Equal(t, benchmarkPrice, int64(0)) require.Equal(t, bid, int64(0)) require.Equal(t, ask, int64(0)) @@ -581,7 +582,7 @@ func TestCollectMercuryEnhancedTelemetry(t *testing.T) { chTelem <- EnhancedTelemetryMercuryData{ TaskRunResults: trrsMercury, - Observation: mercury.Observation{ + Observation: mercuryv1.Observation{ BenchmarkPrice: mercury.ObsResult[*big.Int]{Val: big.NewInt(111111)}, Bid: mercury.ObsResult[*big.Int]{Val: big.NewInt(222222)}, Ask: mercury.ObsResult[*big.Int]{Val: big.NewInt(333333)}, @@ -633,7 +634,7 @@ func TestCollectMercuryEnhancedTelemetry(t *testing.T) { Value: nil, }}, }, - Observation: mercury.Observation{}, + Observation: mercuryv1.Observation{}, RepTimestamp: types.ReportTimestamp{ ConfigDigest: types.ConfigDigest{2}, Epoch: 11, @@ -644,7 +645,7 @@ func TestCollectMercuryEnhancedTelemetry(t *testing.T) { trrsMercury[0].Result.Value = "" chTelem <- EnhancedTelemetryMercuryData{ TaskRunResults: trrsMercury, - Observation: mercury.Observation{}, + Observation: mercuryv1.Observation{}, RepTimestamp: types.ReportTimestamp{ ConfigDigest: types.ConfigDigest{2}, Epoch: 11, diff --git a/core/services/relay/evm/evm.go b/core/services/relay/evm/evm.go index 8f81fe780e8..b630bf13187 100644 --- a/core/services/relay/evm/evm.go +++ b/core/services/relay/evm/evm.go @@ -35,7 +35,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" + reportcodecv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/reportcodec" + reportcodecv2 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2/reportcodec" + reportcodecv3 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -110,7 +112,12 @@ func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytype return nil, errors.WithStack(err) } - reportCodec := reportcodec.NewEVMReportCodec(*relayConfig.FeedID, r.lggr.Named("ReportCodec")) + // FIXME: We actually know the version here since it's in the feed ID, can + // we use generics to avoid passing three of this? + // https://smartcontract-it.atlassian.net/browse/MERC-1414 + reportCodecV1 := reportcodecv1.NewReportCodec(*relayConfig.FeedID, r.lggr.Named("ReportCodecV1")) + reportCodecV2 := reportcodecv2.NewReportCodec(*relayConfig.FeedID, r.lggr.Named("ReportCodecV2")) + reportCodecV3 := reportcodecv3.NewReportCodec(*relayConfig.FeedID, r.lggr.Named("ReportCodecV3")) if !relayConfig.EffectiveTransmitterID.Valid { return nil, errors.New("EffectiveTransmitterID must be specified") @@ -126,7 +133,7 @@ func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytype } transmitter := mercury.NewTransmitter(r.lggr, configWatcher.ContractConfigTracker(), client, privKey.PublicKey, *relayConfig.FeedID, r.db, r.cfg) - return NewMercuryProvider(configWatcher, transmitter, reportCodec, r.lggr), nil + return NewMercuryProvider(configWatcher, transmitter, reportCodecV1, reportCodecV2, reportCodecV3, r.lggr), nil } func (r *Relayer) NewFunctionsProvider(rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs) (relaytypes.FunctionsProvider, error) { diff --git a/core/services/relay/evm/mercury/config_poller.go b/core/services/relay/evm/mercury/config_poller.go index 8a5eade360c..3a17150a5a9 100644 --- a/core/services/relay/evm/mercury/config_poller.go +++ b/core/services/relay/evm/mercury/config_poller.go @@ -15,6 +15,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" ) // FeedScopedConfigSet ConfigSet with FeedID for use with mercury (and multi-config DON) @@ -39,7 +40,7 @@ func init() { // FullConfigFromLog defines the contract config with the feedID type FullConfigFromLog struct { ocrtypes.ContractConfig - feedID [32]byte + feedID types.FeedID } func unpackLogData(d []byte) (*verifier.VerifierConfigSet, error) { diff --git a/core/services/relay/evm/mercury/helper_test.go b/core/services/relay/evm/mercury/helper_test.go deleted file mode 100644 index d7789888f0c..00000000000 --- a/core/services/relay/evm/mercury/helper_test.go +++ /dev/null @@ -1,83 +0,0 @@ -package mercury - -import ( - "math/big" - "testing" - "time" - - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core" - "github.com/ethereum/go-ethereum/crypto" - "github.com/ethereum/go-ethereum/eth/ethconfig" - "github.com/stretchr/testify/require" - - evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier_proxy" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" - "github.com/smartcontractkit/chainlink/v2/core/logger" - pgmocks "github.com/smartcontractkit/chainlink/v2/core/services/pg/mocks" -) - -type TestHarness struct { - configPoller *ConfigPoller - user *bind.TransactOpts - backend *backends.SimulatedBackend - verifierAddress common.Address - verifierContract *verifier.Verifier - logPoller logpoller.LogPoller - eventBroadcaster *pgmocks.EventBroadcaster - subscription *pgmocks.Subscription -} - -func SetupTH(t *testing.T, feedID common.Hash) TestHarness { - key, err := crypto.GenerateKey() - require.NoError(t, err) - user, err := bind.NewKeyedTransactorWithChainID(key, big.NewInt(1337)) - require.NoError(t, err) - b := backends.NewSimulatedBackend(core.GenesisAlloc{ - user.From: {Balance: big.NewInt(1000000000000000000)}}, - 5*ethconfig.Defaults.Miner.GasCeil) - - proxyAddress, _, verifierProxy, err := verifier_proxy.DeployVerifierProxy(user, b, common.Address{}) - require.NoError(t, err, "failed to deploy test mercury verifier proxy contract") - verifierAddress, _, verifierContract, err := verifier.DeployVerifier(user, b, proxyAddress) - require.NoError(t, err, "failed to deploy test mercury verifier contract") - _, err = verifierProxy.InitializeVerifier(user, verifierAddress) - require.NoError(t, err) - b.Commit() - - db := pgtest.NewSqlxDB(t) - cfg := pgtest.NewQConfig(false) - ethClient := evmclient.NewSimulatedBackendClient(t, b, big.NewInt(1337)) - lggr := logger.TestLogger(t) - ctx := testutils.Context(t) - lorm := logpoller.NewORM(big.NewInt(1337), db, lggr, cfg) - lp := logpoller.NewLogPoller(lorm, ethClient, lggr, 100*time.Millisecond, 1, 2, 2, 1000) - eventBroadcaster := pgmocks.NewEventBroadcaster(t) - subscription := pgmocks.NewSubscription(t) - require.NoError(t, lp.Start(ctx)) - t.Cleanup(func() { lp.Close() }) - - eventBroadcaster.On("Subscribe", "insert_on_evm_logs", "").Return(subscription, nil) - - configPoller, err := NewConfigPoller(lggr, lp, verifierAddress, feedID, eventBroadcaster) - require.NoError(t, err) - - configPoller.Start() - - return TestHarness{ - configPoller: configPoller, - user: user, - backend: b, - verifierAddress: verifierAddress, - verifierContract: verifierContract, - logPoller: lp, - eventBroadcaster: eventBroadcaster, - subscription: subscription, - } -} diff --git a/core/services/relay/evm/mercury/helpers_test.go b/core/services/relay/evm/mercury/helpers_test.go index 2b37df0b39a..54da5b42588 100644 --- a/core/services/relay/evm/mercury/helpers_test.go +++ b/core/services/relay/evm/mercury/helpers_test.go @@ -1,19 +1,67 @@ package mercury import ( - "encoding/base64" "math/big" + "testing" + "time" + "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/accounts/abi/bind/backends" + "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/eth/ethconfig" + "github.com/stretchr/testify/require" + evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier_proxy" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" + "github.com/smartcontractkit/chainlink/v2/core/logger" + pgmocks "github.com/smartcontractkit/chainlink/v2/core/services/pg/mocks" + reportcodecv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/reportcodec" + reportcodecv2 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2/reportcodec" + reportcodecv3 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3/reportcodec" + "github.com/smartcontractkit/chainlink/v2/core/utils" "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" +) - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" - "github.com/smartcontractkit/chainlink/v2/core/utils" +var ( + sampleFeedID = [32]uint8{28, 145, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114} + sampleClientPubKey = hexutil.MustDecode("0x724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93") +) + +var sampleReports [][]byte + +var ( + sampleV1Report = buildSampleV1Report(242) + sampleV2Report = buildSampleV2Report(242) + sampleV3Report = buildSampleV3Report(242) + sig2 = ocrtypes.AttributedOnchainSignature{Signature: testutils.MustDecodeBase64("kbeuRczizOJCxBzj7MUAFpz3yl2WRM6K/f0ieEBvA+oTFUaKslbQey10krumVjzAvlvKxMfyZo0WkOgNyfF6xwE="), Signer: 2} + sig3 = ocrtypes.AttributedOnchainSignature{Signature: testutils.MustDecodeBase64("9jz4b6Dh2WhXxQ97a6/S9UNjSfrEi9016XKTrfN0mLQFDiNuws23x7Z4n+6g0sqKH/hnxx1VukWUH/ohtw83/wE="), Signer: 3} + sampleSigs = []ocrtypes.AttributedOnchainSignature{sig2, sig3} + sampleReportContext = ocrtypes.ReportContext{ + ReportTimestamp: ocrtypes.ReportTimestamp{ + ConfigDigest: MustHexToConfigDigest("0x0006fc30092226b37f6924b464e16a54a7978a9a524519a73403af64d487dc45"), + Epoch: 6, + Round: 28, + }, + ExtraHash: [32]uint8{27, 144, 106, 73, 166, 228, 123, 166, 179, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114}, + } ) -func buildSampleReport(p int64) []byte { +func init() { + sampleReports = make([][]byte, 4) + for i := 0; i < len(sampleReports); i++ { + sampleReports[i] = buildSampleV1Report(int64(i)) + } +} + +func buildSampleV1Report(p int64) []byte { feedID := sampleFeedID timestamp := uint32(42) bp := big.NewInt(p) @@ -24,14 +72,48 @@ func buildSampleReport(p int64) []byte { currentBlockTimestamp := uint64(123) validFromBlockNum := uint64(142) - b, err := reportcodec.ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, currentBlockTimestamp, validFromBlockNum) + b, err := reportcodecv1.ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, currentBlockTimestamp, validFromBlockNum) if err != nil { panic(err) } return b } -func buildSamplePayload() []byte { +func buildSampleV2Report(ts int64) []byte { + feedID := sampleFeedID + timestamp := uint32(ts) + bp := big.NewInt(242) + validFromTimestamp := uint32(123) + expiresAt := uint32(456) + linkFee := big.NewInt(3334455) + nativeFee := big.NewInt(556677) + + b, err := reportcodecv2.ReportTypes.Pack(feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, bp) + if err != nil { + panic(err) + } + return b +} + +func buildSampleV3Report(ts int64) []byte { + feedID := sampleFeedID + timestamp := uint32(ts) + bp := big.NewInt(242) + bid := big.NewInt(243) + ask := big.NewInt(244) + validFromTimestamp := uint32(123) + expiresAt := uint32(456) + linkFee := big.NewInt(3334455) + nativeFee := big.NewInt(556677) + + b, err := reportcodecv3.ReportTypes.Pack(feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, bp, bid, ask) + if err != nil { + panic(err) + } + return b +} + +func buildSamplePayload(report []byte) []byte { var rs [][32]byte var ss [][32]byte var vs [32]byte @@ -45,56 +127,68 @@ func buildSamplePayload() []byte { vs[i] = v } rawReportCtx := evmutil.RawReportContext(sampleReportContext) - payload, err := PayloadTypes.Pack(rawReportCtx, []byte(sampleReport), rs, ss, vs) + payload, err := PayloadTypes.Pack(rawReportCtx, report, rs, ss, vs) if err != nil { panic(err) } return payload } -var sampleReports [][]byte - -func init() { - sampleReports = make([][]byte, 4) - for i := 0; i < len(sampleReports); i++ { - sampleReports[i] = buildSampleReport(int64(i)) - } +type TestHarness struct { + configPoller *ConfigPoller + user *bind.TransactOpts + backend *backends.SimulatedBackend + verifierAddress common.Address + verifierContract *verifier.Verifier + logPoller logpoller.LogPoller + eventBroadcaster *pgmocks.EventBroadcaster + subscription *pgmocks.Subscription } -var ( - sampleFeedID = [32]uint8{28, 145, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114} - sampleReport = buildSampleReport(242) - sampleClientPubKey = hexutil.MustDecode("0x724ff6eae9e900270edfff233e16322a70ec06e1a6e62a81ef13921f398f6c93") - sig2 = ocrtypes.AttributedOnchainSignature{Signature: mustDecodeBase64("kbeuRczizOJCxBzj7MUAFpz3yl2WRM6K/f0ieEBvA+oTFUaKslbQey10krumVjzAvlvKxMfyZo0WkOgNyfF6xwE="), Signer: 2} - sig3 = ocrtypes.AttributedOnchainSignature{Signature: mustDecodeBase64("9jz4b6Dh2WhXxQ97a6/S9UNjSfrEi9016XKTrfN0mLQFDiNuws23x7Z4n+6g0sqKH/hnxx1VukWUH/ohtw83/wE="), Signer: 3} - sampleSigs = []ocrtypes.AttributedOnchainSignature{sig2, sig3} - sampleReportContext = ocrtypes.ReportContext{ - ReportTimestamp: ocrtypes.ReportTimestamp{ - ConfigDigest: mustHexToConfigDigest("0x0006fc30092226b37f6924b464e16a54a7978a9a524519a73403af64d487dc45"), - Epoch: 6, - Round: 28, - }, - ExtraHash: [32]uint8{27, 144, 106, 73, 166, 228, 123, 166, 179, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114}, - } - samplePayload = buildSamplePayload() - samplePayloadHex = hexutil.Encode(samplePayload) -) +func SetupTH(t *testing.T, feedID common.Hash) TestHarness { + key, err := crypto.GenerateKey() + require.NoError(t, err) + user, err := bind.NewKeyedTransactorWithChainID(key, big.NewInt(1337)) + require.NoError(t, err) + b := backends.NewSimulatedBackend(core.GenesisAlloc{ + user.From: {Balance: big.NewInt(1000000000000000000)}}, + 5*ethconfig.Defaults.Miner.GasCeil) -func mustDecodeBase64(s string) (b []byte) { - var err error - b, err = base64.StdEncoding.DecodeString(s) - if err != nil { - panic(err) - } - return -} + proxyAddress, _, verifierProxy, err := verifier_proxy.DeployVerifierProxy(user, b, common.Address{}) + require.NoError(t, err, "failed to deploy test mercury verifier proxy contract") + verifierAddress, _, verifierContract, err := verifier.DeployVerifier(user, b, proxyAddress) + require.NoError(t, err, "failed to deploy test mercury verifier contract") + _, err = verifierProxy.InitializeVerifier(user, verifierAddress) + require.NoError(t, err) + b.Commit() -func mustHexToConfigDigest(s string) (cd ocrtypes.ConfigDigest) { - b := hexutil.MustDecode(s) - var err error - cd, err = ocrtypes.BytesToConfigDigest(b) - if err != nil { - panic(err) + db := pgtest.NewSqlxDB(t) + cfg := pgtest.NewQConfig(false) + ethClient := evmclient.NewSimulatedBackendClient(t, b, big.NewInt(1337)) + lggr := logger.TestLogger(t) + ctx := testutils.Context(t) + lorm := logpoller.NewORM(big.NewInt(1337), db, lggr, cfg) + lp := logpoller.NewLogPoller(lorm, ethClient, lggr, 100*time.Millisecond, 1, 2, 2, 1000) + eventBroadcaster := pgmocks.NewEventBroadcaster(t) + subscription := pgmocks.NewSubscription(t) + require.NoError(t, lp.Start(ctx)) + t.Cleanup(func() { lp.Close() }) + + eventBroadcaster.On("Subscribe", "insert_on_evm_logs", "").Return(subscription, nil) + + configPoller, err := NewConfigPoller(lggr, lp, verifierAddress, feedID, eventBroadcaster) + require.NoError(t, err) + + configPoller.Start() + + return TestHarness{ + configPoller: configPoller, + user: user, + backend: b, + verifierAddress: verifierAddress, + verifierContract: verifierContract, + logPoller: lp, + eventBroadcaster: eventBroadcaster, + subscription: subscription, } - return } diff --git a/core/services/relay/evm/mercury/mocks/chain_head_tracker.go b/core/services/relay/evm/mercury/mocks/chain_head_tracker.go index 72ce3d544a2..84d74673cbc 100644 --- a/core/services/relay/evm/mercury/mocks/chain_head_tracker.go +++ b/core/services/relay/evm/mercury/mocks/chain_head_tracker.go @@ -6,11 +6,11 @@ import ( common "github.com/ethereum/go-ethereum/common" client "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + commontypes "github.com/smartcontractkit/chainlink/v2/common/types" + evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" mock "github.com/stretchr/testify/mock" - - types "github.com/smartcontractkit/chainlink/v2/common/types" ) // ChainHeadTracker is an autogenerated mock type for the ChainHeadTracker type @@ -35,15 +35,15 @@ func (_m *ChainHeadTracker) Client() client.Client { } // HeadTracker provides a mock function with given fields: -func (_m *ChainHeadTracker) HeadTracker() types.HeadTracker[*evmtypes.Head, common.Hash] { +func (_m *ChainHeadTracker) HeadTracker() commontypes.HeadTracker[*evmtypes.Head, common.Hash] { ret := _m.Called() - var r0 types.HeadTracker[*evmtypes.Head, common.Hash] - if rf, ok := ret.Get(0).(func() types.HeadTracker[*evmtypes.Head, common.Hash]); ok { + var r0 commontypes.HeadTracker[*evmtypes.Head, common.Hash] + if rf, ok := ret.Get(0).(func() commontypes.HeadTracker[*evmtypes.Head, common.Hash]); ok { r0 = rf() } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(types.HeadTracker[*evmtypes.Head, common.Hash]) + r0 = ret.Get(0).(commontypes.HeadTracker[*evmtypes.Head, common.Hash]) } } diff --git a/core/services/relay/evm/mercury/mocks/pipeline.go b/core/services/relay/evm/mercury/mocks/pipeline.go new file mode 100644 index 00000000000..317404e4409 --- /dev/null +++ b/core/services/relay/evm/mercury/mocks/pipeline.go @@ -0,0 +1,39 @@ +package mocks + +import ( + "context" + "time" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" +) + +type MockRunner struct { + Trrs pipeline.TaskRunResults + Err error +} + +func (m *MockRunner) ExecuteRun(ctx context.Context, spec pipeline.Spec, vars pipeline.Vars, l logger.Logger) (run pipeline.Run, trrs pipeline.TaskRunResults, err error) { + return pipeline.Run{ID: 42}, m.Trrs, m.Err +} + +var _ pipeline.Task = &MockTask{} + +type MockTask struct { + result pipeline.Result +} + +func (m *MockTask) Type() pipeline.TaskType { return "MockTask" } +func (m *MockTask) ID() int { return 0 } +func (m *MockTask) DotID() string { return "" } +func (m *MockTask) Run(ctx context.Context, lggr logger.Logger, vars pipeline.Vars, inputs []pipeline.Result) (pipeline.Result, pipeline.RunInfo) { + return m.result, pipeline.RunInfo{} +} +func (m *MockTask) Base() *pipeline.BaseTask { return nil } +func (m *MockTask) Outputs() []pipeline.Task { return nil } +func (m *MockTask) Inputs() []pipeline.TaskDependency { return nil } +func (m *MockTask) OutputIndex() int32 { return 0 } +func (m *MockTask) TaskTimeout() (time.Duration, bool) { return 0, false } +func (m *MockTask) TaskRetries() uint32 { return 0 } +func (m *MockTask) TaskMinBackoff() time.Duration { return 0 } +func (m *MockTask) TaskMaxBackoff() time.Duration { return 0 } diff --git a/core/services/relay/evm/mercury/offchain_config_digester.go b/core/services/relay/evm/mercury/offchain_config_digester.go index 7fb215c0e60..0dbf7cbbfd6 100644 --- a/core/services/relay/evm/mercury/offchain_config_digester.go +++ b/core/services/relay/evm/mercury/offchain_config_digester.go @@ -7,9 +7,10 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" - "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "github.com/smartcontractkit/wsrpc/credentials" + + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" ) // Originally sourced from: https://github.com/smartcontractkit/offchain-reporting/blob/991ebe1462fd56826a1ddfb34287d542acb2baee/lib/offchainreporting2/chains/evmutil/offchain_config_digester.go @@ -21,16 +22,16 @@ func NewOffchainConfigDigester(feedID [32]byte, chainID *big.Int, contractAddres } type OffchainConfigDigester struct { - FeedID [32]byte + FeedID types.FeedID ChainID *big.Int ContractAddress common.Address } -func (d OffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.ConfigDigest, error) { +func (d OffchainConfigDigester) ConfigDigest(cc ocrtypes.ContractConfig) (ocrtypes.ConfigDigest, error) { signers := []common.Address{} for i, signer := range cc.Signers { if len(signer) != 20 { - return types.ConfigDigest{}, errors.Errorf("%v-th evm signer should be a 20 byte address, but got %x", i, signer) + return ocrtypes.ConfigDigest{}, errors.Errorf("%v-th evm signer should be a 20 byte address, but got %x", i, signer) } a := common.BytesToAddress(signer) signers = append(signers, a) @@ -38,12 +39,12 @@ func (d OffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.Con transmitters := []credentials.StaticSizedPublicKey{} for i, transmitter := range cc.Transmitters { if len(transmitter) != 2*ed25519.PublicKeySize { - return types.ConfigDigest{}, errors.Errorf("%v-th evm transmitter should be a 64 character hex-encoded ed25519 public key, but got '%v' (%d chars)", i, transmitter, len(transmitter)) + return ocrtypes.ConfigDigest{}, errors.Errorf("%v-th evm transmitter should be a 64 character hex-encoded ed25519 public key, but got '%v' (%d chars)", i, transmitter, len(transmitter)) } var t credentials.StaticSizedPublicKey b, err := hex.DecodeString(string(transmitter)) if err != nil { - return types.ConfigDigest{}, errors.Wrapf(err, "%v-th evm transmitter is not valid hex, got: %q", i, transmitter) + return ocrtypes.ConfigDigest{}, errors.Wrapf(err, "%v-th evm transmitter is not valid hex, got: %q", i, transmitter) } copy(t[:], b) @@ -51,7 +52,7 @@ func (d OffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.Con } return configDigest( - d.FeedID, + common.Hash(d.FeedID), d.ChainID, d.ContractAddress, cc.ConfigCount, @@ -64,6 +65,6 @@ func (d OffchainConfigDigester) ConfigDigest(cc types.ContractConfig) (types.Con ), nil } -func (d OffchainConfigDigester) ConfigDigestPrefix() (types.ConfigDigestPrefix, error) { - return types.ConfigDigestPrefixMercuryV02, nil +func (d OffchainConfigDigester) ConfigDigestPrefix() (ocrtypes.ConfigDigestPrefix, error) { + return ocrtypes.ConfigDigestPrefixMercuryV02, nil } diff --git a/core/services/relay/evm/mercury/orm.go b/core/services/relay/evm/mercury/orm.go index 601bc122023..36433f24e2b 100644 --- a/core/services/relay/evm/mercury/orm.go +++ b/core/services/relay/evm/mercury/orm.go @@ -9,13 +9,14 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/lib/pq" + pkgerrors "github.com/pkg/errors" "github.com/smartcontractkit/sqlx" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" ) @@ -27,21 +28,22 @@ type ORM interface { LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) } -type ORMCodec interface { - FeedIDFromReport(report ocrtypes.Report) (feedID [32]byte, err error) +func FeedIDFromReport(report ocrtypes.Report) (feedID types.FeedID, err error) { + if n := copy(feedID[:], report); n != 32 { + return feedID, pkgerrors.Errorf("invalid length for report: %d", len(report)) + } + return feedID, nil } type orm struct { - q pg.Q - codec ORMCodec + q pg.Q } func NewORM(db *sqlx.DB, lggr logger.Logger, cfg pg.QConfig) ORM { namedLogger := lggr.Named("MercuryORM") q := pg.NewQ(db, namedLogger, cfg) return &orm{ - q: q, - codec: (&reportcodec.EVMReportCodec{}), + q: q, } } @@ -61,7 +63,7 @@ func (o *orm) InsertTransmitRequest(req *pb.TransmitRequest, reportCtx ocrtypes. `, req.Payload, hashPayload(req.Payload), reportCtx.ConfigDigest[:], reportCtx.Epoch, reportCtx.Round, reportCtx.ExtraHash[:]) }() - feedID, err := o.codec.FeedIDFromReport(req.Payload) + feedID, err := FeedIDFromReport(req.Payload) if err != nil { return err } diff --git a/core/services/relay/evm/mercury/orm_test.go b/core/services/relay/evm/mercury/orm_test.go index 27dba9b5c92..39db450442f 100644 --- a/core/services/relay/evm/mercury/orm_test.go +++ b/core/services/relay/evm/mercury/orm_test.go @@ -249,3 +249,20 @@ func TestORM_InsertTransmitRequest_LatestReport(t *testing.T) { assert.Equal(t, reports[3], l) }) } + +func Test_ReportCodec_FeedIDFromReport(t *testing.T) { + t.Run("FeedIDFromReport extracts the current block number from a valid report", func(t *testing.T) { + report := buildSampleV1Report(42) + + f, err := FeedIDFromReport(report) + require.NoError(t, err) + + assert.Equal(t, sampleFeedID[:], f[:]) + }) + t.Run("FeedIDFromReport returns error if report is invalid", func(t *testing.T) { + report := []byte{1} + + _, err := FeedIDFromReport(report) + assert.EqualError(t, err, "invalid length for report: 1") + }) +} diff --git a/core/services/relay/evm/mercury/reportcodec/factories_test.go b/core/services/relay/evm/mercury/reportcodec/factories_test.go deleted file mode 100644 index 89cf6cee7a9..00000000000 --- a/core/services/relay/evm/mercury/reportcodec/factories_test.go +++ /dev/null @@ -1,94 +0,0 @@ -package reportcodec - -import ( - "math/big" - - "github.com/ethereum/go-ethereum/common/hexutil" - - "github.com/smartcontractkit/libocr/commontypes" - - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" -) - -func NewValidParsedAttributedObservations() []relaymercury.ParsedAttributedObservation { - return []relaymercury.ParsedAttributedObservation{ - relaymercury.ParsedAttributedObservation{ - Timestamp: 1676484822, - Observer: commontypes.OracleID(1), - - BenchmarkPrice: big.NewInt(345), - Bid: big.NewInt(343), - Ask: big.NewInt(347), - PricesValid: true, - - CurrentBlockNum: 16634364, - CurrentBlockHash: hexutil.MustDecode("8f30cda279821c5bb6f72f7ab900aa5118215ce59fcf8835b12d0cdbadc9d7b0"), - CurrentBlockTimestamp: 1682908180, - CurrentBlockValid: true, - - MaxFinalizedBlockNumber: 16634355, - MaxFinalizedBlockNumberValid: true, - }, - relaymercury.ParsedAttributedObservation{ - Timestamp: 1676484826, - Observer: commontypes.OracleID(2), - - BenchmarkPrice: big.NewInt(335), - Bid: big.NewInt(332), - Ask: big.NewInt(336), - PricesValid: true, - - CurrentBlockNum: 16634364, - CurrentBlockHash: hexutil.MustDecode("8f30cda279821c5bb6f72f7ab900aa5118215ce59fcf8835b12d0cdbadc9d7b0"), - CurrentBlockTimestamp: 1682908180, - CurrentBlockValid: true, - - MaxFinalizedBlockNumber: 16634355, - MaxFinalizedBlockNumberValid: true, - }, - relaymercury.ParsedAttributedObservation{ - Timestamp: 1676484828, - Observer: commontypes.OracleID(3), - - BenchmarkPrice: big.NewInt(347), - Bid: big.NewInt(345), - Ask: big.NewInt(350), - PricesValid: true, - - CurrentBlockNum: 16634365, - CurrentBlockHash: hexutil.MustDecode("40044147503a81e9f2a225f4717bf5faf5dc574f69943bdcd305d5ed97504a7e"), - CurrentBlockTimestamp: 1682591344, - CurrentBlockValid: true, - - MaxFinalizedBlockNumber: 16634355, - MaxFinalizedBlockNumberValid: true, - }, - relaymercury.ParsedAttributedObservation{ - Timestamp: 1676484830, - Observer: commontypes.OracleID(4), - - BenchmarkPrice: big.NewInt(346), - Bid: big.NewInt(347), - Ask: big.NewInt(350), - PricesValid: true, - - CurrentBlockNum: 16634365, - CurrentBlockHash: hexutil.MustDecode("40044147503a81e9f2a225f4717bf5faf5dc574f69943bdcd305d5ed97504a7e"), - CurrentBlockTimestamp: 1682591344, - CurrentBlockValid: true, - - MaxFinalizedBlockNumber: 16634355, - MaxFinalizedBlockNumberValid: true, - }, - } -} - -func NewInvalidParsedAttributedObservations() []relaymercury.ParsedAttributedObservation { - invalidPaos := NewValidParsedAttributedObservations() - for i := range invalidPaos { - invalidPaos[i].PricesValid = false - invalidPaos[i].CurrentBlockValid = false - invalidPaos[i].MaxFinalizedBlockNumberValid = false - } - return invalidPaos -} diff --git a/core/services/relay/evm/mercury/test_helpers.go b/core/services/relay/evm/mercury/test_helpers.go new file mode 100644 index 00000000000..27093268b3e --- /dev/null +++ b/core/services/relay/evm/mercury/test_helpers.go @@ -0,0 +1,39 @@ +package mercury + +import ( + "github.com/ethereum/go-ethereum/common/hexutil" + + "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" +) + +func BuildSamplePayload(report []byte, reportCtx ocrtypes.ReportContext, sigs []ocrtypes.AttributedOnchainSignature) []byte { + var rs [][32]byte + var ss [][32]byte + var vs [32]byte + for i, as := range sigs { + r, s, v, err := evmutil.SplitSignature(as.Signature) + if err != nil { + panic("eventTransmit(ev): error in SplitSignature") + } + rs = append(rs, r) + ss = append(ss, s) + vs[i] = v + } + rawReportCtx := evmutil.RawReportContext(reportCtx) + payload, err := PayloadTypes.Pack(rawReportCtx, report, rs, ss, vs) + if err != nil { + panic(err) + } + return payload +} + +func MustHexToConfigDigest(s string) (cd ocrtypes.ConfigDigest) { + b := hexutil.MustDecode(s) + var err error + cd, err = ocrtypes.BytesToConfigDigest(b) + if err != nil { + panic(err) + } + return +} diff --git a/core/services/relay/evm/mercury/transmitter.go b/core/services/relay/evm/mercury/transmitter.go index 76c294b5418..e70e6fd1db5 100644 --- a/core/services/relay/evm/mercury/transmitter.go +++ b/core/services/relay/evm/mercury/transmitter.go @@ -6,6 +6,7 @@ import ( "crypto/ed25519" "errors" "fmt" + "math/big" "sync" "time" @@ -24,8 +25,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -86,8 +88,7 @@ type mercuryTransmitter struct { cfgTracker ConfigTracker persistenceManager *PersistenceManager - feedID [32]byte - feedIDHex string + feedID types.FeedID fromAccount string stopCh utils.StopChan @@ -128,7 +129,6 @@ func NewTransmitter(lggr logger.Logger, cfgTracker ConfigTracker, rpcClient wsrp cfgTracker, persistenceManager, feedID, - feedIDHex, fmt.Sprintf("%x", fromAccount), make(chan (struct{})), NewTransmitQueue(lggr, feedIDHex, maxTransmitQueueSize, nil, persistenceManager), @@ -149,7 +149,7 @@ func (mt *mercuryTransmitter) Start(ctx context.Context) (err error) { if err != nil { return err } - mt.queue = NewTransmitQueue(mt.lggr, mt.feedIDHex, maxTransmitQueueSize, transmissions, mt.persistenceManager) + mt.queue = NewTransmitQueue(mt.lggr, mt.feedID.String(), maxTransmitQueueSize, transmissions, mt.persistenceManager) if err := mt.rpcClient.Start(ctx); err != nil { return err @@ -244,25 +244,8 @@ func (mt *mercuryTransmitter) runQueueLoop() { mt.transmitDuplicateCount.Inc() mt.lggr.Tracew("Transmit report succeeded; duplicate report", "code", res.Code) default: - elems := map[string]interface{}{} - var validFrom int64 - var currentBlock int64 - var unpackErr error - if err = PayloadTypes.UnpackIntoMap(elems, t.Req.Payload); err != nil { - unpackErr = err - } else { - report := elems["report"].([]byte) - validFrom, err = (&reportcodec.EVMReportCodec{}).ValidFromBlockNumFromReport(report) - if err != nil { - unpackErr = err - } - currentBlock, err = (&reportcodec.EVMReportCodec{}).CurrentBlockNumFromReport(report) - if err != nil { - unpackErr = errors.Join(unpackErr, err) - } - } - transmitServerErrorCount.WithLabelValues(mt.feedIDHex, fmt.Sprintf("%d", res.Code)).Inc() - mt.lggr.Errorw("Transmit report failed; mercury server returned error", "unpackErr", unpackErr, "validFromBlock", validFrom, "currentBlock", currentBlock, "response", res, "reportCtx", t.ReportCtx, "err", res.Error, "code", res.Code) + transmitServerErrorCount.WithLabelValues(mt.feedID.String(), fmt.Sprintf("%d", res.Code)).Inc() + mt.lggr.Errorw("Transmit report failed; mercury server returned error", "response", res, "reportCtx", t.ReportCtx, "err", res.Error, "code", res.Code) } } @@ -321,29 +304,86 @@ func (mt *mercuryTransmitter) LatestConfigDigestAndEpoch(ctx context.Context) (c func (mt *mercuryTransmitter) FetchInitialMaxFinalizedBlockNumber(ctx context.Context) (*int64, error) { mt.lggr.Trace("FetchInitialMaxFinalizedBlockNumber") + + report, err := mt.latestReport(ctx, mt.feedID) + if err != nil { + return nil, err + } + + if report == nil { + mt.lggr.Debugw("FetchInitialMaxFinalizedBlockNumber success; got nil report") + return nil, nil + } + + mt.lggr.Debugw("FetchInitialMaxFinalizedBlockNumber success", "currentBlockNum", report.CurrentBlockNumber) + + return &report.CurrentBlockNumber, nil +} + +func (mt *mercuryTransmitter) LatestPrice(ctx context.Context, feedID [32]byte) (*big.Int, error) { + mt.lggr.Trace("LatestPrice") + + report, err := mt.latestReport(ctx, feedID) + if err != nil { + return nil, err + } + if report == nil { + return nil, nil + } + price, err := relaymercury.DecodeValueInt192(report.Price) + if err != nil { + return nil, pkgerrors.Wrap(err, "failed to decode report.Price as *big.Int") + } + return price, nil +} + +func (mt *mercuryTransmitter) LatestTimestamp(ctx context.Context) (uint32, error) { + mt.lggr.Trace("LatestTimestamp") + + report, err := mt.latestReport(ctx, mt.feedID) + if err != nil { + return 0, err + } + + if report == nil { + mt.lggr.Debugw("LatestTimestamp success; got nil report") + return 0, nil + } + + mt.lggr.Debugw("LatestTimestamp success", "timestamp", report.ObservationsTimestamp) + + return uint32(report.ObservationsTimestamp), nil +} + +func (mt *mercuryTransmitter) latestReport(ctx context.Context, feedID [32]byte) (*pb.Report, error) { + mt.lggr.Trace("latestReport") + req := &pb.LatestReportRequest{ - FeedId: mt.feedID[:], + FeedId: feedID[:], } resp, err := mt.rpcClient.LatestReport(ctx, req) if err != nil { - mt.lggr.Errorw("FetchInitialMaxFinalizedBlockNumber failed", "err", err) - return nil, pkgerrors.Wrap(err, "FetchInitialMaxFinalizedBlockNumber failed to fetch LatestReport") + mt.lggr.Warnw("latestReport failed", "err", err) + return nil, pkgerrors.Wrap(err, "latestReport failed") } if resp == nil { - return nil, errors.New("FetchInitialMaxFinalizedBlockNumber expected LatestReport to return non-nil response") + return nil, errors.New("latestReport expected non-nil response") } if resp.Error != "" { err = errors.New(resp.Error) - mt.lggr.Errorw("FetchInitialMaxFinalizedBlockNumber failed; mercury server returned error", "err", err) + mt.lggr.Warnw("latestReport failed; mercury server returned error", "err", err) return nil, err } if resp.Report == nil { + mt.lggr.Tracew("latestReport success: returned nil") return nil, nil - } else if !bytes.Equal(resp.Report.FeedId, mt.feedID[:]) { - return nil, fmt.Errorf("FetchInitialMaxFinalizedBlockNumber failed; mismatched feed IDs, expected: 0x%x, got: 0x%x", mt.feedID, resp.Report.FeedId) + } else if !bytes.Equal(resp.Report.FeedId, feedID[:]) { + err = fmt.Errorf("latestReport failed; mismatched feed IDs, expected: 0x%x, got: 0x%x", mt.feedID[:], resp.Report.FeedId[:]) + mt.lggr.Errorw("latestReport failed", "err", err) + return nil, err } - mt.lggr.Debugw("FetchInitialMaxFinalizedBlockNumber success", "currentBlockNum", resp.Report.CurrentBlockNumber) + mt.lggr.Tracew("latestReport success", "currentBlockNum", resp.Report.CurrentBlockNumber) - return &resp.Report.CurrentBlockNumber, nil + return resp.Report, nil } diff --git a/core/services/relay/evm/mercury/transmitter_test.go b/core/services/relay/evm/mercury/transmitter_test.go index af0d06ce9c5..ae2fd3c1c23 100644 --- a/core/services/relay/evm/mercury/transmitter_test.go +++ b/core/services/relay/evm/mercury/transmitter_test.go @@ -2,6 +2,7 @@ package mercury import ( "context" + "math/big" "testing" "github.com/ethereum/go-ethereum/common/hexutil" @@ -9,36 +10,59 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/mocks" + mocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" ) -type MockTracker struct { - latestConfigDetails func(ctx context.Context) (changedInBlock uint64, configDigest ocrtypes.ConfigDigest, err error) -} - -func (m MockTracker) LatestConfigDetails(ctx context.Context) (changedInBlock uint64, configDigest ocrtypes.ConfigDigest, err error) { - return m.latestConfigDetails(ctx) -} - -var _ ConfigTracker = &MockTracker{} - func Test_MercuryTransmitter_Transmit(t *testing.T) { - t.Parallel() - lggr := logger.TestLogger(t) db := pgtest.NewSqlxDB(t) - t.Run("transmission successfully enqueued", func(t *testing.T) { + t.Run("v1 report transmission successfully enqueued", func(t *testing.T) { + report := sampleV1Report + c := mocks.MockWSRPCClient{ + TransmitF: func(ctx context.Context, in *pb.TransmitRequest) (out *pb.TransmitResponse, err error) { + require.NotNil(t, in) + assert.Equal(t, hexutil.Encode(buildSamplePayload(report)), hexutil.Encode(in.Payload)) + out = new(pb.TransmitResponse) + out.Code = 42 + out.Error = "" + return out, nil + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + err := mt.Transmit(testutils.Context(t), sampleReportContext, report, sampleSigs) + + require.NoError(t, err) + }) + t.Run("v2 report transmission successfully enqueued", func(t *testing.T) { + report := sampleV2Report + c := mocks.MockWSRPCClient{ + TransmitF: func(ctx context.Context, in *pb.TransmitRequest) (out *pb.TransmitResponse, err error) { + require.NotNil(t, in) + assert.Equal(t, hexutil.Encode(buildSamplePayload(report)), hexutil.Encode(in.Payload)) + out = new(pb.TransmitResponse) + out.Code = 42 + out.Error = "" + return out, nil + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + err := mt.Transmit(testutils.Context(t), sampleReportContext, report, sampleSigs) + + require.NoError(t, err) + }) + t.Run("v3 report transmission successfully enqueued", func(t *testing.T) { + report := sampleV3Report c := mocks.MockWSRPCClient{ TransmitF: func(ctx context.Context, in *pb.TransmitRequest) (out *pb.TransmitResponse, err error) { require.NotNil(t, in) - assert.Equal(t, samplePayloadHex, hexutil.Encode(in.Payload)) + assert.Equal(t, hexutil.Encode(buildSamplePayload(report)), hexutil.Encode(in.Payload)) out = new(pb.TransmitResponse) out.Code = 42 out.Error = "" @@ -46,12 +70,118 @@ func Test_MercuryTransmitter_Transmit(t *testing.T) { }, } mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) - err := mt.Transmit(testutils.Context(t), sampleReportContext, sampleReport, sampleSigs) + err := mt.Transmit(testutils.Context(t), sampleReportContext, report, sampleSigs) require.NoError(t, err) }) } +func Test_MercuryTransmitter_LatestTimestamp(t *testing.T) { + t.Parallel() + lggr := logger.TestLogger(t) + db := pgtest.NewSqlxDB(t) + + t.Run("successful query", func(t *testing.T) { + c := mocks.MockWSRPCClient{ + LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { + require.NotNil(t, in) + assert.Equal(t, hexutil.Encode(sampleFeedID[:]), hexutil.Encode(in.FeedId)) + out = new(pb.LatestReportResponse) + out.Report = new(pb.Report) + out.Report.FeedId = sampleFeedID[:] + out.Report.ObservationsTimestamp = 42 + return out, nil + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + ts, err := mt.LatestTimestamp(testutils.Context(t)) + require.NoError(t, err) + + assert.Equal(t, ts, uint32(42)) + }) + + t.Run("successful query returning nil report (new feed)", func(t *testing.T) { + c := mocks.MockWSRPCClient{ + LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { + out = new(pb.LatestReportResponse) + out.Report = nil + return out, nil + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + ts, err := mt.LatestTimestamp(testutils.Context(t)) + require.NoError(t, err) + + assert.Zero(t, ts) + }) + + t.Run("failing query", func(t *testing.T) { + c := mocks.MockWSRPCClient{ + LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { + return nil, errors.New("something exploded") + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + _, err := mt.LatestTimestamp(testutils.Context(t)) + require.Error(t, err) + assert.Contains(t, err.Error(), "something exploded") + }) +} + +func Test_MercuryTransmitter_LatestPrice(t *testing.T) { + t.Parallel() + lggr := logger.TestLogger(t) + db := pgtest.NewSqlxDB(t) + + t.Run("successful query", func(t *testing.T) { + originalPrice := big.NewInt(123456789) + encodedPrice, _ := relaymercury.EncodeValueInt192(originalPrice) + c := mocks.MockWSRPCClient{ + LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { + require.NotNil(t, in) + assert.Equal(t, hexutil.Encode(sampleFeedID[:]), hexutil.Encode(in.FeedId)) + out = new(pb.LatestReportResponse) + out.Report = new(pb.Report) + out.Report.FeedId = sampleFeedID[:] + out.Report.Price = encodedPrice + return out, nil + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + price, err := mt.LatestPrice(testutils.Context(t), sampleFeedID) + require.NoError(t, err) + + assert.Equal(t, price, originalPrice) + }) + + t.Run("successful query returning nil report (new feed)", func(t *testing.T) { + c := mocks.MockWSRPCClient{ + LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { + out = new(pb.LatestReportResponse) + out.Report = nil + return out, nil + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + price, err := mt.LatestPrice(testutils.Context(t), sampleFeedID) + require.NoError(t, err) + + assert.Nil(t, price) + }) + + t.Run("failing query", func(t *testing.T) { + c := mocks.MockWSRPCClient{ + LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { + return nil, errors.New("something exploded") + }, + } + mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) + _, err := mt.LatestPrice(testutils.Context(t), sampleFeedID) + require.Error(t, err) + assert.Contains(t, err.Error(), "something exploded") + }) +} + func Test_MercuryTransmitter_FetchInitialMaxFinalizedBlockNumber(t *testing.T) { t.Parallel() @@ -117,6 +247,6 @@ func Test_MercuryTransmitter_FetchInitialMaxFinalizedBlockNumber(t *testing.T) { mt := NewTransmitter(lggr, nil, c, sampleClientPubKey, sampleFeedID, db, pgtest.NewQConfig(true)) _, err := mt.FetchInitialMaxFinalizedBlockNumber(testutils.Context(t)) require.Error(t, err) - assert.Contains(t, err.Error(), "FetchInitialMaxFinalizedBlockNumber failed; mismatched feed IDs, expected: 0x1c916b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472, got: 0x") + assert.Contains(t, err.Error(), "latestReport failed; mismatched feed IDs, expected: 0x1c916b4aa7e57ca7b68ae1bf45653f56b656fd3aa335ef7fae696b663f1b8472, got: 0x") }) } diff --git a/core/services/relay/evm/mercury/types/types.go b/core/services/relay/evm/mercury/types/types.go new file mode 100644 index 00000000000..8102a34e4ee --- /dev/null +++ b/core/services/relay/evm/mercury/types/types.go @@ -0,0 +1,49 @@ +package types + +import ( + "context" + "encoding/binary" + + evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +type FeedIDPrefix uint16 + +const ( + _ FeedIDPrefix = 0 // reserved to prevent errors where a zero-default creeps through somewhere + REPORT_V1 FeedIDPrefix = 1 + REPORT_V2 FeedIDPrefix = 2 + REPORT_V3 FeedIDPrefix = 3 + _ FeedIDPrefix = 0xFFFF // reserved for future use +) + +type FeedID [32]byte + +func (f FeedID) Hex() string { return (utils.Hash)(f).Hex() } + +func (f FeedID) String() string { return (utils.Hash)(f).String() } + +func (f *FeedID) UnmarshalText(input []byte) error { + return (*utils.Hash)(f).UnmarshalText(input) +} + +func (f FeedID) Version() FeedIDPrefix { + return FeedIDPrefix(binary.BigEndian.Uint16(f[:2])) +} + +func (f FeedID) IsV1() bool { return f.Version() == REPORT_V1 } +func (f FeedID) IsV2() bool { return f.Version() == REPORT_V2 } +func (f FeedID) IsV3() bool { return f.Version() == REPORT_V3 } + +//go:generate mockery --quiet --name ChainHeadTracker --output ../mocks/ --case=underscore +type ChainHeadTracker interface { + Client() evmclient.Client + HeadTracker() httypes.HeadTracker +} + +type DataSourceORM interface { + LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) +} diff --git a/core/services/relay/evm/mercury/types/types_test.go b/core/services/relay/evm/mercury/types/types_test.go new file mode 100644 index 00000000000..3a18d6368ce --- /dev/null +++ b/core/services/relay/evm/mercury/types/types_test.go @@ -0,0 +1,30 @@ +package types + +import ( + "testing" + + "github.com/stretchr/testify/assert" +) + +var ( + v1FeedId = (FeedID)([32]uint8{00, 01, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114}) + v2FeedId = (FeedID)([32]uint8{00, 02, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114}) + v3FeedId = (FeedID)([32]uint8{00, 03, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114}) +) + +func Test_FeedID(t *testing.T) { + assert.Equal(t, REPORT_V1, v1FeedId.Version()) + assert.True(t, v1FeedId.IsV1()) + assert.False(t, v1FeedId.IsV2()) + assert.False(t, v1FeedId.IsV3()) + + assert.Equal(t, REPORT_V2, v2FeedId.Version()) + assert.False(t, v2FeedId.IsV1()) + assert.True(t, v2FeedId.IsV2()) + assert.False(t, v2FeedId.IsV3()) + + assert.Equal(t, REPORT_V3, v3FeedId.Version()) + assert.False(t, v3FeedId.IsV1()) + assert.False(t, v3FeedId.IsV2()) + assert.True(t, v3FeedId.IsV3()) +} diff --git a/core/services/relay/evm/mercury/data_source.go b/core/services/relay/evm/mercury/v1/data_source.go similarity index 87% rename from core/services/relay/evm/mercury/data_source.go rename to core/services/relay/evm/mercury/v1/data_source.go index d09e424ada2..1bdbd725c88 100644 --- a/core/services/relay/evm/mercury/data_source.go +++ b/core/services/relay/evm/mercury/v1/data_source.go @@ -1,4 +1,4 @@ -package mercury +package mercury_v1 import ( "context" @@ -12,32 +12,25 @@ import ( ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" - evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" - httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" - "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/utils" ) -//go:generate mockery --quiet --name ChainHeadTracker --output ./mocks/ --case=underscore -type ChainHeadTracker interface { - Client() evmclient.Client - HeadTracker() httypes.HeadTracker -} - type Runner interface { ExecuteRun(ctx context.Context, spec pipeline.Spec, vars pipeline.Vars, l logger.Logger) (run pipeline.Run, trrs pipeline.TaskRunResults, err error) } +// Fetcher fetcher data from Mercury server type Fetcher interface { - // FetchInitialMaxFinalizedBlockNumber should fetch the initial max - // finalized block number from the mercury server. + // FetchInitialMaxFinalizedBlockNumber should fetch the initial max finalized block number FetchInitialMaxFinalizedBlockNumber(context.Context) (*int64, error) } @@ -47,29 +40,25 @@ type datasource struct { spec pipeline.Spec lggr logger.Logger runResults chan<- pipeline.Run - orm DataSourceORM - codec relaymercury.ReportCodec + orm types.DataSourceORM + codec reportcodec.ReportCodec feedID [32]byte mu sync.RWMutex chEnhancedTelem chan<- ocrcommon.EnhancedTelemetryMercuryData - chainHeadTracker ChainHeadTracker + chainHeadTracker types.ChainHeadTracker fetcher Fetcher initialBlockNumber *int64 } -var _ relaymercury.DataSource = &datasource{} - -type DataSourceORM interface { - LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) -} +var _ relaymercuryv1.DataSource = &datasource{} -func NewDataSource(orm DataSourceORM, pr pipeline.Runner, jb job.Job, spec pipeline.Spec, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, chainHeadTracker ChainHeadTracker, fetcher Fetcher, initialBlockNumber *int64, feedID [32]byte) *datasource { - return &datasource{pr, jb, spec, lggr, rr, orm, &reportcodec.EVMReportCodec{}, feedID, sync.RWMutex{}, enhancedTelemChan, chainHeadTracker, fetcher, initialBlockNumber} +func NewDataSource(orm types.DataSourceORM, pr pipeline.Runner, jb job.Job, spec pipeline.Spec, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, chainHeadTracker types.ChainHeadTracker, fetcher Fetcher, initialBlockNumber *int64, feedID [32]byte) *datasource { + return &datasource{pr, jb, spec, lggr, rr, orm, reportcodec.ReportCodec{}, feedID, sync.RWMutex{}, enhancedTelemChan, chainHeadTracker, fetcher, initialBlockNumber} } -func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestamp, fetchMaxFinalizedBlockNum bool) (obs relaymercury.Observation, err error) { +func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestamp, fetchMaxFinalizedBlockNum bool) (obs relaymercuryv1.Observation, err error) { // setCurrentBlock must come first, along with observationTimestamp, to // avoid front-running ds.setCurrentBlock(ctx, &obs) @@ -265,7 +254,7 @@ func (ds *datasource) executeRun(ctx context.Context) (pipeline.Run, pipeline.Ta return run, trrs, err } -func (ds *datasource) setCurrentBlock(ctx context.Context, obs *relaymercury.Observation) { +func (ds *datasource) setCurrentBlock(ctx context.Context, obs *relaymercuryv1.Observation) { latestHead, err := ds.getCurrentBlock(ctx) if err != nil { obs.CurrentBlockNum.Err = err diff --git a/core/services/relay/evm/mercury/data_source_test.go b/core/services/relay/evm/mercury/v1/data_source_test.go similarity index 88% rename from core/services/relay/evm/mercury/data_source_test.go rename to core/services/relay/evm/mercury/v1/data_source_test.go index c6f4dec0432..db52e9f3c7d 100644 --- a/core/services/relay/evm/mercury/data_source_test.go +++ b/core/services/relay/evm/mercury/v1/data_source_test.go @@ -1,4 +1,4 @@ -package mercury +package mercury_v1 import ( "context" @@ -16,6 +16,7 @@ import ( ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" commonmocks "github.com/smartcontractkit/chainlink/v2/common/mocks" "github.com/smartcontractkit/chainlink/v2/core/assets" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" @@ -28,11 +29,12 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/reportcodec" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + reportcodecv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/utils" ) -var _ relaymercury.Fetcher = &mockFetcher{} +var _ relaymercury.MercuryServerFetcher = &mockFetcher{} type mockFetcher struct { num *int64 @@ -43,39 +45,15 @@ func (m *mockFetcher) FetchInitialMaxFinalizedBlockNumber(context.Context) (*int return m.num, m.err } -var _ Runner = &mockRunner{} - -type mockRunner struct { - trrs pipeline.TaskRunResults - err error +func (m *mockFetcher) LatestPrice(ctx context.Context, feedID [32]byte) (*big.Int, error) { + return nil, nil } -func (m *mockRunner) ExecuteRun(ctx context.Context, spec pipeline.Spec, vars pipeline.Vars, l logger.Logger) (run pipeline.Run, trrs pipeline.TaskRunResults, err error) { - return pipeline.Run{ID: 42}, m.trrs, m.err +func (m *mockFetcher) LatestTimestamp(context.Context) (uint32, error) { + return 0, nil } -var _ pipeline.Task = &mockTask{} - -type mockTask struct { - result pipeline.Result -} - -func (m *mockTask) Type() pipeline.TaskType { return "MockTask" } -func (m *mockTask) ID() int { return 0 } -func (m *mockTask) DotID() string { return "" } -func (m *mockTask) Run(ctx context.Context, lggr logger.Logger, vars pipeline.Vars, inputs []pipeline.Result) (pipeline.Result, pipeline.RunInfo) { - return m.result, pipeline.RunInfo{} -} -func (m *mockTask) Base() *pipeline.BaseTask { return nil } -func (m *mockTask) Outputs() []pipeline.Task { return nil } -func (m *mockTask) Inputs() []pipeline.TaskDependency { return nil } -func (m *mockTask) OutputIndex() int32 { return 0 } -func (m *mockTask) TaskTimeout() (time.Duration, bool) { return 0, false } -func (m *mockTask) TaskRetries() uint32 { return 0 } -func (m *mockTask) TaskMinBackoff() time.Duration { return 0 } -func (m *mockTask) TaskMaxBackoff() time.Duration { return 0 } - -var _ ChainHeadTracker = &mockHeadTracker{} +var _ types.ChainHeadTracker = &mockHeadTracker{} type mockHeadTracker struct { c evmclient.Client @@ -96,7 +74,7 @@ func (m *mockORM) LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg func TestMercury_Observe(t *testing.T) { orm := &mockORM{} - ds := &datasource{lggr: logger.TestLogger(t), orm: orm, codec: (&reportcodec.EVMReportCodec{})} + ds := &datasource{lggr: logger.TestLogger(t), orm: orm, codec: (reportcodecv1.ReportCodec{})} ctx := testutils.Context(t) repts := ocrtypes.ReportTimestamp{} @@ -104,25 +82,25 @@ func TestMercury_Observe(t *testing.T) { ds.fetcher = fetcher trrs := []pipeline.TaskRunResult{ - pipeline.TaskRunResult{ + { // benchmark price Result: pipeline.Result{Value: "122.345"}, - Task: &mockTask{}, + Task: &mercurymocks.MockTask{}, }, - pipeline.TaskRunResult{ + { // bid Result: pipeline.Result{Value: "121.993"}, - Task: &mockTask{}, + Task: &mercurymocks.MockTask{}, }, - pipeline.TaskRunResult{ + { // ask Result: pipeline.Result{Value: "123.111"}, - Task: &mockTask{}, + Task: &mercurymocks.MockTask{}, }, } - runner := &mockRunner{ - trrs: trrs, + runner := &mercurymocks.MockRunner{ + Trrs: trrs, } ds.pipelineRunner = runner @@ -146,7 +124,7 @@ func TestMercury_Observe(t *testing.T) { t.Run("when fetchMaxFinalizedBlockNum=true", func(t *testing.T) { t.Run("with latest report in database", func(t *testing.T) { - orm.report = sampleReport + orm.report = buildSampleV1Report() orm.err = nil obs, err := ds.Observe(ctx, repts, true) @@ -237,9 +215,9 @@ func TestMercury_Observe(t *testing.T) { t.Run("when fetchMaxFinalizedBlockNum=false", func(t *testing.T) { t.Run("when run execution fails, returns error", func(t *testing.T) { t.Cleanup(func() { - runner.err = nil + runner.Err = nil }) - runner.err = errors.New("run execution failed") + runner.Err = errors.New("run execution failed") _, err := ds.Observe(ctx, repts, false) assert.EqualError(t, err, "Observe failed while executing run: error executing run for spec ID 0: run execution failed") @@ -401,7 +379,7 @@ func TestMercury_SetCurrentBlock(t *testing.T) { ds.chainHeadTracker = chainHeadTracker - obs := relaymercury.Observation{} + obs := relaymercuryv1.Observation{} ds.setCurrentBlock(context.Background(), &obs) assert.Equal(t, h.Number, obs.CurrentBlockNum.Val) @@ -425,7 +403,7 @@ func TestMercury_SetCurrentBlock(t *testing.T) { ds.chainHeadTracker = chainHeadTracker - obs := relaymercury.Observation{} + obs := relaymercuryv1.Observation{} ds.setCurrentBlock(context.Background(), &obs) assert.Equal(t, h.Number, obs.CurrentBlockNum.Val) @@ -451,7 +429,7 @@ func TestMercury_SetCurrentBlock(t *testing.T) { ds.chainHeadTracker = chainHeadTracker - obs := relaymercury.Observation{} + obs := relaymercuryv1.Observation{} ds.setCurrentBlock(context.Background(), &obs) assert.Equal(t, err, obs.CurrentBlockNum.Err) @@ -463,3 +441,23 @@ func TestMercury_SetCurrentBlock(t *testing.T) { headTracker.AssertExpectations(t) }) } + +var sampleFeedID = [32]uint8{28, 145, 107, 74, 167, 229, 124, 167, 182, 138, 225, 191, 69, 101, 63, 86, 182, 86, 253, 58, 163, 53, 239, 127, 174, 105, 107, 102, 63, 27, 132, 114} + +func buildSampleV1Report() []byte { + feedID := sampleFeedID + timestamp := uint32(42) + bp := big.NewInt(242) + bid := big.NewInt(243) + ask := big.NewInt(244) + currentBlockNumber := uint64(143) + currentBlockHash := utils.NewHash() + currentBlockTimestamp := uint64(123) + validFromBlockNum := uint64(142) + + b, err := reportcodecv1.ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, currentBlockTimestamp, validFromBlockNum) + if err != nil { + panic(err) + } + return b +} diff --git a/core/services/relay/evm/mercury/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go similarity index 70% rename from core/services/relay/evm/mercury/reportcodec/report_codec.go rename to core/services/relay/evm/mercury/v1/reportcodec/report_codec.go index 9b28050d2a0..24f7ee385be 100644 --- a/core/services/relay/evm/mercury/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go @@ -3,14 +3,17 @@ package reportcodec import ( "fmt" "math" + "math/big" "github.com/ethereum/go-ethereum/accounts/abi" "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" ) // NOTE: @@ -42,40 +45,51 @@ func getReportTypes() abi.Arguments { }) } -var _ relaymercury.ReportCodec = &EVMReportCodec{} +type Report struct { + FeedId [32]byte + ObservationsTimestamp uint32 + BenchmarkPrice *big.Int + Bid *big.Int + Ask *big.Int + CurrentBlockNum uint64 + CurrentBlockHash [32]byte + ValidFromBlockNum uint64 + CurrentBlockTimestamp uint64 +} + +var _ reportcodec.ReportCodec = &ReportCodec{} -type EVMReportCodec struct { +type ReportCodec struct { logger logger.Logger - feedID [32]byte + feedID types.FeedID } -func NewEVMReportCodec(feedID [32]byte, lggr logger.Logger) *EVMReportCodec { - return &EVMReportCodec{lggr, feedID} +func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { + return &ReportCodec{lggr, feedID} } -func (r *EVMReportCodec) BuildReport(paos []relaymercury.ParsedAttributedObservation, f int, validFromBlockNum int64) (ocrtypes.Report, error) { +func (r *ReportCodec) BuildReport(paos []reportcodec.ParsedAttributedObservation, f int, validFromBlockNum int64) (ocrtypes.Report, error) { if len(paos) == 0 { return nil, errors.Errorf("cannot build report from empty attributed observations") } - // copy so we can safely sort in place - paos = append([]relaymercury.ParsedAttributedObservation{}, paos...) + mPaos := reportcodec.Convert(paos) - timestamp := relaymercury.GetConsensusTimestamp(paos) - benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(paos, f) + timestamp := relaymercury.GetConsensusTimestamp(mPaos) + benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(mPaos, f) if err != nil { return nil, errors.Wrap(err, "GetConsensusBenchmarkPrice failed") } - bid, err := relaymercury.GetConsensusBid(paos, f) + bid, err := relaymercury.GetConsensusBid(mPaos, f) if err != nil { return nil, errors.Wrap(err, "GetConsensusBid failed") } - ask, err := relaymercury.GetConsensusAsk(paos, f) + ask, err := relaymercury.GetConsensusAsk(mPaos, f) if err != nil { return nil, errors.Wrap(err, "GetConsensusAsk failed") } - currentBlockHash, currentBlockNum, currentBlockTimestamp, err := relaymercury.GetConsensusCurrentBlock(paos, f) + currentBlockHash, currentBlockNum, currentBlockTimestamp, err := reportcodec.GetConsensusCurrentBlock(paos, f) if err != nil { return nil, errors.Wrap(err, "GetConsensusCurrentBlock failed") } @@ -96,18 +110,11 @@ func (r *EVMReportCodec) BuildReport(paos []relaymercury.ParsedAttributedObserva // Maximum length in bytes of Report returned by BuildReport. Used for // defending against spam attacks. -func (r *EVMReportCodec) MaxReportLength(n int) (int, error) { +func (r *ReportCodec) MaxReportLength(n int) (int, error) { return maxReportLength, nil } -func (r *EVMReportCodec) FeedIDFromReport(report ocrtypes.Report) (feedID [32]byte, err error) { - if n := copy(feedID[:], report); n != 32 { - return feedID, errors.Errorf("invalid length for report: %d", len(report)) - } - return feedID, nil -} - -func (r *EVMReportCodec) CurrentBlockNumFromReport(report ocrtypes.Report) (int64, error) { +func (r *ReportCodec) CurrentBlockNumFromReport(report ocrtypes.Report) (int64, error) { reportElems := map[string]interface{}{} if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { return 0, errors.Errorf("error during unpack: %v", err) @@ -130,7 +137,7 @@ func (r *EVMReportCodec) CurrentBlockNumFromReport(report ocrtypes.Report) (int6 return int64(blockNum), nil } -func (r *EVMReportCodec) ValidFromBlockNumFromReport(report ocrtypes.Report) (int64, error) { +func (r *ReportCodec) ValidFromBlockNumFromReport(report ocrtypes.Report) (int64, error) { reportElems := map[string]interface{}{} if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { return 0, errors.Errorf("error during unpack: %v", err) @@ -152,3 +159,16 @@ func (r *EVMReportCodec) ValidFromBlockNumFromReport(report ocrtypes.Report) (in return int64(blockNum), nil } + +// Decode is made available to external users (i.e. mercury server) +func (r *ReportCodec) Decode(report ocrtypes.Report) (*Report, error) { + values, err := ReportTypes.Unpack(report) + if err != nil { + return nil, fmt.Errorf("failed to decode report: %w", err) + } + decoded := new(Report) + if err = ReportTypes.Copy(decoded, values); err != nil { + return nil, fmt.Errorf("failed to copy report values to struct: %w", err) + } + return decoded, nil +} diff --git a/core/services/relay/evm/mercury/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go similarity index 62% rename from core/services/relay/evm/mercury/reportcodec/report_codec_test.go rename to core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go index 05b33d13a87..da6dae56dc3 100644 --- a/core/services/relay/evm/mercury/reportcodec/report_codec_test.go +++ b/core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go @@ -12,79 +12,26 @@ import ( "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" "github.com/smartcontractkit/chainlink/v2/core/utils" ) var hash = hexutil.MustDecode("0x552c2cea3ab43bae137d89ee6142a01db3ae2b5678bc3c9bd5f509f537bea57b") -var paos = []relaymercury.ParsedAttributedObservation{ - { - Timestamp: uint32(42), - Observer: commontypes.OracleID(49), - - BenchmarkPrice: big.NewInt(43), - Bid: big.NewInt(44), - Ask: big.NewInt(45), - PricesValid: true, - - CurrentBlockNum: 48, - CurrentBlockHash: hash, - CurrentBlockTimestamp: uint64(123), - CurrentBlockValid: true, - }, - { - Timestamp: uint32(142), - Observer: commontypes.OracleID(149), - - BenchmarkPrice: big.NewInt(143), - Bid: big.NewInt(144), - Ask: big.NewInt(145), - PricesValid: true, - - CurrentBlockNum: 48, - CurrentBlockHash: hash, - CurrentBlockTimestamp: uint64(123), - CurrentBlockValid: true, - }, - { - Timestamp: uint32(242), - Observer: commontypes.OracleID(249), - - BenchmarkPrice: big.NewInt(243), - Bid: big.NewInt(244), - Ask: big.NewInt(245), - PricesValid: true, - - CurrentBlockNum: 248, - CurrentBlockHash: hash, - CurrentBlockTimestamp: uint64(789), - CurrentBlockValid: true, - }, - { - Timestamp: uint32(342), - Observer: commontypes.OracleID(250), - - BenchmarkPrice: big.NewInt(343), - Bid: big.NewInt(344), - Ask: big.NewInt(345), - PricesValid: true, - - CurrentBlockNum: 348, - CurrentBlockHash: hash, - CurrentBlockTimestamp: uint64(123456), - CurrentBlockValid: true, - }, +var paos = []relaymercuryv1.ParsedAttributedObservation{ + relaymercuryv1.NewParsedAttributedObservation(42, commontypes.OracleID(49), big.NewInt(43), big.NewInt(44), big.NewInt(45), true, 248, hash, 123, true, 10, true), + relaymercuryv1.NewParsedAttributedObservation(142, commontypes.OracleID(149), big.NewInt(143), big.NewInt(144), big.NewInt(145), true, 248, hash, 123, true, 11, true), + relaymercuryv1.NewParsedAttributedObservation(242, commontypes.OracleID(249), big.NewInt(243), big.NewInt(244), big.NewInt(245), true, 248, hash, 123, true, 12, true), + relaymercuryv1.NewParsedAttributedObservation(342, commontypes.OracleID(250), big.NewInt(343), big.NewInt(344), big.NewInt(345), true, 842, hash, 456, true, 13, true), } -func Test_ReportCodec_BuildReport(t *testing.T) { - r := EVMReportCodec{} - +func Test_ReportCodec(t *testing.T) { + r := ReportCodec{} f := 1 t.Run("BuildReport errors if observations are empty", func(t *testing.T) { - paos := []relaymercury.ParsedAttributedObservation{} - _, err := r.BuildReport(paos, f, 1) + ps := []relaymercuryv1.ParsedAttributedObservation{} + _, err := r.BuildReport(ps, f, 1) require.Error(t, err) assert.Contains(t, err.Error(), "cannot build report from empty attributed observation") }) @@ -103,33 +50,66 @@ func Test_ReportCodec_BuildReport(t *testing.T) { assert.Equal(t, reportElems["benchmarkPrice"].(*big.Int).Int64(), int64(243)) assert.Equal(t, reportElems["bid"].(*big.Int).Int64(), int64(244)) assert.Equal(t, reportElems["ask"].(*big.Int).Int64(), int64(245)) - assert.Equal(t, reportElems["currentBlockNum"].(uint64), uint64(48)) + assert.Equal(t, reportElems["currentBlockNum"].(uint64), uint64(248)) assert.Equal(t, common.Hash(reportElems["currentBlockHash"].([32]byte)), common.BytesToHash(hash)) assert.Equal(t, reportElems["currentBlockTimestamp"].(uint64), uint64(123)) assert.Equal(t, reportElems["validFromBlockNum"].(uint64), uint64(46)) - assert.Equal(t, types.Report{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf2, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf5, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x30, 0x55, 0x2c, 0x2c, 0xea, 0x3a, 0xb4, 0x3b, 0xae, 0x13, 0x7d, 0x89, 0xee, 0x61, 0x42, 0xa0, 0x1d, 0xb3, 0xae, 0x2b, 0x56, 0x78, 0xbc, 0x3c, 0x9b, 0xd5, 0xf5, 0x9, 0xf5, 0x37, 0xbe, 0xa5, 0x7b, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2e, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7b}, report) + assert.Equal(t, types.Report{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf2, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf5, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf8, 0x55, 0x2c, 0x2c, 0xea, 0x3a, 0xb4, 0x3b, 0xae, 0x13, 0x7d, 0x89, 0xee, 0x61, 0x42, 0xa0, 0x1d, 0xb3, 0xae, 0x2b, 0x56, 0x78, 0xbc, 0x3c, 0x9b, 0xd5, 0xf5, 0x9, 0xf5, 0x37, 0xbe, 0xa5, 0x7b, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x2e, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7b}, report) + max, err := r.MaxReportLength(4) require.NoError(t, err) assert.LessOrEqual(t, len(report), max) + + t.Run("Decode decodes the report", func(t *testing.T) { + decoded, err := r.Decode(report) + require.NoError(t, err) + + require.NotNil(t, decoded) + + assert.Equal(t, uint32(242), decoded.ObservationsTimestamp) + assert.Equal(t, big.NewInt(243), decoded.BenchmarkPrice) + assert.Equal(t, big.NewInt(244), decoded.Bid) + assert.Equal(t, big.NewInt(245), decoded.Ask) + assert.Equal(t, uint64(248), decoded.CurrentBlockNum) + assert.Equal(t, [32]byte(common.BytesToHash(hash)), decoded.CurrentBlockHash) + assert.Equal(t, uint64(123), decoded.CurrentBlockTimestamp) + assert.Equal(t, uint64(46), decoded.ValidFromBlockNum) + }) }) -} -func Test_ReportCodec_MaxReportLength(t *testing.T) { - r := EVMReportCodec{} - n := len(paos) - report, err := r.BuildReport(paos, 1, 46) - require.NoError(t, err) + t.Run("Decode errors on invalid report", func(t *testing.T) { + _, err := r.Decode([]byte{1, 2, 3}) + assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") - t.Run("MaxReportLength returns length of report", func(t *testing.T) { - max, err := r.MaxReportLength(n) - require.NoError(t, err) - assert.Equal(t, len(report), max) + longBad := make([]byte, 64) + for i := 0; i < len(longBad); i++ { + longBad[i] = byte(i) + } + _, err = r.Decode(longBad) + assert.EqualError(t, err, "failed to decode report: abi: improperly encoded uint32 value") }) } +func buildSampleReport(bn int64, feedID [32]byte) []byte { + timestamp := uint32(42) + bp := big.NewInt(242) + bid := big.NewInt(243) + ask := big.NewInt(244) + currentBlockNumber := uint64(bn) + currentBlockHash := utils.NewHash() + currentBlockTimestamp := uint64(123) + validFromBlockNum := uint64(143) + + b, err := ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, currentBlockTimestamp, validFromBlockNum) + if err != nil { + panic(err) + } + return b +} + func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { - r := EVMReportCodec{} + r := ReportCodec{} feedID := utils.NewHash() var validBn int64 = 42 @@ -152,42 +132,3 @@ func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { assert.Contains(t, err.Error(), "blockNum overflows max int64, got: 18446744073709551615") }) } - -func Test_ReportCodec_FeedIDFromReport(t *testing.T) { - r := EVMReportCodec{} - - feedID := utils.NewHash() - var validBn int64 = 42 - - t.Run("FeedIDFromReport extracts the current block number from a valid report", func(t *testing.T) { - report := buildSampleReport(validBn, feedID) - - f, err := r.FeedIDFromReport(report) - require.NoError(t, err) - - assert.Equal(t, feedID[:], f[:]) - }) - t.Run("FeedIDFromReport returns error if report is invalid", func(t *testing.T) { - report := []byte{1} - - _, err := r.FeedIDFromReport(report) - assert.EqualError(t, err, "invalid length for report: 1") - }) -} - -func buildSampleReport(bn int64, feedID [32]byte) []byte { - timestamp := uint32(42) - bp := big.NewInt(242) - bid := big.NewInt(243) - ask := big.NewInt(244) - currentBlockNumber := uint64(bn) - currentBlockHash := utils.NewHash() - currentBlockTimestamp := uint64(123) - validFromBlockNum := uint64(143) - - b, err := ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, currentBlockTimestamp, validFromBlockNum) - if err != nil { - panic(err) - } - return b -} diff --git a/core/services/relay/evm/mercury/v2/data_source.go b/core/services/relay/evm/mercury/v2/data_source.go new file mode 100644 index 00000000000..bbeed56a178 --- /dev/null +++ b/core/services/relay/evm/mercury/v2/data_source.go @@ -0,0 +1,215 @@ +package mercury_v2 + +import ( + "context" + "fmt" + "math/big" + "sync" + + pkgerrors "github.com/pkg/errors" + + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv2 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" + "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +type Runner interface { + ExecuteRun(ctx context.Context, spec pipeline.Spec, vars pipeline.Vars, l logger.Logger) (run pipeline.Run, trrs pipeline.TaskRunResults, err error) +} + +type LatestReportFetcher interface { + LatestPrice(ctx context.Context, feedID [32]byte) (*big.Int, error) + LatestTimestamp(context.Context) (uint32, error) +} + +type datasource struct { + pipelineRunner Runner + jb job.Job + spec pipeline.Spec + feedID types.FeedID + lggr logger.Logger + runResults chan<- pipeline.Run + + fetcher LatestReportFetcher + linkFeedID types.FeedID + nativeFeedID types.FeedID + + mu sync.RWMutex + + chEnhancedTelem chan<- ocrcommon.EnhancedTelemetryMercuryData +} + +var _ relaymercuryv2.DataSource = &datasource{} + +var maxInt192 = new(big.Int).Exp(big.NewInt(2), big.NewInt(191), nil) + +func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID types.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID types.FeedID) *datasource { + return &datasource{pr, jb, spec, feedID, lggr, rr, fetcher, linkFeedID, nativeFeedID, sync.RWMutex{}, enhancedTelemChan} +} + +func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestamp, fetchMaxFinalizedTimestamp bool) (obs relaymercuryv2.Observation, err error) { + var wg sync.WaitGroup + ctx, cancel := context.WithCancel(ctx) + + if fetchMaxFinalizedTimestamp { + wg.Add(1) + go func() { + defer wg.Done() + obs.MaxFinalizedTimestamp.Val, obs.MaxFinalizedTimestamp.Err = ds.fetcher.LatestTimestamp(ctx) + }() + } + + wg.Add(1) + go func() { + defer wg.Done() + var trrs pipeline.TaskRunResults + var run pipeline.Run + run, trrs, err = ds.executeRun(ctx) + if err != nil { + cancel() + err = fmt.Errorf("Observe failed while executing run: %w", err) + return + } + select { + case ds.runResults <- run: + default: + ds.lggr.Warnf("unable to enqueue run save for job ID %d, buffer full", ds.spec.JobID) + } + + var parsed parseOutput + parsed, err = ds.parse(trrs) + if err != nil { + cancel() + // This is not expected under normal circumstances + ds.lggr.Errorw("Observe failed while parsing run results", "err", err) + err = fmt.Errorf("Observe failed while parsing run results: %w", err) + return + } + obs.BenchmarkPrice = parsed.benchmarkPrice + }() + + var isLink, isNative bool + if ds.feedID == ds.linkFeedID { + isLink = true + } else { + wg.Add(1) + go func() { + defer wg.Done() + obs.LinkPrice.Val, obs.LinkPrice.Err = ds.fetcher.LatestPrice(ctx, ds.linkFeedID) + if obs.LinkPrice.Val == nil && obs.LinkPrice.Err == nil { + ds.lggr.Warnw("Mercury server was missing LINK feed, falling back to max int192", "linkFeedID", ds.linkFeedID) + obs.LinkPrice.Val = maxInt192 + } + }() + } + + if ds.feedID == ds.nativeFeedID { + isNative = true + } else { + wg.Add(1) + go func() { + defer wg.Done() + obs.NativePrice.Val, obs.NativePrice.Err = ds.fetcher.LatestPrice(ctx, ds.nativeFeedID) + if obs.NativePrice.Val == nil && obs.NativePrice.Err == nil { + ds.lggr.Warnw("Mercury server was missing native feed, falling back to max int192", "nativeFeedID", ds.nativeFeedID) + obs.NativePrice.Val = maxInt192 + } + }() + } + + wg.Wait() + cancel() + + if isLink || isNative { + // run has now completed so it is safe to use err or benchmark price + if err != nil { + return + } + if isLink { + // This IS the LINK feed, use our observed price + obs.LinkPrice.Val, obs.LinkPrice.Err = obs.BenchmarkPrice.Val, obs.BenchmarkPrice.Err + } + if isNative { + // This IS the native feed, use our observed price + obs.NativePrice.Val, obs.NativePrice.Err = obs.BenchmarkPrice.Val, obs.BenchmarkPrice.Err + } + } + + // todo: implement telemetry - https://smartcontract-it.atlassian.net/browse/MERC-1388 + // if ocrcommon.ShouldCollectEnhancedTelemetryMercury(&ds.jb) { + // ocrcommon.EnqueueEnhancedTelem(ds.chEnhancedTelem, ocrcommon.EnhancedTelemetryMercuryData{ + // TaskRunResults: trrs, + // Observation: obs, + // RepTimestamp: repts, + // }) + // } + + return obs, err +} + +func toBigInt(val interface{}) (*big.Int, error) { + dec, err := utils.ToDecimal(val) + if err != nil { + return nil, err + } + return dec.BigInt(), nil +} + +type parseOutput struct { + benchmarkPrice relaymercury.ObsResult[*big.Int] +} + +func (ds *datasource) parse(trrs pipeline.TaskRunResults) (o parseOutput, merr error) { + var finaltrrs []pipeline.TaskRunResult + for _, trr := range trrs { + // only return terminal trrs from executeRun + if trr.IsTerminal() { + finaltrrs = append(finaltrrs, trr) + } + } + + if len(finaltrrs) != 1 { + return o, fmt.Errorf("invalid number of results, expected: 1, got: %d", len(finaltrrs)) + } + + return o, setBenchmarkPrice(&o, finaltrrs[0].Result) +} + +func setBenchmarkPrice(o *parseOutput, res pipeline.Result) error { + if res.Error != nil { + o.benchmarkPrice.Err = res.Error + return res.Error + } else if val, err := toBigInt(res.Value); err != nil { + return fmt.Errorf("failed to parse BenchmarkPrice: %w", err) + } else { + o.benchmarkPrice.Val = val + } + return nil +} + +// The context passed in here has a timeout of (ObservationTimeout + ObservationGracePeriod). +// Upon context cancellation, its expected that we return any usable values within ObservationGracePeriod. +func (ds *datasource) executeRun(ctx context.Context) (pipeline.Run, pipeline.TaskRunResults, error) { + vars := pipeline.NewVarsFrom(map[string]interface{}{ + "jb": map[string]interface{}{ + "databaseID": ds.jb.ID, + "externalJobID": ds.jb.ExternalJobID, + "name": ds.jb.Name.ValueOrZero(), + }, + }) + + run, trrs, err := ds.pipelineRunner.ExecuteRun(ctx, ds.spec, vars, ds.lggr) + if err != nil { + return pipeline.Run{}, nil, pkgerrors.Wrapf(err, "error executing run for spec ID %v", ds.spec.ID) + } + + return run, trrs, err +} diff --git a/core/services/relay/evm/mercury/v2/data_source_test.go b/core/services/relay/evm/mercury/v2/data_source_test.go new file mode 100644 index 00000000000..98b2c1e6b21 --- /dev/null +++ b/core/services/relay/evm/mercury/v2/data_source_test.go @@ -0,0 +1,231 @@ +package mercury_v2 + +import ( + "context" + "math/big" + "testing" + + "github.com/pkg/errors" + "github.com/stretchr/testify/assert" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" +) + +var _ relaymercury.MercuryServerFetcher = &mockFetcher{} + +type mockFetcher struct { + ts uint32 + tsErr error + linkPrice *big.Int + linkPriceErr error + nativePrice *big.Int + nativePriceErr error +} + +var feedId types.FeedID = [32]byte{1} +var linkFeedId types.FeedID = [32]byte{2} +var nativeFeedId types.FeedID = [32]byte{3} + +func (m *mockFetcher) FetchInitialMaxFinalizedBlockNumber(context.Context) (*int64, error) { + return nil, nil +} + +func (m *mockFetcher) LatestPrice(ctx context.Context, fId [32]byte) (*big.Int, error) { + if fId == linkFeedId { + return m.linkPrice, m.linkPriceErr + } else if fId == nativeFeedId { + return m.nativePrice, m.nativePriceErr + } + return nil, nil +} + +func (m *mockFetcher) LatestTimestamp(context.Context) (uint32, error) { + return m.ts, m.tsErr +} + +func Test_Datasource(t *testing.T) { + ds := &datasource{lggr: logger.TestLogger(t)} + ctx := testutils.Context(t) + repts := ocrtypes.ReportTimestamp{} + + fetcher := &mockFetcher{} + ds.fetcher = fetcher + + goodTrrs := []pipeline.TaskRunResult{ + { + // bp + Result: pipeline.Result{Value: "122.345"}, + Task: &mercurymocks.MockTask{}, + }, + } + + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: goodTrrs, + } + + spec := pipeline.Spec{} + ds.spec = spec + + t.Run("when fetchMaxFinalizedTimestamp=true", func(t *testing.T) { + t.Run("if LatestTimestamp returns error", func(t *testing.T) { + fetcher.tsErr = errors.New("some error") + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.EqualError(t, obs.MaxFinalizedTimestamp.Err, "some error") + assert.Zero(t, obs.MaxFinalizedTimestamp.Val) + }) + + t.Run("if LatestTimestamp succeeds", func(t *testing.T) { + fetcher.tsErr = nil + fetcher.ts = 123 + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.Equal(t, uint32(123), obs.MaxFinalizedTimestamp.Val) + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + }) + + t.Run("if LatestTimestamp succeeds but ts=0 (new feed)", func(t *testing.T) { + fetcher.tsErr = nil + fetcher.ts = 0 + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + assert.Zero(t, obs.MaxFinalizedTimestamp.Val) + }) + + t.Run("when run execution succeeded", func(t *testing.T) { + t.Run("when feedId=linkFeedID=nativeFeedId", func(t *testing.T) { + t.Cleanup(func() { + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, linkFeedId, nativeFeedId + }) + + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, feedId, feedId + + fetcher.ts = 123123 + fetcher.tsErr = nil + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.Equal(t, big.NewInt(122), obs.BenchmarkPrice.Val) + assert.NoError(t, obs.BenchmarkPrice.Err) + assert.Equal(t, uint32(123123), obs.MaxFinalizedTimestamp.Val) + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) + assert.NoError(t, obs.LinkPrice.Err) + assert.Equal(t, big.NewInt(122), obs.NativePrice.Val) + assert.NoError(t, obs.NativePrice.Err) + }) + }) + }) + + t.Run("when fetchMaxFinalizedTimestamp=false", func(t *testing.T) { + t.Run("when run execution fails, returns error", func(t *testing.T) { + t.Cleanup(func() { + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: goodTrrs, + Err: nil, + } + }) + + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: goodTrrs, + Err: errors.New("run execution failed"), + } + + _, err := ds.Observe(ctx, repts, false) + assert.EqualError(t, err, "Observe failed while executing run: error executing run for spec ID 0: run execution failed") + }) + + t.Run("when parsing run results fails, return error", func(t *testing.T) { + t.Cleanup(func() { + runner := &mercurymocks.MockRunner{ + Trrs: goodTrrs, + Err: nil, + } + ds.pipelineRunner = runner + }) + + badTrrs := []pipeline.TaskRunResult{ + { + // benchmark price + Result: pipeline.Result{Error: errors.New("some error with bp")}, + Task: &mercurymocks.MockTask{}, + }, + } + + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: badTrrs, + Err: nil, + } + + _, err := ds.Observe(ctx, repts, false) + assert.EqualError(t, err, "Observe failed while parsing run results: some error with bp") + }) + + t.Run("when run execution succeeded", func(t *testing.T) { + t.Run("when feedId=linkFeedID=nativeFeedId", func(t *testing.T) { + t.Cleanup(func() { + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, linkFeedId, nativeFeedId + }) + + var feedId types.FeedID = [32]byte{1} + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, feedId, feedId + + obs, err := ds.Observe(ctx, repts, false) + assert.NoError(t, err) + + assert.Equal(t, big.NewInt(122), obs.BenchmarkPrice.Val) + assert.NoError(t, obs.BenchmarkPrice.Err) + assert.Equal(t, uint32(0), obs.MaxFinalizedTimestamp.Val) + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) + assert.NoError(t, obs.LinkPrice.Err) + assert.Equal(t, big.NewInt(122), obs.NativePrice.Val) + assert.NoError(t, obs.NativePrice.Err) + }) + + t.Run("when fails to fetch linkPrice or nativePrice", func(t *testing.T) { + t.Cleanup(func() { + fetcher.linkPriceErr = nil + fetcher.nativePriceErr = nil + }) + + fetcher.linkPriceErr = errors.New("some error fetching link price") + fetcher.nativePriceErr = errors.New("some error fetching native price") + + obs, err := ds.Observe(ctx, repts, false) + assert.NoError(t, err) + + assert.Nil(t, obs.LinkPrice.Val) + assert.EqualError(t, obs.LinkPrice.Err, "some error fetching link price") + assert.Nil(t, obs.NativePrice.Val) + assert.EqualError(t, obs.NativePrice.Err, "some error fetching native price") + }) + + t.Run("when succeeds to fetch linkPrice or nativePrice but got nil (new feed)", func(t *testing.T) { + obs, err := ds.Observe(ctx, repts, false) + assert.NoError(t, err) + + assert.Equal(t, obs.LinkPrice.Val, maxInt192) + assert.Nil(t, obs.LinkPrice.Err) + assert.Equal(t, obs.NativePrice.Val, maxInt192) + assert.Nil(t, obs.NativePrice.Err) + }) + }) + }) +} diff --git a/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go new file mode 100644 index 00000000000..ccf9abd6996 --- /dev/null +++ b/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go @@ -0,0 +1,127 @@ +package reportcodec + +import ( + "fmt" + "math" + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/pkg/errors" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" +) + +var ReportTypes = getReportTypes() +var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word + +func getReportTypes() abi.Arguments { + mustNewType := func(t string) abi.Type { + result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) + if err != nil { + panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) + } + return result + } + return abi.Arguments([]abi.Argument{ + {Name: "feedId", Type: mustNewType("bytes32")}, + {Name: "validFromTimestamp", Type: mustNewType("uint32")}, + {Name: "observationsTimestamp", Type: mustNewType("uint32")}, + {Name: "nativeFee", Type: mustNewType("int192")}, + {Name: "linkFee", Type: mustNewType("int192")}, + {Name: "expiresAt", Type: mustNewType("uint32")}, + {Name: "benchmarkPrice", Type: mustNewType("int192")}, + }) +} + +type Report struct { + FeedId [32]byte + ObservationsTimestamp uint32 + BenchmarkPrice *big.Int + ValidFromTimestamp uint32 + ExpiresAt uint32 + LinkFee *big.Int + NativeFee *big.Int +} + +var _ reportcodec.ReportCodec = &ReportCodec{} + +type ReportCodec struct { + logger logger.Logger + feedID types.FeedID +} + +func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { + return &ReportCodec{lggr, feedID} +} + +func (r *ReportCodec) BuildReport(paos []reportcodec.ParsedAttributedObservation, f int, validFromTimestamp, expiresAt uint32) (ocrtypes.Report, error) { + if len(paos) == 0 { + return nil, errors.Errorf("cannot build report from empty attributed observations") + } + + mPaos := reportcodec.Convert(paos) + + timestamp := relaymercury.GetConsensusTimestamp(mPaos) + + benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusBenchmarkPrice failed") + } + + linkFee, err := relaymercury.GetConsensusLinkFee(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusLinkFee failed") + } + nativeFee, err := relaymercury.GetConsensusNativeFee(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusNativeFee failed") + } + + reportBytes, err := ReportTypes.Pack(r.feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, benchmarkPrice) + return ocrtypes.Report(reportBytes), errors.Wrap(err, "failed to pack report blob") +} + +func (r *ReportCodec) MaxReportLength(n int) (int, error) { + return maxReportLength, nil +} + +func (r *ReportCodec) ObservationTimestampFromReport(report ocrtypes.Report) (uint32, error) { + reportElems := map[string]interface{}{} + if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { + return 0, errors.Errorf("error during unpack: %v", err) + } + + timestampIface, ok := reportElems["observationsTimestamp"] + if !ok { + return 0, errors.Errorf("unpacked report has no 'observationTimestamp' field") + } + + timestamp, ok := timestampIface.(uint32) + if !ok { + return 0, errors.Errorf("cannot cast timestamp to uint32, type is %T", timestampIface) + } + + if timestamp > math.MaxInt32 { + return 0, errors.Errorf("timestamp overflows max uint32, got: %d", timestamp) + } + + return timestamp, nil +} + +// Decode is made available to external users (i.e. mercury server) +func (r *ReportCodec) Decode(report ocrtypes.Report) (*Report, error) { + values, err := ReportTypes.Unpack(report) + if err != nil { + return nil, fmt.Errorf("failed to decode report: %w", err) + } + decoded := new(Report) + if err = ReportTypes.Copy(decoded, values); err != nil { + return nil, fmt.Errorf("failed to copy report values to struct: %w", err) + } + return decoded, nil +} diff --git a/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go new file mode 100644 index 00000000000..4e5a79bc50d --- /dev/null +++ b/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go @@ -0,0 +1,120 @@ +package reportcodec + +import ( + "math" + "math/big" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/libocr/commontypes" + "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaymercuryv2 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" +) + +var paos = []relaymercuryv2.ParsedAttributedObservation{ + relaymercuryv2.NewParsedAttributedObservation(42, commontypes.OracleID(49), big.NewInt(43), true, 123, true, big.NewInt(143), true, big.NewInt(457), true), + relaymercuryv2.NewParsedAttributedObservation(142, commontypes.OracleID(149), big.NewInt(143), true, 455, true, big.NewInt(456), true, big.NewInt(345), true), + relaymercuryv2.NewParsedAttributedObservation(242, commontypes.OracleID(249), big.NewInt(243), true, 789, true, big.NewInt(764), true, big.NewInt(167), true), + relaymercuryv2.NewParsedAttributedObservation(342, commontypes.OracleID(250), big.NewInt(343), true, 123, true, big.NewInt(378), true, big.NewInt(643), true), +} + +func Test_ReportCodec_BuildReport(t *testing.T) { + r := ReportCodec{} + f := 1 + + t.Run("BuildReport errors if observations are empty", func(t *testing.T) { + ps := []relaymercuryv2.ParsedAttributedObservation{} + _, err := r.BuildReport(ps, f, 123, 10) + require.Error(t, err) + assert.Contains(t, err.Error(), "cannot build report from empty attributed observation") + }) + + t.Run("BuildReport constructs a report from observations", func(t *testing.T) { + // only need to test happy path since validations are done in relaymercury + + report, err := r.BuildReport(paos, f, 123, 20) + require.NoError(t, err) + + reportElems := make(map[string]interface{}) + err = ReportTypes.UnpackIntoMap(reportElems, report) + require.NoError(t, err) + + assert.Equal(t, int(reportElems["observationsTimestamp"].(uint32)), 242) + assert.Equal(t, reportElems["benchmarkPrice"].(*big.Int).Int64(), int64(243)) + assert.Equal(t, reportElems["validFromTimestamp"].(uint32), uint32(123)) + assert.Equal(t, reportElems["expiresAt"].(uint32), uint32(20)) + assert.Equal(t, reportElems["linkFee"].(*big.Int).Int64(), int64(456)) + assert.Equal(t, reportElems["nativeFee"].(*big.Int).Int64(), int64(457)) + + assert.Equal(t, types.Report{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7b, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf2, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0xc9, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0xc8, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x14, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf3}, report) + max, err := r.MaxReportLength(4) + require.NoError(t, err) + assert.LessOrEqual(t, len(report), max) + + t.Run("Decode decodes the report", func(t *testing.T) { + decoded, err := r.Decode(report) + require.NoError(t, err) + + require.NotNil(t, decoded) + + assert.Equal(t, uint32(242), decoded.ObservationsTimestamp) + assert.Equal(t, big.NewInt(243), decoded.BenchmarkPrice) + assert.Equal(t, uint32(123), decoded.ValidFromTimestamp) + assert.Equal(t, uint32(20), decoded.ExpiresAt) + assert.Equal(t, big.NewInt(456), decoded.LinkFee) + assert.Equal(t, big.NewInt(457), decoded.NativeFee) + }) + }) + + t.Run("Decode errors on invalid report", func(t *testing.T) { + _, err := r.Decode([]byte{1, 2, 3}) + assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") + + longBad := make([]byte, 64) + for i := 0; i < len(longBad); i++ { + longBad[i] = byte(i) + } + _, err = r.Decode(longBad) + assert.EqualError(t, err, "failed to decode report: abi: improperly encoded uint32 value") + }) +} + +func buildSampleReport(ts int64) []byte { + feedID := [32]byte{'f', 'o', 'o'} + timestamp := uint32(ts) + bp := big.NewInt(242) + validFromTimestamp := uint32(123) + expiresAt := uint32(456) + linkFee := big.NewInt(3334455) + nativeFee := big.NewInt(556677) + + b, err := ReportTypes.Pack(feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, bp) + if err != nil { + panic(err) + } + return b +} + +func Test_ReportCodec_ObservationTimestampFromReport(t *testing.T) { + r := ReportCodec{} + + t.Run("ObservationTimestampFromReport extracts observation timestamp from a valid report", func(t *testing.T) { + report := buildSampleReport(123) + + ts, err := r.ObservationTimestampFromReport(report) + require.NoError(t, err) + + assert.Equal(t, ts, uint32(123)) + }) + t.Run("ObservationTimestampFromReport returns error when timestamp is too big", func(t *testing.T) { + report := buildSampleReport(math.MaxInt32 + 1) + + _, err := r.ObservationTimestampFromReport(report) + require.Error(t, err) + + assert.EqualError(t, err, "timestamp overflows max uint32, got: 2147483648") + }) +} diff --git a/core/services/relay/evm/mercury/v3/data_source.go b/core/services/relay/evm/mercury/v3/data_source.go new file mode 100644 index 00000000000..5dcd7c2a266 --- /dev/null +++ b/core/services/relay/evm/mercury/v3/data_source.go @@ -0,0 +1,253 @@ +package mercury_v3 + +import ( + "context" + "errors" + "fmt" + "math/big" + "sync" + + pkgerrors "github.com/pkg/errors" + + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv3 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/job" + "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" + "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +type Runner interface { + ExecuteRun(ctx context.Context, spec pipeline.Spec, vars pipeline.Vars, l logger.Logger) (run pipeline.Run, trrs pipeline.TaskRunResults, err error) +} + +type LatestReportFetcher interface { + LatestPrice(ctx context.Context, feedID [32]byte) (*big.Int, error) + LatestTimestamp(context.Context) (uint32, error) +} + +type datasource struct { + pipelineRunner Runner + jb job.Job + spec pipeline.Spec + feedID types.FeedID + lggr logger.Logger + runResults chan<- pipeline.Run + + fetcher LatestReportFetcher + linkFeedID types.FeedID + nativeFeedID types.FeedID + + mu sync.RWMutex + + chEnhancedTelem chan<- ocrcommon.EnhancedTelemetryMercuryData +} + +var _ relaymercuryv3.DataSource = &datasource{} + +var maxInt192 = new(big.Int).Exp(big.NewInt(2), big.NewInt(191), nil) + +func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID types.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID types.FeedID) *datasource { + return &datasource{pr, jb, spec, feedID, lggr, rr, fetcher, linkFeedID, nativeFeedID, sync.RWMutex{}, enhancedTelemChan} +} + +func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestamp, fetchMaxFinalizedTimestamp bool) (obs relaymercuryv3.Observation, err error) { + var wg sync.WaitGroup + ctx, cancel := context.WithCancel(ctx) + + if fetchMaxFinalizedTimestamp { + wg.Add(1) + go func() { + defer wg.Done() + obs.MaxFinalizedTimestamp.Val, obs.MaxFinalizedTimestamp.Err = ds.fetcher.LatestTimestamp(ctx) + }() + } + + wg.Add(1) + go func() { + defer wg.Done() + var trrs pipeline.TaskRunResults + var run pipeline.Run + run, trrs, err = ds.executeRun(ctx) + if err != nil { + cancel() + err = fmt.Errorf("Observe failed while executing run: %w", err) + return + } + select { + case ds.runResults <- run: + default: + ds.lggr.Warnf("unable to enqueue run save for job ID %d, buffer full", ds.spec.JobID) + } + + var parsed parseOutput + parsed, err = ds.parse(trrs) + if err != nil { + cancel() + // This is not expected under normal circumstances + ds.lggr.Errorw("Observe failed while parsing run results", "err", err) + err = fmt.Errorf("Observe failed while parsing run results: %w", err) + return + } + obs.BenchmarkPrice = parsed.benchmarkPrice + obs.Bid = parsed.bid + obs.Ask = parsed.ask + }() + + var isLink, isNative bool + if ds.feedID == ds.linkFeedID { + isLink = true + } else { + wg.Add(1) + go func() { + defer wg.Done() + obs.LinkPrice.Val, obs.LinkPrice.Err = ds.fetcher.LatestPrice(ctx, ds.linkFeedID) + if obs.LinkPrice.Val == nil && obs.LinkPrice.Err == nil { + ds.lggr.Warnw("Mercury server was missing LINK feed, falling back to max int192", "linkFeedID", ds.linkFeedID) + obs.LinkPrice.Val = maxInt192 + } + }() + } + + if ds.feedID == ds.nativeFeedID { + isNative = true + } else { + wg.Add(1) + go func() { + defer wg.Done() + obs.NativePrice.Val, obs.NativePrice.Err = ds.fetcher.LatestPrice(ctx, ds.nativeFeedID) + if obs.NativePrice.Val == nil && obs.NativePrice.Err == nil { + ds.lggr.Warnw("Mercury server was missing native feed, falling back to max int192", "nativeFeedID", ds.nativeFeedID) + obs.NativePrice.Val = maxInt192 + } + }() + } + + wg.Wait() + cancel() + + if isLink || isNative { + // run has now completed so it is safe to use err or benchmark price + if err != nil { + return + } + if isLink { + // This IS the LINK feed, use our observed price + obs.LinkPrice.Val, obs.LinkPrice.Err = obs.BenchmarkPrice.Val, obs.BenchmarkPrice.Err + } + if isNative { + // This IS the native feed, use our observed price + obs.NativePrice.Val, obs.NativePrice.Err = obs.BenchmarkPrice.Val, obs.BenchmarkPrice.Err + } + } + + // todo: implement telemetry https://smartcontract-it.atlassian.net/browse/MERC-1388 + // if ocrcommon.ShouldCollectEnhancedTelemetryMercury(&ds.jb) { + // ocrcommon.EnqueueEnhancedTelem(ds.chEnhancedTelem, ocrcommon.EnhancedTelemetryMercuryData{ + // TaskRunResults: trrs, + // Observation: obs, + // RepTimestamp: repts, + // }) + // } + + cancel() + return obs, err +} + +func toBigInt(val interface{}) (*big.Int, error) { + dec, err := utils.ToDecimal(val) + if err != nil { + return nil, err + } + return dec.BigInt(), nil +} + +type parseOutput struct { + benchmarkPrice relaymercury.ObsResult[*big.Int] + bid relaymercury.ObsResult[*big.Int] + ask relaymercury.ObsResult[*big.Int] +} + +func (ds *datasource) parse(trrs pipeline.TaskRunResults) (o parseOutput, merr error) { + var finaltrrs []pipeline.TaskRunResult + for _, trr := range trrs { + // only return terminal trrs from executeRun + if trr.IsTerminal() { + finaltrrs = append(finaltrrs, trr) + } + } + + // pipeline.TaskRunResults comes ordered asc by index, this is guaranteed + // by the pipeline executor + if len(finaltrrs) != 3 { + return o, fmt.Errorf("invalid number of results, expected: 3, got: %d", len(finaltrrs)) + } + + merr = errors.Join( + setBenchmarkPrice(&o, finaltrrs[0].Result), + setBid(&o, finaltrrs[1].Result), + setAsk(&o, finaltrrs[2].Result), + ) + + return o, merr +} + +func setBenchmarkPrice(o *parseOutput, res pipeline.Result) error { + if res.Error != nil { + o.benchmarkPrice.Err = res.Error + return res.Error + } else if val, err := toBigInt(res.Value); err != nil { + return fmt.Errorf("failed to parse BenchmarkPrice: %w", err) + } else { + o.benchmarkPrice.Val = val + } + return nil +} + +func setBid(o *parseOutput, res pipeline.Result) error { + if res.Error != nil { + o.bid.Err = res.Error + return res.Error + } else if val, err := toBigInt(res.Value); err != nil { + return fmt.Errorf("failed to parse Bid: %w", err) + } else { + o.bid.Val = val + } + return nil +} + +func setAsk(o *parseOutput, res pipeline.Result) error { + if res.Error != nil { + o.ask.Err = res.Error + return res.Error + } else if val, err := toBigInt(res.Value); err != nil { + return fmt.Errorf("failed to parse Ask: %w", err) + } else { + o.ask.Val = val + } + return nil +} + +// The context passed in here has a timeout of (ObservationTimeout + ObservationGracePeriod). +// Upon context cancellation, its expected that we return any usable values within ObservationGracePeriod. +func (ds *datasource) executeRun(ctx context.Context) (pipeline.Run, pipeline.TaskRunResults, error) { + vars := pipeline.NewVarsFrom(map[string]interface{}{ + "jb": map[string]interface{}{ + "databaseID": ds.jb.ID, + "externalJobID": ds.jb.ExternalJobID, + "name": ds.jb.Name.ValueOrZero(), + }, + }) + + run, trrs, err := ds.pipelineRunner.ExecuteRun(ctx, ds.spec, vars, ds.lggr) + if err != nil { + return pipeline.Run{}, nil, pkgerrors.Wrapf(err, "error executing run for spec ID %v", ds.spec.ID) + } + + return run, trrs, err +} diff --git a/core/services/relay/evm/mercury/v3/data_source_test.go b/core/services/relay/evm/mercury/v3/data_source_test.go new file mode 100644 index 00000000000..d6ceba8f841 --- /dev/null +++ b/core/services/relay/evm/mercury/v3/data_source_test.go @@ -0,0 +1,259 @@ +package mercury_v3 + +import ( + "context" + "math/big" + "testing" + + "github.com/pkg/errors" + "github.com/stretchr/testify/assert" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" +) + +var _ relaymercury.MercuryServerFetcher = &mockFetcher{} + +type mockFetcher struct { + ts uint32 + tsErr error + linkPrice *big.Int + linkPriceErr error + nativePrice *big.Int + nativePriceErr error +} + +var feedId types.FeedID = [32]byte{1} +var linkFeedId types.FeedID = [32]byte{2} +var nativeFeedId types.FeedID = [32]byte{3} + +func (m *mockFetcher) FetchInitialMaxFinalizedBlockNumber(context.Context) (*int64, error) { + return nil, nil +} + +func (m *mockFetcher) LatestPrice(ctx context.Context, fId [32]byte) (*big.Int, error) { + if fId == linkFeedId { + return m.linkPrice, m.linkPriceErr + } else if fId == nativeFeedId { + return m.nativePrice, m.nativePriceErr + } + return nil, nil +} + +func (m *mockFetcher) LatestTimestamp(context.Context) (uint32, error) { + return m.ts, m.tsErr +} + +func Test_Datasource(t *testing.T) { + ds := &datasource{lggr: logger.TestLogger(t)} + ctx := testutils.Context(t) + repts := ocrtypes.ReportTimestamp{} + + fetcher := &mockFetcher{} + ds.fetcher = fetcher + + goodTrrs := []pipeline.TaskRunResult{ + { + // bp + Result: pipeline.Result{Value: "122.345"}, + Task: &mercurymocks.MockTask{}, + }, + { + // bid + Result: pipeline.Result{Value: "121.993"}, + Task: &mercurymocks.MockTask{}, + }, + { + // ask + Result: pipeline.Result{Value: "123.111"}, + Task: &mercurymocks.MockTask{}, + }, + } + + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: goodTrrs, + } + + spec := pipeline.Spec{} + ds.spec = spec + + t.Run("when fetchMaxFinalizedTimestamp=true", func(t *testing.T) { + t.Run("if LatestTimestamp returns error", func(t *testing.T) { + fetcher.tsErr = errors.New("some error") + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.EqualError(t, obs.MaxFinalizedTimestamp.Err, "some error") + assert.Zero(t, obs.MaxFinalizedTimestamp.Val) + }) + + t.Run("if LatestTimestamp succeeds", func(t *testing.T) { + fetcher.tsErr = nil + fetcher.ts = 123 + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.Equal(t, uint32(123), obs.MaxFinalizedTimestamp.Val) + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + }) + + t.Run("if LatestTimestamp succeeds but ts=0 (new feed)", func(t *testing.T) { + fetcher.tsErr = nil + fetcher.ts = 0 + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + assert.Zero(t, obs.MaxFinalizedTimestamp.Val) + }) + + t.Run("when run execution succeeded", func(t *testing.T) { + t.Run("when feedId=linkFeedID=nativeFeedId", func(t *testing.T) { + t.Cleanup(func() { + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, linkFeedId, nativeFeedId + }) + + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, feedId, feedId + + fetcher.ts = 123123 + fetcher.tsErr = nil + + obs, err := ds.Observe(ctx, repts, true) + assert.NoError(t, err) + + assert.Equal(t, big.NewInt(122), obs.BenchmarkPrice.Val) + assert.NoError(t, obs.BenchmarkPrice.Err) + assert.Equal(t, big.NewInt(121), obs.Bid.Val) + assert.NoError(t, obs.Bid.Err) + assert.Equal(t, big.NewInt(123), obs.Ask.Val) + assert.NoError(t, obs.Ask.Err) + assert.Equal(t, uint32(123123), obs.MaxFinalizedTimestamp.Val) + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) + assert.NoError(t, obs.LinkPrice.Err) + assert.Equal(t, big.NewInt(122), obs.NativePrice.Val) + assert.NoError(t, obs.NativePrice.Err) + }) + }) + }) + + t.Run("when fetchMaxFinalizedTimestamp=false", func(t *testing.T) { + t.Run("when run execution fails, returns error", func(t *testing.T) { + t.Cleanup(func() { + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: goodTrrs, + Err: nil, + } + }) + + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: goodTrrs, + Err: errors.New("run execution failed"), + } + + _, err := ds.Observe(ctx, repts, false) + assert.EqualError(t, err, "Observe failed while executing run: error executing run for spec ID 0: run execution failed") + }) + + t.Run("when parsing run results fails, return error", func(t *testing.T) { + t.Cleanup(func() { + runner := &mercurymocks.MockRunner{ + Trrs: goodTrrs, + Err: nil, + } + ds.pipelineRunner = runner + }) + + badTrrs := []pipeline.TaskRunResult{ + { + // benchmark price + Result: pipeline.Result{Value: "122.345"}, + Task: &mercurymocks.MockTask{}, + }, + { + // bid + Result: pipeline.Result{Value: "121.993"}, + Task: &mercurymocks.MockTask{}, + }, + { + // ask + Result: pipeline.Result{Error: errors.New("some error with ask")}, + Task: &mercurymocks.MockTask{}, + }, + } + + ds.pipelineRunner = &mercurymocks.MockRunner{ + Trrs: badTrrs, + Err: nil, + } + + _, err := ds.Observe(ctx, repts, false) + assert.EqualError(t, err, "Observe failed while parsing run results: some error with ask") + }) + + t.Run("when run execution succeeded", func(t *testing.T) { + t.Run("when feedId=linkFeedID=nativeFeedId", func(t *testing.T) { + t.Cleanup(func() { + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, linkFeedId, nativeFeedId + }) + + var feedId types.FeedID = [32]byte{1} + ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, feedId, feedId + + obs, err := ds.Observe(ctx, repts, false) + assert.NoError(t, err) + + assert.Equal(t, big.NewInt(122), obs.BenchmarkPrice.Val) + assert.NoError(t, obs.BenchmarkPrice.Err) + assert.Equal(t, big.NewInt(121), obs.Bid.Val) + assert.NoError(t, obs.Bid.Err) + assert.Equal(t, big.NewInt(123), obs.Ask.Val) + assert.NoError(t, obs.Ask.Err) + assert.Equal(t, uint32(0), obs.MaxFinalizedTimestamp.Val) + assert.NoError(t, obs.MaxFinalizedTimestamp.Err) + assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) + assert.NoError(t, obs.LinkPrice.Err) + assert.Equal(t, big.NewInt(122), obs.NativePrice.Val) + assert.NoError(t, obs.NativePrice.Err) + }) + + t.Run("when fails to fetch linkPrice or nativePrice", func(t *testing.T) { + t.Cleanup(func() { + fetcher.linkPriceErr = nil + fetcher.nativePriceErr = nil + }) + + fetcher.linkPriceErr = errors.New("some error fetching link price") + fetcher.nativePriceErr = errors.New("some error fetching native price") + + obs, err := ds.Observe(ctx, repts, false) + assert.NoError(t, err) + + assert.Nil(t, obs.LinkPrice.Val) + assert.EqualError(t, obs.LinkPrice.Err, "some error fetching link price") + assert.Nil(t, obs.NativePrice.Val) + assert.EqualError(t, obs.NativePrice.Err, "some error fetching native price") + }) + + t.Run("when succeeds to fetch linkPrice or nativePrice but got nil (new feed)", func(t *testing.T) { + obs, err := ds.Observe(ctx, repts, false) + assert.NoError(t, err) + + assert.Equal(t, obs.LinkPrice.Val, maxInt192) + assert.Nil(t, obs.LinkPrice.Err) + assert.Equal(t, obs.NativePrice.Val, maxInt192) + assert.Nil(t, obs.NativePrice.Err) + }) + }) + }) +} diff --git a/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go new file mode 100644 index 00000000000..779e6280d0b --- /dev/null +++ b/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go @@ -0,0 +1,139 @@ +package reportcodec + +import ( + "fmt" + "math" + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/pkg/errors" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" +) + +var ReportTypes = getReportTypes() +var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word + +func getReportTypes() abi.Arguments { + mustNewType := func(t string) abi.Type { + result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) + if err != nil { + panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) + } + return result + } + return abi.Arguments([]abi.Argument{ + {Name: "feedId", Type: mustNewType("bytes32")}, + {Name: "validFromTimestamp", Type: mustNewType("uint32")}, + {Name: "observationsTimestamp", Type: mustNewType("uint32")}, + {Name: "nativeFee", Type: mustNewType("int192")}, + {Name: "linkFee", Type: mustNewType("int192")}, + {Name: "expiresAt", Type: mustNewType("uint32")}, + {Name: "benchmarkPrice", Type: mustNewType("int192")}, + {Name: "bid", Type: mustNewType("int192")}, + {Name: "ask", Type: mustNewType("int192")}, + }) +} + +type Report struct { + FeedId [32]byte + ObservationsTimestamp uint32 + BenchmarkPrice *big.Int + Bid *big.Int + Ask *big.Int + ValidFromTimestamp uint32 + ExpiresAt uint32 + LinkFee *big.Int + NativeFee *big.Int +} + +var _ reportcodec.ReportCodec = &ReportCodec{} + +type ReportCodec struct { + logger logger.Logger + feedID types.FeedID +} + +func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { + return &ReportCodec{lggr, feedID} +} + +func (r *ReportCodec) BuildReport(paos []reportcodec.ParsedAttributedObservation, f int, validFromTimestamp, expiresAt uint32) (ocrtypes.Report, error) { + if len(paos) == 0 { + return nil, errors.Errorf("cannot build report from empty attributed observations") + } + + mPaos := reportcodec.Convert(paos) + + timestamp := relaymercury.GetConsensusTimestamp(mPaos) + + benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusBenchmarkPrice failed") + } + bid, err := relaymercury.GetConsensusBid(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusBid failed") + } + ask, err := relaymercury.GetConsensusAsk(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusAsk failed") + } + + linkFee, err := relaymercury.GetConsensusLinkFee(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusLinkFee failed") + } + nativeFee, err := relaymercury.GetConsensusNativeFee(mPaos, f) + if err != nil { + return nil, errors.Wrap(err, "GetConsensusNativeFee failed") + } + + reportBytes, err := ReportTypes.Pack(r.feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, benchmarkPrice, bid, ask) + return ocrtypes.Report(reportBytes), errors.Wrap(err, "failed to pack report blob") +} + +func (r *ReportCodec) MaxReportLength(n int) (int, error) { + return maxReportLength, nil +} + +func (r *ReportCodec) ObservationTimestampFromReport(report ocrtypes.Report) (uint32, error) { + reportElems := map[string]interface{}{} + if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { + return 0, errors.Errorf("error during unpack: %v", err) + } + + timestampIface, ok := reportElems["observationsTimestamp"] + if !ok { + return 0, errors.Errorf("unpacked report has no 'timestamp' field") + } + + timestamp, ok := timestampIface.(uint32) + if !ok { + return 0, errors.Errorf("cannot cast timestamp to uint32, type is %T", timestampIface) + } + + if timestamp > math.MaxInt32 { + return 0, errors.Errorf("timestamp overflows max uint32, got: %d", timestamp) + } + + return timestamp, nil +} + +// Decode is made available to external users (i.e. mercury server) +func (r *ReportCodec) Decode(report ocrtypes.Report) (*Report, error) { + values, err := ReportTypes.Unpack(report) + if err != nil { + return nil, fmt.Errorf("failed to decode report: %w", err) + } + decoded := new(Report) + if err = ReportTypes.Copy(decoded, values); err != nil { + return nil, fmt.Errorf("failed to copy report values to struct: %w", err) + } + return decoded, nil +} diff --git a/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go new file mode 100644 index 00000000000..9a5e3c0f2fe --- /dev/null +++ b/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go @@ -0,0 +1,126 @@ +package reportcodec + +import ( + "math" + "math/big" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/libocr/commontypes" + "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + + relaymercuryv3 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" +) + +var paos = []relaymercuryv3.ParsedAttributedObservation{ + relaymercuryv3.NewParsedAttributedObservation(42, commontypes.OracleID(49), big.NewInt(43), big.NewInt(44), big.NewInt(45), true, 123, true, big.NewInt(143), true, big.NewInt(457), true), + relaymercuryv3.NewParsedAttributedObservation(142, commontypes.OracleID(149), big.NewInt(143), big.NewInt(144), big.NewInt(145), true, 455, true, big.NewInt(456), true, big.NewInt(345), true), + relaymercuryv3.NewParsedAttributedObservation(242, commontypes.OracleID(249), big.NewInt(243), big.NewInt(244), big.NewInt(245), true, 789, true, big.NewInt(764), true, big.NewInt(167), true), + relaymercuryv3.NewParsedAttributedObservation(342, commontypes.OracleID(250), big.NewInt(343), big.NewInt(344), big.NewInt(345), true, 123, true, big.NewInt(378), true, big.NewInt(643), true), +} + +func Test_ReportCodec_BuildReport(t *testing.T) { + r := ReportCodec{} + f := 1 + + t.Run("BuildReport errors if observations are empty", func(t *testing.T) { + ps := []relaymercuryv3.ParsedAttributedObservation{} + _, err := r.BuildReport(ps, f, 123, 10) + require.Error(t, err) + assert.Contains(t, err.Error(), "cannot build report from empty attributed observation") + }) + + t.Run("BuildReport constructs a report from observations", func(t *testing.T) { + // only need to test happy path since validations are done in relaymercury + + report, err := r.BuildReport(paos, f, 123, 20) + require.NoError(t, err) + + reportElems := make(map[string]interface{}) + err = ReportTypes.UnpackIntoMap(reportElems, report) + require.NoError(t, err) + + assert.Equal(t, int(reportElems["observationsTimestamp"].(uint32)), 242) + assert.Equal(t, reportElems["benchmarkPrice"].(*big.Int).Int64(), int64(243)) + assert.Equal(t, reportElems["bid"].(*big.Int).Int64(), int64(244)) + assert.Equal(t, reportElems["ask"].(*big.Int).Int64(), int64(245)) + assert.Equal(t, reportElems["validFromTimestamp"].(uint32), uint32(123)) + assert.Equal(t, reportElems["expiresAt"].(uint32), uint32(20)) + assert.Equal(t, reportElems["linkFee"].(*big.Int).Int64(), int64(456)) + assert.Equal(t, reportElems["nativeFee"].(*big.Int).Int64(), int64(457)) + + assert.Equal(t, types.Report{0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x7b, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf2, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0xc9, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x1, 0xc8, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x14, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf3, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf4, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0xf5}, report) + max, err := r.MaxReportLength(4) + require.NoError(t, err) + assert.LessOrEqual(t, len(report), max) + + t.Run("Decode decodes the report", func(t *testing.T) { + decoded, err := r.Decode(report) + require.NoError(t, err) + + require.NotNil(t, decoded) + + assert.Equal(t, uint32(242), decoded.ObservationsTimestamp) + assert.Equal(t, big.NewInt(243), decoded.BenchmarkPrice) + assert.Equal(t, big.NewInt(244), decoded.Bid) + assert.Equal(t, big.NewInt(245), decoded.Ask) + assert.Equal(t, uint32(123), decoded.ValidFromTimestamp) + assert.Equal(t, uint32(20), decoded.ExpiresAt) + assert.Equal(t, big.NewInt(456), decoded.LinkFee) + assert.Equal(t, big.NewInt(457), decoded.NativeFee) + }) + }) + + t.Run("Decode errors on invalid report", func(t *testing.T) { + _, err := r.Decode([]byte{1, 2, 3}) + assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") + + longBad := make([]byte, 64) + for i := 0; i < len(longBad); i++ { + longBad[i] = byte(i) + } + _, err = r.Decode(longBad) + assert.EqualError(t, err, "failed to decode report: abi: improperly encoded uint32 value") + }) +} + +func buildSampleReport(ts int64) []byte { + feedID := [32]byte{'f', 'o', 'o'} + timestamp := uint32(ts) + bp := big.NewInt(242) + bid := big.NewInt(243) + ask := big.NewInt(244) + validFromTimestamp := uint32(123) + expiresAt := uint32(456) + linkFee := big.NewInt(3334455) + nativeFee := big.NewInt(556677) + + b, err := ReportTypes.Pack(feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, bp, bid, ask) + if err != nil { + panic(err) + } + return b +} + +func Test_ReportCodec_ObservationTimestampFromReport(t *testing.T) { + r := ReportCodec{} + + t.Run("ObservationTimestampFromReport extracts observation timestamp from a valid report", func(t *testing.T) { + report := buildSampleReport(123) + + ts, err := r.ObservationTimestampFromReport(report) + require.NoError(t, err) + + assert.Equal(t, ts, uint32(123)) + }) + t.Run("ObservationTimestampFromReport returns error when timestamp is too big", func(t *testing.T) { + report := buildSampleReport(math.MaxInt32 + 1) + + _, err := r.ObservationTimestampFromReport(report) + require.Error(t, err) + + assert.EqualError(t, err, "timestamp overflows max uint32, got: 2147483648") + }) +} diff --git a/core/services/relay/evm/mercury_provider.go b/core/services/relay/evm/mercury_provider.go index 9f604234016..ee32b8d99be 100644 --- a/core/services/relay/evm/mercury_provider.go +++ b/core/services/relay/evm/mercury_provider.go @@ -5,6 +5,9 @@ import ( "errors" relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" + relaymercuryv2 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" + relaymercuryv3 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "golang.org/x/exp/maps" @@ -19,7 +22,9 @@ var _ relaytypes.MercuryProvider = (*mercuryProvider)(nil) type mercuryProvider struct { configWatcher *configWatcher transmitter mercury.Transmitter - reportCodec relaymercury.ReportCodec + reportCodecV1 relaymercuryv1.ReportCodec + reportCodecV2 relaymercuryv2.ReportCodec + reportCodecV3 relaymercuryv3.ReportCodec logger logger.Logger ms services.MultiStart @@ -28,13 +33,17 @@ type mercuryProvider struct { func NewMercuryProvider( configWatcher *configWatcher, transmitter mercury.Transmitter, - reportCodec relaymercury.ReportCodec, + reportCodecV1 relaymercuryv1.ReportCodec, + reportCodecV2 relaymercuryv2.ReportCodec, + reportCodecV3 relaymercuryv3.ReportCodec, lggr logger.Logger, ) *mercuryProvider { return &mercuryProvider{ configWatcher, transmitter, - reportCodec, + reportCodecV1, + reportCodecV2, + reportCodecV3, lggr, services.MultiStart{}, } @@ -75,8 +84,16 @@ func (p *mercuryProvider) OnchainConfigCodec() relaymercury.OnchainConfigCodec { return relaymercury.StandardOnchainConfigCodec{} } -func (p *mercuryProvider) ReportCodec() relaymercury.ReportCodec { - return p.reportCodec +func (p *mercuryProvider) ReportCodecV1() relaymercuryv1.ReportCodec { + return p.reportCodecV1 +} + +func (p *mercuryProvider) ReportCodecV2() relaymercuryv2.ReportCodec { + return p.reportCodecV2 +} + +func (p *mercuryProvider) ReportCodecV3() relaymercuryv3.ReportCodec { + return p.reportCodecV3 } func (p *mercuryProvider) ContractTransmitter() relaymercury.Transmitter { diff --git a/core/utils/hash.go b/core/utils/hash.go new file mode 100644 index 00000000000..bcae823770e --- /dev/null +++ b/core/utils/hash.go @@ -0,0 +1,40 @@ +package utils + +import ( + "encoding/hex" + "fmt" + "strings" + + "github.com/pkg/errors" +) + +// Hash is a simplified version of go-ethereum's common.Hash to avoid +// go-ethereum dependency +// It represents a 32 byte fixed size array that marshals/unmarshals assuming a +// 0x prefix +type Hash [32]byte + +// Hex converts a hash to a hex string. +func (h Hash) Hex() string { return fmt.Sprintf("0x%s", hex.EncodeToString(h[:])) } + +// String implements the stringer interface and is used also by the logger when +// doing full logging into a file. +func (h Hash) String() string { + return h.Hex() +} + +// UnmarshalText parses a hash in hex syntax. +func (h *Hash) UnmarshalText(input []byte) error { + if !strings.HasPrefix(string(input), "0x") { + return errors.New("hash: expected a hex string starting with '0x'") + } + phex := new(PlainHexBytes) + if err := phex.UnmarshalText(input[2:]); err != nil { + return fmt.Errorf("hash: %w", err) + } + if len(*phex) != 32 { + return fmt.Errorf("hash: expected 32-byte sequence, got %d bytes", len(*phex)) + } + copy((*h)[:], (*phex)) + return nil +} diff --git a/core/utils/hash_test.go b/core/utils/hash_test.go new file mode 100644 index 00000000000..07ab11f96d1 --- /dev/null +++ b/core/utils/hash_test.go @@ -0,0 +1,65 @@ +package utils + +import ( + "encoding/json" + "strings" + "testing" +) + +func Test_Hash_UnmarshalText(t *testing.T) { + var tests = []struct { + Prefix string + Size int + Error string + }{ + {"", 62, "hash: expected a hex string starting with '0x'"}, + {"0x", 66, "hash: expected 32-byte sequence, got 33 bytes"}, + {"0x", 63, "hash: UnmarshalText failed: odd length"}, + {"0x", 0, "hash: expected 32-byte sequence, got 0 bytes"}, + {"0x", 64, ""}, + {"0X", 64, "hash: expected a hex string starting with '0x'"}, + } + for _, test := range tests { + input := test.Prefix + strings.Repeat("0", test.Size) + v := new(Hash) + err := v.UnmarshalText([]byte(input)) + if err == nil { + if test.Error != "" { + t.Errorf("%s: error mismatch: have nil, want %q", input, test.Error) + } + } else { + if err.Error() != test.Error { + t.Errorf("%s: error mismatch: have %q, want %q", input, err, test.Error) + } + } + } +} + +func Test_Hash_UnmarshalJSON(t *testing.T) { + var tests = []struct { + Prefix string + Size int + Error string + }{ + {"", 62, "hash: expected a hex string starting with '0x'"}, + {"0x", 66, "hash: expected 32-byte sequence, got 33 bytes"}, + {"0x", 63, "hash: UnmarshalText failed: odd length"}, + {"0x", 0, "hash: expected 32-byte sequence, got 0 bytes"}, + {"0x", 64, ""}, + {"0X", 64, "hash: expected a hex string starting with '0x'"}, + } + for _, test := range tests { + input := `"` + test.Prefix + strings.Repeat("0", test.Size) + `"` + var v Hash + err := json.Unmarshal([]byte(input), &v) + if err == nil { + if test.Error != "" { + t.Errorf("%s: error mismatch: have nil, want %q", input, test.Error) + } + } else { + if err.Error() != test.Error { + t.Errorf("%s: error mismatch: have %q, want %q", input, err, test.Error) + } + } + } +} diff --git a/go.mod b/go.mod index ca2ba97ff99..a95e4d1d03f 100644 --- a/go.mod +++ b/go.mod @@ -66,7 +66,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 diff --git a/go.sum b/go.sum index 9ef41e1e2c8..8416db79d14 100644 --- a/go.sum +++ b/go.sum @@ -1435,8 +1435,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a h1:8lHQYdub7q3LgD5ebQOA+usDyUqqiHvKEJPGQ8+FxMA= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a/go.mod h1:Nt4mQh6z6q26jrM4FyQLq/2vBp1Sg3l5md3tBRdRLxg= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index df0f1939569..91f93f3289d 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -382,7 +382,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index e7af499b5b8..9bbdef73f12 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2241,8 +2241,8 @@ github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb2 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a h1:8lHQYdub7q3LgD5ebQOA+usDyUqqiHvKEJPGQ8+FxMA= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230808141159-4e20b0757f3a/go.mod h1:Nt4mQh6z6q26jrM4FyQLq/2vBp1Sg3l5md3tBRdRLxg= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= From d73a4708eb9ebbef12474e109aba4d20340519e3 Mon Sep 17 00:00:00 2001 From: Aaron Lu <50029043+aalu1418@users.noreply.github.com> Date: Wed, 16 Aug 2023 12:46:14 -0600 Subject: [PATCH 192/270] add evm transfer validation for eip1559 (#10196) * add transfer validation for eip1559 * evm-transfer-eip1559-validation-proposal - adding TxAmountWithFees to WrappedEvmEstimator * small renaming + fix mocks * fix dynamic fee + remove unnecessary check * rename GetCost -> GetMaxCost * address cleanup items + add test case for GetMaxCost --------- Co-authored-by: patrickhuie19 --- .../chains/evm/gas/mocks/evm_fee_estimator.go | 37 ++++++++++++++- core/chains/evm/gas/models.go | 21 +++++++++ core/chains/evm/gas/models_test.go | 27 +++++++++-- core/web/evm_transfer_controller.go | 18 +------- core/web/evm_transfer_controller_test.go | 45 +++++++++++++++++++ 5 files changed, 128 insertions(+), 20 deletions(-) diff --git a/core/chains/evm/gas/mocks/evm_fee_estimator.go b/core/chains/evm/gas/mocks/evm_fee_estimator.go index 67eed66a529..20e6c940f7e 100644 --- a/core/chains/evm/gas/mocks/evm_fee_estimator.go +++ b/core/chains/evm/gas/mocks/evm_fee_estimator.go @@ -3,10 +3,12 @@ package mocks import ( - context "context" + big "math/big" assets "github.com/smartcontractkit/chainlink/v2/core/assets" + context "context" + evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" gas "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" @@ -104,6 +106,39 @@ func (_m *EvmFeeEstimator) GetFee(ctx context.Context, calldata []byte, feeLimit return r0, r1, r2 } +// GetMaxCost provides a mock function with given fields: ctx, amount, calldata, feeLimit, maxFeePrice, opts +func (_m *EvmFeeEstimator) GetMaxCost(ctx context.Context, amount assets.Eth, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...types.Opt) (*big.Int, error) { + _va := make([]interface{}, len(opts)) + for _i := range opts { + _va[_i] = opts[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, amount, calldata, feeLimit, maxFeePrice) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 *big.Int + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, assets.Eth, []byte, uint32, *assets.Wei, ...types.Opt) (*big.Int, error)); ok { + return rf(ctx, amount, calldata, feeLimit, maxFeePrice, opts...) + } + if rf, ok := ret.Get(0).(func(context.Context, assets.Eth, []byte, uint32, *assets.Wei, ...types.Opt) *big.Int); ok { + r0 = rf(ctx, amount, calldata, feeLimit, maxFeePrice, opts...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(*big.Int) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, assets.Eth, []byte, uint32, *assets.Wei, ...types.Opt) error); ok { + r1 = rf(ctx, amount, calldata, feeLimit, maxFeePrice, opts...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + // HealthReport provides a mock function with given fields: func (_m *EvmFeeEstimator) HealthReport() map[string]error { ret := _m.Called() diff --git a/core/chains/evm/gas/models.go b/core/chains/evm/gas/models.go index 5e9378812c1..8b6580685b5 100644 --- a/core/chains/evm/gas/models.go +++ b/core/chains/evm/gas/models.go @@ -32,6 +32,9 @@ type EvmFeeEstimator interface { GetFee(ctx context.Context, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...feetypes.Opt) (fee EvmFee, chainSpecificFeeLimit uint32, err error) BumpFee(ctx context.Context, originalFee EvmFee, feeLimit uint32, maxFeePrice *assets.Wei, attempts []EvmPriorAttempt) (bumpedFee EvmFee, chainSpecificFeeLimit uint32, err error) + + // GetMaxCost returns the total value = max price x fee units + transferred value + GetMaxCost(ctx context.Context, amount assets.Eth, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...feetypes.Opt) (*big.Int, error) } // NewEstimator returns the estimator for a given config @@ -164,6 +167,24 @@ func (e WrappedEvmEstimator) GetFee(ctx context.Context, calldata []byte, feeLim return } +func (e WrappedEvmEstimator) GetMaxCost(ctx context.Context, amount assets.Eth, calldata []byte, feeLimit uint32, maxFeePrice *assets.Wei, opts ...feetypes.Opt) (*big.Int, error) { + fees, gasLimit, err := e.GetFee(ctx, calldata, feeLimit, maxFeePrice, opts...) + if err != nil { + return nil, err + } + + var gasPrice *assets.Wei + if e.EIP1559Enabled { + gasPrice = fees.DynamicFeeCap + } else { + gasPrice = fees.Legacy + } + + fee := new(big.Int).Mul(gasPrice.ToInt(), big.NewInt(int64(gasLimit))) + amountWithFees := new(big.Int).Add(amount.ToInt(), fee) + return amountWithFees, nil +} + func (e WrappedEvmEstimator) BumpFee(ctx context.Context, originalFee EvmFee, feeLimit uint32, maxFeePrice *assets.Wei, attempts []EvmPriorAttempt) (bumpedFee EvmFee, chainSpecificFeeLimit uint32, err error) { // validate only 1 fee type is present if (!originalFee.ValidDynamic() && originalFee.Legacy == nil) || (originalFee.ValidDynamic() && originalFee.Legacy != nil) { diff --git a/core/chains/evm/gas/models_test.go b/core/chains/evm/gas/models_test.go index 3e793d27348..048646a980c 100644 --- a/core/chains/evm/gas/models_test.go +++ b/core/chains/evm/gas/models_test.go @@ -2,6 +2,7 @@ package gas_test import ( "context" + "math/big" "testing" "github.com/stretchr/testify/assert" @@ -22,14 +23,14 @@ func TestWrappedEvmEstimator(t *testing.T) { legacyFee := assets.NewWeiI(10) dynamicFee := gas.DynamicFee{ FeeCap: assets.NewWeiI(20), - TipCap: assets.NewWeiI(21), + TipCap: assets.NewWeiI(1), } e := mocks.NewEvmEstimator(t) e.On("GetDynamicFee", mock.Anything, mock.Anything, mock.Anything). - Return(dynamicFee, gasLimit, nil).Once() + Return(dynamicFee, gasLimit, nil).Twice() e.On("GetLegacyGas", mock.Anything, mock.Anything, mock.Anything, mock.Anything). - Return(legacyFee, gasLimit, nil).Once() + Return(legacyFee, gasLimit, nil).Twice() e.On("BumpDynamicFee", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything). Return(dynamicFee, gasLimit, nil).Once() e.On("BumpLegacyGas", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything). @@ -92,4 +93,24 @@ func TestWrappedEvmEstimator(t *testing.T) { }, 0, nil, nil) assert.Error(t, err) }) + + t.Run("GetMaxCost", func(t *testing.T) { + val := assets.NewEthValue(1) + + // expect legacy fee data + dynamicFees := false + estimator := gas.NewWrappedEvmEstimator(e, dynamicFees) + total, err := estimator.GetMaxCost(ctx, val, nil, gasLimit, nil) + require.NoError(t, err) + fee := new(big.Int).Mul(legacyFee.ToInt(), big.NewInt(int64(gasLimit))) + assert.Equal(t, new(big.Int).Add(val.ToInt(), fee), total) + + // expect dynamic fee data + dynamicFees = true + estimator = gas.NewWrappedEvmEstimator(e, dynamicFees) + total, err = estimator.GetMaxCost(ctx, val, nil, gasLimit, nil) + require.NoError(t, err) + fee = new(big.Int).Mul(dynamicFee.FeeCap.ToInt(), big.NewInt(int64(gasLimit))) + assert.Equal(t, new(big.Int).Add(val.ToInt(), fee), total) + }) } diff --git a/core/web/evm_transfer_controller.go b/core/web/evm_transfer_controller.go index 7e7df04160c..e5ceded58d4 100644 --- a/core/web/evm_transfer_controller.go +++ b/core/web/evm_transfer_controller.go @@ -9,7 +9,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/store/models" @@ -94,26 +93,13 @@ func ValidateEthBalanceForTransfer(c *gin.Context, chain evm.Chain, fromAddr com return errors.Errorf("balance is too low for this transaction to be executed: %v", balance) } - var fees gas.EvmFee - gasLimit := chain.Config().EVM().GasEstimator().LimitTransfer() estimator := chain.GasEstimator() - fees, gasLimit, err = estimator.GetFee(c, nil, gasLimit, chain.Config().EVM().GasEstimator().PriceMaxKey(fromAddr)) + amountWithFees, err := estimator.GetMaxCost(c, amount, nil, gasLimit, chain.Config().EVM().GasEstimator().PriceMaxKey(fromAddr)) if err != nil { - return errors.Wrap(err, "failed to estimate gas") - } - - // TODO: support EIP-1559 transactions - if fees.Legacy == nil { - return errors.New("estimator did not return legacy tx fee estimates") + return err } - gasPrice := fees.Legacy - - // Creating a `Big` struct to avoid having a mutation on `tr.Amount` and hence affecting the value stored in the DB - amountAsBig := utils.NewBig(amount.ToInt()) - fee := new(big.Int).Mul(gasPrice.ToInt(), big.NewInt(int64(gasLimit))) - amountWithFees := new(big.Int).Add(amountAsBig.ToInt(), fee) if balance.Cmp(amountWithFees) < 0 { // ETH balance is less than the sent amount + fees return errors.Errorf("balance is too low for this transaction to be executed: %v", balance) diff --git a/core/web/evm_transfer_controller_test.go b/core/web/evm_transfer_controller_test.go index ce4e8c5172f..c58b810e67c 100644 --- a/core/web/evm_transfer_controller_test.go +++ b/core/web/evm_transfer_controller_test.go @@ -252,3 +252,48 @@ func TestTransfersController_JSONBindingError(t *testing.T) { cltest.AssertServerResponse(t, resp, http.StatusBadRequest) } + +func TestTransfersController_CreateSuccess_eip1559(t *testing.T) { + t.Parallel() + + key := cltest.MustGenerateRandomKey(t) + + ethClient := cltest.NewEthMocksWithTransactionsOnBlocksAssertions(t) + + balance, err := assets.NewEthValueS("200") + require.NoError(t, err) + + ethClient.On("PendingNonceAt", mock.Anything, key.Address).Return(uint64(1), nil) + ethClient.On("BalanceAt", mock.Anything, key.Address, (*big.Int)(nil)).Return(balance.ToInt(), nil) + + config := configtest2.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + c.EVM[0].GasEstimator.EIP1559DynamicFees = ptr(true) + c.EVM[0].GasEstimator.Mode = ptr("FixedPrice") + }) + + app := cltest.NewApplicationWithConfigAndKey(t, config, ethClient, key) + require.NoError(t, app.Start(testutils.Context(t))) + + client := app.NewHTTPClient(cltest.APIEmailAdmin) + + amount, err := assets.NewEthValueS("100") + require.NoError(t, err) + + request := models.SendEtherRequest{ + DestinationAddress: common.HexToAddress("0xFA01FA015C8A5332987319823728982379128371"), + FromAddress: key.Address, + Amount: amount, + } + + body, err := json.Marshal(&request) + assert.NoError(t, err) + + resp, cleanup := client.Post("/v2/transfers", bytes.NewBuffer(body)) + t.Cleanup(cleanup) + + errors := cltest.ParseJSONAPIErrors(t, resp.Body) + assert.Equal(t, http.StatusOK, resp.StatusCode) + assert.Len(t, errors.Errors, 0) + + cltest.AssertCount(t, app.GetSqlxDB(), "eth_txes", 1) +} From 35683cf75ceda635b74cc5efd3925cbd123f5d01 Mon Sep 17 00:00:00 2001 From: Tate Date: Wed, 16 Aug 2023 13:54:13 -0600 Subject: [PATCH 193/270] THe final check logic was reversed (#10228) --- .github/workflows/integration-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index e099b9216dc..943ddff4b76 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -448,7 +448,7 @@ jobs: needs: [eth-smoke-tests-matrix,eth-smoke-tests-matrix-docker] steps: - name: Check smoke test matrix status - if: needs.eth-smoke-tests-matrix.result != 'success' && needs.eth-smoke-tests-matrix-docker.result != 'success' + if: needs.eth-smoke-tests-matrix.result != 'success' || needs.eth-smoke-tests-matrix-docker.result != 'success' run: exit 1 - name: Collect Metrics if: always() From fed9c0a847734bdef1036d42eb2e8f80fb5c0cbf Mon Sep 17 00:00:00 2001 From: Oliver Townsend <133903322+ogtownsend@users.noreply.github.com> Date: Wed, 16 Aug 2023 13:07:07 -0700 Subject: [PATCH 194/270] Adding examples to env.example (#10230) --- core/scripts/chaincli/.env.example | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/core/scripts/chaincli/.env.example b/core/scripts/chaincli/.env.example index d6356ae18dc..0003df7d280 100644 --- a/core/scripts/chaincli/.env.example +++ b/core/scripts/chaincli/.env.example @@ -46,3 +46,10 @@ UPKEEP_GAS_LIMIT=5000000 UPKEEP_MERCURY=true UPKEEP_ADD_FUNDS_AMOUNT=10000000000000000000 # 10 LINK +# UPKEEP_TYPE is used to select if we should deploy a conditional, log trigger, mercury, etc upkeep. +# See chainlink/core/scripts/chaincli/config/config.go. Example usage: +# UPKEEP_TYPE=0 # for conditional +# UPKEEP_TYPE=1 # for mercury +# UPKEEP_TYPE=2 # for log trigger +# UPKEEP_TYPE=3 # for log triggered feed lookup + From bfeb9ee1aa070a6db359b08201cf0b432a1709d3 Mon Sep 17 00:00:00 2001 From: Aaron Lu <50029043+aalu1418@users.noreply.github.com> Date: Wed, 16 Aug 2023 15:57:10 -0600 Subject: [PATCH 195/270] add changelog for fix in #10196 (#10235) * add changelog for fix in #10196 * specify which flag for overriding in changelog --- docs/CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index a34a7ae34cd..1bcbbe51b5e 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -15,6 +15,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## 2.4.0 - UNRELEASED ### Fixed - Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. +- Fixed withdrawing ETH from CL node for EIP1559 enabled chains. Previously would error out unless validation was overridden with `allowHigherAmounts`. ### Added - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. From aaa0736e30dda10f60f63873e6f8cfe3d8820c57 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Thu, 17 Aug 2023 07:38:08 +0300 Subject: [PATCH 196/270] fix healthcheck, always pull stable Geth (#10226) * check another log message of Geth * always pull --- integration-tests/docker/test_env/geth.go | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index 5831bf92053..8980a18c631 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -154,12 +154,13 @@ func (g *Geth) getGethContainerRequest(networks []string) (*tc.ContainerRequest, } return &tc.ContainerRequest{ - Name: g.ContainerName, - Image: "ethereum/client-go:stable", - ExposedPorts: []string{"8544/tcp", "8545/tcp"}, - Networks: networks, - WaitingFor: tcwait.ForListeningPort("8545/tcp"). - WithStartupTimeout(60 * time.Second). + Name: g.ContainerName, + AlwaysPullImage: true, + Image: "ethereum/client-go:stable", + ExposedPorts: []string{"8544/tcp", "8545/tcp"}, + Networks: networks, + WaitingFor: tcwait.ForLog("Chain head was updated"). + WithStartupTimeout(120 * time.Second). WithPollInterval(1 * time.Second), Entrypoint: []string{"sh", "./root/init.sh", "--dev", From db450ecec523bcbba9dc503c5b4befbac675f6ac Mon Sep 17 00:00:00 2001 From: Tate Date: Wed, 16 Aug 2023 23:51:19 -0600 Subject: [PATCH 197/270] [TT-519] Cache Fixes To Reduce Total Cache Of Repo (#10232) reverts changes to unit test caching --- .github/actions/setup-go/action.yml | 7 ++-- .github/workflows/ci-core.yml | 2 -- .github/workflows/integration-tests.yml | 47 +++++++++++++++++++------ 3 files changed, 39 insertions(+), 17 deletions(-) diff --git a/.github/actions/setup-go/action.yml b/.github/actions/setup-go/action.yml index 575df306058..996fb4ac507 100644 --- a/.github/actions/setup-go/action.yml +++ b/.github/actions/setup-go/action.yml @@ -4,9 +4,6 @@ inputs: only-modules: description: Set to 'true' to only cache modules default: 'false' - matrix-id: - description: Job caches can have key collisions when used in a matrix so we need to pass a unique id in for these cases - default: "1" cache-version: description: Set this to cache bust default: "1" @@ -39,9 +36,9 @@ runs: ${{ steps.go-cache-dir.outputs.gomodcache }} # The lifetime of go modules is much higher than the build outputs, so we increase cache efficiency # here by not having the primary key contain the branch name - key: ${{ runner.os }}-gomod-${{ inputs.matrix-id }}-${{ inputs.cache-version }}-${{ hashFiles('./go.sum') }} + key: ${{ runner.os }}-gomod-${{ inputs.cache-version }}-${{ hashFiles('./go.sum') }} restore-keys: | - ${{ runner.os }}-gomod-${{ inputs.matrix-id }}-${{ inputs.cache-version }}- + ${{ runner.os }}-gomod-${{ inputs.cache-version }}- - uses: actions/cache@v3 if: ${{ inputs.only-modules == 'false' }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 6d243a62322..b55b69e293c 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -153,8 +153,6 @@ jobs: prod: "true" - name: Setup Go uses: ./.github/actions/setup-go - with: - matrix-id: ${{ matrix.cmd }}-${{ matrix.split.id }} - name: Setup Solana uses: ./.github/actions/setup-solana - name: Setup wasmd diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 943ddff4b76..afda0d393b0 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -174,7 +174,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.8 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -190,7 +190,8 @@ jobs: publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod - matrix_id: ${{ matrix.product.name }} + cache_key_id: core-e2e + cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -198,11 +199,12 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.8 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.9 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod - matrix_id: ${{ matrix.product.name }} + cache_key_id: core-e2e + cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -390,7 +392,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.8 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 env: PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} @@ -405,18 +407,20 @@ jobs: publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod - matrix_id: ${{ matrix.product.name }} + cache_key_id: core-e2e + cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.8 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.9 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod - matrix_id: ${{ matrix.product.name }} + cache_key_id: core-e2e + cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -459,6 +463,26 @@ jobs: hostname: ${{ secrets.GRAFANA_CLOUD_HOST }} this-job-name: ETH Smoke Tests continue-on-error: true + + # Run the setup if the matrix finishes but this time save the cache if we have a cache hit miss + # this will also only run if both of the matrix jobs pass + eth-smoke-go-mod-cache: + environment: integration + needs: [eth-smoke-tests] + runs-on: ubuntu-latest + name: ETH Smoke Tests Go Mod Cache + steps: + - name: Checkout the repo + uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 + with: + ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} + - name: Run Setup + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@v2.2.9 + with: + test_download_vendor_packages_command: cd ./integration-tests && go mod download + go_mod_path: ./integration-tests/go.mod + cache_key_id: core-e2e + cache_restore_only: 'false' ### Migration tests node-migration-tests: @@ -734,7 +758,7 @@ jobs: ref: ${{ needs.get_solana_sha.outputs.sha }} - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 with: test_command_to_run: export ENV_JOB_IMAGE=${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/chainlink-solana-tests:${{ needs.get_solana_sha.outputs.sha }} && make test_smoke cl_repo: ${{ env.CHAINLINK_IMAGE }} @@ -742,6 +766,7 @@ jobs: artifacts_location: /home/runner/work/chainlink-solana/chainlink-solana/integration-tests/logs publish_check_name: Solana Smoke Test Results go_mod_path: ./integration-tests/go.mod + cache_key_id: core-e2e token: ${{ secrets.GITHUB_TOKEN }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -796,7 +821,7 @@ jobs: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} ## Only run OCR smoke test for now - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 env: PYROSCOPE_SERVER: ${{ secrets.QA_PYROSCOPE_INSTANCE }} PYROSCOPE_ENVIRONMENT: ci-smoke-ocr-evm-${{ matrix.testnet }} # TODO: Only for OCR for now @@ -811,6 +836,8 @@ jobs: publish_check_name: ${{ matrix.testnet }} OCR Smoke Test Results token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod + cache_key_id: core-e2e + cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} From b10ea1841e4827b2220c8da5fe5828eeb5ce6fee Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Thu, 17 Aug 2023 06:52:13 -0400 Subject: [PATCH 198/270] update feed lookup to work with mercury 0.3 spec (#10229) * simplify block subscriber to only use broadcaster * add automation custom telem to job * not expose constants * addressed comments * update channel size * address comments * verify check block and log block (#10154) * verify check block and log block * fix lint issue * add some tests * add more tests * update comments * refactor * fix lint issue * make check pipeline robust * more refactoring * fix lint issues * fix tests * make simulating perform upkeeps robust * make feed lookup robust * make mercury request robust * fix tests * use select * add check upkeeps tests * add simulate perform tests * update mercury 0.3 requests * fix tests * small fixes * rename feedId to feedID --- .../ocr2/plugins/ocr2keeper/evm21/abi.go | 20 +- .../plugins/ocr2keeper/evm21/feed_lookup.go | 215 ++++++++++-------- .../ocr2keeper/evm21/feed_lookup_test.go | 187 ++++++++------- 3 files changed, 238 insertions(+), 184 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go index 50e80f5a482..83eb9998a8a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go @@ -36,16 +36,16 @@ const ( UpkeepFailureReasonTxHashNoLongerExists UpkeepFailureReason = 33 // pipeline execution error - NoPipelineError PipelineExecutionState = 0 - CheckBlockTooOld PipelineExecutionState = 1 - CheckBlockInvalid PipelineExecutionState = 2 - RpcFlakyFailure PipelineExecutionState = 3 - MercuryFlakyFailure PipelineExecutionState = 4 - PackUnpackDecodeFailed PipelineExecutionState = 5 - MercuryUnmarshalError PipelineExecutionState = 6 - InvalidMercuryRequest PipelineExecutionState = 7 - FailedToReadMercuryResponse PipelineExecutionState = 8 - InvalidRevertDataInput PipelineExecutionState = 9 + NoPipelineError PipelineExecutionState = 0 + CheckBlockTooOld PipelineExecutionState = 1 + CheckBlockInvalid PipelineExecutionState = 2 + RpcFlakyFailure PipelineExecutionState = 3 + MercuryFlakyFailure PipelineExecutionState = 4 + PackUnpackDecodeFailed PipelineExecutionState = 5 + MercuryUnmarshalError PipelineExecutionState = 6 + InvalidMercuryRequest PipelineExecutionState = 7 + FailedToDecodeMercuryResponse PipelineExecutionState = 8 + InvalidRevertDataInput PipelineExecutionState = 9 ) var utilsABI = types.MustGetABI(automation_utils_2_1.AutomationUtilsABI) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 2bba9b9106e..46d041db534 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -23,21 +23,25 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" "github.com/patrickmn/go-cache" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/logger" ) const ( - BlockNumber = "blockNumber" // valid for v0.2 - FeedId = "feedId" // valid for v0.3 - FeedIdHex = "feedIdHex" // valid for v0.2 - MercuryPathV2 = "/client?" - MercuryPathV3 = "/v1/reports?" - MercuryBatchPathV3 = "/v1/reports/bulk?" - RetryDelay = 500 * time.Millisecond - Timestamp = "timestamp" // valid for v0.3 - TotalAttempt = 3 - UserId = "userId" - MercuryV02 = MercuryVersion("v0.2") - MercuryV03 = MercuryVersion("v0.3") + applicationJson = "application/json" + blockNumber = "blockNumber" // valid for v0.2 + feedIDs = "feedIDs" // valid for v0.3 + feedIdHex = "feedIdHex" // valid for v0.2 + headerAuthorization = "Authorization" + headerContentType = "Content-Type" + headerTimestamp = "X-Authorization-Timestamp" + headerSignature = "X-Authorization-Signature-SHA256" + headerUpkeepId = "X-Authorization-Upkeep-Id" + mercuryPathV02 = "/client?" // only used to access mercury v0.2 server + mercuryBatchPathV03 = "/v1/reports/bulk?" // only used to access mercury v0.3 server + retryDelay = 500 * time.Millisecond + timestamp = "timestamp" // valid for v0.3 + totalAttempt = 3 ) type MercuryVersion string @@ -52,17 +56,24 @@ type FeedLookup struct { block uint64 } -// MercuryResponse is used in both single feed endpoint and bulk endpoint because bulk endpoint will return ONE -// chainlinkBlob which contains multiple reports instead of multiple blobs. -type MercuryResponse struct { +// MercuryV02Response represents a JSON structure used by Mercury v0.2 +type MercuryV02Response struct { ChainlinkBlob string `json:"chainlinkBlob"` } +// MercuryV03Response represents a JSON structure used by Mercury v0.3 +type MercuryV03Response struct { + FeedID string `json:"feedID"` + ValidFromTimestamp string `json:"validFromTimestamp"` + ObservationsTimestamp string `json:"observationsTimestamp"` + FullReport string `json:"fullReport"` +} + type MercuryData struct { Index int Error error Retryable bool - Bytes []byte + Bytes [][]byte State PipelineExecutionState } @@ -74,6 +85,7 @@ type AdminOffchainConfig struct { // feedLookup looks through check upkeep results looking for any that need off chain lookup func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers.CheckResult) []ocr2keepers.CheckResult { + lggr := r.lggr.With("where", "FeedLookup") lookups := map[int]*FeedLookup{} for i, res := range checkResults { if res.IneligibilityReason != uint8(UpkeepFailureReasonTargetCheckReverted) { @@ -87,23 +99,23 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers state, retryable, allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) if err != nil { - r.lggr.Warnf("[FeedLookup] upkeep %s block %d failed to query mercury allow list: %s", upkeepId, block, err) + lggr.Warnf("upkeep %s block %d failed to query mercury allow list: %s", upkeepId, block, err) checkResults[i].PipelineExecutionState = uint8(state) checkResults[i].Retryable = retryable continue } if !allowed { - r.lggr.Warnf("[FeedLookup] upkeep %s block %d NOT allowed to query Mercury server", upkeepId, block) + lggr.Warnf("upkeep %s block %d NOT allowed to query Mercury server", upkeepId, block) checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryAccessNotAllowed) checkResults[i].Retryable = retryable continue } - r.lggr.Infof("[FeedLookup] upkeep %s block %d decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(checkResults[i].PerformData)) + lggr.Infof("upkeep %s block %d decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(checkResults[i].PerformData)) state, lookup, err := r.decodeFeedLookup(res.PerformData) if err != nil { - r.lggr.Warnf("[FeedLookup] upkeep %s block %d decodeFeedLookup: %v", upkeepId, block, err) + lggr.Warnf("upkeep %s block %d decodeFeedLookup: %v", upkeepId, block, err) checkResults[i].PipelineExecutionState = uint8(state) continue } @@ -111,14 +123,14 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers // the block here is exclusively used to call checkCallback at this block, not to be confused with the block number // in the revert for mercury v0.2, which is denoted by time in the struct bc starting from v0.3, only timestamp will be supported lookup.block = uint64(block.Int64()) - r.lggr.Infof("[FeedLookup] upkeep %s block %d decodeFeedLookup feedKey=%s timeKey=%s feeds=%v time=%s extraData=%s", upkeepId, block, lookup.feedParamKey, lookup.timeParamKey, lookup.feeds, lookup.time, hexutil.Encode(lookup.extraData)) + lggr.Infof("upkeep %s block %d decodeFeedLookup feedKey=%s timeKey=%s feeds=%v time=%s extraData=%s", upkeepId, block, lookup.feedParamKey, lookup.timeParamKey, lookup.feeds, lookup.time, hexutil.Encode(lookup.extraData)) lookups[i] = lookup } var wg sync.WaitGroup for i, lookup := range lookups { wg.Add(1) - go r.doLookup(ctx, &wg, lookup, i, checkResults) + go r.doLookup(ctx, &wg, lookup, i, checkResults, lggr) } wg.Wait() @@ -126,52 +138,52 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers return checkResults } -func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup *FeedLookup, i int, checkResults []ocr2keepers.CheckResult) { +func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup *FeedLookup, i int, checkResults []ocr2keepers.CheckResult, lggr logger.Logger) { defer wg.Done() - state, values, retryable, err := r.doMercuryRequest(ctx, lookup) + state, values, retryable, err := r.doMercuryRequest(ctx, lookup, lggr) if err != nil { - r.lggr.Errorf("[FeedLookup] upkeep %s retryable %v doMercuryRequest: %v", lookup.upkeepId, retryable, err) + lggr.Errorf("upkeep %s retryable %v doMercuryRequest: %v", lookup.upkeepId, retryable, err) checkResults[i].Retryable = retryable checkResults[i].PipelineExecutionState = uint8(state) return } for j, v := range values { - r.lggr.Infof("[FeedLookup] checkCallback values[%d]=%s", j, hexutil.Encode(v)) + lggr.Infof("checkCallback values[%d]=%s", j, hexutil.Encode(v)) } state, retryable, mercuryBytes, err := r.checkCallback(ctx, values, lookup) if err != nil { - r.lggr.Errorf("[FeedLookup] upkeep %s block %d checkCallback err: %v", lookup.upkeepId, lookup.block, err) + lggr.Errorf("upkeep %s block %d checkCallback err: %v", lookup.upkeepId, lookup.block, err) checkResults[i].Retryable = retryable checkResults[i].PipelineExecutionState = uint8(state) return } - r.lggr.Infof("[FeedLookup] checkCallback mercuryBytes=%s", hexutil.Encode(mercuryBytes)) + lggr.Infof("checkCallback mercuryBytes=%s", hexutil.Encode(mercuryBytes)) state, needed, performData, failureReason, _, err := r.packer.UnpackCheckCallbackResult(mercuryBytes) if err != nil { - r.lggr.Errorf("[FeedLookup] upkeep %s block %d UnpackCheckCallbackResult err: %v", lookup.upkeepId, lookup.block, err) + lggr.Errorf("upkeep %s block %d UnpackCheckCallbackResult err: %v", lookup.upkeepId, lookup.block, err) checkResults[i].PipelineExecutionState = uint8(state) return } if failureReason == uint8(UpkeepFailureReasonMercuryCallbackReverted) { checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryCallbackReverted) - r.lggr.Debugf("[FeedLookup] upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) + lggr.Debugf("upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) return } if !needed { checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonUpkeepNotNeeded) - r.lggr.Debugf("[FeedLookup] upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) + lggr.Debugf("upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) return } checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonNone) checkResults[i].Eligible = true checkResults[i].PerformData = performData - r.lggr.Infof("[FeedLookup] upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) + lggr.Infof("upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) } // allowedToUseMercury retrieves upkeep's administrative offchain config and decode a mercuryEnabled bool to indicate if @@ -235,24 +247,21 @@ func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup } // doMercuryRequest sends requests to Mercury API to retrieve ChainlinkBlob. -func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup) (PipelineExecutionState, [][]byte, bool, error) { +func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr logger.Logger) (PipelineExecutionState, [][]byte, bool, error) { + var isMercuryV03 bool resultLen := len(ml.feeds) ch := make(chan MercuryData, resultLen) - if ml.feedParamKey == FeedIdHex && ml.timeParamKey == BlockNumber { + if ml.feedParamKey == feedIdHex && ml.timeParamKey == blockNumber { // only mercury v0.2 for i := range ml.feeds { - go r.singleFeedRequest(ctx, ch, i, ml, MercuryV02) + go r.singleFeedRequest(ctx, ch, i, ml, lggr) } - } else if ml.feedParamKey == FeedId && ml.timeParamKey == Timestamp { + } else if ml.feedParamKey == feedIDs && ml.timeParamKey == timestamp { // only mercury v0.3 - if resultLen == 1 { - go r.singleFeedRequest(ctx, ch, 0, ml, MercuryV03) - } else { - // create a new channel with buffer size 1 since the batch endpoint will only return 1 blob - resultLen = 1 - ch = make(chan MercuryData, resultLen) - go r.multiFeedsRequest(ctx, ch, ml) - } + resultLen = 1 + isMercuryV03 = true + ch = make(chan MercuryData, resultLen) + go r.multiFeedsRequest(ctx, ch, ml, lggr) } else { return InvalidRevertDataInput, nil, false, fmt.Errorf("invalid label combination: feed param key %s and time param key %s", ml.feedParamKey, ml.timeParamKey) } @@ -261,9 +270,9 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup) (Pip results := make([][]byte, len(ml.feeds)) retryable := true allSuccess := true - // use the last execution error as the state, if no execution errors, state will be no error + // in v0.2, use the last execution error as the state, if no execution errors, state will be no error state := NoPipelineError - for i := 0; i < len(results); i++ { + for i := 0; i < resultLen; i++ { m := <-ch if m.Error != nil { reqErr = errors.Join(reqErr, m.Error) @@ -272,27 +281,28 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup) (Pip if m.State != NoPipelineError { state = m.State } + continue + } + if isMercuryV03 { + results = m.Bytes + } else { + results[m.Index] = m.Bytes[0] } - results[m.Index] = m.Bytes } - r.lggr.Debugf("FeedLookup upkeep %s retryable %s reqErr %w", ml.upkeepId.String(), retryable && !allSuccess, reqErr) + lggr.Debugf("upkeep %s retryable %s reqErr %w", ml.upkeepId.String(), retryable && !allSuccess, reqErr) // only retry when not all successful AND none are not retryable return state, results, retryable && !allSuccess, reqErr } -// singleFeedRequest sends a Mercury request for a single feed report. -func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryData, index int, ml *FeedLookup, mv MercuryVersion) { +// singleFeedRequest sends a v0.2 Mercury request for a single feed report. +func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryData, index int, ml *FeedLookup, lggr logger.Logger) { q := url.Values{ ml.feedParamKey: {ml.feeds[index]}, ml.timeParamKey: {ml.time.String()}, } mercuryURL := r.mercury.cred.URL - path := MercuryPathV2 - if mv == MercuryV03 { - path = MercuryPathV3 - } - reqUrl := fmt.Sprintf("%s%s%s", mercuryURL, path, q.Encode()) - r.lggr.Debugf("FeedLookup request URL: %s", reqUrl) + reqUrl := fmt.Sprintf("%s%s%s", mercuryURL, mercuryPathV02, q.Encode()) + lggr.Debugf("request URL: %s", reqUrl) req, err := http.NewRequestWithContext(ctx, http.MethodGet, reqUrl, nil) if err != nil { @@ -301,11 +311,11 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa } ts := time.Now().UTC().UnixMilli() - signature := r.generateHMAC(http.MethodGet, path+q.Encode(), []byte{}, r.mercury.cred.Username, r.mercury.cred.Password, ts) - req.Header.Set("Content-Type", "application/json") - req.Header.Set("Authorization", r.mercury.cred.Username) - req.Header.Set("X-Authorization-Timestamp", strconv.FormatInt(ts, 10)) - req.Header.Set("X-Authorization-Signature-SHA256", signature) + signature := r.generateHMAC(http.MethodGet, mercuryPathV02+q.Encode(), []byte{}, r.mercury.cred.Username, r.mercury.cred.Password, ts) + req.Header.Set(headerContentType, applicationJson) + req.Header.Set(headerAuthorization, r.mercury.cred.Username) + req.Header.Set(headerTimestamp, strconv.FormatInt(ts, 10)) + req.Header.Set(headerSignature, signature) // in the case of multiple retries here, use the last attempt's data state := NoPipelineError @@ -316,7 +326,7 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { - r.lggr.Warnf("FeedLookup upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + lggr.Warnf("upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) retryable = true state = MercuryFlakyFailure return err1 @@ -325,12 +335,12 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa body, err1 := io.ReadAll(resp.Body) if err1 != nil { retryable = false - state = FailedToReadMercuryResponse + state = FailedToDecodeMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { - r.lggr.Warnf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) + lggr.Warnf("upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) retryable = true state = MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) @@ -340,24 +350,24 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) } - var m MercuryResponse + var m MercuryV02Response err1 = json.Unmarshal(body, &m) if err1 != nil { - r.lggr.Warnf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + lggr.Warnf("upkeep %s block %s failed to unmarshal body to MercuryV02Response for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) retryable = false state = MercuryUnmarshalError return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { - r.lggr.Warnf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) + lggr.Warnf("upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) retryable = false - state = FailedToReadMercuryResponse + state = FailedToDecodeMercuryResponse return err1 } ch <- MercuryData{ Index: index, - Bytes: blobBytes, + Bytes: [][]byte{blobBytes}, Retryable: false, State: NoPipelineError, } @@ -369,12 +379,13 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa return err.Error() == fmt.Sprintf("%d", http.StatusNotFound) || err.Error() == fmt.Sprintf("%d", http.StatusInternalServerError) }), retry.Context(ctx), - retry.Delay(RetryDelay), - retry.Attempts(TotalAttempt)) + retry.Delay(retryDelay), + retry.Attempts(totalAttempt)) if !sent { md := MercuryData{ Index: index, + Bytes: [][]byte{}, Retryable: retryable, Error: retryErr, State: state, @@ -383,15 +394,15 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa } } -// multiFeedsRequest sends a Mercury request for a multi-feed report -func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryData, ml *FeedLookup) { +// multiFeedsRequest sends a Mercury v0.3 request for a multi-feed report +func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryData, ml *FeedLookup, lggr logger.Logger) { q := url.Values{ - FeedId: {strings.Join(ml.feeds, ",")}, - Timestamp: {ml.time.String()}, + feedIDs: {strings.Join(ml.feeds, ",")}, + timestamp: {ml.time.String()}, } - reqUrl := fmt.Sprintf("%s%s%s", r.mercury.cred.URL, MercuryBatchPathV3, q.Encode()) - r.lggr.Debugf("FeedLookup request URL: %s", reqUrl) + reqUrl := fmt.Sprintf("%s%s%s", r.mercury.cred.URL, mercuryBatchPathV03, q.Encode()) + lggr.Debugf("request URL: %s", reqUrl) req, err := http.NewRequestWithContext(ctx, http.MethodGet, reqUrl, nil) if err != nil { @@ -400,11 +411,15 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa } ts := time.Now().UTC().UnixMilli() - signature := r.generateHMAC(http.MethodGet, MercuryBatchPathV3+q.Encode(), []byte{}, r.mercury.cred.Username, r.mercury.cred.Password, ts) - req.Header.Set("Content-Type", "application/json") - req.Header.Set("Authorization", r.mercury.cred.Username) - req.Header.Set("X-Authorization-Timestamp", strconv.FormatInt(ts, 10)) - req.Header.Set("X-Authorization-Signature-SHA256", signature) + signature := r.generateHMAC(http.MethodGet, mercuryBatchPathV03+q.Encode(), []byte{}, r.mercury.cred.Username, r.mercury.cred.Password, ts) + req.Header.Set(headerContentType, applicationJson) + // username here is often referred to as user id + req.Header.Set(headerAuthorization, r.mercury.cred.Username) + req.Header.Set(headerTimestamp, strconv.FormatInt(ts, 10)) + req.Header.Set(headerSignature, signature) + // mercury will inspect authorization headers above to make sure this user (in automation's context, this node) is eligible to access mercury + // and if it has an automation role. it will then look at this upkeep id to check if it has access to all the requested feeds. + req.Header.Set(headerUpkeepId, ml.upkeepId.String()) // in the case of multiple retries here, use the last attempt's data state := NoPipelineError @@ -415,7 +430,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { - r.lggr.Warnf("FeedLookup upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + lggr.Warnf("upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) retryable = true state = MercuryFlakyFailure return err1 @@ -424,12 +439,12 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa body, err1 := io.ReadAll(resp.Body) if err1 != nil { retryable = false - state = FailedToReadMercuryResponse + state = FailedToDecodeMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { - r.lggr.Warnf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) + lggr.Warnf("upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) retryable = true state = MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) @@ -439,24 +454,29 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) } - var m MercuryResponse - err1 = json.Unmarshal(body, &m) + var responses []MercuryV03Response + err1 = json.Unmarshal(body, &responses) if err1 != nil { - r.lggr.Warnf("FeedLookup upkeep %s block %s failed to unmarshal body to MercuryResponse for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + lggr.Warnf("upkeep %s block %s failed to unmarshal body to MercuryV03Response for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) retryable = false state = MercuryUnmarshalError return err1 } - blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) - if err1 != nil { - r.lggr.Warnf("FeedLookup upkeep %s block %s failed to decode chainlinkBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, err1) - retryable = false - state = FailedToReadMercuryResponse - return err1 + var reportBytes [][]byte + var b []byte + for _, rsp := range responses { + b, err1 = hexutil.Decode(rsp.FullReport) + if err1 != nil { + lggr.Warnf("upkeep %s block %s failed to decode reportBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), rsp.FullReport, err1) + retryable = false + state = FailedToDecodeMercuryResponse + return err1 + } + reportBytes = append(reportBytes, b) } ch <- MercuryData{ Index: 0, - Bytes: blobBytes, + Bytes: reportBytes, Retryable: false, State: NoPipelineError, } @@ -468,12 +488,13 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa return err.Error() == fmt.Sprintf("%d", http.StatusNotFound) || err.Error() == fmt.Sprintf("%d", http.StatusInternalServerError) }), retry.Context(ctx), - retry.Delay(RetryDelay), - retry.Attempts(TotalAttempt)) + retry.Delay(retryDelay), + retry.Attempts(totalAttempt)) if !sent { md := MercuryData{ Index: 0, + Bytes: [][]byte{}, Retryable: retryable, Error: retryErr, State: state, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index dabf33da9e3..d647714d23f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -191,7 +191,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { if tt.blob != "" { hc := mocks.NewHttpClient(t) - mr := MercuryResponse{ChainlinkBlob: tt.blob} + mr := MercuryV02Response{ChainlinkBlob: tt.blob} b, err := json.Marshal(mr) assert.Nil(t, err) resp := &http.Response{ @@ -237,9 +237,9 @@ func TestEvmRegistry_DecodeFeedLookup(t *testing.T) { data: []byte{125, 221, 147, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 138, 215, 253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 100, 72, 101, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 53, 53, 52, 52, 56, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 50, 53, 52, 52, 51, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, state: NoPipelineError, expected: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(25876477), extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, }, @@ -356,9 +356,9 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { { name: "success", lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(25880526), extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, upkeepId: upkeepId, @@ -372,9 +372,9 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { { name: "failure - retryable", lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(25880526), extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, upkeepId: upkeepId, @@ -389,9 +389,9 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { { name: "failure - not retryable", lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(25880526), extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, upkeepId: upkeepId, @@ -411,7 +411,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { hc := mocks.NewHttpClient(t) for _, blob := range tt.mockChainlinkBlobs { - mr := MercuryResponse{ChainlinkBlob: blob} + mr := MercuryV02Response{ChainlinkBlob: blob} b, err := json.Marshal(mr) assert.Nil(t, err) @@ -420,14 +420,14 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { Body: io.NopCloser(bytes.NewReader(b)), } if tt.expectedError != nil && tt.expectedRetryable { - hc.On("Do", mock.Anything).Return(resp, nil).Times(TotalAttempt) + hc.On("Do", mock.Anything).Return(resp, nil).Times(totalAttempt) } else { hc.On("Do", mock.Anything).Return(resp, nil).Once() } } r.hc = hc - state, values, retryable, reqErr := r.doMercuryRequest(context.Background(), tt.lookup) + state, values, retryable, reqErr := r.doMercuryRequest(context.Background(), tt.lookup, r.lggr) assert.Equal(t, tt.expectedValues, values) assert.Equal(t, tt.expectedRetryable, retryable) assert.Equal(t, tt.state, state) @@ -444,7 +444,6 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { name string index int lookup *FeedLookup - mv MercuryVersion blob string statusCode int lastStatusCode int @@ -456,26 +455,24 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { name: "success - mercury responds in the first try", index: 0, lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(123456), upkeepId: upkeepId, }, - mv: MercuryV02, blob: "0xab2123dc00000012", }, { name: "success - retry for 404", index: 0, lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(123456), upkeepId: upkeepId, }, - mv: MercuryV02, blob: "0xab2123dcbabbad", retryNumber: 1, statusCode: http.StatusNotFound, @@ -485,13 +482,12 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { name: "success - retry for 500", index: 0, lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(123456), upkeepId: upkeepId, }, - mv: MercuryV02, blob: "0xab2123dcbbabad", retryNumber: 2, statusCode: http.StatusInternalServerError, @@ -501,15 +497,14 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { name: "failure - returns retryable", index: 0, lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(123456), upkeepId: upkeepId, }, - mv: MercuryV02, blob: "0xab2123dc", - retryNumber: TotalAttempt, + retryNumber: totalAttempt, statusCode: http.StatusNotFound, retryable: true, errorMessage: "All attempts fail:\n#1: 404\n#2: 404\n#3: 404", @@ -518,13 +513,12 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { name: "failure - returns retryable and then non-retryable", index: 0, lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(123456), upkeepId: upkeepId, }, - mv: MercuryV02, blob: "0xab2123dc", retryNumber: 1, statusCode: http.StatusNotFound, @@ -535,13 +529,12 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { name: "failure - returns not retryable", index: 0, lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(123456), upkeepId: upkeepId, }, - mv: MercuryV02, blob: "0xab2123dc", statusCode: http.StatusBadGateway, errorMessage: "All attempts fail:\n#1: FeedLookup upkeep 123456789 block 123456 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", @@ -553,7 +546,7 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { r := setupEVMRegistry(t) hc := mocks.NewHttpClient(t) - mr := MercuryResponse{ChainlinkBlob: tt.blob} + mr := MercuryV02Response{ChainlinkBlob: tt.blob} b, err := json.Marshal(mr) assert.Nil(t, err) @@ -571,7 +564,7 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { } hc.On("Do", mock.Anything).Return(resp, nil).Once() } - } else if tt.retryNumber > 0 && tt.retryNumber < TotalAttempt { + } else if tt.retryNumber > 0 && tt.retryNumber < totalAttempt { retryResp := &http.Response{ StatusCode: tt.statusCode, Body: io.NopCloser(bytes.NewReader(b)), @@ -593,19 +586,19 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { r.hc = hc ch := make(chan MercuryData, 1) - r.singleFeedRequest(context.Background(), ch, tt.index, tt.lookup, tt.mv) + r.singleFeedRequest(context.Background(), ch, tt.index, tt.lookup, r.lggr) m := <-ch assert.Equal(t, tt.index, m.Index) assert.Equal(t, tt.retryable, m.Retryable) - if tt.retryNumber >= TotalAttempt || tt.errorMessage != "" { + if tt.retryNumber >= totalAttempt || tt.errorMessage != "" { assert.Equal(t, tt.errorMessage, m.Error.Error()) - assert.Nil(t, m.Bytes) + assert.Equal(t, [][]byte{}, m.Bytes) } else { blobBytes, err := hexutil.Decode(tt.blob) assert.Nil(t, err) assert.Nil(t, m.Error) - assert.Equal(t, blobBytes, m.Bytes) + assert.Equal(t, [][]byte{blobBytes}, m.Bytes) } }) } @@ -616,63 +609,101 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { tests := []struct { name string lookup *FeedLookup - blob string statusCode int lastStatusCode int retryNumber int retryable bool errorMessage string + responses []MercuryV03Response }{ { name: "success - mercury responds in the first try", lookup: &FeedLookup{ - feedParamKey: FeedId, + feedParamKey: feedIDs, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: Timestamp, + timeParamKey: timestamp, time: big.NewInt(123456), upkeepId: upkeepId, }, - blob: "0xab2123dc00000012", + responses: []MercuryV03Response{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + { + FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123458", + ObservationsTimestamp: "123458", + FullReport: "0xab2123dc00000016", + }, + }, }, { name: "success - retry for 404", lookup: &FeedLookup{ - feedParamKey: FeedId, + feedParamKey: feedIDs, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: Timestamp, + timeParamKey: timestamp, time: big.NewInt(123456), upkeepId: upkeepId, }, - blob: "0xab2123dcbabbad", retryNumber: 1, statusCode: http.StatusNotFound, lastStatusCode: http.StatusOK, + responses: []MercuryV03Response{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + { + FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123458", + ObservationsTimestamp: "123458", + FullReport: "0xab2123dc00000012", + }, + }, }, { name: "success - retry for 500", lookup: &FeedLookup{ - feedParamKey: FeedId, + feedParamKey: feedIDs, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: Timestamp, + timeParamKey: timestamp, time: big.NewInt(123456), upkeepId: upkeepId, }, - blob: "0xab2123dcbbabad", retryNumber: 2, statusCode: http.StatusInternalServerError, lastStatusCode: http.StatusOK, + responses: []MercuryV03Response{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + { + FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123458", + ObservationsTimestamp: "123458", + FullReport: "0xab2123dc00000019", + }, + }, }, { name: "failure - returns retryable", lookup: &FeedLookup{ - feedParamKey: FeedId, + feedParamKey: feedIDs, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: Timestamp, + timeParamKey: timestamp, time: big.NewInt(123456), upkeepId: upkeepId, }, - blob: "0xab2123dc", - retryNumber: TotalAttempt, + retryNumber: totalAttempt, statusCode: http.StatusNotFound, retryable: true, errorMessage: "All attempts fail:\n#1: 404\n#2: 404\n#3: 404", @@ -680,13 +711,12 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { { name: "failure - returns retryable and then non-retryable", lookup: &FeedLookup{ - feedParamKey: FeedId, + feedParamKey: feedIDs, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: Timestamp, + timeParamKey: timestamp, time: big.NewInt(123456), upkeepId: upkeepId, }, - blob: "0xab2123dc", retryNumber: 1, statusCode: http.StatusNotFound, lastStatusCode: http.StatusBadGateway, @@ -695,13 +725,12 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { { name: "failure - returns not retryable", lookup: &FeedLookup{ - feedParamKey: FeedId, + feedParamKey: feedIDs, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: Timestamp, + timeParamKey: timestamp, time: big.NewInt(123456), upkeepId: upkeepId, }, - blob: "0xab2123dc", statusCode: http.StatusBadGateway, errorMessage: "All attempts fail:\n#1: FeedLookup upkeep 123456789 block 123456 received status code 502 for multi feed", }, @@ -712,8 +741,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { r := setupEVMRegistry(t) hc := mocks.NewHttpClient(t) - mr := MercuryResponse{ChainlinkBlob: tt.blob} - b, err := json.Marshal(mr) + b, err := json.Marshal(tt.responses) assert.Nil(t, err) if tt.retryNumber == 0 { @@ -730,7 +758,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { } hc.On("Do", mock.Anything).Return(resp, nil).Once() } - } else if tt.retryNumber > 0 && tt.retryNumber < TotalAttempt { + } else if tt.retryNumber > 0 && tt.retryNumber < totalAttempt { retryResp := &http.Response{ StatusCode: tt.statusCode, Body: io.NopCloser(bytes.NewReader(b)), @@ -752,19 +780,24 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { r.hc = hc ch := make(chan MercuryData, 1) - r.multiFeedsRequest(context.Background(), ch, tt.lookup) + r.multiFeedsRequest(context.Background(), ch, tt.lookup, r.lggr) m := <-ch assert.Equal(t, 0, m.Index) assert.Equal(t, tt.retryable, m.Retryable) - if tt.retryNumber >= TotalAttempt || tt.errorMessage != "" { + if tt.retryNumber >= totalAttempt || tt.errorMessage != "" { assert.Equal(t, tt.errorMessage, m.Error.Error()) - assert.Nil(t, m.Bytes) + assert.Equal(t, [][]byte{}, m.Bytes) } else { - blobBytes, err := hexutil.Decode(tt.blob) - assert.Nil(t, err) assert.Nil(t, m.Error) - assert.Equal(t, blobBytes, m.Bytes) + var reports [][]byte + var report []byte + for _, rsp := range tt.responses { + report, err = hexutil.Decode(rsp.FullReport) + assert.Nil(t, err) + reports = append(reports, report) + } + assert.Equal(t, reports, m.Bytes) } }) } @@ -772,7 +805,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { func TestEvmRegistry_CheckCallback(t *testing.T) { upkeepId := big.NewInt(123456789) - blockNumber := uint64(999) + bn := uint64(999) bs := []byte{183, 114, 215, 10, 0, 0, 0, 0, 0, 0} values := [][]byte{bs} tests := []struct { @@ -794,13 +827,13 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { { name: "success - empty extra data", lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"ETD-USD", "BTC-ETH"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(100), extraData: []byte{48, 120, 48, 48}, upkeepId: upkeepId, - block: blockNumber, + block: bn, }, values: values, statusCode: http.StatusOK, @@ -812,14 +845,14 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { { name: "success - with extra data", lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(18952430), // this is the address of precompile contract ArbSys(0x0000000000000000000000000000000000000064) extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, upkeepId: upkeepId, - block: blockNumber, + block: bn, }, values: values, statusCode: http.StatusOK, @@ -831,13 +864,13 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { { name: "failure - bad response", lookup: &FeedLookup{ - feedParamKey: FeedIdHex, + feedParamKey: feedIdHex, feeds: []string{"ETD-USD", "BTC-ETH"}, - timeParamKey: BlockNumber, + timeParamKey: blockNumber, time: big.NewInt(100), extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 32, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 4, 48, 120, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, upkeepId: upkeepId, - block: blockNumber, + block: bn, }, values: values, statusCode: http.StatusOK, From 77f007401465ec527d48db2f8b70f4111dbba16b Mon Sep 17 00:00:00 2001 From: krehermann Date: Thu, 17 Aug 2023 05:58:59 -0600 Subject: [PATCH 199/270] BCF-2317 One relayer per chain id (#9788) * BCF-2317 One relayer per chain id First sketch... Adds plumbing for Solana only to get quick feedback Key ideas: - Identify relayer as (name, id) tuple eg "solana", "solana-chain-abc" - Create one relayer per identifier and plumb a map[relay_id]relayer to delegate - Use the existing job spec to recreate the relayer_id and do the lookup Note: this change will spawn one relayer per chain id even if the chain id is not used by a job. We may want to implement lazy relayer initialization. * hacking * hacking. track legacy chains and loop relayers. use type cast for legacy compatibility. use relayer factory. begin removing chainset from evm * progress on evm chainset conversion * get build working. * remove evm chain from public interface * complete evm chainset api removal and get first test to work * part way thru test refactor * fix all tests but mocking GetRelayers * get last test to compile * go mod tidy * return non-nil legacy evm chains for compatibility * fix shell tests * on the way to mocks for testing * fix legacy chain Get to be backward compatible. fix nil maps * fix signature. fix relayer opts init * fix bad merge * more test fixes * ensure default chain from relayer extenders * fix legacychain.Get() empty string handling to be backward compatible. * fmt.errorf fixes, nil map fix in cosmos, test fixes * fix test validation errors in job runner. spec was bad; not sure why it used to work unless validation was mocked... * fix retryable eth tx failure and err fmting * err message fix in test and default chain handling in cltest for mock legacy chain * fix eth task err; fix bad merge with vrf * add interface mocks and fix web test * add mocks for RelayChainInteroperators and fix node resolver web test * more mocks * promote legacy chains to interface for testing with web/graphql * manually edit mock file to rm internal pkg dep. not sure how to do this automatically without changning the relayer repo * fix shell test and start fixing eth_key_test * manually fix mocked interface and add comments * fix forward delegate test * fix controller test; fix ChainStatuses implemenation for RelayerChainInteroperator * fix evm chain controller test * wip -- starting services for new relayerchaininterop. cosmos tests still failing * support single chain: relayer in cosmos, but causes a panic b/c the cosmos lib does a global init * bump cosmos to take relayer init once fix and make test ordered to fix it * more web test fixes: big-int-parsable evm keys and node status mocking * fix helper func * fix eth key tests with mocks * make shell local test work with mocks * relayerchaininteroperator node status as a filter on ids to fix tests * remove unused mocks * fix cosmos relayer service funcs. only need to call relayer methods, not single chain because the underlayin adapter handles it for us * fix linter issues * code cleanup, documentation and reorganization * update cosmos * code cleanup * add tests for relayer chain interoperator * update cosmos * fix bad merge * fix node defnition in test controller * fix/reinstitute mock geth client in cltest * more cosmos fixes * change cosmos integration test b/c the init is done in the relayer inside the cosmos package; fix linter errors * take cosmos relayer sdk init only once * update TODOs with tickets, fix lint * reorganize files to remove emv/chain_set.go * naming; code clean up * address feedback; add ticket references; general cleanup * fix merge fallout * update cosmos to committed version, add test coverage for sonar, remove commented code * fix EVMORM implementation - expose via LegacyChains implmentation; address comments * address comments: update names, take simplifying comment, remove dead code * add tests, mv smoke test code to try to fix ci failure * fix codesmells * more cleanup and comment resolution * simplify legacy chain construction and access; remove PUT * simplify ChainStatus func args * rename func for more context, fix up mocks, delete cruft * add test coverage --- core/chains/chain_kv.go | 62 +++ core/chains/chain_kv_test.go | 93 ++++ core/chains/chain_set.go | 10 +- core/chains/cosmos/chain_set.go | 107 ++++- core/chains/evm/chain.go | 139 +++++- core/chains/evm/chain_set.go | 325 ------------- core/chains/evm/chain_set_test.go | 61 --- core/chains/evm/config/chain_scoped.go | 25 +- core/chains/evm/config/config.go | 2 + core/chains/evm/evm_txm.go | 2 +- core/chains/evm/log/helpers_test.go | 7 +- .../evm/mocks/legacy_chain_container.go | 165 +++++++ core/cmd/cosmos_transaction_commands_test.go | 6 +- core/cmd/helpers_test.go | 2 - core/cmd/ocr2vrf_configure_commands.go | 6 +- core/cmd/shell.go | 217 ++------- core/cmd/shell_local.go | 17 +- core/cmd/shell_local_test.go | 104 ++++- core/cmd/shell_test.go | 67 ++- core/internal/cltest/cltest.go | 154 +++---- core/internal/cltest/job_factories.go | 5 +- core/internal/cltest/mocks.go | 28 +- core/internal/features/features_test.go | 24 +- .../features/ocr2/features_ocr2_test.go | 13 +- core/internal/mocks/application.go | 30 +- .../testutils/configtest/v2/general_config.go | 20 +- core/internal/testutils/evmtest/evmtest.go | 43 +- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/services/blockhashstore/bhs_test.go | 6 +- core/services/blockhashstore/delegate.go | 16 +- core/services/blockhashstore/delegate_test.go | 36 +- core/services/blockheaderfeeder/delegate.go | 16 +- core/services/chainlink/application.go | 152 +++--- .../mocks/relayer_chain_interoperators.go | 248 ++++++++++ .../chainlink/relayer_chain_interoperators.go | 368 +++++++++++++++ .../relayer_chain_interoperators_test.go | 419 +++++++++++++++++ core/services/chainlink/relayer_factory.go | 217 +++++++++ core/services/cron/cron_test.go | 6 +- core/services/directrequest/delegate.go | 18 +- core/services/directrequest/delegate_test.go | 14 +- core/services/feeds/orm_test.go | 18 +- core/services/feeds/service.go | 8 +- core/services/feeds/service_test.go | 10 +- core/services/fluxmonitorv2/delegate.go | 20 +- .../fluxmonitorv2/integrations_test.go | 4 +- core/services/fluxmonitorv2/orm_test.go | 6 +- core/services/functions/listener_test.go | 7 +- core/services/gateway/delegate.go | 12 +- core/services/gateway/handler_factory.go | 10 +- .../handlers/functions/handler.functions.go | 15 +- core/services/job/helpers_test.go | 6 +- core/services/job/job_orm_test.go | 131 +++--- .../job/job_pipeline_orm_integration_test.go | 8 +- core/services/job/models.go | 62 ++- core/services/job/models_test.go | 73 +++ core/services/job/orm.go | 38 +- core/services/job/orm_test.go | 4 +- core/services/job/runner_integration_test.go | 65 +-- core/services/job/spawner_test.go | 57 ++- core/services/job/util.go | 33 -- core/services/keeper/delegate.go | 28 +- core/services/keeper/integration_test.go | 2 +- .../registry_synchronizer_helper_test.go | 8 +- core/services/keeper/upkeep_executer_test.go | 8 +- core/services/ocr/delegate.go | 28 +- core/services/ocr/validate.go | 4 +- core/services/ocr2/delegate.go | 157 ++++--- core/services/ocr2/delegate_test.go | 23 +- .../ocr2/plugins/mercury/integration_test.go | 6 +- .../plugins/ocr2keeper/integration_test.go | 2 +- core/services/ocr2/plugins/ocr2keeper/util.go | 32 +- .../internal/ocr2vrf_integration_test.go | 2 +- core/services/ocrbootstrap/delegate.go | 35 +- core/services/ocrcommon/data_source.go | 1 + core/services/pipeline/common.go | 15 +- core/services/pipeline/common_test.go | 16 +- core/services/pipeline/helpers_test.go | 8 +- core/services/pipeline/orm_test.go | 11 +- core/services/pipeline/runner.go | 13 +- core/services/pipeline/runner_test.go | 12 +- core/services/pipeline/task.estimategas.go | 11 +- core/services/pipeline/task.eth_call.go | 9 +- core/services/pipeline/task.eth_call_test.go | 13 +- core/services/pipeline/task.eth_tx.go | 15 +- core/services/pipeline/task.eth_tx_test.go | 9 +- core/services/relay/evm/evm.go | 84 ++-- core/services/relay/evm/functions.go | 12 +- core/services/relay/evm/loop_impl.go | 36 ++ .../relay/evm/mercury/v1/data_source.go | 1 + .../relay/evm/mercury/v1/data_source_test.go | 8 +- .../relay/evm/mocks/loop_relay_adapter.go} | 180 +++++--- core/services/relay/evm/relayer_extender.go | 432 ++++++++++++++++++ .../relay/evm/relayer_extender_test.go | 89 ++++ core/services/relay/evm/types/types.go | 34 ++ core/services/relay/relay.go | 56 +++ core/services/relay/relay_test.go | 48 ++ core/services/vrf/delegate.go | 32 +- core/services/vrf/delegate_test.go | 62 +-- core/services/vrf/v1/integration_test.go | 4 +- .../vrf/v2/integration_helpers_test.go | 15 +- core/services/vrf/v2/integration_v2_test.go | 2 +- core/web/chains_controller.go | 22 +- core/web/common.go | 16 +- core/web/cosmos_chains_controller.go | 8 +- core/web/cosmos_chains_controller_test.go | 6 +- core/web/cosmos_nodes_controller.go | 3 +- core/web/cosmos_transfer_controller.go | 6 +- core/web/eth_keys_controller.go | 23 +- core/web/eth_keys_controller_test.go | 2 +- core/web/evm_chains_controller.go | 8 +- core/web/evm_chains_controller_test.go | 45 +- core/web/evm_forwarders_controller.go | 2 +- core/web/evm_forwarders_controller_test.go | 2 +- core/web/evm_nodes_controller.go | 3 +- core/web/evm_transfer_controller.go | 2 +- core/web/jobs_controller.go | 2 +- core/web/loader/loader_test.go | 38 +- core/web/loader/node.go | 13 +- core/web/nodes_controller.go | 4 +- core/web/replay_controller.go | 2 +- core/web/resolver/eth_key_test.go | 180 ++++---- core/web/resolver/mutation.go | 2 +- core/web/resolver/node_test.go | 11 +- core/web/resolver/query.go | 12 +- core/web/resolver/resolver_test.go | 96 ++-- core/web/solana_chains_controller.go | 10 +- core/web/solana_chains_controller_test.go | 5 +- core/web/solana_nodes_controller.go | 3 +- core/web/solana_transfer_controller.go | 20 +- core/web/starknet_chains_controller.go | 10 +- core/web/starknet_nodes_controller.go | 3 +- go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- .../smoke/forwarders_ocr2_test.go | 3 +- 137 files changed, 4180 insertions(+), 1800 deletions(-) create mode 100644 core/chains/chain_kv.go create mode 100644 core/chains/chain_kv_test.go delete mode 100644 core/chains/evm/chain_set.go delete mode 100644 core/chains/evm/chain_set_test.go create mode 100644 core/chains/evm/mocks/legacy_chain_container.go create mode 100644 core/services/chainlink/mocks/relayer_chain_interoperators.go create mode 100644 core/services/chainlink/relayer_chain_interoperators.go create mode 100644 core/services/chainlink/relayer_chain_interoperators_test.go create mode 100644 core/services/chainlink/relayer_factory.go create mode 100644 core/services/job/models_test.go create mode 100644 core/services/relay/evm/loop_impl.go rename core/{chains/evm/mocks/chain_set.go => services/relay/evm/mocks/loop_relay_adapter.go} (52%) create mode 100644 core/services/relay/evm/relayer_extender.go create mode 100644 core/services/relay/evm/relayer_extender_test.go create mode 100644 core/services/relay/relay_test.go diff --git a/core/chains/chain_kv.go b/core/chains/chain_kv.go new file mode 100644 index 00000000000..6292ef10197 --- /dev/null +++ b/core/chains/chain_kv.go @@ -0,0 +1,62 @@ +package chains + +import ( + "errors" + "fmt" + + "golang.org/x/exp/maps" +) + +type ChainsKV[T ChainService] struct { + // note: this is read only after construction so no need for mutex + chains map[string]T +} + +var ErrNoSuchChainID = errors.New("chain id does not exist") + +func NewChainsKV[T ChainService](cs map[string]T) *ChainsKV[T] { + + return &ChainsKV[T]{ + chains: cs, + } +} +func (c *ChainsKV[T]) Len() int { + return len(c.chains) +} + +// Get return [ErrNoSuchChainID] if [id] is not found +func (c *ChainsKV[T]) Get(id string) (T, error) { + var dflt T + chn, exist := c.chains[id] + if !exist { + return dflt, fmt.Errorf("%w: %s", ErrNoSuchChainID, id) + } + return chn, nil +} + +func (c *ChainsKV[T]) List(ids ...string) ([]T, error) { + if len(ids) == 0 { + return c.Slice(), nil + } + + var ( + result []T + err error + ) + + for _, id := range ids { + chn, exists := c.chains[id] + if !exists { + err2 := fmt.Errorf("%w: %s", ErrNoSuchChainID, id) + err = errors.Join(err, err2) + continue + } + result = append(result, chn) + } + + return result, err +} + +func (c *ChainsKV[T]) Slice() []T { + return maps.Values(c.chains) +} diff --git a/core/chains/chain_kv_test.go b/core/chains/chain_kv_test.go new file mode 100644 index 00000000000..c042eea20f1 --- /dev/null +++ b/core/chains/chain_kv_test.go @@ -0,0 +1,93 @@ +package chains_test + +import ( + "context" + "math/big" + "testing" + + "github.com/stretchr/testify/assert" + + "github.com/smartcontractkit/chainlink/v2/core/chains" +) + +func Test_ChainKV(t *testing.T) { + var ( + testChainID = "id" + testChain = &testChainService{name: "test chain"} + ) + // test empty case + empty := make(map[string]*testChainService) + kv := chains.NewChainsKV[*testChainService](empty) + c, err := kv.Get(testChainID) + assert.Nil(t, c) + assert.ErrorIs(t, err, chains.ErrNoSuchChainID) + + assert.Equal(t, kv.Len(), 0) + assert.Len(t, kv.Slice(), 0) + + cs, err := kv.List() + assert.NoError(t, err) + assert.Len(t, cs, 0) + + // test with one chain + onechain := map[string]*testChainService{testChainID: testChain} + kv = chains.NewChainsKV[*testChainService](onechain) + c, err = kv.Get(testChainID) + assert.Equal(t, c, testChain) + assert.NoError(t, err) + + assert.Equal(t, kv.Len(), 1) + assert.Len(t, kv.Slice(), 1) + + cs, err = kv.List() + assert.NoError(t, err) + assert.Len(t, cs, 1) + + //List explicit chain + cs, err = kv.List(testChainID) + assert.NoError(t, err) + assert.Len(t, cs, 1) + assert.Equal(t, testChain, cs[0]) + + //List no such id + cs, err = kv.List("no such id") + assert.Error(t, err) + assert.Len(t, cs, 0) +} + +type testChainService struct { + name string +} + +// Start the service. Must quit immediately if the context is cancelled. +// The given context applies to Start function only and must not be retained. +func (s *testChainService) Start(_ context.Context) error { + return nil +} + +// Close stops the Service. +// Invariants: Usually after this call the Service cannot be started +// again, you need to build a new Service to do so. +func (s *testChainService) Close() error { + return nil +} + +// Name returns the fully qualified name of the service +func (s *testChainService) Name() string { + return s.name +} + +// Ready should return nil if ready, or an error message otherwise. +func (s *testChainService) Ready() error { + return nil +} + +// HealthReport returns a full health report of the callee including it's dependencies. +// key is the dep name, value is nil if healthy, or error message otherwise. +func (s *testChainService) HealthReport() map[string]error { + return map[string]error{} +} + +func (s *testChainService) SendTx(ctx context.Context, from string, to string, amount *big.Int, balanceCheck bool) error { + return nil +} diff --git a/core/chains/chain_set.go b/core/chains/chain_set.go index 34211fd0d08..9a9bba4ce50 100644 --- a/core/chains/chain_set.go +++ b/core/chains/chain_set.go @@ -22,14 +22,16 @@ var ( ErrNotFound = errors.New("not found") ) -// Chains is a generic interface for chain configuration. -type Chains interface { +// ChainStatuser is a generic interface for chain configuration. +type ChainStatuser interface { + // must return [ErrNotFound] if the id is not found ChainStatus(ctx context.Context, id string) (types.ChainStatus, error) ChainStatuses(ctx context.Context, offset, limit int) ([]types.ChainStatus, int, error) } -// Nodes is an interface for node configuration and state. -type Nodes interface { +// NodesStatuser is an interface for node configuration and state. +// TODO BCF2440, BCF-2511 may need Node(ctx,name) to get a node status by name +type NodesStatuser interface { NodeStatuses(ctx context.Context, offset, limit int, chainIDs ...string) (nodes []types.NodeStatus, count int, err error) } diff --git a/core/chains/cosmos/chain_set.go b/core/chains/cosmos/chain_set.go index 765d2fa358f..008c62c3ffd 100644 --- a/core/chains/cosmos/chain_set.go +++ b/core/chains/cosmos/chain_set.go @@ -1,7 +1,10 @@ package cosmos import ( - "github.com/pkg/errors" + "context" + "errors" + "fmt" + "go.uber.org/multierr" "github.com/smartcontractkit/sqlx" @@ -10,12 +13,14 @@ import ( "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/db" "github.com/smartcontractkit/chainlink-relay/pkg/logger" + "github.com/smartcontractkit/chainlink-relay/pkg/loop" + pkgcosmos "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos" "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos/types" - coreconfig "github.com/smartcontractkit/chainlink/v2/core/config" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" ) var ( @@ -25,9 +30,12 @@ var ( ErrChainIDInvalid = errors.New("chain id does not match any local chains") ) +// Chain is a wrap for easy use in other places in the core node +type Chain = adapters.Chain + // ChainSetOpts holds options for configuring a ChainSet. type ChainSetOpts struct { - Config coreconfig.AppConfig + QueryConfig pg.QConfig Logger logger.Logger DB *sqlx.DB KeyStore keystore.Cosmos @@ -37,9 +45,9 @@ type ChainSetOpts struct { func (o *ChainSetOpts) Validate() (err error) { required := func(s string) error { - return errors.Errorf("%s is required", s) + return fmt.Errorf("%s is required", s) } - if o.Config == nil { + if o.QueryConfig == nil { err = multierr.Append(err, required("Config")) } if o.Logger == nil { @@ -66,33 +74,106 @@ func (o *ChainSetOpts) ConfigsAndLogger() (chains.Configs[string, db.Node], logg func (o *ChainSetOpts) NewTOMLChain(cfg *CosmosConfig) (adapters.Chain, error) { if !cfg.IsEnabled() { - return nil, errors.Errorf("cannot create new chain with ID %s, the chain is disabled", *cfg.ChainID) + return nil, fmt.Errorf("cannot create new chain with ID %s, the chain is disabled", *cfg.ChainID) } - c, err := newChain(*cfg.ChainID, cfg, o.DB, o.KeyStore, o.Config.Database(), o.EventBroadcaster, o.Configs, o.Logger) + c, err := newChain(*cfg.ChainID, cfg, o.DB, o.KeyStore, o.QueryConfig, o.EventBroadcaster, o.Configs, o.Logger) if err != nil { return nil, err } return c, nil } -type ChainSet = adapters.ChainSet +// LegacyChainContainer is container interface for Cosmos chains +type LegacyChainContainer interface { + Get(id string) (adapters.Chain, error) + Len() int + List(ids ...string) ([]adapters.Chain, error) + Slice() []adapters.Chain +} + +type LegacyChains = chains.ChainsKV[adapters.Chain] + +var _ LegacyChainContainer = &LegacyChains{} + +func NewLegacyChains(m map[string]adapters.Chain) *LegacyChains { + return chains.NewChainsKV[adapters.Chain](m) +} + +type LoopRelayerChainer interface { + loop.Relayer + Chain() adapters.Chain +} + +type LoopRelayerSingleChain struct { + loop.Relayer + singleChain *SingleChainSet +} + +func NewLoopRelayerSingleChain(r *pkgcosmos.Relayer, s *SingleChainSet) *LoopRelayerSingleChain { + ra := relay.NewRelayerAdapter(r, s) + return &LoopRelayerSingleChain{ + Relayer: ra, + singleChain: s, + } +} +func (r *LoopRelayerSingleChain) Chain() adapters.Chain { + return r.singleChain.chain +} + +var _ LoopRelayerChainer = &LoopRelayerSingleChain{} -func NewChainSet(opts ChainSetOpts, cfgs CosmosConfigs) (ChainSet, error) { - solChains := map[string]adapters.Chain{} +func newChainSet(opts ChainSetOpts, cfgs CosmosConfigs) (adapters.ChainSet, map[string]adapters.Chain, error) { + cosmosChains := map[string]adapters.Chain{} var err error for _, chain := range cfgs { if !chain.IsEnabled() { continue } var err2 error - solChains[*chain.ChainID], err2 = opts.NewTOMLChain(chain) + cosmosChains[*chain.ChainID], err2 = opts.NewTOMLChain(chain) if err2 != nil { err = multierr.Combine(err, err2) continue } } if err != nil { - return nil, errors.Wrap(err, "failed to load some Cosmos chains") + return nil, nil, fmt.Errorf("failed to load some Cosmos chains: %w", err) + } + + cs, err := chains.NewChainSet[db.Node, adapters.Chain](cosmosChains, &opts) + if err != nil { + return nil, nil, err + } + + return cs, cosmosChains, nil +} + +// SingleChainSet is a chainset with 1 chain. TODO remove when relayer interface is updated +type SingleChainSet struct { + adapters.ChainSet + ID string + chain adapters.Chain +} + +func (s *SingleChainSet) Chain(ctx context.Context, id string) (adapters.Chain, error) { + return s.chain, nil +} + +func NewSingleChainSet(opts ChainSetOpts, cfg *CosmosConfig) (*SingleChainSet, error) { + cs, m, err := newChainSet(opts, CosmosConfigs{cfg}) + if err != nil { + return nil, err + } + if len(m) != 1 { + return nil, fmt.Errorf("invalid Single chain: more than one chain %d", len(m)) + } + var chain adapters.Chain + for _, ch := range m { + chain = ch } - return chains.NewChainSet[db.Node, adapters.Chain](solChains, &opts) + return &SingleChainSet{ + ChainSet: cs, + ID: *cfg.ChainID, + chain: chain, + }, nil } diff --git a/core/chains/evm/chain.go b/core/chains/evm/chain.go index f48a4b40e26..7b7c3c0dd7c 100644 --- a/core/chains/evm/chain.go +++ b/core/chains/evm/chain.go @@ -2,16 +2,21 @@ package evm import ( "context" + "errors" "fmt" "math/big" "net/url" "time" - "github.com/pkg/errors" "go.uber.org/multierr" "golang.org/x/exp/maps" + "github.com/smartcontractkit/sqlx" + + "github.com/smartcontractkit/chainlink-relay/pkg/types" + "github.com/smartcontractkit/chainlink/v2/core/chains" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" evmconfig "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" @@ -22,16 +27,19 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/monitor" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" + evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/config" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/utils" ) //go:generate mockery --quiet --name Chain --output ./mocks/ --case=underscore type Chain interface { - services.ServiceCtx + types.ChainService + ID() *big.Int Client() evmclient.Client Config() evmconfig.ChainScopedConfig @@ -43,11 +51,73 @@ type Chain interface { BalanceMonitor() monitor.BalanceMonitor LogPoller() logpoller.LogPoller GasEstimator() gas.EvmFeeEstimator +} + +var ( + _ Chain = &chain{} + nilBigInt *big.Int + emptyString string +) + +// LegacyChains implements [LegacyChainContainer] +type LegacyChains struct { + *chains.ChainsKV[Chain] + dflt Chain + + cfgs evmtypes.Configs +} - SendTx(ctx context.Context, from, to string, amount *big.Int, balanceCheck bool) error +// LegacyChainContainer is container for EVM chains. +// +//go:generate mockery --quiet --name LegacyChainContainer --output ./mocks/ --case=underscore +type LegacyChainContainer interface { + SetDefault(Chain) + Default() (Chain, error) + Get(id string) (Chain, error) + Len() int + List(ids ...string) ([]Chain, error) + Slice() []Chain + + ChainNodeConfigs() evmtypes.Configs } -var _ Chain = &chain{} +var _ LegacyChainContainer = &LegacyChains{} + +func NewLegacyChains(c evmtypes.Configs, m map[string]Chain) *LegacyChains { + return &LegacyChains{ + ChainsKV: chains.NewChainsKV[Chain](m), + cfgs: c, + } +} + +func (c *LegacyChains) ChainNodeConfigs() evmtypes.Configs { + return c.cfgs +} + +// TODO BCR-2510 this may not be needed if EVM is not enabled by default +func (c *LegacyChains) SetDefault(dflt Chain) { + c.dflt = dflt +} + +func (c *LegacyChains) Default() (Chain, error) { + if c.dflt == nil { + return nil, fmt.Errorf("no default chain specified") + } + return c.dflt, nil +} + +// backward compatibility. +// eth keys are represented as multiple types in the code base; +// *big.Int, string, and int64. this lead to special 'default' handling +// of nil big.Int and empty string. +// +// TODO BCF-2507 unify the type system +func (c *LegacyChains) Get(id string) (Chain, error) { + if id == nilBigInt.String() || id == emptyString { + return c.Default() + } + return c.ChainsKV.Get(id) +} type chain struct { utils.StartStopOnce @@ -73,18 +143,53 @@ func (e errChainDisabled) Error() string { return fmt.Sprintf("cannot create new chain with ID %s, the chain is disabled", e.ChainID.String()) } -func newTOMLChain(ctx context.Context, chain *toml.EVMConfig, opts ChainSetOpts) (*chain, error) { +// TODO BCF-2509 what is this and does it need the entire app config? +type AppConfig interface { + config.AppConfig + toml.HasEVMConfigs +} + +type ChainRelayExtenderConfig struct { + Logger logger.Logger + DB *sqlx.DB + KeyStore keystore.Eth + RelayerConfig +} + +// options for the relayer factory. +// TODO BCF-2508 clean up configuration of chain and relayer after BCF-2440 +// the factory wants to own the logger and db +// the factory creates extenders, which need the same and more opts +type RelayerConfig struct { + GeneralConfig AppConfig + + EventBroadcaster pg.EventBroadcaster + MailMon *utils.MailboxMonitor + GasEstimator gas.EvmFeeEstimator + OperationalConfigs evmtypes.Configs + + // TODO BCF-2513 remove test code from the API + // Gen-functions are useful for dependency injection by tests + GenEthClient func(*big.Int) client.Client + GenLogBroadcaster func(*big.Int) log.Broadcaster + GenLogPoller func(*big.Int) logpoller.LogPoller + GenHeadTracker func(*big.Int, httypes.HeadBroadcaster) httypes.HeadTracker + GenTxManager func(*big.Int) txmgr.TxManager + GenGasEstimator func(*big.Int) gas.EvmFeeEstimator +} + +func NewTOMLChain(ctx context.Context, chain *toml.EVMConfig, opts ChainRelayExtenderConfig) (Chain, error) { chainID := chain.ChainID l := opts.Logger.With("evmChainID", chainID.String()) if !chain.IsEnabled() { return nil, errChainDisabled{ChainID: chainID} } - cfg := evmconfig.NewTOMLChainScopedConfig(opts.Config, chain, l) - // note: per-chain validation is not ncessary at this point since everything is checked earlier on boot. + cfg := evmconfig.NewTOMLChainScopedConfig(opts.GeneralConfig, chain, l) + // note: per-chain validation is not necessary at this point since everything is checked earlier on boot. return newChain(ctx, cfg, chain.Nodes, opts) } -func newChain(ctx context.Context, cfg evmconfig.ChainScopedConfig, nodes []*toml.Node, opts ChainSetOpts) (*chain, error) { +func newChain(ctx context.Context, cfg evmconfig.ChainScopedConfig, nodes []*toml.Node, opts ChainRelayExtenderConfig) (*chain, error) { chainID, chainType := cfg.EVM().ChainID(), cfg.EVM().ChainType() l := opts.Logger.Named(chainID.String()).With("evmChainID", chainID.String()) var client evmclient.Client @@ -94,7 +199,7 @@ func newChain(ctx context.Context, cfg evmconfig.ChainScopedConfig, nodes []*tom var err2 error client, err2 = newEthClientFromChain(cfg.EVM().NodePool(), cfg.EVM().NodeNoNewHeadsThreshold(), l, chainID, chainType, nodes) if err2 != nil { - return nil, errors.Wrapf(err2, "failed to instantiate eth client for chain with ID %s", cfg.EVM().ChainID().String()) + return nil, fmt.Errorf("failed to instantiate eth client for chain with ID %s: %w", cfg.EVM().ChainID().String(), err2) } } else { client = opts.GenEthClient(chainID) @@ -126,7 +231,7 @@ func newChain(ctx context.Context, cfg evmconfig.ChainScopedConfig, nodes []*tom // note: gas estimator is started as a part of the txm txm, gasEstimator, err := newEvmTxm(db, cfg.EVM(), cfg.EVMRPCEnabled(), cfg.Database(), cfg.Database().Listener(), client, l, logPoller, opts) if err != nil { - return nil, errors.Wrapf(err, "failed to instantiate EvmTxm for chain with ID %s", chainID.String()) + return nil, fmt.Errorf("failed to instantiate EvmTxm for chain with ID %s: %w", chainID.String(), err) } headBroadcaster.Subscribe(txm) @@ -182,7 +287,7 @@ func (c *chain) Start(ctx context.Context) error { // Must ensure that EthClient is dialed first because subsequent // services may make eth calls on startup if err := c.client.Dial(ctx); err != nil { - return errors.Wrap(err, "failed to dial ethclient") + return fmt.Errorf("failed to dial ethclient: %w", err) } // Services should be able to handle a non-functional eth client and // not block start in this case, instead retrying in a background loop @@ -302,3 +407,15 @@ func newPrimary(cfg evmconfig.NodePool, noNewHeadsThreshold time.Duration, lggr return evmclient.NewNode(cfg, noNewHeadsThreshold, lggr, (url.URL)(*n.WSURL), (*url.URL)(n.HTTPURL), *n.Name, id, chainID, *n.Order), nil } + +func (opts *ChainRelayExtenderConfig) Check() error { + if opts.Logger == nil { + return errors.New("logger must be non-nil") + } + if opts.GeneralConfig == nil { + return errors.New("config must be non-nil") + } + + opts.OperationalConfigs = chains.NewConfigs[utils.Big, evmtypes.Node](opts.GeneralConfig.EVMConfigs()) + return nil +} diff --git a/core/chains/evm/chain_set.go b/core/chains/evm/chain_set.go deleted file mode 100644 index edfc3e1aeb9..00000000000 --- a/core/chains/evm/chain_set.go +++ /dev/null @@ -1,325 +0,0 @@ -package evm - -import ( - "context" - "fmt" - "math/big" - "sync" - - "github.com/pkg/errors" - "go.uber.org/multierr" - "golang.org/x/exp/maps" - - "github.com/smartcontractkit/sqlx" - - relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" - - "github.com/smartcontractkit/chainlink/v2/core/chains" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/gas" - httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" - "github.com/smartcontractkit/chainlink/v2/core/config" - "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore" - "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/utils" -) - -// ErrNoChains indicates that no EVM chains have been started -var ErrNoChains = errors.New("no EVM chains loaded") - -var _ ChainSet = &chainSet{} - -//go:generate mockery --quiet --name ChainSet --output ./mocks/ --case=underscore -type ChainSet interface { - services.ServiceCtx - chains.Chains - chains.Nodes - - Get(id *big.Int) (Chain, error) - - Default() (Chain, error) - Chains() []Chain - ChainCount() int - - Configs() types.Configs - - SendTx(ctx context.Context, chainID, from, to string, amount *big.Int, balanceCheck bool) error -} - -type chainSet struct { - defaultID *big.Int - chains map[string]*chain - startedChains []Chain - chainsMu sync.RWMutex - logger logger.Logger - opts ChainSetOpts -} - -func (cll *chainSet) Start(ctx context.Context) error { - if !cll.opts.Config.EVMEnabled() { - cll.logger.Warn("EVM is disabled, no EVM-based chains will be started") - return nil - } - if !cll.opts.Config.EVMRPCEnabled() { - cll.logger.Warn("EVM RPC connections are disabled. Chainlink will not connect to any EVM RPC node.") - } - var ms services.MultiStart - for _, c := range cll.Chains() { - if err := ms.Start(ctx, c); err != nil { - return errors.Wrapf(err, "failed to start chain %q", c.ID().String()) - } - cll.startedChains = append(cll.startedChains, c) - } - evmChainIDs := make([]*big.Int, len(cll.startedChains)) - for i, c := range cll.startedChains { - evmChainIDs[i] = c.ID() - } - defChainID := "unspecified" - if cll.defaultID != nil { - defChainID = fmt.Sprintf("%q", cll.defaultID.String()) - } - cll.logger.Infow(fmt.Sprintf("EVM: Started %d/%d chains, default chain ID is %s", len(cll.startedChains), len(cll.Chains()), defChainID), "startedEvmChainIDs", evmChainIDs) - return nil -} - -func (cll *chainSet) Close() (err error) { - cll.logger.Debug("EVM: stopping") - for _, c := range cll.startedChains { - err = multierr.Combine(err, c.Close()) - } - return -} - -func (cll *chainSet) Name() string { - return cll.logger.Name() -} - -func (cll *chainSet) HealthReport() map[string]error { - report := map[string]error{} - for _, c := range cll.Chains() { - maps.Copy(report, c.HealthReport()) - } - return report -} - -func (cll *chainSet) Ready() (err error) { - for _, c := range cll.Chains() { - err = multierr.Combine(err, c.Ready()) - } - return -} - -func (cll *chainSet) Get(id *big.Int) (Chain, error) { - if id == nil { - if cll.defaultID == nil { - cll.logger.Debug("Chain ID not specified, and default is nil") - return nil, errors.New("chain ID not specified, and default is nil") - } - cll.logger.Debugf("Chain ID not specified, using default: %s", cll.defaultID.String()) - return cll.Default() - } - return cll.get(id.String()) -} - -func (cll *chainSet) get(id string) (Chain, error) { - cll.chainsMu.RLock() - defer cll.chainsMu.RUnlock() - c, exists := cll.chains[id] - if exists { - return c, nil - } - return nil, errors.Wrap(chains.ErrNotFound, fmt.Sprintf("failed to get chain with id %s", id)) -} - -func (cll *chainSet) ChainStatus(ctx context.Context, id string) (cfg relaytypes.ChainStatus, err error) { - var cs []relaytypes.ChainStatus - cs, _, err = cll.opts.Configs.Chains(0, -1, id) - if err != nil { - return - } - l := len(cs) - if l == 0 { - err = chains.ErrNotFound - return - } - if l > 1 { - err = fmt.Errorf("multiple chains found: %d", len(cs)) - return - } - cfg = cs[0] - return -} - -func (cll *chainSet) ChainStatuses(ctx context.Context, offset, limit int) ([]relaytypes.ChainStatus, int, error) { - return cll.opts.Configs.Chains(offset, limit) -} - -func (cll *chainSet) Default() (Chain, error) { - cll.chainsMu.RLock() - length := len(cll.chains) - cll.chainsMu.RUnlock() - if length == 0 { - return nil, errors.Wrap(ErrNoChains, "cannot get default EVM chain; no EVM chains are available") - } - if cll.defaultID == nil { - // This is an invariant violation; if any chains are available then a - // default should _always_ have been set in the constructor - return nil, errors.New("no default chain ID specified") - } - - return cll.Get(cll.defaultID) -} - -func (cll *chainSet) Chains() (c []Chain) { - cll.chainsMu.RLock() - defer cll.chainsMu.RUnlock() - for _, chain := range cll.chains { - c = append(c, chain) - } - return c -} - -func (cll *chainSet) ChainCount() int { - cll.chainsMu.RLock() - defer cll.chainsMu.RUnlock() - return len(cll.chains) -} - -func (cll *chainSet) Configs() types.Configs { - return cll.opts.Configs -} - -func (cll *chainSet) NodeStatuses(ctx context.Context, offset, limit int, chainIDs ...string) (nodes []relaytypes.NodeStatus, count int, err error) { - nodes, count, err = cll.opts.Configs.NodeStatusesPaged(offset, limit, chainIDs...) - if err != nil { - err = errors.Wrap(err, "GetNodesForChain failed to load nodes from DB") - return - } - for i := range nodes { - cll.addStateToNode(&nodes[i]) - } - return -} - -func (cll *chainSet) addStateToNode(n *relaytypes.NodeStatus) { - cll.chainsMu.RLock() - chain, exists := cll.chains[n.ChainID] - cll.chainsMu.RUnlock() - if !exists { - // The EVM chain is disabled - n.State = "Disabled" - return - } - states := chain.Client().NodeStates() - if states == nil { - n.State = "Unknown" - return - } - state, exists := states[n.Name] - if exists { - n.State = state - return - } - // The node is in the DB and the chain is enabled but it's not running - n.State = "NotLoaded" -} - -func (cll *chainSet) SendTx(ctx context.Context, chainID, from, to string, amount *big.Int, balanceCheck bool) error { - chain, err := cll.get(chainID) - if err != nil { - return err - } - - return chain.SendTx(ctx, from, to, amount, balanceCheck) -} - -type GeneralConfig interface { - config.AppConfig - toml.HasEVMConfigs -} - -type ChainSetOpts struct { - Config GeneralConfig - Logger logger.Logger - DB *sqlx.DB - KeyStore keystore.Eth - EventBroadcaster pg.EventBroadcaster - Configs types.Configs - MailMon *utils.MailboxMonitor - GasEstimator gas.EvmFeeEstimator - - // Gen-functions are useful for dependency injection by tests - GenEthClient func(*big.Int) client.Client - GenLogBroadcaster func(*big.Int) log.Broadcaster - GenLogPoller func(*big.Int) logpoller.LogPoller - GenHeadTracker func(*big.Int, httypes.HeadBroadcaster) httypes.HeadTracker - GenTxManager func(*big.Int) txmgr.TxManager - GenGasEstimator func(*big.Int) gas.EvmFeeEstimator -} - -// NewTOMLChainSet returns a new ChainSet from TOML configuration. -func NewTOMLChainSet(ctx context.Context, opts ChainSetOpts) (ChainSet, error) { - if err := opts.check(); err != nil { - return nil, err - } - chains := opts.Config.EVMConfigs() - var enabled []*toml.EVMConfig - for i := range chains { - if chains[i].IsEnabled() { - enabled = append(enabled, chains[i]) - } - } - opts.Logger = opts.Logger.Named("EVM") - defaultChainID := opts.Config.DefaultChainID() - if defaultChainID == nil && len(enabled) >= 1 { - defaultChainID = enabled[0].ChainID.ToInt() - if len(enabled) > 1 { - opts.Logger.Debugf("Multiple chains present, default chain: %s", defaultChainID.String()) - } - } - var err error - cll := newChainSet(opts) - cll.defaultID = defaultChainID - for i := range enabled { - cid := enabled[i].ChainID.String() - cll.logger.Infow(fmt.Sprintf("Loading chain %s", cid), "evmChainID", cid) - chain, err2 := newTOMLChain(ctx, enabled[i], opts) - if err2 != nil { - err = multierr.Combine(err, err2) - continue - } - if _, exists := cll.chains[cid]; exists { - return nil, errors.Errorf("duplicate chain with ID %s", cid) - } - cll.chains[cid] = chain - } - return cll, err -} - -func newChainSet(opts ChainSetOpts) *chainSet { - return &chainSet{ - chains: make(map[string]*chain), - startedChains: make([]Chain, 0), - logger: opts.Logger.Named("ChainSet"), - opts: opts, - } -} - -func (opts *ChainSetOpts) check() error { - if opts.Logger == nil { - return errors.New("logger must be non-nil") - } - if opts.Config == nil { - return errors.New("config must be non-nil") - } - - opts.Configs = chains.NewConfigs[utils.Big, types.Node](opts.Config.EVMConfigs()) - return nil -} diff --git a/core/chains/evm/chain_set_test.go b/core/chains/evm/chain_set_test.go deleted file mode 100644 index 2c7de3c62b3..00000000000 --- a/core/chains/evm/chain_set_test.go +++ /dev/null @@ -1,61 +0,0 @@ -package evm_test - -import ( - "math/big" - "testing" - - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" - - "github.com/smartcontractkit/chainlink/v2/core/chains/evm" - evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" - evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" - "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" - configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" - "github.com/smartcontractkit/chainlink/v2/core/utils" -) - -func TestChainSet(t *testing.T) { - t.Parallel() - - newId := testutils.NewRandomEVMChainID() - cfg := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { - one := uint32(1) - c.EVM[0].MinIncomingConfirmations = &one - t := true - c.EVM = append(c.EVM, &toml.EVMConfig{ChainID: utils.NewBig(newId), Enabled: &t, Chain: toml.Defaults(nil)}) - }) - db := pgtest.NewSqlxDB(t) - kst := cltest.NewKeyStore(t, db, cfg.Database()) - require.NoError(t, kst.Unlock(cltest.Password)) - - opts := evmtest.NewChainSetOpts(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), GeneralConfig: cfg}) - opts.GenEthClient = func(*big.Int) evmclient.Client { - return cltest.NewEthMocksWithStartupAssertions(t) - } - chainSet, err := evm.NewTOMLChainSet(testutils.Context(t), opts) - require.NoError(t, err) - - require.NoError(t, chainSet.Start(testutils.Context(t))) - require.NoError(t, chainSet.Chains()[0].Ready()) - - chains := chainSet.Chains() - require.Equal(t, 2, len(chains)) - require.NotEqual(t, chains[0].ID().String(), chains[1].ID().String()) - - assert.NoError(t, chains[0].Ready()) - assert.NoError(t, chains[1].Ready()) - - chainSet.Close() - - chains[0].Client().(*evmclimocks.Client).AssertCalled(t, "Close") - chains[1].Client().(*evmclimocks.Client).AssertCalled(t, "Close") - - assert.Error(t, chains[0].Ready()) - assert.Error(t, chains[1].Ready()) -} diff --git a/core/chains/evm/config/chain_scoped.go b/core/chains/evm/config/chain_scoped.go index 00ed4e328c9..260043ba252 100644 --- a/core/chains/evm/config/chain_scoped.go +++ b/core/chains/evm/config/chain_scoped.go @@ -15,8 +15,11 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" ) -func NewTOMLChainScopedConfig(genCfg gencfg.AppConfig, chain *toml.EVMConfig, lggr logger.Logger) *ChainScoped { - return &ChainScoped{AppConfig: genCfg, cfg: chain, lggr: lggr} +func NewTOMLChainScopedConfig(genCfg gencfg.AppConfig, tomlConfig *toml.EVMConfig, lggr logger.Logger) *ChainScoped { + return &ChainScoped{ + AppConfig: genCfg, + evmConfig: &evmConfig{c: tomlConfig}, + lggr: lggr} } // ChainScoped implements config.ChainScopedConfig with a gencfg.BasicConfig and EVMConfig. @@ -24,7 +27,15 @@ type ChainScoped struct { gencfg.AppConfig lggr logger.Logger - cfg *toml.EVMConfig + evmConfig *evmConfig +} + +func (c *ChainScoped) EVM() EVM { + return c.evmConfig +} + +func (c *ChainScoped) BlockEmissionIdleWarningThreshold() time.Duration { + return c.EVM().NodeNoNewHeadsThreshold() } func (c *ChainScoped) Validate() (err error) { @@ -140,14 +151,6 @@ func (e *evmConfig) NodeNoNewHeadsThreshold() time.Duration { return e.c.NoNewHeadsThreshold.Duration() } -func (c *ChainScoped) EVM() EVM { - return &evmConfig{c: c.cfg} -} - -func (c *ChainScoped) BlockEmissionIdleWarningThreshold() time.Duration { - return c.EVM().NodeNoNewHeadsThreshold() -} - func (e *evmConfig) MinContractPayment() *assets.Link { return e.c.MinContractPayment } diff --git a/core/chains/evm/config/config.go b/core/chains/evm/config/config.go index c0873682af4..05c65a8f997 100644 --- a/core/chains/evm/config/config.go +++ b/core/chains/evm/config/config.go @@ -124,6 +124,8 @@ type NodePool interface { SyncThreshold() uint32 } +// TODO BCF-2509 does the chainscopedconfig really need the entire app config? +// //go:generate mockery --quiet --name ChainScopedConfig --output ./mocks/ --case=underscore type ChainScopedConfig interface { config.AppConfig diff --git a/core/chains/evm/evm_txm.go b/core/chains/evm/evm_txm.go index 23d109c971d..d2f4178c7d9 100644 --- a/core/chains/evm/evm_txm.go +++ b/core/chains/evm/evm_txm.go @@ -22,7 +22,7 @@ func newEvmTxm( client evmclient.Client, lggr logger.Logger, logPoller logpoller.LogPoller, - opts ChainSetOpts, + opts ChainRelayExtenderConfig, ) (txm txmgr.TxManager, estimator gas.EvmFeeEstimator, err error, diff --git a/core/chains/evm/log/helpers_test.go b/core/chains/evm/log/helpers_test.go index b094c2884da..d55a44373f2 100644 --- a/core/chains/evm/log/helpers_test.go +++ b/core/chains/evm/log/helpers_test.go @@ -39,6 +39,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -112,7 +113,7 @@ func (c broadcasterHelperCfg) newWithEthClient(t *testing.T, ethClient evmclient lb := log.NewTestBroadcaster(orm, ethClient, config.EVM(), lggr, c.highestSeenHead, mailMon) kst := cltest.NewKeyStore(t, c.db, globalConfig.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{ + cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{ Client: ethClient, GeneralConfig: globalConfig, DB: c.db, @@ -120,8 +121,8 @@ func (c broadcasterHelperCfg) newWithEthClient(t *testing.T, ethClient evmclient LogBroadcaster: &log.NullBroadcaster{}, MailMon: mailMon, }) - - pipelineHelper := cltest.NewJobPipelineV2(t, config.WebServer(), config.JobPipeline(), config.Database(), cc, c.db, kst, nil, nil) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + pipelineHelper := cltest.NewJobPipelineV2(t, config.WebServer(), config.JobPipeline(), config.Database(), legacyChains, c.db, kst, nil, nil) return &broadcasterHelper{ t: t, diff --git a/core/chains/evm/mocks/legacy_chain_container.go b/core/chains/evm/mocks/legacy_chain_container.go new file mode 100644 index 00000000000..fe906234f16 --- /dev/null +++ b/core/chains/evm/mocks/legacy_chain_container.go @@ -0,0 +1,165 @@ +// Code generated by mockery v2.28.1. DO NOT EDIT. + +package mocks + +import ( + evm "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + mock "github.com/stretchr/testify/mock" + + types "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" +) + +// LegacyChainContainer is an autogenerated mock type for the LegacyChainContainer type +type LegacyChainContainer struct { + mock.Mock +} + +// ChainNodeConfigs provides a mock function with given fields: +func (_m *LegacyChainContainer) ChainNodeConfigs() types.Configs { + ret := _m.Called() + + var r0 types.Configs + if rf, ok := ret.Get(0).(func() types.Configs); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(types.Configs) + } + } + + return r0 +} + +// Default provides a mock function with given fields: +func (_m *LegacyChainContainer) Default() (evm.Chain, error) { + ret := _m.Called() + + var r0 evm.Chain + var r1 error + if rf, ok := ret.Get(0).(func() (evm.Chain, error)); ok { + return rf() + } + if rf, ok := ret.Get(0).(func() evm.Chain); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(evm.Chain) + } + } + + if rf, ok := ret.Get(1).(func() error); ok { + r1 = rf() + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// Get provides a mock function with given fields: id +func (_m *LegacyChainContainer) Get(id string) (evm.Chain, error) { + ret := _m.Called(id) + + var r0 evm.Chain + var r1 error + if rf, ok := ret.Get(0).(func(string) (evm.Chain, error)); ok { + return rf(id) + } + if rf, ok := ret.Get(0).(func(string) evm.Chain); ok { + r0 = rf(id) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(evm.Chain) + } + } + + if rf, ok := ret.Get(1).(func(string) error); ok { + r1 = rf(id) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// Len provides a mock function with given fields: +func (_m *LegacyChainContainer) Len() int { + ret := _m.Called() + + var r0 int + if rf, ok := ret.Get(0).(func() int); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(int) + } + + return r0 +} + +// List provides a mock function with given fields: ids +func (_m *LegacyChainContainer) List(ids ...string) ([]evm.Chain, error) { + _va := make([]interface{}, len(ids)) + for _i := range ids { + _va[_i] = ids[_i] + } + var _ca []interface{} + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 []evm.Chain + var r1 error + if rf, ok := ret.Get(0).(func(...string) ([]evm.Chain, error)); ok { + return rf(ids...) + } + if rf, ok := ret.Get(0).(func(...string) []evm.Chain); ok { + r0 = rf(ids...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]evm.Chain) + } + } + + if rf, ok := ret.Get(1).(func(...string) error); ok { + r1 = rf(ids...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// SetDefault provides a mock function with given fields: _a0 +func (_m *LegacyChainContainer) SetDefault(_a0 evm.Chain) { + _m.Called(_a0) +} + +// Slice provides a mock function with given fields: +func (_m *LegacyChainContainer) Slice() []evm.Chain { + ret := _m.Called() + + var r0 []evm.Chain + if rf, ok := ret.Get(0).(func() []evm.Chain); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]evm.Chain) + } + } + + return r0 +} + +type mockConstructorTestingTNewLegacyChainContainer interface { + mock.TestingT + Cleanup(func()) +} + +// NewLegacyChainContainer creates a new instance of LegacyChainContainer. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +func NewLegacyChainContainer(t mockConstructorTestingTNewLegacyChainContainer) *LegacyChainContainer { + mock := &LegacyChainContainer{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/core/cmd/cosmos_transaction_commands_test.go b/core/cmd/cosmos_transaction_commands_test.go index a736a96050e..593747c6f18 100644 --- a/core/cmd/cosmos_transaction_commands_test.go +++ b/core/cmd/cosmos_transaction_commands_test.go @@ -18,9 +18,9 @@ import ( coscfg "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/config" cosmosdb "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/db" "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/denom" + "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/params" "github.com/smartcontractkit/chainlink-relay/pkg/utils" - "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/params" "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos/cosmostxm" "github.com/smartcontractkit/chainlink/v2/core/cmd" @@ -33,10 +33,12 @@ import ( ) func TestMain(m *testing.M) { + params.InitCosmosSdk( /* bech32Prefix= */ "wasm", /* token= */ "atom", ) + code := m.Run() os.Exit(code) } @@ -60,7 +62,7 @@ func TestShell_SendCosmosCoins(t *testing.T) { from := accounts[0] to := accounts[1] require.NoError(t, app.GetKeyStore().Cosmos().Add(cosmoskey.Raw(from.PrivateKey.Bytes()).Key())) - chain, err := app.GetChains().Cosmos.Chain(testutils.Context(t), chainID) + chain, err := app.GetRelayers().LegacyCosmosChains().Get(chainID) require.NoError(t, err) reader, err := chain.Reader("") diff --git a/core/cmd/helpers_test.go b/core/cmd/helpers_test.go index 1a79deaa928..460576ce6a2 100644 --- a/core/cmd/helpers_test.go +++ b/core/cmd/helpers_test.go @@ -11,5 +11,3 @@ func (s *Shell) CheckRemoteBuildCompatibility(lggr logger.Logger, onlyWarn bool, func (s *Shell) ConfigV2Str(userOnly bool) (string, error) { return s.configV2Str(userOnly) } - -type RelayerFactory = relayerFactory diff --git a/core/cmd/ocr2vrf_configure_commands.go b/core/cmd/ocr2vrf_configure_commands.go index 590776135e1..01bfd89c32b 100644 --- a/core/cmd/ocr2vrf_configure_commands.go +++ b/core/cmd/ocr2vrf_configure_commands.go @@ -338,7 +338,11 @@ func setupKeystore(cli *Shell, app chainlink.Application, keyStore keystore.Mast } if cli.Config.EVMEnabled() { - for _, ch := range app.GetChains().EVM.Chains() { + chains, err := app.GetRelayers().LegacyEVMChains().List() + if err != nil { + return fmt.Errorf("failed to get legacy evm chains") + } + for _, ch := range chains { if err = keyStore.Eth().EnsureKeys(ch.ID()); err != nil { return errors.Wrap(err, "failed to ensure keystore keys") } diff --git a/core/cmd/shell.go b/core/cmd/shell.go index 514450ad99c..2ddc312b17a 100644 --- a/core/cmd/shell.go +++ b/core/cmd/shell.go @@ -23,7 +23,6 @@ import ( "github.com/Masterminds/semver/v3" "github.com/getsentry/sentry-go" "github.com/gin-gonic/gin" - "github.com/pelletier/go-toml/v2" "github.com/pkg/errors" "github.com/urfave/cli" "go.uber.org/multierr" @@ -33,15 +32,9 @@ import ( "github.com/smartcontractkit/sqlx" "github.com/smartcontractkit/chainlink-relay/pkg/loop" - pkgsolana "github.com/smartcontractkit/chainlink-solana/pkg/solana" - pkgstarknet "github.com/smartcontractkit/chainlink-starknet/relayer/pkg/chainlink" "github.com/smartcontractkit/chainlink/v2/core/build" - "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" - "github.com/smartcontractkit/chainlink/v2/core/chains/solana" - "github.com/smartcontractkit/chainlink/v2/core/chains/starknet" "github.com/smartcontractkit/chainlink/v2/core/config" - "github.com/smartcontractkit/chainlink/v2/core/config/env" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" "github.com/smartcontractkit/chainlink/v2/core/services" @@ -49,7 +42,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/periodicbackup" "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/services/versioning" "github.com/smartcontractkit/chainlink/v2/core/services/webhook" "github.com/smartcontractkit/chainlink/v2/core/sessions" @@ -145,62 +137,52 @@ func (n ChainlinkAppFactory) NewApplication(ctx context.Context, cfg chainlink.G dbListener := cfg.Database().Listener() eventBroadcaster := pg.NewEventBroadcaster(cfg.Database().URL(), dbListener.MinReconnectInterval(), dbListener.MaxReconnectDuration(), appLggr, cfg.AppID()) - ccOpts := evm.ChainSetOpts{ - Config: cfg, - Logger: appLggr, - DB: db, - KeyStore: keyStore.Eth(), - EventBroadcaster: eventBroadcaster, - MailMon: mailMon, - } - loopRegistry := plugins.NewLoopRegistry(appLggr.Named("LoopRegistry")) - var chains chainlink.Chains - chains.EVM, err = evm.NewTOMLChainSet(ctx, ccOpts) - if err != nil { - return nil, errors.Wrap(err, "failed to load EVM chainset") + // create the relayer-chain interoperators from application configuration + relayerFactory := chainlink.RelayerFactory{ + Logger: appLggr, + DB: db, + QConfig: cfg.Database(), + LoopRegistry: loopRegistry, + GRPCOpts: grpcOpts, } + evmFactoryCfg := chainlink.EVMFactoryConfig{ + RelayerConfig: evm.RelayerConfig{GeneralConfig: cfg, EventBroadcaster: eventBroadcaster, MailMon: mailMon}, + CSAETHKeystore: keyStore, + } + // evm always enabled for backward compatibility + // TODO BCF-2510 this needs to change in order to clear the path for EVM extraction + initOps := []chainlink.CoreRelayerChainInitFunc{chainlink.InitEVM(ctx, relayerFactory, evmFactoryCfg)} + if cfg.CosmosEnabled() { - cosmosLggr := appLggr.Named("Cosmos") - opts := cosmos.ChainSetOpts{ - Config: cfg, - Logger: cosmosLggr, - DB: db, - KeyStore: keyStore.Cosmos(), + cosmosCfg := chainlink.CosmosFactoryConfig{ + Keystore: keyStore.Cosmos(), + CosmosConfigs: cfg.CosmosConfigs(), EventBroadcaster: eventBroadcaster, } - cfgs := cfg.CosmosConfigs() - opts.Configs = cosmos.NewConfigs(cfgs) - chains.Cosmos, err = cosmos.NewChainSet(opts, cfgs) - if err != nil { - return nil, errors.Wrap(err, "failed to load Cosmos chainset") - } - } - - rf := relayerFactory{ - Logger: appLggr, - DB: db, - GeneralConfig: cfg, - LoopRegistry: loopRegistry, - GRPCOpts: grpcOpts, + initOps = append(initOps, chainlink.InitCosmos(ctx, relayerFactory, cosmosCfg)) } - if cfg.SolanaEnabled() { - var err2 error - chains.Solana, err2 = rf.NewSolana(keyStore.Solana()) - if err2 != nil { - return nil, fmt.Errorf("failed to setup Solana relayer: %w", err2) + solanaCfg := chainlink.SolanaFactoryConfig{ + Keystore: keyStore.Solana(), + SolanaConfigs: cfg.SolanaConfigs(), } + initOps = append(initOps, chainlink.InitSolana(ctx, relayerFactory, solanaCfg)) } - if cfg.StarkNetEnabled() { - var err2 error - chains.StarkNet, err2 = rf.NewStarkNet(keyStore.StarkNet()) - if err2 != nil { - return nil, fmt.Errorf("failed to setup StarkNet relayer: %w", err2) + starkCfg := chainlink.StarkNetFactoryConfig{ + Keystore: keyStore.StarkNet(), + StarknetConfigs: cfg.StarknetConfigs(), } + initOps = append(initOps, chainlink.InitStarknet(ctx, relayerFactory, starkCfg)) + + } + + relayChainInterops, err := chainlink.NewCoreRelayerChainInteroperators(initOps...) + if err != nil { + return nil, err } // Configure and optionally start the audit log forwarder service @@ -213,127 +195,24 @@ func (n ChainlinkAppFactory) NewApplication(ctx context.Context, cfg chainlink.G unrestrictedClient := clhttp.NewUnrestrictedHTTPClient() externalInitiatorManager := webhook.NewExternalInitiatorManager(db, unrestrictedClient, appLggr, cfg.Database()) return chainlink.NewApplication(chainlink.ApplicationOpts{ - Config: cfg, - SqlxDB: db, - KeyStore: keyStore, - Chains: chains, - EventBroadcaster: eventBroadcaster, - MailMon: mailMon, - Logger: appLggr, - AuditLogger: auditLogger, - ExternalInitiatorManager: externalInitiatorManager, - Version: static.Version, - RestrictedHTTPClient: restrictedClient, - UnrestrictedHTTPClient: unrestrictedClient, - SecretGenerator: chainlink.FilePersistedSecretGenerator{}, - LoopRegistry: loopRegistry, - GRPCOpts: grpcOpts, + Config: cfg, + SqlxDB: db, + KeyStore: keyStore, + RelayerChainInteroperators: relayChainInterops, + EventBroadcaster: eventBroadcaster, + MailMon: mailMon, + Logger: appLggr, + AuditLogger: auditLogger, + ExternalInitiatorManager: externalInitiatorManager, + Version: static.Version, + RestrictedHTTPClient: restrictedClient, + UnrestrictedHTTPClient: unrestrictedClient, + SecretGenerator: chainlink.FilePersistedSecretGenerator{}, + LoopRegistry: loopRegistry, + GRPCOpts: grpcOpts, }) } -type relayerFactory struct { - logger.Logger - *sqlx.DB - chainlink.GeneralConfig - *plugins.LoopRegistry - loop.GRPCOpts -} - -func (r relayerFactory) NewSolana(ks keystore.Solana) (loop.Relayer, error) { - var ( - solanaRelayer loop.Relayer - ids []string - solLggr = r.Logger.Named("Solana") - cfgs = r.SolanaConfigs() - signer = &keystore.SolanaSigner{ks} - ) - for _, c := range cfgs { - c := c - ids = append(ids, *c.ChainID) - } - - if cmdName := env.SolanaPluginCmd.Get(); cmdName != "" { - // setup the solana relayer to be a LOOP - tomls, err := toml.Marshal(struct { - Solana solana.SolanaConfigs - }{Solana: cfgs}) - if err != nil { - return nil, fmt.Errorf("failed to marshal Solana configs: %w", err) - } - - solCmdFn, err := plugins.NewCmdFactory(r.Register, plugins.CmdConfig{ - ID: solLggr.Name(), - Cmd: cmdName, - }) - if err != nil { - return nil, fmt.Errorf("failed to create Solana LOOP command: %w", err) - } - solanaRelayer = loop.NewRelayerService(solLggr, r.GRPCOpts, solCmdFn, string(tomls), signer) - } else { - // fallback to embedded chainset - opts := solana.ChainSetOpts{ - Logger: solLggr, - KeyStore: signer, - Configs: solana.NewConfigs(cfgs), - } - chainSet, err := solana.NewChainSet(opts, cfgs) - if err != nil { - return nil, fmt.Errorf("failed to load Solana chainset: %w", err) - } - solanaRelayer = relay.NewRelayerAdapter(pkgsolana.NewRelayer(solLggr, chainSet), chainSet) - } - return solanaRelayer, nil -} - -func (r relayerFactory) NewStarkNet(ks keystore.StarkNet) (loop.Relayer, error) { - var ( - starknetRelayer loop.Relayer - ids []string - starkLggr = r.Logger.Named("StarkNet") - cfgs = r.StarknetConfigs() - loopKs = &keystore.StarknetLooppSigner{StarkNet: ks} - ) - for _, c := range cfgs { - c := c - ids = append(ids, *c.ChainID) - } - - if cmdName := env.StarknetPluginCmd.Get(); cmdName != "" { - // setup the starknet relayer to be a LOOP - tomls, err := toml.Marshal(struct { - Starknet starknet.StarknetConfigs - }{Starknet: cfgs}) - if err != nil { - return nil, fmt.Errorf("failed to marshal StarkNet configs: %w", err) - } - - starknetCmdFn, err := plugins.NewCmdFactory(r.Register, plugins.CmdConfig{ - ID: starkLggr.Name(), - Cmd: cmdName, - }) - if err != nil { - return nil, fmt.Errorf("failed to create StarkNet LOOP command: %w", err) - } - // the starknet relayer service has a delicate keystore dependency. the value that is passed to NewRelayerService must - // be compatible with instantiating a starknet transaction manager KeystoreAdapter within the LOOPp executable. - starknetRelayer = loop.NewRelayerService(starkLggr, r.GRPCOpts, starknetCmdFn, string(tomls), loopKs) - } else { - // fallback to embedded chainset - opts := starknet.ChainSetOpts{ - Logger: starkLggr, - KeyStore: loopKs, - Configs: starknet.NewConfigs(cfgs), - } - chainSet, err := starknet.NewChainSet(opts, cfgs) - if err != nil { - return nil, fmt.Errorf("failed to load StarkNet chainset: %w", err) - } - starknetRelayer = relay.NewRelayerAdapter(pkgstarknet.NewRelayer(starkLggr, chainSet), chainSet) - } - return starknetRelayer, nil - -} - // handleNodeVersioning is a setup-time helper to encapsulate version changes and db migration func handleNodeVersioning(db *sqlx.DB, appLggr logger.Logger, rootDir string, cfg config.Database, healthReportPort uint16) error { var err error diff --git a/core/cmd/shell_local.go b/core/cmd/shell_local.go index 4e0b97c894f..5d4eacb27ae 100644 --- a/core/cmd/shell_local.go +++ b/core/cmd/shell_local.go @@ -370,12 +370,13 @@ func (s *Shell) runNode(c *cli.Context) error { return errors.Wrap(err, "error authenticating keystore") } - evmChainSet := app.GetChains().EVM + legacyEVMChains := app.GetRelayers().LegacyEVMChains() + // By passing in a function we can be lazy trying to look up a default // chain - if there are no existing keys, there is no need to check for // a chain ID DefaultEVMChainIDFunc := func() (*big.Int, error) { - def, err2 := evmChainSet.Default() + def, err2 := legacyEVMChains.Default() if err2 != nil { return nil, errors.Wrap(err2, "cannot get default EVM chain ID; no default EVM chain available") } @@ -387,8 +388,11 @@ func (s *Shell) runNode(c *cli.Context) error { if err != nil { return errors.Wrap(err, "error migrating keystore") } - - for _, ch := range evmChainSet.Chains() { + chainList, err := legacyEVMChains.List() + if err != nil { + return fmt.Errorf("error listing legacy evm chains: %w", err) + } + for _, ch := range chainList { if ch.Config().EVM().AutoCreateKey() { lggr.Debugf("AutoCreateKey=true, will ensure EVM key for chain %s", ch.ID()) err2 := app.GetKeyStore().Eth().EnsureKeys(ch.ID()) @@ -604,7 +608,10 @@ func (s *Shell) RebroadcastTransactions(c *cli.Context) (err error) { return s.errorOut(errors.Wrap(err, "fatal error instantiating application")) } - chain, err := app.GetChains().EVM.Get(chainID) + // TODO: BCF-2511 once the dust settles on BCF-2440/1 evaluate how the + // [loop.Relayer] interface needs to be extended to support programming similar to + // this pattern but in a chain-agnostic way + chain, err := app.GetRelayers().LegacyEVMChains().Get(chainID.String()) if err != nil { return s.errorOut(err) } diff --git a/core/cmd/shell_local_test.go b/core/cmd/shell_local_test.go index ba0839c6e96..46062637633 100644 --- a/core/cmd/shell_local_test.go +++ b/core/cmd/shell_local_test.go @@ -9,21 +9,27 @@ import ( "time" clienttypes "github.com/smartcontractkit/chainlink/v2/common/chains/client" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/cmd" cmdMocks "github.com/smartcontractkit/chainlink/v2/core/cmd/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest/heavyweight" "github.com/smartcontractkit/chainlink/v2/core/internal/mocks" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + chainlinkmocks "github.com/smartcontractkit/chainlink/v2/core/services/chainlink/mocks" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" + evmrelayer "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/sessions" "github.com/smartcontractkit/chainlink/v2/core/store/dialects" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" + "github.com/smartcontractkit/chainlink/v2/plugins" gethTypes "github.com/ethereum/go-ethereum/core/types" "github.com/google/uuid" @@ -33,6 +39,25 @@ import ( "github.com/urfave/cli" ) +func genTestEVMRelayers(t *testing.T, opts evm.ChainRelayExtenderConfig, ks evmrelayer.CSAETHKeystore) *chainlink.CoreRelayerChainInteroperators { + f := chainlink.RelayerFactory{ + Logger: opts.Logger, + DB: opts.DB, + QConfig: opts.GeneralConfig.Database(), + LoopRegistry: plugins.NewLoopRegistry(opts.Logger), + } + + relayers, err := chainlink.NewCoreRelayerChainInteroperators(chainlink.InitEVM(testutils.Context(t), f, chainlink.EVMFactoryConfig{ + RelayerConfig: opts.RelayerConfig, + CSAETHKeystore: ks, + })) + if err != nil { + t.Fatal(err) + } + return relayers + +} + func TestShell_RunNodeWithPasswords(t *testing.T) { tests := []struct { name string @@ -50,11 +75,28 @@ func TestShell_RunNodeWithPasswords(t *testing.T) { s.Password.Keystore = models.NewSecret("dummy") c.EVM[0].Nodes[0].Name = ptr("fake") c.EVM[0].Nodes[0].HTTPURL = models.MustParseURL("http://fake.com") + c.EVM[0].Nodes[0].WSURL = models.MustParseURL("WSS://fake.com/ws") + // seems to be needed for config validate + c.Insecure.OCRDevelopmentMode = nil }) db := pgtest.NewSqlxDB(t) keyStore := cltest.NewKeyStore(t, db, cfg.Database()) sessionORM := sessions.NewORM(db, time.Minute, logger.TestLogger(t), cfg.Database(), audit.NoopLogger) + lggr := logger.TestLogger(t) + + opts := evm.ChainRelayExtenderConfig{ + Logger: lggr, + DB: db, + KeyStore: keyStore.Eth(), + RelayerConfig: evm.RelayerConfig{ + GeneralConfig: cfg, + EventBroadcaster: pg.NewNullEventBroadcaster(), + MailMon: &utils.MailboxMonitor{}, + }, + } + testRelayers := genTestEVMRelayers(t, opts, keyStore) + // Purge the fixture users to test assumption of single admin // initialUser user created above pgtest.MustExec(t, db, "DELETE FROM users;") @@ -62,7 +104,7 @@ func TestShell_RunNodeWithPasswords(t *testing.T) { app := mocks.NewApplication(t) app.On("SessionORM").Return(sessionORM).Maybe() app.On("GetKeyStore").Return(keyStore).Maybe() - app.On("GetChains").Return(chainlink.Chains{EVM: cltest.NewChainSetMockWithOneChain(t, evmtest.NewEthClientMock(t), evmtest.NewChainScopedConfig(t, cfg))}).Maybe() + app.On("GetRelayers").Return(testRelayers).Maybe() app.On("Start", mock.Anything).Maybe().Return(nil) app.On("Stop").Maybe().Return(nil) app.On("ID").Maybe().Return(uuid.New()) @@ -73,7 +115,6 @@ func TestShell_RunNodeWithPasswords(t *testing.T) { cltest.MustInsertRandomKey(t, keyStore.Eth()) apiPrompt := cltest.NewMockAPIInitializer(t) - lggr := logger.TestLogger(t) client := cmd.Shell{ Config: cfg, @@ -131,6 +172,8 @@ func TestShell_RunNodeWithAPICredentialsFile(t *testing.T) { c.EVM[0].Nodes[0].Name = ptr("fake") c.EVM[0].Nodes[0].WSURL = models.MustParseURL("WSS://fake.com/ws") c.EVM[0].Nodes[0].HTTPURL = models.MustParseURL("http://fake.com") + // seems to be needed for config validate + c.Insecure.OCRDevelopmentMode = nil }) db := pgtest.NewSqlxDB(t) sessionORM := sessions.NewORM(db, time.Minute, logger.TestLogger(t), cfg.Database(), audit.NoopLogger) @@ -148,10 +191,23 @@ func TestShell_RunNodeWithAPICredentialsFile(t *testing.T) { ethClient.On("Dial", mock.Anything).Return(nil).Maybe() ethClient.On("BalanceAt", mock.Anything, mock.Anything, mock.Anything).Return(big.NewInt(10), nil).Maybe() + lggr := logger.TestLogger(t) + opts := evm.ChainRelayExtenderConfig{ + Logger: lggr, + DB: db, + KeyStore: keyStore.Eth(), + RelayerConfig: evm.RelayerConfig{ + GeneralConfig: cfg, + EventBroadcaster: pg.NewNullEventBroadcaster(), + + MailMon: &utils.MailboxMonitor{}, + }, + } + testRelayers := genTestEVMRelayers(t, opts, keyStore) app := mocks.NewApplication(t) app.On("SessionORM").Return(sessionORM) app.On("GetKeyStore").Return(keyStore) - app.On("GetChains").Return(chainlink.Chains{EVM: cltest.NewChainSetMockWithOneChain(t, ethClient, evmtest.NewChainScopedConfig(t, cfg))}).Maybe() + app.On("GetRelayers").Return(testRelayers).Maybe() app.On("Start", mock.Anything).Maybe().Return(nil) app.On("Stop").Maybe().Return(nil) app.On("ID").Maybe().Return(uuid.New()) @@ -159,7 +215,6 @@ func TestShell_RunNodeWithAPICredentialsFile(t *testing.T) { prompter := cmdMocks.NewPrompter(t) apiPrompt := cltest.NewMockAPIInitializer(t) - lggr := logger.TestLogger(t) client := cmd.Shell{ Config: cfg, @@ -235,22 +290,28 @@ func TestShell_RebroadcastTransactions_Txm(t *testing.T) { // evm config is used in this test. but if set, it must be pass config validation. // simplest to make it nil c.EVM = nil + // seems to be needed for config validate + c.Insecure.OCRDevelopmentMode = nil }) keyStore := cltest.NewKeyStore(t, sqlxDB, config.Database()) - _, fromAddress := cltest.MustInsertRandomKey(t, keyStore.Eth(), 0) + _, fromAddress := cltest.MustInsertRandomKey(t, keyStore.Eth()) txStore := cltest.NewTestTxStore(t, sqlxDB, config.Database()) cltest.MustInsertConfirmedEthTxWithLegacyAttempt(t, txStore, 7, 42, fromAddress) + lggr := logger.TestLogger(t) + app := mocks.NewApplication(t) app.On("GetSqlxDB").Return(sqlxDB) app.On("GetKeyStore").Return(keyStore) app.On("ID").Maybe().Return(uuid.New()) ethClient := evmtest.NewEthClientMockWithDefaultChain(t) - app.On("GetChains").Return(chainlink.Chains{EVM: cltest.NewChainSetMockWithOneChain(t, ethClient, evmtest.NewChainScopedConfig(t, config))}).Maybe() - ethClient.On("Dial", mock.Anything).Return(nil) + legacy := cltest.NewLegacyChainsWithMockChain(t, ethClient, config) - lggr := logger.TestLogger(t) + mockRelayerChainInteroperators := chainlinkmocks.NewRelayerChainInteroperators(t) + mockRelayerChainInteroperators.On("LegacyEVMChains").Return(legacy, nil) + app.On("GetRelayers").Return(mockRelayerChainInteroperators).Maybe() + ethClient.On("Dial", mock.Anything).Return(nil) client := cmd.Shell{ Config: config, @@ -308,6 +369,8 @@ func TestShell_RebroadcastTransactions_OutsideRange_Txm(t *testing.T) { // evm config is used in this test. but if set, it must be pass config validation. // simplest to make it nil c.EVM = nil + // seems to be needed for config validate + c.Insecure.OCRDevelopmentMode = nil }) keyStore := cltest.NewKeyStore(t, sqlxDB, config.Database()) @@ -317,15 +380,19 @@ func TestShell_RebroadcastTransactions_OutsideRange_Txm(t *testing.T) { txStore := cltest.NewTestTxStore(t, sqlxDB, config.Database()) cltest.MustInsertConfirmedEthTxWithLegacyAttempt(t, txStore, int64(test.nonce), 42, fromAddress) + lggr := logger.TestLogger(t) + app := mocks.NewApplication(t) app.On("GetSqlxDB").Return(sqlxDB) app.On("GetKeyStore").Return(keyStore) app.On("ID").Maybe().Return(uuid.New()) ethClient := evmtest.NewEthClientMockWithDefaultChain(t) ethClient.On("Dial", mock.Anything).Return(nil) - app.On("GetChains").Return(chainlink.Chains{EVM: cltest.NewChainSetMockWithOneChain(t, ethClient, evmtest.NewChainScopedConfig(t, config))}).Maybe() + legacy := cltest.NewLegacyChainsWithMockChain(t, ethClient, config) - lggr := logger.TestLogger(t) + mockRelayerChainInteroperators := chainlinkmocks.NewRelayerChainInteroperators(t) + mockRelayerChainInteroperators.On("LegacyEVMChains").Return(legacy, nil) + app.On("GetRelayers").Return(mockRelayerChainInteroperators).Maybe() client := cmd.Shell{ Config: config, @@ -377,7 +444,10 @@ func TestShell_RebroadcastTransactions_AddressCheck(t *testing.T) { config, sqlxDB := heavyweight.FullTestDBV2(t, "rebroadcasttransactions_outsiderange", func(c *chainlink.Config, s *chainlink.Secrets) { c.Database.Dialect = dialects.Postgres + c.EVM = nil + // seems to be needed for config validate + c.Insecure.OCRDevelopmentMode = nil }) keyStore := cltest.NewKeyStore(t, sqlxDB, config.Database()) @@ -385,22 +455,25 @@ func TestShell_RebroadcastTransactions_AddressCheck(t *testing.T) { _, fromAddress := cltest.MustInsertRandomKey(t, keyStore.Eth(), 0) if !test.enableAddress { - err := keyStore.Eth().Disable(fromAddress, big.NewInt(0)) - require.NoError(t, err) + err := keyStore.Eth().Disable(fromAddress, testutils.FixtureChainID) + require.NoError(t, err, "failed to disable test key") } + lggr := logger.TestLogger(t) + app := mocks.NewApplication(t) app.On("GetSqlxDB").Maybe().Return(sqlxDB) app.On("GetKeyStore").Return(keyStore) app.On("ID").Maybe().Return(uuid.New()) ethClient := evmtest.NewEthClientMockWithDefaultChain(t) ethClient.On("Dial", mock.Anything).Return(nil) - app.On("GetChains").Return(chainlink.Chains{EVM: cltest.NewChainSetMockWithOneChain(t, ethClient, evmtest.NewChainScopedConfig(t, config))}).Maybe() + legacy := cltest.NewLegacyChainsWithMockChain(t, ethClient, config) + mockRelayerChainInteroperators := chainlinkmocks.NewRelayerChainInteroperators(t) + mockRelayerChainInteroperators.On("LegacyEVMChains").Return(legacy, nil) + app.On("GetRelayers").Return(mockRelayerChainInteroperators).Maybe() ethClient.On("SendTransactionReturnCode", mock.Anything, mock.Anything, mock.Anything).Maybe().Return(clienttypes.Successful, nil) - lggr := logger.TestLogger(t) - client := cmd.Shell{ Config: config, AppFactory: cltest.InstanceAppFactory{App: app}, @@ -410,6 +483,7 @@ func TestShell_RebroadcastTransactions_AddressCheck(t *testing.T) { } set := flag.NewFlagSet("test", 0) + set.Set("evmChainID", testutils.SimulatedChainID.String()) cltest.FlagSetApplyFromAction(client.RebroadcastTransactions, set, "") require.NoError(t, set.Set("address", fromAddress.Hex())) diff --git a/core/cmd/shell_test.go b/core/cmd/shell_test.go index b371156e9de..733c0058f37 100644 --- a/core/cmd/shell_test.go +++ b/core/cmd/shell_test.go @@ -12,6 +12,11 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" + solcfg "github.com/smartcontractkit/chainlink-solana/pkg/solana/config" + "github.com/smartcontractkit/chainlink-starknet/relayer/pkg/chainlink/config" + stkcfg "github.com/smartcontractkit/chainlink-starknet/relayer/pkg/chainlink/config" + "github.com/smartcontractkit/chainlink/v2/core/chains/solana" + "github.com/smartcontractkit/chainlink/v2/core/chains/starknet" "github.com/smartcontractkit/chainlink/v2/core/cmd" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" @@ -19,6 +24,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/mocks" "github.com/smartcontractkit/chainlink/v2/core/sessions" "github.com/smartcontractkit/chainlink/v2/plugins" @@ -336,18 +342,30 @@ func TestSetupSolanaRelayer(t *testing.T) { lggr := logger.TestLogger(t) reg := plugins.NewLoopRegistry(lggr) ks := mocks.NewSolana(t) - rf := cmd.RelayerFactory{ - Logger: lggr, - DB: pgtest.NewSqlxDB(t), - GeneralConfig: configtest.NewGeneralConfig(t, nil), - LoopRegistry: reg, + tConfig := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + c.Solana = solana.SolanaConfigs{ + &solana.SolanaConfig{ + ChainID: ptr[string]("solana-id-1"), + Enabled: new(bool), + Chain: solcfg.Chain{}, + Nodes: []*solcfg.Node{}, + }, + } + }) + + rf := chainlink.RelayerFactory{ + Logger: lggr, + DB: pgtest.NewSqlxDB(t), + QConfig: tConfig.Database(), + LoopRegistry: reg, } // not parallel; shared state t.Run("no plugin", func(t *testing.T) { - relayer, err := rf.NewSolana(ks) + relayers, err := rf.NewSolana(ks, tConfig.SolanaConfigs()) require.NoError(t, err) - require.NotNil(t, relayer) + require.NotNil(t, relayers) + require.Len(t, relayers, 1) // no using plugin, so registry should be empty require.Len(t, reg.List(), 0) }) @@ -355,9 +373,10 @@ func TestSetupSolanaRelayer(t *testing.T) { t.Run("plugin", func(t *testing.T) { t.Setenv("CL_SOLANA_CMD", "phony_solana_cmd") - relayer, err := rf.NewSolana(ks) + relayers, err := rf.NewSolana(ks, tConfig.SolanaConfigs()) require.NoError(t, err) - require.NotNil(t, relayer) + require.NotNil(t, relayers) + require.Len(t, relayers, 1) // make sure registry has the plugin require.Len(t, reg.List(), 1) }) @@ -368,18 +387,29 @@ func TestSetupStarkNetRelayer(t *testing.T) { lggr := logger.TestLogger(t) reg := plugins.NewLoopRegistry(lggr) ks := mocks.NewStarkNet(t) - rf := cmd.RelayerFactory{ - Logger: lggr, - DB: pgtest.NewSqlxDB(t), - GeneralConfig: configtest.NewGeneralConfig(t, nil), - LoopRegistry: reg, + tConfig := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + c.Starknet = starknet.StarknetConfigs{ + &starknet.StarknetConfig{ + ChainID: ptr[string]("starknet-id-1"), + Enabled: new(bool), + Chain: stkcfg.Chain{}, + Nodes: []*config.Node{}, + }, + } + }) + rf := chainlink.RelayerFactory{ + Logger: lggr, + DB: pgtest.NewSqlxDB(t), + QConfig: tConfig.Database(), + LoopRegistry: reg, } // not parallel; shared state t.Run("no plugin", func(t *testing.T) { - relayer, err := rf.NewStarkNet(ks) + relayers, err := rf.NewStarkNet(ks, tConfig.StarknetConfigs()) require.NoError(t, err) - require.NotNil(t, relayer) + require.NotNil(t, relayers) + require.Len(t, relayers, 1) // no using plugin, so registry should be empty require.Len(t, reg.List(), 0) }) @@ -387,9 +417,10 @@ func TestSetupStarkNetRelayer(t *testing.T) { t.Run("plugin", func(t *testing.T) { t.Setenv("CL_STARKNET_CMD", "phony_starknet_cmd") - relayer, err := rf.NewStarkNet(ks) + relayers, err := rf.NewStarkNet(ks, tConfig.StarknetConfigs()) require.NoError(t, err) - require.NotNil(t, relayer) + require.NotNil(t, relayers) + require.Len(t, relayers, 1) // make sure registry has the plugin require.Len(t, reg.List(), 1) }) diff --git a/core/internal/cltest/cltest.go b/core/internal/cltest/cltest.go index 4531ddf1586..554484af9ba 100644 --- a/core/internal/cltest/cltest.go +++ b/core/internal/cltest/cltest.go @@ -41,8 +41,7 @@ import ( "github.com/tidwall/gjson" "github.com/urfave/cli" - pkgsolana "github.com/smartcontractkit/chainlink-solana/pkg/solana" - pkgstarknet "github.com/smartcontractkit/chainlink-starknet/relayer/pkg/chainlink" + "github.com/smartcontractkit/chainlink-relay/pkg/loop" clienttypes "github.com/smartcontractkit/chainlink/v2/common/chains/client" txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" @@ -50,7 +49,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/auth" "github.com/smartcontractkit/chainlink/v2/core/bridges" - "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" @@ -59,8 +57,6 @@ import ( httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" - "github.com/smartcontractkit/chainlink/v2/core/chains/solana" - "github.com/smartcontractkit/chainlink/v2/core/chains/starknet" "github.com/smartcontractkit/chainlink/v2/core/cmd" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest" @@ -86,7 +82,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/vrfkey" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" - "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/services/webhook" clsessions "github.com/smartcontractkit/chainlink/v2/core/sessions" "github.com/smartcontractkit/chainlink/v2/core/static" @@ -196,12 +191,12 @@ type JobPipelineConfig interface { MaxSuccessfulRuns() uint64 } -func NewJobPipelineV2(t testing.TB, cfg pipeline.BridgeConfig, jpcfg JobPipelineConfig, dbCfg pg.QConfig, cc evm.ChainSet, db *sqlx.DB, keyStore keystore.Master, restrictedHTTPClient, unrestrictedHTTPClient *http.Client) JobPipelineV2TestHelper { +func NewJobPipelineV2(t testing.TB, cfg pipeline.BridgeConfig, jpcfg JobPipelineConfig, dbCfg pg.QConfig, legacyChains evm.LegacyChainContainer, db *sqlx.DB, keyStore keystore.Master, restrictedHTTPClient, unrestrictedHTTPClient *http.Client) JobPipelineV2TestHelper { lggr := logger.TestLogger(t) prm := pipeline.NewORM(db, lggr, dbCfg, jpcfg.MaxSuccessfulRuns()) btORM := bridges.NewORM(db, lggr, dbCfg) - jrm := job.NewORM(db, cc, prm, btORM, keyStore, lggr, dbCfg) - pr := pipeline.NewRunner(prm, btORM, jpcfg, cfg, cc, keyStore.Eth(), keyStore.VRF(), lggr, restrictedHTTPClient, unrestrictedHTTPClient) + jrm := job.NewORM(db, legacyChains, prm, btORM, keyStore, lggr, dbCfg) + pr := pipeline.NewRunner(prm, btORM, jpcfg, cfg, legacyChains, keyStore.Eth(), keyStore.VRF(), lggr, restrictedHTTPClient, unrestrictedHTTPClient) return JobPipelineV2TestHelper{ prm, jrm, @@ -366,7 +361,7 @@ func NewApplicationWithConfig(t testing.TB, cfg chainlink.GeneralConfig, flagsAn var externalInitiatorManager webhook.ExternalInitiatorManager externalInitiatorManager = &webhook.NullExternalInitiatorManager{} var useRealExternalInitiatorManager bool - var chainCfgs evmtypes.Configs + for _, flag := range flagsAndDeps { switch dep := flag.(type) { case evmclient.Client: @@ -394,104 +389,79 @@ func NewApplicationWithConfig(t testing.TB, cfg chainlink.GeneralConfig, flagsAn } mailMon := utils.NewMailboxMonitor(cfg.AppID().String()) - var chains chainlink.Chains + loopRegistry := plugins.NewLoopRegistry(lggr.Named("LoopRegistry")) + + relayerFactory := chainlink.RelayerFactory{ + Logger: lggr, + DB: db, + QConfig: cfg.Database(), + LoopRegistry: loopRegistry, + GRPCOpts: loop.GRPCOpts{}, + } + chainId := ethClient.ConfiguredChainID() - chains.EVM, err = evm.NewTOMLChainSet(testutils.Context(t), evm.ChainSetOpts{ - Configs: chainCfgs, - Config: cfg, - Logger: lggr, - DB: db, - KeyStore: keyStore.Eth(), - EventBroadcaster: eventBroadcaster, - GenEthClient: func(_ *big.Int) evmclient.Client { - if chainId.Cmp(cfg.DefaultChainID()) != 0 { - t.Fatalf("expected eth client ChainID %d to match configured DefaultChainID %d", chainId, cfg.DefaultChainID()) - } - return ethClient + evmOpts := chainlink.EVMFactoryConfig{ + RelayerConfig: evm.RelayerConfig{ + GeneralConfig: cfg, + EventBroadcaster: eventBroadcaster, + MailMon: mailMon, + GenEthClient: func(_ *big.Int) evmclient.Client { + if chainId.Cmp(cfg.DefaultChainID()) != 0 { + t.Fatalf("expected eth client ChainID %d to match configured DefaultChainID %d", chainId, cfg.DefaultChainID()) + } + return ethClient + }, }, - MailMon: mailMon, - }) - if err != nil { - lggr.Fatal(err) + CSAETHKeystore: keyStore, } + + testCtx := testutils.Context(t) + // evm alway enabled for backward compatibility + initOps := []chainlink.CoreRelayerChainInitFunc{chainlink.InitEVM(testCtx, relayerFactory, evmOpts)} + if cfg.CosmosEnabled() { - cosmosLggr := lggr.Named("Cosmos") - opts := cosmos.ChainSetOpts{ - Config: cfg, - Logger: cosmosLggr, - DB: db, - KeyStore: keyStore.Cosmos(), + cosmosCfg := chainlink.CosmosFactoryConfig{ + Keystore: keyStore.Cosmos(), + CosmosConfigs: cfg.CosmosConfigs(), EventBroadcaster: eventBroadcaster, } - cfgs := cfg.CosmosConfigs() - opts.Configs = cosmos.NewConfigs(cfgs) - chains.Cosmos, err = cosmos.NewChainSet(opts, cfgs) - if err != nil { - lggr.Fatal(err) - } + initOps = append(initOps, chainlink.InitCosmos(testCtx, relayerFactory, cosmosCfg)) } if cfg.SolanaEnabled() { - solLggr := lggr.Named("Solana") - cfgs := cfg.SolanaConfigs() - var ids []string - for _, c := range cfgs { - ids = append(ids, *c.ChainID) - } - - opts := solana.ChainSetOpts{ - Logger: solLggr, - KeyStore: &keystore.SolanaSigner{keyStore.Solana()}, - Configs: solana.NewConfigs(cfgs), + solanaCfg := chainlink.SolanaFactoryConfig{ + Keystore: keyStore.Solana(), + SolanaConfigs: cfg.SolanaConfigs(), } - chainSet, err := solana.NewChainSet(opts, cfgs) - if err != nil { - lggr.Fatal(err) - } - - chains.Solana = relay.NewRelayerAdapter(pkgsolana.NewRelayer(solLggr, chainSet), chainSet) + initOps = append(initOps, chainlink.InitSolana(testCtx, relayerFactory, solanaCfg)) } if cfg.StarkNetEnabled() { - starkLggr := lggr.Named("StarkNet") - cfgs := cfg.StarknetConfigs() - - var ids []string - for _, c := range cfgs { - ids = append(ids, *c.ChainID) + starkCfg := chainlink.StarkNetFactoryConfig{ + Keystore: keyStore.StarkNet(), + StarknetConfigs: cfg.StarknetConfigs(), } + initOps = append(initOps, chainlink.InitStarknet(testCtx, relayerFactory, starkCfg)) - if err != nil { - lggr.Fatal(err) - } - - opts := starknet.ChainSetOpts{ - Logger: starkLggr, - KeyStore: &keystore.StarknetLooppSigner{StarkNet: keyStore.StarkNet()}, - Configs: starknet.NewConfigs(cfgs), - } - - chainSet, err := starknet.NewChainSet(opts, cfgs) - if err != nil { - lggr.Fatal(err) - } - - chains.StarkNet = relay.NewRelayerAdapter(pkgstarknet.NewRelayer(starkLggr, chainSet), chainSet) + } + relayChainInterops, err := chainlink.NewCoreRelayerChainInteroperators(initOps...) + if err != nil { + t.Fatal(err) } c := clhttptest.NewTestLocalOnlyHTTPClient() appInstance, err := chainlink.NewApplication(chainlink.ApplicationOpts{ - Config: cfg, - EventBroadcaster: eventBroadcaster, - MailMon: mailMon, - SqlxDB: db, - KeyStore: keyStore, - Chains: chains, - Logger: lggr, - AuditLogger: auditLogger, - CloseLogger: lggr.Sync, - ExternalInitiatorManager: externalInitiatorManager, - RestrictedHTTPClient: c, - UnrestrictedHTTPClient: c, - SecretGenerator: MockSecretGenerator{}, - LoopRegistry: plugins.NewLoopRegistry(lggr), + Config: cfg, + EventBroadcaster: eventBroadcaster, + MailMon: mailMon, + SqlxDB: db, + KeyStore: keyStore, + RelayerChainInteroperators: relayChainInterops, + Logger: lggr, + AuditLogger: auditLogger, + CloseLogger: lggr.Sync, + ExternalInitiatorManager: externalInitiatorManager, + RestrictedHTTPClient: c, + UnrestrictedHTTPClient: c, + SecretGenerator: MockSecretGenerator{}, + LoopRegistry: plugins.NewLoopRegistry(lggr), }) require.NoError(t, err) app := appInstance.(*chainlink.ChainlinkApplication) diff --git a/core/internal/cltest/job_factories.go b/core/internal/cltest/job_factories.go index 649b2f9d015..624f647c267 100644 --- a/core/internal/cltest/job_factories.go +++ b/core/internal/cltest/job_factories.go @@ -16,6 +16,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/p2pkey" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) const ( @@ -63,8 +64,8 @@ func getORMs(t *testing.T, db *sqlx.DB) (jobORM job.ORM, pipelineORM pipeline.OR lggr := logger.TestLogger(t) pipelineORM = pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgeORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM = job.NewORM(db, cc, pipelineORM, bridgeORM, keyStore, lggr, config.Database()) + cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + jobORM = job.NewORM(db, evmrelay.NewLegacyChainsFromRelayerExtenders(cc), pipelineORM, bridgeORM, keyStore, lggr, config.Database()) t.Cleanup(func() { jobORM.Close() }) return } diff --git a/core/internal/cltest/mocks.go b/core/internal/cltest/mocks.go index 295ad366d04..9529941d4fb 100644 --- a/core/internal/cltest/mocks.go +++ b/core/internal/cltest/mocks.go @@ -4,7 +4,6 @@ import ( "context" "fmt" "io" - "math/big" "net/http" "net/http/httptest" "sync" @@ -14,15 +13,17 @@ import ( "github.com/smartcontractkit/sqlx" + "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" - evmconfig "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config" evmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/mocks" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/cmd" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/sessions" + "github.com/smartcontractkit/chainlink/v2/core/utils" "github.com/smartcontractkit/chainlink/v2/core/web" gethTypes "github.com/ethereum/go-ethereum/core/types" @@ -416,15 +417,22 @@ func (m MockPasswordPrompter) Prompt() string { return m.Password } -func NewChainSetMockWithOneChain(t testing.TB, ethClient evmclient.Client, cfg evmconfig.ChainScopedConfig) evm.ChainSet { - cc := new(evmmocks.ChainSet) +func NewLegacyChainsWithMockChain(t testing.TB, ethClient evmclient.Client, cfg evm.AppConfig) evm.LegacyChainContainer { ch := new(evmmocks.Chain) ch.On("Client").Return(ethClient) - ch.On("Config").Return(cfg) ch.On("Logger").Return(logger.TestLogger(t)) - ch.On("ID").Return(cfg.EVM().ChainID()) - cc.On("Default").Return(ch, nil) - cc.On("Get", (*big.Int)(nil)).Return(ch, nil) - cc.On("Chains").Return([]evm.Chain{ch}) - return cc + scopedCfg := evmtest.NewChainScopedConfig(t, cfg) + ch.On("ID").Return(scopedCfg.EVM().ChainID()) + ch.On("Config").Return(scopedCfg) + + return NewLegacyChainsWithChain(t, ch, cfg) + +} + +func NewLegacyChainsWithChain(t testing.TB, ch evm.Chain, cfg evm.AppConfig) evm.LegacyChainContainer { + chainNodeConfig := chains.NewConfigs[utils.Big, evmtypes.Node](cfg.EVMConfigs()) + m := map[string]evm.Chain{ch.ID().String(): ch} + legacyChains := evm.NewLegacyChains(chainNodeConfig, m) + legacyChains.SetDefault(ch) + return legacyChains } diff --git a/core/internal/features/features_test.go b/core/internal/features/features_test.go index b434fec0905..2e2d29c248d 100644 --- a/core/internal/features/features_test.go +++ b/core/internal/features/features_test.go @@ -65,6 +65,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/p2pkey" "github.com/smartcontractkit/chainlink/v2/core/services/ocr" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/webhook" "github.com/smartcontractkit/chainlink/v2/core/static" "github.com/smartcontractkit/chainlink/v2/core/store/models" @@ -234,7 +235,8 @@ observationSource = """ pipelineORM := pipeline.NewORM(app.GetSqlxDB(), logger.TestLogger(t), cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) bridgeORM := bridges.NewORM(app.GetSqlxDB(), logger.TestLogger(t), cfg.Database()) - jobORM := job.NewORM(app.GetSqlxDB(), app.GetChains().EVM, pipelineORM, bridgeORM, app.KeyStore, logger.TestLogger(t), cfg.Database()) + legacyChains := app.GetRelayers().LegacyEVMChains() + jobORM := job.NewORM(app.GetSqlxDB(), legacyChains, pipelineORM, bridgeORM, app.KeyStore, logger.TestLogger(t), cfg.Database()) runs := cltest.WaitForPipelineComplete(t, 0, jobID, 1, 2, jobORM, 5*time.Second, 300*time.Millisecond) require.Len(t, runs, 1) @@ -922,7 +924,7 @@ func TestIntegration_OCR(t *testing.T) { err = appBootstrap.Start(testutils.Context(t)) require.NoError(t, err) - jb, err := ocr.ValidatedOracleSpecToml(appBootstrap.GetChains().EVM, fmt.Sprintf(` + jb, err := ocr.ValidatedOracleSpecToml(appBootstrap.GetRelayers().LegacyEVMChains(), fmt.Sprintf(` type = "offchainreporting" schemaVersion = 1 name = "boot" @@ -990,7 +992,7 @@ isBootstrapPeer = true // Note we need: observationTimeout + observationGracePeriod + DeltaGrace (500ms) < DeltaRound (1s) // So 200ms + 200ms + 500ms < 1s - jb, err := ocr.ValidatedOracleSpecToml(apps[i].GetChains().EVM, fmt.Sprintf(` + jb, err := ocr.ValidatedOracleSpecToml(apps[i].GetRelayers().LegacyEVMChains(), fmt.Sprintf(` type = "offchainreporting" schemaVersion = 1 name = "web oracle spec" @@ -1150,7 +1152,7 @@ func TestIntegration_OCR_ForwarderFlow(t *testing.T) { require.NoError(t, err) // set forwardingAllowed = true - jb, err := ocr.ValidatedOracleSpecToml(appBootstrap.GetChains().EVM, fmt.Sprintf(` + jb, err := ocr.ValidatedOracleSpecToml(appBootstrap.GetRelayers().LegacyEVMChains(), fmt.Sprintf(` type = "offchainreporting" schemaVersion = 1 name = "boot" @@ -1220,7 +1222,7 @@ isBootstrapPeer = true // Note we need: observationTimeout + observationGracePeriod + DeltaGrace (500ms) < DeltaRound (1s) // So 200ms + 200ms + 500ms < 1s // forwardingAllowed = true - jb, err := ocr.ValidatedOracleSpecToml(apps[i].GetChains().EVM, fmt.Sprintf(` + jb, err := ocr.ValidatedOracleSpecToml(apps[i].GetRelayers().LegacyEVMChains(), fmt.Sprintf(` type = "offchainreporting" schemaVersion = 1 name = "web oracle spec" @@ -1322,7 +1324,7 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { kst := cltest.NewKeyStore(t, db, cfg.Database()) require.NoError(t, kst.Unlock(cltest.Password)) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), Client: ethClient, GeneralConfig: cfg}) + cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), Client: ethClient, GeneralConfig: cfg}) b41 := evmtypes.Block{ Number: 41, @@ -1373,13 +1375,15 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { ethClient.On("Dial", mock.Anything).Return(nil) ethClient.On("ConfiguredChainID", mock.Anything).Return(cfg.DefaultChainID(), nil) ethClient.On("BalanceAt", mock.Anything, mock.Anything, mock.Anything).Maybe().Return(oneETH.ToInt(), nil) - // HeadTracker backfill ethClient.On("HeadByHash", mock.Anything, h40.Hash).Return(&h40, nil).Maybe() ethClient.On("HeadByHash", mock.Anything, h41.Hash).Return(&h41, nil).Maybe() ethClient.On("HeadByHash", mock.Anything, h42.Hash).Return(&h42, nil).Maybe() - require.NoError(t, cc.Start(testutils.Context(t))) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + for _, re := range cc.Slice() { + require.NoError(t, re.Start(testutils.Context(t))) + } var newHeads evmtest.RawSub[*evmtypes.Head] select { case newHeads = <-chchNewHeads: @@ -1387,7 +1391,7 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { t.Fatal("timed out waiting for app to subscribe") } - chain := evmtest.MustGetDefaultChain(t, cc) + chain := evmtest.MustGetDefaultChain(t, legacyChains) estimator := chain.GasEstimator() gasPrice, gasLimit, err := estimator.GetFee(testutils.Context(t), nil, 500_000, maxGasPrice) require.NoError(t, err) @@ -1416,7 +1420,7 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { } func triggerAllKeys(t *testing.T, app *cltest.TestApplication) { - for _, chain := range app.GetChains().EVM.Chains() { + for _, chain := range app.GetRelayers().LegacyEVMChains().Slice() { keys, err := app.KeyStore.Eth().EnabledKeysForChain(chain.ID()) require.NoError(t, err) for _, k := range keys { diff --git a/core/internal/features/ocr2/features_ocr2_test.go b/core/internal/features/ocr2/features_ocr2_test.go index 7c1335dbf80..10317597ebc 100644 --- a/core/internal/features/ocr2/features_ocr2_test.go +++ b/core/internal/features/ocr2/features_ocr2_test.go @@ -266,7 +266,7 @@ func TestIntegration_OCR2(t *testing.T) { err = bootstrapNode.app.Start(testutils.Context(t)) require.NoError(t, err) - chainSet := bootstrapNode.app.GetChains().EVM + chainSet := bootstrapNode.app.GetRelayers().LegacyEVMChains() require.NotNil(t, chainSet) ocrJob, err := ocrbootstrap.ValidatedBootstrapSpecToml(fmt.Sprintf(` type = "bootstrap" @@ -434,7 +434,8 @@ juelsPerFeeCoinSource = """ // Assert we can read the latest config digest and epoch after a report has been submitted. contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorABI)) require.NoError(t, err) - ct, err := evm.NewOCRContractTransmitter(ocrContractAddress, apps[0].Chains.EVM.Chains()[0].Client(), contractABI, nil, apps[0].Chains.EVM.Chains()[0].LogPoller(), lggr, nil) + apps[0].GetRelayers().LegacyEVMChains().Slice() + ct, err := evm.NewOCRContractTransmitter(ocrContractAddress, apps[0].GetRelayers().LegacyEVMChains().Slice()[0].Client(), contractABI, nil, apps[0].GetRelayers().LegacyEVMChains().Slice()[0].LogPoller(), lggr, nil) require.NoError(t, err) configDigest, epoch, err := ct.LatestConfigDigestAndEpoch(testutils.Context(t)) require.NoError(t, err) @@ -535,7 +536,7 @@ func TestIntegration_OCR2_ForwarderFlow(t *testing.T) { err = bootstrapNode.app.Start(testutils.Context(t)) require.NoError(t, err) - chainSet := bootstrapNode.app.GetChains().EVM + chainSet := bootstrapNode.app.GetRelayers().LegacyEVMChains() require.NotNil(t, chainSet) ocrJob, err := ocrbootstrap.ValidatedBootstrapSpecToml(fmt.Sprintf(` type = "bootstrap" @@ -657,9 +658,9 @@ juelsPerFeeCoinSource = """ // Once all the jobs are added, replay to ensure we have the configSet logs. for _, app := range apps { - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), blockBeforeConfig.Number().Int64())) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Replay(testutils.Context(t), blockBeforeConfig.Number().Int64())) } - require.NoError(t, bootstrapNode.app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), blockBeforeConfig.Number().Int64())) + require.NoError(t, bootstrapNode.app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Replay(testutils.Context(t), blockBeforeConfig.Number().Int64())) // Assert that all the OCR jobs get a run with valid values eventually. var wg sync.WaitGroup @@ -709,7 +710,7 @@ juelsPerFeeCoinSource = """ // Assert we can read the latest config digest and epoch after a report has been submitted. contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorABI)) require.NoError(t, err) - ct, err := evm.NewOCRContractTransmitter(ocrContractAddress, apps[0].Chains.EVM.Chains()[0].Client(), contractABI, nil, apps[0].Chains.EVM.Chains()[0].LogPoller(), lggr, nil) + ct, err := evm.NewOCRContractTransmitter(ocrContractAddress, apps[0].GetRelayers().LegacyEVMChains().Slice()[0].Client(), contractABI, nil, apps[0].GetRelayers().LegacyEVMChains().Slice()[0].LogPoller(), lggr, nil) require.NoError(t, err) configDigest, epoch, err := ct.LatestConfigDigestAndEpoch(testutils.Context(t)) require.NoError(t, err) diff --git a/core/internal/mocks/application.go b/core/internal/mocks/application.go index 62264f1ff59..fd065dc5dec 100644 --- a/core/internal/mocks/application.go +++ b/core/internal/mocks/application.go @@ -127,20 +127,6 @@ func (_m *Application) GetAuditLogger() audit.AuditLogger { return r0 } -// GetChains provides a mock function with given fields: -func (_m *Application) GetChains() chainlink.Chains { - ret := _m.Called() - - var r0 chainlink.Chains - if rf, ok := ret.Get(0).(func() chainlink.Chains); ok { - r0 = rf() - } else { - r0 = ret.Get(0).(chainlink.Chains) - } - - return r0 -} - // GetConfig provides a mock function with given fields: func (_m *Application) GetConfig() chainlink.GeneralConfig { ret := _m.Called() @@ -269,6 +255,22 @@ func (_m *Application) GetLoopRegistry() *plugins.LoopRegistry { return r0 } +// GetRelayers provides a mock function with given fields: +func (_m *Application) GetRelayers() chainlink.RelayerChainInteroperators { + ret := _m.Called() + + var r0 chainlink.RelayerChainInteroperators + if rf, ok := ret.Get(0).(func() chainlink.RelayerChainInteroperators); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(chainlink.RelayerChainInteroperators) + } + } + + return r0 +} + // GetSqlxDB provides a mock function with given fields: func (_m *Application) GetSqlxDB() *sqlx.DB { ret := _m.Called() diff --git a/core/internal/testutils/configtest/v2/general_config.go b/core/internal/testutils/configtest/v2/general_config.go index 168906c263e..34843c740d6 100644 --- a/core/internal/testutils/configtest/v2/general_config.go +++ b/core/internal/testutils/configtest/v2/general_config.go @@ -66,7 +66,15 @@ func overrides(c *chainlink.Config, s *chainlink.Secrets) { c.EVM = append(c.EVM, &evmcfg.EVMConfig{ ChainID: chainID, Chain: evmcfg.Defaults(chainID), - Nodes: evmcfg.EVMNodes{{Name: ptr("test")}}, + Nodes: evmcfg.EVMNodes{ + &evmcfg.Node{ + Name: ptr("test"), + WSURL: &models.URL{}, + HTTPURL: &models.URL{}, + SendOnly: new(bool), + Order: ptr[int32](100), + }, + }, }) } @@ -91,7 +99,7 @@ func simulated(c *chainlink.Config, s *chainlink.Secrets) { ChainID: chainID, Chain: evmcfg.Defaults(chainID), Enabled: &enabled, - Nodes: evmcfg.EVMNodes{{}}, + Nodes: evmcfg.EVMNodes{&validTestNode}, } if len(c.EVM) == 1 && c.EVM[0].ChainID.Cmp(utils.NewBigI(client.NullClientChainID)) == 0 { c.EVM[0] = &cfg // replace null, if only entry @@ -100,4 +108,12 @@ func simulated(c *chainlink.Config, s *chainlink.Secrets) { } } +var validTestNode = evmcfg.Node{ + Name: ptr("simulated-node"), + WSURL: models.MustParseURL("WSS://simulated-wss.com/ws"), + HTTPURL: models.MustParseURL("http://simulated.com"), + SendOnly: nil, + Order: ptr(int32(1)), +} + func ptr[T any](v T) *T { return &v } diff --git a/core/internal/testutils/evmtest/evmtest.go b/core/internal/testutils/evmtest/evmtest.go index 88f0b0137f5..bbbeaf05660 100644 --- a/core/internal/testutils/evmtest/evmtest.go +++ b/core/internal/testutils/evmtest/evmtest.go @@ -27,18 +27,18 @@ import ( httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" - evmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/utils" ) -func NewChainScopedConfig(t testing.TB, cfg evm.GeneralConfig) evmconfig.ChainScopedConfig { +func NewChainScopedConfig(t testing.TB, cfg evm.AppConfig) evmconfig.ChainScopedConfig { var evmCfg *evmtoml.EVMConfig if len(cfg.EVMConfigs()) > 0 { evmCfg = cfg.EVMConfigs()[0] @@ -58,7 +58,7 @@ type TestChainOpts struct { Client evmclient.Client LogBroadcaster log.Broadcaster LogPoller logpoller.LogPoller - GeneralConfig evm.GeneralConfig + GeneralConfig evm.AppConfig HeadTracker httypes.HeadTracker DB *sqlx.DB TxManager txmgr.TxManager @@ -67,32 +67,27 @@ type TestChainOpts struct { GasEstimator gas.EvmFeeEstimator } -// NewChainSet returns a simple chain collection with one chain and +// NewChainRelayExtenders returns a simple chain collection with one chain and // allows to mock client/config on that chain -func NewChainSet(t testing.TB, testopts TestChainOpts) evm.ChainSet { - opts := NewChainSetOpts(t, testopts) - cc, err := evm.NewTOMLChainSet(testutils.Context(t), opts) +func NewChainRelayExtenders(t testing.TB, testopts TestChainOpts) *evmrelay.ChainRelayerExtenders { + opts := NewChainRelayExtOpts(t, testopts) + cc, err := evmrelay.NewChainRelayerExtenders(testutils.Context(t), opts) require.NoError(t, err) return cc } -// NewMockChainSetWithChain returns a mock chainset with one chain -func NewMockChainSetWithChain(t testing.TB, ch evm.Chain) *evmmocks.ChainSet { - cc := evmmocks.NewChainSet(t) - cc.On("Default").Return(ch, nil) - return cc -} - -func NewChainSetOpts(t testing.TB, testopts TestChainOpts) evm.ChainSetOpts { +func NewChainRelayExtOpts(t testing.TB, testopts TestChainOpts) evm.ChainRelayExtenderConfig { require.NotNil(t, testopts.KeyStore) - opts := evm.ChainSetOpts{ - Config: testopts.GeneralConfig, - Logger: logger.TestLogger(t), - DB: testopts.DB, - KeyStore: testopts.KeyStore, - EventBroadcaster: pg.NewNullEventBroadcaster(), - MailMon: testopts.MailMon, - GasEstimator: testopts.GasEstimator, + opts := evm.ChainRelayExtenderConfig{ + Logger: logger.TestLogger(t), + DB: testopts.DB, + KeyStore: testopts.KeyStore, + RelayerConfig: evm.RelayerConfig{ + GeneralConfig: testopts.GeneralConfig, + EventBroadcaster: pg.NewNullEventBroadcaster(), + MailMon: testopts.MailMon, + GasEstimator: testopts.GasEstimator, + }, } opts.GenEthClient = func(*big.Int) evmclient.Client { if testopts.Client != nil { @@ -132,7 +127,7 @@ func NewChainSetOpts(t testing.TB, testopts TestChainOpts) evm.ChainSetOpts { return opts } -func MustGetDefaultChain(t testing.TB, cc evm.ChainSet) evm.Chain { +func MustGetDefaultChain(t testing.TB, cc evm.LegacyChainContainer) evm.Chain { chain, err := cc.Default() require.NoError(t, err) return chain diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 2510ec540e4..901e5622894 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -297,7 +297,7 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 94ae5ba7d3a..86a410ddded 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1428,8 +1428,8 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= diff --git a/core/services/blockhashstore/bhs_test.go b/core/services/blockhashstore/bhs_test.go index 6f90d6312f3..79494ea41f6 100644 --- a/core/services/blockhashstore/bhs_test.go +++ b/core/services/blockhashstore/bhs_test.go @@ -19,6 +19,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/blockhashstore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -28,8 +29,9 @@ func TestStoreRotatesFromAddresses(t *testing.T) { cfg := configtest.NewTestGeneralConfig(t) kst := cltest.NewKeyStore(t, db, cfg.Database()) require.NoError(t, kst.Unlock(cltest.Password)) - chainSet := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), GeneralConfig: cfg, Client: ethClient}) - chain, err := chainSet.Get(&cltest.FixtureChainID) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), GeneralConfig: cfg, Client: ethClient}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + chain, err := legacyChains.Get(cltest.FixtureChainID.String()) require.NoError(t, err) lggr := logger.TestLogger(t) ks := keystore.New(db, utils.FastScryptParams, lggr, cfg.Database()) diff --git a/core/services/blockhashstore/delegate.go b/core/services/blockhashstore/delegate.go index dd21d0fbc51..3c2c241a0b7 100644 --- a/core/services/blockhashstore/delegate.go +++ b/core/services/blockhashstore/delegate.go @@ -25,21 +25,21 @@ var _ job.ServiceCtx = &service{} // Delegate creates BlockhashStore feeder jobs. type Delegate struct { - logger logger.Logger - chains evm.ChainSet - ks keystore.Eth + logger logger.Logger + legacyChains evm.LegacyChainContainer + ks keystore.Eth } // NewDelegate creates a new Delegate. func NewDelegate( logger logger.Logger, - chains evm.ChainSet, + legacyChains evm.LegacyChainContainer, ks keystore.Eth, ) *Delegate { return &Delegate{ - logger: logger, - chains: chains, - ks: ks, + logger: logger, + legacyChains: legacyChains, + ks: ks, } } @@ -55,7 +55,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC "blockhashstore.Delegate expects a BlockhashStoreSpec to be present, got %+v", jb) } - chain, err := d.chains.Get(jb.BlockhashStoreSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(jb.BlockhashStoreSpec.EVMChainID.String()) if err != nil { return nil, fmt.Errorf( "getting chain ID %d: %w", jb.BlockhashStoreSpec.EVMChainID.ToInt(), err) diff --git a/core/services/blockhashstore/delegate_test.go b/core/services/blockhashstore/delegate_test.go index a877906228a..43faba94dd8 100644 --- a/core/services/blockhashstore/delegate_test.go +++ b/core/services/blockhashstore/delegate_test.go @@ -24,6 +24,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -37,11 +38,11 @@ func TestDelegate_JobType(t *testing.T) { } type testData struct { - ethClient *mocks.Client - ethKeyStore keystore.Eth - chainSet evm.ChainSet - sendingKey ethkey.KeyV2 - logs *observer.ObservedLogs + ethClient *mocks.Client + ethKeyStore keystore.Eth + legacyChains evm.LegacyChainContainer + sendingKey ethkey.KeyV2 + logs *observer.ObservedLogs } func createTestDelegate(t *testing.T) (*blockhashstore.Delegate, *testData) { @@ -58,7 +59,8 @@ func createTestDelegate(t *testing.T) (*blockhashstore.Delegate, *testData) { lp := &mocklp.LogPoller{} lp.On("RegisterFilter", mock.Anything).Return(nil) lp.On("LatestBlock", mock.Anything, mock.Anything).Return(int64(0), nil) - chainSet := evmtest.NewChainSet( + + relayExtenders := evmtest.NewChainRelayExtenders( t, evmtest.TestChainOpts{ DB: db, @@ -68,13 +70,13 @@ func createTestDelegate(t *testing.T) (*blockhashstore.Delegate, *testData) { LogPoller: lp, }, ) - - return blockhashstore.NewDelegate(lggr, chainSet, kst), &testData{ - ethClient: ethClient, - ethKeyStore: kst, - chainSet: chainSet, - sendingKey: sendingKey, - logs: logs, + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + return blockhashstore.NewDelegate(lggr, legacyChains, kst), &testData{ + ethClient: ethClient, + ethKeyStore: kst, + legacyChains: legacyChains, + sendingKey: sendingKey, + logs: logs, } } @@ -83,8 +85,8 @@ func TestDelegate_ServicesForSpec(t *testing.T) { delegate, testData := createTestDelegate(t) - require.NotEmpty(t, testData.chainSet.Chains()) - defaultWaitBlocks := (int32)(testData.chainSet.Chains()[0].Config().EVM().FinalityDepth()) + require.NotEmpty(t, testData.legacyChains.Slice()) + defaultWaitBlocks := (int32)(testData.legacyChains.Slice()[0].Config().EVM().FinalityDepth()) t.Run("happy", func(t *testing.T) { spec := job.Job{BlockhashStoreSpec: &job.BlockhashStoreSpec{WaitBlocks: defaultWaitBlocks}} @@ -150,8 +152,8 @@ func TestDelegate_StartStop(t *testing.T) { delegate, testData := createTestDelegate(t) - require.NotEmpty(t, testData.chainSet.Chains()) - defaultWaitBlocks := (int32)(testData.chainSet.Chains()[0].Config().EVM().FinalityDepth()) + require.NotEmpty(t, testData.legacyChains.Slice()) + defaultWaitBlocks := (int32)(testData.legacyChains.Slice()[0].Config().EVM().FinalityDepth()) spec := job.Job{BlockhashStoreSpec: &job.BlockhashStoreSpec{ WaitBlocks: defaultWaitBlocks, PollPeriod: time.Second, diff --git a/core/services/blockheaderfeeder/delegate.go b/core/services/blockheaderfeeder/delegate.go index 18faba0b867..938df59bb76 100644 --- a/core/services/blockheaderfeeder/delegate.go +++ b/core/services/blockheaderfeeder/delegate.go @@ -25,20 +25,20 @@ import ( var _ job.ServiceCtx = &service{} type Delegate struct { - logger logger.Logger - chains evm.ChainSet - ks keystore.Eth + logger logger.Logger + legacyChains evm.LegacyChainContainer + ks keystore.Eth } func NewDelegate( logger logger.Logger, - chains evm.ChainSet, + legacyChains evm.LegacyChainContainer, ks keystore.Eth, ) *Delegate { return &Delegate{ - logger: logger, - chains: chains, - ks: ks, + logger: logger, + legacyChains: legacyChains, + ks: ks, } } @@ -53,7 +53,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC return nil, errors.Errorf("Delegate expects a BlockHeaderFeederSpec to be present, got %+v", jb) } - chain, err := d.chains.Get(jb.BlockHeaderFeederSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(jb.BlockHeaderFeederSpec.EVMChainID.String()) if err != nil { return nil, fmt.Errorf( "getting chain ID %d: %w", jb.BlockHeaderFeederSpec.EVMChainID.ToInt(), err) diff --git a/core/services/chainlink/application.go b/core/services/chainlink/application.go index 5cb7828d016..e031973e561 100644 --- a/core/services/chainlink/application.go +++ b/core/services/chainlink/application.go @@ -3,6 +3,7 @@ package chainlink import ( "bytes" "context" + "fmt" "math/big" "net/http" "sync" @@ -17,13 +18,10 @@ import ( "github.com/smartcontractkit/sqlx" - pkgcosmos "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos" "github.com/smartcontractkit/chainlink-relay/pkg/loop" "github.com/smartcontractkit/chainlink/v2/core/bridges" "github.com/smartcontractkit/chainlink/v2/core/build" - "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/config" @@ -48,8 +46,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" "github.com/smartcontractkit/chainlink/v2/core/services/promreporter" - "github.com/smartcontractkit/chainlink/v2/core/services/relay" - evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization" "github.com/smartcontractkit/chainlink/v2/core/services/telemetry" @@ -60,9 +56,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/plugins" ) -//go:generate mockery --quiet --name Application --output ../../internal/mocks/ --case=underscore - // Application implements the common functions used in the core node. +// +//go:generate mockery --quiet --name Application --output ../../internal/mocks/ --case=underscore type Application interface { Start(ctx context.Context) error Stop() error @@ -78,8 +74,7 @@ type Application interface { GetWebAuthnConfiguration() sessions.WebAuthnConfiguration GetExternalInitiatorManager() webhook.ExternalInitiatorManager - GetChains() Chains - + GetRelayers() RelayerChainInteroperators GetLoopRegistry() *plugins.LoopRegistry // V2 Jobs (TOML specified) @@ -114,7 +109,7 @@ type Application interface { // and Store. The JobSubscriber and Scheduler are also available // in the services package, but the Store has its own package. type ChainlinkApplication struct { - Chains Chains + relayers *CoreRelayerChainInteroperators EventBroadcaster pg.EventBroadcaster jobORM job.ORM jobSpawner job.Spawner @@ -147,46 +142,22 @@ type ChainlinkApplication struct { } type ApplicationOpts struct { - Config GeneralConfig - Logger logger.Logger - EventBroadcaster pg.EventBroadcaster - MailMon *utils.MailboxMonitor - SqlxDB *sqlx.DB - KeyStore keystore.Master - Chains Chains - AuditLogger audit.AuditLogger - CloseLogger func() error - ExternalInitiatorManager webhook.ExternalInitiatorManager - Version string - RestrictedHTTPClient *http.Client - UnrestrictedHTTPClient *http.Client - SecretGenerator SecretGenerator - LoopRegistry *plugins.LoopRegistry - GRPCOpts loop.GRPCOpts -} - -// Chains holds a ChainSet for each type of chain. -type Chains struct { - EVM evm.ChainSet - Cosmos cosmos.ChainSet // nil if disabled - Solana loop.Relayer // nil if disabled - StarkNet loop.Relayer // nil if disabled -} - -func (c *Chains) services() (s []services.ServiceCtx) { - if c.Cosmos != nil { - s = append(s, c.Cosmos) - } - if c.EVM != nil { - s = append(s, c.EVM) - } - if c.Solana != nil { - s = append(s, c.Solana) - } - if c.StarkNet != nil { - s = append(s, c.StarkNet) - } - return + Config GeneralConfig + Logger logger.Logger + EventBroadcaster pg.EventBroadcaster + MailMon *utils.MailboxMonitor + SqlxDB *sqlx.DB + KeyStore keystore.Master + RelayerChainInteroperators *CoreRelayerChainInteroperators + AuditLogger audit.AuditLogger + CloseLogger func() error + ExternalInitiatorManager webhook.ExternalInitiatorManager + Version string + RestrictedHTTPClient *http.Client + UnrestrictedHTTPClient *http.Client + SecretGenerator SecretGenerator + LoopRegistry *plugins.LoopRegistry + GRPCOpts loop.GRPCOpts } // NewApplication initializes a new store if one is not already @@ -199,7 +170,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { auditLogger := opts.AuditLogger db := opts.SqlxDB cfg := opts.Config - chains := opts.Chains + relayerChainInterops := opts.RelayerChainInteroperators eventBroadcaster := opts.EventBroadcaster mailMon := opts.MailMon externalInitiatorManager := opts.ExternalInitiatorManager @@ -293,48 +264,56 @@ func NewApplication(opts ApplicationOpts) (Application, error) { } srvcs = append(srvcs, eventBroadcaster, mailMon) - srvcs = append(srvcs, chains.services()...) + srvcs = append(srvcs, relayerChainInterops.Services()...) promReporter := promreporter.NewPromReporter(db.DB, globalLogger) srvcs = append(srvcs, promReporter) + // EVM chains are used all over the place. This will need to change for fully EVM extraction + // TODO: BCF-2510, BCF-2511 + + legacyEVMChains := relayerChainInterops.LegacyEVMChains() + if legacyEVMChains == nil { + return nil, fmt.Errorf("no evm chains found") + } + var ( pipelineORM = pipeline.NewORM(db, globalLogger, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) bridgeORM = bridges.NewORM(db, globalLogger, cfg.Database()) sessionORM = sessions.NewORM(db, cfg.WebServer().SessionTimeout().Duration(), globalLogger, cfg.Database(), auditLogger) mercuryORM = mercury.NewORM(db, globalLogger, cfg.Database()) - pipelineRunner = pipeline.NewRunner(pipelineORM, bridgeORM, cfg.JobPipeline(), cfg.WebServer(), chains.EVM, keyStore.Eth(), keyStore.VRF(), globalLogger, restrictedHTTPClient, unrestrictedHTTPClient) - jobORM = job.NewORM(db, chains.EVM, pipelineORM, bridgeORM, keyStore, globalLogger, cfg.Database()) + pipelineRunner = pipeline.NewRunner(pipelineORM, bridgeORM, cfg.JobPipeline(), cfg.WebServer(), legacyEVMChains, keyStore.Eth(), keyStore.VRF(), globalLogger, restrictedHTTPClient, unrestrictedHTTPClient) + jobORM = job.NewORM(db, legacyEVMChains, pipelineORM, bridgeORM, keyStore, globalLogger, cfg.Database()) txmORM = txmgr.NewTxStore(db, globalLogger, cfg.Database()) ) - srvcs = append(srvcs, pipelineORM) - - for _, chain := range chains.EVM.Chains() { + for _, chain := range legacyEVMChains.Slice() { chain.HeadBroadcaster().Subscribe(promReporter) chain.TxManager().RegisterResumeCallback(pipelineRunner.ResumeRun) } + srvcs = append(srvcs, pipelineORM) + var ( delegates = map[job.Type]job.Delegate{ job.DirectRequest: directrequest.NewDelegate( globalLogger, pipelineRunner, pipelineORM, - chains.EVM, + legacyEVMChains, mailMon), job.Keeper: keeper.NewDelegate( db, jobORM, pipelineRunner, globalLogger, - chains.EVM, + legacyEVMChains, mailMon), job.VRF: vrf.NewDelegate( db, keyStore, pipelineRunner, pipelineORM, - chains.EVM, + legacyEVMChains, globalLogger, cfg.Database(), mailMon), @@ -347,14 +326,14 @@ func NewApplication(opts ApplicationOpts) (Application, error) { globalLogger), job.BlockhashStore: blockhashstore.NewDelegate( globalLogger, - chains.EVM, + legacyEVMChains, keyStore.Eth()), job.BlockHeaderFeeder: blockheaderfeeder.NewDelegate( globalLogger, - chains.EVM, + legacyEVMChains, keyStore.Eth()), job.Gateway: gateway.NewDelegate( - chains.EVM, + legacyEVMChains, keyStore.Eth(), globalLogger), } @@ -371,7 +350,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { pipelineORM, pipelineRunner, db, - chains.EVM, + legacyEVMChains, globalLogger, ) } @@ -395,7 +374,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { pipelineRunner, peerWrapper, monitoringEndpointGen, - chains.EVM, + legacyEVMChains, globalLogger, cfg.Database(), mailMon, @@ -405,23 +384,6 @@ func NewApplication(opts ApplicationOpts) (Application, error) { } if cfg.OCR2().Enabled() { globalLogger.Debug("Off-chain reporting v2 enabled") - relayers := make(map[relay.Network]loop.Relayer) - if cfg.EVMEnabled() { - lggr := globalLogger.Named("EVM") - evmRelayer := evmrelay.NewRelayer(db, chains.EVM, lggr, cfg.Database(), keyStore, eventBroadcaster) - relayers[relay.EVM] = relay.NewRelayerAdapter(evmRelayer, chains.EVM) - } - if cfg.CosmosEnabled() { - lggr := globalLogger.Named("Cosmos.Relayer") - cosmosRelayer := pkgcosmos.NewRelayer(lggr, chains.Cosmos) - relayers[relay.Cosmos] = relay.NewRelayerAdapter(cosmosRelayer, chains.Cosmos) - } - if cfg.SolanaEnabled() { - relayers[relay.Solana] = chains.Solana - } - if cfg.StarkNetEnabled() { - relayers[relay.StarkNet] = chains.StarkNet - } registrarConfig := plugins.NewRegistrarConfig(opts.GRPCOpts, opts.LoopRegistry.Register) ocr2DelegateConfig := ocr2.NewDelegateConfig(cfg.OCR2(), cfg.Mercury(), cfg.Threshold(), cfg.Insecure(), cfg.JobPipeline(), cfg.Database(), registrarConfig) delegates[job.OffchainReporting2] = ocr2.NewDelegate( @@ -432,14 +394,14 @@ func NewApplication(opts ApplicationOpts) (Application, error) { pipelineRunner, peerWrapper, monitoringEndpointGen, - chains.EVM, + legacyEVMChains, globalLogger, ocr2DelegateConfig, keyStore.OCR2(), keyStore.DKGSign(), keyStore.DKGEncrypt(), keyStore.Eth(), - relayers, + opts.RelayerChainInteroperators, mailMon, eventBroadcaster, ) @@ -450,14 +412,14 @@ func NewApplication(opts ApplicationOpts) (Application, error) { globalLogger, cfg.OCR2(), cfg.Insecure(), - relayers, + opts.RelayerChainInteroperators, ) } else { globalLogger.Debug("Off-chain reporting v2 disabled") } var lbs []utils.DependentAwaiter - for _, c := range chains.EVM.Chains() { + for _, c := range legacyEVMChains.Slice() { lbs = append(lbs, c.LogBroadcaster()) } jobSpawner := job.NewSpawner(jobORM, cfg.Database(), delegates, db, globalLogger, lbs) @@ -466,7 +428,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { // We start the log poller after the job spawner // so jobs have a chance to apply their initial log filters. if cfg.Feature().LogPoller() { - for _, c := range chains.EVM.Chains() { + for _, c := range legacyEVMChains.Slice() { srvcs = append(srvcs, c.LogPoller()) } } @@ -485,7 +447,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { cfg.OCR(), cfg.OCR2(), cfg.Database(), - chains.EVM, + legacyEVMChains, globalLogger, opts.Version, ) @@ -494,7 +456,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { } app := &ChainlinkApplication{ - Chains: chains, + relayers: opts.RelayerChainInteroperators, EventBroadcaster: eventBroadcaster, jobORM: jobORM, jobSpawner: jobSpawner, @@ -535,7 +497,7 @@ func NewApplication(opts ApplicationOpts) (Application, error) { // To avoid subscribing chain services twice, we only subscribe them if OCR2 is not enabled. // If it's enabled, they are going to be registered with relayers by default. if !cfg.OCR2().Enabled() { - for _, service := range app.Chains.services() { + for _, service := range app.relayers.Services() { checkable := service.(services.Checkable) if err := app.HealthChecker.Register(service.Name(), checkable); err != nil { return nil, err @@ -698,8 +660,9 @@ func (app *ChainlinkApplication) SessionORM() sessions.ORM { return app.sessionORM } +// TODO BCF-2516 remove this all together remove EVM specifics func (app *ChainlinkApplication) EVMORM() evmtypes.Configs { - return app.Chains.EVM.Configs() + return app.GetRelayers().LegacyEVMChains().ChainNodeConfigs() } func (app *ChainlinkApplication) PipelineORM() pipeline.ORM { @@ -823,7 +786,7 @@ func (app *ChainlinkApplication) GetFeedsService() feeds.Service { // ReplayFromBlock implements the Application interface. func (app *ChainlinkApplication) ReplayFromBlock(chainID *big.Int, number uint64, forceBroadcast bool) error { - chain, err := app.Chains.EVM.Get(chainID) + chain, err := app.GetRelayers().LegacyEVMChains().Get(chainID.String()) if err != nil { return err } @@ -834,9 +797,8 @@ func (app *ChainlinkApplication) ReplayFromBlock(chainID *big.Int, number uint64 return nil } -// GetChains returns Chains. -func (app *ChainlinkApplication) GetChains() Chains { - return app.Chains +func (app *ChainlinkApplication) GetRelayers() RelayerChainInteroperators { + return app.relayers } func (app *ChainlinkApplication) GetEventBroadcaster() pg.EventBroadcaster { diff --git a/core/services/chainlink/mocks/relayer_chain_interoperators.go b/core/services/chainlink/mocks/relayer_chain_interoperators.go new file mode 100644 index 00000000000..eeb4617fc01 --- /dev/null +++ b/core/services/chainlink/mocks/relayer_chain_interoperators.go @@ -0,0 +1,248 @@ +// Code generated by mockery v2.28.1. DO NOT EDIT. + +package mocks + +import ( + context "context" + + chainlink "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + + cosmos "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" + + evm "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + + // Manually edited. mockery generates the wrong dependency. edited to use `loop` rather than `loop/internal` + // seems to caused by incorrect alias resolution of the relayer dep + internal "github.com/smartcontractkit/chainlink-relay/pkg/loop" + + mock "github.com/stretchr/testify/mock" + + relay "github.com/smartcontractkit/chainlink/v2/core/services/relay" + + services "github.com/smartcontractkit/chainlink/v2/core/services" + + types "github.com/smartcontractkit/chainlink-relay/pkg/types" +) + +// RelayerChainInteroperators is an autogenerated mock type for the RelayerChainInteroperators type +type RelayerChainInteroperators struct { + mock.Mock +} + +// ChainStatus provides a mock function with given fields: ctx, id +func (_m *RelayerChainInteroperators) ChainStatus(ctx context.Context, id relay.Identifier) (types.ChainStatus, error) { + ret := _m.Called(ctx, id) + + var r0 types.ChainStatus + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, relay.Identifier) (types.ChainStatus, error)); ok { + return rf(ctx, id) + } + if rf, ok := ret.Get(0).(func(context.Context, relay.Identifier) types.ChainStatus); ok { + r0 = rf(ctx, id) + } else { + r0 = ret.Get(0).(types.ChainStatus) + } + + if rf, ok := ret.Get(1).(func(context.Context, relay.Identifier) error); ok { + r1 = rf(ctx, id) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// ChainStatuses provides a mock function with given fields: ctx, offset, limit +func (_m *RelayerChainInteroperators) ChainStatuses(ctx context.Context, offset int, limit int) ([]types.ChainStatus, int, error) { + ret := _m.Called(ctx, offset, limit) + + var r0 []types.ChainStatus + var r1 int + var r2 error + if rf, ok := ret.Get(0).(func(context.Context, int, int) ([]types.ChainStatus, int, error)); ok { + return rf(ctx, offset, limit) + } + if rf, ok := ret.Get(0).(func(context.Context, int, int) []types.ChainStatus); ok { + r0 = rf(ctx, offset, limit) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]types.ChainStatus) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, int, int) int); ok { + r1 = rf(ctx, offset, limit) + } else { + r1 = ret.Get(1).(int) + } + + if rf, ok := ret.Get(2).(func(context.Context, int, int) error); ok { + r2 = rf(ctx, offset, limit) + } else { + r2 = ret.Error(2) + } + + return r0, r1, r2 +} + +// Get provides a mock function with given fields: id +func (_m *RelayerChainInteroperators) Get(id relay.Identifier) (internal.Relayer, error) { + ret := _m.Called(id) + + var r0 internal.Relayer + var r1 error + if rf, ok := ret.Get(0).(func(relay.Identifier) (internal.Relayer, error)); ok { + return rf(id) + } + if rf, ok := ret.Get(0).(func(relay.Identifier) internal.Relayer); ok { + r0 = rf(id) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(internal.Relayer) + } + } + + if rf, ok := ret.Get(1).(func(relay.Identifier) error); ok { + r1 = rf(id) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +// LegacyCosmosChains provides a mock function with given fields: +func (_m *RelayerChainInteroperators) LegacyCosmosChains() cosmos.LegacyChainContainer { + ret := _m.Called() + + var r0 cosmos.LegacyChainContainer + if rf, ok := ret.Get(0).(func() cosmos.LegacyChainContainer); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(cosmos.LegacyChainContainer) + } + } + + return r0 +} + +// LegacyEVMChains provides a mock function with given fields: +func (_m *RelayerChainInteroperators) LegacyEVMChains() evm.LegacyChainContainer { + ret := _m.Called() + + var r0 evm.LegacyChainContainer + if rf, ok := ret.Get(0).(func() evm.LegacyChainContainer); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(evm.LegacyChainContainer) + } + } + + return r0 +} + +// List provides a mock function with given fields: filter +func (_m *RelayerChainInteroperators) List(filter chainlink.FilterFn) chainlink.RelayerChainInteroperators { + ret := _m.Called(filter) + + var r0 chainlink.RelayerChainInteroperators + if rf, ok := ret.Get(0).(func(chainlink.FilterFn) chainlink.RelayerChainInteroperators); ok { + r0 = rf(filter) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).(chainlink.RelayerChainInteroperators) + } + } + + return r0 +} + +// NodeStatuses provides a mock function with given fields: ctx, offset, limit, chainIDs +func (_m *RelayerChainInteroperators) NodeStatuses(ctx context.Context, offset int, limit int, chainIDs ...string) ([]types.NodeStatus, int, error) { + _va := make([]interface{}, len(chainIDs)) + for _i := range chainIDs { + _va[_i] = chainIDs[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, offset, limit) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 []types.NodeStatus + var r1 int + var r2 error + if rf, ok := ret.Get(0).(func(context.Context, int, int, ...string) ([]types.NodeStatus, int, error)); ok { + return rf(ctx, offset, limit, chainIDs...) + } + if rf, ok := ret.Get(0).(func(context.Context, int, int, ...string) []types.NodeStatus); ok { + r0 = rf(ctx, offset, limit, chainIDs...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]types.NodeStatus) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, int, int, ...string) int); ok { + r1 = rf(ctx, offset, limit, chainIDs...) + } else { + r1 = ret.Get(1).(int) + } + + if rf, ok := ret.Get(2).(func(context.Context, int, int, ...string) error); ok { + r2 = rf(ctx, offset, limit, chainIDs...) + } else { + r2 = ret.Error(2) + } + + return r0, r1, r2 +} + +// Services provides a mock function with given fields: +func (_m *RelayerChainInteroperators) Services() []services.ServiceCtx { + ret := _m.Called() + + var r0 []services.ServiceCtx + if rf, ok := ret.Get(0).(func() []services.ServiceCtx); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]services.ServiceCtx) + } + } + + return r0 +} + +// Slice provides a mock function with given fields: +func (_m *RelayerChainInteroperators) Slice() []internal.Relayer { + ret := _m.Called() + + var r0 []internal.Relayer + if rf, ok := ret.Get(0).(func() []internal.Relayer); ok { + r0 = rf() + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]internal.Relayer) + } + } + + return r0 +} + +type mockConstructorTestingTNewRelayerChainInteroperators interface { + mock.TestingT + Cleanup(func()) +} + +// NewRelayerChainInteroperators creates a new instance of RelayerChainInteroperators. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +func NewRelayerChainInteroperators(t mockConstructorTestingTNewRelayerChainInteroperators) *RelayerChainInteroperators { + mock := &RelayerChainInteroperators{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/core/services/chainlink/relayer_chain_interoperators.go b/core/services/chainlink/relayer_chain_interoperators.go new file mode 100644 index 00000000000..c523b689d10 --- /dev/null +++ b/core/services/chainlink/relayer_chain_interoperators.go @@ -0,0 +1,368 @@ +package chainlink + +import ( + "context" + "errors" + "fmt" + "sort" + "sync" + + "github.com/smartcontractkit/chainlink-relay/pkg/loop" + "github.com/smartcontractkit/chainlink-relay/pkg/types" + "github.com/smartcontractkit/chainlink/v2/core/chains" + "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/services" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" +) + +var ErrNoSuchRelayer = errors.New("relayer does not exist") + +// RelayerChainInteroperators +// encapsulates relayers and chains and is the primary entry point for +// the node to access relayers, get legacy chains associated to a relayer +// and get status about the chains and nodes +// +// note the generated mockery code incorrectly resolves dependencies and needs to be manually edited +// therefore this interface is not auto-generated. for reference use and edit the result: +// `go:generate mockery --quiet --name RelayerChainInteroperators --output ./mocks/ --case=underscore“` +type RelayerChainInteroperators interface { + Services() []services.ServiceCtx + + List(filter FilterFn) RelayerChainInteroperators + + LoopRelayerStorer + LegacyChainer + ChainsNodesStatuser +} + +// LoopRelayerStorer is key-value like interface for storing and +// retrieving [loop.Relayer] +type LoopRelayerStorer interface { + ocr2.RelayGetter + Slice() []loop.Relayer +} + +// LegacyChainer is an interface for getting legacy chains +// This will be deprecated/removed when products depend only +// on the relayer interface. +type LegacyChainer interface { + LegacyEVMChains() evm.LegacyChainContainer + LegacyCosmosChains() cosmos.LegacyChainContainer +} + +// Similar to [chains.ChainStatuser] but keyed by relay identifier instead of string +// TODO BCF-2441 remove this comment when chains.ChainStatus is no longer keyed. +type ChainStatuser interface { + ChainStatus(ctx context.Context, id relay.Identifier) (types.ChainStatus, error) + ChainStatuses(ctx context.Context, offset, limit int) ([]types.ChainStatus, int, error) +} + +// ChainsNodesStatuser report statuses about chains and nodes +type ChainsNodesStatuser interface { + ChainStatuser + chains.NodesStatuser +} + +var _ RelayerChainInteroperators = &CoreRelayerChainInteroperators{} + +// CoreRelayerChainInteroperators implements [RelayerChainInteroperators] +// as needed for the core [chainlink.Application] +type CoreRelayerChainInteroperators struct { + mu sync.Mutex + loopRelayers map[relay.Identifier]loop.Relayer + legacyChains legacyChains + + // we keep an explicit list of services because the legacy implementations have more than + // just the relayer service + srvs []services.ServiceCtx +} + +func NewCoreRelayerChainInteroperators(initFuncs ...CoreRelayerChainInitFunc) (*CoreRelayerChainInteroperators, error) { + cr := &CoreRelayerChainInteroperators{ + loopRelayers: make(map[relay.Identifier]loop.Relayer), + srvs: make([]services.ServiceCtx, 0), + } + for _, initFn := range initFuncs { + err2 := initFn(cr) + if err2 != nil { + return nil, err2 + } + } + return cr, nil +} + +// CoreRelayerChainInitFunc is a hook in the constructor to create relayers from a factory. +type CoreRelayerChainInitFunc func(op *CoreRelayerChainInteroperators) error + +// InitEVM is a option for instantiating evm relayers +func InitEVM(ctx context.Context, factory RelayerFactory, config EVMFactoryConfig) CoreRelayerChainInitFunc { + return func(op *CoreRelayerChainInteroperators) (err error) { + adapters, err2 := factory.NewEVM(ctx, config) + if err2 != nil { + return fmt.Errorf("failed to setup EVM relayer: %w", err2) + } + + legacyMap := make(map[string]evm.Chain) + var defaultChain evm.Chain + for id, a := range adapters { + // adapter is a service + op.srvs = append(op.srvs, a) + op.loopRelayers[id] = a + legacyMap[id.ChainID.String()] = a.Chain() + if a.Default() { + defaultChain = a.Chain() + } + + } + op.legacyChains.EVMChains = evm.NewLegacyChains(config.OperationalConfigs, legacyMap) + // TODO BCF-2510 this may not be necessary if EVM is not enabled by default + if defaultChain != nil { + op.legacyChains.EVMChains.SetDefault(defaultChain) + } + return nil + } +} + +// InitCosmos is a option for instantiating Cosmos relayers +func InitCosmos(ctx context.Context, factory RelayerFactory, config CosmosFactoryConfig) CoreRelayerChainInitFunc { + return func(op *CoreRelayerChainInteroperators) (err error) { + adapters, err2 := factory.NewCosmos(ctx, config) + if err2 != nil { + return fmt.Errorf("failed to setup Cosmos relayer: %w", err2) + } + legacyMap := make(map[string]cosmos.Chain) + for id, a := range adapters { + op.srvs = append(op.srvs, a) + op.loopRelayers[id] = a + legacyMap[id.ChainID.String()] = a.Chain() + } + op.legacyChains.CosmosChains = cosmos.NewLegacyChains(legacyMap) + + return nil + } +} + +// InitSolana is a option for instantiating Solana relayers +func InitSolana(ctx context.Context, factory RelayerFactory, config SolanaFactoryConfig) CoreRelayerChainInitFunc { + return func(op *CoreRelayerChainInteroperators) error { + solRelayers, err2 := factory.NewSolana(config.Keystore, config.SolanaConfigs) + if err2 != nil { + return fmt.Errorf("failed to setup Solana relayer: %w", err2) + } + for id, relayer := range solRelayers { + op.srvs = append(op.srvs, relayer) + op.loopRelayers[id] = relayer + } + + return nil + } +} + +// InitStarknet is a option for instantiating Starknet relayers +func InitStarknet(ctx context.Context, factory RelayerFactory, config StarkNetFactoryConfig) CoreRelayerChainInitFunc { + return func(op *CoreRelayerChainInteroperators) (err error) { + starkRelayers, err2 := factory.NewStarkNet(config.Keystore, config.StarknetConfigs) + if err2 != nil { + return fmt.Errorf("failed to setup StarkNet relayer: %w", err2) + } + for id, relayer := range starkRelayers { + op.srvs = append(op.srvs, relayer) + op.loopRelayers[id] = relayer + } + return nil + } +} + +// Get a [loop.Relayer] by id +func (rs *CoreRelayerChainInteroperators) Get(id relay.Identifier) (loop.Relayer, error) { + rs.mu.Lock() + defer rs.mu.Unlock() + lr, exist := rs.loopRelayers[id] + if !exist { + return nil, fmt.Errorf("%w: %s", ErrNoSuchRelayer, id) + } + return lr, nil +} + +// LegacyEVMChains returns a container with all the evm chains +// TODO BCF-2511 +func (rs *CoreRelayerChainInteroperators) LegacyEVMChains() evm.LegacyChainContainer { + rs.mu.Lock() + defer rs.mu.Unlock() + return rs.legacyChains.EVMChains +} + +// LegacyCosmosChains returns a container with all the cosmos chains +// TODO BCF-2511 +func (rs *CoreRelayerChainInteroperators) LegacyCosmosChains() cosmos.LegacyChainContainer { + rs.mu.Lock() + defer rs.mu.Unlock() + return rs.legacyChains.CosmosChains +} + +// ChainStatus gets [types.ChainStatus] +func (rs *CoreRelayerChainInteroperators) ChainStatus(ctx context.Context, id relay.Identifier) (types.ChainStatus, error) { + + lr, err := rs.Get(id) + if err != nil { + return types.ChainStatus{}, fmt.Errorf("%w: error getting chainstatus: %w", chains.ErrNotFound, err) + } + // this call is weird because the [loop.Relayer] interface still requires id + // but in this context the `relayer` should only have only id + // moreover, the `relayer` here is pinned to one chain we need to pass the chain id + return lr.ChainStatus(ctx, id.ChainID.String()) +} + +func (rs *CoreRelayerChainInteroperators) ChainStatuses(ctx context.Context, offset, limit int) ([]types.ChainStatus, int, error) { + // chain statuses are not dynamic; the call would be better named as ChainConfig or such. + + var ( + stats []types.ChainStatus + totalErr error + ) + rs.mu.Lock() + defer rs.mu.Unlock() + + relayerIds := make([]relay.Identifier, 0) + for rid := range rs.loopRelayers { + relayerIds = append(relayerIds, rid) + } + sort.Slice(relayerIds, func(i, j int) bool { + return relayerIds[i].String() < relayerIds[j].String() + }) + for _, rid := range relayerIds { + lr := rs.loopRelayers[rid] + // the relayer is chain specific; use the chain id and not the relayer id + stat, err := lr.ChainStatus(ctx, rid.ChainID.String()) + if err != nil { + totalErr = errors.Join(totalErr, err) + continue + } + stats = append(stats, stat) + } + + if totalErr != nil { + return nil, 0, totalErr + } + cnt := len(stats) + if len(stats) > limit+offset && limit > 0 { + return stats[offset : offset+limit], cnt, nil + } + return stats[offset:], cnt, nil +} + +func (rs *CoreRelayerChainInteroperators) Node(ctx context.Context, name string) (types.NodeStatus, error) { + // This implementation is round-about + // TODO BFC-2511, may be better in the loop.Relayer interface itself + stats, _, err := rs.NodeStatuses(ctx, 0, -1) + if err != nil { + return types.NodeStatus{}, err + } + for _, stat := range stats { + if stat.Name == name { + return stat, nil + } + } + return types.NodeStatus{}, chains.ErrNotFound +} + +// ids must be a string representation of relay.Identifier +// ids are a filter; if none are specificied, all are returned. +// TODO: BCF-2440/1 this signature can be changed to id relay.Identifier which is a much better API +func (rs *CoreRelayerChainInteroperators) NodeStatuses(ctx context.Context, offset, limit int, relayerIDs ...string) (nodes []types.NodeStatus, count int, err error) { + var ( + totalErr error + result []types.NodeStatus + ) + if len(relayerIDs) == 0 { + for rid, lr := range rs.loopRelayers { + stats, _, err := lr.NodeStatuses(ctx, offset, limit, rid.ChainID.String()) + if err != nil { + totalErr = errors.Join(totalErr, err) + continue + } + result = append(result, stats...) + } + } else { + for _, idStr := range relayerIDs { + rid := new(relay.Identifier) + err := rid.UnmarshalString(idStr) + if err != nil { + totalErr = errors.Join(totalErr, err) + continue + } + lr, exist := rs.loopRelayers[*rid] + if !exist { + totalErr = errors.Join(totalErr, fmt.Errorf("relayer %s does not exist", rid.Name())) + continue + } + nodeStats, _, err := lr.NodeStatuses(ctx, offset, limit, rid.ChainID.String()) + + if err != nil { + totalErr = errors.Join(totalErr, err) + continue + } + result = append(result, nodeStats...) + } + } + if totalErr != nil { + return nil, 0, totalErr + } + if len(result) > limit && limit > 0 { + return result[offset : offset+limit], limit, nil + } + return result[offset:], len(result[offset:]), nil +} + +type FilterFn func(id relay.Identifier) bool + +var AllRelayers = func(id relay.Identifier) bool { + return true +} + +// Returns true if the given network matches id.Network +func FilterRelayersByType(network relay.Network) func(id relay.Identifier) bool { + return func(id relay.Identifier) bool { + return id.Network == network + } +} + +// List returns all the [RelayerChainInteroperators] that match the [FilterFn]. +// A typical usage pattern to use [List] with [FilterByType] to obtain a set of [RelayerChainInteroperators] +// for a given chain +func (rs *CoreRelayerChainInteroperators) List(filter FilterFn) RelayerChainInteroperators { + + matches := make(map[relay.Identifier]loop.Relayer) + rs.mu.Lock() + for id, relayer := range rs.loopRelayers { + if filter(id) { + matches[id] = relayer + } + } + rs.mu.Unlock() + return &CoreRelayerChainInteroperators{ + loopRelayers: matches, + } +} + +// Returns a slice of [loop.Relayer]. A typically usage pattern to is +// use [List(criteria)].Slice() for range based operations +func (rs *CoreRelayerChainInteroperators) Slice() []loop.Relayer { + var result []loop.Relayer + for _, r := range rs.loopRelayers { + result = append(result, r) + } + return result +} +func (rs *CoreRelayerChainInteroperators) Services() (s []services.ServiceCtx) { + return rs.srvs +} + +// legacyChains encapsulates the chain-specific dependencies. Will be +// deprecated when chain-specific logic is removed from products. +type legacyChains struct { + EVMChains evm.LegacyChainContainer + CosmosChains cosmos.LegacyChainContainer +} diff --git a/core/services/chainlink/relayer_chain_interoperators_test.go b/core/services/chainlink/relayer_chain_interoperators_test.go new file mode 100644 index 00000000000..76ef03c6330 --- /dev/null +++ b/core/services/chainlink/relayer_chain_interoperators_test.go @@ -0,0 +1,419 @@ +package chainlink_test + +import ( + "errors" + "math/big" + "testing" + + "github.com/shopspring/decimal" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + coscfg "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos/config" + "github.com/smartcontractkit/chainlink-relay/pkg/loop" + relayutils "github.com/smartcontractkit/chainlink-relay/pkg/utils" + solcfg "github.com/smartcontractkit/chainlink-solana/pkg/solana/config" + stkcfg "github.com/smartcontractkit/chainlink-starknet/relayer/pkg/chainlink/config" + + "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/chains/solana" + "github.com/smartcontractkit/chainlink/v2/core/chains/starknet" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "github.com/smartcontractkit/chainlink/v2/plugins" + + evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" + configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +func TestCoreRelayerChainInteroperators(t *testing.T) { + + evmChainID1, evmChainID2 := utils.NewBig(big.NewInt(1)), utils.NewBig(big.NewInt(2)) + solanaChainID1, solanaChainID2 := "solana-id-1", "solana-id-2" + starknetChainID1, starknetChainID2 := "starknet-id-1", "starknet-id-2" + cosmosChainID1, cosmosChainID2 := "cosmos-id-1", "cosmos-id-2" + + cfg := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + + cfg := evmcfg.Defaults(evmChainID1) + node1_1 := evmcfg.Node{ + Name: ptr("Test node chain1:1"), + WSURL: models.MustParseURL("ws://localhost:8546"), + HTTPURL: models.MustParseURL("http://localhost:8546"), + SendOnly: ptr(false), + Order: ptr(int32(15)), + } + node1_2 := evmcfg.Node{ + Name: ptr("Test node chain1:2"), + WSURL: models.MustParseURL("ws://localhost:8547"), + HTTPURL: models.MustParseURL("http://localhost:8547"), + SendOnly: ptr(false), + Order: ptr(int32(36)), + } + node2_1 := evmcfg.Node{ + Name: ptr("Test node chain2:1"), + WSURL: models.MustParseURL("ws://localhost:8547"), + HTTPURL: models.MustParseURL("http://localhost:8547"), + SendOnly: ptr(false), + Order: ptr(int32(11)), + } + c.EVM[0] = &evmcfg.EVMConfig{ + ChainID: evmChainID1, + Enabled: ptr(true), + Chain: cfg, + Nodes: evmcfg.EVMNodes{&node1_1, &node1_2}, + } + id2 := utils.NewBig(big.NewInt(2)) + c.EVM = append(c.EVM, &evmcfg.EVMConfig{ + ChainID: evmChainID2, + Chain: evmcfg.Defaults(id2), + Enabled: ptr(true), + Nodes: evmcfg.EVMNodes{&node2_1}, + }) + + c.Solana = solana.SolanaConfigs{ + &solana.SolanaConfig{ + ChainID: &solanaChainID1, + Enabled: ptr(true), + Chain: solcfg.Chain{}, + Nodes: []*solcfg.Node{{ + Name: ptr("solana chain 1 node 1"), + URL: ((*relayutils.URL)(models.MustParseURL("http://localhost:8547").URL())), + }}, + }, + &solana.SolanaConfig{ + ChainID: &solanaChainID2, + Enabled: ptr(true), + Chain: solcfg.Chain{}, + Nodes: []*solcfg.Node{{ + Name: ptr("solana chain 2 node 1"), + URL: ((*relayutils.URL)(models.MustParseURL("http://localhost:8527").URL())), + }}, + }, + } + + c.Starknet = starknet.StarknetConfigs{ + &starknet.StarknetConfig{ + ChainID: &starknetChainID1, + Enabled: ptr(true), + Chain: stkcfg.Chain{}, + Nodes: []*stkcfg.Node{ + { + Name: ptr("starknet chain 1 node 1"), + URL: ((*relayutils.URL)(models.MustParseURL("http://localhost:8547").URL())), + }, + { + Name: ptr("starknet chain 1 node 2"), + URL: ((*relayutils.URL)(models.MustParseURL("http://localhost:8548").URL())), + }, + { + Name: ptr("starknet chain 1 node 3"), + URL: ((*relayutils.URL)(models.MustParseURL("http://localhost:8549").URL())), + }, + }, + }, + &starknet.StarknetConfig{ + ChainID: &starknetChainID2, + Enabled: ptr(true), + Chain: stkcfg.Chain{}, + Nodes: []*stkcfg.Node{ + { + Name: ptr("starknet chain 2 node 1"), + URL: ((*relayutils.URL)(models.MustParseURL("http://localhost:3547").URL())), + }, + }, + }, + } + + c.Cosmos = cosmos.CosmosConfigs{ + &cosmos.CosmosConfig{ + ChainID: &cosmosChainID1, + Enabled: ptr(true), + Chain: coscfg.Chain{ + GasLimitMultiplier: ptr(decimal.RequireFromString("1.55555")), + }, + Nodes: cosmos.CosmosNodes{ + &coscfg.Node{ + Name: ptr("cosmos chain 1 node 1"), + TendermintURL: (*relayutils.URL)(models.MustParseURL("http://localhost:9548").URL()), + }, + }, + }, + &cosmos.CosmosConfig{ + ChainID: &cosmosChainID2, + Enabled: ptr(true), + Chain: coscfg.Chain{ + GasLimitMultiplier: ptr(decimal.RequireFromString("0.777")), + }, + Nodes: cosmos.CosmosNodes{ + &coscfg.Node{ + Name: ptr("cosmos chain 2 node 1"), + TendermintURL: (*relayutils.URL)(models.MustParseURL("http://localhost:9598").URL()), + }, + }, + }, + } + }) + + db := pgtest.NewSqlxDB(t) + keyStore := cltest.NewKeyStore(t, db, cfg.Database()) + + lggr := logger.TestLogger(t) + + factory := chainlink.RelayerFactory{ + Logger: lggr, + DB: db, + QConfig: cfg.Database(), + LoopRegistry: plugins.NewLoopRegistry(lggr), + GRPCOpts: loop.GRPCOpts{}, + } + + testctx := testutils.Context(t) + + tests := []struct { + name string + initFuncs []chainlink.CoreRelayerChainInitFunc + + expectedEVMChainCnt int + expectedEVMNodeCnt int + expectedEVMRelayerIds []relay.Identifier + + expectedSolanaChainCnt int + expectedSolanaNodeCnt int + expectedSolanaRelayerIds []relay.Identifier + + expectedStarknetChainCnt int + expectedStarknetNodeCnt int + expectedStarknetRelayerIds []relay.Identifier + + expectedCosmosChainCnt int + expectedCosmosNodeCnt int + expectedCosmosRelayerIds []relay.Identifier + }{ + + {name: "2 evm chains with 3 nodes", + initFuncs: []chainlink.CoreRelayerChainInitFunc{ + chainlink.InitEVM(testctx, factory, chainlink.EVMFactoryConfig{ + RelayerConfig: evm.RelayerConfig{ + GeneralConfig: cfg, + EventBroadcaster: pg.NewNullEventBroadcaster(), + MailMon: &utils.MailboxMonitor{}, + }, + CSAETHKeystore: keyStore, + }), + }, + expectedEVMChainCnt: 2, + expectedEVMNodeCnt: 3, + expectedEVMRelayerIds: []relay.Identifier{ + {Network: relay.EVM, ChainID: relay.ChainID(evmChainID1.String())}, + {Network: relay.EVM, ChainID: relay.ChainID(evmChainID2.String())}, + }, + }, + {name: "2 solana chain with 2 node", + initFuncs: []chainlink.CoreRelayerChainInitFunc{ + chainlink.InitSolana(testctx, factory, chainlink.SolanaFactoryConfig{ + Keystore: keyStore.Solana(), + SolanaConfigs: cfg.SolanaConfigs()}), + }, + expectedSolanaChainCnt: 2, + expectedSolanaNodeCnt: 2, + expectedSolanaRelayerIds: []relay.Identifier{ + {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID1)}, + {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID2)}, + }, + }, + {name: "2 starknet chain with 4 nodes", + initFuncs: []chainlink.CoreRelayerChainInitFunc{ + chainlink.InitStarknet(testctx, factory, chainlink.StarkNetFactoryConfig{ + Keystore: keyStore.StarkNet(), + StarknetConfigs: cfg.StarknetConfigs()}), + }, + expectedStarknetChainCnt: 2, + expectedStarknetNodeCnt: 4, + expectedStarknetRelayerIds: []relay.Identifier{ + {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID1)}, + {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID2)}, + }, + }, + { + name: "2 cosmos chains with 2 nodes", + initFuncs: []chainlink.CoreRelayerChainInitFunc{ + chainlink.InitCosmos(testctx, factory, chainlink.CosmosFactoryConfig{ + Keystore: keyStore.Cosmos(), + CosmosConfigs: cfg.CosmosConfigs(), + EventBroadcaster: pg.NewNullEventBroadcaster()}), + }, + expectedCosmosChainCnt: 2, + expectedCosmosNodeCnt: 2, + expectedCosmosRelayerIds: []relay.Identifier{ + {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID1)}, + {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID2)}, + }, + }, + + {name: "all chains", + initFuncs: []chainlink.CoreRelayerChainInitFunc{chainlink.InitSolana(testctx, factory, chainlink.SolanaFactoryConfig{ + Keystore: keyStore.Solana(), + SolanaConfigs: cfg.SolanaConfigs()}), + chainlink.InitEVM(testctx, factory, chainlink.EVMFactoryConfig{ + RelayerConfig: evm.RelayerConfig{ + GeneralConfig: cfg, + EventBroadcaster: pg.NewNullEventBroadcaster(), + MailMon: &utils.MailboxMonitor{}, + }, + CSAETHKeystore: keyStore, + }), + chainlink.InitStarknet(testctx, factory, chainlink.StarkNetFactoryConfig{ + Keystore: keyStore.StarkNet(), + StarknetConfigs: cfg.StarknetConfigs()}), + chainlink.InitCosmos(testctx, factory, chainlink.CosmosFactoryConfig{ + Keystore: keyStore.Cosmos(), + CosmosConfigs: cfg.CosmosConfigs(), + EventBroadcaster: pg.NewNullEventBroadcaster(), + }), + }, + expectedEVMChainCnt: 2, + expectedEVMNodeCnt: 3, + expectedEVMRelayerIds: []relay.Identifier{ + {Network: relay.EVM, ChainID: relay.ChainID(evmChainID1.String())}, + {Network: relay.EVM, ChainID: relay.ChainID(evmChainID2.String())}, + }, + + expectedSolanaChainCnt: 2, + expectedSolanaNodeCnt: 2, + expectedSolanaRelayerIds: []relay.Identifier{ + {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID1)}, + {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID2)}, + }, + + expectedStarknetChainCnt: 2, + expectedStarknetNodeCnt: 4, + expectedStarknetRelayerIds: []relay.Identifier{ + {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID1)}, + {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID2)}, + }, + + expectedCosmosChainCnt: 2, + expectedCosmosNodeCnt: 2, + expectedCosmosRelayerIds: []relay.Identifier{ + {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID1)}, + {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID2)}, + }, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + cr, err := chainlink.NewCoreRelayerChainInteroperators(tt.initFuncs...) + require.NoError(t, err) + + expectedChainCnt := tt.expectedEVMChainCnt + tt.expectedCosmosChainCnt + tt.expectedSolanaChainCnt + tt.expectedStarknetChainCnt + allChainsStats, cnt, err := cr.ChainStatuses(testctx, 0, 0) + assert.NoError(t, err) + assert.Len(t, allChainsStats, expectedChainCnt) + assert.Equal(t, cnt, len(allChainsStats)) + assert.Len(t, cr.Slice(), expectedChainCnt) + + // should be one relayer per chain and one service per relayer + assert.Len(t, cr.Slice(), expectedChainCnt) + assert.Len(t, cr.Services(), expectedChainCnt) + + expectedNodeCnt := tt.expectedEVMNodeCnt + tt.expectedCosmosNodeCnt + tt.expectedSolanaNodeCnt + tt.expectedStarknetNodeCnt + allNodeStats, cnt, err := cr.NodeStatuses(testctx, 0, 0) + assert.NoError(t, err) + assert.Len(t, allNodeStats, expectedNodeCnt) + assert.Equal(t, cnt, len(allNodeStats)) + + for relayNetwork := range relay.SupportedRelays { + var expectedChainCnt, expectedNodeCnt int + switch relayNetwork { + case relay.EVM: + expectedChainCnt, expectedNodeCnt = tt.expectedEVMChainCnt, tt.expectedEVMNodeCnt + case relay.Cosmos: + expectedChainCnt, expectedNodeCnt = tt.expectedCosmosChainCnt, tt.expectedCosmosNodeCnt + case relay.Solana: + expectedChainCnt, expectedNodeCnt = tt.expectedSolanaChainCnt, tt.expectedSolanaNodeCnt + case relay.StarkNet: + expectedChainCnt, expectedNodeCnt = tt.expectedStarknetChainCnt, tt.expectedStarknetNodeCnt + default: + require.Fail(t, "untested relay network", relayNetwork) + } + + interops := cr.List(chainlink.FilterRelayersByType(relayNetwork)) + assert.Len(t, cr.List(chainlink.FilterRelayersByType(relayNetwork)).Slice(), expectedChainCnt) + if relayNetwork == relay.EVM { + assert.Len(t, cr.LegacyEVMChains().Slice(), expectedChainCnt) + } + if relayNetwork == relay.Cosmos { + assert.Len(t, cr.LegacyCosmosChains().Slice(), expectedChainCnt) + } + + nodesStats, cnt, err := interops.NodeStatuses(testctx, 0, 0) + assert.NoError(t, err) + assert.Len(t, nodesStats, expectedNodeCnt) + assert.Equal(t, cnt, len(nodesStats)) + + } + + allRelayerIds := [][]relay.Identifier{ + tt.expectedEVMRelayerIds, + tt.expectedCosmosRelayerIds, + tt.expectedSolanaRelayerIds, + tt.expectedStarknetRelayerIds, + } + + for _, chainSpecificRelayerIds := range allRelayerIds { + for _, wantId := range chainSpecificRelayerIds { + lr, err := cr.Get(wantId) + assert.NotNil(t, lr) + assert.NoError(t, err) + stat, err := cr.ChainStatus(testctx, wantId) + assert.NoError(t, err) + assert.Equal(t, wantId.ChainID.String(), stat.ID) + // check legacy chains for evm and cosmos + if wantId.Network == relay.EVM { + c, err := cr.LegacyEVMChains().Get(wantId.ChainID.String()) + assert.NoError(t, err) + assert.NotNil(t, c) + assert.Equal(t, wantId.ChainID.String(), c.ID().String()) + } + if wantId.Network == relay.Cosmos { + c, err := cr.LegacyCosmosChains().Get(wantId.ChainID.String()) + assert.NoError(t, err) + assert.NotNil(t, c) + assert.Equal(t, wantId.ChainID.String(), c.ID()) + } + } + } + + expectedMissing := relay.Identifier{Network: relay.Cosmos, ChainID: "not a chain id"} + unwanted, err := cr.Get(expectedMissing) + assert.Nil(t, unwanted) + assert.ErrorIs(t, err, chainlink.ErrNoSuchRelayer) + + }) + } + + t.Run("bad init func", func(t *testing.T) { + t.Parallel() + errBadFunc := errors.New("this is a bad func") + badFunc := func() chainlink.CoreRelayerChainInitFunc { + return func(op *chainlink.CoreRelayerChainInteroperators) error { + return errBadFunc + } + } + cr, err := chainlink.NewCoreRelayerChainInteroperators(badFunc()) + assert.Nil(t, cr) + assert.ErrorIs(t, err, errBadFunc) + }) +} + +func ptr[T any](t T) *T { return &t } diff --git a/core/services/chainlink/relayer_factory.go b/core/services/chainlink/relayer_factory.go new file mode 100644 index 00000000000..b7622e10e4e --- /dev/null +++ b/core/services/chainlink/relayer_factory.go @@ -0,0 +1,217 @@ +package chainlink + +import ( + "context" + "fmt" + + "github.com/pelletier/go-toml/v2" + "github.com/smartcontractkit/sqlx" + + pkgcosmos "github.com/smartcontractkit/chainlink-cosmos/pkg/cosmos" + "github.com/smartcontractkit/chainlink-relay/pkg/loop" + pkgsolana "github.com/smartcontractkit/chainlink-solana/pkg/solana" + pkgstarknet "github.com/smartcontractkit/chainlink-starknet/relayer/pkg/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/chains/cosmos" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/chains/solana" + "github.com/smartcontractkit/chainlink/v2/core/chains/starknet" + "github.com/smartcontractkit/chainlink/v2/core/config/env" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" + "github.com/smartcontractkit/chainlink/v2/plugins" +) + +type RelayerFactory struct { + logger.Logger + *sqlx.DB + pg.QConfig + *plugins.LoopRegistry + loop.GRPCOpts +} + +type EVMFactoryConfig struct { + evm.RelayerConfig + evmrelay.CSAETHKeystore +} + +func (r *RelayerFactory) NewEVM(ctx context.Context, config EVMFactoryConfig) (map[relay.Identifier]evmrelay.LoopRelayAdapter, error) { + // TODO impl EVM loop. For now always 'fallback' to an adapter and embedded chainset + + relayers := make(map[relay.Identifier]evmrelay.LoopRelayAdapter) + + // override some common opts with the factory values. this seems weird... maybe other signatures should change, or this should take a different type... + ccOpts := evm.ChainRelayExtenderConfig{ + + Logger: r.Logger, + DB: r.DB, + KeyStore: config.CSAETHKeystore.Eth(), + RelayerConfig: config.RelayerConfig, + } + + evmRelayExtenders, err := evmrelay.NewChainRelayerExtenders(ctx, ccOpts) + if err != nil { + return nil, err + } + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(evmRelayExtenders) + for _, ext := range evmRelayExtenders.Slice() { + relayID := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(ext.Chain().ID().String())} + chain, err := legacyChains.Get(relayID.ChainID.String()) + if err != nil { + return nil, err + } + relayer := evmrelay.NewLoopRelayAdapter(evmrelay.NewRelayer(ccOpts.DB, chain, r.QConfig, ccOpts.Logger, config.CSAETHKeystore, ccOpts.EventBroadcaster), ext) + relayers[relayID] = relayer + } + + return relayers, nil +} + +type SolanaFactoryConfig struct { + Keystore keystore.Solana + solana.SolanaConfigs +} + +func (r *RelayerFactory) NewSolana(ks keystore.Solana, chainCfgs solana.SolanaConfigs) (map[relay.Identifier]loop.Relayer, error) { + solanaRelayers := make(map[relay.Identifier]loop.Relayer) + var ( + solLggr = r.Logger.Named("Solana") + signer = &keystore.SolanaSigner{Solana: ks} + ) + + // create one relayer per chain id + for _, chainCfg := range chainCfgs { + relayId := relay.Identifier{Network: relay.Solana, ChainID: relay.ChainID(*chainCfg.ChainID)} + // all the lower level APIs expect chainsets. create a single valued set per id + singleChainCfg := solana.SolanaConfigs{chainCfg} + + if cmdName := env.SolanaPluginCmd.Get(); cmdName != "" { + + // setup the solana relayer to be a LOOP + tomls, err := toml.Marshal(struct { + Solana solana.SolanaConfigs + }{Solana: singleChainCfg}) + if err != nil { + return nil, fmt.Errorf("failed to marshal Solana configs: %w", err) + } + + solCmdFn, err := plugins.NewCmdFactory(r.Register, plugins.CmdConfig{ + ID: solLggr.Name(), + Cmd: cmdName, + }) + if err != nil { + return nil, fmt.Errorf("failed to create Solana LOOP command: %w", err) + } + solanaRelayers[relayId] = loop.NewRelayerService(solLggr, r.GRPCOpts, solCmdFn, string(tomls), signer) + + } else { + // fallback to embedded chainset + opts := solana.ChainSetOpts{ + Logger: solLggr, + KeyStore: signer, + Configs: solana.NewConfigs(singleChainCfg), + } + chainSet, err := solana.NewChainSet(opts, singleChainCfg) + if err != nil { + return nil, fmt.Errorf("failed to load Solana chainset: %w", err) + } + solanaRelayers[relayId] = relay.NewRelayerAdapter(pkgsolana.NewRelayer(solLggr, chainSet), chainSet) + } + } + return solanaRelayers, nil +} + +type StarkNetFactoryConfig struct { + Keystore keystore.StarkNet + starknet.StarknetConfigs +} + +func (r *RelayerFactory) NewStarkNet(ks keystore.StarkNet, chainCfgs starknet.StarknetConfigs) (map[relay.Identifier]loop.Relayer, error) { + starknetRelayers := make(map[relay.Identifier]loop.Relayer) + + var ( + starkLggr = r.Logger.Named("StarkNet") + loopKs = &keystore.StarknetLooppSigner{StarkNet: ks} + ) + + // create one relayer per chain id + for _, chainCfg := range chainCfgs { + relayId := relay.Identifier{Network: relay.StarkNet, ChainID: relay.ChainID(*chainCfg.ChainID)} + // all the lower level APIs expect chainsets. create a single valued set per id + singleChainCfg := starknet.StarknetConfigs{chainCfg} + + if cmdName := env.StarknetPluginCmd.Get(); cmdName != "" { + // setup the starknet relayer to be a LOOP + tomls, err := toml.Marshal(struct { + Starknet starknet.StarknetConfigs + }{Starknet: singleChainCfg}) + if err != nil { + return nil, fmt.Errorf("failed to marshal StarkNet configs: %w", err) + } + + starknetCmdFn, err := plugins.NewCmdFactory(r.Register, plugins.CmdConfig{ + ID: starkLggr.Name(), + Cmd: cmdName, + }) + if err != nil { + return nil, fmt.Errorf("failed to create StarkNet LOOP command: %w", err) + } + // the starknet relayer service has a delicate keystore dependency. the value that is passed to NewRelayerService must + // be compatible with instantiating a starknet transaction manager KeystoreAdapter within the LOOPp executable. + starknetRelayers[relayId] = loop.NewRelayerService(starkLggr, r.GRPCOpts, starknetCmdFn, string(tomls), loopKs) + } else { + // fallback to embedded chainset + opts := starknet.ChainSetOpts{ + Logger: starkLggr, + KeyStore: loopKs, + Configs: starknet.NewConfigs(singleChainCfg), + } + chainSet, err := starknet.NewChainSet(opts, singleChainCfg) + if err != nil { + return nil, fmt.Errorf("failed to load StarkNet chainset: %w", err) + } + starknetRelayers[relayId] = relay.NewRelayerAdapter(pkgstarknet.NewRelayer(starkLggr, chainSet), chainSet) + } + } + return starknetRelayers, nil + +} + +type CosmosFactoryConfig struct { + Keystore keystore.Cosmos + cosmos.CosmosConfigs + EventBroadcaster pg.EventBroadcaster +} + +func (r *RelayerFactory) NewCosmos(ctx context.Context, config CosmosFactoryConfig) (map[relay.Identifier]cosmos.LoopRelayerChainer, error) { + relayers := make(map[relay.Identifier]cosmos.LoopRelayerChainer) + + var lggr = r.Logger.Named("Cosmos") + + // create one relayer per chain id + for _, chainCfg := range config.CosmosConfigs { + relayId := relay.Identifier{Network: relay.Cosmos, ChainID: relay.ChainID(*chainCfg.ChainID)} + // all the lower level APIs expect chainsets. create a single valued set per id + // TODO: Cosmos LOOPp impl. For now, use relayer adapter + + opts := cosmos.ChainSetOpts{ + QueryConfig: r.QConfig, + Logger: lggr.Named(relayId.ChainID.String()), + DB: r.DB, + KeyStore: config.Keystore, + EventBroadcaster: config.EventBroadcaster, + } + opts.Configs = cosmos.NewConfigs(cosmos.CosmosConfigs{chainCfg}) + singleChainChainSet, err := cosmos.NewSingleChainSet(opts, chainCfg) + if err != nil { + return nil, fmt.Errorf("failed to load Cosmos chain %q: %w", relayId, err) + } + + relayers[relayId] = cosmos.NewLoopRelayerSingleChain(pkgcosmos.NewRelayer(lggr, singleChainChainSet), singleChainChainSet) + + } + return relayers, nil + +} diff --git a/core/services/cron/cron_test.go b/core/services/cron/cron_test.go index 5ce0414bf1d..1ea37578fc8 100644 --- a/core/services/cron/cron_test.go +++ b/core/services/cron/cron_test.go @@ -19,6 +19,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" pipelinemocks "github.com/smartcontractkit/chainlink/v2/core/services/pipeline/mocks" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) func TestCronV2Pipeline(t *testing.T) { @@ -27,11 +28,12 @@ func TestCronV2Pipeline(t *testing.T) { db := pgtest.NewSqlxDB(t) keyStore := cltest.NewKeyStore(t, db, cfg.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: evmtest.NewEthClientMockWithDefaultChain(t), KeyStore: keyStore.Eth()}) + relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: evmtest.NewEthClientMockWithDefaultChain(t), KeyStore: keyStore.Eth()}) lggr := logger.TestLogger(t) orm := pipeline.NewORM(db, lggr, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, lggr, cfg.Database()) - jobORM := job.NewORM(db, cc, orm, btORM, keyStore, lggr, cfg.Database()) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + jobORM := job.NewORM(db, legacyChains, orm, btORM, keyStore, lggr, cfg.Database()) jb := &job.Job{ Type: job.Cron, diff --git a/core/services/directrequest/delegate.go b/core/services/directrequest/delegate.go index 8d86f044172..4e2ca1e1899 100644 --- a/core/services/directrequest/delegate.go +++ b/core/services/directrequest/delegate.go @@ -29,7 +29,7 @@ type ( pipelineRunner pipeline.Runner pipelineORM pipeline.ORM chHeads chan *evmtypes.Head - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer mailMon *utils.MailboxMonitor } @@ -45,16 +45,16 @@ func NewDelegate( logger logger.Logger, pipelineRunner pipeline.Runner, pipelineORM pipeline.ORM, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, mailMon *utils.MailboxMonitor, ) *Delegate { return &Delegate{ - logger.Named("DirectRequest"), - pipelineRunner, - pipelineORM, - make(chan *evmtypes.Head, 1), - chainSet, - mailMon, + logger: logger.Named("DirectRequest"), + pipelineRunner: pipelineRunner, + pipelineORM: pipelineORM, + chHeads: make(chan *evmtypes.Head, 1), + legacyChains: legacyChains, + mailMon: mailMon, } } @@ -72,7 +72,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC if jb.DirectRequestSpec == nil { return nil, errors.Errorf("DirectRequest: directrequest.Delegate expects a *job.DirectRequestSpec to be present, got %v", jb) } - chain, err := d.chainSet.Get(jb.DirectRequestSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(jb.DirectRequestSpec.EVMChainID.String()) if err != nil { return nil, err } diff --git a/core/services/directrequest/delegate_test.go b/core/services/directrequest/delegate_test.go index c79f5caaafb..68b447e6652 100644 --- a/core/services/directrequest/delegate_test.go +++ b/core/services/directrequest/delegate_test.go @@ -30,6 +30,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" pipeline_mocks "github.com/smartcontractkit/chainlink/v2/core/services/pipeline/mocks" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -43,10 +44,11 @@ func TestDelegate_ServicesForSpec(t *testing.T) { }) keyStore := cltest.NewKeyStore(t, db, cfg.Database()) mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, MailMon: mailMon, KeyStore: keyStore.Eth()}) + relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, MailMon: mailMon, KeyStore: keyStore.Eth()}) lggr := logger.TestLogger(t) - delegate := directrequest.NewDelegate(lggr, runner, nil, cc, mailMon) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + delegate := directrequest.NewDelegate(lggr, runner, nil, legacyChains, mailMon) t.Run("Spec without DirectRequestSpec", func(t *testing.T) { spec := job.Job{} @@ -82,13 +84,13 @@ func NewDirectRequestUniverseWithConfig(t *testing.T, cfg chainlink.GeneralConfi db := pgtest.NewSqlxDB(t) keyStore := cltest.NewKeyStore(t, db, cfg.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, LogBroadcaster: broadcaster, MailMon: mailMon, KeyStore: keyStore.Eth()}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, LogBroadcaster: broadcaster, MailMon: mailMon, KeyStore: keyStore.Eth()}) lggr := logger.TestLogger(t) orm := pipeline.NewORM(db, lggr, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, lggr, cfg.Database()) - - jobORM := job.NewORM(db, cc, orm, btORM, keyStore, lggr, cfg.Database()) - delegate := directrequest.NewDelegate(lggr, runner, orm, cc, mailMon) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jobORM := job.NewORM(db, legacyChains, orm, btORM, keyStore, lggr, cfg.Database()) + delegate := directrequest.NewDelegate(lggr, runner, orm, legacyChains, mailMon) jb := cltest.MakeDirectRequestJobSpec(t) jb.ExternalJobID = uuid.New() diff --git a/core/services/feeds/orm_test.go b/core/services/feeds/orm_test.go index 22850c6d703..b9180651160 100644 --- a/core/services/feeds/orm_test.go +++ b/core/services/feeds/orm_test.go @@ -22,6 +22,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocr" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/testdata/testspecs" "github.com/smartcontractkit/chainlink/v2/core/utils" "github.com/smartcontractkit/chainlink/v2/core/utils/crypto" @@ -1467,13 +1468,14 @@ func createJob(t *testing.T, db *sqlx.DB, externalJobID uuid.UUID) *job.Job { t.Helper() var ( - config = configtest.NewGeneralConfig(t, nil) - keyStore = cltest.NewKeyStore(t, db, config.Database()) - lggr = logger.TestLogger(t) - pipelineORM = pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) - bridgeORM = bridges.NewORM(db, lggr, config.Database()) - cc = evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm = job.NewORM(db, cc, pipelineORM, bridgeORM, keyStore, lggr, config.Database()) + config = configtest.NewGeneralConfig(t, nil) + keyStore = cltest.NewKeyStore(t, db, config.Database()) + lggr = logger.TestLogger(t) + pipelineORM = pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) + bridgeORM = bridges.NewORM(db, lggr, config.Database()) + relayExtenders = evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains = evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm = job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, lggr, config.Database()) ) require.NoError(t, keyStore.OCR().Add(cltest.DefaultOCRKey)) @@ -1485,7 +1487,7 @@ func createJob(t *testing.T, db *sqlx.DB, externalJobID uuid.UUID) *job.Job { _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb, err := ocr.ValidatedOracleSpecToml(cc, + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: externalJobID.String(), TransmitterAddress: address.Hex(), diff --git a/core/services/feeds/service.go b/core/services/feeds/service.go index 112750ef1ec..ca0dcbb06cc 100644 --- a/core/services/feeds/service.go +++ b/core/services/feeds/service.go @@ -113,7 +113,7 @@ type service struct { ocrCfg OCRConfig ocr2cfg OCR2Config connMgr ConnectionsManager - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer lggr logger.Logger version string } @@ -130,7 +130,7 @@ func NewService( ocrCfg OCRConfig, ocr2Cfg OCR2Config, dbCfg pg.QConfig, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, lggr logger.Logger, version string, ) *service { @@ -149,7 +149,7 @@ func NewService( ocrCfg: ocrCfg, ocr2cfg: ocr2Cfg, connMgr: newConnectionsManager(lggr), - chainSet: chainSet, + legacyChains: legacyChains, lggr: lggr, version: version, } @@ -1094,7 +1094,7 @@ func (s *service) generateJob(spec string) (*job.Job, error) { if !s.ocrCfg.Enabled() { return nil, ErrOCRDisabled } - js, err = ocr.ValidatedOracleSpecToml(s.chainSet, spec) + js, err = ocr.ValidatedOracleSpecToml(s.legacyChains, spec) case job.OffchainReporting2: if !s.ocr2cfg.Enabled() { return nil, ErrOCR2Disabled diff --git a/core/services/feeds/service_test.go b/core/services/feeds/service_test.go index ebe3037eeac..3b9bedaf023 100644 --- a/core/services/feeds/service_test.go +++ b/core/services/feeds/service_test.go @@ -31,6 +31,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/p2pkey" ksmocks "github.com/smartcontractkit/chainlink/v2/core/services/keystore/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/versioning" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -147,7 +148,7 @@ type TestService struct { p2pKeystore *ksmocks.P2P ocr1Keystore *ksmocks.OCR ocr2Keystore *ksmocks.OCR2 - cc evm.ChainSet + legacyChains evm.LegacyChainContainer } func setupTestService(t *testing.T) *TestService { @@ -178,14 +179,15 @@ func setupTestServiceCfg(t *testing.T, overrideCfg func(c *chainlink.Config, s * keyStore := new(ksmocks.Master) scopedConfig := evmtest.NewChainScopedConfig(t, gcfg) ethKeyStore := cltest.NewKeyStore(t, db, gcfg.Database()).Eth() - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{GeneralConfig: gcfg, + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{GeneralConfig: gcfg, HeadTracker: headtracker.NullTracker, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) keyStore.On("Eth").Return(ethKeyStore) keyStore.On("CSA").Return(csaKeystore) keyStore.On("P2P").Return(p2pKeystore) keyStore.On("OCR").Return(ocr1Keystore) keyStore.On("OCR2").Return(ocr2Keystore) - svc := feeds.NewService(orm, jobORM, db, spawner, keyStore, scopedConfig.Insecure(), scopedConfig.JobPipeline(), scopedConfig.OCR(), scopedConfig.OCR2(), scopedConfig.Database(), cc, lggr, "1.0.0") + svc := feeds.NewService(orm, jobORM, db, spawner, keyStore, scopedConfig.Insecure(), scopedConfig.JobPipeline(), scopedConfig.OCR(), scopedConfig.OCR2(), scopedConfig.Database(), legacyChains, lggr, "1.0.0") svc.SetConnectionsManager(connMgr) return &TestService{ @@ -199,7 +201,7 @@ func setupTestServiceCfg(t *testing.T, overrideCfg func(c *chainlink.Config, s * p2pKeystore: p2pKeystore, ocr1Keystore: ocr1Keystore, ocr2Keystore: ocr2Keystore, - cc: cc, + legacyChains: legacyChains, } } diff --git a/core/services/fluxmonitorv2/delegate.go b/core/services/fluxmonitorv2/delegate.go index 286555e6675..0564eecaee4 100644 --- a/core/services/fluxmonitorv2/delegate.go +++ b/core/services/fluxmonitorv2/delegate.go @@ -21,7 +21,7 @@ type Delegate struct { jobORM job.ORM pipelineORM pipeline.ORM pipelineRunner pipeline.Runner - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer lggr logger.Logger } @@ -34,17 +34,17 @@ func NewDelegate( pipelineORM pipeline.ORM, pipelineRunner pipeline.Runner, db *sqlx.DB, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, lggr logger.Logger, ) *Delegate { return &Delegate{ - db, - ethKeyStore, - jobORM, - pipelineORM, - pipelineRunner, - chainSet, - lggr.Named("FluxMonitor"), + db: db, + ethKeyStore: ethKeyStore, + jobORM: jobORM, + pipelineORM: pipelineORM, + pipelineRunner: pipelineRunner, + legacyChains: legacyChains, + lggr: lggr.Named("FluxMonitor"), } } @@ -63,7 +63,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) (services []job if jb.FluxMonitorSpec == nil { return nil, errors.Errorf("Delegate expects a *job.FluxMonitorSpec to be present, got %v", jb) } - chain, err := d.chainSet.Get(jb.FluxMonitorSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(jb.FluxMonitorSpec.EVMChainID.String()) if err != nil { return nil, err } diff --git a/core/services/fluxmonitorv2/integrations_test.go b/core/services/fluxmonitorv2/integrations_test.go index 24d6c86a9c8..e76d859e81b 100644 --- a/core/services/fluxmonitorv2/integrations_test.go +++ b/core/services/fluxmonitorv2/integrations_test.go @@ -529,7 +529,7 @@ func TestFluxMonitor_Deviation(t *testing.T) { // Waiting for flux monitor to finish Register process in log broadcaster // and then to have log broadcaster backfill logs after the debounceResubscribe period of ~ 1 sec g.Eventually(func() uint32 { - lb := evmtest.MustGetDefaultChain(t, app.GetChains().EVM).LogBroadcaster() + lb := evmtest.MustGetDefaultChain(t, app.GetRelayers().LegacyEVMChains()).LogBroadcaster() return lb.(log.BroadcasterInTest).TrackedAddressesCount() }, testutils.WaitTimeout(t), 200*time.Millisecond).Should(gomega.BeNumerically(">=", 1)) @@ -680,7 +680,7 @@ ds1 -> ds1_parse // Waiting for flux monitor to finish Register process in log broadcaster // and then to have log broadcaster backfill logs after the debounceResubscribe period of ~ 1 sec g.Eventually(func() uint32 { - lb := evmtest.MustGetDefaultChain(t, app.GetChains().EVM).LogBroadcaster() + lb := evmtest.MustGetDefaultChain(t, app.GetRelayers().LegacyEVMChains()).LogBroadcaster() return lb.(log.BroadcasterInTest).TrackedAddressesCount() }, testutils.WaitTimeout(t), 200*time.Millisecond).Should(gomega.BeNumerically(">=", 2)) diff --git a/core/services/fluxmonitorv2/orm_test.go b/core/services/fluxmonitorv2/orm_test.go index 90b5c5a4308..f02ebb61f60 100644 --- a/core/services/fluxmonitorv2/orm_test.go +++ b/core/services/fluxmonitorv2/orm_test.go @@ -22,6 +22,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/fluxmonitorv2" "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) func TestORM_MostRecentFluxMonitorRoundID(t *testing.T) { @@ -93,10 +94,11 @@ func TestORM_UpdateFluxMonitorRoundStats(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) bridgeORM := bridges.NewORM(db, lggr, cfg.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{GeneralConfig: cfg, DB: db, KeyStore: keyStore.Eth()}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{GeneralConfig: cfg, DB: db, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) // Instantiate a real job ORM because we need to create a job to satisfy // a check in pipeline.CreateRun - jobORM := job.NewORM(db, cc, pipelineORM, bridgeORM, keyStore, lggr, cfg.Database()) + jobORM := job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, lggr, cfg.Database()) orm := newORM(t, db, cfg.Database(), nil) address := testutils.NewAddress() diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index 9085cc0b04c..70790d95cf5 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -34,6 +34,7 @@ import ( threshold_mocks "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/threshold/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" evmrelay_mocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types/mocks" s4_mocks "github.com/smartcontractkit/chainlink/v2/core/services/s4/mocks" @@ -86,8 +87,10 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe db := pgtest.NewSqlxDB(t) kst := cltest.NewKeyStore(t, db, cfg.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, KeyStore: kst.Eth(), LogBroadcaster: broadcaster, MailMon: mailMon}) - chain := cc.Chains()[0] + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, KeyStore: kst.Eth(), LogBroadcaster: broadcaster, MailMon: mailMon}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + + chain := legacyChains.Slice()[0] lggr := logger.TestLogger(t) pluginORM := functions_mocks.NewORM(t) diff --git a/core/services/gateway/delegate.go b/core/services/gateway/delegate.go index ef7104d666f..c42e61b8785 100644 --- a/core/services/gateway/delegate.go +++ b/core/services/gateway/delegate.go @@ -16,15 +16,15 @@ import ( ) type Delegate struct { - chains evm.ChainSet - ks keystore.Eth - lggr logger.Logger + legacyChains evm.LegacyChainContainer + ks keystore.Eth + lggr logger.Logger } var _ job.Delegate = (*Delegate)(nil) -func NewDelegate(chains evm.ChainSet, ks keystore.Eth, lggr logger.Logger) *Delegate { - return &Delegate{chains: chains, ks: ks, lggr: lggr} +func NewDelegate(legacyChains evm.LegacyChainContainer, ks keystore.Eth, lggr logger.Logger) *Delegate { + return &Delegate{legacyChains: legacyChains, ks: ks, lggr: lggr} } func (d *Delegate) JobType() job.Type { @@ -47,7 +47,7 @@ func (d *Delegate) ServicesForSpec(spec job.Job, qopts ...pg.QOpt) (services []j if err2 != nil { return nil, errors.Wrap(err2, "unmarshal gateway config") } - handlerFactory := NewHandlerFactory(d.chains, d.lggr) + handlerFactory := NewHandlerFactory(d.legacyChains, d.lggr) gateway, err := NewGatewayFromConfig(&gatewayConfig, handlerFactory, d.lggr) if err != nil { return nil, err diff --git a/core/services/gateway/handler_factory.go b/core/services/gateway/handler_factory.go index a0107214a23..519de608a0f 100644 --- a/core/services/gateway/handler_factory.go +++ b/core/services/gateway/handler_factory.go @@ -17,20 +17,20 @@ const ( ) type handlerFactory struct { - chains evm.ChainSet - lggr logger.Logger + legacyChains evm.LegacyChainContainer + lggr logger.Logger } var _ HandlerFactory = (*handlerFactory)(nil) -func NewHandlerFactory(chains evm.ChainSet, lggr logger.Logger) HandlerFactory { - return &handlerFactory{chains, lggr} +func NewHandlerFactory(legacyChains evm.LegacyChainContainer, lggr logger.Logger) HandlerFactory { + return &handlerFactory{legacyChains, lggr} } func (hf *handlerFactory) NewHandler(handlerType HandlerType, handlerConfig json.RawMessage, donConfig *config.DONConfig, don handlers.DON) (handlers.Handler, error) { switch handlerType { case FunctionsHandlerType: - return functions.NewFunctionsHandlerFromConfig(handlerConfig, donConfig, don, hf.chains, hf.lggr) + return functions.NewFunctionsHandlerFromConfig(handlerConfig, donConfig, don, hf.legacyChains, hf.lggr) case DummyHandlerType: return handlers.NewDummyHandler(donConfig, don, hf.lggr) default: diff --git a/core/services/gateway/handlers/functions/handler.functions.go b/core/services/gateway/handlers/functions/handler.functions.go index b526112745f..aee099e6cee 100644 --- a/core/services/gateway/handlers/functions/handler.functions.go +++ b/core/services/gateway/handlers/functions/handler.functions.go @@ -4,7 +4,6 @@ import ( "context" "encoding/json" "errors" - "math/big" "time" "github.com/ethereum/go-ethereum/common" @@ -52,7 +51,7 @@ type PendingSecretsRequest struct { var _ handlers.Handler = (*functionsHandler)(nil) -func NewFunctionsHandlerFromConfig(handlerConfig json.RawMessage, donConfig *config.DONConfig, don handlers.DON, chains evm.ChainSet, lggr logger.Logger) (handlers.Handler, error) { +func NewFunctionsHandlerFromConfig(handlerConfig json.RawMessage, donConfig *config.DONConfig, don handlers.DON, legacyChains evm.LegacyChainContainer, lggr logger.Logger) (handlers.Handler, error) { var cfg FunctionsHandlerConfig err := json.Unmarshal(handlerConfig, &cfg) if err != nil { @@ -60,16 +59,12 @@ func NewFunctionsHandlerFromConfig(handlerConfig json.RawMessage, donConfig *con } var allowlist OnchainAllowlist if cfg.OnchainAllowlist != nil { - chainId, ok := big.NewInt(0).SetString(cfg.OnchainAllowlistChainID, 10) - if !ok { - return nil, errors.New("invalid chain ID") - } - chain, err := chains.Get(chainId) - if err != nil { + chain, err2 := legacyChains.Get(cfg.OnchainAllowlistChainID) + if err2 != nil { return nil, err } - allowlist, err = NewOnchainAllowlist(chain.Client(), *cfg.OnchainAllowlist, lggr) - if err != nil { + allowlist, err2 = NewOnchainAllowlist(chain.Client(), *cfg.OnchainAllowlist, lggr) + if err2 != nil { return nil, err } } diff --git a/core/services/job/helpers_test.go b/core/services/job/helpers_test.go index 281a23357ba..21f3a8daa99 100644 --- a/core/services/job/helpers_test.go +++ b/core/services/job/helpers_test.go @@ -26,6 +26,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" "github.com/smartcontractkit/chainlink/v2/core/services/ocr" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/store/models" ) @@ -218,8 +219,9 @@ func makeMinimalHTTPOracleSpec(t *testing.T, db *sqlx.DB, cfg chainlink.GeneralC } s := fmt.Sprintf(minimalNonBootstrapTemplate, contractAddress, transmitterAddress, keyBundle, fetchUrl, timeout) keyStore := cltest.NewKeyStore(t, db, pgtest.NewQConfig(true)) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, Client: evmtest.NewEthClientMockWithDefaultChain(t), GeneralConfig: cfg, KeyStore: keyStore.Eth()}) - _, err := ocr.ValidatedOracleSpecToml(cc, s) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: evmtest.NewEthClientMockWithDefaultChain(t), GeneralConfig: cfg, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + _, err := ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &os) require.NoError(t, err) diff --git a/core/services/job/job_orm_test.go b/core/services/job/job_orm_test.go index 3ea11f25ea9..7c10337159a 100644 --- a/core/services/job/job_orm_test.go +++ b/core/services/job/job_orm_test.go @@ -37,6 +37,7 @@ import ( ocr2validate "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate" "github.com/smartcontractkit/chainlink/v2/core/services/ocrbootstrap" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/vrf/vrfcommon" "github.com/smartcontractkit/chainlink/v2/core/services/webhook" "github.com/smartcontractkit/chainlink/v2/core/testdata/testspecs" @@ -81,8 +82,9 @@ func TestORM(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: ethKeyStore}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) borm := bridges.NewORM(db, logger.TestLogger(t), config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -313,8 +315,9 @@ func TestORM_DeleteJob_DeletesAssociatedRecords(t *testing.T) { lggr := logger.TestLogger(t) pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) scopedConfig := evmtest.NewChainScopedConfig(t, config) korm := keeper.NewORM(db, logger.TestLogger(t), scopedConfig.Database()) @@ -323,7 +326,7 @@ func TestORM_DeleteJob_DeletesAssociatedRecords(t *testing.T) { _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb, err := ocr.ValidatedOracleSpecToml(cc, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ TransmitterAddress: address.Hex(), DS1BridgeName: bridge.Name.String(), DS2BridgeName: bridge2.Name.String(), @@ -412,8 +415,9 @@ func TestORM_CreateJob_VRFV2(t *testing.T) { lggr := logger.TestLogger(t) pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) fromAddresses := []string{cltest.NewEIP55Address().String(), cltest.NewEIP55Address().String()} jb, err := vrfcommon.ValidatedVRFSpec(testspecs.GenerateVRFSpec( @@ -493,8 +497,10 @@ func TestORM_CreateJob_VRFV2Plus(t *testing.T) { lggr := logger.TestLogger(t) pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) fromAddresses := []string{cltest.NewEIP55Address().String(), cltest.NewEIP55Address().String()} jb, err := vrfcommon.ValidatedVRFSpec(testspecs.GenerateVRFSpec( @@ -577,8 +583,9 @@ func TestORM_CreateJob_OCRBootstrap(t *testing.T) { lggr := logger.TestLogger(t) pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := ocrbootstrap.ValidatedBootstrapSpecToml(testspecs.OCRBootstrapSpec) require.NoError(t, err) @@ -616,8 +623,9 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) defaultChainID := config.DefaultChainID() @@ -634,7 +642,7 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { TransmitterAddress: address.Hex(), }) - jb, err := ocr.ValidatedOracleSpecToml(cc, spec.Toml()) + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, spec.Toml()) require.NoError(t, err) // 2nd job with no Chain ID @@ -644,7 +652,7 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { DS2BridgeName: bridge2.Name.String(), TransmitterAddress: address.Hex(), }) - jb2, err := ocr.ValidatedOracleSpecToml(cc, spec2.Toml()) + jb2, err := ocr.ValidatedOracleSpecToml(legacyChains, spec2.Toml()) require.NoError(t, err) // Default Chain Job @@ -657,7 +665,7 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { TransmitterAddress: address.Hex(), JobID: externalJobID.UUID.String(), }) - jb3, err := ocr.ValidatedOracleSpecToml(cc, spec3.Toml()) + jb3, err := ocr.ValidatedOracleSpecToml(legacyChains, spec3.Toml()) require.NoError(t, err) // Custom Chain Job @@ -670,7 +678,7 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { TransmitterAddress: address.Hex(), JobID: externalJobID.UUID.String(), }) - jb4, err := ocr.ValidatedOracleSpecToml(cc, spec4.Toml()) + jb4, err := ocr.ValidatedOracleSpecToml(legacyChains, spec4.Toml()) require.NoError(t, err) t.Run("with legacy NULL chain id", func(t *testing.T) { @@ -712,7 +720,7 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { externalJobID = uuid.NullUUID{UUID: uuid.New(), Valid: true} spec3.JobID = externalJobID.UUID.String() - jb3a, err := ocr.ValidatedOracleSpecToml(cc, spec3.Toml()) + jb3a, err := ocr.ValidatedOracleSpecToml(legacyChains, spec3.Toml()) require.NoError(t, err) err = jobORM.CreateJob(&jb3a) // Try to add duplicate job with default id require.Error(t, err) @@ -720,7 +728,7 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { externalJobID = uuid.NullUUID{UUID: uuid.New(), Valid: true} spec4.JobID = externalJobID.UUID.String() - jb5, err := ocr.ValidatedOracleSpecToml(cc, spec4.Toml()) + jb5, err := ocr.ValidatedOracleSpecToml(legacyChains, spec4.Toml()) require.NoError(t, err) err = jobORM.CreateJob(&jb5) // Try to add duplicate job with custom id @@ -749,8 +757,9 @@ func TestORM_CreateJob_OCR2_DuplicatedContractAddress(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) @@ -811,8 +820,11 @@ func TestORM_CreateJob_OCR2_Sending_Keys_Transmitter_Keys_Validations(t *testing pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + //cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + require.True(t, relayerExtenders.Len() > 0) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := ocr2validate.ValidatedOracleSpecToml(config.OCR2(), config.Insecure(), testspecs.OCR2EVMSpecMinimal) require.NoError(t, err) @@ -922,14 +934,15 @@ func Test_FindJobs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb1, err := ocr.ValidatedOracleSpecToml(cc, + jb1, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: uuid.New().String(), TransmitterAddress: address.Hex(), @@ -1002,8 +1015,9 @@ func Test_FindJob(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -1012,7 +1026,7 @@ func Test_FindJob(t *testing.T) { // Must uniquely name the OCR Specs to properly insert a new job in the job table. externalJobID := uuid.New() _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - job, err := ocr.ValidatedOracleSpecToml(cc, + job, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: externalJobID.String(), Name: "orig ocr spec", @@ -1023,7 +1037,7 @@ func Test_FindJob(t *testing.T) { ) require.NoError(t, err) - jobSameAddress, err := ocr.ValidatedOracleSpecToml(cc, + jobSameAddress, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: uuid.New().String(), TransmitterAddress: address.Hex(), @@ -1066,7 +1080,7 @@ func Test_FindJob(t *testing.T) { require.NoError(t, err) // Create a job with the legacy null evm chain id. - jobWithNullChain, err := ocr.ValidatedOracleSpecToml(cc, + jobWithNullChain, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: uuid.New().String(), ContractAddress: "0xB47f9a6D281B2A82F8692F8dE058E4249363A6fc", @@ -1218,8 +1232,9 @@ func Test_FindJobsByPipelineSpecIDs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) require.NoError(t, err) @@ -1258,15 +1273,16 @@ func Test_FindPipelineRuns(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) externalJobID := uuid.New() _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb, err := ocr.ValidatedOracleSpecToml(cc, + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: externalJobID.String(), TransmitterAddress: address.Hex(), @@ -1318,15 +1334,16 @@ func Test_PipelineRunsByJobID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) externalJobID := uuid.New() _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb, err := ocr.ValidatedOracleSpecToml(cc, + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: externalJobID.String(), TransmitterAddress: address.Hex(), @@ -1378,8 +1395,9 @@ func Test_FindPipelineRunIDsByJobID(t *testing.T) { lggr := logger.TestLogger(t) pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) @@ -1391,7 +1409,7 @@ func Test_FindPipelineRunIDsByJobID(t *testing.T) { key, err := ethkey.NewV2() require.NoError(t, err) - jb, err = ocr.ValidatedOracleSpecToml(cc, + jb, err = ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: jobID, Name: fmt.Sprintf("Job #%v", jobID), @@ -1485,15 +1503,16 @@ func Test_FindPipelineRunsByIDs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) externalJobID := uuid.New() _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb, err := ocr.ValidatedOracleSpecToml(cc, + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: externalJobID.String(), TransmitterAddress: address.Hex(), @@ -1542,8 +1561,9 @@ func Test_FindPipelineRunByID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) require.NoError(t, err) @@ -1586,8 +1606,9 @@ func Test_FindJobWithoutSpecErrors(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) require.NoError(t, err) @@ -1624,8 +1645,9 @@ func Test_FindSpecErrorsByJobIDs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) require.NoError(t, err) @@ -1659,15 +1681,16 @@ func Test_CountPipelineRunsByJobID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - orm := NewTestORM(t, db, cc, pipelineORM, bridgesORM, keyStore, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) _, bridge2 := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) externalJobID := uuid.New() _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) - jb, err := ocr.ValidatedOracleSpecToml(cc, + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, testspecs.GenerateOCRSpec(testspecs.OCRSpecParams{ JobID: externalJobID.String(), TransmitterAddress: address.Hex(), diff --git a/core/services/job/job_pipeline_orm_integration_test.go b/core/services/job/job_pipeline_orm_integration_test.go index bc71fa4cc98..cc459d7edff 100644 --- a/core/services/job/job_pipeline_orm_integration_test.go +++ b/core/services/job/job_pipeline_orm_integration_test.go @@ -17,6 +17,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/store/models" ) @@ -150,10 +151,11 @@ func TestPipelineORM_Integration(t *testing.T) { clearJobsDb(t, db) orm := pipeline.NewORM(db, logger.TestLogger(t), cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, logger.TestLogger(t), cfg.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{Client: evmtest.NewEthClientMockWithDefaultChain(t), DB: db, GeneralConfig: config, KeyStore: ethKeyStore}) - runner := pipeline.NewRunner(orm, btORM, config.JobPipeline(), cfg.WebServer(), cc, nil, nil, lggr, nil, nil) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{Client: evmtest.NewEthClientMockWithDefaultChain(t), DB: db, GeneralConfig: config, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + runner := pipeline.NewRunner(orm, btORM, config.JobPipeline(), cfg.WebServer(), legacyChains, nil, nil, lggr, nil, nil) - jobORM := NewTestORM(t, db, cc, orm, btORM, keyStore, cfg.Database()) + jobORM := NewTestORM(t, db, legacyChains, orm, btORM, keyStore, cfg.Database()) dbSpec := makeVoterTurnoutOCRJobSpec(t, transmitterAddress, bridge.Name.String(), bridge2.Name.String()) diff --git a/core/services/job/models.go b/core/services/job/models.go index d14c16d1adf..7c61fbf1e46 100644 --- a/core/services/job/models.go +++ b/core/services/job/models.go @@ -298,18 +298,6 @@ func (r *JSONConfig) Scan(value interface{}) error { return json.Unmarshal(b, &r) } -func (r JSONConfig) EVMChainID() (int64, error) { - i, ok := r["chainID"] - if !ok { - return -1, fmt.Errorf("%w: chainID must be provided in relay config", ErrNoChainFromSpec) - } - f, ok := i.(float64) - if !ok { - return -1, fmt.Errorf("expected float64 chain id but got: %T", i) - } - return int64(f), nil -} - func (r JSONConfig) MercuryCredentialName() (string, error) { url, ok := r["mercuryCredentialName"] if !ok { @@ -348,10 +336,12 @@ const ( // OCR2OracleSpec defines the job spec for OCR2 jobs. // Relay config is chain specific config for a relay (chain adapter). type OCR2OracleSpec struct { - ID int32 `toml:"-"` - ContractID string `toml:"contractID"` - FeedID *common.Hash `toml:"feedID"` - Relay relay.Network `toml:"relay"` + ID int32 `toml:"-"` + ContractID string `toml:"contractID"` + FeedID *common.Hash `toml:"feedID"` + Relay relay.Network `toml:"relay"` + // TODO BCF-2442 implement ChainID as top level parameter rathe than buried in RelayConfig. + ChainID string `toml:"chainID"` RelayConfig JSONConfig `toml:"relayConfig"` P2PV2Bootstrappers pq.StringArray `toml:"p2pv2Bootstrappers"` OCRKeyBundleID null.String `toml:"ocrKeyBundleID"` @@ -368,6 +358,46 @@ type OCR2OracleSpec struct { CaptureAutomationCustomTelemetry bool `toml:"captureAutomationCustomTelemetry"` } +func (s *OCR2OracleSpec) RelayIdentifier() (relay.Identifier, error) { + var id relay.Identifier + cid, err := s.GetChainID() + if err != nil { + return id, err + } + id.ChainID = cid + id.Network = s.Relay + return id, nil +} + +func (s *OCR2OracleSpec) GetChainID() (relay.ChainID, error) { + if s.ChainID != "" { + return relay.ChainID(s.ChainID), nil + } + // backward compatible job spec + return s.getChainIdFromRelayConfig() +} + +func (s *OCR2OracleSpec) getChainIdFromRelayConfig() (relay.ChainID, error) { + + v, exists := s.RelayConfig["chainID"] + if !exists { + return "", fmt.Errorf("chainID does not exist") + } + switch t := v.(type) { + case string: + return relay.ChainID(t), nil + case int, int64, int32: + return relay.ChainID(fmt.Sprintf("%d", v)), nil + case float64: + // backward compatibility with JSONConfig.EVMChainID + i := int64(t) + return relay.ChainID(strconv.FormatInt(i, 10)), nil + + default: + return "", fmt.Errorf("unable to parse chainID: unexpected type %T", t) + } +} + // GetID is a getter function that returns the ID of the spec. func (s OCR2OracleSpec) GetID() string { return fmt.Sprintf("%v", s.ID) diff --git a/core/services/job/models_test.go b/core/services/job/models_test.go new file mode 100644 index 00000000000..bf28a0553ba --- /dev/null +++ b/core/services/job/models_test.go @@ -0,0 +1,73 @@ +package job + +import ( + "reflect" + "testing" + + "github.com/smartcontractkit/chainlink/v2/core/services/relay" +) + +func TestOCR2OracleSpec_RelayIdentifier(t *testing.T) { + type fields struct { + Relay relay.Network + ChainID string + RelayConfig JSONConfig + } + tests := []struct { + name string + fields fields + want relay.Identifier + wantErr bool + }{ + {name: "err no chain id", + fields: fields{}, + want: relay.Identifier{}, + wantErr: true, + }, + { + name: "evm explicitly configured", + fields: fields{ + Relay: relay.EVM, + ChainID: "1", + }, + want: relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID("1")}, + }, + { + name: "evm implicitly configured", + fields: fields{ + Relay: relay.EVM, + RelayConfig: map[string]any{"chainID": 1}, + }, + want: relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID("1")}, + }, + { + name: "evm implicitly configured with bad value", + fields: fields{ + Relay: relay.EVM, + RelayConfig: map[string]any{"chainID": float32(1)}, + }, + want: relay.Identifier{}, + wantErr: true, + }, + } + for _, tt := range tests { + tt := tt + t.Run(tt.name, func(t *testing.T) { + t.Parallel() + + s := &OCR2OracleSpec{ + Relay: tt.fields.Relay, + ChainID: tt.fields.ChainID, + RelayConfig: tt.fields.RelayConfig, + } + got, err := s.RelayIdentifier() + if (err != nil) != tt.wantErr { + t.Errorf("OCR2OracleSpec.RelayIdentifier() error = %v, wantErr %v", err, tt.wantErr) + return + } + if !reflect.DeepEqual(got, tt.want) { + t.Errorf("OCR2OracleSpec.RelayIdentifier() = %v, want %v", got, tt.want) + } + }) + } +} diff --git a/core/services/job/orm.go b/core/services/job/orm.go index 8543c13a14a..342623a62be 100644 --- a/core/services/job/orm.go +++ b/core/services/job/orm.go @@ -83,20 +83,20 @@ type ORMConfig interface { } type orm struct { - q pg.Q - chainSet evm.ChainSet - keyStore keystore.Master - pipelineORM pipeline.ORM - lggr logger.SugaredLogger - cfg pg.QConfig - bridgeORM bridges.ORM + q pg.Q + legacyChains evm.LegacyChainContainer + keyStore keystore.Master + pipelineORM pipeline.ORM + lggr logger.SugaredLogger + cfg pg.QConfig + bridgeORM bridges.ORM } var _ ORM = (*orm)(nil) func NewORM( db *sqlx.DB, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, pipelineORM pipeline.ORM, bridgeORM bridges.ORM, keyStore keystore.Master, // needed to validation key properties on new job creation @@ -105,13 +105,13 @@ func NewORM( ) *orm { namedLogger := logger.Sugared(lggr.Named("JobORM")) return &orm{ - q: pg.NewQ(db, namedLogger, cfg), - chainSet: chainSet, - keyStore: keyStore, - pipelineORM: pipelineORM, - bridgeORM: bridgeORM, - lggr: namedLogger, - cfg: cfg, + q: pg.NewQ(db, namedLogger, cfg), + legacyChains: legacyChains, + keyStore: keyStore, + pipelineORM: pipelineORM, + bridgeORM: bridgeORM, + lggr: namedLogger, + cfg: cfg, } } func (o *orm) Close() error { @@ -200,7 +200,7 @@ func (o *orm) CreateJob(jb *Job, qopts ...pg.QOpt) error { if jb.OCROracleSpec.EVMChainID == nil { // If unspecified, assume we're creating a job intended to run on default chain id - newChain, err := o.chainSet.Default() + newChain, err := o.legacyChains.Default() if err != nil { return err } @@ -696,7 +696,7 @@ func (o *orm) FindJobs(offset, limit int) (jobs []Job, count int, err error) { func (o *orm) LoadEnvConfigVars(jb *Job) error { if jb.OCROracleSpec != nil { - ch, err := o.chainSet.Get(jb.OCROracleSpec.EVMChainID.ToInt()) + ch, err := o.legacyChains.Get(jb.OCROracleSpec.EVMChainID.String()) if err != nil { return err } @@ -706,13 +706,13 @@ func (o *orm) LoadEnvConfigVars(jb *Job) error { } jb.OCROracleSpec = newSpec } else if jb.VRFSpec != nil { - ch, err := o.chainSet.Get(jb.VRFSpec.EVMChainID.ToInt()) + ch, err := o.legacyChains.Get(jb.VRFSpec.EVMChainID.String()) if err != nil { return err } jb.VRFSpec = LoadEnvConfigVarsVRF(ch.Config().EVM(), *jb.VRFSpec) } else if jb.DirectRequestSpec != nil { - ch, err := o.chainSet.Get(jb.DirectRequestSpec.EVMChainID.ToInt()) + ch, err := o.legacyChains.Get(jb.DirectRequestSpec.EVMChainID.String()) if err != nil { return err } diff --git a/core/services/job/orm_test.go b/core/services/job/orm_test.go index e751065578d..15a2432f9e9 100644 --- a/core/services/job/orm_test.go +++ b/core/services/job/orm_test.go @@ -20,8 +20,8 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" ) -func NewTestORM(t *testing.T, db *sqlx.DB, chainSet evm.ChainSet, pipelineORM pipeline.ORM, bridgeORM bridges.ORM, keyStore keystore.Master, cfg pg.QConfig) job.ORM { - o := job.NewORM(db, chainSet, pipelineORM, bridgeORM, keyStore, logger.TestLogger(t), cfg) +func NewTestORM(t *testing.T, db *sqlx.DB, legacyChains evm.LegacyChainContainer, pipelineORM pipeline.ORM, bridgeORM bridges.ORM, keyStore keystore.Master, cfg pg.QConfig) job.ORM { + o := job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, logger.TestLogger(t), cfg) t.Cleanup(func() { o.Close() }) return o } diff --git a/core/services/job/runner_integration_test.go b/core/services/job/runner_integration_test.go index 6baeac7e8fb..2c12658a09f 100644 --- a/core/services/job/runner_integration_test.go +++ b/core/services/job/runner_integration_test.go @@ -13,12 +13,12 @@ import ( "testing" "time" - evmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/mocks" configtest2 "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -75,18 +75,19 @@ func TestRunner(t *testing.T) { c.Insecure.OCRDevelopmentMode = ptr(true) }) - chainScopedConfig := evmtest.NewChainScopedConfig(t, config) - ethClient := cltest.NewEthMocksWithDefaultChain(t) ethClient.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(cltest.Head(10), nil) ethClient.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Maybe().Return(nil, nil) pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, Client: ethClient, GeneralConfig: config, KeyStore: ethKeyStore}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: ethClient, GeneralConfig: config, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) c := clhttptest.NewTestLocalOnlyHTTPClient() - runner := pipeline.NewRunner(pipelineORM, btORM, config.JobPipeline(), config.WebServer(), cc, nil, nil, logger.TestLogger(t), c, c) - jobORM := NewTestORM(t, db, cc, pipelineORM, btORM, keyStore, config.Database()) + + runner := pipeline.NewRunner(pipelineORM, btORM, config.JobPipeline(), config.WebServer(), legacyChains, nil, nil, logger.TestLogger(t), c, c) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, btORM, keyStore, config.Database()) + _, placeHolderAddress := cltest.MustInsertRandomKey(t, keyStore.Eth()) require.NoError(t, runner.Start(testutils.Context(t))) @@ -192,26 +193,23 @@ func TestRunner(t *testing.T) { _, b := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) // Reference a different one - c := new(evmmocks.Chain) - c.On("Config").Return(chainScopedConfig) - cs := evmmocks.NewChainSet(t) - cs.On("Get", mock.Anything).Return(c, nil) + legacyChains := cltest.NewLegacyChainsWithMockChain(t, nil, config) - jb, err2 := ocr.ValidatedOracleSpecToml(cs, fmt.Sprintf(` + jb, err2 := ocr.ValidatedOracleSpecToml(legacyChains, fmt.Sprintf(` type = "offchainreporting" schemaVersion = 1 - evmChainID = 1 + evmChainID = 0 transmitterID = "%s" contractAddress = "0x613a38AC1659769640aaE063C651F48E0250454C" isBootstrapPeer = false blockchainTimeout = "1s" observationTimeout = "10s" databaseTimeout = "2s" - contractConfigTrackerPollInterval="1s" + contractConfigTrackerPollInterval="15s" contractConfigConfirmations=1 observationGracePeriod = "2s" - contractTransmitterTransmitTimeout = "500ms" - contractConfigTrackerSubscribeInterval="1s" + contractTransmitterTransmitTimeout = "5s" + contractConfigTrackerSubscribeInterval="1m" observationSource = """ ds1 [type=bridge name=blah]; ds1_parse [type=jsonparse path="one,two"]; @@ -235,7 +233,7 @@ relay = "evm" contractID = "0x613a38AC1659769640aaE063C651F48E0250454C" transmitterID = "%s" blockchainTimeout = "1s" -contractConfigTrackerPollInterval = "2s" +contractConfigTrackerPollInterval = "15s" contractConfigConfirmations = 1 observationSource = """ ds1 [type=bridge name="%s"]; @@ -270,7 +268,7 @@ relay = "evm" contractID = "0x613a38AC1659769640aaE063C651F48E0250454C" transmitterID = "%s" blockchainTimeout = "1s" -contractConfigTrackerPollInterval = "2s" +contractConfigTrackerPollInterval = "15s" contractConfigConfirmations = 1 observationSource = """ ds1 [type=bridge name="%s"]; @@ -445,7 +443,7 @@ ds1 -> ds1_parse; """ ` s = fmt.Sprintf(s, cltest.NewEIP55Address(), "http://blah.com", "") - jb, err := ocr.ValidatedOracleSpecToml(cc, s) + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &jb) require.NoError(t, err) @@ -459,7 +457,7 @@ ds1 -> ds1_parse; nil, nil, nil, - cc, + legacyChains, logger.TestLogger(t), config.Database(), srvctest.Start(t, utils.NewMailboxMonitor(t.Name())), @@ -477,7 +475,7 @@ ds1 -> ds1_parse; isBootstrapPeer = true ` s = fmt.Sprintf(s, cltest.NewEIP55Address()) - jb, err := ocr.ValidatedOracleSpecToml(cc, s) + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &jb) require.NoError(t, err) @@ -497,7 +495,7 @@ ds1 -> ds1_parse; nil, pw, monitoringEndpoint, - cc, + legacyChains, lggr, config.Database(), srvctest.Start(t, utils.NewMailboxMonitor(t.Name())), @@ -520,7 +518,7 @@ ds1 -> ds1_parse; """ ` s = fmt.Sprintf(s, cltest.NewEIP55Address(), "http://blah.com", "") - jb, err := ocr.ValidatedOracleSpecToml(cc, s) + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &jb) require.NoError(t, err) @@ -543,7 +541,7 @@ ds1 -> ds1_parse; nil, pw, monitoringEndpoint, - cc, + legacyChains, lggr, config.Database(), srvctest.Start(t, utils.NewMailboxMonitor(t.Name())), @@ -557,7 +555,7 @@ ds1 -> ds1_parse; require.NoError(t, err) s := fmt.Sprintf(minimalNonBootstrapTemplate, cltest.NewEIP55Address(), transmitterAddress.Hex(), kb.ID(), "http://blah.com", "") - jb, err := ocr.ValidatedOracleSpecToml(cc, s) + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &jb) require.NoError(t, err) @@ -577,7 +575,7 @@ ds1 -> ds1_parse; nil, pw, monitoringEndpoint, - cc, + legacyChains, lggr, config.Database(), srvctest.Start(t, utils.NewMailboxMonitor(t.Name())), @@ -588,7 +586,7 @@ ds1 -> ds1_parse; t.Run("test min bootstrap", func(t *testing.T) { s := fmt.Sprintf(minimalBootstrapTemplate, cltest.NewEIP55Address()) - jb, err := ocr.ValidatedOracleSpecToml(cc, s) + jb, err := ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &jb) require.NoError(t, err) @@ -605,7 +603,7 @@ ds1 -> ds1_parse; nil, pw, monitoringEndpoint, - cc, + legacyChains, lggr, config.Database(), srvctest.Start(t, utils.NewMailboxMonitor(t.Name())), @@ -636,7 +634,7 @@ ds1 -> ds1_parse; nil, pw, monitoringEndpoint, - cc, + legacyChains, lggr, config.Database(), srvctest.Start(t, utils.NewMailboxMonitor(t.Name())), @@ -767,7 +765,8 @@ func TestRunner_Success_Callback_AsyncJob(t *testing.T) { app := cltest.NewApplicationWithConfig(t, cfg, ethClient, cltest.UseRealExternalInitiatorManager) keyStore := cltest.NewKeyStore(t, app.GetSqlxDB(), pgtest.NewQConfig(true)) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: app.GetSqlxDB(), Client: ethClient, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: app.GetSqlxDB(), Client: ethClient, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) require.NoError(t, app.Start(testutils.Context(t))) var ( @@ -898,7 +897,7 @@ func TestRunner_Success_Callback_AsyncJob(t *testing.T) { pipelineORM := pipeline.NewORM(app.GetSqlxDB(), logger.TestLogger(t), cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(app.GetSqlxDB(), logger.TestLogger(t), cfg.Database()) - jobORM := NewTestORM(t, app.GetSqlxDB(), cc, pipelineORM, bridgesORM, app.KeyStore, cfg.Database()) + jobORM := NewTestORM(t, app.GetSqlxDB(), legacyChains, pipelineORM, bridgesORM, app.KeyStore, cfg.Database()) // Trigger v2/resume select { @@ -948,7 +947,9 @@ func TestRunner_Error_Callback_AsyncJob(t *testing.T) { app := cltest.NewApplicationWithConfig(t, cfg, ethClient, cltest.UseRealExternalInitiatorManager) keyStore := cltest.NewKeyStore(t, app.GetSqlxDB(), pgtest.NewQConfig(true)) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: app.GetSqlxDB(), Client: ethClient, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: app.GetSqlxDB(), Client: ethClient, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, app.Start(testutils.Context(t))) var ( @@ -1077,7 +1078,7 @@ func TestRunner_Error_Callback_AsyncJob(t *testing.T) { pipelineORM := pipeline.NewORM(app.GetSqlxDB(), logger.TestLogger(t), cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(app.GetSqlxDB(), logger.TestLogger(t), cfg.Database()) - jobORM := NewTestORM(t, app.GetSqlxDB(), cc, pipelineORM, bridgesORM, app.KeyStore, cfg.Database()) + jobORM := NewTestORM(t, app.GetSqlxDB(), legacyChains, pipelineORM, bridgesORM, app.KeyStore, cfg.Database()) // Trigger v2/resume select { diff --git a/core/services/job/spawner_test.go b/core/services/job/spawner_test.go index e0332079d23..f0956958fa0 100644 --- a/core/services/job/spawner_test.go +++ b/core/services/job/spawner_test.go @@ -31,6 +31,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" "github.com/smartcontractkit/chainlink/v2/core/services/relay" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" + evmrelayer "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/utils" "github.com/smartcontractkit/chainlink/v2/plugins" @@ -60,6 +61,18 @@ func clearDB(t *testing.T, db *sqlx.DB) { cltest.ClearDBTables(t, db, "jobs", "pipeline_runs", "pipeline_specs", "pipeline_task_runs") } +type relayGetter struct { + e evmrelay.EVMChainRelayerExtender + r *evmrelayer.Relayer +} + +func newrelayGetter() *relayGetter { + return &relayGetter{} +} +func (g *relayGetter) Get(id relay.Identifier) (loop.Relayer, error) { + return evmrelayer.NewLoopRelayAdapter(g.r, g.e), nil +} + func TestSpawner_CreateJobDeleteJob(t *testing.T) { t.Parallel() @@ -82,11 +95,12 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { *head = cltest.Head(10) }). Return(nil).Maybe() - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, Client: ethClient, GeneralConfig: config, KeyStore: ethKeyStore}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: ethClient, GeneralConfig: config, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) t.Run("should respect its dependents", func(t *testing.T) { lggr := logger.TestLogger(t) - orm := NewTestORM(t, db, cc, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) + orm := NewTestORM(t, db, legacyChains, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) a := utils.NewDependentAwaiter() a.AddDependents(1) spawner := job.NewSpawner(orm, config.Database(), map[job.Type]job.Delegate{}, db, lggr, []utils.DependentAwaiter{a}) @@ -109,7 +123,7 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { jobB := makeOCRJobSpec(t, address, bridge.Name.String(), bridge2.Name.String()) lggr := logger.TestLogger(t) - orm := NewTestORM(t, db, cc, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) + orm := NewTestORM(t, db, legacyChains, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) eventuallyA := cltest.NewAwaiter() serviceA1 := mocks.NewServiceCtx(t) @@ -117,7 +131,7 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { serviceA1.On("Start", mock.Anything).Return(nil).Once() serviceA2.On("Start", mock.Anything).Return(nil).Once().Run(func(mock.Arguments) { eventuallyA.ItHappened() }) mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) - dA := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, cc, logger.TestLogger(t), config.Database(), mailMon) + dA := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, legacyChains, logger.TestLogger(t), config.Database(), mailMon) delegateA := &delegate{jobA.Type, []job.ServiceCtx{serviceA1, serviceA2}, 0, make(chan struct{}), dA} eventuallyB := cltest.NewAwaiter() @@ -125,7 +139,7 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { serviceB2 := mocks.NewServiceCtx(t) serviceB1.On("Start", mock.Anything).Return(nil).Once() serviceB2.On("Start", mock.Anything).Return(nil).Once().Run(func(mock.Arguments) { eventuallyB.ItHappened() }) - dB := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, cc, logger.TestLogger(t), config.Database(), mailMon) + dB := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, legacyChains, logger.TestLogger(t), config.Database(), mailMon) delegateB := &delegate{jobB.Type, []job.ServiceCtx{serviceB1, serviceB2}, 0, make(chan struct{}), dB} spawner := job.NewSpawner(orm, config.Database(), map[job.Type]job.Delegate{ @@ -174,9 +188,9 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { serviceA2.On("Start", mock.Anything).Return(nil).Once().Run(func(mock.Arguments) { eventually.ItHappened() }) lggr := logger.TestLogger(t) - orm := NewTestORM(t, db, cc, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) + orm := NewTestORM(t, db, legacyChains, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) - d := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, cc, logger.TestLogger(t), config.Database(), mailMon) + d := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, legacyChains, logger.TestLogger(t), config.Database(), mailMon) delegateA := &delegate{jobA.Type, []job.ServiceCtx{serviceA1, serviceA2}, 0, nil, d} spawner := job.NewSpawner(orm, config.Database(), map[job.Type]job.Delegate{ jobA.Type: delegateA, @@ -208,9 +222,9 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { serviceA2.On("Start", mock.Anything).Return(nil).Once().Run(func(mock.Arguments) { eventuallyStart.ItHappened() }) lggr := logger.TestLogger(t) - orm := NewTestORM(t, db, cc, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) + orm := NewTestORM(t, db, legacyChains, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) - d := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, cc, logger.TestLogger(t), config.Database(), mailMon) + d := ocr.NewDelegate(nil, orm, nil, nil, nil, monitoringEndpoint, legacyChains, logger.TestLogger(t), config.Database(), mailMon) delegateA := &delegate{jobA.Type, []job.ServiceCtx{serviceA1, serviceA2}, 0, nil, d} spawner := job.NewSpawner(orm, config.Database(), map[job.Type]job.Delegate{ jobA.Type: delegateA, @@ -264,24 +278,29 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { LogPoller: lp, KeyStore: ethKeyStore, } - cs := evmtest.NewChainSet(t, testopts) - chain := evmtest.MustGetDefaultChain(t, cs) + lggr := logger.TestLogger(t) + relayExtenders := evmtest.NewChainRelayExtenders(t, testopts) + assert.Equal(t, relayExtenders.Len(), 1) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + chain := evmtest.MustGetDefaultChain(t, legacyChains) + + evmRelayer := evmrelayer.NewRelayer(testopts.DB, chain, testopts.GeneralConfig.Database(), lggr, keyStore, pg.NewNullEventBroadcaster()) + testRelayGetter := &relayGetter{ + e: relayExtenders.Slice()[0], + r: evmRelayer, + } jobOCR2VRF := makeOCR2VRFJobSpec(t, keyStore, config, address, chain.ID(), 2) - lggr := logger.TestLogger(t) - orm := NewTestORM(t, db, cc, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) - mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) - relayers := make(map[relay.Network]loop.Relayer) - evmRelayer := evmrelay.NewRelayer(db, cc, lggr, config.Database(), keyStore, nil) - relayers[relay.EVM] = relay.NewRelayerAdapter(evmRelayer, cc) + orm := NewTestORM(t, db, legacyChains, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) + mailMon := srvctest.Start(t, utils.NewMailboxMonitor(t.Name())) processConfig := plugins.NewRegistrarConfig(loop.GRPCOpts{}, func(name string) (*plugins.RegisteredLoop, error) { return nil, nil }) ocr2DelegateConfig := ocr2.NewDelegateConfig(config.OCR2(), config.Mercury(), config.Threshold(), config.Insecure(), config.JobPipeline(), config.Database(), processConfig) - d := ocr2.NewDelegate(nil, orm, nil, nil, nil, nil, monitoringEndpoint, cs, lggr, ocr2DelegateConfig, - keyStore.OCR2(), keyStore.DKGSign(), keyStore.DKGEncrypt(), ethKeyStore, relayers, mailMon, nil) + d := ocr2.NewDelegate(nil, orm, nil, nil, nil, nil, monitoringEndpoint, legacyChains, lggr, ocr2DelegateConfig, + keyStore.OCR2(), keyStore.DKGSign(), keyStore.DKGEncrypt(), ethKeyStore, testRelayGetter, mailMon, nil) delegateOCR2 := &delegate{jobOCR2VRF.Type, []job.ServiceCtx{}, 0, nil, d} spawner := job.NewSpawner(orm, config.Database(), map[job.Type]job.Delegate{ diff --git a/core/services/job/util.go b/core/services/job/util.go index 6232dffe737..143dfed7e45 100644 --- a/core/services/job/util.go +++ b/core/services/job/util.go @@ -2,11 +2,8 @@ package job import ( "fmt" - "math/big" "github.com/pkg/errors" - - "github.com/smartcontractkit/chainlink/v2/core/chains/evm" ) var ( @@ -14,36 +11,6 @@ var ( ErrNoSendingKeysFromSpec = fmt.Errorf("could not get sending keys from spec") ) -// EVMChainForJob parses the job spec and retrieves the evm chain found. -func EVMChainForBootstrapJob(job *Job, set evm.ChainSet) (evm.Chain, error) { - chainIDInterface, ok := job.BootstrapSpec.RelayConfig["chainID"] - if !ok { - return nil, fmt.Errorf("%w: chainID must be provided in relay config", ErrNoChainFromSpec) - } - chainID := chainIDInterface.(int64) - chain, err := set.Get(big.NewInt(chainID)) - if err != nil { - return nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err) - } - - return chain, nil -} - -// EVMChainForJob parses the job spec and retrieves the evm chain found. -func EVMChainForJob(job *Job, set evm.ChainSet) (evm.Chain, error) { - chainIDInterface, ok := job.OCR2OracleSpec.RelayConfig["chainID"] - if !ok { - return nil, fmt.Errorf("%w: chainID must be provided in relay config", ErrNoChainFromSpec) - } - chainID := chainIDInterface.(int64) - chain, err := set.Get(big.NewInt(chainID)) - if err != nil { - return nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err) - } - - return chain, nil -} - // SendingKeysForJob parses the job spec and retrieves the sending keys found. func SendingKeysForJob(job *Job) ([]string, error) { sendingKeysInterface, ok := job.OCR2OracleSpec.RelayConfig["sendingKeys"] diff --git a/core/services/keeper/delegate.go b/core/services/keeper/delegate.go index bb9de6c3eeb..cdb085f743e 100644 --- a/core/services/keeper/delegate.go +++ b/core/services/keeper/delegate.go @@ -16,12 +16,12 @@ import ( var _ job.Delegate = (*Delegate)(nil) type Delegate struct { - logger logger.Logger - db *sqlx.DB - jrm job.ORM - pr pipeline.Runner - chainSet evm.ChainSet - mailMon *utils.MailboxMonitor + logger logger.Logger + db *sqlx.DB + jrm job.ORM + pr pipeline.Runner + legacyChains evm.LegacyChainContainer + mailMon *utils.MailboxMonitor } // NewDelegate is the constructor of Delegate @@ -30,16 +30,16 @@ func NewDelegate( jrm job.ORM, pr pipeline.Runner, logger logger.Logger, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, mailMon *utils.MailboxMonitor, ) *Delegate { return &Delegate{ - logger: logger, - db: db, - jrm: jrm, - pr: pr, - chainSet: chainSet, - mailMon: mailMon, + logger: logger, + db: db, + jrm: jrm, + pr: pr, + legacyChains: legacyChains, + mailMon: mailMon, } } @@ -58,7 +58,7 @@ func (d *Delegate) ServicesForSpec(spec job.Job, qopts ...pg.QOpt) (services []j if spec.KeeperSpec == nil { return nil, errors.Errorf("Delegate expects a *job.KeeperSpec to be present, got %v", spec) } - chain, err := d.chainSet.Get(spec.KeeperSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(spec.KeeperSpec.EVMChainID.String()) if err != nil { return nil, err } diff --git a/core/services/keeper/integration_test.go b/core/services/keeper/integration_test.go index 15577b3bb51..2177d418e53 100644 --- a/core/services/keeper/integration_test.go +++ b/core/services/keeper/integration_test.go @@ -417,7 +417,7 @@ func TestKeeperForwarderEthIntegration(t *testing.T) { _, err = forwarderORM.CreateForwarder(fwdrAddress, chainID) require.NoError(t, err) - addr, err := app.Chains.EVM.Chains()[0].TxManager().GetForwarderForEOA(nodeAddress) + addr, err := app.GetRelayers().LegacyEVMChains().Slice()[0].TxManager().GetForwarderForEOA(nodeAddress) require.NoError(t, err) require.Equal(t, addr, fwdrAddress) diff --git a/core/services/keeper/registry_synchronizer_helper_test.go b/core/services/keeper/registry_synchronizer_helper_test.go index 564bac08812..6b9bb815a89 100644 --- a/core/services/keeper/registry_synchronizer_helper_test.go +++ b/core/services/keeper/registry_synchronizer_helper_test.go @@ -19,6 +19,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/keeper" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -42,9 +43,10 @@ func setupRegistrySync(t *testing.T, version keeper.RegistryVersion) ( lbMock := logmocks.NewBroadcaster(t) lbMock.On("AddDependents", 1).Maybe() j := cltest.MustInsertKeeperJob(t, db, korm, cltest.NewEIP55Address(), cltest.NewEIP55Address()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, Client: ethClient, LogBroadcaster: lbMock, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) - ch := evmtest.MustGetDefaultChain(t, cc) - jpv2 := cltest.NewJobPipelineV2(t, cfg.WebServer(), cfg.JobPipeline(), cfg.Database(), cc, db, keyStore, nil, nil) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: ethClient, LogBroadcaster: lbMock, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + ch := evmtest.MustGetDefaultChain(t, legacyChains) + jpv2 := cltest.NewJobPipelineV2(t, cfg.WebServer(), cfg.JobPipeline(), cfg.Database(), legacyChains, db, keyStore, nil, nil) contractAddress := j.KeeperSpec.ContractAddress.Address() switch version { diff --git a/core/services/keeper/upkeep_executer_test.go b/core/services/keeper/upkeep_executer_test.go index e30b49f961f..633372395d1 100644 --- a/core/services/keeper/upkeep_executer_test.go +++ b/core/services/keeper/upkeep_executer_test.go @@ -32,6 +32,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/keeper" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -74,9 +75,10 @@ func setup(t *testing.T, estimator gas.EvmFeeEstimator, overrideFn func(c *chain ethClient := evmtest.NewEthClientMockWithDefaultChain(t) ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Maybe().Return(&evmtypes.Head{Number: 1, Hash: utils.NewHash()}, nil) txm := txmmocks.NewMockEvmTxManager(t) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{TxManager: txm, DB: db, Client: ethClient, KeyStore: keyStore.Eth(), GeneralConfig: cfg, GasEstimator: estimator}) - jpv2 := cltest.NewJobPipelineV2(t, cfg.WebServer(), cfg.JobPipeline(), cfg.Database(), cc, db, keyStore, nil, nil) - ch := evmtest.MustGetDefaultChain(t, cc) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{TxManager: txm, DB: db, Client: ethClient, KeyStore: keyStore.Eth(), GeneralConfig: cfg, GasEstimator: estimator}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jpv2 := cltest.NewJobPipelineV2(t, cfg.WebServer(), cfg.JobPipeline(), cfg.Database(), legacyChains, db, keyStore, nil, nil) + ch := evmtest.MustGetDefaultChain(t, legacyChains) orm := keeper.NewORM(db, logger.TestLogger(t), ch.Config().Database()) registry, job := cltest.MustInsertKeeperRegistry(t, db, orm, keyStore.Eth(), 0, 1, 20) lggr := logger.TestLogger(t) diff --git a/core/services/ocr/delegate.go b/core/services/ocr/delegate.go index ebcd04952d2..c5ace522ccb 100644 --- a/core/services/ocr/delegate.go +++ b/core/services/ocr/delegate.go @@ -41,7 +41,7 @@ type Delegate struct { pipelineRunner pipeline.Runner peerWrapper *ocrcommon.SingletonPeerWrapper monitoringEndpointGen telemetry.MonitoringEndpointGenerator - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer lggr logger.Logger cfg Config mailMon *utils.MailboxMonitor @@ -58,22 +58,22 @@ func NewDelegate( pipelineRunner pipeline.Runner, peerWrapper *ocrcommon.SingletonPeerWrapper, monitoringEndpointGen telemetry.MonitoringEndpointGenerator, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, lggr logger.Logger, cfg Config, mailMon *utils.MailboxMonitor, ) *Delegate { return &Delegate{ - db, - jobORM, - keyStore, - pipelineRunner, - peerWrapper, - monitoringEndpointGen, - chainSet, - lggr.Named("OCR"), - cfg, - mailMon, + db: db, + jobORM: jobORM, + keyStore: keyStore, + pipelineRunner: pipelineRunner, + peerWrapper: peerWrapper, + monitoringEndpointGen: monitoringEndpointGen, + legacyChains: legacyChains, + lggr: lggr.Named("OCR"), + cfg: cfg, + mailMon: mailMon, } } @@ -91,7 +91,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) (services []job if jb.OCROracleSpec == nil { return nil, errors.Errorf("offchainreporting.Delegate expects an *job.OffchainreportingOracleSpec to be present, got %v", jb) } - chain, err := d.chainSet.Get(jb.OCROracleSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(jb.OCROracleSpec.EVMChainID.String()) if err != nil { return nil, err } @@ -235,7 +235,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) (services []job if jb.GasLimit.Valid { jsGasLimit = &jb.GasLimit.Uint32 } - gasLimit := pipeline.SelectGasLimit(chain.Config(), jb.Type.String(), jsGasLimit) + gasLimit := pipeline.SelectGasLimit(chain.Config().EVM().GasEstimator(), jb.Type.String(), jsGasLimit) // effectiveTransmitterAddress is the transmitter address registered on the ocr contract. This is by default the EOA account on the node. // In the case of forwarding, the transmitter address is the forwarder contract deployed onchain between EOA and OCR contract. diff --git a/core/services/ocr/validate.go b/core/services/ocr/validate.go index fc4547cb4e6..07fdc15912e 100644 --- a/core/services/ocr/validate.go +++ b/core/services/ocr/validate.go @@ -37,9 +37,9 @@ type insecureConfig interface { } // ValidatedOracleSpecToml validates an oracle spec that came from TOML -func ValidatedOracleSpecToml(chainSet evm.ChainSet, tomlString string) (job.Job, error) { +func ValidatedOracleSpecToml(legacyChains evm.LegacyChainContainer, tomlString string) (job.Job, error) { return ValidatedOracleSpecTomlCfg(func(id *big.Int) (evmconfig.ChainScopedConfig, error) { - c, err := chainSet.Get(id) + c, err := legacyChains.Get(id.String()) if err != nil { return nil, err } diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 1aa5b11450f..6d91bf448b0 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -71,6 +71,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/plugins" ) +type RelayGetter interface { + Get(id relay.Identifier) (loop.Relayer, error) +} type Delegate struct { db *sqlx.DB jobORM job.ORM @@ -85,12 +88,12 @@ type Delegate struct { dkgSignKs keystore.DKGSign dkgEncryptKs keystore.DKGEncrypt ethKs keystore.Eth - relayers map[relay.Network]loop.Relayer - isNewlyCreatedJob bool // Set to true if this is a new job freshly added, false if job was present already on node boot. - mailMon *utils.MailboxMonitor - eventBroadcaster pg.EventBroadcaster + RelayGetter + isNewlyCreatedJob bool // Set to true if this is a new job freshly added, false if job was present already on node boot. + mailMon *utils.MailboxMonitor + eventBroadcaster pg.EventBroadcaster - chainSet evm.ChainSet // legacy: use relayers instead + legacyChains evm.LegacyChainContainer // legacy: use relayers instead } type DelegateConfig interface { @@ -188,14 +191,14 @@ func NewDelegate( pipelineRunner pipeline.Runner, peerWrapper *ocrcommon.SingletonPeerWrapper, monitoringEndpointGen telemetry.MonitoringEndpointGenerator, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, lggr logger.Logger, cfg DelegateConfig, ks keystore.OCR2, dkgSignKs keystore.DKGSign, dkgEncryptKs keystore.DKGEncrypt, ethKs keystore.Eth, - relayers map[relay.Network]loop.Relayer, + relayers RelayGetter, mailMon *utils.MailboxMonitor, eventBroadcaster pg.EventBroadcaster, ) *Delegate { @@ -207,14 +210,14 @@ func NewDelegate( pipelineRunner: pipelineRunner, peerWrapper: peerWrapper, monitoringEndpointGen: monitoringEndpointGen, - chainSet: chainSet, + legacyChains: legacyChains, cfg: cfg, lggr: lggr, ks: ks, dkgSignKs: dkgSignKs, dkgEncryptKs: dkgEncryptKs, ethKs: ethKs, - relayers: relayers, + RelayGetter: relayers, isNewlyCreatedJob: false, mailMon: mailMon, eventBroadcaster: eventBroadcaster, @@ -248,12 +251,17 @@ func (d *Delegate) OnDeleteJob(jb job.Job, q pg.Queryer) error { return nil } - chainID, err := spec.RelayConfig.EVMChainID() + chainID, err := spec.GetChainID() + if err != nil { + d.lggr.Errorw("OCR2 job spec missing chainID", "err", err) + return nil + } + _, err = chainID.Int64() if err != nil { - d.lggr.Errorf("OCR2 jobs spec missing chainID") + d.lggr.Errorw("OCR2 chainID not evm compatible", "err", err) return nil } - chain, err := d.chainSet.Get(big.NewInt(chainID)) + chain, err := d.legacyChains.Get(chainID.String()) if err != nil { d.lggr.Error(err) return nil @@ -326,15 +334,20 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC lggr := logger.Sugared(d.lggr.Named("OCR2").With(lggrCtx.Args()...)) if spec.Relay == relay.EVM { - chainID, err := spec.RelayConfig.EVMChainID() - if err != nil { - return nil, errors.Wrap(err, "ServicesForSpec failed to get chainID") + chainID, err2 := spec.GetChainID() + if err2 != nil { + return nil, fmt.Errorf("ServicesForSpec failed to get chainID: %w", err2) + } + + _, err2 = chainID.Int64() + if err2 != nil { + return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) } lggr = logger.Sugared(lggr.With("evmChainID", chainID)) - effectiveTransmitterID, err = GetEVMEffectiveTransmitterID(&jb, d.chainSet, chainID, lggr) - if err != nil { - return nil, errors.Wrap(err, "ServicesForSpec failed to get evm transmitterID") + effectiveTransmitterID, err2 = GetEVMEffectiveTransmitterID(&jb, d.legacyChains, chainID.String(), lggr) + if err2 != nil { + return nil, fmt.Errorf("ServicesForSpec failed to get evm transmitterID: %w", err2) } } spec.RelayConfig["effectiveTransmitterID"] = effectiveTransmitterID @@ -418,7 +431,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC } } -func GetEVMEffectiveTransmitterID(jb *job.Job, chainSet evm.ChainSet, chainID int64, lggr logger.SugaredLogger) (string, error) { +func GetEVMEffectiveTransmitterID(jb *job.Job, legacyChains evm.LegacyChainContainer, chainID string, lggr logger.SugaredLogger) (string, error) { spec := jb.OCR2OracleSpec if spec.PluginType == job.Mercury { return spec.TransmitterID.String, nil @@ -442,7 +455,7 @@ func GetEVMEffectiveTransmitterID(jb *job.Job, chainSet evm.ChainSet, chainID in // In the case of forwarding, the transmitter address is the forwarder contract deployed onchain between EOA and OCR contract. // ForwardingAllowed cannot be set with Mercury, so this should always be false for mercury jobs if jb.ForwardingAllowed { - chain, err := chainSet.Get(big.NewInt(chainID)) + chain, err := legacyChains.Get(chainID) if err != nil { return "", errors.Wrap(err, "failed to get chainset") } @@ -484,9 +497,14 @@ func (d *Delegate) newServicesMercury( return nil, errors.Wrapf(err, "ServicesForSpec: mercury job type requires transmitter ID to be a 32-byte hex string, got: %q", transmitterID) } - relayer, exists := d.relayers[spec.Relay] - if !exists { - return nil, errors.Errorf("%s relay does not exist is it enabled?", spec.Relay) + chainID, err := spec.GetChainID() + if err != nil { + return nil, fmt.Errorf("ServicesForSpec failed to get chainID: %w", err) + } + relayID := relay.Identifier{Network: spec.Relay, ChainID: chainID} + relayer, err := d.RelayGetter.Get(relayID) + if err != nil { + return nil, fmt.Errorf("failed to get relay %s is it enabled?: %w", spec.Relay, err) } mercuryProvider, err2 := relayer.NewMercuryProvider(ctx, types.RelayArgs{ @@ -503,13 +521,13 @@ func (d *Delegate) newServicesMercury( return nil, err2 } - chainID, err2 := spec.RelayConfig.EVMChainID() + _, err2 = chainID.Int64() if err2 != nil { - return nil, errors.Wrap(err2, "ServicesForSpec failed to get chainID") + return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) } - chain, err2 := d.chainSet.Get(big.NewInt(chainID)) + chain, err2 := d.legacyChains.Get(chainID.String()) if err2 != nil { - return nil, errors.Wrap(err2, "ServicesForSpec failed to get chain") + return nil, fmt.Errorf("ServicesForSpec failed to get chain: %w", err2) } oracleArgsNoPlugin := libocr2.MercuryOracleArgs{ @@ -564,10 +582,16 @@ func (d *Delegate) newServicesMedian( enhancedTelemChan := make(chan ocrcommon.EnhancedTelemetryData, 100) mConfig := median.NewMedianConfig(d.cfg.JobPipeline().MaxSuccessfulRuns(), d.cfg) - relayer, exists := d.relayers[spec.Relay] - if !exists { - return nil, errors.Errorf("%s relay does not exist is it enabled?", spec.Relay) + chainID, err := spec.GetChainID() + if err != nil { + return nil, fmt.Errorf("failed to get chainID from spec: %w", err) } + relayID := relay.Identifier{Network: spec.Relay, ChainID: chainID} + relayer, err := d.RelayGetter.Get(relayID) + if err != nil { + return nil, fmt.Errorf("failed to get relay %s is it enabled?: %w", spec.Relay, err) + } + medianServices, err2 := median.NewMedianServices(ctx, jb, d.isNewlyCreatedJob, relayer, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, mConfig, enhancedTelemChan, errorLog) if ocrcommon.ShouldCollectEnhancedTelemetry(&jb) { @@ -588,13 +612,17 @@ func (d *Delegate) newServicesDKG( ocrLogger commontypes.Logger, ) ([]job.ServiceCtx, error) { spec := jb.OCR2OracleSpec - chainID, err2 := spec.RelayConfig.EVMChainID() + chainID, err2 := spec.GetChainID() if err2 != nil { return nil, err2 } - chain, err2 := d.chainSet.Get(big.NewInt(chainID)) + evmChainID, err2 := chainID.Int64() if err2 != nil { - return nil, errors.Wrap(err2, "get chainset") + return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + } + chain, err2 := d.legacyChains.Get(chainID.String()) + if err2 != nil { + return nil, fmt.Errorf("get chainset: %w", err2) } ocr2vrfRelayer := evmrelay.NewOCR2VRFRelayer(d.db, chain, lggr.Named("OCR2VRFRelayer"), d.ethKs) dkgProvider, err2 := ocr2vrfRelayer.NewDKGProvider( @@ -637,7 +665,7 @@ func (d *Delegate) newServicesDKG( oracleArgsNoPlugin, d.db, d.cfg.Database(), - big.NewInt(chainID), + big.NewInt(evmChainID), spec.Relay, ) } @@ -652,14 +680,17 @@ func (d *Delegate) newServicesOCR2VRF( lc ocrtypes.LocalConfig, ) ([]job.ServiceCtx, error) { spec := jb.OCR2OracleSpec - chainID, err2 := spec.RelayConfig.EVMChainID() + chainID, err2 := spec.GetChainID() if err2 != nil { return nil, err2 } - - chain, err2 := d.chainSet.Get(big.NewInt(chainID)) + evmChainID, err2 := chainID.Int64() if err2 != nil { - return nil, errors.Wrap(err2, "get chainset") + return nil, fmt.Errorf("chainID not evm compatible: %w", err2) + } + chain, err2 := d.legacyChains.Get(chainID.String()) + if err2 != nil { + return nil, fmt.Errorf("get chainset: %w", err2) } if jb.ForwardingAllowed != chain.Config().EVM().Transactions().ForwardersEnabled() { return nil, errors.New("transaction forwarding settings must be consistent for ocr2vrf") @@ -803,7 +834,7 @@ func (d *Delegate) newServicesOCR2VRF( KeyID: keyID, DKGReportingPluginFactoryDecorator: dkgReportingPluginFactoryDecorator, VRFReportingPluginFactoryDecorator: vrfReportingPluginFactoryDecorator, - DKGSharePersistence: persistence.NewShareDB(d.db, lggr.Named("DKGShareDB"), d.cfg.Database(), big.NewInt(chainID), spec.Relay), + DKGSharePersistence: persistence.NewShareDB(d.db, lggr.Named("DKGShareDB"), d.cfg.Database(), big.NewInt(evmChainID), spec.Relay), }) if err2 != nil { return nil, errors.Wrap(err2, "new ocr2vrf") @@ -875,8 +906,20 @@ func (d *Delegate) newServicesOCR2Keepers21( } mc := d.cfg.Mercury().Credentials(credName) + chainID, err2 := spec.GetChainID() + if err2 != nil { + return nil, err2 + } + _, err2 = chainID.Int64() + if err2 != nil { + return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + } + chain, err2 := d.legacyChains.Get(chainID.String()) + if err2 != nil { + return nil, fmt.Errorf("get chainset: %w", err2) + } - keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, payloadBuilder, upkeepStateStore, up, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, d.chainSet, d.pipelineRunner, mc, kb) + keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, payloadBuilder, upkeepStateStore, up, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, chain, d.pipelineRunner, mc, kb) if err2 != nil { return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") } @@ -974,7 +1017,19 @@ func (d *Delegate) newServicesOCR2Keepers20( cfg ocr2keeper.PluginConfig, spec *job.OCR2OracleSpec, ) ([]job.ServiceCtx, error) { - keeperProvider, rgstry, encoder, logProvider, err2 := ocr2keeper.EVMDependencies20(jb, d.db, lggr, d.chainSet, d.pipelineRunner) + chainID, err2 := spec.GetChainID() + if err2 != nil { + return nil, err2 + } + _, err2 = chainID.Int64() + if err2 != nil { + return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + } + chain, err2 := d.legacyChains.Get(chainID.String()) + if err2 != nil { + return nil, fmt.Errorf("get chainset: %w", err2) + } + keeperProvider, rgstry, encoder, logProvider, err2 := ocr2keeper.EVMDependencies20(jb, d.db, lggr, chain, d.pipelineRunner) if err2 != nil { return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") } @@ -1100,9 +1155,17 @@ func (d *Delegate) newServicesOCR2Functions( return nil, fmt.Errorf("unsupported relay: %s", spec.Relay) } + relayerID, err := spec.RelayIdentifier() + if err != nil { + return nil, fmt.Errorf("functions: OCR2 Delegate could not get relayer: %w", err) + } + chain, err := d.legacyChains.Get(relayerID.ChainID.String()) + if err != nil { + return nil, fmt.Errorf("functions: OCR2 Delegate could not find chain id (%s) given in the spec: %w", relayerID.ChainID, err) + } createPluginProvider := func(pluginType functionsRelay.FunctionsPluginType, relayerName string) (evmrelaytypes.FunctionsProvider, error) { return evmrelay.NewFunctionsProvider( - d.chainSet, + chain, types.RelayArgs{ ExternalJobID: jb.ExternalJobID, JobID: spec.ID, @@ -1135,16 +1198,6 @@ func (d *Delegate) newServicesOCR2Functions( return nil, err } - var relayConfig evmrelaytypes.RelayConfig - err = json.Unmarshal(spec.RelayConfig.Bytes(), &relayConfig) - if err != nil { - return nil, err - } - chain, err := d.chainSet.Get(relayConfig.ChainID.ToInt()) - if err != nil { - return nil, err - } - functionsOracleArgs := libocr2.OCR2OracleArgs{ BinaryNetworkEndpointFactory: d.peerWrapper.Peer2, V2Bootstrappers: bootstrapPeers, diff --git a/core/services/ocr2/delegate_test.go b/core/services/ocr2/delegate_test.go index dc7d5526e16..8bb3288cb36 100644 --- a/core/services/ocr2/delegate_test.go +++ b/core/services/ocr2/delegate_test.go @@ -1,8 +1,14 @@ package ocr2_test import ( + "testing" + "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" + "github.com/stretchr/testify/require" + "gopkg.in/guregu/null.v4" + + "github.com/smartcontractkit/chainlink/v2/core/chains" evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" txmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" @@ -15,11 +21,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2" ocr2validate "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/validate" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/testdata/testspecs" "github.com/smartcontractkit/chainlink/v2/core/utils" - "github.com/stretchr/testify/require" - "gopkg.in/guregu/null.v4" - "testing" ) func TestGetEVMEffectiveTransmitterID(t *testing.T) { @@ -40,7 +44,9 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { lggr := logger.TestLogger(t) txManager := txmmocks.NewMockEvmTxManager(t) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth(), TxManager: txManager}) + relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth(), TxManager: txManager}) + require.True(t, relayerExtenders.Len() > 0) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) type testCase struct { name string @@ -134,7 +140,7 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { require.NoError(t, err) jb.OCR2OracleSpec.TransmitterID = null.StringFrom("some transmitterID string") jb.OCR2OracleSpec.RelayConfig["sendingKeys"] = nil - effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, cc, customChainID.Int64(), lggr) + effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, legacyChains, customChainID.String(), lggr) require.NoError(t, err) require.Equal(t, "some transmitterID string", effectiveTransmitterID) require.Equal(t, []string{"some transmitterID string"}, jb.OCR2OracleSpec.RelayConfig["sendingKeys"].([]string)) @@ -146,7 +152,7 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { require.NoError(t, err) setTestCase(&jb, tc, txManager) - effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, cc, customChainID.Int64(), lggr) + effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, legacyChains, customChainID.String(), lggr) if tc.expectedError { require.Error(t, err) } else { @@ -167,7 +173,8 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { require.NoError(t, err) jb.ForwardingAllowed = true jb.OCR2OracleSpec.TransmitterID = null.StringFrom("0x7e57000000000000000000000000000000000001") - _, err = ocr2.GetEVMEffectiveTransmitterID(&jb, cc, int64(-1), lggr) - require.Equal(t, "failed to get chainset: failed to get chain with id -1: not found", err.Error()) + _, err = ocr2.GetEVMEffectiveTransmitterID(&jb, legacyChains, "-1", lggr) + require.Error(t, err) + require.ErrorIs(t, err, chains.ErrNoSuchChainID) }) } diff --git a/core/services/ocr2/plugins/mercury/integration_test.go b/core/services/ocr2/plugins/mercury/integration_test.go index dbbe9ce4da2..b75855b8db5 100644 --- a/core/services/ocr2/plugins/mercury/integration_test.go +++ b/core/services/ocr2/plugins/mercury/integration_test.go @@ -321,7 +321,7 @@ func TestIntegration_MercuryV1(t *testing.T) { } // Bury it with finality depth - ch, err := bootstrapNode.App.GetChains().EVM.Get(testutils.SimulatedChainID) + ch, err := bootstrapNode.App.GetRelayers().LegacyEVMChains().Get(testutils.SimulatedChainID.String()) require.NoError(t, err) finalityDepth := ch.Config().EVM().FinalityDepth() for i := 0; i < int(finalityDepth); i++ { @@ -651,7 +651,7 @@ func TestIntegration_MercuryV2(t *testing.T) { } // Bury it with finality depth - ch, err := bootstrapNode.App.GetChains().EVM.Get(testutils.SimulatedChainID) + ch, err := bootstrapNode.App.GetRelayers().LegacyEVMChains().Get(testutils.SimulatedChainID.String()) require.NoError(t, err) finalityDepth := ch.Config().EVM().FinalityDepth() for i := 0; i < int(finalityDepth); i++ { @@ -927,7 +927,7 @@ func TestIntegration_MercuryV3(t *testing.T) { } // Bury it with finality depth - ch, err := bootstrapNode.App.GetChains().EVM.Get(testutils.SimulatedChainID) + ch, err := bootstrapNode.App.GetRelayers().LegacyEVMChains().Get(testutils.SimulatedChainID.String()) require.NoError(t, err) finalityDepth := ch.Config().EVM().FinalityDepth() for i := 0; i < int(finalityDepth); i++ { diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_test.go index b5c077124a3..8b7e92c40fe 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_test.go @@ -447,7 +447,7 @@ func setupForwarderForNode( _, err = forwarderORM.CreateForwarder(faddr, chainID) require.NoError(t, err) - chain, err := app.GetChains().EVM.Get((*big.Int)(&chainID)) + chain, err := app.GetRelayers().LegacyEVMChains().Get((*big.Int)(&chainID).String()) require.NoError(t, err) fwdr, err := chain.TxManager().GetForwarderForEOA(recipient) require.NoError(t, err) diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index 819f14be20e..3665dc39e52 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -2,7 +2,6 @@ package ocr2keeper import ( "fmt" - "math/big" "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" @@ -72,32 +71,20 @@ func EVMDependencies20( spec job.Job, db *sqlx.DB, lggr logger.Logger, - set evm.ChainSet, + chain evm.Chain, pr pipeline.Runner, ) (evmrelay.OCR2KeeperProvider, *kevm20.EvmRegistry, Encoder20, *kevm20.LogProvider, error) { var err error - var chain evm.Chain + var keeperProvider evmrelay.OCR2KeeperProvider var registry *kevm20.EvmRegistry - oSpec := spec.OCR2OracleSpec - - // get the chain from the config - chainID, err2 := spec.OCR2OracleSpec.RelayConfig.EVMChainID() - if err2 != nil { - return nil, nil, nil, nil, err2 - } - chain, err2 = set.Get(big.NewInt(chainID)) - if err2 != nil { - return nil, nil, nil, nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err2) - } - // the provider will be returned as a dependency if keeperProvider, err = EVMProvider(db, chain, lggr, spec, pr); err != nil { return nil, nil, nil, nil, err } - rAddr := ethkey.MustEIP55Address(oSpec.ContractID).Address() + rAddr := ethkey.MustEIP55Address(spec.OCR2OracleSpec.ContractID).Address() if registry, err = kevm20.NewEVMRegistryService(rAddr, chain, lggr); err != nil { return nil, nil, nil, nil, err } @@ -125,29 +112,18 @@ func EVMDependencies21( spec job.Job, db *sqlx.DB, lggr logger.Logger, - set evm.ChainSet, + chain evm.Chain, pr pipeline.Runner, mc *models.MercuryCredentials, keyring ocrtypes.OnchainKeyring, ) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[ocr2keepers21plugin.AutomationReportInfo], *kevm21.BlockSubscriber, ocr2keepers21.PayloadBuilder, ocr2keepers21.UpkeepStateUpdater, ocr2keepers21.ConditionalUpkeepProvider, error) { var err error - var chain evm.Chain var keeperProvider evmrelay.OCR2KeeperProvider var registry *kevm21.EvmRegistry var encoder *kevm21.EVMAutomationEncoder21 oSpec := spec.OCR2OracleSpec - // get the chain from the config - chainID, err2 := spec.OCR2OracleSpec.RelayConfig.EVMChainID() - if err2 != nil { - return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err2 - } - chain, err2 = set.Get(big.NewInt(chainID)) - if err2 != nil { - return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, fmt.Errorf("%w: %s", ErrNoChainFromSpec, err2) - } - // the provider will be returned as a dependency if keeperProvider, err = EVMProvider(db, chain, lggr, spec, pr); err != nil { return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err diff --git a/core/services/ocr2/plugins/ocr2vrf/internal/ocr2vrf_integration_test.go b/core/services/ocr2/plugins/ocr2vrf/internal/ocr2vrf_integration_test.go index db646b4e807..0ca6fb383c6 100644 --- a/core/services/ocr2/plugins/ocr2vrf/internal/ocr2vrf_integration_test.go +++ b/core/services/ocr2/plugins/ocr2vrf/internal/ocr2vrf_integration_test.go @@ -431,7 +431,7 @@ func runOCR2VRFTest(t *testing.T, useForwarders bool) { err = bootstrapNode.app.Start(testutils.Context(t)) require.NoError(t, err) - chainSet := bootstrapNode.app.GetChains().EVM + chainSet := bootstrapNode.app.GetRelayers().LegacyEVMChains() require.NotNil(t, chainSet) bootstrapJobSpec := fmt.Sprintf(` type = "bootstrap" diff --git a/core/services/ocrbootstrap/delegate.go b/core/services/ocrbootstrap/delegate.go index 6d269a9067e..5e16c13d51d 100644 --- a/core/services/ocrbootstrap/delegate.go +++ b/core/services/ocrbootstrap/delegate.go @@ -3,6 +3,7 @@ package ocrbootstrap import ( "context" "encoding/json" + "fmt" "github.com/pkg/errors" @@ -21,15 +22,19 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/relay" ) +type RelayGetter interface { + Get(relay.Identifier) (loop.Relayer, error) +} + // Delegate creates Bootstrap jobs type Delegate struct { - db *sqlx.DB - jobORM job.ORM - peerWrapper *ocrcommon.SingletonPeerWrapper - ocr2Cfg validate.OCR2Config - insecureCfg validate.InsecureConfig - lggr logger.SugaredLogger - relayers map[relay.Network]loop.Relayer + db *sqlx.DB + jobORM job.ORM + peerWrapper *ocrcommon.SingletonPeerWrapper + ocr2Cfg validate.OCR2Config + insecureCfg validate.InsecureConfig + lggr logger.SugaredLogger + RelayGetter isNewlyCreatedJob bool } @@ -48,7 +53,7 @@ func NewDelegateBootstrap( lggr logger.Logger, ocr2Cfg validate.OCR2Config, insecureCfg validate.InsecureConfig, - relayers map[relay.Network]loop.Relayer, + relayers RelayGetter, ) *Delegate { return &Delegate{ db: db, @@ -57,7 +62,7 @@ func NewDelegateBootstrap( lggr: logger.Sugared(lggr), ocr2Cfg: ocr2Cfg, insecureCfg: insecureCfg, - relayers: relayers, + RelayGetter: relayers, } } @@ -81,9 +86,15 @@ func (d *Delegate) ServicesForSpec(jobSpec job.Job, qopts ...pg.QOpt) (services } else if !d.peerWrapper.IsStarted() { return nil, errors.New("peerWrapper is not started. OCR2 jobs require a started and running p2p v2 peer") } - relayer, exists := d.relayers[spec.Relay] - if !exists { - return nil, errors.Errorf("%s relay does not exist is it enabled?", spec.Relay) + s := spec.AsOCR2Spec() + chainID, err := (&s).GetChainID() + if err != nil { + return nil, err + } + relayID := relay.Identifier{Network: spec.Relay, ChainID: chainID} + relayer, err := d.RelayGetter.Get(relayID) + if err != nil { + return nil, fmt.Errorf("failed to get relay %s is it enabled?: %w", spec.Relay, err) } if spec.FeedID != nil { spec.RelayConfig["feedID"] = *spec.FeedID diff --git a/core/services/ocrcommon/data_source.go b/core/services/ocrcommon/data_source.go index 03f5a33500b..4ea7cb7a9a9 100644 --- a/core/services/ocrcommon/data_source.go +++ b/core/services/ocrcommon/data_source.go @@ -15,6 +15,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) diff --git a/core/services/pipeline/common.go b/core/services/pipeline/common.go index c2b19c30a9c..8cc54d540fb 100644 --- a/core/services/pipeline/common.go +++ b/core/services/pipeline/common.go @@ -20,7 +20,6 @@ import ( pkgerrors "github.com/pkg/errors" "gopkg.in/guregu/null.v4" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config" "github.com/smartcontractkit/chainlink/v2/core/logger" cnull "github.com/smartcontractkit/chainlink/v2/core/null" @@ -546,23 +545,13 @@ func CheckInputs(inputs []Result, minLen, maxLen, maxErrors int) ([]interface{}, return vals, nil } -func getChainByString(chainSet evm.ChainSet, str string) (evm.Chain, error) { - if str == "" { - return chainSet.Default() - } - id, ok := new(big.Int).SetString(str, 10) - if !ok { - return nil, pkgerrors.Errorf("invalid EVM chain ID: %s", str) - } - return chainSet.Get(id) -} +var ErrInvalidEVMChainID = errors.New("invalid EVM chain ID") -func SelectGasLimit(cfg config.ChainScopedConfig, jobType string, specGasLimit *uint32) uint32 { +func SelectGasLimit(ge config.GasEstimator, jobType string, specGasLimit *uint32) uint32 { if specGasLimit != nil { return *specGasLimit } - ge := cfg.EVM().GasEstimator() jt := ge.LimitJobType() var jobTypeGasLimit *uint32 switch jobType { diff --git a/core/services/pipeline/common_test.go b/core/services/pipeline/common_test.go index 558fe7bfe59..37cc60f27e9 100644 --- a/core/services/pipeline/common_test.go +++ b/core/services/pipeline/common_test.go @@ -338,42 +338,42 @@ func TestSelectGasLimit(t *testing.T) { t.Run("spec defined gas limit", func(t *testing.T) { var specGasLimit uint32 = 1 - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.DirectRequestJobType, &specGasLimit) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.DirectRequestJobType, &specGasLimit) assert.Equal(t, uint32(1), gasLimit) }) t.Run("direct request specific gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.DirectRequestJobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.DirectRequestJobType, nil) assert.Equal(t, uint32(100), gasLimit) }) t.Run("OCR specific gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.OffchainReportingJobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.OffchainReportingJobType, nil) assert.Equal(t, uint32(103), gasLimit) }) t.Run("OCR2 specific gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.OffchainReporting2JobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.OffchainReporting2JobType, nil) assert.Equal(t, uint32(105), gasLimit) }) t.Run("VRF specific gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.VRFJobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.VRFJobType, nil) assert.Equal(t, uint32(101), gasLimit) }) t.Run("flux monitor specific gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.FluxMonitorJobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.FluxMonitorJobType, nil) assert.Equal(t, uint32(102), gasLimit) }) t.Run("keeper specific gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.KeeperJobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.KeeperJobType, nil) assert.Equal(t, uint32(104), gasLimit) }) t.Run("fallback to default gas limit", func(t *testing.T) { - gasLimit := pipeline.SelectGasLimit(cfg, pipeline.WebhookJobType, nil) + gasLimit := pipeline.SelectGasLimit(cfg.EVM().GasEstimator(), pipeline.WebhookJobType, nil) assert.Equal(t, uint32(999), gasLimit) }) } diff --git a/core/services/pipeline/helpers_test.go b/core/services/pipeline/helpers_test.go index 3a7d1fc8161..974ff29d11c 100644 --- a/core/services/pipeline/helpers_test.go +++ b/core/services/pipeline/helpers_test.go @@ -50,15 +50,15 @@ func (t *HTTPTask) HelperSetDependencies(config Config, restrictedHTTPClient, un t.unrestrictedHTTPClient = unrestrictedHTTPClient } -func (t *ETHCallTask) HelperSetDependencies(cc evm.ChainSet, config Config, specGasLimit *uint32, jobType string) { - t.chainSet = cc +func (t *ETHCallTask) HelperSetDependencies(legacyChains evm.LegacyChainContainer, config Config, specGasLimit *uint32, jobType string) { + t.legacyChains = legacyChains t.config = config t.specGasLimit = specGasLimit t.jobType = jobType } -func (t *ETHTxTask) HelperSetDependencies(cc evm.ChainSet, keyStore ETHKeyStore, specGasLimit *uint32, jobType string) { - t.chainSet = cc +func (t *ETHTxTask) HelperSetDependencies(legacyChains evm.LegacyChainContainer, keyStore ETHKeyStore, specGasLimit *uint32, jobType string) { + t.legacyChains = legacyChains t.keyStore = keyStore t.specGasLimit = specGasLimit t.jobType = jobType diff --git a/core/services/pipeline/orm_test.go b/core/services/pipeline/orm_test.go index 722524d6e56..4c03ce16ef8 100644 --- a/core/services/pipeline/orm_test.go +++ b/core/services/pipeline/orm_test.go @@ -23,6 +23,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -520,8 +521,9 @@ func Test_GetUnfinishedRuns_Keepers(t *testing.T) { porm := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgeORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jorm := job.NewORM(db, cc, porm, bridgeORM, keyStore, lggr, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jorm := job.NewORM(db, legacyChains, porm, bridgeORM, keyStore, lggr, config.Database()) defer func() { assert.NoError(t, jorm.Close()) }() timestamp := time.Now() @@ -621,8 +623,9 @@ func Test_GetUnfinishedRuns_DirectRequest(t *testing.T) { porm := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgeORM := bridges.NewORM(db, lggr, config.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jorm := job.NewORM(db, cc, porm, bridgeORM, keyStore, lggr, config.Database()) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + jorm := job.NewORM(db, legacyChains, porm, bridgeORM, keyStore, lggr, config.Database()) defer func() { assert.NoError(t, jorm.Close()) }() timestamp := time.Now() diff --git a/core/services/pipeline/runner.go b/core/services/pipeline/runner.go index 05d6735dde9..7a755e8fe11 100644 --- a/core/services/pipeline/runner.go +++ b/core/services/pipeline/runner.go @@ -20,6 +20,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/recovery" "github.com/smartcontractkit/chainlink/v2/core/services" "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -55,7 +56,7 @@ type runner struct { btORM bridges.ORM config Config bridgeConfig BridgeConfig - chainSet evm.ChainSet + legacyEVMChains evm.LegacyChainContainer ethKeyStore ETHKeyStore vrfKeyStore VRFKeyStore runReaperWorker utils.SleeperTask @@ -101,13 +102,13 @@ var ( ) ) -func NewRunner(orm ORM, btORM bridges.ORM, cfg Config, bridgeCfg BridgeConfig, chainSet evm.ChainSet, ethks ETHKeyStore, vrfks VRFKeyStore, lggr logger.Logger, httpClient, unrestrictedHTTPClient *http.Client) *runner { +func NewRunner(orm ORM, btORM bridges.ORM, cfg Config, bridgeCfg BridgeConfig, legacyChains evm.LegacyChainContainer, ethks ETHKeyStore, vrfks VRFKeyStore, lggr logger.Logger, httpClient, unrestrictedHTTPClient *http.Client) *runner { r := &runner{ orm: orm, btORM: btORM, config: cfg, bridgeConfig: bridgeCfg, - chainSet: chainSet, + legacyEVMChains: legacyChains, ethKeyStore: ethks, vrfKeyStore: vrfks, chStop: make(chan struct{}), @@ -260,7 +261,7 @@ func (r *runner) initializePipeline(run *Run) (*Pipeline, error) { // may run external adapters on their own hardware task.(*BridgeTask).httpClient = r.unrestrictedHTTPClient case TaskTypeETHCall: - task.(*ETHCallTask).chainSet = r.chainSet + task.(*ETHCallTask).legacyChains = r.legacyEVMChains task.(*ETHCallTask).config = r.config task.(*ETHCallTask).specGasLimit = run.PipelineSpec.GasLimit task.(*ETHCallTask).jobType = run.PipelineSpec.JobType @@ -271,12 +272,12 @@ func (r *runner) initializePipeline(run *Run) (*Pipeline, error) { case TaskTypeVRFV2Plus: task.(*VRFTaskV2Plus).keyStore = r.vrfKeyStore case TaskTypeEstimateGasLimit: - task.(*EstimateGasLimitTask).chainSet = r.chainSet + task.(*EstimateGasLimitTask).legacyChains = r.legacyEVMChains task.(*EstimateGasLimitTask).specGasLimit = run.PipelineSpec.GasLimit task.(*EstimateGasLimitTask).jobType = run.PipelineSpec.JobType case TaskTypeETHTx: task.(*ETHTxTask).keyStore = r.ethKeyStore - task.(*ETHTxTask).chainSet = r.chainSet + task.(*ETHTxTask).legacyChains = r.legacyEVMChains task.(*ETHTxTask).specGasLimit = run.PipelineSpec.GasLimit task.(*ETHTxTask).jobType = run.PipelineSpec.JobType task.(*ETHTxTask).forwardingAllowed = run.PipelineSpec.ForwardingAllowed diff --git a/core/services/pipeline/runner_test.go b/core/services/pipeline/runner_test.go index e2918cf8385..2554315a46c 100644 --- a/core/services/pipeline/runner_test.go +++ b/core/services/pipeline/runner_test.go @@ -20,6 +20,8 @@ import ( "github.com/stretchr/testify/require" "gopkg.in/guregu/null.v4" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" + "github.com/smartcontractkit/chainlink/v2/core/bridges" bridgesMocks "github.com/smartcontractkit/chainlink/v2/core/bridges/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" @@ -41,13 +43,14 @@ import ( func newRunner(t testing.TB, db *sqlx.DB, bridgeORM bridges.ORM, cfg chainlink.GeneralConfig) (pipeline.Runner, *mocks.ORM) { lggr := logger.TestLogger(t) ethKeyStore := cltest.NewKeyStore(t, db, cfg.Database()).Eth() - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, KeyStore: ethKeyStore}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) orm := mocks.NewORM(t) q := pg.NewQ(db, lggr, cfg.Database()) orm.On("GetQ").Return(q).Maybe() c := clhttptest.NewTestLocalOnlyHTTPClient() - r := pipeline.NewRunner(orm, bridgeORM, cfg.JobPipeline(), cfg.WebServer(), cc, ethKeyStore, nil, logger.TestLogger(t), c, c) + r := pipeline.NewRunner(orm, bridgeORM, cfg.JobPipeline(), cfg.WebServer(), legacyChains, ethKeyStore, nil, logger.TestLogger(t), c, c) return r, orm } @@ -477,9 +480,10 @@ func Test_PipelineRunner_HandleFaultsPersistRun(t *testing.T) { Return(nil) cfg := configtest.NewTestGeneralConfig(t) ethKeyStore := cltest.NewKeyStore(t, db, cfg.Database()).Eth() - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, KeyStore: ethKeyStore}) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, KeyStore: ethKeyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) lggr := logger.TestLogger(t) - r := pipeline.NewRunner(orm, btORM, cfg.JobPipeline(), cfg.WebServer(), cc, ethKeyStore, nil, lggr, nil, nil) + r := pipeline.NewRunner(orm, btORM, cfg.JobPipeline(), cfg.WebServer(), legacyChains, ethKeyStore, nil, lggr, nil, nil) spec := pipeline.Spec{DotDagSource: ` fail_but_i_dont_care [type=fail] diff --git a/core/services/pipeline/task.estimategas.go b/core/services/pipeline/task.estimategas.go index 5bf82837cb8..967fb7ca034 100644 --- a/core/services/pipeline/task.estimategas.go +++ b/core/services/pipeline/task.estimategas.go @@ -2,6 +2,7 @@ package pipeline import ( "context" + "fmt" "math" "strconv" @@ -29,7 +30,7 @@ type EstimateGasLimitTask struct { EVMChainID string `json:"evmChainID" mapstructure:"evmChainID"` specGasLimit *uint32 - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer jobType string } @@ -64,11 +65,13 @@ func (t *EstimateGasLimitTask) Run(ctx context.Context, lggr logger.Logger, vars return Result{Error: err}, runInfo } - chain, err := getChainByString(t.chainSet, t.EVMChainID) + chain, err := t.legacyChains.Get(t.EVMChainID) if err != nil { - return Result{Error: err}, retryableRunInfo() + err = fmt.Errorf("%w: %s: %w", ErrInvalidEVMChainID, t.EVMChainID, err) + return Result{Error: err}, runInfo } - maximumGasLimit := SelectGasLimit(chain.Config(), t.jobType, t.specGasLimit) + + maximumGasLimit := SelectGasLimit(chain.Config().EVM().GasEstimator(), t.jobType, t.specGasLimit) to := common.Address(toAddr) gasLimit, err := chain.Client().EstimateGas(ctx, ethereum.CallMsg{ From: common.Address(fromAddr), diff --git a/core/services/pipeline/task.eth_call.go b/core/services/pipeline/task.eth_call.go index b93e3c45c66..f3c76d404d4 100644 --- a/core/services/pipeline/task.eth_call.go +++ b/core/services/pipeline/task.eth_call.go @@ -2,6 +2,7 @@ package pipeline import ( "context" + "fmt" "time" "github.com/ethereum/go-ethereum" @@ -34,7 +35,7 @@ type ETHCallTask struct { EVMChainID string `json:"evmChainID" mapstructure:"evmChainID"` specGasLimit *uint32 - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer config Config jobType string } @@ -88,10 +89,12 @@ func (t *ETHCallTask) Run(ctx context.Context, lggr logger.Logger, vars Vars, in return Result{Error: errors.Wrapf(ErrBadInput, "data param must not be empty")}, runInfo } - chain, err := getChainByString(t.chainSet, string(chainID)) + chain, err := t.legacyChains.Get(string(chainID)) if err != nil { + err = fmt.Errorf("%w: %s: %w", ErrInvalidEVMChainID, chainID, err) return Result{Error: err}, runInfo } + var selectedGas uint32 if gasUnlimited { if gas > 0 { @@ -101,7 +104,7 @@ func (t *ETHCallTask) Run(ctx context.Context, lggr logger.Logger, vars Vars, in if gas > 0 { selectedGas = uint32(gas) } else { - selectedGas = SelectGasLimit(chain.Config(), t.jobType, t.specGasLimit) + selectedGas = SelectGasLimit(chain.Config().EVM().GasEstimator(), t.jobType, t.specGasLimit) } } diff --git a/core/services/pipeline/task.eth_call_test.go b/core/services/pipeline/task.eth_call_test.go index 7686caa1e70..b8896488e2d 100644 --- a/core/services/pipeline/task.eth_call_test.go +++ b/core/services/pipeline/task.eth_call_test.go @@ -11,6 +11,7 @@ import ( "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" txmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr/mocks" @@ -24,6 +25,7 @@ import ( keystoremocks "github.com/smartcontractkit/chainlink/v2/core/services/keystore/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" pipelinemocks "github.com/smartcontractkit/chainlink/v2/core/services/pipeline/mocks" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) func TestETHCallTask(t *testing.T) { @@ -225,7 +227,7 @@ func TestETHCallTask(t *testing.T) { On("CallContract", mock.Anything, ethereum.CallMsg{To: &contractAddr, Data: []byte("foo bar")}, (*big.Int)(nil)). Return([]byte("baz quux"), nil).Maybe() }, - nil, nil, "not found", + nil, nil, chains.ErrNoSuchChainID.Error(), }, } @@ -255,14 +257,15 @@ func TestETHCallTask(t *testing.T) { txManager := txmmocks.NewMockEvmTxManager(t) db := pgtest.NewSqlxDB(t) - var cc evm.ChainSet + var legacyChains evm.LegacyChainContainer if test.expectedErrorCause != nil || test.expectedErrorContains != "" { - cc = evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, TxManager: txManager, KeyStore: keyStore}) + exts := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, TxManager: txManager, KeyStore: keyStore}) + legacyChains = evmrelay.NewLegacyChainsFromRelayerExtenders(exts) } else { - cc = cltest.NewChainSetMockWithOneChain(t, ethClient, evmtest.NewChainScopedConfig(t, cfg)) + legacyChains = cltest.NewLegacyChainsWithMockChain(t, ethClient, cfg) } - task.HelperSetDependencies(cc, cfg.JobPipeline(), test.specGasLimit, pipeline.DirectRequestJobType) + task.HelperSetDependencies(legacyChains, cfg.JobPipeline(), test.specGasLimit, pipeline.DirectRequestJobType) result, runInfo := task.Run(testutils.Context(t), lggr, test.vars, test.inputs) assert.False(t, runInfo.IsPending) diff --git a/core/services/pipeline/task.eth_tx.go b/core/services/pipeline/task.eth_tx.go index c0585b5448d..8761732e4f0 100644 --- a/core/services/pipeline/task.eth_tx.go +++ b/core/services/pipeline/task.eth_tx.go @@ -2,6 +2,7 @@ package pipeline import ( "context" + "fmt" "math/big" "reflect" "strconv" @@ -41,7 +42,7 @@ type ETHTxTask struct { forwardingAllowed bool specGasLimit *uint32 keyStore ETHKeyStore - chainSet evm.ChainSet + legacyChains evm.LegacyChainContainer jobType string } @@ -62,18 +63,20 @@ func (t *ETHTxTask) Run(_ context.Context, lggr logger.Logger, vars Vars, inputs return Result{Error: err}, runInfo } - chain, err := getChainByString(t.chainSet, string(chainID)) + chain, err := t.legacyChains.Get(string(chainID)) if err != nil { - return Result{Error: errors.Wrapf(err, "failed to get chain by id: %v", t.EVMChainID)}, retryableRunInfo() + err = fmt.Errorf("%w: %s: %w", ErrInvalidEVMChainID, chainID, err) + return Result{Error: err}, retryableRunInfo() } - cfg := chain.Config() + + cfg := chain.Config().EVM() txManager := chain.TxManager() _, err = CheckInputs(inputs, -1, -1, 0) if err != nil { return Result{Error: errors.Wrap(err, "task inputs")}, runInfo } - maximumGasLimit := SelectGasLimit(cfg, t.jobType, t.specGasLimit) + maximumGasLimit := SelectGasLimit(cfg.GasEstimator(), t.jobType, t.specGasLimit) var ( fromAddrs AddressSliceParam @@ -102,7 +105,7 @@ func (t *ETHTxTask) Run(_ context.Context, lggr logger.Logger, vars Vars, inputs if min, isSet := maybeMinConfirmations.Uint64(); isSet { minOutgoingConfirmations = min } else { - minOutgoingConfirmations = uint64(cfg.EVM().FinalityDepth()) + minOutgoingConfirmations = uint64(cfg.FinalityDepth()) } txMeta, err := decodeMeta(txMetaMap) diff --git a/core/services/pipeline/task.eth_tx_test.go b/core/services/pipeline/task.eth_tx_test.go index 0afd008d88e..d465c16f8fd 100644 --- a/core/services/pipeline/task.eth_tx_test.go +++ b/core/services/pipeline/task.eth_tx_test.go @@ -11,6 +11,7 @@ import ( "gopkg.in/guregu/null.v4" txmgrcommon "github.com/smartcontractkit/chainlink/v2/common/txmgr" + "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" txmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" @@ -22,6 +23,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" keystoremocks "github.com/smartcontractkit/chainlink/v2/core/services/keystore/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) func TestETHTxTask(t *testing.T) { @@ -541,7 +543,7 @@ func TestETHTxTask(t *testing.T) { nil, func(keyStore *keystoremocks.Eth, txManager *txmmocks.MockEvmTxManager) { }, - nil, nil, "not found", pipeline.RunInfo{IsRetryable: true}, + nil, nil, chains.ErrNoSuchChainID.Error(), pipeline.RunInfo{IsRetryable: true}, }, } @@ -571,11 +573,12 @@ func TestETHTxTask(t *testing.T) { }) lggr := logger.TestLogger(t) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, TxManager: txManager, KeyStore: keyStore}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) test.setupClientMocks(keyStore, txManager) - task.HelperSetDependencies(cc, keyStore, test.specGasLimit, pipeline.DirectRequestJobType) + task.HelperSetDependencies(legacyChains, keyStore, test.specGasLimit, pipeline.DirectRequestJobType) result, runInfo := task.Run(testutils.Context(t), lggr, test.vars, test.inputs) assert.Equal(t, test.expectedRunInfo, runInfo) diff --git a/core/services/relay/evm/evm.go b/core/services/relay/evm/evm.go index b630bf13187..86cb1cf433e 100644 --- a/core/services/relay/evm/evm.go +++ b/core/services/relay/evm/evm.go @@ -47,23 +47,28 @@ var _ relaytypes.Relayer = &Relayer{} type Relayer struct { db *sqlx.DB - chainSet evm.ChainSet + chain evm.Chain lggr logger.Logger - cfg pg.QConfig - ks keystore.Master + ks CSAETHKeystore mercuryPool wsrpc.Pool eventBroadcaster pg.EventBroadcaster + pgCfg pg.QConfig +} + +type CSAETHKeystore interface { + CSA() keystore.CSA + Eth() keystore.Eth } -func NewRelayer(db *sqlx.DB, chainSet evm.ChainSet, lggr logger.Logger, cfg pg.QConfig, ks keystore.Master, eventBroadcaster pg.EventBroadcaster) *Relayer { +func NewRelayer(db *sqlx.DB, chain evm.Chain, cfg pg.QConfig, lggr logger.Logger, ks CSAETHKeystore, eventBroadcaster pg.EventBroadcaster) *Relayer { return &Relayer{ db: db, - chainSet: chainSet, + chain: chain, lggr: lggr.Named("Relayer"), - cfg: cfg, ks: ks, mercuryPool: wsrpc.NewPool(lggr.Named("Mercury.WSRPCPool")), eventBroadcaster: eventBroadcaster, + pgCfg: cfg, } } @@ -87,15 +92,15 @@ func (r *Relayer) Ready() error { func (r *Relayer) HealthReport() (report map[string]error) { report = make(map[string]error) - maps.Copy(report, r.chainSet.HealthReport()) maps.Copy(report, r.mercuryPool.HealthReport()) return } func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs) (relaytypes.MercuryProvider, error) { - var relayConfig types.RelayConfig - if err := json.Unmarshal(rargs.RelayConfig, &relayConfig); err != nil { - return nil, errors.WithStack(err) + relayOpts := types.NewRelayOpts(rargs) + relayConfig, err := relayOpts.RelayConfig() + if err != nil { + return nil, fmt.Errorf("failed to get relay config: %w", err) } var mercuryConfig mercuryconfig.PluginConfig @@ -107,7 +112,10 @@ func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytype return nil, errors.New("FeedID must be specified") } - configWatcher, err := newConfigProvider(r.lggr, r.chainSet, rargs, r.eventBroadcaster) + if relayConfig.ChainID.String() != r.chain.ID().String() { + return nil, fmt.Errorf("internal error: chain id in spec does not match this relayer's chain: have %s expected %s", relayConfig.ChainID.String(), r.chain.ID().String()) + } + configWatcher, err := newConfigProvider(r.lggr, r.chain, relayOpts, r.eventBroadcaster) if err != nil { return nil, errors.WithStack(err) } @@ -131,19 +139,28 @@ func (r *Relayer) NewMercuryProvider(rargs relaytypes.RelayArgs, pargs relaytype if err != nil { return nil, err } - transmitter := mercury.NewTransmitter(r.lggr, configWatcher.ContractConfigTracker(), client, privKey.PublicKey, *relayConfig.FeedID, r.db, r.cfg) + transmitter := mercury.NewTransmitter(r.lggr, configWatcher.ContractConfigTracker(), client, privKey.PublicKey, *relayConfig.FeedID, r.db, r.pgCfg) return NewMercuryProvider(configWatcher, transmitter, reportCodecV1, reportCodecV2, reportCodecV3, r.lggr), nil } func (r *Relayer) NewFunctionsProvider(rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs) (relaytypes.FunctionsProvider, error) { - // TODO(FUN-668): Not ready yet (doesn't implement FunctionsEvents() properly). - // Currently only used by the bootstrap job. - return NewFunctionsProvider(r.chainSet, rargs, pargs, r.lggr, r.ks.Eth(), functions.FunctionsPlugin) + // TODO(FUN-668): Not ready yet (doesn't implement FunctionsEvents() properly) + return NewFunctionsProvider(r.chain, rargs, pargs, r.lggr, r.ks.Eth(), functions.FunctionsPlugin) } func (r *Relayer) NewConfigProvider(args relaytypes.RelayArgs) (relaytypes.ConfigProvider, error) { - configProvider, err := newConfigProvider(r.lggr, r.chainSet, args, r.eventBroadcaster) + relayOpts := types.NewRelayOpts(args) + relayConfig, err := relayOpts.RelayConfig() + if err != nil { + return nil, fmt.Errorf("failed to get relay config: %w", err) + } + expectedChainID := relayConfig.ChainID.String() + if expectedChainID != r.chain.ID().String() { + return nil, fmt.Errorf("internal error: chain id in spec does not match this relayer's chain: have %s expected %s", relayConfig.ChainID.String(), r.chain.ID().String()) + } + + configProvider, err := newConfigProvider(r.lggr, r.chain, relayOpts, r.eventBroadcaster) if err != nil { // Never return (*configProvider)(nil) return nil, err @@ -255,27 +272,22 @@ func (c *configWatcher) ContractConfigTracker() ocrtypes.ContractConfigTracker { return c.configPoller } -func newConfigProvider(lggr logger.Logger, chainSet evm.ChainSet, args relaytypes.RelayArgs, eventBroadcaster pg.EventBroadcaster) (*configWatcher, error) { - var relayConfig types.RelayConfig - err := json.Unmarshal(args.RelayConfig, &relayConfig) - if err != nil { - return nil, err - } - chain, err := chainSet.Get(relayConfig.ChainID.ToInt()) - if err != nil { - return nil, err - } - if !common.IsHexAddress(args.ContractID) { +func newConfigProvider(lggr logger.Logger, chain evm.Chain, opts *types.RelayOpts, eventBroadcaster pg.EventBroadcaster) (*configWatcher, error) { + if !common.IsHexAddress(opts.ContractID) { return nil, errors.Errorf("invalid contractID, expected hex address") } - contractAddress := common.HexToAddress(args.ContractID) + contractAddress := common.HexToAddress(opts.ContractID) contractABI, err := abi.JSON(strings.NewReader(ocr2aggregator.OCR2AggregatorMetaData.ABI)) if err != nil { return nil, errors.Wrap(err, "could not get contract ABI JSON") } var cp types.ConfigPoller + relayConfig, err := opts.RelayConfig() + if err != nil { + return nil, fmt.Errorf("failed to get relay config: %w", err) + } if relayConfig.FeedID != nil { cp, err = mercury.NewConfigPoller( lggr, @@ -305,7 +317,7 @@ func newConfigProvider(lggr logger.Logger, chainSet evm.ChainSet, args relaytype ContractAddress: contractAddress, } } - return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, relayConfig.FromBlock, args.New), nil + return newConfigWatcher(lggr, contractAddress, contractABI, offchainConfigDigester, cp, chain, relayConfig.FromBlock, opts.New), nil } func newContractTransmitter(lggr logger.Logger, rargs relaytypes.RelayArgs, transmitterID string, configWatcher *configWatcher, ethKeystore keystore.Eth) (*contractTransmitter, error) { @@ -427,15 +439,21 @@ func newPipelineContractTransmitter(lggr logger.Logger, rargs relaytypes.RelayAr } func (r *Relayer) NewMedianProvider(rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs) (relaytypes.MedianProvider, error) { - configWatcher, err := newConfigProvider(r.lggr, r.chainSet, rargs, r.eventBroadcaster) + relayOpts := types.NewRelayOpts(rargs) + relayConfig, err := relayOpts.RelayConfig() if err != nil { - return nil, err + return nil, fmt.Errorf("failed to get relay config: %w", err) + } + expectedChainID := relayConfig.ChainID.String() + if expectedChainID != r.chain.ID().String() { + return nil, fmt.Errorf("internal error: chain id in spec does not match this relayer's chain: have %s expected %s", relayConfig.ChainID.String(), r.chain.ID().String()) } - var relayConfig types.RelayConfig - if err = json.Unmarshal(rargs.RelayConfig, &relayConfig); err != nil { + configWatcher, err := newConfigProvider(r.lggr, r.chain, relayOpts, r.eventBroadcaster) + if err != nil { return nil, err } + var contractTransmitter ContractTransmitter var reportCodec median.ReportCodec diff --git a/core/services/relay/evm/functions.go b/core/services/relay/evm/functions.go index ad0588e01e6..43a3d2ff86f 100644 --- a/core/services/relay/evm/functions.go +++ b/core/services/relay/evm/functions.go @@ -3,6 +3,7 @@ package evm import ( "context" "encoding/json" + "fmt" "strings" "github.com/ethereum/go-ethereum/accounts/abi" @@ -82,13 +83,16 @@ func (p *functionsProvider) Name() string { return p.configWatcher.Name() } -func NewFunctionsProvider(chainSet evm.ChainSet, rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs, lggr logger.Logger, ethKeystore keystore.Eth, pluginType functionsRelay.FunctionsPluginType) (evmRelayTypes.FunctionsProvider, error) { - var relayConfig evmRelayTypes.RelayConfig - err := json.Unmarshal(rargs.RelayConfig, &relayConfig) +func NewFunctionsProvider(chain evm.Chain, rargs relaytypes.RelayArgs, pargs relaytypes.PluginArgs, lggr logger.Logger, ethKeystore keystore.Eth, pluginType functionsRelay.FunctionsPluginType) (evmRelayTypes.FunctionsProvider, error) { + relayOpts := evmRelayTypes.NewRelayOpts(rargs) + relayConfig, err := relayOpts.RelayConfig() if err != nil { return nil, err } - chain, err := chainSet.Get(relayConfig.ChainID.ToInt()) + expectedChainID := relayConfig.ChainID.String() + if expectedChainID != chain.ID().String() { + return nil, fmt.Errorf("internal error: chain id in spec does not match this relayer's chain: have %s expected %s", relayConfig.ChainID.String(), chain.ID().String()) + } if err != nil { return nil, err } diff --git a/core/services/relay/evm/loop_impl.go b/core/services/relay/evm/loop_impl.go new file mode 100644 index 00000000000..02a9194b380 --- /dev/null +++ b/core/services/relay/evm/loop_impl.go @@ -0,0 +1,36 @@ +package evm + +import ( + "github.com/smartcontractkit/chainlink-relay/pkg/loop" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" +) + +//go:generate mockery --quiet --name LoopRelayAdapter --output ./mocks/ --case=underscore +type LoopRelayAdapter interface { + loop.Relayer + Chain() evm.Chain + Default() bool +} +type LoopRelayer struct { + loop.Relayer + ext EVMChainRelayerExtender +} + +var _ loop.Relayer = &LoopRelayer{} + +func NewLoopRelayAdapter(r *Relayer, cs EVMChainRelayerExtender) *LoopRelayer { + ra := relay.NewRelayerAdapter(r, cs) + return &LoopRelayer{ + Relayer: ra, + ext: cs, + } +} + +func (la *LoopRelayer) Chain() evm.Chain { + return la.ext.Chain() +} + +func (la *LoopRelayer) Default() bool { + return la.ext.Default() +} diff --git a/core/services/relay/evm/mercury/v1/data_source.go b/core/services/relay/evm/mercury/v1/data_source.go index 1bdbd725c88..ff7a2c0ab7f 100644 --- a/core/services/relay/evm/mercury/v1/data_source.go +++ b/core/services/relay/evm/mercury/v1/data_source.go @@ -17,6 +17,7 @@ import ( evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" diff --git a/core/services/relay/evm/mercury/v1/data_source_test.go b/core/services/relay/evm/mercury/v1/data_source_test.go index db52e9f3c7d..d846d64e3d9 100644 --- a/core/services/relay/evm/mercury/v1/data_source_test.go +++ b/core/services/relay/evm/mercury/v1/data_source_test.go @@ -24,10 +24,10 @@ import ( httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" reportcodecv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/reportcodec" @@ -108,7 +108,7 @@ func TestMercury_Observe(t *testing.T) { ds.spec = spec h := commonmocks.NewHeadTracker[*evmtypes.Head, common.Hash](t) - c := evmtest.NewEthClientMock(t) + c := evmclimocks.NewClient(t) ht := &mockHeadTracker{ c: c, h: h, @@ -196,7 +196,7 @@ func TestMercury_Observe(t *testing.T) { h2 := commonmocks.NewHeadTracker[*evmtypes.Head, common.Hash](t) h2.On("LatestChain").Return((*evmtypes.Head)(nil)) ht.h = h2 - c2 := evmtest.NewEthClientMock(t) + c2 := evmclimocks.NewClient(t) c2.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(nil, errors.New("head retrieval failed")) ht.c = c2 @@ -333,7 +333,7 @@ func TestMercury_Observe(t *testing.T) { c.AssertExpectations(t) }) t.Run("if call fails, returns error for that observation", func(t *testing.T) { - c = evmtest.NewEthClientMock(t) + c = evmclimocks.NewClient(t) ht.c = c c.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(nil, errors.New("client call failed")).Once() diff --git a/core/chains/evm/mocks/chain_set.go b/core/services/relay/evm/mocks/loop_relay_adapter.go similarity index 52% rename from core/chains/evm/mocks/chain_set.go rename to core/services/relay/evm/mocks/loop_relay_adapter.go index 76366c9fb00..b0d9b7cf95e 100644 --- a/core/chains/evm/mocks/chain_set.go +++ b/core/services/relay/evm/mocks/loop_relay_adapter.go @@ -7,34 +7,34 @@ import ( big "math/big" evm "github.com/smartcontractkit/chainlink/v2/core/chains/evm" - evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" - mock "github.com/stretchr/testify/mock" types "github.com/smartcontractkit/chainlink-relay/pkg/types" ) -// ChainSet is an autogenerated mock type for the ChainSet type -type ChainSet struct { +// LoopRelayAdapter is an autogenerated mock type for the LoopRelayAdapter type +type LoopRelayAdapter struct { mock.Mock } -// ChainCount provides a mock function with given fields: -func (_m *ChainSet) ChainCount() int { +// Chain provides a mock function with given fields: +func (_m *LoopRelayAdapter) Chain() evm.Chain { ret := _m.Called() - var r0 int - if rf, ok := ret.Get(0).(func() int); ok { + var r0 evm.Chain + if rf, ok := ret.Get(0).(func() evm.Chain); ok { r0 = rf() } else { - r0 = ret.Get(0).(int) + if ret.Get(0) != nil { + r0 = ret.Get(0).(evm.Chain) + } } return r0 } // ChainStatus provides a mock function with given fields: ctx, id -func (_m *ChainSet) ChainStatus(ctx context.Context, id string) (types.ChainStatus, error) { +func (_m *LoopRelayAdapter) ChainStatus(ctx context.Context, id string) (types.ChainStatus, error) { ret := _m.Called(ctx, id) var r0 types.ChainStatus @@ -58,7 +58,7 @@ func (_m *ChainSet) ChainStatus(ctx context.Context, id string) (types.ChainStat } // ChainStatuses provides a mock function with given fields: ctx, offset, limit -func (_m *ChainSet) ChainStatuses(ctx context.Context, offset int, limit int) ([]types.ChainStatus, int, error) { +func (_m *LoopRelayAdapter) ChainStatuses(ctx context.Context, offset int, limit int) ([]types.ChainStatus, int, error) { ret := _m.Called(ctx, offset, limit) var r0 []types.ChainStatus @@ -90,71 +90,83 @@ func (_m *ChainSet) ChainStatuses(ctx context.Context, offset int, limit int) ([ return r0, r1, r2 } -// Chains provides a mock function with given fields: -func (_m *ChainSet) Chains() []evm.Chain { +// Close provides a mock function with given fields: +func (_m *LoopRelayAdapter) Close() error { ret := _m.Called() - var r0 []evm.Chain - if rf, ok := ret.Get(0).(func() []evm.Chain); ok { + var r0 error + if rf, ok := ret.Get(0).(func() error); ok { r0 = rf() } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]evm.Chain) - } + r0 = ret.Error(0) } return r0 } -// Close provides a mock function with given fields: -func (_m *ChainSet) Close() error { +// Default provides a mock function with given fields: +func (_m *LoopRelayAdapter) Default() bool { ret := _m.Called() - var r0 error - if rf, ok := ret.Get(0).(func() error); ok { + var r0 bool + if rf, ok := ret.Get(0).(func() bool); ok { r0 = rf() } else { - r0 = ret.Error(0) + r0 = ret.Get(0).(bool) } return r0 } -// Configs provides a mock function with given fields: -func (_m *ChainSet) Configs() evmtypes.Configs { +// HealthReport provides a mock function with given fields: +func (_m *LoopRelayAdapter) HealthReport() map[string]error { ret := _m.Called() - var r0 evmtypes.Configs - if rf, ok := ret.Get(0).(func() evmtypes.Configs); ok { + var r0 map[string]error + if rf, ok := ret.Get(0).(func() map[string]error); ok { r0 = rf() } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(evmtypes.Configs) + r0 = ret.Get(0).(map[string]error) } } return r0 } -// Default provides a mock function with given fields: -func (_m *ChainSet) Default() (evm.Chain, error) { +// Name provides a mock function with given fields: +func (_m *LoopRelayAdapter) Name() string { ret := _m.Called() - var r0 evm.Chain + var r0 string + if rf, ok := ret.Get(0).(func() string); ok { + r0 = rf() + } else { + r0 = ret.Get(0).(string) + } + + return r0 +} + +// NewConfigProvider provides a mock function with given fields: _a0, _a1 +func (_m *LoopRelayAdapter) NewConfigProvider(_a0 context.Context, _a1 types.RelayArgs) (types.ConfigProvider, error) { + ret := _m.Called(_a0, _a1) + + var r0 types.ConfigProvider var r1 error - if rf, ok := ret.Get(0).(func() (evm.Chain, error)); ok { - return rf() + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs) (types.ConfigProvider, error)); ok { + return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func() evm.Chain); ok { - r0 = rf() + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs) types.ConfigProvider); ok { + r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(evm.Chain) + r0 = ret.Get(0).(types.ConfigProvider) } } - if rf, ok := ret.Get(1).(func() error); ok { - r1 = rf() + if rf, ok := ret.Get(1).(func(context.Context, types.RelayArgs) error); ok { + r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) } @@ -162,25 +174,25 @@ func (_m *ChainSet) Default() (evm.Chain, error) { return r0, r1 } -// Get provides a mock function with given fields: id -func (_m *ChainSet) Get(id *big.Int) (evm.Chain, error) { - ret := _m.Called(id) +// NewFunctionsProvider provides a mock function with given fields: _a0, _a1, _a2 +func (_m *LoopRelayAdapter) NewFunctionsProvider(_a0 context.Context, _a1 types.RelayArgs, _a2 types.PluginArgs) (types.FunctionsProvider, error) { + ret := _m.Called(_a0, _a1, _a2) - var r0 evm.Chain + var r0 types.FunctionsProvider var r1 error - if rf, ok := ret.Get(0).(func(*big.Int) (evm.Chain, error)); ok { - return rf(id) + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs, types.PluginArgs) (types.FunctionsProvider, error)); ok { + return rf(_a0, _a1, _a2) } - if rf, ok := ret.Get(0).(func(*big.Int) evm.Chain); ok { - r0 = rf(id) + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs, types.PluginArgs) types.FunctionsProvider); ok { + r0 = rf(_a0, _a1, _a2) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(evm.Chain) + r0 = ret.Get(0).(types.FunctionsProvider) } } - if rf, ok := ret.Get(1).(func(*big.Int) error); ok { - r1 = rf(id) + if rf, ok := ret.Get(1).(func(context.Context, types.RelayArgs, types.PluginArgs) error); ok { + r1 = rf(_a0, _a1, _a2) } else { r1 = ret.Error(1) } @@ -188,38 +200,60 @@ func (_m *ChainSet) Get(id *big.Int) (evm.Chain, error) { return r0, r1 } -// HealthReport provides a mock function with given fields: -func (_m *ChainSet) HealthReport() map[string]error { - ret := _m.Called() +// NewMedianProvider provides a mock function with given fields: _a0, _a1, _a2 +func (_m *LoopRelayAdapter) NewMedianProvider(_a0 context.Context, _a1 types.RelayArgs, _a2 types.PluginArgs) (types.MedianProvider, error) { + ret := _m.Called(_a0, _a1, _a2) - var r0 map[string]error - if rf, ok := ret.Get(0).(func() map[string]error); ok { - r0 = rf() + var r0 types.MedianProvider + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs, types.PluginArgs) (types.MedianProvider, error)); ok { + return rf(_a0, _a1, _a2) + } + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs, types.PluginArgs) types.MedianProvider); ok { + r0 = rf(_a0, _a1, _a2) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(map[string]error) + r0 = ret.Get(0).(types.MedianProvider) } } - return r0 + if rf, ok := ret.Get(1).(func(context.Context, types.RelayArgs, types.PluginArgs) error); ok { + r1 = rf(_a0, _a1, _a2) + } else { + r1 = ret.Error(1) + } + + return r0, r1 } -// Name provides a mock function with given fields: -func (_m *ChainSet) Name() string { - ret := _m.Called() +// NewMercuryProvider provides a mock function with given fields: _a0, _a1, _a2 +func (_m *LoopRelayAdapter) NewMercuryProvider(_a0 context.Context, _a1 types.RelayArgs, _a2 types.PluginArgs) (types.MercuryProvider, error) { + ret := _m.Called(_a0, _a1, _a2) - var r0 string - if rf, ok := ret.Get(0).(func() string); ok { - r0 = rf() + var r0 types.MercuryProvider + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs, types.PluginArgs) (types.MercuryProvider, error)); ok { + return rf(_a0, _a1, _a2) + } + if rf, ok := ret.Get(0).(func(context.Context, types.RelayArgs, types.PluginArgs) types.MercuryProvider); ok { + r0 = rf(_a0, _a1, _a2) } else { - r0 = ret.Get(0).(string) + if ret.Get(0) != nil { + r0 = ret.Get(0).(types.MercuryProvider) + } } - return r0 + if rf, ok := ret.Get(1).(func(context.Context, types.RelayArgs, types.PluginArgs) error); ok { + r1 = rf(_a0, _a1, _a2) + } else { + r1 = ret.Error(1) + } + + return r0, r1 } // NodeStatuses provides a mock function with given fields: ctx, offset, limit, chainIDs -func (_m *ChainSet) NodeStatuses(ctx context.Context, offset int, limit int, chainIDs ...string) ([]types.NodeStatus, int, error) { +func (_m *LoopRelayAdapter) NodeStatuses(ctx context.Context, offset int, limit int, chainIDs ...string) ([]types.NodeStatus, int, error) { _va := make([]interface{}, len(chainIDs)) for _i := range chainIDs { _va[_i] = chainIDs[_i] @@ -259,7 +293,7 @@ func (_m *ChainSet) NodeStatuses(ctx context.Context, offset int, limit int, cha } // Ready provides a mock function with given fields: -func (_m *ChainSet) Ready() error { +func (_m *LoopRelayAdapter) Ready() error { ret := _m.Called() var r0 error @@ -273,7 +307,7 @@ func (_m *ChainSet) Ready() error { } // SendTx provides a mock function with given fields: ctx, chainID, from, to, amount, balanceCheck -func (_m *ChainSet) SendTx(ctx context.Context, chainID string, from string, to string, amount *big.Int, balanceCheck bool) error { +func (_m *LoopRelayAdapter) SendTx(ctx context.Context, chainID string, from string, to string, amount *big.Int, balanceCheck bool) error { ret := _m.Called(ctx, chainID, from, to, amount, balanceCheck) var r0 error @@ -287,7 +321,7 @@ func (_m *ChainSet) SendTx(ctx context.Context, chainID string, from string, to } // Start provides a mock function with given fields: _a0 -func (_m *ChainSet) Start(_a0 context.Context) error { +func (_m *LoopRelayAdapter) Start(_a0 context.Context) error { ret := _m.Called(_a0) var r0 error @@ -300,14 +334,14 @@ func (_m *ChainSet) Start(_a0 context.Context) error { return r0 } -type mockConstructorTestingTNewChainSet interface { +type mockConstructorTestingTNewLoopRelayAdapter interface { mock.TestingT Cleanup(func()) } -// NewChainSet creates a new instance of ChainSet. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. -func NewChainSet(t mockConstructorTestingTNewChainSet) *ChainSet { - mock := &ChainSet{} +// NewLoopRelayAdapter creates a new instance of LoopRelayAdapter. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +func NewLoopRelayAdapter(t mockConstructorTestingTNewLoopRelayAdapter) *LoopRelayAdapter { + mock := &LoopRelayAdapter{} mock.Mock.Test(t) t.Cleanup(func() { mock.AssertExpectations(t) }) diff --git a/core/services/relay/evm/relayer_extender.go b/core/services/relay/evm/relayer_extender.go new file mode 100644 index 00000000000..865816143e2 --- /dev/null +++ b/core/services/relay/evm/relayer_extender.go @@ -0,0 +1,432 @@ +package evm + +import ( + "context" + "fmt" + "math/big" + "sync" + + "github.com/pkg/errors" + "go.uber.org/multierr" + "golang.org/x/exp/maps" + + relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" + + "github.com/smartcontractkit/chainlink/v2/core/chains" + evmchain "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" + evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" +) + +// ErrNoChains indicates that no EVM chains have been started +var ErrNoChains = errors.New("no EVM chains loaded") + +var _ legacyChainSet = &chainSet{} + +type legacyChainSet interface { + services.ServiceCtx + chains.ChainStatuser + chains.NodesStatuser + + Get(id *big.Int) (evmchain.Chain, error) + + Default() (evmchain.Chain, error) + Chains() []evmchain.Chain + ChainCount() int + + Configs() evmtypes.Configs + + SendTx(ctx context.Context, chainID, from, to string, amount *big.Int, balanceCheck bool) error +} + +type EVMChainRelayerExtender interface { + relay.RelayerExt + Chain() evmchain.Chain + Default() bool +} + +type EVMChainRelayerExtenderSlicer interface { + Slice() []EVMChainRelayerExtender + Len() int + ChainNodeConfigs() evmtypes.Configs +} + +type ChainRelayerExtenders struct { + exts []EVMChainRelayerExtender + cfgs evmtypes.Configs +} + +var _ EVMChainRelayerExtenderSlicer = &ChainRelayerExtenders{} + +func NewLegacyChainsFromRelayerExtenders(exts EVMChainRelayerExtenderSlicer) *evmchain.LegacyChains { + + m := make(map[string]evmchain.Chain) + var dflt evmchain.Chain + for _, r := range exts.Slice() { + m[r.Chain().ID().String()] = r.Chain() + if r.Default() { + dflt = r.Chain() + } + } + l := evmchain.NewLegacyChains(exts.ChainNodeConfigs(), m) + if dflt != nil { + l.SetDefault(dflt) + } + return l +} + +func newChainRelayerExtsFromSlice(exts []*ChainRelayerExt) *ChainRelayerExtenders { + temp := make([]EVMChainRelayerExtender, len(exts)) + for i := range exts { + temp[i] = exts[i] + } + return &ChainRelayerExtenders{ + exts: temp, + } +} + +func (c *ChainRelayerExtenders) ChainNodeConfigs() evmtypes.Configs { + return c.cfgs +} + +func (c *ChainRelayerExtenders) Slice() []EVMChainRelayerExtender { + return c.exts +} + +func (c *ChainRelayerExtenders) Len() int { + return len(c.exts) +} + +// implements OneChain +type ChainRelayerExt struct { + chain evmchain.Chain + // TODO remove this altogether. BFC-2440 + cs *chainSet + isDefault bool +} + +var _ EVMChainRelayerExtender = &ChainRelayerExt{} + +func (s *ChainRelayerExt) Chain() evmchain.Chain { + return s.chain +} + +func (s *ChainRelayerExt) Default() bool { + return s.isDefault +} + +var ErrCorruptEVMChain = errors.New("corrupt evm chain") + +func (s *ChainRelayerExt) Start(ctx context.Context) error { + if len(s.cs.chains) > 1 { + err := fmt.Errorf("%w: internal error more than one chain (%d)", ErrCorruptEVMChain, len(s.cs.chains)) + panic(err) + } + return s.cs.Start(ctx) +} + +func (s *ChainRelayerExt) Close() (err error) { + return s.cs.Close() +} + +func (s *ChainRelayerExt) Name() string { + // we set each private chainSet logger to contain the chain id + return s.cs.Name() +} + +func (s *ChainRelayerExt) HealthReport() map[string]error { + return s.cs.HealthReport() +} + +func (s *ChainRelayerExt) Ready() (err error) { + return s.cs.Ready() +} + +var ErrInconsistentChainRelayerExtender = errors.New("inconsistent evm chain relayer extender") + +func (s *ChainRelayerExt) ChainStatus(ctx context.Context, id string) (relaytypes.ChainStatus, error) { + // TODO BCF-2441: update relayer interface + // we need to implement the interface, but passing id doesn't really make sense because there is only + // one chain here. check the id here to provide clear error reporting. + if s.chain.ID().String() != id { + return relaytypes.ChainStatus{}, fmt.Errorf("%w: given id %q does not match expected id %q", ErrInconsistentChainRelayerExtender, id, s.chain.ID()) + } + return s.cs.ChainStatus(ctx, id) +} + +func (s *ChainRelayerExt) ChainStatuses(ctx context.Context, offset, limit int) ([]relaytypes.ChainStatus, int, error) { + stat, err := s.cs.ChainStatus(ctx, s.chain.ID().String()) + if err != nil { + return nil, -1, err + } + return []relaytypes.ChainStatus{stat}, 1, nil + +} + +func (s *ChainRelayerExt) NodeStatuses(ctx context.Context, offset, limit int, chainIDs ...string) (nodes []relaytypes.NodeStatus, count int, err error) { + if len(chainIDs) > 1 { + return nil, -1, fmt.Errorf("single chain chain set only support one chain id. got %v", chainIDs) + } + cid := chainIDs[0] + if cid != s.chain.ID().String() { + return nil, -1, fmt.Errorf("unknown chain id %s. expected %s", cid, s.chain.ID()) + } + return s.cs.NodeStatuses(ctx, offset, limit, chainIDs...) +} + +func (s *ChainRelayerExt) SendTx(ctx context.Context, chainID, from, to string, amount *big.Int, balanceCheck bool) error { + return s.cs.SendTx(ctx, chainID, from, to, amount, balanceCheck) +} + +type chainSet struct { + defaultID *big.Int + chains map[string]evmchain.Chain + startedChains []evmchain.Chain + chainsMu sync.RWMutex + logger logger.Logger + opts evmchain.ChainRelayExtenderConfig +} + +func (cll *chainSet) Start(ctx context.Context) error { + if !cll.opts.GeneralConfig.EVMEnabled() { + cll.logger.Warn("EVM is disabled, no EVM-based chains will be started") + return nil + } + if !cll.opts.GeneralConfig.EVMRPCEnabled() { + cll.logger.Warn("EVM RPC connections are disabled. Chainlink will not connect to any EVM RPC node.") + } + var ms services.MultiStart + for _, c := range cll.Chains() { + if err := ms.Start(ctx, c); err != nil { + return errors.Wrapf(err, "failed to start chain %q", c.ID().String()) + } + cll.startedChains = append(cll.startedChains, c) + } + evmChainIDs := make([]*big.Int, len(cll.startedChains)) + for i, c := range cll.startedChains { + evmChainIDs[i] = c.ID() + } + defChainID := "unspecified" + if cll.defaultID != nil { + defChainID = fmt.Sprintf("%q", cll.defaultID.String()) + } + cll.logger.Infow(fmt.Sprintf("EVM: Started %d/%d chains, default chain ID is %s", len(cll.startedChains), len(cll.Chains()), defChainID), "startedEvmChainIDs", evmChainIDs) + return nil +} + +func (cll *chainSet) Close() (err error) { + cll.logger.Debug("EVM: stopping") + for _, c := range cll.startedChains { + err = multierr.Combine(err, c.Close()) + } + return +} + +func (cll *chainSet) Name() string { + return cll.logger.Name() +} + +func (cll *chainSet) HealthReport() map[string]error { + report := map[string]error{} + for _, c := range cll.Chains() { + maps.Copy(report, c.HealthReport()) + } + return report +} + +func (cll *chainSet) Ready() (err error) { + for _, c := range cll.Chains() { + err = multierr.Combine(err, c.Ready()) + } + return +} + +func (cll *chainSet) Get(id *big.Int) (evmchain.Chain, error) { + if id == nil { + if cll.defaultID == nil { + cll.logger.Debug("Chain ID not specified, and default is nil") + return nil, errors.New("chain ID not specified, and default is nil") + } + cll.logger.Debugf("Chain ID not specified, using default: %s", cll.defaultID.String()) + return cll.Default() + } + return cll.get(id.String()) +} + +func (cll *chainSet) get(id string) (evmchain.Chain, error) { + cll.chainsMu.RLock() + defer cll.chainsMu.RUnlock() + c, exists := cll.chains[id] + if exists { + return c, nil + } + return nil, errors.Wrap(chains.ErrNotFound, fmt.Sprintf("failed to get chain with id %s", id)) +} + +func (cll *chainSet) ChainStatus(ctx context.Context, id string) (cfg relaytypes.ChainStatus, err error) { + var cs []relaytypes.ChainStatus + cs, _, err = cll.opts.OperationalConfigs.Chains(0, -1, id) + if err != nil { + return + } + l := len(cs) + if l == 0 { + err = chains.ErrNotFound + return + } + if l > 1 { + err = fmt.Errorf("multiple chains found: %d", len(cs)) + return + } + cfg = cs[0] + return +} + +func (cll *chainSet) ChainStatuses(ctx context.Context, offset, limit int) ([]relaytypes.ChainStatus, int, error) { + return cll.opts.OperationalConfigs.Chains(offset, limit) +} + +func (cll *chainSet) Default() (evmchain.Chain, error) { + cll.chainsMu.RLock() + length := len(cll.chains) + cll.chainsMu.RUnlock() + if length == 0 { + return nil, errors.Wrap(ErrNoChains, "cannot get default EVM chain; no EVM chains are available") + } + if cll.defaultID == nil { + // This is an invariant violation; if any chains are available then a + // default should _always_ have been set in the constructor + return nil, errors.New("no default chain ID specified") + } + + return cll.Get(cll.defaultID) +} + +func (cll *chainSet) Chains() (c []evmchain.Chain) { + cll.chainsMu.RLock() + defer cll.chainsMu.RUnlock() + for _, chain := range cll.chains { + c = append(c, chain) + } + return c +} + +func (cll *chainSet) ChainCount() int { + cll.chainsMu.RLock() + defer cll.chainsMu.RUnlock() + return len(cll.chains) +} + +func (cll *chainSet) Configs() evmtypes.Configs { + return cll.opts.OperationalConfigs +} + +func (cll *chainSet) NodeStatuses(ctx context.Context, offset, limit int, chainIDs ...string) (nodes []relaytypes.NodeStatus, count int, err error) { + nodes, count, err = cll.opts.OperationalConfigs.NodeStatusesPaged(offset, limit, chainIDs...) + if err != nil { + err = errors.Wrap(err, "GetNodesForChain failed to load nodes from DB") + return + } + for i := range nodes { + cll.addStateToNode(&nodes[i]) + } + return +} + +func (cll *chainSet) addStateToNode(n *relaytypes.NodeStatus) { + cll.chainsMu.RLock() + chain, exists := cll.chains[n.ChainID] + cll.chainsMu.RUnlock() + if !exists { + // The EVM chain is disabled + n.State = "Disabled" + return + } + states := chain.Client().NodeStates() + if states == nil { + n.State = "Unknown" + return + } + state, exists := states[n.Name] + if exists { + n.State = state + return + } + // The node is in the DB and the chain is enabled but it's not running + n.State = "NotLoaded" +} + +func (cll *chainSet) SendTx(ctx context.Context, chainID, from, to string, amount *big.Int, balanceCheck bool) error { + chain, err := cll.get(chainID) + if err != nil { + return err + } + + return chain.SendTx(ctx, from, to, amount, balanceCheck) +} + +func NewChainRelayerExtenders(ctx context.Context, opts evmchain.ChainRelayExtenderConfig) (*ChainRelayerExtenders, error) { + if err := opts.Check(); err != nil { + return nil, err + } + evmConfigs := opts.GeneralConfig.EVMConfigs() + var enabled []*toml.EVMConfig + for i := range evmConfigs { + if evmConfigs[i].IsEnabled() { + enabled = append(enabled, evmConfigs[i]) + } + } + + defaultChainID := opts.GeneralConfig.DefaultChainID() + if defaultChainID == nil && len(enabled) >= 1 { + defaultChainID = enabled[0].ChainID.ToInt() + if len(enabled) > 1 { + opts.Logger.Debugf("Multiple chains present, default chain: %s", defaultChainID.String()) + } + } + + var result []*ChainRelayerExt + var err error + for i := range enabled { + + cid := enabled[i].ChainID.String() + privOpts := evmchain.ChainRelayExtenderConfig{ + Logger: opts.Logger.Named(cid), + RelayerConfig: opts.RelayerConfig, + DB: opts.DB, + KeyStore: opts.KeyStore, + } + cll := newChainSet(privOpts) + + cll.logger.Infow(fmt.Sprintf("Loading chain %s", cid), "evmChainID", cid) + chain, err2 := evmchain.NewTOMLChain(ctx, enabled[i], privOpts) + if err2 != nil { + err = multierr.Combine(err, err2) + continue + } + if _, exists := cll.chains[cid]; exists { + return nil, errors.Errorf("duplicate chain with ID %s", cid) + } + cll.chains[cid] = chain + + s := &ChainRelayerExt{ + chain: chain, + cs: cll, + isDefault: (cid == defaultChainID.String()), + } + result = append(result, s) + } + return newChainRelayerExtsFromSlice(result), nil +} + +func newChainSet(opts evmchain.ChainRelayExtenderConfig) *chainSet { + return &chainSet{ + chains: make(map[string]evmchain.Chain), + startedChains: make([]evmchain.Chain, 0), + logger: opts.Logger.Named("ChainSet"), + opts: opts, + } +} diff --git a/core/services/relay/evm/relayer_extender_test.go b/core/services/relay/evm/relayer_extender_test.go new file mode 100644 index 00000000000..d4cbb1368c2 --- /dev/null +++ b/core/services/relay/evm/relayer_extender_test.go @@ -0,0 +1,89 @@ +package evm_test + +import ( + "math/big" + "testing" + + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + + evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" + "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +func TestChainRelayExtenders(t *testing.T) { + t.Parallel() + + newId := testutils.NewRandomEVMChainID() + cfg := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + one := uint32(1) + c.EVM[0].MinIncomingConfirmations = &one + t := true + c.EVM = append(c.EVM, &toml.EVMConfig{ChainID: utils.NewBig(newId), Enabled: &t, Chain: toml.Defaults(nil)}) + }) + db := pgtest.NewSqlxDB(t) + kst := cltest.NewKeyStore(t, db, cfg.Database()) + require.NoError(t, kst.Unlock(cltest.Password)) + + opts := evmtest.NewChainRelayExtOpts(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), GeneralConfig: cfg}) + opts.GenEthClient = func(*big.Int) evmclient.Client { + return cltest.NewEthMocksWithStartupAssertions(t) + } + relayExtenders, err := evmrelay.NewChainRelayerExtenders(testutils.Context(t), opts) + require.NoError(t, err) + + require.Equal(t, relayExtenders.Len(), 2) + relayExtendersInstances := relayExtenders.Slice() + for _, c := range relayExtendersInstances { + require.NoError(t, c.Start(testutils.Context(t))) + require.NoError(t, c.Ready()) + } + + require.NotEqual(t, relayExtendersInstances[0].Chain().ID().String(), relayExtendersInstances[1].Chain().ID().String()) + + for _, c := range relayExtendersInstances { + require.NoError(t, c.Close()) + } + + relayExtendersInstances[0].Chain().Client().(*evmclimocks.Client).AssertCalled(t, "Close") + relayExtendersInstances[1].Chain().Client().(*evmclimocks.Client).AssertCalled(t, "Close") + + assert.Error(t, relayExtendersInstances[0].Chain().Ready()) + assert.Error(t, relayExtendersInstances[1].Chain().Ready()) + + // test extender methods on single instance + relayExt := relayExtendersInstances[0] + s, err := relayExt.ChainStatus(testutils.Context(t), "not a chain") + assert.Error(t, err) + assert.Empty(t, s) + // the 0-th extender corresponds to the test fixture default chain + s, err = relayExt.ChainStatus(testutils.Context(t), cltest.FixtureChainID.String()) + assert.NotEmpty(t, s) + assert.NoError(t, err) + + stats, cnt, err := relayExt.ChainStatuses(testutils.Context(t), 0, 0) + assert.NoError(t, err) + assert.Len(t, stats, 1) + assert.Equal(t, 1, cnt) + + // test error conditions for NodeStatuses + nstats, cnt, err := relayExt.NodeStatuses(testutils.Context(t), 0, 0, cltest.FixtureChainID.String(), "error, only one chain supported") + assert.Error(t, err) + assert.Nil(t, nstats) + assert.Equal(t, -1, cnt) + + nstats, cnt, err = relayExt.NodeStatuses(testutils.Context(t), 0, 0, "not the chain id") + assert.Error(t, err) + assert.Nil(t, nstats) + assert.Equal(t, -1, cnt) + +} diff --git a/core/services/relay/evm/types/types.go b/core/services/relay/evm/types/types.go index 7a2c274f5aa..8671082db25 100644 --- a/core/services/relay/evm/types/types.go +++ b/core/services/relay/evm/types/types.go @@ -2,6 +2,9 @@ package types import ( "context" + "encoding/json" + "errors" + "fmt" "github.com/ethereum/go-ethereum/common" "github.com/lib/pq" @@ -10,6 +13,7 @@ import ( ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/smartcontractkit/chainlink-relay/pkg/types" relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -27,6 +31,36 @@ type RelayConfig struct { FeedID *common.Hash `json:"feedID"` } +type RelayOpts struct { + // TODO BCF-2508 -- should anyone ever get the raw config bytes that are embedded in args? if not, + // make this private and wrap the arg fields with funcs on RelayOpts + relaytypes.RelayArgs + c *RelayConfig +} + +var ErrBadRelayConfig = errors.New("bad relay config") + +func NewRelayOpts(args types.RelayArgs) *RelayOpts { + return &RelayOpts{ + RelayArgs: args, + c: nil, // lazy initialization + } +} + +func (o *RelayOpts) RelayConfig() (RelayConfig, error) { + var empty RelayConfig + //TODO this should be done once and the error should be cached + if o.c == nil { + var c RelayConfig + err := json.Unmarshal(o.RelayArgs.RelayConfig, &c) + if err != nil { + return empty, fmt.Errorf("%w: failed to deserialize relay config: %w", ErrBadRelayConfig, err) + } + o.c = &c + } + return *o.c, nil +} + type ConfigPoller interface { ocrtypes.ContractConfigTracker diff --git a/core/services/relay/relay.go b/core/services/relay/relay.go index 2a2cf0d6867..9ee982036cb 100644 --- a/core/services/relay/relay.go +++ b/core/services/relay/relay.go @@ -5,6 +5,8 @@ import ( "errors" "fmt" "math/big" + "regexp" + "strconv" "golang.org/x/exp/maps" @@ -28,6 +30,60 @@ var ( } ) +// Identifier uniquely identifies a relayer by network and chain id +type Identifier struct { + Network Network + ChainID ChainID +} + +func (i *Identifier) Name() string { + return fmt.Sprintf("%s.%s", i.Network, i.ChainID.String()) +} + +func (i *Identifier) String() string { + return i.Name() +} + +var idRegex = regexp.MustCompile( + fmt.Sprintf("^((%s)|(%s)|(%s)|(%s))\\.", EVM, Cosmos, Solana, StarkNet), +) + +func (i *Identifier) UnmarshalString(s string) error { + idxs := idRegex.FindStringIndex(s) + if idxs == nil { + return fmt.Errorf("error unmarshaling Identifier. %q does not match expected pattern", s) + } + // ignore the `.` in the match by dropping last rune + network := s[idxs[0] : idxs[1]-1] + chainID := s[idxs[1]:] + newID := &Identifier{ChainID: ChainID(chainID)} + for n := range SupportedRelays { + if Network(network) == n { + newID.Network = n + break + } + } + if newID.Network == "" { + return fmt.Errorf("error unmarshaling identifier: did not find network in supported list %q", network) + } + i.ChainID = newID.ChainID + i.Network = newID.Network + return nil +} + +type ChainID string + +func (c ChainID) String() string { + return string(c) +} +func (c ChainID) Int64() (int64, error) { + i, err := strconv.Atoi(c.String()) + if err != nil { + return int64(0), err + } + return int64(i), nil +} + // RelayerExt is a subset of [loop.Relayer] for adapting [types.Relayer], typically with a ChainSet. See [relayerAdapter]. type RelayerExt interface { services.ServiceCtx diff --git a/core/services/relay/relay_test.go b/core/services/relay/relay_test.go new file mode 100644 index 00000000000..967bca48da9 --- /dev/null +++ b/core/services/relay/relay_test.go @@ -0,0 +1,48 @@ +package relay + +import ( + "testing" + + "github.com/stretchr/testify/assert" +) + +func TestIdentifier_UnmarshalString(t *testing.T) { + type fields struct { + Network Network + ChainID ChainID + } + type args struct { + s string + } + tests := []struct { + name string + want fields + args args + wantErr bool + }{ + {name: "evm", + args: args{s: "evm.1"}, + wantErr: false, + want: fields{Network: EVM, ChainID: "1"}, + }, + {name: "bad network", + args: args{s: "notANetwork.1"}, + wantErr: true, + }, + {name: "bad pattern", + args: args{s: "evm_1"}, + wantErr: true, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + i := &Identifier{} + err := i.UnmarshalString(tt.args.s) + if (err != nil) != tt.wantErr { + t.Errorf("Identifier.UnmarshalString() error = %v, wantErr %v", err, tt.wantErr) + } + assert.Equal(t, tt.want.Network, i.Network) + assert.Equal(t, tt.want.ChainID, i.ChainID) + }) + } +} diff --git a/core/services/vrf/delegate.go b/core/services/vrf/delegate.go index 5005eac9274..733c21b45a7 100644 --- a/core/services/vrf/delegate.go +++ b/core/services/vrf/delegate.go @@ -34,13 +34,13 @@ import ( ) type Delegate struct { - q pg.Q - pr pipeline.Runner - porm pipeline.ORM - ks keystore.Master - cc evm.ChainSet - lggr logger.Logger - mailMon *utils.MailboxMonitor + q pg.Q + pr pipeline.Runner + porm pipeline.ORM + ks keystore.Master + legacyChains evm.LegacyChainContainer + lggr logger.Logger + mailMon *utils.MailboxMonitor } func NewDelegate( @@ -48,18 +48,18 @@ func NewDelegate( ks keystore.Master, pr pipeline.Runner, porm pipeline.ORM, - chainSet evm.ChainSet, + legacyChains evm.LegacyChainContainer, lggr logger.Logger, cfg pg.QConfig, mailMon *utils.MailboxMonitor) *Delegate { return &Delegate{ - q: pg.NewQ(db, lggr, cfg), - ks: ks, - pr: pr, - porm: porm, - cc: chainSet, - lggr: lggr, - mailMon: mailMon, + q: pg.NewQ(db, lggr, cfg), + ks: ks, + pr: pr, + porm: porm, + legacyChains: legacyChains, + lggr: lggr, + mailMon: mailMon, } } @@ -81,7 +81,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC if err != nil { return nil, err } - chain, err := d.cc.Get(jb.VRFSpec.EVMChainID.ToInt()) + chain, err := d.legacyChains.Get(jb.VRFSpec.EVMChainID.String()) if err != nil { return nil, err } diff --git a/core/services/vrf/delegate_test.go b/core/services/vrf/delegate_test.go index 3d8466b665a..a965008509d 100644 --- a/core/services/vrf/delegate_test.go +++ b/core/services/vrf/delegate_test.go @@ -30,6 +30,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/vrfkey" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/services/signatures/secp256k1" "github.com/smartcontractkit/chainlink/v2/core/services/srvctest" "github.com/smartcontractkit/chainlink/v2/core/services/vrf" @@ -49,18 +50,18 @@ import ( ) type vrfUniverse struct { - jrm job.ORM - pr pipeline.Runner - prm pipeline.ORM - lb *log_mocks.Broadcaster - ec *evmclimocks.Client - ks keystore.Master - vrfkey vrfkey.KeyV2 - submitter common.Address - txm *txmmocks.MockEvmTxManager - hb httypes.HeadBroadcaster - cc evm.ChainSet - cid big.Int + jrm job.ORM + pr pipeline.Runner + prm pipeline.ORM + lb *log_mocks.Broadcaster + ec *evmclimocks.Client + ks keystore.Master + vrfkey vrfkey.KeyV2 + submitter common.Address + txm *txmmocks.MockEvmTxManager + hb httypes.HeadBroadcaster + legacyChains evm.LegacyChainContainer + cid big.Int } func buildVrfUni(t *testing.T, db *sqlx.DB, cfg chainlink.GeneralConfig) vrfUniverse { @@ -77,10 +78,11 @@ func buildVrfUni(t *testing.T, db *sqlx.DB, cfg chainlink.GeneralConfig) vrfUniv btORM := bridges.NewORM(db, lggr, cfg.Database()) txm := txmmocks.NewMockEvmTxManager(t) ks := keystore.New(db, utils.FastScryptParams, lggr, cfg.Database()) - cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{LogBroadcaster: lb, KeyStore: ks.Eth(), Client: ec, DB: db, GeneralConfig: cfg, TxManager: txm}) - jrm := job.NewORM(db, cc, prm, btORM, ks, lggr, cfg.Database()) + cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{LogBroadcaster: lb, KeyStore: ks.Eth(), Client: ec, DB: db, GeneralConfig: cfg, TxManager: txm}) + legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + jrm := job.NewORM(db, legacyChains, prm, btORM, ks, lggr, cfg.Database()) t.Cleanup(func() { jrm.Close() }) - pr := pipeline.NewRunner(prm, btORM, cfg.JobPipeline(), cfg.WebServer(), cc, ks.Eth(), ks.VRF(), lggr, nil, nil) + pr := pipeline.NewRunner(prm, btORM, cfg.JobPipeline(), cfg.WebServer(), legacyChains, ks.Eth(), ks.VRF(), lggr, nil, nil) require.NoError(t, ks.Unlock(testutils.Password)) k, err := ks.Eth().Create(testutils.FixtureChainID) require.NoError(t, err) @@ -90,18 +92,18 @@ func buildVrfUni(t *testing.T, db *sqlx.DB, cfg chainlink.GeneralConfig) vrfUniv require.NoError(t, err) return vrfUniverse{ - jrm: jrm, - pr: pr, - prm: prm, - lb: lb, - ec: ec, - ks: ks, - vrfkey: vrfkey, - submitter: submitter, - txm: txm, - hb: hb, - cc: cc, - cid: *ec.ConfiguredChainID(), + jrm: jrm, + pr: pr, + prm: prm, + lb: lb, + ec: ec, + ks: ks, + vrfkey: vrfkey, + submitter: submitter, + txm: txm, + hb: hb, + legacyChains: legacyChains, + cid: *ec.ConfiguredChainID(), } } @@ -149,7 +151,7 @@ func setup(t *testing.T) (vrfUniverse, *v1.Listener, job.Job) { vuni.ks, vuni.pr, vuni.prm, - vuni.cc, + vuni.legacyChains, logger.TestLogger(t), cfg.Database(), mailMon) @@ -686,11 +688,11 @@ func Test_VRFV2PlusServiceFailsWhenVRFOwnerProvided(t *testing.T) { vuni.ks, vuni.pr, vuni.prm, - vuni.cc, + vuni.legacyChains, logger.TestLogger(t), cfg.Database(), mailMon) - chain, err := vuni.cc.Get(testutils.FixtureChainID) + chain, err := vuni.legacyChains.Get(testutils.FixtureChainID.String()) require.NoError(t, err) vs := testspecs.GenerateVRFSpec(testspecs.VRFSpecParams{ VRFVersion: vrfcommon.V2Plus, diff --git a/core/services/vrf/v1/integration_test.go b/core/services/vrf/v1/integration_test.go index 87cf235cfae..42b709e298c 100644 --- a/core/services/vrf/v1/integration_test.go +++ b/core/services/vrf/v1/integration_test.go @@ -150,8 +150,8 @@ func TestIntegration_VRF_WithBHS(t *testing.T) { cu.RootContractAddress.String(), "", "", "", 0, 200) // Ensure log poller is ready and has all logs. - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), 1)) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Ready()) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Replay(testutils.Context(t), 1)) // Create a VRF request _, err := cu.ConsumerContract.TestRequestRandomness(cu.Carol, diff --git a/core/services/vrf/v2/integration_helpers_test.go b/core/services/vrf/v2/integration_helpers_test.go index 5867796b7c5..dc2395ef143 100644 --- a/core/services/vrf/v2/integration_helpers_test.go +++ b/core/services/vrf/v2/integration_helpers_test.go @@ -245,8 +245,8 @@ func testMultipleConsumersNeedBHS( v2CoordinatorAddress, v2PlusCoordinatorAddress, "", 0, 200) // Ensure log poller is ready and has all logs. - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), 1)) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Ready()) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Replay(testutils.Context(t), 1)) for i := 0; i < nConsumers; i++ { consumer := consumers[i] @@ -392,8 +392,9 @@ func testMultipleConsumersNeedTrustedBHS( v2CoordinatorAddress, v2PlusCoordinatorAddress, uni.trustedBhsContractAddress.String(), 20, 1000) // Ensure log poller is ready and has all logs. - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), 1)) + chain := app.GetRelayers().LegacyEVMChains().Slice()[0] + require.NoError(t, chain.LogPoller().Ready()) + require.NoError(t, chain.LogPoller().Replay(testutils.Context(t), 1)) for i := 0; i < nConsumers; i++ { consumer := consumers[i] @@ -778,8 +779,8 @@ func testBlockHeaderFeeder( v2coordinatorAddress, v2plusCoordinatorAddress) // Ensure log poller is ready and has all logs. - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Ready()) - require.NoError(t, app.Chains.EVM.Chains()[0].LogPoller().Replay(testutils.Context(t), 1)) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Ready()) + require.NoError(t, app.GetRelayers().LegacyEVMChains().Slice()[0].LogPoller().Replay(testutils.Context(t), 1)) for i := 0; i < nConsumers; i++ { consumer := consumers[i] @@ -1684,7 +1685,7 @@ func testMaliciousConsumer( }, testutils.WaitTimeout(t), 1*time.Second).Should(gomega.BeTrue()) // The fulfillment tx should succeed - ch, err := app.GetChains().EVM.Default() + ch, err := app.GetRelayers().LegacyEVMChains().Default() require.NoError(t, err) r, err := ch.Client().TransactionReceipt(testutils.Context(t), attempts[0].Hash) require.NoError(t, err) diff --git a/core/services/vrf/v2/integration_v2_test.go b/core/services/vrf/v2/integration_v2_test.go index fe8c201d22b..e5b94fcdcae 100644 --- a/core/services/vrf/v2/integration_v2_test.go +++ b/core/services/vrf/v2/integration_v2_test.go @@ -1751,7 +1751,7 @@ func TestIntegrationVRFV2(t *testing.T) { }) // We should see the response count present - chain, err := app.Chains.EVM.Get(big.NewInt(1337)) + chain, err := app.GetRelayers().LegacyEVMChains().Get(big.NewInt(1337).String()) require.NoError(t, err) q := pg.NewQ(app.GetSqlxDB(), app.Logger, app.Config.Database()) diff --git a/core/web/chains_controller.go b/core/web/chains_controller.go index ffeafbf3f8d..a932738fa88 100644 --- a/core/web/chains_controller.go +++ b/core/web/chains_controller.go @@ -9,9 +9,10 @@ import ( "github.com/smartcontractkit/chainlink-relay/pkg/types" - "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" ) type ChainsController interface { @@ -22,8 +23,9 @@ type ChainsController interface { } type chainsController[R jsonapi.EntityNamer] struct { + network relay.Network resourceName string - chainSet chains.Chains + chainStats chainlink.ChainStatuser errNotEnabled error newResource func(types.ChainStatus) R lggr logger.Logger @@ -39,11 +41,12 @@ func (e errChainDisabled) Error() string { return fmt.Sprintf("%s is disabled: Set %s=true to enable", e.name, e.tomlKey) } -func newChainsController[R jsonapi.EntityNamer](prefix string, chainSet chains.Chains, errNotEnabled error, +func newChainsController[R jsonapi.EntityNamer](network relay.Network, chainStats chainlink.ChainsNodesStatuser, errNotEnabled error, newResource func(types.ChainStatus) R, lggr logger.Logger, auditLogger audit.AuditLogger) *chainsController[R] { return &chainsController[R]{ - resourceName: prefix + "_chain", - chainSet: chainSet, + network: network, + resourceName: string(network) + "_chain", + chainStats: chainStats, errNotEnabled: errNotEnabled, newResource: newResource, lggr: lggr, @@ -52,11 +55,11 @@ func newChainsController[R jsonapi.EntityNamer](prefix string, chainSet chains.C } func (cc *chainsController[R]) Index(c *gin.Context, size, page, offset int) { - if cc.chainSet == nil { + if cc.chainStats == nil { jsonAPIError(c, http.StatusBadRequest, cc.errNotEnabled) return } - chains, count, err := cc.chainSet.ChainStatuses(c, offset, size) + chains, count, err := cc.chainStats.ChainStatuses(c, offset, size) if err != nil { jsonAPIError(c, http.StatusBadRequest, err) @@ -72,11 +75,12 @@ func (cc *chainsController[R]) Index(c *gin.Context, size, page, offset int) { } func (cc *chainsController[R]) Show(c *gin.Context) { - if cc.chainSet == nil { + if cc.chainStats == nil { jsonAPIError(c, http.StatusBadRequest, cc.errNotEnabled) return } - chain, err := cc.chainSet.ChainStatus(c, c.Param("ID")) + relayID := relay.Identifier{Network: cc.network, ChainID: relay.ChainID(c.Param("ID"))} + chain, err := cc.chainStats.ChainStatus(c, relayID) if err != nil { jsonAPIError(c, http.StatusBadRequest, err) return diff --git a/core/web/common.go b/core/web/common.go index 4204709b2f7..1afc1636ba5 100644 --- a/core/web/common.go +++ b/core/web/common.go @@ -14,23 +14,25 @@ var ( ErrMultipleChains = errors.New("more than one chain available, you must specify evmChainID parameter") ) -func getChain(cs evm.ChainSet, chainIDstr string) (chain evm.Chain, err error) { +func getChain(legacyChains evm.LegacyChainContainer, chainIDstr string) (chain evm.Chain, err error) { + if legacyChains.Len() > 1 { + return nil, ErrMultipleChains + } + if chainIDstr != "" && chainIDstr != "" { - chainID, ok := big.NewInt(0).SetString(chainIDstr, 10) + // evm keys are expected to be parsable as a big int + _, ok := big.NewInt(0).SetString(chainIDstr, 10) if !ok { return nil, ErrInvalidChainID } - chain, err = cs.Get(chainID) + chain, err = legacyChains.Get(chainIDstr) if err != nil { return nil, ErrMissingChainID } return chain, nil } - if cs.ChainCount() > 1 { - return nil, ErrMultipleChains - } - chain, err = cs.Default() + chain, err = legacyChains.Default() if err != nil { return nil, err } diff --git a/core/web/cosmos_chains_controller.go b/core/web/cosmos_chains_controller.go index 251ebb4b954..20a0738c5eb 100644 --- a/core/web/cosmos_chains_controller.go +++ b/core/web/cosmos_chains_controller.go @@ -2,10 +2,16 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) func NewCosmosChainsController(app chainlink.Application) ChainsController { return newChainsController[presenters.CosmosChainResource]( - "cosmos", app.GetChains().Cosmos, ErrCosmosNotEnabled, presenters.NewCosmosChainResource, app.GetLogger(), app.GetAuditLogger()) + relay.Cosmos, + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.Cosmos)), + ErrCosmosNotEnabled, + presenters.NewCosmosChainResource, + app.GetLogger(), + app.GetAuditLogger()) } diff --git a/core/web/cosmos_chains_controller_test.go b/core/web/cosmos_chains_controller_test.go index d8389cbb21e..10a057a5919 100644 --- a/core/web/cosmos_chains_controller_test.go +++ b/core/web/cosmos_chains_controller_test.go @@ -106,14 +106,15 @@ func Test_CosmosChainsController_Index(t *testing.T) { t.Parallel() chainA := &cosmos.CosmosConfig{ - ChainID: ptr(cosmostest.RandomChainID()), + ChainID: ptr("a" + cosmostest.RandomChainID()), Enabled: ptr(true), Chain: coscfg.Chain{ FallbackGasPrice: ptr(decimal.RequireFromString("9.999")), }, } + chainB := &cosmos.CosmosConfig{ - ChainID: ptr(cosmostest.RandomChainID()), + ChainID: ptr("b" + cosmostest.RandomChainID()), Enabled: ptr(true), Chain: coscfg.Chain{ GasLimitMultiplier: ptr(decimal.RequireFromString("1.55555")), @@ -164,6 +165,7 @@ func Test_CosmosChainsController_Index(t *testing.T) { tomlB, err := chainB.TOMLString() require.NoError(t, err) assert.Equal(t, tomlB, chains[0].Config) + } type TestCosmosChainsController struct { diff --git a/core/web/cosmos_nodes_controller.go b/core/web/cosmos_nodes_controller.go index 2a1a65cafe2..756d1ded741 100644 --- a/core/web/cosmos_nodes_controller.go +++ b/core/web/cosmos_nodes_controller.go @@ -2,6 +2,7 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) @@ -10,6 +11,6 @@ var ErrCosmosNotEnabled = errChainDisabled{name: "Cosmos", tomlKey: "Cosmos.Enab func NewCosmosNodesController(app chainlink.Application) NodesController { return newNodesController[presenters.CosmosNodeResource]( - app.GetChains().Cosmos, ErrCosmosNotEnabled, presenters.NewCosmosNodeResource, app.GetAuditLogger(), + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.Cosmos)), ErrCosmosNotEnabled, presenters.NewCosmosNodeResource, app.GetAuditLogger(), ) } diff --git a/core/web/cosmos_transfer_controller.go b/core/web/cosmos_transfer_controller.go index 63769b36326..5276fa758a0 100644 --- a/core/web/cosmos_transfer_controller.go +++ b/core/web/cosmos_transfer_controller.go @@ -28,7 +28,7 @@ type CosmosTransfersController struct { // Create sends Atom and other native coins from the Chainlink's account to a specified address. func (tc *CosmosTransfersController) Create(c *gin.Context) { - cosmosChains := tc.App.GetChains().Cosmos + cosmosChains := tc.App.GetRelayers().LegacyCosmosChains() if cosmosChains == nil { jsonAPIError(c, http.StatusBadRequest, ErrCosmosNotEnabled) return @@ -43,7 +43,9 @@ func (tc *CosmosTransfersController) Create(c *gin.Context) { jsonAPIError(c, http.StatusBadRequest, errors.New("missing cosmosChainID")) return } - chain, err := cosmosChains.Chain(c.Request.Context(), tr.CosmosChainID) + // TODO what about ctx in Get? ctx was used here but not in ETH calls. maybe better to make the interface require ctx and + // put in TODOs in ETH... + chain, err := cosmosChains.Get(tr.CosmosChainID) //cosmosChains.Chain(c.Request.Context(), tr.CosmosChainID) if errors.Is(err, cosmos.ErrChainIDInvalid) || errors.Is(err, cosmos.ErrChainIDEmpty) { jsonAPIError(c, http.StatusBadRequest, err) return diff --git a/core/web/eth_keys_controller.go b/core/web/eth_keys_controller.go index 01c893708ff..f708f8634ec 100644 --- a/core/web/eth_keys_controller.go +++ b/core/web/eth_keys_controller.go @@ -17,6 +17,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" @@ -124,7 +125,7 @@ func (ekc *ETHKeysController) Create(c *gin.Context) { ethKeyStore := ekc.app.GetKeyStore().Eth() cid := c.Query("evmChainID") - chain, ok := ekc.getChain(c, ekc.app.GetChains().EVM, cid) + chain, ok := ekc.getChain(c, cid) if !ok { return } @@ -210,7 +211,7 @@ func (ekc *ETHKeysController) Import(c *gin.Context) { } oldPassword := c.Query("oldpassword") cid := c.Query("evmChainID") - chain, ok := ekc.getChain(c, ekc.app.GetChains().EVM, cid) + chain, ok := ekc.getChain(c, cid) if !ok { return } @@ -271,7 +272,7 @@ func (ekc *ETHKeysController) Chain(c *gin.Context) { address := common.HexToAddress((keyID)) cid := c.Query("evmChainID") - chain, ok := ekc.getChain(c, ekc.app.GetChains().EVM, cid) + chain, ok := ekc.getChain(c, cid) if !ok { return } @@ -356,9 +357,9 @@ func (ekc *ETHKeysController) setEthBalance(bal *big.Int) presenters.NewETHKeyOp // queries the EthClient for the ETH balance at the address associated with state func (ekc *ETHKeysController) getEthBalance(ctx context.Context, state ethkey.State) *big.Int { chainID := state.EVMChainID.ToInt() - chain, err := ekc.app.GetChains().EVM.Get(chainID) + chain, err := ekc.app.GetRelayers().LegacyEVMChains().Get(chainID.String()) if err != nil { - if !errors.Is(errors.Cause(err), evm.ErrNoChains) { + if !errors.Is(errors.Cause(err), evmrelay.ErrNoChains) { ekc.lggr.Errorw("Failed to get EVM Chain", "chainID", chainID, "address", state.Address, "err", err) } return nil @@ -383,9 +384,9 @@ func (ekc *ETHKeysController) setLinkBalance(bal *assets.Link) presenters.NewETH func (ekc *ETHKeysController) getLinkBalance(ctx context.Context, state ethkey.State) *assets.Link { var bal *assets.Link chainID := state.EVMChainID.ToInt() - chain, err := ekc.app.GetChains().EVM.Get(chainID) + chain, err := ekc.app.GetRelayers().LegacyEVMChains().Get(chainID.String()) if err != nil { - if !errors.Is(errors.Cause(err), evm.ErrNoChains) { + if !errors.Is(errors.Cause(err), evmrelay.ErrNoChains) { ekc.lggr.Errorw("Failed to get EVM Chain", "chainID", chainID, "err", err) } } else { @@ -409,9 +410,9 @@ func (ekc *ETHKeysController) setKeyMaxGasPriceWei(price *assets.Wei) presenters func (ekc *ETHKeysController) getKeyMaxGasPriceWei(state ethkey.State, keyAddress common.Address) *assets.Wei { var price *assets.Wei chainID := state.EVMChainID.ToInt() - chain, err := ekc.app.GetChains().EVM.Get(chainID) + chain, err := ekc.app.GetRelayers().LegacyEVMChains().Get(chainID.String()) if err != nil { - if !errors.Is(errors.Cause(err), evm.ErrNoChains) { + if !errors.Is(errors.Cause(err), evmrelay.ErrNoChains) { ekc.lggr.Errorw("Failed to get EVM Chain", "chainID", chainID, "err", err) } } else { @@ -422,8 +423,8 @@ func (ekc *ETHKeysController) getKeyMaxGasPriceWei(state ethkey.State, keyAddres // getChain is a convenience wrapper to retrieve a chain for a given request // and call the corresponding API response error function for 400, 404 and 500 results -func (ekc *ETHKeysController) getChain(c *gin.Context, cs evm.ChainSet, chainIDstr string) (chain evm.Chain, ok bool) { - chain, err := getChain(ekc.app.GetChains().EVM, chainIDstr) +func (ekc *ETHKeysController) getChain(c *gin.Context, chainIDstr string) (chain evm.Chain, ok bool) { + chain, err := getChain(ekc.app.GetRelayers().LegacyEVMChains(), chainIDstr) if err != nil { if errors.Is(err, ErrInvalidChainID) || errors.Is(err, ErrMultipleChains) { jsonAPIError(c, http.StatusBadRequest, err) diff --git a/core/web/eth_keys_controller_test.go b/core/web/eth_keys_controller_test.go index aa676cc1731..0ef01257e17 100644 --- a/core/web/eth_keys_controller_test.go +++ b/core/web/eth_keys_controller_test.go @@ -393,7 +393,7 @@ func TestETHKeysController_ChainSuccess_ResetWithAbandon(t *testing.T) { require.NoError(t, app.Start(testutils.Context(t))) - chain := app.GetChains().EVM.Chains()[0] + chain := app.GetRelayers().LegacyEVMChains().Slice()[0] subject := uuid.New() strategy := commontxmmocks.NewTxStrategy(t) strategy.On("Subject").Return(uuid.NullUUID{UUID: subject, Valid: true}) diff --git a/core/web/evm_chains_controller.go b/core/web/evm_chains_controller.go index 9be243f9331..45b4964c215 100644 --- a/core/web/evm_chains_controller.go +++ b/core/web/evm_chains_controller.go @@ -2,6 +2,7 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) @@ -9,5 +10,10 @@ var ErrEVMNotEnabled = errChainDisabled{name: "EVM", tomlKey: "EVM.Enabled"} func NewEVMChainsController(app chainlink.Application) ChainsController { return newChainsController[presenters.EVMChainResource]( - "evm", app.GetChains().EVM, ErrEVMNotEnabled, presenters.NewEVMChainResource, app.GetLogger(), app.GetAuditLogger()) + relay.EVM, + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.EVM)), + ErrEVMNotEnabled, + presenters.NewEVMChainResource, + app.GetLogger(), + app.GetAuditLogger()) } diff --git a/core/web/evm_chains_controller_test.go b/core/web/evm_chains_controller_test.go index 553bdae937b..6c779868d1b 100644 --- a/core/web/evm_chains_controller_test.go +++ b/core/web/evm_chains_controller_test.go @@ -2,7 +2,9 @@ package web_test import ( "fmt" + "math/big" "net/http" + "sort" "testing" "github.com/manyminds/api2go/jsonapi" @@ -101,10 +103,17 @@ func Test_EVMChainsController_Show(t *testing.T) { func Test_EVMChainsController_Index(t *testing.T) { t.Parallel() - newChains := evmcfg.EVMConfigs{ - {ChainID: utils.NewBig(testutils.NewRandomEVMChainID()), Chain: evmcfg.Defaults(nil)}, + // sort test chain ids to make expected comparison easy + chainIDs := []*big.Int{testutils.NewRandomEVMChainID(), testutils.NewRandomEVMChainID(), testutils.NewRandomEVMChainID()} + sort.Slice(chainIDs, func(i, j int) bool { + + return chainIDs[i].String() < chainIDs[j].String() + }) + + configuredChains := evmcfg.EVMConfigs{ + {ChainID: utils.NewBig(chainIDs[0]), Chain: evmcfg.Defaults(nil)}, { - ChainID: utils.NewBig(testutils.NewRandomEVMChainID()), + ChainID: utils.NewBig(chainIDs[1]), Chain: evmcfg.Defaults(nil, &evmcfg.Chain{ RPCBlockQueryDelay: ptr[uint16](13), GasEstimator: evmcfg.GasEstimator{ @@ -117,7 +126,7 @@ func Test_EVMChainsController_Index(t *testing.T) { }), }, { - ChainID: utils.NewBig(testutils.NewRandomEVMChainID()), + ChainID: utils.NewBig(chainIDs[2]), Chain: evmcfg.Defaults(nil, &evmcfg.Chain{ RPCBlockQueryDelay: ptr[uint16](5), GasEstimator: evmcfg.GasEstimator{ @@ -131,8 +140,9 @@ func Test_EVMChainsController_Index(t *testing.T) { }, } + assert.Len(t, configuredChains, 3) controller := setupEVMChainsControllerTest(t, configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { - c.EVM = append(c.EVM, newChains...) + c.EVM = append(c.EVM, configuredChains...) })) badResp, cleanup := controller.client.Get("/v2/chains/evm?size=asd") @@ -147,37 +157,40 @@ func Test_EVMChainsController_Index(t *testing.T) { metaCount, err := cltest.ParseJSONAPIResponseMetaCount(body) require.NoError(t, err) - require.Equal(t, 1+len(newChains), metaCount) + require.Equal(t, 1+len(configuredChains), metaCount) var links jsonapi.Links - var chains []presenters.EVMChainResource - err = web.ParsePaginatedResponse(body, &chains, &links) + var gotChains []presenters.EVMChainResource + err = web.ParsePaginatedResponse(body, &gotChains, &links) assert.NoError(t, err) assert.NotEmpty(t, links["next"].Href) assert.Empty(t, links["prev"].Href) assert.Len(t, links, 1) - assert.Equal(t, newChains[1].ChainID.String(), chains[2].ID) - toml, err := newChains[1].TOMLString() + // the difference in index value here seems to be due to the fact + // that cltest always has a default EVM chain, which is the off-by-one + // in the indices + assert.Equal(t, gotChains[2].ID, configuredChains[1].ChainID.String()) + toml, err := configuredChains[1].TOMLString() require.NoError(t, err) - assert.Equal(t, toml, chains[2].Config) + assert.Equal(t, toml, gotChains[2].Config) resp, cleanup = controller.client.Get(links["next"].Href) t.Cleanup(cleanup) require.Equal(t, http.StatusOK, resp.StatusCode) - chains = []presenters.EVMChainResource{} - err = web.ParsePaginatedResponse(cltest.ParseResponseBody(t, resp), &chains, &links) + gotChains = []presenters.EVMChainResource{} + err = web.ParsePaginatedResponse(cltest.ParseResponseBody(t, resp), &gotChains, &links) assert.NoError(t, err) assert.Empty(t, links["next"].Href) assert.NotEmpty(t, links["prev"].Href) assert.Len(t, links, 1) - assert.Equal(t, newChains[2].ChainID.String(), chains[0].ID) - toml, err = newChains[2].TOMLString() + assert.Equal(t, gotChains[0].ID, configuredChains[2].ChainID.String()) + toml, err = configuredChains[2].TOMLString() require.NoError(t, err) - assert.Equal(t, toml, chains[0].Config) + assert.Equal(t, toml, gotChains[0].Config) } type TestEVMChainsController struct { diff --git a/core/web/evm_forwarders_controller.go b/core/web/evm_forwarders_controller.go index 68a46a58da7..6228723506d 100644 --- a/core/web/evm_forwarders_controller.go +++ b/core/web/evm_forwarders_controller.go @@ -80,7 +80,7 @@ func (cc *EVMForwardersController) Delete(c *gin.Context) { } filterCleanup := func(tx pg.Queryer, evmChainID int64, addr common.Address) error { - chain, err2 := cc.App.GetChains().EVM.Get(big.NewInt(evmChainID)) + chain, err2 := cc.App.GetRelayers().LegacyEVMChains().Get(big.NewInt(evmChainID).String()) if err2 != nil { // If the chain id doesn't even exist, or logpoller is disabled, then there isn't any filter to clean up. Returning an error // here could be dangerous as it would make it impossible to delete a forwarder with an invalid chain id diff --git a/core/web/evm_forwarders_controller_test.go b/core/web/evm_forwarders_controller_test.go index 212105252c4..705fce05c02 100644 --- a/core/web/evm_forwarders_controller_test.go +++ b/core/web/evm_forwarders_controller_test.go @@ -69,7 +69,7 @@ func Test_EVMForwardersController_Track(t *testing.T) { assert.Equal(t, resource.Address, address) - require.Len(t, controller.app.Chains.EVM.Chains(), 1) + require.Len(t, controller.app.GetRelayers().LegacyEVMChains().Slice(), 1) resp, cleanup = controller.client.Delete("/v2/nodes/evm/forwarders/" + resource.ID) t.Cleanup(cleanup) diff --git a/core/web/evm_nodes_controller.go b/core/web/evm_nodes_controller.go index dda551fba5b..aba0faca8e8 100644 --- a/core/web/evm_nodes_controller.go +++ b/core/web/evm_nodes_controller.go @@ -2,10 +2,11 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) func NewEVMNodesController(app chainlink.Application) NodesController { return newNodesController[presenters.EVMNodeResource]( - app.GetChains().EVM, ErrEVMNotEnabled, presenters.NewEVMNodeResource, app.GetAuditLogger()) + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.EVM)), ErrEVMNotEnabled, presenters.NewEVMNodeResource, app.GetAuditLogger()) } diff --git a/core/web/evm_transfer_controller.go b/core/web/evm_transfer_controller.go index e5ceded58d4..a42ab923c90 100644 --- a/core/web/evm_transfer_controller.go +++ b/core/web/evm_transfer_controller.go @@ -33,7 +33,7 @@ func (tc *EVMTransfersController) Create(c *gin.Context) { return } - chain, err := getChain(tc.App.GetChains().EVM, tr.EVMChainID.String()) + chain, err := getChain(tc.App.GetRelayers().LegacyEVMChains(), tr.EVMChainID.String()) switch err { case ErrInvalidChainID, ErrMultipleChains, ErrMissingChainID: jsonAPIError(c, http.StatusUnprocessableEntity, err) diff --git a/core/web/jobs_controller.go b/core/web/jobs_controller.go index 77a2a34091c..4c8a77d370e 100644 --- a/core/web/jobs_controller.go +++ b/core/web/jobs_controller.go @@ -221,7 +221,7 @@ func (jc *JobsController) validateJobSpec(tomlString string) (jb job.Job, status config := jc.App.GetConfig() switch jobType { case job.OffchainReporting: - jb, err = ocr.ValidatedOracleSpecToml(jc.App.GetChains().EVM, tomlString) + jb, err = ocr.ValidatedOracleSpecToml(jc.App.GetRelayers().LegacyEVMChains(), tomlString) if !config.OCR().Enabled() { return jb, http.StatusNotImplemented, errors.New("The Offchain Reporting feature is disabled by configuration") } diff --git a/core/web/loader/loader_test.go b/core/web/loader/loader_test.go index 0567ab5188b..e2fe78ef452 100644 --- a/core/web/loader/loader_test.go +++ b/core/web/loader/loader_test.go @@ -2,6 +2,7 @@ package loader import ( "database/sql" + "math/big" "testing" "github.com/google/uuid" @@ -14,18 +15,18 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" - evmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr" evmtxmgrmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr/mocks" coremocks "github.com/smartcontractkit/chainlink/v2/core/internal/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + chainlinkmocks "github.com/smartcontractkit/chainlink/v2/core/services/chainlink/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/feeds" feedsMocks "github.com/smartcontractkit/chainlink/v2/core/services/feeds/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/job" jobORMMocks "github.com/smartcontractkit/chainlink/v2/core/services/job/mocks" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -64,32 +65,35 @@ func TestLoader_Chains(t *testing.T) { func TestLoader_Nodes(t *testing.T) { t.Parallel() - evmChainSet := evmmocks.NewChainSet(t) app := coremocks.NewApplication(t) ctx := InjectDataloader(testutils.Context(t), app) - node1 := relaytypes.NodeStatus{ - Name: "test-node-1", - ChainID: "1", - } - node2 := relaytypes.NodeStatus{ - Name: "test-node-1", - ChainID: "2", - } + chainID1, chainID2, notAnID := big.NewInt(1), big.NewInt(2), big.NewInt(3) + relayID1 := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(chainID1.String())} + relayID2 := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(chainID2.String())} + notARelayID := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(notAnID.String())} - evmChainSet.On("NodeStatuses", mock.Anything, mock.Anything, mock.Anything, "2", "1", "3").Return([]relaytypes.NodeStatus{ - node1, node2, + genNodeStat := func(id string) relaytypes.NodeStatus { + return relaytypes.NodeStatus{ + Name: "test-node-" + id, + ChainID: id, + } + } + rcInterops := chainlinkmocks.NewRelayerChainInteroperators(t) + rcInterops.On("NodeStatuses", mock.Anything, mock.Anything, mock.Anything, + relayID2.String(), relayID1.String(), notARelayID.String()).Return([]relaytypes.NodeStatus{ + genNodeStat(chainID2.String()), genNodeStat(chainID1.String()), }, 2, nil) - app.On("GetChains").Return(chainlink.Chains{EVM: evmChainSet}) + app.On("GetRelayers").Return(rcInterops) batcher := nodeBatcher{app} - keys := dataloader.NewKeysFromStrings([]string{"2", "1", "3"}) + keys := dataloader.NewKeysFromStrings([]string{chainID2.String(), chainID1.String(), notAnID.String()}) found := batcher.loadByChainIDs(ctx, keys) require.Len(t, found, 3) - assert.Equal(t, []relaytypes.NodeStatus{node2}, found[0].Data) - assert.Equal(t, []relaytypes.NodeStatus{node1}, found[1].Data) + assert.Equal(t, []relaytypes.NodeStatus{genNodeStat(chainID2.String())}, found[0].Data) + assert.Equal(t, []relaytypes.NodeStatus{genNodeStat(chainID1.String())}, found[1].Data) assert.Equal(t, []relaytypes.NodeStatus{}, found[2].Data) } diff --git a/core/web/loader/node.go b/core/web/loader/node.go index e0b1d6711e8..b9c655ed5e5 100644 --- a/core/web/loader/node.go +++ b/core/web/loader/node.go @@ -8,6 +8,7 @@ import ( "github.com/smartcontractkit/chainlink-relay/pkg/types" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" ) type nodeBatcher struct { @@ -18,20 +19,22 @@ func (b *nodeBatcher) loadByChainIDs(ctx context.Context, keys dataloader.Keys) // Create a map for remembering the order of keys passed in keyOrder := make(map[string]int, len(keys)) // Collect the keys to search for - var ids []string + // note backward compatibility -- this only ever supported evm chains + var evmrelayIdStrs []string + for ix, key := range keys { - ids = append(ids, key.String()) + rid := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(key.String())} + evmrelayIdStrs = append(evmrelayIdStrs, rid.String()) keyOrder[key.String()] = ix } - nodes, _, err := b.app.GetChains().EVM.NodeStatuses(ctx, 0, -1, ids...) + allNodes, _, err := b.app.GetRelayers().NodeStatuses(ctx, 0, 1, evmrelayIdStrs...) if err != nil { return []*dataloader.Result{{Data: nil, Error: err}} } - // Generate a map of nodes to chainIDs nodesForChain := map[string][]types.NodeStatus{} - for _, n := range nodes { + for _, n := range allNodes { nodesForChain[n.ChainID] = append(nodesForChain[n.ChainID], n) } diff --git a/core/web/nodes_controller.go b/core/web/nodes_controller.go index da5fcd05b2d..e65f3e68a8a 100644 --- a/core/web/nodes_controller.go +++ b/core/web/nodes_controller.go @@ -18,14 +18,14 @@ type NodesController interface { } type nodesController[R jsonapi.EntityNamer] struct { - nodeSet chains.Nodes + nodeSet chains.NodesStatuser errNotEnabled error newResource func(status types.NodeStatus) R auditLogger audit.AuditLogger } func newNodesController[R jsonapi.EntityNamer]( - nodeSet chains.Nodes, + nodeSet chains.NodesStatuser, errNotEnabled error, newResource func(status types.NodeStatus) R, auditLogger audit.AuditLogger, diff --git a/core/web/replay_controller.go b/core/web/replay_controller.go index 6809f1852ed..47c3e2dc522 100644 --- a/core/web/replay_controller.go +++ b/core/web/replay_controller.go @@ -46,7 +46,7 @@ func (bdc *ReplayController) ReplayFromBlock(c *gin.Context) { return } - chain, err := getChain(bdc.App.GetChains().EVM, c.Query("evmChainID")) + chain, err := getChain(bdc.App.GetRelayers().LegacyEVMChains(), c.Query("evmChainID")) switch err { case ErrInvalidChainID, ErrMultipleChains, ErrMissingChainID: jsonAPIError(c, http.StatusUnprocessableEntity, err) diff --git a/core/web/resolver/eth_key_test.go b/core/web/resolver/eth_key_test.go index 3f49815548c..5fb5fd3d2a6 100644 --- a/core/web/resolver/eth_key_test.go +++ b/core/web/resolver/eth_key_test.go @@ -14,8 +14,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config" mocks2 "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -86,6 +87,10 @@ func TestResolver_ETHKeys(t *testing.T) { chainID := *utils.NewBigI(12) linkAddr := common.HexToAddress("0x5431F5F973781809D18643b87B44921b11355d81") + cfg := evmtest.NewTestConfigs() + m := map[string]evm.Chain{states[0].EVMChainID.String(): f.Mocks.chain} + legacyEVMChains := evm.NewLegacyChains(cfg, m) + f.Mocks.ethKs.On("GetStatesForKeys", keys).Return(states, nil) f.Mocks.ethKs.On("Get", keys[0].Address.Hex()).Return(keys[0], nil) f.Mocks.ethKs.On("GetAll").Return(keys, nil) @@ -94,35 +99,37 @@ func TestResolver_ETHKeys(t *testing.T) { f.Mocks.balM.On("GetEthBalance", address).Return(assets.NewEth(1)) f.Mocks.chain.On("BalanceMonitor").Return(f.Mocks.balM) f.Mocks.chain.On("Config").Return(f.Mocks.scfg) - f.Mocks.chainSet.On("Get", states[0].EVMChainID.ToInt()).Return(f.Mocks.chain, nil) + f.Mocks.relayerChainInterops.On("LegacyEVMChains").Return(legacyEVMChains) f.Mocks.evmORM.PutChains(toml.EVMConfig{ChainID: &chainID}) f.Mocks.keystore.On("Eth").Return(f.Mocks.ethKs) f.App.On("GetKeyStore").Return(f.Mocks.keystore) f.App.On("EVMORM").Return(f.Mocks.evmORM) - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) + f.Mocks.scfg.On("EVM").Return(&evmMockConfig) }, query: query, result: ` - { - "ethKeys": { - "results": [ - { - "address": "0x5431F5F973781809D18643b87B44921b11355d81", - "isDisabled": false, - "ethBalance": "0.000000000000000001", - "linkBalance": "12", - "maxGasPriceWei": "1", - "createdAt": "2021-01-01T00:00:00Z", - "updatedAt": "2021-01-01T00:00:00Z", - "chain": { - "id": "12" - } + { + "ethKeys": { + "results": [ + { + "address": "0x5431F5F973781809D18643b87B44921b11355d81", + "isDisabled": false, + "ethBalance": "0.000000000000000001", + "linkBalance": "12", + "maxGasPriceWei": "1", + "createdAt": "2021-01-01T00:00:00Z", + "updatedAt": "2021-01-01T00:00:00Z", + "chain": { + "id": "12" + } + } + ] } - ] - } - }`, + }`, }, + { name: "success with no chains", authenticated: true, @@ -137,38 +144,39 @@ func TestResolver_ETHKeys(t *testing.T) { }, } chainID := *utils.NewBigI(12) - + f.Mocks.legacyEVMChains.On("Get", states[0].EVMChainID.String()).Return(nil, evmrelay.ErrNoChains) f.Mocks.ethKs.On("GetStatesForKeys", keys).Return(states, nil) f.Mocks.ethKs.On("Get", keys[0].Address.Hex()).Return(keys[0], nil) f.Mocks.ethKs.On("GetAll").Return(keys, nil) - f.Mocks.chainSet.On("Get", states[0].EVMChainID.ToInt()).Return(f.Mocks.chain, evm.ErrNoChains) + f.Mocks.relayerChainInterops.On("LegacyEVMChains").Return(f.Mocks.legacyEVMChains) f.Mocks.evmORM.PutChains(toml.EVMConfig{ChainID: &chainID}) f.Mocks.keystore.On("Eth").Return(f.Mocks.ethKs) f.App.On("GetKeyStore").Return(f.Mocks.keystore) f.App.On("EVMORM").Return(f.Mocks.evmORM) - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) }, query: query, result: ` - { - "ethKeys": { - "results": [ { - "address": "0x5431F5F973781809D18643b87B44921b11355d81", - "isDisabled": false, - "ethBalance": null, - "linkBalance": null, - "maxGasPriceWei": null, - "createdAt": "2021-01-01T00:00:00Z", - "updatedAt": "2021-01-01T00:00:00Z", - "chain": { - "id": "12" + "ethKeys": { + "results": [ + { + "address": "0x5431F5F973781809D18643b87B44921b11355d81", + "isDisabled": false, + "ethBalance": null, + "linkBalance": null, + "maxGasPriceWei": null, + "createdAt": "2021-01-01T00:00:00Z", + "updatedAt": "2021-01-01T00:00:00Z", + "chain": { + "id": "12" + } + } + ] } - } - ] - } - }`, + }`, }, + { name: "generic error on GetAll()", authenticated: true, @@ -239,6 +247,7 @@ func TestResolver_ETHKeys(t *testing.T) { }, }, }, + { name: "Empty set on #chainSet.Get()", authenticated: true, @@ -257,17 +266,18 @@ func TestResolver_ETHKeys(t *testing.T) { f.Mocks.ethKs.On("Get", keys[0].Address.Hex()).Return(ethkey.KeyV2{}, nil) f.Mocks.ethKs.On("GetAll").Return(keys, nil) f.Mocks.keystore.On("Eth").Return(f.Mocks.ethKs) - f.Mocks.chainSet.On("Get", states[0].EVMChainID.ToInt()).Return(f.Mocks.chain, gError) + f.Mocks.legacyEVMChains.On("Get", states[0].EVMChainID.String()).Return(f.Mocks.chain, gError) + f.Mocks.relayerChainInterops.On("LegacyEVMChains").Return(f.Mocks.legacyEVMChains) + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) f.App.On("GetKeyStore").Return(f.Mocks.keystore) - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) }, query: query, result: ` - { - "ethKeys": { - "results": [] - } - }`, + { + "ethKeys": { + "results": [] + } + }`, }, { name: "generic error on GetLINKBalance()", @@ -290,37 +300,38 @@ func TestResolver_ETHKeys(t *testing.T) { f.Mocks.ethKs.On("GetAll").Return(keys, nil) f.Mocks.keystore.On("Eth").Return(f.Mocks.ethKs) f.Mocks.ethClient.On("LINKBalance", mock.Anything, address, linkAddr).Return(assets.NewLinkFromJuels(12), gError) - f.Mocks.chainSet.On("Get", states[0].EVMChainID.ToInt()).Return(f.Mocks.chain, nil) + f.Mocks.legacyEVMChains.On("Get", states[0].EVMChainID.String()).Return(f.Mocks.chain, nil) + f.Mocks.relayerChainInterops.On("LegacyEVMChains").Return(f.Mocks.legacyEVMChains) f.Mocks.chain.On("Client").Return(f.Mocks.ethClient) f.Mocks.balM.On("GetEthBalance", address).Return(assets.NewEth(1)) f.Mocks.chain.On("BalanceMonitor").Return(f.Mocks.balM) f.App.On("GetKeyStore").Return(f.Mocks.keystore) - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) f.Mocks.chain.On("Config").Return(f.Mocks.scfg) f.Mocks.evmORM.PutChains(toml.EVMConfig{ChainID: &chainID}) + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) f.App.On("EVMORM").Return(f.Mocks.evmORM) f.Mocks.scfg.On("EVM").Return(&evmMockConfig) }, query: query, result: ` - { - "ethKeys": { - "results": [ - { - "address": "0x5431F5F973781809D18643b87B44921b11355d81", - "isDisabled": false, - "ethBalance": "0.000000000000000001", - "linkBalance": null, - "maxGasPriceWei": "1", - "createdAt": "2021-01-01T00:00:00Z", - "updatedAt": "2021-01-01T00:00:00Z", - "chain": { - "id": "12" - } + { + "ethKeys": { + "results": [ + { + "address": "0x5431F5F973781809D18643b87B44921b11355d81", + "isDisabled": false, + "ethBalance": "0.000000000000000001", + "linkBalance": null, + "maxGasPriceWei": "1", + "createdAt": "2021-01-01T00:00:00Z", + "updatedAt": "2021-01-01T00:00:00Z", + "chain": { + "id": "12" + } + } + ] } - ] - } - }`, + }`, }, { name: "success with no eth balance", @@ -345,34 +356,35 @@ func TestResolver_ETHKeys(t *testing.T) { f.Mocks.chain.On("Client").Return(f.Mocks.ethClient) f.Mocks.chain.On("BalanceMonitor").Return(nil) f.Mocks.chain.On("Config").Return(f.Mocks.scfg) - f.Mocks.chainSet.On("Get", states[0].EVMChainID.ToInt()).Return(f.Mocks.chain, nil) + f.Mocks.legacyEVMChains.On("Get", states[0].EVMChainID.String()).Return(f.Mocks.chain, nil) + f.Mocks.relayerChainInterops.On("LegacyEVMChains").Return(f.Mocks.legacyEVMChains) f.Mocks.evmORM.PutChains(toml.EVMConfig{ChainID: &chainID}) f.Mocks.keystore.On("Eth").Return(f.Mocks.ethKs) f.App.On("GetKeyStore").Return(f.Mocks.keystore) f.App.On("EVMORM").Return(f.Mocks.evmORM) - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) f.Mocks.scfg.On("EVM").Return(&evmMockConfig) }, query: query, result: ` - { - "ethKeys": { - "results": [ - { - "address": "0x5431F5F973781809D18643b87B44921b11355d81", - "isDisabled": false, - "ethBalance": null, - "linkBalance": "12", - "maxGasPriceWei": "1", - "createdAt": "2021-01-01T00:00:00Z", - "updatedAt": "2021-01-01T00:00:00Z", - "chain": { - "id": "12" - } + { + "ethKeys": { + "results": [ + { + "address": "0x5431F5F973781809D18643b87B44921b11355d81", + "isDisabled": false, + "ethBalance": null, + "linkBalance": "12", + "maxGasPriceWei": "1", + "createdAt": "2021-01-01T00:00:00Z", + "updatedAt": "2021-01-01T00:00:00Z", + "chain": { + "id": "12" + } + } + ] } - ] - } - }`, + }`, }, } diff --git a/core/web/resolver/mutation.go b/core/web/resolver/mutation.go index dfb4b9f85be..5af263d9395 100644 --- a/core/web/resolver/mutation.go +++ b/core/web/resolver/mutation.go @@ -1011,7 +1011,7 @@ func (r *Resolver) CreateJob(ctx context.Context, args struct { config := r.App.GetConfig() switch jbt { case job.OffchainReporting: - jb, err = ocr.ValidatedOracleSpecToml(r.App.GetChains().EVM, args.Input.TOML) + jb, err = ocr.ValidatedOracleSpecToml(r.App.GetRelayers().LegacyEVMChains(), args.Input.TOML) if !config.OCR().Enabled() { return nil, errors.New("The Offchain Reporting feature is disabled by configuration") } diff --git a/core/web/resolver/node_test.go b/core/web/resolver/node_test.go index 1bb381731d6..e949a67a85b 100644 --- a/core/web/resolver/node_test.go +++ b/core/web/resolver/node_test.go @@ -8,9 +8,7 @@ import ( "github.com/stretchr/testify/mock" "github.com/smartcontractkit/chainlink-relay/pkg/types" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -45,8 +43,8 @@ func TestResolver_Nodes(t *testing.T) { name: "success", authenticated: true, before: func(f *gqlTestFramework) { - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) - f.Mocks.chainSet.On("NodeStatuses", mock.Anything, PageDefaultOffset, PageDefaultLimit).Return([]types.NodeStatus{ + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) + f.Mocks.relayerChainInterops.On("NodeStatuses", mock.Anything, PageDefaultOffset, PageDefaultLimit).Return([]types.NodeStatus{ { Name: "node-name", ChainID: chainID.String(), @@ -55,6 +53,7 @@ func TestResolver_Nodes(t *testing.T) { }, 1, nil) f.App.On("EVMORM").Return(f.Mocks.evmORM) f.Mocks.evmORM.PutChains(toml.EVMConfig{ChainID: &chainID}) + }, query: query, result: ` @@ -77,8 +76,8 @@ func TestResolver_Nodes(t *testing.T) { name: "generic error", authenticated: true, before: func(f *gqlTestFramework) { - f.Mocks.chainSet.On("NodeStatuses", mock.Anything, PageDefaultOffset, PageDefaultLimit).Return([]types.NodeStatus{}, 0, gError) - f.App.On("GetChains").Return(chainlink.Chains{EVM: f.Mocks.chainSet}) + f.Mocks.relayerChainInterops.On("NodeStatuses", mock.Anything, PageDefaultOffset, PageDefaultLimit).Return([]types.NodeStatus{}, 0, gError) + f.App.On("GetRelayers").Return(f.Mocks.relayerChainInterops) }, query: query, result: `null`, diff --git a/core/web/resolver/query.go b/core/web/resolver/query.go index 802e33be6bf..3ae8b77b6db 100644 --- a/core/web/resolver/query.go +++ b/core/web/resolver/query.go @@ -11,12 +11,11 @@ import ( "github.com/pkg/errors" "github.com/smartcontractkit/chainlink-relay/pkg/types" - "github.com/smartcontractkit/chainlink/v2/core/bridges" "github.com/smartcontractkit/chainlink/v2/core/chains" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/vrfkey" + evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils/stringutils" ) @@ -327,12 +326,11 @@ func (r *Resolver) Nodes(ctx context.Context, args struct { offset := pageOffset(args.Offset) limit := pageLimit(args.Limit) - nodes, count, err := r.App.GetChains().EVM.NodeStatuses(ctx, offset, limit) + allNodes, total, err := r.App.GetRelayers().NodeStatuses(ctx, offset, limit) if err != nil { return nil, err } - - npr, warn := NewNodesPayload(nodes, int32(count)) + npr, warn := NewNodesPayload(allNodes, int32(total)) if warn != nil { r.App.GetLogger().Warnw("Error creating NodesPayloadResolver", "err", warn) } @@ -407,8 +405,8 @@ func (r *Resolver) ETHKeys(ctx context.Context) (*ETHKeysPayloadResolver, error) return nil, err } - chain, err := r.App.GetChains().EVM.Get(state.EVMChainID.ToInt()) - if errors.Is(errors.Cause(err), evm.ErrNoChains) { + chain, err := r.App.GetRelayers().LegacyEVMChains().Get(state.EVMChainID.String()) + if errors.Is(errors.Cause(err), evmrelay.ErrNoChains) { ethKeys = append(ethKeys, ETHKey{ addr: k.EIP55Address, state: state, diff --git a/core/web/resolver/resolver_test.go b/core/web/resolver/resolver_test.go index c628a020052..16a91c54d38 100644 --- a/core/web/resolver/resolver_test.go +++ b/core/web/resolver/resolver_test.go @@ -33,29 +33,30 @@ import ( ) type mocks struct { - bridgeORM *bridgeORMMocks.ORM - evmORM *evmtest.TestConfigs - jobORM *jobORMMocks.ORM - sessionsORM *sessionsMocks.ORM - pipelineORM *pipelineMocks.ORM - feedsSvc *feedsMocks.Service - cfg *chainlinkMocks.GeneralConfig - scfg *evmConfigMocks.ChainScopedConfig - ocr *keystoreMocks.OCR - ocr2 *keystoreMocks.OCR2 - csa *keystoreMocks.CSA - keystore *keystoreMocks.Master - ethKs *keystoreMocks.Eth - p2p *keystoreMocks.P2P - vrf *keystoreMocks.VRF - solana *keystoreMocks.Solana - chain *evmORMMocks.Chain - chainSet *evmORMMocks.ChainSet - ethClient *evmClientMocks.Client - eIMgr *webhookmocks.ExternalInitiatorManager - balM *evmORMMocks.BalanceMonitor - txmStore *evmtxmgrmocks.EvmTxStore - auditLogger *audit.AuditLoggerService + bridgeORM *bridgeORMMocks.ORM + evmORM *evmtest.TestConfigs + jobORM *jobORMMocks.ORM + sessionsORM *sessionsMocks.ORM + pipelineORM *pipelineMocks.ORM + feedsSvc *feedsMocks.Service + cfg *chainlinkMocks.GeneralConfig + scfg *evmConfigMocks.ChainScopedConfig + ocr *keystoreMocks.OCR + ocr2 *keystoreMocks.OCR2 + csa *keystoreMocks.CSA + keystore *keystoreMocks.Master + ethKs *keystoreMocks.Eth + p2p *keystoreMocks.P2P + vrf *keystoreMocks.VRF + solana *keystoreMocks.Solana + chain *evmORMMocks.Chain + legacyEVMChains *evmORMMocks.LegacyChainContainer + relayerChainInterops *chainlinkMocks.RelayerChainInteroperators + ethClient *evmClientMocks.Client + eIMgr *webhookmocks.ExternalInitiatorManager + balM *evmORMMocks.BalanceMonitor + txmStore *evmtxmgrmocks.EvmTxStore + auditLogger *audit.AuditLoggerService } // gqlTestFramework is a framework wrapper containing the objects needed to run @@ -63,7 +64,7 @@ type mocks struct { type gqlTestFramework struct { t *testing.T - // The mocked chainlf.Mocks.chainSetink.Application + // The mocked chainlink.Application App *coremocks.Application // The root GQL schema @@ -91,29 +92,30 @@ func setupFramework(t *testing.T) *gqlTestFramework { // Setup mocks // Note - If you add a new mock make sure you assert it's expectation below. m := &mocks{ - bridgeORM: bridgeORMMocks.NewORM(t), - evmORM: evmtest.NewTestConfigs(), - jobORM: jobORMMocks.NewORM(t), - feedsSvc: feedsMocks.NewService(t), - sessionsORM: sessionsMocks.NewORM(t), - pipelineORM: pipelineMocks.NewORM(t), - cfg: chainlinkMocks.NewGeneralConfig(t), - scfg: evmConfigMocks.NewChainScopedConfig(t), - ocr: keystoreMocks.NewOCR(t), - ocr2: keystoreMocks.NewOCR2(t), - csa: keystoreMocks.NewCSA(t), - keystore: keystoreMocks.NewMaster(t), - ethKs: keystoreMocks.NewEth(t), - p2p: keystoreMocks.NewP2P(t), - vrf: keystoreMocks.NewVRF(t), - solana: keystoreMocks.NewSolana(t), - chain: evmORMMocks.NewChain(t), - chainSet: evmORMMocks.NewChainSet(t), - ethClient: evmClientMocks.NewClient(t), - eIMgr: webhookmocks.NewExternalInitiatorManager(t), - balM: evmORMMocks.NewBalanceMonitor(t), - txmStore: evmtxmgrmocks.NewEvmTxStore(t), - auditLogger: &audit.AuditLoggerService{}, + bridgeORM: bridgeORMMocks.NewORM(t), + evmORM: evmtest.NewTestConfigs(), + jobORM: jobORMMocks.NewORM(t), + feedsSvc: feedsMocks.NewService(t), + sessionsORM: sessionsMocks.NewORM(t), + pipelineORM: pipelineMocks.NewORM(t), + cfg: chainlinkMocks.NewGeneralConfig(t), + scfg: evmConfigMocks.NewChainScopedConfig(t), + ocr: keystoreMocks.NewOCR(t), + ocr2: keystoreMocks.NewOCR2(t), + csa: keystoreMocks.NewCSA(t), + keystore: keystoreMocks.NewMaster(t), + ethKs: keystoreMocks.NewEth(t), + p2p: keystoreMocks.NewP2P(t), + vrf: keystoreMocks.NewVRF(t), + solana: keystoreMocks.NewSolana(t), + chain: evmORMMocks.NewChain(t), + legacyEVMChains: evmORMMocks.NewLegacyChainContainer(t), + relayerChainInterops: chainlinkMocks.NewRelayerChainInteroperators(t), + ethClient: evmClientMocks.NewClient(t), + eIMgr: webhookmocks.NewExternalInitiatorManager(t), + balM: evmORMMocks.NewBalanceMonitor(t), + txmStore: evmtxmgrmocks.NewEvmTxStore(t), + auditLogger: &audit.AuditLoggerService{}, } app.Mock.On("GetAuditLogger", mock.Anything, mock.Anything).Return(audit.NoopLogger).Maybe() diff --git a/core/web/solana_chains_controller.go b/core/web/solana_chains_controller.go index 5c6e1854ec4..8e2d4393a5f 100644 --- a/core/web/solana_chains_controller.go +++ b/core/web/solana_chains_controller.go @@ -2,10 +2,16 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) func NewSolanaChainsController(app chainlink.Application) ChainsController { - return newChainsController("solana", app.GetChains().Solana, ErrSolanaNotEnabled, - presenters.NewSolanaChainResource, app.GetLogger(), app.GetAuditLogger()) + return newChainsController( + relay.Solana, + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.Solana)), + ErrSolanaNotEnabled, + presenters.NewSolanaChainResource, + app.GetLogger(), + app.GetAuditLogger()) } diff --git a/core/web/solana_chains_controller_test.go b/core/web/solana_chains_controller_test.go index 5f2c00540d0..e6055840804 100644 --- a/core/web/solana_chains_controller_test.go +++ b/core/web/solana_chains_controller_test.go @@ -8,11 +8,12 @@ import ( "time" "github.com/manyminds/api2go/jsonapi" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink-relay/pkg/types" "github.com/smartcontractkit/chainlink-relay/pkg/utils" "github.com/smartcontractkit/chainlink-solana/pkg/solana/config" - "github.com/stretchr/testify/assert" - "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/chains/solana" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" diff --git a/core/web/solana_nodes_controller.go b/core/web/solana_nodes_controller.go index 350da7152e3..1c12418a5b2 100644 --- a/core/web/solana_nodes_controller.go +++ b/core/web/solana_nodes_controller.go @@ -2,6 +2,7 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) @@ -10,5 +11,5 @@ var ErrSolanaNotEnabled = errChainDisabled{name: "Solana", tomlKey: "Solana.Enab func NewSolanaNodesController(app chainlink.Application) NodesController { return newNodesController[presenters.SolanaNodeResource]( - app.GetChains().Solana, ErrSolanaNotEnabled, presenters.NewSolanaNodeResource, app.GetAuditLogger()) + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.Solana)), ErrSolanaNotEnabled, presenters.NewSolanaNodeResource, app.GetAuditLogger()) } diff --git a/core/web/solana_transfer_controller.go b/core/web/solana_transfer_controller.go index 5180a9d42c7..cd650f37ba1 100644 --- a/core/web/solana_transfer_controller.go +++ b/core/web/solana_transfer_controller.go @@ -11,6 +11,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" solanamodels "github.com/smartcontractkit/chainlink/v2/core/store/models/solana" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) @@ -22,8 +23,8 @@ type SolanaTransfersController struct { // Create sends SOL and other native coins from the Chainlink's account to a specified address. func (tc *SolanaTransfersController) Create(c *gin.Context) { - relayer := tc.App.GetChains().Solana - if relayer == nil { + relayers := tc.App.GetRelayers().List(chainlink.FilterRelayersByType(relay.Solana)) + if relayers == nil { jsonAPIError(c, http.StatusBadRequest, ErrSolanaNotEnabled) return } @@ -47,7 +48,20 @@ func (tc *SolanaTransfersController) Create(c *gin.Context) { } amount := new(big.Int).SetUint64(tr.Amount) - err := relayer.SendTx(c, tr.SolanaChainID, tr.From.String(), tr.To.String(), amount, !tr.AllowHigherAmounts) + relayerID := relay.Identifier{Network: relay.Solana, ChainID: relay.ChainID(tr.SolanaChainID)} + relayer, err := relayers.Get(relayerID) + if err != nil { + if errors.Is(err, chainlink.ErrNoSuchRelayer) { + jsonAPIError(c, http.StatusBadRequest, err) + return + } else { + jsonAPIError(c, http.StatusInternalServerError, err) + return + } + } + // note the [loop.Relayer] API is in intermediate state. we found the relayer above; we should not need to pass + // the chain id here + err = relayer.SendTx(c, tr.SolanaChainID, tr.From.String(), tr.To.String(), amount, !tr.AllowHigherAmounts) if err != nil { switch err { case chains.ErrNotFound, chains.ErrChainIDEmpty: diff --git a/core/web/starknet_chains_controller.go b/core/web/starknet_chains_controller.go index 7b5baee95e8..414e17d9823 100644 --- a/core/web/starknet_chains_controller.go +++ b/core/web/starknet_chains_controller.go @@ -2,10 +2,16 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) func NewStarkNetChainsController(app chainlink.Application) ChainsController { - return newChainsController("starknet", app.GetChains().StarkNet, ErrStarkNetNotEnabled, - presenters.NewStarkNetChainResource, app.GetLogger(), app.GetAuditLogger()) + return newChainsController( + relay.StarkNet, + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.StarkNet)), + ErrStarkNetNotEnabled, + presenters.NewStarkNetChainResource, + app.GetLogger(), + app.GetAuditLogger()) } diff --git a/core/web/starknet_nodes_controller.go b/core/web/starknet_nodes_controller.go index 23cf27cee15..5c6e5c4d575 100644 --- a/core/web/starknet_nodes_controller.go +++ b/core/web/starknet_nodes_controller.go @@ -2,6 +2,7 @@ package web import ( "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/relay" "github.com/smartcontractkit/chainlink/v2/core/web/presenters" ) @@ -10,5 +11,5 @@ var ErrStarkNetNotEnabled = errChainDisabled{name: "StarkNet", tomlKey: "Starkne func NewStarkNetNodesController(app chainlink.Application) NodesController { return newNodesController[presenters.StarkNetNodeResource]( - app.GetChains().StarkNet, ErrStarkNetNotEnabled, presenters.NewStarkNetNodeResource, app.GetAuditLogger()) + app.GetRelayers().List(chainlink.FilterRelayersByType(relay.StarkNet)), ErrStarkNetNotEnabled, presenters.NewStarkNetNodeResource, app.GetAuditLogger()) } diff --git a/go.mod b/go.mod index a95e4d1d03f..b1e1245b7ce 100644 --- a/go.mod +++ b/go.mod @@ -65,7 +65,7 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a diff --git a/go.sum b/go.sum index 8416db79d14..927d3733233 100644 --- a/go.sum +++ b/go.sum @@ -1433,8 +1433,8 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 91f93f3289d..12cb324064f 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -381,7 +381,7 @@ require ( github.com/shopspring/decimal v1.3.1 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 9bbdef73f12..fefc570179b 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2237,8 +2237,8 @@ github.com/slack-go/slack v0.12.2 h1:x3OppyMyGIbbiyFhsBmpf9pwkUzMhthJMRNmNlA4LaQ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQdlMQKOw= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24 h1:hK/BPzpROry7dR6pXcVWlgNlb6rmwctyw6gNlaeHkfk= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230802143343-59cdfce9fb24/go.mod h1:Tm2RONlTE3lIxsdu7rX2J1y9hjfUeUQLBXZx+8lzg/M= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= diff --git a/integration-tests/smoke/forwarders_ocr2_test.go b/integration-tests/smoke/forwarders_ocr2_test.go index 0c184eac479..cb6a3f0556d 100644 --- a/integration-tests/smoke/forwarders_ocr2_test.go +++ b/integration-tests/smoke/forwarders_ocr2_test.go @@ -8,10 +8,11 @@ import ( "time" "github.com/ethereum/go-ethereum/common" + "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" - "github.com/stretchr/testify/require" ) func TestForwarderOCR2Basic(t *testing.T) { From f079fdf45486f869bf6597b8acbb93286160b3e9 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Thu, 17 Aug 2023 13:15:24 +0100 Subject: [PATCH 200/270] update getBlockHash to not use rpc client (#10244) * update getBlockHash to not use rpc client * remove another ref * fix test --- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 11 +++++++---- .../ocr2/plugins/ocr2keeper/evm21/registry_test.go | 6 +++--- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 0d8ef509d81..5548b22de07 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -936,12 +936,15 @@ func (r *EvmRegistry) fetchTriggerConfig(id *big.Int) ([]byte, error) { } func (r *EvmRegistry) getBlockHash(blockNumber *big.Int) (common.Hash, error) { - block, err := r.client.BlockByNumber(r.ctx, blockNumber) + blocks, err := r.poller.GetBlocksRange(r.ctx, []uint64{blockNumber.Uint64()}) if err != nil { return [32]byte{}, err } + if len(blocks) == 0 { + return [32]byte{}, fmt.Errorf("could not find block %d in log poller", blockNumber.Uint64()) + } - return block.Hash(), nil + return blocks[0].BlockHash, nil } func (r *EvmRegistry) getTxBlock(txHash common.Hash) (*big.Int, common.Hash, error) { @@ -983,12 +986,12 @@ func (r *EvmRegistry) verifyCheckBlock(ctx context.Context, checkBlock, upkeepId h, ok = r.bs.queryBlocksMap(checkBlock.Int64()) if !ok { r.lggr.Warnf("check block %s does not exist in block subscriber for upkeepId %s, querying eth client", checkBlock, upkeepId) - b, err := r.client.BlockByNumber(ctx, checkBlock) + hash, err := r.getBlockHash(checkBlock) if err != nil { r.lggr.Warnf("failed to query block %s: %s", checkBlock, err.Error()) return RpcFlakyFailure, true } - h = b.Hash().Hex() + h = hash.Hex() } if checkHash.Hex() != h { r.lggr.Warnf("check block %s hash do not match. %s from block subscriber vs %s from trigger for upkeepId %s", checkBlock, h, checkHash.Hex(), upkeepId) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go index 57ab7dcc114..28889d0006f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go @@ -447,9 +447,9 @@ func TestRegistry_VerifyCheckBlock(t *testing.T) { bs: bs, } if tc.makeEthCall { - client := new(evmClientMocks.Client) - client.On("BlockByNumber", mock.Anything, tc.checkBlock).Return(nil, fmt.Errorf("error")) - e.client = client + poller := new(mocks.LogPoller) + poller.On("GetBlocksRange", mock.Anything, mock.Anything).Return(nil, fmt.Errorf("error")) + e.poller = poller } state, retryable := e.verifyCheckBlock(context.Background(), tc.checkBlock, tc.upkeepId, tc.checkHash) From 8e03d55e380fc4396fe2e97f9923098ee71bbdea Mon Sep 17 00:00:00 2001 From: Makram Date: Thu, 17 Aug 2023 17:45:41 +0300 Subject: [PATCH 201/270] chore: add s_subIds collection to SubscriptionAPI.sol (#10219) * chore: add s_subIds collection to SubscriptionAPI.sol * chore: add unit test for getSubscriptionIds * chore: rename to getActiveSubscriptionIds * chore: bump snapshot * chore: more tests * chore: prettier * chore: add more assertions in test * chore: remove useless test * chore: assertNotEq doesn't exist anymore? * chore: update vrf snapshot * FOUNDRY_PROFILE=vrf make snapshot --------- Co-authored-by: Rens Rooimans --- contracts/gas-snapshots/vrf.gas-snapshot | 25 ++++---- contracts/scripts/native_solc_compile_all_vrf | 2 +- .../dev/interfaces/IVRFSubscriptionV2Plus.sol | 9 +++ .../src/v0.8/dev/vrf/SubscriptionAPI.sol | 35 +++++++++++ .../ExposedVRFCoordinatorV2Plus.sol | 7 +++ .../test/v0.8/foundry/vrf/VRFV2Plus.t.sol | 63 +++++++++++++++++++ .../vrf_coordinator_v2plus.go | 28 ++++++++- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 8 files changed, 155 insertions(+), 16 deletions(-) diff --git a/contracts/gas-snapshots/vrf.gas-snapshot b/contracts/gas-snapshots/vrf.gas-snapshot index a6232a44400..637a0edf963 100644 --- a/contracts/gas-snapshots/vrf.gas-snapshot +++ b/contracts/gas-snapshots/vrf.gas-snapshot @@ -1,14 +1,15 @@ TrustedBlockhashStoreTest:testGenericBHSFunctions() (gas: 53507) TrustedBlockhashStoreTest:testTrustedBHSFunctions() (gas: 49536) -VRFCoordinatorV2Plus_Migration:testDeregister() (gas: 99350) -VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCaller() (gas: 27277) -VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCoordinator() (gas: 17777) -VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenPendingFulfillment() (gas: 237557) -VRFCoordinatorV2Plus_Migration:testMigration() (gas: 451067) -VRFV2Plus:testCreateSubscription() (gas: 92494) -VRFV2Plus:testRegisterProvingKey() (gas: 100951) -VRFV2Plus:testRequestAndFulfillRandomWordsLINK() (gas: 667896) -VRFV2Plus:testRequestAndFulfillRandomWordsNative() (gas: 618375) -VRFV2Plus:testSetConfig() (gas: 72991) -VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsLINKWrapper() (gas: 373063) -VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsNativeWrapper() (gas: 273557) \ No newline at end of file +VRFCoordinatorV2Plus_Migration:testDeregister() (gas: 99368) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCaller() (gas: 27234) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenInvalidCoordinator() (gas: 17734) +VRFCoordinatorV2Plus_Migration:testMigrateRevertsWhenPendingFulfillment() (gas: 237536) +VRFCoordinatorV2Plus_Migration:testMigration() (gas: 468424) +VRFV2Plus:testCreateSubscription() (gas: 181121) +VRFV2Plus:testGetActiveSubscriptionIds() (gas: 3465607) +VRFV2Plus:testRegisterProvingKey() (gas: 101019) +VRFV2Plus:testRequestAndFulfillRandomWordsLINK() (gas: 755125) +VRFV2Plus:testRequestAndFulfillRandomWordsNative() (gas: 705549) +VRFV2Plus:testSetConfig() (gas: 73057) +VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsLINKWrapper() (gas: 390063) +VRFV2PlusWrapperTest:testRequestAndFulfillRandomWordsNativeWrapper() (gas: 290612) \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_vrf b/contracts/scripts/native_solc_compile_all_vrf index ac5a183e55d..8b35ac45748 100755 --- a/contracts/scripts/native_solc_compile_all_vrf +++ b/contracts/scripts/native_solc_compile_all_vrf @@ -55,7 +55,7 @@ compileContract vrf/VRFOwner.sol # VRF V2Plus compileContract dev/vrf/testhelpers/VRFV2PlusConsumerExample.sol -compileContractAltOpts dev/vrf/VRFCoordinatorV2Plus.sol 1000 +compileContractAltOpts dev/vrf/VRFCoordinatorV2Plus.sol 500 compileContract dev/vrf/BatchVRFCoordinatorV2Plus.sol compileContract dev/vrf/VRFV2PlusWrapper.sol compileContract dev/vrf/testhelpers/VRFConsumerV2PlusUpgradeableExample.sol diff --git a/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol b/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol index 655a585207f..47b31d98bd1 100644 --- a/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol +++ b/contracts/src/v0.8/dev/interfaces/IVRFSubscriptionV2Plus.sol @@ -71,6 +71,15 @@ interface IVRFSubscriptionV2Plus { view returns (uint96 balance, uint96 ethBalance, uint64 reqCount, address owner, address[] memory consumers); + /** + * @notice Paginate through all active VRF subscriptions. + * @param startIndex index of the subscription to start from + * @param maxCount maximum number of subscriptions to return, 0 to return all + * @dev the order of IDs in the list is **not guaranteed**, therefore, if making successive calls, one + * @dev should consider keeping the blockheight constant to ensure a holistic picture of the contract state + */ + function getActiveSubscriptionIds(uint256 startIndex, uint256 maxCount) external view returns (uint256[] memory); + /** * @notice Fund a subscription with ETH. * @param subId - ID of the subscription diff --git a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol index e0909460639..3113385ecac 100644 --- a/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol +++ b/contracts/src/v0.8/dev/vrf/SubscriptionAPI.sol @@ -1,6 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.0; +import "../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; import "../../shared/interfaces/LinkTokenInterface.sol"; import "../../shared/access/ConfirmedOwner.sol"; import "../../interfaces/AggregatorV3Interface.sol"; @@ -8,6 +9,8 @@ import "../../shared/interfaces/IERC677Receiver.sol"; import "../interfaces/IVRFSubscriptionV2Plus.sol"; abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscriptionV2Plus { + using EnumerableSet for EnumerableSet.UintSet; + /// @dev may not be provided upon construction on some chains due to lack of availability LinkTokenInterface public LINK; /// @dev may not be provided upon construction on some chains due to lack of availability @@ -31,6 +34,7 @@ abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscr event EthFundsRecovered(address to, uint256 amount); error LinkAlreadySet(); error FailedToSendEther(); + error IndexOutOfRange(); // We use the subscription struct (1 word) // at fulfillment time. @@ -60,6 +64,13 @@ abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscr mapping(uint256 => Subscription) /* subId */ /* subscription */ internal s_subscriptions; // subscription nonce used to construct subID. Rises monotonically uint64 public s_currentSubNonce; + // track all subscription id's that were created by this contract + // note: access should be through the getActiveSubscriptionIds() view function + // which takes a starting index and a max number to fetch in order to allow + // "pagination" of the subscription ids. in the event a very large number of + // subscription id's are stored in this set, they cannot be retrieved in a + // single RPC call without violating various size limits. + EnumerableSet.UintSet internal s_subIds; // s_totalBalance tracks the total link sent to/from // this contract through onTokenTransfer, cancelSubscription and oracleWithdraw. // A discrepancy with this contract's link balance indicates someone @@ -273,14 +284,35 @@ abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscr ); } + /** + * @inheritdoc IVRFSubscriptionV2Plus + */ + function getActiveSubscriptionIds( + uint256 startIndex, + uint256 maxCount + ) external view override returns (uint256[] memory) { + uint256 numSubs = s_subIds.length(); + if (startIndex >= numSubs) revert IndexOutOfRange(); + uint256 endIndex = startIndex + maxCount; + endIndex = endIndex > numSubs || maxCount == 0 ? numSubs : endIndex; + uint256[] memory ids = new uint256[](endIndex - startIndex); + for (uint256 idx = 0; idx < ids.length; idx++) { + ids[idx] = s_subIds.at(idx + startIndex); + } + return ids; + } + /** * @inheritdoc IVRFSubscriptionV2Plus */ function createSubscription() external override nonReentrant returns (uint256) { + // Generate a subscription id that is globally unique. uint256 subId = uint256( keccak256(abi.encodePacked(msg.sender, blockhash(block.number - 1), address(this), s_currentSubNonce)) ); + // Increment the subscription nonce counter. s_currentSubNonce++; + // Initialize storage variables. address[] memory consumers = new address[](0); s_subscriptions[subId] = Subscription({balance: 0, ethBalance: 0, reqCount: 0}); s_subscriptionConfigs[subId] = SubscriptionConfig({ @@ -288,6 +320,8 @@ abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscr requestedOwner: address(0), consumers: consumers }); + // Update the s_subIds set, which tracks all subscription ids created in this contract. + s_subIds.add(subId); emit SubscriptionCreated(subId, msg.sender); return subId; @@ -355,6 +389,7 @@ abstract contract SubscriptionAPI is ConfirmedOwner, IERC677Receiver, IVRFSubscr } delete s_subscriptionConfigs[subId]; delete s_subscriptions[subId]; + s_subIds.remove(subId); s_totalBalance -= balance; s_totalEthBalance -= ethBalance; return (balance, ethBalance); diff --git a/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol b/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol index 819225bd7ed..82f4068112d 100644 --- a/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol +++ b/contracts/src/v0.8/dev/vrf/testhelpers/ExposedVRFCoordinatorV2Plus.sol @@ -3,8 +3,11 @@ pragma solidity ^0.8.4; import "../../../vrf/VRF.sol"; import {VRFCoordinatorV2Plus} from "../VRFCoordinatorV2Plus.sol"; +import "../../../vendor/openzeppelin-solidity/v4.7.3/contracts/utils/structs/EnumerableSet.sol"; contract ExposedVRFCoordinatorV2Plus is VRFCoordinatorV2Plus { + using EnumerableSet for EnumerableSet.UintSet; + constructor(address blockhashStore) VRFCoordinatorV2Plus(blockhashStore) {} function computeRequestIdExternal( @@ -26,4 +29,8 @@ contract ExposedVRFCoordinatorV2Plus is VRFCoordinatorV2Plus { ) external view returns (Output memory) { return getRandomnessFromProof(proof, rc); } + + function getActiveSubscriptionIdsLength() external view returns (uint256) { + return s_subIds.length(); + } } diff --git a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol index 2fed36c86b2..4e22008549c 100644 --- a/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol +++ b/contracts/test/v0.8/foundry/vrf/VRFV2Plus.t.sol @@ -11,6 +11,7 @@ import {VRFV2PlusConsumerExample} from "../../../../src/v0.8/dev/vrf/testhelpers import {VRFV2PlusClient} from "../../../../src/v0.8/dev/vrf/libraries/VRFV2PlusClient.sol"; import {console} from "forge-std/console.sol"; import {VmSafe} from "forge-std/Vm.sol"; +import "@openzeppelin/contracts/utils/math/Math.sol"; // for Math.ceilDiv /* * USAGE INSTRUCTIONS: @@ -141,6 +142,68 @@ contract VRFV2Plus is BaseTest { s_testCoordinator.fundSubscriptionWithEth{value: 10 ether}(subId); } + function testGetActiveSubscriptionIds() public { + uint numSubs = 40; + for (uint i = 0; i < numSubs; i++) { + s_testCoordinator.createSubscription(); + } + // get all subscriptions, assert length is correct + uint256[] memory allSubs = s_testCoordinator.getActiveSubscriptionIds(0, 0); + assertEq(allSubs.length, s_testCoordinator.getActiveSubscriptionIdsLength()); + + // paginate through subscriptions, batching by 10. + // we should eventually get all the subscriptions this way. + uint256[][] memory subIds = paginateSubscriptions(s_testCoordinator, 10); + // check that all subscriptions were returned + uint actualNumSubs = 0; + for (uint batchIdx = 0; batchIdx < subIds.length; batchIdx++) { + for (uint subIdx = 0; subIdx < subIds[batchIdx].length; subIdx++) { + s_testCoordinator.getSubscription(subIds[batchIdx][subIdx]); + actualNumSubs++; + } + } + assertEq(actualNumSubs, s_testCoordinator.getActiveSubscriptionIdsLength()); + + // cancel a bunch of subscriptions, assert that they are not returned + uint256[] memory subsToCancel = new uint256[](3); + for (uint i = 0; i < 3; i++) { + subsToCancel[i] = subIds[0][i]; + } + for (uint i = 0; i < subsToCancel.length; i++) { + s_testCoordinator.cancelSubscription(subsToCancel[i], LINK_WHALE); + } + uint256[][] memory newSubIds = paginateSubscriptions(s_testCoordinator, 10); + // check that all subscriptions were returned + // and assert that none of the canceled subscriptions are returned + actualNumSubs = 0; + for (uint batchIdx = 0; batchIdx < newSubIds.length; batchIdx++) { + for (uint subIdx = 0; subIdx < newSubIds[batchIdx].length; subIdx++) { + for (uint i = 0; i < subsToCancel.length; i++) { + assertFalse(newSubIds[batchIdx][subIdx] == subsToCancel[i]); + } + s_testCoordinator.getSubscription(newSubIds[batchIdx][subIdx]); + actualNumSubs++; + } + } + assertEq(actualNumSubs, s_testCoordinator.getActiveSubscriptionIdsLength()); + } + + function paginateSubscriptions( + ExposedVRFCoordinatorV2Plus coordinator, + uint256 batchSize + ) internal view returns (uint256[][] memory) { + uint arrIndex = 0; + uint startIndex = 0; + uint256 numSubs = coordinator.getActiveSubscriptionIdsLength(); + uint256[][] memory subIds = new uint256[][](Math.ceilDiv(numSubs, batchSize)); + while (startIndex < numSubs) { + subIds[arrIndex] = coordinator.getActiveSubscriptionIds(startIndex, batchSize); + startIndex += batchSize; + arrIndex++; + } + return subIds; + } + event RandomWordsRequested( bytes32 indexed keyHash, uint256 requestId, diff --git a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go index 3f13a956981..f4f52e85382 100644 --- a/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go +++ b/core/gethwrappers/generated/vrf_coordinator_v2plus/vrf_coordinator_v2plus.go @@ -66,8 +66,8 @@ type VRFV2PlusClientRandomWordsRequest struct { } var VRFCoordinatorV2PlusMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"reentrancyLock\",\"type\":\"bool\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b506040516200607b3803806200607b833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615ea0620001db6000396000818161060b0152613a8c0152615ea06000f3fe6080604052600436106102f15760003560e01c806386fe91c71161018f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095b578063ee9d2d3814610982578063f2fde38b146109af57600080fd5b8063dc311dd3146108f7578063e72f6e3014610928578063e8509bff1461094857600080fd5b8063d98e620e116100bb578063d98e620e14610881578063da2f2610146108a1578063dac83d29146108d757600080fd5b8063bec4c08c14610821578063caf70c4a14610841578063cb6317971461086157600080fd5b8063a4c0ed3611610143578063ad1783611161011d578063ad178361146107c1578063b08c8795146107e1578063b2a7cac51461080157600080fd5b8063a4c0ed3614610761578063a8cb447b14610781578063aa433aff146107a157600080fd5b80639b1c385e116101745780639b1c385e146106f25780639d40a6fd14610712578063a21a23e41461074c57600080fd5b806386fe91c7146106a85780638da5cb5b146106d457600080fd5b806340d6bb821161024857806364d51a2a116101fc5780636b6feccc116101d65780636b6feccc1461062d5780636f64f03f1461067357806379ba50971461069357600080fd5b806364d51a2a146105c457806366316d8d146105d9578063689c4517146105f957600080fd5b806346d8d4861161022d57806346d8d4861461056457806357133e64146105845780635d06b4ab146105a457600080fd5b806340d6bb821461050957806341af6c871461053457600080fd5b80630ae09540116102aa578063294daa4911610284578063294daa4914610495578063330987b3146104b1578063405b84fa146104e957600080fd5b80630ae095401461041557806315c48b84146104355780631b6b6d231461045d57600080fd5b8063043bd6ae116102db578063043bd6ae14610345578063088070f51461036957806308821d58146103f557600080fd5b8062012291146102f657806304104edb14610323575b600080fd5b34801561030257600080fd5b5061030b6109cf565b60405161031a939291906159c7565b60405180910390f35b34801561032f57600080fd5b5061034361033e366004615375565b610a4b565b005b34801561035157600080fd5b5061035b600e5481565b60405190815260200161031a565b34801561037557600080fd5b50600a546103bd9061ffff81169063ffffffff62010000820481169160ff600160301b8204169167010000000000000082048116916b01000000000000000000000090041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a00161031a565b34801561040157600080fd5b506103436104103660046154b6565b610c0d565b34801561042157600080fd5b5061034361043036600461575b565b610da1565b34801561044157600080fd5b5061044a60c881565b60405161ffff909116815260200161031a565b34801561046957600080fd5b5060025461047d906001600160a01b031681565b6040516001600160a01b03909116815260200161031a565b3480156104a157600080fd5b506040516001815260200161031a565b3480156104bd57600080fd5b506104d16104cc366004615589565b610e6f565b6040516001600160601b03909116815260200161031a565b3480156104f557600080fd5b5061034361050436600461575b565b6113a3565b34801561051557600080fd5b5061051f6101f481565b60405163ffffffff909116815260200161031a565b34801561054057600080fd5b5061055461054f36600461550b565b611783565b604051901515815260200161031a565b34801561057057600080fd5b5061034361057f366004615392565b611985565b34801561059057600080fd5b5061034361059f3660046153c7565b611b02565b3480156105b057600080fd5b506103436105bf366004615375565b611b7b565b3480156105d057600080fd5b5061044a606481565b3480156105e557600080fd5b506103436105f4366004615392565b611c52565b34801561060557600080fd5b5061047d7f000000000000000000000000000000000000000000000000000000000000000081565b34801561063957600080fd5b50600f546106569063ffffffff8082169164010000000090041682565b6040805163ffffffff93841681529290911660208301520161031a565b34801561067f57600080fd5b5061034361068e366004615400565b611df1565b34801561069f57600080fd5b50610343611f09565b3480156106b457600080fd5b506007546104d1906801000000000000000090046001600160601b031681565b3480156106e057600080fd5b506000546001600160a01b031661047d565b3480156106fe57600080fd5b5061035b61070d366004615667565b611fba565b34801561071e57600080fd5b506007546107339067ffffffffffffffff1681565b60405167ffffffffffffffff909116815260200161031a565b34801561075857600080fd5b5061035b6123e4565b34801561076d57600080fd5b5061034361077c36600461542d565b61266c565b34801561078d57600080fd5b5061034361079c366004615375565b61283e565b3480156107ad57600080fd5b506103436107bc36600461550b565b612959565b3480156107cd57600080fd5b5060035461047d906001600160a01b031681565b3480156107ed57600080fd5b506103436107fc3660046156bd565b6129b9565b34801561080d57600080fd5b5061034361081c36600461550b565b612b55565b34801561082d57600080fd5b5061034361083c36600461575b565b612ca4565b34801561084d57600080fd5b5061035b61085c3660046154d2565b612e5a565b34801561086d57600080fd5b5061034361087c36600461575b565b612e8a565b34801561088d57600080fd5b5061035b61089c36600461550b565b61318e565b3480156108ad57600080fd5b5061047d6108bc36600461550b565b600b602052600090815260409020546001600160a01b031681565b3480156108e357600080fd5b506103436108f236600461575b565b6131af565b34801561090357600080fd5b5061091761091236600461550b565b6132ce565b60405161031a959493929190615b65565b34801561093457600080fd5b50610343610943366004615375565b6133ca565b61034361095636600461550b565b613592565b34801561096757600080fd5b506007546104d190600160a01b90046001600160601b031681565b34801561098e57600080fd5b5061035b61099d36600461550b565b600d6020526000908152604090205481565b3480156109bb57600080fd5b506103436109ca366004615375565b6136d1565b600a54600c805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3957602002820191906000526020600020905b815481526020019060010190808311610a25575b50505050509050925092509250909192565b610a536136e2565b60105460005b81811015610be057826001600160a01b031660108281548110610a7e57610a7e615e44565b6000918252602090912001546001600160a01b03161415610bce576010610aa6600184615d3c565b81548110610ab657610ab6615e44565b600091825260209091200154601080546001600160a01b039092169183908110610ae257610ae2615e44565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826010610b19600185615d3c565b81548110610b2957610b29615e44565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506010805480610b6857610b68615e2e565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bd881615dab565b915050610a59565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c156136e2565b604080518082018252600091610c44919084906002908390839080828437600092019190915250612e5a915050565b6000818152600b60205260409020549091506001600160a01b031680610c8057604051631dfd6e1360e21b815260048101839052602401610c01565b6000828152600b6020526040812080546001600160a01b03191690555b600c54811015610d585782600c8281548110610cbb57610cbb615e44565b90600052602060002001541415610d4657600c805460009190610ce090600190615d3c565b81548110610cf057610cf0615e44565b9060005260206000200154905080600c8381548110610d1157610d11615e44565b600091825260209091200155600c805480610d2e57610d2e615e2e565b60019003818190600052602060002001600090559055505b80610d5081615dab565b915050610c9d565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9491815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610dd957604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0d57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615610e385760405163769dd35360e11b815260040160405180910390fd5b610e4184611783565b15610e5f57604051631685ecdd60e31b815260040160405180910390fd5b610e69848461373e565b50505050565b600a54600090600160301b900460ff1615610e9d5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eae85856138d5565b90506000846060015163ffffffff1667ffffffffffffffff811115610ed557610ed5615e5a565b604051908082528060200260200182016040528015610efe578160200160208202803683370190505b50905060005b856060015163ffffffff16811015610f7e57826040015181604051602001610f36929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f6157610f61615e44565b602090810291909101015280610f7681615dab565b915050610f04565b50602080830180516000908152600d90925260408083208390559051905182917f1fe543e30000000000000000000000000000000000000000000000000000000091610fcf91908690602401615a3a565b60408051601f198184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b031990941693909317909252600a805466ff0000000000001916600160301b17905590880151608089015191925060009161104c9163ffffffff169084613bc8565b600a805466ff00000000000019169055602089810151600090815260069091526040902054909150600160c01b900467ffffffffffffffff16611090816001615cbb565b6020808b01516000908152600690915260408120805467ffffffffffffffff93909316600160c01b0277ffffffffffffffffffffffffffffffffffffffffffffffff9093169290921790915560a08a015180516110ef90600190615d3c565b815181106110ff576110ff615e44565b602091010151600a5460f89190911c6001149150600090611138908a906b010000000000000000000000900463ffffffff163a85613c16565b90508115611241576020808c01516000908152600690915260409020546001600160601b03808316600160601b90920416101561118857604051631e9acf1760e31b815260040160405180910390fd5b60208b81015160009081526006909152604090208054829190600c906111bf908490600160601b90046001600160601b0316615d53565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600990915281208054859450909261121891859116615ce7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555061132d565b6020808c01516000908152600690915260409020546001600160601b038083169116101561128257604051631e9acf1760e31b815260040160405180910390fd5b6020808c0151600090815260069091526040812080548392906112af9084906001600160601b0316615d53565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600b60209081526040808320546001600160a01b03168352600890915281208054859450909261130891859116615ce7565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b8a6020015188602001517f49580fdfd9497e1ed5c1b1cec0495087ae8e3f1267470ec2fb015db32e3d6aa78a60400151848860405161138a939291909283526001600160601b039190911660208301521515604082015260600190565b60405180910390a3985050505050505050505b92915050565b6113ac81613c66565b6113d457604051635428d44960e01b81526001600160a01b0382166004820152602401610c01565b6000806000806113e3866132ce565b945094505093509350336001600160a01b0316826001600160a01b03161461144d5760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c01565b61145686611783565b156114a35760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c01565b60006040518060c001604052806114b8600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b0316815250905060008160405160200161150c9190615952565b604051602081830303815290604052905061152688613cd0565b50506040517fce3f47190000000000000000000000000000000000000000000000000000000081526001600160a01b0388169063ce3f4719906001600160601b0388169061157890859060040161593f565b6000604051808303818588803b15801561159157600080fd5b505af11580156115a5573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b15801561160157600080fd5b505af1158015611615573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061163991906154ee565b6116855760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c01565b60005b8351811015611736578381815181106116a3576116a3615e44565b60209081029190910101516040517f8ea981170000000000000000000000000000000000000000000000000000000081526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561170b57600080fd5b505af115801561171f573d6000803e3d6000fd5b50505050808061172e90615dab565b915050611688565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561180d57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116117ef575b505050505081525050905060005b81604001515181101561197b5760005b600c54811015611968576000611931600c838154811061184d5761184d615e44565b90600052602060002001548560400151858151811061186e5761186e615e44565b602002602001015188600460008960400151898151811061189157611891615e44565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e825282528290205482518083018890529590931685830152606085019390935267ffffffffffffffff9091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b506000818152600d6020526040902054909150156119555750600195945050505050565b508061196081615dab565b91505061182b565b508061197381615dab565b91505061181b565b5060009392505050565b600a54600160301b900460ff16156119b05760405163769dd35360e11b815260040160405180910390fd5b336000908152600960205260409020546001600160601b03808316911610156119ec57604051631e9acf1760e31b815260040160405180910390fd5b3360009081526009602052604081208054839290611a149084906001600160601b0316615d53565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760148282829054906101000a90046001600160601b0316611a5c9190615d53565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611ad6576040519150601f19603f3d011682016040523d82523d6000602084013e611adb565b606091505b5050905080611afd57604051630dcf35db60e41b815260040160405180910390fd5b505050565b611b0a6136e2565b6002546001600160a01b031615611b4d576040517f2d118a6e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611b836136e2565b611b8c81613c66565b15611bce576040517fac8a27ef0000000000000000000000000000000000000000000000000000000081526001600160a01b0382166004820152602401610c01565b601080546001810182556000919091527f1b6847dc741a1b0cd08d278845f9d819d87b734759afb55fe2de5cb82a9ae6720180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600a54600160301b900460ff1615611c7d5760405163769dd35360e11b815260040160405180910390fd5b336000908152600860205260409020546001600160601b0380831691161015611cb957604051631e9acf1760e31b815260040160405180910390fd5b3360009081526008602052604081208054839290611ce19084906001600160601b0316615d53565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600760088282829054906101000a90046001600160601b0316611d299190615d53565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611d9857600080fd5b505af1158015611dac573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611dd091906154ee565b611ded57604051631e9acf1760e31b815260040160405180910390fd5b5050565b611df96136e2565b604080518082018252600091611e28919084906002908390839080828437600092019190915250612e5a915050565b6000818152600b60205260409020549091506001600160a01b031615611e7d576040517f4a0b8fa700000000000000000000000000000000000000000000000000000000815260048101829052602401610c01565b6000818152600b6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600c805460018101825594527fdf6966c971051c3d54ec59162606531493a51404a002842f56009d7e5cf4a8c7909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d94565b6001546001600160a01b03163314611f635760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c01565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600a54600090600160301b900460ff1615611fe85760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b031661202357604051630fb532db60e11b815260040160405180910390fd5b33600090815260046020908152604080832085830135845290915290205467ffffffffffffffff1680612075576040516379bfd40160e01b815260208401356004820152336024820152604401610c01565b600a5461ffff1661208c60608501604086016156a2565b61ffff1610806120af575060c86120a960608501604086016156a2565b61ffff16115b156120f5576120c460608401604085016156a2565b600a5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c01565b600a5462010000900463ffffffff166121146080850160608601615780565b63ffffffff16111561217d576121306080840160608501615780565b600a546040517ff5d7e01e00000000000000000000000000000000000000000000000000000000815263ffffffff9283166004820152620100009091049091166024820152604401610c01565b6101f461219060a0850160808601615780565b63ffffffff1611156121ef576121ac60a0840160808501615780565b6040517f47386bec00000000000000000000000000000000000000000000000000000000815263ffffffff90911660048201526101f46024820152604401610c01565b60006121fc826001615cbb565b6040805186356020808301829052338385015280890135606084015267ffffffffffffffff85166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e08085018490528551808603909101815261010090940190945282519201919091209293509060009061228d9061228890890189615bbb565b613f20565b9050600061229a82613fcf565b9050836122a5614055565b60208a01356122ba60808c0160608d01615780565b6122ca60a08d0160808e01615780565b33866040516020016122e29796959493929190615ac7565b60405160208183030381529060405280519060200120600d600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061235991906156a2565b8e606001602081019061236c9190615780565b8f608001602081019061237f9190615780565b8960405161239296959493929190615a88565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff191667ffffffffffffffff9490941693909317909255925050505b919050565b600a54600090600160301b900460ff16156124125760405163769dd35360e11b815260040160405180910390fd5b600033612420600143615d3c565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b7fffffffffffffffff00000000000000000000000000000000000000000000000016606882015260700160408051601f1981840301815291905280516020909101206007805491925067ffffffffffffffff9091169060006124b883615dc6565b91906101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055505060008067ffffffffffffffff8111156124fa576124fa615e5a565b604051908082528060200260200182016040528015612523578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182167fffffffffffffffff00000000000000000000000000000000000000000000000090941693909317600160601b91909216021777ffffffffffffffffffffffffffffffffffffffffffffffff16600160c01b67ffffffffffffffff9092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b03928316178355925160018301805490941691161790915592518051949550909361262e9260028501920190615089565b50506040513381528391507f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600a54600160301b900460ff16156126975760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b031633146126db576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612715576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006127238284018461550b565b6000818152600560205260409020549091506001600160a01b031661275b57604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b0316918691906127828385615ce7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600760088282829054906101000a90046001600160601b03166127ca9190615ce7565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a82878461281d9190615ca3565b604080519283526020830191909152015b60405180910390a2505050505050565b6128466136e2565b6007544790600160a01b90046001600160601b031681811115612886576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611afd57600061289a8284615d3c565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d80600081146128e9576040519150601f19603f3d011682016040523d82523d6000602084013e6128ee565b606091505b505090508061291057604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6129616136e2565b6000818152600560205260409020546001600160a01b031661299657604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0a9082906001600160a01b031661373e565b6129c16136e2565b60c861ffff871611156129fb5760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c01565b60008213612a1f576040516321ea67b360e11b815260048101839052602401610c01565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600a805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff00000000000000000000001916176b01000000000000000000000083021790558a51600f80548d87015192891667ffffffffffffffff1990911617640100000000928916929092029190911790819055600e8d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600a54600160301b900460ff1615612b805760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612bb557604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612c2757600081815260056020526040908190206001015490517fd084e9750000000000000000000000000000000000000000000000000000000081526001600160a01b039091166004820152602401610c01565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612cdc57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612d1057604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612d3b5760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612d87576040517f05a48e0f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff1615612dbf57610e69565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612e6d9190615931565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612ec257604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612ef657604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff1615612f215760405163769dd35360e11b815260040160405180910390fd5b612f2a84611783565b15612f4857604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b038316600090815260046020908152604080832087845290915290205467ffffffffffffffff16612fa5576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c01565b60008481526005602090815260408083206002018054825181850281018501909352808352919290919083018282801561300857602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612fea575b5050505050905060006001825161301f9190615d3c565b905060005b825181101561312b57856001600160a01b031683828151811061304957613049615e44565b60200260200101516001600160a01b0316141561311957600083838151811061307457613074615e44565b6020026020010151905080600560008a815260200190815260200160002060020183815481106130a6576130a6615e44565b600091825260208083209190910180546001600160a01b0319166001600160a01b0394909416939093179092558981526005909152604090206002018054806130f1576130f1615e2e565b600082815260209020810160001990810180546001600160a01b03191690550190555061312b565b8061312381615dab565b915050613024565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a7910161282e565b600c818154811061319e57600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b0316806131e757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461321b57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c01565b600a54600160301b900460ff16156132465760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e695760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612e4c565b6000818152600560205260408120548190819081906060906001600160a01b031661330c57604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b90910467ffffffffffffffff16946001600160a01b03909416939183918301828280156133b057602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613392575b505050505090509450945094509450945091939590929450565b6133d26136e2565b6002546040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561342f57600080fd5b505afa158015613443573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134679190615524565b6007549091506801000000000000000090046001600160601b0316818111156134ad576040516354ced18160e11b81526004810182905260248101839052604401610c01565b81811015611afd5760006134c18284615d3c565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561351157600080fd5b505af1158015613525573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061354991906154ee565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600a54600160301b900460ff16156135bd5760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b03166135f257604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c6136218385615ce7565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600760148282829054906101000a90046001600160601b03166136699190615ce7565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846136bc9190615ca3565b60408051928352602083019190915201612c98565b6136d96136e2565b610c0a816140ee565b6000546001600160a01b0316331461373c5760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c01565b565b60008061374a84613cd0565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156137a757600080fd5b505af11580156137bb573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906137df91906154ee565b6137fc57604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114613852576040519150601f19603f3d011682016040523d82523d6000602084013e613857565b606091505b505090508061387957604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b604080516060810182526000808252602082018190529181019190915260006139018460000151612e5a565b6000818152600b60205260409020549091506001600160a01b03168061393d57604051631dfd6e1360e21b815260048101839052602401610c01565b600082866080015160405160200161395f929190918252602082015260400190565b60408051601f1981840301815291815281516020928301206000818152600d909352912054909150806139be576040517f3688124a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b85516020808801516040808a015160608b015160808c015160a08d015193516139ed978a979096959101615b11565b604051602081830303815290604052805190602001208114613a3b576040517fd529142c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a4a8760000151614198565b905080613b565786516040517fe9413d3800000000000000000000000000000000000000000000000000000000815267ffffffffffffffff90911660048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063e9413d389060240160206040518083038186803b158015613ad657600080fd5b505afa158015613aea573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b0e9190615524565b905080613b565786516040517f175dadad00000000000000000000000000000000000000000000000000000000815267ffffffffffffffff9091166004820152602401610c01565b6000886080015182604051602001613b78929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c90506000613b9f8a8361429f565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613bda57600080fd5b611388810390508460408204820311613bf257600080fd5b50823b613bfe57600080fd5b60008083516020850160008789f190505b9392505050565b60008115613c4457600f54613c3d9086908690640100000000900463ffffffff168661430a565b9050613c5e565b600f54613c5b908690869063ffffffff1686614374565b90505b949350505050565b6000805b601054811015613cc757826001600160a01b031660108281548110613c9157613c91615e44565b6000918252602090912001546001600160a01b03161415613cb55750600192915050565b80613cbf81615dab565b915050613c6a565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613d5c57602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613d3e575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b90910467ffffffffffffffff16928201929092529096509094509192505b826040015151811015613e3a576004600084604001518381518110613de957613de9615e44565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613e3281615dab565b915050613dc2565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590613e7260028301826150ee565b505060008581526006602052604081205560078054859190600890613ead9084906801000000000000000090046001600160601b0316615d53565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600760148282829054906101000a90046001600160601b0316613ef59190615d53565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60408051602081019091526000815281613f49575060408051602081019091526000815261139d565b7f92fd133800000000000000000000000000000000000000000000000000000000613f748385615d7b565b6001600160e01b03191614613fb5576040517f5247fdce00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b613fc28260048186615c79565b810190613c0f919061553d565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa8260405160240161400891511515815260200190565b60408051601f198184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff166001600160e01b03199093169290921790915292915050565b60004661a4b181148061406a575062066eed81145b156140e75760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140a957600080fd5b505afa1580156140bd573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906140e19190615524565b91505090565b4391505090565b6001600160a01b0381163314156141475760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c01565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b18114806141ad575062066eed81145b1561428f576101008367ffffffffffffffff166141c8614055565b6141d29190615d3c565b11806141ef57506141e1614055565b8367ffffffffffffffff1610155b156141fd5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815267ffffffffffffffff84166004820152606490632b407a829060240160206040518083038186803b15801561425757600080fd5b505afa15801561426b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c0f9190615524565b505067ffffffffffffffff164090565b60006142d38360000151846020015185604001518660600151868860a001518960c001518a60e001518b610100015161447b565b600383602001516040516020016142eb929190615a26565b60408051601f1981840301815291905280516020909101209392505050565b6000806143156146b6565b905060005a6143248888615ca3565b61432e9190615d3c565b6143389085615d1d565b9050600061435163ffffffff871664e8d4a51000615d1d565b90508261435e8284615ca3565b6143689190615ca3565b98975050505050505050565b60008061437f614712565b9050600081136143a5576040516321ea67b360e11b815260048101829052602401610c01565b60006143af6146b6565b9050600082825a6143c08b8b615ca3565b6143ca9190615d3c565b6143d49088615d1d565b6143de9190615ca3565b6143f090670de0b6b3a7640000615d1d565b6143fa9190615d09565b9050600061441363ffffffff881664e8d4a51000615d1d565b905061442b816b033b2e3c9fd0803ce8000000615d3c565b821115614464576040517fe80fa38100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61446e8183615ca3565b9998505050505050505050565b614484896147fa565b6144d05760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c01565b6144d9886147fa565b6145255760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c01565b61452e836147fa565b61457a5760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c01565b614583826147fa565b6145cf5760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c01565b6145db878a88876148d3565b6146275760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c01565b60006146338a87614a08565b90506000614646898b878b868989614a6c565b90506000614657838d8d8a86614b8c565b9050808a146146a85760405162461bcd60e51b815260206004820152600d60248201527f696e76616c69642070726f6f66000000000000000000000000000000000000006044820152606401610c01565b505050505050505050505050565b60004661a4b18114806146cb575062066eed81145b1561470a57606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b1580156140a957600080fd5b600091505090565b600a54600354604080517ffeaf968c0000000000000000000000000000000000000000000000000000000081529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b15801561478d57600080fd5b505afa1580156147a1573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906147c5919061579b565b5094509092508491505080156147e957506147e08242615d3c565b8463ffffffff16105b15613c5e5750600e54949350505050565b80516000906401000003d019116148535760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d019116148ac5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c01565b60208201516401000003d0199080096148cc8360005b6020020151614bcc565b1492915050565b60006001600160a01b03821661492b5760405162461bcd60e51b815260206004820152600b60248201527f626164207769746e6573730000000000000000000000000000000000000000006044820152606401610c01565b60208401516000906001161561494257601c614945565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa1580156149e0573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b614a1061510c565b614a3d60018484604051602001614a2993929190615910565b604051602081830303815290604052614bf0565b90505b614a49816147fa565b61139d578051604080516020810192909252614a659101614a29565b9050614a40565b614a7461510c565b825186516401000003d0199081900691061415614ad35760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c01565b614ade878988614c3e565b614b2a5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c01565b614b35848685614c3e565b614b815760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c01565b614368868484614d78565b600060028686868587604051602001614baa969594939291906158b1565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614bf861510c565b614c0182614e3f565b8152614c16614c118260006148c2565b614e7a565b6020820181905260029006600114156123df576020810180516401000003d019039052919050565b600082614c8d5760405162461bcd60e51b815260206004820152600b60248201527f7a65726f207363616c61720000000000000000000000000000000000000000006044820152606401610c01565b83516020850151600090614ca390600290615dee565b15614caf57601c614cb2565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614d24573d6000803e3d6000fd5b505050602060405103519050600086604051602001614d43919061589f565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614d8061510c565b835160208086015185519186015160009384938493614da193909190614e9a565b919450925090506401000003d019858209600114614e015760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c01565b60405180604001604052806401000003d01980614e2057614e20615e18565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106123df57604080516020808201939093528151808203840181529082019091528051910120614e47565b600061139d826002614e936401000003d0196001615ca3565b901c614f7a565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614eda8383858561501c565b9098509050614eeb88828e88615040565b9098509050614efc88828c87615040565b90985090506000614f0f8d878b85615040565b9098509050614f208882868661501c565b9098509050614f3188828e89615040565b9098509050818114614f66576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614f6a565b8196505b5050505050509450945094915050565b600080614f8561512a565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a0820152614fb7615148565b60208160c0846005600019fa9250826150125760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c01565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b8280548282559060005260206000209081019282156150de579160200282015b828111156150de57825182546001600160a01b0319166001600160a01b039091161782556020909201916001909101906150a9565b506150ea929150615166565b5090565b5080546000825590600052602060002090810190610c0a9190615166565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b808211156150ea5760008155600101615167565b80356123df81615e70565b806040810183101561139d57600080fd5b600082601f8301126151a857600080fd5b6151b0615c09565b8083856040860111156151c257600080fd5b60005b60028110156151e45781358452602093840193909101906001016151c5565b509095945050505050565b600082601f83011261520057600080fd5b813567ffffffffffffffff8082111561521b5761521b615e5a565b604051601f8301601f19908116603f0116810190828211818310171561524357615243615e5a565b8160405283815286602085880101111561525c57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600060c0828403121561528e57600080fd5b615296615c32565b9050813567ffffffffffffffff80821682146152b157600080fd5b818352602084013560208401526152ca60408501615330565b60408401526152db60608501615330565b60608401526152ec6080850161517b565b608084015260a084013591508082111561530557600080fd5b50615312848285016151ef565b60a08301525092915050565b803561ffff811681146123df57600080fd5b803563ffffffff811681146123df57600080fd5b805169ffffffffffffffffffff811681146123df57600080fd5b80356001600160601b03811681146123df57600080fd5b60006020828403121561538757600080fd5b8135613c0f81615e70565b600080604083850312156153a557600080fd5b82356153b081615e70565b91506153be6020840161535e565b90509250929050565b600080604083850312156153da57600080fd5b82356153e581615e70565b915060208301356153f581615e70565b809150509250929050565b6000806060838503121561541357600080fd5b823561541e81615e70565b91506153be8460208501615186565b6000806000806060858703121561544357600080fd5b843561544e81615e70565b935060208501359250604085013567ffffffffffffffff8082111561547257600080fd5b818701915087601f83011261548657600080fd5b81358181111561549557600080fd5b8860208285010111156154a757600080fd5b95989497505060200194505050565b6000604082840312156154c857600080fd5b613c0f8383615186565b6000604082840312156154e457600080fd5b613c0f8383615197565b60006020828403121561550057600080fd5b8151613c0f81615e85565b60006020828403121561551d57600080fd5b5035919050565b60006020828403121561553657600080fd5b5051919050565b60006020828403121561554f57600080fd5b6040516020810181811067ffffffffffffffff8211171561557257615572615e5a565b604052823561558081615e85565b81529392505050565b6000808284036101c081121561559e57600080fd5b6101a0808212156155ae57600080fd5b6155b6615c55565b91506155c28686615197565b82526155d18660408701615197565b60208301526080850135604083015260a0850135606083015260c0850135608083015261560060e0860161517b565b60a083015261010061561487828801615197565b60c0840152615627876101408801615197565b60e08401526101808601359083015290925083013567ffffffffffffffff81111561565157600080fd5b61565d8582860161527c565b9150509250929050565b60006020828403121561567957600080fd5b813567ffffffffffffffff81111561569057600080fd5b820160c08185031215613c0f57600080fd5b6000602082840312156156b457600080fd5b613c0f8261531e565b60008060008060008086880360e08112156156d757600080fd5b6156e08861531e565b96506156ee60208901615330565b95506156fc60408901615330565b945061570a60608901615330565b9350608088013592506040609f198201121561572557600080fd5b5061572e615c09565b61573a60a08901615330565b815261574860c08901615330565b6020820152809150509295509295509295565b6000806040838503121561576e57600080fd5b8235915060208301356153f581615e70565b60006020828403121561579257600080fd5b613c0f82615330565b600080600080600060a086880312156157b357600080fd5b6157bc86615344565b94506020860151935060408601519250606086015191506157df60808701615344565b90509295509295909350565b600081518084526020808501945080840160005b838110156158245781516001600160a01b0316875295820195908201906001016157ff565b509495945050505050565b8060005b6002811015610e69578151845260209384019390910190600101615833565b6000815180845260005b818110156158785760208185018101518683018201520161585c565b8181111561588a576000602083870101525b50601f01601f19169290920160200192915050565b6158a9818361582f565b604001919050565b8681526158c1602082018761582f565b6158ce606082018661582f565b6158db60a082018561582f565b6158e860e082018461582f565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b838152615920602082018461582f565b606081019190915260800192915050565b6040810161139d828461582f565b602081526000613c0f6020830184615852565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261599860e08401826157eb565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615a18578451835293830193918301916001016159fc565b509098975050505050505050565b82815260608101613c0f602083018461582f565b6000604082018483526020604081850152818551808452606086019150828701935060005b81811015615a7b57845183529383019391830191600101615a5f565b5090979650505050505050565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a083015261436860c0830184615852565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261446e60e0830184615852565b87815267ffffffffffffffff87166020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c083015261446e60e0830184615852565b60006001600160601b03808816835280871660208401525067ffffffffffffffff851660408301526001600160a01b038416606083015260a06080830152615bb060a08301846157eb565b979650505050505050565b6000808335601e19843603018112615bd257600080fd5b83018035915067ffffffffffffffff821115615bed57600080fd5b602001915036819003821315615c0257600080fd5b9250929050565b6040805190810167ffffffffffffffff81118282101715615c2c57615c2c615e5a565b60405290565b60405160c0810167ffffffffffffffff81118282101715615c2c57615c2c615e5a565b604051610120810167ffffffffffffffff81118282101715615c2c57615c2c615e5a565b60008085851115615c8957600080fd5b83861115615c9657600080fd5b5050820193919092039150565b60008219821115615cb657615cb6615e02565b500190565b600067ffffffffffffffff808316818516808303821115615cde57615cde615e02565b01949350505050565b60006001600160601b03808316818516808303821115615cde57615cde615e02565b600082615d1857615d18615e18565b500490565b6000816000190483118215151615615d3757615d37615e02565b500290565b600082821015615d4e57615d4e615e02565b500390565b60006001600160601b0383811690831681811015615d7357615d73615e02565b039392505050565b6001600160e01b03198135818116916004851015615da35780818660040360031b1b83161692505b505092915050565b6000600019821415615dbf57615dbf615e02565b5060010190565b600067ffffffffffffffff80831681811415615de457615de4615e02565b6001019392505050565b600082615dfd57615dfd615e18565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0a57600080fd5b8015158114610c0a57600080fdfea164736f6c6343000806000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"blockhashStore\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"internalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"externalBalance\",\"type\":\"uint256\"}],\"name\":\"BalanceInvariantViolated\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"blockNum\",\"type\":\"uint256\"}],\"name\":\"BlockhashNotInStore\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorNotRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"FailedToSendEther\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectCommitment\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"have\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"want\",\"type\":\"uint256\"}],\"name\":\"InsufficientGasForConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidExtraArgsTag\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"int256\",\"name\":\"linkWei\",\"type\":\"int256\"}],\"name\":\"InvalidLinkWeiPrice\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"have\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"min\",\"type\":\"uint16\"},{\"internalType\":\"uint16\",\"name\":\"max\",\"type\":\"uint16\"}],\"name\":\"InvalidRequestConfirmations\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"LinkAlreadySet\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeRequestedOwner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"MustBeSubOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoCorrespondingRequest\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"NoSuchProvingKey\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"have\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"want\",\"type\":\"uint32\"}],\"name\":\"NumWordsTooBig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentTooLarge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PendingRequestExists\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"}],\"name\":\"ProvingKeyAlreadyRegistered\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Reentrant\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"indexed\":false,\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinatorAddress\",\"type\":\"address\"}],\"name\":\"CoordinatorRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"EthFundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"MigrationCompleted\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyDeregistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"}],\"name\":\"ProvingKeyRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"outputSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subID\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"RandomWordsFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"requestId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"preSeed\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"RandomWordsRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountLink\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amountEth\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldEthBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newEthBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFundedWithEth\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"BLOCKHASH_STORE\",\"outputs\":[{\"internalType\":\"contractBlockhashStoreInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK\",\"outputs\":[{\"internalType\":\"contractLinkTokenInterface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"LINK_ETH_FEED\",\"outputs\":[{\"internalType\":\"contractAggregatorV3Interface\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_CONSUMERS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_NUM_WORDS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"MAX_REQUEST_CONFIRMATIONS\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"deregisterMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"deregisterProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256[2]\",\"name\":\"pk\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"gamma\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"c\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"s\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"seed\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"uWitness\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"cGammaWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256[2]\",\"name\":\"sHashWitness\",\"type\":\"uint256[2]\"},{\"internalType\":\"uint256\",\"name\":\"zInv\",\"type\":\"uint256\"}],\"internalType\":\"structVRF.Proof\",\"name\":\"proof\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint64\",\"name\":\"blockNum\",\"type\":\"uint64\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFCoordinatorV2Plus.RequestCommitment\",\"name\":\"rc\",\"type\":\"tuple\"}],\"name\":\"fulfillRandomWords\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"fundSubscriptionWithEth\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveSubscriptionIds\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRequestConfig\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"getSubscription\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"ethBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint64\",\"name\":\"reqCount\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[2]\",\"name\":\"publicKey\",\"type\":\"uint256[2]\"}],\"name\":\"hashOfKey\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newCoordinator\",\"type\":\"address\"}],\"name\":\"migrate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"migrationVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"version\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdrawEth\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"addresspayable\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverEthFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"}],\"name\":\"registerMigratableCoordinator\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"oracle\",\"type\":\"address\"},{\"internalType\":\"uint256[2]\",\"name\":\"publicProvingKey\",\"type\":\"uint256[2]\"}],\"name\":\"registerProvingKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"keyHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"uint16\",\"name\":\"requestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"numWords\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"extraArgs\",\"type\":\"bytes\"}],\"internalType\":\"structVRFV2PlusClient.RandomWordsRequest\",\"name\":\"req\",\"type\":\"tuple\"}],\"name\":\"requestRandomWords\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"subId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"requestSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_config\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"reentrancyLock\",\"type\":\"bool\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_currentSubNonce\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_fallbackWeiPerUnitLink\",\"outputs\":[{\"internalType\":\"int256\",\"name\":\"\",\"type\":\"int256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_provingKeyHashes\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_provingKeys\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_requestCommitments\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_totalEthBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"minimumRequestConfirmations\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"maxGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"stalenessSeconds\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"gasAfterPaymentCalculation\",\"type\":\"uint32\"},{\"internalType\":\"int256\",\"name\":\"fallbackWeiPerUnitLink\",\"type\":\"int256\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeLinkPPM\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"fulfillmentFlatFeeEthPPM\",\"type\":\"uint32\"}],\"internalType\":\"structVRFCoordinatorV2Plus.FeeConfig\",\"name\":\"feeConfig\",\"type\":\"tuple\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkEthFeed\",\"type\":\"address\"}],\"name\":\"setLINKAndLINKETHFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b506040516200604038038062006040833981016040819052620000349162000183565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000d7565b50505060601b6001600160601b031916608052620001b5565b6001600160a01b038116331415620001325760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019657600080fd5b81516001600160a01b0381168114620001ae57600080fd5b9392505050565b60805160601c615e65620001db600039600081816105ee015261397a0152615e656000f3fe6080604052600436106102dc5760003560e01c80638da5cb5b1161017f578063bec4c08c116100e1578063dc311dd31161008a578063e95704bd11610064578063e95704bd1461095d578063ee9d2d3814610984578063f2fde38b146109b157600080fd5b8063dc311dd3146108f9578063e72f6e301461092a578063e8509bff1461094a57600080fd5b8063d98e620e116100bb578063d98e620e14610883578063da2f2610146108a3578063dac83d29146108d957600080fd5b8063bec4c08c14610823578063caf70c4a14610843578063cb6317971461086357600080fd5b8063a8cb447b11610143578063aefb212f1161011d578063aefb212f146107b6578063b08c8795146107e3578063b2a7cac51461080357600080fd5b8063a8cb447b14610756578063aa433aff14610776578063ad1783611461079657600080fd5b80638da5cb5b146106ab5780639b1c385e146106c95780639d40a6fd146106e9578063a21a23e414610721578063a4c0ed361461073657600080fd5b806340d6bb821161024357806366316d8d116101ec5780636f64f03f116101c65780636f64f03f1461065657806379ba50971461067657806386fe91c71461068b57600080fd5b806366316d8d146105bc578063689c4517146105dc5780636b6feccc1461061057600080fd5b806357133e641161021d57806357133e64146105675780635d06b4ab1461058757806364d51a2a146105a757600080fd5b806340d6bb82146104ec57806341af6c871461051757806346d8d4861461054757600080fd5b80630ae09540116102a5578063294daa491161027f578063294daa4914610478578063330987b314610494578063405b84fa146104cc57600080fd5b80630ae09540146103f857806315c48b84146104185780631b6b6d231461044057600080fd5b8062012291146102e157806304104edb1461030e578063043bd6ae14610330578063088070f51461035457806308821d58146103d8575b600080fd5b3480156102ed57600080fd5b506102f66109d1565b604051610305939291906159c9565b60405180910390f35b34801561031a57600080fd5b5061032e610329366004615316565b610a4d565b005b34801561033c57600080fd5b5061034660115481565b604051908152602001610305565b34801561036057600080fd5b50600d546103a09061ffff81169063ffffffff62010000820481169160ff600160301b820416916701000000000000008204811691600160581b90041685565b6040805161ffff909616865263ffffffff9485166020870152921515928501929092528216606084015216608082015260a001610305565b3480156103e457600080fd5b5061032e6103f3366004615456565b610c0f565b34801561040457600080fd5b5061032e6104133660046156f8565b610da3565b34801561042457600080fd5b5061042d60c881565b60405161ffff9091168152602001610305565b34801561044c57600080fd5b50600254610460906001600160a01b031681565b6040516001600160a01b039091168152602001610305565b34801561048457600080fd5b5060405160018152602001610305565b3480156104a057600080fd5b506104b46104af366004615528565b610e71565b6040516001600160601b039091168152602001610305565b3480156104d857600080fd5b5061032e6104e73660046156f8565b61135b565b3480156104f857600080fd5b506105026101f481565b60405163ffffffff9091168152602001610305565b34801561052357600080fd5b506105376105323660046154ab565b611709565b6040519015158152602001610305565b34801561055357600080fd5b5061032e610562366004615333565b61190a565b34801561057357600080fd5b5061032e610582366004615368565b611a87565b34801561059357600080fd5b5061032e6105a2366004615316565b611ae7565b3480156105b357600080fd5b5061042d606481565b3480156105c857600080fd5b5061032e6105d7366004615333565b611ba5565b3480156105e857600080fd5b506104607f000000000000000000000000000000000000000000000000000000000000000081565b34801561061c57600080fd5b506012546106399063ffffffff8082169164010000000090041682565b6040805163ffffffff938416815292909116602083015201610305565b34801561066257600080fd5b5061032e6106713660046153a1565b611d44565b34801561068257600080fd5b5061032e611e43565b34801561069757600080fd5b50600a546104b4906001600160601b031681565b3480156106b757600080fd5b506000546001600160a01b0316610460565b3480156106d557600080fd5b506103466106e4366004615605565b611ef4565b3480156106f557600080fd5b50600754610709906001600160401b031681565b6040516001600160401b039091168152602001610305565b34801561072d57600080fd5b506103466122e9565b34801561074257600080fd5b5061032e6107513660046153ce565b612539565b34801561076257600080fd5b5061032e610771366004615316565b6126d9565b34801561078257600080fd5b5061032e6107913660046154ab565b6127f4565b3480156107a257600080fd5b50600354610460906001600160a01b031681565b3480156107c257600080fd5b506107d66107d136600461571d565b612854565b604051610305919061592e565b3480156107ef57600080fd5b5061032e6107fe36600461565a565b612955565b34801561080f57600080fd5b5061032e61081e3660046154ab565b612ae9565b34801561082f57600080fd5b5061032e61083e3660046156f8565b612c1f565b34801561084f57600080fd5b5061034661085e366004615472565b612dbb565b34801561086f57600080fd5b5061032e61087e3660046156f8565b612deb565b34801561088f57600080fd5b5061034661089e3660046154ab565b6130ee565b3480156108af57600080fd5b506104606108be3660046154ab565b600e602052600090815260409020546001600160a01b031681565b3480156108e557600080fd5b5061032e6108f43660046156f8565b61310f565b34801561090557600080fd5b506109196109143660046154ab565b61322e565b604051610305959493929190615b31565b34801561093657600080fd5b5061032e610945366004615316565b613329565b61032e6109583660046154ab565b6134cc565b34801561096957600080fd5b50600a546104b490600160601b90046001600160601b031681565b34801561099057600080fd5b5061034661099f3660046154ab565b60106020526000908152604090205481565b3480156109bd57600080fd5b5061032e6109cc366004615316565b61360b565b600d54600f805460408051602080840282018101909252828152600094859460609461ffff8316946201000090930463ffffffff16939192839190830182828015610a3b57602002820191906000526020600020905b815481526020019060010190808311610a27575b50505050509050925092509250909192565b610a5561361c565b60135460005b81811015610be257826001600160a01b031660138281548110610a8057610a80615e09565b6000918252602090912001546001600160a01b03161415610bd0576013610aa8600184615d02565b81548110610ab857610ab8615e09565b600091825260209091200154601380546001600160a01b039092169183908110610ae457610ae4615e09565b600091825260209091200180546001600160a01b0319166001600160a01b0392909216919091179055826013610b1b600185615d02565b81548110610b2b57610b2b615e09565b9060005260206000200160006101000a8154816001600160a01b0302191690836001600160a01b031602179055506013805480610b6a57610b6a615df3565b6000828152602090819020600019908301810180546001600160a01b03191690559091019091556040516001600160a01b03851681527ff80a1a97fd42251f3c33cda98635e7399253033a6774fe37cd3f650b5282af37910160405180910390a1505050565b80610bda81615d71565b915050610a5b565b50604051635428d44960e01b81526001600160a01b03831660048201526024015b60405180910390fd5b50565b610c1761361c565b604080518082018252600091610c46919084906002908390839080828437600092019190915250612dbb915050565b6000818152600e60205260409020549091506001600160a01b031680610c8257604051631dfd6e1360e21b815260048101839052602401610c03565b6000828152600e6020526040812080546001600160a01b03191690555b600f54811015610d5a5782600f8281548110610cbd57610cbd615e09565b90600052602060002001541415610d4857600f805460009190610ce290600190615d02565b81548110610cf257610cf2615e09565b9060005260206000200154905080600f8381548110610d1357610d13615e09565b600091825260209091200155600f805480610d3057610d30615df3565b60019003818190600052602060002001600090559055505b80610d5281615d71565b915050610c9f565b50806001600160a01b03167f72be339577868f868798bac2c93e52d6f034fef4689a9848996c14ebb7416c0d83604051610d9691815260200190565b60405180910390a2505050565b60008281526005602052604090205482906001600160a01b031680610ddb57604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614610e0f57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c03565b600d54600160301b900460ff1615610e3a5760405163769dd35360e11b815260040160405180910390fd5b610e4384611709565b15610e6157604051631685ecdd60e31b815260040160405180910390fd5b610e6b8484613678565b50505050565b600d54600090600160301b900460ff1615610e9f5760405163769dd35360e11b815260040160405180910390fd5b60005a90506000610eb0858561380f565b90506000846060015163ffffffff166001600160401b03811115610ed657610ed6615e1f565b604051908082528060200260200182016040528015610eff578160200160208202803683370190505b50905060005b856060015163ffffffff16811015610f7f57826040015181604051602001610f37929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c828281518110610f6257610f62615e09565b602090810291909101015280610f7781615d71565b915050610f05565b5060208083018051600090815260109092526040808320839055905190518291631fe543e360e01b91610fb791908690602401615a3c565b60408051601f198184030181529181526020820180516001600160e01b03166001600160e01b031990941693909317909252600d805466ff0000000000001916600160301b17905590880151608089015191925060009161101f9163ffffffff169084613a9c565b600d805466ff00000000000019169055602089810151600090815260069091526040902054909150600160c01b90046001600160401b0316611062816001615c82565b6020808b0151600090815260069091526040812080546001600160401b0393909316600160c01b026001600160c01b039093169290921790915560a08a015180516110af90600190615d02565b815181106110bf576110bf615e09565b602091010151600d5460f89190911c60011491506000906110f0908a90600160581b900463ffffffff163a85613aea565b905081156111f9576020808c01516000908152600690915260409020546001600160601b03808316600160601b90920416101561114057604051631e9acf1760e31b815260040160405180910390fd5b60208b81015160009081526006909152604090208054829190600c90611177908490600160601b90046001600160601b0316615d19565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600e60209081526040808320546001600160a01b03168352600c9091528120805485945090926111d091859116615cad565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506112e5565b6020808c01516000908152600690915260409020546001600160601b038083169116101561123a57604051631e9acf1760e31b815260040160405180910390fd5b6020808c0151600090815260069091526040812080548392906112679084906001600160601b0316615d19565b82546101009290920a6001600160601b0381810219909316918316021790915589516000908152600e60209081526040808320546001600160a01b03168352600b9091528120805485945090926112c091859116615cad565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505b8a6020015188602001517f49580fdfd9497e1ed5c1b1cec0495087ae8e3f1267470ec2fb015db32e3d6aa78a604001518488604051611342939291909283526001600160601b039190911660208301521515604082015260600190565b60405180910390a3985050505050505050505b92915050565b61136481613b3a565b61138c57604051635428d44960e01b81526001600160a01b0382166004820152602401610c03565b60008060008061139b8661322e565b945094505093509350336001600160a01b0316826001600160a01b0316146114055760405162461bcd60e51b815260206004820152601660248201527f4e6f7420737562736372697074696f6e206f776e6572000000000000000000006044820152606401610c03565b61140e86611709565b1561145b5760405162461bcd60e51b815260206004820152601660248201527f50656e64696e67207265717565737420657869737473000000000000000000006044820152606401610c03565b60006040518060c00160405280611470600190565b60ff168152602001888152602001846001600160a01b03168152602001838152602001866001600160601b03168152602001856001600160601b031681525090506000816040516020016114c49190615954565b60405160208183030381529060405290506114de88613ba4565b505060405163ce3f471960e01b81526001600160a01b0388169063ce3f4719906001600160601b03881690611517908590600401615941565b6000604051808303818588803b15801561153057600080fd5b505af1158015611544573d6000803e3d6000fd5b505060025460405163a9059cbb60e01b81526001600160a01b038c811660048301526001600160601b038c166024830152909116935063a9059cbb92506044019050602060405180830381600087803b1580156115a057600080fd5b505af11580156115b4573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906115d8919061548e565b6116245760405162461bcd60e51b815260206004820152601260248201527f696e73756666696369656e742066756e647300000000000000000000000000006044820152606401610c03565b60005b83518110156116bc5783818151811061164257611642615e09565b6020908102919091010151604051638ea9811760e01b81526001600160a01b038a8116600483015290911690638ea9811790602401600060405180830381600087803b15801561169157600080fd5b505af11580156116a5573d6000803e3d6000fd5b5050505080806116b490615d71565b915050611627565b50604080516001600160a01b0389168152602081018a90527fd63ca8cb945956747ee69bfdc3ea754c24a4caf7418db70e46052f7850be4187910160405180910390a15050505050505050565b6000818152600560209081526040808320815160608101835281546001600160a01b039081168252600183015416818501526002820180548451818702810187018652818152879693958601939092919083018282801561179357602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311611775575b505050505081525050905060005b8160400151518110156119005760005b600f548110156118ed5760006118b6600f83815481106117d3576117d3615e09565b9060005260206000200154856040015185815181106117f4576117f4615e09565b602002602001015188600460008960400151898151811061181757611817615e09565b6020908102919091018101516001600160a01b03908116835282820193909352604091820160009081208e82528252829020548251808301889052959093168583015260608501939093526001600160401b039091166080808501919091528151808503909101815260a08401825280519083012060c084019490945260e0808401859052815180850390910181526101009093019052815191012091565b50600081815260106020526040902054909150156118da5750600195945050505050565b50806118e581615d71565b9150506117b1565b50806118f881615d71565b9150506117a1565b5060009392505050565b600d54600160301b900460ff16156119355760405163769dd35360e11b815260040160405180910390fd5b336000908152600c60205260409020546001600160601b038083169116101561197157604051631e9acf1760e31b815260040160405180910390fd5b336000908152600c6020526040812080548392906119999084906001600160601b0316615d19565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600a600c8282829054906101000a90046001600160601b03166119e19190615d19565b92506101000a8154816001600160601b0302191690836001600160601b031602179055506000826001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d8060008114611a5b576040519150601f19603f3d011682016040523d82523d6000602084013e611a60565b606091505b5050905080611a8257604051630dcf35db60e41b815260040160405180910390fd5b505050565b611a8f61361c565b6002546001600160a01b031615611ab957604051631688c53760e11b815260040160405180910390fd5b600280546001600160a01b039384166001600160a01b03199182161790915560038054929093169116179055565b611aef61361c565b611af881613b3a565b15611b215760405163ac8a27ef60e01b81526001600160a01b0382166004820152602401610c03565b601380546001810182556000919091527f66de8ffda797e3de9c05e8fc57b3bf0ec28a930d40b0d285d93c06501cf6a0900180546001600160a01b0319166001600160a01b0383169081179091556040519081527fb7cabbfc11e66731fc77de0444614282023bcbd41d16781c753a431d0af016259060200160405180910390a150565b600d54600160301b900460ff1615611bd05760405163769dd35360e11b815260040160405180910390fd5b336000908152600b60205260409020546001600160601b0380831691161015611c0c57604051631e9acf1760e31b815260040160405180910390fd5b336000908152600b602052604081208054839290611c349084906001600160601b0316615d19565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555080600a60008282829054906101000a90046001600160601b0316611c7c9190615d19565b82546101009290920a6001600160601b0381810219909316918316021790915560025460405163a9059cbb60e01b81526001600160a01b03868116600483015292851660248201529116915063a9059cbb90604401602060405180830381600087803b158015611ceb57600080fd5b505af1158015611cff573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611d23919061548e565b611d4057604051631e9acf1760e31b815260040160405180910390fd5b5050565b611d4c61361c565b604080518082018252600091611d7b919084906002908390839080828437600092019190915250612dbb915050565b6000818152600e60205260409020549091506001600160a01b031615611db757604051634a0b8fa760e01b815260048101829052602401610c03565b6000818152600e6020908152604080832080546001600160a01b0319166001600160a01b038816908117909155600f805460018101825594527f8d1108e10bcb7c27dddfc02ed9d693a074039d026cf4ea4240b40f7d581ac802909301849055518381527fe729ae16526293f74ade739043022254f1489f616295a25bf72dfb4511ed73b89101610d96565b6001546001600160a01b03163314611e9d5760405162461bcd60e51b815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610c03565b60008054336001600160a01b0319808316821784556001805490911690556040516001600160a01b0390921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600d54600090600160301b900460ff1615611f225760405163769dd35360e11b815260040160405180910390fd5b6020808301356000908152600590915260409020546001600160a01b0316611f5d57604051630fb532db60e11b815260040160405180910390fd5b3360009081526004602090815260408083208583013584529091529020546001600160401b031680611fae576040516379bfd40160e01b815260208401356004820152336024820152604401610c03565b600d5461ffff16611fc5606085016040860161563f565b61ffff161080611fe8575060c8611fe2606085016040860161563f565b61ffff16115b1561202e57611ffd606084016040850161563f565b600d5460405163539c34bb60e11b815261ffff92831660048201529116602482015260c86044820152606401610c03565b600d5462010000900463ffffffff1661204d608085016060860161573f565b63ffffffff16111561209d57612069608084016060850161573f565b600d54604051637aebf00f60e11b815263ffffffff9283166004820152620100009091049091166024820152604401610c03565b6101f46120b060a085016080860161573f565b63ffffffff1611156120f6576120cc60a084016080850161573f565b6040516311ce1afb60e21b815263ffffffff90911660048201526101f46024820152604401610c03565b6000612103826001615c82565b604080518635602080830182905233838501528089013560608401526001600160401b0385166080808501919091528451808503909101815260a0808501865281519183019190912060c085019390935260e0808501849052855180860390910181526101009094019094528251920191909120929350906000906121939061218e90890189615b86565b613df3565b905060006121a082613e70565b9050836121ab613ee1565b60208a01356121c060808c0160608d0161573f565b6121d060a08d0160808e0161573f565b33866040516020016121e89796959493929190615a94565b604051602081830303815290604052805190602001206010600086815260200190815260200160002081905550336001600160a01b0316886020013589600001357feb0e3652e0f44f417695e6e90f2f42c99b65cd7169074c5a654b16b9748c3a4e87878d604001602081019061225f919061563f565b8e6060016020810190612272919061573f565b8f6080016020810190612285919061573f565b8960405161229896959493929190615a55565b60405180910390a450503360009081526004602090815260408083208983013584529091529020805467ffffffffffffffff19166001600160401b039490941693909317909255925050505b919050565b600d54600090600160301b900460ff16156123175760405163769dd35360e11b815260040160405180910390fd5b600033612325600143615d02565b600754604051606093841b6bffffffffffffffffffffffff199081166020830152924060348201523090931b909116605483015260c01b6001600160c01b031916606882015260700160408051601f198184030181529190528051602090910120600780549192506001600160401b039091169060006123a483615d8c565b91906101000a8154816001600160401b0302191690836001600160401b03160217905550506000806001600160401b038111156123e3576123e3615e1f565b60405190808252806020026020018201604052801561240c578160200160208202803683370190505b506040805160608082018352600080835260208084018281528486018381528984526006835286842095518654925191516001600160601b039182166001600160c01b031990941693909317600160601b9190921602176001600160c01b0316600160c01b6001600160401b039092169190910217909355835191820184523382528183018181528285018681528883526005855294909120825181546001600160a01b03199081166001600160a01b0392831617835592516001830180549094169116179091559251805194955090936124ed926002850192019061502c565b506124fd91506008905083613f7a565b5060405133815282907f1d3015d7ba850fa198dc7b1a3f5d42779313a681035f77c8c03764c61005518d9060200160405180910390a250905090565b600d54600160301b900460ff16156125645760405163769dd35360e11b815260040160405180910390fd5b6002546001600160a01b0316331461258f576040516344b0e3c360e01b815260040160405180910390fd5b602081146125b057604051638129bbcd60e01b815260040160405180910390fd5b60006125be828401846154ab565b6000818152600560205260409020549091506001600160a01b03166125f657604051630fb532db60e11b815260040160405180910390fd5b600081815260066020526040812080546001600160601b03169186919061261d8385615cad565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555084600a60008282829054906101000a90046001600160601b03166126659190615cad565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f1ced9348ff549fceab2ac57cd3a9de38edaaab274b725ee82c23e8fc8c4eec7a8287846126b89190615c6a565b604080519283526020830191909152015b60405180910390a2505050505050565b6126e161361c565b600a544790600160601b90046001600160601b031681811115612721576040516354ced18160e11b81526004810182905260248101839052604401610c03565b81811015611a825760006127358284615d02565b90506000846001600160a01b03168260405160006040518083038185875af1925050503d8060008114612784576040519150601f19603f3d011682016040523d82523d6000602084013e612789565b606091505b50509050806127ab57604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b0387168152602081018490527f879c9ea2b9d5345b84ccd12610b032602808517cebdb795007f3dcb4df377317910160405180910390a15050505050565b6127fc61361c565b6000818152600560205260409020546001600160a01b031661283157604051630fb532db60e11b815260040160405180910390fd5b600081815260056020526040902054610c0c9082906001600160a01b0316613678565b606060006128626008613f86565b905080841061288457604051631390f2a160e01b815260040160405180910390fd5b60006128908486615c6a565b90508181118061289e575083155b6128a857806128aa565b815b905060006128b88683615d02565b6001600160401b038111156128cf576128cf615e1f565b6040519080825280602002602001820160405280156128f8578160200160208202803683370190505b50905060005b815181101561294b5761291c6129148883615c6a565b600890613f90565b82828151811061292e5761292e615e09565b60209081029190910101528061294381615d71565b9150506128fe565b5095945050505050565b61295d61361c565b60c861ffff871611156129975760405163539c34bb60e11b815261ffff871660048201819052602482015260c86044820152606401610c03565b600082136129bb576040516321ea67b360e11b815260048101839052602401610c03565b6040805160a0808201835261ffff891680835263ffffffff89811660208086018290526000868801528a831660608088018290528b85166080988901819052600d805465ffffffffffff19168817620100008702176effffffffffffffffff000000000000191667010000000000000085026effffffff0000000000000000000000191617600160581b83021790558a51601280548d87015192891667ffffffffffffffff199091161764010000000092891692909202919091179081905560118d90558a519788528785019590955298860191909152840196909652938201879052838116928201929092529190921c90911660c08201527f777357bb93f63d088f18112d3dba38457aec633eb8f1341e1d418380ad328e789060e00160405180910390a1505050505050565b600d54600160301b900460ff1615612b145760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b0316612b4957604051630fb532db60e11b815260040160405180910390fd5b6000818152600560205260409020600101546001600160a01b03163314612ba2576000818152600560205260409081902060010154905163d084e97560e01b81526001600160a01b039091166004820152602401610c03565b6000818152600560209081526040918290208054336001600160a01b0319808316821784556001909301805490931690925583516001600160a01b0390911680825292810191909152909183917fd4114ab6e9af9f597c52041f32d62dc57c5c4e4c0d4427006069635e216c938691015b60405180910390a25050565b60008281526005602052604090205482906001600160a01b031680612c5757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612c8b57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c03565b600d54600160301b900460ff1615612cb65760405163769dd35360e11b815260040160405180910390fd5b60008481526005602052604090206002015460641415612ce9576040516305a48e0f60e01b815260040160405180910390fd5b6001600160a01b03831660009081526004602090815260408083208784529091529020546001600160401b031615612d2057610e6b565b6001600160a01b03831660008181526004602090815260408083208884528252808320805467ffffffffffffffff19166001908117909155600583528184206002018054918201815584529282902090920180546001600160a01b03191684179055905191825285917f1e980d04aa7648e205713e5e8ea3808672ac163d10936d36f91b2c88ac1575e191015b60405180910390a250505050565b600081604051602001612dce9190615920565b604051602081830303815290604052805190602001209050919050565b60008281526005602052604090205482906001600160a01b031680612e2357604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b03821614612e5757604051636c51fda960e11b81526001600160a01b0382166004820152602401610c03565b600d54600160301b900460ff1615612e825760405163769dd35360e11b815260040160405180910390fd5b612e8b84611709565b15612ea957604051631685ecdd60e31b815260040160405180910390fd5b6001600160a01b03831660009081526004602090815260408083208784529091529020546001600160401b0316612f05576040516379bfd40160e01b8152600481018590526001600160a01b0384166024820152604401610c03565b600084815260056020908152604080832060020180548251818502810185019093528083529192909190830182828015612f6857602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311612f4a575b50505050509050600060018251612f7f9190615d02565b905060005b825181101561308b57856001600160a01b0316838281518110612fa957612fa9615e09565b60200260200101516001600160a01b03161415613079576000838381518110612fd457612fd4615e09565b6020026020010151905080600560008a8152602001908152602001600020600201838154811061300657613006615e09565b600091825260208083209190910180546001600160a01b0319166001600160a01b03949094169390931790925589815260059091526040902060020180548061305157613051615df3565b600082815260209020810160001990810180546001600160a01b03191690550190555061308b565b8061308381615d71565b915050612f84565b506001600160a01b03851660008181526004602090815260408083208a8452825291829020805467ffffffffffffffff19169055905191825287917f32158c6058347c1601b2d12bc696ac6901d8a9a9aa3ba10c27ab0a983e8425a791016126c9565b600f81815481106130fe57600080fd5b600091825260209091200154905081565b60008281526005602052604090205482906001600160a01b03168061314757604051630fb532db60e11b815260040160405180910390fd5b336001600160a01b0382161461317b57604051636c51fda960e11b81526001600160a01b0382166004820152602401610c03565b600d54600160301b900460ff16156131a65760405163769dd35360e11b815260040160405180910390fd5b6000848152600560205260409020600101546001600160a01b03848116911614610e6b5760008481526005602090815260409182902060010180546001600160a01b0319166001600160a01b03871690811790915582513381529182015285917f21a4dad170a6bf476c31bbcf4a16628295b0e450672eec25d7c93308e05344a19101612dad565b6000818152600560205260408120548190819081906060906001600160a01b031661326c57604051630fb532db60e11b815260040160405180910390fd5b60008681526006602090815260408083205460058352928190208054600290910180548351818602810186019094528084526001600160601b0380871696600160601b810490911695600160c01b9091046001600160401b0316946001600160a01b039094169391839183018282801561330f57602002820191906000526020600020905b81546001600160a01b031681526001909101906020018083116132f1575b505050505090509450945094509450945091939590929450565b61333161361c565b6002546040516370a0823160e01b81523060048201526000916001600160a01b0316906370a082319060240160206040518083038186803b15801561337557600080fd5b505afa158015613389573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133ad91906154c4565b600a549091506001600160601b0316818111156133e7576040516354ced18160e11b81526004810182905260248101839052604401610c03565b81811015611a825760006133fb8284615d02565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526024820184905292935091169063a9059cbb90604401602060405180830381600087803b15801561344b57600080fd5b505af115801561345f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613483919061548e565b50604080516001600160a01b0386168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b600d54600160301b900460ff16156134f75760405163769dd35360e11b815260040160405180910390fd5b6000818152600560205260409020546001600160a01b031661352c57604051630fb532db60e11b815260040160405180910390fd5b60008181526006602052604090208054600160601b90046001600160601b0316903490600c61355b8385615cad565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555034600a600c8282829054906101000a90046001600160601b03166135a39190615cad565b92506101000a8154816001600160601b0302191690836001600160601b03160217905550817f3f1ddc3ab1bdb39001ad76ca51a0e6f57ce6627c69f251d1de41622847721cde8234846135f69190615c6a565b60408051928352602083019190915201612c13565b61361361361c565b610c0c81613f9c565b6000546001600160a01b031633146136765760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610c03565b565b60008061368484613ba4565b60025460405163a9059cbb60e01b81526001600160a01b0387811660048301526001600160601b0385166024830152939550919350919091169063a9059cbb90604401602060405180830381600087803b1580156136e157600080fd5b505af11580156136f5573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613719919061548e565b61373657604051631e9acf1760e31b815260040160405180910390fd5b6000836001600160a01b0316826001600160601b031660405160006040518083038185875af1925050503d806000811461378c576040519150601f19603f3d011682016040523d82523d6000602084013e613791565b606091505b50509050806137b357604051630dcf35db60e41b815260040160405180910390fd5b604080516001600160a01b03861681526001600160601b038581166020830152841681830152905186917f8c74ce8b8cf87f5eb001275c8be27eb34ea2b62bfab6814fcc62192bb63e81c4919081900360600190a25050505050565b6040805160608101825260008082526020820181905291810191909152600061383b8460000151612dbb565b6000818152600e60205260409020549091506001600160a01b03168061387757604051631dfd6e1360e21b815260048101839052602401610c03565b6000828660800151604051602001613899929190918252602082015260400190565b60408051601f19818403018152918152815160209283012060008181526010909352912054909150806138df57604051631b44092560e11b815260040160405180910390fd5b85516020808801516040808a015160608b015160808c015160a08d0151935161390e978a979096959101615ade565b6040516020818303038152906040528051906020012081146139435760405163354a450b60e21b815260040160405180910390fd5b60006139528760000151614046565b905080613a2a578651604051631d2827a760e31b81526001600160401b0390911660048201527f00000000000000000000000000000000000000000000000000000000000000006001600160a01b03169063e9413d389060240160206040518083038186803b1580156139c457600080fd5b505afa1580156139d8573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906139fc91906154c4565b905080613a2a57865160405163175dadad60e01b81526001600160401b039091166004820152602401610c03565b6000886080015182604051602001613a4c929190918252602082015260400190565b6040516020818303038152906040528051906020012060001c90506000613a738a83614130565b604080516060810182529889526020890196909652948701949094525093979650505050505050565b60005a611388811015613aae57600080fd5b611388810390508460408204820311613ac657600080fd5b50823b613ad257600080fd5b60008083516020850160008789f190505b9392505050565b60008115613b1857601254613b119086908690640100000000900463ffffffff168661419b565b9050613b32565b601254613b2f908690869063ffffffff1686614205565b90505b949350505050565b6000805b601354811015613b9b57826001600160a01b031660138281548110613b6557613b65615e09565b6000918252602090912001546001600160a01b03161415613b895750600192915050565b80613b9381615d71565b915050613b3e565b50600092915050565b6000818152600560209081526040808320815160608101835281546001600160a01b03908116825260018301541681850152600282018054845181870281018701865281815287968796949594860193919290830182828015613c3057602002820191906000526020600020905b81546001600160a01b03168152600190910190602001808311613c12575b505050919092525050506000858152600660209081526040808320815160608101835290546001600160601b03808216808452600160601b8304909116948301859052600160c01b9091046001600160401b0316928201929092529096509094509192505b826040015151811015613d0d576004600084604001518381518110613cbc57613cbc615e09565b6020908102919091018101516001600160a01b0316825281810192909252604090810160009081208982529092529020805467ffffffffffffffff1916905580613d0581615d71565b915050613c95565b50600085815260056020526040812080546001600160a01b03199081168255600182018054909116905590613d456002830182615091565b5050600085815260066020526040812055613d616008866142f3565b50600a8054859190600090613d809084906001600160601b0316615d19565b92506101000a8154816001600160601b0302191690836001600160601b0316021790555082600a600c8282829054906101000a90046001600160601b0316613dc89190615d19565b92506101000a8154816001600160601b0302191690836001600160601b031602179055505050915091565b60408051602081019091526000815281613e1c5750604080516020810190915260008152611355565b63125fa26760e31b613e2e8385615d41565b6001600160e01b03191614613e5657604051632923fee760e11b815260040160405180910390fd5b613e638260048186615c40565b810190613ae391906154dd565b60607f92fd13387c7fe7befbc38d303d6468778fb9731bc4583f17d92989c6fcfdeaaa82604051602401613ea991511515815260200190565b60408051601f198184030181529190526020810180516001600160e01b03166001600160e01b03199093169290921790915292915050565b60004661a4b1811480613ef6575062066eed81145b15613f735760646001600160a01b031663a3b1b31d6040518163ffffffff1660e01b815260040160206040518083038186803b158015613f3557600080fd5b505afa158015613f49573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f6d91906154c4565b91505090565b4391505090565b6000613ae383836142ff565b6000611355825490565b6000613ae3838361434e565b6001600160a01b038116331415613ff55760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610c03565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60004661a4b181148061405b575062066eed81145b1561412157610100836001600160401b0316614075613ee1565b61407f9190615d02565b118061409b575061408e613ee1565b836001600160401b031610155b156140a95750600092915050565b6040516315a03d4160e11b81526001600160401b0384166004820152606490632b407a829060240160206040518083038186803b1580156140e957600080fd5b505afa1580156140fd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ae391906154c4565b50506001600160401b03164090565b60006141648360000151846020015185604001518660600151868860a001518960c001518a60e001518b6101000151614378565b6003836020015160405160200161417c929190615a28565b60408051601f1981840301815291905280516020909101209392505050565b6000806141a66145a3565b905060005a6141b58888615c6a565b6141bf9190615d02565b6141c99085615ce3565b905060006141e263ffffffff871664e8d4a51000615ce3565b9050826141ef8284615c6a565b6141f99190615c6a565b98975050505050505050565b6000806142106145ff565b905060008113614236576040516321ea67b360e11b815260048101829052602401610c03565b60006142406145a3565b9050600082825a6142518b8b615c6a565b61425b9190615d02565b6142659088615ce3565b61426f9190615c6a565b61428190670de0b6b3a7640000615ce3565b61428b9190615ccf565b905060006142a463ffffffff881664e8d4a51000615ce3565b90506142bc816b033b2e3c9fd0803ce8000000615d02565b8211156142dc5760405163e80fa38160e01b815260040160405180910390fd5b6142e68183615c6a565b9998505050505050505050565b6000613ae383836146ce565b600081815260018301602052604081205461434657508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155611355565b506000611355565b600082600001828154811061436557614365615e09565b9060005260206000200154905092915050565b614381896147c1565b6143cd5760405162461bcd60e51b815260206004820152601a60248201527f7075626c6963206b6579206973206e6f74206f6e2063757276650000000000006044820152606401610c03565b6143d6886147c1565b6144225760405162461bcd60e51b815260206004820152601560248201527f67616d6d61206973206e6f74206f6e20637572766500000000000000000000006044820152606401610c03565b61442b836147c1565b6144775760405162461bcd60e51b815260206004820152601d60248201527f6347616d6d615769746e657373206973206e6f74206f6e2063757276650000006044820152606401610c03565b614480826147c1565b6144cc5760405162461bcd60e51b815260206004820152601c60248201527f73486173685769746e657373206973206e6f74206f6e206375727665000000006044820152606401610c03565b6144d8878a888761489a565b6145245760405162461bcd60e51b815260206004820152601960248201527f6164647228632a706b2b732a6729213d5f755769746e657373000000000000006044820152606401610c03565b60006145308a876149bd565b90506000614543898b878b868989614a21565b90506000614554838d8d8a86614b41565b9050808a146145955760405162461bcd60e51b815260206004820152600d60248201526c34b73b30b634b210383937b7b360991b6044820152606401610c03565b505050505050505050505050565b60004661a4b18114806145b8575062066eed81145b156145f757606c6001600160a01b031663c6f7de0e6040518163ffffffff1660e01b815260040160206040518083038186803b158015613f3557600080fd5b600091505090565b600d5460035460408051633fabe5a360e21b81529051600093670100000000000000900463ffffffff169283151592859283926001600160a01b03169163feaf968c9160048083019260a0929190829003018186803b15801561466157600080fd5b505afa158015614675573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190614699919061575a565b5094509092508491505080156146bd57506146b48242615d02565b8463ffffffff16105b15613b325750601154949350505050565b600081815260018301602052604081205480156147b75760006146f2600183615d02565b855490915060009061470690600190615d02565b905081811461476b57600086600001828154811061472657614726615e09565b906000526020600020015490508087600001848154811061474957614749615e09565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061477c5761477c615df3565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050611355565b6000915050611355565b80516000906401000003d0191161481a5760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420782d6f7264696e61746500000000000000000000000000006044820152606401610c03565b60208201516401000003d019116148735760405162461bcd60e51b815260206004820152601260248201527f696e76616c696420792d6f7264696e61746500000000000000000000000000006044820152606401610c03565b60208201516401000003d0199080096148938360005b6020020151614b81565b1492915050565b60006001600160a01b0382166148e05760405162461bcd60e51b815260206004820152600b60248201526a626164207769746e65737360a81b6044820152606401610c03565b6020840151600090600116156148f757601c6148fa565b601b5b9050600070014551231950b75fc4402da1732fc9bebe1985876000602002015109865170014551231950b75fc4402da1732fc9bebe19918203925060009190890987516040805160008082526020820180845287905260ff88169282019290925260608101929092526080820183905291925060019060a0016020604051602081039080840390855afa158015614995573d6000803e3d6000fd5b5050604051601f1901516001600160a01b039081169088161495505050505050949350505050565b6149c56150af565b6149f2600184846040516020016149de939291906158ff565b604051602081830303815290604052614ba5565b90505b6149fe816147c1565b611355578051604080516020810192909252614a1a91016149de565b90506149f5565b614a296150af565b825186516401000003d0199081900691061415614a885760405162461bcd60e51b815260206004820152601e60248201527f706f696e747320696e2073756d206d7573742062652064697374696e637400006044820152606401610c03565b614a93878988614bf3565b614adf5760405162461bcd60e51b815260206004820152601660248201527f4669727374206d756c20636865636b206661696c6564000000000000000000006044820152606401610c03565b614aea848685614bf3565b614b365760405162461bcd60e51b815260206004820152601760248201527f5365636f6e64206d756c20636865636b206661696c65640000000000000000006044820152606401610c03565b6141f9868484614d1b565b600060028686868587604051602001614b5f969594939291906158a0565b60408051601f1981840301815291905280516020909101209695505050505050565b6000806401000003d01980848509840990506401000003d019600782089392505050565b614bad6150af565b614bb682614de2565b8152614bcb614bc6826000614889565b614e1d565b6020820181905260029006600114156122e4576020810180516401000003d019039052919050565b600082614c305760405162461bcd60e51b815260206004820152600b60248201526a3d32b9379039b1b0b630b960a91b6044820152606401610c03565b83516020850151600090614c4690600290615db3565b15614c5257601c614c55565b601b5b9050600070014551231950b75fc4402da1732fc9bebe198387096040805160008082526020820180845281905260ff86169282019290925260608101869052608081018390529192509060019060a0016020604051602081039080840390855afa158015614cc7573d6000803e3d6000fd5b505050602060405103519050600086604051602001614ce6919061588e565b60408051601f1981840301815291905280516020909101206001600160a01b0392831692169190911498975050505050505050565b614d236150af565b835160208086015185519186015160009384938493614d4493909190614e3d565b919450925090506401000003d019858209600114614da45760405162461bcd60e51b815260206004820152601960248201527f696e765a206d75737420626520696e7665727365206f66207a000000000000006044820152606401610c03565b60405180604001604052806401000003d01980614dc357614dc3615ddd565b87860981526020016401000003d0198785099052979650505050505050565b805160208201205b6401000003d01981106122e457604080516020808201939093528151808203840181529082019091528051910120614dea565b6000611355826002614e366401000003d0196001615c6a565b901c614f1d565b60008080600180826401000003d019896401000003d019038808905060006401000003d0198b6401000003d019038a0890506000614e7d83838585614fbf565b9098509050614e8e88828e88614fe3565b9098509050614e9f88828c87614fe3565b90985090506000614eb28d878b85614fe3565b9098509050614ec388828686614fbf565b9098509050614ed488828e89614fe3565b9098509050818114614f09576401000003d019818a0998506401000003d01982890997506401000003d0198183099650614f0d565b8196505b5050505050509450945094915050565b600080614f286150cd565b6020808252818101819052604082015260608101859052608081018490526401000003d01960a0820152614f5a6150eb565b60208160c0846005600019fa925082614fb55760405162461bcd60e51b815260206004820152601260248201527f6269674d6f64457870206661696c7572652100000000000000000000000000006044820152606401610c03565b5195945050505050565b6000806401000003d0198487096401000003d0198487099097909650945050505050565b600080806401000003d019878509905060006401000003d01987876401000003d019030990506401000003d0198183086401000003d01986890990999098509650505050505050565b828054828255906000526020600020908101928215615081579160200282015b8281111561508157825182546001600160a01b0319166001600160a01b0390911617825560209092019160019091019061504c565b5061508d929150615109565b5090565b5080546000825590600052602060002090810190610c0c9190615109565b60405180604001604052806002906020820280368337509192915050565b6040518060c001604052806006906020820280368337509192915050565b60405180602001604052806001906020820280368337509192915050565b5b8082111561508d576000815560010161510a565b80356122e481615e35565b806040810183101561135557600080fd5b600082601f83011261514b57600080fd5b615153615bd3565b80838560408601111561516557600080fd5b60005b6002811015615187578135845260209384019390910190600101615168565b509095945050505050565b600082601f8301126151a357600080fd5b81356001600160401b03808211156151bd576151bd615e1f565b604051601f8301601f19908116603f011681019082821181831017156151e5576151e5615e1f565b816040528381528660208588010111156151fe57600080fd5b836020870160208301376000602085830101528094505050505092915050565b600060c0828403121561523057600080fd5b615238615bfb565b905081356001600160401b03808216821461525257600080fd5b8183526020840135602084015261526b604085016152d1565b604084015261527c606085016152d1565b606084015261528d6080850161511e565b608084015260a08401359150808211156152a657600080fd5b506152b384828501615192565b60a08301525092915050565b803561ffff811681146122e457600080fd5b803563ffffffff811681146122e457600080fd5b805169ffffffffffffffffffff811681146122e457600080fd5b80356001600160601b03811681146122e457600080fd5b60006020828403121561532857600080fd5b8135613ae381615e35565b6000806040838503121561534657600080fd5b823561535181615e35565b915061535f602084016152ff565b90509250929050565b6000806040838503121561537b57600080fd5b823561538681615e35565b9150602083013561539681615e35565b809150509250929050565b600080606083850312156153b457600080fd5b82356153bf81615e35565b915061535f8460208501615129565b600080600080606085870312156153e457600080fd5b84356153ef81615e35565b93506020850135925060408501356001600160401b038082111561541257600080fd5b818701915087601f83011261542657600080fd5b81358181111561543557600080fd5b88602082850101111561544757600080fd5b95989497505060200194505050565b60006040828403121561546857600080fd5b613ae38383615129565b60006040828403121561548457600080fd5b613ae3838361513a565b6000602082840312156154a057600080fd5b8151613ae381615e4a565b6000602082840312156154bd57600080fd5b5035919050565b6000602082840312156154d657600080fd5b5051919050565b6000602082840312156154ef57600080fd5b604051602081018181106001600160401b038211171561551157615511615e1f565b604052823561551f81615e4a565b81529392505050565b6000808284036101c081121561553d57600080fd5b6101a08082121561554d57600080fd5b615555615c1d565b9150615561868661513a565b8252615570866040870161513a565b60208301526080850135604083015260a0850135606083015260c0850135608083015261559f60e0860161511e565b60a08301526101006155b38782880161513a565b60c08401526155c687610140880161513a565b60e0840152610180860135908301529092508301356001600160401b038111156155ef57600080fd5b6155fb8582860161521e565b9150509250929050565b60006020828403121561561757600080fd5b81356001600160401b0381111561562d57600080fd5b820160c08185031215613ae357600080fd5b60006020828403121561565157600080fd5b613ae3826152bf565b60008060008060008086880360e081121561567457600080fd5b61567d886152bf565b965061568b602089016152d1565b9550615699604089016152d1565b94506156a7606089016152d1565b9350608088013592506040609f19820112156156c257600080fd5b506156cb615bd3565b6156d760a089016152d1565b81526156e560c089016152d1565b6020820152809150509295509295509295565b6000806040838503121561570b57600080fd5b82359150602083013561539681615e35565b6000806040838503121561573057600080fd5b50508035926020909101359150565b60006020828403121561575157600080fd5b613ae3826152d1565b600080600080600060a0868803121561577257600080fd5b61577b866152e5565b945060208601519350604086015192506060860151915061579e608087016152e5565b90509295509295909350565b600081518084526020808501945080840160005b838110156157e35781516001600160a01b0316875295820195908201906001016157be565b509495945050505050565b8060005b6002811015610e6b5781518452602093840193909101906001016157f2565b600081518084526020808501945080840160005b838110156157e357815187529582019590820190600101615825565b6000815180845260005b818110156158675760208185018101518683018201520161584b565b81811115615879576000602083870101525b50601f01601f19169290920160200192915050565b61589881836157ee565b604001919050565b8681526158b060208201876157ee565b6158bd60608201866157ee565b6158ca60a08201856157ee565b6158d760e08201846157ee565b60609190911b6bffffffffffffffffffffffff19166101208201526101340195945050505050565b83815261590f60208201846157ee565b606081019190915260800192915050565b6040810161135582846157ee565b602081526000613ae36020830184615811565b602081526000613ae36020830184615841565b6020815260ff8251166020820152602082015160408201526001600160a01b0360408301511660608201526000606083015160c0608084015261599a60e08401826157aa565b905060808401516001600160601b0380821660a08601528060a08701511660c086015250508091505092915050565b60006060820161ffff86168352602063ffffffff86168185015260606040850152818551808452608086019150828701935060005b81811015615a1a578451835293830193918301916001016159fe565b509098975050505050505050565b82815260608101613ae360208301846157ee565b828152604060208201526000613b326040830184615811565b86815285602082015261ffff85166040820152600063ffffffff808616606084015280851660808401525060c060a08301526141f960c0830184615841565b878152866020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c08301526142e660e0830184615841565b8781526001600160401b0387166020820152856040820152600063ffffffff80871660608401528086166080840152506001600160a01b03841660a083015260e060c08301526142e660e0830184615841565b60006001600160601b0380881683528087166020840152506001600160401b03851660408301526001600160a01b038416606083015260a06080830152615b7b60a08301846157aa565b979650505050505050565b6000808335601e19843603018112615b9d57600080fd5b8301803591506001600160401b03821115615bb757600080fd5b602001915036819003821315615bcc57600080fd5b9250929050565b604080519081016001600160401b0381118282101715615bf557615bf5615e1f565b60405290565b60405160c081016001600160401b0381118282101715615bf557615bf5615e1f565b60405161012081016001600160401b0381118282101715615bf557615bf5615e1f565b60008085851115615c5057600080fd5b83861115615c5d57600080fd5b5050820193919092039150565b60008219821115615c7d57615c7d615dc7565b500190565b60006001600160401b03808316818516808303821115615ca457615ca4615dc7565b01949350505050565b60006001600160601b03808316818516808303821115615ca457615ca4615dc7565b600082615cde57615cde615ddd565b500490565b6000816000190483118215151615615cfd57615cfd615dc7565b500290565b600082821015615d1457615d14615dc7565b500390565b60006001600160601b0383811690831681811015615d3957615d39615dc7565b039392505050565b6001600160e01b03198135818116916004851015615d695780818660040360031b1b83161692505b505092915050565b6000600019821415615d8557615d85615dc7565b5060010190565b60006001600160401b0380831681811415615da957615da9615dc7565b6001019392505050565b600082615dc257615dc2615ddd565b500690565b634e487b7160e01b600052601160045260246000fd5b634e487b7160e01b600052601260045260246000fd5b634e487b7160e01b600052603160045260246000fd5b634e487b7160e01b600052603260045260246000fd5b634e487b7160e01b600052604160045260246000fd5b6001600160a01b0381168114610c0c57600080fd5b8015158114610c0c57600080fdfea164736f6c6343000806000a", } var VRFCoordinatorV2PlusABI = VRFCoordinatorV2PlusMetaData.ABI @@ -338,6 +338,28 @@ func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusCallerSession) MAXREQUESTCONFIR return _VRFCoordinatorV2Plus.Contract.MAXREQUESTCONFIRMATIONS(&_VRFCoordinatorV2Plus.CallOpts) } +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusCaller) GetActiveSubscriptionIds(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) { + var out []interface{} + err := _VRFCoordinatorV2Plus.contract.Call(opts, &out, "getActiveSubscriptionIds", startIndex, maxCount) + + if err != nil { + return *new([]*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) + + return out0, err + +} + +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusSession) GetActiveSubscriptionIds(startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) { + return _VRFCoordinatorV2Plus.Contract.GetActiveSubscriptionIds(&_VRFCoordinatorV2Plus.CallOpts, startIndex, maxCount) +} + +func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusCallerSession) GetActiveSubscriptionIds(startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) { + return _VRFCoordinatorV2Plus.Contract.GetActiveSubscriptionIds(&_VRFCoordinatorV2Plus.CallOpts, startIndex, maxCount) +} + func (_VRFCoordinatorV2Plus *VRFCoordinatorV2PlusCaller) GetRequestConfig(opts *bind.CallOpts) (uint16, uint32, [][32]byte, error) { var out []interface{} err := _VRFCoordinatorV2Plus.contract.Call(opts, &out, "getRequestConfig") @@ -3716,6 +3738,8 @@ type VRFCoordinatorV2PlusInterface interface { MAXREQUESTCONFIRMATIONS(opts *bind.CallOpts) (uint16, error) + GetActiveSubscriptionIds(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) + GetRequestConfig(opts *bind.CallOpts) (uint16, uint32, [][32]byte, error) GetSubscription(opts *bind.CallOpts, subId *big.Int) (GetSubscription, diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 80f053cb534..5037f7c7277 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -70,7 +70,7 @@ vrf_consumer_v2_upgradeable_example: ../../contracts/solc/v0.8.6/VRFConsumerV2Up vrf_coordinator_mock: ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin 5c495cf8df1f46d8736b9150cdf174cce358cb8352f60f0d5bb9581e23920501 vrf_coordinator_v2: ../../contracts/solc/v0.8.6/VRFCoordinatorV2.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2.bin 75c87cf1624a401ac6303df9c8e04896aa8a53849e8b0c3d7340a9d089ef6d4b vrf_coordinator_v2_plus_v2_example: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus_V2Example.bin 02d0ec25e4f3d72f818e7ebc2b5f5949a94889ab0da091f0d3e7f5e4a20a0bb6 -vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 177efc55a336d4f5b643142b8528be16d710d52324f36ef09f1ff1d27ff41747 +vrf_coordinator_v2plus: ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.abi ../../contracts/solc/v0.8.6/VRFCoordinatorV2Plus.bin 912a7372a66ed8fd3a38a5b0913c8dca668ddb5d0e2de9d5352a6fac9e60f92b vrf_external_sub_owner_example: ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.abi ../../contracts/solc/v0.8.6/VRFExternalSubOwnerExample.bin 14f888eb313930b50233a6f01ea31eba0206b7f41a41f6311670da8bb8a26963 vrf_load_test_external_sub_owner: ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.abi ../../contracts/solc/v0.8.6/VRFLoadTestExternalSubOwner.bin 2097faa70265e420036cc8a3efb1f1e0836ad2d7323b295b9a26a125dbbe6c7d vrf_load_test_ownerless_consumer: ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.abi ../../contracts/solc/v0.8.6/VRFLoadTestOwnerlessConsumer.bin 74f914843cbc70b9c3079c3e1c709382ce415225e8bb40113e7ac018bfcb0f5c From 76968ed917590e7e4d958be7680ac86a0c463ceb Mon Sep 17 00:00:00 2001 From: Andrei Smirnov Date: Thu, 17 Aug 2023 18:54:24 +0300 Subject: [PATCH 202/270] Functions: updating scripts (#10241) --- .../scripts/functions/src/generate_jobspecs_cmd.go | 14 +++++++------- core/scripts/functions/templates/bootstrap.toml | 7 +++++-- core/scripts/functions/templates/oracle.toml | 4 ++-- 3 files changed, 14 insertions(+), 11 deletions(-) diff --git a/core/scripts/functions/src/generate_jobspecs_cmd.go b/core/scripts/functions/src/generate_jobspecs_cmd.go index d7de2da3b55..332e2bdc0cb 100644 --- a/core/scripts/functions/src/generate_jobspecs_cmd.go +++ b/core/scripts/functions/src/generate_jobspecs_cmd.go @@ -28,11 +28,11 @@ func (g *generateJobSpecs) Run(args []string) { nodesFile := fs.String("nodes", "", "a file containing nodes urls, logins and passwords") chainID := fs.Int64("chainid", 80001, "chain id") p2pPort := fs.Int64("p2pport", 6690, "p2p port") - donID := fs.String("donid", "", "don ID string") - contractAddress := fs.String("contract", "", "oracle contract address") + donID := fs.String("donid", "", "don id string") + routerAddress := fs.String("contract", "", "router contract address") truncateHostname := fs.Bool("truncateboothostname", false, "truncate host name to first segment (needed for staging DONs)") err := fs.Parse(args) - if err != nil || nodesFile == nil || *nodesFile == "" || contractAddress == nil || *contractAddress == "" { + if err != nil || nodesFile == nil || *nodesFile == "" || routerAddress == nil || *routerAddress == "" { fs.Usage() os.Exit(1) } @@ -45,7 +45,7 @@ func (g *generateJobSpecs) Run(args []string) { helpers.PanicErr(err) bootHost := nodes[0].url.Host - lines = replacePlaceholders(lines, *chainID, *p2pPort, *contractAddress, bootHost, &bootstrapNode, &bootstrapNode, *truncateHostname) + lines = replacePlaceholders(lines, *donID, *chainID, *p2pPort, *routerAddress, bootHost, &bootstrapNode, &bootstrapNode, *truncateHostname) outputPath := filepath.Join(artefactsDir, bootHost+".toml") err = writeLines(lines, outputPath) helpers.PanicErr(err) @@ -54,7 +54,7 @@ func (g *generateJobSpecs) Run(args []string) { lines, err = readLines(filepath.Join(templatesDir, oracleSpecTemplate)) helpers.PanicErr(err) for i := 1; i < len(nodes); i++ { - oracleLines := replacePlaceholders(lines, donID, *chainID, *p2pPort, *contractAddress, bootHost, &bootstrapNode, &nca[i], *truncateHostname) + oracleLines := replacePlaceholders(lines, *donID, *chainID, *p2pPort, *routerAddress, bootHost, &bootstrapNode, &nca[i], *truncateHostname) outputPath := filepath.Join(artefactsDir, nodes[i].url.Host+".toml") err = writeLines(oracleLines, outputPath) helpers.PanicErr(err) @@ -62,7 +62,7 @@ func (g *generateJobSpecs) Run(args []string) { } } -func replacePlaceholders(lines []string, donID string, chainID, p2pPort int64, contractAddress, bootHost string, boot *NodeKeys, node *NodeKeys, truncateHostname bool) (output []string) { +func replacePlaceholders(lines []string, donID string, chainID, p2pPort int64, routerAddress, bootHost string, boot *NodeKeys, node *NodeKeys, truncateHostname bool) (output []string) { chainIDStr := strconv.FormatInt(chainID, 10) if truncateHostname { bootHost = bootHost[:strings.IndexByte(bootHost, '.')] @@ -71,7 +71,7 @@ func replacePlaceholders(lines []string, donID string, chainID, p2pPort int64, c ts := time.Now().UTC().Format("2006-01-02T15:04") for _, l := range lines { l = strings.Replace(l, "{{chain_id}}", chainIDStr, 1) - l = strings.Replace(l, "{{oracle_contract_address}}", contractAddress, 1) + l = strings.Replace(l, "{{router_contract_address}}", routerAddress, 1) l = strings.Replace(l, "{{node_eth_address}}", node.EthAddress, 1) l = strings.Replace(l, "{{ocr2_key_bundle_id}}", node.OCR2BundleID, 1) l = strings.Replace(l, "{{p2p_bootstrapper}}", bootstrapper, 1) diff --git a/core/scripts/functions/templates/bootstrap.toml b/core/scripts/functions/templates/bootstrap.toml index 48d011e30d0..a738a53eea6 100644 --- a/core/scripts/functions/templates/bootstrap.toml +++ b/core/scripts/functions/templates/bootstrap.toml @@ -1,9 +1,12 @@ type = "bootstrap" schemaVersion = 1 -name = "Functions bootstrap {{timestamp}}" +name = "Functions V1 bootstrap {{timestamp}}" forwardingAllowed = false -contractID = "{{oracle_contract_address}}" +contractID = "{{router_contract_address}}" relay = "evm" [relayConfig] chainID = {{chain_id}} +contractUpdateCheckFrequencySec = 60 +contractVersion = 1 +donID = "{{don_id}}" diff --git a/core/scripts/functions/templates/oracle.toml b/core/scripts/functions/templates/oracle.toml index 47465cbaa08..10e2164a047 100644 --- a/core/scripts/functions/templates/oracle.toml +++ b/core/scripts/functions/templates/oracle.toml @@ -1,8 +1,8 @@ type = "offchainreporting2" schemaVersion = 1 -name = "Functions {{timestamp}}" +name = "Functions V1 {{timestamp}}" forwardingAllowed = false -contractID = "{{oracle_contract_address}}" +contractID = "{{router_contract_address}}" ocrKeyBundleID = "{{ocr2_key_bundle_id}}" p2pv2Bootstrappers = [ "{{p2p_bootstrapper}}" From e5eaff0f4949cb9f943499ecaf0d5e06c86fdc2c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Aug 2023 12:30:29 -0500 Subject: [PATCH 203/270] Bump sonarsource/sonarqube-scan-action from 1.2.0 to 2.0.0 (#9958) Bumps [sonarsource/sonarqube-scan-action](https://github.com/sonarsource/sonarqube-scan-action) from 1.2.0 to 2.0.0. - [Release notes](https://github.com/sonarsource/sonarqube-scan-action/releases) - [Commits](https://github.com/sonarsource/sonarqube-scan-action/compare/a6ba0aafc293e03de5437af7edbc97f7d3ebc91a...4b0bfc149f5e285930eeb5e917327e66660c6e92) --- updated-dependencies: - dependency-name: sonarsource/sonarqube-scan-action dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jordan Krage --- .github/workflows/ci-core.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index b55b69e293c..5ff52edb80f 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -317,7 +317,7 @@ jobs: echo "sonarqube_tests_report_paths=$(find go_core_tests_*_logs -name output.txt | paste -sd "," -)" >> $GITHUB_OUTPUT echo "sonarqube_coverage_report_paths=$(find go_core_tests_*_logs -name coverage.txt | paste -sd "," -)" >> $GITHUB_OUTPUT - name: SonarQube Scan - uses: sonarsource/sonarqube-scan-action@a6ba0aafc293e03de5437af7edbc97f7d3ebc91a # v1.2.0 + uses: sonarsource/sonarqube-scan-action@4b0bfc149f5e285930eeb5e917327e66660c6e92 # v2.0.0 with: args: > -Dsonar.go.tests.reportPaths=${{ steps.sonarqube_report_paths.outputs.sonarqube_tests_report_paths }} From 67792a7bb56240acc783998d1d550d344ca32371 Mon Sep 17 00:00:00 2001 From: Aaron Lu <50029043+aalu1418@users.noreply.github.com> Date: Thu, 17 Aug 2023 11:43:22 -0600 Subject: [PATCH 204/270] remove unnecessary generic client + update commenting for clarity (#10249) --- common/types/client.go | 56 ------------ core/chains/evm/client/client.go | 37 ++++---- core/chains/evm/client/mocks/client.go | 88 +++++-------------- core/chains/evm/client/null_client.go | 10 --- .../evm/client/simulated_backend_client.go | 8 -- 5 files changed, 44 insertions(+), 155 deletions(-) delete mode 100644 common/types/client.go diff --git a/common/types/client.go b/common/types/client.go deleted file mode 100644 index a3f89a3155b..00000000000 --- a/common/types/client.go +++ /dev/null @@ -1,56 +0,0 @@ -package types - -import ( - "context" - "math/big" -) - -// A generic client interface for communication with the RPC node -// Every native chain must implement independently -type Client[ - CHAINID ID, - SEQ Sequence, - ADDR Hashable, - BLOCK any, - BLOCKHASH Hashable, - TX any, - TXHASH Hashable, - TXRECEIPT any, - EVENT any, - EVENTOPS any, // event filter query options -] interface { - // ChainID stored for quick access - ConfiguredChainID() CHAINID - // ChainID RPC call - ChainID() (CHAINID, error) - - Accounts[ADDR, SEQ] - Transactions[TX, TXHASH, TXRECEIPT] - Events[EVENT, EVENTOPS] - Blocks[BLOCK, BLOCKHASH] - - CallContext(ctx context.Context, result interface{}, method string, args ...interface{}) error -} - -type Accounts[ADDR Hashable, SEQ Sequence] interface { - BalanceAt(ctx context.Context, accountAddress ADDR, blockNumber *big.Int) (*big.Int, error) - TokenBalance(ctx context.Context, accountAddress ADDR, tokenAddress ADDR) (*big.Int, error) - SequenceAt(ctx context.Context, accountAddress ADDR, blockNumber *big.Int) (SEQ, error) -} - -type Transactions[TX any, TXHASH Hashable, TXRECEIPT any] interface { - SendTransaction(ctx context.Context, tx *TX) error - SimulateTransaction(ctx context.Context, tx *TX) error - TransactionByHash(ctx context.Context, txHash TXHASH) (*TX, error) - TransactionReceipt(ctx context.Context, txHash TXHASH) (*TXRECEIPT, error) -} - -type Blocks[BLOCK any, BLOCKHASH Hashable] interface { - BlockByNumber(ctx context.Context, number *big.Int) (*BLOCK, error) - BlockByHash(ctx context.Context, hash BLOCKHASH) (*BLOCK, error) - LatestBlockHeight(context.Context) (*big.Int, error) -} - -type Events[EVENT any, EVENTOPS any] interface { - FilterEvents(ctx context.Context, query EVENTOPS) ([]EVENT, error) -} diff --git a/core/chains/evm/client/client.go b/core/chains/evm/client/client.go index d727c1a6ad1..339542f4ce1 100644 --- a/core/chains/evm/client/client.go +++ b/core/chains/evm/client/client.go @@ -8,7 +8,6 @@ import ( clienttypes "github.com/smartcontractkit/chainlink/v2/common/chains/client" htrktypes "github.com/smartcontractkit/chainlink/v2/common/headtracker/types" - commontypes "github.com/smartcontractkit/chainlink/v2/common/types" "github.com/smartcontractkit/chainlink/v2/core/assets" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/config" @@ -30,16 +29,23 @@ const BALANCE_OF_ADDRESS_FUNCTION_SELECTOR = "0x70a08231" // Client is the interface used to interact with an ethereum node. type Client interface { - commontypes.Client[*big.Int, evmtypes.Nonce, common.Address, types.Block, common.Hash, types.Transaction, common.Hash, types.Receipt, types.Log, ethereum.FilterQuery] - Dial(ctx context.Context) error Close() + // ChainID locally stored for quick access + ConfiguredChainID() *big.Int + // ChainID RPC call + ChainID() (*big.Int, error) // NodeStates returns a map of node Name->node state // It might be nil or empty, e.g. for mock clients etc NodeStates() map[string]string + TokenBalance(ctx context.Context, address common.Address, contractAddress common.Address) (*big.Int, error) + BalanceAt(ctx context.Context, account common.Address, blockNumber *big.Int) (*big.Int, error) + LINKBalance(ctx context.Context, address common.Address, linkAddress common.Address) (*assets.Link, error) + // Wrapped RPC methods + CallContext(ctx context.Context, result interface{}, method string, args ...interface{}) error BatchCallContext(ctx context.Context, b []rpc.BatchElem) error // BatchCallContextAll calls BatchCallContext for every single node including // sendonlys. @@ -58,22 +64,29 @@ type Client interface { SendTransactionReturnCode(ctx context.Context, tx *types.Transaction, fromAddress common.Address) (clienttypes.SendTxReturnCode, error) // Wrapped Geth client methods + // blockNumber can be specified as `nil` to imply latest block + // if blocks, transactions, or receipts are not found - a nil result and an error are returned + // these methods may not be compatible with non Ethereum chains as return types may follow different formats + // suggested options: use HeadByNumber/HeadByHash (above) or CallContext and parse with custom types + SendTransaction(ctx context.Context, tx *types.Transaction) error CodeAt(ctx context.Context, account common.Address, blockNumber *big.Int) ([]byte, error) PendingCodeAt(ctx context.Context, account common.Address) ([]byte, error) PendingNonceAt(ctx context.Context, account common.Address) (uint64, error) - + SequenceAt(ctx context.Context, account common.Address, blockNumber *big.Int) (evmtypes.Nonce, error) + TransactionByHash(ctx context.Context, txHash common.Hash) (*types.Transaction, error) + TransactionReceipt(ctx context.Context, txHash common.Hash) (*types.Receipt, error) + BlockByNumber(ctx context.Context, number *big.Int) (*types.Block, error) + BlockByHash(ctx context.Context, hash common.Hash) (*types.Block, error) FilterLogs(ctx context.Context, q ethereum.FilterQuery) ([]types.Log, error) SubscribeFilterLogs(ctx context.Context, q ethereum.FilterQuery, ch chan<- types.Log) (ethereum.Subscription, error) - EstimateGas(ctx context.Context, call ethereum.CallMsg) (uint64, error) SuggestGasPrice(ctx context.Context) (*big.Int, error) SuggestGasTipCap(ctx context.Context) (*big.Int, error) + LatestBlockHeight(ctx context.Context) (*big.Int, error) HeaderByNumber(ctx context.Context, n *big.Int) (*types.Header, error) HeaderByHash(ctx context.Context, h common.Hash) (*types.Header, error) - LINKBalance(ctx context.Context, address common.Address, linkAddress common.Address) (*assets.Link, error) - CallContract(ctx context.Context, msg ethereum.CallMsg, blockNumber *big.Int) ([]byte, error) IsL2() bool @@ -92,7 +105,6 @@ type client struct { var _ Client = (*client)(nil) var _ htrktypes.Client[*evmtypes.Head, ethereum.Subscription, *big.Int, common.Hash] = (*client)(nil) -var _ commontypes.Client[*big.Int, evmtypes.Nonce, common.Address, types.Block, common.Hash, types.Transaction, common.Hash, types.Receipt, types.Log, ethereum.FilterQuery] = (*client)(nil) // NewClientWithNodes instantiates a client from a list of nodes // Currently only supports one primary @@ -209,11 +221,6 @@ func (client *client) SendTransaction(ctx context.Context, tx *types.Transaction return client.pool.SendTransaction(ctx, tx) } -func (client *client) SimulateTransaction(ctx context.Context, tx *types.Transaction) error { - // todo: implement if used - return errors.New("SimulateTransaction not implemented") -} - func (client *client) PendingNonceAt(ctx context.Context, account common.Address) (uint64, error) { return client.pool.PendingNonceAt(ctx, account) } @@ -297,10 +304,6 @@ func ToBlockNumArg(number *big.Int) string { return hexutil.EncodeBig(number) } -func (client *client) FilterEvents(ctx context.Context, q ethereum.FilterQuery) ([]types.Log, error) { - return client.FilterLogs(ctx, q) -} - func (client *client) FilterLogs(ctx context.Context, q ethereum.FilterQuery) ([]types.Log, error) { return client.pool.FilterLogs(ctx, q) } diff --git a/core/chains/evm/client/mocks/client.go b/core/chains/evm/client/mocks/client.go index 1f3ceb6870d..aec16a9e524 100644 --- a/core/chains/evm/client/mocks/client.go +++ b/core/chains/evm/client/mocks/client.go @@ -29,17 +29,17 @@ type Client struct { mock.Mock } -// BalanceAt provides a mock function with given fields: ctx, accountAddress, blockNumber -func (_m *Client) BalanceAt(ctx context.Context, accountAddress common.Address, blockNumber *big.Int) (*big.Int, error) { - ret := _m.Called(ctx, accountAddress, blockNumber) +// BalanceAt provides a mock function with given fields: ctx, account, blockNumber +func (_m *Client) BalanceAt(ctx context.Context, account common.Address, blockNumber *big.Int) (*big.Int, error) { + ret := _m.Called(ctx, account, blockNumber) var r0 *big.Int var r1 error if rf, ok := ret.Get(0).(func(context.Context, common.Address, *big.Int) (*big.Int, error)); ok { - return rf(ctx, accountAddress, blockNumber) + return rf(ctx, account, blockNumber) } if rf, ok := ret.Get(0).(func(context.Context, common.Address, *big.Int) *big.Int); ok { - r0 = rf(ctx, accountAddress, blockNumber) + r0 = rf(ctx, account, blockNumber) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(*big.Int) @@ -47,7 +47,7 @@ func (_m *Client) BalanceAt(ctx context.Context, accountAddress common.Address, } if rf, ok := ret.Get(1).(func(context.Context, common.Address, *big.Int) error); ok { - r1 = rf(ctx, accountAddress, blockNumber) + r1 = rf(ctx, account, blockNumber) } else { r1 = ret.Error(1) } @@ -289,32 +289,6 @@ func (_m *Client) EstimateGas(ctx context.Context, call ethereum.CallMsg) (uint6 return r0, r1 } -// FilterEvents provides a mock function with given fields: ctx, query -func (_m *Client) FilterEvents(ctx context.Context, query ethereum.FilterQuery) ([]types.Log, error) { - ret := _m.Called(ctx, query) - - var r0 []types.Log - var r1 error - if rf, ok := ret.Get(0).(func(context.Context, ethereum.FilterQuery) ([]types.Log, error)); ok { - return rf(ctx, query) - } - if rf, ok := ret.Get(0).(func(context.Context, ethereum.FilterQuery) []types.Log); ok { - r0 = rf(ctx, query) - } else { - if ret.Get(0) != nil { - r0 = ret.Get(0).([]types.Log) - } - } - - if rf, ok := ret.Get(1).(func(context.Context, ethereum.FilterQuery) error); ok { - r1 = rf(ctx, query) - } else { - r1 = ret.Error(1) - } - - return r0, r1 -} - // FilterLogs provides a mock function with given fields: ctx, q func (_m *Client) FilterLogs(ctx context.Context, q ethereum.FilterQuery) ([]types.Log, error) { ret := _m.Called(ctx, q) @@ -485,17 +459,17 @@ func (_m *Client) LINKBalance(ctx context.Context, address common.Address, linkA return r0, r1 } -// LatestBlockHeight provides a mock function with given fields: _a0 -func (_m *Client) LatestBlockHeight(_a0 context.Context) (*big.Int, error) { - ret := _m.Called(_a0) +// LatestBlockHeight provides a mock function with given fields: ctx +func (_m *Client) LatestBlockHeight(ctx context.Context) (*big.Int, error) { + ret := _m.Called(ctx) var r0 *big.Int var r1 error if rf, ok := ret.Get(0).(func(context.Context) (*big.Int, error)); ok { - return rf(_a0) + return rf(ctx) } if rf, ok := ret.Get(0).(func(context.Context) *big.Int); ok { - r0 = rf(_a0) + r0 = rf(ctx) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(*big.Int) @@ -503,7 +477,7 @@ func (_m *Client) LatestBlockHeight(_a0 context.Context) (*big.Int, error) { } if rf, ok := ret.Get(1).(func(context.Context) error); ok { - r1 = rf(_a0) + r1 = rf(ctx) } else { r1 = ret.Error(1) } @@ -615,23 +589,23 @@ func (_m *Client) SendTransactionReturnCode(ctx context.Context, tx *types.Trans return r0, r1 } -// SequenceAt provides a mock function with given fields: ctx, accountAddress, blockNumber -func (_m *Client) SequenceAt(ctx context.Context, accountAddress common.Address, blockNumber *big.Int) (evmtypes.Nonce, error) { - ret := _m.Called(ctx, accountAddress, blockNumber) +// SequenceAt provides a mock function with given fields: ctx, account, blockNumber +func (_m *Client) SequenceAt(ctx context.Context, account common.Address, blockNumber *big.Int) (evmtypes.Nonce, error) { + ret := _m.Called(ctx, account, blockNumber) var r0 evmtypes.Nonce var r1 error if rf, ok := ret.Get(0).(func(context.Context, common.Address, *big.Int) (evmtypes.Nonce, error)); ok { - return rf(ctx, accountAddress, blockNumber) + return rf(ctx, account, blockNumber) } if rf, ok := ret.Get(0).(func(context.Context, common.Address, *big.Int) evmtypes.Nonce); ok { - r0 = rf(ctx, accountAddress, blockNumber) + r0 = rf(ctx, account, blockNumber) } else { r0 = ret.Get(0).(evmtypes.Nonce) } if rf, ok := ret.Get(1).(func(context.Context, common.Address, *big.Int) error); ok { - r1 = rf(ctx, accountAddress, blockNumber) + r1 = rf(ctx, account, blockNumber) } else { r1 = ret.Error(1) } @@ -639,20 +613,6 @@ func (_m *Client) SequenceAt(ctx context.Context, accountAddress common.Address, return r0, r1 } -// SimulateTransaction provides a mock function with given fields: ctx, tx -func (_m *Client) SimulateTransaction(ctx context.Context, tx *types.Transaction) error { - ret := _m.Called(ctx, tx) - - var r0 error - if rf, ok := ret.Get(0).(func(context.Context, *types.Transaction) error); ok { - r0 = rf(ctx, tx) - } else { - r0 = ret.Error(0) - } - - return r0 -} - // SubscribeFilterLogs provides a mock function with given fields: ctx, q, ch func (_m *Client) SubscribeFilterLogs(ctx context.Context, q ethereum.FilterQuery, ch chan<- types.Log) (ethereum.Subscription, error) { ret := _m.Called(ctx, q, ch) @@ -757,17 +717,17 @@ func (_m *Client) SuggestGasTipCap(ctx context.Context) (*big.Int, error) { return r0, r1 } -// TokenBalance provides a mock function with given fields: ctx, accountAddress, tokenAddress -func (_m *Client) TokenBalance(ctx context.Context, accountAddress common.Address, tokenAddress common.Address) (*big.Int, error) { - ret := _m.Called(ctx, accountAddress, tokenAddress) +// TokenBalance provides a mock function with given fields: ctx, address, contractAddress +func (_m *Client) TokenBalance(ctx context.Context, address common.Address, contractAddress common.Address) (*big.Int, error) { + ret := _m.Called(ctx, address, contractAddress) var r0 *big.Int var r1 error if rf, ok := ret.Get(0).(func(context.Context, common.Address, common.Address) (*big.Int, error)); ok { - return rf(ctx, accountAddress, tokenAddress) + return rf(ctx, address, contractAddress) } if rf, ok := ret.Get(0).(func(context.Context, common.Address, common.Address) *big.Int); ok { - r0 = rf(ctx, accountAddress, tokenAddress) + r0 = rf(ctx, address, contractAddress) } else { if ret.Get(0) != nil { r0 = ret.Get(0).(*big.Int) @@ -775,7 +735,7 @@ func (_m *Client) TokenBalance(ctx context.Context, accountAddress common.Addres } if rf, ok := ret.Get(1).(func(context.Context, common.Address, common.Address) error); ok { - r1 = rf(ctx, accountAddress, tokenAddress) + r1 = rf(ctx, address, contractAddress) } else { r1 = ret.Error(1) } diff --git a/core/chains/evm/client/null_client.go b/core/chains/evm/client/null_client.go index adfd4eacc00..394f792eeaa 100644 --- a/core/chains/evm/client/null_client.go +++ b/core/chains/evm/client/null_client.go @@ -131,11 +131,6 @@ func (nc *NullClient) SendTransaction(ctx context.Context, tx *types.Transaction return nil } -func (nc *NullClient) SimulateTransaction(ctx context.Context, tx *types.Transaction) error { - nc.lggr.Debug("SimulateTransaction") - return nil -} - func (nc *NullClient) PendingCodeAt(ctx context.Context, account common.Address) ([]byte, error) { nc.lggr.Debug("PendingCodeAt") return nil, nil @@ -181,11 +176,6 @@ func (nc *NullClient) BalanceAt(ctx context.Context, account common.Address, blo return big.NewInt(0), nil } -func (nc *NullClient) FilterEvents(ctx context.Context, q ethereum.FilterQuery) ([]types.Log, error) { - nc.lggr.Debug("FilterEvents") - return nil, nil -} - func (nc *NullClient) FilterLogs(ctx context.Context, q ethereum.FilterQuery) ([]types.Log, error) { nc.lggr.Debug("FilterLogs") return nil, nil diff --git a/core/chains/evm/client/simulated_backend_client.go b/core/chains/evm/client/simulated_backend_client.go index df69de07e6e..74b7aa54ece 100644 --- a/core/chains/evm/client/simulated_backend_client.go +++ b/core/chains/evm/client/simulated_backend_client.go @@ -111,10 +111,6 @@ func (c *SimulatedBackendClient) CallContext(ctx context.Context, result interfa } } -func (c *SimulatedBackendClient) FilterEvents(ctx context.Context, q ethereum.FilterQuery) (logs []types.Log, err error) { - return c.b.FilterLogs(ctx, q) -} - // FilterLogs returns all logs that respect the passed filter query. func (c *SimulatedBackendClient) FilterLogs(ctx context.Context, q ethereum.FilterQuery) (logs []types.Log, err error) { return c.b.FilterLogs(ctx, q) @@ -405,10 +401,6 @@ func (c *SimulatedBackendClient) SendTransaction(ctx context.Context, tx *types. return err } -func (c *SimulatedBackendClient) SimulateTransaction(ctx context.Context, tx *types.Transaction) error { - panic("not implemented") -} - type revertError struct { error reason string From d670f880f94137f40afedfc372bca537464ff167 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 17 Aug 2023 12:58:01 -0500 Subject: [PATCH 205/270] Bump smartcontractkit/chainlink-github-actions from 2.2.1 to 2.2.9 (#10240) * Bump smartcontractkit/chainlink-github-actions from 2.2.1 to 2.2.9 Bumps [smartcontractkit/chainlink-github-actions](https://github.com/smartcontractkit/chainlink-github-actions) from 2.2.1 to 2.2.9. - [Release notes](https://github.com/smartcontractkit/chainlink-github-actions/releases) - [Commits](https://github.com/smartcontractkit/chainlink-github-actions/compare/v2.2.1...260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35) --- updated-dependencies: - dependency-name: smartcontractkit/chainlink-github-actions dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] * Update .github/workflows/ci-core.yml --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Jordan Krage --- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 ++--- .github/workflows/ci-core.yml | 2 +- .github/workflows/generic-test-runner.yml | 6 ++--- .github/workflows/integration-chaos-tests.yml | 6 ++--- .github/workflows/integration-tests.yml | 22 +++++++++---------- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/performance-tests.yml | 2 +- 8 files changed, 24 insertions(+), 24 deletions(-) diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index 7d5e11b157c..e8e4556a85f 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -107,7 +107,7 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 env: DETACH_RUNNER: true TEST_SUITE: benchmark diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index b814f3ba903..b22a53b88ee 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -49,7 +49,7 @@ jobs: - name: Check if image exists if: inputs.chainlinkImage == '' id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 #v2.2.1 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 #v2.2.9 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -57,7 +57,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' && inputs.chainlinkImage == '' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -160,7 +160,7 @@ jobs: echo "version=develop" >>$GITHUB_OUTPUT fi - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 #v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 #v2.2.9 env: PYROSCOPE_SERVER: ${{ matrix.tests.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.tests.pyroscope_env }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 5ff52edb80f..9278ea418cd 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -180,7 +180,7 @@ jobs: run: ./tools/bin/${{ matrix.cmd }} "${{ matrix.split.pkgs }}" - name: Print Filtered Test Results if: failure() - uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@9a48ff0869aa6cb2753125301f744d5372d669f6 # v2.2.5 + uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: results-file: ./output.txt output-file: ./output-short.txt diff --git a/.github/workflows/generic-test-runner.yml b/.github/workflows/generic-test-runner.yml index a739d705f88..0ec9b21abed 100644 --- a/.github/workflows/generic-test-runner.yml +++ b/.github/workflows/generic-test-runner.yml @@ -53,7 +53,7 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 #v2.2.1 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 #v2.2.9 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -61,7 +61,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -126,7 +126,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 1h -count=1 ./${{ github.event.inputs.directory }} -run ${{ github.event.inputs.test }} -v -args ${{ github.event.inputs.test-inputs }} test_download_vendor_packages_command: cd ./integration-tests && go mod download diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index a9d3c559f93..2b47b21b759 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -30,7 +30,7 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: repository: chainlink tag: ${{ github.sha }} @@ -38,7 +38,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -109,7 +109,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: test_command_to_run: make test_need_operator_assets && cd integration-tests && go test -timeout 1h -count=1 -json -test.parallel 11 ./chaos 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index afda0d393b0..88b06566fa7 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -86,7 +86,7 @@ jobs: - name: Check if image exists if: needs.changes.outputs.src == 'true' id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -94,7 +94,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' && needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -174,7 +174,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -199,7 +199,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod @@ -392,7 +392,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 env: PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} @@ -415,7 +415,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod @@ -477,7 +477,7 @@ jobs: with: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} - name: Run Setup - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod @@ -521,7 +521,7 @@ jobs: run: | echo "Running migration tests from version '${{ steps.get_latest_version.outputs.latest_version }}' to: '${{ github.sha }}'" - name: Run Migration Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.7 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json ./migration 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download @@ -619,7 +619,7 @@ jobs: steps: - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: repository: chainlink-solana-tests tag: ${{ needs.get_solana_sha.outputs.sha }} @@ -758,7 +758,7 @@ jobs: ref: ${{ needs.get_solana_sha.outputs.sha }} - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 with: test_command_to_run: export ENV_JOB_IMAGE=${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/chainlink-solana-tests:${{ needs.get_solana_sha.outputs.sha }} && make test_smoke cl_repo: ${{ env.CHAINLINK_IMAGE }} @@ -821,7 +821,7 @@ jobs: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} ## Only run OCR smoke test for now - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 env: PYROSCOPE_SERVER: ${{ secrets.QA_PYROSCOPE_INSTANCE }} PYROSCOPE_ENVIRONMENT: ci-smoke-ocr-evm-${{ matrix.testnet }} # TODO: Only for OCR for now diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 8a986b3bdd2..9f6dafc0dac 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -121,7 +121,7 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 env: DETACH_RUNNER: true TEST_SUITE: soak diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 60479e6c960..ad4dbfb63b3 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -57,7 +57,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@ad22fbd6f4d108b82aaf49b527bcf40f32babea8 # v2.2.1 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 with: test_command_to_run: cd integration-tests && go test -timeout 1h -count=1 -json -test.parallel 10 ./performance 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: make gomod From 96da6fafc6b9cc573e8ea4a62dbe9b12d360a142 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Thu, 17 Aug 2023 15:40:05 -0400 Subject: [PATCH 206/270] Bump libocr to latest (#10250) --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 901e5622894..3a7ea529030 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -18,7 +18,7 @@ require ( github.com/pelletier/go-toml/v2 v2.0.9 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 - github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 + github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 github.com/smartcontractkit/ocr2keepers v0.7.10 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 86a410ddded..c43c5e77716 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1440,8 +1440,8 @@ github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kN github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= -github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= -github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= +github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= +github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= diff --git a/go.mod b/go.mod index b1e1245b7ce..35c7361325b 100644 --- a/go.mod +++ b/go.mod @@ -69,7 +69,7 @@ require ( github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a - github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 + github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 github.com/smartcontractkit/ocr2keepers v0.7.10 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb diff --git a/go.sum b/go.sum index 927d3733233..7db387da245 100644 --- a/go.sum +++ b/go.sum @@ -1445,8 +1445,8 @@ github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kN github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= -github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= -github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= +github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= +github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 12cb324064f..942d2c1dd2f 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -22,7 +22,7 @@ require ( github.com/smartcontractkit/chainlink-env v0.36.0 github.com/smartcontractkit/chainlink-testing-framework v1.15.3 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 - github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 + github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 github.com/smartcontractkit/ocr2keepers v0.7.10 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.9 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index fefc570179b..f36904df940 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2253,8 +2253,8 @@ github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kN github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= -github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829 h1:fzefK1SzoRSHzZduOCzIJ2kmkBMPKwIf3FgeBlw7Jjk= -github.com/smartcontractkit/libocr v0.0.0-20230802221916-2271752fa829/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= +github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= +github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= From dc7e03125cd04153743cc880a732248e958fe575 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Thu, 17 Aug 2023 21:01:50 -0400 Subject: [PATCH 207/270] Fixes a Race in OCR Test (#10252) * Fixes a Race in OCR Test * formatting * Cleanup and whoopsie * Update action * Docker update --- .github/actions/build-test-image/action.yml | 4 +- .github/workflows/integration-tests.yml | 6 +- integration-tests/docker/test_env/cl_node.go | 14 ++-- integration-tests/docker/test_env/geth.go | 8 ++- .../docker/test_env/mockserver.go | 3 +- integration-tests/docker/test_env/test_env.go | 67 +++++++++---------- .../docker/test_env/test_env_builder.go | 13 ++-- integration-tests/go.mod | 2 +- 8 files changed, 57 insertions(+), 60 deletions(-) diff --git a/.github/actions/build-test-image/action.yml b/.github/actions/build-test-image/action.yml index 6ee74eb5c18..29c9bbd0004 100644 --- a/.github/actions/build-test-image/action.yml +++ b/.github/actions/build-test-image/action.yml @@ -32,7 +32,7 @@ runs: steps: - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@ab595504ae9cf10c60eb8d2c5ce025284e58b210 #v2.1.5 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 with: repository: ${{ inputs.repository }} tag: ${{ inputs.tag }} @@ -40,7 +40,7 @@ runs: AWS_ROLE_TO_ASSUME: ${{ inputs.QA_AWS_ROLE_TO_ASSUME }} - name: Build and Publish Test Runner if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/docker/build-push@ab595504ae9cf10c60eb8d2c5ce025284e58b210 #v2.1.5 + uses: smartcontractkit/chainlink-github-actions/docker/build-push@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 with: tags: | ${{ inputs.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ inputs.QA_AWS_REGION }}.amazonaws.com/${{ inputs.repository }}:${{ inputs.tag }} diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 88b06566fa7..eb5bba7f2cc 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -86,7 +86,7 @@ jobs: - name: Check if image exists if: needs.changes.outputs.src == 'true' id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -94,7 +94,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' && needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -619,7 +619,7 @@ jobs: steps: - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 with: repository: chainlink-solana-tests tag: ${{ needs.get_solana_sha.outputs.sha }} diff --git a/integration-tests/docker/test_env/cl_node.go b/integration-tests/docker/test_env/cl_node.go index 88158450027..4d690e9dd76 100644 --- a/integration-tests/docker/test_env/cl_node.go +++ b/integration-tests/docker/test_env/cl_node.go @@ -12,25 +12,25 @@ import ( "sync" "time" + "github.com/ethereum/go-ethereum" + "github.com/ethereum/go-ethereum/common" "github.com/google/uuid" "github.com/pelletier/go-toml/v2" "github.com/pkg/errors" - - "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/common" "github.com/rs/zerolog/log" + tc "github.com/testcontainers/testcontainers-go" + tcwait "github.com/testcontainers/testcontainers-go/wait" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2/types" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" - tc "github.com/testcontainers/testcontainers-go" - tcwait "github.com/testcontainers/testcontainers-go/wait" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/utils" "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/chaintype" ) var ( diff --git a/integration-tests/docker/test_env/geth.go b/integration-tests/docker/test_env/geth.go index 8980a18c631..764f7acf418 100644 --- a/integration-tests/docker/test_env/geth.go +++ b/integration-tests/docker/test_env/geth.go @@ -4,17 +4,19 @@ import ( "context" "fmt" "os" + "time" "github.com/ethereum/go-ethereum/accounts" "github.com/ethereum/go-ethereum/accounts/keystore" "github.com/google/uuid" "github.com/pkg/errors" "github.com/rs/zerolog/log" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" - "time" + + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + + "github.com/smartcontractkit/chainlink/integration-tests/utils/templates" ) const ( diff --git a/integration-tests/docker/test_env/mockserver.go b/integration-tests/docker/test_env/mockserver.go index 76894aa098b..8a8f966678c 100644 --- a/integration-tests/docker/test_env/mockserver.go +++ b/integration-tests/docker/test_env/mockserver.go @@ -10,9 +10,10 @@ import ( "github.com/google/uuid" "github.com/pkg/errors" "github.com/rs/zerolog/log" - ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" tc "github.com/testcontainers/testcontainers-go" tcwait "github.com/testcontainers/testcontainers-go/wait" + + ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" ) type MockServer struct { diff --git a/integration-tests/docker/test_env/test_env.go b/integration-tests/docker/test_env/test_env.go index 12958f38da7..40e4c27bd2a 100644 --- a/integration-tests/docker/test_env/test_env.go +++ b/integration-tests/docker/test_env/test_env.go @@ -2,24 +2,22 @@ package test_env import ( "math/big" - "sync" - - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - "github.com/smartcontractkit/chainlink-testing-framework/docker/test_env" - - "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" "github.com/rs/zerolog/log" - "github.com/smartcontractkit/chainlink-testing-framework/logwatch" tc "github.com/testcontainers/testcontainers-go" - "go.uber.org/multierr" + "golang.org/x/sync/errgroup" + + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink-testing-framework/docker/test_env" + "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/integration-tests/client" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/docker" "github.com/smartcontractkit/chainlink/integration-tests/utils" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" ) var ( @@ -76,18 +74,18 @@ func (te *CLClusterTestEnv) ParallelTransactions(enabled bool) { te.EVMClient.ParallelTransactions(enabled) } -func (m *CLClusterTestEnv) WithPrivateGethChain(evmNetworks []blockchain.EVMNetwork) *CLClusterTestEnv { +func (te *CLClusterTestEnv) WithPrivateGethChain(evmNetworks []blockchain.EVMNetwork) *CLClusterTestEnv { var chains []test_env.PrivateGethChain for _, evmNetwork := range evmNetworks { n := evmNetwork - chains = append(chains, test_env.NewPrivateGethChain(&n, []string{m.Network.Name})) + chains = append(chains, test_env.NewPrivateGethChain(&n, []string{te.Network.Name})) } - m.PrivateGethChain = chains - return m + te.PrivateGethChain = chains + return te } -func (m *CLClusterTestEnv) StartPrivateGethChain() error { - for _, chain := range m.PrivateGethChain { +func (te *CLClusterTestEnv) StartPrivateGethChain() error { + for _, chain := range te.PrivateGethChain { err := chain.PrimaryNode.Start() if err != nil { return err @@ -118,20 +116,17 @@ func (te *CLClusterTestEnv) GetAPIs() []*client.ChainlinkClient { // StartClNodes start one bootstrap node and {count} OCR nodes func (te *CLClusterTestEnv) StartClNodes(nodeConfig *chainlink.Config, count int) error { - var wg sync.WaitGroup - var errs = []error{} - var mu sync.Mutex + eg := &errgroup.Group{} + nodes := make(chan *ClNode, count) // Start nodes for i := 0; i < count; i++ { - i := i - wg.Add(1) - go func() { - defer wg.Done() + nodeIndex := i + eg.Go(func() error { var nodeContainerName, dbContainerName string if te.Cfg != nil { - nodeContainerName = te.Cfg.Nodes[i].NodeContainerName - dbContainerName = te.Cfg.Nodes[i].DbContainerName + nodeContainerName = te.Cfg.Nodes[nodeIndex].NodeContainerName + dbContainerName = te.Cfg.Nodes[nodeIndex].DbContainerName } n := NewClNode([]string{te.Network.Name}, nodeConfig, WithNodeContainerName(nodeContainerName), @@ -139,22 +134,22 @@ func (te *CLClusterTestEnv) StartClNodes(nodeConfig *chainlink.Config, count int ) err := n.StartContainer() if err != nil { - mu.Lock() - errs = append(errs, err) - mu.Unlock() - } else { - mu.Lock() - te.CLNodes = append(te.CLNodes, n) - mu.Unlock() + return err } - }() + nodes <- n + return nil + }) } - wg.Wait() + if err := eg.Wait(); err != nil { + return err + } + close(nodes) - if len(errs) > 0 { - return multierr.Combine(errs...) + for node := range nodes { + te.CLNodes = append(te.CLNodes, node) } + return nil } @@ -194,7 +189,7 @@ func (te *CLClusterTestEnv) GetNodeCSAKeys() ([]string, error) { } func (te *CLClusterTestEnv) Terminate() error { - // TESTCONTAINERS_RYUK_DISABLED=false by defualt so ryuk will remove all + // TESTCONTAINERS_RYUK_DISABLED=false by default so ryuk will remove all // the containers and the Network return nil } diff --git a/integration-tests/docker/test_env/test_env_builder.go b/integration-tests/docker/test_env/test_env_builder.go index 9eb98ea23c3..04b9f44f3f7 100644 --- a/integration-tests/docker/test_env/test_env_builder.go +++ b/integration-tests/docker/test_env/test_env_builder.go @@ -5,16 +5,15 @@ import ( "os" "github.com/pkg/errors" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink-testing-framework/logwatch" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/integration-tests/contracts" "github.com/smartcontractkit/chainlink/integration-tests/networks" - - "github.com/rs/zerolog/log" - "github.com/smartcontractkit/chainlink/integration-tests/types/config/node" - "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" ) type CLTestEnvBuilder struct { @@ -69,9 +68,9 @@ func (b *CLTestEnvBuilder) WithGeth() *CLTestEnvBuilder { return b } -func (m *CLTestEnvBuilder) WithPrivateGethChains(evmNetworks []blockchain.EVMNetwork) *CLTestEnvBuilder { - m.nonDevGethNetworks = evmNetworks - return m +func (b *CLTestEnvBuilder) WithPrivateGethChains(evmNetworks []blockchain.EVMNetwork) *CLTestEnvBuilder { + b.nonDevGethNetworks = evmNetworks + return b } func (b *CLTestEnvBuilder) WithCLNodeConfig(cfg *chainlink.Config) *CLTestEnvBuilder { diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 942d2c1dd2f..e8f2b7138d7 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -31,7 +31,6 @@ require ( github.com/testcontainers/testcontainers-go v0.22.0 github.com/umbracle/ethgo v0.1.3 go.dedis.ch/kyber/v3 v3.1.0 - go.uber.org/multierr v1.11.0 go.uber.org/zap v1.24.0 golang.org/x/sync v0.3.0 gopkg.in/guregu/null.v4 v4.0.0 @@ -443,6 +442,7 @@ require ( go.starlark.net v0.0.0-20220817180228-f738f5508c12 // indirect go.uber.org/atomic v1.11.0 // indirect go.uber.org/goleak v1.2.1 // indirect + go.uber.org/multierr v1.11.0 // indirect go.uber.org/ratelimit v0.2.0 // indirect golang.org/x/arch v0.4.0 // indirect golang.org/x/crypto v0.11.0 // indirect From 7a4c442754cbd966809b9c07fb022d9d4cac8a6f Mon Sep 17 00:00:00 2001 From: David Cauchi <13139524+davidcauchi@users.noreply.github.com> Date: Fri, 18 Aug 2023 16:20:28 +0200 Subject: [PATCH 208/270] Scroll update toml config (#10243) * extended time setting, due to sporadic block production rate * Add toml config comment * make config-docs --- core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml | 6 +++++- core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml | 6 +++++- docs/CONFIG.md | 8 ++++---- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml b/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml index 63c08559016..b7d290feb89 100644 --- a/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml +++ b/core/chains/evm/config/toml/defaults/Scroll_Mainnet.toml @@ -1,11 +1,15 @@ ChainID = '534352' FinalityDepth = 1 -LogPollInterval = '3s' +# extended time setting, due to sporadic block production rate +LogPollInterval = '30s' MinIncomingConfirmations = 1 # Scroll only emits blocks when a new tx is received, so this method of liveness detection is not useful NoNewHeadsThreshold = '0' OCR.ContractConfirmations = 1 +[Transactions] +ResendAfterThreshold = '2m' + [GasEstimator] Mode = 'L2Suggested' # Scroll uses the L2Suggested estimator; we don't want to place any limits on the minimum gas price diff --git a/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml b/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml index 5a1a0f9ba7d..263f57c4c67 100644 --- a/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml +++ b/core/chains/evm/config/toml/defaults/Scroll_Sepolia.toml @@ -1,11 +1,15 @@ ChainID = '534351' FinalityDepth = 1 -LogPollInterval = '3s' +# extended time setting, due to sporadic block production rate +LogPollInterval = '30s' MinIncomingConfirmations = 1 # Scroll only emits blocks when a new tx is received, so this method of liveness detection is not useful NoNewHeadsThreshold = '0' OCR.ContractConfirmations = 1 +[Transactions] +ResendAfterThreshold = '2m' + [GasEstimator] Mode = 'L2Suggested' # Scroll uses the L2Suggested estimator; we don't want to place any limits on the minimum gas price diff --git a/docs/CONFIG.md b/docs/CONFIG.md index ab19672e668..57aed6862b5 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -4018,7 +4018,7 @@ BlockBackfillSkip = false FinalityDepth = 1 FinalityTagEnabled = false LogBackfillBatchSize = 1000 -LogPollInterval = '3s' +LogPollInterval = '30s' LogKeepBlocksDepth = 100000 MinIncomingConfirmations = 1 MinContractPayment = '0.00001 link' @@ -4033,7 +4033,7 @@ MaxInFlight = 16 MaxQueued = 250 ReaperInterval = '1h0m0s' ReaperThreshold = '168h0m0s' -ResendAfterThreshold = '1m0s' +ResendAfterThreshold = '2m0s' [BalanceMonitor] Enabled = true @@ -4095,7 +4095,7 @@ BlockBackfillSkip = false FinalityDepth = 1 FinalityTagEnabled = false LogBackfillBatchSize = 1000 -LogPollInterval = '3s' +LogPollInterval = '30s' LogKeepBlocksDepth = 100000 MinIncomingConfirmations = 1 MinContractPayment = '0.00001 link' @@ -4110,7 +4110,7 @@ MaxInFlight = 16 MaxQueued = 250 ReaperInterval = '1h0m0s' ReaperThreshold = '168h0m0s' -ResendAfterThreshold = '1m0s' +ResendAfterThreshold = '2m0s' [BalanceMonitor] Enabled = true From 0f0e2a099c6a6f754363238ffcddf187c4f98a35 Mon Sep 17 00:00:00 2001 From: Gheorghe Strimtu Date: Fri, 18 Aug 2023 17:28:25 +0300 Subject: [PATCH 209/270] Keepers 1.2 contract mocks (#10222) * Keepers 1.2 contract mocks * gas wrapper mock * integration-tests wrappers * prettier, more emits --- contracts/scripts/native_solc_compile_all_7 | 1 + .../native_solc_compile_all_automation | 2 + contracts/src/v0.7/KeeperRegistry1_1Mock.sol | 351 ++ .../mocks/KeeperRegistrar1_2Mock.sol | 122 + ...istryCheckUpkeepGasUsageWrapper1_2Mock.sol | 32 + .../gas_wrapper_mock/gas_wrapper_mock.go | 614 ++++ .../keeper_registrar_wrapper1_2_mock.go | 1492 ++++++++ .../keeper_registry_wrapper1_1_mock.go | 3083 +++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 3 + core/gethwrappers/go_generate.go | 3 + .../contracts/contract_deployer.go | 57 + .../contracts/contract_models.go | 30 + .../contracts/ethereum_contracts.go | 252 ++ 13 files changed, 6042 insertions(+) create mode 100644 contracts/src/v0.7/KeeperRegistry1_1Mock.sol create mode 100644 contracts/src/v0.8/automation/mocks/KeeperRegistrar1_2Mock.sol create mode 100644 contracts/src/v0.8/automation/mocks/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.sol create mode 100644 core/gethwrappers/generated/gas_wrapper_mock/gas_wrapper_mock.go create mode 100644 core/gethwrappers/generated/keeper_registrar_wrapper1_2_mock/keeper_registrar_wrapper1_2_mock.go create mode 100644 core/gethwrappers/generated/keeper_registry_wrapper1_1_mock/keeper_registry_wrapper1_1_mock.go diff --git a/contracts/scripts/native_solc_compile_all_7 b/contracts/scripts/native_solc_compile_all_7 index 090b0d8baee..b2d76b3cb5f 100755 --- a/contracts/scripts/native_solc_compile_all_7 +++ b/contracts/scripts/native_solc_compile_all_7 @@ -36,6 +36,7 @@ compileContract tests/VRFCoordinatorMock.sol # Keeper/Automation compileContract KeeperRegistry1_1.sol +compileContract KeeperRegistry1_1Mock.sol compileContract UpkeepRegistrationRequests.sol compileContract tests/UpkeepPerformCounterRestrictive.sol compileContract tests/UpkeepCounter.sol \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all_automation b/contracts/scripts/native_solc_compile_all_automation index 5c9c9e8811d..96dbc96c718 100755 --- a/contracts/scripts/native_solc_compile_all_automation +++ b/contracts/scripts/native_solc_compile_all_automation @@ -42,6 +42,8 @@ compileContract dev/automation/tests/LogUpkeepCounter.sol # Keepers x VRF v2 compileContract KeepersVRFConsumer.sol +compileContract automation/mocks/KeeperRegistrar1_2Mock.sol +compileContract automation/mocks/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.sol SOLC_VERSION="0.8.16" diff --git a/contracts/src/v0.7/KeeperRegistry1_1Mock.sol b/contracts/src/v0.7/KeeperRegistry1_1Mock.sol new file mode 100644 index 00000000000..3acbfb5e7af --- /dev/null +++ b/contracts/src/v0.7/KeeperRegistry1_1Mock.sol @@ -0,0 +1,351 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.7.0; + +contract KeeperRegistry1_1Mock { + event ConfigSet( + uint32 paymentPremiumPPB, + uint24 blockCountPerTurn, + uint32 checkGasLimit, + uint24 stalenessSeconds, + uint16 gasCeilingMultiplier, + uint256 fallbackGasPrice, + uint256 fallbackLinkPrice + ); + event FlatFeeSet(uint32 flatFeeMicroLink); + event FundsAdded(uint256 indexed id, address indexed from, uint96 amount); + event FundsWithdrawn(uint256 indexed id, uint256 amount, address to); + event KeepersUpdated(address[] keepers, address[] payees); + event OwnershipTransferRequested(address indexed from, address indexed to); + event OwnershipTransferred(address indexed from, address indexed to); + event Paused(address account); + event PayeeshipTransferRequested(address indexed keeper, address indexed from, address indexed to); + event PayeeshipTransferred(address indexed keeper, address indexed from, address indexed to); + event PaymentWithdrawn(address indexed keeper, uint256 indexed amount, address indexed to, address payee); + event RegistrarChanged(address indexed from, address indexed to); + event Unpaused(address account); + event UpkeepCanceled(uint256 indexed id, uint64 indexed atBlockHeight); + event UpkeepPerformed( + uint256 indexed id, + bool indexed success, + address indexed from, + uint96 payment, + bytes performData + ); + event UpkeepRegistered(uint256 indexed id, uint32 executeGas, address admin); + + function emitConfigSet( + uint32 paymentPremiumPPB, + uint24 blockCountPerTurn, + uint32 checkGasLimit, + uint24 stalenessSeconds, + uint16 gasCeilingMultiplier, + uint256 fallbackGasPrice, + uint256 fallbackLinkPrice + ) public { + emit ConfigSet( + paymentPremiumPPB, + blockCountPerTurn, + checkGasLimit, + stalenessSeconds, + gasCeilingMultiplier, + fallbackGasPrice, + fallbackLinkPrice + ); + } + + function emitFlatFeeSet(uint32 flatFeeMicroLink) public { + emit FlatFeeSet(flatFeeMicroLink); + } + + function emitFundsAdded(uint256 id, address from, uint96 amount) public { + emit FundsAdded(id, from, amount); + } + + function emitFundsWithdrawn(uint256 id, uint256 amount, address to) public { + emit FundsWithdrawn(id, amount, to); + } + + function emitKeepersUpdated(address[] memory keepers, address[] memory payees) public { + emit KeepersUpdated(keepers, payees); + } + + function emitOwnershipTransferRequested(address from, address to) public { + emit OwnershipTransferRequested(from, to); + } + + function emitOwnershipTransferred(address from, address to) public { + emit OwnershipTransferred(from, to); + } + + function emitPaused(address account) public { + emit Paused(account); + } + + function emitPayeeshipTransferRequested(address keeper, address from, address to) public { + emit PayeeshipTransferRequested(keeper, from, to); + } + + function emitPayeeshipTransferred(address keeper, address from, address to) public { + emit PayeeshipTransferred(keeper, from, to); + } + + function emitPaymentWithdrawn(address keeper, uint256 amount, address to, address payee) public { + emit PaymentWithdrawn(keeper, amount, to, payee); + } + + function emitRegistrarChanged(address from, address to) public { + emit RegistrarChanged(from, to); + } + + function emitUnpaused(address account) public { + emit Unpaused(account); + } + + function emitUpkeepCanceled(uint256 id, uint64 atBlockHeight) public { + emit UpkeepCanceled(id, atBlockHeight); + } + + function emitUpkeepPerformed( + uint256 id, + bool success, + address from, + uint96 payment, + bytes memory performData + ) public { + emit UpkeepPerformed(id, success, from, payment, performData); + } + + function emitUpkeepRegistered(uint256 id, uint32 executeGas, address admin) public { + emit UpkeepRegistered(id, executeGas, admin); + } + + uint256 private s_upkeepCount; + + // Function to set the current number of registered upkeeps + function setUpkeepCount(uint256 _upkeepCount) external { + s_upkeepCount = _upkeepCount; + } + + // Function to get the current number of registered upkeeps + function getUpkeepCount() external view returns (uint256) { + return s_upkeepCount; + } + + uint256[] private s_canceledUpkeepList; + + // Function to set the current number of canceled upkeeps + function setCanceledUpkeepList(uint256[] memory _canceledUpkeepList) external { + s_canceledUpkeepList = _canceledUpkeepList; + } + + // Function to set the current number of canceled upkeeps + function getCanceledUpkeepList() external view returns (uint256[] memory) { + return s_canceledUpkeepList; + } + + address[] private s_keeperList; + + // Function to set the keeper list for testing purposes + function setKeeperList(address[] memory _keepers) external { + s_keeperList = _keepers; + } + + // Function to get the keeper list + function getKeeperList() external view returns (address[] memory) { + return s_keeperList; + } + + struct Config { + uint32 paymentPremiumPPB; + uint32 flatFeeMicroLink; // min 0.000001 LINK, max 4294 LINK + uint24 blockCountPerTurn; + uint32 checkGasLimit; + uint24 stalenessSeconds; + uint16 gasCeilingMultiplier; + } + + Config private s_config; + uint256 private s_fallbackGasPrice; + uint256 private s_fallbackLinkPrice; + + // Function to set the configuration for testing purposes + function setConfig( + uint32 _paymentPremiumPPB, + uint32 _flatFeeMicroLink, + uint24 _blockCountPerTurn, + uint32 _checkGasLimit, + uint24 _stalenessSeconds, + uint16 _gasCeilingMultiplier, + uint256 _fallbackGasPrice, + uint256 _fallbackLinkPrice + ) external { + s_config.paymentPremiumPPB = _paymentPremiumPPB; + s_config.flatFeeMicroLink = _flatFeeMicroLink; + s_config.blockCountPerTurn = _blockCountPerTurn; + s_config.checkGasLimit = _checkGasLimit; + s_config.stalenessSeconds = _stalenessSeconds; + s_config.gasCeilingMultiplier = _gasCeilingMultiplier; + s_fallbackGasPrice = _fallbackGasPrice; + s_fallbackLinkPrice = _fallbackLinkPrice; + } + + // Function to get the configuration + function getConfig() + external + view + returns ( + uint32 paymentPremiumPPB, + uint24 blockCountPerTurn, + uint32 checkGasLimit, + uint24 stalenessSeconds, + uint16 gasCeilingMultiplier, + uint256 fallbackGasPrice, + uint256 fallbackLinkPrice + ) + { + return ( + s_config.paymentPremiumPPB, + s_config.blockCountPerTurn, + s_config.checkGasLimit, + s_config.stalenessSeconds, + s_config.gasCeilingMultiplier, + s_fallbackGasPrice, + s_fallbackLinkPrice + ); + } + + struct Upkeep { + address target; + uint32 executeGas; + uint96 balance; + address admin; + uint64 maxValidBlocknumber; + address lastKeeper; + } + + mapping(uint256 => Upkeep) private s_upkeep; + mapping(uint256 => bytes) private s_checkData; + + // Function to set the upkeep and checkData for testing purposes + function setUpkeep( + uint256 id, + address _target, + uint32 _executeGas, + uint96 _balance, + address _admin, + uint64 _maxValidBlocknumber, + address _lastKeeper, + bytes memory _checkData + ) external { + Upkeep memory upkeep = Upkeep({ + target: _target, + executeGas: _executeGas, + balance: _balance, + admin: _admin, + maxValidBlocknumber: _maxValidBlocknumber, + lastKeeper: _lastKeeper + }); + + s_upkeep[id] = upkeep; + s_checkData[id] = _checkData; + } + + // Function to get the upkeep and checkData + function getUpkeep( + uint256 id + ) + external + view + returns ( + address target, + uint32 executeGas, + bytes memory checkData, + uint96 balance, + address lastKeeper, + address admin, + uint64 maxValidBlocknumber + ) + { + Upkeep memory reg = s_upkeep[id]; + return ( + reg.target, + reg.executeGas, + s_checkData[id], + reg.balance, + reg.lastKeeper, + reg.admin, + reg.maxValidBlocknumber + ); + } + + mapping(uint256 => uint96) private s_minBalances; + + // Function to set the minimum balance for a specific upkeep id + function setMinBalance(uint256 id, uint96 minBalance) external { + s_minBalances[id] = minBalance; + } + + // Function to get the minimum balance for a specific upkeep id + function getMinBalanceForUpkeep(uint256 id) external view returns (uint96) { + return s_minBalances[id]; + } + + struct UpkeepData { + bytes performData; + uint256 maxLinkPayment; + uint256 gasLimit; + uint256 adjustedGasWei; + uint256 linkEth; + } + + mapping(uint256 => UpkeepData) private s_upkeepData; + + // Function to set mock data for the checkUpkeep function + function setCheckUpkeepData( + uint256 id, + bytes memory performData, + uint256 maxLinkPayment, + uint256 gasLimit, + uint256 adjustedGasWei, + uint256 linkEth + ) external { + s_upkeepData[id] = UpkeepData({ + performData: performData, + maxLinkPayment: maxLinkPayment, + gasLimit: gasLimit, + adjustedGasWei: adjustedGasWei, + linkEth: linkEth + }); + } + + // Mock checkUpkeep function + function checkUpkeep( + uint256 id, + address from + ) + external + view + returns ( + bytes memory performData, + uint256 maxLinkPayment, + uint256 gasLimit, + uint256 adjustedGasWei, + uint256 linkEth + ) + { + UpkeepData storage data = s_upkeepData[id]; + return (data.performData, data.maxLinkPayment, data.gasLimit, data.adjustedGasWei, data.linkEth); + } + + mapping(uint256 => bool) private s_upkeepSuccess; + + // Function to set mock return data for the performUpkeep function + function setPerformUpkeepSuccess(uint256 id, bool success) external { + s_upkeepSuccess[id] = success; + } + + // Mock performUpkeep function + function performUpkeep(uint256 id, bytes calldata performData) external returns (bool success) { + return s_upkeepSuccess[id]; + } +} diff --git a/contracts/src/v0.8/automation/mocks/KeeperRegistrar1_2Mock.sol b/contracts/src/v0.8/automation/mocks/KeeperRegistrar1_2Mock.sol new file mode 100644 index 00000000000..b147c98e9ae --- /dev/null +++ b/contracts/src/v0.8/automation/mocks/KeeperRegistrar1_2Mock.sol @@ -0,0 +1,122 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.6; + +contract KeeperRegistrar1_2Mock { + event AutoApproveAllowedSenderSet(address indexed senderAddress, bool allowed); + event ConfigChanged( + uint8 autoApproveConfigType, + uint32 autoApproveMaxAllowed, + address keeperRegistry, + uint96 minLINKJuels + ); + event OwnershipTransferRequested(address indexed from, address indexed to); + event OwnershipTransferred(address indexed from, address indexed to); + event RegistrationApproved(bytes32 indexed hash, string displayName, uint256 indexed upkeepId); + event RegistrationRejected(bytes32 indexed hash); + event RegistrationRequested( + bytes32 indexed hash, + string name, + bytes encryptedEmail, + address indexed upkeepContract, + uint32 gasLimit, + address adminAddress, + bytes checkData, + uint96 amount, + uint8 indexed source + ); + + function emitAutoApproveAllowedSenderSet(address senderAddress, bool allowed) public { + emit AutoApproveAllowedSenderSet(senderAddress, allowed); + } + + function emitConfigChanged( + uint8 autoApproveConfigType, + uint32 autoApproveMaxAllowed, + address keeperRegistry, + uint96 minLINKJuels + ) public { + emit ConfigChanged(autoApproveConfigType, autoApproveMaxAllowed, keeperRegistry, minLINKJuels); + } + + function emitOwnershipTransferRequested(address from, address to) public { + emit OwnershipTransferRequested(from, to); + } + + function emitOwnershipTransferred(address from, address to) public { + emit OwnershipTransferred(from, to); + } + + function emitRegistrationApproved(bytes32 hash, string memory displayName, uint256 upkeepId) public { + emit RegistrationApproved(hash, displayName, upkeepId); + } + + function emitRegistrationRejected(bytes32 hash) public { + emit RegistrationRejected(hash); + } + + function emitRegistrationRequested( + bytes32 hash, + string memory name, + bytes memory encryptedEmail, + address upkeepContract, + uint32 gasLimit, + address adminAddress, + bytes memory checkData, + uint96 amount, + uint8 source + ) public { + emit RegistrationRequested( + hash, + name, + encryptedEmail, + upkeepContract, + gasLimit, + adminAddress, + checkData, + amount, + source + ); + } + + enum AutoApproveType { + DISABLED, + ENABLED_SENDER_ALLOWLIST, + ENABLED_ALL + } + + AutoApproveType public s_autoApproveConfigType; + uint32 public s_autoApproveMaxAllowed; + uint32 public s_approvedCount; + address public s_keeperRegistry; + uint256 public s_minLINKJuels; + + // Function to set mock return data for the getRegistrationConfig function + function setRegistrationConfig( + AutoApproveType _autoApproveConfigType, + uint32 _autoApproveMaxAllowed, + uint32 _approvedCount, + address _keeperRegistry, + uint256 _minLINKJuels + ) external { + s_autoApproveConfigType = _autoApproveConfigType; + s_autoApproveMaxAllowed = _autoApproveMaxAllowed; + s_approvedCount = _approvedCount; + s_keeperRegistry = _keeperRegistry; + s_minLINKJuels = _minLINKJuels; + } + + // Mock getRegistrationConfig function + function getRegistrationConfig() + external + view + returns ( + AutoApproveType autoApproveConfigType, + uint32 autoApproveMaxAllowed, + uint32 approvedCount, + address keeperRegistry, + uint256 minLINKJuels + ) + { + return (s_autoApproveConfigType, s_autoApproveMaxAllowed, s_approvedCount, s_keeperRegistry, s_minLINKJuels); + } +} diff --git a/contracts/src/v0.8/automation/mocks/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.sol b/contracts/src/v0.8/automation/mocks/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.sol new file mode 100644 index 00000000000..87e93c637ee --- /dev/null +++ b/contracts/src/v0.8/automation/mocks/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.sol @@ -0,0 +1,32 @@ +// SPDX-License-Identifier: MIT + +pragma solidity ^0.8.6; + +contract KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock { + event OwnershipTransferRequested(address indexed from, address indexed to); + event OwnershipTransferred(address indexed from, address indexed to); + + function emitOwnershipTransferRequested(address from, address to) public { + emit OwnershipTransferRequested(from, to); + } + + function emitOwnershipTransferred(address from, address to) public { + emit OwnershipTransferred(from, to); + } + + bool public s_mockResult; + bytes public s_mockPayload; + uint256 public s_mockGas; + + // Function to set mock return data for the measureCheckGas function + function setMeasureCheckGasResult(bool result, bytes memory payload, uint256 gas) external { + s_mockResult = result; + s_mockPayload = payload; + s_mockGas = gas; + } + + // Mock measureCheckGas function + function measureCheckGas(uint256 id, address from) external returns (bool, bytes memory, uint256) { + return (s_mockResult, s_mockPayload, s_mockGas); + } +} diff --git a/core/gethwrappers/generated/gas_wrapper_mock/gas_wrapper_mock.go b/core/gethwrappers/generated/gas_wrapper_mock/gas_wrapper_mock.go new file mode 100644 index 00000000000..b0420097b43 --- /dev/null +++ b/core/gethwrappers/generated/gas_wrapper_mock/gas_wrapper_mock.go @@ -0,0 +1,614 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package gas_wrapper_mock + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var KeeperRegistryCheckUpkeepGasUsageWrapperMockMetaData = &bind.MetaData{ + ABI: "[{\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"measureCheckGas\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_mockGas\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_mockPayload\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_mockResult\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"result\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"gas\",\"type\":\"uint256\"}],\"name\":\"setMeasureCheckGasResult\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b506106b9806100206000396000f3fe608060405234801561001057600080fd5b506004361061007d5760003560e01c8063846811931161005b57806384681193146100d5578063b019b4e8146100f2578063b023145014610105578063f7420bc21461011a57600080fd5b80632dae06f51461008257806356343496146100975780636bf49030146100b3575b600080fd5b610095610090366004610466565b61012d565b005b6100a060025481565b6040519081526020015b60405180910390f35b6100c66100c1366004610556565b610174565b6040516100aa939291906105e4565b6000546100e29060ff1681565b60405190151581526020016100aa565b610095610100366004610433565b610227565b61010d610285565b6040516100aa919061060f565b610095610128366004610433565b610313565b600080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016841515179055815161016c906001906020850190610371565b506002555050565b6000606060008060009054906101000a900460ff16600160025481805461019a90610629565b80601f01602080910402602001604051908101604052809291908181526020018280546101c690610629565b80156102135780601f106101e857610100808354040283529160200191610213565b820191906000526020600020905b8154815290600101906020018083116101f657829003601f168201915b505050505091509250925092509250925092565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b6001805461029290610629565b80601f01602080910402602001604051908101604052809291908181526020018280546102be90610629565b801561030b5780601f106102e05761010080835404028352916020019161030b565b820191906000526020600020905b8154815290600101906020018083116102ee57829003601f168201915b505050505081565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a35050565b82805461037d90610629565b90600052602060002090601f01602090048101928261039f57600085556103e5565b82601f106103b857805160ff19168380011785556103e5565b828001600101855582156103e5579182015b828111156103e55782518255916020019190600101906103ca565b506103f19291506103f5565b5090565b5b808211156103f157600081556001016103f6565b803573ffffffffffffffffffffffffffffffffffffffff8116811461042e57600080fd5b919050565b6000806040838503121561044657600080fd5b61044f8361040a565b915061045d6020840161040a565b90509250929050565b60008060006060848603121561047b57600080fd5b8335801515811461048b57600080fd5b9250602084013567ffffffffffffffff808211156104a857600080fd5b818601915086601f8301126104bc57600080fd5b8135818111156104ce576104ce61067d565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019083821181831017156105145761051461067d565b8160405282815289602084870101111561052d57600080fd5b826020860160208301376000602084830101528096505050505050604084013590509250925092565b6000806040838503121561056957600080fd5b8235915061045d6020840161040a565b6000815180845260005b8181101561059f57602081850181015186830182015201610583565b818111156105b1576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b83151581526060602082015260006105ff6060830185610579565b9050826040830152949350505050565b6020815260006106226020830184610579565b9392505050565b600181811c9082168061063d57607f821691505b60208210811415610677577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var KeeperRegistryCheckUpkeepGasUsageWrapperMockABI = KeeperRegistryCheckUpkeepGasUsageWrapperMockMetaData.ABI + +var KeeperRegistryCheckUpkeepGasUsageWrapperMockBin = KeeperRegistryCheckUpkeepGasUsageWrapperMockMetaData.Bin + +func DeployKeeperRegistryCheckUpkeepGasUsageWrapperMock(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *KeeperRegistryCheckUpkeepGasUsageWrapperMock, error) { + parsed, err := KeeperRegistryCheckUpkeepGasUsageWrapperMockMetaData.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(KeeperRegistryCheckUpkeepGasUsageWrapperMockBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &KeeperRegistryCheckUpkeepGasUsageWrapperMock{KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller: KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller{contract: contract}, KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor: KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor{contract: contract}, KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer: KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer{contract: contract}}, nil +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMock struct { + address common.Address + abi abi.ABI + KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller + KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor + KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller struct { + contract *bind.BoundContract +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor struct { + contract *bind.BoundContract +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer struct { + contract *bind.BoundContract +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockSession struct { + Contract *KeeperRegistryCheckUpkeepGasUsageWrapperMock + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockCallerSession struct { + Contract *KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller + CallOpts bind.CallOpts +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorSession struct { + Contract *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor + TransactOpts bind.TransactOpts +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockRaw struct { + Contract *KeeperRegistryCheckUpkeepGasUsageWrapperMock +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockCallerRaw struct { + Contract *KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorRaw struct { + Contract *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor +} + +func NewKeeperRegistryCheckUpkeepGasUsageWrapperMock(address common.Address, backend bind.ContractBackend) (*KeeperRegistryCheckUpkeepGasUsageWrapperMock, error) { + abi, err := abi.JSON(strings.NewReader(KeeperRegistryCheckUpkeepGasUsageWrapperMockABI)) + if err != nil { + return nil, err + } + contract, err := bindKeeperRegistryCheckUpkeepGasUsageWrapperMock(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &KeeperRegistryCheckUpkeepGasUsageWrapperMock{address: address, abi: abi, KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller: KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller{contract: contract}, KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor: KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor{contract: contract}, KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer: KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer{contract: contract}}, nil +} + +func NewKeeperRegistryCheckUpkeepGasUsageWrapperMockCaller(address common.Address, caller bind.ContractCaller) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller, error) { + contract, err := bindKeeperRegistryCheckUpkeepGasUsageWrapperMock(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller{contract: contract}, nil +} + +func NewKeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor(address common.Address, transactor bind.ContractTransactor) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor, error) { + contract, err := bindKeeperRegistryCheckUpkeepGasUsageWrapperMock(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor{contract: contract}, nil +} + +func NewKeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer(address common.Address, filterer bind.ContractFilterer) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer, error) { + contract, err := bindKeeperRegistryCheckUpkeepGasUsageWrapperMock(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer{contract: contract}, nil +} + +func bindKeeperRegistryCheckUpkeepGasUsageWrapperMock(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := KeeperRegistryCheckUpkeepGasUsageWrapperMockMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller.contract.Call(opts, result, method, params...) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor.contract.Transfer(opts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor.contract.Transact(opts, method, params...) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.contract.Call(opts, result, method, params...) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.contract.Transfer(opts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.contract.Transact(opts, method, params...) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller) SMockGas(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Call(opts, &out, "s_mockGas") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) SMockGas() (*big.Int, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SMockGas(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.CallOpts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCallerSession) SMockGas() (*big.Int, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SMockGas(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.CallOpts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller) SMockPayload(opts *bind.CallOpts) ([]byte, error) { + var out []interface{} + err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Call(opts, &out, "s_mockPayload") + + if err != nil { + return *new([]byte), err + } + + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) + + return out0, err + +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) SMockPayload() ([]byte, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SMockPayload(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.CallOpts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCallerSession) SMockPayload() ([]byte, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SMockPayload(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.CallOpts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCaller) SMockResult(opts *bind.CallOpts) (bool, error) { + var out []interface{} + err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Call(opts, &out, "s_mockResult") + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) SMockResult() (bool, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SMockResult(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.CallOpts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockCallerSession) SMockResult() (bool, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SMockResult(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.CallOpts) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor) EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Transact(opts, "emitOwnershipTransferRequested", from, to) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.EmitOwnershipTransferRequested(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, from, to) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.EmitOwnershipTransferRequested(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, from, to) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor) EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Transact(opts, "emitOwnershipTransferred", from, to) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.EmitOwnershipTransferred(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, from, to) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.EmitOwnershipTransferred(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, from, to) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor) MeasureCheckGas(opts *bind.TransactOpts, id *big.Int, from common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Transact(opts, "measureCheckGas", id, from) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) MeasureCheckGas(id *big.Int, from common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.MeasureCheckGas(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, id, from) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorSession) MeasureCheckGas(id *big.Int, from common.Address) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.MeasureCheckGas(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, id, from) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactor) SetMeasureCheckGasResult(opts *bind.TransactOpts, result bool, payload []byte, gas *big.Int) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.Transact(opts, "setMeasureCheckGasResult", result, payload, gas) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockSession) SetMeasureCheckGasResult(result bool, payload []byte, gas *big.Int) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SetMeasureCheckGasResult(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, result, payload, gas) +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockTransactorSession) SetMeasureCheckGasResult(result bool, payload []byte, gas *big.Int) (*types.Transaction, error) { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.Contract.SetMeasureCheckGasResult(&_KeeperRegistryCheckUpkeepGasUsageWrapperMock.TransactOpts, result, payload, gas) +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator struct { + Event *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested) + 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(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested) + 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 *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator{contract: _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested) + if err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer) ParseOwnershipTransferRequested(log types.Log) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested, error) { + event := new(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested) + if err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator struct { + Event *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred) + 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(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred) + 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 *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator{contract: _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred) + if err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.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 (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMockFilterer) ParseOwnershipTransferred(log types.Log) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred, error) { + event := new(KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred) + if err := _KeeperRegistryCheckUpkeepGasUsageWrapperMock.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMock) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _KeeperRegistryCheckUpkeepGasUsageWrapperMock.abi.Events["OwnershipTransferRequested"].ID: + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.ParseOwnershipTransferRequested(log) + case _KeeperRegistryCheckUpkeepGasUsageWrapperMock.abi.Events["OwnershipTransferred"].ID: + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.ParseOwnershipTransferred(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (_KeeperRegistryCheckUpkeepGasUsageWrapperMock *KeeperRegistryCheckUpkeepGasUsageWrapperMock) Address() common.Address { + return _KeeperRegistryCheckUpkeepGasUsageWrapperMock.address +} + +type KeeperRegistryCheckUpkeepGasUsageWrapperMockInterface interface { + SMockGas(opts *bind.CallOpts) (*big.Int, error) + + SMockPayload(opts *bind.CallOpts) ([]byte, error) + + SMockResult(opts *bind.CallOpts) (bool, error) + + EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + MeasureCheckGas(opts *bind.TransactOpts, id *big.Int, from common.Address) (*types.Transaction, error) + + SetMeasureCheckGasResult(opts *bind.TransactOpts, result bool, payload []byte, gas *big.Int) (*types.Transaction, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*KeeperRegistryCheckUpkeepGasUsageWrapperMockOwnershipTransferred, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generated/keeper_registrar_wrapper1_2_mock/keeper_registrar_wrapper1_2_mock.go b/core/gethwrappers/generated/keeper_registrar_wrapper1_2_mock/keeper_registrar_wrapper1_2_mock.go new file mode 100644 index 00000000000..ea4c49f7c88 --- /dev/null +++ b/core/gethwrappers/generated/keeper_registrar_wrapper1_2_mock/keeper_registrar_wrapper1_2_mock.go @@ -0,0 +1,1492 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package keeper_registrar_wrapper1_2_mock + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var KeeperRegistrarMockMetaData = &bind.MetaData{ + ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"AutoApproveAllowedSenderSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"autoApproveConfigType\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"minLINKJuels\",\"type\":\"uint96\"}],\"name\":\"ConfigChanged\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"displayName\",\"type\":\"string\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"RegistrationApproved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"}],\"name\":\"RegistrationRejected\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"encryptedEmail\",\"type\":\"bytes\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"upkeepContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"indexed\":true,\"internalType\":\"uint8\",\"name\":\"source\",\"type\":\"uint8\"}],\"name\":\"RegistrationRequested\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"senderAddress\",\"type\":\"address\"},{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"}],\"name\":\"emitAutoApproveAllowedSenderSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"autoApproveConfigType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"minLINKJuels\",\"type\":\"uint96\"}],\"name\":\"emitConfigChanged\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"displayName\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"emitRegistrationApproved\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"}],\"name\":\"emitRegistrationRejected\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"hash\",\"type\":\"bytes32\"},{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedEmail\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"upkeepContract\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"},{\"internalType\":\"uint8\",\"name\":\"source\",\"type\":\"uint8\"}],\"name\":\"emitRegistrationRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getRegistrationConfig\",\"outputs\":[{\"internalType\":\"enumKeeperRegistrar1_2Mock.AutoApproveType\",\"name\":\"autoApproveConfigType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"autoApproveMaxAllowed\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"approvedCount\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"keeperRegistry\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"minLINKJuels\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_approvedCount\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_autoApproveConfigType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistrar1_2Mock.AutoApproveType\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_autoApproveMaxAllowed\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_keeperRegistry\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_minLINKJuels\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistrar1_2Mock.AutoApproveType\",\"name\":\"_autoApproveConfigType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"_autoApproveMaxAllowed\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"_approvedCount\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"_keeperRegistry\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"_minLINKJuels\",\"type\":\"uint256\"}],\"name\":\"setRegistrationConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610ba0806100206000396000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c8063aee052f31161008c578063b59d75eb11610066578063b59d75eb14610259578063bb98fe561461026c578063ca40bcd314610285578063f7420bc21461029857600080fd5b8063aee052f314610220578063b019b4e814610233578063b49fd35b1461024657600080fd5b806384638bb6116100c857806384638bb61461014a578063850af0cb146101645780639e105f95146101bb578063adeab0b71461020d57600080fd5b80631701f938146100ef5780634882b5bd1461010457806355e8b24814610120575b600080fd5b6101026100fd36600461093a565b6102ab565b005b61010d60015481565b6040519081526020015b60405180910390f35b60005461013590610100900463ffffffff1681565b60405163ffffffff9091168152602001610117565b6000546101579060ff1681565b6040516101179190610a34565b6000546001546040516101179260ff811692610100820463ffffffff90811693650100000000008404909116926901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff169190610a48565b6000546101e8906901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610117565b61010261021b366004610789565b610322565b61010261022e366004610888565b610350565b61010261024136600461071a565b61038e565b6101026102543660046108d8565b6103ec565b6101026102673660046107a2565b6104e9565b6000546101359065010000000000900463ffffffff1681565b61010261029336600461074d565b610551565b6101026102a636600461071a565b6105a7565b6040805160ff8616815263ffffffff8516602082015273ffffffffffffffffffffffffffffffffffffffff8416818301526bffffffffffffffffffffffff8316606082015290517f6293a703ec7145dfa23c5cde2e627d6a02e153fc2e9c03b14d1e22cbb4a7e9cd9181900360800190a150505050565b60405181907f3663fb28ebc87645eb972c9dad8521bf665c623f287e79f1c56f1eb374b82a2290600090a250565b80837fb9a292fb7e3edd920cd2d2829a3615a640c43fd7de0a0820aa0668feb4c37d4b846040516103819190610a98565b60405180910390a3505050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b600080548691907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016600183600281111561042957610429610b35565b0217905550600080547fffffffffffffffffffffffffffffffffffffffffffffff0000000000000000ff1661010063ffffffff968716027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff1617650100000000009490951693909302939093177fffffff0000000000000000000000000000000000000000ffffffffffffffffff16690100000000000000000073ffffffffffffffffffffffffffffffffffffffff929092169190910217905560015550565b8060ff168673ffffffffffffffffffffffffffffffffffffffff168a7fc3f5df4aefec026f610a3fcb08f19476492d69d2cb78b1c2eba259a8820e6a788b8b8a8a8a8a60405161053e96959493929190610ab2565b60405180910390a4505050505050505050565b8173ffffffffffffffffffffffffffffffffffffffff167f20c6237dac83526a849285a9f79d08a483291bdd3a056a0ef9ae94ecee1ad3568260405161059b911515815260200190565b60405180910390a25050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a35050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461062957600080fd5b919050565b600082601f83011261063f57600080fd5b813567ffffffffffffffff8082111561065a5761065a610b64565b604051601f83017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f011681019082821181831017156106a0576106a0610b64565b816040528381528660208588010111156106b957600080fd5b836020870160208301376000602085830101528094505050505092915050565b803563ffffffff8116811461062957600080fd5b803560ff8116811461062957600080fd5b80356bffffffffffffffffffffffff8116811461062957600080fd5b6000806040838503121561072d57600080fd5b61073683610605565b915061074460208401610605565b90509250929050565b6000806040838503121561076057600080fd5b61076983610605565b91506020830135801515811461077e57600080fd5b809150509250929050565b60006020828403121561079b57600080fd5b5035919050565b60008060008060008060008060006101208a8c0312156107c157600080fd5b8935985060208a013567ffffffffffffffff808211156107e057600080fd5b6107ec8d838e0161062e565b995060408c013591508082111561080257600080fd5b61080e8d838e0161062e565b985061081c60608d01610605565b975061082a60808d016106d9565b965061083860a08d01610605565b955060c08c013591508082111561084e57600080fd5b5061085b8c828d0161062e565b93505061086a60e08b016106fe565b91506108796101008b016106ed565b90509295985092959850929598565b60008060006060848603121561089d57600080fd5b83359250602084013567ffffffffffffffff8111156108bb57600080fd5b6108c78682870161062e565b925050604084013590509250925092565b600080600080600060a086880312156108f057600080fd5b8535600381106108ff57600080fd5b945061090d602087016106d9565b935061091b604087016106d9565b925061092960608701610605565b949793965091946080013592915050565b6000806000806080858703121561095057600080fd5b610959856106ed565b9350610967602086016106d9565b925061097560408601610605565b9150610983606086016106fe565b905092959194509250565b6000815180845260005b818110156109b457602081850181015186830182015201610998565b818111156109c6576000602083870101525b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b60038110610a30577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60208101610a4282846109f9565b92915050565b60a08101610a5682886109f9565b63ffffffff808716602084015280861660408401525073ffffffffffffffffffffffffffffffffffffffff841660608301528260808301529695505050505050565b602081526000610aab602083018461098e565b9392505050565b60c081526000610ac560c083018961098e565b8281036020840152610ad7818961098e565b905063ffffffff8716604084015273ffffffffffffffffffffffffffffffffffffffff861660608401528281036080840152610b13818661098e565b9150506bffffffffffffffffffffffff831660a0830152979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fdfea164736f6c6343000806000a", +} + +var KeeperRegistrarMockABI = KeeperRegistrarMockMetaData.ABI + +var KeeperRegistrarMockBin = KeeperRegistrarMockMetaData.Bin + +func DeployKeeperRegistrarMock(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *KeeperRegistrarMock, error) { + parsed, err := KeeperRegistrarMockMetaData.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(KeeperRegistrarMockBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &KeeperRegistrarMock{KeeperRegistrarMockCaller: KeeperRegistrarMockCaller{contract: contract}, KeeperRegistrarMockTransactor: KeeperRegistrarMockTransactor{contract: contract}, KeeperRegistrarMockFilterer: KeeperRegistrarMockFilterer{contract: contract}}, nil +} + +type KeeperRegistrarMock struct { + address common.Address + abi abi.ABI + KeeperRegistrarMockCaller + KeeperRegistrarMockTransactor + KeeperRegistrarMockFilterer +} + +type KeeperRegistrarMockCaller struct { + contract *bind.BoundContract +} + +type KeeperRegistrarMockTransactor struct { + contract *bind.BoundContract +} + +type KeeperRegistrarMockFilterer struct { + contract *bind.BoundContract +} + +type KeeperRegistrarMockSession struct { + Contract *KeeperRegistrarMock + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type KeeperRegistrarMockCallerSession struct { + Contract *KeeperRegistrarMockCaller + CallOpts bind.CallOpts +} + +type KeeperRegistrarMockTransactorSession struct { + Contract *KeeperRegistrarMockTransactor + TransactOpts bind.TransactOpts +} + +type KeeperRegistrarMockRaw struct { + Contract *KeeperRegistrarMock +} + +type KeeperRegistrarMockCallerRaw struct { + Contract *KeeperRegistrarMockCaller +} + +type KeeperRegistrarMockTransactorRaw struct { + Contract *KeeperRegistrarMockTransactor +} + +func NewKeeperRegistrarMock(address common.Address, backend bind.ContractBackend) (*KeeperRegistrarMock, error) { + abi, err := abi.JSON(strings.NewReader(KeeperRegistrarMockABI)) + if err != nil { + return nil, err + } + contract, err := bindKeeperRegistrarMock(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &KeeperRegistrarMock{address: address, abi: abi, KeeperRegistrarMockCaller: KeeperRegistrarMockCaller{contract: contract}, KeeperRegistrarMockTransactor: KeeperRegistrarMockTransactor{contract: contract}, KeeperRegistrarMockFilterer: KeeperRegistrarMockFilterer{contract: contract}}, nil +} + +func NewKeeperRegistrarMockCaller(address common.Address, caller bind.ContractCaller) (*KeeperRegistrarMockCaller, error) { + contract, err := bindKeeperRegistrarMock(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockCaller{contract: contract}, nil +} + +func NewKeeperRegistrarMockTransactor(address common.Address, transactor bind.ContractTransactor) (*KeeperRegistrarMockTransactor, error) { + contract, err := bindKeeperRegistrarMock(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockTransactor{contract: contract}, nil +} + +func NewKeeperRegistrarMockFilterer(address common.Address, filterer bind.ContractFilterer) (*KeeperRegistrarMockFilterer, error) { + contract, err := bindKeeperRegistrarMock(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockFilterer{contract: contract}, nil +} + +func bindKeeperRegistrarMock(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := KeeperRegistrarMockMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _KeeperRegistrarMock.Contract.KeeperRegistrarMockCaller.contract.Call(opts, result, method, params...) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.KeeperRegistrarMockTransactor.contract.Transfer(opts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.KeeperRegistrarMockTransactor.contract.Transact(opts, method, params...) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _KeeperRegistrarMock.Contract.contract.Call(opts, result, method, params...) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.contract.Transfer(opts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.contract.Transact(opts, method, params...) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCaller) GetRegistrationConfig(opts *bind.CallOpts) (GetRegistrationConfig, + + error) { + var out []interface{} + err := _KeeperRegistrarMock.contract.Call(opts, &out, "getRegistrationConfig") + + outstruct := new(GetRegistrationConfig) + if err != nil { + return *outstruct, err + } + + outstruct.AutoApproveConfigType = *abi.ConvertType(out[0], new(uint8)).(*uint8) + outstruct.AutoApproveMaxAllowed = *abi.ConvertType(out[1], new(uint32)).(*uint32) + outstruct.ApprovedCount = *abi.ConvertType(out[2], new(uint32)).(*uint32) + outstruct.KeeperRegistry = *abi.ConvertType(out[3], new(common.Address)).(*common.Address) + outstruct.MinLINKJuels = *abi.ConvertType(out[4], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) GetRegistrationConfig() (GetRegistrationConfig, + + error) { + return _KeeperRegistrarMock.Contract.GetRegistrationConfig(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerSession) GetRegistrationConfig() (GetRegistrationConfig, + + error) { + return _KeeperRegistrarMock.Contract.GetRegistrationConfig(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCaller) SApprovedCount(opts *bind.CallOpts) (uint32, error) { + var out []interface{} + err := _KeeperRegistrarMock.contract.Call(opts, &out, "s_approvedCount") + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) SApprovedCount() (uint32, error) { + return _KeeperRegistrarMock.Contract.SApprovedCount(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerSession) SApprovedCount() (uint32, error) { + return _KeeperRegistrarMock.Contract.SApprovedCount(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCaller) SAutoApproveConfigType(opts *bind.CallOpts) (uint8, error) { + var out []interface{} + err := _KeeperRegistrarMock.contract.Call(opts, &out, "s_autoApproveConfigType") + + if err != nil { + return *new(uint8), err + } + + out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) + + return out0, err + +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) SAutoApproveConfigType() (uint8, error) { + return _KeeperRegistrarMock.Contract.SAutoApproveConfigType(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerSession) SAutoApproveConfigType() (uint8, error) { + return _KeeperRegistrarMock.Contract.SAutoApproveConfigType(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCaller) SAutoApproveMaxAllowed(opts *bind.CallOpts) (uint32, error) { + var out []interface{} + err := _KeeperRegistrarMock.contract.Call(opts, &out, "s_autoApproveMaxAllowed") + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) SAutoApproveMaxAllowed() (uint32, error) { + return _KeeperRegistrarMock.Contract.SAutoApproveMaxAllowed(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerSession) SAutoApproveMaxAllowed() (uint32, error) { + return _KeeperRegistrarMock.Contract.SAutoApproveMaxAllowed(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCaller) SKeeperRegistry(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _KeeperRegistrarMock.contract.Call(opts, &out, "s_keeperRegistry") + + if err != nil { + return *new(common.Address), err + } + + out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + + return out0, err + +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) SKeeperRegistry() (common.Address, error) { + return _KeeperRegistrarMock.Contract.SKeeperRegistry(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerSession) SKeeperRegistry() (common.Address, error) { + return _KeeperRegistrarMock.Contract.SKeeperRegistry(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCaller) SMinLINKJuels(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _KeeperRegistrarMock.contract.Call(opts, &out, "s_minLINKJuels") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) SMinLINKJuels() (*big.Int, error) { + return _KeeperRegistrarMock.Contract.SMinLINKJuels(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockCallerSession) SMinLINKJuels() (*big.Int, error) { + return _KeeperRegistrarMock.Contract.SMinLINKJuels(&_KeeperRegistrarMock.CallOpts) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitAutoApproveAllowedSenderSet(opts *bind.TransactOpts, senderAddress common.Address, allowed bool) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitAutoApproveAllowedSenderSet", senderAddress, allowed) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitAutoApproveAllowedSenderSet(senderAddress common.Address, allowed bool) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitAutoApproveAllowedSenderSet(&_KeeperRegistrarMock.TransactOpts, senderAddress, allowed) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitAutoApproveAllowedSenderSet(senderAddress common.Address, allowed bool) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitAutoApproveAllowedSenderSet(&_KeeperRegistrarMock.TransactOpts, senderAddress, allowed) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitConfigChanged(opts *bind.TransactOpts, autoApproveConfigType uint8, autoApproveMaxAllowed uint32, keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitConfigChanged", autoApproveConfigType, autoApproveMaxAllowed, keeperRegistry, minLINKJuels) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitConfigChanged(autoApproveConfigType uint8, autoApproveMaxAllowed uint32, keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitConfigChanged(&_KeeperRegistrarMock.TransactOpts, autoApproveConfigType, autoApproveMaxAllowed, keeperRegistry, minLINKJuels) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitConfigChanged(autoApproveConfigType uint8, autoApproveMaxAllowed uint32, keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitConfigChanged(&_KeeperRegistrarMock.TransactOpts, autoApproveConfigType, autoApproveMaxAllowed, keeperRegistry, minLINKJuels) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitOwnershipTransferRequested", from, to) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitOwnershipTransferRequested(&_KeeperRegistrarMock.TransactOpts, from, to) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitOwnershipTransferRequested(&_KeeperRegistrarMock.TransactOpts, from, to) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitOwnershipTransferred", from, to) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitOwnershipTransferred(&_KeeperRegistrarMock.TransactOpts, from, to) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitOwnershipTransferred(&_KeeperRegistrarMock.TransactOpts, from, to) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitRegistrationApproved(opts *bind.TransactOpts, hash [32]byte, displayName string, upkeepId *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitRegistrationApproved", hash, displayName, upkeepId) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitRegistrationApproved(hash [32]byte, displayName string, upkeepId *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitRegistrationApproved(&_KeeperRegistrarMock.TransactOpts, hash, displayName, upkeepId) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitRegistrationApproved(hash [32]byte, displayName string, upkeepId *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitRegistrationApproved(&_KeeperRegistrarMock.TransactOpts, hash, displayName, upkeepId) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitRegistrationRejected(opts *bind.TransactOpts, hash [32]byte) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitRegistrationRejected", hash) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitRegistrationRejected(hash [32]byte) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitRegistrationRejected(&_KeeperRegistrarMock.TransactOpts, hash) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitRegistrationRejected(hash [32]byte) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitRegistrationRejected(&_KeeperRegistrarMock.TransactOpts, hash) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) EmitRegistrationRequested(opts *bind.TransactOpts, hash [32]byte, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, checkData []byte, amount *big.Int, source uint8) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "emitRegistrationRequested", hash, name, encryptedEmail, upkeepContract, gasLimit, adminAddress, checkData, amount, source) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) EmitRegistrationRequested(hash [32]byte, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, checkData []byte, amount *big.Int, source uint8) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitRegistrationRequested(&_KeeperRegistrarMock.TransactOpts, hash, name, encryptedEmail, upkeepContract, gasLimit, adminAddress, checkData, amount, source) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) EmitRegistrationRequested(hash [32]byte, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, checkData []byte, amount *big.Int, source uint8) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.EmitRegistrationRequested(&_KeeperRegistrarMock.TransactOpts, hash, name, encryptedEmail, upkeepContract, gasLimit, adminAddress, checkData, amount, source) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactor) SetRegistrationConfig(opts *bind.TransactOpts, _autoApproveConfigType uint8, _autoApproveMaxAllowed uint32, _approvedCount uint32, _keeperRegistry common.Address, _minLINKJuels *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.contract.Transact(opts, "setRegistrationConfig", _autoApproveConfigType, _autoApproveMaxAllowed, _approvedCount, _keeperRegistry, _minLINKJuels) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockSession) SetRegistrationConfig(_autoApproveConfigType uint8, _autoApproveMaxAllowed uint32, _approvedCount uint32, _keeperRegistry common.Address, _minLINKJuels *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.SetRegistrationConfig(&_KeeperRegistrarMock.TransactOpts, _autoApproveConfigType, _autoApproveMaxAllowed, _approvedCount, _keeperRegistry, _minLINKJuels) +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockTransactorSession) SetRegistrationConfig(_autoApproveConfigType uint8, _autoApproveMaxAllowed uint32, _approvedCount uint32, _keeperRegistry common.Address, _minLINKJuels *big.Int) (*types.Transaction, error) { + return _KeeperRegistrarMock.Contract.SetRegistrationConfig(&_KeeperRegistrarMock.TransactOpts, _autoApproveConfigType, _autoApproveMaxAllowed, _approvedCount, _keeperRegistry, _minLINKJuels) +} + +type KeeperRegistrarMockAutoApproveAllowedSenderSetIterator struct { + Event *KeeperRegistrarMockAutoApproveAllowedSenderSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockAutoApproveAllowedSenderSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockAutoApproveAllowedSenderSet) + 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(KeeperRegistrarMockAutoApproveAllowedSenderSet) + 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 *KeeperRegistrarMockAutoApproveAllowedSenderSetIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockAutoApproveAllowedSenderSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockAutoApproveAllowedSenderSet struct { + SenderAddress common.Address + Allowed bool + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterAutoApproveAllowedSenderSet(opts *bind.FilterOpts, senderAddress []common.Address) (*KeeperRegistrarMockAutoApproveAllowedSenderSetIterator, error) { + + var senderAddressRule []interface{} + for _, senderAddressItem := range senderAddress { + senderAddressRule = append(senderAddressRule, senderAddressItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "AutoApproveAllowedSenderSet", senderAddressRule) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockAutoApproveAllowedSenderSetIterator{contract: _KeeperRegistrarMock.contract, event: "AutoApproveAllowedSenderSet", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchAutoApproveAllowedSenderSet(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockAutoApproveAllowedSenderSet, senderAddress []common.Address) (event.Subscription, error) { + + var senderAddressRule []interface{} + for _, senderAddressItem := range senderAddress { + senderAddressRule = append(senderAddressRule, senderAddressItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "AutoApproveAllowedSenderSet", senderAddressRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockAutoApproveAllowedSenderSet) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "AutoApproveAllowedSenderSet", 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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseAutoApproveAllowedSenderSet(log types.Log) (*KeeperRegistrarMockAutoApproveAllowedSenderSet, error) { + event := new(KeeperRegistrarMockAutoApproveAllowedSenderSet) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "AutoApproveAllowedSenderSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistrarMockConfigChangedIterator struct { + Event *KeeperRegistrarMockConfigChanged + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockConfigChangedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockConfigChanged) + 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(KeeperRegistrarMockConfigChanged) + 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 *KeeperRegistrarMockConfigChangedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockConfigChangedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockConfigChanged struct { + AutoApproveConfigType uint8 + AutoApproveMaxAllowed uint32 + KeeperRegistry common.Address + MinLINKJuels *big.Int + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterConfigChanged(opts *bind.FilterOpts) (*KeeperRegistrarMockConfigChangedIterator, error) { + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "ConfigChanged") + if err != nil { + return nil, err + } + return &KeeperRegistrarMockConfigChangedIterator{contract: _KeeperRegistrarMock.contract, event: "ConfigChanged", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockConfigChanged) (event.Subscription, error) { + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "ConfigChanged") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockConfigChanged) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "ConfigChanged", 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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseConfigChanged(log types.Log) (*KeeperRegistrarMockConfigChanged, error) { + event := new(KeeperRegistrarMockConfigChanged) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "ConfigChanged", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistrarMockOwnershipTransferRequestedIterator struct { + Event *KeeperRegistrarMockOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockOwnershipTransferRequested) + 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(KeeperRegistrarMockOwnershipTransferRequested) + 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 *KeeperRegistrarMockOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistrarMockOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockOwnershipTransferRequestedIterator{contract: _KeeperRegistrarMock.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockOwnershipTransferRequested) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseOwnershipTransferRequested(log types.Log) (*KeeperRegistrarMockOwnershipTransferRequested, error) { + event := new(KeeperRegistrarMockOwnershipTransferRequested) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistrarMockOwnershipTransferredIterator struct { + Event *KeeperRegistrarMockOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockOwnershipTransferred) + 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(KeeperRegistrarMockOwnershipTransferred) + 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 *KeeperRegistrarMockOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistrarMockOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockOwnershipTransferredIterator{contract: _KeeperRegistrarMock.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockOwnershipTransferred) + if err := _KeeperRegistrarMock.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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseOwnershipTransferred(log types.Log) (*KeeperRegistrarMockOwnershipTransferred, error) { + event := new(KeeperRegistrarMockOwnershipTransferred) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistrarMockRegistrationApprovedIterator struct { + Event *KeeperRegistrarMockRegistrationApproved + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockRegistrationApprovedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockRegistrationApproved) + 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(KeeperRegistrarMockRegistrationApproved) + 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 *KeeperRegistrarMockRegistrationApprovedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockRegistrationApprovedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockRegistrationApproved struct { + Hash [32]byte + DisplayName string + UpkeepId *big.Int + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterRegistrationApproved(opts *bind.FilterOpts, hash [][32]byte, upkeepId []*big.Int) (*KeeperRegistrarMockRegistrationApprovedIterator, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "RegistrationApproved", hashRule, upkeepIdRule) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockRegistrationApprovedIterator{contract: _KeeperRegistrarMock.contract, event: "RegistrationApproved", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchRegistrationApproved(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockRegistrationApproved, hash [][32]byte, upkeepId []*big.Int) (event.Subscription, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepIdRule []interface{} + for _, upkeepIdItem := range upkeepId { + upkeepIdRule = append(upkeepIdRule, upkeepIdItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "RegistrationApproved", hashRule, upkeepIdRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockRegistrationApproved) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "RegistrationApproved", 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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseRegistrationApproved(log types.Log) (*KeeperRegistrarMockRegistrationApproved, error) { + event := new(KeeperRegistrarMockRegistrationApproved) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "RegistrationApproved", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistrarMockRegistrationRejectedIterator struct { + Event *KeeperRegistrarMockRegistrationRejected + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockRegistrationRejectedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockRegistrationRejected) + 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(KeeperRegistrarMockRegistrationRejected) + 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 *KeeperRegistrarMockRegistrationRejectedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockRegistrationRejectedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockRegistrationRejected struct { + Hash [32]byte + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterRegistrationRejected(opts *bind.FilterOpts, hash [][32]byte) (*KeeperRegistrarMockRegistrationRejectedIterator, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "RegistrationRejected", hashRule) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockRegistrationRejectedIterator{contract: _KeeperRegistrarMock.contract, event: "RegistrationRejected", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchRegistrationRejected(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockRegistrationRejected, hash [][32]byte) (event.Subscription, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "RegistrationRejected", hashRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockRegistrationRejected) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "RegistrationRejected", 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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseRegistrationRejected(log types.Log) (*KeeperRegistrarMockRegistrationRejected, error) { + event := new(KeeperRegistrarMockRegistrationRejected) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "RegistrationRejected", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistrarMockRegistrationRequestedIterator struct { + Event *KeeperRegistrarMockRegistrationRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistrarMockRegistrationRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistrarMockRegistrationRequested) + 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(KeeperRegistrarMockRegistrationRequested) + 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 *KeeperRegistrarMockRegistrationRequestedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistrarMockRegistrationRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistrarMockRegistrationRequested struct { + Hash [32]byte + Name string + EncryptedEmail []byte + UpkeepContract common.Address + GasLimit uint32 + AdminAddress common.Address + CheckData []byte + Amount *big.Int + Source uint8 + Raw types.Log +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) FilterRegistrationRequested(opts *bind.FilterOpts, hash [][32]byte, upkeepContract []common.Address, source []uint8) (*KeeperRegistrarMockRegistrationRequestedIterator, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepContractRule []interface{} + for _, upkeepContractItem := range upkeepContract { + upkeepContractRule = append(upkeepContractRule, upkeepContractItem) + } + + var sourceRule []interface{} + for _, sourceItem := range source { + sourceRule = append(sourceRule, sourceItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.FilterLogs(opts, "RegistrationRequested", hashRule, upkeepContractRule, sourceRule) + if err != nil { + return nil, err + } + return &KeeperRegistrarMockRegistrationRequestedIterator{contract: _KeeperRegistrarMock.contract, event: "RegistrationRequested", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) WatchRegistrationRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockRegistrationRequested, hash [][32]byte, upkeepContract []common.Address, source []uint8) (event.Subscription, error) { + + var hashRule []interface{} + for _, hashItem := range hash { + hashRule = append(hashRule, hashItem) + } + + var upkeepContractRule []interface{} + for _, upkeepContractItem := range upkeepContract { + upkeepContractRule = append(upkeepContractRule, upkeepContractItem) + } + + var sourceRule []interface{} + for _, sourceItem := range source { + sourceRule = append(sourceRule, sourceItem) + } + + logs, sub, err := _KeeperRegistrarMock.contract.WatchLogs(opts, "RegistrationRequested", hashRule, upkeepContractRule, sourceRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistrarMockRegistrationRequested) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "RegistrationRequested", 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 (_KeeperRegistrarMock *KeeperRegistrarMockFilterer) ParseRegistrationRequested(log types.Log) (*KeeperRegistrarMockRegistrationRequested, error) { + event := new(KeeperRegistrarMockRegistrationRequested) + if err := _KeeperRegistrarMock.contract.UnpackLog(event, "RegistrationRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type GetRegistrationConfig struct { + AutoApproveConfigType uint8 + AutoApproveMaxAllowed uint32 + ApprovedCount uint32 + KeeperRegistry common.Address + MinLINKJuels *big.Int +} + +func (_KeeperRegistrarMock *KeeperRegistrarMock) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _KeeperRegistrarMock.abi.Events["AutoApproveAllowedSenderSet"].ID: + return _KeeperRegistrarMock.ParseAutoApproveAllowedSenderSet(log) + case _KeeperRegistrarMock.abi.Events["ConfigChanged"].ID: + return _KeeperRegistrarMock.ParseConfigChanged(log) + case _KeeperRegistrarMock.abi.Events["OwnershipTransferRequested"].ID: + return _KeeperRegistrarMock.ParseOwnershipTransferRequested(log) + case _KeeperRegistrarMock.abi.Events["OwnershipTransferred"].ID: + return _KeeperRegistrarMock.ParseOwnershipTransferred(log) + case _KeeperRegistrarMock.abi.Events["RegistrationApproved"].ID: + return _KeeperRegistrarMock.ParseRegistrationApproved(log) + case _KeeperRegistrarMock.abi.Events["RegistrationRejected"].ID: + return _KeeperRegistrarMock.ParseRegistrationRejected(log) + case _KeeperRegistrarMock.abi.Events["RegistrationRequested"].ID: + return _KeeperRegistrarMock.ParseRegistrationRequested(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (KeeperRegistrarMockAutoApproveAllowedSenderSet) Topic() common.Hash { + return common.HexToHash("0x20c6237dac83526a849285a9f79d08a483291bdd3a056a0ef9ae94ecee1ad356") +} + +func (KeeperRegistrarMockConfigChanged) Topic() common.Hash { + return common.HexToHash("0x6293a703ec7145dfa23c5cde2e627d6a02e153fc2e9c03b14d1e22cbb4a7e9cd") +} + +func (KeeperRegistrarMockOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (KeeperRegistrarMockOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (KeeperRegistrarMockRegistrationApproved) Topic() common.Hash { + return common.HexToHash("0xb9a292fb7e3edd920cd2d2829a3615a640c43fd7de0a0820aa0668feb4c37d4b") +} + +func (KeeperRegistrarMockRegistrationRejected) Topic() common.Hash { + return common.HexToHash("0x3663fb28ebc87645eb972c9dad8521bf665c623f287e79f1c56f1eb374b82a22") +} + +func (KeeperRegistrarMockRegistrationRequested) Topic() common.Hash { + return common.HexToHash("0xc3f5df4aefec026f610a3fcb08f19476492d69d2cb78b1c2eba259a8820e6a78") +} + +func (_KeeperRegistrarMock *KeeperRegistrarMock) Address() common.Address { + return _KeeperRegistrarMock.address +} + +type KeeperRegistrarMockInterface interface { + GetRegistrationConfig(opts *bind.CallOpts) (GetRegistrationConfig, + + error) + + SApprovedCount(opts *bind.CallOpts) (uint32, error) + + SAutoApproveConfigType(opts *bind.CallOpts) (uint8, error) + + SAutoApproveMaxAllowed(opts *bind.CallOpts) (uint32, error) + + SKeeperRegistry(opts *bind.CallOpts) (common.Address, error) + + SMinLINKJuels(opts *bind.CallOpts) (*big.Int, error) + + EmitAutoApproveAllowedSenderSet(opts *bind.TransactOpts, senderAddress common.Address, allowed bool) (*types.Transaction, error) + + EmitConfigChanged(opts *bind.TransactOpts, autoApproveConfigType uint8, autoApproveMaxAllowed uint32, keeperRegistry common.Address, minLINKJuels *big.Int) (*types.Transaction, error) + + EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitRegistrationApproved(opts *bind.TransactOpts, hash [32]byte, displayName string, upkeepId *big.Int) (*types.Transaction, error) + + EmitRegistrationRejected(opts *bind.TransactOpts, hash [32]byte) (*types.Transaction, error) + + EmitRegistrationRequested(opts *bind.TransactOpts, hash [32]byte, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, checkData []byte, amount *big.Int, source uint8) (*types.Transaction, error) + + SetRegistrationConfig(opts *bind.TransactOpts, _autoApproveConfigType uint8, _autoApproveMaxAllowed uint32, _approvedCount uint32, _keeperRegistry common.Address, _minLINKJuels *big.Int) (*types.Transaction, error) + + FilterAutoApproveAllowedSenderSet(opts *bind.FilterOpts, senderAddress []common.Address) (*KeeperRegistrarMockAutoApproveAllowedSenderSetIterator, error) + + WatchAutoApproveAllowedSenderSet(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockAutoApproveAllowedSenderSet, senderAddress []common.Address) (event.Subscription, error) + + ParseAutoApproveAllowedSenderSet(log types.Log) (*KeeperRegistrarMockAutoApproveAllowedSenderSet, error) + + FilterConfigChanged(opts *bind.FilterOpts) (*KeeperRegistrarMockConfigChangedIterator, error) + + WatchConfigChanged(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockConfigChanged) (event.Subscription, error) + + ParseConfigChanged(log types.Log) (*KeeperRegistrarMockConfigChanged, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistrarMockOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*KeeperRegistrarMockOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistrarMockOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*KeeperRegistrarMockOwnershipTransferred, error) + + FilterRegistrationApproved(opts *bind.FilterOpts, hash [][32]byte, upkeepId []*big.Int) (*KeeperRegistrarMockRegistrationApprovedIterator, error) + + WatchRegistrationApproved(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockRegistrationApproved, hash [][32]byte, upkeepId []*big.Int) (event.Subscription, error) + + ParseRegistrationApproved(log types.Log) (*KeeperRegistrarMockRegistrationApproved, error) + + FilterRegistrationRejected(opts *bind.FilterOpts, hash [][32]byte) (*KeeperRegistrarMockRegistrationRejectedIterator, error) + + WatchRegistrationRejected(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockRegistrationRejected, hash [][32]byte) (event.Subscription, error) + + ParseRegistrationRejected(log types.Log) (*KeeperRegistrarMockRegistrationRejected, error) + + FilterRegistrationRequested(opts *bind.FilterOpts, hash [][32]byte, upkeepContract []common.Address, source []uint8) (*KeeperRegistrarMockRegistrationRequestedIterator, error) + + WatchRegistrationRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistrarMockRegistrationRequested, hash [][32]byte, upkeepContract []common.Address, source []uint8) (event.Subscription, error) + + ParseRegistrationRequested(log types.Log) (*KeeperRegistrarMockRegistrationRequested, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generated/keeper_registry_wrapper1_1_mock/keeper_registry_wrapper1_1_mock.go b/core/gethwrappers/generated/keeper_registry_wrapper1_1_mock/keeper_registry_wrapper1_1_mock.go new file mode 100644 index 00000000000..d7bfc132eb5 --- /dev/null +++ b/core/gethwrappers/generated/keeper_registry_wrapper1_1_mock/keeper_registry_wrapper1_1_mock.go @@ -0,0 +1,3083 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package keeper_registry_wrapper1_1_mock + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var KeeperRegistryMockMetaData = &bind.MetaData{ + ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint24\",\"name\":\"blockCountPerTurn\",\"type\":\"uint24\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"}],\"name\":\"FlatFeeSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"keepers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"KeepersUpdated\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"keeper\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"keeper\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"keeper\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"RegistrarChanged\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"executeGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"maxLinkPayment\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"adjustedGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkEth\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"blockCountPerTurn\",\"type\":\"uint24\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"}],\"name\":\"emitConfigSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"}],\"name\":\"emitFlatFeeSet\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"emitFundsAdded\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitFundsWithdrawn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"keepers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"emitKeepersUpdated\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitOwnershipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"emitPaused\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"keeper\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitPayeeshipTransferRequested\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"keeper\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitPayeeshipTransferred\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"keeper\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"emitPaymentWithdrawn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"emitRegistrarChanged\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"emitUnpaused\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"emitUpkeepCanceled\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"payment\",\"type\":\"uint96\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"emitUpkeepPerformed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"executeGas\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"emitUpkeepRegistered\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCanceledUpkeepList\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"blockCountPerTurn\",\"type\":\"uint24\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getKeeperList\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"executeGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"lastKeeper\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getUpkeepCount\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"_canceledUpkeepList\",\"type\":\"uint256[]\"}],\"name\":\"setCanceledUpkeepList\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint256\",\"name\":\"maxLinkPayment\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"adjustedGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkEth\",\"type\":\"uint256\"}],\"name\":\"setCheckUpkeepData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"_paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"_flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"_blockCountPerTurn\",\"type\":\"uint24\"},{\"internalType\":\"uint32\",\"name\":\"_checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"_stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"_gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint256\",\"name\":\"_fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_fallbackLinkPrice\",\"type\":\"uint256\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"_keepers\",\"type\":\"address[]\"}],\"name\":\"setKeeperList\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"name\":\"setMinBalance\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"name\":\"setPerformUpkeepSuccess\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"_target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"_executeGas\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"_balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"_admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"_maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"_lastKeeper\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"_checkData\",\"type\":\"bytes\"}],\"name\":\"setUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_upkeepCount\",\"type\":\"uint256\"}],\"name\":\"setUpkeepCount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50611fb6806100206000396000f3fe608060405234801561001057600080fd5b50600436106101f05760003560e01c8063999a73bb1161010f578063c3f909d4116100a2578063db30a38611610071578063db30a38614610d76578063f7420bc214610dd7578063fecf27c914610e12578063ffc1d91c14610e2c576101f0565b8063c3f909d414610aed578063c41b813a14610b45578063c7c3a19a14610c12578063d5b16ded14610d31576101f0565b8063b019b4e8116100de578063b019b4e814610996578063b34362d7146109d1578063b657bc9c14610a0c578063c2030c8b14610a4a576101f0565b8063999a73bb146107b857806399e1a39b146108df5780639ec3ce4b14610924578063a6e95ed014610957576101f0565b806358e1e734116101875780637be5c756116101565780637be5c756146106b557806381d2c40c146106e8578063825bea391461073e5780638a8aa1651461076f576101f0565b806358e1e7341461056b57806367923e95146105b0578063749e9cc9146105fd5780637bbaf1ea1461062a576101f0565b80633e2d7056116101c35780633e2d7056146103815780634a16a9ad146103a65780634e6575e01461048a5780635181feaa146104ad576101f0565b806315a126ea146101f55780631ffe6c971461024d578063284403761461035c5780632cb6864d14610379575b600080fd5b6101fd610ecf565b60408051602080825283518183015283519192839290830191858101910280838360005b83811015610239578181015183820152602001610221565b505050509050019250505060405180910390f35b61035a600480360361010081101561026457600080fd5b81359173ffffffffffffffffffffffffffffffffffffffff602082013581169263ffffffff604084013516926bffffffffffffffffffffffff60608201351692608082013581169267ffffffffffffffff60a0840135169260c08101359092169190810190610100810160e08201356401000000008111156102e557600080fd5b8201836020820111156102f757600080fd5b8035906020019184600183028401116401000000008311171561031957600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550610f3e945050505050565b005b61035a6004803603602081101561037257600080fd5b503561117b565b6101fd611180565b61035a6004803603604081101561039757600080fd5b508035906020013515156111d7565b61035a600480360360a08110156103bc57600080fd5b813591602081013515159173ffffffffffffffffffffffffffffffffffffffff604083013516916bffffffffffffffffffffffff6060820135169181019060a08101608082013564010000000081111561041557600080fd5b82018360208201111561042757600080fd5b8035906020019184600183028401116401000000008311171561044957600080fd5b91908080601f016020809104026020016040519081016040528093929190818152602001838380828437600092019190915250929550611215945050505050565b61035a600480360360208110156104a057600080fd5b503563ffffffff166112e6565b61035a600480360360c08110156104c357600080fd5b813591908101906040810160208201356401000000008111156104e557600080fd5b8201836020820111156104f757600080fd5b8035906020019184600183028401116401000000008311171561051957600080fd5b91908080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152509295505082359350505060208101359060408101359060600135611322565b61035a6004803603606081101561058157600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020810135821691604090910135166113a0565b61035a600480360360608110156105c657600080fd5b50803590602081013573ffffffffffffffffffffffffffffffffffffffff1690604001356bffffffffffffffffffffffff16611416565b61035a6004803603604081101561061357600080fd5b508035906020013567ffffffffffffffff16611476565b6106a16004803603604081101561064057600080fd5b8135919081019060408101602082013564010000000081111561066257600080fd5b82018360208201111561067457600080fd5b8035906020019184600183028401116401000000008311171561069657600080fd5b5090925090506114b1565b604080519115158252519081900360200190f35b61035a600480360360208110156106cb57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff166114c8565b61035a600480360360e08110156106fe57600080fd5b5063ffffffff813581169162ffffff60208201358116926040830135169160608101359091169061ffff6080820135169060a08101359060c00135611514565b61035a6004803603604081101561075457600080fd5b50803590602001356bffffffffffffffffffffffff16611589565b61035a6004803603608081101561078557600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135811691602081013591604082013581169160600135166115d4565b61035a600480360360408110156107ce57600080fd5b8101906020810181356401000000008111156107e957600080fd5b8201836020820111156107fb57600080fd5b8035906020019184602083028401116401000000008311171561081d57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929594936020810193503591505064010000000081111561086d57600080fd5b82018360208201111561087f57600080fd5b803590602001918460208302840111640100000000831117156108a157600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550611656945050505050565b61035a600480360360608110156108f557600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135811691602081013582169160409091013516611715565b61035a6004803603602081101561093a57600080fd5b503573ffffffffffffffffffffffffffffffffffffffff1661178b565b61035a6004803603606081101561096d57600080fd5b508035906020810135906040013573ffffffffffffffffffffffffffffffffffffffff166117d7565b61035a600480360360408110156109ac57600080fd5b5073ffffffffffffffffffffffffffffffffffffffff8135811691602001351661182b565b61035a600480360360408110156109e757600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020013516611889565b610a2960048036036020811015610a2257600080fd5b50356118e7565b604080516bffffffffffffffffffffffff9092168252519081900360200190f35b61035a60048036036020811015610a6057600080fd5b810190602081018135640100000000811115610a7b57600080fd5b820183602082011115610a8d57600080fd5b80359060200191846020830284011164010000000083111715610aaf57600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550611907945050505050565b610af561191e565b6040805163ffffffff988916815262ffffff9788166020820152959097168588015292909416606084015261ffff16608083015260a082019290925260c081019190915290519081900360e00190f35b610b7e60048036036040811015610b5b57600080fd5b508035906020013573ffffffffffffffffffffffffffffffffffffffff1661198e565b6040518080602001868152602001858152602001848152602001838152602001828103825287818151815260200191508051906020019080838360005b83811015610bd3578181015183820152602001610bbb565b50505050905090810190601f168015610c005780820380516001836020036101000a031916815260200191505b50965050505050505060405180910390f35b610c2f60048036036020811015610c2857600080fd5b5035611a76565b604051808873ffffffffffffffffffffffffffffffffffffffff1681526020018763ffffffff16815260200180602001866bffffffffffffffffffffffff1681526020018573ffffffffffffffffffffffffffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff1681526020018367ffffffffffffffff168152602001828103825287818151815260200191508051906020019080838360005b83811015610cf0578181015183820152602001610cd8565b50505050905090810190601f168015610d1d5780820380516001836020036101000a031916815260200191505b509850505050505050505060405180910390f35b61035a60048036036060811015610d4757600080fd5b50803590602081013563ffffffff16906040013573ffffffffffffffffffffffffffffffffffffffff16611c1f565b61035a6004803603610100811015610d8d57600080fd5b5063ffffffff8135811691602081013582169162ffffff604083013581169260608101359092169160808101359091169061ffff60a0820135169060c08101359060e00135611c79565b61035a60048036036040811015610ded57600080fd5b5073ffffffffffffffffffffffffffffffffffffffff81358116916020013516611ddd565b610e1a611e3b565b60408051918252519081900360200190f35b61035a60048036036020811015610e4257600080fd5b810190602081018135640100000000811115610e5d57600080fd5b820183602082011115610e6f57600080fd5b80359060200191846020830284011164010000000083111715610e9157600080fd5b919080806020026020016040519081016040528093929190818152602001838360200280828437600092019190915250929550611e41945050505050565b60606002805480602002602001604051908101604052809291908181526020018280548015610f3457602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610f09575b5050505050905090565b60006040518060c001604052808973ffffffffffffffffffffffffffffffffffffffff1681526020018863ffffffff168152602001876bffffffffffffffffffffffff1681526020018673ffffffffffffffffffffffffffffffffffffffff1681526020018567ffffffffffffffff1681526020018473ffffffffffffffffffffffffffffffffffffffff16815250905080600660008b815260200190815260200160002060008201518160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060208201518160000160146101000a81548163ffffffff021916908363ffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060808201518160020160006101000a81548167ffffffffffffffff021916908367ffffffffffffffff16021790555060a08201518160020160086101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505081600760008b8152602001908152602001600020908051906020019061116f929190611e54565b50505050505050505050565b600055565b60606001805480602002602001604051908101604052809291908181526020018280548015610f3457602002820191906000526020600020905b8154815260200190600101908083116111ba575050505050905090565b6000918252600a602052604090912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b8273ffffffffffffffffffffffffffffffffffffffff16841515867fcaacad83e47cc45c280d487ec84184eee2fa3b54ebaa393bda7549f13da228f6858560405180836bffffffffffffffffffffffff16815260200180602001828103825283818151815260200191508051906020019080838360005b838110156112a457818101518382015260200161128c565b50505050905090810190601f1680156112d15780820380516001836020036101000a031916815260200191505b50935050505060405180910390a45050505050565b6040805163ffffffff8316815290517f17b46a44a823646eef686b7824df2962de896bc9a012a60b67694c5cbf184d8b9181900360200190a150565b6040805160a0810182528681526020808201879052818301869052606082018590526080820184905260008981526009825292909220815180519293919261136d9284920190611e54565b50602082015160018201556040820151600282015560608201516003820155608090910151600490910155505050505050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b360405160405180910390a4505050565b604080516bffffffffffffffffffffffff83168152905173ffffffffffffffffffffffffffffffffffffffff84169185917fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039181900360200190a3505050565b60405167ffffffffffffffff82169083907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a35050565b50506000908152600a602052604090205460ff1690565b6040805173ffffffffffffffffffffffffffffffffffffffff8316815290517f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2589181900360200190a150565b6040805163ffffffff808a16825262ffffff808a166020840152908816828401528616606082015261ffff8516608082015260a0810184905260c0810183905290517feb3c06937e6595fd80ec1add18a195026d5cf65f122cc3ffedbfb18a9ed80b399181900360e00190a150505050505050565b60009182526008602052604090912080547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff909216919091179055565b8173ffffffffffffffffffffffffffffffffffffffff16838573ffffffffffffffffffffffffffffffffffffffff167f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f4069884604051808273ffffffffffffffffffffffffffffffffffffffff16815260200191505060405180910390a450505050565b7f056264c94f28bb06c99d13f0446eb96c67c215d8d707bce2655a98ddf1c0b71f8282604051808060200180602001838103835285818151815260200191508051906020019060200280838360005b838110156116bd5781810151838201526020016116a5565b50505050905001838103825284818151815260200191508051906020019060200280838360005b838110156116fc5781810151838201526020016116e4565b5050505090500194505050505060405180910390a15050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff168473ffffffffffffffffffffffffffffffffffffffff167f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836760405160405180910390a4505050565b6040805173ffffffffffffffffffffffffffffffffffffffff8316815290517f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa9181900360200190a150565b6040805183815273ffffffffffffffffffffffffffffffffffffffff83166020820152815185927ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318928290030190a2505050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e060405160405180910390a35050565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167f9bf4a5b30267728df68663e14adb47e559863967c419dc6030638883408bed2e60405160405180910390a35050565b6000908152600860205260409020546bffffffffffffffffffffffff1690565b805161191a906001906020840190611ee0565b5050565b60035460045460055463ffffffff8084169468010000000000000000850462ffffff908116956b0100000000000000000000008104909316946f01000000000000000000000000000000840490911693720100000000000000000000000000000000000090930461ffff16929091565b60606000806000806000600960008981526020019081526020016000209050806000018160010154826002015483600301548460040154848054600181600116156101000203166002900480601f016020809104026020016040519081016040528092919081815260200182805460018160011615610100020316600290048015611a5a5780601f10611a2f57610100808354040283529160200191611a5a565b820191906000526020600020905b815481529060010190602001808311611a3d57829003601f168201915b5050505050945095509550955095509550509295509295909350565b6000818152600660209081526040808320815160c081018352815473ffffffffffffffffffffffffffffffffffffffff8082168084527401000000000000000000000000000000000000000090920463ffffffff168387018190526001808601546bffffffffffffffffffffffff81168689019081526c010000000000000000000000009091048416606080880191825260029889015467ffffffffffffffff811660808a019081526801000000000000000090910490961660a089019081528d8d5260078c528a8d20935190519251965184548c5161010097821615979097027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff01169a909a04601f81018d90048d0286018d01909b528a85528c9b919a8c9a8b9a8b9a8b9a91999098909796949591939091879190830182828015611bfe5780601f10611bd357610100808354040283529160200191611bfe565b820191906000526020600020905b815481529060010190602001808311611be157829003601f168201915b50505050509450975097509750975097509750975050919395979092949650565b6040805163ffffffff8416815273ffffffffffffffffffffffffffffffffffffffff83166020820152815185927fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d012928290030190a2505050565b600380547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff998a16177fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff16640100000000988a1698909802979097177fffffffffffffffffffffffffffffffffffffffffff000000ffffffffffffffff166801000000000000000062ffffff97881602177fffffffffffffffffffffffffffffffffff00000000ffffffffffffffffffffff166b0100000000000000000000009590981694909402969096177fffffffffffffffffffffffffffff000000ffffffffffffffffffffffffffffff166f010000000000000000000000000000009290941691909102929092177fffffffffffffffffffffffff0000ffffffffffffffffffffffffffffffffffff16720100000000000000000000000000000000000061ffff939093169290920291909117909155600491909155600555565b8073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff167fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127860405160405180910390a35050565b60005490565b805161191a906002906020840190611f1a565b828054600181600116156101000203166002900490600052602060002090601f016020900481019282611e8a5760008555611ed0565b82601f10611ea357805160ff1916838001178555611ed0565b82800160010185558215611ed0579182015b82811115611ed0578251825591602001919060010190611eb5565b50611edc929150611f94565b5090565b828054828255906000526020600020908101928215611ed05791602002820182811115611ed0578251825591602001919060010190611eb5565b828054828255906000526020600020908101928215611ed0579160200282015b82811115611ed057825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190611f3a565b5b80821115611edc5760008155600101611f9556fea164736f6c6343000706000a", +} + +var KeeperRegistryMockABI = KeeperRegistryMockMetaData.ABI + +var KeeperRegistryMockBin = KeeperRegistryMockMetaData.Bin + +func DeployKeeperRegistryMock(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *KeeperRegistryMock, error) { + parsed, err := KeeperRegistryMockMetaData.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(KeeperRegistryMockBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &KeeperRegistryMock{KeeperRegistryMockCaller: KeeperRegistryMockCaller{contract: contract}, KeeperRegistryMockTransactor: KeeperRegistryMockTransactor{contract: contract}, KeeperRegistryMockFilterer: KeeperRegistryMockFilterer{contract: contract}}, nil +} + +type KeeperRegistryMock struct { + address common.Address + abi abi.ABI + KeeperRegistryMockCaller + KeeperRegistryMockTransactor + KeeperRegistryMockFilterer +} + +type KeeperRegistryMockCaller struct { + contract *bind.BoundContract +} + +type KeeperRegistryMockTransactor struct { + contract *bind.BoundContract +} + +type KeeperRegistryMockFilterer struct { + contract *bind.BoundContract +} + +type KeeperRegistryMockSession struct { + Contract *KeeperRegistryMock + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type KeeperRegistryMockCallerSession struct { + Contract *KeeperRegistryMockCaller + CallOpts bind.CallOpts +} + +type KeeperRegistryMockTransactorSession struct { + Contract *KeeperRegistryMockTransactor + TransactOpts bind.TransactOpts +} + +type KeeperRegistryMockRaw struct { + Contract *KeeperRegistryMock +} + +type KeeperRegistryMockCallerRaw struct { + Contract *KeeperRegistryMockCaller +} + +type KeeperRegistryMockTransactorRaw struct { + Contract *KeeperRegistryMockTransactor +} + +func NewKeeperRegistryMock(address common.Address, backend bind.ContractBackend) (*KeeperRegistryMock, error) { + abi, err := abi.JSON(strings.NewReader(KeeperRegistryMockABI)) + if err != nil { + return nil, err + } + contract, err := bindKeeperRegistryMock(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &KeeperRegistryMock{address: address, abi: abi, KeeperRegistryMockCaller: KeeperRegistryMockCaller{contract: contract}, KeeperRegistryMockTransactor: KeeperRegistryMockTransactor{contract: contract}, KeeperRegistryMockFilterer: KeeperRegistryMockFilterer{contract: contract}}, nil +} + +func NewKeeperRegistryMockCaller(address common.Address, caller bind.ContractCaller) (*KeeperRegistryMockCaller, error) { + contract, err := bindKeeperRegistryMock(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &KeeperRegistryMockCaller{contract: contract}, nil +} + +func NewKeeperRegistryMockTransactor(address common.Address, transactor bind.ContractTransactor) (*KeeperRegistryMockTransactor, error) { + contract, err := bindKeeperRegistryMock(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &KeeperRegistryMockTransactor{contract: contract}, nil +} + +func NewKeeperRegistryMockFilterer(address common.Address, filterer bind.ContractFilterer) (*KeeperRegistryMockFilterer, error) { + contract, err := bindKeeperRegistryMock(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &KeeperRegistryMockFilterer{contract: contract}, nil +} + +func bindKeeperRegistryMock(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := KeeperRegistryMockMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _KeeperRegistryMock.Contract.KeeperRegistryMockCaller.contract.Call(opts, result, method, params...) +} + +func (_KeeperRegistryMock *KeeperRegistryMockRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.KeeperRegistryMockTransactor.contract.Transfer(opts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.KeeperRegistryMockTransactor.contract.Transact(opts, method, params...) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _KeeperRegistryMock.Contract.contract.Call(opts, result, method, params...) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.contract.Transfer(opts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.contract.Transact(opts, method, params...) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) CheckUpkeep(opts *bind.CallOpts, id *big.Int, from common.Address) (CheckUpkeep, + + error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "checkUpkeep", id, from) + + outstruct := new(CheckUpkeep) + if err != nil { + return *outstruct, err + } + + outstruct.PerformData = *abi.ConvertType(out[0], new([]byte)).(*[]byte) + outstruct.MaxLinkPayment = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + outstruct.GasLimit = *abi.ConvertType(out[2], new(*big.Int)).(**big.Int) + outstruct.AdjustedGasWei = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + outstruct.LinkEth = *abi.ConvertType(out[4], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) CheckUpkeep(id *big.Int, from common.Address) (CheckUpkeep, + + error) { + return _KeeperRegistryMock.Contract.CheckUpkeep(&_KeeperRegistryMock.CallOpts, id, from) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) CheckUpkeep(id *big.Int, from common.Address) (CheckUpkeep, + + error) { + return _KeeperRegistryMock.Contract.CheckUpkeep(&_KeeperRegistryMock.CallOpts, id, from) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) GetCanceledUpkeepList(opts *bind.CallOpts) ([]*big.Int, error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "getCanceledUpkeepList") + + if err != nil { + return *new([]*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new([]*big.Int)).(*[]*big.Int) + + return out0, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) GetCanceledUpkeepList() ([]*big.Int, error) { + return _KeeperRegistryMock.Contract.GetCanceledUpkeepList(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) GetCanceledUpkeepList() ([]*big.Int, error) { + return _KeeperRegistryMock.Contract.GetCanceledUpkeepList(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) GetConfig(opts *bind.CallOpts) (GetConfig, + + error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "getConfig") + + outstruct := new(GetConfig) + if err != nil { + return *outstruct, err + } + + outstruct.PaymentPremiumPPB = *abi.ConvertType(out[0], new(uint32)).(*uint32) + outstruct.BlockCountPerTurn = *abi.ConvertType(out[1], new(*big.Int)).(**big.Int) + outstruct.CheckGasLimit = *abi.ConvertType(out[2], new(uint32)).(*uint32) + outstruct.StalenessSeconds = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + outstruct.GasCeilingMultiplier = *abi.ConvertType(out[4], new(uint16)).(*uint16) + outstruct.FallbackGasPrice = *abi.ConvertType(out[5], new(*big.Int)).(**big.Int) + outstruct.FallbackLinkPrice = *abi.ConvertType(out[6], new(*big.Int)).(**big.Int) + + return *outstruct, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) GetConfig() (GetConfig, + + error) { + return _KeeperRegistryMock.Contract.GetConfig(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) GetConfig() (GetConfig, + + error) { + return _KeeperRegistryMock.Contract.GetConfig(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) GetKeeperList(opts *bind.CallOpts) ([]common.Address, error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "getKeeperList") + + if err != nil { + return *new([]common.Address), err + } + + out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) + + return out0, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) GetKeeperList() ([]common.Address, error) { + return _KeeperRegistryMock.Contract.GetKeeperList(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) GetKeeperList() ([]common.Address, error) { + return _KeeperRegistryMock.Contract.GetKeeperList(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) GetMinBalanceForUpkeep(opts *bind.CallOpts, id *big.Int) (*big.Int, error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "getMinBalanceForUpkeep", id) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) GetMinBalanceForUpkeep(id *big.Int) (*big.Int, error) { + return _KeeperRegistryMock.Contract.GetMinBalanceForUpkeep(&_KeeperRegistryMock.CallOpts, id) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) GetMinBalanceForUpkeep(id *big.Int) (*big.Int, error) { + return _KeeperRegistryMock.Contract.GetMinBalanceForUpkeep(&_KeeperRegistryMock.CallOpts, id) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) GetUpkeep(opts *bind.CallOpts, id *big.Int) (GetUpkeep, + + error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "getUpkeep", id) + + outstruct := new(GetUpkeep) + if err != nil { + return *outstruct, err + } + + outstruct.Target = *abi.ConvertType(out[0], new(common.Address)).(*common.Address) + outstruct.ExecuteGas = *abi.ConvertType(out[1], new(uint32)).(*uint32) + outstruct.CheckData = *abi.ConvertType(out[2], new([]byte)).(*[]byte) + outstruct.Balance = *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + outstruct.LastKeeper = *abi.ConvertType(out[4], new(common.Address)).(*common.Address) + outstruct.Admin = *abi.ConvertType(out[5], new(common.Address)).(*common.Address) + outstruct.MaxValidBlocknumber = *abi.ConvertType(out[6], new(uint64)).(*uint64) + + return *outstruct, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) GetUpkeep(id *big.Int) (GetUpkeep, + + error) { + return _KeeperRegistryMock.Contract.GetUpkeep(&_KeeperRegistryMock.CallOpts, id) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) GetUpkeep(id *big.Int) (GetUpkeep, + + error) { + return _KeeperRegistryMock.Contract.GetUpkeep(&_KeeperRegistryMock.CallOpts, id) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCaller) GetUpkeepCount(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _KeeperRegistryMock.contract.Call(opts, &out, "getUpkeepCount") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) GetUpkeepCount() (*big.Int, error) { + return _KeeperRegistryMock.Contract.GetUpkeepCount(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockCallerSession) GetUpkeepCount() (*big.Int, error) { + return _KeeperRegistryMock.Contract.GetUpkeepCount(&_KeeperRegistryMock.CallOpts) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitConfigSet(opts *bind.TransactOpts, paymentPremiumPPB uint32, blockCountPerTurn *big.Int, checkGasLimit uint32, stalenessSeconds *big.Int, gasCeilingMultiplier uint16, fallbackGasPrice *big.Int, fallbackLinkPrice *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitConfigSet", paymentPremiumPPB, blockCountPerTurn, checkGasLimit, stalenessSeconds, gasCeilingMultiplier, fallbackGasPrice, fallbackLinkPrice) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitConfigSet(paymentPremiumPPB uint32, blockCountPerTurn *big.Int, checkGasLimit uint32, stalenessSeconds *big.Int, gasCeilingMultiplier uint16, fallbackGasPrice *big.Int, fallbackLinkPrice *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitConfigSet(&_KeeperRegistryMock.TransactOpts, paymentPremiumPPB, blockCountPerTurn, checkGasLimit, stalenessSeconds, gasCeilingMultiplier, fallbackGasPrice, fallbackLinkPrice) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitConfigSet(paymentPremiumPPB uint32, blockCountPerTurn *big.Int, checkGasLimit uint32, stalenessSeconds *big.Int, gasCeilingMultiplier uint16, fallbackGasPrice *big.Int, fallbackLinkPrice *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitConfigSet(&_KeeperRegistryMock.TransactOpts, paymentPremiumPPB, blockCountPerTurn, checkGasLimit, stalenessSeconds, gasCeilingMultiplier, fallbackGasPrice, fallbackLinkPrice) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitFlatFeeSet(opts *bind.TransactOpts, flatFeeMicroLink uint32) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitFlatFeeSet", flatFeeMicroLink) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitFlatFeeSet(flatFeeMicroLink uint32) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitFlatFeeSet(&_KeeperRegistryMock.TransactOpts, flatFeeMicroLink) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitFlatFeeSet(flatFeeMicroLink uint32) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitFlatFeeSet(&_KeeperRegistryMock.TransactOpts, flatFeeMicroLink) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitFundsAdded(opts *bind.TransactOpts, id *big.Int, from common.Address, amount *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitFundsAdded", id, from, amount) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitFundsAdded(id *big.Int, from common.Address, amount *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitFundsAdded(&_KeeperRegistryMock.TransactOpts, id, from, amount) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitFundsAdded(id *big.Int, from common.Address, amount *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitFundsAdded(&_KeeperRegistryMock.TransactOpts, id, from, amount) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitFundsWithdrawn(opts *bind.TransactOpts, id *big.Int, amount *big.Int, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitFundsWithdrawn", id, amount, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitFundsWithdrawn(id *big.Int, amount *big.Int, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitFundsWithdrawn(&_KeeperRegistryMock.TransactOpts, id, amount, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitFundsWithdrawn(id *big.Int, amount *big.Int, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitFundsWithdrawn(&_KeeperRegistryMock.TransactOpts, id, amount, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitKeepersUpdated(opts *bind.TransactOpts, keepers []common.Address, payees []common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitKeepersUpdated", keepers, payees) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitKeepersUpdated(keepers []common.Address, payees []common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitKeepersUpdated(&_KeeperRegistryMock.TransactOpts, keepers, payees) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitKeepersUpdated(keepers []common.Address, payees []common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitKeepersUpdated(&_KeeperRegistryMock.TransactOpts, keepers, payees) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitOwnershipTransferRequested", from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitOwnershipTransferRequested(&_KeeperRegistryMock.TransactOpts, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitOwnershipTransferRequested(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitOwnershipTransferRequested(&_KeeperRegistryMock.TransactOpts, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitOwnershipTransferred", from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitOwnershipTransferred(&_KeeperRegistryMock.TransactOpts, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitOwnershipTransferred(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitOwnershipTransferred(&_KeeperRegistryMock.TransactOpts, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitPaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitPaused", account) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitPaused(account common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPaused(&_KeeperRegistryMock.TransactOpts, account) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitPaused(account common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPaused(&_KeeperRegistryMock.TransactOpts, account) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitPayeeshipTransferRequested(opts *bind.TransactOpts, keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitPayeeshipTransferRequested", keeper, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitPayeeshipTransferRequested(keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPayeeshipTransferRequested(&_KeeperRegistryMock.TransactOpts, keeper, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitPayeeshipTransferRequested(keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPayeeshipTransferRequested(&_KeeperRegistryMock.TransactOpts, keeper, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitPayeeshipTransferred(opts *bind.TransactOpts, keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitPayeeshipTransferred", keeper, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitPayeeshipTransferred(keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPayeeshipTransferred(&_KeeperRegistryMock.TransactOpts, keeper, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitPayeeshipTransferred(keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPayeeshipTransferred(&_KeeperRegistryMock.TransactOpts, keeper, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitPaymentWithdrawn(opts *bind.TransactOpts, keeper common.Address, amount *big.Int, to common.Address, payee common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitPaymentWithdrawn", keeper, amount, to, payee) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitPaymentWithdrawn(keeper common.Address, amount *big.Int, to common.Address, payee common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPaymentWithdrawn(&_KeeperRegistryMock.TransactOpts, keeper, amount, to, payee) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitPaymentWithdrawn(keeper common.Address, amount *big.Int, to common.Address, payee common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitPaymentWithdrawn(&_KeeperRegistryMock.TransactOpts, keeper, amount, to, payee) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitRegistrarChanged(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitRegistrarChanged", from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitRegistrarChanged(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitRegistrarChanged(&_KeeperRegistryMock.TransactOpts, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitRegistrarChanged(from common.Address, to common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitRegistrarChanged(&_KeeperRegistryMock.TransactOpts, from, to) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitUnpaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitUnpaused", account) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitUnpaused(account common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUnpaused(&_KeeperRegistryMock.TransactOpts, account) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitUnpaused(account common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUnpaused(&_KeeperRegistryMock.TransactOpts, account) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitUpkeepCanceled(opts *bind.TransactOpts, id *big.Int, atBlockHeight uint64) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitUpkeepCanceled", id, atBlockHeight) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitUpkeepCanceled(id *big.Int, atBlockHeight uint64) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUpkeepCanceled(&_KeeperRegistryMock.TransactOpts, id, atBlockHeight) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitUpkeepCanceled(id *big.Int, atBlockHeight uint64) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUpkeepCanceled(&_KeeperRegistryMock.TransactOpts, id, atBlockHeight) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitUpkeepPerformed(opts *bind.TransactOpts, id *big.Int, success bool, from common.Address, payment *big.Int, performData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitUpkeepPerformed", id, success, from, payment, performData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitUpkeepPerformed(id *big.Int, success bool, from common.Address, payment *big.Int, performData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUpkeepPerformed(&_KeeperRegistryMock.TransactOpts, id, success, from, payment, performData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitUpkeepPerformed(id *big.Int, success bool, from common.Address, payment *big.Int, performData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUpkeepPerformed(&_KeeperRegistryMock.TransactOpts, id, success, from, payment, performData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) EmitUpkeepRegistered(opts *bind.TransactOpts, id *big.Int, executeGas uint32, admin common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "emitUpkeepRegistered", id, executeGas, admin) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) EmitUpkeepRegistered(id *big.Int, executeGas uint32, admin common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUpkeepRegistered(&_KeeperRegistryMock.TransactOpts, id, executeGas, admin) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) EmitUpkeepRegistered(id *big.Int, executeGas uint32, admin common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.EmitUpkeepRegistered(&_KeeperRegistryMock.TransactOpts, id, executeGas, admin) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) PerformUpkeep(opts *bind.TransactOpts, id *big.Int, performData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "performUpkeep", id, performData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) PerformUpkeep(id *big.Int, performData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.PerformUpkeep(&_KeeperRegistryMock.TransactOpts, id, performData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) PerformUpkeep(id *big.Int, performData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.PerformUpkeep(&_KeeperRegistryMock.TransactOpts, id, performData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetCanceledUpkeepList(opts *bind.TransactOpts, _canceledUpkeepList []*big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setCanceledUpkeepList", _canceledUpkeepList) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetCanceledUpkeepList(_canceledUpkeepList []*big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetCanceledUpkeepList(&_KeeperRegistryMock.TransactOpts, _canceledUpkeepList) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetCanceledUpkeepList(_canceledUpkeepList []*big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetCanceledUpkeepList(&_KeeperRegistryMock.TransactOpts, _canceledUpkeepList) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetCheckUpkeepData(opts *bind.TransactOpts, id *big.Int, performData []byte, maxLinkPayment *big.Int, gasLimit *big.Int, adjustedGasWei *big.Int, linkEth *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setCheckUpkeepData", id, performData, maxLinkPayment, gasLimit, adjustedGasWei, linkEth) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetCheckUpkeepData(id *big.Int, performData []byte, maxLinkPayment *big.Int, gasLimit *big.Int, adjustedGasWei *big.Int, linkEth *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetCheckUpkeepData(&_KeeperRegistryMock.TransactOpts, id, performData, maxLinkPayment, gasLimit, adjustedGasWei, linkEth) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetCheckUpkeepData(id *big.Int, performData []byte, maxLinkPayment *big.Int, gasLimit *big.Int, adjustedGasWei *big.Int, linkEth *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetCheckUpkeepData(&_KeeperRegistryMock.TransactOpts, id, performData, maxLinkPayment, gasLimit, adjustedGasWei, linkEth) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetConfig(opts *bind.TransactOpts, _paymentPremiumPPB uint32, _flatFeeMicroLink uint32, _blockCountPerTurn *big.Int, _checkGasLimit uint32, _stalenessSeconds *big.Int, _gasCeilingMultiplier uint16, _fallbackGasPrice *big.Int, _fallbackLinkPrice *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setConfig", _paymentPremiumPPB, _flatFeeMicroLink, _blockCountPerTurn, _checkGasLimit, _stalenessSeconds, _gasCeilingMultiplier, _fallbackGasPrice, _fallbackLinkPrice) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetConfig(_paymentPremiumPPB uint32, _flatFeeMicroLink uint32, _blockCountPerTurn *big.Int, _checkGasLimit uint32, _stalenessSeconds *big.Int, _gasCeilingMultiplier uint16, _fallbackGasPrice *big.Int, _fallbackLinkPrice *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetConfig(&_KeeperRegistryMock.TransactOpts, _paymentPremiumPPB, _flatFeeMicroLink, _blockCountPerTurn, _checkGasLimit, _stalenessSeconds, _gasCeilingMultiplier, _fallbackGasPrice, _fallbackLinkPrice) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetConfig(_paymentPremiumPPB uint32, _flatFeeMicroLink uint32, _blockCountPerTurn *big.Int, _checkGasLimit uint32, _stalenessSeconds *big.Int, _gasCeilingMultiplier uint16, _fallbackGasPrice *big.Int, _fallbackLinkPrice *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetConfig(&_KeeperRegistryMock.TransactOpts, _paymentPremiumPPB, _flatFeeMicroLink, _blockCountPerTurn, _checkGasLimit, _stalenessSeconds, _gasCeilingMultiplier, _fallbackGasPrice, _fallbackLinkPrice) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetKeeperList(opts *bind.TransactOpts, _keepers []common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setKeeperList", _keepers) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetKeeperList(_keepers []common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetKeeperList(&_KeeperRegistryMock.TransactOpts, _keepers) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetKeeperList(_keepers []common.Address) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetKeeperList(&_KeeperRegistryMock.TransactOpts, _keepers) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetMinBalance(opts *bind.TransactOpts, id *big.Int, minBalance *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setMinBalance", id, minBalance) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetMinBalance(id *big.Int, minBalance *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetMinBalance(&_KeeperRegistryMock.TransactOpts, id, minBalance) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetMinBalance(id *big.Int, minBalance *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetMinBalance(&_KeeperRegistryMock.TransactOpts, id, minBalance) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetPerformUpkeepSuccess(opts *bind.TransactOpts, id *big.Int, success bool) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setPerformUpkeepSuccess", id, success) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetPerformUpkeepSuccess(id *big.Int, success bool) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetPerformUpkeepSuccess(&_KeeperRegistryMock.TransactOpts, id, success) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetPerformUpkeepSuccess(id *big.Int, success bool) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetPerformUpkeepSuccess(&_KeeperRegistryMock.TransactOpts, id, success) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetUpkeep(opts *bind.TransactOpts, id *big.Int, _target common.Address, _executeGas uint32, _balance *big.Int, _admin common.Address, _maxValidBlocknumber uint64, _lastKeeper common.Address, _checkData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setUpkeep", id, _target, _executeGas, _balance, _admin, _maxValidBlocknumber, _lastKeeper, _checkData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetUpkeep(id *big.Int, _target common.Address, _executeGas uint32, _balance *big.Int, _admin common.Address, _maxValidBlocknumber uint64, _lastKeeper common.Address, _checkData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetUpkeep(&_KeeperRegistryMock.TransactOpts, id, _target, _executeGas, _balance, _admin, _maxValidBlocknumber, _lastKeeper, _checkData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetUpkeep(id *big.Int, _target common.Address, _executeGas uint32, _balance *big.Int, _admin common.Address, _maxValidBlocknumber uint64, _lastKeeper common.Address, _checkData []byte) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetUpkeep(&_KeeperRegistryMock.TransactOpts, id, _target, _executeGas, _balance, _admin, _maxValidBlocknumber, _lastKeeper, _checkData) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactor) SetUpkeepCount(opts *bind.TransactOpts, _upkeepCount *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.contract.Transact(opts, "setUpkeepCount", _upkeepCount) +} + +func (_KeeperRegistryMock *KeeperRegistryMockSession) SetUpkeepCount(_upkeepCount *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetUpkeepCount(&_KeeperRegistryMock.TransactOpts, _upkeepCount) +} + +func (_KeeperRegistryMock *KeeperRegistryMockTransactorSession) SetUpkeepCount(_upkeepCount *big.Int) (*types.Transaction, error) { + return _KeeperRegistryMock.Contract.SetUpkeepCount(&_KeeperRegistryMock.TransactOpts, _upkeepCount) +} + +type KeeperRegistryMockConfigSetIterator struct { + Event *KeeperRegistryMockConfigSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockConfigSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockConfigSet) + 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(KeeperRegistryMockConfigSet) + 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 *KeeperRegistryMockConfigSetIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockConfigSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockConfigSet struct { + PaymentPremiumPPB uint32 + BlockCountPerTurn *big.Int + CheckGasLimit uint32 + StalenessSeconds *big.Int + GasCeilingMultiplier uint16 + FallbackGasPrice *big.Int + FallbackLinkPrice *big.Int + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterConfigSet(opts *bind.FilterOpts) (*KeeperRegistryMockConfigSetIterator, error) { + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "ConfigSet") + if err != nil { + return nil, err + } + return &KeeperRegistryMockConfigSetIterator{contract: _KeeperRegistryMock.contract, event: "ConfigSet", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchConfigSet(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockConfigSet) (event.Subscription, error) { + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "ConfigSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockConfigSet) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "ConfigSet", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseConfigSet(log types.Log) (*KeeperRegistryMockConfigSet, error) { + event := new(KeeperRegistryMockConfigSet) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "ConfigSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockFlatFeeSetIterator struct { + Event *KeeperRegistryMockFlatFeeSet + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockFlatFeeSetIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockFlatFeeSet) + 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(KeeperRegistryMockFlatFeeSet) + 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 *KeeperRegistryMockFlatFeeSetIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockFlatFeeSetIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockFlatFeeSet struct { + FlatFeeMicroLink uint32 + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterFlatFeeSet(opts *bind.FilterOpts) (*KeeperRegistryMockFlatFeeSetIterator, error) { + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "FlatFeeSet") + if err != nil { + return nil, err + } + return &KeeperRegistryMockFlatFeeSetIterator{contract: _KeeperRegistryMock.contract, event: "FlatFeeSet", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchFlatFeeSet(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockFlatFeeSet) (event.Subscription, error) { + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "FlatFeeSet") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockFlatFeeSet) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "FlatFeeSet", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseFlatFeeSet(log types.Log) (*KeeperRegistryMockFlatFeeSet, error) { + event := new(KeeperRegistryMockFlatFeeSet) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "FlatFeeSet", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockFundsAddedIterator struct { + Event *KeeperRegistryMockFundsAdded + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockFundsAddedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockFundsAdded) + 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(KeeperRegistryMockFundsAdded) + 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 *KeeperRegistryMockFundsAddedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockFundsAddedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockFundsAdded struct { + Id *big.Int + From common.Address + Amount *big.Int + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterFundsAdded(opts *bind.FilterOpts, id []*big.Int, from []common.Address) (*KeeperRegistryMockFundsAddedIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "FundsAdded", idRule, fromRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockFundsAddedIterator{contract: _KeeperRegistryMock.contract, event: "FundsAdded", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockFundsAdded, id []*big.Int, from []common.Address) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "FundsAdded", idRule, fromRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockFundsAdded) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "FundsAdded", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseFundsAdded(log types.Log) (*KeeperRegistryMockFundsAdded, error) { + event := new(KeeperRegistryMockFundsAdded) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "FundsAdded", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockFundsWithdrawnIterator struct { + Event *KeeperRegistryMockFundsWithdrawn + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockFundsWithdrawnIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockFundsWithdrawn) + 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(KeeperRegistryMockFundsWithdrawn) + 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 *KeeperRegistryMockFundsWithdrawnIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockFundsWithdrawnIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockFundsWithdrawn struct { + Id *big.Int + Amount *big.Int + To common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterFundsWithdrawn(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryMockFundsWithdrawnIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "FundsWithdrawn", idRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockFundsWithdrawnIterator{contract: _KeeperRegistryMock.contract, event: "FundsWithdrawn", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchFundsWithdrawn(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockFundsWithdrawn, id []*big.Int) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "FundsWithdrawn", idRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockFundsWithdrawn) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "FundsWithdrawn", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseFundsWithdrawn(log types.Log) (*KeeperRegistryMockFundsWithdrawn, error) { + event := new(KeeperRegistryMockFundsWithdrawn) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "FundsWithdrawn", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockKeepersUpdatedIterator struct { + Event *KeeperRegistryMockKeepersUpdated + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockKeepersUpdatedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockKeepersUpdated) + 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(KeeperRegistryMockKeepersUpdated) + 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 *KeeperRegistryMockKeepersUpdatedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockKeepersUpdatedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockKeepersUpdated struct { + Keepers []common.Address + Payees []common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterKeepersUpdated(opts *bind.FilterOpts) (*KeeperRegistryMockKeepersUpdatedIterator, error) { + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "KeepersUpdated") + if err != nil { + return nil, err + } + return &KeeperRegistryMockKeepersUpdatedIterator{contract: _KeeperRegistryMock.contract, event: "KeepersUpdated", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchKeepersUpdated(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockKeepersUpdated) (event.Subscription, error) { + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "KeepersUpdated") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockKeepersUpdated) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "KeepersUpdated", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseKeepersUpdated(log types.Log) (*KeeperRegistryMockKeepersUpdated, error) { + event := new(KeeperRegistryMockKeepersUpdated) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "KeepersUpdated", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockOwnershipTransferRequestedIterator struct { + Event *KeeperRegistryMockOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockOwnershipTransferRequested) + 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(KeeperRegistryMockOwnershipTransferRequested) + 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 *KeeperRegistryMockOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryMockOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockOwnershipTransferRequestedIterator{contract: _KeeperRegistryMock.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockOwnershipTransferRequested) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseOwnershipTransferRequested(log types.Log) (*KeeperRegistryMockOwnershipTransferRequested, error) { + event := new(KeeperRegistryMockOwnershipTransferRequested) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockOwnershipTransferredIterator struct { + Event *KeeperRegistryMockOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockOwnershipTransferred) + 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(KeeperRegistryMockOwnershipTransferred) + 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 *KeeperRegistryMockOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryMockOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockOwnershipTransferredIterator{contract: _KeeperRegistryMock.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockOwnershipTransferred) + if err := _KeeperRegistryMock.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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseOwnershipTransferred(log types.Log) (*KeeperRegistryMockOwnershipTransferred, error) { + event := new(KeeperRegistryMockOwnershipTransferred) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockPausedIterator struct { + Event *KeeperRegistryMockPaused + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockPausedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockPaused) + 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(KeeperRegistryMockPaused) + 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 *KeeperRegistryMockPausedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockPausedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockPaused struct { + Account common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterPaused(opts *bind.FilterOpts) (*KeeperRegistryMockPausedIterator, error) { + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "Paused") + if err != nil { + return nil, err + } + return &KeeperRegistryMockPausedIterator{contract: _KeeperRegistryMock.contract, event: "Paused", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchPaused(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPaused) (event.Subscription, error) { + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "Paused") + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockPaused) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "Paused", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParsePaused(log types.Log) (*KeeperRegistryMockPaused, error) { + event := new(KeeperRegistryMockPaused) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "Paused", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockPayeeshipTransferRequestedIterator struct { + Event *KeeperRegistryMockPayeeshipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockPayeeshipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockPayeeshipTransferRequested) + 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(KeeperRegistryMockPayeeshipTransferRequested) + 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 *KeeperRegistryMockPayeeshipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockPayeeshipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockPayeeshipTransferRequested struct { + Keeper common.Address + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterPayeeshipTransferRequested(opts *bind.FilterOpts, keeper []common.Address, from []common.Address, to []common.Address) (*KeeperRegistryMockPayeeshipTransferRequestedIterator, error) { + + var keeperRule []interface{} + for _, keeperItem := range keeper { + keeperRule = append(keeperRule, keeperItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "PayeeshipTransferRequested", keeperRule, fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockPayeeshipTransferRequestedIterator{contract: _KeeperRegistryMock.contract, event: "PayeeshipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchPayeeshipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPayeeshipTransferRequested, keeper []common.Address, from []common.Address, to []common.Address) (event.Subscription, error) { + + var keeperRule []interface{} + for _, keeperItem := range keeper { + keeperRule = append(keeperRule, keeperItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "PayeeshipTransferRequested", keeperRule, fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockPayeeshipTransferRequested) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "PayeeshipTransferRequested", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParsePayeeshipTransferRequested(log types.Log) (*KeeperRegistryMockPayeeshipTransferRequested, error) { + event := new(KeeperRegistryMockPayeeshipTransferRequested) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "PayeeshipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockPayeeshipTransferredIterator struct { + Event *KeeperRegistryMockPayeeshipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockPayeeshipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockPayeeshipTransferred) + 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(KeeperRegistryMockPayeeshipTransferred) + 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 *KeeperRegistryMockPayeeshipTransferredIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockPayeeshipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockPayeeshipTransferred struct { + Keeper common.Address + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterPayeeshipTransferred(opts *bind.FilterOpts, keeper []common.Address, from []common.Address, to []common.Address) (*KeeperRegistryMockPayeeshipTransferredIterator, error) { + + var keeperRule []interface{} + for _, keeperItem := range keeper { + keeperRule = append(keeperRule, keeperItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "PayeeshipTransferred", keeperRule, fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockPayeeshipTransferredIterator{contract: _KeeperRegistryMock.contract, event: "PayeeshipTransferred", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchPayeeshipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPayeeshipTransferred, keeper []common.Address, from []common.Address, to []common.Address) (event.Subscription, error) { + + var keeperRule []interface{} + for _, keeperItem := range keeper { + keeperRule = append(keeperRule, keeperItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "PayeeshipTransferred", keeperRule, fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockPayeeshipTransferred) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "PayeeshipTransferred", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParsePayeeshipTransferred(log types.Log) (*KeeperRegistryMockPayeeshipTransferred, error) { + event := new(KeeperRegistryMockPayeeshipTransferred) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "PayeeshipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockPaymentWithdrawnIterator struct { + Event *KeeperRegistryMockPaymentWithdrawn + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockPaymentWithdrawnIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockPaymentWithdrawn) + 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(KeeperRegistryMockPaymentWithdrawn) + 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 *KeeperRegistryMockPaymentWithdrawnIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockPaymentWithdrawnIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockPaymentWithdrawn struct { + Keeper common.Address + Amount *big.Int + To common.Address + Payee common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterPaymentWithdrawn(opts *bind.FilterOpts, keeper []common.Address, amount []*big.Int, to []common.Address) (*KeeperRegistryMockPaymentWithdrawnIterator, error) { + + var keeperRule []interface{} + for _, keeperItem := range keeper { + keeperRule = append(keeperRule, keeperItem) + } + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "PaymentWithdrawn", keeperRule, amountRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockPaymentWithdrawnIterator{contract: _KeeperRegistryMock.contract, event: "PaymentWithdrawn", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchPaymentWithdrawn(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPaymentWithdrawn, keeper []common.Address, amount []*big.Int, to []common.Address) (event.Subscription, error) { + + var keeperRule []interface{} + for _, keeperItem := range keeper { + keeperRule = append(keeperRule, keeperItem) + } + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "PaymentWithdrawn", keeperRule, amountRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockPaymentWithdrawn) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "PaymentWithdrawn", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParsePaymentWithdrawn(log types.Log) (*KeeperRegistryMockPaymentWithdrawn, error) { + event := new(KeeperRegistryMockPaymentWithdrawn) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "PaymentWithdrawn", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockRegistrarChangedIterator struct { + Event *KeeperRegistryMockRegistrarChanged + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockRegistrarChangedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockRegistrarChanged) + 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(KeeperRegistryMockRegistrarChanged) + 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 *KeeperRegistryMockRegistrarChangedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockRegistrarChangedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockRegistrarChanged struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterRegistrarChanged(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryMockRegistrarChangedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "RegistrarChanged", fromRule, toRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockRegistrarChangedIterator{contract: _KeeperRegistryMock.contract, event: "RegistrarChanged", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchRegistrarChanged(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockRegistrarChanged, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "RegistrarChanged", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockRegistrarChanged) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "RegistrarChanged", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseRegistrarChanged(log types.Log) (*KeeperRegistryMockRegistrarChanged, error) { + event := new(KeeperRegistryMockRegistrarChanged) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "RegistrarChanged", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockUnpausedIterator struct { + Event *KeeperRegistryMockUnpaused + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockUnpausedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockUnpaused) + 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(KeeperRegistryMockUnpaused) + 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 *KeeperRegistryMockUnpausedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockUnpausedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockUnpaused struct { + Account common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterUnpaused(opts *bind.FilterOpts) (*KeeperRegistryMockUnpausedIterator, error) { + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "Unpaused") + if err != nil { + return nil, err + } + return &KeeperRegistryMockUnpausedIterator{contract: _KeeperRegistryMock.contract, event: "Unpaused", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUnpaused) (event.Subscription, error) { + + logs, sub, err := _KeeperRegistryMock.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(KeeperRegistryMockUnpaused) + if err := _KeeperRegistryMock.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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseUnpaused(log types.Log) (*KeeperRegistryMockUnpaused, error) { + event := new(KeeperRegistryMockUnpaused) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "Unpaused", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockUpkeepCanceledIterator struct { + Event *KeeperRegistryMockUpkeepCanceled + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockUpkeepCanceledIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockUpkeepCanceled) + 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(KeeperRegistryMockUpkeepCanceled) + 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 *KeeperRegistryMockUpkeepCanceledIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockUpkeepCanceledIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockUpkeepCanceled struct { + Id *big.Int + AtBlockHeight uint64 + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterUpkeepCanceled(opts *bind.FilterOpts, id []*big.Int, atBlockHeight []uint64) (*KeeperRegistryMockUpkeepCanceledIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + var atBlockHeightRule []interface{} + for _, atBlockHeightItem := range atBlockHeight { + atBlockHeightRule = append(atBlockHeightRule, atBlockHeightItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "UpkeepCanceled", idRule, atBlockHeightRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockUpkeepCanceledIterator{contract: _KeeperRegistryMock.contract, event: "UpkeepCanceled", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchUpkeepCanceled(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUpkeepCanceled, id []*big.Int, atBlockHeight []uint64) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + var atBlockHeightRule []interface{} + for _, atBlockHeightItem := range atBlockHeight { + atBlockHeightRule = append(atBlockHeightRule, atBlockHeightItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "UpkeepCanceled", idRule, atBlockHeightRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockUpkeepCanceled) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "UpkeepCanceled", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseUpkeepCanceled(log types.Log) (*KeeperRegistryMockUpkeepCanceled, error) { + event := new(KeeperRegistryMockUpkeepCanceled) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "UpkeepCanceled", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockUpkeepPerformedIterator struct { + Event *KeeperRegistryMockUpkeepPerformed + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockUpkeepPerformedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockUpkeepPerformed) + 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(KeeperRegistryMockUpkeepPerformed) + 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 *KeeperRegistryMockUpkeepPerformedIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockUpkeepPerformedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockUpkeepPerformed struct { + Id *big.Int + Success bool + From common.Address + Payment *big.Int + PerformData []byte + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterUpkeepPerformed(opts *bind.FilterOpts, id []*big.Int, success []bool, from []common.Address) (*KeeperRegistryMockUpkeepPerformedIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + var successRule []interface{} + for _, successItem := range success { + successRule = append(successRule, successItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "UpkeepPerformed", idRule, successRule, fromRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockUpkeepPerformedIterator{contract: _KeeperRegistryMock.contract, event: "UpkeepPerformed", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchUpkeepPerformed(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUpkeepPerformed, id []*big.Int, success []bool, from []common.Address) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + var successRule []interface{} + for _, successItem := range success { + successRule = append(successRule, successItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "UpkeepPerformed", idRule, successRule, fromRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockUpkeepPerformed) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "UpkeepPerformed", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseUpkeepPerformed(log types.Log) (*KeeperRegistryMockUpkeepPerformed, error) { + event := new(KeeperRegistryMockUpkeepPerformed) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "UpkeepPerformed", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type KeeperRegistryMockUpkeepRegisteredIterator struct { + Event *KeeperRegistryMockUpkeepRegistered + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *KeeperRegistryMockUpkeepRegisteredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(KeeperRegistryMockUpkeepRegistered) + 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(KeeperRegistryMockUpkeepRegistered) + 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 *KeeperRegistryMockUpkeepRegisteredIterator) Error() error { + return it.fail +} + +func (it *KeeperRegistryMockUpkeepRegisteredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type KeeperRegistryMockUpkeepRegistered struct { + Id *big.Int + ExecuteGas uint32 + Admin common.Address + Raw types.Log +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) FilterUpkeepRegistered(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryMockUpkeepRegisteredIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.FilterLogs(opts, "UpkeepRegistered", idRule) + if err != nil { + return nil, err + } + return &KeeperRegistryMockUpkeepRegisteredIterator{contract: _KeeperRegistryMock.contract, event: "UpkeepRegistered", logs: logs, sub: sub}, nil +} + +func (_KeeperRegistryMock *KeeperRegistryMockFilterer) WatchUpkeepRegistered(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUpkeepRegistered, id []*big.Int) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _KeeperRegistryMock.contract.WatchLogs(opts, "UpkeepRegistered", idRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(KeeperRegistryMockUpkeepRegistered) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "UpkeepRegistered", 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 (_KeeperRegistryMock *KeeperRegistryMockFilterer) ParseUpkeepRegistered(log types.Log) (*KeeperRegistryMockUpkeepRegistered, error) { + event := new(KeeperRegistryMockUpkeepRegistered) + if err := _KeeperRegistryMock.contract.UnpackLog(event, "UpkeepRegistered", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type CheckUpkeep struct { + PerformData []byte + MaxLinkPayment *big.Int + GasLimit *big.Int + AdjustedGasWei *big.Int + LinkEth *big.Int +} +type GetConfig struct { + PaymentPremiumPPB uint32 + BlockCountPerTurn *big.Int + CheckGasLimit uint32 + StalenessSeconds *big.Int + GasCeilingMultiplier uint16 + FallbackGasPrice *big.Int + FallbackLinkPrice *big.Int +} +type GetUpkeep struct { + Target common.Address + ExecuteGas uint32 + CheckData []byte + Balance *big.Int + LastKeeper common.Address + Admin common.Address + MaxValidBlocknumber uint64 +} + +func (_KeeperRegistryMock *KeeperRegistryMock) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _KeeperRegistryMock.abi.Events["ConfigSet"].ID: + return _KeeperRegistryMock.ParseConfigSet(log) + case _KeeperRegistryMock.abi.Events["FlatFeeSet"].ID: + return _KeeperRegistryMock.ParseFlatFeeSet(log) + case _KeeperRegistryMock.abi.Events["FundsAdded"].ID: + return _KeeperRegistryMock.ParseFundsAdded(log) + case _KeeperRegistryMock.abi.Events["FundsWithdrawn"].ID: + return _KeeperRegistryMock.ParseFundsWithdrawn(log) + case _KeeperRegistryMock.abi.Events["KeepersUpdated"].ID: + return _KeeperRegistryMock.ParseKeepersUpdated(log) + case _KeeperRegistryMock.abi.Events["OwnershipTransferRequested"].ID: + return _KeeperRegistryMock.ParseOwnershipTransferRequested(log) + case _KeeperRegistryMock.abi.Events["OwnershipTransferred"].ID: + return _KeeperRegistryMock.ParseOwnershipTransferred(log) + case _KeeperRegistryMock.abi.Events["Paused"].ID: + return _KeeperRegistryMock.ParsePaused(log) + case _KeeperRegistryMock.abi.Events["PayeeshipTransferRequested"].ID: + return _KeeperRegistryMock.ParsePayeeshipTransferRequested(log) + case _KeeperRegistryMock.abi.Events["PayeeshipTransferred"].ID: + return _KeeperRegistryMock.ParsePayeeshipTransferred(log) + case _KeeperRegistryMock.abi.Events["PaymentWithdrawn"].ID: + return _KeeperRegistryMock.ParsePaymentWithdrawn(log) + case _KeeperRegistryMock.abi.Events["RegistrarChanged"].ID: + return _KeeperRegistryMock.ParseRegistrarChanged(log) + case _KeeperRegistryMock.abi.Events["Unpaused"].ID: + return _KeeperRegistryMock.ParseUnpaused(log) + case _KeeperRegistryMock.abi.Events["UpkeepCanceled"].ID: + return _KeeperRegistryMock.ParseUpkeepCanceled(log) + case _KeeperRegistryMock.abi.Events["UpkeepPerformed"].ID: + return _KeeperRegistryMock.ParseUpkeepPerformed(log) + case _KeeperRegistryMock.abi.Events["UpkeepRegistered"].ID: + return _KeeperRegistryMock.ParseUpkeepRegistered(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (KeeperRegistryMockConfigSet) Topic() common.Hash { + return common.HexToHash("0xeb3c06937e6595fd80ec1add18a195026d5cf65f122cc3ffedbfb18a9ed80b39") +} + +func (KeeperRegistryMockFlatFeeSet) Topic() common.Hash { + return common.HexToHash("0x17b46a44a823646eef686b7824df2962de896bc9a012a60b67694c5cbf184d8b") +} + +func (KeeperRegistryMockFundsAdded) Topic() common.Hash { + return common.HexToHash("0xafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa734891506203") +} + +func (KeeperRegistryMockFundsWithdrawn) Topic() common.Hash { + return common.HexToHash("0xf3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318") +} + +func (KeeperRegistryMockKeepersUpdated) Topic() common.Hash { + return common.HexToHash("0x056264c94f28bb06c99d13f0446eb96c67c215d8d707bce2655a98ddf1c0b71f") +} + +func (KeeperRegistryMockOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (KeeperRegistryMockOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (KeeperRegistryMockPaused) Topic() common.Hash { + return common.HexToHash("0x62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258") +} + +func (KeeperRegistryMockPayeeshipTransferRequested) Topic() common.Hash { + return common.HexToHash("0x84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e38367") +} + +func (KeeperRegistryMockPayeeshipTransferred) Topic() common.Hash { + return common.HexToHash("0x78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b3") +} + +func (KeeperRegistryMockPaymentWithdrawn) Topic() common.Hash { + return common.HexToHash("0x9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f40698") +} + +func (KeeperRegistryMockRegistrarChanged) Topic() common.Hash { + return common.HexToHash("0x9bf4a5b30267728df68663e14adb47e559863967c419dc6030638883408bed2e") +} + +func (KeeperRegistryMockUnpaused) Topic() common.Hash { + return common.HexToHash("0x5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa") +} + +func (KeeperRegistryMockUpkeepCanceled) Topic() common.Hash { + return common.HexToHash("0x91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f791181") +} + +func (KeeperRegistryMockUpkeepPerformed) Topic() common.Hash { + return common.HexToHash("0xcaacad83e47cc45c280d487ec84184eee2fa3b54ebaa393bda7549f13da228f6") +} + +func (KeeperRegistryMockUpkeepRegistered) Topic() common.Hash { + return common.HexToHash("0xbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d012") +} + +func (_KeeperRegistryMock *KeeperRegistryMock) Address() common.Address { + return _KeeperRegistryMock.address +} + +type KeeperRegistryMockInterface interface { + CheckUpkeep(opts *bind.CallOpts, id *big.Int, from common.Address) (CheckUpkeep, + + error) + + GetCanceledUpkeepList(opts *bind.CallOpts) ([]*big.Int, error) + + GetConfig(opts *bind.CallOpts) (GetConfig, + + error) + + GetKeeperList(opts *bind.CallOpts) ([]common.Address, error) + + GetMinBalanceForUpkeep(opts *bind.CallOpts, id *big.Int) (*big.Int, error) + + GetUpkeep(opts *bind.CallOpts, id *big.Int) (GetUpkeep, + + error) + + GetUpkeepCount(opts *bind.CallOpts) (*big.Int, error) + + EmitConfigSet(opts *bind.TransactOpts, paymentPremiumPPB uint32, blockCountPerTurn *big.Int, checkGasLimit uint32, stalenessSeconds *big.Int, gasCeilingMultiplier uint16, fallbackGasPrice *big.Int, fallbackLinkPrice *big.Int) (*types.Transaction, error) + + EmitFlatFeeSet(opts *bind.TransactOpts, flatFeeMicroLink uint32) (*types.Transaction, error) + + EmitFundsAdded(opts *bind.TransactOpts, id *big.Int, from common.Address, amount *big.Int) (*types.Transaction, error) + + EmitFundsWithdrawn(opts *bind.TransactOpts, id *big.Int, amount *big.Int, to common.Address) (*types.Transaction, error) + + EmitKeepersUpdated(opts *bind.TransactOpts, keepers []common.Address, payees []common.Address) (*types.Transaction, error) + + EmitOwnershipTransferRequested(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitOwnershipTransferred(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitPaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) + + EmitPayeeshipTransferRequested(opts *bind.TransactOpts, keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) + + EmitPayeeshipTransferred(opts *bind.TransactOpts, keeper common.Address, from common.Address, to common.Address) (*types.Transaction, error) + + EmitPaymentWithdrawn(opts *bind.TransactOpts, keeper common.Address, amount *big.Int, to common.Address, payee common.Address) (*types.Transaction, error) + + EmitRegistrarChanged(opts *bind.TransactOpts, from common.Address, to common.Address) (*types.Transaction, error) + + EmitUnpaused(opts *bind.TransactOpts, account common.Address) (*types.Transaction, error) + + EmitUpkeepCanceled(opts *bind.TransactOpts, id *big.Int, atBlockHeight uint64) (*types.Transaction, error) + + EmitUpkeepPerformed(opts *bind.TransactOpts, id *big.Int, success bool, from common.Address, payment *big.Int, performData []byte) (*types.Transaction, error) + + EmitUpkeepRegistered(opts *bind.TransactOpts, id *big.Int, executeGas uint32, admin common.Address) (*types.Transaction, error) + + PerformUpkeep(opts *bind.TransactOpts, id *big.Int, performData []byte) (*types.Transaction, error) + + SetCanceledUpkeepList(opts *bind.TransactOpts, _canceledUpkeepList []*big.Int) (*types.Transaction, error) + + SetCheckUpkeepData(opts *bind.TransactOpts, id *big.Int, performData []byte, maxLinkPayment *big.Int, gasLimit *big.Int, adjustedGasWei *big.Int, linkEth *big.Int) (*types.Transaction, error) + + SetConfig(opts *bind.TransactOpts, _paymentPremiumPPB uint32, _flatFeeMicroLink uint32, _blockCountPerTurn *big.Int, _checkGasLimit uint32, _stalenessSeconds *big.Int, _gasCeilingMultiplier uint16, _fallbackGasPrice *big.Int, _fallbackLinkPrice *big.Int) (*types.Transaction, error) + + SetKeeperList(opts *bind.TransactOpts, _keepers []common.Address) (*types.Transaction, error) + + SetMinBalance(opts *bind.TransactOpts, id *big.Int, minBalance *big.Int) (*types.Transaction, error) + + SetPerformUpkeepSuccess(opts *bind.TransactOpts, id *big.Int, success bool) (*types.Transaction, error) + + SetUpkeep(opts *bind.TransactOpts, id *big.Int, _target common.Address, _executeGas uint32, _balance *big.Int, _admin common.Address, _maxValidBlocknumber uint64, _lastKeeper common.Address, _checkData []byte) (*types.Transaction, error) + + SetUpkeepCount(opts *bind.TransactOpts, _upkeepCount *big.Int) (*types.Transaction, error) + + FilterConfigSet(opts *bind.FilterOpts) (*KeeperRegistryMockConfigSetIterator, error) + + WatchConfigSet(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockConfigSet) (event.Subscription, error) + + ParseConfigSet(log types.Log) (*KeeperRegistryMockConfigSet, error) + + FilterFlatFeeSet(opts *bind.FilterOpts) (*KeeperRegistryMockFlatFeeSetIterator, error) + + WatchFlatFeeSet(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockFlatFeeSet) (event.Subscription, error) + + ParseFlatFeeSet(log types.Log) (*KeeperRegistryMockFlatFeeSet, error) + + FilterFundsAdded(opts *bind.FilterOpts, id []*big.Int, from []common.Address) (*KeeperRegistryMockFundsAddedIterator, error) + + WatchFundsAdded(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockFundsAdded, id []*big.Int, from []common.Address) (event.Subscription, error) + + ParseFundsAdded(log types.Log) (*KeeperRegistryMockFundsAdded, error) + + FilterFundsWithdrawn(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryMockFundsWithdrawnIterator, error) + + WatchFundsWithdrawn(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockFundsWithdrawn, id []*big.Int) (event.Subscription, error) + + ParseFundsWithdrawn(log types.Log) (*KeeperRegistryMockFundsWithdrawn, error) + + FilterKeepersUpdated(opts *bind.FilterOpts) (*KeeperRegistryMockKeepersUpdatedIterator, error) + + WatchKeepersUpdated(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockKeepersUpdated) (event.Subscription, error) + + ParseKeepersUpdated(log types.Log) (*KeeperRegistryMockKeepersUpdated, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryMockOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*KeeperRegistryMockOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryMockOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*KeeperRegistryMockOwnershipTransferred, error) + + FilterPaused(opts *bind.FilterOpts) (*KeeperRegistryMockPausedIterator, error) + + WatchPaused(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPaused) (event.Subscription, error) + + ParsePaused(log types.Log) (*KeeperRegistryMockPaused, error) + + FilterPayeeshipTransferRequested(opts *bind.FilterOpts, keeper []common.Address, from []common.Address, to []common.Address) (*KeeperRegistryMockPayeeshipTransferRequestedIterator, error) + + WatchPayeeshipTransferRequested(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPayeeshipTransferRequested, keeper []common.Address, from []common.Address, to []common.Address) (event.Subscription, error) + + ParsePayeeshipTransferRequested(log types.Log) (*KeeperRegistryMockPayeeshipTransferRequested, error) + + FilterPayeeshipTransferred(opts *bind.FilterOpts, keeper []common.Address, from []common.Address, to []common.Address) (*KeeperRegistryMockPayeeshipTransferredIterator, error) + + WatchPayeeshipTransferred(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPayeeshipTransferred, keeper []common.Address, from []common.Address, to []common.Address) (event.Subscription, error) + + ParsePayeeshipTransferred(log types.Log) (*KeeperRegistryMockPayeeshipTransferred, error) + + FilterPaymentWithdrawn(opts *bind.FilterOpts, keeper []common.Address, amount []*big.Int, to []common.Address) (*KeeperRegistryMockPaymentWithdrawnIterator, error) + + WatchPaymentWithdrawn(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockPaymentWithdrawn, keeper []common.Address, amount []*big.Int, to []common.Address) (event.Subscription, error) + + ParsePaymentWithdrawn(log types.Log) (*KeeperRegistryMockPaymentWithdrawn, error) + + FilterRegistrarChanged(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*KeeperRegistryMockRegistrarChangedIterator, error) + + WatchRegistrarChanged(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockRegistrarChanged, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseRegistrarChanged(log types.Log) (*KeeperRegistryMockRegistrarChanged, error) + + FilterUnpaused(opts *bind.FilterOpts) (*KeeperRegistryMockUnpausedIterator, error) + + WatchUnpaused(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUnpaused) (event.Subscription, error) + + ParseUnpaused(log types.Log) (*KeeperRegistryMockUnpaused, error) + + FilterUpkeepCanceled(opts *bind.FilterOpts, id []*big.Int, atBlockHeight []uint64) (*KeeperRegistryMockUpkeepCanceledIterator, error) + + WatchUpkeepCanceled(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUpkeepCanceled, id []*big.Int, atBlockHeight []uint64) (event.Subscription, error) + + ParseUpkeepCanceled(log types.Log) (*KeeperRegistryMockUpkeepCanceled, error) + + FilterUpkeepPerformed(opts *bind.FilterOpts, id []*big.Int, success []bool, from []common.Address) (*KeeperRegistryMockUpkeepPerformedIterator, error) + + WatchUpkeepPerformed(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUpkeepPerformed, id []*big.Int, success []bool, from []common.Address) (event.Subscription, error) + + ParseUpkeepPerformed(log types.Log) (*KeeperRegistryMockUpkeepPerformed, error) + + FilterUpkeepRegistered(opts *bind.FilterOpts, id []*big.Int) (*KeeperRegistryMockUpkeepRegisteredIterator, error) + + WatchUpkeepRegistered(opts *bind.WatchOpts, sink chan<- *KeeperRegistryMockUpkeepRegistered, id []*big.Int) (event.Subscription, error) + + ParseUpkeepRegistered(log types.Log) (*KeeperRegistryMockUpkeepRegistered, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 5037f7c7277..c2ba625b9e3 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -21,15 +21,18 @@ flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../cont functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsBillingRegistryEventsMock.bin 50deeb883bd9c3729702be335c0388f9d8553bab4be5e26ecacac496a89e2b77 functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 +gas_wrapper_mock: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.bin a9b08f18da59125c6fc305855710241f3d35161b8b9f3e3f635a7b1d5c6da9c8 i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 0ae09bdeddc850a53471ddf47b89d1b32c17e97f531570177738605dfb4d0d10 i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 +keeper_registrar_wrapper1_2_mock: ../../contracts/solc/v0.8.6/KeeperRegistrar1_2Mock.abi ../../contracts/solc/v0.8.6/KeeperRegistrar1_2Mock.bin 5b155a7cb3def309fd7525de1d7cd364ebf8491bdc3060eac08ea0ff55ab29bc keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 keeper_registry_logic1_3: ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin 0176d7abdb01b370c5bf4f670d9abf85ca10aff53b1f7bdad41f85fabe666020 keeper_registry_logic2_0: ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin d69d2bc8e4844293dbc2d45abcddc50b84c88554ecccfa4fa77c0ca45ec80871 keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin dca600c9eb8a3de11d974722dc4de7f3a995c646c4f4b38b358580f2a0ca4612 keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 1f22c3bdf1544cd258d085f1f52bd55024ff2c549288860ba1ce9aaebfa9122b keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin 6ce079f2738f015f7374673a2816e8e9787143d00b780ea7652c8aa9ad9e1e20 +keeper_registry_wrapper1_1_mock: ../../contracts/solc/v0.7/KeeperRegistry1_1Mock.abi ../../contracts/solc/v0.7/KeeperRegistry1_1Mock.bin 98ddb3680e86359de3b5d17e648253ba29a84703f087a1b52237824003a8c6df keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 0db49680d76..c4d7d576b8d 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -30,14 +30,17 @@ package gethwrappers // Automation //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin KeeperRegistry keeper_registry_wrapper1_1 +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.7/KeeperRegistry1_1Mock.abi ../../contracts/solc/v0.7/KeeperRegistry1_1Mock.bin KeeperRegistryMock keeper_registry_wrapper1_1_mock //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.abi ../../contracts/solc/v0.7/UpkeepPerformCounterRestrictive.bin UpkeepPerformCounterRestrictive upkeep_perform_counter_restrictive_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.7/UpkeepCounter.abi ../../contracts/solc/v0.7/UpkeepCounter.bin UpkeepCounter upkeep_counter_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/CronUpkeepFactory.abi - CronUpkeepFactory cron_upkeep_factory_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/CronUpkeep.abi - CronUpkeep cron_upkeep_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin KeeperRegistrar keeper_registrar_wrapper1_2 +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistrar1_2Mock.abi ../../contracts/solc/v0.8.6/KeeperRegistrar1_2Mock.bin KeeperRegistrarMock keeper_registrar_wrapper1_2_mock //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin KeeperRegistry keeper_registry_wrapper1_2 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/TypeAndVersionInterface.abi ../../contracts/solc/v0.8.6/TypeAndVersionInterface.bin TypeAndVersionInterface type_and_version_interface_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin KeeperRegistryCheckUpkeepGasUsageWrapper gas_wrapper +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.bin KeeperRegistryCheckUpkeepGasUsageWrapperMock gas_wrapper_mock //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin KeeperRegistry keeper_registry_wrapper1_3 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin KeeperRegistryLogic keeper_registry_logic1_3 //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin KeeperRegistrar keeper_registrar_wrapper2_0 diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index d72e679e2c0..778f3dfac29 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -24,14 +24,17 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper_mock" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper2_0" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic1_3" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic2_0" registrylogica21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1" registrylogicb21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_1" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_1_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_3" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" @@ -99,6 +102,9 @@ type ContractDeployer interface { DeployMockAggregatorProxy(aggregatorAddr string) (MockAggregatorProxy, error) DeployOffchainAggregatorV2(linkAddr string, offchainOptions OffchainOptions) (OffchainAggregatorV2, error) DeployKeeperRegistryCheckUpkeepGasUsageWrapper(keeperRegistryAddr string) (KeeperRegistryCheckUpkeepGasUsageWrapper, error) + DeployKeeperRegistry11Mock() (KeeperRegistry11Mock, error) + DeployKeeperRegistrar12Mock() (KeeperRegistrar12Mock, error) + DeployKeeperGasWrapperMock() (KeeperGasWrapperMock, error) } // NewContractDeployer returns an instance of a contract deployer based on the client type @@ -319,6 +325,57 @@ func (e *EthereumContractDeployer) DeployStakingEventsMock() (StakingEventsMock, }, nil } +func (e *EthereumContractDeployer) DeployKeeperRegistry11Mock() (KeeperRegistry11Mock, error) { + address, _, instance, err := e.client.DeployContract("KeeperRegistry11Mock", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return keeper_registry_wrapper1_1_mock.DeployKeeperRegistryMock(auth, backend) + }) + if err != nil { + return nil, err + } + return &EthereumKeeperRegistry11Mock{ + client: e.client, + registryMock: instance.(*keeper_registry_wrapper1_1_mock.KeeperRegistryMock), + address: address, + }, nil +} + +func (e *EthereumContractDeployer) DeployKeeperRegistrar12Mock() (KeeperRegistrar12Mock, error) { + address, _, instance, err := e.client.DeployContract("KeeperRegistrar12Mock", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return keeper_registrar_wrapper1_2_mock.DeployKeeperRegistrarMock(auth, backend) + }) + if err != nil { + return nil, err + } + return &EthereumKeeperRegistrar12Mock{ + client: e.client, + registrarMock: instance.(*keeper_registrar_wrapper1_2_mock.KeeperRegistrarMock), + address: address, + }, nil +} + +func (e *EthereumContractDeployer) DeployKeeperGasWrapperMock() (KeeperGasWrapperMock, error) { + address, _, instance, err := e.client.DeployContract("KeeperGasWrapperMock", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return gas_wrapper_mock.DeployKeeperRegistryCheckUpkeepGasUsageWrapperMock(auth, backend) + }) + if err != nil { + return nil, err + } + return &EthereumKeeperGasWrapperMock{ + client: e.client, + gasWrapperMock: instance.(*gas_wrapper_mock.KeeperRegistryCheckUpkeepGasUsageWrapperMock), + address: address, + }, nil +} + func (e *EthereumContractDeployer) DeployOffchainAggregatorEventsMock() (OffchainAggregatorEventsMock, error) { address, _, instance, err := e.client.DeployContract("OffchainAggregatorEventsMock", func( auth *bind.TransactOpts, diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index 6597416d796..9724c4cb3f6 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -256,6 +256,36 @@ type OffchainAggregatorEventsMock interface { NewTransmission(aggregatorRoundId uint32, answer *big.Int, transmitter common.Address, observations []*big.Int, observers []byte, rawReportContext [32]byte) error } +type KeeperRegistry11Mock interface { + Address() string + EmitUpkeepPerformed(id *big.Int, success bool, from common.Address, payment *big.Int, performData []byte) error + EmitUpkeepCanceled(id *big.Int, atBlockHeight uint64) error + EmitFundsWithdrawn(id *big.Int, amount *big.Int, to common.Address) error + EmitKeepersUpdated(keepers []common.Address, payees []common.Address) error + EmitUpkeepRegistered(id *big.Int, executeGas uint32, admin common.Address) error + EmitFundsAdded(id *big.Int, from common.Address, amount *big.Int) error + SetUpkeepCount(_upkeepCount *big.Int) error + SetCanceledUpkeepList(_canceledUpkeepList []*big.Int) error + SetKeeperList(_keepers []common.Address) error + SetConfig(_paymentPremiumPPB uint32, _flatFeeMicroLink uint32, _blockCountPerTurn *big.Int, _checkGasLimit uint32, _stalenessSeconds *big.Int, _gasCeilingMultiplier uint16, _fallbackGasPrice *big.Int, _fallbackLinkPrice *big.Int) error + SetUpkeep(id *big.Int, _target common.Address, _executeGas uint32, _balance *big.Int, _admin common.Address, _maxValidBlocknumber uint64, _lastKeeper common.Address, _checkData []byte) error + SetMinBalance(id *big.Int, minBalance *big.Int) error + SetCheckUpkeepData(id *big.Int, performData []byte, maxLinkPayment *big.Int, gasLimit *big.Int, adjustedGasWei *big.Int, linkEth *big.Int) error + SetPerformUpkeepSuccess(id *big.Int, success bool) error +} + +type KeeperRegistrar12Mock interface { + Address() string + EmitRegistrationRequested(hash [32]byte, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, checkData []byte, amount *big.Int, source uint8) error + EmitRegistrationApproved(hash [32]byte, displayName string, upkeepId *big.Int) error + SetRegistrationConfig(_autoApproveConfigType uint8, _autoApproveMaxAllowed uint32, _approvedCount uint32, _keeperRegistry common.Address, _minLINKJuels *big.Int) error +} + +type KeeperGasWrapperMock interface { + Address() string + SetMeasureCheckGasResult(result bool, payload []byte, gas *big.Int) error +} + type MockAggregatorProxy interface { Address() string UpdateAggregator(aggregator common.Address) error diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index c63e0bd862f..1e933f1ee80 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -26,6 +26,9 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_billing_registry_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/functions_oracle_events_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/gas_wrapper_mock" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2_mock" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_1_mock" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_aggregator_proxy" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_ethlink_aggregator_wrapper" @@ -479,6 +482,255 @@ func (f *EthereumOffchainAggregatorEventsMock) NewTransmission(aggregatorRoundId return f.client.ProcessTransaction(tx) } +// EthereumKeeperRegistry11Mock represents the basic keeper registry 1.1 mock contract +type EthereumKeeperRegistry11Mock struct { + client blockchain.EVMClient + registryMock *keeper_registry_wrapper1_1_mock.KeeperRegistryMock + address *common.Address +} + +func (f *EthereumKeeperRegistry11Mock) Address() string { + return f.address.Hex() +} + +func (f *EthereumKeeperRegistry11Mock) EmitUpkeepPerformed(id *big.Int, success bool, from common.Address, payment *big.Int, performData []byte) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.EmitUpkeepPerformed(opts, id, success, from, payment, performData) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) EmitUpkeepCanceled(id *big.Int, atBlockHeight uint64) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.EmitUpkeepCanceled(opts, id, atBlockHeight) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) EmitFundsWithdrawn(id *big.Int, amount *big.Int, to common.Address) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.EmitFundsWithdrawn(opts, id, amount, to) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) EmitKeepersUpdated(keepers []common.Address, payees []common.Address) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.EmitKeepersUpdated(opts, keepers, payees) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) EmitUpkeepRegistered(id *big.Int, executeGas uint32, admin common.Address) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.EmitUpkeepRegistered(opts, id, executeGas, admin) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) EmitFundsAdded(id *big.Int, from common.Address, amount *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.EmitFundsAdded(opts, id, from, amount) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetUpkeepCount(_upkeepCount *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetUpkeepCount(opts, _upkeepCount) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetCanceledUpkeepList(_canceledUpkeepList []*big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetCanceledUpkeepList(opts, _canceledUpkeepList) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetKeeperList(_keepers []common.Address) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetKeeperList(opts, _keepers) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetConfig(_paymentPremiumPPB uint32, _flatFeeMicroLink uint32, _blockCountPerTurn *big.Int, _checkGasLimit uint32, _stalenessSeconds *big.Int, _gasCeilingMultiplier uint16, _fallbackGasPrice *big.Int, _fallbackLinkPrice *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetConfig(opts, _paymentPremiumPPB, _flatFeeMicroLink, _blockCountPerTurn, _checkGasLimit, _stalenessSeconds, _gasCeilingMultiplier, _fallbackGasPrice, _fallbackLinkPrice) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetUpkeep(id *big.Int, _target common.Address, _executeGas uint32, _balance *big.Int, _admin common.Address, _maxValidBlocknumber uint64, _lastKeeper common.Address, _checkData []byte) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetUpkeep(opts, id, _target, _executeGas, _balance, _admin, _maxValidBlocknumber, _lastKeeper, _checkData) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetMinBalance(id *big.Int, minBalance *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetMinBalance(opts, id, minBalance) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetCheckUpkeepData(id *big.Int, performData []byte, maxLinkPayment *big.Int, gasLimit *big.Int, adjustedGasWei *big.Int, linkEth *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetCheckUpkeepData(opts, id, performData, maxLinkPayment, gasLimit, adjustedGasWei, linkEth) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistry11Mock) SetPerformUpkeepSuccess(id *big.Int, success bool) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registryMock.SetPerformUpkeepSuccess(opts, id, success) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +// EthereumKeeperRegistrar12Mock represents the basic keeper registrar 1.2 mock contract +type EthereumKeeperRegistrar12Mock struct { + client blockchain.EVMClient + registrarMock *keeper_registrar_wrapper1_2_mock.KeeperRegistrarMock + address *common.Address +} + +func (f *EthereumKeeperRegistrar12Mock) Address() string { + return f.address.Hex() +} + +func (f *EthereumKeeperRegistrar12Mock) EmitRegistrationRequested(hash [32]byte, name string, encryptedEmail []byte, upkeepContract common.Address, gasLimit uint32, adminAddress common.Address, checkData []byte, amount *big.Int, source uint8) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registrarMock.EmitRegistrationRequested(opts, hash, name, encryptedEmail, upkeepContract, gasLimit, adminAddress, checkData, amount, source) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistrar12Mock) EmitRegistrationApproved(hash [32]byte, displayName string, upkeepId *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registrarMock.EmitRegistrationApproved(opts, hash, displayName, upkeepId) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +func (f *EthereumKeeperRegistrar12Mock) SetRegistrationConfig(_autoApproveConfigType uint8, _autoApproveMaxAllowed uint32, _approvedCount uint32, _keeperRegistry common.Address, _minLINKJuels *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.registrarMock.SetRegistrationConfig(opts, _autoApproveConfigType, _autoApproveMaxAllowed, _approvedCount, _keeperRegistry, _minLINKJuels) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + +// EthereumKeeperGasWrapperMock represents the basic keeper gas wrapper mock contract +type EthereumKeeperGasWrapperMock struct { + client blockchain.EVMClient + gasWrapperMock *gas_wrapper_mock.KeeperRegistryCheckUpkeepGasUsageWrapperMock + address *common.Address +} + +func (f *EthereumKeeperGasWrapperMock) Address() string { + return f.address.Hex() +} + +func (f *EthereumKeeperGasWrapperMock) SetMeasureCheckGasResult(result bool, payload []byte, gas *big.Int) error { + opts, err := f.client.TransactionOpts(f.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := f.gasWrapperMock.SetMeasureCheckGasResult(opts, result, payload, gas) + if err != nil { + return err + } + return f.client.ProcessTransaction(tx) +} + // EthereumFluxAggregator represents the basic flux aggregation contract type EthereumFluxAggregator struct { client blockchain.EVMClient From 9c1debbbc9956fa0cea9f7bd18ffdee9b05d846f Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Fri, 18 Aug 2023 08:59:12 -0700 Subject: [PATCH 210/270] Handle user decryption errors in DecryptionQueue (#10253) --- .../plugins/threshold/decryption_queue.go | 19 +++++++++++++++++-- .../threshold/decryption_queue_test.go | 17 +++++++++++++++++ 2 files changed, 34 insertions(+), 2 deletions(-) diff --git a/core/services/ocr2/plugins/threshold/decryption_queue.go b/core/services/ocr2/plugins/threshold/decryption_queue.go index 957db4b9caf..4db6dff9c4b 100644 --- a/core/services/ocr2/plugins/threshold/decryption_queue.go +++ b/core/services/ocr2/plugins/threshold/decryption_queue.go @@ -204,13 +204,28 @@ func (dq *decryptionQueue) SetResult(ciphertextId decryptionPlugin.CiphertextId, dq.mu.Lock() defer dq.mu.Unlock() + if err == nil && plaintext == nil { + dq.lggr.Errorf("received nil error and nil plaintext for ciphertextId %s", string(ciphertextId)) + return + } + req, ok := dq.pendingRequests[string(ciphertextId)] if ok { - dq.lggr.Debugf("responding with result for pending decryption request ciphertextId %s", string(ciphertextId)) - req.chPlaintext <- plaintext + if err != nil { + dq.lggr.Debugf("decryption error for ciphertextId %s", string(ciphertextId)) + } else { + dq.lggr.Debugf("responding with result for pending decryption request ciphertextId %s", string(ciphertextId)) + req.chPlaintext <- plaintext + } close(req.chPlaintext) delete(dq.pendingRequests, string(ciphertextId)) } else { + if err != nil { + // This is currently possible only for ErrAggregation, encountered during Report() phase. + dq.lggr.Debugf("received decryption error for ciphertextId %s which doesn't exist locally", string(ciphertextId)) + return + } + // Cache plaintext result in completedRequests map for cacheTimeoutMs to account for delayed Decrypt() calls timer := time.AfterFunc(dq.completedRequestsCacheTimeout, func() { dq.lggr.Debugf("expired decryption result for ciphertextId %s from completedRequests cache", string(ciphertextId)) diff --git a/core/services/ocr2/plugins/threshold/decryption_queue_test.go b/core/services/ocr2/plugins/threshold/decryption_queue_test.go index 573682649e2..84fa0f918fa 100644 --- a/core/services/ocr2/plugins/threshold/decryption_queue_test.go +++ b/core/services/ocr2/plugins/threshold/decryption_queue_test.go @@ -253,6 +253,23 @@ func Test_decryptionQueue_Decrypt_CleanupSuccessfulRequest(t *testing.T) { assert.Equal(t, err2.Error(), "context provided by caller was cancelled") } +func Test_decryptionQueue_Decrypt_UserErrorDuringDecryption(t *testing.T) { + lggr := logger.TestLogger(t) + dq := NewDecryptionQueue(5, 1000, 64, testutils.WaitTimeout(t), lggr) + ciphertextId := []byte("1") + + go func() { + waitForPendingRequestToBeAdded(t, dq, ciphertextId) + dq.SetResult(ciphertextId, nil, decryptionPlugin.ErrAggregation) + }() + + ctx, cancel := context.WithCancel(testutils.Context(t)) + defer cancel() + + _, err := dq.Decrypt(ctx, ciphertextId, []byte("encrypted")) + assert.Equal(t, err.Error(), "pending decryption request for ciphertextId 1 was closed without a response") +} + func Test_decryptionQueue_Decrypt_HandleClosedChannelWithoutPlaintextResponse(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(5, 1000, 64, testutils.WaitTimeout(t), lggr) From 875472051ad530621a0cf90cf5af5bc71043e2d4 Mon Sep 17 00:00:00 2001 From: krehermann Date: Fri, 18 Aug 2023 11:15:05 -0600 Subject: [PATCH 211/270] BCF-2549 Fix node status range argument. (#10259) --- core/web/loader/loader_test.go | 2 +- core/web/loader/node.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/web/loader/loader_test.go b/core/web/loader/loader_test.go index e2fe78ef452..0b37b8ce892 100644 --- a/core/web/loader/loader_test.go +++ b/core/web/loader/loader_test.go @@ -80,7 +80,7 @@ func TestLoader_Nodes(t *testing.T) { } } rcInterops := chainlinkmocks.NewRelayerChainInteroperators(t) - rcInterops.On("NodeStatuses", mock.Anything, mock.Anything, mock.Anything, + rcInterops.On("NodeStatuses", mock.Anything, 0, -1, relayID2.String(), relayID1.String(), notARelayID.String()).Return([]relaytypes.NodeStatus{ genNodeStat(chainID2.String()), genNodeStat(chainID1.String()), }, 2, nil) diff --git a/core/web/loader/node.go b/core/web/loader/node.go index b9c655ed5e5..b6b16c23e6c 100644 --- a/core/web/loader/node.go +++ b/core/web/loader/node.go @@ -28,7 +28,7 @@ func (b *nodeBatcher) loadByChainIDs(ctx context.Context, keys dataloader.Keys) keyOrder[key.String()] = ix } - allNodes, _, err := b.app.GetRelayers().NodeStatuses(ctx, 0, 1, evmrelayIdStrs...) + allNodes, _, err := b.app.GetRelayers().NodeStatuses(ctx, 0, -1, evmrelayIdStrs...) if err != nil { return []*dataloader.Result{{Data: nil, Error: err}} } From ffe96438ee3c7b15bec65032a776c8d4a6480062 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Fri, 18 Aug 2023 21:02:29 +0300 Subject: [PATCH 212/270] try more resources (#10256) --- .github/workflows/integration-tests.yml | 46 ++++++++++++------------- 1 file changed, 23 insertions(+), 23 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index eb5bba7f2cc..eeb0f190794 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -255,11 +255,11 @@ jobs: pyroscope_env: "" - name: ocr nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-ocr-evm-simulated - name: ocr2 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-ocr2-evm-simulated - name: runlog nodes: 1 @@ -267,109 +267,109 @@ jobs: pyroscope_env: "" - name: vrf nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-vrf-evm-simulated - name: vrfv2 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-vrf2-evm-simulated - name: forwarder_ocr nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-forwarder-ocr-evm-simulated - name: forwarders_ocr2 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-forwarder-ocr-evm-simulated # Keeper tests split out to use minimal environments - name: keeper-1 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperBasicSmoke$ - name: keeper-2 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperBlockCountPerTurn/registry_1_1$ - name: keeper-3 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperBlockCountPerTurn/registry_1_2$ - name: keeper-4 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperBlockCountPerTurn/registry_1_3$ - name: keeper-5 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperSimulation$ - name: keeper-6 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperCheckPerformGasLimit/registry_1_2$ - name: keeper-7 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperCheckPerformGasLimit/registry_1_3$ - name: keeper-8 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperRegisterUpkeep$ - name: keeper-9 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperAddFunds$ - name: keeper-10 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperRemove$ - name: keeper-11 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperPauseRegistry$ - name: keeper-12 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperMigrateRegistry$ - name: keeper-13 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperNodeDown/registry_1_1$ - name: keeper-14 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperNodeDown/registry_1_2$ - name: keeper-15 nodes: 1 - os: ubuntu-latest + os: ubuntu20.04-8cores-32GB pyroscope_env: ci-smoke-keeper-evm-simulated file: keeper run: -run ^TestKeeperNodeDown/registry_1_3$ @@ -496,7 +496,7 @@ jobs: runs-on: ubuntu-latest needs: [build-chainlink, changes, build-test-image] # Only run migration tests on new tags - if: startsWith(github.ref, 'refs/tags/') + if: startsWith(github.ref, 'refs/tags/') env: SELECTED_NETWORKS: SIMULATED,SIMULATED_1,SIMULATED_2 CHAINLINK_COMMIT_SHA: ${{ github.sha }} @@ -783,7 +783,7 @@ jobs: ### Start Live Testnet Section - testnet-smoke-tests-matrix: + testnet-smoke-tests-matrix: if: ${{ github.event_name == 'schedule' || (github.event_name == 'push' && startsWith(github.ref, 'refs/tags/')) }} ## Only run live tests on new tags and nightly environment: integration permissions: From fbae1afbb38b71b6316460cefffd9ce58e94d354 Mon Sep 17 00:00:00 2001 From: krehermann Date: Fri, 18 Aug 2023 15:30:26 -0600 Subject: [PATCH 213/270] BCF-2555: unify job spec relayer access (#10260) * BCF-2555: unify job spec relayer access * shorten func name * shorten func name and rename relay.Identifier->relay.ID * move EVM cleanup into helper * add tests * code smell cleanup --- .../mocks/relayer_chain_interoperators.go | 16 +- .../chainlink/relayer_chain_interoperators.go | 24 +-- .../relayer_chain_interoperators_test.go | 28 +-- core/services/chainlink/relayer_factory.go | 24 +-- core/services/job/models.go | 13 +- core/services/job/models_test.go | 12 +- core/services/job/spawner_test.go | 2 +- core/services/ocr2/delegate.go | 185 +++++++++--------- core/services/ocr2/delegate_test.go | 14 +- core/services/ocrbootstrap/delegate.go | 12 +- core/services/relay/relay.go | 30 ++- core/services/relay/relay_test.go | 35 +++- core/web/chains_controller.go | 2 +- core/web/loader/loader_test.go | 6 +- core/web/loader/node.go | 2 +- core/web/solana_transfer_controller.go | 2 +- 16 files changed, 229 insertions(+), 178 deletions(-) diff --git a/core/services/chainlink/mocks/relayer_chain_interoperators.go b/core/services/chainlink/mocks/relayer_chain_interoperators.go index eeb4617fc01..f25ced6c3ca 100644 --- a/core/services/chainlink/mocks/relayer_chain_interoperators.go +++ b/core/services/chainlink/mocks/relayer_chain_interoperators.go @@ -30,21 +30,21 @@ type RelayerChainInteroperators struct { } // ChainStatus provides a mock function with given fields: ctx, id -func (_m *RelayerChainInteroperators) ChainStatus(ctx context.Context, id relay.Identifier) (types.ChainStatus, error) { +func (_m *RelayerChainInteroperators) ChainStatus(ctx context.Context, id relay.ID) (types.ChainStatus, error) { ret := _m.Called(ctx, id) var r0 types.ChainStatus var r1 error - if rf, ok := ret.Get(0).(func(context.Context, relay.Identifier) (types.ChainStatus, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, relay.ID) (types.ChainStatus, error)); ok { return rf(ctx, id) } - if rf, ok := ret.Get(0).(func(context.Context, relay.Identifier) types.ChainStatus); ok { + if rf, ok := ret.Get(0).(func(context.Context, relay.ID) types.ChainStatus); ok { r0 = rf(ctx, id) } else { r0 = ret.Get(0).(types.ChainStatus) } - if rf, ok := ret.Get(1).(func(context.Context, relay.Identifier) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, relay.ID) error); ok { r1 = rf(ctx, id) } else { r1 = ret.Error(1) @@ -87,15 +87,15 @@ func (_m *RelayerChainInteroperators) ChainStatuses(ctx context.Context, offset } // Get provides a mock function with given fields: id -func (_m *RelayerChainInteroperators) Get(id relay.Identifier) (internal.Relayer, error) { +func (_m *RelayerChainInteroperators) Get(id relay.ID) (internal.Relayer, error) { ret := _m.Called(id) var r0 internal.Relayer var r1 error - if rf, ok := ret.Get(0).(func(relay.Identifier) (internal.Relayer, error)); ok { + if rf, ok := ret.Get(0).(func(relay.ID) (internal.Relayer, error)); ok { return rf(id) } - if rf, ok := ret.Get(0).(func(relay.Identifier) internal.Relayer); ok { + if rf, ok := ret.Get(0).(func(relay.ID) internal.Relayer); ok { r0 = rf(id) } else { if ret.Get(0) != nil { @@ -103,7 +103,7 @@ func (_m *RelayerChainInteroperators) Get(id relay.Identifier) (internal.Relayer } } - if rf, ok := ret.Get(1).(func(relay.Identifier) error); ok { + if rf, ok := ret.Get(1).(func(relay.ID) error); ok { r1 = rf(id) } else { r1 = ret.Error(1) diff --git a/core/services/chainlink/relayer_chain_interoperators.go b/core/services/chainlink/relayer_chain_interoperators.go index c523b689d10..4d92fef53d2 100644 --- a/core/services/chainlink/relayer_chain_interoperators.go +++ b/core/services/chainlink/relayer_chain_interoperators.go @@ -55,7 +55,7 @@ type LegacyChainer interface { // Similar to [chains.ChainStatuser] but keyed by relay identifier instead of string // TODO BCF-2441 remove this comment when chains.ChainStatus is no longer keyed. type ChainStatuser interface { - ChainStatus(ctx context.Context, id relay.Identifier) (types.ChainStatus, error) + ChainStatus(ctx context.Context, id relay.ID) (types.ChainStatus, error) ChainStatuses(ctx context.Context, offset, limit int) ([]types.ChainStatus, int, error) } @@ -71,7 +71,7 @@ var _ RelayerChainInteroperators = &CoreRelayerChainInteroperators{} // as needed for the core [chainlink.Application] type CoreRelayerChainInteroperators struct { mu sync.Mutex - loopRelayers map[relay.Identifier]loop.Relayer + loopRelayers map[relay.ID]loop.Relayer legacyChains legacyChains // we keep an explicit list of services because the legacy implementations have more than @@ -81,7 +81,7 @@ type CoreRelayerChainInteroperators struct { func NewCoreRelayerChainInteroperators(initFuncs ...CoreRelayerChainInitFunc) (*CoreRelayerChainInteroperators, error) { cr := &CoreRelayerChainInteroperators{ - loopRelayers: make(map[relay.Identifier]loop.Relayer), + loopRelayers: make(map[relay.ID]loop.Relayer), srvs: make([]services.ServiceCtx, 0), } for _, initFn := range initFuncs { @@ -176,7 +176,7 @@ func InitStarknet(ctx context.Context, factory RelayerFactory, config StarkNetFa } // Get a [loop.Relayer] by id -func (rs *CoreRelayerChainInteroperators) Get(id relay.Identifier) (loop.Relayer, error) { +func (rs *CoreRelayerChainInteroperators) Get(id relay.ID) (loop.Relayer, error) { rs.mu.Lock() defer rs.mu.Unlock() lr, exist := rs.loopRelayers[id] @@ -203,7 +203,7 @@ func (rs *CoreRelayerChainInteroperators) LegacyCosmosChains() cosmos.LegacyChai } // ChainStatus gets [types.ChainStatus] -func (rs *CoreRelayerChainInteroperators) ChainStatus(ctx context.Context, id relay.Identifier) (types.ChainStatus, error) { +func (rs *CoreRelayerChainInteroperators) ChainStatus(ctx context.Context, id relay.ID) (types.ChainStatus, error) { lr, err := rs.Get(id) if err != nil { @@ -225,7 +225,7 @@ func (rs *CoreRelayerChainInteroperators) ChainStatuses(ctx context.Context, off rs.mu.Lock() defer rs.mu.Unlock() - relayerIds := make([]relay.Identifier, 0) + relayerIds := make([]relay.ID, 0) for rid := range rs.loopRelayers { relayerIds = append(relayerIds, rid) } @@ -287,7 +287,7 @@ func (rs *CoreRelayerChainInteroperators) NodeStatuses(ctx context.Context, offs } } else { for _, idStr := range relayerIDs { - rid := new(relay.Identifier) + rid := new(relay.ID) err := rid.UnmarshalString(idStr) if err != nil { totalErr = errors.Join(totalErr, err) @@ -316,15 +316,15 @@ func (rs *CoreRelayerChainInteroperators) NodeStatuses(ctx context.Context, offs return result[offset:], len(result[offset:]), nil } -type FilterFn func(id relay.Identifier) bool +type FilterFn func(id relay.ID) bool -var AllRelayers = func(id relay.Identifier) bool { +var AllRelayers = func(id relay.ID) bool { return true } // Returns true if the given network matches id.Network -func FilterRelayersByType(network relay.Network) func(id relay.Identifier) bool { - return func(id relay.Identifier) bool { +func FilterRelayersByType(network relay.Network) func(id relay.ID) bool { + return func(id relay.ID) bool { return id.Network == network } } @@ -334,7 +334,7 @@ func FilterRelayersByType(network relay.Network) func(id relay.Identifier) bool // for a given chain func (rs *CoreRelayerChainInteroperators) List(filter FilterFn) RelayerChainInteroperators { - matches := make(map[relay.Identifier]loop.Relayer) + matches := make(map[relay.ID]loop.Relayer) rs.mu.Lock() for id, relayer := range rs.loopRelayers { if filter(id) { diff --git a/core/services/chainlink/relayer_chain_interoperators_test.go b/core/services/chainlink/relayer_chain_interoperators_test.go index 76ef03c6330..ebd528a2bc5 100644 --- a/core/services/chainlink/relayer_chain_interoperators_test.go +++ b/core/services/chainlink/relayer_chain_interoperators_test.go @@ -184,19 +184,19 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { expectedEVMChainCnt int expectedEVMNodeCnt int - expectedEVMRelayerIds []relay.Identifier + expectedEVMRelayerIds []relay.ID expectedSolanaChainCnt int expectedSolanaNodeCnt int - expectedSolanaRelayerIds []relay.Identifier + expectedSolanaRelayerIds []relay.ID expectedStarknetChainCnt int expectedStarknetNodeCnt int - expectedStarknetRelayerIds []relay.Identifier + expectedStarknetRelayerIds []relay.ID expectedCosmosChainCnt int expectedCosmosNodeCnt int - expectedCosmosRelayerIds []relay.Identifier + expectedCosmosRelayerIds []relay.ID }{ {name: "2 evm chains with 3 nodes", @@ -212,7 +212,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { }, expectedEVMChainCnt: 2, expectedEVMNodeCnt: 3, - expectedEVMRelayerIds: []relay.Identifier{ + expectedEVMRelayerIds: []relay.ID{ {Network: relay.EVM, ChainID: relay.ChainID(evmChainID1.String())}, {Network: relay.EVM, ChainID: relay.ChainID(evmChainID2.String())}, }, @@ -225,7 +225,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { }, expectedSolanaChainCnt: 2, expectedSolanaNodeCnt: 2, - expectedSolanaRelayerIds: []relay.Identifier{ + expectedSolanaRelayerIds: []relay.ID{ {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID1)}, {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID2)}, }, @@ -238,7 +238,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { }, expectedStarknetChainCnt: 2, expectedStarknetNodeCnt: 4, - expectedStarknetRelayerIds: []relay.Identifier{ + expectedStarknetRelayerIds: []relay.ID{ {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID1)}, {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID2)}, }, @@ -253,7 +253,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { }, expectedCosmosChainCnt: 2, expectedCosmosNodeCnt: 2, - expectedCosmosRelayerIds: []relay.Identifier{ + expectedCosmosRelayerIds: []relay.ID{ {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID1)}, {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID2)}, }, @@ -282,28 +282,28 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { }, expectedEVMChainCnt: 2, expectedEVMNodeCnt: 3, - expectedEVMRelayerIds: []relay.Identifier{ + expectedEVMRelayerIds: []relay.ID{ {Network: relay.EVM, ChainID: relay.ChainID(evmChainID1.String())}, {Network: relay.EVM, ChainID: relay.ChainID(evmChainID2.String())}, }, expectedSolanaChainCnt: 2, expectedSolanaNodeCnt: 2, - expectedSolanaRelayerIds: []relay.Identifier{ + expectedSolanaRelayerIds: []relay.ID{ {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID1)}, {Network: relay.Solana, ChainID: relay.ChainID(solanaChainID2)}, }, expectedStarknetChainCnt: 2, expectedStarknetNodeCnt: 4, - expectedStarknetRelayerIds: []relay.Identifier{ + expectedStarknetRelayerIds: []relay.ID{ {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID1)}, {Network: relay.StarkNet, ChainID: relay.ChainID(starknetChainID2)}, }, expectedCosmosChainCnt: 2, expectedCosmosNodeCnt: 2, - expectedCosmosRelayerIds: []relay.Identifier{ + expectedCosmosRelayerIds: []relay.ID{ {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID1)}, {Network: relay.Cosmos, ChainID: relay.ChainID(cosmosChainID2)}, }, @@ -363,7 +363,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { } - allRelayerIds := [][]relay.Identifier{ + allRelayerIds := [][]relay.ID{ tt.expectedEVMRelayerIds, tt.expectedCosmosRelayerIds, tt.expectedSolanaRelayerIds, @@ -394,7 +394,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { } } - expectedMissing := relay.Identifier{Network: relay.Cosmos, ChainID: "not a chain id"} + expectedMissing := relay.ID{Network: relay.Cosmos, ChainID: "not a chain id"} unwanted, err := cr.Get(expectedMissing) assert.Nil(t, unwanted) assert.ErrorIs(t, err, chainlink.ErrNoSuchRelayer) diff --git a/core/services/chainlink/relayer_factory.go b/core/services/chainlink/relayer_factory.go index b7622e10e4e..ded4d1886f8 100644 --- a/core/services/chainlink/relayer_factory.go +++ b/core/services/chainlink/relayer_factory.go @@ -37,10 +37,10 @@ type EVMFactoryConfig struct { evmrelay.CSAETHKeystore } -func (r *RelayerFactory) NewEVM(ctx context.Context, config EVMFactoryConfig) (map[relay.Identifier]evmrelay.LoopRelayAdapter, error) { +func (r *RelayerFactory) NewEVM(ctx context.Context, config EVMFactoryConfig) (map[relay.ID]evmrelay.LoopRelayAdapter, error) { // TODO impl EVM loop. For now always 'fallback' to an adapter and embedded chainset - relayers := make(map[relay.Identifier]evmrelay.LoopRelayAdapter) + relayers := make(map[relay.ID]evmrelay.LoopRelayAdapter) // override some common opts with the factory values. this seems weird... maybe other signatures should change, or this should take a different type... ccOpts := evm.ChainRelayExtenderConfig{ @@ -57,7 +57,7 @@ func (r *RelayerFactory) NewEVM(ctx context.Context, config EVMFactoryConfig) (m } legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(evmRelayExtenders) for _, ext := range evmRelayExtenders.Slice() { - relayID := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(ext.Chain().ID().String())} + relayID := relay.ID{Network: relay.EVM, ChainID: relay.ChainID(ext.Chain().ID().String())} chain, err := legacyChains.Get(relayID.ChainID.String()) if err != nil { return nil, err @@ -74,8 +74,8 @@ type SolanaFactoryConfig struct { solana.SolanaConfigs } -func (r *RelayerFactory) NewSolana(ks keystore.Solana, chainCfgs solana.SolanaConfigs) (map[relay.Identifier]loop.Relayer, error) { - solanaRelayers := make(map[relay.Identifier]loop.Relayer) +func (r *RelayerFactory) NewSolana(ks keystore.Solana, chainCfgs solana.SolanaConfigs) (map[relay.ID]loop.Relayer, error) { + solanaRelayers := make(map[relay.ID]loop.Relayer) var ( solLggr = r.Logger.Named("Solana") signer = &keystore.SolanaSigner{Solana: ks} @@ -83,7 +83,7 @@ func (r *RelayerFactory) NewSolana(ks keystore.Solana, chainCfgs solana.SolanaCo // create one relayer per chain id for _, chainCfg := range chainCfgs { - relayId := relay.Identifier{Network: relay.Solana, ChainID: relay.ChainID(*chainCfg.ChainID)} + relayId := relay.ID{Network: relay.Solana, ChainID: relay.ChainID(*chainCfg.ChainID)} // all the lower level APIs expect chainsets. create a single valued set per id singleChainCfg := solana.SolanaConfigs{chainCfg} @@ -128,8 +128,8 @@ type StarkNetFactoryConfig struct { starknet.StarknetConfigs } -func (r *RelayerFactory) NewStarkNet(ks keystore.StarkNet, chainCfgs starknet.StarknetConfigs) (map[relay.Identifier]loop.Relayer, error) { - starknetRelayers := make(map[relay.Identifier]loop.Relayer) +func (r *RelayerFactory) NewStarkNet(ks keystore.StarkNet, chainCfgs starknet.StarknetConfigs) (map[relay.ID]loop.Relayer, error) { + starknetRelayers := make(map[relay.ID]loop.Relayer) var ( starkLggr = r.Logger.Named("StarkNet") @@ -138,7 +138,7 @@ func (r *RelayerFactory) NewStarkNet(ks keystore.StarkNet, chainCfgs starknet.St // create one relayer per chain id for _, chainCfg := range chainCfgs { - relayId := relay.Identifier{Network: relay.StarkNet, ChainID: relay.ChainID(*chainCfg.ChainID)} + relayId := relay.ID{Network: relay.StarkNet, ChainID: relay.ChainID(*chainCfg.ChainID)} // all the lower level APIs expect chainsets. create a single valued set per id singleChainCfg := starknet.StarknetConfigs{chainCfg} @@ -185,14 +185,14 @@ type CosmosFactoryConfig struct { EventBroadcaster pg.EventBroadcaster } -func (r *RelayerFactory) NewCosmos(ctx context.Context, config CosmosFactoryConfig) (map[relay.Identifier]cosmos.LoopRelayerChainer, error) { - relayers := make(map[relay.Identifier]cosmos.LoopRelayerChainer) +func (r *RelayerFactory) NewCosmos(ctx context.Context, config CosmosFactoryConfig) (map[relay.ID]cosmos.LoopRelayerChainer, error) { + relayers := make(map[relay.ID]cosmos.LoopRelayerChainer) var lggr = r.Logger.Named("Cosmos") // create one relayer per chain id for _, chainCfg := range config.CosmosConfigs { - relayId := relay.Identifier{Network: relay.Cosmos, ChainID: relay.ChainID(*chainCfg.ChainID)} + relayId := relay.ID{Network: relay.Cosmos, ChainID: relay.ChainID(*chainCfg.ChainID)} // all the lower level APIs expect chainsets. create a single valued set per id // TODO: Cosmos LOOPp impl. For now, use relayer adapter diff --git a/core/services/job/models.go b/core/services/job/models.go index 7c61fbf1e46..d70afde12c2 100644 --- a/core/services/job/models.go +++ b/core/services/job/models.go @@ -358,18 +358,15 @@ type OCR2OracleSpec struct { CaptureAutomationCustomTelemetry bool `toml:"captureAutomationCustomTelemetry"` } -func (s *OCR2OracleSpec) RelayIdentifier() (relay.Identifier, error) { - var id relay.Identifier - cid, err := s.GetChainID() +func (s *OCR2OracleSpec) RelayID() (relay.ID, error) { + cid, err := s.getChainID() if err != nil { - return id, err + return relay.ID{}, err } - id.ChainID = cid - id.Network = s.Relay - return id, nil + return relay.NewID(s.Relay, cid) } -func (s *OCR2OracleSpec) GetChainID() (relay.ChainID, error) { +func (s *OCR2OracleSpec) getChainID() (relay.ChainID, error) { if s.ChainID != "" { return relay.ChainID(s.ChainID), nil } diff --git a/core/services/job/models_test.go b/core/services/job/models_test.go index bf28a0553ba..277f0d7eb29 100644 --- a/core/services/job/models_test.go +++ b/core/services/job/models_test.go @@ -16,12 +16,12 @@ func TestOCR2OracleSpec_RelayIdentifier(t *testing.T) { tests := []struct { name string fields fields - want relay.Identifier + want relay.ID wantErr bool }{ {name: "err no chain id", fields: fields{}, - want: relay.Identifier{}, + want: relay.ID{}, wantErr: true, }, { @@ -30,7 +30,7 @@ func TestOCR2OracleSpec_RelayIdentifier(t *testing.T) { Relay: relay.EVM, ChainID: "1", }, - want: relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID("1")}, + want: relay.ID{Network: relay.EVM, ChainID: relay.ChainID("1")}, }, { name: "evm implicitly configured", @@ -38,7 +38,7 @@ func TestOCR2OracleSpec_RelayIdentifier(t *testing.T) { Relay: relay.EVM, RelayConfig: map[string]any{"chainID": 1}, }, - want: relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID("1")}, + want: relay.ID{Network: relay.EVM, ChainID: relay.ChainID("1")}, }, { name: "evm implicitly configured with bad value", @@ -46,7 +46,7 @@ func TestOCR2OracleSpec_RelayIdentifier(t *testing.T) { Relay: relay.EVM, RelayConfig: map[string]any{"chainID": float32(1)}, }, - want: relay.Identifier{}, + want: relay.ID{}, wantErr: true, }, } @@ -60,7 +60,7 @@ func TestOCR2OracleSpec_RelayIdentifier(t *testing.T) { ChainID: tt.fields.ChainID, RelayConfig: tt.fields.RelayConfig, } - got, err := s.RelayIdentifier() + got, err := s.RelayID() if (err != nil) != tt.wantErr { t.Errorf("OCR2OracleSpec.RelayIdentifier() error = %v, wantErr %v", err, tt.wantErr) return diff --git a/core/services/job/spawner_test.go b/core/services/job/spawner_test.go index f0956958fa0..a013bd50bc1 100644 --- a/core/services/job/spawner_test.go +++ b/core/services/job/spawner_test.go @@ -69,7 +69,7 @@ type relayGetter struct { func newrelayGetter() *relayGetter { return &relayGetter{} } -func (g *relayGetter) Get(id relay.Identifier) (loop.Relayer, error) { +func (g *relayGetter) Get(id relay.ID) (loop.Relayer, error) { return evmrelayer.NewLoopRelayAdapter(g.r, g.e), nil } diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 6d91bf448b0..0a8e4c05509 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -6,7 +6,6 @@ import ( "encoding/json" "fmt" "log" - "math/big" "time" "gopkg.in/guregu/null.v4" @@ -71,8 +70,10 @@ import ( "github.com/smartcontractkit/chainlink/v2/plugins" ) +var ErrJobSpecNoRelayer = errors.New("OCR2 job spec could not get relayer id") + type RelayGetter interface { - Get(id relay.Identifier) (loop.Relayer, error) + Get(id relay.ID) (loop.Relayer, error) } type Delegate struct { db *sqlx.DB @@ -236,34 +237,37 @@ func (d *Delegate) AfterJobCreated(spec job.Job) {} func (d *Delegate) BeforeJobDeleted(spec job.Job) {} func (d *Delegate) OnDeleteJob(jb job.Job, q pg.Queryer) error { // If the job spec is malformed in any way, we report the error but return nil so that - // the job deletion itself isn't blocked. However, if UnregisterFilter returns an - // error, that means it failed to remove a valid active filter from the db. We do abort the job deletion - // in that case, since it should be easy for the user to retry and will avoid leaving the db in - // an inconsistent state. This assumes UnregisterFilter will return nil if the filter wasn't found - // at all (no rows deleted). + // the job deletion itself isn't blocked. spec := jb.OCR2OracleSpec if spec == nil { d.lggr.Errorf("offchainreporting2.Delegate.OnDeleteJob called with wrong job type, ignoring non-OCR2 spec %v", jb) return nil } - if spec.Relay != relay.EVM { - return nil - } - chainID, err := spec.GetChainID() + rid, err := spec.RelayID() if err != nil { - d.lggr.Errorw("OCR2 job spec missing chainID", "err", err) + d.lggr.Errorw("DeleteJob: "+ErrJobSpecNoRelayer.Error(), "err", err) return nil } - _, err = chainID.Int64() - if err != nil { - d.lggr.Errorw("OCR2 chainID not evm compatible", "err", err) - return nil + // we only have clean to do for the EVM + if rid.Network == relay.EVM { + return d.cleanupEVM(jb, q, rid) } - chain, err := d.legacyChains.Get(chainID.String()) + return nil +} + +// cleanupEVM is a helper for clean up EVM specific state when a job is deleted +func (d *Delegate) cleanupEVM(jb job.Job, q pg.Queryer, relayID relay.ID) error { + // If UnregisterFilter returns an + // error, that means it failed to remove a valid active filter from the db. We do abort the job deletion + // in that case, since it should be easy for the user to retry and will avoid leaving the db in + // an inconsistent state. This assumes UnregisterFilter will return nil if the filter wasn't found + // at all (no rows deleted). + spec := jb.OCR2OracleSpec + chain, err := d.legacyChains.Get(relayID.ChainID.String()) if err != nil { - d.lggr.Error(err) + d.lggr.Error("cleanupEVM: failed to chain get chain %s", "err", relayID.ChainID, err) return nil } lp := chain.LogPoller() @@ -333,19 +337,19 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC } lggr := logger.Sugared(d.lggr.Named("OCR2").With(lggrCtx.Args()...)) - if spec.Relay == relay.EVM { - chainID, err2 := spec.GetChainID() - if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec failed to get chainID: %w", err2) - } + rid, err := spec.RelayID() + if err != nil { + return nil, fmt.Errorf("ServicesForSpec: %w: %w", ErrJobSpecNoRelayer, err) + } - _, err2 = chainID.Int64() + if rid.Network == relay.EVM { + lggr = logger.Sugared(lggr.With("evmChainID", rid.ChainID)) + + chain, err2 := d.legacyChains.Get(rid.ChainID.String()) if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + return nil, fmt.Errorf("ServicesForSpec: could not get EVM chain %s: %w", rid.ChainID, err2) } - lggr = logger.Sugared(lggr.With("evmChainID", chainID)) - - effectiveTransmitterID, err2 = GetEVMEffectiveTransmitterID(&jb, d.legacyChains, chainID.String(), lggr) + effectiveTransmitterID, err2 = GetEVMEffectiveTransmitterID(&jb, chain, lggr) if err2 != nil { return nil, fmt.Errorf("ServicesForSpec failed to get evm transmitterID: %w", err2) } @@ -431,7 +435,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC } } -func GetEVMEffectiveTransmitterID(jb *job.Job, legacyChains evm.LegacyChainContainer, chainID string, lggr logger.SugaredLogger) (string, error) { +func GetEVMEffectiveTransmitterID(jb *job.Job, chain evm.Chain, lggr logger.SugaredLogger) (string, error) { spec := jb.OCR2OracleSpec if spec.PluginType == job.Mercury { return spec.TransmitterID.String, nil @@ -444,7 +448,6 @@ func GetEVMEffectiveTransmitterID(jb *job.Job, legacyChains evm.LegacyChainConta if err != nil { return "", err } - if len(sendingKeys) > 1 && spec.PluginType != job.OCR2VRF { return "", errors.New("only ocr2 vrf should have more than 1 sending key") } @@ -455,11 +458,9 @@ func GetEVMEffectiveTransmitterID(jb *job.Job, legacyChains evm.LegacyChainConta // In the case of forwarding, the transmitter address is the forwarder contract deployed onchain between EOA and OCR contract. // ForwardingAllowed cannot be set with Mercury, so this should always be false for mercury jobs if jb.ForwardingAllowed { - chain, err := legacyChains.Get(chainID) - if err != nil { - return "", errors.Wrap(err, "failed to get chainset") + if chain == nil { + return "", fmt.Errorf("job forwarding requires non-nil chain") } - effectiveTransmitterID, err := chain.TxManager().GetForwarderForEOA(common.HexToAddress(spec.TransmitterID.String)) if err == nil { return effectiveTransmitterID.String(), nil @@ -497,15 +498,22 @@ func (d *Delegate) newServicesMercury( return nil, errors.Wrapf(err, "ServicesForSpec: mercury job type requires transmitter ID to be a 32-byte hex string, got: %q", transmitterID) } - chainID, err := spec.GetChainID() + rid, err := spec.RelayID() if err != nil { - return nil, fmt.Errorf("ServicesForSpec failed to get chainID: %w", err) + return nil, fmt.Errorf("mercury services: %w: %w", ErrJobSpecNoRelayer, err) + } + if rid.Network != relay.EVM { + return nil, fmt.Errorf("mercury services: expected EVM relayer got %s", rid.Network) } - relayID := relay.Identifier{Network: spec.Relay, ChainID: chainID} - relayer, err := d.RelayGetter.Get(relayID) + relayer, err := d.RelayGetter.Get(rid) if err != nil { return nil, fmt.Errorf("failed to get relay %s is it enabled?: %w", spec.Relay, err) } + chain, err := d.legacyChains.Get(rid.ChainID.String()) + if err != nil { + return nil, fmt.Errorf("mercury services: failed to get chain %s: %w", rid.ChainID, err) + } + mercuryProvider, err2 := relayer.NewMercuryProvider(ctx, types.RelayArgs{ ExternalJobID: jb.ExternalJobID, @@ -521,15 +529,6 @@ func (d *Delegate) newServicesMercury( return nil, err2 } - _, err2 = chainID.Int64() - if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) - } - chain, err2 := d.legacyChains.Get(chainID.String()) - if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec failed to get chain: %w", err2) - } - oracleArgsNoPlugin := libocr2.MercuryOracleArgs{ BinaryNetworkEndpointFactory: d.peerWrapper.Peer2, V2Bootstrappers: bootstrapPeers, @@ -582,14 +581,13 @@ func (d *Delegate) newServicesMedian( enhancedTelemChan := make(chan ocrcommon.EnhancedTelemetryData, 100) mConfig := median.NewMedianConfig(d.cfg.JobPipeline().MaxSuccessfulRuns(), d.cfg) - chainID, err := spec.GetChainID() + rid, err := spec.RelayID() if err != nil { - return nil, fmt.Errorf("failed to get chainID from spec: %w", err) + return nil, fmt.Errorf("median services: %w: %w", ErrJobSpecNoRelayer, err) } - relayID := relay.Identifier{Network: spec.Relay, ChainID: chainID} - relayer, err := d.RelayGetter.Get(relayID) + relayer, err := d.RelayGetter.Get(rid) if err != nil { - return nil, fmt.Errorf("failed to get relay %s is it enabled?: %w", spec.Relay, err) + return nil, fmt.Errorf("median services; failed to get relay %s is it enabled?: %w", spec.Relay, err) } medianServices, err2 := median.NewMedianServices(ctx, jb, d.isNewlyCreatedJob, relayer, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, mConfig, enhancedTelemChan, errorLog) @@ -612,17 +610,17 @@ func (d *Delegate) newServicesDKG( ocrLogger commontypes.Logger, ) ([]job.ServiceCtx, error) { spec := jb.OCR2OracleSpec - chainID, err2 := spec.GetChainID() - if err2 != nil { - return nil, err2 + rid, err := spec.RelayID() + if err != nil { + return nil, fmt.Errorf("DKG services: %w: %w", ErrJobSpecNoRelayer, err) } - evmChainID, err2 := chainID.Int64() - if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + if rid.Network != relay.EVM { + return nil, fmt.Errorf("DKG services: expected EVM relayer got %s", rid.Network) } - chain, err2 := d.legacyChains.Get(chainID.String()) + + chain, err2 := d.legacyChains.Get(rid.ChainID.String()) if err2 != nil { - return nil, fmt.Errorf("get chainset: %w", err2) + return nil, fmt.Errorf("DKG services: failed to get chain %s: %w", rid.ChainID, err2) } ocr2vrfRelayer := evmrelay.NewOCR2VRFRelayer(d.db, chain, lggr.Named("OCR2VRFRelayer"), d.ethKs) dkgProvider, err2 := ocr2vrfRelayer.NewDKGProvider( @@ -665,7 +663,7 @@ func (d *Delegate) newServicesDKG( oracleArgsNoPlugin, d.db, d.cfg.Database(), - big.NewInt(evmChainID), + chain.ID(), spec.Relay, ) } @@ -680,17 +678,17 @@ func (d *Delegate) newServicesOCR2VRF( lc ocrtypes.LocalConfig, ) ([]job.ServiceCtx, error) { spec := jb.OCR2OracleSpec - chainID, err2 := spec.GetChainID() - if err2 != nil { - return nil, err2 + + rid, err := spec.RelayID() + if err != nil { + return nil, fmt.Errorf("VRF services: %w: %w", ErrJobSpecNoRelayer, err) } - evmChainID, err2 := chainID.Int64() - if err2 != nil { - return nil, fmt.Errorf("chainID not evm compatible: %w", err2) + if rid.Network != relay.EVM { + return nil, fmt.Errorf("VRF services: expected EVM relayer got %s", rid.Network) } - chain, err2 := d.legacyChains.Get(chainID.String()) + chain, err2 := d.legacyChains.Get(rid.ChainID.String()) if err2 != nil { - return nil, fmt.Errorf("get chainset: %w", err2) + return nil, fmt.Errorf("VRF services: failed to get chain (%s): %w", rid.ChainID, err2) } if jb.ForwardingAllowed != chain.Config().EVM().Transactions().ForwardersEnabled() { return nil, errors.New("transaction forwarding settings must be consistent for ocr2vrf") @@ -834,7 +832,7 @@ func (d *Delegate) newServicesOCR2VRF( KeyID: keyID, DKGReportingPluginFactoryDecorator: dkgReportingPluginFactoryDecorator, VRFReportingPluginFactoryDecorator: vrfReportingPluginFactoryDecorator, - DKGSharePersistence: persistence.NewShareDB(d.db, lggr.Named("DKGShareDB"), d.cfg.Database(), big.NewInt(evmChainID), spec.Relay), + DKGSharePersistence: persistence.NewShareDB(d.db, lggr.Named("DKGShareDB"), d.cfg.Database(), chain.ID(), spec.Relay), }) if err2 != nil { return nil, errors.Wrap(err2, "new ocr2vrf") @@ -906,17 +904,17 @@ func (d *Delegate) newServicesOCR2Keepers21( } mc := d.cfg.Mercury().Credentials(credName) - chainID, err2 := spec.GetChainID() - if err2 != nil { - return nil, err2 + rid, err := spec.RelayID() + if err != nil { + return nil, fmt.Errorf("keeper2 services: %w: %w", ErrJobSpecNoRelayer, err) } - _, err2 = chainID.Int64() - if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + if rid.Network != relay.EVM { + return nil, fmt.Errorf("keeper2 services: expected EVM relayer got %s", rid.Network) } - chain, err2 := d.legacyChains.Get(chainID.String()) + + chain, err2 := d.legacyChains.Get(rid.ChainID.String()) if err2 != nil { - return nil, fmt.Errorf("get chainset: %w", err2) + return nil, fmt.Errorf("keeper2 services: failed to get chain %s: %w", rid.ChainID, err2) } keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, payloadBuilder, upkeepStateStore, up, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, chain, d.pipelineRunner, mc, kb) @@ -1017,18 +1015,19 @@ func (d *Delegate) newServicesOCR2Keepers20( cfg ocr2keeper.PluginConfig, spec *job.OCR2OracleSpec, ) ([]job.ServiceCtx, error) { - chainID, err2 := spec.GetChainID() - if err2 != nil { - return nil, err2 + + rid, err := spec.RelayID() + if err != nil { + return nil, fmt.Errorf("keepers2.0 services: %w: %w", ErrJobSpecNoRelayer, err) } - _, err2 = chainID.Int64() - if err2 != nil { - return nil, fmt.Errorf("ServicesForSpec chainID not evm compatible: %w", err2) + if rid.Network != relay.EVM { + return nil, fmt.Errorf("keepers2.0 services: expected EVM relayer got %s", rid.Network) } - chain, err2 := d.legacyChains.Get(chainID.String()) + chain, err2 := d.legacyChains.Get(rid.ChainID.String()) if err2 != nil { - return nil, fmt.Errorf("get chainset: %w", err2) + return nil, fmt.Errorf("keepers2.0 services: failed to get chain (%s): %w", rid.ChainID, err2) } + keeperProvider, rgstry, encoder, logProvider, err2 := ocr2keeper.EVMDependencies20(jb, d.db, lggr, chain, d.pipelineRunner) if err2 != nil { return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") @@ -1151,17 +1150,17 @@ func (d *Delegate) newServicesOCR2Functions( ocrLogger commontypes.Logger, ) ([]job.ServiceCtx, error) { spec := jb.OCR2OracleSpec - if spec.Relay != relay.EVM { - return nil, fmt.Errorf("unsupported relay: %s", spec.Relay) - } - relayerID, err := spec.RelayIdentifier() + rid, err := spec.RelayID() if err != nil { - return nil, fmt.Errorf("functions: OCR2 Delegate could not get relayer: %w", err) + return nil, fmt.Errorf("functions services: %w: %w", ErrJobSpecNoRelayer, err) + } + if rid.Network != relay.EVM { + return nil, fmt.Errorf("functions services: expected EVM relayer got %s", rid.Network) } - chain, err := d.legacyChains.Get(relayerID.ChainID.String()) + chain, err := d.legacyChains.Get(rid.ChainID.String()) if err != nil { - return nil, fmt.Errorf("functions: OCR2 Delegate could not find chain id (%s) given in the spec: %w", relayerID.ChainID, err) + return nil, fmt.Errorf("functions services: failed to get chain %s: %w", rid.ChainID, err) } createPluginProvider := func(pluginType functionsRelay.FunctionsPluginType, relayerName string) (evmrelaytypes.FunctionsProvider, error) { return evmrelay.NewFunctionsProvider( diff --git a/core/services/ocr2/delegate_test.go b/core/services/ocr2/delegate_test.go index 8bb3288cb36..066b2eb2876 100644 --- a/core/services/ocr2/delegate_test.go +++ b/core/services/ocr2/delegate_test.go @@ -8,7 +8,6 @@ import ( "github.com/stretchr/testify/require" "gopkg.in/guregu/null.v4" - "github.com/smartcontractkit/chainlink/v2/core/chains" evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" txmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/txmgr/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/cltest" @@ -140,7 +139,9 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { require.NoError(t, err) jb.OCR2OracleSpec.TransmitterID = null.StringFrom("some transmitterID string") jb.OCR2OracleSpec.RelayConfig["sendingKeys"] = nil - effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, legacyChains, customChainID.String(), lggr) + chain, err := legacyChains.Get(customChainID.String()) + require.NoError(t, err) + effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, chain, lggr) require.NoError(t, err) require.Equal(t, "some transmitterID string", effectiveTransmitterID) require.Equal(t, []string{"some transmitterID string"}, jb.OCR2OracleSpec.RelayConfig["sendingKeys"].([]string)) @@ -151,8 +152,10 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { jb, err := ocr2validate.ValidatedOracleSpecToml(config.OCR2(), config.Insecure(), testspecs.OCR2EVMSpecMinimal) require.NoError(t, err) setTestCase(&jb, tc, txManager) + chain, err := legacyChains.Get(customChainID.String()) + require.NoError(t, err) - effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, legacyChains, customChainID.String(), lggr) + effectiveTransmitterID, err := ocr2.GetEVMEffectiveTransmitterID(&jb, chain, lggr) if tc.expectedError { require.Error(t, err) } else { @@ -173,8 +176,9 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { require.NoError(t, err) jb.ForwardingAllowed = true jb.OCR2OracleSpec.TransmitterID = null.StringFrom("0x7e57000000000000000000000000000000000001") - _, err = ocr2.GetEVMEffectiveTransmitterID(&jb, legacyChains, "-1", lggr) + chain, err := legacyChains.Get("not an id") + require.Error(t, err) + _, err = ocr2.GetEVMEffectiveTransmitterID(&jb, chain, lggr) require.Error(t, err) - require.ErrorIs(t, err, chains.ErrNoSuchChainID) }) } diff --git a/core/services/ocrbootstrap/delegate.go b/core/services/ocrbootstrap/delegate.go index 5e16c13d51d..b39f9eec6ec 100644 --- a/core/services/ocrbootstrap/delegate.go +++ b/core/services/ocrbootstrap/delegate.go @@ -23,7 +23,7 @@ import ( ) type RelayGetter interface { - Get(relay.Identifier) (loop.Relayer, error) + Get(relay.ID) (loop.Relayer, error) } // Delegate creates Bootstrap jobs @@ -87,14 +87,14 @@ func (d *Delegate) ServicesForSpec(jobSpec job.Job, qopts ...pg.QOpt) (services return nil, errors.New("peerWrapper is not started. OCR2 jobs require a started and running p2p v2 peer") } s := spec.AsOCR2Spec() - chainID, err := (&s).GetChainID() + rid, err := s.RelayID() if err != nil { - return nil, err + return nil, fmt.Errorf("ServicesForSpec: could not get relayer: %w", err) } - relayID := relay.Identifier{Network: spec.Relay, ChainID: chainID} - relayer, err := d.RelayGetter.Get(relayID) + + relayer, err := d.RelayGetter.Get(rid) if err != nil { - return nil, fmt.Errorf("failed to get relay %s is it enabled?: %w", spec.Relay, err) + return nil, fmt.Errorf("ServiceForSpec: failed to get relay %s is it enabled?: %w", rid.Name(), err) } if spec.FeedID != nil { spec.RelayConfig["feedID"] = *spec.FeedID diff --git a/core/services/relay/relay.go b/core/services/relay/relay.go index 9ee982036cb..c6d3ab6a900 100644 --- a/core/services/relay/relay.go +++ b/core/services/relay/relay.go @@ -30,25 +30,43 @@ var ( } ) -// Identifier uniquely identifies a relayer by network and chain id -type Identifier struct { +// ID uniquely identifies a relayer by network and chain id +type ID struct { Network Network ChainID ChainID } -func (i *Identifier) Name() string { +func (i *ID) Name() string { return fmt.Sprintf("%s.%s", i.Network, i.ChainID.String()) } -func (i *Identifier) String() string { +func (i *ID) String() string { return i.Name() } +func NewID(n Network, c ChainID) (ID, error) { + id := ID{Network: n, ChainID: c} + err := id.validate() + if err != nil { + return ID{}, err + } + return id, nil +} +func (i *ID) validate() error { + // the only validation is to ensure that EVM chain ids are compatible with int64 + if i.Network == EVM { + _, err := i.ChainID.Int64() + if err != nil { + return fmt.Errorf("RelayIdentifier invalid: EVM relayer must have integer-compatible chain ID: %w", err) + } + } + return nil +} var idRegex = regexp.MustCompile( fmt.Sprintf("^((%s)|(%s)|(%s)|(%s))\\.", EVM, Cosmos, Solana, StarkNet), ) -func (i *Identifier) UnmarshalString(s string) error { +func (i *ID) UnmarshalString(s string) error { idxs := idRegex.FindStringIndex(s) if idxs == nil { return fmt.Errorf("error unmarshaling Identifier. %q does not match expected pattern", s) @@ -56,7 +74,7 @@ func (i *Identifier) UnmarshalString(s string) error { // ignore the `.` in the match by dropping last rune network := s[idxs[0] : idxs[1]-1] chainID := s[idxs[1]:] - newID := &Identifier{ChainID: ChainID(chainID)} + newID := &ID{ChainID: ChainID(chainID)} for n := range SupportedRelays { if Network(network) == n { newID.Network = n diff --git a/core/services/relay/relay_test.go b/core/services/relay/relay_test.go index 967bca48da9..0ed14b6c5b7 100644 --- a/core/services/relay/relay_test.go +++ b/core/services/relay/relay_test.go @@ -36,7 +36,7 @@ func TestIdentifier_UnmarshalString(t *testing.T) { } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { - i := &Identifier{} + i := &ID{} err := i.UnmarshalString(tt.args.s) if (err != nil) != tt.wantErr { t.Errorf("Identifier.UnmarshalString() error = %v, wantErr %v", err, tt.wantErr) @@ -46,3 +46,36 @@ func TestIdentifier_UnmarshalString(t *testing.T) { }) } } + +func TestNewID(t *testing.T) { + type args struct { + n Network + c ChainID + } + tests := []struct { + name string + args args + want ID + wantErr bool + }{ + {name: "good evm", + args: args{n: EVM, c: "1"}, + want: ID{Network: EVM, ChainID: "1"}, + }, + {name: "bad evm", + args: args{n: EVM, c: "not a number"}, + want: ID{}, + wantErr: true, + }, + } + for _, tt := range tests { + t.Run(tt.name, func(t *testing.T) { + got, err := NewID(tt.args.n, tt.args.c) + if (err != nil) != tt.wantErr { + t.Errorf("NewID() error = %v, wantErr %v", err, tt.wantErr) + return + } + assert.Equal(t, tt.want, got, "got id %v", got) + }) + } +} diff --git a/core/web/chains_controller.go b/core/web/chains_controller.go index a932738fa88..c11d457c49c 100644 --- a/core/web/chains_controller.go +++ b/core/web/chains_controller.go @@ -79,7 +79,7 @@ func (cc *chainsController[R]) Show(c *gin.Context) { jsonAPIError(c, http.StatusBadRequest, cc.errNotEnabled) return } - relayID := relay.Identifier{Network: cc.network, ChainID: relay.ChainID(c.Param("ID"))} + relayID := relay.ID{Network: cc.network, ChainID: relay.ChainID(c.Param("ID"))} chain, err := cc.chainStats.ChainStatus(c, relayID) if err != nil { jsonAPIError(c, http.StatusBadRequest, err) diff --git a/core/web/loader/loader_test.go b/core/web/loader/loader_test.go index 0b37b8ce892..d5123053cf2 100644 --- a/core/web/loader/loader_test.go +++ b/core/web/loader/loader_test.go @@ -69,9 +69,9 @@ func TestLoader_Nodes(t *testing.T) { ctx := InjectDataloader(testutils.Context(t), app) chainID1, chainID2, notAnID := big.NewInt(1), big.NewInt(2), big.NewInt(3) - relayID1 := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(chainID1.String())} - relayID2 := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(chainID2.String())} - notARelayID := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(notAnID.String())} + relayID1 := relay.ID{Network: relay.EVM, ChainID: relay.ChainID(chainID1.String())} + relayID2 := relay.ID{Network: relay.EVM, ChainID: relay.ChainID(chainID2.String())} + notARelayID := relay.ID{Network: relay.EVM, ChainID: relay.ChainID(notAnID.String())} genNodeStat := func(id string) relaytypes.NodeStatus { return relaytypes.NodeStatus{ diff --git a/core/web/loader/node.go b/core/web/loader/node.go index b6b16c23e6c..fb0c58d1f2c 100644 --- a/core/web/loader/node.go +++ b/core/web/loader/node.go @@ -23,7 +23,7 @@ func (b *nodeBatcher) loadByChainIDs(ctx context.Context, keys dataloader.Keys) var evmrelayIdStrs []string for ix, key := range keys { - rid := relay.Identifier{Network: relay.EVM, ChainID: relay.ChainID(key.String())} + rid := relay.ID{Network: relay.EVM, ChainID: relay.ChainID(key.String())} evmrelayIdStrs = append(evmrelayIdStrs, rid.String()) keyOrder[key.String()] = ix } diff --git a/core/web/solana_transfer_controller.go b/core/web/solana_transfer_controller.go index cd650f37ba1..8238f775626 100644 --- a/core/web/solana_transfer_controller.go +++ b/core/web/solana_transfer_controller.go @@ -48,7 +48,7 @@ func (tc *SolanaTransfersController) Create(c *gin.Context) { } amount := new(big.Int).SetUint64(tr.Amount) - relayerID := relay.Identifier{Network: relay.Solana, ChainID: relay.ChainID(tr.SolanaChainID)} + relayerID := relay.ID{Network: relay.Solana, ChainID: relay.ChainID(tr.SolanaChainID)} relayer, err := relayers.Get(relayerID) if err != nil { if errors.Is(err, chainlink.ErrNoSuchRelayer) { From f5e35cf960e86c72ea3d684d671030e59a837af6 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Sun, 20 Aug 2023 18:27:14 -0500 Subject: [PATCH 214/270] golangci-lint (#10258) * golangci-lint: ineffectual assignment to err (ineffassign) * this result of append is never used, except maybe in other appends (staticcheck) * Fixing Test_EthResender_resendUnconfirmed (#10266) --------- Co-authored-by: Patrick --- core/chains/evm/txmgr/resender_test.go | 12 ++++++------ core/chains/evm/types/types_test.go | 4 ++++ core/cmd/shell.go | 1 + core/internal/cltest/cltest.go | 4 ---- .../integration_tests/v1/internal/testutils.go | 3 ++- .../ocr2keeper/evm21/logprovider/integration_test.go | 1 + core/services/vrf/v2/integration_helpers_test.go | 4 ---- core/services/vrf/v2/integration_v2_test.go | 1 + 8 files changed, 15 insertions(+), 15 deletions(-) diff --git a/core/chains/evm/txmgr/resender_test.go b/core/chains/evm/txmgr/resender_test.go index 32523ab5c26..60b6bcdce20 100644 --- a/core/chains/evm/txmgr/resender_test.go +++ b/core/chains/evm/txmgr/resender_test.go @@ -67,10 +67,10 @@ func Test_EthResender_resendUnconfirmed(t *testing.T) { er := txmgr.NewEvmResender(lggr, txStore, txmgr.NewEvmTxmClient(ethClient), ethKeyStore, 100*time.Millisecond, ccfg.EVM(), ccfg.EVM().Transactions()) + var resentHex = make(map[string]struct{}) ethClient.On("BatchCallContextAll", mock.Anything, mock.MatchedBy(func(elems []rpc.BatchElem) bool { - resentHex := make([]string, len(elems)) - for i, elem := range elems { - resentHex[i] = elem.Args[0].(string) + for _, elem := range elems { + resentHex[elem.Args[0].(string)] = struct{}{} } assert.Len(t, elems, len(addr1TxesRawHex)+len(addr2TxesRawHex)+int(txConfig.MaxInFlight())) // All addr1TxesRawHex should be included @@ -78,12 +78,12 @@ func Test_EthResender_resendUnconfirmed(t *testing.T) { assert.Contains(t, resentHex, addr) } // All addr2TxesRawHex should be included - for _, addr := range addr1TxesRawHex { + for _, addr := range addr2TxesRawHex { assert.Contains(t, resentHex, addr) } // Up to limit EvmMaxInFlightTransactions addr3TxesRawHex should be included - for i, addr := range addr1TxesRawHex { - if i > int(txConfig.MaxInFlight()) { + for i, addr := range addr3TxesRawHex { + if i >= int(txConfig.MaxInFlight()) { // Above limit EvmMaxInFlightTransactions addr3TxesRawHex should NOT be included assert.NotContains(t, resentHex, addr) } else { diff --git a/core/chains/evm/types/types_test.go b/core/chains/evm/types/types_test.go index 09a6d553a79..f285849ce92 100644 --- a/core/chains/evm/types/types_test.go +++ b/core/chains/evm/types/types_test.go @@ -228,8 +228,10 @@ func Test_AddressArrayScan(t *testing.T) { require.NoError(t, err) require.Len(t, addr1, 20) addr2, err := hex.DecodeString("56b9a2dc53736b361b72d900cdf9f78f9406fbbb") + require.NoError(t, err) require.Len(t, addr2, 20) toolong, err := hex.DecodeString("6b361b72d900cdf9f78f9406fbbb6b361b72d900cdf9f78f9406fbbb") + require.NoError(t, err) require.Len(t, toolong, 28) a := types.AddressArray{} @@ -244,8 +246,10 @@ func Test_HashArrayScan(t *testing.T) { require.NoError(t, err) require.Len(t, h1, 32) h2, err := hex.DecodeString("56b9a2dc53736b361b72d900cdf9f78f9406fbbb06fbbb6b361b7206fbbb6b36") + require.NoError(t, err) require.Len(t, h2, 32) tooshort, err := hex.DecodeString("6b361b72d900cdf9f78f9406fbbb6b361b72d900cdf9f78f9406fbbb") + require.NoError(t, err) require.Len(t, tooshort, 28) h := types.HashArray{} diff --git a/core/cmd/shell.go b/core/cmd/shell.go index 2ddc312b17a..2ffdebe16e8 100644 --- a/core/cmd/shell.go +++ b/core/cmd/shell.go @@ -32,6 +32,7 @@ import ( "github.com/smartcontractkit/sqlx" "github.com/smartcontractkit/chainlink-relay/pkg/loop" + "github.com/smartcontractkit/chainlink/v2/core/build" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/config" diff --git a/core/internal/cltest/cltest.go b/core/internal/cltest/cltest.go index 554484af9ba..7a315acd9d9 100644 --- a/core/internal/cltest/cltest.go +++ b/core/internal/cltest/cltest.go @@ -383,10 +383,6 @@ func NewApplicationWithConfig(t testing.TB, cfg chainlink.GeneralConfig, flagsAn } keyStore := keystore.New(db, utils.FastScryptParams, lggr, cfg.Database()) - var ids []utils.Big - for _, c := range cfg.EVMConfigs() { - ids = append(ids, *c.ChainID) - } mailMon := utils.NewMailboxMonitor(cfg.AppID().String()) loopRegistry := plugins.NewLoopRegistry(lggr.Named("LoopRegistry")) diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go index 827323c2d22..f25abf9c1d4 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/internal/testutils.go @@ -118,11 +118,12 @@ func CreateAndFundSubscriptions(t *testing.T, b *backends.SimulatedBackend, owne privateKey, err := crypto.HexToECDSA(allowListPrivateKey[2:]) require.NoError(t, err) flatSignature, err := crypto.Sign(message[:], privateKey) + require.NoError(t, err) var r [32]byte copy(r[:], flatSignature[:32]) var s [32]byte copy(s[:], flatSignature[32:64]) - v := uint8(flatSignature[65]) + v := flatSignature[65] allowListContract.AcceptTermsOfService(owner, owner.From, owner.From, r, s, v) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index a8132c35465..6ba8da90362 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -346,6 +346,7 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { t.Log("waiting for log poller to get updated") // let the log poller work b, err := ethClient.BlockByHash(ctx, backend.Commit()) + require.NoError(t, err) latestBlock := b.Number().Int64() for { latestPolled, lberr := lp.LatestBlock(pg.WithParentCtx(ctx)) diff --git a/core/services/vrf/v2/integration_helpers_test.go b/core/services/vrf/v2/integration_helpers_test.go index dc2395ef143..43ca198334d 100644 --- a/core/services/vrf/v2/integration_helpers_test.go +++ b/core/services/vrf/v2/integration_helpers_test.go @@ -181,14 +181,12 @@ func testMultipleConsumersNeedBHS( sendEth(t, ownerKey, uni.backend, vrfKey.Address, 10) // generate n BHS keys to make sure BHS job rotates sending keys - var bhsKeys []ethkey.KeyV2 var bhsKeyAddresses []string var keySpecificOverrides []toml.KeySpecific var keys []interface{} gasLanePriceWei := assets.GWei(10) for i := 0; i < nConsumers; i++ { bhsKey := cltest.MustGenerateRandomKey(t) - bhsKeys = append(bhsKeys, bhsKey) bhsKeyAddresses = append(bhsKeyAddresses, bhsKey.Address.String()) keys = append(keys, bhsKey) keySpecificOverrides = append(keySpecificOverrides, toml.KeySpecific{ @@ -321,7 +319,6 @@ func testMultipleConsumersNeedTrustedBHS( sendEth(t, ownerKey, uni.backend, vrfKey.Address, 10) // generate n BHS keys to make sure BHS job rotates sending keys - var bhsKeys []ethkey.KeyV2 var bhsKeyAddresses []common.Address var bhsKeyAddressesStrings []string var keySpecificOverrides []toml.KeySpecific @@ -329,7 +326,6 @@ func testMultipleConsumersNeedTrustedBHS( gasLanePriceWei := assets.GWei(10) for i := 0; i < nConsumers; i++ { bhsKey := cltest.MustGenerateRandomKey(t) - bhsKeys = append(bhsKeys, bhsKey) bhsKeyAddressesStrings = append(bhsKeyAddressesStrings, bhsKey.Address.String()) bhsKeyAddresses = append(bhsKeyAddresses, bhsKey.Address) keys = append(keys, bhsKey) diff --git a/core/services/vrf/v2/integration_v2_test.go b/core/services/vrf/v2/integration_v2_test.go index e5b94fcdcae..6ae1cb020a5 100644 --- a/core/services/vrf/v2/integration_v2_test.go +++ b/core/services/vrf/v2/integration_v2_test.go @@ -224,6 +224,7 @@ func newVRFCoordinatorV2Universe(t *testing.T, key ethkey.KeyV2, numConsumers in // Deploy old VRF v2 coordinator from bytecode err, oldRootContractAddress, oldRootContract := deployOldCoordinator( t, linkAddress, bhsAddress, linkEthFeed, backend, neil) + require.NoError(t, err) // Deploy the VRFOwner contract, which will own the VRF coordinator // in some tests. From f321466ddd09ff63480fa3dc426b419868afe32e Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Mon, 21 Aug 2023 14:08:27 +0300 Subject: [PATCH 215/270] Keepers 2.1 Final Alignment (#10210) * added active upkeep list * active list: fix View function * encoding package * merge leftovers * revert abi.go file and test * revert abi and use encoding interface * fix tests genUpkeepID * fix util error * Use the active upkeep list * Use the ActiveUpkeepList in the upkeep provider and registry * Go mod tidy * refacor components instantiation (wip) NOTE: integration tests are not passing * rename facade to services * cleanup workID Generator * small cleanups in registry * add todos in registry * cleanup encoder dependency registry * hook in active list to payload builder * remove unused method * rename function to clarify registry * add todo in events * Cleanup active upkeep configs * add todo * rename upkeep initialization / refreshing * rename poll logs * cleanup ch state logs * instantiation refactor leftovers # Conflicts: # core/services/ocr2/plugins/ocr2keeper/evm21/registry.go # core/services/ocr2/plugins/ocr2keeper/evm21/services.go * small cleanup in processUpkeepStateLog * cleanup gas limit log * cleanup unused functions from registry * Add coverage to active upkeep list * polish upkeep state event handler * recoverer (wip) * cleanup transmit events from registry * cleanup transmit events * cleanup registry log names * break down registry * cleanup registry * fix tests * Remove the block ticker from keepers * Use ocr3 config helper * Revert "Remove the block ticker from keepers" This reverts commit 159ec6e80269d23993e0259a468c84864f91ac65. * Revert "Use ocr3 config helper" This reverts commit bf2ccaaca6b3a9aef84f3842c288c90d6fd91f6a. * Use the ocr3confighelper * recoverer (wip) * fix filter store: clone filters * recoverer backfill test (wip) * add test for recoverable backfill * fix recoverer * Add payload building functionality * Update the payload builder interface * Rework the payload builder * Update tests for payload builder * Update implementation, ignore empty payloads, update tests * state reader mock * added some unit tests for recoverer * block time resolver for log recoverer * added recoverer as a service to run * add recoevry test * Bump keepers, update the log recoverer interface, rework payload builder, add tests * fixes of check block across components * Fix tests * final merge * In the encoder, initialise the FastGasWei and LinkNative to non-nil values * Only set fast gas wei and link native from the result if they are not nil * Fix test wording * block sub: copy hash bytes * recoverer logs * add some todos and polish mercury lookup * small cleanup * payload builder small fixes * cleanup registry * fix setting block number * provider: populate check block as log block number * start upkeep state store * remove hack * negative range protection * add todo * improve log burst * state store start * log recoverer fixes * Update tests * Go imports * Fix linting * gc for recoverer * recovery integration test (wip) * minor polishing * add comment on job spec config * add todos * int test all log trigger flows * runs number check * lint * Use the crypto package instead of the math package to please the linter * Rename to randIntn * recoverer review alignments * log provider config (wip) * skip test * upkeep logs limiting + buffer fixes * update to latest ocr2keepers * review fixes * more review fixes * Add tests to the recoverer * small cleanup for recoverer * small comment * cleanup todos * cleanup todos * increase time between emit logs * update ocr2keepers * skip flaky test * fix test * polish TODOs --------- Co-authored-by: Akshay Aggarwal Co-authored-by: Fergal Gribben Co-authored-by: ferglor <19188060+ferglor@users.noreply.github.com> Co-authored-by: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- core/services/ocr2/delegate.go | 34 +- .../ocr2/plugins/ocr2keeper/config.go | 4 + .../plugins/ocr2keeper/evm21/active_list.go | 121 +++ .../ocr2keeper/evm21/active_list_test.go | 103 +++ .../ocr2keeper/evm21/block_subscriber.go | 18 +- .../ocr2keeper/evm21/core/interfaces.go | 2 + .../evm21/core/mocks/upkeep_state_reader.go | 64 ++ .../plugins/ocr2keeper/evm21/core/payload.go | 25 +- .../ocr2keeper/evm21/core/payload_test.go | 20 +- .../ocr2keeper/evm21/{ => core}/testutil.go | 10 +- .../ocr2keeper/evm21/core/type_test.go | 11 +- .../evm21/{ => encoding}/encoder.go | 37 +- .../evm21/{ => encoding}/encoder_test.go | 22 +- .../ocr2keeper/evm21/encoding/interface.go | 55 ++ .../evm21/{abi.go => encoding/packer.go} | 103 +-- .../{abi_test.go => encoding/packer_test.go} | 108 ++- .../plugins/ocr2keeper/evm21/feed_lookup.go | 111 +-- .../ocr2keeper/evm21/feed_lookup_test.go | 76 +- .../evm21/logprovider/block_time.go | 72 ++ .../evm21/logprovider/block_time_test.go | 85 ++ .../ocr2keeper/evm21/logprovider/buffer.go | 92 ++- .../evm21/logprovider/buffer_test.go | 23 +- .../ocr2keeper/evm21/logprovider/factory.go | 19 + .../evm21/logprovider/filter_store.go | 32 +- .../evm21/logprovider/filter_store_test.go | 12 +- .../evm21/logprovider/integration_test.go | 244 ++++-- .../logprovider/{abi.go => log_packer.go} | 2 +- .../ocr2keeper/evm21/logprovider/provider.go | 181 +++-- .../evm21/logprovider/provider_life_cycle.go | 21 +- .../logprovider/provider_life_cycle_test.go | 4 +- .../evm21/logprovider/provider_opts.go | 54 +- .../evm21/logprovider/provider_test.go | 28 +- .../ocr2keeper/evm21/logprovider/recoverer.go | 482 ++++++++++- .../evm21/logprovider/recoverer_test.go | 715 +++++++++++++++- .../ocr2keeper/evm21/payload_builder.go | 52 +- .../ocr2keeper/evm21/payload_builder_test.go | 209 +++++ .../ocr2/plugins/ocr2keeper/evm21/registry.go | 765 +++--------------- .../evm21/registry_check_pipeline_test.go | 603 ++++++++++++++ .../plugins/ocr2keeper/evm21/registry_test.go | 666 +-------------- .../evm21/regsitry_check_pipeline.go | 348 ++++++++ .../ocr2/plugins/ocr2keeper/evm21/services.go | 144 ++++ .../evm21/transmit_event_provider.go | 24 +- .../evm21/transmit_event_provider_test.go | 5 +- .../ocr2keeper/evm21/upkeep_provider.go | 36 +- .../ocr2keeper/evm21/upkeep_provider_test.go | 52 +- .../ocr2keeper/evm21/upkeepstate/scanner.go | 4 + .../ocr2keeper/evm21/upkeepstate/store.go | 74 +- .../evm21/upkeepstate/store_test.go | 10 +- .../plugins/ocr2keeper/integration_21_test.go | 188 +++-- core/services/ocr2/plugins/ocr2keeper/util.go | 35 +- go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 56 files changed, 4159 insertions(+), 2064 deletions(-) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/active_list.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/active_list_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/core/mocks/upkeep_state_reader.go rename core/services/ocr2/plugins/ocr2keeper/evm21/{ => core}/testutil.go (68%) rename core/services/ocr2/plugins/ocr2keeper/evm21/{ => encoding}/encoder.go (78%) rename core/services/ocr2/plugins/ocr2keeper/evm21/{ => encoding}/encoder_test.go (80%) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go rename core/services/ocr2/plugins/ocr2keeper/evm21/{abi.go => encoding/packer.go} (53%) rename core/services/ocr2/plugins/ocr2keeper/evm21/{abi_test.go => encoding/packer_test.go} (87%) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/factory.go rename core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/{abi.go => log_packer.go} (93%) create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/registry_check_pipeline_test.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/regsitry_check_pipeline.go create mode 100644 core/services/ocr2/plugins/ocr2keeper/evm21/services.go diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 3a7ea529030..5627eb126e6 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.10 + github.com/smartcontractkit/ocr2keepers v0.7.15 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index c43c5e77716..4f498b255ac 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= -github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.15 h1:MihIDmSpp62n+6NWQplNJAdD2MXs5BKh4EFOwNhAd1k= +github.com/smartcontractkit/ocr2keepers v0.7.15/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 0a8e4c05509..135344728a2 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -917,11 +917,10 @@ func (d *Delegate) newServicesOCR2Keepers21( return nil, fmt.Errorf("keeper2 services: failed to get chain %s: %w", rid.ChainID, err2) } - keeperProvider, rgstry, encoder, transmitEventProvider, logProvider, wrappedKey, blockSub, payloadBuilder, upkeepStateStore, up, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, chain, d.pipelineRunner, mc, kb) + keeperProvider, services, err2 := ocr2keeper.EVMDependencies21(jb, d.db, lggr, chain, d.pipelineRunner, mc, kb) if err2 != nil { return nil, errors.Wrap(err2, "could not build dependencies for ocr2 keepers") } - // set some defaults conf := ocr2keepers21config.ReportingFactoryConfig{ CacheExpiration: ocr2keepers21config.DefaultCacheExpiration, @@ -957,19 +956,19 @@ func (d *Delegate) newServicesOCR2Keepers21( MonitoringEndpoint: d.monitoringEndpointGen.GenMonitoringEndpoint(spec.ContractID, synchronization.OCR2Automation), OffchainConfigDigester: keeperProvider.OffchainConfigDigester(), OffchainKeyring: kb, - OnchainKeyring: wrappedKey, + OnchainKeyring: services.Keyring(), LocalConfig: lc, - LogProvider: logProvider, - EventProvider: transmitEventProvider, - Runnable: rgstry, - Encoder: encoder, - BlockSubscriber: blockSub, - RecoverableProvider: new(mockRecoverableProvider), - PayloadBuilder: payloadBuilder, - UpkeepProvider: up, - UpkeepStateUpdater: upkeepStateStore, + LogProvider: services.LogEventProvider(), + EventProvider: services.TransmitEventProvider(), + Runnable: services.Registry(), + Encoder: services.Encoder(), + BlockSubscriber: services.BlockSubscriber(), + RecoverableProvider: services.LogRecoverer(), + PayloadBuilder: services.PayloadBuilder(), + UpkeepProvider: services.UpkeepProvider(), + UpkeepStateUpdater: services.UpkeepStateStore(), UpkeepTypeGetter: ocr2keeper21core.GetUpkeepType, - WorkIDGenerator: ocr2keeper21core.WorkIDGenerator, + WorkIDGenerator: ocr2keeper21core.UpkeepWorkID, // TODO: Clean up the config CacheExpiration: cfg.CacheExpiration.Value(), CacheEvictionInterval: cfg.CacheEvictionInterval.Value(), @@ -996,9 +995,12 @@ func (d *Delegate) newServicesOCR2Keepers21( return []job.ServiceCtx{ runResultSaver, keeperProvider, - rgstry, - blockSub, - transmitEventProvider, + services.Registry(), + services.BlockSubscriber(), + services.LogEventProvider(), + services.LogRecoverer(), + services.UpkeepStateStore(), + services.TransmitEventProvider(), pluginService, }, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/config.go b/core/services/ocr2/plugins/ocr2keeper/config.go index 63751dabc27..d3035878ece 100644 --- a/core/services/ocr2/plugins/ocr2keeper/config.go +++ b/core/services/ocr2/plugins/ocr2keeper/config.go @@ -31,6 +31,10 @@ func (d Duration) Value() time.Duration { return time.Duration(d) } +// NOTE: This plugin config is shared among different versions of keepers +// Any changes to this config should keep in mind existing production +// deployments of all versions of keepers and should be backwards compatible +// with existing job specs. type PluginConfig struct { // CacheExpiration is the duration of time a cached key is available. Use // this value to balance memory usage and RPC calls. A new set of keys is diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/active_list.go b/core/services/ocr2/plugins/ocr2keeper/evm21/active_list.go new file mode 100644 index 00000000000..899dd398d03 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/active_list.go @@ -0,0 +1,121 @@ +package evm + +import ( + "math/big" + "sync" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" +) + +// ActiveUpkeepList is a list to manage active upkeep IDs +type ActiveUpkeepList interface { + // Reset resets the list to the given IDs + Reset(ids ...*big.Int) + // Add adds new entries to the list + Add(id ...*big.Int) int + // Remove removes entries from the list + Remove(id ...*big.Int) int + // View returns the list of IDs of the given type + View(...ocr2keepers.UpkeepType) []*big.Int + // IsActive returns true if the given ID is of an active upkeep + IsActive(id *big.Int) bool + Size() int +} + +type activeList struct { + items map[string]bool + lock sync.RWMutex +} + +var _ ActiveUpkeepList = &activeList{} + +// NewActiveList creates a new ActiveList +func NewActiveUpkeepList() ActiveUpkeepList { + return &activeList{ + items: make(map[string]bool), + } +} + +// Reset resets the list to the given IDs +func (al *activeList) Reset(ids ...*big.Int) { + al.lock.Lock() + defer al.lock.Unlock() + + al.items = make(map[string]bool) + for _, id := range ids { + al.items[id.String()] = true + } +} + +// Add adds new entries to the list +func (al *activeList) Add(ids ...*big.Int) int { + al.lock.Lock() + defer al.lock.Unlock() + + count := 0 + for _, id := range ids { + if key := id.String(); !al.items[key] { + count++ + al.items[key] = true + } + } + return count +} + +// Remove removes entries from the list +func (al *activeList) Remove(ids ...*big.Int) int { + al.lock.Lock() + defer al.lock.Unlock() + + count := 0 + for _, id := range ids { + key := id.String() + if al.items[key] { + count++ + delete(al.items, key) + } + } + return count +} + +// View returns the list of IDs of the given type +func (al *activeList) View(upkeepTypes ...ocr2keepers.UpkeepType) []*big.Int { + al.lock.RLock() + defer al.lock.RUnlock() + + var keys []*big.Int + for key := range al.items { + id := &ocr2keepers.UpkeepIdentifier{} + bint, ok := big.NewInt(0).SetString(key, 10) + if !ok { + continue + } + if !id.FromBigInt(bint) { + continue + } + currentType := core.GetUpkeepType(*id) + for _, t := range upkeepTypes { + if currentType == t { + keys = append(keys, bint) + break + } + } + } + return keys +} + +func (al *activeList) IsActive(id *big.Int) bool { + al.lock.RLock() + defer al.lock.RUnlock() + + return al.items[id.String()] +} + +func (al *activeList) Size() int { + al.lock.RLock() + defer al.lock.RUnlock() + + return len(al.items) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/active_list_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/active_list_test.go new file mode 100644 index 00000000000..76ca6bfdf19 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/active_list_test.go @@ -0,0 +1,103 @@ +package evm + +import ( + "math/big" + "sort" + "testing" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" +) + +func TestActiveUpkeepList(t *testing.T) { + logIDs := []ocr2keepers.UpkeepIdentifier{ + core.GenUpkeepID(ocr2keepers.LogTrigger, "0"), + core.GenUpkeepID(ocr2keepers.LogTrigger, "1"), + core.GenUpkeepID(ocr2keepers.LogTrigger, "2"), + core.GenUpkeepID(ocr2keepers.LogTrigger, "3"), + core.GenUpkeepID(ocr2keepers.LogTrigger, "4"), + } + conditionalIDs := []ocr2keepers.UpkeepIdentifier{ + core.GenUpkeepID(ocr2keepers.ConditionTrigger, "0"), + core.GenUpkeepID(ocr2keepers.ConditionTrigger, "1"), + core.GenUpkeepID(ocr2keepers.ConditionTrigger, "2"), + core.GenUpkeepID(ocr2keepers.ConditionTrigger, "3"), + core.GenUpkeepID(ocr2keepers.ConditionTrigger, "4"), + } + + tests := []struct { + name string + initial []*big.Int + add []*big.Int + remove []*big.Int + expectedLogIds []*big.Int + expectedConditionalIds []*big.Int + }{ + { + name: "happy flow", + initial: []*big.Int{logIDs[0].BigInt(), logIDs[1].BigInt(), conditionalIDs[0].BigInt(), conditionalIDs[1].BigInt()}, + add: []*big.Int{logIDs[2].BigInt(), logIDs[3].BigInt(), conditionalIDs[2].BigInt(), conditionalIDs[3].BigInt()}, + remove: []*big.Int{logIDs[3].BigInt(), conditionalIDs[3].BigInt()}, + expectedLogIds: []*big.Int{logIDs[0].BigInt(), logIDs[1].BigInt(), logIDs[2].BigInt()}, + expectedConditionalIds: []*big.Int{conditionalIDs[0].BigInt(), conditionalIDs[1].BigInt(), conditionalIDs[2].BigInt()}, + }, + { + name: "empty", + initial: []*big.Int{}, + add: []*big.Int{}, + remove: []*big.Int{}, + expectedLogIds: []*big.Int{}, + expectedConditionalIds: []*big.Int{}, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + al := NewActiveUpkeepList() + al.Reset(tc.initial...) + require.Equal(t, len(tc.initial), al.Size()) + for _, id := range tc.initial { + require.True(t, al.IsActive(id)) + } + al.Add(tc.add...) + for _, id := range tc.add { + require.True(t, al.IsActive(id)) + } + al.Remove(tc.remove...) + for _, id := range tc.remove { + require.False(t, al.IsActive(id)) + } + logIds := al.View(ocr2keepers.LogTrigger) + require.Equal(t, len(tc.expectedLogIds), len(logIds)) + sort.Slice(logIds, func(i, j int) bool { + return logIds[i].Cmp(logIds[j]) < 0 + }) + for i := range logIds { + require.Equal(t, tc.expectedLogIds[i], logIds[i]) + } + conditionalIds := al.View(ocr2keepers.ConditionTrigger) + require.Equal(t, len(tc.expectedConditionalIds), len(conditionalIds)) + sort.Slice(conditionalIds, func(i, j int) bool { + return conditionalIds[i].Cmp(conditionalIds[j]) < 0 + }) + for i := range conditionalIds { + require.Equal(t, tc.expectedConditionalIds[i], conditionalIds[i]) + } + }) + } +} + +func TestActiveUpkeepList_error(t *testing.T) { + t.Run("if invalid or negative numbers are in the store, they are excluded from the view operation", func(t *testing.T) { + al := &activeList{} + al.items = make(map[string]bool) + al.items["not a number"] = true + al.items["-1"] = true + al.items["100"] = true + + keys := al.View(ocr2keepers.ConditionTrigger) + require.Equal(t, []*big.Int{big.NewInt(100)}, keys) + }) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go index 2785e6503ed..ca74eb85e1a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/block_subscriber.go @@ -25,8 +25,8 @@ const ( channelSize = 100 // lookbackDepth decides valid trigger block lookback range lookbackDepth = 1024 - // blockHistorySize decides the block history size - blockHistorySize = int64(128) + // blockHistorySize decides the block history size sent to subscribers + blockHistorySize = int64(256) ) type BlockSubscriber struct { @@ -43,12 +43,14 @@ type BlockSubscriber struct { maxSubId int lastClearedBlock int64 lastSentBlock int64 - latestBlock atomic.Int64 + latestBlock atomic.Pointer[ocr2keepers.BlockKey] blockHistorySize int64 blockSize int64 lggr logger.Logger } +var _ ocr2keepers.BlockSubscriber = &BlockSubscriber{} + func NewBlockSubscriber(hb httypes.HeadBroadcaster, lp logpoller.LogPoller, lggr logger.Logger) *BlockSubscriber { return &BlockSubscriber{ hb: hb, @@ -58,7 +60,7 @@ func NewBlockSubscriber(hb httypes.HeadBroadcaster, lp logpoller.LogPoller, lggr blocks: map[int64]string{}, blockHistorySize: blockHistorySize, blockSize: lookbackDepth, - latestBlock: atomic.Int64{}, + latestBlock: atomic.Pointer[ocr2keepers.BlockKey]{}, lggr: lggr.Named("BlockSubscriber"), } } @@ -130,7 +132,6 @@ func (bs *BlockSubscriber) Start(ctx context.Context) error { return bs.sync.StartOnce("BlockSubscriber", func() error { bs.mu.Lock() defer bs.mu.Unlock() - // TODO: we should use ctx instead of context.Background()) bs.ctx, bs.cancel = context.WithCancel(context.Background()) // initialize the blocks map with the recent blockSize blocks blocks, err := bs.getBlockRange(bs.ctx) @@ -239,8 +240,11 @@ func (bs *BlockSubscriber) processHead(h *evmtypes.Head) { bs.lggr.Debugf("blocks block %d hash is %s", h.Number, h.Hash.Hex()) history := bs.buildHistory(h.Number) - - bs.latestBlock.Store(h.Number) + block := &ocr2keepers.BlockKey{ + Number: ocr2keepers.BlockNumber(h.Number), + } + copy(block.Hash[:], h.Hash[:]) + bs.latestBlock.Store(block) bs.lastSentBlock = h.Number // send history to all subscribers for _, subC := range bs.subscribers { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go index 99db102a109..e6d9bb3d8a7 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/interfaces.go @@ -7,6 +7,8 @@ import ( ) // UpkeepStateReader is the interface for reading the current state of upkeeps. +// +//go:generate mockery --quiet --name UpkeepStateReader --output ./mocks/ --case=underscore type UpkeepStateReader interface { SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/mocks/upkeep_state_reader.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/mocks/upkeep_state_reader.go new file mode 100644 index 00000000000..09a5f299463 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/mocks/upkeep_state_reader.go @@ -0,0 +1,64 @@ +// Code generated by mockery v2.28.1. DO NOT EDIT. + +package mocks + +import ( + context "context" + + mock "github.com/stretchr/testify/mock" + + types "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" +) + +// UpkeepStateReader is an autogenerated mock type for the UpkeepStateReader type +type UpkeepStateReader struct { + mock.Mock +} + +// SelectByWorkIDsInRange provides a mock function with given fields: ctx, start, end, workIDs +func (_m *UpkeepStateReader) SelectByWorkIDsInRange(ctx context.Context, start int64, end int64, workIDs ...string) ([]types.UpkeepState, error) { + _va := make([]interface{}, len(workIDs)) + for _i := range workIDs { + _va[_i] = workIDs[_i] + } + var _ca []interface{} + _ca = append(_ca, ctx, start, end) + _ca = append(_ca, _va...) + ret := _m.Called(_ca...) + + var r0 []types.UpkeepState + var r1 error + if rf, ok := ret.Get(0).(func(context.Context, int64, int64, ...string) ([]types.UpkeepState, error)); ok { + return rf(ctx, start, end, workIDs...) + } + if rf, ok := ret.Get(0).(func(context.Context, int64, int64, ...string) []types.UpkeepState); ok { + r0 = rf(ctx, start, end, workIDs...) + } else { + if ret.Get(0) != nil { + r0 = ret.Get(0).([]types.UpkeepState) + } + } + + if rf, ok := ret.Get(1).(func(context.Context, int64, int64, ...string) error); ok { + r1 = rf(ctx, start, end, workIDs...) + } else { + r1 = ret.Error(1) + } + + return r0, r1 +} + +type mockConstructorTestingTNewUpkeepStateReader interface { + mock.TestingT + Cleanup(func()) +} + +// NewUpkeepStateReader creates a new instance of UpkeepStateReader. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. +func NewUpkeepStateReader(t mockConstructorTestingTNewUpkeepStateReader) *UpkeepStateReader { + mock := &UpkeepStateReader{} + mock.Mock.Test(t) + + t.Cleanup(func() { mock.AssertExpectations(t) }) + + return mock +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go index f3c035cb697..d7336737674 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload.go @@ -13,27 +13,13 @@ var ( ErrInvalidUpkeepID = fmt.Errorf("invalid upkeepID") ) -// UpkeepWorkID returns the identifier using the given upkeepID and trigger extension(tx hash and log index). -func UpkeepWorkID(id *big.Int, trigger ocr2keepers.Trigger) (string, error) { +func UpkeepWorkID(uid ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) string { var triggerExtBytes []byte if trigger.LogTriggerExtension != nil { triggerExtBytes = trigger.LogTriggerExtension.LogIdentifier() } - uid := &ocr2keepers.UpkeepIdentifier{} - ok := uid.FromBigInt(id) - if !ok { - return "", ErrInvalidUpkeepID - } - // TODO (auto-4314): Ensure it works with conditionals and add unit tests hash := crypto.Keccak256(append(uid[:], triggerExtBytes...)) - return hex.EncodeToString(hash[:]), nil -} - -func WorkIDGenerator(u ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) string { - // Error should not happen here since we pass in a valid upkeepID - // TODO: Clean this up - id, _ := UpkeepWorkID(u.BigInt(), trigger) - return id + return hex.EncodeToString(hash[:]) } func NewUpkeepPayload(id *big.Int, trigger ocr2keepers.Trigger, checkData []byte) (ocr2keepers.UpkeepPayload, error) { @@ -48,11 +34,6 @@ func NewUpkeepPayload(id *big.Int, trigger ocr2keepers.Trigger, checkData []byte CheckData: checkData, } // set work id based on upkeep id and trigger - wid, err := UpkeepWorkID(id, trigger) - if err != nil { - return ocr2keepers.UpkeepPayload{}, fmt.Errorf("error while generating workID: %w", err) - } - p.WorkID = wid - + p.WorkID = UpkeepWorkID(*uid, trigger) return p, nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go index afb0d77a3fb..c0edf5ca278 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go @@ -16,7 +16,6 @@ func TestWorkID(t *testing.T) { upkeepID string trigger ocr2keepers.Trigger expected string - errored bool }{ { name: "happy flow no extension", @@ -36,7 +35,7 @@ func TestWorkID(t *testing.T) { }, { name: "happy flow with extension", - upkeepID: genUpkeepID(ocr2keepers.LogTrigger, "12345").String(), + upkeepID: GenUpkeepID(ocr2keepers.LogTrigger, "12345").String(), trigger: ocr2keepers.Trigger{ BlockNumber: 123, BlockHash: common.HexToHash("0xabcdef"), @@ -45,7 +44,7 @@ func TestWorkID(t *testing.T) { TxHash: common.HexToHash("0x12345"), }, }, - expected: "91ace35299de40860e17d31adbc64bee48f437362cedd3b69ccf749a2f38d8e5", + expected: "278fb23f812503265e1d8e8531e1df62ad593455917eed7872f24c634a048a11", }, { name: "empty upkeepID", @@ -61,19 +60,18 @@ func TestWorkID(t *testing.T) { for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { // Convert the string to a big.Int - var upkeepID big.Int - _, success := upkeepID.SetString(tc.upkeepID, 10) + var id big.Int + _, success := id.SetString(tc.upkeepID, 10) if !success { t.Fatal("Invalid big integer value") } - - res, err := UpkeepWorkID(&upkeepID, tc.trigger) - if tc.errored { - assert.Error(t, err) - return + uid := &ocr2keepers.UpkeepIdentifier{} + ok := uid.FromBigInt(&id) + if !ok { + t.Fatal("Invalid upkeep identifier") } - assert.NoError(t, err) + res := UpkeepWorkID(*uid, tc.trigger) assert.Equal(t, tc.expected, res, "UpkeepWorkID mismatch") }) } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/testutil.go similarity index 68% rename from core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/core/testutil.go index be3394cce36..47935b56f68 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/testutil.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/testutil.go @@ -1,4 +1,4 @@ -package evm +package core import ( "math/big" @@ -7,8 +7,8 @@ import ( ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" ) -// genUpkeepID generates an ocr2keepers.UpkeepIdentifier with a specific UpkeepType and some random string -func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) ocr2keepers.UpkeepIdentifier { +// GenUpkeepID generates an ocr2keepers.UpkeepIdentifier with a specific UpkeepType and some random string +func GenUpkeepID(uType ocr2keepers.UpkeepType, rand string) ocr2keepers.UpkeepIdentifier { b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) b = append(b, []byte(rand)...) b = common.RightPadBytes(b, 32-len(b)) @@ -20,8 +20,8 @@ func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) ocr2keepers.UpkeepId return ocr2keepers.UpkeepIdentifier(id) } -// upkeepIDFromInt converts an int string to ocr2keepers.UpkeepIdentifier -func upkeepIDFromInt(id string) ocr2keepers.UpkeepIdentifier { +// UpkeepIDFromInt converts an int string to ocr2keepers.UpkeepIdentifier +func UpkeepIDFromInt(id string) ocr2keepers.UpkeepIdentifier { uid := &ocr2keepers.UpkeepIdentifier{} idInt, _ := big.NewInt(0).SetString(id, 10) uid.FromBigInt(idInt) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go index dd313a30078..8a2a51533e5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/type_test.go @@ -4,7 +4,6 @@ import ( "math/big" "testing" - "github.com/ethereum/go-ethereum/common" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" @@ -28,12 +27,12 @@ func TestGetUpkeepType(t *testing.T) { }, { "condition trigger", - genUpkeepID(ocr2keepers.ConditionTrigger, "").Bytes(), + GenUpkeepID(ocr2keepers.ConditionTrigger, "").BigInt().Bytes(), ocr2keepers.ConditionTrigger, }, { "log trigger", - genUpkeepID(ocr2keepers.LogTrigger, "111").Bytes(), + GenUpkeepID(ocr2keepers.LogTrigger, "111").BigInt().Bytes(), ocr2keepers.LogTrigger, }, { @@ -54,9 +53,3 @@ func TestGetUpkeepType(t *testing.T) { }) } } - -func genUpkeepID(uType ocr2keepers.UpkeepType, rand string) *big.Int { - b := append([]byte{1}, common.LeftPadBytes([]byte{uint8(uType)}, 15)...) - b = append(b, []byte(rand)...) - return big.NewInt(0).SetBytes(b) -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/encoder.go similarity index 78% rename from core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/encoding/encoder.go index cfdd26d3fd5..62a359a7231 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/encoder.go @@ -1,4 +1,4 @@ -package evm +package encoding import ( "fmt" @@ -14,16 +14,26 @@ var ( ErrEmptyResults = fmt.Errorf("empty results; cannot encode") ) -type EVMAutomationEncoder21 struct { - packer *evmRegistryPackerV2_1 +type reportEncoder struct { + packer Packer } -func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([]byte, error) { +var _ ocr2keepers.Encoder = (*reportEncoder)(nil) + +func NewReportEncoder(p Packer) ocr2keepers.Encoder { + return &reportEncoder{ + packer: p, + } +} + +func (e reportEncoder) Encode(results ...ocr2keepers.CheckResult) ([]byte, error) { if len(results) == 0 { return nil, ErrEmptyResults } report := automation_utils_2_1.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), UpkeepIds: make([]*big.Int, len(results)), GasLimits: make([]*big.Int, len(results)), Triggers: make([][]byte, len(results)), @@ -38,8 +48,12 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] if checkBlock.Cmp(highestCheckBlock) == 1 { highestCheckBlock = checkBlock - report.FastGasWei = result.FastGasWei - report.LinkNative = result.LinkNative + if result.FastGasWei != nil { + report.FastGasWei = result.FastGasWei + } + if result.LinkNative != nil { + report.LinkNative = result.LinkNative + } } id := result.UpkeepID.BigInt() @@ -69,14 +83,12 @@ func (enc EVMAutomationEncoder21) Encode(results ...ocr2keepers.CheckResult) ([] encoded++ } - fmt.Printf("[automation-ocr3|EvmRegistry|Encoder] encoded %d out of %d results\n", encoded, len(results)) - - return enc.packer.PackReport(report) + return e.packer.PackReport(report) } // Extract the plugin will call this function to accept/transmit reports -func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpkeep, error) { - report, err := enc.packer.UnpackReport(raw) +func (e reportEncoder) Extract(raw []byte) ([]ocr2keepers.ReportedUpkeep, error) { + report, err := e.packer.UnpackReport(raw) if err != nil { return nil, fmt.Errorf("%w: failed to unpack report", err) } @@ -84,7 +96,6 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk for i, upkeepId := range report.UpkeepIds { triggerW, err := core.UnpackTrigger(upkeepId, report.Triggers[i]) if err != nil { - // TODO: log error and continue instead? return nil, fmt.Errorf("%w: failed to unpack trigger", err) } id := &ocr2keepers.UpkeepIdentifier{} @@ -101,7 +112,7 @@ func (enc EVMAutomationEncoder21) Extract(raw []byte) ([]ocr2keepers.ReportedUpk trigger.LogTriggerExtension.Index = triggerW.LogIndex default: } - workID, _ := core.UpkeepWorkID(upkeepId, trigger) + workID := core.UpkeepWorkID(*id, trigger) reportedUpkeeps[i] = ocr2keepers.ReportedUpkeep{ WorkID: workID, UpkeepID: *id, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/encoder_test.go similarity index 80% rename from core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/encoding/encoder_test.go index 241d3396d93..a7fe7f536b1 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoder_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/encoder_test.go @@ -1,4 +1,4 @@ -package evm +package encoding import ( "math/big" @@ -15,13 +15,13 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) -func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { +func TestReportEncoder_EncodeExtract(t *testing.T) { keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) assert.Nil(t, err) utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) assert.Nil(t, err) - encoder := EVMAutomationEncoder21{ - packer: NewEvmRegistryPackerV2_1(keepersABI, utilsABI), + encoder := reportEncoder{ + packer: NewAbiPacker(keepersABI, utilsABI), } tests := []struct { @@ -35,7 +35,7 @@ func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { { "happy flow single", []ocr2keepers.CheckResult{ - newResult(1, 1, genUpkeepID(ocr2keepers.LogTrigger, "123"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), 1, 1), }, 704, 1, @@ -45,9 +45,9 @@ func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { { "happy flow multiple", []ocr2keepers.CheckResult{ - newResult(1, 1, genUpkeepID(ocr2keepers.LogTrigger, "10"), 1, 1), - newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "20"), 1, 1), - newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "30"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.LogTrigger, "10"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.ConditionTrigger, "20"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.ConditionTrigger, "30"), 1, 1), }, 1280, 3, @@ -57,9 +57,9 @@ func TestEVMAutomationEncoder21_EncodeExtract(t *testing.T) { { "happy flow highest block number first", []ocr2keepers.CheckResult{ - newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "30"), 1, 1), - newResult(1, 1, genUpkeepID(ocr2keepers.ConditionTrigger, "20"), 1, 1), - newResult(1, 1, genUpkeepID(ocr2keepers.LogTrigger, "10"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.ConditionTrigger, "30"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.ConditionTrigger, "20"), 1, 1), + newResult(1, 1, core.GenUpkeepID(ocr2keepers.LogTrigger, "10"), 1, 1), }, 1280, 1000, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go new file mode 100644 index 00000000000..8601617cf45 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go @@ -0,0 +1,55 @@ +package encoding + +import ( + "math/big" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" + iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" +) + +type UpkeepFailureReason uint8 +type PipelineExecutionState uint8 + +const ( + // upkeep failure onchain reasons + UpkeepFailureReasonNone UpkeepFailureReason = 0 + UpkeepFailureReasonUpkeepCancelled UpkeepFailureReason = 1 + UpkeepFailureReasonUpkeepPaused UpkeepFailureReason = 2 + UpkeepFailureReasonTargetCheckReverted UpkeepFailureReason = 3 + UpkeepFailureReasonUpkeepNotNeeded UpkeepFailureReason = 4 + UpkeepFailureReasonPerformDataExceedsLimit UpkeepFailureReason = 5 + UpkeepFailureReasonInsufficientBalance UpkeepFailureReason = 6 + UpkeepFailureReasonMercuryCallbackReverted UpkeepFailureReason = 7 + UpkeepFailureReasonRevertDataExceedsLimit UpkeepFailureReason = 8 + UpkeepFailureReasonRegistryPaused UpkeepFailureReason = 9 + // leaving a gap here for more onchain failure reasons in the future + // upkeep failure offchain reasons + UpkeepFailureReasonMercuryAccessNotAllowed UpkeepFailureReason = 32 + UpkeepFailureReasonTxHashNoLongerExists UpkeepFailureReason = 33 + + // pipeline execution error + NoPipelineError PipelineExecutionState = 0 + CheckBlockTooOld PipelineExecutionState = 1 + CheckBlockInvalid PipelineExecutionState = 2 + RpcFlakyFailure PipelineExecutionState = 3 + MercuryFlakyFailure PipelineExecutionState = 4 + PackUnpackDecodeFailed PipelineExecutionState = 5 + MercuryUnmarshalError PipelineExecutionState = 6 + InvalidMercuryRequest PipelineExecutionState = 7 + FailedToDecodeMercuryResponse PipelineExecutionState = 8 + InvalidRevertDataInput PipelineExecutionState = 9 +) + +type UpkeepInfo = iregistry21.KeeperRegistryBase21UpkeepInfo + +type Packer interface { + UnpackCheckResult(payload ocr2keepers.UpkeepPayload, raw string) (ocr2keepers.CheckResult, error) + UnpackCheckCallbackResult(callbackResp []byte) (PipelineExecutionState, bool, []byte, uint8, *big.Int, error) + UnpackPerformResult(raw string) (PipelineExecutionState, bool, error) + UnpackUpkeepInfo(id *big.Int, raw string) (UpkeepInfo, error) + UnpackLogTriggerConfig(raw []byte) (automation_utils_2_1.LogTriggerConfig, error) + PackReport(report automation_utils_2_1.KeeperRegistryBase21Report) ([]byte, error) + UnpackReport(raw []byte) (automation_utils_2_1.KeeperRegistryBase21Report, error) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go similarity index 53% rename from core/services/ocr2/plugins/ocr2keeper/evm21/abi.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go index 83eb9998a8a..e3d44cdef86 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go @@ -1,4 +1,4 @@ -package evm +package encoding import ( "fmt" @@ -10,81 +10,47 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" - iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" -) - -type UpkeepFailureReason uint8 -type PipelineExecutionState uint8 - -const ( - // upkeep failure onchain reasons - UpkeepFailureReasonNone UpkeepFailureReason = 0 - UpkeepFailureReasonUpkeepCancelled UpkeepFailureReason = 1 - UpkeepFailureReasonUpkeepPaused UpkeepFailureReason = 2 - UpkeepFailureReasonTargetCheckReverted UpkeepFailureReason = 3 - UpkeepFailureReasonUpkeepNotNeeded UpkeepFailureReason = 4 - UpkeepFailureReasonPerformDataExceedsLimit UpkeepFailureReason = 5 - UpkeepFailureReasonInsufficientBalance UpkeepFailureReason = 6 - UpkeepFailureReasonMercuryCallbackReverted UpkeepFailureReason = 7 - UpkeepFailureReasonRevertDataExceedsLimit UpkeepFailureReason = 8 - UpkeepFailureReasonRegistryPaused UpkeepFailureReason = 9 - // leaving a gap here for more onchain failure reasons in the future - // upkeep failure offchain reasons - UpkeepFailureReasonMercuryAccessNotAllowed UpkeepFailureReason = 32 - UpkeepFailureReasonLogBlockNoLongerExists UpkeepFailureReason = 31 - UpkeepFailureReasonLogBlockInvalid UpkeepFailureReason = 32 - UpkeepFailureReasonTxHashNoLongerExists UpkeepFailureReason = 33 - - // pipeline execution error - NoPipelineError PipelineExecutionState = 0 - CheckBlockTooOld PipelineExecutionState = 1 - CheckBlockInvalid PipelineExecutionState = 2 - RpcFlakyFailure PipelineExecutionState = 3 - MercuryFlakyFailure PipelineExecutionState = 4 - PackUnpackDecodeFailed PipelineExecutionState = 5 - MercuryUnmarshalError PipelineExecutionState = 6 - InvalidMercuryRequest PipelineExecutionState = 7 - FailedToDecodeMercuryResponse PipelineExecutionState = 8 - InvalidRevertDataInput PipelineExecutionState = 9 ) var utilsABI = types.MustGetABI(automation_utils_2_1.AutomationUtilsABI) -type UpkeepInfo = iregistry21.KeeperRegistryBase21UpkeepInfo - // triggerWrapper is a wrapper for the different trigger types (log and condition triggers). // NOTE: we use log trigger because it extends condition trigger, type triggerWrapper = automation_utils_2_1.KeeperRegistryBase21LogTrigger -type evmRegistryPackerV2_1 struct { +type abiPacker struct { abi abi.ABI utilsAbi abi.ABI } -func NewEvmRegistryPackerV2_1(abi abi.ABI, utilsAbi abi.ABI) *evmRegistryPackerV2_1 { - return &evmRegistryPackerV2_1{abi: abi, utilsAbi: utilsAbi} +var _ Packer = (*abiPacker)(nil) + +func NewAbiPacker(abi abi.ABI, utilsAbi abi.ABI) *abiPacker { + return &abiPacker{abi: abi, utilsAbi: utilsAbi} } -func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, raw string) (ocr2keepers.CheckResult, error) { +func (p *abiPacker) UnpackCheckResult(payload ocr2keepers.UpkeepPayload, raw string) (ocr2keepers.CheckResult, error) { b, err := hexutil.Decode(raw) if err != nil { // decode failed, not retryable - return getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false), fmt.Errorf("upkeepId %s failed to decode checkUpkeep result %s: %s", p.UpkeepID.String(), raw, err) + return GetIneligibleCheckResultWithoutPerformData(payload, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false), + fmt.Errorf("upkeepId %s failed to decode checkUpkeep result %s: %s", payload.UpkeepID.String(), raw, err) } - out, err := rp.abi.Methods["checkUpkeep"].Outputs.UnpackValues(b) + out, err := p.abi.Methods["checkUpkeep"].Outputs.UnpackValues(b) if err != nil { // unpack failed, not retryable - return getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false), fmt.Errorf("upkeepId %s failed to unpack checkUpkeep result %s: %s", p.UpkeepID.String(), raw, err) + return GetIneligibleCheckResultWithoutPerformData(payload, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false), + fmt.Errorf("upkeepId %s failed to unpack checkUpkeep result %s: %s", payload.UpkeepID.String(), raw, err) } result := ocr2keepers.CheckResult{ Eligible: *abi.ConvertType(out[0], new(bool)).(*bool), Retryable: false, GasAllocated: uint64((*abi.ConvertType(out[4], new(*big.Int)).(**big.Int)).Int64()), - UpkeepID: p.UpkeepID, - Trigger: p.Trigger, - WorkID: p.WorkID, + UpkeepID: payload.UpkeepID, + Trigger: payload.Trigger, + WorkID: payload.WorkID, FastGasWei: *abi.ConvertType(out[5], new(*big.Int)).(**big.Int), LinkNative: *abi.ConvertType(out[6], new(*big.Int)).(**big.Int), IneligibilityReason: *abi.ConvertType(out[2], new(uint8)).(*uint8), @@ -100,8 +66,8 @@ func (rp *evmRegistryPackerV2_1) UnpackCheckResult(p ocr2keepers.UpkeepPayload, return result, nil } -func (rp *evmRegistryPackerV2_1) UnpackCheckCallbackResult(callbackResp []byte) (PipelineExecutionState, bool, []byte, uint8, *big.Int, error) { - out, err := rp.abi.Methods["checkCallback"].Outputs.UnpackValues(callbackResp) +func (p *abiPacker) UnpackCheckCallbackResult(callbackResp []byte) (PipelineExecutionState, bool, []byte, uint8, *big.Int, error) { + out, err := p.abi.Methods["checkCallback"].Outputs.UnpackValues(callbackResp) if err != nil { return PackUnpackDecodeFailed, false, nil, 0, nil, fmt.Errorf("%w: unpack checkUpkeep return: %s", err, hexutil.Encode(callbackResp)) } @@ -110,16 +76,17 @@ func (rp *evmRegistryPackerV2_1) UnpackCheckCallbackResult(callbackResp []byte) rawPerformData := *abi.ConvertType(out[1], new([]byte)).(*[]byte) failureReason := *abi.ConvertType(out[2], new(uint8)).(*uint8) gasUsed := *abi.ConvertType(out[3], new(*big.Int)).(**big.Int) + return NoPipelineError, upkeepNeeded, rawPerformData, failureReason, gasUsed, nil } -func (rp *evmRegistryPackerV2_1) UnpackPerformResult(raw string) (PipelineExecutionState, bool, error) { +func (p *abiPacker) UnpackPerformResult(raw string) (PipelineExecutionState, bool, error) { b, err := hexutil.Decode(raw) if err != nil { return PackUnpackDecodeFailed, false, err } - out, err := rp.abi.Methods["simulatePerformUpkeep"].Outputs.UnpackValues(b) + out, err := p.abi.Methods["simulatePerformUpkeep"].Outputs.UnpackValues(b) if err != nil { return PackUnpackDecodeFailed, false, err } @@ -127,13 +94,13 @@ func (rp *evmRegistryPackerV2_1) UnpackPerformResult(raw string) (PipelineExecut return NoPipelineError, *abi.ConvertType(out[0], new(bool)).(*bool), nil } -func (rp *evmRegistryPackerV2_1) UnpackUpkeepInfo(id *big.Int, raw string) (UpkeepInfo, error) { +func (p *abiPacker) UnpackUpkeepInfo(id *big.Int, raw string) (UpkeepInfo, error) { b, err := hexutil.Decode(raw) if err != nil { return UpkeepInfo{}, err } - out, err := rp.abi.Methods["getUpkeep"].Outputs.UnpackValues(b) + out, err := p.abi.Methods["getUpkeep"].Outputs.UnpackValues(b) if err != nil { return UpkeepInfo{}, fmt.Errorf("%w: unpack getUpkeep return: %s", err, raw) } @@ -144,7 +111,7 @@ func (rp *evmRegistryPackerV2_1) UnpackUpkeepInfo(id *big.Int, raw string) (Upke } // UnpackLogTriggerConfig unpacks the log trigger config from the given raw data -func (rp *evmRegistryPackerV2_1) UnpackLogTriggerConfig(raw []byte) (automation_utils_2_1.LogTriggerConfig, error) { +func (p *abiPacker) UnpackLogTriggerConfig(raw []byte) (automation_utils_2_1.LogTriggerConfig, error) { var cfg automation_utils_2_1.LogTriggerConfig out, err := utilsABI.Methods["_logTriggerConfig"].Inputs.UnpackValues(raw) @@ -154,14 +121,14 @@ func (rp *evmRegistryPackerV2_1) UnpackLogTriggerConfig(raw []byte) (automation_ converted, ok := abi.ConvertType(out[0], new(automation_utils_2_1.LogTriggerConfig)).(*automation_utils_2_1.LogTriggerConfig) if !ok { - return cfg, fmt.Errorf("failed to convert type") + return cfg, fmt.Errorf("failed to convert type during UnpackLogTriggerConfig") } return *converted, nil } // PackReport packs the report with abi definitions from the contract. -func (rp *evmRegistryPackerV2_1) PackReport(report automation_utils_2_1.KeeperRegistryBase21Report) ([]byte, error) { - bts, err := rp.utilsAbi.Pack("_report", &report) +func (p *abiPacker) PackReport(report automation_utils_2_1.KeeperRegistryBase21Report) ([]byte, error) { + bts, err := p.utilsAbi.Pack("_report", &report) if err != nil { return nil, fmt.Errorf("%w: failed to pack report", err) } @@ -170,8 +137,8 @@ func (rp *evmRegistryPackerV2_1) PackReport(report automation_utils_2_1.KeeperRe } // UnpackReport unpacks the report from the given raw data. -func (rp *evmRegistryPackerV2_1) UnpackReport(raw []byte) (automation_utils_2_1.KeeperRegistryBase21Report, error) { - unpacked, err := rp.utilsAbi.Methods["_report"].Inputs.Unpack(raw) +func (p *abiPacker) UnpackReport(raw []byte) (automation_utils_2_1.KeeperRegistryBase21Report, error) { + unpacked, err := p.utilsAbi.Methods["_report"].Inputs.Unpack(raw) if err != nil { return automation_utils_2_1.KeeperRegistryBase21Report{}, fmt.Errorf("%w: failed to unpack report", err) } @@ -196,3 +163,17 @@ func (rp *evmRegistryPackerV2_1) UnpackReport(raw []byte) (automation_utils_2_1. return report, nil } + +// GetIneligibleCheckResultWithoutPerformData returns an ineligible check result with ineligibility reason and pipeline execution state but without perform data +func GetIneligibleCheckResultWithoutPerformData(p ocr2keepers.UpkeepPayload, reason UpkeepFailureReason, state PipelineExecutionState, retryable bool) ocr2keepers.CheckResult { + return ocr2keepers.CheckResult{ + IneligibilityReason: uint8(reason), + PipelineExecutionState: uint8(state), + Retryable: retryable, + UpkeepID: p.UpkeepID, + Trigger: p.Trigger, + WorkID: p.WorkID, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go similarity index 87% rename from core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go index 01c92ad4711..a6b7d504d58 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/abi_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go @@ -1,4 +1,4 @@ -package evm +package encoding import ( "fmt" @@ -17,7 +17,107 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) -func TestUnpackCheckResults(t *testing.T) { +func TestPacker_PackReport(t *testing.T) { + for _, tc := range []struct { + name string + report automation21Utils.KeeperRegistryBase21Report + expectsErr bool + wantErr error + wantBytes int + }{ + { + name: "all non-nil values get encoded to a byte array of a specific length", + report: automation21Utils.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + UpkeepIds: []*big.Int{big.NewInt(3)}, + GasLimits: []*big.Int{big.NewInt(4)}, + Triggers: [][]byte{ + {5}, + }, + PerformDatas: [][]byte{ + {6}, + }, + }, + wantBytes: 608, + }, + { + name: "if upkeep IDs are nil, the packed report is smaller", + report: automation21Utils.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(1), + LinkNative: big.NewInt(2), + UpkeepIds: nil, + GasLimits: []*big.Int{big.NewInt(4)}, + Triggers: [][]byte{ + {5}, + }, + PerformDatas: [][]byte{ + {6}, + }, + }, + wantBytes: 576, + }, + { + name: "if gas limits are nil, the packed report is smaller", + report: automation21Utils.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(1), + LinkNative: big.NewInt(2), + UpkeepIds: []*big.Int{big.NewInt(3)}, + GasLimits: nil, + Triggers: [][]byte{ + {5}, + }, + PerformDatas: [][]byte{ + {6}, + }, + }, + wantBytes: 576, + }, + { + name: "if perform datas are nil, the packed report is smaller", + report: automation21Utils.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(1), + LinkNative: big.NewInt(2), + UpkeepIds: []*big.Int{big.NewInt(3)}, + GasLimits: []*big.Int{big.NewInt(4)}, + Triggers: [][]byte{ + {5}, + }, + PerformDatas: nil, + }, + wantBytes: 512, + }, + { + name: "if triggers are nil, the packed report is smaller", + report: automation21Utils.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(1), + LinkNative: big.NewInt(2), + UpkeepIds: []*big.Int{big.NewInt(3)}, + GasLimits: []*big.Int{big.NewInt(4)}, + Triggers: nil, + PerformDatas: [][]byte{ + {6}, + }, + }, + wantBytes: 512, + }, + } { + t.Run(tc.name, func(t *testing.T) { + packer, err := newPacker() + assert.NoError(t, err) + bytes, err := packer.PackReport(tc.report) + if tc.expectsErr { + assert.Error(t, err) + assert.Equal(t, tc.wantErr.Error(), err.Error()) + } else { + assert.NoError(t, err) + assert.Equal(t, tc.wantBytes, len(bytes)) + } + }) + } +} + +func TestPacker_UnpackCheckResults(t *testing.T) { uid, _ := new(big.Int).SetString("1843548457736589226156809205796175506139185429616502850435279853710366065936", 10) upkeepId := ocr2keepers.UpkeepIdentifier{} upkeepId.FromBigInt(uid) @@ -233,7 +333,7 @@ func TestPacker_UnpackLogTriggerConfig(t *testing.T) { } } -func newPacker() (*evmRegistryPackerV2_1, error) { +func newPacker() (*abiPacker, error) { keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) if err != nil { return nil, err @@ -242,5 +342,5 @@ func newPacker() (*evmRegistryPackerV2_1, error) { if err != nil { return nil, err } - return NewEvmRegistryPackerV2_1(keepersABI, utilsABI), nil + return NewAbiPacker(keepersABI, utilsABI), nil } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 46d041db534..a27c8ca89d6 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -25,6 +25,7 @@ import ( ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/encoding" ) const ( @@ -74,12 +75,12 @@ type MercuryData struct { Error error Retryable bool Bytes [][]byte - State PipelineExecutionState + State encoding.PipelineExecutionState } -// AdminOffchainConfig represents the administrative offchain config for each upkeep. It can be set by s_upkeepManager +// UpkeepPrivilegeConfig represents the administrative offchain config for each upkeep. It can be set by s_upkeepManager // role on the registry. Upkeeps allowed to use Mercury server will have this set to true. -type AdminOffchainConfig struct { +type UpkeepPrivilegeConfig struct { MercuryEnabled bool `json:"mercuryEnabled"` } @@ -88,15 +89,26 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers lggr := r.lggr.With("where", "FeedLookup") lookups := map[int]*FeedLookup{} for i, res := range checkResults { - if res.IneligibilityReason != uint8(UpkeepFailureReasonTargetCheckReverted) { + if res.IneligibilityReason != uint8(encoding.UpkeepFailureReasonTargetCheckReverted) { + // Feedlookup only works when upkeep target check reverts continue } block := big.NewInt(int64(res.Trigger.BlockNumber)) upkeepId := res.UpkeepID - opts := r.buildCallOpts(ctx, block) + // Try to decode the revert error into feed lookup format. User upkeeps can revert with any reason, see if they + // tried to call mercury + lggr.Infof("upkeep %s block %d trying to decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(checkResults[i].PerformData)) + lookup, err := r.decodeFeedLookup(res.PerformData) + if err != nil { + lggr.Warnf("upkeep %s block %d decodeFeedLookup failed: %v", upkeepId, block, err) + // Not feed lookup error, nothing to do here + continue + } + opts := r.buildCallOpts(ctx, block) + // TODO: Remove allowlist for v0.3 state, retryable, allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) if err != nil { lggr.Warnf("upkeep %s block %d failed to query mercury allow list: %s", upkeepId, block, err) @@ -107,18 +119,10 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers if !allowed { lggr.Warnf("upkeep %s block %d NOT allowed to query Mercury server", upkeepId, block) - checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryAccessNotAllowed) - checkResults[i].Retryable = retryable + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonMercuryAccessNotAllowed) continue } - lggr.Infof("upkeep %s block %d decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(checkResults[i].PerformData)) - state, lookup, err := r.decodeFeedLookup(res.PerformData) - if err != nil { - lggr.Warnf("upkeep %s block %d decodeFeedLookup: %v", upkeepId, block, err) - checkResults[i].PipelineExecutionState = uint8(state) - continue - } lookup.upkeepId = upkeepId.BigInt() // the block here is exclusively used to call checkCallback at this block, not to be confused with the block number // in the revert for mercury v0.2, which is denoted by time in the struct bc starting from v0.3, only timestamp will be supported @@ -168,19 +172,19 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * return } - if failureReason == uint8(UpkeepFailureReasonMercuryCallbackReverted) { - checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonMercuryCallbackReverted) + if failureReason == uint8(encoding.UpkeepFailureReasonMercuryCallbackReverted) { + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonMercuryCallbackReverted) lggr.Debugf("upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) return } if !needed { - checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonUpkeepNotNeeded) + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonUpkeepNotNeeded) lggr.Debugf("upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) return } - checkResults[i].IneligibilityReason = uint8(UpkeepFailureReasonNone) + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonNone) checkResults[i].Eligible = true checkResults[i].PerformData = performData lggr.Infof("upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) @@ -188,36 +192,36 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * // allowedToUseMercury retrieves upkeep's administrative offchain config and decode a mercuryEnabled bool to indicate if // this upkeep is allowed to use Mercury service. -func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (state PipelineExecutionState, retryable bool, allow bool, err error) { +func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (state encoding.PipelineExecutionState, retryable bool, allow bool, err error) { allowed, ok := r.mercury.allowListCache.Get(upkeepId.String()) if ok { - return NoPipelineError, false, allowed.(bool), nil + return encoding.NoPipelineError, false, allowed.(bool), nil } cfg, err := r.registry.GetUpkeepPrivilegeConfig(opts, upkeepId) if err != nil { - return RpcFlakyFailure, true, false, fmt.Errorf("failed to get upkeep privilege config for upkeep ID %s: %v", upkeepId, err) + return encoding.RpcFlakyFailure, true, false, fmt.Errorf("failed to get upkeep privilege config for upkeep ID %s: %v", upkeepId, err) } - var a AdminOffchainConfig + var a UpkeepPrivilegeConfig err = json.Unmarshal(cfg, &a) if err != nil { - return MercuryUnmarshalError, false, false, fmt.Errorf("failed to unmarshal privilege config for upkeep ID %s: %v", upkeepId, err) + return encoding.MercuryUnmarshalError, false, false, fmt.Errorf("failed to unmarshal privilege config for upkeep ID %s: %v", upkeepId, err) } r.mercury.allowListCache.Set(upkeepId.String(), a.MercuryEnabled, cache.DefaultExpiration) - return NoPipelineError, false, a.MercuryEnabled, nil + return encoding.NoPipelineError, false, a.MercuryEnabled, nil } // decodeFeedLookup decodes the revert error FeedLookup(string feedParamKey, string[] feeds, string feedParamKey, uint256 time, byte[] extraData) -func (r *EvmRegistry) decodeFeedLookup(data []byte) (PipelineExecutionState, *FeedLookup, error) { +func (r *EvmRegistry) decodeFeedLookup(data []byte) (*FeedLookup, error) { e := r.mercury.abi.Errors["FeedLookup"] unpack, err := e.Unpack(data) if err != nil { - return PackUnpackDecodeFailed, nil, fmt.Errorf("unpack error: %w", err) + return nil, fmt.Errorf("unpack error: %w", err) } errorParameters := unpack.([]interface{}) - return NoPipelineError, &FeedLookup{ + return &FeedLookup{ feedParamKey: *abi.ConvertType(errorParameters[0], new(string)).(*string), feeds: *abi.ConvertType(errorParameters[1], new([]string)).(*[]string), timeParamKey: *abi.ConvertType(errorParameters[2], new(string)).(*string), @@ -226,10 +230,10 @@ func (r *EvmRegistry) decodeFeedLookup(data []byte) (PipelineExecutionState, *Fe }, nil } -func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup *FeedLookup) (PipelineExecutionState, bool, hexutil.Bytes, error) { +func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup *FeedLookup) (encoding.PipelineExecutionState, bool, hexutil.Bytes, error) { payload, err := r.abi.Pack("checkCallback", lookup.upkeepId, values, lookup.extraData) if err != nil { - return PackUnpackDecodeFailed, false, nil, err + return encoding.PackUnpackDecodeFailed, false, nil, err } var b hexutil.Bytes @@ -241,13 +245,13 @@ func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup // call checkCallback function at the block which OCR3 has agreed upon err = r.client.CallContext(ctx, &b, "eth_call", args, hexutil.EncodeUint64(lookup.block)) if err != nil { - return RpcFlakyFailure, true, nil, err + return encoding.RpcFlakyFailure, true, nil, err } - return NoPipelineError, false, b, nil + return encoding.NoPipelineError, false, b, nil } // doMercuryRequest sends requests to Mercury API to retrieve ChainlinkBlob. -func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr logger.Logger) (PipelineExecutionState, [][]byte, bool, error) { +func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr logger.Logger) (encoding.PipelineExecutionState, [][]byte, bool, error) { var isMercuryV03 bool resultLen := len(ml.feeds) ch := make(chan MercuryData, resultLen) @@ -263,7 +267,8 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr ch = make(chan MercuryData, resultLen) go r.multiFeedsRequest(ctx, ch, ml, lggr) } else { - return InvalidRevertDataInput, nil, false, fmt.Errorf("invalid label combination: feed param key %s and time param key %s", ml.feedParamKey, ml.timeParamKey) + // TODO: This should result in upkeep ineligible since upkeep gave a wrong mercury input + return encoding.InvalidRevertDataInput, nil, false, fmt.Errorf("invalid label combination: feed param key %s and time param key %s", ml.feedParamKey, ml.timeParamKey) } var reqErr error @@ -271,14 +276,14 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr retryable := true allSuccess := true // in v0.2, use the last execution error as the state, if no execution errors, state will be no error - state := NoPipelineError + state := encoding.NoPipelineError for i := 0; i < resultLen; i++ { m := <-ch if m.Error != nil { reqErr = errors.Join(reqErr, m.Error) retryable = retryable && m.Retryable allSuccess = false - if m.State != NoPipelineError { + if m.State != encoding.NoPipelineError { state = m.State } continue @@ -306,7 +311,7 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa req, err := http.NewRequestWithContext(ctx, http.MethodGet, reqUrl, nil) if err != nil { - ch <- MercuryData{Index: index, Error: err, Retryable: false, State: InvalidMercuryRequest} + ch <- MercuryData{Index: index, Error: err, Retryable: false, State: encoding.InvalidMercuryRequest} return } @@ -318,7 +323,7 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa req.Header.Set(headerSignature, signature) // in the case of multiple retries here, use the last attempt's data - state := NoPipelineError + state := encoding.NoPipelineError retryable := false sent := false retryErr := retry.Do( @@ -328,25 +333,25 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa if err1 != nil { lggr.Warnf("upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) retryable = true - state = MercuryFlakyFailure + state = encoding.MercuryFlakyFailure return err1 } defer resp.Body.Close() body, err1 := io.ReadAll(resp.Body) if err1 != nil { retryable = false - state = FailedToDecodeMercuryResponse + state = encoding.FailedToDecodeMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { lggr.Warnf("upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) retryable = true - state = MercuryFlakyFailure + state = encoding.MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { retryable = false - state = InvalidMercuryRequest + state = encoding.InvalidMercuryRequest return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) } @@ -355,21 +360,21 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa if err1 != nil { lggr.Warnf("upkeep %s block %s failed to unmarshal body to MercuryV02Response for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) retryable = false - state = MercuryUnmarshalError + state = encoding.MercuryUnmarshalError return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { lggr.Warnf("upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) retryable = false - state = FailedToDecodeMercuryResponse + state = encoding.FailedToDecodeMercuryResponse return err1 } ch <- MercuryData{ Index: index, Bytes: [][]byte{blobBytes}, Retryable: false, - State: NoPipelineError, + State: encoding.NoPipelineError, } sent = true return nil @@ -406,7 +411,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa req, err := http.NewRequestWithContext(ctx, http.MethodGet, reqUrl, nil) if err != nil { - ch <- MercuryData{Index: 0, Error: err, Retryable: false, State: InvalidMercuryRequest} + ch <- MercuryData{Index: 0, Error: err, Retryable: false, State: encoding.InvalidMercuryRequest} return } @@ -422,7 +427,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa req.Header.Set(headerUpkeepId, ml.upkeepId.String()) // in the case of multiple retries here, use the last attempt's data - state := NoPipelineError + state := encoding.NoPipelineError retryable := false sent := false retryErr := retry.Do( @@ -432,25 +437,25 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa if err1 != nil { lggr.Warnf("upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) retryable = true - state = MercuryFlakyFailure + state = encoding.MercuryFlakyFailure return err1 } defer resp.Body.Close() body, err1 := io.ReadAll(resp.Body) if err1 != nil { retryable = false - state = FailedToDecodeMercuryResponse + state = encoding.FailedToDecodeMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { lggr.Warnf("upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) retryable = true - state = MercuryFlakyFailure + state = encoding.MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { retryable = false - state = InvalidMercuryRequest + state = encoding.InvalidMercuryRequest return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) } @@ -459,7 +464,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa if err1 != nil { lggr.Warnf("upkeep %s block %s failed to unmarshal body to MercuryV03Response for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) retryable = false - state = MercuryUnmarshalError + state = encoding.MercuryUnmarshalError return err1 } var reportBytes [][]byte @@ -469,7 +474,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa if err1 != nil { lggr.Warnf("upkeep %s block %s failed to decode reportBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), rsp.FullReport, err1) retryable = false - state = FailedToDecodeMercuryResponse + state = encoding.FailedToDecodeMercuryResponse return err1 } reportBytes = append(reportBytes, b) @@ -478,7 +483,7 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa Index: 0, Bytes: reportBytes, Retryable: false, - State: NoPipelineError, + State: encoding.NoPipelineError, } sent = true return nil diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index d647714d23f..a6e493aa264 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -21,6 +21,7 @@ import ( "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/encoding" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/mocks" evmClientMocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" @@ -48,17 +49,17 @@ func setupEVMRegistry(t *testing.T) *EvmRegistry { client := evmClientMocks.NewClient(t) r := &EvmRegistry{ - lggr: lggr, - poller: logPoller, - addr: addr, - client: client, - txHashes: make(map[string]bool), - registry: mockRegistry, - abi: keeperRegistryABI, - active: make(map[string]activeUpkeep), - packer: NewEvmRegistryPackerV2_1(keeperRegistryABI, utilsABI), - headFunc: func(ocr2keepers.BlockKey) {}, - chLog: make(chan logpoller.Log, 1000), + lggr: lggr, + poller: logPoller, + addr: addr, + client: client, + logProcessed: make(map[string]bool), + registry: mockRegistry, + abi: keeperRegistryABI, + active: NewActiveUpkeepList(), + packer: encoding.NewAbiPacker(keeperRegistryABI, utilsABI), + headFunc: func(ocr2keepers.BlockKey) {}, + chLog: make(chan logpoller.Log, 1000), mercury: &MercuryConfig{ cred: &models.MercuryCredentials{ URL: "https://google.com", @@ -66,7 +67,7 @@ func setupEVMRegistry(t *testing.T) *EvmRegistry { Password: "FakeClientKey", }, abi: feedLookupCompatibleABI, - allowListCache: cache.New(defaultAllowListExpiration, cleanupInterval), + allowListCache: cache.New(defaultAllowListExpiration, allowListCleanupInterval), }, hc: mockHttpClient, } @@ -101,7 +102,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: uint8(UpkeepFailureReasonTargetCheckReverted), + IneligibilityReason: uint8(encoding.UpkeepFailureReasonTargetCheckReverted), }, }, blob: "0x00066dfcd1ed2d95b18c948dbc5bd64c687afe93e4ca7d663ddec14c20090ad80000000000000000000000000000000000000000000000000000000000159761000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000002200000000000000000000000000000000000000000000000000000000000000280000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001204554482d5553442d415242495452554d2d544553544e4554000000000000000000000000000000000000000000000000000000000000000000000000648a1fbb000000000000000000000000000000000000000000000000000000274421041500000000000000000000000000000000000000000000000000000027437c6ecd0000000000000000000000000000000000000000000000000000002744c5995d00000000000000000000000000000000000000000000000000000000018d6ec108936dfe39c48715572a51ac868129958f937fb95ef5abdf73a239cf86a4fee700000000000000000000000000000000000000000000000000000000018d6ec100000000000000000000000000000000000000000000000000000000648a1fbb00000000000000000000000000000000000000000000000000000000000000028a26e557ee2feb91ccb116f3ab4eb1469afe5c3b012538cb151dbe3fbceaf6f117b24ac2a82cff25b286ae0a9b903dc6badaa16f6e67bf0983461b008574e30a00000000000000000000000000000000000000000000000000000000000000020db5c5924481061b98df59caefd9c4c1e72657c4976bf7c7568730fbdaf828080bff6b1edea2c8fed5e8bbac5574aa94cf809d898f5055cb1db14a16f1493726", @@ -118,7 +119,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: uint8(UpkeepFailureReasonNone), + IneligibilityReason: uint8(encoding.UpkeepFailureReasonNone), }, }, hasError: false, @@ -133,7 +134,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: uint8(UpkeepFailureReasonInsufficientBalance), + IneligibilityReason: uint8(encoding.UpkeepFailureReasonInsufficientBalance), }, }, expectedResults: []ocr2keepers.CheckResult{ @@ -144,13 +145,13 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: uint8(UpkeepFailureReasonInsufficientBalance), + IneligibilityReason: uint8(encoding.UpkeepFailureReasonInsufficientBalance), }, }, hasError: true, }, { - name: "skip - no mercury permission", + name: "skip - invalid revert data", input: []ocr2keepers.CheckResult{ { PerformData: []byte{}, @@ -158,7 +159,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: uint8(UpkeepFailureReasonTargetCheckReverted), + IneligibilityReason: uint8(encoding.UpkeepFailureReasonTargetCheckReverted), }, }, expectedResults: []ocr2keepers.CheckResult{ @@ -169,10 +170,10 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { Trigger: ocr2keepers.Trigger{ BlockNumber: 26046145, }, - IneligibilityReason: uint8(UpkeepFailureReasonMercuryAccessNotAllowed), + IneligibilityReason: uint8(encoding.UpkeepFailureReasonTargetCheckReverted), }, }, - hasError: false, + hasError: true, }, } @@ -182,7 +183,7 @@ func TestEvmRegistry_FeedLookup(t *testing.T) { if !tt.cachedAdminCfg && !tt.hasError { mockRegistry := mocks.NewRegistry(t) - cfg := AdminOffchainConfig{MercuryEnabled: tt.hasPermission} + cfg := UpkeepPrivilegeConfig{MercuryEnabled: tt.hasPermission} b, err := json.Marshal(cfg) assert.Nil(t, err) mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return(b, nil) @@ -229,13 +230,12 @@ func TestEvmRegistry_DecodeFeedLookup(t *testing.T) { name string data []byte expected *FeedLookup - state PipelineExecutionState + state encoding.PipelineExecutionState err error }{ { - name: "success - decode to feed lookup", - data: []byte{125, 221, 147, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 138, 215, 253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 100, 72, 101, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 53, 53, 52, 52, 56, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 50, 53, 52, 52, 51, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, - state: NoPipelineError, + name: "success - decode to feed lookup", + data: []byte{125, 221, 147, 62, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 160, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 224, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 138, 215, 253, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 128, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 9, 102, 101, 101, 100, 73, 100, 72, 101, 120, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 64, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 53, 53, 52, 52, 56, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 48, 120, 52, 50, 53, 52, 52, 51, 50, 100, 53, 53, 53, 51, 52, 52, 50, 100, 52, 49, 53, 50, 52, 50, 52, 57, 53, 52, 53, 50, 53, 53, 52, 100, 50, 100, 53, 52, 52, 53, 53, 51, 53, 52, 52, 101, 52, 53, 53, 52, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 11, 98, 108, 111, 99, 107, 78, 117, 109, 98, 101, 114, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 20, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}, expected: &FeedLookup{ feedParamKey: feedIdHex, feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, @@ -245,19 +245,17 @@ func TestEvmRegistry_DecodeFeedLookup(t *testing.T) { }, }, { - name: "failure - unpack error", - data: []byte{1, 2, 3, 4}, - err: errors.New("unpack error: invalid data for unpacking"), - state: PackUnpackDecodeFailed, + name: "failure - unpack error", + data: []byte{1, 2, 3, 4}, + err: errors.New("unpack error: invalid data for unpacking"), }, } for _, tt := range tests { t.Run(tt.name, func(t *testing.T) { r := setupEVMRegistry(t) - state, fl, err := r.decodeFeedLookup(tt.data) + fl, err := r.decodeFeedLookup(tt.data) assert.Equal(t, tt.expected, fl) - assert.Equal(t, tt.state, state) if tt.err != nil { assert.Equal(t, tt.err.Error(), err.Error()) } @@ -273,7 +271,7 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { cached bool allowed bool errorMessage string - state PipelineExecutionState + state encoding.PipelineExecutionState retryable bool }{ { @@ -300,7 +298,7 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { name: "failure - cannot unmarshal privilege config", cached: false, errorMessage: "failed to unmarshal privilege config for upkeep ID 71022726777042968814359024671382968091267501884371696415772139504780367423725: invalid character '\\x00' looking for beginning of value", - state: MercuryUnmarshalError, + state: encoding.MercuryUnmarshalError, }, } @@ -317,7 +315,7 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { r.mercury.allowListCache.Set(upkeepId.String(), tt.allowed, cache.DefaultExpiration) } else { mockRegistry := mocks.NewRegistry(t) - cfg := AdminOffchainConfig{MercuryEnabled: tt.allowed} + cfg := UpkeepPrivilegeConfig{MercuryEnabled: tt.allowed} b, err := json.Marshal(cfg) assert.Nil(t, err) mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return(b, nil) @@ -351,7 +349,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedValues [][]byte expectedRetryable bool expectedError error - state PipelineExecutionState + state encoding.PipelineExecutionState }{ { name: "success", @@ -384,7 +382,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedValues: [][]byte{nil}, expectedRetryable: true, expectedError: errors.New("All attempts fail:\n#1: 500\n#2: 500\n#3: 500"), - state: MercuryFlakyFailure, + state: encoding.MercuryFlakyFailure, }, { name: "failure - not retryable", @@ -401,7 +399,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedValues: [][]byte{nil}, expectedRetryable: false, expectedError: errors.New("All attempts fail:\n#1: FeedLookup upkeep 88786950015966611018675766524283132478093844178961698330929478019253453382042 block 25880526 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"), - state: InvalidMercuryRequest, + state: encoding.InvalidMercuryRequest, }, } @@ -821,7 +819,7 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { performData []byte wantErr assert.ErrorAssertionFunc - state PipelineExecutionState + state encoding.PipelineExecutionState retryable bool }{ { @@ -877,7 +875,7 @@ func TestEvmRegistry_CheckCallback(t *testing.T) { callbackResp: []byte{}, callbackErr: errors.New("bad response"), wantErr: assert.Error, - state: RpcFlakyFailure, + state: encoding.RpcFlakyFailure, retryable: true, }, } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time.go new file mode 100644 index 00000000000..1d8500bcc61 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time.go @@ -0,0 +1,72 @@ +package logprovider + +import ( + "context" + "fmt" + "sort" + "time" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" +) + +var ( + defaultSampleSize = int64(10) + defaultBlockTime = time.Second * 1 +) + +type blockTimeResolver struct { + poller logpoller.LogPoller +} + +func newBlockTimeResolver(poller logpoller.LogPoller) *blockTimeResolver { + return &blockTimeResolver{ + poller: poller, + } +} + +func (r *blockTimeResolver) BlockTime(ctx context.Context, blockSampleSize int64) (time.Duration, error) { + if blockSampleSize < 2 { // min 2 blocks range + blockSampleSize = defaultSampleSize + } + + latest, err := r.poller.LatestBlock(pg.WithParentCtx(ctx)) + if err != nil { + return 0, fmt.Errorf("failed to get latest block from poller: %w", err) + } + if latest < blockSampleSize { + return defaultBlockTime, nil + } + blockTimes, err := r.getSampleTimestamps(ctx, blockSampleSize, latest) + if err != nil { + return 0, err + } + + var sumDiff time.Duration + for i := range blockTimes { + if i != int(blockSampleSize-1) { + sumDiff += blockTimes[i].Sub(blockTimes[i+1]) + } + } + + return sumDiff / time.Duration(blockSampleSize-1), nil +} + +func (r *blockTimeResolver) getSampleTimestamps(ctx context.Context, blockSampleSize, latest int64) ([]time.Time, error) { + blockSample := make([]uint64, blockSampleSize) + for i := range blockSample { + blockSample[i] = uint64(latest - blockSampleSize + int64(i)) + } + blocks, err := r.poller.GetBlocksRange(ctx, blockSample) + if err != nil { + return nil, fmt.Errorf("failed to get block range from poller: %w", err) + } + sort.Slice(blocks, func(i, j int) bool { + return blocks[i].BlockNumber > blocks[j].BlockNumber + }) + blockTimes := make([]time.Time, blockSampleSize) + for i, b := range blocks { + blockTimes[i] = b.BlockTimestamp + } + return blockTimes, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time_test.go new file mode 100644 index 00000000000..55437ff6721 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/block_time_test.go @@ -0,0 +1,85 @@ +package logprovider + +import ( + "context" + "fmt" + "testing" + "time" + + "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + lpmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" +) + +func TestBlockTimeResolver_BlockTime(t *testing.T) { + now := time.Now() + + tests := []struct { + name string + blockSampleSize int64 + latestBlock int64 + latestBlockErr error + blocksRange []logpoller.LogPollerBlock + blocksRangeErr error + blockTime time.Duration + blockTimeErr error + }{ + { + "latest block err", + 10, + 0, + fmt.Errorf("test err"), + nil, + nil, + 0, + fmt.Errorf("test err"), + }, + { + "block range err", + 10, + 20, + nil, + nil, + fmt.Errorf("test err"), + 0, + fmt.Errorf("test err"), + }, + { + "2 sec block time", + 4, + 20, + nil, + []logpoller.LogPollerBlock{ + {BlockTimestamp: now.Add(-time.Second * (2 * 4)), BlockNumber: 1}, + {BlockTimestamp: now.Add(-time.Second * (2 * 3)), BlockNumber: 2}, + {BlockTimestamp: now.Add(-time.Second * (2 * 2)), BlockNumber: 3}, + {BlockTimestamp: now.Add(-time.Second * 2), BlockNumber: 4}, + }, + nil, + 2 * time.Second, + nil, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + ctx, cancel := context.WithCancel(context.Background()) + defer cancel() + + lp := new(lpmocks.LogPoller) + resolver := newBlockTimeResolver(lp) + + lp.On("LatestBlock", mock.Anything).Return(tc.latestBlock, tc.latestBlockErr) + lp.On("GetBlocksRange", mock.Anything, mock.Anything).Return(tc.blocksRange, tc.blocksRangeErr) + + blockTime, err := resolver.BlockTime(ctx, tc.blockSampleSize) + if tc.blockTimeErr != nil { + require.Error(t, err) + return + } + require.Equal(t, tc.blockTime, blockTime) + }) + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go index 8a2e760bbf4..a8f3d64f058 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go @@ -10,10 +10,17 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" ) +var ( + // AllowedLogsPerBlock is the maximum number of logs allowed per upkeep in a block. + AllowedLogsPerBlock = 128 + // BufferMaxBlockSize is the maximum number of blocks in the buffer. + BufferMaxBlockSize = 1024 +) + // fetchedLog holds the log and the ID of the upkeep type fetchedLog struct { - id *big.Int - log logpoller.Log + upkeepID *big.Int + log logpoller.Log } // fetchedBlock holds the logs fetched for a block @@ -26,23 +33,13 @@ type fetchedBlock struct { visited []fetchedLog } -// Reset resets the block to the given block number, if the block is newer than the current block. -func (b fetchedBlock) Reset(block int64) (fetchedBlock, int64) { - if b.blockNumber < block { - return fetchedBlock{ - blockNumber: block, - }, b.blockNumber - } - return b, b.blockNumber -} - // Has returns true if the block has the log, // and the number of logs for that upkeep in the block. func (b fetchedBlock) Has(id *big.Int, log logpoller.Log) (bool, int) { allLogs := append(b.logs, b.visited...) upkeepLogs := 0 for _, l := range allLogs { - if l.id.Cmp(id) != 0 { + if l.upkeepID.Cmp(id) != 0 { continue } upkeepLogs++ @@ -62,7 +59,7 @@ type logEventBuffer struct { // size is the number of blocks supported by the buffer size int32 - maxBlockLogs, maxUpkeepLogsPerBlock int32 + maxBlockLogs, maxUpkeepLogsPerBlock int // blocks is the circular buffer of fetched blocks blocks []fetchedBlock // latestBlock is the latest block number seen @@ -74,8 +71,8 @@ func newLogEventBuffer(lggr logger.Logger, size, maxBlockLogs, maxUpkeepLogsPerB lggr: lggr.Named("KeepersRegistry.LogEventBuffer"), size: int32(size), blocks: make([]fetchedBlock, size), - maxBlockLogs: int32(maxBlockLogs), - maxUpkeepLogsPerBlock: int32(maxUpkeepLogsPerBlock), + maxBlockLogs: maxBlockLogs, + maxUpkeepLogsPerBlock: maxUpkeepLogsPerBlock, } } @@ -105,23 +102,24 @@ func (b *logEventBuffer) enqueue(id *big.Int, logs ...logpoller.Log) int { continue } i := b.blockNumberIndex(log.BlockNumber) - block, prevBlock := b.blocks[i].Reset(log.BlockNumber) - if prevBlock > 0 { - if prevBlock > log.BlockNumber { - lggr.Debugw("Skipping old log", "currentBlock", block.blockNumber, "newBlock", log.BlockNumber) - continue - } else if prevBlock < log.BlockNumber { - lggr.Debugw("Overriding block", "prevBlock", prevBlock, "newBlock", log.BlockNumber) - } + currentBlock := b.blocks[i] + if currentBlock.blockNumber < log.BlockNumber { + lggr.Debugw("Got log on a new block", "prevBlock", currentBlock.blockNumber, "newBlock", log.BlockNumber) + currentBlock.blockNumber = log.BlockNumber + currentBlock.logs = nil + currentBlock.visited = nil + } else if currentBlock.blockNumber > log.BlockNumber { + // not expected to happen + lggr.Debugw("Skipping log from old block", "currentBlock", currentBlock.blockNumber, "newBlock", log.BlockNumber) + continue } - if len(block.logs)+1 > maxBlockLogs { + if len(currentBlock.logs)+1 > maxBlockLogs { lggr.Debugw("Reached max logs number per block, dropping log", "blockNumber", log.BlockNumber, "blockHash", log.BlockHash, "txHash", log.TxHash, "logIndex", log.LogIndex) continue } - if has, upkeepLogs := block.Has(id, log); has { - // lggr.Debugw("Skipping existing log", "blockNumber", log.BlockNumber, - // "blockHash", log.BlockHash, "txHash", log.TxHash, "logIndex", log.LogIndex) + if has, upkeepLogs := currentBlock.Has(id, log); has { + // Skipping existing log continue } else if upkeepLogs+1 > maxUpkeepLogs { lggr.Debugw("Reached max logs number per upkeep, dropping log", "blockNumber", log.BlockNumber, @@ -129,8 +127,8 @@ func (b *logEventBuffer) enqueue(id *big.Int, logs ...logpoller.Log) int { continue } // lggr.Debugw("Adding log", "i", i, "blockBlock", block.blockNumber, "logBlock", log.BlockNumber, "id", id) - block.logs = append(block.logs, fetchedLog{id: id, log: log}) - b.blocks[i] = block + currentBlock.logs = append(currentBlock.logs, fetchedLog{upkeepID: id, log: log}) + b.blocks[i] = currentBlock added++ if log.BlockNumber > latestBlock { latestBlock = log.BlockNumber @@ -186,7 +184,7 @@ func (b *logEventBuffer) peekRange(start, end int64) []fetchedLog { } // peek returns the logs in range [latestBlock-blocks, latestBlock] -func (b *logEventBuffer) dequeue(blocks int) []fetchedLog { +func (b *logEventBuffer) dequeue(blocks, upkeepLimit int) []fetchedLog { latestBlock := b.latestBlockSeen() if latestBlock == 0 { return nil @@ -194,25 +192,39 @@ func (b *logEventBuffer) dequeue(blocks int) []fetchedLog { if blocks > int(latestBlock) { blocks = int(latestBlock) - 1 } - return b.dequeueRange(latestBlock-int64(blocks), latestBlock) + return b.dequeueRange(latestBlock-int64(blocks), latestBlock, upkeepLimit) } // dequeueRange returns the logs between start and end inclusive. -func (b *logEventBuffer) dequeueRange(start, end int64) []fetchedLog { +func (b *logEventBuffer) dequeueRange(start, end int64, upkeepLimit int) []fetchedLog { b.lock.Lock() defer b.lock.Unlock() blocksInRange := b.getBlocksInRange(int(start), int(end)) + logsCount := map[string]int{} + var results []fetchedLog for i, block := range blocksInRange { // double checking that we don't have any gaps in the range if block.blockNumber < start || block.blockNumber > end { continue } - results = append(results, block.logs...) - block.visited = append(block.visited, block.logs...) - block.logs = nil + var remainingLogs, blockResults []fetchedLog + for _, log := range block.logs { + if logsCount[log.upkeepID.String()] >= upkeepLimit { + remainingLogs = append(remainingLogs, log) + continue + } + logsCount[log.upkeepID.String()]++ + blockResults = append(blockResults, log) + } + if len(blockResults) == 0 { + continue + } + block.visited = append(block.visited, blockResults...) + results = append(results, blockResults...) + block.logs = remainingLogs b.blocks[i] = block } @@ -220,7 +232,9 @@ func (b *logEventBuffer) dequeueRange(start, end int64) []fetchedLog { return results[i].log.BlockNumber < results[j].log.BlockNumber }) - b.lggr.Debugw("Dequeued logs", "results", len(results), "start", start, "end", end) + if len(results) > 0 { + b.lggr.Debugw("Dequeued logs", "results", len(results), "start", start, "end", end) + } return results } @@ -259,7 +273,9 @@ func (b *logEventBuffer) normalRange(start, end int) (int, int) { start++ } if start == end { - // ensure we have at least one block in range + // ensure we have at least one block in range as end is exclusive + // TODO: verify if we really need to do this here or if this can be removed safely + // as start is aligned in line 285 end++ } if end-start > size { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go index f3abd04fd17..cec34b9649b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go @@ -175,7 +175,7 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { }) t.Run("enqueue logs overflow", func(t *testing.T) { - buf := newLogEventBuffer(logger.TestLogger(t), 3, 2, 10) + buf := newLogEventBuffer(logger.TestLogger(t), 2, 2, 10) require.Equal(t, 2, buf.enqueue(big.NewInt(1), logpoller.Log{BlockNumber: 1, TxHash: common.HexToHash("0x1"), LogIndex: 0}, @@ -230,14 +230,14 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { results := buf.peekRange(int64(1), int64(2)) require.Equal(t, 2, len(results)) verifyBlockNumbers(t, results, 1, 2) - removed := buf.dequeueRange(int64(1), int64(2)) + removed := buf.dequeueRange(int64(1), int64(2), 2) require.Equal(t, 2, len(removed)) results = buf.peekRange(int64(1), int64(2)) require.Equal(t, 0, len(results)) }) t.Run("enqueue peek and dequeue", func(t *testing.T) { - buf := newLogEventBuffer(logger.TestLogger(t), 3, 10, 10) + buf := newLogEventBuffer(logger.TestLogger(t), 4, 10, 10) require.Equal(t, buf.enqueue(big.NewInt(10), logpoller.Log{BlockNumber: 1, TxHash: common.HexToHash("0x1"), LogIndex: 10}, @@ -250,10 +250,11 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { results := buf.peek(8) require.Equal(t, 4, len(results)) verifyBlockNumbers(t, results, 1, 2, 3, 3) - removed := buf.dequeue(8) + removed := buf.dequeue(8, 5) require.Equal(t, 4, len(removed)) buf.lock.Lock() require.Equal(t, 0, len(buf.blocks[0].logs)) + require.Equal(t, int64(2), buf.blocks[1].blockNumber) require.Equal(t, 1, len(buf.blocks[1].visited)) buf.lock.Unlock() }) @@ -295,6 +296,20 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { fmt.Println(results) verifyBlockNumbers(t, results, 2, 3, 4, 4) }) + + t.Run("dequeue with limits", func(t *testing.T) { + buf := newLogEventBuffer(logger.TestLogger(t), 3, 5, 10) + require.Equal(t, buf.enqueue(big.NewInt(1), + logpoller.Log{BlockNumber: 1, TxHash: common.HexToHash("0x1"), LogIndex: 0}, + logpoller.Log{BlockNumber: 2, TxHash: common.HexToHash("0x2"), LogIndex: 0}, + logpoller.Log{BlockNumber: 3, TxHash: common.HexToHash("0x3"), LogIndex: 0}, + logpoller.Log{BlockNumber: 4, TxHash: common.HexToHash("0x4"), LogIndex: 0}, + logpoller.Log{BlockNumber: 5, TxHash: common.HexToHash("0x5"), LogIndex: 0}, + ), 5) + + logs := buf.dequeue(10, 2) + require.Equal(t, 2, len(logs)) + }) } func verifyBlockNumbers(t *testing.T, logs []fetchedLog, bns ...int64) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/factory.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/factory.go new file mode 100644 index 00000000000..cbbb8db54dc --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/factory.go @@ -0,0 +1,19 @@ +package logprovider + +import ( + "github.com/ethereum/go-ethereum/accounts/abi" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" +) + +func New(lggr logger.Logger, poller logpoller.LogPoller, c client.Client, utilsABI abi.ABI, stateStore core.UpkeepStateReader) (LogEventProvider, LogRecoverer) { + filterStore := NewUpkeepFilterStore() + packer := NewLogEventsPacker(utilsABI) + provider := NewLogProvider(lggr, poller, packer, filterStore, nil) + recoverer := NewLogRecoverer(lggr, poller, c, stateStore, packer, filterStore, 0, provider.opts.LookbackBlocks) + + return provider, recoverer +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go index fe6f6ffeead..e139655c59b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go @@ -19,6 +19,11 @@ type UpkeepFilterStore interface { Size() int } +type UpkeepFilterStoreTest interface { + UpkeepFilterStore + ResetLastPollBlock() +} + var _ UpkeepFilterStore = &upkeepFilterStore{} type upkeepFilter struct { @@ -36,6 +41,21 @@ type upkeepFilter struct { lastRePollBlock int64 } +func (f upkeepFilter) Clone() upkeepFilter { + topics := make([]common.Hash, len(f.topics)) + copy(topics, f.topics) + addr := make([]byte, len(f.addr)) + copy(addr, f.addr) + return upkeepFilter{ + upkeepID: f.upkeepID, + topics: topics, + addr: addr, + lastPollBlock: f.lastPollBlock, + lastRePollBlock: f.lastRePollBlock, + blockLimiter: f.blockLimiter, + } +} + type upkeepFilterStore struct { lock *sync.RWMutex // filters is a map of upkeepID to upkeepFilter @@ -130,7 +150,7 @@ func (s *upkeepFilterStore) GetFilters(selector func(upkeepFilter) bool) []upkee var filters []upkeepFilter for _, f := range s.filters { if selector(f) { - filters = append(filters, f) + filters = append(filters, f.Clone()) } } return filters @@ -161,3 +181,13 @@ func (s *upkeepFilterStore) Size() int { return len(s.filters) } + +func (s *upkeepFilterStore) ResetLastPollBlock() { + s.lock.Lock() + defer s.lock.Unlock() + + for k, f := range s.filters { + f.lastPollBlock = 0 + s.filters[k] = f + } +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go index 91c32409b80..b2030a8dc96 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store_test.go @@ -2,6 +2,7 @@ package logprovider import ( "math/big" + "sort" "sync" "testing" @@ -50,7 +51,16 @@ func TestFilterStore_CRUD(t *testing.T) { require.Equal(t, len(tc.initial), len(s.GetIDs(nil))) s.AddActiveUpkeeps(tc.toAdd...) require.Equal(t, len(tc.expectedPostAdd), s.Size()) - require.Equal(t, len(tc.expectedPostAdd), len(s.GetFilters(func(f upkeepFilter) bool { return true }))) + filters := s.GetFilters(func(f upkeepFilter) bool { return true }) + require.Equal(t, len(tc.expectedPostAdd), len(filters)) + if len(filters) > 0 { + sort.Slice(filters, func(i, j int) bool { + return filters[i].upkeepID.Cmp(filters[j].upkeepID) < 0 + }) + for i, f := range filters { + require.Equal(t, tc.expectedPostAdd[i].upkeepID, f.upkeepID) + } + } s.RemoveActiveUpkeeps(tc.toRemove...) require.Equal(t, len(tc.expectedPostRemove), len(s.GetIDs(func(upkeepFilter) bool { return true }))) }) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index 6ba8da90362..fdb3cbb7ea5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -25,6 +25,7 @@ import ( ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/assets" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" @@ -35,6 +36,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + kevmcore "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) @@ -53,7 +55,10 @@ func TestIntegration_LogEventProvider(t *testing.T) { opts := &logprovider.LogEventProviderOptions{ ReadInterval: time.Second / 2, } - logProvider, _, lp, ethClient := setupLogProvider(t, db, backend, opts) + lp, ethClient, utilsABI := setupDependencies(t, db, backend) + filterStore := logprovider.NewUpkeepFilterStore() + provider, _ := setup(logger.TestLogger(t), lp, nil, utilsABI, nil, filterStore, opts) + logProvider := provider.(logprovider.LogEventProviderTest) n := 10 @@ -69,52 +74,97 @@ func TestIntegration_LogEventProvider(t *testing.T) { defer logProvider.Close() logsRounds := 10 - pollerTimeout := time.Second * 5 poll := pollFn(ctx, t, lp, ethClient) triggerEvents(ctx, t, backend, carrol, logsRounds, poll, contracts...) poll(backend.Commit()) - // let it time to poll - <-time.After(pollerTimeout) - logs, _ := logProvider.GetLatestPayloads(ctx) - require.NoError(t, logProvider.Close()) + waitLogPoller(ctx, t, backend, lp, ethClient) + + waitLogProvider(ctx, t, logProvider, 3) + + allPayloads := collectPayloads(ctx, t, logProvider, n, 5) + require.GreaterOrEqual(t, len(allPayloads), n, + "failed to get logs after restart") - require.GreaterOrEqual(t, len(logs), n, "failed to get all logs") t.Run("Restart", func(t *testing.T) { + t.Log("restarting log provider") // assuming that our service was closed and restarted, // we should be able to backfill old logs and fetch new ones - require.NoError(t, logProvider.Close()) + logDataABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + require.NoError(t, err) + filterStore.ResetLastPollBlock() + logProvider2 := logprovider.NewLogProvider(logger.TestLogger(t), lp, logprovider.NewLogEventsPacker(logDataABI), filterStore, opts) poll(backend.Commit()) - go func() { - if err := logProvider.Start(ctx); err != nil { - t.Logf("error starting log provider: %s", err) + if err2 := logProvider2.Start(ctx); err2 != nil { + t.Logf("error starting log provider: %s", err2) t.Fail() } }() - defer logProvider.Close() - - logsAfterRestart, _ := logProvider.GetLatestPayloads(ctx) - require.GreaterOrEqual(t, len(logsAfterRestart), 0, - "logs should have been marked visited") - - triggerEvents(ctx, t, backend, carrol, logsRounds, poll, contracts...) - // let it time to poll - poll(backend.Commit()) + defer logProvider2.Close() - <-time.After(pollerTimeout) + waitLogProvider(ctx, t, logProvider2, 2) - logsAfterRestart, _ = logProvider.GetLatestPayloads(ctx) - require.NoError(t, logProvider.Close()) + t.Log("getting logs after restart") + logsAfterRestart := collectPayloads(ctx, t, logProvider2, n, 5) require.GreaterOrEqual(t, len(logsAfterRestart), n, "failed to get logs after restart") }) } +func TestIntegration_LogEventProvider_Backfill(t *testing.T) { + ctx, cancel := context.WithTimeout(testutils.Context(t), time.Second*60) + defer cancel() + + backend, stopMining, accounts := setupBackend(t) + defer stopMining() + carrol := accounts[2] + + db := setupDB(t) + defer db.Close() + + opts := &logprovider.LogEventProviderOptions{ + ReadInterval: time.Second / 4, + } + lp, ethClient, utilsABI := setupDependencies(t, db, backend) + filterStore := logprovider.NewUpkeepFilterStore() + provider, _ := setup(logger.TestLogger(t), lp, nil, utilsABI, nil, filterStore, opts) + logProvider := provider.(logprovider.LogEventProviderTest) + + n := 10 + + _, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) + + poll := pollFn(ctx, t, lp, ethClient) + + rounds := 8 + for i := 0; i < rounds; i++ { + poll(backend.Commit()) + triggerEvents(ctx, t, backend, carrol, n, poll, contracts...) + poll(backend.Commit()) + } + + waitLogPoller(ctx, t, backend, lp, ethClient) + + // starting the log provider should backfill logs + go func() { + if startErr := logProvider.Start(ctx); startErr != nil { + t.Logf("error starting log provider: %s", startErr) + t.Fail() + } + }() + defer logProvider.Close() + + waitLogProvider(ctx, t, logProvider, 3) + + allPayloads := collectPayloads(ctx, t, logProvider, n, 5) + require.GreaterOrEqual(t, len(allPayloads), len(contracts), "failed to backfill logs") +} + func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { setupTest := func( t *testing.T, @@ -137,8 +187,10 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { stopMining() _ = db.Close() } - - logProvider, _, lp, ethClient := setupLogProvider(t, db, backend, opts) + lp, ethClient, utilsABI := setupDependencies(t, db, backend) + filterStore := logprovider.NewUpkeepFilterStore() + provider, _ := setup(logger.TestLogger(t), lp, nil, utilsABI, nil, filterStore, opts) + logProvider := provider.(logprovider.LogEventProviderTest) rounds := 5 numberOfUserContracts := 10 @@ -221,7 +273,6 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { _, err := logProvider.GetLatestPayloads(ctx) require.NoError(t, err) - require.NoError(t, logProvider.Close()) }) t.Run("should produce a rate limit error for over burst limit", func(t *testing.T) { @@ -260,7 +311,6 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { _, err := logProvider.GetLatestPayloads(ctx) require.NoError(t, err) - require.NoError(t, logProvider.Close()) }) t.Run("should allow polling after lookback number of blocks have passed", func(t *testing.T) { @@ -272,7 +322,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { BlockLimitBurst: 5, // LogBlocksLookback is set low to reduce the number of blocks required // to reset the block limiter to maxBurst - LogBlocksLookback: 50, + LookbackBlocks: 50, }) defer deferFunc() @@ -311,11 +361,11 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { _, err = logProvider.GetLatestPayloads(ctx) require.NoError(t, err) - require.NoError(t, logProvider.Close()) }) } -func TestIntegration_LogEventProvider_Backfill(t *testing.T) { +func TestIntegration_LogRecoverer_Backfill(t *testing.T) { + t.Skip() // TODO: remove skip after removing constant timeouts ctx, cancel := context.WithTimeout(testutils.Context(t), time.Second*60) defer cancel() @@ -326,9 +376,20 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { db := setupDB(t) defer db.Close() - logProvider, _, lp, ethClient := setupLogProvider(t, db, backend, &logprovider.LogEventProviderOptions{ - ReadInterval: time.Second / 4, - }) + lookbackBlocks := int64(200) + opts := &logprovider.LogEventProviderOptions{ + ReadInterval: time.Second / 4, + LookbackBlocks: lookbackBlocks, + } + lp, ethClient, utilsABI := setupDependencies(t, db, backend) + filterStore := logprovider.NewUpkeepFilterStore() + origDefaultRecoveryInterval := logprovider.DefaultRecoveryInterval + logprovider.DefaultRecoveryInterval = time.Millisecond * 200 + defer func() { + logprovider.DefaultRecoveryInterval = origDefaultRecoveryInterval + }() + provider, recoverer := setup(logger.TestLogger(t), lp, nil, utilsABI, &mockUpkeepStateStore{}, filterStore, opts) + logProvider := provider.(logprovider.LogEventProviderTest) n := 10 @@ -338,47 +399,86 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { rounds := 8 for i := 0; i < rounds; i++ { - poll(backend.Commit()) triggerEvents(ctx, t, backend, carrol, n, poll, contracts...) poll(backend.Commit()) } + poll(backend.Commit()) - t.Log("waiting for log poller to get updated") - // let the log poller work - b, err := ethClient.BlockByHash(ctx, backend.Commit()) - require.NoError(t, err) - latestBlock := b.Number().Int64() - for { - latestPolled, lberr := lp.LatestBlock(pg.WithParentCtx(ctx)) - require.NoError(t, lberr) - if latestPolled >= latestBlock { - break - } - lp.PollAndSaveLogs(ctx, latestBlock) - } + waitLogPoller(ctx, t, backend, lp, ethClient) - // starting the log provider should backfill logs + // create dummy blocks + var blockNumber int64 + for blockNumber < lookbackBlocks*4 { + b, err := ethClient.BlockByHash(ctx, backend.Commit()) + require.NoError(t, err) + bn := b.Number() + blockNumber = bn.Int64() + } + // starting the log recoverer should backfill logs go func() { - if startErr := logProvider.Start(ctx); err != nil { + if startErr := recoverer.Start(ctx); startErr != nil { t.Logf("error starting log provider: %s", startErr) t.Fail() } }() - defer logProvider.Close() + defer recoverer.Close() + + lctx, lcancel := context.WithTimeout(ctx, time.Second*15) + defer lcancel() + var allProposals []ocr2keepers.UpkeepPayload + for lctx.Err() == nil { + poll(backend.Commit()) + proposals, err := recoverer.GetRecoveryProposals(ctx) + require.NoError(t, err) + allProposals = append(allProposals, proposals...) + if len(allProposals) < n { + time.Sleep(100 * time.Millisecond) + continue + } + break + } + require.NoError(t, lctx.Err(), "could not recover logs before timeout") +} + +func collectPayloads(ctx context.Context, t *testing.T, logProvider logprovider.LogEventProvider, n, rounds int) []ocr2keepers.UpkeepPayload { + allPayloads := make([]ocr2keepers.UpkeepPayload, 0) + for ctx.Err() == nil && len(allPayloads) < n && rounds > 0 { + logs, err := logProvider.GetLatestPayloads(ctx) + require.NoError(t, err) + require.LessOrEqual(t, len(logs), logprovider.AllowedLogsPerUpkeep, "failed to get all logs") + allPayloads = append(allPayloads, logs...) + rounds-- + } + return allPayloads +} - t.Log("waiting for log provider to do some backfilling") +// waitLogProvider waits until the provider reaches the given partition +func waitLogProvider(ctx context.Context, t *testing.T, logProvider logprovider.LogEventProviderTest, partition int) { + t.Logf("waiting for log provider to reach partition %d", partition) for ctx.Err() == nil { currentPartition := logProvider.CurrentPartitionIdx() - if currentPartition > 2 { // make sure we went over all items + if currentPartition > uint64(partition) { // make sure we went over all items break } + time.Sleep(100 * time.Millisecond) } +} - logs, err := logProvider.GetLatestPayloads(ctx) +// waitLogPoller waits until the log poller is familiar with the given block +func waitLogPoller(ctx context.Context, t *testing.T, backend *backends.SimulatedBackend, lp logpoller.LogPollerTest, ethClient *evmclient.SimulatedBackendClient) { + t.Log("waiting for log poller to get updated") + // let the log poller work + b, err := ethClient.BlockByHash(ctx, backend.Commit()) require.NoError(t, err) - require.NoError(t, logProvider.Close()) - - require.GreaterOrEqual(t, len(logs), len(contracts), "failed to backfill logs") + latestBlock := b.Number().Int64() + for { + latestPolled, lberr := lp.LatestBlock(pg.WithParentCtx(ctx)) + require.NoError(t, lberr) + if latestPolled >= latestBlock { + break + } + lp.PollAndSaveLogs(ctx, latestBlock) + } } func pollFn(ctx context.Context, t *testing.T, lp logpoller.LogPollerTest, ethClient *evmclient.SimulatedBackendClient) func(blockHash common.Hash) { @@ -456,20 +556,29 @@ func newPlainLogTriggerConfig(upkeepAddr common.Address) logprovider.LogTriggerC } } -func setupLogProvider(t *testing.T, db *sqlx.DB, backend *backends.SimulatedBackend, opts *logprovider.LogEventProviderOptions) (logprovider.LogEventProviderTest, logprovider.UpkeepFilterStore, logpoller.LogPollerTest, *evmclient.SimulatedBackendClient) { +func setupDependencies(t *testing.T, db *sqlx.DB, backend *backends.SimulatedBackend) (logpoller.LogPollerTest, *evmclient.SimulatedBackendClient, abi.ABI) { ethClient := evmclient.NewSimulatedBackendClient(t, backend, big.NewInt(1337)) pollerLggr := logger.TestLogger(t) pollerLggr.SetLogLevel(zapcore.WarnLevel) lorm := logpoller.NewORM(big.NewInt(1337), db, pollerLggr, pgtest.NewQConfig(false)) lp := logpoller.NewLogPoller(lorm, ethClient, pollerLggr, 100*time.Millisecond, 1, 2, 2, 1000) - lggr := logger.TestLogger(t) - logDataABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) require.NoError(t, err) - filterStore := logprovider.NewUpkeepFilterStore() - logProvider := logprovider.New(lggr, lp, logprovider.NewLogEventsPacker(logDataABI), filterStore, opts) - return logProvider, filterStore, lp, ethClient + return lp, ethClient, utilsABI +} + +func setup(lggr logger.Logger, poller logpoller.LogPoller, c client.Client, utilsABI abi.ABI, stateStore kevmcore.UpkeepStateReader, filterStore logprovider.UpkeepFilterStore, opts *logprovider.LogEventProviderOptions) (logprovider.LogEventProvider, logprovider.LogRecoverer) { + packer := logprovider.NewLogEventsPacker(utilsABI) + if opts == nil { + opts = new(logprovider.LogEventProviderOptions) + opts.Defaults() + } + provider := logprovider.NewLogProvider(lggr, poller, packer, filterStore, opts) + recoverer := logprovider.NewLogRecoverer(lggr, poller, c, stateStore, packer, filterStore, 0, opts.LookbackBlocks) + + return provider, recoverer } func setupBackend(t *testing.T) (*backends.SimulatedBackend, func(), []*bind.TransactOpts) { @@ -500,3 +609,14 @@ func setupDB(t *testing.T) *sqlx.DB { }) return db } + +type mockUpkeepStateStore struct { +} + +func (m *mockUpkeepStateStore) SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + states := make([]ocr2keepers.UpkeepState, len(workIDs)) + for i := range workIDs { + states[i] = ocr2keepers.UnknownState + } + return states, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/log_packer.go similarity index 93% rename from core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/log_packer.go index 86caebd9bc7..c4e8d7e0da2 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/abi.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/log_packer.go @@ -28,7 +28,7 @@ func (p *logEventsPacker) PackLogData(log logpoller.Log) ([]byte, error) { } b, err := p.abi.Pack("_log", &automation_utils_2_1.Log{ Index: big.NewInt(log.LogIndex), - TxIndex: big.NewInt(0), // TODO + TxIndex: big.NewInt(0), // TODO: Add this to the logpoller TxHash: log.TxHash, BlockNumber: big.NewInt(log.BlockNumber), BlockHash: log.BlockHash, diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 71cf8a15374..9f20589e79f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -6,6 +6,7 @@ import ( "errors" "fmt" "hash" + "io" "math/big" "runtime" "sync" @@ -26,22 +27,25 @@ import ( var ( ErrHeadNotAvailable = fmt.Errorf("head not available") ErrBlockLimitExceeded = fmt.Errorf("block limit exceeded") + + // AllowedLogsPerUpkeep is the maximum number of logs allowed per upkeep every single call. + AllowedLogsPerUpkeep = 5 ) // LogTriggerConfig is an alias for log trigger config. type LogTriggerConfig automation_utils_2_1.LogTriggerConfig -type LogEventProvider interface { - // Start starts the log event provider. - Start(ctx context.Context) error - // Close closes the log event provider. - Close() error +type LogTriggersLifeCycle interface { // RegisterFilter registers the filter (if valid) for the given upkeepID. RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfig) error // UnregisterFilter removes the filter for the given upkeepID. UnregisterFilter(upkeepID *big.Int) error - // GetLatestPayloads returns the logs in the given range. - GetLatestPayloads(context.Context) ([]ocr2keepers.UpkeepPayload, error) +} +type LogEventProvider interface { + ocr2keepers.LogEventProvider + LogTriggersLifeCycle + Start(context.Context) error + io.Closer } type LogEventProviderTest interface { @@ -50,8 +54,8 @@ type LogEventProviderTest interface { CurrentPartitionIdx() uint64 } -var _ ocr2keepers.PayloadBuilder = &logEventProvider{} -var _ ocr2keepers.LogEventProvider = &logEventProvider{} +var _ LogEventProvider = &logEventProvider{} +var _ LogEventProviderTest = &logEventProvider{} // logEventProvider manages log filters for upkeeps and enables to read the log events. type logEventProvider struct { @@ -73,7 +77,7 @@ type logEventProvider struct { currentPartitionIdx uint64 } -func New(lggr logger.Logger, poller logpoller.LogPoller, packer LogDataPacker, filterStore UpkeepFilterStore, opts *LogEventProviderOptions) *logEventProvider { +func NewLogProvider(lggr logger.Logger, poller logpoller.LogPoller, packer LogDataPacker, filterStore UpkeepFilterStore, opts *LogEventProviderOptions) *logEventProvider { if opts == nil { opts = new(LogEventProviderOptions) } @@ -81,7 +85,7 @@ func New(lggr logger.Logger, poller logpoller.LogPoller, packer LogDataPacker, f return &logEventProvider{ packer: packer, lggr: lggr.Named("KeepersRegistry.LogEventProvider"), - buffer: newLogEventBuffer(lggr, opts.LogBufferSize, opts.BufferMaxBlockSize, opts.AllowedLogsPerBlock), + buffer: newLogEventBuffer(lggr, int(opts.LookbackBlocks), BufferMaxBlockSize, AllowedLogsPerBlock), poller: poller, lock: sync.RWMutex{}, opts: opts, @@ -89,73 +93,91 @@ func New(lggr logger.Logger, poller logpoller.LogPoller, packer LogDataPacker, f } } -func (p *logEventProvider) Start(pctx context.Context) error { - ctx, cancel := context.WithCancel(pctx) - defer cancel() +func (p *logEventProvider) Start(context.Context) error { + ctx, cancel := context.WithCancel(context.Background()) p.lock.Lock() + if p.cancel != nil { + p.lock.Unlock() + cancel() // Cancel the created context + return errors.New("already started") + } p.cancel = cancel p.lock.Unlock() readQ := make(chan []*big.Int, 32) - for i := 0; i < p.opts.Readers; i++ { - go p.startReader(ctx, readQ) + p.lggr.Infow("starting log event provider", "readInterval", p.opts.ReadInterval, "readMaxBatchSize", p.opts.ReadBatchSize, "readers", p.opts.Readers) + + { // start readers + go func(ctx context.Context) { + for i := 0; i < p.opts.Readers; i++ { + go p.startReader(ctx, readQ) + } + }(ctx) } - return p.scheduleReadJobs(ctx, func(ids []*big.Int) { - select { - case readQ <- ids: - case <-ctx.Done(): - default: - p.lggr.Warnw("readQ is full, dropping ids", "ids", ids) - } - }) + { // start scheduler + lggr := p.lggr.With("where", "scheduler") + go func(ctx context.Context) { + err := p.scheduleReadJobs(ctx, func(ids []*big.Int) { + select { + case readQ <- ids: + case <-ctx.Done(): + default: + lggr.Warnw("readQ is full, dropping ids", "ids", ids) + } + }) + if err != nil { + lggr.Warnw("stopped scheduling read jobs with error", "err", err) + } + lggr.Debug("stopped scheduling read jobs") + }(ctx) + } + + return nil } func (p *logEventProvider) Close() error { p.lock.Lock() defer p.lock.Unlock() - if p.cancel != nil { - p.cancel() + if cancel := p.cancel; cancel != nil { + p.cancel = nil + cancel() + } else { + return errors.New("already stopped") } return nil } -func (p *logEventProvider) BuildPayloads(ctx context.Context, proposals ...ocr2keepers.CoordinatedBlockProposal) ([]ocr2keepers.UpkeepPayload, error) { - // TODO: implement - return []ocr2keepers.UpkeepPayload{}, nil +func (p *logEventProvider) Name() string { + return p.lggr.Name() } func (p *logEventProvider) GetLatestPayloads(context.Context) ([]ocr2keepers.UpkeepPayload, error) { + // TODO: Fitler logs below upkeep creation block here latest := p.buffer.latestBlockSeen() - diff := latest - p.opts.LogBlocksLookback + diff := latest - p.opts.LookbackBlocks if diff < 0 { diff = latest } - logs := p.buffer.dequeue(int(diff)) + logs := p.buffer.dequeue(int(diff), AllowedLogsPerUpkeep) + + // p.lggr.Debugw("got latest logs from buffer", "latest", latest, "diff", diff, "logs", len(logs)) var payloads []ocr2keepers.UpkeepPayload for _, l := range logs { log := l.log - trig := ocr2keepers.NewTrigger( - ocr2keepers.BlockNumber(log.BlockNumber), - log.BlockHash, - ) - trig.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{ - TxHash: log.TxHash, - Index: uint32(log.LogIndex), - } + trig := logToTrigger(log) checkData, err := p.packer.PackLogData(log) if err != nil { p.lggr.Warnw("failed to pack log data", "err", err, "log", log) continue } - - payload, err := core.NewUpkeepPayload(l.id, trig, checkData) + payload, err := core.NewUpkeepPayload(l.upkeepID, trig, checkData) if err != nil { - // skip invalid payloads + p.lggr.Warnw("failed to create upkeep payload", "err", err, "id", l.upkeepID, "trigger", trig, "checkData", checkData) continue } @@ -171,10 +193,10 @@ func (p *logEventProvider) ReadLogs(ctx context.Context, force bool, ids ...*big if err != nil { return fmt.Errorf("%w: %s", ErrHeadNotAvailable, err) } - entries := p.getEntries(latest, force, ids...) + filters := p.getFilters(latest, force, ids...) - err = p.readLogs(ctx, latest, entries) - p.updateEntriesLastPoll(entries) + err = p.readLogs(ctx, latest, filters) + p.updateFiltersLastPoll(filters) // p.lggr.Debugw("read logs for entries", "latestBlock", latest, "entries", len(entries), "err", err) if err != nil { return fmt.Errorf("fetched logs with errors: %w", err) @@ -204,7 +226,7 @@ func (p *logEventProvider) scheduleReadJobs(pctx context.Context, execute func([ case <-ticker.C: ids := p.getPartitionIds(h, int(partitionIdx)) if len(ids) > 0 { - maxBatchSize := p.opts.ReadMaxBatchSize + maxBatchSize := p.opts.ReadBatchSize for len(ids) > maxBatchSize { batch := ids[:maxBatchSize] execute(batch) @@ -216,7 +238,7 @@ func (p *logEventProvider) scheduleReadJobs(pctx context.Context, execute func([ partitionIdx++ atomic.StoreUint64(&p.currentPartitionIdx, partitionIdx) case <-ctx.Done(): - return nil + return ctx.Err() } } } @@ -246,7 +268,7 @@ func (p *logEventProvider) startReader(pctx context.Context, readQ <-chan []*big // getPartitionIds returns the upkeepIDs for the given partition and the number of partitions. // Partitioning is done by hashing the upkeepID and taking the modulus of the number of partitions. func (p *logEventProvider) getPartitionIds(hashFn hash.Hash, partition int) []*big.Int { - numOfPartitions := p.filterStore.Size() / p.opts.ReadMaxBatchSize + numOfPartitions := p.filterStore.Size() / p.opts.ReadBatchSize if numOfPartitions < 1 { numOfPartitions = 1 } @@ -271,7 +293,7 @@ func (p *logEventProvider) getPartitionIds(hashFn hash.Hash, partition int) []*b return ids } -func (p *logEventProvider) updateEntriesLastPoll(entries []upkeepFilter) { +func (p *logEventProvider) updateFiltersLastPoll(entries []upkeepFilter) { p.filterStore.UpdateFilters(func(orig, f upkeepFilter) upkeepFilter { if f.lastPollBlock > orig.lastPollBlock { orig.lastPollBlock = f.lastPollBlock @@ -280,9 +302,10 @@ func (p *logEventProvider) updateEntriesLastPoll(entries []upkeepFilter) { }, entries...) } -// getEntries returns the filters for the given upkeepIDs, +// getFilters returns the filters for the given upkeepIDs, // returns empty filter for inactive upkeeps. -func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big.Int) []upkeepFilter { +// TODO: Cleanup force variable as it is always passed as true. +func (p *logEventProvider) getFilters(latestBlock int64, force bool, ids ...*big.Int) []upkeepFilter { var filters []upkeepFilter p.filterStore.RangeFiltersByIDs(func(i int, f upkeepFilter) { if len(f.addr) == 0 { // not found @@ -295,19 +318,7 @@ func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big filters = append(filters, upkeepFilter{upkeepID: f.upkeepID}) return } - // cloning struct to be thread safe - topics := make([]common.Hash, len(f.topics)) - copy(topics, f.topics) - addr := make([]byte, len(f.addr)) - copy(addr, f.addr) - filters = append(filters, upkeepFilter{ - upkeepID: f.upkeepID, - topics: topics, - addr: addr, - lastPollBlock: f.lastPollBlock, - lastRePollBlock: f.lastRePollBlock, - blockLimiter: f.blockLimiter, - }) + filters = append(filters, f.Clone()) }, ids...) return filters @@ -315,10 +326,10 @@ func (p *logEventProvider) getEntries(latestBlock int64, force bool, ids ...*big // readLogs calls log poller to get the logs for the given upkeep entries. // -// TODO: batch entries by contract address and call log poller once per contract address -// NOTE: the entries are already grouped by contract address -func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries []upkeepFilter) (merr error) { - lookbackBlocks := p.opts.LogBlocksLookback +// Exploratory: batch filters by contract address and call log poller once per contract address +// NOTE: the filters are already grouped by contract address +func (p *logEventProvider) readLogs(ctx context.Context, latest int64, filters []upkeepFilter) (merr error) { + lookbackBlocks := p.opts.LookbackBlocks if latest < lookbackBlocks { // special case of an empty or new blockchain (e.g. simulated chain) lookbackBlocks = latest @@ -326,52 +337,50 @@ func (p *logEventProvider) readLogs(ctx context.Context, latest int64, entries [ // maxBurst will be used to increase the burst limit to allow a long range scan maxBurst := int(lookbackBlocks + 1) - for _, entry := range entries { - if len(entry.addr) == 0 { + for _, filter := range filters { + if len(filter.addr) == 0 { continue } - // start should either be the last block polled for the entry or the - // lookback range in the case this is the first time the entry is polled - start := entry.lastPollBlock + // start should either be the last block polled for the filter or the + // lookback range in the case this is the first time the filter is polled + start := filter.lastPollBlock if start == 0 || start < latest-lookbackBlocks { start = latest - lookbackBlocks - entry.blockLimiter.SetBurst(maxBurst) + filter.blockLimiter.SetBurst(maxBurst) } - resv := entry.blockLimiter.ReserveN(time.Now(), int(latest-start)) + resv := filter.blockLimiter.ReserveN(time.Now(), int(latest-start)) if !resv.OK() { - merr = errors.Join(merr, fmt.Errorf("%w: %s", ErrBlockLimitExceeded, entry.upkeepID.String())) + merr = errors.Join(merr, fmt.Errorf("%w: %s", ErrBlockLimitExceeded, filter.upkeepID.String())) continue } // adding a buffer to check for reorged logs. - start = start - p.opts.LookbackBuffer + start = start - p.opts.ReorgBuffer if start < 0 { start = 0 } - logs, err := p.poller.LogsWithSigs(start, latest, entry.topics, common.BytesToAddress(entry.addr), pg.WithParentCtx(ctx)) + logs, err := p.poller.LogsWithSigs(start, latest, filter.topics, common.BytesToAddress(filter.addr), pg.WithParentCtx(ctx)) if err != nil { // cancel limit reservation as we failed to get logs resv.Cancel() - // exit if the context was canceled if ctx.Err() != nil { + // exit if the context was canceled return merr } - - merr = errors.Join(merr, fmt.Errorf("failed to get logs for upkeep %s: %w", entry.upkeepID.String(), err)) - + merr = errors.Join(merr, fmt.Errorf("failed to get logs for upkeep %s: %w", filter.upkeepID.String(), err)) continue } // if this limiter's burst was set to the max -> // reset it and cancel the reservation to allow further processing - if entry.blockLimiter.Burst() == maxBurst { + if filter.blockLimiter.Burst() == maxBurst { resv.Cancel() - entry.blockLimiter.SetBurst(p.opts.BlockLimitBurst) + filter.blockLimiter.SetBurst(p.opts.BlockLimitBurst) } - p.buffer.enqueue(entry.upkeepID, logs...) + p.buffer.enqueue(filter.upkeepID, logs...) - entry.lastPollBlock = latest + filter.lastPollBlock = latest } return merr diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go index 752a9c3a709..35dacc0b05b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go @@ -3,6 +3,7 @@ package logprovider import ( "bytes" "math/big" + "time" "github.com/ethereum/go-ethereum/common" "github.com/pkg/errors" @@ -11,6 +12,11 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" ) +var ( + // LogRetention is the amount of time to retain logs for. + LogRetention = 24 * time.Hour +) + func (p *logEventProvider) RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfig) error { if err := p.validateLogTriggerConfig(cfg); err != nil { return errors.Wrap(err, "invalid log trigger config") @@ -18,19 +24,22 @@ func (p *logEventProvider) RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfi filter := p.newLogFilter(upkeepID, cfg) if p.filterStore.Has(upkeepID) { - // TODO: check for updates + // TODO: check if filter was updated, if so unregister previous filter and register new one return errors.Errorf("filter for upkeep with id %s already registered", upkeepID.String()) } + // TODO: ReplayAsync logs for the upkeep from creation block + // TODO: Verify handling of different upkeeps using same filter if err := p.poller.RegisterFilter(filter); err != nil { return errors.Wrap(err, "failed to register upkeep filter") } topics := make([]common.Hash, len(filter.EventSigs)) copy(topics, filter.EventSigs) p.filterStore.AddActiveUpkeeps(upkeepFilter{ - upkeepID: upkeepID, - addr: filter.Addresses[0].Bytes(), - topics: topics, - blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), + upkeepID: upkeepID, + addr: filter.Addresses[0].Bytes(), + topics: topics, + blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), + lastPollBlock: 0, // TODO: Start from filter creation block }) return nil @@ -54,7 +63,7 @@ func (p *logEventProvider) newLogFilter(upkeepID *big.Int, cfg LogTriggerConfig) Name: p.filterName(upkeepID), EventSigs: topics, Addresses: []common.Address{cfg.ContractAddress}, - Retention: p.opts.LogRetention, + Retention: LogRetention, } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go index e300f375e98..3b2e0c7d1df 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go @@ -56,7 +56,7 @@ func TestLogEventProvider_LifeCycle(t *testing.T) { mp.On("RegisterFilter", mock.Anything).Return(nil) mp.On("UnregisterFilter", mock.Anything, mock.Anything).Return(nil) } - p := New(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) + p := NewLogProvider(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) err := p.RegisterFilter(tc.upkeepID, tc.upkeepCfg) if tc.errored { require.Error(t, err) @@ -183,7 +183,7 @@ func TestLogEventProvider_GetFiltersBySelector(t *testing.T) { }, } - p := New(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) + p := NewLogProvider(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_opts.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_opts.go index 7907bc1f21b..1a09e99ec08 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_opts.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_opts.go @@ -8,63 +8,45 @@ import ( // LogEventProviderOptions holds the options for the log event provider. type LogEventProviderOptions struct { - // LogRetention is the amount of time to retain logs for. - LogRetention time.Duration - // AllowedLogsPerBlock is the maximum number of logs allowed per block in the buffer. - BufferMaxBlockSize int - // LogBufferSize is the number of blocks in the buffer. - LogBufferSize int - // AllowedLogsPerBlock is the maximum number of logs allowed per block & upkeep in the buffer. - AllowedLogsPerBlock int - // LogBlocksLookback is the number of blocks to look back for logs. - LogBlocksLookback int64 - // LookbackBuffer is the number of blocks to add as a buffer to the lookback. - LookbackBuffer int64 - // BlockRateLimit is the rate limit for fetching logs per block. + // LookbackBlocks is the number of blocks to look back for logs. + LookbackBlocks int64 + // ReorgBuffer is the number of blocks to add as a buffer to the lookback. + ReorgBuffer int64 + // BlockRateLimit is the rate limit on the range of blocks the we fetch logs for. BlockRateLimit rate.Limit - // BlockLimitBurst is the burst limit for fetching logs per block. + // BlockLimitBurst is the burst upper limit on the range of blocks the we fetch logs for. BlockLimitBurst int // ReadInterval is the interval to fetch logs in the background. ReadInterval time.Duration - // ReadMaxBatchSize is the max number of items in one read batch / partition. - ReadMaxBatchSize int + // ReadBatchSize is the max number of items in one read batch / partition. + ReadBatchSize int // Readers is the number of reader workers to spawn. Readers int } // Defaults sets the default values for the options. func (o *LogEventProviderOptions) Defaults() { - if o.LogRetention == 0 { - o.LogRetention = 24 * time.Hour + if o.LookbackBlocks == 0 { + // TODO: Ensure lookback blocks is at least as large as Finality Depth to + // ensure recoverer does not go beyond finality depth + o.LookbackBlocks = 200 } - if o.BufferMaxBlockSize == 0 { - o.BufferMaxBlockSize = 1024 - } - if o.AllowedLogsPerBlock == 0 { - o.AllowedLogsPerBlock = 128 - } - if o.LogBlocksLookback == 0 { - o.LogBlocksLookback = 512 - } - if o.LogBufferSize == 0 { - o.LogBufferSize = int(o.LogBlocksLookback * 3) - } - if o.LookbackBuffer == 0 { - o.LookbackBuffer = 32 + if o.ReorgBuffer == 0 { + o.ReorgBuffer = 32 } if o.BlockRateLimit == 0 { o.BlockRateLimit = rate.Every(time.Second) } if o.BlockLimitBurst == 0 { - o.BlockLimitBurst = int(o.LogBlocksLookback) + o.BlockLimitBurst = int(o.LookbackBlocks) } if o.ReadInterval == 0 { o.ReadInterval = time.Second } - if o.ReadMaxBatchSize == 0 { - o.ReadMaxBatchSize = 32 + if o.ReadBatchSize == 0 { + o.ReadBatchSize = 32 } if o.Readers == 0 { - o.Readers = 2 + o.Readers = 4 } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go index 7886623f92e..8660bb8097c 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go @@ -22,22 +22,22 @@ import ( ) func TestLogEventProvider_GetEntries(t *testing.T) { - p := New(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) + p := NewLogProvider(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) _, f := newEntry(p, 1) p.filterStore.AddActiveUpkeeps(f) t.Run("no entries", func(t *testing.T) { - entries := p.getEntries(0, false, big.NewInt(0)) + entries := p.getFilters(0, false, big.NewInt(0)) require.Len(t, entries, 1) require.Equal(t, len(entries[0].addr), 0) }) t.Run("has entry with lower lastPollBlock", func(t *testing.T) { - entries := p.getEntries(0, false, f.upkeepID) + entries := p.getFilters(0, false, f.upkeepID) require.Len(t, entries, 1) require.Greater(t, len(entries[0].addr), 0) - entries = p.getEntries(10, false, f.upkeepID) + entries = p.getFilters(10, false, f.upkeepID) require.Len(t, entries, 1) require.Greater(t, len(entries[0].addr), 0) }) @@ -47,18 +47,18 @@ func TestLogEventProvider_GetEntries(t *testing.T) { f.lastPollBlock = 3 p.filterStore.AddActiveUpkeeps(f) - entries := p.getEntries(1, false, f.upkeepID) + entries := p.getFilters(1, false, f.upkeepID) require.Len(t, entries, 1) require.Equal(t, len(entries[0].addr), 0) - entries = p.getEntries(1, true, f.upkeepID) + entries = p.getFilters(1, true, f.upkeepID) require.Len(t, entries, 1) require.Greater(t, len(entries[0].addr), 0) }) } func TestLogEventProvider_UpdateEntriesLastPoll(t *testing.T) { - p := New(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) + p := NewLogProvider(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) n := 10 @@ -71,7 +71,7 @@ func TestLogEventProvider_UpdateEntriesLastPoll(t *testing.T) { t.Run("no entries", func(t *testing.T) { _, f := newEntry(p, n*2) f.lastPollBlock = 10 - p.updateEntriesLastPoll([]upkeepFilter{f}) + p.updateFiltersLastPoll([]upkeepFilter{f}) filters := p.filterStore.GetFilters(nil) for _, f := range filters { @@ -84,14 +84,14 @@ func TestLogEventProvider_UpdateEntriesLastPoll(t *testing.T) { f2.lastPollBlock = 10 _, f1 := newEntry(p, n-1) f1.lastPollBlock = 10 - p.updateEntriesLastPoll([]upkeepFilter{f1, f2}) + p.updateFiltersLastPoll([]upkeepFilter{f1, f2}) p.filterStore.RangeFiltersByIDs(func(_ int, f upkeepFilter) { require.Equal(t, int64(10), f.lastPollBlock) }, f1.upkeepID, f2.upkeepID) // update with same block - p.updateEntriesLastPoll([]upkeepFilter{f1}) + p.updateFiltersLastPoll([]upkeepFilter{f1}) // checking other entries are not updated _, f := newEntry(p, 1) @@ -172,9 +172,9 @@ func TestLogEventProvider_ScheduleReadJobs(t *testing.T) { defer cancel() readInterval := 10 * time.Millisecond - p := New(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), &LogEventProviderOptions{ - ReadMaxBatchSize: tc.maxBatchSize, - ReadInterval: readInterval, + p := NewLogProvider(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), &LogEventProviderOptions{ + ReadBatchSize: tc.maxBatchSize, + ReadInterval: readInterval, }) var ids []*big.Int @@ -248,7 +248,7 @@ func TestLogEventProvider_ReadLogs(t *testing.T) { }, }, nil) - p := New(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) + p := NewLogProvider(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) var ids []*big.Int for i := 0; i < 10; i++ { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go index 4284448b40b..594a5110946 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go @@ -2,82 +2,254 @@ package logprovider import ( "context" + "crypto/rand" "errors" + "fmt" + "io" + "math/big" + "sort" "sync" + "sync/atomic" "time" + "github.com/ethereum/go-ethereum/common" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) var ( - ErrNotFound = errors.New("not found") + ErrNotFound = errors.New("not found") + DefaultRecoveryInterval = 5 * time.Second + // TODO: Reduce these intervals to allow sending same proposals again if they were not fulfilled + RecoveryCacheTTL = 24*time.Hour - time.Second + GCInterval = time.Hour + + recoveryBatchSize = 10 + recoveryLogsBuffer = int64(50) ) +type LogRecoverer interface { + ocr2keepers.RecoverableProvider + GetProposalData(context.Context, ocr2keepers.CoordinatedBlockProposal) ([]byte, error) + + Start(context.Context) error + io.Closer +} + +// TODO: Ensure that the logs enqueued into pending reach a final state type logRecoverer struct { lggr logger.Logger cancel context.CancelFunc + lookbackBlocks *atomic.Int64 + blockTime *atomic.Int64 + interval time.Duration - lock *sync.RWMutex + lock sync.RWMutex pending []ocr2keepers.UpkeepPayload - visited map[string]bool + visited map[string]time.Time - poller logpoller.LogPoller + filterStore UpkeepFilterStore + states core.UpkeepStateReader + packer LogDataPacker + poller logpoller.LogPoller + client client.Client } -var _ ocr2keepers.RecoverableProvider = &logRecoverer{} +var _ LogRecoverer = &logRecoverer{} -func NewLogRecoverer(lggr logger.Logger, poller logpoller.LogPoller, interval time.Duration) *logRecoverer { +func NewLogRecoverer(lggr logger.Logger, poller logpoller.LogPoller, client client.Client, stateStore core.UpkeepStateReader, packer LogDataPacker, filterStore UpkeepFilterStore, interval time.Duration, lookbackBlocks int64) *logRecoverer { if interval == 0 { - interval = 30 * time.Second + interval = DefaultRecoveryInterval } - return &logRecoverer{ - lggr: lggr.Named("LogRecoverer"), - interval: interval, - lock: &sync.RWMutex{}, - pending: make([]ocr2keepers.UpkeepPayload, 0), - visited: make(map[string]bool), - poller: poller, + + rec := &logRecoverer{ + lggr: lggr.Named("LogRecoverer"), + + blockTime: &atomic.Int64{}, + lookbackBlocks: &atomic.Int64{}, + interval: interval, + + pending: make([]ocr2keepers.UpkeepPayload, 0), + visited: make(map[string]time.Time), + poller: poller, + filterStore: filterStore, + states: stateStore, + packer: packer, + client: client, } + + rec.lookbackBlocks.Store(lookbackBlocks) + rec.blockTime.Store(int64(defaultBlockTime)) + + return rec } func (r *logRecoverer) Start(pctx context.Context) error { - ctx, cancel := context.WithCancel(pctx) + ctx, cancel := context.WithCancel(context.Background()) + r.lock.Lock() + if r.cancel != nil { + r.lock.Unlock() + cancel() // Cancel the created context + return errors.New("already started") + } r.cancel = cancel - interval := r.interval r.lock.Unlock() - ticker := time.NewTicker(interval) - defer ticker.Stop() + blockTimeResolver := newBlockTimeResolver(r.poller) + blockTime, err := blockTimeResolver.BlockTime(ctx, defaultSampleSize) + if err != nil { + // TODO: TBD exit or just log a warning + // return fmt.Errorf("failed to compute block time: %w", err) + r.lggr.Warnw("failed to compute block time", "err", err) + } + if blockTime > 0 { + r.blockTime.Store(int64(blockTime)) + } - r.lggr.Debug("Starting log recoverer") + r.lggr.Infow("starting log recoverer", "blockTime", r.blockTime.Load(), "lookbackBlocks", r.lookbackBlocks.Load(), "interval", r.interval) - for { - select { - case <-ticker.C: - r.recover(ctx) - case <-ctx.Done(): - return nil - } + { + go func(ctx context.Context, interval time.Duration) { + ticker := time.NewTicker(interval) + defer ticker.Stop() + + gcTicker := time.NewTicker(GCInterval) + defer gcTicker.Stop() + + for { + select { + case <-ticker.C: + if err := r.recover(ctx); err != nil { + r.lggr.Warnw("failed to recover logs", "err", err) + } + case <-gcTicker.C: + r.clean(ctx) + case <-ctx.Done(): + return + } + } + }(ctx, r.interval) } + + return nil } func (r *logRecoverer) Close() error { r.lock.Lock() defer r.lock.Unlock() - if r.cancel != nil { - r.cancel() + if cancel := r.cancel; cancel != nil { + r.cancel = nil + cancel() + } else { + return errors.New("already stopped") } return nil } +func (r *logRecoverer) GetProposalData(ctx context.Context, proposal ocr2keepers.CoordinatedBlockProposal) ([]byte, error) { + switch core.GetUpkeepType(proposal.UpkeepID) { + case ocr2keepers.LogTrigger: + return r.getLogTriggerCheckData(ctx, proposal) + default: + return []byte{}, errors.New("not a log trigger upkeep ID") + } +} + +func (r *logRecoverer) getLogTriggerCheckData(ctx context.Context, proposal ocr2keepers.CoordinatedBlockProposal) ([]byte, error) { + if !r.filterStore.Has(proposal.UpkeepID.BigInt()) { + return nil, fmt.Errorf("filter not found for upkeep %v", proposal.UpkeepID) + } + latest, err := r.poller.LatestBlock(pg.WithParentCtx(ctx)) + if err != nil { + return nil, err + } + + // TODO: Ensure start block is above upkeep creation block + start, offsetBlock := r.getRecoveryWindow(latest) + if proposal.Trigger.LogTriggerExtension == nil { + return nil, errors.New("missing log trigger extension") + } + logBlock := int64(proposal.Trigger.LogTriggerExtension.BlockNumber) + if logBlock == 0 { + var number *big.Int + number, _, err = r.getTxBlock(proposal.Trigger.LogTriggerExtension.TxHash) + if err != nil { + return nil, err + } + if number == nil { + return nil, errors.New("failed to get tx block") + } + logBlock = number.Int64() + } + if isRecoverable := logBlock < offsetBlock && logBlock > start; !isRecoverable { + return nil, errors.New("log block is not recoverable") + } + upkeepStates, err := r.states.SelectByWorkIDsInRange(ctx, int64(logBlock)-1, offsetBlock, proposal.WorkID) + if err != nil { + return nil, err + } + + for _, upkeepState := range upkeepStates { + switch upkeepState { + case ocr2keepers.Performed, ocr2keepers.Ineligible: + return nil, errors.New("upkeep state is not recoverable") + default: + // we can proceed + } + } + + var filter upkeepFilter + r.filterStore.RangeFiltersByIDs(func(i int, f upkeepFilter) { + filter = f + }, proposal.UpkeepID.BigInt()) + + if len(filter.addr) == 0 { + return nil, fmt.Errorf("invalid filter found for upkeepID %s", proposal.UpkeepID.String()) + } + + logs, err := r.poller.LogsWithSigs(logBlock-1, logBlock+1, filter.topics, common.BytesToAddress(filter.addr), pg.WithParentCtx(ctx)) + if err != nil { + return nil, fmt.Errorf("could not read logs: %w", err) + } + + for _, log := range logs { + trigger := logToTrigger(log) + // use coordinated proposal block number as checkblock/hash + trigger.BlockHash = proposal.Trigger.BlockHash + trigger.BlockNumber = proposal.Trigger.BlockNumber + wid := core.UpkeepWorkID(proposal.UpkeepID, trigger) + if wid == proposal.WorkID { + r.lggr.Debugw("found log for proposal", "upkeepId", proposal.UpkeepID, "trigger.ext", trigger.LogTriggerExtension) + checkData, err := r.packer.PackLogData(log) + if err != nil { + return nil, fmt.Errorf("failed to pack log data: %w", err) + } + return checkData, nil + } + } + return nil, fmt.Errorf("no log found for upkeepID %v and trigger %+v", proposal.UpkeepID, proposal.Trigger) +} + +func (r *logRecoverer) getTxBlock(txHash common.Hash) (*big.Int, common.Hash, error) { + // TODO: do manual eth_getTransactionReceipt call to get block number and hash + txr, err := r.client.TransactionReceipt(context.Background(), txHash) + if err != nil { + return nil, common.Hash{}, err + } + + return txr.BlockNumber, txr.BlockHash, nil +} + func (r *logRecoverer) GetRecoveryProposals(ctx context.Context) ([]ocr2keepers.UpkeepPayload, error) { r.lock.Lock() defer r.lock.Unlock() @@ -86,16 +258,256 @@ func (r *logRecoverer) GetRecoveryProposals(ctx context.Context) ([]ocr2keepers. return nil, nil } - pending := r.pending - r.pending = make([]ocr2keepers.UpkeepPayload, 0) + logsCount := map[string]int{} + + var results, pending []ocr2keepers.UpkeepPayload + for _, payload := range r.pending { + uid := payload.UpkeepID.String() + if logsCount[uid] >= AllowedLogsPerUpkeep { + pending = append(pending, payload) + continue + } + logsCount[uid]++ + results = append(results, payload) + } + r.pending = pending + + r.lggr.Debugf("found %d pending payloads", len(pending)) + + return results, nil +} + +func (r *logRecoverer) recover(ctx context.Context) error { + latest, err := r.poller.LatestBlock(pg.WithParentCtx(ctx)) + if err != nil { + return fmt.Errorf("%w: %s", ErrHeadNotAvailable, err) + } + // TODO: Ensure start block is above upkeep creation block + start, offsetBlock := r.getRecoveryWindow(latest) + if offsetBlock < 0 { + // too soon to recover, we don't have enough blocks + return nil + } + + filters := r.getFilterBatch(offsetBlock) + if len(filters) == 0 { + return nil + } + + r.lggr.Debugw("recovering logs", "filters", filters, "startBlock", start, "offsetBlock", offsetBlock, "latestBlock", latest) - for _, p := range pending { - r.visited[p.WorkID] = true + var wg sync.WaitGroup + for _, f := range filters { + wg.Add(1) + go func(f upkeepFilter) { + defer wg.Done() + if err := r.recoverFilter(ctx, f, start, offsetBlock); err != nil { + r.lggr.Debugw("error recovering filter", "err", err.Error()) + } + }(f) } + wg.Wait() - return pending, nil + return nil +} + +// recoverFilter recovers logs for a single upkeep filter. +func (r *logRecoverer) recoverFilter(ctx context.Context, f upkeepFilter, startBlock, offsetBlock int64) error { + start := f.lastRePollBlock + if start < startBlock { + start = startBlock + } + if start < 0 { + start = 0 + } + end := start + recoveryLogsBuffer + if end > offsetBlock { + end = offsetBlock + } + // we expect start to be > offsetBlock in any case + logs, err := r.poller.LogsWithSigs(start, end, f.topics, common.BytesToAddress(f.addr), pg.WithParentCtx(ctx)) + if err != nil { + return fmt.Errorf("could not read logs: %w", err) + } + + workIDs := make([]string, 0) + for _, log := range logs { + trigger := logToTrigger(log) + upkeepId := &ocr2keepers.UpkeepIdentifier{} + ok := upkeepId.FromBigInt(f.upkeepID) + if !ok { + r.lggr.Warnw("failed to convert upkeepID to UpkeepIdentifier", "upkeepID", f.upkeepID) + continue + } + workIDs = append(workIDs, core.UpkeepWorkID(*upkeepId, trigger)) + } + + states, err := r.states.SelectByWorkIDsInRange(ctx, start, end, workIDs...) + if err != nil { + return fmt.Errorf("could not read states: %w", err) + } + if len(logs) != len(states) { + return fmt.Errorf("log and state count mismatch: %d != %d", len(logs), len(states)) + } + filteredLogs := r.filterFinalizedStates(f, logs, states) + + added, alreadyPending := r.populatePending(f, filteredLogs) + if added > 0 { + r.lggr.Debugw("found missed logs", "count", added, "upkeepID", f.upkeepID) + } else if alreadyPending == 0 { + r.filterStore.UpdateFilters(func(uf1, uf2 upkeepFilter) upkeepFilter { + uf1.lastRePollBlock = end + return uf1 + }, f) + } + + return nil +} + +// populatePending adds the logs to the pending list if they are not already pending. +// returns the number of logs added and the number of logs that were already pending. +func (r *logRecoverer) populatePending(f upkeepFilter, filteredLogs []logpoller.Log) (int, int) { + r.lock.Lock() + defer r.lock.Unlock() + + pendingSizeBefore := len(r.pending) + alreadyPending := 0 + for _, log := range filteredLogs { + trigger := logToTrigger(log) + // Set the checkBlock and Hash to zero so that the checkPipeline uses the latest block + trigger.BlockHash = [32]byte{} + trigger.BlockNumber = 0 + upkeepId := &ocr2keepers.UpkeepIdentifier{} + ok := upkeepId.FromBigInt(f.upkeepID) + if !ok { + r.lggr.Warnw("failed to convert upkeepID to UpkeepIdentifier", "upkeepID", f.upkeepID) + continue + } + wid := core.UpkeepWorkID(*upkeepId, trigger) + if _, ok := r.visited[wid]; ok { + alreadyPending++ + continue + } + checkData, err := r.packer.PackLogData(log) + if err != nil { + r.lggr.Warnw("failed to pack log data", "err", err, "log", log) + continue + } + payload, err := core.NewUpkeepPayload(f.upkeepID, trigger, checkData) + if err != nil { + r.lggr.Warnw("failed to create payload", "err", err, "log", log) + continue + } + // r.lggr.Debugw("adding a payload to pending", "payload", payload) + r.visited[wid] = time.Now() + r.pending = append(r.pending, payload) + } + return len(r.pending) - pendingSizeBefore, alreadyPending +} + +// filterFinalizedStates filters out the log upkeeps that have already been completed (performed or ineligible). +func (r *logRecoverer) filterFinalizedStates(f upkeepFilter, logs []logpoller.Log, states []ocr2keepers.UpkeepState) []logpoller.Log { + filtered := make([]logpoller.Log, 0) + + for i, log := range logs { + state := states[i] + if state != ocr2keepers.UnknownState { + continue + } + filtered = append(filtered, log) + } + + return filtered +} + +// getRecoveryWindow returns the block range of which the recoverer will try work on +func (r *logRecoverer) getRecoveryWindow(latest int64) (int64, int64) { + lookbackBlocks := r.lookbackBlocks.Load() + blockTime := r.blockTime.Load() + blocksInDay := int64(24*time.Hour) / blockTime + return latest - blocksInDay, latest - lookbackBlocks +} + +// getFilterBatch returns a batch of filters that are ready to be recovered. +func (r *logRecoverer) getFilterBatch(offsetBlock int64) []upkeepFilter { + filters := r.filterStore.GetFilters(func(f upkeepFilter) bool { + return f.lastRePollBlock <= offsetBlock + }) + + sort.Slice(filters, func(i, j int) bool { + return filters[i].lastRePollBlock < filters[j].lastRePollBlock + }) + + return r.selectFilterBatch(filters) } -func (r *logRecoverer) recover(ctx context.Context) { - // TODO: implement +// selectFilterBatch selects a batch of filters to be recovered. +// Half of the batch is selected randomly, the other half is selected +// in order of the oldest lastRePollBlock. +func (r *logRecoverer) selectFilterBatch(filters []upkeepFilter) []upkeepFilter { + batchSize := recoveryBatchSize + + if len(filters) < batchSize { + return filters + } + results := filters[:batchSize/2] + filters = filters[batchSize/2:] + + for len(results) < batchSize && len(filters) != 0 { + i, err := r.randIntn(len(filters)) + if err != nil { + r.lggr.Debugw("error generating random number", "error", err.Error()) + continue + } + results = append(results, filters[i]) + if i == 0 { + filters = filters[1:] + } else if i == len(filters)-1 { + filters = filters[:i] + } else { + filters = append(filters[:i], filters[i+1:]...) + } + } + + return results +} + +func (r *logRecoverer) randIntn(limit int) (int, error) { + n, err := rand.Int(rand.Reader, big.NewInt(int64(limit))) + if err != nil { + return 0, err + } + + return int(n.Int64()), nil +} + +func logToTrigger(log logpoller.Log) ocr2keepers.Trigger { + t := ocr2keepers.NewTrigger( + ocr2keepers.BlockNumber(log.BlockNumber), + log.BlockHash, + ) + t.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{ + TxHash: log.TxHash, + Index: uint32(log.LogIndex), + BlockHash: log.BlockHash, + BlockNumber: ocr2keepers.BlockNumber(log.BlockNumber), + } + return t +} + +func (r *logRecoverer) clean(ctx context.Context) { + r.lock.Lock() + defer r.lock.Unlock() + + cleaned := 0 + for id, t := range r.visited { + if time.Since(t) > RecoveryCacheTTL { + delete(r.visited, id) + cleaned++ + } + } + + if cleaned > 0 { + r.lggr.Debugw("gc: cleaned visited upkeeps", "cleaned", cleaned) + } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go index 79a8f1e1941..b78f0d2ac59 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go @@ -2,19 +2,34 @@ package logprovider import ( "context" + "fmt" + "math/big" + "sort" "testing" "time" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/pkg/errors" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + lpmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core/mocks" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" + "github.com/smartcontractkit/chainlink/v2/core/utils" ) func TestLogRecoverer_GetRecoverables(t *testing.T) { ctx, cancel := context.WithCancel(context.Background()) defer cancel() - r := NewLogRecoverer(logger.TestLogger(t), nil, time.Millisecond*10) + r := NewLogRecoverer(logger.TestLogger(t), nil, nil, nil, nil, nil, time.Millisecond*10, 0) tests := []struct { name string @@ -31,10 +46,33 @@ func TestLogRecoverer_GetRecoverables(t *testing.T) { { "happy flow", []ocr2keepers.UpkeepPayload{ - {WorkID: "1"}, {WorkID: "2"}, + {WorkID: "1", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "2", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "2")}, }, []ocr2keepers.UpkeepPayload{ - {WorkID: "1"}, {WorkID: "2"}, + {WorkID: "1", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "2", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "2")}, + }, + false, + }, + { + "rate limiting", + []ocr2keepers.UpkeepPayload{ + {WorkID: "1", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "2", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "3", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "4", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "5", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "6", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "2", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "2")}, + }, + []ocr2keepers.UpkeepPayload{ + {WorkID: "1", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "2", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "3", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "4", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "5", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1")}, + {WorkID: "2", UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "2")}, }, false, }, @@ -56,3 +94,674 @@ func TestLogRecoverer_GetRecoverables(t *testing.T) { }) } } + +func TestLogRecoverer_Recover(t *testing.T) { + ctx, cancel := context.WithCancel(context.Background()) + defer cancel() + + tests := []struct { + name string + lookbackBlocks int64 + latestBlock int64 + latestBlockErr error + active []upkeepFilter + states []ocr2keepers.UpkeepState + logs []logpoller.Log + logsErr error + recoverErr error + proposalsWorkIDs []string + }{ + { + "no filters", + 200, + 300, + nil, + []upkeepFilter{}, + []ocr2keepers.UpkeepState{}, + []logpoller.Log{}, + nil, + nil, + []string{}, + }, + { + "latest block error", + 200, + 0, + fmt.Errorf("test error"), + []upkeepFilter{}, + []ocr2keepers.UpkeepState{}, + []logpoller.Log{}, + nil, + fmt.Errorf("test error"), + []string{}, + }, + { + "get logs error", + 200, + 300, + nil, + []upkeepFilter{ + { + upkeepID: big.NewInt(1), + addr: common.HexToAddress("0x1").Bytes(), + topics: []common.Hash{ + common.HexToHash("0x1"), + }, + lastPollBlock: 0, + }, + }, + []ocr2keepers.UpkeepState{}, + []logpoller.Log{}, + fmt.Errorf("test error"), + nil, + []string{}, + }, + { + "happy flow", + 100, + 200, + nil, + []upkeepFilter{ + { + upkeepID: big.NewInt(1), + addr: common.HexToAddress("0x1").Bytes(), + topics: []common.Hash{ + common.HexToHash("0x1"), + }, + lastPollBlock: 0, + }, + }, + []ocr2keepers.UpkeepState{ocr2keepers.UnknownState}, + []logpoller.Log{ + { + BlockNumber: 2, + TxHash: common.HexToHash("0x111"), + LogIndex: 1, + BlockHash: common.HexToHash("0x2"), + }, + }, + nil, + nil, + []string{"ef1833ce5eb633189430bf52332ef8a1263ae20b9243f77be2809acb58966616"}, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + lookbackBlocks := int64(100) + recoverer, filterStore, lp, statesReader := setupTestRecoverer(t, time.Millisecond*50, lookbackBlocks) + + filterStore.AddActiveUpkeeps(tc.active...) + lp.On("LatestBlock", mock.Anything).Return(tc.latestBlock, tc.latestBlockErr) + lp.On("LogsWithSigs", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.logs, tc.logsErr) + statesReader.On("SelectByWorkIDsInRange", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.states, nil) + + err := recoverer.recover(ctx) + if tc.recoverErr != nil { + require.Error(t, err) + return + } + require.NoError(t, err) + + proposals, err := recoverer.GetRecoveryProposals(ctx) + require.NoError(t, err) + require.Equal(t, len(tc.proposalsWorkIDs), len(proposals)) + if len(proposals) > 0 { + sort.Slice(proposals, func(i, j int) bool { + return proposals[i].WorkID < proposals[j].WorkID + }) + } + for i := range proposals { + require.Equal(t, tc.proposalsWorkIDs[i], proposals[i].WorkID) + } + }) + } +} + +func TestLogRecoverer_SelectFilterBatch(t *testing.T) { + n := (recoveryBatchSize*2 + 2) + filters := []upkeepFilter{} + for i := 0; i < n; i++ { + filters = append(filters, upkeepFilter{ + upkeepID: big.NewInt(int64(i)), + }) + } + recoverer, _, _, _ := setupTestRecoverer(t, time.Millisecond*50, int64(100)) + + batch := recoverer.selectFilterBatch(filters) + require.Equal(t, recoveryBatchSize, len(batch)) + + batch = recoverer.selectFilterBatch(filters[:recoveryBatchSize/2]) + require.Equal(t, recoveryBatchSize/2, len(batch)) +} + +func TestLogRecoverer_FilterFinalizedStates(t *testing.T) { + tests := []struct { + name string + logs []logpoller.Log + states []ocr2keepers.UpkeepState + want []logpoller.Log + }{ + { + "empty", + []logpoller.Log{}, + []ocr2keepers.UpkeepState{}, + []logpoller.Log{}, + }, + { + "happy flow", + []logpoller.Log{ + {LogIndex: 0}, {LogIndex: 2}, {LogIndex: 2}, + }, + []ocr2keepers.UpkeepState{ + ocr2keepers.UnknownState, + ocr2keepers.Performed, + ocr2keepers.Ineligible, + }, + []logpoller.Log{ + {LogIndex: 0}, + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + recoverer, _, _, _ := setupTestRecoverer(t, time.Millisecond*50, int64(100)) + state := recoverer.filterFinalizedStates(upkeepFilter{}, tc.logs, tc.states) + require.Equal(t, len(tc.want), len(state)) + for i := range state { + require.Equal(t, tc.want[i].LogIndex, state[i].LogIndex) + } + }) + } +} + +func TestLogRecoverer_GetProposalData(t *testing.T) { + for _, tc := range []struct { + name string + proposal ocr2keepers.CoordinatedBlockProposal + skipFilter bool + filterStore UpkeepFilterStore + logPoller logpoller.LogPoller + client client.Client + stateReader core.UpkeepStateReader + wantBytes []byte + expectErr bool + wantErr error + }{ + { + name: "passing an empty proposal with an empty upkeep ID returns an error", + proposal: ocr2keepers.CoordinatedBlockProposal{}, + expectErr: true, + wantErr: errors.New("not a log trigger upkeep ID"), + }, + { + name: "if a filter is not found for the upkeep ID, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + }, + skipFilter: true, + expectErr: true, + wantErr: errors.New("filter not found for upkeep 452312848583266388373324160190187140457511065560374322131410487042692349952"), + }, + { + name: "if an error is encountered fetching the latest block, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 0, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 0, errors.New("latest block boom") + }, + }, + expectErr: true, + wantErr: errors.New("latest block boom"), + }, + { + name: "if an error is encountered fetching the tx receipt, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 0, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + client: &mockClient{ + TransactionReceiptFn: func(ctx context.Context, txHash common.Hash) (*types.Receipt, error) { + return nil, errors.New("tx receipt boom") + }, + }, + expectErr: true, + wantErr: errors.New("tx receipt boom"), + }, + { + name: "if the tx block is nil, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 0, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + client: &mockClient{ + TransactionReceiptFn: func(ctx context.Context, txHash common.Hash) (*types.Receipt, error) { + return &types.Receipt{}, nil + }, + }, + expectErr: true, + wantErr: errors.New("failed to get tx block"), + }, + { + name: "if a log trigger extension block number is 0, and the block number on the tx receipt is not recoverable, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 0, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + client: &mockClient{ + TransactionReceiptFn: func(ctx context.Context, txHash common.Hash) (*types.Receipt, error) { + return &types.Receipt{ + BlockNumber: big.NewInt(200), + }, nil + }, + }, + expectErr: true, + wantErr: errors.New("log block is not recoverable"), + }, + { + name: "if a log block is not recoverable, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 200, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + expectErr: true, + wantErr: errors.New("log block is not recoverable"), + }, + { + name: "if a log block is recoverable, when the upkeep state reader errors, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 80, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return nil, errors.New("upkeep state boom") + }, + }, + expectErr: true, + wantErr: errors.New("upkeep state boom"), + }, + { + name: "if a log block is recoverable, when the upkeep state reader returns a non recoverable state, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 80, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return []ocr2keepers.UpkeepState{ + ocr2keepers.Ineligible, + }, nil + }, + }, + expectErr: true, + wantErr: errors.New("upkeep state is not recoverable"), + }, + { + name: "if a log block is recoverable, when the filter address is empty, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 80, + }, + }, + }, + filterStore: &mockFilterStore{ + HasFn: func(id *big.Int) bool { + return true + }, + RangeFiltersByIDsFn: func(iterator func(int, upkeepFilter), ids ...*big.Int) { + + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return []ocr2keepers.UpkeepState{ + ocr2keepers.UnknownState, + }, nil + }, + }, + expectErr: true, + wantErr: errors.New("invalid filter found for upkeepID 452312848583266388373324160190187140457511065560374322131410487042692349952"), + }, + { + name: "if a log block is recoverable, when the log poller returns an error fetching logs, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 80, + }, + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + LogsWithSigsFn: func(start, end int64, eventSigs []common.Hash, address common.Address, qopts ...pg.QOpt) ([]logpoller.Log, error) { + return nil, errors.New("logs with sigs boom") + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return []ocr2keepers.UpkeepState{ + ocr2keepers.UnknownState, + }, nil + }, + }, + expectErr: true, + wantErr: errors.New("could not read logs: logs with sigs boom"), + }, + { + name: "if a log block is recoverable, when logs cannot be found for an upkeep ID, an error is returned", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: ocr2keepers.Trigger{ + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + BlockNumber: 80, + }, + }, + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + LogsWithSigsFn: func(start, end int64, eventSigs []common.Hash, address common.Address, qopts ...pg.QOpt) ([]logpoller.Log, error) { + return []logpoller.Log{ + { + BlockNumber: 80, + }, + }, nil + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return []ocr2keepers.UpkeepState{ + ocr2keepers.UnknownState, + }, nil + }, + }, + expectErr: true, + wantErr: errors.New(`no log found for upkeepID 452312848583266388373324160190187140457511065560374322131410487042692349952 and trigger {"BlockNumber":0,"BlockHash":"0000000000000000000000000000000000000000000000000000000000000000","LogTriggerExtension":{"BlockHash":"0000000000000000000000000000000000000000000000000000000000000000","BlockNumber":80,"Index":0,"TxHash":"0000000000000000000000000000000000000000000000000000000000000000"}}`), + }, + { + name: "happy path with empty check data", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: func() ocr2keepers.Trigger { + t := ocr2keepers.NewTrigger( + ocr2keepers.BlockNumber(80), + [32]byte{1}, + ) + t.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{ + TxHash: [32]byte{2}, + Index: uint32(3), + BlockHash: [32]byte{1}, + BlockNumber: ocr2keepers.BlockNumber(80), + } + return t + }(), + WorkID: "476453e1b49fc73fa6f97cb77272a07b57f2414a39b0267e58df8cb006d9c491", + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + LogsWithSigsFn: func(start, end int64, eventSigs []common.Hash, address common.Address, qopts ...pg.QOpt) ([]logpoller.Log, error) { + return []logpoller.Log{ + { + BlockNumber: 80, + BlockHash: [32]byte{1}, + TxHash: [32]byte{2}, + LogIndex: 3, + }, + }, nil + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return []ocr2keepers.UpkeepState{ + ocr2keepers.UnknownState, + }, nil + }, + }, + wantBytes: []byte(nil), + }, + { + name: "happy path with check data", + proposal: ocr2keepers.CoordinatedBlockProposal{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123"), + Trigger: func() ocr2keepers.Trigger { + t := ocr2keepers.NewTrigger( + ocr2keepers.BlockNumber(80), + [32]byte{1}, + ) + t.LogTriggerExtension = &ocr2keepers.LogTriggerExtension{ + TxHash: [32]byte{2}, + Index: uint32(3), + BlockHash: [32]byte{1}, + BlockNumber: ocr2keepers.BlockNumber(80), + } + return t + }(), + WorkID: "476453e1b49fc73fa6f97cb77272a07b57f2414a39b0267e58df8cb006d9c491", + }, + logPoller: &mockLogPoller{ + LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { + return 100, nil + }, + LogsWithSigsFn: func(start, end int64, eventSigs []common.Hash, address common.Address, qopts ...pg.QOpt) ([]logpoller.Log, error) { + return []logpoller.Log{ + { + EvmChainId: utils.NewBig(big.NewInt(1)), + LogIndex: 3, + BlockHash: [32]byte{1}, + BlockNumber: 80, + BlockTimestamp: time.Date(2022, 1, 1, 1, 1, 1, 1, time.UTC), + EventSig: common.HexToHash("abc"), + TxHash: [32]byte{2}, + Data: []byte{1, 2, 3}, + CreatedAt: time.Date(2022, 1, 1, 1, 1, 1, 1, time.UTC), + }, + }, nil + }, + }, + stateReader: &mockStateReader{ + SelectByWorkIDsInRangeFn: func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return []ocr2keepers.UpkeepState{ + ocr2keepers.UnknownState, + }, nil + }, + }, + wantBytes: []byte{1, 2, 3}, + }, + } { + t.Run(tc.name, func(t *testing.T) { + recoverer, filterStore, _, _ := setupTestRecoverer(t, time.Second, 10) + + if !tc.skipFilter { + filterStore.AddActiveUpkeeps(upkeepFilter{ + addr: []byte("test"), + upkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "123").BigInt(), + }) + } + + if tc.filterStore != nil { + recoverer.filterStore = tc.filterStore + } + if tc.logPoller != nil { + recoverer.poller = tc.logPoller + } + if tc.client != nil { + recoverer.client = tc.client + } + if tc.stateReader != nil { + recoverer.states = tc.stateReader + } + + b, err := recoverer.GetProposalData(context.Background(), tc.proposal) + if tc.expectErr { + assert.Error(t, err) + assert.Equal(t, tc.wantErr.Error(), err.Error()) + } else { + assert.NoError(t, err) + assert.Equal(t, tc.wantBytes, b) + } + }) + } +} + +type mockFilterStore struct { + UpkeepFilterStore + HasFn func(id *big.Int) bool + RangeFiltersByIDsFn func(iterator func(int, upkeepFilter), ids ...*big.Int) +} + +func (s *mockFilterStore) RangeFiltersByIDs(iterator func(int, upkeepFilter), ids ...*big.Int) { + s.RangeFiltersByIDsFn(iterator, ids...) +} + +func (s *mockFilterStore) Has(id *big.Int) bool { + return s.HasFn(id) +} + +type mockLogPoller struct { + logpoller.LogPoller + LatestBlockFn func(qopts ...pg.QOpt) (int64, error) + LogsWithSigsFn func(start, end int64, eventSigs []common.Hash, address common.Address, qopts ...pg.QOpt) ([]logpoller.Log, error) +} + +func (p *mockLogPoller) LogsWithSigs(start, end int64, eventSigs []common.Hash, address common.Address, qopts ...pg.QOpt) ([]logpoller.Log, error) { + return p.LogsWithSigsFn(start, end, eventSigs, address, qopts...) +} +func (p *mockLogPoller) LatestBlock(qopts ...pg.QOpt) (int64, error) { + return p.LatestBlockFn(qopts...) +} + +type mockClient struct { + client.Client + TransactionReceiptFn func(ctx context.Context, txHash common.Hash) (*types.Receipt, error) +} + +func (c *mockClient) TransactionReceipt(ctx context.Context, txHash common.Hash) (*types.Receipt, error) { + return c.TransactionReceiptFn(ctx, txHash) +} + +type mockStateReader struct { + SelectByWorkIDsInRangeFn func(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) +} + +func (r *mockStateReader) SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { + return r.SelectByWorkIDsInRangeFn(ctx, start, end, workIDs...) +} + +func setupTestRecoverer(t *testing.T, interval time.Duration, lookbackBlocks int64) (*logRecoverer, UpkeepFilterStore, *lpmocks.LogPoller, *mocks.UpkeepStateReader) { + lp := new(lpmocks.LogPoller) + statesReader := new(mocks.UpkeepStateReader) + filterStore := NewUpkeepFilterStore() + recoverer := NewLogRecoverer(logger.TestLogger(t), lp, nil, statesReader, &mockedPacker{}, filterStore, interval, lookbackBlocks) + return recoverer, filterStore, lp, statesReader +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go b/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go index 51991b5d5aa..9351aa71d65 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder.go @@ -7,40 +7,54 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" ) type payloadBuilder struct { - lggr logger.Logger + upkeepList ActiveUpkeepList + lggr logger.Logger + recoverer logprovider.LogRecoverer } var _ ocr2keepers.PayloadBuilder = &payloadBuilder{} -func NewPayloadBuilder(lggr logger.Logger) *payloadBuilder { +func NewPayloadBuilder(activeUpkeepList ActiveUpkeepList, recoverer logprovider.LogRecoverer, lggr logger.Logger) *payloadBuilder { return &payloadBuilder{ - lggr: lggr, + upkeepList: activeUpkeepList, + lggr: lggr, + recoverer: recoverer, } } func (b *payloadBuilder) BuildPayloads(ctx context.Context, proposals ...ocr2keepers.CoordinatedBlockProposal) ([]ocr2keepers.UpkeepPayload, error) { payloads := make([]ocr2keepers.UpkeepPayload, len(proposals)) - for i, p := range proposals { - b.lggr.Debugf("building payload for coordinated block proposal %+v", p) - var checkData []byte - switch core.GetUpkeepType(p.UpkeepID) { - case ocr2keepers.LogTrigger: - checkData = []byte{} // TODO: call recoverer - case ocr2keepers.ConditionTrigger: - // Trigger.BlockNumber and Trigger.BlockHash are already coordinated - checkData = []byte{} // CheckData derived on chain for conditionals - // TODO: check for upkeepID being active upkeep here - default: - } - payload, err := core.NewUpkeepPayload(p.UpkeepID.BigInt(), p.Trigger, checkData) - if err != nil { - b.lggr.Warnw("failed to build payload", "err", err, "upkeepID", p.UpkeepID) - payloads[i] = ocr2keepers.UpkeepPayload{} + + for i, proposal := range proposals { + var payload ocr2keepers.UpkeepPayload + if b.upkeepList.IsActive(proposal.UpkeepID.BigInt()) { + b.lggr.Debugf("building payload for coordinated block proposal %+v", proposal) + checkData := []byte{} + var err error + switch core.GetUpkeepType(proposal.UpkeepID) { + case ocr2keepers.LogTrigger: + checkData, err = b.recoverer.GetProposalData(ctx, proposal) + if err != nil { + b.lggr.Warnw("failed to get log proposal data", "err", err, "upkeepID", proposal.UpkeepID, "trigger", proposal.Trigger) + continue + } + case ocr2keepers.ConditionTrigger: + // Empty checkData for conditionals + } + payload, err = core.NewUpkeepPayload(proposal.UpkeepID.BigInt(), proposal.Trigger, checkData) + if err != nil { + b.lggr.Warnw("error building upkeep payload", "err", err, "upkeepID", proposal.UpkeepID) + continue + } + } else { + b.lggr.Warnw("upkeep is not active, skipping", "upkeepID", proposal.UpkeepID) continue } + payloads[i] = payload } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder_test.go new file mode 100644 index 00000000000..6c0ef78bbc4 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/payload_builder_test.go @@ -0,0 +1,209 @@ +package evm + +import ( + "context" + "math/big" + "testing" + + "github.com/pkg/errors" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/stretchr/testify/assert" + + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" +) + +func TestNewPayloadBuilder(t *testing.T) { + for _, tc := range []struct { + name string + activeList ActiveUpkeepList + recoverer logprovider.LogRecoverer + proposals []types.CoordinatedBlockProposal + wantPayloads []types.UpkeepPayload + }{ + { + name: "for log trigger upkeeps, new payloads are created", + activeList: &mockActiveUpkeepList{ + IsActiveFn: func(id *big.Int) bool { + return true + }, + }, + proposals: []types.CoordinatedBlockProposal{ + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "abc"), + WorkID: "workID1", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + }, + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "def"), + WorkID: "workID2", + Trigger: types.Trigger{ + BlockNumber: 2, + BlockHash: [32]byte{2}, + }, + }, + }, + recoverer: &mockLogRecoverer{ + GetProposalDataFn: func(ctx context.Context, proposal types.CoordinatedBlockProposal) ([]byte, error) { + return []byte{1, 2, 3}, nil + }, + }, + wantPayloads: []types.UpkeepPayload{ + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "abc"), + WorkID: "714f83255c5b562823725748c4a75777c9b78ea8c5ba72ea819926a1fecd389e", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + CheckData: []byte{1, 2, 3}, + }, + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "def"), + WorkID: "3956daa0378d6a761fe972ee00fe98338f17fb6b7865c1d49a8a416cd85977b8", + Trigger: types.Trigger{ + BlockNumber: 2, + BlockHash: [32]byte{2}, + }, + CheckData: []byte{1, 2, 3}, + }, + }, + }, + { + name: "for an inactive log trigger upkeep, an empty payload is added to the list of payloads", + activeList: &mockActiveUpkeepList{ + IsActiveFn: func(id *big.Int) bool { + return core.GenUpkeepID(types.LogTrigger, "ghi").BigInt().Cmp(id) != 0 + }, + }, + proposals: []types.CoordinatedBlockProposal{ + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "abc"), + WorkID: "workID1", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + }, + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "def"), + WorkID: "workID2", + Trigger: types.Trigger{ + BlockNumber: 2, + BlockHash: [32]byte{2}, + }, + }, + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "ghi"), + WorkID: "workID3", + Trigger: types.Trigger{ + BlockNumber: 3, + BlockHash: [32]byte{3}, + }, + }, + }, + recoverer: &mockLogRecoverer{ + GetProposalDataFn: func(ctx context.Context, proposal types.CoordinatedBlockProposal) ([]byte, error) { + return []byte{1, 2, 3}, nil + }, + }, + wantPayloads: []types.UpkeepPayload{ + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "abc"), + WorkID: "714f83255c5b562823725748c4a75777c9b78ea8c5ba72ea819926a1fecd389e", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + CheckData: []byte{1, 2, 3}, + }, + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "def"), + WorkID: "3956daa0378d6a761fe972ee00fe98338f17fb6b7865c1d49a8a416cd85977b8", + Trigger: types.Trigger{ + BlockNumber: 2, + BlockHash: [32]byte{2}, + }, + CheckData: []byte{1, 2, 3}, + }, + {}, + }, + }, + { + name: "when the recoverer errors, an empty payload is created but not added to the list of payloads", + activeList: &mockActiveUpkeepList{ + IsActiveFn: func(id *big.Int) bool { + return true + }, + }, + proposals: []types.CoordinatedBlockProposal{ + { + UpkeepID: core.GenUpkeepID(types.LogTrigger, "abc"), + WorkID: "workID1", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + }, + }, + recoverer: &mockLogRecoverer{ + GetProposalDataFn: func(ctx context.Context, proposal types.CoordinatedBlockProposal) ([]byte, error) { + return nil, errors.New("recoverer boom") + }, + }, + wantPayloads: []types.UpkeepPayload{ + {}, + }, + }, + { + name: "for a conditional upkeep, a new payload with empty check data is added to the list of payloads", + activeList: &mockActiveUpkeepList{ + IsActiveFn: func(id *big.Int) bool { + return true + }, + }, + proposals: []types.CoordinatedBlockProposal{ + { + UpkeepID: core.GenUpkeepID(types.ConditionTrigger, "def"), + WorkID: "workID1", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + }, + }, + wantPayloads: []types.UpkeepPayload{ + { + UpkeepID: core.GenUpkeepID(types.ConditionTrigger, "def"), + WorkID: "58f2f231792448679a75bac6efc2af4ba731901f0cb93a44a366525751cbabfb", + Trigger: types.Trigger{ + BlockNumber: 1, + BlockHash: [32]byte{1}, + }, + CheckData: make([]byte, 0), + }, + }, + }, + } { + t.Run(tc.name, func(t *testing.T) { + lggr, _ := logger.NewLogger() + builder := NewPayloadBuilder(tc.activeList, tc.recoverer, lggr) + payloads, err := builder.BuildPayloads(context.Background(), tc.proposals...) + assert.NoError(t, err) + assert.Equal(t, tc.wantPayloads, payloads) + }) + } +} + +type mockLogRecoverer struct { + logprovider.LogRecoverer + GetProposalDataFn func(context.Context, types.CoordinatedBlockProposal) ([]byte, error) +} + +func (r *mockLogRecoverer) GetProposalData(ctx context.Context, p types.CoordinatedBlockProposal) ([]byte, error) { + return r.GetProposalDataFn(ctx, p) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 5548b22de07..908048ca2bc 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -5,7 +5,6 @@ import ( "fmt" "math/big" "net/http" - "strings" "sync" "time" @@ -15,23 +14,18 @@ import ( coreTypes "github.com/ethereum/go-ethereum/core/types" "github.com/pkg/errors" - "github.com/ethereum/go-ethereum/common/hexutil" - "github.com/ethereum/go-ethereum/rpc" "github.com/patrickmn/go-cache" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" - "go.uber.org/multierr" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" - "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/feed_lookup_compatible_interface" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/models" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/encoding" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" "github.com/smartcontractkit/chainlink/v2/core/services/pg" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -40,10 +34,8 @@ import ( const ( // defaultAllowListExpiration decides how long an upkeep's allow list info will be valid for. defaultAllowListExpiration = 20 * time.Minute - // cleanupInterval decides when the expired items in cache will be deleted. - cleanupInterval = 25 * time.Minute - // validCheckBlockRange decides the max distance between the check block and the current block - validCheckBlockRange = 128 + // allowListCleanupInterval decides when the expired items in allowList cache will be deleted. + allowListCleanupInterval = 5 * time.Minute ) var ( @@ -54,13 +46,15 @@ var ( ErrABINotParsable = fmt.Errorf("error parsing abi") ActiveUpkeepIDBatchSize int64 = 1000 FetchUpkeepConfigBatchSize = 10 - reInitializationDelay = 15 * time.Minute - logEventLookback int64 = 250 + // This is the interval at which active upkeep list is fully refreshed from chain + refreshInterval = 15 * time.Minute + // This is the lookback for polling upkeep state event logs from latest block + logEventLookback int64 = 250 ) //go:generate mockery --quiet --name Registry --output ./mocks/ --case=underscore type Registry interface { - GetUpkeep(opts *bind.CallOpts, id *big.Int) (UpkeepInfo, error) + GetUpkeep(opts *bind.CallOpts, id *big.Int) (encoding.UpkeepInfo, error) GetState(opts *bind.CallOpts) (iregistry21.GetState, error) GetActiveUpkeepIDs(opts *bind.CallOpts, startIndex *big.Int, maxCount *big.Int) ([]*big.Int, error) GetUpkeepPrivilegeConfig(opts *bind.CallOpts, upkeepId *big.Int) ([]byte, error) @@ -74,180 +68,85 @@ type HttpClient interface { Do(req *http.Request) (*http.Response, error) } -type LatestBlockGetter interface { - LatestBlock() int64 -} - -func NewEVMRegistryService(addr common.Address, client evm.Chain, mc *models.MercuryCredentials, bs *BlockSubscriber, lggr logger.Logger) (*EvmRegistry, *EVMAutomationEncoder21, error) { - feedLookupCompatibleABI, err := abi.JSON(strings.NewReader(feed_lookup_compatible_interface.FeedLookupCompatibleInterfaceABI)) - if err != nil { - return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) - } - keeperRegistryABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) - if err != nil { - return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) - } - utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) - if err != nil { - return nil, nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) - } - packer := NewEvmRegistryPackerV2_1(keeperRegistryABI, utilsABI) - logPacker := logprovider.NewLogEventsPacker(utilsABI) - - registry, err := iregistry21.NewIKeeperRegistryMaster(addr, client.Client()) - if err != nil { - return nil, nil, fmt.Errorf("%w: failed to create caller for address and backend", ErrInitializationFailure) - } - - filterStore := logprovider.NewUpkeepFilterStore() - logEventProvider := logprovider.New(lggr, client.LogPoller(), logPacker, filterStore, nil) - - r := &EvmRegistry{ - ht: client.HeadTracker(), - lggr: lggr.Named("EvmRegistry"), - poller: client.LogPoller(), - addr: addr, - client: client.Client(), - txHashes: make(map[string]bool), - registry: registry, - active: make(map[string]activeUpkeep), - abi: keeperRegistryABI, - packer: packer, - headFunc: func(ocr2keepers.BlockKey) {}, - chLog: make(chan logpoller.Log, 1000), +func NewEvmRegistry( + lggr logger.Logger, + addr common.Address, + client evm.Chain, + feedLookupCompatibleABI, keeperRegistryABI abi.ABI, + registry *iregistry21.IKeeperRegistryMaster, + mc *models.MercuryCredentials, + al ActiveUpkeepList, + logEventProvider logprovider.LogEventProvider, + packer encoding.Packer, + blockSub *BlockSubscriber, +) *EvmRegistry { + return &EvmRegistry{ + lggr: lggr.Named("EvmRegistry"), + poller: client.LogPoller(), + addr: addr, + client: client.Client(), + logProcessed: make(map[string]bool), + registry: registry, + abi: keeperRegistryABI, + active: al, + packer: packer, + headFunc: func(ocr2keepers.BlockKey) {}, + chLog: make(chan logpoller.Log, 1000), mercury: &MercuryConfig{ cred: mc, abi: feedLookupCompatibleABI, - allowListCache: cache.New(defaultAllowListExpiration, cleanupInterval), + allowListCache: cache.New(defaultAllowListExpiration, allowListCleanupInterval), }, hc: http.DefaultClient, - enc: EVMAutomationEncoder21{packer: packer}, logEventProvider: logEventProvider, - bs: bs, - } - - if err := r.registerEvents(client.ID().Uint64(), addr); err != nil { - return nil, nil, fmt.Errorf("logPoller error while registering automation events: %w", err) + bs: blockSub, } - - return r, &r.enc, nil } var upkeepStateEvents = []common.Hash{ iregistry21.IKeeperRegistryMasterUpkeepRegistered{}.Topic(), // adds new upkeep id to registry iregistry21.IKeeperRegistryMasterUpkeepReceived{}.Topic(), // adds new upkeep id to registry via migration - iregistry21.IKeeperRegistryMasterUpkeepGasLimitSet{}.Topic(), // unpauses an upkeep - iregistry21.IKeeperRegistryMasterUpkeepUnpaused{}.Topic(), // updates the gas limit for an upkeep + iregistry21.IKeeperRegistryMasterUpkeepUnpaused{}.Topic(), // unpauses an upkeep iregistry21.IKeeperRegistryMasterUpkeepPaused{}.Topic(), // pauses an upkeep + iregistry21.IKeeperRegistryMasterUpkeepMigrated{}.Topic(), // migrated an upkeep, equivalent to cancel from this registry's perspective iregistry21.IKeeperRegistryMasterUpkeepCanceled{}.Topic(), // cancels an upkeep iregistry21.IKeeperRegistryMasterUpkeepTriggerConfigSet{}.Topic(), // trigger config was changed } -var upkeepActiveEvents = []common.Hash{ - iregistry21.IKeeperRegistryMasterUpkeepPerformed{}.Topic(), - iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{}.Topic(), - iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{}.Topic(), - iregistry21.IKeeperRegistryMasterStaleUpkeepReport{}.Topic(), -} - -type checkResult struct { - cr []ocr2keepers.CheckResult - err error -} - -type activeUpkeep struct { - ID *big.Int - PerformGasLimit uint32 - CheckData []byte -} - type MercuryConfig struct { cred *models.MercuryCredentials abi abi.ABI - // allowListCache stores the admin address' privilege. in 2.1, this only includes a JSON bytes for allowed to use mercury + // allowListCache stores the upkeeps privileges. In 2.1, this only includes a JSON bytes for allowed to use mercury allowListCache *cache.Cache } type EvmRegistry struct { - ht types.HeadTracker sync utils.StartStopOnce lggr logger.Logger poller logpoller.LogPoller addr common.Address client client.Client + chainID uint64 registry Registry abi abi.ABI - packer *evmRegistryPackerV2_1 + packer encoding.Packer chLog chan logpoller.Log reInit *time.Timer mu sync.RWMutex - txHashes map[string]bool + logProcessed map[string]bool + active ActiveUpkeepList lastPollBlock int64 ctx context.Context cancel context.CancelFunc - active map[string]activeUpkeep headFunc func(ocr2keepers.BlockKey) runState int runError error mercury *MercuryConfig hc HttpClient - enc EVMAutomationEncoder21 bs *BlockSubscriber logEventProvider logprovider.LogEventProvider } -// GetActiveUpkeepIDs uses the latest head and map of all active upkeeps to build a -// slice of upkeep keys. -func (r *EvmRegistry) GetActiveUpkeepIDs(ctx context.Context) ([]ocr2keepers.UpkeepIdentifier, error) { - return r.GetActiveUpkeepIDsByType(ctx) -} - -// GetActiveUpkeepIDsByType returns all active upkeeps of the given trigger types. -func (r *EvmRegistry) GetActiveUpkeepIDsByType(ctx context.Context, triggers ...uint8) ([]ocr2keepers.UpkeepIdentifier, error) { - r.mu.RLock() - defer r.mu.RUnlock() - - keys := make([]ocr2keepers.UpkeepIdentifier, 0) - - for _, value := range r.active { - uid := &ocr2keepers.UpkeepIdentifier{} - uid.FromBigInt(value.ID) - if len(triggers) == 0 { - keys = append(keys, *uid) - continue - } - trigger := core.GetUpkeepType(*uid) - for _, t := range triggers { - if trigger == ocr2keepers.UpkeepType(t) { - keys = append(keys, *uid) - break - } - } - } - - return keys, nil -} - -func (r *EvmRegistry) CheckUpkeeps(ctx context.Context, keys ...ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { - r.lggr.Debugw("Checking upkeeps", "upkeeps", keys) - chResult := make(chan checkResult, 1) - go r.doCheck(ctx, keys, chResult) - - select { - case rs := <-chResult: - result := make([]ocr2keepers.CheckResult, len(rs.cr)) - copy(result, rs.cr) - return result, rs.err - case <-ctx.Done(): - // safety on context done to provide an error on context cancellation - // contract calls through the geth wrappers are a bit of a black box - // so this safety net ensures contexts are fully respected and contract - // call functions have a more graceful closure outside the scope of - // CheckUpkeep needing to return immediately. - return nil, fmt.Errorf("%w: failed to check upkeep on registry", ErrContextCancelled) - } -} - func (r *EvmRegistry) Name() string { return r.lggr.Name() } @@ -257,9 +156,13 @@ func (r *EvmRegistry) Start(ctx context.Context) error { r.mu.Lock() defer r.mu.Unlock() r.ctx, r.cancel = context.WithCancel(context.Background()) - r.reInit = time.NewTimer(reInitializationDelay) + r.reInit = time.NewTimer(refreshInterval) - // initialize the upkeep keys; if the reInit timer returns, do it again + if err := r.registerEvents(r.chainID, r.addr); err != nil { + return fmt.Errorf("logPoller error while registering automation events: %w", err) + } + + // refresh the active upkeep keys; if the reInit timer returns, do it again { go func(cx context.Context, tmr *time.Timer, lggr logger.Logger, f func() error) { err := f() @@ -274,12 +177,12 @@ func (r *EvmRegistry) Start(ctx context.Context) error { if err != nil { lggr.Errorf("failed to re-initialize upkeeps", err) } - tmr.Reset(reInitializationDelay) + tmr.Reset(refreshInterval) case <-cx.Done(): return } } - }(r.ctx, r.reInit, r.lggr, r.initialize) + }(r.ctx, r.reInit, r.lggr, r.refreshActiveUpkeeps) } // start polling logs on an interval @@ -298,7 +201,7 @@ func (r *EvmRegistry) Start(ctx context.Context) error { return } } - }(r.ctx, r.lggr, r.pollLogs) + }(r.ctx, r.lggr, r.pollUpkeepStateLogs) } // run process to process logs from log channel @@ -318,20 +221,6 @@ func (r *EvmRegistry) Start(ctx context.Context) error { }(r.ctx, r.chLog, r.lggr, r.processUpkeepStateLog) } - // Start log event provider - { - go func(ctx context.Context, lggr logger.Logger, f func(context.Context) error, c func() error) { - for ctx.Err() == nil { - if err := f(ctx); err != nil { - lggr.Errorf("failed to start log event provider", err) - } - if err := c(); err != nil { - lggr.Errorf("failed to close log event provider", err) - } - } - }(r.ctx, r.lggr, r.logEventProvider.Start, r.logEventProvider.Close) - } - r.runState = 1 return nil }) @@ -368,47 +257,22 @@ func (r *EvmRegistry) HealthReport() map[string]error { return map[string]error{r.Name(): r.sync.Healthy()} } -func (r *EvmRegistry) LogEventProvider() logprovider.LogEventProvider { - return r.logEventProvider -} - -func (r *EvmRegistry) initialize() error { - startupCtx, cancel := context.WithTimeout(r.ctx, reInitializationDelay) +func (r *EvmRegistry) refreshActiveUpkeeps() error { + // Allow for max timeout of refreshInterval + ctx, cancel := context.WithTimeout(r.ctx, refreshInterval) defer cancel() - idMap := make(map[string]activeUpkeep) - - r.lggr.Debugf("Re-initializing active upkeeps list") + r.lggr.Debugf("Refreshing active upkeeps list") // get active upkeep ids from contract - ids, err := r.getLatestIDsFromContract(startupCtx) + ids, err := r.getLatestIDsFromContract(ctx) if err != nil { - return fmt.Errorf("failed to get ids from contract: %s", err) + return fmt.Errorf("failed to get active upkeep ids from contract during refresh: %s", err) } + r.active.Reset(ids...) - var offset int - for offset < len(ids) { - batch := FetchUpkeepConfigBatchSize - if len(ids)-offset < batch { - batch = len(ids) - offset - } - - actives, err := r.getUpkeepConfigs(startupCtx, ids[offset:offset+batch]) - if err != nil { - return fmt.Errorf("failed to get configs for id batch (length '%d'): %s", batch, err) - } - - for _, active := range actives { - idMap[active.ID.String()] = active - } - - offset += batch - } - - r.mu.Lock() - r.active = idMap - r.mu.Unlock() - - // register upkeep ids for log triggers + // refresh trigger config log upkeeps + // Note: We only update the trigger config for current active upkeeps and do not remove configs + // for any upkeeps that might have been removed. We depend upon state events to remove the configs for _, id := range ids { uid := &ocr2keepers.UpkeepIdentifier{} uid.FromBigInt(id) @@ -424,7 +288,7 @@ func (r *EvmRegistry) initialize() error { return nil } -func (r *EvmRegistry) pollLogs() error { +func (r *EvmRegistry) pollUpkeepStateLogs() error { var latest int64 var end int64 var err error @@ -443,47 +307,34 @@ func (r *EvmRegistry) pollLogs() error { return nil } - { - var logs []logpoller.Log - - if logs, err = r.poller.LogsWithSigs( - end-logEventLookback, - end, - upkeepStateEvents, - r.addr, - pg.WithParentCtx(r.ctx), - ); err != nil { - return fmt.Errorf("%w: %s", ErrLogReadFailure, err) - } + var logs []logpoller.Log + if logs, err = r.poller.LogsWithSigs( + end-logEventLookback, + end, + upkeepStateEvents, + r.addr, + pg.WithParentCtx(r.ctx), + ); err != nil { + return fmt.Errorf("%w: %s", ErrLogReadFailure, err) + } - for _, log := range logs { - r.chLog <- log - } + for _, log := range logs { + r.chLog <- log } return nil } -func UpkeepFilterName(addr common.Address) string { - return logpoller.FilterName("KeeperRegistry Events", addr.String()) -} - -func (r *EvmRegistry) registerEvents(chainID uint64, addr common.Address) error { - // Add log filters for the log poller so that it can poll and find the logs that - // we need - return r.poller.RegisterFilter(logpoller.Filter{ - Name: UpkeepFilterName(addr), - EventSigs: append(upkeepStateEvents, upkeepActiveEvents...), - Addresses: []common.Address{addr}, - }) -} - func (r *EvmRegistry) processUpkeepStateLog(l logpoller.Log) error { - hash := l.TxHash.String() - if _, ok := r.txHashes[hash]; ok { + lid := fmt.Sprintf("%s%d", l.TxHash.String(), l.LogIndex) + r.mu.Lock() + if _, ok := r.logProcessed[lid]; ok { + r.mu.Unlock() return nil } - r.txHashes[hash] = true + r.logProcessed[lid] = true + r.mu.Unlock() + txHash := l.TxHash.String() rawLog := l.ToGethLog() abilog, err := r.registry.ParseLog(rawLog) @@ -493,50 +344,64 @@ func (r *EvmRegistry) processUpkeepStateLog(l logpoller.Log) error { switch l := abilog.(type) { case *iregistry21.IKeeperRegistryMasterUpkeepPaused: - r.lggr.Debugf("KeeperRegistryUpkeepPaused log detected for upkeep ID %s in transaction %s", l.Id.String(), hash) + r.lggr.Debugf("KeeperRegistryUpkeepPaused log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) r.removeFromActive(l.Id) case *iregistry21.IKeeperRegistryMasterUpkeepCanceled: - r.lggr.Debugf("KeeperRegistryUpkeepCanceled log detected for upkeep ID %s in transaction %s", l.Id.String(), hash) + r.lggr.Debugf("KeeperRegistryUpkeepCanceled log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) + r.removeFromActive(l.Id) + case *iregistry21.IKeeperRegistryMasterUpkeepMigrated: + r.lggr.Debugf("KeeperRegistryMasterUpkeepMigrated log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) r.removeFromActive(l.Id) case *iregistry21.IKeeperRegistryMasterUpkeepTriggerConfigSet: - r.lggr.Debugf("KeeperRegistryUpkeepTriggerConfigSet log detected for upkeep ID %s in transaction %s", l.Id.String(), hash) - // passing nil instead of l.TriggerConfig to protect against reorgs, - // as we'll fetch the latest config from the contract - if err := r.updateTriggerConfig(l.Id, nil); err != nil { - r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", l.Id.String(), err) + r.lggr.Debugf("KeeperRegistryUpkeepTriggerConfigSet log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) + if err := r.updateTriggerConfig(l.Id, l.TriggerConfig); err != nil { + r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepTriggerConfigSet for upkeep ID %s: %s", l.Id.String(), err) } case *iregistry21.IKeeperRegistryMasterUpkeepRegistered: uid := &ocr2keepers.UpkeepIdentifier{} uid.FromBigInt(l.Id) trigger := core.GetUpkeepType(*uid) - r.lggr.Debugf("KeeperRegistryUpkeepRegistered log detected for upkeep ID %s (trigger=%d) in transaction %s", l.Id.String(), trigger, hash) - r.addToActive(l.Id, false) + r.lggr.Debugf("KeeperRegistryUpkeepRegistered log detected for upkeep ID %s (trigger=%d) in transaction %s", l.Id.String(), trigger, txHash) + r.active.Add(l.Id) if err := r.updateTriggerConfig(l.Id, nil); err != nil { - r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", err) + r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepRegistered for upkeep ID %s: %s", err) } case *iregistry21.IKeeperRegistryMasterUpkeepReceived: - r.lggr.Debugf("KeeperRegistryUpkeepReceived log detected for upkeep ID %s in transaction %s", l.Id.String(), hash) - r.addToActive(l.Id, false) + r.lggr.Debugf("KeeperRegistryUpkeepReceived log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) + r.active.Add(l.Id) + if err := r.updateTriggerConfig(l.Id, nil); err != nil { + r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepReceived for upkeep ID %s: %s", err) + } case *iregistry21.IKeeperRegistryMasterUpkeepUnpaused: - r.lggr.Debugf("KeeperRegistryUpkeepUnpaused log detected for upkeep ID %s in transaction %s", l.Id.String(), hash) - r.addToActive(l.Id, false) + r.lggr.Debugf("KeeperRegistryUpkeepUnpaused log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) + r.active.Add(l.Id) if err := r.updateTriggerConfig(l.Id, nil); err != nil { - r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", err) + r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepUnpaused for upkeep ID %s: %s", err) } - case *iregistry21.IKeeperRegistryMasterUpkeepGasLimitSet: - r.lggr.Debugf("KeeperRegistryUpkeepGasLimitSet log detected for upkeep ID %s in transaction %s", l.Id.String(), hash) - r.addToActive(l.Id, true) default: - r.lggr.Debugf("Unknown log detected for log %+v in transaction %s", l, hash) + r.lggr.Debugf("Unknown log detected for log %+v in transaction %s", l, txHash) } return nil } +func RegistryUpkeepFilterName(addr common.Address) string { + return logpoller.FilterName("KeeperRegistry Events", addr.String()) +} + +func (r *EvmRegistry) registerEvents(chainID uint64, addr common.Address) error { + // Add log filters for the log poller so that it can poll and find the logs that + // we need + return r.poller.RegisterFilter(logpoller.Filter{ + Name: RegistryUpkeepFilterName(addr), + EventSigs: upkeepStateEvents, + Addresses: []common.Address{addr}, + }) +} + +// Removes an upkeepID from active list and unregisters the log filter for log upkeeps func (r *EvmRegistry) removeFromActive(id *big.Int) { - r.mu.Lock() - delete(r.active, id.String()) - r.mu.Unlock() + r.active.Remove(id) uid := &ocr2keepers.UpkeepIdentifier{} uid.FromBigInt(id) @@ -551,38 +416,15 @@ func (r *EvmRegistry) removeFromActive(id *big.Int) { } } -func (r *EvmRegistry) addToActive(id *big.Int, force bool) { - r.mu.Lock() - defer r.mu.Unlock() - - if r.active == nil { - r.active = make(map[string]activeUpkeep) - } - - if _, ok := r.active[id.String()]; !ok || force { - actives, err := r.getUpkeepConfigs(r.ctx, []*big.Int{id}) - if err != nil { - r.lggr.Warnf("failed to get upkeep configs during adding active upkeep: %w", err) - return - } - - if len(actives) != 1 { - return - } - - r.active[id.String()] = actives[0] - } -} - func (r *EvmRegistry) buildCallOpts(ctx context.Context, block *big.Int) *bind.CallOpts { opts := bind.CallOpts{ Context: ctx, } if block == nil || block.Int64() == 0 { - l := r.ht.LatestChain() - if l != nil && l.BlockNumber() != 0 { - opts.BlockNumber = big.NewInt(l.BlockNumber()) + l := r.bs.latestBlock.Load() + if l != nil && l.Number != 0 { + opts.BlockNumber = big.NewInt(int64(l.Number)) } } else { opts.BlockNumber = block @@ -628,277 +470,6 @@ func (r *EvmRegistry) getLatestIDsFromContract(ctx context.Context) ([]*big.Int, return ids, nil } -func (r *EvmRegistry) doCheck(ctx context.Context, keys []ocr2keepers.UpkeepPayload, chResult chan checkResult) { - upkeepResults, err := r.checkUpkeeps(ctx, keys) - if err != nil { - chResult <- checkResult{ - err: err, - } - return - } - - upkeepResults = r.feedLookup(ctx, upkeepResults) - - upkeepResults, err = r.simulatePerformUpkeeps(ctx, upkeepResults) - if err != nil { - chResult <- checkResult{ - err: err, - } - return - } - - chResult <- checkResult{ - cr: upkeepResults, - } -} - -// getBlockAndUpkeepId retrieves check block number, block hash from trigger and upkeep id -func (r *EvmRegistry) getBlockAndUpkeepId(upkeepID ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) (*big.Int, common.Hash, *big.Int) { - block := new(big.Int).SetInt64(int64(trigger.BlockNumber)) - return block, common.BytesToHash(trigger.BlockHash[:]), upkeepID.BigInt() -} - -func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { - var ( - checkReqs []rpc.BatchElem - checkResults []*string - results = make([]ocr2keepers.CheckResult, len(payloads)) - ) - indices := map[int]int{} - - for i, p := range payloads { - block, checkHash, upkeepId := r.getBlockAndUpkeepId(p.UpkeepID, p.Trigger) - state, retryable := r.verifyCheckBlock(ctx, block, upkeepId, checkHash) - if state != NoPipelineError { - results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, state, retryable) - continue - } - - opts := r.buildCallOpts(ctx, block) - var payload []byte - var err error - uid := &ocr2keepers.UpkeepIdentifier{} - uid.FromBigInt(upkeepId) - switch core.GetUpkeepType(*uid) { - case ocr2keepers.LogTrigger: - reason, state, retryable := r.verifyLogExists(upkeepId, p) - if reason != UpkeepFailureReasonNone || state != NoPipelineError { - results[i] = getIneligibleCheckResultWithoutPerformData(p, reason, state, retryable) - continue - } - - // check data will include the log trigger config - payload, err = r.abi.Pack("checkUpkeep", upkeepId, p.CheckData) - if err != nil { - // pack error, no retryable - r.lggr.Warnf("failed to pack log trigger checkUpkeep data for upkeepId %s with check data %s: %s", upkeepId, hexutil.Encode(p.CheckData), err) - results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false) - continue - } - default: - // checkUpkeep is overloaded on the contract for conditionals and log upkeeps - // Need to use the first function (checkUpkeep0) for conditionals - payload, err = r.abi.Pack("checkUpkeep0", upkeepId) - if err != nil { - // pack error, no retryable - r.lggr.Warnf("failed to pack conditional checkUpkeep data for upkeepId %s with check data %s: %s", upkeepId, hexutil.Encode(p.CheckData), err) - results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, PackUnpackDecodeFailed, false) - continue - } - } - indices[len(checkReqs)] = i - results[i] = getIneligibleCheckResultWithoutPerformData(p, UpkeepFailureReasonNone, NoPipelineError, false) - - var result string - checkReqs = append(checkReqs, rpc.BatchElem{ - Method: "eth_call", - Args: []interface{}{ - map[string]interface{}{ - "to": r.addr.Hex(), - "data": hexutil.Bytes(payload), - }, - hexutil.EncodeBig(opts.BlockNumber), - }, - Result: &result, - }) - - checkResults = append(checkResults, &result) - } - - if len(checkResults) > 0 { - // In contrast to CallContext, BatchCallContext only returns errors that have occurred - // while sending the request. Any error specific to a request is reported through the - // Error field of the corresponding BatchElem. - // hence, if BatchCallContext returns an error, it will be an error which will terminate the pipeline - if err := r.client.BatchCallContext(ctx, checkReqs); err != nil { - r.lggr.Errorf("failed to batch call for checkUpkeeps: %s", err) - return nil, err - } - } - - for i, req := range checkReqs { - index := indices[i] - if req.Error != nil { - // individual upkeep failed in a batch call, retryable - r.lggr.Warnf("error encountered in check result for upkeepId %s: %s", results[index].UpkeepID.String(), req.Error) - results[index].Retryable = true - results[index].PipelineExecutionState = uint8(RpcFlakyFailure) - } else { - var err error - results[index], err = r.packer.UnpackCheckResult(payloads[index], *checkResults[i]) - if err != nil { - r.lggr.Warnf("failed to unpack check result: %s", err) - } - } - } - - return results, nil -} - -func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults []ocr2keepers.CheckResult) ([]ocr2keepers.CheckResult, error) { - var ( - performReqs = make([]rpc.BatchElem, 0, len(checkResults)) - performResults = make([]*string, 0, len(checkResults)) - performToKeyIdx = make([]int, 0, len(checkResults)) - ) - - for i, cr := range checkResults { - if !cr.Eligible { - continue - } - - block, _, upkeepId := r.getBlockAndUpkeepId(cr.UpkeepID, cr.Trigger) - - opts := r.buildCallOpts(ctx, block) - - // Since checkUpkeep is true, simulate perform upkeep to ensure it doesn't revert - payload, err := r.abi.Pack("simulatePerformUpkeep", upkeepId, cr.PerformData) - if err != nil { - // pack failed, not retryable - r.lggr.Warnf("failed to pack perform data %s for %s: %s", hexutil.Encode(cr.PerformData), upkeepId, err) - checkResults[i].Eligible = false - checkResults[i].PipelineExecutionState = uint8(PackUnpackDecodeFailed) - continue - } - - var result string - performReqs = append(performReqs, rpc.BatchElem{ - Method: "eth_call", - Args: []interface{}{ - map[string]interface{}{ - "to": r.addr.Hex(), - "data": hexutil.Bytes(payload), - }, - hexutil.EncodeBig(opts.BlockNumber), - }, - Result: &result, - }) - - performResults = append(performResults, &result) - performToKeyIdx = append(performToKeyIdx, i) - } - - if len(performReqs) > 0 { - if err := r.client.BatchCallContext(ctx, performReqs); err != nil { - r.lggr.Errorf("failed to batch call for simulatePerformUpkeeps: %s", err) - return nil, err - } - } - - for i, req := range performReqs { - idx := performToKeyIdx[i] - if req.Error != nil { - // individual upkeep failed in a batch call, retryable - r.lggr.Warnf("failed to simulate upkeepId %s: %s", checkResults[idx].UpkeepID.String(), req.Error) - checkResults[idx].Retryable = true - checkResults[idx].Eligible = false - checkResults[idx].PipelineExecutionState = uint8(RpcFlakyFailure) - continue - } - - state, simulatePerformSuccess, err := r.packer.UnpackPerformResult(*performResults[i]) - if err != nil { - // unpack failed, not retryable - r.lggr.Warnf("failed to unpack simulate performUpkeep result for upkeepId %s for state %d: %s", checkResults[idx].UpkeepID.String(), state, req.Error) - checkResults[idx].Retryable = false - checkResults[idx].Eligible = false - checkResults[idx].PipelineExecutionState = uint8(state) - continue - } - - if !simulatePerformSuccess { - r.lggr.Warnf("upkeepId %s is not eligible after simulation", checkResults[idx].UpkeepID.String()) - checkResults[performToKeyIdx[i]].Eligible = false - } - } - - return checkResults, nil -} - -// TODO (AUTO-2013): Have better error handling to not return nil results in case of partial errors -func (r *EvmRegistry) getUpkeepConfigs(ctx context.Context, ids []*big.Int) ([]activeUpkeep, error) { - if len(ids) == 0 { - return []activeUpkeep{}, nil - } - - var ( - uReqs = make([]rpc.BatchElem, len(ids)) - uResults = make([]*string, len(ids)) - ) - - for i, id := range ids { - opts := r.buildCallOpts(ctx, nil) - - payload, err := r.abi.Pack("getUpkeep", id) - if err != nil { - return nil, fmt.Errorf("failed to pack id with abi: %s", err) - } - - var result string - uReqs[i] = rpc.BatchElem{ - Method: "eth_call", - Args: []interface{}{ - map[string]interface{}{ - "to": r.addr.Hex(), - "data": hexutil.Bytes(payload), - }, - hexutil.EncodeBig(opts.BlockNumber), - }, - Result: &result, - } - - uResults[i] = &result - } - - if err := r.client.BatchCallContext(ctx, uReqs); err != nil { - return nil, fmt.Errorf("rpc error: %s", err) - } - - var ( - multiErr error - results = make([]activeUpkeep, len(ids)) - ) - - for i, req := range uReqs { - if req.Error != nil { - r.lggr.Debugf("error encountered for config id %s with message '%s' in get config", ids[i], req.Error) - multierr.AppendInto(&multiErr, req.Error) - } else { - info, err := r.packer.UnpackUpkeepInfo(ids[i], *uResults[i]) - if err != nil { - return nil, fmt.Errorf("failed to unpack result: %s", err) - } - results[i] = activeUpkeep{ // TODO - ID: ids[i], - PerformGasLimit: info.PerformGas, - CheckData: info.CheckData, - } - } - } - - return results, multiErr -} - func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { uid := &ocr2keepers.UpkeepIdentifier{} uid.FromBigInt(id) @@ -934,101 +505,3 @@ func (r *EvmRegistry) fetchTriggerConfig(id *big.Int) ([]byte, error) { } return cfg, nil } - -func (r *EvmRegistry) getBlockHash(blockNumber *big.Int) (common.Hash, error) { - blocks, err := r.poller.GetBlocksRange(r.ctx, []uint64{blockNumber.Uint64()}) - if err != nil { - return [32]byte{}, err - } - if len(blocks) == 0 { - return [32]byte{}, fmt.Errorf("could not find block %d in log poller", blockNumber.Uint64()) - } - - return blocks[0].BlockHash, nil -} - -func (r *EvmRegistry) getTxBlock(txHash common.Hash) (*big.Int, common.Hash, error) { - // TODO: we need to differentiate here b/w flaky errors and tx not found errors - txr, err := r.client.TransactionReceipt(r.ctx, txHash) - if err != nil { - return nil, common.Hash{}, err - } - - return txr.BlockNumber, txr.BlockHash, nil -} - -// getIneligibleCheckResultWithoutPerformData returns an ineligible check result with ineligibility reason and pipeline execution state but without perform data -func getIneligibleCheckResultWithoutPerformData(p ocr2keepers.UpkeepPayload, reason UpkeepFailureReason, state PipelineExecutionState, retryable bool) ocr2keepers.CheckResult { - return ocr2keepers.CheckResult{ - IneligibilityReason: uint8(reason), - PipelineExecutionState: uint8(state), - Retryable: retryable, - UpkeepID: p.UpkeepID, - Trigger: p.Trigger, - WorkID: p.WorkID, - FastGasWei: big.NewInt(0), - LinkNative: big.NewInt(0), - } -} - -// verifyCheckBlock checks that the check block and hash are valid, returns the pipeline execution state and retryable -func (r *EvmRegistry) verifyCheckBlock(ctx context.Context, checkBlock, upkeepId *big.Int, checkHash common.Hash) (state PipelineExecutionState, retryable bool) { - // verify check block number is not too old - if r.bs.latestBlock.Load()-checkBlock.Int64() > validCheckBlockRange { - r.lggr.Warnf("latest block is %d, check block number %s is too old for upkeepId %s", r.bs.latestBlock.Load(), checkBlock, upkeepId) - return CheckBlockTooOld, false - } - r.lggr.Warnf("latestBlock=%d checkBlock=%d", r.bs.latestBlock.Load(), checkBlock.Int64()) - - var h string - var ok bool - // verify check block number and hash are valid - h, ok = r.bs.queryBlocksMap(checkBlock.Int64()) - if !ok { - r.lggr.Warnf("check block %s does not exist in block subscriber for upkeepId %s, querying eth client", checkBlock, upkeepId) - hash, err := r.getBlockHash(checkBlock) - if err != nil { - r.lggr.Warnf("failed to query block %s: %s", checkBlock, err.Error()) - return RpcFlakyFailure, true - } - h = hash.Hex() - } - if checkHash.Hex() != h { - r.lggr.Warnf("check block %s hash do not match. %s from block subscriber vs %s from trigger for upkeepId %s", checkBlock, h, checkHash.Hex(), upkeepId) - return CheckBlockInvalid, false - } - return NoPipelineError, false -} - -// verifyLogExists checks that the log still exists on chain, returns failure reason, pipeline error, and retryable -func (r *EvmRegistry) verifyLogExists(upkeepId *big.Int, p ocr2keepers.UpkeepPayload) (UpkeepFailureReason, PipelineExecutionState, bool) { - logBlockNumber := int64(p.Trigger.LogTriggerExtension.BlockNumber) - logBlockHash := common.BytesToHash(p.Trigger.LogTriggerExtension.BlockHash[:]) - // if log block number is populated, check log block number and block hash - if logBlockNumber != 0 { - h, ok := r.bs.queryBlocksMap(logBlockNumber) - if ok && h == logBlockHash.Hex() { - r.lggr.Debugf("tx hash %s exists on chain at block number %d for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), logBlockNumber, upkeepId) - return UpkeepFailureReasonNone, NoPipelineError, false - } - r.lggr.Debugf("log block %d does not exist in block subscriber for upkeepId %s, querying eth client", logBlockNumber, upkeepId) - } else { - r.lggr.Debugf("log block not provided, querying eth client for tx hash %s for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) - } - // query eth client as a fallback - bn, _, err := r.getTxBlock(p.Trigger.LogTriggerExtension.TxHash) - if err != nil { - // primitive way of checking errors - if strings.Contains(err.Error(), "missing required field") || strings.Contains(err.Error(), "not found") { - return UpkeepFailureReasonTxHashNoLongerExists, NoPipelineError, false - } - r.lggr.Warnf("failed to query tx hash %s for upkeepId %s: %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId, err.Error()) - return UpkeepFailureReasonNone, RpcFlakyFailure, true - } - if bn == nil { - r.lggr.Warnf("tx hash %s does not exist on chain for upkeepId %s.", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) - return UpkeepFailureReasonLogBlockNoLongerExists, NoPipelineError, false - } - r.lggr.Debugf("tx hash %s exists on chain for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) - return UpkeepFailureReasonNone, NoPipelineError, false -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_check_pipeline_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_check_pipeline_test.go new file mode 100644 index 00000000000..88016f07f15 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_check_pipeline_test.go @@ -0,0 +1,603 @@ +package evm + +import ( + "context" + "fmt" + "math/big" + "sync/atomic" + "testing" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/rpc" + + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/mock" + + evmClientMocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/encoding" + "github.com/smartcontractkit/chainlink/v2/core/services/pg" +) + +func TestRegistry_GetBlockAndUpkeepId(t *testing.T) { + r := &EvmRegistry{} + tests := []struct { + name string + input ocr2keepers.UpkeepPayload + wantBlock *big.Int + wantUpkeep *big.Int + }{ + { + "happy flow", + ocr2keepers.UpkeepPayload{ + UpkeepID: core.UpkeepIDFromInt("10"), + Trigger: ocr2keepers.Trigger{ + BlockNumber: 1, + BlockHash: common.HexToHash("0x1"), + }, + }, + big.NewInt(1), + big.NewInt(10), + }, + { + "empty trigger", + ocr2keepers.UpkeepPayload{ + UpkeepID: core.UpkeepIDFromInt("10"), + }, + big.NewInt(0), + big.NewInt(10), + }, + { + "empty payload", + ocr2keepers.UpkeepPayload{}, + big.NewInt(0), + big.NewInt(0), + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + block, _, upkeep := r.getBlockAndUpkeepId(tc.input.UpkeepID, tc.input.Trigger) + assert.Equal(t, tc.wantBlock, block) + assert.Equal(t, tc.wantUpkeep.String(), upkeep.String()) + }) + } +} + +func TestRegistry_VerifyCheckBlock(t *testing.T) { + lggr := logger.TestLogger(t) + upkeepId := ocr2keepers.UpkeepIdentifier{} + upkeepId.FromBigInt(big.NewInt(12345)) + tests := []struct { + name string + checkBlock *big.Int + latestBlock ocr2keepers.BlockKey + upkeepId *big.Int + checkHash common.Hash + payload ocr2keepers.UpkeepPayload + blocks map[int64]string + poller logpoller.LogPoller + state encoding.PipelineExecutionState + retryable bool + makeEthCall bool + }{ + { + name: "check block number too told", + checkBlock: big.NewInt(500), + latestBlock: ocr2keepers.BlockKey{Number: 800}, + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + state: encoding.CheckBlockTooOld, + }, + { + name: "for an invalid check block number, if hash does not match the check hash, return CheckBlockInvalid", + checkBlock: big.NewInt(500), + latestBlock: ocr2keepers.BlockKey{Number: 560}, + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + poller: &mockLogPoller{ + GetBlocksRangeFn: func(ctx context.Context, numbers []uint64, qopts ...pg.QOpt) ([]logpoller.LogPollerBlock, error) { + return []logpoller.LogPollerBlock{ + { + BlockHash: common.HexToHash("abcdef"), + }, + }, nil + }, + }, + state: encoding.CheckBlockInvalid, + retryable: false, + makeEthCall: true, + }, + { + name: "for an invalid check block number, if hash does match the check hash, return NoPipelineError", + checkBlock: big.NewInt(500), + latestBlock: ocr2keepers.BlockKey{Number: 560}, + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + poller: &mockLogPoller{ + GetBlocksRangeFn: func(ctx context.Context, numbers []uint64, qopts ...pg.QOpt) ([]logpoller.LogPollerBlock, error) { + return []logpoller.LogPollerBlock{ + { + BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + }, + }, nil + }, + }, + state: encoding.NoPipelineError, + retryable: false, + makeEthCall: true, + }, + { + name: "check block hash does not match", + checkBlock: big.NewInt(500), + latestBlock: ocr2keepers.BlockKey{Number: 560}, + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + blocks: map[int64]string{ + 500: "0xa518faeadcc423338c62572da84dda35fe44b34f521ce88f6081b703b250cca4", + }, + state: encoding.CheckBlockInvalid, + }, + { + name: "check block is valid", + checkBlock: big.NewInt(500), + latestBlock: ocr2keepers.BlockKey{Number: 560}, + upkeepId: big.NewInt(12345), + checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), + WorkID: "work", + }, + blocks: map[int64]string{ + 500: "0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83", + }, + state: encoding.NoPipelineError, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + bs := &BlockSubscriber{ + latestBlock: atomic.Pointer[ocr2keepers.BlockKey]{}, + blocks: tc.blocks, + } + bs.latestBlock.Store(&tc.latestBlock) + e := &EvmRegistry{ + lggr: lggr, + bs: bs, + poller: tc.poller, + } + if tc.makeEthCall { + client := new(evmClientMocks.Client) + client.On("BlockByNumber", mock.Anything, tc.checkBlock).Return(nil, fmt.Errorf("error")) + e.client = client + } + + state, retryable := e.verifyCheckBlock(context.Background(), tc.checkBlock, tc.upkeepId, tc.checkHash) + assert.Equal(t, tc.state, state) + assert.Equal(t, tc.retryable, retryable) + }) + } +} + +type mockLogPoller struct { + logpoller.LogPoller + GetBlocksRangeFn func(ctx context.Context, numbers []uint64, qopts ...pg.QOpt) ([]logpoller.LogPollerBlock, error) +} + +func (p *mockLogPoller) GetBlocksRange(ctx context.Context, numbers []uint64, qopts ...pg.QOpt) ([]logpoller.LogPollerBlock, error) { + return p.GetBlocksRangeFn(ctx, numbers, qopts...) +} + +func TestRegistry_VerifyLogExists(t *testing.T) { + lggr := logger.TestLogger(t) + upkeepId := ocr2keepers.UpkeepIdentifier{} + upkeepId.FromBigInt(big.NewInt(12345)) + + extension := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71"), + BlockNumber: 500, + } + extension1 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71"), + BlockNumber: 0, + } + + tests := []struct { + name string + upkeepId *big.Int + payload ocr2keepers.UpkeepPayload + blocks map[int64]string + makeEthCall bool + reason encoding.UpkeepFailureReason + state encoding.PipelineExecutionState + retryable bool + ethCallErr error + receipt *types.Receipt + }{ + { + name: "log block number invalid", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), + WorkID: "work", + }, + reason: encoding.UpkeepFailureReasonNone, + state: encoding.RpcFlakyFailure, + retryable: true, + makeEthCall: true, + ethCallErr: fmt.Errorf("error"), + }, + { + name: "log block no longer exists", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), + WorkID: "work", + }, + reason: encoding.UpkeepFailureReasonTxHashNoLongerExists, + retryable: false, + makeEthCall: true, + blocks: map[int64]string{ + 500: "0xb2173b4b75f23f56b7b2b6b2cc5fa9ed1079b9d1655b12b40fdb4dbf59006419", + }, + receipt: &types.Receipt{}, + }, + { + name: "eth client returns a matching block", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension1), + WorkID: "work", + }, + reason: encoding.UpkeepFailureReasonNone, + retryable: false, + blocks: map[int64]string{ + 500: "0xa518faeadcc423338c62572da84dda35fe44b34f521ce88f6081b703b250cca4", + }, + makeEthCall: true, + receipt: &types.Receipt{ + BlockNumber: big.NewInt(550), + BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + }, + }, + { + name: "log block is valid", + upkeepId: big.NewInt(12345), + payload: ocr2keepers.UpkeepPayload{ + UpkeepID: upkeepId, + Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), + WorkID: "work", + }, + reason: encoding.UpkeepFailureReasonNone, + retryable: false, + blocks: map[int64]string{ + 500: "0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71", + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + bs := &BlockSubscriber{ + blocks: tc.blocks, + } + e := &EvmRegistry{ + lggr: lggr, + bs: bs, + ctx: context.Background(), + } + + if tc.makeEthCall { + client := new(evmClientMocks.Client) + client.On("TransactionReceipt", mock.Anything, common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651")). + Return(tc.receipt, tc.ethCallErr) + e.client = client + } + + reason, state, retryable := e.verifyLogExists(tc.upkeepId, tc.payload) + assert.Equal(t, tc.reason, reason) + assert.Equal(t, tc.state, state) + assert.Equal(t, tc.retryable, retryable) + }) + } +} + +func TestRegistry_CheckUpkeeps(t *testing.T) { + lggr := logger.TestLogger(t) + uid0 := core.GenUpkeepID(ocr2keepers.UpkeepType(0), "p0") + uid1 := core.GenUpkeepID(ocr2keepers.UpkeepType(1), "p1") + uid2 := core.GenUpkeepID(ocr2keepers.UpkeepType(1), "p2") + + extension1 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x0919c83363b439ea634ce2b576cf3e30db26b340fb7a12058c2fcc401bd04ba0"), + BlockNumber: 550, + } + extension2 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), + BlockNumber: 550, + } + + trigger0 := ocr2keepers.NewTrigger(150, common.HexToHash("0x1c77db0abe32327cf3ea9de2aadf79876f9e6b6dfcee9d4719a8a2dc8ca289d0")) + trigger1 := ocr2keepers.NewLogTrigger(560, common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), extension1) + trigger2 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension2) + + tests := []struct { + name string + inputs []ocr2keepers.UpkeepPayload + blocks map[int64]string + latestBlock ocr2keepers.BlockKey + results []ocr2keepers.CheckResult + err error + ethCalls map[string]bool + receipts map[string]*types.Receipt + ethCallErrors map[string]error + }{ + { + name: "check upkeeps with different upkeep types", + inputs: []ocr2keepers.UpkeepPayload{ + { + UpkeepID: uid0, + Trigger: trigger0, + WorkID: "work0", + }, + { + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + }, + { + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + // check data byte slice length cannot be odd number, abi pack error + CheckData: []byte{0, 0, 0, 0, 1}, + }, + }, + blocks: map[int64]string{ + 550: "0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857", + 560: "0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857", + 570: "0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc", + }, + latestBlock: ocr2keepers.BlockKey{Number: 580}, + results: []ocr2keepers.CheckResult{ + { + PipelineExecutionState: uint8(encoding.CheckBlockTooOld), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid0, + Trigger: trigger0, + WorkID: "work0", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + }, + { + PipelineExecutionState: uint8(encoding.RpcFlakyFailure), + Retryable: true, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + }, + { + PipelineExecutionState: uint8(encoding.PackUnpackDecodeFailed), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + }, + }, + ethCalls: map[string]bool{ + uid1.String(): true, + }, + receipts: map[string]*types.Receipt{ + //uid1.String(): { + // BlockNumber: big.NewInt(550), + // BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), + //}, + }, + ethCallErrors: map[string]error{ + uid1.String(): fmt.Errorf("error"), + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + bs := &BlockSubscriber{ + latestBlock: atomic.Pointer[ocr2keepers.BlockKey]{}, + blocks: tc.blocks, + } + bs.latestBlock.Store(&tc.latestBlock) + e := &EvmRegistry{ + lggr: lggr, + bs: bs, + } + client := new(evmClientMocks.Client) + for _, i := range tc.inputs { + uid := i.UpkeepID.String() + if tc.ethCalls[uid] { + client.On("TransactionReceipt", mock.Anything, common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651")). + Return(tc.receipts[uid], tc.ethCallErrors[uid]) + } + } + e.client = client + + results, err := e.checkUpkeeps(context.Background(), tc.inputs) + assert.Equal(t, tc.results, results) + assert.Equal(t, tc.err, err) + }) + } +} + +func TestRegistry_SimulatePerformUpkeeps(t *testing.T) { + uid0 := core.GenUpkeepID(ocr2keepers.UpkeepType(0), "p0") + uid1 := core.GenUpkeepID(ocr2keepers.UpkeepType(1), "p1") + uid2 := core.GenUpkeepID(ocr2keepers.UpkeepType(1), "p2") + + extension1 := &ocr2keepers.LogTriggerExtension{ + TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), + Index: 0, + BlockHash: common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), + BlockNumber: 550, + } + + trigger0 := ocr2keepers.NewTrigger(150, common.HexToHash("0x1c77db0abe32327cf3ea9de2aadf79876f9e6b6dfcee9d4719a8a2dc8ca289d0")) + trigger1 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension1) + trigger2 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension1) + + cr0 := ocr2keepers.CheckResult{ + PipelineExecutionState: uint8(encoding.CheckBlockTooOld), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid0, + Trigger: trigger0, + WorkID: "work0", + GasAllocated: 0, + PerformData: nil, + FastGasWei: big.NewInt(0), + LinkNative: big.NewInt(0), + } + + tests := []struct { + name string + inputs []ocr2keepers.CheckResult + results []ocr2keepers.CheckResult + err error + }{ + { + name: "simulate multiple upkeeps", + inputs: []ocr2keepers.CheckResult{ + cr0, + { + PipelineExecutionState: 0, + Retryable: false, + Eligible: true, + IneligibilityReason: 0, + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + { + PipelineExecutionState: 0, + Retryable: false, + Eligible: true, + IneligibilityReason: 0, + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + }, + results: []ocr2keepers.CheckResult{ + cr0, + { + PipelineExecutionState: uint8(encoding.RpcFlakyFailure), + Retryable: true, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid1, + Trigger: trigger1, + WorkID: "work1", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + { + PipelineExecutionState: uint8(encoding.PackUnpackDecodeFailed), + Retryable: false, + Eligible: false, + IneligibilityReason: 0, + UpkeepID: uid2, + Trigger: trigger2, + WorkID: "work2", + GasAllocated: 20000, + PerformData: []byte{0, 0, 0, 1, 2, 3}, + FastGasWei: big.NewInt(20000), + LinkNative: big.NewInt(20000), + }, + }, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + e := setupEVMRegistry(t) + client := new(evmClientMocks.Client) + client.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { + return len(b) == 2 && b[0].Method == "eth_call" && b[1].Method == "eth_call" + })).Return(nil). + Run(func(args mock.Arguments) { + be := args.Get(1).([]rpc.BatchElem) + be[0].Error = fmt.Errorf("error") + res := "0x0001" + be[1].Result = res + }).Once() + e.client = client + + results, err := e.simulatePerformUpkeeps(context.Background(), tc.inputs) + assert.Equal(t, tc.results, results) + assert.Equal(t, tc.err, err) + }) + } + +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go index 28889d0006f..e17145ff81e 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_test.go @@ -1,150 +1,21 @@ package evm import ( - "context" "fmt" "math/big" - "sync/atomic" "testing" "time" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/rpc" - ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" - evmClientMocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" - "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/utils" ) -func TestGetActiveUpkeepIDs(t *testing.T) { - tests := []struct { - Name string - LatestHead int64 - ActiveIDs []string - ExpectedErr error - ExpectedKeys []ocr2keepers.UpkeepIdentifier - }{ - {Name: "NoActiveIDs", LatestHead: 1, ActiveIDs: []string{}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{}}, - {Name: "AvailableActiveIDs", LatestHead: 1, ActiveIDs: []string{ - "32329108151019397958065800113404894502874153543356521479058624064899121404671", - "5820911532554020907796191562093071158274499580927271776163559390280294438608", - }, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - upkeepIDFromInt("32329108151019397958065800113404894502874153543356521479058624064899121404671"), - upkeepIDFromInt("5820911532554020907796191562093071158274499580927271776163559390280294438608"), - }}, - } - - for _, test := range tests { - t.Run(test.Name, func(t *testing.T) { - actives := make(map[string]activeUpkeep) - for _, id := range test.ActiveIDs { - idNum := big.NewInt(0) - idNum.SetString(id, 10) - actives[id] = activeUpkeep{ID: idNum} - } - - rg := &EvmRegistry{ - active: actives, - } - - keys, err := rg.GetActiveUpkeepIDs(context.Background()) - - if test.ExpectedErr != nil { - assert.ErrorIs(t, err, test.ExpectedErr) - } else { - assert.Nil(t, err) - } - - if len(test.ExpectedKeys) > 0 { - for _, key := range keys { - assert.Contains(t, test.ExpectedKeys, key) - } - } else { - assert.Equal(t, test.ExpectedKeys, keys) - } - }) - } -} - -func TestGetActiveUpkeepIDsByType(t *testing.T) { - tests := []struct { - Name string - LatestHead int64 - ActiveIDs []string - ExpectedErr error - ExpectedKeys []ocr2keepers.UpkeepIdentifier - Triggers []uint8 - }{ - {Name: "no active ids", LatestHead: 1, ActiveIDs: []string{}, ExpectedKeys: []ocr2keepers.UpkeepIdentifier{}}, - { - Name: "get log upkeeps", - LatestHead: 1, - ActiveIDs: []string{"8", "32329108151019397958065800113404894502874153543356521479058624064899121404671"}, - ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - upkeepIDFromInt("32329108151019397958065800113404894502874153543356521479058624064899121404671"), - }, - Triggers: []uint8{uint8(ocr2keepers.LogTrigger)}, - }, - { - Name: "get conditional upkeeps", - LatestHead: 1, - ActiveIDs: []string{"8", "32329108151019397958065800113404894502874153543356521479058624064899121404671"}, - ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - upkeepIDFromInt("8"), - }, - Triggers: []uint8{uint8(ocr2keepers.ConditionTrigger)}, - }, - { - Name: "get multiple types of upkeeps", - LatestHead: 1, - ActiveIDs: []string{"8", "32329108151019397958065800113404894502874153543356521479058624064899121404671"}, - ExpectedKeys: []ocr2keepers.UpkeepIdentifier{ - upkeepIDFromInt("8"), - upkeepIDFromInt("32329108151019397958065800113404894502874153543356521479058624064899121404671"), - }, - Triggers: []uint8{uint8(ocr2keepers.LogTrigger), uint8(ocr2keepers.ConditionTrigger)}, - }, - } - - for _, test := range tests { - t.Run(test.Name, func(t *testing.T) { - actives := make(map[string]activeUpkeep) - for _, id := range test.ActiveIDs { - idNum := big.NewInt(0) - idNum.SetString(id, 10) - actives[id] = activeUpkeep{ID: idNum} - } - - rg := &EvmRegistry{ - active: actives, - } - - keys, err := rg.GetActiveUpkeepIDsByType(context.Background(), test.Triggers...) - - if test.ExpectedErr != nil { - assert.ErrorIs(t, err, test.ExpectedErr) - } else { - assert.Nil(t, err) - } - - if len(test.ExpectedKeys) > 0 { - for _, key := range keys { - assert.Contains(t, test.ExpectedKeys, key) - } - } else { - assert.Equal(t, test.ExpectedKeys, keys) - } - }) - } -} - func TestPollLogs(t *testing.T) { tests := []struct { Name string @@ -276,7 +147,7 @@ func TestPollLogs(t *testing.T) { chLog: make(chan logpoller.Log, 10), } - err := rg.pollLogs() + err := rg.pollUpkeepStateLogs() assert.Equal(t, test.ExpectedLastPoll, rg.lastPollBlock) if test.ExpectedErr != nil { @@ -311,538 +182,3 @@ func TestPollLogs(t *testing.T) { }) } } - -func TestRegistry_GetBlockAndUpkeepId(t *testing.T) { - r := &EvmRegistry{} - tests := []struct { - name string - input ocr2keepers.UpkeepPayload - wantBlock *big.Int - wantUpkeep *big.Int - }{ - { - "happy flow", - ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepIDFromInt("10"), - Trigger: ocr2keepers.Trigger{ - BlockNumber: 1, - BlockHash: common.HexToHash("0x1"), - }, - }, - big.NewInt(1), - big.NewInt(10), - }, - { - "empty trigger", - ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepIDFromInt("10"), - }, - big.NewInt(0), - big.NewInt(10), - }, - { - "empty payload", - ocr2keepers.UpkeepPayload{}, - big.NewInt(0), - big.NewInt(0), - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - block, _, upkeep := r.getBlockAndUpkeepId(tc.input.UpkeepID, tc.input.Trigger) - assert.Equal(t, tc.wantBlock, block) - assert.Equal(t, tc.wantUpkeep.String(), upkeep.String()) - }) - } -} - -func TestRegistry_VerifyCheckBlock(t *testing.T) { - lggr := logger.TestLogger(t) - upkeepId := ocr2keepers.UpkeepIdentifier{} - upkeepId.FromBigInt(big.NewInt(12345)) - tests := []struct { - name string - checkBlock *big.Int - latestBlock *big.Int - upkeepId *big.Int - checkHash common.Hash - payload ocr2keepers.UpkeepPayload - blocks map[int64]string - state PipelineExecutionState - retryable bool - makeEthCall bool - }{ - { - name: "check block number too told", - checkBlock: big.NewInt(500), - latestBlock: big.NewInt(800), - upkeepId: big.NewInt(12345), - checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), - WorkID: "work", - }, - state: CheckBlockTooOld, - }, - { - name: "check block number invalid", - checkBlock: big.NewInt(500), - latestBlock: big.NewInt(560), - upkeepId: big.NewInt(12345), - checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), - WorkID: "work", - }, - state: RpcFlakyFailure, - retryable: true, - makeEthCall: true, - }, - { - name: "check block hash does not match", - checkBlock: big.NewInt(500), - latestBlock: big.NewInt(560), - upkeepId: big.NewInt(12345), - checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), - WorkID: "work", - }, - blocks: map[int64]string{ - 500: "0xa518faeadcc423338c62572da84dda35fe44b34f521ce88f6081b703b250cca4", - }, - state: CheckBlockInvalid, - }, - { - name: "check block is valid", - checkBlock: big.NewInt(500), - latestBlock: big.NewInt(560), - upkeepId: big.NewInt(12345), - checkHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewTrigger(500, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83")), - WorkID: "work", - }, - blocks: map[int64]string{ - 500: "0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83", - }, - state: NoPipelineError, - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - bs := &BlockSubscriber{ - latestBlock: atomic.Int64{}, - blocks: tc.blocks, - } - bs.latestBlock.Store(tc.latestBlock.Int64()) - e := &EvmRegistry{ - lggr: lggr, - bs: bs, - } - if tc.makeEthCall { - poller := new(mocks.LogPoller) - poller.On("GetBlocksRange", mock.Anything, mock.Anything).Return(nil, fmt.Errorf("error")) - e.poller = poller - } - - state, retryable := e.verifyCheckBlock(context.Background(), tc.checkBlock, tc.upkeepId, tc.checkHash) - assert.Equal(t, tc.state, state) - assert.Equal(t, tc.retryable, retryable) - }) - } -} - -func TestRegistry_VerifyLogExists(t *testing.T) { - lggr := logger.TestLogger(t) - upkeepId := ocr2keepers.UpkeepIdentifier{} - upkeepId.FromBigInt(big.NewInt(12345)) - - extension := &ocr2keepers.LogTriggerExtension{ - TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), - Index: 0, - BlockHash: common.HexToHash("0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71"), - BlockNumber: 500, - } - extension1 := &ocr2keepers.LogTriggerExtension{ - TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), - Index: 0, - BlockHash: common.HexToHash("0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71"), - BlockNumber: 0, - } - - tests := []struct { - name string - upkeepId *big.Int - payload ocr2keepers.UpkeepPayload - blocks map[int64]string - makeEthCall bool - reason UpkeepFailureReason - state PipelineExecutionState - retryable bool - ethCallErr error - receipt *types.Receipt - }{ - { - name: "log block number invalid", - upkeepId: big.NewInt(12345), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), - WorkID: "work", - }, - reason: UpkeepFailureReasonNone, - state: RpcFlakyFailure, - retryable: true, - makeEthCall: true, - ethCallErr: fmt.Errorf("error"), - }, - { - name: "log block no longer exists", - upkeepId: big.NewInt(12345), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), - WorkID: "work", - }, - reason: UpkeepFailureReasonLogBlockNoLongerExists, - retryable: false, - makeEthCall: true, - blocks: map[int64]string{ - 500: "0xb2173b4b75f23f56b7b2b6b2cc5fa9ed1079b9d1655b12b40fdb4dbf59006419", - }, - receipt: &types.Receipt{}, - }, - { - name: "eth client returns a matching block", - upkeepId: big.NewInt(12345), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension1), - WorkID: "work", - }, - reason: UpkeepFailureReasonNone, - retryable: false, - blocks: map[int64]string{ - 500: "0xa518faeadcc423338c62572da84dda35fe44b34f521ce88f6081b703b250cca4", - }, - makeEthCall: true, - receipt: &types.Receipt{ - BlockNumber: big.NewInt(550), - BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), - }, - }, - { - name: "log block is valid", - upkeepId: big.NewInt(12345), - payload: ocr2keepers.UpkeepPayload{ - UpkeepID: upkeepId, - Trigger: ocr2keepers.NewLogTrigger(550, common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), extension), - WorkID: "work", - }, - reason: UpkeepFailureReasonNone, - retryable: false, - blocks: map[int64]string{ - 500: "0x3df0e926f3e21ec1195ffe007a2899214905eb02e768aa89ce0b94accd7f3d71", - }, - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - bs := &BlockSubscriber{ - blocks: tc.blocks, - } - e := &EvmRegistry{ - lggr: lggr, - bs: bs, - ctx: context.Background(), - } - - if tc.makeEthCall { - client := new(evmClientMocks.Client) - client.On("TransactionReceipt", mock.Anything, common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651")). - Return(tc.receipt, tc.ethCallErr) - e.client = client - } - - reason, state, retryable := e.verifyLogExists(tc.upkeepId, tc.payload) - assert.Equal(t, tc.reason, reason) - assert.Equal(t, tc.state, state) - assert.Equal(t, tc.retryable, retryable) - }) - } -} - -func TestRegistry_CheckUpkeeps(t *testing.T) { - lggr := logger.TestLogger(t) - uid0 := genUpkeepID(ocr2keepers.UpkeepType(0), "p0") - uid1 := genUpkeepID(ocr2keepers.UpkeepType(1), "p1") - uid2 := genUpkeepID(ocr2keepers.UpkeepType(1), "p2") - - extension1 := &ocr2keepers.LogTriggerExtension{ - TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), - Index: 0, - BlockHash: common.HexToHash("0x0919c83363b439ea634ce2b576cf3e30db26b340fb7a12058c2fcc401bd04ba0"), - BlockNumber: 550, - } - extension2 := &ocr2keepers.LogTriggerExtension{ - TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), - Index: 0, - BlockHash: common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), - BlockNumber: 550, - } - - trigger0 := ocr2keepers.NewTrigger(150, common.HexToHash("0x1c77db0abe32327cf3ea9de2aadf79876f9e6b6dfcee9d4719a8a2dc8ca289d0")) - trigger1 := ocr2keepers.NewLogTrigger(560, common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), extension1) - trigger2 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension2) - - tests := []struct { - name string - inputs []ocr2keepers.UpkeepPayload - blocks map[int64]string - latestBlock *big.Int - results []ocr2keepers.CheckResult - err error - ethCalls map[string]bool - receipts map[string]*types.Receipt - ethCallErrors map[string]error - }{ - { - name: "check upkeeps with different upkeep types", - inputs: []ocr2keepers.UpkeepPayload{ - { - UpkeepID: uid0, - Trigger: trigger0, - WorkID: "work0", - }, - { - UpkeepID: uid1, - Trigger: trigger1, - WorkID: "work1", - }, - { - UpkeepID: uid2, - Trigger: trigger2, - WorkID: "work2", - // check data byte slice length cannot be odd number, abi pack error - CheckData: []byte{0, 0, 0, 0, 1}, - }, - }, - blocks: map[int64]string{ - 550: "0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857", - 560: "0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857", - 570: "0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc", - }, - latestBlock: big.NewInt(580), - results: []ocr2keepers.CheckResult{ - { - PipelineExecutionState: uint8(CheckBlockTooOld), - Retryable: false, - Eligible: false, - IneligibilityReason: 0, - UpkeepID: uid0, - Trigger: trigger0, - WorkID: "work0", - GasAllocated: 0, - PerformData: nil, - FastGasWei: big.NewInt(0), - LinkNative: big.NewInt(0), - }, - { - PipelineExecutionState: uint8(RpcFlakyFailure), - Retryable: true, - Eligible: false, - IneligibilityReason: 0, - UpkeepID: uid1, - Trigger: trigger1, - WorkID: "work1", - GasAllocated: 0, - PerformData: nil, - FastGasWei: big.NewInt(0), - LinkNative: big.NewInt(0), - }, - { - PipelineExecutionState: uint8(PackUnpackDecodeFailed), - Retryable: false, - Eligible: false, - IneligibilityReason: 0, - UpkeepID: uid2, - Trigger: trigger2, - WorkID: "work2", - GasAllocated: 0, - PerformData: nil, - FastGasWei: big.NewInt(0), - LinkNative: big.NewInt(0), - }, - }, - ethCalls: map[string]bool{ - uid1.String(): true, - }, - receipts: map[string]*types.Receipt{ - //uid1.String(): { - // BlockNumber: big.NewInt(550), - // BlockHash: common.HexToHash("0x5bff03de234fe771ac0d685f9ee0fb0b757ea02ec9e6f10e8e2ee806db1b6b83"), - //}, - }, - ethCallErrors: map[string]error{ - uid1.String(): fmt.Errorf("error"), - }, - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - bs := &BlockSubscriber{ - latestBlock: atomic.Int64{}, - blocks: tc.blocks, - } - bs.latestBlock.Store(tc.latestBlock.Int64()) - e := &EvmRegistry{ - lggr: lggr, - bs: bs, - } - client := new(evmClientMocks.Client) - for _, i := range tc.inputs { - uid := i.UpkeepID.String() - if tc.ethCalls[uid] { - client.On("TransactionReceipt", mock.Anything, common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651")). - Return(tc.receipts[uid], tc.ethCallErrors[uid]) - } - } - e.client = client - - results, err := e.checkUpkeeps(context.Background(), tc.inputs) - assert.Equal(t, tc.results, results) - assert.Equal(t, tc.err, err) - }) - } -} - -func TestRegistry_SimulatePerformUpkeeps(t *testing.T) { - uid0 := genUpkeepID(ocr2keepers.UpkeepType(0), "p0") - uid1 := genUpkeepID(ocr2keepers.UpkeepType(1), "p1") - uid2 := genUpkeepID(ocr2keepers.UpkeepType(1), "p2") - - extension1 := &ocr2keepers.LogTriggerExtension{ - TxHash: common.HexToHash("0xc8def8abdcf3a4eaaf6cc13bff3e4e2a7168d86ea41dbbf97451235aa76c3651"), - Index: 0, - BlockHash: common.HexToHash("0x9840e5b709bfccf6a1b44f34c884bc39403f57923f3f5ead6243cc090546b857"), - BlockNumber: 550, - } - - trigger0 := ocr2keepers.NewTrigger(150, common.HexToHash("0x1c77db0abe32327cf3ea9de2aadf79876f9e6b6dfcee9d4719a8a2dc8ca289d0")) - trigger1 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension1) - trigger2 := ocr2keepers.NewLogTrigger(570, common.HexToHash("0x1222d75217e2dd461cc77e4091c37abe76277430d97f1963a822b4e94ebb83fc"), extension1) - - cr0 := ocr2keepers.CheckResult{ - PipelineExecutionState: uint8(CheckBlockTooOld), - Retryable: false, - Eligible: false, - IneligibilityReason: 0, - UpkeepID: uid0, - Trigger: trigger0, - WorkID: "work0", - GasAllocated: 0, - PerformData: nil, - FastGasWei: big.NewInt(0), - LinkNative: big.NewInt(0), - } - - tests := []struct { - name string - inputs []ocr2keepers.CheckResult - results []ocr2keepers.CheckResult - err error - }{ - { - name: "simulate multiple upkeeps", - inputs: []ocr2keepers.CheckResult{ - cr0, - { - PipelineExecutionState: 0, - Retryable: false, - Eligible: true, - IneligibilityReason: 0, - UpkeepID: uid1, - Trigger: trigger1, - WorkID: "work1", - GasAllocated: 20000, - PerformData: []byte{0, 0, 0, 1, 2, 3}, - FastGasWei: big.NewInt(20000), - LinkNative: big.NewInt(20000), - }, - { - PipelineExecutionState: 0, - Retryable: false, - Eligible: true, - IneligibilityReason: 0, - UpkeepID: uid2, - Trigger: trigger2, - WorkID: "work2", - GasAllocated: 20000, - PerformData: []byte{0, 0, 0, 1, 2, 3}, - FastGasWei: big.NewInt(20000), - LinkNative: big.NewInt(20000), - }, - }, - results: []ocr2keepers.CheckResult{ - cr0, - { - PipelineExecutionState: uint8(RpcFlakyFailure), - Retryable: true, - Eligible: false, - IneligibilityReason: 0, - UpkeepID: uid1, - Trigger: trigger1, - WorkID: "work1", - GasAllocated: 20000, - PerformData: []byte{0, 0, 0, 1, 2, 3}, - FastGasWei: big.NewInt(20000), - LinkNative: big.NewInt(20000), - }, - { - PipelineExecutionState: uint8(PackUnpackDecodeFailed), - Retryable: false, - Eligible: false, - IneligibilityReason: 0, - UpkeepID: uid2, - Trigger: trigger2, - WorkID: "work2", - GasAllocated: 20000, - PerformData: []byte{0, 0, 0, 1, 2, 3}, - FastGasWei: big.NewInt(20000), - LinkNative: big.NewInt(20000), - }, - }, - }, - } - - for _, tc := range tests { - t.Run(tc.name, func(t *testing.T) { - e := setupEVMRegistry(t) - client := new(evmClientMocks.Client) - client.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { - return len(b) == 2 && b[0].Method == "eth_call" && b[1].Method == "eth_call" - })).Return(nil). - Run(func(args mock.Arguments) { - be := args.Get(1).([]rpc.BatchElem) - be[0].Error = fmt.Errorf("error") - res := "0x0001" - be[1].Result = res - }).Once() - e.client = client - - results, err := e.simulatePerformUpkeeps(context.Background(), tc.inputs) - assert.Equal(t, tc.results, results) - assert.Equal(t, tc.err, err) - }) - } - -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/regsitry_check_pipeline.go b/core/services/ocr2/plugins/ocr2keeper/evm21/regsitry_check_pipeline.go new file mode 100644 index 00000000000..07462208113 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/regsitry_check_pipeline.go @@ -0,0 +1,348 @@ +package evm + +import ( + "context" + "fmt" + "math/big" + "strings" + + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/common/hexutil" + "github.com/ethereum/go-ethereum/rpc" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/encoding" +) + +const ( + // validCheckBlockRange decides the max distance between the check block and the current block + // allowed in checkPipeline + validCheckBlockRange = 128 +) + +type checkResult struct { + cr []ocr2keepers.CheckResult + err error +} + +func (r *EvmRegistry) CheckUpkeeps(ctx context.Context, keys ...ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { + r.lggr.Debugw("Checking upkeeps", "upkeeps", keys) + for i := range keys { + if keys[i].Trigger.BlockNumber == 0 { // check block was not populated, use latest + latest := r.bs.latestBlock.Load() + copy(keys[i].Trigger.BlockHash[:], latest.Hash[:]) + keys[i].Trigger.BlockNumber = latest.Number + r.lggr.Debugf("Check upkeep key had no trigger block number, using latest block %v", keys[i].Trigger.BlockNumber) + } + } + + chResult := make(chan checkResult, 1) + go r.doCheck(ctx, keys, chResult) + + select { + case rs := <-chResult: + result := make([]ocr2keepers.CheckResult, len(rs.cr)) + copy(result, rs.cr) + return result, rs.err + case <-ctx.Done(): + // safety on context done to provide an error on context cancellation + // contract calls through the geth wrappers are a bit of a black box + // so this safety net ensures contexts are fully respected and contract + // call functions have a more graceful closure outside the scope of + // CheckUpkeep needing to return immediately. + return nil, fmt.Errorf("%w: failed to check upkeep on registry", ErrContextCancelled) + } +} + +func (r *EvmRegistry) doCheck(ctx context.Context, keys []ocr2keepers.UpkeepPayload, chResult chan checkResult) { + upkeepResults, err := r.checkUpkeeps(ctx, keys) + if err != nil { + chResult <- checkResult{ + err: err, + } + return + } + + upkeepResults = r.feedLookup(ctx, upkeepResults) + + upkeepResults, err = r.simulatePerformUpkeeps(ctx, upkeepResults) + if err != nil { + chResult <- checkResult{ + err: err, + } + return + } + + chResult <- checkResult{ + cr: upkeepResults, + } +} + +// getBlockAndUpkeepId retrieves check block number, block hash from trigger and upkeep id +func (r *EvmRegistry) getBlockAndUpkeepId(upkeepID ocr2keepers.UpkeepIdentifier, trigger ocr2keepers.Trigger) (*big.Int, common.Hash, *big.Int) { + block := new(big.Int).SetInt64(int64(trigger.BlockNumber)) + return block, common.BytesToHash(trigger.BlockHash[:]), upkeepID.BigInt() +} + +func (r *EvmRegistry) getBlockHash(blockNumber *big.Int) (common.Hash, error) { + blocks, err := r.poller.GetBlocksRange(r.ctx, []uint64{blockNumber.Uint64()}) + if err != nil { + return [32]byte{}, err + } + if len(blocks) == 0 { + return [32]byte{}, fmt.Errorf("could not find block %d in log poller", blockNumber.Uint64()) + } + + return blocks[0].BlockHash, nil +} + +func (r *EvmRegistry) getTxBlock(txHash common.Hash) (*big.Int, common.Hash, error) { + // TODO: do manual eth_getTransactionReceipt call to get block number and hash + txr, err := r.client.TransactionReceipt(r.ctx, txHash) + if err != nil { + return nil, common.Hash{}, err + } + + return txr.BlockNumber, txr.BlockHash, nil +} + +// verifyCheckBlock checks that the check block and hash are valid, returns the pipeline execution state and retryable +func (r *EvmRegistry) verifyCheckBlock(ctx context.Context, checkBlock, upkeepId *big.Int, checkHash common.Hash) (state encoding.PipelineExecutionState, retryable bool) { + // verify check block number is not too old + latestBlock := r.bs.latestBlock.Load() + if int64(latestBlock.Number)-checkBlock.Int64() > validCheckBlockRange { + r.lggr.Warnf("latest block is %d, check block number %s is too old for upkeepId %s", r.bs.latestBlock.Load(), checkBlock, upkeepId) + return encoding.CheckBlockTooOld, false + } + r.lggr.Warnf("latestBlock=%d checkBlock=%d", r.bs.latestBlock.Load(), checkBlock.Int64()) + + var h string + var ok bool + // verify check block number and hash are valid + h, ok = r.bs.queryBlocksMap(checkBlock.Int64()) + if !ok { + r.lggr.Warnf("check block %s does not exist in block subscriber for upkeepId %s, querying eth client", checkBlock, upkeepId) + b, err := r.getBlockHash(checkBlock) + if err != nil { + r.lggr.Warnf("failed to query block %s: %s", checkBlock, err.Error()) + return encoding.RpcFlakyFailure, true + } + h = b.Hex() + } + if checkHash.Hex() != h { + r.lggr.Warnf("check block %s hash do not match. %s from block subscriber vs %s from trigger for upkeepId %s", checkBlock, h, checkHash.Hex(), upkeepId) + return encoding.CheckBlockInvalid, false + } + return encoding.NoPipelineError, false +} + +// verifyLogExists checks that the log still exists on chain, returns failure reason, pipeline error, and retryable +func (r *EvmRegistry) verifyLogExists(upkeepId *big.Int, p ocr2keepers.UpkeepPayload) (encoding.UpkeepFailureReason, encoding.PipelineExecutionState, bool) { + logBlockNumber := int64(p.Trigger.LogTriggerExtension.BlockNumber) + logBlockHash := common.BytesToHash(p.Trigger.LogTriggerExtension.BlockHash[:]) + // if log block number is populated, check log block number and block hash + if logBlockNumber != 0 { + h, ok := r.bs.queryBlocksMap(logBlockNumber) + if ok && h == logBlockHash.Hex() { + r.lggr.Debugf("tx hash %s exists on chain at block number %d for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), logBlockNumber, upkeepId) + return encoding.UpkeepFailureReasonNone, encoding.NoPipelineError, false + } + r.lggr.Debugf("log block %d does not exist in block subscriber for upkeepId %s, querying eth client", logBlockNumber, upkeepId) + } else { + r.lggr.Debugf("log block not provided, querying eth client for tx hash %s for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) + } + // query eth client as a fallback + bn, _, err := r.getTxBlock(p.Trigger.LogTriggerExtension.TxHash) + if err != nil { + // primitive way of checking errors + if strings.Contains(err.Error(), "missing required field") || strings.Contains(err.Error(), "not found") { + return encoding.UpkeepFailureReasonTxHashNoLongerExists, encoding.NoPipelineError, false + } + r.lggr.Warnf("failed to query tx hash %s for upkeepId %s: %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId, err.Error()) + return encoding.UpkeepFailureReasonNone, encoding.RpcFlakyFailure, true + } + if bn == nil { + r.lggr.Warnf("tx hash %s does not exist on chain for upkeepId %s.", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) + return encoding.UpkeepFailureReasonTxHashNoLongerExists, encoding.NoPipelineError, false + } + r.lggr.Debugf("tx hash %s exists on chain for upkeepId %s", hexutil.Encode(p.Trigger.LogTriggerExtension.TxHash[:]), upkeepId) + return encoding.UpkeepFailureReasonNone, encoding.NoPipelineError, false +} + +func (r *EvmRegistry) checkUpkeeps(ctx context.Context, payloads []ocr2keepers.UpkeepPayload) ([]ocr2keepers.CheckResult, error) { + var ( + checkReqs []rpc.BatchElem + checkResults []*string + results = make([]ocr2keepers.CheckResult, len(payloads)) + ) + indices := map[int]int{} + + for i, p := range payloads { + block, checkHash, upkeepId := r.getBlockAndUpkeepId(p.UpkeepID, p.Trigger) + state, retryable := r.verifyCheckBlock(ctx, block, upkeepId, checkHash) + if state != encoding.NoPipelineError { + results[i] = encoding.GetIneligibleCheckResultWithoutPerformData(p, encoding.UpkeepFailureReasonNone, state, retryable) + continue + } + + opts := r.buildCallOpts(ctx, block) + var payload []byte + var err error + uid := &ocr2keepers.UpkeepIdentifier{} + uid.FromBigInt(upkeepId) + switch core.GetUpkeepType(*uid) { + case ocr2keepers.LogTrigger: + reason, state, retryable := r.verifyLogExists(upkeepId, p) + if reason != encoding.UpkeepFailureReasonNone || state != encoding.NoPipelineError { + results[i] = encoding.GetIneligibleCheckResultWithoutPerformData(p, reason, state, retryable) + continue + } + + // check data will include the log trigger config + payload, err = r.abi.Pack("checkUpkeep", upkeepId, p.CheckData) + if err != nil { + // pack error, no retryable + r.lggr.Warnf("failed to pack log trigger checkUpkeep data for upkeepId %s with check data %s: %s", upkeepId, hexutil.Encode(p.CheckData), err) + results[i] = encoding.GetIneligibleCheckResultWithoutPerformData(p, encoding.UpkeepFailureReasonNone, encoding.PackUnpackDecodeFailed, false) + continue + } + default: + // checkUpkeep is overloaded on the contract for conditionals and log upkeeps + // Need to use the first function (checkUpkeep0) for conditionals + payload, err = r.abi.Pack("checkUpkeep0", upkeepId) + if err != nil { + // pack error, no retryable + r.lggr.Warnf("failed to pack conditional checkUpkeep data for upkeepId %s with check data %s: %s", upkeepId, hexutil.Encode(p.CheckData), err) + results[i] = encoding.GetIneligibleCheckResultWithoutPerformData(p, encoding.UpkeepFailureReasonNone, encoding.PackUnpackDecodeFailed, false) + continue + } + } + indices[len(checkReqs)] = i + results[i] = encoding.GetIneligibleCheckResultWithoutPerformData(p, encoding.UpkeepFailureReasonNone, encoding.NoPipelineError, false) + + var result string + checkReqs = append(checkReqs, rpc.BatchElem{ + Method: "eth_call", + Args: []interface{}{ + map[string]interface{}{ + "to": r.addr.Hex(), + "data": hexutil.Bytes(payload), + }, + hexutil.EncodeBig(opts.BlockNumber), + }, + Result: &result, + }) + + checkResults = append(checkResults, &result) + } + + if len(checkResults) > 0 { + // In contrast to CallContext, BatchCallContext only returns errors that have occurred + // while sending the request. Any error specific to a request is reported through the + // Error field of the corresponding BatchElem. + // hence, if BatchCallContext returns an error, it will be an error which will terminate the pipeline + if err := r.client.BatchCallContext(ctx, checkReqs); err != nil { + r.lggr.Errorf("failed to batch call for checkUpkeeps: %s", err) + return nil, err + } + } + + for i, req := range checkReqs { + index := indices[i] + if req.Error != nil { + // individual upkeep failed in a batch call, retryable + r.lggr.Warnf("error encountered in check result for upkeepId %s: %s", results[index].UpkeepID.String(), req.Error) + results[index].Retryable = true + results[index].PipelineExecutionState = uint8(encoding.RpcFlakyFailure) + } else { + var err error + results[index], err = r.packer.UnpackCheckResult(payloads[index], *checkResults[i]) + if err != nil { + r.lggr.Warnf("failed to unpack check result: %s", err) + } + } + } + + return results, nil +} + +func (r *EvmRegistry) simulatePerformUpkeeps(ctx context.Context, checkResults []ocr2keepers.CheckResult) ([]ocr2keepers.CheckResult, error) { + var ( + performReqs = make([]rpc.BatchElem, 0, len(checkResults)) + performResults = make([]*string, 0, len(checkResults)) + performToKeyIdx = make([]int, 0, len(checkResults)) + ) + + for i, cr := range checkResults { + if !cr.Eligible { + continue + } + + block, _, upkeepId := r.getBlockAndUpkeepId(cr.UpkeepID, cr.Trigger) + + opts := r.buildCallOpts(ctx, block) + + // Since checkUpkeep is true, simulate perform upkeep to ensure it doesn't revert + payload, err := r.abi.Pack("simulatePerformUpkeep", upkeepId, cr.PerformData) + if err != nil { + // pack failed, not retryable + r.lggr.Warnf("failed to pack perform data %s for %s: %s", hexutil.Encode(cr.PerformData), upkeepId, err) + checkResults[i].Eligible = false + checkResults[i].PipelineExecutionState = uint8(encoding.PackUnpackDecodeFailed) + continue + } + + var result string + performReqs = append(performReqs, rpc.BatchElem{ + Method: "eth_call", + Args: []interface{}{ + map[string]interface{}{ + "to": r.addr.Hex(), + "data": hexutil.Bytes(payload), + }, + hexutil.EncodeBig(opts.BlockNumber), + }, + Result: &result, + }) + + performResults = append(performResults, &result) + performToKeyIdx = append(performToKeyIdx, i) + } + + if len(performReqs) > 0 { + if err := r.client.BatchCallContext(ctx, performReqs); err != nil { + r.lggr.Errorf("failed to batch call for simulatePerformUpkeeps: %s", err) + return nil, err + } + } + + for i, req := range performReqs { + idx := performToKeyIdx[i] + if req.Error != nil { + // individual upkeep failed in a batch call, retryable + r.lggr.Warnf("failed to simulate upkeepId %s: %s", checkResults[idx].UpkeepID.String(), req.Error) + checkResults[idx].Retryable = true + checkResults[idx].Eligible = false + checkResults[idx].PipelineExecutionState = uint8(encoding.RpcFlakyFailure) + continue + } + + state, simulatePerformSuccess, err := r.packer.UnpackPerformResult(*performResults[i]) + if err != nil { + // unpack failed, not retryable + r.lggr.Warnf("failed to unpack simulate performUpkeep result for upkeepId %s for state %d: %s", checkResults[idx].UpkeepID.String(), state, req.Error) + checkResults[idx].Retryable = false + checkResults[idx].Eligible = false + checkResults[idx].PipelineExecutionState = uint8(state) + continue + } + + if !simulatePerformSuccess { + r.lggr.Warnf("upkeepId %s is not eligible after simulation of perform", checkResults[idx].UpkeepID.String()) + checkResults[performToKeyIdx[i]].Eligible = false + } + } + + return checkResults, nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/services.go b/core/services/ocr2/plugins/ocr2keeper/evm21/services.go new file mode 100644 index 00000000000..639b2b6af79 --- /dev/null +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/services.go @@ -0,0 +1,144 @@ +package evm + +import ( + "fmt" + "strings" + + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/ethereum/go-ethereum/common" + "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/feed_lookup_compatible_interface" + iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/models" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/encoding" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate" +) + +type AutomationServices interface { + Registry() *EvmRegistry + Encoder() ocr2keepers.Encoder + TransmitEventProvider() *TransmitEventProvider + BlockSubscriber() *BlockSubscriber + PayloadBuilder() ocr2keepers.PayloadBuilder + UpkeepStateStore() upkeepstate.UpkeepStateStore + LogEventProvider() logprovider.LogEventProvider + LogRecoverer() logprovider.LogRecoverer + UpkeepProvider() ocr2keepers.ConditionalUpkeepProvider + Keyring() ocr3types.OnchainKeyring[plugin.AutomationReportInfo] +} + +func New(addr common.Address, client evm.Chain, mc *models.MercuryCredentials, keyring ocrtypes.OnchainKeyring, lggr logger.Logger) (AutomationServices, error) { + feedLookupCompatibleABI, err := abi.JSON(strings.NewReader(feed_lookup_compatible_interface.FeedLookupCompatibleInterfaceABI)) + if err != nil { + return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + } + keeperRegistryABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) + if err != nil { + return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + } + utilsABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) + if err != nil { + return nil, fmt.Errorf("%w: %s", ErrABINotParsable, err) + } + registryContract, err := iregistry21.NewIKeeperRegistryMaster(addr, client.Client()) + if err != nil { + return nil, fmt.Errorf("%w: failed to create caller for address and backend", ErrInitializationFailure) + } + // lookback blocks for transmit event is hard coded and should provide ample time for logs + // to be detected in most cases + var transmitLookbackBlocks int64 = 250 + transmitter, err := NewTransmitEventProvider(lggr, client.LogPoller(), addr, client.Client(), transmitLookbackBlocks) + if err != nil { + return nil, err + } + + services := new(automationServices) + services.transmitter = transmitter + + packer := encoding.NewAbiPacker(keeperRegistryABI, utilsABI) + services.encoder = encoding.NewReportEncoder(packer) + + scanner := upkeepstate.NewPerformedEventsScanner(lggr, client.LogPoller(), addr) + services.upkeepState = upkeepstate.NewUpkeepStateStore(lggr, scanner) + + logProvider, logRecoverer := logprovider.New(lggr, client.LogPoller(), client.Client(), utilsABI, services.upkeepState) + services.logProvider = logProvider + services.logRecoverer = logRecoverer + services.blockSub = NewBlockSubscriber(client.HeadBroadcaster(), client.LogPoller(), lggr) + + services.keyring = NewOnchainKeyringV3Wrapper(keyring) + + al := NewActiveUpkeepList() + services.payloadBuilder = NewPayloadBuilder(al, logRecoverer, lggr) + + services.reg = NewEvmRegistry(lggr, addr, client, feedLookupCompatibleABI, + keeperRegistryABI, registryContract, mc, al, services.logProvider, + packer, services.blockSub) + + services.upkeepProvider = NewUpkeepProvider(al, services.blockSub, client.LogPoller()) + + return services, nil +} + +type automationServices struct { + reg *EvmRegistry + encoder ocr2keepers.Encoder + transmitter *TransmitEventProvider + blockSub *BlockSubscriber + payloadBuilder ocr2keepers.PayloadBuilder + upkeepState upkeepstate.UpkeepStateStore + logProvider logprovider.LogEventProvider + logRecoverer logprovider.LogRecoverer + upkeepProvider *upkeepProvider + keyring *onchainKeyringV3Wrapper +} + +var _ AutomationServices = &automationServices{} + +func (f *automationServices) Registry() *EvmRegistry { + return f.reg +} + +func (f *automationServices) Encoder() ocr2keepers.Encoder { + return f.encoder +} + +func (f *automationServices) TransmitEventProvider() *TransmitEventProvider { + return f.transmitter +} + +func (f *automationServices) BlockSubscriber() *BlockSubscriber { + return f.blockSub +} + +func (f *automationServices) PayloadBuilder() ocr2keepers.PayloadBuilder { + return f.payloadBuilder +} + +func (f *automationServices) UpkeepStateStore() upkeepstate.UpkeepStateStore { + return f.upkeepState +} + +func (f *automationServices) LogEventProvider() logprovider.LogEventProvider { + return f.logProvider +} + +func (f *automationServices) LogRecoverer() logprovider.LogRecoverer { + return f.logRecoverer +} + +func (f *automationServices) UpkeepProvider() ocr2keepers.ConditionalUpkeepProvider { + return f.upkeepProvider +} + +func (f *automationServices) Keyring() ocr3types.OnchainKeyring[plugin.AutomationReportInfo] { + return f.keyring +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go index d3fbc496aae..3b87277ee54 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider.go @@ -51,14 +51,15 @@ func NewTransmitEventProvider( if err != nil { return nil, err } - // Add log filters for the log poller so that it can poll and find the logs that - // we need. err = logPoller.RegisterFilter(logpoller.Filter{ Name: TransmitEventProviderFilterName(contract.Address()), EventSigs: []common.Hash{ - iregistry21.IKeeperRegistryMasterUpkeepPerformed{}.Topic(), - iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{}.Topic(), - iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{}.Topic(), + // These are the events that are emitted when a node transmits a report + iregistry21.IKeeperRegistryMasterUpkeepPerformed{}.Topic(), // Happy path: report performed the upkeep + iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{}.Topic(), // Report checkBlockNumber was reorged + iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{}.Topic(), // Upkeep didn't have sufficient funds when report reached chain, perform was aborted early + // Report was too old when it reached the chain. For conditionals upkeep was already performed on a higher block than checkBlockNum + // for logs upkeep was already performed for the particular log iregistry21.IKeeperRegistryMasterStaleUpkeepReport{}.Topic(), }, Addresses: []common.Address{registryAddress}, @@ -136,9 +137,8 @@ func (c *TransmitEventProvider) GetLatestEvents(ctx context.Context) ([]ocr2keep []common.Hash{ iregistry21.IKeeperRegistryMasterUpkeepPerformed{}.Topic(), iregistry21.IKeeperRegistryMasterStaleUpkeepReport{}.Topic(), - // TODO: enable once we have the corredponding types in ocr2keepers - // iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{}.Topic(), - // iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{}.Topic(), + iregistry21.IKeeperRegistryMasterReorgedUpkeepReport{}.Topic(), + iregistry21.IKeeperRegistryMasterInsufficientFundsUpkeepReport{}.Topic(), }, c.registryAddress, pg.WithParentCtx(ctx), @@ -232,10 +232,7 @@ func (c *TransmitEventProvider) convertToTransmitEvents(logs []transmitEventLog, trigger.LogTriggerExtension.Index = triggerW.LogIndex default: } - workID, err := core.UpkeepWorkID(id, trigger) - if err != nil { - return nil, err - } + workID := core.UpkeepWorkID(*upkeepId, trigger) vals = append(vals, ocr2keepers.TransmitEvent{ Type: l.TransmitEventType(), TransmitBlock: ocr2keepers.BlockNumber(l.BlockNumber), @@ -300,7 +297,6 @@ func (l transmitEventLog) TransmitEventType() ocr2keepers.TransmitEventType { case l.InsufficientFunds != nil: return ocr2keepers.InsufficientFundsReportEvent default: - // TODO: use unknown type - return ocr2keepers.TransmitEventType(0) + return ocr2keepers.UnknownEvent } } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go index f41a80655de..de619c24df1 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/transmit_event_provider_test.go @@ -17,6 +17,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) func TestTransmitEventProvider(t *testing.T) { @@ -100,7 +101,7 @@ func TestTransmitEventProvider(t *testing.T) { func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { provider := &TransmitEventProvider{} - id := genUpkeepID(ocr2keepers.LogTrigger, "1111111111111111") + id := core.GenUpkeepID(ocr2keepers.LogTrigger, "1111111111111111") tests := []struct { name string performed []transmitEventLog @@ -159,7 +160,7 @@ func TestTransmitEventProvider_ConvertToTransmitEvents(t *testing.T) { } func TestTransmitEventLog(t *testing.T) { - uid := genUpkeepID(ocr2keepers.ConditionTrigger, "111") + uid := core.GenUpkeepID(ocr2keepers.ConditionTrigger, "111") tests := []struct { name string diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go index e9b4f67947f..787675ba24f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go @@ -2,50 +2,36 @@ package evm import ( "context" - "math/big" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" - "github.com/smartcontractkit/chainlink/v2/core/services/pg" ) var _ ocr2keepers.ConditionalUpkeepProvider = &upkeepProvider{} type upkeepProvider struct { - reg *EvmRegistry - lp logpoller.LogPoller + activeUpkeeps ActiveUpkeepList + bs *BlockSubscriber + lp logpoller.LogPoller } -func NewUpkeepProvider(reg *EvmRegistry, lp logpoller.LogPoller) *upkeepProvider { +func NewUpkeepProvider(activeUpkeeps ActiveUpkeepList, bs *BlockSubscriber, lp logpoller.LogPoller) *upkeepProvider { return &upkeepProvider{ - reg: reg, - lp: lp, + activeUpkeeps: activeUpkeeps, + bs: bs, + lp: lp, } } func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context) ([]ocr2keepers.UpkeepPayload, error) { - ids, err := p.reg.GetActiveUpkeepIDsByType(ctx, uint8(ocr2keepers.ConditionTrigger)) - if err != nil { - return nil, err - } - latestBlock, err := p.lp.LatestBlock(pg.WithParentCtx(ctx)) - if err != nil { - return nil, err - } - - block := big.NewInt(latestBlock) - blockHash, err := p.reg.getBlockHash(block) - if err != nil { - return nil, err - } - + latestBlock := p.bs.latestBlock.Load() var payloads []ocr2keepers.UpkeepPayload - for _, uid := range ids { + for _, uid := range p.activeUpkeeps.View(ocr2keepers.ConditionTrigger) { payload, err := core.NewUpkeepPayload( - uid.BigInt(), - ocr2keepers.NewTrigger(ocr2keepers.BlockNumber(block.Int64()), blockHash), + uid, + ocr2keepers.NewTrigger(ocr2keepers.BlockNumber(latestBlock.Number), latestBlock.Hash), nil, ) if err != nil { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go index ddf93183336..e55a9753eca 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go @@ -4,7 +4,6 @@ import ( "bytes" "math/big" "sort" - "sync" "testing" coreTypes "github.com/ethereum/go-ethereum/core/types" @@ -15,6 +14,7 @@ import ( clientmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { @@ -22,46 +22,44 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { ctx := testutils.Context(t) c := new(clientmocks.Client) - r := &EvmRegistry{ - mu: sync.RWMutex{}, - active: map[string]activeUpkeep{}, - client: c, - } + bs := &BlockSubscriber{} var lp logpoller.LogPoller - p := NewUpkeepProvider(r, lp) - tests := []struct { name string - active map[string]activeUpkeep + active ActiveUpkeepList blockHeader coreTypes.Header want []ocr2keepers.UpkeepPayload wantErr bool }{ { "empty", - map[string]activeUpkeep{}, + &mockActiveUpkeepList{ + ViewFn: func(upkeepType ...ocr2keepers.UpkeepType) []*big.Int { + return []*big.Int{} + }, + }, coreTypes.Header{Number: big.NewInt(0)}, nil, false, }, { "happy flow", - map[string]activeUpkeep{ - "1": { - ID: big.NewInt(1), - }, - "2": { - ID: big.NewInt(2), + &mockActiveUpkeepList{ + ViewFn: func(upkeepType ...ocr2keepers.UpkeepType) []*big.Int { + return []*big.Int{ + big.NewInt(1), + big.NewInt(2), + } }, }, coreTypes.Header{Number: big.NewInt(1)}, []ocr2keepers.UpkeepPayload{ { - UpkeepID: upkeepIDFromInt("10"), + UpkeepID: core.UpkeepIDFromInt("10"), }, { - UpkeepID: upkeepIDFromInt("15"), + UpkeepID: core.UpkeepIDFromInt("15"), }, }, false, @@ -73,9 +71,7 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { b := coreTypes.NewBlockWithHeader(&tc.blockHeader) c.On("BlockByNumber", mock.Anything, mock.Anything).Return(b, nil) - r.mu.Lock() - r.active = tc.active - r.mu.Unlock() + p := NewUpkeepProvider(tc.active, bs, lp) got, err := p.GetActiveUpkeeps(ctx) require.NoError(t, err) @@ -92,3 +88,17 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { }) } } + +type mockActiveUpkeepList struct { + ActiveUpkeepList + ViewFn func(...ocr2keepers.UpkeepType) []*big.Int + IsActiveFn func(id *big.Int) bool +} + +func (l *mockActiveUpkeepList) View(u ...ocr2keepers.UpkeepType) []*big.Int { + return l.ViewFn(u...) +} + +func (l *mockActiveUpkeepList) IsActive(id *big.Int) bool { + return l.IsActiveFn(id) +} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go index 7cc029a6d84..ae33ceadbb0 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go @@ -3,6 +3,7 @@ package upkeepstate import ( "context" "fmt" + "io" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" @@ -15,6 +16,9 @@ import ( type PerformedLogsScanner interface { WorkIDsInRange(ctx context.Context, start, end int64) ([]string, error) + + Start(context.Context) error + io.Closer } type performedEventsScanner struct { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go index c70e8226d9b..13fb749d222 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store.go @@ -2,12 +2,15 @@ package upkeepstate import ( "context" + "fmt" + "io" "sync" "time" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) var ( @@ -17,15 +20,12 @@ var ( GCInterval = 2 * time.Hour ) -// UpkeepStateReader is the interface for reading the current state of upkeeps. -type UpkeepStateReader interface { - SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) -} - // UpkeepStateStore is the interface for managing upkeeps final state in a local store. type UpkeepStateStore interface { ocr2keepers.UpkeepStateUpdater - UpkeepStateReader + core.UpkeepStateReader + Start(context.Context) error + io.Closer } var ( @@ -36,14 +36,14 @@ var ( type upkeepStateRecord struct { workID string state ocr2keepers.UpkeepState - block uint64 addedAt time.Time } // upkeepStateStore implements UpkeepStateStore. -// It stores the state of ineligible upkeeps in a local, in-memory cache (TODO: save in DB). +// It stores the state of ineligible upkeeps in a local, in-memory cache. // In addition, performed events are fetched by the scanner on demand. +// TODO: Add DB persistence type upkeepStateStore struct { lggr logger.Logger @@ -66,36 +66,53 @@ func NewUpkeepStateStore(lggr logger.Logger, scanner PerformedLogsScanner) *upke // Start starts the upkeep state store. // it does background cleanup of the cache. -func (u *upkeepStateStore) Start(pctx context.Context) error { - ctx, cancel := context.WithCancel(pctx) - defer cancel() - +func (u *upkeepStateStore) Start(context.Context) error { u.mu.Lock() + if u.cancel != nil { + u.mu.Unlock() + return fmt.Errorf("already started") + } + ctx, cancel := context.WithCancel(context.Background()) u.cancel = cancel u.mu.Unlock() + if err := u.scanner.Start(ctx); err != nil { + return fmt.Errorf("failed to start scanner") + } + u.lggr.Debug("Starting upkeep state store") - ticker := time.NewTicker(GCInterval) - defer ticker.Stop() + { + go func(ctx context.Context) { + ticker := time.NewTicker(GCInterval) + defer ticker.Stop() - for { - select { - case <-ticker.C: - u.cleanup() - case <-ctx.Done(): - return nil - } + for { + select { + case <-ticker.C: + u.cleanup() + case <-ctx.Done(): + + } + } + }(ctx) } + + return nil } func (u *upkeepStateStore) Close() error { u.mu.Lock() - cancel := u.cancel - u.mu.Unlock() + defer u.mu.Unlock() - if cancel != nil { + if cancel := u.cancel; cancel != nil { + u.cancel = nil cancel() + } else { + return fmt.Errorf("already stopped") + } + if err := u.scanner.Close(); err != nil { + return fmt.Errorf("failed to start scanner") } return nil @@ -104,7 +121,6 @@ func (u *upkeepStateStore) Close() error { // SelectByWorkIDs returns the current state of the upkeep for the provided ids. // If an id is not found, the state is returned as StateUnknown. // We first check the cache, and if any ids are missing, we fetch them from the scanner. -// TODO: fetch from DB func (u *upkeepStateStore) SelectByWorkIDsInRange(ctx context.Context, start, end int64, workIDs ...string) ([]ocr2keepers.UpkeepState, error) { states, ok := u.selectFromCache(workIDs...) if ok { @@ -127,7 +143,7 @@ func (u *upkeepStateStore) SetUpkeepState(_ context.Context, result ocr2keepers. return nil } - u.upsertStateRecord(result.WorkID, ocr2keepers.Ineligible, uint64(result.Trigger.BlockNumber)) + u.upsertStateRecord(result.WorkID, ocr2keepers.Ineligible) return nil } @@ -135,8 +151,7 @@ func (u *upkeepStateStore) SetUpkeepState(_ context.Context, result ocr2keepers. // upsertStateRecord inserts or updates a record for the provided // check result. If an item already exists in the data store, the state and // block are updated. -// TODO: persist to DB -func (u *upkeepStateStore) upsertStateRecord(workID string, s ocr2keepers.UpkeepState, b uint64) { +func (u *upkeepStateStore) upsertStateRecord(workID string, s ocr2keepers.UpkeepState) { u.mu.Lock() defer u.mu.Unlock() @@ -148,7 +163,6 @@ func (u *upkeepStateStore) upsertStateRecord(workID string, s ocr2keepers.Upkeep } } record.state = s - record.block = b u.cache[workID] = record } @@ -169,7 +183,6 @@ func (u *upkeepStateStore) fetchPerformed(ctx context.Context, start, end int64, workID: workID, state: ocr2keepers.Performed, addedAt: time.Now(), - block: uint64(end), // TODO: use block number from log } u.cache[workID] = s } @@ -207,7 +220,6 @@ func (u *upkeepStateStore) cleanup() { // cleanDB cleans up records in the DB that are older than the TTL. func (u *upkeepStateStore) cleanDB() { - // TODO: implement } // cleanupCache removes any records from the cache that are older than the TTL. diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go index 1d89546c844..853b0c317ce 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/store_test.go @@ -159,11 +159,9 @@ func TestUpkeepStateStore_Upsert(t *testing.T) { store.mu.Lock() addedAt := store.cache["0x1"].addedAt - block := store.cache["0x1"].block store.mu.Unlock() require.True(t, now.After(addedAt)) - require.Equal(t, uint64(2), block) } func createUpkeepIDForTest(v int64) ocr2keepers.UpkeepIdentifier { @@ -201,3 +199,11 @@ func (s *mockScanner) WorkIDsInRange(ctx context.Context, start, end int64) ([]s s.workIDs = nil return res, s.err } + +func (s *mockScanner) Start(context.Context) error { + return nil +} + +func (s *mockScanner) Close() error { + return nil +} diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go index 0f19c49ccb7..7a808f66f6b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go @@ -22,6 +22,7 @@ import ( "github.com/onsi/gomega" "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/confighelper" + "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3confighelper" ocrTypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "github.com/smartcontractkit/ocr2keepers/pkg/v3/config" "github.com/stretchr/testify/assert" @@ -151,14 +152,7 @@ func TestIntegration_KeeperPluginConditionalUpkeep(t *testing.T) { } g.Eventually(receivedBytes, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.Equal(payload1)) - // check pipeline runs - var allRuns []pipeline.Run - for _, node := range nodes { - runs, err2 := node.App.PipelineORM().GetAllRuns() - require.NoError(t, err2) - allRuns = append(allRuns, runs...) - } - require.GreaterOrEqual(t, len(allRuns), 1) + checkPipelineRuns(t, nodes, 1) // change payload _, err = upkeepContract.SetBytesToSend(carrol, payload2) @@ -203,63 +197,122 @@ func TestIntegration_KeeperPluginLogUpkeep(t *testing.T) { registry := deployKeeper21Registry(t, steve, backend, linkAddr, linkFeedAddr, gasFeedAddr) nodes := setupNodes(t, nodeKeys, registry, backend, steve) - - <-time.After(time.Second * 5) + // wait for nodes to start + // TODO: find a better way to do this + <-time.After(time.Second * 10) upkeeps := 1 _, err = linkToken.Transfer(sergey, carrol.From, big.NewInt(0).Mul(oneHunEth, big.NewInt(int64(upkeeps+1)))) require.NoError(t, err) - ids, _, contracts := deployUpkeeps(t, backend, carrol, steve, linkToken, registry, upkeeps) + + backend.Commit() + + ids, addrs, contracts := deployUpkeeps(t, backend, carrol, steve, linkToken, registry, upkeeps) require.Equal(t, upkeeps, len(ids)) - require.Equal(t, len(contracts), len(ids)) + require.Equal(t, len(ids), len(contracts)) + require.Equal(t, len(ids), len(addrs)) + backend.Commit() - go func(contracts []*log_upkeep_counter_wrapper.LogUpkeepCounter) { - <-time.After(time.Second * 5) - ctx := testutils.Context(t) - emits := 10 - for i := 0; i < emits || ctx.Err() != nil; i++ { - <-time.After(time.Second) - t.Logf("EvmRegistry: calling upkeep contracts to emit events. run: %d", i+1) - for _, contract := range contracts { - _, err = contract.Start(carrol) - require.NoError(t, err) - backend.Commit() - } + emits := 10 + go emitEvents(testutils.Context(t), t, emits, contracts, carrol, func() { + backend.Commit() + time.Sleep(3 * time.Second) + }) + + listener, done := listenPerformed(t, backend, registry, ids, int64(1)) + g.Eventually(listener, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.BeTrue()) + done() + + runs := checkPipelineRuns(t, nodes, 1*len(nodes)) // TODO: TBD + + t.Run("recover logs", func(t *testing.T) { + t.Skip() // TODO: fix test (fails in CI) + addr, contract := addrs[0], contracts[0] + upkeepID := registerUpkeep(t, registry, addr, carrol, steve, backend) + backend.Commit() + t.Logf("Registered new upkeep %s for address %s", upkeepID.String(), addr.String()) + // blockBeforeEmits := backend.Blockchain().CurrentBlock().Number.Uint64() + // Emit 100 logs in a burst + emits := 100 + emitEvents(testutils.Context(t), t, 100, []*log_upkeep_counter_wrapper.LogUpkeepCounter{contract}, carrol, func() {}) + // Mine enough blocks to ensre these logs don't fall into log provider range + dummyBlocks := 500 + for i := 0; i < dummyBlocks; i++ { + backend.Commit() + time.Sleep(time.Millisecond * 10) } - }(contracts) + t.Logf("Mined %d blocks", dummyBlocks) - performed := listenPerformed(t, backend, registry, ids) + // listener, done := listenPerformed(t, backend, registry, []*big.Int{upkeepID}, int64(blockBeforeEmits)) + // defer done() + // g.Eventually(listener, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.BeTrue()) - receivedPerformedEvents := func() bool { - count := 0 - performed.Range(func(key, value interface{}) bool { - count++ - return true - }) - return count > 0 + expectedPostRecover := runs + emits // TODO: TBD + waitPipelineRuns(t, nodes, expectedPostRecover, testutils.WaitTimeout(t), cltest.DBPollingInterval) + + }) +} + +func waitPipelineRuns(t *testing.T, nodes []Node, n int, timeout, interval time.Duration) { + ctx, cancel := context.WithTimeout(testutils.Context(t), timeout) + defer cancel() + var allRuns []pipeline.Run + for len(allRuns) < n && ctx.Err() == nil { + allRuns = []pipeline.Run{} + for _, node := range nodes { + runs, err := node.App.PipelineORM().GetAllRuns() + require.NoError(t, err) + allRuns = append(allRuns, runs...) + } + time.Sleep(interval) } - g.Eventually(receivedPerformedEvents, testutils.WaitTimeout(t), cltest.DBPollingInterval).Should(gomega.BeTrue()) + runs := len(allRuns) + t.Logf("found %d pipeline runs", runs) + require.GreaterOrEqual(t, runs, n) +} - // check pipeline runs +func checkPipelineRuns(t *testing.T, nodes []Node, n int) int { var allRuns []pipeline.Run for _, node := range nodes { runs, err2 := node.App.PipelineORM().GetAllRuns() require.NoError(t, err2) allRuns = append(allRuns, runs...) } + runs := len(allRuns) + t.Logf("found %d pipeline runs", runs) + require.GreaterOrEqual(t, runs, n) + return runs +} - require.GreaterOrEqual(t, len(allRuns), 1) +func emitEvents(ctx context.Context, t *testing.T, n int, contracts []*log_upkeep_counter_wrapper.LogUpkeepCounter, carrol *bind.TransactOpts, afterEmit func()) { + for i := 0; i < n && ctx.Err() == nil; i++ { + for _, contract := range contracts { + // t.Logf("[automation-ocr3 | EvmRegistry] calling upkeep contracts to emit events. run: %d; contract addr: %s", i+1, contract.Address().Hex()) + _, err := contract.Start(carrol) + require.NoError(t, err) + } + afterEmit() + } } -func listenPerformed(t *testing.T, backend *backends.SimulatedBackend, registry *iregistry21.IKeeperRegistryMaster, ids []*big.Int) *sync.Map { - performed := &sync.Map{} +func mapListener(m *sync.Map, n int) func() bool { + return func() bool { + count := 0 + m.Range(func(key, value interface{}) bool { + count++ + return true + }) + return count > n + } +} +func listenPerformed(t *testing.T, backend *backends.SimulatedBackend, registry *iregistry21.IKeeperRegistryMaster, ids []*big.Int, startBlock int64) (func() bool, func()) { + cache := &sync.Map{} + ctx, cancel := context.WithCancel(testutils.Context(t)) + start := startBlock go func() { - ctx, cancel := context.WithCancel(testutils.Context(t)) - defer cancel() - for ctx.Err() == nil { bl := backend.Blockchain().CurrentBlock().Number.Uint64() sc := make([]bool, len(ids)) @@ -267,21 +320,26 @@ func listenPerformed(t *testing.T, backend *backends.SimulatedBackend, registry sc[i] = true } iter, err := registry.FilterUpkeepPerformed(&bind.FilterOpts{ - Start: 0, + Start: uint64(start), End: &bl, - Context: testutils.Context(t), + Context: ctx, }, ids, sc) + if ctx.Err() != nil { + return + } require.NoError(t, err) for iter.Next() { if iter.Event != nil { - t.Log("EvmRegistry: upkeep performed event emitted") - performed.Store(iter.Event.Id, true) + t.Logf("[automation-ocr3 | EvmRegistry] upkeep performed event emitted for id %s", iter.Event.Id.String()) + cache.Store(iter.Event.Id.String(), true) } } + require.NoError(t, iter.Close()) time.Sleep(time.Second) } }() - return performed + + return mapListener(cache, 0), cancel } func setupNodes(t *testing.T, nodeKeys [5]ethkey.KeyV2, registry *iregistry21.IKeeperRegistryMaster, backend *backends.SimulatedBackend, usr *bind.TransactOpts) []Node { @@ -386,8 +444,7 @@ func setupNodes(t *testing.T, nodeKeys [5]ethkey.KeyV2, registry *iregistry21.IK t.FailNow() } - // TODO: Use ocr3confighelper instead - signers, transmitters, threshold, onchainConfig, offchainConfigVersion, offchainConfig, err := confighelper.ContractSetConfigArgsForTestsOCR3( + signers, transmitters, threshold, onchainConfig, offchainConfigVersion, offchainConfig, err := ocr3confighelper.ContractSetConfigArgsForTests( 5*time.Second, // deltaProgress time.Duration, 10*time.Second, // deltaResend time.Duration, 100*time.Millisecond, // deltaInitial time.Duration, @@ -448,21 +505,8 @@ func deployUpkeeps(t *testing.T, backend *backends.SimulatedBackend, carrol, ste big.NewInt(100000), ) require.NoError(t, err) - logTriggerConfigType := abi.MustNewType("tuple(address contractAddress, uint8 filterSelector, bytes32 topic0, bytes32 topic1, bytes32 topic2, bytes32 topic3)") - logTriggerConfig, err := abi.Encode(map[string]interface{}{ - "contractAddress": upkeepAddr, - "filterSelector": 0, // no indexed topics filtered - "topic0": "0x3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d", // event sig for Trigger() - "topic1": "0x", - "topic2": "0x", - "topic3": "0x", - }, logTriggerConfigType) - require.NoError(t, err) - registrationTx, err := registry.RegisterUpkeep(steve, upkeepAddr, 2_500_000, carrol.From, 1, []byte{}, logTriggerConfig, []byte{}) - require.NoError(t, err) - backend.Commit() - upkeepID := getUpkeepIdFromTx21(t, registry, registrationTx, backend) + upkeepID := registerUpkeep(t, registry, upkeepAddr, carrol, steve, backend) // Fund the upkeep _, err = linkToken.Approve(carrol, registry.Address(), oneHunEth) @@ -478,6 +522,26 @@ func deployUpkeeps(t *testing.T, backend *backends.SimulatedBackend, carrol, ste return ids, addrs, contracts } +func registerUpkeep(t *testing.T, registry *iregistry21.IKeeperRegistryMaster, upkeepAddr common.Address, carrol, steve *bind.TransactOpts, backend *backends.SimulatedBackend) *big.Int { + logTriggerConfigType := abi.MustNewType("tuple(address contractAddress, uint8 filterSelector, bytes32 topic0, bytes32 topic1, bytes32 topic2, bytes32 topic3)") + logTriggerConfig, err := abi.Encode(map[string]interface{}{ + "contractAddress": upkeepAddr, + "filterSelector": 0, // no indexed topics filtered + "topic0": "0x3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d", // event sig for Trigger() + "topic1": "0x", + "topic2": "0x", + "topic3": "0x", + }, logTriggerConfigType) + require.NoError(t, err) + + registrationTx, err := registry.RegisterUpkeep(steve, upkeepAddr, 2_500_000, carrol.From, 1, []byte{}, logTriggerConfig, []byte{}) + require.NoError(t, err) + backend.Commit() + upkeepID := getUpkeepIdFromTx21(t, registry, registrationTx, backend) + + return upkeepID +} + func deployKeeper21Registry( t *testing.T, auth *bind.TransactOpts, diff --git a/core/services/ocr2/plugins/ocr2keeper/util.go b/core/services/ocr2/plugins/ocr2keeper/util.go index 3665dc39e52..5934ed45df2 100644 --- a/core/services/ocr2/plugins/ocr2keeper/util.go +++ b/core/services/ocr2/plugins/ocr2keeper/util.go @@ -3,13 +3,11 @@ package ocr2keeper import ( "fmt" - "github.com/smartcontractkit/libocr/offchainreporting2plus/ocr3types" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ocr2keepers20 "github.com/smartcontractkit/ocr2keepers/pkg/v2" ocr2keepers20coordinator "github.com/smartcontractkit/ocr2keepers/pkg/v2/coordinator" ocr2keepers20polling "github.com/smartcontractkit/ocr2keepers/pkg/v2/observer/polling" ocr2keepers20runner "github.com/smartcontractkit/ocr2keepers/pkg/v2/runner" - ocr2keepers21plugin "github.com/smartcontractkit/ocr2keepers/pkg/v3/plugin" "github.com/smartcontractkit/sqlx" "github.com/smartcontractkit/chainlink-relay/pkg/types" @@ -23,7 +21,6 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/models" kevm20 "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm20" kevm21 "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21" - "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" ) @@ -116,41 +113,23 @@ func EVMDependencies21( pr pipeline.Runner, mc *models.MercuryCredentials, keyring ocrtypes.OnchainKeyring, -) (evmrelay.OCR2KeeperProvider, *kevm21.EvmRegistry, Encoder21, *kevm21.TransmitEventProvider, ocr2keepers21.LogEventProvider, ocr3types.OnchainKeyring[ocr2keepers21plugin.AutomationReportInfo], *kevm21.BlockSubscriber, ocr2keepers21.PayloadBuilder, ocr2keepers21.UpkeepStateUpdater, ocr2keepers21.ConditionalUpkeepProvider, error) { +) (evmrelay.OCR2KeeperProvider, kevm21.AutomationServices, error) { var err error var keeperProvider evmrelay.OCR2KeeperProvider - var registry *kevm21.EvmRegistry - var encoder *kevm21.EVMAutomationEncoder21 oSpec := spec.OCR2OracleSpec - // the provider will be returned as a dependency if keeperProvider, err = EVMProvider(db, chain, lggr, spec, pr); err != nil { - return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err + return nil, nil, err } - bs := kevm21.NewBlockSubscriber(chain.HeadBroadcaster(), chain.LogPoller(), lggr) rAddr := ethkey.MustEIP55Address(oSpec.ContractID).Address() - if registry, encoder, err = kevm21.NewEVMRegistryService(rAddr, chain, mc, bs, lggr); err != nil { - return nil, nil, nil, nil, nil, nil, nil, nil, nil, nil, err + services, err := kevm21.New(rAddr, chain, mc, keyring, lggr) + if err != nil { + return nil, nil, err } - pb := kevm21.NewPayloadBuilder(lggr) - scanner := upkeepstate.NewPerformedEventsScanner( - lggr, - chain.LogPoller(), - rAddr, - ) - us := upkeepstate.NewUpkeepStateStore(lggr, scanner) - up := kevm21.NewUpkeepProvider(registry, chain.LogPoller()) - - // lookback blocks is hard coded and should provide ample time for logs - // to be detected in most cases - var lookbackBlocks int64 = 250 - // TODO: accept a version of the registry contract and use the correct interfaces - logTransmitter, err := kevm21.NewTransmitEventProvider(lggr, chain.LogPoller(), rAddr, chain.Client(), lookbackBlocks) - - return keeperProvider, registry, encoder, logTransmitter, registry.LogEventProvider(), kevm21.NewOnchainKeyringV3Wrapper(keyring), bs, pb, us, up, err + return keeperProvider, services, err } func FilterNamesFromSpec21(spec *job.OCR2OracleSpec) (names []string, err error) { @@ -158,5 +137,5 @@ func FilterNamesFromSpec21(spec *job.OCR2OracleSpec) (names []string, err error) if err != nil { return nil, err } - return []string{kevm21.TransmitEventProviderFilterName(addr.Address()), kevm21.UpkeepFilterName(addr.Address())}, err + return []string{kevm21.TransmitEventProviderFilterName(addr.Address()), kevm21.RegistryUpkeepFilterName(addr.Address())}, err } diff --git a/go.mod b/go.mod index 35c7361325b..396af2a2cb4 100644 --- a/go.mod +++ b/go.mod @@ -70,7 +70,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.10 + github.com/smartcontractkit/ocr2keepers v0.7.15 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index 7db387da245..907b2bd48d4 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= -github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.15 h1:MihIDmSpp62n+6NWQplNJAdD2MXs5BKh4EFOwNhAd1k= +github.com/smartcontractkit/ocr2keepers v0.7.15/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index e8f2b7138d7..142efc37720 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.3 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.10 + github.com/smartcontractkit/ocr2keepers v0.7.15 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.9 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index f36904df940..2e1969d592d 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.10 h1:v0DsX13gAxtTbhcAlPvM0fjR9BlT7n4BkHJ6S8HAquQ= -github.com/smartcontractkit/ocr2keepers v0.7.10/go.mod h1:y5QUa8sHmrqz/LYIueB5RL8aeO71kh4F9BfaJ8rZHt0= +github.com/smartcontractkit/ocr2keepers v0.7.15 h1:MihIDmSpp62n+6NWQplNJAdD2MXs5BKh4EFOwNhAd1k= +github.com/smartcontractkit/ocr2keepers v0.7.15/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From b0673e88189de0c228c95cf3db4d17d9f10edf45 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Mon, 21 Aug 2023 15:41:42 +0300 Subject: [PATCH 216/270] TT-426 fix direct request reorg test (#10268) --- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +-- integration-tests/reorg/reorg_test.go | 44 +++++++++++++++++++++------ 3 files changed, 37 insertions(+), 13 deletions(-) diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 142efc37720..59507765c3e 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -381,7 +381,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 2e1969d592d..e4baae60a59 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2241,8 +2241,8 @@ github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce67266 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d h1:gUaXYfDsXMAjMJj1k1Nm3EGZIfLVigMibi+4aj8az7o= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/integration-tests/reorg/reorg_test.go b/integration-tests/reorg/reorg_test.go index 1a1deed2734..d6ac5ce1cf1 100644 --- a/integration-tests/reorg/reorg_test.go +++ b/integration-tests/reorg/reorg_test.go @@ -23,15 +23,34 @@ import ( ctfClient "github.com/smartcontractkit/chainlink-testing-framework/client" "github.com/smartcontractkit/chainlink-testing-framework/utils" + "context" + "github.com/onsi/gomega" + "github.com/rs/zerolog/log" "github.com/smartcontractkit/chainlink/integration-tests/actions" "github.com/smartcontractkit/chainlink/integration-tests/client" "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/networks" +) + +const ( + baseDRTOML = ` +[Feature] +LogPoller = true +` + networkDRTOML = ` +Enabled = true +FinalityDepth = %s +LogPollInterval = '1s' + +[EVM.HeadTracker] +HistoryDepth = %s +` ) const ( EVMFinalityDepth = "200" EVMTrackerHistoryDepth = "400" - reorgBlocks = 50 + reorgBlocks = 10 minIncomingConfirmations = "200" timeout = "15m" interval = "2s" @@ -102,14 +121,10 @@ func TestDirectRequestReorg(t *testing.T) { // related https://app.shortcut.com/chainlinklabs/story/38295/creating-an-evm-chain-via-cli-or-api-immediately-polling-the-nodes-and-returning-an-error // node must work and reconnect even if network is not working time.Sleep(90 * time.Second) + activeEVMNetwork = networks.SimulatedEVMNonDev + netCfg := fmt.Sprintf(networkDRTOML, EVMFinalityDepth, EVMTrackerHistoryDepth) chainlinkDeployment, err := chainlink.NewDeployment(1, map[string]interface{}{ - "env": map[string]interface{}{ - "eth_url": "ws://geth-ethereum-geth:8546", - "eth_http_url": "http://geth-ethereum-geth:8544", - "eth_chain_id": "1337", - "ETH_FINALITY_DEPTH": EVMFinalityDepth, - "ETH_HEAD_TRACKER_HISTORY_DEPTH": EVMTrackerHistoryDepth, - }, + "toml": client.AddNetworkDetailedConfig(baseDRTOML, netCfg, activeEVMNetwork), }) require.NoError(t, err, "Error building Chainlink deployment") err = testEnvironment.AddHelmCharts(chainlinkDeployment).Run() @@ -154,11 +169,11 @@ func TestDirectRequestReorg(t *testing.T) { err = chainlinkNodes[0].MustCreateBridge(&bta) require.NoError(t, err, "Creating bridge shouldn't fail") - os := &client.DirectRequestTxPipelineSpec{ + drps := &client.DirectRequestTxPipelineSpec{ BridgeTypeAttributes: bta, DataPath: "data,result", } - ost, err := os.String() + ost, err := drps.String() require.NoError(t, err, "Building observation source spec shouldn't fail") _, err = chainlinkNodes[0].MustCreateJob(&client.DirectRequestJobSpec{ @@ -199,4 +214,13 @@ func TestDirectRequestReorg(t *testing.T) { err = rc.WaitDepthReached() require.NoError(t, err, "Error waiting for depth to be reached") + + gom := gomega.NewGomegaWithT(t) + gom.Eventually(func(g gomega.Gomega) { + d, err := consumer.Data(context.Background()) + g.Expect(err).ShouldNot(gomega.HaveOccurred(), "Getting data from consumer contract shouldn't fail") + g.Expect(d).ShouldNot(gomega.BeNil(), "Expected the initial on chain data to be nil") + log.Debug().Int64("Data", d.Int64()).Msg("Found on chain") + g.Expect(d.Int64()).Should(gomega.BeNumerically("==", 5), "Expected the on-chain data to be 5, but found %d", d.Int64()) + }, timeout, interval).Should(gomega.Succeed()) } From 66f23303c4d9a63f1efac027ea6025ab7c1cbf4a Mon Sep 17 00:00:00 2001 From: "Essam A. Hassan" Date: Mon, 21 Aug 2023 15:03:37 +0200 Subject: [PATCH 217/270] Update relayer dep from orphaned commit (#10267) * update relayer dep from orphaned commit * go mod tidy everywhere --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 5627eb126e6..85b627c2933 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -298,7 +298,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 4f498b255ac..afd008a9542 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1430,8 +1430,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d h1:gUaXYfDsXMAjMJj1k1Nm3EGZIfLVigMibi+4aj8az7o= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/go.mod b/go.mod index 396af2a2cb4..dd6632b334d 100644 --- a/go.mod +++ b/go.mod @@ -66,7 +66,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 diff --git a/go.sum b/go.sum index 907b2bd48d4..db73ae99db4 100644 --- a/go.sum +++ b/go.sum @@ -1435,8 +1435,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc h1:4RZI/rozr+wXmny8IIMdsQYLwzXko3Leq/L1mcXljz8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230814175909-17597db0d6fc/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d h1:gUaXYfDsXMAjMJj1k1Nm3EGZIfLVigMibi+4aj8az7o= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= From d166ad94d817c5b1436b3901965d0db02f21fedf Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Mon, 21 Aug 2023 16:55:30 +0100 Subject: [PATCH 218/270] Update ocr2keepers (#10270) * Update ocr2keepers * update * update ocr2keepers --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- go.mod | 2 +- go.sum | 4 ++-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- 6 files changed, 9 insertions(+), 9 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 85b627c2933..da41fc877e2 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.15 + github.com/smartcontractkit/ocr2keepers v0.7.16 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index afd008a9542..576c425ecc9 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1442,8 +1442,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.15 h1:MihIDmSpp62n+6NWQplNJAdD2MXs5BKh4EFOwNhAd1k= -github.com/smartcontractkit/ocr2keepers v0.7.15/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= +github.com/smartcontractkit/ocr2keepers v0.7.16 h1:brSHJIlm2tD8lbxxJOFVhSmXGU8bKoUC/3CEaYCPd/U= +github.com/smartcontractkit/ocr2keepers v0.7.16/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/go.mod b/go.mod index dd6632b334d..e94d2bff56e 100644 --- a/go.mod +++ b/go.mod @@ -70,7 +70,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.15 + github.com/smartcontractkit/ocr2keepers v0.7.16 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 diff --git a/go.sum b/go.sum index db73ae99db4..7b5c074f4ee 100644 --- a/go.sum +++ b/go.sum @@ -1447,8 +1447,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.15 h1:MihIDmSpp62n+6NWQplNJAdD2MXs5BKh4EFOwNhAd1k= -github.com/smartcontractkit/ocr2keepers v0.7.15/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= +github.com/smartcontractkit/ocr2keepers v0.7.16 h1:brSHJIlm2tD8lbxxJOFVhSmXGU8bKoUC/3CEaYCPd/U= +github.com/smartcontractkit/ocr2keepers v0.7.16/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 59507765c3e..f3d77336646 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.15.3 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.15 + github.com/smartcontractkit/ocr2keepers v0.7.16 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.2.9 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index e4baae60a59..ea87cfd60bc 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.15 h1:MihIDmSpp62n+6NWQplNJAdD2MXs5BKh4EFOwNhAd1k= -github.com/smartcontractkit/ocr2keepers v0.7.15/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= +github.com/smartcontractkit/ocr2keepers v0.7.16 h1:brSHJIlm2tD8lbxxJOFVhSmXGU8bKoUC/3CEaYCPd/U= +github.com/smartcontractkit/ocr2keepers v0.7.16/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From be4e037e61f5473e71e1a0e547b8b614b12450bf Mon Sep 17 00:00:00 2001 From: Oliver Townsend <133903322+ogtownsend@users.noreply.github.com> Date: Mon, 21 Aug 2023 11:26:47 -0700 Subject: [PATCH 219/270] Start log trigger upkeeps in launch-and-test chaincli cmd (#10234) --- core/scripts/chaincli/handler/keeper.go | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/core/scripts/chaincli/handler/keeper.go b/core/scripts/chaincli/handler/keeper.go index 4db80829e2b..0cbc1525577 100644 --- a/core/scripts/chaincli/handler/keeper.go +++ b/core/scripts/chaincli/handler/keeper.go @@ -529,6 +529,7 @@ func (k *Keeper) deployUpkeeps(ctx context.Context, registryAddr common.Address, var upkeepAddr common.Address var deployUpkeepTx *types.Transaction var registerUpkeepTx *types.Transaction + var logUpkeepCounter *log_upkeep_counter_wrapper.LogUpkeepCounter var checkData []byte var err error switch k.cfg.UpkeepType { @@ -603,7 +604,7 @@ func (k *Keeper) deployUpkeeps(ctx context.Context, registryAddr common.Address, log.Fatal(i, upkeepAddr.Hex(), ": RegisterUpkeep failed - ", err) } case config.LogTrigger: - upkeepAddr, deployUpkeepTx, _, err = log_upkeep_counter_wrapper.DeployLogUpkeepCounter( + upkeepAddr, deployUpkeepTx, logUpkeepCounter, err = log_upkeep_counter_wrapper.DeployLogUpkeepCounter( k.buildTxOpts(ctx), k.client, big.NewInt(k.cfg.UpkeepTestRange), @@ -631,6 +632,16 @@ func (k *Keeper) deployUpkeeps(ctx context.Context, registryAddr common.Address, if err != nil { log.Fatal(i, upkeepAddr.Hex(), ": RegisterUpkeep failed - ", err) } + + // Start up log trigger cycle + logUpkeepStartTx, err := logUpkeepCounter.Start(k.buildTxOpts(ctx)) + if err != nil { + log.Fatal("failed to start log upkeep counter", err) + } + if err := k.waitTx(ctx, logUpkeepStartTx); err != nil { + log.Fatalf("Log upkeep Start() failed for upkeepId: %s, error is %s", upkeepAddr.Hex(), err.Error()) + } + log.Println(i, upkeepAddr.Hex(), ": Log upkeep successfully started - ", helpers.ExplorerLink(k.cfg.ChainID, logUpkeepStartTx.Hash())) default: log.Fatal("unexpected upkeep type") } From 3feeea2ea09f30ad223363015141efdd3150f564 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Mon, 21 Aug 2023 15:58:44 -0400 Subject: [PATCH 220/270] add test to ensure a user can pause, cancel, withdraw (#10194) --- .../test/v0.8/automation/KeeperRegistry2_1.test.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index a0d370919d7..c209d04387b 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -2863,6 +2863,18 @@ describe('KeeperRegistry2_1', () => { ) }) + describe('after the registration is paused, then cancelled', () => { + it('allows the admin to withdraw', async () => { + const balance = await registry.getBalance(upkeepId) + const payee = await payee1.getAddress() + await registry.connect(admin).pauseUpkeep(upkeepId) + await registry.connect(owner).cancelUpkeep(upkeepId) + await expect(() => + registry.connect(admin).withdrawFunds(upkeepId, payee), + ).to.changeTokenBalance(linkToken, payee1, balance) + }) + }) + describe('after the registration is cancelled', () => { beforeEach(async () => { await registry.connect(owner).cancelUpkeep(upkeepId) From 0fd84bc96f84418c56764342477fcac5ab11e363 Mon Sep 17 00:00:00 2001 From: Chunkai Yang Date: Mon, 21 Aug 2023 18:00:42 -0400 Subject: [PATCH 221/270] Fix foundry filter typo (#10269) --- .github/workflows/solidity-foundry.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/solidity-foundry.yml b/.github/workflows/solidity-foundry.yml index ff357312a6a..5c114c6e0ad 100644 --- a/.github/workflows/solidity-foundry.yml +++ b/.github/workflows/solidity-foundry.yml @@ -22,7 +22,7 @@ jobs: src: - 'contracts/src/v0.8/**/*' - '.github/workflows/solidity-foundry.yml' - - 'contacts/foundry.toml' + - 'contracts/foundry.toml' tests: strategy: From d8f7582ad72bb01826e2eba1dea2ffa4cd03c82e Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Mon, 21 Aug 2023 18:00:44 -0400 Subject: [PATCH 222/270] add check for zeroAddress in setConfig() (#10193) --- .../dev/automation/2_1/KeeperRegistry2_1.sol | 2 + .../automation/2_1/KeeperRegistryBase2_1.sol | 2 + .../2_1/interfaces/IKeeperRegistryMaster.sol | 6 ++- .../v0.8/automation/KeeperRegistry2_1.test.ts | 40 +++++++++++++++++++ .../i_keeper_registry_master_wrapper_2_1.go | 2 +- .../keeper_registry_logic_a_wrapper_2_1.go | 2 +- .../keeper_registry_logic_b_wrapper_2_1.go | 2 +- .../keeper_registry_wrapper_2_1.go | 4 +- ...rapper-dependency-versions-do-not-edit.txt | 8 ++-- 9 files changed, 57 insertions(+), 11 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol index 90e50beb02d..db3a9b14113 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistry2_1.sol @@ -279,9 +279,11 @@ contract KeeperRegistry2_1 is KeeperRegistryBase2_1, OCR2Abstract, Chainable, IE address temp; for (uint256 i = 0; i < signers.length; i++) { if (s_signers[signers[i]].active) revert RepeatedSigner(); + if (signers[i] == ZERO_ADDRESS) revert InvalidSigner(); s_signers[signers[i]] = Signer({active: true, index: uint8(i)}); temp = transmitters[i]; + if (temp == ZERO_ADDRESS) revert InvalidTransmitter(); transmitter = s_transmitters[temp]; if (transmitter.active) revert RepeatedTransmitter(); transmitter.active = true; diff --git a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol index 19c42cfe5c8..45501eaae95 100644 --- a/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/KeeperRegistryBase2_1.sol @@ -120,6 +120,8 @@ abstract contract KeeperRegistryBase2_1 is ConfirmedOwner, ExecutionPrevention { error InvalidPayee(); error InvalidRecipient(); error InvalidReport(); + error InvalidSigner(); + error InvalidTransmitter(); error InvalidTriggerType(); error MaxCheckDataSizeCanOnlyIncrease(); error MaxPerformDataSizeCanOnlyIncrease(); diff --git a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol index 9df7d8da14d..cab4d61c5b9 100644 --- a/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol +++ b/contracts/src/v0.8/dev/automation/2_1/interfaces/IKeeperRegistryMaster.sol @@ -1,4 +1,4 @@ -// abi-checksum: 0x0199025a18d5956b044baa2131c1d61dd2eef5eb6335edc00633d829045edb7c +// abi-checksum: 0x0ed34e4b36bd7b4a5447152c2d61491e6ba7ed944b11e4dfef4fea184708975e // SPDX-License-Identifier: MIT // !! THIS FILE WAS AUTOGENERATED BY abi-to-sol v0.6.6. SEE SOURCE BELOW. !! pragma solidity ^0.8.4; @@ -21,6 +21,8 @@ interface IKeeperRegistryMaster { error InvalidPayee(); error InvalidRecipient(); error InvalidReport(); + error InvalidSigner(); + error InvalidTransmitter(); error InvalidTrigger(); error InvalidTriggerType(); error MaxCheckDataSizeCanOnlyIncrease(); @@ -373,5 +375,5 @@ interface KeeperRegistryBase2_1 { // THIS FILE WAS AUTOGENERATED FROM THE FOLLOWING ABI JSON: /* -[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dedupKey","type":"bytes32"}],"name":"DedupKeyAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfigTypeSafe","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"dedupKey","type":"bytes32"}],"name":"hasDedupKey","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] +[{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicA","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[],"name":"ArrayHasNoEntries","type":"error"},{"inputs":[],"name":"CannotCancel","type":"error"},{"inputs":[],"name":"CheckDataExceedsLimit","type":"error"},{"inputs":[],"name":"ConfigDigestMismatch","type":"error"},{"inputs":[],"name":"DuplicateEntry","type":"error"},{"inputs":[],"name":"DuplicateSigners","type":"error"},{"inputs":[],"name":"GasLimitCanOnlyIncrease","type":"error"},{"inputs":[],"name":"GasLimitOutsideRange","type":"error"},{"inputs":[],"name":"IncorrectNumberOfFaultyOracles","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSignatures","type":"error"},{"inputs":[],"name":"IncorrectNumberOfSigners","type":"error"},{"inputs":[],"name":"IndexOutOfRange","type":"error"},{"inputs":[],"name":"InsufficientFunds","type":"error"},{"inputs":[],"name":"InvalidDataLength","type":"error"},{"inputs":[],"name":"InvalidPayee","type":"error"},{"inputs":[],"name":"InvalidRecipient","type":"error"},{"inputs":[],"name":"InvalidReport","type":"error"},{"inputs":[],"name":"InvalidSigner","type":"error"},{"inputs":[],"name":"InvalidTransmitter","type":"error"},{"inputs":[],"name":"InvalidTrigger","type":"error"},{"inputs":[],"name":"InvalidTriggerType","type":"error"},{"inputs":[],"name":"MaxCheckDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MaxPerformDataSizeCanOnlyIncrease","type":"error"},{"inputs":[],"name":"MigrationNotPermitted","type":"error"},{"inputs":[],"name":"NotAContract","type":"error"},{"inputs":[],"name":"OnlyActiveSigners","type":"error"},{"inputs":[],"name":"OnlyActiveTransmitters","type":"error"},{"inputs":[],"name":"OnlyCallableByAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByLINKToken","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByOwnerOrRegistrar","type":"error"},{"inputs":[],"name":"OnlyCallableByPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedAdmin","type":"error"},{"inputs":[],"name":"OnlyCallableByProposedPayee","type":"error"},{"inputs":[],"name":"OnlyCallableByUpkeepPrivilegeManager","type":"error"},{"inputs":[],"name":"OnlyPausedUpkeep","type":"error"},{"inputs":[],"name":"OnlySimulatedBackend","type":"error"},{"inputs":[],"name":"OnlyUnpausedUpkeep","type":"error"},{"inputs":[],"name":"ParameterLengthError","type":"error"},{"inputs":[],"name":"PaymentGreaterThanAllLINK","type":"error"},{"inputs":[],"name":"ReentrantCall","type":"error"},{"inputs":[],"name":"RegistryPaused","type":"error"},{"inputs":[],"name":"RepeatedSigner","type":"error"},{"inputs":[],"name":"RepeatedTransmitter","type":"error"},{"inputs":[{"internalType":"bytes","name":"reason","type":"bytes"}],"name":"TargetCheckReverted","type":"error"},{"inputs":[],"name":"TooManyOracles","type":"error"},{"inputs":[],"name":"TranscoderNotSet","type":"error"},{"inputs":[],"name":"UpkeepAlreadyExists","type":"error"},{"inputs":[],"name":"UpkeepCancelled","type":"error"},{"inputs":[],"name":"UpkeepNotCanceled","type":"error"},{"inputs":[],"name":"UpkeepNotNeeded","type":"error"},{"inputs":[],"name":"ValueNotChanged","type":"error"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"admin","type":"address"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"AdminPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"CancelledUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint32","name":"previousConfigBlockNumber","type":"uint32"},{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint64","name":"configCount","type":"uint64"},{"indexed":false,"internalType":"address[]","name":"signers","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"uint8","name":"f","type":"uint8"},{"indexed":false,"internalType":"bytes","name":"onchainConfig","type":"bytes"},{"indexed":false,"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"ConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"bytes32","name":"dedupKey","type":"bytes32"}],"name":"DedupKeyAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"FundsAdded","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":false,"internalType":"address","name":"to","type":"address"}],"name":"FundsWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"InsufficientFundsUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"uint96","name":"amount","type":"uint96"}],"name":"OwnerFundsWithdrawn","type":"event"},{"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":false,"internalType":"address","name":"account","type":"address"}],"name":"Paused","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address[]","name":"transmitters","type":"address[]"},{"indexed":false,"internalType":"address[]","name":"payees","type":"address[]"}],"name":"PayeesUpdated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"PayeeshipTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"transmitter","type":"address"},{"indexed":true,"internalType":"uint256","name":"amount","type":"uint256"},{"indexed":true,"internalType":"address","name":"to","type":"address"},{"indexed":false,"internalType":"address","name":"payee","type":"address"}],"name":"PaymentWithdrawn","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"ReorgedUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"StaleUpkeepReport","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"indexed":false,"internalType":"uint32","name":"epoch","type":"uint32"}],"name":"Transmitted","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"address","name":"account","type":"address"}],"name":"Unpaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferRequested","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"address","name":"from","type":"address"},{"indexed":true,"internalType":"address","name":"to","type":"address"}],"name":"UpkeepAdminTransferred","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"uint64","name":"atBlockHeight","type":"uint64"}],"name":"UpkeepCanceled","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"UpkeepCheckDataSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint96","name":"gasLimit","type":"uint96"}],"name":"UpkeepGasLimitSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"remainingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"destination","type":"address"}],"name":"UpkeepMigrated","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"UpkeepOffchainConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepPaused","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":true,"internalType":"bool","name":"success","type":"bool"},{"indexed":false,"internalType":"uint96","name":"totalPayment","type":"uint96"},{"indexed":false,"internalType":"uint256","name":"gasUsed","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"gasOverhead","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"trigger","type":"bytes"}],"name":"UpkeepPerformed","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"privilegeConfig","type":"bytes"}],"name":"UpkeepPrivilegeConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint256","name":"startingBalance","type":"uint256"},{"indexed":false,"internalType":"address","name":"importedFrom","type":"address"}],"name":"UpkeepReceived","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"uint32","name":"performGas","type":"uint32"},{"indexed":false,"internalType":"address","name":"admin","type":"address"}],"name":"UpkeepRegistered","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"},{"indexed":false,"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"UpkeepTriggerConfigSet","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"uint256","name":"id","type":"uint256"}],"name":"UpkeepUnpaused","type":"event"},{"stateMutability":"nonpayable","type":"fallback"},{"inputs":[],"name":"acceptOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"fallbackTo","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDetails","outputs":[{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"blockNumber","type":"uint32"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"latestConfigDigestAndEpoch","outputs":[{"internalType":"bool","name":"scanLogs","type":"bool"},{"internalType":"bytes32","name":"configDigest","type":"bytes32"},{"internalType":"uint32","name":"epoch","type":"uint32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"sender","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"onTokenTransfer","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"owner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"internalType":"bytes","name":"onchainConfigBytes","type":"bytes"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"onchainConfig","type":"tuple"},{"internalType":"uint64","name":"offchainConfigVersion","type":"uint64"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"setConfigTypeSafe","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"performData","type":"bytes"}],"name":"simulatePerformUpkeep","outputs":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"to","type":"address"}],"name":"transferOwnership","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes32[3]","name":"reportContext","type":"bytes32[3]"},{"internalType":"bytes","name":"rawReport","type":"bytes"},{"internalType":"bytes32[]","name":"rs","type":"bytes32[]"},{"internalType":"bytes32[]","name":"ss","type":"bytes32[]"},{"internalType":"bytes32","name":"rawVs","type":"bytes32"}],"name":"transmit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"typeAndVersion","outputs":[{"internalType":"string","name":"","type":"string"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract KeeperRegistryLogicB2_1","name":"logicB","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint96","name":"amount","type":"uint96"}],"name":"addFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"cancelUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes[]","name":"values","type":"bytes[]"},{"internalType":"bytes","name":"extraData","type":"bytes"}],"name":"checkCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerData","type":"bytes"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"checkUpkeep","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"},{"internalType":"uint256","name":"gasLimit","type":"uint256"},{"internalType":"uint256","name":"fastGasWei","type":"uint256"},{"internalType":"uint256","name":"linkNative","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"payload","type":"bytes"}],"name":"executeCallback","outputs":[{"internalType":"bool","name":"upkeepNeeded","type":"bool"},{"internalType":"bytes","name":"performData","type":"bytes"},{"internalType":"enum KeeperRegistryBase2_1.UpkeepFailureReason","name":"upkeepFailureReason","type":"uint8"},{"internalType":"uint256","name":"gasUsed","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256[]","name":"ids","type":"uint256[]"},{"internalType":"address","name":"destination","type":"address"}],"name":"migrateUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"bytes","name":"encodedUpkeeps","type":"bytes"}],"name":"receiveUpkeeps","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"gasLimit","type":"uint32"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"name":"registerUpkeep","outputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"triggerConfig","type":"bytes"}],"name":"setUpkeepTriggerConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"mode","type":"uint8"},{"internalType":"address","name":"link","type":"address"},{"internalType":"address","name":"linkNativeFeed","type":"address"},{"internalType":"address","name":"fastGasFeed","type":"address"},{"internalType":"address","name":"automationForwarderLogic","type":"address"}],"stateMutability":"nonpayable","type":"constructor"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"}],"name":"acceptPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"acceptUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"startIndex","type":"uint256"},{"internalType":"uint256","name":"maxCount","type":"uint256"}],"name":"getActiveUpkeepIDs","outputs":[{"internalType":"uint256[]","name":"","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"}],"name":"getAdminPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getAutomationForwarderLogic","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getBalance","outputs":[{"internalType":"uint96","name":"balance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCancellationDelay","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getConditionalGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getFastGasFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepID","type":"uint256"}],"name":"getForwarder","outputs":[{"internalType":"contract IAutomationForwarder","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLinkNativeFeedAddress","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLogGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"triggerType","type":"uint8"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"getMaxPaymentForGas","outputs":[{"internalType":"uint96","name":"maxPayment","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalance","outputs":[{"internalType":"uint96","name":"","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getMinBalanceForUpkeep","outputs":[{"internalType":"uint96","name":"minBalance","type":"uint96"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getMode","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Mode","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"}],"name":"getPeerRegistryMigrationPermission","outputs":[{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getPerPerformByteGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"getPerSignerGasOverhead","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getSignerInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getState","outputs":[{"components":[{"internalType":"uint32","name":"nonce","type":"uint32"},{"internalType":"uint96","name":"ownerLinkBalance","type":"uint96"},{"internalType":"uint256","name":"expectedLinkBalance","type":"uint256"},{"internalType":"uint96","name":"totalPremium","type":"uint96"},{"internalType":"uint256","name":"numUpkeeps","type":"uint256"},{"internalType":"uint32","name":"configCount","type":"uint32"},{"internalType":"uint32","name":"latestConfigBlockNumber","type":"uint32"},{"internalType":"bytes32","name":"latestConfigDigest","type":"bytes32"},{"internalType":"uint32","name":"latestEpoch","type":"uint32"},{"internalType":"bool","name":"paused","type":"bool"}],"internalType":"struct KeeperRegistryBase2_1.State","name":"state","type":"tuple"},{"components":[{"internalType":"uint32","name":"paymentPremiumPPB","type":"uint32"},{"internalType":"uint32","name":"flatFeeMicroLink","type":"uint32"},{"internalType":"uint32","name":"checkGasLimit","type":"uint32"},{"internalType":"uint24","name":"stalenessSeconds","type":"uint24"},{"internalType":"uint16","name":"gasCeilingMultiplier","type":"uint16"},{"internalType":"uint96","name":"minUpkeepSpend","type":"uint96"},{"internalType":"uint32","name":"maxPerformGas","type":"uint32"},{"internalType":"uint32","name":"maxCheckDataSize","type":"uint32"},{"internalType":"uint32","name":"maxPerformDataSize","type":"uint32"},{"internalType":"uint32","name":"maxRevertDataSize","type":"uint32"},{"internalType":"uint256","name":"fallbackGasPrice","type":"uint256"},{"internalType":"uint256","name":"fallbackLinkPrice","type":"uint256"},{"internalType":"address","name":"transcoder","type":"address"},{"internalType":"address[]","name":"registrars","type":"address[]"},{"internalType":"address","name":"upkeepPrivilegeManager","type":"address"}],"internalType":"struct KeeperRegistryBase2_1.OnchainConfig","name":"config","type":"tuple"},{"internalType":"address[]","name":"signers","type":"address[]"},{"internalType":"address[]","name":"transmitters","type":"address[]"},{"internalType":"uint8","name":"f","type":"uint8"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"query","type":"address"}],"name":"getTransmitterInfo","outputs":[{"internalType":"bool","name":"active","type":"bool"},{"internalType":"uint8","name":"index","type":"uint8"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"uint96","name":"lastCollected","type":"uint96"},{"internalType":"address","name":"payee","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getTriggerType","outputs":[{"internalType":"enum KeeperRegistryBase2_1.Trigger","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"getUpkeep","outputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"uint32","name":"performGas","type":"uint32"},{"internalType":"bytes","name":"checkData","type":"bytes"},{"internalType":"uint96","name":"balance","type":"uint96"},{"internalType":"address","name":"admin","type":"address"},{"internalType":"uint64","name":"maxValidBlocknumber","type":"uint64"},{"internalType":"uint32","name":"lastPerformedBlockNumber","type":"uint32"},{"internalType":"uint96","name":"amountSpent","type":"uint96"},{"internalType":"bool","name":"paused","type":"bool"},{"internalType":"bytes","name":"offchainConfig","type":"bytes"}],"internalType":"struct KeeperRegistryBase2_1.UpkeepInfo","name":"upkeepInfo","type":"tuple"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepPrivilegeConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"}],"name":"getUpkeepTriggerConfig","outputs":[{"internalType":"bytes","name":"","type":"bytes"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"dedupKey","type":"bytes32"}],"name":"hasDedupKey","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"pause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"pauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"recoverFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"admin","type":"address"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setAdminPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"payees","type":"address[]"}],"name":"setPayees","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"peer","type":"address"},{"internalType":"enum KeeperRegistryBase2_1.MigrationPermission","name":"permission","type":"uint8"}],"name":"setPeerRegistryMigrationPermission","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"newCheckData","type":"bytes"}],"name":"setUpkeepCheckData","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"uint32","name":"gasLimit","type":"uint32"}],"name":"setUpkeepGasLimit","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"bytes","name":"config","type":"bytes"}],"name":"setUpkeepOffchainConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"upkeepId","type":"uint256"},{"internalType":"bytes","name":"newPrivilegeConfig","type":"bytes"}],"name":"setUpkeepPrivilegeConfig","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"transmitter","type":"address"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferPayeeship","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"proposed","type":"address"}],"name":"transferUpkeepAdmin","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"unpause","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"}],"name":"unpauseUpkeep","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"upkeepTranscoderVersion","outputs":[{"internalType":"enum UpkeepFormat","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[],"name":"upkeepVersion","outputs":[{"internalType":"uint8","name":"","type":"uint8"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"id","type":"uint256"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[],"name":"withdrawOwnerFunds","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"}],"name":"withdrawPayment","outputs":[],"stateMutability":"nonpayable","type":"function"}] */ diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index c209d04387b..f51ce4133b4 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -3553,6 +3553,46 @@ describe('KeeperRegistry2_1', () => { ) }) + it('reverts if signers or transmitters are the zero address', async () => { + await evmRevert( + registry + .connect(owner) + .setConfigTypeSafe( + [randomAddress(), randomAddress(), randomAddress(), zeroAddress], + [ + randomAddress(), + randomAddress(), + randomAddress(), + randomAddress(), + ], + f, + newConfig, + offchainVersion, + offchainBytes, + ), + 'InvalidSigner()', + ) + + await evmRevert( + registry + .connect(owner) + .setConfigTypeSafe( + [ + randomAddress(), + randomAddress(), + randomAddress(), + randomAddress(), + ], + [randomAddress(), randomAddress(), randomAddress(), zeroAddress], + f, + newConfig, + offchainVersion, + offchainBytes, + ), + 'InvalidTransmitter()', + ) + }) + it('updates the onchainConfig and configDigest', async () => { const old = await registry.getState() const oldConfig = old.config diff --git a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go index 67de7e61208..c43f32103de 100644 --- a/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go +++ b/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1/i_keeper_registry_master_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var IKeeperRegistryMasterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"hasDedupKey\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTransmitter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"uint8\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"hasDedupKey\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", } var IKeeperRegistryMasterABI = IKeeperRegistryMasterMetaData.ABI diff --git a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go index 96b2442aa4a..48c4d75e8b3 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_a_wrapper_2_1/keeper_registry_logic_a_wrapper_2_1.go @@ -31,7 +31,7 @@ var ( ) var KeeperRegistryLogicAMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicB\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTransmitter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"addFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"cancelUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerData\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"gasLimit\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fastGasWei\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"linkNative\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"}],\"name\":\"executeCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"},{\"internalType\":\"enumKeeperRegistryBase2_1.UpkeepFailureReason\",\"name\":\"upkeepFailureReason\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256[]\",\"name\":\"ids\",\"type\":\"uint256[]\"},{\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"migrateUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"encodedUpkeeps\",\"type\":\"bytes\"}],\"name\":\"receiveUpkeeps\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"registerUpkeep\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepTriggerConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", Bin: "0x6101406040523480156200001257600080fd5b50604051620061d1380380620061d18339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051615d18620004b96000396000818161010e01526101a90152600081816103e10152611fa10152600081816135370152818161376d015281816139b50152613b5d015260006130e1015260006131c5015260008181611de301526123af0152615d186000f3fe60806040523480156200001157600080fd5b50600436106200010c5760003560e01c806385c1b0ba11620000a5578063c8048022116200006f578063c804802214620002b7578063ce7dc5b414620002ce578063f2fde38b14620002e5578063f7d334ba14620002fc576200010c565b806385c1b0ba14620002535780638da5cb5b146200026a5780638e86139b1462000289578063948108f714620002a0576200010c565b80634ee88d3511620000e75780634ee88d3514620001ef5780636ded9eae146200020657806371791aa0146200021d57806379ba50971462000249576200010c565b806328f32f38146200015457806329c5efad146200017e578063349e8cca14620001a7575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e8080156200014d573d6000f35b3d6000fd5b005b6200016b62000165366004620041ea565b62000313565b6040519081526020015b60405180910390f35b620001956200018f366004620042d0565b6200068c565b604051620001759493929190620043f8565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200162000175565b620001526200020036600462004435565b62000930565b6200016b6200021736600462004485565b62000998565b620002346200022e366004620042d0565b620009fe565b60405162000175979695949392919062004538565b62000152620010f0565b62000152620002643660046200458a565b620011f3565b60005473ffffffffffffffffffffffffffffffffffffffff16620001c9565b620001526200029a36600462004617565b62001e64565b62000152620002b13660046200467a565b620021ec565b62000152620002c8366004620046a9565b6200247f565b62000195620002df3660046200477f565b62002846565b62000152620002f6366004620047f6565b62002916565b620002346200030d366004620046a9565b6200292e565b6000805473ffffffffffffffffffffffffffffffffffffffff163314801590620003475750620003456009336200296c565b155b156200037f576040517fd48b678b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff89163b620003ce576040517f09ee12d500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b620003d986620029a0565b9050600089307f00000000000000000000000000000000000000000000000000000000000000006040516200040e9062003f7b565b73ffffffffffffffffffffffffffffffffffffffff938416815291831660208301529091166040820152606001604051809103906000f08015801562000458573d6000803e3d6000fd5b5090506200051f826040518060e001604052806000151581526020018c63ffffffff16815260200163ffffffff801681526020018473ffffffffffffffffffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff16815260200160006bffffffffffffffffffffffff168152602001600063ffffffff168152508a89898080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508b92508a915062002b449050565b6014805474010000000000000000000000000000000000000000900463ffffffff1690806200054e8362004845565b91906101000a81548163ffffffff021916908363ffffffff16021790555050817fbae366358c023f887e791d7a62f2e4316f1026bd77f6fb49501a917b3bc5d0128a8a604051620005c792919063ffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a2817fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d878760405162000603929190620048b4565b60405180910390a2817f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d5664856040516200063d9190620048ca565b60405180910390a2817f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf485084604051620006779190620048ca565b60405180910390a25098975050505050505050565b600060606000806200069d62002f1f565b600086815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff90811694830194909452650100000000008104841694820194909452690100000000000000000090930473ffffffffffffffffffffffffffffffffffffffff166060840152600101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a0840152780100000000000000000000000000000000000000000000000090041660c08201525a9150600080826060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620007b7573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620007dd9190620048ec565b73ffffffffffffffffffffffffffffffffffffffff166013600101600c9054906101000a900463ffffffff1663ffffffff16896040516200081f91906200490c565b60006040518083038160008787f1925050503d80600081146200085f576040519150601f19603f3d011682016040523d82523d6000602084013e62000864565b606091505b50915091505a6200087690856200492a565b935081620008a157600060405180602001604052806000815250600796509650965050505062000927565b80806020019051810190620008b791906200499b565b909750955086620008e557600060405180602001604052806000815250600496509650965050505062000927565b601554865164010000000090910463ffffffff1610156200092357600060405180602001604052806000815250600596509650965050505062000927565b5050505b92959194509250565b6200093b8362002f5a565b6000838152601a602052604090206200095682848362004a90565b50827f2b72ac786c97e68dbab71023ed6f2bdbfc80ad9bb7808941929229d71b7d566483836040516200098b929190620048b4565b60405180910390a2505050565b6000620009f288888860008989604051806020016040528060008152508a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152506200031392505050565b98975050505050505050565b60006060600080600080600062000a1462002f1f565b600062000a218a62003010565b905060006012604051806101200160405290816000820160009054906101000a900460ff1660ff1660ff1681526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900462ffffff1662ffffff1662ffffff16815260200160008201600c9054906101000a900461ffff1661ffff1661ffff16815260200160008201600e9054906101000a900460ff1615151515815260200160008201600f9054906101000a900460ff161515151581526020016000820160109054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160008201601c9054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090506000600460008d81526020019081526020016000206040518060e00160405290816000820160009054906101000a900460ff161515151581526020016000820160019054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160059054906101000a900463ffffffff1663ffffffff1663ffffffff1681526020016000820160099054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1681526020016001820160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff16815260200160018201600c9054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff166bffffffffffffffffffffffff1681526020016001820160189054906101000a900463ffffffff1663ffffffff1663ffffffff168152505090508160a001511562000d45576000604051806020016040528060008152506009600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b604081015163ffffffff9081161462000d96576000604051806020016040528060008152506001600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b80511562000ddc576000604051806020016040528060008152506002600084602001516000808263ffffffff1692509950995099509950995099509950505050620010e4565b62000de782620030be565b602083015160155492975090955060009162000e19918591879190640100000000900463ffffffff168a8a87620032b0565b9050806bffffffffffffffffffffffff168260a001516bffffffffffffffffffffffff16101562000e83576000604051806020016040528060008152506006600085602001516000808263ffffffff1692509a509a509a509a509a509a509a5050505050620010e4565b600062000e928e868f62003301565b90505a9850600080846060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000eea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062000f109190620048ec565b73ffffffffffffffffffffffffffffffffffffffff166013600101600c9054906101000a900463ffffffff1663ffffffff168460405162000f5291906200490c565b60006040518083038160008787f1925050503d806000811462000f92576040519150601f19603f3d011682016040523d82523d6000602084013e62000f97565b606091505b50915091505a62000fa9908c6200492a565b9a5081620010295760155481516801000000000000000090910463ffffffff1610156200100657505060408051602080820190925260008082529490910151939c509a50600899505063ffffffff9091169550620010e492505050565b602090940151939b5060039a505063ffffffff9092169650620010e49350505050565b808060200190518101906200103f91906200499b565b909e509c508d6200108057505060408051602080820190925260008082529490910151939c509a50600499505063ffffffff9091169550620010e492505050565b6015548d5164010000000090910463ffffffff161015620010d157505060408051602080820190925260008082529490910151939c509a50600599505063ffffffff9091169550620010e492505050565b505050506020015163ffffffff16945050505b92959891949750929550565b60015473ffffffffffffffffffffffffffffffffffffffff16331462001177576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b600173ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff1660038111156200123257620012326200438d565b141580156200127e5750600373ffffffffffffffffffffffffffffffffffffffff821660009081526019602052604090205460ff1660038111156200127b576200127b6200438d565b14155b15620012b6576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6013546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1662001316576040517fd12d7d8d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082900362001352576040517f2c2fc94100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160e081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c081018290526000808567ffffffffffffffff811115620013a957620013a962004071565b604051908082528060200260200182016040528015620013d3578160200160208202803683370190505b50905060008667ffffffffffffffff811115620013f457620013f462004071565b6040519080825280602002602001820160405280156200147b57816020015b6040805160e08101825260008082526020808301829052928201819052606082018190526080820181905260a0820181905260c082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181620014135790505b50905060008767ffffffffffffffff8111156200149c576200149c62004071565b604051908082528060200260200182016040528015620014d157816020015b6060815260200190600190039081620014bb5790505b50905060008867ffffffffffffffff811115620014f257620014f262004071565b6040519080825280602002602001820160405280156200152757816020015b6060815260200190600190039081620015115790505b50905060008967ffffffffffffffff81111562001548576200154862004071565b6040519080825280602002602001820160405280156200157d57816020015b6060815260200190600190039081620015675790505b50905060005b8a81101562001b61578b8b82818110620015a157620015a162004bb8565b60209081029290920135600081815260048452604090819020815160e081018352815460ff811615158252610100810463ffffffff90811697830197909752650100000000008104871693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490931660c08401529a509098506200168090508962002f5a565b60608801516040517f1a5da6c800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8c8116600483015290911690631a5da6c890602401600060405180830381600087803b158015620016f057600080fd5b505af115801562001705573d6000803e3d6000fd5b50505050878582815181106200171f576200171f62004bb8565b6020026020010181905250600560008a815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1686828151811062001773576200177362004bb8565b73ffffffffffffffffffffffffffffffffffffffff90921660209283029190910182015260008a81526007909152604090208054620017b290620049e8565b80601f0160208091040260200160405190810160405280929190818152602001828054620017e090620049e8565b8015620018315780601f10620018055761010080835404028352916020019162001831565b820191906000526020600020905b8154815290600101906020018083116200181357829003601f168201915b50505050508482815181106200184b576200184b62004bb8565b6020026020010181905250601a60008a815260200190815260200160002080546200187690620049e8565b80601f0160208091040260200160405190810160405280929190818152602001828054620018a490620049e8565b8015620018f55780601f10620018c957610100808354040283529160200191620018f5565b820191906000526020600020905b815481529060010190602001808311620018d757829003601f168201915b50505050508382815181106200190f576200190f62004bb8565b6020026020010181905250601b60008a815260200190815260200160002080546200193a90620049e8565b80601f01602080910402602001604051908101604052809291908181526020018280546200196890620049e8565b8015620019b95780601f106200198d57610100808354040283529160200191620019b9565b820191906000526020600020905b8154815290600101906020018083116200199b57829003601f168201915b5050505050828281518110620019d357620019d362004bb8565b60200260200101819052508760a001516bffffffffffffffffffffffff1687620019fe919062004be7565b60008a815260046020908152604080832080547fffffff000000000000000000000000000000000000000000000000000000000016815560010180547fffffffff000000000000000000000000000000000000000000000000000000001690556007909152812091985062001a74919062003f89565b6000898152601a6020526040812062001a8d9162003f89565b6000898152601b6020526040812062001aa69162003f89565b600089815260066020526040902080547fffffffffffffffffffffffff000000000000000000000000000000000000000016905562001ae760028a62003523565b5060a0880151604080516bffffffffffffffffffffffff909216825273ffffffffffffffffffffffffffffffffffffffff8c1660208301528a917fb38647142fbb1ea4c000fc4569b37a4e9a9f6313317b84ee3e5326c1a6cd06ff910160405180910390a28062001b588162004bfd565b91505062001583565b508560185462001b7291906200492a565b60185560008b8b868167ffffffffffffffff81111562001b965762001b9662004071565b60405190808252806020026020018201604052801562001bc0578160200160208202803683370190505b508988888860405160200162001bde98979695949392919062004da3565b60405160208183030381529060405290508973ffffffffffffffffffffffffffffffffffffffff16638e86139b6013600001600c9054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff1663c71249ab60038e73ffffffffffffffffffffffffffffffffffffffff1663aab9edd66040518163ffffffff1660e01b8152600401602060405180830381865afa15801562001c9a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001cc0919062004e73565b866040518463ffffffff1660e01b815260040162001ce19392919062004e98565b600060405180830381865afa15801562001cff573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405262001d47919081019062004ebf565b6040518263ffffffff1660e01b815260040162001d659190620048ca565b600060405180830381600087803b15801562001d8057600080fd5b505af115801562001d95573d6000803e3d6000fd5b50506040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8d81166004830152602482018b90527f000000000000000000000000000000000000000000000000000000000000000016925063a9059cbb91506044016020604051808303816000875af115801562001e2f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062001e55919062004ef8565b50505050505050505050505050565b60023360009081526019602052604090205460ff16600381111562001e8d5762001e8d6200438d565b1415801562001ec3575060033360009081526019602052604090205460ff16600381111562001ec05762001ec06200438d565b14155b1562001efb576040517f0ebeec3c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080808062001f11888a018a620050f0565b965096509650965096509650965060005b8751811015620021e057600073ffffffffffffffffffffffffffffffffffffffff1687828151811062001f595762001f5962004bb8565b60200260200101516060015173ffffffffffffffffffffffffffffffffffffffff16036200206d5785818151811062001f965762001f9662004bb8565b6020026020010151307f000000000000000000000000000000000000000000000000000000000000000060405162001fce9062003f7b565b73ffffffffffffffffffffffffffffffffffffffff938416815291831660208301529091166040820152606001604051809103906000f08015801562002018573d6000803e3d6000fd5b508782815181106200202e576200202e62004bb8565b60200260200101516060019073ffffffffffffffffffffffffffffffffffffffff16908173ffffffffffffffffffffffffffffffffffffffff16815250505b6200212588828151811062002086576200208662004bb8565b6020026020010151888381518110620020a357620020a362004bb8565b6020026020010151878481518110620020c057620020c062004bb8565b6020026020010151878581518110620020dd57620020dd62004bb8565b6020026020010151878681518110620020fa57620020fa62004bb8565b602002602001015187878151811062002117576200211762004bb8565b602002602001015162002b44565b8781815181106200213a576200213a62004bb8565b60200260200101517f74931a144e43a50694897f241d973aecb5024c0e910f9bb80a163ea3c1cf5a7188838151811062002178576200217862004bb8565b602002602001015160a0015133604051620021c39291906bffffffffffffffffffffffff92909216825273ffffffffffffffffffffffffffffffffffffffff16602082015260400190565b60405180910390a280620021d78162004bfd565b91505062001f22565b50505050505050505050565b600082815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c08201529114620022ea576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b818160a00151620022fc919062005221565b600084815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601854620023649184169062004be7565b6018556040517f23b872dd0000000000000000000000000000000000000000000000000000000081523360048201523060248201526bffffffffffffffffffffffff831660448201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906323b872dd906064016020604051808303816000875af11580156200240e573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062002434919062004ef8565b506040516bffffffffffffffffffffffff83168152339084907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a3505050565b6000818152600460209081526040808320815160e081018352815460ff81161515825263ffffffff6101008204811695830195909552650100000000008104851693820184905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004831660c082015292911415906200256860005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16149050818015620025c35750808015620025c15750620025b462003531565b836040015163ffffffff16115b155b15620025fb576040517ffbc0357800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b801580156200262e575060008481526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314155b1562002666576040517ffbdb8e5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006200267262003531565b9050816200268a576200268760328262004be7565b90505b6000858152600460205260409020805463ffffffff80841665010000000000027fffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffffff90921691909117909155620026e69060029087906200352316565b5060135460808501516bffffffffffffffffffffffff91821691600091168211156200274f5760808601516200271d908362005249565b90508560a001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff1611156200274f575060a08501515b808660a0015162002761919062005249565b600088815260046020526040902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff166c010000000000000000000000006bffffffffffffffffffffffff93841602179055601454620027c99183911662005221565b601480547fffffffffffffffffffffffffffffffffffffffff000000000000000000000000166bffffffffffffffffffffffff9290921691909117905560405167ffffffffffffffff84169088907f91cb3bb75cfbd718bbfccc56b7f53d92d7048ef4ca39a3b7b7c6d4af1f79118190600090a350505050505050565b600060606000806200285762002f1f565b6000634b56a42e60e01b888888604051602401620028789392919062005271565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290506200290389826200068c565b929c919b50995090975095505050505050565b62002920620035ed565b6200292b8162003670565b50565b600060606000806000806000620029558860405180602001604052806000815250620009fe565b959e949d50929b5090995097509550909350915050565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260018301602052604081205415155b90505b92915050565b6000806000620029c76001620029b562003531565b620029c191906200492a565b62003767565b601454604080516020810193909352309083015274010000000000000000000000000000000000000000900463ffffffff166060820152608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201209083015201604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052905060045b600f81101562002ad3578282828151811062002a8f5762002a8f62004bb8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a9053508062002aca8162004bfd565b91505062002a6f565b5083600181111562002ae95762002ae96200438d565b60f81b81600f8151811062002b025762002b0262004bb8565b60200101907effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916908160001a90535062002b3c81620052a5565b949350505050565b6012546e010000000000000000000000000000900460ff161562002b94576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601554835163ffffffff909116101562002bda576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6108fc856020015163ffffffff16108062002c185750601454602086015163ffffffff70010000000000000000000000000000000090920482169116115b1562002c50576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000868152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff161562002cba576040517f6e3b930b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000868152600460209081526040808320885181548a8501518b85015160608d01517fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000009093169315157fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff169390931761010063ffffffff92831602177fffffff000000000000000000000000000000000000000000000000ffffffffff1665010000000000938216939093027fffffff0000000000000000000000000000000000000000ffffffffffffffffff1692909217690100000000000000000073ffffffffffffffffffffffffffffffffffffffff9283160217835560808b01516001909301805460a08d015160c08e01516bffffffffffffffffffffffff9687167fffffffffffffffff000000000000000000000000000000000000000000000000909316929092176c010000000000000000000000009690911695909502949094177fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff1678010000000000000000000000000000000000000000000000009490931693909302919091179091556005835281842080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169189169190911790556007909152902062002ead8482620052e8565b508460a001516bffffffffffffffffffffffff1660185462002ed0919062004be7565b6018556000868152601a6020526040902062002eed8382620052e8565b506000868152601b6020526040902062002f088282620052e8565b5062002f16600287620038cf565b50505050505050565b321562002f58576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff16331462002fb8576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff908116146200292b576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f811015620030a5577fff00000000000000000000000000000000000000000000000000000000000000821683826020811062003059576200305962004bb8565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146200309057506000949350505050565b806200309c8162004bfd565b91505062003017565b5081600f1a600181111562002b3c5762002b3c6200438d565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156200314b573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200317191906200542a565b50945090925050506000811315806200318957508142105b80620031ae5750828015620031ae5750620031a582426200492a565b8463ffffffff16105b15620031bf576016549550620031c3565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156200322f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200325591906200542a565b50945090925050506000811315806200326d57508142105b806200329257508280156200329257506200328982426200492a565b8463ffffffff16105b15620032a3576017549450620032a7565b8094505b50505050915091565b600080620032c488878b60000151620038dd565b9050600080620032e18b8a63ffffffff16858a8a60018b6200397c565b9092509050620032f2818362005221565b9b9a5050505050505050505050565b606060008360018111156200331a576200331a6200438d565b03620033e7576000848152600760205260409081902090517f6e04ff0d0000000000000000000000000000000000000000000000000000000091620033629160240162005522565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915290506200351c565b6001836001811115620033fe57620033fe6200438d565b03620034ea576000828060200190518101906200341c919062005599565b6000868152600760205260409081902090519192507f40691db4000000000000000000000000000000000000000000000000000000009162003463918491602401620056ad565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009093169290921790915291506200351c9050565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b9392505050565b600062002997838362003e1e565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156200356a576200356a6200438d565b03620035e857606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620035bd573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620035e3919062005775565b905090565b504390565b60005473ffffffffffffffffffffffffffffffffffffffff16331462002f58576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016200116e565b3373ffffffffffffffffffffffffffffffffffffffff821603620036f1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200116e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115620037a057620037a06200438d565b03620038c5576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015620037f5573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200381b919062005775565b905080831015806200383957506101006200383784836200492a565b115b15620038485750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa1580156200389f573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200351c919062005775565b504090565b919050565b600062002997838362003f29565b60008080856001811115620038f657620038f66200438d565b0362003907575062015f906200392a565b60018560018111156200391e576200391e6200438d565b03620034ea57506201adb05b6200393d63ffffffff851660146200578f565b6200394a846001620057cf565b6200395b9060ff16611d4c6200578f565b62003967908362004be7565b62003973919062004be7565b95945050505050565b6000806000896080015161ffff16876200399791906200578f565b9050838015620039a65750803a105b15620039af57503a5b600060027f00000000000000000000000000000000000000000000000000000000000000006002811115620039e857620039e86200438d565b0362003b5957604080516000815260208101909152851562003a4c5760003660405180608001604052806048815260200162005cc46048913960405160200162003a3593929190620057eb565b604051602081830303815290604052905062003aba565b60155462003a6a90640100000000900463ffffffff16600462005814565b63ffffffff1667ffffffffffffffff81111562003a8b5762003a8b62004071565b6040519080825280601f01601f19166020018201604052801562003ab6576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e9062003b0c908490600401620048ca565b602060405180830381865afa15801562003b2a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003b50919062005775565b91505062003cc3565b60017f0000000000000000000000000000000000000000000000000000000000000000600281111562003b905762003b906200438d565b0362003cc357841562003c1857606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562003bea573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c10919062005775565b905062003cc3565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa15801562003c67573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019062003c8d919062005843565b505060155492945062003cb293505050640100000000900463ffffffff16826200578f565b62003cbf9060106200578f565b9150505b8462003ce257808b6080015161ffff1662003cdf91906200578f565b90505b62003cf261ffff8716826200588e565b90506000878262003d048c8e62004be7565b62003d1090866200578f565b62003d1c919062004be7565b62003d3090670de0b6b3a76400006200578f565b62003d3c91906200588e565b905060008c6040015163ffffffff1664e8d4a5100062003d5d91906200578f565b898e6020015163ffffffff16858f8862003d7891906200578f565b62003d84919062004be7565b62003d9490633b9aca006200578f565b62003da091906200578f565b62003dac91906200588e565b62003db8919062004be7565b90506b033b2e3c9fd0803ce800000062003dd3828462004be7565b111562003e0c576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000818152600183016020526040812054801562003f1757600062003e456001836200492a565b855490915060009062003e5b906001906200492a565b905081811462003ec757600086600001828154811062003e7f5762003e7f62004bb8565b906000526020600020015490508087600001848154811062003ea55762003ea562004bb8565b6000918252602080832090910192909255918252600188019052604090208390555b855486908062003edb5762003edb620058ca565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506200299a565b60009150506200299a565b5092915050565b600081815260018301602052604081205462003f72575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556200299a565b5060006200299a565b6103ca80620058fa83390190565b50805462003f9790620049e8565b6000825580601f1062003fa8575050565b601f0160209004906000526020600020908101906200292b91905b8082111562003fd9576000815560010162003fc3565b5090565b73ffffffffffffffffffffffffffffffffffffffff811681146200292b57600080fd5b803563ffffffff81168114620038ca57600080fd5b803560028110620038ca57600080fd5b60008083601f8401126200403857600080fd5b50813567ffffffffffffffff8111156200405157600080fd5b6020830191508360208285010111156200406a57600080fd5b9250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160e0810167ffffffffffffffff81118282101715620040c657620040c662004071565b60405290565b604051610100810167ffffffffffffffff81118282101715620040c657620040c662004071565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156200413d576200413d62004071565b604052919050565b600067ffffffffffffffff82111562004162576200416262004071565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f830112620041a057600080fd5b8135620041b7620041b18262004145565b620040f3565b818152846020838601011115620041cd57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060008060e0898b0312156200420757600080fd5b8835620042148162003fdd565b97506200422460208a0162004000565b96506040890135620042368162003fdd565b95506200424660608a0162004015565b9450608089013567ffffffffffffffff808211156200426457600080fd5b620042728c838d0162004025565b909650945060a08b01359150808211156200428c57600080fd5b6200429a8c838d016200418e565b935060c08b0135915080821115620042b157600080fd5b50620042c08b828c016200418e565b9150509295985092959890939650565b60008060408385031215620042e457600080fd5b82359150602083013567ffffffffffffffff8111156200430357600080fd5b62004311858286016200418e565b9150509250929050565b60005b83811015620043385781810151838201526020016200431e565b50506000910152565b600081518084526200435b8160208601602086016200431b565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600a8110620043f4577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b841515815260806020820152600062004415608083018662004341565b9050620044266040830185620043bc565b82606083015295945050505050565b6000806000604084860312156200444b57600080fd5b83359250602084013567ffffffffffffffff8111156200446a57600080fd5b620044788682870162004025565b9497909650939450505050565b600080600080600080600060a0888a031215620044a157600080fd5b8735620044ae8162003fdd565b9650620044be6020890162004000565b95506040880135620044d08162003fdd565b9450606088013567ffffffffffffffff80821115620044ee57600080fd5b620044fc8b838c0162004025565b909650945060808a01359150808211156200451657600080fd5b50620045258a828b0162004025565b989b979a50959850939692959293505050565b871515815260e0602082015260006200455560e083018962004341565b9050620045666040830188620043bc565b8560608301528460808301528360a08301528260c083015298975050505050505050565b600080600060408486031215620045a057600080fd5b833567ffffffffffffffff80821115620045b957600080fd5b818601915086601f830112620045ce57600080fd5b813581811115620045de57600080fd5b8760208260051b8501011115620045f457600080fd5b602092830195509350508401356200460c8162003fdd565b809150509250925092565b600080602083850312156200462b57600080fd5b823567ffffffffffffffff8111156200464357600080fd5b620046518582860162004025565b90969095509350505050565b80356bffffffffffffffffffffffff81168114620038ca57600080fd5b600080604083850312156200468e57600080fd5b82359150620046a0602084016200465d565b90509250929050565b600060208284031215620046bc57600080fd5b5035919050565b600067ffffffffffffffff821115620046e057620046e062004071565b5060051b60200190565b600082601f830112620046fc57600080fd5b813560206200470f620041b183620046c3565b82815260059290921b840181019181810190868411156200472f57600080fd5b8286015b848110156200477457803567ffffffffffffffff811115620047555760008081fd5b620047658986838b01016200418e565b84525091830191830162004733565b509695505050505050565b600080600080606085870312156200479657600080fd5b84359350602085013567ffffffffffffffff80821115620047b657600080fd5b620047c488838901620046ea565b94506040870135915080821115620047db57600080fd5b50620047ea8782880162004025565b95989497509550505050565b6000602082840312156200480957600080fd5b81356200351c8162003fdd565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b600063ffffffff80831681810362004861576200486162004816565b6001019392505050565b8183528181602085013750600060208284010152600060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f840116840101905092915050565b60208152600062002b3c6020830184866200486b565b60208152600062002997602083018462004341565b8051620038ca8162003fdd565b600060208284031215620048ff57600080fd5b81516200351c8162003fdd565b60008251620049208184602087016200431b565b9190910192915050565b818103818111156200299a576200299a62004816565b80151581146200292b57600080fd5b600082601f8301126200496157600080fd5b815162004972620041b18262004145565b8181528460208386010111156200498857600080fd5b62002b3c8260208301602087016200431b565b60008060408385031215620049af57600080fd5b8251620049bc8162004940565b602084015190925067ffffffffffffffff811115620049da57600080fd5b62004311858286016200494f565b600181811c90821680620049fd57607f821691505b60208210810362004a37577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111562004a8b57600081815260208120601f850160051c8101602086101562004a665750805b601f850160051c820191505b8181101562004a875782815560010162004a72565b5050505b505050565b67ffffffffffffffff83111562004aab5762004aab62004071565b62004ac38362004abc8354620049e8565b8362004a3d565b6000601f84116001811462004b18576000851562004ae15750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835562004bb1565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b8281101562004b69578685013582556020948501946001909201910162004b47565b508682101562004ba5577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b808201808211156200299a576200299a62004816565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820362004c315762004c3162004816565b5060010190565b600081518084526020808501945080840160005b8381101562004cf75781518051151588528381015163ffffffff908116858a01526040808301519091169089015260608082015173ffffffffffffffffffffffffffffffffffffffff16908901526080808201516bffffffffffffffffffffffff169089015260a08082015162004cd2828b01826bffffffffffffffffffffffff169052565b505060c09081015163ffffffff169088015260e0909601959082019060010162004c4c565b509495945050505050565b600081518084526020808501945080840160005b8381101562004cf757815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010162004d16565b600081518084526020808501808196508360051b8101915082860160005b8581101562004d9657828403895262004d8384835162004341565b9885019893509084019060010162004d68565b5091979650505050505050565b60e081528760e082015260006101007f07ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8a111562004de057600080fd5b8960051b808c8386013783018381038201602085015262004e048282018b62004c38565b915050828103604084015262004e1b818962004d02565b9050828103606084015262004e31818862004d02565b9050828103608084015262004e47818762004d4a565b905082810360a084015262004e5d818662004d4a565b905082810360c0840152620032f2818562004d4a565b60006020828403121562004e8657600080fd5b815160ff811681146200351c57600080fd5b60ff8416815260ff8316602082015260606040820152600062003973606083018462004341565b60006020828403121562004ed257600080fd5b815167ffffffffffffffff81111562004eea57600080fd5b62002b3c848285016200494f565b60006020828403121562004f0b57600080fd5b81516200351c8162004940565b600082601f83011262004f2a57600080fd5b8135602062004f3d620041b183620046c3565b82815260059290921b8401810191818101908684111562004f5d57600080fd5b8286015b8481101562004774578035835291830191830162004f61565b600082601f83011262004f8c57600080fd5b8135602062004f9f620041b183620046c3565b82815260e0928302850182019282820191908785111562004fbf57600080fd5b8387015b85811015620050765781818a03121562004fdd5760008081fd5b62004fe7620040a0565b813562004ff48162004940565b81526200500382870162004000565b8682015260406200501681840162004000565b908201526060828101356200502b8162003fdd565b9082015260806200503e8382016200465d565b9082015260a0620050518382016200465d565b9082015260c06200506483820162004000565b90820152845292840192810162004fc3565b5090979650505050505050565b600082601f8301126200509557600080fd5b81356020620050a8620041b183620046c3565b82815260059290921b84018101918181019086841115620050c857600080fd5b8286015b8481101562004774578035620050e28162003fdd565b8352918301918301620050cc565b600080600080600080600060e0888a0312156200510c57600080fd5b873567ffffffffffffffff808211156200512557600080fd5b620051338b838c0162004f18565b985060208a01359150808211156200514a57600080fd5b620051588b838c0162004f7a565b975060408a01359150808211156200516f57600080fd5b6200517d8b838c0162005083565b965060608a01359150808211156200519457600080fd5b620051a28b838c0162005083565b955060808a0135915080821115620051b957600080fd5b620051c78b838c01620046ea565b945060a08a0135915080821115620051de57600080fd5b620051ec8b838c01620046ea565b935060c08a01359150808211156200520357600080fd5b50620052128a828b01620046ea565b91505092959891949750929550565b6bffffffffffffffffffffffff81811683821601908082111562003f225762003f2262004816565b6bffffffffffffffffffffffff82811682821603908082111562003f225762003f2262004816565b60408152600062005286604083018662004d4a565b82810360208401526200529b8185876200486b565b9695505050505050565b8051602080830151919081101562004a37577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60209190910360031b1b16919050565b815167ffffffffffffffff81111562005305576200530562004071565b6200531d81620053168454620049e8565b8462004a3d565b602080601f8311600181146200537357600084156200533c5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b17855562004a87565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b82811015620053c257888601518255948401946001909101908401620053a1565b5085821015620053ff57878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b01905550565b805169ffffffffffffffffffff81168114620038ca57600080fd5b600080600080600060a086880312156200544357600080fd5b6200544e866200540f565b945060208601519350604086015192506060860151915062005473608087016200540f565b90509295509295909350565b600081546200548e81620049e8565b808552602060018381168015620054ae5760018114620054e75762005517565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b890101955062005517565b866000528260002060005b858110156200550f5781548a8201860152908301908401620054f2565b890184019650505b505050505092915050565b6020815260006200299760208301846200547f565b600082601f8301126200554957600080fd5b815160206200555c620041b183620046c3565b82815260059290921b840181019181810190868411156200557c57600080fd5b8286015b8481101562004774578051835291830191830162005580565b600060208284031215620055ac57600080fd5b815167ffffffffffffffff80821115620055c557600080fd5b908301906101008286031215620055db57600080fd5b620055e5620040cc565b82518152602083015160208201526040830151604082015260608301516060820152608083015160808201526200561f60a08401620048df565b60a082015260c0830151828111156200563757600080fd5b620056458782860162005537565b60c08301525060e0830151828111156200565e57600080fd5b6200566c878286016200494f565b60e08301525095945050505050565b600081518084526020808501945080840160005b8381101562004cf7578151875295820195908201906001016200568f565b60408152825160408201526020830151606082015260408301516080820152606083015160a0820152608083015160c082015273ffffffffffffffffffffffffffffffffffffffff60a08401511660e0820152600060c0840151610100808185015250620057206101408401826200567b565b905060e08501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0848303016101208501526200575e828262004341565b91505082810360208401526200397381856200547f565b6000602082840312156200578857600080fd5b5051919050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615620057ca57620057ca62004816565b500290565b60ff81811683821601908111156200299a576200299a62004816565b8284823760008382016000815283516200580a8183602088016200431b565b0195945050505050565b600063ffffffff808316818516818304811182151516156200583a576200583a62004816565b02949350505050565b60008060008060008060c087890312156200585d57600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082620058c5577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe60c060405234801561001057600080fd5b506040516103ca3803806103ca83398101604081905261002f91610076565b600080546001600160a01b0319166001600160a01b039384161790559181166080521660a0526100b9565b80516001600160a01b038116811461007157600080fd5b919050565b60008060006060848603121561008b57600080fd5b6100948461005a565b92506100a26020850161005a565b91506100b06040850161005a565b90509250925092565b60805160a0516102e76100e36000396000603801526000818160c4015261011701526102e76000f3fe608060405234801561001057600080fd5b50600436106100365760003560e01c806379188d161461007b578063f00e6a2a146100aa575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610076573d6000f35b3d6000fd5b61008e6100893660046101c1565b6100ee565b6040805192151583526020830191909152015b60405180910390f35b60405173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001681526020016100a1565b60008054819073ffffffffffffffffffffffffffffffffffffffff16331461011557600080fd5b7f00000000000000000000000000000000000000000000000000000000000000005a91505a61138881101561014957600080fd5b61138881039050856040820482031161016157600080fd5b50803b61016d57600080fd5b6000808551602087016000858af192505a610188908361029a565b9150509250929050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080604083850312156101d457600080fd5b82359150602083013567ffffffffffffffff808211156101f357600080fd5b818501915085601f83011261020757600080fd5b81358181111561021957610219610192565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f0116810190838211818310171561025f5761025f610192565b8160405282815288602084870101111561027857600080fd5b8260208601602083013760006020848301015280955050505050509250929050565b818103818111156102d4577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b9291505056fea164736f6c6343000810000a307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } diff --git a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go index a4738d74ef3..15330fb8219 100644 --- a/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_logic_b_wrapper_2_1/keeper_registry_logic_b_wrapper_2_1.go @@ -75,7 +75,7 @@ type KeeperRegistryBase21UpkeepInfo struct { } var KeeperRegistryLogicBMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"hasDedupKey\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + ABI: "[{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"mode\",\"type\":\"uint8\"},{\"internalType\":\"address\",\"name\":\"link\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"linkNativeFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"fastGasFeed\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"automationForwarderLogic\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTransmitter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"}],\"name\":\"acceptPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"acceptUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"startIndex\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"maxCount\",\"type\":\"uint256\"}],\"name\":\"getActiveUpkeepIDs\",\"outputs\":[{\"internalType\":\"uint256[]\",\"name\":\"\",\"type\":\"uint256[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"getAdminPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAutomationForwarderLogic\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getCancellationDelay\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConditionalGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getFastGasFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepID\",\"type\":\"uint256\"}],\"name\":\"getForwarder\",\"outputs\":[{\"internalType\":\"contractIAutomationForwarder\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLinkNativeFeedAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getLogGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"triggerType\",\"type\":\"uint8\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"getMaxPaymentForGas\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"maxPayment\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getMinBalanceForUpkeep\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"minBalance\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMode\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Mode\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"}],\"name\":\"getPeerRegistryMigrationPermission\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerPerformByteGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getPerSignerGasOverhead\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getSignerInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getState\",\"outputs\":[{\"components\":[{\"internalType\":\"uint32\",\"name\":\"nonce\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"ownerLinkBalance\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"expectedLinkBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint96\",\"name\":\"totalPremium\",\"type\":\"uint96\"},{\"internalType\":\"uint256\",\"name\":\"numUpkeeps\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"latestConfigBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"latestConfigDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"latestEpoch\",\"type\":\"uint32\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"}],\"internalType\":\"structKeeperRegistryBase2_1.State\",\"name\":\"state\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"config\",\"type\":\"tuple\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"query\",\"type\":\"address\"}],\"name\":\"getTransmitterInfo\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"active\",\"type\":\"bool\"},{\"internalType\":\"uint8\",\"name\":\"index\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"lastCollected\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getTriggerType\",\"outputs\":[{\"internalType\":\"enumKeeperRegistryBase2_1.Trigger\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"getUpkeep\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"target\",\"type\":\"address\"},{\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"internalType\":\"bytes\",\"name\":\"checkData\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"maxValidBlocknumber\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"lastPerformedBlockNumber\",\"type\":\"uint32\"},{\"internalType\":\"uint96\",\"name\":\"amountSpent\",\"type\":\"uint96\"},{\"internalType\":\"bool\",\"name\":\"paused\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"internalType\":\"structKeeperRegistryBase2_1.UpkeepInfo\",\"name\":\"upkeepInfo\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepPrivilegeConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"}],\"name\":\"getUpkeepTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"hasDedupKey\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"pauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setAdminPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"setPayees\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"peer\",\"type\":\"address\"},{\"internalType\":\"enumKeeperRegistryBase2_1.MigrationPermission\",\"name\":\"permission\",\"type\":\"uint8\"}],\"name\":\"setPeerRegistryMigrationPermission\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"setUpkeepCheckData\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"uint32\",\"name\":\"gasLimit\",\"type\":\"uint32\"}],\"name\":\"setUpkeepGasLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"config\",\"type\":\"bytes\"}],\"name\":\"setUpkeepOffchainConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"upkeepId\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"newPrivilegeConfig\",\"type\":\"bytes\"}],\"name\":\"setUpkeepPrivilegeConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferPayeeship\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"proposed\",\"type\":\"address\"}],\"name\":\"transferUpkeepAdmin\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"unpauseUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepTranscoderVersion\",\"outputs\":[{\"internalType\":\"enumUpkeepFormat\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"upkeepVersion\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"withdrawOwnerFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"withdrawPayment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", Bin: "0x6101206040523480156200001257600080fd5b5060405162004fbc38038062004fbc8339810160408190526200003591620001e9565b84848484843380600081620000915760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000c457620000c48162000121565b505050846002811115620000dc57620000dc6200025e565b60e0816002811115620000f357620000f36200025e565b9052506001600160a01b0393841660805291831660a052821660c05216610100525062000274945050505050565b336001600160a01b038216036200017b5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000088565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b0381168114620001e457600080fd5b919050565b600080600080600060a086880312156200020257600080fd5b8551600381106200021257600080fd5b94506200022260208701620001cc565b93506200023260408701620001cc565b92506200024260608701620001cc565b91506200025260808701620001cc565b90509295509295909350565b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e05161010051614cbd620002ff600039600061058701526000818161052501528181613352015281816138d50152613a680152600081816105f4015261314601526000818161071c01526132200152600081816107aa01528181611bab01528181611e81015281816122ee0152818161280101526128850152614cbd6000f3fe608060405234801561001057600080fd5b50600436106103365760003560e01c806379ba5097116101b2578063b121e147116100f9578063ca30e603116100a2578063eb5dcd6c1161007c578063eb5dcd6c146107f4578063ed56b3e114610807578063f2fde38b1461087a578063faa3e9961461088d57600080fd5b8063ca30e603146107a8578063cd7f71b5146107ce578063d7632648146107e157600080fd5b8063b657bc9c116100d3578063b657bc9c1461076d578063b79550be14610780578063c7c3a19a1461078857600080fd5b8063b121e14714610740578063b148ab6b14610753578063b6511a2a1461076657600080fd5b80638dcf0fe71161015b578063aab9edd611610135578063aab9edd614610703578063abc76ae014610712578063b10b673c1461071a57600080fd5b80638dcf0fe7146106ca578063a710b221146106dd578063a72aa27e146106f057600080fd5b80638456cb591161018c5780638456cb59146106915780638765ecbe146106995780638da5cb5b146106ac57600080fd5b806379ba50971461063e57806379ea9943146106465780637d9b97e01461068957600080fd5b8063421d183b116102815780635165f2f51161022a5780636209e1e9116102045780636209e1e9146105df5780636709d0e5146105f2578063671d36ed14610618578063744bfe611461062b57600080fd5b80635165f2f5146105725780635425d8ac146105855780635b6aa71c146105cc57600080fd5b80634b4fd03b1161025b5780634b4fd03b146105235780634ca16c52146105495780635147cd591461055257600080fd5b8063421d183b1461047a57806344cb70b8146104e057806348013d7b1461051357600080fd5b80631a2af011116102e3578063232c1cc5116102bd578063232c1cc5146104585780633b9cce591461045f5780633f4ba83a1461047257600080fd5b80631a2af011146103d45780631e010439146103e7578063207b65161461044557600080fd5b80631865c57d116103145780631865c57d14610388578063187256e8146103a157806319d97a94146103b457600080fd5b8063050ee65d1461033b57806306e3b632146103535780630b7d33e614610373575b600080fd5b6201adb05b6040519081526020015b60405180910390f35b610366610361366004613df3565b6108d3565b60405161034a9190613e15565b610386610381366004613ea2565b6109f0565b005b610390610aaa565b60405161034a9594939291906140a5565b6103866103af3660046141dc565b610ec3565b6103c76103c2366004614219565b610f34565b60405161034a91906142a0565b6103866103e23660046142b3565b610fd6565b6104286103f5366004614219565b6000908152600460205260409020600101546c0100000000000000000000000090046bffffffffffffffffffffffff1690565b6040516bffffffffffffffffffffffff909116815260200161034a565b6103c7610453366004614219565b6110dc565b6014610340565b61038661046d3660046142d8565b6110f9565b61038661134f565b61048d61048836600461434d565b6113b5565b60408051951515865260ff90941660208601526bffffffffffffffffffffffff9283169385019390935216606083015273ffffffffffffffffffffffffffffffffffffffff16608082015260a00161034a565b6105036104ee366004614219565b60009081526008602052604090205460ff1690565b604051901515815260200161034a565b60005b60405161034a91906143a9565b7f0000000000000000000000000000000000000000000000000000000000000000610516565b62015f90610340565b610565610560366004614219565b6114e8565b60405161034a91906143bc565b610386610580366004614219565b6114f3565b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161034a565b6104286105da3660046143e9565b61166a565b6103c76105ed36600461434d565b61179c565b7f00000000000000000000000000000000000000000000000000000000000000006105a7565b610386610626366004614422565b6117d0565b6103866106393660046142b3565b6118aa565b610386611ca7565b6105a7610654366004614219565b6000908152600460205260409020546901000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1690565b610386611da9565b610386611f04565b6103866106a7366004614219565b611f75565b60005473ffffffffffffffffffffffffffffffffffffffff166105a7565b6103866106d8366004613ea2565b6120ef565b6103866106eb36600461445e565b612144565b6103866106fe36600461448c565b6123c0565b6040516003815260200161034a565b611d4c610340565b7f00000000000000000000000000000000000000000000000000000000000000006105a7565b61038661074e36600461434d565b6124b5565b610386610761366004614219565b6125ad565b6032610340565b61042861077b366004614219565b61279b565b6103866127c8565b61079b610796366004614219565b612924565b60405161034a91906144af565b7f00000000000000000000000000000000000000000000000000000000000000006105a7565b6103866107dc366004613ea2565b612cf7565b6104286107ef366004614219565b612d8e565b61038661080236600461445e565b612d99565b61086161081536600461434d565b73ffffffffffffffffffffffffffffffffffffffff166000908152600c602090815260409182902082518084019093525460ff8082161515808552610100909204169290910182905291565b60408051921515835260ff90911660208301520161034a565b61038661088836600461434d565b612ef7565b6108c661089b36600461434d565b73ffffffffffffffffffffffffffffffffffffffff1660009081526019602052604090205460ff1690565b60405161034a91906145e6565b606060006108e16002612f0b565b905080841061091c576040517f1390f2a100000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006109288486614629565b905081811180610936575083155b6109405780610942565b815b90506000610950868361463c565b67ffffffffffffffff8111156109685761096861464f565b604051908082528060200260200182016040528015610991578160200160208202803683370190505b50905060005b81518110156109e4576109b56109ad8883614629565b600290612f15565b8282815181106109c7576109c761467e565b6020908102919091010152806109dc816146ad565b915050610997565b50925050505b92915050565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314610a51576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152601c60205260409020610a6a828483614787565b50827f2fd8d70753a007014349d4591843cc031c2dd7a260d7dd82eca8253686ae77698383604051610a9d9291906148a2565b60405180910390a2505050565b6040805161014081018252600080825260208201819052918101829052606081018290526080810182905260a0810182905260c0810182905260e081018290526101008101829052610120810191909152604080516101e08101825260008082526020820181905291810182905260608082018390526080820183905260a0820183905260c0820183905260e08201839052610100820183905261012082018390526101408201839052610160820183905261018082018390526101a08201526101c0810191909152604080516101408101825260145463ffffffff7401000000000000000000000000000000000000000082041682526bffffffffffffffffffffffff908116602083015260185492820192909252601254700100000000000000000000000000000000900490911660608281019190915290819060009060808101610bf76002612f0b565b81526014547801000000000000000000000000000000000000000000000000810463ffffffff9081166020808501919091527c0100000000000000000000000000000000000000000000000000000000808404831660408087019190915260115460608088019190915260125492830485166080808901919091526e010000000000000000000000000000840460ff16151560a09889015282516101e081018452610100808604881682526501000000000086048816968201969096526c010000000000000000000000008089048816948201949094526901000000000000000000850462ffffff16928101929092529282900461ffff16928101929092526013546bffffffffffffffffffffffff811696830196909652700100000000000000000000000000000000909404831660c082015260155480841660e0830152640100000000810484169282019290925268010000000000000000909104909116610120820152601654610140820152601754610160820152910473ffffffffffffffffffffffffffffffffffffffff166101808201529095506101a08101610d9f6009612f28565b81526015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16602091820152601254600d80546040805182860281018601909152818152949850899489949293600e9360ff909116928591830182828015610e4257602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e17575b5050505050925081805480602002602001604051908101604052809291908181526020018280548015610eab57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311610e80575b50505050509150945094509450945094509091929394565b610ecb612f35565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260196020526040902080548291907fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001836003811115610f2b57610f2b61436a565b02179055505050565b6000818152601c60205260409020805460609190610f51906146e5565b80601f0160208091040260200160405190810160405280929190818152602001828054610f7d906146e5565b8015610fca5780601f10610f9f57610100808354040283529160200191610fca565b820191906000526020600020905b815481529060010190602001808311610fad57829003601f168201915b50505050509050919050565b610fdf82612fb8565b3373ffffffffffffffffffffffffffffffffffffffff82160361102e576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116146110d85760008281526006602052604080822080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff851690811790915590519091339185917fb1cbb2c4b8480034c27e06da5f096b8233a8fd4497028593a41ff6df79726b3591a45b5050565b6000818152601a60205260409020805460609190610f51906146e5565b611101612f35565b600e54811461113c576040517fcf54c06a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b600e5481101561130e576000600e828154811061115e5761115e61467e565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff908116808452600f909252604083205491935016908585858181106111a8576111a861467e565b90506020020160208101906111bd919061434d565b905073ffffffffffffffffffffffffffffffffffffffff81161580611250575073ffffffffffffffffffffffffffffffffffffffff82161580159061122e57508073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b8015611250575073ffffffffffffffffffffffffffffffffffffffff81811614155b15611287576040517fb387a23800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff818116146112f85773ffffffffffffffffffffffffffffffffffffffff8381166000908152600f6020526040902080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169183169190911790555b5050508080611306906146ad565b91505061113f565b507fa46de38886467c59be07a0675f14781206a5477d871628af46c2443822fcb725600e8383604051611343939291906148ef565b60405180910390a15050565b611357612f35565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff1690556040513381527f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa906020015b60405180910390a1565b73ffffffffffffffffffffffffffffffffffffffff81166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152829182918291829190829061148f57606082015160125460009161147b9170010000000000000000000000000000000090046bffffffffffffffffffffffff166149a1565b600e5490915061148b90826149f5565b9150505b8151602083015160408401516114a6908490614a20565b6060949094015173ffffffffffffffffffffffffffffffffffffffff9a8b166000908152600f6020526040902054929b919a9499509750921694509092505050565b60006109ea8261306c565b6114fc81612fb8565b600081815260046020908152604091829020825160e081018452815460ff8116151580835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c0820152906115fb576040517f1b88a78400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905561163a600283613117565b5060405182907f7bada562044eb163f6b4003c4553e4e62825344c0418eea087bed5ee05a4745690600090a25050565b604080516101208101825260125460ff808216835263ffffffff6101008084048216602086015265010000000000840482169585019590955262ffffff6901000000000000000000840416606085015261ffff6c0100000000000000000000000084041660808501526e01000000000000000000000000000083048216151560a08501526f010000000000000000000000000000008304909116151560c08401526bffffffffffffffffffffffff70010000000000000000000000000000000083041660e08401527c01000000000000000000000000000000000000000000000000000000009091041691810191909152600090818061176983613123565b91509150611792838787601360020160049054906101000a900463ffffffff1686866000613301565b9695505050505050565b73ffffffffffffffffffffffffffffffffffffffff81166000908152601d60205260409020805460609190610f51906146e5565b6015546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff163314611831576040517f77c3599200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff83166000908152601d60205260409020611861828483614787565b508273ffffffffffffffffffffffffffffffffffffffff167f7c44b4eb59ee7873514e7e43e7718c269d872965938b288aa143befca62f99d28383604051610a9d9291906148a2565b6012546f01000000000000000000000000000000900460ff16156118fa576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f0100000000000000000000000000000017905573ffffffffffffffffffffffffffffffffffffffff8116611981576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000828152600460209081526040808320815160e081018352815460ff81161515825263ffffffff610100820481168387015265010000000000820481168386015273ffffffffffffffffffffffffffffffffffffffff6901000000000000000000909204821660608401526001909301546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c082015286855260059093529220549091163314611a88576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b611a9061334c565b816040015163ffffffff161115611ad3576040517fff84e5dd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600460205260409020600101546018546c010000000000000000000000009091046bffffffffffffffffffffffff1690611b1390829061463c565b60185560008481526004602081905260409182902060010180547fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff16905590517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff858116928201929092526bffffffffffffffffffffffff831660248201527f00000000000000000000000000000000000000000000000000000000000000009091169063a9059cbb906044016020604051808303816000875af1158015611bf6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190611c1a9190614a45565b50604080516bffffffffffffffffffffffff8316815273ffffffffffffffffffffffffffffffffffffffff8516602082015285917ff3b5906e5672f3e524854103bcafbbdba80dbdfeca2c35e116127b1060a68318910160405180910390a25050601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff1690555050565b60015473ffffffffffffffffffffffffffffffffffffffff163314611d2d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b611db1612f35565b6014546018546bffffffffffffffffffffffff90911690611dd390829061463c565b601855601480547fffffffffffffffffffffffffffffffffffffffff0000000000000000000000001690556040516bffffffffffffffffffffffff821681527f1d07d0b0be43d3e5fee41a80b579af370affee03fa595bf56d5d4c19328162f19060200160405180910390a16040517fa9059cbb0000000000000000000000000000000000000000000000000000000081523360048201526bffffffffffffffffffffffff821660248201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063a9059cbb906044015b6020604051808303816000875af1158015611ee0573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110d89190614a45565b611f0c612f35565b601280547fffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffff166e0100000000000000000000000000001790556040513381527f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258906020016113ab565b611f7e81612fb8565b600081815260046020908152604091829020825160e081018452815460ff8116158015835263ffffffff610100830481169584019590955265010000000000820485169583019590955273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201529061207d576040517f514b6c2400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260046020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790556120bf600283613401565b5060405182907f8ab10247ce168c27748e656ecf852b951fcaac790c18106b19aa0ae57a8b741f90600090a25050565b6120f883612fb8565b6000838152601b60205260409020612111828483614787565b50827f3e8740446213c8a77d40e08f79136ce3f347d13ed270a6ebdf57159e0faf48508383604051610a9d9291906148a2565b73ffffffffffffffffffffffffffffffffffffffff8116612191576040517f9c8d2cd200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f60205260409020541633146121f1576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e5460009161222891859170010000000000000000000000000000000090046bffffffffffffffffffffffff169061340d565b73ffffffffffffffffffffffffffffffffffffffff84166000908152600b6020526040902080547fffffffffffffffffffffffffffffffffffff000000000000000000000000ffff169055601854909150612292906bffffffffffffffffffffffff83169061463c565b6018556040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff83811660048301526bffffffffffffffffffffffff831660248301527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015612337573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061235b9190614a45565b5060405133815273ffffffffffffffffffffffffffffffffffffffff808416916bffffffffffffffffffffffff8416918616907f9819093176a1851202c7bcfa46845809b4e47c261866550e94ed3775d2f406989060200160405180910390a4505050565b6108fc8163ffffffff1610806123f5575060145463ffffffff7001000000000000000000000000000000009091048116908216115b1561242c576040517f14c237fb00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61243582612fb8565b60008281526004602090815260409182902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffff00000000ff1661010063ffffffff861690810291909117909155915191825283917fc24c07e655ce79fba8a589778987d3c015bc6af1632bb20cf9182e02a65d972c910160405180910390a25050565b73ffffffffffffffffffffffffffffffffffffffff818116600090815260106020526040902054163314612515576040517f6752e7aa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8181166000818152600f602090815260408083208054337fffffffffffffffffffffffff000000000000000000000000000000000000000080831682179093556010909452828520805490921690915590519416939092849290917f78af32efdcad432315431e9b03d27e6cd98fb79c405fdc5af7c1714d9c0f75b39190a45050565b600081815260046020908152604091829020825160e081018452815460ff81161515825263ffffffff6101008204811694830194909452650100000000008104841694820185905273ffffffffffffffffffffffffffffffffffffffff69010000000000000000009091041660608201526001909101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a083015278010000000000000000000000000000000000000000000000009004821660c082015291146126aa576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526006602052604090205473ffffffffffffffffffffffffffffffffffffffff163314612707576040517f6352a85300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526005602090815260408083208054337fffffffffffffffffffffffff0000000000000000000000000000000000000000808316821790935560069094528285208054909216909155905173ffffffffffffffffffffffffffffffffffffffff90911692839186917f5cff4db96bef051785e999f44bfcd21c18823e034fb92dd376e3db4ce0feeb2c91a4505050565b60006109ea6127a98361306c565b600084815260046020526040902054610100900463ffffffff1661166a565b6127d0612f35565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561285d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906128819190614a67565b90507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663a9059cbb33601854846128ce919061463c565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e085901b16815273ffffffffffffffffffffffffffffffffffffffff90921660048301526024820152604401611ec1565b604080516101408101825260008082526020820181905260609282018390528282018190526080820181905260a0820181905260c0820181905260e082018190526101008201526101208101919091526000828152600460209081526040808320815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606083018190526001909101546bffffffffffffffffffffffff80821660808501526c0100000000000000000000000082041660a08401527801000000000000000000000000000000000000000000000000900490921660c0820152919015612abc57816060015173ffffffffffffffffffffffffffffffffffffffff1663f00e6a2a6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612a93573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612ab79190614a80565b612abf565b60005b90506040518061014001604052808273ffffffffffffffffffffffffffffffffffffffff168152602001836020015163ffffffff168152602001600760008781526020019081526020016000208054612b17906146e5565b80601f0160208091040260200160405190810160405280929190818152602001828054612b43906146e5565b8015612b905780601f10612b6557610100808354040283529160200191612b90565b820191906000526020600020905b815481529060010190602001808311612b7357829003601f168201915b505050505081526020018360a001516bffffffffffffffffffffffff1681526020016005600087815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff168152602001836040015163ffffffff1667ffffffffffffffff1681526020018360c0015163ffffffff16815260200183608001516bffffffffffffffffffffffff168152602001836000015115158152602001601b60008781526020019081526020016000208054612c6d906146e5565b80601f0160208091040260200160405190810160405280929190818152602001828054612c99906146e5565b8015612ce65780601f10612cbb57610100808354040283529160200191612ce6565b820191906000526020600020905b815481529060010190602001808311612cc957829003601f168201915b505050505081525092505050919050565b612d0083612fb8565b60155463ffffffff16811115612d42576040517fae7235df00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000838152600760205260409020612d5b828483614787565b50827fcba2d5723b2ee59e53a8e8a82a4a7caf4fdfe70e9f7c582950bf7e7a5c24e83d8383604051610a9d9291906148a2565b60006109ea8261279b565b73ffffffffffffffffffffffffffffffffffffffff8281166000908152600f6020526040902054163314612df9576040517fcebf515b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821603612e48576040517f8c8728c700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff8281166000908152601060205260409020548116908216146110d85773ffffffffffffffffffffffffffffffffffffffff82811660008181526010602052604080822080547fffffffffffffffffffffffff0000000000000000000000000000000000000000169486169485179055513392917f84f7c7c80bb8ed2279b4aab5f61cd05e6374073d38f46d7f32de8c30e9e3836791a45050565b612eff612f35565b612f0881613615565b50565b60006109ea825490565b6000612f21838361370a565b9392505050565b60606000612f2183613734565b60005473ffffffffffffffffffffffffffffffffffffffff163314612fb6576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401611d24565b565b60008181526005602052604090205473ffffffffffffffffffffffffffffffffffffffff163314613015576040517fa47c170600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090205465010000000000900463ffffffff90811614612f08576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000818160045b600f8110156130f9577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106130b1576130b161467e565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff1916146130e757506000949350505050565b806130f1816146ad565b915050613073565b5081600f1a600181111561310f5761310f61436a565b949350505050565b6000612f21838361378f565b6000806000836060015162ffffff1690506000808263ffffffff161190506000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa1580156131af573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906131d39190614ab7565b50945090925050506000811315806131ea57508142105b8061320b575082801561320b5750613202824261463c565b8463ffffffff16105b1561321a57601654955061321e565b8095505b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663feaf968c6040518163ffffffff1660e01b815260040160a060405180830381865afa158015613289573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132ad9190614ab7565b50945090925050506000811315806132c457508142105b806132e557508280156132e557506132dc824261463c565b8463ffffffff16105b156132f45760175494506132f8565b8094505b50505050915091565b60008061331388878b600001516137de565b905060008061332e8b8a63ffffffff16858a8a60018b6138a0565b909250905061333d8183614a20565b9b9a5050505050505050505050565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156133825761338261436a565b036133fc57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156133d3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133f79190614a67565b905090565b504390565b6000612f218383613cf9565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152906136095760008160600151856134a591906149a1565b905060006134b385836149f5565b905080836040018181516134c79190614a20565b6bffffffffffffffffffffffff169052506134e28582614b07565b836060018181516134f39190614a20565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b60400151949350505050565b3373ffffffffffffffffffffffffffffffffffffffff821603613694576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401611d24565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008260000182815481106137215761372161467e565b9060005260206000200154905092915050565b606081600001805480602002602001604051908101604052809291908181526020018280548015610fca57602002820191906000526020600020905b8154815260200190600101908083116137705750505050509050919050565b60008181526001830160205260408120546137d6575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556109ea565b5060006109ea565b600080808560018111156137f4576137f461436a565b03613803575062015f90613858565b60018560018111156138175761381761436a565b0361382657506201adb0613858565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61386963ffffffff85166014614b3b565b613874846001614b78565b6138839060ff16611d4c614b3b565b61388d9083614629565b6138979190614629565b95945050505050565b6000806000896080015161ffff16876138b99190614b3b565b90508380156138c75750803a105b156138cf57503a5b600060027f000000000000000000000000000000000000000000000000000000000000000060028111156139055761390561436a565b03613a6457604080516000815260208101909152851561396357600036604051806080016040528060488152602001614c696048913960405160200161394d93929190614b91565b60405160208183030381529060405290506139cb565b60155461397f90640100000000900463ffffffff166004614bb8565b63ffffffff1667ffffffffffffffff81111561399d5761399d61464f565b6040519080825280601f01601f1916602001820160405280156139c7576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613a1b9084906004016142a0565b602060405180830381865afa158015613a38573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a5c9190614a67565b915050613bbe565b60017f00000000000000000000000000000000000000000000000000000000000000006002811115613a9857613a9861436a565b03613bbe578415613b1a57606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613aef573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b139190614a67565b9050613bbe565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa158015613b68573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613b8c9190614bdb565b5050601554929450613baf93505050640100000000900463ffffffff1682614b3b565b613bba906010614b3b565b9150505b84613bda57808b6080015161ffff16613bd79190614b3b565b90505b613be861ffff871682614c25565b905060008782613bf88c8e614629565b613c029086614b3b565b613c0c9190614629565b613c1e90670de0b6b3a7640000614b3b565b613c289190614c25565b905060008c6040015163ffffffff1664e8d4a51000613c479190614b3b565b898e6020015163ffffffff16858f88613c609190614b3b565b613c6a9190614629565b613c7890633b9aca00614b3b565b613c829190614b3b565b613c8c9190614c25565b613c969190614629565b90506b033b2e3c9fd0803ce8000000613caf8284614629565b1115613ce7576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b60008181526001830160205260408120548015613de2576000613d1d60018361463c565b8554909150600090613d319060019061463c565b9050818114613d96576000866000018281548110613d5157613d5161467e565b9060005260206000200154905080876000018481548110613d7457613d7461467e565b6000918252602080832090910192909255918252600188019052604090208390555b8554869080613da757613da7614c39565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506109ea565b60009150506109ea565b5092915050565b60008060408385031215613e0657600080fd5b50508035926020909101359150565b6020808252825182820181905260009190848201906040850190845b81811015613e4d57835183529284019291840191600101613e31565b50909695505050505050565b60008083601f840112613e6b57600080fd5b50813567ffffffffffffffff811115613e8357600080fd5b602083019150836020828501011115613e9b57600080fd5b9250929050565b600080600060408486031215613eb757600080fd5b83359250602084013567ffffffffffffffff811115613ed557600080fd5b613ee186828701613e59565b9497909650939450505050565b600081518084526020808501945080840160005b83811015613f3457815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101613f02565b509495945050505050565b805163ffffffff16825260006101e06020830151613f65602086018263ffffffff169052565b506040830151613f7d604086018263ffffffff169052565b506060830151613f94606086018262ffffff169052565b506080830151613faa608086018261ffff169052565b5060a0830151613fca60a08601826bffffffffffffffffffffffff169052565b5060c0830151613fe260c086018263ffffffff169052565b5060e0830151613ffa60e086018263ffffffff169052565b506101008381015163ffffffff908116918601919091526101208085015190911690850152610140808401519085015261016080840151908501526101808084015173ffffffffffffffffffffffffffffffffffffffff16908501526101a08084015181860183905261406f83870182613eee565b925050506101c08084015161409b8287018273ffffffffffffffffffffffffffffffffffffffff169052565b5090949350505050565b855163ffffffff16815260006101c060208801516140d360208501826bffffffffffffffffffffffff169052565b506040880151604084015260608801516140fd60608501826bffffffffffffffffffffffff169052565b506080880151608084015260a088015161411f60a085018263ffffffff169052565b5060c088015161413760c085018263ffffffff169052565b5060e088015160e08401526101008089015161415a8286018263ffffffff169052565b505061012088810151151590840152610140830181905261417d81840188613f3f565b90508281036101608401526141928187613eee565b90508281036101808401526141a78186613eee565b9150506117926101a083018460ff169052565b73ffffffffffffffffffffffffffffffffffffffff81168114612f0857600080fd5b600080604083850312156141ef57600080fd5b82356141fa816141ba565b915060208301356004811061420e57600080fd5b809150509250929050565b60006020828403121561422b57600080fd5b5035919050565b60005b8381101561424d578181015183820152602001614235565b50506000910152565b6000815180845261426e816020860160208601614232565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612f216020830184614256565b600080604083850312156142c657600080fd5b82359150602083013561420e816141ba565b600080602083850312156142eb57600080fd5b823567ffffffffffffffff8082111561430357600080fd5b818501915085601f83011261431757600080fd5b81358181111561432657600080fd5b8660208260051b850101111561433b57600080fd5b60209290920196919550909350505050565b60006020828403121561435f57600080fd5b8135612f21816141ba565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60038110612f0857612f0861436a565b602081016143b683614399565b91905290565b60208101600283106143b6576143b661436a565b803563ffffffff811681146143e457600080fd5b919050565b600080604083850312156143fc57600080fd5b82356002811061440b57600080fd5b9150614419602084016143d0565b90509250929050565b60008060006040848603121561443757600080fd5b8335614442816141ba565b9250602084013567ffffffffffffffff811115613ed557600080fd5b6000806040838503121561447157600080fd5b823561447c816141ba565b9150602083013561420e816141ba565b6000806040838503121561449f57600080fd5b82359150614419602084016143d0565b602081526144d660208201835173ffffffffffffffffffffffffffffffffffffffff169052565b600060208301516144ef604084018263ffffffff169052565b50604083015161014080606085015261450c610160850183614256565b9150606085015161452d60808601826bffffffffffffffffffffffff169052565b50608085015173ffffffffffffffffffffffffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015163ffffffff811660e08601525060e0850151610100614599818701836bffffffffffffffffffffffff169052565b86015190506101206145ae8682018315159052565b8601518584037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018387015290506117928382614256565b60208101600483106143b6576143b661436a565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156109ea576109ea6145fa565b818103818111156109ea576109ea6145fa565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036146de576146de6145fa565b5060010190565b600181811c908216806146f957607f821691505b602082108103614732577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b601f82111561478257600081815260208120601f850160051c8101602086101561475f5750805b601f850160051c820191505b8181101561477e5782815560010161476b565b5050505b505050565b67ffffffffffffffff83111561479f5761479f61464f565b6147b3836147ad83546146e5565b83614738565b6000601f84116001811461480557600085156147cf5750838201355b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600387901b1c1916600186901b17835561489b565b6000838152602090207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0861690835b828110156148545786850135825560209485019460019092019101614834565b508682101561488f577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60f88860031b161c19848701351681555b505060018560011b0183555b5050505050565b60208152816020820152818360408301376000818301604090810191909152601f9092017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0160101919050565b6000604082016040835280865480835260608501915087600052602092508260002060005b8281101561494657815473ffffffffffffffffffffffffffffffffffffffff1684529284019260019182019101614914565b505050838103828501528481528590820160005b8681101561499557823561496d816141ba565b73ffffffffffffffffffffffffffffffffffffffff168252918301919083019060010161495a565b50979650505050505050565b6bffffffffffffffffffffffff828116828216039080821115613dec57613dec6145fa565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60006bffffffffffffffffffffffff80841680614a1457614a146149c6565b92169190910492915050565b6bffffffffffffffffffffffff818116838216019080821115613dec57613dec6145fa565b600060208284031215614a5757600080fd5b81518015158114612f2157600080fd5b600060208284031215614a7957600080fd5b5051919050565b600060208284031215614a9257600080fd5b8151612f21816141ba565b805169ffffffffffffffffffff811681146143e457600080fd5b600080600080600060a08688031215614acf57600080fd5b614ad886614a9d565b9450602086015193506040860151925060608601519150614afb60808701614a9d565b90509295509295909350565b60006bffffffffffffffffffffffff80831681851681830481118215151615614b3257614b326145fa565b02949350505050565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615614b7357614b736145fa565b500290565b60ff81811683821601908111156109ea576109ea6145fa565b828482376000838201600081528351614bae818360208801614232565b0195945050505050565b600063ffffffff80831681851681830481118215151615614b3257614b326145fa565b60008060008060008060c08789031215614bf457600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600082614c3457614c346149c6565b500490565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } diff --git a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go index 1e1b8449aa6..4bbd827dc52 100644 --- a/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go +++ b/core/gethwrappers/generated/keeper_registry_wrapper_2_1/keeper_registry_wrapper_2_1.go @@ -49,8 +49,8 @@ type KeeperRegistryBase21OnchainConfig struct { } var KeeperRegistryMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x6101406040523480156200001257600080fd5b50604051620053d4380380620053d48339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051614f33620004a16000396000818160d6015261016f01526000505060008181612dd20152818161313b015281816132ce015261395901526000505060005050600061043b0152614f336000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063aed2e92911610081578063e29b753c1161005b578063e29b753c146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063aed2e92914610262578063afcb95d71461028c578063b1dc65a4146102d5576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613bd8565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613c61565b610423565b610275610270366004613cbd565b61063f565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102e3366004613d4e565b6107a7565b6101196102f63660046141c9565b6112ea565b610119610309366004614296565b612101565b61011961031c366004614325565b61212a565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da82840184614342565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff1661438a565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da9085906143af565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b60008061064a61213e565b6012546e010000000000000000000000000000900460ff1615610699576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f8901859004850281018501909552878552909361079893899089908190840183828082843760009201919091525061217892505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506108d5576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff1661091e576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a351461095a576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516109679060016143f1565b60ff16861415806109785750858414155b156109af576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109bf8a8a8a8a8a8a8a8a612383565b60006109cb8a8a6125ec565b9050600081604001515167ffffffffffffffff8111156109ed576109ed613e05565b604051908082528060200260200182016040528015610ab157816020015b604080516101e0810182526000610100820181815261012083018290526101408301829052610160830182905261018083018290526101a083018290526101c0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181610a0b5790505b5090506000805b836040015151811015610efa576004600085604001518381518110610adf57610adf6143c2565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201528351849083908110610bc457610bc46143c2565b602002602001015160000181905250610bf984604001518281518110610bec57610bec6143c2565b60200260200101516126a7565b838281518110610c0b57610c0b6143c2565b6020026020010151608001906001811115610c2857610c2861440a565b90816001811115610c3b57610c3b61440a565b81525050610caf85848381518110610c5557610c556143c2565b60200260200101516080015186606001518481518110610c7757610c776143c2565b60200260200101518760a001518581518110610c9557610c956143c2565b602002602001015151886000015189602001516001612752565b838281518110610cc157610cc16143c2565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050610d4d84604001518281518110610d0857610d086143c2565b602002602001015185608001518381518110610d2657610d266143c2565b6020026020010151858481518110610d4057610d406143c2565b602002602001015161279d565b848381518110610d5f57610d5f6143c2565b6020026020010151602001858481518110610d7c57610d7c6143c2565b602002602001015160e0018281525082151515158152505050828181518110610da757610da76143c2565b60200260200101516020015115610dca57610dc3600183614439565b9150610dcf565b610ee8565b610e35838281518110610de457610de46143c2565b6020026020010151600001516060015185606001518381518110610e0a57610e0a6143c2565b60200260200101518660a001518481518110610e2857610e286143c2565b6020026020010151612178565b848381518110610e4757610e476143c2565b6020026020010151606001858481518110610e6457610e646143c2565b602002602001015160a0018281525082151515158152505050828181518110610e8f57610e8f6143c2565b602002602001015160a0015186610ea69190614454565b9550610ee884604001518281518110610ec157610ec16143c2565b6020026020010151848381518110610edb57610edb6143c2565b602002602001015161291c565b80610ef281614467565b915050610ab8565b508061ffff16600003610f115750505050506112e0565b8351610f1e9060016143f1565b610f2d9060ff1661044c61449f565b616b6c610f3b8d601061449f565b5a610f469089614454565b610f5091906143af565b610f5a91906143af565b610f6491906143af565b9450611b58610f7761ffff83168761450b565b610f8191906143af565b945060008060008060005b87604001515181101561118257868181518110610fab57610fab6143c2565b60200260200101516020015115611170576110078a888381518110610fd257610fd26143c2565b6020026020010151608001518a60a001518481518110610ff457610ff46143c2565b6020026020010151518c60000151612a2e565b878281518110611019576110196143c2565b602002602001015160c00181815250506110758989604001518381518110611043576110436143c2565b602002602001015189848151811061105d5761105d6143c2565b60200260200101518b600001518c602001518b612a4e565b9093509150611084828561438a565b9350611090838661438a565b94508681815181106110a4576110a46143c2565b6020026020010151606001511515886040015182815181106110c8576110c86143c2565b60200260200101517fad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b84866110fd919061438a565b8a858151811061110f5761110f6143c2565b602002602001015160a001518b868151811061112d5761112d6143c2565b602002602001015160c001518d60800151878151811061114f5761114f6143c2565b6020026020010151604051611167949392919061451f565b60405180910390a35b8061117a81614467565b915050610f8c565b5050336000908152600b6020526040902080548492506002906111ba9084906201000090046bffffffffffffffffffffffff1661438a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff16611214919061438a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f600160038110611257576112576143c2565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff1611156112d657601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6112f2612b41565b601f8651111561132e576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff1660000361136b576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8451865114158061138a575061138284600361455c565b60ff16865111155b156113c1576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff1681101561145657611443600e828154811061141a5761141a6143c2565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612bc2565b508061144e81614467565b9150506113ee565b5060008060005b836bffffffffffffffffffffffff1681101561155f57600d8181548110611486576114866143c2565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff909216945090829081106114c1576114c16143c2565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016905591508061155781614467565b91505061145d565b5061156c600d6000613aad565b611578600e6000613aad565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c518110156118fc57600c60008e83815181106115bd576115bd6143c2565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff1615611628576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f8481518110611659576116596143c2565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110611701576117016143c2565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff81166000908152600b83526040908190208151608081018352905460ff80821615801584526101008304909116958301959095526bffffffffffffffffffffffff6201000082048116938301939093526e01000000000000000000000000000090049091166060820152945092506117c6576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090951694909417179190911692909217919091179055806118f481614467565b91505061159e565b50508a516119129150600d9060208d0190613acb565b50885161192690600e9060208c0190613acb565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff169050611ee8612dcc565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff9384160217808255600192601891611f639185917801000000000000000000000000000000000000000000000000900416614585565b92506101000a81548163ffffffff021916908363ffffffff160217905550600088604051602001611f9491906145f3565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152919052601454909150611ffd90469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f612e81565b60115560005b61200d6009612f2b565b81101561203d5761202a612022600983612f35565b600990612f41565b508061203581614467565b915050612003565b5060005b896101a0015151811015612094576120818a6101a001518281518110612069576120696143c2565b60200260200101516009612f6390919063ffffffff16565b508061208c81614467565b915050612041565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f6040516120eb99989796959493929190614757565b60405180910390a1505050505050505050505050565b6121228686868680602001905181019061211b9190614888565b86866112ea565b505050505050565b612132612b41565b61213b81612f85565b50565b3215612176576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60125460009081906f01000000000000000000000000000000900460ff16156121cd576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b000000000000000000000000000000000000000000000000000000009061223a908590602401613bd8565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d169061230d90879087906004016149e2565b60408051808303816000875af115801561232b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061234f91906149fb565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b60008787604051612395929190614a2e565b6040519081900381206123ac918b90602001614a3e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b8881101561258357600185878360208110612418576124186143c2565b61242591901a601b6143f1565b8c8c85818110612437576124376143c2565b905060200201358b8b86818110612450576124506143c2565b905060200201356040516000815260200160405260405161248d949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156124af573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff808216151580855261010090920416938301939093529095509350905061255d576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b84019350808061257b90614467565b9150506123fb565b50827e010101010101010101010101010101010101010101010101010101010101018416146125de576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b6126256040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b600061263383850185614b2f565b604081015151606082015151919250908114158061265657508082608001515114155b806126665750808260a001515114155b1561269d576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5090505b92915050565b6000818160045b600f811015612734577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106126ec576126ec6143c2565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161461272257506000949350505050565b8061272c81614467565b9150506126ae565b5081600f1a600181111561274a5761274a61440a565b949350505050565b60008061276488878b6000015161307a565b905060008061277f8b8a63ffffffff16858a8a60018b613106565b909250905061278e818361438a565b9b9a5050505050505050505050565b6000808080846080015160018111156127b8576127b861440a565b036127dc576127c886868661355f565b6127d75760009250905061079f565b612853565b6001846080015160018111156127f4576127f461440a565b03612821576000612806878787613653565b925090508061281b575060009250905061079f565b50612853565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61285b612dcc565b84516040015163ffffffff16116128af57857fc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd56368660405161289c9190613bd8565b60405180910390a260009250905061079f565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff16101561290f57857f377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e028660405161289c9190613bd8565b6001969095509350505050565b6000816080015160018111156129345761293461440a565b036129a657612941612dcc565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b6001816080015160018111156129be576129be61440a565b03612a2a5760e08101805160009081526008602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055915191517fa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f29190a25b5050565b6000612a3b84848461307a565b90508085101561274a5750929392505050565b600080612a69888760a001518860c001518888886001613106565b90925090506000612a7a828461438a565b600089815260046020526040902060010180549192508291600c90612abe9084906c0100000000000000000000000090046bffffffffffffffffffffffff16614c1c565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612b079185911661438a565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314612176576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015290612dbe576000816060015185612c5a9190614c1c565b90506000612c688583614c41565b90508083604001818151612c7c919061438a565b6bffffffffffffffffffffffff16905250612c978582614c6c565b83606001818151612ca8919061438a565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115612e0257612e0261440a565b03612e7c57606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612e53573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612e779190614ca0565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a604051602001612ea599989796959493929190614cb9565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b60006126a1825490565b6000612dc583836137e0565b6000612dc58373ffffffffffffffffffffffffffffffffffffffff841661380a565b6000612dc58373ffffffffffffffffffffffffffffffffffffffff8416613904565b3373ffffffffffffffffffffffffffffffffffffffff821603613004576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600080808560018111156130905761309061440a565b0361309f575062015f906130be565b60018560018111156130b3576130b361440a565b0361282157506201adb05b6130cf63ffffffff8516601461449f565b6130da8460016143f1565b6130e99060ff16611d4c61449f565b6130f390836143af565b6130fd91906143af565b95945050505050565b6000806000896080015161ffff168761311f919061449f565b905083801561312d5750803a105b1561313557503a5b600060027f0000000000000000000000000000000000000000000000000000000000000000600281111561316b5761316b61440a565b036132ca5760408051600081526020810190915285156131c957600036604051806080016040528060488152602001614edf604891396040516020016131b393929190614d4e565b6040516020818303038152906040529050613231565b6015546131e590640100000000900463ffffffff166004614d75565b63ffffffff1667ffffffffffffffff81111561320357613203613e05565b6040519080825280601f01601f19166020018201604052801561322d576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613281908490600401613bd8565b602060405180830381865afa15801561329e573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906132c29190614ca0565b915050613424565b60017f000000000000000000000000000000000000000000000000000000000000000060028111156132fe576132fe61440a565b0361342457841561338057606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613355573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133799190614ca0565b9050613424565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156133ce573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133f29190614d98565b505060155492945061341593505050640100000000900463ffffffff168261449f565b61342090601061449f565b9150505b8461344057808b6080015161ffff1661343d919061449f565b90505b61344e61ffff87168261450b565b90506000878261345e8c8e6143af565b613468908661449f565b61347291906143af565b61348490670de0b6b3a764000061449f565b61348e919061450b565b905060008c6040015163ffffffff1664e8d4a510006134ad919061449f565b898e6020015163ffffffff16858f886134c6919061449f565b6134d091906143af565b6134de90633b9aca0061449f565b6134e8919061449f565b6134f2919061450b565b6134fc91906143af565b90506b033b2e3c9fd0803ce800000061351582846143af565b111561354d576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b600080838060200190518101906135769190614de2565b835160c00151815191925063ffffffff908116911610156135d357847f405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8856040516135c19190613bd8565b60405180910390a26000915050612dc5565b6020810151158015906135fa5750602081015181516135f79063ffffffff16613953565b14155b806136135750613608612dcc565b815163ffffffff1610155b1561364857847f6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301856040516135c19190613bd8565b506001949350505050565b60008060008480602001905181019061366c9190614e3a565b9050600086826000015183602001516040516020016136c393929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061372557508160600151613722836040015163ffffffff16613953565b14155b806137415750613733612dcc565b826040015163ffffffff1610155b1561378b57867f6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301876040516137769190613bd8565b60405180910390a260009350915061079f9050565b60008181526008602052604090205460ff16156137d257867f405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8876040516137769190613bd8565b600197909650945050505050565b60008260000182815481106137f7576137f76143c2565b9060005260206000200154905092915050565b600081815260018301602052604081205480156138f357600061382e600183614454565b855490915060009061384290600190614454565b90508181146138a7576000866000018281548110613862576138626143c2565b9060005260206000200154905080876000018481548110613885576138856143c2565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806138b8576138b8614eaf565b6001900381819060005260206000200160009055905585600101600086815260200190815260200160002060009055600193505050506126a1565b60009150506126a1565b5092915050565b600081815260018301602052604081205461394b575081546001818101845560008481526020808220909301849055845484825282860190935260409020919091556126a1565b5060006126a1565b600060017f000000000000000000000000000000000000000000000000000000000000000060028111156139895761398961440a565b03613aa3576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156139dc573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613a009190614ca0565b90508083101580613a1b5750610100613a198483614454565b115b15613a295750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613a7f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612dc59190614ca0565b504090565b919050565b508054600082559060005260206000209081019061213b9190613b55565b828054828255906000526020600020908101928215613b45579160200282015b82811115613b4557825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613aeb565b50613b51929150613b55565b5090565b5b80821115613b515760008155600101613b56565b60005b83811015613b85578181015183820152602001613b6d565b50506000910152565b60008151808452613ba6816020860160208601613b6a565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612dc56020830184613b8e565b73ffffffffffffffffffffffffffffffffffffffff8116811461213b57600080fd5b8035613aa881613beb565b60008083601f840112613c2a57600080fd5b50813567ffffffffffffffff811115613c4257600080fd5b602083019150836020828501011115613c5a57600080fd5b9250929050565b60008060008060608587031215613c7757600080fd5b8435613c8281613beb565b935060208501359250604085013567ffffffffffffffff811115613ca557600080fd5b613cb187828801613c18565b95989497509550505050565b600080600060408486031215613cd257600080fd5b83359250602084013567ffffffffffffffff811115613cf057600080fd5b613cfc86828701613c18565b9497909650939450505050565b60008083601f840112613d1b57600080fd5b50813567ffffffffffffffff811115613d3357600080fd5b6020830191508360208260051b8501011115613c5a57600080fd5b60008060008060008060008060e0898b031215613d6a57600080fd5b606089018a811115613d7b57600080fd5b8998503567ffffffffffffffff80821115613d9557600080fd5b613da18c838d01613c18565b909950975060808b0135915080821115613dba57600080fd5b613dc68c838d01613d09565b909750955060a08b0135915080821115613ddf57600080fd5b50613dec8b828c01613d09565b999c989b50969995989497949560c00135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613e5857613e58613e05565b60405290565b60405160c0810167ffffffffffffffff81118282101715613e5857613e58613e05565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613ec857613ec8613e05565b604052919050565b600067ffffffffffffffff821115613eea57613eea613e05565b5060051b60200190565b600082601f830112613f0557600080fd5b81356020613f1a613f1583613ed0565b613e81565b82815260059290921b84018101918181019086841115613f3957600080fd5b8286015b84811015613f5d578035613f5081613beb565b8352918301918301613f3d565b509695505050505050565b803560ff81168114613aa857600080fd5b63ffffffff8116811461213b57600080fd5b8035613aa881613f79565b62ffffff8116811461213b57600080fd5b8035613aa881613f96565b61ffff8116811461213b57600080fd5b8035613aa881613fb2565b6bffffffffffffffffffffffff8116811461213b57600080fd5b8035613aa881613fcd565b60006101e0828403121561400557600080fd5b61400d613e34565b905061401882613f8b565b815261402660208301613f8b565b602082015261403760408301613f8b565b604082015261404860608301613fa7565b606082015261405960808301613fc2565b608082015261406a60a08301613fe7565b60a082015261407b60c08301613f8b565b60c082015261408c60e08301613f8b565b60e082015261010061409f818401613f8b565b908201526101206140b1838201613f8b565b90820152610140828101359082015261016080830135908201526101806140d9818401613c0d565b908201526101a08281013567ffffffffffffffff8111156140f957600080fd5b61410585828601613ef4565b8284015250506101c0614119818401613c0d565b9082015292915050565b803567ffffffffffffffff81168114613aa857600080fd5b600082601f83011261414c57600080fd5b813567ffffffffffffffff81111561416657614166613e05565b61419760207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613e81565b8181528460208386010111156141ac57600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c087890312156141e257600080fd5b863567ffffffffffffffff808211156141fa57600080fd5b6142068a838b01613ef4565b9750602089013591508082111561421c57600080fd5b6142288a838b01613ef4565b965061423660408a01613f68565b9550606089013591508082111561424c57600080fd5b6142588a838b01613ff2565b945061426660808a01614123565b935060a089013591508082111561427c57600080fd5b5061428989828a0161413b565b9150509295509295509295565b60008060008060008060c087890312156142af57600080fd5b863567ffffffffffffffff808211156142c757600080fd5b6142d38a838b01613ef4565b975060208901359150808211156142e957600080fd5b6142f58a838b01613ef4565b965061430360408a01613f68565b9550606089013591508082111561431957600080fd5b6142588a838b0161413b565b60006020828403121561433757600080fd5b8135612dc581613beb565b60006020828403121561435457600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156138fd576138fd61435b565b808201808211156126a1576126a161435b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60ff81811683821601908111156126a1576126a161435b565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156138fd576138fd61435b565b818103818111156126a1576126a161435b565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036144985761449861435b565b5060010190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156144d7576144d761435b565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b60008261451a5761451a6144dc565b500490565b6bffffffffffffffffffffffff851681528360208201528260408201526080606082015260006145526080830184613b8e565b9695505050505050565b600060ff821660ff84168160ff048111821515161561457d5761457d61435b565b029392505050565b63ffffffff8181168382160190808211156138fd576138fd61435b565b600081518084526020808501945080840160005b838110156145e857815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016145b6565b509495945050505050565b6020815261460a60208201835163ffffffff169052565b60006020830151614623604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e083015161010061469c8185018363ffffffff169052565b84015190506101206146b58482018363ffffffff169052565b84015190506101406146ce8482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a06147118185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c081818601526147316102008601846145a2565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526147878184018a6145a2565b9050828103608084015261479b81896145a2565b905060ff871660a084015282810360c08401526147b88187613b8e565b905067ffffffffffffffff851660e08401528281036101008401526147dd8185613b8e565b9c9b505050505050505050505050565b8051613aa881613f79565b8051613aa881613f96565b8051613aa881613fb2565b8051613aa881613fcd565b8051613aa881613beb565b600082601f83011261483557600080fd5b81516020614845613f1583613ed0565b82815260059290921b8401810191818101908684111561486457600080fd5b8286015b84811015613f5d57805161487b81613beb565b8352918301918301614868565b60006020828403121561489a57600080fd5b815167ffffffffffffffff808211156148b257600080fd5b908301906101e082860312156148c757600080fd5b6148cf613e34565b6148d8836147ed565b81526148e6602084016147ed565b60208201526148f7604084016147ed565b6040820152614908606084016147f8565b606082015261491960808401614803565b608082015261492a60a0840161480e565b60a082015261493b60c084016147ed565b60c082015261494c60e084016147ed565b60e082015261010061495f8185016147ed565b908201526101206149718482016147ed565b9082015261014083810151908201526101608084015190820152610180614999818501614819565b908201526101a083810151838111156149b157600080fd5b6149bd88828701614824565b8284015250506101c091506149d3828401614819565b91810191909152949350505050565b82815260406020820152600061274a6040830184613b8e565b60008060408385031215614a0e57600080fd5b82518015158114614a1e57600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614a6557600080fd5b81356020614a75613f1583613ed0565b82815260059290921b84018101918181019086841115614a9457600080fd5b8286015b84811015613f5d5780358352918301918301614a98565b600082601f830112614ac057600080fd5b81356020614ad0613f1583613ed0565b82815260059290921b84018101918181019086841115614aef57600080fd5b8286015b84811015613f5d57803567ffffffffffffffff811115614b135760008081fd5b614b218986838b010161413b565b845250918301918301614af3565b600060208284031215614b4157600080fd5b813567ffffffffffffffff80821115614b5957600080fd5b9083019060c08286031215614b6d57600080fd5b614b75613e5e565b8235815260208301356020820152604083013582811115614b9557600080fd5b614ba187828601614a54565b604083015250606083013582811115614bb957600080fd5b614bc587828601614a54565b606083015250608083013582811115614bdd57600080fd5b614be987828601614aaf565b60808301525060a083013582811115614c0157600080fd5b614c0d87828601614aaf565b60a08301525095945050505050565b6bffffffffffffffffffffffff8281168282160390808211156138fd576138fd61435b565b60006bffffffffffffffffffffffff80841680614c6057614c606144dc565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614c9757614c9761435b565b02949350505050565b600060208284031215614cb257600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614d008285018b6145a2565b91508382036080850152614d14828a6145a2565b915060ff881660a085015283820360c0850152614d318288613b8e565b90861660e085015283810361010085015290506147dd8185613b8e565b828482376000838201600081528351614d6b818360208801613b6a565b0195945050505050565b600063ffffffff80831681851681830481118215151615614c9757614c9761435b565b60008060008060008060c08789031215614db157600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614df457600080fd5b6040516040810181811067ffffffffffffffff82111715614e1757614e17613e05565b6040528251614e2581613f79565b81526020928301519281019290925250919050565b600060808284031215614e4c57600080fd5b6040516080810181811067ffffffffffffffff82111715614e6f57614e6f613e05565b604052825181526020830151614e8481613f79565b60208201526040830151614e9781613f79565b60408201526060928301519281019290925250919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"contractKeeperRegistryLogicB2_1\",\"name\":\"logicA\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ArrayHasNoEntries\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CannotCancel\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"CheckDataExceedsLimit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ConfigDigestMismatch\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateEntry\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DuplicateSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"GasLimitOutsideRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfFaultyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IncorrectNumberOfSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"IndexOutOfRange\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InsufficientFunds\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDataLength\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidRecipient\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTransmitter\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTrigger\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidTriggerType\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxCheckDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MaxPerformDataSizeCanOnlyIncrease\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MigrationNotPermitted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NotAContract\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveSigners\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyActiveTransmitters\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByLINKToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByOwnerOrRegistrar\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedAdmin\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByProposedPayee\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableByUpkeepPrivilegeManager\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyPausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlySimulatedBackend\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyUnpausedUpkeep\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ParameterLengthError\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"PaymentGreaterThanAllLINK\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ReentrantCall\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RegistryPaused\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedSigner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"RepeatedTransmitter\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"reason\",\"type\":\"bytes\"}],\"name\":\"TargetCheckReverted\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TooManyOracles\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TranscoderNotSet\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepAlreadyExists\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepCancelled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotCanceled\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"UpkeepNotNeeded\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ValueNotChanged\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"AdminPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"CancelledUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"dedupKey\",\"type\":\"bytes32\"}],\"name\":\"DedupKeyAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"FundsAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"FundsWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"InsufficientFundsUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"OwnerFundsWithdrawn\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"payees\",\"type\":\"address[]\"}],\"name\":\"PayeesUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"PayeeshipTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"}],\"name\":\"PaymentWithdrawn\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"ReorgedUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"StaleUpkeepReport\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"name\":\"Transmitted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"UpkeepAdminTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"atBlockHeight\",\"type\":\"uint64\"}],\"name\":\"UpkeepCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"newCheckData\",\"type\":\"bytes\"}],\"name\":\"UpkeepCheckDataSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"gasLimit\",\"type\":\"uint96\"}],\"name\":\"UpkeepGasLimitSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"remainingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"destination\",\"type\":\"address\"}],\"name\":\"UpkeepMigrated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepOffchainConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepPaused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalPayment\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"gasOverhead\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"trigger\",\"type\":\"bytes\"}],\"name\":\"UpkeepPerformed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"privilegeConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepPrivilegeConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"startingBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"importedFrom\",\"type\":\"address\"}],\"name\":\"UpkeepReceived\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"performGas\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"admin\",\"type\":\"address\"}],\"name\":\"UpkeepRegistered\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"triggerConfig\",\"type\":\"bytes\"}],\"name\":\"UpkeepTriggerConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"}],\"name\":\"UpkeepUnpaused\",\"type\":\"event\"},{\"stateMutability\":\"nonpayable\",\"type\":\"fallback\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"fallbackTo\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfigBytes\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"address[]\",\"name\":\"transmitters\",\"type\":\"address[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"components\":[{\"internalType\":\"uint32\",\"name\":\"paymentPremiumPPB\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"flatFeeMicroLink\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"checkGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint24\",\"name\":\"stalenessSeconds\",\"type\":\"uint24\"},{\"internalType\":\"uint16\",\"name\":\"gasCeilingMultiplier\",\"type\":\"uint16\"},{\"internalType\":\"uint96\",\"name\":\"minUpkeepSpend\",\"type\":\"uint96\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformGas\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxCheckDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxPerformDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"maxRevertDataSize\",\"type\":\"uint32\"},{\"internalType\":\"uint256\",\"name\":\"fallbackGasPrice\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"fallbackLinkPrice\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"transcoder\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"registrars\",\"type\":\"address[]\"},{\"internalType\":\"address\",\"name\":\"upkeepPrivilegeManager\",\"type\":\"address\"}],\"internalType\":\"structKeeperRegistryBase2_1.OnchainConfig\",\"name\":\"onchainConfig\",\"type\":\"tuple\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"setConfigTypeSafe\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"id\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"simulatePerformUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"},{\"internalType\":\"uint256\",\"name\":\"gasUsed\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[3]\",\"name\":\"reportContext\",\"type\":\"bytes32[3]\"},{\"internalType\":\"bytes\",\"name\":\"rawReport\",\"type\":\"bytes\"},{\"internalType\":\"bytes32[]\",\"name\":\"rs\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"ss\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes32\",\"name\":\"rawVs\",\"type\":\"bytes32\"}],\"name\":\"transmit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"typeAndVersion\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x6101406040523480156200001257600080fd5b50604051620054b9380380620054b98339810160408190526200003591620003df565b80816001600160a01b0316634b4fd03b6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000075573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200009b919062000406565b826001600160a01b031663ca30e6036040518163ffffffff1660e01b8152600401602060405180830381865afa158015620000da573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001009190620003df565b836001600160a01b031663b10b673c6040518163ffffffff1660e01b8152600401602060405180830381865afa1580156200013f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001659190620003df565b846001600160a01b0316636709d0e56040518163ffffffff1660e01b8152600401602060405180830381865afa158015620001a4573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001ca9190620003df565b856001600160a01b0316635425d8ac6040518163ffffffff1660e01b8152600401602060405180830381865afa15801562000209573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906200022f9190620003df565b3380600081620002865760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620002b957620002b9816200031b565b505050846002811115620002d157620002d162000429565b60e0816002811115620002e857620002e862000429565b9052506001600160a01b0393841660805291831660a052821660c0528116610100529190911661012052506200043f9050565b336001600160a01b03821603620003755760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200027d565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6001600160a01b0381168114620003dc57600080fd5b50565b600060208284031215620003f257600080fd5b8151620003ff81620003c6565b9392505050565b6000602082840312156200041957600080fd5b815160038110620003ff57600080fd5b634e487b7160e01b600052602160045260246000fd5b60805160a05160c05160e0516101005161012051615018620004a16000396000818160d6015261016f01526000505060008181612eb701528181613220015281816133b30152613a3e01526000505060005050600061043b01526150186000f3fe608060405234801561001057600080fd5b50600436106100d45760003560e01c8063aed2e92911610081578063e29b753c1161005b578063e29b753c146102e8578063e3d0e712146102fb578063f2fde38b1461030e576100d4565b8063aed2e92914610262578063afcb95d71461028c578063b1dc65a4146102d5576100d4565b806381ff7048116100b257806381ff7048146101bc5780638da5cb5b14610231578063a4c0ed361461024f576100d4565b8063181f5a771461011b578063349e8cca1461016d57806379ba5097146101b4575b7f00000000000000000000000000000000000000000000000000000000000000003660008037600080366000845af43d6000803e808015610114573d6000f35b3d6000fd5b005b6101576040518060400160405280601481526020017f4b6565706572526567697374727920322e312e3000000000000000000000000081525081565b6040516101649190613cbd565b60405180910390f35b7f00000000000000000000000000000000000000000000000000000000000000005b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610164565b610119610321565b61020e60145460115463ffffffff780100000000000000000000000000000000000000000000000083048116937c01000000000000000000000000000000000000000000000000000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610164565b60005473ffffffffffffffffffffffffffffffffffffffff1661018f565b61011961025d366004613d46565b610423565b610275610270366004613da2565b61063f565b604080519215158352602083019190915201610164565b601154601254604080516000815260208101939093527c010000000000000000000000000000000000000000000000000000000090910463ffffffff1690820152606001610164565b6101196102e3366004613e33565b6107a7565b6101196102f63660046142ae565b6112ea565b61011961030936600461437b565b6121e6565b61011961031c36600461440a565b61220f565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103a7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b3373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610492576040517fc8bad78d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b602081146104cc576040517fdfe9309000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006104da82840184614427565b60008181526004602052604090205490915065010000000000900463ffffffff90811614610534576040517f9c0083a200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008181526004602052604090206001015461056f9085906c0100000000000000000000000090046bffffffffffffffffffffffff1661446f565b600082815260046020526040902060010180546bffffffffffffffffffffffff929092166c01000000000000000000000000027fffffffffffffffff000000000000000000000000ffffffffffffffffffffffff9092169190911790556018546105da908590614494565b6018556040516bffffffffffffffffffffffff8516815273ffffffffffffffffffffffffffffffffffffffff86169082907fafd24114486da8ebfc32f3626dada8863652e187461aa74d4bfa7348915062039060200160405180910390a35050505050565b60008061064a612223565b6012546e010000000000000000000000000000900460ff1615610699576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600085815260046020908152604091829020825160e081018452815460ff811615158252610100810463ffffffff908116838601819052650100000000008304821684880152690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff16606084018190526001909401546bffffffffffffffffffffffff80821660808601526c0100000000000000000000000082041660a0850152780100000000000000000000000000000000000000000000000090041660c08301528451601f8901859004850281018501909552878552909361079893899089908190840183828082843760009201919091525061225d92505050565b9093509150505b935093915050565b60005a604080516101208101825260125460ff808216835261010080830463ffffffff90811660208601526501000000000084048116958501959095526901000000000000000000830462ffffff1660608501526c01000000000000000000000000830461ffff1660808501526e0100000000000000000000000000008304821615801560a08601526f010000000000000000000000000000008404909216151560c085015270010000000000000000000000000000000083046bffffffffffffffffffffffff1660e08501527c0100000000000000000000000000000000000000000000000000000000909204909316908201529192506108d5576040517f24522f3400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600b602052604090205460ff1661091e576040517f1099ed7500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6011548a351461095a576040517fdfdcf8e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b80516109679060016144d6565b60ff16861415806109785750858414155b156109af576040517f0244f71a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6109bf8a8a8a8a8a8a8a8a612468565b60006109cb8a8a6126d1565b9050600081604001515167ffffffffffffffff8111156109ed576109ed613eea565b604051908082528060200260200182016040528015610ab157816020015b604080516101e0810182526000610100820181815261012083018290526101408301829052610160830182905261018083018290526101a083018290526101c0830182905282526020808301829052928201819052606082018190526080820181905260a0820181905260c0820181905260e082015282527fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff909201910181610a0b5790505b5090506000805b836040015151811015610efa576004600085604001518381518110610adf57610adf6144a7565b6020908102919091018101518252818101929092526040908101600020815160e081018352815460ff811615158252610100810463ffffffff90811695830195909552650100000000008104851693820193909352690100000000000000000090920473ffffffffffffffffffffffffffffffffffffffff166060830152600101546bffffffffffffffffffffffff80821660808401526c0100000000000000000000000082041660a08301527801000000000000000000000000000000000000000000000000900490911660c08201528351849083908110610bc457610bc46144a7565b602002602001015160000181905250610bf984604001518281518110610bec57610bec6144a7565b602002602001015161278c565b838281518110610c0b57610c0b6144a7565b6020026020010151608001906001811115610c2857610c286144ef565b90816001811115610c3b57610c3b6144ef565b81525050610caf85848381518110610c5557610c556144a7565b60200260200101516080015186606001518481518110610c7757610c776144a7565b60200260200101518760a001518581518110610c9557610c956144a7565b602002602001015151886000015189602001516001612837565b838281518110610cc157610cc16144a7565b6020026020010151604001906bffffffffffffffffffffffff1690816bffffffffffffffffffffffff1681525050610d4d84604001518281518110610d0857610d086144a7565b602002602001015185608001518381518110610d2657610d266144a7565b6020026020010151858481518110610d4057610d406144a7565b6020026020010151612882565b848381518110610d5f57610d5f6144a7565b6020026020010151602001858481518110610d7c57610d7c6144a7565b602002602001015160e0018281525082151515158152505050828181518110610da757610da76144a7565b60200260200101516020015115610dca57610dc360018361451e565b9150610dcf565b610ee8565b610e35838281518110610de457610de46144a7565b6020026020010151600001516060015185606001518381518110610e0a57610e0a6144a7565b60200260200101518660a001518481518110610e2857610e286144a7565b602002602001015161225d565b848381518110610e4757610e476144a7565b6020026020010151606001858481518110610e6457610e646144a7565b602002602001015160a0018281525082151515158152505050828181518110610e8f57610e8f6144a7565b602002602001015160a0015186610ea69190614539565b9550610ee884604001518281518110610ec157610ec16144a7565b6020026020010151848381518110610edb57610edb6144a7565b6020026020010151612a01565b80610ef28161454c565b915050610ab8565b508061ffff16600003610f115750505050506112e0565b8351610f1e9060016144d6565b610f2d9060ff1661044c614584565b616b6c610f3b8d6010614584565b5a610f469089614539565b610f509190614494565b610f5a9190614494565b610f649190614494565b9450611b58610f7761ffff8316876145f0565b610f819190614494565b945060008060008060005b87604001515181101561118257868181518110610fab57610fab6144a7565b60200260200101516020015115611170576110078a888381518110610fd257610fd26144a7565b6020026020010151608001518a60a001518481518110610ff457610ff46144a7565b6020026020010151518c60000151612b13565b878281518110611019576110196144a7565b602002602001015160c00181815250506110758989604001518381518110611043576110436144a7565b602002602001015189848151811061105d5761105d6144a7565b60200260200101518b600001518c602001518b612b33565b9093509150611084828561446f565b9350611090838661446f565b94508681815181106110a4576110a46144a7565b6020026020010151606001511515886040015182815181106110c8576110c86144a7565b60200260200101517fad8cc9579b21dfe2c2f6ea35ba15b656e46b4f5b0cb424f52739b8ce5cac9c5b84866110fd919061446f565b8a858151811061110f5761110f6144a7565b602002602001015160a001518b868151811061112d5761112d6144a7565b602002602001015160c001518d60800151878151811061114f5761114f6144a7565b60200260200101516040516111679493929190614604565b60405180910390a35b8061117a8161454c565b915050610f8c565b5050336000908152600b6020526040902080548492506002906111ba9084906201000090046bffffffffffffffffffffffff1661446f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555080601260000160108282829054906101000a90046bffffffffffffffffffffffff16611214919061446f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555060008f600160038110611257576112576144a7565b602002013560001c9050600060088264ffffffffff16901c905087610100015163ffffffff168163ffffffff1611156112d657601280547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff8416021790555b5050505050505050505b5050505050505050565b6112f2612c26565b601f8651111561132e576040517f25d0209c00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8360ff1660000361136b576040517fe77dba5600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8451865114158061138a5750611382846003614641565b60ff16865111155b156113c1576040517f1d2d1c5800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601254600e547001000000000000000000000000000000009091046bffffffffffffffffffffffff169060005b816bffffffffffffffffffffffff1681101561145657611443600e828154811061141a5761141a6144a7565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff168484612ca7565b508061144e8161454c565b9150506113ee565b5060008060005b836bffffffffffffffffffffffff1681101561155f57600d8181548110611486576114866144a7565b600091825260209091200154600e805473ffffffffffffffffffffffffffffffffffffffff909216945090829081106114c1576114c16144a7565b600091825260208083209091015473ffffffffffffffffffffffffffffffffffffffff8681168452600c8352604080852080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001690559116808452600b90925290912080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690559150806115578161454c565b91505061145d565b5061156c600d6000613b92565b611578600e6000613b92565b604080516080810182526000808252602082018190529181018290526060810182905290805b8c518110156119e157600c60008e83815181106115bd576115bd6144a7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528101919091526040016000205460ff1615611628576040517f77cea0fa00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff168d8281518110611652576116526144a7565b602002602001015173ffffffffffffffffffffffffffffffffffffffff16036116a7576040517f815e1d6400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60405180604001604052806001151581526020018260ff16815250600c60008f84815181106116d8576116d86144a7565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff1682528181019290925260400160002082518154939092015160ff16610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909316929092171790558b518c9082908110611780576117806144a7565b60200260200101519150600073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16036117f0576040517f58a70a0a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff82166000908152600b60209081526040918290208251608081018452905460ff80821615801584526101008304909116938301939093526bffffffffffffffffffffffff6201000082048116948301949094526e010000000000000000000000000000900490921660608301529093506118ab576040517f6a7281ad00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6001835260ff80821660208086019182526bffffffffffffffffffffffff808b166060880190815273ffffffffffffffffffffffffffffffffffffffff87166000908152600b909352604092839020885181549551948a0151925184166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff939094166201000002929092167fffffffffffff000000000000000000000000000000000000000000000000ffff94909616610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090951694909417179190911692909217919091179055806119d98161454c565b91505061159e565b50508a516119f79150600d9060208d0190613bb0565b508851611a0b90600e9060208c0190613bb0565b506040518061012001604052808960ff168152602001886000015163ffffffff168152602001886020015163ffffffff168152602001886060015162ffffff168152602001886080015161ffff1681526020016012600001600e9054906101000a900460ff16151581526020016012600001600f9054906101000a900460ff1615158152602001856bffffffffffffffffffffffff168152602001600063ffffffff16815250601260008201518160000160006101000a81548160ff021916908360ff16021790555060208201518160000160016101000a81548163ffffffff021916908363ffffffff16021790555060408201518160000160056101000a81548163ffffffff021916908363ffffffff16021790555060608201518160000160096101000a81548162ffffff021916908362ffffff160217905550608082015181600001600c6101000a81548161ffff021916908361ffff16021790555060a082015181600001600e6101000a81548160ff02191690831515021790555060c082015181600001600f6101000a81548160ff02191690831515021790555060e08201518160000160106101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061010082015181600001601c6101000a81548163ffffffff021916908363ffffffff1602179055509050506040518061018001604052808860a001516bffffffffffffffffffffffff16815260200188610180015173ffffffffffffffffffffffffffffffffffffffff168152602001601360010160009054906101000a90046bffffffffffffffffffffffff166bffffffffffffffffffffffff168152602001886040015163ffffffff1681526020018860c0015163ffffffff168152602001601360010160149054906101000a900463ffffffff1663ffffffff168152602001601360010160189054906101000a900463ffffffff1663ffffffff1681526020016013600101601c9054906101000a900463ffffffff1663ffffffff1681526020018860e0015163ffffffff16815260200188610100015163ffffffff16815260200188610120015163ffffffff168152602001886101c0015173ffffffffffffffffffffffffffffffffffffffff16815250601360008201518160000160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550602082015181600001600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555060408201518160010160006101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550606082015181600101600c6101000a81548163ffffffff021916908363ffffffff16021790555060808201518160010160106101000a81548163ffffffff021916908363ffffffff16021790555060a08201518160010160146101000a81548163ffffffff021916908363ffffffff16021790555060c08201518160010160186101000a81548163ffffffff021916908363ffffffff16021790555060e082015181600101601c6101000a81548163ffffffff021916908363ffffffff1602179055506101008201518160020160006101000a81548163ffffffff021916908363ffffffff1602179055506101208201518160020160046101000a81548163ffffffff021916908363ffffffff1602179055506101408201518160020160086101000a81548163ffffffff021916908363ffffffff16021790555061016082015181600201600c6101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555090505086610140015160168190555086610160015160178190555060006013600101601c9054906101000a900463ffffffff169050611fcd612eb1565b601480547bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167c010000000000000000000000000000000000000000000000000000000063ffffffff9384160217808255600192601891612048918591780100000000000000000000000000000000000000000000000090041661466a565b92506101000a81548163ffffffff021916908363ffffffff16021790555060008860405160200161207991906146d8565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe00181529190526014549091506120e290469030907801000000000000000000000000000000000000000000000000900463ffffffff168f8f8f878f8f612f66565b60115560005b6120f26009613010565b8110156121225761210f61210760098361301a565b600990613026565b508061211a8161454c565b9150506120e8565b5060005b896101a0015151811015612179576121668a6101a00151828151811061214e5761214e6144a7565b6020026020010151600961304890919063ffffffff16565b50806121718161454c565b915050612126565b507f1591690b8638f5fb2dbec82ac741805ac5da8b45dc5263f4875b0496fdce4e0582601154601360010160189054906101000a900463ffffffff168f8f8f878f8f6040516121d09998979695949392919061483c565b60405180910390a1505050505050505050505050565b61220786868686806020019051810190612200919061496d565b86866112ea565b505050505050565b612217612c26565b6122208161306a565b50565b321561225b576040517fb60ac5db00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b565b60125460009081906f01000000000000000000000000000000900460ff16156122b2576040517f37ed32e800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff166f010000000000000000000000000000001790556040517f4585e33b000000000000000000000000000000000000000000000000000000009061231f908590602401613cbd565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529181526020820180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009094169390931790925290517f79188d1600000000000000000000000000000000000000000000000000000000815290935073ffffffffffffffffffffffffffffffffffffffff8616906379188d16906123f29087908790600401614ac7565b60408051808303816000875af1158015612410573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906124349190614ae0565b601280547fffffffffffffffffffffffffffffffff00ffffffffffffffffffffffffffffff16905590969095509350505050565b6000878760405161247a929190614b13565b604051908190038120612491918b90602001614b23565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815282825280516020918201208383019092526000808452908301819052909250906000805b88811015612668576001858783602081106124fd576124fd6144a7565b61250a91901a601b6144d6565b8c8c8581811061251c5761251c6144a7565b905060200201358b8b86818110612535576125356144a7565b9050602002013560405160008152602001604052604051612572949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015612594573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff81166000908152600c602090815290849020838501909452925460ff8082161515808552610100909204169383019390935290955093509050612642576040517f0f4c073700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b826020015160080260ff166001901b8401935080806126609061454c565b9150506124e0565b50827e010101010101010101010101010101010101010101010101010101010101018416146126c3576040517fc103be2e00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505050505050505050505050565b61270a6040518060c001604052806000815260200160008152602001606081526020016060815260200160608152602001606081525090565b600061271883850185614c14565b604081015151606082015151919250908114158061273b57508082608001515114155b8061274b5750808260a001515114155b15612782576040517fb55ac75400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5090505b92915050565b6000818160045b600f811015612819577fff0000000000000000000000000000000000000000000000000000000000000082168382602081106127d1576127d16144a7565b1a60f81b7effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff19161461280757506000949350505050565b806128118161454c565b915050612793565b5081600f1a600181111561282f5761282f6144ef565b949350505050565b60008061284988878b6000015161315f565b90506000806128648b8a63ffffffff16858a8a60018b6131eb565b9092509050612873818361446f565b9b9a5050505050505050505050565b60008080808460800151600181111561289d5761289d6144ef565b036128c1576128ad868686613644565b6128bc5760009250905061079f565b612938565b6001846080015160018111156128d9576128d96144ef565b036129065760006128eb878787613738565b9250905080612900575060009250905061079f565b50612938565b6040517ff2b2d41200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b612940612eb1565b84516040015163ffffffff161161299457857fc3237c8807c467c1b39b8d0395eff077313e691bf0a7388106792564ebfd5636866040516129819190613cbd565b60405180910390a260009250905061079f565b83604001516bffffffffffffffffffffffff16846000015160a001516bffffffffffffffffffffffff1610156129f457857f377c8b0c126ae5248d27aca1c76fac4608aff85673ee3caf09747e1044549e02866040516129819190613cbd565b6001969095509350505050565b600081608001516001811115612a1957612a196144ef565b03612a8b57612a26612eb1565b6000838152600460205260409020600101805463ffffffff929092167801000000000000000000000000000000000000000000000000027fffffffff00000000ffffffffffffffffffffffffffffffffffffffffffffffff9092169190911790555050565b600181608001516001811115612aa357612aa36144ef565b03612b0f5760e08101805160009081526008602052604080822080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001179055915191517fa4a4e334c0e330143f9437484fe516c13bc560b86b5b0daf58e7084aaac228f29190a25b5050565b6000612b2084848461315f565b90508085101561282f5750929392505050565b600080612b4e888760a001518860c0015188888860016131eb565b90925090506000612b5f828461446f565b600089815260046020526040902060010180549192508291600c90612ba39084906c0100000000000000000000000090046bffffffffffffffffffffffff16614d01565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915560008a815260046020526040812060010180548594509092612bec9185911661446f565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555050965096945050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461225b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161039e565b73ffffffffffffffffffffffffffffffffffffffff83166000908152600b602090815260408083208151608081018352905460ff80821615801584526101008304909116948301949094526bffffffffffffffffffffffff6201000082048116938301939093526e0100000000000000000000000000009004909116606082015290612ea3576000816060015185612d3f9190614d01565b90506000612d4d8583614d26565b90508083604001818151612d61919061446f565b6bffffffffffffffffffffffff16905250612d7c8582614d51565b83606001818151612d8d919061446f565b6bffffffffffffffffffffffff90811690915273ffffffffffffffffffffffffffffffffffffffff89166000908152600b602090815260409182902087518154928901519389015160608a015186166e010000000000000000000000000000027fffffffffffff000000000000000000000000ffffffffffffffffffffffffffff919096166201000002167fffffffffffff000000000000000000000000000000000000000000000000ffff60ff95909516610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff921515929092167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909416939093171792909216179190911790555050505b6040015190505b9392505050565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115612ee757612ee76144ef565b03612f6157606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015612f38573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612f5c9190614d85565b905090565b504390565b6000808a8a8a8a8a8a8a8a8a604051602001612f8a99989796959493929190614d9e565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe001815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e01000000000000000000000000000000000000000000000000000000000000179b9a5050505050505050505050565b6000612786825490565b6000612eaa83836138c5565b6000612eaa8373ffffffffffffffffffffffffffffffffffffffff84166138ef565b6000612eaa8373ffffffffffffffffffffffffffffffffffffffff84166139e9565b3373ffffffffffffffffffffffffffffffffffffffff8216036130e9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161039e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008080856001811115613175576131756144ef565b03613184575062015f906131a3565b6001856001811115613198576131986144ef565b0361290657506201adb05b6131b463ffffffff85166014614584565b6131bf8460016144d6565b6131ce9060ff16611d4c614584565b6131d89083614494565b6131e29190614494565b95945050505050565b6000806000896080015161ffff16876132049190614584565b90508380156132125750803a105b1561321a57503a5b600060027f00000000000000000000000000000000000000000000000000000000000000006002811115613250576132506144ef565b036133af5760408051600081526020810190915285156132ae57600036604051806080016040528060488152602001614fc46048913960405160200161329893929190614e33565b6040516020818303038152906040529050613316565b6015546132ca90640100000000900463ffffffff166004614e5a565b63ffffffff1667ffffffffffffffff8111156132e8576132e8613eea565b6040519080825280601f01601f191660200182016040528015613312576020820181803683370190505b5090505b6040517f49948e0e00000000000000000000000000000000000000000000000000000000815273420000000000000000000000000000000000000f906349948e0e90613366908490600401613cbd565b602060405180830381865afa158015613383573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906133a79190614d85565b915050613509565b60017f000000000000000000000000000000000000000000000000000000000000000060028111156133e3576133e36144ef565b0361350957841561346557606c73ffffffffffffffffffffffffffffffffffffffff1663c6f7de0e6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561343a573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061345e9190614d85565b9050613509565b6000606c73ffffffffffffffffffffffffffffffffffffffff166341b247a86040518163ffffffff1660e01b815260040160c060405180830381865afa1580156134b3573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906134d79190614e7d565b50506015549294506134fa93505050640100000000900463ffffffff1682614584565b613505906010614584565b9150505b8461352557808b6080015161ffff166135229190614584565b90505b61353361ffff8716826145f0565b9050600087826135438c8e614494565b61354d9086614584565b6135579190614494565b61356990670de0b6b3a7640000614584565b61357391906145f0565b905060008c6040015163ffffffff1664e8d4a510006135929190614584565b898e6020015163ffffffff16858f886135ab9190614584565b6135b59190614494565b6135c390633b9aca00614584565b6135cd9190614584565b6135d791906145f0565b6135e19190614494565b90506b033b2e3c9fd0803ce80000006135fa8284614494565b1115613632576040517f2ad7547a00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b909c909b509950505050505050505050565b6000808380602001905181019061365b9190614ec7565b835160c00151815191925063ffffffff908116911610156136b857847f405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e8856040516136a69190613cbd565b60405180910390a26000915050612eaa565b6020810151158015906136df5750602081015181516136dc9063ffffffff16613a38565b14155b806136f857506136ed612eb1565b815163ffffffff1610155b1561372d57847f6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc301856040516136a69190613cbd565b506001949350505050565b6000806000848060200190518101906137519190614f1f565b9050600086826000015183602001516040516020016137a893929190928352602083019190915260e01b7fffffffff0000000000000000000000000000000000000000000000000000000016604082015260440190565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052805160209091012060608301519091501580159061380a57508160600151613807836040015163ffffffff16613a38565b14155b806138265750613818612eb1565b826040015163ffffffff1610155b1561387057867f6aa7f60c176da7af894b384daea2249497448137f5943c1237ada8bc92bdc3018760405161385b9190613cbd565b60405180910390a260009350915061079f9050565b60008181526008602052604090205460ff16156138b757867f405288ea7be309e16cfdf481367f90a413e1d4634fcdaf8966546db9b93012e88760405161385b9190613cbd565b600197909650945050505050565b60008260000182815481106138dc576138dc6144a7565b9060005260206000200154905092915050565b600081815260018301602052604081205480156139d8576000613913600183614539565b855490915060009061392790600190614539565b905081811461398c576000866000018281548110613947576139476144a7565b906000526020600020015490508087600001848154811061396a5761396a6144a7565b6000918252602080832090910192909255918252600188019052604090208390555b855486908061399d5761399d614f94565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050612786565b6000915050612786565b5092915050565b6000818152600183016020526040812054613a3057508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155612786565b506000612786565b600060017f00000000000000000000000000000000000000000000000000000000000000006002811115613a6e57613a6e6144ef565b03613b88576000606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015613ac1573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613ae59190614d85565b90508083101580613b005750610100613afe8483614539565b115b15613b0e5750600092915050565b6040517f2b407a8200000000000000000000000000000000000000000000000000000000815260048101849052606490632b407a8290602401602060405180830381865afa158015613b64573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612eaa9190614d85565b504090565b919050565b50805460008255906000526020600020908101906122209190613c3a565b828054828255906000526020600020908101928215613c2a579160200282015b82811115613c2a57825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909116178255602090920191600190910190613bd0565b50613c36929150613c3a565b5090565b5b80821115613c365760008155600101613c3b565b60005b83811015613c6a578181015183820152602001613c52565b50506000910152565b60008151808452613c8b816020860160208601613c4f565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b602081526000612eaa6020830184613c73565b73ffffffffffffffffffffffffffffffffffffffff8116811461222057600080fd5b8035613b8d81613cd0565b60008083601f840112613d0f57600080fd5b50813567ffffffffffffffff811115613d2757600080fd5b602083019150836020828501011115613d3f57600080fd5b9250929050565b60008060008060608587031215613d5c57600080fd5b8435613d6781613cd0565b935060208501359250604085013567ffffffffffffffff811115613d8a57600080fd5b613d9687828801613cfd565b95989497509550505050565b600080600060408486031215613db757600080fd5b83359250602084013567ffffffffffffffff811115613dd557600080fd5b613de186828701613cfd565b9497909650939450505050565b60008083601f840112613e0057600080fd5b50813567ffffffffffffffff811115613e1857600080fd5b6020830191508360208260051b8501011115613d3f57600080fd5b60008060008060008060008060e0898b031215613e4f57600080fd5b606089018a811115613e6057600080fd5b8998503567ffffffffffffffff80821115613e7a57600080fd5b613e868c838d01613cfd565b909950975060808b0135915080821115613e9f57600080fd5b613eab8c838d01613dee565b909750955060a08b0135915080821115613ec457600080fd5b50613ed18b828c01613dee565b999c989b50969995989497949560c00135949350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516101e0810167ffffffffffffffff81118282101715613f3d57613f3d613eea565b60405290565b60405160c0810167ffffffffffffffff81118282101715613f3d57613f3d613eea565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715613fad57613fad613eea565b604052919050565b600067ffffffffffffffff821115613fcf57613fcf613eea565b5060051b60200190565b600082601f830112613fea57600080fd5b81356020613fff613ffa83613fb5565b613f66565b82815260059290921b8401810191818101908684111561401e57600080fd5b8286015b8481101561404257803561403581613cd0565b8352918301918301614022565b509695505050505050565b803560ff81168114613b8d57600080fd5b63ffffffff8116811461222057600080fd5b8035613b8d8161405e565b62ffffff8116811461222057600080fd5b8035613b8d8161407b565b61ffff8116811461222057600080fd5b8035613b8d81614097565b6bffffffffffffffffffffffff8116811461222057600080fd5b8035613b8d816140b2565b60006101e082840312156140ea57600080fd5b6140f2613f19565b90506140fd82614070565b815261410b60208301614070565b602082015261411c60408301614070565b604082015261412d6060830161408c565b606082015261413e608083016140a7565b608082015261414f60a083016140cc565b60a082015261416060c08301614070565b60c082015261417160e08301614070565b60e0820152610100614184818401614070565b90820152610120614196838201614070565b90820152610140828101359082015261016080830135908201526101806141be818401613cf2565b908201526101a08281013567ffffffffffffffff8111156141de57600080fd5b6141ea85828601613fd9565b8284015250506101c06141fe818401613cf2565b9082015292915050565b803567ffffffffffffffff81168114613b8d57600080fd5b600082601f83011261423157600080fd5b813567ffffffffffffffff81111561424b5761424b613eea565b61427c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601613f66565b81815284602083860101111561429157600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008060008060c087890312156142c757600080fd5b863567ffffffffffffffff808211156142df57600080fd5b6142eb8a838b01613fd9565b9750602089013591508082111561430157600080fd5b61430d8a838b01613fd9565b965061431b60408a0161404d565b9550606089013591508082111561433157600080fd5b61433d8a838b016140d7565b945061434b60808a01614208565b935060a089013591508082111561436157600080fd5b5061436e89828a01614220565b9150509295509295509295565b60008060008060008060c0878903121561439457600080fd5b863567ffffffffffffffff808211156143ac57600080fd5b6143b88a838b01613fd9565b975060208901359150808211156143ce57600080fd5b6143da8a838b01613fd9565b96506143e860408a0161404d565b955060608901359150808211156143fe57600080fd5b61433d8a838b01614220565b60006020828403121561441c57600080fd5b8135612eaa81613cd0565b60006020828403121561443957600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6bffffffffffffffffffffffff8181168382160190808211156139e2576139e2614440565b8082018082111561278657612786614440565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b60ff818116838216019081111561278657612786614440565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b61ffff8181168382160190808211156139e2576139e2614440565b8181038181111561278657612786614440565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361457d5761457d614440565b5060010190565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156145bc576145bc614440565b500290565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b6000826145ff576145ff6145c1565b500490565b6bffffffffffffffffffffffff851681528360208201528260408201526080606082015260006146376080830184613c73565b9695505050505050565b600060ff821660ff84168160ff048111821515161561466257614662614440565b029392505050565b63ffffffff8181168382160190808211156139e2576139e2614440565b600081518084526020808501945080840160005b838110156146cd57815173ffffffffffffffffffffffffffffffffffffffff168752958201959082019060010161469b565b509495945050505050565b602081526146ef60208201835163ffffffff169052565b60006020830151614708604084018263ffffffff169052565b50604083015163ffffffff8116606084015250606083015162ffffff8116608084015250608083015161ffff811660a08401525060a08301516bffffffffffffffffffffffff811660c08401525060c083015163ffffffff811660e08401525060e08301516101006147818185018363ffffffff169052565b840151905061012061479a8482018363ffffffff169052565b84015190506101406147b38482018363ffffffff169052565b840151610160848101919091528401516101808085019190915284015190506101a06147f68185018373ffffffffffffffffffffffffffffffffffffffff169052565b808501519150506101e06101c08181860152614816610200860184614687565b95015173ffffffffffffffffffffffffffffffffffffffff169301929092525090919050565b600061012063ffffffff808d1684528b6020850152808b1660408501525080606084015261486c8184018a614687565b905082810360808401526148808189614687565b905060ff871660a084015282810360c084015261489d8187613c73565b905067ffffffffffffffff851660e08401528281036101008401526148c28185613c73565b9c9b505050505050505050505050565b8051613b8d8161405e565b8051613b8d8161407b565b8051613b8d81614097565b8051613b8d816140b2565b8051613b8d81613cd0565b600082601f83011261491a57600080fd5b8151602061492a613ffa83613fb5565b82815260059290921b8401810191818101908684111561494957600080fd5b8286015b8481101561404257805161496081613cd0565b835291830191830161494d565b60006020828403121561497f57600080fd5b815167ffffffffffffffff8082111561499757600080fd5b908301906101e082860312156149ac57600080fd5b6149b4613f19565b6149bd836148d2565b81526149cb602084016148d2565b60208201526149dc604084016148d2565b60408201526149ed606084016148dd565b60608201526149fe608084016148e8565b6080820152614a0f60a084016148f3565b60a0820152614a2060c084016148d2565b60c0820152614a3160e084016148d2565b60e0820152610100614a448185016148d2565b90820152610120614a568482016148d2565b9082015261014083810151908201526101608084015190820152610180614a7e8185016148fe565b908201526101a08381015183811115614a9657600080fd5b614aa288828701614909565b8284015250506101c09150614ab88284016148fe565b91810191909152949350505050565b82815260406020820152600061282f6040830184613c73565b60008060408385031215614af357600080fd5b82518015158114614b0357600080fd5b6020939093015192949293505050565b8183823760009101908152919050565b8281526080810160608360208401379392505050565b600082601f830112614b4a57600080fd5b81356020614b5a613ffa83613fb5565b82815260059290921b84018101918181019086841115614b7957600080fd5b8286015b848110156140425780358352918301918301614b7d565b600082601f830112614ba557600080fd5b81356020614bb5613ffa83613fb5565b82815260059290921b84018101918181019086841115614bd457600080fd5b8286015b8481101561404257803567ffffffffffffffff811115614bf85760008081fd5b614c068986838b0101614220565b845250918301918301614bd8565b600060208284031215614c2657600080fd5b813567ffffffffffffffff80821115614c3e57600080fd5b9083019060c08286031215614c5257600080fd5b614c5a613f43565b8235815260208301356020820152604083013582811115614c7a57600080fd5b614c8687828601614b39565b604083015250606083013582811115614c9e57600080fd5b614caa87828601614b39565b606083015250608083013582811115614cc257600080fd5b614cce87828601614b94565b60808301525060a083013582811115614ce657600080fd5b614cf287828601614b94565b60a08301525095945050505050565b6bffffffffffffffffffffffff8281168282160390808211156139e2576139e2614440565b60006bffffffffffffffffffffffff80841680614d4557614d456145c1565b92169190910492915050565b60006bffffffffffffffffffffffff80831681851681830481118215151615614d7c57614d7c614440565b02949350505050565b600060208284031215614d9757600080fd5b5051919050565b60006101208b835273ffffffffffffffffffffffffffffffffffffffff8b16602084015267ffffffffffffffff808b166040850152816060850152614de58285018b614687565b91508382036080850152614df9828a614687565b915060ff881660a085015283820360c0850152614e168288613c73565b90861660e085015283810361010085015290506148c28185613c73565b828482376000838201600081528351614e50818360208801613c4f565b0195945050505050565b600063ffffffff80831681851681830481118215151615614d7c57614d7c614440565b60008060008060008060c08789031215614e9657600080fd5b865195506020870151945060408701519350606087015192506080870151915060a087015190509295509295509295565b600060408284031215614ed957600080fd5b6040516040810181811067ffffffffffffffff82111715614efc57614efc613eea565b6040528251614f0a8161405e565b81526020928301519281019290925250919050565b600060808284031215614f3157600080fd5b6040516080810181811067ffffffffffffffff82111715614f5457614f54613eea565b604052825181526020830151614f698161405e565b60208201526040830151614f7c8161405e565b60408201526060928301519281019290925250919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfe307866666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666666a164736f6c6343000810000a", } var KeeperRegistryABI = KeeperRegistryMetaData.ABI diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index c2ba625b9e3..823ffb0083e 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -22,21 +22,21 @@ functions_billing_registry_events_mock: ../../contracts/solc/v0.8.6/FunctionsBil functions_oracle_events_mock: ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.abi ../../contracts/solc/v0.8.6/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c gas_wrapper: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2.bin 4a5dcdac486d18fcd58e3488c15c1710ae76b977556a3f3191bd269a4bc75723 gas_wrapper_mock: ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.abi ../../contracts/solc/v0.8.6/KeeperRegistryCheckUpkeepGasUsageWrapper1_2Mock.bin a9b08f18da59125c6fc305855710241f3d35161b8b9f3e3f635a7b1d5c6da9c8 -i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 0ae09bdeddc850a53471ddf47b89d1b32c17e97f531570177738605dfb4d0d10 +i_keeper_registry_master_wrapper_2_1: ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.abi ../../contracts/solc/v0.8.16/IKeeperRegistryMaster.bin 4426a320baaef8a66692699ec008e371eb7f841b1f9f02ff817c0eee0c63c7b5 i_log_automation: ../../contracts/solc/v0.8.16/ILogAutomation.abi ../../contracts/solc/v0.8.16/ILogAutomation.bin b9bc273ba34750073874397e7681909794d15b31da8a4449c5aafa0bb5ea1dfc keeper_registrar_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistrar.abi ../../contracts/solc/v0.8.6/KeeperRegistrar.bin e49b2f8b23da17af1ed2209b8ae0968cc04350554d636711e6c24a3ad3118692 keeper_registrar_wrapper1_2_mock: ../../contracts/solc/v0.8.6/KeeperRegistrar1_2Mock.abi ../../contracts/solc/v0.8.6/KeeperRegistrar1_2Mock.bin 5b155a7cb3def309fd7525de1d7cd364ebf8491bdc3060eac08ea0ff55ab29bc keeper_registrar_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistrar2_0.bin 647f125c2f0dafabcdc545cb77b15dc2ec3ea9429357806813179b1fd555c2d2 keeper_registry_logic1_3: ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic1_3.bin 0176d7abdb01b370c5bf4f670d9abf85ca10aff53b1f7bdad41f85fabe666020 keeper_registry_logic2_0: ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistryLogic2_0.bin d69d2bc8e4844293dbc2d45abcddc50b84c88554ecccfa4fa77c0ca45ec80871 -keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin dca600c9eb8a3de11d974722dc4de7f3a995c646c4f4b38b358580f2a0ca4612 -keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 1f22c3bdf1544cd258d085f1f52bd55024ff2c549288860ba1ce9aaebfa9122b +keeper_registry_logic_a_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicA2_1.bin 77481ab75c9aa86a62a7b2a708599b5ea1a6346ed1c0def6d4826e7ae523f1ee +keeper_registry_logic_b_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistryLogicB2_1.bin 467d10741a04601b136553a2b1c6ab37f2a65d809366faf03180a22ff26be215 keeper_registry_wrapper1_1: ../../contracts/solc/v0.7/KeeperRegistry1_1.abi ../../contracts/solc/v0.7/KeeperRegistry1_1.bin 6ce079f2738f015f7374673a2816e8e9787143d00b780ea7652c8aa9ad9e1e20 keeper_registry_wrapper1_1_mock: ../../contracts/solc/v0.7/KeeperRegistry1_1Mock.abi ../../contracts/solc/v0.7/KeeperRegistry1_1Mock.bin 98ddb3680e86359de3b5d17e648253ba29a84703f087a1b52237824003a8c6df keeper_registry_wrapper1_2: ../../contracts/solc/v0.8.6/KeeperRegistry1_2.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_2.bin c08f903e7ecbdf89bbfea32c6dd334d3bf908ac809ebf63545890798a5f7a4a7 keeper_registry_wrapper1_3: ../../contracts/solc/v0.8.6/KeeperRegistry1_3.abi ../../contracts/solc/v0.8.6/KeeperRegistry1_3.bin 5e1414eacbc1880b7349a4f253b7eca176f7f6300ef3cd834c493ce795a17e25 keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi ../../contracts/solc/v0.8.6/KeeperRegistry2_0.bin c32dea7d5ef66b7c58ddc84ddf69aa44df1b3ae8601fbc271c95be4ff5853056 -keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 3423537dd5b4c8b42d693a7720053e7dc3ad64fbfab56fb4996c300d2bc26fa0 +keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 6406f37de79d3d2efa86fb961e1462b62a5a2fff4aeb408bbdb4bc7272d91638 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 log_emitter: ../../contracts/solc/v0.8.19/LogEmitter.abi ../../contracts/solc/v0.8.19/LogEmitter.bin 244ba13730c036de0b02beef4e3d9c9a96946ce353c27f366baecc7f5be5a6fd log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin b16d9cafc51d85c4cd0b32fe0f53e37243b769585c5473c6f0e2c5db7dafc817 From 314c7fd6fe1926ea05ba1574b134ad73dfd2dade Mon Sep 17 00:00:00 2001 From: Lei Date: Mon, 21 Aug 2023 15:59:19 -0700 Subject: [PATCH 223/270] log trigger based upkeep for basic test (#10159) --- .../actions/automation_ocr_helpers.go | 26 +-- integration-tests/actions/keeper_helpers.go | 68 +++---- .../chaos/automation_chaos_test.go | 12 +- .../contracts/contract_deployer.go | 35 +++- .../contracts/ethereum_keeper_contracts.go | 177 +++++++++++++----- .../reorg/automation_reorg_test.go | 12 +- integration-tests/smoke/automation_test.go | 87 +++------ .../testsetups/keeper_benchmark.go | 5 +- 8 files changed, 220 insertions(+), 202 deletions(-) diff --git a/integration-tests/actions/automation_ocr_helpers.go b/integration-tests/actions/automation_ocr_helpers.go index 0a85ef8f47b..4561bc1764a 100644 --- a/integration-tests/actions/automation_ocr_helpers.go +++ b/integration-tests/actions/automation_ocr_helpers.go @@ -81,7 +81,7 @@ func BuildAutoOCR2ConfigVarsWithKeyIndex( 10*time.Second, // deltaProgress time.Duration, 15*time.Second, // deltaResend time.Duration, 500*time.Millisecond, // deltaInitial time.Duration, - 3000*time.Millisecond, // deltaRound time.Duration, + 1000*time.Millisecond, // deltaRound time.Duration, 200*time.Millisecond, // deltaGrace time.Duration, 300*time.Millisecond, // deltaCertifiedCommitRequest time.Duration deltaStage, // deltaStage time.Duration, @@ -266,24 +266,14 @@ func DeployAutoOCRRegistryAndRegistrar( return registry, registrar } -func DeployConsumers( - t *testing.T, - registry contracts.KeeperRegistry, - registrar contracts.KeeperRegistrar, - linkToken contracts.LinkToken, - contractDeployer contracts.ContractDeployer, - client blockchain.EVMClient, - numberOfUpkeeps int, - linkFundsForEachUpkeep *big.Int, - upkeepGasLimit uint32, -) ([]contracts.KeeperConsumer, []*big.Int) { - upkeeps := DeployKeeperConsumers(t, contractDeployer, client, numberOfUpkeeps) +func DeployConsumers(t *testing.T, registry contracts.KeeperRegistry, registrar contracts.KeeperRegistrar, linkToken contracts.LinkToken, contractDeployer contracts.ContractDeployer, client blockchain.EVMClient, numberOfUpkeeps int, linkFundsForEachUpkeep *big.Int, upkeepGasLimit uint32, isLogTrigger bool) ([]contracts.KeeperConsumer, []*big.Int) { + upkeeps := DeployKeeperConsumers(t, contractDeployer, client, numberOfUpkeeps, isLogTrigger) var upkeepsAddresses []string for _, upkeep := range upkeeps { upkeepsAddresses = append(upkeepsAddresses, upkeep.Address()) } upkeepIds := RegisterUpkeepContracts( - t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, + t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, isLogTrigger, ) return upkeeps, upkeepIds } @@ -310,9 +300,7 @@ func DeployPerformanceConsumers( for _, upkeep := range upkeeps { upkeepsAddresses = append(upkeepsAddresses, upkeep.Address()) } - upkeepIds := RegisterUpkeepContracts( - t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, - ) + upkeepIds := RegisterUpkeepContracts(t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, false) return upkeeps, upkeepIds } @@ -333,9 +321,7 @@ func DeployPerformDataCheckerConsumers( for _, upkeep := range upkeeps { upkeepsAddresses = append(upkeepsAddresses, upkeep.Address()) } - upkeepIds := RegisterUpkeepContracts( - t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, - ) + upkeepIds := RegisterUpkeepContracts(t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, false) return upkeeps, upkeepIds } diff --git a/integration-tests/actions/keeper_helpers.go b/integration-tests/actions/keeper_helpers.go index 4a1ad439766..98c9a51e1c8 100644 --- a/integration-tests/actions/keeper_helpers.go +++ b/integration-tests/actions/keeper_helpers.go @@ -142,14 +142,12 @@ func DeployKeeperContracts( } registrar := DeployKeeperRegistrar(t, registryVersion, linkToken, registrarSettings, contractDeployer, client, registry) - upkeeps := DeployKeeperConsumers(t, contractDeployer, client, numberOfUpkeeps) + upkeeps := DeployKeeperConsumers(t, contractDeployer, client, numberOfUpkeeps, false) var upkeepsAddresses []string for _, upkeep := range upkeeps { upkeepsAddresses = append(upkeepsAddresses, upkeep.Address()) } - upkeepIds := RegisterUpkeepContracts( - t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, - ) + upkeepIds := RegisterUpkeepContracts(t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfUpkeeps, upkeepsAddresses, false) err = client.WaitForEvents() require.NoError(t, err, "Error waiting for events") @@ -212,9 +210,7 @@ func DeployPerformanceKeeperContracts( upkeepsAddresses = append(upkeepsAddresses, upkeep.Address()) } - upkeepIds := RegisterUpkeepContracts( - t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfContracts, upkeepsAddresses, - ) + upkeepIds := RegisterUpkeepContracts(t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfContracts, upkeepsAddresses, false) return registry, registrar, upkeeps, upkeepIds } @@ -270,9 +266,7 @@ func DeployPerformDataCheckerContracts( upkeepsAddresses = append(upkeepsAddresses, upkeep.Address()) } - upkeepIds := RegisterUpkeepContracts( - t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfContracts, upkeepsAddresses, - ) + upkeepIds := RegisterUpkeepContracts(t, linkToken, linkFundsForEachUpkeep, client, upkeepGasLimit, registry, registrar, numberOfContracts, upkeepsAddresses, false) return registry, registrar, upkeeps, upkeepIds } @@ -330,38 +324,17 @@ func DeployUpkeepTranscoder( return transcoder } -func RegisterUpkeepContracts( - t *testing.T, - linkToken contracts.LinkToken, - linkFunds *big.Int, - client blockchain.EVMClient, - upkeepGasLimit uint32, - registry contracts.KeeperRegistry, - registrar contracts.KeeperRegistrar, - numberOfContracts int, - upkeepAddresses []string, -) []*big.Int { +func RegisterUpkeepContracts(t *testing.T, linkToken contracts.LinkToken, linkFunds *big.Int, client blockchain.EVMClient, upkeepGasLimit uint32, registry contracts.KeeperRegistry, registrar contracts.KeeperRegistrar, numberOfContracts int, upkeepAddresses []string, isLogTrigger bool) []*big.Int { checkData := make([][]byte, 0) for i := 0; i < numberOfContracts; i++ { checkData = append(checkData, []byte("0")) } return RegisterUpkeepContractsWithCheckData( t, linkToken, linkFunds, client, upkeepGasLimit, registry, registrar, - numberOfContracts, upkeepAddresses, checkData) + numberOfContracts, upkeepAddresses, checkData, isLogTrigger) } -func RegisterUpkeepContractsWithCheckData( - t *testing.T, - linkToken contracts.LinkToken, - linkFunds *big.Int, - client blockchain.EVMClient, - upkeepGasLimit uint32, - registry contracts.KeeperRegistry, - registrar contracts.KeeperRegistrar, - numberOfContracts int, - upkeepAddresses []string, - checkData [][]byte, -) []*big.Int { +func RegisterUpkeepContractsWithCheckData(t *testing.T, linkToken contracts.LinkToken, linkFunds *big.Int, client blockchain.EVMClient, upkeepGasLimit uint32, registry contracts.KeeperRegistry, registrar contracts.KeeperRegistrar, numberOfContracts int, upkeepAddresses []string, checkData [][]byte, isLogTrigger bool) []*big.Int { l := utils.GetTestLogger(t) registrationTxHashes := make([]common.Hash, 0) upkeepIds := make([]*big.Int, 0) @@ -376,6 +349,7 @@ func RegisterUpkeepContractsWithCheckData( linkFunds, 0, client.GetDefaultWallet().Address(), + isLogTrigger, ) require.NoError(t, err, "Encoding the register request shouldn't fail") tx, err := linkToken.TransferAndCall(registrar.Address(), linkFunds, req) @@ -419,19 +393,22 @@ func RegisterUpkeepContractsWithCheckData( return upkeepIds } -func DeployKeeperConsumers( - t *testing.T, - contractDeployer contracts.ContractDeployer, - client blockchain.EVMClient, - numberOfContracts int, -) []contracts.KeeperConsumer { +func DeployKeeperConsumers(t *testing.T, contractDeployer contracts.ContractDeployer, client blockchain.EVMClient, numberOfContracts int, isLogTrigger bool) []contracts.KeeperConsumer { l := utils.GetTestLogger(t) keeperConsumerContracts := make([]contracts.KeeperConsumer, 0) for contractCount := 0; contractCount < numberOfContracts; contractCount++ { // Deploy consumer - keeperConsumerInstance, err := contractDeployer.DeployKeeperConsumer(big.NewInt(5)) - require.NoError(t, err, "Deploying KeeperConsumer instance %d shouldn't fail", contractCount+1) + var keeperConsumerInstance contracts.KeeperConsumer + var err error + + if isLogTrigger { + keeperConsumerInstance, err = contractDeployer.DeployAutomationLogTriggerConsumer(big.NewInt(1000)) // 1000 block test range + } else { + keeperConsumerInstance, err = contractDeployer.DeployKeeperConsumer(big.NewInt(5)) + } + + require.NoError(t, err, "Deploying Consumer instance %d shouldn't fail", contractCount+1) keeperConsumerContracts = append(keeperConsumerContracts, keeperConsumerInstance) l.Debug(). Str("Contract Address", keeperConsumerInstance.Address()). @@ -439,7 +416,7 @@ func DeployKeeperConsumers( Int("Out Of", numberOfContracts). Msg("Deployed Keeper Consumer Contract") if (contractCount+1)%ContractDeploymentInterval == 0 { // For large amounts of contract deployments, space things out some - err = client.WaitForEvents() + err := client.WaitForEvents() require.NoError(t, err, "Failed to wait for KeeperConsumer deployments") } } @@ -600,15 +577,14 @@ func RegisterNewUpkeeps( upkeepGasLimit uint32, numberOfNewUpkeeps int, ) ([]contracts.KeeperConsumer, []*big.Int) { - newlyDeployedUpkeeps := DeployKeeperConsumers(t, contractDeployer, client, numberOfNewUpkeeps) + newlyDeployedUpkeeps := DeployKeeperConsumers(t, contractDeployer, client, numberOfNewUpkeeps, false) var addressesOfNewUpkeeps []string for _, upkeep := range newlyDeployedUpkeeps { addressesOfNewUpkeeps = append(addressesOfNewUpkeeps, upkeep.Address()) } - newUpkeepIDs := RegisterUpkeepContracts(t, linkToken, big.NewInt(9e18), client, upkeepGasLimit, - registry, registrar, numberOfNewUpkeeps, addressesOfNewUpkeeps) + newUpkeepIDs := RegisterUpkeepContracts(t, linkToken, big.NewInt(9e18), client, upkeepGasLimit, registry, registrar, numberOfNewUpkeeps, addressesOfNewUpkeeps, false) return newlyDeployedUpkeeps, newUpkeepIDs } diff --git a/integration-tests/chaos/automation_chaos_test.go b/integration-tests/chaos/automation_chaos_test.go index 8b803eca320..dd2a39a57be 100644 --- a/integration-tests/chaos/automation_chaos_test.go +++ b/integration-tests/chaos/automation_chaos_test.go @@ -243,17 +243,7 @@ func TestAutomationChaos(t *testing.T) { require.NoError(t, err, "Registry config should be be set successfully") require.NoError(t, chainClient.WaitForEvents(), "Waiting for config to be set") - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - numberOfUpkeeps, - big.NewInt(defaultLinkFunds), - defaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, numberOfUpkeeps, big.NewInt(defaultLinkFunds), defaultUpkeepGasLimit, false) l.Info().Msg("Waiting for all upkeeps to be performed") diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 778f3dfac29..3555caebad7 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -40,6 +40,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" registry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/log_upkeep_counter_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_aggregator_proxy" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_ethlink_aggregator_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/mock_gas_aggregator_wrapper" @@ -70,6 +71,7 @@ type ContractDeployer interface { DeployKeeperRegistry(opts *KeeperRegistryOpts) (KeeperRegistry, error) LoadKeeperRegistry(address common.Address, registryVersion eth_contracts.KeeperRegistryVersion) (KeeperRegistry, error) DeployKeeperConsumer(updateInterval *big.Int) (KeeperConsumer, error) + DeployAutomationLogTriggerConsumer(testInterval *big.Int) (KeeperConsumer, error) DeployKeeperConsumerPerformance( testBlockRange, averageCadence, @@ -686,6 +688,7 @@ func (e *EthereumContractDeployer) DeployKeeperRegistrar(registryVersion eth_con // set default TriggerType to 0(conditional), AutoApproveConfigType to 2(auto approve enabled), AutoApproveMaxAllowed to 1000 triggerConfigs := []registrar21.AutomationRegistrar21InitialTriggerConfig{ {TriggerType: 0, AutoApproveType: 2, AutoApproveMaxAllowed: 1000}, + {TriggerType: 1, AutoApproveType: 2, AutoApproveMaxAllowed: 1000}, } return registrar21.DeployAutomationRegistrar( @@ -1022,7 +1025,7 @@ func (e *EthereumContractDeployer) DeployKeeperRegistry( return nil, err } - address, _, instance, err := e.client.DeployContract("KeeperRegistry2_0", func( + address, _, _, err := e.client.DeployContract("KeeperRegistry2_1", func( auth *bind.TransactOpts, backend bind.ContractBackend, ) (common.Address, *types.Transaction, interface{}, error) { @@ -1039,10 +1042,17 @@ func (e *EthereumContractDeployer) DeployKeeperRegistry( return nil, err } + registryMaster, err := iregistry21.NewIKeeperRegistryMaster( + *address, + e.client.Backend(), + ) + if err != nil { + return nil, err + } return &EthereumKeeperRegistry{ client: e.client, version: eth_contracts.RegistryVersion_2_1, - registry2_1: instance.(*registry21.KeeperRegistry), + registry2_1: registryMaster, address: address, }, err default: @@ -1126,7 +1136,7 @@ func (e *EthereumContractDeployer) LoadKeeperRegistry(address common.Address, re return &EthereumKeeperRegistry{ address: &address, client: e.client, - registry2_1: instance.(*registry21.KeeperRegistry), + registry2_1: instance.(*iregistry21.IKeeperRegistryMaster), }, err default: return nil, fmt.Errorf("keeper registry version %d is not supported", registryVersion) @@ -1150,6 +1160,25 @@ func (e *EthereumContractDeployer) DeployKeeperConsumer(updateInterval *big.Int) }, err } +func (e *EthereumContractDeployer) DeployAutomationLogTriggerConsumer(testInterval *big.Int) (KeeperConsumer, error) { + address, _, instance, err := e.client.DeployContract("LogUpkeepCounter", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return log_upkeep_counter_wrapper.DeployLogUpkeepCounter( + auth, backend, testInterval, + ) + }) + if err != nil { + return nil, err + } + return &EthereumAutomationLogCounterConsumer{ + client: e.client, + consumer: instance.(*log_upkeep_counter_wrapper.LogUpkeepCounter), + address: address, + }, err +} + func (e *EthereumContractDeployer) DeployUpkeepCounter(testRange *big.Int, interval *big.Int) (UpkeepCounter, error) { address, _, instance, err := e.client.DeployContract("UpkeepCounter", func( auth *bind.TransactOpts, diff --git a/integration-tests/contracts/ethereum_keeper_contracts.go b/integration-tests/contracts/ethereum_keeper_contracts.go index 615131590cd..0d21fd9e739 100644 --- a/integration-tests/contracts/ethereum_keeper_contracts.go +++ b/integration-tests/contracts/ethereum_keeper_contracts.go @@ -11,6 +11,7 @@ import ( geth "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" @@ -19,18 +20,18 @@ import ( goabi "github.com/umbracle/ethgo/abi" cltypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" registrar21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_registrar_wrapper2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" - registry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" - - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registrar_wrapper2_0" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_1" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_2" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper1_3" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper2_0" - "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" + registry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/keeper_registry_wrapper_2_1" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/log_upkeep_counter_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/upkeep_transcoder" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -44,17 +45,7 @@ var registrarABI = cltypes.MustGetABI(registrar21.AutomationRegistrarABI) type KeeperRegistrar interface { Address() string - EncodeRegisterRequest( - name string, - email []byte, - upkeepAddr string, - gasLimit uint32, - adminAddr string, - checkData []byte, - amount *big.Int, - source uint8, - senderAddr string, - ) ([]byte, error) + EncodeRegisterRequest(name string, email []byte, upkeepAddr string, gasLimit uint32, adminAddr string, checkData []byte, amount *big.Int, source uint8, senderAddr string, isLogTrigger bool) ([]byte, error) Fund(ethAmount *big.Float) error } @@ -90,6 +81,7 @@ type KeeperConsumer interface { Address() string Fund(ethAmount *big.Float) error Counter(ctx context.Context) (*big.Int, error) + Start() error } type UpkeepCounter interface { @@ -204,7 +196,7 @@ type EthereumKeeperRegistry struct { registry1_2 *keeper_registry_wrapper1_2.KeeperRegistry registry1_3 *keeper_registry_wrapper1_3.KeeperRegistry registry2_0 *keeper_registry_wrapper2_0.KeeperRegistry - registry2_1 *keeper_registry_wrapper_2_1.KeeperRegistry + registry2_1 *i_keeper_registry_master_wrapper_2_1.IKeeperRegistryMaster address *common.Address } @@ -239,10 +231,9 @@ func (rcs *KeeperRegistrySettings) EncodeOnChainConfig(registrar string) ([]byte Registrars: []common.Address{common.HexToAddress(registrar)}, UpkeepPrivilegeManager: common.Address{}, } - encodedOnchainConfig, err := utilsABI.Pack("_onChainConfig", &onchainConfigStruct) + encodedOnchainConfig, err := utilsABI.Methods["_onChainConfig"].Inputs.Pack(&onchainConfigStruct) - // slice off the first 4 bytes which is the function signature - return encodedOnchainConfig[4:], err + return encodedOnchainConfig, err } else { configType := goabi.MustNewType("tuple(uint32 paymentPremiumPPB,uint32 flatFeeMicroLink,uint32 checkGasLimit,uint24 stalenessSeconds,uint16 gasCeilingMultiplier,uint96 minUpkeepSpend,uint32 maxPerformGas,uint32 maxCheckDataSize,uint32 maxPerformDataSize,uint256 fallbackGasPrice,uint256 fallbackLinkPrice,address transcoder,address registrar)") onchainConfig, err := goabi.Encode(map[string]interface{}{ @@ -748,6 +739,11 @@ func (v *EthereumKeeperRegistry) CancelUpkeep(id *big.Int) error { if err != nil { return err } + case ethereum.RegistryVersion_2_1: + tx, err = v.registry2_1.CancelUpkeep(opts, id) + if err != nil { + return err + } } log.Info(). @@ -1508,6 +1504,11 @@ type EthereumKeeperConsumer struct { address *common.Address } +// Just pass for non-logtrigger +func (v *EthereumKeeperConsumer) Start() error { + return nil +} + func (v *EthereumKeeperConsumer) Address() string { return v.address.Hex() } @@ -1532,6 +1533,49 @@ func (v *EthereumKeeperConsumer) Counter(ctx context.Context) (*big.Int, error) return cnt, nil } +type EthereumAutomationLogCounterConsumer struct { + client blockchain.EVMClient + consumer *log_upkeep_counter_wrapper.LogUpkeepCounter + address *common.Address +} + +func (v *EthereumAutomationLogCounterConsumer) Address() string { + return v.address.Hex() +} + +func (v *EthereumAutomationLogCounterConsumer) Start() error { + txOpts, err := v.client.TransactionOpts(v.client.GetDefaultWallet()) + if err != nil { + return err + } + + tx, err := v.consumer.Start(txOpts) + if err != nil { + return err + } + return v.client.ProcessTransaction(tx) +} + +func (v *EthereumAutomationLogCounterConsumer) Fund(ethAmount *big.Float) error { + gasEstimates, err := v.client.EstimateGas(geth.CallMsg{}) + if err != nil { + return err + } + return v.client.Fund(v.address.Hex(), ethAmount, gasEstimates) +} + +func (v *EthereumAutomationLogCounterConsumer) Counter(ctx context.Context) (*big.Int, error) { + opts := &bind.CallOpts{ + From: common.HexToAddress(v.client.GetDefaultWallet().Address()), + Context: ctx, + } + cnt, err := v.consumer.Counter(opts) + if err != nil { + return nil, err + } + return cnt, nil +} + // EthereumKeeperConsumerPerformance represents a more complicated keeper consumer contract, one intended only for // performance tests. type EthereumKeeperConsumerPerformance struct { @@ -1690,17 +1734,7 @@ func (v *EthereumKeeperRegistrar) Fund(ethAmount *big.Float) error { } // EncodeRegisterRequest encodes register request to call it through link token TransferAndCall -func (v *EthereumKeeperRegistrar) EncodeRegisterRequest( - name string, - email []byte, - upkeepAddr string, - gasLimit uint32, - adminAddr string, - checkData []byte, - amount *big.Int, - source uint8, - senderAddr string, -) ([]byte, error) { +func (v *EthereumKeeperRegistrar) EncodeRegisterRequest(name string, email []byte, upkeepAddr string, gasLimit uint32, adminAddr string, checkData []byte, amount *big.Int, source uint8, senderAddr string, isLogTrigger bool) ([]byte, error) { if v.registrar20 != nil { registryABI, err := abi.JSON(strings.NewReader(keeper_registrar_wrapper2_0.KeeperRegistrarMetaData.ABI)) if err != nil { @@ -1724,25 +1758,74 @@ func (v *EthereumKeeperRegistrar) EncodeRegisterRequest( } return req, nil } else if v.registrar21 != nil { - req, err := registrarABI.Pack( - "register", - name, - email, - common.HexToAddress(upkeepAddr), - gasLimit, - common.HexToAddress(adminAddr), - uint8(0), // trigger type - checkData, - []byte{}, // triggerConfig - []byte{}, // offchainConfig - amount, - common.HexToAddress(senderAddr), - ) + if isLogTrigger { + // bytes representation of 0x3d53a39550e04688065827f3bb86584cb007ab9ebca7ebd528e7301c9c31eb5d + topic0InBytes := [32]byte{ + 61, 83, 163, 149, 80, 224, 70, 136, + 6, 88, 39, 243, 187, 134, 88, 76, + 176, 7, 171, 158, 188, 167, 235, + 213, 40, 231, 48, 28, 156, 49, 235, 93, + } - if err != nil { - return nil, err + // bytes representation of 0x0000000000000000000000000000000000000000000000000000000000000000 + bytes0 := [32]byte{ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + } + + logTriggerConfigStruct := automation_utils_2_1.LogTriggerConfig{ + ContractAddress: common.HexToAddress(upkeepAddr), + FilterSelector: 0, + Topic0: topic0InBytes, + Topic1: bytes0, + Topic2: bytes0, + Topic3: bytes0, + } + encodedLogTriggerConfig, err := utilsABI.Methods["_logTriggerConfig"].Inputs.Pack(&logTriggerConfigStruct) + if err != nil { + return nil, err + } + + req, err := registrarABI.Pack( + "register", + name, + email, + common.HexToAddress(upkeepAddr), + gasLimit, + common.HexToAddress(adminAddr), + uint8(1), // trigger type + checkData, + encodedLogTriggerConfig, // triggerConfig + []byte{}, // offchainConfig + amount, + common.HexToAddress(senderAddr), + ) + + if err != nil { + return nil, err + } + return req, nil + + } else { + req, err := registrarABI.Pack( + "register", + name, + email, + common.HexToAddress(upkeepAddr), + gasLimit, + common.HexToAddress(adminAddr), + uint8(0), // trigger type + checkData, + []byte{}, // triggerConfig + []byte{}, // offchainConfig + amount, + common.HexToAddress(senderAddr), + ) + + if err != nil { + return nil, err + } + return req, nil } - return req, nil } registryABI, err := abi.JSON(strings.NewReader(keeper_registrar_wrapper1_2.KeeperRegistrarMetaData.ABI)) if err != nil { diff --git a/integration-tests/reorg/automation_reorg_test.go b/integration-tests/reorg/automation_reorg_test.go index 3504aa3ad6a..cfc6a2b2968 100644 --- a/integration-tests/reorg/automation_reorg_test.go +++ b/integration-tests/reorg/automation_reorg_test.go @@ -186,17 +186,7 @@ func TestAutomationReorg(t *testing.T) { require.NoError(t, err, "Registry config should be be set successfully") require.NoError(t, chainClient.WaitForEvents(), "Waiting for config to be set") - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - numberOfUpkeeps, - big.NewInt(defaultLinkFunds), - defaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, numberOfUpkeeps, big.NewInt(defaultLinkFunds), defaultUpkeepGasLimit, false) l.Info().Msg("Waiting for all upkeeps to be performed") diff --git a/integration-tests/smoke/automation_test.go b/integration-tests/smoke/automation_test.go index bf1d607bbb4..88a1a1eae44 100644 --- a/integration-tests/smoke/automation_test.go +++ b/integration-tests/smoke/automation_test.go @@ -104,12 +104,11 @@ func SetupAutomationBasic(t *testing.T, nodeUpgrade bool) { registryVersions := map[string]ethereum.KeeperRegistryVersion{ "registry_2_0": ethereum.RegistryVersion_2_0, - //"registry_2_1": ethereum.RegistryVersion_2_1, + //"registry_2_1_conditional": ethereum.RegistryVersion_2_1, + //"registry_2_1_logtrigger": ethereum.RegistryVersion_2_1, } - for n, rv := range registryVersions { - name := n - registryVersion := rv + for name, registryVersion := range registryVersions { t.Run(name, func(t *testing.T) { t.Parallel() @@ -133,6 +132,9 @@ func SetupAutomationBasic(t *testing.T, nodeUpgrade bool) { return } + // Use the name to determine if this is a log trigger or not + isLogTrigger := name == "registry_2_1_logtrigger" + consumers, upkeepIDs := actions.DeployConsumers( t, registry, @@ -143,12 +145,25 @@ func SetupAutomationBasic(t *testing.T, nodeUpgrade bool) { defaultAmountOfUpkeeps, big.NewInt(automationDefaultLinkFunds), automationDefaultUpkeepGasLimit, + isLogTrigger, ) l.Info().Msg("Waiting for all upkeeps to be performed") gom := gomega.NewGomegaWithT(t) + + // Wait for 30 seconds to allow everything to be ready before emitting logs + time.Sleep(30 * time.Second) + for i := 0; i < len(upkeepIDs); i++ { + err := consumers[i].Start() + if err != nil { + return + } + } + + startTime := time.Now() + // TODO Tune this timeout window after stress testing gom.Eventually(func(g gomega.Gomega) { - // Check if the upkeeps are performing multiple times by analyzing their counters and checking they are greater than 10 + // Check if the upkeeps are performing multiple times by analyzing their counters for i := 0; i < len(upkeepIDs); i++ { counter, err := consumers[i].Counter(context.Background()) require.NoError(t, err, "Failed to retrieve consumer counter for upkeep at index %d", i) @@ -159,6 +174,8 @@ func SetupAutomationBasic(t *testing.T, nodeUpgrade bool) { } }, "5m", "1s").Should(gomega.Succeed()) // ~1m for cluster setup, ~2m for performing each upkeep 5 times, ~2m buffer + l.Info().Msgf("Total time taken to get 5 performs for each upkeep: %s", time.Since(startTime)) + if nodeUpgrade { expect := 5 // Upgrade the nodes one at a time and check that the upkeeps are still being performed @@ -222,17 +239,7 @@ func TestAutomationAddFunds(t *testing.T) { return } - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - defaultAmountOfUpkeeps, - big.NewInt(1), - automationDefaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, defaultAmountOfUpkeeps, big.NewInt(1), automationDefaultUpkeepGasLimit, false) gom := gomega.NewGomegaWithT(t) // Since the upkeep is currently underfunded, check that it doesn't get executed @@ -275,17 +282,7 @@ func TestAutomationPauseUnPause(t *testing.T) { return } - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - defaultAmountOfUpkeeps, - big.NewInt(automationDefaultLinkFunds), - automationDefaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, defaultAmountOfUpkeeps, big.NewInt(automationDefaultLinkFunds), automationDefaultUpkeepGasLimit, false) gom := gomega.NewGomegaWithT(t) gom.Eventually(func(g gomega.Gomega) { @@ -359,17 +356,7 @@ func TestAutomationRegisterUpkeep(t *testing.T) { return } - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - defaultAmountOfUpkeeps, - big.NewInt(automationDefaultLinkFunds), - automationDefaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, defaultAmountOfUpkeeps, big.NewInt(automationDefaultLinkFunds), automationDefaultUpkeepGasLimit, false) var initialCounters = make([]*big.Int, len(upkeepIDs)) gom := gomega.NewGomegaWithT(t) @@ -432,17 +419,7 @@ func TestAutomationPauseRegistry(t *testing.T) { return } - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - defaultAmountOfUpkeeps, - big.NewInt(automationDefaultLinkFunds), - automationDefaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, defaultAmountOfUpkeeps, big.NewInt(automationDefaultLinkFunds), automationDefaultUpkeepGasLimit, false) gom := gomega.NewGomegaWithT(t) // Observe that the upkeeps which are initially registered are performing @@ -491,17 +468,7 @@ func TestAutomationKeeperNodesDown(t *testing.T) { return } - consumers, upkeepIDs := actions.DeployConsumers( - t, - registry, - registrar, - linkToken, - contractDeployer, - chainClient, - defaultAmountOfUpkeeps, - big.NewInt(automationDefaultLinkFunds), - automationDefaultUpkeepGasLimit, - ) + consumers, upkeepIDs := actions.DeployConsumers(t, registry, registrar, linkToken, contractDeployer, chainClient, defaultAmountOfUpkeeps, big.NewInt(automationDefaultLinkFunds), automationDefaultUpkeepGasLimit, false) gom := gomega.NewGomegaWithT(t) nodesWithoutBootstrap := chainlinkNodes[1:] diff --git a/integration-tests/testsetups/keeper_benchmark.go b/integration-tests/testsetups/keeper_benchmark.go index 4b2691ca2ef..8bc11c43599 100644 --- a/integration-tests/testsetups/keeper_benchmark.go +++ b/integration-tests/testsetups/keeper_benchmark.go @@ -542,10 +542,7 @@ func (k *KeeperBenchmarkTest) DeployBenchmarkKeeperContracts( linkFunds = big.NewInt(0).Add(linkFunds, minLinkBalance) - upkeepIds := actions.RegisterUpkeepContractsWithCheckData( - t, k.linkToken, linkFunds, k.chainClient, uint32(upkeep.UpkeepGasLimit), registry, - registrar, upkeep.NumberOfUpkeeps, upkeepAddresses, checkData, - ) + upkeepIds := actions.RegisterUpkeepContractsWithCheckData(t, k.linkToken, linkFunds, k.chainClient, uint32(upkeep.UpkeepGasLimit), registry, registrar, upkeep.NumberOfUpkeeps, upkeepAddresses, checkData, false) k.keeperRegistries[index] = registry k.keeperRegistrars[index] = registrar From 209f8c0be705a11770f334d7407c8d34f024a42e Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Tue, 22 Aug 2023 13:26:44 +0100 Subject: [PATCH 224/270] fix nil latest block in upkeep provider (#10281) --- .../ocr2keeper/evm21/upkeep_provider.go | 4 ++ .../ocr2keeper/evm21/upkeep_provider_test.go | 58 +++++++++++-------- 2 files changed, 37 insertions(+), 25 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go index 787675ba24f..8e08008eca4 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider.go @@ -2,6 +2,7 @@ package evm import ( "context" + "fmt" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" @@ -27,6 +28,9 @@ func NewUpkeepProvider(activeUpkeeps ActiveUpkeepList, bs *BlockSubscriber, lp l func (p *upkeepProvider) GetActiveUpkeeps(ctx context.Context) ([]ocr2keepers.UpkeepPayload, error) { latestBlock := p.bs.latestBlock.Load() + if latestBlock == nil { + return nil, fmt.Errorf("no latest block found when fetching active upkeeps") + } var payloads []ocr2keepers.UpkeepPayload for _, uid := range p.activeUpkeeps.View(ocr2keepers.ConditionTrigger) { payload, err := core.NewUpkeepPayload( diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go index e55a9753eca..ac49675812e 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeep_provider_test.go @@ -1,34 +1,27 @@ package evm import ( - "bytes" "math/big" - "sort" + "sync/atomic" "testing" - coreTypes "github.com/ethereum/go-ethereum/core/types" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" - "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" - clientmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { - t.Skip() ctx := testutils.Context(t) - c := new(clientmocks.Client) - bs := &BlockSubscriber{} var lp logpoller.LogPoller tests := []struct { name string active ActiveUpkeepList - blockHeader coreTypes.Header + latestBlock *ocr2keepers.BlockKey want []ocr2keepers.UpkeepPayload wantErr bool }{ @@ -39,7 +32,7 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { return []*big.Int{} }, }, - coreTypes.Header{Number: big.NewInt(0)}, + &ocr2keepers.BlockKey{Number: 1}, nil, false, }, @@ -53,38 +46,53 @@ func TestUpkeepProvider_GetActiveUpkeeps(t *testing.T) { } }, }, - coreTypes.Header{Number: big.NewInt(1)}, + &ocr2keepers.BlockKey{Number: 1}, []ocr2keepers.UpkeepPayload{ { - UpkeepID: core.UpkeepIDFromInt("10"), + UpkeepID: core.UpkeepIDFromInt("1"), + Trigger: ocr2keepers.NewTrigger(ocr2keepers.BlockNumber(1), [32]byte{}), + WorkID: "b10e2d527612073b26eecdfd717e6a320cf44b4afac2b0732d9fcbe2b7fa0cf6", }, { - UpkeepID: core.UpkeepIDFromInt("15"), + UpkeepID: core.UpkeepIDFromInt("2"), + Trigger: ocr2keepers.NewTrigger(ocr2keepers.BlockNumber(1), [32]byte{}), + WorkID: "405787fa12a823e0f2b7631cc41b3ba8828b3321ca811111fa75cd3aa3bb5ace", }, }, false, }, + { + "latest block not found", + &mockActiveUpkeepList{ + ViewFn: func(upkeepType ...ocr2keepers.UpkeepType) []*big.Int { + return []*big.Int{ + big.NewInt(1), + big.NewInt(2), + } + }, + }, + nil, + []ocr2keepers.UpkeepPayload{}, + true, + }, } for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { - b := coreTypes.NewBlockWithHeader(&tc.blockHeader) - c.On("BlockByNumber", mock.Anything, mock.Anything).Return(b, nil) - + bs := &BlockSubscriber{ + latestBlock: atomic.Pointer[ocr2keepers.BlockKey]{}, + } + bs.latestBlock.Store(tc.latestBlock) p := NewUpkeepProvider(tc.active, bs, lp) got, err := p.GetActiveUpkeeps(ctx) + if tc.wantErr { + require.Error(t, err) + return + } require.NoError(t, err) require.Len(t, got, len(tc.want)) - sort.Slice(got, func(i, j int) bool { - return bytes.Compare(got[i].UpkeepID[:], got[j].UpkeepID[:]) < 0 - }) - for i, payload := range got { - expected := tc.want[i] - // require.Equal(t, expected.ID, payload.ID) // TODO: uncomment once we change to workID - require.Equal(t, expected.UpkeepID, payload.UpkeepID) - require.Equal(t, b.Number().Int64(), payload.Trigger.BlockNumber) - } + require.Equal(t, tc.want, got) }) } } From c909ac500bf23d790cf3b84db7292c88440b2736 Mon Sep 17 00:00:00 2001 From: Sam Date: Tue, 22 Aug 2023 08:37:04 -0400 Subject: [PATCH 225/270] Zero feedID is treated the same as absent feed ID (#10283) --- core/services/ocr2/delegate.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 135344728a2..5483b4c8b80 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -331,7 +331,7 @@ func (d *Delegate) ServicesForSpec(jb job.Job, qopts ...pg.QOpt) ([]job.ServiceC ContractID: spec.ContractID, TransmitterID: transmitterID, } - if spec.FeedID != nil { + if spec.FeedID != nil && (*spec.FeedID != (common.Hash{})) { lggrCtx.FeedID = *spec.FeedID spec.RelayConfig["feedID"] = spec.FeedID } @@ -486,7 +486,7 @@ func (d *Delegate) newServicesMercury( lc ocrtypes.LocalConfig, ocrLogger commontypes.Logger, ) ([]job.ServiceCtx, error) { - if jb.OCR2OracleSpec.FeedID == nil { + if jb.OCR2OracleSpec.FeedID == nil || (*jb.OCR2OracleSpec.FeedID == (common.Hash{})) { return nil, errors.Errorf("ServicesForSpec: mercury job type requires feedID") } spec := jb.OCR2OracleSpec From 0c7f635dde3071036559efc75c468d9738c44144 Mon Sep 17 00:00:00 2001 From: Mateusz Sekara Date: Tue, 22 Aug 2023 14:44:48 +0200 Subject: [PATCH 226/270] Fixing missing statement termination in migration 0182 (#10280) * Fixing migration 0182, because of the missing ';' * Fixing migration 0182, because of the missing ';' --- core/store/migrate/migrations/0182_nullable_feed_id.sql | 2 +- .../migrate/migrations/0188_nullable_feed_id_fix.sql | 9 +++++++++ 2 files changed, 10 insertions(+), 1 deletion(-) create mode 100644 core/store/migrate/migrations/0188_nullable_feed_id_fix.sql diff --git a/core/store/migrate/migrations/0182_nullable_feed_id.sql b/core/store/migrate/migrations/0182_nullable_feed_id.sql index f7d3dbf131e..94b2e201b76 100644 --- a/core/store/migrate/migrations/0182_nullable_feed_id.sql +++ b/core/store/migrate/migrations/0182_nullable_feed_id.sql @@ -1,6 +1,6 @@ -- +goose Up ALTER TABLE ocr2_oracle_specs ALTER COLUMN feed_id DROP NOT NULL, ALTER COLUMN feed_id SET DEFAULT NULL; -UPDATE ocr2_oracle_specs SET feed_id=NULL WHERE feed_id='\x0000000000000000000000000000000000000000000000000000000000000000' +UPDATE ocr2_oracle_specs SET feed_id=NULL WHERE feed_id='\x0000000000000000000000000000000000000000000000000000000000000000'; -- +goose Down UPDATE ocr2_oracle_specs SET feed_id='\x0000000000000000000000000000000000000000000000000000000000000000' WHERE feed_id IS NULL; diff --git a/core/store/migrate/migrations/0188_nullable_feed_id_fix.sql b/core/store/migrate/migrations/0188_nullable_feed_id_fix.sql new file mode 100644 index 00000000000..572f8da6279 --- /dev/null +++ b/core/store/migrate/migrations/0188_nullable_feed_id_fix.sql @@ -0,0 +1,9 @@ +-- +goose Up +UPDATE ocr2_oracle_specs +SET feed_id=NULL +WHERE feed_id = '\x0000000000000000000000000000000000000000000000000000000000000000'; + +-- +goose Down +UPDATE ocr2_oracle_specs +SET feed_id='\x0000000000000000000000000000000000000000000000000000000000000000' +WHERE feed_id IS NULL; From eac93e5a8b097b0219789acd12205119eb5920a4 Mon Sep 17 00:00:00 2001 From: ferglor <19188060+ferglor@users.noreply.github.com> Date: Tue, 22 Aug 2023 14:57:32 +0100 Subject: [PATCH 227/270] Skip KeeperPluginLogUpkeep (#10286) --- core/services/ocr2/plugins/ocr2keeper/integration_21_test.go | 1 + 1 file changed, 1 insertion(+) diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go index 7a808f66f6b..ce1ea6e344b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go @@ -165,6 +165,7 @@ func TestIntegration_KeeperPluginConditionalUpkeep(t *testing.T) { } func TestIntegration_KeeperPluginLogUpkeep(t *testing.T) { + t.Skip() // TODO: fix test (fails in CI) g := gomega.NewWithT(t) // setup blockchain From 5933703cfc431fd5a2b5a9a2e1ff889252ac31d5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 22 Aug 2023 09:37:45 -0500 Subject: [PATCH 228/270] Bump github.com/pressly/goose/v3 from 3.5.3 to 3.15.0 (#10185) * Bump github.com/pressly/goose/v3 from 3.5.3 to 3.15.0 Bumps [github.com/pressly/goose/v3](https://github.com/pressly/goose) from 3.5.3 to 3.15.0. - [Release notes](https://github.com/pressly/goose/releases) - [Changelog](https://github.com/pressly/goose/blob/master/CHANGELOG.md) - [Commits](https://github.com/pressly/goose/compare/v3.5.3...v3.15.0) --- updated-dependencies: - dependency-name: github.com/pressly/goose/v3 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * core/store/migrate/migrations: upgrade from deprecated goose API * core/store/migrate: add migrations/*.go to embeded file system --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: jmank88 --- core/scripts/go.mod | 6 +- core/scripts/go.sum | 247 ++--------------- core/store/migrate/migrate.go | 2 +- .../migrations/0036_external_job_id.go | 17 +- .../migrations/0054_remove_legacy_pipeline.go | 11 +- .../migrate/migrations/0056_multichain.go | 13 +- go.mod | 10 +- go.sum | 252 ++---------------- integration-tests/go.mod | 4 +- integration-tests/go.sum | 10 +- 10 files changed, 76 insertions(+), 496 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index da41fc877e2..d8b38e9b891 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -192,7 +192,7 @@ require ( github.com/jmoiron/sqlx v1.3.5 // indirect github.com/jpillora/backoff v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect - github.com/klauspost/compress v1.16.3 // indirect + github.com/klauspost/compress v1.16.7 // indirect github.com/klauspost/cpuid/v2 v2.2.4 // indirect github.com/koron/go-ssdp v0.0.2 // indirect github.com/kr/pretty v0.3.1 // indirect @@ -269,7 +269,7 @@ require ( github.com/mwitkow/grpc-proxy v0.0.0-20230212185441-f345521cb9c9 // indirect github.com/oklog/run v1.1.0 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect - github.com/opencontainers/image-spec v1.1.0-rc3 // indirect + github.com/opencontainers/image-spec v1.1.0-rc4 // indirect github.com/opentracing/opentracing-go v1.2.0 // indirect github.com/patrickmn/go-cache v2.1.0+incompatible // indirect github.com/pelletier/go-toml v1.9.5 // indirect @@ -277,7 +277,7 @@ require ( github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c // indirect - github.com/pressly/goose/v3 v3.5.3 // indirect + github.com/pressly/goose/v3 v3.15.0 // indirect github.com/prometheus/client_golang v1.16.0 // indirect github.com/prometheus/client_model v0.4.0 // indirect github.com/prometheus/common v0.44.0 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 576c425ecc9..4814f0769b6 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1,4 +1,3 @@ -bazil.org/fuse v0.0.0-20200407214033-5883e5a4b512/go.mod h1:FbcW6z/2VytnFDhZfumh8Ss8zxHE6qpMP5sHTRe0EaM= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= @@ -71,11 +70,6 @@ github.com/AlekSi/pointer v1.1.0 h1:SSDMPcXD9jSl8FPy9cRzoRaMJtm9g9ggGTxecRUbQoI= github.com/AlekSi/pointer v1.1.0/go.mod h1:y7BvfRI3wXPWKXEBhU71nbnIEEZX0QTSB2Bj48UJIZE= github.com/AndreasBriese/bbloom v0.0.0-20180913140656-343706a395b7/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= -github.com/Azure/azure-sdk-for-go/sdk/azcore v0.19.0/go.mod h1:h6H6c8enJmmocHUbLiiGY6sx7f9i+X3m1CHdd5c6Rdw= -github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.11.0/go.mod h1:HcM1YX14R7CJcghJGOYCgdezslRSVzqwLf/q+4Y2r/0= -github.com/Azure/azure-sdk-for-go/sdk/internal v0.7.0/go.mod h1:yqy467j36fJxcRV2TzfVZ1pCb5vxm4BtZPUdYWe/Xo8= -github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= @@ -83,7 +77,6 @@ github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbi github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= -github.com/ClickHouse/clickhouse-go v1.5.4/go.mod h1:EaI/sW7Azgz9UATzd5ZdZHRUhHgv5+JMS9NSr2smCJI= github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/CosmWasm/wasmd v0.40.1 h1:LxbO78t/6S8TkeQlUrJ0m5O87HtAwLx4RGHq3rdrOEU= @@ -102,11 +95,9 @@ github.com/Kubuxu/go-os-helper v0.0.1/go.mod h1:N8B+I7vPCT80IcP58r50u4+gEEcsZETF github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/Masterminds/semver/v3 v3.2.1 h1:RN9w6+7QoMeJVGyfmbcgs28Br8cvmnucEXnY0rYXWg0= github.com/Masterminds/semver/v3 v3.2.1/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ= -github.com/Microsoft/go-winio v0.5.1/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= -github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8D7ML55dXQrVaamCz2vxCfdQBasLZfHKk= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OneOfOne/xxhash v1.2.5 h1:zl/OfRA6nftbBK9qTohYBJ5xvw6C/oNKizR7cZGl3cI= github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= @@ -156,8 +147,6 @@ github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1U github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bits-and-blooms/bitset v1.2.0/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA= -github.com/bkaradzic/go-lz4 v1.0.0/go.mod h1:0YdlkowM3VswSROI7qDxhRvJ3sLhlFrRRwjwegp5jy4= github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= github.com/blendle/zapdriver v1.3.1 h1:C3dydBOWYRiOk+B8X9IVZ5IOe+7cl+tGOexN4QqHfpE= github.com/blendle/zapdriver v1.3.1/go.mod h1:mdXfREi6u5MArG4j9fewC+FGnXaBR+T4Ox4J2u4eHCc= @@ -182,7 +171,6 @@ github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/cenkalti/backoff/v4 v4.1.2/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/cp v1.1.1 h1:nCb6ZLdB7NRaqsm91JtQTAme2SKJzXVsdPIPkyJr1MU= @@ -192,7 +180,6 @@ github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XL github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M= github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= @@ -200,11 +187,9 @@ github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWR github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/readline v1.5.1 h1:upd/6fQk4src78LMRzh5vItIt361/o4uq553V8B5sGI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/cilium/ebpf v0.6.2/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudflare/golz4 v0.0.0-20150217214814-ef862a3cdc58/go.mod h1:EOBUe0h4xcZ5GoxqC5SDxFQ8gwyZPKQoEzownBlhI80= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -232,10 +217,7 @@ github.com/cometbft/cometbft-db v0.7.0 h1:uBjbrBx4QzU0zOEnU8KxoDl18dMNgDh+zZRUE0 github.com/cometbft/cometbft-db v0.7.0/go.mod h1:yiKJIm2WKrt6x8Cyxtq9YTEcIMPcEe4XPxhgX59Fzf0= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= -github.com/containerd/console v1.0.2/go.mod h1:ytZPjGgY2oeTkAONYafi2kSj0aYggsf8acV1PGKCbzQ= -github.com/containerd/continuity v0.0.0-20190827140505-75bee3e2ccb6/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y= -github.com/containerd/continuity v0.2.2/go.mod h1:pWygW9u7LtS1o4N/Tn0FoCFDIXZ7rxcMX7HX1Dmibvk= -github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= +github.com/containerd/continuity v0.4.1 h1:wQnVrjIyQ8vhU2sgOiL5T07jo+ouqc2bnKsv5/EqGhU= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -245,7 +227,6 @@ github.com/coreos/go-semver v0.3.0 h1:wkHLiw0WNATZnSG7epLsujiMCgPAc9xhjJ4tgnAxmf github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= @@ -269,17 +250,14 @@ github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVN github.com/cosmos/ledger-cosmos-go v0.12.1/go.mod h1:dhO6kj+Y+AHIOgAe4L9HL/6NDdyyth4q238I9yFpD2g= github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= -github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= -github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= github.com/daaku/go.zipexe v1.0.0/go.mod h1:z8IiR6TsVLEYKwXAoE/I+8ys/sDkgTzSL0CLnGVd57E= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= @@ -299,7 +277,6 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= -github.com/denisenkom/go-mssqldb v0.12.0/go.mod h1:iiK0YP1ZeepvmBQk/QpLEhhTNJgfzrpArPY/aFvc9yU= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/dfuse-io/logging v0.0.0-20201110202154-26697de88c79/go.mod h1:V+ED4kT/t/lKtH99JQmKIb0v9WL3VaYkJ36CfHlVECI= github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70 h1:CuJS05R9jmNlUK8GOxrEELPbfXm0EuGh/30LjkjN5vo= @@ -320,16 +297,12 @@ github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUn github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= -github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= -github.com/docker/cli v20.10.11+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v20.10.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/docker v24.0.2+incompatible h1:eATx+oLz9WdNVkQrr0qjQ8HvRJ4bOOxfzEo8R+dA3cg= github.com/docker/docker v24.0.2+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= -github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/docker/go-units v0.5.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= @@ -364,7 +337,6 @@ github.com/fjl/memsize v0.0.0-20190710130421-bcb5799ab5e5 h1:FtmdgXiUlNeRsoNMFlK github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6 h1:u/UEqS66A5ckRmS4yNpjmVH56sVtS/RfclBAYocb4as= github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6/go.mod h1:1i71OnUq3iUe1ma7Lr6yG6/rjvM3emb6yoL7xLFzcVQ= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= -github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k= github.com/frankban/quicktest v1.14.4 h1:g2rn0vABPOOXmZUj+vbmUp0lPoXEMuhTpIluN0XL9UY= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= @@ -445,9 +417,8 @@ github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91 github.com/go-playground/validator/v10 v10.10.0/go.mod h1:74x4gJWsvQexRdW8Pn3dXSGrTK4nAUsbPlLADvpJkos= github.com/go-playground/validator/v10 v10.14.0 h1:vgvQWe3XCz3gIeFDm/HnTIbj6UGmg/+t63MyGU2n5js= github.com/go-playground/validator/v10 v10.14.0/go.mod h1:9iXMNT7sEkjXb0I+enO7QXmzG6QCsPWY4zveKFVRSyU= -github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE= github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= +github.com/go-sql-driver/mysql v1.7.1 h1:lUIinVbN1DY0xBg0eMOzmmtGoHwWBbvnWubQUrtU8EI= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-stack/stack v1.8.1 h1:ntEHSVwIt7PNXNpgPmVfMrNhLtgjlmnZha2kOpuRiDw= github.com/go-stack/stack v1.8.1/go.mod h1:dcoOX6HbPZSZptuspn9bctJ+N/CnF5gGygcUP3XYfe4= @@ -464,7 +435,6 @@ github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU= github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= -github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= @@ -476,8 +446,6 @@ github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= -github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= -github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188/go.mod h1:vXjM/+wXQnTPR4KqTKDgJukSZ6amVRtWMPEjE6sQoK8= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.1.0 h1:/d3pCKDPWNnvIWe0vVUpNP32qc8U3PDVxySP/y360qE= github.com/golang/glog v1.1.0/go.mod h1:pfYeQZ3JWZoXTV5sFc986z3HTpwQs9At6P4ImfuP3NQ= @@ -576,7 +544,6 @@ github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 h1:hR7/MlvK23p6+lIw9S github.com/google/pprof v0.0.0-20230602150820-91b7bce49751/go.mod h1:Jh3hGz2jkYak8qXPD19ryItVnUgpgeqzdkY/D0EaeuA= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.4 h1:1kZ/sQM3srePvKs3tXAvQzo66XfcReoqFpIpIccE7Oc= -github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -691,7 +658,6 @@ github.com/huin/goutil v0.0.0-20170803182201-1ca381bf3150/go.mod h1:PpLOETDnJ0o3 github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= @@ -814,7 +780,6 @@ github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= -github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= github.com/jmoiron/sqlx v1.3.5 h1:vFFPA71p1o5gAeqtEAwLU4dnX2napprKtHr7PYIcN3g= github.com/jmoiron/sqlx v1.3.5/go.mod h1:nRVWtLre0KfCLJvgxzCsLVMogSvQ1zNJtpYr2Ccp0mQ= github.com/joho/godotenv v1.4.0 h1:3l4+N6zfMWnkbPEXKng2o2/MR5mSwTrBih4ZEkkz1lg= @@ -838,7 +803,6 @@ github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2 github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 h1:Z9n2FFNUXsshfwJMBgNA0RU6/i7WVaAegv3PtuIHPMs= -github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= @@ -847,8 +811,8 @@ github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0 github.com/klauspost/compress v1.11.4/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= -github.com/klauspost/compress v1.16.3 h1:XuJt9zzcnaz6a16/OU53ZjWp/v7/42WcR5t2a0PcNQY= -github.com/klauspost/compress v1.16.3/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/klauspost/compress v1.16.7 h1:2mk3MPGNzKyxErAw8YaohYh69+pa4sIQSC0fPGCFR9I= +github.com/klauspost/compress v1.16.7/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.2.4 h1:acbojRNwl3o09bUq+yDCtZFc1aiwaAAxtcn8YkZXnvk= @@ -880,12 +844,10 @@ github.com/leanovate/gopter v0.2.10-0.20210127095200-9abe2343507a/go.mod h1:U2L/ github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= -github.com/lib/pq v0.0.0-20180327071824-d34b9ff171c2/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.10.2/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= -github.com/lib/pq v1.10.4/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/libp2p/go-addr-util v0.0.1/go.mod h1:4ac6O7n9rIAKB1dnd+s8IbbMXkt+oBpzX4/+RACcnlQ= @@ -1104,8 +1066,6 @@ github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN github.com/manifoldco/promptui v0.9.0 h1:3V4HzJk1TtXW1MTZMP7mdlwbBpIinw3HztaIlYthEiA= github.com/manyminds/api2go v0.0.0-20171030193247-e7b693844a6f h1:tVvGiZQFjOXP+9YyGqSA6jE55x1XVxmoPYudncxrZ8U= github.com/manyminds/api2go v0.0.0-20171030193247-e7b693844a6f/go.mod h1:Z60vy0EZVSu0bOugCHdcN5ZxFMKSpjRgsnh0XKPFqqk= -github.com/matryer/is v1.4.0 h1:sosSmIWwkYITGrxZ25ULNDeKiMNzFSr4V/eqBQP0PeE= -github.com/matryer/is v1.4.0/go.mod h1:8I/i5uYgLzgsgEloJE1U6xx5HkBQpAZvepWuujKwMRU= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= @@ -1132,9 +1092,7 @@ github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= github.com/mattn/go-sqlite3 v1.14.6/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= -github.com/mattn/go-sqlite3 v1.14.10/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= github.com/mattn/go-sqlite3 v2.0.3+incompatible h1:gXHsfypPkaMZrKbD5209QV9jbUTJKjyR5WD3HYQSd+U= github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= @@ -1170,13 +1128,10 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4 github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= -github.com/moby/sys/mountinfo v0.4.1/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A= -github.com/moby/term v0.0.0-20201216013528-df9cb8a40635/go.mod h1:FBS0z0QWA44HXygs7VXDUOGoN/1TV3RuWkLO04am3wc= -github.com/moby/term v0.0.0-20220808134915-39b0c02b01ae h1:O4SWKdcHVCvYqyDV+9CJA1fcDN2L11Bule0iFy3YlAI= +github.com/moby/term v0.5.0 h1:xt8Q1nalod/v7BqbG21f8mQPqH+xAaC9C3N3wfWbVP0= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -1184,7 +1139,6 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/modocache/gover v0.0.0-20171022184752-b58185e213c5/go.mod h1:caMODM3PzxT8aQXRPkAt8xlV/e7d7w8GM5g0fa5F0D8= github.com/montanaflynn/stats v0.7.1 h1:etflOAAHORrCC44V+aR6Ftzort912ZU+YLiSTuV8eaE= github.com/montanaflynn/stats v0.7.1/go.mod h1:etXPPgVO6n31NxCd9KQUMvCM+ve0ruNzt6R8Bnaayow= github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= @@ -1197,7 +1151,6 @@ github.com/mr-tron/base58 v1.1.2/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjW github.com/mr-tron/base58 v1.1.3/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= github.com/mr-tron/base58 v1.2.0 h1:T/HDJBh4ZCPbU39/+c3rRvE0uKBQlU27+QI8LJ4t64o= github.com/mr-tron/base58 v1.2.0/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= -github.com/mrunalp/fileutils v0.5.0/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= github.com/multiformats/go-base32 v0.0.3 h1:tw5+NhuwaOjJCC5Pp82QuXbrmLzWg7uxlMFp8Nq/kkI= @@ -1287,22 +1240,16 @@ github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1y github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= github.com/onsi/gomega v1.27.8 h1:gegWiwZjBsf2DgiSbf5hpokZ98JVDMcWkUiigk6/KXc= -github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= -github.com/opencontainers/image-spec v1.0.2/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= -github.com/opencontainers/image-spec v1.1.0-rc3 h1:fzg1mXZFj8YdPeNkRXMg+zb88BFV0Ys52cJydRwBkb8= -github.com/opencontainers/image-spec v1.1.0-rc3/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= -github.com/opencontainers/runc v1.0.2/go.mod h1:aTaHFFwQXuA71CiyxOdFFIorAoemI04suvGRQFzWTD0= +github.com/opencontainers/image-spec v1.1.0-rc4 h1:oOxKUJWnFC4YGHCCMNql1x4YaDfYBTS5Y4x/Cgeo1E0= +github.com/opencontainers/image-spec v1.1.0-rc4/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= github.com/opencontainers/runc v1.1.7 h1:y2EZDS8sNng4Ksf0GUYNhKbTShZJPJg1FiXJNH/uoCk= -github.com/opencontainers/runtime-spec v1.0.3-0.20210326190908-1c3f411f0417/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= -github.com/opencontainers/selinux v1.8.2/go.mod h1:MUIHuUEvKB1wtJjQdOyYRgOnLD2xAPP8dBsCoU0KuF8= github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= -github.com/ory/dockertest/v3 v3.8.1/go.mod h1:wSRQ3wmkz+uSARYMk7kVJFDBGm8x5gSxIhI7NDc+BAQ= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= @@ -1317,10 +1264,8 @@ github.com/pelletier/go-toml/v2 v2.0.9/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdU github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= -github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= -github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4/go.mod h1:4OwLy04Bl9Ef3GJJCoec+30X3LQs/0/m4HFRt/2LUSA= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -1333,8 +1278,8 @@ github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= -github.com/pressly/goose/v3 v3.5.3 h1:lIQIIXVbdO2RuQtJBS1e7MZjKEk0demVWt6i0YPiOrg= -github.com/pressly/goose/v3 v3.5.3/go.mod h1:IL4NNMdXx9O6hHpGbNB5l1hkVe/Avoz4gBDE5g7rQNg= +github.com/pressly/goose/v3 v3.15.0 h1:6tY5aDqFknY6VZkorFGgZtWygodZQxfmmEF4rqyJW9k= +github.com/pressly/goose/v3 v3.15.0/go.mod h1:LlIo3zGccjb/YUgG+Svdb9Er14vefRdlDI7URCDrwYo= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= @@ -1372,8 +1317,7 @@ github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqn github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGnWA97M= github.com/regen-network/protobuf v1.3.3-alpha.regen.1 h1:OHEc+q5iIAXpqiqFKeLpu5NwTIkVXUs48vFMwzqpqY4= github.com/regen-network/protobuf v1.3.3-alpha.regen.1/go.mod h1:2DjTFR1HhMQhiWC5sZ4OhQ3+NtdbZ6oBDKQwq5Ou+FI= -github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0 h1:OdAsTTz6OkFY5QxjkYwrChwuRruF69c169dPK26NUlk= -github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= +github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec h1:W09IVJc94icq4NjY3clb7Lk8O1qJ8BdBEF8z0ibU0rE= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.4.4 h1:8TfxU8dW6PdqD27gjM8MVNuicgxIjxpm4K7x4jp8sis= github.com/rivo/uniseg v0.4.4/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= @@ -1408,7 +1352,6 @@ github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtm github.com/scylladb/go-reflectx v1.0.1 h1:b917wZM7189pZdlND9PbIJ6NQxfDPfBvUaQ7cjj1iZQ= github.com/scylladb/go-reflectx v1.0.1/go.mod h1:rWnOfDIRWBGN0miMLIcoPt/Dhi2doCMZqwMCJ3KupFc= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= @@ -1422,8 +1365,6 @@ github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeV github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= @@ -1512,7 +1453,6 @@ github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXl github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/subosito/gotenv v1.4.2 h1:X1TuBLAMDFbaTAChgCBLu3DU3UPyELpnF2jjJ2cz/S8= github.com/subosito/gotenv v1.4.2/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= -github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww= github.com/syndtr/goleveldb v1.0.0/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ= github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d h1:vfofYNRScrDdvS342BElfbETmL1Aiz3i2t0zfRj16Hs= github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d/go.mod h1:RRCYJbIwD5jmqPI9XoAFR0OcDxqUctll6zUj/+B4S48= @@ -1543,7 +1483,6 @@ github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+F github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= -github.com/tv42/httpunix v0.0.0-20191220191345-2ba4b9c3382c/go.mod h1:hzIxponao9Kjc7aWznkXaL4U4TWaDSs8zcsY4Ka08nM= github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= @@ -1565,7 +1504,6 @@ github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722 h1:10Nbw6cACsnQm7 github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722/go.mod h1:c8J0h9aULj2i3umrfyestM6jCq0LK0U6ly6bWy96nd4= github.com/unrolled/secure v1.13.0 h1:sdr3Phw2+f8Px8HE5sd1EHdj1aV3yUwed/uZXChLFsk= github.com/unrolled/secure v1.13.0/go.mod h1:BmF5hyM6tXczk3MpQkFf1hpKSRqCyhqcbiQtiAF7+40= -github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli v1.22.14 h1:ebbhrRiGK2i4naQJr+1Xj92HXZCrK7MsyTS/ob3HnAk= github.com/urfave/cli v1.22.14/go.mod h1:X0eDS6pD6Exaclxm99NJ3FiCDRED7vIHpx2mDOHLvkA= github.com/urfave/cli/v2 v2.17.2-0.20221006022127-8f469abc00aa h1:5SqCsI/2Qya2bCzK15ozrqo2sZxkh0FHynJZOTVoV6Q= @@ -1577,8 +1515,6 @@ github.com/valyala/fastjson v1.4.1/go.mod h1:nV6MsjxL2IMJQUoHDIrjEI7oLyeqK6aBD7E github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= -github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE= -github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU= github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1 h1:EKhdznlJHPMoKr0XTrX+IlJs1LH3lyx2nfr1dOlZ79k= github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1/go.mod h1:8UvriyWtv5Q5EOgjHaSseUEdkQfvwFv1I/In/O2M9gc= github.com/whyrusleeping/go-logging v0.0.0-20170515211332-0457bb6b88fc/go.mod h1:bopw91TMyo8J3tvftk8xmU2kPmlrt4nScJQZU2hE5EM= @@ -1605,13 +1541,11 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= -github.com/ziutek/mymysql v1.5.4/go.mod h1:LMSpPZ6DbqWFxNCHW77HeMg9I646SAhApZ/wKdgO/C0= github.com/zondax/hid v0.9.1 h1:gQe66rtmyZ8VeGFcOpbuH3r7erYtNEAezCAYu8LdkJo= github.com/zondax/hid v0.9.1/go.mod h1:l5wttcP0jwtdLjqjMMWFVEE7d1zO0jvSPA9OPZxWpEM= github.com/zondax/ledger-go v0.14.1 h1:Pip65OOl4iJ84WTpA4BKChvOufMhhbxED3BaihoZN4c= @@ -1705,7 +1639,6 @@ golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200602180216-279210d13fed/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201203163018-be400aefbc4c/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= @@ -1715,7 +1648,6 @@ golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20220210151621-f4118a5b28e2/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58= golang.org/x/crypto v0.11.0 h1:6Ewdq3tDic1mg5xRO4milcWCfMVQhI4NkqWWvqejpuA= golang.org/x/crypto v0.11.0/go.mod h1:xgJhtzW8F9jGdVFWZESrid1U1bjeNy4zgy5cRr/CIio= @@ -1756,7 +1688,6 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= @@ -1814,11 +1745,7 @@ golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96b golang.org/x/net v0.0.0-20210423184538-5f58ad60dda6/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210510120150-4163338589ed/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20210610132358-84b48f89b13b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= @@ -1873,7 +1800,6 @@ golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190526052359-791d8a0f4d09/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190606203320-7fc4e5ec1444/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1885,10 +1811,8 @@ golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191210023423-ac6580df4449/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1905,18 +1829,14 @@ golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200831180312-196b9ba8737a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201126233918-771906719818/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201204225414-ed752295db88/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1925,19 +1845,15 @@ golang.org/x/sys v0.0.0-20210331175145-43e1dd70ce54/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210426230700-d19ff857e887/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210629170331-7dc0b73dc9fb/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210819135213-f52c844e1c1c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210902050250-f475640dd07b/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220405052023-b1e9470b6e64/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -1998,7 +1914,6 @@ golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190823170909-c4a336ef6a2f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -2040,7 +1955,6 @@ golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20201124115921-2c860bdd6e78/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= @@ -2051,7 +1965,6 @@ golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= golang.org/x/tools v0.1.1/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.11.0 h1:EMCa6U9S2LtZXLAMoWiR/R8dAQFRqbAitmbJ2UKhoi8= golang.org/x/tools v0.11.0/go.mod h1:anzJrxPjNtfgiYQYirP2CPGzGLxrH2u2QBhn6Bf3qY8= @@ -2236,8 +2149,6 @@ gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= -gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -2247,134 +2158,16 @@ honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= -lukechampine.com/uint128 v1.1.1/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= -lukechampine.com/uint128 v1.2.0 h1:mBi/5l91vocEN8otkC5bDLhi2KdCticRiwbdB0O+rjI= -lukechampine.com/uint128 v1.2.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= -modernc.org/cc/v3 v3.33.6/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.33.9/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.33.11/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.34.0/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.0/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.4/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.5/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.7/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.8/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.10/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.15/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.16/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.17/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.18/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.20/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.22 h1:BzShpwCAP7TWzFppM4k2t03RhXhgYqaibROWkrWq7lE= -modernc.org/cc/v3 v3.35.22/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/ccgo/v3 v3.9.5/go.mod h1:umuo2EP2oDSBnD3ckjaVUXMrmeAw8C8OSICVa0iFf60= -modernc.org/ccgo/v3 v3.10.0/go.mod h1:c0yBmkRFi7uW4J7fwx/JiijwOjeAeR2NoSaRVFPmjMw= -modernc.org/ccgo/v3 v3.11.0/go.mod h1:dGNposbDp9TOZ/1KBxghxtUp/bzErD0/0QW4hhSaBMI= -modernc.org/ccgo/v3 v3.11.1/go.mod h1:lWHxfsn13L3f7hgGsGlU28D9eUOf6y3ZYHKoPaKU0ag= -modernc.org/ccgo/v3 v3.11.3/go.mod h1:0oHunRBMBiXOKdaglfMlRPBALQqsfrCKXgw9okQ3GEw= -modernc.org/ccgo/v3 v3.12.4/go.mod h1:Bk+m6m2tsooJchP/Yk5ji56cClmN6R1cqc9o/YtbgBQ= -modernc.org/ccgo/v3 v3.12.6/go.mod h1:0Ji3ruvpFPpz+yu+1m0wk68pdr/LENABhTrDkMDWH6c= -modernc.org/ccgo/v3 v3.12.8/go.mod h1:Hq9keM4ZfjCDuDXxaHptpv9N24JhgBZmUG5q60iLgUo= -modernc.org/ccgo/v3 v3.12.11/go.mod h1:0jVcmyDwDKDGWbcrzQ+xwJjbhZruHtouiBEvDfoIsdg= -modernc.org/ccgo/v3 v3.12.14/go.mod h1:GhTu1k0YCpJSuWwtRAEHAol5W7g1/RRfS4/9hc9vF5I= -modernc.org/ccgo/v3 v3.12.18/go.mod h1:jvg/xVdWWmZACSgOiAhpWpwHWylbJaSzayCqNOJKIhs= -modernc.org/ccgo/v3 v3.12.20/go.mod h1:aKEdssiu7gVgSy/jjMastnv/q6wWGRbszbheXgWRHc8= -modernc.org/ccgo/v3 v3.12.21/go.mod h1:ydgg2tEprnyMn159ZO/N4pLBqpL7NOkJ88GT5zNU2dE= -modernc.org/ccgo/v3 v3.12.22/go.mod h1:nyDVFMmMWhMsgQw+5JH6B6o4MnZ+UQNw1pp52XYFPRk= -modernc.org/ccgo/v3 v3.12.25/go.mod h1:UaLyWI26TwyIT4+ZFNjkyTbsPsY3plAEB6E7L/vZV3w= -modernc.org/ccgo/v3 v3.12.29/go.mod h1:FXVjG7YLf9FetsS2OOYcwNhcdOLGt8S9bQ48+OP75cE= -modernc.org/ccgo/v3 v3.12.36/go.mod h1:uP3/Fiezp/Ga8onfvMLpREq+KUjUmYMxXPO8tETHtA8= -modernc.org/ccgo/v3 v3.12.38/go.mod h1:93O0G7baRST1vNj4wnZ49b1kLxt0xCW5Hsa2qRaZPqc= -modernc.org/ccgo/v3 v3.12.43/go.mod h1:k+DqGXd3o7W+inNujK15S5ZYuPoWYLpF5PYougCmthU= -modernc.org/ccgo/v3 v3.12.46/go.mod h1:UZe6EvMSqOxaJ4sznY7b23/k13R8XNlyWsO5bAmSgOE= -modernc.org/ccgo/v3 v3.12.47/go.mod h1:m8d6p0zNps187fhBwzY/ii6gxfjob1VxWb919Nk1HUk= -modernc.org/ccgo/v3 v3.12.50/go.mod h1:bu9YIwtg+HXQxBhsRDE+cJjQRuINuT9PUK4orOco/JI= -modernc.org/ccgo/v3 v3.12.51/go.mod h1:gaIIlx4YpmGO2bLye04/yeblmvWEmE4BBBls4aJXFiE= -modernc.org/ccgo/v3 v3.12.53/go.mod h1:8xWGGTFkdFEWBEsUmi+DBjwu/WLy3SSOrqEmKUjMeEg= -modernc.org/ccgo/v3 v3.12.54/go.mod h1:yANKFTm9llTFVX1FqNKHE0aMcQb1fuPJx6p8AcUx+74= -modernc.org/ccgo/v3 v3.12.55/go.mod h1:rsXiIyJi9psOwiBkplOaHye5L4MOOaCjHg1Fxkj7IeU= -modernc.org/ccgo/v3 v3.12.56/go.mod h1:ljeFks3faDseCkr60JMpeDb2GSO3TKAmrzm7q9YOcMU= -modernc.org/ccgo/v3 v3.12.57/go.mod h1:hNSF4DNVgBl8wYHpMvPqQWDQx8luqxDnNGCMM4NFNMc= -modernc.org/ccgo/v3 v3.12.60/go.mod h1:k/Nn0zdO1xHVWjPYVshDeWKqbRWIfif5dtsIOCUVMqM= -modernc.org/ccgo/v3 v3.12.66/go.mod h1:jUuxlCFZTUZLMV08s7B1ekHX5+LIAurKTTaugUr/EhQ= -modernc.org/ccgo/v3 v3.12.67/go.mod h1:Bll3KwKvGROizP2Xj17GEGOTrlvB1XcVaBrC90ORO84= -modernc.org/ccgo/v3 v3.12.73/go.mod h1:hngkB+nUUqzOf3iqsM48Gf1FZhY599qzVg1iX+BT3cQ= -modernc.org/ccgo/v3 v3.12.81/go.mod h1:p2A1duHoBBg1mFtYvnhAnQyI6vL0uw5PGYLSIgF6rYY= -modernc.org/ccgo/v3 v3.12.84/go.mod h1:ApbflUfa5BKadjHynCficldU1ghjen84tuM5jRynB7w= -modernc.org/ccgo/v3 v3.12.86/go.mod h1:dN7S26DLTgVSni1PVA3KxxHTcykyDurf3OgUzNqTSrU= -modernc.org/ccgo/v3 v3.12.90/go.mod h1:obhSc3CdivCRpYZmrvO88TXlW0NvoSVvdh/ccRjJYko= -modernc.org/ccgo/v3 v3.12.92/go.mod h1:5yDdN7ti9KWPi5bRVWPl8UNhpEAtCjuEE7ayQnzzqHA= -modernc.org/ccgo/v3 v3.13.1/go.mod h1:aBYVOUfIlcSnrsRVU8VRS35y2DIfpgkmVkYZ0tpIXi4= -modernc.org/ccgo/v3 v3.15.1/go.mod h1:md59wBwDT2LznX/OTCPoVS6KIsdRgY8xqQwBV+hkTH0= -modernc.org/ccgo/v3 v3.15.9/go.mod h1:md59wBwDT2LznX/OTCPoVS6KIsdRgY8xqQwBV+hkTH0= -modernc.org/ccgo/v3 v3.15.10/go.mod h1:wQKxoFn0ynxMuCLfFD09c8XPUCc8obfchoVR9Cn0fI8= -modernc.org/ccgo/v3 v3.15.12/go.mod h1:VFePOWoCd8uDGRJpq/zfJ29D0EVzMSyID8LCMWYbX6I= -modernc.org/ccgo/v3 v3.15.13 h1:hqlCzNJTXLrhS70y1PqWckrF9x1btSQRC7JFuQcBg5c= -modernc.org/ccgo/v3 v3.15.13/go.mod h1:QHtvdpeODlXjdK3tsbpyK+7U9JV4PQsrPGIbtmc0KfY= -modernc.org/ccorpus v1.11.1/go.mod h1:2gEUTrWqdpH2pXsmTM1ZkjeSrUWDpjMu2T6m29L/ErQ= -modernc.org/ccorpus v1.11.4/go.mod h1:2gEUTrWqdpH2pXsmTM1ZkjeSrUWDpjMu2T6m29L/ErQ= -modernc.org/httpfs v1.0.6/go.mod h1:7dosgurJGp0sPaRanU53W4xZYKh14wfzX420oZADeHM= -modernc.org/libc v1.9.8/go.mod h1:U1eq8YWr/Kc1RWCMFUWEdkTg8OTcfLw2kY8EDwl039w= -modernc.org/libc v1.9.11/go.mod h1:NyF3tsA5ArIjJ83XB0JlqhjTabTCHm9aX4XMPHyQn0Q= -modernc.org/libc v1.11.0/go.mod h1:2lOfPmj7cz+g1MrPNmX65QCzVxgNq2C5o0jdLY2gAYg= -modernc.org/libc v1.11.2/go.mod h1:ioIyrl3ETkugDO3SGZ+6EOKvlP3zSOycUETe4XM4n8M= -modernc.org/libc v1.11.5/go.mod h1:k3HDCP95A6U111Q5TmG3nAyUcp3kR5YFZTeDS9v8vSU= -modernc.org/libc v1.11.6/go.mod h1:ddqmzR6p5i4jIGK1d/EiSw97LBcE3dK24QEwCFvgNgE= -modernc.org/libc v1.11.11/go.mod h1:lXEp9QOOk4qAYOtL3BmMve99S5Owz7Qyowzvg6LiZso= -modernc.org/libc v1.11.13/go.mod h1:ZYawJWlXIzXy2Pzghaf7YfM8OKacP3eZQI81PDLFdY8= -modernc.org/libc v1.11.16/go.mod h1:+DJquzYi+DMRUtWI1YNxrlQO6TcA5+dRRiq8HWBWRC8= -modernc.org/libc v1.11.19/go.mod h1:e0dgEame6mkydy19KKaVPBeEnyJB4LGNb0bBH1EtQ3I= -modernc.org/libc v1.11.24/go.mod h1:FOSzE0UwookyT1TtCJrRkvsOrX2k38HoInhw+cSCUGk= -modernc.org/libc v1.11.26/go.mod h1:SFjnYi9OSd2W7f4ct622o/PAYqk7KHv6GS8NZULIjKY= -modernc.org/libc v1.11.27/go.mod h1:zmWm6kcFXt/jpzeCgfvUNswM0qke8qVwxqZrnddlDiE= -modernc.org/libc v1.11.28/go.mod h1:Ii4V0fTFcbq3qrv3CNn+OGHAvzqMBvC7dBNyC4vHZlg= -modernc.org/libc v1.11.31/go.mod h1:FpBncUkEAtopRNJj8aRo29qUiyx5AvAlAxzlx9GNaVM= -modernc.org/libc v1.11.34/go.mod h1:+Tzc4hnb1iaX/SKAutJmfzES6awxfU1BPvrrJO0pYLg= -modernc.org/libc v1.11.37/go.mod h1:dCQebOwoO1046yTrfUE5nX1f3YpGZQKNcITUYWlrAWo= -modernc.org/libc v1.11.39/go.mod h1:mV8lJMo2S5A31uD0k1cMu7vrJbSA3J3waQJxpV4iqx8= -modernc.org/libc v1.11.42/go.mod h1:yzrLDU+sSjLE+D4bIhS7q1L5UwXDOw99PLSX0BlZvSQ= -modernc.org/libc v1.11.44/go.mod h1:KFq33jsma7F5WXiYelU8quMJasCCTnHK0mkri4yPHgA= -modernc.org/libc v1.11.45/go.mod h1:Y192orvfVQQYFzCNsn+Xt0Hxt4DiO4USpLNXBlXg/tM= -modernc.org/libc v1.11.47/go.mod h1:tPkE4PzCTW27E6AIKIR5IwHAQKCAtudEIeAV1/SiyBg= -modernc.org/libc v1.11.49/go.mod h1:9JrJuK5WTtoTWIFQ7QjX2Mb/bagYdZdscI3xrvHbXjE= -modernc.org/libc v1.11.51/go.mod h1:R9I8u9TS+meaWLdbfQhq2kFknTW0O3aw3kEMqDDxMaM= -modernc.org/libc v1.11.53/go.mod h1:5ip5vWYPAoMulkQ5XlSJTy12Sz5U6blOQiYasilVPsU= -modernc.org/libc v1.11.54/go.mod h1:S/FVnskbzVUrjfBqlGFIPA5m7UwB3n9fojHhCNfSsnw= -modernc.org/libc v1.11.55/go.mod h1:j2A5YBRm6HjNkoSs/fzZrSxCuwWqcMYTDPLNx0URn3M= -modernc.org/libc v1.11.56/go.mod h1:pakHkg5JdMLt2OgRadpPOTnyRXm/uzu+Yyg/LSLdi18= -modernc.org/libc v1.11.58/go.mod h1:ns94Rxv0OWyoQrDqMFfWwka2BcaF6/61CqJRK9LP7S8= -modernc.org/libc v1.11.71/go.mod h1:DUOmMYe+IvKi9n6Mycyx3DbjfzSKrdr/0Vgt3j7P5gw= -modernc.org/libc v1.11.75/go.mod h1:dGRVugT6edz361wmD9gk6ax1AbDSe0x5vji0dGJiPT0= -modernc.org/libc v1.11.82/go.mod h1:NF+Ek1BOl2jeC7lw3a7Jj5PWyHPwWD4aq3wVKxqV1fI= -modernc.org/libc v1.11.86/go.mod h1:ePuYgoQLmvxdNT06RpGnaDKJmDNEkV7ZPKI2jnsvZoE= -modernc.org/libc v1.11.87/go.mod h1:Qvd5iXTeLhI5PS0XSyqMY99282y+3euapQFxM7jYnpY= -modernc.org/libc v1.11.88/go.mod h1:h3oIVe8dxmTcchcFuCcJ4nAWaoiwzKCdv82MM0oiIdQ= -modernc.org/libc v1.11.98/go.mod h1:ynK5sbjsU77AP+nn61+k+wxUGRx9rOFcIqWYYMaDZ4c= -modernc.org/libc v1.11.101/go.mod h1:wLLYgEiY2D17NbBOEp+mIJJJBGSiy7fLL4ZrGGZ+8jI= -modernc.org/libc v1.12.0/go.mod h1:2MH3DaF/gCU8i/UBiVE1VFRos4o523M7zipmwH8SIgQ= -modernc.org/libc v1.14.1/go.mod h1:npFeGWjmZTjFeWALQLrvklVmAxv4m80jnG3+xI8FdJk= -modernc.org/libc v1.14.2/go.mod h1:MX1GBLnRLNdvmK9azU9LCxZ5lMyhrbEMK8rG3X/Fe34= -modernc.org/libc v1.14.3/go.mod h1:GPIvQVOVPizzlqyRX3l756/3ppsAgg1QgPxjr5Q4agQ= -modernc.org/libc v1.14.5 h1:DAHvwGoVRDZs5iJXnX9RJrgXSsorupCWmJ2ac964Owk= -modernc.org/libc v1.14.5/go.mod h1:2PJHINagVxO4QW/5OQdRrvMYo+bm5ClpUFfyXCYl9ak= -modernc.org/mathutil v1.1.1/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/mathutil v1.2.2/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/mathutil v1.4.0/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/mathutil v1.4.1 h1:ij3fYGe8zBF4Vu+g0oT7mB06r8sqGWKuJu1yXeR4by8= -modernc.org/mathutil v1.4.1/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/memory v1.0.4/go.mod h1:nV2OApxradM3/OVbs2/0OsP6nPfakXpi50C7dcoHXlc= -modernc.org/memory v1.0.5 h1:XRch8trV7GgvTec2i7jc33YlUI0RKVDBvZ5eZ5m8y14= -modernc.org/memory v1.0.5/go.mod h1:B7OYswTRnfGg+4tDH1t1OeUNnsy2viGTdME4tzd+IjM= -modernc.org/opt v0.1.1 h1:/0RX92k9vwVeDXj+Xn23DKp2VJubL7k8qNffND6qn3A= -modernc.org/opt v0.1.1/go.mod h1:WdSiB5evDcignE70guQKxYUl14mgWtbClRi5wmkkTX0= -modernc.org/sqlite v1.14.6 h1:Jt5P3k80EtDBWaq1beAxnWW+5MdHXbZITujnRS7+zWg= -modernc.org/sqlite v1.14.6/go.mod h1:yiCvMv3HblGmzENNIaNtFhfaNIwcla4u2JQEwJPzfEc= -modernc.org/strutil v1.1.1 h1:xv+J1BXY3Opl2ALrBwyfEikFAj8pmqcpnfmuwUwcozs= -modernc.org/strutil v1.1.1/go.mod h1:DE+MQQ/hjKBZS2zNInV5hhcipt5rLPWkmpbGeW5mmdw= -modernc.org/tcl v1.11.0/go.mod h1:zsTUpbQ+NxQEjOjCUlImDLPv1sG8Ww0qp66ZvyOxCgw= -modernc.org/token v1.0.0 h1:a0jaWiNMDhDUtqOj09wvjWWAqd3q7WpBulmL9H2egsk= -modernc.org/token v1.0.0/go.mod h1:UGzOrNV1mAFSEB63lOFHIpNRUVMvYTc6yu1SMY/XTDM= -modernc.org/z v1.3.0/go.mod h1:+mvgLH814oDjtATDdT3rs84JnUIpkvAF5B8AVkNlE2g= +lukechampine.com/uint128 v1.3.0 h1:cDdUVfRwDUDovz610ABgFD17nXD4/uDgVHl2sC3+sbo= +modernc.org/cc/v3 v3.41.0 h1:QoR1Sn3YWlmA1T4vLaKZfawdVtSiGx8H+cEojbC7v1Q= +modernc.org/ccgo/v3 v3.16.14 h1:af6KNtFgsVmnDYrWk3PQCS9XT6BXe7o3ZFJKkIKvXNQ= +modernc.org/libc v1.24.1 h1:uvJSeCKL/AgzBo2yYIPPTy82v21KgGnizcGYfBHaNuM= +modernc.org/mathutil v1.6.0 h1:fRe9+AmYlaej+64JsEEhoWuAYBkOtQiMEU7n/XgfYi4= +modernc.org/memory v1.6.0 h1:i6mzavxrE9a30whzMfwf7XWVODx2r5OYXvU46cirX7o= +modernc.org/opt v0.1.3 h1:3XOZf2yznlhC+ibLltsDGzABUGVx8J6pnFMS3E4dcq4= +modernc.org/sqlite v1.25.0 h1:AFweiwPNd/b3BoKnBOfFm+Y260guGMF+0UFk0savqeA= +modernc.org/strutil v1.1.3 h1:fNMm+oJklMGYfU9Ylcywl0CO5O6nTfaowNsh2wpPjzY= +modernc.org/token v1.1.0 h1:Xl7Ap9dKaEs5kLoOQeQmPWevfnk/DM5qcLcYlA8ys6Y= nhooyr.io/websocket v1.8.6 h1:s+C3xAMLwGmlI31Nyn/eAehUlZPwfYZu2JXM621Q5/k= pgregory.net/rapid v0.5.5 h1:jkgx1TjbQPD/feRoK+S/mXw9e1uj6WilpHrXJowi6oA= pgregory.net/rapid v0.5.5/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= diff --git a/core/store/migrate/migrate.go b/core/store/migrate/migrate.go index e94cfbf8fba..97714b68bef 100644 --- a/core/store/migrate/migrate.go +++ b/core/store/migrate/migrate.go @@ -19,7 +19,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/store/migrate/migrations" // Invoke init() functions within migrations pkg. ) -//go:embed migrations/*.sql +//go:embed migrations/*.sql migrations/*.go var embedMigrations embed.FS const MIGRATIONS_DIR string = "migrations" diff --git a/core/store/migrate/migrations/0036_external_job_id.go b/core/store/migrate/migrations/0036_external_job_id.go index 47c0fa51b49..82f26206d88 100644 --- a/core/store/migrate/migrations/0036_external_job_id.go +++ b/core/store/migrate/migrations/0036_external_job_id.go @@ -1,6 +1,7 @@ package migrations import ( + "context" "database/sql" "fmt" @@ -10,7 +11,7 @@ import ( ) func init() { - goose.AddMigration(Up36, Down36) + goose.AddMigrationContext(Up36, Down36) } const ( @@ -35,9 +36,9 @@ const ( ) // nolint -func Up36(tx *sql.Tx) error { +func Up36(ctx context.Context, tx *sql.Tx) error { // Add the external ID column and remove type specific ones. - if _, err := tx.Exec(up36_1); err != nil { + if _, err := tx.ExecContext(ctx, up36_1); err != nil { return err } @@ -45,7 +46,7 @@ func Up36(tx *sql.Tx) error { // We do this to avoid using the uuid postgres extension. var jobIDs []int32 txx := sqlx.NewTx(tx, "postgres") - if err := txx.Select(&jobIDs, "SELECT id FROM jobs"); err != nil { + if err := txx.SelectContext(ctx, &jobIDs, "SELECT id FROM jobs"); err != nil { return err } if len(jobIDs) != 0 { @@ -58,22 +59,22 @@ func Up36(tx *sql.Tx) error { } } stmt += ` AS vals(external_job_id, id) WHERE vals.id = j.id` - if _, err := tx.Exec(stmt); err != nil { + if _, err := tx.ExecContext(ctx, stmt); err != nil { return err } } // Add constraints on the external_job_id. - if _, err := tx.Exec(up36_2); err != nil { + if _, err := tx.ExecContext(ctx, up36_2); err != nil { return err } return nil } // nolint -func Down36(tx *sql.Tx) error { - if _, err := tx.Exec(down36); err != nil { +func Down36(ctx context.Context, tx *sql.Tx) error { + if _, err := tx.ExecContext(ctx, down36); err != nil { return err } return nil diff --git a/core/store/migrate/migrations/0054_remove_legacy_pipeline.go b/core/store/migrate/migrations/0054_remove_legacy_pipeline.go index 3db2f19c6c6..924d32308b8 100644 --- a/core/store/migrate/migrations/0054_remove_legacy_pipeline.go +++ b/core/store/migrate/migrations/0054_remove_legacy_pipeline.go @@ -1,6 +1,7 @@ package migrations import ( + "context" "database/sql" "github.com/pkg/errors" @@ -28,26 +29,26 @@ ALTER TABLE job_spec_errors_v2 RENAME TO job_spec_errors; ` func init() { - goose.AddMigration(Up54, Down54) + goose.AddMigrationContext(Up54, Down54) } // nolint -func Up54(tx *sql.Tx) error { +func Up54(ctx context.Context, tx *sql.Tx) error { if err := CheckNoLegacyJobs(tx); err != nil { return err } - if _, err := tx.Exec(up54); err != nil { + if _, err := tx.ExecContext(ctx, up54); err != nil { return err } return nil } // nolint -func Down54(tx *sql.Tx) error { +func Down54(ctx context.Context, tx *sql.Tx) error { return errors.New("irreversible migration") } -// CheckNoLegacyJobs ensures that there are are no legacy job specs +// CheckNoLegacyJobs ensures that there are no legacy job specs func CheckNoLegacyJobs(tx *sql.Tx) error { var count int if err := tx.QueryRow(`SELECT COUNT(*) FROM job_specs WHERE deleted_at IS NULL`).Scan(&count); err != nil { diff --git a/core/store/migrate/migrations/0056_multichain.go b/core/store/migrate/migrations/0056_multichain.go index 419dacc9f52..128e7be5407 100644 --- a/core/store/migrate/migrations/0056_multichain.go +++ b/core/store/migrate/migrations/0056_multichain.go @@ -1,6 +1,7 @@ package migrations import ( + "context" "database/sql" "fmt" "log" @@ -12,7 +13,7 @@ import ( ) func init() { - goose.AddMigration(Up56, Down56) + goose.AddMigrationContext(Up56, Down56) } const up56 = ` @@ -48,8 +49,8 @@ DROP TABLE evm_chains; ` // nolint -func Up56(tx *sql.Tx) error { - if _, err := tx.Exec(up56); err != nil { +func Up56(ctx context.Context, tx *sql.Tx) error { + if _, err := tx.ExecContext(ctx, up56); err != nil { return err } evmDisabled := os.Getenv("EVM_ENABLED") == "false" @@ -67,7 +68,7 @@ func Up56(tx *sql.Tx) error { if !ok { panic(fmt.Sprintf("ETH_CHAIN_ID was invalid, expected a number, got: %s", chainIDStr)) } - _, err := tx.Exec("INSERT INTO evm_chains (id, created_at, updated_at) VALUES ($1, NOW(), NOW());", chainID.String()) + _, err := tx.ExecContext(ctx, "INSERT INTO evm_chains (id, created_at, updated_at) VALUES ($1, NOW(), NOW());", chainID.String()) return err } } @@ -75,8 +76,8 @@ func Up56(tx *sql.Tx) error { } // nolint -func Down56(tx *sql.Tx) error { - _, err := tx.Exec(down56) +func Down56(ctx context.Context, tx *sql.Tx) error { + _, err := tx.ExecContext(ctx, down56) if err != nil { return err } diff --git a/go.mod b/go.mod index e94d2bff56e..ca94d21b1f8 100644 --- a/go.mod +++ b/go.mod @@ -53,7 +53,7 @@ require ( github.com/pelletier/go-toml v1.9.5 github.com/pelletier/go-toml/v2 v2.0.9 github.com/pkg/errors v0.9.1 - github.com/pressly/goose/v3 v3.5.3 + github.com/pressly/goose/v3 v3.15.0 github.com/prometheus/client_golang v1.16.0 github.com/prometheus/client_model v0.4.0 github.com/prometheus/common v0.44.0 @@ -114,12 +114,10 @@ require ( filippo.io/edwards25519 v1.0.0 // indirect github.com/99designs/go-keychain v0.0.0-20191008050251-8e49817e8af4 // indirect github.com/99designs/keyring v1.2.1 // indirect - github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 // indirect github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d // indirect github.com/CosmWasm/wasmvm v1.2.4 // indirect github.com/DataDog/zstd v1.5.2 // indirect github.com/Masterminds/goutils v1.1.1 // indirect - github.com/Microsoft/go-winio v0.6.1 // indirect github.com/VictoriaMetrics/fastcache v1.10.0 // indirect github.com/andres-erbsen/clock v0.0.0-20160526145045-9e14626cd129 // indirect github.com/armon/go-metrics v0.4.1 // indirect @@ -216,7 +214,7 @@ require ( github.com/huandu/skiplist v1.2.0 // indirect github.com/huandu/xstrings v1.4.0 // indirect github.com/huin/goupnp v1.0.3 // indirect - github.com/imdario/mergo v0.3.15 // indirect + github.com/imdario/mergo v0.3.16 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/ipfs/go-cid v0.0.7 // indirect github.com/ipfs/go-datastore v0.4.5 // indirect @@ -235,7 +233,7 @@ require ( github.com/jmhodges/levigo v1.0.0 // indirect github.com/jmoiron/sqlx v1.3.5 // indirect github.com/json-iterator/go v1.1.12 // indirect - github.com/klauspost/compress v1.16.3 // indirect + github.com/klauspost/compress v1.16.7 // indirect github.com/klauspost/cpuid/v2 v2.2.4 // indirect github.com/koron/go-ssdp v0.0.2 // indirect github.com/kr/pretty v0.3.1 // indirect @@ -305,8 +303,6 @@ require ( github.com/mwitkow/grpc-proxy v0.0.0-20230212185441-f345521cb9c9 // indirect github.com/oklog/run v1.1.0 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect - github.com/opencontainers/image-spec v1.1.0-rc3 // indirect - github.com/opencontainers/runc v1.1.7 // indirect github.com/opentracing/opentracing-go v1.2.0 // indirect github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect diff --git a/go.sum b/go.sum index 7b5c074f4ee..a8abfa7a75a 100644 --- a/go.sum +++ b/go.sum @@ -1,4 +1,3 @@ -bazil.org/fuse v0.0.0-20200407214033-5883e5a4b512/go.mod h1:FbcW6z/2VytnFDhZfumh8Ss8zxHE6qpMP5sHTRe0EaM= cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= @@ -71,20 +70,13 @@ github.com/AlekSi/pointer v1.1.0 h1:SSDMPcXD9jSl8FPy9cRzoRaMJtm9g9ggGTxecRUbQoI= github.com/AlekSi/pointer v1.1.0/go.mod h1:y7BvfRI3wXPWKXEBhU71nbnIEEZX0QTSB2Bj48UJIZE= github.com/AndreasBriese/bbloom v0.0.0-20180913140656-343706a395b7/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= -github.com/Azure/azure-sdk-for-go/sdk/azcore v0.19.0/go.mod h1:h6H6c8enJmmocHUbLiiGY6sx7f9i+X3m1CHdd5c6Rdw= -github.com/Azure/azure-sdk-for-go/sdk/azidentity v0.11.0/go.mod h1:HcM1YX14R7CJcghJGOYCgdezslRSVzqwLf/q+4Y2r/0= -github.com/Azure/azure-sdk-for-go/sdk/internal v0.7.0/go.mod h1:yqy467j36fJxcRV2TzfVZ1pCb5vxm4BtZPUdYWe/Xo8= -github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8= -github.com/Azure/go-ansiterm v0.0.0-20210617225240-d185dfc1b5a1/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161 h1:L/gRVlceqvL25UVaW/CKtUDjefjrs0SPonmDGUVOYP0= -github.com/Azure/go-ansiterm v0.0.0-20230124172434-306776ec8161/go.mod h1:xomTg63KZ2rFqZQzSB4Vz2SUXa1BpHTVz9L5PTmPC4E= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d h1:nalkkPQcITbvhmL4+C4cKA87NW0tfm3Kl9VXRoPywFg= github.com/ChainSafe/go-schnorrkel v0.0.0-20200405005733-88cbf1b4c40d/go.mod h1:URdX5+vg25ts3aCh8H5IFZybJYKWhJHYMTnf+ULtoC4= -github.com/ClickHouse/clickhouse-go v1.5.4/go.mod h1:EaI/sW7Azgz9UATzd5ZdZHRUhHgv5+JMS9NSr2smCJI= github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/CosmWasm/wasmd v0.40.1 h1:LxbO78t/6S8TkeQlUrJ0m5O87HtAwLx4RGHq3rdrOEU= @@ -108,11 +100,8 @@ github.com/Masterminds/semver/v3 v3.2.1 h1:RN9w6+7QoMeJVGyfmbcgs28Br8cvmnucEXnY0 github.com/Masterminds/semver/v3 v3.2.1/go.mod h1:qvl/7zhW3nngYb5+80sSMF+FG2BjYrf8m9wsX0PNOMQ= github.com/Masterminds/sprig/v3 v3.2.3 h1:eL2fZNezLomi0uOLqjQoN6BfsDD+fyLtgbJMAj9n6YA= github.com/Masterminds/sprig/v3 v3.2.3/go.mod h1:rXcFaZ2zZbLRJv/xSysmlgIM1u11eBaRMhvYXJNkGuM= -github.com/Microsoft/go-winio v0.5.1/go.mod h1:JPGBdM1cNvN/6ISo+n8V5iA4v8pBzdOpzfwIujj1a84= github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= -github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5 h1:TngWCqHvy9oXAN6lEVMRuU21PR1EtLVZJmdB18Gu3Rw= -github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8D7ML55dXQrVaamCz2vxCfdQBasLZfHKk= github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OneOfOne/xxhash v1.2.5 h1:zl/OfRA6nftbBK9qTohYBJ5xvw6C/oNKizR7cZGl3cI= github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= @@ -158,8 +147,6 @@ github.com/bgentry/go-netrc v0.0.0-20140422174119-9fd32a8b3d3d h1:xDfNPAt8lFiC1U github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816 h1:41iFGWnSlI2gVpmOtVTJZNodLdLQLn/KsJqFvXwnd/s= github.com/bgentry/speakeasy v0.1.1-0.20220910012023-760eaf8b6816/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= -github.com/bits-and-blooms/bitset v1.2.0/go.mod h1:gIdJ4wp64HaoK2YrL1Q5/N7Y16edYb8uY+O0FJTyyDA= -github.com/bkaradzic/go-lz4 v1.0.0/go.mod h1:0YdlkowM3VswSROI7qDxhRvJ3sLhlFrRRwjwegp5jy4= github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= github.com/blendle/zapdriver v1.3.1 h1:C3dydBOWYRiOk+B8X9IVZ5IOe+7cl+tGOexN4QqHfpE= github.com/blendle/zapdriver v1.3.1/go.mod h1:mdXfREi6u5MArG4j9fewC+FGnXaBR+T4Ox4J2u4eHCc= @@ -184,7 +171,6 @@ github.com/bytedance/sonic v1.9.1 h1:6iJ6NqdoxCDr6mbY8h18oSO+cShGSMRGCEo7F2h0x8s github.com/bytedance/sonic v1.9.1/go.mod h1:i736AoUSYt75HyZLoJW9ERYxcy6eaN6h4BZXU064P/U= github.com/cenkalti/backoff v2.2.1+incompatible h1:tNowT99t7UNflLxfYYSlKYsBpXdEet03Pg2g16Swow4= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= -github.com/cenkalti/backoff/v4 v4.1.2/go.mod h1:scbssz8iZGpm3xbr14ovlUdkxfGXNInqkPWOWmG2CLw= github.com/cenkalti/backoff/v4 v4.2.1 h1:y4OZtCnogmCPw98Zjyt5a6+QwPLGkiQsYW5oUqylYbM= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/cp v1.1.1 h1:nCb6ZLdB7NRaqsm91JtQTAme2SKJzXVsdPIPkyJr1MU= @@ -194,7 +180,6 @@ github.com/cespare/xxhash/v2 v2.1.1/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XL github.com/cespare/xxhash/v2 v2.1.2/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/checkpoint-restore/go-criu/v5 v5.0.0/go.mod h1:cfwC0EG7HMUenopBsUf9d89JlCLQIfgVcNsNN0t6T2M= github.com/chenzhuoyu/base64x v0.0.0-20211019084208-fb5309c8db06/go.mod h1:DH46F32mSOjUmXrMHnKwZdA8wcEefY7UVqBKYGjpdQY= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311 h1:qSGYFH7+jGhDF8vLC+iwCD4WpbV1EBDSzWkJODFLams= github.com/chenzhuoyu/base64x v0.0.0-20221115062448-fe3a3abad311/go.mod h1:b583jCggY9gE99b6G5LEC39OIiVsWj+R97kbl5odCEk= @@ -202,11 +187,9 @@ github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWR github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= github.com/chzyer/readline v1.5.1 h1:upd/6fQk4src78LMRzh5vItIt361/o4uq553V8B5sGI= github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= -github.com/cilium/ebpf v0.6.2/go.mod h1:4tRaxcgiL706VnOzHOdBlY8IEAIdxINsQBcU4xJJXRs= github.com/circonus-labs/circonus-gometrics v2.3.1+incompatible/go.mod h1:nmEj6Dob7S7YxXgwXpfOuvO54S+tGdZdw9fuRZt25Ag= github.com/circonus-labs/circonusllhist v0.1.3/go.mod h1:kMXHVDlOchFAehlya5ePtbp5jckzBHf4XRpQvBOLI+I= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= -github.com/cloudflare/golz4 v0.0.0-20150217214814-ef862a3cdc58/go.mod h1:EOBUe0h4xcZ5GoxqC5SDxFQ8gwyZPKQoEzownBlhI80= github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= @@ -234,10 +217,7 @@ github.com/cometbft/cometbft-db v0.7.0 h1:uBjbrBx4QzU0zOEnU8KxoDl18dMNgDh+zZRUE0 github.com/cometbft/cometbft-db v0.7.0/go.mod h1:yiKJIm2WKrt6x8Cyxtq9YTEcIMPcEe4XPxhgX59Fzf0= github.com/confio/ics23/go v0.9.0 h1:cWs+wdbS2KRPZezoaaj+qBleXgUk5WOQFMP3CQFGTr4= github.com/confio/ics23/go v0.9.0/go.mod h1:4LPZ2NYqnYIVRklaozjNR1FScgDJ2s5Xrp+e/mYVRak= -github.com/containerd/console v1.0.2/go.mod h1:ytZPjGgY2oeTkAONYafi2kSj0aYggsf8acV1PGKCbzQ= -github.com/containerd/continuity v0.0.0-20190827140505-75bee3e2ccb6/go.mod h1:GL3xCUCBDV3CZiTSEKksMWbLE66hEyuu9qyDOOqM47Y= -github.com/containerd/continuity v0.2.2/go.mod h1:pWygW9u7LtS1o4N/Tn0FoCFDIXZ7rxcMX7HX1Dmibvk= -github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvAXZJ/eg= +github.com/containerd/continuity v0.4.1 h1:wQnVrjIyQ8vhU2sgOiL5T07jo+ouqc2bnKsv5/EqGhU= github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= @@ -247,7 +227,6 @@ github.com/coreos/go-semver v0.3.0 h1:wkHLiw0WNATZnSG7epLsujiMCgPAc9xhjJ4tgnAxmf github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= -github.com/coreos/go-systemd/v22 v22.3.2/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk= github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis= @@ -271,17 +250,14 @@ github.com/cosmos/ledger-cosmos-go v0.12.1 h1:sMBxza5p/rNK/06nBSNmsI/WDqI0pVJFVN github.com/cosmos/ledger-cosmos-go v0.12.1/go.mod h1:dhO6kj+Y+AHIOgAe4L9HL/6NDdyyth4q238I9yFpD2g= github.com/cosmos/rosetta-sdk-go v0.10.0 h1:E5RhTruuoA7KTIXUcMicL76cffyeoyvNybzUGSKFTcM= github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= -github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creachadair/taskgroup v0.4.2 h1:jsBLdAJE42asreGss2xZGZ8fJra7WtwnHWeJFxv2Li8= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creack/pty v1.1.11/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= github.com/cucumber/common/gherkin/go/v22 v22.0.0 h1:4K8NqptbvdOrjL9DEea6HFjSpbdT9+Q5kgLpmmsHYl0= github.com/cucumber/common/messages/go/v17 v17.1.1 h1:RNqopvIFyLWnKv0LfATh34SWBhXeoFTJnSrgm9cT/Ts= -github.com/cyphar/filepath-securejoin v0.2.2/go.mod h1:FpkQEhXnPnOthhzymB7CGsFk2G9VLXONKD9G7QGMM+4= github.com/daaku/go.zipexe v1.0.0/go.mod h1:z8IiR6TsVLEYKwXAoE/I+8ys/sDkgTzSL0CLnGVd57E= github.com/danieljoos/wincred v1.1.2 h1:QLdCxFs1/Yl4zduvBdcHB8goaYk9RARS2SgLLRuAyr0= github.com/danieljoos/wincred v1.1.2/go.mod h1:GijpziifJoIBfYh+S7BbkdUTU4LfM+QnGqR5Vl2tAx0= @@ -299,7 +275,6 @@ github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5il github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= -github.com/denisenkom/go-mssqldb v0.12.0/go.mod h1:iiK0YP1ZeepvmBQk/QpLEhhTNJgfzrpArPY/aFvc9yU= github.com/desertbit/timer v0.0.0-20180107155436-c41aec40b27f h1:U5y3Y5UE0w7amNe7Z5G/twsBW0KEalRQXZzf8ufSh9I= github.com/dfuse-io/logging v0.0.0-20201110202154-26697de88c79/go.mod h1:V+ED4kT/t/lKtH99JQmKIb0v9WL3VaYkJ36CfHlVECI= github.com/dfuse-io/logging v0.0.0-20210109005628-b97a57253f70 h1:CuJS05R9jmNlUK8GOxrEELPbfXm0EuGh/30LjkjN5vo= @@ -320,14 +295,9 @@ github.com/dgryski/go-farm v0.0.0-20190423205320-6a90982ecee2/go.mod h1:SqUrOPUn github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13 h1:fAjc9m62+UWV/WAFKLNi6ZS0675eEUC9y3AlwSbQu1Y= github.com/dgryski/go-farm v0.0.0-20200201041132-a6ae2369ad13/go.mod h1:SqUrOPUnsFjfmXRMNPybcSiG0BgUW2AuFH8PAnS2iTw= github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= -github.com/dnaeon/go-vcr v1.2.0/go.mod h1:R4UdLID7HZT3taECzJs4YgbbH6PIGXB6W/sc5OLb6RQ= -github.com/docker/cli v20.10.11+incompatible/go.mod h1:JLrzqnKDaYBop7H2jaqPtU4hHvMKP+vjCwu2uszcLI8= github.com/docker/distribution v2.8.2+incompatible h1:T3de5rq0dB1j30rp0sA2rER+m322EBzniBPB6ZIzuh8= github.com/docker/distribution v2.8.2+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= -github.com/docker/docker v20.10.7+incompatible/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= -github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= -github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= github.com/docker/go-units v0.5.0 h1:69rxXcBk27SvSaaxTtLh/8llcHD8vYHT7WSdRZ/jvr4= github.com/dustin/go-humanize v1.0.0/go.mod h1:HtrtbFcZ19U5GC7JDqmcUSB87Iq5E25KnS6fMYU6eOk= github.com/dustin/go-humanize v1.0.1 h1:GzkhY7T5VNhEkwH0PVJgjz+fX1rhBrR7pRT3mDkpeCY= @@ -361,7 +331,6 @@ github.com/fjl/memsize v0.0.0-20190710130421-bcb5799ab5e5 h1:FtmdgXiUlNeRsoNMFlK github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6 h1:u/UEqS66A5ckRmS4yNpjmVH56sVtS/RfclBAYocb4as= github.com/flynn/noise v0.0.0-20180327030543-2492fe189ae6/go.mod h1:1i71OnUq3iUe1ma7Lr6yG6/rjvM3emb6yoL7xLFzcVQ= github.com/fortytw2/leaktest v1.3.0 h1:u8491cBMTQ8ft8aeV+adlcytMZylmA5nnwwkRZjI8vw= -github.com/frankban/quicktest v1.11.3/go.mod h1:wRf/ReqHper53s+kmmSZizM8NamnL3IM0I9ntUbOk+k= github.com/frankban/quicktest v1.14.4 h1:g2rn0vABPOOXmZUj+vbmUp0lPoXEMuhTpIluN0XL9UY= github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= @@ -442,9 +411,8 @@ github.com/go-playground/universal-translator v0.18.1/go.mod h1:xekY+UJKNuX9WP91 github.com/go-playground/validator/v10 v10.10.0/go.mod h1:74x4gJWsvQexRdW8Pn3dXSGrTK4nAUsbPlLADvpJkos= github.com/go-playground/validator/v10 v10.14.0 h1:vgvQWe3XCz3gIeFDm/HnTIbj6UGmg/+t63MyGU2n5js= github.com/go-playground/validator/v10 v10.14.0/go.mod h1:9iXMNT7sEkjXb0I+enO7QXmzG6QCsPWY4zveKFVRSyU= -github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= -github.com/go-sql-driver/mysql v1.6.0 h1:BCTh4TKNUYmOmMUcQ3IipzF5prigylS7XXjEkfCHuOE= github.com/go-sql-driver/mysql v1.6.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= +github.com/go-sql-driver/mysql v1.7.1 h1:lUIinVbN1DY0xBg0eMOzmmtGoHwWBbvnWubQUrtU8EI= github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/go-stack/stack v1.8.1 h1:ntEHSVwIt7PNXNpgPmVfMrNhLtgjlmnZha2kOpuRiDw= github.com/go-stack/stack v1.8.1/go.mod h1:dcoOX6HbPZSZptuspn9bctJ+N/CnF5gGygcUP3XYfe4= @@ -462,7 +430,6 @@ github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU= github.com/goccy/go-json v0.10.2/go.mod h1:6MelG93GURQebXPDq3khkgXZkazVtN9CRI+MGFi0w8I= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2 h1:ZpnhV/YsD2/4cESfV5+Hoeu/iUR3ruzNvZ+yQfO03a0= github.com/godbus/dbus v0.0.0-20190726142602-4481cbc300e2/go.mod h1:bBOAhwG1umN6/6ZUMtDFBMQR8jRg9O75tm9K00oMsK4= -github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= github.com/gofrs/uuid v4.0.0+incompatible/go.mod h1:b2aQJv3Z4Fp6yNu3cdSllBxTCLRxnplIgP/c0N/04lM= @@ -475,8 +442,6 @@ github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= -github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= -github.com/golang-sql/sqlexp v0.0.0-20170517235910-f1bb20e5a188/go.mod h1:vXjM/+wXQnTPR4KqTKDgJukSZ6amVRtWMPEjE6sQoK8= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/glog v1.1.0 h1:/d3pCKDPWNnvIWe0vVUpNP32qc8U3PDVxySP/y360qE= github.com/golang/glog v1.1.0/go.mod h1:pfYeQZ3JWZoXTV5sFc986z3HTpwQs9At6P4ImfuP3NQ= @@ -574,7 +539,6 @@ github.com/google/pprof v0.0.0-20230602150820-91b7bce49751 h1:hR7/MlvK23p6+lIw9S github.com/google/pprof v0.0.0-20230602150820-91b7bce49751/go.mod h1:Jh3hGz2jkYak8qXPD19ryItVnUgpgeqzdkY/D0EaeuA= github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.4 h1:1kZ/sQM3srePvKs3tXAvQzo66XfcReoqFpIpIccE7Oc= -github.com/google/shlex v0.0.0-20191202100458-e7afc7fbc510/go.mod h1:pupxD2MaaD3pAXIBCelhxNneeOaAeabZDe5s4K6zSpQ= github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.1.2/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/google/uuid v1.2.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= @@ -691,9 +655,8 @@ github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:q github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.11/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/imdario/mergo v0.3.12/go.mod h1:jmQim1M+e3UYxmgPu/WyfjB3N3VflVyUjjjwH0dnCYA= -github.com/imdario/mergo v0.3.15 h1:M8XP7IuFNsqUx6VPK2P9OSmsYsI/YFaGil0uD21V3dM= -github.com/imdario/mergo v0.3.15/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= +github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= +github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= @@ -816,7 +779,6 @@ github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9YPoQUg= github.com/jmhodges/levigo v1.0.0 h1:q5EC36kV79HWeTBWsod3mG11EgStG3qArTKcvlksN1U= github.com/jmhodges/levigo v1.0.0/go.mod h1:Q6Qx+uH3RAqyK4rFQroq9RL7mdkABMcfhEI+nNuzMJQ= -github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= github.com/jmoiron/sqlx v1.3.5 h1:vFFPA71p1o5gAeqtEAwLU4dnX2napprKtHr7PYIcN3g= github.com/jmoiron/sqlx v1.3.5/go.mod h1:nRVWtLre0KfCLJvgxzCsLVMogSvQ1zNJtpYr2Ccp0mQ= github.com/joho/godotenv v1.4.0 h1:3l4+N6zfMWnkbPEXKng2o2/MR5mSwTrBih4ZEkkz1lg= @@ -840,7 +802,6 @@ github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2 github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51 h1:Z9n2FFNUXsshfwJMBgNA0RU6/i7WVaAegv3PtuIHPMs= -github.com/kballard/go-shellquote v0.0.0-20180428030007-95032a82bc51/go.mod h1:CzGEWj7cYgsdH8dAjBGEr58BoE7ScuLd+fwFZ44+/x8= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= @@ -849,8 +810,8 @@ github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0 github.com/klauspost/compress v1.11.4/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= -github.com/klauspost/compress v1.16.3 h1:XuJt9zzcnaz6a16/OU53ZjWp/v7/42WcR5t2a0PcNQY= -github.com/klauspost/compress v1.16.3/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/klauspost/compress v1.16.7 h1:2mk3MPGNzKyxErAw8YaohYh69+pa4sIQSC0fPGCFR9I= +github.com/klauspost/compress v1.16.7/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.2.4 h1:acbojRNwl3o09bUq+yDCtZFc1aiwaAAxtcn8YkZXnvk= @@ -882,12 +843,10 @@ github.com/leanovate/gopter v0.2.10-0.20210127095200-9abe2343507a/go.mod h1:U2L/ github.com/leodido/go-urn v1.2.1/go.mod h1:zt4jvISO2HfUBqxjfIshjdMTYS56ZS/qv49ictyFfxY= github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q= github.com/leodido/go-urn v1.2.4/go.mod h1:7ZrI8mTSeBSHl/UaRyKQW1qZeMgak41ANeCNaVckg+4= -github.com/lib/pq v0.0.0-20180327071824-d34b9ff171c2/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= github.com/lib/pq v1.10.2/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= -github.com/lib/pq v1.10.4/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/lib/pq v1.10.9 h1:YXG7RB+JIjhP29X+OtkiDnYaXQwpS4JEWq7dtCCRUEw= github.com/lib/pq v1.10.9/go.mod h1:AlVN5x4E4T544tWzH6hKfbfQvm3HdbOxrmggDNAPY9o= github.com/libp2p/go-addr-util v0.0.1/go.mod h1:4ac6O7n9rIAKB1dnd+s8IbbMXkt+oBpzX4/+RACcnlQ= @@ -1106,8 +1065,6 @@ github.com/mailru/easyjson v0.0.0-20180823135443-60711f1a8329/go.mod h1:C1wdFJiN github.com/manifoldco/promptui v0.9.0 h1:3V4HzJk1TtXW1MTZMP7mdlwbBpIinw3HztaIlYthEiA= github.com/manyminds/api2go v0.0.0-20171030193247-e7b693844a6f h1:tVvGiZQFjOXP+9YyGqSA6jE55x1XVxmoPYudncxrZ8U= github.com/manyminds/api2go v0.0.0-20171030193247-e7b693844a6f/go.mod h1:Z60vy0EZVSu0bOugCHdcN5ZxFMKSpjRgsnh0XKPFqqk= -github.com/matryer/is v1.4.0 h1:sosSmIWwkYITGrxZ25ULNDeKiMNzFSr4V/eqBQP0PeE= -github.com/matryer/is v1.4.0/go.mod h1:8I/i5uYgLzgsgEloJE1U6xx5HkBQpAZvepWuujKwMRU= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= @@ -1134,9 +1091,7 @@ github.com/mattn/go-isatty v0.0.19/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= github.com/mattn/go-sqlite3 v1.14.6/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= -github.com/mattn/go-sqlite3 v1.14.10/go.mod h1:NyWgC/yNuGj7Q9rpYnZvas74GogHl5/Z4A/KQRfk6bU= github.com/mattn/go-sqlite3 v2.0.3+incompatible h1:gXHsfypPkaMZrKbD5209QV9jbUTJKjyR5WD3HYQSd+U= github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= @@ -1175,15 +1130,12 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4 github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= github.com/mitchellh/reflectwalk v1.0.0/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= -github.com/moby/sys/mountinfo v0.4.1/go.mod h1:rEr8tzG/lsIZHBtN/JjGG+LMYx9eXgW2JI+6q0qou+A= -github.com/moby/term v0.0.0-20201216013528-df9cb8a40635/go.mod h1:FBS0z0QWA44HXygs7VXDUOGoN/1TV3RuWkLO04am3wc= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -1191,7 +1143,6 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= -github.com/modocache/gover v0.0.0-20171022184752-b58185e213c5/go.mod h1:caMODM3PzxT8aQXRPkAt8xlV/e7d7w8GM5g0fa5F0D8= github.com/mostynb/zstdpool-freelist v0.0.0-20201229113212-927304c0c3b1 h1:mPMvm6X6tf4w8y7j9YIt6V9jfWhL6QlbEc7CCmeQlWk= github.com/mostynb/zstdpool-freelist v0.0.0-20201229113212-927304c0c3b1/go.mod h1:ye2e/VUEtE2BHE+G/QcKkcLQVAEJoYRFj5VUOQatCRE= github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= @@ -1201,7 +1152,6 @@ github.com/mr-tron/base58 v1.1.2/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjW github.com/mr-tron/base58 v1.1.3/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= github.com/mr-tron/base58 v1.2.0 h1:T/HDJBh4ZCPbU39/+c3rRvE0uKBQlU27+QI8LJ4t64o= github.com/mr-tron/base58 v1.2.0/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= -github.com/mrunalp/fileutils v0.5.0/go.mod h1:M1WthSahJixYnrXQl/DFQuteStB1weuxD2QJNHXfbSQ= github.com/mtibben/percent v0.2.1 h1:5gssi8Nqo8QU/r2pynCm+hBQHpkB/uNK7BJCFogWdzs= github.com/mtibben/percent v0.2.1/go.mod h1:KG9uO+SZkUp+VkRHsCdYQV3XSZrrSpR3O9ibNBTZrns= github.com/multiformats/go-base32 v0.0.3 h1:tw5+NhuwaOjJCC5Pp82QuXbrmLzWg7uxlMFp8Nq/kkI= @@ -1293,23 +1243,15 @@ github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAl github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= github.com/onsi/gomega v1.27.8 h1:gegWiwZjBsf2DgiSbf5hpokZ98JVDMcWkUiigk6/KXc= github.com/onsi/gomega v1.27.8/go.mod h1:2J8vzI/s+2shY9XHRApDkdgPo1TKT7P2u6fXeJKFnNQ= -github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s= github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8Oi/yOhh5U= github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= -github.com/opencontainers/image-spec v1.0.2/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= -github.com/opencontainers/image-spec v1.1.0-rc3 h1:fzg1mXZFj8YdPeNkRXMg+zb88BFV0Ys52cJydRwBkb8= -github.com/opencontainers/image-spec v1.1.0-rc3/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= -github.com/opencontainers/runc v1.0.2/go.mod h1:aTaHFFwQXuA71CiyxOdFFIorAoemI04suvGRQFzWTD0= +github.com/opencontainers/image-spec v1.1.0-rc4 h1:oOxKUJWnFC4YGHCCMNql1x4YaDfYBTS5Y4x/Cgeo1E0= github.com/opencontainers/runc v1.1.7 h1:y2EZDS8sNng4Ksf0GUYNhKbTShZJPJg1FiXJNH/uoCk= -github.com/opencontainers/runc v1.1.7/go.mod h1:CbUumNnWCuTGFukNXahoo/RFBZvDAgRh/smNYNOhA50= -github.com/opencontainers/runtime-spec v1.0.3-0.20210326190908-1c3f411f0417/go.mod h1:jwyrGlmzljRJv/Fgzds9SsS/C5hL+LL3ko9hs6T5lQ0= -github.com/opencontainers/selinux v1.8.2/go.mod h1:MUIHuUEvKB1wtJjQdOyYRgOnLD2xAPP8dBsCoU0KuF8= github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.1.0/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= github.com/opentracing/opentracing-go v1.2.0 h1:uEJPy/1a5RIPAJ0Ov+OIO8OxWu77jEv+1B0VhjKrZUs= github.com/opentracing/opentracing-go v1.2.0/go.mod h1:GxEUsuufX4nBwe+T+Wl9TAgYrxe9dPLANfrWvHYVTgc= github.com/ory/dockertest v3.3.5+incompatible h1:iLLK6SQwIhcbrG783Dghaaa3WPzGc+4Emza6EbVUUGA= -github.com/ory/dockertest/v3 v3.8.1/go.mod h1:wSRQ3wmkz+uSARYMk7kVJFDBGm8x5gSxIhI7NDc+BAQ= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/pascaldekloe/goe v0.1.0 h1:cBOtyMzM9HTpWjXfbbunk26uA6nG3a8n06Wieeh0MwY= github.com/pascaldekloe/goe v0.1.0/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= @@ -1324,10 +1266,8 @@ github.com/pelletier/go-toml/v2 v2.0.9/go.mod h1:tJU2Z3ZkXwnxa4DPO899bsyIoywizdU github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 h1:hDSdbBuw3Lefr6R18ax0tZ2BJeNB3NehB3trOwYBsdU= github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08/go.mod h1:pxMtw7cyUw6B2bRH0ZBANSPg+AoSud1I1iyJHI69jH4= -github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= github.com/pingcap/errors v0.11.4 h1:lFuQV/oaUMGcD2tqt+01ROSmJs75VG1ToEOkZIZ4nE4= github.com/pingcap/errors v0.11.4/go.mod h1:Oi8TUi2kEtXXLMJk9l1cGmz20kV3TaQ0usTwv5KuLY8= -github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4/go.mod h1:4OwLy04Bl9Ef3GJJCoec+30X3LQs/0/m4HFRt/2LUSA= github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA= github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= @@ -1340,8 +1280,8 @@ github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= -github.com/pressly/goose/v3 v3.5.3 h1:lIQIIXVbdO2RuQtJBS1e7MZjKEk0demVWt6i0YPiOrg= -github.com/pressly/goose/v3 v3.5.3/go.mod h1:IL4NNMdXx9O6hHpGbNB5l1hkVe/Avoz4gBDE5g7rQNg= +github.com/pressly/goose/v3 v3.15.0 h1:6tY5aDqFknY6VZkorFGgZtWygodZQxfmmEF4rqyJW9k= +github.com/pressly/goose/v3 v3.15.0/go.mod h1:LlIo3zGccjb/YUgG+Svdb9Er14vefRdlDI7URCDrwYo= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= github.com/prometheus/client_golang v1.0.0/go.mod h1:db9x61etRT2tGnBNRi70OPL5FsnadC4Ky3P0J6CfImo= @@ -1379,8 +1319,7 @@ github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475/go.mod h1:bCqn github.com/regen-network/gocuke v0.6.2 h1:pHviZ0kKAq2U2hN2q3smKNxct6hS0mGByFMHGnWA97M= github.com/regen-network/protobuf v1.3.3-alpha.regen.1 h1:OHEc+q5iIAXpqiqFKeLpu5NwTIkVXUs48vFMwzqpqY4= github.com/regen-network/protobuf v1.3.3-alpha.regen.1/go.mod h1:2DjTFR1HhMQhiWC5sZ4OhQ3+NtdbZ6oBDKQwq5Ou+FI= -github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0 h1:OdAsTTz6OkFY5QxjkYwrChwuRruF69c169dPK26NUlk= -github.com/remyoudompheng/bigfft v0.0.0-20200410134404-eec4a21b6bb0/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= +github.com/remyoudompheng/bigfft v0.0.0-20230129092748-24d4a6f8daec h1:W09IVJc94icq4NjY3clb7Lk8O1qJ8BdBEF8z0ibU0rE= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= github.com/rivo/uniseg v0.4.4 h1:8TfxU8dW6PdqD27gjM8MVNuicgxIjxpm4K7x4jp8sis= github.com/rivo/uniseg v0.4.4/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= @@ -1413,7 +1352,6 @@ github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtm github.com/scylladb/go-reflectx v1.0.1 h1:b917wZM7189pZdlND9PbIJ6NQxfDPfBvUaQ7cjj1iZQ= github.com/scylladb/go-reflectx v1.0.1/go.mod h1:rWnOfDIRWBGN0miMLIcoPt/Dhi2doCMZqwMCJ3KupFc= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= -github.com/seccomp/libseccomp-golang v0.9.1/go.mod h1:GbW5+tmTXfcxTToHLXlScSlAvWlF4P2Ca7zGrPiEpWo= github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= @@ -1427,8 +1365,6 @@ github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeV github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= -github.com/sirupsen/logrus v1.7.0/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= -github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ= github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= @@ -1518,7 +1454,6 @@ github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXl github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/subosito/gotenv v1.4.2 h1:X1TuBLAMDFbaTAChgCBLu3DU3UPyELpnF2jjJ2cz/S8= github.com/subosito/gotenv v1.4.2/go.mod h1:ayKnFf/c6rvx/2iiLrJUk1e6plDbT3edrFNGqEflhK0= -github.com/syndtr/gocapability v0.0.0-20200815063812-42c35b437635/go.mod h1:hkRG7XYTFWNJGYcbNJQlaLq0fg1yr4J4t/NcTQtrfww= github.com/syndtr/goleveldb v1.0.0/go.mod h1:ZVVdQEZoIme9iO1Ch2Jdy24qqXrMMOU6lpPAyBWyWuQ= github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d h1:vfofYNRScrDdvS342BElfbETmL1Aiz3i2t0zfRj16Hs= github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d/go.mod h1:RRCYJbIwD5jmqPI9XoAFR0OcDxqUctll6zUj/+B4S48= @@ -1549,7 +1484,6 @@ github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+F github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tv42/httpunix v0.0.0-20150427012821-b75d8614f926/go.mod h1:9ESjWnEqriFuLhtthL60Sar/7RFoluCcXsuvEwTV5KM= -github.com/tv42/httpunix v0.0.0-20191220191345-2ba4b9c3382c/go.mod h1:hzIxponao9Kjc7aWznkXaL4U4TWaDSs8zcsY4Ka08nM= github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS4MhqMhdFk5YI= github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= @@ -1571,7 +1505,6 @@ github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722 h1:10Nbw6cACsnQm7 github.com/umbracle/fastrlp v0.0.0-20220527094140-59d5dd30e722/go.mod h1:c8J0h9aULj2i3umrfyestM6jCq0LK0U6ly6bWy96nd4= github.com/unrolled/secure v1.13.0 h1:sdr3Phw2+f8Px8HE5sd1EHdj1aV3yUwed/uZXChLFsk= github.com/unrolled/secure v1.13.0/go.mod h1:BmF5hyM6tXczk3MpQkFf1hpKSRqCyhqcbiQtiAF7+40= -github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli v1.22.14 h1:ebbhrRiGK2i4naQJr+1Xj92HXZCrK7MsyTS/ob3HnAk= github.com/urfave/cli v1.22.14/go.mod h1:X0eDS6pD6Exaclxm99NJ3FiCDRED7vIHpx2mDOHLvkA= github.com/urfave/cli/v2 v2.17.2-0.20221006022127-8f469abc00aa h1:5SqCsI/2Qya2bCzK15ozrqo2sZxkh0FHynJZOTVoV6Q= @@ -1583,8 +1516,6 @@ github.com/valyala/fastjson v1.4.1/go.mod h1:nV6MsjxL2IMJQUoHDIrjEI7oLyeqK6aBD7E github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= -github.com/vishvananda/netlink v1.1.0/go.mod h1:cTgwzPIzzgDAYoQrMm0EdrjRUBkTqKYppBueQtXaqoE= -github.com/vishvananda/netns v0.0.0-20191106174202-0a2b9b5464df/go.mod h1:JP3t17pCcGlemwknint6hfoeCVQrEMVwxRLRjXpq+BU= github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1 h1:EKhdznlJHPMoKr0XTrX+IlJs1LH3lyx2nfr1dOlZ79k= github.com/whyrusleeping/go-keyspace v0.0.0-20160322163242-5b898ac5add1/go.mod h1:8UvriyWtv5Q5EOgjHaSseUEdkQfvwFv1I/In/O2M9gc= github.com/whyrusleeping/go-logging v0.0.0-20170515211332-0457bb6b88fc/go.mod h1:bopw91TMyo8J3tvftk8xmU2kPmlrt4nScJQZU2hE5EM= @@ -1611,13 +1542,11 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= -github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/yusufpapurcu/wmi v1.2.2/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= github.com/yusufpapurcu/wmi v1.2.3 h1:E1ctvB7uKFMOJw3fdOW32DwGE9I7t++CRUEMKvFoFiw= github.com/yusufpapurcu/wmi v1.2.3/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= -github.com/ziutek/mymysql v1.5.4/go.mod h1:LMSpPZ6DbqWFxNCHW77HeMg9I646SAhApZ/wKdgO/C0= github.com/zondax/hid v0.9.1 h1:gQe66rtmyZ8VeGFcOpbuH3r7erYtNEAezCAYu8LdkJo= github.com/zondax/hid v0.9.1/go.mod h1:l5wttcP0jwtdLjqjMMWFVEE7d1zO0jvSPA9OPZxWpEM= github.com/zondax/ledger-go v0.14.1 h1:Pip65OOl4iJ84WTpA4BKChvOufMhhbxED3BaihoZN4c= @@ -1711,7 +1640,6 @@ golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20200602180216-279210d13fed/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200728195943-123391ffb6de/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20201016220609-9e8e0b390897/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20201203163018-be400aefbc4c/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20201221181555-eec23a3978ad/go.mod h1:jdWPYTVW3xRLrWPugEBEK3UY2ZEsg3UU495nc5E+M+I= golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= @@ -1721,7 +1649,6 @@ golang.org/x/crypto v0.0.0-20210616213533-5ff15b29337e/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20210711020723-a769d52b0f97/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= -golang.org/x/crypto v0.0.0-20220210151621-f4118a5b28e2/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.3.0/go.mod h1:hebNnKkNXi2UzZN1eVRvBB7co0a+JxK6XbPiWVs/3J4= golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58= golang.org/x/crypto v0.11.0 h1:6Ewdq3tDic1mg5xRO4milcWCfMVQhI4NkqWWvqejpuA= @@ -1763,7 +1690,6 @@ golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.12.0 h1:rmsUpXtvNzj340zd98LZ4KntptpfRHwpFOHG188oHXc= golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1820,11 +1746,7 @@ golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96b golang.org/x/net v0.0.0-20210423184538-5f58ad60dda6/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= golang.org/x/net v0.0.0-20210510120150-4163338589ed/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20210610132358-84b48f89b13b/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= golang.org/x/net v0.0.0-20220607020251-c690dde0001d/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= @@ -1879,7 +1801,6 @@ golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190526052359-791d8a0f4d09/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190606203320-7fc4e5ec1444/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1891,10 +1812,8 @@ golang.org/x/sys v0.0.0-20190924154521-2837fb4f24fe/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191005200804-aed5e4c7ecf9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191026070338-33540a1f6037/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191115151921-52ab43148777/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20191210023423-ac6580df4449/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1911,18 +1830,14 @@ golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200831180312-196b9ba8737a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20200909081042-eff7692f9009/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20201126233918-771906719818/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201201145000-ef89a241ccb3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201204225414-ed752295db88/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210104204734-6f8348627aad/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210112080510-489259a85091/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210119212857-b64e53b001e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210124154548-22da62e12c0c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210225134936-a50acf3fe073/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210315160823-c6e025ad8005/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210320140829-1e4c9ba3b0c4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1931,19 +1846,15 @@ golang.org/x/sys v0.0.0-20210331175145-43e1dd70ce54/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210403161142-5e06dd20ab57/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423082822-04245dca01da/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210423185535-09eb48e85fd7/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20210426230700-d19ff857e887/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210514084401-e8d321eab015/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210616094352-59db8d763f22/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210629170331-7dc0b73dc9fb/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210806184541-e5e7981a1069/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210819135213-f52c844e1c1c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20210902050250-f475640dd07b/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220405052023-b1e9470b6e64/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= @@ -2006,7 +1917,6 @@ golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBn golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= -golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20190823170909-c4a336ef6a2f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= @@ -2048,7 +1958,6 @@ golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200904185747-39188db58858/go.mod h1:Cj7w3i3Rnn0Xh82ur9kSqwfTHTeVxaDqrfMjpcNT6bE= golang.org/x/tools v0.0.0-20201110124207-079ba7bd75cd/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.0.0-20201124115921-2c860bdd6e78/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201201161351-ac6f37ff4c2a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201208233053-a543418bbed2/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20201224043029-2b0845dc783e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= @@ -2058,7 +1967,6 @@ golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.11.0 h1:EMCa6U9S2LtZXLAMoWiR/R8dAQFRqbAitmbJ2UKhoi8= golang.org/x/tools v0.11.0/go.mod h1:anzJrxPjNtfgiYQYirP2CPGzGLxrH2u2QBhn6Bf3qY8= @@ -2242,8 +2150,6 @@ gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= -gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= -gotest.tools/v3 v3.0.3/go.mod h1:Z7Lb0S5l+klDB31fvDQX8ss/FlKDxtlFlw3Oa8Ymbl8= gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= @@ -2253,134 +2159,16 @@ honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= honnef.co/go/tools v0.1.3/go.mod h1:NgwopIslSNH47DimFoV78dnkksY2EFtX0ajyb3K/las= -lukechampine.com/uint128 v1.1.1/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= -lukechampine.com/uint128 v1.2.0 h1:mBi/5l91vocEN8otkC5bDLhi2KdCticRiwbdB0O+rjI= -lukechampine.com/uint128 v1.2.0/go.mod h1:c4eWIwlEGaxC/+H1VguhU4PHXNWDCDMUlWdIWl2j1gk= -modernc.org/cc/v3 v3.33.6/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.33.9/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.33.11/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.34.0/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.0/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.4/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.5/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.7/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.8/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.10/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.15/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.16/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.17/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.18/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.20/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/cc/v3 v3.35.22 h1:BzShpwCAP7TWzFppM4k2t03RhXhgYqaibROWkrWq7lE= -modernc.org/cc/v3 v3.35.22/go.mod h1:iPJg1pkwXqAV16SNgFBVYmggfMg6xhs+2oiO0vclK3g= -modernc.org/ccgo/v3 v3.9.5/go.mod h1:umuo2EP2oDSBnD3ckjaVUXMrmeAw8C8OSICVa0iFf60= -modernc.org/ccgo/v3 v3.10.0/go.mod h1:c0yBmkRFi7uW4J7fwx/JiijwOjeAeR2NoSaRVFPmjMw= -modernc.org/ccgo/v3 v3.11.0/go.mod h1:dGNposbDp9TOZ/1KBxghxtUp/bzErD0/0QW4hhSaBMI= -modernc.org/ccgo/v3 v3.11.1/go.mod h1:lWHxfsn13L3f7hgGsGlU28D9eUOf6y3ZYHKoPaKU0ag= -modernc.org/ccgo/v3 v3.11.3/go.mod h1:0oHunRBMBiXOKdaglfMlRPBALQqsfrCKXgw9okQ3GEw= -modernc.org/ccgo/v3 v3.12.4/go.mod h1:Bk+m6m2tsooJchP/Yk5ji56cClmN6R1cqc9o/YtbgBQ= -modernc.org/ccgo/v3 v3.12.6/go.mod h1:0Ji3ruvpFPpz+yu+1m0wk68pdr/LENABhTrDkMDWH6c= -modernc.org/ccgo/v3 v3.12.8/go.mod h1:Hq9keM4ZfjCDuDXxaHptpv9N24JhgBZmUG5q60iLgUo= -modernc.org/ccgo/v3 v3.12.11/go.mod h1:0jVcmyDwDKDGWbcrzQ+xwJjbhZruHtouiBEvDfoIsdg= -modernc.org/ccgo/v3 v3.12.14/go.mod h1:GhTu1k0YCpJSuWwtRAEHAol5W7g1/RRfS4/9hc9vF5I= -modernc.org/ccgo/v3 v3.12.18/go.mod h1:jvg/xVdWWmZACSgOiAhpWpwHWylbJaSzayCqNOJKIhs= -modernc.org/ccgo/v3 v3.12.20/go.mod h1:aKEdssiu7gVgSy/jjMastnv/q6wWGRbszbheXgWRHc8= -modernc.org/ccgo/v3 v3.12.21/go.mod h1:ydgg2tEprnyMn159ZO/N4pLBqpL7NOkJ88GT5zNU2dE= -modernc.org/ccgo/v3 v3.12.22/go.mod h1:nyDVFMmMWhMsgQw+5JH6B6o4MnZ+UQNw1pp52XYFPRk= -modernc.org/ccgo/v3 v3.12.25/go.mod h1:UaLyWI26TwyIT4+ZFNjkyTbsPsY3plAEB6E7L/vZV3w= -modernc.org/ccgo/v3 v3.12.29/go.mod h1:FXVjG7YLf9FetsS2OOYcwNhcdOLGt8S9bQ48+OP75cE= -modernc.org/ccgo/v3 v3.12.36/go.mod h1:uP3/Fiezp/Ga8onfvMLpREq+KUjUmYMxXPO8tETHtA8= -modernc.org/ccgo/v3 v3.12.38/go.mod h1:93O0G7baRST1vNj4wnZ49b1kLxt0xCW5Hsa2qRaZPqc= -modernc.org/ccgo/v3 v3.12.43/go.mod h1:k+DqGXd3o7W+inNujK15S5ZYuPoWYLpF5PYougCmthU= -modernc.org/ccgo/v3 v3.12.46/go.mod h1:UZe6EvMSqOxaJ4sznY7b23/k13R8XNlyWsO5bAmSgOE= -modernc.org/ccgo/v3 v3.12.47/go.mod h1:m8d6p0zNps187fhBwzY/ii6gxfjob1VxWb919Nk1HUk= -modernc.org/ccgo/v3 v3.12.50/go.mod h1:bu9YIwtg+HXQxBhsRDE+cJjQRuINuT9PUK4orOco/JI= -modernc.org/ccgo/v3 v3.12.51/go.mod h1:gaIIlx4YpmGO2bLye04/yeblmvWEmE4BBBls4aJXFiE= -modernc.org/ccgo/v3 v3.12.53/go.mod h1:8xWGGTFkdFEWBEsUmi+DBjwu/WLy3SSOrqEmKUjMeEg= -modernc.org/ccgo/v3 v3.12.54/go.mod h1:yANKFTm9llTFVX1FqNKHE0aMcQb1fuPJx6p8AcUx+74= -modernc.org/ccgo/v3 v3.12.55/go.mod h1:rsXiIyJi9psOwiBkplOaHye5L4MOOaCjHg1Fxkj7IeU= -modernc.org/ccgo/v3 v3.12.56/go.mod h1:ljeFks3faDseCkr60JMpeDb2GSO3TKAmrzm7q9YOcMU= -modernc.org/ccgo/v3 v3.12.57/go.mod h1:hNSF4DNVgBl8wYHpMvPqQWDQx8luqxDnNGCMM4NFNMc= -modernc.org/ccgo/v3 v3.12.60/go.mod h1:k/Nn0zdO1xHVWjPYVshDeWKqbRWIfif5dtsIOCUVMqM= -modernc.org/ccgo/v3 v3.12.66/go.mod h1:jUuxlCFZTUZLMV08s7B1ekHX5+LIAurKTTaugUr/EhQ= -modernc.org/ccgo/v3 v3.12.67/go.mod h1:Bll3KwKvGROizP2Xj17GEGOTrlvB1XcVaBrC90ORO84= -modernc.org/ccgo/v3 v3.12.73/go.mod h1:hngkB+nUUqzOf3iqsM48Gf1FZhY599qzVg1iX+BT3cQ= -modernc.org/ccgo/v3 v3.12.81/go.mod h1:p2A1duHoBBg1mFtYvnhAnQyI6vL0uw5PGYLSIgF6rYY= -modernc.org/ccgo/v3 v3.12.84/go.mod h1:ApbflUfa5BKadjHynCficldU1ghjen84tuM5jRynB7w= -modernc.org/ccgo/v3 v3.12.86/go.mod h1:dN7S26DLTgVSni1PVA3KxxHTcykyDurf3OgUzNqTSrU= -modernc.org/ccgo/v3 v3.12.90/go.mod h1:obhSc3CdivCRpYZmrvO88TXlW0NvoSVvdh/ccRjJYko= -modernc.org/ccgo/v3 v3.12.92/go.mod h1:5yDdN7ti9KWPi5bRVWPl8UNhpEAtCjuEE7ayQnzzqHA= -modernc.org/ccgo/v3 v3.13.1/go.mod h1:aBYVOUfIlcSnrsRVU8VRS35y2DIfpgkmVkYZ0tpIXi4= -modernc.org/ccgo/v3 v3.15.1/go.mod h1:md59wBwDT2LznX/OTCPoVS6KIsdRgY8xqQwBV+hkTH0= -modernc.org/ccgo/v3 v3.15.9/go.mod h1:md59wBwDT2LznX/OTCPoVS6KIsdRgY8xqQwBV+hkTH0= -modernc.org/ccgo/v3 v3.15.10/go.mod h1:wQKxoFn0ynxMuCLfFD09c8XPUCc8obfchoVR9Cn0fI8= -modernc.org/ccgo/v3 v3.15.12/go.mod h1:VFePOWoCd8uDGRJpq/zfJ29D0EVzMSyID8LCMWYbX6I= -modernc.org/ccgo/v3 v3.15.13 h1:hqlCzNJTXLrhS70y1PqWckrF9x1btSQRC7JFuQcBg5c= -modernc.org/ccgo/v3 v3.15.13/go.mod h1:QHtvdpeODlXjdK3tsbpyK+7U9JV4PQsrPGIbtmc0KfY= -modernc.org/ccorpus v1.11.1/go.mod h1:2gEUTrWqdpH2pXsmTM1ZkjeSrUWDpjMu2T6m29L/ErQ= -modernc.org/ccorpus v1.11.4/go.mod h1:2gEUTrWqdpH2pXsmTM1ZkjeSrUWDpjMu2T6m29L/ErQ= -modernc.org/httpfs v1.0.6/go.mod h1:7dosgurJGp0sPaRanU53W4xZYKh14wfzX420oZADeHM= -modernc.org/libc v1.9.8/go.mod h1:U1eq8YWr/Kc1RWCMFUWEdkTg8OTcfLw2kY8EDwl039w= -modernc.org/libc v1.9.11/go.mod h1:NyF3tsA5ArIjJ83XB0JlqhjTabTCHm9aX4XMPHyQn0Q= -modernc.org/libc v1.11.0/go.mod h1:2lOfPmj7cz+g1MrPNmX65QCzVxgNq2C5o0jdLY2gAYg= -modernc.org/libc v1.11.2/go.mod h1:ioIyrl3ETkugDO3SGZ+6EOKvlP3zSOycUETe4XM4n8M= -modernc.org/libc v1.11.5/go.mod h1:k3HDCP95A6U111Q5TmG3nAyUcp3kR5YFZTeDS9v8vSU= -modernc.org/libc v1.11.6/go.mod h1:ddqmzR6p5i4jIGK1d/EiSw97LBcE3dK24QEwCFvgNgE= -modernc.org/libc v1.11.11/go.mod h1:lXEp9QOOk4qAYOtL3BmMve99S5Owz7Qyowzvg6LiZso= -modernc.org/libc v1.11.13/go.mod h1:ZYawJWlXIzXy2Pzghaf7YfM8OKacP3eZQI81PDLFdY8= -modernc.org/libc v1.11.16/go.mod h1:+DJquzYi+DMRUtWI1YNxrlQO6TcA5+dRRiq8HWBWRC8= -modernc.org/libc v1.11.19/go.mod h1:e0dgEame6mkydy19KKaVPBeEnyJB4LGNb0bBH1EtQ3I= -modernc.org/libc v1.11.24/go.mod h1:FOSzE0UwookyT1TtCJrRkvsOrX2k38HoInhw+cSCUGk= -modernc.org/libc v1.11.26/go.mod h1:SFjnYi9OSd2W7f4ct622o/PAYqk7KHv6GS8NZULIjKY= -modernc.org/libc v1.11.27/go.mod h1:zmWm6kcFXt/jpzeCgfvUNswM0qke8qVwxqZrnddlDiE= -modernc.org/libc v1.11.28/go.mod h1:Ii4V0fTFcbq3qrv3CNn+OGHAvzqMBvC7dBNyC4vHZlg= -modernc.org/libc v1.11.31/go.mod h1:FpBncUkEAtopRNJj8aRo29qUiyx5AvAlAxzlx9GNaVM= -modernc.org/libc v1.11.34/go.mod h1:+Tzc4hnb1iaX/SKAutJmfzES6awxfU1BPvrrJO0pYLg= -modernc.org/libc v1.11.37/go.mod h1:dCQebOwoO1046yTrfUE5nX1f3YpGZQKNcITUYWlrAWo= -modernc.org/libc v1.11.39/go.mod h1:mV8lJMo2S5A31uD0k1cMu7vrJbSA3J3waQJxpV4iqx8= -modernc.org/libc v1.11.42/go.mod h1:yzrLDU+sSjLE+D4bIhS7q1L5UwXDOw99PLSX0BlZvSQ= -modernc.org/libc v1.11.44/go.mod h1:KFq33jsma7F5WXiYelU8quMJasCCTnHK0mkri4yPHgA= -modernc.org/libc v1.11.45/go.mod h1:Y192orvfVQQYFzCNsn+Xt0Hxt4DiO4USpLNXBlXg/tM= -modernc.org/libc v1.11.47/go.mod h1:tPkE4PzCTW27E6AIKIR5IwHAQKCAtudEIeAV1/SiyBg= -modernc.org/libc v1.11.49/go.mod h1:9JrJuK5WTtoTWIFQ7QjX2Mb/bagYdZdscI3xrvHbXjE= -modernc.org/libc v1.11.51/go.mod h1:R9I8u9TS+meaWLdbfQhq2kFknTW0O3aw3kEMqDDxMaM= -modernc.org/libc v1.11.53/go.mod h1:5ip5vWYPAoMulkQ5XlSJTy12Sz5U6blOQiYasilVPsU= -modernc.org/libc v1.11.54/go.mod h1:S/FVnskbzVUrjfBqlGFIPA5m7UwB3n9fojHhCNfSsnw= -modernc.org/libc v1.11.55/go.mod h1:j2A5YBRm6HjNkoSs/fzZrSxCuwWqcMYTDPLNx0URn3M= -modernc.org/libc v1.11.56/go.mod h1:pakHkg5JdMLt2OgRadpPOTnyRXm/uzu+Yyg/LSLdi18= -modernc.org/libc v1.11.58/go.mod h1:ns94Rxv0OWyoQrDqMFfWwka2BcaF6/61CqJRK9LP7S8= -modernc.org/libc v1.11.71/go.mod h1:DUOmMYe+IvKi9n6Mycyx3DbjfzSKrdr/0Vgt3j7P5gw= -modernc.org/libc v1.11.75/go.mod h1:dGRVugT6edz361wmD9gk6ax1AbDSe0x5vji0dGJiPT0= -modernc.org/libc v1.11.82/go.mod h1:NF+Ek1BOl2jeC7lw3a7Jj5PWyHPwWD4aq3wVKxqV1fI= -modernc.org/libc v1.11.86/go.mod h1:ePuYgoQLmvxdNT06RpGnaDKJmDNEkV7ZPKI2jnsvZoE= -modernc.org/libc v1.11.87/go.mod h1:Qvd5iXTeLhI5PS0XSyqMY99282y+3euapQFxM7jYnpY= -modernc.org/libc v1.11.88/go.mod h1:h3oIVe8dxmTcchcFuCcJ4nAWaoiwzKCdv82MM0oiIdQ= -modernc.org/libc v1.11.98/go.mod h1:ynK5sbjsU77AP+nn61+k+wxUGRx9rOFcIqWYYMaDZ4c= -modernc.org/libc v1.11.101/go.mod h1:wLLYgEiY2D17NbBOEp+mIJJJBGSiy7fLL4ZrGGZ+8jI= -modernc.org/libc v1.12.0/go.mod h1:2MH3DaF/gCU8i/UBiVE1VFRos4o523M7zipmwH8SIgQ= -modernc.org/libc v1.14.1/go.mod h1:npFeGWjmZTjFeWALQLrvklVmAxv4m80jnG3+xI8FdJk= -modernc.org/libc v1.14.2/go.mod h1:MX1GBLnRLNdvmK9azU9LCxZ5lMyhrbEMK8rG3X/Fe34= -modernc.org/libc v1.14.3/go.mod h1:GPIvQVOVPizzlqyRX3l756/3ppsAgg1QgPxjr5Q4agQ= -modernc.org/libc v1.14.5 h1:DAHvwGoVRDZs5iJXnX9RJrgXSsorupCWmJ2ac964Owk= -modernc.org/libc v1.14.5/go.mod h1:2PJHINagVxO4QW/5OQdRrvMYo+bm5ClpUFfyXCYl9ak= -modernc.org/mathutil v1.1.1/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/mathutil v1.2.2/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/mathutil v1.4.0/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/mathutil v1.4.1 h1:ij3fYGe8zBF4Vu+g0oT7mB06r8sqGWKuJu1yXeR4by8= -modernc.org/mathutil v1.4.1/go.mod h1:mZW8CKdRPY1v87qxC/wUdX5O1qDzXMP5TH3wjfpga6E= -modernc.org/memory v1.0.4/go.mod h1:nV2OApxradM3/OVbs2/0OsP6nPfakXpi50C7dcoHXlc= -modernc.org/memory v1.0.5 h1:XRch8trV7GgvTec2i7jc33YlUI0RKVDBvZ5eZ5m8y14= -modernc.org/memory v1.0.5/go.mod h1:B7OYswTRnfGg+4tDH1t1OeUNnsy2viGTdME4tzd+IjM= -modernc.org/opt v0.1.1 h1:/0RX92k9vwVeDXj+Xn23DKp2VJubL7k8qNffND6qn3A= -modernc.org/opt v0.1.1/go.mod h1:WdSiB5evDcignE70guQKxYUl14mgWtbClRi5wmkkTX0= -modernc.org/sqlite v1.14.6 h1:Jt5P3k80EtDBWaq1beAxnWW+5MdHXbZITujnRS7+zWg= -modernc.org/sqlite v1.14.6/go.mod h1:yiCvMv3HblGmzENNIaNtFhfaNIwcla4u2JQEwJPzfEc= -modernc.org/strutil v1.1.1 h1:xv+J1BXY3Opl2ALrBwyfEikFAj8pmqcpnfmuwUwcozs= -modernc.org/strutil v1.1.1/go.mod h1:DE+MQQ/hjKBZS2zNInV5hhcipt5rLPWkmpbGeW5mmdw= -modernc.org/tcl v1.11.0/go.mod h1:zsTUpbQ+NxQEjOjCUlImDLPv1sG8Ww0qp66ZvyOxCgw= -modernc.org/token v1.0.0 h1:a0jaWiNMDhDUtqOj09wvjWWAqd3q7WpBulmL9H2egsk= -modernc.org/token v1.0.0/go.mod h1:UGzOrNV1mAFSEB63lOFHIpNRUVMvYTc6yu1SMY/XTDM= -modernc.org/z v1.3.0/go.mod h1:+mvgLH814oDjtATDdT3rs84JnUIpkvAF5B8AVkNlE2g= +lukechampine.com/uint128 v1.3.0 h1:cDdUVfRwDUDovz610ABgFD17nXD4/uDgVHl2sC3+sbo= +modernc.org/cc/v3 v3.41.0 h1:QoR1Sn3YWlmA1T4vLaKZfawdVtSiGx8H+cEojbC7v1Q= +modernc.org/ccgo/v3 v3.16.14 h1:af6KNtFgsVmnDYrWk3PQCS9XT6BXe7o3ZFJKkIKvXNQ= +modernc.org/libc v1.24.1 h1:uvJSeCKL/AgzBo2yYIPPTy82v21KgGnizcGYfBHaNuM= +modernc.org/mathutil v1.6.0 h1:fRe9+AmYlaej+64JsEEhoWuAYBkOtQiMEU7n/XgfYi4= +modernc.org/memory v1.6.0 h1:i6mzavxrE9a30whzMfwf7XWVODx2r5OYXvU46cirX7o= +modernc.org/opt v0.1.3 h1:3XOZf2yznlhC+ibLltsDGzABUGVx8J6pnFMS3E4dcq4= +modernc.org/sqlite v1.25.0 h1:AFweiwPNd/b3BoKnBOfFm+Y260guGMF+0UFk0savqeA= +modernc.org/strutil v1.1.3 h1:fNMm+oJklMGYfU9Ylcywl0CO5O6nTfaowNsh2wpPjzY= +modernc.org/token v1.1.0 h1:Xl7Ap9dKaEs5kLoOQeQmPWevfnk/DM5qcLcYlA8ys6Y= nhooyr.io/websocket v1.8.6 h1:s+C3xAMLwGmlI31Nyn/eAehUlZPwfYZu2JXM621Q5/k= pgregory.net/rapid v0.5.5 h1:jkgx1TjbQPD/feRoK+S/mXw9e1uj6WilpHrXJowi6oA= pgregory.net/rapid v0.5.5/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index f3d77336646..db6932a3149 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -230,7 +230,7 @@ require ( github.com/holiman/uint256 v1.2.2 // indirect github.com/huandu/skiplist v1.2.0 // indirect github.com/huin/goupnp v1.0.3 // indirect - github.com/imdario/mergo v0.3.15 // indirect + github.com/imdario/mergo v0.3.16 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/ipfs/go-cid v0.0.7 // indirect github.com/ipfs/go-datastore v0.4.5 // indirect @@ -256,7 +256,7 @@ require ( github.com/jpillora/backoff v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/julienschmidt/httprouter v1.3.0 // indirect - github.com/klauspost/compress v1.16.3 // indirect + github.com/klauspost/compress v1.16.7 // indirect github.com/klauspost/cpuid/v2 v2.2.4 // indirect github.com/koron/go-ssdp v0.0.2 // indirect github.com/kr/pretty v0.3.1 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index ea87cfd60bc..ddd8b070a86 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -1401,8 +1401,8 @@ github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:q github.com/iancoleman/strcase v0.2.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= -github.com/imdario/mergo v0.3.15 h1:M8XP7IuFNsqUx6VPK2P9OSmsYsI/YFaGil0uD21V3dM= -github.com/imdario/mergo v0.3.15/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= +github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= +github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/improbable-eng/grpc-web v0.15.0 h1:BN+7z6uNXZ1tQGcNAuaU1YjsLTApzkjt2tzCixLaUPQ= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= @@ -1576,8 +1576,8 @@ github.com/klauspost/compress v1.11.4/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYs github.com/klauspost/compress v1.12.3/go.mod h1:8dP1Hq4DHOhN9w426knH3Rhby4rFm6D8eO+e+Dq5Gzg= github.com/klauspost/compress v1.13.6/go.mod h1:/3/Vjq9QcHkK5uEr5lBEmyoZ1iFhe47etQ6QUkpK6sk= github.com/klauspost/compress v1.15.9/go.mod h1:PhcZ0MbTNciWF3rruxRgKxI5NkcHHrHUDtV4Yw2GlzU= -github.com/klauspost/compress v1.16.3 h1:XuJt9zzcnaz6a16/OU53ZjWp/v7/42WcR5t2a0PcNQY= -github.com/klauspost/compress v1.16.3/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/klauspost/compress v1.16.7 h1:2mk3MPGNzKyxErAw8YaohYh69+pa4sIQSC0fPGCFR9I= +github.com/klauspost/compress v1.16.7/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/klauspost/cpuid/v2 v2.0.4/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= github.com/klauspost/cpuid/v2 v2.0.9/go.mod h1:FInQzS24/EEf25PyTYn52gqo7WaD8xa0213Md/qVLRg= @@ -2108,7 +2108,7 @@ github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndr github.com/posener/complete v1.2.3/go.mod h1:WZIdtGGp+qx0sLrYKtIRAruyNpv6hFCicSgv7Sy7s/s= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c h1:ncq/mPwQF4JjgDlrVEn3C11VoGHZN7m8qihwgMEtzYw= github.com/power-devops/perfstat v0.0.0-20210106213030-5aafc221ea8c/go.mod h1:OmDBASR4679mdNQnz2pUhc2G8CO2JrUAVFDRBDP/hJE= -github.com/pressly/goose/v3 v3.5.3 h1:lIQIIXVbdO2RuQtJBS1e7MZjKEk0demVWt6i0YPiOrg= +github.com/pressly/goose/v3 v3.15.0 h1:6tY5aDqFknY6VZkorFGgZtWygodZQxfmmEF4rqyJW9k= github.com/prometheus/alertmanager v0.25.0 h1:vbXKUR6PYRiZPRIKfmXaG+dmCKG52RtPL4Btl8hQGvg= github.com/prometheus/alertmanager v0.25.0/go.mod h1:MEZ3rFVHqKZsw7IcNS/m4AWZeXThmJhumpiWR4eHU/w= github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= From 477f602280b0c86c99acb1012e2547ee8e4cfc94 Mon Sep 17 00:00:00 2001 From: Rens Rooimans Date: Tue, 22 Aug 2023 16:39:49 +0200 Subject: [PATCH 229/270] add generic burn mint 677 token (#10207) * add generic burn mint 677 token * add wrappers * explicitly keep using old link token in hh tests * add shared to compile_all --- contracts/gas-snapshots/shared.gas-snapshot | 32 + contracts/scripts/native_solc_compile_all | 2 +- .../scripts/native_solc_compile_all_shared | 29 + .../src/v0.8/shared/access/OwnerIsCreator.sol | 10 + contracts/src/v0.8/shared/test/BaseTest.t.sol | 29 + .../test/token/ERC677/BurnMintERC677.t.sol | 348 +++ .../token/ERC677/OpStackBurnMintERC677.t.sol | 117 + .../shared/token/ERC20/IBurnMintERC20.sol | 29 + .../token/ERC20/IOptimismMintableERC20.sol | 25 + .../shared/token/ERC677/BurnMintERC677.sol | 216 ++ .../src/v0.8/shared/token/ERC677/ERC677.sol | 24 + .../src/v0.8/shared/token/ERC677/IERC677.sol | 13 + .../shared/token/ERC677/IERC677Receiver.sol | 6 + .../v0.8/shared/token/ERC677/LinkToken.sol | 8 + .../token/ERC677/OpStackBurnMintERC677.sol | 49 + .../token/ERC20/extensions/ERC20Burnable.sol | 39 + contracts/test/v0.7/KeeperRegistry1_1.test.ts | 6 +- .../v0.7/UpkeepRegistrationRequests.test.ts | 4 +- contracts/test/v0.8/KeeperRegistrar.test.ts | 4 +- .../VRFSubscriptionBalanceMonitor.test.ts | 7 +- .../automation/AutomationRegistrar2_1.test.ts | 4 +- .../automation/ERC20BalanceMonitor.test.ts | 5 +- .../automation/KeeperRegistrar2_0.test.ts | 4 +- .../v0.8/automation/KeeperRegistry1_2.test.ts | 4 +- .../v0.8/automation/KeeperRegistry1_3.test.ts | 4 +- .../v0.8/automation/KeeperRegistry2_0.test.ts | 4 +- .../v0.8/automation/KeeperRegistry2_1.test.ts | 18 +- .../LinkAvailableBalanceMonitor.test.ts | 8 +- .../automation/UpkeepTranscoder3_0.test.ts | 4 +- .../automation/UpkeepTranscoder4_0.test.ts | 11 +- contracts/test/v0.8/dev/VRFV2Wrapper.test.ts | 11 +- .../burn_mint_erc677/burn_mint_erc677.go | 2068 +++++++++++++++++ .../shared/generated/link_token/link_token.go | 2068 +++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 3 + core/gethwrappers/shared/go_generate.go | 6 + 35 files changed, 5186 insertions(+), 33 deletions(-) create mode 100755 contracts/scripts/native_solc_compile_all_shared create mode 100644 contracts/src/v0.8/shared/access/OwnerIsCreator.sol create mode 100644 contracts/src/v0.8/shared/test/BaseTest.t.sol create mode 100644 contracts/src/v0.8/shared/test/token/ERC677/BurnMintERC677.t.sol create mode 100644 contracts/src/v0.8/shared/test/token/ERC677/OpStackBurnMintERC677.t.sol create mode 100644 contracts/src/v0.8/shared/token/ERC20/IBurnMintERC20.sol create mode 100644 contracts/src/v0.8/shared/token/ERC20/IOptimismMintableERC20.sol create mode 100644 contracts/src/v0.8/shared/token/ERC677/BurnMintERC677.sol create mode 100644 contracts/src/v0.8/shared/token/ERC677/ERC677.sol create mode 100644 contracts/src/v0.8/shared/token/ERC677/IERC677.sol create mode 100644 contracts/src/v0.8/shared/token/ERC677/IERC677Receiver.sol create mode 100644 contracts/src/v0.8/shared/token/ERC677/LinkToken.sol create mode 100644 contracts/src/v0.8/shared/token/ERC677/OpStackBurnMintERC677.sol create mode 100644 contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Burnable.sol create mode 100644 core/gethwrappers/shared/generated/burn_mint_erc677/burn_mint_erc677.go create mode 100644 core/gethwrappers/shared/generated/link_token/link_token.go create mode 100644 core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt create mode 100644 core/gethwrappers/shared/go_generate.go diff --git a/contracts/gas-snapshots/shared.gas-snapshot b/contracts/gas-snapshots/shared.gas-snapshot index e69de29bb2d..cb2e8defe4a 100644 --- a/contracts/gas-snapshots/shared.gas-snapshot +++ b/contracts/gas-snapshots/shared.gas-snapshot @@ -0,0 +1,32 @@ +BurnMintERC677_approve:testApproveSuccess() (gas: 52254) +BurnMintERC677_approve:testInvalidAddressReverts() (gas: 10641) +BurnMintERC677_burn:testBasicBurnSuccess() (gas: 164344) +BurnMintERC677_burn:testBurnFromZeroAddressReverts() (gas: 43462) +BurnMintERC677_burn:testExceedsBalanceReverts() (gas: 18035) +BurnMintERC677_burn:testSenderNotBurnerReverts() (gas: 13359) +BurnMintERC677_burnFrom:testBurnFromSuccess() (gas: 54662) +BurnMintERC677_burnFrom:testExceedsBalanceReverts() (gas: 32873) +BurnMintERC677_burnFrom:testInsufficientAllowanceReverts() (gas: 18107) +BurnMintERC677_burnFrom:testSenderNotBurnerReverts() (gas: 13359) +BurnMintERC677_burnFromAlias:testBurnFromSuccess() (gas: 54688) +BurnMintERC677_burnFromAlias:testExceedsBalanceReverts() (gas: 32889) +BurnMintERC677_burnFromAlias:testInsufficientAllowanceReverts() (gas: 18127) +BurnMintERC677_burnFromAlias:testSenderNotBurnerReverts() (gas: 13379) +BurnMintERC677_constructor:testConstructorSuccess() (gas: 1669109) +BurnMintERC677_decreaseApproval:testDecreaseApprovalSuccess() (gas: 28520) +BurnMintERC677_grantMintAndBurnRoles:testGrantMintAndBurnRolesSuccess() (gas: 120049) +BurnMintERC677_grantRole:testGrantBurnAccessSuccess() (gas: 52707) +BurnMintERC677_grantRole:testGrantManySuccess() (gas: 935521) +BurnMintERC677_grantRole:testGrantMintAccessSuccess() (gas: 93588) +BurnMintERC677_increaseApproval:testIncreaseApprovalSuccess() (gas: 40911) +BurnMintERC677_mint:testBasicMintSuccess() (gas: 149365) +BurnMintERC677_mint:testMaxSupplyExceededReverts() (gas: 46627) +BurnMintERC677_mint:testSenderNotMinterReverts() (gas: 11195) +BurnMintERC677_supportsInterface:testConstructorSuccess() (gas: 8685) +BurnMintERC677_transfer:testInvalidAddressReverts() (gas: 10617) +BurnMintERC677_transfer:testTransferSuccess() (gas: 39462) +OpStackBurnMintERC677_constructor:testConstructorSuccess() (gas: 1739317) +OpStackBurnMintERC677_interfaceCompatibility:testBurnCompatibility() (gas: 259440) +OpStackBurnMintERC677_interfaceCompatibility:testMintCompatibility() (gas: 137935) +OpStackBurnMintERC677_interfaceCompatibility:testStaticFunctionsCompatibility() (gas: 10622) +OpStackBurnMintERC677_supportsInterface:testConstructorSuccess() (gas: 8961) \ No newline at end of file diff --git a/contracts/scripts/native_solc_compile_all b/contracts/scripts/native_solc_compile_all index b90405e7de9..e695c49206c 100755 --- a/contracts/scripts/native_solc_compile_all +++ b/contracts/scripts/native_solc_compile_all @@ -12,7 +12,7 @@ python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt # 6 and 7 are legacy contracts, for each other 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 6 7 feeds functions llo-feeds transmission vrf automation logpoller events_mock +for product in 6 7 feeds functions llo-feeds transmission vrf automation logpoller events_mock shared do $SCRIPTPATH/native_solc_compile_all_$product done diff --git a/contracts/scripts/native_solc_compile_all_shared b/contracts/scripts/native_solc_compile_all_shared new file mode 100755 index 00000000000..1912b419228 --- /dev/null +++ b/contracts/scripts/native_solc_compile_all_shared @@ -0,0 +1,29 @@ +#!/usr/bin/env bash + +set -e + +echo " ┌──────────────────────────────────────────────┐" +echo " │ Compiling shared contracts... │" +echo " └──────────────────────────────────────────────┘" + +SOLC_VERSION="0.8.19" +OPTIMIZE_RUNS=1000000 + + +SCRIPTPATH="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; pwd -P )" +python3 -m pip install --require-hashes -r $SCRIPTPATH/requirements.txt +solc-select install $SOLC_VERSION +solc-select use $SOLC_VERSION +export SOLC_VERSION=$SOLC_VERSION + +ROOT="$( cd "$(dirname "$0")" >/dev/null 2>&1 ; cd ../../ && pwd -P )" + +compileContract () { + solc --overwrite --optimize --optimize-runs $OPTIMIZE_RUNS --metadata-hash none \ + -o $ROOT/contracts/solc/v$SOLC_VERSION \ + --abi --bin --allow-paths $ROOT/contracts/src/v0.8\ + $ROOT/contracts/src/v0.8/$1 +} + +compileContract shared/token/ERC677/BurnMintERC677.sol +compileContract shared/token/ERC677/LinkToken.sol diff --git a/contracts/src/v0.8/shared/access/OwnerIsCreator.sol b/contracts/src/v0.8/shared/access/OwnerIsCreator.sol new file mode 100644 index 00000000000..829c68794a5 --- /dev/null +++ b/contracts/src/v0.8/shared/access/OwnerIsCreator.sol @@ -0,0 +1,10 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {ConfirmedOwner} from "./ConfirmedOwner.sol"; + +/// @title The OwnerIsCreator contract +/// @notice A contract with helpers for basic contract ownership. +contract OwnerIsCreator is ConfirmedOwner { + constructor() ConfirmedOwner(msg.sender) {} +} diff --git a/contracts/src/v0.8/shared/test/BaseTest.t.sol b/contracts/src/v0.8/shared/test/BaseTest.t.sol new file mode 100644 index 00000000000..4d8ef60eb20 --- /dev/null +++ b/contracts/src/v0.8/shared/test/BaseTest.t.sol @@ -0,0 +1,29 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.19; + +import "forge-std/Test.sol"; + +contract BaseTest is Test { + bool private s_baseTestInitialized; + address internal constant OWNER = 0x72da681452Ab957d1020c25fFaCA47B43980b7C3; + address internal constant STRANGER = 0x02e7d5DD1F4dDbC9f512FfA01d30aa190Ae3edBb; + + // Fri May 26 2023 13:49:53 GMT+0000 + uint256 internal constant BLOCK_TIME = 1685108993; + + function setUp() public virtual { + // BaseTest.setUp is often called multiple times from tests' setUp due to inheritance. + if (s_baseTestInitialized) return; + s_baseTestInitialized = true; + + vm.label(OWNER, "Owner"); + vm.label(STRANGER, "Stranger"); + + // Set the sender to OWNER permanently + vm.startPrank(OWNER); + deal(OWNER, 1e20); + + // Set the block time to a constant known value + vm.warp(BLOCK_TIME); + } +} diff --git a/contracts/src/v0.8/shared/test/token/ERC677/BurnMintERC677.t.sol b/contracts/src/v0.8/shared/test/token/ERC677/BurnMintERC677.t.sol new file mode 100644 index 00000000000..6b223f51236 --- /dev/null +++ b/contracts/src/v0.8/shared/test/token/ERC677/BurnMintERC677.t.sol @@ -0,0 +1,348 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.19; + +import {IBurnMintERC20} from "../../../token/ERC20/IBurnMintERC20.sol"; +import {IERC677} from "../../../token/ERC677/IERC677.sol"; + +import {BaseTest} from "../../BaseTest.t.sol"; +import {BurnMintERC677} from "../../../token/ERC677/BurnMintERC677.sol"; + +import {IERC20} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol"; +import {Strings} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Strings.sol"; +import {IERC165} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol"; + +contract BurnMintERC677Setup is BaseTest { + event Transfer(address indexed from, address indexed to, uint256 value); + event MintAccessGranted(address indexed minter); + event BurnAccessGranted(address indexed burner); + event MintAccessRevoked(address indexed minter); + event BurnAccessRevoked(address indexed burner); + + BurnMintERC677 internal s_burnMintERC677; + + address internal s_mockPool = address(6243783892); + uint256 internal s_amount = 1e18; + + function setUp() public virtual override { + BaseTest.setUp(); + s_burnMintERC677 = new BurnMintERC677("Chainlink Token", "LINK", 18, 1e27); + + // Set s_mockPool to be a burner and minter + s_burnMintERC677.grantMintAndBurnRoles(s_mockPool); + deal(address(s_burnMintERC677), OWNER, s_amount); + } +} + +contract BurnMintERC677_constructor is BurnMintERC677Setup { + function testConstructorSuccess() public { + string memory name = "Chainlink token v2"; + string memory symbol = "LINK2"; + uint8 decimals = 19; + uint256 maxSupply = 1e33; + s_burnMintERC677 = new BurnMintERC677(name, symbol, decimals, maxSupply); + + assertEq(name, s_burnMintERC677.name()); + assertEq(symbol, s_burnMintERC677.symbol()); + assertEq(decimals, s_burnMintERC677.decimals()); + assertEq(maxSupply, s_burnMintERC677.maxSupply()); + } +} + +contract BurnMintERC677_approve is BurnMintERC677Setup { + function testApproveSuccess() public { + uint256 balancePre = s_burnMintERC677.balanceOf(STRANGER); + uint256 sendingAmount = s_amount / 2; + + s_burnMintERC677.approve(STRANGER, sendingAmount); + + changePrank(STRANGER); + + s_burnMintERC677.transferFrom(OWNER, STRANGER, sendingAmount); + + assertEq(sendingAmount + balancePre, s_burnMintERC677.balanceOf(STRANGER)); + } + + // Reverts + + function testInvalidAddressReverts() public { + vm.expectRevert(); + + s_burnMintERC677.approve(address(s_burnMintERC677), s_amount); + } +} + +contract BurnMintERC677_transfer is BurnMintERC677Setup { + function testTransferSuccess() public { + uint256 balancePre = s_burnMintERC677.balanceOf(STRANGER); + uint256 sendingAmount = s_amount / 2; + + s_burnMintERC677.transfer(STRANGER, sendingAmount); + + assertEq(sendingAmount + balancePre, s_burnMintERC677.balanceOf(STRANGER)); + } + + // Reverts + + function testInvalidAddressReverts() public { + vm.expectRevert(); + + s_burnMintERC677.transfer(address(s_burnMintERC677), s_amount); + } +} + +contract BurnMintERC677_mint is BurnMintERC677Setup { + function testBasicMintSuccess() public { + uint256 balancePre = s_burnMintERC677.balanceOf(OWNER); + + s_burnMintERC677.grantMintAndBurnRoles(OWNER); + + vm.expectEmit(); + emit Transfer(address(0), OWNER, s_amount); + + s_burnMintERC677.mint(OWNER, s_amount); + + assertEq(balancePre + s_amount, s_burnMintERC677.balanceOf(OWNER)); + } + + // Revert + + function testSenderNotMinterReverts() public { + vm.expectRevert(abi.encodeWithSelector(BurnMintERC677.SenderNotMinter.selector, OWNER)); + s_burnMintERC677.mint(STRANGER, 1e18); + } + + function testMaxSupplyExceededReverts() public { + changePrank(s_mockPool); + + // Mint max supply + s_burnMintERC677.mint(OWNER, s_burnMintERC677.maxSupply()); + + vm.expectRevert( + abi.encodeWithSelector(BurnMintERC677.MaxSupplyExceeded.selector, s_burnMintERC677.maxSupply() + 1) + ); + + // Attempt to mint 1 more than max supply + s_burnMintERC677.mint(OWNER, 1); + } +} + +contract BurnMintERC677_burn is BurnMintERC677Setup { + function testBasicBurnSuccess() public { + s_burnMintERC677.grantBurnRole(OWNER); + deal(address(s_burnMintERC677), OWNER, s_amount); + + vm.expectEmit(); + emit Transfer(OWNER, address(0), s_amount); + + s_burnMintERC677.burn(s_amount); + + assertEq(0, s_burnMintERC677.balanceOf(OWNER)); + } + + // Revert + + function testSenderNotBurnerReverts() public { + vm.expectRevert(abi.encodeWithSelector(BurnMintERC677.SenderNotBurner.selector, OWNER)); + + s_burnMintERC677.burnFrom(STRANGER, s_amount); + } + + function testExceedsBalanceReverts() public { + changePrank(s_mockPool); + + vm.expectRevert("ERC20: burn amount exceeds balance"); + + s_burnMintERC677.burn(s_amount * 2); + } + + function testBurnFromZeroAddressReverts() public { + s_burnMintERC677.grantBurnRole(address(0)); + changePrank(address(0)); + + vm.expectRevert("ERC20: burn from the zero address"); + + s_burnMintERC677.burn(0); + } +} + +contract BurnMintERC677_burnFromAlias is BurnMintERC677Setup { + function setUp() public virtual override { + BurnMintERC677Setup.setUp(); + } + + function testBurnFromSuccess() public { + s_burnMintERC677.approve(s_mockPool, s_amount); + + changePrank(s_mockPool); + + s_burnMintERC677.burn(OWNER, s_amount); + + assertEq(0, s_burnMintERC677.balanceOf(OWNER)); + } + + // Reverts + + function testSenderNotBurnerReverts() public { + vm.expectRevert(abi.encodeWithSelector(BurnMintERC677.SenderNotBurner.selector, OWNER)); + + s_burnMintERC677.burn(OWNER, s_amount); + } + + function testInsufficientAllowanceReverts() public { + changePrank(s_mockPool); + + vm.expectRevert("ERC20: insufficient allowance"); + + s_burnMintERC677.burn(OWNER, s_amount); + } + + function testExceedsBalanceReverts() public { + s_burnMintERC677.approve(s_mockPool, s_amount * 2); + + changePrank(s_mockPool); + + vm.expectRevert("ERC20: burn amount exceeds balance"); + + s_burnMintERC677.burn(OWNER, s_amount * 2); + } +} + +contract BurnMintERC677_burnFrom is BurnMintERC677Setup { + function setUp() public virtual override { + BurnMintERC677Setup.setUp(); + } + + function testBurnFromSuccess() public { + s_burnMintERC677.approve(s_mockPool, s_amount); + + changePrank(s_mockPool); + + s_burnMintERC677.burnFrom(OWNER, s_amount); + + assertEq(0, s_burnMintERC677.balanceOf(OWNER)); + } + + // Reverts + + function testSenderNotBurnerReverts() public { + vm.expectRevert(abi.encodeWithSelector(BurnMintERC677.SenderNotBurner.selector, OWNER)); + + s_burnMintERC677.burnFrom(OWNER, s_amount); + } + + function testInsufficientAllowanceReverts() public { + changePrank(s_mockPool); + + vm.expectRevert("ERC20: insufficient allowance"); + + s_burnMintERC677.burnFrom(OWNER, s_amount); + } + + function testExceedsBalanceReverts() public { + s_burnMintERC677.approve(s_mockPool, s_amount * 2); + + changePrank(s_mockPool); + + vm.expectRevert("ERC20: burn amount exceeds balance"); + + s_burnMintERC677.burnFrom(OWNER, s_amount * 2); + } +} + +contract BurnMintERC677_grantRole is BurnMintERC677Setup { + function testGrantMintAccessSuccess() public { + assertFalse(s_burnMintERC677.isMinter(STRANGER)); + + vm.expectEmit(); + emit MintAccessGranted(STRANGER); + + s_burnMintERC677.grantMintAndBurnRoles(STRANGER); + + assertTrue(s_burnMintERC677.isMinter(STRANGER)); + + vm.expectEmit(); + emit MintAccessRevoked(STRANGER); + + s_burnMintERC677.revokeMintRole(STRANGER); + + assertFalse(s_burnMintERC677.isMinter(STRANGER)); + } + + function testGrantBurnAccessSuccess() public { + assertFalse(s_burnMintERC677.isBurner(STRANGER)); + + vm.expectEmit(); + emit BurnAccessGranted(STRANGER); + + s_burnMintERC677.grantBurnRole(STRANGER); + + assertTrue(s_burnMintERC677.isBurner(STRANGER)); + + vm.expectEmit(); + emit BurnAccessRevoked(STRANGER); + + s_burnMintERC677.revokeBurnRole(STRANGER); + + assertFalse(s_burnMintERC677.isBurner(STRANGER)); + } + + function testGrantManySuccess() public { + uint256 numberOfPools = 10; + address[] memory permissionedAddresses = new address[](numberOfPools + 1); + permissionedAddresses[0] = s_mockPool; + + for (uint160 i = 0; i < numberOfPools; ++i) { + permissionedAddresses[i + 1] = address(i); + s_burnMintERC677.grantMintAndBurnRoles(address(i)); + } + + assertEq(permissionedAddresses, s_burnMintERC677.getBurners()); + assertEq(permissionedAddresses, s_burnMintERC677.getMinters()); + } +} + +contract BurnMintERC677_grantMintAndBurnRoles is BurnMintERC677Setup { + function testGrantMintAndBurnRolesSuccess() public { + assertFalse(s_burnMintERC677.isMinter(STRANGER)); + assertFalse(s_burnMintERC677.isBurner(STRANGER)); + + vm.expectEmit(); + emit MintAccessGranted(STRANGER); + vm.expectEmit(); + emit BurnAccessGranted(STRANGER); + + s_burnMintERC677.grantMintAndBurnRoles(STRANGER); + + assertTrue(s_burnMintERC677.isMinter(STRANGER)); + assertTrue(s_burnMintERC677.isBurner(STRANGER)); + } +} + +contract BurnMintERC677_decreaseApproval is BurnMintERC677Setup { + function testDecreaseApprovalSuccess() public { + s_burnMintERC677.approve(s_mockPool, s_amount); + uint256 allowance = s_burnMintERC677.allowance(OWNER, s_mockPool); + assertEq(allowance, s_amount); + s_burnMintERC677.decreaseApproval(s_mockPool, s_amount); + assertEq(s_burnMintERC677.allowance(OWNER, s_mockPool), allowance - s_amount); + } +} + +contract BurnMintERC677_increaseApproval is BurnMintERC677Setup { + function testIncreaseApprovalSuccess() public { + s_burnMintERC677.approve(s_mockPool, s_amount); + uint256 allowance = s_burnMintERC677.allowance(OWNER, s_mockPool); + assertEq(allowance, s_amount); + s_burnMintERC677.increaseApproval(s_mockPool, s_amount); + assertEq(s_burnMintERC677.allowance(OWNER, s_mockPool), allowance + s_amount); + } +} + +contract BurnMintERC677_supportsInterface is BurnMintERC677Setup { + function testConstructorSuccess() public { + assertTrue(s_burnMintERC677.supportsInterface(type(IERC20).interfaceId)); + assertTrue(s_burnMintERC677.supportsInterface(type(IERC677).interfaceId)); + assertTrue(s_burnMintERC677.supportsInterface(type(IBurnMintERC20).interfaceId)); + assertTrue(s_burnMintERC677.supportsInterface(type(IERC165).interfaceId)); + } +} diff --git a/contracts/src/v0.8/shared/test/token/ERC677/OpStackBurnMintERC677.t.sol b/contracts/src/v0.8/shared/test/token/ERC677/OpStackBurnMintERC677.t.sol new file mode 100644 index 00000000000..f22a92a4258 --- /dev/null +++ b/contracts/src/v0.8/shared/test/token/ERC677/OpStackBurnMintERC677.t.sol @@ -0,0 +1,117 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IBurnMintERC20} from "../../../token/ERC20/IBurnMintERC20.sol"; +import {IOptimismMintableERC20Minimal, IOptimismMintableERC20} from "../../../token/ERC20/IOptimismMintableERC20.sol"; +import {IERC677} from "../../../token/ERC677/IERC677.sol"; + +import {BurnMintERC677} from "../../../token/ERC677/BurnMintERC677.sol"; +import {BaseTest} from "../../BaseTest.t.sol"; +import {OpStackBurnMintERC677} from "../../../token/ERC677/OpStackBurnMintERC677.sol"; + +import {IERC165} from "../../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol"; + +contract OpStackBurnMintERC677Setup is BaseTest { + address internal s_l1Token = address(897352983527); + address internal s_l2Bridge = address(1928235235); + + OpStackBurnMintERC677 internal s_opStackBurnMintERC677; + + function setUp() public virtual override { + BaseTest.setUp(); + s_opStackBurnMintERC677 = new OpStackBurnMintERC677("Chainlink Token", "LINK", 18, 1e27, s_l1Token, s_l2Bridge); + } +} + +contract OpStackBurnMintERC677_constructor is OpStackBurnMintERC677Setup { + function testConstructorSuccess() public { + string memory name = "Chainlink token l2"; + string memory symbol = "LINK L2"; + uint8 decimals = 18; + uint256 maxSupply = 1e33; + s_opStackBurnMintERC677 = new OpStackBurnMintERC677(name, symbol, decimals, maxSupply, s_l1Token, s_l2Bridge); + + assertEq(name, s_opStackBurnMintERC677.name()); + assertEq(symbol, s_opStackBurnMintERC677.symbol()); + assertEq(decimals, s_opStackBurnMintERC677.decimals()); + assertEq(maxSupply, s_opStackBurnMintERC677.maxSupply()); + assertEq(s_l1Token, s_opStackBurnMintERC677.remoteToken()); + assertEq(s_l2Bridge, s_opStackBurnMintERC677.bridge()); + } +} + +contract OpStackBurnMintERC677_supportsInterface is OpStackBurnMintERC677Setup { + function testConstructorSuccess() public { + assertTrue(s_opStackBurnMintERC677.supportsInterface(type(IOptimismMintableERC20Minimal).interfaceId)); + assertTrue(s_opStackBurnMintERC677.supportsInterface(type(IERC677).interfaceId)); + assertTrue(s_opStackBurnMintERC677.supportsInterface(type(IBurnMintERC20).interfaceId)); + assertTrue(s_opStackBurnMintERC677.supportsInterface(type(IERC165).interfaceId)); + } +} + +contract OpStackBurnMintERC677_interfaceCompatibility is OpStackBurnMintERC677Setup { + event Transfer(address indexed from, address indexed to, uint256 value); + + IOptimismMintableERC20 internal s_opStackToken; + + function setUp() public virtual override { + OpStackBurnMintERC677Setup.setUp(); + s_opStackToken = IOptimismMintableERC20(address(s_opStackBurnMintERC677)); + } + + function testStaticFunctionsCompatibility() public { + assertEq(s_l1Token, s_opStackToken.remoteToken()); + assertEq(s_l2Bridge, s_opStackToken.bridge()); + } + + function testMintCompatibility() public { + // Ensure roles work + vm.expectRevert(abi.encodeWithSelector(BurnMintERC677.SenderNotMinter.selector, OWNER)); + s_opStackToken.mint(OWNER, 1); + + // Use the actual contract to grant mint + s_opStackBurnMintERC677.grantMintRole(OWNER); + + // Ensure zero address check works + vm.expectRevert("ERC20: mint to the zero address"); + s_opStackToken.mint(address(0x0), 0); + + address mintToAddress = address(0x1); + uint256 mintAmount = 1; + + vm.expectEmit(); + emit Transfer(address(0), mintToAddress, mintAmount); + + s_opStackToken.mint(mintToAddress, mintAmount); + } + + function testBurnCompatibility() public { + // Ensure roles work + vm.expectRevert(abi.encodeWithSelector(BurnMintERC677.SenderNotBurner.selector, OWNER)); + s_opStackToken.burn(address(0x0), 1); + + // Use the actual contract to grant burn + s_opStackBurnMintERC677.grantBurnRole(OWNER); + + // Ensure zero address check works + vm.expectRevert("ERC20: approve from the zero address"); + s_opStackToken.burn(address(0x0), 0); + + address burnFromAddress = address(0x1); + uint256 burnAmount = 1; + + // Ensure `burn(address, amount)` works like burnFrom and requires allowance + vm.expectRevert("ERC20: insufficient allowance"); + s_opStackToken.burn(burnFromAddress, burnAmount); + + changePrank(burnFromAddress); + deal(address(s_opStackToken), burnFromAddress, burnAmount); + s_opStackBurnMintERC677.approve(OWNER, burnAmount); + changePrank(OWNER); + + vm.expectEmit(); + emit Transfer(burnFromAddress, address(0x0), burnAmount); + + s_opStackToken.burn(burnFromAddress, burnAmount); + } +} diff --git a/contracts/src/v0.8/shared/token/ERC20/IBurnMintERC20.sol b/contracts/src/v0.8/shared/token/ERC20/IBurnMintERC20.sol new file mode 100644 index 00000000000..2b2f3fd3787 --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC20/IBurnMintERC20.sol @@ -0,0 +1,29 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol"; + +interface IBurnMintERC20 is IERC20 { + /// @notice Mints new tokens for a given address. + /// @param account The address to mint the new tokens to. + /// @param amount The number of tokens to be minted. + /// @dev this function increases the total supply. + function mint(address account, uint256 amount) external; + + /// @notice Burns tokens from the sender. + /// @param amount The number of tokens to be burned. + /// @dev this function decreases the total supply. + function burn(uint256 amount) external; + + /// @notice Burns tokens from a given address.. + /// @param account The address to burn tokens from. + /// @param amount The number of tokens to be burned. + /// @dev this function decreases the total supply. + function burn(address account, uint256 amount) external; + + /// @notice Burns tokens from a given address.. + /// @param account The address to burn tokens from. + /// @param amount The number of tokens to be burned. + /// @dev this function decreases the total supply. + function burnFrom(address account, uint256 amount) external; +} diff --git a/contracts/src/v0.8/shared/token/ERC20/IOptimismMintableERC20.sol b/contracts/src/v0.8/shared/token/ERC20/IOptimismMintableERC20.sol new file mode 100644 index 00000000000..79441cf89f7 --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC20/IOptimismMintableERC20.sol @@ -0,0 +1,25 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol"; + +/// @title IOptimismMintableERC20Minimal +/// @dev This interface is a subset of the Optimism ERC20 interface that is defined +/// below. This is done to now have to overwrite the burn and mint functions again in +/// the implementation, as that leads to more complicated, error prone code. +interface IOptimismMintableERC20Minimal is IERC165 { + /// @notice Returns the address of the token on L1. + function remoteToken() external view returns (address); + + /// @notice Returns the address of the bridge on L2. + function bridge() external returns (address); +} + +/// @title IOptimismMintableERC20 +/// @notice This is the complete interface for the Optimism mintable ERC20 token as defined in +/// https://github.com/ethereum-optimism/optimism/blob/develop/packages/contracts-bedrock/contracts/universal/IOptimismMintableERC20.sol +interface IOptimismMintableERC20 is IERC165, IOptimismMintableERC20Minimal { + function mint(address _to, uint256 _amount) external; + + function burn(address _from, uint256 _amount) external; +} diff --git a/contracts/src/v0.8/shared/token/ERC677/BurnMintERC677.sol b/contracts/src/v0.8/shared/token/ERC677/BurnMintERC677.sol new file mode 100644 index 00000000000..0d78581b13c --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC677/BurnMintERC677.sol @@ -0,0 +1,216 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IBurnMintERC20} from "../ERC20/IBurnMintERC20.sol"; +import {IERC677} from "./IERC677.sol"; + +import {ERC677} from "./ERC677.sol"; +import {OwnerIsCreator} from "../../access/OwnerIsCreator.sol"; + +import {ERC20Burnable} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Burnable.sol"; +import {EnumerableSet} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/structs/EnumerableSet.sol"; +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol"; +import {IERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/IERC20.sol"; + +/// @notice A basic ERC677 compatible token contract with burn and minting roles. +/// @dev The total supply can be limited during deployment. +contract BurnMintERC677 is IBurnMintERC20, ERC677, IERC165, ERC20Burnable, OwnerIsCreator { + using EnumerableSet for EnumerableSet.AddressSet; + + error SenderNotMinter(address sender); + error SenderNotBurner(address sender); + error MaxSupplyExceeded(uint256 supplyAfterMint); + + event MintAccessGranted(address indexed minter); + event BurnAccessGranted(address indexed burner); + event MintAccessRevoked(address indexed minter); + event BurnAccessRevoked(address indexed burner); + + // @dev the allowed minter addresses + EnumerableSet.AddressSet internal s_minters; + // @dev the allowed burner addresses + EnumerableSet.AddressSet internal s_burners; + + /// @dev The number of decimals for the token + uint8 internal immutable i_decimals; + + /// @dev The maximum supply of the token, 0 if unlimited + uint256 internal immutable i_maxSupply; + + constructor(string memory name, string memory symbol, uint8 decimals_, uint256 maxSupply_) ERC677(name, symbol) { + i_decimals = decimals_; + i_maxSupply = maxSupply_; + } + + function supportsInterface(bytes4 interfaceId) public pure virtual override returns (bool) { + return + interfaceId == type(IERC20).interfaceId || + interfaceId == type(IERC677).interfaceId || + interfaceId == type(IBurnMintERC20).interfaceId || + interfaceId == type(IERC165).interfaceId; + } + + // ================================================================ + // | ERC20 | + // ================================================================ + + /// @dev Returns the number of decimals used in its user representation. + function decimals() public view virtual override returns (uint8) { + return i_decimals; + } + + /// @dev Returns the max supply of the token, 0 if unlimited. + function maxSupply() public view virtual returns (uint256) { + return i_maxSupply; + } + + /// @dev Uses OZ ERC20 _transfer to disallow sending to address(0). + /// @dev Disallows sending to address(this) + function _transfer(address from, address to, uint256 amount) internal virtual override validAddress(to) { + super._transfer(from, to, amount); + } + + /// @dev Uses OZ ERC20 _approve to disallow approving for address(0). + /// @dev Disallows approving for address(this) + function _approve(address owner, address spender, uint256 amount) internal virtual override validAddress(spender) { + super._approve(owner, spender, amount); + } + + /// @dev Exists to be backwards compatible with the older naming convention. + function decreaseApproval(address spender, uint256 subtractedValue) external returns (bool success) { + return decreaseAllowance(spender, subtractedValue); + } + + /// @dev Exists to be backwards compatible with the older naming convention. + function increaseApproval(address spender, uint256 addedValue) external { + increaseAllowance(spender, addedValue); + } + + /// @notice Check if recipient is valid (not this contract address). + /// @param recipient the account we transfer/approve to. + /// @dev Reverts with an empty revert to be compatible with the existing link token when + /// the recipient is this contract address. + modifier validAddress(address recipient) virtual { + if (recipient == address(this)) revert(); + _; + } + + // ================================================================ + // | Burning & minting | + // ================================================================ + + /// @inheritdoc ERC20Burnable + /// @dev Uses OZ ERC20 _burn to disallow burning from address(0). + /// @dev Decreases the total supply. + function burn(uint256 amount) public override(IBurnMintERC20, ERC20Burnable) onlyBurner { + super.burn(amount); + } + + /// @inheritdoc IBurnMintERC20 + /// @dev Alias for BurnFrom for compatibility with the older naming convention. + /// @dev Uses burnFrom for all validation & logic. + function burn(address account, uint256 amount) public virtual override { + burnFrom(account, amount); + } + + /// @inheritdoc ERC20Burnable + /// @dev Uses OZ ERC20 _burn to disallow burning from address(0). + /// @dev Decreases the total supply. + function burnFrom(address account, uint256 amount) public override(IBurnMintERC20, ERC20Burnable) onlyBurner { + super.burnFrom(account, amount); + } + + /// @inheritdoc IBurnMintERC20 + /// @dev Uses OZ ERC20 _mint to disallow minting to address(0). + /// @dev Disallows minting to address(this) + /// @dev Increases the total supply. + function mint(address account, uint256 amount) external override onlyMinter validAddress(account) { + if (i_maxSupply != 0 && totalSupply() + amount > i_maxSupply) revert MaxSupplyExceeded(totalSupply() + amount); + + _mint(account, amount); + } + + // ================================================================ + // | Roles | + // ================================================================ + + /// @notice grants both mint and burn roles to `burnAndMinter`. + /// @dev calls public functions so this function does not require + /// access controls. This is handled in the inner functions. + function grantMintAndBurnRoles(address burnAndMinter) external { + grantMintRole(burnAndMinter); + grantBurnRole(burnAndMinter); + } + + /// @notice Grants mint role to the given address. + /// @dev only the owner can call this function. + function grantMintRole(address minter) public onlyOwner { + if (s_minters.add(minter)) { + emit MintAccessGranted(minter); + } + } + + /// @notice Grants burn role to the given address. + /// @dev only the owner can call this function. + function grantBurnRole(address burner) public onlyOwner { + if (s_burners.add(burner)) { + emit BurnAccessGranted(burner); + } + } + + /// @notice Revokes mint role for the given address. + /// @dev only the owner can call this function. + function revokeMintRole(address minter) public onlyOwner { + if (s_minters.remove(minter)) { + emit MintAccessRevoked(minter); + } + } + + /// @notice Revokes burn role from the given address. + /// @dev only the owner can call this function + function revokeBurnRole(address burner) public onlyOwner { + if (s_burners.remove(burner)) { + emit BurnAccessRevoked(burner); + } + } + + /// @notice Returns all permissioned minters + function getMinters() public view returns (address[] memory) { + return s_minters.values(); + } + + /// @notice Returns all permissioned burners + function getBurners() public view returns (address[] memory) { + return s_burners.values(); + } + + // ================================================================ + // | Access | + // ================================================================ + + /// @notice Checks whether a given address is a minter for this token. + /// @return true if the address is allowed to mint. + function isMinter(address minter) public view returns (bool) { + return s_minters.contains(minter); + } + + /// @notice Checks whether a given address is a burner for this token. + /// @return true if the address is allowed to burn. + function isBurner(address burner) public view returns (bool) { + return s_burners.contains(burner); + } + + /// @notice Checks whether the msg.sender is a permissioned minter for this token + /// @dev Reverts with a SenderNotMinter if the check fails + modifier onlyMinter() { + if (!isMinter(msg.sender)) revert SenderNotMinter(msg.sender); + _; + } + + /// @notice Checks whether the msg.sender is a permissioned burner for this token + /// @dev Reverts with a SenderNotBurner if the check fails + modifier onlyBurner() { + if (!isBurner(msg.sender)) revert SenderNotBurner(msg.sender); + _; + } +} diff --git a/contracts/src/v0.8/shared/token/ERC677/ERC677.sol b/contracts/src/v0.8/shared/token/ERC677/ERC677.sol new file mode 100644 index 00000000000..de124d53c55 --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC677/ERC677.sol @@ -0,0 +1,24 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity ^0.8.0; + +import {IERC677} from "./IERC677.sol"; +import {IERC677Receiver} from "./IERC677Receiver.sol"; + +import {Address} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/Address.sol"; +import {ERC20} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol"; + +contract ERC677 is IERC677, ERC20 { + using Address for address; + + constructor(string memory name, string memory symbol) ERC20(name, symbol) {} + + /// @inheritdoc IERC677 + function transferAndCall(address to, uint amount, bytes memory data) public returns (bool success) { + super.transfer(to, amount); + emit Transfer(msg.sender, to, amount, data); + if (to.isContract()) { + IERC677Receiver(to).onTokenTransfer(msg.sender, amount, data); + } + return true; + } +} diff --git a/contracts/src/v0.8/shared/token/ERC677/IERC677.sol b/contracts/src/v0.8/shared/token/ERC677/IERC677.sol new file mode 100644 index 00000000000..7e303a42efb --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC677/IERC677.sol @@ -0,0 +1,13 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +interface IERC677 { + event Transfer(address indexed from, address indexed to, uint256 value, bytes data); + + /// @notice Transfer tokens from `msg.sender` to another address and then call `onTransferReceived` on receiver + /// @param to The address which you want to transfer to + /// @param amount The amount of tokens to be transferred + /// @param data bytes Additional data with no specified format, sent in call to `to` + /// @return true unless throwing + function transferAndCall(address to, uint256 amount, bytes memory data) external returns (bool); +} diff --git a/contracts/src/v0.8/shared/token/ERC677/IERC677Receiver.sol b/contracts/src/v0.8/shared/token/ERC677/IERC677Receiver.sol new file mode 100644 index 00000000000..2e44d860a82 --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC677/IERC677Receiver.sol @@ -0,0 +1,6 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +interface IERC677Receiver { + function onTokenTransfer(address sender, uint256 amount, bytes calldata data) external; +} diff --git a/contracts/src/v0.8/shared/token/ERC677/LinkToken.sol b/contracts/src/v0.8/shared/token/ERC677/LinkToken.sol new file mode 100644 index 00000000000..b4640a8e311 --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC677/LinkToken.sol @@ -0,0 +1,8 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {BurnMintERC677} from "./BurnMintERC677.sol"; + +contract LinkToken is BurnMintERC677 { + constructor() BurnMintERC677("ChainLink Token", "LINK", 18, 1e27) {} +} diff --git a/contracts/src/v0.8/shared/token/ERC677/OpStackBurnMintERC677.sol b/contracts/src/v0.8/shared/token/ERC677/OpStackBurnMintERC677.sol new file mode 100644 index 00000000000..714a4a11baf --- /dev/null +++ b/contracts/src/v0.8/shared/token/ERC677/OpStackBurnMintERC677.sol @@ -0,0 +1,49 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.0; + +import {IOptimismMintableERC20Minimal, IOptimismMintableERC20} from "../ERC20/IOptimismMintableERC20.sol"; + +import {BurnMintERC677} from "./BurnMintERC677.sol"; + +import {IERC165} from "../../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/introspection/IERC165.sol"; + +/// @notice A basic ERC677 compatible token contract with burn and minting roles that supports +/// the native L2 bridging requirements of the Optimism Stack. +/// @dev Note: the L2 bridge contract needs to be given burn and mint privileges manually, +/// since this contract does not automatically grant them. This allows the owner to revoke +/// the bridge's privileges if necessary. +contract OpStackBurnMintERC677 is BurnMintERC677, IOptimismMintableERC20Minimal { + /// @dev The address of the L1 token. + address internal immutable i_l1Token; + /// @dev The address of the L2 bridge. + address internal immutable i_l2Bridge; + + constructor( + string memory name, + string memory symbol, + uint8 decimals_, + uint256 maxSupply_, + address l1Token, + address l2Bridge + ) BurnMintERC677(name, symbol, decimals_, maxSupply_) { + i_l1Token = l1Token; + i_l2Bridge = l2Bridge; + } + + function supportsInterface(bytes4 interfaceId) public pure virtual override(IERC165, BurnMintERC677) returns (bool) { + return + interfaceId == type(IOptimismMintableERC20).interfaceId || + interfaceId == type(IOptimismMintableERC20Minimal).interfaceId || + super.supportsInterface(interfaceId); + } + + /// @notice Returns the address of the L1 token. + function remoteToken() public view override returns (address) { + return i_l1Token; + } + + /// @notice Returns the address of the L2 bridge. + function bridge() public view override returns (address) { + return i_l2Bridge; + } +} diff --git a/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Burnable.sol b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Burnable.sol new file mode 100644 index 00000000000..e7752729b42 --- /dev/null +++ b/contracts/src/v0.8/vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/extensions/ERC20Burnable.sol @@ -0,0 +1,39 @@ +// SPDX-License-Identifier: MIT +// OpenZeppelin Contracts (last updated v4.5.0) (token/ERC20/extensions/ERC20Burnable.sol) + +pragma solidity ^0.8.0; + +import "../ERC20.sol"; +import "../../../utils/Context.sol"; + +/** + * @dev Extension of {ERC20} that allows token holders to destroy both their own + * tokens and those that they have an allowance for, in a way that can be + * recognized off-chain (via event analysis). + */ +abstract contract ERC20Burnable is Context, ERC20 { + /** + * @dev Destroys `amount` tokens from the caller. + * + * See {ERC20-_burn}. + */ + function burn(uint256 amount) public virtual { + _burn(_msgSender(), amount); + } + + /** + * @dev Destroys `amount` tokens from `account`, deducting from the caller's + * allowance. + * + * See {ERC20-_burn} and {ERC20-allowance}. + * + * Requirements: + * + * - the caller must have allowance for ``accounts``'s tokens of at least + * `amount`. + */ + function burnFrom(address account, uint256 amount) public virtual { + _spendAllowance(account, _msgSender(), amount); + _burn(account, amount); + } +} \ No newline at end of file diff --git a/contracts/test/v0.7/KeeperRegistry1_1.test.ts b/contracts/test/v0.7/KeeperRegistry1_1.test.ts index 845832e76f7..4e3a8c91b35 100644 --- a/contracts/test/v0.7/KeeperRegistry1_1.test.ts +++ b/contracts/test/v0.7/KeeperRegistry1_1.test.ts @@ -2,7 +2,7 @@ import { ethers } from 'hardhat' import { assert, expect } from 'chai' import { evmRevert } from '../test-helpers/matchers' import { getUsers, Personas } from '../test-helpers/setup' -import { BigNumber, Signer, BigNumberish } from 'ethers' +import { BigNumber, BigNumberish, Signer } from 'ethers' import { LinkToken__factory as LinkTokenFactory } from '../../typechain/factories/LinkToken__factory' import { KeeperRegistry1_1__factory as KeeperRegistryFactory } from '../../typechain/factories/KeeperRegistry1_1__factory' import { MockV3Aggregator__factory as MockV3AggregatorFactory } from '../../typechain/factories/MockV3Aggregator__factory' @@ -37,7 +37,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) // need full path because there are two contracts with name MockV3Aggregator mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', diff --git a/contracts/test/v0.7/UpkeepRegistrationRequests.test.ts b/contracts/test/v0.7/UpkeepRegistrationRequests.test.ts index 906c86c6b44..5ec9306c668 100644 --- a/contracts/test/v0.7/UpkeepRegistrationRequests.test.ts +++ b/contracts/test/v0.7/UpkeepRegistrationRequests.test.ts @@ -25,7 +25,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.7/tests/MockV3Aggregator.sol:MockV3Aggregator', )) as unknown as MockV3AggregatorFactory diff --git a/contracts/test/v0.8/KeeperRegistrar.test.ts b/contracts/test/v0.8/KeeperRegistrar.test.ts index f4af3bdff31..9cef1d0204f 100644 --- a/contracts/test/v0.8/KeeperRegistrar.test.ts +++ b/contracts/test/v0.8/KeeperRegistrar.test.ts @@ -28,7 +28,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', )) as unknown as MockV3AggregatorFactory diff --git a/contracts/test/v0.8/VRFSubscriptionBalanceMonitor.test.ts b/contracts/test/v0.8/VRFSubscriptionBalanceMonitor.test.ts index ef022209821..c13d144776c 100644 --- a/contracts/test/v0.8/VRFSubscriptionBalanceMonitor.test.ts +++ b/contracts/test/v0.8/VRFSubscriptionBalanceMonitor.test.ts @@ -2,8 +2,8 @@ import { ethers } from 'hardhat' import { assert, expect } from 'chai' import type { SignerWithAddress } from '@nomiclabs/hardhat-ethers/signers' import { - VRFSubscriptionBalanceMonitorExposed, LinkToken, + VRFSubscriptionBalanceMonitorExposed, } from '../../typechain' import * as h from '../test-helpers/helpers' import { BigNumber, Contract } from 'ethers' @@ -65,7 +65,10 @@ describe('VRFSubscriptionBalanceMonitor', () => { 'VRFSubscriptionBalanceMonitorExposed', owner, ) - const ltFactory = await ethers.getContractFactory('LinkToken', owner) + const ltFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + owner, + ) const coordinatorFactory = await ethers.getContractFactory( 'src/v0.8/vrf/VRFCoordinatorV2.sol:VRFCoordinatorV2', diff --git a/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts b/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts index cb74ee61b52..323050def56 100644 --- a/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts +++ b/contracts/test/v0.8/automation/AutomationRegistrar2_1.test.ts @@ -29,7 +29,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', )) as unknown as MockV3AggregatorFactory diff --git a/contracts/test/v0.8/automation/ERC20BalanceMonitor.test.ts b/contracts/test/v0.8/automation/ERC20BalanceMonitor.test.ts index 95e72cb0ca4..afab7af5107 100644 --- a/contracts/test/v0.8/automation/ERC20BalanceMonitor.test.ts +++ b/contracts/test/v0.8/automation/ERC20BalanceMonitor.test.ts @@ -66,7 +66,10 @@ describe('ERC20BalanceMonitor', () => { 'ERC20BalanceMonitorExposed', owner, ) - const ltFactory = await ethers.getContractFactory('LinkToken', owner) + const ltFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + owner, + ) const reFactory = await ethers.getContractFactory('ReceiveEmitter', owner) const rfeFactory = await ethers.getContractFactory( 'ReceiveFallbackEmitter', diff --git a/contracts/test/v0.8/automation/KeeperRegistrar2_0.test.ts b/contracts/test/v0.8/automation/KeeperRegistrar2_0.test.ts index 6fdc0668f93..14a5c7eba2d 100644 --- a/contracts/test/v0.8/automation/KeeperRegistrar2_0.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistrar2_0.test.ts @@ -31,7 +31,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', )) as unknown as MockV3AggregatorFactory diff --git a/contracts/test/v0.8/automation/KeeperRegistry1_2.test.ts b/contracts/test/v0.8/automation/KeeperRegistry1_2.test.ts index cc8ee3a8d08..ba026fa18d9 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry1_2.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry1_2.test.ts @@ -67,7 +67,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) // need full path because there are two contracts with name MockV3Aggregator mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', diff --git a/contracts/test/v0.8/automation/KeeperRegistry1_3.test.ts b/contracts/test/v0.8/automation/KeeperRegistry1_3.test.ts index c58fb4d7655..eee4344b461 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry1_3.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry1_3.test.ts @@ -76,7 +76,9 @@ let personas: Personas before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) // need full path because there are two contracts with name MockV3Aggregator mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_0.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_0.test.ts index 7a9779b1e88..9886e84854b 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_0.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_0.test.ts @@ -252,7 +252,9 @@ const parseCancelledUpkeepReportLogs = (receipt: any) => { before(async () => { personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) // need full path because there are two contracts with name MockV3Aggregator mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', diff --git a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts index f51ce4133b4..8ddc2f450e6 100644 --- a/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts +++ b/contracts/test/v0.8/automation/KeeperRegistry2_1.test.ts @@ -4,15 +4,15 @@ import { assert, expect } from 'chai' import { BigNumber, BigNumberish, - Signer, - Wallet, - ContractTransaction, BytesLike, ContractReceipt, + ContractTransaction, + Signer, + Wallet, } from 'ethers' import { evmRevert } from '../../test-helpers/matchers' import { getUsers, Personas } from '../../test-helpers/setup' -import { toWei, randomAddress } from '../../test-helpers/helpers' +import { randomAddress, toWei } from '../../test-helpers/helpers' import { LinkToken__factory as LinkTokenFactory } from '../../../typechain/factories/LinkToken__factory' import { MercuryUpkeep__factory as MercuryUpkeepFactory } from '../../../typechain/factories/MercuryUpkeep__factory' import { MockV3Aggregator__factory as MockV3AggregatorFactory } from '../../../typechain/factories/MockV3Aggregator__factory' @@ -33,12 +33,12 @@ import { MockOVMGasPriceOracle } from '../../../typechain/MockOVMGasPriceOracle' import { UpkeepTranscoder } from '../../../typechain/UpkeepTranscoder' import { UpkeepAutoFunder } from '../../../typechain' import { + CancelledUpkeepReportEvent, IKeeperRegistryMaster as IKeeperRegistry, - UpkeepPerformedEvent, + InsufficientFundsUpkeepReportEvent, ReorgedUpkeepReportEvent, StaleUpkeepReportEvent, - InsufficientFundsUpkeepReportEvent, - CancelledUpkeepReportEvent, + UpkeepPerformedEvent, } from '../../../typechain/IKeeperRegistryMaster' import { deployMockContract, @@ -427,7 +427,9 @@ describe('KeeperRegistry2_1', () => { const utilsFactory = await ethers.getContractFactory('AutomationUtils2_1') automationUtils = await utilsFactory.deploy() - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) // need full path because there are two contracts with name MockV3Aggregator mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', diff --git a/contracts/test/v0.8/automation/LinkAvailableBalanceMonitor.test.ts b/contracts/test/v0.8/automation/LinkAvailableBalanceMonitor.test.ts index d77401a009a..4efd98039f5 100644 --- a/contracts/test/v0.8/automation/LinkAvailableBalanceMonitor.test.ts +++ b/contracts/test/v0.8/automation/LinkAvailableBalanceMonitor.test.ts @@ -3,16 +3,17 @@ import chai, { assert, expect } from 'chai' import type { SignerWithAddress } from '@nomiclabs/hardhat-ethers/signers' import { loadFixture } from '@nomicfoundation/hardhat-network-helpers' import * as h from '../../test-helpers/helpers' +import { mineBlock } from '../../test-helpers/helpers' import { IAggregatorProxy__factory as IAggregatorProxyFactory } from '../../../typechain/factories/IAggregatorProxy__factory' import { ILinkAvailable__factory as ILinkAvailableFactory } from '../../../typechain/factories/ILinkAvailable__factory' import { LinkAvailableBalanceMonitor, LinkToken } from '../../../typechain' import { BigNumber } from 'ethers' -import { mineBlock } from '../../test-helpers/helpers' import deepEqualInAnyOrder from 'deep-equal-in-any-order' import { deployMockContract, MockContract, } from '@ethereum-waffle/mock-contract' + chai.use(deepEqualInAnyOrder) //////////////////////////////// GAS USAGE LIMITS - CHANGE WITH CAUTION ////////////////////////// @@ -136,7 +137,10 @@ const setup = async () => { 'LinkAvailableBalanceMonitor', owner, ) - const ltFactory = await ethers.getContractFactory('LinkToken', owner) + const ltFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + owner, + ) lt = await ltFactory.deploy() labm = await labmFactory.deploy(lt.address, twoLINK) diff --git a/contracts/test/v0.8/automation/UpkeepTranscoder3_0.test.ts b/contracts/test/v0.8/automation/UpkeepTranscoder3_0.test.ts index 93ae2a44ea9..8bad7f63873 100644 --- a/contracts/test/v0.8/automation/UpkeepTranscoder3_0.test.ts +++ b/contracts/test/v0.8/automation/UpkeepTranscoder3_0.test.ts @@ -127,7 +127,9 @@ before(async () => { ) personas = (await getUsers()).personas - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) // need full path because there are two contracts with name MockV3Aggregator mockV3AggregatorFactory = (await ethers.getContractFactory( 'src/v0.8/tests/MockV3Aggregator.sol:MockV3Aggregator', diff --git a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts index e2903ee447a..7c7715fd599 100644 --- a/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts +++ b/contracts/test/v0.8/automation/UpkeepTranscoder4_0.test.ts @@ -13,15 +13,14 @@ import { KeeperRegistryLogic1_3__factory as KeeperRegistryLogicFactory } from '. import { toWei } from '../../test-helpers/helpers' import { loadFixture } from '@nomicfoundation/hardhat-network-helpers' import { - LinkToken, - MockV3Aggregator, + IKeeperRegistryMaster, KeeperRegistry1_2, KeeperRegistry1_3, KeeperRegistry2_0, - IKeeperRegistryMaster, + LinkToken, + MockV3Aggregator, UpkeepMock, } from '../../../typechain' -import {} from '../../../typechain' import { deployRegistry21 } from './helpers' let transcoder: UpkeepTranscoder @@ -310,7 +309,9 @@ const setup = async () => { ) transcoder = await upkeepTranscoderFactory.connect(owner).deploy() - linkTokenFactory = await ethers.getContractFactory('LinkToken') + linkTokenFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + ) linkToken = await linkTokenFactory.connect(owner).deploy() // need full path because there are two contracts with name MockV3Aggregator const mockV3AggregatorFactory = (await ethers.getContractFactory( diff --git a/contracts/test/v0.8/dev/VRFV2Wrapper.test.ts b/contracts/test/v0.8/dev/VRFV2Wrapper.test.ts index a8ff77175f7..fc888fc9738 100644 --- a/contracts/test/v0.8/dev/VRFV2Wrapper.test.ts +++ b/contracts/test/v0.8/dev/VRFV2Wrapper.test.ts @@ -1,7 +1,7 @@ -import { expect, assert } from 'chai' +import { assert, expect } from 'chai' import { BigNumber, BigNumberish, Signer } from 'ethers' import { ethers } from 'hardhat' -import { toBytes32String, reset } from '../../test-helpers/helpers' +import { reset, toBytes32String } from '../../test-helpers/helpers' import { bigNumEquals } from '../../test-helpers/matchers' import { describe } from 'mocha' import { @@ -11,8 +11,8 @@ import { VRFCoordinatorV2Mock, VRFV2Wrapper, VRFV2WrapperConsumerExample, - VRFV2WrapperRevertingConsumerExample, VRFV2WrapperOutOfGasConsumerExample, + VRFV2WrapperRevertingConsumerExample, } from '../../../typechain' describe('VRFV2Wrapper', () => { @@ -100,7 +100,10 @@ describe('VRFV2Wrapper', () => { )) as unknown as MockV3Aggregator__factory linkEthFeed = await linkEthFeedFactory.deploy(18, weiPerUnitLink) // 1 LINK = 0.003 ETH - const linkFactory = await ethers.getContractFactory('LinkToken', owner) + const linkFactory = await ethers.getContractFactory( + 'src/v0.4/LinkToken.sol:LinkToken', + owner, + ) link = await linkFactory.deploy() wrongLink = await linkFactory.deploy() diff --git a/core/gethwrappers/shared/generated/burn_mint_erc677/burn_mint_erc677.go b/core/gethwrappers/shared/generated/burn_mint_erc677/burn_mint_erc677.go new file mode 100644 index 00000000000..f138b3b1f00 --- /dev/null +++ b/core/gethwrappers/shared/generated/burn_mint_erc677/burn_mint_erc677.go @@ -0,0 +1,2068 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package burn_mint_erc677 + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var BurnMintERC677MetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"symbol\",\"type\":\"string\"},{\"internalType\":\"uint8\",\"name\":\"decimals_\",\"type\":\"uint8\"},{\"internalType\":\"uint256\",\"name\":\"maxSupply_\",\"type\":\"uint256\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"supplyAfterMint\",\"type\":\"uint256\"}],\"name\":\"MaxSupplyExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderNotBurner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderNotMinter\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"BurnAccessGranted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"BurnAccessRevoked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"MintAccessGranted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"MintAccessRevoked\",\"type\":\"event\"},{\"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\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burnFrom\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseApproval\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBurners\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMinters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"grantBurnRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burnAndMinter\",\"type\":\"address\"}],\"name\":\"grantMintAndBurnRoles\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"grantMintRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseApproval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"isBurner\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"isMinter\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"maxSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"revokeBurnRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"revokeMintRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"transferAndCall\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b50604051620022dd380380620022dd833981016040819052620000349162000277565b338060008686818160036200004a838262000391565b50600462000059828262000391565b5050506001600160a01b0384169150620000bc90505760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600580546001600160a01b0319166001600160a01b0384811691909117909155811615620000ef57620000ef8162000106565b50505060ff90911660805260a052506200045d9050565b336001600160a01b03821603620001605760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000b3565b600680546001600160a01b0319166001600160a01b03838116918217909255600554604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b634e487b7160e01b600052604160045260246000fd5b600082601f830112620001da57600080fd5b81516001600160401b0380821115620001f757620001f7620001b2565b604051601f8301601f19908116603f01168101908282118183101715620002225762000222620001b2565b816040528381526020925086838588010111156200023f57600080fd5b600091505b8382101562000263578582018301518183018401529082019062000244565b600093810190920192909252949350505050565b600080600080608085870312156200028e57600080fd5b84516001600160401b0380821115620002a657600080fd5b620002b488838901620001c8565b95506020870151915080821115620002cb57600080fd5b50620002da87828801620001c8565b935050604085015160ff81168114620002f257600080fd5b6060959095015193969295505050565b600181811c908216806200031757607f821691505b6020821081036200033857634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200038c57600081815260208120601f850160051c81016020861015620003675750805b601f850160051c820191505b81811015620003885782815560010162000373565b5050505b505050565b81516001600160401b03811115620003ad57620003ad620001b2565b620003c581620003be845462000302565b846200033e565b602080601f831160018114620003fd5760008415620003e45750858301515b600019600386901b1c1916600185901b17855562000388565b600085815260208120601f198616915b828110156200042e578886015182559484019460019091019084016200040d565b50858210156200044d5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a051611e4c6200049160003960008181610447015281816108c301526108ed015260006102710152611e4c6000f3fe608060405234801561001057600080fd5b50600436106101f05760003560e01c806379cc67901161010f578063c2e3273d116100a2578063d73dd62311610071578063d73dd6231461046b578063dd62ed3e1461047e578063f2fde38b146104c4578063f81094f3146104d757600080fd5b8063c2e3273d1461040c578063c630948d1461041f578063c64d0ebc14610432578063d5abeb011461044557600080fd5b80639dc29fac116100de5780639dc29fac146103c0578063a457c2d7146103d3578063a9059cbb146103e6578063aa271e1a146103f957600080fd5b806379cc67901461037557806386fe8b43146103885780638da5cb5b1461039057806395d89b41146103b857600080fd5b806340c10f19116101875780636618846311610156578063661884631461030f5780636b32810b1461032257806370a082311461033757806379ba50971461036d57600080fd5b806340c10f19146102c157806342966c68146102d65780634334614a146102e95780634f5632f8146102fc57600080fd5b806323b872dd116101c357806323b872dd14610257578063313ce5671461026a578063395093511461029b5780634000aea0146102ae57600080fd5b806301ffc9a7146101f557806306fdde031461021d578063095ea7b31461023257806318160ddd14610245575b600080fd5b6102086102033660046119b9565b6104ea565b60405190151581526020015b60405180910390f35b61022561061b565b6040516102149190611a5f565b610208610240366004611a9b565b6106ad565b6002545b604051908152602001610214565b610208610265366004611ac5565b6106c5565b60405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610214565b6102086102a9366004611a9b565b6106e9565b6102086102bc366004611b30565b610735565b6102d46102cf366004611a9b565b610858565b005b6102d46102e4366004611c19565b61097f565b6102086102f7366004611c32565b6109cc565b6102d461030a366004611c32565b6109d9565b61020861031d366004611a9b565b610a35565b61032a610a48565b6040516102149190611c4d565b610249610345366004611c32565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6102d4610a59565b6102d4610383366004611a9b565b610b5a565b61032a610ba9565b60055460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610214565b610225610bb5565b6102d46103ce366004611a9b565b610bc4565b6102086103e1366004611a9b565b610bce565b6102086103f4366004611a9b565b610c9f565b610208610407366004611c32565b610cad565b6102d461041a366004611c32565b610cba565b6102d461042d366004611c32565b610d16565b6102d4610440366004611c32565b610d24565b7f0000000000000000000000000000000000000000000000000000000000000000610249565b6102d4610479366004611a9b565b610d80565b61024961048c366004611ca7565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6102d46104d2366004611c32565b610d8a565b6102d46104e5366004611c32565b610d9b565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f36372b0700000000000000000000000000000000000000000000000000000000148061057d57507fffffffff0000000000000000000000000000000000000000000000000000000082167f4000aea000000000000000000000000000000000000000000000000000000000145b806105c957507fffffffff0000000000000000000000000000000000000000000000000000000082167fe6599b4d00000000000000000000000000000000000000000000000000000000145b8061061557507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b60606003805461062a90611cda565b80601f016020809104026020016040519081016040528092919081815260200182805461065690611cda565b80156106a35780601f10610678576101008083540402835291602001916106a3565b820191906000526020600020905b81548152906001019060200180831161068657829003601f168201915b5050505050905090565b6000336106bb818585610df7565b5060019392505050565b6000336106d3858285610e2b565b6106de858585610efc565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906106bb9082908690610730908790611d5c565b610df7565b60006107418484610c9f565b508373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c1685856040516107a1929190611d6f565b60405180910390a373ffffffffffffffffffffffffffffffffffffffff84163b156106bb576040517fa4c0ed3600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063a4c0ed369061081c90339087908790600401611d90565b600060405180830381600087803b15801561083657600080fd5b505af115801561084a573d6000803e3d6000fd5b505050505060019392505050565b61086133610cad565b61089e576040517fe2c8c9d50000000000000000000000000000000000000000000000000000000081523360048201526024015b60405180910390fd5b813073ffffffffffffffffffffffffffffffffffffffff8216036108c157600080fd5b7f00000000000000000000000000000000000000000000000000000000000000001580159061092257507f00000000000000000000000000000000000000000000000000000000000000008261091660025490565b6109209190611d5c565b115b15610970578161093160025490565b61093b9190611d5c565b6040517fcbbf111300000000000000000000000000000000000000000000000000000000815260040161089591815260200190565b61097a8383610f2a565b505050565b610988336109cc565b6109c0576040517fc820b10b000000000000000000000000000000000000000000000000000000008152336004820152602401610895565b6109c98161101d565b50565b6000610615600983611027565b6109e1611056565b6109ec6009826110d9565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907f0a675452746933cefe3d74182e78db7afe57ba60eaa4234b5d85e9aa41b0610c90600090a250565b6000610a418383610bce565b9392505050565b6060610a5460076110fb565b905090565b60065473ffffffffffffffffffffffffffffffffffffffff163314610ada576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610895565b600580547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560068054909116905560405173ffffffffffffffffffffffffffffffffffffffff909116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b610b63336109cc565b610b9b576040517fc820b10b000000000000000000000000000000000000000000000000000000008152336004820152602401610895565b610ba58282611108565b5050565b6060610a5460096110fb565b60606004805461062a90611cda565b610ba58282610b5a565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919083811015610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f0000000000000000000000000000000000000000000000000000006064820152608401610895565b6106de8286868403610df7565b6000336106bb818585610efc565b6000610615600783611027565b610cc2611056565b610ccd60078261111d565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907fe46fef8bbff1389d9010703cf8ebb363fb3daf5bf56edc27080b67bc8d9251ea90600090a250565b610d1f81610cba565b6109c9815b610d2c611056565b610d3760098261111d565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907f92308bb7573b2a3d17ddb868b39d8ebec433f3194421abc22d084f89658c9bad90600090a250565b61097a82826106e9565b610d92611056565b6109c98161113f565b610da3611056565b610dae6007826110d9565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907fed998b960f6340d045f620c119730f7aa7995e7425c2401d3a5b64ff998a59e990600090a250565b813073ffffffffffffffffffffffffffffffffffffffff821603610e1a57600080fd5b610e25848484611235565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610e255781811015610eef576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610895565b610e258484848403610df7565b813073ffffffffffffffffffffffffffffffffffffffff821603610f1f57600080fd5b610e258484846113e8565b73ffffffffffffffffffffffffffffffffffffffff8216610fa7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610895565b8060026000828254610fb99190611d5c565b909155505073ffffffffffffffffffffffffffffffffffffffff8216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b6109c93382611657565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001830160205260408120541515610a41565b60055473ffffffffffffffffffffffffffffffffffffffff1633146110d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610895565b565b6000610a418373ffffffffffffffffffffffffffffffffffffffff841661181b565b60606000610a418361190e565b611113823383610e2b565b610ba58282611657565b6000610a418373ffffffffffffffffffffffffffffffffffffffff841661196a565b3373ffffffffffffffffffffffffffffffffffffffff8216036111be576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610895565b600680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600554604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b73ffffffffffffffffffffffffffffffffffffffff83166112d7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff821661137a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f73730000000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff831661148b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f64726573730000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff821661152e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f65737300000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260208190526040902054818110156115e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e636500000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610e25565b73ffffffffffffffffffffffffffffffffffffffff82166116fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f73000000000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260208190526040902054818110156117b0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f63650000000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff83166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3505050565b6000818152600183016020526040812054801561190457600061183f600183611dce565b855490915060009061185390600190611dce565b90508181146118b857600086600001828154811061187357611873611de1565b906000526020600020015490508087600001848154811061189657611896611de1565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806118c9576118c9611e10565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610615565b6000915050610615565b60608160000180548060200260200160405190810160405280929190818152602001828054801561195e57602002820191906000526020600020905b81548152602001906001019080831161194a575b50505050509050919050565b60008181526001830160205260408120546119b157508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610615565b506000610615565b6000602082840312156119cb57600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610a4157600080fd5b6000815180845260005b81811015611a2157602081850181015186830182015201611a05565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000610a4160208301846119fb565b803573ffffffffffffffffffffffffffffffffffffffff81168114611a9657600080fd5b919050565b60008060408385031215611aae57600080fd5b611ab783611a72565b946020939093013593505050565b600080600060608486031215611ada57600080fd5b611ae384611a72565b9250611af160208501611a72565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080600060608486031215611b4557600080fd5b611b4e84611a72565b925060208401359150604084013567ffffffffffffffff80821115611b7257600080fd5b818601915086601f830112611b8657600080fd5b813581811115611b9857611b98611b01565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715611bde57611bde611b01565b81604052828152896020848701011115611bf757600080fd5b8260208601602083013760006020848301015280955050505050509250925092565b600060208284031215611c2b57600080fd5b5035919050565b600060208284031215611c4457600080fd5b610a4182611a72565b6020808252825182820181905260009190848201906040850190845b81811015611c9b57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101611c69565b50909695505050505050565b60008060408385031215611cba57600080fd5b611cc383611a72565b9150611cd160208401611a72565b90509250929050565b600181811c90821680611cee57607f821691505b602082108103611d27577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561061557610615611d2d565b828152604060208201526000611d8860408301846119fb565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff84168152826020820152606060408201526000611dc560608301846119fb565b95945050505050565b8181038181111561061557610615611d2d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000813000a", +} + +var BurnMintERC677ABI = BurnMintERC677MetaData.ABI + +var BurnMintERC677Bin = BurnMintERC677MetaData.Bin + +func DeployBurnMintERC677(auth *bind.TransactOpts, backend bind.ContractBackend, name string, symbol string, decimals_ uint8, maxSupply_ *big.Int) (common.Address, *types.Transaction, *BurnMintERC677, error) { + parsed, err := BurnMintERC677MetaData.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(BurnMintERC677Bin), backend, name, symbol, decimals_, maxSupply_) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &BurnMintERC677{BurnMintERC677Caller: BurnMintERC677Caller{contract: contract}, BurnMintERC677Transactor: BurnMintERC677Transactor{contract: contract}, BurnMintERC677Filterer: BurnMintERC677Filterer{contract: contract}}, nil +} + +type BurnMintERC677 struct { + address common.Address + abi abi.ABI + BurnMintERC677Caller + BurnMintERC677Transactor + BurnMintERC677Filterer +} + +type BurnMintERC677Caller struct { + contract *bind.BoundContract +} + +type BurnMintERC677Transactor struct { + contract *bind.BoundContract +} + +type BurnMintERC677Filterer struct { + contract *bind.BoundContract +} + +type BurnMintERC677Session struct { + Contract *BurnMintERC677 + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type BurnMintERC677CallerSession struct { + Contract *BurnMintERC677Caller + CallOpts bind.CallOpts +} + +type BurnMintERC677TransactorSession struct { + Contract *BurnMintERC677Transactor + TransactOpts bind.TransactOpts +} + +type BurnMintERC677Raw struct { + Contract *BurnMintERC677 +} + +type BurnMintERC677CallerRaw struct { + Contract *BurnMintERC677Caller +} + +type BurnMintERC677TransactorRaw struct { + Contract *BurnMintERC677Transactor +} + +func NewBurnMintERC677(address common.Address, backend bind.ContractBackend) (*BurnMintERC677, error) { + abi, err := abi.JSON(strings.NewReader(BurnMintERC677ABI)) + if err != nil { + return nil, err + } + contract, err := bindBurnMintERC677(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &BurnMintERC677{address: address, abi: abi, BurnMintERC677Caller: BurnMintERC677Caller{contract: contract}, BurnMintERC677Transactor: BurnMintERC677Transactor{contract: contract}, BurnMintERC677Filterer: BurnMintERC677Filterer{contract: contract}}, nil +} + +func NewBurnMintERC677Caller(address common.Address, caller bind.ContractCaller) (*BurnMintERC677Caller, error) { + contract, err := bindBurnMintERC677(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &BurnMintERC677Caller{contract: contract}, nil +} + +func NewBurnMintERC677Transactor(address common.Address, transactor bind.ContractTransactor) (*BurnMintERC677Transactor, error) { + contract, err := bindBurnMintERC677(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &BurnMintERC677Transactor{contract: contract}, nil +} + +func NewBurnMintERC677Filterer(address common.Address, filterer bind.ContractFilterer) (*BurnMintERC677Filterer, error) { + contract, err := bindBurnMintERC677(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &BurnMintERC677Filterer{contract: contract}, nil +} + +func bindBurnMintERC677(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := BurnMintERC677MetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_BurnMintERC677 *BurnMintERC677Raw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _BurnMintERC677.Contract.BurnMintERC677Caller.contract.Call(opts, result, method, params...) +} + +func (_BurnMintERC677 *BurnMintERC677Raw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _BurnMintERC677.Contract.BurnMintERC677Transactor.contract.Transfer(opts) +} + +func (_BurnMintERC677 *BurnMintERC677Raw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _BurnMintERC677.Contract.BurnMintERC677Transactor.contract.Transact(opts, method, params...) +} + +func (_BurnMintERC677 *BurnMintERC677CallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _BurnMintERC677.Contract.contract.Call(opts, result, method, params...) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _BurnMintERC677.Contract.contract.Transfer(opts) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _BurnMintERC677.Contract.contract.Transact(opts, method, params...) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "allowance", owner, spender) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { + return _BurnMintERC677.Contract.Allowance(&_BurnMintERC677.CallOpts, owner, spender) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { + return _BurnMintERC677.Contract.Allowance(&_BurnMintERC677.CallOpts, owner, spender) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "balanceOf", account) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) BalanceOf(account common.Address) (*big.Int, error) { + return _BurnMintERC677.Contract.BalanceOf(&_BurnMintERC677.CallOpts, account) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) BalanceOf(account common.Address) (*big.Int, error) { + return _BurnMintERC677.Contract.BalanceOf(&_BurnMintERC677.CallOpts, account) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) Decimals(opts *bind.CallOpts) (uint8, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "decimals") + + if err != nil { + return *new(uint8), err + } + + out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) Decimals() (uint8, error) { + return _BurnMintERC677.Contract.Decimals(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) Decimals() (uint8, error) { + return _BurnMintERC677.Contract.Decimals(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) GetBurners(opts *bind.CallOpts) ([]common.Address, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "getBurners") + + if err != nil { + return *new([]common.Address), err + } + + out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) GetBurners() ([]common.Address, error) { + return _BurnMintERC677.Contract.GetBurners(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) GetBurners() ([]common.Address, error) { + return _BurnMintERC677.Contract.GetBurners(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) GetMinters(opts *bind.CallOpts) ([]common.Address, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "getMinters") + + if err != nil { + return *new([]common.Address), err + } + + out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) GetMinters() ([]common.Address, error) { + return _BurnMintERC677.Contract.GetMinters(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) GetMinters() ([]common.Address, error) { + return _BurnMintERC677.Contract.GetMinters(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) IsBurner(opts *bind.CallOpts, burner common.Address) (bool, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "isBurner", burner) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) IsBurner(burner common.Address) (bool, error) { + return _BurnMintERC677.Contract.IsBurner(&_BurnMintERC677.CallOpts, burner) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) IsBurner(burner common.Address) (bool, error) { + return _BurnMintERC677.Contract.IsBurner(&_BurnMintERC677.CallOpts, burner) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) IsMinter(opts *bind.CallOpts, minter common.Address) (bool, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "isMinter", minter) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) IsMinter(minter common.Address) (bool, error) { + return _BurnMintERC677.Contract.IsMinter(&_BurnMintERC677.CallOpts, minter) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) IsMinter(minter common.Address) (bool, error) { + return _BurnMintERC677.Contract.IsMinter(&_BurnMintERC677.CallOpts, minter) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) MaxSupply(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "maxSupply") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) MaxSupply() (*big.Int, error) { + return _BurnMintERC677.Contract.MaxSupply(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) MaxSupply() (*big.Int, error) { + return _BurnMintERC677.Contract.MaxSupply(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) Name(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "name") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) Name() (string, error) { + return _BurnMintERC677.Contract.Name(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) Name() (string, error) { + return _BurnMintERC677.Contract.Name(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _BurnMintERC677.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 (_BurnMintERC677 *BurnMintERC677Session) Owner() (common.Address, error) { + return _BurnMintERC677.Contract.Owner(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) Owner() (common.Address, error) { + return _BurnMintERC677.Contract.Owner(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _BurnMintERC677.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 (_BurnMintERC677 *BurnMintERC677Session) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _BurnMintERC677.Contract.SupportsInterface(&_BurnMintERC677.CallOpts, interfaceId) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _BurnMintERC677.Contract.SupportsInterface(&_BurnMintERC677.CallOpts, interfaceId) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) Symbol(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "symbol") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) Symbol() (string, error) { + return _BurnMintERC677.Contract.Symbol(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) Symbol() (string, error) { + return _BurnMintERC677.Contract.Symbol(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Caller) TotalSupply(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _BurnMintERC677.contract.Call(opts, &out, "totalSupply") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_BurnMintERC677 *BurnMintERC677Session) TotalSupply() (*big.Int, error) { + return _BurnMintERC677.Contract.TotalSupply(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677CallerSession) TotalSupply() (*big.Int, error) { + return _BurnMintERC677.Contract.TotalSupply(&_BurnMintERC677.CallOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "acceptOwnership") +} + +func (_BurnMintERC677 *BurnMintERC677Session) AcceptOwnership() (*types.Transaction, error) { + return _BurnMintERC677.Contract.AcceptOwnership(&_BurnMintERC677.TransactOpts) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _BurnMintERC677.Contract.AcceptOwnership(&_BurnMintERC677.TransactOpts) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "approve", spender, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Approve(&_BurnMintERC677.TransactOpts, spender, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Approve(&_BurnMintERC677.TransactOpts, spender, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) Burn(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "burn", amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) Burn(amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Burn(&_BurnMintERC677.TransactOpts, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) Burn(amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Burn(&_BurnMintERC677.TransactOpts, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) Burn0(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "burn0", account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) Burn0(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Burn0(&_BurnMintERC677.TransactOpts, account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) Burn0(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Burn0(&_BurnMintERC677.TransactOpts, account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) BurnFrom(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "burnFrom", account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) BurnFrom(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.BurnFrom(&_BurnMintERC677.TransactOpts, account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) BurnFrom(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.BurnFrom(&_BurnMintERC677.TransactOpts, account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "decreaseAllowance", spender, subtractedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Session) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.DecreaseAllowance(&_BurnMintERC677.TransactOpts, spender, subtractedValue) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.DecreaseAllowance(&_BurnMintERC677.TransactOpts, spender, subtractedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) DecreaseApproval(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "decreaseApproval", spender, subtractedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Session) DecreaseApproval(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.DecreaseApproval(&_BurnMintERC677.TransactOpts, spender, subtractedValue) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) DecreaseApproval(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.DecreaseApproval(&_BurnMintERC677.TransactOpts, spender, subtractedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) GrantBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "grantBurnRole", burner) +} + +func (_BurnMintERC677 *BurnMintERC677Session) GrantBurnRole(burner common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.GrantBurnRole(&_BurnMintERC677.TransactOpts, burner) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) GrantBurnRole(burner common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.GrantBurnRole(&_BurnMintERC677.TransactOpts, burner) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) GrantMintAndBurnRoles(opts *bind.TransactOpts, burnAndMinter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "grantMintAndBurnRoles", burnAndMinter) +} + +func (_BurnMintERC677 *BurnMintERC677Session) GrantMintAndBurnRoles(burnAndMinter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.GrantMintAndBurnRoles(&_BurnMintERC677.TransactOpts, burnAndMinter) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) GrantMintAndBurnRoles(burnAndMinter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.GrantMintAndBurnRoles(&_BurnMintERC677.TransactOpts, burnAndMinter) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) GrantMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "grantMintRole", minter) +} + +func (_BurnMintERC677 *BurnMintERC677Session) GrantMintRole(minter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.GrantMintRole(&_BurnMintERC677.TransactOpts, minter) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) GrantMintRole(minter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.GrantMintRole(&_BurnMintERC677.TransactOpts, minter) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "increaseAllowance", spender, addedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Session) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.IncreaseAllowance(&_BurnMintERC677.TransactOpts, spender, addedValue) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.IncreaseAllowance(&_BurnMintERC677.TransactOpts, spender, addedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) IncreaseApproval(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "increaseApproval", spender, addedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Session) IncreaseApproval(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.IncreaseApproval(&_BurnMintERC677.TransactOpts, spender, addedValue) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) IncreaseApproval(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.IncreaseApproval(&_BurnMintERC677.TransactOpts, spender, addedValue) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) Mint(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "mint", account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) Mint(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Mint(&_BurnMintERC677.TransactOpts, account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) Mint(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Mint(&_BurnMintERC677.TransactOpts, account, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) RevokeBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "revokeBurnRole", burner) +} + +func (_BurnMintERC677 *BurnMintERC677Session) RevokeBurnRole(burner common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.RevokeBurnRole(&_BurnMintERC677.TransactOpts, burner) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) RevokeBurnRole(burner common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.RevokeBurnRole(&_BurnMintERC677.TransactOpts, burner) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) RevokeMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "revokeMintRole", minter) +} + +func (_BurnMintERC677 *BurnMintERC677Session) RevokeMintRole(minter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.RevokeMintRole(&_BurnMintERC677.TransactOpts, minter) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) RevokeMintRole(minter common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.RevokeMintRole(&_BurnMintERC677.TransactOpts, minter) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) Transfer(opts *bind.TransactOpts, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "transfer", to, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) Transfer(to common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Transfer(&_BurnMintERC677.TransactOpts, to, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) Transfer(to common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.Transfer(&_BurnMintERC677.TransactOpts, to, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) TransferAndCall(opts *bind.TransactOpts, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "transferAndCall", to, amount, data) +} + +func (_BurnMintERC677 *BurnMintERC677Session) TransferAndCall(to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _BurnMintERC677.Contract.TransferAndCall(&_BurnMintERC677.TransactOpts, to, amount, data) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) TransferAndCall(to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _BurnMintERC677.Contract.TransferAndCall(&_BurnMintERC677.TransactOpts, to, amount, data) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "transferFrom", from, to, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Session) TransferFrom(from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.TransferFrom(&_BurnMintERC677.TransactOpts, from, to, amount) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) TransferFrom(from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _BurnMintERC677.Contract.TransferFrom(&_BurnMintERC677.TransactOpts, from, to, amount) +} + +func (_BurnMintERC677 *BurnMintERC677Transactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _BurnMintERC677.contract.Transact(opts, "transferOwnership", to) +} + +func (_BurnMintERC677 *BurnMintERC677Session) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.TransferOwnership(&_BurnMintERC677.TransactOpts, to) +} + +func (_BurnMintERC677 *BurnMintERC677TransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _BurnMintERC677.Contract.TransferOwnership(&_BurnMintERC677.TransactOpts, to) +} + +type BurnMintERC677ApprovalIterator struct { + Event *BurnMintERC677Approval + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677ApprovalIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677Approval) + 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(BurnMintERC677Approval) + 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 *BurnMintERC677ApprovalIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677ApprovalIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677Approval struct { + Owner common.Address + Spender common.Address + Value *big.Int + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*BurnMintERC677ApprovalIterator, error) { + + var ownerRule []interface{} + for _, ownerItem := range owner { + ownerRule = append(ownerRule, ownerItem) + } + var spenderRule []interface{} + for _, spenderItem := range spender { + spenderRule = append(spenderRule, spenderItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "Approval", ownerRule, spenderRule) + if err != nil { + return nil, err + } + return &BurnMintERC677ApprovalIterator{contract: _BurnMintERC677.contract, event: "Approval", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchApproval(opts *bind.WatchOpts, sink chan<- *BurnMintERC677Approval, owner []common.Address, spender []common.Address) (event.Subscription, error) { + + var ownerRule []interface{} + for _, ownerItem := range owner { + ownerRule = append(ownerRule, ownerItem) + } + var spenderRule []interface{} + for _, spenderItem := range spender { + spenderRule = append(spenderRule, spenderItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "Approval", ownerRule, spenderRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677Approval) + if err := _BurnMintERC677.contract.UnpackLog(event, "Approval", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseApproval(log types.Log) (*BurnMintERC677Approval, error) { + event := new(BurnMintERC677Approval) + if err := _BurnMintERC677.contract.UnpackLog(event, "Approval", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677BurnAccessGrantedIterator struct { + Event *BurnMintERC677BurnAccessGranted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677BurnAccessGrantedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677BurnAccessGranted) + 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(BurnMintERC677BurnAccessGranted) + 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 *BurnMintERC677BurnAccessGrantedIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677BurnAccessGrantedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677BurnAccessGranted struct { + Burner common.Address + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterBurnAccessGranted(opts *bind.FilterOpts, burner []common.Address) (*BurnMintERC677BurnAccessGrantedIterator, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "BurnAccessGranted", burnerRule) + if err != nil { + return nil, err + } + return &BurnMintERC677BurnAccessGrantedIterator{contract: _BurnMintERC677.contract, event: "BurnAccessGranted", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchBurnAccessGranted(opts *bind.WatchOpts, sink chan<- *BurnMintERC677BurnAccessGranted, burner []common.Address) (event.Subscription, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "BurnAccessGranted", burnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677BurnAccessGranted) + if err := _BurnMintERC677.contract.UnpackLog(event, "BurnAccessGranted", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseBurnAccessGranted(log types.Log) (*BurnMintERC677BurnAccessGranted, error) { + event := new(BurnMintERC677BurnAccessGranted) + if err := _BurnMintERC677.contract.UnpackLog(event, "BurnAccessGranted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677BurnAccessRevokedIterator struct { + Event *BurnMintERC677BurnAccessRevoked + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677BurnAccessRevokedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677BurnAccessRevoked) + 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(BurnMintERC677BurnAccessRevoked) + 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 *BurnMintERC677BurnAccessRevokedIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677BurnAccessRevokedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677BurnAccessRevoked struct { + Burner common.Address + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterBurnAccessRevoked(opts *bind.FilterOpts, burner []common.Address) (*BurnMintERC677BurnAccessRevokedIterator, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "BurnAccessRevoked", burnerRule) + if err != nil { + return nil, err + } + return &BurnMintERC677BurnAccessRevokedIterator{contract: _BurnMintERC677.contract, event: "BurnAccessRevoked", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchBurnAccessRevoked(opts *bind.WatchOpts, sink chan<- *BurnMintERC677BurnAccessRevoked, burner []common.Address) (event.Subscription, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "BurnAccessRevoked", burnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677BurnAccessRevoked) + if err := _BurnMintERC677.contract.UnpackLog(event, "BurnAccessRevoked", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseBurnAccessRevoked(log types.Log) (*BurnMintERC677BurnAccessRevoked, error) { + event := new(BurnMintERC677BurnAccessRevoked) + if err := _BurnMintERC677.contract.UnpackLog(event, "BurnAccessRevoked", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677MintAccessGrantedIterator struct { + Event *BurnMintERC677MintAccessGranted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677MintAccessGrantedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677MintAccessGranted) + 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(BurnMintERC677MintAccessGranted) + 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 *BurnMintERC677MintAccessGrantedIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677MintAccessGrantedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677MintAccessGranted struct { + Minter common.Address + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterMintAccessGranted(opts *bind.FilterOpts, minter []common.Address) (*BurnMintERC677MintAccessGrantedIterator, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "MintAccessGranted", minterRule) + if err != nil { + return nil, err + } + return &BurnMintERC677MintAccessGrantedIterator{contract: _BurnMintERC677.contract, event: "MintAccessGranted", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchMintAccessGranted(opts *bind.WatchOpts, sink chan<- *BurnMintERC677MintAccessGranted, minter []common.Address) (event.Subscription, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "MintAccessGranted", minterRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677MintAccessGranted) + if err := _BurnMintERC677.contract.UnpackLog(event, "MintAccessGranted", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseMintAccessGranted(log types.Log) (*BurnMintERC677MintAccessGranted, error) { + event := new(BurnMintERC677MintAccessGranted) + if err := _BurnMintERC677.contract.UnpackLog(event, "MintAccessGranted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677MintAccessRevokedIterator struct { + Event *BurnMintERC677MintAccessRevoked + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677MintAccessRevokedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677MintAccessRevoked) + 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(BurnMintERC677MintAccessRevoked) + 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 *BurnMintERC677MintAccessRevokedIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677MintAccessRevokedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677MintAccessRevoked struct { + Minter common.Address + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterMintAccessRevoked(opts *bind.FilterOpts, minter []common.Address) (*BurnMintERC677MintAccessRevokedIterator, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "MintAccessRevoked", minterRule) + if err != nil { + return nil, err + } + return &BurnMintERC677MintAccessRevokedIterator{contract: _BurnMintERC677.contract, event: "MintAccessRevoked", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchMintAccessRevoked(opts *bind.WatchOpts, sink chan<- *BurnMintERC677MintAccessRevoked, minter []common.Address) (event.Subscription, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "MintAccessRevoked", minterRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677MintAccessRevoked) + if err := _BurnMintERC677.contract.UnpackLog(event, "MintAccessRevoked", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseMintAccessRevoked(log types.Log) (*BurnMintERC677MintAccessRevoked, error) { + event := new(BurnMintERC677MintAccessRevoked) + if err := _BurnMintERC677.contract.UnpackLog(event, "MintAccessRevoked", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677OwnershipTransferRequestedIterator struct { + Event *BurnMintERC677OwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677OwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677OwnershipTransferRequested) + 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(BurnMintERC677OwnershipTransferRequested) + 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 *BurnMintERC677OwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677OwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677OwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677OwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &BurnMintERC677OwnershipTransferRequestedIterator{contract: _BurnMintERC677.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *BurnMintERC677OwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677OwnershipTransferRequested) + if err := _BurnMintERC677.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseOwnershipTransferRequested(log types.Log) (*BurnMintERC677OwnershipTransferRequested, error) { + event := new(BurnMintERC677OwnershipTransferRequested) + if err := _BurnMintERC677.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677OwnershipTransferredIterator struct { + Event *BurnMintERC677OwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677OwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677OwnershipTransferred) + 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(BurnMintERC677OwnershipTransferred) + 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 *BurnMintERC677OwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677OwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677OwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677OwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &BurnMintERC677OwnershipTransferredIterator{contract: _BurnMintERC677.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *BurnMintERC677OwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677OwnershipTransferred) + if err := _BurnMintERC677.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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseOwnershipTransferred(log types.Log) (*BurnMintERC677OwnershipTransferred, error) { + event := new(BurnMintERC677OwnershipTransferred) + if err := _BurnMintERC677.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677TransferIterator struct { + Event *BurnMintERC677Transfer + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677TransferIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677Transfer) + 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(BurnMintERC677Transfer) + 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 *BurnMintERC677TransferIterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677TransferIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677Transfer struct { + From common.Address + To common.Address + Value *big.Int + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677TransferIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "Transfer", fromRule, toRule) + if err != nil { + return nil, err + } + return &BurnMintERC677TransferIterator{contract: _BurnMintERC677.contract, event: "Transfer", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchTransfer(opts *bind.WatchOpts, sink chan<- *BurnMintERC677Transfer, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "Transfer", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677Transfer) + if err := _BurnMintERC677.contract.UnpackLog(event, "Transfer", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseTransfer(log types.Log) (*BurnMintERC677Transfer, error) { + event := new(BurnMintERC677Transfer) + if err := _BurnMintERC677.contract.UnpackLog(event, "Transfer", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type BurnMintERC677Transfer0Iterator struct { + Event *BurnMintERC677Transfer0 + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *BurnMintERC677Transfer0Iterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(BurnMintERC677Transfer0) + 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(BurnMintERC677Transfer0) + 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 *BurnMintERC677Transfer0Iterator) Error() error { + return it.fail +} + +func (it *BurnMintERC677Transfer0Iterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type BurnMintERC677Transfer0 struct { + From common.Address + To common.Address + Value *big.Int + Data []byte + Raw types.Log +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) FilterTransfer0(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677Transfer0Iterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.FilterLogs(opts, "Transfer0", fromRule, toRule) + if err != nil { + return nil, err + } + return &BurnMintERC677Transfer0Iterator{contract: _BurnMintERC677.contract, event: "Transfer0", logs: logs, sub: sub}, nil +} + +func (_BurnMintERC677 *BurnMintERC677Filterer) WatchTransfer0(opts *bind.WatchOpts, sink chan<- *BurnMintERC677Transfer0, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _BurnMintERC677.contract.WatchLogs(opts, "Transfer0", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(BurnMintERC677Transfer0) + if err := _BurnMintERC677.contract.UnpackLog(event, "Transfer0", 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 (_BurnMintERC677 *BurnMintERC677Filterer) ParseTransfer0(log types.Log) (*BurnMintERC677Transfer0, error) { + event := new(BurnMintERC677Transfer0) + if err := _BurnMintERC677.contract.UnpackLog(event, "Transfer0", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_BurnMintERC677 *BurnMintERC677) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _BurnMintERC677.abi.Events["Approval"].ID: + return _BurnMintERC677.ParseApproval(log) + case _BurnMintERC677.abi.Events["BurnAccessGranted"].ID: + return _BurnMintERC677.ParseBurnAccessGranted(log) + case _BurnMintERC677.abi.Events["BurnAccessRevoked"].ID: + return _BurnMintERC677.ParseBurnAccessRevoked(log) + case _BurnMintERC677.abi.Events["MintAccessGranted"].ID: + return _BurnMintERC677.ParseMintAccessGranted(log) + case _BurnMintERC677.abi.Events["MintAccessRevoked"].ID: + return _BurnMintERC677.ParseMintAccessRevoked(log) + case _BurnMintERC677.abi.Events["OwnershipTransferRequested"].ID: + return _BurnMintERC677.ParseOwnershipTransferRequested(log) + case _BurnMintERC677.abi.Events["OwnershipTransferred"].ID: + return _BurnMintERC677.ParseOwnershipTransferred(log) + case _BurnMintERC677.abi.Events["Transfer"].ID: + return _BurnMintERC677.ParseTransfer(log) + case _BurnMintERC677.abi.Events["Transfer0"].ID: + return _BurnMintERC677.ParseTransfer0(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (BurnMintERC677Approval) Topic() common.Hash { + return common.HexToHash("0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925") +} + +func (BurnMintERC677BurnAccessGranted) Topic() common.Hash { + return common.HexToHash("0x92308bb7573b2a3d17ddb868b39d8ebec433f3194421abc22d084f89658c9bad") +} + +func (BurnMintERC677BurnAccessRevoked) Topic() common.Hash { + return common.HexToHash("0x0a675452746933cefe3d74182e78db7afe57ba60eaa4234b5d85e9aa41b0610c") +} + +func (BurnMintERC677MintAccessGranted) Topic() common.Hash { + return common.HexToHash("0xe46fef8bbff1389d9010703cf8ebb363fb3daf5bf56edc27080b67bc8d9251ea") +} + +func (BurnMintERC677MintAccessRevoked) Topic() common.Hash { + return common.HexToHash("0xed998b960f6340d045f620c119730f7aa7995e7425c2401d3a5b64ff998a59e9") +} + +func (BurnMintERC677OwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (BurnMintERC677OwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (BurnMintERC677Transfer) Topic() common.Hash { + return common.HexToHash("0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef") +} + +func (BurnMintERC677Transfer0) Topic() common.Hash { + return common.HexToHash("0xe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c16") +} + +func (_BurnMintERC677 *BurnMintERC677) Address() common.Address { + return _BurnMintERC677.address +} + +type BurnMintERC677Interface interface { + Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) + + BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) + + Decimals(opts *bind.CallOpts) (uint8, error) + + GetBurners(opts *bind.CallOpts) ([]common.Address, error) + + GetMinters(opts *bind.CallOpts) ([]common.Address, error) + + IsBurner(opts *bind.CallOpts, burner common.Address) (bool, error) + + IsMinter(opts *bind.CallOpts, minter common.Address) (bool, error) + + MaxSupply(opts *bind.CallOpts) (*big.Int, error) + + Name(opts *bind.CallOpts) (string, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + Symbol(opts *bind.CallOpts) (string, error) + + TotalSupply(opts *bind.CallOpts) (*big.Int, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) + + Burn(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + + Burn0(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) + + BurnFrom(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) + + DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) + + DecreaseApproval(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) + + GrantBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) + + GrantMintAndBurnRoles(opts *bind.TransactOpts, burnAndMinter common.Address) (*types.Transaction, error) + + GrantMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) + + IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) + + IncreaseApproval(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) + + Mint(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) + + RevokeBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) + + RevokeMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) + + Transfer(opts *bind.TransactOpts, to common.Address, amount *big.Int) (*types.Transaction, error) + + TransferAndCall(opts *bind.TransactOpts, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) + + TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*BurnMintERC677ApprovalIterator, error) + + WatchApproval(opts *bind.WatchOpts, sink chan<- *BurnMintERC677Approval, owner []common.Address, spender []common.Address) (event.Subscription, error) + + ParseApproval(log types.Log) (*BurnMintERC677Approval, error) + + FilterBurnAccessGranted(opts *bind.FilterOpts, burner []common.Address) (*BurnMintERC677BurnAccessGrantedIterator, error) + + WatchBurnAccessGranted(opts *bind.WatchOpts, sink chan<- *BurnMintERC677BurnAccessGranted, burner []common.Address) (event.Subscription, error) + + ParseBurnAccessGranted(log types.Log) (*BurnMintERC677BurnAccessGranted, error) + + FilterBurnAccessRevoked(opts *bind.FilterOpts, burner []common.Address) (*BurnMintERC677BurnAccessRevokedIterator, error) + + WatchBurnAccessRevoked(opts *bind.WatchOpts, sink chan<- *BurnMintERC677BurnAccessRevoked, burner []common.Address) (event.Subscription, error) + + ParseBurnAccessRevoked(log types.Log) (*BurnMintERC677BurnAccessRevoked, error) + + FilterMintAccessGranted(opts *bind.FilterOpts, minter []common.Address) (*BurnMintERC677MintAccessGrantedIterator, error) + + WatchMintAccessGranted(opts *bind.WatchOpts, sink chan<- *BurnMintERC677MintAccessGranted, minter []common.Address) (event.Subscription, error) + + ParseMintAccessGranted(log types.Log) (*BurnMintERC677MintAccessGranted, error) + + FilterMintAccessRevoked(opts *bind.FilterOpts, minter []common.Address) (*BurnMintERC677MintAccessRevokedIterator, error) + + WatchMintAccessRevoked(opts *bind.WatchOpts, sink chan<- *BurnMintERC677MintAccessRevoked, minter []common.Address) (event.Subscription, error) + + ParseMintAccessRevoked(log types.Log) (*BurnMintERC677MintAccessRevoked, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677OwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *BurnMintERC677OwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*BurnMintERC677OwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677OwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *BurnMintERC677OwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*BurnMintERC677OwnershipTransferred, error) + + FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677TransferIterator, error) + + WatchTransfer(opts *bind.WatchOpts, sink chan<- *BurnMintERC677Transfer, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseTransfer(log types.Log) (*BurnMintERC677Transfer, error) + + FilterTransfer0(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*BurnMintERC677Transfer0Iterator, error) + + WatchTransfer0(opts *bind.WatchOpts, sink chan<- *BurnMintERC677Transfer0, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseTransfer0(log types.Log) (*BurnMintERC677Transfer0, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/shared/generated/link_token/link_token.go b/core/gethwrappers/shared/generated/link_token/link_token.go new file mode 100644 index 00000000000..98de7de66a0 --- /dev/null +++ b/core/gethwrappers/shared/generated/link_token/link_token.go @@ -0,0 +1,2068 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package link_token + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var LinkTokenMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"supplyAfterMint\",\"type\":\"uint256\"}],\"name\":\"MaxSupplyExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderNotBurner\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderNotMinter\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"BurnAccessGranted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"BurnAccessRevoked\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"MintAccessGranted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"MintAccessRevoked\",\"type\":\"event\"},{\"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\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burn\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"burnFrom\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseApproval\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getBurners\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getMinters\",\"outputs\":[{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"grantBurnRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burnAndMinter\",\"type\":\"address\"}],\"name\":\"grantMintAndBurnRoles\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"grantMintRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseApproval\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"isBurner\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"isMinter\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"maxSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"mint\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"burner\",\"type\":\"address\"}],\"name\":\"revokeBurnRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"minter\",\"type\":\"address\"}],\"name\":\"revokeMintRole\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"transferAndCall\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"success\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60c06040523480156200001157600080fd5b506040518060400160405280600f81526020016e21b430b4b72634b735902a37b5b2b760891b815250604051806040016040528060048152602001634c494e4b60e01b81525060126b033b2e3c9fd0803ce8000000338060008686818181600390816200007f91906200028c565b5060046200008e82826200028c565b5050506001600160a01b0384169150620000f190505760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600580546001600160a01b0319166001600160a01b0384811691909117909155811615620001245762000124816200013b565b50505060ff90911660805260a05250620003589050565b336001600160a01b03821603620001955760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401620000e8565b600680546001600160a01b0319166001600160a01b03838116918217909255600554604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200021257607f821691505b6020821081036200023357634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200028757600081815260208120601f850160051c81016020861015620002625750805b601f850160051c820191505b8181101562000283578281556001016200026e565b5050505b505050565b81516001600160401b03811115620002a857620002a8620001e7565b620002c081620002b98454620001fd565b8462000239565b602080601f831160018114620002f85760008415620002df5750858301515b600019600386901b1c1916600185901b17855562000283565b600085815260208120601f198616915b82811015620003295788860151825594840194600190910190840162000308565b5085821015620003485787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b60805160a051611e4c6200038c60003960008181610447015281816108c301526108ed015260006102710152611e4c6000f3fe608060405234801561001057600080fd5b50600436106101f05760003560e01c806379cc67901161010f578063c2e3273d116100a2578063d73dd62311610071578063d73dd6231461046b578063dd62ed3e1461047e578063f2fde38b146104c4578063f81094f3146104d757600080fd5b8063c2e3273d1461040c578063c630948d1461041f578063c64d0ebc14610432578063d5abeb011461044557600080fd5b80639dc29fac116100de5780639dc29fac146103c0578063a457c2d7146103d3578063a9059cbb146103e6578063aa271e1a146103f957600080fd5b806379cc67901461037557806386fe8b43146103885780638da5cb5b1461039057806395d89b41146103b857600080fd5b806340c10f19116101875780636618846311610156578063661884631461030f5780636b32810b1461032257806370a082311461033757806379ba50971461036d57600080fd5b806340c10f19146102c157806342966c68146102d65780634334614a146102e95780634f5632f8146102fc57600080fd5b806323b872dd116101c357806323b872dd14610257578063313ce5671461026a578063395093511461029b5780634000aea0146102ae57600080fd5b806301ffc9a7146101f557806306fdde031461021d578063095ea7b31461023257806318160ddd14610245575b600080fd5b6102086102033660046119b9565b6104ea565b60405190151581526020015b60405180910390f35b61022561061b565b6040516102149190611a5f565b610208610240366004611a9b565b6106ad565b6002545b604051908152602001610214565b610208610265366004611ac5565b6106c5565b60405160ff7f0000000000000000000000000000000000000000000000000000000000000000168152602001610214565b6102086102a9366004611a9b565b6106e9565b6102086102bc366004611b30565b610735565b6102d46102cf366004611a9b565b610858565b005b6102d46102e4366004611c19565b61097f565b6102086102f7366004611c32565b6109cc565b6102d461030a366004611c32565b6109d9565b61020861031d366004611a9b565b610a35565b61032a610a48565b6040516102149190611c4d565b610249610345366004611c32565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6102d4610a59565b6102d4610383366004611a9b565b610b5a565b61032a610ba9565b60055460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610214565b610225610bb5565b6102d46103ce366004611a9b565b610bc4565b6102086103e1366004611a9b565b610bce565b6102086103f4366004611a9b565b610c9f565b610208610407366004611c32565b610cad565b6102d461041a366004611c32565b610cba565b6102d461042d366004611c32565b610d16565b6102d4610440366004611c32565b610d24565b7f0000000000000000000000000000000000000000000000000000000000000000610249565b6102d4610479366004611a9b565b610d80565b61024961048c366004611ca7565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b6102d46104d2366004611c32565b610d8a565b6102d46104e5366004611c32565b610d9b565b60007fffffffff0000000000000000000000000000000000000000000000000000000082167f36372b0700000000000000000000000000000000000000000000000000000000148061057d57507fffffffff0000000000000000000000000000000000000000000000000000000082167f4000aea000000000000000000000000000000000000000000000000000000000145b806105c957507fffffffff0000000000000000000000000000000000000000000000000000000082167fe6599b4d00000000000000000000000000000000000000000000000000000000145b8061061557507fffffffff0000000000000000000000000000000000000000000000000000000082167f01ffc9a700000000000000000000000000000000000000000000000000000000145b92915050565b60606003805461062a90611cda565b80601f016020809104026020016040519081016040528092919081815260200182805461065690611cda565b80156106a35780601f10610678576101008083540402835291602001916106a3565b820191906000526020600020905b81548152906001019060200180831161068657829003601f168201915b5050505050905090565b6000336106bb818585610df7565b5060019392505050565b6000336106d3858285610e2b565b6106de858585610efc565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906106bb9082908690610730908790611d5c565b610df7565b60006107418484610c9f565b508373ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff167fe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c1685856040516107a1929190611d6f565b60405180910390a373ffffffffffffffffffffffffffffffffffffffff84163b156106bb576040517fa4c0ed3600000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff85169063a4c0ed369061081c90339087908790600401611d90565b600060405180830381600087803b15801561083657600080fd5b505af115801561084a573d6000803e3d6000fd5b505050505060019392505050565b61086133610cad565b61089e576040517fe2c8c9d50000000000000000000000000000000000000000000000000000000081523360048201526024015b60405180910390fd5b813073ffffffffffffffffffffffffffffffffffffffff8216036108c157600080fd5b7f00000000000000000000000000000000000000000000000000000000000000001580159061092257507f00000000000000000000000000000000000000000000000000000000000000008261091660025490565b6109209190611d5c565b115b15610970578161093160025490565b61093b9190611d5c565b6040517fcbbf111300000000000000000000000000000000000000000000000000000000815260040161089591815260200190565b61097a8383610f2a565b505050565b610988336109cc565b6109c0576040517fc820b10b000000000000000000000000000000000000000000000000000000008152336004820152602401610895565b6109c98161101d565b50565b6000610615600983611027565b6109e1611056565b6109ec6009826110d9565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907f0a675452746933cefe3d74182e78db7afe57ba60eaa4234b5d85e9aa41b0610c90600090a250565b6000610a418383610bce565b9392505050565b6060610a5460076110fb565b905090565b60065473ffffffffffffffffffffffffffffffffffffffff163314610ada576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610895565b600580547fffffffffffffffffffffffff00000000000000000000000000000000000000008082163390811790935560068054909116905560405173ffffffffffffffffffffffffffffffffffffffff909116919082907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b610b63336109cc565b610b9b576040517fc820b10b000000000000000000000000000000000000000000000000000000008152336004820152602401610895565b610ba58282611108565b5050565b6060610a5460096110fb565b60606004805461062a90611cda565b610ba58282610b5a565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff8716845290915281205490919083811015610c92576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f0000000000000000000000000000000000000000000000000000006064820152608401610895565b6106de8286868403610df7565b6000336106bb818585610efc565b6000610615600783611027565b610cc2611056565b610ccd60078261111d565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907fe46fef8bbff1389d9010703cf8ebb363fb3daf5bf56edc27080b67bc8d9251ea90600090a250565b610d1f81610cba565b6109c9815b610d2c611056565b610d3760098261111d565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907f92308bb7573b2a3d17ddb868b39d8ebec433f3194421abc22d084f89658c9bad90600090a250565b61097a82826106e9565b610d92611056565b6109c98161113f565b610da3611056565b610dae6007826110d9565b156109c95760405173ffffffffffffffffffffffffffffffffffffffff8216907fed998b960f6340d045f620c119730f7aa7995e7425c2401d3a5b64ff998a59e990600090a250565b813073ffffffffffffffffffffffffffffffffffffffff821603610e1a57600080fd5b610e25848484611235565b50505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8114610e255781811015610eef576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e63650000006044820152606401610895565b610e258484848403610df7565b813073ffffffffffffffffffffffffffffffffffffffff821603610f1f57600080fd5b610e258484846113e8565b73ffffffffffffffffffffffffffffffffffffffff8216610fa7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601f60248201527f45524332303a206d696e7420746f20746865207a65726f2061646472657373006044820152606401610895565b8060026000828254610fb99190611d5c565b909155505073ffffffffffffffffffffffffffffffffffffffff8216600081815260208181526040808320805486019055518481527fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a35050565b6109c93382611657565b73ffffffffffffffffffffffffffffffffffffffff811660009081526001830160205260408120541515610a41565b60055473ffffffffffffffffffffffffffffffffffffffff1633146110d7576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610895565b565b6000610a418373ffffffffffffffffffffffffffffffffffffffff841661181b565b60606000610a418361190e565b611113823383610e2b565b610ba58282611657565b6000610a418373ffffffffffffffffffffffffffffffffffffffff841661196a565b3373ffffffffffffffffffffffffffffffffffffffff8216036111be576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610895565b600680547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600554604051919216907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b73ffffffffffffffffffffffffffffffffffffffff83166112d7576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f72657373000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff821661137a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f73730000000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff831661148b576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f64726573730000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff821661152e576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f65737300000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff8316600090815260208190526040902054818110156115e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e636500000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610e25565b73ffffffffffffffffffffffffffffffffffffffff82166116fa576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f45524332303a206275726e2066726f6d20746865207a65726f2061646472657360448201527f73000000000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260208190526040902054818110156117b0576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a206275726e20616d6f756e7420657863656564732062616c616e60448201527f63650000000000000000000000000000000000000000000000000000000000006064820152608401610895565b73ffffffffffffffffffffffffffffffffffffffff83166000818152602081815260408083208686039055600280548790039055518581529192917fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3505050565b6000818152600183016020526040812054801561190457600061183f600183611dce565b855490915060009061185390600190611dce565b90508181146118b857600086600001828154811061187357611873611de1565b906000526020600020015490508087600001848154811061189657611896611de1565b6000918252602080832090910192909255918252600188019052604090208390555b85548690806118c9576118c9611e10565b600190038181906000526020600020016000905590558560010160008681526020019081526020016000206000905560019350505050610615565b6000915050610615565b60608160000180548060200260200160405190810160405280929190818152602001828054801561195e57602002820191906000526020600020905b81548152602001906001019080831161194a575b50505050509050919050565b60008181526001830160205260408120546119b157508154600181810184556000848152602080822090930184905584548482528286019093526040902091909155610615565b506000610615565b6000602082840312156119cb57600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610a4157600080fd5b6000815180845260005b81811015611a2157602081850181015186830182015201611a05565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b602081526000610a4160208301846119fb565b803573ffffffffffffffffffffffffffffffffffffffff81168114611a9657600080fd5b919050565b60008060408385031215611aae57600080fd5b611ab783611a72565b946020939093013593505050565b600080600060608486031215611ada57600080fd5b611ae384611a72565b9250611af160208501611a72565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b600080600060608486031215611b4557600080fd5b611b4e84611a72565b925060208401359150604084013567ffffffffffffffff80821115611b7257600080fd5b818601915086601f830112611b8657600080fd5b813581811115611b9857611b98611b01565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0908116603f01168101908382118183101715611bde57611bde611b01565b81604052828152896020848701011115611bf757600080fd5b8260208601602083013760006020848301015280955050505050509250925092565b600060208284031215611c2b57600080fd5b5035919050565b600060208284031215611c4457600080fd5b610a4182611a72565b6020808252825182820181905260009190848201906040850190845b81811015611c9b57835173ffffffffffffffffffffffffffffffffffffffff1683529284019291840191600101611c69565b50909695505050505050565b60008060408385031215611cba57600080fd5b611cc383611a72565b9150611cd160208401611a72565b90509250929050565b600181811c90821680611cee57607f821691505b602082108103611d27577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561061557610615611d2d565b828152604060208201526000611d8860408301846119fb565b949350505050565b73ffffffffffffffffffffffffffffffffffffffff84168152826020820152606060408201526000611dc560608301846119fb565b95945050505050565b8181038181111561061557610615611d2d565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fdfea164736f6c6343000813000a", +} + +var LinkTokenABI = LinkTokenMetaData.ABI + +var LinkTokenBin = LinkTokenMetaData.Bin + +func DeployLinkToken(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *LinkToken, error) { + parsed, err := LinkTokenMetaData.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(LinkTokenBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &LinkToken{LinkTokenCaller: LinkTokenCaller{contract: contract}, LinkTokenTransactor: LinkTokenTransactor{contract: contract}, LinkTokenFilterer: LinkTokenFilterer{contract: contract}}, nil +} + +type LinkToken struct { + address common.Address + abi abi.ABI + LinkTokenCaller + LinkTokenTransactor + LinkTokenFilterer +} + +type LinkTokenCaller struct { + contract *bind.BoundContract +} + +type LinkTokenTransactor struct { + contract *bind.BoundContract +} + +type LinkTokenFilterer struct { + contract *bind.BoundContract +} + +type LinkTokenSession struct { + Contract *LinkToken + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type LinkTokenCallerSession struct { + Contract *LinkTokenCaller + CallOpts bind.CallOpts +} + +type LinkTokenTransactorSession struct { + Contract *LinkTokenTransactor + TransactOpts bind.TransactOpts +} + +type LinkTokenRaw struct { + Contract *LinkToken +} + +type LinkTokenCallerRaw struct { + Contract *LinkTokenCaller +} + +type LinkTokenTransactorRaw struct { + Contract *LinkTokenTransactor +} + +func NewLinkToken(address common.Address, backend bind.ContractBackend) (*LinkToken, error) { + abi, err := abi.JSON(strings.NewReader(LinkTokenABI)) + if err != nil { + return nil, err + } + contract, err := bindLinkToken(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &LinkToken{address: address, abi: abi, LinkTokenCaller: LinkTokenCaller{contract: contract}, LinkTokenTransactor: LinkTokenTransactor{contract: contract}, LinkTokenFilterer: LinkTokenFilterer{contract: contract}}, nil +} + +func NewLinkTokenCaller(address common.Address, caller bind.ContractCaller) (*LinkTokenCaller, error) { + contract, err := bindLinkToken(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &LinkTokenCaller{contract: contract}, nil +} + +func NewLinkTokenTransactor(address common.Address, transactor bind.ContractTransactor) (*LinkTokenTransactor, error) { + contract, err := bindLinkToken(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &LinkTokenTransactor{contract: contract}, nil +} + +func NewLinkTokenFilterer(address common.Address, filterer bind.ContractFilterer) (*LinkTokenFilterer, error) { + contract, err := bindLinkToken(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &LinkTokenFilterer{contract: contract}, nil +} + +func bindLinkToken(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := LinkTokenMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_LinkToken *LinkTokenRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _LinkToken.Contract.LinkTokenCaller.contract.Call(opts, result, method, params...) +} + +func (_LinkToken *LinkTokenRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LinkToken.Contract.LinkTokenTransactor.contract.Transfer(opts) +} + +func (_LinkToken *LinkTokenRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _LinkToken.Contract.LinkTokenTransactor.contract.Transact(opts, method, params...) +} + +func (_LinkToken *LinkTokenCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _LinkToken.Contract.contract.Call(opts, result, method, params...) +} + +func (_LinkToken *LinkTokenTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LinkToken.Contract.contract.Transfer(opts) +} + +func (_LinkToken *LinkTokenTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _LinkToken.Contract.contract.Transact(opts, method, params...) +} + +func (_LinkToken *LinkTokenCaller) Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "allowance", owner, spender) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { + return _LinkToken.Contract.Allowance(&_LinkToken.CallOpts, owner, spender) +} + +func (_LinkToken *LinkTokenCallerSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { + return _LinkToken.Contract.Allowance(&_LinkToken.CallOpts, owner, spender) +} + +func (_LinkToken *LinkTokenCaller) BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "balanceOf", account) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) BalanceOf(account common.Address) (*big.Int, error) { + return _LinkToken.Contract.BalanceOf(&_LinkToken.CallOpts, account) +} + +func (_LinkToken *LinkTokenCallerSession) BalanceOf(account common.Address) (*big.Int, error) { + return _LinkToken.Contract.BalanceOf(&_LinkToken.CallOpts, account) +} + +func (_LinkToken *LinkTokenCaller) Decimals(opts *bind.CallOpts) (uint8, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "decimals") + + if err != nil { + return *new(uint8), err + } + + out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) Decimals() (uint8, error) { + return _LinkToken.Contract.Decimals(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) Decimals() (uint8, error) { + return _LinkToken.Contract.Decimals(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) GetBurners(opts *bind.CallOpts) ([]common.Address, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "getBurners") + + if err != nil { + return *new([]common.Address), err + } + + out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) GetBurners() ([]common.Address, error) { + return _LinkToken.Contract.GetBurners(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) GetBurners() ([]common.Address, error) { + return _LinkToken.Contract.GetBurners(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) GetMinters(opts *bind.CallOpts) ([]common.Address, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "getMinters") + + if err != nil { + return *new([]common.Address), err + } + + out0 := *abi.ConvertType(out[0], new([]common.Address)).(*[]common.Address) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) GetMinters() ([]common.Address, error) { + return _LinkToken.Contract.GetMinters(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) GetMinters() ([]common.Address, error) { + return _LinkToken.Contract.GetMinters(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) IsBurner(opts *bind.CallOpts, burner common.Address) (bool, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "isBurner", burner) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) IsBurner(burner common.Address) (bool, error) { + return _LinkToken.Contract.IsBurner(&_LinkToken.CallOpts, burner) +} + +func (_LinkToken *LinkTokenCallerSession) IsBurner(burner common.Address) (bool, error) { + return _LinkToken.Contract.IsBurner(&_LinkToken.CallOpts, burner) +} + +func (_LinkToken *LinkTokenCaller) IsMinter(opts *bind.CallOpts, minter common.Address) (bool, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "isMinter", minter) + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) IsMinter(minter common.Address) (bool, error) { + return _LinkToken.Contract.IsMinter(&_LinkToken.CallOpts, minter) +} + +func (_LinkToken *LinkTokenCallerSession) IsMinter(minter common.Address) (bool, error) { + return _LinkToken.Contract.IsMinter(&_LinkToken.CallOpts, minter) +} + +func (_LinkToken *LinkTokenCaller) MaxSupply(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "maxSupply") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) MaxSupply() (*big.Int, error) { + return _LinkToken.Contract.MaxSupply(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) MaxSupply() (*big.Int, error) { + return _LinkToken.Contract.MaxSupply(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) Name(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "name") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) Name() (string, error) { + return _LinkToken.Contract.Name(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) Name() (string, error) { + return _LinkToken.Contract.Name(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _LinkToken.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 (_LinkToken *LinkTokenSession) Owner() (common.Address, error) { + return _LinkToken.Contract.Owner(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) Owner() (common.Address, error) { + return _LinkToken.Contract.Owner(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { + var out []interface{} + err := _LinkToken.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 (_LinkToken *LinkTokenSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _LinkToken.Contract.SupportsInterface(&_LinkToken.CallOpts, interfaceId) +} + +func (_LinkToken *LinkTokenCallerSession) SupportsInterface(interfaceId [4]byte) (bool, error) { + return _LinkToken.Contract.SupportsInterface(&_LinkToken.CallOpts, interfaceId) +} + +func (_LinkToken *LinkTokenCaller) Symbol(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "symbol") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) Symbol() (string, error) { + return _LinkToken.Contract.Symbol(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) Symbol() (string, error) { + return _LinkToken.Contract.Symbol(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCaller) TotalSupply(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _LinkToken.contract.Call(opts, &out, "totalSupply") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_LinkToken *LinkTokenSession) TotalSupply() (*big.Int, error) { + return _LinkToken.Contract.TotalSupply(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenCallerSession) TotalSupply() (*big.Int, error) { + return _LinkToken.Contract.TotalSupply(&_LinkToken.CallOpts) +} + +func (_LinkToken *LinkTokenTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "acceptOwnership") +} + +func (_LinkToken *LinkTokenSession) AcceptOwnership() (*types.Transaction, error) { + return _LinkToken.Contract.AcceptOwnership(&_LinkToken.TransactOpts) +} + +func (_LinkToken *LinkTokenTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _LinkToken.Contract.AcceptOwnership(&_LinkToken.TransactOpts) +} + +func (_LinkToken *LinkTokenTransactor) Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "approve", spender, amount) +} + +func (_LinkToken *LinkTokenSession) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Approve(&_LinkToken.TransactOpts, spender, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Approve(&_LinkToken.TransactOpts, spender, amount) +} + +func (_LinkToken *LinkTokenTransactor) Burn(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "burn", amount) +} + +func (_LinkToken *LinkTokenSession) Burn(amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Burn(&_LinkToken.TransactOpts, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) Burn(amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Burn(&_LinkToken.TransactOpts, amount) +} + +func (_LinkToken *LinkTokenTransactor) Burn0(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "burn0", account, amount) +} + +func (_LinkToken *LinkTokenSession) Burn0(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Burn0(&_LinkToken.TransactOpts, account, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) Burn0(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Burn0(&_LinkToken.TransactOpts, account, amount) +} + +func (_LinkToken *LinkTokenTransactor) BurnFrom(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "burnFrom", account, amount) +} + +func (_LinkToken *LinkTokenSession) BurnFrom(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.BurnFrom(&_LinkToken.TransactOpts, account, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) BurnFrom(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.BurnFrom(&_LinkToken.TransactOpts, account, amount) +} + +func (_LinkToken *LinkTokenTransactor) DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "decreaseAllowance", spender, subtractedValue) +} + +func (_LinkToken *LinkTokenSession) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.DecreaseAllowance(&_LinkToken.TransactOpts, spender, subtractedValue) +} + +func (_LinkToken *LinkTokenTransactorSession) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.DecreaseAllowance(&_LinkToken.TransactOpts, spender, subtractedValue) +} + +func (_LinkToken *LinkTokenTransactor) DecreaseApproval(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "decreaseApproval", spender, subtractedValue) +} + +func (_LinkToken *LinkTokenSession) DecreaseApproval(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.DecreaseApproval(&_LinkToken.TransactOpts, spender, subtractedValue) +} + +func (_LinkToken *LinkTokenTransactorSession) DecreaseApproval(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.DecreaseApproval(&_LinkToken.TransactOpts, spender, subtractedValue) +} + +func (_LinkToken *LinkTokenTransactor) GrantBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "grantBurnRole", burner) +} + +func (_LinkToken *LinkTokenSession) GrantBurnRole(burner common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.GrantBurnRole(&_LinkToken.TransactOpts, burner) +} + +func (_LinkToken *LinkTokenTransactorSession) GrantBurnRole(burner common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.GrantBurnRole(&_LinkToken.TransactOpts, burner) +} + +func (_LinkToken *LinkTokenTransactor) GrantMintAndBurnRoles(opts *bind.TransactOpts, burnAndMinter common.Address) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "grantMintAndBurnRoles", burnAndMinter) +} + +func (_LinkToken *LinkTokenSession) GrantMintAndBurnRoles(burnAndMinter common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.GrantMintAndBurnRoles(&_LinkToken.TransactOpts, burnAndMinter) +} + +func (_LinkToken *LinkTokenTransactorSession) GrantMintAndBurnRoles(burnAndMinter common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.GrantMintAndBurnRoles(&_LinkToken.TransactOpts, burnAndMinter) +} + +func (_LinkToken *LinkTokenTransactor) GrantMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "grantMintRole", minter) +} + +func (_LinkToken *LinkTokenSession) GrantMintRole(minter common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.GrantMintRole(&_LinkToken.TransactOpts, minter) +} + +func (_LinkToken *LinkTokenTransactorSession) GrantMintRole(minter common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.GrantMintRole(&_LinkToken.TransactOpts, minter) +} + +func (_LinkToken *LinkTokenTransactor) IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "increaseAllowance", spender, addedValue) +} + +func (_LinkToken *LinkTokenSession) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.IncreaseAllowance(&_LinkToken.TransactOpts, spender, addedValue) +} + +func (_LinkToken *LinkTokenTransactorSession) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.IncreaseAllowance(&_LinkToken.TransactOpts, spender, addedValue) +} + +func (_LinkToken *LinkTokenTransactor) IncreaseApproval(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "increaseApproval", spender, addedValue) +} + +func (_LinkToken *LinkTokenSession) IncreaseApproval(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.IncreaseApproval(&_LinkToken.TransactOpts, spender, addedValue) +} + +func (_LinkToken *LinkTokenTransactorSession) IncreaseApproval(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.IncreaseApproval(&_LinkToken.TransactOpts, spender, addedValue) +} + +func (_LinkToken *LinkTokenTransactor) Mint(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "mint", account, amount) +} + +func (_LinkToken *LinkTokenSession) Mint(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Mint(&_LinkToken.TransactOpts, account, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) Mint(account common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Mint(&_LinkToken.TransactOpts, account, amount) +} + +func (_LinkToken *LinkTokenTransactor) RevokeBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "revokeBurnRole", burner) +} + +func (_LinkToken *LinkTokenSession) RevokeBurnRole(burner common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.RevokeBurnRole(&_LinkToken.TransactOpts, burner) +} + +func (_LinkToken *LinkTokenTransactorSession) RevokeBurnRole(burner common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.RevokeBurnRole(&_LinkToken.TransactOpts, burner) +} + +func (_LinkToken *LinkTokenTransactor) RevokeMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "revokeMintRole", minter) +} + +func (_LinkToken *LinkTokenSession) RevokeMintRole(minter common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.RevokeMintRole(&_LinkToken.TransactOpts, minter) +} + +func (_LinkToken *LinkTokenTransactorSession) RevokeMintRole(minter common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.RevokeMintRole(&_LinkToken.TransactOpts, minter) +} + +func (_LinkToken *LinkTokenTransactor) Transfer(opts *bind.TransactOpts, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "transfer", to, amount) +} + +func (_LinkToken *LinkTokenSession) Transfer(to common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Transfer(&_LinkToken.TransactOpts, to, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) Transfer(to common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.Transfer(&_LinkToken.TransactOpts, to, amount) +} + +func (_LinkToken *LinkTokenTransactor) TransferAndCall(opts *bind.TransactOpts, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "transferAndCall", to, amount, data) +} + +func (_LinkToken *LinkTokenSession) TransferAndCall(to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _LinkToken.Contract.TransferAndCall(&_LinkToken.TransactOpts, to, amount, data) +} + +func (_LinkToken *LinkTokenTransactorSession) TransferAndCall(to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) { + return _LinkToken.Contract.TransferAndCall(&_LinkToken.TransactOpts, to, amount, data) +} + +func (_LinkToken *LinkTokenTransactor) TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "transferFrom", from, to, amount) +} + +func (_LinkToken *LinkTokenSession) TransferFrom(from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.TransferFrom(&_LinkToken.TransactOpts, from, to, amount) +} + +func (_LinkToken *LinkTokenTransactorSession) TransferFrom(from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _LinkToken.Contract.TransferFrom(&_LinkToken.TransactOpts, from, to, amount) +} + +func (_LinkToken *LinkTokenTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _LinkToken.contract.Transact(opts, "transferOwnership", to) +} + +func (_LinkToken *LinkTokenSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.TransferOwnership(&_LinkToken.TransactOpts, to) +} + +func (_LinkToken *LinkTokenTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _LinkToken.Contract.TransferOwnership(&_LinkToken.TransactOpts, to) +} + +type LinkTokenApprovalIterator struct { + Event *LinkTokenApproval + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenApprovalIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenApproval) + 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(LinkTokenApproval) + 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 *LinkTokenApprovalIterator) Error() error { + return it.fail +} + +func (it *LinkTokenApprovalIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenApproval struct { + Owner common.Address + Spender common.Address + Value *big.Int + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*LinkTokenApprovalIterator, error) { + + var ownerRule []interface{} + for _, ownerItem := range owner { + ownerRule = append(ownerRule, ownerItem) + } + var spenderRule []interface{} + for _, spenderItem := range spender { + spenderRule = append(spenderRule, spenderItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "Approval", ownerRule, spenderRule) + if err != nil { + return nil, err + } + return &LinkTokenApprovalIterator{contract: _LinkToken.contract, event: "Approval", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchApproval(opts *bind.WatchOpts, sink chan<- *LinkTokenApproval, owner []common.Address, spender []common.Address) (event.Subscription, error) { + + var ownerRule []interface{} + for _, ownerItem := range owner { + ownerRule = append(ownerRule, ownerItem) + } + var spenderRule []interface{} + for _, spenderItem := range spender { + spenderRule = append(spenderRule, spenderItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "Approval", ownerRule, spenderRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenApproval) + if err := _LinkToken.contract.UnpackLog(event, "Approval", 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 (_LinkToken *LinkTokenFilterer) ParseApproval(log types.Log) (*LinkTokenApproval, error) { + event := new(LinkTokenApproval) + if err := _LinkToken.contract.UnpackLog(event, "Approval", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenBurnAccessGrantedIterator struct { + Event *LinkTokenBurnAccessGranted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenBurnAccessGrantedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenBurnAccessGranted) + 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(LinkTokenBurnAccessGranted) + 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 *LinkTokenBurnAccessGrantedIterator) Error() error { + return it.fail +} + +func (it *LinkTokenBurnAccessGrantedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenBurnAccessGranted struct { + Burner common.Address + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterBurnAccessGranted(opts *bind.FilterOpts, burner []common.Address) (*LinkTokenBurnAccessGrantedIterator, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "BurnAccessGranted", burnerRule) + if err != nil { + return nil, err + } + return &LinkTokenBurnAccessGrantedIterator{contract: _LinkToken.contract, event: "BurnAccessGranted", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchBurnAccessGranted(opts *bind.WatchOpts, sink chan<- *LinkTokenBurnAccessGranted, burner []common.Address) (event.Subscription, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "BurnAccessGranted", burnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenBurnAccessGranted) + if err := _LinkToken.contract.UnpackLog(event, "BurnAccessGranted", 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 (_LinkToken *LinkTokenFilterer) ParseBurnAccessGranted(log types.Log) (*LinkTokenBurnAccessGranted, error) { + event := new(LinkTokenBurnAccessGranted) + if err := _LinkToken.contract.UnpackLog(event, "BurnAccessGranted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenBurnAccessRevokedIterator struct { + Event *LinkTokenBurnAccessRevoked + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenBurnAccessRevokedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenBurnAccessRevoked) + 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(LinkTokenBurnAccessRevoked) + 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 *LinkTokenBurnAccessRevokedIterator) Error() error { + return it.fail +} + +func (it *LinkTokenBurnAccessRevokedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenBurnAccessRevoked struct { + Burner common.Address + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterBurnAccessRevoked(opts *bind.FilterOpts, burner []common.Address) (*LinkTokenBurnAccessRevokedIterator, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "BurnAccessRevoked", burnerRule) + if err != nil { + return nil, err + } + return &LinkTokenBurnAccessRevokedIterator{contract: _LinkToken.contract, event: "BurnAccessRevoked", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchBurnAccessRevoked(opts *bind.WatchOpts, sink chan<- *LinkTokenBurnAccessRevoked, burner []common.Address) (event.Subscription, error) { + + var burnerRule []interface{} + for _, burnerItem := range burner { + burnerRule = append(burnerRule, burnerItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "BurnAccessRevoked", burnerRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenBurnAccessRevoked) + if err := _LinkToken.contract.UnpackLog(event, "BurnAccessRevoked", 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 (_LinkToken *LinkTokenFilterer) ParseBurnAccessRevoked(log types.Log) (*LinkTokenBurnAccessRevoked, error) { + event := new(LinkTokenBurnAccessRevoked) + if err := _LinkToken.contract.UnpackLog(event, "BurnAccessRevoked", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenMintAccessGrantedIterator struct { + Event *LinkTokenMintAccessGranted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenMintAccessGrantedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenMintAccessGranted) + 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(LinkTokenMintAccessGranted) + 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 *LinkTokenMintAccessGrantedIterator) Error() error { + return it.fail +} + +func (it *LinkTokenMintAccessGrantedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenMintAccessGranted struct { + Minter common.Address + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterMintAccessGranted(opts *bind.FilterOpts, minter []common.Address) (*LinkTokenMintAccessGrantedIterator, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "MintAccessGranted", minterRule) + if err != nil { + return nil, err + } + return &LinkTokenMintAccessGrantedIterator{contract: _LinkToken.contract, event: "MintAccessGranted", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchMintAccessGranted(opts *bind.WatchOpts, sink chan<- *LinkTokenMintAccessGranted, minter []common.Address) (event.Subscription, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "MintAccessGranted", minterRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenMintAccessGranted) + if err := _LinkToken.contract.UnpackLog(event, "MintAccessGranted", 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 (_LinkToken *LinkTokenFilterer) ParseMintAccessGranted(log types.Log) (*LinkTokenMintAccessGranted, error) { + event := new(LinkTokenMintAccessGranted) + if err := _LinkToken.contract.UnpackLog(event, "MintAccessGranted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenMintAccessRevokedIterator struct { + Event *LinkTokenMintAccessRevoked + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenMintAccessRevokedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenMintAccessRevoked) + 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(LinkTokenMintAccessRevoked) + 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 *LinkTokenMintAccessRevokedIterator) Error() error { + return it.fail +} + +func (it *LinkTokenMintAccessRevokedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenMintAccessRevoked struct { + Minter common.Address + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterMintAccessRevoked(opts *bind.FilterOpts, minter []common.Address) (*LinkTokenMintAccessRevokedIterator, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "MintAccessRevoked", minterRule) + if err != nil { + return nil, err + } + return &LinkTokenMintAccessRevokedIterator{contract: _LinkToken.contract, event: "MintAccessRevoked", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchMintAccessRevoked(opts *bind.WatchOpts, sink chan<- *LinkTokenMintAccessRevoked, minter []common.Address) (event.Subscription, error) { + + var minterRule []interface{} + for _, minterItem := range minter { + minterRule = append(minterRule, minterItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "MintAccessRevoked", minterRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenMintAccessRevoked) + if err := _LinkToken.contract.UnpackLog(event, "MintAccessRevoked", 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 (_LinkToken *LinkTokenFilterer) ParseMintAccessRevoked(log types.Log) (*LinkTokenMintAccessRevoked, error) { + event := new(LinkTokenMintAccessRevoked) + if err := _LinkToken.contract.UnpackLog(event, "MintAccessRevoked", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenOwnershipTransferRequestedIterator struct { + Event *LinkTokenOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenOwnershipTransferRequested) + 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(LinkTokenOwnershipTransferRequested) + 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 *LinkTokenOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *LinkTokenOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &LinkTokenOwnershipTransferRequestedIterator{contract: _LinkToken.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *LinkTokenOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenOwnershipTransferRequested) + if err := _LinkToken.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_LinkToken *LinkTokenFilterer) ParseOwnershipTransferRequested(log types.Log) (*LinkTokenOwnershipTransferRequested, error) { + event := new(LinkTokenOwnershipTransferRequested) + if err := _LinkToken.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenOwnershipTransferredIterator struct { + Event *LinkTokenOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenOwnershipTransferred) + 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(LinkTokenOwnershipTransferred) + 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 *LinkTokenOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *LinkTokenOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &LinkTokenOwnershipTransferredIterator{contract: _LinkToken.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *LinkTokenOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenOwnershipTransferred) + if err := _LinkToken.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 (_LinkToken *LinkTokenFilterer) ParseOwnershipTransferred(log types.Log) (*LinkTokenOwnershipTransferred, error) { + event := new(LinkTokenOwnershipTransferred) + if err := _LinkToken.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenTransferIterator struct { + Event *LinkTokenTransfer + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenTransferIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenTransfer) + 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(LinkTokenTransfer) + 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 *LinkTokenTransferIterator) Error() error { + return it.fail +} + +func (it *LinkTokenTransferIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenTransfer struct { + From common.Address + To common.Address + Value *big.Int + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenTransferIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "Transfer", fromRule, toRule) + if err != nil { + return nil, err + } + return &LinkTokenTransferIterator{contract: _LinkToken.contract, event: "Transfer", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchTransfer(opts *bind.WatchOpts, sink chan<- *LinkTokenTransfer, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "Transfer", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenTransfer) + if err := _LinkToken.contract.UnpackLog(event, "Transfer", 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 (_LinkToken *LinkTokenFilterer) ParseTransfer(log types.Log) (*LinkTokenTransfer, error) { + event := new(LinkTokenTransfer) + if err := _LinkToken.contract.UnpackLog(event, "Transfer", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type LinkTokenTransfer0Iterator struct { + Event *LinkTokenTransfer0 + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *LinkTokenTransfer0Iterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(LinkTokenTransfer0) + 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(LinkTokenTransfer0) + 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 *LinkTokenTransfer0Iterator) Error() error { + return it.fail +} + +func (it *LinkTokenTransfer0Iterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type LinkTokenTransfer0 struct { + From common.Address + To common.Address + Value *big.Int + Data []byte + Raw types.Log +} + +func (_LinkToken *LinkTokenFilterer) FilterTransfer0(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenTransfer0Iterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.FilterLogs(opts, "Transfer0", fromRule, toRule) + if err != nil { + return nil, err + } + return &LinkTokenTransfer0Iterator{contract: _LinkToken.contract, event: "Transfer0", logs: logs, sub: sub}, nil +} + +func (_LinkToken *LinkTokenFilterer) WatchTransfer0(opts *bind.WatchOpts, sink chan<- *LinkTokenTransfer0, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _LinkToken.contract.WatchLogs(opts, "Transfer0", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(LinkTokenTransfer0) + if err := _LinkToken.contract.UnpackLog(event, "Transfer0", 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 (_LinkToken *LinkTokenFilterer) ParseTransfer0(log types.Log) (*LinkTokenTransfer0, error) { + event := new(LinkTokenTransfer0) + if err := _LinkToken.contract.UnpackLog(event, "Transfer0", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_LinkToken *LinkToken) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _LinkToken.abi.Events["Approval"].ID: + return _LinkToken.ParseApproval(log) + case _LinkToken.abi.Events["BurnAccessGranted"].ID: + return _LinkToken.ParseBurnAccessGranted(log) + case _LinkToken.abi.Events["BurnAccessRevoked"].ID: + return _LinkToken.ParseBurnAccessRevoked(log) + case _LinkToken.abi.Events["MintAccessGranted"].ID: + return _LinkToken.ParseMintAccessGranted(log) + case _LinkToken.abi.Events["MintAccessRevoked"].ID: + return _LinkToken.ParseMintAccessRevoked(log) + case _LinkToken.abi.Events["OwnershipTransferRequested"].ID: + return _LinkToken.ParseOwnershipTransferRequested(log) + case _LinkToken.abi.Events["OwnershipTransferred"].ID: + return _LinkToken.ParseOwnershipTransferred(log) + case _LinkToken.abi.Events["Transfer"].ID: + return _LinkToken.ParseTransfer(log) + case _LinkToken.abi.Events["Transfer0"].ID: + return _LinkToken.ParseTransfer0(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (LinkTokenApproval) Topic() common.Hash { + return common.HexToHash("0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925") +} + +func (LinkTokenBurnAccessGranted) Topic() common.Hash { + return common.HexToHash("0x92308bb7573b2a3d17ddb868b39d8ebec433f3194421abc22d084f89658c9bad") +} + +func (LinkTokenBurnAccessRevoked) Topic() common.Hash { + return common.HexToHash("0x0a675452746933cefe3d74182e78db7afe57ba60eaa4234b5d85e9aa41b0610c") +} + +func (LinkTokenMintAccessGranted) Topic() common.Hash { + return common.HexToHash("0xe46fef8bbff1389d9010703cf8ebb363fb3daf5bf56edc27080b67bc8d9251ea") +} + +func (LinkTokenMintAccessRevoked) Topic() common.Hash { + return common.HexToHash("0xed998b960f6340d045f620c119730f7aa7995e7425c2401d3a5b64ff998a59e9") +} + +func (LinkTokenOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (LinkTokenOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (LinkTokenTransfer) Topic() common.Hash { + return common.HexToHash("0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef") +} + +func (LinkTokenTransfer0) Topic() common.Hash { + return common.HexToHash("0xe19260aff97b920c7df27010903aeb9c8d2be5d310a2c67824cf3f15396e4c16") +} + +func (_LinkToken *LinkToken) Address() common.Address { + return _LinkToken.address +} + +type LinkTokenInterface interface { + Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) + + BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) + + Decimals(opts *bind.CallOpts) (uint8, error) + + GetBurners(opts *bind.CallOpts) ([]common.Address, error) + + GetMinters(opts *bind.CallOpts) ([]common.Address, error) + + IsBurner(opts *bind.CallOpts, burner common.Address) (bool, error) + + IsMinter(opts *bind.CallOpts, minter common.Address) (bool, error) + + MaxSupply(opts *bind.CallOpts) (*big.Int, error) + + Name(opts *bind.CallOpts) (string, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) + + Symbol(opts *bind.CallOpts) (string, error) + + TotalSupply(opts *bind.CallOpts) (*big.Int, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) + + Burn(opts *bind.TransactOpts, amount *big.Int) (*types.Transaction, error) + + Burn0(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) + + BurnFrom(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) + + DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) + + DecreaseApproval(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) + + GrantBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) + + GrantMintAndBurnRoles(opts *bind.TransactOpts, burnAndMinter common.Address) (*types.Transaction, error) + + GrantMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) + + IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) + + IncreaseApproval(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) + + Mint(opts *bind.TransactOpts, account common.Address, amount *big.Int) (*types.Transaction, error) + + RevokeBurnRole(opts *bind.TransactOpts, burner common.Address) (*types.Transaction, error) + + RevokeMintRole(opts *bind.TransactOpts, minter common.Address) (*types.Transaction, error) + + Transfer(opts *bind.TransactOpts, to common.Address, amount *big.Int) (*types.Transaction, error) + + TransferAndCall(opts *bind.TransactOpts, to common.Address, amount *big.Int, data []byte) (*types.Transaction, error) + + TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*LinkTokenApprovalIterator, error) + + WatchApproval(opts *bind.WatchOpts, sink chan<- *LinkTokenApproval, owner []common.Address, spender []common.Address) (event.Subscription, error) + + ParseApproval(log types.Log) (*LinkTokenApproval, error) + + FilterBurnAccessGranted(opts *bind.FilterOpts, burner []common.Address) (*LinkTokenBurnAccessGrantedIterator, error) + + WatchBurnAccessGranted(opts *bind.WatchOpts, sink chan<- *LinkTokenBurnAccessGranted, burner []common.Address) (event.Subscription, error) + + ParseBurnAccessGranted(log types.Log) (*LinkTokenBurnAccessGranted, error) + + FilterBurnAccessRevoked(opts *bind.FilterOpts, burner []common.Address) (*LinkTokenBurnAccessRevokedIterator, error) + + WatchBurnAccessRevoked(opts *bind.WatchOpts, sink chan<- *LinkTokenBurnAccessRevoked, burner []common.Address) (event.Subscription, error) + + ParseBurnAccessRevoked(log types.Log) (*LinkTokenBurnAccessRevoked, error) + + FilterMintAccessGranted(opts *bind.FilterOpts, minter []common.Address) (*LinkTokenMintAccessGrantedIterator, error) + + WatchMintAccessGranted(opts *bind.WatchOpts, sink chan<- *LinkTokenMintAccessGranted, minter []common.Address) (event.Subscription, error) + + ParseMintAccessGranted(log types.Log) (*LinkTokenMintAccessGranted, error) + + FilterMintAccessRevoked(opts *bind.FilterOpts, minter []common.Address) (*LinkTokenMintAccessRevokedIterator, error) + + WatchMintAccessRevoked(opts *bind.WatchOpts, sink chan<- *LinkTokenMintAccessRevoked, minter []common.Address) (event.Subscription, error) + + ParseMintAccessRevoked(log types.Log) (*LinkTokenMintAccessRevoked, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *LinkTokenOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*LinkTokenOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *LinkTokenOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*LinkTokenOwnershipTransferred, error) + + FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenTransferIterator, error) + + WatchTransfer(opts *bind.WatchOpts, sink chan<- *LinkTokenTransfer, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseTransfer(log types.Log) (*LinkTokenTransfer, error) + + FilterTransfer0(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*LinkTokenTransfer0Iterator, error) + + WatchTransfer0(opts *bind.WatchOpts, sink chan<- *LinkTokenTransfer0, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseTransfer0(log types.Log) (*LinkTokenTransfer0, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt new file mode 100644 index 00000000000..b8a0f62f842 --- /dev/null +++ b/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -0,0 +1,3 @@ +GETH_VERSION: 1.12.0 +burn_mint_erc677: ../../../contracts/solc/v0.8.19/BurnMintERC677.abi ../../../contracts/solc/v0.8.19/BurnMintERC677.bin 405c9016171e614b17e10588653ef8d33dcea21dd569c3fddc596a46fcff68a3 +link_token: ../../../contracts/solc/v0.8.19/LinkToken.abi ../../../contracts/solc/v0.8.19/LinkToken.bin c0ef9b507103aae541ebc31d87d051c2764ba9d843076b30ec505d37cdfffaba diff --git a/core/gethwrappers/shared/go_generate.go b/core/gethwrappers/shared/go_generate.go new file mode 100644 index 00000000000..e4acb59e98c --- /dev/null +++ b/core/gethwrappers/shared/go_generate.go @@ -0,0 +1,6 @@ +// Package gethwrappers provides tools for wrapping solidity contracts with +// golang packages, using abigen. +package gethwrappers + +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/BurnMintERC677.abi ../../../contracts/solc/v0.8.19/BurnMintERC677.bin BurnMintERC677 burn_mint_erc677 +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/LinkToken.abi ../../../contracts/solc/v0.8.19/LinkToken.bin LinkToken link_token From 3d9ff561e25c9271dc595ac5f3c49d2f6fe001c8 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Tue, 22 Aug 2023 11:13:05 -0400 Subject: [PATCH 230/270] Bumped test dependencies (#10290) --- integration-tests/go.mod | 20 +++++----- integration-tests/go.sum | 41 ++++++++++---------- integration-tests/networks/known_networks.go | 4 +- 3 files changed, 33 insertions(+), 32 deletions(-) diff --git a/integration-tests/go.mod b/integration-tests/go.mod index db6932a3149..d394e36bc0a 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -17,21 +17,21 @@ require ( github.com/onsi/gomega v1.27.8 github.com/pelletier/go-toml/v2 v2.0.9 github.com/pkg/errors v0.9.1 - github.com/rs/zerolog v1.29.1 + github.com/rs/zerolog v1.30.0 github.com/slack-go/slack v0.12.2 github.com/smartcontractkit/chainlink-env v0.36.0 - github.com/smartcontractkit/chainlink-testing-framework v1.15.3 + github.com/smartcontractkit/chainlink-testing-framework v1.16.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 github.com/smartcontractkit/ocr2keepers v0.7.16 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 - github.com/smartcontractkit/wasp v0.2.9 + github.com/smartcontractkit/wasp v0.3.0 github.com/spf13/cobra v1.6.1 github.com/stretchr/testify v1.8.4 - github.com/testcontainers/testcontainers-go v0.22.0 + github.com/testcontainers/testcontainers-go v0.23.0 github.com/umbracle/ethgo v0.1.3 go.dedis.ch/kyber/v3 v3.1.0 - go.uber.org/zap v1.24.0 + go.uber.org/zap v1.25.0 golang.org/x/sync v0.3.0 gopkg.in/guregu/null.v4 v4.0.0 ) @@ -445,15 +445,15 @@ require ( go.uber.org/multierr v1.11.0 // indirect go.uber.org/ratelimit v0.2.0 // indirect golang.org/x/arch v0.4.0 // indirect - golang.org/x/crypto v0.11.0 // indirect + golang.org/x/crypto v0.12.0 // indirect golang.org/x/exp v0.0.0-20230713183714-613f0c0eb8a1 // indirect golang.org/x/lint v0.0.0-20210508222113-6edffad5e616 // indirect golang.org/x/mod v0.12.0 // indirect - golang.org/x/net v0.12.0 // indirect + golang.org/x/net v0.14.0 // indirect golang.org/x/oauth2 v0.10.0 // indirect - golang.org/x/sys v0.10.0 // indirect - golang.org/x/term v0.10.0 // indirect - golang.org/x/text v0.11.0 // indirect + golang.org/x/sys v0.11.0 // indirect + golang.org/x/term v0.11.0 // indirect + golang.org/x/text v0.12.0 // indirect golang.org/x/time v0.3.0 // indirect golang.org/x/tools v0.11.0 // indirect gomodules.xyz/jsonpatch/v2 v2.2.0 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index ddd8b070a86..ac9d7d94384 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2189,11 +2189,11 @@ github.com/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjR github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= github.com/rs/cors v1.8.3 h1:O+qNyWn7Z+F9M0ILBHgMVPuB1xTOucVd5gtaYyXBpRo= github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= -github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= +github.com/rs/xid v1.5.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= github.com/rs/zerolog v1.13.0/go.mod h1:YbFCdg8HfsridGWAh22vktObvhZbQsZXe4/zB0OKkWU= github.com/rs/zerolog v1.15.0/go.mod h1:xYTKnLHcpfU2225ny5qZjxnj9NvkumZYjJHlAThCjNc= -github.com/rs/zerolog v1.29.1 h1:cO+d60CHkknCbvzEWxP0S9K6KqyTjrCNUy1LdQLCGPc= -github.com/rs/zerolog v1.29.1/go.mod h1:Le6ESbR7hc+DP6Lt1THiV8CQSdkkNrd3R0XbEgp3ZBU= +github.com/rs/zerolog v1.30.0 h1:SymVODrcRsaRaSInD9yQtKbtWqwsfoPcRff/oRXLj4c= +github.com/rs/zerolog v1.30.0/go.mod h1:/tk+P47gFdPXq4QYjvCmT5/Gsug2nagsFWBWhAiSi1w= github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday v1.6.0 h1:KqfZb0pUVN2lYqZUYRddxF4OR8ZMURnJIG5Y3VRLtww= github.com/russross/blackfriday v1.6.0/go.mod h1:ti0ldHuxg49ri4ksnFxlkCfN+hvslNlmVHqNRXXJNAY= @@ -2247,8 +2247,8 @@ github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a8 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a/go.mod h1:LL+FLf10gOUHrF3aUsRGEZlT/w8DaW5T/eEo/54W68c= -github.com/smartcontractkit/chainlink-testing-framework v1.15.3 h1:phuO4wpbT3GR2ZFIzgwQ3DjfLaZwtHOvJkuEJOC8vxk= -github.com/smartcontractkit/chainlink-testing-framework v1.15.3/go.mod h1:m9p6TzNHs4SXfsS3MJHjTk2vF8jsqHb2ipSSYkjT6zs= +github.com/smartcontractkit/chainlink-testing-framework v1.16.0 h1:jLpqwqaTpJXQvTJ1IXTomcCToOdrSCe4+IGcLXGsmD0= +github.com/smartcontractkit/chainlink-testing-framework v1.16.0/go.mod h1:t6FJX3akEfAO31p96ru0ilNPfE9P2UshUlXTIkI58LM= github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472 h1:x3kNwgFlDmbE/n0gTSRMt9GBDfsfGrs4X9b9arPZtFI= github.com/smartcontractkit/go-plugin v0.0.0-20230605132010-0f4d515d1472/go.mod h1:6/1TEzT0eQznvI/gV2CM29DLSkAK/e58mUWKVsPaph0= github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJif132UCdjo8u43i7iPN1/MFnu49hv7lFGFftCHKU= @@ -2265,8 +2265,8 @@ github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300- github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= -github.com/smartcontractkit/wasp v0.2.9 h1:gIKuhRjdqQCj61OrdxqKZ2vAuXxs+PlibygYkFlP4l8= -github.com/smartcontractkit/wasp v0.2.9/go.mod h1:skquNdMbKxIrHi5O8Kyukf66AaaXuEpEEaSTxfHbhak= +github.com/smartcontractkit/wasp v0.3.0 h1:mueeLvpb6HyGNwILxCOKShDR6q18plQn7Gb1j3G/Qkk= +github.com/smartcontractkit/wasp v0.3.0/go.mod h1:skquNdMbKxIrHi5O8Kyukf66AaaXuEpEEaSTxfHbhak= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= @@ -2344,8 +2344,8 @@ github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125 h1:3SNcvBmEPE1YlB github.com/teris-io/shortid v0.0.0-20201117134242-e59966efd125/go.mod h1:M8agBzgqHIhgj7wEn9/0hJUZcrvt9VY+Ln+S1I5Mha0= github.com/test-go/testify v1.1.4 h1:Tf9lntrKUMHiXQ07qBScBTSA0dhYQlu83hswqelv1iE= github.com/test-go/testify v1.1.4/go.mod h1:rH7cfJo/47vWGdi4GPj16x3/t1xGOj2YxzmNQzk2ghU= -github.com/testcontainers/testcontainers-go v0.22.0 h1:hOK4NzNu82VZcKEB1aP9LO1xYssVFMvlfeuDW9JMmV0= -github.com/testcontainers/testcontainers-go v0.22.0/go.mod h1:k0YiPa26xJCRUbUkYqy5rY6NGvSbVCeUBXCvucscBR4= +github.com/testcontainers/testcontainers-go v0.23.0 h1:ERYTSikX01QczBLPZpqsETTBO7lInqEP349phDOVJVs= +github.com/testcontainers/testcontainers-go v0.23.0/go.mod h1:3gzuZfb7T9qfcH2pHpV4RLlWrPjeWNQah6XlYQ32c4I= github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a h1:YuO+afVc3eqrjiCUizNCxI53bl/BnPiVwXqLzqYTqgU= github.com/theodesp/go-heaps v0.0.0-20190520121037-88e35354fe0a/go.mod h1:/sfW47zCZp9FrtGcWyo1VjbgDaodxX9ovZvgLb/MxaA= github.com/thlib/go-timezone-local v0.0.0-20210907160436-ef149e42d28e h1:BuzhfgfWQbX0dWzYzT1zsORLnHRv3bcRcsaUk0VmXA8= @@ -2531,8 +2531,9 @@ go.uber.org/zap v1.14.0/go.mod h1:zwrFLgMcdUuIBviXEYEH1YKNaOBnKXsx2IPda5bBwHM= go.uber.org/zap v1.14.1/go.mod h1:Mb2vm2krFEG5DV0W9qcHBYFtp/Wku1cvYaqPsS/WYfc= go.uber.org/zap v1.15.0/go.mod h1:Mb2vm2krFEG5DV0W9qcHBYFtp/Wku1cvYaqPsS/WYfc= go.uber.org/zap v1.16.0/go.mod h1:MA8QOfq0BHJwdXa996Y4dYkAqRKB8/1K1QMMZVaNZjQ= -go.uber.org/zap v1.24.0 h1:FiJd5l1UOLj0wCgbSE0rwwXHzEdAZS6hiiSnxJN/D60= go.uber.org/zap v1.24.0/go.mod h1:2kMP+WWQ8aoFoedH3T2sq6iJ2yDWpHbP0f6MQbS9Gkg= +go.uber.org/zap v1.25.0 h1:4Hvk6GtkucQ790dqmj7l1eEnRdKm3k3ZUrUMS2d5+5c= +go.uber.org/zap v1.25.0/go.mod h1:JIAUzQIH94IC4fOJQm7gMmBJP5k7wQfdcnYdPoEXJYk= golang.org/x/arch v0.0.0-20210923205945-b76863e36670/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= golang.org/x/arch v0.4.0 h1:A8WCeEWhLwPBKNbFi5Wv5UTCBx5zzubnXDlMOFAzFMc= golang.org/x/arch v0.4.0/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= @@ -2577,8 +2578,8 @@ golang.org/x/crypto v0.0.0-20211108221036-ceb1ce70b4fa/go.mod h1:GvvjBRRGRdwPK5y golang.org/x/crypto v0.0.0-20220622213112-05595931fe9d/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.0.0-20221012134737-56aed061732a/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= golang.org/x/crypto v0.6.0/go.mod h1:OFC/31mSvZgRz0V1QTNCzfAI1aIRzbiufJtkMIlEp58= -golang.org/x/crypto v0.11.0 h1:6Ewdq3tDic1mg5xRO4milcWCfMVQhI4NkqWWvqejpuA= -golang.org/x/crypto v0.11.0/go.mod h1:xgJhtzW8F9jGdVFWZESrid1U1bjeNy4zgy5cRr/CIio= +golang.org/x/crypto v0.12.0 h1:tFM/ta59kqch6LlvYnPa0yx5a83cL2nHflFhYKvv9Yk= +golang.org/x/crypto v0.12.0/go.mod h1:NF0Gs7EO5K4qLn+Ylc+fih8BSTeIjAP05siRnAh98yw= golang.org/x/exp v0.0.0-20180321215751-8460e604b9de/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20180807140117-3d87b88a115f/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= @@ -2726,8 +2727,8 @@ golang.org/x/net v0.5.0/go.mod h1:DivGGAXEgPSlEBzxGzZI+ZLohi+xUj054jfeKui00ws= golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs= golang.org/x/net v0.8.0/go.mod h1:QVkue5JL9kW//ek3r6jTKnTFis1tRmNAW2P1shuFdJc= -golang.org/x/net v0.12.0 h1:cfawfvKITfUsFCeJIHJrbSxpeu/E81khclypR0GVT50= -golang.org/x/net v0.12.0/go.mod h1:zEVYFnQC7m/vmpQFELhcD1EWkZlX69l4oqgmer6hfKA= +golang.org/x/net v0.14.0 h1:BONx9s002vGdD9umnlX1Po8vOZmrgH34qlHcD1MfK14= +golang.org/x/net v0.14.0/go.mod h1:PpSgVXXLK0OxS0F31C1/tv6XNguvCrnXIDrFMspZIUI= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -2906,8 +2907,8 @@ golang.org/x/sys v0.4.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.10.0 h1:SqMFp9UcQJZa+pmYuAKjd9xq1f0j5rLcDIk0mj4qAsA= -golang.org/x/sys v0.10.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.11.0 h1:eG7RXZHdqOJ1i+0lgLgCpSXAp6M3LYlAo6osgSi0xOM= +golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20201210144234-2321bbc49cbf/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= @@ -2918,8 +2919,8 @@ golang.org/x/term v0.3.0/go.mod h1:q750SLmJuPmVoN1blW3UFBPREJfb1KmY3vwxfr+nFDA= golang.org/x/term v0.4.0/go.mod h1:9P2UbLfCdcvo3p/nzKvsmas4TnlujnuoV9hGgYzW1lQ= golang.org/x/term v0.5.0/go.mod h1:jMB1sMXY+tzblOD4FWmEbocvup2/aLOaQEp7JmGp78k= golang.org/x/term v0.6.0/go.mod h1:m6U89DPEgQRMq3DNkDClhWw02AUbt2daBVO4cn4Hv9U= -golang.org/x/term v0.10.0 h1:3R7pNqamzBraeqj/Tj8qt1aQ2HpmlC+Cx/qL/7hn4/c= -golang.org/x/term v0.10.0/go.mod h1:lpqdcUyK/oCiQxvxVrppt5ggO2KCZ5QblwqPnfZ6d5o= +golang.org/x/term v0.11.0 h1:F9tnn/DA/Im8nCwm+fX+1/eBwi4qFjRT++MhtVC4ZX0= +golang.org/x/term v0.11.0/go.mod h1:zC9APTIj3jG3FdV/Ons+XE1riIZXG4aZ4GTHiPZJPIU= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -2935,8 +2936,8 @@ golang.org/x/text v0.5.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.6.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.7.0/go.mod h1:mrYo+phRRbMaCq/xk9113O4dZlRixOauAjOtrjsXDZ8= golang.org/x/text v0.8.0/go.mod h1:e1OnstbJyHTd6l/uOt8jFFHp6TRDWZR/bV3emEE/zU8= -golang.org/x/text v0.11.0 h1:LAntKIrcmeSKERyiOh0XMV39LXS8IE9UL2yP7+f5ij4= -golang.org/x/text v0.11.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= +golang.org/x/text v0.12.0 h1:k+n5B8goJNdU7hSvEtMUz3d1Q6D/XW4COJSJR6fN0mc= +golang.org/x/text v0.12.0/go.mod h1:TvPlkZtksWOMsz7fbANvkp4WM8x/WCo/om8BMLbz+aE= golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= diff --git a/integration-tests/networks/known_networks.go b/integration-tests/networks/known_networks.go index a7b70a51763..2886f6c359d 100644 --- a/integration-tests/networks/known_networks.go +++ b/integration-tests/networks/known_networks.go @@ -546,7 +546,7 @@ func setURLs(prefix string, network *blockchain.EVMNetwork) { httpURLs := strings.Split(httpEnvURLs, ",") network.URLs = wsURLs network.HTTPURLs = httpURLs - log.Info().Interface(wsEnvVar, wsURLs).Interface(httpEnvVar, httpURLs).Msg("Read network URLs") + log.Info().Msg("Read network URLs") } // setKeys sets a network's private key(s) based on env vars @@ -573,5 +573,5 @@ func setKeys(prefix string, network *blockchain.EVMNetwork) { } keys := strings.Split(keysEnv, ",") network.PrivateKeys = keys - log.Info().Interface(envVar, keys).Msg("Read network Keys") + log.Info().Msg("Read network Keys") } From 1309826d49afc1ce455c183f20ebcd300d5effb6 Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Tue, 22 Aug 2023 11:37:08 -0400 Subject: [PATCH 231/270] update .nvmrc to match .tool-versions (#10289) --- .nvmrc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.nvmrc b/.nvmrc index 53a42214a46..f274881e5fd 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -v16.13.2 +v16.16.0 From 269e8f3b360fd49210cc2cd0411f3a433f77ab80 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Tue, 22 Aug 2023 12:00:10 -0400 Subject: [PATCH 232/270] release/2.4.0 -> develop (#10288) * Bump version and update CHANGELOG for core v2.4.0 * fix/changelog-simple-passwords: adding notification for upcoming breaking change wrt simple passwords in 2.5 (#10110) (cherry picked from commit 33f4e1a852da99f3a58f2b834533c495d095f874) * feature/simple-passwords-log: adding notification for upcoming configuration change error logs for insecure configs on secure builds * release/2.4.0-fix: updating CHANGELOG for simple passwords entry comments (#10165) * add evm transfer validation for eip1559 (#10196) * add transfer validation for eip1559 * evm-transfer-eip1559-validation-proposal - adding TxAmountWithFees to WrappedEvmEstimator * small renaming + fix mocks * fix dynamic fee + remove unnecessary check * rename GetCost -> GetMaxCost * address cleanup items + add test case for GetMaxCost --------- Co-authored-by: patrickhuie19 * add changelog for fix in #10196 (#10235) * add changelog for fix in #10196 * specify which flag for overriding in changelog * bug/2326-simple-passwords: re-enabling simple passwords restriction for prod (#10021) * bug/2326-simple-passwords: re-enabling simple passwords restriction for prod * strong password for tests --------- Co-authored-by: skudasov * fixing changelog * Finalize date on changelog for 2.4.0 --------- Co-authored-by: Patrick Co-authored-by: Sam Co-authored-by: Aaron Lu <50029043+aalu1418@users.noreply.github.com> Co-authored-by: skudasov --- core/cmd/shell.go | 12 ++++++++--- core/cmd/shell_local.go | 10 +++++++-- docs/CHANGELOG.md | 48 +++++++++++++++++++++++++---------------- 3 files changed, 46 insertions(+), 24 deletions(-) diff --git a/core/cmd/shell.go b/core/cmd/shell.go index 2ffdebe16e8..cc7562b2e6d 100644 --- a/core/cmd/shell.go +++ b/core/cmd/shell.go @@ -109,9 +109,15 @@ func (s *Shell) errorOut(err error) cli.ExitCoder { func (s *Shell) configExitErr(validateFn func() error) cli.ExitCoder { err := validateFn() if err != nil { - fmt.Println("Invalid configuration:", err) - fmt.Println() - return s.errorOut(errors.New("invalid configuration")) + if err.Error() != "invalid secrets: Database.AllowSimplePasswords: invalid value (true): insecure configs are not allowed on secure builds" { + fmt.Println("Invalid configuration:", err) + fmt.Println() + return s.errorOut(errors.New("invalid configuration")) + } else { + fmt.Printf("Notification for upcoming configuration change: %v\n", err) + fmt.Println("This configuration will be disallowed in future production releases.") + fmt.Println() + } } return nil } diff --git a/core/cmd/shell_local.go b/core/cmd/shell_local.go index 5d4eacb27ae..cd4f170523b 100644 --- a/core/cmd/shell_local.go +++ b/core/cmd/shell_local.go @@ -294,7 +294,10 @@ func (s *Shell) runNode(c *cli.Context) error { err := s.Config.Validate() if err != nil { - return errors.Wrap(err, "config validation failed") + if err.Error() != "invalid secrets: Database.AllowSimplePasswords: invalid value (true): insecure configs are not allowed on secure builds" { + return errors.Wrap(err, "config validation failed") + } + lggr.Errorf("Notification for upcoming configuration change: %v", err) } lggr.Infow(fmt.Sprintf("Starting Chainlink Node %s at commit %s", static.Version, static.Sha), "Version", static.Version, "SHA", static.Sha) @@ -634,7 +637,10 @@ func (s *Shell) RebroadcastTransactions(c *cli.Context) (err error) { err = s.Config.Validate() if err != nil { - return s.errorOut(fmt.Errorf("error validating configuration: %+v", err)) + if err.Error() != "invalid secrets: Database.AllowSimplePasswords: invalid value (true): insecure configs are not allowed on secure builds" { + return s.errorOut(fmt.Errorf("error validating configuration: %+v", err)) + } + lggr.Errorf("Notification for required upcoming configuration change: %v", err) } err = keyStore.Unlock(s.Config.Password().Keystore()) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 1bcbbe51b5e..2f787e14b2f 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,31 +9,36 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] -### Changed -- Simple passwords are no longer allowed for production builds + + +## 2.4.0 - 2023-08-21 -## 2.4.0 - UNRELEASED ### Fixed -- Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. + +- Updated `v2/keys/evm` and `v2/keys/eth` routes to return 400 and 404 status codes where appropriate. Previously 500s were returned when requested resources were not found or client requests could not be parsed. - Fixed withdrawing ETH from CL node for EIP1559 enabled chains. Previously would error out unless validation was overridden with `allowHigherAmounts`. ### Added + - Added the ability to specify and merge fields from multiple secrets files. Overrides of fields and keys are not allowed. -### Upcoming Breaking Change -- Starting in 2.5.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: +### Upcoming Required Configuration Change + +- Starting in 2.6.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: + ``` AllowSimplePasswords=true ``` -- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to RFC 3986 for special character escape rules. - +- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986) for special character escape rules. ## 2.3.0 - 2023-07-28 ### Added + - Add a new field called `Order` (range from 1 to 100) to `EVM.Nodes` that is used for the `PriorityLevel` node selector and also as a tie-breaker for `HighestHead` and `TotalDifficulty`. `Order` levels are considered in ascending order. If not defined it will default to `Order = 100` (last level). - Added new node selection mode called `PriorityLevel` for EVM, it is a tiered round-robin in ascending order of the`Order` field. Example: + ``` [EVM.NodePool] SelectionMode = 'PriorityLevel' @@ -42,8 +47,9 @@ SelectionMode = 'PriorityLevel' Name = '...' WSURL = '...' HTTPURL = '...' -Order = 5 +Order = 5 ``` + - The config keys `WebServer.StartTimeout` and `WebServer.HTTPMaxSize`. These keys respectively set a timeout for the node server to start and set the max request size for HTTP requests. Previously these attributes were set by `JobPipeline.DefaultHTTPLimit`/`JobPipeline.DefaultHTTPTimeout`. To migrate to these new fields, set their values to be identical to @@ -62,18 +68,20 @@ Order = 5 - Add two new config parameters `WebServer.ListenIP` and `WebServer.TLS.ListenIP` which allows binding Chainlink HTTP/HTTPS servers to a particular IP. The default is '0.0.0.0' which listens to all IP addresses (same behavior as before). Set to '127.0.0.1' to only allow connections from the local machine (this can be handy for local development). - Add several new metrics for mercury feeds, related to WSRPC connections: - - `mercury_transmit_timeout_count` - - `mercury_dial_count` - - `mercury_dial_success_count` - - `mercury_dial_error_count` - - `mercury_connection_reset_count` + - `mercury_transmit_timeout_count` + - `mercury_dial_count` + - `mercury_dial_success_count` + - `mercury_dial_error_count` + - `mercury_connection_reset_count` Node operators may wish to add alerting based around these metrics. ### Fixed + - Fixed a bug in the `nodes xxx list` command that caused results to not be displayed correctly ### Changed + - Assumption violations for MaxFeePerGas >= BaseFeePerGas and MaxFeePerGas >= MaxPriorityFeePerGas in EIP-1559 effective gas price calculation will now use a gas price if specified - Config validation now enforces protection against duplicate chain ids and node fields per provided TOML file. Duplicates accross multiple configuration files are still valid. If you have specified duplicate chain ids or nodes in a given configuration file, this change will error out of all `node` subcommands. - Restricted scope of the `Evm.GasEstimator.LimitJobType.OCR`, `OCR.DefaultTransactionQueueDepth`, and `OCR.SimulateTransactions` settings so they @@ -81,6 +89,7 @@ Node operators may wish to add alerting based around these metrics. want your settings to apply to OCR2. ### Removed + - Legacy chain types Optimism and Optimism2. OptimismBedrock is now used to handle Optimism's special cases. - Optimism Kovan configurations along with legacy error messages. @@ -91,16 +100,18 @@ Node operators may wish to add alerting based around these metrics. - New prometheus metric for mercury transmit queue: `mercury_transmit_queue_load`. This is a gauge, scoped by feed ID, that measures how many pending transmissions are in the queue. This should generally speaking be small (< 10 or so). Nops may wish to add alerting if this exceeds some amount. - Experimental support of runtime process isolation for Solana data feeds. Requires plugin binaries to be installed and configured via the env vars `CL_SOLANA_CMD` and `CL_MEDIAN_CMD`. See [plugins/README.md](../plugins/README.md). + ### Fixed - Fixed a bug which made it impossible to re-send the same transaction after abandoning it while manually changing the nonce. ### Changed + - Set default for EVM.GasEstimator.BumpTxDepth to EVM.Transactions.MaxInFlight. - Bumped batch size defaults for EVM specific configuration. If you are overriding any of these fields in your local config, please consider if it is necessary: - - `LogBackfillBatchSize = 1000` - - `RPCDefaultBatchSize = 250` - - `GasEstimator.BatchSize = 25` + - `LogBackfillBatchSize = 1000` + - `RPCDefaultBatchSize = 250` + - `GasEstimator.BatchSize = 25` - Dropped support for Development Mode configuration. `CL_DEV` is now ignored on production builds. - Updated Docker image's PostgreSQL client (used for backups) to v15 in order to support PostgreSQL v15 servers. @@ -1871,8 +1882,7 @@ transactions that started hitting this limit and instead continue to resubmit at the highest price that worked. Node operators should check their geth nodes and remove this cap if configured, -you can do this by running your geth node with `--rpc.gascap=0 ---rpc.txfeecap=0` or setting these values in your config toml. +you can do this by running your geth node with `--rpc.gascap=0 --rpc.txfeecap=0` or setting these values in your config toml. - Make head backfill asynchronous. This should eliminate some harmless but annoying errors related to backfilling heads, logged on startup and From db6f9e546eb8f645319b44d566184b55bd70e071 Mon Sep 17 00:00:00 2001 From: Anirudh Warrier Date: Tue, 22 Aug 2023 21:43:17 +0530 Subject: [PATCH 233/270] [AUTO-4617] enable automation v2.1 basic smoke tests (#10291) * enable automation 21 basic smoke tests * increase nodes for automation ci tests --- .github/workflows/integration-tests.yml | 2 +- integration-tests/smoke/automation_test.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index eeb0f190794..113bcbc57a7 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -156,7 +156,7 @@ jobs: matrix: product: - name: automation - nodes: 9 + nodes: 11 os: ubuntu-latest pyroscope_env: ci-smoke-automation-evm-simulated # temporarily disabled diff --git a/integration-tests/smoke/automation_test.go b/integration-tests/smoke/automation_test.go index 88a1a1eae44..ab757afe87a 100644 --- a/integration-tests/smoke/automation_test.go +++ b/integration-tests/smoke/automation_test.go @@ -104,8 +104,8 @@ func SetupAutomationBasic(t *testing.T, nodeUpgrade bool) { registryVersions := map[string]ethereum.KeeperRegistryVersion{ "registry_2_0": ethereum.RegistryVersion_2_0, - //"registry_2_1_conditional": ethereum.RegistryVersion_2_1, - //"registry_2_1_logtrigger": ethereum.RegistryVersion_2_1, + "registry_2_1_conditional": ethereum.RegistryVersion_2_1, + "registry_2_1_logtrigger": ethereum.RegistryVersion_2_1, } for name, registryVersion := range registryVersions { From c65f75d037b22a81c6f52a187091424240917781 Mon Sep 17 00:00:00 2001 From: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Date: Tue, 22 Aug 2023 11:53:42 -0500 Subject: [PATCH 234/270] Updated codeowners & added config warning comment (#10106) * updated codeowners & added config warning comment * Update CODEOWNERS --- CODEOWNERS | 18 +++++++++++++----- .../functions/config/config_types.proto | 2 ++ 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/CODEOWNERS b/CODEOWNERS index 84039a72266..2b2fb18443a 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -46,8 +46,16 @@ /core/services/webhook @samsondav -# Chainlink Functions related services -core/services/ocr2/plugins/functions @bolekk @justinkaseman @KuphJr @pinebit +# Chainlink Functions +core/services/functions @smartcontractkit/functions +core/services/ocr2/plugins/functions @smartcontractkit/functions +core/services/s4 @pinebit @bolekk +core/service/ocr2/plugins/s4 @pinebit @bolekk +core/services/ocr2/plugins/threshold @KuphJr @bolekk +core/services/relay/evm/functions.go @bolekk @justinkaseman @KuphJr +core/services/relay/evm/functions @bolekk @justinkaseman @KuphJr +core/scripts/functions @smartcontractkit/functions +core/scripts/gateway @bolekk @pinebit # API /core/web @jkongie @@ -62,8 +70,9 @@ core/services/ocr2/plugins/functions @bolekk @justinkaseman @KuphJr @pinebit /contracts/ @se3000 @connorwstein /contracts/**/*Keeper* @smartcontractkit/keepers /contracts/**/*Upkeep* @smartcontractkit/keepers -/contracts/**/*Functions* @bolekk @justinkaseman @KuphJr @pinebit -/contracts/src/v0.8/functions @bolekk @justinkaseman @KuphJr @pinebit +/contracts/**/*Functions* @smartcontractkit/functions +/contracts/src/v0.8/functions @smartcontractkit/functions +contracts/test/v0.8/functions @smartcontractkit/functions /contracts/src/v0.8/llo-feeds @austinborn @Fletch153 # Tests @@ -71,7 +80,6 @@ core/services/ocr2/plugins/functions @bolekk @justinkaseman @KuphJr @pinebit /integration-tests/**/*keeper* @smartcontractkit/keepers /integration-tests/**/*automation* @smartcontractkit/keepers - # CI/CD /.github/** @chainchad @javuto @jkongie @jmank88 @samsondav /.github/workflows/integration-tests.yml @smartcontractkit/test-tooling-team diff --git a/core/services/ocr2/plugins/functions/config/config_types.proto b/core/services/ocr2/plugins/functions/config/config_types.proto index bdba9843207..095a9c3ce62 100644 --- a/core/services/ocr2/plugins/functions/config/config_types.proto +++ b/core/services/ocr2/plugins/functions/config/config_types.proto @@ -4,6 +4,8 @@ option go_package = "core/services/ocr2/plugins/functions/config"; package functions_config_types; +// WARNING: Any changes to protobufs must also be reflected in Gauntlet which is used to generate the OCR plugin config for production deployments + enum AggregationMethod { AGGREGATION_MODE = 0; AGGREGATION_MEDIAN = 1; From 20ef0b43cdd06db98a896498e098d4bf800697ec Mon Sep 17 00:00:00 2001 From: Ryan Hall Date: Tue, 22 Aug 2023 12:59:25 -0400 Subject: [PATCH 235/270] prefer Inputs.pack in automation packer (#10257) --- .../dev/automation/2_1/AutomationUtils2_1.sol | 12 +++++----- core/internal/cltest/simulated_backend.go | 2 +- .../ocr2keeper/evm21/encoding/packer.go | 5 ++--- .../ocr2keeper/evm21/encoding/packer_test.go | 22 +++++++++++++++++++ 4 files changed, 31 insertions(+), 10 deletions(-) diff --git a/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol b/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol index cf2dd34fdfa..3de56b6a1d0 100644 --- a/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol +++ b/contracts/src/v0.8/dev/automation/2_1/AutomationUtils2_1.sol @@ -26,15 +26,15 @@ contract AutomationUtils2_1 { /** * @dev this can be removed as OnchainConfig is now exposed directly from the registry */ - function _onChainConfig(KeeperRegistryBase2_1.OnchainConfig memory) external {} + function _onChainConfig(KeeperRegistryBase2_1.OnchainConfig memory) external {} // 0x2ff92a81 - function _report(KeeperRegistryBase2_1.Report memory) external {} + function _report(KeeperRegistryBase2_1.Report memory) external {} // 0xe65d6546 - function _logTriggerConfig(LogTriggerConfig memory) external {} + function _logTriggerConfig(LogTriggerConfig memory) external {} // 0x21f373d7 - function _logTrigger(KeeperRegistryBase2_1.LogTrigger memory) external {} + function _logTrigger(KeeperRegistryBase2_1.LogTrigger memory) external {} // 0x1c8d8260 - function _conditionalTrigger(KeeperRegistryBase2_1.ConditionalTrigger memory) external {} + function _conditionalTrigger(KeeperRegistryBase2_1.ConditionalTrigger memory) external {} // 0x4b6df294 - function _log(Log memory) external {} + function _log(Log memory) external {} // 0xe9720a49 } diff --git a/core/internal/cltest/simulated_backend.go b/core/internal/cltest/simulated_backend.go index 177bfc25ce7..9a3dcfd5184 100644 --- a/core/internal/cltest/simulated_backend.go +++ b/core/internal/cltest/simulated_backend.go @@ -73,7 +73,7 @@ func NewApplicationWithConfigV2AndKeyOnSimulatedBlockchain( return NewApplicationWithConfigAndKey(t, cfg, flagsAndDeps...) } -// Mine forces the simulated backend to produce a new block every 2 seconds +// Mine forces the simulated backend to produce a new block every X seconds func Mine(backend *backends.SimulatedBackend, blockTime time.Duration) (stopMining func()) { timer := time.NewTicker(blockTime) chStop := make(chan struct{}) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go index e3d44cdef86..c710b31291f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer.go @@ -128,12 +128,11 @@ func (p *abiPacker) UnpackLogTriggerConfig(raw []byte) (automation_utils_2_1.Log // PackReport packs the report with abi definitions from the contract. func (p *abiPacker) PackReport(report automation_utils_2_1.KeeperRegistryBase21Report) ([]byte, error) { - bts, err := p.utilsAbi.Pack("_report", &report) + bts, err := p.utilsAbi.Methods["_report"].Inputs.Pack(&report) if err != nil { return nil, fmt.Errorf("%w: failed to pack report", err) } - - return bts[4:], nil + return bts, nil } // UnpackReport unpacks the report from the given raw data. diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go index a6b7d504d58..ccc84765baa 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/packer_test.go @@ -11,7 +11,9 @@ import ( "github.com/ethereum/go-ethereum/common/hexutil" ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" automation21Utils "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_utils_2_1" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" @@ -333,6 +335,26 @@ func TestPacker_UnpackLogTriggerConfig(t *testing.T) { } } +func TestPacker_PackReport_UnpackReport(t *testing.T) { + report := automation_utils_2_1.KeeperRegistryBase21Report{ + FastGasWei: big.NewInt(1), + LinkNative: big.NewInt(1), + UpkeepIds: []*big.Int{big.NewInt(1), big.NewInt(2)}, + GasLimits: []*big.Int{big.NewInt(100), big.NewInt(200)}, + Triggers: [][]byte{{1, 2, 3, 4}, {5, 6, 7, 8}}, + PerformDatas: [][]byte{{5, 6, 7, 8}, {1, 2, 3, 4}}, + } + packer, err := newPacker() + require.NoError(t, err) + res, err := packer.PackReport(report) + require.NoError(t, err) + report2, err := packer.UnpackReport(res) + require.NoError(t, err) + assert.Equal(t, report, report2) + expected := "0x00000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000c00000000000000000000000000000000000000000000000000000000000000120000000000000000000000000000000000000000000000000000000000000018000000000000000000000000000000000000000000000000000000000000002600000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000006400000000000000000000000000000000000000000000000000000000000000c800000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000000000000000000000000000040000000000000000000000000000000000000000000000000000000000000008000000000000000000000000000000000000000000000000000000000000000040102030400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000405060708000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000002000000000000000000000000000000000000000000000000000000000000004000000000000000000000000000000000000000000000000000000000000000800000000000000000000000000000000000000000000000000000000000000004050607080000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040102030400000000000000000000000000000000000000000000000000000000" + assert.Equal(t, hexutil.Encode(res), expected) +} + func newPacker() (*abiPacker, error) { keepersABI, err := abi.JSON(strings.NewReader(iregistry21.IKeeperRegistryMasterABI)) if err != nil { From 8f535976ca1393b21546223ef09ca191519e69ab Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Tue, 22 Aug 2023 14:59:52 -0400 Subject: [PATCH 236/270] rename registry check pipeline (#10301) --- .../{regsitry_check_pipeline.go => registry_check_pipeline.go} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename core/services/ocr2/plugins/ocr2keeper/evm21/{regsitry_check_pipeline.go => registry_check_pipeline.go} (100%) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/regsitry_check_pipeline.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry_check_pipeline.go similarity index 100% rename from core/services/ocr2/plugins/ocr2keeper/evm21/regsitry_check_pipeline.go rename to core/services/ocr2/plugins/ocr2keeper/evm21/registry_check_pipeline.go From 02baac31a5ca441c28a727c81a76b0be3fa930ec Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Tue, 22 Aug 2023 15:21:18 -0400 Subject: [PATCH 237/270] [Functions] (test): Initial structure for foundry tests (#10140) * (test): Initial structure for foundry tests & setup * Suggested changes * update gas snapshot --- .../gas-snapshots/functions.gas-snapshot | 8 +- .../v0.8/functions/tests/1_0_0/BaseTest.t.sol | 12 +- .../tests/1_0_0/FunctionsClient.t.sol | 22 ++ .../tests/1_0_0/FunctionsCoordinator.t.sol | 219 ++++++++++++++++ .../tests/1_0_0/FunctionsRequest.t.sol | 47 ++++ .../tests/1_0_0/FunctionsRouter.t.sol | 233 ++++++++++++------ .../tests/1_0_0/FunctionsSubscriptions.t.sol | 188 ++++++++++++++ .../FunctionsTermsOfServiceAllowList.t.sol | 52 ++++ .../v0.8/functions/tests/1_0_0/Setup.t.sol | 102 ++++++++ .../FunctionsClientWithEmptyCallback.sol | 7 +- 10 files changed, 799 insertions(+), 91 deletions(-) create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/FunctionsClient.t.sol create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/FunctionsCoordinator.t.sol create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/FunctionsRequest.t.sol create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/FunctionsSubscriptions.t.sol create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/FunctionsTermsOfServiceAllowList.t.sol create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/Setup.t.sol diff --git a/contracts/gas-snapshots/functions.gas-snapshot b/contracts/gas-snapshots/functions.gas-snapshot index bda023cf117..b0a733f39c8 100644 --- a/contracts/gas-snapshots/functions.gas-snapshot +++ b/contracts/gas-snapshots/functions.gas-snapshot @@ -8,4 +8,10 @@ FunctionsOracle_setRegistry:testOnlyOwnerReverts() (gas: 10927) FunctionsOracle_setRegistry:testSetRegistrySuccess() (gas: 35791) FunctionsOracle_setRegistry:testSetRegistry_gas() (gas: 31987) FunctionsOracle_typeAndVersion:testTypeAndVersionSuccess() (gas: 6905) -FunctionsRouter_createSubscription:testCreateSubscriptionSuccess() (gas: 111376) \ No newline at end of file +FunctionsRouter_Pause:test_Pause_RevertIfNotOwner() (gas: 13293) +FunctionsRouter_Pause:test_Pause_Success() (gas: 20205) +FunctionsRouter_Unpause:test_Unpause_RevertIfNotOwner() (gas: 13338) +FunctionsRouter_Unpause:test_Unpause_Success() (gas: 77279) +FunctionsSubscriptions_createSubscription:test_CreateSubscription_RevertIfNotAllowedSender() (gas: 26347) +FunctionsSubscriptions_createSubscription:test_CreateSubscription_RevertIfPaused() (gas: 15699) +FunctionsSubscriptions_createSubscription:test_CreateSubscription_Success() (gas: 152436) diff --git a/contracts/src/v0.8/functions/tests/1_0_0/BaseTest.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/BaseTest.t.sol index 51faad52666..13994f88f71 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/BaseTest.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/BaseTest.t.sol @@ -4,14 +4,18 @@ import {Test} from "forge-std/Test.sol"; contract BaseTest is Test { bool private s_baseTestInitialized; - address internal constant OWNER = 0x00007e64E1fB0C487F25dd6D3601ff6aF8d32e4e; + + uint256 internal OWNER_PRIVATE_KEY = 0x1; + address internal OWNER_ADDRESS = vm.addr(OWNER_PRIVATE_KEY); + + uint256 internal STRANGER_PRIVATE_KEY = 0x2; + address internal STRANGER_ADDRESS = vm.addr(STRANGER_PRIVATE_KEY); function setUp() public virtual { // BaseTest.setUp is often called multiple times from tests' setUp due to inheritance. if (s_baseTestInitialized) return; s_baseTestInitialized = true; - - // Set msg.sender to OWNER until changePrank or stopPrank is called - vm.startPrank(OWNER); + // Set msg.sender to OWNER until stopPrank is called + vm.startPrank(OWNER_ADDRESS); } } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsClient.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsClient.t.sol new file mode 100644 index 00000000000..b2740b7e297 --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsClient.t.sol @@ -0,0 +1,22 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +/// @notice #constructor +contract FunctionsClient_Constructor { + +} + +/// @notice #_sendRequest +contract FunctionsClient__SendRequest { + +} + +/// @notice #fulfillRequest +contract FunctionsClient_FulfillRequest { + +} + +/// @notice #handleOracleFulfillment +contract FunctionsClient_HandleOracleFulfillment { + +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsCoordinator.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsCoordinator.t.sol new file mode 100644 index 00000000000..c6d560fffc6 --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsCoordinator.t.sol @@ -0,0 +1,219 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +// ================================================================ +// | Functions Coordinator | +// ================================================================ + +/// @notice #constructor +contract FunctionsCoordinator_Constructor { + +} + +/// @notice #getThresholdPublicKey +contract FunctionsCoordinator_GetThresholdPublicKey { + +} + +/// @notice #setThresholdPublicKey +contract FunctionsCoordinator_SetThresholdPublicKey { + +} + +/// @notice #getDONPublicKey +contract FunctionsCoordinator_GetDONPublicKey { + +} + +/// @notice #setDONPublicKey +contract FunctionsCoordinator__SetDONPublicKey { + +} + +/// @notice #_isTransmitter +contract FunctionsCoordinator_IsTransmitter { + +} + +/// @notice #setNodePublicKey +contract FunctionsCoordinator_SetNodePublicKey { + +} + +/// @notice #deleteNodePublicKey +contract FunctionsCoordinator_DeleteNodePublicKey { + +} + +/// @notice #getAllNodePublicKeys +contract FunctionsCoordinator_GetAllNodePublicKeys { + +} + +/// @notice #startRequest +contract FunctionsCoordinator_StartRequest { + +} + +/// @notice #_beforeSetConfig +contract FunctionsCoordinator__BeforeSetConfig { + +} + +/// @notice #_getTransmitters +contract FunctionsCoordinator__GetTransmitters { + +} + +/// @notice #_report +contract FunctionsCoordinator__Report { + +} + +/// @notice #_onlyOwner +contract FunctionsCoordinator__OnlyOwner { + +} + +// ================================================================ +// | Functions Billing | +// ================================================================ + +/// @notice #constructor +contract FunctionsBilling_Constructor { + +} + +/// @notice #getConfig +contract FunctionsBilling_GetConfig { + +} + +/// @notice #updateConfig +contract FunctionsBilling_UpdateConfig { + +} + +/// @notice #getDONFee +contract FunctionsBilling_GetDONFee { + +} + +/// @notice #getAdminFee +contract FunctionsBilling_GetAdminFee { + +} + +/// @notice #getWeiPerUnitLink +contract FunctionsBilling_GetWeiPerUnitLink { + +} + +/// @notice #_getJuelsPerGas +contract FunctionsBilling__GetJuelsPerGas { + +} + +/// @notice #estimateCost +contract FunctionsBilling_EstimateCost { + +} + +/// @notice #_calculateCostEstimate +contract FunctionsBilling__CalculateCostEstimate { + +} + +/// @notice #_startBilling +contract FunctionsBilling__StartBilling { + +} + +/// @notice #_computeRequestId +contract FunctionsBilling__ComputeRequestId { + +} + +/// @notice #_fulfillAndBill +contract FunctionsBilling__FulfillAndBill { + +} + +/// @notice #deleteCommitment +contract FunctionsBilling_DeleteCommitment { + +} + +/// @notice #oracleWithdraw +contract FunctionsBilling_OracleWithdraw { + +} + +/// @notice #oracleWithdrawAll +contract FunctionsBilling_OracleWithdrawAll { + +} + +/// @notice #_getTransmitters +contract FunctionsBilling__GetTransmitters { + +} + +/// @notice #_disperseFeePool +contract FunctionsBilling__DisperseFeePool { + +} + +// ================================================================ +// | OCR2Base | +// ================================================================ + +/// @notice #constructor +contract OCR2Base_Constructor { + +} + +/// @notice #checkConfigValid +contract OCR2Base_CheckConfigValid { + +} + +/// @notice #latestConfigDigestAndEpoch +contract OCR2Base_LatestConfigDigestAndEpoch { + +} + +/// @notice #setConfig +contract OCR2Base_SetConfig { + +} + +/// @notice #configDigestFromConfigData +contract OCR2Base_ConfigDigestFromConfigData { + +} + +/// @notice #latestConfigDetails +contract OCR2Base_LatestConfigDetails { + +} + +/// @notice #transmitters +contract OCR2Base_Transmitters { + +} + +/// @notice #_report +contract OCR2Base__Report { + +} + +/// @notice #requireExpectedMsgDataLength +contract OCR2Base_RequireExpectedMsgDataLength { + +} + +/// @notice #transmit +contract OCR2Base_Transmit { + +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRequest.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRequest.t.sol new file mode 100644 index 00000000000..a274bbe8cfc --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRequest.t.sol @@ -0,0 +1,47 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +/// @notice #REQUEST_DATA_VERSION +contract FunctionsRequest_REQUEST_DATA_VERSION { + +} + +/// @notice #DEFAULT_BUFFER_SIZE +contract FunctionsRequest_DEFAULT_BUFFER_SIZE { + +} + +/// @notice #encodeCBOR +contract FunctionsRequest_EncodeCBOR { + +} + +/// @notice #initializeRequest +contract FunctionsRequest_InitializeRequest { + +} + +/// @notice #initializeRequestForInlineJavaScript +contract FunctionsRequest_InitializeRequestForInlineJavaScript { + +} + +/// @notice #addSecretsReference +contract FunctionsRequest_AddSecretsReference { + +} + +/// @notice #addDONHostedSecrets +contract FunctionsRequest_AddDONHostedSecrets { + +} + +/// @notice #setArgs +contract FunctionsRequest_SetArgs { + +} + +/// @notice #setBytesArgs +contract FunctionsRequest_SetBytesArgs { + +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol index e6cd87b0aa4..649c06f9eed 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsRouter.t.sol @@ -1,110 +1,179 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.0; +pragma solidity ^0.8.19; -import {IFunctionsRouter} from "../../dev/1_0_0/interfaces/IFunctionsRouter.sol"; -import {IFunctionsBilling} from "../../dev/1_0_0/interfaces/IFunctionsBilling.sol"; -import {ITermsOfServiceAllowList} from "../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; - -import {BaseTest} from "./BaseTest.t.sol"; import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; -import {FunctionsCoordinator} from "../../dev/1_0_0/FunctionsCoordinator.sol"; -import {FunctionsBilling} from "../../dev/1_0_0/FunctionsBilling.sol"; -import {MockV3Aggregator} from "../../../tests/MockV3Aggregator.sol"; -import {TermsOfServiceAllowList} from "../../dev/1_0_0/accessControl/TermsOfServiceAllowList.sol"; +import {FunctionsSubscriptions} from "../../dev/1_0_0/FunctionsSubscriptions.sol"; -contract FunctionsRouterSetup is BaseTest { - FunctionsRouter internal s_functionsRouter; - FunctionsCoordinator internal s_functionsCoordinator; - MockV3Aggregator internal s_linkEthFeed; - TermsOfServiceAllowList internal s_termsOfServiceAllowList; +import {FunctionsRouterSetup, FunctionsOwnerAcceptTermsOfService} from "./Setup.t.sol"; - uint16 internal s_maxConsumersPerSubscription = 100; - uint72 internal s_adminFee = 561724823; - bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; +// ================================================================ +// | Functions Router | +// ================================================================ - address internal s_linkToken = 0x01BE23585060835E02B77ef475b0Cc51aA1e0709; +/// @notice #constructor +contract FunctionsRouter_Constructor { - int256 internal LINK_ETH_RATE = 5021530000000000; +} - function setUp() public virtual override { - BaseTest.setUp(); - s_functionsRouter = new FunctionsRouter(s_linkToken, getRouterConfig()); - s_linkEthFeed = new MockV3Aggregator(0, LINK_ETH_RATE); +/// @notice #getConfig +contract FunctionsRouter_GetConfig { - s_termsOfServiceAllowList = new TermsOfServiceAllowList(getTermsOfServiceConfig()); - } +} - function getRouterConfig() public view returns (FunctionsRouter.Config memory) { - uint32[] memory maxCallbackGasLimits = new uint32[](1); - maxCallbackGasLimits[0] = type(uint32).max; - - return - FunctionsRouter.Config({ - maxConsumersPerSubscription: s_maxConsumersPerSubscription, - adminFee: s_adminFee, - handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, - maxCallbackGasLimits: maxCallbackGasLimits, - gasForCallExactCheck: 5000 - }); - } +/// @notice #updateConfig +contract FunctionsRouter_UpdateConfig { - function getCoordinatorConfig() public pure returns (FunctionsBilling.Config memory) { - return - FunctionsBilling.Config({ - maxCallbackGasLimit: 5, - feedStalenessSeconds: 5, - gasOverheadAfterCallback: 5, - gasOverheadBeforeCallback: 5, - requestTimeoutSeconds: 1, - donFee: 5, - maxSupportedRequestDataVersion: 5, - fulfillmentGasPriceOverEstimationBP: 5, - fallbackNativePerUnitLink: 2874 - }); - } +} + +/// @notice #isValidCallbackGasLimit +contract FunctionsRouter_IsValidCallbackGasLimit { + +} + +/// @notice #getAdminFee +contract FunctionsRouter_GetAdminFee { + +} + +/// @notice #getAllowListId +contract FunctionsRouter_GetAllowListId { + +} + +/// @notice #setAllowListId +contract FunctionsRouter_SetAllowListId { + +} + +/// @notice #_getMaxConsumers +contract FunctionsRouter__GetMaxConsumers { + +} + +/// @notice #sendRequest +contract FunctionsRouter_SendRequest { + +} + +/// @notice #sendRequestToProposed +contract FunctionsRouter_SendRequestToProposed { + +} + +/// @notice #_sendRequest +contract FunctionsRouter__SendRequest { + +} + +/// @notice #fulfill +contract FunctionsRouter_Fulfill { + +} + +/// @notice #_callback +contract FunctionsRouter__Callback { + +} + +/// @notice #getContractById +contract FunctionsRouter_GetContractById { + +} + +/// @notice #getProposedContractById +contract FunctionsRouter_GetProposedContractById { + +} + +/// @notice #getProposedContractSet +contract FunctionsRouter_GetProposedContractSet { + +} + +/// @notice #proposeContractsUpdate +contract FunctionsRouter_ProposeContractsUpdate { + +} + +/// @notice #updateContracts +contract FunctionsRouter_UpdateContracts { + +} + +/// @notice #_whenNotPaused +contract FunctionsRouter__WhenNotPaused { + +} + +/// @notice #_onlyRouterOwner +contract FunctionsRouter__OnlyRouterOwner { - function getTermsOfServiceConfig() public pure returns (TermsOfServiceAllowList.Config memory) { - return TermsOfServiceAllowList.Config({enabled: false, signerPublicKey: address(132)}); - } } -contract FunctionsSetRoutes is FunctionsRouterSetup { +/// @notice #_onlySenderThatAcceptedToS +contract FunctionsRouter__OnlySenderThatAcceptedToS { + +} + +/// @notice #pause +contract FunctionsRouter_Pause is FunctionsRouterSetup { function setUp() public virtual override { FunctionsRouterSetup.setUp(); - s_functionsCoordinator = new FunctionsCoordinator( - address(s_functionsRouter), - getCoordinatorConfig(), - address(s_linkEthFeed) - ); - - bytes32 allowListId = s_functionsRouter.getAllowListId(); - bytes32[] memory proposedContractSetIds = new bytes32[](2); - proposedContractSetIds[0] = bytes32("1"); - proposedContractSetIds[1] = allowListId; - address[] memory proposedContractSetAddresses = new address[](2); - proposedContractSetAddresses[0] = address(s_functionsCoordinator); - proposedContractSetAddresses[1] = address(s_termsOfServiceAllowList); - - s_functionsRouter.proposeContractsUpdate(proposedContractSetIds, proposedContractSetAddresses); - s_functionsRouter.updateContracts(); + } + + event Paused(address account); + + function test_Pause_RevertIfNotOwner() public { + // Send as stranger + vm.stopPrank(); + vm.startPrank(STRANGER_ADDRESS); + + vm.expectRevert("Only callable by owner"); + s_functionsRouter.pause(); + } + + function test_Pause_Success() public { + // topic0 (always checked), NOT topic1 (false), NOT topic2 (false), NOT topic3 (false), and data (true). + vm.expectEmit(false, false, false, true); + emit Paused(OWNER_ADDRESS); + + s_functionsRouter.pause(); + + bool isPaused = s_functionsRouter.paused(); + assertEq(isPaused, true); + + vm.expectRevert("Pausable: paused"); + s_functionsRouter.createSubscription(); } } -contract FunctionsRouter_createSubscription is FunctionsSetRoutes { +/// @notice #unpause +contract FunctionsRouter_Unpause is FunctionsRouterSetup { function setUp() public virtual override { - FunctionsSetRoutes.setUp(); + FunctionsRouterSetup.setUp(); + s_functionsRouter.pause(); } - event SubscriptionCreated(uint64 indexed subscriptionId, address owner); + event Unpaused(address account); - function testCreateSubscriptionSuccess() public { - vm.expectEmit(); - emit SubscriptionCreated(1, OWNER); + function test_Unpause_RevertIfNotOwner() public { + // Send as stranger + vm.stopPrank(); + vm.startPrank(STRANGER_ADDRESS); - s_functionsRouter.createSubscription(); + vm.expectRevert("Only callable by owner"); + s_functionsRouter.unpause(); + } + + function test_Unpause_Success() public { + // topic0 (always checked), NOT topic1 (false), NOT topic2 (false), NOT topic3 (false), and data (true). + vm.expectEmit(false, false, false, true); + emit Unpaused(OWNER_ADDRESS); + + s_functionsRouter.unpause(); - vm.expectEmit(); - emit SubscriptionCreated(2, OWNER); + bool isPaused = s_functionsRouter.paused(); + assertEq(isPaused, false); s_functionsRouter.createSubscription(); } diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsSubscriptions.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsSubscriptions.t.sol new file mode 100644 index 00000000000..ab77a33691d --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsSubscriptions.t.sol @@ -0,0 +1,188 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; +import {FunctionsSubscriptions} from "../../dev/1_0_0/FunctionsSubscriptions.sol"; + +import {FunctionsRouterSetup, FunctionsOwnerAcceptTermsOfService} from "./Setup.t.sol"; + +// ================================================================ +// | Functions Subscriptions | +// ================================================================ + +/// @notice #constructor +contract FunctionsSubscriptions_Constructor { + +} + +/// @notice #_markRequestInFlight +contract FunctionsSubscriptions__MarkRequestInFlight { + +} + +/// @notice #_pay +contract FunctionsSubscriptions__Pay { + +} + +/// @notice #ownerCancelSubscription +contract FunctionsSubscriptions_OwnerCancelSubscription { + +} + +/// @notice #recoverFunds +contract FunctionsSubscriptions_RecoverFunds { + +} + +/// @notice #oracleWithdraw +contract FunctionsSubscriptions_OracleWithdraw { + +} + +/// @notice #ownerWithdraw +contract FunctionsSubscriptions_OwnerWithdraw { + +} + +/// @notice #onTokenTransfer +contract FunctionsSubscriptions_OnTokenTransfer { + +} + +/// @notice #getTotalBalance +contract FunctionsSubscriptions_GetTotalBalance { + +} + +/// @notice #getSubscriptionCount +contract FunctionsSubscriptions_GetSubscriptionCount { + +} + +/// @notice #getSubscription +contract FunctionsSubscriptions_GetSubscription { + +} + +/// @notice #getConsumer +contract FunctionsSubscriptions_GetConsumer { + +} + +/// @notice #_isExistingSubscription +contract FunctionsSubscriptions__IsExistingSubscription { + +} + +/// @notice #_isAllowedConsumer +contract FunctionsSubscriptions__IsAllowedConsumer { + +} + +/// @notice #createSubscription +contract FunctionsSubscriptions_createSubscription is FunctionsOwnerAcceptTermsOfService { + function setUp() public virtual override { + FunctionsOwnerAcceptTermsOfService.setUp(); + } + + event SubscriptionCreated(uint64 indexed subscriptionId, address owner); + + function test_CreateSubscription_Success() public { + vm.expectEmit(true, false, false, true); + emit SubscriptionCreated(1, OWNER_ADDRESS); + uint64 firstCallSubscriptionId = s_functionsRouter.createSubscription(); + assertEq(firstCallSubscriptionId, 1); + + vm.expectEmit(true, false, false, true); + emit SubscriptionCreated(2, OWNER_ADDRESS); + uint64 secondCallSubscriptionId = s_functionsRouter.createSubscription(); + assertEq(secondCallSubscriptionId, 2); + + vm.expectEmit(true, false, false, true); + emit SubscriptionCreated(3, OWNER_ADDRESS); + uint64 thirdCallSubscriptionId = s_functionsRouter.createSubscription(); + assertEq(thirdCallSubscriptionId, 3); + } + + function test_CreateSubscription_RevertIfPaused() public { + s_functionsRouter.pause(); + + vm.expectRevert("Pausable: paused"); + s_functionsRouter.createSubscription(); + } + + function test_CreateSubscription_RevertIfNotAllowedSender() public { + // Send as stranger, who has not accepted Terms of Service + vm.stopPrank(); + vm.startPrank(STRANGER_ADDRESS); + + vm.expectRevert(abi.encodeWithSelector(FunctionsRouter.SenderMustAcceptTermsOfService.selector, STRANGER_ADDRESS)); + s_functionsRouter.createSubscription(); + } +} + +/// @notice #createSubscriptionWithConsumer +contract FunctionsSubscriptions_CreateSubscriptionWithConsumer { + +} + +/// @notice #proposeSubscriptionOwnerTransfer +contract FunctionsSubscriptions_ProposeSubscriptionOwnerTransfer { + +} + +/// @notice #acceptSubscriptionOwnerTransfer +contract FunctionsSubscriptions_AcceptSubscriptionOwnerTransfer { + +} + +/// @notice #removeConsumer +contract FunctionsSubscriptions_RemoveConsumer { + +} + +/// @notice #_getMaxConsumers +contract FunctionsSubscriptions__GetMaxConsumers { + +} + +/// @notice #addConsumer +contract FunctionsSubscriptions_AddConsumer { + +} + +/// @notice #cancelSubscription +contract FunctionsSubscriptions_CancelSubscription { + +} + +/// @notice #_cancelSubscriptionHelper +contract FunctionsSubscriptions__CancelSubscriptionHelper { + +} + +/// @notice #pendingRequestExists +contract FunctionsSubscriptions_PendingRequestExists { + +} + +/// @notice #setFlags +contract FunctionsSubscriptions_SetFlags { + +} + +/// @notice #getFlags +contract FunctionsSubscriptions_GetFlags { + +} + +/// @notice #timeoutRequests +contract FunctionsSubscriptions_TimeoutRequests { + +} + +/// @notice #_onlySubscriptionOwner +contract FunctionsSubscriptions__OnlySubscriptionOwner { + +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/FunctionsTermsOfServiceAllowList.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsTermsOfServiceAllowList.t.sol new file mode 100644 index 00000000000..af6fa6dcca5 --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/FunctionsTermsOfServiceAllowList.t.sol @@ -0,0 +1,52 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +/// @notice #constructor +contract FunctionsTermsOfServiceAllowList_Constructor { + +} + +/// @notice #getConfig +contract FunctionsTermsOfServiceAllowList_GetConfig { + +} + +/// @notice #updateConfig +contract FunctionsTermsOfServiceAllowList_UpdateConfig { + +} + +/// @notice #getMessage +contract FunctionsTermsOfServiceAllowList_GetMessage { + +} + +/// @notice #acceptTermsOfService +contract FunctionsTermsOfServiceAllowList_AcceptTermsOfService { + +} + +/// @notice #getAllAllowedSenders +contract FunctionsTermsOfServiceAllowList_GetAllAllowedSenders { + +} + +/// @notice #hasAccess +contract FunctionsTermsOfServiceAllowList_HasAccess { + +} + +/// @notice #isBlockedSender +contract FunctionsTermsOfServiceAllowList_IsBlockedSender { + +} + +/// @notice #blockSender +contract FunctionsTermsOfServiceAllowList_BlockSender { + +} + +/// @notice #unblockSender +contract FunctionsTermsOfServiceAllowList_UnblockSender { + +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/Setup.t.sol b/contracts/src/v0.8/functions/tests/1_0_0/Setup.t.sol new file mode 100644 index 00000000000..56addcabd79 --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/Setup.t.sol @@ -0,0 +1,102 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {BaseTest} from "./BaseTest.t.sol"; +import {FunctionsRouter} from "../../dev/1_0_0/FunctionsRouter.sol"; +import {FunctionsCoordinator} from "../../dev/1_0_0/FunctionsCoordinator.sol"; +import {FunctionsBilling} from "../../dev/1_0_0/FunctionsBilling.sol"; +import {MockV3Aggregator} from "../../../tests/MockV3Aggregator.sol"; +import {TermsOfServiceAllowList} from "../../dev/1_0_0/accessControl/TermsOfServiceAllowList.sol"; + +contract FunctionsRouterSetup is BaseTest { + FunctionsRouter internal s_functionsRouter; + FunctionsCoordinator internal s_functionsCoordinator; + MockV3Aggregator internal s_linkEthFeed; + TermsOfServiceAllowList internal s_termsOfServiceAllowList; + + uint16 internal s_maxConsumersPerSubscription = 100; + uint72 internal s_adminFee = 100; + bytes4 internal s_handleOracleFulfillmentSelector = 0x0ca76175; + + address internal s_linkToken = 0x01BE23585060835E02B77ef475b0Cc51aA1e0709; + + int256 internal LINK_ETH_RATE = 6000000000000000; + + uint256 internal TOS_SIGNER_PRIVATE_KEY = 0x3; + address internal TOS_SIGNER = vm.addr(TOS_SIGNER_PRIVATE_KEY); + + function setUp() public virtual override { + BaseTest.setUp(); + s_functionsRouter = new FunctionsRouter(s_linkToken, getRouterConfig()); + s_linkEthFeed = new MockV3Aggregator(0, LINK_ETH_RATE); + s_functionsCoordinator = new FunctionsCoordinator( + address(s_functionsRouter), + getCoordinatorConfig(), + address(s_linkEthFeed) + ); + s_termsOfServiceAllowList = new TermsOfServiceAllowList(getTermsOfServiceConfig()); + } + + function getRouterConfig() public view returns (FunctionsRouter.Config memory) { + uint32[] memory maxCallbackGasLimits = new uint32[](3); + maxCallbackGasLimits[0] = 300_000; + maxCallbackGasLimits[1] = 500_000; + maxCallbackGasLimits[2] = 1_000_000; + + return + FunctionsRouter.Config({ + maxConsumersPerSubscription: s_maxConsumersPerSubscription, + adminFee: s_adminFee, + handleOracleFulfillmentSelector: s_handleOracleFulfillmentSelector, + maxCallbackGasLimits: maxCallbackGasLimits, + gasForCallExactCheck: 5000 + }); + } + + function getCoordinatorConfig() public pure returns (FunctionsBilling.Config memory) { + return + FunctionsBilling.Config({ + maxCallbackGasLimit: 0, // NOTE: unused , TODO: remove + feedStalenessSeconds: 24 * 60 * 60, // 1 day + gasOverheadAfterCallback: 44_615, // TODO: update + gasOverheadBeforeCallback: 44_615, // TODO: update + requestTimeoutSeconds: 60 * 5, // 5 minutes + donFee: 100, + maxSupportedRequestDataVersion: 1, + fulfillmentGasPriceOverEstimationBP: 5000, + fallbackNativePerUnitLink: 5000000000000000 + }); + } + + function getTermsOfServiceConfig() public view returns (TermsOfServiceAllowList.Config memory) { + return TermsOfServiceAllowList.Config({enabled: true, signerPublicKey: TOS_SIGNER}); + } +} + +contract FunctionsSetupRoutes is FunctionsRouterSetup { + function setUp() public virtual override { + FunctionsRouterSetup.setUp(); + + bytes32 allowListId = s_functionsRouter.getAllowListId(); + bytes32[] memory proposedContractSetIds = new bytes32[](2); + proposedContractSetIds[0] = bytes32("1"); + proposedContractSetIds[1] = allowListId; + address[] memory proposedContractSetAddresses = new address[](2); + proposedContractSetAddresses[0] = address(s_functionsCoordinator); + proposedContractSetAddresses[1] = address(s_termsOfServiceAllowList); + + s_functionsRouter.proposeContractsUpdate(proposedContractSetIds, proposedContractSetAddresses); + s_functionsRouter.updateContracts(); + } +} + +contract FunctionsOwnerAcceptTermsOfService is FunctionsSetupRoutes { + function setUp() public virtual override { + FunctionsSetupRoutes.setUp(); + + bytes32 message = s_termsOfServiceAllowList.getMessage(OWNER_ADDRESS, OWNER_ADDRESS); + bytes32 prefixedMessage = keccak256(abi.encodePacked("\x19Ethereum Signed Message:\n32", message)); + (uint8 v, bytes32 r, bytes32 s) = vm.sign(TOS_SIGNER_PRIVATE_KEY, prefixedMessage); + s_termsOfServiceAllowList.acceptTermsOfService(OWNER_ADDRESS, OWNER_ADDRESS, r, s, v); + } +} diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol index 7f9050b1e2f..4878290b6eb 100644 --- a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsClientWithEmptyCallback.sol @@ -1,9 +1,6 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.6; -import {ITermsOfServiceAllowList} from "../../../dev/1_0_0/accessControl/interfaces/ITermsOfServiceAllowList.sol"; -import {IFunctionsSubscriptions} from "../../../dev/1_0_0/interfaces/IFunctionsSubscriptions.sol"; - import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; @@ -28,5 +25,7 @@ contract FunctionsClientWithEmptyCallback is FunctionsClient { emit SendRequestInvoked(requestId, sourceCode, subscriptionId); } - function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal override {} + function fulfillRequest(bytes32 /*requestId*/, bytes memory /*response*/, bytes memory /*err*/) internal override { + // Do nothing + } } From 84d0cd4011ea0b8c6844b32a3370fd403adb5e11 Mon Sep 17 00:00:00 2001 From: Anindita Ghosh <88458927+AnieeG@users.noreply.github.com> Date: Tue, 22 Aug 2023 14:31:30 -0700 Subject: [PATCH 238/270] Adding erc20 contract wrapper (#10295) * adding erc20 contract wrapper * updated native_solc_compile --- .../scripts/native_solc_compile_all_shared | 1 + .../shared/generated/erc20/erc20.go | 702 ++++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + core/gethwrappers/shared/go_generate.go | 1 + 4 files changed, 705 insertions(+) create mode 100644 core/gethwrappers/shared/generated/erc20/erc20.go diff --git a/contracts/scripts/native_solc_compile_all_shared b/contracts/scripts/native_solc_compile_all_shared index 1912b419228..e7199f81feb 100755 --- a/contracts/scripts/native_solc_compile_all_shared +++ b/contracts/scripts/native_solc_compile_all_shared @@ -27,3 +27,4 @@ compileContract () { compileContract shared/token/ERC677/BurnMintERC677.sol compileContract shared/token/ERC677/LinkToken.sol +compileContract vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/ERC20.sol diff --git a/core/gethwrappers/shared/generated/erc20/erc20.go b/core/gethwrappers/shared/generated/erc20/erc20.go new file mode 100644 index 00000000000..f5b1d9b7bf2 --- /dev/null +++ b/core/gethwrappers/shared/generated/erc20/erc20.go @@ -0,0 +1,702 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package erc20 + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var ERC20MetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"string\",\"name\":\"name_\",\"type\":\"string\"},{\"internalType\":\"string\",\"name\":\"symbol_\",\"type\":\"string\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Approval\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"value\",\"type\":\"uint256\"}],\"name\":\"Transfer\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"}],\"name\":\"allowance\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"approve\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"balanceOf\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"decimals\",\"outputs\":[{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"subtractedValue\",\"type\":\"uint256\"}],\"name\":\"decreaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"spender\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"addedValue\",\"type\":\"uint256\"}],\"name\":\"increaseAllowance\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"name\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"symbol\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"totalSupply\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transfer\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"transferFrom\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60806040523480156200001157600080fd5b5060405162000de638038062000de683398101604081905262000034916200011f565b600362000042838262000218565b50600462000051828262000218565b505050620002e4565b634e487b7160e01b600052604160045260246000fd5b600082601f8301126200008257600080fd5b81516001600160401b03808211156200009f576200009f6200005a565b604051601f8301601f19908116603f01168101908282118183101715620000ca57620000ca6200005a565b81604052838152602092508683858801011115620000e757600080fd5b600091505b838210156200010b5785820183015181830184015290820190620000ec565b600093810190920192909252949350505050565b600080604083850312156200013357600080fd5b82516001600160401b03808211156200014b57600080fd5b620001598683870162000070565b935060208501519150808211156200017057600080fd5b506200017f8582860162000070565b9150509250929050565b600181811c908216806200019e57607f821691505b602082108103620001bf57634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200021357600081815260208120601f850160051c81016020861015620001ee5750805b601f850160051c820191505b818110156200020f57828155600101620001fa565b5050505b505050565b81516001600160401b038111156200023457620002346200005a565b6200024c8162000245845462000189565b84620001c5565b602080601f8311600181146200028457600084156200026b5750858301515b600019600386901b1c1916600185901b1785556200020f565b600085815260208120601f198616915b82811015620002b55788860151825594840194600190910190840162000294565b5085821015620002d45787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b610af280620002f46000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80633950935111610081578063a457c2d71161005b578063a457c2d714610194578063a9059cbb146101a7578063dd62ed3e146101ba57600080fd5b8063395093511461014357806370a082311461015657806395d89b411461018c57600080fd5b806318160ddd116100b257806318160ddd1461010f57806323b872dd14610121578063313ce5671461013457600080fd5b806306fdde03146100ce578063095ea7b3146100ec575b600080fd5b6100d6610200565b6040516100e39190610908565b60405180910390f35b6100ff6100fa36600461099d565b610292565b60405190151581526020016100e3565b6002545b6040519081526020016100e3565b6100ff61012f3660046109c7565b6102ac565b604051601281526020016100e3565b6100ff61015136600461099d565b6102d0565b610113610164366004610a03565b73ffffffffffffffffffffffffffffffffffffffff1660009081526020819052604090205490565b6100d661031c565b6100ff6101a236600461099d565b61032b565b6100ff6101b536600461099d565b610401565b6101136101c8366004610a25565b73ffffffffffffffffffffffffffffffffffffffff918216600090815260016020908152604080832093909416825291909152205490565b60606003805461020f90610a58565b80601f016020809104026020016040519081016040528092919081815260200182805461023b90610a58565b80156102885780601f1061025d57610100808354040283529160200191610288565b820191906000526020600020905b81548152906001019060200180831161026b57829003601f168201915b5050505050905090565b6000336102a081858561040f565b60019150505b92915050565b6000336102ba8582856105c2565b6102c5858585610699565b506001949350505050565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684529091528120549091906102a09082908690610317908790610aab565b61040f565b60606004805461020f90610a58565b33600081815260016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452909152812054909190838110156103f4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a2064656372656173656420616c6c6f77616e63652062656c6f7760448201527f207a65726f00000000000000000000000000000000000000000000000000000060648201526084015b60405180910390fd5b6102c5828686840361040f565b6000336102a0818585610699565b73ffffffffffffffffffffffffffffffffffffffff83166104b1576040517f08c379a0000000000000000000000000000000000000000000000000000000008152602060048201526024808201527f45524332303a20617070726f76652066726f6d20746865207a65726f2061646460448201527f726573730000000000000000000000000000000000000000000000000000000060648201526084016103eb565b73ffffffffffffffffffffffffffffffffffffffff8216610554576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602260248201527f45524332303a20617070726f766520746f20746865207a65726f20616464726560448201527f737300000000000000000000000000000000000000000000000000000000000060648201526084016103eb565b73ffffffffffffffffffffffffffffffffffffffff83811660008181526001602090815260408083209487168084529482529182902085905590518481527f8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925910160405180910390a3505050565b73ffffffffffffffffffffffffffffffffffffffff8381166000908152600160209081526040808320938616835292905220547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff81146106935781811015610686576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f45524332303a20696e73756666696369656e7420616c6c6f77616e636500000060448201526064016103eb565b610693848484840361040f565b50505050565b73ffffffffffffffffffffffffffffffffffffffff831661073c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602560248201527f45524332303a207472616e736665722066726f6d20746865207a65726f20616460448201527f647265737300000000000000000000000000000000000000000000000000000060648201526084016103eb565b73ffffffffffffffffffffffffffffffffffffffff82166107df576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602360248201527f45524332303a207472616e7366657220746f20746865207a65726f206164647260448201527f657373000000000000000000000000000000000000000000000000000000000060648201526084016103eb565b73ffffffffffffffffffffffffffffffffffffffff831660009081526020819052604090205481811015610895576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f45524332303a207472616e7366657220616d6f756e742065786365656473206260448201527f616c616e6365000000000000000000000000000000000000000000000000000060648201526084016103eb565b73ffffffffffffffffffffffffffffffffffffffff848116600081815260208181526040808320878703905593871680835291849020805487019055925185815290927fddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef910160405180910390a3610693565b600060208083528351808285015260005b8181101561093557858101830151858201604001528201610919565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461099857600080fd5b919050565b600080604083850312156109b057600080fd5b6109b983610974565b946020939093013593505050565b6000806000606084860312156109dc57600080fd5b6109e584610974565b92506109f360208501610974565b9150604084013590509250925092565b600060208284031215610a1557600080fd5b610a1e82610974565b9392505050565b60008060408385031215610a3857600080fd5b610a4183610974565b9150610a4f60208401610974565b90509250929050565b600181811c90821680610a6c57607f821691505b602082108103610aa5577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b808201808211156102a6577f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fdfea164736f6c6343000813000a", +} + +var ERC20ABI = ERC20MetaData.ABI + +var ERC20Bin = ERC20MetaData.Bin + +func DeployERC20(auth *bind.TransactOpts, backend bind.ContractBackend, name_ string, symbol_ string) (common.Address, *types.Transaction, *ERC20, error) { + parsed, err := ERC20MetaData.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(ERC20Bin), backend, name_, symbol_) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &ERC20{ERC20Caller: ERC20Caller{contract: contract}, ERC20Transactor: ERC20Transactor{contract: contract}, ERC20Filterer: ERC20Filterer{contract: contract}}, nil +} + +type ERC20 struct { + address common.Address + abi abi.ABI + ERC20Caller + ERC20Transactor + ERC20Filterer +} + +type ERC20Caller struct { + contract *bind.BoundContract +} + +type ERC20Transactor struct { + contract *bind.BoundContract +} + +type ERC20Filterer struct { + contract *bind.BoundContract +} + +type ERC20Session struct { + Contract *ERC20 + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type ERC20CallerSession struct { + Contract *ERC20Caller + CallOpts bind.CallOpts +} + +type ERC20TransactorSession struct { + Contract *ERC20Transactor + TransactOpts bind.TransactOpts +} + +type ERC20Raw struct { + Contract *ERC20 +} + +type ERC20CallerRaw struct { + Contract *ERC20Caller +} + +type ERC20TransactorRaw struct { + Contract *ERC20Transactor +} + +func NewERC20(address common.Address, backend bind.ContractBackend) (*ERC20, error) { + abi, err := abi.JSON(strings.NewReader(ERC20ABI)) + if err != nil { + return nil, err + } + contract, err := bindERC20(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &ERC20{address: address, abi: abi, ERC20Caller: ERC20Caller{contract: contract}, ERC20Transactor: ERC20Transactor{contract: contract}, ERC20Filterer: ERC20Filterer{contract: contract}}, nil +} + +func NewERC20Caller(address common.Address, caller bind.ContractCaller) (*ERC20Caller, error) { + contract, err := bindERC20(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &ERC20Caller{contract: contract}, nil +} + +func NewERC20Transactor(address common.Address, transactor bind.ContractTransactor) (*ERC20Transactor, error) { + contract, err := bindERC20(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &ERC20Transactor{contract: contract}, nil +} + +func NewERC20Filterer(address common.Address, filterer bind.ContractFilterer) (*ERC20Filterer, error) { + contract, err := bindERC20(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &ERC20Filterer{contract: contract}, nil +} + +func bindERC20(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := ERC20MetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_ERC20 *ERC20Raw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _ERC20.Contract.ERC20Caller.contract.Call(opts, result, method, params...) +} + +func (_ERC20 *ERC20Raw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _ERC20.Contract.ERC20Transactor.contract.Transfer(opts) +} + +func (_ERC20 *ERC20Raw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _ERC20.Contract.ERC20Transactor.contract.Transact(opts, method, params...) +} + +func (_ERC20 *ERC20CallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _ERC20.Contract.contract.Call(opts, result, method, params...) +} + +func (_ERC20 *ERC20TransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _ERC20.Contract.contract.Transfer(opts) +} + +func (_ERC20 *ERC20TransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _ERC20.Contract.contract.Transact(opts, method, params...) +} + +func (_ERC20 *ERC20Caller) Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) { + var out []interface{} + err := _ERC20.contract.Call(opts, &out, "allowance", owner, spender) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_ERC20 *ERC20Session) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { + return _ERC20.Contract.Allowance(&_ERC20.CallOpts, owner, spender) +} + +func (_ERC20 *ERC20CallerSession) Allowance(owner common.Address, spender common.Address) (*big.Int, error) { + return _ERC20.Contract.Allowance(&_ERC20.CallOpts, owner, spender) +} + +func (_ERC20 *ERC20Caller) BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) { + var out []interface{} + err := _ERC20.contract.Call(opts, &out, "balanceOf", account) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_ERC20 *ERC20Session) BalanceOf(account common.Address) (*big.Int, error) { + return _ERC20.Contract.BalanceOf(&_ERC20.CallOpts, account) +} + +func (_ERC20 *ERC20CallerSession) BalanceOf(account common.Address) (*big.Int, error) { + return _ERC20.Contract.BalanceOf(&_ERC20.CallOpts, account) +} + +func (_ERC20 *ERC20Caller) Decimals(opts *bind.CallOpts) (uint8, error) { + var out []interface{} + err := _ERC20.contract.Call(opts, &out, "decimals") + + if err != nil { + return *new(uint8), err + } + + out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) + + return out0, err + +} + +func (_ERC20 *ERC20Session) Decimals() (uint8, error) { + return _ERC20.Contract.Decimals(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20CallerSession) Decimals() (uint8, error) { + return _ERC20.Contract.Decimals(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20Caller) Name(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _ERC20.contract.Call(opts, &out, "name") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_ERC20 *ERC20Session) Name() (string, error) { + return _ERC20.Contract.Name(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20CallerSession) Name() (string, error) { + return _ERC20.Contract.Name(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20Caller) Symbol(opts *bind.CallOpts) (string, error) { + var out []interface{} + err := _ERC20.contract.Call(opts, &out, "symbol") + + if err != nil { + return *new(string), err + } + + out0 := *abi.ConvertType(out[0], new(string)).(*string) + + return out0, err + +} + +func (_ERC20 *ERC20Session) Symbol() (string, error) { + return _ERC20.Contract.Symbol(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20CallerSession) Symbol() (string, error) { + return _ERC20.Contract.Symbol(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20Caller) TotalSupply(opts *bind.CallOpts) (*big.Int, error) { + var out []interface{} + err := _ERC20.contract.Call(opts, &out, "totalSupply") + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_ERC20 *ERC20Session) TotalSupply() (*big.Int, error) { + return _ERC20.Contract.TotalSupply(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20CallerSession) TotalSupply() (*big.Int, error) { + return _ERC20.Contract.TotalSupply(&_ERC20.CallOpts) +} + +func (_ERC20 *ERC20Transactor) Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.contract.Transact(opts, "approve", spender, amount) +} + +func (_ERC20 *ERC20Session) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.Approve(&_ERC20.TransactOpts, spender, amount) +} + +func (_ERC20 *ERC20TransactorSession) Approve(spender common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.Approve(&_ERC20.TransactOpts, spender, amount) +} + +func (_ERC20 *ERC20Transactor) DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _ERC20.contract.Transact(opts, "decreaseAllowance", spender, subtractedValue) +} + +func (_ERC20 *ERC20Session) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.DecreaseAllowance(&_ERC20.TransactOpts, spender, subtractedValue) +} + +func (_ERC20 *ERC20TransactorSession) DecreaseAllowance(spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.DecreaseAllowance(&_ERC20.TransactOpts, spender, subtractedValue) +} + +func (_ERC20 *ERC20Transactor) IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _ERC20.contract.Transact(opts, "increaseAllowance", spender, addedValue) +} + +func (_ERC20 *ERC20Session) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.IncreaseAllowance(&_ERC20.TransactOpts, spender, addedValue) +} + +func (_ERC20 *ERC20TransactorSession) IncreaseAllowance(spender common.Address, addedValue *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.IncreaseAllowance(&_ERC20.TransactOpts, spender, addedValue) +} + +func (_ERC20 *ERC20Transactor) Transfer(opts *bind.TransactOpts, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.contract.Transact(opts, "transfer", to, amount) +} + +func (_ERC20 *ERC20Session) Transfer(to common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.Transfer(&_ERC20.TransactOpts, to, amount) +} + +func (_ERC20 *ERC20TransactorSession) Transfer(to common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.Transfer(&_ERC20.TransactOpts, to, amount) +} + +func (_ERC20 *ERC20Transactor) TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.contract.Transact(opts, "transferFrom", from, to, amount) +} + +func (_ERC20 *ERC20Session) TransferFrom(from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.TransferFrom(&_ERC20.TransactOpts, from, to, amount) +} + +func (_ERC20 *ERC20TransactorSession) TransferFrom(from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) { + return _ERC20.Contract.TransferFrom(&_ERC20.TransactOpts, from, to, amount) +} + +type ERC20ApprovalIterator struct { + Event *ERC20Approval + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *ERC20ApprovalIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(ERC20Approval) + 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(ERC20Approval) + 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 *ERC20ApprovalIterator) Error() error { + return it.fail +} + +func (it *ERC20ApprovalIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type ERC20Approval struct { + Owner common.Address + Spender common.Address + Value *big.Int + Raw types.Log +} + +func (_ERC20 *ERC20Filterer) FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*ERC20ApprovalIterator, error) { + + var ownerRule []interface{} + for _, ownerItem := range owner { + ownerRule = append(ownerRule, ownerItem) + } + var spenderRule []interface{} + for _, spenderItem := range spender { + spenderRule = append(spenderRule, spenderItem) + } + + logs, sub, err := _ERC20.contract.FilterLogs(opts, "Approval", ownerRule, spenderRule) + if err != nil { + return nil, err + } + return &ERC20ApprovalIterator{contract: _ERC20.contract, event: "Approval", logs: logs, sub: sub}, nil +} + +func (_ERC20 *ERC20Filterer) WatchApproval(opts *bind.WatchOpts, sink chan<- *ERC20Approval, owner []common.Address, spender []common.Address) (event.Subscription, error) { + + var ownerRule []interface{} + for _, ownerItem := range owner { + ownerRule = append(ownerRule, ownerItem) + } + var spenderRule []interface{} + for _, spenderItem := range spender { + spenderRule = append(spenderRule, spenderItem) + } + + logs, sub, err := _ERC20.contract.WatchLogs(opts, "Approval", ownerRule, spenderRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(ERC20Approval) + if err := _ERC20.contract.UnpackLog(event, "Approval", 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 (_ERC20 *ERC20Filterer) ParseApproval(log types.Log) (*ERC20Approval, error) { + event := new(ERC20Approval) + if err := _ERC20.contract.UnpackLog(event, "Approval", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type ERC20TransferIterator struct { + Event *ERC20Transfer + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *ERC20TransferIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(ERC20Transfer) + 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(ERC20Transfer) + 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 *ERC20TransferIterator) Error() error { + return it.fail +} + +func (it *ERC20TransferIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type ERC20Transfer struct { + From common.Address + To common.Address + Value *big.Int + Raw types.Log +} + +func (_ERC20 *ERC20Filterer) FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*ERC20TransferIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _ERC20.contract.FilterLogs(opts, "Transfer", fromRule, toRule) + if err != nil { + return nil, err + } + return &ERC20TransferIterator{contract: _ERC20.contract, event: "Transfer", logs: logs, sub: sub}, nil +} + +func (_ERC20 *ERC20Filterer) WatchTransfer(opts *bind.WatchOpts, sink chan<- *ERC20Transfer, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _ERC20.contract.WatchLogs(opts, "Transfer", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(ERC20Transfer) + if err := _ERC20.contract.UnpackLog(event, "Transfer", 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 (_ERC20 *ERC20Filterer) ParseTransfer(log types.Log) (*ERC20Transfer, error) { + event := new(ERC20Transfer) + if err := _ERC20.contract.UnpackLog(event, "Transfer", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_ERC20 *ERC20) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _ERC20.abi.Events["Approval"].ID: + return _ERC20.ParseApproval(log) + case _ERC20.abi.Events["Transfer"].ID: + return _ERC20.ParseTransfer(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (ERC20Approval) Topic() common.Hash { + return common.HexToHash("0x8c5be1e5ebec7d5bd14f71427d1e84f3dd0314c0f7b2291e5b200ac8c7c3b925") +} + +func (ERC20Transfer) Topic() common.Hash { + return common.HexToHash("0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef") +} + +func (_ERC20 *ERC20) Address() common.Address { + return _ERC20.address +} + +type ERC20Interface interface { + Allowance(opts *bind.CallOpts, owner common.Address, spender common.Address) (*big.Int, error) + + BalanceOf(opts *bind.CallOpts, account common.Address) (*big.Int, error) + + Decimals(opts *bind.CallOpts) (uint8, error) + + Name(opts *bind.CallOpts) (string, error) + + Symbol(opts *bind.CallOpts) (string, error) + + TotalSupply(opts *bind.CallOpts) (*big.Int, error) + + Approve(opts *bind.TransactOpts, spender common.Address, amount *big.Int) (*types.Transaction, error) + + DecreaseAllowance(opts *bind.TransactOpts, spender common.Address, subtractedValue *big.Int) (*types.Transaction, error) + + IncreaseAllowance(opts *bind.TransactOpts, spender common.Address, addedValue *big.Int) (*types.Transaction, error) + + Transfer(opts *bind.TransactOpts, to common.Address, amount *big.Int) (*types.Transaction, error) + + TransferFrom(opts *bind.TransactOpts, from common.Address, to common.Address, amount *big.Int) (*types.Transaction, error) + + FilterApproval(opts *bind.FilterOpts, owner []common.Address, spender []common.Address) (*ERC20ApprovalIterator, error) + + WatchApproval(opts *bind.WatchOpts, sink chan<- *ERC20Approval, owner []common.Address, spender []common.Address) (event.Subscription, error) + + ParseApproval(log types.Log) (*ERC20Approval, error) + + FilterTransfer(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*ERC20TransferIterator, error) + + WatchTransfer(opts *bind.WatchOpts, sink chan<- *ERC20Transfer, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseTransfer(log types.Log) (*ERC20Transfer, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt index b8a0f62f842..3094b1a94f0 100644 --- a/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/shared/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,3 +1,4 @@ GETH_VERSION: 1.12.0 burn_mint_erc677: ../../../contracts/solc/v0.8.19/BurnMintERC677.abi ../../../contracts/solc/v0.8.19/BurnMintERC677.bin 405c9016171e614b17e10588653ef8d33dcea21dd569c3fddc596a46fcff68a3 +erc20: ../../../contracts/solc/v0.8.19/ERC20.abi ../../../contracts/solc/v0.8.19/ERC20.bin 5b1a93d9b24f250e49a730c96335a8113c3f7010365cba578f313b483001d4fc link_token: ../../../contracts/solc/v0.8.19/LinkToken.abi ../../../contracts/solc/v0.8.19/LinkToken.bin c0ef9b507103aae541ebc31d87d051c2764ba9d843076b30ec505d37cdfffaba diff --git a/core/gethwrappers/shared/go_generate.go b/core/gethwrappers/shared/go_generate.go index e4acb59e98c..169a87b9b2d 100644 --- a/core/gethwrappers/shared/go_generate.go +++ b/core/gethwrappers/shared/go_generate.go @@ -4,3 +4,4 @@ package gethwrappers //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/BurnMintERC677.abi ../../../contracts/solc/v0.8.19/BurnMintERC677.bin BurnMintERC677 burn_mint_erc677 //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/LinkToken.abi ../../../contracts/solc/v0.8.19/LinkToken.bin LinkToken link_token +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/ERC20.abi ../../../contracts/solc/v0.8.19/ERC20.bin ERC20 erc20 From c368940e6921ad1d9339b2698916a8a92777a041 Mon Sep 17 00:00:00 2001 From: Anindita Ghosh <88458927+AnieeG@users.noreply.github.com> Date: Tue, 22 Aug 2023 16:18:35 -0700 Subject: [PATCH 239/270] add make command to test with local image (#10307) --- integration-tests/Makefile | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/integration-tests/Makefile b/integration-tests/Makefile index f558d598498..110c119df75 100644 --- a/integration-tests/Makefile +++ b/integration-tests/Makefile @@ -191,3 +191,25 @@ test_benchmark_automation: ## Run the automation benchmark tests .PHONY: test_reorg_automation test_reorg_automation: ## Run the automation reorg tests go test -timeout 300m -v -run ^TestAutomationReorg$$ ./reorg -count=1 | tee automation_reorg_run_`date +"%Y%m%d-%H%M%S"`.log + +# image: the name for the chainlink image being built, example: image=chainlink +# tag: the tag for the chainlink image being built, example: tag=latest +# example usage: make build_docker_image image=chainlink tag=latest +.PHONY: build_docker_image +build_docker_image: + docker build -f ../core/chainlink.Dockerfile --build-arg COMMIT_SHA=$(git rev-parse HEAD) --build-arg CHAINLINK_USER=chainlink -t $(image):$(tag) ../ + + +# image: the name for the chainlink image being built, example: image=chainlink +# tag: the tag for the chainlink image being built, example: tag=latest +# args: the args to pass to the test runner, example: args="--focus @cron -p" +# product: the product to run tests for, example: product=cron +# example usage: make run_test_with_local_image image=chainlink tag=latest-dev product=cron +.PHONY: run_test_with_local_image +run_test_with_local_image: build_docker_image + CHAINLINK_IMAGE=$(image) \ + CHAINLINK_VERSION=$(tag) \ + SELECTED_NETWORKS="SIMULATED,SIMULATED_1,SIMULATED_2" \ + ARGS="$(args)" \ + PRODUCT=$(product) \ + ./scripts/run_product_tests \ No newline at end of file From 13b1ac0783a698af9f9eaa3e60e311e8a5b4953c Mon Sep 17 00:00:00 2001 From: Morgan Kuphal <87319522+KuphJr@users.noreply.github.com> Date: Tue, 22 Aug 2023 19:18:44 -0500 Subject: [PATCH 240/270] Emit user error bytes (#10276) * Emit user error bytes * lint * Addressed feedback on field names * USER_CALLBACK_SUCCESS -> USER_CALLBACK_FULFILLED * USER_CALLBACK_FULFILLED -> FULFILLED --- .../functions/dev/1_0_0/FunctionsBilling.sol | 4 ++-- .../dev/1_0_0/FunctionsCoordinator.sol | 3 ++- .../functions/dev/1_0_0/FunctionsRouter.sol | 12 ++++++---- .../dev/1_0_0/libraries/FunctionsResponse.sol | 4 ++-- .../v1/FunctionsSubscriptions.test.ts | 3 +++ .../functions_router/functions_router.go | 23 ++++++++++--------- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 7 files changed, 29 insertions(+), 22 deletions(-) diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol index f9347317721..efad1eab5e5 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsBilling.sol @@ -288,8 +288,8 @@ abstract contract FunctionsBilling is Routable, IFunctionsBilling { // In these two fulfillment results the user has been charged // Otherwise, the Coordinator should hold on to the request commitment if ( - resultCode == FunctionsResponse.FulfillResult.USER_SUCCESS || - resultCode == FunctionsResponse.FulfillResult.USER_ERROR + resultCode == FunctionsResponse.FulfillResult.FULFILLED || + resultCode == FunctionsResponse.FulfillResult.USER_CALLBACK_ERROR ) { delete s_requestCommitments[requestId]; // Reimburse the transmitter for the fulfillment gas cost diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol index 7733e20d98c..46df61cd916 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsCoordinator.sol @@ -197,7 +197,8 @@ contract FunctionsCoordinator is OCR2Base, IFunctionsCoordinator, FunctionsBilli // In these two fulfillment results the user has been charged // Otherwise, the DON will re-try if ( - result == FunctionsResponse.FulfillResult.USER_SUCCESS || result == FunctionsResponse.FulfillResult.USER_ERROR + result == FunctionsResponse.FulfillResult.FULFILLED || + result == FunctionsResponse.FulfillResult.USER_CALLBACK_ERROR ) { emit OracleResponse(requestIds[i], msg.sender); } diff --git a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol index c946e041429..46f6929fabc 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/FunctionsRouter.sol @@ -46,7 +46,8 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, address transmitter, FunctionsResponse.FulfillResult resultCode, bytes response, - bytes returnData + bytes err, + bytes callbackReturnData ); event RequestNotProcessed( @@ -348,8 +349,8 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, ); resultCode = result.success - ? FunctionsResponse.FulfillResult.USER_SUCCESS - : FunctionsResponse.FulfillResult.USER_ERROR; + ? FunctionsResponse.FulfillResult.FULFILLED + : FunctionsResponse.FulfillResult.USER_CALLBACK_ERROR; Receipt memory receipt = _pay( commitment.subscriptionId, @@ -367,8 +368,9 @@ contract FunctionsRouter is IFunctionsRouter, FunctionsSubscriptions, Pausable, totalCostJuels: receipt.totalCostJuels, transmitter: transmitter, resultCode: resultCode, - response: result.success ? response : err, - returnData: result.returnData + response: response, + err: err, + callbackReturnData: result.returnData }); return (resultCode, receipt.callbackGasCostJuels); diff --git a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol index 178f22820e5..71e731b2e33 100644 --- a/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol +++ b/contracts/src/v0.8/functions/dev/1_0_0/libraries/FunctionsResponse.sol @@ -21,8 +21,8 @@ library FunctionsResponse { } enum FulfillResult { - USER_SUCCESS, // 0 - USER_ERROR, // 1 + FULFILLED, // 0 + USER_CALLBACK_ERROR, // 1 INVALID_REQUEST_ID, // 2 COST_EXCEEDS_COMMITMENT, // 3 INSUFFICIENT_GAS_PROVIDED, // 4 diff --git a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts index 7768138801a..e2f0372be15 100644 --- a/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts +++ b/contracts/test/v0.8/functions/v1/FunctionsSubscriptions.test.ts @@ -655,6 +655,7 @@ describe('Functions Router - Subscriptions', () => { 0, // Result code for callback failing () => true, () => true, + () => true, ) .to.emit(contracts.client, 'FulfillRequestInvoked') .withArgs(requestId, response, error) @@ -741,6 +742,7 @@ describe('Functions Router - Subscriptions', () => { 1, // Result code for callback failing () => true, () => true, + () => true, ) }) @@ -848,6 +850,7 @@ describe('Functions Router - Subscriptions', () => { 1, // Result code for callback failing () => true, () => true, + () => true, ) }) }) diff --git a/core/gethwrappers/functions/generated/functions_router/functions_router.go b/core/gethwrappers/functions/generated/functions_router/functions_router.go index eb6342a9607..83c3f9b6132 100644 --- a/core/gethwrappers/functions/generated/functions_router/functions_router.go +++ b/core/gethwrappers/functions/generated/functions_router/functions_router.go @@ -68,8 +68,8 @@ type IFunctionsSubscriptionsSubscription struct { } var FunctionsRouterMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"totalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"deductionAttempt\",\"type\":\"uint256\"}],\"name\":\"TotalBalanceInvariantViolated\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"returnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162006241380380620062418339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615b8e620006b3600039600081816113c20152818161219501528181612a8d01528181612b5101526132cc0152615b8e6000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f1366004614888565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046148c9565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614970565b6102f66103a2366004614983565b610853565b6102f66103b5366004614b46565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614df2565b6109b2565b60405161030f929190614eda565b6102f6610417366004614f67565b610d98565b6102f661101d565b610437610432366004615069565b61102f565b60405190815260200161030f565b610437610453366004615069565b61108f565b6102f66104663660046150ed565b61109b565b610437610479366004614888565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be36600461511b565b6111e9565b6102f66104d136600461511b565b61140b565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b366004615149565b61155d565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004615177565b6115ed565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c3660046150ed565b6116ac565b6102f6611860565b6102f66105a7366004614888565b611987565b6102f6611ace565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e53660046150ed565b611ade565b6104e4611eb3565b610605610600366004614888565b612040565b60405161030f91906151e1565b6102f6610620366004615269565b612175565b610559610633366004615177565b6123c1565b600954610437565b6102f6612420565b61065061256c565b60405161030f9291906152c5565b61066661263c565b60405161030f919061531c565b6104e46106813660046153c6565b612771565b6102f66106943660046150ed565b6129f1565b6102f66106a73660046153c6565b612a54565b6102f66106ba3660046153e3565b612bcd565b6104a06106cd366004614888565b612e9e565b6102f66106e0366004615177565b612fed565b6102f66106f33660046153c6565b612ffa565b61070061300b565b61070981613013565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16613089565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d7615459565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b61300b565b61086482613013565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d613375565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906146d3565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a7919061531c565b60405180910390a150565b6000806109bd6133fb565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615488565b60405180910390a2506000610d8d565b8251600090815260056020908152604091829020549151610aab918691016154ba565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615488565b8261012001518360a0015163ffffffff16610b1e9190615616565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a789188908790615488565b6000610b7e8460a0015163ffffffff16613403565b610b88908861563b565b9050600081878660c0015168ffffffffffffffffff16610ba89190615663565b610bb29190615663565b9050610bc18560800151612040565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615488565b60405180910390a25060009150610d8d9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a908990615488565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c91906134a5565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d158860200151613403565b8d613634565b9050846080015167ffffffffffffffff1685600001517f47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b836020015189888760000151610d68578e610d6a565b8f5b8860400151604051610d80959493929190615688565b60405180910390a3519150505b965096945050505050565b610da0613375565b8151815181141580610db25750600881115b15610de9576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610edb576000848281518110610e0857610e08615459565b602002602001015190506000848381518110610e2657610e26615459565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e91575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610ec8576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ed4906156ea565b9050610dec565b506040805180820190915283815260208082018490528451600c91610f0491839188019061477e565b506020828101518051610f1d92600185019201906147b9565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f6057610f60615459565b602002602001015160086000878581518110610f7e57610f7e615459565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fc757610fc7615459565b60200260200101516040516110059392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611016816156ea565b9050610f24565b611025613375565b61102d6139b6565b565b60008061103b836115ed565b905061108383828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613a339050565b98975050505050505050565b60008061103b836123c1565b6110a36133fb565b6110ac82613ddc565b6110b4613ea2565b73ffffffffffffffffffffffffffffffffffffffff8116158061111b575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611152576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111f161300b565b806bffffffffffffffffffffffff166000036112275750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611293576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff808416911610156112fc576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b30600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff1661137f9190615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061140683836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613fac9092919063ffffffff16565b505050565b6114136133fb565b806bffffffffffffffffffffffff1660000361145b576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff9081169082168110156114c7576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff80841691161015611530576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b33600090815260016020526040812080548492906113299084906bffffffffffffffffffffffff16615722565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561167657600c805460ff831690811061161557611615615459565b9060005260206000200154830361166657600d805460ff831690811061163d5761163d615459565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b61166f81615747565b90506115f1565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6116b46133fb565b6116bd82613ddc565b6116c5613ea2565b60006116d4600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611737576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff161561177f57505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff1633146118e1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b61198f6133fb565b611997613ea2565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611a37576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611853565b611ad6613375565b61102d614039565b611ae66133fb565b611aef82613ddc565b611af7613ea2565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b9f576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611bf4576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611c6f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611c44575b5050505050905060005b8151811015611e17578373ffffffffffffffffffffffffffffffffffffffff16828281518110611cab57611cab615459565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611e07578160018351611cdd9190615766565b81518110611ced57611ced615459565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611d3057611d30615459565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611daa57611daa615779565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611e17565b611e10816156ea565b9050611c79565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611ebd6133fb565b611ec5613ea2565b60028054600090611edf9067ffffffffffffffff166157a8565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611f55578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611ff0926002850192909101906147b9565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261207a82613013565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561215b57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612130575b505050505081526020016003820154815250509050919050565b61217d6133fb565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146121ec576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612226576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600061223482840184614888565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff166122ad576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906122e48385615663565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661233a9190615663565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f88287846123a191906157cf565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff16806115e7576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b612428613375565b60005b600c5481101561254b576000600c600001828154811061244d5761244d615459565b906000526020600020015490506000600c600101838154811061247257612472615459565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612544816156ea565b905061242b565b50600c600061255a8282614833565b612568600183016000614833565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156125c457602002820191906000526020600020905b8154815260200190600101908083116125b0575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561262d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612602575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561276357602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116127265790505b505050505081525050905090565b600061277b6133fb565b612783613ea2565b6002805460009061279d9067ffffffffffffffff166157a8565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612813578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926128ae926002850192909101906147b9565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b6129f96133fb565b612a0282613ddc565b612a0a613ea2565b612a1382612e9e565b15612a4a576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6125688282613089565b612a5c61300b565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612ae9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612b0d91906157e2565b6000549091506bffffffffffffffffffffffff1681811015611406576000612b358284615766565b9050612b7873ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613fac565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612bd56133fb565b60005b81811015611406576000838383818110612bf457612bf4615459565b90506101600201803603810190612c0b91906157fb565b80516080820151600082815260056020908152604091829020549151949550929391929091612c3c918691016154ba565b6040516020818303038152906040528051906020012014612c89576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612cce576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612d41573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d659190615818565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612da69084906bffffffffffffffffffffffff16615722565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612e2e918591690100000000000000000090041661583a565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612e97906156ea565b9050612bd8565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612f1657602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612eeb575b5050505050905060005b8151811015612fe357600060046000848481518110612f4157612f41615459565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612fd257506001949350505050565b50612fdc816156ea565b9050612f20565b5060009392505050565b612ff5613375565b600955565b613002613375565b61075481614094565b61102d613375565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561316a57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff16815260019091019060200180831161313f575b505050918352505060039190910154602090910152805190915060005b82608001515181101561322b5760046000846080015183815181106131ae576131ae615459565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613224816156ea565b9050613187565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061325d6002830182614833565b506000600391909101819055805482919081906132899084906bffffffffffffffffffffffff16615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061331083826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613fac9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611ea5565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61102d614190565b60006bffffffffffffffffffffffff8211156134a1576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b906134ef9089908990899060240161585b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6135ba57600080fd5b5a848110156135c857600080fd5b84900360408104810389106135dc57600080fd5b505a60008087516020890160008c8ef193505a900391503d6084811115613601575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b60408051808201909152600080825260208201526000613654848661563b565b90506000816136638886615663565b61366d9190615663565b67ffffffffffffffff8b166000908152600360205260409020549091506bffffffffffffffffffffffff808316911610156137005767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812080548392906137379084906bffffffffffffffffffffffff16615722565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600360205260409020600101548b82169116101590506137e45767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812060010180548b929061381e9084906bffffffffffffffffffffffff16615722565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555081846138589190615663565b33600090815260016020526040812080549091906138859084906bffffffffffffffffffffffff16615663565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926138cc91859116615663565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613950918591690100000000000000000090041661583a565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6139be6141fd565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613a3d6133fb565b613a4685613013565b613a503386614269565b613a5a8583610757565b8351600003613a94576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a9f86612040565b90506000613aad338861155d565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a8152602001613b038c67ffffffffffffffff166000908152600360208190526040909120015490565b815233602082015260408781015188519190920191613b2191615722565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b8152600401613be79190615886565b610160604051808303816000875af1158015613c07573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c2b91906159eb565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613d3291906154ba565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613d72338983604001516142dd565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613dc69796959493929190615abe565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e53576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff821614612568576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613ed25750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613f3390339060248101615b36565b602060405180830381865afa158015613f50573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f749190615818565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526114069084906143b8565b614041614190565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a258613a093390565b3373ffffffffffffffffffffffffffffffffffffffff821603614113576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661102d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff16612568576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143179084906bffffffffffffffffffffffff16615663565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261438d92849290041661583a565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b600061441a826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166144c49092919063ffffffff16565b80519091501561140657808060200190518101906144389190615818565b611406576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606144d384846000856144db565b949350505050565b60608247101561456d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516145969190615b65565b60006040518083038185875af1925050503d80600081146145d3576040519150601f19603f3d011682016040523d82523d6000602084013e6145d8565b606091505b50915091506145e9878383876145f4565b979650505050505050565b6060831561468a5782516000036146835773ffffffffffffffffffffffffffffffffffffffff85163b614683576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816144d3565b6144d3838381511561469f5781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b39190614970565b828054828255906000526020600020906007016008900481019282156147725791602002820160005b8382111561474057835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026146fc565b80156147705782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614740565b505b506134a192915061484d565b828054828255906000526020600020908101928215614772579160200282015b8281111561477257825182559160200191906001019061479e565b828054828255906000526020600020908101928215614772579160200282015b8281111561477257825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906147d9565b508054600082559060005260206000209081019061075491905b5b808211156134a1576000815560010161484e565b67ffffffffffffffff8116811461075457600080fd5b803561488381614862565b919050565b60006020828403121561489a57600080fd5b81356148a581614862565b9392505050565b63ffffffff8116811461075457600080fd5b8035614883816148ac565b600080604083850312156148dc57600080fd5b82356148e781614862565b915060208301356148f7816148ac565b809150509250929050565b60005b8381101561491d578181015183820152602001614905565b50506000910152565b6000815180845261493e816020860160208601614902565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006148a56020830184614926565b6000806040838503121561499657600080fd5b82356149a181614862565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff81118282101715614a0157614a016149af565b60405290565b604051610160810167ffffffffffffffff81118282101715614a0157614a016149af565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614a7257614a726149af565b604052919050565b803561ffff8116811461488357600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561488381614a8c565b600067ffffffffffffffff821115614ac857614ac86149af565b5060051b60200190565b600082601f830112614ae357600080fd5b81356020614af8614af383614aae565b614a2b565b82815260059290921b84018101918181019086841115614b1757600080fd5b8286015b84811015614b3b578035614b2e816148ac565b8352918301918301614b1b565b509695505050505050565b600060208284031215614b5857600080fd5b813567ffffffffffffffff80821115614b7057600080fd5b9083019060a08286031215614b8457600080fd5b614b8c6149de565b614b9583614a7a565b81526020830135614ba581614a8c565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614bdd57600080fd5b6040820152614bee60608401614a7a565b6060820152608083013582811115614c0557600080fd5b614c1187828601614ad2565b60808301525095945050505050565b600082601f830112614c3157600080fd5b813567ffffffffffffffff811115614c4b57614c4b6149af565b614c7c60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a2b565b818152846020838601011115614c9157600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561488381614cae565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561488381614cd3565b64ffffffffff8116811461075457600080fd5b803561488381614d00565b60006101608284031215614d3157600080fd5b614d39614a07565b905081358152614d4b60208301614cf5565b6020820152614d5c60408301614cc8565b6040820152614d6d60608301614cf5565b6060820152614d7e60808301614878565b6080820152614d8f60a083016148be565b60a0820152614da060c08301614aa3565b60c0820152614db160e08301614aa3565b60e0820152610100614dc4818401614d13565b90820152610120614dd6838201614d13565b90820152610140614de88382016148be565b9082015292915050565b6000806000806000806102008789031215614e0c57600080fd5b863567ffffffffffffffff80821115614e2457600080fd5b614e308a838b01614c20565b97506020890135915080821115614e4657600080fd5b50614e5389828a01614c20565b9550506040870135614e6481614cae565b93506060870135614e7481614cae565b92506080870135614e8481614cd3565b9150614e938860a08901614d1e565b90509295509295509295565b60078110614ed6577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614ee88285614e9f565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614f1457600080fd5b81356020614f24614af383614aae565b82815260059290921b84018101918181019086841115614f4357600080fd5b8286015b84811015614b3b578035614f5a81614cd3565b8352918301918301614f47565b60008060408385031215614f7a57600080fd5b823567ffffffffffffffff80821115614f9257600080fd5b818501915085601f830112614fa657600080fd5b81356020614fb6614af383614aae565b82815260059290921b84018101918181019089841115614fd557600080fd5b948201945b83861015614ff357853582529482019490820190614fda565b9650508601359250508082111561500957600080fd5b5061501685828601614f03565b9150509250929050565b60008083601f84011261503257600080fd5b50813567ffffffffffffffff81111561504a57600080fd5b60208301915083602082850101111561506257600080fd5b9250929050565b60008060008060008060a0878903121561508257600080fd5b863561508d81614862565b9550602087013567ffffffffffffffff8111156150a957600080fd5b6150b589828a01615020565b90965094506150c8905060408801614a7a565b925060608701356150d8816148ac565b80925050608087013590509295509295509295565b6000806040838503121561510057600080fd5b823561510b81614862565b915060208301356148f781614cd3565b6000806040838503121561512e57600080fd5b823561513981614cd3565b915060208301356148f781614cae565b6000806040838503121561515c57600080fd5b823561516781614cd3565b915060208301356148f781614862565b60006020828403121561518957600080fd5b5035919050565b600081518084526020808501945080840160005b838110156151d657815173ffffffffffffffffffffffffffffffffffffffff16875295820195908201906001016151a4565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261525360e0840182615190565b905060a084015160c08401528091505092915050565b6000806000806060858703121561527f57600080fd5b843561528a81614cd3565b935060208501359250604085013567ffffffffffffffff8111156152ad57600080fd5b6152b987828801615020565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b828110156152fe578151845292840192908401906001016152e2565b505050838103828501526153128186615190565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614b3b57835163ffffffff1682529284019260019290920191908401906153a0565b6000602082840312156153d857600080fd5b81356148a581614cd3565b600080602083850312156153f657600080fd5b823567ffffffffffffffff8082111561540e57600080fd5b818501915085601f83011261542257600080fd5b81358181111561543157600080fd5b8660206101608302850101111561544757600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016144d36040830184614e9f565b815181526020808301516101608301916154eb9084018273ffffffffffffffffffffffffffffffffffffffff169052565b50604083015161550b60408401826bffffffffffffffffffffffff169052565b506060830151615533606084018273ffffffffffffffffffffffffffffffffffffffff169052565b50608083015161554f608084018267ffffffffffffffff169052565b5060a083015161556760a084018263ffffffff169052565b5060c083015161558460c084018268ffffffffffffffffff169052565b5060e08301516155a160e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff818116838216019080821115615634576156346155e7565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155df576155df6155e7565b6bffffffffffffffffffffffff818116838216019080821115615634576156346155e7565b6bffffffffffffffffffffffff8616815273ffffffffffffffffffffffffffffffffffffffff851660208201526156c26040820185614e9f565b60a0606082015260006156d860a0830185614926565b82810360808401526110838185614926565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361571b5761571b6155e7565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615634576156346155e7565b600060ff821660ff810361575d5761575d6155e7565b60010192915050565b818103818111156115e7576115e76155e7565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157c5576157c56155e7565b6001019392505050565b808201808211156115e7576115e76155e7565b6000602082840312156157f457600080fd5b5051919050565b6000610160828403121561580e57600080fd5b6148a58383614d1e565b60006020828403121561582a57600080fd5b815180151581146148a557600080fd5b67ffffffffffffffff818116838216019080821115615634576156346155e7565b8381526060602082015260006158746060830185614926565b82810360408401526153128185614926565b60208152600082516101608060208501526158a5610180850183614926565b91506020850151604085015260408501516158d8606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e085015161010061594f8187018363ffffffff169052565b86015190506101206159668682018361ffff169052565b86015190506101406159838682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161488381614cd3565b805161488381614cae565b805161488381614862565b8051614883816148ac565b805161488381614a8c565b805161488381614d00565b600061016082840312156159fe57600080fd5b615a06614a07565b82518152615a16602084016159a9565b6020820152615a27604084016159b4565b6040820152615a38606084016159a9565b6060820152615a49608084016159bf565b6080820152615a5a60a084016159ca565b60a0820152615a6b60c084016159d5565b60c0820152615a7c60e084016159d5565b60e0820152610100615a8f8185016159e0565b90820152610120615aa18482016159e0565b90820152610140615ab38482016159ca565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615aff60e0830187614926565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006144d36040830184614926565b60008251615b77818460208701614902565b919091019291505056fea164736f6c6343000813000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkToken\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"CannotRemoveWithPendingRequests\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptyRequestData\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint32\",\"name\":\"limit\",\"type\":\"uint32\"}],\"name\":\"GasLimitTooBig\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"IdentifierIsReserved\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint96\",\"name\":\"currentBalanceJuels\",\"type\":\"uint96\"}],\"name\":\"InsufficientBalance\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidCalldata\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidConsumer\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint8\",\"name\":\"value\",\"type\":\"uint8\"}],\"name\":\"InvalidGasFlagValue\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidProposal\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSubscription\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"}],\"name\":\"MustBeProposedOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"MustBeSubscriptionOwner\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromCoordinator\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyCallableFromLink\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RouteNotFound\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"SenderMustAcceptTermsOfService\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"TimeoutNotExceeded\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint16\",\"name\":\"maximumConsumers\",\"type\":\"uint16\"}],\"name\":\"TooManyConsumers\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"totalBalance\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"deductionAttempt\",\"type\":\"uint256\"}],\"name\":\"TotalBalanceInvariantViolated\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"indexed\":false,\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"name\":\"ConfigUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"proposedContractSetId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetFromAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"proposedContractSetToAddress\",\"type\":\"address\"}],\"name\":\"ContractProposed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"ContractUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"FundsRecovered\",\"type\":\"event\"},{\"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\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Paused\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"}],\"name\":\"RequestNotProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"totalCostJuels\",\"type\":\"uint96\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"callbackReturnData\",\"type\":\"bytes\"}],\"name\":\"RequestProcessed\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"subscriptionOwner\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestingContract\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requestInitiator\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"}],\"name\":\"RequestStart\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"}],\"name\":\"RequestTimedOut\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"fundsRecipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"fundsAmount\",\"type\":\"uint256\"}],\"name\":\"SubscriptionCanceled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerAdded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"SubscriptionConsumerRemoved\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"}],\"name\":\"SubscriptionCreated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"oldBalance\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newBalance\",\"type\":\"uint256\"}],\"name\":\"SubscriptionFunded\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferRequested\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"SubscriptionOwnerTransferred\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"account\",\"type\":\"address\"}],\"name\":\"Unpaused\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_RETURN_BYTES\",\"outputs\":[{\"internalType\":\"uint16\",\"name\":\"\",\"type\":\"uint16\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"acceptSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"addConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"cancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"createSubscription\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"createSubscriptionWithConsumer\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"},{\"internalType\":\"uint96\",\"name\":\"juelsPerGas\",\"type\":\"uint96\"},{\"internalType\":\"uint96\",\"name\":\"costWithoutCallback\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"transmitter\",\"type\":\"address\"},{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment\",\"name\":\"commitment\",\"type\":\"tuple\"}],\"name\":\"fulfill\",\"outputs\":[{\"internalType\":\"enumFunctionsResponse.FulfillResult\",\"name\":\"resultCode\",\"type\":\"uint8\"},{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAdminFee\",\"outputs\":[{\"internalType\":\"uint72\",\"name\":\"\",\"type\":\"uint72\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getAllowListId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getConfig\",\"outputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getConsumer\",\"outputs\":[{\"components\":[{\"internalType\":\"bool\",\"name\":\"allowed\",\"type\":\"bool\"},{\"internalType\":\"uint64\",\"name\":\"initiatedRequests\",\"type\":\"uint64\"},{\"internalType\":\"uint64\",\"name\":\"completedRequests\",\"type\":\"uint64\"}],\"internalType\":\"structIFunctionsSubscriptions.Consumer\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getFlags\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"getProposedContractById\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getProposedContractSet\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"getSubscription\",\"outputs\":[{\"components\":[{\"internalType\":\"uint96\",\"name\":\"balance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"owner\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"blockedBalance\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"proposedOwner\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"consumers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"internalType\":\"structIFunctionsSubscriptions.Subscription\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getSubscriptionCount\",\"outputs\":[{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"getTotalBalance\",\"outputs\":[{\"internalType\":\"uint96\",\"name\":\"\",\"type\":\"uint96\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"}],\"name\":\"isValidCallbackGasLimit\",\"outputs\":[],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"onTokenTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"oracleWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"ownerCancelSubscription\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"amount\",\"type\":\"uint96\"}],\"name\":\"ownerWithdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"pause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"paused\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"}],\"name\":\"pendingRequestExists\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"proposedContractSetIds\",\"type\":\"bytes32[]\"},{\"internalType\":\"address[]\",\"name\":\"proposedContractSetAddresses\",\"type\":\"address[]\"}],\"name\":\"proposeContractsUpdate\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"newOwner\",\"type\":\"address\"}],\"name\":\"proposeSubscriptionOwnerTransfer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"recoverFunds\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"address\",\"name\":\"consumer\",\"type\":\"address\"}],\"name\":\"removeConsumer\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"},{\"internalType\":\"uint16\",\"name\":\"dataVersion\",\"type\":\"uint16\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"donId\",\"type\":\"bytes32\"}],\"name\":\"sendRequestToProposed\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"allowListId\",\"type\":\"bytes32\"}],\"name\":\"setAllowListId\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"flags\",\"type\":\"bytes32\"}],\"name\":\"setFlags\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"coordinator\",\"type\":\"address\"},{\"internalType\":\"uint96\",\"name\":\"estimatedTotalCostJuels\",\"type\":\"uint96\"},{\"internalType\":\"address\",\"name\":\"client\",\"type\":\"address\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"uint32\",\"name\":\"callbackGasLimit\",\"type\":\"uint32\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"uint72\",\"name\":\"donFee\",\"type\":\"uint72\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadBeforeCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint40\",\"name\":\"gasOverheadAfterCallback\",\"type\":\"uint40\"},{\"internalType\":\"uint32\",\"name\":\"timeoutTimestamp\",\"type\":\"uint32\"}],\"internalType\":\"structFunctionsResponse.Commitment[]\",\"name\":\"requestsToTimeoutByCommitment\",\"type\":\"tuple[]\"}],\"name\":\"timeoutRequests\",\"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\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"unpause\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint16\",\"name\":\"maxConsumersPerSubscription\",\"type\":\"uint16\"},{\"internalType\":\"uint72\",\"name\":\"adminFee\",\"type\":\"uint72\"},{\"internalType\":\"bytes4\",\"name\":\"handleOracleFulfillmentSelector\",\"type\":\"bytes4\"},{\"internalType\":\"uint16\",\"name\":\"gasForCallExactCheck\",\"type\":\"uint16\"},{\"internalType\":\"uint32[]\",\"name\":\"maxCallbackGasLimits\",\"type\":\"uint32[]\"}],\"internalType\":\"structFunctionsRouter.Config\",\"name\":\"config\",\"type\":\"tuple\"}],\"name\":\"updateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"updateContracts\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162006254380380620062548339810160408190526200003491620004df565b6001600160a01b0382166080526006805460ff191690553380600081620000a25760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600680546001600160a01b0380851661010002610100600160a81b031990921691909117909155811615620000dc57620000dc81620000f8565b505050620000f081620001aa60201b60201c565b50506200067b565b336001600160a01b03821603620001525760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000099565b600780546001600160a01b0319166001600160a01b03838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b620001b462000287565b8051600a80546020808501516040860151606087015161ffff908116600160781b0261ffff60781b1960e09390931c6b010000000000000000000000029290921665ffffffffffff60581b196001600160481b0390941662010000026001600160581b031990961691909716179390931716939093171781556080830151805184936200024792600b92910190620002ea565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516200027c9190620005dd565b60405180910390a150565b60065461010090046001600160a01b03163314620002e85760405162461bcd60e51b815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640162000099565b565b828054828255906000526020600020906007016008900481019282156200038e5791602002820160005b838211156200035a57835183826101000a81548163ffffffff021916908363ffffffff160217905550926020019260040160208160030104928301926001030262000314565b80156200038c5782816101000a81549063ffffffff02191690556004016020816003010492830192600103026200035a565b505b506200039c929150620003a0565b5090565b5b808211156200039c5760008155600101620003a1565b634e487b7160e01b600052604160045260246000fd5b60405160a081016001600160401b0381118282101715620003f257620003f2620003b7565b60405290565b604051601f8201601f191681016001600160401b0381118282101715620004235762000423620003b7565b604052919050565b805161ffff811681146200043e57600080fd5b919050565b600082601f8301126200045557600080fd5b815160206001600160401b03821115620004735762000473620003b7565b8160051b62000484828201620003f8565b92835284810182019282810190878511156200049f57600080fd5b83870192505b84831015620004d457825163ffffffff81168114620004c45760008081fd5b82529183019190830190620004a5565b979650505050505050565b60008060408385031215620004f357600080fd5b82516001600160a01b03811681146200050b57600080fd5b60208401519092506001600160401b03808211156200052957600080fd5b9084019060a082870312156200053e57600080fd5b62000548620003cd565b62000553836200042b565b815260208301516001600160481b03811681146200057057600080fd5b602082015260408301516001600160e01b0319811681146200059157600080fd5b6040820152620005a4606084016200042b565b6060820152608083015182811115620005bc57600080fd5b620005ca8882860162000443565b6080830152508093505050509250929050565b6020808252825161ffff90811683830152838201516001600160481b03166040808501919091528401516001600160e01b0319166060808501919091528401511660808084019190915283015160a080840152805160c0840181905260009291820190839060e08601905b808310156200067057835163ffffffff16825292840192600192909201919084019062000648565b509695505050505050565b608051615ba1620006b3600039600081816113b40152818161218701528181612a7f01528181612b4301526132be0152615ba16000f3fe608060405234801561001057600080fd5b50600436106102de5760003560e01c80637341c10c11610186578063aab396bd116100e3578063d7ae1d3011610097578063e82ad7d411610071578063e82ad7d4146106bf578063ea320e0b146106d2578063f2fde38b146106e557600080fd5b8063d7ae1d3014610686578063e72f6e3014610699578063e82622aa146106ac57600080fd5b8063badc3eb6116100c8578063badc3eb614610648578063c3f909d41461065e578063cc77470a1461067357600080fd5b8063aab396bd14610638578063b734c0f41461064057600080fd5b80639f87fad71161013a578063a47c76961161011f578063a47c7696146105f2578063a4c0ed3614610612578063a9c9a9181461062557600080fd5b80639f87fad7146105d7578063a21a23e4146105ea57600080fd5b8063823597401161016b57806382359740146105995780638456cb59146105ac5780638da5cb5b146105b457600080fd5b80637341c10c1461057e57806379ba50971461059157600080fd5b80633f4ba83a1161023f5780635c975abb116101f357806366419970116101cd57806366419970146104d6578063674603d0146104fd5780636a2215de1461054657600080fd5b80635c975abb146104995780635ed6dfba146104b057806366316d8d146104c357600080fd5b8063461d276211610224578063461d2762146104455780634b8832d31461045857806355fedefa1461046b57600080fd5b80633f4ba83a1461041c57806341db4ca31461042457600080fd5b80631ded3b36116102965780632a905ccc1161027b5780632a905ccc146103ba57806333060529146103e85780633e871e4d1461040957600080fd5b80631ded3b361461039457806321b60e7f146103a757600080fd5b806310fc49c1116102c757806310fc49c11461031857806312b583491461032b578063181f5a771461034b57600080fd5b806302bcc5b6146102e35780630c5d49cb146102f8575b600080fd5b6102f66102f136600461487a565b6106f8565b005b610300608481565b60405161ffff90911681526020015b60405180910390f35b6102f66103263660046148bb565b610757565b6000546040516bffffffffffffffffffffffff909116815260200161030f565b6103876040518060400160405280601781526020017f46756e6374696f6e7320526f757465722076312e302e3000000000000000000081525081565b60405161030f9190614962565b6102f66103a2366004614975565b610853565b6102f66103b5366004614b38565b610885565b600a5462010000900468ffffffffffffffffff1660405168ffffffffffffffffff909116815260200161030f565b6103fb6103f6366004614de4565b6109b2565b60405161030f929190614ecc565b6102f6610417366004614f59565b610d8a565b6102f661100f565b61043761043236600461505b565b611021565b60405190815260200161030f565b61043761045336600461505b565b611081565b6102f66104663660046150df565b61108d565b61043761047936600461487a565b67ffffffffffffffff166000908152600360208190526040909120015490565b60065460ff165b604051901515815260200161030f565b6102f66104be36600461510d565b6111db565b6102f66104d136600461510d565b6113fd565b60025467ffffffffffffffff165b60405167ffffffffffffffff909116815260200161030f565b61051061050b36600461513b565b61154f565b6040805182511515815260208084015167ffffffffffffffff90811691830191909152928201519092169082015260600161030f565b610559610554366004615169565b6115df565b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200161030f565b6102f661058c3660046150df565b61169e565b6102f6611852565b6102f66105a736600461487a565b611979565b6102f6611ac0565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16610559565b6102f66105e53660046150df565b611ad0565b6104e4611ea5565b61060561060036600461487a565b612032565b60405161030f91906151d3565b6102f661062036600461525b565b612167565b610559610633366004615169565b6123b3565b600954610437565b6102f6612412565b61065061255e565b60405161030f9291906152b7565b61066661262e565b60405161030f919061530e565b6104e46106813660046153b8565b612763565b6102f66106943660046150df565b6129e3565b6102f66106a73660046153b8565b612a46565b6102f66106ba3660046153d5565b612bbf565b6104a06106cd36600461487a565b612e90565b6102f66106e0366004615169565b612fdf565b6102f66106f33660046153b8565b612fec565b610700612ffd565b61070981613005565b67ffffffffffffffff81166000908152600360205260409020546107549082906c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661307b565b50565b67ffffffffffffffff8216600090815260036020819052604082200154600b54911a9081106107bc576040517f45c108ce00000000000000000000000000000000000000000000000000000000815260ff821660048201526024015b60405180910390fd5b6000600a6001018260ff16815481106107d7576107d761544b565b90600052602060002090600891828204019190066004029054906101000a900463ffffffff1690508063ffffffff168363ffffffff16111561084d576040517f1d70f87a00000000000000000000000000000000000000000000000000000000815263ffffffff821660048201526024016107b3565b50505050565b61085b612ffd565b61086482613005565b67ffffffffffffffff90911660009081526003602081905260409091200155565b61088d613367565b8051600a80546020808501516040860151606087015161ffff9081166f01000000000000000000000000000000027fffffffffffffffffffffffffffffff0000ffffffffffffffffffffffffffffff60e09390931c6b01000000000000000000000002929092167fffffffffffffffffffffffffffffff000000000000ffffffffffffffffffffff68ffffffffffffffffff90941662010000027fffffffffffffffffffffffffffffffffffffffffff0000000000000000000000909616919097161793909317169390931717815560808301518051849361097492600b929101906146c5565b509050507f049ce2e6e1420eb4b07b425e90129186833eb346bda40b37d5d921aad482f71c816040516109a7919061530e565b60405180910390a150565b6000806109bd6133ed565b826020015173ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610a26576040517f8bec23e700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b8251600090815260056020526040902054610a885782516020840151604051600294507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a78918890879061547a565b60405180910390a2506000610d7f565b8251600090815260056020908152604091829020549151610aab918691016154ac565b6040516020818303038152906040528051906020012014610b035782516020840151604051600694507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a78918890879061547a565b8261012001518360a0015163ffffffff16610b1e9190615608565b64ffffffffff165a1015610b695782516020840151604051600494507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610a78918890879061547a565b6000610b7e8460a0015163ffffffff166133f5565b610b88908861562d565b9050600081878660c0015168ffffffffffffffffff16610ba89190615655565b610bb29190615655565b9050610bc18560800151612032565b600001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c395784516020860151604051600596507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a90899061547a565b60405180910390a25060009150610d7f9050565b84604001516bffffffffffffffffffffffff16816bffffffffffffffffffffffff161115610c9e5784516020860151604051600396507f1a90e9a50793db2e394cf581e7c522e10c358a81e70acf6b5a0edd620c08dee191610c25918a90899061547a565b505082516000908152600560205260408120819055835160a08501516060860151610cce92918c918c9190613497565b8051909150610cde576001610ce1565b60005b92506000610d1b8560800151866040015187606001518860c0015168ffffffffffffffffff168c610d1588602001516133f5565b8d613626565b9050846080015167ffffffffffffffff1685600001517f64778f26c70b60a8d7e29e2451b3844302d959448401c0535b768ed88c6b505e836020015189888f8f8960400151604051610d729695949392919061567a565b60405180910390a3519150505b965096945050505050565b610d92613367565b8151815181141580610da45750600881115b15610ddb576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60005b81811015610ecd576000848281518110610dfa57610dfa61544b565b602002602001015190506000848381518110610e1857610e1861544b565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff161480610e83575060008281526008602052604090205473ffffffffffffffffffffffffffffffffffffffff8281169116145b15610eba576040517fee03280800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b505080610ec6906156fd565b9050610dde565b506040805180820190915283815260208082018490528451600c91610ef6918391880190614770565b506020828101518051610f0f92600185019201906147ab565b5090505060005b835181101561084d577f8b052f0f4bf82fede7daffea71592b29d5ef86af1f3c7daaa0345dbb2f52f481848281518110610f5257610f5261544b565b602002602001015160086000878581518110610f7057610f7061544b565b6020026020010151815260200190815260200160002060009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16858481518110610fb957610fb961544b565b6020026020010151604051610ff79392919092835273ffffffffffffffffffffffffffffffffffffffff918216602084015216604082015260600190565b60405180910390a1611008816156fd565b9050610f16565b611017613367565b61101f6139a8565b565b60008061102d836115df565b905061107583828a8a8a8080601f0160208091040260200160405190810160405280939291908181526020018383808284376000920191909152508c92508b9150613a259050565b98975050505050505050565b60008061102d836123b3565b6110956133ed565b61109e82613dce565b6110a6613e94565b73ffffffffffffffffffffffffffffffffffffffff8116158061110d575067ffffffffffffffff821660009081526003602052604090206001015473ffffffffffffffffffffffffffffffffffffffff8281166c0100000000000000000000000090920416145b15611144576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff821660008181526003602090815260409182902060010180546bffffffffffffffffffffffff166c0100000000000000000000000073ffffffffffffffffffffffffffffffffffffffff8716908102919091179091558251338152918201527f69436ea6df009049404f564eff6622cd00522b0bd6a89efd9e52a355c4a879be910160405180910390a25050565b6111e3612ffd565b806bffffffffffffffffffffffff166000036112195750306000908152600160205260409020546bffffffffffffffffffffffff165b306000908152600160205260409020546bffffffffffffffffffffffff908116908216811015611285576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff808416911610156112ee576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b306000908152600160205260408120805484929061131b9084906bffffffffffffffffffffffff16615735565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550816000808282829054906101000a90046bffffffffffffffffffffffff166113719190615735565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055506113f883836bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613f9e9092919063ffffffff16565b505050565b6114056133ed565b806bffffffffffffffffffffffff1660000361144d576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b336000908152600160205260409020546bffffffffffffffffffffffff9081169082168110156114b9576040517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff821660048201526024016107b3565b6000546bffffffffffffffffffffffff80841691161015611522576000546040517fdda2b2160000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff918216600482015290831660248201526044016107b3565b336000908152600160205260408120805484929061131b9084906bffffffffffffffffffffffff16615735565b60408051606080820183526000808352602080840182905292840181905273ffffffffffffffffffffffffffffffffffffffff861681526004835283812067ffffffffffffffff868116835290845290849020845192830185525460ff81161515835261010081048216938301939093526901000000000000000000909204909116918101919091525b92915050565b6000805b600c5460ff8216101561166857600c805460ff83169081106116075761160761544b565b9060005260206000200154830361165857600d805460ff831690811061162f5761162f61544b565b60009182526020909120015473ffffffffffffffffffffffffffffffffffffffff169392505050565b6116618161575a565b90506115e3565b506040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018390526024016107b3565b6116a66133ed565b6116af82613dce565b6116b7613e94565b60006116c6600a5461ffff1690565b67ffffffffffffffff841660009081526003602052604090206002015490915061ffff82169003611729576040517fb72bc70300000000000000000000000000000000000000000000000000000000815261ffff821660048201526024016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8716845290915290205460ff161561177157505050565b73ffffffffffffffffffffffffffffffffffffffff8216600081815260046020908152604080832067ffffffffffffffff881680855290835281842080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00166001908117909155600384528285206002018054918201815585529383902090930180547fffffffffffffffffffffffff000000000000000000000000000000000000000016851790555192835290917f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e091015b60405180910390a2505050565b60075473ffffffffffffffffffffffffffffffffffffffff1633146118d3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016107b3565b600680547fffffffffffffffffffffff0000000000000000000000000000000000000000ff81166101003381810292909217909355600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001690556040519290910473ffffffffffffffffffffffffffffffffffffffff169182907f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e090600090a350565b6119816133ed565b611989613e94565b67ffffffffffffffff81166000908152600360205260409020805460019091015473ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481169290910416338114611a29576040517f4e1d9f1800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff821660048201526024016107b3565b67ffffffffffffffff831660008181526003602090815260409182902080546c01000000000000000000000000339081026bffffffffffffffffffffffff928316178355600190920180549091169055825173ffffffffffffffffffffffffffffffffffffffff87168152918201527f6f1dc65165ffffedfd8e507b4a0f1fcfdada045ed11f6c26ba27cedfe87802f09101611845565b611ac8613367565b61101f61402b565b611ad86133ed565b611ae182613dce565b611ae9613e94565b73ffffffffffffffffffffffffffffffffffffffff8116600090815260046020908152604080832067ffffffffffffffff8087168552908352928190208151606081018352905460ff8116151580835261010082048616948301949094526901000000000000000000900490931690830152611b91576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b806040015167ffffffffffffffff16816020015167ffffffffffffffff1614611be6576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8316600090815260036020908152604080832060020180548251818502810185019093528083529192909190830182828015611c6157602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311611c36575b5050505050905060005b8151811015611e09578373ffffffffffffffffffffffffffffffffffffffff16828281518110611c9d57611c9d61544b565b602002602001015173ffffffffffffffffffffffffffffffffffffffff1603611df9578160018351611ccf9190615779565b81518110611cdf57611cdf61544b565b6020026020010151600360008767ffffffffffffffff1667ffffffffffffffff1681526020019081526020016000206002018281548110611d2257611d2261544b565b600091825260208083209190910180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff949094169390931790925567ffffffffffffffff87168152600390915260409020600201805480611d9c57611d9c61578c565b60008281526020902081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff90810180547fffffffffffffffffffffffff0000000000000000000000000000000000000000169055019055611e09565b611e02816156fd565b9050611c6b565b5073ffffffffffffffffffffffffffffffffffffffff8316600081815260046020908152604080832067ffffffffffffffff89168085529083529281902080547fffffffffffffffffffffffffffffff00000000000000000000000000000000001690555192835290917f182bff9831466789164ca77075fffd84916d35a8180ba73c27e45634549b445b91015b60405180910390a250505050565b6000611eaf6133ed565b611eb7613e94565b60028054600090611ed19067ffffffffffffffff166157bb565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015611f47578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff9384161784559386015160608701519091169093029216919091176001820155608083015180519192611fe2926002850192909101906147ab565b5060a0919091015160039091015560405133815267ffffffffffffffff8216907f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf9060200160405180910390a290565b6040805160c0810182526000808252602082018190529181018290526060808201839052608082015260a081019190915261206c82613005565b67ffffffffffffffff8216600090815260036020908152604091829020825160c08101845281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c0100000000000000000000000092839004811684870152600185015491821684880152919004166060820152600282018054855181860281018601909652808652919492936080860193929083018282801561214d57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612122575b505050505081526020016003820154815250509050919050565b61216f6133ed565b3373ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016146121de576040517f44b0e3c300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208114612218576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60006122268284018461487a565b67ffffffffffffffff81166000908152600360205260409020549091506c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1661229f576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8116600090815260036020526040812080546bffffffffffffffffffffffff16918691906122d68385615655565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550846000808282829054906101000a90046bffffffffffffffffffffffff1661232c9190615655565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff1602179055508167ffffffffffffffff167fd39ec07f4e209f627a4c427971473820dc129761ba28de8906bd56f57101d4f882878461239391906157e2565b6040805192835260208301919091520160405180910390a2505050505050565b60008181526008602052604081205473ffffffffffffffffffffffffffffffffffffffff16806115d9576040517f80833e33000000000000000000000000000000000000000000000000000000008152600481018490526024016107b3565b61241a613367565b60005b600c5481101561253d576000600c600001828154811061243f5761243f61544b565b906000526020600020015490506000600c60010183815481106124645761246461544b565b6000918252602080832091909101548483526008825260409283902054835186815273ffffffffffffffffffffffffffffffffffffffff91821693810193909352169181018290529091507ff8a6175bca1ba37d682089187edc5e20a859989727f10ca6bd9a5bc0de8caf949060600160405180910390a160009182526008602052604090912080547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff909216919091179055612536816156fd565b905061241d565b50600c600061254c8282614825565b61255a600183016000614825565b5050565b606080600c600001600c600101818054806020026020016040519081016040528092919081815260200182805480156125b657602002820191906000526020600020905b8154815260200190600101908083116125a2575b505050505091508080548060200260200160405190810160405280929190818152602001828054801561261f57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff1681526001909101906020018083116125f4575b50505050509050915091509091565b6040805160a08101825260008082526020820181905291810182905260608082019290925260808101919091526040805160a081018252600a805461ffff808216845268ffffffffffffffffff620100008304166020808601919091527fffffffff000000000000000000000000000000000000000000000000000000006b010000000000000000000000840460e01b16858701526f01000000000000000000000000000000909204166060840152600b80548551818402810184019096528086529394929360808601939283018282801561275557602002820191906000526020600020906000905b82829054906101000a900463ffffffff1663ffffffff16815260200190600401906020826003010492830192600103820291508084116127185790505b505050505081525050905090565b600061276d6133ed565b612775613e94565b6002805460009061278f9067ffffffffffffffff166157bb565b825467ffffffffffffffff8083166101009490940a93840293021916919091179091556040805160c0810182526000808252336020830152918101829052606081018290529192506080820190604051908082528060200260200182016040528015612805578160200160208202803683370190505b5081526000602091820181905267ffffffffffffffff841681526003825260409081902083518484015173ffffffffffffffffffffffffffffffffffffffff9081166c010000000000000000000000009081026bffffffffffffffffffffffff93841617845593860151606087015190911690930292169190911760018201556080830151805191926128a0926002850192909101906147ab565b5060a0919091015160039182015567ffffffffffffffff82166000818152602092835260408082206002018054600180820183559184528584200180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff891690811790915583526004855281832084845285529181902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00169092179091555133815290917f464722b4166576d3dcbba877b999bc35cf911f4eaf434b7eba68fa113951d0bf910160405180910390a260405173ffffffffffffffffffffffffffffffffffffffff8316815267ffffffffffffffff8216907f43dc749a04ac8fb825cbd514f7c0e13f13bc6f2ee66043b76629d51776cff8e09060200160405180910390a2919050565b6129eb6133ed565b6129f482613dce565b6129fc613e94565b612a0582612e90565b15612a3c576040517f06eb10c800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61255a828261307b565b612a4e612ffd565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015612adb573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612aff91906157f5565b6000549091506bffffffffffffffffffffffff16818110156113f8576000612b278284615779565b9050612b6a73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168583613f9e565b6040805173ffffffffffffffffffffffffffffffffffffffff86168152602081018390527f59bfc682b673f8cbf945f1e454df9334834abf7dfe7f92237ca29ecb9b436600910160405180910390a150505050565b612bc76133ed565b60005b818110156113f8576000838383818110612be657612be661544b565b90506101600201803603810190612bfd919061580e565b80516080820151600082815260056020908152604091829020549151949550929391929091612c2e918691016154ac565b6040516020818303038152906040528051906020012014612c7b576040517f8129bbcd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b82610140015163ffffffff16421015612cc0576040517fa2376fe800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60208301516040517f85b214cf0000000000000000000000000000000000000000000000000000000081526004810184905273ffffffffffffffffffffffffffffffffffffffff909116906385b214cf906024016020604051808303816000875af1158015612d33573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190612d57919061582b565b5060408084015167ffffffffffffffff831660009081526003602052918220600101805491929091612d989084906bffffffffffffffffffffffff16615735565b82546bffffffffffffffffffffffff9182166101009390930a928302919092021990911617905550606083015173ffffffffffffffffffffffffffffffffffffffff16600090815260046020908152604080832067ffffffffffffffff808616855292529091208054600192600991612e20918591690100000000000000000090041661584d565b825467ffffffffffffffff9182166101009390930a9283029190920219909116179055506000828152600560205260408082208290555183917ff1ca1e9147be737b04a2b018a79405f687a97de8dd8a2559bbe62357343af41491a250505080612e89906156fd565b9050612bca565b67ffffffffffffffff8116600090815260036020908152604080832060020180548251818502810185019093528083528493830182828015612f0857602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311612edd575b5050505050905060005b8151811015612fd557600060046000848481518110612f3357612f3361544b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff808a168352908452908290208251606081018452905460ff8116151582526101008104831694820185905269010000000000000000009004909116918101829052925014612fc457506001949350505050565b50612fce816156fd565b9050612f12565b5060009392505050565b612fe7613367565b600955565b612ff4613367565b61075481614086565b61101f613367565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff16610754576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff82166000908152600360209081526040808320815160c08101835281546bffffffffffffffffffffffff808216835273ffffffffffffffffffffffffffffffffffffffff6c010000000000000000000000009283900481168488015260018501549182168487015291900416606082015260028201805484518187028101870190955280855291949293608086019390929083018282801561315c57602002820191906000526020600020905b815473ffffffffffffffffffffffffffffffffffffffff168152600190910190602001808311613131575b505050918352505060039190910154602090910152805190915060005b82608001515181101561321d5760046000846080015183815181106131a0576131a061544b565b60209081029190910181015173ffffffffffffffffffffffffffffffffffffffff168252818101929092526040908101600090812067ffffffffffffffff89168252909252902080547fffffffffffffffffffffffffffffff0000000000000000000000000000000000169055613216816156fd565b9050613179565b5067ffffffffffffffff84166000908152600360205260408120818155600181018290559061324f6002830182614825565b5060006003919091018190558054829190819061327b9084906bffffffffffffffffffffffff16615735565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff16021790555061330283826bffffffffffffffffffffffff167f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16613f9e9092919063ffffffff16565b6040805173ffffffffffffffffffffffffffffffffffffffff851681526bffffffffffffffffffffffff8316602082015267ffffffffffffffff8616917fe8ed5b475a5b5987aa9165e8731bb78043f39eee32ec5a1169a89e27fcd498159101611e97565b600654610100900473ffffffffffffffffffffffffffffffffffffffff16331461101f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016107b3565b61101f614182565b60006bffffffffffffffffffffffff821115613493576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203960448201527f362062697473000000000000000000000000000000000000000000000000000060648201526084016107b3565b5090565b60408051606080820183526000808352602083015291810191909152600a546040516000916b010000000000000000000000900460e01b906134e19089908990899060240161586e565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152918152602080830180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff000000000000000000000000000000000000000000000000000000009590951694909417909352600a548151608480825260c0820190935292945061ffff6f0100000000000000000000000000000090910416926000928392839282018180368337019050509050863b6135ac57600080fd5b5a848110156135ba57600080fd5b84900360408104810389106135ce57600080fd5b505a60008087516020890160008c8ef193505a900391503d60848111156135f3575060845b808252806000602084013e5060408051606081018252931515845260208401929092529082015298975050505050505050565b60408051808201909152600080825260208201526000613646848661562d565b90506000816136558886615655565b61365f9190615655565b67ffffffffffffffff8b166000908152600360205260409020549091506bffffffffffffffffffffffff808316911610156136f25767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812080548392906137299084906bffffffffffffffffffffffff16615735565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915567ffffffffffffffff8c166000908152600360205260409020600101548b82169116101590506137d65767ffffffffffffffff8a16600090815260036020526040908190205490517f6b0fe56f0000000000000000000000000000000000000000000000000000000081526bffffffffffffffffffffffff90911660048201526024016107b3565b67ffffffffffffffff8a16600090815260036020526040812060010180548b92906138109084906bffffffffffffffffffffffff16615735565b92506101000a8154816bffffffffffffffffffffffff02191690836bffffffffffffffffffffffff160217905550818461384a9190615655565b33600090815260016020526040812080549091906138779084906bffffffffffffffffffffffff16615655565b82546101009290920a6bffffffffffffffffffffffff81810219909316918316021790915530600090815260016020526040812080548b945090926138be91859116615655565b82546bffffffffffffffffffffffff9182166101009390930a92830291909202199091161790555073ffffffffffffffffffffffffffffffffffffffff8816600090815260046020908152604080832067ffffffffffffffff808f16855292529091208054600192600991613942918591690100000000000000000090041661584d565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff1602179055506040518060400160405280836bffffffffffffffffffffffff168152602001826bffffffffffffffffffffffff1681525092505050979650505050505050565b6139b06141ef565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690557f5db9ee0a495bf2e6ff9c91a7834c1ba4fdd244a5e8aa4e537bd38aeae4b073aa335b60405173ffffffffffffffffffffffffffffffffffffffff909116815260200160405180910390a1565b6000613a2f6133ed565b613a3885613005565b613a42338661425b565b613a4c8583610757565b8351600003613a86576040517ec1cfc000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000613a9186612032565b90506000613a9f338861154f565b905060008873ffffffffffffffffffffffffffffffffffffffff1663a631571e6040518061016001604052808a8152602001613af58c67ffffffffffffffff166000908152600360208190526040909120015490565b815233602082015260408781015188519190920191613b1391615735565b6bffffffffffffffffffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018b67ffffffffffffffff168152602001856020015167ffffffffffffffff1681526020018863ffffffff1681526020018961ffff168152602001856040015167ffffffffffffffff168152602001866020015173ffffffffffffffffffffffffffffffffffffffff168152506040518263ffffffff1660e01b8152600401613bd99190615899565b610160604051808303816000875af1158015613bf9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613c1d91906159fe565b9050604051806101600160405280826000015181526020018a73ffffffffffffffffffffffffffffffffffffffff16815260200182604001516bffffffffffffffffffffffff1681526020013373ffffffffffffffffffffffffffffffffffffffff1681526020018967ffffffffffffffff1681526020018663ffffffff168152602001600a60000160029054906101000a900468ffffffffffffffffff1668ffffffffffffffffff1681526020018260e0015168ffffffffffffffffff16815260200182610100015164ffffffffff16815260200182610120015164ffffffffff16815260200182610140015163ffffffff16815250604051602001613d2491906154ac565b60405160208183030381529060405280519060200120600560008360000151815260200190815260200160002081905550613d64338983604001516142cf565b8767ffffffffffffffff168a82600001517ff67aec45c9a7ede407974a3e0c3a743dffeab99ee3f2d4c9a8144c2ebf2c7ec9866020015133328d8d8d8a60400151604051613db89796959493929190615ad1565b60405180910390a4519998505050505050505050565b67ffffffffffffffff81166000908152600360205260409020546c01000000000000000000000000900473ffffffffffffffffffffffffffffffffffffffff1680613e45576040517f1f6a65b600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3373ffffffffffffffffffffffffffffffffffffffff82161461255a576040517f5a68151d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60095460009081526008602052604090205473ffffffffffffffffffffffffffffffffffffffff1680613ec45750565b604080516000815260208101918290527f6b14daf80000000000000000000000000000000000000000000000000000000090915273ffffffffffffffffffffffffffffffffffffffff821690636b14daf890613f2590339060248101615b49565b602060405180830381865afa158015613f42573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190613f66919061582b565b610754576040517f229062630000000000000000000000000000000000000000000000000000000081523360048201526024016107b3565b6040805173ffffffffffffffffffffffffffffffffffffffff8416602482015260448082018490528251808303909101815260649091019091526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fa9059cbb000000000000000000000000000000000000000000000000000000001790526113f89084906143aa565b614033614182565b600680547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001660011790557f62e78cea01bee320cd4e420270b5ea74000d11b0c9f74754ebdbfc544b05a2586139fb3390565b3373ffffffffffffffffffffffffffffffffffffffff821603614105576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016107b3565b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff838116918217909255600654604051919261010090910416907fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae127890600090a350565b60065460ff161561101f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f5061757361626c653a207061757365640000000000000000000000000000000060448201526064016107b3565b60065460ff1661101f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f5061757361626c653a206e6f742070617573656400000000000000000000000060448201526064016107b3565b73ffffffffffffffffffffffffffffffffffffffff8216600090815260046020908152604080832067ffffffffffffffff8516845290915290205460ff1661255a576040517f71e8313700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b67ffffffffffffffff8216600090815260036020526040812060010180548392906143099084906bffffffffffffffffffffffff16615655565b82546bffffffffffffffffffffffff91821661010093840a908102920219161790915573ffffffffffffffffffffffffffffffffffffffff8516600090815260046020908152604080832067ffffffffffffffff808916855292529091208054600194509092849261437f92849290041661584d565b92506101000a81548167ffffffffffffffff021916908367ffffffffffffffff160217905550505050565b600061440c826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166144b69092919063ffffffff16565b8051909150156113f8578080602001905181019061442a919061582b565b6113f8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016107b3565b60606144c584846000856144cd565b949350505050565b60608247101561455f576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016107b3565b6000808673ffffffffffffffffffffffffffffffffffffffff1685876040516145889190615b78565b60006040518083038185875af1925050503d80600081146145c5576040519150601f19603f3d011682016040523d82523d6000602084013e6145ca565b606091505b50915091506145db878383876145e6565b979650505050505050565b6060831561467c5782516000036146755773ffffffffffffffffffffffffffffffffffffffff85163b614675576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016107b3565b50816144c5565b6144c583838151156146915781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107b39190614962565b828054828255906000526020600020906007016008900481019282156147645791602002820160005b8382111561473257835183826101000a81548163ffffffff021916908363ffffffff16021790555092602001926004016020816003010492830192600103026146ee565b80156147625782816101000a81549063ffffffff0219169055600401602081600301049283019260010302614732565b505b5061349392915061483f565b828054828255906000526020600020908101928215614764579160200282015b82811115614764578251825591602001919060010190614790565b828054828255906000526020600020908101928215614764579160200282015b8281111561476457825182547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff9091161782556020909201916001909101906147cb565b508054600082559060005260206000209081019061075491905b5b808211156134935760008155600101614840565b67ffffffffffffffff8116811461075457600080fd5b803561487581614854565b919050565b60006020828403121561488c57600080fd5b813561489781614854565b9392505050565b63ffffffff8116811461075457600080fd5b80356148758161489e565b600080604083850312156148ce57600080fd5b82356148d981614854565b915060208301356148e98161489e565b809150509250929050565b60005b8381101561490f5781810151838201526020016148f7565b50506000910152565b600081518084526149308160208601602086016148f4565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b6020815260006148976020830184614918565b6000806040838503121561498857600080fd5b823561499381614854565b946020939093013593505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b60405160a0810167ffffffffffffffff811182821017156149f3576149f36149a1565b60405290565b604051610160810167ffffffffffffffff811182821017156149f3576149f36149a1565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715614a6457614a646149a1565b604052919050565b803561ffff8116811461487557600080fd5b68ffffffffffffffffff8116811461075457600080fd5b803561487581614a7e565b600067ffffffffffffffff821115614aba57614aba6149a1565b5060051b60200190565b600082601f830112614ad557600080fd5b81356020614aea614ae583614aa0565b614a1d565b82815260059290921b84018101918181019086841115614b0957600080fd5b8286015b84811015614b2d578035614b208161489e565b8352918301918301614b0d565b509695505050505050565b600060208284031215614b4a57600080fd5b813567ffffffffffffffff80821115614b6257600080fd5b9083019060a08286031215614b7657600080fd5b614b7e6149d0565b614b8783614a6c565b81526020830135614b9781614a7e565b602082015260408301357fffffffff0000000000000000000000000000000000000000000000000000000081168114614bcf57600080fd5b6040820152614be060608401614a6c565b6060820152608083013582811115614bf757600080fd5b614c0387828601614ac4565b60808301525095945050505050565b600082601f830112614c2357600080fd5b813567ffffffffffffffff811115614c3d57614c3d6149a1565b614c6e60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601614a1d565b818152846020838601011115614c8357600080fd5b816020850160208301376000918101602001919091529392505050565b6bffffffffffffffffffffffff8116811461075457600080fd5b803561487581614ca0565b73ffffffffffffffffffffffffffffffffffffffff8116811461075457600080fd5b803561487581614cc5565b64ffffffffff8116811461075457600080fd5b803561487581614cf2565b60006101608284031215614d2357600080fd5b614d2b6149f9565b905081358152614d3d60208301614ce7565b6020820152614d4e60408301614cba565b6040820152614d5f60608301614ce7565b6060820152614d706080830161486a565b6080820152614d8160a083016148b0565b60a0820152614d9260c08301614a95565b60c0820152614da360e08301614a95565b60e0820152610100614db6818401614d05565b90820152610120614dc8838201614d05565b90820152610140614dda8382016148b0565b9082015292915050565b6000806000806000806102008789031215614dfe57600080fd5b863567ffffffffffffffff80821115614e1657600080fd5b614e228a838b01614c12565b97506020890135915080821115614e3857600080fd5b50614e4589828a01614c12565b9550506040870135614e5681614ca0565b93506060870135614e6681614ca0565b92506080870135614e7681614cc5565b9150614e858860a08901614d10565b90509295509295509295565b60078110614ec8577f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b9052565b60408101614eda8285614e91565b6bffffffffffffffffffffffff831660208301529392505050565b600082601f830112614f0657600080fd5b81356020614f16614ae583614aa0565b82815260059290921b84018101918181019086841115614f3557600080fd5b8286015b84811015614b2d578035614f4c81614cc5565b8352918301918301614f39565b60008060408385031215614f6c57600080fd5b823567ffffffffffffffff80821115614f8457600080fd5b818501915085601f830112614f9857600080fd5b81356020614fa8614ae583614aa0565b82815260059290921b84018101918181019089841115614fc757600080fd5b948201945b83861015614fe557853582529482019490820190614fcc565b96505086013592505080821115614ffb57600080fd5b5061500885828601614ef5565b9150509250929050565b60008083601f84011261502457600080fd5b50813567ffffffffffffffff81111561503c57600080fd5b60208301915083602082850101111561505457600080fd5b9250929050565b60008060008060008060a0878903121561507457600080fd5b863561507f81614854565b9550602087013567ffffffffffffffff81111561509b57600080fd5b6150a789828a01615012565b90965094506150ba905060408801614a6c565b925060608701356150ca8161489e565b80925050608087013590509295509295509295565b600080604083850312156150f257600080fd5b82356150fd81614854565b915060208301356148e981614cc5565b6000806040838503121561512057600080fd5b823561512b81614cc5565b915060208301356148e981614ca0565b6000806040838503121561514e57600080fd5b823561515981614cc5565b915060208301356148e981614854565b60006020828403121561517b57600080fd5b5035919050565b600081518084526020808501945080840160005b838110156151c857815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101615196565b509495945050505050565b6020815260006bffffffffffffffffffffffff808451166020840152602084015173ffffffffffffffffffffffffffffffffffffffff8082166040860152826040870151166060860152806060870151166080860152505050608083015160c060a084015261524560e0840182615182565b905060a084015160c08401528091505092915050565b6000806000806060858703121561527157600080fd5b843561527c81614cc5565b935060208501359250604085013567ffffffffffffffff81111561529f57600080fd5b6152ab87828801615012565b95989497509550505050565b604080825283519082018190526000906020906060840190828701845b828110156152f0578151845292840192908401906001016152d4565b505050838103828501526153048186615182565b9695505050505050565b6000602080835260c0830161ffff808651168386015268ffffffffffffffffff838701511660408601527fffffffff00000000000000000000000000000000000000000000000000000000604087015116606086015280606087015116608086015250608085015160a08086015281815180845260e0870191508483019350600092505b80831015614b2d57835163ffffffff168252928401926001929092019190840190615392565b6000602082840312156153ca57600080fd5b813561489781614cc5565b600080602083850312156153e857600080fd5b823567ffffffffffffffff8082111561540057600080fd5b818501915085601f83011261541457600080fd5b81358181111561542357600080fd5b8660206101608302850101111561543957600080fd5b60209290920196919550909350505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b73ffffffffffffffffffffffffffffffffffffffff848116825283166020820152606081016144c56040830184614e91565b815181526020808301516101608301916154dd9084018273ffffffffffffffffffffffffffffffffffffffff169052565b5060408301516154fd60408401826bffffffffffffffffffffffff169052565b506060830151615525606084018273ffffffffffffffffffffffffffffffffffffffff169052565b506080830151615541608084018267ffffffffffffffff169052565b5060a083015161555960a084018263ffffffff169052565b5060c083015161557660c084018268ffffffffffffffffff169052565b5060e083015161559360e084018268ffffffffffffffffff169052565b506101008381015164ffffffffff81168483015250506101208381015164ffffffffff81168483015250506101408381015163ffffffff8116848301525b505092915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b64ffffffffff818116838216019080821115615626576156266155d9565b5092915050565b6bffffffffffffffffffffffff8181168382160280821691908281146155d1576155d16155d9565b6bffffffffffffffffffffffff818116838216019080821115615626576156266155d9565b6bffffffffffffffffffffffff8716815273ffffffffffffffffffffffffffffffffffffffff861660208201526156b46040820186614e91565b60c0606082015260006156ca60c0830186614918565b82810360808401526156dc8186614918565b905082810360a08401526156f08185614918565b9998505050505050505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff820361572e5761572e6155d9565b5060010190565b6bffffffffffffffffffffffff828116828216039080821115615626576156266155d9565b600060ff821660ff8103615770576157706155d9565b60010192915050565b818103818111156115d9576115d96155d9565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603160045260246000fd5b600067ffffffffffffffff8083168181036157d8576157d86155d9565b6001019392505050565b808201808211156115d9576115d96155d9565b60006020828403121561580757600080fd5b5051919050565b6000610160828403121561582157600080fd5b6148978383614d10565b60006020828403121561583d57600080fd5b8151801515811461489757600080fd5b67ffffffffffffffff818116838216019080821115615626576156266155d9565b8381526060602082015260006158876060830185614918565b82810360408401526153048185614918565b60208152600082516101608060208501526158b8610180850183614918565b91506020850151604085015260408501516158eb606086018273ffffffffffffffffffffffffffffffffffffffff169052565b5060608501516bffffffffffffffffffffffff8116608086015250608085015168ffffffffffffffffff811660a08601525060a085015167ffffffffffffffff811660c08601525060c085015167ffffffffffffffff811660e08601525060e08501516101006159628187018363ffffffff169052565b86015190506101206159798682018361ffff169052565b86015190506101406159968682018367ffffffffffffffff169052565b9095015173ffffffffffffffffffffffffffffffffffffffff1693019290925250919050565b805161487581614cc5565b805161487581614ca0565b805161487581614854565b80516148758161489e565b805161487581614a7e565b805161487581614cf2565b60006101608284031215615a1157600080fd5b615a196149f9565b82518152615a29602084016159bc565b6020820152615a3a604084016159c7565b6040820152615a4b606084016159bc565b6060820152615a5c608084016159d2565b6080820152615a6d60a084016159dd565b60a0820152615a7e60c084016159e8565b60c0820152615a8f60e084016159e8565b60e0820152610100615aa28185016159f3565b90820152610120615ab48482016159f3565b90820152610140615ac68482016159dd565b908201529392505050565b600073ffffffffffffffffffffffffffffffffffffffff808a168352808916602084015280881660408401525060e06060830152615b1260e0830187614918565b61ffff9590951660808301525063ffffffff9290921660a08301526bffffffffffffffffffffffff1660c090910152949350505050565b73ffffffffffffffffffffffffffffffffffffffff831681526040602082015260006144c56040830184614918565b60008251615b8a8184602087016148f4565b919091019291505056fea164736f6c6343000813000a", } var FunctionsRouterABI = FunctionsRouterMetaData.ABI @@ -1934,14 +1934,15 @@ func (it *FunctionsRouterRequestProcessedIterator) Close() error { } type FunctionsRouterRequestProcessed struct { - RequestId [32]byte - SubscriptionId uint64 - TotalCostJuels *big.Int - Transmitter common.Address - ResultCode uint8 - Response []byte - ReturnData []byte - Raw types.Log + RequestId [32]byte + SubscriptionId uint64 + TotalCostJuels *big.Int + Transmitter common.Address + ResultCode uint8 + Response []byte + Err []byte + CallbackReturnData []byte + Raw types.Log } func (_FunctionsRouter *FunctionsRouterFilterer) FilterRequestProcessed(opts *bind.FilterOpts, requestId [][32]byte, subscriptionId []uint64) (*FunctionsRouterRequestProcessedIterator, error) { @@ -3389,7 +3390,7 @@ func (FunctionsRouterRequestNotProcessed) Topic() common.Hash { } func (FunctionsRouterRequestProcessed) Topic() common.Hash { - return common.HexToHash("0x47ffcaa55fde21cc7135c65541826c9e65dda59c29dc109aae964989e8fc664b") + return common.HexToHash("0x64778f26c70b60a8d7e29e2451b3844302d959448401c0535b768ed88c6b505e") } func (FunctionsRouterRequestStart) Topic() common.Hash { diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 39517dd0e83..8c467632fc1 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -6,7 +6,7 @@ functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClien functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 7b2fb23e2f49121dfe4b096de5e60fe57be0a196c2423a4693293c23c96f9af4 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c -functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin ad1af30b1fdd2818e3ba75f7bf2e058d7bf134cf7d243dc7e5d4108975a1af64 +functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin dd1d3527e19d65efe029c4a131ded44dc0ca961e5c4f459743992435431ec478 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d ocr2dr_client: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClient.bin 84aa63f9dbc5c7eac240db699b09e613ca4c6cd56dab10bdc25b02461b717e21 ocr2dr_client_example: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsClientExample.bin a978d9b52a5a2da19eef0975979de256e62980a0cfb3084fe6d66a351b4ef534 From f05f6d0efc08885e75b1b09fbac6f1bf9936cb77 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Tue, 22 Aug 2023 20:48:58 -0400 Subject: [PATCH 241/270] generate wrappers for testing purpose (#10306) * generate wrappers for testing purpose * update --- .../native_solc_compile_all_automation | 1 + .../tests/LogTriggeredFeedLookup.sol | 9 +- contracts/src/v0.8/tests/MercuryUpkeep.sol | 2 +- .../dummy_protocol_wrapper.go | 751 ++++++++++++++++++ .../log_triggered_feed_lookup_wrapper.go | 32 +- .../mercury_upkeep_wrapper.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 5 +- core/gethwrappers/go_generate.go | 1 + 8 files changed, 793 insertions(+), 10 deletions(-) create mode 100644 core/gethwrappers/generated/dummy_protocol_wrapper/dummy_protocol_wrapper.go diff --git a/contracts/scripts/native_solc_compile_all_automation b/contracts/scripts/native_solc_compile_all_automation index 96dbc96c718..b6de82b8892 100755 --- a/contracts/scripts/native_solc_compile_all_automation +++ b/contracts/scripts/native_solc_compile_all_automation @@ -61,6 +61,7 @@ compileContract dev/automation/2_1/interfaces/ILogAutomation.sol compileContract dev/automation/2_1/AutomationUtils2_1.sol compileContract dev/automation/2_1/AutomationForwarderLogic.sol compileContract dev/automation/tests/LogTriggeredFeedLookup.sol +compileContract dev/automation/tests/DummyProtocol.sol compileContract dev/automation/2_1/interfaces/FeedLookupCompatibleInterface.sol compileContract tests/VerifiableLoadUpkeep.sol diff --git a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol index c2d91c90405..f7861c34554 100644 --- a/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol +++ b/contracts/src/v0.8/dev/automation/tests/LogTriggeredFeedLookup.sol @@ -36,12 +36,14 @@ contract LogTriggeredFeedLookup is ILogAutomation, FeedLookupCompatibleInterface // for mercury config bool public useArbitrumBlockNum; + bool public verify; string[] public feedsHex = ["0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"]; string public feedParamKey = "feedIdHex"; string public timeParamKey = "blockNumber"; - constructor(bool _useArbitrumBlockNum) { + constructor(bool _useArbitrumBlockNum, bool _verify) { useArbitrumBlockNum = _useArbitrumBlockNum; + verify = _verify; } function setTimeParamKey(string memory timeParam) external { @@ -81,7 +83,10 @@ contract LogTriggeredFeedLookup is ILogAutomation, FeedLookupCompatibleInterface (bytes[] memory values, bytes memory extraData) = abi.decode(performData, (bytes[], bytes)); (uint256 orderId, uint256 amount, address exchange) = abi.decode(extraData, (uint256, uint256, address)); - bytes memory verifiedResponse = VERIFIER.verify(values[0]); + bytes memory verifiedResponse = ""; + if (verify) { + verifiedResponse = VERIFIER.verify(values[0]); + } emit PerformingLogTriggerUpkeep( tx.origin, diff --git a/contracts/src/v0.8/tests/MercuryUpkeep.sol b/contracts/src/v0.8/tests/MercuryUpkeep.sol index 53a9411568f..cf3ca6be519 100644 --- a/contracts/src/v0.8/tests/MercuryUpkeep.sol +++ b/contracts/src/v0.8/tests/MercuryUpkeep.sol @@ -45,7 +45,7 @@ contract MercuryUpkeep is AutomationCompatibleInterface, FeedLookupCompatibleInt previousPerformBlock = 0; initialBlock = 0; counter = 0; - feedParamKey = "feedIDHex"; // feedIDStr is deprecated + feedParamKey = "feedIdHex"; // feedIDStr is deprecated feeds = [ "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000" diff --git a/core/gethwrappers/generated/dummy_protocol_wrapper/dummy_protocol_wrapper.go b/core/gethwrappers/generated/dummy_protocol_wrapper/dummy_protocol_wrapper.go new file mode 100644 index 00000000000..e7a88fdd06e --- /dev/null +++ b/core/gethwrappers/generated/dummy_protocol_wrapper/dummy_protocol_wrapper.go @@ -0,0 +1,751 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package dummy_protocol_wrapper + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var DummyProtocolMetaData = &bind.MetaData{ + ABI: "[{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"}],\"name\":\"LimitOrderExecuted\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"price\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"LimitOrderSent\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"price\",\"type\":\"uint256\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"LimitOrderWithdrawn\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"}],\"name\":\"executeLimitOrder\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"targetContract\",\"type\":\"address\"},{\"internalType\":\"uint8\",\"name\":\"selector\",\"type\":\"uint8\"},{\"internalType\":\"bytes32\",\"name\":\"t0\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"t1\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"t2\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"t3\",\"type\":\"bytes32\"}],\"name\":\"getAdvancedLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"targetContract\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"t0\",\"type\":\"bytes32\"}],\"name\":\"getBasicLogTriggerConfig\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"logTrigger\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"price\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"sendLimitedOrder\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"price\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"}],\"name\":\"withdrawLimit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b506103e2806100206000396000f3fe608060405234801561001057600080fd5b50600436106100675760003560e01c80636bb17e4c116100505780636bb17e4c1461013d5780639ab74b0e1461013d578063af38c9c21461015057600080fd5b80632065ff7e1461006c5780635f35f80b14610081575b600080fd5b61007f61007a3660046102ad565b6101f0565b005b61012761008f3660046102e2565b6040805160c0808201835273ffffffffffffffffffffffffffffffffffffffff9890981680825260ff97881660208084019182528385019889526060808501988952608080860198895260a095860197885286519283019490945291519099168985015296519688019690965293519486019490945290519184019190915251828401528051808303909301835260e0909101905290565b604051610134919061033f565b60405180910390f35b61007f61014b3660046102ad565b61023a565b61012761015e3660046103ab565b6040805160c0808201835273ffffffffffffffffffffffffffffffffffffffff94909416808252600060208084018281528486019687526060808601848152608080880186815260a0988901968752895195860197909752925160ff168489015297519083015295519581019590955290519184019190915251828401528051808303909301835260e0909101905290565b8073ffffffffffffffffffffffffffffffffffffffff1682847fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd60405160405180910390a4505050565b8073ffffffffffffffffffffffffffffffffffffffff1682847f3e9c37b3143f2eb7e9a2a0f8091b6de097b62efcfe48e1f68847a832e521750a60405160405180910390a4505050565b803573ffffffffffffffffffffffffffffffffffffffff811681146102a857600080fd5b919050565b6000806000606084860312156102c257600080fd5b83359250602084013591506102d960408501610284565b90509250925092565b60008060008060008060c087890312156102fb57600080fd5b61030487610284565b9550602087013560ff8116811461031a57600080fd5b95989597505050506040840135936060810135936080820135935060a0909101359150565b600060208083528351808285015260005b8181101561036c57858101830151858201604001528201610350565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b600080604083850312156103be57600080fd5b6103c783610284565b94602093909301359350505056fea164736f6c6343000810000a", +} + +var DummyProtocolABI = DummyProtocolMetaData.ABI + +var DummyProtocolBin = DummyProtocolMetaData.Bin + +func DeployDummyProtocol(auth *bind.TransactOpts, backend bind.ContractBackend) (common.Address, *types.Transaction, *DummyProtocol, error) { + parsed, err := DummyProtocolMetaData.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(DummyProtocolBin), backend) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &DummyProtocol{DummyProtocolCaller: DummyProtocolCaller{contract: contract}, DummyProtocolTransactor: DummyProtocolTransactor{contract: contract}, DummyProtocolFilterer: DummyProtocolFilterer{contract: contract}}, nil +} + +type DummyProtocol struct { + address common.Address + abi abi.ABI + DummyProtocolCaller + DummyProtocolTransactor + DummyProtocolFilterer +} + +type DummyProtocolCaller struct { + contract *bind.BoundContract +} + +type DummyProtocolTransactor struct { + contract *bind.BoundContract +} + +type DummyProtocolFilterer struct { + contract *bind.BoundContract +} + +type DummyProtocolSession struct { + Contract *DummyProtocol + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type DummyProtocolCallerSession struct { + Contract *DummyProtocolCaller + CallOpts bind.CallOpts +} + +type DummyProtocolTransactorSession struct { + Contract *DummyProtocolTransactor + TransactOpts bind.TransactOpts +} + +type DummyProtocolRaw struct { + Contract *DummyProtocol +} + +type DummyProtocolCallerRaw struct { + Contract *DummyProtocolCaller +} + +type DummyProtocolTransactorRaw struct { + Contract *DummyProtocolTransactor +} + +func NewDummyProtocol(address common.Address, backend bind.ContractBackend) (*DummyProtocol, error) { + abi, err := abi.JSON(strings.NewReader(DummyProtocolABI)) + if err != nil { + return nil, err + } + contract, err := bindDummyProtocol(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &DummyProtocol{address: address, abi: abi, DummyProtocolCaller: DummyProtocolCaller{contract: contract}, DummyProtocolTransactor: DummyProtocolTransactor{contract: contract}, DummyProtocolFilterer: DummyProtocolFilterer{contract: contract}}, nil +} + +func NewDummyProtocolCaller(address common.Address, caller bind.ContractCaller) (*DummyProtocolCaller, error) { + contract, err := bindDummyProtocol(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &DummyProtocolCaller{contract: contract}, nil +} + +func NewDummyProtocolTransactor(address common.Address, transactor bind.ContractTransactor) (*DummyProtocolTransactor, error) { + contract, err := bindDummyProtocol(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &DummyProtocolTransactor{contract: contract}, nil +} + +func NewDummyProtocolFilterer(address common.Address, filterer bind.ContractFilterer) (*DummyProtocolFilterer, error) { + contract, err := bindDummyProtocol(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &DummyProtocolFilterer{contract: contract}, nil +} + +func bindDummyProtocol(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := DummyProtocolMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_DummyProtocol *DummyProtocolRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _DummyProtocol.Contract.DummyProtocolCaller.contract.Call(opts, result, method, params...) +} + +func (_DummyProtocol *DummyProtocolRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _DummyProtocol.Contract.DummyProtocolTransactor.contract.Transfer(opts) +} + +func (_DummyProtocol *DummyProtocolRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _DummyProtocol.Contract.DummyProtocolTransactor.contract.Transact(opts, method, params...) +} + +func (_DummyProtocol *DummyProtocolCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _DummyProtocol.Contract.contract.Call(opts, result, method, params...) +} + +func (_DummyProtocol *DummyProtocolTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _DummyProtocol.Contract.contract.Transfer(opts) +} + +func (_DummyProtocol *DummyProtocolTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _DummyProtocol.Contract.contract.Transact(opts, method, params...) +} + +func (_DummyProtocol *DummyProtocolCaller) GetAdvancedLogTriggerConfig(opts *bind.CallOpts, targetContract common.Address, selector uint8, t0 [32]byte, t1 [32]byte, t2 [32]byte, t3 [32]byte) ([]byte, error) { + var out []interface{} + err := _DummyProtocol.contract.Call(opts, &out, "getAdvancedLogTriggerConfig", targetContract, selector, t0, t1, t2, t3) + + if err != nil { + return *new([]byte), err + } + + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) + + return out0, err + +} + +func (_DummyProtocol *DummyProtocolSession) GetAdvancedLogTriggerConfig(targetContract common.Address, selector uint8, t0 [32]byte, t1 [32]byte, t2 [32]byte, t3 [32]byte) ([]byte, error) { + return _DummyProtocol.Contract.GetAdvancedLogTriggerConfig(&_DummyProtocol.CallOpts, targetContract, selector, t0, t1, t2, t3) +} + +func (_DummyProtocol *DummyProtocolCallerSession) GetAdvancedLogTriggerConfig(targetContract common.Address, selector uint8, t0 [32]byte, t1 [32]byte, t2 [32]byte, t3 [32]byte) ([]byte, error) { + return _DummyProtocol.Contract.GetAdvancedLogTriggerConfig(&_DummyProtocol.CallOpts, targetContract, selector, t0, t1, t2, t3) +} + +func (_DummyProtocol *DummyProtocolCaller) GetBasicLogTriggerConfig(opts *bind.CallOpts, targetContract common.Address, t0 [32]byte) ([]byte, error) { + var out []interface{} + err := _DummyProtocol.contract.Call(opts, &out, "getBasicLogTriggerConfig", targetContract, t0) + + if err != nil { + return *new([]byte), err + } + + out0 := *abi.ConvertType(out[0], new([]byte)).(*[]byte) + + return out0, err + +} + +func (_DummyProtocol *DummyProtocolSession) GetBasicLogTriggerConfig(targetContract common.Address, t0 [32]byte) ([]byte, error) { + return _DummyProtocol.Contract.GetBasicLogTriggerConfig(&_DummyProtocol.CallOpts, targetContract, t0) +} + +func (_DummyProtocol *DummyProtocolCallerSession) GetBasicLogTriggerConfig(targetContract common.Address, t0 [32]byte) ([]byte, error) { + return _DummyProtocol.Contract.GetBasicLogTriggerConfig(&_DummyProtocol.CallOpts, targetContract, t0) +} + +func (_DummyProtocol *DummyProtocolTransactor) ExecuteLimitOrder(opts *bind.TransactOpts, orderId *big.Int, amount *big.Int, exchange common.Address) (*types.Transaction, error) { + return _DummyProtocol.contract.Transact(opts, "executeLimitOrder", orderId, amount, exchange) +} + +func (_DummyProtocol *DummyProtocolSession) ExecuteLimitOrder(orderId *big.Int, amount *big.Int, exchange common.Address) (*types.Transaction, error) { + return _DummyProtocol.Contract.ExecuteLimitOrder(&_DummyProtocol.TransactOpts, orderId, amount, exchange) +} + +func (_DummyProtocol *DummyProtocolTransactorSession) ExecuteLimitOrder(orderId *big.Int, amount *big.Int, exchange common.Address) (*types.Transaction, error) { + return _DummyProtocol.Contract.ExecuteLimitOrder(&_DummyProtocol.TransactOpts, orderId, amount, exchange) +} + +func (_DummyProtocol *DummyProtocolTransactor) SendLimitedOrder(opts *bind.TransactOpts, amount *big.Int, price *big.Int, to common.Address) (*types.Transaction, error) { + return _DummyProtocol.contract.Transact(opts, "sendLimitedOrder", amount, price, to) +} + +func (_DummyProtocol *DummyProtocolSession) SendLimitedOrder(amount *big.Int, price *big.Int, to common.Address) (*types.Transaction, error) { + return _DummyProtocol.Contract.SendLimitedOrder(&_DummyProtocol.TransactOpts, amount, price, to) +} + +func (_DummyProtocol *DummyProtocolTransactorSession) SendLimitedOrder(amount *big.Int, price *big.Int, to common.Address) (*types.Transaction, error) { + return _DummyProtocol.Contract.SendLimitedOrder(&_DummyProtocol.TransactOpts, amount, price, to) +} + +func (_DummyProtocol *DummyProtocolTransactor) WithdrawLimit(opts *bind.TransactOpts, amount *big.Int, price *big.Int, from common.Address) (*types.Transaction, error) { + return _DummyProtocol.contract.Transact(opts, "withdrawLimit", amount, price, from) +} + +func (_DummyProtocol *DummyProtocolSession) WithdrawLimit(amount *big.Int, price *big.Int, from common.Address) (*types.Transaction, error) { + return _DummyProtocol.Contract.WithdrawLimit(&_DummyProtocol.TransactOpts, amount, price, from) +} + +func (_DummyProtocol *DummyProtocolTransactorSession) WithdrawLimit(amount *big.Int, price *big.Int, from common.Address) (*types.Transaction, error) { + return _DummyProtocol.Contract.WithdrawLimit(&_DummyProtocol.TransactOpts, amount, price, from) +} + +type DummyProtocolLimitOrderExecutedIterator struct { + Event *DummyProtocolLimitOrderExecuted + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *DummyProtocolLimitOrderExecutedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(DummyProtocolLimitOrderExecuted) + 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(DummyProtocolLimitOrderExecuted) + 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 *DummyProtocolLimitOrderExecutedIterator) Error() error { + return it.fail +} + +func (it *DummyProtocolLimitOrderExecutedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type DummyProtocolLimitOrderExecuted struct { + OrderId *big.Int + Amount *big.Int + Exchange common.Address + Raw types.Log +} + +func (_DummyProtocol *DummyProtocolFilterer) FilterLimitOrderExecuted(opts *bind.FilterOpts, orderId []*big.Int, amount []*big.Int, exchange []common.Address) (*DummyProtocolLimitOrderExecutedIterator, error) { + + var orderIdRule []interface{} + for _, orderIdItem := range orderId { + orderIdRule = append(orderIdRule, orderIdItem) + } + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var exchangeRule []interface{} + for _, exchangeItem := range exchange { + exchangeRule = append(exchangeRule, exchangeItem) + } + + logs, sub, err := _DummyProtocol.contract.FilterLogs(opts, "LimitOrderExecuted", orderIdRule, amountRule, exchangeRule) + if err != nil { + return nil, err + } + return &DummyProtocolLimitOrderExecutedIterator{contract: _DummyProtocol.contract, event: "LimitOrderExecuted", logs: logs, sub: sub}, nil +} + +func (_DummyProtocol *DummyProtocolFilterer) WatchLimitOrderExecuted(opts *bind.WatchOpts, sink chan<- *DummyProtocolLimitOrderExecuted, orderId []*big.Int, amount []*big.Int, exchange []common.Address) (event.Subscription, error) { + + var orderIdRule []interface{} + for _, orderIdItem := range orderId { + orderIdRule = append(orderIdRule, orderIdItem) + } + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var exchangeRule []interface{} + for _, exchangeItem := range exchange { + exchangeRule = append(exchangeRule, exchangeItem) + } + + logs, sub, err := _DummyProtocol.contract.WatchLogs(opts, "LimitOrderExecuted", orderIdRule, amountRule, exchangeRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(DummyProtocolLimitOrderExecuted) + if err := _DummyProtocol.contract.UnpackLog(event, "LimitOrderExecuted", 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 (_DummyProtocol *DummyProtocolFilterer) ParseLimitOrderExecuted(log types.Log) (*DummyProtocolLimitOrderExecuted, error) { + event := new(DummyProtocolLimitOrderExecuted) + if err := _DummyProtocol.contract.UnpackLog(event, "LimitOrderExecuted", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type DummyProtocolLimitOrderSentIterator struct { + Event *DummyProtocolLimitOrderSent + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *DummyProtocolLimitOrderSentIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(DummyProtocolLimitOrderSent) + 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(DummyProtocolLimitOrderSent) + 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 *DummyProtocolLimitOrderSentIterator) Error() error { + return it.fail +} + +func (it *DummyProtocolLimitOrderSentIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type DummyProtocolLimitOrderSent struct { + Amount *big.Int + Price *big.Int + To common.Address + Raw types.Log +} + +func (_DummyProtocol *DummyProtocolFilterer) FilterLimitOrderSent(opts *bind.FilterOpts, amount []*big.Int, price []*big.Int, to []common.Address) (*DummyProtocolLimitOrderSentIterator, error) { + + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var priceRule []interface{} + for _, priceItem := range price { + priceRule = append(priceRule, priceItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _DummyProtocol.contract.FilterLogs(opts, "LimitOrderSent", amountRule, priceRule, toRule) + if err != nil { + return nil, err + } + return &DummyProtocolLimitOrderSentIterator{contract: _DummyProtocol.contract, event: "LimitOrderSent", logs: logs, sub: sub}, nil +} + +func (_DummyProtocol *DummyProtocolFilterer) WatchLimitOrderSent(opts *bind.WatchOpts, sink chan<- *DummyProtocolLimitOrderSent, amount []*big.Int, price []*big.Int, to []common.Address) (event.Subscription, error) { + + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var priceRule []interface{} + for _, priceItem := range price { + priceRule = append(priceRule, priceItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _DummyProtocol.contract.WatchLogs(opts, "LimitOrderSent", amountRule, priceRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(DummyProtocolLimitOrderSent) + if err := _DummyProtocol.contract.UnpackLog(event, "LimitOrderSent", 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 (_DummyProtocol *DummyProtocolFilterer) ParseLimitOrderSent(log types.Log) (*DummyProtocolLimitOrderSent, error) { + event := new(DummyProtocolLimitOrderSent) + if err := _DummyProtocol.contract.UnpackLog(event, "LimitOrderSent", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type DummyProtocolLimitOrderWithdrawnIterator struct { + Event *DummyProtocolLimitOrderWithdrawn + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *DummyProtocolLimitOrderWithdrawnIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(DummyProtocolLimitOrderWithdrawn) + 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(DummyProtocolLimitOrderWithdrawn) + 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 *DummyProtocolLimitOrderWithdrawnIterator) Error() error { + return it.fail +} + +func (it *DummyProtocolLimitOrderWithdrawnIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type DummyProtocolLimitOrderWithdrawn struct { + Amount *big.Int + Price *big.Int + From common.Address + Raw types.Log +} + +func (_DummyProtocol *DummyProtocolFilterer) FilterLimitOrderWithdrawn(opts *bind.FilterOpts, amount []*big.Int, price []*big.Int, from []common.Address) (*DummyProtocolLimitOrderWithdrawnIterator, error) { + + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var priceRule []interface{} + for _, priceItem := range price { + priceRule = append(priceRule, priceItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + + logs, sub, err := _DummyProtocol.contract.FilterLogs(opts, "LimitOrderWithdrawn", amountRule, priceRule, fromRule) + if err != nil { + return nil, err + } + return &DummyProtocolLimitOrderWithdrawnIterator{contract: _DummyProtocol.contract, event: "LimitOrderWithdrawn", logs: logs, sub: sub}, nil +} + +func (_DummyProtocol *DummyProtocolFilterer) WatchLimitOrderWithdrawn(opts *bind.WatchOpts, sink chan<- *DummyProtocolLimitOrderWithdrawn, amount []*big.Int, price []*big.Int, from []common.Address) (event.Subscription, error) { + + var amountRule []interface{} + for _, amountItem := range amount { + amountRule = append(amountRule, amountItem) + } + var priceRule []interface{} + for _, priceItem := range price { + priceRule = append(priceRule, priceItem) + } + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + + logs, sub, err := _DummyProtocol.contract.WatchLogs(opts, "LimitOrderWithdrawn", amountRule, priceRule, fromRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(DummyProtocolLimitOrderWithdrawn) + if err := _DummyProtocol.contract.UnpackLog(event, "LimitOrderWithdrawn", 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 (_DummyProtocol *DummyProtocolFilterer) ParseLimitOrderWithdrawn(log types.Log) (*DummyProtocolLimitOrderWithdrawn, error) { + event := new(DummyProtocolLimitOrderWithdrawn) + if err := _DummyProtocol.contract.UnpackLog(event, "LimitOrderWithdrawn", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_DummyProtocol *DummyProtocol) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _DummyProtocol.abi.Events["LimitOrderExecuted"].ID: + return _DummyProtocol.ParseLimitOrderExecuted(log) + case _DummyProtocol.abi.Events["LimitOrderSent"].ID: + return _DummyProtocol.ParseLimitOrderSent(log) + case _DummyProtocol.abi.Events["LimitOrderWithdrawn"].ID: + return _DummyProtocol.ParseLimitOrderWithdrawn(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (DummyProtocolLimitOrderExecuted) Topic() common.Hash { + return common.HexToHash("0xd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd") +} + +func (DummyProtocolLimitOrderSent) Topic() common.Hash { + return common.HexToHash("0x3e9c37b3143f2eb7e9a2a0f8091b6de097b62efcfe48e1f68847a832e521750a") +} + +func (DummyProtocolLimitOrderWithdrawn) Topic() common.Hash { + return common.HexToHash("0x0a71b8ed921ff64d49e4d39449f8a21094f38a0aeae489c3051aedd63f2c229f") +} + +func (_DummyProtocol *DummyProtocol) Address() common.Address { + return _DummyProtocol.address +} + +type DummyProtocolInterface interface { + GetAdvancedLogTriggerConfig(opts *bind.CallOpts, targetContract common.Address, selector uint8, t0 [32]byte, t1 [32]byte, t2 [32]byte, t3 [32]byte) ([]byte, error) + + GetBasicLogTriggerConfig(opts *bind.CallOpts, targetContract common.Address, t0 [32]byte) ([]byte, error) + + ExecuteLimitOrder(opts *bind.TransactOpts, orderId *big.Int, amount *big.Int, exchange common.Address) (*types.Transaction, error) + + SendLimitedOrder(opts *bind.TransactOpts, amount *big.Int, price *big.Int, to common.Address) (*types.Transaction, error) + + WithdrawLimit(opts *bind.TransactOpts, amount *big.Int, price *big.Int, from common.Address) (*types.Transaction, error) + + FilterLimitOrderExecuted(opts *bind.FilterOpts, orderId []*big.Int, amount []*big.Int, exchange []common.Address) (*DummyProtocolLimitOrderExecutedIterator, error) + + WatchLimitOrderExecuted(opts *bind.WatchOpts, sink chan<- *DummyProtocolLimitOrderExecuted, orderId []*big.Int, amount []*big.Int, exchange []common.Address) (event.Subscription, error) + + ParseLimitOrderExecuted(log types.Log) (*DummyProtocolLimitOrderExecuted, error) + + FilterLimitOrderSent(opts *bind.FilterOpts, amount []*big.Int, price []*big.Int, to []common.Address) (*DummyProtocolLimitOrderSentIterator, error) + + WatchLimitOrderSent(opts *bind.WatchOpts, sink chan<- *DummyProtocolLimitOrderSent, amount []*big.Int, price []*big.Int, to []common.Address) (event.Subscription, error) + + ParseLimitOrderSent(log types.Log) (*DummyProtocolLimitOrderSent, error) + + FilterLimitOrderWithdrawn(opts *bind.FilterOpts, amount []*big.Int, price []*big.Int, from []common.Address) (*DummyProtocolLimitOrderWithdrawnIterator, error) + + WatchLimitOrderWithdrawn(opts *bind.WatchOpts, sink chan<- *DummyProtocolLimitOrderWithdrawn, amount []*big.Int, price []*big.Int, from []common.Address) (event.Subscription, error) + + ParseLimitOrderWithdrawn(log types.Log) (*DummyProtocolLimitOrderWithdrawn, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go b/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go index f09dd42d2ab..21bc8fa80bf 100644 --- a/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go +++ b/core/gethwrappers/generated/log_triggered_feed_lookup_wrapper/log_triggered_feed_lookup_wrapper.go @@ -42,15 +42,15 @@ type Log struct { } var LogTriggeredFeedLookupMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useArbitrumBlockNum\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"verified\",\"type\":\"bytes\"}],\"name\":\"PerformingLogTriggerUpkeep\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParam\",\"type\":\"string\"}],\"name\":\"setFeedParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"timeParam\",\"type\":\"string\"}],\"name\":\"setTimeParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x610120604052604260a0818152608091829190620015dd60c03990526200002a9060019081620000d4565b506040805180820190915260098152680cccacac892c890caf60bb1b60208201526002906200005a908262000250565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b60208201526003906200008c908262000250565b503480156200009a57600080fd5b506040516200161f3803806200161f833981016040819052620000bd916200031c565b6000805460ff191691151591909117905562000347565b8280548282559060005260206000209081019282156200011f579160200282015b828111156200011f57825182906200010e908262000250565b5091602001919060010190620000f5565b506200012d92915062000131565b5090565b808211156200012d57600062000148828262000152565b5060010162000131565b5080546200016090620001c1565b6000825580601f1062000171575050565b601f01602090049060005260206000209081019062000191919062000194565b50565b5b808211156200012d576000815560010162000195565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001d657607f821691505b602082108103620001f757634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200024b57600081815260208120601f850160051c81016020861015620002265750805b601f850160051c820191505b81811015620002475782815560010162000232565b5050505b505050565b81516001600160401b038111156200026c576200026c620001ab565b62000284816200027d8454620001c1565b84620001fd565b602080601f831160018114620002bc5760008415620002a35750858301515b600019600386901b1c1916600185901b17855562000247565b600085815260208120601f198616915b82811015620002ed57888601518255948401946001909101908401620002cc565b50858210156200030c5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b6000602082840312156200032f57600080fd5b815180151581146200034057600080fd5b9392505050565b61128680620003576000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c8063642f6cef116100765780639d6f1cc71161005b5780639d6f1cc71461016b578063afb28d1f1461018b578063c98f10b01461019357600080fd5b8063642f6cef1461013b5780639525d5741461015857600080fd5b80634585e33b116100a75780634585e33b146101025780634b56a42e14610115578063601d5a711461012857600080fd5b806305e25131146100c357806340691db4146100d8575b600080fd5b6100d66100d136600461098e565b61019b565b005b6100eb6100e6366004610a3f565b6101b2565b6040516100f9929190610b1a565b60405180910390f35b6100d6610110366004610b3d565b610462565b6100eb610123366004610baf565b6105d1565b6100d6610136366004610c6c565b610627565b6000546101489060ff1681565b60405190151581526020016100f9565b6100d6610166366004610c6c565b610633565b61017e610179366004610ca1565b61063f565b6040516100f99190610cba565b61017e6106eb565b61017e6106f8565b80516101ae90600190602084019061078b565b5050565b6000606060006101c0610705565b90507fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd6101f060c0870187610cd4565b600081811061020157610201610d3c565b90506020020135036103da57600061021c60c0870187610cd4565b600181811061022d5761022d610d3c565b9050602002013560405160200161024691815260200190565b604051602081830303815290604052905060008180602001905181019061026d9190610d6b565b9050600061027e60c0890189610cd4565b600281811061028f5761028f610d3c565b905060200201356040516020016102a891815260200190565b60405160208183030381529060405290506000818060200190518101906102cf9190610d6b565b905060006102e060c08b018b610cd4565b60038181106102f1576102f1610d3c565b9050602002013560405160200161030a91815260200190565b60405160208183030381529060405290506000818060200190518101906103319190610dad565b604080516020810188905290810185905273ffffffffffffffffffffffffffffffffffffffff821660608201529091506002906001906003908a90608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526103d19594939291600401610eb6565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f670000000000000000000000000000000000000000000000000000000000000060648201526084016103d1565b60008061047183850185610baf565b9150915060008060008380602001905181019061048e9190610f79565b92509250925060007309dff56a4ff44e0f4436260a04f5cfa65636a48173ffffffffffffffffffffffffffffffffffffffff16638e760afe876000815181106104d9576104d9610d3c565b60200260200101516040518263ffffffff1660e01b81526004016104fd9190610cba565b6000604051808303816000875af115801561051c573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01682016040526105629190810190610fae565b9050327f299a03817e683a32b21e29e3ae3c31f1c9c773f7d532836d116b62a9281fbc9d858585610591610705565b8b6000815181106105a4576105a4610d3c565b6020026020010151876040516105bf96959493929190611025565b60405180910390a25050505050505050565b60006060600084846040516020016105ea929190611085565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052600193509150505b9250929050565b60036101ae828261115f565b60026101ae828261115f565b6001818154811061064f57600080fd5b90600052602060002001600091509050805461066a90610dc8565b80601f016020809104026020016040519081016040528092919081815260200182805461069690610dc8565b80156106e35780601f106106b8576101008083540402835291602001916106e3565b820191906000526020600020905b8154815290600101906020018083116106c657829003601f168201915b505050505081565b6002805461066a90610dc8565b6003805461066a90610dc8565b6000805460ff161561078657606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561075d573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107819190610d6b565b905090565b504390565b8280548282559060005260206000209081019282156107d1579160200282015b828111156107d157825182906107c1908261115f565b50916020019190600101906107ab565b506107dd9291506107e1565b5090565b808211156107dd5760006107f582826107fe565b506001016107e1565b50805461080a90610dc8565b6000825580601f1061081a575050565b601f016020900490600052602060002090810190610838919061083b565b50565b5b808211156107dd576000815560010161083c565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156108c6576108c6610850565b604052919050565b600067ffffffffffffffff8211156108e8576108e8610850565b5060051b60200190565b600067ffffffffffffffff82111561090c5761090c610850565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f83011261094957600080fd5b813561095c610957826108f2565b61087f565b81815284602083860101111561097157600080fd5b816020850160208301376000918101602001919091529392505050565b600060208083850312156109a157600080fd5b823567ffffffffffffffff808211156109b957600080fd5b818501915085601f8301126109cd57600080fd5b81356109db610957826108ce565b81815260059190911b830184019084810190888311156109fa57600080fd5b8585015b83811015610a3257803585811115610a165760008081fd5b610a248b89838a0101610938565b8452509186019186016109fe565b5098975050505050505050565b60008060408385031215610a5257600080fd5b823567ffffffffffffffff80821115610a6a57600080fd5b908401906101008287031215610a7f57600080fd5b90925060208401359080821115610a9557600080fd5b50610aa285828601610938565b9150509250929050565b60005b83811015610ac7578181015183820152602001610aaf565b50506000910152565b60008151808452610ae8816020860160208601610aac565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b8215158152604060208201526000610b356040830184610ad0565b949350505050565b60008060208385031215610b5057600080fd5b823567ffffffffffffffff80821115610b6857600080fd5b818501915085601f830112610b7c57600080fd5b813581811115610b8b57600080fd5b866020828501011115610b9d57600080fd5b60209290920196919550909350505050565b60008060408385031215610bc257600080fd5b823567ffffffffffffffff80821115610bda57600080fd5b818501915085601f830112610bee57600080fd5b81356020610bfe610957836108ce565b82815260059290921b84018101918181019089841115610c1d57600080fd5b8286015b84811015610c5557803586811115610c395760008081fd5b610c478c86838b0101610938565b845250918301918301610c21565b5096505086013592505080821115610a9557600080fd5b600060208284031215610c7e57600080fd5b813567ffffffffffffffff811115610c9557600080fd5b610b3584828501610938565b600060208284031215610cb357600080fd5b5035919050565b602081526000610ccd6020830184610ad0565b9392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610d0957600080fd5b83018035915067ffffffffffffffff821115610d2457600080fd5b6020019150600581901b360382131561062057600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215610d7d57600080fd5b5051919050565b805173ffffffffffffffffffffffffffffffffffffffff81168114610da857600080fd5b919050565b600060208284031215610dbf57600080fd5b610ccd82610d84565b600181811c90821680610ddc57607f821691505b602082108103610e15577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008154610e2881610dc8565b808552602060018381168015610e455760018114610e7d57610eab565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b8901019550610eab565b866000528260002060005b85811015610ea35781548a8201860152908301908401610e88565b890184019650505b505050505092915050565b60a081526000610ec960a0830188610e1b565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610f3b577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610f298383610e1b565b94860194925060019182019101610ef0565b50508681036040880152610f4f818b610e1b565b9450505050508460608401528281036080840152610f6d8185610ad0565b98975050505050505050565b600080600060608486031215610f8e57600080fd5b8351925060208401519150610fa560408501610d84565b90509250925092565b600060208284031215610fc057600080fd5b815167ffffffffffffffff811115610fd757600080fd5b8201601f81018413610fe857600080fd5b8051610ff6610957826108f2565b81815285602083850101111561100b57600080fd5b61101c826020830160208601610aac565b95945050505050565b86815285602082015273ffffffffffffffffffffffffffffffffffffffff8516604082015283606082015260c06080820152600061106660c0830185610ad0565b82810360a08401526110788185610ad0565b9998505050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b838110156110fa577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa08887030185526110e8868351610ad0565b955093820193908201906001016110ae565b50508584038187015250505061101c8185610ad0565b601f82111561115a57600081815260208120601f850160051c810160208610156111375750805b601f850160051c820191505b8181101561115657828155600101611143565b5050505b505050565b815167ffffffffffffffff81111561117957611179610850565b61118d816111878454610dc8565b84611110565b602080601f8311600181146111e057600084156111aa5750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555611156565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561122d5788860151825594840194600190910190840161120e565b508582101561126957878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + ABI: "[{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"_useArbitrumBlockNum\",\"type\":\"bool\"},{\"internalType\":\"bool\",\"name\":\"_verify\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"from\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"orderId\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"exchange\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"blob\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"verified\",\"type\":\"bytes\"}],\"name\":\"PerformingLogTriggerUpkeep\",\"type\":\"event\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"components\":[{\"internalType\":\"uint256\",\"name\":\"index\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"txIndex\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"txHash\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"internalType\":\"bytes32\",\"name\":\"blockHash\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"source\",\"type\":\"address\"},{\"internalType\":\"bytes32[]\",\"name\":\"topics\",\"type\":\"bytes32[]\"},{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"internalType\":\"structLog\",\"name\":\"log\",\"type\":\"tuple\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"name\":\"checkLog\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"upkeepNeeded\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feedsHex\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParam\",\"type\":\"string\"}],\"name\":\"setFeedParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string[]\",\"name\":\"newFeeds\",\"type\":\"string[]\"}],\"name\":\"setFeedsHex\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"timeParam\",\"type\":\"string\"}],\"name\":\"setTimeParamKey\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useArbitrumBlockNum\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", + Bin: "0x610120604052604260a08181526080918291906200164e60c03990526200002a9060019081620000e5565b506040805180820190915260098152680cccacac892c890caf60bb1b60208201526002906200005a908262000261565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b60208201526003906200008c908262000261565b503480156200009a57600080fd5b506040516200169038038062001690833981016040819052620000bd9162000343565b6000805461ffff191692151561ff00191692909217610100911515919091021790556200037b565b82805482825590600052602060002090810192821562000130579160200282015b828111156200013057825182906200011f908262000261565b509160200191906001019062000106565b506200013e92915062000142565b5090565b808211156200013e57600062000159828262000163565b5060010162000142565b5080546200017190620001d2565b6000825580601f1062000182575050565b601f016020900490600052602060002090810190620001a29190620001a5565b50565b5b808211156200013e5760008155600101620001a6565b634e487b7160e01b600052604160045260246000fd5b600181811c90821680620001e757607f821691505b6020821081036200020857634e487b7160e01b600052602260045260246000fd5b50919050565b601f8211156200025c57600081815260208120601f850160051c81016020861015620002375750805b601f850160051c820191505b81811015620002585782815560010162000243565b5050505b505050565b81516001600160401b038111156200027d576200027d620001bc565b62000295816200028e8454620001d2565b846200020e565b602080601f831160018114620002cd5760008415620002b45750858301515b600019600386901b1c1916600185901b17855562000258565b600085815260208120601f198616915b82811015620002fe57888601518255948401946001909101908401620002dd565b50858210156200031d5787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b805180151581146200033e57600080fd5b919050565b600080604083850312156200035757600080fd5b62000362836200032d565b915062000372602084016200032d565b90509250929050565b6112c3806200038b6000396000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c8063642f6cef11610081578063afb28d1f1161005b578063afb28d1f14610196578063c98f10b01461019e578063fc735e99146101a657600080fd5b8063642f6cef146101465780639525d574146101635780639d6f1cc71461017657600080fd5b80634585e33b116100b25780634585e33b1461010d5780634b56a42e14610120578063601d5a711461013357600080fd5b806305e25131146100ce57806340691db4146100e3575b600080fd5b6100e16100dc3660046109cb565b6101b8565b005b6100f66100f1366004610a7c565b6101cf565b604051610104929190610b57565b60405180910390f35b6100e161011b366004610b7a565b61047f565b6100f661012e366004610bec565b61060e565b6100e1610141366004610ca9565b610664565b6000546101539060ff1681565b6040519015158152602001610104565b6100e1610171366004610ca9565b610670565b610189610184366004610cde565b61067c565b6040516101049190610cf7565b610189610728565b610189610735565b60005461015390610100900460ff1681565b80516101cb9060019060208401906107c8565b5050565b6000606060006101dd610742565b90507fd1ffe9e45581c11d7d9f2ed5f75217cd4be9f8b7eee6af0f6d03f46de53956cd61020d60c0870187610d11565b600081811061021e5761021e610d79565b90506020020135036103f757600061023960c0870187610d11565b600181811061024a5761024a610d79565b9050602002013560405160200161026391815260200190565b604051602081830303815290604052905060008180602001905181019061028a9190610da8565b9050600061029b60c0890189610d11565b60028181106102ac576102ac610d79565b905060200201356040516020016102c591815260200190565b60405160208183030381529060405290506000818060200190518101906102ec9190610da8565b905060006102fd60c08b018b610d11565b600381811061030e5761030e610d79565b9050602002013560405160200161032791815260200190565b604051602081830303815290604052905060008180602001905181019061034e9190610dea565b604080516020810188905290810185905273ffffffffffffffffffffffffffffffffffffffff821660608201529091506002906001906003908a90608001604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152908290527f7ddd933e0000000000000000000000000000000000000000000000000000000082526103ee9594939291600401610ef3565b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602160248201527f636f756c64206e6f742066696e64206d61746368696e67206576656e7420736960448201527f670000000000000000000000000000000000000000000000000000000000000060648201526084016103ee565b60008061048e83850185610bec565b915091506000806000838060200190518101906104ab9190610fb6565b6040805160208101909152600080825254939650919450925090610100900460ff16156105a1577309dff56a4ff44e0f4436260a04f5cfa65636a48173ffffffffffffffffffffffffffffffffffffffff16638e760afe8760008151811061051557610515610d79565b60200260200101516040518263ffffffff1660e01b81526004016105399190610cf7565b6000604051808303816000875af1158015610558573d6000803e3d6000fd5b505050506040513d6000823e601f3d9081017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016820160405261059e9190810190610feb565b90505b327f299a03817e683a32b21e29e3ae3c31f1c9c773f7d532836d116b62a9281fbc9d8585856105ce610742565b8b6000815181106105e1576105e1610d79565b6020026020010151876040516105fc96959493929190611062565b60405180910390a25050505050505050565b60006060600084846040516020016106279291906110c2565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0818403018152919052600193509150505b9250929050565b60036101cb828261119c565b60026101cb828261119c565b6001818154811061068c57600080fd5b9060005260206000200160009150905080546106a790610e05565b80601f01602080910402602001604051908101604052809291908181526020018280546106d390610e05565b80156107205780601f106106f557610100808354040283529160200191610720565b820191906000526020600020905b81548152906001019060200180831161070357829003601f168201915b505050505081565b600280546106a790610e05565b600380546106a790610e05565b6000805460ff16156107c357606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa15801561079a573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107be9190610da8565b905090565b504390565b82805482825590600052602060002090810192821561080e579160200282015b8281111561080e57825182906107fe908261119c565b50916020019190600101906107e8565b5061081a92915061081e565b5090565b8082111561081a576000610832828261083b565b5060010161081e565b50805461084790610e05565b6000825580601f10610857575050565b601f0160209004906000526020600020908101906108759190610878565b50565b5b8082111561081a5760008155600101610879565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156109035761090361088d565b604052919050565b600067ffffffffffffffff8211156109255761092561088d565b5060051b60200190565b600067ffffffffffffffff8211156109495761094961088d565b50601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe01660200190565b600082601f83011261098657600080fd5b81356109996109948261092f565b6108bc565b8181528460208386010111156109ae57600080fd5b816020850160208301376000918101602001919091529392505050565b600060208083850312156109de57600080fd5b823567ffffffffffffffff808211156109f657600080fd5b818501915085601f830112610a0a57600080fd5b8135610a186109948261090b565b81815260059190911b83018401908481019088831115610a3757600080fd5b8585015b83811015610a6f57803585811115610a535760008081fd5b610a618b89838a0101610975565b845250918601918601610a3b565b5098975050505050505050565b60008060408385031215610a8f57600080fd5b823567ffffffffffffffff80821115610aa757600080fd5b908401906101008287031215610abc57600080fd5b90925060208401359080821115610ad257600080fd5b50610adf85828601610975565b9150509250929050565b60005b83811015610b04578181015183820152602001610aec565b50506000910152565b60008151808452610b25816020860160208601610ae9565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169290920160200192915050565b8215158152604060208201526000610b726040830184610b0d565b949350505050565b60008060208385031215610b8d57600080fd5b823567ffffffffffffffff80821115610ba557600080fd5b818501915085601f830112610bb957600080fd5b813581811115610bc857600080fd5b866020828501011115610bda57600080fd5b60209290920196919550909350505050565b60008060408385031215610bff57600080fd5b823567ffffffffffffffff80821115610c1757600080fd5b818501915085601f830112610c2b57600080fd5b81356020610c3b6109948361090b565b82815260059290921b84018101918181019089841115610c5a57600080fd5b8286015b84811015610c9257803586811115610c765760008081fd5b610c848c86838b0101610975565b845250918301918301610c5e565b5096505086013592505080821115610ad257600080fd5b600060208284031215610cbb57600080fd5b813567ffffffffffffffff811115610cd257600080fd5b610b7284828501610975565b600060208284031215610cf057600080fd5b5035919050565b602081526000610d0a6020830184610b0d565b9392505050565b60008083357fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe1843603018112610d4657600080fd5b83018035915067ffffffffffffffff821115610d6157600080fd5b6020019150600581901b360382131561065d57600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b600060208284031215610dba57600080fd5b5051919050565b805173ffffffffffffffffffffffffffffffffffffffff81168114610de557600080fd5b919050565b600060208284031215610dfc57600080fd5b610d0a82610dc1565b600181811c90821680610e1957607f821691505b602082108103610e52577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b60008154610e6581610e05565b808552602060018381168015610e825760018114610eba57610ee8565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008516838901528284151560051b8901019550610ee8565b866000528260002060005b85811015610ee05781548a8201860152908301908401610ec5565b890184019650505b505050505092915050565b60a081526000610f0660a0830188610e58565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610f78577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610f668383610e58565b94860194925060019182019101610f2d565b50508681036040880152610f8c818b610e58565b9450505050508460608401528281036080840152610faa8185610b0d565b98975050505050505050565b600080600060608486031215610fcb57600080fd5b8351925060208401519150610fe260408501610dc1565b90509250925092565b600060208284031215610ffd57600080fd5b815167ffffffffffffffff81111561101457600080fd5b8201601f8101841361102557600080fd5b80516110336109948261092f565b81815285602083850101111561104857600080fd5b611059826020830160208601610ae9565b95945050505050565b86815285602082015273ffffffffffffffffffffffffffffffffffffffff8516604082015283606082015260c0608082015260006110a360c0830185610b0d565b82810360a08401526110b58185610b0d565b9998505050505050505050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015611137577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552611125868351610b0d565b955093820193908201906001016110eb565b5050858403818701525050506110598185610b0d565b601f82111561119757600081815260208120601f850160051c810160208610156111745750805b601f850160051c820191505b8181101561119357828155600101611180565b5050505b505050565b815167ffffffffffffffff8111156111b6576111b661088d565b6111ca816111c48454610e05565b8461114d565b602080601f83116001811461121d57600084156111e75750858301515b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600386901b1c1916600185901b178555611193565b6000858152602081207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08616915b8281101561126a5788860151825594840194600190910190840161124b565b50858210156112a657878501517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff600388901b60f8161c191681555b5050505050600190811b0190555056fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var LogTriggeredFeedLookupABI = LogTriggeredFeedLookupMetaData.ABI var LogTriggeredFeedLookupBin = LogTriggeredFeedLookupMetaData.Bin -func DeployLogTriggeredFeedLookup(auth *bind.TransactOpts, backend bind.ContractBackend, _useArbitrumBlockNum bool) (common.Address, *types.Transaction, *LogTriggeredFeedLookup, error) { +func DeployLogTriggeredFeedLookup(auth *bind.TransactOpts, backend bind.ContractBackend, _useArbitrumBlockNum bool, _verify bool) (common.Address, *types.Transaction, *LogTriggeredFeedLookup, error) { parsed, err := LogTriggeredFeedLookupMetaData.GetAbi() if err != nil { return common.Address{}, nil, nil, err @@ -59,7 +59,7 @@ func DeployLogTriggeredFeedLookup(auth *bind.TransactOpts, backend bind.Contract return common.Address{}, nil, nil, errors.New("GetABI returned nil") } - address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(LogTriggeredFeedLookupBin), backend, _useArbitrumBlockNum) + address, tx, contract, err := bind.DeployContract(auth, *parsed, common.FromHex(LogTriggeredFeedLookupBin), backend, _useArbitrumBlockNum, _verify) if err != nil { return common.Address{}, nil, nil, err } @@ -293,6 +293,28 @@ func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCallerSession) UseArbitrumB return _LogTriggeredFeedLookup.Contract.UseArbitrumBlockNum(&_LogTriggeredFeedLookup.CallOpts) } +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCaller) Verify(opts *bind.CallOpts) (bool, error) { + var out []interface{} + err := _LogTriggeredFeedLookup.contract.Call(opts, &out, "verify") + + if err != nil { + return *new(bool), err + } + + out0 := *abi.ConvertType(out[0], new(bool)).(*bool) + + return out0, err + +} + +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupSession) Verify() (bool, error) { + return _LogTriggeredFeedLookup.Contract.Verify(&_LogTriggeredFeedLookup.CallOpts) +} + +func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupCallerSession) Verify() (bool, error) { + return _LogTriggeredFeedLookup.Contract.Verify(&_LogTriggeredFeedLookup.CallOpts) +} + func (_LogTriggeredFeedLookup *LogTriggeredFeedLookupTransactor) CheckLog(opts *bind.TransactOpts, log Log, arg1 []byte) (*types.Transaction, error) { return _LogTriggeredFeedLookup.contract.Transact(opts, "checkLog", log, arg1) } @@ -515,6 +537,8 @@ type LogTriggeredFeedLookupInterface interface { UseArbitrumBlockNum(opts *bind.CallOpts) (bool, error) + Verify(opts *bind.CallOpts) (bool, error) + CheckLog(opts *bind.TransactOpts, log Log, arg1 []byte) (*types.Transaction, error) PerformUpkeep(opts *bind.TransactOpts, performData []byte) (*types.Transaction, error) diff --git a/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go b/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go index 9d4d49cbab7..3233012fb7c 100644 --- a/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go +++ b/core/gethwrappers/generated/mercury_upkeep_wrapper/mercury_upkeep_wrapper.go @@ -32,7 +32,7 @@ var ( var MercuryUpkeepMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"_testRange\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"_interval\",\"type\":\"uint256\"},{\"internalType\":\"bool\",\"name\":\"_useL1BlockNumber\",\"type\":\"bool\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"feedParamKey\",\"type\":\"string\"},{\"internalType\":\"string[]\",\"name\":\"feeds\",\"type\":\"string[]\"},{\"internalType\":\"string\",\"name\":\"timeParamKey\",\"type\":\"string\"},{\"internalType\":\"uint256\",\"name\":\"time\",\"type\":\"uint256\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"FeedLookup\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"address\",\"name\":\"origin\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"uint256\",\"name\":\"blockNumber\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"v0\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"v1\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"ed\",\"type\":\"bytes\"}],\"name\":\"MercuryPerformEvent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"callbackReturnBool\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes[]\",\"name\":\"values\",\"type\":\"bytes[]\"},{\"internalType\":\"bytes\",\"name\":\"extraData\",\"type\":\"bytes\"}],\"name\":\"checkCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"data\",\"type\":\"bytes\"}],\"name\":\"checkUpkeep\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"counter\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"eligible\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"feedParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"feeds\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"initialBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"interval\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"performData\",\"type\":\"bytes\"}],\"name\":\"performUpkeep\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"previousPerformBlock\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"setCallbackReturnBool\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bool\",\"name\":\"value\",\"type\":\"bool\"}],\"name\":\"setShouldRevertCallback\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"shouldRevertCallback\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"testRange\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"timeParamKey\",\"outputs\":[{\"internalType\":\"string\",\"name\":\"\",\"type\":\"string\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"useL1BlockNumber\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"view\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162001308380380620013088339810160408190526200003491620001f7565b60008381556001839055600281905560038190556004556040805180820190915260098152680cccacac8928890caf60bb1b60208201526006906200007a9082620002dc565b50604051806040016040528060405180608001604052806042815260200162001284604291398152602001604051806080016040528060428152602001620012c6604291399052620000d190600590600262000120565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152600790620001039082620002dc565b50151560805250506008805461ff001916610100179055620003a8565b8280548282559060005260206000209081019282156200016b579160200282015b828111156200016b57825182906200015a9082620002dc565b509160200191906001019062000141565b50620001799291506200017d565b5090565b80821115620001795760006200019482826200019e565b506001016200017d565b508054620001ac906200024d565b6000825580601f10620001bd575050565b601f016020900490600052602060002090810190620001dd9190620001e0565b50565b5b80821115620001795760008155600101620001e1565b6000806000606084860312156200020d57600080fd5b8351925060208401519150604084015180151581146200022c57600080fd5b809150509250925092565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200026257607f821691505b6020821081036200028357634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002d757600081815260208120601f850160051c81016020861015620002b25750805b601f850160051c820191505b81811015620002d357828155600101620002be565b5050505b505050565b81516001600160401b03811115620002f857620002f862000237565b62000310816200030984546200024d565b8462000289565b602080601f8311600181146200034857600084156200032f5750858301515b600019600386901b1c1916600185901b178555620002d3565b600085815260208120601f198616915b82811015620003795788860151825594840194600190910190840162000358565b5085821015620003985787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b608051610eab620003d960003960008181610170015281816102bf015281816105ef01526107220152610eab6000f3fe608060405234801561001057600080fd5b506004361061011b5760003560e01c80635b48391a116100b2578063917d895f11610081578063afb28d1f11610066578063afb28d1f146102a3578063c98f10b0146102ab578063d832d92f146102b357600080fd5b8063917d895f14610291578063947a36fb1461029a57600080fd5b80635b48391a1461022757806361bc221a1461026c5780636250a13a146102755780636e04ff0d1461027e57600080fd5b80634585e33b116100ee5780634585e33b146101925780634a5479f3146101a75780634b56a42e146101c75780634bdb3862146101e857600080fd5b806302be021f14610120578063102d538b146101425780632cb15864146101545780632d02b93b1461016b575b600080fd5b60085461012d9060ff1681565b60405190151581526020015b60405180910390f35b60085461012d90610100900460ff1681565b61015d60035481565b604051908152602001610139565b61012d7f000000000000000000000000000000000000000000000000000000000000000081565b6101a56101a03660046107f1565b6102bb565b005b6101ba6101b5366004610863565b610414565b60405161013991906108e0565b6101da6101d5366004610a06565b6104c0565b604051610139929190610aec565b6101a56101f6366004610b0f565b600880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b6101a5610235366004610b0f565b60088054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b61015d60045481565b61015d60005481565b6101da61028c3660046107f1565b610593565b61015d60025481565b61015d60015481565b6101ba6106f2565b6101ba6106ff565b61012d61070c565b60007f0000000000000000000000000000000000000000000000000000000000000000156102ea57504361035d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610336573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061035a9190610b31565b90505b60035460000361036d5760038190555b60008061037c84860186610a06565b60028590556004549193509150610394906001610b79565b60045581518390339032907fec3208363089f292bf230caa1cd39f9dc25d98a341b935d9ebd7a95e2ec82af19086906000906103d2576103d2610b92565b6020026020010151866001815181106103ed576103ed610b92565b60200260200101518660405161040593929190610bc1565b60405180910390a45050505050565b6005818154811061042457600080fd5b90600052602060002001600091509050805461043f90610c04565b80601f016020809104026020016040519081016040528092919081815260200182805461046b90610c04565b80156104b85780601f1061048d576101008083540402835291602001916104b8565b820191906000526020600020905b81548152906001019060200180831161049b57829003601f168201915b505050505081565b60085460009060609060ff1615610538576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f73686f756c6452657665727443616c6c6261636b20697320747275650000000060448201526064015b60405180910390fd5b6000848460405160200161054d929190610c57565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152919052600854610100900460ff1693509150505b9250929050565b6000606061059f61070c565b6105eb576000848481818080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525095975091955061058c945050505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561061a57504361068d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610666573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061068a9190610b31565b90505b604080516c6400000000000000000000000060208201528151601481830301815260348201928390527f7ddd933e0000000000000000000000000000000000000000000000000000000090925261052f91600691600591600791869190603801610dc8565b6006805461043f90610c04565b6007805461043f90610c04565b600060035460000361071e5750600190565b60007f00000000000000000000000000000000000000000000000000000000000000001561074d5750436107c0565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610799573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107bd9190610b31565b90505b6000546003546107d09083610e8b565b1080156107eb57506001546002546107e89083610e8b565b10155b91505090565b6000806020838503121561080457600080fd5b823567ffffffffffffffff8082111561081c57600080fd5b818501915085601f83011261083057600080fd5b81358181111561083f57600080fd5b86602082850101111561085157600080fd5b60209290920196919550909350505050565b60006020828403121561087557600080fd5b5035919050565b6000815180845260005b818110156108a257602081850181015186830182015201610886565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006108f3602083018461087c565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610970576109706108fa565b604052919050565b600082601f83011261098957600080fd5b813567ffffffffffffffff8111156109a3576109a36108fa565b6109d460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610929565b8181528460208386010111156109e957600080fd5b816020850160208301376000918101602001919091529392505050565b60008060408385031215610a1957600080fd5b823567ffffffffffffffff80821115610a3157600080fd5b818501915085601f830112610a4557600080fd5b8135602082821115610a5957610a596108fa565b8160051b610a68828201610929565b928352848101820192828101908a851115610a8257600080fd5b83870192505b84831015610abe57823586811115610aa05760008081fd5b610aae8c86838b0101610978565b8352509183019190830190610a88565b9750505086013592505080821115610ad557600080fd5b50610ae285828601610978565b9150509250929050565b8215158152604060208201526000610b07604083018461087c565b949350505050565b600060208284031215610b2157600080fd5b813580151581146108f357600080fd5b600060208284031215610b4357600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610b8c57610b8c610b4a565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b606081526000610bd4606083018661087c565b8281036020840152610be6818661087c565b90508281036040840152610bfa818561087c565b9695505050505050565b600181811c90821680610c1857607f821691505b602082108103610c51577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610ccc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610cba86835161087c565b95509382019390820190600101610c80565b505085840381870152505050610ce2818561087c565b95945050505050565b8054600090600181811c9080831680610d0557607f831692505b60208084108203610d3f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b838852818015610d565760018114610d8e57610dbc565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008616828a01528185151560051b8a01019650610dbc565b876000528160002060005b86811015610db45781548b8201850152908501908301610d99565b8a0183019750505b50505050505092915050565b60a081526000610ddb60a0830188610ceb565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610e4d577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610e3b8383610ceb565b94860194925060019182019101610e02565b50508681036040880152610e61818b610ceb565b9450505050508460608401528281036080840152610e7f818561087c565b98975050505050505050565b81810381811115610b8c57610b8c610b4a56fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001308380380620013088339810160408190526200003491620001f7565b60008381556001839055600281905560038190556004556040805180820190915260098152680cccacac892c890caf60bb1b60208201526006906200007a9082620002dc565b50604051806040016040528060405180608001604052806042815260200162001284604291398152602001604051806080016040528060428152602001620012c6604291399052620000d190600590600262000120565b5060408051808201909152600b81526a313637b1b5a73ab6b132b960a91b6020820152600790620001039082620002dc565b50151560805250506008805461ff001916610100179055620003a8565b8280548282559060005260206000209081019282156200016b579160200282015b828111156200016b57825182906200015a9082620002dc565b509160200191906001019062000141565b50620001799291506200017d565b5090565b80821115620001795760006200019482826200019e565b506001016200017d565b508054620001ac906200024d565b6000825580601f10620001bd575050565b601f016020900490600052602060002090810190620001dd9190620001e0565b50565b5b80821115620001795760008155600101620001e1565b6000806000606084860312156200020d57600080fd5b8351925060208401519150604084015180151581146200022c57600080fd5b809150509250925092565b634e487b7160e01b600052604160045260246000fd5b600181811c908216806200026257607f821691505b6020821081036200028357634e487b7160e01b600052602260045260246000fd5b50919050565b601f821115620002d757600081815260208120601f850160051c81016020861015620002b25750805b601f850160051c820191505b81811015620002d357828155600101620002be565b5050505b505050565b81516001600160401b03811115620002f857620002f862000237565b62000310816200030984546200024d565b8462000289565b602080601f8311600181146200034857600084156200032f5750858301515b600019600386901b1c1916600185901b178555620002d3565b600085815260208120601f198616915b82811015620003795788860151825594840194600190910190840162000358565b5085821015620003985787850151600019600388901b60f8161c191681555b5050505050600190811b01905550565b608051610eab620003d960003960008181610170015281816102bf015281816105ef01526107220152610eab6000f3fe608060405234801561001057600080fd5b506004361061011b5760003560e01c80635b48391a116100b2578063917d895f11610081578063afb28d1f11610066578063afb28d1f146102a3578063c98f10b0146102ab578063d832d92f146102b357600080fd5b8063917d895f14610291578063947a36fb1461029a57600080fd5b80635b48391a1461022757806361bc221a1461026c5780636250a13a146102755780636e04ff0d1461027e57600080fd5b80634585e33b116100ee5780634585e33b146101925780634a5479f3146101a75780634b56a42e146101c75780634bdb3862146101e857600080fd5b806302be021f14610120578063102d538b146101425780632cb15864146101545780632d02b93b1461016b575b600080fd5b60085461012d9060ff1681565b60405190151581526020015b60405180910390f35b60085461012d90610100900460ff1681565b61015d60035481565b604051908152602001610139565b61012d7f000000000000000000000000000000000000000000000000000000000000000081565b6101a56101a03660046107f1565b6102bb565b005b6101ba6101b5366004610863565b610414565b60405161013991906108e0565b6101da6101d5366004610a06565b6104c0565b604051610139929190610aec565b6101a56101f6366004610b0f565b600880547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0016911515919091179055565b6101a5610235366004610b0f565b60088054911515610100027fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff909216919091179055565b61015d60045481565b61015d60005481565b6101da61028c3660046107f1565b610593565b61015d60025481565b61015d60015481565b6101ba6106f2565b6101ba6106ff565b61012d61070c565b60007f0000000000000000000000000000000000000000000000000000000000000000156102ea57504361035d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610336573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061035a9190610b31565b90505b60035460000361036d5760038190555b60008061037c84860186610a06565b60028590556004549193509150610394906001610b79565b60045581518390339032907fec3208363089f292bf230caa1cd39f9dc25d98a341b935d9ebd7a95e2ec82af19086906000906103d2576103d2610b92565b6020026020010151866001815181106103ed576103ed610b92565b60200260200101518660405161040593929190610bc1565b60405180910390a45050505050565b6005818154811061042457600080fd5b90600052602060002001600091509050805461043f90610c04565b80601f016020809104026020016040519081016040528092919081815260200182805461046b90610c04565b80156104b85780601f1061048d576101008083540402835291602001916104b8565b820191906000526020600020905b81548152906001019060200180831161049b57829003601f168201915b505050505081565b60085460009060609060ff1615610538576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601c60248201527f73686f756c6452657665727443616c6c6261636b20697320747275650000000060448201526064015b60405180910390fd5b6000848460405160200161054d929190610c57565b604080518083037fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0018152919052600854610100900460ff1693509150505b9250929050565b6000606061059f61070c565b6105eb576000848481818080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525095975091955061058c945050505050565b60007f00000000000000000000000000000000000000000000000000000000000000001561061a57504361068d565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610666573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061068a9190610b31565b90505b604080516c6400000000000000000000000060208201528151601481830301815260348201928390527f7ddd933e0000000000000000000000000000000000000000000000000000000090925261052f91600691600591600791869190603801610dc8565b6006805461043f90610c04565b6007805461043f90610c04565b600060035460000361071e5750600190565b60007f00000000000000000000000000000000000000000000000000000000000000001561074d5750436107c0565b606473ffffffffffffffffffffffffffffffffffffffff1663a3b1b31d6040518163ffffffff1660e01b8152600401602060405180830381865afa158015610799573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906107bd9190610b31565b90505b6000546003546107d09083610e8b565b1080156107eb57506001546002546107e89083610e8b565b10155b91505090565b6000806020838503121561080457600080fd5b823567ffffffffffffffff8082111561081c57600080fd5b818501915085601f83011261083057600080fd5b81358181111561083f57600080fd5b86602082850101111561085157600080fd5b60209290920196919550909350505050565b60006020828403121561087557600080fd5b5035919050565b6000815180845260005b818110156108a257602081850181015186830182015201610886565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006108f3602083018461087c565b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610970576109706108fa565b604052919050565b600082601f83011261098957600080fd5b813567ffffffffffffffff8111156109a3576109a36108fa565b6109d460207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610929565b8181528460208386010111156109e957600080fd5b816020850160208301376000918101602001919091529392505050565b60008060408385031215610a1957600080fd5b823567ffffffffffffffff80821115610a3157600080fd5b818501915085601f830112610a4557600080fd5b8135602082821115610a5957610a596108fa565b8160051b610a68828201610929565b928352848101820192828101908a851115610a8257600080fd5b83870192505b84831015610abe57823586811115610aa05760008081fd5b610aae8c86838b0101610978565b8352509183019190830190610a88565b9750505086013592505080821115610ad557600080fd5b50610ae285828601610978565b9150509250929050565b8215158152604060208201526000610b07604083018461087c565b949350505050565b600060208284031215610b2157600080fd5b813580151581146108f357600080fd5b600060208284031215610b4357600080fd5b5051919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b80820180821115610b8c57610b8c610b4a565b92915050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b606081526000610bd4606083018661087c565b8281036020840152610be6818661087c565b90508281036040840152610bfa818561087c565b9695505050505050565b600181811c90821680610c1857607f821691505b602082108103610c51577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b50919050565b6000604082016040835280855180835260608501915060608160051b8601019250602080880160005b83811015610ccc577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffa0888703018552610cba86835161087c565b95509382019390820190600101610c80565b505085840381870152505050610ce2818561087c565b95945050505050565b8054600090600181811c9080831680610d0557607f831692505b60208084108203610d3f577f4e487b7100000000000000000000000000000000000000000000000000000000600052602260045260246000fd5b838852818015610d565760018114610d8e57610dbc565b7fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff008616828a01528185151560051b8a01019650610dbc565b876000528160002060005b86811015610db45781548b8201850152908501908301610d99565b8a0183019750505b50505050505092915050565b60a081526000610ddb60a0830188610ceb565b6020838203818501528188548084528284019150828160051b8501018a6000528360002060005b83811015610e4d577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0878403018552610e3b8383610ceb565b94860194925060019182019101610e02565b50508681036040880152610e61818b610ceb565b9450505050508460608401528281036080840152610e7f818561087c565b98975050505050505050565b81810381811115610b8c57610b8c610b4a56fea164736f6c6343000810000a307834353534343832643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030307834323534343332643535353334343264343135323432343935343532353534643264353434353533353434653435353430303030303030303030303030303030", } var MercuryUpkeepABI = MercuryUpkeepMetaData.ABI diff --git a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 823ffb0083e..3f602da118c 100644 --- a/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -15,6 +15,7 @@ consumer_wrapper: ../../contracts/solc/v0.7/Consumer.abi ../../contracts/solc/v0 cron_upkeep_factory_wrapper: ../../contracts/solc/v0.8.6/CronUpkeepFactory.abi - dacb0f8cdf54ae9d2781c5e720fc314b32ed5e58eddccff512c75d6067292cd7 cron_upkeep_wrapper: ../../contracts/solc/v0.8.6/CronUpkeep.abi - 362fcfcf30a6ab3acff83095ea4b2b9056dd5e9dcb94bc5411aae58995d22709 derived_price_feed_wrapper: ../../contracts/solc/v0.8.6/DerivedPriceFeed.abi ../../contracts/solc/v0.8.6/DerivedPriceFeed.bin c8542e6c850c2d0fffb79a7f7213dc927ec64e6ddd54e1224cb2fb4a13aabdd0 +dummy_protocol_wrapper: ../../contracts/solc/v0.8.16/DummyProtocol.abi ../../contracts/solc/v0.8.16/DummyProtocol.bin 583a448170b13abf7ed64e406e8177d78c9e55ab44efd141eee60de23a71ee3b feed_lookup_compatible_interface: ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.abi ../../contracts/solc/v0.8.16/FeedLookupCompatibleInterface.bin 2c5c2cb669a666ab6f14e7fdbd11ea019997e3860f56ccfaf112156e412f1b15 flags_wrapper: ../../contracts/solc/v0.6/Flags.abi ../../contracts/solc/v0.6/Flags.bin 2034d1b562ca37a63068851915e3703980276e8d5f7db6db8a3351a49d69fc4a flux_aggregator_wrapper: ../../contracts/solc/v0.6/FluxAggregator.abi ../../contracts/solc/v0.6/FluxAggregator.bin a3b0a6396c4aa3b5ee39b3c4bd45efc89789d4859379a8a92caca3a0496c5794 @@ -39,9 +40,9 @@ keeper_registry_wrapper2_0: ../../contracts/solc/v0.8.6/KeeperRegistry2_0.abi .. keeper_registry_wrapper_2_1: ../../contracts/solc/v0.8.16/KeeperRegistry2_1.abi ../../contracts/solc/v0.8.16/KeeperRegistry2_1.bin 6406f37de79d3d2efa86fb961e1462b62a5a2fff4aeb408bbdb4bc7272d91638 keepers_vrf_consumer: ../../contracts/solc/v0.8.6/KeepersVRFConsumer.abi ../../contracts/solc/v0.8.6/KeepersVRFConsumer.bin fa75572e689c9e84705c63e8dbe1b7b8aa1a8fe82d66356c4873d024bb9166e8 log_emitter: ../../contracts/solc/v0.8.19/LogEmitter.abi ../../contracts/solc/v0.8.19/LogEmitter.bin 244ba13730c036de0b02beef4e3d9c9a96946ce353c27f366baecc7f5be5a6fd -log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin b16d9cafc51d85c4cd0b32fe0f53e37243b769585c5473c6f0e2c5db7dafc817 +log_triggered_feed_lookup_wrapper: ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin 9678fec51a491bf3f4bfeb582211bf8ab0328b58b2710e45b51be0dde1155933 log_upkeep_counter_wrapper: ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin 13d6543329f89d06cbf3901d7f9ecdc42acc1a84d8c61db291fcbfdbe1138eb1 -mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/MercuryUpkeep.abi ../../contracts/solc/v0.8.16/MercuryUpkeep.bin f19fbcaf789578996cf7d5dc3c2adbad33b661c2d8bb71daf1b87b57a0678564 +mercury_upkeep_wrapper: ../../contracts/solc/v0.8.16/MercuryUpkeep.abi ../../contracts/solc/v0.8.16/MercuryUpkeep.bin 27a33050249b6c7de7236772d7960f29c69e6f8167cc736409312d0e965508a3 mock_aggregator_proxy: ../../contracts/solc/v0.8.6/MockAggregatorProxy.abi ../../contracts/solc/v0.8.6/MockAggregatorProxy.bin b16c108f3dd384c342ddff5e94da7c0a8d39d1be5e3d8f2cf61ecc7f0e50ff42 mock_ethlink_aggregator_wrapper: ../../contracts/solc/v0.6/MockETHLINKAggregator.abi ../../contracts/solc/v0.6/MockETHLINKAggregator.bin 1c52c24f797b8482aa12b8251dcea1c072827bd5b3426b822621261944b99ca0 mock_gas_aggregator_wrapper: ../../contracts/solc/v0.6/MockGASAggregator.abi ../../contracts/solc/v0.6/MockGASAggregator.bin bacbb1ea4dc6beac0db8a13ca5c75e2fd61b903d70feea9b3b1c8b10fe8df4f3 diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index c4d7d576b8d..54531aa6bbd 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -63,6 +63,7 @@ package gethwrappers //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/AutomationForwarderLogic.abi ../../contracts/solc/v0.8.16/AutomationForwarderLogic.bin AutomationForwarderLogic automation_forwarder_logic //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/LogUpkeepCounter.abi ../../contracts/solc/v0.8.6/LogUpkeepCounter.bin LogUpkeepCounter log_upkeep_counter_wrapper //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.abi ../../contracts/solc/v0.8.16/LogTriggeredFeedLookup.bin LogTriggeredFeedLookup log_triggered_feed_lookup_wrapper +//go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.16/DummyProtocol.abi ../../contracts/solc/v0.8.16/DummyProtocol.bin DummyProtocol dummy_protocol_wrapper // v0.8.6 VRFConsumer //go:generate go run ./generation/generate/wrap.go ../../contracts/solc/v0.8.6/VRFCoordinatorMock.abi ../../contracts/solc/v0.8.6/VRFCoordinatorMock.bin VRFCoordinatorMock vrf_coordinator_mock From 1809f99f8fbbe39a4b3604038c3f784fcd208518 Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Wed, 23 Aug 2023 06:55:43 -0700 Subject: [PATCH 242/270] [Functions] Handle zero addresses correctly in LogPollerWrapper (#10310) --- .../relay/evm/functions/logpoller_wrapper.go | 19 +++++- .../evm/functions/logpoller_wrapper_test.go | 65 +++++++++++++++++-- 2 files changed, 75 insertions(+), 9 deletions(-) diff --git a/core/services/relay/evm/functions/logpoller_wrapper.go b/core/services/relay/evm/functions/logpoller_wrapper.go index 1f712ddba32..eae1970da93 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper.go +++ b/core/services/relay/evm/functions/logpoller_wrapper.go @@ -8,6 +8,7 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" + "github.com/pkg/errors" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" @@ -102,8 +103,11 @@ func (l *logPollerWrapper) Ready() error { // methods of LogPollerWrapper func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmRelayTypes.OracleResponse, error) { l.mu.Lock() - coordinators := []common.Address{l.activeCoordinator} - if l.activeCoordinator != l.proposedCoordinator { + coordinators := []common.Address{} + if l.activeCoordinator != (common.Address{}) { + coordinators = append(coordinators, l.activeCoordinator) + } + if l.proposedCoordinator != (common.Address{}) && l.activeCoordinator != l.proposedCoordinator { coordinators = append(coordinators, l.proposedCoordinator) } nextBlock := l.nextBlock @@ -120,6 +124,10 @@ func (l *logPollerWrapper) LatestEvents() ([]evmRelayTypes.OracleRequest, []evmR // outside of the lock resultsReq := []evmRelayTypes.OracleRequest{} resultsResp := []evmRelayTypes.OracleResponse{} + if len(coordinators) == 0 { + l.lggr.Debug("LatestEvents: no non-zero coordinators to check") + return resultsReq, resultsResp, errors.New("no non-zero coordinators to check") + } if latest < nextBlock { l.lggr.Debugw("LatestEvents: no new blocks to check", "latest", latest, "nextBlock", nextBlock) return resultsReq, resultsResp, nil @@ -257,6 +265,7 @@ func (l *logPollerWrapper) checkForRouteUpdates() { active, proposed, err := l.getCurrentCoordinators(timeoutCtx) if err != nil { l.lggr.Errorw("LogPollerWrapper: error calling getCurrentCoordinators", "err", err) + return } l.handleRouteUpdate(active, proposed) } @@ -303,6 +312,12 @@ func (l *logPollerWrapper) getCurrentCoordinators(ctx context.Context) (common.A func (l *logPollerWrapper) handleRouteUpdate(activeCoordinator common.Address, proposedCoordinator common.Address) { l.mu.Lock() defer l.mu.Unlock() + + if activeCoordinator == (common.Address{}) { + l.lggr.Error("LogPollerWrapper: cannot update activeCoordinator to zero address") + return + } + if activeCoordinator == l.activeCoordinator && proposedCoordinator == l.proposedCoordinator { l.lggr.Debug("LogPollerWrapper: no changes to routes") return diff --git a/core/services/relay/evm/functions/logpoller_wrapper_test.go b/core/services/relay/evm/functions/logpoller_wrapper_test.go index ea493880d89..224aa51a5da 100644 --- a/core/services/relay/evm/functions/logpoller_wrapper_test.go +++ b/core/services/relay/evm/functions/logpoller_wrapper_test.go @@ -2,8 +2,10 @@ package functions_test import ( "encoding/hex" + "sync" "testing" + "github.com/ethereum/go-ethereum/common" gethcommon "github.com/ethereum/go-ethereum/common" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" @@ -15,33 +17,82 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/functions/config" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" ) -func TestLogPollerWrapper_BasicEmptyEvents(t *testing.T) { - t.Parallel() +type subscriber struct { + updates sync.WaitGroup + expectedCalls int +} +func (s *subscriber) UpdateRoutes(activeCoordinator common.Address, proposedCoordinator common.Address) error { + if s.expectedCalls == 0 { + panic("unexpected call to UpdateRoutes") + } + if activeCoordinator == (common.Address{}) { + panic("activeCoordinator should not be zero") + } + s.expectedCalls-- + s.updates.Done() + return nil +} + +func newSubscriber(expectedCalls int) *subscriber { + sub := &subscriber{expectedCalls: expectedCalls} + sub.updates.Add(expectedCalls) + return sub +} + +func addr(t *testing.T, lastByte string) []byte { + contractAddr, err := hex.DecodeString("00000000000000000000000000000000000000000000000000000000000000" + lastByte) + require.NoError(t, err) + return contractAddr +} + +func setUp(t *testing.T, updateFrequencySec uint32) (*lpmocks.LogPoller, types.LogPollerWrapper, *evmclimocks.Client) { lggr := logger.TestLogger(t) client := evmclimocks.NewClient(t) lp := lpmocks.NewLogPoller(t) config := config.PluginConfig{ - ContractUpdateCheckFrequencySec: 1000000, // only once + ContractUpdateCheckFrequencySec: updateFrequencySec, ContractVersion: 1, } lpWrapper, err := functions.NewLogPollerWrapper(gethcommon.Address{}, config, client, lp, lggr) require.NoError(t, err) lp.On("LatestBlock").Return(int64(100), nil) - lp.On("Logs", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return([]logpoller.Log{}, nil) - contractAddr, err := hex.DecodeString("0000000000000000000000000000000000000000000000000000000000000001") - require.NoError(t, err) - client.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(contractAddr, nil) + return lp, lpWrapper, client +} + +func TestLogPollerWrapper_SingleSubscriberEmptyEvents(t *testing.T) { + t.Parallel() + lp, lpWrapper, client := setUp(t, 100_000) // check only once + + lp.On("Logs", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return([]logpoller.Log{}, nil) + client.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(addr(t, "01"), nil) lp.On("RegisterFilter", mock.Anything).Return(nil) + subscriber := newSubscriber(1) + lpWrapper.SubscribeToUpdates("mock_subscriber", subscriber) + require.NoError(t, lpWrapper.Start(testutils.Context(t))) + subscriber.updates.Wait() reqs, resps, err := lpWrapper.LatestEvents() require.NoError(t, err) require.Equal(t, 0, len(reqs)) require.Equal(t, 0, len(resps)) lpWrapper.Close() } + +func TestLogPollerWrapper_ErrorOnZeroAddresses(t *testing.T) { + t.Parallel() + _, lpWrapper, client := setUp(t, 100_000) // check only once + + client.On("CallContract", mock.Anything, mock.Anything, mock.Anything).Return(addr(t, "00"), nil) + + require.NoError(t, lpWrapper.Start(testutils.Context(t))) + _, _, err := lpWrapper.LatestEvents() + require.Error(t, err) + lpWrapper.Close() +} From 9bba6b87e5df01e9a460f113eacb395f62f6ef89 Mon Sep 17 00:00:00 2001 From: Jordan Krage Date: Wed, 23 Aug 2023 09:11:00 -0500 Subject: [PATCH 243/270] golangci-lint cleanup (#10312) * bool-literal-in-expr: omit Boolean literal in expression (revive) ineffectual assignment (ineffassign) unused (unused) receiver-naming: receiver name should not be an underscore, omit the name if it is unused (revive) unreachable: unreachable code (govet) rows.Err must be checked (rowserrcheck) * golangci-lint: version golangci-lint output instead of overwriting --- .gitignore | 1 + GNUmakefile | 3 +- core/chains/evm/client/send_only_node_test.go | 2 +- .../evm/gas/block_history_estimator_test.go | 42 +++++++++---------- .../evm/logpoller/log_poller_internal_test.go | 26 +----------- core/chains/evm/logpoller/log_poller_test.go | 2 - core/chains/evm/txmgr/broadcaster_test.go | 7 ---- core/chains/evm/txmgr/txmgr_test.go | 2 +- core/services/job/spawner_test.go | 3 -- .../ocr2/plugins/dkg/persistence/db_test.go | 3 ++ 10 files changed, 30 insertions(+), 61 deletions(-) diff --git a/.gitignore b/.gitignore index b763b582487..4d65eb32a1e 100644 --- a/.gitignore +++ b/.gitignore @@ -45,6 +45,7 @@ core/cmd/TestClient_ImportExportP2PKeyBundle_test_key.json output.txt race.* golangci-lint-output.txt +golangci-lint/ # DB state ./db/ diff --git a/GNUmakefile b/GNUmakefile index b9d11a7cbc6..6ee81eb5036 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -145,7 +145,8 @@ config-docs: ## Generate core node configuration documentation .PHONY: golangci-lint golangci-lint: ## Run golangci-lint for all issues. - docker run --rm -v $(shell pwd):/app -w /app golangci/golangci-lint:v1.53.2 golangci-lint run --max-issues-per-linter 0 --max-same-issues 0 > golangci-lint-output.txt + [ -d "./golangci-lint" ] || mkdir ./golangci-lint && \ + docker run --rm -v $(shell pwd):/app -w /app golangci/golangci-lint:v1.53.2 golangci-lint run --max-issues-per-linter 0 --max-same-issues 0 > ./golangci-lint/$(shell date --iso=seconds).txt GORELEASER_CONFIG ?= .goreleaser.yaml diff --git a/core/chains/evm/client/send_only_node_test.go b/core/chains/evm/client/send_only_node_test.go index de0ecd98e96..b37ee142533 100644 --- a/core/chains/evm/client/send_only_node_test.go +++ b/core/chains/evm/client/send_only_node_test.go @@ -160,7 +160,7 @@ func TestBatchCallContext(t *testing.T) { mock.MatchedBy( func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == blockNum && b[0].Args[1] == true + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == blockNum && b[0].Args[1].(bool) })).Return(nil).Once().Return(nil) s.SetEthClient(mockBatchSender, nil) diff --git a/core/chains/evm/gas/block_history_estimator_test.go b/core/chains/evm/gas/block_history_estimator_test.go index 3e7d201f7ec..c44e68002d2 100644 --- a/core/chains/evm/gas/block_history_estimator_test.go +++ b/core/chains/evm/gas/block_history_estimator_test.go @@ -83,8 +83,8 @@ func TestBlockHistoryEstimator_Start(t *testing.T) { ethClient.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(h, nil) ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == "0x2a" && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == "0x29" && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == "0x2a" && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == "0x29" && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &evmtypes.Block{ @@ -129,7 +129,7 @@ func TestBlockHistoryEstimator_Start(t *testing.T) { // First succeeds (42) ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 1 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(42) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(42) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &evmtypes.Block{ @@ -140,7 +140,7 @@ func TestBlockHistoryEstimator_Start(t *testing.T) { // Second fails (41) ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 1 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(41) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(41) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Return(errors.Wrap(context.DeadlineExceeded, "some error message")).Once() err := bhe.Start(testutils.Context(t)) @@ -382,8 +382,8 @@ func TestBlockHistoryEstimator_FetchBlocks(t *testing.T) { ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(43) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(42) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(43) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(42) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Once().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &b43 @@ -392,7 +392,7 @@ func TestBlockHistoryEstimator_FetchBlocks(t *testing.T) { }) ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 1 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(41) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(41) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Once().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &b41 @@ -420,8 +420,8 @@ func TestBlockHistoryEstimator_FetchBlocks(t *testing.T) { // 43 is skipped because it was already in the history ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(44) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(42) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(44) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(42) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Once().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &b44 @@ -484,8 +484,8 @@ func TestBlockHistoryEstimator_FetchBlocks(t *testing.T) { ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(3) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(2) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(3) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(2) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Once().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &b3 @@ -551,8 +551,8 @@ func TestBlockHistoryEstimator_FetchBlocks(t *testing.T) { ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(3) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(2) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(3) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(2) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Once().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) b2New := b2 @@ -663,8 +663,8 @@ func TestBlockHistoryEstimator_FetchBlocks(t *testing.T) { ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 2 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(43) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(42) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(43) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(42) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Once().Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &b43 @@ -1816,9 +1816,9 @@ func TestBlockHistoryEstimator_UseDefaultPriceAsFallback(t *testing.T) { ethClient.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(h, nil) ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 3 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(42) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(41) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[2].Method == "eth_getBlockByNumber" && b[2].Args[0] == gas.Int64ToHex(40) && b[1].Args[1] == true && reflect.TypeOf(b[2].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(42) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(41) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[2].Method == "eth_getBlockByNumber" && b[2].Args[0] == gas.Int64ToHex(40) && b[1].Args[1].(bool) && reflect.TypeOf(b[2].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &evmtypes.Block{ @@ -1868,9 +1868,9 @@ func TestBlockHistoryEstimator_UseDefaultPriceAsFallback(t *testing.T) { ethClient.On("HeadByNumber", mock.Anything, (*big.Int)(nil)).Return(h, nil) ethClient.On("BatchCallContext", mock.Anything, mock.MatchedBy(func(b []rpc.BatchElem) bool { return len(b) == 3 && - b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(42) && b[0].Args[1] == true && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(41) && b[1].Args[1] == true && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) && - b[2].Method == "eth_getBlockByNumber" && b[2].Args[0] == gas.Int64ToHex(40) && b[1].Args[1] == true && reflect.TypeOf(b[2].Result) == reflect.TypeOf(&evmtypes.Block{}) + b[0].Method == "eth_getBlockByNumber" && b[0].Args[0] == gas.Int64ToHex(42) && b[0].Args[1].(bool) && reflect.TypeOf(b[0].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[1].Method == "eth_getBlockByNumber" && b[1].Args[0] == gas.Int64ToHex(41) && b[1].Args[1].(bool) && reflect.TypeOf(b[1].Result) == reflect.TypeOf(&evmtypes.Block{}) && + b[2].Method == "eth_getBlockByNumber" && b[2].Args[0] == gas.Int64ToHex(40) && b[1].Args[1].(bool) && reflect.TypeOf(b[2].Result) == reflect.TypeOf(&evmtypes.Block{}) })).Return(nil).Run(func(args mock.Arguments) { elems := args.Get(1).([]rpc.BatchElem) elems[0].Result = &evmtypes.Block{ diff --git a/core/chains/evm/logpoller/log_poller_internal_test.go b/core/chains/evm/logpoller/log_poller_internal_test.go index 6a78d2e30ae..13ec0262391 100644 --- a/core/chains/evm/logpoller/log_poller_internal_test.go +++ b/core/chains/evm/logpoller/log_poller_internal_test.go @@ -11,14 +11,11 @@ import ( "github.com/ethereum/go-ethereum/accounts/abi" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" - "github.com/jackc/pgconn" "github.com/pkg/errors" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" "go.uber.org/zap/zapcore" - "go.uber.org/zap/zaptest/observer" - "golang.org/x/exp/slices" evmclimocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client/mocks" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" @@ -58,14 +55,13 @@ func TestLogPoller_RegisterFilter(t *testing.T) { db := pgtest.NewSqlxDB(t) orm := NewORM(chainID, db, lggr, pgtest.NewQConfig(true)) - lp := NewLogPoller(orm, nil, lggr, time.Hour, 1, 1, 2, 1000) db.Close() db = pgtest.NewSqlxDB(t) orm = NewORM(chainID, db, lggr, pgtest.NewQConfig(true)) // Set up a test chain with a log emitting contract deployed. - lp = NewLogPoller(orm, nil, lggr, time.Hour, 1, 1, 2, 1000) + lp := NewLogPoller(orm, nil, lggr, time.Hour, 1, 1, 2, 1000) // We expect a zero Filter if nothing registered yet. f := lp.Filter(nil, nil, nil) @@ -138,26 +134,6 @@ func TestLogPoller_RegisterFilter(t *testing.T) { assert.Len(t, lp.Filter(nil, nil, nil).Topics[0], 0) } -func assertForeignConstraintError(t *testing.T, observedLog observer.LoggedEntry, - table string, constraint string) { - - assert.Equal(t, "SQL ERROR", observedLog.Entry.Message) - - i := slices.IndexFunc(observedLog.Context, func(f zapcore.Field) bool { - return f.Key == "err" - }) - require.GreaterOrEqual(t, i, 0) - field := observedLog.Context[i] - require.Equal(t, zapcore.ErrorType, field.Type) - err, ok := field.Interface.(error) - var pgErr *pgconn.PgError - require.True(t, errors.As(err, &pgErr)) - require.True(t, ok) - assert.Equal(t, "23503", pgErr.SQLState()) // foreign key constraint violation code - assert.Equal(t, table, pgErr.TableName) - assert.Equal(t, constraint, pgErr.ConstraintName) -} - func TestLogPoller_ConvertLogs(t *testing.T) { t.Parallel() lggr := logger.TestLogger(t) diff --git a/core/chains/evm/logpoller/log_poller_test.go b/core/chains/evm/logpoller/log_poller_test.go index 595b961101f..17df4dc6291 100644 --- a/core/chains/evm/logpoller/log_poller_test.go +++ b/core/chains/evm/logpoller/log_poller_test.go @@ -1098,8 +1098,6 @@ func TestTooManyLogResults(t *testing.T) { return []types.Log{}, nil // succeed when single block requested } return []types.Log{}, &clientErr // return "too many results" error if block range spans 4 or more blocks - - return logs, err }) lp.PollAndSaveLogs(ctx, 298) diff --git a/core/chains/evm/txmgr/broadcaster_test.go b/core/chains/evm/txmgr/broadcaster_test.go index 6d16a697bbd..2e3a1e0f731 100644 --- a/core/chains/evm/txmgr/broadcaster_test.go +++ b/core/chains/evm/txmgr/broadcaster_test.go @@ -1870,13 +1870,6 @@ func TestEthBroadcaster_SyncNonce(t *testing.T) { } -func checkerToJson(t *testing.T, checker txmgr.TransmitCheckerSpec) *datatypes.JSON { - b, err := json.Marshal(checker) - require.NoError(t, err) - j := datatypes.JSON(b) - return &j -} - type testCheckerFactory struct { err error } diff --git a/core/chains/evm/txmgr/txmgr_test.go b/core/chains/evm/txmgr/txmgr_test.go index c3c995e8abf..d127304c408 100644 --- a/core/chains/evm/txmgr/txmgr_test.go +++ b/core/chains/evm/txmgr/txmgr_test.go @@ -430,7 +430,7 @@ type transactionsConfig struct { e *evmConfig } -func (_ *transactionsConfig) ForwardersEnabled() bool { return true } +func (*transactionsConfig) ForwardersEnabled() bool { return true } func (t *transactionsConfig) MaxInFlight() uint32 { return t.e.maxInFlight } func (t *transactionsConfig) MaxQueued() uint64 { return t.e.maxQueued } func (t *transactionsConfig) ReaperInterval() time.Duration { return t.e.reaperInterval } diff --git a/core/services/job/spawner_test.go b/core/services/job/spawner_test.go index a013bd50bc1..f35aa50ba4d 100644 --- a/core/services/job/spawner_test.go +++ b/core/services/job/spawner_test.go @@ -66,9 +66,6 @@ type relayGetter struct { r *evmrelayer.Relayer } -func newrelayGetter() *relayGetter { - return &relayGetter{} -} func (g *relayGetter) Get(id relay.ID) (loop.Relayer, error) { return evmrelayer.NewLoopRelayAdapter(g.r, g.e), nil } diff --git a/core/services/ocr2/plugins/dkg/persistence/db_test.go b/core/services/ocr2/plugins/dkg/persistence/db_test.go index 3eb3eb19b03..b830a8db3bc 100644 --- a/core/services/ocr2/plugins/dkg/persistence/db_test.go +++ b/core/services/ocr2/plugins/dkg/persistence/db_test.go @@ -60,6 +60,7 @@ func TestShareDB_WriteShareRecords(t *testing.T) { for rows.Next() { require.NoError(tt, rows.Scan(&count)) } + require.NoError(tt, rows.Err()) require.Equal(tt, 3, count) }) @@ -88,6 +89,7 @@ func TestShareDB_WriteShareRecords(t *testing.T) { for rows.Next() { require.NoError(tt, rows.Scan(&count)) } + require.NoError(tt, rows.Err()) require.Equal(tt, 0, count) }) @@ -125,6 +127,7 @@ func TestShareDB_WriteShareRecords(t *testing.T) { for rows.Next() { require.NoError(tt, rows.Scan(&count)) } + require.NoError(tt, rows.Err()) require.Equal(tt, 0, count) }) From 89eaf14545add6c9ec85351a13efe010cd87abfe Mon Sep 17 00:00:00 2001 From: Bolek <1416262+bolekk@users.noreply.github.com> Date: Wed, 23 Aug 2023 07:27:03 -0700 Subject: [PATCH 244/270] [Functions] Use ciphertextID equal to requestID bytes (#10299) --- .../functions/src/generate_ocr2_config_cmd.go | 2 + core/scripts/functions/src/sample_config.json | 3 +- core/scripts/go.mod | 4 +- core/scripts/go.sum | 8 +- core/services/functions/listener.go | 13 +- core/services/functions/listener_test.go | 8 +- .../ocr2/plugins/functions/config/config.go | 1 + .../functions/config/config_types.pb.go | 164 ++++++++++-------- .../functions/config/config_types.proto | 2 + .../v0/functions_integration_test.go | 1 + .../v1/functions_integration_test.go | 1 + .../plugins/threshold/decryption_queue.go | 28 +-- .../threshold/decryption_queue_test.go | 17 +- .../ocr2/plugins/threshold/mocks/decryptor.go | 9 +- go.mod | 4 +- go.sum | 8 +- integration-tests/go.mod | 4 +- integration-tests/go.sum | 8 +- 18 files changed, 155 insertions(+), 130 deletions(-) diff --git a/core/scripts/functions/src/generate_ocr2_config_cmd.go b/core/scripts/functions/src/generate_ocr2_config_cmd.go index 0310360fbe2..cbb6a7f3bbc 100644 --- a/core/scripts/functions/src/generate_ocr2_config_cmd.go +++ b/core/scripts/functions/src/generate_ocr2_config_cmd.go @@ -32,6 +32,7 @@ type ThresholdOffchainConfig struct { RequestCountLimit uint32 RequestTotalBytesLimit uint32 RequireLocalRequestCheck bool + K uint32 } type S4ReportingPluginConfig struct { @@ -222,6 +223,7 @@ func (g *generateOCR2Config) Run(args []string) { RequestCountLimit: cfg.ThresholdOffchainConfig.RequestCountLimit, RequestTotalBytesLimit: cfg.ThresholdOffchainConfig.RequestTotalBytesLimit, RequireLocalRequestCheck: cfg.ThresholdOffchainConfig.RequireLocalRequestCheck, + K: cfg.ThresholdOffchainConfig.K, }, S4PluginConfig: &config.S4ReportingPluginConfig{ MaxQueryLengthBytes: cfg.S4ReportingPluginConfig.MaxQueryLengthBytes, diff --git a/core/scripts/functions/src/sample_config.json b/core/scripts/functions/src/sample_config.json index 474000a7adb..a6f4f5b0aa2 100644 --- a/core/scripts/functions/src/sample_config.json +++ b/core/scripts/functions/src/sample_config.json @@ -14,7 +14,8 @@ "MaxReportLengthBytes": 10000, "RequestCountLimit": 100, "RequestTotalBytesLimit": 100000, - "RequireLocalRequestCheck": true + "RequireLocalRequestCheck": true, + "K": 3 }, "S4ReportingPluginConfig": { diff --git a/core/scripts/go.mod b/core/scripts/go.mod index d8b38e9b891..1c2ee9fd637 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -301,8 +301,8 @@ require ( github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect - github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect - github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 // indirect + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb // indirect + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect github.com/spaolacci/murmur3 v1.1.0 // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 4814f0769b6..caa7c1b6f44 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1389,10 +1389,10 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SO github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 h1:AQsTWhkwF/a9Dbv2Y4U4Xi5Go1sflttB0rHL6+8TD6c= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb h1:xNLGJcARfz9HCUKla6wH0gmwsG1/FTAWWeOplW2J72A= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb h1:jyhgdafuZsex+kEHDIgq8o8wuVoPTr9wsGmuBtcFbEk= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= diff --git a/core/services/functions/listener.go b/core/services/functions/listener.go index 6d7e69f830c..f7c94437654 100644 --- a/core/services/functions/listener.go +++ b/core/services/functions/listener.go @@ -500,7 +500,7 @@ func (l *FunctionsListener) handleRequest(ctx context.Context, requestID Request return } - nodeProvidedSecrets, userErr, internalErr := l.getSecrets(ctx, eaClient, requestIDStr, subscriptionOwner, requestData) + nodeProvidedSecrets, userErr, internalErr := l.getSecrets(ctx, eaClient, requestID, subscriptionOwner, requestData) if internalErr != nil { l.logger.Errorw("internal error during getSecrets", "requestID", requestIDStr, "err", internalErr) l.setError(ctx, requestID, INTERNAL_ERROR, []byte(internalErr.Error())) @@ -678,25 +678,26 @@ func (l *FunctionsListener) reportSourceCodeDomains(requestId RequestID, domains } } -func (l *FunctionsListener) getSecrets(ctx context.Context, eaClient ExternalAdapterClient, requestID string, subscriptionOwner common.Address, requestData *RequestData) (decryptedSecrets string, userError, internalError error) { +func (l *FunctionsListener) getSecrets(ctx context.Context, eaClient ExternalAdapterClient, requestID RequestID, subscriptionOwner common.Address, requestData *RequestData) (decryptedSecrets string, userError, internalError error) { if l.decryptor == nil { l.logger.Warn("Decryptor not configured") return "", nil, nil } var secrets []byte + requestIDStr := formatRequestId(requestID) switch requestData.SecretsLocation { case LocationInline: - l.logger.Warnw("request used Inline secrets location, processing with no secrets", "requestID", requestID) + l.logger.Warnw("request used Inline secrets location, processing with no secrets", "requestID", requestIDStr) return "", nil, nil case LocationRemote: - thresholdEncSecrets, userError, err := eaClient.FetchEncryptedSecrets(ctx, requestData.Secrets, requestID, l.job.Name.ValueOrZero()) + thresholdEncSecrets, userError, err := eaClient.FetchEncryptedSecrets(ctx, requestData.Secrets, requestIDStr, l.job.Name.ValueOrZero()) if err != nil { return "", nil, errors.Wrap(err, "failed to fetch encrypted secrets") } if len(userError) != 0 { - l.logger.Debugw("no valid threshold encrypted secrets detected, falling back to legacy secrets", "requestID", requestID, "err", string(userError)) + l.logger.Debugw("no valid threshold encrypted secrets detected, falling back to legacy secrets", "requestID", requestIDStr, "err", string(userError)) } secrets = thresholdEncSecrets case LocationDONHosted: @@ -725,7 +726,7 @@ func (l *FunctionsListener) getSecrets(ctx context.Context, eaClient ExternalAda decryptCtx, cancel := context.WithTimeout(ctx, time.Duration(l.pluginConfig.DecryptionQueueConfig.DecryptRequestTimeoutSec)*time.Second) defer cancel() - decryptedSecretsBytes, err := l.decryptor.Decrypt(decryptCtx, []byte(requestID), secrets) + decryptedSecretsBytes, err := l.decryptor.Decrypt(decryptCtx, requestID[:], secrets) if err != nil { return "", errors.New("threshold decryption of secrets failed"), nil } diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index 70790d95cf5..f8db766c31c 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -17,6 +17,8 @@ import ( "github.com/stretchr/testify/require" "google.golang.org/protobuf/proto" + decryptionPlugin "github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin" + cl_cbor "github.com/smartcontractkit/chainlink/v2/core/cbor" log_mocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/log/mocks" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/ocr2dr_oracle" @@ -214,7 +216,7 @@ func TestFunctionsListener_ThresholdDecryptedSecrets(t *testing.T) { uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) uni.eaClient.On("FetchEncryptedSecrets", mock.Anything, mock.Anything, RequestIDStr, mock.Anything, mock.Anything).Return(EncryptedSecrets, nil, nil) - uni.decryptor.On("Decrypt", mock.Anything, []byte(RequestIDStr), EncryptedSecrets).Return(DecryptedSecrets, nil) + uni.decryptor.On("Decrypt", mock.Anything, decryptionPlugin.CiphertextId(RequestID[:]), EncryptedSecrets).Return(DecryptedSecrets, nil) uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, string(DecryptedSecrets), mock.Anything).Return(ResultBytes, nil, nil, nil) uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) @@ -247,7 +249,7 @@ func TestFunctionsListener_ThresholdDecryptedSecretsFailure(t *testing.T) { uni.logBroadcaster.On("MarkConsumed", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) uni.eaClient.On("FetchEncryptedSecrets", mock.Anything, mock.Anything, RequestIDStr, mock.Anything, mock.Anything).Return(EncryptedSecrets, nil, nil) - uni.decryptor.On("Decrypt", mock.Anything, []byte(RequestIDStr), EncryptedSecrets).Return(nil, errors.New("threshold decryption error")) + uni.decryptor.On("Decrypt", mock.Anything, decryptionPlugin.CiphertextId(RequestID[:]), EncryptedSecrets).Return(nil, errors.New("threshold decryption error")) uni.pluginORM.On("SetError", RequestID, functions_service.USER_ERROR, []byte("threshold decryption of secrets failed"), mock.Anything, true, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) }).Return(nil) @@ -566,7 +568,7 @@ func TestFunctionsListener_HandleOracleRequestV1_ThresholdDecryptedSecrets(t *te uni.pluginORM.On("CreateRequest", mock.Anything, mock.Anything).Return(nil) uni.bridgeAccessor.On("NewExternalAdapterClient").Return(uni.eaClient, nil) uni.eaClient.On("FetchEncryptedSecrets", mock.Anything, mock.Anything, RequestIDStr, mock.Anything, mock.Anything).Return(EncryptedSecrets, nil, nil) - uni.decryptor.On("Decrypt", mock.Anything, []byte(RequestIDStr), EncryptedSecrets).Return(DecryptedSecrets, nil) + uni.decryptor.On("Decrypt", mock.Anything, decryptionPlugin.CiphertextId(RequestID[:]), EncryptedSecrets).Return(DecryptedSecrets, nil) uni.eaClient.On("RunComputation", mock.Anything, RequestIDStr, mock.Anything, SubscriptionOwner.Hex(), SubscriptionID, mock.Anything, mock.Anything, mock.Anything).Return(ResultBytes, nil, nil, nil) uni.pluginORM.On("SetResult", RequestID, ResultBytes, mock.Anything, mock.Anything).Run(func(args mock.Arguments) { close(doneCh) diff --git a/core/services/ocr2/plugins/functions/config/config.go b/core/services/ocr2/plugins/functions/config/config.go index a14a3f2d815..d373de57376 100644 --- a/core/services/ocr2/plugins/functions/config/config.go +++ b/core/services/ocr2/plugins/functions/config/config.go @@ -113,6 +113,7 @@ func (ThresholdConfigParser) ParseConfig(config []byte) (*decryptionPluginConfig RequestCountLimit: thresholdPluginConfig.RequestCountLimit, RequestTotalBytesLimit: thresholdPluginConfig.RequestTotalBytesLimit, RequireLocalRequestCheck: thresholdPluginConfig.RequireLocalRequestCheck, + K: thresholdPluginConfig.K, }, }, nil } diff --git a/core/services/ocr2/plugins/functions/config/config_types.pb.go b/core/services/ocr2/plugins/functions/config/config_types.pb.go index b185a9176c2..b9debdcd466 100644 --- a/core/services/ocr2/plugins/functions/config/config_types.pb.go +++ b/core/services/ocr2/plugins/functions/config/config_types.pb.go @@ -66,6 +66,7 @@ func (AggregationMethod) EnumDescriptor() ([]byte, []int) { return file_core_services_ocr2_plugins_functions_config_config_types_proto_rawDescGZIP(), []int{0} } +// Has to match the corresponding proto in tdh2. type ThresholdReportingPluginConfig struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -77,6 +78,7 @@ type ThresholdReportingPluginConfig struct { RequestCountLimit uint32 `protobuf:"varint,4,opt,name=request_count_limit,json=requestCountLimit,proto3" json:"request_count_limit,omitempty"` RequestTotalBytesLimit uint32 `protobuf:"varint,5,opt,name=request_total_bytes_limit,json=requestTotalBytesLimit,proto3" json:"request_total_bytes_limit,omitempty"` RequireLocalRequestCheck bool `protobuf:"varint,6,opt,name=require_local_request_check,json=requireLocalRequestCheck,proto3" json:"require_local_request_check,omitempty"` + K uint32 `protobuf:"varint,7,opt,name=k,proto3" json:"k,omitempty"` // Number of decryption shares required for assembling plaintext. } func (x *ThresholdReportingPluginConfig) Reset() { @@ -153,6 +155,13 @@ func (x *ThresholdReportingPluginConfig) GetRequireLocalRequestCheck() bool { return false } +func (x *ThresholdReportingPluginConfig) GetK() uint32 { + if x != nil { + return x.K + } + return 0 +} + type S4ReportingPluginConfig struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -261,7 +270,9 @@ type ReportingPluginConfig struct { UniqueReports bool `protobuf:"varint,6,opt,name=uniqueReports,proto3" json:"uniqueReports,omitempty"` ThresholdPluginConfig *ThresholdReportingPluginConfig `protobuf:"bytes,7,opt,name=thresholdPluginConfig,proto3" json:"thresholdPluginConfig,omitempty"` S4PluginConfig *S4ReportingPluginConfig `protobuf:"bytes,8,opt,name=s4PluginConfig,proto3" json:"s4PluginConfig,omitempty"` - MaxReportTotalCallbackGas uint32 `protobuf:"varint,9,opt,name=maxReportTotalCallbackGas,proto3" json:"maxReportTotalCallbackGas,omitempty"` + // Needs to be set in tandem with gas estimator (e.g. [EVM.GasEstimator.LimitJobType] OCR = ) + // otherwise the report won't go through TX Manager or fail later. + MaxReportTotalCallbackGas uint32 `protobuf:"varint,9,opt,name=maxReportTotalCallbackGas,proto3" json:"maxReportTotalCallbackGas,omitempty"` } func (x *ReportingPluginConfig) Reset() { @@ -367,7 +378,7 @@ var file_core_services_ocr2_plugins_functions_config_config_types_proto_rawDesc 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x16, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x66, - 0x69, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x22, 0xf7, 0x02, 0x0a, 0x1e, 0x54, 0x68, 0x72, + 0x69, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x22, 0x85, 0x03, 0x0a, 0x1e, 0x54, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x33, 0x0a, 0x16, 0x6d, 0x61, 0x78, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5f, @@ -391,80 +402,81 @@ var file_core_services_ocr2_plugins_functions_config_config_types_proto_rawDesc 0x6f, 0x63, 0x61, 0x6c, 0x5f, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x5f, 0x63, 0x68, 0x65, 0x63, 0x6b, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x18, 0x72, 0x65, 0x71, 0x75, 0x69, 0x72, 0x65, 0x4c, 0x6f, 0x63, 0x61, 0x6c, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x43, 0x68, 0x65, - 0x63, 0x6b, 0x22, 0x95, 0x03, 0x0a, 0x17, 0x53, 0x34, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, - 0x6e, 0x67, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x33, - 0x0a, 0x16, 0x6d, 0x61, 0x78, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x6c, 0x65, 0x6e, 0x67, - 0x74, 0x68, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x13, - 0x6d, 0x61, 0x78, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, - 0x74, 0x65, 0x73, 0x12, 0x3f, 0x0a, 0x1c, 0x6d, 0x61, 0x78, 0x5f, 0x6f, 0x62, 0x73, 0x65, 0x72, - 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5f, 0x62, 0x79, - 0x74, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x19, 0x6d, 0x61, 0x78, 0x4f, 0x62, - 0x73, 0x65, 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, - 0x79, 0x74, 0x65, 0x73, 0x12, 0x35, 0x0a, 0x17, 0x6d, 0x61, 0x78, 0x5f, 0x72, 0x65, 0x70, 0x6f, - 0x72, 0x74, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x14, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, - 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x11, 0x6e, - 0x5f, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x5f, 0x73, 0x68, 0x61, 0x72, 0x64, 0x73, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0f, 0x6e, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, - 0x74, 0x53, 0x68, 0x61, 0x72, 0x64, 0x73, 0x12, 0x36, 0x0a, 0x17, 0x6d, 0x61, 0x78, 0x5f, 0x6f, - 0x62, 0x73, 0x65, 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x6e, 0x74, 0x72, 0x69, - 0x65, 0x73, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x15, 0x6d, 0x61, 0x78, 0x4f, 0x62, 0x73, - 0x65, 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x12, - 0x2c, 0x0a, 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x72, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x5f, 0x65, 0x6e, - 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x10, 0x6d, 0x61, 0x78, - 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x12, 0x3b, 0x0a, - 0x1a, 0x6d, 0x61, 0x78, 0x5f, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5f, 0x65, 0x78, 0x70, 0x69, - 0x72, 0x65, 0x64, 0x5f, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, - 0x0d, 0x52, 0x17, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x45, 0x78, 0x70, 0x69, - 0x72, 0x65, 0x64, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x22, 0xff, 0x04, 0x0a, 0x15, 0x52, - 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, - 0x6e, 0x66, 0x69, 0x67, 0x12, 0x30, 0x0a, 0x13, 0x6d, 0x61, 0x78, 0x51, 0x75, 0x65, 0x72, 0x79, - 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0d, 0x52, 0x13, 0x6d, 0x61, 0x78, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4c, 0x65, 0x6e, 0x67, 0x74, - 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x3c, 0x0a, 0x19, 0x6d, 0x61, 0x78, 0x4f, 0x62, 0x73, - 0x65, 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, - 0x74, 0x65, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x19, 0x6d, 0x61, 0x78, 0x4f, 0x62, - 0x73, 0x65, 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, - 0x79, 0x74, 0x65, 0x73, 0x12, 0x32, 0x0a, 0x14, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, - 0x74, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, - 0x28, 0x0d, 0x52, 0x14, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x4c, 0x65, 0x6e, - 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x30, 0x0a, 0x13, 0x6d, 0x61, 0x78, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x69, 0x7a, 0x65, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x13, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, - 0x74, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x65, 0x0a, 0x18, 0x64, 0x65, - 0x66, 0x61, 0x75, 0x6c, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x66, - 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, - 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, - 0x6e, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x52, 0x18, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, - 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x68, 0x6f, - 0x64, 0x12, 0x24, 0x0a, 0x0d, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x72, - 0x74, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, - 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x73, 0x12, 0x6c, 0x0a, 0x15, 0x74, 0x68, 0x72, 0x65, 0x73, - 0x68, 0x6f, 0x6c, 0x64, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x36, 0x2e, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, - 0x54, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, - 0x6e, 0x67, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x15, - 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, - 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x57, 0x0a, 0x0e, 0x73, 0x34, 0x50, 0x6c, 0x75, 0x67, 0x69, - 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2f, 0x2e, - 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, - 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x53, 0x34, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, - 0x6e, 0x67, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x0e, - 0x73, 0x34, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x3c, - 0x0a, 0x19, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x54, 0x6f, 0x74, 0x61, 0x6c, - 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x0d, 0x52, 0x19, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x54, 0x6f, 0x74, 0x61, - 0x6c, 0x43, 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x2a, 0x41, 0x0a, 0x11, - 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x68, 0x6f, - 0x64, 0x12, 0x14, 0x0a, 0x10, 0x41, 0x47, 0x47, 0x52, 0x45, 0x47, 0x41, 0x54, 0x49, 0x4f, 0x4e, - 0x5f, 0x4d, 0x4f, 0x44, 0x45, 0x10, 0x00, 0x12, 0x16, 0x0a, 0x12, 0x41, 0x47, 0x47, 0x52, 0x45, - 0x47, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4d, 0x45, 0x44, 0x49, 0x41, 0x4e, 0x10, 0x01, 0x42, - 0x2d, 0x5a, 0x2b, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, - 0x2f, 0x6f, 0x63, 0x72, 0x32, 0x2f, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x2f, 0x66, 0x75, - 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x62, 0x06, - 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x63, 0x6b, 0x12, 0x0c, 0x0a, 0x01, 0x6b, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x01, 0x6b, + 0x22, 0x95, 0x03, 0x0a, 0x17, 0x53, 0x34, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6e, 0x67, + 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x33, 0x0a, 0x16, + 0x6d, 0x61, 0x78, 0x5f, 0x71, 0x75, 0x65, 0x72, 0x79, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, + 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x13, 0x6d, 0x61, + 0x78, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, + 0x73, 0x12, 0x3f, 0x0a, 0x1c, 0x6d, 0x61, 0x78, 0x5f, 0x6f, 0x62, 0x73, 0x65, 0x72, 0x76, 0x61, + 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5f, 0x62, 0x79, 0x74, 0x65, + 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x19, 0x6d, 0x61, 0x78, 0x4f, 0x62, 0x73, 0x65, + 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, + 0x65, 0x73, 0x12, 0x35, 0x0a, 0x17, 0x6d, 0x61, 0x78, 0x5f, 0x72, 0x65, 0x70, 0x6f, 0x72, 0x74, + 0x5f, 0x6c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x5f, 0x62, 0x79, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, + 0x01, 0x28, 0x0d, 0x52, 0x14, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x4c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x2a, 0x0a, 0x11, 0x6e, 0x5f, 0x73, + 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x5f, 0x73, 0x68, 0x61, 0x72, 0x64, 0x73, 0x18, 0x04, + 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0f, 0x6e, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x53, + 0x68, 0x61, 0x72, 0x64, 0x73, 0x12, 0x36, 0x0a, 0x17, 0x6d, 0x61, 0x78, 0x5f, 0x6f, 0x62, 0x73, + 0x65, 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, + 0x18, 0x05, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x15, 0x6d, 0x61, 0x78, 0x4f, 0x62, 0x73, 0x65, 0x72, + 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x12, 0x2c, 0x0a, + 0x12, 0x6d, 0x61, 0x78, 0x5f, 0x72, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x5f, 0x65, 0x6e, 0x74, 0x72, + 0x69, 0x65, 0x73, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x10, 0x6d, 0x61, 0x78, 0x52, 0x65, + 0x70, 0x6f, 0x72, 0x74, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x12, 0x3b, 0x0a, 0x1a, 0x6d, + 0x61, 0x78, 0x5f, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x5f, 0x65, 0x78, 0x70, 0x69, 0x72, 0x65, + 0x64, 0x5f, 0x65, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0d, 0x52, + 0x17, 0x6d, 0x61, 0x78, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x45, 0x78, 0x70, 0x69, 0x72, 0x65, + 0x64, 0x45, 0x6e, 0x74, 0x72, 0x69, 0x65, 0x73, 0x22, 0xff, 0x04, 0x0a, 0x15, 0x52, 0x65, 0x70, + 0x6f, 0x72, 0x74, 0x69, 0x6e, 0x67, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, + 0x69, 0x67, 0x12, 0x30, 0x0a, 0x13, 0x6d, 0x61, 0x78, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4c, 0x65, + 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, + 0x13, 0x6d, 0x61, 0x78, 0x51, 0x75, 0x65, 0x72, 0x79, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, + 0x79, 0x74, 0x65, 0x73, 0x12, 0x3c, 0x0a, 0x19, 0x6d, 0x61, 0x78, 0x4f, 0x62, 0x73, 0x65, 0x72, + 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, + 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x19, 0x6d, 0x61, 0x78, 0x4f, 0x62, 0x73, 0x65, + 0x72, 0x76, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4c, 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, + 0x65, 0x73, 0x12, 0x32, 0x0a, 0x14, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x4c, + 0x65, 0x6e, 0x67, 0x74, 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, + 0x52, 0x14, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x4c, 0x65, 0x6e, 0x67, 0x74, + 0x68, 0x42, 0x79, 0x74, 0x65, 0x73, 0x12, 0x30, 0x0a, 0x13, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x42, 0x61, 0x74, 0x63, 0x68, 0x53, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, + 0x01, 0x28, 0x0d, 0x52, 0x13, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x42, + 0x61, 0x74, 0x63, 0x68, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x65, 0x0a, 0x18, 0x64, 0x65, 0x66, 0x61, + 0x75, 0x6c, 0x74, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, + 0x74, 0x68, 0x6f, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, 0x66, 0x75, 0x6e, + 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x74, 0x79, + 0x70, 0x65, 0x73, 0x2e, 0x41, 0x67, 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4d, + 0x65, 0x74, 0x68, 0x6f, 0x64, 0x52, 0x18, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6c, 0x74, 0x41, 0x67, + 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x12, + 0x24, 0x0a, 0x0d, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x73, + 0x18, 0x06, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0d, 0x75, 0x6e, 0x69, 0x71, 0x75, 0x65, 0x52, 0x65, + 0x70, 0x6f, 0x72, 0x74, 0x73, 0x12, 0x6c, 0x0a, 0x15, 0x74, 0x68, 0x72, 0x65, 0x73, 0x68, 0x6f, + 0x6c, 0x64, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x07, + 0x20, 0x01, 0x28, 0x0b, 0x32, 0x36, 0x2e, 0x66, 0x75, 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, + 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x73, 0x2e, 0x54, 0x68, + 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6e, 0x67, + 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x15, 0x74, 0x68, + 0x72, 0x65, 0x73, 0x68, 0x6f, 0x6c, 0x64, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, + 0x66, 0x69, 0x67, 0x12, 0x57, 0x0a, 0x0e, 0x73, 0x34, 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, + 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x18, 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x2f, 0x2e, 0x66, 0x75, + 0x6e, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x5f, 0x74, + 0x79, 0x70, 0x65, 0x73, 0x2e, 0x53, 0x34, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x69, 0x6e, 0x67, + 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52, 0x0e, 0x73, 0x34, + 0x50, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x3c, 0x0a, 0x19, + 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x61, + 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, 0x0d, 0x52, + 0x19, 0x6d, 0x61, 0x78, 0x52, 0x65, 0x70, 0x6f, 0x72, 0x74, 0x54, 0x6f, 0x74, 0x61, 0x6c, 0x43, + 0x61, 0x6c, 0x6c, 0x62, 0x61, 0x63, 0x6b, 0x47, 0x61, 0x73, 0x2a, 0x41, 0x0a, 0x11, 0x41, 0x67, + 0x67, 0x72, 0x65, 0x67, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x4d, 0x65, 0x74, 0x68, 0x6f, 0x64, 0x12, + 0x14, 0x0a, 0x10, 0x41, 0x47, 0x47, 0x52, 0x45, 0x47, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4d, + 0x4f, 0x44, 0x45, 0x10, 0x00, 0x12, 0x16, 0x0a, 0x12, 0x41, 0x47, 0x47, 0x52, 0x45, 0x47, 0x41, + 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x4d, 0x45, 0x44, 0x49, 0x41, 0x4e, 0x10, 0x01, 0x42, 0x2d, 0x5a, + 0x2b, 0x63, 0x6f, 0x72, 0x65, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x73, 0x2f, 0x6f, + 0x63, 0x72, 0x32, 0x2f, 0x70, 0x6c, 0x75, 0x67, 0x69, 0x6e, 0x73, 0x2f, 0x66, 0x75, 0x6e, 0x63, + 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x2f, 0x63, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, } var ( diff --git a/core/services/ocr2/plugins/functions/config/config_types.proto b/core/services/ocr2/plugins/functions/config/config_types.proto index 095a9c3ce62..c0e58e45384 100644 --- a/core/services/ocr2/plugins/functions/config/config_types.proto +++ b/core/services/ocr2/plugins/functions/config/config_types.proto @@ -11,6 +11,7 @@ enum AggregationMethod { AGGREGATION_MEDIAN = 1; } +// Has to match the corresponding proto in tdh2. message ThresholdReportingPluginConfig { uint32 max_query_length_bytes = 1; uint32 max_observation_length_bytes = 2; @@ -18,6 +19,7 @@ message ThresholdReportingPluginConfig { uint32 request_count_limit = 4; uint32 request_total_bytes_limit = 5; bool require_local_request_check = 6; + uint32 k = 7; // Number of decryption shares required for assembling plaintext. } message S4ReportingPluginConfig { diff --git a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go index 1f943dcbf48..011e67c77ca 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v0/functions_integration_test.go @@ -69,6 +69,7 @@ func TestIntegration_Functions_MultipleRequests_ThresholdDecryptionSuccess(t *te RequestCountLimit: 50, RequestTotalBytesLimit: 50_000, RequireLocalRequestCheck: true, + K: 2, }, } diff --git a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go index 522f38e5421..944bafadf75 100644 --- a/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go +++ b/core/services/ocr2/plugins/functions/integration_tests/v1/functions_integration_test.go @@ -72,6 +72,7 @@ func TestIntegration_Functions_MultipleV1Requests_ThresholdDecryptionSuccess(t * RequestCountLimit: 50, RequestTotalBytesLimit: 50_000, RequireLocalRequestCheck: true, + K: 2, }, } diff --git a/core/services/ocr2/plugins/threshold/decryption_queue.go b/core/services/ocr2/plugins/threshold/decryption_queue.go index 4db6dff9c4b..b051e94dfe8 100644 --- a/core/services/ocr2/plugins/threshold/decryption_queue.go +++ b/core/services/ocr2/plugins/threshold/decryption_queue.go @@ -105,7 +105,7 @@ func (dq *decryptionQueue) getResult(ciphertextId decryptionPlugin.CiphertextId, req, ok := dq.completedRequests[string(ciphertextId)] if ok { - dq.lggr.Debugf("ciphertextId %s was already decrypted by the DON", string(ciphertextId)) + dq.lggr.Debugf("ciphertextId %s was already decrypted by the DON", ciphertextId) chPlaintext <- req.plaintext req.timer.Stop() delete(dq.completedRequests, string(ciphertextId)) @@ -126,7 +126,7 @@ func (dq *decryptionQueue) getResult(ciphertextId decryptionPlugin.CiphertextId, chPlaintext, ciphertext, } - dq.lggr.Debugf("ciphertextId %s added to pendingRequestQueue", string(ciphertextId)) + dq.lggr.Debugf("ciphertextId %s added to pendingRequestQueue", ciphertextId) return chPlaintext, nil } @@ -144,21 +144,21 @@ func (dq *decryptionQueue) GetRequests(requestCountLimit int, totalBytesLimit in break } - requestId := dq.pendingRequestQueue[i] - pendingRequest, exists := dq.pendingRequests[string(requestId)] + ciphertextId := dq.pendingRequestQueue[i] + pendingRequest, exists := dq.pendingRequests[string(ciphertextId)] if !exists { - dq.lggr.Debugf("pending decryption request for ciphertextId %s expired", string(requestId)) + dq.lggr.Debugf("pending decryption request for ciphertextId %s expired", ciphertextId) indicesToRemove[i] = struct{}{} continue } requestToAdd := decryptionPlugin.DecryptionRequest{ - CiphertextId: requestId, + CiphertextId: ciphertextId, Ciphertext: pendingRequest.ciphertext, } - requestTotalLen := len(requestId) + len(pendingRequest.ciphertext) + requestTotalLen := len(ciphertextId) + len(pendingRequest.ciphertext) if (totalBytes + requestTotalLen) > totalBytesLimit { dq.lggr.Debug("totalBytesLimit reached in GetRequests") @@ -194,7 +194,7 @@ func (dq *decryptionQueue) GetCiphertext(ciphertextId decryptionPlugin.Ciphertex req, ok := dq.pendingRequests[string(ciphertextId)] if !ok { - return nil, errors.New("ciphertext not found") + return nil, fmt.Errorf("ciphertextID %s not found", ciphertextId) } return req.ciphertext, nil @@ -205,16 +205,16 @@ func (dq *decryptionQueue) SetResult(ciphertextId decryptionPlugin.CiphertextId, defer dq.mu.Unlock() if err == nil && plaintext == nil { - dq.lggr.Errorf("received nil error and nil plaintext for ciphertextId %s", string(ciphertextId)) + dq.lggr.Errorf("received nil error and nil plaintext for ciphertextId %s", ciphertextId) return } req, ok := dq.pendingRequests[string(ciphertextId)] if ok { if err != nil { - dq.lggr.Debugf("decryption error for ciphertextId %s", string(ciphertextId)) + dq.lggr.Debugf("decryption error for ciphertextId %s", ciphertextId) } else { - dq.lggr.Debugf("responding with result for pending decryption request ciphertextId %s", string(ciphertextId)) + dq.lggr.Debugf("responding with result for pending decryption request ciphertextId %s", ciphertextId) req.chPlaintext <- plaintext } close(req.chPlaintext) @@ -222,19 +222,19 @@ func (dq *decryptionQueue) SetResult(ciphertextId decryptionPlugin.CiphertextId, } else { if err != nil { // This is currently possible only for ErrAggregation, encountered during Report() phase. - dq.lggr.Debugf("received decryption error for ciphertextId %s which doesn't exist locally", string(ciphertextId)) + dq.lggr.Debugf("received decryption error for ciphertextId %s which doesn't exist locally", ciphertextId) return } // Cache plaintext result in completedRequests map for cacheTimeoutMs to account for delayed Decrypt() calls timer := time.AfterFunc(dq.completedRequestsCacheTimeout, func() { - dq.lggr.Debugf("expired decryption result for ciphertextId %s from completedRequests cache", string(ciphertextId)) + dq.lggr.Debugf("expired decryption result for ciphertextId %s from completedRequests cache", ciphertextId) dq.mu.Lock() delete(dq.completedRequests, string(ciphertextId)) dq.mu.Unlock() }) - dq.lggr.Debugf("adding decryption result for ciphertextId %s to completedRequests cache", string(ciphertextId)) + dq.lggr.Debugf("adding decryption result for ciphertextId %s to completedRequests cache", ciphertextId) dq.completedRequests[string(ciphertextId)] = completedRequest{ plaintext, timer, diff --git a/core/services/ocr2/plugins/threshold/decryption_queue_test.go b/core/services/ocr2/plugins/threshold/decryption_queue_test.go index 84fa0f918fa..dbe6e779ea6 100644 --- a/core/services/ocr2/plugins/threshold/decryption_queue_test.go +++ b/core/services/ocr2/plugins/threshold/decryption_queue_test.go @@ -199,8 +199,8 @@ func Test_decryptionQueue_GetCiphertext_CiphertextNotFound(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(3, 1000, 64, testutils.WaitTimeout(t), lggr) - _, err := dq.GetCiphertext([]byte("8")) - assert.Equal(t, err.Error(), "ciphertext not found") + _, err := dq.GetCiphertext([]byte{0xa5}) + assert.Equal(t, err.Error(), "ciphertextID 0xa5 not found") } func Test_decryptionQueue_Decrypt_DecryptCalledAfterReadyResult(t *testing.T) { @@ -256,7 +256,7 @@ func Test_decryptionQueue_Decrypt_CleanupSuccessfulRequest(t *testing.T) { func Test_decryptionQueue_Decrypt_UserErrorDuringDecryption(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(5, 1000, 64, testutils.WaitTimeout(t), lggr) - ciphertextId := []byte("1") + ciphertextId := []byte{0x12, 0x0f} go func() { waitForPendingRequestToBeAdded(t, dq, ciphertextId) @@ -267,23 +267,24 @@ func Test_decryptionQueue_Decrypt_UserErrorDuringDecryption(t *testing.T) { defer cancel() _, err := dq.Decrypt(ctx, ciphertextId, []byte("encrypted")) - assert.Equal(t, err.Error(), "pending decryption request for ciphertextId 1 was closed without a response") + assert.Equal(t, err.Error(), "pending decryption request for ciphertextId 0x120f was closed without a response") } func Test_decryptionQueue_Decrypt_HandleClosedChannelWithoutPlaintextResponse(t *testing.T) { lggr := logger.TestLogger(t) dq := NewDecryptionQueue(5, 1000, 64, testutils.WaitTimeout(t), lggr) + ciphertextId := []byte{0x00, 0xff} go func() { - waitForPendingRequestToBeAdded(t, dq, []byte("1")) - close(dq.pendingRequests[string([]byte("1"))].chPlaintext) + waitForPendingRequestToBeAdded(t, dq, ciphertextId) + close(dq.pendingRequests[string(ciphertextId)].chPlaintext) }() ctx, cancel := context.WithCancel(testutils.Context(t)) defer cancel() - _, err := dq.Decrypt(ctx, []byte("1"), []byte("encrypted")) - assert.Equal(t, err.Error(), "pending decryption request for ciphertextId 1 was closed without a response") + _, err := dq.Decrypt(ctx, ciphertextId, []byte("encrypted")) + assert.Equal(t, err.Error(), "pending decryption request for ciphertextId 0x00ff was closed without a response") } func Test_decryptionQueue_GetRequests_RequestsCountLimit(t *testing.T) { diff --git a/core/services/ocr2/plugins/threshold/mocks/decryptor.go b/core/services/ocr2/plugins/threshold/mocks/decryptor.go index 1b4520a63d1..7b899262904 100644 --- a/core/services/ocr2/plugins/threshold/mocks/decryptor.go +++ b/core/services/ocr2/plugins/threshold/mocks/decryptor.go @@ -5,6 +5,7 @@ package mocks import ( context "context" + decryptionplugin "github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin" mock "github.com/stretchr/testify/mock" ) @@ -14,15 +15,15 @@ type Decryptor struct { } // Decrypt provides a mock function with given fields: ctx, ciphertextId, ciphertext -func (_m *Decryptor) Decrypt(ctx context.Context, ciphertextId []byte, ciphertext []byte) ([]byte, error) { +func (_m *Decryptor) Decrypt(ctx context.Context, ciphertextId decryptionplugin.CiphertextId, ciphertext []byte) ([]byte, error) { ret := _m.Called(ctx, ciphertextId, ciphertext) var r0 []byte var r1 error - if rf, ok := ret.Get(0).(func(context.Context, []byte, []byte) ([]byte, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, decryptionplugin.CiphertextId, []byte) ([]byte, error)); ok { return rf(ctx, ciphertextId, ciphertext) } - if rf, ok := ret.Get(0).(func(context.Context, []byte, []byte) []byte); ok { + if rf, ok := ret.Get(0).(func(context.Context, decryptionplugin.CiphertextId, []byte) []byte); ok { r0 = rf(ctx, ciphertextId, ciphertext) } else { if ret.Get(0) != nil { @@ -30,7 +31,7 @@ func (_m *Decryptor) Decrypt(ctx context.Context, ciphertextId []byte, ciphertex } } - if rf, ok := ret.Get(1).(func(context.Context, []byte, []byte) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, decryptionplugin.CiphertextId, []byte) error); ok { r1 = rf(ctx, ciphertextId, ciphertext) } else { r1 = ret.Error(1) diff --git a/go.mod b/go.mod index ca94d21b1f8..aad1a92b884 100644 --- a/go.mod +++ b/go.mod @@ -73,8 +73,8 @@ require ( github.com/smartcontractkit/ocr2keepers v0.7.16 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb - github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 - github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb github.com/smartcontractkit/wsrpc v0.7.2 github.com/spf13/cast v1.5.1 github.com/stretchr/testify v1.8.4 diff --git a/go.sum b/go.sum index a8abfa7a75a..cf38be23ecc 100644 --- a/go.sum +++ b/go.sum @@ -1389,10 +1389,10 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SO github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 h1:AQsTWhkwF/a9Dbv2Y4U4Xi5Go1sflttB0rHL6+8TD6c= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb h1:xNLGJcARfz9HCUKla6wH0gmwsG1/FTAWWeOplW2J72A= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb h1:jyhgdafuZsex+kEHDIgq8o8wuVoPTr9wsGmuBtcFbEk= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= github.com/smartcontractkit/wsrpc v0.7.2/go.mod h1:sj7QX2NQibhkhxTfs3KOhAj/5xwgqMipTvJVSssT9i0= github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index d394e36bc0a..6674155de13 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -385,8 +385,8 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect - github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 // indirect - github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 // indirect + github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb // indirect + github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb // indirect github.com/smartcontractkit/wsrpc v0.7.2 // indirect github.com/spacemonkeygo/spacelog v0.0.0-20180420211403-2296661a0572 // indirect github.com/spaolacci/murmur3 v1.1.0 // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index ac9d7d94384..de6fa60ca3a 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2261,10 +2261,10 @@ github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SO github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb/go.mod h1:HNUu4cJekUdsJbwRBCiOybtkPJEfGRELQPe2tkoDEyk= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27 h1:AQsTWhkwF/a9Dbv2Y4U4Xi5Go1sflttB0rHL6+8TD6c= -github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230808152300-d34f9201db27/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27 h1:azEVb1iB0gClMoakc3DMlWXM6j/hgzH2gWUCB8H16VA= -github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230808152300-d34f9201db27/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb h1:xNLGJcARfz9HCUKla6wH0gmwsG1/FTAWWeOplW2J72A= +github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb/go.mod h1:q6f4fe39oZPdsh1i57WznEZgxd8siidMaSFq3wdPmVg= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb h1:jyhgdafuZsex+kEHDIgq8o8wuVoPTr9wsGmuBtcFbEk= +github.com/smartcontractkit/tdh2/go/tdh2 v0.0.0-20230823081604-f2a0e6b108bb/go.mod h1:G5Sd/yzHWf26rQ+X0nG9E0buKPqRGPMJAfk2gwCzOOw= github.com/smartcontractkit/wasp v0.3.0 h1:mueeLvpb6HyGNwILxCOKShDR6q18plQn7Gb1j3G/Qkk= github.com/smartcontractkit/wasp v0.3.0/go.mod h1:skquNdMbKxIrHi5O8Kyukf66AaaXuEpEEaSTxfHbhak= github.com/smartcontractkit/wsrpc v0.7.2 h1:iBXzMeg7vc5YoezIQBq896y25BARw7OKbhrb6vPbtRQ= From d8b38212ffd778f83b8983dd2dbcd660bfc00b20 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Wed, 23 Aug 2023 10:58:49 -0400 Subject: [PATCH 245/270] [TT-502] Soak Tests Go Wild on Failure (#10304) * Debugging * Debugging * Remove early exit * Uses exit code 2 * Return debug * Test interruption * Finish debug --- integration-tests/.tool-versions | 2 +- integration-tests/scripts/entrypoint | 10 +++++++++- integration-tests/testsetups/ocr.go | 3 ++- 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/integration-tests/.tool-versions b/integration-tests/.tool-versions index cc7693190ea..563ef48e9a6 100644 --- a/integration-tests/.tool-versions +++ b/integration-tests/.tool-versions @@ -1,4 +1,4 @@ -golang 1.20.6 +golang 1.21.0 k3d 5.4.6 kubectl 1.25.5 nodejs 18.13.0 diff --git a/integration-tests/scripts/entrypoint b/integration-tests/scripts/entrypoint index 858a3d83b8d..3955023685d 100755 --- a/integration-tests/scripts/entrypoint +++ b/integration-tests/scripts/entrypoint @@ -2,7 +2,7 @@ # Runs tests for a specific product -set -ex +set -x # get this scripts directory SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &>/dev/null && pwd) @@ -17,6 +17,14 @@ cd "$SCRIPT_DIR"/../ || exit 1 # run the tests ./${SUITE}.test -test.v -test.count 1 ${ARGS} -test.run ^${TEST_NAME}$ +exit_code=$? + +echo "Test exit code: ${exit_code}" + +if [ $exit_code -eq 2 ]; then # 2 is the code for an interrupted test, we only want to restart the test when the test is interrupted + exit 1 # Exiting with non-zero status to trigger pod restart +fi + # Sleep for the amount of time provided by the POST_RUN_SLEEP env var upload_to_slack() { curl -F file=@$1 -F "initial_comment=$2" -F channels=${SLACK_CHANNEL} -H "Authorization: Bearer ${SLACK_API_KEY}" https://slack.com/api/files.upload diff --git a/integration-tests/testsetups/ocr.go b/integration-tests/testsetups/ocr.go index 679c23b3060..88f52fa16f3 100644 --- a/integration-tests/testsetups/ocr.go +++ b/integration-tests/testsetups/ocr.go @@ -183,6 +183,7 @@ func (o *OCRSoakTest) Setup() { err error network = networks.SelectedNetwork ) + // Environment currently being used to soak test on // Make connections to soak test resources o.chainClient, err = blockchain.NewEVMClient(network, o.testEnvironment) @@ -479,7 +480,7 @@ func (o *OCRSoakTest) testLoop(testDuration time.Duration, newValue int) { o.log.Error().Err(err).Msg("Error saving state") } log.Warn().Str("Time Taken", time.Since(saveStart).String()).Msg("Saved state") - os.Exit(1) + os.Exit(2) // Exit with code 2 to indicate test was interrupted, not just a normal failure case <-endTest: return case <-newRoundTrigger.C: From 1ead9ee6f6bb36137f8a49a68b11aa986b538772 Mon Sep 17 00:00:00 2001 From: "Essam A. Hassan" Date: Wed, 23 Aug 2023 19:13:54 +0200 Subject: [PATCH 246/270] Extract types and decode into light weight libs (#10311) --- core/services/ocr2/delegate.go | 5 +- .../ocr2/plugins/mercury/config/config.go | 9 ++- core/services/ocr2/plugins/mercury/plugin.go | 3 +- .../relay/evm/mercury/config_poller.go | 4 +- .../relay/evm/mercury/helpers_test.go | 5 +- .../evm/mercury/offchain_config_digester.go | 4 +- core/services/relay/evm/mercury/orm.go | 4 +- .../services/relay/evm/mercury/transmitter.go | 4 +- .../services/relay/evm/mercury/types/types.go | 30 ---------- .../services/relay/evm/mercury/utils/feeds.go | 35 ++++++++++++ .../types_test.go => utils/feeds_test.go} | 2 +- .../mercury/v1/reportcodec/report_codec.go | 56 ++----------------- .../relay/evm/mercury/v1/types/types.go | 55 ++++++++++++++++++ .../relay/evm/mercury/v2/data_source.go | 10 ++-- .../relay/evm/mercury/v2/data_source_test.go | 10 ++-- .../mercury/v2/reportcodec/report_codec.go | 51 ++--------------- .../relay/evm/mercury/v2/types/types.go | 51 +++++++++++++++++ .../relay/evm/mercury/v3/data_source.go | 10 ++-- .../relay/evm/mercury/v3/data_source_test.go | 10 ++-- .../mercury/v3/reportcodec/report_codec.go | 46 ++------------- .../relay/evm/mercury/v3/types/types.go | 55 ++++++++++++++++++ 21 files changed, 255 insertions(+), 204 deletions(-) create mode 100644 core/services/relay/evm/mercury/utils/feeds.go rename core/services/relay/evm/mercury/{types/types_test.go => utils/feeds_test.go} (98%) create mode 100644 core/services/relay/evm/mercury/v1/types/types.go create mode 100644 core/services/relay/evm/mercury/v2/types/types.go create mode 100644 core/services/relay/evm/mercury/v3/types/types.go diff --git a/core/services/ocr2/delegate.go b/core/services/ocr2/delegate.go index 5483b4c8b80..39d5e939f3b 100644 --- a/core/services/ocr2/delegate.go +++ b/core/services/ocr2/delegate.go @@ -62,7 +62,8 @@ import ( evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" functionsRelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/functions" evmmercury "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury" - evmmercurytypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + mercuryutils "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" + evmrelaytypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/types" "github.com/smartcontractkit/chainlink/v2/core/services/synchronization" "github.com/smartcontractkit/chainlink/v2/core/services/telemetry" @@ -545,7 +546,7 @@ func (d *Delegate) newServicesMercury( chEnhancedTelem := make(chan ocrcommon.EnhancedTelemetryMercuryData, 100) - mercuryServices, err2 := mercury.NewServices(jb, mercuryProvider, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, d.cfg.JobPipeline(), chEnhancedTelem, chain, d.mercuryORM, (evmmercurytypes.FeedID)(*spec.FeedID)) + mercuryServices, err2 := mercury.NewServices(jb, mercuryProvider, d.pipelineRunner, runResults, lggr, oracleArgsNoPlugin, d.cfg.JobPipeline(), chEnhancedTelem, chain, d.mercuryORM, (mercuryutils.FeedID)(*spec.FeedID)) if ocrcommon.ShouldCollectEnhancedTelemetryMercury(&jb) { enhancedTelemService := ocrcommon.NewEnhancedTelemetryService(&jb, chEnhancedTelem, make(chan struct{}), d.monitoringEndpointGen.GenMonitoringEndpoint(spec.FeedID.String(), synchronization.EnhancedEAMercury), lggr.Named("Enhanced Telemetry Mercury")) diff --git a/core/services/ocr2/plugins/mercury/config/config.go b/core/services/ocr2/plugins/mercury/config/config.go index 944140d99a8..fc5d0a6a20d 100644 --- a/core/services/ocr2/plugins/mercury/config/config.go +++ b/core/services/ocr2/plugins/mercury/config/config.go @@ -12,9 +12,8 @@ import ( pkgerrors "github.com/pkg/errors" "github.com/smartcontractkit/chainlink/v2/core/null" + mercuryutils "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" "github.com/smartcontractkit/chainlink/v2/core/utils" - - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" ) type PluginConfig struct { @@ -26,11 +25,11 @@ type PluginConfig struct { // effectively sets the "first" validFromBlockNumber. InitialBlockNumber null.Int64 `json:"initialBlockNumber" toml:"initialBlockNumber"` - LinkFeedID *types.FeedID `json:"linkFeedID" toml:"linkFeedID"` - NativeFeedID *types.FeedID `json:"nativeFeedID" toml:"nativeFeedID"` + LinkFeedID *mercuryutils.FeedID `json:"linkFeedID" toml:"linkFeedID"` + NativeFeedID *mercuryutils.FeedID `json:"nativeFeedID" toml:"nativeFeedID"` } -func ValidatePluginConfig(config PluginConfig, feedID types.FeedID) (merr error) { +func ValidatePluginConfig(config PluginConfig, feedID mercuryutils.FeedID) (merr error) { if config.RawServerURL == "" { merr = errors.New("mercury: ServerURL must be specified") } else { diff --git a/core/services/ocr2/plugins/mercury/plugin.go b/core/services/ocr2/plugins/mercury/plugin.go index c38096845ea..557c83fd11e 100644 --- a/core/services/ocr2/plugins/mercury/plugin.go +++ b/core/services/ocr2/plugins/mercury/plugin.go @@ -18,6 +18,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" mercuryv1 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1" mercuryv2 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2" mercuryv3 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3" @@ -38,7 +39,7 @@ func NewServices( chEnhancedTelem chan ocrcommon.EnhancedTelemetryMercuryData, chainHeadTracker types.ChainHeadTracker, orm types.DataSourceORM, - feedID types.FeedID, + feedID utils.FeedID, ) ([]job.ServiceCtx, error) { if jb.PipelineSpec == nil { return nil, errors.New("expected job to have a non-nil PipelineSpec") diff --git a/core/services/relay/evm/mercury/config_poller.go b/core/services/relay/evm/mercury/config_poller.go index 3a17150a5a9..2f16157bfac 100644 --- a/core/services/relay/evm/mercury/config_poller.go +++ b/core/services/relay/evm/mercury/config_poller.go @@ -15,7 +15,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" ) // FeedScopedConfigSet ConfigSet with FeedID for use with mercury (and multi-config DON) @@ -40,7 +40,7 @@ func init() { // FullConfigFromLog defines the contract config with the feedID type FullConfigFromLog struct { ocrtypes.ContractConfig - feedID types.FeedID + feedID utils.FeedID } func unpackLogData(d []byte) (*verifier.VerifierConfigSet, error) { diff --git a/core/services/relay/evm/mercury/helpers_test.go b/core/services/relay/evm/mercury/helpers_test.go index 54da5b42588..4a7b8f70d75 100644 --- a/core/services/relay/evm/mercury/helpers_test.go +++ b/core/services/relay/evm/mercury/helpers_test.go @@ -14,6 +14,9 @@ import ( "github.com/ethereum/go-ethereum/eth/ethconfig" "github.com/stretchr/testify/require" + "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" + ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" + evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/llo-feeds/generated/verifier" @@ -26,8 +29,6 @@ import ( reportcodecv2 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2/reportcodec" reportcodecv3 "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3/reportcodec" "github.com/smartcontractkit/chainlink/v2/core/utils" - "github.com/smartcontractkit/libocr/offchainreporting2plus/chains/evmutil" - ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" ) var ( diff --git a/core/services/relay/evm/mercury/offchain_config_digester.go b/core/services/relay/evm/mercury/offchain_config_digester.go index 0dbf7cbbfd6..a12198738a9 100644 --- a/core/services/relay/evm/mercury/offchain_config_digester.go +++ b/core/services/relay/evm/mercury/offchain_config_digester.go @@ -10,7 +10,7 @@ import ( ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" "github.com/smartcontractkit/wsrpc/credentials" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" ) // Originally sourced from: https://github.com/smartcontractkit/offchain-reporting/blob/991ebe1462fd56826a1ddfb34287d542acb2baee/lib/offchainreporting2/chains/evmutil/offchain_config_digester.go @@ -22,7 +22,7 @@ func NewOffchainConfigDigester(feedID [32]byte, chainID *big.Int, contractAddres } type OffchainConfigDigester struct { - FeedID types.FeedID + FeedID utils.FeedID ChainID *big.Int ContractAddress common.Address } diff --git a/core/services/relay/evm/mercury/orm.go b/core/services/relay/evm/mercury/orm.go index 36433f24e2b..49a5f250e14 100644 --- a/core/services/relay/evm/mercury/orm.go +++ b/core/services/relay/evm/mercury/orm.go @@ -16,7 +16,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" ) @@ -28,7 +28,7 @@ type ORM interface { LatestReport(ctx context.Context, feedID [32]byte, qopts ...pg.QOpt) (report []byte, err error) } -func FeedIDFromReport(report ocrtypes.Report) (feedID types.FeedID, err error) { +func FeedIDFromReport(report ocrtypes.Report) (feedID utils.FeedID, err error) { if n := copy(feedID[:], report); n != 32 { return feedID, pkgerrors.Errorf("invalid length for report: %d", len(report)) } diff --git a/core/services/relay/evm/mercury/transmitter.go b/core/services/relay/evm/mercury/transmitter.go index e70e6fd1db5..228c5dd7044 100644 --- a/core/services/relay/evm/mercury/transmitter.go +++ b/core/services/relay/evm/mercury/transmitter.go @@ -22,12 +22,12 @@ import ( "github.com/smartcontractkit/sqlx" relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" + mercuryutils "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services" "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc" "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/wsrpc/pb" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -88,7 +88,7 @@ type mercuryTransmitter struct { cfgTracker ConfigTracker persistenceManager *PersistenceManager - feedID types.FeedID + feedID mercuryutils.FeedID fromAccount string stopCh utils.StopChan diff --git a/core/services/relay/evm/mercury/types/types.go b/core/services/relay/evm/mercury/types/types.go index 8102a34e4ee..6affba58169 100644 --- a/core/services/relay/evm/mercury/types/types.go +++ b/core/services/relay/evm/mercury/types/types.go @@ -2,42 +2,12 @@ package types import ( "context" - "encoding/binary" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" httypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/headtracker/types" "github.com/smartcontractkit/chainlink/v2/core/services/pg" - "github.com/smartcontractkit/chainlink/v2/core/utils" ) -type FeedIDPrefix uint16 - -const ( - _ FeedIDPrefix = 0 // reserved to prevent errors where a zero-default creeps through somewhere - REPORT_V1 FeedIDPrefix = 1 - REPORT_V2 FeedIDPrefix = 2 - REPORT_V3 FeedIDPrefix = 3 - _ FeedIDPrefix = 0xFFFF // reserved for future use -) - -type FeedID [32]byte - -func (f FeedID) Hex() string { return (utils.Hash)(f).Hex() } - -func (f FeedID) String() string { return (utils.Hash)(f).String() } - -func (f *FeedID) UnmarshalText(input []byte) error { - return (*utils.Hash)(f).UnmarshalText(input) -} - -func (f FeedID) Version() FeedIDPrefix { - return FeedIDPrefix(binary.BigEndian.Uint16(f[:2])) -} - -func (f FeedID) IsV1() bool { return f.Version() == REPORT_V1 } -func (f FeedID) IsV2() bool { return f.Version() == REPORT_V2 } -func (f FeedID) IsV3() bool { return f.Version() == REPORT_V3 } - //go:generate mockery --quiet --name ChainHeadTracker --output ../mocks/ --case=underscore type ChainHeadTracker interface { Client() evmclient.Client diff --git a/core/services/relay/evm/mercury/utils/feeds.go b/core/services/relay/evm/mercury/utils/feeds.go new file mode 100644 index 00000000000..d2fd2106e98 --- /dev/null +++ b/core/services/relay/evm/mercury/utils/feeds.go @@ -0,0 +1,35 @@ +package utils + +import ( + "encoding/binary" + + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +type FeedVersion uint16 + +const ( + _ FeedVersion = iota + REPORT_V1 + REPORT_V2 + REPORT_V3 + _ +) + +type FeedID [32]byte + +func (f FeedID) Hex() string { return (utils.Hash)(f).Hex() } + +func (f FeedID) String() string { return (utils.Hash)(f).String() } + +func (f *FeedID) UnmarshalText(input []byte) error { + return (*utils.Hash)(f).UnmarshalText(input) +} + +func (f FeedID) Version() FeedVersion { + return FeedVersion(binary.BigEndian.Uint16(f[:2])) +} + +func (f FeedID) IsV1() bool { return f.Version() == REPORT_V1 } +func (f FeedID) IsV2() bool { return f.Version() == REPORT_V2 } +func (f FeedID) IsV3() bool { return f.Version() == REPORT_V3 } diff --git a/core/services/relay/evm/mercury/types/types_test.go b/core/services/relay/evm/mercury/utils/feeds_test.go similarity index 98% rename from core/services/relay/evm/mercury/types/types_test.go rename to core/services/relay/evm/mercury/utils/feeds_test.go index 3a18d6368ce..dddd125a602 100644 --- a/core/services/relay/evm/mercury/types/types_test.go +++ b/core/services/relay/evm/mercury/utils/feeds_test.go @@ -1,4 +1,4 @@ -package types +package utils import ( "testing" diff --git a/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go index 24f7ee385be..12307bb3e12 100644 --- a/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go @@ -1,11 +1,8 @@ package reportcodec import ( - "fmt" "math" - "math/big" - "github.com/ethereum/go-ethereum/accounts/abi" "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" @@ -13,55 +10,22 @@ import ( reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" + reporttypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v1/types" ) // NOTE: // This report codec is based on the original median evmreportcodec // here: // https://github.com/smartcontractkit/offchain-reporting/blob/master/lib/offchainreporting2/reportingplugin/median/evmreportcodec/reportcodec.go - -var ReportTypes = getReportTypes() +var ReportTypes = reporttypes.GetSchema() var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word -func getReportTypes() abi.Arguments { - mustNewType := func(t string) abi.Type { - result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) - if err != nil { - panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) - } - return result - } - return abi.Arguments([]abi.Argument{ - {Name: "feedId", Type: mustNewType("bytes32")}, - {Name: "observationsTimestamp", Type: mustNewType("uint32")}, - {Name: "benchmarkPrice", Type: mustNewType("int192")}, - {Name: "bid", Type: mustNewType("int192")}, - {Name: "ask", Type: mustNewType("int192")}, - {Name: "currentBlockNum", Type: mustNewType("uint64")}, - {Name: "currentBlockHash", Type: mustNewType("bytes32")}, - {Name: "validFromBlockNum", Type: mustNewType("uint64")}, - {Name: "currentBlockTimestamp", Type: mustNewType("uint64")}, - }) -} - -type Report struct { - FeedId [32]byte - ObservationsTimestamp uint32 - BenchmarkPrice *big.Int - Bid *big.Int - Ask *big.Int - CurrentBlockNum uint64 - CurrentBlockHash [32]byte - ValidFromBlockNum uint64 - CurrentBlockTimestamp uint64 -} - var _ reportcodec.ReportCodec = &ReportCodec{} type ReportCodec struct { logger logger.Logger - feedID types.FeedID + feedID utils.FeedID } func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { @@ -161,14 +125,6 @@ func (r *ReportCodec) ValidFromBlockNumFromReport(report ocrtypes.Report) (int64 } // Decode is made available to external users (i.e. mercury server) -func (r *ReportCodec) Decode(report ocrtypes.Report) (*Report, error) { - values, err := ReportTypes.Unpack(report) - if err != nil { - return nil, fmt.Errorf("failed to decode report: %w", err) - } - decoded := new(Report) - if err = ReportTypes.Copy(decoded, values); err != nil { - return nil, fmt.Errorf("failed to copy report values to struct: %w", err) - } - return decoded, nil +func (r *ReportCodec) Decode(report ocrtypes.Report) (*reporttypes.Report, error) { + return reporttypes.Decode(report) } diff --git a/core/services/relay/evm/mercury/v1/types/types.go b/core/services/relay/evm/mercury/v1/types/types.go new file mode 100644 index 00000000000..a25b6b8359f --- /dev/null +++ b/core/services/relay/evm/mercury/v1/types/types.go @@ -0,0 +1,55 @@ +package reporttypes + +import ( + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" +) + +var schema = GetSchema() + +func GetSchema() abi.Arguments { + mustNewType := func(t string) abi.Type { + result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) + if err != nil { + panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) + } + return result + } + return abi.Arguments([]abi.Argument{ + {Name: "feedId", Type: mustNewType("bytes32")}, + {Name: "observationsTimestamp", Type: mustNewType("uint32")}, + {Name: "benchmarkPrice", Type: mustNewType("int192")}, + {Name: "bid", Type: mustNewType("int192")}, + {Name: "ask", Type: mustNewType("int192")}, + {Name: "currentBlockNum", Type: mustNewType("uint64")}, + {Name: "currentBlockHash", Type: mustNewType("bytes32")}, + {Name: "validFromBlockNum", Type: mustNewType("uint64")}, + {Name: "currentBlockTimestamp", Type: mustNewType("uint64")}, + }) +} + +type Report struct { + FeedId [32]byte + ObservationsTimestamp uint32 + BenchmarkPrice *big.Int + Bid *big.Int + Ask *big.Int + CurrentBlockNum uint64 + CurrentBlockHash [32]byte + ValidFromBlockNum uint64 + CurrentBlockTimestamp uint64 +} + +func Decode(report []byte) (*Report, error) { + values, err := schema.Unpack(report) + if err != nil { + return nil, fmt.Errorf("failed to decode report: %w", err) + } + decoded := new(Report) + if err = schema.Copy(decoded, values); err != nil { + return nil, fmt.Errorf("failed to copy report values to struct: %w", err) + } + return decoded, nil +} diff --git a/core/services/relay/evm/mercury/v2/data_source.go b/core/services/relay/evm/mercury/v2/data_source.go index bbeed56a178..75db51efcb7 100644 --- a/core/services/relay/evm/mercury/v2/data_source.go +++ b/core/services/relay/evm/mercury/v2/data_source.go @@ -17,7 +17,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + mercuryutils "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -34,13 +34,13 @@ type datasource struct { pipelineRunner Runner jb job.Job spec pipeline.Spec - feedID types.FeedID + feedID mercuryutils.FeedID lggr logger.Logger runResults chan<- pipeline.Run fetcher LatestReportFetcher - linkFeedID types.FeedID - nativeFeedID types.FeedID + linkFeedID mercuryutils.FeedID + nativeFeedID mercuryutils.FeedID mu sync.RWMutex @@ -51,7 +51,7 @@ var _ relaymercuryv2.DataSource = &datasource{} var maxInt192 = new(big.Int).Exp(big.NewInt(2), big.NewInt(191), nil) -func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID types.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID types.FeedID) *datasource { +func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID mercuryutils.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID mercuryutils.FeedID) *datasource { return &datasource{pr, jb, spec, feedID, lggr, rr, fetcher, linkFeedID, nativeFeedID, sync.RWMutex{}, enhancedTelemChan} } diff --git a/core/services/relay/evm/mercury/v2/data_source_test.go b/core/services/relay/evm/mercury/v2/data_source_test.go index 98b2c1e6b21..65f4a1e2b44 100644 --- a/core/services/relay/evm/mercury/v2/data_source_test.go +++ b/core/services/relay/evm/mercury/v2/data_source_test.go @@ -16,7 +16,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" ) var _ relaymercury.MercuryServerFetcher = &mockFetcher{} @@ -30,9 +30,9 @@ type mockFetcher struct { nativePriceErr error } -var feedId types.FeedID = [32]byte{1} -var linkFeedId types.FeedID = [32]byte{2} -var nativeFeedId types.FeedID = [32]byte{3} +var feedId utils.FeedID = [32]byte{1} +var linkFeedId utils.FeedID = [32]byte{2} +var nativeFeedId utils.FeedID = [32]byte{3} func (m *mockFetcher) FetchInitialMaxFinalizedBlockNumber(context.Context) (*int64, error) { return nil, nil @@ -183,7 +183,7 @@ func Test_Datasource(t *testing.T) { ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, linkFeedId, nativeFeedId }) - var feedId types.FeedID = [32]byte{1} + var feedId utils.FeedID = [32]byte{1} ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, feedId, feedId obs, err := ds.Observe(ctx, repts, false) diff --git a/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go index ccf9abd6996..42f1c0e34b0 100644 --- a/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go @@ -1,11 +1,8 @@ package reportcodec import ( - "fmt" "math" - "math/big" - "github.com/ethereum/go-ethereum/accounts/abi" "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" @@ -13,46 +10,18 @@ import ( reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" + reporttypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v2/types" ) -var ReportTypes = getReportTypes() +var ReportTypes = reporttypes.GetSchema() var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word -func getReportTypes() abi.Arguments { - mustNewType := func(t string) abi.Type { - result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) - if err != nil { - panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) - } - return result - } - return abi.Arguments([]abi.Argument{ - {Name: "feedId", Type: mustNewType("bytes32")}, - {Name: "validFromTimestamp", Type: mustNewType("uint32")}, - {Name: "observationsTimestamp", Type: mustNewType("uint32")}, - {Name: "nativeFee", Type: mustNewType("int192")}, - {Name: "linkFee", Type: mustNewType("int192")}, - {Name: "expiresAt", Type: mustNewType("uint32")}, - {Name: "benchmarkPrice", Type: mustNewType("int192")}, - }) -} - -type Report struct { - FeedId [32]byte - ObservationsTimestamp uint32 - BenchmarkPrice *big.Int - ValidFromTimestamp uint32 - ExpiresAt uint32 - LinkFee *big.Int - NativeFee *big.Int -} - var _ reportcodec.ReportCodec = &ReportCodec{} type ReportCodec struct { logger logger.Logger - feedID types.FeedID + feedID utils.FeedID } func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { @@ -114,14 +83,6 @@ func (r *ReportCodec) ObservationTimestampFromReport(report ocrtypes.Report) (ui } // Decode is made available to external users (i.e. mercury server) -func (r *ReportCodec) Decode(report ocrtypes.Report) (*Report, error) { - values, err := ReportTypes.Unpack(report) - if err != nil { - return nil, fmt.Errorf("failed to decode report: %w", err) - } - decoded := new(Report) - if err = ReportTypes.Copy(decoded, values); err != nil { - return nil, fmt.Errorf("failed to copy report values to struct: %w", err) - } - return decoded, nil +func (r *ReportCodec) Decode(report ocrtypes.Report) (*reporttypes.Report, error) { + return reporttypes.Decode(report) } diff --git a/core/services/relay/evm/mercury/v2/types/types.go b/core/services/relay/evm/mercury/v2/types/types.go new file mode 100644 index 00000000000..af973d3122f --- /dev/null +++ b/core/services/relay/evm/mercury/v2/types/types.go @@ -0,0 +1,51 @@ +package reporttypes + +import ( + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" +) + +var schema = GetSchema() + +func GetSchema() abi.Arguments { + mustNewType := func(t string) abi.Type { + result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) + if err != nil { + panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) + } + return result + } + return abi.Arguments([]abi.Argument{ + {Name: "feedId", Type: mustNewType("bytes32")}, + {Name: "validFromTimestamp", Type: mustNewType("uint32")}, + {Name: "observationsTimestamp", Type: mustNewType("uint32")}, + {Name: "nativeFee", Type: mustNewType("int192")}, + {Name: "linkFee", Type: mustNewType("int192")}, + {Name: "expiresAt", Type: mustNewType("uint32")}, + {Name: "benchmarkPrice", Type: mustNewType("int192")}, + }) +} + +type Report struct { + FeedId [32]byte + ObservationsTimestamp uint32 + BenchmarkPrice *big.Int + ValidFromTimestamp uint32 + ExpiresAt uint32 + LinkFee *big.Int + NativeFee *big.Int +} + +func Decode(report []byte) (*Report, error) { + values, err := schema.Unpack(report) + if err != nil { + return nil, fmt.Errorf("failed to decode report: %w", err) + } + decoded := new(Report) + if err = schema.Copy(decoded, values); err != nil { + return nil, fmt.Errorf("failed to copy report values to struct: %w", err) + } + return decoded, nil +} diff --git a/core/services/relay/evm/mercury/v3/data_source.go b/core/services/relay/evm/mercury/v3/data_source.go index 5dcd7c2a266..a7bd1c189be 100644 --- a/core/services/relay/evm/mercury/v3/data_source.go +++ b/core/services/relay/evm/mercury/v3/data_source.go @@ -18,7 +18,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/job" "github.com/smartcontractkit/chainlink/v2/core/services/ocrcommon" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + mercuryutils "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" "github.com/smartcontractkit/chainlink/v2/core/utils" ) @@ -35,13 +35,13 @@ type datasource struct { pipelineRunner Runner jb job.Job spec pipeline.Spec - feedID types.FeedID + feedID mercuryutils.FeedID lggr logger.Logger runResults chan<- pipeline.Run fetcher LatestReportFetcher - linkFeedID types.FeedID - nativeFeedID types.FeedID + linkFeedID mercuryutils.FeedID + nativeFeedID mercuryutils.FeedID mu sync.RWMutex @@ -52,7 +52,7 @@ var _ relaymercuryv3.DataSource = &datasource{} var maxInt192 = new(big.Int).Exp(big.NewInt(2), big.NewInt(191), nil) -func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID types.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID types.FeedID) *datasource { +func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID mercuryutils.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID mercuryutils.FeedID) *datasource { return &datasource{pr, jb, spec, feedID, lggr, rr, fetcher, linkFeedID, nativeFeedID, sync.RWMutex{}, enhancedTelemChan} } diff --git a/core/services/relay/evm/mercury/v3/data_source_test.go b/core/services/relay/evm/mercury/v3/data_source_test.go index d6ceba8f841..2db4cb9f4b4 100644 --- a/core/services/relay/evm/mercury/v3/data_source_test.go +++ b/core/services/relay/evm/mercury/v3/data_source_test.go @@ -16,7 +16,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/pipeline" mercurymocks "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/mocks" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" ) var _ relaymercury.MercuryServerFetcher = &mockFetcher{} @@ -30,9 +30,9 @@ type mockFetcher struct { nativePriceErr error } -var feedId types.FeedID = [32]byte{1} -var linkFeedId types.FeedID = [32]byte{2} -var nativeFeedId types.FeedID = [32]byte{3} +var feedId utils.FeedID = [32]byte{1} +var linkFeedId utils.FeedID = [32]byte{2} +var nativeFeedId utils.FeedID = [32]byte{3} func (m *mockFetcher) FetchInitialMaxFinalizedBlockNumber(context.Context) (*int64, error) { return nil, nil @@ -207,7 +207,7 @@ func Test_Datasource(t *testing.T) { ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, linkFeedId, nativeFeedId }) - var feedId types.FeedID = [32]byte{1} + var feedId utils.FeedID = [32]byte{1} ds.feedID, ds.linkFeedID, ds.nativeFeedID = feedId, feedId, feedId obs, err := ds.Observe(ctx, repts, false) diff --git a/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go index 779e6280d0b..0c9cd2e5cfc 100644 --- a/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go @@ -3,9 +3,7 @@ package reportcodec import ( "fmt" "math" - "math/big" - "github.com/ethereum/go-ethereum/accounts/abi" "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" @@ -13,50 +11,18 @@ import ( reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" "github.com/smartcontractkit/chainlink/v2/core/logger" - "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/types" + "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/utils" + reporttypes "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm/mercury/v3/types" ) -var ReportTypes = getReportTypes() +var ReportTypes = reporttypes.GetSchema() var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word -func getReportTypes() abi.Arguments { - mustNewType := func(t string) abi.Type { - result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) - if err != nil { - panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) - } - return result - } - return abi.Arguments([]abi.Argument{ - {Name: "feedId", Type: mustNewType("bytes32")}, - {Name: "validFromTimestamp", Type: mustNewType("uint32")}, - {Name: "observationsTimestamp", Type: mustNewType("uint32")}, - {Name: "nativeFee", Type: mustNewType("int192")}, - {Name: "linkFee", Type: mustNewType("int192")}, - {Name: "expiresAt", Type: mustNewType("uint32")}, - {Name: "benchmarkPrice", Type: mustNewType("int192")}, - {Name: "bid", Type: mustNewType("int192")}, - {Name: "ask", Type: mustNewType("int192")}, - }) -} - -type Report struct { - FeedId [32]byte - ObservationsTimestamp uint32 - BenchmarkPrice *big.Int - Bid *big.Int - Ask *big.Int - ValidFromTimestamp uint32 - ExpiresAt uint32 - LinkFee *big.Int - NativeFee *big.Int -} - var _ reportcodec.ReportCodec = &ReportCodec{} type ReportCodec struct { logger logger.Logger - feedID types.FeedID + feedID utils.FeedID } func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { @@ -126,12 +92,12 @@ func (r *ReportCodec) ObservationTimestampFromReport(report ocrtypes.Report) (ui } // Decode is made available to external users (i.e. mercury server) -func (r *ReportCodec) Decode(report ocrtypes.Report) (*Report, error) { +func (r *ReportCodec) Decode(report ocrtypes.Report) (*reporttypes.Report, error) { values, err := ReportTypes.Unpack(report) if err != nil { return nil, fmt.Errorf("failed to decode report: %w", err) } - decoded := new(Report) + decoded := new(reporttypes.Report) if err = ReportTypes.Copy(decoded, values); err != nil { return nil, fmt.Errorf("failed to copy report values to struct: %w", err) } diff --git a/core/services/relay/evm/mercury/v3/types/types.go b/core/services/relay/evm/mercury/v3/types/types.go new file mode 100644 index 00000000000..630f8a16e69 --- /dev/null +++ b/core/services/relay/evm/mercury/v3/types/types.go @@ -0,0 +1,55 @@ +package reporttypes + +import ( + "fmt" + "math/big" + + "github.com/ethereum/go-ethereum/accounts/abi" +) + +var schema = GetSchema() + +func GetSchema() abi.Arguments { + mustNewType := func(t string) abi.Type { + result, err := abi.NewType(t, "", []abi.ArgumentMarshaling{}) + if err != nil { + panic(fmt.Sprintf("Unexpected error during abi.NewType: %s", err)) + } + return result + } + return abi.Arguments([]abi.Argument{ + {Name: "feedId", Type: mustNewType("bytes32")}, + {Name: "validFromTimestamp", Type: mustNewType("uint32")}, + {Name: "observationsTimestamp", Type: mustNewType("uint32")}, + {Name: "nativeFee", Type: mustNewType("int192")}, + {Name: "linkFee", Type: mustNewType("int192")}, + {Name: "expiresAt", Type: mustNewType("uint32")}, + {Name: "benchmarkPrice", Type: mustNewType("int192")}, + {Name: "bid", Type: mustNewType("int192")}, + {Name: "ask", Type: mustNewType("int192")}, + }) +} + +type Report struct { + FeedId [32]byte + ObservationsTimestamp uint32 + BenchmarkPrice *big.Int + Bid *big.Int + Ask *big.Int + ValidFromTimestamp uint32 + ExpiresAt uint32 + LinkFee *big.Int + NativeFee *big.Int +} + +func Decode(report []byte) (*Report, error) { + values, err := schema.Unpack(report) + if err != nil { + return nil, fmt.Errorf("failed to decode report: %w", err) + } + decoded := new(Report) + if err = schema.Copy(decoded, values); err != nil { + return nil, fmt.Errorf("failed to copy report values to struct: %w", err) + } + return decoded, nil +} From c320b7afb28483d6576b149f73387e8f267a8290 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Wed, 23 Aug 2023 14:01:05 -0400 Subject: [PATCH 247/270] handle invalid revert data for mercury (#10300) --- .../ocr2keeper/evm21/encoding/interface.go | 2 +- .../plugins/ocr2keeper/evm21/feed_lookup.go | 15 ++++++---- .../ocr2keeper/evm21/feed_lookup_test.go | 30 ++++++++++++++++++- 3 files changed, 39 insertions(+), 8 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go index 8601617cf45..3044db4ea11 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go @@ -28,6 +28,7 @@ const ( // upkeep failure offchain reasons UpkeepFailureReasonMercuryAccessNotAllowed UpkeepFailureReason = 32 UpkeepFailureReasonTxHashNoLongerExists UpkeepFailureReason = 33 + UpkeepFailureReasonInvalidRevertDataInput UpkeepFailureReason = 34 // pipeline execution error NoPipelineError PipelineExecutionState = 0 @@ -39,7 +40,6 @@ const ( MercuryUnmarshalError PipelineExecutionState = 6 InvalidMercuryRequest PipelineExecutionState = 7 FailedToDecodeMercuryResponse PipelineExecutionState = 8 - InvalidRevertDataInput PipelineExecutionState = 9 ) type UpkeepInfo = iregistry21.KeeperRegistryBase21UpkeepInfo diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index a27c8ca89d6..500d76954d9 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -145,11 +145,12 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup *FeedLookup, i int, checkResults []ocr2keepers.CheckResult, lggr logger.Logger) { defer wg.Done() - state, values, retryable, err := r.doMercuryRequest(ctx, lookup, lggr) + state, reason, values, retryable, err := r.doMercuryRequest(ctx, lookup, lggr) if err != nil { lggr.Errorf("upkeep %s retryable %v doMercuryRequest: %v", lookup.upkeepId, retryable, err) checkResults[i].Retryable = retryable checkResults[i].PipelineExecutionState = uint8(state) + checkResults[i].IneligibilityReason = uint8(reason) return } for j, v := range values { @@ -250,11 +251,14 @@ func (r *EvmRegistry) checkCallback(ctx context.Context, values [][]byte, lookup return encoding.NoPipelineError, false, b, nil } -// doMercuryRequest sends requests to Mercury API to retrieve ChainlinkBlob. -func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr logger.Logger) (encoding.PipelineExecutionState, [][]byte, bool, error) { +// doMercuryRequest sends requests to Mercury API to retrieve mercury data. +func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr logger.Logger) (encoding.PipelineExecutionState, encoding.UpkeepFailureReason, [][]byte, bool, error) { var isMercuryV03 bool resultLen := len(ml.feeds) ch := make(chan MercuryData, resultLen) + if len(ml.feeds) == 0 { + return encoding.NoPipelineError, encoding.UpkeepFailureReasonInvalidRevertDataInput, [][]byte{}, false, fmt.Errorf("invalid revert data input: feed param key %s, time param key %s, feeds %s", ml.feedParamKey, ml.timeParamKey, ml.feeds) + } if ml.feedParamKey == feedIdHex && ml.timeParamKey == blockNumber { // only mercury v0.2 for i := range ml.feeds { @@ -267,8 +271,7 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr ch = make(chan MercuryData, resultLen) go r.multiFeedsRequest(ctx, ch, ml, lggr) } else { - // TODO: This should result in upkeep ineligible since upkeep gave a wrong mercury input - return encoding.InvalidRevertDataInput, nil, false, fmt.Errorf("invalid label combination: feed param key %s and time param key %s", ml.feedParamKey, ml.timeParamKey) + return encoding.NoPipelineError, encoding.UpkeepFailureReasonInvalidRevertDataInput, [][]byte{}, false, fmt.Errorf("invalid revert data input: feed param key %s, time param key %s, feeds %s", ml.feedParamKey, ml.timeParamKey, ml.feeds) } var reqErr error @@ -296,7 +299,7 @@ func (r *EvmRegistry) doMercuryRequest(ctx context.Context, ml *FeedLookup, lggr } lggr.Debugf("upkeep %s retryable %s reqErr %w", ml.upkeepId.String(), retryable && !allSuccess, reqErr) // only retry when not all successful AND none are not retryable - return state, results, retryable && !allSuccess, reqErr + return state, encoding.UpkeepFailureReasonNone, results, retryable && !allSuccess, reqErr } // singleFeedRequest sends a v0.2 Mercury request for a single feed report. diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index a6e493aa264..9c44c7d5c15 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -350,6 +350,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedRetryable bool expectedError error state encoding.PipelineExecutionState + reason encoding.UpkeepFailureReason }{ { name: "success", @@ -401,6 +402,32 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { expectedError: errors.New("All attempts fail:\n#1: FeedLookup upkeep 88786950015966611018675766524283132478093844178961698330929478019253453382042 block 25880526 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"), state: encoding.InvalidMercuryRequest, }, + { + name: "failure - no feeds", + lookup: &FeedLookup{ + feedParamKey: feedIdHex, + feeds: []string{}, + timeParamKey: blockNumber, + time: big.NewInt(25880526), + extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, + upkeepId: upkeepId, + }, + expectedValues: [][]byte{}, + reason: encoding.UpkeepFailureReasonInvalidRevertDataInput, + }, + { + name: "failure - invalid revert data", + lookup: &FeedLookup{ + feedParamKey: feedIDs, + feeds: []string{}, + timeParamKey: blockNumber, + time: big.NewInt(25880526), + extraData: []byte{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 100}, + upkeepId: upkeepId, + }, + expectedValues: [][]byte{}, + reason: encoding.UpkeepFailureReasonInvalidRevertDataInput, + }, } for _, tt := range tests { @@ -425,10 +452,11 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { } r.hc = hc - state, values, retryable, reqErr := r.doMercuryRequest(context.Background(), tt.lookup, r.lggr) + state, reason, values, retryable, reqErr := r.doMercuryRequest(context.Background(), tt.lookup, r.lggr) assert.Equal(t, tt.expectedValues, values) assert.Equal(t, tt.expectedRetryable, retryable) assert.Equal(t, tt.state, state) + assert.Equal(t, tt.reason, reason) if tt.expectedError != nil { assert.Equal(t, tt.expectedError.Error(), reqErr.Error()) } From a75af3a56a22798640fefc4e2803b6889d7402a9 Mon Sep 17 00:00:00 2001 From: Adam Hamrick Date: Wed, 23 Aug 2023 14:08:52 -0400 Subject: [PATCH 248/270] [TT-267] Removes Disk Log (#10297) * Removes Disk Log * Import cleanup * Use Go 1.20 * Tidy --- integration-tests/types/config/node/core.go | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/integration-tests/types/config/node/core.go b/integration-tests/types/config/node/core.go index 5ee27447a2c..6968f3fadc4 100644 --- a/integration-tests/types/config/node/core.go +++ b/integration-tests/types/config/node/core.go @@ -9,20 +9,19 @@ import ( "path/filepath" "time" - "github.com/smartcontractkit/chainlink-testing-framework/blockchain" - - "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" - "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" - "github.com/smartcontractkit/chainlink/v2/core/utils/config" - "go.uber.org/zap/zapcore" + "github.com/smartcontractkit/chainlink-testing-framework/blockchain" "github.com/smartcontractkit/chainlink/v2/core/assets" evmcfg "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" "github.com/smartcontractkit/chainlink/v2/core/config/toml" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" "github.com/smartcontractkit/chainlink/v2/core/store/models" "github.com/smartcontractkit/chainlink/v2/core/utils" + "github.com/smartcontractkit/chainlink/v2/core/utils/config" + + "github.com/smartcontractkit/chainlink/integration-tests/actions/vrfv2_actions/vrfv2_constants" ) var ( @@ -37,6 +36,9 @@ var ( Log: toml.Log{ Level: ptr(toml.LogLevel(zapcore.DebugLevel)), JSONConsole: ptr(true), + File: toml.LogFile{ + MaxSize: ptr(utils.FileSize(0)), + }, }, WebServer: toml.WebServer{ AllowOrigins: ptr("*"), @@ -133,7 +135,7 @@ func SetChainConfig( ) { if cfg.EVM == nil { var nodes []*evmcfg.Node - for i, _ := range wsUrls { + for i := range wsUrls { node := evmcfg.Node{ Name: ptr(fmt.Sprintf("node_%d_%s", i, chain.Name)), WSURL: mustURL(wsUrls[i]), From b20302b0466209d012b523fd7027c819e5e4555c Mon Sep 17 00:00:00 2001 From: Amir Y <83904651+amirylm@users.noreply.github.com> Date: Wed, 23 Aug 2023 21:38:12 +0300 Subject: [PATCH 249/270] Log provider: fix DB issues and enable to update filter (#10285) * provider: added timeout for reads and increased read q size (32 -> 64) * update filter config (wip): - updated + creation block for filters - enabled config updates for higher blocks - trying to fix registration TODO: tests * increased read logs timeout * added some tests * fix test * reduce creation block * revert check for multiple upkeeps with same filter * recoverer to take filter update block into account * small fix int test * added test case and comment * filters life cycle + fix latest block in provider * TODO > Exploratory * lint and TODO * cleanup * TODO * remove force flag * review * review fixes * revert changes --- .../evm21/logprovider/filter_store.go | 43 +++--- .../evm21/logprovider/integration_test.go | 113 ++++++++++++++-- .../ocr2keeper/evm21/logprovider/provider.go | 67 ++++++---- .../evm21/logprovider/provider_life_cycle.go | 122 ++++++++++++++---- .../logprovider/provider_life_cycle_test.go | 104 +++++++++++++-- .../evm21/logprovider/provider_test.go | 54 ++++---- .../ocr2keeper/evm21/logprovider/recoverer.go | 17 ++- .../evm21/logprovider/recoverer_test.go | 93 ++++++++++++- .../ocr2/plugins/ocr2keeper/evm21/registry.go | 50 +++++-- .../plugins/ocr2keeper/integration_21_test.go | 10 +- 10 files changed, 537 insertions(+), 136 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go index e139655c59b..38b1e4e26f3 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/filter_store.go @@ -12,6 +12,7 @@ type UpkeepFilterStore interface { GetIDs(selector func(upkeepFilter) bool) []*big.Int UpdateFilters(updater func(upkeepFilter, upkeepFilter) upkeepFilter, filters ...upkeepFilter) Has(id *big.Int) bool + Get(id *big.Int) *upkeepFilter RangeFiltersByIDs(iterator func(int, upkeepFilter), ids ...*big.Int) GetFilters(selector func(upkeepFilter) bool) []upkeepFilter AddActiveUpkeeps(filters ...upkeepFilter) @@ -19,17 +20,14 @@ type UpkeepFilterStore interface { Size() int } -type UpkeepFilterStoreTest interface { - UpkeepFilterStore - ResetLastPollBlock() -} - var _ UpkeepFilterStore = &upkeepFilterStore{} type upkeepFilter struct { addr []byte topics []common.Hash upkeepID *big.Int + // configUpdateBlock is the block number the filter was last updated at + configUpdateBlock uint64 // lastPollBlock is the last block number the logs were fetched for this upkeep // used by log event provider. lastPollBlock int64 @@ -47,12 +45,13 @@ func (f upkeepFilter) Clone() upkeepFilter { addr := make([]byte, len(f.addr)) copy(addr, f.addr) return upkeepFilter{ - upkeepID: f.upkeepID, - topics: topics, - addr: addr, - lastPollBlock: f.lastPollBlock, - lastRePollBlock: f.lastRePollBlock, - blockLimiter: f.blockLimiter, + upkeepID: f.upkeepID, + topics: topics, + addr: addr, + configUpdateBlock: f.configUpdateBlock, + lastPollBlock: f.lastPollBlock, + lastRePollBlock: f.lastRePollBlock, + blockLimiter: f.blockLimiter, } } @@ -117,6 +116,18 @@ func (s *upkeepFilterStore) Has(id *big.Int) bool { return ok } +func (s *upkeepFilterStore) Get(id *big.Int) *upkeepFilter { + s.lock.RLock() + defer s.lock.RUnlock() + + f, ok := s.filters[id.String()] + if !ok { + return nil + } + fp := f.Clone() + return &fp +} + func (s *upkeepFilterStore) RangeFiltersByIDs(iterator func(int, upkeepFilter), ids ...*big.Int) { s.lock.RLock() defer s.lock.RUnlock() @@ -181,13 +192,3 @@ func (s *upkeepFilterStore) Size() int { return len(s.filters) } - -func (s *upkeepFilterStore) ResetLastPollBlock() { - s.lock.Lock() - defer s.lock.Unlock() - - for k, f := range s.filters { - f.lastPollBlock = 0 - s.filters[k] = f - } -} diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go index fdb3cbb7ea5..08d56c78c59 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/integration_test.go @@ -62,7 +62,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { n := 10 - _, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) + ids, addrs, contracts := deployUpkeepCounter(t, n, ethClient, backend, carrol, logProvider) lp.PollAndSaveLogs(ctx, int64(n)) go func() { @@ -95,7 +95,7 @@ func TestIntegration_LogEventProvider(t *testing.T) { // we should be able to backfill old logs and fetch new ones logDataABI, err := abi.JSON(strings.NewReader(automation_utils_2_1.AutomationUtilsABI)) require.NoError(t, err) - filterStore.ResetLastPollBlock() + filterStore := logprovider.NewUpkeepFilterStore() logProvider2 := logprovider.NewLogProvider(logger.TestLogger(t), lp, logprovider.NewLogEventsPacker(logDataABI), filterStore, opts) poll(backend.Commit()) @@ -107,6 +107,18 @@ func TestIntegration_LogEventProvider(t *testing.T) { }() defer logProvider2.Close() + // re-register filters + for i, id := range ids { + err = logProvider2.RegisterFilter(logprovider.FilterOptions{ + UpkeepID: id, + TriggerConfig: newPlainLogTriggerConfig(addrs[i]), + // using block number at which the upkeep was registered, + // before we emitted any logs + UpdateBlock: uint64(n), + }) + require.NoError(t, err) + } + waitLogProvider(ctx, t, logProvider2, 2) t.Log("getting logs after restart") @@ -116,6 +128,78 @@ func TestIntegration_LogEventProvider(t *testing.T) { }) } +func TestIntegration_LogEventProvider_UpdateConfig(t *testing.T) { + ctx, cancel := context.WithCancel(testutils.Context(t)) + defer cancel() + + backend, stopMining, accounts := setupBackend(t) + defer stopMining() + carrol := accounts[2] + + db := setupDB(t) + defer db.Close() + + opts := &logprovider.LogEventProviderOptions{ + ReadInterval: time.Second / 2, + } + lp, ethClient, utilsABI := setupDependencies(t, db, backend) + filterStore := logprovider.NewUpkeepFilterStore() + provider, _ := setup(logger.TestLogger(t), lp, nil, utilsABI, nil, filterStore, opts) + logProvider := provider.(logprovider.LogEventProviderTest) + + _, addrs, contracts := deployUpkeepCounter(t, 1, ethClient, backend, carrol, logProvider) + lp.PollAndSaveLogs(ctx, int64(5)) + require.Equal(t, 1, len(contracts)) + require.Equal(t, 1, len(addrs)) + + t.Run("update filter config", func(t *testing.T) { + upkeepID := kevmcore.GenUpkeepID(ocr2keepers.LogTrigger, "111") + id := upkeepID.BigInt() + cfg := newPlainLogTriggerConfig(addrs[0]) + b, err := ethClient.BlockByHash(ctx, backend.Commit()) + require.NoError(t, err) + bn := b.Number() + err = logProvider.RegisterFilter(logprovider.FilterOptions{ + UpkeepID: id, + TriggerConfig: cfg, + UpdateBlock: bn.Uint64(), + }) + require.NoError(t, err) + // old block + err = logProvider.RegisterFilter(logprovider.FilterOptions{ + UpkeepID: id, + TriggerConfig: cfg, + UpdateBlock: bn.Uint64() - 1, + }) + require.Error(t, err) + // new block + b, err = ethClient.BlockByHash(ctx, backend.Commit()) + require.NoError(t, err) + bn = b.Number() + err = logProvider.RegisterFilter(logprovider.FilterOptions{ + UpkeepID: id, + TriggerConfig: cfg, + UpdateBlock: bn.Uint64(), + }) + require.NoError(t, err) + }) + + t.Run("register same log filter", func(t *testing.T) { + upkeepID := kevmcore.GenUpkeepID(ocr2keepers.LogTrigger, "222") + id := upkeepID.BigInt() + cfg := newPlainLogTriggerConfig(addrs[0]) + b, err := ethClient.BlockByHash(ctx, backend.Commit()) + require.NoError(t, err) + bn := b.Number() + err = logProvider.RegisterFilter(logprovider.FilterOptions{ + UpkeepID: id, + TriggerConfig: cfg, + UpdateBlock: bn.Uint64(), + }) + require.NoError(t, err) + }) +} + func TestIntegration_LogEventProvider_Backfill(t *testing.T) { ctx, cancel := context.WithTimeout(testutils.Context(t), time.Second*60) defer cancel() @@ -137,7 +221,7 @@ func TestIntegration_LogEventProvider_Backfill(t *testing.T) { n := 10 - _, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) + _, _, contracts := deployUpkeepCounter(t, n, ethClient, backend, carrol, logProvider) poll := pollFn(ctx, t, lp, ethClient) @@ -200,6 +284,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { ids, _, contracts := deployUpkeepCounter( t, numberOfUserContracts, + ethClient, backend, userContractAccount, logProvider) @@ -232,7 +317,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { assert.GreaterOrEqual(t, latestBlock, minimumBlockCount, "to ensure the integrety of the test, the minimum block count before the test should be %d but got %d", minimumBlockCount, latestBlock) } - require.NoError(t, logProvider.ReadLogs(ctx, true, ids...)) + require.NoError(t, logProvider.ReadLogs(ctx, ids...)) return ctx, backend, poll, logProvider, ids, deferFunc } @@ -260,7 +345,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { // advance 1 block for every read poll(backend.Commit()) - err := logProvider.ReadLogs(ctx, true, ids...) + err := logProvider.ReadLogs(ctx, ids...) if err != nil { assert.False(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") } @@ -298,7 +383,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { poll(backend.Commit()) } - err := logProvider.ReadLogs(ctx, true, ids...) + err := logProvider.ReadLogs(ctx, ids...) if err != nil { assert.True(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") } @@ -336,7 +421,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { // all entries should error at this point because there are too many // blocks to processes - err := logProvider.ReadLogs(ctx, true, ids...) + err := logProvider.ReadLogs(ctx, ids...) if err != nil { assert.True(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") } @@ -351,7 +436,7 @@ func TestIntegration_LogEventProvider_RateLimit(t *testing.T) { // all entries should reset to the maxBurst because they are beyond // the log lookback - err = logProvider.ReadLogs(ctx, true, ids...) + err = logProvider.ReadLogs(ctx, ids...) if err != nil { assert.True(t, errors.Is(err, logprovider.ErrBlockLimitExceeded), "error should not contain block limit exceeded") } @@ -393,7 +478,7 @@ func TestIntegration_LogRecoverer_Backfill(t *testing.T) { n := 10 - _, _, contracts := deployUpkeepCounter(t, n, backend, carrol, logProvider) + _, _, contracts := deployUpkeepCounter(t, n, ethClient, backend, carrol, logProvider) poll := pollFn(ctx, t, lp, ethClient) @@ -520,6 +605,7 @@ func triggerEvents( func deployUpkeepCounter( t *testing.T, n int, + ethClient *evmclient.SimulatedBackendClient, backend *backends.SimulatedBackend, account *bind.TransactOpts, logProvider logprovider.LogEventProvider, @@ -542,7 +628,14 @@ func deployUpkeepCounter( upkeepID := ocr2keepers.UpkeepIdentifier(append(common.LeftPadBytes([]byte{1}, 16), upkeepAddr[:16]...)) id := upkeepID.BigInt() ids = append(ids, id) - err = logProvider.RegisterFilter(id, newPlainLogTriggerConfig(upkeepAddr)) + b, err := ethClient.BlockByHash(context.Background(), backend.Commit()) + require.NoError(t, err) + bn := b.Number() + err = logProvider.RegisterFilter(logprovider.FilterOptions{ + UpkeepID: id, + TriggerConfig: newPlainLogTriggerConfig(upkeepAddr), + UpdateBlock: bn.Uint64(), + }) require.NoError(t, err) } return ids, contractsAddrs, contracts diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 9f20589e79f..576971c0a7f 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -30,27 +30,39 @@ var ( // AllowedLogsPerUpkeep is the maximum number of logs allowed per upkeep every single call. AllowedLogsPerUpkeep = 5 + + readJobQueueSize = 64 + readLogsTimeout = 10 * time.Second ) // LogTriggerConfig is an alias for log trigger config. type LogTriggerConfig automation_utils_2_1.LogTriggerConfig +type FilterOptions struct { + UpkeepID *big.Int + TriggerConfig LogTriggerConfig + UpdateBlock uint64 +} + type LogTriggersLifeCycle interface { // RegisterFilter registers the filter (if valid) for the given upkeepID. - RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfig) error + RegisterFilter(opts FilterOptions) error // UnregisterFilter removes the filter for the given upkeepID. UnregisterFilter(upkeepID *big.Int) error } type LogEventProvider interface { ocr2keepers.LogEventProvider LogTriggersLifeCycle + + RefreshActiveUpkeeps(ids ...*big.Int) ([]*big.Int, error) + Start(context.Context) error io.Closer } type LogEventProviderTest interface { LogEventProvider - ReadLogs(ctx context.Context, force bool, ids ...*big.Int) error + ReadLogs(ctx context.Context, ids ...*big.Int) error CurrentPartitionIdx() uint64 } @@ -67,7 +79,8 @@ type logEventProvider struct { packer LogDataPacker - lock sync.RWMutex + lock sync.RWMutex + registerLock sync.Mutex filterStore UpkeepFilterStore buffer *logEventBuffer @@ -87,7 +100,6 @@ func NewLogProvider(lggr logger.Logger, poller logpoller.LogPoller, packer LogDa lggr: lggr.Named("KeepersRegistry.LogEventProvider"), buffer: newLogEventBuffer(lggr, int(opts.LookbackBlocks), BufferMaxBlockSize, AllowedLogsPerBlock), poller: poller, - lock: sync.RWMutex{}, opts: opts, filterStore: filterStore, } @@ -105,7 +117,7 @@ func (p *logEventProvider) Start(context.Context) error { p.cancel = cancel p.lock.Unlock() - readQ := make(chan []*big.Int, 32) + readQ := make(chan []*big.Int, readJobQueueSize) p.lggr.Infow("starting log event provider", "readInterval", p.opts.ReadInterval, "readMaxBatchSize", p.opts.ReadBatchSize, "readers", p.opts.Readers) @@ -155,9 +167,11 @@ func (p *logEventProvider) Name() string { return p.lggr.Name() } -func (p *logEventProvider) GetLatestPayloads(context.Context) ([]ocr2keepers.UpkeepPayload, error) { - // TODO: Fitler logs below upkeep creation block here - latest := p.buffer.latestBlockSeen() +func (p *logEventProvider) GetLatestPayloads(ctx context.Context) ([]ocr2keepers.UpkeepPayload, error) { + latest, err := p.poller.LatestBlock(pg.WithParentCtx(ctx)) + if err != nil { + return nil, fmt.Errorf("%w: %s", ErrHeadNotAvailable, err) + } diff := latest - p.opts.LookbackBlocks if diff < 0 { diff = latest @@ -188,12 +202,18 @@ func (p *logEventProvider) GetLatestPayloads(context.Context) ([]ocr2keepers.Upk } // ReadLogs fetches the logs for the given upkeeps. -func (p *logEventProvider) ReadLogs(ctx context.Context, force bool, ids ...*big.Int) error { +func (p *logEventProvider) ReadLogs(pctx context.Context, ids ...*big.Int) error { + ctx, cancel := context.WithTimeout(pctx, readLogsTimeout) + defer cancel() + latest, err := p.poller.LatestBlock(pg.WithParentCtx(ctx)) if err != nil { return fmt.Errorf("%w: %s", ErrHeadNotAvailable, err) } - filters := p.getFilters(latest, force, ids...) + if latest == 0 { + return fmt.Errorf("%w: %s", ErrHeadNotAvailable, "latest block is 0") + } + filters := p.getFilters(latest, ids...) err = p.readLogs(ctx, latest, filters) p.updateFiltersLastPoll(filters) @@ -253,7 +273,7 @@ func (p *logEventProvider) startReader(pctx context.Context, readQ <-chan []*big for { select { case batch := <-readQ: - if err := p.ReadLogs(ctx, true, batch...); err != nil { + if err := p.ReadLogs(ctx, batch...); err != nil { if ctx.Err() != nil { return } @@ -304,8 +324,7 @@ func (p *logEventProvider) updateFiltersLastPoll(entries []upkeepFilter) { // getFilters returns the filters for the given upkeepIDs, // returns empty filter for inactive upkeeps. -// TODO: Cleanup force variable as it is always passed as true. -func (p *logEventProvider) getFilters(latestBlock int64, force bool, ids ...*big.Int) []upkeepFilter { +func (p *logEventProvider) getFilters(latestBlock int64, ids ...*big.Int) []upkeepFilter { var filters []upkeepFilter p.filterStore.RangeFiltersByIDs(func(i int, f upkeepFilter) { if len(f.addr) == 0 { // not found @@ -313,7 +332,12 @@ func (p *logEventProvider) getFilters(latestBlock int64, force bool, ids ...*big filters = append(filters, f) return } - if !force && f.lastPollBlock > latestBlock { + if f.configUpdateBlock > uint64(latestBlock) { + p.lggr.Debugw("upkeep config update block was created after latestBlock", "upkeep", f.upkeepID.String(), "configUpdateBlock", f.configUpdateBlock, "latestBlock", latestBlock) + filters = append(filters, upkeepFilter{upkeepID: f.upkeepID}) + return + } + if f.lastPollBlock > latestBlock { p.lggr.Debugw("already polled latest block", "entry.lastPollBlock", f.lastPollBlock, "latestBlock", latestBlock, "upkeep", f.upkeepID.String()) filters = append(filters, upkeepFilter{upkeepID: f.upkeepID}) return @@ -331,8 +355,8 @@ func (p *logEventProvider) getFilters(latestBlock int64, force bool, ids ...*big func (p *logEventProvider) readLogs(ctx context.Context, latest int64, filters []upkeepFilter) (merr error) { lookbackBlocks := p.opts.LookbackBlocks if latest < lookbackBlocks { - // special case of an empty or new blockchain (e.g. simulated chain) - lookbackBlocks = latest + // special case of a new blockchain (e.g. simulated chain) + lookbackBlocks = latest - 1 } // maxBurst will be used to increase the burst limit to allow a long range scan maxBurst := int(lookbackBlocks + 1) @@ -341,10 +365,9 @@ func (p *logEventProvider) readLogs(ctx context.Context, latest int64, filters [ if len(filter.addr) == 0 { continue } - // start should either be the last block polled for the filter or the - // lookback range in the case this is the first time the filter is polled start := filter.lastPollBlock - if start == 0 || start < latest-lookbackBlocks { + // range should not exceed [lookbackBlocks, latest] + if start < latest-lookbackBlocks { start = latest - lookbackBlocks filter.blockLimiter.SetBurst(maxBurst) } @@ -356,10 +379,10 @@ func (p *logEventProvider) readLogs(ctx context.Context, latest int64, filters [ } // adding a buffer to check for reorged logs. start = start - p.opts.ReorgBuffer - if start < 0 { - start = 0 + // make sure start of the range is not before the config update block + if configUpdateBlock := int64(filter.configUpdateBlock); start < configUpdateBlock { + start = configUpdateBlock } - logs, err := p.poller.LogsWithSigs(start, latest, filter.topics, common.BytesToAddress(filter.addr), pg.WithParentCtx(ctx)) if err != nil { // cancel limit reservation as we failed to get logs diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go index 35dacc0b05b..4ddc93e376b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle.go @@ -2,11 +2,12 @@ package logprovider import ( "bytes" + "errors" + "fmt" "math/big" "time" "github.com/ethereum/go-ethereum/common" - "github.com/pkg/errors" "golang.org/x/time/rate" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" @@ -17,42 +18,113 @@ var ( LogRetention = 24 * time.Hour ) -func (p *logEventProvider) RegisterFilter(upkeepID *big.Int, cfg LogTriggerConfig) error { +func (p *logEventProvider) RefreshActiveUpkeeps(ids ...*big.Int) ([]*big.Int, error) { + if len(ids) == 0 { + return nil, nil + } + p.lggr.Debugw("Refreshing active upkeeps", "upkeeps", len(ids)) + visited := make(map[string]bool, len(ids)) + for _, id := range ids { + visited[id.String()] = false + } + inactiveIDs := p.filterStore.GetIDs(func(f upkeepFilter) bool { + uid := f.upkeepID.String() + _, ok := visited[uid] + visited[uid] = true + return !ok + }) + var merr error + if len(inactiveIDs) > 0 { + p.lggr.Debugw("Removing inactive upkeeps", "upkeeps", len(inactiveIDs)) + for _, id := range inactiveIDs { + if err := p.UnregisterFilter(id); err != nil { + merr = errors.Join(merr, fmt.Errorf("failed to unregister filter: %s", id.String())) + } + } + } + var newIDs []*big.Int + for id, ok := range visited { + if !ok { + uid, _ := new(big.Int).SetString(id, 10) + newIDs = append(newIDs, uid) + } + } + + return newIDs, merr +} + +func (p *logEventProvider) RegisterFilter(opts FilterOptions) error { + upkeepID, cfg := opts.UpkeepID, opts.TriggerConfig if err := p.validateLogTriggerConfig(cfg); err != nil { - return errors.Wrap(err, "invalid log trigger config") + return fmt.Errorf("invalid log trigger config: %w", err) } - filter := p.newLogFilter(upkeepID, cfg) + lpFilter := p.newLogFilter(upkeepID, cfg) + + // using lock to facilitate multiple events causing filter registration + // at the same time. + // Exploratory: consider using a q to handle registration requests + p.registerLock.Lock() + defer p.registerLock.Unlock() - if p.filterStore.Has(upkeepID) { - // TODO: check if filter was updated, if so unregister previous filter and register new one - return errors.Errorf("filter for upkeep with id %s already registered", upkeepID.String()) + var filter upkeepFilter + currentFilter := p.filterStore.Get(upkeepID) + if currentFilter != nil { + if currentFilter.configUpdateBlock > opts.UpdateBlock { + // already registered with a config from a higher block number + return fmt.Errorf("filter for upkeep with id %s already registered with newer config", upkeepID.String()) + } else if currentFilter.configUpdateBlock == opts.UpdateBlock { + // already registered with the same config + p.lggr.Debugf("filter for upkeep with id %s already registered with the same config", upkeepID.String()) + return nil + } + // removing filter so we can recreate it with updated values + err := p.poller.UnregisterFilter(p.filterName(currentFilter.upkeepID)) + if err != nil { + return fmt.Errorf("failed to unregister upkeep filter %s for update: %w", upkeepID.String(), err) + } + filter = *currentFilter + } else { // new filter + filter = upkeepFilter{ + upkeepID: upkeepID, + blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), + } } - // TODO: ReplayAsync logs for the upkeep from creation block - // TODO: Verify handling of different upkeeps using same filter - if err := p.poller.RegisterFilter(filter); err != nil { - return errors.Wrap(err, "failed to register upkeep filter") + filter.lastPollBlock = 0 + filter.lastRePollBlock = 0 + filter.configUpdateBlock = opts.UpdateBlock + filter.addr = lpFilter.Addresses[0].Bytes() + filter.topics = make([]common.Hash, len(lpFilter.EventSigs)) + copy(filter.topics, lpFilter.EventSigs) + + if err := p.register(lpFilter, filter); err != nil { + return fmt.Errorf("failed to register upkeep filter %s: %w", filter.upkeepID.String(), err) } - topics := make([]common.Hash, len(filter.EventSigs)) - copy(topics, filter.EventSigs) - p.filterStore.AddActiveUpkeeps(upkeepFilter{ - upkeepID: upkeepID, - addr: filter.Addresses[0].Bytes(), - topics: topics, - blockLimiter: rate.NewLimiter(p.opts.BlockRateLimit, p.opts.BlockLimitBurst), - lastPollBlock: 0, // TODO: Start from filter creation block - }) + + return nil +} + +// register registers the upkeep filter with the log poller and adds it to the filter store. +func (p *logEventProvider) register(lpFilter logpoller.Filter, ufilter upkeepFilter) error { + if err := p.poller.RegisterFilter(lpFilter); err != nil { + return err + } + p.filterStore.AddActiveUpkeeps(ufilter) + p.poller.ReplayAsync(int64(ufilter.configUpdateBlock)) return nil } func (p *logEventProvider) UnregisterFilter(upkeepID *big.Int) error { err := p.poller.UnregisterFilter(p.filterName(upkeepID)) - if err == nil { - p.filterStore.RemoveActiveUpkeeps(upkeepFilter{ - upkeepID: upkeepID, - }) + if err != nil { + // TODO: mark as removed in filter store, so we'll + // automatically retry on next refresh + return fmt.Errorf("failed to unregister upkeep filter %s: %w", upkeepID.String(), err) } - return errors.Wrap(err, "failed to unregister upkeep filter") + p.filterStore.RemoveActiveUpkeeps(upkeepFilter{ + upkeepID: upkeepID, + }) + return nil } // newLogFilter creates logpoller.Filter from the given upkeep config diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go index 3b2e0c7d1df..3f9ddaa5af3 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_life_cycle_test.go @@ -5,20 +5,24 @@ import ( "testing" "github.com/ethereum/go-ethereum/common" + ocr2keepers "github.com/smartcontractkit/ocr2keepers/pkg/v3/types" "github.com/stretchr/testify/mock" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller/mocks" "github.com/smartcontractkit/chainlink/v2/core/logger" + "github.com/smartcontractkit/chainlink/v2/core/services/ocr2/plugins/ocr2keeper/evm21/core" ) func TestLogEventProvider_LifeCycle(t *testing.T) { tests := []struct { - name string - errored bool - upkeepID *big.Int - upkeepCfg LogTriggerConfig - mockPoller bool + name string + errored bool + upkeepID *big.Int + upkeepCfg LogTriggerConfig + cfgUpdateBlock uint64 + mockPoller bool + unregister bool }{ { "new upkeep", @@ -28,13 +32,17 @@ func TestLogEventProvider_LifeCycle(t *testing.T) { ContractAddress: common.BytesToAddress(common.LeftPadBytes([]byte{1, 2, 3, 4}, 20)), Topic0: common.BytesToHash(common.LeftPadBytes([]byte{1, 2, 3, 4}, 32)), }, + uint64(1), true, + false, }, { "empty config", true, big.NewInt(111), LogTriggerConfig{}, + uint64(0), + false, false, }, { @@ -45,29 +53,99 @@ func TestLogEventProvider_LifeCycle(t *testing.T) { ContractAddress: common.BytesToAddress(common.LeftPadBytes([]byte{}, 20)), Topic0: common.BytesToHash(common.LeftPadBytes([]byte{}, 32)), }, + uint64(2), + false, + false, + }, + { + "existing config", + true, + big.NewInt(111), + LogTriggerConfig{ + ContractAddress: common.BytesToAddress(common.LeftPadBytes([]byte{1, 2, 3, 4}, 20)), + Topic0: common.BytesToHash(common.LeftPadBytes([]byte{1, 2, 3, 4}, 32)), + }, + uint64(0), + true, + false, + }, + { + "existing config with newer block", false, + big.NewInt(111), + LogTriggerConfig{ + ContractAddress: common.BytesToAddress(common.LeftPadBytes([]byte{1, 2, 3, 4}, 20)), + Topic0: common.BytesToHash(common.LeftPadBytes([]byte{1, 2, 3, 4}, 32)), + }, + uint64(2), + true, + true, }, } + mp := new(mocks.LogPoller) + mp.On("RegisterFilter", mock.Anything).Return(nil) + mp.On("UnregisterFilter", mock.Anything).Return(nil) + mp.On("ReplayAsync", mock.Anything).Return(nil) + p := NewLogProvider(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) + for _, tc := range tests { t.Run(tc.name, func(t *testing.T) { - mp := new(mocks.LogPoller) - if tc.mockPoller { - mp.On("RegisterFilter", mock.Anything).Return(nil) - mp.On("UnregisterFilter", mock.Anything, mock.Anything).Return(nil) - } - p := NewLogProvider(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) - err := p.RegisterFilter(tc.upkeepID, tc.upkeepCfg) + err := p.RegisterFilter(FilterOptions{ + UpkeepID: tc.upkeepID, + TriggerConfig: tc.upkeepCfg, + UpdateBlock: tc.cfgUpdateBlock, + }) if tc.errored { require.Error(t, err) } else { require.NoError(t, err) - require.NoError(t, p.UnregisterFilter(tc.upkeepID)) + if tc.unregister { + require.NoError(t, p.UnregisterFilter(tc.upkeepID)) + } } }) } } +func TestEventLogProvider_RefreshActiveUpkeeps(t *testing.T) { + mp := new(mocks.LogPoller) + mp.On("RegisterFilter", mock.Anything).Return(nil) + mp.On("UnregisterFilter", mock.Anything).Return(nil) + mp.On("ReplayAsync", mock.Anything).Return(nil) + + p := NewLogProvider(logger.TestLogger(t), mp, &mockedPacker{}, NewUpkeepFilterStore(), nil) + + require.NoError(t, p.RegisterFilter(FilterOptions{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "1111").BigInt(), + TriggerConfig: LogTriggerConfig{ + ContractAddress: common.BytesToAddress(common.LeftPadBytes([]byte{1, 2, 3, 4}, 20)), + Topic0: common.BytesToHash(common.LeftPadBytes([]byte{1, 2, 3, 4}, 32)), + }, + UpdateBlock: uint64(0), + })) + require.NoError(t, p.RegisterFilter(FilterOptions{ + UpkeepID: core.GenUpkeepID(ocr2keepers.LogTrigger, "2222").BigInt(), + TriggerConfig: LogTriggerConfig{ + ContractAddress: common.BytesToAddress(common.LeftPadBytes([]byte{1, 2, 3, 4}, 20)), + Topic0: common.BytesToHash(common.LeftPadBytes([]byte{1, 2, 3, 4}, 32)), + }, + UpdateBlock: uint64(0), + })) + require.Equal(t, 2, p.filterStore.Size()) + + newIds, err := p.RefreshActiveUpkeeps() + require.NoError(t, err) + require.Len(t, newIds, 0) + newIds, err = p.RefreshActiveUpkeeps( + core.GenUpkeepID(ocr2keepers.LogTrigger, "2222").BigInt(), + core.GenUpkeepID(ocr2keepers.LogTrigger, "1234").BigInt(), + core.GenUpkeepID(ocr2keepers.LogTrigger, "123").BigInt()) + require.NoError(t, err) + require.Len(t, newIds, 2) + require.Equal(t, 1, p.filterStore.Size()) +} + func TestLogEventProvider_GetFiltersBySelector(t *testing.T) { var zeroBytes [32]byte tests := []struct { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go index 8660bb8097c..7c1aa84ac4b 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider_test.go @@ -21,39 +21,45 @@ import ( "golang.org/x/time/rate" ) -func TestLogEventProvider_GetEntries(t *testing.T) { +func TestLogEventProvider_GetFilters(t *testing.T) { p := NewLogProvider(logger.TestLogger(t), nil, &mockedPacker{}, NewUpkeepFilterStore(), nil) _, f := newEntry(p, 1) p.filterStore.AddActiveUpkeeps(f) - t.Run("no entries", func(t *testing.T) { - entries := p.getFilters(0, false, big.NewInt(0)) - require.Len(t, entries, 1) - require.Equal(t, len(entries[0].addr), 0) + t.Run("no filters", func(t *testing.T) { + filters := p.getFilters(0, big.NewInt(0)) + require.Len(t, filters, 1) + require.Equal(t, len(filters[0].addr), 0) }) - t.Run("has entry with lower lastPollBlock", func(t *testing.T) { - entries := p.getFilters(0, false, f.upkeepID) - require.Len(t, entries, 1) - require.Greater(t, len(entries[0].addr), 0) - entries = p.getFilters(10, false, f.upkeepID) - require.Len(t, entries, 1) - require.Greater(t, len(entries[0].addr), 0) + t.Run("has filter with lower lastPollBlock", func(t *testing.T) { + filters := p.getFilters(0, f.upkeepID) + require.Len(t, filters, 1) + require.Greater(t, len(filters[0].addr), 0) + filters = p.getFilters(10, f.upkeepID) + require.Len(t, filters, 1) + require.Greater(t, len(filters[0].addr), 0) }) - t.Run("has entry with higher lastPollBlock", func(t *testing.T) { + t.Run("has filter with higher lastPollBlock", func(t *testing.T) { _, f := newEntry(p, 2) f.lastPollBlock = 3 p.filterStore.AddActiveUpkeeps(f) - entries := p.getFilters(1, false, f.upkeepID) - require.Len(t, entries, 1) - require.Equal(t, len(entries[0].addr), 0) + filters := p.getFilters(1, f.upkeepID) + require.Len(t, filters, 1) + require.Equal(t, len(filters[0].addr), 0) + }) + + t.Run("has filter with higher configUpdateBlock", func(t *testing.T) { + _, f := newEntry(p, 2) + f.configUpdateBlock = 3 + p.filterStore.AddActiveUpkeeps(f) - entries = p.getFilters(1, true, f.upkeepID) - require.Len(t, entries, 1) - require.Greater(t, len(entries[0].addr), 0) + filters := p.getFilters(1, f.upkeepID) + require.Len(t, filters, 1) + require.Equal(t, len(filters[0].addr), 0) }) } @@ -239,6 +245,7 @@ func TestLogEventProvider_ReadLogs(t *testing.T) { mp := new(mocks.LogPoller) mp.On("RegisterFilter", mock.Anything).Return(nil) + mp.On("ReplayAsync", mock.Anything).Return() mp.On("UnregisterFilter", mock.Anything, mock.Anything).Return(nil) mp.On("LatestBlock", mock.Anything).Return(int64(1), nil) mp.On("LogsWithSigs", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return([]logpoller.Log{ @@ -254,17 +261,20 @@ func TestLogEventProvider_ReadLogs(t *testing.T) { for i := 0; i < 10; i++ { cfg, f := newEntry(p, i+1) ids = append(ids, f.upkeepID) - require.NoError(t, p.RegisterFilter(f.upkeepID, cfg)) + require.NoError(t, p.RegisterFilter(FilterOptions{ + UpkeepID: f.upkeepID, + TriggerConfig: cfg, + })) } t.Run("no entries", func(t *testing.T) { - require.NoError(t, p.ReadLogs(ctx, false, big.NewInt(999999))) + require.NoError(t, p.ReadLogs(ctx, big.NewInt(999999))) logs := p.buffer.peek(10) require.Len(t, logs, 0) }) t.Run("has entries", func(t *testing.T) { - require.NoError(t, p.ReadLogs(ctx, true, ids[:2]...)) + require.NoError(t, p.ReadLogs(ctx, ids[:2]...)) logs := p.buffer.peek(10) require.Len(t, logs, 2) }) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go index 594a5110946..6dd5f8fe56a 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer.go @@ -282,12 +282,15 @@ func (r *logRecoverer) recover(ctx context.Context) error { if err != nil { return fmt.Errorf("%w: %s", ErrHeadNotAvailable, err) } - // TODO: Ensure start block is above upkeep creation block + start, offsetBlock := r.getRecoveryWindow(latest) if offsetBlock < 0 { // too soon to recover, we don't have enough blocks return nil } + if start < 0 { + start = 0 + } filters := r.getFilterBatch(offsetBlock) if len(filters) == 0 { @@ -314,12 +317,14 @@ func (r *logRecoverer) recover(ctx context.Context) error { // recoverFilter recovers logs for a single upkeep filter. func (r *logRecoverer) recoverFilter(ctx context.Context, f upkeepFilter, startBlock, offsetBlock int64) error { start := f.lastRePollBlock + // ensure we don't recover logs from before the filter was created + // NOTE: we expect that filter with configUpdateBlock > offsetBlock were already filtered out. + if configUpdateBlock := int64(f.configUpdateBlock); start < configUpdateBlock { + start = configUpdateBlock + } if start < startBlock { start = startBlock } - if start < 0 { - start = 0 - } end := start + recoveryLogsBuffer if end > offsetBlock { end = offsetBlock @@ -431,7 +436,9 @@ func (r *logRecoverer) getRecoveryWindow(latest int64) (int64, int64) { // getFilterBatch returns a batch of filters that are ready to be recovered. func (r *logRecoverer) getFilterBatch(offsetBlock int64) []upkeepFilter { filters := r.filterStore.GetFilters(func(f upkeepFilter) bool { - return f.lastRePollBlock <= offsetBlock + // ensure we work only on filters that are ready to be recovered + // no need to recover in case f.configUpdateBlock is after offsetBlock + return f.lastRePollBlock <= offsetBlock && int64(f.configUpdateBlock) <= offsetBlock }) sort.Slice(filters, func(i, j int) bool { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go index b78f0d2ac59..fbd09a1f778 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go @@ -106,6 +106,7 @@ func TestLogRecoverer_Recover(t *testing.T) { latestBlockErr error active []upkeepFilter states []ocr2keepers.UpkeepState + statesErr error logs []logpoller.Log logsErr error recoverErr error @@ -118,6 +119,7 @@ func TestLogRecoverer_Recover(t *testing.T) { nil, []upkeepFilter{}, []ocr2keepers.UpkeepState{}, + nil, []logpoller.Log{}, nil, nil, @@ -130,11 +132,40 @@ func TestLogRecoverer_Recover(t *testing.T) { fmt.Errorf("test error"), []upkeepFilter{}, []ocr2keepers.UpkeepState{}, + nil, []logpoller.Log{}, nil, fmt.Errorf("test error"), []string{}, }, + { + "states error", + 100, + 200, + nil, + []upkeepFilter{ + { + upkeepID: big.NewInt(1), + addr: common.HexToAddress("0x1").Bytes(), + topics: []common.Hash{ + common.HexToHash("0x1"), + }, + }, + }, + nil, + fmt.Errorf("test error"), + []logpoller.Log{ + { + BlockNumber: 2, + TxHash: common.HexToHash("0x111"), + LogIndex: 1, + BlockHash: common.HexToHash("0x2"), + }, + }, + nil, + nil, + []string{}, + }, { "get logs error", 200, @@ -147,10 +178,10 @@ func TestLogRecoverer_Recover(t *testing.T) { topics: []common.Hash{ common.HexToHash("0x1"), }, - lastPollBlock: 0, }, }, []ocr2keepers.UpkeepState{}, + nil, []logpoller.Log{}, fmt.Errorf("test error"), nil, @@ -168,10 +199,18 @@ func TestLogRecoverer_Recover(t *testing.T) { topics: []common.Hash{ common.HexToHash("0x1"), }, - lastPollBlock: 0, + }, + { + upkeepID: big.NewInt(2), + addr: common.HexToAddress("0x2").Bytes(), + topics: []common.Hash{ + common.HexToHash("0x2"), + }, + configUpdateBlock: 150, // should be filtered out }, }, []ocr2keepers.UpkeepState{ocr2keepers.UnknownState}, + nil, []logpoller.Log{ { BlockNumber: 2, @@ -194,7 +233,7 @@ func TestLogRecoverer_Recover(t *testing.T) { filterStore.AddActiveUpkeeps(tc.active...) lp.On("LatestBlock", mock.Anything).Return(tc.latestBlock, tc.latestBlockErr) lp.On("LogsWithSigs", mock.Anything, mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.logs, tc.logsErr) - statesReader.On("SelectByWorkIDsInRange", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.states, nil) + statesReader.On("SelectByWorkIDsInRange", mock.Anything, mock.Anything, mock.Anything, mock.Anything).Return(tc.states, tc.statesErr) err := recoverer.recover(ctx) if tc.recoverErr != nil { @@ -235,6 +274,54 @@ func TestLogRecoverer_SelectFilterBatch(t *testing.T) { require.Equal(t, recoveryBatchSize/2, len(batch)) } +func TestLogRecoverer_getFilterBatch(t *testing.T) { + tests := []struct { + name string + offsetBlock int64 + filters []upkeepFilter + want int + }{ + { + "empty", + 2, + []upkeepFilter{}, + 0, + }, + { + "filter out of range", + 100, + []upkeepFilter{ + { + upkeepID: big.NewInt(1), + addr: common.HexToAddress("0x1").Bytes(), + lastRePollBlock: 50, + }, + { + upkeepID: big.NewInt(2), + addr: common.HexToAddress("0x2").Bytes(), + lastRePollBlock: 50, + configUpdateBlock: 101, // out of range + }, + { + upkeepID: big.NewInt(3), + addr: common.HexToAddress("0x3").Bytes(), + configUpdateBlock: 99, + }, + }, + 2, + }, + } + + for _, tc := range tests { + t.Run(tc.name, func(t *testing.T) { + recoverer, filterStore, _, _ := setupTestRecoverer(t, time.Millisecond*50, int64(100)) + filterStore.AddActiveUpkeeps(tc.filters...) + batch := recoverer.getFilterBatch(tc.offsetBlock) + require.Equal(t, tc.want, len(batch)) + }) + } +} + func TestLogRecoverer_FilterFinalizedStates(t *testing.T) { tests := []struct { name string diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go index 908048ca2bc..fabfcca8248 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/registry.go @@ -2,6 +2,7 @@ package evm import ( "context" + goerrors "errors" "fmt" "math/big" "net/http" @@ -270,22 +271,39 @@ func (r *EvmRegistry) refreshActiveUpkeeps() error { } r.active.Reset(ids...) - // refresh trigger config log upkeeps - // Note: We only update the trigger config for current active upkeeps and do not remove configs - // for any upkeeps that might have been removed. We depend upon state events to remove the configs + return r.refreshLogTriggerUpkeeps(ids) +} + +// refreshLogTriggerUpkeeps refreshes the active upkeep ids for log trigger upkeeps +// +// TODO: check for updated config for log trigger upkeeps and update it, currently we ignore them. +func (r *EvmRegistry) refreshLogTriggerUpkeeps(ids []*big.Int) error { + logTriggerIDs := make([]*big.Int, 0) for _, id := range ids { uid := &ocr2keepers.UpkeepIdentifier{} - uid.FromBigInt(id) + if ok := uid.FromBigInt(id); !ok { + r.lggr.Warnf("failed to parse upkeep id %s", id.String()) + } switch core.GetUpkeepType(*uid) { case ocr2keepers.LogTrigger: - if err := r.updateTriggerConfig(id, nil); err != nil { - r.lggr.Warnf("failed to update trigger config for upkeep ID %s: %s", id.String(), err) - } + logTriggerIDs = append(logTriggerIDs, id) default: } } + newUpkeeps, err := r.logEventProvider.RefreshActiveUpkeeps(logTriggerIDs...) + if err != nil { + return fmt.Errorf("failed to refresh active upkeep ids in log event provider: %w", err) + } + var merr error + for _, id := range newUpkeeps { + // TODO: find the ConfigSet/UpkeepUnpaused events for this upkeep and pass cfg and block number + // block number should be taken from UpkeepUnpaused if it's block is higher than ConfigSet + if err := r.updateTriggerConfig(id, nil, 0); err != nil { + merr = goerrors.Join(merr, fmt.Errorf("failed to update trigger config for upkeep id %s: %w", id.String(), err)) + } + } - return nil + return merr } func (r *EvmRegistry) pollUpkeepStateLogs() error { @@ -354,7 +372,7 @@ func (r *EvmRegistry) processUpkeepStateLog(l logpoller.Log) error { r.removeFromActive(l.Id) case *iregistry21.IKeeperRegistryMasterUpkeepTriggerConfigSet: r.lggr.Debugf("KeeperRegistryUpkeepTriggerConfigSet log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) - if err := r.updateTriggerConfig(l.Id, l.TriggerConfig); err != nil { + if err := r.updateTriggerConfig(l.Id, l.TriggerConfig, rawLog.BlockNumber); err != nil { r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepTriggerConfigSet for upkeep ID %s: %s", l.Id.String(), err) } case *iregistry21.IKeeperRegistryMasterUpkeepRegistered: @@ -363,19 +381,19 @@ func (r *EvmRegistry) processUpkeepStateLog(l logpoller.Log) error { trigger := core.GetUpkeepType(*uid) r.lggr.Debugf("KeeperRegistryUpkeepRegistered log detected for upkeep ID %s (trigger=%d) in transaction %s", l.Id.String(), trigger, txHash) r.active.Add(l.Id) - if err := r.updateTriggerConfig(l.Id, nil); err != nil { + if err := r.updateTriggerConfig(l.Id, nil, rawLog.BlockNumber); err != nil { r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepRegistered for upkeep ID %s: %s", err) } case *iregistry21.IKeeperRegistryMasterUpkeepReceived: r.lggr.Debugf("KeeperRegistryUpkeepReceived log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) r.active.Add(l.Id) - if err := r.updateTriggerConfig(l.Id, nil); err != nil { + if err := r.updateTriggerConfig(l.Id, nil, rawLog.BlockNumber); err != nil { r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepReceived for upkeep ID %s: %s", err) } case *iregistry21.IKeeperRegistryMasterUpkeepUnpaused: r.lggr.Debugf("KeeperRegistryUpkeepUnpaused log detected for upkeep ID %s in transaction %s", l.Id.String(), txHash) r.active.Add(l.Id) - if err := r.updateTriggerConfig(l.Id, nil); err != nil { + if err := r.updateTriggerConfig(l.Id, nil, rawLog.BlockNumber); err != nil { r.lggr.Warnf("failed to update trigger config upon KeeperRegistryMasterUpkeepUnpaused for upkeep ID %s: %s", err) } default: @@ -470,7 +488,7 @@ func (r *EvmRegistry) getLatestIDsFromContract(ctx context.Context) ([]*big.Int, return ids, nil } -func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { +func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte, logBlock uint64) error { uid := &ocr2keepers.UpkeepIdentifier{} uid.FromBigInt(id) switch core.GetUpkeepType(*uid) { @@ -486,7 +504,11 @@ func (r *EvmRegistry) updateTriggerConfig(id *big.Int, cfg []byte) error { if err != nil { return errors.Wrap(err, "failed to unpack log upkeep config") } - if err := r.logEventProvider.RegisterFilter(id, logprovider.LogTriggerConfig(parsed)); err != nil { + if err := r.logEventProvider.RegisterFilter(logprovider.FilterOptions{ + TriggerConfig: logprovider.LogTriggerConfig(parsed), + UpkeepID: id, + UpdateBlock: logBlock, + }); err != nil { return errors.Wrap(err, "failed to register log filter") } r.lggr.Debugw("registered log filter", "upkeepID", id.String(), "cfg", parsed) diff --git a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go index ce1ea6e344b..91e422ce949 100644 --- a/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/integration_21_test.go @@ -230,6 +230,7 @@ func TestIntegration_KeeperPluginLogUpkeep(t *testing.T) { t.Run("recover logs", func(t *testing.T) { t.Skip() // TODO: fix test (fails in CI) + addr, contract := addrs[0], contracts[0] upkeepID := registerUpkeep(t, registry, addr, carrol, steve, backend) backend.Commit() @@ -237,7 +238,14 @@ func TestIntegration_KeeperPluginLogUpkeep(t *testing.T) { // blockBeforeEmits := backend.Blockchain().CurrentBlock().Number.Uint64() // Emit 100 logs in a burst emits := 100 - emitEvents(testutils.Context(t), t, 100, []*log_upkeep_counter_wrapper.LogUpkeepCounter{contract}, carrol, func() {}) + i := 0 + emitEvents(testutils.Context(t), t, 100, []*log_upkeep_counter_wrapper.LogUpkeepCounter{contract}, carrol, func() { + i++ + if i%(emits/4) == 0 { + backend.Commit() + time.Sleep(time.Millisecond * 250) // otherwise we get "invalid transaction nonce" errors + } + }) // Mine enough blocks to ensre these logs don't fall into log provider range dummyBlocks := 500 for i := 0; i < dummyBlocks; i++ { From 70af3b1a943312e610141aca0351b51762789d5b Mon Sep 17 00:00:00 2001 From: Patrick Date: Wed, 23 Aug 2023 16:04:01 -0400 Subject: [PATCH 250/270] allow-simple-passwords-changelog-v2.5.0: adding entry (#10318) --- docs/CHANGELOG.md | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 2f787e14b2f..56a76249c68 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,6 +9,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] +### Upcoming Required Configuration Change + +- Starting in 2.6.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: + +``` +AllowSimplePasswords=true +``` + +- To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986) for special character escape rules. + ## 2.4.0 - 2023-08-21 From 6559505eb4efc412791e59ef0fc393e17b11ef17 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Wed, 23 Aug 2023 16:12:01 -0400 Subject: [PATCH 251/270] only check mercury permission for v0.2 (#10302) * handle invalid revert data for mercury * only check mercury permission for v0.2 * update * check empty bytes for registry returns --- .../plugins/ocr2keeper/evm21/feed_lookup.go | 60 +++++++++++------- .../ocr2keeper/evm21/feed_lookup_test.go | 62 +++++++++++-------- 2 files changed, 75 insertions(+), 47 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 500d76954d9..66655c43498 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -99,36 +99,50 @@ func (r *EvmRegistry) feedLookup(ctx context.Context, checkResults []ocr2keepers // Try to decode the revert error into feed lookup format. User upkeeps can revert with any reason, see if they // tried to call mercury - lggr.Infof("upkeep %s block %d trying to decodeFeedLookup performData=%s", upkeepId, block, hexutil.Encode(checkResults[i].PerformData)) - lookup, err := r.decodeFeedLookup(res.PerformData) + lggr.Infof("at block %d upkeep %s trying to decodeFeedLookup performData=%s", block, upkeepId, hexutil.Encode(checkResults[i].PerformData)) + l, err := r.decodeFeedLookup(res.PerformData) if err != nil { lggr.Warnf("upkeep %s block %d decodeFeedLookup failed: %v", upkeepId, block, err) // Not feed lookup error, nothing to do here continue } - opts := r.buildCallOpts(ctx, block) - // TODO: Remove allowlist for v0.3 - state, retryable, allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) - if err != nil { - lggr.Warnf("upkeep %s block %d failed to query mercury allow list: %s", upkeepId, block, err) - checkResults[i].PipelineExecutionState = uint8(state) - checkResults[i].Retryable = retryable + if len(l.feeds) == 0 { + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonInvalidRevertDataInput) + lggr.Warnf("at block %s upkeep %s has empty feeds array", block, upkeepId) continue } + // mercury permission checking for v0.3 is done by mercury server + if l.feedParamKey == feedIdHex && l.timeParamKey == blockNumber { + // check permission on the registry for mercury v0.2 + opts := r.buildCallOpts(ctx, block) + state, reason, retryable, allowed, err := r.allowedToUseMercury(opts, upkeepId.BigInt()) + if err != nil { + lggr.Warnf("at block %s upkeep %s failed to query mercury allow list: %s", block, upkeepId, err) + checkResults[i].PipelineExecutionState = uint8(state) + checkResults[i].IneligibilityReason = uint8(reason) + checkResults[i].Retryable = retryable + continue + } - if !allowed { - lggr.Warnf("upkeep %s block %d NOT allowed to query Mercury server", upkeepId, block) - checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonMercuryAccessNotAllowed) + if !allowed { + lggr.Warnf("at block %d upkeep %s NOT allowed to query Mercury server", block, upkeepId) + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonMercuryAccessNotAllowed) + continue + } + } else if l.feedParamKey != feedIDs || l.timeParamKey != timestamp { + // if mercury version cannot be determined, set failure reason + lggr.Warnf("at block %d upkeep %s NOT allowed to query Mercury server", block, upkeepId) + checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonInvalidRevertDataInput) continue } - lookup.upkeepId = upkeepId.BigInt() + l.upkeepId = upkeepId.BigInt() // the block here is exclusively used to call checkCallback at this block, not to be confused with the block number // in the revert for mercury v0.2, which is denoted by time in the struct bc starting from v0.3, only timestamp will be supported - lookup.block = uint64(block.Int64()) - lggr.Infof("upkeep %s block %d decodeFeedLookup feedKey=%s timeKey=%s feeds=%v time=%s extraData=%s", upkeepId, block, lookup.feedParamKey, lookup.timeParamKey, lookup.feeds, lookup.time, hexutil.Encode(lookup.extraData)) - lookups[i] = lookup + l.block = uint64(block.Int64()) + lggr.Infof("at block %d upkeep %s decodeFeedLookup feedKey=%s timeKey=%s feeds=%v time=%s extraData=%s", block, upkeepId, l.feedParamKey, l.timeParamKey, l.feeds, l.time, hexutil.Encode(l.extraData)) + lookups[i] = l } var wg sync.WaitGroup @@ -193,24 +207,28 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * // allowedToUseMercury retrieves upkeep's administrative offchain config and decode a mercuryEnabled bool to indicate if // this upkeep is allowed to use Mercury service. -func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (state encoding.PipelineExecutionState, retryable bool, allow bool, err error) { +func (r *EvmRegistry) allowedToUseMercury(opts *bind.CallOpts, upkeepId *big.Int) (state encoding.PipelineExecutionState, reason encoding.UpkeepFailureReason, retryable bool, allow bool, err error) { allowed, ok := r.mercury.allowListCache.Get(upkeepId.String()) if ok { - return encoding.NoPipelineError, false, allowed.(bool), nil + return encoding.NoPipelineError, encoding.UpkeepFailureReasonNone, false, allowed.(bool), nil } cfg, err := r.registry.GetUpkeepPrivilegeConfig(opts, upkeepId) if err != nil { - return encoding.RpcFlakyFailure, true, false, fmt.Errorf("failed to get upkeep privilege config for upkeep ID %s: %v", upkeepId, err) + return encoding.RpcFlakyFailure, encoding.UpkeepFailureReasonNone, true, false, fmt.Errorf("failed to get upkeep privilege config: %v", err) + } + if len(cfg) == 0 { + r.mercury.allowListCache.Set(upkeepId.String(), false, cache.DefaultExpiration) + return encoding.NoPipelineError, encoding.UpkeepFailureReasonMercuryAccessNotAllowed, false, false, fmt.Errorf("upkeep privilege config is empty") } var a UpkeepPrivilegeConfig err = json.Unmarshal(cfg, &a) if err != nil { - return encoding.MercuryUnmarshalError, false, false, fmt.Errorf("failed to unmarshal privilege config for upkeep ID %s: %v", upkeepId, err) + return encoding.MercuryUnmarshalError, encoding.UpkeepFailureReasonNone, false, false, fmt.Errorf("failed to unmarshal privilege config: %v", err) } r.mercury.allowListCache.Set(upkeepId.String(), a.MercuryEnabled, cache.DefaultExpiration) - return encoding.NoPipelineError, false, a.MercuryEnabled, nil + return encoding.NoPipelineError, encoding.UpkeepFailureReasonNone, false, a.MercuryEnabled, nil } // decodeFeedLookup decodes the revert error FeedLookup(string feedParamKey, string[] feeds, string feedParamKey, uint256 time, byte[] extraData) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index 9c44c7d5c15..0e7fbe0c1d5 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -267,12 +267,15 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { upkeepId, ok := new(big.Int).SetString("71022726777042968814359024671382968091267501884371696415772139504780367423725", 10) assert.True(t, ok, t.Name()) tests := []struct { - name string - cached bool - allowed bool - errorMessage string - state encoding.PipelineExecutionState - retryable bool + name string + cached bool + allowed bool + ethCallErr error + err error + state encoding.PipelineExecutionState + reason encoding.UpkeepFailureReason + retryable bool + config []byte }{ { name: "success - allowed via cache", @@ -281,7 +284,6 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { }, { name: "success - allowed via fetching privilege config", - cached: false, allowed: true, }, { @@ -291,14 +293,26 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { }, { name: "success - not allowed via fetching privilege config", - cached: false, allowed: false, }, { - name: "failure - cannot unmarshal privilege config", - cached: false, - errorMessage: "failed to unmarshal privilege config for upkeep ID 71022726777042968814359024671382968091267501884371696415772139504780367423725: invalid character '\\x00' looking for beginning of value", - state: encoding.MercuryUnmarshalError, + name: "failure - cannot unmarshal privilege config", + err: fmt.Errorf("failed to unmarshal privilege config: invalid character '\\x00' looking for beginning of value"), + state: encoding.MercuryUnmarshalError, + config: []byte{0, 1}, + }, + { + name: "failure - flaky RPC", + retryable: true, + err: fmt.Errorf("failed to get upkeep privilege config: flaky RPC"), + state: encoding.RpcFlakyFailure, + ethCallErr: fmt.Errorf("flaky RPC"), + }, + { + name: "failure - empty upkeep privilege config", + err: fmt.Errorf("upkeep privilege config is empty"), + reason: encoding.UpkeepFailureReasonMercuryAccessNotAllowed, + config: []byte{}, }, } @@ -306,13 +320,13 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { t.Run(tt.name, func(t *testing.T) { r := setupEVMRegistry(t) - if tt.errorMessage != "" { - mockRegistry := mocks.NewRegistry(t) - mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return([]byte{0, 1}, nil) - r.registry = mockRegistry + if tt.cached { + r.mercury.allowListCache.Set(upkeepId.String(), tt.allowed, cache.DefaultExpiration) } else { - if tt.cached { - r.mercury.allowListCache.Set(upkeepId.String(), tt.allowed, cache.DefaultExpiration) + if tt.err != nil { + mockRegistry := mocks.NewRegistry(t) + mockRegistry.On("GetUpkeepPrivilegeConfig", mock.Anything, upkeepId).Return(tt.config, tt.ethCallErr) + r.registry = mockRegistry } else { mockRegistry := mocks.NewRegistry(t) cfg := UpkeepPrivilegeConfig{MercuryEnabled: tt.allowed} @@ -323,15 +337,11 @@ func TestEvmRegistry_AllowedToUseMercury(t *testing.T) { } } - state, retryable, allowed, err := r.allowedToUseMercury(nil, upkeepId) - if tt.errorMessage != "" { - assert.NotNil(t, err) - assert.Equal(t, tt.errorMessage, err.Error()) - } else { - assert.Nil(t, err) - assert.Equal(t, tt.allowed, allowed) - } + state, reason, retryable, allowed, err := r.allowedToUseMercury(nil, upkeepId) + assert.Equal(t, tt.err, err) + assert.Equal(t, tt.allowed, allowed) assert.Equal(t, tt.state, state) + assert.Equal(t, tt.reason, reason) assert.Equal(t, tt.retryable, retryable) }) } From caa0f03b67959e92257c41d66507b59060f8ae31 Mon Sep 17 00:00:00 2001 From: FelixFan1992 Date: Wed, 23 Aug 2023 17:03:30 -0400 Subject: [PATCH 252/270] update mercury v0.3 path and decode with new response struct (#10316) * handle invalid revert data for mercury * only check mercury permission for v0.2 * update * check empty bytes for registry returns * update mercury v0.3 path and response decoding * update * fix tests * fix tests --- .../ocr2keeper/evm21/encoding/interface.go | 18 +-- .../plugins/ocr2keeper/evm21/feed_lookup.go | 79 ++++++---- .../ocr2keeper/evm21/feed_lookup_test.go | 136 ++++++++++-------- 3 files changed, 138 insertions(+), 95 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go index 3044db4ea11..e896a144aa8 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/encoding/interface.go @@ -31,15 +31,15 @@ const ( UpkeepFailureReasonInvalidRevertDataInput UpkeepFailureReason = 34 // pipeline execution error - NoPipelineError PipelineExecutionState = 0 - CheckBlockTooOld PipelineExecutionState = 1 - CheckBlockInvalid PipelineExecutionState = 2 - RpcFlakyFailure PipelineExecutionState = 3 - MercuryFlakyFailure PipelineExecutionState = 4 - PackUnpackDecodeFailed PipelineExecutionState = 5 - MercuryUnmarshalError PipelineExecutionState = 6 - InvalidMercuryRequest PipelineExecutionState = 7 - FailedToDecodeMercuryResponse PipelineExecutionState = 8 + NoPipelineError PipelineExecutionState = 0 + CheckBlockTooOld PipelineExecutionState = 1 + CheckBlockInvalid PipelineExecutionState = 2 + RpcFlakyFailure PipelineExecutionState = 3 + MercuryFlakyFailure PipelineExecutionState = 4 + PackUnpackDecodeFailed PipelineExecutionState = 5 + MercuryUnmarshalError PipelineExecutionState = 6 + InvalidMercuryRequest PipelineExecutionState = 7 + InvalidMercuryResponse PipelineExecutionState = 8 // this will only happen if Mercury server sends bad responses ) type UpkeepInfo = iregistry21.KeeperRegistryBase21UpkeepInfo diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go index 66655c43498..9bf0de6c1d1 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup.go @@ -38,8 +38,8 @@ const ( headerTimestamp = "X-Authorization-Timestamp" headerSignature = "X-Authorization-Signature-SHA256" headerUpkeepId = "X-Authorization-Upkeep-Id" - mercuryPathV02 = "/client?" // only used to access mercury v0.2 server - mercuryBatchPathV03 = "/v1/reports/bulk?" // only used to access mercury v0.3 server + mercuryPathV02 = "/client?" // only used to access mercury v0.2 server + mercuryBatchPathV03 = "/api/v1/reports/bulk?" // only used to access mercury v0.3 server retryDelay = 500 * time.Millisecond timestamp = "timestamp" // valid for v0.3 totalAttempt = 3 @@ -64,10 +64,14 @@ type MercuryV02Response struct { // MercuryV03Response represents a JSON structure used by Mercury v0.3 type MercuryV03Response struct { - FeedID string `json:"feedID"` + Reports []MercuryV03Report `json:"reports"` +} + +type MercuryV03Report struct { + FeedID string `json:"feedID"` // feed id in hex ValidFromTimestamp string `json:"validFromTimestamp"` ObservationsTimestamp string `json:"observationsTimestamp"` - FullReport string `json:"fullReport"` + FullReport string `json:"fullReport"` // the actual mercury report of this feed, can be sent to verifier } type MercuryData struct { @@ -173,7 +177,7 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * state, retryable, mercuryBytes, err := r.checkCallback(ctx, values, lookup) if err != nil { - lggr.Errorf("upkeep %s block %d checkCallback err: %v", lookup.upkeepId, lookup.block, err) + lggr.Errorf("at block %d upkeep %s checkCallback err: %v", lookup.block, lookup.upkeepId, err) checkResults[i].Retryable = retryable checkResults[i].PipelineExecutionState = uint8(state) return @@ -182,27 +186,27 @@ func (r *EvmRegistry) doLookup(ctx context.Context, wg *sync.WaitGroup, lookup * state, needed, performData, failureReason, _, err := r.packer.UnpackCheckCallbackResult(mercuryBytes) if err != nil { - lggr.Errorf("upkeep %s block %d UnpackCheckCallbackResult err: %v", lookup.upkeepId, lookup.block, err) + lggr.Errorf("at block %d upkeep %s UnpackCheckCallbackResult err: %v", lookup.block, lookup.upkeepId, err) checkResults[i].PipelineExecutionState = uint8(state) return } if failureReason == uint8(encoding.UpkeepFailureReasonMercuryCallbackReverted) { checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonMercuryCallbackReverted) - lggr.Debugf("upkeep %s block %d mercury callback reverts", lookup.upkeepId, lookup.block) + lggr.Debugf("at block %d upkeep %s mercury callback reverts", lookup.block, lookup.upkeepId) return } if !needed { checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonUpkeepNotNeeded) - lggr.Debugf("upkeep %s block %d callback reports upkeep not needed", lookup.upkeepId, lookup.block) + lggr.Debugf("at block %d upkeep %s callback reports upkeep not needed", lookup.block, lookup.upkeepId) return } checkResults[i].IneligibilityReason = uint8(encoding.UpkeepFailureReasonNone) checkResults[i].Eligible = true checkResults[i].PerformData = performData - lggr.Infof("upkeep %s block %d successful with perform data: %s", lookup.upkeepId, lookup.block, hexutil.Encode(performData)) + lggr.Infof("at block %d upkeep %s successful with perform data: %s", lookup.block, lookup.upkeepId, hexutil.Encode(performData)) } // allowedToUseMercury retrieves upkeep's administrative offchain config and decode a mercuryEnabled bool to indicate if @@ -352,43 +356,49 @@ func (r *EvmRegistry) singleFeedRequest(ctx context.Context, ch chan<- MercuryDa retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { - lggr.Warnf("upkeep %s block %s GET request fails for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + lggr.Warnf("at block %s upkeep %s GET request fails for feed %s: %v", ml.time.String(), ml.upkeepId.String(), ml.feeds[index], err1) retryable = true state = encoding.MercuryFlakyFailure return err1 } - defer resp.Body.Close() + defer func(Body io.ReadCloser) { + err = Body.Close() + if err != nil { + lggr.Warnf("failed to close mercury response Body: %s", err) + } + }(resp.Body) + body, err1 := io.ReadAll(resp.Body) if err1 != nil { retryable = false - state = encoding.FailedToDecodeMercuryResponse + state = encoding.InvalidMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { - lggr.Warnf("upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) + lggr.Warnf("at block %s upkeep %s received status code %d for feed %s", ml.time.String(), ml.upkeepId.String(), resp.StatusCode, ml.feeds[index]) retryable = true state = encoding.MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { retryable = false state = encoding.InvalidMercuryRequest - return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for feed %s", ml.upkeepId.String(), ml.time.String(), resp.StatusCode, ml.feeds[index]) + return fmt.Errorf("at block %s upkeep %s received status code %d for feed %s", ml.time.String(), ml.upkeepId.String(), resp.StatusCode, ml.feeds[index]) } var m MercuryV02Response err1 = json.Unmarshal(body, &m) if err1 != nil { - lggr.Warnf("upkeep %s block %s failed to unmarshal body to MercuryV02Response for feed %s: %v", ml.upkeepId.String(), ml.time.String(), ml.feeds[index], err1) + lggr.Warnf("at block %s upkeep %s failed to unmarshal body to MercuryV02Response for feed %s: %v", ml.time.String(), ml.upkeepId.String(), ml.feeds[index], err1) retryable = false state = encoding.MercuryUnmarshalError return err1 } blobBytes, err1 := hexutil.Decode(m.ChainlinkBlob) if err1 != nil { - lggr.Warnf("upkeep %s block %s failed to decode chainlinkBlob %s for feed %s: %v", ml.upkeepId.String(), ml.time.String(), m.ChainlinkBlob, ml.feeds[index], err1) + lggr.Warnf("at block %s upkeep %s failed to decode chainlinkBlob %s for feed %s: %v", ml.time.String(), ml.upkeepId.String(), m.ChainlinkBlob, ml.feeds[index], err1) retryable = false - state = encoding.FailedToDecodeMercuryResponse + state = encoding.InvalidMercuryResponse return err1 } ch <- MercuryData{ @@ -456,46 +466,59 @@ func (r *EvmRegistry) multiFeedsRequest(ctx context.Context, ch chan<- MercuryDa retryable = false resp, err1 := r.hc.Do(req) if err1 != nil { - lggr.Warnf("upkeep %s block %s GET request fails for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + lggr.Warnf("at block %s upkeep %s GET request fails from mercury v0.3: %v", ml.time.String(), ml.upkeepId.String(), err1) retryable = true state = encoding.MercuryFlakyFailure return err1 } - defer resp.Body.Close() + defer func(Body io.ReadCloser) { + err = Body.Close() + if err != nil { + lggr.Warnf("failed to close mercury response Body: %s", err) + } + }(resp.Body) + body, err1 := io.ReadAll(resp.Body) if err1 != nil { retryable = false - state = encoding.FailedToDecodeMercuryResponse + state = encoding.InvalidMercuryResponse return err1 } if resp.StatusCode == http.StatusNotFound || resp.StatusCode == http.StatusInternalServerError { - lggr.Warnf("upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) + lggr.Warnf("at block %s upkeep %s received status code %d from mercury v0.3", ml.time.String(), ml.upkeepId.String(), resp.StatusCode) retryable = true state = encoding.MercuryFlakyFailure return errors.New(strconv.FormatInt(int64(resp.StatusCode), 10)) } else if resp.StatusCode != http.StatusOK { retryable = false state = encoding.InvalidMercuryRequest - return fmt.Errorf("FeedLookup upkeep %s block %s received status code %d for multi feed", ml.upkeepId.String(), ml.time.String(), resp.StatusCode) + return fmt.Errorf("at block %s upkeep %s received status code %d from mercury v0.3", ml.time.String(), ml.upkeepId.String(), resp.StatusCode) } - var responses []MercuryV03Response - err1 = json.Unmarshal(body, &responses) + var response MercuryV03Response + err1 = json.Unmarshal(body, &response) if err1 != nil { - lggr.Warnf("upkeep %s block %s failed to unmarshal body to MercuryV03Response for multi feed: %v", ml.upkeepId.String(), ml.time.String(), err1) + lggr.Warnf("at block %s upkeep %s failed to unmarshal body to MercuryV03Response from mercury v0.3: %v", ml.time.String(), ml.upkeepId.String(), err1) retryable = false state = encoding.MercuryUnmarshalError return err1 } + if len(response.Reports) != len(ml.feeds) { + // this should never happen. if this upkeep does not have permission for any feeds it requests, or if certain feeds are + // missing in mercury server, the mercury server v0.3 should respond with 400s, rather than returning partial results + retryable = false + state = encoding.InvalidMercuryResponse + return fmt.Errorf("at block %s upkeep %s requested %d feeds but received %d reports from mercury v0.3", ml.time.String(), ml.upkeepId.String(), len(ml.feeds), len(response.Reports)) + } var reportBytes [][]byte var b []byte - for _, rsp := range responses { + for _, rsp := range response.Reports { b, err1 = hexutil.Decode(rsp.FullReport) if err1 != nil { - lggr.Warnf("upkeep %s block %s failed to decode reportBlob %s for multi feed: %v", ml.upkeepId.String(), ml.time.String(), rsp.FullReport, err1) + lggr.Warnf("upkeep %s block %s failed to decode fullReport %s from mercury v0.3: %v", ml.upkeepId.String(), ml.time.String(), rsp.FullReport, err1) retryable = false - state = encoding.FailedToDecodeMercuryResponse + state = encoding.InvalidMercuryResponse return err1 } reportBytes = append(reportBytes, b) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go index 0e7fbe0c1d5..a1d7d221b27 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/feed_lookup_test.go @@ -409,7 +409,7 @@ func TestEvmRegistry_DoMercuryRequest(t *testing.T) { mockChainlinkBlobs: []string{"0x00066dfcd1ed2d95b18c948dbc5bd64c687afe93e4ca7d663ddec14c20090ad80000000000000000000000000000000000000000000000000000000000081401000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000e000000000000000000000000000000000000000000000000000000000000002200000000000000000000000000000000000000000000000000000000000000280000100000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001204554482d5553442d415242495452554d2d544553544e455400000000000000000000000000000000000000000000000000000000000000000000000064891c98000000000000000000000000000000000000000000000000000000289ad8d367000000000000000000000000000000000000000000000000000000289acf0b38000000000000000000000000000000000000000000000000000000289b3da40000000000000000000000000000000000000000000000000000000000018ae7ce74d9fa252a8983976eab600dc7590c778d04813430841bc6e765c34cd81a168d00000000000000000000000000000000000000000000000000000000018ae7cb0000000000000000000000000000000000000000000000000000000064891c98000000000000000000000000000000000000000000000000000000000000000260412b94e525ca6cedc9f544fd86f77606d52fe731a5d069dbe836a8bfc0fb8c911963b0ae7a14971f3b4621bffb802ef0605392b9a6c89c7fab1df8633a5ade00000000000000000000000000000000000000000000000000000000000000024500c2f521f83fba5efc2bf3effaaedde43d0a4adff785c1213b712a3aed0d8157642a84324db0cf9695ebd27708d4608eb0337e0dd87b0e43f0fa70c700d911"}, expectedValues: [][]byte{nil}, expectedRetryable: false, - expectedError: errors.New("All attempts fail:\n#1: FeedLookup upkeep 88786950015966611018675766524283132478093844178961698330929478019253453382042 block 25880526 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"), + expectedError: errors.New("All attempts fail:\n#1: at block 25880526 upkeep 88786950015966611018675766524283132478093844178961698330929478019253453382042 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000"), state: encoding.InvalidMercuryRequest, }, { @@ -559,7 +559,7 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { retryNumber: 1, statusCode: http.StatusNotFound, lastStatusCode: http.StatusBadGateway, - errorMessage: "All attempts fail:\n#1: 404\n#2: FeedLookup upkeep 123456789 block 123456 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + errorMessage: "All attempts fail:\n#1: 404\n#2: at block 123456 upkeep 123456789 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", }, { name: "failure - returns not retryable", @@ -573,7 +573,7 @@ func TestEvmRegistry_SingleFeedRequest(t *testing.T) { }, blob: "0xab2123dc", statusCode: http.StatusBadGateway, - errorMessage: "All attempts fail:\n#1: FeedLookup upkeep 123456789 block 123456 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + errorMessage: "All attempts fail:\n#1: at block 123456 upkeep 123456789 received status code 502 for feed 0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", }, } @@ -650,7 +650,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { retryNumber int retryable bool errorMessage string - responses []MercuryV03Response + response MercuryV03Response }{ { name: "success - mercury responds in the first try", @@ -661,20 +661,23 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { time: big.NewInt(123456), upkeepId: upkeepId, }, - responses: []MercuryV03Response{ - { - FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", - ValidFromTimestamp: "123456", - ObservationsTimestamp: "123456", - FullReport: "0xab2123dc00000012", - }, - { - FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", - ValidFromTimestamp: "123458", - ObservationsTimestamp: "123458", - FullReport: "0xab2123dc00000016", + response: MercuryV03Response{ + Reports: []MercuryV03Report{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + { + FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123458", + ObservationsTimestamp: "123458", + FullReport: "0xab2123dc00000016", + }, }, }, + statusCode: http.StatusOK, }, { name: "success - retry for 404", @@ -688,18 +691,20 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { retryNumber: 1, statusCode: http.StatusNotFound, lastStatusCode: http.StatusOK, - responses: []MercuryV03Response{ - { - FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", - ValidFromTimestamp: "123456", - ObservationsTimestamp: "123456", - FullReport: "0xab2123dc00000012", - }, - { - FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", - ValidFromTimestamp: "123458", - ObservationsTimestamp: "123458", - FullReport: "0xab2123dc00000012", + response: MercuryV03Response{ + Reports: []MercuryV03Report{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + { + FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123458", + ObservationsTimestamp: "123458", + FullReport: "0xab2123dc00000012", + }, }, }, }, @@ -715,18 +720,20 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { retryNumber: 2, statusCode: http.StatusInternalServerError, lastStatusCode: http.StatusOK, - responses: []MercuryV03Response{ - { - FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", - ValidFromTimestamp: "123456", - ObservationsTimestamp: "123456", - FullReport: "0xab2123dc00000012", - }, - { - FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", - ValidFromTimestamp: "123458", - ObservationsTimestamp: "123458", - FullReport: "0xab2123dc00000019", + response: MercuryV03Response{ + Reports: []MercuryV03Report{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + { + FeedID: "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123458", + ObservationsTimestamp: "123458", + FullReport: "0xab2123dc00000019", + }, }, }, }, @@ -756,7 +763,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { retryNumber: 1, statusCode: http.StatusNotFound, lastStatusCode: http.StatusBadGateway, - errorMessage: "All attempts fail:\n#1: 404\n#2: FeedLookup upkeep 123456789 block 123456 received status code 502 for multi feed", + errorMessage: "All attempts fail:\n#1: 404\n#2: at block 123456 upkeep 123456789 received status code 502 from mercury v0.3", }, { name: "failure - returns not retryable", @@ -768,7 +775,29 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { upkeepId: upkeepId, }, statusCode: http.StatusBadGateway, - errorMessage: "All attempts fail:\n#1: FeedLookup upkeep 123456789 block 123456 received status code 502 for multi feed", + errorMessage: "All attempts fail:\n#1: at block 123456 upkeep 123456789 received status code 502 from mercury v0.3", + }, + { + name: "failure - reports length does not match feeds length", + lookup: &FeedLookup{ + feedParamKey: feedIDs, + feeds: []string{"0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", "0x4254432d5553442d415242495452554d2d544553544e45540000000000000000"}, + timeParamKey: timestamp, + time: big.NewInt(123456), + upkeepId: upkeepId, + }, + response: MercuryV03Response{ + Reports: []MercuryV03Report{ + { + FeedID: "0x4554482d5553442d415242495452554d2d544553544e45540000000000000000", + ValidFromTimestamp: "123456", + ObservationsTimestamp: "123456", + FullReport: "0xab2123dc00000012", + }, + }, + }, + statusCode: http.StatusOK, + errorMessage: "All attempts fail:\n#1: at block 123456 upkeep 123456789 requested 2 feeds but received 1 reports from mercury v0.3", }, } @@ -776,25 +805,16 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { t.Run(tt.name, func(t *testing.T) { r := setupEVMRegistry(t) hc := mocks.NewHttpClient(t) - - b, err := json.Marshal(tt.responses) + b, err := json.Marshal(tt.response) assert.Nil(t, err) if tt.retryNumber == 0 { - if tt.errorMessage != "" { - resp := &http.Response{ - StatusCode: tt.statusCode, - Body: io.NopCloser(bytes.NewReader(b)), - } - hc.On("Do", mock.Anything).Return(resp, nil).Once() - } else { - resp := &http.Response{ - StatusCode: http.StatusOK, - Body: io.NopCloser(bytes.NewReader(b)), - } - hc.On("Do", mock.Anything).Return(resp, nil).Once() + resp := &http.Response{ + StatusCode: tt.statusCode, + Body: io.NopCloser(bytes.NewReader(b)), } - } else if tt.retryNumber > 0 && tt.retryNumber < totalAttempt { + hc.On("Do", mock.Anything).Return(resp, nil).Once() + } else if tt.retryNumber < totalAttempt { retryResp := &http.Response{ StatusCode: tt.statusCode, Body: io.NopCloser(bytes.NewReader(b)), @@ -828,7 +848,7 @@ func TestEvmRegistry_MultiFeedRequest(t *testing.T) { assert.Nil(t, m.Error) var reports [][]byte var report []byte - for _, rsp := range tt.responses { + for _, rsp := range tt.response.Reports { report, err = hexutil.Decode(rsp.FullReport) assert.Nil(t, err) reports = append(reports, report) From 07781c816b472269714d84739978b1d5c611fe96 Mon Sep 17 00:00:00 2001 From: Austin Born Date: Wed, 23 Aug 2023 14:05:10 -0700 Subject: [PATCH 253/270] Add setConfigFromSource on Verifier contract (#10204) * Add setConfigFromSource to Mercury Verifier contract * Add/update tests * Minor fixes * Prettier formatting * Update wrappers for llo-feeds * Update gas snapshot * Update gas snapshot * Update LLO Feeds snapshot * Remove .gas-snapshot --- .../gas-snapshots/llo-feeds.gas-snapshot | 36 ++--- contracts/src/v0.8/llo-feeds/Verifier.sol | 77 +++++++++- .../v0.8/llo-feeds/interfaces/IVerifier.sol | 26 ++++ .../llo-feeds/test/mocks/ErroredVerifier.sol | 15 ++ .../test/verifier/BaseVerifierTest.t.sol | 3 +- .../VerifierSetConfigFromSourceTest.t.sol | 131 ++++++++++++++++++ .../test/verifier/VerifierSetConfigTest.t.sol | 2 + .../errored_verifier/errored_verifier.go | 26 +++- .../llo-feeds/generated/verifier/verifier.go | 18 ++- ...rapper-dependency-versions-do-not-edit.txt | 4 +- 10 files changed, 312 insertions(+), 26 deletions(-) create mode 100644 contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigFromSourceTest.t.sol diff --git a/contracts/gas-snapshots/llo-feeds.gas-snapshot b/contracts/gas-snapshots/llo-feeds.gas-snapshot index b643c6f8cd8..a5cb93c6f90 100644 --- a/contracts/gas-snapshots/llo-feeds.gas-snapshot +++ b/contracts/gas-snapshots/llo-feeds.gas-snapshot @@ -139,12 +139,12 @@ RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSet() (g RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSetWithInvalidWeights() (gas: 248516) RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForLargerSet() (gas: 241638) RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForSmallerSet() (gas: 239964) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesAMiddleDigest() (gas: 24243) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesTheFirstDigest() (gas: 24210) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyUnsetsDigestsInSequence() (gas: 44316) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfCalledByNonOwner() (gas: 11322) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnEmptyDigest() (gas: 10951) -VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnNonExistentDigest() (gas: 13425) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesAMiddleDigest() (gas: 24221) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesTheFirstDigest() (gas: 24188) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyUnsetsDigestsInSequence() (gas: 44250) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfCalledByNonOwner() (gas: 11300) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnEmptyDigest() (gas: 10929) +VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_revertsIfRemovingAnNonExistentDigest() (gas: 13403) VerifierActivateConfigTest:test_revertsIfDigestIsEmpty() (gas: 10939) VerifierActivateConfigTest:test_revertsIfDigestNotSet() (gas: 13371) VerifierActivateConfigTest:test_revertsIfNotOwner() (gas: 13410) @@ -153,8 +153,8 @@ VerifierActivateFeedTest:test_revertsIfNoFeedExistsActivate() (gas: 13179) VerifierActivateFeedTest:test_revertsIfNoFeedExistsDeactivate() (gas: 13179) VerifierActivateFeedTest:test_revertsIfNotOwnerActivateFeed() (gas: 13360) VerifierActivateFeedTest:test_revertsIfNotOwnerDeactivateFeed() (gas: 13437) -VerifierConstructorTest:test_revertsIfInitializedWithEmptyVerifierProxy() (gas: 59818) -VerifierConstructorTest:test_setsTheCorrectProperties() (gas: 1678828) +VerifierConstructorTest:test_revertsIfInitializedWithEmptyVerifierProxy() (gas: 59939) +VerifierConstructorTest:test_setsTheCorrectProperties() (gas: 1785046) VerifierDeactivateFeedWithVerifyTest:test_currentReportAllowsVerification() (gas: 188309) VerifierDeactivateFeedWithVerifyTest:test_currentReportFailsVerification() (gas: 109640) VerifierDeactivateFeedWithVerifyTest:test_previousReportAllowsVerification() (gas: 95886) @@ -181,16 +181,20 @@ VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest:test_correctlyUnsetsVeri VerifierProxyUnsetVerifierWithPreviouslySetVerifierTest:test_emitsAnEventAfterUnsettingVerifier() (gas: 17965) VerifierProxyVerifyTest:test_proxiesToTheCorrectVerifier() (gas: 200395) VerifierProxyVerifyTest:test_revertsIfNoVerifierConfigured() (gas: 108443) -VerifierSetConfigTest:test_correctlyUpdatesTheConfig() (gas: 1057727) +VerifierSetConfigFromSourceMultipleDigestsTest:test_correctlySetsConfigWhenDigestsAreRemoved() (gas: 538606) +VerifierSetConfigFromSourceMultipleDigestsTest:test_correctlyUpdatesDigestsOnMultipleVerifiersInTheProxy() (gas: 964141) +VerifierSetConfigFromSourceMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 520142) +VerifierSetConfigFromSourceTest:test_revertsIfCalledByNonOwner() (gas: 179332) +VerifierSetConfigTest:test_correctlyUpdatesTheConfig() (gas: 1057626) VerifierSetConfigTest:test_revertsIfCalledByNonOwner() (gas: 179223) -VerifierSetConfigTest:test_revertsIfDuplicateSigners() (gas: 251512) +VerifierSetConfigTest:test_revertsIfDuplicateSigners() (gas: 251573) VerifierSetConfigTest:test_revertsIfFaultToleranceIsZero() (gas: 176522) VerifierSetConfigTest:test_revertsIfNotEnoughSigners() (gas: 15814) VerifierSetConfigTest:test_revertsIfSetWithTooManySigners() (gas: 22170) -VerifierSetConfigTest:test_revertsIfSignerContainsZeroAddress() (gas: 227942) -VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlySetsConfigWhenDigestsAreRemoved() (gas: 538532) -VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesDigestsOnMultipleVerifiersInTheProxy() (gas: 963972) -VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 520054) +VerifierSetConfigTest:test_revertsIfSignerContainsZeroAddress() (gas: 228003) +VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlySetsConfigWhenDigestsAreRemoved() (gas: 538415) +VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesDigestsOnMultipleVerifiersInTheProxy() (gas: 963754) +VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 519945) VerifierSupportsInterfaceTest:test_falseIfIsNotCorrectInterface() (gas: 5590) VerifierSupportsInterfaceTest:test_trueIfIsCorrectInterface() (gas: 5611) VerifierTestBillingReport:test_verifyWithLink() (gas: 274052) @@ -200,7 +204,7 @@ VerifierTestBillingReport:test_verifyWithNativeUnwrappedReturnsChange() (gas: 27 VerifierVerifyMultipleConfigDigestTest:test_canVerifyNewerReportsWithNewerConfigs() (gas: 127500) VerifierVerifyMultipleConfigDigestTest:test_canVerifyOlderReportsWithOlderConfigs() (gas: 183379) VerifierVerifyMultipleConfigDigestTest:test_revertsIfAReportIsVerifiedWithAnExistingButIncorrectDigest() (gas: 84470) -VerifierVerifyMultipleConfigDigestTest:test_revertsIfVerifyingWithAnUnsetDigest() (gas: 124369) +VerifierVerifyMultipleConfigDigestTest:test_revertsIfVerifyingWithAnUnsetDigest() (gas: 124347) VerifierVerifySingleConfigDigestTest:test_emitsAnEventIfReportVerified() (gas: 183237) VerifierVerifySingleConfigDigestTest:test_returnsThePriceAndBlockNumIfReportVerified() (gas: 183406) VerifierVerifySingleConfigDigestTest:test_revertsIfConfigDigestNotSet() (gas: 112459) @@ -212,7 +216,7 @@ VerifierVerifySingleConfigDigestTest:test_revertsIfVerifiedWithIncorrectAddresse VerifierVerifySingleConfigDigestTest:test_revertsIfWrongNumberOfSigners() (gas: 106317) VerifierVerifySingleConfigDigestTest:test_setsTheCorrectEpoch() (gas: 190539) Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 207063) -Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922517) +Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922408) Verifier_verify:testVerifyProxySuccess_gas() (gas: 197508) Verifier_verify:testVerifySuccess_gas() (gas: 182991) Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245475) diff --git a/contracts/src/v0.8/llo-feeds/Verifier.sol b/contracts/src/v0.8/llo-feeds/Verifier.sol index c528ac06ec8..0bc2dee18c8 100644 --- a/contracts/src/v0.8/llo-feeds/Verifier.sol +++ b/contracts/src/v0.8/llo-feeds/Verifier.sol @@ -316,6 +316,70 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { bytes memory offchainConfig, Common.AddressAndWeight[] memory recipientAddressesAndWeights ) external override checkConfigValid(signers.length, f) onlyOwner { + _setConfig( + feedId, + block.chainid, + address(this), + signers, + offchainTransmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig, + recipientAddressesAndWeights + ); + } + + /// @inheritdoc IVerifier + function setConfigFromSource( + bytes32 feedId, + uint256 sourceChainId, + address sourceAddress, + address[] memory signers, + bytes32[] memory offchainTransmitters, + uint8 f, + bytes memory onchainConfig, + uint64 offchainConfigVersion, + bytes memory offchainConfig, + Common.AddressAndWeight[] memory recipientAddressesAndWeights + ) external override checkConfigValid(signers.length, f) onlyOwner { + _setConfig( + feedId, + sourceChainId, + sourceAddress, + signers, + offchainTransmitters, + f, + onchainConfig, + offchainConfigVersion, + offchainConfig, + recipientAddressesAndWeights + ); + } + + /// @notice Sets config based on the given arguments + /// @param feedId Feed ID to set config for + /// @param sourceChainId Chain ID of source config + /// @param sourceAddress Address of source config Verifier + /// @param signers addresses with which oracles sign the reports + /// @param offchainTransmitters CSA key for the ith Oracle + /// @param f number of faulty oracles the system can tolerate + /// @param onchainConfig serialized configuration used by the contract (and possibly oracles) + /// @param offchainConfigVersion version number for offchainEncoding schema + /// @param offchainConfig serialized configuration used by the oracles exclusively and only passed through the contract + /// @param recipientAddressesAndWeights the addresses and weights of all the recipients to receive rewards + function _setConfig( + bytes32 feedId, + uint256 sourceChainId, + address sourceAddress, + address[] memory signers, + bytes32[] memory offchainTransmitters, + uint8 f, + bytes memory onchainConfig, + uint64 offchainConfigVersion, + bytes memory offchainConfig, + Common.AddressAndWeight[] memory recipientAddressesAndWeights + ) internal { VerifierState storage feedVerifierState = s_feedVerifierStates[feedId]; // Increment the number of times a config has been set first @@ -323,6 +387,8 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { bytes32 configDigest = _configDigestFromConfigData( feedId, + sourceChainId, + sourceAddress, feedVerifierState.configCount, signers, offchainTransmitters, @@ -376,6 +442,9 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { } /// @notice Generates the config digest from config data + /// @param feedId Feed ID to set config for + /// @param sourceChainId Chain ID of source config + /// @param sourceAddress Address of source config Verifier /// @param configCount ordinal number of this config setting among all config settings over the life of this contract /// @param signers ith element is address ith oracle uses to sign a report /// @param offchainTransmitters ith element is address ith oracle used to transmit reports (in this case used for flexible additional field, such as CSA pub keys) @@ -386,6 +455,8 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { /// @dev This function is a modified version of the method from OCR2Abstract function _configDigestFromConfigData( bytes32 feedId, + uint256 sourceChainId, + address sourceAddress, uint64 configCount, address[] memory signers, bytes32[] memory offchainTransmitters, @@ -393,13 +464,13 @@ contract Verifier is IVerifier, ConfirmedOwner, TypeAndVersionInterface { bytes memory onchainConfig, uint64 offchainConfigVersion, bytes memory offchainConfig - ) internal view returns (bytes32) { + ) internal pure returns (bytes32) { uint256 h = uint256( keccak256( abi.encode( feedId, - block.chainid, // chainId - address(this), // contractAddress + sourceChainId, + sourceAddress, configCount, signers, offchainTransmitters, diff --git a/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol b/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol index c2bc95cff53..181bf9ad716 100644 --- a/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol +++ b/contracts/src/v0.8/llo-feeds/interfaces/IVerifier.sol @@ -40,6 +40,32 @@ interface IVerifier is IERC165 { Common.AddressAndWeight[] memory recipientAddressesAndWeights ) external; + /** + * @notice identical to `setConfig` except with args for sourceChainId and sourceAddress + * @param feedId Feed ID to set config for + * @param sourceChainId Chain ID of source config + * @param sourceAddress Address of source config Verifier + * @param signers addresses with which oracles sign the reports + * @param offchainTransmitters CSA key for the ith Oracle + * @param f number of faulty oracles the system can tolerate + * @param onchainConfig serialized configuration used by the contract (and possibly oracles) + * @param offchainConfigVersion version number for offchainEncoding schema + * @param offchainConfig serialized configuration used by the oracles exclusively and only passed through the contract + * @param recipientAddressesAndWeights the addresses and weights of all the recipients to receive rewards + */ + function setConfigFromSource( + bytes32 feedId, + uint256 sourceChainId, + address sourceAddress, + address[] memory signers, + bytes32[] memory offchainTransmitters, + uint8 f, + bytes memory onchainConfig, + uint64 offchainConfigVersion, + bytes memory offchainConfig, + Common.AddressAndWeight[] memory recipientAddressesAndWeights + ) external; + /** * @notice Activates the configuration for a config digest * @param feedId Feed ID to activate config for diff --git a/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol b/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol index 13e46f0202b..23ef7c85802 100644 --- a/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol +++ b/contracts/src/v0.8/llo-feeds/test/mocks/ErroredVerifier.sol @@ -42,6 +42,21 @@ contract ErroredVerifier is IVerifier { revert("Failed to set config"); } + function setConfigFromSource( + bytes32, + uint256, + address, + address[] memory, + bytes32[] memory, + uint8, + bytes memory, + uint64, + bytes memory, + Common.AddressAndWeight[] memory + ) external pure override { + revert("Failed to set config"); + } + function activateConfig(bytes32, bytes32) external pure { revert("Failed to activate config"); } diff --git a/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol index 1a604798b1d..cdecb132e7d 100644 --- a/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol @@ -164,6 +164,7 @@ contract BaseTest is Test { function _configDigestFromConfigData( bytes32 feedId, + uint256 chainId, address verifierAddr, uint64 configCount, address[] memory signers, @@ -177,7 +178,7 @@ contract BaseTest is Test { keccak256( abi.encode( feedId, - block.chainid, + chainId, verifierAddr, configCount, signers, diff --git a/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigFromSourceTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigFromSourceTest.t.sol new file mode 100644 index 00000000000..2ba25294168 --- /dev/null +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigFromSourceTest.t.sol @@ -0,0 +1,131 @@ +// SPDX-License-Identifier: UNLICENSED +pragma solidity 0.8.16; + +import {BaseTest, BaseTestWithMultipleConfiguredDigests} from "./BaseVerifierTest.t.sol"; +import {Verifier} from "../../Verifier.sol"; +import {VerifierProxy} from "../../VerifierProxy.sol"; +import {Common} from "../../../libraries/Common.sol"; + +contract VerifierSetConfigFromSourceTest is BaseTest { + function setUp() public virtual override { + BaseTest.setUp(); + } + + function test_revertsIfCalledByNonOwner() public { + vm.expectRevert("Only callable by owner"); + Signer[] memory signers = _getSigners(MAX_ORACLES); + + changePrank(USER); + s_verifier.setConfigFromSource( + FEED_ID, + 12345, + address(12345), + _getSignerAddresses(signers), + s_offchaintransmitters, + FAULT_TOLERANCE, + bytes(""), + VERIFIER_VERSION, + bytes(""), + new Common.AddressAndWeight[](0) + ); + } +} + +contract VerifierSetConfigFromSourceMultipleDigestsTest is BaseTestWithMultipleConfiguredDigests { + function test_correctlyUpdatesTheDigestInTheProxy() public { + Signer[] memory newSigners = _getSigners(15); + + s_verifier.setConfigFromSource( + FEED_ID, + 12345, + address(12345), + _getSignerAddresses(newSigners), + s_offchaintransmitters, + 4, + bytes(""), + VERIFIER_VERSION, + bytes(""), + new Common.AddressAndWeight[](0) + ); + + (, , bytes32 configDigest) = s_verifier.latestConfigDetails(FEED_ID); + address verifierAddr = s_verifierProxy.getVerifier(configDigest); + assertEq(verifierAddr, address(s_verifier)); + } + + function test_correctlyUpdatesDigestsOnMultipleVerifiersInTheProxy() public { + Signer[] memory newSigners = _getSigners(15); + + s_verifier.setConfigFromSource( + FEED_ID_2, + 12345, + address(12345), + _getSignerAddresses(newSigners), + s_offchaintransmitters, + 4, + bytes(""), + VERIFIER_VERSION, + bytes(""), + new Common.AddressAndWeight[](0) + ); + + (, , bytes32 configDigest) = s_verifier.latestConfigDetails(FEED_ID_2); + address verifierAddr = s_verifierProxy.getVerifier(configDigest); + assertEq(verifierAddr, address(s_verifier)); + + s_verifier_2.setConfigFromSource( + FEED_ID_3, + 12345, + address(12345), + _getSignerAddresses(newSigners), + s_offchaintransmitters, + 4, + bytes(""), + VERIFIER_VERSION, + bytes(""), + new Common.AddressAndWeight[](0) + ); + + (, , bytes32 configDigest2) = s_verifier_2.latestConfigDetails(FEED_ID_3); + address verifierAddr2 = s_verifierProxy.getVerifier(configDigest2); + assertEq(verifierAddr2, address(s_verifier_2)); + } + + function test_correctlySetsConfigWhenDigestsAreRemoved() public { + s_verifier.deactivateConfig(FEED_ID, s_configDigestTwo); + + Signer[] memory newSigners = _getSigners(15); + + s_verifier.setConfigFromSource( + FEED_ID, + 12345, + address(s_verifier), + _getSignerAddresses(newSigners), + s_offchaintransmitters, + 4, + bytes(""), + VERIFIER_VERSION, + bytes(""), + new Common.AddressAndWeight[](0) + ); + + bytes32 expectedConfigDigest = _configDigestFromConfigData( + FEED_ID, + 12345, + address(s_verifier), + s_numConfigsSet + 1, + _getSignerAddresses(newSigners), + s_offchaintransmitters, + 4, + bytes(""), + VERIFIER_VERSION, + bytes("") + ); + + (uint32 configCount, uint32 blockNumber, bytes32 configDigest) = s_verifier.latestConfigDetails(FEED_ID); + + assertEq(configCount, s_numConfigsSet + 1); + assertEq(blockNumber, block.number); + assertEq(configDigest, expectedConfigDigest); + } +} diff --git a/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol index ded1da7de62..faa1f98bc30 100644 --- a/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/VerifierSetConfigTest.t.sol @@ -129,6 +129,7 @@ contract VerifierSetConfigTest is BaseTest { bytes32 expectedConfigDigest = _configDigestFromConfigData( FEED_ID, + block.chainid, address(s_verifier), 1, _getSignerAddresses(signers), @@ -223,6 +224,7 @@ contract VerifierSetConfigWhenThereAreMultipleDigestsTest is BaseTestWithMultipl bytes32 expectedConfigDigest = _configDigestFromConfigData( FEED_ID, + block.chainid, address(s_verifier), s_numConfigsSet + 1, _getSignerAddresses(newSigners), diff --git a/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go b/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go index 1f20f46b1a0..d6a52b74fd1 100644 --- a/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go +++ b/core/gethwrappers/llo-feeds/generated/errored_verifier/errored_verifier.go @@ -34,8 +34,8 @@ type CommonAddressAndWeight struct { } var ErroredVerifierMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", - Bin: "0x608060405234801561001057600080fd5b50610ab7806100206000396000f3fe608060405234801561001057600080fd5b50600436106100a35760003560e01c8063564a0a7a11610076578063b70d929d1161005b578063b70d929d14610180578063ded6307c146101b6578063e84f128e146101c957600080fd5b8063564a0a7a1461015a57806394d959801461016d57600080fd5b806301ffc9a7146100a85780633d3ac1b5146101125780633dd864301461013257806352ba27d614610147575b600080fd5b6100fd6100b6366004610571565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b610125610120366004610718565b6101ff565b6040516101099190610766565b6101456101403660046107d2565b610269565b005b61014561015536600461098b565b6102cb565b6101456101683660046107d2565b61032d565b61014561017b366004610a88565b61038f565b61019361018e3660046107d2565b6103f1565b604080519315158452602084019290925263ffffffff1690820152606001610109565b6101456101c4366004610a88565b610480565b6101dc6101d73660046107d2565b6104e2565b6040805163ffffffff948516815293909216602084015290820152606001610109565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4661696c656420746f207665726966790000000000000000000000000000000060448201526060906064015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4661696c656420746f20616374697661746520666565640000000000000000006044820152606401610260565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4661696c656420746f2073657420636f6e6669670000000000000000000000006044820152606401610260565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4661696c656420746f20646561637469766174652066656564000000000000006044820152606401610260565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f4661696c656420746f206465616374697661746520636f6e66696700000000006044820152606401610260565b60008060006040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610260906020808252602c908201527f4661696c656420746f20676574206c617465737420636f6e666967206469676560408201527f737420616e642065706f63680000000000000000000000000000000000000000606082015260800190565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4661696c656420746f20616374697661746520636f6e666967000000000000006044820152606401610260565b60008060006040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102609060208082526023908201527f4661696c656420746f20676574206c617465737420636f6e666967206465746160408201527f696c730000000000000000000000000000000000000000000000000000000000606082015260800190565b60006020828403121561058357600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146105b357600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561060c5761060c6105ba565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610659576106596105ba565b604052919050565b600082601f83011261067257600080fd5b813567ffffffffffffffff81111561068c5761068c6105ba565b6106bd60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601610612565b8181528460208386010111156106d257600080fd5b816020850160208301376000918101602001919091529392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461071357600080fd5b919050565b6000806040838503121561072b57600080fd5b823567ffffffffffffffff81111561074257600080fd5b61074e85828601610661565b92505061075d602084016106ef565b90509250929050565b600060208083528351808285015260005b8181101561079357858101830151858201604001528201610777565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b6000602082840312156107e457600080fd5b5035919050565b600067ffffffffffffffff821115610805576108056105ba565b5060051b60200190565b600082601f83011261082057600080fd5b81356020610835610830836107eb565b610612565b82815260059290921b8401810191818101908684111561085457600080fd5b8286015b8481101561087657610869816106ef565b8352918301918301610858565b509695505050505050565b600082601f83011261089257600080fd5b813560206108a2610830836107eb565b82815260059290921b840181019181810190868411156108c157600080fd5b8286015b8481101561087657803583529183019183016108c5565b803560ff8116811461071357600080fd5b803567ffffffffffffffff8116811461071357600080fd5b600082601f83011261091657600080fd5b81356020610926610830836107eb565b82815260069290921b8401810191818101908684111561094557600080fd5b8286015b8481101561087657604081890312156109625760008081fd5b61096a6105e9565b610973826106ef565b81528185013585820152835291830191604001610949565b600080600080600080600080610100898b0312156109a857600080fd5b88359750602089013567ffffffffffffffff808211156109c757600080fd5b6109d38c838d0161080f565b985060408b01359150808211156109e957600080fd5b6109f58c838d01610881565b9750610a0360608c016108dc565b965060808b0135915080821115610a1957600080fd5b610a258c838d01610661565b9550610a3360a08c016108ed565b945060c08b0135915080821115610a4957600080fd5b610a558c838d01610661565b935060e08b0135915080821115610a6b57600080fd5b50610a788b828c01610905565b9150509295985092959890939650565b60008060408385031215610a9b57600080fd5b5050803592602090910135915056fea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"\",\"type\":\"tuple[]\"}],\"name\":\"setConfigFromSource\",\"outputs\":[],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"\",\"type\":\"bytes\"}],\"stateMutability\":\"pure\",\"type\":\"function\"}]", + Bin: "0x608060405234801561001057600080fd5b50610bf9806100206000396000f3fe608060405234801561001057600080fd5b50600436106100be5760003560e01c806394d9598011610076578063b70d929d1161005b578063b70d929d146101a9578063ded6307c146101df578063e84f128e146101f257600080fd5b806394d95980146101885780639b103f131461019b57600080fd5b80633dd86430116100a75780633dd864301461014d57806352ba27d614610162578063564a0a7a1461017557600080fd5b806301ffc9a7146100c35780633d3ac1b51461012d575b600080fd5b6101186100d136600461059a565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b61014061013b366004610741565b610228565b604051610124919061078f565b61016061015b3660046107fb565b610292565b005b6101606101703660046109b4565b6102f4565b6101606101833660046107fb565b610356565b610160610196366004610ab1565b6103b8565b610160610170366004610ad3565b6101bc6101b73660046107fb565b61041a565b604080519315158452602084019290925263ffffffff1690820152606001610124565b6101606101ed366004610ab1565b6104a9565b6102056102003660046107fb565b61050b565b6040805163ffffffff948516815293909216602084015290820152606001610124565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601060248201527f4661696c656420746f207665726966790000000000000000000000000000000060448201526060906064015b60405180910390fd5b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f4661696c656420746f20616374697661746520666565640000000000000000006044820152606401610289565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601460248201527f4661696c656420746f2073657420636f6e6669670000000000000000000000006044820152606401610289565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4661696c656420746f20646561637469766174652066656564000000000000006044820152606401610289565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601b60248201527f4661696c656420746f206465616374697661746520636f6e66696700000000006044820152606401610289565b60008060006040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610289906020808252602c908201527f4661696c656420746f20676574206c617465737420636f6e666967206469676560408201527f737420616e642065706f63680000000000000000000000000000000000000000606082015260800190565b6040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601960248201527f4661696c656420746f20616374697661746520636f6e666967000000000000006044820152606401610289565b60008060006040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102899060208082526023908201527f4661696c656420746f20676574206c617465737420636f6e666967206465746160408201527f696c730000000000000000000000000000000000000000000000000000000000606082015260800190565b6000602082840312156105ac57600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146105dc57600080fd5b9392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff81118282101715610635576106356105e3565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715610682576106826105e3565b604052919050565b600082601f83011261069b57600080fd5b813567ffffffffffffffff8111156106b5576106b56105e3565b6106e660207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161063b565b8181528460208386010111156106fb57600080fd5b816020850160208301376000918101602001919091529392505050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461073c57600080fd5b919050565b6000806040838503121561075457600080fd5b823567ffffffffffffffff81111561076b57600080fd5b6107778582860161068a565b92505061078660208401610718565b90509250929050565b600060208083528351808285015260005b818110156107bc578581018301518582016040015282016107a0565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60006020828403121561080d57600080fd5b5035919050565b600067ffffffffffffffff82111561082e5761082e6105e3565b5060051b60200190565b600082601f83011261084957600080fd5b8135602061085e61085983610814565b61063b565b82815260059290921b8401810191818101908684111561087d57600080fd5b8286015b8481101561089f5761089281610718565b8352918301918301610881565b509695505050505050565b600082601f8301126108bb57600080fd5b813560206108cb61085983610814565b82815260059290921b840181019181810190868411156108ea57600080fd5b8286015b8481101561089f57803583529183019183016108ee565b803560ff8116811461073c57600080fd5b803567ffffffffffffffff8116811461073c57600080fd5b600082601f83011261093f57600080fd5b8135602061094f61085983610814565b82815260069290921b8401810191818101908684111561096e57600080fd5b8286015b8481101561089f576040818903121561098b5760008081fd5b610993610612565b61099c82610718565b81528185013585820152835291830191604001610972565b600080600080600080600080610100898b0312156109d157600080fd5b88359750602089013567ffffffffffffffff808211156109f057600080fd5b6109fc8c838d01610838565b985060408b0135915080821115610a1257600080fd5b610a1e8c838d016108aa565b9750610a2c60608c01610905565b965060808b0135915080821115610a4257600080fd5b610a4e8c838d0161068a565b9550610a5c60a08c01610916565b945060c08b0135915080821115610a7257600080fd5b610a7e8c838d0161068a565b935060e08b0135915080821115610a9457600080fd5b50610aa18b828c0161092e565b9150509295985092959890939650565b60008060408385031215610ac457600080fd5b50508035926020909101359150565b6000806000806000806000806000806101408b8d031215610af357600080fd5b8a35995060208b01359850610b0a60408c01610718565b975060608b013567ffffffffffffffff80821115610b2757600080fd5b610b338e838f01610838565b985060808d0135915080821115610b4957600080fd5b610b558e838f016108aa565b9750610b6360a08e01610905565b965060c08d0135915080821115610b7957600080fd5b610b858e838f0161068a565b9550610b9360e08e01610916565b94506101008d0135915080821115610baa57600080fd5b610bb68e838f0161068a565b93506101208d0135915080821115610bcd57600080fd5b50610bda8d828e0161092e565b9150509295989b9194979a509295985056fea164736f6c6343000810000a", } var ErroredVerifierABI = ErroredVerifierMetaData.ABI @@ -322,6 +322,26 @@ func (_ErroredVerifier *ErroredVerifierCallerSession) SetConfig(arg0 [32]byte, a return _ErroredVerifier.Contract.SetConfig(&_ErroredVerifier.CallOpts, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7) } +func (_ErroredVerifier *ErroredVerifierCaller) SetConfigFromSource(opts *bind.CallOpts, arg0 [32]byte, arg1 *big.Int, arg2 common.Address, arg3 []common.Address, arg4 [][32]byte, arg5 uint8, arg6 []byte, arg7 uint64, arg8 []byte, arg9 []CommonAddressAndWeight) error { + var out []interface{} + err := _ErroredVerifier.contract.Call(opts, &out, "setConfigFromSource", arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) + + if err != nil { + return err + } + + return err + +} + +func (_ErroredVerifier *ErroredVerifierSession) SetConfigFromSource(arg0 [32]byte, arg1 *big.Int, arg2 common.Address, arg3 []common.Address, arg4 [][32]byte, arg5 uint8, arg6 []byte, arg7 uint64, arg8 []byte, arg9 []CommonAddressAndWeight) error { + return _ErroredVerifier.Contract.SetConfigFromSource(&_ErroredVerifier.CallOpts, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) +} + +func (_ErroredVerifier *ErroredVerifierCallerSession) SetConfigFromSource(arg0 [32]byte, arg1 *big.Int, arg2 common.Address, arg3 []common.Address, arg4 [][32]byte, arg5 uint8, arg6 []byte, arg7 uint64, arg8 []byte, arg9 []CommonAddressAndWeight) error { + return _ErroredVerifier.Contract.SetConfigFromSource(&_ErroredVerifier.CallOpts, arg0, arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8, arg9) +} + func (_ErroredVerifier *ErroredVerifierCaller) SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) { var out []interface{} err := _ErroredVerifier.contract.Call(opts, &out, "supportsInterface", interfaceId) @@ -385,6 +405,8 @@ type ErroredVerifierInterface interface { SetConfig(opts *bind.CallOpts, arg0 [32]byte, arg1 []common.Address, arg2 [][32]byte, arg3 uint8, arg4 []byte, arg5 uint64, arg6 []byte, arg7 []CommonAddressAndWeight) error + SetConfigFromSource(opts *bind.CallOpts, arg0 [32]byte, arg1 *big.Int, arg2 common.Address, arg3 []common.Address, arg4 [][32]byte, arg5 uint8, arg6 []byte, arg7 uint64, arg8 []byte, arg9 []CommonAddressAndWeight) error + SupportsInterface(opts *bind.CallOpts, interfaceId [4]byte) (bool, error) Verify(opts *bind.CallOpts, arg0 []byte, arg1 common.Address) ([]byte, error) diff --git a/core/gethwrappers/llo-feeds/generated/verifier/verifier.go b/core/gethwrappers/llo-feeds/generated/verifier/verifier.go index d234e79e5e6..7830951f646 100644 --- a/core/gethwrappers/llo-feeds/generated/verifier/verifier.go +++ b/core/gethwrappers/llo-feeds/generated/verifier/verifier.go @@ -36,8 +36,8 @@ type CommonAddressAndWeight struct { } var VerifierMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierProxyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"CannotDeactivateLatestConfig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DigestEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestInactive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestNotSet\",\"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\":[],\"name\":\"FeedIdEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InactiveFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"expectedNumSigners\",\"type\":\"uint256\"}],\"name\":\"IncorrectSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InvalidFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rsLength\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"ssLength\",\"type\":\"uint256\"}],\"name\":\"MismatchedSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NonUniqueSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedDeactivated\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"}],\"name\":\"ReportVerified\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"recipientAddressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"isVerifier\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b5060405162002150380380620021508339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051611f55620001fb6000396000818161031d015261091e0152611f556000f3fe608060405234801561001057600080fd5b50600436106100df5760003560e01c806379ba50971161008c578063b70d929d11610066578063b70d929d14610221578063ded6307c14610280578063e84f128e14610293578063f2fde38b146102f057600080fd5b806379ba5097146101de5780638da5cb5b146101e657806394d959801461020e57600080fd5b80633dd86430116100bd5780633dd86430146101a357806352ba27d6146101b8578063564a0a7a146101cb57600080fd5b806301ffc9a7146100e4578063181f5a771461014e5780633d3ac1b514610190575b600080fd5b6101396100f2366004611487565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b60408051808201909152600e81527f566572696669657220312e312e3000000000000000000000000000000000000060208201525b6040516101459190611534565b61018361019e366004611570565b610303565b6101b66101b13660046115f1565b61049d565b005b6101b66101c6366004611902565b61054f565b6101b66101d93660046115f1565b610a3f565b6101b6610b00565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610145565b6101b661021c3660046119ff565b610bfd565b61025d61022f3660046115f1565b6000908152600260205260408120600181015490549192909168010000000000000000900463ffffffff1690565b604080519315158452602084019290925263ffffffff1690820152606001610145565b6101b661028e3660046119ff565b610d5e565b6102cd6102a13660046115f1565b6000908152600260205260409020805460019091015463ffffffff808316936401000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610145565b6101b66102fe366004611a21565b610e6f565b60603373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610374576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080808080610386888a018a611a3c565b9450945094509450945060008461039c90611b17565b60008181526002602052604090208054919250906c01000000000000000000000000900460ff1615610402576040517f36dbe748000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b8651600081815260028301602052604090206104218483898985610e83565b61042b8984610f7f565b87516020890120610440818b8a8a8a87610fe7565b60405173ffffffffffffffffffffffffffffffffffffffff8d16815285907f58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc59060200160405180910390a250969c9b505050505050505050505050565b6104a5611263565b60008181526002602052604081208054909163ffffffff90911690036104fa576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff16815560405182907ff438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b490600090a25050565b86518560ff168060000361058f576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8211156105d4576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f60248201526044016103f9565b6105df816003611bba565b821161063757816105f1826003611bba565b6105fc906001611bf7565b6040517f9dd9e6d8000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b61063f611263565b60008a81526002602052604081208054909163ffffffff90911690829061066583611c10565b82546101009290920a63ffffffff81810219909316918316021790915582546000925061069a918e91168d8d8d8d8d8d6112e6565b6000818152600284016020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8d16176101001790559091505b8b518160ff1610156108db5760008c8260ff168151811061070057610700611b5c565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603610770576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452600190810190925290912054610100900460ff16908111156107c3576107c3611c33565b14801591506107fe576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805180820190915260ff8416815260208101600190526000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684526001908101835292208351815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00821681178355928501519193919284927fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff000090921617906101009084908111156108c0576108c0611c33565b02179055509050505050806108d490611c62565b90506106dd565b5060018201546040517f589ede2800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169163589ede2891610956919085908a90600401611c81565b600060405180830381600087803b15801561097057600080fd5b505af1158015610984573d6000803e3d6000fd5b505050508b7fa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da8360000160049054906101000a900463ffffffff16838560000160009054906101000a900463ffffffff168f8f8f8f8f8f6040516109f099989796959493929190611d78565b60405180910390a281547fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff1664010000000063ffffffff43160217825560019091015550505050505050505050565b610a47611263565b60008181526002602052604081208054909163ffffffff9091169003610a9c576040517fa25b0b96000000000000000000000000000000000000000000000000000000008152600481018390526024016103f9565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff166c0100000000000000000000000017815560405182907ffc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd06190600090a25050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610b81576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064016103f9565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610c05611263565b600082815260026020526040902081610c4a576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610ca0576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b80600101548203610ce7576040517fa403c01600000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555183907f0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c90610d519085815260200190565b60405180910390a2505050565b610d66611263565b600082815260026020526040902081610dab576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610e01576040517f8bca631100000000000000000000000000000000000000000000000000000000815260048101849052602481018390526044016103f9565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555183907f54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe774690610d519085815260200190565b610e77611263565b610e8081611392565b50565b8054600090610e969060ff166001611e0e565b8254909150610100900460ff16610ee3576040517ffc10a28300000000000000000000000000000000000000000000000000000000815260048101879052602481018690526044016103f9565b8060ff16845114610f2f5783516040517f5348a282000000000000000000000000000000000000000000000000000000008152600481019190915260ff821660248201526044016103f9565b8251845114610f7757835183516040517ff0d31408000000000000000000000000000000000000000000000000000000008152600481019290925260248201526044016103f9565b505050505050565b6020820151815463ffffffff600883901c81169168010000000000000000900416811115610fe15782547fffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffff166801000000000000000063ffffffff8316021783555b50505050565b60008686604051602001610ffc929190611e27565b6040516020818303038152906040528051906020012090506000611030604080518082019091526000808252602082015290565b8651600090815b818110156111fb5760018689836020811061105457611054611b5c565b61106191901a601b611e0e565b8c848151811061107357611073611b5c565b60200260200101518c858151811061108d5761108d611b5c565b6020026020010151604051600081526020016040526040516110cb949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa1580156110ed573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526001808d01602090815291859020848601909552845460ff80821686529399509395509085019261010090049091169081111561117257611172611c33565b600181111561118357611183611c33565b90525093506001846020015160018111156111a0576111a0611c33565b146111d7576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836000015160080260ff166001901b85019450806111f490611e63565b9050611037565b50837e01010101010101010101010101010101010101010101010101010101010101851614611256576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff1633146112e4576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103f9565b565b6000808946308b8b8b8b8b8b8b60405160200161130c9a99989796959493929190611e9b565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e060000000000000000000000000000000000000000000000000000000000001791505098975050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603611411576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103f9565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561149957600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146114c957600080fd5b9392505050565b6000815180845260005b818110156114f6576020818501810151868301820152016114da565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006114c960208301846114d0565b803573ffffffffffffffffffffffffffffffffffffffff8116811461156b57600080fd5b919050565b60008060006040848603121561158557600080fd5b833567ffffffffffffffff8082111561159d57600080fd5b818601915086601f8301126115b157600080fd5b8135818111156115c057600080fd5b8760208285010111156115d257600080fd5b6020928301955093506115e89186019050611547565b90509250925092565b60006020828403121561160357600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561165c5761165c61160a565b60405290565b6040516060810167ffffffffffffffff8111828210171561165c5761165c61160a565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156116cc576116cc61160a565b604052919050565b600067ffffffffffffffff8211156116ee576116ee61160a565b5060051b60200190565b600082601f83011261170957600080fd5b8135602061171e611719836116d4565b611685565b82815260059290921b8401810191818101908684111561173d57600080fd5b8286015b8481101561175f5761175281611547565b8352918301918301611741565b509695505050505050565b600082601f83011261177b57600080fd5b8135602061178b611719836116d4565b82815260059290921b840181019181810190868411156117aa57600080fd5b8286015b8481101561175f57803583529183019183016117ae565b803560ff8116811461156b57600080fd5b600082601f8301126117e757600080fd5b813567ffffffffffffffff8111156118015761180161160a565b61183260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611685565b81815284602083860101111561184757600080fd5b816020850160208301376000918101602001919091529392505050565b803567ffffffffffffffff8116811461156b57600080fd5b600082601f83011261188d57600080fd5b8135602061189d611719836116d4565b82815260069290921b840181019181810190868411156118bc57600080fd5b8286015b8481101561175f57604081890312156118d95760008081fd5b6118e1611639565b6118ea82611547565b815281850135858201528352918301916040016118c0565b600080600080600080600080610100898b03121561191f57600080fd5b88359750602089013567ffffffffffffffff8082111561193e57600080fd5b61194a8c838d016116f8565b985060408b013591508082111561196057600080fd5b61196c8c838d0161176a565b975061197a60608c016117c5565b965060808b013591508082111561199057600080fd5b61199c8c838d016117d6565b95506119aa60a08c01611864565b945060c08b01359150808211156119c057600080fd5b6119cc8c838d016117d6565b935060e08b01359150808211156119e257600080fd5b506119ef8b828c0161187c565b9150509295985092959890939650565b60008060408385031215611a1257600080fd5b50508035926020909101359150565b600060208284031215611a3357600080fd5b6114c982611547565b600080600080600060e08688031215611a5457600080fd5b86601f870112611a6357600080fd5b611a6b611662565b806060880189811115611a7d57600080fd5b885b81811015611a97578035845260209384019301611a7f565b5090965035905067ffffffffffffffff80821115611ab457600080fd5b611ac089838a016117d6565b95506080880135915080821115611ad657600080fd5b611ae289838a0161176a565b945060a0880135915080821115611af857600080fd5b50611b058882890161176a565b9598949750929560c001359392505050565b80516020808301519190811015611b56577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611bf257611bf2611b8b565b500290565b80820180821115611c0a57611c0a611b8b565b92915050565b600063ffffffff808316818103611c2957611c29611b8b565b6001019392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b600060ff821660ff8103611c7857611c78611b8b565b60010192915050565b600060608201858352602085818501526040606081860152828651808552608087019150838801945060005b81811015611ce8578551805173ffffffffffffffffffffffffffffffffffffffff168452850151858401529484019491830191600101611cad565b50909998505050505050505050565b600081518084526020808501945080840160005b83811015611d3d57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101611d0b565b509495945050505050565b600081518084526020808501945080840160005b83811015611d3d57815187529582019590820190600101611d5c565b600061012063ffffffff808d1684528b6020850152808b16604085015250806060840152611da88184018a611cf7565b90508281036080840152611dbc8189611d48565b905060ff871660a084015282810360c0840152611dd981876114d0565b905067ffffffffffffffff851660e0840152828103610100840152611dfe81856114d0565b9c9b505050505050505050505050565b60ff8181168382160190811115611c0a57611c0a611b8b565b828152600060208083018460005b6003811015611e5257815183529183019190830190600101611e35565b505050506080820190509392505050565b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611e9457611e94611b8b565b5060010190565b60006101408c83528b602084015273ffffffffffffffffffffffffffffffffffffffff8b16604084015267ffffffffffffffff808b166060850152816080850152611ee88285018b611cf7565b915083820360a0850152611efc828a611d48565b915060ff881660c085015283820360e0850152611f1982886114d0565b9086166101008501528381036101208501529050611f3781856114d0565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"verifierProxyAddr\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"AccessForbidden\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"BadVerification\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"CannotDeactivateLatestConfig\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"DigestEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestInactive\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"DigestNotSet\",\"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\":[],\"name\":\"FeedIdEmpty\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InactiveFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"expectedNumSigners\",\"type\":\"uint256\"}],\"name\":\"IncorrectSignatureCount\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"numSigners\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"minSigners\",\"type\":\"uint256\"}],\"name\":\"InsufficientSigners\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"InvalidFeed\",\"type\":\"error\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"rsLength\",\"type\":\"uint256\"},{\"internalType\":\"uint256\",\"name\":\"ssLength\",\"type\":\"uint256\"}],\"name\":\"MismatchedSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NonUniqueSignatures\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroAddress\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"ConfigDeactivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint32\",\"name\":\"previousConfigBlockNumber\",\"type\":\"uint32\"},{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"configCount\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"indexed\":false,\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"indexed\":false,\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"indexed\":false,\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"indexed\":false,\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"}],\"name\":\"ConfigSet\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedActivated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"FeedDeactivated\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"requester\",\"type\":\"address\"}],\"name\":\"ReportVerified\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"activateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"activateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"deactivateConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"deactivateFeed\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDetails\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"configCount\",\"type\":\"uint32\"},{\"internalType\":\"uint32\",\"name\":\"blockNumber\",\"type\":\"uint32\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"}],\"name\":\"latestConfigDigestAndEpoch\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"scanLogs\",\"type\":\"bool\"},{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"internalType\":\"uint32\",\"name\":\"epoch\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"recipientAddressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setConfig\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"uint256\",\"name\":\"sourceChainId\",\"type\":\"uint256\"},{\"internalType\":\"address\",\"name\":\"sourceAddress\",\"type\":\"address\"},{\"internalType\":\"address[]\",\"name\":\"signers\",\"type\":\"address[]\"},{\"internalType\":\"bytes32[]\",\"name\":\"offchainTransmitters\",\"type\":\"bytes32[]\"},{\"internalType\":\"uint8\",\"name\":\"f\",\"type\":\"uint8\"},{\"internalType\":\"bytes\",\"name\":\"onchainConfig\",\"type\":\"bytes\"},{\"internalType\":\"uint64\",\"name\":\"offchainConfigVersion\",\"type\":\"uint64\"},{\"internalType\":\"bytes\",\"name\":\"offchainConfig\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"recipientAddressesAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setConfigFromSource\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"isVerifier\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"signedReport\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"sender\",\"type\":\"address\"}],\"name\":\"verify\",\"outputs\":[{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"}],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162002362380380620023628339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163d92e233d60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051612167620001fb6000396000818161033b01526112cf01526121676000f3fe608060405234801561001057600080fd5b50600436106100ea5760003560e01c80638da5cb5b1161008c578063b70d929d11610066578063b70d929d1461023f578063ded6307c1461029e578063e84f128e146102b1578063f2fde38b1461030e57600080fd5b80638da5cb5b146101f157806394d95980146102195780639b103f131461022c57600080fd5b80633dd86430116100c85780633dd86430146101ae57806352ba27d6146101c3578063564a0a7a146101d657806379ba5097146101e957600080fd5b806301ffc9a7146100ef578063181f5a77146101595780633d3ac1b51461019b575b600080fd5b6101446100fd366004611580565b7fffffffff00000000000000000000000000000000000000000000000000000000167f3d3ac1b5000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b60408051808201909152600e81527f566572696669657220312e312e3000000000000000000000000000000000000060208201525b604051610150919061162d565b61018e6101a9366004611669565b610321565b6101c16101bc3660046116ea565b6104bb565b005b6101c16101d13660046119fb565b61056d565b6101c16101e43660046116ea565b61067b565b6101c161073c565b60005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610150565b6101c1610227366004611af8565b610839565b6101c161023a366004611b1a565b61099a565b61027b61024d3660046116ea565b6000908152600260205260408120600181015490549192909168010000000000000000900463ffffffff1690565b604080519315158452602084019290925263ffffffff1690820152606001610150565b6101c16102ac366004611af8565b610a64565b6102eb6102bf3660046116ea565b6000908152600260205260409020805460019091015463ffffffff808316936401000000009093041691565b6040805163ffffffff948516815293909216602084015290820152606001610150565b6101c161031c366004611c33565b610b75565b60603373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614610392576040517fef67f5d800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000808080806103a4888a018a611c4e565b945094509450945094506000846103ba90611d29565b60008181526002602052604090208054919250906c01000000000000000000000000900460ff1615610420576040517f36dbe748000000000000000000000000000000000000000000000000000000008152600481018390526024015b60405180910390fd5b86516000818152600283016020526040902061043f8483898985610b89565b6104498984610c85565b8751602089012061045e818b8a8a8a87610ced565b60405173ffffffffffffffffffffffffffffffffffffffff8d16815285907f58ca9502e98a536e06e72d680fcc251e5d10b72291a281665a2c2dc0ac30fcc59060200160405180910390a250969c9b505050505050505050505050565b6104c3610f69565b60008181526002602052604081208054909163ffffffff9091169003610518576040517fa25b0b9600000000000000000000000000000000000000000000000000000000815260048101839052602401610417565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff16815560405182907ff438564f793525caa89c6e3a26d41e16aa39d1e589747595751e3f3df75cb2b490600090a25050565b86518560ff16806000036105ad576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f8211156105f2576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f6024820152604401610417565b6105fd816003611dcc565b8211610655578161060f826003611dcc565b61061a906001611e09565b6040517f9dd9e6d800000000000000000000000000000000000000000000000000000000815260048101929092526024820152604401610417565b61065d610f69565b61066f8a46308c8c8c8c8c8c8c610fec565b50505050505050505050565b610683610f69565b60008181526002602052604081208054909163ffffffff90911690036106d8576040517fa25b0b9600000000000000000000000000000000000000000000000000000000815260048101839052602401610417565b80547fffffffffffffffffffffffffffffffffffffff00ffffffffffffffffffffffff166c0100000000000000000000000017815560405182907ffc4f79b8c65b6be1773063461984c0974400d1e99654c79477a092ace83fd06190600090a25050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146107bd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e6572000000000000000000006044820152606401610417565b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b610841610f69565b600082815260026020526040902081610886576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff1690036108dc576040517f8bca63110000000000000000000000000000000000000000000000000000000081526004810184905260248101839052604401610417565b80600101548203610923576040517fa403c0160000000000000000000000000000000000000000000000000000000081526004810184905260248101839052604401610417565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff1690555183907f0e173bea63a8c59ec70bf87043f2a729693790183f16a1a54b705de9e989cc4c9061098d9085815260200190565b60405180910390a2505050565b86518560ff16806000036109da576040517f0743bae600000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b601f821115610a1f576040517f61750f4000000000000000000000000000000000000000000000000000000000815260048101839052601f6024820152604401610417565b610a2a816003611dcc565b8211610a3c578161060f826003611dcc565b610a44610f69565b610a568c8c8c8c8c8c8c8c8c8c610fec565b505050505050505050505050565b610a6c610f69565b600082815260026020526040902081610ab1576040517fe332262700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600082815260028201602052604081205460ff169003610b07576040517f8bca63110000000000000000000000000000000000000000000000000000000081526004810184905260248101839052604401610417565b60008281526002820160205260409081902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00ff166101001790555183907f54f8872b9b94ebea6577f33576d55847bd8ea22641ccc886b965f6e50bfe77469061098d9085815260200190565b610b7d610f69565b610b86816113dd565b50565b8054600090610b9c9060ff166001611e22565b8254909150610100900460ff16610be9576040517ffc10a2830000000000000000000000000000000000000000000000000000000081526004810187905260248101869052604401610417565b8060ff16845114610c355783516040517f5348a282000000000000000000000000000000000000000000000000000000008152600481019190915260ff82166024820152604401610417565b8251845114610c7d57835183516040517ff0d3140800000000000000000000000000000000000000000000000000000000815260048101929092526024820152604401610417565b505050505050565b6020820151815463ffffffff600883901c81169168010000000000000000900416811115610ce75782547fffffffffffffffffffffffffffffffffffffffff00000000ffffffffffffffff166801000000000000000063ffffffff8316021783555b50505050565b60008686604051602001610d02929190611e3b565b6040516020818303038152906040528051906020012090506000610d36604080518082019091526000808252602082015290565b8651600090815b81811015610f0157600186898360208110610d5a57610d5a611d6e565b610d6791901a601b611e22565b8c8481518110610d7957610d79611d6e565b60200260200101518c8581518110610d9357610d93611d6e565b602002602001015160405160008152602001604052604051610dd1949392919093845260ff9290921660208401526040830152606082015260800190565b6020604051602081039080840390855afa158015610df3573d6000803e3d6000fd5b5050604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081015173ffffffffffffffffffffffffffffffffffffffff811660009081526001808d01602090815291859020848601909552845460ff808216865293995093955090850192610100900490911690811115610e7857610e78611e77565b6001811115610e8957610e89611e77565b9052509350600184602001516001811115610ea657610ea6611e77565b14610edd576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b836000015160080260ff166001901b8501945080610efa90611ea6565b9050610d3d565b50837e01010101010101010101010101010101010101010101010101010101010101851614610f5c576040517f4df18f0700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610fea576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e6572000000000000000000006044820152606401610417565b565b60008a81526002602052604081208054909163ffffffff90911690829061101283611ede565b82546101009290920a63ffffffff81810219909316918316021790915582546000925061104b918e918e918e91168d8d8d8d8d8d6114d2565b6000818152600284016020526040812080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00001660ff8b16176101001790559091505b89518160ff16101561128c5760008a8260ff16815181106110b1576110b1611d6e565b60200260200101519050600073ffffffffffffffffffffffffffffffffffffffff168173ffffffffffffffffffffffffffffffffffffffff1603611121576040517fd92e233d00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000806000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff87168452600190810190925290912054610100900460ff169081111561117457611174611e77565b14801591506111af576040517ff67bc7c400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805180820190915260ff8416815260208101600190526000858152600287016020908152604080832073ffffffffffffffffffffffffffffffffffffffff871684526001908101835292208351815460ff9091167fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff00821681178355928501519193919284927fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0000909216179061010090849081111561127157611271611e77565b021790555090505050508061128590611f01565b905061108e565b5060018201546040517f589ede2800000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169163589ede2891611307919085908890600401611f20565b600060405180830381600087803b15801561132157600080fd5b505af1158015611335573d6000803e3d6000fd5b505083546040518f93507fa23a88453230b183877098801ff5a8f771a120e2573eea559ce6c4c2e305a4da925061138e9163ffffffff6401000000008204811692879291909116908f908f908f908f908f908f90612017565b60405180910390a281547fffffffffffffffffffffffffffffffffffffffff0000000000000000ffffffff1664010000000063ffffffff43160217825560019091015550505050505050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361145c576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c660000000000000000006044820152606401610417565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000808b8b8b8b8b8b8b8b8b8b6040516020016114f89a999897969594939291906120ad565b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe081840301815291905280516020909101207dffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff167e06000000000000000000000000000000000000000000000000000000000000179150509a9950505050505050505050565b60006020828403121561159257600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146115c257600080fd5b9392505050565b6000815180845260005b818110156115ef576020818501810151868301820152016115d3565b5060006020828601015260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010191505092915050565b6020815260006115c260208301846115c9565b803573ffffffffffffffffffffffffffffffffffffffff8116811461166457600080fd5b919050565b60008060006040848603121561167e57600080fd5b833567ffffffffffffffff8082111561169657600080fd5b818601915086601f8301126116aa57600080fd5b8135818111156116b957600080fd5b8760208285010111156116cb57600080fd5b6020928301955093506116e19186019050611640565b90509250925092565b6000602082840312156116fc57600080fd5b5035919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040805190810167ffffffffffffffff8111828210171561175557611755611703565b60405290565b6040516060810167ffffffffffffffff8111828210171561175557611755611703565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156117c5576117c5611703565b604052919050565b600067ffffffffffffffff8211156117e7576117e7611703565b5060051b60200190565b600082601f83011261180257600080fd5b81356020611817611812836117cd565b61177e565b82815260059290921b8401810191818101908684111561183657600080fd5b8286015b848110156118585761184b81611640565b835291830191830161183a565b509695505050505050565b600082601f83011261187457600080fd5b81356020611884611812836117cd565b82815260059290921b840181019181810190868411156118a357600080fd5b8286015b8481101561185857803583529183019183016118a7565b803560ff8116811461166457600080fd5b600082601f8301126118e057600080fd5b813567ffffffffffffffff8111156118fa576118fa611703565b61192b60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161177e565b81815284602083860101111561194057600080fd5b816020850160208301376000918101602001919091529392505050565b803567ffffffffffffffff8116811461166457600080fd5b600082601f83011261198657600080fd5b81356020611996611812836117cd565b82815260069290921b840181019181810190868411156119b557600080fd5b8286015b8481101561185857604081890312156119d25760008081fd5b6119da611732565b6119e382611640565b815281850135858201528352918301916040016119b9565b600080600080600080600080610100898b031215611a1857600080fd5b88359750602089013567ffffffffffffffff80821115611a3757600080fd5b611a438c838d016117f1565b985060408b0135915080821115611a5957600080fd5b611a658c838d01611863565b9750611a7360608c016118be565b965060808b0135915080821115611a8957600080fd5b611a958c838d016118cf565b9550611aa360a08c0161195d565b945060c08b0135915080821115611ab957600080fd5b611ac58c838d016118cf565b935060e08b0135915080821115611adb57600080fd5b50611ae88b828c01611975565b9150509295985092959890939650565b60008060408385031215611b0b57600080fd5b50508035926020909101359150565b6000806000806000806000806000806101408b8d031215611b3a57600080fd5b8a35995060208b01359850611b5160408c01611640565b975060608b013567ffffffffffffffff80821115611b6e57600080fd5b611b7a8e838f016117f1565b985060808d0135915080821115611b9057600080fd5b611b9c8e838f01611863565b9750611baa60a08e016118be565b965060c08d0135915080821115611bc057600080fd5b611bcc8e838f016118cf565b9550611bda60e08e0161195d565b94506101008d0135915080821115611bf157600080fd5b611bfd8e838f016118cf565b93506101208d0135915080821115611c1457600080fd5b50611c218d828e01611975565b9150509295989b9194979a5092959850565b600060208284031215611c4557600080fd5b6115c282611640565b600080600080600060e08688031215611c6657600080fd5b86601f870112611c7557600080fd5b611c7d61175b565b806060880189811115611c8f57600080fd5b885b81811015611ca9578035845260209384019301611c91565b5090965035905067ffffffffffffffff80821115611cc657600080fd5b611cd289838a016118cf565b95506080880135915080821115611ce857600080fd5b611cf489838a01611863565b945060a0880135915080821115611d0a57600080fd5b50611d1788828901611863565b9598949750929560c001359392505050565b80516020808301519190811015611d68577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611e0457611e04611d9d565b500290565b80820180821115611e1c57611e1c611d9d565b92915050565b60ff8181168382160190811115611e1c57611e1c611d9d565b828152600060208083018460005b6003811015611e6657815183529183019190830190600101611e49565b505050506080820190509392505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611ed757611ed7611d9d565b5060010190565b600063ffffffff808316818103611ef757611ef7611d9d565b6001019392505050565b600060ff821660ff8103611f1757611f17611d9d565b60010192915050565b600060608201858352602085818501526040606081860152828651808552608087019150838801945060005b81811015611f87578551805173ffffffffffffffffffffffffffffffffffffffff168452850151858401529484019491830191600101611f4c565b50909998505050505050505050565b600081518084526020808501945080840160005b83811015611fdc57815173ffffffffffffffffffffffffffffffffffffffff1687529582019590820190600101611faa565b509495945050505050565b600081518084526020808501945080840160005b83811015611fdc57815187529582019590820190600101611ffb565b600061012063ffffffff808d1684528b6020850152808b166040850152508060608401526120478184018a611f96565b9050828103608084015261205b8189611fe7565b905060ff871660a084015282810360c084015261207881876115c9565b905067ffffffffffffffff851660e084015282810361010084015261209d81856115c9565b9c9b505050505050505050505050565b60006101408c83528b602084015273ffffffffffffffffffffffffffffffffffffffff8b16604084015267ffffffffffffffff808b1660608501528160808501526120fa8285018b611f96565b915083820360a085015261210e828a611fe7565b915060ff881660c085015283820360e085015261212b82886115c9565b908616610100850152838103610120850152905061214981856115c9565b9d9c5050505050505050505050505056fea164736f6c6343000810000a", } var VerifierABI = VerifierMetaData.ABI @@ -376,6 +376,18 @@ func (_Verifier *VerifierTransactorSession) SetConfig(feedId [32]byte, signers [ return _Verifier.Contract.SetConfig(&_Verifier.TransactOpts, feedId, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) } +func (_Verifier *VerifierTransactor) SetConfigFromSource(opts *bind.TransactOpts, feedId [32]byte, sourceChainId *big.Int, sourceAddress common.Address, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _Verifier.contract.Transact(opts, "setConfigFromSource", feedId, sourceChainId, sourceAddress, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) +} + +func (_Verifier *VerifierSession) SetConfigFromSource(feedId [32]byte, sourceChainId *big.Int, sourceAddress common.Address, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _Verifier.Contract.SetConfigFromSource(&_Verifier.TransactOpts, feedId, sourceChainId, sourceAddress, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) +} + +func (_Verifier *VerifierTransactorSession) SetConfigFromSource(feedId [32]byte, sourceChainId *big.Int, sourceAddress common.Address, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) { + return _Verifier.Contract.SetConfigFromSource(&_Verifier.TransactOpts, feedId, sourceChainId, sourceAddress, signers, offchainTransmitters, f, onchainConfig, offchainConfigVersion, offchainConfig, recipientAddressesAndWeights) +} + func (_Verifier *VerifierTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { return _Verifier.contract.Transact(opts, "transferOwnership", to) } @@ -1544,6 +1556,8 @@ type VerifierInterface interface { SetConfig(opts *bind.TransactOpts, feedId [32]byte, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + SetConfigFromSource(opts *bind.TransactOpts, feedId [32]byte, sourceChainId *big.Int, sourceAddress common.Address, signers []common.Address, offchainTransmitters [][32]byte, f uint8, onchainConfig []byte, offchainConfigVersion uint64, offchainConfig []byte, recipientAddressesAndWeights []CommonAddressAndWeight) (*types.Transaction, error) + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) Verify(opts *bind.TransactOpts, signedReport []byte, sender common.Address) (*types.Transaction, error) diff --git a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt index c50d38674a5..2b62ac60b84 100644 --- a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,9 +1,9 @@ GETH_VERSION: 1.12.0 -errored_verifier: ../../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../../contracts/solc/v0.8.16/ErroredVerifier.bin eeae445bed26b9da9c0659d138e810964bd9f667eaf02515ae23c185a3ac0adc +errored_verifier: ../../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../../contracts/solc/v0.8.16/ErroredVerifier.bin 1b0a03b90137d31fceb340b80ade65a4ed52fa63c5caf24183ce3f63567d818f exposed_verifier: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 fee_manager: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin d5674bbad7231fc588dc8c9d1f803fedb649ba7355b3c5ab11f9810c5c839a6b llo_feeds: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin cb71e018f67e49d7bc0e194c822204dfd59f79ff42e4fc8fd8ab63f3acd71361 llo_feeds_test: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 reward_manager: ../../../contracts/solc/v0.8.16/RewardManager.abi ../../../contracts/solc/v0.8.16/RewardManager.bin 1694433bbcf39684ec105b3b1d9478f7158165c97b711483f1f4f4fa4eb61364 -verifier: ../../../contracts/solc/v0.8.16/Verifier.abi ../../../contracts/solc/v0.8.16/Verifier.bin 8518b13062166f7102d031f82a841573ca4d89eb27e96d633503e49302b75b47 +verifier: ../../../contracts/solc/v0.8.16/Verifier.abi ../../../contracts/solc/v0.8.16/Verifier.bin 3c9b047bd96056a8bf85c0a1e928044c1166c58c4bd6986975100877ff43f1ec verifier_proxy: ../../../contracts/solc/v0.8.16/VerifierProxy.abi ../../../contracts/solc/v0.8.16/VerifierProxy.bin 64c61227ccc947171c35c5cd5dc664c492fbe2139fdfee70d4941a0109261341 From 7d59eb21963e7ffc0f9b11c45a1021aa8050e2b0 Mon Sep 17 00:00:00 2001 From: Tate Date: Wed, 23 Aug 2023 16:22:11 -0600 Subject: [PATCH 254/270] Add More E2E Test Dependencies To Cache (#10313) --- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 +-- .github/workflows/ci-core.yml | 2 +- .github/workflows/generic-test-runner.yml | 6 +-- .github/workflows/integration-chaos-tests.yml | 6 +-- .github/workflows/integration-tests.yml | 41 +++++++++++-------- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/performance-tests.yml | 2 +- 8 files changed, 37 insertions(+), 30 deletions(-) diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index e8e4556a85f..3113d74e6f1 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -107,7 +107,7 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 env: DETACH_RUNNER: true TEST_SUITE: benchmark diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index b22a53b88ee..baf507143f9 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -49,7 +49,7 @@ jobs: - name: Check if image exists if: inputs.chainlinkImage == '' id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 #v2.2.9 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -57,7 +57,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' && inputs.chainlinkImage == '' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -160,7 +160,7 @@ jobs: echo "version=develop" >>$GITHUB_OUTPUT fi - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 #v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 env: PYROSCOPE_SERVER: ${{ matrix.tests.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.tests.pyroscope_env }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 9278ea418cd..3904c729cbb 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -180,7 +180,7 @@ jobs: run: ./tools/bin/${{ matrix.cmd }} "${{ matrix.split.pkgs }}" - name: Print Filtered Test Results if: failure() - uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: results-file: ./output.txt output-file: ./output-short.txt diff --git a/.github/workflows/generic-test-runner.yml b/.github/workflows/generic-test-runner.yml index 0ec9b21abed..e6e862703f6 100644 --- a/.github/workflows/generic-test-runner.yml +++ b/.github/workflows/generic-test-runner.yml @@ -53,7 +53,7 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 #v2.2.9 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -61,7 +61,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -126,7 +126,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 1h -count=1 ./${{ github.event.inputs.directory }} -run ${{ github.event.inputs.test }} -v -args ${{ github.event.inputs.test-inputs }} test_download_vendor_packages_command: cd ./integration-tests && go mod download diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index 2b47b21b759..724b5581676 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -30,7 +30,7 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: repository: chainlink tag: ${{ github.sha }} @@ -38,7 +38,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -109,7 +109,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_command_to_run: make test_need_operator_assets && cd integration-tests && go test -timeout 1h -count=1 -json -test.parallel 11 ./chaos 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 113bcbc57a7..38bb5e7f62b 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -21,6 +21,7 @@ env: TEST_SUITE: smoke TEST_ARGS: -test.timeout 12m INTERNAL_DOCKER_REPO: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com + MOD_CACHE_VERSION: 2 jobs: changes: @@ -174,7 +175,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -190,7 +191,7 @@ jobs: publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -199,11 +200,11 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -392,7 +393,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 env: PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} @@ -407,7 +408,7 @@ jobs: publish_check_name: EVM Smoke Test Results ${{ matrix.product.name }} token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -415,11 +416,11 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -469,7 +470,7 @@ jobs: eth-smoke-go-mod-cache: environment: integration needs: [eth-smoke-tests] - runs-on: ubuntu-latest + runs-on: ubuntu20.04-16cores-64GB name: ETH Smoke Tests Go Mod Cache steps: - name: Checkout the repo @@ -477,11 +478,15 @@ jobs: with: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} - name: Run Setup - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: - test_download_vendor_packages_command: cd ./integration-tests && go mod download + test_download_vendor_packages_command: | + cd ./integration-tests + go mod download + # force download of test dependencies + go test -run=NonExistentTest ./smoke/... || echo "ignore expected test failure" go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} cache_restore_only: 'false' ### Migration tests @@ -521,7 +526,7 @@ jobs: run: | echo "Running migration tests from version '${{ steps.get_latest_version.outputs.latest_version }}' to: '${{ github.sha }}'" - name: Run Migration Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json ./migration 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download @@ -531,6 +536,8 @@ jobs: publish_check_name: Node Migration Test Results token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} + cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} @@ -758,7 +765,7 @@ jobs: ref: ${{ needs.get_solana_sha.outputs.sha }} - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_command_to_run: export ENV_JOB_IMAGE=${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/chainlink-solana-tests:${{ needs.get_solana_sha.outputs.sha }} && make test_smoke cl_repo: ${{ env.CHAINLINK_IMAGE }} @@ -766,7 +773,7 @@ jobs: artifacts_location: /home/runner/work/chainlink-solana/chainlink-solana/integration-tests/logs publish_check_name: Solana Smoke Test Results go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-solana-e2e-${{ env.MOD_CACHE_VERSION }} token: ${{ secrets.GITHUB_TOKEN }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} @@ -821,7 +828,7 @@ jobs: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} ## Only run OCR smoke test for now - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 env: PYROSCOPE_SERVER: ${{ secrets.QA_PYROSCOPE_INSTANCE }} PYROSCOPE_ENVIRONMENT: ci-smoke-ocr-evm-${{ matrix.testnet }} # TODO: Only for OCR for now @@ -836,7 +843,7 @@ jobs: publish_check_name: ${{ matrix.testnet }} OCR Smoke Test Results token: ${{ secrets.GITHUB_TOKEN }} go_mod_path: ./integration-tests/go.mod - cache_key_id: core-e2e + cache_key_id: core-e2e-${{ env.MOD_CACHE_VERSION }} cache_restore_only: 'true' QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 9f6dafc0dac..532c5bdef58 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -121,7 +121,7 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 env: DETACH_RUNNER: true TEST_SUITE: soak diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index ad4dbfb63b3..57b337db995 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -57,7 +57,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@260e9b8a4c78d8c1fa6693a0e7144b40e41c7a35 # v2.2.9 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 with: test_command_to_run: cd integration-tests && go test -timeout 1h -count=1 -json -test.parallel 10 ./performance 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: make gomod From f1c9ec7ecfc3008f92c6df6b85dc10779289d5d9 Mon Sep 17 00:00:00 2001 From: Chunkai Yang Date: Thu, 24 Aug 2023 00:46:03 -0400 Subject: [PATCH 255/270] Include shared folder in gethwrapper generation (#10321) --- core/gethwrappers/go_generate.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/core/gethwrappers/go_generate.go b/core/gethwrappers/go_generate.go index 54531aa6bbd..6249e3385e0 100644 --- a/core/gethwrappers/go_generate.go +++ b/core/gethwrappers/go_generate.go @@ -134,6 +134,9 @@ package gethwrappers // Mercury //go:generate go generate ./llo-feeds +// Shared +//go:generate go generate ./shared + // Mocks that contain only events and functions to emit them // These contracts are used in testing Atlas flows. The contracts contain no logic, only events, structures, and functions to emit them. // The flow is as follows: From 7b1c1015a2bc391bb5ab7b02e4519d0e3e4297c2 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Thu, 24 Aug 2023 10:51:10 +0100 Subject: [PATCH 256/270] Improvements to log buffer dequeueRange (#10315) * Improvements to log buffer dequeueRange * add log * fix tests * fix test * limit latest block * fix bug * fix tests * comment out log * style --- .../ocr2keeper/evm21/logprovider/buffer.go | 64 +++++++------------ .../evm21/logprovider/buffer_test.go | 60 +++++++++++------ .../ocr2keeper/evm21/logprovider/provider.go | 8 +-- 3 files changed, 67 insertions(+), 65 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go index a8f3d64f058..1977795f6e8 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer.go @@ -126,7 +126,7 @@ func (b *logEventBuffer) enqueue(id *big.Int, logs ...logpoller.Log) int { "blockHash", log.BlockHash, "txHash", log.TxHash, "logIndex", log.LogIndex) continue } - // lggr.Debugw("Adding log", "i", i, "blockBlock", block.blockNumber, "logBlock", log.BlockNumber, "id", id) + // lggr.Debugw("Adding log", "i", i, "blockBlock", currentBlock.blockNumber, "logBlock", log.BlockNumber, "id", id) currentBlock.logs = append(currentBlock.logs, fetchedLog{upkeepID: id, log: log}) b.blocks[i] = currentBlock added++ @@ -183,18 +183,6 @@ func (b *logEventBuffer) peekRange(start, end int64) []fetchedLog { return results } -// peek returns the logs in range [latestBlock-blocks, latestBlock] -func (b *logEventBuffer) dequeue(blocks, upkeepLimit int) []fetchedLog { - latestBlock := b.latestBlockSeen() - if latestBlock == 0 { - return nil - } - if blocks > int(latestBlock) { - blocks = int(latestBlock) - 1 - } - return b.dequeueRange(latestBlock-int64(blocks), latestBlock, upkeepLimit) -} - // dequeueRange returns the logs between start and end inclusive. func (b *logEventBuffer) dequeueRange(start, end int64, upkeepLimit int) []fetchedLog { b.lock.Lock() @@ -203,9 +191,8 @@ func (b *logEventBuffer) dequeueRange(start, end int64, upkeepLimit int) []fetch blocksInRange := b.getBlocksInRange(int(start), int(end)) logsCount := map[string]int{} - var results []fetchedLog - for i, block := range blocksInRange { + for _, block := range blocksInRange { // double checking that we don't have any gaps in the range if block.blockNumber < start || block.blockNumber > end { continue @@ -225,7 +212,7 @@ func (b *logEventBuffer) dequeueRange(start, end int64, upkeepLimit int) []fetch block.visited = append(block.visited, blockResults...) results = append(results, blockResults...) block.logs = remainingLogs - b.blocks[i] = block + b.blocks[b.blockNumberIndex(block.blockNumber)] = block } sort.SliceStable(results, func(i, j int) bool { @@ -243,49 +230,42 @@ func (b *logEventBuffer) dequeueRange(start, end int64, upkeepLimit int) []fetch // NOTE: this function should be called with the lock held func (b *logEventBuffer) getBlocksInRange(start, end int) []fetchedBlock { var blocksInRange []fetchedBlock - start, end = b.normalRange(start, end) + start, end = b.blockRangeToIndices(start, end) if start == -1 || end == -1 { // invalid range return blocksInRange } - if start < end { - return b.blocks[start:end] + if start <= end { + // Normal range, need to return indices from start to end(inclusive) + return b.blocks[start : end+1] } // in case we get circular range such as [0, 1, end, ... , start, ..., size-1] - // we need to return the blocks in two ranges: [start, size-1] and [0, end] + // we need to return the blocks in two ranges: [0, end](inclusive) and [start, size-1] blocksInRange = append(blocksInRange, b.blocks[start:]...) - blocksInRange = append(blocksInRange, b.blocks[:end]...) + blocksInRange = append(blocksInRange, b.blocks[:end+1]...) return blocksInRange } -// normalRange returns the normalized range of start and end, -// aligned with buffer sizes. -func (b *logEventBuffer) normalRange(start, end int) (int, int) { - if end < start || end == 0 { +// blockRangeToIndices returns the normalized range of start to end block range, +// to indices aligned with buffer size. Note ranges inclusive of start, end indices. +func (b *logEventBuffer) blockRangeToIndices(start, end int) (int, int) { + latest := b.latestBlockSeen() + if end > int(latest) { + // Limit end of range to latest block seen + end = int(latest) + } + if end < start || start == 0 || end == 0 { // invalid range return -1, -1 } size := b.bufferSize() - if start == 0 { - // we reduce start by 1 to make it easier to calculate the index, - // but we need to ensure we don't go below 0. - start++ - } - if start == end { - // ensure we have at least one block in range as end is exclusive - // TODO: verify if we really need to do this here or if this can be removed safely - // as start is aligned in line 285 - end++ - } - if end-start > size { - // ensure we don't have more than the buffer size + if end-start >= size { + // If range requires more than buffer size blocks, only to return + // last size blocks as that's the max the buffer stores. start = (end - size) + 1 } - start = (start - 1) % size - end = end % size - - return start, end + return b.blockNumberIndex(int64(start)), b.blockNumberIndex(int64(end)) } // blockNumberIndex returns the index of the block in the buffer diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go index cec34b9649b..de68dd31e22 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/buffer_test.go @@ -14,11 +14,10 @@ import ( func TestLogEventBuffer_GetBlocksInRange(t *testing.T) { size := 3 + maxSeenBlock := int64(4) buf := newLogEventBuffer(logger.TestLogger(t), size, 10, 10) buf.enqueue(big.NewInt(1), - logpoller.Log{BlockNumber: 1, TxHash: common.HexToHash("0x1"), LogIndex: 0}, - logpoller.Log{BlockNumber: 1, TxHash: common.HexToHash("0x1"), LogIndex: 1}, logpoller.Log{BlockNumber: 2, TxHash: common.HexToHash("0x2"), LogIndex: 0}, logpoller.Log{BlockNumber: 3, TxHash: common.HexToHash("0x3"), LogIndex: 0}, ) @@ -26,6 +25,8 @@ func TestLogEventBuffer_GetBlocksInRange(t *testing.T) { buf.enqueue(big.NewInt(2), logpoller.Log{BlockNumber: 2, TxHash: common.HexToHash("0x2"), LogIndex: 2}, logpoller.Log{BlockNumber: 3, TxHash: common.HexToHash("0x3"), LogIndex: 2}, + logpoller.Log{BlockNumber: 4, TxHash: common.HexToHash("0x1"), LogIndex: 0}, + logpoller.Log{BlockNumber: 4, TxHash: common.HexToHash("0x1"), LogIndex: 1}, ) tests := []struct { @@ -36,27 +37,26 @@ func TestLogEventBuffer_GetBlocksInRange(t *testing.T) { }{ { name: "all", - from: 1, - to: 3, + from: 2, + to: 4, want: 3, }, { name: "partial", - from: 1, - to: 2, + from: 2, + to: 3, want: 2, }, { name: "circular", - from: 2, + from: 3, to: 4, - want: 3, + want: 2, }, { name: "zero start", from: 0, to: 2, - want: 2, }, { name: "invalid zero end", @@ -68,6 +68,17 @@ func TestLogEventBuffer_GetBlocksInRange(t *testing.T) { from: 4, to: 2, }, + { + name: "outside max last seen", + from: 5, + to: 10, + }, + { + name: "limited by max last seen", + from: 2, + to: 5, + want: 3, + }, } for _, tc := range tests { @@ -76,15 +87,10 @@ func TestLogEventBuffer_GetBlocksInRange(t *testing.T) { require.Equal(t, tc.want, len(blocks)) if tc.want > 0 { from := tc.from - if from == 0 { - from++ - } require.Equal(t, from, blocks[0].blockNumber) to := tc.to - if to == 0 { - to++ - } else if to > int64(size) { - to = to % int64(size) + if to >= maxSeenBlock { + to = maxSeenBlock } require.Equal(t, to, blocks[len(blocks)-1].blockNumber) } @@ -250,7 +256,7 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { results := buf.peek(8) require.Equal(t, 4, len(results)) verifyBlockNumbers(t, results, 1, 2, 3, 3) - removed := buf.dequeue(8, 5) + removed := buf.dequeueRange(1, 3, 5) require.Equal(t, 4, len(removed)) buf.lock.Lock() require.Equal(t, 0, len(buf.blocks[0].logs)) @@ -292,7 +298,7 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { logpoller.Log{BlockNumber: 2, TxHash: common.HexToHash("0x2"), LogIndex: 0}, logpoller.Log{BlockNumber: 3, TxHash: common.HexToHash("0x3"), LogIndex: 0}, ), 2) - results := buf.peekRange(int64(0), int64(5)) + results := buf.peekRange(int64(1), int64(5)) fmt.Println(results) verifyBlockNumbers(t, results, 2, 3, 4, 4) }) @@ -307,9 +313,25 @@ func TestLogEventBuffer_EnqueueDequeue(t *testing.T) { logpoller.Log{BlockNumber: 5, TxHash: common.HexToHash("0x5"), LogIndex: 0}, ), 5) - logs := buf.dequeue(10, 2) + logs := buf.dequeueRange(1, 5, 2) require.Equal(t, 2, len(logs)) }) + t.Run("dequeue doesn't return same logs again", func(t *testing.T) { + buf := newLogEventBuffer(logger.TestLogger(t), 3, 5, 10) + require.Equal(t, buf.enqueue(big.NewInt(1), + logpoller.Log{BlockNumber: 1, TxHash: common.HexToHash("0x1"), LogIndex: 0}, + logpoller.Log{BlockNumber: 2, TxHash: common.HexToHash("0x2"), LogIndex: 0}, + logpoller.Log{BlockNumber: 3, TxHash: common.HexToHash("0x3"), LogIndex: 0}, + ), 3) + + logs := buf.dequeueRange(3, 3, 2) + fmt.Println(logs) + require.Equal(t, 1, len(logs)) + + logs = buf.dequeueRange(3, 3, 2) + fmt.Println(logs) + require.Equal(t, 0, len(logs)) + }) } func verifyBlockNumbers(t *testing.T, logs []fetchedLog, bns ...int64) { diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go index 576971c0a7f..377315a69eb 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/provider.go @@ -172,11 +172,11 @@ func (p *logEventProvider) GetLatestPayloads(ctx context.Context) ([]ocr2keepers if err != nil { return nil, fmt.Errorf("%w: %s", ErrHeadNotAvailable, err) } - diff := latest - p.opts.LookbackBlocks - if diff < 0 { - diff = latest + start := latest - p.opts.LookbackBlocks + if start <= 0 { + start = 1 } - logs := p.buffer.dequeue(int(diff), AllowedLogsPerUpkeep) + logs := p.buffer.dequeueRange(start, latest, AllowedLogsPerUpkeep) // p.lggr.Debugw("got latest logs from buffer", "latest", latest, "diff", diff, "logs", len(logs)) From a59fe1f2903d7d70ac3a6bbd93bab245c304175b Mon Sep 17 00:00:00 2001 From: Michael Fletcher <36506122+Fletch153@users.noreply.github.com> Date: Thu, 24 Aug 2023 11:18:06 +0100 Subject: [PATCH 257/270] Update schema definitions (#10293) * Update schema definitions * Update gas snapshot * Removed unused event and fix test function sigs * regenerate go wrappers * gas snapshots --- .../gas-snapshots/llo-feeds.gas-snapshot | 112 +++++++++--------- .../src/v0.8/llo-feeds/dev/FeeManager.sol | 22 +--- .../test/fee-manager/BaseFeeManager.t.sol | 33 +++--- .../fee-manager/FeeManager.processFee.t.sol | 6 +- .../test/verifier/BaseVerifierTest.t.sol | 42 +++---- .../generated/fee_manager/fee_manager.go | 4 +- ...rapper-dependency-versions-do-not-edit.txt | 2 +- 7 files changed, 103 insertions(+), 118 deletions(-) diff --git a/contracts/gas-snapshots/llo-feeds.gas-snapshot b/contracts/gas-snapshots/llo-feeds.gas-snapshot index a5cb93c6f90..e865fa0164e 100644 --- a/contracts/gas-snapshots/llo-feeds.gas-snapshot +++ b/contracts/gas-snapshots/llo-feeds.gas-snapshot @@ -1,70 +1,70 @@ -FeeManagerProcessFeeTest:test_DiscountIsAppliedForNative() (gas: 47654) +FeeManagerProcessFeeTest:test_DiscountIsAppliedForNative() (gas: 47380) FeeManagerProcessFeeTest:test_V1PayloadVerifies() (gas: 17377) -FeeManagerProcessFeeTest:test_V2PayloadVerifies() (gas: 104591) -FeeManagerProcessFeeTest:test_V2PayloadWithoutQuoteFails() (gas: 19950) -FeeManagerProcessFeeTest:test_V2PayloadWithoutZeroFee() (gas: 62375) +FeeManagerProcessFeeTest:test_V2PayloadVerifies() (gas: 104525) +FeeManagerProcessFeeTest:test_V2PayloadWithoutQuoteFails() (gas: 19972) +FeeManagerProcessFeeTest:test_V2PayloadWithoutZeroFee() (gas: 62309) FeeManagerProcessFeeTest:test_WithdrawERC20() (gas: 62862) FeeManagerProcessFeeTest:test_WithdrawNonAdminAddr() (gas: 48655) FeeManagerProcessFeeTest:test_WithdrawUnwrappedNative() (gas: 20266) -FeeManagerProcessFeeTest:test_baseFeeIsAppliedForLink() (gas: 15021) -FeeManagerProcessFeeTest:test_baseFeeIsAppliedForNative() (gas: 17517) -FeeManagerProcessFeeTest:test_correctDiscountIsAppliedWhenBothTokensAreDiscounted() (gas: 83916) -FeeManagerProcessFeeTest:test_discountAIsNotAppliedWhenSetForOtherUsers() (gas: 51279) -FeeManagerProcessFeeTest:test_discountFeeRoundsDownWhenUneven() (gas: 47800) -FeeManagerProcessFeeTest:test_discountIsAppliedForLink() (gas: 45109) -FeeManagerProcessFeeTest:test_discountIsAppliedWith100PercentSurcharge() (gas: 71303) -FeeManagerProcessFeeTest:test_discountIsNoLongerAppliedAfterRemoving() (gas: 41064) +FeeManagerProcessFeeTest:test_baseFeeIsAppliedForLink() (gas: 14747) +FeeManagerProcessFeeTest:test_baseFeeIsAppliedForNative() (gas: 17243) +FeeManagerProcessFeeTest:test_correctDiscountIsAppliedWhenBothTokensAreDiscounted() (gas: 83368) +FeeManagerProcessFeeTest:test_discountAIsNotAppliedWhenSetForOtherUsers() (gas: 51005) +FeeManagerProcessFeeTest:test_discountFeeRoundsDownWhenUneven() (gas: 47526) +FeeManagerProcessFeeTest:test_discountIsAppliedForLink() (gas: 44835) +FeeManagerProcessFeeTest:test_discountIsAppliedWith100PercentSurcharge() (gas: 71029) +FeeManagerProcessFeeTest:test_discountIsNoLongerAppliedAfterRemoving() (gas: 40625) FeeManagerProcessFeeTest:test_discountIsNotAppliedForInvalidTokenAddress() (gas: 12439) -FeeManagerProcessFeeTest:test_discountIsNotAppliedToOtherFeeds() (gas: 49326) +FeeManagerProcessFeeTest:test_discountIsNotAppliedToOtherFeeds() (gas: 49052) FeeManagerProcessFeeTest:test_emptyQuoteRevertsWithError() (gas: 12305) FeeManagerProcessFeeTest:test_eventIsEmittedAfterSurchargeIsSet() (gas: 36250) FeeManagerProcessFeeTest:test_eventIsEmittedUponWithdraw() (gas: 59974) -FeeManagerProcessFeeTest:test_feeIsUpdatedAfterDiscountIsRemoved() (gas: 43550) -FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewDiscountIsApplied() (gas: 60124) -FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewSurchargeIsApplied() (gas: 56407) -FeeManagerProcessFeeTest:test_feeIsZeroWith100PercentDiscount() (gas: 47510) -FeeManagerProcessFeeTest:test_getBaseRewardWithLinkQuote() (gas: 15064) -FeeManagerProcessFeeTest:test_getLinkFeeIsRoundedUp() (gas: 45278) -FeeManagerProcessFeeTest:test_getLinkRewardIsRoundedDown() (gas: 45180) -FeeManagerProcessFeeTest:test_getLinkRewardWithNativeQuoteAndSurchargeWithLinkDiscount() (gas: 74934) -FeeManagerProcessFeeTest:test_getRewardWithLinkDiscount() (gas: 45087) -FeeManagerProcessFeeTest:test_getRewardWithLinkQuoteAndLinkDiscount() (gas: 45110) -FeeManagerProcessFeeTest:test_getRewardWithNativeQuote() (gas: 17540) -FeeManagerProcessFeeTest:test_getRewardWithNativeQuoteAndSurcharge() (gas: 45608) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterDiscountIsRemoved() (gas: 43112) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewDiscountIsApplied() (gas: 59576) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewSurchargeIsApplied() (gas: 55859) +FeeManagerProcessFeeTest:test_feeIsZeroWith100PercentDiscount() (gas: 47236) +FeeManagerProcessFeeTest:test_getBaseRewardWithLinkQuote() (gas: 14790) +FeeManagerProcessFeeTest:test_getLinkFeeIsRoundedUp() (gas: 45004) +FeeManagerProcessFeeTest:test_getLinkRewardIsRoundedDown() (gas: 44906) +FeeManagerProcessFeeTest:test_getLinkRewardWithNativeQuoteAndSurchargeWithLinkDiscount() (gas: 74660) +FeeManagerProcessFeeTest:test_getRewardWithLinkDiscount() (gas: 44813) +FeeManagerProcessFeeTest:test_getRewardWithLinkQuoteAndLinkDiscount() (gas: 44836) +FeeManagerProcessFeeTest:test_getRewardWithNativeQuote() (gas: 17266) +FeeManagerProcessFeeTest:test_getRewardWithNativeQuoteAndSurcharge() (gas: 45334) FeeManagerProcessFeeTest:test_linkAvailableForPaymentReturnsLinkBalance() (gas: 47416) -FeeManagerProcessFeeTest:test_nativeSurcharge0Percent() (gas: 25630) -FeeManagerProcessFeeTest:test_nativeSurcharge100Percent() (gas: 45644) +FeeManagerProcessFeeTest:test_nativeSurcharge0Percent() (gas: 25356) +FeeManagerProcessFeeTest:test_nativeSurcharge100Percent() (gas: 45370) FeeManagerProcessFeeTest:test_nativeSurchargeCannotExceed100Percent() (gas: 12085) FeeManagerProcessFeeTest:test_nativeSurchargeEventIsEmittedOnUpdate() (gas: 36252) -FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFee() (gas: 47172) -FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFeeAndDiscountAndSurchargeIsSet() (gas: 70762) -FeeManagerProcessFeeTest:test_nonAdminProxyUserCannotProcessFee() (gas: 19062) +FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFee() (gas: 46898) +FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFeeAndDiscountAndSurchargeIsSet() (gas: 70488) +FeeManagerProcessFeeTest:test_nonAdminProxyUserCannotProcessFee() (gas: 19084) FeeManagerProcessFeeTest:test_nonAdminUserCanNotSetDiscount() (gas: 14751) -FeeManagerProcessFeeTest:test_processFeeAsProxy() (gas: 105088) -FeeManagerProcessFeeTest:test_processFeeDefaultReportsStillVerifiesWithEmptyQuote() (gas: 18170) -FeeManagerProcessFeeTest:test_processFeeEmitsEventIfNotEnoughLink() (gas: 121568) +FeeManagerProcessFeeTest:test_processFeeAsProxy() (gas: 104814) +FeeManagerProcessFeeTest:test_processFeeDefaultReportsStillVerifiesWithEmptyQuote() (gas: 18192) +FeeManagerProcessFeeTest:test_processFeeEmitsEventIfNotEnoughLink() (gas: 121316) FeeManagerProcessFeeTest:test_processFeeIfSubscriberIsSelf() (gas: 19197) -FeeManagerProcessFeeTest:test_processFeeNative() (gas: 154869) -FeeManagerProcessFeeTest:test_processFeeUsesCorrectDigest() (gas: 106112) -FeeManagerProcessFeeTest:test_processFeeWithDefaultReportPayloadAndQuoteStillVerifies() (gas: 20509) -FeeManagerProcessFeeTest:test_processFeeWithInvalidReportVersion() (gas: 21997) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNative() (gas: 159309) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeLinkAddress() (gas: 68253) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeShortFunds() (gas: 72784) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeWithExcessiveFee() (gas: 166315) -FeeManagerProcessFeeTest:test_processFeeWithWithCorruptQuotePayload() (gas: 19786) -FeeManagerProcessFeeTest:test_processFeeWithWithEmptyQuotePayload() (gas: 20264) +FeeManagerProcessFeeTest:test_processFeeNative() (gas: 154595) +FeeManagerProcessFeeTest:test_processFeeUsesCorrectDigest() (gas: 105773) +FeeManagerProcessFeeTest:test_processFeeWithDefaultReportPayloadAndQuoteStillVerifies() (gas: 20531) +FeeManagerProcessFeeTest:test_processFeeWithInvalidReportVersionFailsToDecode() (gas: 22031) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNative() (gas: 159057) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeLinkAddress() (gas: 68001) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeShortFunds() (gas: 72532) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeWithExcessiveFee() (gas: 166041) +FeeManagerProcessFeeTest:test_processFeeWithWithCorruptQuotePayload() (gas: 19808) +FeeManagerProcessFeeTest:test_processFeeWithWithEmptyQuotePayload() (gas: 20286) FeeManagerProcessFeeTest:test_processFeeWithWithZeroQuotePayload() (gas: 21226) FeeManagerProcessFeeTest:test_reportWithNoExpiryOrFeeReturnsZero() (gas: 10966) FeeManagerProcessFeeTest:test_setDiscountOver100Percent() (gas: 14453) FeeManagerProcessFeeTest:test_subscriberDiscountEventIsEmittedOnUpdate() (gas: 41119) -FeeManagerProcessFeeTest:test_surchargeFeeRoundsUpWhenUneven() (gas: 45937) -FeeManagerProcessFeeTest:test_surchargeIsApplied() (gas: 45905) -FeeManagerProcessFeeTest:test_surchargeIsAppliedForNativeFeeWithDiscount() (gas: 71618) -FeeManagerProcessFeeTest:test_surchargeIsNoLongerAppliedAfterRemoving() (gas: 40744) -FeeManagerProcessFeeTest:test_surchargeIsNotAppliedForLinkFee() (gas: 45125) -FeeManagerProcessFeeTest:test_surchargeIsNotAppliedWith100PercentDiscount() (gas: 71116) -FeeManagerProcessFeeTest:test_testRevertIfReportHasExpired() (gas: 15561) +FeeManagerProcessFeeTest:test_surchargeFeeRoundsUpWhenUneven() (gas: 45663) +FeeManagerProcessFeeTest:test_surchargeIsApplied() (gas: 45631) +FeeManagerProcessFeeTest:test_surchargeIsAppliedForNativeFeeWithDiscount() (gas: 71344) +FeeManagerProcessFeeTest:test_surchargeIsNoLongerAppliedAfterRemoving() (gas: 40305) +FeeManagerProcessFeeTest:test_surchargeIsNotAppliedForLinkFee() (gas: 44851) +FeeManagerProcessFeeTest:test_surchargeIsNotAppliedWith100PercentDiscount() (gas: 70842) +FeeManagerProcessFeeTest:test_testRevertIfReportHasExpired() (gas: 15287) RewardManagerClaimTest:test_claimAllRecipients() (gas: 257750) RewardManagerClaimTest:test_claimMultipleRecipients() (gas: 143154) RewardManagerClaimTest:test_claimRewardsWithDuplicatPoolIdsDoesNotPayoutTwice() (gas: 306046) @@ -197,10 +197,10 @@ VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesDigestsOnM VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 519945) VerifierSupportsInterfaceTest:test_falseIfIsNotCorrectInterface() (gas: 5590) VerifierSupportsInterfaceTest:test_trueIfIsCorrectInterface() (gas: 5611) -VerifierTestBillingReport:test_verifyWithLink() (gas: 274052) -VerifierTestBillingReport:test_verifyWithNative() (gas: 252372) -VerifierTestBillingReport:test_verifyWithNativeUnwrapped() (gas: 263437) -VerifierTestBillingReport:test_verifyWithNativeUnwrappedReturnsChange() (gas: 270504) +VerifierTestBillingReport:test_verifyWithLink() (gas: 273778) +VerifierTestBillingReport:test_verifyWithNative() (gas: 252098) +VerifierTestBillingReport:test_verifyWithNativeUnwrapped() (gas: 263163) +VerifierTestBillingReport:test_verifyWithNativeUnwrappedReturnsChange() (gas: 270230) VerifierVerifyMultipleConfigDigestTest:test_canVerifyNewerReportsWithNewerConfigs() (gas: 127500) VerifierVerifyMultipleConfigDigestTest:test_canVerifyOlderReportsWithOlderConfigs() (gas: 183379) VerifierVerifyMultipleConfigDigestTest:test_revertsIfAReportIsVerifiedWithAnExistingButIncorrectDigest() (gas: 84470) @@ -219,5 +219,5 @@ Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 207063) Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922408) Verifier_verify:testVerifyProxySuccess_gas() (gas: 197508) Verifier_verify:testVerifySuccess_gas() (gas: 182991) -Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245475) -Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 262092) \ No newline at end of file +Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245201) +Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 261818) \ No newline at end of file diff --git a/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol b/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol index 5fea27220d2..036800ccab4 100644 --- a/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol +++ b/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol @@ -41,8 +41,6 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { // @notice the different report versions bytes32 private constant REPORT_V1 = 0x0001000000000000000000000000000000000000000000000000000000000000; - bytes32 private constant REPORT_V2 = 0x0002000000000000000000000000000000000000000000000000000000000000; - bytes32 private constant REPORT_V3 = 0x0003000000000000000000000000000000000000000000000000000000000000; /// @notice the surcharge fee to be paid if paying in native uint256 public s_nativeSurcharge; @@ -68,9 +66,6 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { /// @notice thrown if a report has no quote error InvalidQuote(); - /// @notice thrown if a report has an invalid version - error InvalidReportVersion(); - // @notice Thrown when the caller is not authorized error Unauthorized(); @@ -247,19 +242,10 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { uint256 linkQuantity; uint256 nativeQuantity; uint256 expiresAt; - if (reportVersion == REPORT_V2) { - (, , , , expiresAt, linkQuantity, nativeQuantity) = abi.decode( - report, - (bytes32, uint32, int192, uint32, uint32, uint192, uint192) - ); - } else if (reportVersion == REPORT_V3) { - (, , , , , , expiresAt, linkQuantity, nativeQuantity) = abi.decode( - report, - (bytes32, uint32, int192, int192, int192, uint32, uint32, uint192, uint192) - ); - } else { - revert InvalidReportVersion(); - } + (, , , , linkQuantity, nativeQuantity, expiresAt) = abi.decode( + report, + (bytes32, uint32, uint32, int192, uint192, uint192, uint32) + ); //read the timestamp bytes from the report data and verify it has not expired if (expiresAt < block.timestamp) { diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol index be984af3267..0392704b963 100644 --- a/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol @@ -64,7 +64,6 @@ contract BaseFeeManagerTest is Test { bytes4 internal immutable INVALID_DEPOSIT_ERROR = FeeManager.InvalidDeposit.selector; bytes4 internal immutable INVALID_QUOTE_ERROR = FeeManager.InvalidQuote.selector; bytes4 internal immutable UNAUTHORIZED_ERROR = FeeManager.Unauthorized.selector; - bytes4 internal immutable INVALID_REPORT_VERSION_ERROR = FeeManager.InvalidReportVersion.selector; bytes internal constant ONLY_CALLABLE_BY_OWNER_ERROR = "Only callable by owner"; bytes internal constant INSUFFICIENT_ALLOWANCE_ERROR = "ERC20: insufficient allowance"; @@ -170,11 +169,11 @@ contract BaseFeeManagerTest is Test { abi.encode( feedId, uint32(0), - int192(0), uint32(0), - uint32(block.timestamp), - DEFAULT_REPORT_LINK_FEE, - DEFAULT_REPORT_NATIVE_FEE + int192(0), + uint192(DEFAULT_REPORT_LINK_FEE), + uint192(DEFAULT_REPORT_NATIVE_FEE), + uint32(block.timestamp) ); } @@ -183,8 +182,8 @@ contract BaseFeeManagerTest is Test { uint256 expiry, uint256 linkFee, uint256 nativeFee - ) public view returns (bytes memory) { - return abi.encode(feedId, uint32(0), int192(0), uint32(0), uint32(expiry), linkFee, nativeFee); + ) public pure returns (bytes memory) { + return abi.encode(feedId, uint32(0), uint32(0), int192(0), uint192(linkFee), uint192(nativeFee), uint32(expiry)); } function getV2Report(bytes32 feedId) public view returns (bytes memory) { @@ -192,13 +191,13 @@ contract BaseFeeManagerTest is Test { abi.encode( feedId, uint32(0), - int192(0), - int192(0), - int192(0), uint32(0), - uint32(block.timestamp), + int192(0), uint192(DEFAULT_REPORT_LINK_FEE), - uint192(DEFAULT_REPORT_NATIVE_FEE) + uint192(DEFAULT_REPORT_NATIVE_FEE), + uint32(block.timestamp), + int192(0), + int192(0) ); } @@ -212,13 +211,13 @@ contract BaseFeeManagerTest is Test { abi.encode( feedId, uint32(0), - int192(0), - int192(0), - int192(0), uint32(0), - uint32(expiry), + int192(0), uint192(linkFee), - uint192(nativeFee) + uint192(nativeFee), + uint32(expiry), + int192(0), + int192(0) ); } diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol index bf7db55e4ce..4ba54bb5fdb 100644 --- a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.processFee.t.sol @@ -315,14 +315,14 @@ contract FeeManagerProcessFeeTest is BaseFeeManagerTest { processFee(payload, USER, 0, ADMIN); } - function test_processFeeWithInvalidReportVersion() public { + function test_processFeeWithInvalidReportVersionFailsToDecode() public { bytes memory data = abi.encode(0x0000100000000000000000000000000000000000000000000000000000000000); //get the default payload bytes memory payload = getPayload(data, getQuotePayload(getLinkAddress())); - //version is invalid as feedId is 0 - vm.expectRevert(INVALID_REPORT_VERSION_ERROR); + //serialization will fail as there is no report to decode + vm.expectRevert(); //processing the fee will not withdraw anything as there is no fee to collect processFee(payload, USER, 0, ADMIN); diff --git a/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol b/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol index cdecb132e7d..38ceb3030ef 100644 --- a/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/verifier/BaseVerifierTest.t.sol @@ -248,20 +248,20 @@ contract BaseTestWithConfiguredVerifierAndFeeManager is BaseTest { bytes32 feedId; // The time the median value was observed on uint32 observationsTimestamp; - // The median value agreed in an OCR round - int192 benchmarkPrice; - // The best bid value agreed in an OCR round - int192 bid; - // The best ask value agreed in an OCR round - int192 ask; // The timestamp the report is valid from uint32 validFromTimestamp; - // The expiry of the report - uint32 expiresAt; + // The median value agreed in an OCR round + int192 benchmarkPrice; // The link fee uint192 linkFee; // The native fee uint192 nativeFee; + // The expiry of the report + uint32 expiresAt; + // The best bid value agreed in an OCR round + int192 bid; + // The best ask value agreed in an OCR round + int192 ask; } function setUp() public virtual override { @@ -306,13 +306,13 @@ contract BaseTestWithConfiguredVerifierAndFeeManager is BaseTest { abi.encode( report.feedId, report.observationsTimestamp, - report.benchmarkPrice, - report.bid, - report.ask, report.validFromTimestamp, - report.expiresAt, + report.benchmarkPrice, report.linkFee, - report.nativeFee + report.nativeFee, + report.expiresAt, + report.bid, + report.ask ); } @@ -332,26 +332,26 @@ contract BaseTestWithConfiguredVerifierAndFeeManager is BaseTest { return abi.encode(reportContext, reportBytes, rs, ss, rawVs, quote); } - function _generateQuote(address billingAddress) internal returns (bytes memory) { + function _generateQuote(address billingAddress) internal pure returns (bytes memory) { return abi.encode(billingAddress); } - function _generateV2Report() internal returns (V2Report memory) { + function _generateV2Report() internal view returns (V2Report memory) { return V2Report({ feedId: FEED_ID_V3, observationsTimestamp: OBSERVATIONS_TIMESTAMP, - benchmarkPrice: MEDIAN, - bid: BID, - ask: ASK, validFromTimestamp: uint32(block.timestamp), - expiresAt: uint32(block.timestamp), + benchmarkPrice: MEDIAN, linkFee: uint192(DEFAULT_REPORT_LINK_FEE), - nativeFee: uint192(DEFAULT_REPORT_NATIVE_FEE) + nativeFee: uint192(DEFAULT_REPORT_NATIVE_FEE), + expiresAt: uint32(block.timestamp), + bid: BID, + ask: ASK }); } - function _generateReportContext(bytes32 feedId) internal returns (bytes32[3] memory) { + function _generateReportContext(bytes32 feedId) internal view returns (bytes32[3] memory) { (, , bytes32 latestConfigDigest) = s_verifier.latestConfigDetails(feedId); bytes32[3] memory reportContext; reportContext[0] = latestConfigDigest; diff --git a/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go b/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go index 9957546c42c..eb5b4c4f35d 100644 --- a/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go +++ b/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go @@ -45,8 +45,8 @@ type IFeeManagerQuote struct { } var FeeManagerMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_nativeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_proxyAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_rewardManagerAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ExpiredReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDeposit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDiscount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidQuote\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidReportVersion\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSurcharge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nativeQuantity\",\"type\":\"uint256\"}],\"name\":\"InsufficientLink\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newSurcharge\",\"type\":\"uint256\"}],\"name\":\"NativeSurchargeUpdated\",\"type\":\"event\"},{\"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\":\"subscriber\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"SubscriberDiscountUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"quoteAddress\",\"type\":\"address\"}],\"internalType\":\"structIFeeManager.Quote\",\"name\":\"quote\",\"type\":\"tuple\"}],\"name\":\"getFeeAndReward\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkAvailableForPayment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"}],\"name\":\"processFee\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_nativeSurcharge\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_subscriberDiscounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setFeeRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"surcharge\",\"type\":\"uint256\"}],\"name\":\"setNativeSurcharge\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"updateSubscriberDiscount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101006040523480156200001257600080fd5b506040516200259938038062002599833981016040819052620000359162000288565b33806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf81620001c0565b5050506001600160a01b0384161580620000e057506001600160a01b038316155b80620000f357506001600160a01b038216155b806200010657506001600160a01b038116155b15620001255760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03848116608081905284821660a05283821660c05290821660e081905260405163095ea7b360e01b81526004810191909152600019602482015263095ea7b3906044016020604051808303816000875af11580156200018f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001b59190620002e5565b505050505062000310565b336001600160a01b038216036200021a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200028357600080fd5b919050565b600080600080608085870312156200029f57600080fd5b620002aa856200026b565b9350620002ba602086016200026b565b9250620002ca604086016200026b565b9150620002da606086016200026b565b905092959194509250565b600060208284031215620002f857600080fd5b815180151581146200030957600080fd5b9392505050565b60805160a05160c05160e0516121ed620003ac6000396000818161041b01528181610f38015261118e0152600081816103840152610bc50152600081816106b301528181610706015281816109c501528181610d3001528181610df701526112fa0152600081816106d8015281816107610152818161095001528181610b0501528181610eb70152818161107a01526112a301526121ed6000f3fe6080604052600436106100dd5760003560e01c80638da5cb5b1161007f578063f1387e1611610059578063f1387e16146102d6578063f237f1a8146102e9578063f2fde38b14610309578063f3fef3a31461032957600080fd5b80638da5cb5b1461025e578063c541cbde14610293578063d09dc339146102c157600080fd5b806369fd2b34116100bb57806369fd2b34146101c95780636b54d8a6146101eb57806379ba50971461020b57806387d6d8431461022057600080fd5b806301ffc9a7146100e2578063181f5a771461015957806332f5f746146101a5575b600080fd5b3480156100ee57600080fd5b506101446100fd36600461175e565b7fffffffff00000000000000000000000000000000000000000000000000000000167ff1387e16000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b34801561016557600080fd5b50604080518082018252601081527f4665654d616e6167657220302e302e31000000000000000000000000000000006020820152905161015091906117a7565b3480156101b157600080fd5b506101bb60035481565b604051908152602001610150565b3480156101d557600080fd5b506101e96101e4366004611813565b610349565b005b3480156101f757600080fd5b506101e9610206366004611892565b61048b565b34801561021757600080fd5b506101e9610510565b34801561022c57600080fd5b506101bb61023b3660046118cd565b600260209081526000938452604080852082529284528284209052825290205481565b34801561026a57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610150565b34801561029f57600080fd5b506102b36102ae366004611a44565b610612565b604051610150929190611ae5565b3480156102cd57600080fd5b506101bb610ad4565b6101e96102e4366004611b39565b610b8a565b3480156102f557600080fd5b506101e9610304366004611bb1565b611257565b34801561031557600080fd5b506101e9610324366004611bf9565b6113fe565b34801561033557600080fd5b506101e9610344366004611c16565b611412565b60005473ffffffffffffffffffffffffffffffffffffffff1633148015906103a757503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b156103de576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f633b5f6e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063633b5f6e9061045490869086908690600401611c42565b600060405180830381600087803b15801561046e57600080fd5b505af1158015610482573d6000803e3d6000fd5b50505050505050565b6104936115ac565b670de0b6b3a76400008111156104d5576040517f05e8ac2900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60038190556040518181527fa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e19060200160405180910390a150565b60015473ffffffffffffffffffffffffffffffffffffffff163314610596576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6040805180820190915260008082526020820152604080518082019091526000808252602082015260408051808201909152600080825260208201526040805180820190915260008082526020820152600061066d87611cb1565b90507fffff00000000000000000000000000000000000000000000000000000000000080821690810161070457505073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000811683527f00000000000000000000000000000000000000000000000000000000000000001681529092509050610acc565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff16141580156107b457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff1614155b156107eb576040517ff861803000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600080807ffffe000000000000000000000000000000000000000000000000000000000000840161085d578a80602001905181019061082a9190611d49565b77ffffffffffffffffffffffffffffffffffffffffffffffff918216995016965063ffffffff1694506108ff9350505050565b7ffffd00000000000000000000000000000000000000000000000000000000000084016108cd578a8060200190518101906108989190611dc8565b77ffffffffffffffffffffffffffffffffffffffffffffffff9182169b5016985063ffffffff1696506108ff95505050505050565b6040517f52762c7400000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b42811015610939576040517fb6c405f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116808852602088018590528b51909116036109ae57855173ffffffffffffffffffffffffffffffffffffffff16875260208087015190880152610a1e565b73ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000168752600354610a1890610a0090670de0b6b3a7640000611e98565b610a0a9084611eab565b670de0b6b3a764000061162f565b60208801525b73ffffffffffffffffffffffffffffffffffffffff808d16600090815260026020908152604080832089845282528083208e5190941683529281529190205490880151670de0b6b3a764000090610a76908390611eab565b610a809190611ee8565b8860200151610a8f9190611f23565b886020018181525050610aab818860200151610a0a9190611eab565b8760200151610aba9190611f23565b60208801525095975093955050505050505b935093915050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610b61573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b859190611f36565b905090565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610be857503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b15610c1f576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff821603610c6e576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610c7c83850185611fbd565b915050600081610c8b90611cb1565b6040805160208101909152600081529091507e010000000000000000000000000000000000000000000000000000000000007fffff000000000000000000000000000000000000000000000000000000000000831614610d12576000610cf38688018861208c565b9550505050505080806020019051810190610d0e9190612154565b9150505b600080610d20338685610612565b91509150600034600014610e84577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614610db7576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3483602001511115610df5576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db084602001516040518263ffffffff1660e01b81526004016000604051808303818588803b158015610e6157600080fd5b505af1158015610e75573d6000803e3d6000fd5b50505050508260200151340390505b6000610e90898b612182565b9050836020015160001461120057835173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116911603610f9b5760208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8a8116602483015260448201929092527f00000000000000000000000000000000000000000000000000000000000000009091169063efb03fe990606401600060405180830381600087803b158015610f7e57600080fd5b505af1158015610f92573d6000803e3d6000fd5b50505050611200565b3460000361104c57835160208501516040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8b8116600483015230602483015260448201929092529116906323b872dd906064016020604051808303816000875af1158015611026573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061104a91906121be565b505b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa1580156110d6573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906110fa9190611f36565b8360200151111561114c5760208084015185820151604080519283529282015282917feb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7910160405180910390a2611200565b60208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905230602482015260448101919091527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063efb03fe990606401600060405180830381600087803b1580156111e757600080fd5b505af11580156111fb573d6000803e3d6000fd5b505050505b811561124b5760405173ffffffffffffffffffffffffffffffffffffffff89169083156108fc029084906000818181858888f19350505050158015611249573d6000803e3d6000fd5b505b50505050505050505050565b61125f6115ac565b670de0b6b3a76400008111156112a1576040517f997ea36000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415801561134957507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b15611380576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84811660008181526002602090815260408083208884528252808320948716808452948252918290208590558151938452830184905285927f41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84910160405180910390a350505050565b6114066115ac565b61140f81611669565b50565b61141a6115ac565b73ffffffffffffffffffffffffffffffffffffffff8216611480576000805460405173ffffffffffffffffffffffffffffffffffffffff9091169183156108fc02918491818181858888f1935050505015801561147b573d6000803e3d6000fd5b505050565b8173ffffffffffffffffffffffffffffffffffffffff1663a9059cbb6114bb60005473ffffffffffffffffffffffffffffffffffffffff1690565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af115801561152d573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061155191906121be565b506040805133815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb9060600160405180910390a15050565b60005473ffffffffffffffffffffffffffffffffffffffff16331461162d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161058d565b565b6000821561165d5781611643600185611f23565b61164d9190611ee8565b611658906001611e98565b611660565b60005b90505b92915050565b3373ffffffffffffffffffffffffffffffffffffffff8216036116e8576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161058d565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60006020828403121561177057600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146117a057600080fd5b9392505050565b600060208083528351808285015260005b818110156117d4578581018301518582016040015282016117b8565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60008060006040848603121561182857600080fd5b83359250602084013567ffffffffffffffff8082111561184757600080fd5b818601915086601f83011261185b57600080fd5b81358181111561186a57600080fd5b8760208260061b850101111561187f57600080fd5b6020830194508093505050509250925092565b6000602082840312156118a457600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461140f57600080fd5b6000806000606084860312156118e257600080fd5b83356118ed816118ab565b9250602084013591506040840135611904816118ab565b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516020810167ffffffffffffffff811182821017156119615761196161190f565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156119ae576119ae61190f565b604052919050565b600082601f8301126119c757600080fd5b813567ffffffffffffffff8111156119e1576119e161190f565b611a1260207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611967565b818152846020838601011115611a2757600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008385036060811215611a5a57600080fd5b8435611a65816118ab565b9350602085013567ffffffffffffffff811115611a8157600080fd5b611a8d878288016119b6565b93505060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc082011215611ac057600080fd5b50611ac961193e565b6040850135611ad7816118ab565b815292959194509192509050565b825173ffffffffffffffffffffffffffffffffffffffff1681526020808401519082015260808101825173ffffffffffffffffffffffffffffffffffffffff166040830152602083015160608301526117a0565b600080600060408486031215611b4e57600080fd5b833567ffffffffffffffff80821115611b6657600080fd5b818601915086601f830112611b7a57600080fd5b813581811115611b8957600080fd5b876020828501011115611b9b57600080fd5b60209283019550935050840135611904816118ab565b60008060008060808587031215611bc757600080fd5b8435611bd2816118ab565b9350602085013592506040850135611be9816118ab565b9396929550929360600135925050565b600060208284031215611c0b57600080fd5b81356117a0816118ab565b60008060408385031215611c2957600080fd5b8235611c34816118ab565b946020939093013593505050565b8381526040602080830182905282820184905260009190859060608501845b87811015611ca4578335611c74816118ab565b73ffffffffffffffffffffffffffffffffffffffff16825283830135838301529284019290840190600101611c61565b5098975050505050505050565b80516020808301519190811015611cf0577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805163ffffffff81168114611d0a57600080fd5b919050565b8051601781900b8114611d0a57600080fd5b805177ffffffffffffffffffffffffffffffffffffffffffffffff81168114611d0a57600080fd5b600080600080600080600060e0888a031215611d6457600080fd5b87519650611d7460208901611cf6565b9550611d8260408901611d0f565b9450611d9060608901611cf6565b9350611d9e60808901611cf6565b9250611dac60a08901611d21565b9150611dba60c08901611d21565b905092959891949750929550565b60008060008060008060008060006101208a8c031215611de757600080fd5b89519850611df760208b01611cf6565b9750611e0560408b01611d0f565b9650611e1360608b01611d0f565b9550611e2160808b01611d0f565b9450611e2f60a08b01611cf6565b9350611e3d60c08b01611cf6565b9250611e4b60e08b01611d21565b9150611e5a6101008b01611d21565b90509295985092959850929598565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561166357611663611e69565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611ee357611ee3611e69565b500290565b600082611f1e577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b8181038181111561166357611663611e69565b600060208284031215611f4857600080fd5b5051919050565b600082601f830112611f6057600080fd5b6040516060810181811067ffffffffffffffff82111715611f8357611f8361190f565b604052806060840185811115611f9857600080fd5b845b81811015611fb2578035835260209283019201611f9a565b509195945050505050565b60008060808385031215611fd057600080fd5b611fda8484611f4f565b9150606083013567ffffffffffffffff811115611ff657600080fd5b612002858286016119b6565b9150509250929050565b600082601f83011261201d57600080fd5b8135602067ffffffffffffffff8211156120395761203961190f565b8160051b612048828201611967565b928352848101820192828101908785111561206257600080fd5b83870192505b8483101561208157823582529183019190830190612068565b979650505050505050565b60008060008060008061010087890312156120a657600080fd5b6120b08888611f4f565b9550606087013567ffffffffffffffff808211156120cd57600080fd5b6120d98a838b016119b6565b965060808901359150808211156120ef57600080fd5b6120fb8a838b0161200c565b955060a089013591508082111561211157600080fd5b61211d8a838b0161200c565b945060c0890135935060e089013591508082111561213a57600080fd5b5061214789828a016119b6565b9150509295509295509295565b60006020828403121561216657600080fd5b61216e61193e565b8251612179816118ab565b81529392505050565b80356020831015611663577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b6000602082840312156121d057600080fd5b815180151581146117a057600080fdfea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_nativeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_proxyAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_rewardManagerAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ExpiredReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDeposit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDiscount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidQuote\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSurcharge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nativeQuantity\",\"type\":\"uint256\"}],\"name\":\"InsufficientLink\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newSurcharge\",\"type\":\"uint256\"}],\"name\":\"NativeSurchargeUpdated\",\"type\":\"event\"},{\"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\":\"subscriber\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"SubscriberDiscountUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"quoteAddress\",\"type\":\"address\"}],\"internalType\":\"structIFeeManager.Quote\",\"name\":\"quote\",\"type\":\"tuple\"}],\"name\":\"getFeeAndReward\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkAvailableForPayment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"}],\"name\":\"processFee\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_nativeSurcharge\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_subscriberDiscounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setFeeRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"surcharge\",\"type\":\"uint256\"}],\"name\":\"setNativeSurcharge\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"updateSubscriberDiscount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101006040523480156200001257600080fd5b506040516200242338038062002423833981016040819052620000359162000288565b33806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf81620001c0565b5050506001600160a01b0384161580620000e057506001600160a01b038316155b80620000f357506001600160a01b038216155b806200010657506001600160a01b038116155b15620001255760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03848116608081905284821660a05283821660c05290821660e081905260405163095ea7b360e01b81526004810191909152600019602482015263095ea7b3906044016020604051808303816000875af11580156200018f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001b59190620002e5565b505050505062000310565b336001600160a01b038216036200021a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200028357600080fd5b919050565b600080600080608085870312156200029f57600080fd5b620002aa856200026b565b9350620002ba602086016200026b565b9250620002ca604086016200026b565b9150620002da606086016200026b565b905092959194509250565b600060208284031215620002f857600080fd5b815180151581146200030957600080fd5b9392505050565b60805160a05160c05160e051612077620003ac6000396000818161041b01528181610e6d01526110c30152600081816103840152610afa0152600081816106b301528181610706015281816108fa01528181610c6501528181610d2c015261122f0152600081816106d8015281816107610152818161088501528181610a3a01528181610dec01528181610faf01526111d801526120776000f3fe6080604052600436106100dd5760003560e01c80638da5cb5b1161007f578063f1387e1611610059578063f1387e16146102d6578063f237f1a8146102e9578063f2fde38b14610309578063f3fef3a31461032957600080fd5b80638da5cb5b1461025e578063c541cbde14610293578063d09dc339146102c157600080fd5b806369fd2b34116100bb57806369fd2b34146101c95780636b54d8a6146101eb57806379ba50971461020b57806387d6d8431461022057600080fd5b806301ffc9a7146100e2578063181f5a771461015957806332f5f746146101a5575b600080fd5b3480156100ee57600080fd5b506101446100fd366004611693565b7fffffffff00000000000000000000000000000000000000000000000000000000167ff1387e16000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b34801561016557600080fd5b50604080518082018252601081527f4665654d616e6167657220302e302e31000000000000000000000000000000006020820152905161015091906116dc565b3480156101b157600080fd5b506101bb60035481565b604051908152602001610150565b3480156101d557600080fd5b506101e96101e4366004611748565b610349565b005b3480156101f757600080fd5b506101e96102063660046117c7565b61048b565b34801561021757600080fd5b506101e9610510565b34801561022c57600080fd5b506101bb61023b366004611802565b600260209081526000938452604080852082529284528284209052825290205481565b34801561026a57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610150565b34801561029f57600080fd5b506102b36102ae366004611979565b610612565b604051610150929190611a1a565b3480156102cd57600080fd5b506101bb610a09565b6101e96102e4366004611a6e565b610abf565b3480156102f557600080fd5b506101e9610304366004611ae6565b61118c565b34801561031557600080fd5b506101e9610324366004611b2e565b611333565b34801561033557600080fd5b506101e9610344366004611b4b565b611347565b60005473ffffffffffffffffffffffffffffffffffffffff1633148015906103a757503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b156103de576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f633b5f6e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063633b5f6e9061045490869086908690600401611b77565b600060405180830381600087803b15801561046e57600080fd5b505af1158015610482573d6000803e3d6000fd5b50505050505050565b6104936114e1565b670de0b6b3a76400008111156104d5576040517f05e8ac2900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60038190556040518181527fa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e19060200160405180910390a150565b60015473ffffffffffffffffffffffffffffffffffffffff163314610596576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6040805180820190915260008082526020820152604080518082019091526000808252602082015260408051808201909152600080825260208201526040805180820190915260008082526020820152600061066d87611be6565b90507fffff00000000000000000000000000000000000000000000000000000000000080821690810161070457505073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000811683527f00000000000000000000000000000000000000000000000000000000000000001681529092509050610a01565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff16141580156107b457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff1614155b156107eb576040517ff861803000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060008a8060200190518101906108049190611c6c565b77ffffffffffffffffffffffffffffffffffffffffffffffff92831699509116965063ffffffff169450505042831015915061086e9050576040517fb6c405f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116808852602088018590528b51909116036108e357855173ffffffffffffffffffffffffffffffffffffffff16875260208087015190880152610953565b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016875260035461094d9061093590670de0b6b3a7640000611d22565b61093f9084611d35565b670de0b6b3a7640000611564565b60208801525b73ffffffffffffffffffffffffffffffffffffffff808d16600090815260026020908152604080832089845282528083208e5190941683529281529190205490880151670de0b6b3a7640000906109ab908390611d35565b6109b59190611d72565b88602001516109c49190611dad565b8860200181815250506109e081886020015161093f9190611d35565b87602001516109ef9190611dad565b60208801525095975093955050505050505b935093915050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610a96573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610aba9190611dc0565b905090565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610b1d57503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b15610b54576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff821603610ba3576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610bb183850185611e47565b915050600081610bc090611be6565b6040805160208101909152600081529091507e010000000000000000000000000000000000000000000000000000000000007fffff000000000000000000000000000000000000000000000000000000000000831614610c47576000610c2886880188611f16565b9550505050505080806020019051810190610c439190611fde565b9150505b600080610c55338685610612565b91509150600034600014610db9577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614610cec576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3483602001511115610d2a576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db084602001516040518263ffffffff1660e01b81526004016000604051808303818588803b158015610d9657600080fd5b505af1158015610daa573d6000803e3d6000fd5b50505050508260200151340390505b6000610dc5898b61200c565b9050836020015160001461113557835173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116911603610ed05760208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8a8116602483015260448201929092527f00000000000000000000000000000000000000000000000000000000000000009091169063efb03fe990606401600060405180830381600087803b158015610eb357600080fd5b505af1158015610ec7573d6000803e3d6000fd5b50505050611135565b34600003610f8157835160208501516040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8b8116600483015230602483015260448201929092529116906323b872dd906064016020604051808303816000875af1158015610f5b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f7f9190612048565b505b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561100b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061102f9190611dc0565b836020015111156110815760208084015185820151604080519283529282015282917feb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7910160405180910390a2611135565b60208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905230602482015260448101919091527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063efb03fe990606401600060405180830381600087803b15801561111c57600080fd5b505af1158015611130573d6000803e3d6000fd5b505050505b81156111805760405173ffffffffffffffffffffffffffffffffffffffff89169083156108fc029084906000818181858888f1935050505015801561117e573d6000803e3d6000fd5b505b50505050505050505050565b6111946114e1565b670de0b6b3a76400008111156111d6576040517f997ea36000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415801561127e57507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b156112b5576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84811660008181526002602090815260408083208884528252808320948716808452948252918290208590558151938452830184905285927f41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84910160405180910390a350505050565b61133b6114e1565b6113448161159e565b50565b61134f6114e1565b73ffffffffffffffffffffffffffffffffffffffff82166113b5576000805460405173ffffffffffffffffffffffffffffffffffffffff9091169183156108fc02918491818181858888f193505050501580156113b0573d6000803e3d6000fd5b505050565b8173ffffffffffffffffffffffffffffffffffffffff1663a9059cbb6113f060005473ffffffffffffffffffffffffffffffffffffffff1690565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af1158015611462573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114869190612048565b506040805133815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb9060600160405180910390a15050565b60005473ffffffffffffffffffffffffffffffffffffffff163314611562576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161058d565b565b600082156115925781611578600185611dad565b6115829190611d72565b61158d906001611d22565b611595565b60005b90505b92915050565b3373ffffffffffffffffffffffffffffffffffffffff82160361161d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161058d565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156116a557600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146116d557600080fd5b9392505050565b600060208083528351808285015260005b81811015611709578581018301518582016040015282016116ed565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60008060006040848603121561175d57600080fd5b83359250602084013567ffffffffffffffff8082111561177c57600080fd5b818601915086601f83011261179057600080fd5b81358181111561179f57600080fd5b8760208260061b85010111156117b457600080fd5b6020830194508093505050509250925092565b6000602082840312156117d957600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461134457600080fd5b60008060006060848603121561181757600080fd5b8335611822816117e0565b9250602084013591506040840135611839816117e0565b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516020810167ffffffffffffffff8111828210171561189657611896611844565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156118e3576118e3611844565b604052919050565b600082601f8301126118fc57600080fd5b813567ffffffffffffffff81111561191657611916611844565b61194760207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161189c565b81815284602083860101111561195c57600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000838503606081121561198f57600080fd5b843561199a816117e0565b9350602085013567ffffffffffffffff8111156119b657600080fd5b6119c2878288016118eb565b93505060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0820112156119f557600080fd5b506119fe611873565b6040850135611a0c816117e0565b815292959194509192509050565b825173ffffffffffffffffffffffffffffffffffffffff1681526020808401519082015260808101825173ffffffffffffffffffffffffffffffffffffffff166040830152602083015160608301526116d5565b600080600060408486031215611a8357600080fd5b833567ffffffffffffffff80821115611a9b57600080fd5b818601915086601f830112611aaf57600080fd5b813581811115611abe57600080fd5b876020828501011115611ad057600080fd5b60209283019550935050840135611839816117e0565b60008060008060808587031215611afc57600080fd5b8435611b07816117e0565b9350602085013592506040850135611b1e816117e0565b9396929550929360600135925050565b600060208284031215611b4057600080fd5b81356116d5816117e0565b60008060408385031215611b5e57600080fd5b8235611b69816117e0565b946020939093013593505050565b8381526040602080830182905282820184905260009190859060608501845b87811015611bd9578335611ba9816117e0565b73ffffffffffffffffffffffffffffffffffffffff16825283830135838301529284019290840190600101611b96565b5098975050505050505050565b80516020808301519190811015611c25577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805163ffffffff81168114611c3f57600080fd5b919050565b805177ffffffffffffffffffffffffffffffffffffffffffffffff81168114611c3f57600080fd5b600080600080600080600060e0888a031215611c8757600080fd5b87519650611c9760208901611c2b565b9550611ca560408901611c2b565b945060608801518060170b8114611cbb57600080fd5b9350611cc960808901611c44565b9250611cd760a08901611c44565b9150611ce560c08901611c2b565b905092959891949750929550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561159857611598611cf3565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611d6d57611d6d611cf3565b500290565b600082611da8577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b8181038181111561159857611598611cf3565b600060208284031215611dd257600080fd5b5051919050565b600082601f830112611dea57600080fd5b6040516060810181811067ffffffffffffffff82111715611e0d57611e0d611844565b604052806060840185811115611e2257600080fd5b845b81811015611e3c578035835260209283019201611e24565b509195945050505050565b60008060808385031215611e5a57600080fd5b611e648484611dd9565b9150606083013567ffffffffffffffff811115611e8057600080fd5b611e8c858286016118eb565b9150509250929050565b600082601f830112611ea757600080fd5b8135602067ffffffffffffffff821115611ec357611ec3611844565b8160051b611ed282820161189c565b9283528481018201928281019087851115611eec57600080fd5b83870192505b84831015611f0b57823582529183019190830190611ef2565b979650505050505050565b6000806000806000806101008789031215611f3057600080fd5b611f3a8888611dd9565b9550606087013567ffffffffffffffff80821115611f5757600080fd5b611f638a838b016118eb565b96506080890135915080821115611f7957600080fd5b611f858a838b01611e96565b955060a0890135915080821115611f9b57600080fd5b611fa78a838b01611e96565b945060c0890135935060e0890135915080821115611fc457600080fd5b50611fd189828a016118eb565b9150509295509295509295565b600060208284031215611ff057600080fd5b611ff8611873565b8251612003816117e0565b81529392505050565b80356020831015611598577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b60006020828403121561205a57600080fd5b815180151581146116d557600080fdfea164736f6c6343000810000a", } var FeeManagerABI = FeeManagerMetaData.ABI diff --git a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 2b62ac60b84..7f218e76e4d 100644 --- a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,7 +1,7 @@ GETH_VERSION: 1.12.0 errored_verifier: ../../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../../contracts/solc/v0.8.16/ErroredVerifier.bin 1b0a03b90137d31fceb340b80ade65a4ed52fa63c5caf24183ce3f63567d818f exposed_verifier: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 -fee_manager: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin d5674bbad7231fc588dc8c9d1f803fedb649ba7355b3c5ab11f9810c5c839a6b +fee_manager: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin 3f0dbc02b8d9acd42e30ba9438f8eb3d47bdf5ce1f10814eabaf3e401bc6cf7d llo_feeds: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin cb71e018f67e49d7bc0e194c822204dfd59f79ff42e4fc8fd8ab63f3acd71361 llo_feeds_test: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 reward_manager: ../../../contracts/solc/v0.8.16/RewardManager.abi ../../../contracts/solc/v0.8.16/RewardManager.bin 1694433bbcf39684ec105b3b1d9478f7158165c97b711483f1f4f4fa4eb61364 From 3e2bf385ff9d180e094b2bbe2d7438f6cd20dd59 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Thu, 24 Aug 2023 11:57:17 +0100 Subject: [PATCH 258/270] Remove 0x prefix from scanned logs (#10327) * Remove 0x prefix from scanned logs * use same function as wid generation --- .../ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go | 4 ++-- .../ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go index ae33ceadbb0..9a0684850ec 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner.go @@ -2,11 +2,11 @@ package upkeepstate import ( "context" + "encoding/hex" "fmt" "io" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/common/hexutil" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/logpoller" iregistry21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/i_keeper_registry_master_wrapper_2_1" @@ -80,7 +80,7 @@ func (s *performedEventsScanner) logsToWorkIDs(logs []logpoller.Log) []string { s.lggr.Debugw("unexpected log topics", "topics", topics) continue } - workIDs = append(workIDs, hexutil.Encode(topics[1].Bytes())) + workIDs = append(workIDs, hex.EncodeToString(topics[1].Bytes())) } return workIDs } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go index a8c8e8f6010..f066fe0aa43 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/upkeepstate/scanner_test.go @@ -49,11 +49,11 @@ func TestPerformedEventsScanner(t *testing.T) { Address: registryAddr, Topics: convertTopics([]common.Hash{ iregistry21.IKeeperRegistryMasterDedupKeyAdded{}.Topic(), - common.HexToHash("0x1111"), + common.HexToHash("0x290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563"), }), }, }, - []string{common.HexToHash("0x1111").Hex()}, + []string{"290decd9548b62a8d60345a988386fc84ba6bc95484008f6362f93160ef3e563"}, nil, false, }, From ea436d24be099fa5abb99f6d39f0755669864698 Mon Sep 17 00:00:00 2001 From: krehermann Date: Thu, 24 Aug 2023 05:39:52 -0600 Subject: [PATCH 259/270] BCF-2562: fix nil panic caused by missing configuration (#10296) * BCF-2562: fix nil panic caused by missing configuration * better error messages * remove debugging code * make lazy init thread safe and add test * graphql logging and fix test --- core/chains/chain_set.go | 4 +- core/chains/cosmos/config.go | 6 +- core/chains/evm/chain.go | 36 +++++++--- core/chains/evm/chain_test.go | 54 ++++++++++++++ core/chains/evm/config/toml/config.go | 6 +- core/chains/evm/log/helpers_test.go | 3 +- core/chains/solana/config.go | 6 +- core/chains/starknet/config.go | 6 +- core/cmd/shell.go | 2 +- core/cmd/shell_local_test.go | 6 +- core/internal/cltest/cltest.go | 2 +- core/internal/cltest/job_factories.go | 5 +- core/internal/cltest/mocks.go | 7 +- core/internal/features/features_test.go | 3 +- core/internal/testutils/evmtest/evmtest.go | 7 +- core/services/blockhashstore/bhs_test.go | 3 +- core/services/blockhashstore/delegate_test.go | 3 +- .../chainlink/relayer_chain_interoperators.go | 8 ++- .../relayer_chain_interoperators_test.go | 4 +- core/services/chainlink/relayer_factory.go | 5 +- core/services/cron/cron_test.go | 5 +- core/services/directrequest/delegate_test.go | 8 ++- core/services/feeds/orm_test.go | 6 +- core/services/feeds/service_test.go | 3 +- core/services/fluxmonitorv2/orm_test.go | 5 +- core/services/functions/listener_test.go | 5 +- core/services/job/helpers_test.go | 5 +- core/services/job/job_orm_test.go | 70 ++++++++++++------- .../job/job_pipeline_orm_integration_test.go | 5 +- core/services/job/runner_integration_test.go | 9 ++- core/services/job/spawner_test.go | 8 ++- .../registry_synchronizer_helper_test.go | 3 +- core/services/keeper/upkeep_executer_test.go | 5 +- core/services/ocr2/delegate_test.go | 7 +- core/services/pipeline/orm_test.go | 10 +-- core/services/pipeline/runner_test.go | 6 +- core/services/pipeline/task.eth_call_test.go | 4 +- core/services/pipeline/task.eth_tx_test.go | 3 +- core/services/relay/evm/relayer_extender.go | 41 ++++++----- core/services/vrf/delegate_test.go | 5 +- core/web/resolver/eth_key_test.go | 9 ++- core/web/resolver/query.go | 10 ++- core/web/resolver/resolver_test.go | 3 + 43 files changed, 276 insertions(+), 135 deletions(-) create mode 100644 core/chains/evm/chain_test.go diff --git a/core/chains/chain_set.go b/core/chains/chain_set.go index 9a9bba4ce50..ed5ee918366 100644 --- a/core/chains/chain_set.go +++ b/core/chains/chain_set.go @@ -80,7 +80,7 @@ func (c *chainSet[N, S]) Chain(ctx context.Context, id string) (s S, err error) } ch, ok := c.chains[id] if !ok { - err = ErrNotFound + err = fmt.Errorf("chain %s: %w", id, ErrNotFound) return } return ch, nil @@ -94,7 +94,7 @@ func (c *chainSet[N, S]) ChainStatus(ctx context.Context, id string) (cfg types. } l := len(cs) if l == 0 { - err = ErrNotFound + err = fmt.Errorf("chain %s: %w", id, ErrNotFound) return } if l > 1 { diff --git a/core/chains/cosmos/config.go b/core/chains/cosmos/config.go index 780e83f1279..41de217f010 100644 --- a/core/chains/cosmos/config.go +++ b/core/chains/cosmos/config.go @@ -115,7 +115,7 @@ func (cs CosmosConfigs) Node(name string) (n db.Node, err error) { } } } - err = chains.ErrNotFound + err = fmt.Errorf("node %s: %w", name, chains.ErrNotFound) return } @@ -131,7 +131,7 @@ func (cs CosmosConfigs) nodes(chainID string) (ns CosmosNodes) { func (cs CosmosConfigs) Nodes(chainID string) (ns []db.Node, err error) { nodes := cs.nodes(chainID) if nodes == nil { - err = chains.ErrNotFound + err = fmt.Errorf("no nodes: chain %s: %w", chainID, chains.ErrNotFound) return } for _, n := range nodes { @@ -152,7 +152,7 @@ func (cs CosmosConfigs) NodeStatus(name string) (n relaytypes.NodeStatus, err er } } } - err = chains.ErrNotFound + err = fmt.Errorf("node %s: %w", name, chains.ErrNotFound) return } diff --git a/core/chains/evm/chain.go b/core/chains/evm/chain.go index 7b7c3c0dd7c..619b3e2db77 100644 --- a/core/chains/evm/chain.go +++ b/core/chains/evm/chain.go @@ -6,6 +6,7 @@ import ( "fmt" "math/big" "net/url" + "sync" "time" "go.uber.org/multierr" @@ -83,11 +84,14 @@ type LegacyChainContainer interface { var _ LegacyChainContainer = &LegacyChains{} -func NewLegacyChains(c evmtypes.Configs, m map[string]Chain) *LegacyChains { +func NewLegacyChains(cfg AppConfig, m map[string]Chain) (*LegacyChains, error) { + if cfg == nil { + return nil, fmt.Errorf("must provide non-nil app config") + } return &LegacyChains{ ChainsKV: chains.NewChainsKV[Chain](m), - cfgs: c, - } + cfgs: chains.NewConfigs[utils.Big, evmtypes.Node](cfg.EVMConfigs()), + }, nil } func (c *LegacyChains) ChainNodeConfigs() evmtypes.Configs { @@ -161,12 +165,14 @@ type ChainRelayExtenderConfig struct { // the factory wants to own the logger and db // the factory creates extenders, which need the same and more opts type RelayerConfig struct { - GeneralConfig AppConfig + AppConfig AppConfig - EventBroadcaster pg.EventBroadcaster - MailMon *utils.MailboxMonitor - GasEstimator gas.EvmFeeEstimator - OperationalConfigs evmtypes.Configs + EventBroadcaster pg.EventBroadcaster + MailMon *utils.MailboxMonitor + GasEstimator gas.EvmFeeEstimator + + init sync.Once + operationalConfigs evmtypes.Configs // TODO BCF-2513 remove test code from the API // Gen-functions are useful for dependency injection by tests @@ -178,13 +184,21 @@ type RelayerConfig struct { GenGasEstimator func(*big.Int) gas.EvmFeeEstimator } +func (r *RelayerConfig) EVMConfigs() evmtypes.Configs { + if r.operationalConfigs == nil { + r.init.Do(func() { + r.operationalConfigs = chains.NewConfigs[utils.Big, evmtypes.Node](r.AppConfig.EVMConfigs()) + }) + } + return r.operationalConfigs +} func NewTOMLChain(ctx context.Context, chain *toml.EVMConfig, opts ChainRelayExtenderConfig) (Chain, error) { chainID := chain.ChainID l := opts.Logger.With("evmChainID", chainID.String()) if !chain.IsEnabled() { return nil, errChainDisabled{ChainID: chainID} } - cfg := evmconfig.NewTOMLChainScopedConfig(opts.GeneralConfig, chain, l) + cfg := evmconfig.NewTOMLChainScopedConfig(opts.AppConfig, chain, l) // note: per-chain validation is not necessary at this point since everything is checked earlier on boot. return newChain(ctx, cfg, chain.Nodes, opts) } @@ -412,10 +426,10 @@ func (opts *ChainRelayExtenderConfig) Check() error { if opts.Logger == nil { return errors.New("logger must be non-nil") } - if opts.GeneralConfig == nil { + if opts.AppConfig == nil { return errors.New("config must be non-nil") } - opts.OperationalConfigs = chains.NewConfigs[utils.Big, evmtypes.Node](opts.GeneralConfig.EVMConfigs()) + opts.operationalConfigs = chains.NewConfigs[utils.Big, evmtypes.Node](opts.AppConfig.EVMConfigs()) return nil } diff --git a/core/chains/evm/chain_test.go b/core/chains/evm/chain_test.go new file mode 100644 index 00000000000..e80bfc02934 --- /dev/null +++ b/core/chains/evm/chain_test.go @@ -0,0 +1,54 @@ +package evm_test + +import ( + "math/big" + "testing" + + "github.com/stretchr/testify/assert" + + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm/mocks" + configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" + "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" + "github.com/smartcontractkit/chainlink/v2/core/utils" +) + +func TestLegacyChains(t *testing.T) { + evmCfg := configtest.NewGeneralConfig(t, nil) + + c := mocks.NewChain(t) + c.On("ID").Return(big.NewInt(7)) + m := map[string]evm.Chain{c.ID().String(): c} + + l, err := evm.NewLegacyChains(evmCfg, m) + assert.NoError(t, err) + assert.NotNil(t, l.ChainNodeConfigs()) + got, err := l.Get(c.ID().String()) + assert.NoError(t, err) + assert.Equal(t, c, got) + + l, err = evm.NewLegacyChains(nil, m) + assert.Error(t, err) + assert.Nil(t, l) +} + +func TestRelayConfigInit(t *testing.T) { + appCfg := configtest.NewGeneralConfig(t, nil) + rCfg := evm.RelayerConfig{ + AppConfig: appCfg, + } + + evmCfg := rCfg.EVMConfigs() + assert.NotNil(t, evmCfg) + + // test lazy init is done only once + // note this kind of swapping should never happen in prod + appCfg2 := configtest.NewGeneralConfig(t, func(c *chainlink.Config, s *chainlink.Secrets) { + c.EVM[0].ChainID = utils.NewBig(big.NewInt(27)) + }) + rCfg.AppConfig = appCfg2 + + newEvmCfg := rCfg.EVMConfigs() + assert.NotNil(t, newEvmCfg) + assert.Equal(t, evmCfg, newEvmCfg) +} diff --git a/core/chains/evm/config/toml/config.go b/core/chains/evm/config/toml/config.go index 2f89edc6526..fdfce23a877 100644 --- a/core/chains/evm/config/toml/config.go +++ b/core/chains/evm/config/toml/config.go @@ -133,7 +133,7 @@ func (cs EVMConfigs) Node(name string) (types.Node, error) { } } } - return types.Node{}, chains.ErrNotFound + return types.Node{}, fmt.Errorf("node %s: %w", name, chains.ErrNotFound) } func (cs EVMConfigs) NodeStatus(name string) (relaytypes.NodeStatus, error) { @@ -144,7 +144,7 @@ func (cs EVMConfigs) NodeStatus(name string) (relaytypes.NodeStatus, error) { } } } - return relaytypes.NodeStatus{}, chains.ErrNotFound + return relaytypes.NodeStatus{}, fmt.Errorf("node %s: %w", name, chains.ErrNotFound) } func legacyNode(n *Node, chainID *utils.Big) (v2 types.Node) { @@ -190,7 +190,7 @@ func (cs EVMConfigs) Nodes(chainID utils.Big) (ns []types.Node, err error) { id := chainID.String() nodes := cs.nodes(id) if nodes == nil { - err = chains.ErrNotFound + err = fmt.Errorf("no nodes: chain %s: %w", &chainID, chains.ErrNotFound) return } for _, n := range nodes { diff --git a/core/chains/evm/log/helpers_test.go b/core/chains/evm/log/helpers_test.go index d55a44373f2..e11c9faaf46 100644 --- a/core/chains/evm/log/helpers_test.go +++ b/core/chains/evm/log/helpers_test.go @@ -121,7 +121,8 @@ func (c broadcasterHelperCfg) newWithEthClient(t *testing.T, ethClient evmclient LogBroadcaster: &log.NullBroadcaster{}, MailMon: mailMon, }) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + require.NoError(t, err) pipelineHelper := cltest.NewJobPipelineV2(t, config.WebServer(), config.JobPipeline(), config.Database(), legacyChains, c.db, kst, nil, nil) return &broadcasterHelper{ diff --git a/core/chains/solana/config.go b/core/chains/solana/config.go index 49f0ee4a1c3..e654a9029b1 100644 --- a/core/chains/solana/config.go +++ b/core/chains/solana/config.go @@ -113,7 +113,7 @@ func (cs SolanaConfigs) Node(name string) (soldb.Node, error) { } } } - return soldb.Node{}, chains.ErrNotFound + return soldb.Node{}, fmt.Errorf("node %s: %w", name, chains.ErrNotFound) } func (cs SolanaConfigs) nodes(chainID string) (ns SolanaNodes) { @@ -128,7 +128,7 @@ func (cs SolanaConfigs) nodes(chainID string) (ns SolanaNodes) { func (cs SolanaConfigs) Nodes(chainID string) (ns []soldb.Node, err error) { nodes := cs.nodes(chainID) if nodes == nil { - err = chains.ErrNotFound + err = fmt.Errorf("no nodes: chain %s: %w", chainID, chains.ErrNotFound) return } for _, n := range nodes { @@ -148,7 +148,7 @@ func (cs SolanaConfigs) NodeStatus(name string) (types.NodeStatus, error) { } } } - return types.NodeStatus{}, chains.ErrNotFound + return types.NodeStatus{}, fmt.Errorf("node %s: %w", name, chains.ErrNotFound) } func (cs SolanaConfigs) NodeStatuses(chainIDs ...string) (ns []types.NodeStatus, err error) { diff --git a/core/chains/starknet/config.go b/core/chains/starknet/config.go index 1c306e7b342..c555028c6fb 100644 --- a/core/chains/starknet/config.go +++ b/core/chains/starknet/config.go @@ -112,7 +112,7 @@ func (cs StarknetConfigs) Node(name string) (n db.Node, err error) { } } } - err = chains.ErrNotFound + err = fmt.Errorf("node %s: %w", name, chains.ErrNotFound) return } @@ -128,7 +128,7 @@ func (cs StarknetConfigs) nodes(chainID string) (ns StarknetNodes) { func (cs StarknetConfigs) Nodes(chainID string) (ns []db.Node, err error) { nodes := cs.nodes(chainID) if nodes == nil { - err = chains.ErrNotFound + err = fmt.Errorf("no nodes: chain %s: %w", chainID, chains.ErrNotFound) return } for _, n := range nodes { @@ -148,7 +148,7 @@ func (cs StarknetConfigs) NodeStatus(name string) (n types.NodeStatus, err error } } } - err = chains.ErrNotFound + err = fmt.Errorf("node %s: %w", name, chains.ErrNotFound) return } diff --git a/core/cmd/shell.go b/core/cmd/shell.go index cc7562b2e6d..4215e36b496 100644 --- a/core/cmd/shell.go +++ b/core/cmd/shell.go @@ -156,8 +156,8 @@ func (n ChainlinkAppFactory) NewApplication(ctx context.Context, cfg chainlink.G } evmFactoryCfg := chainlink.EVMFactoryConfig{ - RelayerConfig: evm.RelayerConfig{GeneralConfig: cfg, EventBroadcaster: eventBroadcaster, MailMon: mailMon}, CSAETHKeystore: keyStore, + RelayerConfig: evm.RelayerConfig{AppConfig: cfg, EventBroadcaster: eventBroadcaster, MailMon: mailMon}, } // evm always enabled for backward compatibility // TODO BCF-2510 this needs to change in order to clear the path for EVM extraction diff --git a/core/cmd/shell_local_test.go b/core/cmd/shell_local_test.go index 46062637633..db170d267d5 100644 --- a/core/cmd/shell_local_test.go +++ b/core/cmd/shell_local_test.go @@ -43,7 +43,7 @@ func genTestEVMRelayers(t *testing.T, opts evm.ChainRelayExtenderConfig, ks evmr f := chainlink.RelayerFactory{ Logger: opts.Logger, DB: opts.DB, - QConfig: opts.GeneralConfig.Database(), + QConfig: opts.AppConfig.Database(), LoopRegistry: plugins.NewLoopRegistry(opts.Logger), } @@ -90,7 +90,7 @@ func TestShell_RunNodeWithPasswords(t *testing.T) { DB: db, KeyStore: keyStore.Eth(), RelayerConfig: evm.RelayerConfig{ - GeneralConfig: cfg, + AppConfig: cfg, EventBroadcaster: pg.NewNullEventBroadcaster(), MailMon: &utils.MailboxMonitor{}, }, @@ -197,7 +197,7 @@ func TestShell_RunNodeWithAPICredentialsFile(t *testing.T) { DB: db, KeyStore: keyStore.Eth(), RelayerConfig: evm.RelayerConfig{ - GeneralConfig: cfg, + AppConfig: cfg, EventBroadcaster: pg.NewNullEventBroadcaster(), MailMon: &utils.MailboxMonitor{}, diff --git a/core/internal/cltest/cltest.go b/core/internal/cltest/cltest.go index 7a315acd9d9..c57e35d46f6 100644 --- a/core/internal/cltest/cltest.go +++ b/core/internal/cltest/cltest.go @@ -398,7 +398,7 @@ func NewApplicationWithConfig(t testing.TB, cfg chainlink.GeneralConfig, flagsAn chainId := ethClient.ConfiguredChainID() evmOpts := chainlink.EVMFactoryConfig{ RelayerConfig: evm.RelayerConfig{ - GeneralConfig: cfg, + AppConfig: cfg, EventBroadcaster: eventBroadcaster, MailMon: mailMon, GenEthClient: func(_ *big.Int) evmclient.Client { diff --git a/core/internal/cltest/job_factories.go b/core/internal/cltest/job_factories.go index 624f647c267..fd496c5f972 100644 --- a/core/internal/cltest/job_factories.go +++ b/core/internal/cltest/job_factories.go @@ -6,6 +6,7 @@ import ( "github.com/google/uuid" "github.com/smartcontractkit/sqlx" + "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/bridges" @@ -65,7 +66,9 @@ func getORMs(t *testing.T, db *sqlx.DB) (jobORM job.ORM, pipelineORM pipeline.OR pipelineORM = pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgeORM := bridges.NewORM(db, lggr, config.Database()) cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - jobORM = job.NewORM(db, evmrelay.NewLegacyChainsFromRelayerExtenders(cc), pipelineORM, bridgeORM, keyStore, lggr, config.Database()) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + assert.NoError(t, err) + jobORM = job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, lggr, config.Database()) t.Cleanup(func() { jobORM.Close() }) return } diff --git a/core/internal/cltest/mocks.go b/core/internal/cltest/mocks.go index 9529941d4fb..4984b8157f1 100644 --- a/core/internal/cltest/mocks.go +++ b/core/internal/cltest/mocks.go @@ -13,7 +13,6 @@ import ( "github.com/smartcontractkit/sqlx" - "github.com/smartcontractkit/chainlink/v2/core/chains" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" evmclient "github.com/smartcontractkit/chainlink/v2/core/chains/evm/client" evmmocks "github.com/smartcontractkit/chainlink/v2/core/chains/evm/mocks" @@ -23,12 +22,12 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/chainlink" "github.com/smartcontractkit/chainlink/v2/core/sessions" - "github.com/smartcontractkit/chainlink/v2/core/utils" "github.com/smartcontractkit/chainlink/v2/core/web" gethTypes "github.com/ethereum/go-ethereum/core/types" "github.com/robfig/cron/v3" "github.com/stretchr/testify/assert" + "github.com/stretchr/testify/require" ) // MockSubscription a mock subscription @@ -430,9 +429,9 @@ func NewLegacyChainsWithMockChain(t testing.TB, ethClient evmclient.Client, cfg } func NewLegacyChainsWithChain(t testing.TB, ch evm.Chain, cfg evm.AppConfig) evm.LegacyChainContainer { - chainNodeConfig := chains.NewConfigs[utils.Big, evmtypes.Node](cfg.EVMConfigs()) m := map[string]evm.Chain{ch.ID().String(): ch} - legacyChains := evm.NewLegacyChains(chainNodeConfig, m) + legacyChains, err := evm.NewLegacyChains(cfg, m) + require.NoError(t, err) legacyChains.SetDefault(ch) return legacyChains } diff --git a/core/internal/features/features_test.go b/core/internal/features/features_test.go index 2e2d29c248d..e730ec5f3a0 100644 --- a/core/internal/features/features_test.go +++ b/core/internal/features/features_test.go @@ -1380,7 +1380,8 @@ func TestIntegration_BlockHistoryEstimator(t *testing.T) { ethClient.On("HeadByHash", mock.Anything, h41.Hash).Return(&h41, nil).Maybe() ethClient.On("HeadByHash", mock.Anything, h42.Hash).Return(&h42, nil).Maybe() - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + require.NoError(t, err) for _, re := range cc.Slice() { require.NoError(t, re.Start(testutils.Context(t))) } diff --git a/core/internal/testutils/evmtest/evmtest.go b/core/internal/testutils/evmtest/evmtest.go index bbbeaf05660..0fd391c3a23 100644 --- a/core/internal/testutils/evmtest/evmtest.go +++ b/core/internal/testutils/evmtest/evmtest.go @@ -1,6 +1,7 @@ package evmtest import ( + "fmt" "math/big" "sync" "sync/atomic" @@ -83,7 +84,7 @@ func NewChainRelayExtOpts(t testing.TB, testopts TestChainOpts) evm.ChainRelayEx DB: testopts.DB, KeyStore: testopts.KeyStore, RelayerConfig: evm.RelayerConfig{ - GeneralConfig: testopts.GeneralConfig, + AppConfig: testopts.GeneralConfig, EventBroadcaster: pg.NewNullEventBroadcaster(), MailMon: testopts.MailMon, GasEstimator: testopts.GasEstimator, @@ -211,7 +212,7 @@ func (mo *TestConfigs) Nodes(chainID utils.Big) (nodes []evmtypes.Node, err erro } } } - err = chains.ErrNotFound + err = fmt.Errorf("no nodes: chain %s: %w", chainID.String(), chains.ErrNotFound) return } @@ -227,7 +228,7 @@ func (mo *TestConfigs) Node(name string) (evmtypes.Node, error) { } } } - return evmtypes.Node{}, chains.ErrNotFound + return evmtypes.Node{}, fmt.Errorf("node %s: %w", name, chains.ErrNotFound) } func (mo *TestConfigs) NodeStatusesPaged(offset int, limit int, chainIDs ...string) (nodes []types.NodeStatus, cnt int, err error) { diff --git a/core/services/blockhashstore/bhs_test.go b/core/services/blockhashstore/bhs_test.go index 79494ea41f6..d0e5ac71a7b 100644 --- a/core/services/blockhashstore/bhs_test.go +++ b/core/services/blockhashstore/bhs_test.go @@ -30,7 +30,8 @@ func TestStoreRotatesFromAddresses(t *testing.T) { kst := cltest.NewKeyStore(t, db, cfg.Database()) require.NoError(t, kst.Unlock(cltest.Password)) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, KeyStore: kst.Eth(), GeneralConfig: cfg, Client: ethClient}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) chain, err := legacyChains.Get(cltest.FixtureChainID.String()) require.NoError(t, err) lggr := logger.TestLogger(t) diff --git a/core/services/blockhashstore/delegate_test.go b/core/services/blockhashstore/delegate_test.go index 43faba94dd8..b0456206861 100644 --- a/core/services/blockhashstore/delegate_test.go +++ b/core/services/blockhashstore/delegate_test.go @@ -70,7 +70,8 @@ func createTestDelegate(t *testing.T) (*blockhashstore.Delegate, *testData) { LogPoller: lp, }, ) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) return blockhashstore.NewDelegate(lggr, legacyChains, kst), &testData{ ethClient: ethClient, ethKeyStore: kst, diff --git a/core/services/chainlink/relayer_chain_interoperators.go b/core/services/chainlink/relayer_chain_interoperators.go index 4d92fef53d2..e4de1352925 100644 --- a/core/services/chainlink/relayer_chain_interoperators.go +++ b/core/services/chainlink/relayer_chain_interoperators.go @@ -116,7 +116,11 @@ func InitEVM(ctx context.Context, factory RelayerFactory, config EVMFactoryConfi } } - op.legacyChains.EVMChains = evm.NewLegacyChains(config.OperationalConfigs, legacyMap) + legacy, err := evm.NewLegacyChains(config.AppConfig, legacyMap) + if err != nil { + return err + } + op.legacyChains.EVMChains = legacy // TODO BCF-2510 this may not be necessary if EVM is not enabled by default if defaultChain != nil { op.legacyChains.EVMChains.SetDefault(defaultChain) @@ -265,7 +269,7 @@ func (rs *CoreRelayerChainInteroperators) Node(ctx context.Context, name string) return stat, nil } } - return types.NodeStatus{}, chains.ErrNotFound + return types.NodeStatus{}, fmt.Errorf("node %s: %w", name, chains.ErrNotFound) } // ids must be a string representation of relay.Identifier diff --git a/core/services/chainlink/relayer_chain_interoperators_test.go b/core/services/chainlink/relayer_chain_interoperators_test.go index ebd528a2bc5..acdb05f1776 100644 --- a/core/services/chainlink/relayer_chain_interoperators_test.go +++ b/core/services/chainlink/relayer_chain_interoperators_test.go @@ -203,7 +203,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { initFuncs: []chainlink.CoreRelayerChainInitFunc{ chainlink.InitEVM(testctx, factory, chainlink.EVMFactoryConfig{ RelayerConfig: evm.RelayerConfig{ - GeneralConfig: cfg, + AppConfig: cfg, EventBroadcaster: pg.NewNullEventBroadcaster(), MailMon: &utils.MailboxMonitor{}, }, @@ -265,7 +265,7 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { SolanaConfigs: cfg.SolanaConfigs()}), chainlink.InitEVM(testctx, factory, chainlink.EVMFactoryConfig{ RelayerConfig: evm.RelayerConfig{ - GeneralConfig: cfg, + AppConfig: cfg, EventBroadcaster: pg.NewNullEventBroadcaster(), MailMon: &utils.MailboxMonitor{}, }, diff --git a/core/services/chainlink/relayer_factory.go b/core/services/chainlink/relayer_factory.go index ded4d1886f8..51f18b7e61b 100644 --- a/core/services/chainlink/relayer_factory.go +++ b/core/services/chainlink/relayer_factory.go @@ -55,7 +55,10 @@ func (r *RelayerFactory) NewEVM(ctx context.Context, config EVMFactoryConfig) (m if err != nil { return nil, err } - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(evmRelayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(evmRelayExtenders) + if err != nil { + return nil, err + } for _, ext := range evmRelayExtenders.Slice() { relayID := relay.ID{Network: relay.EVM, ChainID: relay.ChainID(ext.Chain().ID().String())} chain, err := legacyChains.Get(relayID.ChainID.String()) diff --git a/core/services/cron/cron_test.go b/core/services/cron/cron_test.go index 1ea37578fc8..1d89248d4a5 100644 --- a/core/services/cron/cron_test.go +++ b/core/services/cron/cron_test.go @@ -32,7 +32,8 @@ func TestCronV2Pipeline(t *testing.T) { lggr := logger.TestLogger(t) orm := pipeline.NewORM(db, lggr, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, lggr, cfg.Database()) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + require.NoError(t, err) jobORM := job.NewORM(db, legacyChains, orm, btORM, keyStore, lggr, cfg.Database()) jb := &job.Job{ @@ -44,7 +45,7 @@ func TestCronV2Pipeline(t *testing.T) { } delegate := cron.NewDelegate(runner, lggr) - err := jobORM.CreateJob(jb) + err = jobORM.CreateJob(jb) require.NoError(t, err) serviceArray, err := delegate.ServicesForSpec(*jb) require.NoError(t, err) diff --git a/core/services/directrequest/delegate_test.go b/core/services/directrequest/delegate_test.go index 68b447e6652..8a453dbe9db 100644 --- a/core/services/directrequest/delegate_test.go +++ b/core/services/directrequest/delegate_test.go @@ -47,7 +47,8 @@ func TestDelegate_ServicesForSpec(t *testing.T) { relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, MailMon: mailMon, KeyStore: keyStore.Eth()}) lggr := logger.TestLogger(t) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + require.NoError(t, err) delegate := directrequest.NewDelegate(lggr, runner, nil, legacyChains, mailMon) t.Run("Spec without DirectRequestSpec", func(t *testing.T) { @@ -88,7 +89,8 @@ func NewDirectRequestUniverseWithConfig(t *testing.T, cfg chainlink.GeneralConfi lggr := logger.TestLogger(t) orm := pipeline.NewORM(db, lggr, cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, lggr, cfg.Database()) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jobORM := job.NewORM(db, legacyChains, orm, btORM, keyStore, lggr, cfg.Database()) delegate := directrequest.NewDelegate(lggr, runner, orm, legacyChains, mailMon) @@ -97,7 +99,7 @@ func NewDirectRequestUniverseWithConfig(t *testing.T, cfg chainlink.GeneralConfi if specF != nil { specF(jb) } - err := jobORM.CreateJob(jb) + err = jobORM.CreateJob(jb) require.NoError(t, err) serviceArray, err := delegate.ServicesForSpec(*jb) require.NoError(t, err) diff --git a/core/services/feeds/orm_test.go b/core/services/feeds/orm_test.go index b9180651160..0ff60188008 100644 --- a/core/services/feeds/orm_test.go +++ b/core/services/feeds/orm_test.go @@ -1474,10 +1474,10 @@ func createJob(t *testing.T, db *sqlx.DB, externalJobID uuid.UUID) *job.Job { pipelineORM = pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgeORM = bridges.NewORM(db, lggr, config.Database()) relayExtenders = evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains = evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) - orm = job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, lggr, config.Database()) ) - + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) + orm := job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, lggr, config.Database()) require.NoError(t, keyStore.OCR().Add(cltest.DefaultOCRKey)) require.NoError(t, keyStore.P2P().Add(cltest.DefaultP2PKey)) diff --git a/core/services/feeds/service_test.go b/core/services/feeds/service_test.go index 3b9bedaf023..48fefd35daf 100644 --- a/core/services/feeds/service_test.go +++ b/core/services/feeds/service_test.go @@ -181,7 +181,8 @@ func setupTestServiceCfg(t *testing.T, overrideCfg func(c *chainlink.Config, s * ethKeyStore := cltest.NewKeyStore(t, db, gcfg.Database()).Eth() relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{GeneralConfig: gcfg, HeadTracker: headtracker.NullTracker, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) keyStore.On("Eth").Return(ethKeyStore) keyStore.On("CSA").Return(csaKeystore) keyStore.On("P2P").Return(p2pKeystore) diff --git a/core/services/fluxmonitorv2/orm_test.go b/core/services/fluxmonitorv2/orm_test.go index f02ebb61f60..e7185efa7bd 100644 --- a/core/services/fluxmonitorv2/orm_test.go +++ b/core/services/fluxmonitorv2/orm_test.go @@ -95,7 +95,8 @@ func TestORM_UpdateFluxMonitorRoundStats(t *testing.T) { bridgeORM := bridges.NewORM(db, lggr, cfg.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{GeneralConfig: cfg, DB: db, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) // Instantiate a real job ORM because we need to create a job to satisfy // a check in pipeline.CreateRun jobORM := job.NewORM(db, legacyChains, pipelineORM, bridgeORM, keyStore, lggr, cfg.Database()) @@ -105,7 +106,7 @@ func TestORM_UpdateFluxMonitorRoundStats(t *testing.T) { var roundID uint32 = 1 jb := makeJob(t) - err := jobORM.CreateJob(jb) + err = jobORM.CreateJob(jb) require.NoError(t, err) for expectedCount := uint64(1); expectedCount < 4; expectedCount++ { diff --git a/core/services/functions/listener_test.go b/core/services/functions/listener_test.go index f8db766c31c..0c74b0563f4 100644 --- a/core/services/functions/listener_test.go +++ b/core/services/functions/listener_test.go @@ -90,7 +90,8 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe db := pgtest.NewSqlxDB(t) kst := cltest.NewKeyStore(t, db, cfg.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, Client: ethClient, KeyStore: kst.Eth(), LogBroadcaster: broadcaster, MailMon: mailMon}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) chain := legacyChains.Slice()[0] lggr := logger.TestLogger(t) @@ -126,7 +127,7 @@ func NewFunctionsListenerUniverse(t *testing.T, timeoutSec int, pruneFrequencySe decryptor := threshold_mocks.NewDecryptor(t) var pluginConfig config.PluginConfig - err := json.Unmarshal(jsonConfig.Bytes(), &pluginConfig) + err = json.Unmarshal(jsonConfig.Bytes(), &pluginConfig) require.NoError(t, err) contractAddress := "0xa" diff --git a/core/services/job/helpers_test.go b/core/services/job/helpers_test.go index 21f3a8daa99..106ba8d27c7 100644 --- a/core/services/job/helpers_test.go +++ b/core/services/job/helpers_test.go @@ -220,8 +220,9 @@ func makeMinimalHTTPOracleSpec(t *testing.T, db *sqlx.DB, cfg chainlink.GeneralC s := fmt.Sprintf(minimalNonBootstrapTemplate, contractAddress, transmitterAddress, keyBundle, fetchUrl, timeout) keyStore := cltest.NewKeyStore(t, db, pgtest.NewQConfig(true)) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: evmtest.NewEthClientMockWithDefaultChain(t), GeneralConfig: cfg, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) - _, err := ocr.ValidatedOracleSpecToml(legacyChains, s) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) + _, err = ocr.ValidatedOracleSpecToml(legacyChains, s) require.NoError(t, err) err = toml.Unmarshal([]byte(s), &os) require.NoError(t, err) diff --git a/core/services/job/job_orm_test.go b/core/services/job/job_orm_test.go index 7c10337159a..0f70e74b247 100644 --- a/core/services/job/job_orm_test.go +++ b/core/services/job/job_orm_test.go @@ -83,7 +83,8 @@ func TestORM(t *testing.T) { bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) borm := bridges.NewORM(db, logger.TestLogger(t), config.Database()) @@ -316,7 +317,8 @@ func TestORM_DeleteJob_DeletesAssociatedRecords(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) scopedConfig := evmtest.NewChainScopedConfig(t, config) korm := keeper.NewORM(db, logger.TestLogger(t), scopedConfig.Database()) @@ -416,7 +418,9 @@ func TestORM_CreateJob_VRFV2(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) + jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) fromAddresses := []string{cltest.NewEIP55Address().String(), cltest.NewEIP55Address().String()} @@ -498,8 +502,8 @@ func TestORM_CreateJob_VRFV2Plus(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) - + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + require.NoError(t, err) jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) fromAddresses := []string{cltest.NewEIP55Address().String(), cltest.NewEIP55Address().String()} @@ -584,7 +588,8 @@ func TestORM_CreateJob_OCRBootstrap(t *testing.T) { pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := ocrbootstrap.ValidatedBootstrapSpecToml(testspecs.OCRBootstrapSpec) @@ -624,7 +629,8 @@ func TestORM_CreateJob_OCR_DuplicatedContractAddress(t *testing.T) { bridgesORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) defaultChainID := config.DefaultChainID() @@ -758,7 +764,8 @@ func TestORM_CreateJob_OCR2_DuplicatedContractAddress(t *testing.T) { bridgesORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) @@ -820,10 +827,10 @@ func TestORM_CreateJob_OCR2_Sending_Keys_Transmitter_Keys_Validations(t *testing pipelineORM := pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) - //cc := evmtest.NewChainSet(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - require.True(t, relayerExtenders.Len() > 0) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + require.True(t, relayExtenders.Len() > 0) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jobORM := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := ocr2validate.ValidatedOracleSpecToml(config.OCR2(), config.Insecure(), testspecs.OCR2EVMSpecMinimal) @@ -935,7 +942,8 @@ func Test_FindJobs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -1015,8 +1023,9 @@ func Test_FindJob(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -1233,7 +1242,8 @@ func Test_FindJobsByPipelineSpecIDs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) @@ -1273,8 +1283,9 @@ func Test_FindPipelineRuns(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -1335,7 +1346,8 @@ func Test_PipelineRunsByJobID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -1396,7 +1408,8 @@ func Test_FindPipelineRunIDsByJobID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, address := cltest.MustInsertRandomKey(t, keyStore.Eth()) @@ -1504,7 +1517,8 @@ func Test_FindPipelineRunsByIDs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) @@ -1561,8 +1575,9 @@ func Test_FindPipelineRunByID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) - cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) @@ -1607,7 +1622,8 @@ func Test_FindJobWithoutSpecErrors(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) @@ -1646,7 +1662,8 @@ func Test_FindSpecErrorsByJobIDs(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) jb, err := directrequest.ValidatedDirectRequestSpec(testspecs.DirectRequestSpec) @@ -1682,7 +1699,8 @@ func Test_CountPipelineRunsByJobID(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) bridgesORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := NewTestORM(t, db, legacyChains, pipelineORM, bridgesORM, keyStore, config.Database()) _, bridge := cltest.MustCreateBridge(t, db, cltest.BridgeOpts{}, config.Database()) diff --git a/core/services/job/job_pipeline_orm_integration_test.go b/core/services/job/job_pipeline_orm_integration_test.go index cc459d7edff..ff1cab4f3c6 100644 --- a/core/services/job/job_pipeline_orm_integration_test.go +++ b/core/services/job/job_pipeline_orm_integration_test.go @@ -152,7 +152,8 @@ func TestPipelineORM_Integration(t *testing.T) { orm := pipeline.NewORM(db, logger.TestLogger(t), cfg.Database(), cfg.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, logger.TestLogger(t), cfg.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{Client: evmtest.NewEthClientMockWithDefaultChain(t), DB: db, GeneralConfig: config, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) runner := pipeline.NewRunner(orm, btORM, config.JobPipeline(), cfg.WebServer(), legacyChains, nil, nil, lggr, nil, nil) jobORM := NewTestORM(t, db, legacyChains, orm, btORM, keyStore, cfg.Database()) @@ -160,7 +161,7 @@ func TestPipelineORM_Integration(t *testing.T) { dbSpec := makeVoterTurnoutOCRJobSpec(t, transmitterAddress, bridge.Name.String(), bridge2.Name.String()) // Need a job in order to create a run - err := jobORM.CreateJob(dbSpec) + err = jobORM.CreateJob(dbSpec) require.NoError(t, err) var pipelineSpecs []pipeline.Spec diff --git a/core/services/job/runner_integration_test.go b/core/services/job/runner_integration_test.go index 2c12658a09f..8418ae999bb 100644 --- a/core/services/job/runner_integration_test.go +++ b/core/services/job/runner_integration_test.go @@ -82,7 +82,8 @@ func TestRunner(t *testing.T) { pipelineORM := pipeline.NewORM(db, logger.TestLogger(t), config.Database(), config.JobPipeline().MaxSuccessfulRuns()) btORM := bridges.NewORM(db, logger.TestLogger(t), config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: ethClient, GeneralConfig: config, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) c := clhttptest.NewTestLocalOnlyHTTPClient() runner := pipeline.NewRunner(pipelineORM, btORM, config.JobPipeline(), config.WebServer(), legacyChains, nil, nil, logger.TestLogger(t), c, c) @@ -766,7 +767,8 @@ func TestRunner_Success_Callback_AsyncJob(t *testing.T) { app := cltest.NewApplicationWithConfig(t, cfg, ethClient, cltest.UseRealExternalInitiatorManager) keyStore := cltest.NewKeyStore(t, app.GetSqlxDB(), pgtest.NewQConfig(true)) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: app.GetSqlxDB(), Client: ethClient, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) require.NoError(t, app.Start(testutils.Context(t))) var ( @@ -948,7 +950,8 @@ func TestRunner_Error_Callback_AsyncJob(t *testing.T) { app := cltest.NewApplicationWithConfig(t, cfg, ethClient, cltest.UseRealExternalInitiatorManager) keyStore := cltest.NewKeyStore(t, app.GetSqlxDB(), pgtest.NewQConfig(true)) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: app.GetSqlxDB(), Client: ethClient, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) require.NoError(t, app.Start(testutils.Context(t))) diff --git a/core/services/job/spawner_test.go b/core/services/job/spawner_test.go index f35aa50ba4d..de6ca541e59 100644 --- a/core/services/job/spawner_test.go +++ b/core/services/job/spawner_test.go @@ -94,7 +94,8 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { Return(nil).Maybe() relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: ethClient, GeneralConfig: config, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) t.Run("should respect its dependents", func(t *testing.T) { lggr := logger.TestLogger(t) orm := NewTestORM(t, db, legacyChains, pipeline.NewORM(db, lggr, config.Database(), config.JobPipeline().MaxSuccessfulRuns()), bridges.NewORM(db, lggr, config.Database()), keyStore, config.Database()) @@ -279,7 +280,8 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { lggr := logger.TestLogger(t) relayExtenders := evmtest.NewChainRelayExtenders(t, testopts) assert.Equal(t, relayExtenders.Len(), 1) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) chain := evmtest.MustGetDefaultChain(t, legacyChains) evmRelayer := evmrelayer.NewRelayer(testopts.DB, chain, testopts.GeneralConfig.Database(), lggr, keyStore, pg.NewNullEventBroadcaster()) @@ -304,7 +306,7 @@ func TestSpawner_CreateJobDeleteJob(t *testing.T) { jobOCR2VRF.Type: delegateOCR2, }, db, lggr, nil) - err := spawner.CreateJob(jobOCR2VRF) + err = spawner.CreateJob(jobOCR2VRF) require.NoError(t, err) jobSpecID := jobOCR2VRF.ID delegateOCR2.jobID = jobOCR2VRF.ID diff --git a/core/services/keeper/registry_synchronizer_helper_test.go b/core/services/keeper/registry_synchronizer_helper_test.go index 6b9bb815a89..c3fadc8bcf4 100644 --- a/core/services/keeper/registry_synchronizer_helper_test.go +++ b/core/services/keeper/registry_synchronizer_helper_test.go @@ -44,7 +44,8 @@ func setupRegistrySync(t *testing.T, version keeper.RegistryVersion) ( lbMock.On("AddDependents", 1).Maybe() j := cltest.MustInsertKeeperJob(t, db, korm, cltest.NewEIP55Address(), cltest.NewEIP55Address()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, Client: ethClient, LogBroadcaster: lbMock, GeneralConfig: cfg, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) ch := evmtest.MustGetDefaultChain(t, legacyChains) jpv2 := cltest.NewJobPipelineV2(t, cfg.WebServer(), cfg.JobPipeline(), cfg.Database(), legacyChains, db, keyStore, nil, nil) contractAddress := j.KeeperSpec.ContractAddress.Address() diff --git a/core/services/keeper/upkeep_executer_test.go b/core/services/keeper/upkeep_executer_test.go index 633372395d1..0f15f3949ba 100644 --- a/core/services/keeper/upkeep_executer_test.go +++ b/core/services/keeper/upkeep_executer_test.go @@ -76,7 +76,8 @@ func setup(t *testing.T, estimator gas.EvmFeeEstimator, overrideFn func(c *chain ethClient.On("HeadByNumber", mock.Anything, mock.Anything).Maybe().Return(&evmtypes.Head{Number: 1, Hash: utils.NewHash()}, nil) txm := txmmocks.NewMockEvmTxManager(t) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{TxManager: txm, DB: db, Client: ethClient, KeyStore: keyStore.Eth(), GeneralConfig: cfg, GasEstimator: estimator}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jpv2 := cltest.NewJobPipelineV2(t, cfg.WebServer(), cfg.JobPipeline(), cfg.Database(), legacyChains, db, keyStore, nil, nil) ch := evmtest.MustGetDefaultChain(t, legacyChains) orm := keeper.NewORM(db, logger.TestLogger(t), ch.Config().Database()) @@ -84,7 +85,7 @@ func setup(t *testing.T, estimator gas.EvmFeeEstimator, overrideFn func(c *chain lggr := logger.TestLogger(t) executer := keeper.NewUpkeepExecuter(job, orm, jpv2.Pr, ethClient, ch.HeadBroadcaster(), ch.GasEstimator(), lggr, ch.Config().Keeper(), job.KeeperSpec.FromAddress.Address()) upkeep := cltest.MustInsertUpkeepForRegistry(t, db, ch.Config().Database(), registry) - err := executer.Start(testutils.Context(t)) + err = executer.Start(testutils.Context(t)) t.Cleanup(func() { executer.Close() }) require.NoError(t, err) return db, cfg, ethClient, executer, registry, upkeep, job, jpv2, txm, keyStore, ch, orm diff --git a/core/services/ocr2/delegate_test.go b/core/services/ocr2/delegate_test.go index 066b2eb2876..af4c9355b0a 100644 --- a/core/services/ocr2/delegate_test.go +++ b/core/services/ocr2/delegate_test.go @@ -43,9 +43,10 @@ func TestGetEVMEffectiveTransmitterID(t *testing.T) { lggr := logger.TestLogger(t) txManager := txmmocks.NewMockEvmTxManager(t) - relayerExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth(), TxManager: txManager}) - require.True(t, relayerExtenders.Len() > 0) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayerExtenders) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth(), TxManager: txManager}) + require.True(t, relayExtenders.Len() > 0) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) type testCase struct { name string diff --git a/core/services/pipeline/orm_test.go b/core/services/pipeline/orm_test.go index 4c03ce16ef8..0863226e647 100644 --- a/core/services/pipeline/orm_test.go +++ b/core/services/pipeline/orm_test.go @@ -522,7 +522,8 @@ func Test_GetUnfinishedRuns_Keepers(t *testing.T) { bridgeORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jorm := job.NewORM(db, legacyChains, porm, bridgeORM, keyStore, lggr, config.Database()) defer func() { assert.NoError(t, jorm.Close()) }() @@ -547,7 +548,7 @@ func Test_GetUnfinishedRuns_Keepers(t *testing.T) { MaxTaskDuration: models.Interval(1 * time.Minute), } - err := jorm.CreateJob(&keeperJob) + err = jorm.CreateJob(&keeperJob) require.NoError(t, err) require.Equal(t, job.Keeper, keeperJob.Type) @@ -624,7 +625,8 @@ func Test_GetUnfinishedRuns_DirectRequest(t *testing.T) { bridgeORM := bridges.NewORM(db, lggr, config.Database()) relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: config, KeyStore: keyStore.Eth()}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jorm := job.NewORM(db, legacyChains, porm, bridgeORM, keyStore, lggr, config.Database()) defer func() { assert.NoError(t, jorm.Close()) }() @@ -648,7 +650,7 @@ func Test_GetUnfinishedRuns_DirectRequest(t *testing.T) { MaxTaskDuration: models.Interval(1 * time.Minute), } - err := jorm.CreateJob(&drJob) + err = jorm.CreateJob(&drJob) require.NoError(t, err) require.Equal(t, job.DirectRequest, drJob.Type) diff --git a/core/services/pipeline/runner_test.go b/core/services/pipeline/runner_test.go index 2554315a46c..1b13289289e 100644 --- a/core/services/pipeline/runner_test.go +++ b/core/services/pipeline/runner_test.go @@ -44,7 +44,8 @@ func newRunner(t testing.TB, db *sqlx.DB, bridgeORM bridges.ORM, cfg chainlink.G lggr := logger.TestLogger(t) ethKeyStore := cltest.NewKeyStore(t, db, cfg.Database()).Eth() relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) orm := mocks.NewORM(t) q := pg.NewQ(db, lggr, cfg.Database()) @@ -481,7 +482,8 @@ func Test_PipelineRunner_HandleFaultsPersistRun(t *testing.T) { cfg := configtest.NewTestGeneralConfig(t) ethKeyStore := cltest.NewKeyStore(t, db, cfg.Database()).Eth() relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, KeyStore: ethKeyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) lggr := logger.TestLogger(t) r := pipeline.NewRunner(orm, btORM, cfg.JobPipeline(), cfg.WebServer(), legacyChains, ethKeyStore, nil, lggr, nil, nil) diff --git a/core/services/pipeline/task.eth_call_test.go b/core/services/pipeline/task.eth_call_test.go index b8896488e2d..8d7f128a0d4 100644 --- a/core/services/pipeline/task.eth_call_test.go +++ b/core/services/pipeline/task.eth_call_test.go @@ -258,9 +258,11 @@ func TestETHCallTask(t *testing.T) { db := pgtest.NewSqlxDB(t) var legacyChains evm.LegacyChainContainer + var err error if test.expectedErrorCause != nil || test.expectedErrorContains != "" { exts := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, TxManager: txManager, KeyStore: keyStore}) - legacyChains = evmrelay.NewLegacyChainsFromRelayerExtenders(exts) + legacyChains, err = evmrelay.NewLegacyChainsFromRelayerExtenders(exts) + require.NoError(t, err) } else { legacyChains = cltest.NewLegacyChainsWithMockChain(t, ethClient, cfg) } diff --git a/core/services/pipeline/task.eth_tx_test.go b/core/services/pipeline/task.eth_tx_test.go index d465c16f8fd..83f855c9982 100644 --- a/core/services/pipeline/task.eth_tx_test.go +++ b/core/services/pipeline/task.eth_tx_test.go @@ -575,7 +575,8 @@ func TestETHTxTask(t *testing.T) { relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{DB: db, GeneralConfig: cfg, TxManager: txManager, KeyStore: keyStore}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) test.setupClientMocks(keyStore, txManager) task.HelperSetDependencies(legacyChains, keyStore, test.specGasLimit, pipeline.DirectRequestJobType) diff --git a/core/services/relay/evm/relayer_extender.go b/core/services/relay/evm/relayer_extender.go index 865816143e2..cab804e5883 100644 --- a/core/services/relay/evm/relayer_extender.go +++ b/core/services/relay/evm/relayer_extender.go @@ -13,6 +13,7 @@ import ( relaytypes "github.com/smartcontractkit/chainlink-relay/pkg/types" "github.com/smartcontractkit/chainlink/v2/core/chains" + "github.com/smartcontractkit/chainlink/v2/core/chains/evm" evmchain "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" evmtypes "github.com/smartcontractkit/chainlink/v2/core/chains/evm/types" @@ -51,17 +52,17 @@ type EVMChainRelayerExtender interface { type EVMChainRelayerExtenderSlicer interface { Slice() []EVMChainRelayerExtender Len() int - ChainNodeConfigs() evmtypes.Configs + AppConfig() evmchain.AppConfig } type ChainRelayerExtenders struct { exts []EVMChainRelayerExtender - cfgs evmtypes.Configs + cfg evmchain.AppConfig } var _ EVMChainRelayerExtenderSlicer = &ChainRelayerExtenders{} -func NewLegacyChainsFromRelayerExtenders(exts EVMChainRelayerExtenderSlicer) *evmchain.LegacyChains { +func NewLegacyChainsFromRelayerExtenders(exts EVMChainRelayerExtenderSlicer) (*evmchain.LegacyChains, error) { m := make(map[string]evmchain.Chain) var dflt evmchain.Chain @@ -71,25 +72,29 @@ func NewLegacyChainsFromRelayerExtenders(exts EVMChainRelayerExtenderSlicer) *ev dflt = r.Chain() } } - l := evmchain.NewLegacyChains(exts.ChainNodeConfigs(), m) + l, err := evmchain.NewLegacyChains(exts.AppConfig(), m) + if err != nil { + return nil, err + } if dflt != nil { l.SetDefault(dflt) } - return l + return l, nil } -func newChainRelayerExtsFromSlice(exts []*ChainRelayerExt) *ChainRelayerExtenders { +func newChainRelayerExtsFromSlice(exts []*ChainRelayerExt, appConfig evm.AppConfig) *ChainRelayerExtenders { temp := make([]EVMChainRelayerExtender, len(exts)) for i := range exts { temp[i] = exts[i] } return &ChainRelayerExtenders{ exts: temp, + cfg: appConfig, } } -func (c *ChainRelayerExtenders) ChainNodeConfigs() evmtypes.Configs { - return c.cfgs +func (c *ChainRelayerExtenders) AppConfig() evmchain.AppConfig { + return c.cfg } func (c *ChainRelayerExtenders) Slice() []EVMChainRelayerExtender { @@ -191,11 +196,11 @@ type chainSet struct { } func (cll *chainSet) Start(ctx context.Context) error { - if !cll.opts.GeneralConfig.EVMEnabled() { + if !cll.opts.AppConfig.EVMEnabled() { cll.logger.Warn("EVM is disabled, no EVM-based chains will be started") return nil } - if !cll.opts.GeneralConfig.EVMRPCEnabled() { + if !cll.opts.AppConfig.EVMRPCEnabled() { cll.logger.Warn("EVM RPC connections are disabled. Chainlink will not connect to any EVM RPC node.") } var ms services.MultiStart @@ -268,13 +273,13 @@ func (cll *chainSet) get(id string) (evmchain.Chain, error) { func (cll *chainSet) ChainStatus(ctx context.Context, id string) (cfg relaytypes.ChainStatus, err error) { var cs []relaytypes.ChainStatus - cs, _, err = cll.opts.OperationalConfigs.Chains(0, -1, id) + cs, _, err = cll.opts.EVMConfigs().Chains(0, -1, id) if err != nil { return } l := len(cs) if l == 0 { - err = chains.ErrNotFound + err = fmt.Errorf("chain %s: %w", id, chains.ErrNotFound) return } if l > 1 { @@ -286,7 +291,7 @@ func (cll *chainSet) ChainStatus(ctx context.Context, id string) (cfg relaytypes } func (cll *chainSet) ChainStatuses(ctx context.Context, offset, limit int) ([]relaytypes.ChainStatus, int, error) { - return cll.opts.OperationalConfigs.Chains(offset, limit) + return cll.opts.EVMConfigs().Chains(offset, limit) } func (cll *chainSet) Default() (evmchain.Chain, error) { @@ -321,11 +326,11 @@ func (cll *chainSet) ChainCount() int { } func (cll *chainSet) Configs() evmtypes.Configs { - return cll.opts.OperationalConfigs + return cll.opts.EVMConfigs() } func (cll *chainSet) NodeStatuses(ctx context.Context, offset, limit int, chainIDs ...string) (nodes []relaytypes.NodeStatus, count int, err error) { - nodes, count, err = cll.opts.OperationalConfigs.NodeStatusesPaged(offset, limit, chainIDs...) + nodes, count, err = cll.opts.EVMConfigs().NodeStatusesPaged(offset, limit, chainIDs...) if err != nil { err = errors.Wrap(err, "GetNodesForChain failed to load nodes from DB") return @@ -372,7 +377,7 @@ func NewChainRelayerExtenders(ctx context.Context, opts evmchain.ChainRelayExten if err := opts.Check(); err != nil { return nil, err } - evmConfigs := opts.GeneralConfig.EVMConfigs() + evmConfigs := opts.AppConfig.EVMConfigs() var enabled []*toml.EVMConfig for i := range evmConfigs { if evmConfigs[i].IsEnabled() { @@ -380,7 +385,7 @@ func NewChainRelayerExtenders(ctx context.Context, opts evmchain.ChainRelayExten } } - defaultChainID := opts.GeneralConfig.DefaultChainID() + defaultChainID := opts.AppConfig.DefaultChainID() if defaultChainID == nil && len(enabled) >= 1 { defaultChainID = enabled[0].ChainID.ToInt() if len(enabled) > 1 { @@ -419,7 +424,7 @@ func NewChainRelayerExtenders(ctx context.Context, opts evmchain.ChainRelayExten } result = append(result, s) } - return newChainRelayerExtsFromSlice(result), nil + return newChainRelayerExtsFromSlice(result, opts.AppConfig), nil } func newChainSet(opts evmchain.ChainRelayExtenderConfig) *chainSet { diff --git a/core/services/vrf/delegate_test.go b/core/services/vrf/delegate_test.go index a965008509d..dba1d818ed4 100644 --- a/core/services/vrf/delegate_test.go +++ b/core/services/vrf/delegate_test.go @@ -78,8 +78,9 @@ func buildVrfUni(t *testing.T, db *sqlx.DB, cfg chainlink.GeneralConfig) vrfUniv btORM := bridges.NewORM(db, lggr, cfg.Database()) txm := txmmocks.NewMockEvmTxManager(t) ks := keystore.New(db, utils.FastScryptParams, lggr, cfg.Database()) - cc := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{LogBroadcaster: lb, KeyStore: ks.Eth(), Client: ec, DB: db, GeneralConfig: cfg, TxManager: txm}) - legacyChains := evmrelay.NewLegacyChainsFromRelayerExtenders(cc) + relayExtenders := evmtest.NewChainRelayExtenders(t, evmtest.TestChainOpts{LogBroadcaster: lb, KeyStore: ks.Eth(), Client: ec, DB: db, GeneralConfig: cfg, TxManager: txm}) + legacyChains, err := evmrelay.NewLegacyChainsFromRelayerExtenders(relayExtenders) + require.NoError(t, err) jrm := job.NewORM(db, legacyChains, prm, btORM, ks, lggr, cfg.Database()) t.Cleanup(func() { jrm.Close() }) pr := pipeline.NewRunner(prm, btORM, cfg.JobPipeline(), cfg.WebServer(), legacyChains, ks.Eth(), ks.VRF(), lggr, nil, nil) diff --git a/core/web/resolver/eth_key_test.go b/core/web/resolver/eth_key_test.go index 5fb5fd3d2a6..0df24ef9ff1 100644 --- a/core/web/resolver/eth_key_test.go +++ b/core/web/resolver/eth_key_test.go @@ -8,13 +8,15 @@ import ( gqlerrors "github.com/graph-gophers/graphql-go/errors" "github.com/pkg/errors" "github.com/stretchr/testify/mock" + "github.com/stretchr/testify/require" "github.com/smartcontractkit/chainlink/v2/core/assets" "github.com/smartcontractkit/chainlink/v2/core/chains/evm" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config" mocks2 "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/mocks" "github.com/smartcontractkit/chainlink/v2/core/chains/evm/config/toml" - "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" + configtest "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/configtest/v2" + "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/ethkey" evmrelay "github.com/smartcontractkit/chainlink/v2/core/services/relay/evm" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -87,9 +89,10 @@ func TestResolver_ETHKeys(t *testing.T) { chainID := *utils.NewBigI(12) linkAddr := common.HexToAddress("0x5431F5F973781809D18643b87B44921b11355d81") - cfg := evmtest.NewTestConfigs() + cfg := configtest.NewGeneralConfig(t, nil) m := map[string]evm.Chain{states[0].EVMChainID.String(): f.Mocks.chain} - legacyEVMChains := evm.NewLegacyChains(cfg, m) + legacyEVMChains, err := evm.NewLegacyChains(cfg, m) + require.NoError(t, err) f.Mocks.ethKs.On("GetStatesForKeys", keys).Return(states, nil) f.Mocks.ethKs.On("Get", keys[0].Address.Hex()).Return(keys[0], nil) diff --git a/core/web/resolver/query.go b/core/web/resolver/query.go index 3ae8b77b6db..05a778a6624 100644 --- a/core/web/resolver/query.go +++ b/core/web/resolver/query.go @@ -222,10 +222,13 @@ func (r *Resolver) Node(ctx context.Context, args struct{ ID graphql.ID }) (*Nod if err := authenticateUser(ctx); err != nil { return nil, err } - + r.App.GetLogger().Debug("resolver Node args %v", args) name := string(args.ID) + r.App.GetLogger().Debug("resolver Node name %s", name) node, err := r.App.EVMORM().NodeStatus(name) if err != nil { + r.App.GetLogger().Errorw("resolver getting node status", "err", err) + if errors.Is(err, chains.ErrNotFound) { npr, warn := NewNodePayloadResolver(nil, err) if warn != nil { @@ -325,9 +328,12 @@ func (r *Resolver) Nodes(ctx context.Context, args struct { offset := pageOffset(args.Offset) limit := pageLimit(args.Limit) - + r.App.GetLogger().Debugw("resolver Nodes query", "offset", offset, "limit", limit) allNodes, total, err := r.App.GetRelayers().NodeStatuses(ctx, offset, limit) + r.App.GetLogger().Debugw("resolver Nodes query result", "nodes", allNodes, "total", total, "err", err) + if err != nil { + r.App.GetLogger().Errorw("Error creating get nodes status from app", "err", err) return nil, err } npr, warn := NewNodesPayload(allNodes, int32(total)) diff --git a/core/web/resolver/resolver_test.go b/core/web/resolver/resolver_test.go index 16a91c54d38..d0523d6b968 100644 --- a/core/web/resolver/resolver_test.go +++ b/core/web/resolver/resolver_test.go @@ -18,6 +18,7 @@ import ( coremocks "github.com/smartcontractkit/chainlink/v2/core/internal/mocks" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/evmtest" + "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/logger/audit" chainlinkMocks "github.com/smartcontractkit/chainlink/v2/core/services/chainlink/mocks" feedsMocks "github.com/smartcontractkit/chainlink/v2/core/services/feeds/mocks" @@ -118,7 +119,9 @@ func setupFramework(t *testing.T) *gqlTestFramework { auditLogger: &audit.AuditLoggerService{}, } + lggr := logger.TestLogger(t) app.Mock.On("GetAuditLogger", mock.Anything, mock.Anything).Return(audit.NoopLogger).Maybe() + app.Mock.On("GetLogger").Return(lggr).Maybe() f := &gqlTestFramework{ t: t, From ad4e9ce4db30cdbe3452c27519a2e4245ec118e5 Mon Sep 17 00:00:00 2001 From: Akshay Aggarwal <71980293+infiloop2@users.noreply.github.com> Date: Thu, 24 Aug 2023 14:04:02 +0100 Subject: [PATCH 260/270] update ocr2keepers to latest version (#10329) * update ocr2keepers to latest version * further fixes * fix tests --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 ++-- .../ocr2keeper/evm21/core/payload_test.go | 17 +++++++++++++++-- .../evm21/logprovider/recoverer_test.go | 6 +++--- go.mod | 2 +- go.sum | 4 ++-- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 ++-- 8 files changed, 27 insertions(+), 14 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 1c2ee9fd637..fcbb16a31c5 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -19,7 +19,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.16 + github.com/smartcontractkit/ocr2keepers v0.7.17 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/spf13/cobra v1.6.1 diff --git a/core/scripts/go.sum b/core/scripts/go.sum index caa7c1b6f44..cae9a6488f9 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1383,8 +1383,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.16 h1:brSHJIlm2tD8lbxxJOFVhSmXGU8bKoUC/3CEaYCPd/U= -github.com/smartcontractkit/ocr2keepers v0.7.16/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= +github.com/smartcontractkit/ocr2keepers v0.7.17 h1:847GG2SHyHIPc3yu+dhB+1HfeLRhSjyiKnhw3umpoJw= +github.com/smartcontractkit/ocr2keepers v0.7.17/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go index c0edf5ca278..f7b245ffce0 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/core/payload_test.go @@ -44,7 +44,20 @@ func TestWorkID(t *testing.T) { TxHash: common.HexToHash("0x12345"), }, }, - expected: "278fb23f812503265e1d8e8531e1df62ad593455917eed7872f24c634a048a11", + expected: "db0e245ff4e7551d6c862d9a0eb5466624e1439ad1db262a7a3d6137d892d0a3", + }, + { + name: "happy path example from an actual tx", + upkeepID: "57755329819103678328139927896464733492677608573736038892412245689671711489918", + trigger: ocr2keepers.Trigger{ + BlockNumber: 39344455, + BlockHash: common.HexToHash("0xb41258d18cd44ebf7a0d70de011f2bc4a67c9b68e8b6dada864045d8543bb020"), + LogTriggerExtension: &ocr2keepers.LogTriggerExtension{ + Index: 41, + TxHash: common.HexToHash("0x44079b1b33aff337dbf17b9e12c5724ecab979c50c8201a9814a488ff3e22384"), + }, + }, + expected: "cdb4cfd9b4855b28d243d099c41b832da6b2d99dda3e7d09b900899afd09328f", }, { name: "empty upkeepID", @@ -111,7 +124,7 @@ func TestNewUpkeepPayload(t *testing.T) { }, }, check: []byte("check-data-111"), - workID: "9fd4d46e09ad25e831fdee664dbaa3b68c37034303234bf70001e3577af43a4f", + workID: "d2fc1c0d626b480a4180f30b89142ae727c85e0b4dc0a82645bcef8062ff932a", }, } diff --git a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go index fbd09a1f778..ed2ce1b0347 100644 --- a/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go +++ b/core/services/ocr2/plugins/ocr2keeper/evm21/logprovider/recoverer_test.go @@ -221,7 +221,7 @@ func TestLogRecoverer_Recover(t *testing.T) { }, nil, nil, - []string{"ef1833ce5eb633189430bf52332ef8a1263ae20b9243f77be2809acb58966616"}, + []string{"84c83c79c2be2c3eabd8d35986a2a798d9187564d7f4f8f96c5a0f40f50bed3f"}, }, } @@ -691,7 +691,7 @@ func TestLogRecoverer_GetProposalData(t *testing.T) { } return t }(), - WorkID: "476453e1b49fc73fa6f97cb77272a07b57f2414a39b0267e58df8cb006d9c491", + WorkID: "d91c6f090b8477f434cf775182e4ff12c90618ba4da5b8ec06aa719768b7743a", }, logPoller: &mockLogPoller{ LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { @@ -734,7 +734,7 @@ func TestLogRecoverer_GetProposalData(t *testing.T) { } return t }(), - WorkID: "476453e1b49fc73fa6f97cb77272a07b57f2414a39b0267e58df8cb006d9c491", + WorkID: "d91c6f090b8477f434cf775182e4ff12c90618ba4da5b8ec06aa719768b7743a", }, logPoller: &mockLogPoller{ LatestBlockFn: func(qopts ...pg.QOpt) (int64, error) { diff --git a/go.mod b/go.mod index aad1a92b884..d40292e6453 100644 --- a/go.mod +++ b/go.mod @@ -70,7 +70,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.16 + github.com/smartcontractkit/ocr2keepers v0.7.17 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb diff --git a/go.sum b/go.sum index cf38be23ecc..71dd4f53e78 100644 --- a/go.sum +++ b/go.sum @@ -1383,8 +1383,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.16 h1:brSHJIlm2tD8lbxxJOFVhSmXGU8bKoUC/3CEaYCPd/U= -github.com/smartcontractkit/ocr2keepers v0.7.16/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= +github.com/smartcontractkit/ocr2keepers v0.7.17 h1:847GG2SHyHIPc3yu+dhB+1HfeLRhSjyiKnhw3umpoJw= +github.com/smartcontractkit/ocr2keepers v0.7.17/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 6674155de13..a7c1b00b75b 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -23,7 +23,7 @@ require ( github.com/smartcontractkit/chainlink-testing-framework v1.16.0 github.com/smartcontractkit/chainlink/v2 v2.0.0-00010101000000-000000000000 github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 - github.com/smartcontractkit/ocr2keepers v0.7.16 + github.com/smartcontractkit/ocr2keepers v0.7.17 github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 github.com/smartcontractkit/wasp v0.3.0 github.com/spf13/cobra v1.6.1 diff --git a/integration-tests/go.sum b/integration-tests/go.sum index de6fa60ca3a..74705e10b51 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2255,8 +2255,8 @@ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f h1:hgJ github.com/smartcontractkit/grpc-proxy v0.0.0-20230731113816-f1be6620749f/go.mod h1:MvMXoufZAtqExNexqi4cjrNYE9MefKddKylxjS+//n0= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 h1:rzbqGoScs9VHGnyCKF7AoQEuUfwJnzcKmGIfaczeanA= github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5/go.mod h1:2lyRkw/qLQgUWlrWWmq5nj0y90rWeO6Y+v+fCakRgb0= -github.com/smartcontractkit/ocr2keepers v0.7.16 h1:brSHJIlm2tD8lbxxJOFVhSmXGU8bKoUC/3CEaYCPd/U= -github.com/smartcontractkit/ocr2keepers v0.7.16/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= +github.com/smartcontractkit/ocr2keepers v0.7.17 h1:847GG2SHyHIPc3yu+dhB+1HfeLRhSjyiKnhw3umpoJw= +github.com/smartcontractkit/ocr2keepers v0.7.17/go.mod h1:AjcIEKeNnU7NRlvnuMCTjBIQ1kpW0YHhlFdeDa/3hs0= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687 h1:NwC3SOc25noBTe1KUQjt45fyTIuInhoE2UfgcHAdihM= github.com/smartcontractkit/ocr2vrf v0.0.0-20230804151440-2f1eb1e20687/go.mod h1:YYZq52t4wcHoMQeITksYsorD+tZcOyuVU5+lvot3VFM= github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb h1:OMaBUb4X9IFPLbGbCHsMU+kw/BPCrewaVwWGIBc0I4A= From 7d452615e277305dc41f468dd2a939de6e6c0424 Mon Sep 17 00:00:00 2001 From: Michael Fletcher <36506122+Fletch153@users.noreply.github.com> Date: Thu, 24 Aug 2023 14:22:54 +0100 Subject: [PATCH 261/270] Implement deficit payment mechanism + tests (#10282) * Implement deficit payment mechanism + tests * Re-run snapshot and removed unchecked * Update gas snapshots * Added explicit checks + additional tests * Update llo-feeds.gas-snapshot * Update go wrappers * update to safeTransfer --------- Co-authored-by: Austin Born --- .../gas-snapshots/llo-feeds.gas-snapshot | 180 ++++++++--------- .../src/v0.8/llo-feeds/dev/FeeManager.sol | 42 +++- .../src/v0.8/llo-feeds/dev/RewardManager.sol | 7 +- .../llo-feeds/dev/interfaces/IFeeManager.sol | 12 ++ .../test/fee-manager/BaseFeeManager.t.sol | 18 ++ .../test/fee-manager/FeeManager.general.t.sol | 99 ++++++++++ .../generated/fee_manager/fee_manager.go | 182 +++++++++++++++++- .../reward_manager/reward_manager.go | 2 +- ...rapper-dependency-versions-do-not-edit.txt | 4 +- 9 files changed, 443 insertions(+), 103 deletions(-) diff --git a/contracts/gas-snapshots/llo-feeds.gas-snapshot b/contracts/gas-snapshots/llo-feeds.gas-snapshot index e865fa0164e..c5d28f2e6eb 100644 --- a/contracts/gas-snapshots/llo-feeds.gas-snapshot +++ b/contracts/gas-snapshots/llo-feeds.gas-snapshot @@ -1,63 +1,67 @@ FeeManagerProcessFeeTest:test_DiscountIsAppliedForNative() (gas: 47380) FeeManagerProcessFeeTest:test_V1PayloadVerifies() (gas: 17377) -FeeManagerProcessFeeTest:test_V2PayloadVerifies() (gas: 104525) -FeeManagerProcessFeeTest:test_V2PayloadWithoutQuoteFails() (gas: 19972) -FeeManagerProcessFeeTest:test_V2PayloadWithoutZeroFee() (gas: 62309) -FeeManagerProcessFeeTest:test_WithdrawERC20() (gas: 62862) -FeeManagerProcessFeeTest:test_WithdrawNonAdminAddr() (gas: 48655) +FeeManagerProcessFeeTest:test_V2PayloadVerifies() (gas: 105616) +FeeManagerProcessFeeTest:test_V2PayloadWithoutQuoteFails() (gas: 19971) +FeeManagerProcessFeeTest:test_V2PayloadWithoutZeroFee() (gas: 63248) +FeeManagerProcessFeeTest:test_WithdrawERC20() (gas: 63905) +FeeManagerProcessFeeTest:test_WithdrawNonAdminAddr() (gas: 48635) FeeManagerProcessFeeTest:test_WithdrawUnwrappedNative() (gas: 20266) -FeeManagerProcessFeeTest:test_baseFeeIsAppliedForLink() (gas: 14747) -FeeManagerProcessFeeTest:test_baseFeeIsAppliedForNative() (gas: 17243) +FeeManagerProcessFeeTest:test_baseFeeIsAppliedForLink() (gas: 14770) +FeeManagerProcessFeeTest:test_baseFeeIsAppliedForNative() (gas: 17266) FeeManagerProcessFeeTest:test_correctDiscountIsAppliedWhenBothTokensAreDiscounted() (gas: 83368) -FeeManagerProcessFeeTest:test_discountAIsNotAppliedWhenSetForOtherUsers() (gas: 51005) +FeeManagerProcessFeeTest:test_discountAIsNotAppliedWhenSetForOtherUsers() (gas: 51028) FeeManagerProcessFeeTest:test_discountFeeRoundsDownWhenUneven() (gas: 47526) -FeeManagerProcessFeeTest:test_discountIsAppliedForLink() (gas: 44835) -FeeManagerProcessFeeTest:test_discountIsAppliedWith100PercentSurcharge() (gas: 71029) +FeeManagerProcessFeeTest:test_discountIsAppliedForLink() (gas: 44813) +FeeManagerProcessFeeTest:test_discountIsAppliedWith100PercentSurcharge() (gas: 70986) FeeManagerProcessFeeTest:test_discountIsNoLongerAppliedAfterRemoving() (gas: 40625) FeeManagerProcessFeeTest:test_discountIsNotAppliedForInvalidTokenAddress() (gas: 12439) FeeManagerProcessFeeTest:test_discountIsNotAppliedToOtherFeeds() (gas: 49052) FeeManagerProcessFeeTest:test_emptyQuoteRevertsWithError() (gas: 12305) FeeManagerProcessFeeTest:test_eventIsEmittedAfterSurchargeIsSet() (gas: 36250) -FeeManagerProcessFeeTest:test_eventIsEmittedUponWithdraw() (gas: 59974) +FeeManagerProcessFeeTest:test_eventIsEmittedUponWithdraw() (gas: 60995) FeeManagerProcessFeeTest:test_feeIsUpdatedAfterDiscountIsRemoved() (gas: 43112) FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewDiscountIsApplied() (gas: 59576) -FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewSurchargeIsApplied() (gas: 55859) +FeeManagerProcessFeeTest:test_feeIsUpdatedAfterNewSurchargeIsApplied() (gas: 55837) FeeManagerProcessFeeTest:test_feeIsZeroWith100PercentDiscount() (gas: 47236) FeeManagerProcessFeeTest:test_getBaseRewardWithLinkQuote() (gas: 14790) FeeManagerProcessFeeTest:test_getLinkFeeIsRoundedUp() (gas: 45004) -FeeManagerProcessFeeTest:test_getLinkRewardIsRoundedDown() (gas: 44906) +FeeManagerProcessFeeTest:test_getLinkRewardIsRoundedDown() (gas: 44928) FeeManagerProcessFeeTest:test_getLinkRewardWithNativeQuoteAndSurchargeWithLinkDiscount() (gas: 74660) -FeeManagerProcessFeeTest:test_getRewardWithLinkDiscount() (gas: 44813) +FeeManagerProcessFeeTest:test_getRewardWithLinkDiscount() (gas: 44856) FeeManagerProcessFeeTest:test_getRewardWithLinkQuoteAndLinkDiscount() (gas: 44836) FeeManagerProcessFeeTest:test_getRewardWithNativeQuote() (gas: 17266) FeeManagerProcessFeeTest:test_getRewardWithNativeQuoteAndSurcharge() (gas: 45334) -FeeManagerProcessFeeTest:test_linkAvailableForPaymentReturnsLinkBalance() (gas: 47416) -FeeManagerProcessFeeTest:test_nativeSurcharge0Percent() (gas: 25356) +FeeManagerProcessFeeTest:test_linkAvailableForPaymentReturnsLinkBalance() (gas: 47449) +FeeManagerProcessFeeTest:test_nativeSurcharge0Percent() (gas: 25401) FeeManagerProcessFeeTest:test_nativeSurcharge100Percent() (gas: 45370) FeeManagerProcessFeeTest:test_nativeSurchargeCannotExceed100Percent() (gas: 12085) FeeManagerProcessFeeTest:test_nativeSurchargeEventIsEmittedOnUpdate() (gas: 36252) FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFee() (gas: 46898) -FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFeeAndDiscountAndSurchargeIsSet() (gas: 70488) -FeeManagerProcessFeeTest:test_nonAdminProxyUserCannotProcessFee() (gas: 19084) -FeeManagerProcessFeeTest:test_nonAdminUserCanNotSetDiscount() (gas: 14751) -FeeManagerProcessFeeTest:test_processFeeAsProxy() (gas: 104814) -FeeManagerProcessFeeTest:test_processFeeDefaultReportsStillVerifiesWithEmptyQuote() (gas: 18192) -FeeManagerProcessFeeTest:test_processFeeEmitsEventIfNotEnoughLink() (gas: 121316) -FeeManagerProcessFeeTest:test_processFeeIfSubscriberIsSelf() (gas: 19197) -FeeManagerProcessFeeTest:test_processFeeNative() (gas: 154595) -FeeManagerProcessFeeTest:test_processFeeUsesCorrectDigest() (gas: 105773) -FeeManagerProcessFeeTest:test_processFeeWithDefaultReportPayloadAndQuoteStillVerifies() (gas: 20531) -FeeManagerProcessFeeTest:test_processFeeWithInvalidReportVersionFailsToDecode() (gas: 22031) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNative() (gas: 159057) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeLinkAddress() (gas: 68001) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeShortFunds() (gas: 72532) -FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeWithExcessiveFee() (gas: 166041) +FeeManagerProcessFeeTest:test_noFeeIsAppliedWhenReportHasZeroFeeAndDiscountAndSurchargeIsSet() (gas: 70466) +FeeManagerProcessFeeTest:test_nonAdminProxyUserCannotProcessFee() (gas: 19083) +FeeManagerProcessFeeTest:test_nonAdminUserCanNotSetDiscount() (gas: 14729) +FeeManagerProcessFeeTest:test_payLinkDeficit() (gas: 176744) +FeeManagerProcessFeeTest:test_payLinkDeficitOnlyCallableByAdmin() (gas: 12412) +FeeManagerProcessFeeTest:test_payLinkDeficitPaysAllFeesProcessed() (gas: 193372) +FeeManagerProcessFeeTest:test_payLinkDeficitTwice() (gas: 179113) +FeeManagerProcessFeeTest:test_processFeeAsProxy() (gas: 105905) +FeeManagerProcessFeeTest:test_processFeeDefaultReportsStillVerifiesWithEmptyQuote() (gas: 18191) +FeeManagerProcessFeeTest:test_processFeeEmitsEventIfNotEnoughLink() (gas: 144715) +FeeManagerProcessFeeTest:test_processFeeIfSubscriberIsSelf() (gas: 19196) +FeeManagerProcessFeeTest:test_processFeeNative() (gas: 156773) +FeeManagerProcessFeeTest:test_processFeeUsesCorrectDigest() (gas: 106864) +FeeManagerProcessFeeTest:test_processFeeWithDefaultReportPayloadAndQuoteStillVerifies() (gas: 20530) +FeeManagerProcessFeeTest:test_processFeeWithInvalidReportVersionFailsToDecode() (gas: 22030) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNative() (gas: 160148) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeLinkAddress() (gas: 68000) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeShortFunds() (gas: 72531) +FeeManagerProcessFeeTest:test_processFeeWithUnwrappedNativeWithExcessiveFee() (gas: 167132) FeeManagerProcessFeeTest:test_processFeeWithWithCorruptQuotePayload() (gas: 19808) -FeeManagerProcessFeeTest:test_processFeeWithWithEmptyQuotePayload() (gas: 20286) -FeeManagerProcessFeeTest:test_processFeeWithWithZeroQuotePayload() (gas: 21226) +FeeManagerProcessFeeTest:test_processFeeWithWithEmptyQuotePayload() (gas: 20285) +FeeManagerProcessFeeTest:test_processFeeWithWithZeroQuotePayload() (gas: 21225) FeeManagerProcessFeeTest:test_reportWithNoExpiryOrFeeReturnsZero() (gas: 10966) FeeManagerProcessFeeTest:test_setDiscountOver100Percent() (gas: 14453) -FeeManagerProcessFeeTest:test_subscriberDiscountEventIsEmittedOnUpdate() (gas: 41119) +FeeManagerProcessFeeTest:test_subscriberDiscountEventIsEmittedOnUpdate() (gas: 41096) FeeManagerProcessFeeTest:test_surchargeFeeRoundsUpWhenUneven() (gas: 45663) FeeManagerProcessFeeTest:test_surchargeIsApplied() (gas: 45631) FeeManagerProcessFeeTest:test_surchargeIsAppliedForNativeFeeWithDiscount() (gas: 71344) @@ -65,47 +69,47 @@ FeeManagerProcessFeeTest:test_surchargeIsNoLongerAppliedAfterRemoving() (gas: 40 FeeManagerProcessFeeTest:test_surchargeIsNotAppliedForLinkFee() (gas: 44851) FeeManagerProcessFeeTest:test_surchargeIsNotAppliedWith100PercentDiscount() (gas: 70842) FeeManagerProcessFeeTest:test_testRevertIfReportHasExpired() (gas: 15287) -RewardManagerClaimTest:test_claimAllRecipients() (gas: 257750) -RewardManagerClaimTest:test_claimMultipleRecipients() (gas: 143154) -RewardManagerClaimTest:test_claimRewardsWithDuplicatPoolIdsDoesNotPayoutTwice() (gas: 306046) -RewardManagerClaimTest:test_claimSingleRecipient() (gas: 82153) -RewardManagerClaimTest:test_claimUnevenAmountRoundsDown() (gas: 291448) +RewardManagerClaimTest:test_claimAllRecipients() (gas: 261746) +RewardManagerClaimTest:test_claimMultipleRecipients() (gas: 145152) +RewardManagerClaimTest:test_claimRewardsWithDuplicatPoolIdsDoesNotPayoutTwice() (gas: 311112) +RewardManagerClaimTest:test_claimSingleRecipient() (gas: 83152) +RewardManagerClaimTest:test_claimUnevenAmountRoundsDown() (gas: 296514) RewardManagerClaimTest:test_claimUnregisteredPoolId() (gas: 33836) RewardManagerClaimTest:test_claimUnregisteredRecipient() (gas: 35153) -RewardManagerClaimTest:test_eventIsEmittedUponClaim() (gas: 79828) +RewardManagerClaimTest:test_eventIsEmittedUponClaim() (gas: 80827) RewardManagerClaimTest:test_eventIsNotEmittedUponUnsuccessfulClaim() (gas: 24119) -RewardManagerClaimTest:test_recipientsClaimMultipleDeposits() (gas: 345435) -RewardManagerClaimTest:test_singleRecipientClaimMultipleDeposits() (gas: 122526) -RewardManagerNoRecipientSet:test_claimAllRecipientsAfterRecipientsSet() (gas: 456069) +RewardManagerClaimTest:test_recipientsClaimMultipleDeposits() (gas: 354497) +RewardManagerClaimTest:test_singleRecipientClaimMultipleDeposits() (gas: 125594) +RewardManagerNoRecipientSet:test_claimAllRecipientsAfterRecipientsSet() (gas: 460065) RewardManagerPayRecipientsTest:test_addFundsToPoolAsNonOwnerOrFeeManager() (gas: 12746) -RewardManagerPayRecipientsTest:test_addFundsToPoolAsOwner() (gas: 48620) -RewardManagerPayRecipientsTest:test_payAllRecipients() (gas: 239952) +RewardManagerPayRecipientsTest:test_addFundsToPoolAsOwner() (gas: 49476) +RewardManagerPayRecipientsTest:test_payAllRecipients() (gas: 243950) RewardManagerPayRecipientsTest:test_payAllRecipientsFromNonAdminUser() (gas: 15490) -RewardManagerPayRecipientsTest:test_payAllRecipientsFromRecipientInPool() (gas: 240242) -RewardManagerPayRecipientsTest:test_payAllRecipientsWithAdditionalInvalidRecipient() (gas: 251334) -RewardManagerPayRecipientsTest:test_payAllRecipientsWithAdditionalUnregisteredRecipient() (gas: 254496) +RewardManagerPayRecipientsTest:test_payAllRecipientsFromRecipientInPool() (gas: 244240) +RewardManagerPayRecipientsTest:test_payAllRecipientsWithAdditionalInvalidRecipient() (gas: 255332) +RewardManagerPayRecipientsTest:test_payAllRecipientsWithAdditionalUnregisteredRecipient() (gas: 258494) RewardManagerPayRecipientsTest:test_payRecipientWithInvalidPool() (gas: 28014) RewardManagerPayRecipientsTest:test_payRecipientsEmptyRecipientList() (gas: 19996) RewardManagerPayRecipientsTest:test_payRecipientsWithInvalidPoolId() (gas: 43841) -RewardManagerPayRecipientsTest:test_paySingleRecipient() (gas: 78279) -RewardManagerPayRecipientsTest:test_paySubsetOfRecipientsInPool() (gas: 189107) -RewardManagerRecipientClaimDifferentWeightsTest:test_allRecipientsClaimingReceiveExpectedAmount() (gas: 260811) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimAllRecipientsMultiplePools() (gas: 476699) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimAllRecipientsSinglePool() (gas: 263819) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimEmptyPoolWhenSecondPoolContainsFunds() (gas: 270760) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimMultipleRecipientsMultiplePools() (gas: 243846) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimMultipleRecipientsSinglePool() (gas: 143216) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimSingleRecipientMultiplePools() (gas: 122217) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimSingleUniqueRecipient() (gas: 96657) -RewardManagerRecipientClaimMultiplePoolsTest:test_claimUnevenAmountRoundsDown() (gas: 532419) +RewardManagerPayRecipientsTest:test_paySingleRecipient() (gas: 79278) +RewardManagerPayRecipientsTest:test_paySubsetOfRecipientsInPool() (gas: 192105) +RewardManagerRecipientClaimDifferentWeightsTest:test_allRecipientsClaimingReceiveExpectedAmount() (gas: 264807) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimAllRecipientsMultiplePools() (gas: 484691) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimAllRecipientsSinglePool() (gas: 267815) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimEmptyPoolWhenSecondPoolContainsFunds() (gas: 274756) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimMultipleRecipientsMultiplePools() (gas: 247842) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimMultipleRecipientsSinglePool() (gas: 145214) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimSingleRecipientMultiplePools() (gas: 124215) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimSingleUniqueRecipient() (gas: 97656) +RewardManagerRecipientClaimMultiplePoolsTest:test_claimUnevenAmountRoundsDown() (gas: 542551) RewardManagerRecipientClaimMultiplePoolsTest:test_claimUnregisteredRecipient() (gas: 55393) RewardManagerRecipientClaimMultiplePoolsTest:test_getRewardsAvailableToRecipientInBothPools() (gas: 24031) RewardManagerRecipientClaimMultiplePoolsTest:test_getRewardsAvailableToRecipientInNoPools() (gas: 18192) RewardManagerRecipientClaimMultiplePoolsTest:test_getRewardsAvailableToRecipientInSinglePool() (gas: 21793) -RewardManagerRecipientClaimMultiplePoolsTest:test_recipientsClaimMultipleDeposits() (gas: 349885) -RewardManagerRecipientClaimMultiplePoolsTest:test_singleRecipientClaimMultipleDeposits() (gas: 122542) -RewardManagerRecipientClaimUnevenWeightTest:test_allRecipientsClaimingReceiveExpectedAmount() (gas: 184329) -RewardManagerRecipientClaimUnevenWeightTest:test_allRecipientsClaimingReceiveExpectedAmountWithSmallDeposit() (gas: 204221) +RewardManagerRecipientClaimMultiplePoolsTest:test_recipientsClaimMultipleDeposits() (gas: 358947) +RewardManagerRecipientClaimMultiplePoolsTest:test_singleRecipientClaimMultipleDeposits() (gas: 125610) +RewardManagerRecipientClaimUnevenWeightTest:test_allRecipientsClaimingReceiveExpectedAmount() (gas: 187397) +RewardManagerRecipientClaimUnevenWeightTest:test_allRecipientsClaimingReceiveExpectedAmountWithSmallDeposit() (gas: 207289) RewardManagerSetRecipientsTest:test_eventIsEmittedUponSetRecipients() (gas: 185494) RewardManagerSetRecipientsTest:test_setRecipientContainsDuplicateRecipients() (gas: 117290) RewardManagerSetRecipientsTest:test_setRewardRecipientFromManagerAddress() (gas: 185271) @@ -118,27 +122,27 @@ RewardManagerSetRecipientsTest:test_setRewardRecipients() (gas: 179469) RewardManagerSetRecipientsTest:test_setRewardRecipientsIsEmpty() (gas: 82005) RewardManagerSetRecipientsTest:test_setSingleRewardRecipient() (gas: 105112) RewardManagerSetupTest:test_eventEmittedUponFeeManagerUpdate() (gas: 16365) -RewardManagerSetupTest:test_eventEmittedUponFeePaid() (gas: 250264) -RewardManagerSetupTest:test_rejectsZeroLinkAddressOnConstruction() (gas: 59044) +RewardManagerSetupTest:test_eventEmittedUponFeePaid() (gas: 251334) +RewardManagerSetupTest:test_rejectsZeroLinkAddressOnConstruction() (gas: 59237) RewardManagerSetupTest:test_setFeeManagerZeroAddress() (gas: 12015) -RewardManagerUpdateRewardRecipientsMultiplePoolsTest:test_updatePrimaryRecipientWeights() (gas: 342516) -RewardManagerUpdateRewardRecipientsTest:test_eventIsEmittedUponUpdateRecipients() (gas: 267066) +RewardManagerUpdateRewardRecipientsMultiplePoolsTest:test_updatePrimaryRecipientWeights() (gas: 351585) +RewardManagerUpdateRewardRecipientsTest:test_eventIsEmittedUponUpdateRecipients() (gas: 271069) RewardManagerUpdateRewardRecipientsTest:test_onlyAdminCanUpdateRecipients() (gas: 14622) -RewardManagerUpdateRewardRecipientsTest:test_partialUpdateRecipientWeights() (gas: 197909) -RewardManagerUpdateRewardRecipientsTest:test_updateAllRecipientsWithSameAddressAndWeight() (gas: 261004) -RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsToSubset() (gas: 235391) -RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithExcessiveWeight() (gas: 248952) -RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithSameAddressAndWeight() (gas: 141088) -RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithUnderWeightSet() (gas: 249017) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientWeights() (gas: 337998) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientWithNewZeroAddress() (gas: 247682) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsContainsDuplicateRecipients() (gas: 274972) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentLargerSet() (gas: 250186) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentPartialSet() (gas: 248406) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSet() (gas: 249627) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSetWithInvalidWeights() (gas: 248516) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForLargerSet() (gas: 241638) -RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForSmallerSet() (gas: 239964) +RewardManagerUpdateRewardRecipientsTest:test_partialUpdateRecipientWeights() (gas: 202980) +RewardManagerUpdateRewardRecipientsTest:test_updateAllRecipientsWithSameAddressAndWeight() (gas: 265007) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsToSubset() (gas: 239393) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithExcessiveWeight() (gas: 252954) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithSameAddressAndWeight() (gas: 143091) +RewardManagerUpdateRewardRecipientsTest:test_updatePartialRecipientsWithUnderWeightSet() (gas: 253019) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientWeights() (gas: 347067) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientWithNewZeroAddress() (gas: 251680) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsContainsDuplicateRecipients() (gas: 278976) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentLargerSet() (gas: 254184) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentPartialSet() (gas: 252404) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSet() (gas: 253625) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsToDifferentSetWithInvalidWeights() (gas: 252514) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForLargerSet() (gas: 245636) +RewardManagerUpdateRewardRecipientsTest:test_updateRecipientsUpdateAndRemoveExistingForSmallerSet() (gas: 243962) VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesAMiddleDigest() (gas: 24221) VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyRemovesTheFirstDigest() (gas: 24188) VerificationdeactivateConfigWhenThereAreMultipleDigestsTest:test_correctlyUnsetsDigestsInSequence() (gas: 44250) @@ -197,10 +201,10 @@ VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesDigestsOnM VerifierSetConfigWhenThereAreMultipleDigestsTest:test_correctlyUpdatesTheDigestInTheProxy() (gas: 519945) VerifierSupportsInterfaceTest:test_falseIfIsNotCorrectInterface() (gas: 5590) VerifierSupportsInterfaceTest:test_trueIfIsCorrectInterface() (gas: 5611) -VerifierTestBillingReport:test_verifyWithLink() (gas: 273778) -VerifierTestBillingReport:test_verifyWithNative() (gas: 252098) -VerifierTestBillingReport:test_verifyWithNativeUnwrapped() (gas: 263163) -VerifierTestBillingReport:test_verifyWithNativeUnwrappedReturnsChange() (gas: 270230) +VerifierTestBillingReport:test_verifyWithLink() (gas: 274848) +VerifierTestBillingReport:test_verifyWithNative() (gas: 275476) +VerifierTestBillingReport:test_verifyWithNativeUnwrapped() (gas: 285450) +VerifierTestBillingReport:test_verifyWithNativeUnwrappedReturnsChange() (gas: 292517) VerifierVerifyMultipleConfigDigestTest:test_canVerifyNewerReportsWithNewerConfigs() (gas: 127500) VerifierVerifyMultipleConfigDigestTest:test_canVerifyOlderReportsWithOlderConfigs() (gas: 183379) VerifierVerifyMultipleConfigDigestTest:test_revertsIfAReportIsVerifiedWithAnExistingButIncorrectDigest() (gas: 84470) @@ -219,5 +223,5 @@ Verifier_accessControlledVerify:testVerifyWithAccessControl_gas() (gas: 207063) Verifier_setConfig:testSetConfigSuccess_gas() (gas: 922408) Verifier_verify:testVerifyProxySuccess_gas() (gas: 197508) Verifier_verify:testVerifySuccess_gas() (gas: 182991) -Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 245201) -Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 261818) \ No newline at end of file +Verifier_verifyWithFee:testVerifyProxyWithLinkFeeSuccess_gas() (gas: 246271) +Verifier_verifyWithFee:testVerifyProxyWithNativeFeeSuccess_gas() (gas: 263976) \ No newline at end of file diff --git a/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol b/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol index 036800ccab4..2d3376cd67a 100644 --- a/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol +++ b/contracts/src/v0.8/llo-feeds/dev/FeeManager.sol @@ -10,6 +10,7 @@ import {IRewardManager} from "./interfaces/IRewardManager.sol"; import {IWERC20} from "../../shared/interfaces/IWERC20.sol"; import {IERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC20.sol"; import {Math} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/math/Math.sol"; +import {SafeERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol"; /** * @title FeeManager @@ -18,9 +19,14 @@ import {Math} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/utils/ma * @notice This contract is used for the handling of fees required for users verifying reports. */ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { + using SafeERC20 for IERC20; + /// @notice list of subscribers and their discounts subscriberDiscounts[subscriber][feedId][token] mapping(address => mapping(bytes32 => mapping(address => uint256))) public s_subscriberDiscounts; + /// @notice keep track of any subsidised link that is owed to the reward manager. + mapping(bytes32 => uint256) public s_linkDeficit; + /// @notice the total discount that can be applied to a fee, 1e18 = 100% discount uint256 private constant PERCENTAGE_SCALAR = 1e18; @@ -66,9 +72,12 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { /// @notice thrown if a report has no quote error InvalidQuote(); - // @notice Thrown when the caller is not authorized + // @notice thrown when the caller is not authorized error Unauthorized(); + // @notice thrown when trying to clear a zero deficit + error ZeroDeficit(); + /// @notice Emitted whenever a subscriber's discount is updated /// @param subscriber address of the subscriber to update discounts for /// @param feedId Feed ID for the discount @@ -91,6 +100,11 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { /// @param quantity Amount of the asset withdrawn event Withdraw(address adminAddress, address assetAddress, uint256 quantity); + /// @notice Emits when a deficit has been cleared for a particular config digest + /// @param configDigest Config digest of the deficit cleared + /// @param linkQuantity Amount of LINK required to pay the deficit + event LinkDeficitCleared(bytes32 indexed configDigest, uint256 linkQuantity); + /** * @notice Construct the FeeManager contract * @param _linkAddress The address of the LINK token @@ -146,7 +160,7 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { //v2 doesn't need a quote payload, so skip the decoding if the report is a v1 report Quote memory quote; - if (getReportVersion(feedId) != REPORT_V1) { + if (_getReportVersion(feedId) != REPORT_V1) { //all reports greater than v1 should have a quote payload (, , , , , bytes memory quoteBytes) = abi.decode( payload, @@ -190,13 +204,13 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { } else { //if the fee is in native wrapped, transfer to this contract in exchange for the equivalent amount of LINK excluding the surcharge if (msg.value == 0) { - IERC20(fee.assetAddress).transferFrom(subscriber, address(this), fee.amount); + IERC20(fee.assetAddress).safeTransferFrom(subscriber, address(this), fee.amount); } //check that the contract has enough LINK before paying the fee if (reward.amount > IERC20(i_linkAddress).balanceOf(address(this))) { - // If not enough LINK on this contract to forward for rewards, fire this event and - // call onFeePaid out-of-band to pay out rewards + // If not enough LINK on this contract to forward for rewards, tally the deficit to be paid by out-of-band LINK + s_linkDeficit[configDigest] += reward.amount; emit InsufficientLink(configDigest, reward.amount, fee.amount); } else { //bill the payee and distribute the fee using the config digest as the key @@ -224,7 +238,7 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { bytes32 feedId = bytes32(report); //the report needs to be a support version - bytes32 reportVersion = getReportVersion(feedId); + bytes32 reportVersion = _getReportVersion(feedId); //version 1 of the reports don't require quotes, so the fee will be 0 if (reportVersion == REPORT_V1) { @@ -321,12 +335,13 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { } //withdraw the requested asset - IERC20(assetAddress).transfer(owner(), quantity); + IERC20(assetAddress).safeTransfer(owner(), quantity); //emit event when funds are withdrawn emit Withdraw(msg.sender, assetAddress, quantity); } + /// @inheritdoc IFeeManager function linkAvailableForPayment() external view returns (uint256) { //return the amount of LINK this contact has available to pay rewards return IERC20(i_linkAddress).balanceOf(address(this)); @@ -336,7 +351,18 @@ contract FeeManager is IFeeManager, ConfirmedOwner, TypeAndVersionInterface { * @notice Gets the current version of the report that is encoded as the last two bytes of the feed * @param feedId feed id to get the report version for */ - function getReportVersion(bytes32 feedId) internal pure returns (bytes32) { + function _getReportVersion(bytes32 feedId) internal pure returns (bytes32) { return REPORT_VERSION_MASK & feedId; } + + /// @inheritdoc IFeeManager + function payLinkDeficit(bytes32 configDigest) external onlyOwner { + uint256 deficit = s_linkDeficit[configDigest]; + if (deficit == 0) revert ZeroDeficit(); + + delete s_linkDeficit[configDigest]; + i_rewardManager.onFeePaid(configDigest, address(this), deficit); + + emit LinkDeficitCleared(configDigest, deficit); + } } diff --git a/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol b/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol index f32cbd5e24d..fbe072cacab 100644 --- a/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol +++ b/contracts/src/v0.8/llo-feeds/dev/RewardManager.sol @@ -7,6 +7,7 @@ import {IERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interf import {TypeAndVersionInterface} from "../../interfaces/TypeAndVersionInterface.sol"; import {IERC165} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/interfaces/IERC165.sol"; import {Common} from "../../libraries/Common.sol"; +import {SafeERC20} from "../../vendor/openzeppelin-solidity/v4.8.0/contracts/token/ERC20/utils/SafeERC20.sol"; /** * @title FeeManager @@ -15,6 +16,8 @@ import {Common} from "../../libraries/Common.sol"; * @notice This contract will be used to reward any configured recipients within a pool. Recipients will receive a share of their pool relative to their configured weight. */ contract RewardManager is IRewardManager, ConfirmedOwner, TypeAndVersionInterface { + using SafeERC20 for IERC20; + // @dev The mapping of total fees collected for a particular pot: s_totalRewardRecipientFees[poolId] mapping(bytes32 => uint256) public s_totalRewardRecipientFees; @@ -97,7 +100,7 @@ contract RewardManager is IRewardManager, ConfirmedOwner, TypeAndVersionInterfac } //transfer the fee to this contract - IERC20(i_linkAddress).transferFrom(payee, address(this), amount); + IERC20(i_linkAddress).safeTransferFrom(payee, address(this), amount); emit FeePaid(poolId, payee, amount); } @@ -144,7 +147,7 @@ contract RewardManager is IRewardManager, ConfirmedOwner, TypeAndVersionInterfac //check if there's any rewards to claim in the given poolId if (claimAmount != 0) { //transfer the reward to the recipient - IERC20(i_linkAddress).transfer(recipient, claimAmount); + IERC20(i_linkAddress).safeTransfer(recipient, claimAmount); } return claimAmount; diff --git a/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol b/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol index 7716cdeaa31..e045b961c3e 100644 --- a/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol +++ b/contracts/src/v0.8/llo-feeds/dev/interfaces/IFeeManager.sol @@ -61,4 +61,16 @@ interface IFeeManager is IERC165, IVerifierFeeManager { * @param quantity quantity to withdraw */ function withdraw(address assetAddress, uint256 quantity) external; + + /** + * @notice Returns the link balance of the fee manager + * @return link balance of the fee manager + */ + function linkAvailableForPayment() external returns (uint256); + + /** + * @notice Admin function to pay the LINK deficit for a given config digest + * @param configDigest the config digest to pay the deficit for + */ + function payLinkDeficit(bytes32 configDigest) external; } diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol index 0392704b963..b17679d1490 100644 --- a/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/BaseFeeManager.t.sol @@ -66,12 +66,14 @@ contract BaseFeeManagerTest is Test { bytes4 internal immutable UNAUTHORIZED_ERROR = FeeManager.Unauthorized.selector; bytes internal constant ONLY_CALLABLE_BY_OWNER_ERROR = "Only callable by owner"; bytes internal constant INSUFFICIENT_ALLOWANCE_ERROR = "ERC20: insufficient allowance"; + bytes4 internal immutable ZERO_DEFICIT = FeeManager.ZeroDeficit.selector; //events emitted event SubscriberDiscountUpdated(address indexed subscriber, bytes32 indexed feedId, address token, uint256 discount); event NativeSurchargeUpdated(uint256 newSurcharge); event InsufficientLink(bytes32 indexed configDigest, uint256 linkQuantity, uint256 nativeQuantity); event Withdraw(address adminAddress, address assetAddress, uint256 quantity); + event LinkDeficitCleared(bytes32 indexed configDigest, uint256 linkQuantity); function setUp() public virtual { //change to admin user @@ -340,4 +342,20 @@ contract BaseFeeManagerTest is Test { function getNativeAddress() public view returns (address) { return address(native); } + + function payLinkDeficit(bytes32 configDigest, address sender) public { + //record the current address and switch to the recipient + address originalAddr = msg.sender; + changePrank(sender); + + //approve the link to be transferred + feeManager.payLinkDeficit(configDigest); + + //change back to the original address + changePrank(originalAddr); + } + + function getLinkDeficit(bytes32 configDigest) public view returns (uint256) { + return feeManager.s_linkDeficit(configDigest); + } } diff --git a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol index 69c13d2f8e9..0c8c9dd9ee4 100644 --- a/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol +++ b/contracts/src/v0.8/llo-feeds/test/fee-manager/FeeManager.general.t.sol @@ -134,4 +134,103 @@ contract FeeManagerProcessFeeTest is BaseFeeManagerTest { //check the link available for payment is the link balance assertEq(feeManager.linkAvailableForPayment(), getLinkBalance(address(feeManager))); } + + function test_payLinkDeficit() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE, USER); + + //not enough funds in the reward pool should trigger an insufficient link event + vm.expectEmit(); + emit InsufficientLink(DEFAULT_CONFIG_DIGEST, DEFAULT_REPORT_LINK_FEE, DEFAULT_REPORT_NATIVE_FEE); + + //process the fee + processFee(payload, USER, 0, ADMIN); + + //double check the rewardManager balance is 0 + assertEq(getLinkBalance(address(rewardManager)), 0); + + //simulate a deposit of link to cover the deficit + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + vm.expectEmit(); + emit LinkDeficitCleared(DEFAULT_CONFIG_DIGEST, DEFAULT_REPORT_LINK_FEE); + + //pay the deficit which will transfer link from the rewardManager to the rewardManager + payLinkDeficit(DEFAULT_CONFIG_DIGEST, ADMIN); + + //check the rewardManager received the link + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + } + + function test_payLinkDeficitTwice() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE, USER); + + //not enough funds in the reward pool should trigger an insufficient link event + vm.expectEmit(); + emit InsufficientLink(DEFAULT_CONFIG_DIGEST, DEFAULT_REPORT_LINK_FEE, DEFAULT_REPORT_NATIVE_FEE); + + //process the fee + processFee(payload, USER, 0, ADMIN); + + //double check the rewardManager balance is 0 + assertEq(getLinkBalance(address(rewardManager)), 0); + + //simulate a deposit of link to cover the deficit + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE); + + vm.expectEmit(); + emit LinkDeficitCleared(DEFAULT_CONFIG_DIGEST, DEFAULT_REPORT_LINK_FEE); + + //pay the deficit which will transfer link from the rewardManager to the rewardManager + payLinkDeficit(DEFAULT_CONFIG_DIGEST, ADMIN); + + //check the rewardManager received the link + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE); + + //paying again should revert with 0 + vm.expectRevert(ZERO_DEFICIT); + + payLinkDeficit(DEFAULT_CONFIG_DIGEST, ADMIN); + } + + function test_payLinkDeficitPaysAllFeesProcessed() public { + //get the default payload + bytes memory payload = getPayload(getV2Report(DEFAULT_FEED_1_V3), getQuotePayload(getNativeAddress())); + + //approve the native to be transferred from the user + approveNative(address(feeManager), DEFAULT_REPORT_NATIVE_FEE * 2, USER); + + //processing the fee will transfer the native from the user to the feeManager + processFee(payload, USER, 0, ADMIN); + processFee(payload, USER, 0, ADMIN); + + //check the deficit has been increased twice + assertEq(getLinkDeficit(DEFAULT_CONFIG_DIGEST), DEFAULT_REPORT_LINK_FEE * 2); + + //double check the rewardManager balance is 0 + assertEq(getLinkBalance(address(rewardManager)), 0); + + //simulate a deposit of link to cover the deficit + mintLink(address(feeManager), DEFAULT_REPORT_LINK_FEE * 2); + + vm.expectEmit(); + emit LinkDeficitCleared(DEFAULT_CONFIG_DIGEST, DEFAULT_REPORT_LINK_FEE * 2); + + //pay the deficit which will transfer link from the rewardManager to the rewardManager + payLinkDeficit(DEFAULT_CONFIG_DIGEST, ADMIN); + + //check the rewardManager received the link + assertEq(getLinkBalance(address(rewardManager)), DEFAULT_REPORT_LINK_FEE * 2); + } + + function test_payLinkDeficitOnlyCallableByAdmin() public { + vm.expectRevert(ONLY_CALLABLE_BY_OWNER_ERROR); + + payLinkDeficit(DEFAULT_CONFIG_DIGEST, USER); + } } diff --git a/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go b/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go index eb5b4c4f35d..31c0a0b1a06 100644 --- a/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go +++ b/core/gethwrappers/llo-feeds/generated/fee_manager/fee_manager.go @@ -45,8 +45,8 @@ type IFeeManagerQuote struct { } var FeeManagerMetaData = &bind.MetaData{ - ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_nativeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_proxyAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_rewardManagerAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ExpiredReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDeposit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDiscount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidQuote\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSurcharge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nativeQuantity\",\"type\":\"uint256\"}],\"name\":\"InsufficientLink\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newSurcharge\",\"type\":\"uint256\"}],\"name\":\"NativeSurchargeUpdated\",\"type\":\"event\"},{\"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\":\"subscriber\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"SubscriberDiscountUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"quoteAddress\",\"type\":\"address\"}],\"internalType\":\"structIFeeManager.Quote\",\"name\":\"quote\",\"type\":\"tuple\"}],\"name\":\"getFeeAndReward\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkAvailableForPayment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"}],\"name\":\"processFee\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_nativeSurcharge\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_subscriberDiscounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setFeeRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"surcharge\",\"type\":\"uint256\"}],\"name\":\"setNativeSurcharge\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"updateSubscriberDiscount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x6101006040523480156200001257600080fd5b506040516200242338038062002423833981016040819052620000359162000288565b33806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf81620001c0565b5050506001600160a01b0384161580620000e057506001600160a01b038316155b80620000f357506001600160a01b038216155b806200010657506001600160a01b038116155b15620001255760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03848116608081905284821660a05283821660c05290821660e081905260405163095ea7b360e01b81526004810191909152600019602482015263095ea7b3906044016020604051808303816000875af11580156200018f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001b59190620002e5565b505050505062000310565b336001600160a01b038216036200021a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200028357600080fd5b919050565b600080600080608085870312156200029f57600080fd5b620002aa856200026b565b9350620002ba602086016200026b565b9250620002ca604086016200026b565b9150620002da606086016200026b565b905092959194509250565b600060208284031215620002f857600080fd5b815180151581146200030957600080fd5b9392505050565b60805160a05160c05160e051612077620003ac6000396000818161041b01528181610e6d01526110c30152600081816103840152610afa0152600081816106b301528181610706015281816108fa01528181610c6501528181610d2c015261122f0152600081816106d8015281816107610152818161088501528181610a3a01528181610dec01528181610faf01526111d801526120776000f3fe6080604052600436106100dd5760003560e01c80638da5cb5b1161007f578063f1387e1611610059578063f1387e16146102d6578063f237f1a8146102e9578063f2fde38b14610309578063f3fef3a31461032957600080fd5b80638da5cb5b1461025e578063c541cbde14610293578063d09dc339146102c157600080fd5b806369fd2b34116100bb57806369fd2b34146101c95780636b54d8a6146101eb57806379ba50971461020b57806387d6d8431461022057600080fd5b806301ffc9a7146100e2578063181f5a771461015957806332f5f746146101a5575b600080fd5b3480156100ee57600080fd5b506101446100fd366004611693565b7fffffffff00000000000000000000000000000000000000000000000000000000167ff1387e16000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b34801561016557600080fd5b50604080518082018252601081527f4665654d616e6167657220302e302e31000000000000000000000000000000006020820152905161015091906116dc565b3480156101b157600080fd5b506101bb60035481565b604051908152602001610150565b3480156101d557600080fd5b506101e96101e4366004611748565b610349565b005b3480156101f757600080fd5b506101e96102063660046117c7565b61048b565b34801561021757600080fd5b506101e9610510565b34801561022c57600080fd5b506101bb61023b366004611802565b600260209081526000938452604080852082529284528284209052825290205481565b34801561026a57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610150565b34801561029f57600080fd5b506102b36102ae366004611979565b610612565b604051610150929190611a1a565b3480156102cd57600080fd5b506101bb610a09565b6101e96102e4366004611a6e565b610abf565b3480156102f557600080fd5b506101e9610304366004611ae6565b61118c565b34801561031557600080fd5b506101e9610324366004611b2e565b611333565b34801561033557600080fd5b506101e9610344366004611b4b565b611347565b60005473ffffffffffffffffffffffffffffffffffffffff1633148015906103a757503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b156103de576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f633b5f6e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063633b5f6e9061045490869086908690600401611b77565b600060405180830381600087803b15801561046e57600080fd5b505af1158015610482573d6000803e3d6000fd5b50505050505050565b6104936114e1565b670de0b6b3a76400008111156104d5576040517f05e8ac2900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60038190556040518181527fa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e19060200160405180910390a150565b60015473ffffffffffffffffffffffffffffffffffffffff163314610596576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6040805180820190915260008082526020820152604080518082019091526000808252602082015260408051808201909152600080825260208201526040805180820190915260008082526020820152600061066d87611be6565b90507fffff00000000000000000000000000000000000000000000000000000000000080821690810161070457505073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000811683527f00000000000000000000000000000000000000000000000000000000000000001681529092509050610a01565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff16141580156107b457507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff1614155b156107eb576040517ff861803000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060008a8060200190518101906108049190611c6c565b77ffffffffffffffffffffffffffffffffffffffffffffffff92831699509116965063ffffffff169450505042831015915061086e9050576040517fb6c405f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116808852602088018590528b51909116036108e357855173ffffffffffffffffffffffffffffffffffffffff16875260208087015190880152610953565b73ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016875260035461094d9061093590670de0b6b3a7640000611d22565b61093f9084611d35565b670de0b6b3a7640000611564565b60208801525b73ffffffffffffffffffffffffffffffffffffffff808d16600090815260026020908152604080832089845282528083208e5190941683529281529190205490880151670de0b6b3a7640000906109ab908390611d35565b6109b59190611d72565b88602001516109c49190611dad565b8860200181815250506109e081886020015161093f9190611d35565b87602001516109ef9190611dad565b60208801525095975093955050505050505b935093915050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610a96573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610aba9190611dc0565b905090565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610b1d57503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b15610b54576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff821603610ba3576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610bb183850185611e47565b915050600081610bc090611be6565b6040805160208101909152600081529091507e010000000000000000000000000000000000000000000000000000000000007fffff000000000000000000000000000000000000000000000000000000000000831614610c47576000610c2886880188611f16565b9550505050505080806020019051810190610c439190611fde565b9150505b600080610c55338685610612565b91509150600034600014610db9577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614610cec576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3483602001511115610d2a576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db084602001516040518263ffffffff1660e01b81526004016000604051808303818588803b158015610d9657600080fd5b505af1158015610daa573d6000803e3d6000fd5b50505050508260200151340390505b6000610dc5898b61200c565b9050836020015160001461113557835173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116911603610ed05760208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8a8116602483015260448201929092527f00000000000000000000000000000000000000000000000000000000000000009091169063efb03fe990606401600060405180830381600087803b158015610eb357600080fd5b505af1158015610ec7573d6000803e3d6000fd5b50505050611135565b34600003610f8157835160208501516040517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8b8116600483015230602483015260448201929092529116906323b872dd906064016020604051808303816000875af1158015610f5b573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f7f9190612048565b505b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561100b573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061102f9190611dc0565b836020015111156110815760208084015185820151604080519283529282015282917feb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7910160405180910390a2611135565b60208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905230602482015260448101919091527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063efb03fe990606401600060405180830381600087803b15801561111c57600080fd5b505af1158015611130573d6000803e3d6000fd5b505050505b81156111805760405173ffffffffffffffffffffffffffffffffffffffff89169083156108fc029084906000818181858888f1935050505015801561117e573d6000803e3d6000fd5b505b50505050505050505050565b6111946114e1565b670de0b6b3a76400008111156111d6576040517f997ea36000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff161415801561127e57507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b156112b5576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84811660008181526002602090815260408083208884528252808320948716808452948252918290208590558151938452830184905285927f41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84910160405180910390a350505050565b61133b6114e1565b6113448161159e565b50565b61134f6114e1565b73ffffffffffffffffffffffffffffffffffffffff82166113b5576000805460405173ffffffffffffffffffffffffffffffffffffffff9091169183156108fc02918491818181858888f193505050501580156113b0573d6000803e3d6000fd5b505050565b8173ffffffffffffffffffffffffffffffffffffffff1663a9059cbb6113f060005473ffffffffffffffffffffffffffffffffffffffff1690565b6040517fffffffff0000000000000000000000000000000000000000000000000000000060e084901b16815273ffffffffffffffffffffffffffffffffffffffff9091166004820152602481018490526044016020604051808303816000875af1158015611462573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906114869190612048565b506040805133815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb9060600160405180910390a15050565b60005473ffffffffffffffffffffffffffffffffffffffff163314611562576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161058d565b565b600082156115925781611578600185611dad565b6115829190611d72565b61158d906001611d22565b611595565b60005b90505b92915050565b3373ffffffffffffffffffffffffffffffffffffffff82160361161d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161058d565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156116a557600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146116d557600080fd5b9392505050565b600060208083528351808285015260005b81811015611709578581018301518582016040015282016116ed565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60008060006040848603121561175d57600080fd5b83359250602084013567ffffffffffffffff8082111561177c57600080fd5b818601915086601f83011261179057600080fd5b81358181111561179f57600080fd5b8760208260061b85010111156117b457600080fd5b6020830194508093505050509250925092565b6000602082840312156117d957600080fd5b5035919050565b73ffffffffffffffffffffffffffffffffffffffff8116811461134457600080fd5b60008060006060848603121561181757600080fd5b8335611822816117e0565b9250602084013591506040840135611839816117e0565b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516020810167ffffffffffffffff8111828210171561189657611896611844565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156118e3576118e3611844565b604052919050565b600082601f8301126118fc57600080fd5b813567ffffffffffffffff81111561191657611916611844565b61194760207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8401160161189c565b81815284602083860101111561195c57600080fd5b816020850160208301376000918101602001919091529392505050565b6000806000838503606081121561198f57600080fd5b843561199a816117e0565b9350602085013567ffffffffffffffff8111156119b657600080fd5b6119c2878288016118eb565b93505060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc0820112156119f557600080fd5b506119fe611873565b6040850135611a0c816117e0565b815292959194509192509050565b825173ffffffffffffffffffffffffffffffffffffffff1681526020808401519082015260808101825173ffffffffffffffffffffffffffffffffffffffff166040830152602083015160608301526116d5565b600080600060408486031215611a8357600080fd5b833567ffffffffffffffff80821115611a9b57600080fd5b818601915086601f830112611aaf57600080fd5b813581811115611abe57600080fd5b876020828501011115611ad057600080fd5b60209283019550935050840135611839816117e0565b60008060008060808587031215611afc57600080fd5b8435611b07816117e0565b9350602085013592506040850135611b1e816117e0565b9396929550929360600135925050565b600060208284031215611b4057600080fd5b81356116d5816117e0565b60008060408385031215611b5e57600080fd5b8235611b69816117e0565b946020939093013593505050565b8381526040602080830182905282820184905260009190859060608501845b87811015611bd9578335611ba9816117e0565b73ffffffffffffffffffffffffffffffffffffffff16825283830135838301529284019290840190600101611b96565b5098975050505050505050565b80516020808301519190811015611c25577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805163ffffffff81168114611c3f57600080fd5b919050565b805177ffffffffffffffffffffffffffffffffffffffffffffffff81168114611c3f57600080fd5b600080600080600080600060e0888a031215611c8757600080fd5b87519650611c9760208901611c2b565b9550611ca560408901611c2b565b945060608801518060170b8114611cbb57600080fd5b9350611cc960808901611c44565b9250611cd760a08901611c44565b9150611ce560c08901611c2b565b905092959891949750929550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b8082018082111561159857611598611cf3565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0483118215151615611d6d57611d6d611cf3565b500290565b600082611da8577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b8181038181111561159857611598611cf3565b600060208284031215611dd257600080fd5b5051919050565b600082601f830112611dea57600080fd5b6040516060810181811067ffffffffffffffff82111715611e0d57611e0d611844565b604052806060840185811115611e2257600080fd5b845b81811015611e3c578035835260209283019201611e24565b509195945050505050565b60008060808385031215611e5a57600080fd5b611e648484611dd9565b9150606083013567ffffffffffffffff811115611e8057600080fd5b611e8c858286016118eb565b9150509250929050565b600082601f830112611ea757600080fd5b8135602067ffffffffffffffff821115611ec357611ec3611844565b8160051b611ed282820161189c565b9283528481018201928281019087851115611eec57600080fd5b83870192505b84831015611f0b57823582529183019190830190611ef2565b979650505050505050565b6000806000806000806101008789031215611f3057600080fd5b611f3a8888611dd9565b9550606087013567ffffffffffffffff80821115611f5757600080fd5b611f638a838b016118eb565b96506080890135915080821115611f7957600080fd5b611f858a838b01611e96565b955060a0890135915080821115611f9b57600080fd5b611fa78a838b01611e96565b945060c0890135935060e0890135915080821115611fc457600080fd5b50611fd189828a016118eb565b9150509295509295509295565b600060208284031215611ff057600080fd5b611ff8611873565b8251612003816117e0565b81529392505050565b80356020831015611598577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b60006020828403121561205a57600080fd5b815180151581146116d557600080fdfea164736f6c6343000810000a", + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"_linkAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_nativeAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_proxyAddress\",\"type\":\"address\"},{\"internalType\":\"address\",\"name\":\"_rewardManagerAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"ExpiredReport\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDeposit\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidDiscount\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidQuote\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidSurcharge\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidToken\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"ZeroDeficit\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"nativeQuantity\",\"type\":\"uint256\"}],\"name\":\"InsufficientLink\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"linkQuantity\",\"type\":\"uint256\"}],\"name\":\"LinkDeficitCleared\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"newSurcharge\",\"type\":\"uint256\"}],\"name\":\"NativeSurchargeUpdated\",\"type\":\"event\"},{\"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\":\"subscriber\",\"type\":\"address\"},{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"SubscriberDiscountUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"adminAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"Withdraw\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes\",\"name\":\"report\",\"type\":\"bytes\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"quoteAddress\",\"type\":\"address\"}],\"internalType\":\"structIFeeManager.Quote\",\"name\":\"quote\",\"type\":\"tuple\"}],\"name\":\"getFeeAndReward\",\"outputs\":[{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.Asset\",\"name\":\"\",\"type\":\"tuple\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"linkAvailableForPayment\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"}],\"name\":\"payLinkDeficit\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes\",\"name\":\"payload\",\"type\":\"bytes\"},{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"}],\"name\":\"processFee\",\"outputs\":[],\"stateMutability\":\"payable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_linkDeficit\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_nativeSurcharge\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_subscriberDiscounts\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"configDigest\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setFeeRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"surcharge\",\"type\":\"uint256\"}],\"name\":\"setNativeSurcharge\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"subscriber\",\"type\":\"address\"},{\"internalType\":\"bytes32\",\"name\":\"feedId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"token\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"discount\",\"type\":\"uint256\"}],\"name\":\"updateSubscriberDiscount\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"assetAddress\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"withdraw\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x6101006040523480156200001257600080fd5b506040516200296d3803806200296d833981016040819052620000359162000288565b33806000816200008c5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000bf57620000bf81620001c0565b5050506001600160a01b0384161580620000e057506001600160a01b038316155b80620000f357506001600160a01b038216155b806200010657506001600160a01b038116155b15620001255760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b03848116608081905284821660a05283821660c05290821660e081905260405163095ea7b360e01b81526004810191909152600019602482015263095ea7b3906044016020604051808303816000875af11580156200018f573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190620001b59190620002e5565b505050505062000310565b336001600160a01b038216036200021a5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000083565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b80516001600160a01b03811681146200028357600080fd5b919050565b600080600080608085870312156200029f57600080fd5b620002aa856200026b565b9350620002ba602086016200026b565b9250620002ca604086016200026b565b9150620002da606086016200026b565b905092959194509250565b600060208284031215620002f857600080fd5b815180151581146200030957600080fd5b9392505050565b60805160a05160c05160e0516125ba620003b36000396000818161047e01528181610bc00152818161101d01526112230152600081816103e70152610caa015260008181610716015281816107690152818161095d01528181610e1501528181610edc015261138f01526000818161073b015281816107c4015281816108e801528181610a9d01528181610f9c015281816110e3015261133801526125ba6000f3fe6080604052600436106100f35760003560e01c80638da5cb5b1161008a578063f1387e1611610059578063f1387e1614610339578063f237f1a81461034c578063f2fde38b1461036c578063f3fef3a31461038c57600080fd5b80638da5cb5b146102a1578063c541cbde146102d6578063d09dc33914610304578063e389d9a41461031957600080fd5b806369fd2b34116100c657806369fd2b341461020c5780636b54d8a61461022e57806379ba50971461024e57806387d6d8431461026357600080fd5b8063013f542b146100f857806301ffc9a714610138578063181f5a77146101aa57806332f5f746146101f6575b600080fd5b34801561010457600080fd5b50610125610113366004611bb8565b60036020526000908152604090205481565b6040519081526020015b60405180910390f35b34801561014457600080fd5b5061019a610153366004611bd1565b7fffffffff00000000000000000000000000000000000000000000000000000000167ff1387e16000000000000000000000000000000000000000000000000000000001490565b604051901515815260200161012f565b3480156101b657600080fd5b50604080518082018252601081527f4665654d616e6167657220302e302e31000000000000000000000000000000006020820152905161012f9190611c37565b34801561020257600080fd5b5061012560045481565b34801561021857600080fd5b5061022c610227366004611c88565b6103ac565b005b34801561023a57600080fd5b5061022c610249366004611bb8565b6104ee565b34801561025a57600080fd5b5061022c610573565b34801561026f57600080fd5b5061012561027e366004611d29565b600260209081526000938452604080852082529284528284209052825290205481565b3480156102ad57600080fd5b5060005460405173ffffffffffffffffffffffffffffffffffffffff909116815260200161012f565b3480156102e257600080fd5b506102f66102f1366004611ea0565b610675565b60405161012f929190611f41565b34801561031057600080fd5b50610125610a6c565b34801561032557600080fd5b5061022c610334366004611bb8565b610b22565b61022c610347366004611f95565b610c6f565b34801561035857600080fd5b5061022c61036736600461200d565b6112ec565b34801561037857600080fd5b5061022c610387366004612055565b611493565b34801561039857600080fd5b5061022c6103a7366004612072565b6114a7565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061040a57503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b15610441576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040517f633b5f6e00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000169063633b5f6e906104b79086908690869060040161209e565b600060405180830381600087803b1580156104d157600080fd5b505af11580156104e5573d6000803e3d6000fd5b50505050505050565b6104f66115af565b670de0b6b3a7640000811115610538576040517f05e8ac2900000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60048190556040518181527fa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e19060200160405180910390a150565b60015473ffffffffffffffffffffffffffffffffffffffff1633146105f9576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b604080518082019091526000808252602082015260408051808201909152600080825260208201526040805180820190915260008082526020820152604080518082019091526000808252602082015260006106d08761210d565b90507fffff00000000000000000000000000000000000000000000000000000000000080821690810161076757505073ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000811683527f00000000000000000000000000000000000000000000000000000000000000001681529092509050610a64565b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff161415801561081757507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16876000015173ffffffffffffffffffffffffffffffffffffffff1614155b1561084e576040517ff861803000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008060008a8060200190518101906108679190612193565b77ffffffffffffffffffffffffffffffffffffffffffffffff92831699509116965063ffffffff16945050504283101591506108d19050576040517fb6c405f500000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000008116808852602088018590528b519091160361094657855173ffffffffffffffffffffffffffffffffffffffff168752602080870151908801526109b6565b73ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001687526004546109b09061099890670de0b6b3a7640000612249565b6109a2908461225c565b670de0b6b3a7640000611632565b60208801525b73ffffffffffffffffffffffffffffffffffffffff808d16600090815260026020908152604080832089845282528083208e5190941683529281529190205490880151670de0b6b3a764000090610a0e90839061225c565b610a189190612299565b8860200151610a2791906122d4565b886020018181525050610a438188602001516109a2919061225c565b8760200151610a5291906122d4565b60208801525095975093955050505050505b935093915050565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201526000907f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa158015610af9573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610b1d91906122e7565b905090565b610b2a6115af565b60008181526003602052604081205490819003610b73576040517f03aad31200000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008281526003602052604080822091909155517fefb03fe900000000000000000000000000000000000000000000000000000000815260048101839052306024820152604481018290527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063efb03fe990606401600060405180830381600087803b158015610c1957600080fd5b505af1158015610c2d573d6000803e3d6000fd5b50505050817f843f0b103e50b42b08f9d30f12f961845a6d02623730872e24644899c0dd989582604051610c6391815260200190565b60405180910390a25050565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610ccd57503373ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001614155b15610d04576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3073ffffffffffffffffffffffffffffffffffffffff821603610d53576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000610d618385018561236e565b915050600081610d709061210d565b6040805160208101909152600081529091507e010000000000000000000000000000000000000000000000000000000000007fffff000000000000000000000000000000000000000000000000000000000000831614610df7576000610dd88688018861243d565b9550505050505080806020019051810190610df39190612505565b9150505b600080610e05338685610675565b91509150600034600014610f69577f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16836000015173ffffffffffffffffffffffffffffffffffffffff1614610e9c576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b3483602001511115610eda576040517fb2e532de00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663d0e30db084602001516040518263ffffffff1660e01b81526004016000604051808303818588803b158015610f4657600080fd5b505af1158015610f5a573d6000803e3d6000fd5b50505050508260200151340390505b6000610f75898b612533565b9050836020015160001461129557835173ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000081169116036110805760208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905273ffffffffffffffffffffffffffffffffffffffff8a8116602483015260448201929092527f00000000000000000000000000000000000000000000000000000000000000009091169063efb03fe990606401600060405180830381600087803b15801561106357600080fd5b505af1158015611077573d6000803e3d6000fd5b50505050611295565b346000036110b557602084015184516110b59173ffffffffffffffffffffffffffffffffffffffff909116908a90309061166c565b6040517f70a082310000000000000000000000000000000000000000000000000000000081523060048201527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff16906370a0823190602401602060405180830381865afa15801561113f573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061116391906122e7565b836020015111156111e15782602001516003600083815260200190815260200160002060008282546111959190612249565b909155505060208381015185820151604080519283529282015282917feb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7910160405180910390a2611295565b60208301516040517fefb03fe90000000000000000000000000000000000000000000000000000000081526004810183905230602482015260448101919091527f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff169063efb03fe990606401600060405180830381600087803b15801561127c57600080fd5b505af1158015611290573d6000803e3d6000fd5b505050505b81156112e05760405173ffffffffffffffffffffffffffffffffffffffff89169083156108fc029084906000818181858888f193505050501580156112de573d6000803e3d6000fd5b505b50505050505050505050565b6112f46115af565b670de0b6b3a7640000811115611336576040517f997ea36000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff16141580156113de57507f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff168273ffffffffffffffffffffffffffffffffffffffff1614155b15611415576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b73ffffffffffffffffffffffffffffffffffffffff84811660008181526002602090815260408083208884528252808320948716808452948252918290208590558151938452830184905285927f41eb9ccd292d5906dc1f0ec108bed3e2b966e3071e033df938f7215f6d30ca84910160405180910390a350505050565b61149b6115af565b6114a48161174e565b50565b6114af6115af565b73ffffffffffffffffffffffffffffffffffffffff8216611515576000805460405173ffffffffffffffffffffffffffffffffffffffff9091169183156108fc02918491818181858888f19350505050158015611510573d6000803e3d6000fd5b505050565b61155561153760005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff84169083611843565b6040805133815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f9b1bfa7fa9ee420a16e124f794c35ac9f90472acc99140eb2f6447c714cad8eb9060600160405180910390a15050565b60005473ffffffffffffffffffffffffffffffffffffffff163314611630576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016105f0565b565b6000821561166057816116466001856122d4565b6116509190612299565b61165b906001612249565b611663565b60005b90505b92915050565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526117489085907f23b872dd00000000000000000000000000000000000000000000000000000000906084015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff0000000000000000000000000000000000000000000000000000000090931692909217909152611899565b50505050565b3373ffffffffffffffffffffffffffffffffffffffff8216036117cd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016105f0565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526115109084907fa9059cbb00000000000000000000000000000000000000000000000000000000906064016116c6565b60006118fb826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166119a59092919063ffffffff16565b8051909150156115105780806020019051810190611919919061256f565b611510576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f7420737563636565640000000000000000000000000000000000000000000060648201526084016105f0565b60606119b484846000856119be565b90505b9392505050565b606082471015611a50576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c000000000000000000000000000000000000000000000000000060648201526084016105f0565b6000808673ffffffffffffffffffffffffffffffffffffffff168587604051611a799190612591565b60006040518083038185875af1925050503d8060008114611ab6576040519150601f19603f3d011682016040523d82523d6000602084013e611abb565b606091505b5091509150611acc87838387611ad9565b925050505b949350505050565b60608315611b6f578251600003611b685773ffffffffffffffffffffffffffffffffffffffff85163b611b68576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e747261637400000060448201526064016105f0565b5081611ad1565b611ad18383815115611b845781518083602001fd5b806040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105f09190611c37565b600060208284031215611bca57600080fd5b5035919050565b600060208284031215611be357600080fd5b81357fffffffff00000000000000000000000000000000000000000000000000000000811681146119b757600080fd5b60005b83811015611c2e578181015183820152602001611c16565b50506000910152565b6020815260008251806020840152611c56816040850160208701611c13565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b600080600060408486031215611c9d57600080fd5b83359250602084013567ffffffffffffffff80821115611cbc57600080fd5b818601915086601f830112611cd057600080fd5b813581811115611cdf57600080fd5b8760208260061b8501011115611cf457600080fd5b6020830194508093505050509250925092565b73ffffffffffffffffffffffffffffffffffffffff811681146114a457600080fd5b600080600060608486031215611d3e57600080fd5b8335611d4981611d07565b9250602084013591506040840135611d6081611d07565b809150509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b6040516020810167ffffffffffffffff81118282101715611dbd57611dbd611d6b565b60405290565b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611e0a57611e0a611d6b565b604052919050565b600082601f830112611e2357600080fd5b813567ffffffffffffffff811115611e3d57611e3d611d6b565b611e6e60207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f84011601611dc3565b818152846020838601011115611e8357600080fd5b816020850160208301376000918101602001919091529392505050565b60008060008385036060811215611eb657600080fd5b8435611ec181611d07565b9350602085013567ffffffffffffffff811115611edd57600080fd5b611ee987828801611e12565b93505060207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffc082011215611f1c57600080fd5b50611f25611d9a565b6040850135611f3381611d07565b815292959194509192509050565b825173ffffffffffffffffffffffffffffffffffffffff1681526020808401519082015260808101825173ffffffffffffffffffffffffffffffffffffffff166040830152602083015160608301526119b7565b600080600060408486031215611faa57600080fd5b833567ffffffffffffffff80821115611fc257600080fd5b818601915086601f830112611fd657600080fd5b813581811115611fe557600080fd5b876020828501011115611ff757600080fd5b60209283019550935050840135611d6081611d07565b6000806000806080858703121561202357600080fd5b843561202e81611d07565b935060208501359250604085013561204581611d07565b9396929550929360600135925050565b60006020828403121561206757600080fd5b81356119b781611d07565b6000806040838503121561208557600080fd5b823561209081611d07565b946020939093013593505050565b8381526040602080830182905282820184905260009190859060608501845b878110156121005783356120d081611d07565b73ffffffffffffffffffffffffffffffffffffffff168252838301358383015292840192908401906001016120bd565b5098975050505050505050565b8051602080830151919081101561214c577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8160200360031b1b821691505b50919050565b805163ffffffff8116811461216657600080fd5b919050565b805177ffffffffffffffffffffffffffffffffffffffffffffffff8116811461216657600080fd5b600080600080600080600060e0888a0312156121ae57600080fd5b875196506121be60208901612152565b95506121cc60408901612152565b945060608801518060170b81146121e257600080fd5b93506121f06080890161216b565b92506121fe60a0890161216b565b915061220c60c08901612152565b905092959891949750929550565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b808201808211156116665761166661221a565b6000817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff04831182151516156122945761229461221a565b500290565b6000826122cf577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500490565b818103818111156116665761166661221a565b6000602082840312156122f957600080fd5b5051919050565b600082601f83011261231157600080fd5b6040516060810181811067ffffffffffffffff8211171561233457612334611d6b565b60405280606084018581111561234957600080fd5b845b8181101561236357803583526020928301920161234b565b509195945050505050565b6000806080838503121561238157600080fd5b61238b8484612300565b9150606083013567ffffffffffffffff8111156123a757600080fd5b6123b385828601611e12565b9150509250929050565b600082601f8301126123ce57600080fd5b8135602067ffffffffffffffff8211156123ea576123ea611d6b565b8160051b6123f9828201611dc3565b928352848101820192828101908785111561241357600080fd5b83870192505b8483101561243257823582529183019190830190612419565b979650505050505050565b600080600080600080610100878903121561245757600080fd5b6124618888612300565b9550606087013567ffffffffffffffff8082111561247e57600080fd5b61248a8a838b01611e12565b965060808901359150808211156124a057600080fd5b6124ac8a838b016123bd565b955060a08901359150808211156124c257600080fd5b6124ce8a838b016123bd565b945060c0890135935060e08901359150808211156124eb57600080fd5b506124f889828a01611e12565b9150509295509295509295565b60006020828403121561251757600080fd5b61251f611d9a565b825161252a81611d07565b81529392505050565b80356020831015611666577fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff602084900360031b1b1692915050565b60006020828403121561258157600080fd5b815180151581146119b757600080fd5b600082516125a3818460208701611c13565b919091019291505056fea164736f6c6343000810000a", } var FeeManagerABI = FeeManagerMetaData.ABI @@ -252,6 +252,28 @@ func (_FeeManager *FeeManagerCallerSession) Owner() (common.Address, error) { return _FeeManager.Contract.Owner(&_FeeManager.CallOpts) } +func (_FeeManager *FeeManagerCaller) SLinkDeficit(opts *bind.CallOpts, arg0 [32]byte) (*big.Int, error) { + var out []interface{} + err := _FeeManager.contract.Call(opts, &out, "s_linkDeficit", arg0) + + if err != nil { + return *new(*big.Int), err + } + + out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) + + return out0, err + +} + +func (_FeeManager *FeeManagerSession) SLinkDeficit(arg0 [32]byte) (*big.Int, error) { + return _FeeManager.Contract.SLinkDeficit(&_FeeManager.CallOpts, arg0) +} + +func (_FeeManager *FeeManagerCallerSession) SLinkDeficit(arg0 [32]byte) (*big.Int, error) { + return _FeeManager.Contract.SLinkDeficit(&_FeeManager.CallOpts, arg0) +} + func (_FeeManager *FeeManagerCaller) SNativeSurcharge(opts *bind.CallOpts) (*big.Int, error) { var out []interface{} err := _FeeManager.contract.Call(opts, &out, "s_nativeSurcharge") @@ -352,6 +374,18 @@ func (_FeeManager *FeeManagerTransactorSession) AcceptOwnership() (*types.Transa return _FeeManager.Contract.AcceptOwnership(&_FeeManager.TransactOpts) } +func (_FeeManager *FeeManagerTransactor) PayLinkDeficit(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) { + return _FeeManager.contract.Transact(opts, "payLinkDeficit", configDigest) +} + +func (_FeeManager *FeeManagerSession) PayLinkDeficit(configDigest [32]byte) (*types.Transaction, error) { + return _FeeManager.Contract.PayLinkDeficit(&_FeeManager.TransactOpts, configDigest) +} + +func (_FeeManager *FeeManagerTransactorSession) PayLinkDeficit(configDigest [32]byte) (*types.Transaction, error) { + return _FeeManager.Contract.PayLinkDeficit(&_FeeManager.TransactOpts, configDigest) +} + func (_FeeManager *FeeManagerTransactor) ProcessFee(opts *bind.TransactOpts, payload []byte, subscriber common.Address) (*types.Transaction, error) { return _FeeManager.contract.Transact(opts, "processFee", payload, subscriber) } @@ -553,6 +587,134 @@ func (_FeeManager *FeeManagerFilterer) ParseInsufficientLink(log types.Log) (*Fe return event, nil } +type FeeManagerLinkDeficitClearedIterator struct { + Event *FeeManagerLinkDeficitCleared + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FeeManagerLinkDeficitClearedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FeeManagerLinkDeficitCleared) + 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(FeeManagerLinkDeficitCleared) + 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 *FeeManagerLinkDeficitClearedIterator) Error() error { + return it.fail +} + +func (it *FeeManagerLinkDeficitClearedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FeeManagerLinkDeficitCleared struct { + ConfigDigest [32]byte + LinkQuantity *big.Int + Raw types.Log +} + +func (_FeeManager *FeeManagerFilterer) FilterLinkDeficitCleared(opts *bind.FilterOpts, configDigest [][32]byte) (*FeeManagerLinkDeficitClearedIterator, error) { + + var configDigestRule []interface{} + for _, configDigestItem := range configDigest { + configDigestRule = append(configDigestRule, configDigestItem) + } + + logs, sub, err := _FeeManager.contract.FilterLogs(opts, "LinkDeficitCleared", configDigestRule) + if err != nil { + return nil, err + } + return &FeeManagerLinkDeficitClearedIterator{contract: _FeeManager.contract, event: "LinkDeficitCleared", logs: logs, sub: sub}, nil +} + +func (_FeeManager *FeeManagerFilterer) WatchLinkDeficitCleared(opts *bind.WatchOpts, sink chan<- *FeeManagerLinkDeficitCleared, configDigest [][32]byte) (event.Subscription, error) { + + var configDigestRule []interface{} + for _, configDigestItem := range configDigest { + configDigestRule = append(configDigestRule, configDigestItem) + } + + logs, sub, err := _FeeManager.contract.WatchLogs(opts, "LinkDeficitCleared", configDigestRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FeeManagerLinkDeficitCleared) + if err := _FeeManager.contract.UnpackLog(event, "LinkDeficitCleared", 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 (_FeeManager *FeeManagerFilterer) ParseLinkDeficitCleared(log types.Log) (*FeeManagerLinkDeficitCleared, error) { + event := new(FeeManagerLinkDeficitCleared) + if err := _FeeManager.contract.UnpackLog(event, "LinkDeficitCleared", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + type FeeManagerNativeSurchargeUpdatedIterator struct { Event *FeeManagerNativeSurchargeUpdated @@ -1203,6 +1365,8 @@ func (_FeeManager *FeeManager) ParseLog(log types.Log) (generated.AbigenLog, err switch log.Topics[0] { case _FeeManager.abi.Events["InsufficientLink"].ID: return _FeeManager.ParseInsufficientLink(log) + case _FeeManager.abi.Events["LinkDeficitCleared"].ID: + return _FeeManager.ParseLinkDeficitCleared(log) case _FeeManager.abi.Events["NativeSurchargeUpdated"].ID: return _FeeManager.ParseNativeSurchargeUpdated(log) case _FeeManager.abi.Events["OwnershipTransferRequested"].ID: @@ -1223,6 +1387,10 @@ func (FeeManagerInsufficientLink) Topic() common.Hash { return common.HexToHash("0xeb6f22018570d97db6df12dc94f202b4e2b2888a6a5d4bd179422c91b29dcdf7") } +func (FeeManagerLinkDeficitCleared) Topic() common.Hash { + return common.HexToHash("0x843f0b103e50b42b08f9d30f12f961845a6d02623730872e24644899c0dd9895") +} + func (FeeManagerNativeSurchargeUpdated) Topic() common.Hash { return common.HexToHash("0xa320ddc8288125050af9b9b75fd872443f8c722e70b14fc8475dbd630a4916e1") } @@ -1254,6 +1422,8 @@ type FeeManagerInterface interface { Owner(opts *bind.CallOpts) (common.Address, error) + SLinkDeficit(opts *bind.CallOpts, arg0 [32]byte) (*big.Int, error) + SNativeSurcharge(opts *bind.CallOpts) (*big.Int, error) SSubscriberDiscounts(opts *bind.CallOpts, arg0 common.Address, arg1 [32]byte, arg2 common.Address) (*big.Int, error) @@ -1264,6 +1434,8 @@ type FeeManagerInterface interface { AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + PayLinkDeficit(opts *bind.TransactOpts, configDigest [32]byte) (*types.Transaction, error) + ProcessFee(opts *bind.TransactOpts, payload []byte, subscriber common.Address) (*types.Transaction, error) SetFeeRecipients(opts *bind.TransactOpts, configDigest [32]byte, rewardRecipientAndWeights []CommonAddressAndWeight) (*types.Transaction, error) @@ -1282,6 +1454,12 @@ type FeeManagerInterface interface { ParseInsufficientLink(log types.Log) (*FeeManagerInsufficientLink, error) + FilterLinkDeficitCleared(opts *bind.FilterOpts, configDigest [][32]byte) (*FeeManagerLinkDeficitClearedIterator, error) + + WatchLinkDeficitCleared(opts *bind.WatchOpts, sink chan<- *FeeManagerLinkDeficitCleared, configDigest [][32]byte) (event.Subscription, error) + + ParseLinkDeficitCleared(log types.Log) (*FeeManagerLinkDeficitCleared, error) + FilterNativeSurchargeUpdated(opts *bind.FilterOpts) (*FeeManagerNativeSurchargeUpdatedIterator, error) WatchNativeSurchargeUpdated(opts *bind.WatchOpts, sink chan<- *FeeManagerNativeSurchargeUpdated) (event.Subscription, error) diff --git a/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go b/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go index d533c426c26..3ea1bee3e8b 100644 --- a/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go +++ b/core/gethwrappers/llo-feeds/generated/reward_manager/reward_manager.go @@ -37,7 +37,7 @@ type CommonAddressAndWeight struct { var RewardManagerMetaData = &bind.MetaData{ ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"linkAddress\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"InvalidAddress\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidPoolId\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"InvalidWeights\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"Unauthorized\",\"type\":\"error\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"address\",\"name\":\"newFeeManagerAddress\",\"type\":\"address\"}],\"name\":\"FeeManagerUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":false,\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"indexed\":false,\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"FeePaid\",\"type\":\"event\"},{\"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\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"indexed\":false,\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"newRewardRecipients\",\"type\":\"tuple[]\"}],\"name\":\"RewardRecipientsUpdated\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"indexed\":true,\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"},{\"indexed\":false,\"internalType\":\"uint256\",\"name\":\"quantity\",\"type\":\"uint256\"}],\"name\":\"RewardsClaimed\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"poolIds\",\"type\":\"bytes32[]\"}],\"name\":\"claimRewards\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"recipient\",\"type\":\"address\"}],\"name\":\"getAvailableRewardPoolIds\",\"outputs\":[{\"internalType\":\"bytes32[]\",\"name\":\"\",\"type\":\"bytes32[]\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"payee\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"amount\",\"type\":\"uint256\"}],\"name\":\"onFeePaid\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"internalType\":\"address[]\",\"name\":\"recipients\",\"type\":\"address[]\"}],\"name\":\"payRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_feeManagerAddress\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"name\":\"s_registeredPoolIds\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"},{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"name\":\"s_rewardRecipientWeights\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"name\":\"s_totalRewardRecipientFees\",\"outputs\":[{\"internalType\":\"uint256\",\"name\":\"\",\"type\":\"uint256\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"newFeeManagerAddress\",\"type\":\"address\"}],\"name\":\"setFeeManager\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"rewardRecipientAndWeights\",\"type\":\"tuple[]\"}],\"name\":\"setRewardRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes4\",\"name\":\"interfaceId\",\"type\":\"bytes4\"}],\"name\":\"supportsInterface\",\"outputs\":[{\"internalType\":\"bool\",\"name\":\"\",\"type\":\"bool\"}],\"stateMutability\":\"pure\",\"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\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"poolId\",\"type\":\"bytes32\"},{\"components\":[{\"internalType\":\"address\",\"name\":\"addr\",\"type\":\"address\"},{\"internalType\":\"uint256\",\"name\":\"weight\",\"type\":\"uint256\"}],\"internalType\":\"structCommon.AddressAndWeight[]\",\"name\":\"newRewardRecipients\",\"type\":\"tuple[]\"}],\"name\":\"updateRewardRecipients\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", - Bin: "0x60a06040523480156200001157600080fd5b50604051620019ce380380620019ce8339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b6080516117d3620001fb600039600081816109f10152610dda01526117d36000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c80636992922f11610097578063cd5f729211610066578063cd5f7292146102e0578063efb03fe9146102f3578063f2fde38b14610306578063f34517aa1461031957600080fd5b80636992922f1461026f57806379ba50971461028f5780638ac85a5c146102975780638da5cb5b146102c257600080fd5b806339ee81e1116100d357806339ee81e114610208578063472d35b9146102365780634d32208414610249578063633b5f6e1461025c57600080fd5b806301ffc9a7146101055780630f3c34d11461016f578063181f5a7714610184578063276e7660146101c3575b600080fd5b61015a61011336600461127a565b7fffffffff00000000000000000000000000000000000000000000000000000000167fefb03fe9000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b61018261017d36600461133a565b61032c565b005b604080518082018252601381527f5265776172644d616e6167657220302e302e31000000000000000000000000006020820152905161016691906113e0565b6007546101e39073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610166565b61022861021636600461144c565b60026020526000908152604090205481565b604051908152602001610166565b61018261024436600461148e565b61033a565b6101826102573660046114b0565b610408565b61018261026a36600461152f565b61053f565b61028261027d36600461148e565b6106f5565b604051610166919061159b565b6101826107f1565b6102286102a53660046115df565b600460209081526000928352604080842090915290825290205481565b60005473ffffffffffffffffffffffffffffffffffffffff166101e3565b6102286102ee36600461144c565b6108f3565b61018261030136600461160b565b610914565b61018261031436600461148e565b610aba565b61018261032736600461152f565b610ace565b6103363382610c48565b5050565b610342610e52565b73ffffffffffffffffffffffffffffffffffffffff811661038f576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527fe45f5e140399b0a7e12971ab020724b828fbed8ac408c420884dc7d1bbe506b49060200160405180910390a150565b8261042860005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415801561047a57506000818152600460209081526040808320338452909152902054155b156104b1576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160018082528183019092526000916020808301908036833701905050905084816000815181106104e7576104e7611640565b60200260200101818152505060005b838110156105375761052e85858381811061051357610513611640565b9050602002016020810190610528919061148e565b83610c48565b506001016104f6565b505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061057f575060075473ffffffffffffffffffffffffffffffffffffffff163314155b156105b6576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008190036105f1576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526005602052604090205460ff161561063a576040517f0afa7ee800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006805460018181019092557ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f01849055600084815260056020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690911790556106b6838383670de0b6b3a7640000610ed5565b827fe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b38419683836040516106e892919061166f565b60405180910390a2505050565b60065460609060008167ffffffffffffffff811115610716576107166112bc565b60405190808252806020026020018201604052801561073f578160200160208202803683370190505b5090506000805b838110156107e75760006006828154811061076357610763611640565b600091825260208083209091015480835260048252604080842073ffffffffffffffffffffffffffffffffffffffff8c168552909252912054909150156107de57600081815260026020526040902054156107de57808484815181106107cb576107cb611640565b6020026020010181815250508260010192505b50600101610746565b5090949350505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610877576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6006818154811061090357600080fd5b600091825260209091200154905081565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610954575060075473ffffffffffffffffffffffffffffffffffffffff163314155b1561098b576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526002602052604090819020805483019055517f23b872dd00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8381166004830152306024830152604482018390527f000000000000000000000000000000000000000000000000000000000000000016906323b872dd906064016020604051808303816000875af1158015610a3a573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a5e91906116d3565b506040805184815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f0ae7c9bfbc7dfc3426a34852f9a1cdd2f750abec8190abbff0bbe13d8118c30c9060600160405180910390a1505050565b610ac2610e52565b610acb816110ce565b50565b610ad6610e52565b604080516001808252818301909252600091602080830190803683370190505090508381600081518110610b0c57610b0c611640565b6020026020010181815250506000805b83811015610bfa576000858583818110610b3857610b38611640565b610b4e926020604090920201908101915061148e565b600088815260046020908152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152812054919250819003610bba576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610beb878785818110610bcf57610bcf611640565b610be5926020604090920201908101915061148e565b86610c48565b50929092019150600101610b1c565b50610c0785858584610ed5565b847fe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b3841968585604051610c3992919061166f565b60405180910390a25050505050565b60008060005b8351811015610d87576000848281518110610c6b57610c6b611640565b6020908102919091018101516000818152600283526040808220546003855281832073ffffffffffffffffffffffffffffffffffffffff8c16808552908652828420548585526004875283852091855295529082205492945092830391670de0b6b3a76400009083020490819003610ce65750505050610d77565b600084815260036020908152604080832073ffffffffffffffffffffffffffffffffffffffff8d168085529252909120849055885196820196899087908110610d3157610d31611640565b60200260200101517ffec539b3c42d74cd492c3ecf7966bf014b327beef98e935cdc3ec5e54a6901c783604051610d6a91815260200190565b60405180910390a3505050505b610d8081611724565b9050610c4e565b508015610e49576040517fa9059cbb00000000000000000000000000000000000000000000000000000000815273ffffffffffffffffffffffffffffffffffffffff8581166004830152602482018390527f0000000000000000000000000000000000000000000000000000000000000000169063a9059cbb906044016020604051808303816000875af1158015610e23573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610e4791906116d3565b505b90505b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610ed3576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161086e565b565b610f308383808060200260200160405190810160405280939291908181526020016000905b82821015610f2657610f176040830286013681900381019061175c565b81526020019060010190610efa565b50505050506111c3565b15610f67576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b8381101561108d576000858583818110610f8757610f87611640565b9050604002016020013590506000868684818110610fa757610fa7611640565b610fbd926020604090920201908101915061148e565b905073ffffffffffffffffffffffffffffffffffffffff811661100c576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81600003611046576040517f84677ce800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600088815260046020908152604080832073ffffffffffffffffffffffffffffffffffffffff909416835292905220819055919091019061108681611724565b9050610f6b565b508181146110c7576040517f84677ce800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050565b3373ffffffffffffffffffffffffffffffffffffffff82160361114d576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161086e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000805b82518110156112715760006111dd8260016117b3565b90505b8351811015611268578381815181106111fb576111fb611640565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1684838151811061122f5761122f611640565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff1603611260575060019392505050565b6001016111e0565b506001016111c7565b50600092915050565b60006020828403121561128c57600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610e4957600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611332576113326112bc565b604052919050565b6000602080838503121561134d57600080fd5b823567ffffffffffffffff8082111561136557600080fd5b818501915085601f83011261137957600080fd5b81358181111561138b5761138b6112bc565b8060051b915061139c8483016112eb565b81815291830184019184810190888411156113b657600080fd5b938501935b838510156113d4578435825293850193908501906113bb565b98975050505050505050565b600060208083528351808285015260005b8181101561140d578581018301518582016040015282016113f1565b5060006040828601015260407fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f8301168501019250505092915050565b60006020828403121561145e57600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff8116811461148957600080fd5b919050565b6000602082840312156114a057600080fd5b6114a982611465565b9392505050565b6000806000604084860312156114c557600080fd5b83359250602084013567ffffffffffffffff808211156114e457600080fd5b818601915086601f8301126114f857600080fd5b81358181111561150757600080fd5b8760208260051b850101111561151c57600080fd5b6020830194508093505050509250925092565b60008060006040848603121561154457600080fd5b83359250602084013567ffffffffffffffff8082111561156357600080fd5b818601915086601f83011261157757600080fd5b81358181111561158657600080fd5b8760208260061b850101111561151c57600080fd5b6020808252825182820181905260009190848201906040850190845b818110156115d3578351835292840192918401916001016115b7565b50909695505050505050565b600080604083850312156115f257600080fd5b8235915061160260208401611465565b90509250929050565b60008060006060848603121561162057600080fd5b8335925061163060208501611465565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020808252818101839052600090604080840186845b878110156116c65773ffffffffffffffffffffffffffffffffffffffff6116ab83611465565b16835281850135858401529183019190830190600101611685565b5090979650505050505050565b6000602082840312156116e557600080fd5b81518015158114610e4957600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611755576117556116f5565b5060010190565b60006040828403121561176e57600080fd5b6040516040810181811067ffffffffffffffff82111715611791576117916112bc565b60405261179d83611465565b8152602083013560208201528091505092915050565b80820180821115610e4c57610e4c6116f556fea164736f6c6343000810000a", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001d5338038062001d538339810160408190526200003491620001a6565b33806000816200008b5760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000be57620000be81620000fb565b5050506001600160a01b038116620000e95760405163e6c4247b60e01b815260040160405180910390fd5b6001600160a01b0316608052620001d8565b336001600160a01b03821603620001555760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640162000082565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b600060208284031215620001b957600080fd5b81516001600160a01b0381168114620001d157600080fd5b9392505050565b608051611b58620001fb600039600081816109b90152610d2a0152611b586000f3fe608060405234801561001057600080fd5b50600436106101005760003560e01c80636992922f11610097578063cd5f729211610066578063cd5f7292146102e0578063efb03fe9146102f3578063f2fde38b14610306578063f34517aa1461031957600080fd5b80636992922f1461026f57806379ba50971461028f5780638ac85a5c146102975780638da5cb5b146102c257600080fd5b806339ee81e1116100d357806339ee81e114610208578063472d35b9146102365780634d32208414610249578063633b5f6e1461025c57600080fd5b806301ffc9a7146101055780630f3c34d11461016f578063181f5a7714610184578063276e7660146101c3575b600080fd5b61015a6101133660046115da565b7fffffffff00000000000000000000000000000000000000000000000000000000167fefb03fe9000000000000000000000000000000000000000000000000000000001490565b60405190151581526020015b60405180910390f35b61018261017d36600461169a565b61032c565b005b604080518082018252601381527f5265776172644d616e6167657220302e302e3100000000000000000000000000602082015290516101669190611764565b6007546101e39073ffffffffffffffffffffffffffffffffffffffff1681565b60405173ffffffffffffffffffffffffffffffffffffffff9091168152602001610166565b6102286102163660046117b5565b60026020526000908152604090205481565b604051908152602001610166565b6101826102443660046117f7565b61033a565b610182610257366004611819565b610408565b61018261026a366004611898565b61053f565b61028261027d3660046117f7565b6106f5565b6040516101669190611904565b6101826107f1565b6102286102a5366004611948565b600460209081526000928352604080842090915290825290205481565b60005473ffffffffffffffffffffffffffffffffffffffff166101e3565b6102286102ee3660046117b5565b6108f3565b610182610301366004611974565b610914565b6101826103143660046117f7565b610a3c565b610182610327366004611898565b610a50565b6103363382610bca565b5050565b610342610d5a565b73ffffffffffffffffffffffffffffffffffffffff811661038f576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600780547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83169081179091556040519081527fe45f5e140399b0a7e12971ab020724b828fbed8ac408c420884dc7d1bbe506b49060200160405180910390a150565b8261042860005473ffffffffffffffffffffffffffffffffffffffff1690565b73ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161415801561047a57506000818152600460209081526040808320338452909152902054155b156104b1576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6040805160018082528183019092526000916020808301908036833701905050905084816000815181106104e7576104e76119a9565b60200260200101818152505060005b838110156105375761052e858583818110610513576105136119a9565b905060200201602081019061052891906117f7565b83610bca565b506001016104f6565b505050505050565b60005473ffffffffffffffffffffffffffffffffffffffff16331480159061057f575060075473ffffffffffffffffffffffffffffffffffffffff163314155b156105b6576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008190036105f1576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526005602052604090205460ff161561063a576040517f0afa7ee800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6006805460018181019092557ff652222313e28459528d920b65115c16c04f3efc82aaedc97be59f3f377c0d3f01849055600084815260056020526040902080547fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff001690911790556106b6838383670de0b6b3a7640000610ddd565b827fe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b38419683836040516106e89291906119d8565b60405180910390a2505050565b60065460609060008167ffffffffffffffff8111156107165761071661161c565b60405190808252806020026020018201604052801561073f578160200160208202803683370190505b5090506000805b838110156107e757600060068281548110610763576107636119a9565b600091825260208083209091015480835260048252604080842073ffffffffffffffffffffffffffffffffffffffff8c168552909252912054909150156107de57600081815260026020526040902054156107de57808484815181106107cb576107cb6119a9565b6020026020010181815250508260010192505b50600101610746565b5090949350505050565b60015473ffffffffffffffffffffffffffffffffffffffff163314610877576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6006818154811061090357600080fd5b600091825260209091200154905081565b60005473ffffffffffffffffffffffffffffffffffffffff163314801590610954575060075473ffffffffffffffffffffffffffffffffffffffff163314155b1561098b576040517f82b4290000000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60008381526002602052604090208054820190556109e173ffffffffffffffffffffffffffffffffffffffff7f000000000000000000000000000000000000000000000000000000000000000016833084610fd6565b6040805184815273ffffffffffffffffffffffffffffffffffffffff841660208201529081018290527f0ae7c9bfbc7dfc3426a34852f9a1cdd2f750abec8190abbff0bbe13d8118c30c9060600160405180910390a1505050565b610a44610d5a565b610a4d816110b8565b50565b610a58610d5a565b604080516001808252818301909252600091602080830190803683370190505090508381600081518110610a8e57610a8e6119a9565b6020026020010181815250506000805b83811015610b7c576000858583818110610aba57610aba6119a9565b610ad092602060409092020190810191506117f7565b600088815260046020908152604080832073ffffffffffffffffffffffffffffffffffffffff85168452909152812054919250819003610b3c576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b610b6d878785818110610b5157610b516119a9565b610b6792602060409092020190810191506117f7565b86610bca565b50929092019150600101610a9e565b50610b8985858584610ddd565b847fe5ca4131deaeb848b5d6a9c0f85795efc54e8a0252eb38d3e77a1efc2b3841968585604051610bbb9291906119d8565b60405180910390a25050505050565b60008060005b8351811015610d09576000848281518110610bed57610bed6119a9565b6020908102919091018101516000818152600283526040808220546003855281832073ffffffffffffffffffffffffffffffffffffffff8c16808552908652828420548585526004875283852091855295529082205492945092830391670de0b6b3a76400009083020490819003610c685750505050610cf9565b600084815260036020908152604080832073ffffffffffffffffffffffffffffffffffffffff8d168085529252909120849055885196820196899087908110610cb357610cb36119a9565b60200260200101517ffec539b3c42d74cd492c3ecf7966bf014b327beef98e935cdc3ec5e54a6901c783604051610cec91815260200190565b60405180910390a3505050505b610d0281611a6b565b9050610bd0565b508015610d5157610d5173ffffffffffffffffffffffffffffffffffffffff7f00000000000000000000000000000000000000000000000000000000000000001685836111ad565b90505b92915050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610ddb576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e657200000000000000000000604482015260640161086e565b565b610e388383808060200260200160405190810160405280939291908181526020016000905b82821015610e2e57610e1f60408302860136819003810190611aa3565b81526020019060010190610e02565b5050505050611208565b15610e6f576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b6000805b83811015610f95576000858583818110610e8f57610e8f6119a9565b9050604002016020013590506000868684818110610eaf57610eaf6119a9565b610ec592602060409092020190810191506117f7565b905073ffffffffffffffffffffffffffffffffffffffff8116610f14576040517fe6c4247b00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b81600003610f4e576040517f84677ce800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b600088815260046020908152604080832073ffffffffffffffffffffffffffffffffffffffff9094168352929052208190559190910190610f8e81611a6b565b9050610e73565b50818114610fcf576040517f84677ce800000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b5050505050565b60405173ffffffffffffffffffffffffffffffffffffffff808516602483015283166044820152606481018290526110b29085907f23b872dd00000000000000000000000000000000000000000000000000000000906084015b604080517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe08184030181529190526020810180517bffffffffffffffffffffffffffffffffffffffffffffffffffffffff167fffffffff00000000000000000000000000000000000000000000000000000000909316929092179091526112bf565b50505050565b3373ffffffffffffffffffffffffffffffffffffffff821603611137576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c66000000000000000000604482015260640161086e565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60405173ffffffffffffffffffffffffffffffffffffffff83166024820152604481018290526112039084907fa9059cbb0000000000000000000000000000000000000000000000000000000090606401611030565b505050565b6000805b82518110156112b6576000611222826001611afa565b90505b83518110156112ad57838181518110611240576112406119a9565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff16848381518110611274576112746119a9565b60200260200101516000015173ffffffffffffffffffffffffffffffffffffffff16036112a5575060019392505050565b600101611225565b5060010161120c565b50600092915050565b6000611321826040518060400160405280602081526020017f5361666545524332303a206c6f772d6c6576656c2063616c6c206661696c65648152508573ffffffffffffffffffffffffffffffffffffffff166113cb9092919063ffffffff16565b805190915015611203578080602001905181019061133f9190611b0d565b611203576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602a60248201527f5361666545524332303a204552433230206f7065726174696f6e20646964206e60448201527f6f74207375636365656400000000000000000000000000000000000000000000606482015260840161086e565b60606113da84846000856113e2565b949350505050565b606082471015611474576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152602660248201527f416464726573733a20696e73756666696369656e742062616c616e636520666f60448201527f722063616c6c0000000000000000000000000000000000000000000000000000606482015260840161086e565b6000808673ffffffffffffffffffffffffffffffffffffffff16858760405161149d9190611b2f565b60006040518083038185875af1925050503d80600081146114da576040519150601f19603f3d011682016040523d82523d6000602084013e6114df565b606091505b50915091506114f0878383876114fb565b979650505050505050565b6060831561159157825160000361158a5773ffffffffffffffffffffffffffffffffffffffff85163b61158a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601d60248201527f416464726573733a2063616c6c20746f206e6f6e2d636f6e7472616374000000604482015260640161086e565b50816113da565b6113da83838151156115a65781518083602001fd5b806040517f08c379a000000000000000000000000000000000000000000000000000000000815260040161086e9190611764565b6000602082840312156115ec57600080fd5b81357fffffffff0000000000000000000000000000000000000000000000000000000081168114610d5157600080fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff811182821017156116925761169261161c565b604052919050565b600060208083850312156116ad57600080fd5b823567ffffffffffffffff808211156116c557600080fd5b818501915085601f8301126116d957600080fd5b8135818111156116eb576116eb61161c565b8060051b91506116fc84830161164b565b818152918301840191848101908884111561171657600080fd5b938501935b838510156117345784358252938501939085019061171b565b98975050505050505050565b60005b8381101561175b578181015183820152602001611743565b50506000910152565b6020815260008251806020840152611783816040850160208701611740565b601f017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0169190910160400192915050565b6000602082840312156117c757600080fd5b5035919050565b803573ffffffffffffffffffffffffffffffffffffffff811681146117f257600080fd5b919050565b60006020828403121561180957600080fd5b611812826117ce565b9392505050565b60008060006040848603121561182e57600080fd5b83359250602084013567ffffffffffffffff8082111561184d57600080fd5b818601915086601f83011261186157600080fd5b81358181111561187057600080fd5b8760208260051b850101111561188557600080fd5b6020830194508093505050509250925092565b6000806000604084860312156118ad57600080fd5b83359250602084013567ffffffffffffffff808211156118cc57600080fd5b818601915086601f8301126118e057600080fd5b8135818111156118ef57600080fd5b8760208260061b850101111561188557600080fd5b6020808252825182820181905260009190848201906040850190845b8181101561193c57835183529284019291840191600101611920565b50909695505050505050565b6000806040838503121561195b57600080fd5b8235915061196b602084016117ce565b90509250929050565b60008060006060848603121561198957600080fd5b83359250611999602085016117ce565b9150604084013590509250925092565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b6020808252818101839052600090604080840186845b87811015611a2f5773ffffffffffffffffffffffffffffffffffffffff611a14836117ce565b168352818501358584015291830191908301906001016119ee565b5090979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff8203611a9c57611a9c611a3c565b5060010190565b600060408284031215611ab557600080fd5b6040516040810181811067ffffffffffffffff82111715611ad857611ad861161c565b604052611ae4836117ce565b8152602083013560208201528091505092915050565b80820180821115610d5457610d54611a3c565b600060208284031215611b1f57600080fd5b81518015158114610d5157600080fd5b60008251611b41818460208701611740565b919091019291505056fea164736f6c6343000810000a", } var RewardManagerABI = RewardManagerMetaData.ABI diff --git a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 7f218e76e4d..13b0f9ba040 100644 --- a/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/llo-feeds/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -1,9 +1,9 @@ GETH_VERSION: 1.12.0 errored_verifier: ../../../contracts/solc/v0.8.16/ErroredVerifier.abi ../../../contracts/solc/v0.8.16/ErroredVerifier.bin 1b0a03b90137d31fceb340b80ade65a4ed52fa63c5caf24183ce3f63567d818f exposed_verifier: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 -fee_manager: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin 3f0dbc02b8d9acd42e30ba9438f8eb3d47bdf5ce1f10814eabaf3e401bc6cf7d +fee_manager: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin 0fca974f9243402e60e1420382efe594a4eed910a849711a86b76bde01bba184 llo_feeds: ../../../contracts/solc/v0.8.16/FeeManager.abi ../../../contracts/solc/v0.8.16/FeeManager.bin cb71e018f67e49d7bc0e194c822204dfd59f79ff42e4fc8fd8ab63f3acd71361 llo_feeds_test: ../../../contracts/solc/v0.8.16/ExposedVerifier.abi ../../../contracts/solc/v0.8.16/ExposedVerifier.bin 6932cea8f2738e874d3ec9e1a4231d2421704030c071d9e15dd2f7f08482c246 -reward_manager: ../../../contracts/solc/v0.8.16/RewardManager.abi ../../../contracts/solc/v0.8.16/RewardManager.bin 1694433bbcf39684ec105b3b1d9478f7158165c97b711483f1f4f4fa4eb61364 +reward_manager: ../../../contracts/solc/v0.8.16/RewardManager.abi ../../../contracts/solc/v0.8.16/RewardManager.bin b8a37ed1b1eb92004a5e9d6936877bf7254d04799c594824764bab5e52233d2c verifier: ../../../contracts/solc/v0.8.16/Verifier.abi ../../../contracts/solc/v0.8.16/Verifier.bin 3c9b047bd96056a8bf85c0a1e928044c1166c58c4bd6986975100877ff43f1ec verifier_proxy: ../../../contracts/solc/v0.8.16/VerifierProxy.abi ../../../contracts/solc/v0.8.16/VerifierProxy.bin 64c61227ccc947171c35c5cd5dc664c492fbe2139fdfee70d4941a0109261341 From 3d5d44aed00ac3c2c7f6dd4f755032bcd3d7f733 Mon Sep 17 00:00:00 2001 From: george-dorin <120329946+george-dorin@users.noreply.github.com> Date: Thu, 24 Aug 2023 16:58:29 +0300 Subject: [PATCH 262/270] Show jobs when a chain id disabled (#9948) * Combine errors * Fix lint * Show job spec if chain is disabled * Add test * Change to ErrNoSuchChainID --- core/services/job/orm.go | 5 +- core/web/resolver/job_test.go | 88 ++++++++++++++++++++++++----------- core/web/resolver/query.go | 4 ++ 3 files changed, 66 insertions(+), 31 deletions(-) diff --git a/core/services/job/orm.go b/core/services/job/orm.go index 342623a62be..d7cfbd0fc4a 100644 --- a/core/services/job/orm.go +++ b/core/services/job/orm.go @@ -684,10 +684,7 @@ func (o *orm) FindJobs(offset, limit int) (jobs []Job, count int, err error) { return err } for i := range jobs { - err = o.LoadEnvConfigVars(&jobs[i]) - if err != nil { - return err - } + err = multierr.Combine(err, o.LoadEnvConfigVars(&jobs[i])) } return nil }) diff --git a/core/web/resolver/job_test.go b/core/web/resolver/job_test.go index 8a34b5a4ffc..7d73d7d0d2a 100644 --- a/core/web/resolver/job_test.go +++ b/core/web/resolver/job_test.go @@ -13,6 +13,7 @@ import ( "github.com/stretchr/testify/mock" "gopkg.in/guregu/null.v4" + "github.com/smartcontractkit/chainlink/v2/core/chains" clnull "github.com/smartcontractkit/chainlink/v2/core/null" "github.com/smartcontractkit/chainlink/v2/core/services/directrequest" "github.com/smartcontractkit/chainlink/v2/core/services/job" @@ -171,6 +172,32 @@ func TestResolver_Job(t *testing.T) { } } ` + exampleJobResult = ` + { + "job": { + "id": "1", + "createdAt": "2021-01-01T00:00:00Z", + "externalJobID": "00000000-0000-0000-0000-000000000001", + "gasLimit": 123, + "maxTaskDuration": "1s", + "name": "job1", + "schemaVersion": 1, + "spec": { + "__typename": "OCRSpec" + }, + "runs": { + "__typename": "JobRunsPayload", + "results": [{ + "id": "200" + }], + "metadata": { + "total": 1 + } + }, + "observationSource": "ds1 [type=bridge name=voter_turnout];" + } + } + ` ) testCases := []GQLTestCase{ @@ -204,33 +231,8 @@ func TestResolver_Job(t *testing.T) { On("CountPipelineRunsByJobID", int32(1)). Return(int32(1), nil) }, - query: query, - result: ` - { - "job": { - "id": "1", - "createdAt": "2021-01-01T00:00:00Z", - "externalJobID": "00000000-0000-0000-0000-000000000001", - "gasLimit": 123, - "maxTaskDuration": "1s", - "name": "job1", - "schemaVersion": 1, - "spec": { - "__typename": "OCRSpec" - }, - "runs": { - "__typename": "JobRunsPayload", - "results": [{ - "id": "200" - }], - "metadata": { - "total": 1 - } - }, - "observationSource": "ds1 [type=bridge name=voter_turnout];" - } - } - `, + query: query, + result: exampleJobResult, }, { name: "not found", @@ -249,6 +251,38 @@ func TestResolver_Job(t *testing.T) { } `, }, + { + name: "show job when chainID is disabled", + authenticated: true, + before: func(f *gqlTestFramework) { + f.App.On("JobORM").Return(f.Mocks.jobORM) + f.Mocks.jobORM.On("FindJobWithoutSpecErrors", id).Return(job.Job{ + ID: 1, + Name: null.StringFrom("job1"), + SchemaVersion: 1, + GasLimit: clnull.Uint32From(123), + MaxTaskDuration: models.Interval(1 * time.Second), + ExternalJobID: externalJobID, + CreatedAt: f.Timestamp(), + Type: job.OffchainReporting, + OCROracleSpec: &job.OCROracleSpec{}, + PipelineSpec: &pipeline.Spec{ + DotDagSource: "ds1 [type=bridge name=voter_turnout];", + }, + }, chains.ErrNoSuchChainID) + f.Mocks.jobORM. + On("FindPipelineRunIDsByJobID", int32(1), 0, 50). + Return([]int64{200}, nil) + f.Mocks.jobORM. + On("FindPipelineRunsByIDs", []int64{200}). + Return([]pipeline.Run{{ID: 200}}, nil) + f.Mocks.jobORM. + On("CountPipelineRunsByJobID", int32(1)). + Return(int32(1), nil) + }, + query: query, + result: exampleJobResult, + }, } RunGQLTests(t, testCases) diff --git a/core/web/resolver/query.go b/core/web/resolver/query.go index 05a778a6624..22b95a2d2ef 100644 --- a/core/web/resolver/query.go +++ b/core/web/resolver/query.go @@ -153,7 +153,11 @@ func (r *Resolver) Job(ctx context.Context, args struct{ ID graphql.ID }) (*JobP if err != nil { if errors.Is(err, sql.ErrNoRows) { return NewJobPayload(r.App, nil, err), nil + } + //We still need to show the job in UI/CLI even if the chain id is disabled + if errors.Is(err, chains.ErrNoSuchChainID) { + return NewJobPayload(r.App, &j, err), nil } return nil, err From 2ad6189f450487c9982f45b8c4a6431ff76e6f24 Mon Sep 17 00:00:00 2001 From: Sergey Kudasov Date: Thu, 24 Aug 2023 17:18:32 +0300 Subject: [PATCH 263/270] TT-542 functions basic soak/load test (#10322) * TT-542 functions soak/load tests * TT-542 functions soak/load tests * TT-542 functions soak/load tests --- .../scripts/native_solc_compile_all_functions | 5 +- .../testhelpers/FunctionsLoadTestClient.sol | 71 ++ .../functions_load_test_client.go | 988 ++++++++++++++++++ ...rapper-dependency-versions-do-not-edit.txt | 1 + core/gethwrappers/functions/go_generate.go | 1 + .../contracts/contract_deployer.go | 19 + .../contracts/contract_loader.go | 82 ++ .../contracts/contract_models.go | 14 + .../contracts/ethereum_contracts.go | 96 ++ integration-tests/load/functions/README.md | 22 + .../load/functions/cmd/dashboard.go | 34 + integration-tests/load/functions/config.go | 80 ++ integration-tests/load/functions/config.toml | 34 + .../load/functions/functions_test.go | 62 ++ integration-tests/load/functions/gun.go | 36 + integration-tests/load/functions/setup.go | 64 ++ integration-tests/load/functions/util.go | 15 + 17 files changed, 1622 insertions(+), 2 deletions(-) create mode 100644 contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsLoadTestClient.sol create mode 100644 core/gethwrappers/functions/generated/functions_load_test_client/functions_load_test_client.go create mode 100644 integration-tests/load/functions/README.md create mode 100644 integration-tests/load/functions/cmd/dashboard.go create mode 100644 integration-tests/load/functions/config.go create mode 100644 integration-tests/load/functions/config.toml create mode 100644 integration-tests/load/functions/functions_test.go create mode 100644 integration-tests/load/functions/gun.go create mode 100644 integration-tests/load/functions/setup.go create mode 100644 integration-tests/load/functions/util.go diff --git a/contracts/scripts/native_solc_compile_all_functions b/contracts/scripts/native_solc_compile_all_functions index 8b342445fb1..904ad0563b3 100755 --- a/contracts/scripts/native_solc_compile_all_functions +++ b/contracts/scripts/native_solc_compile_all_functions @@ -55,5 +55,6 @@ compileContract 1_0_0 dev/1_0_0/FunctionsRouter.sol compileContract 1_0_0 dev/1_0_0/FunctionsCoordinator.sol compileContract 1_0_0 dev/1_0_0/accessControl/TermsOfServiceAllowList.sol compileContract 1_0_0 dev/1_0_0/example/FunctionsClientExample.sol -# Test helpers -compileContract 1_0_0 tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol \ No newline at end of file +## Test helpers +compileContract 1_0_0 tests/1_0_0/testhelpers/FunctionsCoordinatorTestHelper.sol +compileContract 1_0_0 tests/1_0_0/testhelpers/FunctionsLoadTestClient.sol \ No newline at end of file diff --git a/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsLoadTestClient.sol b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsLoadTestClient.sol new file mode 100644 index 00000000000..7aa46e9ba06 --- /dev/null +++ b/contracts/src/v0.8/functions/tests/1_0_0/testhelpers/FunctionsLoadTestClient.sol @@ -0,0 +1,71 @@ +// SPDX-License-Identifier: MIT +pragma solidity ^0.8.19; + +import {FunctionsClient} from "../../../dev/1_0_0/FunctionsClient.sol"; +import {ConfirmedOwner} from "../../../../shared/access/ConfirmedOwner.sol"; +import {FunctionsRequest} from "../../../dev/1_0_0/libraries/FunctionsRequest.sol"; + +/** + * @title Chainlink Functions load test client implementation + */ +contract FunctionsLoadTestClient is FunctionsClient, ConfirmedOwner { + using FunctionsRequest for FunctionsRequest.Request; + + uint32 public constant MAX_CALLBACK_GAS = 70_000; + + bytes32 public s_lastRequestId; + bytes32 public s_lastResponse; + bytes32 public s_lastError; + uint32 public s_lastResponseLength; + uint32 public s_lastErrorLength; + + constructor(address router) FunctionsClient(router) ConfirmedOwner(msg.sender) {} + + /** + * @notice Send a simple request + * @param source JavaScript source code + * @param encryptedSecretsReferences Encrypted secrets payload + * @param args List of arguments accessible from within the source code + * @param subscriptionId Billing ID + */ + function sendRequest( + string calldata source, + bytes calldata encryptedSecretsReferences, + string[] calldata args, + uint64 subscriptionId, + bytes32 jobId + ) external onlyOwner { + FunctionsRequest.Request memory req; + req.initializeRequestForInlineJavaScript(source); + if (encryptedSecretsReferences.length > 0) req.addSecretsReference(encryptedSecretsReferences); + if (args.length > 0) req.setArgs(args); + s_lastRequestId = _sendRequest(req.encodeCBOR(), subscriptionId, MAX_CALLBACK_GAS, jobId); + } + + /** + * @notice Store latest result/error + * @param requestId The request ID, returned by sendRequest() + * @param response Aggregated response from the user code + * @param err Aggregated error from the user code or from the execution pipeline + * Either response or error parameter will be set, but never both + */ + function fulfillRequest(bytes32 requestId, bytes memory response, bytes memory err) internal override { + // Save only the first 32 bytes of response/error to always fit within MAX_CALLBACK_GAS + s_lastRequestId = requestId; + s_lastResponse = bytesToBytes32(response); + s_lastResponseLength = uint32(response.length); + s_lastError = bytesToBytes32(err); + s_lastErrorLength = uint32(err.length); + } + + function bytesToBytes32(bytes memory b) private pure returns (bytes32 out) { + uint256 maxLen = 32; + if (b.length < 32) { + maxLen = b.length; + } + for (uint256 i = 0; i < maxLen; ++i) { + out |= bytes32(b[i]) >> (i * 8); + } + return out; + } +} diff --git a/core/gethwrappers/functions/generated/functions_load_test_client/functions_load_test_client.go b/core/gethwrappers/functions/generated/functions_load_test_client/functions_load_test_client.go new file mode 100644 index 00000000000..90d1ac33533 --- /dev/null +++ b/core/gethwrappers/functions/generated/functions_load_test_client/functions_load_test_client.go @@ -0,0 +1,988 @@ +// Code generated - DO NOT EDIT. +// This file is a generated binding and any manual changes will be lost. + +package functions_load_test_client + +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/v2/core/gethwrappers/generated" +) + +var ( + _ = errors.New + _ = big.NewInt + _ = strings.NewReader + _ = ethereum.NotFound + _ = bind.Bind + _ = common.Big1 + _ = types.BloomLookup + _ = event.NewSubscription + _ = abi.ConvertType +) + +var FunctionsLoadTestClientMetaData = &bind.MetaData{ + ABI: "[{\"inputs\":[{\"internalType\":\"address\",\"name\":\"router\",\"type\":\"address\"}],\"stateMutability\":\"nonpayable\",\"type\":\"constructor\"},{\"inputs\":[],\"name\":\"EmptyArgs\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"EmptySource\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"NoInlineSecrets\",\"type\":\"error\"},{\"inputs\":[],\"name\":\"OnlyRouterCanFulfill\",\"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\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestFulfilled\",\"type\":\"event\"},{\"anonymous\":false,\"inputs\":[{\"indexed\":true,\"internalType\":\"bytes32\",\"name\":\"id\",\"type\":\"bytes32\"}],\"name\":\"RequestSent\",\"type\":\"event\"},{\"inputs\":[],\"name\":\"MAX_CALLBACK_GAS\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"acceptOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"bytes32\",\"name\":\"requestId\",\"type\":\"bytes32\"},{\"internalType\":\"bytes\",\"name\":\"response\",\"type\":\"bytes\"},{\"internalType\":\"bytes\",\"name\":\"err\",\"type\":\"bytes\"}],\"name\":\"handleOracleFulfillment\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"owner\",\"outputs\":[{\"internalType\":\"address\",\"name\":\"\",\"type\":\"address\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastError\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastErrorLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastRequestId\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponse\",\"outputs\":[{\"internalType\":\"bytes32\",\"name\":\"\",\"type\":\"bytes32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[],\"name\":\"s_lastResponseLength\",\"outputs\":[{\"internalType\":\"uint32\",\"name\":\"\",\"type\":\"uint32\"}],\"stateMutability\":\"view\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"string\",\"name\":\"source\",\"type\":\"string\"},{\"internalType\":\"bytes\",\"name\":\"encryptedSecretsReferences\",\"type\":\"bytes\"},{\"internalType\":\"string[]\",\"name\":\"args\",\"type\":\"string[]\"},{\"internalType\":\"uint64\",\"name\":\"subscriptionId\",\"type\":\"uint64\"},{\"internalType\":\"bytes32\",\"name\":\"jobId\",\"type\":\"bytes32\"}],\"name\":\"sendRequest\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"},{\"inputs\":[{\"internalType\":\"address\",\"name\":\"to\",\"type\":\"address\"}],\"name\":\"transferOwnership\",\"outputs\":[],\"stateMutability\":\"nonpayable\",\"type\":\"function\"}]", + Bin: "0x60a06040523480156200001157600080fd5b5060405162001a3d38038062001a3d833981016040819052620000349162000180565b6001600160a01b0381166080523380600081620000985760405162461bcd60e51b815260206004820152601860248201527f43616e6e6f7420736574206f776e657220746f207a65726f000000000000000060448201526064015b60405180910390fd5b600080546001600160a01b0319166001600160a01b0384811691909117909155811615620000cb57620000cb81620000d5565b50505050620001b2565b336001600160a01b038216036200012f5760405162461bcd60e51b815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016200008f565b600180546001600160a01b0319166001600160a01b0383811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b6000602082840312156200019357600080fd5b81516001600160a01b0381168114620001ab57600080fd5b9392505050565b608051611868620001d5600039600081816101c601526109f101526118686000f3fe608060405234801561001057600080fd5b50600436106100c95760003560e01c80636d9809a011610081578063b1e217491161005b578063b1e2174914610182578063f2fde38b1461018b578063f7b4c06f1461019e57600080fd5b80636d9809a01461014857806379ba5097146101525780638da5cb5b1461015a57600080fd5b806342748b2a116100b257806342748b2a146100ff5780634b0795a81461012c5780635fa353e71461013557600080fd5b80630ca76175146100ce5780633944ea3a146100e3575b600080fd5b6100e16100dc3660046112b4565b6101ae565b005b6100ec60035481565b6040519081526020015b60405180910390f35b60055461011790640100000000900463ffffffff1681565b60405163ffffffff90911681526020016100f6565b6100ec60045481565b6100e1610143366004611387565b61022d565b6101176201117081565b6100e1610347565b60005460405173ffffffffffffffffffffffffffffffffffffffff90911681526020016100f6565b6100ec60025481565b6100e161019936600461146b565b610449565b6005546101179063ffffffff1681565b3373ffffffffffffffffffffffffffffffffffffffff7f0000000000000000000000000000000000000000000000000000000000000000161461021d576040517fc6829f8300000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b61022883838361045d565b505050565b6102356104f2565b61027e6040805161010081019091528060008152602001600081526020016000815260200160608152602001606081526020016060815260200160608152602001606081525090565b6102c089898080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105759050565b85156103085761030887878080601f01602080910402602001604051908101604052809392919081815260200183838082843760009201919091525085939250506105869050565b83156103225761032261031b85876114a1565b82906105d0565b61033961032e82610613565b8462011170856109ec565b600255505050505050505050565b60015473ffffffffffffffffffffffffffffffffffffffff1633146103cd576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4d7573742062652070726f706f736564206f776e65720000000000000000000060448201526064015b60405180910390fd5b60008054337fffffffffffffffffffffffff00000000000000000000000000000000000000008083168217845560018054909116905560405173ffffffffffffffffffffffffffffffffffffffff90921692909183917f8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e091a350565b6104516104f2565b61045a81610acb565b50565b600283905561046b82610bc0565b6003558151600580547fffffffffffffffffffffffffffffffffffffffffffffffffffffffff000000001663ffffffff9092169190911790556104ad81610bc0565b600455516005805463ffffffff909216640100000000027fffffffffffffffffffffffffffffffffffffffffffffffff00000000ffffffff9092169190911790555050565b60005473ffffffffffffffffffffffffffffffffffffffff163314610573576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601660248201527f4f6e6c792063616c6c61626c65206279206f776e65720000000000000000000060448201526064016103c4565b565b6105828260008084610c42565b5050565b80516000036105c1576040517fe889636f00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60016020830152608090910152565b805160000361060b576040517ffe936cb700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60c090910152565b60606000610622610100610cd9565b905061066c6040518060400160405280600c81526020017f636f64654c6f636174696f6e000000000000000000000000000000000000000081525082610cfa90919063ffffffff16565b825161068a90600281111561068357610683611539565b8290610d13565b60408051808201909152600881527f6c616e677561676500000000000000000000000000000000000000000000000060208201526106c9908290610cfa565b60408301516106e090801561068357610683611539565b60408051808201909152600681527f736f757263650000000000000000000000000000000000000000000000000000602082015261071f908290610cfa565b606083015161072f908290610cfa565b60a083015151156107895760408051808201909152601081527f726571756573745369676e6174757265000000000000000000000000000000006020820152610779908290610cfa565b60a0830151610789908290610d48565b60c083015151156108365760408051808201909152600481527f617267730000000000000000000000000000000000000000000000000000000060208201526107d3908290610cfa565b6107dc81610d55565b60005b8360c001515181101561082c5761081c8460c00151828151811061080557610805611568565b602002602001015183610cfa90919063ffffffff16565b610825816115c6565b90506107df565b5061083681610d79565b608083015151156109375760008360200151600281111561085957610859611539565b03610890576040517fa80d31f700000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b60408051808201909152600f81527f736563726574734c6f636174696f6e000000000000000000000000000000000060208201526108cf908290610cfa565b6108e88360200151600281111561068357610683611539565b60408051808201909152600781527f73656372657473000000000000000000000000000000000000000000000000006020820152610927908290610cfa565b6080830151610937908290610d48565b60e083015151156109e45760408051808201909152600981527f62797465734172677300000000000000000000000000000000000000000000006020820152610981908290610cfa565b61098a81610d55565b60005b8360e00151518110156109da576109ca8460e0015182815181106109b3576109b3611568565b602002602001015183610d4890919063ffffffff16565b6109d3816115c6565b905061098d565b506109e481610d79565b515192915050565b6000807f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff1663461d27628688600188886040518663ffffffff1660e01b8152600401610a519594939291906115fe565b6020604051808303816000875af1158015610a70573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610a94919061169e565b60405190915081907f1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db890600090a295945050505050565b3373ffffffffffffffffffffffffffffffffffffffff821603610b4a576040517f08c379a000000000000000000000000000000000000000000000000000000000815260206004820152601760248201527f43616e6e6f74207472616e7366657220746f2073656c6600000000000000000060448201526064016103c4565b600180547fffffffffffffffffffffffff00000000000000000000000000000000000000001673ffffffffffffffffffffffffffffffffffffffff83811691821790925560008054604051929316917fed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae12789190a350565b60008060209050602083511015610bd5575081515b60005b81811015610c3b57610beb8160086116b7565b848281518110610bfd57610bfd611568565b01602001517fff0000000000000000000000000000000000000000000000000000000000000016901c9290921791610c34816115c6565b9050610bd8565b5050919050565b8051600003610c7d576040517f22ce3edd00000000000000000000000000000000000000000000000000000000815260040160405180910390fd5b83836002811115610c9057610c90611539565b90816002811115610ca357610ca3611539565b90525060408401828015610cb957610cb9611539565b90818015610cc957610cc9611539565b9052506060909301929092525050565b610ce161116b565b8051610ced9083610d97565b5060006020820152919050565b610d078260038351610e11565b81516102289082610f38565b8151610d209060c2610f60565b506105828282604051602001610d3891815260200190565b6040516020818303038152906040525b610d078260028351610e11565b610d60816004610fc9565b600181602001818151610d7391906116ce565b90525050565b610d84816007610fc9565b600181602001818151610d7391906116e1565b604080518082019091526060815260006020820152610db76020836116f4565b15610ddf57610dc76020836116f4565b610dd29060206116e1565b610ddc90836116ce565b91505b602080840183905260405180855260008152908184010181811015610e0357600080fd5b604052508290505b92915050565b60178167ffffffffffffffff1611610e3e578251610e389060e0600585901b168317610f60565b50505050565b60ff8167ffffffffffffffff1611610e80578251610e67906018611fe0600586901b1617610f60565b508251610e389067ffffffffffffffff83166001610fe0565b61ffff8167ffffffffffffffff1611610ec3578251610eaa906019611fe0600586901b1617610f60565b508251610e389067ffffffffffffffff83166002610fe0565b63ffffffff8167ffffffffffffffff1611610f08578251610eef90601a611fe0600586901b1617610f60565b508251610e389067ffffffffffffffff83166004610fe0565b8251610f1f90601b611fe0600586901b1617610f60565b508251610e389067ffffffffffffffff83166008610fe0565b604080518082019091526060815260006020820152610f5983838451611065565b9392505050565b6040805180820190915260608152600060208201528251516000610f858260016116ce565b905084602001518210610fa657610fa685610fa18360026116b7565b611154565b8451602083820101858153508051821115610fbf578181525b5093949350505050565b815161022890601f611fe0600585901b1617610f60565b604080518082019091526060815260006020820152835151600061100482856116ce565b905085602001518111156110215761102186610fa18360026116b7565b600060016110318661010061184f565b61103b91906116e1565b90508651828101878319825116178152508051831115611059578281525b50959695505050505050565b604080518082019091526060815260006020820152825182111561108857600080fd5b835151600061109784836116ce565b905085602001518111156110b4576110b486610fa18360026116b7565b8551805183820160200191600091808511156110ce578482525b505050602086015b6020861061110e57805182526110ed6020836116ce565b91506110fa6020826116ce565b90506111076020876116e1565b95506110d6565b5181517fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff60208890036101000a0190811690199190911617905250849150509392505050565b81516111608383610d97565b50610e388382610f38565b6040518060400160405280611193604051806040016040528060608152602001600081525090565b8152602001600081525090565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052604160045260246000fd5b604051601f82017fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe016810167ffffffffffffffff81118282101715611216576112166111a0565b604052919050565b600067ffffffffffffffff831115611238576112386111a0565b61126960207fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f860116016111cf565b905082815283838301111561127d57600080fd5b828260208301376000602084830101529392505050565b600082601f8301126112a557600080fd5b610f598383356020850161121e565b6000806000606084860312156112c957600080fd5b83359250602084013567ffffffffffffffff808211156112e857600080fd5b6112f487838801611294565b9350604086013591508082111561130a57600080fd5b5061131786828701611294565b9150509250925092565b60008083601f84011261133357600080fd5b50813567ffffffffffffffff81111561134b57600080fd5b60208301915083602082850101111561136357600080fd5b9250929050565b803567ffffffffffffffff8116811461138257600080fd5b919050565b60008060008060008060008060a0898b0312156113a357600080fd5b883567ffffffffffffffff808211156113bb57600080fd5b6113c78c838d01611321565b909a50985060208b01359150808211156113e057600080fd5b6113ec8c838d01611321565b909850965060408b013591508082111561140557600080fd5b818b0191508b601f83011261141957600080fd5b81358181111561142857600080fd5b8c60208260051b850101111561143d57600080fd5b60208301965080955050505061145560608a0161136a565b9150608089013590509295985092959890939650565b60006020828403121561147d57600080fd5b813573ffffffffffffffffffffffffffffffffffffffff81168114610f5957600080fd5b600067ffffffffffffffff808411156114bc576114bc6111a0565b8360051b60206114cd8183016111cf565b8681529185019181810190368411156114e557600080fd5b865b8481101561152d578035868111156114ff5760008081fd5b880136601f8201126115115760008081fd5b61151f36823587840161121e565b8452509183019183016114e7565b50979650505050505050565b7f4e487b7100000000000000000000000000000000000000000000000000000000600052602160045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052603260045260246000fd5b7f4e487b7100000000000000000000000000000000000000000000000000000000600052601160045260246000fd5b60007fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff82036115f7576115f7611597565b5060010190565b67ffffffffffffffff861681526000602060a08184015286518060a085015260005b8181101561163c5788810183015185820160c001528201611620565b50600060c0828601015260c07fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe0601f83011685010192505050611685604083018661ffff169052565b63ffffffff939093166060820152608001529392505050565b6000602082840312156116b057600080fd5b5051919050565b8082028115828204841417610e0b57610e0b611597565b80820180821115610e0b57610e0b611597565b81810381811115610e0b57610e0b611597565b60008261172a577f4e487b7100000000000000000000000000000000000000000000000000000000600052601260045260246000fd5b500690565b600181815b8085111561178857817fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561176e5761176e611597565b8085161561177b57918102915b93841c9390800290611734565b509250929050565b60008261179f57506001610e0b565b816117ac57506000610e0b565b81600181146117c257600281146117cc576117e8565b6001915050610e0b565b60ff8411156117dd576117dd611597565b50506001821b610e0b565b5060208310610133831016604e8410600b841016171561180b575081810a610e0b565b611815838361172f565b807fffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff0482111561184757611847611597565b029392505050565b6000610f59838361179056fea164736f6c6343000813000a", +} + +var FunctionsLoadTestClientABI = FunctionsLoadTestClientMetaData.ABI + +var FunctionsLoadTestClientBin = FunctionsLoadTestClientMetaData.Bin + +func DeployFunctionsLoadTestClient(auth *bind.TransactOpts, backend bind.ContractBackend, router common.Address) (common.Address, *types.Transaction, *FunctionsLoadTestClient, error) { + parsed, err := FunctionsLoadTestClientMetaData.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(FunctionsLoadTestClientBin), backend, router) + if err != nil { + return common.Address{}, nil, nil, err + } + return address, tx, &FunctionsLoadTestClient{FunctionsLoadTestClientCaller: FunctionsLoadTestClientCaller{contract: contract}, FunctionsLoadTestClientTransactor: FunctionsLoadTestClientTransactor{contract: contract}, FunctionsLoadTestClientFilterer: FunctionsLoadTestClientFilterer{contract: contract}}, nil +} + +type FunctionsLoadTestClient struct { + address common.Address + abi abi.ABI + FunctionsLoadTestClientCaller + FunctionsLoadTestClientTransactor + FunctionsLoadTestClientFilterer +} + +type FunctionsLoadTestClientCaller struct { + contract *bind.BoundContract +} + +type FunctionsLoadTestClientTransactor struct { + contract *bind.BoundContract +} + +type FunctionsLoadTestClientFilterer struct { + contract *bind.BoundContract +} + +type FunctionsLoadTestClientSession struct { + Contract *FunctionsLoadTestClient + CallOpts bind.CallOpts + TransactOpts bind.TransactOpts +} + +type FunctionsLoadTestClientCallerSession struct { + Contract *FunctionsLoadTestClientCaller + CallOpts bind.CallOpts +} + +type FunctionsLoadTestClientTransactorSession struct { + Contract *FunctionsLoadTestClientTransactor + TransactOpts bind.TransactOpts +} + +type FunctionsLoadTestClientRaw struct { + Contract *FunctionsLoadTestClient +} + +type FunctionsLoadTestClientCallerRaw struct { + Contract *FunctionsLoadTestClientCaller +} + +type FunctionsLoadTestClientTransactorRaw struct { + Contract *FunctionsLoadTestClientTransactor +} + +func NewFunctionsLoadTestClient(address common.Address, backend bind.ContractBackend) (*FunctionsLoadTestClient, error) { + abi, err := abi.JSON(strings.NewReader(FunctionsLoadTestClientABI)) + if err != nil { + return nil, err + } + contract, err := bindFunctionsLoadTestClient(address, backend, backend, backend) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClient{address: address, abi: abi, FunctionsLoadTestClientCaller: FunctionsLoadTestClientCaller{contract: contract}, FunctionsLoadTestClientTransactor: FunctionsLoadTestClientTransactor{contract: contract}, FunctionsLoadTestClientFilterer: FunctionsLoadTestClientFilterer{contract: contract}}, nil +} + +func NewFunctionsLoadTestClientCaller(address common.Address, caller bind.ContractCaller) (*FunctionsLoadTestClientCaller, error) { + contract, err := bindFunctionsLoadTestClient(address, caller, nil, nil) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientCaller{contract: contract}, nil +} + +func NewFunctionsLoadTestClientTransactor(address common.Address, transactor bind.ContractTransactor) (*FunctionsLoadTestClientTransactor, error) { + contract, err := bindFunctionsLoadTestClient(address, nil, transactor, nil) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientTransactor{contract: contract}, nil +} + +func NewFunctionsLoadTestClientFilterer(address common.Address, filterer bind.ContractFilterer) (*FunctionsLoadTestClientFilterer, error) { + contract, err := bindFunctionsLoadTestClient(address, nil, nil, filterer) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientFilterer{contract: contract}, nil +} + +func bindFunctionsLoadTestClient(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { + parsed, err := FunctionsLoadTestClientMetaData.GetAbi() + if err != nil { + return nil, err + } + return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _FunctionsLoadTestClient.Contract.FunctionsLoadTestClientCaller.contract.Call(opts, result, method, params...) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.FunctionsLoadTestClientTransactor.contract.Transfer(opts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.FunctionsLoadTestClientTransactor.contract.Transact(opts, method, params...) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { + return _FunctionsLoadTestClient.Contract.contract.Call(opts, result, method, params...) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.contract.Transfer(opts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.contract.Transact(opts, method, params...) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) MAXCALLBACKGAS(opts *bind.CallOpts) (uint32, error) { + var out []interface{} + err := _FunctionsLoadTestClient.contract.Call(opts, &out, "MAX_CALLBACK_GAS") + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) MAXCALLBACKGAS() (uint32, error) { + return _FunctionsLoadTestClient.Contract.MAXCALLBACKGAS(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) MAXCALLBACKGAS() (uint32, error) { + return _FunctionsLoadTestClient.Contract.MAXCALLBACKGAS(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) Owner(opts *bind.CallOpts) (common.Address, error) { + var out []interface{} + err := _FunctionsLoadTestClient.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 (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) Owner() (common.Address, error) { + return _FunctionsLoadTestClient.Contract.Owner(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) Owner() (common.Address, error) { + return _FunctionsLoadTestClient.Contract.Owner(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) SLastError(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _FunctionsLoadTestClient.contract.Call(opts, &out, "s_lastError") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) SLastError() ([32]byte, error) { + return _FunctionsLoadTestClient.Contract.SLastError(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) SLastError() ([32]byte, error) { + return _FunctionsLoadTestClient.Contract.SLastError(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) SLastErrorLength(opts *bind.CallOpts) (uint32, error) { + var out []interface{} + err := _FunctionsLoadTestClient.contract.Call(opts, &out, "s_lastErrorLength") + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) SLastErrorLength() (uint32, error) { + return _FunctionsLoadTestClient.Contract.SLastErrorLength(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) SLastErrorLength() (uint32, error) { + return _FunctionsLoadTestClient.Contract.SLastErrorLength(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) SLastRequestId(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _FunctionsLoadTestClient.contract.Call(opts, &out, "s_lastRequestId") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) SLastRequestId() ([32]byte, error) { + return _FunctionsLoadTestClient.Contract.SLastRequestId(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) SLastRequestId() ([32]byte, error) { + return _FunctionsLoadTestClient.Contract.SLastRequestId(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) SLastResponse(opts *bind.CallOpts) ([32]byte, error) { + var out []interface{} + err := _FunctionsLoadTestClient.contract.Call(opts, &out, "s_lastResponse") + + if err != nil { + return *new([32]byte), err + } + + out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) + + return out0, err + +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) SLastResponse() ([32]byte, error) { + return _FunctionsLoadTestClient.Contract.SLastResponse(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) SLastResponse() ([32]byte, error) { + return _FunctionsLoadTestClient.Contract.SLastResponse(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCaller) SLastResponseLength(opts *bind.CallOpts) (uint32, error) { + var out []interface{} + err := _FunctionsLoadTestClient.contract.Call(opts, &out, "s_lastResponseLength") + + if err != nil { + return *new(uint32), err + } + + out0 := *abi.ConvertType(out[0], new(uint32)).(*uint32) + + return out0, err + +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) SLastResponseLength() (uint32, error) { + return _FunctionsLoadTestClient.Contract.SLastResponseLength(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientCallerSession) SLastResponseLength() (uint32, error) { + return _FunctionsLoadTestClient.Contract.SLastResponseLength(&_FunctionsLoadTestClient.CallOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactor) AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { + return _FunctionsLoadTestClient.contract.Transact(opts, "acceptOwnership") +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) AcceptOwnership() (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.AcceptOwnership(&_FunctionsLoadTestClient.TransactOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactorSession) AcceptOwnership() (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.AcceptOwnership(&_FunctionsLoadTestClient.TransactOpts) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactor) HandleOracleFulfillment(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { + return _FunctionsLoadTestClient.contract.Transact(opts, "handleOracleFulfillment", requestId, response, err) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) HandleOracleFulfillment(requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.HandleOracleFulfillment(&_FunctionsLoadTestClient.TransactOpts, requestId, response, err) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactorSession) HandleOracleFulfillment(requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.HandleOracleFulfillment(&_FunctionsLoadTestClient.TransactOpts, requestId, response, err) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactor) SendRequest(opts *bind.TransactOpts, source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) { + return _FunctionsLoadTestClient.contract.Transact(opts, "sendRequest", source, encryptedSecretsReferences, args, subscriptionId, jobId) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) SendRequest(source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.SendRequest(&_FunctionsLoadTestClient.TransactOpts, source, encryptedSecretsReferences, args, subscriptionId, jobId) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactorSession) SendRequest(source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.SendRequest(&_FunctionsLoadTestClient.TransactOpts, source, encryptedSecretsReferences, args, subscriptionId, jobId) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactor) TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) { + return _FunctionsLoadTestClient.contract.Transact(opts, "transferOwnership", to) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.TransferOwnership(&_FunctionsLoadTestClient.TransactOpts, to) +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientTransactorSession) TransferOwnership(to common.Address) (*types.Transaction, error) { + return _FunctionsLoadTestClient.Contract.TransferOwnership(&_FunctionsLoadTestClient.TransactOpts, to) +} + +type FunctionsLoadTestClientOwnershipTransferRequestedIterator struct { + Event *FunctionsLoadTestClientOwnershipTransferRequested + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsLoadTestClientOwnershipTransferRequestedIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsLoadTestClientOwnershipTransferRequested) + 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(FunctionsLoadTestClientOwnershipTransferRequested) + 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 *FunctionsLoadTestClientOwnershipTransferRequestedIterator) Error() error { + return it.fail +} + +func (it *FunctionsLoadTestClientOwnershipTransferRequestedIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsLoadTestClientOwnershipTransferRequested struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsLoadTestClientOwnershipTransferRequestedIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.FilterLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientOwnershipTransferRequestedIterator{contract: _FunctionsLoadTestClient.contract, event: "OwnershipTransferRequested", logs: logs, sub: sub}, nil +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.WatchLogs(opts, "OwnershipTransferRequested", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsLoadTestClientOwnershipTransferRequested) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "OwnershipTransferRequested", 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 (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) ParseOwnershipTransferRequested(log types.Log) (*FunctionsLoadTestClientOwnershipTransferRequested, error) { + event := new(FunctionsLoadTestClientOwnershipTransferRequested) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "OwnershipTransferRequested", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FunctionsLoadTestClientOwnershipTransferredIterator struct { + Event *FunctionsLoadTestClientOwnershipTransferred + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsLoadTestClientOwnershipTransferredIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsLoadTestClientOwnershipTransferred) + 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(FunctionsLoadTestClientOwnershipTransferred) + 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 *FunctionsLoadTestClientOwnershipTransferredIterator) Error() error { + return it.fail +} + +func (it *FunctionsLoadTestClientOwnershipTransferredIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsLoadTestClientOwnershipTransferred struct { + From common.Address + To common.Address + Raw types.Log +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsLoadTestClientOwnershipTransferredIterator, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.FilterLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientOwnershipTransferredIterator{contract: _FunctionsLoadTestClient.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) { + + var fromRule []interface{} + for _, fromItem := range from { + fromRule = append(fromRule, fromItem) + } + var toRule []interface{} + for _, toItem := range to { + toRule = append(toRule, toItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.WatchLogs(opts, "OwnershipTransferred", fromRule, toRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsLoadTestClientOwnershipTransferred) + if err := _FunctionsLoadTestClient.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 (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) ParseOwnershipTransferred(log types.Log) (*FunctionsLoadTestClientOwnershipTransferred, error) { + event := new(FunctionsLoadTestClientOwnershipTransferred) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FunctionsLoadTestClientRequestFulfilledIterator struct { + Event *FunctionsLoadTestClientRequestFulfilled + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsLoadTestClientRequestFulfilledIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsLoadTestClientRequestFulfilled) + 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(FunctionsLoadTestClientRequestFulfilled) + 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 *FunctionsLoadTestClientRequestFulfilledIterator) Error() error { + return it.fail +} + +func (it *FunctionsLoadTestClientRequestFulfilledIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsLoadTestClientRequestFulfilled struct { + Id [32]byte + Raw types.Log +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) FilterRequestFulfilled(opts *bind.FilterOpts, id [][32]byte) (*FunctionsLoadTestClientRequestFulfilledIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.FilterLogs(opts, "RequestFulfilled", idRule) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientRequestFulfilledIterator{contract: _FunctionsLoadTestClient.contract, event: "RequestFulfilled", logs: logs, sub: sub}, nil +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) WatchRequestFulfilled(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientRequestFulfilled, id [][32]byte) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.WatchLogs(opts, "RequestFulfilled", idRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsLoadTestClientRequestFulfilled) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "RequestFulfilled", 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 (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) ParseRequestFulfilled(log types.Log) (*FunctionsLoadTestClientRequestFulfilled, error) { + event := new(FunctionsLoadTestClientRequestFulfilled) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "RequestFulfilled", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +type FunctionsLoadTestClientRequestSentIterator struct { + Event *FunctionsLoadTestClientRequestSent + + contract *bind.BoundContract + event string + + logs chan types.Log + sub ethereum.Subscription + done bool + fail error +} + +func (it *FunctionsLoadTestClientRequestSentIterator) Next() bool { + + if it.fail != nil { + return false + } + + if it.done { + select { + case log := <-it.logs: + it.Event = new(FunctionsLoadTestClientRequestSent) + 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(FunctionsLoadTestClientRequestSent) + 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 *FunctionsLoadTestClientRequestSentIterator) Error() error { + return it.fail +} + +func (it *FunctionsLoadTestClientRequestSentIterator) Close() error { + it.sub.Unsubscribe() + return nil +} + +type FunctionsLoadTestClientRequestSent struct { + Id [32]byte + Raw types.Log +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) FilterRequestSent(opts *bind.FilterOpts, id [][32]byte) (*FunctionsLoadTestClientRequestSentIterator, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.FilterLogs(opts, "RequestSent", idRule) + if err != nil { + return nil, err + } + return &FunctionsLoadTestClientRequestSentIterator{contract: _FunctionsLoadTestClient.contract, event: "RequestSent", logs: logs, sub: sub}, nil +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) WatchRequestSent(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientRequestSent, id [][32]byte) (event.Subscription, error) { + + var idRule []interface{} + for _, idItem := range id { + idRule = append(idRule, idItem) + } + + logs, sub, err := _FunctionsLoadTestClient.contract.WatchLogs(opts, "RequestSent", idRule) + if err != nil { + return nil, err + } + return event.NewSubscription(func(quit <-chan struct{}) error { + defer sub.Unsubscribe() + for { + select { + case log := <-logs: + + event := new(FunctionsLoadTestClientRequestSent) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "RequestSent", 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 (_FunctionsLoadTestClient *FunctionsLoadTestClientFilterer) ParseRequestSent(log types.Log) (*FunctionsLoadTestClientRequestSent, error) { + event := new(FunctionsLoadTestClientRequestSent) + if err := _FunctionsLoadTestClient.contract.UnpackLog(event, "RequestSent", log); err != nil { + return nil, err + } + event.Raw = log + return event, nil +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClient) ParseLog(log types.Log) (generated.AbigenLog, error) { + switch log.Topics[0] { + case _FunctionsLoadTestClient.abi.Events["OwnershipTransferRequested"].ID: + return _FunctionsLoadTestClient.ParseOwnershipTransferRequested(log) + case _FunctionsLoadTestClient.abi.Events["OwnershipTransferred"].ID: + return _FunctionsLoadTestClient.ParseOwnershipTransferred(log) + case _FunctionsLoadTestClient.abi.Events["RequestFulfilled"].ID: + return _FunctionsLoadTestClient.ParseRequestFulfilled(log) + case _FunctionsLoadTestClient.abi.Events["RequestSent"].ID: + return _FunctionsLoadTestClient.ParseRequestSent(log) + + default: + return nil, fmt.Errorf("abigen wrapper received unknown log topic: %v", log.Topics[0]) + } +} + +func (FunctionsLoadTestClientOwnershipTransferRequested) Topic() common.Hash { + return common.HexToHash("0xed8889f560326eb138920d842192f0eb3dd22b4f139c87a2c57538e05bae1278") +} + +func (FunctionsLoadTestClientOwnershipTransferred) Topic() common.Hash { + return common.HexToHash("0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0") +} + +func (FunctionsLoadTestClientRequestFulfilled) Topic() common.Hash { + return common.HexToHash("0x85e1543bf2f84fe80c6badbce3648c8539ad1df4d2b3d822938ca0538be727e6") +} + +func (FunctionsLoadTestClientRequestSent) Topic() common.Hash { + return common.HexToHash("0x1131472297a800fee664d1d89cfa8f7676ff07189ecc53f80bbb5f4969099db8") +} + +func (_FunctionsLoadTestClient *FunctionsLoadTestClient) Address() common.Address { + return _FunctionsLoadTestClient.address +} + +type FunctionsLoadTestClientInterface interface { + MAXCALLBACKGAS(opts *bind.CallOpts) (uint32, error) + + Owner(opts *bind.CallOpts) (common.Address, error) + + SLastError(opts *bind.CallOpts) ([32]byte, error) + + SLastErrorLength(opts *bind.CallOpts) (uint32, error) + + SLastRequestId(opts *bind.CallOpts) ([32]byte, error) + + SLastResponse(opts *bind.CallOpts) ([32]byte, error) + + SLastResponseLength(opts *bind.CallOpts) (uint32, error) + + AcceptOwnership(opts *bind.TransactOpts) (*types.Transaction, error) + + HandleOracleFulfillment(opts *bind.TransactOpts, requestId [32]byte, response []byte, err []byte) (*types.Transaction, error) + + SendRequest(opts *bind.TransactOpts, source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) (*types.Transaction, error) + + TransferOwnership(opts *bind.TransactOpts, to common.Address) (*types.Transaction, error) + + FilterOwnershipTransferRequested(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsLoadTestClientOwnershipTransferRequestedIterator, error) + + WatchOwnershipTransferRequested(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientOwnershipTransferRequested, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferRequested(log types.Log) (*FunctionsLoadTestClientOwnershipTransferRequested, error) + + FilterOwnershipTransferred(opts *bind.FilterOpts, from []common.Address, to []common.Address) (*FunctionsLoadTestClientOwnershipTransferredIterator, error) + + WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientOwnershipTransferred, from []common.Address, to []common.Address) (event.Subscription, error) + + ParseOwnershipTransferred(log types.Log) (*FunctionsLoadTestClientOwnershipTransferred, error) + + FilterRequestFulfilled(opts *bind.FilterOpts, id [][32]byte) (*FunctionsLoadTestClientRequestFulfilledIterator, error) + + WatchRequestFulfilled(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientRequestFulfilled, id [][32]byte) (event.Subscription, error) + + ParseRequestFulfilled(log types.Log) (*FunctionsLoadTestClientRequestFulfilled, error) + + FilterRequestSent(opts *bind.FilterOpts, id [][32]byte) (*FunctionsLoadTestClientRequestSentIterator, error) + + WatchRequestSent(opts *bind.WatchOpts, sink chan<- *FunctionsLoadTestClientRequestSent, id [][32]byte) (event.Subscription, error) + + ParseRequestSent(log types.Log) (*FunctionsLoadTestClientRequestSent, error) + + ParseLog(log types.Log) (generated.AbigenLog, error) + + Address() common.Address +} diff --git a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt index 8c467632fc1..0fb2b611b4d 100644 --- a/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt +++ b/core/gethwrappers/functions/generation/generated-wrapper-dependency-versions-do-not-edit.txt @@ -5,6 +5,7 @@ functions_billing_registry_events_mock: ../../../contracts/solc/v0.8.6/functions functions_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin 2368f537a04489c720a46733f8596c4fc88a31062ecfa966d05f25dd98608aca functions_client_example: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin 25036bdb94a50a81df4222418bf9aa1e0c8540d5834b7e6e639aa63a2a2c8206 functions_coordinator: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin 7b2fb23e2f49121dfe4b096de5e60fe57be0a196c2423a4693293c23c96f9af4 +functions_load_test_client: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsLoadTestClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsLoadTestClient.bin 28f2834dea12b3aefa7c696b64ca5272a1ab5cdf33365c9f7fafdc0b7d5669e8 functions_oracle_events_mock: ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/FunctionsOracleEventsMock.bin 3ca70f966f8fe751987f0ccb50bebb6aa5be77e4a9f835d1ae99e0e9bfb7d52c functions_router: ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin dd1d3527e19d65efe029c4a131ded44dc0ca961e5c4f459743992435431ec478 ocr2dr: ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.abi ../../../contracts/solc/v0.8.6/functions/0_0_0/Functions.bin d9a794b33f47cc57563d216f7cf3a612309fc3062356a27e30005cf1d59e449d diff --git a/core/gethwrappers/functions/go_generate.go b/core/gethwrappers/functions/go_generate.go index 04ea0bff283..bc0fcd2a0ce 100644 --- a/core/gethwrappers/functions/go_generate.go +++ b/core/gethwrappers/functions/go_generate.go @@ -15,6 +15,7 @@ package gethwrappers //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRequest.bin Functions functions //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClient.bin FunctionsClient functions_client //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsClientExample.bin FunctionsClientExample functions_client_example +//go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsLoadTestClient.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsLoadTestClient.bin FunctionsLoadTestClient functions_load_test_client //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsCoordinator.bin FunctionsCoordinator functions_coordinator //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/FunctionsRouter.bin FunctionsRouter functions_router //go:generate go run ../generation/generate/wrap.go ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.abi ../../../contracts/solc/v0.8.19/functions/1_0_0/TermsOfServiceAllowList.bin TermsOfServiceAllowList functions_allow_list diff --git a/integration-tests/contracts/contract_deployer.go b/integration-tests/contracts/contract_deployer.go index 3555caebad7..578ca1ea549 100644 --- a/integration-tests/contracts/contract_deployer.go +++ b/integration-tests/contracts/contract_deployer.go @@ -16,6 +16,7 @@ import ( ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_load_test_client" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_consumer_benchmark" automationForwarderLogic "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_forwarder_logic" registrar21 "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/automation_registrar_wrapper2_1" @@ -97,6 +98,7 @@ type ContractDeployer interface { DeployOperatorFactory(linkAddr string) (OperatorFactory, error) DeployStaking(params eth_contracts.StakingPoolConstructorParams) (Staking, error) DeployBatchBlockhashStore(blockhashStoreAddr string) (BatchBlockhashStore, error) + DeployFunctionsLoadTestClient(router string) (FunctionsLoadTestClient, error) DeployFunctionsOracleEventsMock() (FunctionsOracleEventsMock, error) DeployFunctionsBillingRegistryEventsMock() (FunctionsBillingRegistryEventsMock, error) DeployStakingEventsMock() (StakingEventsMock, error) @@ -276,6 +278,23 @@ func (e *EthereumContractDeployer) DeployStaking(params eth_contracts.StakingPoo }, nil } +func (e *EthereumContractDeployer) DeployFunctionsLoadTestClient(router string) (FunctionsLoadTestClient, error) { + address, _, instance, err := e.client.DeployContract("FunctionsLoadTestClient", func( + auth *bind.TransactOpts, + backend bind.ContractBackend, + ) (common.Address, *types.Transaction, interface{}, error) { + return functions_load_test_client.DeployFunctionsLoadTestClient(auth, backend, common.HexToAddress(router)) + }) + if err != nil { + return nil, err + } + return &EthereumFunctionsLoadTestClient{ + client: e.client, + instance: instance.(*functions_load_test_client.FunctionsLoadTestClient), + address: *address, + }, nil +} + func (e *EthereumContractDeployer) DeployFunctionsOracleEventsMock() (FunctionsOracleEventsMock, error) { address, _, instance, err := e.client.DeployContract("FunctionsOracleEventsMock", func( auth *bind.TransactOpts, diff --git a/integration-tests/contracts/contract_loader.go b/integration-tests/contracts/contract_loader.go index 14995296b8f..7517ef7ba7e 100644 --- a/integration-tests/contracts/contract_loader.go +++ b/integration-tests/contracts/contract_loader.go @@ -6,14 +6,24 @@ import ( "github.com/ethereum/go-ethereum/common" "github.com/smartcontractkit/chainlink-testing-framework/blockchain" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_load_test_client" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_router" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/authorized_forwarder" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/link_token_interface" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/operator_wrapper" ) // ContractLoader is an interface for abstracting the contract loading methods across network implementations type ContractLoader interface { + LoadLINKToken(address string) (LinkToken, error) LoadOperatorContract(address common.Address) (Operator, error) LoadAuthorizedForwarder(address common.Address) (AuthorizedForwarder, error) + + /* functions 1_0_0 */ + LoadFunctionsCoordinator(addr string) (FunctionsCoordinator, error) + LoadFunctionsRouter(addr string) (FunctionsRouter, error) + LoadFunctionsLoadTestClient(addr string) (FunctionsLoadTestClient, error) } // NewContractLoader returns an instance of a contract Loader based on the client type @@ -72,6 +82,78 @@ func NewEthereumContractLoader(ethClient blockchain.EVMClient) *EthereumContract } } +// LoadLINKToken returns deployed on given address LINK Token contract instance +func (e *EthereumContractLoader) LoadLINKToken(addr string) (LinkToken, error) { + instance, err := e.client.LoadContract("LINK Token", common.HexToAddress(addr), func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return link_token_interface.NewLinkToken(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumLinkToken{ + client: e.client, + instance: instance.(*link_token_interface.LinkToken), + address: common.HexToAddress(addr), + }, err +} + +// LoadFunctionsCoordinator returns deployed on given address FunctionsCoordinator contract instance +func (e *EthereumContractLoader) LoadFunctionsCoordinator(addr string) (FunctionsCoordinator, error) { + instance, err := e.client.LoadContract("Functions Coordinator", common.HexToAddress(addr), func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return functions_coordinator.NewFunctionsCoordinator(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumFunctionsCoordinator{ + client: e.client, + instance: instance.(*functions_coordinator.FunctionsCoordinator), + address: common.HexToAddress(addr), + }, err +} + +// LoadFunctionsRouter returns deployed on given address FunctionsRouter contract instance +func (e *EthereumContractLoader) LoadFunctionsRouter(addr string) (FunctionsRouter, error) { + instance, err := e.client.LoadContract("Functions Router", common.HexToAddress(addr), func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return functions_router.NewFunctionsRouter(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumFunctionsRouter{ + client: e.client, + instance: instance.(*functions_router.FunctionsRouter), + address: common.HexToAddress(addr), + }, err +} + +// LoadFunctionsLoadTestClient returns deployed on given address FunctionsLoadTestClient contract instance +func (e *EthereumContractLoader) LoadFunctionsLoadTestClient(addr string) (FunctionsLoadTestClient, error) { + instance, err := e.client.LoadContract("FunctionsLoadTestClient", common.HexToAddress(addr), func( + address common.Address, + backend bind.ContractBackend, + ) (interface{}, error) { + return functions_load_test_client.NewFunctionsLoadTestClient(address, backend) + }) + if err != nil { + return nil, err + } + return &EthereumFunctionsLoadTestClient{ + client: e.client, + instance: instance.(*functions_load_test_client.FunctionsLoadTestClient), + address: common.HexToAddress(addr), + }, err +} + // LoadOperatorContract returns deployed on given address Operator contract instance func (e *EthereumContractLoader) LoadOperatorContract(address common.Address) (Operator, error) { instance, err := e.client.LoadContract("Operator", address, func( diff --git a/integration-tests/contracts/contract_models.go b/integration-tests/contracts/contract_models.go index 9724c4cb3f6..9af61d7d880 100644 --- a/integration-tests/contracts/contract_models.go +++ b/integration-tests/contracts/contract_models.go @@ -333,3 +333,17 @@ type AuthorizedForwarder interface { Owner(ctx context.Context) (string, error) GetAuthorizedSenders(ctx context.Context) ([]string, error) } + +type FunctionsCoordinator interface { + Address() string +} + +type FunctionsRouter interface { + Address() string + CreateSubscriptionWithConsumer(consumer string) (uint64, error) +} + +type FunctionsLoadTestClient interface { + Address() string + SendRequest(source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) error +} diff --git a/integration-tests/contracts/ethereum_contracts.go b/integration-tests/contracts/ethereum_contracts.go index 1e933f1ee80..e419a02e578 100644 --- a/integration-tests/contracts/ethereum_contracts.go +++ b/integration-tests/contracts/ethereum_contracts.go @@ -18,8 +18,14 @@ import ( ocrConfigHelper "github.com/smartcontractkit/libocr/offchainreporting/confighelper" ocrTypes "github.com/smartcontractkit/libocr/offchainreporting/types" + "github.com/ethereum/go-ethereum/accounts/abi" + "github.com/pkg/errors" "github.com/smartcontractkit/chainlink/integration-tests/client" eth_contracts "github.com/smartcontractkit/chainlink/integration-tests/contracts/ethereum" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_client_example" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_coordinator" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_load_test_client" + "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/functions/generated/functions_router" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/authorized_forwarder" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flags_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/flux_aggregator_wrapper" @@ -37,6 +43,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/operator_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/oracle_wrapper" "github.com/smartcontractkit/chainlink/v2/core/gethwrappers/generated/test_api_consumer_wrapper" + "strings" ) // EthereumOracle oracle for "directrequest" job tests @@ -1930,3 +1937,92 @@ type EthereumKeeperRegistryCheckUpkeepGasUsageWrapper struct { func (e *EthereumKeeperRegistryCheckUpkeepGasUsageWrapper) Address() string { return e.address.Hex() } + +/* Functions 1_0_0 */ + +type EthereumFunctionsRouter struct { + address common.Address + client blockchain.EVMClient + instance *functions_router.FunctionsRouter +} + +func (e *EthereumFunctionsRouter) Address() string { + return e.address.Hex() +} + +func (e *EthereumFunctionsRouter) CreateSubscriptionWithConsumer(consumer string) (uint64, error) { + opts, err := e.client.TransactionOpts(e.client.GetDefaultWallet()) + if err != nil { + return 0, err + } + tx, err := e.instance.CreateSubscriptionWithConsumer(opts, common.HexToAddress(consumer)) + if err != nil { + return 0, err + } + if err := e.client.ProcessTransaction(tx); err != nil { + return 0, err + } + r, err := e.client.GetTxReceipt(tx.Hash()) + if err != nil { + return 0, err + } + for _, l := range r.Logs { + log.Warn().Interface("Log", common.Bytes2Hex(l.Data)).Send() + } + topicsMap := map[string]interface{}{} + + fabi, err := abi.JSON(strings.NewReader(functions_router.FunctionsRouterABI)) + if err != nil { + return 0, err + } + for _, ev := range fabi.Events { + log.Warn().Str("EventName", ev.Name).Send() + } + topicOneInputs := abi.Arguments{fabi.Events["SubscriptionCreated"].Inputs[0]} + topicOneHash := []common.Hash{r.Logs[0].Topics[1:][0]} + if err := abi.ParseTopicsIntoMap(topicsMap, topicOneInputs, topicOneHash); err != nil { + return 0, errors.Wrap(err, "failed to decode topic value") + } + log.Warn().Interface("NewTopicsDecoded", topicsMap).Send() + if topicsMap["subscriptionId"] == 0 { + return 0, errors.New("failed to decode subscription ID after creation") + } + return topicsMap["subscriptionId"].(uint64), nil +} + +type EthereumFunctionsCoordinator struct { + address common.Address + client blockchain.EVMClient + instance *functions_coordinator.FunctionsCoordinator +} + +func (e *EthereumFunctionsCoordinator) Address() string { + return e.address.Hex() +} + +type EthereumFunctionsLoadTestClient struct { + address common.Address + client blockchain.EVMClient + instance *functions_load_test_client.FunctionsLoadTestClient +} + +func (e *EthereumFunctionsLoadTestClient) Address() string { + return e.address.Hex() +} + +func (e *EthereumFunctionsLoadTestClient) SendRequest(source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) error { + opts, err := e.client.TransactionOpts(e.client.GetDefaultWallet()) + if err != nil { + return err + } + tx, err := e.instance.SendRequest(opts, source, encryptedSecretsReferences, args, subscriptionId, jobId) + if err != nil { + return err + } + if err := e.client.ProcessTransaction(tx); err != nil { + return err + } + revertReason, _, _ := e.client.RevertReasonFromTx(tx.Hash(), functions_client_example.FunctionsClientExampleABI) + log.Debug().Str("RevertReason", revertReason).Send() + return nil +} diff --git a/integration-tests/load/functions/README.md b/integration-tests/load/functions/README.md new file mode 100644 index 00000000000..ec94b9ded0a --- /dev/null +++ b/integration-tests/load/functions/README.md @@ -0,0 +1,22 @@ +### Functions Load tests + +## Usage +``` +export LOKI_TOKEN=... +export LOKI_URL=... + +go test -v -run TestFunctionsLoad/functions_soak_test +``` + +### Dashboards + +Deploying dashboard: +``` +export GRAFANA_URL=... +export GRAFANA_TOKEN=... +export DATA_SOURCE_NAME=... +export DASHBOARD_FOLDER=LoadTests +export DASHBOARD_NAME=FunctionsV1 + +go run dashboard.go +``` \ No newline at end of file diff --git a/integration-tests/load/functions/cmd/dashboard.go b/integration-tests/load/functions/cmd/dashboard.go new file mode 100644 index 00000000000..6414759e672 --- /dev/null +++ b/integration-tests/load/functions/cmd/dashboard.go @@ -0,0 +1,34 @@ +package main + +import ( + "github.com/K-Phoen/grabana/dashboard" + "github.com/K-Phoen/grabana/logs" + "github.com/K-Phoen/grabana/row" + "github.com/smartcontractkit/wasp" +) + +func main() { + lokiDS := "grafanacloud-logs" + d, err := wasp.NewDashboard(nil, + []dashboard.Option{ + dashboard.Row("DON logs (errors)", + row.Collapse(), + row.WithLogs( + "DON logs", + logs.DataSource(lokiDS), + logs.Span(12), + logs.Height("300px"), + logs.Transparent(), + logs.WithLokiTarget(` + { cluster="staging-us-west-2-main", app=~"clc-ocr2-dr-matic-testnet" } | json | level="error" + `), + )), + }, + ) + if err != nil { + panic(err) + } + if _, err := d.Deploy(); err != nil { + panic(err) + } +} diff --git a/integration-tests/load/functions/config.go b/integration-tests/load/functions/config.go new file mode 100644 index 00000000000..baba37d2c82 --- /dev/null +++ b/integration-tests/load/functions/config.go @@ -0,0 +1,80 @@ +package loadfunctions + +import ( + "github.com/pelletier/go-toml/v2" + "github.com/pkg/errors" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/v2/core/store/models" + "math/big" + "os" +) + +const ( + DefaultConfigFilename = "config.toml" + + ErrReadPerfConfig = "failed to read TOML config for performance tests" + ErrUnmarshalPerfConfig = "failed to unmarshal TOML config for performance tests" +) + +type PerformanceConfig struct { + Soak *Soak `toml:"Soak"` + Load *Load `toml:"Load"` + SoakVolume *SoakVolume `toml:"SoakVolume"` + LoadVolume *LoadVolume `toml:"LoadVolume"` + Common *Common `toml:"Common"` +} + +type Common struct { + Funding + LINKTokenAddr string `toml:"link_token_addr"` + Coordinator string `toml:"coordinator_addr"` + Router string `toml:"router_addr"` + LoadTestClient string `toml:"client_example_addr"` + SubscriptionID uint64 `toml:"subscription_id"` + DONID string `toml:"don_id"` +} + +type Funding struct { + NodeFunds *big.Float `toml:"node_funds"` + SubFunds *big.Int `toml:"sub_funds"` +} + +type Soak struct { + RPS int64 `toml:"rps"` + Duration *models.Duration `toml:"duration"` +} + +type SoakVolume struct { + Products int64 `toml:"products"` + Pace *models.Duration `toml:"pace"` + Duration *models.Duration `toml:"duration"` +} + +type Load struct { + RPSFrom int64 `toml:"rps_from"` + RPSIncrease int64 `toml:"rps_increase"` + RPSSteps int `toml:"rps_steps"` + Duration *models.Duration `toml:"duration"` +} + +type LoadVolume struct { + ProductsFrom int64 `toml:"products_from"` + ProductsIncrease int64 `toml:"products_increase"` + ProductsSteps int `toml:"products_steps"` + Pace *models.Duration `toml:"pace"` + Duration *models.Duration `toml:"duration"` +} + +func ReadConfig() (*PerformanceConfig, error) { + var cfg *PerformanceConfig + d, err := os.ReadFile(DefaultConfigFilename) + if err != nil { + return nil, errors.Wrap(err, ErrReadPerfConfig) + } + err = toml.Unmarshal(d, &cfg) + if err != nil { + return nil, errors.Wrap(err, ErrUnmarshalPerfConfig) + } + log.Debug().Interface("PerformanceConfig", cfg).Msg("Parsed performance config") + return cfg, nil +} diff --git a/integration-tests/load/functions/config.toml b/integration-tests/load/functions/config.toml new file mode 100644 index 00000000000..14cedcd9a5d --- /dev/null +++ b/integration-tests/load/functions/config.toml @@ -0,0 +1,34 @@ +[Soak] +rps = 1 +duration = "1h" + +[Load] +rps_from = 1 +rps_increase = 1 +rps_steps = 10 +duration = "3m" + +[SoakVolume] +products = 5 +pace = "1s" +duration = "3m" + +[LoadVolume] +products_from = 1 +products_increase = 1 +products_steps = 10 +pace = "1s" +duration = "3m" + +[Common] +# Polygon Mumbai only for now +link_token_addr = "0x326C977E6efc84E512bB9C30f76E30c160eD06FB" +coordinator_addr = "0x69b4C680209737B877c93327fC2144ec39eaC423" +router_addr = "0xa4Ac8b863A6b4fB064B6bdF87aD61d389d97748d" +client_example_addr = "0x2720cC3a112d33B5C1D40270f7c7BE7CADec1690" +don_id = "functions_staging_mumbai" +# comment it to automatically create and fund a new one +subscription_id = 48 +# not used until we have full DON setup +# node_funds = 10 +sub_funds = 7 \ No newline at end of file diff --git a/integration-tests/load/functions/functions_test.go b/integration-tests/load/functions/functions_test.go new file mode 100644 index 00000000000..656c3b80ec1 --- /dev/null +++ b/integration-tests/load/functions/functions_test.go @@ -0,0 +1,62 @@ +package loadfunctions + +import ( + "github.com/smartcontractkit/wasp" + "github.com/stretchr/testify/require" + "testing" + "time" +) + +func TestFunctionsLoad(t *testing.T) { + cfg, err := ReadConfig() + require.NoError(t, err) + env, functionContracts, err := SetupLocalLoadTestEnv(cfg) + require.NoError(t, err) + env.ParallelTransactions(true) + + labels := map[string]string{ + "branch": "functions_healthcheck", + "commit": "functions_healthcheck", + } + + singleFeedConfig := &wasp.Config{ + T: t, + LoadType: wasp.RPS, + GenName: "gun", + CallTimeout: 2 * time.Minute, + Gun: NewSingleFunctionCallGun( + functionContracts, + "const response = await Functions.makeHttpRequest({ url: 'http://dummyjson.com/products/1' }); return Functions.encodeUint256(response.data.id)", + []byte{}, + []string{}, + cfg.Common.SubscriptionID, + StringToByte32(cfg.Common.DONID), + ), + Labels: labels, + LokiConfig: wasp.NewEnvLokiConfig(), + } + + t.Run("functions soak test", func(t *testing.T) { + singleFeedConfig.Schedule = wasp.Plain( + cfg.Soak.RPS, + cfg.Soak.Duration.Duration(), + ) + _, err := wasp.NewProfile(). + Add(wasp.NewGenerator(singleFeedConfig)). + Run(true) + require.NoError(t, err) + }) + + t.Run("functions load test", func(t *testing.T) { + singleFeedConfig.Schedule = wasp.Steps( + cfg.Load.RPSFrom, + cfg.Load.RPSIncrease, + cfg.Load.RPSSteps, + cfg.Load.Duration.Duration(), + ) + _, err = wasp.NewProfile(). + Add(wasp.NewGenerator(singleFeedConfig)). + Run(true) + require.NoError(t, err) + }) +} diff --git a/integration-tests/load/functions/gun.go b/integration-tests/load/functions/gun.go new file mode 100644 index 00000000000..358e0acb986 --- /dev/null +++ b/integration-tests/load/functions/gun.go @@ -0,0 +1,36 @@ +package loadfunctions + +import ( + "github.com/smartcontractkit/wasp" +) + +/* SingleFunctionCallGun is a gun that constantly requests randomness for one feed */ + +type SingleFunctionCallGun struct { + contracts *Contracts + source string + encryptedSecretsReferences []byte + args []string + subscriptionId uint64 + jobId [32]byte +} + +func NewSingleFunctionCallGun(contracts *Contracts, source string, encryptedSecretsReferences []byte, args []string, subscriptionId uint64, jobId [32]byte) *SingleFunctionCallGun { + return &SingleFunctionCallGun{ + contracts: contracts, + source: source, + encryptedSecretsReferences: encryptedSecretsReferences, + args: args, + subscriptionId: subscriptionId, + jobId: jobId, + } +} + +// Call implements example gun call, assertions on response bodies should be done here +func (m *SingleFunctionCallGun) Call(l *wasp.Generator) *wasp.CallResult { + err := m.contracts.LoadTestClient.SendRequest(m.source, m.encryptedSecretsReferences, m.args, m.subscriptionId, m.jobId) + if err != nil { + return &wasp.CallResult{Error: err.Error(), Failed: true} + } + return &wasp.CallResult{} +} diff --git a/integration-tests/load/functions/setup.go b/integration-tests/load/functions/setup.go new file mode 100644 index 00000000000..cd8038c41ba --- /dev/null +++ b/integration-tests/load/functions/setup.go @@ -0,0 +1,64 @@ +package loadfunctions + +import ( + "github.com/pkg/errors" + "github.com/rs/zerolog/log" + "github.com/smartcontractkit/chainlink/integration-tests/contracts" + "github.com/smartcontractkit/chainlink/integration-tests/docker/test_env" + chainlinkutils "github.com/smartcontractkit/chainlink/v2/core/utils" + "math/big" +) + +type Contracts struct { + LinkToken contracts.LinkToken + Coordinator contracts.FunctionsCoordinator + Router contracts.FunctionsRouter + LoadTestClient contracts.FunctionsLoadTestClient +} + +func SetupLocalLoadTestEnv(cfg *PerformanceConfig) (*test_env.CLClusterTestEnv, *Contracts, error) { + env, err := test_env.NewCLTestEnvBuilder(). + Build() + if err != nil { + return env, nil, err + } + env.EVMClient.GetNonceSetting() + lt, err := env.ContractLoader.LoadLINKToken(cfg.Common.LINKTokenAddr) + if err != nil { + return env, nil, err + } + coord, err := env.ContractLoader.LoadFunctionsCoordinator(cfg.Common.Coordinator) + if err != nil { + return env, nil, err + } + router, err := env.ContractLoader.LoadFunctionsRouter(cfg.Common.Router) + if err != nil { + return env, nil, err + } + loadTestClient, err := env.ContractLoader.LoadFunctionsLoadTestClient(cfg.Common.LoadTestClient) + if err != nil { + return env, nil, err + } + if cfg.Common.SubscriptionID == 0 { + log.Info().Msg("Creating new subscription") + subID, err := router.CreateSubscriptionWithConsumer(loadTestClient.Address()) + if err != nil { + return env, nil, errors.Wrap(err, "failed to create a new subscription") + } + encodedSubId, err := chainlinkutils.ABIEncode(`[{"type":"uint64"}]`, subID) + if err != nil { + return env, nil, errors.Wrap(err, "failed to encode subscription ID for funding") + } + _, err = lt.TransferAndCall(router.Address(), big.NewInt(0).Mul(cfg.Common.Funding.SubFunds, big.NewInt(1e18)), encodedSubId) + if err != nil { + return env, nil, errors.Wrap(err, "failed to transferAndCall router, LINK funding") + } + cfg.Common.SubscriptionID = subID + } + return env, &Contracts{ + LinkToken: lt, + Coordinator: coord, + Router: router, + LoadTestClient: loadTestClient, + }, nil +} diff --git a/integration-tests/load/functions/util.go b/integration-tests/load/functions/util.go new file mode 100644 index 00000000000..d5a4a2d6061 --- /dev/null +++ b/integration-tests/load/functions/util.go @@ -0,0 +1,15 @@ +package loadfunctions + +// StringToByte32 transforms a single string into a [32]byte value +func StringToByte32(s string) [32]byte { + var result [32]byte + + for i, ch := range []byte(s) { + if i > 31 { + break + } + result[i] = ch + } + + return result +} From fae804ed047ce723bf1d09c0d8dd03764b0754e2 Mon Sep 17 00:00:00 2001 From: Sam Date: Thu, 24 Aug 2023 10:22:35 -0400 Subject: [PATCH 264/270] Cleanup and refactor mercury v0.3 (#10303) --- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +- .../services/relay/evm/mercury/transmitter.go | 7 +- .../relay/evm/mercury/transmitter_test.go | 6 +- .../relay/evm/mercury/v1/data_source_test.go | 2 +- .../mercury/v1/reportcodec/report_codec.go | 103 ++++++------------ .../v1/reportcodec/report_codec_test.go | 65 ++++++++--- .../relay/evm/mercury/v1/types/types.go | 1 + .../relay/evm/mercury/v2/data_source.go | 8 +- .../relay/evm/mercury/v2/data_source_test.go | 14 +-- .../mercury/v2/reportcodec/report_codec.go | 69 +++++------- .../v2/reportcodec/report_codec_test.go | 46 +++++--- .../relay/evm/mercury/v2/types/types.go | 1 + .../relay/evm/mercury/v3/data_source.go | 8 +- .../relay/evm/mercury/v3/data_source_test.go | 14 +-- .../mercury/v3/reportcodec/report_codec.go | 89 +++++---------- .../v3/reportcodec/report_codec_test.go | 48 +++++--- .../relay/evm/mercury/v3/types/types.go | 1 + go.mod | 2 +- go.sum | 4 +- integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +- 22 files changed, 236 insertions(+), 264 deletions(-) diff --git a/core/scripts/go.mod b/core/scripts/go.mod index fcbb16a31c5..5bbaf919d5b 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -298,7 +298,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20230823081604-f2a0e6b108bb // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index cae9a6488f9..7830ad734e6 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1371,8 +1371,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d h1:gUaXYfDsXMAjMJj1k1Nm3EGZIfLVigMibi+4aj8az7o= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 h1:z9PIgm0klhunwPy+KZYR4E9vCpjgJaMOyQRLCYgfoLk= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/core/services/relay/evm/mercury/transmitter.go b/core/services/relay/evm/mercury/transmitter.go index 228c5dd7044..a98d7c28928 100644 --- a/core/services/relay/evm/mercury/transmitter.go +++ b/core/services/relay/evm/mercury/transmitter.go @@ -337,7 +337,8 @@ func (mt *mercuryTransmitter) LatestPrice(ctx context.Context, feedID [32]byte) return price, nil } -func (mt *mercuryTransmitter) LatestTimestamp(ctx context.Context) (uint32, error) { +// LatestTimestamp will return -1, nil if the feed is missing +func (mt *mercuryTransmitter) LatestTimestamp(ctx context.Context) (int64, error) { mt.lggr.Trace("LatestTimestamp") report, err := mt.latestReport(ctx, mt.feedID) @@ -347,12 +348,12 @@ func (mt *mercuryTransmitter) LatestTimestamp(ctx context.Context) (uint32, erro if report == nil { mt.lggr.Debugw("LatestTimestamp success; got nil report") - return 0, nil + return -1, nil } mt.lggr.Debugw("LatestTimestamp success", "timestamp", report.ObservationsTimestamp) - return uint32(report.ObservationsTimestamp), nil + return report.ObservationsTimestamp, nil } func (mt *mercuryTransmitter) latestReport(ctx context.Context, feedID [32]byte) (*pb.Report, error) { diff --git a/core/services/relay/evm/mercury/transmitter_test.go b/core/services/relay/evm/mercury/transmitter_test.go index ae2fd3c1c23..f4682d0b32e 100644 --- a/core/services/relay/evm/mercury/transmitter_test.go +++ b/core/services/relay/evm/mercury/transmitter_test.go @@ -97,10 +97,10 @@ func Test_MercuryTransmitter_LatestTimestamp(t *testing.T) { ts, err := mt.LatestTimestamp(testutils.Context(t)) require.NoError(t, err) - assert.Equal(t, ts, uint32(42)) + assert.Equal(t, int64(42), ts) }) - t.Run("successful query returning nil report (new feed)", func(t *testing.T) { + t.Run("successful query returning nil report (new feed) gives latest timestamp = -1", func(t *testing.T) { c := mocks.MockWSRPCClient{ LatestReportF: func(ctx context.Context, in *pb.LatestReportRequest) (out *pb.LatestReportResponse, err error) { out = new(pb.LatestReportResponse) @@ -112,7 +112,7 @@ func Test_MercuryTransmitter_LatestTimestamp(t *testing.T) { ts, err := mt.LatestTimestamp(testutils.Context(t)) require.NoError(t, err) - assert.Zero(t, ts) + assert.Equal(t, int64(-1), ts) }) t.Run("failing query", func(t *testing.T) { diff --git a/core/services/relay/evm/mercury/v1/data_source_test.go b/core/services/relay/evm/mercury/v1/data_source_test.go index d846d64e3d9..b518ee1818d 100644 --- a/core/services/relay/evm/mercury/v1/data_source_test.go +++ b/core/services/relay/evm/mercury/v1/data_source_test.go @@ -49,7 +49,7 @@ func (m *mockFetcher) LatestPrice(ctx context.Context, feedID [32]byte) (*big.In return nil, nil } -func (m *mockFetcher) LatestTimestamp(context.Context) (uint32, error) { +func (m *mockFetcher) LatestTimestamp(context.Context) (int64, error) { return 0, nil } diff --git a/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go index 12307bb3e12..a28186cce9c 100644 --- a/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v1/reportcodec/report_codec.go @@ -1,12 +1,14 @@ package reportcodec import ( + "errors" + "fmt" "math" - "github.com/pkg/errors" + "github.com/ethereum/go-ethereum/common" + pkgerrors "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -32,44 +34,28 @@ func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { return &ReportCodec{lggr, feedID} } -func (r *ReportCodec) BuildReport(paos []reportcodec.ParsedAttributedObservation, f int, validFromBlockNum int64) (ocrtypes.Report, error) { - if len(paos) == 0 { - return nil, errors.Errorf("cannot build report from empty attributed observations") +func (r *ReportCodec) BuildReport(rf reportcodec.ReportFields) (ocrtypes.Report, error) { + var merr error + if rf.BenchmarkPrice == nil { + merr = errors.Join(merr, errors.New("benchmarkPrice may not be nil")) } - - mPaos := reportcodec.Convert(paos) - - timestamp := relaymercury.GetConsensusTimestamp(mPaos) - benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusBenchmarkPrice failed") + if rf.Bid == nil { + merr = errors.Join(merr, errors.New("bid may not be nil")) } - bid, err := relaymercury.GetConsensusBid(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusBid failed") + if rf.Ask == nil { + merr = errors.Join(merr, errors.New("ask may not be nil")) } - ask, err := relaymercury.GetConsensusAsk(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusAsk failed") + if len(rf.CurrentBlockHash) != 32 { + merr = errors.Join(merr, fmt.Errorf("invalid length for currentBlockHash, expected: 32, got: %d", len(rf.CurrentBlockHash))) } - - currentBlockHash, currentBlockNum, currentBlockTimestamp, err := reportcodec.GetConsensusCurrentBlock(paos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusCurrentBlock failed") + if merr != nil { + return nil, merr } + var currentBlockHash common.Hash + copy(currentBlockHash[:], rf.CurrentBlockHash) - if validFromBlockNum > currentBlockNum { - return nil, errors.Errorf("validFromBlockNum=%d may not be greater than currentBlockNum=%d", validFromBlockNum, currentBlockNum) - } - - if len(currentBlockHash) != 32 { - return nil, errors.Errorf("invalid length for currentBlockHash, expected: 32, got: %d", len(currentBlockHash)) - } - currentBlockHashArray := [32]byte{} - copy(currentBlockHashArray[:], currentBlockHash) - - reportBytes, err := ReportTypes.Pack(r.feedID, timestamp, benchmarkPrice, bid, ask, uint64(currentBlockNum), currentBlockHashArray, uint64(validFromBlockNum), currentBlockTimestamp) - return ocrtypes.Report(reportBytes), errors.Wrap(err, "failed to pack report blob") + reportBytes, err := ReportTypes.Pack(r.feedID, rf.Timestamp, rf.BenchmarkPrice, rf.Bid, rf.Ask, uint64(rf.CurrentBlockNum), currentBlockHash, uint64(rf.ValidFromBlockNum), rf.CurrentBlockTimestamp) + return ocrtypes.Report(reportBytes), pkgerrors.Wrap(err, "failed to pack report blob") } // Maximum length in bytes of Report returned by BuildReport. Used for @@ -79,52 +65,27 @@ func (r *ReportCodec) MaxReportLength(n int) (int, error) { } func (r *ReportCodec) CurrentBlockNumFromReport(report ocrtypes.Report) (int64, error) { - reportElems := map[string]interface{}{} - if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { - return 0, errors.Errorf("error during unpack: %v", err) - } - - blockNumIface, ok := reportElems["currentBlockNum"] - if !ok { - return 0, errors.Errorf("unpacked report has no 'currentBlockNum' field") - } - - blockNum, ok := blockNumIface.(uint64) - if !ok { - return 0, errors.Errorf("cannot cast blockNum to int64, type is %T", blockNumIface) + decoded, err := r.Decode(report) + if err != nil { + return 0, err } - - if blockNum > math.MaxInt64 { - return 0, errors.Errorf("blockNum overflows max int64, got: %d", blockNum) + if decoded.CurrentBlockNum > math.MaxInt64 { + return 0, fmt.Errorf("CurrentBlockNum=%d overflows max int64", decoded.CurrentBlockNum) } - - return int64(blockNum), nil + return int64(decoded.CurrentBlockNum), nil } func (r *ReportCodec) ValidFromBlockNumFromReport(report ocrtypes.Report) (int64, error) { - reportElems := map[string]interface{}{} - if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { - return 0, errors.Errorf("error during unpack: %v", err) - } - - blockNumIface, ok := reportElems["validFromBlockNum"] - if !ok { - return 0, errors.Errorf("unpacked report has no 'validFromBlockNum' field") - } - - blockNum, ok := blockNumIface.(uint64) - if !ok { - return 0, errors.Errorf("cannot cast blockNum to int64, type is %T", blockNumIface) + decoded, err := r.Decode(report) + if err != nil { + return 0, err } - - if blockNum > math.MaxInt64 { - return 0, errors.Errorf("blockNum overflows max int64, got: %d", blockNum) + if decoded.ValidFromBlockNum > math.MaxInt64 { + return 0, fmt.Errorf("ValidFromBlockNum=%d overflows max int64", decoded.ValidFromBlockNum) } - - return int64(blockNum), nil + return int64(decoded.ValidFromBlockNum), nil } -// Decode is made available to external users (i.e. mercury server) func (r *ReportCodec) Decode(report ocrtypes.Report) (*reporttypes.Report, error) { return reporttypes.Decode(report) } diff --git a/core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go index da6dae56dc3..6e6a58af4ca 100644 --- a/core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go +++ b/core/services/relay/evm/mercury/v1/reportcodec/report_codec_test.go @@ -9,7 +9,6 @@ import ( "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaymercuryv1 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v1" @@ -18,28 +17,37 @@ import ( ) var hash = hexutil.MustDecode("0x552c2cea3ab43bae137d89ee6142a01db3ae2b5678bc3c9bd5f509f537bea57b") -var paos = []relaymercuryv1.ParsedAttributedObservation{ - relaymercuryv1.NewParsedAttributedObservation(42, commontypes.OracleID(49), big.NewInt(43), big.NewInt(44), big.NewInt(45), true, 248, hash, 123, true, 10, true), - relaymercuryv1.NewParsedAttributedObservation(142, commontypes.OracleID(149), big.NewInt(143), big.NewInt(144), big.NewInt(145), true, 248, hash, 123, true, 11, true), - relaymercuryv1.NewParsedAttributedObservation(242, commontypes.OracleID(249), big.NewInt(243), big.NewInt(244), big.NewInt(245), true, 248, hash, 123, true, 12, true), - relaymercuryv1.NewParsedAttributedObservation(342, commontypes.OracleID(250), big.NewInt(343), big.NewInt(344), big.NewInt(345), true, 842, hash, 456, true, 13, true), + +func newValidReportFields() relaymercuryv1.ReportFields { + return relaymercuryv1.ReportFields{ + Timestamp: 242, + BenchmarkPrice: big.NewInt(243), + Bid: big.NewInt(244), + Ask: big.NewInt(245), + CurrentBlockNum: 248, + CurrentBlockHash: hash, + ValidFromBlockNum: 46, + CurrentBlockTimestamp: 123, + } } func Test_ReportCodec(t *testing.T) { r := ReportCodec{} - f := 1 - t.Run("BuildReport errors if observations are empty", func(t *testing.T) { - ps := []relaymercuryv1.ParsedAttributedObservation{} - _, err := r.BuildReport(ps, f, 1) + t.Run("BuildReport errors on zero fields", func(t *testing.T) { + _, err := r.BuildReport(relaymercuryv1.ReportFields{}) require.Error(t, err) - assert.Contains(t, err.Error(), "cannot build report from empty attributed observation") + assert.Contains(t, err.Error(), "benchmarkPrice may not be nil") + assert.Contains(t, err.Error(), "bid may not be nil") + assert.Contains(t, err.Error(), "ask may not be nil") + assert.Contains(t, err.Error(), "invalid length for currentBlockHash, expected: 32, got: 0") }) t.Run("BuildReport constructs a report from observations", func(t *testing.T) { + rf := newValidReportFields() // only need to test happy path since validations are done in relaymercury - report, err := r.BuildReport(paos, f, 46) + report, err := r.BuildReport(rf) require.NoError(t, err) reportElems := make(map[string]interface{}) @@ -91,7 +99,7 @@ func Test_ReportCodec(t *testing.T) { }) } -func buildSampleReport(bn int64, feedID [32]byte) []byte { +func buildSampleReport(bn, validFromBn int64, feedID [32]byte) []byte { timestamp := uint32(42) bp := big.NewInt(242) bid := big.NewInt(243) @@ -99,9 +107,9 @@ func buildSampleReport(bn int64, feedID [32]byte) []byte { currentBlockNumber := uint64(bn) currentBlockHash := utils.NewHash() currentBlockTimestamp := uint64(123) - validFromBlockNum := uint64(143) + validFromBlockNum := uint64(validFromBn) - b, err := ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, currentBlockTimestamp, validFromBlockNum) + b, err := ReportTypes.Pack(feedID, timestamp, bp, bid, ask, currentBlockNumber, currentBlockHash, validFromBlockNum, currentBlockTimestamp) if err != nil { panic(err) } @@ -116,7 +124,7 @@ func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { var invalidBn int64 = -1 t.Run("CurrentBlockNumFromReport extracts the current block number from a valid report", func(t *testing.T) { - report := buildSampleReport(validBn, feedID) + report := buildSampleReport(validBn, 143, feedID) bn, err := r.CurrentBlockNumFromReport(report) require.NoError(t, err) @@ -124,11 +132,32 @@ func Test_ReportCodec_CurrentBlockNumFromReport(t *testing.T) { assert.Equal(t, validBn, bn) }) t.Run("CurrentBlockNumFromReport returns error if block num is too large", func(t *testing.T) { - report := buildSampleReport(invalidBn, feedID) + report := buildSampleReport(invalidBn, 143, feedID) _, err := r.CurrentBlockNumFromReport(report) require.Error(t, err) - assert.Contains(t, err.Error(), "blockNum overflows max int64, got: 18446744073709551615") + assert.Contains(t, err.Error(), "CurrentBlockNum=18446744073709551615 overflows max int64") + }) +} +func Test_ReportCodec_ValidFromBlockNumFromReport(t *testing.T) { + r := ReportCodec{} + feedID := utils.NewHash() + + t.Run("ValidFromBlockNumFromReport extracts the valid from block number from a valid report", func(t *testing.T) { + report := buildSampleReport(42, 999, feedID) + + bn, err := r.ValidFromBlockNumFromReport(report) + require.NoError(t, err) + + assert.Equal(t, int64(999), bn) + }) + t.Run("ValidFromBlockNumFromReport returns error if valid from block number is too large", func(t *testing.T) { + report := buildSampleReport(42, -1, feedID) + + _, err := r.ValidFromBlockNumFromReport(report) + require.Error(t, err) + + assert.Contains(t, err.Error(), "ValidFromBlockNum=18446744073709551615 overflows max int64") }) } diff --git a/core/services/relay/evm/mercury/v1/types/types.go b/core/services/relay/evm/mercury/v1/types/types.go index a25b6b8359f..709fd856a21 100644 --- a/core/services/relay/evm/mercury/v1/types/types.go +++ b/core/services/relay/evm/mercury/v1/types/types.go @@ -42,6 +42,7 @@ type Report struct { CurrentBlockTimestamp uint64 } +// Decode is made available to external users (i.e. mercury server) func Decode(report []byte) (*Report, error) { values, err := schema.Unpack(report) if err != nil { diff --git a/core/services/relay/evm/mercury/v2/data_source.go b/core/services/relay/evm/mercury/v2/data_source.go index 75db51efcb7..bb9d72e35d9 100644 --- a/core/services/relay/evm/mercury/v2/data_source.go +++ b/core/services/relay/evm/mercury/v2/data_source.go @@ -27,7 +27,7 @@ type Runner interface { type LatestReportFetcher interface { LatestPrice(ctx context.Context, feedID [32]byte) (*big.Int, error) - LatestTimestamp(context.Context) (uint32, error) + LatestTimestamp(context.Context) (int64, error) } type datasource struct { @@ -49,8 +49,6 @@ type datasource struct { var _ relaymercuryv2.DataSource = &datasource{} -var maxInt192 = new(big.Int).Exp(big.NewInt(2), big.NewInt(191), nil) - func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID mercuryutils.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID mercuryutils.FeedID) *datasource { return &datasource{pr, jb, spec, feedID, lggr, rr, fetcher, linkFeedID, nativeFeedID, sync.RWMutex{}, enhancedTelemChan} } @@ -106,7 +104,7 @@ func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestam obs.LinkPrice.Val, obs.LinkPrice.Err = ds.fetcher.LatestPrice(ctx, ds.linkFeedID) if obs.LinkPrice.Val == nil && obs.LinkPrice.Err == nil { ds.lggr.Warnw("Mercury server was missing LINK feed, falling back to max int192", "linkFeedID", ds.linkFeedID) - obs.LinkPrice.Val = maxInt192 + obs.LinkPrice.Val = relaymercury.MaxInt192 } }() } @@ -120,7 +118,7 @@ func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestam obs.NativePrice.Val, obs.NativePrice.Err = ds.fetcher.LatestPrice(ctx, ds.nativeFeedID) if obs.NativePrice.Val == nil && obs.NativePrice.Err == nil { ds.lggr.Warnw("Mercury server was missing native feed, falling back to max int192", "nativeFeedID", ds.nativeFeedID) - obs.NativePrice.Val = maxInt192 + obs.NativePrice.Val = relaymercury.MaxInt192 } }() } diff --git a/core/services/relay/evm/mercury/v2/data_source_test.go b/core/services/relay/evm/mercury/v2/data_source_test.go index 65f4a1e2b44..0d5d7b5895f 100644 --- a/core/services/relay/evm/mercury/v2/data_source_test.go +++ b/core/services/relay/evm/mercury/v2/data_source_test.go @@ -22,7 +22,7 @@ import ( var _ relaymercury.MercuryServerFetcher = &mockFetcher{} type mockFetcher struct { - ts uint32 + ts int64 tsErr error linkPrice *big.Int linkPriceErr error @@ -47,7 +47,7 @@ func (m *mockFetcher) LatestPrice(ctx context.Context, fId [32]byte) (*big.Int, return nil, nil } -func (m *mockFetcher) LatestTimestamp(context.Context) (uint32, error) { +func (m *mockFetcher) LatestTimestamp(context.Context) (int64, error) { return m.ts, m.tsErr } @@ -92,7 +92,7 @@ func Test_Datasource(t *testing.T) { obs, err := ds.Observe(ctx, repts, true) assert.NoError(t, err) - assert.Equal(t, uint32(123), obs.MaxFinalizedTimestamp.Val) + assert.Equal(t, int64(123), obs.MaxFinalizedTimestamp.Val) assert.NoError(t, obs.MaxFinalizedTimestamp.Err) }) @@ -123,7 +123,7 @@ func Test_Datasource(t *testing.T) { assert.Equal(t, big.NewInt(122), obs.BenchmarkPrice.Val) assert.NoError(t, obs.BenchmarkPrice.Err) - assert.Equal(t, uint32(123123), obs.MaxFinalizedTimestamp.Val) + assert.Equal(t, int64(123123), obs.MaxFinalizedTimestamp.Val) assert.NoError(t, obs.MaxFinalizedTimestamp.Err) assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) assert.NoError(t, obs.LinkPrice.Err) @@ -191,7 +191,7 @@ func Test_Datasource(t *testing.T) { assert.Equal(t, big.NewInt(122), obs.BenchmarkPrice.Val) assert.NoError(t, obs.BenchmarkPrice.Err) - assert.Equal(t, uint32(0), obs.MaxFinalizedTimestamp.Val) + assert.Equal(t, int64(0), obs.MaxFinalizedTimestamp.Val) assert.NoError(t, obs.MaxFinalizedTimestamp.Err) assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) assert.NoError(t, obs.LinkPrice.Err) @@ -221,9 +221,9 @@ func Test_Datasource(t *testing.T) { obs, err := ds.Observe(ctx, repts, false) assert.NoError(t, err) - assert.Equal(t, obs.LinkPrice.Val, maxInt192) + assert.Equal(t, obs.LinkPrice.Val, relaymercury.MaxInt192) assert.Nil(t, obs.LinkPrice.Err) - assert.Equal(t, obs.NativePrice.Val, maxInt192) + assert.Equal(t, obs.NativePrice.Val, relaymercury.MaxInt192) assert.Nil(t, obs.NativePrice.Err) }) }) diff --git a/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go index 42f1c0e34b0..60dde81f1cb 100644 --- a/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v2/reportcodec/report_codec.go @@ -1,12 +1,13 @@ package reportcodec import ( - "math" + "errors" + "fmt" + "math/big" - "github.com/pkg/errors" + pkgerrors "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -16,6 +17,7 @@ import ( var ReportTypes = reporttypes.GetSchema() var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word +var zero = big.NewInt(0) var _ reportcodec.ReportCodec = &ReportCodec{} @@ -28,31 +30,26 @@ func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { return &ReportCodec{lggr, feedID} } -func (r *ReportCodec) BuildReport(paos []reportcodec.ParsedAttributedObservation, f int, validFromTimestamp, expiresAt uint32) (ocrtypes.Report, error) { - if len(paos) == 0 { - return nil, errors.Errorf("cannot build report from empty attributed observations") +func (r *ReportCodec) BuildReport(rf reportcodec.ReportFields) (ocrtypes.Report, error) { + var merr error + if rf.BenchmarkPrice == nil { + merr = errors.Join(merr, errors.New("benchmarkPrice may not be nil")) } - - mPaos := reportcodec.Convert(paos) - - timestamp := relaymercury.GetConsensusTimestamp(mPaos) - - benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusBenchmarkPrice failed") + if rf.LinkFee == nil { + merr = errors.Join(merr, errors.New("linkFee may not be nil")) + } else if rf.LinkFee.Cmp(zero) < 0 { + merr = errors.Join(merr, fmt.Errorf("linkFee may not be negative (got: %s)", rf.LinkFee)) } - - linkFee, err := relaymercury.GetConsensusLinkFee(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusLinkFee failed") + if rf.NativeFee == nil { + merr = errors.Join(merr, errors.New("nativeFee may not be nil")) + } else if rf.NativeFee.Cmp(zero) < 0 { + merr = errors.Join(merr, fmt.Errorf("nativeFee may not be negative (got: %s)", rf.NativeFee)) } - nativeFee, err := relaymercury.GetConsensusNativeFee(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusNativeFee failed") + if merr != nil { + return nil, merr } - - reportBytes, err := ReportTypes.Pack(r.feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, benchmarkPrice) - return ocrtypes.Report(reportBytes), errors.Wrap(err, "failed to pack report blob") + reportBytes, err := ReportTypes.Pack(r.feedID, rf.ValidFromTimestamp, rf.Timestamp, rf.NativeFee, rf.LinkFee, rf.ExpiresAt, rf.BenchmarkPrice) + return ocrtypes.Report(reportBytes), pkgerrors.Wrap(err, "failed to pack report blob") } func (r *ReportCodec) MaxReportLength(n int) (int, error) { @@ -60,29 +57,13 @@ func (r *ReportCodec) MaxReportLength(n int) (int, error) { } func (r *ReportCodec) ObservationTimestampFromReport(report ocrtypes.Report) (uint32, error) { - reportElems := map[string]interface{}{} - if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { - return 0, errors.Errorf("error during unpack: %v", err) - } - - timestampIface, ok := reportElems["observationsTimestamp"] - if !ok { - return 0, errors.Errorf("unpacked report has no 'observationTimestamp' field") - } - - timestamp, ok := timestampIface.(uint32) - if !ok { - return 0, errors.Errorf("cannot cast timestamp to uint32, type is %T", timestampIface) - } - - if timestamp > math.MaxInt32 { - return 0, errors.Errorf("timestamp overflows max uint32, got: %d", timestamp) + decoded, err := r.Decode(report) + if err != nil { + return 0, err } - - return timestamp, nil + return decoded.ObservationsTimestamp, nil } -// Decode is made available to external users (i.e. mercury server) func (r *ReportCodec) Decode(report ocrtypes.Report) (*reporttypes.Report, error) { return reporttypes.Decode(report) } diff --git a/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go index 4e5a79bc50d..c0c931dfe3a 100644 --- a/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go +++ b/core/services/relay/evm/mercury/v2/reportcodec/report_codec_test.go @@ -1,41 +1,44 @@ package reportcodec import ( - "math" "math/big" "testing" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaymercuryv2 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v2" ) -var paos = []relaymercuryv2.ParsedAttributedObservation{ - relaymercuryv2.NewParsedAttributedObservation(42, commontypes.OracleID(49), big.NewInt(43), true, 123, true, big.NewInt(143), true, big.NewInt(457), true), - relaymercuryv2.NewParsedAttributedObservation(142, commontypes.OracleID(149), big.NewInt(143), true, 455, true, big.NewInt(456), true, big.NewInt(345), true), - relaymercuryv2.NewParsedAttributedObservation(242, commontypes.OracleID(249), big.NewInt(243), true, 789, true, big.NewInt(764), true, big.NewInt(167), true), - relaymercuryv2.NewParsedAttributedObservation(342, commontypes.OracleID(250), big.NewInt(343), true, 123, true, big.NewInt(378), true, big.NewInt(643), true), +func newValidReportFields() relaymercuryv2.ReportFields { + return relaymercuryv2.ReportFields{ + Timestamp: 242, + BenchmarkPrice: big.NewInt(243), + ValidFromTimestamp: 123, + ExpiresAt: 20, + LinkFee: big.NewInt(456), + NativeFee: big.NewInt(457), + } } func Test_ReportCodec_BuildReport(t *testing.T) { r := ReportCodec{} - f := 1 - t.Run("BuildReport errors if observations are empty", func(t *testing.T) { - ps := []relaymercuryv2.ParsedAttributedObservation{} - _, err := r.BuildReport(ps, f, 123, 10) + t.Run("BuildReport errors on zero values", func(t *testing.T) { + _, err := r.BuildReport(relaymercuryv2.ReportFields{}) require.Error(t, err) - assert.Contains(t, err.Error(), "cannot build report from empty attributed observation") + assert.Contains(t, err.Error(), "benchmarkPrice may not be nil") + assert.Contains(t, err.Error(), "linkFee may not be nil") + assert.Contains(t, err.Error(), "nativeFee may not be nil") }) t.Run("BuildReport constructs a report from observations", func(t *testing.T) { + rf := newValidReportFields() // only need to test happy path since validations are done in relaymercury - report, err := r.BuildReport(paos, f, 123, 20) + report, err := r.BuildReport(rf) require.NoError(t, err) reportElems := make(map[string]interface{}) @@ -69,6 +72,17 @@ func Test_ReportCodec_BuildReport(t *testing.T) { }) }) + t.Run("errors on negative fee", func(t *testing.T) { + rf := newValidReportFields() + rf.LinkFee = big.NewInt(-1) + rf.NativeFee = big.NewInt(-1) + _, err := r.BuildReport(rf) + require.Error(t, err) + + assert.Contains(t, err.Error(), "linkFee may not be negative (got: -1)") + assert.Contains(t, err.Error(), "nativeFee may not be negative (got: -1)") + }) + t.Run("Decode errors on invalid report", func(t *testing.T) { _, err := r.Decode([]byte{1, 2, 3}) assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") @@ -109,12 +123,12 @@ func Test_ReportCodec_ObservationTimestampFromReport(t *testing.T) { assert.Equal(t, ts, uint32(123)) }) - t.Run("ObservationTimestampFromReport returns error when timestamp is too big", func(t *testing.T) { - report := buildSampleReport(math.MaxInt32 + 1) + t.Run("ObservationTimestampFromReport returns error when report is invalid", func(t *testing.T) { + report := []byte{1, 2, 3} _, err := r.ObservationTimestampFromReport(report) require.Error(t, err) - assert.EqualError(t, err, "timestamp overflows max uint32, got: 2147483648") + assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") }) } diff --git a/core/services/relay/evm/mercury/v2/types/types.go b/core/services/relay/evm/mercury/v2/types/types.go index af973d3122f..b09ee66f093 100644 --- a/core/services/relay/evm/mercury/v2/types/types.go +++ b/core/services/relay/evm/mercury/v2/types/types.go @@ -38,6 +38,7 @@ type Report struct { NativeFee *big.Int } +// Decode is made available to external users (i.e. mercury server) func Decode(report []byte) (*Report, error) { values, err := schema.Unpack(report) if err != nil { diff --git a/core/services/relay/evm/mercury/v3/data_source.go b/core/services/relay/evm/mercury/v3/data_source.go index a7bd1c189be..46dcf1fecdb 100644 --- a/core/services/relay/evm/mercury/v3/data_source.go +++ b/core/services/relay/evm/mercury/v3/data_source.go @@ -28,7 +28,7 @@ type Runner interface { type LatestReportFetcher interface { LatestPrice(ctx context.Context, feedID [32]byte) (*big.Int, error) - LatestTimestamp(context.Context) (uint32, error) + LatestTimestamp(context.Context) (int64, error) } type datasource struct { @@ -50,8 +50,6 @@ type datasource struct { var _ relaymercuryv3.DataSource = &datasource{} -var maxInt192 = new(big.Int).Exp(big.NewInt(2), big.NewInt(191), nil) - func NewDataSource(pr pipeline.Runner, jb job.Job, spec pipeline.Spec, feedID mercuryutils.FeedID, lggr logger.Logger, rr chan pipeline.Run, enhancedTelemChan chan ocrcommon.EnhancedTelemetryMercuryData, fetcher LatestReportFetcher, linkFeedID, nativeFeedID mercuryutils.FeedID) *datasource { return &datasource{pr, jb, spec, feedID, lggr, rr, fetcher, linkFeedID, nativeFeedID, sync.RWMutex{}, enhancedTelemChan} } @@ -109,7 +107,7 @@ func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestam obs.LinkPrice.Val, obs.LinkPrice.Err = ds.fetcher.LatestPrice(ctx, ds.linkFeedID) if obs.LinkPrice.Val == nil && obs.LinkPrice.Err == nil { ds.lggr.Warnw("Mercury server was missing LINK feed, falling back to max int192", "linkFeedID", ds.linkFeedID) - obs.LinkPrice.Val = maxInt192 + obs.LinkPrice.Val = relaymercury.MaxInt192 } }() } @@ -123,7 +121,7 @@ func (ds *datasource) Observe(ctx context.Context, repts ocrtypes.ReportTimestam obs.NativePrice.Val, obs.NativePrice.Err = ds.fetcher.LatestPrice(ctx, ds.nativeFeedID) if obs.NativePrice.Val == nil && obs.NativePrice.Err == nil { ds.lggr.Warnw("Mercury server was missing native feed, falling back to max int192", "nativeFeedID", ds.nativeFeedID) - obs.NativePrice.Val = maxInt192 + obs.NativePrice.Val = relaymercury.MaxInt192 } }() } diff --git a/core/services/relay/evm/mercury/v3/data_source_test.go b/core/services/relay/evm/mercury/v3/data_source_test.go index 2db4cb9f4b4..7fc2e90193c 100644 --- a/core/services/relay/evm/mercury/v3/data_source_test.go +++ b/core/services/relay/evm/mercury/v3/data_source_test.go @@ -22,7 +22,7 @@ import ( var _ relaymercury.MercuryServerFetcher = &mockFetcher{} type mockFetcher struct { - ts uint32 + ts int64 tsErr error linkPrice *big.Int linkPriceErr error @@ -47,7 +47,7 @@ func (m *mockFetcher) LatestPrice(ctx context.Context, fId [32]byte) (*big.Int, return nil, nil } -func (m *mockFetcher) LatestTimestamp(context.Context) (uint32, error) { +func (m *mockFetcher) LatestTimestamp(context.Context) (int64, error) { return m.ts, m.tsErr } @@ -102,7 +102,7 @@ func Test_Datasource(t *testing.T) { obs, err := ds.Observe(ctx, repts, true) assert.NoError(t, err) - assert.Equal(t, uint32(123), obs.MaxFinalizedTimestamp.Val) + assert.Equal(t, int64(123), obs.MaxFinalizedTimestamp.Val) assert.NoError(t, obs.MaxFinalizedTimestamp.Err) }) @@ -137,7 +137,7 @@ func Test_Datasource(t *testing.T) { assert.NoError(t, obs.Bid.Err) assert.Equal(t, big.NewInt(123), obs.Ask.Val) assert.NoError(t, obs.Ask.Err) - assert.Equal(t, uint32(123123), obs.MaxFinalizedTimestamp.Val) + assert.Equal(t, int64(123123), obs.MaxFinalizedTimestamp.Val) assert.NoError(t, obs.MaxFinalizedTimestamp.Err) assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) assert.NoError(t, obs.LinkPrice.Err) @@ -219,7 +219,7 @@ func Test_Datasource(t *testing.T) { assert.NoError(t, obs.Bid.Err) assert.Equal(t, big.NewInt(123), obs.Ask.Val) assert.NoError(t, obs.Ask.Err) - assert.Equal(t, uint32(0), obs.MaxFinalizedTimestamp.Val) + assert.Equal(t, int64(0), obs.MaxFinalizedTimestamp.Val) assert.NoError(t, obs.MaxFinalizedTimestamp.Err) assert.Equal(t, big.NewInt(122), obs.LinkPrice.Val) assert.NoError(t, obs.LinkPrice.Err) @@ -249,9 +249,9 @@ func Test_Datasource(t *testing.T) { obs, err := ds.Observe(ctx, repts, false) assert.NoError(t, err) - assert.Equal(t, obs.LinkPrice.Val, maxInt192) + assert.Equal(t, obs.LinkPrice.Val, relaymercury.MaxInt192) assert.Nil(t, obs.LinkPrice.Err) - assert.Equal(t, obs.NativePrice.Val, maxInt192) + assert.Equal(t, obs.NativePrice.Val, relaymercury.MaxInt192) assert.Nil(t, obs.NativePrice.Err) }) }) diff --git a/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go b/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go index 0c9cd2e5cfc..66995e74ea7 100644 --- a/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go +++ b/core/services/relay/evm/mercury/v3/reportcodec/report_codec.go @@ -1,13 +1,14 @@ package reportcodec import ( + "errors" "fmt" - "math" - "github.com/pkg/errors" + "math/big" + + pkgerrors "github.com/pkg/errors" ocrtypes "github.com/smartcontractkit/libocr/offchainreporting2plus/types" - relaymercury "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury" reportcodec "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" "github.com/smartcontractkit/chainlink/v2/core/logger" @@ -17,6 +18,7 @@ import ( var ReportTypes = reporttypes.GetSchema() var maxReportLength = 32 * len(ReportTypes) // each arg is 256 bit EVM word +var zero = big.NewInt(0) var _ reportcodec.ReportCodec = &ReportCodec{} @@ -29,39 +31,32 @@ func NewReportCodec(feedID [32]byte, lggr logger.Logger) *ReportCodec { return &ReportCodec{lggr, feedID} } -func (r *ReportCodec) BuildReport(paos []reportcodec.ParsedAttributedObservation, f int, validFromTimestamp, expiresAt uint32) (ocrtypes.Report, error) { - if len(paos) == 0 { - return nil, errors.Errorf("cannot build report from empty attributed observations") +func (r *ReportCodec) BuildReport(rf reportcodec.ReportFields) (ocrtypes.Report, error) { + var merr error + if rf.BenchmarkPrice == nil { + merr = errors.Join(merr, errors.New("benchmarkPrice may not be nil")) } - - mPaos := reportcodec.Convert(paos) - - timestamp := relaymercury.GetConsensusTimestamp(mPaos) - - benchmarkPrice, err := relaymercury.GetConsensusBenchmarkPrice(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusBenchmarkPrice failed") + if rf.Bid == nil { + merr = errors.Join(merr, errors.New("bid may not be nil")) } - bid, err := relaymercury.GetConsensusBid(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusBid failed") + if rf.Ask == nil { + merr = errors.Join(merr, errors.New("ask may not be nil")) } - ask, err := relaymercury.GetConsensusAsk(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusAsk failed") + if rf.LinkFee == nil { + merr = errors.Join(merr, errors.New("linkFee may not be nil")) + } else if rf.LinkFee.Cmp(zero) < 0 { + merr = errors.Join(merr, fmt.Errorf("linkFee may not be negative (got: %s)", rf.LinkFee)) } - - linkFee, err := relaymercury.GetConsensusLinkFee(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusLinkFee failed") + if rf.NativeFee == nil { + merr = errors.Join(merr, errors.New("nativeFee may not be nil")) + } else if rf.NativeFee.Cmp(zero) < 0 { + merr = errors.Join(merr, fmt.Errorf("nativeFee may not be negative (got: %s)", rf.NativeFee)) } - nativeFee, err := relaymercury.GetConsensusNativeFee(mPaos, f) - if err != nil { - return nil, errors.Wrap(err, "GetConsensusNativeFee failed") + if merr != nil { + return nil, merr } - - reportBytes, err := ReportTypes.Pack(r.feedID, validFromTimestamp, timestamp, nativeFee, linkFee, expiresAt, benchmarkPrice, bid, ask) - return ocrtypes.Report(reportBytes), errors.Wrap(err, "failed to pack report blob") + reportBytes, err := ReportTypes.Pack(r.feedID, rf.ValidFromTimestamp, rf.Timestamp, rf.NativeFee, rf.LinkFee, rf.ExpiresAt, rf.BenchmarkPrice, rf.Bid, rf.Ask) + return ocrtypes.Report(reportBytes), pkgerrors.Wrap(err, "failed to pack report blob") } func (r *ReportCodec) MaxReportLength(n int) (int, error) { @@ -69,37 +64,13 @@ func (r *ReportCodec) MaxReportLength(n int) (int, error) { } func (r *ReportCodec) ObservationTimestampFromReport(report ocrtypes.Report) (uint32, error) { - reportElems := map[string]interface{}{} - if err := ReportTypes.UnpackIntoMap(reportElems, report); err != nil { - return 0, errors.Errorf("error during unpack: %v", err) - } - - timestampIface, ok := reportElems["observationsTimestamp"] - if !ok { - return 0, errors.Errorf("unpacked report has no 'timestamp' field") - } - - timestamp, ok := timestampIface.(uint32) - if !ok { - return 0, errors.Errorf("cannot cast timestamp to uint32, type is %T", timestampIface) - } - - if timestamp > math.MaxInt32 { - return 0, errors.Errorf("timestamp overflows max uint32, got: %d", timestamp) + decoded, err := r.Decode(report) + if err != nil { + return 0, err } - - return timestamp, nil + return decoded.ObservationsTimestamp, nil } -// Decode is made available to external users (i.e. mercury server) func (r *ReportCodec) Decode(report ocrtypes.Report) (*reporttypes.Report, error) { - values, err := ReportTypes.Unpack(report) - if err != nil { - return nil, fmt.Errorf("failed to decode report: %w", err) - } - decoded := new(reporttypes.Report) - if err = ReportTypes.Copy(decoded, values); err != nil { - return nil, fmt.Errorf("failed to copy report values to struct: %w", err) - } - return decoded, nil + return reporttypes.Decode(report) } diff --git a/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go b/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go index 9a5e3c0f2fe..80cf4c9665b 100644 --- a/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go +++ b/core/services/relay/evm/mercury/v3/reportcodec/report_codec_test.go @@ -1,41 +1,46 @@ package reportcodec import ( - "math" "math/big" "testing" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" - "github.com/smartcontractkit/libocr/commontypes" "github.com/smartcontractkit/libocr/offchainreporting2plus/types" relaymercuryv3 "github.com/smartcontractkit/chainlink-relay/pkg/reportingplugins/mercury/v3" ) -var paos = []relaymercuryv3.ParsedAttributedObservation{ - relaymercuryv3.NewParsedAttributedObservation(42, commontypes.OracleID(49), big.NewInt(43), big.NewInt(44), big.NewInt(45), true, 123, true, big.NewInt(143), true, big.NewInt(457), true), - relaymercuryv3.NewParsedAttributedObservation(142, commontypes.OracleID(149), big.NewInt(143), big.NewInt(144), big.NewInt(145), true, 455, true, big.NewInt(456), true, big.NewInt(345), true), - relaymercuryv3.NewParsedAttributedObservation(242, commontypes.OracleID(249), big.NewInt(243), big.NewInt(244), big.NewInt(245), true, 789, true, big.NewInt(764), true, big.NewInt(167), true), - relaymercuryv3.NewParsedAttributedObservation(342, commontypes.OracleID(250), big.NewInt(343), big.NewInt(344), big.NewInt(345), true, 123, true, big.NewInt(378), true, big.NewInt(643), true), +func newValidReportFields() relaymercuryv3.ReportFields { + return relaymercuryv3.ReportFields{ + Timestamp: 242, + BenchmarkPrice: big.NewInt(243), + Bid: big.NewInt(244), + Ask: big.NewInt(245), + ValidFromTimestamp: 123, + ExpiresAt: 20, + LinkFee: big.NewInt(456), + NativeFee: big.NewInt(457), + } } func Test_ReportCodec_BuildReport(t *testing.T) { r := ReportCodec{} - f := 1 - t.Run("BuildReport errors if observations are empty", func(t *testing.T) { - ps := []relaymercuryv3.ParsedAttributedObservation{} - _, err := r.BuildReport(ps, f, 123, 10) + t.Run("BuildReport errors on zero values", func(t *testing.T) { + _, err := r.BuildReport(relaymercuryv3.ReportFields{}) require.Error(t, err) - assert.Contains(t, err.Error(), "cannot build report from empty attributed observation") + assert.Contains(t, err.Error(), "benchmarkPrice may not be nil") + assert.Contains(t, err.Error(), "linkFee may not be nil") + assert.Contains(t, err.Error(), "nativeFee may not be nil") }) t.Run("BuildReport constructs a report from observations", func(t *testing.T) { + rf := newValidReportFields() // only need to test happy path since validations are done in relaymercury - report, err := r.BuildReport(paos, f, 123, 20) + report, err := r.BuildReport(rf) require.NoError(t, err) reportElems := make(map[string]interface{}) @@ -73,6 +78,17 @@ func Test_ReportCodec_BuildReport(t *testing.T) { }) }) + t.Run("errors on negative fee", func(t *testing.T) { + rf := newValidReportFields() + rf.LinkFee = big.NewInt(-1) + rf.NativeFee = big.NewInt(-1) + _, err := r.BuildReport(rf) + require.Error(t, err) + + assert.Contains(t, err.Error(), "linkFee may not be negative (got: -1)") + assert.Contains(t, err.Error(), "nativeFee may not be negative (got: -1)") + }) + t.Run("Decode errors on invalid report", func(t *testing.T) { _, err := r.Decode([]byte{1, 2, 3}) assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") @@ -115,12 +131,12 @@ func Test_ReportCodec_ObservationTimestampFromReport(t *testing.T) { assert.Equal(t, ts, uint32(123)) }) - t.Run("ObservationTimestampFromReport returns error when timestamp is too big", func(t *testing.T) { - report := buildSampleReport(math.MaxInt32 + 1) + t.Run("ObservationTimestampFromReport returns error when report is invalid", func(t *testing.T) { + report := []byte{1, 2, 3} _, err := r.ObservationTimestampFromReport(report) require.Error(t, err) - assert.EqualError(t, err, "timestamp overflows max uint32, got: 2147483648") + assert.EqualError(t, err, "failed to decode report: abi: cannot marshal in to go type: length insufficient 3 require 32") }) } diff --git a/core/services/relay/evm/mercury/v3/types/types.go b/core/services/relay/evm/mercury/v3/types/types.go index 630f8a16e69..110315942d8 100644 --- a/core/services/relay/evm/mercury/v3/types/types.go +++ b/core/services/relay/evm/mercury/v3/types/types.go @@ -42,6 +42,7 @@ type Report struct { NativeFee *big.Int } +// Decode is made available to external users (i.e. mercury server) func Decode(report []byte) (*Report, error) { values, err := schema.Unpack(report) if err != nil { diff --git a/go.mod b/go.mod index d40292e6453..eec11c19cec 100644 --- a/go.mod +++ b/go.mod @@ -66,7 +66,7 @@ require ( github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a github.com/smartcontractkit/libocr v0.0.0-20230816220705-665e93233ae5 diff --git a/go.sum b/go.sum index 71dd4f53e78..de3cfe7acc7 100644 --- a/go.sum +++ b/go.sum @@ -1371,8 +1371,8 @@ github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumv github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d h1:gUaXYfDsXMAjMJj1k1Nm3EGZIfLVigMibi+4aj8az7o= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 h1:z9PIgm0klhunwPy+KZYR4E9vCpjgJaMOyQRLCYgfoLk= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= diff --git a/integration-tests/go.mod b/integration-tests/go.mod index a7c1b00b75b..69450aef6cd 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -381,7 +381,7 @@ require ( github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect - github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d // indirect + github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect github.com/smartcontractkit/sqlx v1.3.5-0.20210805004948-4be295aacbeb // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 74705e10b51..28def434dd5 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2241,8 +2241,8 @@ github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce67266 github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d h1:gUaXYfDsXMAjMJj1k1Nm3EGZIfLVigMibi+4aj8az7o= -github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230817164916-93440e96411d/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 h1:z9PIgm0klhunwPy+KZYR4E9vCpjgJaMOyQRLCYgfoLk= +github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85/go.mod h1:H3/j2l84FsxYevCLNERdVasI7FVr+t2mkpv+BCJLSVw= github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a h1:b3rjvZLpTV45TmCV+ALX+EDDslf91pnDUugP54Lu9FA= From d4578c1f3228cd6d7697650ba2fecdb630f51679 Mon Sep 17 00:00:00 2001 From: Patrick Date: Thu, 24 Aug 2023 10:58:40 -0400 Subject: [PATCH 265/270] Update Operator UI from v0.8.0-91e5ba4 to v0.8.0-95ae9da (#10333) * Update Operator UI from v0.8.0-91e5ba4 to v0.8.0-95ae9da * empty commit for CI --------- Co-authored-by: github-merge-queue[bot] --- operator_ui/TAG | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/operator_ui/TAG b/operator_ui/TAG index e75a8c12a57..b6ab818cb54 100644 --- a/operator_ui/TAG +++ b/operator_ui/TAG @@ -1 +1 @@ -v0.8.0-91e5ba4 +v0.8.0-95ae9da From 05ccfc65e47bac2b0b7d61e2440c7c0021d82e8b Mon Sep 17 00:00:00 2001 From: Tate Date: Thu, 24 Aug 2023 09:14:15 -0600 Subject: [PATCH 266/270] Bump Test Actions To Get Docker Image Exists Fix (#10335) --- .github/actions/build-test-image/action.yml | 4 ++-- .../workflows/automation-benchmark-tests.yml | 2 +- .../workflows/automation-ondemand-tests.yml | 6 ++--- .github/workflows/ci-core.yml | 2 +- .github/workflows/generic-test-runner.yml | 6 ++--- .github/workflows/integration-chaos-tests.yml | 6 ++--- .github/workflows/integration-tests.yml | 22 +++++++++---------- .github/workflows/on-demand-ocr-soak-test.yml | 2 +- .github/workflows/performance-tests.yml | 2 +- 9 files changed, 26 insertions(+), 26 deletions(-) diff --git a/.github/actions/build-test-image/action.yml b/.github/actions/build-test-image/action.yml index 29c9bbd0004..4384fe23e65 100644 --- a/.github/actions/build-test-image/action.yml +++ b/.github/actions/build-test-image/action.yml @@ -32,7 +32,7 @@ runs: steps: - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: repository: ${{ inputs.repository }} tag: ${{ inputs.tag }} @@ -40,7 +40,7 @@ runs: AWS_ROLE_TO_ASSUME: ${{ inputs.QA_AWS_ROLE_TO_ASSUME }} - name: Build and Publish Test Runner if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/docker/build-push@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 + uses: smartcontractkit/chainlink-github-actions/docker/build-push@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: tags: | ${{ inputs.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ inputs.QA_AWS_REGION }}.amazonaws.com/${{ inputs.repository }}:${{ inputs.tag }} diff --git a/.github/workflows/automation-benchmark-tests.yml b/.github/workflows/automation-benchmark-tests.yml index 3113d74e6f1..38c75ccbcef 100644 --- a/.github/workflows/automation-benchmark-tests.yml +++ b/.github/workflows/automation-benchmark-tests.yml @@ -107,7 +107,7 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 env: DETACH_RUNNER: true TEST_SUITE: benchmark diff --git a/.github/workflows/automation-ondemand-tests.yml b/.github/workflows/automation-ondemand-tests.yml index baf507143f9..ed60a4d4e55 100644 --- a/.github/workflows/automation-ondemand-tests.yml +++ b/.github/workflows/automation-ondemand-tests.yml @@ -49,7 +49,7 @@ jobs: - name: Check if image exists if: inputs.chainlinkImage == '' id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -57,7 +57,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' && inputs.chainlinkImage == '' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -160,7 +160,7 @@ jobs: echo "version=develop" >>$GITHUB_OUTPUT fi - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 env: PYROSCOPE_SERVER: ${{ matrix.tests.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.tests.pyroscope_env }} diff --git a/.github/workflows/ci-core.yml b/.github/workflows/ci-core.yml index 3904c729cbb..4ef0fb68688 100644 --- a/.github/workflows/ci-core.yml +++ b/.github/workflows/ci-core.yml @@ -180,7 +180,7 @@ jobs: run: ./tools/bin/${{ matrix.cmd }} "${{ matrix.split.pkgs }}" - name: Print Filtered Test Results if: failure() - uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/go/go-test-results-parsing@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: results-file: ./output.txt output-file: ./output-short.txt diff --git a/.github/workflows/generic-test-runner.yml b/.github/workflows/generic-test-runner.yml index e6e862703f6..727b091ac41 100644 --- a/.github/workflows/generic-test-runner.yml +++ b/.github/workflows/generic-test-runner.yml @@ -53,7 +53,7 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -61,7 +61,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -126,7 +126,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 1h -count=1 ./${{ github.event.inputs.directory }} -run ${{ github.event.inputs.test }} -v -args ${{ github.event.inputs.test-inputs }} test_download_vendor_packages_command: cd ./integration-tests && go mod download diff --git a/.github/workflows/integration-chaos-tests.yml b/.github/workflows/integration-chaos-tests.yml index 724b5581676..0191c3f4615 100644 --- a/.github/workflows/integration-chaos-tests.yml +++ b/.github/workflows/integration-chaos-tests.yml @@ -30,7 +30,7 @@ jobs: uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: repository: chainlink tag: ${{ github.sha }} @@ -38,7 +38,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -109,7 +109,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_command_to_run: make test_need_operator_assets && cd integration-tests && go test -timeout 1h -count=1 -json -test.parallel 11 ./chaos 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download diff --git a/.github/workflows/integration-tests.yml b/.github/workflows/integration-tests.yml index 38bb5e7f62b..a47530e4d04 100644 --- a/.github/workflows/integration-tests.yml +++ b/.github/workflows/integration-tests.yml @@ -87,7 +87,7 @@ jobs: - name: Check if image exists if: needs.changes.outputs.src == 'true' id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: repository: chainlink tag: ${{ github.sha }}${{ matrix.image.tag-suffix }} @@ -95,7 +95,7 @@ jobs: AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} - name: Build Image if: steps.check-image.outputs.exists == 'false' && needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/build-image@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: cl_repo: smartcontractkit/chainlink cl_ref: ${{ github.sha }} @@ -175,7 +175,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 env: TESTCONTAINERS_RYUK_DISABLED: true PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 @@ -200,7 +200,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod @@ -393,7 +393,7 @@ jobs: ## Run this step when changes that require tests to be run are made - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 env: PYROSCOPE_SERVER: ${{ matrix.product.pyroscope_env == '' && '' || !startsWith(github.ref, 'refs/tags/') && '' || secrets.QA_PYROSCOPE_INSTANCE }} # Avoid sending blank envs https://github.com/orgs/community/discussions/25725 PYROSCOPE_ENVIRONMENT: ${{ matrix.product.pyroscope_env }} @@ -416,7 +416,7 @@ jobs: ## Run this step when changes that do not need the test to run are made - name: Run Setup if: needs.changes.outputs.src == 'false' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-run-tests-environment@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_download_vendor_packages_command: cd ./integration-tests && go mod download go_mod_path: ./integration-tests/go.mod @@ -478,7 +478,7 @@ jobs: with: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} - name: Run Setup - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/setup-go@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_download_vendor_packages_command: | cd ./integration-tests @@ -526,7 +526,7 @@ jobs: run: | echo "Running migration tests from version '${{ steps.get_latest_version.outputs.latest_version }}' to: '${{ github.sha }}'" - name: Run Migration Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_command_to_run: make test_need_operator_assets && cd ./integration-tests && go test -timeout 30m -count=1 -json ./migration 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: cd ./integration-tests && go mod download @@ -626,7 +626,7 @@ jobs: steps: - name: Check if image exists id: check-image - uses: smartcontractkit/chainlink-github-actions/docker/image-exists@395ee22f09f3e975690fa150343ce1e0c9e908c3 # v2.2.10 + uses: smartcontractkit/chainlink-github-actions/docker/image-exists@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: repository: chainlink-solana-tests tag: ${{ needs.get_solana_sha.outputs.sha }} @@ -765,7 +765,7 @@ jobs: ref: ${{ needs.get_solana_sha.outputs.sha }} - name: Run Tests if: needs.changes.outputs.src == 'true' - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_command_to_run: export ENV_JOB_IMAGE=${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/chainlink-solana-tests:${{ needs.get_solana_sha.outputs.sha }} && make test_smoke cl_repo: ${{ env.CHAINLINK_IMAGE }} @@ -828,7 +828,7 @@ jobs: ref: ${{ github.event.pull_request.head.sha || github.event.merge_group.head_sha }} ## Only run OCR smoke test for now - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 env: PYROSCOPE_SERVER: ${{ secrets.QA_PYROSCOPE_INSTANCE }} PYROSCOPE_ENVIRONMENT: ci-smoke-ocr-evm-${{ matrix.testnet }} # TODO: Only for OCR for now diff --git a/.github/workflows/on-demand-ocr-soak-test.yml b/.github/workflows/on-demand-ocr-soak-test.yml index 532c5bdef58..284464a4d09 100644 --- a/.github/workflows/on-demand-ocr-soak-test.yml +++ b/.github/workflows/on-demand-ocr-soak-test.yml @@ -121,7 +121,7 @@ jobs: QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 env: DETACH_RUNNER: true TEST_SUITE: soak diff --git a/.github/workflows/performance-tests.yml b/.github/workflows/performance-tests.yml index 57b337db995..3c104892407 100644 --- a/.github/workflows/performance-tests.yml +++ b/.github/workflows/performance-tests.yml @@ -57,7 +57,7 @@ jobs: - name: Checkout the repo uses: actions/checkout@c85c95e3d7251135ab7dc9ce3241c5835cc595a9 # v3.5.3 - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@d8d8289ebe487dc995be45d00519def022643fa7 # v2.2.11 + uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c6214deb10a3f374c6d3430c32c5202015d463 # v2.2.12 with: test_command_to_run: cd integration-tests && go test -timeout 1h -count=1 -json -test.parallel 10 ./performance 2>&1 | tee /tmp/gotest.log | gotestfmt test_download_vendor_packages_command: make gomod From 0fac805bd1d1f96acd65492316cdd78f692aef2a Mon Sep 17 00:00:00 2001 From: Calvin <78729586+calvwang9@users.noreply.github.com> Date: Fri, 25 Aug 2023 01:31:35 +1000 Subject: [PATCH 267/270] Bci 1738/cosmos cleanup (#10238) * add native token field to cosmos config * remove fcdurl * change gas token to native token * rename to fee token * add bech32 prefix to cosmos config * bump chainlink-cosmos to feature branch * fix type error * update chain-cosmos.toml * fix fee estimator test * fix types and gas price estimator input * make config-docs * update chainlink-cosmos version * fix cosmos config tests * update tomls and types * fix tests * cleanup CosmosSendAtom * fix docs and scripts tests * remove atom references * use ValidateDenom * fix cosmos config in relayer test * sort cosmos config fields alphabetically * undo accidental test changes * bump chainlink-cosmos version * fix cosmos config order --------- Co-authored-by: krehermann --- core/chains/cosmos/chain.go | 2 +- core/chains/cosmos/config.go | 23 +++++++++++------ core/chains/cosmos/cosmostxm/main_test.go | 2 +- core/chains/cosmos/cosmostxm/txm.go | 6 ++--- .../cosmos/cosmostxm/txm_internal_test.go | 9 +++++-- core/chains/cosmos/cosmostxm/txm_test.go | 18 +++++++------ core/cmd/cosmos_transaction_commands.go | 25 ++++++++++++------- core/cmd/cosmos_transaction_commands_test.go | 22 ++++++++-------- core/config/docs/chains-cosmos.toml | 6 +++-- core/scripts/go.mod | 2 +- core/scripts/go.sum | 4 +-- core/services/chainlink/config_test.go | 6 +++-- .../relayer_chain_interoperators_test.go | 4 +++ .../chainlink/testdata/config-full.toml | 3 ++- .../config-multi-chain-effective.toml | 6 +++-- core/store/models/cosmos/common.go | 1 + core/web/cosmos_chains_controller_test.go | 3 ++- core/web/cosmos_transfer_controller.go | 18 +++---------- core/web/resolver/testdata/config-full.toml | 3 ++- .../config-multi-chain-effective.toml | 6 +++-- .../resolver/testdata/config-multi-chain.toml | 4 +++ docs/CONFIG.md | 15 ++++++++--- go.mod | 2 +- go.sum | 4 +-- integration-tests/client/chainlink_models.go | 1 - integration-tests/go.mod | 2 +- integration-tests/go.sum | 4 +-- testdata/scripts/txs/cosmos/create/help.txtar | 2 +- testdata/scripts/txs/cosmos/help.txtar | 2 +- 29 files changed, 122 insertions(+), 83 deletions(-) diff --git a/core/chains/cosmos/chain.go b/core/chains/cosmos/chain.go index d182d57f8f8..82d9a87f4d1 100644 --- a/core/chains/cosmos/chain.go +++ b/core/chains/cosmos/chain.go @@ -62,7 +62,7 @@ func newChain(id string, cfg coscfg.Config, db *sqlx.DB, ks keystore.Cosmos, log gpe := cosmosclient.NewMustGasPriceEstimator([]cosmosclient.GasPricesEstimator{ cosmosclient.NewClosureGasPriceEstimator(func() (map[string]sdk.DecCoin, error) { return map[string]sdk.DecCoin{ - "uatom": sdk.NewDecCoinFromDec("uatom", cfg.FallbackGasPrice()), + cfg.FeeToken(): sdk.NewDecCoinFromDec(cfg.FeeToken(), cfg.FallbackGasPrice()), }, nil }), }, lggr) diff --git a/core/chains/cosmos/config.go b/core/chains/cosmos/config.go index 41de217f010..62a76be44d1 100644 --- a/core/chains/cosmos/config.go +++ b/core/chains/cosmos/config.go @@ -255,6 +255,9 @@ func (c *CosmosConfig) SetFrom(f *CosmosConfig) { } func setFromChain(c, f *coscfg.Chain) { + if f.Bech32Prefix != nil { + c.Bech32Prefix = f.Bech32Prefix + } if f.BlockRate != nil { c.BlockRate = f.BlockRate } @@ -267,8 +270,8 @@ func setFromChain(c, f *coscfg.Chain) { if f.FallbackGasPrice != nil { c.FallbackGasPrice = f.FallbackGasPrice } - if f.FCDURL != nil { - c.FCDURL = f.FCDURL + if f.FeeToken != nil { + c.FeeToken = f.FeeToken } if f.GasLimitMultiplier != nil { c.GasLimitMultiplier = f.GasLimitMultiplier @@ -279,11 +282,11 @@ func setFromChain(c, f *coscfg.Chain) { if f.OCR2CachePollPeriod != nil { c.OCR2CachePollPeriod = f.OCR2CachePollPeriod } - if f.BlockRate != nil { - c.BlockRate = f.BlockRate + if f.OCR2CacheTTL != nil { + c.OCR2CacheTTL = f.OCR2CacheTTL } - if f.BlockRate != nil { - c.BlockRate = f.BlockRate + if f.TxMsgTimeout != nil { + c.TxMsgTimeout = f.TxMsgTimeout } } @@ -311,6 +314,10 @@ func (c *CosmosConfig) TOMLString() (string, error) { var _ coscfg.Config = &CosmosConfig{} +func (c *CosmosConfig) Bech32Prefix() string { + return *c.Chain.Bech32Prefix +} + func (c *CosmosConfig) BlockRate() time.Duration { return c.Chain.BlockRate.Duration() } @@ -327,8 +334,8 @@ func (c *CosmosConfig) FallbackGasPrice() sdk.Dec { return sdkDecFromDecimal(c.Chain.FallbackGasPrice) } -func (c *CosmosConfig) FCDURL() url.URL { - return (url.URL)(*c.Chain.FCDURL) +func (c *CosmosConfig) FeeToken() string { + return *c.Chain.FeeToken } func (c *CosmosConfig) GasLimitMultiplier() float64 { diff --git a/core/chains/cosmos/cosmostxm/main_test.go b/core/chains/cosmos/cosmostxm/main_test.go index 5d01e418927..bc340afa430 100644 --- a/core/chains/cosmos/cosmostxm/main_test.go +++ b/core/chains/cosmos/cosmostxm/main_test.go @@ -10,7 +10,7 @@ import ( func TestMain(m *testing.M) { params.InitCosmosSdk( /* bech32Prefix= */ "wasm", - /* token= */ "atom", + /* token= */ "cosm", ) code := m.Run() os.Exit(code) diff --git a/core/chains/cosmos/cosmostxm/txm.go b/core/chains/cosmos/cosmostxm/txm.go index 02be242ad18..7b0e2ad2887 100644 --- a/core/chains/cosmos/cosmostxm/txm.go +++ b/core/chains/cosmos/cosmostxm/txm.go @@ -498,12 +498,12 @@ func (txm *Txm) GetMsgs(ids ...int64) (adapters.Msgs, error) { return txm.orm.GetMsgs(ids...) } -// GasPrice returns the gas price from the estimator in uatom. +// GasPrice returns the gas price from the estimator in the configured fee token. func (txm *Txm) GasPrice() (sdk.DecCoin, error) { prices := txm.gpe.GasPrices() - gasPrice, ok := prices["uatom"] + gasPrice, ok := prices[txm.cfg.FeeToken()] if !ok { - return sdk.DecCoin{}, errors.New("unexpected empty uatom price") + return sdk.DecCoin{}, errors.New("unexpected empty gas price") } return gasPrice, nil } diff --git a/core/chains/cosmos/cosmostxm/txm_internal_test.go b/core/chains/cosmos/cosmostxm/txm_internal_test.go index 5b766d528da..6a9944a1a53 100644 --- a/core/chains/cosmos/cosmostxm/txm_internal_test.go +++ b/core/chains/cosmos/cosmostxm/txm_internal_test.go @@ -23,6 +23,7 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/internal/testutils" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/cosmostest" "github.com/smartcontractkit/chainlink/v2/core/internal/testutils/pgtest" + "github.com/smartcontractkit/chainlink/v2/core/logger" "github.com/smartcontractkit/chainlink/v2/core/services/keystore" "github.com/smartcontractkit/chainlink/v2/core/utils" @@ -72,14 +73,18 @@ func TestTxm(t *testing.T) { logCfg := pgtest.NewQConfig(true) chainID := cosmostest.RandomChainID() two := int64(2) + feeToken := "ucosm" cfg := &cosmos.CosmosConfig{Chain: coscfg.Chain{ MaxMsgsPerBatch: &two, + FeeToken: &feeToken, }} cfg.SetDefaults() gpe := cosmosclient.NewMustGasPriceEstimator([]cosmosclient.GasPricesEstimator{ cosmosclient.NewFixedGasPriceEstimator(map[string]cosmostypes.DecCoin{ - "uatom": cosmostypes.NewDecCoinFromDec("uatom", cosmostypes.MustNewDecFromStr("0.01")), - }), + cfg.FeeToken(): cosmostypes.NewDecCoinFromDec(cfg.FeeToken(), cosmostypes.MustNewDecFromStr("0.01")), + }, + lggr.(logger.SugaredLogger), + ), }, lggr) t.Run("single msg", func(t *testing.T) { diff --git a/core/chains/cosmos/cosmostxm/txm_test.go b/core/chains/cosmos/cosmostxm/txm_test.go index d13100e06bf..7bfd76e1d8c 100644 --- a/core/chains/cosmos/cosmostxm/txm_test.go +++ b/core/chains/cosmos/cosmostxm/txm_test.go @@ -36,9 +36,9 @@ import ( func TestTxm_Integration(t *testing.T) { chainID := cosmostest.RandomChainID() - fallbackGasPrice := sdk.NewDecCoinFromDec("uatom", sdk.MustNewDecFromStr("0.01")) cosmosChain := coscfg.Chain{} cosmosChain.SetDefaults() + fallbackGasPrice := sdk.NewDecCoinFromDec(*cosmosChain.FeeToken, sdk.MustNewDecFromStr("0.01")) chainConfig := cosmos.CosmosConfig{ChainID: &chainID, Enabled: ptr(true), Chain: cosmosChain} cfg, db := heavyweight.FullTestDBNoFixturesV2(t, "cosmos_txm", func(c *chainlink.Config, s *chainlink.Secrets) { c.Cosmos = cosmos.CosmosConfigs{&chainConfig} @@ -47,8 +47,10 @@ func TestTxm_Integration(t *testing.T) { logCfg := pgtest.NewQConfig(true) gpe := cosmosclient.NewMustGasPriceEstimator([]cosmosclient.GasPricesEstimator{ cosmosclient.NewFixedGasPriceEstimator(map[string]sdk.DecCoin{ - "uatom": fallbackGasPrice, - }), + *cosmosChain.FeeToken: fallbackGasPrice, + }, + lggr.(logger.SugaredLogger), + ), }, lggr) orm := cosmostxm.NewORM(chainID, db, lggr, logCfg) eb := pg.NewEventBroadcaster(cfg.Database().URL(), 0, 0, lggr, uuid.New()) @@ -57,11 +59,11 @@ func TestTxm_Integration(t *testing.T) { ks := keystore.New(db, utils.FastScryptParams, lggr, pgtest.NewQConfig(true)) zeConfig := sdk.GetConfig() fmt.Println(zeConfig) - accounts, testdir, tendermintURL := cosmosclient.SetupLocalCosmosNode(t, chainID, "uatom") + accounts, testdir, tendermintURL := cosmosclient.SetupLocalCosmosNode(t, chainID, *cosmosChain.FeeToken) tc, err := cosmosclient.NewClient(chainID, tendermintURL, cosmos.DefaultRequestTimeout, lggr) require.NoError(t, err) - // First create a transmitter key and fund it with 1k uatom + // First create a transmitter key and fund it with 1k native tokens require.NoError(t, ks.Unlock("blah")) transmitterKey, err := ks.Cosmos().Create() require.NoError(t, err) @@ -69,8 +71,8 @@ func TestTxm_Integration(t *testing.T) { require.NoError(t, err) an, sn, err := tc.Account(accounts[0].Address) require.NoError(t, err) - resp, err := tc.SignAndBroadcast([]sdk.Msg{banktypes.NewMsgSend(accounts[0].Address, transmitterID, sdk.NewCoins(sdk.NewInt64Coin("uatom", 100000)))}, - an, sn, gpe.GasPrices()["uatom"], accounts[0].PrivateKey, txtypes.BroadcastMode_BROADCAST_MODE_SYNC) + resp, err := tc.SignAndBroadcast([]sdk.Msg{banktypes.NewMsgSend(accounts[0].Address, transmitterID, sdk.NewCoins(sdk.NewInt64Coin(*cosmosChain.FeeToken, 100000)))}, + an, sn, gpe.GasPrices()[*cosmosChain.FeeToken], accounts[0].PrivateKey, txtypes.BroadcastMode_BROADCAST_MODE_SYNC) tx, success := cosmosclient.AwaitTxCommitted(t, tc, resp.TxResponse.TxHash) require.True(t, success) require.Equal(t, types.CodeTypeOK, tx.TxResponse.Code) @@ -78,7 +80,7 @@ func TestTxm_Integration(t *testing.T) { // TODO: find a way to pull this test artifact from // the chainlink-cosmos repo instead of copying it to cores testdata - contractID := cosmosclient.DeployTestContract(t, tendermintURL, chainID, "uatom", accounts[0], cosmosclient.Account{ + contractID := cosmosclient.DeployTestContract(t, tendermintURL, chainID, *cosmosChain.FeeToken, accounts[0], cosmosclient.Account{ Name: "transmitter", PrivateKey: cosmostxm.NewKeyWrapper(transmitterKey), Address: transmitterID, diff --git a/core/cmd/cosmos_transaction_commands.go b/core/cmd/cosmos_transaction_commands.go index 2f8f7d8df89..7c53d1ff1da 100644 --- a/core/cmd/cosmos_transaction_commands.go +++ b/core/cmd/cosmos_transaction_commands.go @@ -21,8 +21,8 @@ func initCosmosTxSubCmd(s *Shell) cli.Command { Subcommands: []cli.Command{ { Name: "create", - Usage: "Send Atom from node Cosmos account to destination .", - Action: s.CosmosSendAtom, + Usage: "Send of from node Cosmos account to destination .", + Action: s.CosmosSendNativeToken, Flags: []cli.Flag{ cli.BoolFlag{ Name: "force", @@ -61,18 +61,24 @@ func (p *CosmosMsgPresenter) RenderTable(rt RendererTable) error { return nil } -// CosmosSendAtom transfers coins from the node's account to a specified address. -func (s *Shell) CosmosSendAtom(c *cli.Context) (err error) { +// CosmosSendNativeToken transfers coins from the node's account to a specified address. +func (s *Shell) CosmosSendNativeToken(c *cli.Context) (err error) { if c.NArg() < 3 { - return s.errorOut(errors.New("three arguments expected: amount, fromAddress and toAddress")) + return s.errorOut(errors.New("four arguments expected: token, amount, fromAddress and toAddress")) } - amount, err := sdk.NewDecFromStr(c.Args().Get(0)) + err = sdk.ValidateDenom(c.Args().Get(0)) if err != nil { - return s.errorOut(fmt.Errorf("invalid coin: %w", err)) + return s.errorOut(fmt.Errorf("invalid native token: %w", err)) } - unparsedFromAddress := c.Args().Get(1) + amount, err := sdk.NewDecFromStr(c.Args().Get(1)) + if err != nil { + return s.errorOut(multierr.Combine( + fmt.Errorf("invalid coin: %w", err))) + } + + unparsedFromAddress := c.Args().Get(2) fromAddress, err := sdk.AccAddressFromBech32(unparsedFromAddress) if err != nil { return s.errorOut(multierr.Combine( @@ -80,7 +86,7 @@ func (s *Shell) CosmosSendAtom(c *cli.Context) (err error) { unparsedFromAddress), err)) } - unparsedDestinationAddress := c.Args().Get(2) + unparsedDestinationAddress := c.Args().Get(3) destinationAddress, err := sdk.AccAddressFromBech32(unparsedDestinationAddress) if err != nil { return s.errorOut(multierr.Combine( @@ -98,6 +104,7 @@ func (s *Shell) CosmosSendAtom(c *cli.Context) (err error) { FromAddress: fromAddress, Amount: amount, CosmosChainID: chainID, + Token: c.Args().Get(0), AllowHigherAmounts: c.IsSet("force"), } diff --git a/core/cmd/cosmos_transaction_commands_test.go b/core/cmd/cosmos_transaction_commands_test.go index 593747c6f18..11b89c5232a 100644 --- a/core/cmd/cosmos_transaction_commands_test.go +++ b/core/cmd/cosmos_transaction_commands_test.go @@ -32,11 +32,13 @@ import ( "github.com/smartcontractkit/chainlink/v2/core/services/keystore/keys/cosmoskey" ) +var nativeToken = "cosm" + func TestMain(m *testing.M) { params.InitCosmosSdk( /* bech32Prefix= */ "wasm", - /* token= */ "atom", + /* token= */ nativeToken, ) code := m.Run() @@ -46,10 +48,10 @@ func TestMain(m *testing.M) { func TestShell_SendCosmosCoins(t *testing.T) { // TODO(BCI-978): cleanup once SetupLocalCosmosNode is updated chainID := cosmostest.RandomChainID() - accounts, _, url := cosmosclient.SetupLocalCosmosNode(t, chainID, "uatom") - require.Greater(t, len(accounts), 1) cosmosChain := coscfg.Chain{} cosmosChain.SetDefaults() + accounts, _, url := cosmosclient.SetupLocalCosmosNode(t, chainID, *cosmosChain.FeeToken) + require.Greater(t, len(accounts), 1) nodes := cosmos.CosmosNodes{ &coscfg.Node{ Name: ptr("random"), @@ -69,7 +71,7 @@ func TestShell_SendCosmosCoins(t *testing.T) { require.NoError(t, err) require.Eventually(t, func() bool { - coin, err := reader.Balance(from.Address, "uatom") + coin, err := reader.Balance(from.Address, *cosmosChain.FeeToken) if !assert.NoError(t, err) { return false } @@ -95,17 +97,17 @@ func TestShell_SendCosmosCoins(t *testing.T) { } { tt := tt t.Run(tt.amount, func(t *testing.T) { - startBal, err := reader.Balance(from.Address, "uatom") + startBal, err := reader.Balance(from.Address, *cosmosChain.FeeToken) require.NoError(t, err) set := flag.NewFlagSet("sendcosmoscoins", 0) - cltest.FlagSetApplyFromAction(client.CosmosSendAtom, set, "cosmos") + cltest.FlagSetApplyFromAction(client.CosmosSendNativeToken, set, "cosmos") require.NoError(t, set.Set("id", chainID)) - require.NoError(t, set.Parse([]string{tt.amount, from.Address.String(), to.Address.String()})) + require.NoError(t, set.Parse([]string{nativeToken, tt.amount, from.Address.String(), to.Address.String()})) c := cli.NewContext(cliapp, set, nil) - err = client.CosmosSendAtom(c) + err = client.CosmosSendNativeToken(c) if tt.expErr == "" { require.NoError(t, err) } else { @@ -154,11 +156,11 @@ func TestShell_SendCosmosCoins(t *testing.T) { } // Check balance - endBal, err := reader.Balance(from.Address, "uatom") + endBal, err := reader.Balance(from.Address, *cosmosChain.FeeToken) require.NoError(t, err) if assert.NotNil(t, startBal) && assert.NotNil(t, endBal) { diff := startBal.Sub(*endBal).Amount - sent, err := denom.ConvertDecCoinToDenom(sdk.NewDecCoinFromDec("atom", sdk.MustNewDecFromStr(tt.amount)), "uatom") + sent, err := denom.ConvertDecCoinToDenom(sdk.NewDecCoinFromDec(nativeToken, sdk.MustNewDecFromStr(tt.amount)), *cosmosChain.FeeToken) require.NoError(t, err) if assert.True(t, diff.IsInt64()) && assert.True(t, sent.Amount.IsInt64()) { require.Greater(t, diff.Int64(), sent.Amount.Int64()) diff --git a/core/config/docs/chains-cosmos.toml b/core/config/docs/chains-cosmos.toml index 1a5155f3cd6..3281c6c27a6 100644 --- a/core/config/docs/chains-cosmos.toml +++ b/core/config/docs/chains-cosmos.toml @@ -3,6 +3,8 @@ ChainID = 'Malaga-420' # Example # Enabled enables this chain. Enabled = true # Default +# Bech32Prefix is the human-readable prefix for addresses on this Cosmos chain. See https://docs.cosmos.network/v0.47/spec/addresses/bech32. +Bech32Prefix = 'wasm' # Default # BlockRate is the average time between blocks. BlockRate = '6s' # Default # BlocksUntilTxTimeout is the number of blocks to wait before giving up on the tx getting confirmed. @@ -11,8 +13,8 @@ BlocksUntilTxTimeout = 30 # Default ConfirmPollPeriod = '1s' # Default # FallbackGasPrice sets a fallback gas price to use when the estimator is not available. FallbackGasPrice = '0.015' # Default -# FCDURL sets the FCD (Full Client Daemon) URL. -FCDURL = 'http://cosmos.com' # Example +# FeeToken is the token denomination which is being used to pay gas fees on this chain. +FeeToken = 'ucosm' # Default # GasLimitMultiplier scales the estimated gas limit. GasLimitMultiplier = '1.5' # Default # MaxMsgsPerBatch limits the numbers of mesages per transaction batch. diff --git a/core/scripts/go.mod b/core/scripts/go.mod index 5bbaf919d5b..50da3a9cc76 100644 --- a/core/scripts/go.mod +++ b/core/scripts/go.mod @@ -297,7 +297,7 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect diff --git a/core/scripts/go.sum b/core/scripts/go.sum index 7830ad734e6..7da9f19e2be 100644 --- a/core/scripts/go.sum +++ b/core/scripts/go.sum @@ -1369,8 +1369,8 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048 h1:OHj8qzXajBAIT9TBnHN5LVGoCxvso/4JgCeg/l76Tgk= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048/go.mod h1:xMwqRdj5vqYhCJXgKVqvyAwdcqM6ZAEhnwEQ4Khsop8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 h1:z9PIgm0klhunwPy+KZYR4E9vCpjgJaMOyQRLCYgfoLk= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= diff --git a/core/services/chainlink/config_test.go b/core/services/chainlink/config_test.go index 4ce91f4d11c..e2e12545613 100644 --- a/core/services/chainlink/config_test.go +++ b/core/services/chainlink/config_test.go @@ -609,11 +609,12 @@ func TestConfig_Marshal(t *testing.T) { ChainID: ptr("Malaga-420"), Enabled: ptr(true), Chain: coscfg.Chain{ + Bech32Prefix: ptr("wasm"), BlockRate: relayutils.MustNewDuration(time.Minute), BlocksUntilTxTimeout: ptr[int64](12), ConfirmPollPeriod: relayutils.MustNewDuration(time.Second), FallbackGasPrice: mustDecimal("0.001"), - FCDURL: relayutils.MustParseURL("http://cosmos.com"), + FeeToken: ptr("ucosm"), GasLimitMultiplier: mustDecimal("1.2"), MaxMsgsPerBatch: ptr[int64](17), OCR2CachePollPeriod: relayutils.MustNewDuration(time.Minute), @@ -956,11 +957,12 @@ SendOnly = true {"Cosmos", Config{Cosmos: full.Cosmos}, `[[Cosmos]] ChainID = 'Malaga-420' Enabled = true +Bech32Prefix = 'wasm' BlockRate = '1m0s' BlocksUntilTxTimeout = 12 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.001' -FCDURL = 'http://cosmos.com' +FeeToken = 'ucosm' GasLimitMultiplier = '1.2' MaxMsgsPerBatch = 17 OCR2CachePollPeriod = '1m0s' diff --git a/core/services/chainlink/relayer_chain_interoperators_test.go b/core/services/chainlink/relayer_chain_interoperators_test.go index acdb05f1776..e86900ea0ee 100644 --- a/core/services/chainlink/relayer_chain_interoperators_test.go +++ b/core/services/chainlink/relayer_chain_interoperators_test.go @@ -139,6 +139,8 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { Enabled: ptr(true), Chain: coscfg.Chain{ GasLimitMultiplier: ptr(decimal.RequireFromString("1.55555")), + Bech32Prefix: ptr("wasm"), + FeeToken: ptr("cosm"), }, Nodes: cosmos.CosmosNodes{ &coscfg.Node{ @@ -152,6 +154,8 @@ func TestCoreRelayerChainInteroperators(t *testing.T) { Enabled: ptr(true), Chain: coscfg.Chain{ GasLimitMultiplier: ptr(decimal.RequireFromString("0.777")), + Bech32Prefix: ptr("wasm"), + FeeToken: ptr("cosm"), }, Nodes: cosmos.CosmosNodes{ &coscfg.Node{ diff --git a/core/services/chainlink/testdata/config-full.toml b/core/services/chainlink/testdata/config-full.toml index c269fbfedb8..4279cc729f9 100644 --- a/core/services/chainlink/testdata/config-full.toml +++ b/core/services/chainlink/testdata/config-full.toml @@ -320,11 +320,12 @@ SendOnly = true [[Cosmos]] ChainID = 'Malaga-420' Enabled = true +Bech32Prefix = 'wasm' BlockRate = '1m0s' BlocksUntilTxTimeout = 12 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.001' -FCDURL = 'http://cosmos.com' +FeeToken = 'ucosm' GasLimitMultiplier = '1.2' MaxMsgsPerBatch = 17 OCR2CachePollPeriod = '1m0s' diff --git a/core/services/chainlink/testdata/config-multi-chain-effective.toml b/core/services/chainlink/testdata/config-multi-chain-effective.toml index cbd5d14f481..d6b38349b83 100644 --- a/core/services/chainlink/testdata/config-multi-chain-effective.toml +++ b/core/services/chainlink/testdata/config-multi-chain-effective.toml @@ -451,11 +451,12 @@ WSURL = 'wss://web.socket/test/bar' [[Cosmos]] ChainID = 'Ibiza-808' +Bech32Prefix = 'wasm' BlockRate = '6s' BlocksUntilTxTimeout = 30 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.015' -FCDURL = '' +FeeToken = 'ucosm' GasLimitMultiplier = '1.5' MaxMsgsPerBatch = 13 OCR2CachePollPeriod = '4s' @@ -468,11 +469,12 @@ TendermintURL = 'http://columbus.cosmos.com' [[Cosmos]] ChainID = 'Malaga-420' +Bech32Prefix = 'wasm' BlockRate = '6s' BlocksUntilTxTimeout = 20 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.015' -FCDURL = '' +FeeToken = 'ucosm' GasLimitMultiplier = '1.5' MaxMsgsPerBatch = 100 OCR2CachePollPeriod = '4s' diff --git a/core/store/models/cosmos/common.go b/core/store/models/cosmos/common.go index 8143b899cf0..1bf896eb8c2 100644 --- a/core/store/models/cosmos/common.go +++ b/core/store/models/cosmos/common.go @@ -8,5 +8,6 @@ type SendRequest struct { FromAddress sdk.AccAddress `json:"from"` Amount sdk.Dec `json:"amount"` CosmosChainID string `json:"cosmosChainID"` + Token string `json:"token"` AllowHigherAmounts bool `json:"allowHigherAmounts"` } diff --git a/core/web/cosmos_chains_controller_test.go b/core/web/cosmos_chains_controller_test.go index 10a057a5919..f670076d748 100644 --- a/core/web/cosmos_chains_controller_test.go +++ b/core/web/cosmos_chains_controller_test.go @@ -43,11 +43,12 @@ func Test_CosmosChainsController_Show(t *testing.T) { Enabled: true, Config: `ChainID = 'Chainlink-12' Enabled = true +Bech32Prefix = 'wasm' BlockRate = '6s' BlocksUntilTxTimeout = 30 ConfirmPollPeriod = '1s' FallbackGasPrice = '9.999' -FCDURL = '' +FeeToken = 'ucosm' GasLimitMultiplier = '1.55555' MaxMsgsPerBatch = 100 OCR2CachePollPeriod = '4s' diff --git a/core/web/cosmos_transfer_controller.go b/core/web/cosmos_transfer_controller.go index 5276fa758a0..2409a05e6a4 100644 --- a/core/web/cosmos_transfer_controller.go +++ b/core/web/cosmos_transfer_controller.go @@ -26,7 +26,7 @@ type CosmosTransfersController struct { App chainlink.Application } -// Create sends Atom and other native coins from the Chainlink's account to a specified address. +// Create sends native coins from the Chainlink's account to a specified address. func (tc *CosmosTransfersController) Create(c *gin.Context) { cosmosChains := tc.App.GetRelayers().LegacyCosmosChains() if cosmosChains == nil { @@ -58,10 +58,9 @@ func (tc *CosmosTransfersController) Create(c *gin.Context) { jsonAPIError(c, http.StatusUnprocessableEntity, errors.Errorf("withdrawal source address is missing: %v", tr.FromAddress)) return } - - coin, err := denom.ConvertDecCoinToDenom(sdk.NewDecCoinFromDec("atom", tr.Amount), "uatom") + coin, err := denom.ConvertDecCoinToDenom(sdk.NewDecCoinFromDec(tr.Token, tr.Amount), chain.Config().FeeToken()) if err != nil { - jsonAPIError(c, http.StatusBadRequest, errors.Errorf("unable to convert to uatom: %v", err)) + jsonAPIError(c, http.StatusBadRequest, errors.Errorf("unable to convert %s to %s: %v", tr.Token, chain.Config().FeeToken(), err)) return } else if !coin.Amount.IsPositive() { jsonAPIError(c, http.StatusBadRequest, errors.Errorf("amount must be greater than zero: %s", coin.Amount)) @@ -118,17 +117,8 @@ func (tc *CosmosTransfersController) Create(c *gin.Context) { } // cosmosValidateBalance validates that fromAddr's balance can cover coin, including fees at gasPrice. -// Note: This is currently limited to uatom only, for both gasPrice and coin. func cosmosValidateBalance(reader client.Reader, gasPrice sdk.DecCoin, fromAddr sdk.AccAddress, coin sdk.Coin) error { - const denom = "uatom" - if gasPrice.Denom != denom { - return errors.Errorf("unsupported gas price denom: %s", gasPrice.Denom) - } - if coin.Denom != denom { - return errors.Errorf("unsupported coin denom: %s", gasPrice.Denom) - } - - balance, err := reader.Balance(fromAddr, denom) + balance, err := reader.Balance(fromAddr, coin.GetDenom()) if err != nil { return err } diff --git a/core/web/resolver/testdata/config-full.toml b/core/web/resolver/testdata/config-full.toml index 08ba7e0ee6c..96f24b1955c 100644 --- a/core/web/resolver/testdata/config-full.toml +++ b/core/web/resolver/testdata/config-full.toml @@ -319,11 +319,12 @@ SendOnly = true [[Cosmos]] ChainID = 'Malaga-420' Enabled = true +Bech32Prefix = 'wasm' BlockRate = '1m0s' BlocksUntilTxTimeout = 12 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.001' -FCDURL = 'http://cosmos.com' +FeeToken = 'ucosm' GasLimitMultiplier = '1.2' MaxMsgsPerBatch = 17 OCR2CachePollPeriod = '1m0s' diff --git a/core/web/resolver/testdata/config-multi-chain-effective.toml b/core/web/resolver/testdata/config-multi-chain-effective.toml index cbd5d14f481..d6b38349b83 100644 --- a/core/web/resolver/testdata/config-multi-chain-effective.toml +++ b/core/web/resolver/testdata/config-multi-chain-effective.toml @@ -451,11 +451,12 @@ WSURL = 'wss://web.socket/test/bar' [[Cosmos]] ChainID = 'Ibiza-808' +Bech32Prefix = 'wasm' BlockRate = '6s' BlocksUntilTxTimeout = 30 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.015' -FCDURL = '' +FeeToken = 'ucosm' GasLimitMultiplier = '1.5' MaxMsgsPerBatch = 13 OCR2CachePollPeriod = '4s' @@ -468,11 +469,12 @@ TendermintURL = 'http://columbus.cosmos.com' [[Cosmos]] ChainID = 'Malaga-420' +Bech32Prefix = 'wasm' BlockRate = '6s' BlocksUntilTxTimeout = 20 ConfirmPollPeriod = '1s' FallbackGasPrice = '0.015' -FCDURL = '' +FeeToken = 'ucosm' GasLimitMultiplier = '1.5' MaxMsgsPerBatch = 100 OCR2CachePollPeriod = '4s' diff --git a/core/web/resolver/testdata/config-multi-chain.toml b/core/web/resolver/testdata/config-multi-chain.toml index 53425dd1afe..eee786e69bf 100644 --- a/core/web/resolver/testdata/config-multi-chain.toml +++ b/core/web/resolver/testdata/config-multi-chain.toml @@ -71,6 +71,8 @@ WSURL = 'wss://web.socket/test/bar' [[Cosmos]] ChainID = 'Ibiza-808' +Bech32Prefix = 'wasm' +FeeToken = 'ucosm' MaxMsgsPerBatch = 13 [[Cosmos.Nodes]] @@ -79,7 +81,9 @@ TendermintURL = 'http://columbus.cosmos.com' [[Cosmos]] ChainID = 'Malaga-420' +Bech32Prefix = 'wasm' BlocksUntilTxTimeout = 20 +FeeToken = 'ucosm' [[Cosmos.Nodes]] Name = 'secondary' diff --git a/docs/CONFIG.md b/docs/CONFIG.md index 57aed6862b5..efbe9cbbf01 100644 --- a/docs/CONFIG.md +++ b/docs/CONFIG.md @@ -5135,11 +5135,12 @@ GasLimit controls the gas limit for transmit transactions from ocr2automation jo [[Cosmos]] ChainID = 'Malaga-420' # Example Enabled = true # Default +Bech32Prefix = 'wasm' # Default BlockRate = '6s' # Default BlocksUntilTxTimeout = 30 # Default ConfirmPollPeriod = '1s' # Default FallbackGasPrice = '0.015' # Default -FCDURL = 'http://cosmos.com' # Example +FeeToken = 'ucosm' # Default GasLimitMultiplier = '1.5' # Default MaxMsgsPerBatch = 100 # Default OCR2CachePollPeriod = '4s' # Default @@ -5160,6 +5161,12 @@ Enabled = true # Default ``` Enabled enables this chain. +### Bech32Prefix +```toml +Bech32Prefix = 'wasm' # Default +``` +Bech32Prefix is the human-readable prefix for addresses on this Cosmos chain. See https://docs.cosmos.network/v0.47/spec/addresses/bech32. + ### BlockRate ```toml BlockRate = '6s' # Default @@ -5184,11 +5191,11 @@ FallbackGasPrice = '0.015' # Default ``` FallbackGasPrice sets a fallback gas price to use when the estimator is not available. -### FCDURL +### FeeToken ```toml -FCDURL = 'http://cosmos.com' # Example +FeeToken = 'ucosm' # Default ``` -FCDURL sets the FCD (Full Client Daemon) URL. +FeeToken is the token denomination which is being used to pay gas fees on this chain. ### GasLimitMultiplier ```toml diff --git a/go.mod b/go.mod index eec11c19cec..e6afe0f8d18 100644 --- a/go.mod +++ b/go.mod @@ -65,7 +65,7 @@ require ( github.com/shirou/gopsutil/v3 v3.22.12 github.com/shopspring/decimal v1.3.1 github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048 // TODO: update when https://github.com/smartcontractkit/chainlink-cosmos/pull/356 is merged github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a diff --git a/go.sum b/go.sum index de3cfe7acc7..589d6cece36 100644 --- a/go.sum +++ b/go.sum @@ -1369,8 +1369,8 @@ github.com/sirupsen/logrus v1.9.3 h1:dueUQJ1C2q9oE3F7wvmSGAaVtTmUizReu6fjN8uqzbQ github.com/sirupsen/logrus v1.9.3/go.mod h1:naHLuLoDiP4jHNo9R0sCBMtWGeIprob74mVsIT4qYEQ= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048 h1:OHj8qzXajBAIT9TBnHN5LVGoCxvso/4JgCeg/l76Tgk= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048/go.mod h1:xMwqRdj5vqYhCJXgKVqvyAwdcqM6ZAEhnwEQ4Khsop8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 h1:z9PIgm0klhunwPy+KZYR4E9vCpjgJaMOyQRLCYgfoLk= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2/go.mod h1:gWclxGW7rLkbjXn7FGizYlyKhp/boekto4MEYGyiMG4= github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 h1:/fm02hYSUdhbSh7xPn7os9yHj7dnl8aLs2+nFXPiB4g= diff --git a/integration-tests/client/chainlink_models.go b/integration-tests/client/chainlink_models.go index e01b07ab2c3..881b2d125e8 100644 --- a/integration-tests/client/chainlink_models.go +++ b/integration-tests/client/chainlink_models.go @@ -428,7 +428,6 @@ type CosmosChainConfig struct { type CosmosChainAttributes struct { ChainID string `json:"chainID"` Config CosmosChainConfig `json:"config"` - FCDURL string `json:"fcdURL" db:"fcd_url"` } // CosmosChain is the model that represents the terra chain when read diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 69450aef6cd..9ad8b7164ce 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -380,7 +380,7 @@ require ( github.com/shopspring/decimal v1.3.1 // indirect github.com/sirupsen/logrus v1.9.3 // indirect github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 // indirect - github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 // indirect + github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048 // indirect github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 // indirect github.com/smartcontractkit/chainlink-solana v1.0.3-0.20230802143301-165000751a85 // indirect github.com/smartcontractkit/chainlink-starknet/relayer v0.0.1-beta-test.0.20230802150127-d2c95679d61a // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 28def434dd5..187291d8510 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -2237,8 +2237,8 @@ github.com/slack-go/slack v0.12.2 h1:x3OppyMyGIbbiyFhsBmpf9pwkUzMhthJMRNmNlA4LaQ github.com/slack-go/slack v0.12.2/go.mod h1:hlGi5oXA+Gt+yWTPP0plCdRKmjsDxecdHxYQdlMQKOw= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704 h1:T3lFWumvbfM1u/etVq42Afwq/jtNSBSOA8n5jntnNPo= github.com/smartcontractkit/caigo v0.0.0-20230621050857-b29a4ca8c704/go.mod h1:2QuJdEouTWjh5BDy5o/vgGXQtR4Gz8yH1IYB5eT7u4M= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665 h1:gtgDzthL8YLz+0SMfqj0SM6BdTJ/79UuhNbHmL8/3tA= -github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230811192642-2299ce672665/go.mod h1:FivgQBChVNSUUMKdOtzRJFSto2g40nfOkWVAA65nHOI= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048 h1:OHj8qzXajBAIT9TBnHN5LVGoCxvso/4JgCeg/l76Tgk= +github.com/smartcontractkit/chainlink-cosmos v0.4.1-0.20230824124058-9b063c470048/go.mod h1:xMwqRdj5vqYhCJXgKVqvyAwdcqM6ZAEhnwEQ4Khsop8= github.com/smartcontractkit/chainlink-env v0.36.0 h1:CFOjs0c0y3lrHi/fl5qseCH9EQa5W/6CFyOvmhe2VnA= github.com/smartcontractkit/chainlink-env v0.36.0/go.mod h1:NbRExHmJGnKSYXmvNuJx5VErSx26GtE1AEN/CRzYOg8= github.com/smartcontractkit/chainlink-relay v0.1.7-0.20230824125819-215fd09979a2 h1:z9PIgm0klhunwPy+KZYR4E9vCpjgJaMOyQRLCYgfoLk= diff --git a/testdata/scripts/txs/cosmos/create/help.txtar b/testdata/scripts/txs/cosmos/create/help.txtar index 1c11a02c11f..88876b0924a 100644 --- a/testdata/scripts/txs/cosmos/create/help.txtar +++ b/testdata/scripts/txs/cosmos/create/help.txtar @@ -3,7 +3,7 @@ cmp stdout out.txt -- out.txt -- NAME: - chainlink txs cosmos create - Send Atom from node Cosmos account to destination . + chainlink txs cosmos create - Send of from node Cosmos account to destination . USAGE: chainlink txs cosmos create [command options] [arguments...] diff --git a/testdata/scripts/txs/cosmos/help.txtar b/testdata/scripts/txs/cosmos/help.txtar index e2e9524219d..461076e9635 100644 --- a/testdata/scripts/txs/cosmos/help.txtar +++ b/testdata/scripts/txs/cosmos/help.txtar @@ -9,7 +9,7 @@ USAGE: chainlink txs cosmos command [command options] [arguments...] COMMANDS: - create Send Atom from node Cosmos account to destination . + create Send of from node Cosmos account to destination . OPTIONS: --help, -h show help From 57956748c2c7f0ae66de36fbb810fd55e3575065 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Thu, 24 Aug 2023 13:22:24 -0400 Subject: [PATCH 268/270] Bump version and update CHANGELOG for core v2.5.0 --- VERSION | 2 +- docs/CHANGELOG.md | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index 197c4d5c2d7..437459cd94c 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -2.4.0 +2.5.0 diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 56a76249c68..0968b045e97 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -9,6 +9,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ## [dev] +... + +## 2.5.0 - UNRELEASED + ### Upcoming Required Configuration Change - Starting in 2.6.0, chainlink nodes will no longer allow insecure configuration for production builds. Any TOML configuration that sets the following line will fail validation checks in `node start` or `node validate`: From f27c965a2bb69d52c24ac8b2b2cf115af91075bb Mon Sep 17 00:00:00 2001 From: Justin Kaseman Date: Thu, 24 Aug 2023 16:14:26 -0700 Subject: [PATCH 269/270] Add v2.5.0 Functions changelog entry --- docs/CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index 0968b045e97..a1fb2353aa5 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -23,6 +23,10 @@ AllowSimplePasswords=true - To migrate on production builds, update the database password set in Database.URL to be 16 - 50 characters without leading or trailing whitespace. URI parsing rules apply to the chosen password - refer to [RFC 3986](https://datatracker.ietf.org/doc/html/rfc3986) for special character escape rules. +### Added + +- Various Functions improvements + ## 2.4.0 - 2023-08-21 From b96cb806e6ea648799e31a71fb1803607d79cde4 Mon Sep 17 00:00:00 2001 From: chainchad <96362174+chainchad@users.noreply.github.com> Date: Wed, 13 Sep 2023 10:26:57 -0400 Subject: [PATCH 270/270] Update release date for v2.5.0 --- docs/CHANGELOG.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/CHANGELOG.md b/docs/CHANGELOG.md index a1fb2353aa5..a5c31a8b4d7 100644 --- a/docs/CHANGELOG.md +++ b/docs/CHANGELOG.md @@ -11,7 +11,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ... -## 2.5.0 - UNRELEASED + + +## 2.5.0 - 2023-09-13 ### Upcoming Required Configuration Change @@ -27,8 +29,6 @@ AllowSimplePasswords=true - Various Functions improvements - - ## 2.4.0 - 2023-08-21 ### Fixed